Skip to content

Commit

Permalink
fix: add limit for emotion style to fix transparent panel
Browse files Browse the repository at this point in the history
  • Loading branch information
moonrailgun committed Nov 6, 2023
1 parent ed5ff61 commit 766477a
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 2 deletions.
Original file line number Diff line number Diff line change
@@ -1,8 +1,10 @@
import { Popover } from 'antd';
import clsx from 'clsx';
import React, { useState } from 'react';
import { Icon } from 'tailchat-design';

interface BaseChatInputButtonProps {
overlayClassName?: string;
icon: string;
popoverContent: (ctx: { hidePopover: () => void }) => React.ReactElement;
}
Expand All @@ -21,7 +23,10 @@ export const BaseChatInputButton: React.FC<BaseChatInputButtonProps> =
},
})
}
overlayClassName="chat-message-input_action-popover"
overlayClassName={clsx(
'chat-message-input_action-popover',
props.overlayClassName
)}
showArrow={false}
placement="topRight"
trigger={['click']}
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
.chat-message-input_action-popover {
.chat-message-input_action-popover.emotion-popover {
> .ant-popover-content > .ant-popover-inner {
background-color: transparent;
border-radius: 10px;
Expand Down
1 change: 1 addition & 0 deletions client/web/src/components/ChatBox/ChatInputBox/Emotion.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ export const ChatInputEmotion: React.FC = React.memo(() => {

return (
<BaseChatInputButton
overlayClassName="emotion-popover"
icon="mdi:emoticon-happy-outline"
popoverContent={({ hidePopover }) => (
<EmojiPanel
Expand Down

0 comments on commit 766477a

Please sign in to comment.