Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

BlurView Conflict #27

Open
perryneal11 opened this issue Nov 18, 2023 · 2 comments
Open

BlurView Conflict #27

perryneal11 opened this issue Nov 18, 2023 · 2 comments
Assignees
Labels
bug Something isn't working

Comments

@perryneal11
Copy link

perryneal11 commented Nov 18, 2023

Bug

Because the actionsheet is using the BlurView library, other areas that I use BlurView in are triggering the following error.

Screenshot 2023-11-17 at 11 37 02 PM

I installed using npm install @react-native-community/blur@latest

Environment info

Library Version
@alessiocancian/react-native-actionsheet "^2.4.2"
react-native "0.67.4",
"@react-native-community/blur": "^4.3.2"

Steps To Reproduce

I was not able to run the sample app, and I am working in a private repo. But this is the component causing the error.

Describe what you expected to happen:

1.I expect to be able to add a BlurView in my app without it conflicting with the actionsheet

Reproducible sample code

`            <BlurView
              style={{
                position: 'absolute',
                top: 0,
                left: 0,
                bottom: 0,
                right: 0,
              }}
              // viewRef={this.state.viewRef}
              blurType="dark"
              blurAmount={100}
              reducedTransparencyFallbackColor={AppStyle.colorTheme.black}
            />
            {Platform.OS === 'ios' && (
              <BlurView
                style={{
                  position: 'absolute',
                  top: 0,
                  left: 0,
                  bottom: 0,
                  right: 0,
                }}
                // viewRef={this.state.viewRef}
                blurType="dark"
                blurAmount={100}
                reducedTransparencyFallbackColor={AppStyle.colorTheme.black}
              />
            )}`

                  <ActionSheet
        ref={actionsheetRef}
        options={options}
        cancelButtonIndex={2}
        destructiveButtonIndex={1}
        onPress={index => imagePickerOption(index)}
      />

@perryneal11 perryneal11 added the bug Something isn't working label Nov 18, 2023
@Waltari10
Copy link

Adding resolutions to your package.json should fix this. It prevents from having multiple different versions of the blur package in your deps.

 "resolutions": {
    "@react-native-community/blur": "4.4.0"
  },

@litinskii
Copy link

+1 same error

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

4 participants