mirror of https://github.com/buster-so/buster.git
Update BlockContextMenu.tsx
This commit is contained in:
parent
f00150c585
commit
63112231a7
|
@ -22,6 +22,7 @@ import {
|
||||||
ContextMenuTrigger
|
ContextMenuTrigger
|
||||||
} from '@/components/ui/context-menu';
|
} from '@/components/ui/context-menu';
|
||||||
import { useIsTouchDevice } from '@/hooks/useIsTouchDevice';
|
import { useIsTouchDevice } from '@/hooks/useIsTouchDevice';
|
||||||
|
import { DEFAULT_THEME_STYLE } from '../ThemeWrapper/themes';
|
||||||
|
|
||||||
type Value = 'askAI' | null;
|
type Value = 'askAI' | null;
|
||||||
|
|
||||||
|
@ -91,6 +92,7 @@ export function BlockContextMenu({ children }: { children: React.ReactNode }) {
|
||||||
</ContextMenuTrigger>
|
</ContextMenuTrigger>
|
||||||
<ContextMenuContent
|
<ContextMenuContent
|
||||||
className="w-64"
|
className="w-64"
|
||||||
|
style={DEFAULT_THEME_STYLE}
|
||||||
onCloseAutoFocus={(e) => {
|
onCloseAutoFocus={(e) => {
|
||||||
e.preventDefault();
|
e.preventDefault();
|
||||||
editor.getApi(BlockSelectionPlugin).blockSelection.focus();
|
editor.getApi(BlockSelectionPlugin).blockSelection.focus();
|
||||||
|
|
Loading…
Reference in New Issue