Hide unimplemented context menus (#299)

This commit is contained in:
Felicio Mununga 2022-07-19 12:51:52 +02:00 committed by GitHub
parent b57edc9921
commit e68ea9de5a
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 56 additions and 59 deletions

View File

@ -1,7 +1,7 @@
import React from 'react'
import { ChatMenu } from '../../../../components/chat-menu'
import { ContextMenuTrigger } from '../../../../system'
// import { ChatMenu } from '../../../../components/chat-menu'
// import { ContextMenuTrigger } from '../../../../system'
import { SidebarItem } from '../sidebar-item'
import type { SidebarItemProps } from '../sidebar-item'
@ -14,9 +14,9 @@ export const ChannelItem = (props: Props) => {
const { children, ...sidebarItemProps } = props
return (
<ContextMenuTrigger>
// <ContextMenuTrigger>
<SidebarItem {...sidebarItemProps}>#{children}</SidebarItem>
<ChatMenu type="context" />
</ContextMenuTrigger>
// <ChatMenu type="context" />
// </ContextMenuTrigger>
)
}

View File

@ -12,8 +12,8 @@ import {
Avatar,
Box,
Button,
ContextMenu,
ContextMenuTrigger,
// ContextMenu,
// ContextMenuTrigger,
// DropdownMenu,
// DropdownMenuTrigger,
// EmojiHash,
@ -171,7 +171,7 @@ export const ChatMessage = (props: Props) => {
return (
<>
<ContextMenuTrigger>
{/* <ContextMenuTrigger> */}
<Wrapper mention={mention} pinned={pinned} data-active={reacting}>
{responseTo && <MessageReply messageId={responseTo} />}
<Flex gap={2}>
@ -236,10 +236,7 @@ export const ChatMessage = (props: Props) => {
{renderMessage()}
<MessageReactions
reactions={reactions}
onClick={handleReaction}
/>
<MessageReactions reactions={reactions} onClick={handleReaction} />
</Box>
</Flex>
@ -256,11 +253,11 @@ export const ChatMessage = (props: Props) => {
reactions={reactions}
/>
</Wrapper>
<ContextMenu>
{/* <ContextMenu>
<ContextMenu.Item onSelect={handleReplyClick}>Reply</ContextMenu.Item>
{/* <ContextMenu.Item onSelect={handlePinClick}>Pin</ContextMenu.Item> */}
</ContextMenu>
</ContextMenuTrigger>
<ContextMenu.Item onSelect={handlePinClick}>Pin</ContextMenu.Item>
</ContextMenu> */}
{/* </ContextMenuTrigger> */}
</>
)
}