reactjs-tiptap-editor 1.0.24 → 1.0.26
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/{ActionMenuButton-HYlhmRvw.js → ActionMenuButton-B4KDkZ0z.js} +1 -1
- package/lib/{ActionMenuButton-B8NhVw5m.cjs → ActionMenuButton-C3Cfeza9.cjs} +1 -1
- package/lib/Attachment.cjs +1 -1
- package/lib/Attachment.js +25 -25
- package/lib/Blockquote.cjs +5 -5
- package/lib/Blockquote.js +1490 -53
- package/lib/Bold.cjs +1 -1
- package/lib/Bold.js +3 -3
- package/lib/BulletList.cjs +1 -1
- package/lib/BulletList.js +2 -2
- package/lib/Callout.cjs +1 -1
- package/lib/Callout.js +222 -8
- package/lib/Clear.cjs +1 -1
- package/lib/Clear.js +2 -2
- package/lib/Code.cjs +1 -1
- package/lib/Code.js +56 -39
- package/lib/CodeBlock.cjs +1 -1
- package/lib/CodeBlock.js +8 -4
- package/lib/CodeView.cjs +1 -1
- package/lib/CodeView.js +2 -2
- package/lib/Color.cjs +1 -1
- package/lib/Color.js +3 -3
- package/lib/Column.cjs +1 -1
- package/lib/Column.js +2 -2
- package/lib/{Drawer-Was4hxYH.cjs → Drawer-D7E9kTca.cjs} +1 -1
- package/lib/{Drawer-CaXVhxo4.js → Drawer-DA0FLHs9.js} +20 -20
- package/lib/Drawer.cjs +1 -1
- package/lib/Drawer.js +4 -4
- package/lib/Emoji.cjs +1 -1
- package/lib/Emoji.js +1644 -148
- package/lib/Excalidraw.cjs +1 -1
- package/lib/Excalidraw.js +10 -10
- package/lib/ExportPdf.cjs +1 -1
- package/lib/ExportPdf.js +2 -2
- package/lib/ExportWord.cjs +1 -1
- package/lib/ExportWord.js +2 -2
- package/lib/FontFamily.cjs +1 -1
- package/lib/FontFamily.js +5 -5
- package/lib/FontSize.cjs +1 -1
- package/lib/FontSize.js +5 -5
- package/lib/FormatPainter.cjs +1 -0
- package/lib/FormatPainter.js +133 -0
- package/lib/Heading.cjs +1 -1
- package/lib/Heading.js +15 -11
- package/lib/Highlight.cjs +1 -1
- package/lib/Highlight.js +38 -32
- package/lib/History.cjs +7 -1
- package/lib/History.js +519 -478
- package/lib/HorizontalRule.cjs +1 -1
- package/lib/HorizontalRule.js +2 -2
- package/lib/{Iframe-Bp986fj0.js → Iframe-DZ3r3QzK.js} +7 -7
- package/lib/{Iframe-BI0sq6pd.cjs → Iframe-OMVd0xa_.cjs} +1 -1
- package/lib/Iframe.cjs +1 -1
- package/lib/Iframe.js +3 -3
- package/lib/Image.cjs +1 -1
- package/lib/Image.js +6 -6
- package/lib/ImageGif.cjs +1 -1
- package/lib/ImageGif.js +35 -35
- package/lib/ImportWord.cjs +1 -1
- package/lib/ImportWord.js +15 -15
- package/lib/{Indent-FvM52kjA.cjs → Indent-QgCoonRk.cjs} +1 -1
- package/lib/{Indent-E6B8DkyN.js → Indent-kI4G-clX.js} +2 -2
- package/lib/Indent.cjs +1 -1
- package/lib/Indent.js +2 -2
- package/lib/Italic.cjs +1 -1
- package/lib/Italic.js +2 -2
- package/lib/{Katex-pzwyyiFJ.js → Katex-BPbXjcZQ.js} +6 -7
- package/lib/Katex-CUofhjB5.cjs +4 -0
- package/lib/Katex.cjs +1 -1
- package/lib/Katex.js +3 -3
- package/lib/LineHeight.cjs +1 -1
- package/lib/LineHeight.js +4 -4
- package/lib/Link.cjs +1 -1
- package/lib/Link.js +2 -2
- package/lib/{LinkEditBlock-OjN4F2rM.js → LinkEditBlock-BYWwH2_x.js} +59 -32
- package/lib/{LinkEditBlock-Cmkmp2fW.cjs → LinkEditBlock-Z7RRurvx.cjs} +2 -2
- package/lib/MarkdownPaste.cjs +1 -1
- package/lib/MarkdownPaste.js +1 -1
- package/lib/Mention.cjs +1 -1
- package/lib/Mention.js +9 -5
- package/lib/Mermaid.cjs +2 -2
- package/lib/Mermaid.js +61 -62
- package/lib/MoreMark.cjs +1 -1
- package/lib/MoreMark.js +5 -5
- package/lib/OrderedList.cjs +1 -1
- package/lib/OrderedList.js +2 -2
- package/lib/SearchAndReplace.cjs +1 -1
- package/lib/SearchAndReplace.js +14 -14
- package/lib/SlashCommand.cjs +1 -1
- package/lib/SlashCommand.js +7 -7
- package/lib/{SlashCommandNodeView-o323V8li.js → SlashCommandNodeView-C0l3Fb_3.js} +10 -10
- package/lib/{SlashCommandNodeView-DarAytvt.cjs → SlashCommandNodeView-DPPmYEjC.cjs} +1 -1
- package/lib/Strike.cjs +1 -1
- package/lib/Strike.js +2 -2
- package/lib/{Table-Clnz-i4l.cjs → Table-D5G3rfwb.cjs} +5 -5
- package/lib/{Table-CC9uNHPL.js → Table-DwseaFSD.js} +115 -97
- package/lib/Table.cjs +1 -1
- package/lib/Table.js +1 -1
- package/lib/TaskList.cjs +1 -1
- package/lib/TaskList.js +2 -2
- package/lib/TextAlign.cjs +1 -1
- package/lib/TextAlign.js +11 -11
- package/lib/TextDirection.cjs +1 -1
- package/lib/TextDirection.js +3 -3
- package/lib/TextUnderline.cjs +1 -1
- package/lib/TextUnderline.js +2 -2
- package/lib/{Twitter-BVnXL8we.js → Twitter-DP26Lkn8.js} +195 -195
- package/lib/Twitter-q4ZGZL0i.cjs +1 -0
- package/lib/Twitter.cjs +1 -1
- package/lib/Twitter.js +3 -3
- package/lib/Video.cjs +1 -1
- package/lib/Video.js +5 -5
- package/lib/bubble.cjs +6 -6
- package/lib/bubble.js +2783 -2137
- package/lib/{clsx-D6gYQn3o.cjs → clsx-DRbkQ4T7.cjs} +1 -1
- package/lib/{clsx-0OU6n9va.js → clsx-_bq4MQQ7.js} +14 -4
- package/lib/components/Bubble/RichTextBubbleCallout.d.ts +1 -1
- package/lib/components/Bubble/RichTextBubbleCodeBlock.d.ts +1 -1
- package/lib/components/Bubble/RichTextBubbleColumns.d.ts +1 -1
- package/lib/components/Bubble/RichTextBubbleDrawer.d.ts +1 -1
- package/lib/components/Bubble/RichTextBubbleExcalidraw.d.ts +1 -1
- package/lib/components/Bubble/RichTextBubbleIframe.d.ts +1 -1
- package/lib/components/Bubble/RichTextBubbleKatex.d.ts +2 -1
- package/lib/components/Bubble/RichTextBubbleLink.d.ts +1 -1
- package/lib/components/Bubble/RichTextBubbleMedia.d.ts +3 -3
- package/lib/components/Bubble/RichTextBubbleMenuDragHandle.d.ts +2 -1
- package/lib/components/Bubble/RichTextBubbleMermaid.d.ts +1 -1
- package/lib/components/Bubble/RichTextBubbleTable.d.ts +1 -1
- package/lib/components/Bubble/RichTextBubbleText.d.ts +1 -1
- package/lib/components/Bubble/RichTextBubbleTwitter.d.ts +1 -1
- package/lib/components/ColorPicker.d.ts +1 -1
- package/lib/components/ReactBus.d.ts +1 -1
- package/lib/components/RichTextProvider.d.ts +1 -1
- package/lib/components/SlashDialogTrigger/RenderDialogUploadImage.d.ts +1 -1
- package/lib/components/SlashDialogTrigger/RenderDialogUploadVideo.d.ts +1 -1
- package/lib/components/SlashDialogTrigger/SlashDialogTrigger.d.ts +2 -1
- package/lib/components/icons/Activity.d.ts +2 -1
- package/lib/components/icons/Animas.d.ts +2 -1
- package/lib/components/icons/AspectRatio.d.ts +1 -1
- package/lib/components/icons/Blockquote.d.ts +1 -1
- package/lib/components/icons/CodeView.d.ts +1 -1
- package/lib/components/icons/ColumnAddLeft.d.ts +1 -1
- package/lib/components/icons/ColumnAddRight.d.ts +1 -1
- package/lib/components/icons/DeleteColumn.d.ts +1 -1
- package/lib/components/icons/DeleteRow.d.ts +1 -1
- package/lib/components/icons/Direction.d.ts +1 -1
- package/lib/components/icons/Excalidraw.d.ts +1 -1
- package/lib/components/icons/ExportPdf.d.ts +1 -1
- package/lib/components/icons/ExportWord.d.ts +2 -1
- package/lib/components/icons/FileWordOutline.d.ts +1 -1
- package/lib/components/icons/Flag.d.ts +2 -1
- package/lib/components/icons/Food.d.ts +2 -1
- package/lib/components/icons/GIfIcon.d.ts +1 -1
- package/lib/components/icons/Html.d.ts +1 -1
- package/lib/components/icons/Icon.d.ts +1 -1
- package/lib/components/icons/IconColorFill.d.ts +1 -1
- package/lib/components/icons/IconHighlightFill.d.ts +1 -1
- package/lib/components/icons/ImportWord.d.ts +2 -1
- package/lib/components/icons/LeftToRight.d.ts +1 -1
- package/lib/components/icons/LineHeight.d.ts +1 -1
- package/lib/components/icons/MenuDown.d.ts +1 -1
- package/lib/components/icons/Mermaid.d.ts +1 -1
- package/lib/components/icons/NoFill.d.ts +1 -1
- package/lib/components/icons/Object.d.ts +2 -1
- package/lib/components/icons/RightToLeft.d.ts +1 -1
- package/lib/components/icons/SizeL.d.ts +1 -1
- package/lib/components/icons/SizeM.d.ts +1 -1
- package/lib/components/icons/SizeS.d.ts +1 -1
- package/lib/components/icons/Symbol.d.ts +2 -1
- package/lib/components/icons/Travel.d.ts +2 -1
- package/lib/components/icons/Twitter.d.ts +1 -1
- package/lib/components/ui/dialog.d.ts +2 -2
- package/lib/components/ui/dropdown-menu.d.ts +1 -1
- package/lib/components/ui/emoji-picker.d.ts +4 -4
- package/lib/components/ui/toaster.d.ts +1 -1
- package/lib/{dropdown-menu-BW2M6saA.js → dropdown-menu-BKSX4gvT.js} +1 -1
- package/lib/{dropdown-menu-BIGvxqiu.cjs → dropdown-menu-CURWpB9o.cjs} +1 -1
- package/lib/extensions/Attachment/components/NodeViewAttachment/FileIcon.d.ts +1 -1
- package/lib/extensions/Attachment/components/NodeViewAttachment/NodeViewAttachment.d.ts +1 -1
- package/lib/extensions/Attachment/components/RichTextAttachment.d.ts +1 -1
- package/lib/extensions/Blockquote/components/RichTextBlockquote.d.ts +1 -1
- package/lib/extensions/Bold/components/RichTextBold.d.ts +1 -1
- package/lib/extensions/BulletList/components/RichTextBulletList.d.ts +1 -1
- package/lib/extensions/Callout/components/NodeViewCallout/NodeViewCallout.d.ts +1 -1
- package/lib/extensions/Callout/components/RichTextCallout.d.ts +1 -1
- package/lib/extensions/Clear/components/RichTextClear.d.ts +1 -1
- package/lib/extensions/Code/components/RichTextCode.d.ts +1 -1
- package/lib/extensions/CodeBlock/components/RichTextCodeBlock.d.ts +2 -1
- package/lib/extensions/CodeView/components/RichTextCodeView.d.ts +1 -1
- package/lib/extensions/Color/components/RichTextColor.d.ts +1 -1
- package/lib/extensions/Column/components/RichTextColumn.d.ts +1 -1
- package/lib/extensions/Drawer/components/ControlDrawer/ControlDrawer.d.ts +2 -1
- package/lib/extensions/Drawer/components/ControlDrawer/icon.d.ts +27 -27
- package/lib/extensions/Drawer/components/EditDrawerBlock.d.ts +1 -1
- package/lib/extensions/Drawer/components/NodeViewDrawer/NodeViewDrawer.d.ts +2 -1
- package/lib/extensions/Drawer/components/RichTextDrawer.d.ts +1 -1
- package/lib/extensions/Emoji/components/RichTextEmoji.d.ts +2 -1
- package/lib/extensions/Excalidraw/components/NodeViewExcalidraw/NodeViewExcalidraw.d.ts +2 -1
- package/lib/extensions/Excalidraw/components/RichTextExcalidraw.d.ts +1 -1
- package/lib/extensions/ExportPdf/components/RichTextExportPdf.d.ts +1 -1
- package/lib/extensions/ExportWord/components/RichTextExportWord.d.ts +1 -1
- package/lib/extensions/FontFamily/components/RichTextFontFamily.d.ts +1 -1
- package/lib/extensions/FontSize/components/RichTextFontSize.d.ts +1 -1
- package/lib/extensions/FormatPainter/FormatPainter.d.ts +17 -0
- package/lib/extensions/FormatPainter/components/RichTextFormatPainter.d.ts +1 -0
- package/lib/extensions/FormatPainter/index.d.ts +1 -0
- package/lib/extensions/Heading/components/RichTextHeading.d.ts +1 -1
- package/lib/extensions/Highlight/components/RichTextHighlight.d.ts +2 -1
- package/lib/extensions/History/components/RichTextHistory.d.ts +3 -2
- package/lib/extensions/HorizontalRule/components/RichTextHorizontalRule.d.ts +1 -1
- package/lib/extensions/Iframe/components/IframeNodeView.d.ts +1 -1
- package/lib/extensions/Iframe/components/RichTextIframe.d.ts +1 -1
- package/lib/extensions/Image/components/ImageCropper.d.ts +2 -1
- package/lib/extensions/Image/components/ImageView.d.ts +2 -1
- package/lib/extensions/Image/components/RichTextImage.d.ts +1 -1
- package/lib/extensions/ImageGif/components/ImageGifView.d.ts +2 -1
- package/lib/extensions/ImageGif/components/RichTextImageGif.d.ts +2 -1
- package/lib/extensions/ImportWord/components/RichTextImportWord.d.ts +1 -1
- package/lib/extensions/Indent/components/RichTextIndent.d.ts +1 -1
- package/lib/extensions/Italic/components/RichTextItalic.d.ts +1 -1
- package/lib/extensions/Katex/components/KatexWrapper.d.ts +1 -1
- package/lib/extensions/Katex/components/RichTextKatex.d.ts +1 -1
- package/lib/extensions/LineHeight/components/RichTextLightHeight.d.ts +1 -1
- package/lib/extensions/Link/components/LinkEditBlock.d.ts +1 -1
- package/lib/extensions/Link/components/LinkViewBlock.d.ts +2 -1
- package/lib/extensions/Link/components/RichTextLink.d.ts +1 -1
- package/lib/extensions/Mermaid/components/NodeViewMermaid/NodeViewMermaid.d.ts +2 -1
- package/lib/extensions/Mermaid/components/RichTextMermaid.d.ts +1 -1
- package/lib/extensions/MoreMark/components/RichTextMoreMark.d.ts +1 -1
- package/lib/extensions/OrderedList/components/RichTextOrderedList.d.ts +1 -1
- package/lib/extensions/SearchAndReplace/components/RichTextSearchAndReplace.d.ts +1 -1
- package/lib/extensions/SlashCommand/components/SlashCommandList.d.ts +1 -1
- package/lib/extensions/Strike/components/RichTextStrike.d.ts +1 -1
- package/lib/extensions/Table/components/CreateTablePopover.d.ts +2 -1
- package/lib/extensions/Table/components/RichTextTable.d.ts +2 -1
- package/lib/extensions/TaskList/components/RichTextTaskList.d.ts +1 -1
- package/lib/extensions/TextAlign/components/RichTextAlign.d.ts +1 -1
- package/lib/extensions/TextDirection/components/RichTextTextDirection.d.ts +1 -1
- package/lib/extensions/TextUnderline/components/RichTextUnderline.d.ts +1 -1
- package/lib/extensions/Twitter/components/FormEditLinkTwitter.d.ts +1 -1
- package/lib/extensions/Twitter/components/NodeViewTweet.d.ts +1 -1
- package/lib/extensions/Twitter/components/RichTextTwitter.d.ts +1 -1
- package/lib/extensions/Video/components/RichTextVideo.d.ts +1 -1
- package/lib/index-BGfIcDCQ.cjs +26 -0
- package/lib/index-BaR0Brts.js +1115 -0
- package/lib/index-BgNKVyMW.cjs +2 -0
- package/lib/index-BpLw6ebr.cjs +1 -0
- package/lib/{index-BrsJsbds.js → index-C52cuQ_Y.js} +1503 -1352
- package/lib/index-CDw4Eszh.cjs +12 -0
- package/lib/{index-CUvjYuRp.cjs → index-CHVV5iY-.cjs} +1 -1
- package/lib/{index-zw-Kd38i.js → index-CJMI7Fjf.js} +1 -1
- package/lib/{index-D-Ouz0vF.js → index-DQy9iBzV.js} +1 -1
- package/lib/index-Dbm_Mans.js +1756 -0
- package/lib/{index-oj858lQO.js → index-DtyAGMbq.js} +208 -208
- package/lib/{index-BblvcbTH.js → index-Dx-Dh7KS.js} +1464 -1348
- package/lib/{index-BAb_UADw.cjs → index-SEMQrdk2.cjs} +1 -1
- package/lib/index-aujjnfSJ.cjs +1 -0
- package/lib/index.cjs +1 -1
- package/lib/index.js +12 -12
- package/lib/{jsx-runtime-CT7Pcg-t.js → jsx-runtime-DE8oVoME.js} +3 -1
- package/lib/locale-bundle.cjs +1 -1
- package/lib/locale-bundle.js +1 -1
- package/lib/locales/index.d.ts +1 -1
- package/lib/{popover-BIVHT1W9.js → popover-BB-ZDnqk.js} +1 -1
- package/lib/{popover-DoSfJsFS.cjs → popover-CrywEkBR.cjs} +1 -1
- package/lib/{renderNodeView-D--fDFov.cjs → renderNodeView-5h3-p80E.cjs} +1 -1
- package/lib/{renderNodeView-CfWJK4rG.js → renderNodeView-DoKZ4GYy.js} +2 -2
- package/lib/{separator-SRbPfmGa.cjs → separator-BGO9AZp4.cjs} +1 -1
- package/lib/{separator-b-qOPJmp.js → separator-DuuOJRQd.js} +21 -21
- package/lib/store/EditorEditableReactive.d.ts +1 -1
- package/lib/store/ThemeColorReactive.d.ts +1 -1
- package/lib/style.css +1 -1
- package/lib/types.d.ts +2 -2
- package/lib/{updatePosition-DGPtRfWN.cjs → updatePosition-B1oRJE1x.cjs} +1 -1
- package/lib/{updatePosition-BwzAsiY0.js → updatePosition-CFTYKYNJ.js} +2 -2
- package/package.json +79 -66
- package/lib/Callout-B-S2f0Qo.cjs +0 -1
- package/lib/Callout-CF7Y9yJ7.js +0 -340
- package/lib/Katex-DP6EjdKz.cjs +0 -4
- package/lib/Twitter-0kmrijjL.cjs +0 -1
- package/lib/index-BF3EVCB1.cjs +0 -2
- package/lib/index-Bcj8cyOO.cjs +0 -24
- package/lib/index-CGjT-a9h.js +0 -1377
- package/lib/index-CPTpXLfX.cjs +0 -11
- package/lib/index-CWw4s87s.cjs +0 -1
- package/lib/index-Cal5SPfB.js +0 -779
- package/lib/index-deubsx3z.cjs +0 -1
- package/lib/textarea-CpxXPky_.js +0 -20
- package/lib/textarea-DbGw9oCU.cjs +0 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";const n=require("./index-
|
|
1
|
+
"use strict";const n=require("./index-BGfIcDCQ.cjs");var p=20,i=(t,e=0)=>{const r=[];return!t.children.length||e>p||Array.from(t.children).forEach(o=>{o.tagName==="SPAN"?r.push(o):o.children.length&&r.push(...i(o,e+1))}),r},f=t=>{if(!t.children.length)return;const e=i(t);e&&e.forEach(r=>{var o,s;const l=r.getAttribute("style"),d=(s=(o=r.parentElement)==null?void 0:o.closest("span"))==null?void 0:s.getAttribute("style");r.setAttribute("style",`${d};${l}`)})},c=n.Mark.create({name:"textStyle",priority:101,addOptions(){return{HTMLAttributes:{},mergeNestedSpanStyles:!0}},parseHTML(){return[{tag:"span",consuming:!1,getAttrs:t=>t.hasAttribute("style")?(this.options.mergeNestedSpanStyles&&f(t),{}):!1}]},renderHTML({HTMLAttributes:t}){return["span",n.mergeAttributes(this.options.HTMLAttributes,t),0]},addCommands(){return{toggleTextStyle:t=>({commands:e})=>e.toggleMark(this.name,t),removeEmptyTextStyle:()=>({tr:t})=>{const{selection:e}=t;return t.doc.nodesBetween(e.from,e.to,(r,o)=>{if(r.isTextblock)return!0;r.marks.filter(s=>s.type===this.type).some(s=>Object.values(s.attrs).some(l=>!!l))||t.removeMark(o,o+r.nodeSize,this.type)}),!0}}}}),S=n.Extension.create({name:"backgroundColor",addOptions(){return{types:["textStyle"]}},addGlobalAttributes(){return[{types:this.options.types,attributes:{backgroundColor:{default:null,parseHTML:t=>{var e;const r=(e=n.getStyleProperty(t,"background-color"))!=null?e:t.style.backgroundColor;return r==null?void 0:r.replace(/['"]+/g,"")},renderHTML:t=>t.backgroundColor?{style:`background-color: ${t.backgroundColor}`}:{}}}}]},addCommands(){return{setBackgroundColor:t=>({chain:e})=>e().setMark("textStyle",{backgroundColor:t}).run(),unsetBackgroundColor:()=>({chain:t})=>t().setMark("textStyle",{backgroundColor:null}).removeEmptyTextStyle().run()}}}),a=n.Extension.create({name:"color",addOptions(){return{types:["textStyle"]}},addGlobalAttributes(){return[{types:this.options.types,attributes:{color:{default:null,parseHTML:t=>{var e;const r=(e=n.getStyleProperty(t,"color"))!=null?e:t.style.color;return r==null?void 0:r.replace(/['"]+/g,"")},renderHTML:t=>t.color?{style:`color: ${t.color}`}:{}}}}]},addCommands(){return{setColor:t=>({chain:e})=>e().setMark("textStyle",{color:t}).run(),unsetColor:()=>({chain:t})=>t().setMark("textStyle",{color:null}).removeEmptyTextStyle().run()}}}),u=n.Extension.create({name:"fontFamily",addOptions(){return{types:["textStyle"]}},addGlobalAttributes(){return[{types:this.options.types,attributes:{fontFamily:{default:null,parseHTML:t=>{var e;return(e=n.getStyleProperty(t,"font-family"))!=null?e:t.style.fontFamily},renderHTML:t=>t.fontFamily?{style:`font-family: ${t.fontFamily}`}:{}}}}]},addCommands(){return{setFontFamily:t=>({chain:e})=>e().setMark("textStyle",{fontFamily:t}).run(),unsetFontFamily:()=>({chain:t})=>t().setMark("textStyle",{fontFamily:null}).removeEmptyTextStyle().run()}}}),g=n.Extension.create({name:"fontSize",addOptions(){return{types:["textStyle"]}},addGlobalAttributes(){return[{types:this.options.types,attributes:{fontSize:{default:null,parseHTML:t=>{var e;return(e=n.getStyleProperty(t,"font-size"))!=null?e:t.style.fontSize},renderHTML:t=>t.fontSize?{style:`font-size: ${t.fontSize}`}:{}}}}]},addCommands(){return{setFontSize:t=>({chain:e})=>e().setMark("textStyle",{fontSize:t}).run(),unsetFontSize:()=>({chain:t})=>t().setMark("textStyle",{fontSize:null}).removeEmptyTextStyle().run()}}}),y=n.Extension.create({name:"lineHeight",addOptions(){return{types:["textStyle"]}},addGlobalAttributes(){return[{types:this.options.types,attributes:{lineHeight:{default:null,parseHTML:t=>{var e;return(e=n.getStyleProperty(t,"line-height"))!=null?e:t.style.lineHeight},renderHTML:t=>t.lineHeight?{style:`line-height: ${t.lineHeight}`}:{}}}}]},addCommands(){return{setLineHeight:t=>({chain:e})=>e().setMark("textStyle",{lineHeight:t}).run(),unsetLineHeight:()=>({chain:t})=>t().setMark("textStyle",{lineHeight:null}).removeEmptyTextStyle().run()}}});n.Extension.create({name:"textStyleKit",addExtensions(){const t=[];return this.options.backgroundColor!==!1&&t.push(S.configure(this.options.backgroundColor)),this.options.color!==!1&&t.push(a.configure(this.options.color)),this.options.fontFamily!==!1&&t.push(u.configure(this.options.fontFamily)),this.options.fontSize!==!1&&t.push(g.configure(this.options.fontSize)),this.options.lineHeight!==!1&&t.push(y.configure(this.options.lineHeight)),this.options.textStyle!==!1&&t.push(c.configure(this.options.textStyle)),t}});exports.Color=a;exports.FontFamily=u;exports.LineHeight=y;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";const i=require("react/jsx-runtime"),m=require("react"),ft=require("@radix-ui/react-slot"),Ge=require("./index-NsYff_Ni.cjs");require("./theme.cjs");const de=require("./clsx-DRbkQ4T7.cjs"),Qt=require("@radix-ui/react-tabs"),Jt=require("@radix-ui/react-select"),c=require("lucide-react"),er=require("@radix-ui/react-dialog"),ie=require("./index-BGfIcDCQ.cjs"),G=require("./index-BpLw6ebr.cjs"),tr=require("@radix-ui/react-toggle"),rr=require("@radix-ui/react-tooltip"),Ce=require("@radix-ui/react-icons"),ir=require("@radix-ui/react-label"),nr=require("@radix-ui/react-checkbox"),or=require("react-image-crop");function re(e){const t=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(e){for(const r in e)if(r!=="default"){const n=Object.getOwnPropertyDescriptor(e,r);Object.defineProperty(t,r,n.get?n:{enumerable:!0,get:()=>e[r]})}}return t.default=e,Object.freeze(t)}const P=re(m),ne=re(Qt),U=re(Jt),q=re(er),xt=re(tr),we=re(rr),gt=re(ir),Ue=re(nr),qe="-",sr=e=>{const t=lr(e),{conflictingClassGroups:r,conflictingClassGroupModifiers:n}=e;return{getClassGroupId:l=>{const a=l.split(qe);return a[0]===""&&a.length!==1&&a.shift(),pt(a,t)||ar(l)},getConflictingClassGroupIds:(l,a)=>{const d=r[l]||[];return a&&n[l]?[...d,...n[l]]:d}}},pt=(e,t)=>{var l;if(e.length===0)return t.classGroupId;const r=e[0],n=t.nextPart.get(r),o=n?pt(e.slice(1),n):void 0;if(o)return o;if(t.validators.length===0)return;const s=e.join(qe);return(l=t.validators.find(({validator:a})=>a(s)))==null?void 0:l.classGroupId},at=/^\[(.+)\]$/,ar=e=>{if(at.test(e)){const t=at.exec(e)[1],r=t==null?void 0:t.substring(0,t.indexOf(":"));if(r)return"arbitrary.."+r}},lr=e=>{const{theme:t,prefix:r}=e,n={nextPart:new Map,validators:[]};return dr(Object.entries(e.classGroups),r).forEach(([s,l])=>{Fe(l,n,s,t)}),n},Fe=(e,t,r,n)=>{e.forEach(o=>{if(typeof o=="string"){const s=o===""?t:lt(t,o);s.classGroupId=r;return}if(typeof o=="function"){if(cr(o)){Fe(o(n),t,r,n);return}t.validators.push({validator:o,classGroupId:r});return}Object.entries(o).forEach(([s,l])=>{Fe(l,lt(t,s),r,n)})})},lt=(e,t)=>{let r=e;return t.split(qe).forEach(n=>{r.nextPart.has(n)||r.nextPart.set(n,{nextPart:new Map,validators:[]}),r=r.nextPart.get(n)}),r},cr=e=>e.isThemeGetter,dr=(e,t)=>t?e.map(([r,n])=>{const o=n.map(s=>typeof s=="string"?t+s:typeof s=="object"?Object.fromEntries(Object.entries(s).map(([l,a])=>[t+l,a])):s);return[r,o]}):e,ur=e=>{if(e<1)return{get:()=>{},set:()=>{}};let t=0,r=new Map,n=new Map;const o=(s,l)=>{r.set(s,l),t++,t>e&&(t=0,n=r,r=new Map)};return{get(s){let l=r.get(s);if(l!==void 0)return l;if((l=n.get(s))!==void 0)return o(s,l),l},set(s,l){r.has(s)?r.set(s,l):o(s,l)}}},bt="!",hr=e=>{const{separator:t,experimentalParseClassName:r}=e,n=t.length===1,o=t[0],s=t.length,l=a=>{const d=[];let h=0,x=0,w;for(let p=0;p<a.length;p++){let C=a[p];if(h===0){if(C===o&&(n||a.slice(p,p+s)===t)){d.push(a.slice(x,p)),x=p+s;continue}if(C==="/"){w=p;continue}}C==="["?h++:C==="]"&&h--}const u=d.length===0?a:a.substring(x),j=u.startsWith(bt),g=j?u.substring(1):u,k=w&&w>x?w-x:void 0;return{modifiers:d,hasImportantModifier:j,baseClassName:g,maybePostfixModifierPosition:k}};return r?a=>r({className:a,parseClassName:l}):l},mr=e=>{if(e.length<=1)return e;const t=[];let r=[];return e.forEach(n=>{n[0]==="["?(t.push(...r.sort(),n),r=[]):r.push(n)}),t.push(...r.sort()),t},fr=e=>({cache:ur(e.cacheSize),parseClassName:hr(e),...sr(e)}),xr=/\s+/,gr=(e,t)=>{const{parseClassName:r,getClassGroupId:n,getConflictingClassGroupIds:o}=t,s=[],l=e.trim().split(xr);let a="";for(let d=l.length-1;d>=0;d-=1){const h=l[d],{modifiers:x,hasImportantModifier:w,baseClassName:u,maybePostfixModifierPosition:j}=r(h);let g=!!j,k=n(g?u.substring(0,j):u);if(!k){if(!g){a=h+(a.length>0?" "+a:a);continue}if(k=n(u),!k){a=h+(a.length>0?" "+a:a);continue}g=!1}const p=mr(x).join(":"),C=w?p+bt:p,v=C+k;if(s.includes(v))continue;s.push(v);const L=o(k,g);for(let b=0;b<L.length;++b){const z=L[b];s.push(C+z)}a=h+(a.length>0?" "+a:a)}return a};function pr(){let e=0,t,r,n="";for(;e<arguments.length;)(t=arguments[e++])&&(r=vt(t))&&(n&&(n+=" "),n+=r);return n}const vt=e=>{if(typeof e=="string")return e;let t,r="";for(let n=0;n<e.length;n++)e[n]&&(t=vt(e[n]))&&(r&&(r+=" "),r+=t);return r};function br(e,...t){let r,n,o,s=l;function l(d){const h=t.reduce((x,w)=>w(x),e());return r=fr(h),n=r.cache.get,o=r.cache.set,s=a,a(d)}function a(d){const h=n(d);if(h)return h;const x=gr(d,r);return o(d,x),x}return function(){return s(pr.apply(null,arguments))}}const D=e=>{const t=r=>r[e]||[];return t.isThemeGetter=!0,t},wt=/^\[(?:([a-z-]+):)?(.+)\]$/i,vr=/^\d+\/\d+$/,wr=new Set(["px","full","screen"]),yr=/^(\d+(\.\d+)?)?(xs|sm|md|lg|xl)$/,jr=/\d+(%|px|r?em|[sdl]?v([hwib]|min|max)|pt|pc|in|cm|mm|cap|ch|ex|r?lh|cq(w|h|i|b|min|max))|\b(calc|min|max|clamp)\(.+\)|^0$/,Cr=/^(rgba?|hsla?|hwb|(ok)?(lab|lch)|color-mix)\(.+\)$/,Sr=/^(inset_)?-?((\d+)?\.?(\d+)[a-z]+|0)_-?((\d+)?\.?(\d+)[a-z]+|0)/,kr=/^(url|image|image-set|cross-fade|element|(repeating-)?(linear|radial|conic)-gradient)\(.+\)$/,Y=e=>le(e)||wr.has(e)||vr.test(e),J=e=>he(e,"length",Er),le=e=>!!e&&!Number.isNaN(Number(e)),Ve=e=>he(e,"number",le),fe=e=>!!e&&Number.isInteger(Number(e)),Tr=e=>e.endsWith("%")&&le(e.slice(0,-1)),T=e=>wt.test(e),ee=e=>yr.test(e),Mr=new Set(["length","size","percentage"]),Ir=e=>he(e,Mr,yt),Nr=e=>he(e,"position",yt),zr=new Set(["image","url"]),Lr=e=>he(e,zr,Vr),Ar=e=>he(e,"",Rr),xe=()=>!0,he=(e,t,r)=>{const n=wt.exec(e);return n?n[1]?typeof t=="string"?n[1]===t:t.has(n[1]):r(n[2]):!1},Er=e=>jr.test(e)&&!Cr.test(e),yt=()=>!1,Rr=e=>Sr.test(e),Vr=e=>kr.test(e),Dr=()=>{const e=D("colors"),t=D("spacing"),r=D("blur"),n=D("brightness"),o=D("borderColor"),s=D("borderRadius"),l=D("borderSpacing"),a=D("borderWidth"),d=D("contrast"),h=D("grayscale"),x=D("hueRotate"),w=D("invert"),u=D("gap"),j=D("gradientColorStops"),g=D("gradientColorStopPositions"),k=D("inset"),p=D("margin"),C=D("opacity"),v=D("padding"),L=D("saturate"),b=D("scale"),z=D("sepia"),y=D("skew"),B=D("space"),I=D("translate"),H=()=>["auto","contain","none"],A=()=>["auto","hidden","clip","visible","scroll"],F=()=>["auto",T,t],f=()=>[T,t],V=()=>["",Y,J],E=()=>["auto",le,T],S=()=>["bottom","center","left","left-bottom","left-top","right","right-bottom","right-top","top"],N=()=>["solid","dashed","dotted","double","none"],M=()=>["normal","multiply","screen","overlay","darken","lighten","color-dodge","color-burn","hard-light","soft-light","difference","exclusion","hue","saturation","color","luminosity"],O=()=>["start","end","center","between","around","evenly","stretch"],_=()=>["","0",T],$=()=>["auto","avoid","all","avoid-page","page","left","right","column"],X=()=>[le,T];return{cacheSize:500,separator:":",theme:{colors:[xe],spacing:[Y,J],blur:["none","",ee,T],brightness:X(),borderColor:[e],borderRadius:["none","","full",ee,T],borderSpacing:f(),borderWidth:V(),contrast:X(),grayscale:_(),hueRotate:X(),invert:_(),gap:f(),gradientColorStops:[e],gradientColorStopPositions:[Tr,J],inset:F(),margin:F(),opacity:X(),padding:f(),saturate:X(),scale:X(),sepia:_(),skew:X(),space:f(),translate:f()},classGroups:{aspect:[{aspect:["auto","square","video",T]}],container:["container"],columns:[{columns:[ee]}],"break-after":[{"break-after":$()}],"break-before":[{"break-before":$()}],"break-inside":[{"break-inside":["auto","avoid","avoid-page","avoid-column"]}],"box-decoration":[{"box-decoration":["slice","clone"]}],box:[{box:["border","content"]}],display:["block","inline-block","inline","flex","inline-flex","table","inline-table","table-caption","table-cell","table-column","table-column-group","table-footer-group","table-header-group","table-row-group","table-row","flow-root","grid","inline-grid","contents","list-item","hidden"],float:[{float:["right","left","none","start","end"]}],clear:[{clear:["left","right","both","none","start","end"]}],isolation:["isolate","isolation-auto"],"object-fit":[{object:["contain","cover","fill","none","scale-down"]}],"object-position":[{object:[...S(),T]}],overflow:[{overflow:A()}],"overflow-x":[{"overflow-x":A()}],"overflow-y":[{"overflow-y":A()}],overscroll:[{overscroll:H()}],"overscroll-x":[{"overscroll-x":H()}],"overscroll-y":[{"overscroll-y":H()}],position:["static","fixed","absolute","relative","sticky"],inset:[{inset:[k]}],"inset-x":[{"inset-x":[k]}],"inset-y":[{"inset-y":[k]}],start:[{start:[k]}],end:[{end:[k]}],top:[{top:[k]}],right:[{right:[k]}],bottom:[{bottom:[k]}],left:[{left:[k]}],visibility:["visible","invisible","collapse"],z:[{z:["auto",fe,T]}],basis:[{basis:F()}],"flex-direction":[{flex:["row","row-reverse","col","col-reverse"]}],"flex-wrap":[{flex:["wrap","wrap-reverse","nowrap"]}],flex:[{flex:["1","auto","initial","none",T]}],grow:[{grow:_()}],shrink:[{shrink:_()}],order:[{order:["first","last","none",fe,T]}],"grid-cols":[{"grid-cols":[xe]}],"col-start-end":[{col:["auto",{span:["full",fe,T]},T]}],"col-start":[{"col-start":E()}],"col-end":[{"col-end":E()}],"grid-rows":[{"grid-rows":[xe]}],"row-start-end":[{row:["auto",{span:[fe,T]},T]}],"row-start":[{"row-start":E()}],"row-end":[{"row-end":E()}],"grid-flow":[{"grid-flow":["row","col","dense","row-dense","col-dense"]}],"auto-cols":[{"auto-cols":["auto","min","max","fr",T]}],"auto-rows":[{"auto-rows":["auto","min","max","fr",T]}],gap:[{gap:[u]}],"gap-x":[{"gap-x":[u]}],"gap-y":[{"gap-y":[u]}],"justify-content":[{justify:["normal",...O()]}],"justify-items":[{"justify-items":["start","end","center","stretch"]}],"justify-self":[{"justify-self":["auto","start","end","center","stretch"]}],"align-content":[{content:["normal",...O(),"baseline"]}],"align-items":[{items:["start","end","center","baseline","stretch"]}],"align-self":[{self:["auto","start","end","center","stretch","baseline"]}],"place-content":[{"place-content":[...O(),"baseline"]}],"place-items":[{"place-items":["start","end","center","baseline","stretch"]}],"place-self":[{"place-self":["auto","start","end","center","stretch"]}],p:[{p:[v]}],px:[{px:[v]}],py:[{py:[v]}],ps:[{ps:[v]}],pe:[{pe:[v]}],pt:[{pt:[v]}],pr:[{pr:[v]}],pb:[{pb:[v]}],pl:[{pl:[v]}],m:[{m:[p]}],mx:[{mx:[p]}],my:[{my:[p]}],ms:[{ms:[p]}],me:[{me:[p]}],mt:[{mt:[p]}],mr:[{mr:[p]}],mb:[{mb:[p]}],ml:[{ml:[p]}],"space-x":[{"space-x":[B]}],"space-x-reverse":["space-x-reverse"],"space-y":[{"space-y":[B]}],"space-y-reverse":["space-y-reverse"],w:[{w:["auto","min","max","fit","svw","lvw","dvw",T,t]}],"min-w":[{"min-w":[T,t,"min","max","fit"]}],"max-w":[{"max-w":[T,t,"none","full","min","max","fit","prose",{screen:[ee]},ee]}],h:[{h:[T,t,"auto","min","max","fit","svh","lvh","dvh"]}],"min-h":[{"min-h":[T,t,"min","max","fit","svh","lvh","dvh"]}],"max-h":[{"max-h":[T,t,"min","max","fit","svh","lvh","dvh"]}],size:[{size:[T,t,"auto","min","max","fit"]}],"font-size":[{text:["base",ee,J]}],"font-smoothing":["antialiased","subpixel-antialiased"],"font-style":["italic","not-italic"],"font-weight":[{font:["thin","extralight","light","normal","medium","semibold","bold","extrabold","black",Ve]}],"font-family":[{font:[xe]}],"fvn-normal":["normal-nums"],"fvn-ordinal":["ordinal"],"fvn-slashed-zero":["slashed-zero"],"fvn-figure":["lining-nums","oldstyle-nums"],"fvn-spacing":["proportional-nums","tabular-nums"],"fvn-fraction":["diagonal-fractions","stacked-fractions"],tracking:[{tracking:["tighter","tight","normal","wide","wider","widest",T]}],"line-clamp":[{"line-clamp":["none",le,Ve]}],leading:[{leading:["none","tight","snug","normal","relaxed","loose",Y,T]}],"list-image":[{"list-image":["none",T]}],"list-style-type":[{list:["none","disc","decimal",T]}],"list-style-position":[{list:["inside","outside"]}],"placeholder-color":[{placeholder:[e]}],"placeholder-opacity":[{"placeholder-opacity":[C]}],"text-alignment":[{text:["left","center","right","justify","start","end"]}],"text-color":[{text:[e]}],"text-opacity":[{"text-opacity":[C]}],"text-decoration":["underline","overline","line-through","no-underline"],"text-decoration-style":[{decoration:[...N(),"wavy"]}],"text-decoration-thickness":[{decoration:["auto","from-font",Y,J]}],"underline-offset":[{"underline-offset":["auto",Y,T]}],"text-decoration-color":[{decoration:[e]}],"text-transform":["uppercase","lowercase","capitalize","normal-case"],"text-overflow":["truncate","text-ellipsis","text-clip"],"text-wrap":[{text:["wrap","nowrap","balance","pretty"]}],indent:[{indent:f()}],"vertical-align":[{align:["baseline","top","middle","bottom","text-top","text-bottom","sub","super",T]}],whitespace:[{whitespace:["normal","nowrap","pre","pre-line","pre-wrap","break-spaces"]}],break:[{break:["normal","words","all","keep"]}],hyphens:[{hyphens:["none","manual","auto"]}],content:[{content:["none",T]}],"bg-attachment":[{bg:["fixed","local","scroll"]}],"bg-clip":[{"bg-clip":["border","padding","content","text"]}],"bg-opacity":[{"bg-opacity":[C]}],"bg-origin":[{"bg-origin":["border","padding","content"]}],"bg-position":[{bg:[...S(),Nr]}],"bg-repeat":[{bg:["no-repeat",{repeat:["","x","y","round","space"]}]}],"bg-size":[{bg:["auto","cover","contain",Ir]}],"bg-image":[{bg:["none",{"gradient-to":["t","tr","r","br","b","bl","l","tl"]},Lr]}],"bg-color":[{bg:[e]}],"gradient-from-pos":[{from:[g]}],"gradient-via-pos":[{via:[g]}],"gradient-to-pos":[{to:[g]}],"gradient-from":[{from:[j]}],"gradient-via":[{via:[j]}],"gradient-to":[{to:[j]}],rounded:[{rounded:[s]}],"rounded-s":[{"rounded-s":[s]}],"rounded-e":[{"rounded-e":[s]}],"rounded-t":[{"rounded-t":[s]}],"rounded-r":[{"rounded-r":[s]}],"rounded-b":[{"rounded-b":[s]}],"rounded-l":[{"rounded-l":[s]}],"rounded-ss":[{"rounded-ss":[s]}],"rounded-se":[{"rounded-se":[s]}],"rounded-ee":[{"rounded-ee":[s]}],"rounded-es":[{"rounded-es":[s]}],"rounded-tl":[{"rounded-tl":[s]}],"rounded-tr":[{"rounded-tr":[s]}],"rounded-br":[{"rounded-br":[s]}],"rounded-bl":[{"rounded-bl":[s]}],"border-w":[{border:[a]}],"border-w-x":[{"border-x":[a]}],"border-w-y":[{"border-y":[a]}],"border-w-s":[{"border-s":[a]}],"border-w-e":[{"border-e":[a]}],"border-w-t":[{"border-t":[a]}],"border-w-r":[{"border-r":[a]}],"border-w-b":[{"border-b":[a]}],"border-w-l":[{"border-l":[a]}],"border-opacity":[{"border-opacity":[C]}],"border-style":[{border:[...N(),"hidden"]}],"divide-x":[{"divide-x":[a]}],"divide-x-reverse":["divide-x-reverse"],"divide-y":[{"divide-y":[a]}],"divide-y-reverse":["divide-y-reverse"],"divide-opacity":[{"divide-opacity":[C]}],"divide-style":[{divide:N()}],"border-color":[{border:[o]}],"border-color-x":[{"border-x":[o]}],"border-color-y":[{"border-y":[o]}],"border-color-s":[{"border-s":[o]}],"border-color-e":[{"border-e":[o]}],"border-color-t":[{"border-t":[o]}],"border-color-r":[{"border-r":[o]}],"border-color-b":[{"border-b":[o]}],"border-color-l":[{"border-l":[o]}],"divide-color":[{divide:[o]}],"outline-style":[{outline:["",...N()]}],"outline-offset":[{"outline-offset":[Y,T]}],"outline-w":[{outline:[Y,J]}],"outline-color":[{outline:[e]}],"ring-w":[{ring:V()}],"ring-w-inset":["ring-inset"],"ring-color":[{ring:[e]}],"ring-opacity":[{"ring-opacity":[C]}],"ring-offset-w":[{"ring-offset":[Y,J]}],"ring-offset-color":[{"ring-offset":[e]}],shadow:[{shadow:["","inner","none",ee,Ar]}],"shadow-color":[{shadow:[xe]}],opacity:[{opacity:[C]}],"mix-blend":[{"mix-blend":[...M(),"plus-lighter","plus-darker"]}],"bg-blend":[{"bg-blend":M()}],filter:[{filter:["","none"]}],blur:[{blur:[r]}],brightness:[{brightness:[n]}],contrast:[{contrast:[d]}],"drop-shadow":[{"drop-shadow":["","none",ee,T]}],grayscale:[{grayscale:[h]}],"hue-rotate":[{"hue-rotate":[x]}],invert:[{invert:[w]}],saturate:[{saturate:[L]}],sepia:[{sepia:[z]}],"backdrop-filter":[{"backdrop-filter":["","none"]}],"backdrop-blur":[{"backdrop-blur":[r]}],"backdrop-brightness":[{"backdrop-brightness":[n]}],"backdrop-contrast":[{"backdrop-contrast":[d]}],"backdrop-grayscale":[{"backdrop-grayscale":[h]}],"backdrop-hue-rotate":[{"backdrop-hue-rotate":[x]}],"backdrop-invert":[{"backdrop-invert":[w]}],"backdrop-opacity":[{"backdrop-opacity":[C]}],"backdrop-saturate":[{"backdrop-saturate":[L]}],"backdrop-sepia":[{"backdrop-sepia":[z]}],"border-collapse":[{border:["collapse","separate"]}],"border-spacing":[{"border-spacing":[l]}],"border-spacing-x":[{"border-spacing-x":[l]}],"border-spacing-y":[{"border-spacing-y":[l]}],"table-layout":[{table:["auto","fixed"]}],caption:[{caption:["top","bottom"]}],transition:[{transition:["none","all","","colors","opacity","shadow","transform",T]}],duration:[{duration:X()}],ease:[{ease:["linear","in","out","in-out",T]}],delay:[{delay:X()}],animate:[{animate:["none","spin","ping","pulse","bounce",T]}],transform:[{transform:["","gpu","none"]}],scale:[{scale:[b]}],"scale-x":[{"scale-x":[b]}],"scale-y":[{"scale-y":[b]}],rotate:[{rotate:[fe,T]}],"translate-x":[{"translate-x":[I]}],"translate-y":[{"translate-y":[I]}],"skew-x":[{"skew-x":[y]}],"skew-y":[{"skew-y":[y]}],"transform-origin":[{origin:["center","top","top-right","right","bottom-right","bottom","bottom-left","left","top-left",T]}],accent:[{accent:["auto",e]}],appearance:[{appearance:["none","auto"]}],cursor:[{cursor:["auto","default","pointer","wait","text","move","help","not-allowed","none","context-menu","progress","cell","crosshair","vertical-text","alias","copy","no-drop","grab","grabbing","all-scroll","col-resize","row-resize","n-resize","e-resize","s-resize","w-resize","ne-resize","nw-resize","se-resize","sw-resize","ew-resize","ns-resize","nesw-resize","nwse-resize","zoom-in","zoom-out",T]}],"caret-color":[{caret:[e]}],"pointer-events":[{"pointer-events":["none","auto"]}],resize:[{resize:["none","y","x",""]}],"scroll-behavior":[{scroll:["auto","smooth"]}],"scroll-m":[{"scroll-m":f()}],"scroll-mx":[{"scroll-mx":f()}],"scroll-my":[{"scroll-my":f()}],"scroll-ms":[{"scroll-ms":f()}],"scroll-me":[{"scroll-me":f()}],"scroll-mt":[{"scroll-mt":f()}],"scroll-mr":[{"scroll-mr":f()}],"scroll-mb":[{"scroll-mb":f()}],"scroll-ml":[{"scroll-ml":f()}],"scroll-p":[{"scroll-p":f()}],"scroll-px":[{"scroll-px":f()}],"scroll-py":[{"scroll-py":f()}],"scroll-ps":[{"scroll-ps":f()}],"scroll-pe":[{"scroll-pe":f()}],"scroll-pt":[{"scroll-pt":f()}],"scroll-pr":[{"scroll-pr":f()}],"scroll-pb":[{"scroll-pb":f()}],"scroll-pl":[{"scroll-pl":f()}],"snap-align":[{snap:["start","end","center","align-none"]}],"snap-stop":[{snap:["normal","always"]}],"snap-type":[{snap:["none","x","y","both"]}],"snap-strictness":[{snap:["mandatory","proximity"]}],touch:[{touch:["auto","none","manipulation"]}],"touch-x":[{"touch-pan":["x","left","right"]}],"touch-y":[{"touch-pan":["y","up","down"]}],"touch-pz":["touch-pinch-zoom"],select:[{select:["none","text","all","auto"]}],"will-change":[{"will-change":["auto","scroll","contents","transform",T]}],fill:[{fill:[e,"none"]}],"stroke-w":[{stroke:[Y,J,Ve]}],stroke:[{stroke:[e,"none"]}],sr:["sr-only","not-sr-only"],"forced-color-adjust":[{"forced-color-adjust":["auto","none"]}]},conflictingClassGroups:{overflow:["overflow-x","overflow-y"],overscroll:["overscroll-x","overscroll-y"],inset:["inset-x","inset-y","start","end","top","right","bottom","left"],"inset-x":["right","left"],"inset-y":["top","bottom"],flex:["basis","grow","shrink"],gap:["gap-x","gap-y"],p:["px","py","ps","pe","pt","pr","pb","pl"],px:["pr","pl"],py:["pt","pb"],m:["mx","my","ms","me","mt","mr","mb","ml"],mx:["mr","ml"],my:["mt","mb"],size:["w","h"],"font-size":["leading"],"fvn-normal":["fvn-ordinal","fvn-slashed-zero","fvn-figure","fvn-spacing","fvn-fraction"],"fvn-ordinal":["fvn-normal"],"fvn-slashed-zero":["fvn-normal"],"fvn-figure":["fvn-normal"],"fvn-spacing":["fvn-normal"],"fvn-fraction":["fvn-normal"],"line-clamp":["display","overflow"],rounded:["rounded-s","rounded-e","rounded-t","rounded-r","rounded-b","rounded-l","rounded-ss","rounded-se","rounded-ee","rounded-es","rounded-tl","rounded-tr","rounded-br","rounded-bl"],"rounded-s":["rounded-ss","rounded-es"],"rounded-e":["rounded-se","rounded-ee"],"rounded-t":["rounded-tl","rounded-tr"],"rounded-r":["rounded-tr","rounded-br"],"rounded-b":["rounded-br","rounded-bl"],"rounded-l":["rounded-tl","rounded-bl"],"border-spacing":["border-spacing-x","border-spacing-y"],"border-w":["border-w-s","border-w-e","border-w-t","border-w-r","border-w-b","border-w-l"],"border-w-x":["border-w-r","border-w-l"],"border-w-y":["border-w-t","border-w-b"],"border-color":["border-color-s","border-color-e","border-color-t","border-color-r","border-color-b","border-color-l"],"border-color-x":["border-color-r","border-color-l"],"border-color-y":["border-color-t","border-color-b"],"scroll-m":["scroll-mx","scroll-my","scroll-ms","scroll-me","scroll-mt","scroll-mr","scroll-mb","scroll-ml"],"scroll-mx":["scroll-mr","scroll-ml"],"scroll-my":["scroll-mt","scroll-mb"],"scroll-p":["scroll-px","scroll-py","scroll-ps","scroll-pe","scroll-pt","scroll-pr","scroll-pb","scroll-pl"],"scroll-px":["scroll-pr","scroll-pl"],"scroll-py":["scroll-pt","scroll-pb"],touch:["touch-x","touch-y","touch-pz"],"touch-x":["touch"],"touch-y":["touch"],"touch-pz":["touch"]},conflictingClassGroupModifiers:{"font-size":["leading"]}}},Pr=br(Dr);function R(...e){return Pr(de.clsx(e))}let De;function Pe(){return De===void 0&&(De=navigator.platform.includes("Mac")),De}function jt(e){return`${e}`.toLowerCase()==="mod"?Pe()?"⌘":"Ctrl":`${e}`.toLowerCase()==="alt"?Pe()?"⌥":"Alt":`${e}`.toLowerCase()==="shift"?Pe()?"⇧":"Shift":e}function Ct(e){return e.map(jt).join(" ")}const Xe=m.forwardRef((e,t)=>{const{icon:r=void 0,tooltip:n=void 0,disabled:o=!1,customClass:s="",loading:l=void 0,shortcutKeys:a=void 0,tooltipOptions:d={},action:h=void 0,isActive:x=void 0,children:w,asChild:u=!1,upload:j=!1,initialDisplayedColor:g=void 0,dataState:k=!1,...p}=e,C=Ye[r],v=u?ft.Slot:Ke,L=b=>{if(o){b.preventDefault();return}h==null||h(b)};return i.jsxs(It,{children:[i.jsx(Nt,{asChild:!0,children:i.jsxs(v,{className:R("richtext-h-[32px] richtext-w-[32px]",s),"data-state":k?"on":"off",disabled:o,onClick:L,ref:t,size:"sm",...p,children:[C&&i.jsx(C,{className:"richtext-size-4"}),w]})}),n&&i.jsx(Qe,{...d,className:"richtext-tooltip",children:i.jsxs("div",{className:"richtext-flex richtext-max-w-24 richtext-flex-col richtext-items-center richtext-text-center",children:[i.jsx("div",{children:n}),!!(a!=null&&a.length)&&i.jsx("span",{children:Ct(a)})]})})]})});function Hr(e){return i.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",width:"1em",height:"1em",viewBox:"0 0 24 24",...e,children:i.jsx("path",{fill:"currentColor",d:"M19 12h-2v3h-3v2h5zM7 9h3V7H5v5h2zm14-6H3a2 2 0 0 0-2 2v14a2 2 0 0 0 2 2h18a2 2 0 0 0 2-2V5a2 2 0 0 0-2-2m0 16H3V5h18z"})})}function _r(e){return i.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",width:"1em",height:"1em",viewBox:"0 0 24 24",...e,children:i.jsx("path",{fill:"none",stroke:"currentColor",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"2",d:"M6 15h15m0 4H6m9-8h6m0-4h-6M9 9h1a1 1 0 1 1-1 1V7.5a2 2 0 0 1 2-2M3 9h1a1 1 0 1 1-1 1V7.5a2 2 0 0 1 2-2"})})}function Or(){return i.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",xmlnsXlink:"http://www.w3.org/1999/xlink","aria-hidden":"true",role:"img",className:"richtext-h-4 richtext-w-4",width:"1em",height:"1em",viewBox:"0 0 24 24",children:i.jsx("path",{fill:"none",stroke:"currentColor",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"1.5",d:"M5.5 3c1.404 0 2.107 0 2.611.38c.219.164.406.375.552.62C9 4.568 9 5.358 9 6.938v10.125c0 1.58 0 2.37-.337 2.937a2.1 2.1 0 0 1-.552.621c-.504.38-1.207.38-2.611.38s-2.107 0-2.611-.38a2.1 2.1 0 0 1-.552-.62C2 19.432 2 18.642 2 17.062V6.938c0-1.58 0-2.37.337-2.938a2.1 2.1 0 0 1 .552-.62C3.393 3 4.096 3 5.5 3M20 11.938v5.124c0 1.58 0 2.37-.337 2.938a2.1 2.1 0 0 1-.552.62c-.504.38-1.207.38-2.611.38s-2.107 0-2.611-.38a2.1 2.1 0 0 1-.552-.62C13 19.433 13 18.642 13 17.063V6.938c0-1.58 0-2.37.337-2.938M22 9l-6-6m6 0l-6 6",color:"currentColor"})})}function Br(){return i.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",xmlnsXlink:"http://www.w3.org/1999/xlink","aria-hidden":"true",role:"img",className:"richtext-h-4 richtext-w-4",width:"1em",height:"1em",viewBox:"0 0 24 24",children:i.jsx("path",{fill:"none",stroke:"currentColor",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"1.5",d:"M21 18.5c0 1.404 0 2.107-.38 2.611a2.1 2.1 0 0 1-.62.552c-.567.337-1.358.337-2.937.337H6.938c-1.58 0-2.37 0-2.938-.337a2.1 2.1 0 0 1-.62-.552C3 20.607 3 19.904 3 18.5s0-2.107.38-2.611c.163-.218.374-.406.62-.552C4.567 15 5.357 15 6.938 15h10.125c1.58 0 2.37 0 2.937.337c.246.146.457.334.62.552c.38.504.38 1.207.38 2.611M12.063 4H6.937C5.358 4 4.568 4 4 4.337a2.1 2.1 0 0 0-.62.552C3 5.393 3 6.096 3 7.5s0 2.107.38 2.611c.163.218.374.406.62.552C4.567 11 5.357 11 6.938 11h10.125c1.58 0 2.37 0 2.937-.337M21 8l-6-6m6 0l-6 6",color:"currentColor"})})}function Ur(e){return i.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",width:"1em",height:"1em",viewBox:"0 0 24 24",...e,children:i.jsx("path",{fill:"currentColor",d:"M14 2H6a2 2 0 0 0-2 2v16c0 1.11.89 2 2 2h12c1.11 0 2-.89 2-2V8zm4 18H6V4h7v5h5zm-.65-10l-2.1 9h-1.4l-1.8-6.79l-1.8 6.79h-1.4l-2.2-9h1.5l1.4 6.81l1.8-6.81h1.3l1.8 6.81l1.4-6.81z"})})}function ce(e){const t=Ye[e.name];return t?i.jsx(t,{onClick:e==null?void 0:e.onClick,className:`richtext-h-4 richtext-w-4 ${(e==null?void 0:e.className)||""}`}):null}function Fr(e){return i.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",width:"1em",height:"1em",viewBox:"0 0 24 24",...e,children:i.jsx("path",{fill:"currentColor",d:"M21 22H3v-2h18zm0-18H3V2h18zm-11 9.7h4l-2-5.4zM11.2 6h1.7l4.7 12h-2l-.9-2.6H9.4L8.5 18h-2z"})})}function St(e){return i.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",xmlnsXlink:"http://www.w3.org/1999/xlink","aria-hidden":"true",role:"img",width:"1em",height:"1em",viewBox:"0 0 48 48",...e,children:i.jsx("path",{fill:"currentColor",stroke:"currentColor",strokeLinejoin:"round",strokeWidth:4,d:"M36 19L24 31L12 19z"})})}function $r(e){return i.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",width:"1em",height:"1em",viewBox:"0 0 24 24",...e,children:i.jsx("path",{fill:"currentColor",d:"M9 7v10h6v-2h-4V7z"})})}function Wr(e){return i.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",width:"1em",height:"1em",viewBox:"0 0 24 24",...e,children:i.jsx("path",{fill:"currentColor",d:"M9 7c-1.1 0-2 .9-2 2v8h2V9h2v7h2V9h2v8h2V9a2 2 0 0 0-2-2z"})})}function Gr(e){return i.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",width:"1em",height:"1em",viewBox:"0 0 24 24",...e,children:i.jsx("path",{fill:"currentColor",d:"M11 7c-1.1 0-2 .9-2 2v2a2 2 0 0 0 2 2h2v2H9v2h4c1.11 0 2-.89 2-2v-2a2 2 0 0 0-2-2h-2V9h4V7z"})})}function qr(){return i.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",width:"1em",height:"1em",viewBox:"0 0 24 24",children:i.jsx("path",{fill:"currentColor",d:"M9.4 16.6L4.8 12l4.6-4.6L8 6l-6 6 6 6l1.4-1.4zm5.2 0l4.6-4.6-4.6-4.6L16 6l6 6-6 6l-1.4-1.4z"})})}function Xr(){return i.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",width:"1em",height:"1em",viewBox:"0 0 24 24",children:i.jsx("path",{fill:"none",stroke:"currentColor",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"2",d:"M14 4h4a1 1 0 0 1 1 1v14a1 1 0 0 1-1 1h-4a1 1 0 0 1-1-1V5a1 1 0 0 1 1-1m-9 8h4m-2-2v4"})})}function Yr(){return i.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",width:"1em",height:"1em",viewBox:"0 0 24 24",children:i.jsx("path",{fill:"none",stroke:"currentColor",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"2",d:"M6 4h4a1 1 0 0 1 1 1v14a1 1 0 0 1-1 1H6a1 1 0 0 1-1-1V5a1 1 0 0 1 1-1m9 8h4m-2-2v4"})})}function Zr(){return i.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",width:"1em",height:"1em",viewBox:"0 0 24 24",children:i.jsx("path",{fill:"none",stroke:"currentColor",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"2",d:"M12 21v-4m0-4V9m0-4V3m-2 18h4M8 5v4h11l2-2l-2-2zm6 8v4H6l-2-2l2-2z"})})}function Kr(){return i.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",width:"1em",height:"1em",viewBox:"0 0 24 24",children:i.jsx("path",{fill:"currentColor",d:"M23.943 19.806a.2.2 0 0 0-.168-.034c-1.26-1.855-2.873-3.61-4.419-5.315l-.252-.284c-.001-.073-.067-.12-.134-.15l-.084-.084c-.05-.1-.169-.167-.286-.1c-.47.234-.907.585-1.327.919c-.554.434-1.109.87-1.63 1.354a5 5 0 0 0-.588.618c-.084.117-.017.217.084.267c-.37.368-.74.736-1.109 1.12a.2.2 0 0 0-.05.134c0 .05.033.1.067.117l.655.502v.016c.924.92 2.554 2.173 4.285 3.527c.251.201.52.402.773.602c.117.134.234.285.335.418c.05.066.169.084.236.033c.033.034.084.067.118.1a.24.24 0 0 0 .1.034a.15.15 0 0 0 .135-.066a.24.24 0 0 0 .033-.1c.017 0 .017.016.034.016a.2.2 0 0 0 .134-.05l3.058-3.327c.12-.116.014-.267 0-.267m-7.628-.134l-1.546-1.17l-.15-.1c-.035-.017-.068-.05-.102-.067l-.117-.1c.66-.66 1.33-1.308 2-1.956c-.488.484-1.463 1.906-1.261 2.373c.002 0 .018.042.067.084zm4.1 3.126l-1.277-.97a27 27 0 0 0-1.58-1.504c.69.518 1.277.97 1.361 1.053c.673.585.638.485 1.093.87l.554.4c-.074.103-.151.148-.151.151m.336.25l-.034-.016a1 1 0 0 0 .152-.117zM.588 3.476c.033.217.084.435.117.636c.201 1.103.403 2.106.772 2.858l.152.568c.05.217.134.485.219.552a67 67 0 0 0 3.578 2.942a.18.18 0 0 0 .219 0s0 .016.016.016a.15.15 0 0 0 .118.05a.2.2 0 0 0 .134-.05c1.798-1.989 3.142-3.627 4.1-4.998c.068-.066.084-.167.084-.25c.067-.067.118-.151.185-.201c.067-.067.067-.184 0-.235l-.017-.016c0-.033-.017-.084-.05-.1c-.42-.401-.722-.685-1.042-.986a94 94 0 0 1-2.352-2.273c-.017-.017-.034-.034-.067-.034c-.336-.117-1.025-.234-1.882-.385c-1.277-.216-3.008-.517-4.57-.986c0 0-.101 0-.118.017l-.05.05C.05.714.022.707 0 .718c.017.1.017.167.05.284c0 .033.068.301.068.334zm7.19 4.78l-.033.034a.036.036 0 0 1 .033-.034M6.553 2.238c.101.1.521.502.622.585c-.437-.2-1.529-.702-2.034-.869c.505.1 1.194.201 1.412.284M.79 1.403c.252.434.454 1.939.655 3.41c-.118-.469-.201-.936-.302-1.372C.992 2.673.84 1.988.638 1.386c.124 0 .152.021.152.017m-.286-.369c0-.016 0-.033-.017-.033c.085 0 .135.017.202.05c0 .006-.145-.017-.185-.017m23.17-.217c.017-.066-.336-.367-.219-.384c.253-.017.253-.401 0-.401c-.335.017-.688.1-1.008.15c-.587.117-1.192.234-1.78.367a80 80 0 0 0-3.949.937c-.403.117-.857.2-1.243.401c-.135.067-.118.2-.05.284c-.034.017-.051.017-.085.034c-.117.017-.218.034-.335.05c-.102.017-.152.1-.135.2c0 .017.017.05.017.067c-.706.936-1.496 1.923-2.353 2.976c-.84.969-1.73 1.989-2.62 3.042c-2.84 3.31-6.05 7.07-9.594 10.38a.16.16 0 0 0 0 .234c.016.016.033.033.05.033c-.05.05-.101.085-.152.134q-.05.05-.05.1a.4.4 0 0 0-.067.084c-.067.067-.067.184.017.234c.067.066.185.066.235-.017c.017-.017.017-.033.033-.033a.265.265 0 0 1 .37 0c.202.217.404.435.588.618l-.42-.35c-.067-.067-.184-.05-.234.016c-.068.066-.051.184.016.234l4.469 3.727c.034.034.067.034.118.034a.15.15 0 0 0 .117-.05l.101-.1c.017.016.05.016.067.016c.05 0 .084-.016.118-.05c6.049-6.05 10.922-10.614 16.5-14.693c.05-.033.067-.1.067-.15c.067 0 .118-.05.15-.117c1.026-3.125 1.228-5.9 1.295-7.27c0-.059.016-.038.016-.068c.017-.033.017-.05.017-.05a.98.98 0 0 0-.067-.619m-10.82 4.915c.268-.301.537-.619.806-.903c-1.73 2.273-4.603 5.767-8.67 9.929c2.773-3.059 5.562-6.218 7.864-9.026M5.14 23.466c-.016-.017-.016-.017 0-.017zm2.504-2.156c.135-.15.27-.284.42-.434c0 0 0 .016.017.016c-.224.198-.433.418-.437.418m.69-.668c.099-.1.14-.173.284-.318c.992-1.02 2.017-2.04 3.059-3.076l.016-.016c.252-.2.555-.418.824-.619a228 228 0 0 0-4.184 4.029M14.852 3.91c-.554.719-1.176 1.671-1.697 2.423c-1.646 2.374-6.94 8.174-7.057 8.274a1190 1190 0 0 1-4.839 4.597l-.1.1c-.085-.1-.085-.25.016-.334C8.652 11.966 13.19 6.133 15.021 3.576c-.05.116-.084.216-.168.334zm2.906 3.427c-.671-.386-.99-.987-.806-1.572l.05-.2a.8.8 0 0 1 .085-.167a1.9 1.9 0 0 1 .756-.703c.016 0 .033 0 .05-.016c-.017-.034-.017-.084-.017-.134c.017-.1.085-.167.202-.167c.202 0 .824.184 1.059.384c.067.05.134.117.202.184c.084.1.218.268.285.401c.034.017.067.184.118.268c.033.134.067.284.05.418c-.017.016 0 .116-.017.116a1.6 1.6 0 0 1-.218.619c-.03.03.006.012-.05.067a1.2 1.2 0 0 1-.32.334a1.49 1.49 0 0 1-1.26.234a2 2 0 0 0-.169-.066m4.37 1.403c0 .017-.017.05 0 .067c-.034 0-.05.017-.085.034a110 110 0 0 0-3.915 3.025c1.11-.986 2.218-1.989 3.378-2.975c.336-.301.571-.686.638-1.12l.168-1.003v-.033c.085-.201.404-.118.353.1c-.004-.001-.173.795-.537 1.905"})})}function kt(){return i.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"1em",height:"1em",viewBox:"0 0 32 32",children:[i.jsx("path",{fill:"currentColor",d:"M30 18v-2h-6v10h2v-4h3v-2h-3v-2zm-11 8h-4V16h4a3.003 3.003 0 0 1 3 3v4a3.003 3.003 0 0 1-3 3m-2-2h2a1 1 0 0 0 1-1v-4a1 1 0 0 0-1-1h-2zm-6-8H6v10h2v-3h3a2.003 2.003 0 0 0 2-2v-3a2 2 0 0 0-2-2m-3 5v-3h3l.001 3z"}),i.jsx("path",{fill:"currentColor",d:"M22 14v-4a.91.91 0 0 0-.3-.7l-7-7A.9.9 0 0 0 14 2H4a2.006 2.006 0 0 0-2 2v24a2 2 0 0 0 2 2h16v-2H4V4h8v6a2.006 2.006 0 0 0 2 2h6v2Zm-8-4V4.4l5.6 5.6Z"})]})}function Tt(){return i.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"1em",height:"1em",className:"icon",viewBox:"0 0 1024 1024",children:[i.jsx("path",{fill:"currentColor",d:"M679.253 402.364 618.77 561.015l-60.348-158.651a30.04 30.04 0 0 0-30.447-18.637 29.76 29.76 0 0 0-30.447 18.637l-60.416 158.651-60.416-158.651a30.515 30.515 0 0 0-38.843-17.272 28.945 28.945 0 0 0-17.954 37.547l88.815 233.267c4.369 11.469 15.7 19.115 28.398 19.115a30.31 30.31 0 0 0 28.468-19.115l62.395-163.908 62.396 163.84c4.437 11.605 15.701 19.183 28.4 19.183a30.31 30.31 0 0 0 28.466-19.115l88.747-233.267a28.945 28.945 0 0 0-17.886-37.547 30.447 30.447 0 0 0-38.912 17.272zm219.478 395.605-51.883-29.218c-28.672-16.18-52.224-3.072-52.224 29.082v.273H643.209a29.833 29.833 0 0 0-30.31 29.354c0 16.18 13.584 29.218 30.31 29.218h151.825c1.092 30.516 24.03 43.077 52.224 27.648l51.063-27.989c29.013-15.906 29.15-42.189.41-58.368"}),i.jsx("path",{fill:"currentColor",d:"m810.667 913.135-.478.068H201.796c-19.865 0-36.727-11.673-36.727-25.6v-618.36h154.965c51.268 0 92.911-39.39 92.911-87.858v-87.86H810.19c19.797 0 36.522 11.742 36.522 25.669V739.26h61.987V119.262c0-46.421-44.169-84.241-98.51-84.241H328.364l-225.28 194.56v658.09c0 46.285 44.236 84.105 98.713 84.105H810.19c43.759 0 80.554-24.713 93.32-58.573h-92.842zM350.89 94.89v86.562c0 16.11-13.858 29.286-30.925 29.286H216.815L350.959 94.891z"})]})}function Qr(){return i.jsx("svg",{height:"1em",viewBox:"0 0 15 15",width:"1em",xmlns:"http://www.w3.org/2000/svg",children:i.jsx("path",{d:"M2.5 10.5H2v.5h.5zm2 0v.5H5v-.5zm9-7h.5v-.207l-.146-.147zm-3-3l.354-.354L10.707 0H10.5zM2 6v4.5h1V6zm.5 5h2v-1h-2zm2.5-.5v-2H4v2zM3 7h2V6H3zM2 5V1.5H1V5zm11-1.5V5h1V3.5zM2.5 1h8V0h-8zm7.646-.146l3 3l.708-.708l-3-3zM2 1.5a.5.5 0 0 1 .5-.5V0A1.5 1.5 0 0 0 1 1.5zM1 12v1.5h1V12zm1.5 3h10v-1h-10zM14 13.5V12h-1v1.5zM12.5 15a1.5 1.5 0 0 0 1.5-1.5h-1a.5.5 0 0 1-.5.5zM1 13.5A1.5 1.5 0 0 0 2.5 15v-1a.5.5 0 0 1-.5-.5zM6 7h3V6H6zm0 4h3v-1H6zm1-4.5v4h1v-4zm3.5.5H13V6h-2.5zM10 6v5h1V6zm.5 3H12V8h-1.5z",fill:"currentColor"})})}function Jr(){return i.jsx("svg",{height:"1em",viewBox:"0 0 24 24",width:"1em",xmlns:"http://www.w3.org/2000/svg",children:i.jsxs("g",{fill:"none",stroke:"currentColor",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"2",children:[i.jsx("path",{d:"M14 3v4a1 1 0 0 0 1 1h4"}),i.jsx("path",{d:"M5 12V5a2 2 0 0 1 2-2h7l5 5v4M2 21v-6m3 0v6m-3-3h3m15-3v6h2m-9 0v-6l2 3l2-3v6m-9.5-6h3M9 15v6"})]})})}function ei(){return i.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",width:"1em",height:"1em",viewBox:"0 0 20 20",children:i.jsx("path",{fill:"currentColor",d:"M6.5 3a.75.75 0 0 1 .697.471l3 7.5a.75.75 0 0 1-1.393.557L7.992 9.5H5.008l-.811 2.028a.75.75 0 0 1-1.393-.556l3-7.5A.75.75 0 0 1 6.5 3m0 2.77L5.608 8h1.784zm8.28-1.55a.75.75 0 1 0-1.06 1.06l.72.72h-3.69a.75.75 0 0 0 0 1.5h3.69l-.72.72a.75.75 0 0 0 1.06 1.06l2-2a.75.75 0 0 0 0-1.06zm0 7.5a.75.75 0 1 0-1.06 1.06l.72.72H3.75a.75.75 0 0 0 0 1.5h10.69l-.72.72a.75.75 0 1 0 1.06 1.06l2-2a.75.75 0 0 0 0-1.06z"})})}function ti(){return i.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",width:"1em",height:"1em",viewBox:"0 0 48 48",children:i.jsxs("g",{fill:"none",stroke:"currentColor",strokeWidth:"4",children:[i.jsx("circle",{cx:"10",cy:"24",r:"4"}),i.jsx("circle",{cx:"38",cy:"10",r:"4"}),i.jsx("circle",{cx:"38",cy:"24",r:"4"}),i.jsx("circle",{cx:"38",cy:"38",r:"4"}),i.jsx("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M34 38H22V10h12M14 24h20"})]})})}function ri(){return i.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",width:"1em",height:"1em",viewBox:"0 0 20 20",children:i.jsx("path",{fill:"currentColor",d:"M13.5 3a.75.75 0 0 0-.697.471l-3 7.5a.75.75 0 0 0 1.393.557l.812-2.028h2.984l.811 2.028a.75.75 0 0 0 1.393-.556l-3-7.5A.75.75 0 0 0 13.5 3m0 2.77L14.392 8h-1.784zM5.22 4.22a.75.75 0 0 1 1.06 1.06L5.56 6h3.69a.75.75 0 0 1 0 1.5H5.56l.72.72a.75.75 0 0 1-1.06 1.06l-2-2a.75.75 0 0 1 0-1.06zm0 7.5a.75.75 0 0 1 1.06 1.06l-.72.72h10.69a.75.75 0 0 1 0 1.5H5.56l.72.72a.75.75 0 1 1-1.06 1.06l-2-2a.75.75 0 0 1 0-1.06z"})})}function ii(){return i.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",width:"1em",height:"1em",viewBox:"0 0 24 24",children:i.jsx("path",{fill:"none",stroke:"currentColor",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:"1.5",d:"m3 21l7.548-7.548M21 3l-7.548 7.548m0 0L8 3H3l7.548 10.452m2.904-2.904L21 21h-5l-5.452-7.548",color:"currentColor"})})}function ni(){return i.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",xmlnsXlink:"http://www.w3.org/1999/xlink","aria-hidden":"true",role:"img",width:"1em",height:"1em",viewBox:"0 0 24 24",children:i.jsx("path",{fill:"currentColor",d:"M14 2H6a2 2 0 0 0-2 2v16c0 1.11.89 2 2 2h12c1.11 0 2-.89 2-2V8zm4 18H6V4h7v5h5zm-.65-10l-2.1 9h-1.4l-1.8-6.79l-1.8 6.79h-1.4l-2.2-9h1.5l1.4 6.81l1.8-6.81h1.3l1.8 6.81l1.4-6.81z"})})}const Ye={Bold:c.Bold,LoaderCircle:c.LoaderCircle,Italic:c.Italic,Underline:c.Underline,Quote:c.Quote,TextQuote:_r,Strikethrough:c.Strikethrough,Minus:c.Minus,Eraser:c.Eraser,PaintRoller:c.PaintRoller,Redo2:c.Redo2,Undo2:c.Undo2,AlignCenter:Ce.TextAlignCenterIcon,AlignJustify:Ce.TextAlignJustifyIcon,AlignLeft:Ce.TextAlignLeftIcon,AlignRight:Ce.TextAlignRightIcon,ChevronDown:c.ChevronDown,Subscript:c.Subscript,Superscript:c.Superscript,Code:c.Code,Code2:c.CodeXml,Type:c.Type,IndentIncrease:c.IndentIncrease,IndentDecrease:c.IndentDecrease,List:c.List,ListOrdered:c.ListOrdered,ListTodo:c.ListTodo,Link:c.Link,ImageUp:c.ImageUp,Video:c.Video,Maximize:c.Maximize,Minimize:c.Minimize,Table:c.Table,Sparkles:c.Sparkles,Pencil:c.Pencil,Unlink:c.Unlink,BetweenHorizonalEnd:c.BetweenHorizonalEnd,BetweenHorizonalStart:c.BetweenHorizonalStart,BetweenVerticalStart:c.BetweenVerticalStart,BetweenVerticalEnd:c.BetweenVerticalEnd,TableCellsMerge:c.TableCellsMerge,TableCellsSplit:c.TableCellsSplit,Trash2:c.Trash2,Trash:c.Trash,Replace:c.Replace,ChevronsUpDown:c.ChevronsUpDown,LineHeight:Fr,Word:Ur,HeadingParagraph:c.Pilcrow,Heading1:c.Heading1,Heading2:c.Heading2,Heading3:c.Heading3,Heading4:c.Heading4,Heading5:c.Heading5,Heading6:c.Heading6,Columns2:c.Columns2,Columns3:c.Columns3,Columns4:c.Columns4,Plus:c.Plus,Grip:c.GripVertical,Copy:c.Copy,Clipboard:c.Clipboard,PanelLeft:c.PanelLeft,PanelRight:c.PanelRight,Columns:c.Columns2,Iframe:c.Frame,MenuDown:St,SizeS:Gr,SizeM:Wr,SizeL:$r,AspectRatio:Hr,Emoji:c.SmilePlus,DeleteColumn:Or,DeleteRow:Br,SearchAndReplace:c.Replace,EmojiIcon:c.SmilePlusIcon,KatexIcon:c.Sigma,ExportPdf:kt,ExportWord:Tt,ImportWord:ni,ColumnAddLeft:Xr,ColumnAddRight:Yr,BookMarked:c.BookMarked,Excalidraw:Kr,ZoomIn:c.ZoomIn,ZoomOut:c.ZoomOut,Settings:c.Settings,Eye:c.Eye,TextDirection:Zr,LeftToRight:ei,RightToLeft:ri,Attachment:c.Paperclip,GifIcon:Qr,ChevronUp:c.ChevronUp,Crop:c.CropIcon,Mermaid:ti,Twitter:ii,CodeView:qr,FlipX:c.FlipVertical,FlipY:c.FlipHorizontal,PencilRuler:c.PencilRuler,WrapText:c.WrapText,Loader:c.Loader2,X:c.X,Html:Jr,ExternalLink:c.ExternalLink,Callout:c.NotebookPen},ct=e=>typeof e=="boolean"?`${e}`:e===0?"0":e,dt=de.clsx,Ze=(e,t)=>r=>{var n;if((t==null?void 0:t.variants)==null)return dt(e,r==null?void 0:r.class,r==null?void 0:r.className);const{variants:o,defaultVariants:s}=t,l=Object.keys(o).map(h=>{const x=r==null?void 0:r[h],w=s==null?void 0:s[h];if(x===null)return null;const u=ct(x)||ct(w);return o[h][u]}),a=r&&Object.entries(r).reduce((h,x)=>{let[w,u]=x;return u===void 0||(h[w]=u),h},{}),d=t==null||(n=t.compoundVariants)===null||n===void 0?void 0:n.reduce((h,x)=>{let{class:w,className:u,...j}=x;return Object.entries(j).every(g=>{let[k,p]=g;return Array.isArray(p)?p.includes({...s,...a}[k]):{...s,...a}[k]===p})?[...h,w,u]:h},[]);return dt(e,l,d,r==null?void 0:r.class,r==null?void 0:r.className)},oi=Ze("richtext-inline-flex richtext-items-center richtext-justify-center richtext-whitespace-nowrap richtext-rounded-md richtext-text-sm richtext-font-medium richtext-ring-offset-background richtext-transition-colors focus-visible:richtext-outline-none focus-visible:richtext-ring-2 focus-visible:richtext-ring-ring focus-visible:richtext-ring-offset-1 disabled:richtext-pointer-events-none disabled:richtext-opacity-50",{variants:{variant:{default:"!richtext-bg-primary !richtext-text-primary-foreground hover:!richtext-bg-primary/90",destructive:"richtext-bg-destructive richtext-text-destructive-foreground hover:richtext-bg-destructive/90",outline:"richtext-border richtext-border-input richtext-bg-background richtext-text-foreground hover:richtext-bg-accent hover:richtext-text-accent-foreground",secondary:"richtext-bg-secondary richtext-text-secondary-foreground hover:richtext-bg-secondary/80",ghost:"hover:richtext-bg-accent hover:richtext-text-accent-foreground",link:"richtext-text-primary richtext-underline-offset-4 hover:richtext-underline"},size:{default:"richtext-h-10 richtext-px-4 richtext-py-2",sm:"richtext-h-9 richtext-rounded-md richtext-px-3",lg:"richtext-h-11 richtext-rounded-md richtext-px-8",icon:"richtext-size-10"}},defaultVariants:{variant:"default",size:"default"}}),W=P.forwardRef(({className:e,variant:t,size:r,asChild:n=!1,...o},s)=>{const l=n?ft.Slot:"button";return i.jsx(l,{className:R(oi({variant:t,size:r,className:e})),ref:s,...o})});W.displayName="Button";const te=P.forwardRef(({className:e,type:t,...r},n)=>i.jsx("input",{ref:n,type:t,className:R("richtext-flex richtext-h-10 richtext-w-full richtext-rounded-md !richtext-border richtext-border-input richtext-bg-transparent richtext-px-3 richtext-py-2 richtext-text-sm richtext-text-foreground richtext-ring-offset-background file:richtext-border-0 file:richtext-bg-transparent file:richtext-text-sm file:richtext-font-medium placeholder:richtext-text-muted-foreground focus-visible:richtext-outline-none focus-visible:richtext-ring-1 focus-visible:richtext-ring-ring focus-visible:richtext-ring-offset-1 disabled:richtext-cursor-not-allowed disabled:richtext-opacity-50",e),...r}));te.displayName="Input";const si=Ze("richtext-text-sm richtext-font-medium richtext-leading-none richtext-text-foreground peer-disabled:richtext-cursor-not-allowed peer-disabled:richtext-opacity-70"),ue=P.forwardRef(({className:e,...t},r)=>i.jsx(gt.Root,{className:R(si(),e),ref:r,...t}));ue.displayName=gt.Root.displayName;const ze=ne.Root,ye=P.forwardRef(({className:e,...t},r)=>i.jsx(ne.List,{ref:r,className:R("richtext-inline-flex richtext-h-10 richtext-items-center richtext-justify-center richtext-rounded-md richtext-bg-muted richtext-p-1 richtext-text-muted-foreground",e),...t}));ye.displayName=ne.List.displayName;const Z=P.forwardRef(({className:e,...t},r)=>i.jsx(ne.Trigger,{ref:r,className:R("richtext-inline-flex richtext-items-center richtext-justify-center richtext-whitespace-nowrap richtext-rounded-sm richtext-px-3 richtext-py-1.5 richtext-text-sm richtext-font-medium richtext-ring-offset-background richtext-transition-all focus-visible:richtext-outline-none focus-visible:richtext-ring-2 focus-visible:richtext-ring-ring focus-visible:richtext-ring-offset-1 disabled:richtext-pointer-events-none disabled:richtext-opacity-50 data-[state=active]:richtext-bg-background data-[state=active]:richtext-text-foreground data-[state=active]:richtext-shadow-sm",e),...t}));Z.displayName=ne.Trigger.displayName;const K=P.forwardRef(({className:e,...t},r)=>i.jsx(ne.Content,{ref:r,className:R("richtext-mt-2 richtext-ring-offset-background focus-visible:richtext-outline-none focus-visible:richtext-ring-2 focus-visible:richtext-ring-ring focus-visible:richtext-ring-offset-1",e),...t}));K.displayName=ne.Content.displayName;const Mt=P.forwardRef(({className:e,...t},r)=>i.jsx("textarea",{ref:r,className:R("richtext-flex richtext-min-h-[80px] richtext-w-full richtext-rounded-md !richtext-border richtext-border-input richtext-bg-transparent richtext-px-3 richtext-py-2 richtext-text-sm richtext-ring-offset-background placeholder:richtext-text-muted-foreground focus-visible:richtext-outline-none focus-visible:richtext-ring-2 focus-visible:richtext-ring-ring focus-visible:richtext-ring-offset-1 disabled:richtext-cursor-not-allowed disabled:richtext-opacity-50",e),...t}));Mt.displayName="Textarea";const ai=Ze("richtext-inline-flex richtext-items-center richtext-justify-center richtext-rounded-md richtext-text-sm richtext-font-medium richtext-ring-offset-background richtext-transition-colors hover:richtext-bg-muted hover:richtext-text-muted-foreground focus-visible:richtext-outline-none focus-visible:richtext-ring-2 focus-visible:richtext-ring-ring focus-visible:richtext-ring-offset-1 disabled:richtext-pointer-events-none disabled:richtext-opacity-50 data-[state=on]:richtext-bg-accent data-[state=on]:richtext-text-accent-foreground",{variants:{variant:{default:"richtext-bg-transparent",outline:"richtext-border richtext-border-input richtext-bg-transparent hover:richtext-bg-accent hover:richtext-text-accent-foreground"},size:{default:"richtext-h-10 richtext-px-3",sm:"richtext-h-9 richtext-px-2",lg:"richtext-h-11 richtext-px-5"}},defaultVariants:{variant:"default",size:"default"}}),Ke=P.forwardRef(({className:e,variant:t,size:r,...n},o)=>i.jsx(xt.Root,{ref:o,className:R(ai({variant:t,size:r,className:e})),...n}));Ke.displayName=xt.Root.displayName;const li=we.Provider,It=we.Root,Nt=we.Trigger,Qe=P.forwardRef(({className:e,sideOffset:t=4,...r},n)=>i.jsx(we.Content,{"data-richtext-portal":!0,ref:n,sideOffset:t,className:R("richtext-z-50 richtext-overflow-hidden richtext-rounded-md !richtext-border-none richtext-bg-primary richtext-px-3 richtext-py-1.5 richtext-text-sm richtext-text-primary-foreground richtext-shadow-md richtext-animate-in richtext-fade-in-0 richtext-zoom-in-95 data-[side=bottom]:richtext-slide-in-from-top-2 data-[side=left]:richtext-slide-in-from-right-2 data-[side=right]:richtext-slide-in-from-left-2 data-[side=top]:richtext-slide-in-from-bottom-2",e),...r}));Qe.displayName=we.Content.displayName;const ci=U.Root,di=U.Value,zt=P.forwardRef(({className:e,children:t,...r},n)=>i.jsxs(U.Trigger,{ref:n,className:R("richtext-flex richtext-h-10 richtext-w-full richtext-items-center richtext-justify-between richtext-rounded-md richtext-border richtext-border-input richtext-bg-background richtext-px-3 richtext-py-2 richtext-text-sm richtext-text-foreground richtext-ring-offset-background placeholder:richtext-text-muted-foreground focus:richtext-outline-none focus:richtext-ring-2 focus:richtext-ring-ring focus:richtext-ring-offset-1 disabled:richtext-cursor-not-allowed disabled:richtext-opacity-50 [&>span]:richtext-line-clamp-1",e),...r,children:[t,i.jsx(U.Icon,{asChild:!0,children:i.jsx(c.ChevronDown,{className:"richtext-size-4 richtext-opacity-50"})})]}));zt.displayName=U.Trigger.displayName;const Lt=P.forwardRef(({className:e,...t},r)=>i.jsx(U.ScrollUpButton,{ref:r,className:R("richtext-flex richtext-cursor-default richtext-items-center richtext-justify-center richtext-py-1",e),...t,children:i.jsx(c.ChevronUp,{className:"richtext-size-4"})}));Lt.displayName=U.ScrollUpButton.displayName;const At=P.forwardRef(({className:e,...t},r)=>i.jsx(U.ScrollDownButton,{ref:r,className:R("richtext-flex richtext-cursor-default richtext-items-center richtext-justify-center richtext-py-1",e),...t,children:i.jsx(c.ChevronDown,{className:"richtext-size-4"})}));At.displayName=U.ScrollDownButton.displayName;const Et=P.forwardRef(({className:e,children:t,position:r="popper",...n},o)=>i.jsx(U.Portal,{children:i.jsxs(U.Content,{"data-richtext-portal":!0,position:r,ref:o,className:R("richtext-relative richtext-z-50 richtext-max-h-60 richtext-min-w-[8rem] richtext-overflow-hidden richtext-overflow-y-auto richtext-rounded-md richtext-border !richtext-border-border richtext-bg-popover richtext-text-popover-foreground richtext-shadow-md data-[state=open]:richtext-animate-in data-[state=closed]:richtext-animate-out data-[state=closed]:richtext-fade-out-0 data-[state=open]:richtext-fade-in-0 data-[state=closed]:richtext-zoom-out-95 data-[state=open]:richtext-zoom-in-95 data-[side=bottom]:richtext-slide-in-from-top-2 data-[side=left]:richtext-slide-in-from-right-2 data-[side=right]:richtext-slide-in-from-left-2 data-[side=top]:richtext-slide-in-from-bottom-2",r==="popper"&&"data-[side=bottom]:richtext-translate-y-1 data-[side=left]:richtext--translate-x-1 data-[side=right]:richtext-translate-x-1 data-[side=top]:richtext--translate-y-1",e),...n,children:[i.jsx(Lt,{}),i.jsx(U.Viewport,{className:R("richtext-p-1",r==="popper"&&"richtext-h-[var(--radix-select-trigger-height)] richtext-w-full richtext-min-w-[var(--radix-select-trigger-width)]"),children:t}),i.jsx(At,{})]})}));Et.displayName=U.Content.displayName;const ui=P.forwardRef(({className:e,...t},r)=>i.jsx(U.Label,{className:R("richtext-py-1.5 richtext-pl-8 richtext-pr-2 richtext-text-sm richtext-font-semibold",e),ref:r,...t}));ui.displayName=U.Label.displayName;const Rt=P.forwardRef(({className:e,children:t,...r},n)=>i.jsxs(U.Item,{ref:n,className:R("richtext-relative richtext-flex richtext-w-full richtext-cursor-default richtext-select-none richtext-items-center richtext-rounded-sm richtext-py-1.5 richtext-pl-8 richtext-pr-2 richtext-text-sm richtext-outline-none focus:richtext-bg-accent focus:richtext-text-accent-foreground data-[disabled]:richtext-pointer-events-none data-[disabled]:richtext-opacity-50",e),...r,children:[i.jsx("span",{className:"richtext-absolute richtext-left-2 richtext-flex richtext-size-3.5 richtext-items-center richtext-justify-center",children:i.jsx(U.ItemIndicator,{children:i.jsx(c.Check,{className:"richtext-size-4"})})}),i.jsx(U.ItemText,{children:t})]}));Rt.displayName=U.Item.displayName;const hi=P.forwardRef(({className:e,...t},r)=>i.jsx(U.Separator,{className:R("richtext--mx-1 richtext-my-1 richtext-h-px richtext-bg-muted",e),ref:r,...t}));hi.displayName=U.Separator.displayName;const mi=1,fi=1e6;let He=0;function xi(){return He=(He+1)%Number.MAX_SAFE_INTEGER,He.toString()}const _e=new Map;function ut(e){if(_e.has(e))return;const t=setTimeout(()=>{_e.delete(e),pe({type:"REMOVE_TOAST",toastId:e})},fi);_e.set(e,t)}function gi(e,t){switch(t.type){case"ADD_TOAST":return{...e,toasts:[t.toast,...e.toasts].slice(0,mi)};case"UPDATE_TOAST":return{...e,toasts:e.toasts.map(r=>r.id===t.toast.id?{...r,...t.toast}:r)};case"DISMISS_TOAST":{const{toastId:r}=t;return r?ut(r):e.toasts.forEach(n=>{ut(n.id)}),{...e,toasts:e.toasts.map(n=>n.id===r||r===void 0?{...n,open:!1}:n)}}case"REMOVE_TOAST":return t.toastId===void 0?{...e,toasts:[]}:{...e,toasts:e.toasts.filter(r=>r.id!==t.toastId)}}}const ke=[];let Te={toasts:[]};function pe(e){Te=gi(Te,e),ke.forEach(t=>{t(Te)})}function pi({...e}){const t=xi(),r=o=>pe({type:"UPDATE_TOAST",toast:{...o,id:t}}),n=()=>pe({type:"DISMISS_TOAST",toastId:t});return pe({type:"ADD_TOAST",toast:{...e,id:t,open:!0,onOpenChange:o=>{o||n()}}}),{id:t,dismiss:n,update:r}}function Le(){const[e,t]=P.useState(Te);return P.useEffect(()=>(ke.push(t),()=>{const r=ke.indexOf(t);r>-1&&ke.splice(r,1)}),[e]),{...e,toast:pi,dismiss:r=>pe({type:"DISMISS_TOAST",toastId:r})}}const Ae=P.forwardRef(({className:e,...t},r)=>i.jsx(Ue.Root,{ref:r,className:R("!richtext-peer !richtext-h-4 !richtext-w-4 !richtext-shrink-0 !richtext-rounded-sm !richtext-border !richtext-border-primary !richtext-p-0 !richtext-ring-offset-background focus-visible:!richtext-outline-none focus-visible:!richtext-ring-2 focus-visible:!richtext-ring-ring focus-visible:!richtext-ring-offset-1 disabled:!richtext-cursor-not-allowed disabled:!richtext-opacity-50 data-[state=checked]:!richtext-bg-primary data-[state=checked]:!richtext-text-primary-foreground",e),...t,children:i.jsx(Ue.Indicator,{className:R("!richtext-flex !richtext-items-center !richtext-justify-center !richtext-p-0 !richtext-text-current"),children:i.jsx(c.Check,{className:"!richtext-h-4 !richtext-w-4"})})}));Ae.displayName=Ue.Root.displayName;function bi(e){return e=e||new Map,{all:e,on(t,r){const n=e.get(t);n?n.push(r):e.set(t,[r])},off(t,r){const n=e.get(t);n&&(r?n.splice(n.indexOf(r)>>>0,1):e.set(t,[]))},emit(t,r){let n=e.get(t);n&&n.slice().map(o=>{o(r)}),n=e.get("*"),n&&n.slice().map(o=>{o(t,r)})}}}const Je=bi(),Vt=m.createContext(Je),vi=()=>m.useContext(Vt);function et(e,t){const r=vi();m.useEffect(()=>(t.map(n=>r.on(n,e)),()=>{t.map(n=>r.off(n,e))}),[r,t,e])}const wi=Je.emit;function yi({children:e}){return i.jsx(Vt.Provider,{value:Je,children:e})}const me=q.Root,Ee=q.Trigger,ji=q.Portal,Dt=P.forwardRef(({className:e,...t},r)=>i.jsx(q.Overlay,{ref:r,className:R("richtext-fixed richtext-inset-0 richtext-z-50 richtext-bg-black/80 data-[state=open]:richtext-animate-in data-[state=closed]:richtext-animate-out data-[state=closed]:richtext-fade-out-0 data-[state=open]:richtext-fade-in-0",e),...t}));Dt.displayName=q.Overlay.displayName;const oe=P.forwardRef(({className:e,children:t,...r},n)=>i.jsxs(ji,{"data-richtext-portal":!0,children:[i.jsx(Dt,{}),i.jsxs(q.Content,{"data-richtext-portal":!0,ref:n,className:R("richtext-fixed richtext-left-[50%] richtext-top-[50%] richtext-z-50 richtext-grid richtext-w-full richtext-max-w-lg richtext-translate-x-[-50%] richtext-translate-y-[-50%] richtext-gap-4 richtext-border !richtext-border-border richtext-bg-background richtext-p-6 richtext-shadow-lg richtext-duration-200 data-[state=open]:richtext-animate-in data-[state=closed]:richtext-animate-out data-[state=closed]:richtext-fade-out-0 data-[state=open]:richtext-fade-in-0 data-[state=closed]:richtext-zoom-out-95 data-[state=open]:richtext-zoom-in-95 data-[state=closed]:richtext-slide-out-to-left-1/2 data-[state=closed]:richtext-slide-out-to-top-[48%] data-[state=open]:richtext-slide-in-from-left-1/2 data-[state=open]:richtext-slide-in-from-top-[48%] sm:richtext-rounded-lg",e),...r,children:[t,i.jsxs(q.Close,{className:"richtext-absolute richtext-right-4 richtext-top-4 richtext-rounded-sm richtext-opacity-70 richtext-ring-offset-background richtext-transition-opacity hover:richtext-opacity-100 focus:richtext-outline-none focus:richtext-ring-2 focus:richtext-ring-ring focus:richtext-ring-offset-1 disabled:richtext-pointer-events-none data-[state=open]:richtext-bg-accent data-[state=open]:richtext-text-muted-foreground",children:[i.jsx(c.X,{className:"richtext-size-4 richtext-text-accent-foreground"}),i.jsx("span",{className:"richtext-sr-only richtext-text-accent-foreground",children:"Close"})]})]})]}));oe.displayName=q.Content.displayName;function Pt({className:e,...t}){return i.jsx("div",{className:R("richtext-flex richtext-flex-col richtext-space-y-1.5 richtext-text-center sm:richtext-text-left",e),...t})}Pt.displayName="DialogHeader";function tt({className:e,...t}){return i.jsx("div",{className:R("richtext-flex richtext-flex-col-reverse sm:richtext-flex-row sm:richtext-justify-end sm:richtext-space-x-2",e),...t})}tt.displayName="DialogFooter";const se=P.forwardRef(({className:e,...t},r)=>i.jsx(q.Title,{ref:r,className:R("richtext-text-lg richtext-font-semibold richtext-leading-none richtext-tracking-tight richtext-text-foreground",e),...t}));se.displayName=q.Title.displayName;const Ci=P.forwardRef(({className:e,...t},r)=>i.jsx(q.Description,{className:R("richtext-text-sm richtext-text-muted-foreground",e),ref:r,...t}));Ci.displayName=q.Description.displayName;var Si=/(?:^|\s)(!\[(.+|:?)]\((\S+)(?:(?:\s+)["'](\S+)["'])?\))$/,ki=ie.Node3.create({name:"image",addOptions(){return{inline:!1,allowBase64:!1,HTMLAttributes:{},resize:!1}},inline(){return this.options.inline},group(){return this.options.inline?"inline":"block"},draggable:!0,addAttributes(){return{src:{default:null},alt:{default:null},title:{default:null},width:{default:null},height:{default:null}}},parseHTML(){return[{tag:this.options.allowBase64?"img[src]":'img[src]:not([src^="data:"])'}]},renderHTML({HTMLAttributes:e}){return["img",ie.mergeAttributes(this.options.HTMLAttributes,e)]},parseMarkdown:(e,t)=>t.createNode("image",{src:e.href,title:e.title,alt:e.text}),renderMarkdown:e=>{var t,r,n,o,s,l;const a=(r=(t=e.attrs)==null?void 0:t.src)!=null?r:"",d=(o=(n=e.attrs)==null?void 0:n.alt)!=null?o:"",h=(l=(s=e.attrs)==null?void 0:s.title)!=null?l:"";return h?``:``},addNodeView(){if(!this.options.resize||!this.options.resize.enabled||typeof document>"u")return null;const{directions:e,minWidth:t,minHeight:r,alwaysPreserveAspectRatio:n}=this.options.resize;return({node:o,getPos:s,HTMLAttributes:l,editor:a})=>{const d=document.createElement("img");d.draggable=!1;const h=ie.mergeAttributes(this.options.HTMLAttributes,l);Object.entries(h).forEach(([u,j])=>{if(j!=null)switch(u){case"width":case"height":break;default:d.setAttribute(u,j);break}}),h.src!==null&&(d.src=h.src);const x=new ie.ResizableNodeView({element:d,editor:a,node:o,getPos:s,onResize:(u,j)=>{d.style.width=`${u}px`,d.style.height=`${j}px`},onCommit:(u,j)=>{const g=s();g!==void 0&&this.editor.chain().setNodeSelection(g).updateAttributes(this.name,{width:u,height:j}).run()},onUpdate:(u,j,g)=>u.type===o.type,options:{directions:e,min:{width:t,height:r},preserveAspectRatio:n===!0}}),w=x.dom;return w.style.visibility="hidden",w.style.pointerEvents="none",d.onload=()=>{w.style.visibility="",w.style.pointerEvents=""},x}},addCommands(){return{setImage:e=>({commands:t})=>t.insertContent({type:this.name,attrs:e})}},addInputRules(){return[ie.nodeInputRule({find:Si,type:this.type,getAttributes:e=>{const[,,t,r,n]=e;return{src:r,alt:t,title:n}}})]}}),Ht=ki,Ti=typeof global=="object"&&global&&global.Object===Object&&global,Mi=typeof self=="object"&&self&&self.Object===Object&&self,_t=Ti||Mi||Function("return this")(),Me=_t.Symbol,Ot=Object.prototype,Ii=Ot.hasOwnProperty,Ni=Ot.toString,ge=Me?Me.toStringTag:void 0;function zi(e){var t=Ii.call(e,ge),r=e[ge];try{e[ge]=void 0;var n=!0}catch{}var o=Ni.call(e);return n&&(t?e[ge]=r:delete e[ge]),o}var Li=Object.prototype,Ai=Li.toString;function Ei(e){return Ai.call(e)}var Ri="[object Null]",Vi="[object Undefined]",ht=Me?Me.toStringTag:void 0;function Bt(e){return e==null?e===void 0?Vi:Ri:ht&&ht in Object(e)?zi(e):Ei(e)}function Ut(e){return e!=null&&typeof e=="object"}var Di="[object Symbol]";function Pi(e){return typeof e=="symbol"||Ut(e)&&Bt(e)==Di}var Hi=/\s/;function _i(e){for(var t=e.length;t--&&Hi.test(e.charAt(t)););return t}var Oi=/^\s+/;function Bi(e){return e&&e.slice(0,_i(e)+1).replace(Oi,"")}function Ie(e){var t=typeof e;return e!=null&&(t=="object"||t=="function")}var mt=NaN,Ui=/^[-+]0x[0-9a-f]+$/i,Fi=/^0b[01]+$/i,$i=/^0o[0-7]+$/i,Wi=parseInt;function be(e){if(typeof e=="number")return e;if(Pi(e))return mt;if(Ie(e)){var t=typeof e.valueOf=="function"?e.valueOf():e;e=Ie(t)?t+"":t}if(typeof e!="string")return e===0?e:+e;e=Bi(e);var r=Fi.test(e);return r||$i.test(e)?Wi(e.slice(2),r?2:8):Ui.test(e)?mt:+e}function Gi(e,t,r){return e===e&&(r!==void 0&&(e=e<=r?e:r),t!==void 0&&(e=e>=t?e:t)),e}function Ft(e,t,r){return r===void 0&&(r=t,t=void 0),r!==void 0&&(r=be(r),r=r===r?r:0),t!==void 0&&(t=be(t),t=t===t?t:0),Gi(be(e),t,r)}var Oe=function(){return _t.Date.now()},qi="Expected a function",Xi=Math.max,Yi=Math.min;function $t(e,t,r){var n,o,s,l,a,d,h=0,x=!1,w=!1,u=!0;if(typeof e!="function")throw new TypeError(qi);t=be(t)||0,Ie(r)&&(x=!!r.leading,w="maxWait"in r,s=w?Xi(be(r.maxWait)||0,t):s,u="trailing"in r?!!r.trailing:u);function j(y){var B=n,I=o;return n=o=void 0,h=y,l=e.apply(I,B),l}function g(y){return h=y,a=setTimeout(C,t),x?j(y):l}function k(y){var B=y-d,I=y-h,H=t-B;return w?Yi(H,s-I):H}function p(y){var B=y-d,I=y-h;return d===void 0||B>=t||B<0||w&&I>=s}function C(){var y=Oe();if(p(y))return v(y);a=setTimeout(C,k(y))}function v(y){return a=void 0,u&&n?j(y):(n=o=void 0,l)}function L(){a!==void 0&&clearTimeout(a),h=0,n=d=o=a=void 0}function b(){return a===void 0?l:v(Oe())}function z(){var y=Oe(),B=p(y);if(n=arguments,o=this,d=y,B){if(a===void 0)return g(d);if(w)return clearTimeout(a),a=setTimeout(C,t),j(d)}return a===void 0&&(a=setTimeout(C,t)),l}return z.cancel=L,z.flush=b,z}var Zi="[object Number]";function $e(e){return typeof e=="number"||Ut(e)&&Bt(e)==Zi}var Ki="Expected a function";function We(e,t,r){var n=!0,o=!0;if(typeof e!="function")throw new TypeError(Ki);return Ie(r)&&(n="leading"in r?!!r.leading:n,o="trailing"in r?!!r.trailing:o),$t(e,t,{leading:n,maxWait:t,trailing:o})}const Se={TOP_LEFT:"tl",TOP_RIGHT:"tr",BOTTOM_LEFT:"bl",BOTTOM_RIGHT:"br"};function Qi(e){var H,A,F;const[t,r]=m.useState({width:G.IMAGE_MAX_SIZE,height:G.IMAGE_MAX_SIZE}),[n,o]=m.useState({width:0,height:0}),[s]=m.useState([Se.TOP_LEFT,Se.TOP_RIGHT,Se.BOTTOM_LEFT,Se.BOTTOM_RIGHT]),[l,a]=m.useState(!1),[d,h]=m.useState({x:0,y:0,w:0,h:0,dir:""}),{align:x,inline:w}=(H=e==null?void 0:e.node)==null?void 0:H.attrs,u=w===!0||w==="true",j=u&&(x==="left"||x==="right"),g=m.useMemo(()=>{var st;const{src:f,alt:V,width:E,height:S,flipX:N,flipY:M}=(st=e==null?void 0:e.node)==null?void 0:st.attrs,O=$e(E)?`${E}px`:E,_=$e(S)?`${S}px`:S,$=[];N&&$.push("rotateX(180deg)"),M&&$.push("rotateY(180deg)");const X=$.join(" ");return{src:f||void 0,alt:V||void 0,style:{width:O||void 0,height:_||void 0,transform:X||"none",...j?{float:x}:{}}}},[(A=e==null?void 0:e.node)==null?void 0:A.attrs,j,x]),k=m.useMemo(()=>{const{style:{width:f}}=g;return{width:f==="100%"?f:void 0}},[g]);function p(f){o({width:f.target.width,height:f.target.height})}function C(){const{editor:f,getPos:V}=e;f.commands.setNodeSelection(V())}const v=m.useCallback(We(()=>{const{editor:f}=e,{width:V}=getComputedStyle(f.view.dom);r(E=>({...E,width:Number.parseInt(V,10)}))},G.IMAGE_THROTTLE_WAIT_TIME),[e==null?void 0:e.editor]);function L(f,V){f.preventDefault(),f.stopPropagation();const E=n.width,S=n.height,N=E/S;let M=Number(e.node.attrs.width),O=Number(e.node.attrs.height);const _=t.width;M&&!O?(M=M>_?_:M,O=Math.round(M/N)):O&&!M?(M=Math.round(O*N),M=M>_?_:M):!M&&!O?(M=E>_?_:E,O=Math.round(M/N)):M=M>_?_:M,a(!0),h({x:f.clientX,y:f.clientY,w:M,h:O,dir:V})}const b=m.useCallback(We(f=>{if(f.preventDefault(),f.stopPropagation(),!l)return;const{x:V,w:E,dir:S}=d,N=(f.clientX-V)*(/l/.test(S)?-1:1),M=Ft(E+N,G.IMAGE_MIN_SIZE,t.width);e.updateAttributes({width:M,height:null})},G.IMAGE_THROTTLE_WAIT_TIME),[l,d,t,e.updateAttributes]),z=m.useCallback(f=>{f.preventDefault(),f.stopPropagation(),l&&(h({x:0,y:0,w:0,h:0,dir:""}),a(!1),C())},[l,C]),y=m.useCallback(()=>{document==null||document.addEventListener("mousemove",b,!0),document==null||document.addEventListener("mouseup",z,!0)},[b,z]),B=m.useCallback(()=>{document==null||document.removeEventListener("mousemove",b,!0),document==null||document.removeEventListener("mouseup",z,!0)},[b,z]);m.useEffect(()=>(l?y():B(),()=>{B()}),[l,y,B]);const I=m.useMemo(()=>new ResizeObserver(()=>v()),[v]);return m.useEffect(()=>(I.observe(e.editor.view.dom),()=>{I.disconnect()}),[e.editor.view.dom,I]),i.jsx(de.NodeViewWrapper,{as:"span",className:"image-view",style:{float:j?x:void 0,margin:j?x==="left"?"1em 1em 1em 0":"1em 0 1em 1em":void 0,display:u?"inline":"block",textAlign:j?void 0:x,width:((F=g.style)==null?void 0:F.width)??"auto",...j?{}:k},children:i.jsxs("span",{"data-drag-handle":!0,draggable:"true",style:k,className:`image-view__body ${e!=null&&e.selected?"image-view__body--focused":""} ${l?"image-view__body--resizing":""}`,children:[i.jsx("img",{alt:g.alt,className:"image-view__body__image block",height:"auto",onClick:C,onLoad:p,src:g.src,style:g.style}),(e==null?void 0:e.editor.view.editable)&&((e==null?void 0:e.selected)||l)&&i.jsx("span",{className:"image-resizer",children:s==null?void 0:s.map(f=>i.jsx("span",{className:`image-resizer__handler image-resizer__handler--${f}`,onMouseDown:V=>L(V,f)},`image-dir-${f}`))})]})})}function Ji(e){const{editor:t}=de.useCurrentEditor(),r=P.useMemo(()=>t,[e,t]);return de.useEditorState({editor:r,selector(o){return o.editor?{editor:o.editor,editorState:o.editor.state,canCommand:o.editor.can}:{editor:null,editorState:void 0,canCommand:void 0}}})||{editor:null}}function Q(){return Ji().editor}const Wt=Ge.y(!1);function rt(){return Ge.b(Wt)}function en(){return Ge.S(Wt)}const Gt=()=>!1;function tn(e=Gt){const t=rt(),[r,n]=m.useState(()=>{const a=e();return typeof a=="boolean"?!a:a}),o=Q();m.useEffect(()=>{if(!o||!e)return;const a=()=>{const d=e();n(typeof d=="boolean"?!d:d)};return a(),o.on("selectionUpdate",a),o.on("transaction",a),()=>{o.off("selectionUpdate",a),o.off("transaction",a)}},[o,e]);const s=m.useMemo(()=>!t||!o?!0:typeof r=="boolean"?r:!1,[t,o,r]),l=m.useMemo(()=>!t||!o,[t,o]);return{disabled:s,dataState:r,editorDisabled:l}}function je(e=Gt){const t=rt(),[r,n]=m.useState({}),[o,s]=m.useState(e()),l=Q();m.useEffect(()=>{if(!l||!e)return;const h=()=>{s(e())};return h(),l.on("selectionUpdate",h),()=>{l.off("selectionUpdate",h)}},[r,l,e]);const a=m.useMemo(()=>!t||!l,[t,l]),d=m.useMemo(()=>!t||!l,[t,l]);return{disabled:a,dataState:o,editorDisabled:d,update:()=>n({})}}function ae(e){const t=Q();return m.useMemo(()=>t?t.extensionManager.extensions.find(n=>n.name===e):null,[t,e])}function rn(e,t,r){return e<t?t:e>r?r:e}const nn=e=>typeof e=="number",on=e=>typeof e=="string",sn=e=>typeof e=="function";function an(e,t="px"){if(!e)return e;const r=nn(e)?String(e):e,n=Number.parseFloat(r),o=r.match(/[%a-z]+$/i),s=o?o[0]:t;return Number.isNaN(n)?e:n+s}function ln(e,t){if(!e)return!1;const{extensions:r=[]}=(e==null?void 0:e.extensionManager)??{};return!!r.find(o=>o.name===t)}function cn(e){return e.map(t=>on(t)?{value:t,name:t}:t)}function it(e){const t=Q(),r=ae(e),{t:n}=G.useLocale();return m.useMemo(()=>{if(!t||!r||!n)return null;const{button:o}=r.options;return!o||!sn(o)?null:o({editor:t,extension:r,t:n})},[t,r,n])}function dn(e,t){const r=e.type,n=e.name.toLowerCase(),o=n.split(".").pop();if(!o)return!1;const l=r||{heif:"image/heif",heic:"image/heic",dng:"image/x-adobe-dng",cr2:"image/x-canon-cr2",nef:"image/x-nikon-nef",arw:"image/x-sony-arw",raf:"image/x-fuji-raf",orf:"image/x-olympus-orf"}[o];return t.some(a=>{if(a.startsWith("."))return n.endsWith(a);if(a.endsWith("/*")){const d=a.split("/")[0];return l==null?void 0:l.startsWith(d+"/")}return l===a})}function nt(e,t){const{acceptMimes:r,maxSize:n,t:o,toast:s}=t,l=[];return(Array.isArray(e)?e:Object.values(e)).forEach(d=>{if(!dn(d,r)){t.onError?t.onError({type:"type",message:o("editor.upload.fileTypeNotSupported",{fileName:d.name}),file:d}):s({variant:"default",title:o("editor.upload.fileTypeNotSupported",{fileName:d.name})});return}if(d.size>n){const h=(n/1024/1024).toFixed(2);t.onError?t.onError({type:"size",message:o("editor.upload.fileSizeTooBig",{fileName:d.name,size:h}),file:d}):s({variant:"default",title:o("editor.upload.fileSizeTooBig",{fileName:d.name,size:h})});return}l.push(d)}),l}function un(){const{t:e}=G.useLocale(),{toast:t}=Le(),r=Q(),n=it(ve.name),{icon:o,tooltip:s}=(n==null?void 0:n.componentProps)??{},{editorDisabled:l}=je(),[a,d]=m.useState(!1),[h,x]=m.useState(!1),[w,u]=m.useState(!1),j=ae(ve.name),[g,k]=m.useState(""),[p,C]=m.useState(""),v=m.useRef(null),L=(j==null?void 0:j.options.defaultInline)||!1,[b,z]=m.useState(L),y=m.useMemo(()=>(j==null?void 0:j.options)||Re,[j]);async function B(A){var V;const F=(V=A==null?void 0:A.target)==null?void 0:V.files;if(!r||r.isDestroyed||F.length===0||w){A.target.value="";return}const f=nt(F,{acceptMimes:y==null?void 0:y.acceptMimes,maxSize:y==null?void 0:y.maxSize,t:e,toast:t,onError:y.onError});if(f.length<=0){A.target.value="";return}u(!0);try{if(y!=null&&y.multiple){const E=f.map(async N=>{let M="";return y.upload?M=await y.upload(N):M=URL.createObjectURL(N),M});(await Promise.all(E)).forEach(N=>{r.chain().focus().setImageInline({src:N,inline:b,alt:p}).run()})}else{const E=f[0];let S="";y.upload?S=await y.upload(E):S=URL.createObjectURL(E),r.chain().focus().setImageInline({src:S,inline:b,alt:p}).run()}d(!1),C(""),z(L)}catch(E){console.error("Error uploading image",E),y.onError?y.onError({type:"upload",message:e("editor.upload.error")}):t({variant:"destructive",title:e("editor.upload.error")})}finally{u(!1),A.target.value=""}}function I(A){A.preventDefault(),A.stopPropagation(),r.chain().focus().setImageInline({src:g,inline:b,alt:p}).run(),d(!1),z(L),k(""),C("")}function H(A){var F;A.preventDefault(),(F=v.current)==null||F.click()}return n?i.jsxs(me,{onOpenChange:A=>{d(A),A||x(!1)},open:a,children:[i.jsx(Ee,{asChild:!0,children:i.jsx(Xe,{disabled:l,icon:o,tooltip:s,action:()=>{l||d(!0)}})}),i.jsxs(oe,{className:h?"richtext-hidden":void 0,children:[i.jsx(se,{children:e("editor.image.dialog.title")}),i.jsxs(ze,{activationMode:"manual",defaultValue:y.resourceImage==="both"||y.resourceImage==="upload"?"upload":"link",children:[y.resourceImage==="both"&&i.jsxs(ye,{className:"richtext-grid richtext-w-full richtext-grid-cols-2",children:[i.jsx(Z,{value:"upload",children:e("editor.image.dialog.tab.upload")}),i.jsx(Z,{value:"link",children:e("editor.image.dialog.tab.url")})]}),i.jsxs("div",{className:"richtext-my-[10px] richtext-flex richtext-items-center richtext-gap-[4px]",children:[i.jsx(Ae,{checked:b,onCheckedChange:A=>{z(A)}}),i.jsx(ue,{children:e("editor.link.dialog.inline")})]}),y.enableAlt&&i.jsxs("div",{className:"richtext-my-[10px]",children:[i.jsx(ue,{className:"mb-[6px]",children:e("editor.imageUpload.alt")}),i.jsx(te,{onChange:A=>C(A.target.value),required:!0,type:"text",value:p})]}),i.jsxs(K,{value:"upload",children:[i.jsxs("div",{className:"richtext-flex richtext-items-center richtext-gap-[10px]",children:[i.jsx(W,{className:"richtext-mt-1 richtext-w-full",disabled:w,onClick:H,size:"sm",children:w?i.jsxs(i.Fragment,{children:[e("editor.imageUpload.uploading"),i.jsx(ce,{className:"richtext-ml-1 richtext-animate-spin",name:"Loader"})]}):e("editor.image.dialog.tab.upload")}),i.jsx(Yt,{alt:p,disabled:w,editor:r,imageInline:b,onClose:()=>{d(!1),x(!1),C(""),z(L)},onOpenChange:x})]}),i.jsx("input",{accept:y.acceptMimes.join(",")||"image/*",multiple:y.multiple,onChange:B,ref:v,style:{display:"none"},type:"file"})]}),i.jsx(K,{value:"link",children:i.jsx("form",{onSubmit:I,children:i.jsxs("div",{className:"richtext-flex richtext-items-center richtext-gap-2",children:[i.jsx(te,{autoFocus:!0,onChange:A=>k(A.target.value),placeholder:e("editor.image.dialog.placeholder"),required:!0,type:"url",value:g}),i.jsx(W,{type:"submit",children:e("editor.image.dialog.button.apply")})]})})})]})]})]}):i.jsx(i.Fragment,{})}const Re={acceptMimes:["image/jpeg","image/gif","image/png","image/jpg"],maxSize:1024*1024*5,multiple:!0,resourceImage:"both",defaultInline:!1,enableAlt:!0};function qt(e){return e==null?null:e===!0||e===""||e==="true"}function Be(e){return qt(e)??!1}const ve=Ht.extend({group:"inline",inline:!0,defining:!0,draggable:!0,selectable:!0,addOptions(){var e;return{...Re,...(e=this.parent)==null?void 0:e.call(this),upload:()=>Promise.reject("Image Upload Function"),button:({editor:t,extension:r,t:n})=>{var o,s;return{componentProps:{action:()=>!0,upload:r.options.upload,disabled:!((s=(o=t.can()).setImage)!=null&&s.call(o,{})),icon:"ImageUp",tooltip:n("editor.image.tooltip")}}}}},addAttributes(){var e;return{...(e=this.parent)==null?void 0:e.call(this),flipX:{default:!1},flipY:{default:!1},width:{default:null,parseHTML:t=>{const r=t.style.width||t.getAttribute("width")||null;return r?Number.parseInt(r,10):null},renderHTML:t=>({width:t.width})},align:{default:"center",parseHTML:t=>t.getAttribute("align"),renderHTML:t=>({align:t.align})},inline:{default:!1,parseHTML:t=>qt(t.getAttribute("inline")),renderHTML:t=>({inline:t.inline?"true":null})},alt:{default:"",parseHTML:t=>t.getAttribute("alt"),renderHTML:t=>({alt:t.alt})}}},addNodeView(){return de.ReactNodeViewRenderer(Qi)},addCommands(){var e;return{...(e=this.parent)==null?void 0:e.call(this),setImageInline:t=>({commands:r})=>r.insertContent({type:this.name,attrs:{...t,inline:t.inline??this.options.defaultInline}}),updateImage:t=>({commands:r})=>r.updateAttributes(this.name,t),setAlignImage:t=>({commands:r})=>r.updateAttributes(this.name,{align:t})}},renderHTML({HTMLAttributes:e}){const{flipX:t,flipY:r,align:n,inline:o}=e,s=Be(o),l=s&&(n==="left"||n==="right"),a=t||r?`transform: rotateX(${t?"180":"0"}deg) rotateY(${r?"180":"0"}deg);`:"",d=!s&&n==="center"?"margin: 0 auto;":!s&&n==="right"?"margin-left: auto;":s?"":"margin-right: auto;",h=s?"":"display: block;",x=l?`float: ${n};`:"",u=`${h}${d}${x}${l?n==="left"?"margin: 1em 1em 1em 0;":"margin: 1em 0 1em 1em;":""}${a}`,j={...e,inline:s?"true":null};return["span",{class:"image"},["img",ie.mergeAttributes({height:"auto",style:u||null},this.options.HTMLAttributes,j)]]},parseHTML(){return[{tag:"span.image",getAttrs:e=>{const t=e.querySelector("img"),r=t==null?void 0:t.getAttribute("width"),n=(t==null?void 0:t.getAttribute("flipx"))||!1,o=(t==null?void 0:t.getAttribute("flipy"))||!1;return{src:t==null?void 0:t.getAttribute("src"),alt:t==null?void 0:t.getAttribute("alt"),caption:t==null?void 0:t.getAttribute("caption"),width:r?Number.parseInt(r,10):null,align:(t==null?void 0:t.getAttribute("align"))||e.style.textAlign||null,inline:Be(t==null?void 0:t.getAttribute("inline")),flipX:n==="true",flipY:o==="true"}}},{tag:"div[class=image]",getAttrs:e=>{const t=e.querySelector("img"),r=t==null?void 0:t.getAttribute("width"),n=(t==null?void 0:t.getAttribute("flipx"))||!1,o=(t==null?void 0:t.getAttribute("flipy"))||!1;return{src:t==null?void 0:t.getAttribute("src"),alt:t==null?void 0:t.getAttribute("alt"),caption:t==null?void 0:t.getAttribute("caption"),width:r?Number.parseInt(r,10):null,align:(t==null?void 0:t.getAttribute("align"))||e.style.textAlign||null,inline:Be(t==null?void 0:t.getAttribute("inline")),flipX:n==="true",flipY:o==="true"}}},{tag:'img[src]:not([src^="data:"])'}]}});function hn(e){return e.replace(/^.*\/|\..+$/g,"")}function mn(e){return e.split(".").pop()}function fn(e){return e<1024?`${e} Byte`:e<1024*1024?`${(e/1024).toFixed(2)} KB`:`${(e/1024/1024).toFixed(2)} MB`}function xn(e){return e?e==="application/pdf"?"pdf":e.startsWith("application/")&&[".document","word"].some(t=>e.includes(t))?"word":e.startsWith("application/")&&["presentation"].some(t=>e.includes(t))?"excel":e.startsWith("application/")&&["sheet"].some(t=>e.includes(t))?"ppt":e.startsWith("image")?"image":e.startsWith("audio")?"audio":e.startsWith("video")?"video":"file":"file"}function gn(e){return new Promise(t=>{const r=new FileReader;r.addEventListener("load",()=>{t({alt:e.name,src:r.result})},!1),r.readAsDataURL(e)})}function Xt(e,t){const r=e.split(","),n=r[0].match(/:(.*?);/)[1],o=atob(r[r.length-1]);let s=o.length;const l=new Uint8Array(s);for(;s--;)l[s]=o.charCodeAt(s);return new File([l],t,{type:n})}function Yt({editor:e,imageInline:t,onClose:r,onOpenChange:n,disabled:o,alt:s}){var V,E;const{t:l}=G.useLocale(),{toast:a}=Le(),[d,h]=m.useState(!1),[x,w]=m.useState(!1),u=m.useRef(null),[j,g]=m.useState(),[k,p]=m.useState(""),C=m.useRef(null),[v,L]=m.useState({src:"",file:null}),b=ae(ve.name),z=m.useMemo(()=>(b==null?void 0:b.options)??{},[b]);function y(S){if(u.current&&S.width&&S.height){const N=B(u.current,S);p(N)}}function B(S,N){const M=document.createElement("canvas"),O=S.naturalWidth/S.width,_=S.naturalHeight/S.height;M.width=N.width*O,M.height=N.height*_;const $=M.getContext("2d");return $&&($.imageSmoothingEnabled=!1,$.drawImage(S,N.x*O,N.y*_,N.width*O,N.height*_,0,0,N.width*O,N.height*_)),M.toDataURL("image/png",1)}const I=m.useCallback(()=>{C.current&&(C.current.value="")},[]),H=m.useCallback(S=>{h(S),n==null||n(S),S||(g(void 0),p(""),L({src:"",file:null}),I())},[n,I]),A=m.useCallback(async()=>{var S;if(!x){w(!0);try{const N=Xt(k,((S=v==null?void 0:v.file)==null?void 0:S.name)||"image.png");let M="";z.upload?M=await z.upload(N):M=URL.createObjectURL(N),e.chain().focus().setImageInline({src:M,inline:t,alt:s}).run(),H(!1),r()}catch(N){console.error("Error cropping image",N)}finally{w(!1)}}},[s,k,e,H,t,x,r,(V=v==null?void 0:v.file)==null?void 0:V.name,z]);function F(S){var N;S.preventDefault(),(N=C.current)==null||N.click()}const f=async S=>{var $;const N=($=S==null?void 0:S.target)==null?void 0:$.files;if(!e||e.isDestroyed||N.length===0){S.target.value="";return}const M=nt(N,{acceptMimes:z==null?void 0:z.acceptMimes,maxSize:z==null?void 0:z.maxSize,t:l,toast:a,onError:z.onError});if(M.length<=0){S.target.value="";return}const O=M[0],_=await gn(O);H(!0),L({src:_.src,file:O})};return i.jsxs(i.Fragment,{children:[i.jsx(W,{className:"richtext-mt-1 richtext-w-full",disabled:o,onClick:F,size:"sm",children:l("editor.image.dialog.tab.uploadCrop")}),i.jsxs(me,{open:d,onOpenChange:H,children:[i.jsx(Ee,{}),i.jsxs(oe,{children:[i.jsx(se,{children:l("editor.image.dialog.tab.uploadCrop")}),i.jsx("div",{children:v.src&&i.jsx(or,{className:"richtext-w-full",crop:j,onChange:S=>g(S),onComplete:S=>y(S),children:i.jsx("img",{alt:"Crop me",ref:u,src:v.src})})}),i.jsxs(tt,{children:[i.jsxs(W,{disabled:x,onClick:()=>{H(!1)},children:[l("editor.imageUpload.cancel"),i.jsx(ce,{className:"richtext-ml-1",name:"Trash2"})]}),i.jsx(W,{className:"richtext-w-fit",disabled:x||!j,onClick:A,children:x?i.jsxs(i.Fragment,{children:[l("editor.imageUpload.uploading"),i.jsx(ce,{className:"richtext-ml-1 richtext-animate-spin",name:"Loader"})]}):i.jsxs(i.Fragment,{children:[l("editor.imageUpload.crop"),i.jsx(ce,{className:"richtext-ml-1",name:"Crop"})]})})]})]})]}),i.jsx("input",{accept:((E=z==null?void 0:z.acceptMimes)==null?void 0:E.join(","))||"image/*",multiple:!1,onChange:f,ref:C,style:{display:"none"},type:"file"})]})}const ot={UPLOAD_IMAGE:e=>`UPLOAD_IMAGE-${e}`,UPLOAD_VIDEO:e=>`UPLOAD_VIDEO-${e}`,EXCALIDRAW:e=>`EXCALIDRAW-${e}`};function pn(){const{t:e}=G.useLocale(),{toast:t}=Le(),r=Q(),{editorDisabled:n}=je(),[o,s]=m.useState(!1),[l,a]=m.useState(!1),d=ot.UPLOAD_IMAGE(r.id);et(s,[d]);const[h,x]=m.useState(!1),w=ae(ve.name),[u,j]=m.useState(""),[g,k]=m.useState(""),p=m.useRef(null),C=(w==null?void 0:w.options.defaultInline)||!1,[v,L]=m.useState(C),b=m.useMemo(()=>(w==null?void 0:w.options)||Re,[w]);async function z(I){var F;const H=(F=I==null?void 0:I.target)==null?void 0:F.files;if(!r||r.isDestroyed||H.length===0||h){I.target.value="";return}const A=nt(H,{acceptMimes:b==null?void 0:b.acceptMimes,maxSize:b==null?void 0:b.maxSize,t:e,toast:t,onError:b.onError});if(A.length<=0){I.target.value="";return}x(!0);try{if(b!=null&&b.multiple){const f=A.map(async E=>{let S="";return b.upload?S=await b.upload(E):S=URL.createObjectURL(E),S});(await Promise.all(f)).forEach(E=>{r.chain().focus().setImageInline({src:E,inline:v,alt:g}).run()})}else{const f=A[0];let V="";b.upload?V=await b.upload(f):V=URL.createObjectURL(f),r.chain().focus().setImageInline({src:V,inline:v,alt:g}).run()}s(!1),k(""),L(C)}catch(f){console.error("Error uploading image",f),b.onError?b.onError({type:"upload",message:e("editor.upload.error")}):t({variant:"destructive",title:e("editor.upload.error")})}finally{x(!1),I.target.value=""}}function y(I){I.preventDefault(),I.stopPropagation(),r.chain().focus().setImageInline({src:u,inline:v,alt:g}).run(),s(!1),L(C),j(""),k("")}function B(I){var H;I.preventDefault(),(H=p.current)==null||H.click()}return n?i.jsx(i.Fragment,{}):i.jsx(me,{onOpenChange:I=>{s(I),I||a(!1)},open:o,children:i.jsxs(oe,{className:l?"richtext-hidden":void 0,children:[i.jsx(se,{children:e("editor.image.dialog.title")}),i.jsxs(ze,{activationMode:"manual",defaultValue:b.resourceImage==="both"||b.resourceImage==="upload"?"upload":"link",children:[b.resourceImage==="both"&&i.jsxs(ye,{className:"richtext-grid richtext-w-full richtext-grid-cols-2",children:[i.jsx(Z,{value:"upload",children:e("editor.image.dialog.tab.upload")}),i.jsx(Z,{value:"link",children:e("editor.image.dialog.tab.url")})]}),i.jsxs("div",{className:"richtext-my-[10px] richtext-flex richtext-items-center richtext-gap-[4px]",children:[i.jsx(Ae,{checked:v,onCheckedChange:I=>{L(I)}}),i.jsx(ue,{children:e("editor.link.dialog.inline")})]}),b.enableAlt&&i.jsxs("div",{className:"richtext-my-[10px]",children:[i.jsx(ue,{className:"mb-[6px]",children:e("editor.imageUpload.alt")}),i.jsx(te,{onChange:I=>k(I.target.value),required:!0,type:"text",value:g})]}),i.jsxs(K,{value:"upload",children:[i.jsxs("div",{className:"richtext-flex richtext-items-center richtext-gap-[10px]",children:[i.jsx(W,{className:"richtext-mt-1 richtext-w-full",disabled:h,onClick:B,size:"sm",children:h?i.jsxs(i.Fragment,{children:[e("editor.imageUpload.uploading"),i.jsx(ce,{className:"richtext-ml-1 richtext-animate-spin",name:"Loader"})]}):e("editor.image.dialog.tab.upload")}),i.jsx(Yt,{alt:g,disabled:h,editor:r,imageInline:v,onClose:()=>{s(!1),a(!1),k(""),L(C)},onOpenChange:a})]}),i.jsx("input",{accept:b.acceptMimes.join(",")||"image/*",multiple:b.multiple,onChange:z,ref:p,style:{display:"none"},type:"file"})]}),i.jsx(K,{value:"link",children:i.jsx("form",{onSubmit:y,children:i.jsxs("div",{className:"richtext-flex richtext-items-center richtext-gap-2",children:[i.jsx(te,{autoFocus:!0,onChange:I=>j(I.target.value),placeholder:e("editor.image.dialog.placeholder"),required:!0,type:"url",value:u}),i.jsx(W,{type:"submit",children:e("editor.image.dialog.button.apply")})]})})})]})]})})}function Zt(e,t){let r;try{r=new URL(e)}catch{return!1}return!(t!=null&&t.length)||t.length===1&&t[0]==="."?!0:t.some(n=>{if(n.includes("*")){const o=n.replace(/\./g,String.raw`\.`).replace(/\*/g,".*");return new RegExp(`^${o}$`).test(r.hostname)}return r.hostname.includes(n)})}function bn(){const{t:e}=G.useLocale(),t=Q(),r=it(Ne.name),{icon:n,tooltip:o}=(r==null?void 0:r.componentProps)??{},{editorDisabled:s}=je(),[l,a]=m.useState(""),d=m.useRef(null),[h,x]=m.useState(""),[w,u]=m.useState(!1),j=ae(Ne.name),g=m.useMemo(()=>(j==null?void 0:j.options)??{},[j]);async function k(v){var y;const L=(y=v==null?void 0:v.target)==null?void 0:y.files;if(!t||t.isDestroyed||L.length===0)return;const b=L[0];let z="";g.upload?z=await g.upload(b):z=URL.createObjectURL(b),t.chain().focus().setVideo({src:z,width:"100%"}).run(),u(!1)}function p(v){v.preventDefault(),v.stopPropagation(),l&&(t.chain().focus().setVideo({src:l,width:"100%"}).run(),u(!1),a(""))}function C(v){var L;v.preventDefault(),(L=d.current)==null||L.click()}return i.jsxs(me,{onOpenChange:u,open:w,children:[i.jsx(Ee,{asChild:!0,children:i.jsx(Xe,{disabled:s,icon:n,tooltip:o,action:()=>{s||u(!0)}})}),i.jsxs(oe,{children:[i.jsx(se,{children:e("editor.video.dialog.title")}),i.jsxs(ze,{activationMode:"manual",defaultValue:(g==null?void 0:g.resourceVideo)==="both"||(g==null?void 0:g.resourceVideo)==="upload"?"upload":"link",children:[i.jsxs(ye,{className:"richtext-grid richtext-w-full richtext-grid-cols-2",children:[((g==null?void 0:g.resourceVideo)==="both"||(g==null?void 0:g.resourceVideo)==="upload")&&i.jsx(Z,{value:"upload",children:e("editor.video.dialog.tab.upload")}),((g==null?void 0:g.resourceVideo)==="both"||(g==null?void 0:g.resourceVideo)==="link")&&i.jsx(Z,{value:"link",children:e("editor.video.dialog.link")})]}),i.jsxs(K,{value:"upload",children:[i.jsx("div",{className:"richtext-flex richtext-items-center richtext-gap-[10px]",children:i.jsx(W,{className:"richtext-mt-1 richtext-w-full",onClick:C,size:"sm",children:e("editor.video.dialog.tab.upload")})}),i.jsx("input",{accept:"video/*",multiple:!0,onChange:k,ref:d,type:"file",style:{display:"none"}})]}),i.jsxs(K,{value:"link",children:[i.jsx("div",{children:i.jsxs("div",{className:"richtext-flex richtext-items-center richtext-gap-2",children:[i.jsx(te,{autoFocus:!0,placeholder:e("editor.video.dialog.placeholder"),required:!0,type:"url",value:l,onBlur:v=>{const L=v.target.value,b=g.videoProviders||["."];L&&!Zt(L,b)?x("Invalid video URL"):x("")},onChange:v=>{a(v.target.value)}}),i.jsx(W,{onClick:p,type:"button",children:e("editor.video.dialog.button.apply")})]})}),h&&i.jsx("div",{className:"richtext-my-[5px] richtext-text-red-500",children:h})]})]})]})]})}function vn(e){e=e.replace("https://youtu.be/","https://www.youtube.com/watch?v=").replace("watch?v=","embed/");const t=e.match(/^https:\/\/www\.youtube\.com\/shorts\/([a-zA-Z0-9_-]+)/);t&&(e=`https://www.youtube.com/embed/${t[1]}`);const r=e.match(/^https:\/\/vimeo\.com\/(\d+)(?:\/([a-zA-Z0-9]+))?/);if(r){const o=r[1],s=r[2];s?e=`https://player.vimeo.com/video/${o}?h=${s}`:e=`https://player.vimeo.com/video/${o}`}return/^https?:\/\/www.bilibili.com\/video\/.*/i.test(e)&&(e=e.replace(/\?.*$/,"").replace("https://www.bilibili.com/video/","https://player.bilibili.com/player.html?bvid=")),e.includes("drive.google.com")&&(e=e.replace("/view","/preview")),e}const Ne=ie.Node3.create({name:"video",group:"block",atom:!0,draggable:!0,addOptions(){return{divider:!1,spacer:!1,allowFullscreen:!0,upload:void 0,frameborder:!1,resourceVideo:"both",width:G.VIDEO_SIZE["size-medium"],HTMLAttributes:{class:"iframe-wrapper"},button:({editor:e,t})=>{var r,n;return{componentProps:{action:()=>{},isActive:()=>e.isActive("video")||!1,disabled:!((n=(r=e.can()).setVideo)!=null&&n.call(r,{})),icon:"Video",tooltip:t("editor.video.tooltip"),videoProviders:["."],editor:e}}}}},addAttributes(){return{src:{default:null,renderHTML:({src:e})=>({src:e?vn(e):null})},width:{default:this.options.width,renderHTML:({width:e})=>({width:an(e)})},frameborder:{default:this.options.frameborder?1:0,parseHTML:()=>this.options.frameborder?1:0},allowfullscreen:{default:this.options.allowFullscreen,parseHTML:()=>this.options.allowFullscreen},align:{default:"center",renderHTML:({align:e})=>({align:e})}}},parseHTML(){return[{tag:"div[data-video] iframe"}]},renderHTML({HTMLAttributes:e}){const{width:t="100%",align:r="center"}=e??{},n={...e,width:"100%",height:"100%"},o=`position: relative;overflow: hidden;display: flex;flex: 1;max-width: ${t};`,s=`flex: 1;padding-bottom: ${9/16*100}%;`,x=["div",{style:`display: flex; justify-content: ${r};`},["div",{style:o},["div",{style:s}],["iframe",n]]];return["div",{...this.options.HTMLAttributes,class:"iframe-wrapper","data-video":""},x]},addCommands(){return{setVideo:e=>({commands:t})=>t.insertContent({type:this.name,attrs:e}),updateVideo:e=>({commands:t})=>t.updateAttributes(this.name,e)}}});function wn(){const{t:e}=G.useLocale(),t=Q(),{editorDisabled:r}=je(),[n,o]=m.useState(""),s=m.useRef(null),[l,a]=m.useState(""),[d,h]=m.useState(!1),x=ae(Ne.name),w=ot.UPLOAD_VIDEO(t.id);et(h,[w]);const u=m.useMemo(()=>(x==null?void 0:x.options)??{},[x]);async function j(p){var b;const C=(b=p==null?void 0:p.target)==null?void 0:b.files;if(!t||t.isDestroyed||C.length===0)return;const v=C[0];let L="";u.upload?L=await u.upload(v):L=URL.createObjectURL(v),t.chain().focus().setVideo({src:L,width:"100%"}).run(),h(!1)}function g(p){p.preventDefault(),p.stopPropagation(),n&&(t.chain().focus().setVideo({src:n,width:"100%"}).run(),h(!1),o(""))}function k(p){var C;p.preventDefault(),(C=s.current)==null||C.click()}return r?i.jsx(i.Fragment,{}):i.jsx(me,{onOpenChange:h,open:d,children:i.jsxs(oe,{children:[i.jsx(se,{children:e("editor.video.dialog.title")}),i.jsxs(ze,{activationMode:"manual",defaultValue:(u==null?void 0:u.resourceVideo)==="both"||(u==null?void 0:u.resourceVideo)==="upload"?"upload":"link",children:[i.jsxs(ye,{className:"richtext-grid richtext-w-full richtext-grid-cols-2",children:[((u==null?void 0:u.resourceVideo)==="both"||(u==null?void 0:u.resourceVideo)==="upload")&&i.jsx(Z,{value:"upload",children:e("editor.video.dialog.tab.upload")}),((u==null?void 0:u.resourceVideo)==="both"||(u==null?void 0:u.resourceVideo)==="link")&&i.jsx(Z,{value:"link",children:e("editor.video.dialog.link")})]}),i.jsxs(K,{value:"upload",children:[i.jsx("div",{className:"richtext-flex richtext-items-center richtext-gap-[10px]",children:i.jsx(W,{className:"richtext-mt-1 richtext-w-full",onClick:k,size:"sm",children:e("editor.video.dialog.tab.upload")})}),i.jsx("input",{accept:"video/*",multiple:!0,onChange:j,ref:s,type:"file",style:{display:"none"}})]}),i.jsxs(K,{value:"link",children:[i.jsx("div",{children:i.jsxs("div",{className:"richtext-flex richtext-items-center richtext-gap-2",children:[i.jsx(te,{autoFocus:!0,placeholder:e("editor.video.dialog.placeholder"),required:!0,type:"url",value:n,onBlur:p=>{const C=p.target.value,v=u.videoProviders||["."];C&&!Zt(C,v)?a("Invalid video URL"):a("")},onChange:p=>{o(p.target.value)}}),i.jsx(W,{onClick:g,type:"button",children:e("editor.video.dialog.button.apply")})]})}),l&&i.jsx("div",{className:"richtext-my-[5px] richtext-text-red-500",children:l})]})]})]})})}function Kt(){return i.jsxs(i.Fragment,{children:[i.jsx(pn,{}),i.jsx(wn,{})]})}process.env.NODE_ENV!=="production"&&(Kt.displayName="SlashDialogTrigger");exports.ActionButton=Xe;exports.Button=W;exports.Checkbox=Ae;exports.DEFAULT_OPTIONS=Re;exports.Dialog=me;exports.DialogContent=oe;exports.DialogFooter=tt;exports.DialogHeader=Pt;exports.DialogTitle=se;exports.DialogTrigger=Ee;exports.EVENTS=ot;exports.ExportPdf=kt;exports.ExportWord=Tt;exports.IconComponent=ce;exports.Image=ve;exports.Input=te;exports.Label=ue;exports.MenuDown=St;exports.ReactBusProvider=yi;exports.RichTextImage=un;exports.RichTextVideo=bn;exports.Select=ci;exports.SelectContent=Et;exports.SelectItem=Rt;exports.SelectTrigger=zt;exports.SelectValue=di;exports.SlashDialogTrigger=Kt;exports.Textarea=Mt;exports.Toggle=Ke;exports.Tooltip=It;exports.TooltipContent=Qe;exports.TooltipProvider=li;exports.TooltipTrigger=Nt;exports.Video=Ne;exports.clamp=rn;exports.clamp$1=Ft;exports.cn=R;exports.dataURLtoFile=Xt;exports.debounce=$t;exports.emit=wi;exports.ensureNameValueOptions=cn;exports.extractFileExtension=mn;exports.extractFilename=hn;exports.getShortcutKey=jt;exports.getShortcutKeys=Ct;exports.hasExtension=ln;exports.icons=Ye;exports.index_default=Ht;exports.isNumber=$e;exports.normalizeFileSize=fn;exports.normalizeFileType=xn;exports.throttle=We;exports.useActive=tn;exports.useButtonProps=it;exports.useEditableEditor=rt;exports.useEditorInstance=Q;exports.useExtension=ae;exports.useListener=et;exports.useStoreEditableEditor=en;exports.useToast=Le;exports.useToggleActive=je;
|
package/lib/index.cjs
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const o=require("react/jsx-runtime"),C=require("./clsx-
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const o=require("react/jsx-runtime"),C=require("./clsx-DRbkQ4T7.cjs"),l=require("react"),d=require("./index-aujjnfSJ.cjs"),f=require("./theme.cjs"),M=`
|
|
2
2
|
.reactjs-tiptap-editor {
|
|
3
3
|
button,
|
|
4
4
|
input:where([type=button]),
|
package/lib/index.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { jsx as s, Fragment as f, jsxs as
|
|
2
|
-
import { E as
|
|
1
|
+
import { jsx as s, Fragment as f, jsxs as j } from "react/jsx-runtime";
|
|
2
|
+
import { E as N } from "./clsx-_bq4MQQ7.js";
|
|
3
3
|
import { useEffect as l, useId as M } from "react";
|
|
4
|
-
import {
|
|
4
|
+
import { U as P, V as A, W as $, X as O } from "./index-C52cuQ_Y.js";
|
|
5
5
|
import { useTheme as D, THEME as m } from "./theme.js";
|
|
6
6
|
const H = `
|
|
7
7
|
.reactjs-tiptap-editor {
|
|
@@ -160,8 +160,8 @@ function y(e, n = {}) {
|
|
|
160
160
|
const p = x(u).filter((b) => {
|
|
161
161
|
if (!["prepend", "prependQueue"].includes(b.getAttribute(g)))
|
|
162
162
|
return !1;
|
|
163
|
-
const
|
|
164
|
-
return r >=
|
|
163
|
+
const T = Number(b.getAttribute(E) || 0);
|
|
164
|
+
return r >= T;
|
|
165
165
|
});
|
|
166
166
|
if (p.length > 0)
|
|
167
167
|
return u.insertBefore(i, p.at(-1).nextSibling), i;
|
|
@@ -196,7 +196,7 @@ function C(e, n, t = {}) {
|
|
|
196
196
|
const a = y(e, t);
|
|
197
197
|
return a.setAttribute(v(t), n), a;
|
|
198
198
|
}
|
|
199
|
-
function
|
|
199
|
+
function V() {
|
|
200
200
|
const { theme: e, color: n, borderRadius: t } = D();
|
|
201
201
|
return l(() => {
|
|
202
202
|
const o = e || "light", r = n || "default";
|
|
@@ -223,19 +223,19 @@ function Y() {
|
|
|
223
223
|
};
|
|
224
224
|
}, [e, n, t]), /* @__PURE__ */ s(f, {});
|
|
225
225
|
}
|
|
226
|
-
function
|
|
226
|
+
function W({ editor: e, children: n }) {
|
|
227
227
|
const t = M();
|
|
228
228
|
return l(() => (C(H, "react-tiptap-reset"), () => {
|
|
229
229
|
w("react-tiptap-reset");
|
|
230
230
|
}), []), l(() => {
|
|
231
231
|
e && (e.id = t);
|
|
232
|
-
}, [t, e]), e ? /* @__PURE__ */ s("div", { className: "reactjs-tiptap-editor", children: /* @__PURE__ */ s(A, { children: /* @__PURE__ */
|
|
233
|
-
/* @__PURE__ */ s(
|
|
232
|
+
}, [t, e]), e ? /* @__PURE__ */ s("div", { className: "reactjs-tiptap-editor", children: /* @__PURE__ */ s(A, { children: /* @__PURE__ */ j(N.Provider, { value: { editor: e }, children: [
|
|
233
|
+
/* @__PURE__ */ s($, { delayDuration: 0, disableHoverableContent: !0, children: n }),
|
|
234
234
|
/* @__PURE__ */ s(L, { editor: e }),
|
|
235
|
-
/* @__PURE__ */ s(
|
|
236
|
-
/* @__PURE__ */ s(
|
|
235
|
+
/* @__PURE__ */ s(O, {}),
|
|
236
|
+
/* @__PURE__ */ s(V, {})
|
|
237
237
|
] }) }) }) : /* @__PURE__ */ s(f, {});
|
|
238
238
|
}
|
|
239
239
|
export {
|
|
240
|
-
|
|
240
|
+
W as RichTextProvider
|
|
241
241
|
};
|
|
@@ -5,7 +5,9 @@ var s = (n, r) => {
|
|
|
5
5
|
return n(r);
|
|
6
6
|
const { children: e, ...o } = r ?? {};
|
|
7
7
|
if (n === "svg")
|
|
8
|
-
throw new Error(
|
|
8
|
+
throw new Error(
|
|
9
|
+
"SVG elements are not supported in the JSX syntax, use the array syntax instead"
|
|
10
|
+
);
|
|
9
11
|
return [n, o, e];
|
|
10
12
|
};
|
|
11
13
|
export {
|
package/lib/locale-bundle.cjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("./index-
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("./index-BpLw6ebr.cjs");exports.en=e.locale;exports.fi=e.locale$1;exports.hu_HU=e.locale$2;exports.ja=e.locale$3;exports.localeActions=e.localeActions;exports.pt_BR=e.locale$4;exports.useLocale=e.useLocale;exports.vi=e.locale$5;exports.zh_CN=e.locale$6;
|
package/lib/locale-bundle.js
CHANGED
package/lib/locales/index.d.ts
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import { default as en } from './en';
|
|
2
2
|
import { default as fi } from './fi';
|
|
3
3
|
import { default as hu_HU } from './hu';
|
|
4
|
+
import { default as ja } from './ja';
|
|
4
5
|
import { default as pt_BR } from './pt-br';
|
|
5
6
|
import { default as vi } from './vi';
|
|
6
7
|
import { default as zh_CN } from './zh-cn';
|
|
7
|
-
import { default as ja } from './ja';
|
|
8
8
|
declare const LANG: {
|
|
9
9
|
currentLang: string;
|
|
10
10
|
message: {
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { jsx as e } from "react/jsx-runtime";
|
|
2
2
|
import * as t from "@radix-ui/react-popover";
|
|
3
3
|
import * as c from "react";
|
|
4
|
-
import { c as s } from "./index-
|
|
4
|
+
import { c as s } from "./index-C52cuQ_Y.js";
|
|
5
5
|
const x = t.Root, p = t.Trigger, n = c.forwardRef(({ className: o, align: r = "center", sideOffset: i = 4, ...a }, d) => /* @__PURE__ */ e(t.Portal, { children: /* @__PURE__ */ e(
|
|
6
6
|
t.Content,
|
|
7
7
|
{
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";const a=require("react/jsx-runtime"),d=require("@radix-ui/react-popover"),p=require("react"),h=require("./index-
|
|
1
|
+
"use strict";const a=require("react/jsx-runtime"),d=require("@radix-ui/react-popover"),p=require("react"),h=require("./index-aujjnfSJ.cjs");function n(t){const r=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(t){for(const e in t)if(e!=="default"){const i=Object.getOwnPropertyDescriptor(t,e);Object.defineProperty(r,e,i.get?i:{enumerable:!0,get:()=>t[e]})}}return r.default=t,Object.freeze(r)}const o=n(d),l=n(p),x=o.Root,m=o.Trigger,c=l.forwardRef(({className:t,align:r="center",sideOffset:e=4,...i},s)=>a.jsx(o.Portal,{children:a.jsx(o.Content,{align:r,"data-richtext-portal":!0,ref:s,sideOffset:e,className:h.cn("richtext-z-50 richtext-w-72 richtext-rounded-md !richtext-border !richtext-border-border richtext-bg-popover richtext-p-4 richtext-text-popover-foreground richtext-shadow-md richtext-outline-none data-[state=open]:richtext-animate-in data-[state=closed]:richtext-animate-out data-[state=closed]:richtext-fade-out-0 data-[state=open]:richtext-fade-in-0 data-[state=closed]:richtext-zoom-out-95 data-[state=open]:richtext-zoom-in-95 data-[side=bottom]:richtext-slide-in-from-top-2 data-[side=left]:richtext-slide-in-from-right-2 data-[side=right]:richtext-slide-in-from-left-2 data-[side=top]:richtext-slide-in-from-bottom-2",t),...i})}));c.displayName=o.Content.displayName;exports.Popover=x;exports.PopoverContent=c;exports.PopoverTrigger=m;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";const i=require("./clsx-
|
|
1
|
+
"use strict";const i=require("./clsx-DRbkQ4T7.cjs"),r=require("./updatePosition-B1oRJE1x.cjs");function d(o){return()=>{let e;return{onStart:t=>{t.clientRect&&(e=new i.ReactRenderer(o,{props:t,editor:t.editor}),e.element.style.position="absolute",document.body.appendChild(e.element),r.updatePosition(t.editor,e.element))},onUpdate(t){e.updateProps(t),t.clientRect&&r.updatePosition(t.editor,e.element)},onKeyDown(t){var n;return t.event.key==="Escape"?(e.destroy(),e.element.remove(),!0):(n=e.ref)==null?void 0:n.onKeyDown(t)},onExit(){e.destroy(),e.element.remove()}}}}exports.renderNodeViewClosure=d;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
"use strict";const e=require("react/jsx-runtime"),E=require("lucide-react"),n=require("react"),P=require("react-colorful"),j=require("./index-
|
|
1
|
+
"use strict";const e=require("react/jsx-runtime"),E=require("lucide-react"),n=require("react"),P=require("react-colorful"),j=require("./index-aujjnfSJ.cjs");require("./theme.cjs");const v=require("./popover-CrywEkBR.cjs"),O=require("@radix-ui/react-separator"),C=require("./index-BpLw6ebr.cjs");function N(t){const r=Object.create(null,{[Symbol.toStringTag]:{value:"Module"}});if(t){for(const c in t)if(c!=="default"){const h=Object.getOwnPropertyDescriptor(t,c);Object.defineProperty(r,c,h.get?h:{enumerable:!0,get:()=>t[c]})}}return r.default=t,Object.freeze(r)}const y=N(n),z=N(O);function R(){return e.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",width:"1em",height:"1em",viewBox:"0 0 24 24",children:e.jsx("path",{fill:"currentColor",d:"M18 14c0-4-6-10.8-6-10.8s-1.33 1.51-2.73 3.52l8.59 8.59c.09-.42.14-.86.14-1.31m-.88 3.12L12.5 12.5L5.27 5.27L4 6.55l3.32 3.32C6.55 11.32 6 12.79 6 14c0 3.31 2.69 6 6 6c1.52 0 2.9-.57 3.96-1.5l2.63 2.63l1.27-1.27z"})})}const w=typeof window>"u";function L(t,r,c=window){const h=n.useRef(void 0);n.useEffect(()=>{h.current=r},[r]),n.useEffect(()=>{if(!(c&&c.addEventListener))return;const f=x=>{h.current&&h.current(x)};return c.addEventListener(t,f),()=>{c.removeEventListener(t,f)}},[t,c])}function _(t,r,c={}){const{initializeWithValue:h=!0}=c,i=n.useCallback(o=>c.serializer?c.serializer(o):JSON.stringify(o),[c]),f=n.useCallback(o=>{if(c.deserializer)return c.deserializer(o);if(o==="undefined")return;const l=r instanceof Function?r():r;let s;try{s=JSON.parse(o)}catch(a){return console.error("Error parsing JSON:",a),l}return s},[c,r]),x=n.useCallback(()=>{const o=r instanceof Function?r():r;if(w)return o;try{const l=window.localStorage.getItem(t);return l?f(l):o}catch(l){return console.warn(`Error reading localStorage key “${t}”:`,l),o}},[r,t,f]),[d,p]=n.useState(()=>h?x():r instanceof Function?r():r),b=n.useCallback(o=>{w&&console.warn(`Tried setting localStorage key “${t}” even though environment is not a client`);try{const l=o instanceof Function?o(x()):o;window.localStorage.setItem(t,i(l)),p(l),window.dispatchEvent(new StorageEvent("local-storage",{key:t}))}catch(l){console.warn(`Error setting localStorage key “${t}”:`,l)}},[t,i,x]),g=n.useCallback(()=>{w&&console.warn(`Tried removing localStorage key “${t}” even though environment is not a client`);const o=r instanceof Function?r():r;window.localStorage.removeItem(t),p(o),window.dispatchEvent(new StorageEvent("local-storage",{key:t}))},[t,r]);n.useEffect(()=>{p(x())},[t]);const m=n.useCallback(o=>{o.key&&o.key!==t||p(x())},[t,x]);return L("storage",m),L("local-storage",m),[d,b,g]}function q(t){const{t:r}=C.useLocale(),{disabled:c=!1,value:h,onChange:i,colors:f=C.COLORS_LIST,highlight:x}=t,[d,p]=n.useState(!1),b=n.useMemo(()=>{const s=f,a=[];for(let u=0;u<s.length;u+=10)a.push(s.slice(u,u+10));return a},[f]),[g,m]=_(x?"richtext-recent-highlight":"richtext-recent-colors",[]),o=s=>{const a=[...g],u=a.indexOf(s);u!==-1&&a.splice(u,1),a.unshift(s),a.length>10&&a.pop(),m(a)};function l(s){if(s===void 0){i==null||i(s),p(!1);return}/^#([\da-f]{3}){1,2}$/i.test(s)&&(i==null||i(s),o(s),p(!1))}return e.jsxs(v.Popover,{modal:!0,onOpenChange:p,open:d,children:[e.jsx(v.PopoverTrigger,{asChild:!0,className:"!richtext-p-0",disabled:c,children:t==null?void 0:t.children}),e.jsx(v.PopoverContent,{align:"start",className:"richtext-size-full !richtext-p-2",hideWhenDetached:!0,side:"bottom",children:e.jsxs("div",{className:"richtext-flex richtext-flex-col",children:[e.jsxs("div",{className:"rd-1 richtext-flex richtext-cursor-pointer richtext-items-center richtext-gap-[4px] richtext-p-1 hover:richtext-bg-accent",onClick:()=>{l(void 0)},children:[e.jsx(R,{}),e.jsx("span",{className:"richtext-ml-1 richtext-text-sm",children:r(x?"editor.nofill":"editor.default")})]}),b.map((s,a)=>e.jsx("span",{className:"richtext-relative richtext-flex richtext-h-auto richtext-w-full richtext-p-0 last:richtext-pb-2",children:s.map((u,k)=>e.jsx("span",{className:"richtext-inline-block richtext-size-6 richtext-flex-[0_0_auto] richtext-cursor-pointer richtext-rounded-sm !richtext-border richtext-border-solid !richtext-border-transparent richtext-p-0.5 hover:!richtext-border-border",onClick:()=>l(u),children:e.jsx("span",{className:"richtext-relative richtext-block richtext-size-[18px] richtext-rounded-[2px]",style:{backgroundColor:u},children:u===h?e.jsx("svg",{className:"richtext-absolute -richtext-top-px richtext-left-px richtext-block richtext-size-3",viewBox:"0 0 18 18",style:{fill:"rgb(255, 255, 255)"},children:e.jsx("path",{d:"M21,7L9,19L3.5,13.5L4.91,12.09L9,16.17L19.59,5.59L21,7Z"})}):e.jsx("svg",{viewBox:"0 0 18 18",style:{fill:"rgb(255, 255, 255)",display:"none"},children:e.jsx("path",{d:"M21,7L9,19L3.5,13.5L4.91,12.09L9,16.17L19.59,5.59L21,7Z"})})})},`sub-color-${k}`))},`color-row-${a}`)),e.jsxs("div",{children:[e.jsx("div",{className:"richtext-my-1 richtext-text-sm",children:r("editor.recent")}),e.jsx("span",{className:"richtext-relative richtext-flex richtext-h-auto richtext-w-full richtext-flex-wrap richtext-p-0 last:richtext-pb-2",children:g==null?void 0:g.map((s,a)=>e.jsx("span",{className:"richtext-inline-block richtext-size-6 richtext-flex-[0_0_auto] richtext-cursor-pointer richtext-rounded-sm !richtext-border richtext-border-transparent richtext-p-0.5 hover:richtext-border-border hover:richtext-shadow-sm",onClick:()=>l(s),children:e.jsx("span",{className:"richtext-relative richtext-block richtext-size-[18px] richtext-rounded-[2px] richtext-border-transparent",style:{backgroundColor:s},children:e.jsx("svg",{viewBox:"0 0 18 18",style:{fill:"rgb(255, 255, 255)",display:"none"},children:e.jsx("path",{d:"M21,7L9,19L3.5,13.5L4.91,12.09L9,16.17L19.59,5.59L21,7Z"})})})},`sub-color-recent-${a}`))})]}),e.jsx(M,{setColor:l})]})})]})}function M({setColor:t}){const{t:r}=C.useLocale(),[c,h]=n.useState(!1),[i,f]=n.useState("#000000"),x=n.useCallback(d=>{f(d)},[]);return e.jsxs(v.Popover,{onOpenChange:h,open:c,children:[e.jsx(v.PopoverTrigger,{asChild:!0,children:e.jsxs("div",{className:"richtext-p-1.5 richtext-text-sm hover:richtext-cursor-pointer hover:richtext-bg-accent",children:[r("editor.color.more"),"..."]})}),e.jsxs(v.PopoverContent,{children:[e.jsxs("div",{className:"richtext-flex richtext-flex-col richtext-items-center richtext-justify-center",children:[e.jsx(P.HexColorPicker,{color:i,onChange:d=>{x(d)}}),e.jsx(j.Input,{className:"richtext-mt-[8px] richtext-w-full",type:"text",value:i.replace("#",""),onChange:d=>{d.preventDefault(),d.stopPropagation(),x(`#${d.target.value}`)}})]}),e.jsx(S,{className:"richtext-my-[10px]"}),e.jsx(j.Button,{className:"richtext-w-full",onClick:d=>{d.preventDefault(),d.stopPropagation(),t(i),h(!1)},children:e.jsx(E.Plus,{size:16})})]})]})}const S=y.forwardRef(({className:t,orientation:r="horizontal",decorative:c=!0,...h},i)=>e.jsx(z.Root,{ref:i,decorative:c,orientation:r,className:j.cn("richtext-shrink-0 richtext-bg-border",r==="horizontal"?"richtext-h-[1px] richtext-w-full":"richtext-h-full richtext-w-[1px]",t),...h}));S.displayName=z.Root.displayName;exports.ColorPicker=q;exports.Separator=S;
|
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
import { jsx as t, jsxs as p } from "react/jsx-runtime";
|
|
2
|
-
import { Plus as
|
|
2
|
+
import { Plus as P } from "lucide-react";
|
|
3
3
|
import * as $ from "react";
|
|
4
4
|
import { useCallback as m, useState as w, useEffect as L, useRef as M, useMemo as B } from "react";
|
|
5
5
|
import { HexColorPicker as F } from "react-colorful";
|
|
6
|
-
import {
|
|
6
|
+
import { k as I, B as _, c as T } from "./index-C52cuQ_Y.js";
|
|
7
7
|
import "./theme.js";
|
|
8
|
-
import {
|
|
9
|
-
import
|
|
10
|
-
import
|
|
8
|
+
import { P as N, a as z, b as E } from "./popover-BB-ZDnqk.js";
|
|
9
|
+
import * as y from "@radix-ui/react-separator";
|
|
10
|
+
import { u as R, C as j } from "./index-DtyAGMbq.js";
|
|
11
11
|
function D() {
|
|
12
12
|
return /* @__PURE__ */ t("svg", { xmlns: "http://www.w3.org/2000/svg", width: "1em", height: "1em", viewBox: "0 0 24 24", children: /* @__PURE__ */ t(
|
|
13
13
|
"path",
|
|
@@ -102,7 +102,7 @@ function J(e, r, c = {}) {
|
|
|
102
102
|
return S("storage", v), S("local-storage", v), [h, b, g];
|
|
103
103
|
}
|
|
104
104
|
function X(e) {
|
|
105
|
-
const { t: r } =
|
|
105
|
+
const { t: r } = R(), { disabled: c = !1, value: d, onChange: n, colors: u = j, highlight: a } = e, [h, f] = w(!1), b = B(() => {
|
|
106
106
|
const i = u, l = [];
|
|
107
107
|
for (let x = 0; x < i.length; x += 10)
|
|
108
108
|
l.push(i.slice(x, x + 10));
|
|
@@ -121,10 +121,10 @@ function X(e) {
|
|
|
121
121
|
}
|
|
122
122
|
/^#([\da-f]{3}){1,2}$/i.test(i) && (n == null || n(i), o(i), f(!1));
|
|
123
123
|
}
|
|
124
|
-
return /* @__PURE__ */ p(
|
|
125
|
-
/* @__PURE__ */ t(
|
|
124
|
+
return /* @__PURE__ */ p(N, { modal: !0, onOpenChange: f, open: h, children: [
|
|
125
|
+
/* @__PURE__ */ t(z, { asChild: !0, className: "!richtext-p-0", disabled: c, children: e == null ? void 0 : e.children }),
|
|
126
126
|
/* @__PURE__ */ t(
|
|
127
|
-
|
|
127
|
+
E,
|
|
128
128
|
{
|
|
129
129
|
align: "start",
|
|
130
130
|
className: "richtext-size-full !richtext-p-2",
|
|
@@ -148,7 +148,7 @@ function X(e) {
|
|
|
148
148
|
"span",
|
|
149
149
|
{
|
|
150
150
|
className: "richtext-relative richtext-flex richtext-h-auto richtext-w-full richtext-p-0 last:richtext-pb-2",
|
|
151
|
-
children: i.map((x,
|
|
151
|
+
children: i.map((x, O) => /* @__PURE__ */ t(
|
|
152
152
|
"span",
|
|
153
153
|
{
|
|
154
154
|
className: "richtext-inline-block richtext-size-6 richtext-flex-[0_0_auto] richtext-cursor-pointer richtext-rounded-sm !richtext-border richtext-border-solid !richtext-border-transparent richtext-p-0.5 hover:!richtext-border-border",
|
|
@@ -184,7 +184,7 @@ function X(e) {
|
|
|
184
184
|
}
|
|
185
185
|
)
|
|
186
186
|
},
|
|
187
|
-
`sub-color-${
|
|
187
|
+
`sub-color-${O}`
|
|
188
188
|
))
|
|
189
189
|
},
|
|
190
190
|
`color-row-${l}`
|
|
@@ -227,15 +227,15 @@ function X(e) {
|
|
|
227
227
|
] });
|
|
228
228
|
}
|
|
229
229
|
function Z({ setColor: e }) {
|
|
230
|
-
const { t: r } =
|
|
230
|
+
const { t: r } = R(), [c, d] = w(!1), [n, u] = w("#000000"), a = m((h) => {
|
|
231
231
|
u(h);
|
|
232
232
|
}, []);
|
|
233
|
-
return /* @__PURE__ */ p(
|
|
234
|
-
/* @__PURE__ */ t(
|
|
233
|
+
return /* @__PURE__ */ p(N, { onOpenChange: d, open: c, children: [
|
|
234
|
+
/* @__PURE__ */ t(z, { asChild: !0, children: /* @__PURE__ */ p("div", { className: "richtext-p-1.5 richtext-text-sm hover:richtext-cursor-pointer hover:richtext-bg-accent", children: [
|
|
235
235
|
r("editor.color.more"),
|
|
236
236
|
"..."
|
|
237
237
|
] }) }),
|
|
238
|
-
/* @__PURE__ */ p(
|
|
238
|
+
/* @__PURE__ */ p(E, { children: [
|
|
239
239
|
/* @__PURE__ */ p("div", { className: "richtext-flex richtext-flex-col richtext-items-center richtext-justify-center", children: [
|
|
240
240
|
/* @__PURE__ */ t(
|
|
241
241
|
F,
|
|
@@ -258,7 +258,7 @@ function Z({ setColor: e }) {
|
|
|
258
258
|
}
|
|
259
259
|
)
|
|
260
260
|
] }),
|
|
261
|
-
/* @__PURE__ */ t(
|
|
261
|
+
/* @__PURE__ */ t(k, { className: "richtext-my-[10px]" }),
|
|
262
262
|
/* @__PURE__ */ t(
|
|
263
263
|
_,
|
|
264
264
|
{
|
|
@@ -266,14 +266,14 @@ function Z({ setColor: e }) {
|
|
|
266
266
|
onClick: (h) => {
|
|
267
267
|
h.preventDefault(), h.stopPropagation(), e(n), d(!1);
|
|
268
268
|
},
|
|
269
|
-
children: /* @__PURE__ */ t(
|
|
269
|
+
children: /* @__PURE__ */ t(P, { size: 16 })
|
|
270
270
|
}
|
|
271
271
|
)
|
|
272
272
|
] })
|
|
273
273
|
] });
|
|
274
274
|
}
|
|
275
|
-
const
|
|
276
|
-
|
|
275
|
+
const k = $.forwardRef(({ className: e, orientation: r = "horizontal", decorative: c = !0, ...d }, n) => /* @__PURE__ */ t(
|
|
276
|
+
y.Root,
|
|
277
277
|
{
|
|
278
278
|
ref: n,
|
|
279
279
|
decorative: c,
|
|
@@ -286,8 +286,8 @@ const O = $.forwardRef(({ className: e, orientation: r = "horizontal", decorativ
|
|
|
286
286
|
...d
|
|
287
287
|
}
|
|
288
288
|
));
|
|
289
|
-
|
|
289
|
+
k.displayName = y.Root.displayName;
|
|
290
290
|
export {
|
|
291
291
|
X as C,
|
|
292
|
-
|
|
292
|
+
k as S
|
|
293
293
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export declare function EditorEditableReactive({ editor }: any): import("react
|
|
1
|
+
export declare function EditorEditableReactive({ editor }: any): import("react").JSX.Element;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export declare function ThemeColorReactive(): import("react
|
|
1
|
+
export declare function ThemeColorReactive(): import("react").JSX.Element;
|