-
Notifications
You must be signed in to change notification settings - Fork 23
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
Gradient support for the background #18
Comments
You can use customComponent and height/width 100%. Example below: In app.jsx import { heightPercentageToDP, widthPercentageToDP } from 'react-native-responsive-screen';
<AnimatedSplash
translucent={true}
isLoaded={isLoaded}
backgroundColor={#f0f0f0}
logoHeight={heightPercentageToDP(100)}
logoWidth={widthPercentageToDP(100)}
customComponent={<SplashScreenLogo />}>
<App />
</AnimatedSplash> In SplashScreenLogo.jsx import LinearGradient from 'react-native-linear-gradient';
<LinearGradient>
<View
style={styles.container}
{...props}>
<Image
accessibilityIgnoresInvertColors={false}
source={require('../../assets/images/icon-white.png')}
style={styles.logo}
/>
</View>
</LinearGradient> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Hi, there.
Can you please add gradient support for the background? It would be very helpful. Thanks
The text was updated successfully, but these errors were encountered: