@chaibuilder/sdk 1.2.52 → 1.2.53

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.
Files changed (62) hide show
  1. package/dist/{AddBlocks-fozauzIV.cjs → AddBlocks-7OJEZC2D.cjs} +1 -1
  2. package/dist/{AddBlocks-GxEmM16E.js → AddBlocks-kJNH96eQ.js} +1 -1
  3. package/dist/{CanvasArea-rdY6SFYn.js → CanvasArea-ZxrQurg_.js} +3 -3
  4. package/dist/{CanvasArea-NRtblq5d.cjs → CanvasArea-nWHWl6zD.cjs} +2 -2
  5. package/dist/{ChaiBuilderEditor-bNZZWYMh.js → ChaiBuilderEditor-4xhn_QlL.js} +2 -2
  6. package/dist/{ChaiBuilderEditor-Pga_zJgw.cjs → ChaiBuilderEditor-Rqlg194T.cjs} +1 -1
  7. package/dist/{CodeEditor-ye3IXW3i.cjs → CodeEditor-C6p5CZfl.cjs} +1 -1
  8. package/dist/{CodeEditor-tqtgia3I.js → CodeEditor-vTWgHJei.js} +1 -1
  9. package/dist/{CurrentPage-7NM90y76.js → CurrentPage-KPr8MnO0.js} +2 -2
  10. package/dist/{CurrentPage-sx7KVTmt.cjs → CurrentPage-bfY5xyr7.cjs} +1 -1
  11. package/dist/{ListTree-7Pz6H6eE.cjs → ListTree-4J0SUudU.cjs} +1 -1
  12. package/dist/{ListTree-oRbeDNod.js → ListTree-5s7iNbKT.js} +1 -1
  13. package/dist/{PagesPanel-XiTUaiq_.js → PagesPanel-aZBPSLS7.js} +3 -3
  14. package/dist/{PagesPanel-Nr-908vy.cjs → PagesPanel-re4w2009.cjs} +1 -1
  15. package/dist/{ProjectPanel-XfknsGkz.js → ProjectPanel-bWZtA_mw.js} +3 -3
  16. package/dist/{ProjectPanel-SuFYN60H.cjs → ProjectPanel-uo19SCtW.cjs} +1 -1
  17. package/dist/Settings-AcK9rEs3.cjs +1 -0
  18. package/dist/{Settings-dJ72rwnH.js → Settings-SK2ONoi0.js} +795 -805
  19. package/dist/{SidePanels-5dnRAsJh.cjs → SidePanels-YAKKqxIi.cjs} +1 -1
  20. package/dist/{SidePanels-t9oUA51J.js → SidePanels-ezU-hGki.js} +2 -2
  21. package/dist/{ThemeConfiguration-pcHbYiIP.js → ThemeConfiguration-q5rLYmXB.js} +1 -1
  22. package/dist/{ThemeConfiguration-2Sbh29qi.cjs → ThemeConfiguration-qUXsJBBZ.cjs} +1 -1
  23. package/dist/{Topbar-ID6Ipphd.cjs → Topbar-9mJ6dJn-.cjs} +1 -1
  24. package/dist/{Topbar-0DmS6VpB.js → Topbar-YhJ6xVs-.js} +1 -1
  25. package/dist/{UILibrariesPanel-G9J4KUsZ.js → UILibrariesPanel-N7acP7aA.js} +1 -1
  26. package/dist/{UILibrariesPanel-sXY6hozJ.cjs → UILibrariesPanel-uNt8spPr.cjs} +1 -1
  27. package/dist/{UnsplashImages-HK4_1VVL.cjs → UnsplashImages-5IlwWgRv.cjs} +1 -1
  28. package/dist/{UnsplashImages-MeS5Cu7a.js → UnsplashImages-iY__3dsJ.js} +1 -1
  29. package/dist/{UploadImages-AIKATqfP.js → UploadImages-KHk-jx9-.js} +1 -1
  30. package/dist/{UploadImages-LSnxByGV.cjs → UploadImages-UjtFHUqM.cjs} +1 -1
  31. package/dist/{add-page-modal-krxKdX7-.cjs → add-page-modal-8GuYgZa-.cjs} +1 -1
  32. package/dist/{add-page-modal-JkD45moJ.js → add-page-modal-HmfsbbCH.js} +3 -3
  33. package/dist/{confirm-alert-NHxthdRK.js → confirm-alert-AoUx_ZEf.js} +1 -1
  34. package/dist/{confirm-alert--QTC21Z2.cjs → confirm-alert-qdryZAvd.cjs} +1 -1
  35. package/dist/core.cjs +1 -1
  36. package/dist/core.js +1 -1
  37. package/dist/{delete-page-modal-BIe0kYNH.cjs → delete-page-modal-8qEY88SK.cjs} +1 -1
  38. package/dist/{delete-page-modal-8rjPEchH.js → delete-page-modal-KCPx8Ako.js} +2 -2
  39. package/dist/email.cjs +1 -1
  40. package/dist/email.js +1 -1
  41. package/dist/{form-PQYPrD_Q.js → form-LHHE25z8.js} +1 -1
  42. package/dist/{form-6OLp5uEG.cjs → form-zHGQEmOp.cjs} +1 -1
  43. package/dist/{index-seU0_UZX.cjs → index-swYRuZtl.cjs} +1 -1
  44. package/dist/{index-9_b2eou7.js → index-tGVTszX2.js} +2 -2
  45. package/dist/{page-viewer-sKluQ_e1.js → page-viewer-P5yNaWy1.js} +3 -3
  46. package/dist/{page-viewer-WwwMC1Kq.cjs → page-viewer-t9AFrRlP.cjs} +1 -1
  47. package/dist/{project-general-setting-pRO1ikDV.cjs → project-general-setting-Ojhf6Nl6.cjs} +1 -1
  48. package/dist/{project-general-setting-Lc2ByvTt.js → project-general-setting-Qm8odisi.js} +3 -3
  49. package/dist/{project-seo-setting-BzSrXFVv.cjs → project-seo-setting-4E1mqV3j.cjs} +1 -1
  50. package/dist/{project-seo-setting-530_6o9S.js → project-seo-setting-j8EdSO40.js} +2 -2
  51. package/dist/{single-page-detail-_VP4zaCI.cjs → single-page-detail-bv-XFGOD.cjs} +1 -1
  52. package/dist/{single-page-detail-qDxxtedN.js → single-page-detail-mQfFVaou.js} +4 -4
  53. package/dist/studio.cjs +1 -1
  54. package/dist/studio.js +2 -2
  55. package/dist/ui.cjs +1 -1
  56. package/dist/ui.js +1 -1
  57. package/dist/{useCanvasSettings-pURFQG4q.cjs → useCanvasSettings-4WtrDzCu.cjs} +1 -1
  58. package/dist/{useCanvasSettings-5y2fSCpN.js → useCanvasSettings-Rvn5rRB8.js} +1 -1
  59. package/dist/web-blocks.cjs +1 -1
  60. package/dist/web-blocks.js +241 -195
  61. package/package.json +1 -1
  62. package/dist/Settings-22Hy7jUT.cjs +0 -1
