diff --git a/ui/editor/components/color-selector.tsx b/ui/editor/components/color-selector.tsx index 16d132032..60cafa68a 100644 --- a/ui/editor/components/color-selector.tsx +++ b/ui/editor/components/color-selector.tsx @@ -1,6 +1,7 @@ import { Editor } from "@tiptap/core"; import { Check, ChevronDown } from "lucide-react"; import { Dispatch, FC, SetStateAction } from "react"; +import * as Popover from "@radix-ui/react-popover"; export interface BubbleColorMenuItem { name: string; @@ -105,26 +106,29 @@ export const ColorSelector: FC = ({ ); return ( -
- + + - {isOpen && ( -
+
Color
{TEXT_COLORS.map(({ name, color }, index) => ( ))} -
- )} -
+ + + ); }; diff --git a/ui/editor/components/node-selector.tsx b/ui/editor/components/node-selector.tsx index d933f3611..d8a45ec90 100644 --- a/ui/editor/components/node-selector.tsx +++ b/ui/editor/components/node-selector.tsx @@ -11,8 +11,8 @@ import { Code, CheckSquare, } from "lucide-react"; +import * as Popover from "@radix-ui/react-popover"; import { Dispatch, FC, SetStateAction } from "react"; - import { BubbleMenuItem } from "./bubble-menu"; interface NodeSelectorProps { @@ -99,17 +99,20 @@ export const NodeSelector: FC = ({ }; return ( -
- + +
+ setIsOpen(!isOpen)} + > + {activeItem?.name} + + - {isOpen && ( -
+ {items.map((item, index) => ( ))} -
- )} -
+ +
+ ); };