Line height 23
This commit is contained in:
parent
c130355a2e
commit
444d293c38
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
|
@ -23,7 +23,7 @@ const AtMention = React.memo(({ mention, mentions, username, navToRoomInfo, styl
|
|||
if (mention === 'all' || mention === 'here') {
|
||||
return (
|
||||
<Text style={[styles.plainText, styles.text]}>
|
||||
<View style={{ marginBottom: isIOS ? -3 : 0 }}>
|
||||
<View style={{ marginBottom: isIOS ? -2 : 0 }}>
|
||||
<Text
|
||||
style={[
|
||||
styles.plainText,
|
||||
|
@ -35,7 +35,8 @@ const AtMention = React.memo(({ mention, mentions, username, navToRoomInfo, styl
|
|||
overflow: 'hidden',
|
||||
marginBottom: isIOS ? 0 : -5,
|
||||
color: themes[theme].pureWhite,
|
||||
backgroundColor: themes[theme].mentionGroupColor
|
||||
backgroundColor: themes[theme].mentionGroupColor,
|
||||
lineHeight: 23
|
||||
}
|
||||
]}
|
||||
>
|
||||
|
@ -76,7 +77,7 @@ const AtMention = React.memo(({ mention, mentions, username, navToRoomInfo, styl
|
|||
const m = useRealName && user.name ? user.name : user.username;
|
||||
return (
|
||||
<Text style={[styles.plainText, styles.text]}>
|
||||
<View style={{ marginBottom: isIOS ? -3 : 0 }}>
|
||||
<View style={{ marginBottom: isIOS ? -2 : 0 }}>
|
||||
<Text
|
||||
style={[
|
||||
styles.plainText,
|
||||
|
@ -86,7 +87,8 @@ const AtMention = React.memo(({ mention, mentions, username, navToRoomInfo, styl
|
|||
...sharedStyles.textMedium,
|
||||
borderRadius: 4,
|
||||
overflow: 'hidden',
|
||||
marginBottom: isIOS ? 0 : -5
|
||||
marginBottom: isIOS ? 0 : -5,
|
||||
lineHeight: 23
|
||||
},
|
||||
mentionStyle
|
||||
]}
|
||||
|
|
|
@ -41,7 +41,7 @@ const Hashtag = React.memo(({ hashtag, channels, navToRoomInfo, style = [] }: IH
|
|||
if (channels && channels.length && channels.findIndex(channel => channel.name === hashtag) !== -1) {
|
||||
return (
|
||||
<Text style={[styles.plainText, styles.text]}>
|
||||
<View style={{ marginBottom: isIOS ? -3 : 0 }}>
|
||||
<View style={{ marginBottom: isIOS ? -2 : 0 }}>
|
||||
<Text
|
||||
style={[
|
||||
styles.plainText,
|
||||
|
@ -53,7 +53,8 @@ const Hashtag = React.memo(({ hashtag, channels, navToRoomInfo, style = [] }: IH
|
|||
overflow: 'hidden',
|
||||
marginBottom: isIOS ? 0 : -5,
|
||||
color: themes[theme].mentionOthersColor,
|
||||
backgroundColor: themes[theme].mentionOthersBackground
|
||||
backgroundColor: themes[theme].mentionOthersBackground,
|
||||
lineHeight: 23
|
||||
}
|
||||
]}
|
||||
onPress={handlePress}
|
||||
|
|
|
@ -33,7 +33,7 @@ const MarkdownPreview = ({ msg, numberOfLines = 1, testID, style = [] }: IMarkdo
|
|||
return (
|
||||
<Text
|
||||
accessibilityLabel={m}
|
||||
style={[styles.text, { color: themes[theme].bodyText }, ...style]}
|
||||
style={[styles.text, { color: themes[theme].bodyText, lineHeight: 16 }, ...style]}
|
||||
numberOfLines={numberOfLines}
|
||||
testID={testID}
|
||||
>
|
||||
|
|
|
@ -136,6 +136,131 @@ const allMentionTokens = [
|
|||
type: 'PLAIN_TEXT',
|
||||
value: 'rocket.cat'
|
||||
}
|
||||
},
|
||||
{
|
||||
type: 'PLAIN_TEXT',
|
||||
value: ' testing '
|
||||
},
|
||||
{
|
||||
type: 'MENTION_USER',
|
||||
value: {
|
||||
type: 'PLAIN_TEXT',
|
||||
value: 'all'
|
||||
}
|
||||
},
|
||||
{
|
||||
type: 'PLAIN_TEXT',
|
||||
value: ' testing '
|
||||
},
|
||||
{
|
||||
type: 'MENTION_USER',
|
||||
value: {
|
||||
type: 'PLAIN_TEXT',
|
||||
value: 'rocket.cat'
|
||||
}
|
||||
},
|
||||
{
|
||||
type: 'PLAIN_TEXT',
|
||||
value: ' testing '
|
||||
},
|
||||
{
|
||||
type: 'MENTION_USER',
|
||||
value: {
|
||||
type: 'PLAIN_TEXT',
|
||||
value: 'all'
|
||||
}
|
||||
},
|
||||
{
|
||||
type: 'PLAIN_TEXT',
|
||||
value: ' testing '
|
||||
},
|
||||
{
|
||||
type: 'MENTION_USER',
|
||||
value: {
|
||||
type: 'PLAIN_TEXT',
|
||||
value: 'rocket.cat'
|
||||
}
|
||||
},
|
||||
{
|
||||
type: 'PLAIN_TEXT',
|
||||
value: ' testing '
|
||||
},
|
||||
{
|
||||
type: 'MENTION_USER',
|
||||
value: {
|
||||
type: 'PLAIN_TEXT',
|
||||
value: 'all'
|
||||
}
|
||||
},
|
||||
{
|
||||
type: 'PLAIN_TEXT',
|
||||
value: ' testing '
|
||||
},
|
||||
{
|
||||
type: 'MENTION_USER',
|
||||
value: {
|
||||
type: 'PLAIN_TEXT',
|
||||
value: 'rocket.cat'
|
||||
}
|
||||
},
|
||||
{
|
||||
type: 'PLAIN_TEXT',
|
||||
value: ' testing '
|
||||
},
|
||||
{
|
||||
type: 'MENTION_USER',
|
||||
value: {
|
||||
type: 'PLAIN_TEXT',
|
||||
value: 'all'
|
||||
}
|
||||
},
|
||||
{
|
||||
type: 'PLAIN_TEXT',
|
||||
value: ' testing '
|
||||
},
|
||||
{
|
||||
type: 'MENTION_USER',
|
||||
value: {
|
||||
type: 'PLAIN_TEXT',
|
||||
value: 'rocket.cat'
|
||||
}
|
||||
},
|
||||
{
|
||||
type: 'PLAIN_TEXT',
|
||||
value: ' testing '
|
||||
},
|
||||
{
|
||||
type: 'MENTION_USER',
|
||||
value: {
|
||||
type: 'PLAIN_TEXT',
|
||||
value: 'all'
|
||||
}
|
||||
},
|
||||
{
|
||||
type: 'PLAIN_TEXT',
|
||||
value: ' testing '
|
||||
},
|
||||
{
|
||||
type: 'MENTION_USER',
|
||||
value: {
|
||||
type: 'PLAIN_TEXT',
|
||||
value: 'rocket.cat'
|
||||
}
|
||||
},
|
||||
{
|
||||
type: 'PLAIN_TEXT',
|
||||
value: ' testing '
|
||||
},
|
||||
{
|
||||
type: 'MENTION_USER',
|
||||
value: {
|
||||
type: 'PLAIN_TEXT',
|
||||
value: 'all'
|
||||
}
|
||||
},
|
||||
{
|
||||
type: 'PLAIN_TEXT',
|
||||
value: ' testing '
|
||||
}
|
||||
]
|
||||
}
|
||||
|
@ -260,25 +385,6 @@ export const Mentions = () => (
|
|||
</View>
|
||||
);
|
||||
|
||||
// export const Mentions = () => (
|
||||
// <View style={styles.container}>
|
||||
// <Text style={{ lineHeight: 24, fontSize: 16, fontFamily: 'Inter', fontWeight: '400' }}>
|
||||
// <AtMention mention='all' />
|
||||
// <Text> asd as das dasd asd asd asd asd asd asd ads adas </Text>
|
||||
// <AtMention mention='all' />
|
||||
// <Text> asd as das dasd asd asd asd asd asd asd ads adas </Text>
|
||||
// <AtMention mention='all' />
|
||||
// <Text> asd as das dasd asd asd asd asd asd asd ads adas </Text>
|
||||
// <AtMention mention='all' />
|
||||
// <Text> asd as das dasd asd asd asd asd asd asd ads adas </Text>
|
||||
// <AtMention mention='all' />
|
||||
// <Text> asd as das dasd asd asd asd asd asd asd ads adas </Text>
|
||||
// <AtMention mention='all' />
|
||||
// <Text> asd as das dasd asd asd asd asd asd asd ads adas </Text>
|
||||
// </Text>
|
||||
// </View>
|
||||
// );
|
||||
|
||||
const channelTokens = [
|
||||
{
|
||||
type: 'PARAGRAPH',
|
||||
|
|
Loading…
Reference in New Issue