@@ -1 +1 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("./jsx-runtime-Z_BpKhVy.cjs"),u=require("react"),t=require("lodash-es"),h=require("jotai"),E=require("react-i18next"),s=require("./ChaiBuilderEditor-Pga_zJgw.cjs"),b=require("@radix-ui/react-icons"),R=require("@chaibuilder/runtime"),T=require("flagged"),q=require("./MODIFIERS-mVmfEGgo.cjs"),N=require("./atoms-a0H_593V.cjs"),k=require("./html-to-json-9uiQ2Dp2.cjs");require("./_commonjsHelpers-wDK0ZLPo.cjs");require("clsx");require("react-dom");require("@radix-ui/react-scroll-area");require("@floating-ui/react-dom");require("i18next");require("./Functions-N3yhPYKY.cjs");require("tailwind-merge");require("@react-hookz/web");require("tree-model");require("./utils-D_vtk3zK.cjs");require("@radix-ui/react-toggle");require("class-variance-authority");require("@radix-ui/react-switch");require("@radix-ui/react-slot");require("@radix-ui/react-accordion");require("@radix-ui/react-alert-dialog");require("@radix-ui/react-dialog");require("@radix-ui/react-label");require("@radix-ui/react-tabs");require("@radix-ui/react-tooltip");require("@radix-ui/react-popover");require("@radix-ui/react-menubar");require("@radix-ui/react-hover-card");require("@radix-ui/react-select");require("@radix-ui/react-dropdown-menu");require("@radix-ui/react-separator");require("@radix-ui/react-toast");require("cmdk");require("@radix-ui/react-context-menu");require("react-icons-picker");require("react-quill");require("react-hotkeys-hook");require("lucide-react");require("./index--mLLy7QQ.cjs");require("himalaya");const y=({block:r})=>{const[,i]=h.useAtom(N.draggedBlockAtom),{type:l,icon:c,label:d}=r,{addCoreBlock:p,addPredefinedBlock:j}=s.useAddBlock(),[o,g]=s.useSelectedBlockIds(),[,f]=s.useHighlightBlockId(),[,x]=h.useAtom(s.activePanelAtom),a=()=>{if(t.has(r,"blocks")){const m=t.isFunction(r.blocks)?r.blocks():r.blocks;j(R.syncBlocksWithDefaults(m),t.first(o))}else p(r,t.first(o));x(q.OUTLINE_KEY)},n=T.useFeature("dnd");return e.jsxRuntimeExports.jsx(e.jsxRuntimeExports.Fragment,{children:e.jsxRuntimeExports.jsxs(s.Tooltip,{children:[e.jsxRuntimeExports.jsx(s.TooltipTrigger,{asChild:!0,children:e.jsxRuntimeExports.jsxs("button",{onClick:a,type:"button",onDragStart:m=>{m.dataTransfer.setData("text/plain",JSON.stringify(t.omit(r,["component","icon"]))),m.dataTransfer.setDragImage(new Image,0,0),i(t.omit(r,["component","icon"])),setTimeout(()=>{g([]),f(null),x(q.OUTLINE_KEY)},200)},draggable:"true",className:"space-y-2 rounded-lg border border-border p-3 text-center hover:bg-slate-300/50 "+(n?"cursor-grab":"cursor-pointer"),children:[u.createElement(c||b.BoxIcon,{className:"w-4 h-4 mx-auto"}),e.jsxRuntimeExports.jsx("p",{className:"text-xs",children:d||l})]})}),e.jsxRuntimeExports.jsx(s.TooltipContent,{children:e.jsxRuntimeExports.jsx("p",{children:d||l})})]})})},B=()=>{const{t:r}=E.useTranslation(),[i,l]=u.useState(""),{addPredefinedBlock:c}=s.useAddBlock(),[d]=s.useSelectedBlockIds(),[,p]=h.useAtom(s.activePanelAtom),j=()=>{const o=k.getBlocksFromHTML(i);c([...o],t.first(d)||null),l(""),p(q.OUTLINE_KEY)};return e.jsxRuntimeExports.jsxs(s.Card,{className:"border-border/0 p-0 shadow-none",children:[e.jsxRuntimeExports.jsx(s.CardHeader,{className:"p-3",children:e.jsxRuntimeExports.jsx(s.CardDescription,{children:r("html_snippet_description")})}),e.jsxRuntimeExports.jsx(s.CardContent,{className:"space-y-2 px-3 py-0",children:e.jsxRuntimeExports.jsxs("div",{className:"space-y-1",children:[e.jsxRuntimeExports.jsx(s.Label,{htmlFor:"current",className:"text-sm",children:r("tailwind_html_snippet")}),e.jsxRuntimeExports.jsx(s.Textarea,{autoFocus:!0,tabIndex:1,ref:o=>o&&o.focus(),onChange:o=>l(o.target.value),rows:12,value:i,placeholder:r("enter_code_snippet"),className:"resize-none overflow-x-auto whitespace-pre bg-gray-100 font-mono text-xs font-normal"})]})}),e.jsxRuntimeExports.jsxs(s.CardFooter,{className:"flex flex-col justify-end p-3",children:[e.jsxRuntimeExports.jsx(s.Button,{disabled:i.trim()==="",onClick:()=>j(),size:"sm",className:"w-full",children:r("import_html")}),e.jsxRuntimeExports.jsx(s.Alert,{variant:"default",className:"mt-2 border-none p-1 text-gray-400",children:e.jsxRuntimeExports.jsx(s.AlertTitle,{className:"text-xs font-normal leading-4",children:r("note_imported_html")})})]})]})},v=()=>{const{t:r}=E.useTranslation(),[i,l]=u.useState("core"),[c,d]=u.useState("basic"),p=R.useChaiBlocks(),[,j]=h.useAtom(s.showPredefinedBlockCategoryAtom),o=s.useBuilderProp("importHTMLSupport",!0),g=s.useBuilderProp("filterChaiBlock",()=>!0),f=t.filter(p,g),x=t.groupBy(f,"category"),a=t.uniq(t.map(x.core,"group"));return u.useEffect(()=>{!t.includes(a,c)&&!t.isEmpty(a)&&!t.isEmpty(c)&&d(t.first(a))},[a,c]),e.jsxRuntimeExports.jsxs("div",{className:"flex h-full w-72 flex-col overflow-hidden",children:[e.jsxRuntimeExports.jsxs("div",{className:"mb-2 flex flex-col justify-between rounded-md bg-background/30 p-1",children:[e.jsxRuntimeExports.jsx("h1",{className:"flex flex-col items-baseline px-1 text-xl font-semibold xl:flex-col",children:r("add_block")}),e.jsxRuntimeExports.jsx("span",{className:"p-0 text-xs font-light leading-3 opacity-80 xl:pl-1",children:r(i==="html"?"enter_paste_tailwind_html":"click_to_add_block")})]}),e.jsxRuntimeExports.jsx(s.Tabs,{onValueChange:n=>{j(""),l(n)},value:i,className:"h-max",children:e.jsxRuntimeExports.jsxs(s.TabsList,{className:"grid w-full "+(o?"grid-cols-2":"grid-cols-1"),children:[e.jsxRuntimeExports.jsx(s.TabsTrigger,{value:"core",children:r("Blocks")}),o?e.jsxRuntimeExports.jsx(s.TabsTrigger,{value:"html",children:r("import")}):null]})}),i==="core"&&e.jsxRuntimeExports.jsx(s.ScrollArea,{className:"-mx-1.5 h-[calc(100vh-156px)] overflow-y-auto",children:e.jsxRuntimeExports.jsx("div",{className:"mt-2 w-full",children:u.Children.toArray(t.map(a,n=>t.reject(t.filter(t.values(x.core),{group:n}),{hidden:!0}).length?e.jsxRuntimeExports.jsx(s.Accordion,{type:"single",value:n,collapsible:!0,className:"w-full",children:e.jsxRuntimeExports.jsxs(s.AccordionItem,{value:n,children:[e.jsxRuntimeExports.jsx(s.AccordionTrigger,{className:"rounded-md bg-gray-100 px-4 py-2 capitalize",children:n}),e.jsxRuntimeExports.jsx(s.AccordionContent,{className:"p-3",children:e.jsxRuntimeExports.jsx("div",{className:"grid grid-cols-3 gap-2",children:u.Children.toArray(t.reject(t.filter(t.values(x.core),{group:n}),{hidden:!0}).map(m=>e.jsxRuntimeExports.jsx(y,{block:m})))})})]})}):null))})}),i==="html"&&o?e.jsxRuntimeExports.jsx(B,{}):null]})};exports.default=v;
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("./jsx-runtime-Z_BpKhVy.cjs"),u=require("react"),t=require("lodash-es"),h=require("jotai"),E=require("react-i18next"),s=require("./ChaiBuilderEditor-Rqlg194T.cjs"),b=require("@radix-ui/react-icons"),R=require("@chaibuilder/runtime"),T=require("flagged"),q=require("./MODIFIERS-mVmfEGgo.cjs"),N=require("./atoms-a0H_593V.cjs"),k=require("./html-to-json-9uiQ2Dp2.cjs");require("./_commonjsHelpers-wDK0ZLPo.cjs");require("clsx");require("react-dom");require("@radix-ui/react-scroll-area");require("@floating-ui/react-dom");require("i18next");require("./Functions-N3yhPYKY.cjs");require("tailwind-merge");require("@react-hookz/web");require("tree-model");require("./utils-D_vtk3zK.cjs");require("@radix-ui/react-toggle");require("class-variance-authority");require("@radix-ui/react-switch");require("@radix-ui/react-slot");require("@radix-ui/react-accordion");require("@radix-ui/react-alert-dialog");require("@radix-ui/react-dialog");require("@radix-ui/react-label");require("@radix-ui/react-tabs");require("@radix-ui/react-tooltip");require("@radix-ui/react-popover");require("@radix-ui/react-menubar");require("@radix-ui/react-hover-card");require("@radix-ui/react-select");require("@radix-ui/react-dropdown-menu");require("@radix-ui/react-separator");require("@radix-ui/react-toast");require("cmdk");require("@radix-ui/react-context-menu");require("react-icons-picker");require("react-quill");require("react-hotkeys-hook");require("lucide-react");require("./index--mLLy7QQ.cjs");require("himalaya");const y=({block:r})=>{const[,i]=h.useAtom(N.draggedBlockAtom),{type:l,icon:c,label:d}=r,{addCoreBlock:p,addPredefinedBlock:j}=s.useAddBlock(),[o,g]=s.useSelectedBlockIds(),[,f]=s.useHighlightBlockId(),[,x]=h.useAtom(s.activePanelAtom),a=()=>{if(t.has(r,"blocks")){const m=t.isFunction(r.blocks)?r.blocks():r.blocks;j(R.syncBlocksWithDefaults(m),t.first(o))}else p(r,t.first(o));x(q.OUTLINE_KEY)},n=T.useFeature("dnd");return e.jsxRuntimeExports.jsx(e.jsxRuntimeExports.Fragment,{children:e.jsxRuntimeExports.jsxs(s.Tooltip,{children:[e.jsxRuntimeExports.jsx(s.TooltipTrigger,{asChild:!0,children:e.jsxRuntimeExports.jsxs("button",{onClick:a,type:"button",onDragStart:m=>{m.dataTransfer.setData("text/plain",JSON.stringify(t.omit(r,["component","icon"]))),m.dataTransfer.setDragImage(new Image,0,0),i(t.omit(r,["component","icon"])),setTimeout(()=>{g([]),f(null),x(q.OUTLINE_KEY)},200)},draggable:"true",className:"space-y-2 rounded-lg border border-border p-3 text-center hover:bg-slate-300/50 "+(n?"cursor-grab":"cursor-pointer"),children:[u.createElement(c||b.BoxIcon,{className:"w-4 h-4 mx-auto"}),e.jsxRuntimeExports.jsx("p",{className:"text-xs",children:d||l})]})}),e.jsxRuntimeExports.jsx(s.TooltipContent,{children:e.jsxRuntimeExports.jsx("p",{children:d||l})})]})})},B=()=>{const{t:r}=E.useTranslation(),[i,l]=u.useState(""),{addPredefinedBlock:c}=s.useAddBlock(),[d]=s.useSelectedBlockIds(),[,p]=h.useAtom(s.activePanelAtom),j=()=>{const o=k.getBlocksFromHTML(i);c([...o],t.first(d)||null),l(""),p(q.OUTLINE_KEY)};return e.jsxRuntimeExports.jsxs(s.Card,{className:"border-border/0 p-0 shadow-none",children:[e.jsxRuntimeExports.jsx(s.CardHeader,{className:"p-3",children:e.jsxRuntimeExports.jsx(s.CardDescription,{children:r("html_snippet_description")})}),e.jsxRuntimeExports.jsx(s.CardContent,{className:"space-y-2 px-3 py-0",children:e.jsxRuntimeExports.jsxs("div",{className:"space-y-1",children:[e.jsxRuntimeExports.jsx(s.Label,{htmlFor:"current",className:"text-sm",children:r("tailwind_html_snippet")}),e.jsxRuntimeExports.jsx(s.Textarea,{autoFocus:!0,tabIndex:1,ref:o=>o&&o.focus(),onChange:o=>l(o.target.value),rows:12,value:i,placeholder:r("enter_code_snippet"),className:"resize-none overflow-x-auto whitespace-pre bg-gray-100 font-mono text-xs font-normal"})]})}),e.jsxRuntimeExports.jsxs(s.CardFooter,{className:"flex flex-col justify-end p-3",children:[e.jsxRuntimeExports.jsx(s.Button,{disabled:i.trim()==="",onClick:()=>j(),size:"sm",className:"w-full",children:r("import_html")}),e.jsxRuntimeExports.jsx(s.Alert,{variant:"default",className:"mt-2 border-none p-1 text-gray-400",children:e.jsxRuntimeExports.jsx(s.AlertTitle,{className:"text-xs font-normal leading-4",children:r("note_imported_html")})})]})]})},v=()=>{const{t:r}=E.useTranslation(),[i,l]=u.useState("core"),[c,d]=u.useState("basic"),p=R.useChaiBlocks(),[,j]=h.useAtom(s.showPredefinedBlockCategoryAtom),o=s.useBuilderProp("importHTMLSupport",!0),g=s.useBuilderProp("filterChaiBlock",()=>!0),f=t.filter(p,g),x=t.groupBy(f,"category"),a=t.uniq(t.map(x.core,"group"));return u.useEffect(()=>{!t.includes(a,c)&&!t.isEmpty(a)&&!t.isEmpty(c)&&d(t.first(a))},[a,c]),e.jsxRuntimeExports.jsxs("div",{className:"flex h-full w-72 flex-col overflow-hidden",children:[e.jsxRuntimeExports.jsxs("div",{className:"mb-2 flex flex-col justify-between rounded-md bg-background/30 p-1",children:[e.jsxRuntimeExports.jsx("h1",{className:"flex flex-col items-baseline px-1 text-xl font-semibold xl:flex-col",children:r("add_block")}),e.jsxRuntimeExports.jsx("span",{className:"p-0 text-xs font-light leading-3 opacity-80 xl:pl-1",children:r(i==="html"?"enter_paste_tailwind_html":"click_to_add_block")})]}),e.jsxRuntimeExports.jsx(s.Tabs,{onValueChange:n=>{j(""),l(n)},value:i,className:"h-max",children:e.jsxRuntimeExports.jsxs(s.TabsList,{className:"grid w-full "+(o?"grid-cols-2":"grid-cols-1"),children:[e.jsxRuntimeExports.jsx(s.TabsTrigger,{value:"core",children:r("Blocks")}),o?e.jsxRuntimeExports.jsx(s.TabsTrigger,{value:"html",children:r("import")}):null]})}),i==="core"&&e.jsxRuntimeExports.jsx(s.ScrollArea,{className:"-mx-1.5 h-[calc(100vh-156px)] overflow-y-auto",children:e.jsxRuntimeExports.jsx("div",{className:"mt-2 w-full",children:u.Children.toArray(t.map(a,n=>t.reject(t.filter(t.values(x.core),{group:n}),{hidden:!0}).length?e.jsxRuntimeExports.jsx(s.Accordion,{type:"single",value:n,collapsible:!0,className:"w-full",children:e.jsxRuntimeExports.jsxs(s.AccordionItem,{value:n,children:[e.jsxRuntimeExports.jsx(s.AccordionTrigger,{className:"rounded-md bg-gray-100 px-4 py-2 capitalize",children:n}),e.jsxRuntimeExports.jsx(s.AccordionContent,{className:"p-3",children:e.jsxRuntimeExports.jsx("div",{className:"grid grid-cols-3 gap-2",children:u.Children.toArray(t.reject(t.filter(t.values(x.core),{group:n}),{hidden:!0}).map(m=>e.jsxRuntimeExports.jsx(y,{block:m})))})})]})}):null))})}),i==="html"&&o?e.jsxRuntimeExports.jsx(B,{}):null]})};exports.default=v;
@@ -3,7 +3,7 @@ import k, { createElement as D, useState as b, useEffect as L } from "react";
3
3
  import { has as S, isFunction as E, first as h, omit as N, filter as g, groupBy as F, uniq as H, map as B, includes as M, isEmpty as y, reject as C, values as v } from "lodash-es";
