diff --git a/stylesheets/_modules.scss b/stylesheets/_modules.scss index 3a7e348fa..c37d708bd 100644 --- a/stylesheets/_modules.scss +++ b/stylesheets/_modules.scss @@ -20,11 +20,6 @@ .module-contact-name__profile-number.italic { font-style: italic; } - -.module-contact-name.compact { - display: block; -} - // Module: Message .module-message__error-container { diff --git a/ts/components/conversation/ContactName.tsx b/ts/components/conversation/ContactName.tsx index 5216371f3..d370980f2 100644 --- a/ts/components/conversation/ContactName.tsx +++ b/ts/components/conversation/ContactName.tsx @@ -13,12 +13,11 @@ type Props = { profileName?: string | null; module?: string; boldProfileName?: boolean; - compact?: boolean; shouldShowPubkey: boolean; }; export const ContactName = (props: Props) => { - const { pubkey, name, profileName, module, boldProfileName, compact, shouldShowPubkey } = props; + const { pubkey, name, profileName, module, boldProfileName, shouldShowPubkey } = props; const prefix = module || 'module-contact-name'; const convoName = useNicknameOrProfileNameOrShortenedPubkey(pubkey); @@ -43,7 +42,7 @@ export const ContactName = (props: Props) => { return ( { pubkey={PubKey.shorten(author)} name={authorName} profileName={authorProfileName} - compact={true} shouldShowPubkey={Boolean(props.showPubkeyForAuthor)} /> )} diff --git a/ts/components/conversation/message/message-content/quote/QuoteAuthor.tsx b/ts/components/conversation/message/message-content/quote/QuoteAuthor.tsx index 01763fa5a..e2b92b348 100644 --- a/ts/components/conversation/message/message-content/quote/QuoteAuthor.tsx +++ b/ts/components/conversation/message/message-content/quote/QuoteAuthor.tsx @@ -41,7 +41,6 @@ export const QuoteAuthor = (props: QuoteAuthorProps) => { diff --git a/ts/components/dialog/ReactListModal.tsx b/ts/components/dialog/ReactListModal.tsx index fbf943c32..f4a1fafd9 100644 --- a/ts/components/dialog/ReactListModal.tsx +++ b/ts/components/dialog/ReactListModal.tsx @@ -14,6 +14,7 @@ import { } from '../../state/ducks/modalDialog'; import { useSelectedIsPublic, + useSelectedWeAreAdmin, useSelectedWeAreModerator, } from '../../state/selectors/selectedConversation'; import { SortedReactionList } from '../../types/Reaction'; @@ -50,6 +51,11 @@ const StyledSendersContainer = styled(Flex)` padding: 0 16px 16px; `; +const StyledContactContainer = styled.span` + text-overflow: ellipsis; + overflow: hidden; +`; + const StyledReactionBar = styled(Flex)` width: 100%; margin: 12px 0 20px 4px; @@ -132,7 +138,7 @@ const ReactionSenders = (props: ReactionSendersProps) => { justifyContent={'space-between'} alignItems={'center'} > - + { {sender === me ? ( window.i18n('you') ) : ( - + + + )} {sender === me && ( @@ -231,6 +239,7 @@ export const ReactListModal = (props: Props) => { const msgProps = useMessageReactsPropsById(messageId); const isPublic = useSelectedIsPublic(); + const weAreAdmin = useSelectedWeAreAdmin(); const weAreModerator = useSelectedWeAreModerator(); const me = UserUtils.getOurPubKeyStrFromCache(); @@ -362,7 +371,7 @@ export const ReactListModal = (props: Props) => { )}

- {isPublic && weAreModerator && ( + {isPublic && (weAreAdmin || weAreModerator) && (