From 8fba03a97aa30e10b0a667a49a30c5191146dd49 Mon Sep 17 00:00:00 2001 From: Ivan Chen Date: Wed, 12 May 2021 14:57:02 -0400 Subject: fixed styling --- src/screens/badge/BadgeItem.tsx | 20 +++++++++++++++----- 1 file changed, 15 insertions(+), 5 deletions(-) (limited to 'src/screens') diff --git a/src/screens/badge/BadgeItem.tsx b/src/screens/badge/BadgeItem.tsx index 1051d4a7..409cc429 100644 --- a/src/screens/badge/BadgeItem.tsx +++ b/src/screens/badge/BadgeItem.tsx @@ -44,7 +44,15 @@ const BadgeItem: React.FC = ({ - {title} + 30 + ? {fontSize: normalize(12), lineHeight: normalize(16)} + : {}, + ]}> + {title} + @@ -53,17 +61,19 @@ const BadgeItem: React.FC = ({ ); }; +const ITEM_WIDTH = SCREEN_WIDTH / 3 - 20; + const styles = StyleSheet.create({ border: { - width: SCREEN_WIDTH / 3 - 20 + 6, - height: 146, + width: ITEM_WIDTH + 6, + height: 156, marginLeft: 10, marginBottom: 12, borderRadius: 8, }, item: { - width: SCREEN_WIDTH / 3 - 20, - height: 140, + width: ITEM_WIDTH, + height: 150, borderRadius: 8, }, detailContainer: { -- cgit v1.2.3-70-g09d2 From d8dfc057e31e334a3e67a5931a9040fb77acfc45 Mon Sep 17 00:00:00 2001 From: Ivan Chen Date: Wed, 12 May 2021 18:16:55 -0400 Subject: cleaned up and adjusted styles --- src/screens/badge/BadgeItem.tsx | 31 ++++++++++++------------------- 1 file changed, 12 insertions(+), 19 deletions(-) (limited to 'src/screens') diff --git a/src/screens/badge/BadgeItem.tsx b/src/screens/badge/BadgeItem.tsx index 409cc429..e4f1b1da 100644 --- a/src/screens/badge/BadgeItem.tsx +++ b/src/screens/badge/BadgeItem.tsx @@ -43,17 +43,15 @@ const BadgeItem: React.FC = ({ style={styles.item}> - - 30 - ? {fontSize: normalize(12), lineHeight: normalize(16)} - : {}, - ]}> - {title} - - + 30 + ? {fontSize: normalize(12), lineHeight: normalize(16)} + : {}, + ]}> + {title} + @@ -78,18 +76,13 @@ const styles = StyleSheet.create({ }, detailContainer: { flexGrow: 1, - justifyContent: 'center', + justifyContent: 'space-evenly', alignItems: 'center', - borderWidth: 3, - borderRadius: 8, - borderColor: 'transparent', }, imageStyles: { - width: 40, - height: 40, - marginTop: '11%', + width: normalize(50), + height: normalize(50), }, - textContainer: {marginTop: '16%'}, title: { fontSize: normalize(15), fontWeight: '500', -- cgit v1.2.3-70-g09d2