4
4
  import { useAtom as x } from "jotai";
5
5
  import { useTranslation as A } from "react-i18next";
6
- import { n as w, L as I, D as q, ag as P, ac as z, ad as O, ae as R, bl as G, bm as J, bn as K, bo as U, aD as V, bb as W, bp as Y, B as Q, bq as X, br as Z, bs as $, h as T, ai as ee, aj as te, ak as _, bg as se, b6 as oe, b7 as re, b8 as ae, b9 as le } from "./ChaiBuilderEditor-bNZZWYMh.js";
6
+ import { n as w, L as I, D as q, ag as P, ac as z, ad as O, ae as R, bl as G, bm as J, bn as K, bo as U, aD as V, bb as W, bp as Y, B as Q, bq as X, br as Z, bs as $, h as T, ai as ee, aj as te, ak as _, bg as se, b6 as oe, b7 as re, b8 as ae, b9 as le } from "./ChaiBuilderEditor-4xhn_QlL.js";
7
7
  import { BoxIcon as ie } from "@radix-ui/react-icons";
8
8
  import { syncBlocksWithDefaults as ce, useChaiBlocks as ne } from "@chaibuilder/runtime";
9
9
  import { useFeature as de } from "flagged";
@@ -5,7 +5,7 @@ import { j as r } from "./jsx-runtime-WbnYoNE9.js";
5
5
  import A, { createElement as ce, useCallback as O, useState as B, useEffect as j, Component as $e, Children as ze, Suspense as J, useRef as de, useMemo as Oe } from "react";
6
6
  import { map as H, includes as pe, toUpper as X, round as Ue, throttle as ye, has as be, isEmpty as I, first as U, omit as We, pick as qe, get as f, isString as se, memoize as Ke, each as Ye, find as Ge, filter as ke, isNull as Xe } from "lodash-es";
7
7
  import { ResetIcon as ue, SunIcon as Qe, MobileIcon as he, LaptopIcon as Ze, DesktopIcon as Je, DotsVerticalIcon as Ve, EraserIcon as et, ZoomInIcon as tt, DragHandleDots2Icon as st, ArrowUpIcon as ot, CopyIcon as nt, TrashIcon as rt } from "@radix-ui/react-icons";
8
- import { k as we, B as W, w as je, aq as Ce, ar as it, as as at, at as lt, au as ct, p as oe, X as dt, h as P, av as pt, aw as ut, ax as ht, ay as mt, az as gt, aA as ft, aB as _e, L as D, Y as M, A as xt, a as vt, b as $t, c as yt, d as bt, e as kt, f as wt, g as jt, a3 as Ct, aC as _t, aD as Bt, q as Be, ap as z, aE as Dt, n as At, D as T, aF as De, Q as It, aG as F, aH as St, j as ne, x as Ae, F as Ie, H as Se, V as Et, aI as Nt, aJ as Mt, aK as Tt, G as Lt, aL as Ft, aM as Rt, aN as Ht, aO as Pt, M as zt, aP as Ot, ah as V, i as Ut, a2 as Wt } from "./ChaiBuilderEditor-bNZZWYMh.js";
8
+ import { k as we, B as W, w as je, aq as Ce, ar as it, as as at, at as lt, au as ct, p as oe, X as dt, h as P, av as pt, aw as ut, ax as ht, ay as mt, az as gt, aA as ft, aB as _e, L as D, Y as M, A as xt, a as vt, b as $t, c as yt, d as bt, e as kt, f as wt, g as jt, a3 as Ct, aC as _t, aD as Bt, q as Be, ap as z, aE as Dt, n as At, D as T, aF as De, Q as It, aG as F, aH as St, j as ne, x as Ae, F as Ie, H as Se, V as Et, aI as Nt, aJ as Mt, aK as Tt, G as Lt, aL as Ft, aM as Rt, aN as Ht, aO as Pt, M as zt, aP as Ot, ah as V, i as Ut, a2 as Wt } from "./ChaiBuilderEditor-4xhn_QlL.js";
9
9
  import { useTranslation as re } from "react-i18next";
10
10
  import { useAtom as b } from "jotai";
11
11
  import { SparklesIcon as qt } from "lucide-react";
@@ -24,7 +24,7 @@ import ts from "tailwindcss-palette-generator";
24
24
  import { twMerge as ss } from "tailwind-merge";
25
25
  import { S as ge, a as Ne } from "./MODIFIERS-fd5XOmum.js";
26
26
  import { getBlockComponent as os } from "@chaibuilder/runtime";
27
- import { u as ns } from "./useCanvasSettings-5y2fSCpN.js";
27
+ import { u as ns } from "./useCanvasSettings-Rvn5rRB8.js";
28
28
  import { Provider as rs } from "react-wrap-balancer";
29
29
  import { Resizable as is } from "re-resizable";
