diff --git a/packages/client/src/tiptap/core/wrappers/emoji-list/index.module.scss b/packages/client/src/tiptap/core/wrappers/emoji-list/index.module.scss index 53648ea1..88c3fd81 100644 --- a/packages/client/src/tiptap/core/wrappers/emoji-list/index.module.scss +++ b/packages/client/src/tiptap/core/wrappers/emoji-list/index.module.scss @@ -5,10 +5,6 @@ overflow-y: auto; border-radius: var(--border-radius); box-shadow: rgb(9 30 66 / 31%) 0 0 1px, rgb(9 30 66 / 25%) 0 4px 8px -2px; - - &::-webkit-scrollbar { - background-color: #fff !important; - } } .item { @@ -21,7 +17,6 @@ background-color: rgb(255 255 255); border: 0; border-radius: 0; - outline: none; flex: 0 0 auto; align-items: center; diff --git a/packages/client/src/tiptap/core/wrappers/emoji-list/index.tsx b/packages/client/src/tiptap/core/wrappers/emoji-list/index.tsx index ebd7a6d7..0b0d4e6f 100644 --- a/packages/client/src/tiptap/core/wrappers/emoji-list/index.tsx +++ b/packages/client/src/tiptap/core/wrappers/emoji-list/index.tsx @@ -36,7 +36,7 @@ export const EmojiList: React.FC = forwardRef((props, ref) => { useEffect(() => { if (Number.isNaN(selectedIndex + 1)) return; - const el = $container.current.querySelector(`button:nth-of-type(${selectedIndex + 1})`); + const el = $container.current.querySelector(`span:nth-of-type(${selectedIndex + 1})`); el && scrollIntoView(el, { behavior: 'smooth', scrollMode: 'if-needed' }); }, [selectedIndex]); diff --git a/packages/client/src/tiptap/core/wrappers/mention-list/index.module.scss b/packages/client/src/tiptap/core/wrappers/mention-list/index.module.scss index 806ea46a..31c57c16 100644 --- a/packages/client/src/tiptap/core/wrappers/mention-list/index.module.scss +++ b/packages/client/src/tiptap/core/wrappers/mention-list/index.module.scss @@ -1,9 +1,8 @@ .items { - width: 200px; - max-height: 380px; + width: 160px; + max-height: 320px; overflow-x: hidden; overflow-y: auto; - background-color: var(--semi-color-bg-0); border-radius: var(--border-radius); box-shadow: rgb(9 30 66 / 31%) 0 0 1px, rgb(9 30 66 / 25%) 0 4px 8px -2px; } @@ -18,11 +17,8 @@ background-color: rgb(255 255 255); border: 0; border-radius: 0; - outline: 0; flex: 0 0 auto; align-items: center; - box-sizing: border-box; - fill: rgb(255 255 255); &:hover { background-color: #f4f5f7; diff --git a/packages/client/src/tiptap/core/wrappers/mention-list/index.tsx b/packages/client/src/tiptap/core/wrappers/mention-list/index.tsx index 4dadbd79..cb59a226 100644 --- a/packages/client/src/tiptap/core/wrappers/mention-list/index.tsx +++ b/packages/client/src/tiptap/core/wrappers/mention-list/index.tsx @@ -36,7 +36,7 @@ export const MentionList: React.FC = forwardRef((props, ref) => { useEffect(() => { if (Number.isNaN(selectedIndex + 1)) return; - const el = $container.current.querySelector(`button:nth-of-type(${selectedIndex + 1})`); + const el = $container.current.querySelector(`span:nth-of-type(${selectedIndex + 1})`); el && scrollIntoView(el, { behavior: 'smooth', scrollMode: 'if-needed' }); }, [selectedIndex]); diff --git a/packages/client/src/tiptap/core/wrappers/menu-list/index.tsx b/packages/client/src/tiptap/core/wrappers/menu-list/index.tsx index 52a256f9..0332f416 100644 --- a/packages/client/src/tiptap/core/wrappers/menu-list/index.tsx +++ b/packages/client/src/tiptap/core/wrappers/menu-list/index.tsx @@ -42,7 +42,7 @@ export const MenuList: React.FC = forwardRef((props, ref) => { useEffect(() => { if (Number.isNaN(selectedIndex + 1)) return; - const el = $container.current.querySelector(`button:nth-of-type(${selectedIndex + 1})`); + const el = $container.current.querySelector(`span:nth-of-type(${selectedIndex + 1})`); el && scrollIntoView(el, { behavior: 'smooth', scrollMode: 'if-needed' }); }, [selectedIndex]);