Skip to content

Commit ec1ba5d

Browse files
author
pwysowski
committed
fix: avatar header title flex
1 parent 8f4e4d6 commit ec1ba5d

File tree

2 files changed

+6
-4
lines changed

2 files changed

+6
-4
lines changed

src/predefinedComponents/AvatarHeader/AvatarHeader.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -133,7 +133,7 @@ class AvatarHeader extends React.Component {
133133
{ opacity: authorOpacity }
134134
]}
135135
>
136-
<Text style={styles.message}>{title}</Text>
136+
<Text numberOfLines={4} style={[styles.message, styles.foregroundTitle]}>{title}</Text>
137137
</Animated.View>
138138
<Animated.View style={[styles.infoContainer, { opacity: aboutOpacity }]}>
139139
<Text style={styles.infoText}>{subtitle}</Text>

src/predefinedComponents/AvatarHeader/AvatarHeader.styles.js

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,6 @@ export default StyleSheet.create({
3030
marginRight: 12
3131
},
3232
infoContainer: {
33-
flex: 1,
3433
flexDirection: 'row',
3534
marginBottom: 16
3635
},
@@ -42,6 +41,7 @@ export default StyleSheet.create({
4241
width: 56
4342
},
4443
infoText: {
44+
flexGrow: 1,
4545
color: colors.white,
4646
fontSize: constants.normalizedFontSize(16),
4747
lineHeight: 24
@@ -63,7 +63,6 @@ export default StyleSheet.create({
6363
},
6464
userModalMessageContainer: {
6565
marginTop: 12,
66-
flex: 5,
6766
paddingBottom: 8
6867
},
6968
rightHeaderButton: {
@@ -72,5 +71,8 @@ export default StyleSheet.create({
7271
},
7372
leftHeaderButton: {
7473
flex: 1,
74+
},
75+
foregroundTitle: {
76+
flexGrow: 1,
7577
}
76-
})
78+
})

0 commit comments

Comments
 (0)