30
30
  import "./_commonjsHelpers-UyOWmZb0.js";
@@ -1225,7 +1225,7 @@ const Ps = () => {
1225
1225
  )
1226
1226
  }
1227
1227
  );
1228
- }, Us = A.lazy(() => import("./CodeEditor-tqtgia3I.js")), Go = () => {
1228
+ }, Us = A.lazy(() => import("./CodeEditor-vTWgHJei.js")), Go = () => {
1229
1229
  const [n] = Ut();
1230
1230
  return /* @__PURE__ */ r.jsxs("div", { className: "flex h-full w-full flex-col", children: [
1231
1231
  /* @__PURE__ */ r.jsx(hs, {}),
@@ -1,4 +1,4 @@
1
- "use strict";var ne=Object.defineProperty;var oe=(o,s,e)=>s in o?ne(o,s,{enumerable:!0,configurable:!0,writable:!0,value:e}):o[s]=e;var I=(o,s,e)=>(oe(o,typeof s!="symbol"?s+"":s,e),e);Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const r=require("./jsx-runtime-Z_BpKhVy.cjs"),x=require("react"),c=require("lodash-es"),R=require("@radix-ui/react-icons"),i=require("./ChaiBuilderEditor-Pga_zJgw.cjs"),U=require("react-i18next"),k=require("jotai"),re=require("lucide-react"),Y=require("react-dom"),w=require("prop-types"),ie=require("react-quill"),M=require("./atoms-a0H_593V.cjs"),le=require("@floating-ui/dom"),G=require("@floating-ui/react-dom"),ce=require("@react-hookz/web"),ae=require("flagged"),de=require("@tailwindcss/typography"),ue=require("@tailwindcss/forms"),pe=require("@tailwindcss/aspect-ratio"),xe=require("tailwindcss-palette-generator"),he=require("tailwind-merge"),T=require("./MODIFIERS-mVmfEGgo.cjs"),me=require("@chaibuilder/runtime"),ge=require("./useCanvasSettings-pURFQG4q.cjs"),fe=require("react-wrap-balancer"),ve=require("re-resizable");require("./_commonjsHelpers-wDK0ZLPo.cjs");require("clsx");require("@radix-ui/react-scroll-area");require("i18next");require("./Functions-N3yhPYKY.cjs");require("tree-model");require("./utils-D_vtk3zK.cjs");require("@radix-ui/react-toggle");require("class-variance-authority");require("@radix-ui/react-switch");require("@radix-ui/react-slot");require("@radix-ui/react-accordion");require("@radix-ui/react-alert-dialog");require("@radix-ui/react-dialog");require("@radix-ui/react-label");require("@radix-ui/react-tabs");require("@radix-ui/react-tooltip");require("@radix-ui/react-popover");require("@radix-ui/react-menubar");require("@radix-ui/react-hover-card");require("@radix-ui/react-select");require("@radix-ui/react-dropdown-menu");require("@radix-ui/react-separator");require("@radix-ui/react-toast");require("cmdk");require("@radix-ui/react-context-menu");require("react-icons-picker");require("react-hotkeys-hook");require("./index--mLLy7QQ.cjs");const je=()=>{const{hasUndo:o,hasRedo:s,undo:e,redo:t}=i.useUndoManager();return r.jsxRuntimeExports.jsxs("div",{className:"flex items-center",children:[r.jsxRuntimeExports.jsx(i.Button,{disabled:!o(),size:"sm",onClick:e,className:"rounded-full",variant:"ghost",children:r.jsxRuntimeExports.jsx(R.ResetIcon,{})}),r.jsxRuntimeExports.jsx(i.Button,{disabled:!s(),onClick:t,size:"sm",className:"rounded-full",variant:"ghost",children:r.jsxRuntimeExports.jsx(R.ResetIcon,{className:"rotate-180 scale-y-[-1] transform"})})]})};function ye(){const[o,s]=i.useDarkMode();return r.jsxRuntimeExports.jsxs("div",{className:"flex items-center",children:[r.jsxRuntimeExports.jsx(R.SunIcon,{className:"size-4 shrink-0"}),r.jsxRuntimeExports.jsx(i.Switch,{id:"dark-mode-switch",checked:o,onCheckedChange:()=>{s(!o)},className:`${o?"bg-violet-600":"bg-violet-300"} relative ml-2 inline-flex h-[20px] w-[40px] shrink-0 cursor-pointer rounded-full border-2 border-transparent transition-colors duration-200 ease-in-out focus:outline-none focus-visible:ring-2 focus-visible:ring-white focus-visible:ring-opacity-75`,children:r.jsxRuntimeExports.jsx("span",{"aria-hidden":"true",className:`${o?"translate-x-5":"translate-x-0"} pointer-events-none -mt-px inline-block h-[18px] w-[20px] transform rounded-full bg-white shadow-lg ring-0 transition duration-200 ease-in-out`})}),r.jsxRuntimeExports.jsx(i.FaMoon,{className:"size-4 ml-3 shrink-0"})]})}const X=({landscape:o=!1})=>r.jsxRuntimeExports.jsxs("svg",{className:o?"rotate-90":"",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 13 13",xmlSpace:"preserve",width:13,height:13,children:[r.jsxRuntimeExports.jsx("g",{strokeWidth:0}),r.jsxRuntimeExports.jsx("g",{strokeLinecap:"round",strokeLinejoin:"round"}),r.jsxRuntimeExports.jsx("path",{d:"M10.65 0H2.349a.851.851 0 0 0-.851.852v11.299c0 .47.382.852.851.852h8.3a.851.851 0 0 0 .851-.852V.852A.851.851 0 0 0 10.65 0zM6.599 12.466a.367.367 0 1 1 0-.735.367.367 0 0 1 0 .735zm3.9-1.267H2.5V1h8.001v10.199z",style:{fill:"#000"}})]}),$e=[{title:"mobile_xs_title",content:"mobile_xs_content",breakpoint:"xs",icon:r.jsxRuntimeExports.jsx(R.MobileIcon,{}),width:400},{title:"mobile_sm_title",content:"mobile_sm_content",breakpoint:"sm",icon:r.jsxRuntimeExports.jsx(R.MobileIcon,{className:"rotate-90"}),width:640},{title:"tablet_md_title",content:"tablet_md_content",breakpoint:"md",icon:r.jsxRuntimeExports.jsx(X,{}),width:800},{title:"tablet_lg_title",content:"tablet_lg_content",breakpoint:"lg",icon:r.jsxRuntimeExports.jsx(X,{landscape:!0}),width:1024},{title:"desktop_xl_title",content:"desktop_xl_content",breakpoint:"xl",icon:r.jsxRuntimeExports.jsx(R.LaptopIcon,{}),width:1420},{title:"large_desktop_2xl_title",content:"large_desktop_2xl_content",breakpoint:"2xl",icon:r.jsxRuntimeExports.jsx(R.DesktopIcon,{}),width:1920}],Z=({title:o,content:s,currentBreakpoint:e,breakpoint:t,width:n,icon:u,onClick:a})=>{const{t:l}=U.useTranslation();return r.jsxRuntimeExports.jsxs(i.HoverCard,{children:[r.jsxRuntimeExports.jsx(i.HoverCardTrigger,{asChild:!0,children:r.jsxRuntimeExports.jsx(i.Button,{onClick:()=>a(n),size:"sm",variant:t===e?"secondary":"ghost",children:u})}),r.jsxRuntimeExports.jsx(i.HoverCardContent,{className:"w-52 border-border",children:r.jsxRuntimeExports.jsx("div",{className:"flex justify-between space-x-4",children:r.jsxRuntimeExports.jsxs("div",{className:"space-y-1",children:[r.jsxRuntimeExports.jsx("h4",{className:"text-sm font-semibold",children:l(o)}),r.jsxRuntimeExports.jsx("p",{className:"text-xs",children:l(s)})]})})})]})},be=()=>{const[,o,s]=i.useCanvasWidth(),[e,t]=i.useSelectedBreakpoints(),{t:n}=U.useTranslation(),u=i.useBuilderProp("breakpoints",$e),a=l=>{e.includes(l)?e.length>2&&t(e.filter(p=>p!==l)):t(p=>[...p,l])};return u.length<4?r.jsxRuntimeExports.jsx("div",{className:"flex items-center rounded-md",children:c.map(u,l=>x.createElement(Z,{...l,onClick:s,key:l.breakpoint,currentBreakpoint:o}))}):r.jsxRuntimeExports.jsxs("div",{className:"flex items-center rounded-md",children:[c.map(u.filter(l=>c.includes(e,c.toUpper(l.breakpoint))),l=>x.createElement(Z,{...l,onClick:s,key:l.breakpoint,currentBreakpoint:o})),r.jsxRuntimeExports.jsxs(i.DropdownMenu,{children:[r.jsxRuntimeExports.jsx(i.DropdownMenuTrigger,{asChild:!0,children:r.jsxRuntimeExports.jsx("span",{className:"cursor-pointer px-2.5 hover:opacity-80",children:r.jsxRuntimeExports.jsx(R.DotsVerticalIcon,{className:"scale-90 transform"})})}),r.jsxRuntimeExports.jsxs(i.DropdownMenuContent,{className:"w-56 border-border text-xs",children:[r.jsxRuntimeExports.jsx(i.DropdownMenuLabel,{children:n("Breakpoints")}),r.jsxRuntimeExports.jsx(i.DropdownMenuSeparator,{}),c.map(u,l=>r.jsxRuntimeExports.jsx(i.DropdownMenuCheckboxItem,{disabled:l.breakpoint==="xs",onCheckedChange:()=>a(c.toUpper(l.breakpoint)),checked:c.includes(e,c.toUpper(l.breakpoint)),children:n(l.title)},l.breakpoint))]})]})]})},ke=()=>{const{t:o}=U.useTranslation(),{setNewBlocks:s}=i.useBlocksStoreUndoableActions(),[,e]=i.useSelectedBlockIds(),[,t]=i.useSelectedStylingBlocks(),n=x.useCallback(()=>{s([]),e([]),t([])},[s]);return r.jsxRuntimeExports.jsx("div",{className:"flex items-center",children:r.jsxRuntimeExports.jsxs(i.AlertDialog,{children:[r.jsxRuntimeExports.jsx(i.AlertDialogTrigger,{asChild:!0,children:r.jsxRuntimeExports.jsxs(i.Button,{size:"sm",variant:"ghost",className:"flex items-center gap-x-1",children:[r.jsxRuntimeExports.jsx(R.EraserIcon,{})," ",o("clear")]})}),r.jsxRuntimeExports.jsxs(i.AlertDialogContent,{className:"border-border",children:[r.jsxRuntimeExports.jsxs(i.AlertDialogHeader,{children:[r.jsxRuntimeExports.jsx(i.AlertDialogTitle,{children:o("clear_canvas_title")}),r.jsxRuntimeExports.jsx(i.AlertDialogDescription,{children:o("clear_canvas_description")})]}),r.jsxRuntimeExports.jsxs(i.AlertDialogFooter,{children:[r.jsxRuntimeExports.jsx(i.AlertDialogCancel,{children:o("cancel")}),r.jsxRuntimeExports.jsx(i.AlertDialogAction,{onClick:n,children:o("yes")})]})]})]})})},Ee=()=>{const[o,s]=k.useAtom(i.aiAssistantActiveAtom);return i.useBuilderProp("askAiCallBack",null)?r.jsxRuntimeExports.jsxs("div",{className:"flex items-center space-x-2",children:[r.jsxRuntimeExports.jsxs(i.Label,{htmlFor:"ai-assistant",className:"flex items-center gap-x-1 text-sm text-yellow-600",children:[r.jsxRuntimeExports.jsx(re.SparklesIcon,{className:"w-4"}),"AI Assistant"]}),r.jsxRuntimeExports.jsx(i.Switch,{className:"scale-90",checked:o,onCheckedChange:t=>{s(t)},id:"ai-assitantt"})]}):null},Re=()=>{const o=i.useBuilderProp("darkMode",!0),[s]=i.useCanvasZoom();return r.jsxRuntimeExports.jsxs("div",{className:"flex h-10 items-center justify-between border-b bg-background/70 px-2",children:[r.jsxRuntimeExports.jsxs("div",{className:"flex h-full space-x-2",children:[r.jsxRuntimeExports.jsx(be,{}),r.jsxRuntimeExports.jsx(i.Separator,{orientation:"vertical"}),o?r.jsxRuntimeExports.jsxs(r.jsxRuntimeExports.Fragment,{children:[r.jsxRuntimeExports.jsx(ye,{}),r.jsxRuntimeExports.jsx(i.Separator,{orientation:"vertical"})]}):null,r.jsxRuntimeExports.jsxs("div",{className:"flex w-12 cursor-not-allowed items-center justify-center gap-x-1 space-x-0 font-medium text-gray-400",children:[r.jsxRuntimeExports.jsx(R.ZoomInIcon,{className:"h-3.5 w-3.5 flex-shrink-0"})," ",r.jsxRuntimeExports.jsxs("div",{className:"text-xs leading-3",children:[c.round(s,0),"%"]})]}),r.jsxRuntimeExports.jsx(i.Separator,{orientation:"vertical"}),r.jsxRuntimeExports.jsx(je,{})]}),r.jsxRuntimeExports.jsxs("div",{className:"flex h-full items-center space-x-2",children:[r.jsxRuntimeExports.jsx(ke,{}),r.jsxRuntimeExports.jsx(i.Separator,{orientation:"vertical"}),r.jsxRuntimeExports.jsx(Ee,{})]})]})},we=`<!doctype html>
1
+ "use strict";var ne=Object.defineProperty;var oe=(o,s,e)=>s in o?ne(o,s,{enumerable:!0,configurable:!0,writable:!0,value:e}):o[s]=e;var I=(o,s,e)=>(oe(o,typeof s!="symbol"?s+"":s,e),e);Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const r=require("./jsx-runtime-Z_BpKhVy.cjs"),x=require("react"),c=require("lodash-es"),R=require("@radix-ui/react-icons"),i=require("./ChaiBuilderEditor-Rqlg194T.cjs"),U=require("react-i18next"),k=require("jotai"),re=require("lucide-react"),Y=require("react-dom"),w=require("prop-types"),ie=require("react-quill"),M=require("./atoms-a0H_593V.cjs"),le=require("@floating-ui/dom"),G=require("@floating-ui/react-dom"),ce=require("@react-hookz/web"),ae=require("flagged"),de=require("@tailwindcss/typography"),ue=require("@tailwindcss/forms"),pe=require("@tailwindcss/aspect-ratio"),xe=require("tailwindcss-palette-generator"),he=require("tailwind-merge"),T=require("./MODIFIERS-mVmfEGgo.cjs"),me=require("@chaibuilder/runtime"),ge=require("./useCanvasSettings-4WtrDzCu.cjs"),fe=require("react-wrap-balancer"),ve=require("re-resizable");require("./_commonjsHelpers-wDK0ZLPo.cjs");require("clsx");require("@radix-ui/react-scroll-area");require("i18next");require("./Functions-N3yhPYKY.cjs");require("tree-model");require("./utils-D_vtk3zK.cjs");require("@radix-ui/react-toggle");require("class-variance-authority");require("@radix-ui/react-switch");require("@radix-ui/react-slot");require("@radix-ui/react-accordion");require("@radix-ui/react-alert-dialog");require("@radix-ui/react-dialog");require("@radix-ui/react-label");require("@radix-ui/react-tabs");require("@radix-ui/react-tooltip");require("@radix-ui/react-popover");require("@radix-ui/react-menubar");require("@radix-ui/react-hover-card");require("@radix-ui/react-select");require("@radix-ui/react-dropdown-menu");require("@radix-ui/react-separator");require("@radix-ui/react-toast");require("cmdk");require("@radix-ui/react-context-menu");require("react-icons-picker");require("react-hotkeys-hook");require("./index--mLLy7QQ.cjs");const je=()=>{const{hasUndo:o,hasRedo:s,undo:e,redo:t}=i.useUndoManager();return r.jsxRuntimeExports.jsxs("div",{className:"flex items-center",children:[r.jsxRuntimeExports.jsx(i.Button,{disabled:!o(),size:"sm",onClick:e,className:"rounded-full",variant:"ghost",children:r.jsxRuntimeExports.jsx(R.ResetIcon,{})}),r.jsxRuntimeExports.jsx(i.Button,{disabled:!s(),onClick:t,size:"sm",className:"rounded-full",variant:"ghost",children:r.jsxRuntimeExports.jsx(R.ResetIcon,{className:"rotate-180 scale-y-[-1] transform"})})]})};function ye(){const[o,s]=i.useDarkMode();return r.jsxRuntimeExports.jsxs("div",{className:"flex items-center",children:[r.jsxRuntimeExports.jsx(R.SunIcon,{className:"size-4 shrink-0"}),r.jsxRuntimeExports.jsx(i.Switch,{id:"dark-mode-switch",checked:o,onCheckedChange:()=>{s(!o)},className:`${o?"bg-violet-600":"bg-violet-300"} relative ml-2 inline-flex h-[20px] w-[40px] shrink-0 cursor-pointer rounded-full border-2 border-transparent transition-colors duration-200 ease-in-out focus:outline-none focus-visible:ring-2 focus-visible:ring-white focus-visible:ring-opacity-75`,children:r.jsxRuntimeExports.jsx("span",{"aria-hidden":"true",className:`${o?"translate-x-5":"translate-x-0"} pointer-events-none -mt-px inline-block h-[18px] w-[20px] transform rounded-full bg-white shadow-lg ring-0 transition duration-200 ease-in-out`})}),r.jsxRuntimeExports.jsx(i.FaMoon,{className:"size-4 ml-3 shrink-0"})]})}const X=({landscape:o=!1})=>r.jsxRuntimeExports.jsxs("svg",{className:o?"rotate-90":"",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 13 13",xmlSpace:"preserve",width:13,height:13,children:[r.jsxRuntimeExports.jsx("g",{strokeWidth:0}),r.jsxRuntimeExports.jsx("g",{strokeLinecap:"round",strokeLinejoin:"round"}),r.jsxRuntimeExports.jsx("path",{d:"M10.65 0H2.349a.851.851 0 0 0-.851.852v11.299c0 .47.382.852.851.852h8.3a.851.851 0 0 0 .851-.852V.852A.851.851 0 0 0 10.65 0zM6.599 12.466a.367.367 0 1 1 0-.735.367.367 0 0 1 0 .735zm3.9-1.267H2.5V1h8.001v10.199z",style:{fill:"#000"}})]}),$e=[{title:"mobile_xs_title",content:"mobile_xs_content",breakpoint:"xs",icon:r.jsxRuntimeExports.jsx(R.MobileIcon,{}),width:400},{title:"mobile_sm_title",content:"mobile_sm_content",breakpoint:"sm",icon:r.jsxRuntimeExports.jsx(R.MobileIcon,{className:"rotate-90"}),width:640},{title:"tablet_md_title",content:"tablet_md_content",breakpoint:"md",icon:r.jsxRuntimeExports.jsx(X,{}),width:800},{title:"tablet_lg_title",content:"tablet_lg_content",breakpoint:"lg",icon:r.jsxRuntimeExports.jsx(X,{landscape:!0}),width:1024},{title:"desktop_xl_title",content:"desktop_xl_content",breakpoint:"xl",icon:r.jsxRuntimeExports.jsx(R.LaptopIcon,{}),width:1420},{title:"large_desktop_2xl_title",content:"large_desktop_2xl_content",breakpoint:"2xl",icon:r.jsxRuntimeExports.jsx(R.DesktopIcon,{}),width:1920}],Z=({title:o,content:s,currentBreakpoint:e,breakpoint:t,width:n,icon:u,onClick:a})=>{const{t:l}=U.useTranslation();return r.jsxRuntimeExports.jsxs(i.HoverCard,{children:[r.jsxRuntimeExports.jsx(i.HoverCardTrigger,{asChild:!0,children:r.jsxRuntimeExports.jsx(i.Button,{onClick:()=>a(n),size:"sm",variant:t===e?"secondary":"ghost",children:u})}),r.jsxRuntimeExports.jsx(i.HoverCardContent,{className:"w-52 border-border",children:r.jsxRuntimeExports.jsx("div",{className:"flex justify-between space-x-4",children:r.jsxRuntimeExports.jsxs("div",{className:"space-y-1",children:[r.jsxRuntimeExports.jsx("h4",{className:"text-sm font-semibold",children:l(o)}),r.jsxRuntimeExports.jsx("p",{className:"text-xs",children:l(s)})]})})})]})},be=()=>{const[,o,s]=i.useCanvasWidth(),[e,t]=i.useSelectedBreakpoints(),{t:n}=U.useTranslation(),u=i.useBuilderProp("breakpoints",$e),a=l=>{e.includes(l)?e.length>2&&t(e.filter(p=>p!==l)):t(p=>[...p,l])};return u.length<4?r.jsxRuntimeExports.jsx("div",{className:"flex items-center rounded-md",children:c.map(u,l=>x.createElement(Z,{...l,onClick:s,key:l.breakpoint,currentBreakpoint:o}))}):r.jsxRuntimeExports.jsxs("div",{className:"flex items-center rounded-md",children:[c.map(u.filter(l=>c.includes(e,c.toUpper(l.breakpoint))),l=>x.createElement(Z,{...l,onClick:s,key:l.breakpoint,currentBreakpoint:o})),r.jsxRuntimeExports.jsxs(i.DropdownMenu,{children:[r.jsxRuntimeExports.jsx(i.DropdownMenuTrigger,{asChild:!0,children:r.jsxRuntimeExports.jsx("span",{className:"cursor-pointer px-2.5 hover:opacity-80",children:r.jsxRuntimeExports.jsx(R.DotsVerticalIcon,{className:"scale-90 transform"})})}),r.jsxRuntimeExports.jsxs(i.DropdownMenuContent,{className:"w-56 border-border text-xs",children:[r.jsxRuntimeExports.jsx(i.DropdownMenuLabel,{children:n("Breakpoints")}),r.jsxRuntimeExports.jsx(i.DropdownMenuSeparator,{}),c.map(u,l=>r.jsxRuntimeExports.jsx(i.DropdownMenuCheckboxItem,{disabled:l.breakpoint==="xs",onCheckedChange:()=>a(c.toUpper(l.breakpoint)),checked:c.includes(e,c.toUpper(l.breakpoint)),children:n(l.title)},l.breakpoint))]})]})]})},ke=()=>{const{t:o}=U.useTranslation(),{setNewBlocks:s}=i.useBlocksStoreUndoableActions(),[,e]=i.useSelectedBlockIds(),[,t]=i.useSelectedStylingBlocks(),n=x.useCallback(()=>{s([]),e([]),t([])},[s]);return r.jsxRuntimeExports.jsx("div",{className:"flex items-center",children:r.jsxRuntimeExports.jsxs(i.AlertDialog,{children:[r.jsxRuntimeExports.jsx(i.AlertDialogTrigger,{asChild:!0,children:r.jsxRuntimeExports.jsxs(i.Button,{size:"sm",variant:"ghost",className:"flex items-center gap-x-1",children:[r.jsxRuntimeExports.jsx(R.EraserIcon,{})," ",o("clear")]})}),r.jsxRuntimeExports.jsxs(i.AlertDialogContent,{className:"border-border",children:[r.jsxRuntimeExports.jsxs(i.AlertDialogHeader,{children:[r.jsxRuntimeExports.jsx(i.AlertDialogTitle,{children:o("clear_canvas_title")}),r.jsxRuntimeExports.jsx(i.AlertDialogDescription,{children:o("clear_canvas_description")})]}),r.jsxRuntimeExports.jsxs(i.AlertDialogFooter,{children:[r.jsxRuntimeExports.jsx(i.AlertDialogCancel,{children:o("cancel")}),r.jsxRuntimeExports.jsx(i.AlertDialogAction,{onClick:n,children:o("yes")})]})]})]})})},Ee=()=>{const[o,s]=k.useAtom(i.aiAssistantActiveAtom);return i.useBuilderProp("askAiCallBack",null)?r.jsxRuntimeExports.jsxs("div",{className:"flex items-center space-x-2",children:[r.jsxRuntimeExports.jsxs(i.Label,{htmlFor:"ai-assistant",className:"flex items-center gap-x-1 text-sm text-yellow-600",children:[r.jsxRuntimeExports.jsx(re.SparklesIcon,{className:"w-4"}),"AI Assistant"]}),r.jsxRuntimeExports.jsx(i.Switch,{className:"scale-90",checked:o,onCheckedChange:t=>{s(t)},id:"ai-assitantt"})]}):null},Re=()=>{const o=i.useBuilderProp("darkMode",!0),[s]=i.useCanvasZoom();return r.jsxRuntimeExports.jsxs("div",{className:"flex h-10 items-center justify-between border-b bg-background/70 px-2",children:[r.jsxRuntimeExports.jsxs("div",{className:"flex h-full space-x-2",children:[r.jsxRuntimeExports.jsx(be,{}),r.jsxRuntimeExports.jsx(i.Separator,{orientation:"vertical"}),o?r.jsxRuntimeExports.jsxs(r.jsxRuntimeExports.Fragment,{children:[r.jsxRuntimeExports.jsx(ye,{}),r.jsxRuntimeExports.jsx(i.Separator,{orientation:"vertical"})]}):null,r.jsxRuntimeExports.jsxs("div",{className:"flex w-12 cursor-not-allowed items-center justify-center gap-x-1 space-x-0 font-medium text-gray-400",children:[r.jsxRuntimeExports.jsx(R.ZoomInIcon,{className:"h-3.5 w-3.5 flex-shrink-0"})," ",r.jsxRuntimeExports.jsxs("div",{className:"text-xs leading-3",children:[c.round(s,0),"%"]})]}),r.jsxRuntimeExports.jsx(i.Separator,{orientation:"vertical"}),r.jsxRuntimeExports.jsx(je,{})]}),r.jsxRuntimeExports.jsxs("div",{className:"flex h-full items-center space-x-2",children:[r.jsxRuntimeExports.jsx(ke,{}),r.jsxRuntimeExports.jsx(i.Separator,{orientation:"vertical"}),r.jsxRuntimeExports.jsx(Ee,{})]})]})},we=`<!doctype html>
2
2
  <html lang="en" dir="__HTML_DIR__" class="scroll-smooth h-full overflow-y-auto">
3
3
  <head>
4
4
  <meta charset="UTF-8">
@@ -53,4 +53,4 @@
53
53
  outline: 1px solid ${e.length===1?"#42a1fc":"orange"} !important; outline-offset: -1px;
54
54
  }`)},[e,g]),x.useEffect(()=>{if(!a){m.textContent="";return}m.textContent=`[data-block-id="${a}"]{ pointer-events: none !important; opacity: 0.2 !important}`},[a]),x.useEffect(()=>{d&&(d.textContent=n?`[data-style-id="${n}"]{ outline: 1px solid #42a1fc !important; outline-offset: -1px;}`:"")},[n,e,d]),x.useEffect(()=>{h&&(h.textContent=`${c.map(u,({id:v})=>`[data-style-id="${v}"]`).join(",")}{
55
55
  outline: 1px solid #42a1fc !important; outline-offset: -1px;
56
- }`)},[u,h]),x.useEffect(()=>{const v=c.get(s,"bodyTextLightColor","#64748b"),f=c.get(s,"bodyTextDarkColor","#94a3b8"),E=c.get(s,"bodyBgLightColor","#FFFFFF"),S=c.get(s,"bodyBgDarkColor","#0f172a");l.body.className=`font-body antialiased text-[${v}] bg-[${E}] dark:text-[${f}] dark:bg-[${S}]`},[s,l,o]),o==="page"?r.jsxRuntimeExports.jsxs(r.jsxRuntimeExports.Fragment,{children:[$&&r.jsxRuntimeExports.jsx("link",{id:"heading-font",rel:"stylesheet",type:"text/css",href:`https://fonts.googleapis.com/css2?family=${$.replace(/ /g,"+")}:wght@300;400;500;600;700;800;900&display=swap`,media:"all"}),b&&$!==b&&r.jsxRuntimeExports.jsx("link",{id:"body-font",rel:"stylesheet",type:"text/css",href:`https://fonts.googleapis.com/css2?family=${b.replace(/ /g,"+")}:wght@300;400;500;600;700;800;900&display=swap`,media:"all"}),$&&r.jsxRuntimeExports.jsx("style",{children:`h1,h2,h3,h4,h5,h6{font-family: "${$}",ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, "Noto Sans", sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol", "Noto Color Emoji";}`})]}):null},Ye=o=>{const s={};return Object.keys(o).forEach(e=>{c.isString(o[e])&&o[e].startsWith(T.SLOT_KEY)&&(s[e]=o[e].replace(T.SLOT_KEY,"").split(","))}),s},Ge=c.memoize(o=>{const s=o.replace(T.STYLES_KEY,"").split(",");return he.twMerge(s[0],s[1])});function Xe(o,s){return c.get(o,`${s}_attrs`,{})}function Ze(o){const s={};return Object.keys(o).forEach(e=>{if(c.isString(o[e])&&o[e].startsWith(T.STYLES_KEY)){const t=Ge(o[e]);s[e]={className:t,"data-style-prop":e,"data-block-parent":o._id,"data-style-id":`${e}-${o._id}`,...Xe(o,e)}}}),s}function Qe(o,s){const e=c.get(o,"_bindings",{});return c.isEmpty(e)?{...o}:(c.each(e,(t,n)=>{c.isString(t)&&c.get(s,t,null)&&(o[n]=c.get(s,t,null))}),o)}function z({blocks:o}){const[s]=i.useBlocksStore(),[e]=k.useAtom(M.draggedBlockAtom),[t]=k.useAtom(M.dropTargetAtom),[n]=ge.useCanvasSettings(),u=x.useCallback(d=>Ze(d),[]),[a]=i.useChaiExternalData(),[l]=k.useAtom(i.inlineEditingActiveAtom),p=x.useCallback(d=>d.reduce((g,h)=>{const m=c.get(n,h,{});return{...g,...m}},{}),[n,s]);return r.jsxRuntimeExports.jsx(r.jsxRuntimeExports.Fragment,{children:x.Children.toArray(o.map((d,g)=>{if(l===d._id)return null;const h=Ye(d),m={};c.isEmpty(h)||Object.keys(h).forEach(S=>{m[S]=x.Children.toArray(h[S].map(D=>r.jsxRuntimeExports.jsx(z,{blocks:[c.find(s,{_id:D})]})))});const $=c.filter(s,{_parent:d._id});m.children=$.length?r.jsxRuntimeExports.jsx(z,{blocks:$}):null;const b=me.getBlockComponent(d._type),v=c.get(b,"builderComponent",c.get(b,"component",null));if(c.isNull(v))return r.jsxRuntimeExports.jsx("noscript",{children:`<!-- ${d==null?void 0:d._type} not registered -->`});const f=c.has(b,"getBlockStateFrom")?b==null?void 0:b.getBlockStateFrom(d,s):[],E=p(f);return r.jsxRuntimeExports.jsx(x.Suspense,{children:x.createElement(v,{blockProps:{"data-block-id":d._id,"data-block-type":d._type,...e?{"data-dnd":i.canAcceptChildBlock(d._type,e==null?void 0:e._type)?"yes":"no"}:{},...t===d._id?{"data-drop":"yes"}:{}},index:g,...Qe(d,a),...u(d),...m,inBuilder:!0,blockState:E})})}))})}const Je=()=>{const[o]=i.useBlocksStore(),s=c.isEmpty(o)?null:r.jsxRuntimeExports.jsx(i.BlocksExternalDataProvider,{children:r.jsxRuntimeExports.jsx(z,{blocks:c.filter(o,e=>c.isEmpty(e._parent))})});return r.jsxRuntimeExports.jsx(r.jsxRuntimeExports.Fragment,{children:s})},Ve=(o,s)=>o.querySelector(`[data-style-id="${s}"]`),et=()=>{const[o]=k.useAtom(i.networkModeAtom),[s]=i.usePreviewMode(),[e]=i.useCanvasWidth(),[,t]=i.useSelectedBlockIds(),n=i.useSelectedBlock(),[,u]=i.useHighlightBlockId(),a=x.useRef(null),l=x.useRef(null),[p,d]=x.useState({width:0,height:0}),g=Se(p),[h,m]=x.useState(0),[$,b]=x.useState([]),[,v]=x.useState([]),[,f]=k.useAtom(i.canvasIframeAtom),[E,S]=i.useSelectedStylingBlocks(),D=i.useBuilderProp("loading",!1),q=i.useBuilderProp("htmlDir","ltr");x.useEffect(()=>{const{clientWidth:j,clientHeight:C}=l.current;d({width:j,height:C}),h===0&&m(j)},[l,e,h]);const L=(j,C=0)=>{const{top:A}=j.getBoundingClientRect();return A+C>=0&&A-C<=window.innerHeight};x.useEffect(()=>{var j,C;if(n&&n.type!=="Multiple"&&a.current){const A=se(a.current.contentDocument,n._id);A&&(L(A)||(C=(j=a.current)==null?void 0:j.contentWindow)==null||C.scrollTo({top:A.offsetTop,behavior:"smooth"}),b([A]))}},[n]),x.useEffect(()=>{if(!c.isEmpty(E)&&a.current){const j=Ve(a.current.contentDocument,c.first(E).id);v(j?[j]:[null])}else v([null])},[E]);const F=x.useMemo(()=>{let j=we;return j=j.replace("__HTML_DIR__",q),o==="offline"&&(j=j.replace("https://old.chaibuilder.com/offline/tailwind.cdn.js","/offline/tailwind.cdn.js"),j=j.replace("https://unpkg.com/aos@next/dist/aos.css","/offline/aos.css"),j=j.replace("https://unpkg.com/aos@next/dist/aos.js","/offline/aos.js")),j},[o]);return r.jsxRuntimeExports.jsx("div",{onClick:()=>{t([]),S([])},onMouseLeave:()=>setTimeout(()=>u(""),300),className:"relative mx-auto h-full w-full overflow-hidden",style:h>0&&!c.isEmpty(g)?{width:s?"100%":h}:{},ref:l,children:r.jsxRuntimeExports.jsxs(Ce,{contentDidMount:()=>f(a.current),ref:a,id:"canvas-iframe",style:{width:`${e}px`,...g},className:"relative mx-auto box-content h-full max-w-full shadow-lg transition-all duration-300 ease-linear",initialContent:F,children:[r.jsxRuntimeExports.jsx(Oe,{}),r.jsxRuntimeExports.jsx(Ue,{block:n,selectedBlockElement:c.first($)}),r.jsxRuntimeExports.jsx(Ke,{model:"page"}),r.jsxRuntimeExports.jsx(fe.Provider,{children:r.jsxRuntimeExports.jsx(He,{children:D?r.jsxRuntimeExports.jsx("div",{className:"h-full p-4",children:r.jsxRuntimeExports.jsx(i.Skeleton,{className:"h-full"})}):r.jsxRuntimeExports.jsx(Je,{})})}),r.jsxRuntimeExports.jsx("br",{}),r.jsxRuntimeExports.jsx("div",{id:"placeholder",className:"pointer-events-none absolute z-[99999] max-w-full bg-green-500 transition-transform"})]})})},tt=x.lazy(()=>Promise.resolve().then(()=>require("./CodeEditor-ye3IXW3i.cjs"))),st=()=>{const[o]=i.useCodeEditor();return r.jsxRuntimeExports.jsxs("div",{className:"flex h-full w-full flex-col",children:[r.jsxRuntimeExports.jsx(Re,{}),r.jsxRuntimeExports.jsxs("div",{className:"relative flex h-full flex-col overflow-hidden bg-slate-800/90 bg-[linear-gradient(to_right,#222_0.5px,transparent_0.5px),linear-gradient(to_bottom,#222_0.5px,transparent_0.5px)] bg-[size:12px_12px] px-2",children:[r.jsxRuntimeExports.jsx(x.Suspense,{fallback:r.jsxRuntimeExports.jsx(i.Skeleton,{className:"h-full"}),children:r.jsxRuntimeExports.jsx(i.ErrorBoundary,{children:r.jsxRuntimeExports.jsx(et,{})})}),o?r.jsxRuntimeExports.jsx(x.Suspense,{fallback:r.jsxRuntimeExports.jsx(i.Skeleton,{className:"h-full"}),children:r.jsxRuntimeExports.jsx(ve.Resizable,{enable:{top:!0,bottom:!1},className:"max-h-[400px] min-h-[200px]",children:r.jsxRuntimeExports.jsx(tt,{})})}):null]})]})};exports.default=st;
56
+ }`)},[u,h]),x.useEffect(()=>{const v=c.get(s,"bodyTextLightColor","#64748b"),f=c.get(s,"bodyTextDarkColor","#94a3b8"),E=c.get(s,"bodyBgLightColor","#FFFFFF"),S=c.get(s,"bodyBgDarkColor","#0f172a");l.body.className=`font-body antialiased text-[${v}] bg-[${E}] dark:text-[${f}] dark:bg-[${S}]`},[s,l,o]),o==="page"?r.jsxRuntimeExports.jsxs(r.jsxRuntimeExports.Fragment,{children:[$&&r.jsxRuntimeExports.jsx("link",{id:"heading-font",rel:"stylesheet",type:"text/css",href:`https://fonts.googleapis.com/css2?family=${$.replace(/ /g,"+")}:wght@300;400;500;600;700;800;900&display=swap`,media:"all"}),b&&$!==b&&r.jsxRuntimeExports.jsx("link",{id:"body-font",rel:"stylesheet",type:"text/css",href:`https://fonts.googleapis.com/css2?family=${b.replace(/ /g,"+")}:wght@300;400;500;600;700;800;900&display=swap`,media:"all"}),$&&r.jsxRuntimeExports.jsx("style",{children:`h1,h2,h3,h4,h5,h6{font-family: "${$}",ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, "Noto Sans", sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol", "Noto Color Emoji";}`})]}):null},Ye=o=>{const s={};return Object.keys(o).forEach(e=>{c.isString(o[e])&&o[e].startsWith(T.SLOT_KEY)&&(s[e]=o[e].replace(T.SLOT_KEY,"").split(","))}),s},Ge=c.memoize(o=>{const s=o.replace(T.STYLES_KEY,"").split(",");return he.twMerge(s[0],s[1])});function Xe(o,s){return c.get(o,`${s}_attrs`,{})}function Ze(o){const s={};return Object.keys(o).forEach(e=>{if(c.isString(o[e])&&o[e].startsWith(T.STYLES_KEY)){const t=Ge(o[e]);s[e]={className:t,"data-style-prop":e,"data-block-parent":o._id,"data-style-id":`${e}-${o._id}`,...Xe(o,e)}}}),s}function Qe(o,s){const e=c.get(o,"_bindings",{});return c.isEmpty(e)?{...o}:(c.each(e,(t,n)=>{c.isString(t)&&c.get(s,t,null)&&(o[n]=c.get(s,t,null))}),o)}function z({blocks:o}){const[s]=i.useBlocksStore(),[e]=k.useAtom(M.draggedBlockAtom),[t]=k.useAtom(M.dropTargetAtom),[n]=ge.useCanvasSettings(),u=x.useCallback(d=>Ze(d),[]),[a]=i.useChaiExternalData(),[l]=k.useAtom(i.inlineEditingActiveAtom),p=x.useCallback(d=>d.reduce((g,h)=>{const m=c.get(n,h,{});return{...g,...m}},{}),[n,s]);return r.jsxRuntimeExports.jsx(r.jsxRuntimeExports.Fragment,{children:x.Children.toArray(o.map((d,g)=>{if(l===d._id)return null;const h=Ye(d),m={};c.isEmpty(h)||Object.keys(h).forEach(S=>{m[S]=x.Children.toArray(h[S].map(D=>r.jsxRuntimeExports.jsx(z,{blocks:[c.find(s,{_id:D})]})))});const $=c.filter(s,{_parent:d._id});m.children=$.length?r.jsxRuntimeExports.jsx(z,{blocks:$}):null;const b=me.getBlockComponent(d._type),v=c.get(b,"builderComponent",c.get(b,"component",null));if(c.isNull(v))return r.jsxRuntimeExports.jsx("noscript",{children:`<!-- ${d==null?void 0:d._type} not registered -->`});const f=c.has(b,"getBlockStateFrom")?b==null?void 0:b.getBlockStateFrom(d,s):[],E=p(f);return r.jsxRuntimeExports.jsx(x.Suspense,{children:x.createElement(v,{blockProps:{"data-block-id":d._id,"data-block-type":d._type,...e?{"data-dnd":i.canAcceptChildBlock(d._type,e==null?void 0:e._type)?"yes":"no"}:{},...t===d._id?{"data-drop":"yes"}:{}},index:g,...Qe(d,a),...u(d),...m,inBuilder:!0,blockState:E})})}))})}const Je=()=>{const[o]=i.useBlocksStore(),s=c.isEmpty(o)?null:r.jsxRuntimeExports.jsx(i.BlocksExternalDataProvider,{children:r.jsxRuntimeExports.jsx(z,{blocks:c.filter(o,e=>c.isEmpty(e._parent))})});return r.jsxRuntimeExports.jsx(r.jsxRuntimeExports.Fragment,{children:s})},Ve=(o,s)=>o.querySelector(`[data-style-id="${s}"]`),et=()=>{const[o]=k.useAtom(i.networkModeAtom),[s]=i.usePreviewMode(),[e]=i.useCanvasWidth(),[,t]=i.useSelectedBlockIds(),n=i.useSelectedBlock(),[,u]=i.useHighlightBlockId(),a=x.useRef(null),l=x.useRef(null),[p,d]=x.useState({width:0,height:0}),g=Se(p),[h,m]=x.useState(0),[$,b]=x.useState([]),[,v]=x.useState([]),[,f]=k.useAtom(i.canvasIframeAtom),[E,S]=i.useSelectedStylingBlocks(),D=i.useBuilderProp("loading",!1),q=i.useBuilderProp("htmlDir","ltr");x.useEffect(()=>{const{clientWidth:j,clientHeight:C}=l.current;d({width:j,height:C}),h===0&&m(j)},[l,e,h]);const L=(j,C=0)=>{const{top:A}=j.getBoundingClientRect();return A+C>=0&&A-C<=window.innerHeight};x.useEffect(()=>{var j,C;if(n&&n.type!=="Multiple"&&a.current){const A=se(a.current.contentDocument,n._id);A&&(L(A)||(C=(j=a.current)==null?void 0:j.contentWindow)==null||C.scrollTo({top:A.offsetTop,behavior:"smooth"}),b([A]))}},[n]),x.useEffect(()=>{if(!c.isEmpty(E)&&a.current){const j=Ve(a.current.contentDocument,c.first(E).id);v(j?[j]:[null])}else v([null])},[E]);const F=x.useMemo(()=>{let j=we;return j=j.replace("__HTML_DIR__",q),o==="offline"&&(j=j.replace("https://old.chaibuilder.com/offline/tailwind.cdn.js","/offline/tailwind.cdn.js"),j=j.replace("https://unpkg.com/aos@next/dist/aos.css","/offline/aos.css"),j=j.replace("https://unpkg.com/aos@next/dist/aos.js","/offline/aos.js")),j},[o]);return r.jsxRuntimeExports.jsx("div",{onClick:()=>{t([]),S([])},onMouseLeave:()=>setTimeout(()=>u(""),300),className:"relative mx-auto h-full w-full overflow-hidden",style:h>0&&!c.isEmpty(g)?{width:s?"100%":h}:{},ref:l,children:r.jsxRuntimeExports.jsxs(Ce,{contentDidMount:()=>f(a.current),ref:a,id:"canvas-iframe",style:{width:`${e}px`,...g},className:"relative mx-auto box-content h-full max-w-full shadow-lg transition-all duration-300 ease-linear",initialContent:F,children:[r.jsxRuntimeExports.jsx(Oe,{}),r.jsxRuntimeExports.jsx(Ue,{block:n,selectedBlockElement:c.first($)}),r.jsxRuntimeExports.jsx(Ke,{model:"page"}),r.jsxRuntimeExports.jsx(fe.Provider,{children:r.jsxRuntimeExports.jsx(He,{children:D?r.jsxRuntimeExports.jsx("div",{className:"h-full p-4",children:r.jsxRuntimeExports.jsx(i.Skeleton,{className:"h-full"})}):r.jsxRuntimeExports.jsx(Je,{})})}),r.jsxRuntimeExports.jsx("br",{}),r.jsxRuntimeExports.jsx("div",{id:"placeholder",className:"pointer-events-none absolute z-[99999] max-w-full bg-green-500 transition-transform"})]})})},tt=x.lazy(()=>Promise.resolve().then(()=>require("./CodeEditor-C6p5CZfl.cjs"))),st=()=>{const[o]=i.useCodeEditor();return r.jsxRuntimeExports.jsxs("div",{className:"flex h-full w-full flex-col",children:[r.jsxRuntimeExports.jsx(Re,{}),r.jsxRuntimeExports.jsxs("div",{className:"relative flex h-full flex-col overflow-hidden bg-slate-800/90 bg-[linear-gradient(to_right,#222_0.5px,transparent_0.5px),linear-gradient(to_bottom,#222_0.5px,transparent_0.5px)] bg-[size:12px_12px] px-2",children:[r.jsxRuntimeExports.jsx(x.Suspense,{fallback:r.jsxRuntimeExports.jsx(i.Skeleton,{className:"h-full"}),children:r.jsxRuntimeExports.jsx(i.ErrorBoundary,{children:r.jsxRuntimeExports.jsx(et,{})})}),o?r.jsxRuntimeExports.jsx(x.Suspense,{fallback:r.jsxRuntimeExports.jsx(i.Skeleton,{className:"h-full"}),children:r.jsxRuntimeExports.jsx(ve.Resizable,{enable:{top:!0,bottom:!1},className:"max-h-[400px] min-h-[200px]",children:r.jsxRuntimeExports.jsx(tt,{})})}):null]})]})};exports.default=st;
@@ -42140,7 +42140,7 @@ const Mu1 = (t) => {
42140
42140
  }
42141
42141
  )
42142
42142
  ] });
42143
- }, wu1 = m.lazy(() => import("./UnsplashImages-MeS5Cu7a.js")), Cu1 = m.lazy(() => import("./UploadImages-AIKATqfP.js")), LS = ({
42143
+ }, wu1 = m.lazy(() => import("./UnsplashImages-iY__3dsJ.js")), Cu1 = m.lazy(() => import("./UploadImages-KHk-jx9-.js")), LS = ({
42144
42144
  isModalView: t = !1,
42145
42145
  onSelect: c = () => {
42146
42146
  }
@@ -42615,7 +42615,7 @@ const Ru1 = ({ blockId: t }) => {
42615
42615
  /* @__PURE__ */ L.jsx(Nu1, { onOpen: (a) => e(a) }),
42616
42616
  c ? null : /* @__PURE__ */ L.jsx(Ru1, { blockId: c4(t) })
42617
42617
  ] });
42618
- }, ju1 = _t(() => import("./SidePanels-t9oUA51J.js")), Du1 = _t(() => import("./Topbar-0DmS6VpB.js")), qu1 = _t(() => import("./CanvasArea-rdY6SFYn.js")), Zu1 = _t(() => import("./Settings-dJ72rwnH.js")), Wu1 = () => {
42618
+ }, ju1 = _t(() => import("./SidePanels-ezU-hGki.js")), Du1 = _t(() => import("./Topbar-YhJ6xVs-.js")), qu1 = _t(() => import("./CanvasArea-ZxrQurg_.js")), Zu1 = _t(() => import("./Settings-SK2ONoi0.js")), Wu1 = () => {
42619
42619
  const { savePage: t } = Ys1(), c = B2("autoSaveSupport", !0), e = B2("autoSaveInterval", 60);
42620
42620
  $S(() => {
42621
42621
  c && t();