File tree Expand file tree Collapse file tree 3 files changed +16
-6
lines changed
packages/uikit-react-native/src
groupChannelThread/component Expand file tree Collapse file tree 3 files changed +16
-6
lines changed Original file line number Diff line number Diff line change @@ -37,6 +37,10 @@ export type SuggestedMentionListProps = {
3737 inputHeight : number ;
3838 onPressToMention : ( user : SendbirdMember , searchStringRange : Range ) => void ;
3939 mentionedUsers : MentionedUser [ ] ;
40+ /**
41+ * Whether to show user id information on each item.
42+ * */
43+ showUserId ?: boolean ;
4044} ;
4145
4246export type ChannelInputProps = {
Original file line number Diff line number Diff line change @@ -26,6 +26,7 @@ const GroupChannelSuggestedMentionList = ({
2626 bottomInset,
2727 onPressToMention,
2828 mentionedUsers,
29+ showUserId = true ,
2930} : GroupChannelProps [ 'SuggestedMentionList' ] ) => {
3031 const { width : screenWidth , height : screenHeight } = useWindowDimensions ( ) ;
3132 const { channel } = useContext ( GroupChannelContexts . Fragment ) ;
@@ -79,9 +80,11 @@ const GroupChannelSuggestedMentionList = ({
7980 < Text body2 color = { colors . onBackground01 } numberOfLines = { 1 } style = { styles . userNickname } >
8081 { member . nickname || STRINGS . LABELS . USER_NO_NAME }
8182 </ Text >
82- < Text body3 color = { colors . onBackground03 } numberOfLines = { 1 } style = { styles . userId } >
83- { member . userId }
84- </ Text >
83+ { ! ! showUserId && (
84+ < Text body3 color = { colors . onBackground03 } numberOfLines = { 1 } style = { styles . userId } >
85+ { member . userId }
86+ </ Text >
87+ ) }
8588 < Divider style = { { position : 'absolute' , bottom : 0 } } />
8689 </ Box >
8790 </ Pressable >
Original file line number Diff line number Diff line change @@ -25,6 +25,7 @@ const GroupChannelThreadSuggestedMentionList = ({
2525 bottomInset,
2626 onPressToMention,
2727 mentionedUsers,
28+ showUserId = true ,
2829} : GroupChannelThreadProps [ 'SuggestedMentionList' ] ) => {
2930 const { width : screenWidth , height : screenHeight } = useWindowDimensions ( ) ;
3031 const { channel } = useContext ( GroupChannelThreadContexts . Fragment ) ;
@@ -78,9 +79,11 @@ const GroupChannelThreadSuggestedMentionList = ({
7879 < Text body2 color = { colors . onBackground01 } numberOfLines = { 1 } style = { styles . userNickname } >
7980 { member . nickname || STRINGS . LABELS . USER_NO_NAME }
8081 </ Text >
81- < Text body3 color = { colors . onBackground03 } numberOfLines = { 1 } style = { styles . userId } >
82- { member . userId }
83- </ Text >
82+ { ! ! showUserId && (
83+ < Text body3 color = { colors . onBackground03 } numberOfLines = { 1 } style = { styles . userId } >
84+ { member . userId }
85+ </ Text >
86+ ) }
8487 < Divider style = { { position : 'absolute' , bottom : 0 } } />
8588 </ View >
8689 </ Pressable >
You can’t perform that action at this time.
0 commit comments