diff options
author | Ivan Chen <ivan@tagg.id> | 2021-04-20 17:16:46 -0400 |
---|---|---|
committer | Ivan Chen <ivan@tagg.id> | 2021-04-20 17:21:46 -0400 |
commit | bae0136cb1939302b758249a1978251bd37aaee8 (patch) | |
tree | 8788895fe72bef062a4de3b3b8e245d091dc3c1f /src/components/common/TaggPrompt.tsx | |
parent | 5ff7cab4bd36337b2c86e3d4915a6fc3ceef1ddb (diff) |
linted
Diffstat (limited to 'src/components/common/TaggPrompt.tsx')
-rw-r--r-- | src/components/common/TaggPrompt.tsx | 14 |
1 files changed, 6 insertions, 8 deletions
diff --git a/src/components/common/TaggPrompt.tsx b/src/components/common/TaggPrompt.tsx index 5e125d00..6b59d4a5 100644 --- a/src/components/common/TaggPrompt.tsx +++ b/src/components/common/TaggPrompt.tsx @@ -1,8 +1,8 @@ -import * as React from 'react'; +import React from 'react'; import {StyleSheet, Text, TouchableOpacity} from 'react-native'; import {Image, View} from 'react-native-animatable'; import CloseIcon from '../../assets/ionicons/close-outline.svg'; -import {isIPhoneX, normalize, SCREEN_HEIGHT} from '../../utils'; +import {normalize, SCREEN_HEIGHT} from '../../utils'; type TaggPromptProps = { messageHeader: string; @@ -39,13 +39,11 @@ const TaggPrompt: React.FC<TaggPromptProps> = ({ } }; + const topPadding = {paddingTop: noPadding ? 0 : SCREEN_HEIGHT / 10}; + const bottomPadding = {paddingBottom: noPadding ? 0 : SCREEN_HEIGHT / 50}; + return ( - <View - style={[ - styles.container, - {paddingTop: noPadding ? 0 : SCREEN_HEIGHT / 10}, - {paddingBottom: noPadding ? 0 : SCREEN_HEIGHT / 50}, - ]}> + <View style={[styles.container, topPadding, bottomPadding]}> <Image style={styles.icon} source={logo()} /> <Text style={styles.header}>{messageHeader}</Text> <Text style={styles.subtext}>{messageBody}</Text> |