Advertisement
Guest User

Untitled

a guest
Jun 17th, 2019
77
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.64 KB | None | 0 0
  1. import React from "react";
  2. import { View, Text } from "react-native";
  3.  
  4. const Alert = ({ title, text, backgroundColor, borderColor, titleColor, descriptionColor }) => {
  5. return (
  6. <ThemeContext.Consumer>
  7. {theme => (
  8. <View style={[
  9. ...,
  10. {
  11. backgroundColor: backgroundColor,
  12. borderColor: borderColor
  13. }
  14. ]}>
  15. <Text style={[..., { color: titleColor }]}> {title} </Text>
  16. <Text style={[..., { color: descriptionColor }]}> {text} </Text>
  17. </View>
  18. </ThemeContext.Consumer>
  19. );
  20. };
  21.  
  22. export default Alert;
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement