Kureev / react-native-blur

React Native Blur component
MIT License
3.76k stars 556 forks source link

Navigation issue with blurView #619

Open nirali-chavda opened 4 months ago

nirali-chavda commented 4 months ago

When i use Below Blurview component with position absolute then my StackNavigation slide animation is not working properly but when i remove position absolute then slide animation works fine but Blurview is not working.

              <BlurView
                style={{ position: "absolute",
                top: 0,
                left: 0,
                bottom: 0,
                right: 0}}
                blurType="light"
                blurAmount={10}
                overlayColor="transparent"
                reducedTransparencyFallbackColor="black"
              />
ChoiHyeongu commented 4 months ago

SAME HERE

ghshgd commented 4 months ago

same here, when I use blur with position absolute and navigate to other screen, that screen(after navigating) is covered white foreground with some opacity

meetwithtaha commented 3 months ago

This is hepping with me too in Android any luck?

DevJoseAle commented 3 months ago

Same here

steadev commented 3 months ago

Same here.. RN 0.74.2

iOS works fine.

Android has this issue

janisievins commented 3 months ago

Facing the same issue. react-native version 0.74.2, @react-native-community/blur version 4.3.2.

martinsinghk commented 2 months ago

In my case, I use the BlurView with absolute position in a navigation bottom bar. When I navigate to the target view, the whole screen would disappear and just leave my APP on plain SplashScreen. I encounter this problem on Android 13 so far, and iOS is just fine.

"react-native": "0.74.2",
"@react-native-community/blur": "^4.4.0",
"@react-navigation/bottom-tabs": "^6.5.20"

So to save my day, I set a boolean state by a 1s timeout in useEffect. Now it seems alright. There's a bit of blur transition in the beginning, though that's fine for me.

  const [blur, setBlur] = React.useState(false);
  useEffect(() => {
    setTimeout(() => {
      setBlur(true);
    }, 1000);
  }, []);
return (
  ...
  <BlurView style={Platform.OS === 'ios' || blur ? { position: 'absolute' } : null} ... />
);

It's a shame but I don't have time to investigate this problem on Android side. Hope that someone else find out the root cause and share here.

mkhotib20 commented 2 months ago

Same here..

@react-native-community/blur version : 4.4.0 react-native version : 0.74.3

Android has this issue iOS works fine.

vmendesneto commented 2 months ago

Has anyone managed to solve it somehow on Android?

Weissheiten commented 2 months ago

There is a discussion here: https://github.com/software-mansion/react-native-screens/issues/1661 and what seems to solve the problem (but introduce a slight flicker) is using the setting: animation: 'slide_from_bottom',

So far no "clean" solution that I know of.