fix blur on image alt text background

This commit is contained in:
vineyardbovines
2026-05-29 16:03:22 -04:00
parent b0708dcefb
commit f644a6dd99
3 changed files with 44 additions and 32 deletions
+1
View File
@@ -0,0 +1 @@
gif-autoplay@86b6827814e8320576e6a403f11ef4f318a72fc1
+5 -1
View File
@@ -230,7 +230,11 @@ function LightboxGallery({
style={[ style={[
a.px_4xl, a.px_4xl,
a.py_2xl, a.py_2xl,
{backgroundColor: 'rgba(0, 0, 0, 0.45)'}, {
backgroundColor: 'rgba(0, 0, 0, 0.5)',
// @ts-expect-error web only
backdropFilter: 'blur(16px)',
},
delayedFadeInAnim, delayedFadeInAnim,
]}> ]}>
<Pressable <Pressable
+8 -1
View File
@@ -7,6 +7,7 @@ import {
View, View,
} from 'react-native' } from 'react-native'
import {useSafeAreaInsets} from 'react-native-safe-area-context' import {useSafeAreaInsets} from 'react-native-safe-area-context'
import {BlurView} from 'expo-blur'
import {useLingui} from '@lingui/react/macro' import {useLingui} from '@lingui/react/macro'
import {atoms as a, useTheme} from '#/alf' import {atoms as a, useTheme} from '#/alf'
@@ -37,6 +38,7 @@ export function Footer({altText, isAltExpanded, onToggleAltExpanded}: Props) {
{paddingBottom: insets.bottom + 8}, {paddingBottom: insets.bottom + 8},
]}> ]}>
<View style={[a.mx_md, styles.altWrap]}> <View style={[a.mx_md, styles.altWrap]}>
<BlurView intensity={16} tint="dark" style={styles.altBlur}>
<ScrollView <ScrollView
scrollEnabled={isAltExpanded} scrollEnabled={isAltExpanded}
onMomentumScrollBegin={() => { onMomentumScrollBegin={() => {
@@ -67,6 +69,7 @@ export function Footer({altText, isAltExpanded, onToggleAltExpanded}: Props) {
</Text> </Text>
</Pressable> </Pressable>
</ScrollView> </ScrollView>
</BlurView>
</View> </View>
</View> </View>
) )
@@ -74,8 +77,12 @@ export function Footer({altText, isAltExpanded, onToggleAltExpanded}: Props) {
const styles = StyleSheet.create({ const styles = StyleSheet.create({
altWrap: { altWrap: {
backgroundColor: 'rgba(0, 0, 0, 0.45)',
borderRadius: 12, borderRadius: 12,
overflow: 'hidden', overflow: 'hidden',
}, },
altBlur: {
// Tint kept over the blur so dense, text-heavy images stay readable,
// including on Android where the blur falls back to a flat overlay.
backgroundColor: 'rgba(0, 0, 0, 0.5)',
},
}) })