aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorIvan Chen <ivan@tagg.id>2021-03-15 18:52:27 -0400
committerIvan Chen <ivan@tagg.id>2021-03-15 18:52:27 -0400
commit39c8ef103966026f4d75fc1a4a4ad3f9cbb0117a (patch)
tree47d0bdf13b3e968d9ea183b097c1f911e251603d /src
parentda60a2a3921a96a5c0b26f682f1b7d5c971dd6df (diff)
adjusted header font size depending on length
Diffstat (limited to 'src')
-rw-r--r--src/routes/main/MainStackScreen.tsx10
1 files changed, 8 insertions, 2 deletions
diff --git a/src/routes/main/MainStackScreen.tsx b/src/routes/main/MainStackScreen.tsx
index 95d45d32..8f7556be 100644
--- a/src/routes/main/MainStackScreen.tsx
+++ b/src/routes/main/MainStackScreen.tsx
@@ -268,7 +268,14 @@ export const headerBarOptions: (
/>
),
headerTitle: () => (
- <Text style={[styles.headerTitle, {color: color}]}>{title}</Text>
+ <Text
+ style={[
+ styles.headerTitle,
+ {color: color},
+ {fontSize: title.length > 18 ? normalize(14) : normalize(16)},
+ ]}>
+ {title}
+ </Text>
),
});
@@ -291,7 +298,6 @@ const styles = StyleSheet.create({
marginLeft: 30,
},
headerTitle: {
- fontSize: normalize(16),
letterSpacing: normalize(1.3),
fontWeight: '700',
},