diff --git a/src/components/puck/blocks/rich-text.tsx b/src/components/puck/blocks/rich-text.tsx
index 0685409..9549179 100644
--- a/src/components/puck/blocks/rich-text.tsx
+++ b/src/components/puck/blocks/rich-text.tsx
@@ -1,4 +1,6 @@
+"use client";
import type { ComponentConfig, RichText } from "@puckeditor/core";
+import { RichTextMenu } from "@puckeditor/core";
import { cn } from "@/lib/utils";
import { defineProps, field, responsive } from "@/lib/puck/define-props";
import { resolveResponsive } from "@/lib/puck/responsive-tailwind";
@@ -27,7 +29,33 @@ type RichTextProps = {
const props = defineProps({
content: field.raw(
- { type: "richtext", contentEditable: true },
+ { type: "richtext",
+ contentEditable: true,
+ tiptap: {
+ selector: ({ editor }: { editor?: any }) => ({
+ isLink: editor?.isActive("link"),
+ }),
+ },
+ renderMenu: ({ children, editor, editorState }: { children?: any; editor?: any; editorState?: any }) => (
+
+ {children}
+
+
+
+
+ ),
+ },
"Lorem ipsum dolor sit amet, consectetur adipiscing elit. Sed do eiusmod tempor incididunt ut labore et dolore magna aliqua.",
),
textColor: field.select(textColor, { label: "Text color", default: "foreground" }),
@@ -44,6 +72,7 @@ export const RichTextComponent: ComponentConfig = {
return (