Remove superfluous view

This commit is contained in:
Dan Abramov
2024-11-07 11:24:01 +00:00
parent 0110552183
commit 4487136d58
@@ -314,25 +314,23 @@ const ImageItem = ({
return ( return (
<GestureDetector gesture={composedGesture}> <GestureDetector gesture={composedGesture}>
<Animated.View renderToHardwareTextureAndroid> <Animated.View
<Animated.View ref={containerRef}
ref={containerRef} // Necessary to make opacity work for both children together.
// Necessary to make opacity work for both children together. renderToHardwareTextureAndroid
renderToHardwareTextureAndroid style={[styles.container, animatedStyle]}>
style={[styles.container, animatedStyle]}> <ActivityIndicator size="small" color="#FFF" style={styles.loading} />
<ActivityIndicator size="small" color="#FFF" style={styles.loading} /> <AnimatedImage
<AnimatedImage contentFit="cover"
contentFit="cover" source={{uri: imageSrc.uri}}
source={{uri: imageSrc.uri}} placeholderContentFit="cover"
placeholderContentFit="cover" placeholder={{uri: imageSrc.thumbUri}}
placeholder={{uri: imageSrc.thumbUri}} style={imageStyle}
style={imageStyle} accessibilityLabel={imageSrc.alt}
accessibilityLabel={imageSrc.alt} accessibilityHint=""
accessibilityHint="" accessibilityIgnoresInvertColors
accessibilityIgnoresInvertColors cachePolicy="memory"
cachePolicy="memory" />
/>
</Animated.View>
</Animated.View> </Animated.View>
</GestureDetector> </GestureDetector>
) )