Skip to content

Commit

Permalink
Merge pull request #2279 from daostack/bugfix/CW-2245-chat-message-menu
Browse files Browse the repository at this point in the history
Messages action menu issues #2245
  • Loading branch information
pvm-code authored Oct 31, 2023
2 parents 1905140 + 00ed70f commit 3a612a9
Show file tree
Hide file tree
Showing 3 changed files with 16 additions and 6 deletions.
15 changes: 11 additions & 4 deletions src/shared/components/Chat/ChatMessage/ChatMessage.module.scss
Original file line number Diff line number Diff line change
Expand Up @@ -68,6 +68,17 @@
}
}

.elementDropdownMenu {
direction: ltr;
}

.menuArrowButton {
display: none;
}
.menuArrowButtonVisible {
display: block;
}

.messageTextWithReply {
padding: 0.25rem 0rem 0.5rem;
}
Expand Down Expand Up @@ -220,10 +231,6 @@
}
}

.menuArrowButton {
display: none;
}

.highlighted {
animation: highlighted 10s forwards;
border: 0.06rem solid $c-pink-active-feed-cards;
Expand Down
5 changes: 4 additions & 1 deletion src/shared/components/Chat/ChatMessage/ChatMessage.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -448,7 +448,10 @@ export default function ChatMessage({
isControlledDropdown={false}
isOpen={isMenuOpen}
styles={{
menuButton: styles.menuArrowButton,
menu: styles.elementDropdownMenu,
menuButton: classNames(styles.menuArrowButton, {
[styles.menuArrowButtonVisible]: isMenuOpen,
}),
}}
feedItemId={feedItemId}
onDelete={onMessageDelete}
Expand Down
2 changes: 1 addition & 1 deletion src/shared/components/ElementDropdown/ElementDropdown.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -340,7 +340,7 @@ const ElementDropdown: FC<ElementDropdownProps> = ({
menuButton: classNames(styles?.menuButton, {
"element-dropdown__menu-button--transparent": transparent,
}),
menu: "element-dropdown__menu",
menu: classNames("element-dropdown__menu", styles?.menu),
menuItem: "element-dropdown__menu-item",
}}
/>
Expand Down

0 comments on commit 3a612a9

Please sign in to comment.