@chaibuilder/sdk 0.1.4 → 0.1.6

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 (78) hide show
  1. package/dist/{AddBlocks-b6a12d50.js → AddBlocks-671fde09.js} +20 -19
  2. package/dist/AddBlocks-862cf7e0.cjs +3 -0
  3. package/dist/{BrandingOptions-1190723a.js → BrandingOptions-520c438d.js} +11 -9
  4. package/dist/BrandingOptions-8bbdd54f.cjs +1 -0
  5. package/dist/{CanvasArea-f5d27245.cjs → CanvasArea-86eef07f.cjs} +2 -2
  6. package/dist/{CanvasArea-15458836.js → CanvasArea-d912e63e.js} +226 -224
  7. package/dist/{Class-e34b2337.js → Class-1fb4c0c4.js} +110 -169
  8. package/dist/Class-6c695ccb.cjs +1 -0
  9. package/dist/Layers-ae78b10e.cjs +1 -0
  10. package/dist/{Layers-ff4ef9c0.js → Layers-db65053b.js} +12 -10
  11. package/dist/MODIFIERS-70fef873.cjs +1 -0
  12. package/dist/MODIFIERS-c2e02614.js +67 -0
  13. package/dist/{MarkAsGlobalBlock-dea26aa7.js → MarkAsGlobalBlock-a1274d49.js} +10 -8
  14. package/dist/MarkAsGlobalBlock-d5b40fdb.cjs +1 -0
  15. package/dist/PagesPanel-41ebbdd1.cjs +1 -0
  16. package/dist/{PagesPanel-3e9163c4.js → PagesPanel-48cb686f.js} +12 -10
  17. package/dist/ProjectPanel-08a229f3.cjs +1 -0
  18. package/dist/{ProjectPanel-17c5f131.js → ProjectPanel-920b0f75.js} +9 -10
  19. package/dist/Settings-0c125f1b.cjs +1 -0
  20. package/dist/{Settings-6f2e86a9.js → Settings-9ccc4a65.js} +7 -5
  21. package/dist/{SidePanels-96e64da9.js → SidePanels-9684bfe2.js} +8 -6
  22. package/dist/SidePanels-ef33ed66.cjs +1 -0
  23. package/dist/{Topbar-08d10607.js → Topbar-2f40d770.js} +7 -5
  24. package/dist/Topbar-84eadc0e.cjs +1 -0
  25. package/dist/add-page-modal-7fc782b9.cjs +1 -0
  26. package/dist/add-page-modal-fb7d069a.js +93 -0
  27. package/dist/core.cjs +1 -1
  28. package/dist/core.d.ts +13 -11
  29. package/dist/core.js +63 -61
  30. package/dist/delete-page-modal-15e71ba4.cjs +1 -0
  31. package/dist/{delete-page-modal-fa7b4272.js → delete-page-modal-cc906461.js} +9 -8
  32. package/dist/html-to-json-01cc5fe0.cjs +1 -0
  33. package/dist/{html-to-json-9304dbda.js → html-to-json-d20aafdd.js} +2 -2
  34. package/dist/index-1217461b.cjs +2 -0
  35. package/dist/index-32519c31.js +4909 -0
  36. package/dist/lib.cjs +1 -1
  37. package/dist/lib.js +4 -4
  38. package/dist/page-viewer-15b9eb5f.cjs +1 -0
  39. package/dist/{page-viewer-f1452439.js → page-viewer-77998a4d.js} +21 -18
  40. package/dist/{project-general-setting-0d7715b8.cjs → project-general-setting-a8be43b9.cjs} +1 -1
  41. package/dist/{project-general-setting-e5d14fa6.js → project-general-setting-e66f4966.js} +7 -5
  42. package/dist/render.cjs +2 -2
  43. package/dist/render.d.ts +9 -3
  44. package/dist/render.js +154 -134
  45. package/dist/single-page-detail-116281ae.cjs +1 -0
  46. package/dist/{single-page-detail-74f88ed2.js → single-page-detail-a0332ab5.js} +39 -38
  47. package/dist/style.css +1 -1
  48. package/dist/useChangePage-6a7c7374.js +12 -0
  49. package/dist/useChangePage-f22cea36.cjs +1 -0
  50. package/dist/usePageActions-5e28a006.cjs +1 -0
  51. package/dist/usePageActions-d6e1d325.js +38 -0
  52. package/package.json +3 -2
  53. package/dist/AddBlocks-1f683caa.cjs +0 -3
  54. package/dist/BrandingOptions-02e4ebcf.cjs +0 -1
  55. package/dist/CONTROLS-031e1de3.cjs +0 -1
  56. package/dist/CONTROLS-442caee5.js +0 -6
  57. package/dist/Class-7d6aadbc.cjs +0 -1
  58. package/dist/Layers-06fa708d.cjs +0 -1
  59. package/dist/MarkAsGlobalBlock-fa0e0543.cjs +0 -1
  60. package/dist/PagesPanel-b08e1357.cjs +0 -1
  61. package/dist/ProjectPanel-f0b94e3f.cjs +0 -1
  62. package/dist/Settings-739cff3b.cjs +0 -1
  63. package/dist/SidePanels-ce4d41d5.cjs +0 -1
  64. package/dist/Topbar-b97472fc.cjs +0 -1
  65. package/dist/add-page-modal-3275cfb2.cjs +0 -1
  66. package/dist/add-page-modal-bcd9249e.js +0 -93
  67. package/dist/delete-page-modal-420a17e3.cjs +0 -1
  68. package/dist/html-to-json-9c9961da.cjs +0 -1
  69. package/dist/index-133d90a5.cjs +0 -2
  70. package/dist/index-3f65447f.js +0 -4754
  71. package/dist/page-viewer-139bfb2a.cjs +0 -1
  72. package/dist/single-page-detail-54d7feca.cjs +0 -1
  73. package/dist/useMutation-7d536740.cjs +0 -1
  74. package/dist/useMutation-97876a40.js +0 -126
  75. package/dist/usePageActions-ac9ad321.cjs +0 -1
  76. package/dist/usePageActions-de3b7515.js +0 -37
  77. package/dist/useProjectActions-3b1dbb5e.js +0 -18
  78. package/dist/useProjectActions-41af0f70.cjs +0 -1
@@ -1,29 +1,29 @@
1
1
  var yt = Object.defineProperty;
2
- var vt = (e, n, r) => n in e ? yt(e, n, { enumerable: !0, configurable: !0, writable: !0, value: r }) : e[n] = r;
3
- var V = (e, n, r) => (vt(e, typeof n != "symbol" ? n + "" : n, r), r);
2
+ var vt = (e, r, n) => r in e ? yt(e, r, { enumerable: !0, configurable: !0, writable: !0, value: n }) : e[r] = n;
3
+ var V = (e, r, n) => (vt(e, typeof r != "symbol" ? r + "" : r, n), n);
4
4
  import { j as t } from "./jsx-runtime-944c88e2.js";
5
5
  import G, { createElement as gt, useCallback as Q, useState as H, useEffect as F, Component as Xe, Children as xt, useRef as Oe, useMemo as bt, lazy as wt, Suspense as Et } from "react";
6
6
  import { map as ie, includes as Me, toUpper as ye, round as St, isEmpty as ee, first as ce, get as $, memoize as Tt, find as jt, filter as Ze, isString as Je } from "lodash";
7
7
  import { ResetIcon as De, DotsVerticalIcon as Ct, MobileIcon as Be, LaptopIcon as kt, DesktopIcon as _t, EraserIcon as Rt, ZoomInIcon as At, ArrowUpIcon as Pt, CopyIcon as It, TrashIcon as Ot, DragHandleDots2Icon as Mt } from "@radix-ui/react-icons";
8
8
  import { B as le, u as Qe, S as et } from "./useBuilderProp-81a14920.js";
9
- import { c as ke, d as tt, e as _e, f as Dt, g as Bt, h as X, i as Z, j as $t, k as nt, l as rt, m as Nt, n as Lt, o as Ft, p as ot, q as st, u as Wt, r as qt, s as Ut, t as Yt, v as zt, w as Ht, x as Re, y as at, z as Kt, A as Vt, B as Gt, b as Xt, E as Zt } from "./index-3f65447f.js";
9
+ import { c as ke, d as tt, e as _e, f as Dt, g as Bt, h as X, i as Z, j as $t, k as rt, l as nt, m as Nt, n as Lt, o as Ft, p as ot, q as st, u as Wt, r as qt, s as Ut, t as Yt, v as zt, w as Ht, x as Re, y as at, z as Kt, A as Vt, B as Gt, b as Xt, E as Zt } from "./index-32519c31.js";
10
10
  import { useTranslation as it } from "react-i18next";
11
11
  import { S as se } from "./separator-a80d065b.js";
12
- import { S as Jt, D as Qt, c as en, d as tn, h as nn, i as rn, f as on, H as sn, a as an, b as cn } from "./dropdown-menu-ae3ed09b.js";
13
- import { L as ln } from "./label-e770a087.js";
14
- import { A as dn, a as un, b as fn, c as pn, e as hn, f as mn, d as yn, h as vn, g as gn } from "./alert-dialog-ee98f47e.js";
12
+ import { S as Jt, D as Qt, c as er, d as tr, h as rr, i as nr, f as or, H as sr, a as ar, b as ir } from "./dropdown-menu-ae3ed09b.js";
13
+ import { L as cr } from "./label-e770a087.js";
14
+ import { A as lr, a as dr, b as ur, c as fr, e as pr, f as hr, d as mr, h as yr, g as vr } from "./alert-dialog-ee98f47e.js";
15
15
  import { useAtom as te } from "jotai";
16
- import { flip as xn } from "@floating-ui/dom";
17
- import { useFloating as bn, shift as wn } from "@floating-ui/react-dom";
18
- import { useDrag as En } from "react-dnd";
19
- import { useResizeObserver as Sn } from "@react-hookz/web";
20
- import { tailwindcssPaletteGenerator as Tn } from "@bobthered/tailwindcss-palette-generator";
21
- import { Provider as jn } from "react-wrap-balancer";
22
- import { twMerge as Cn } from "tailwind-merge";
23
- import { S as ct, a as $e } from "./CONTROLS-442caee5.js";
24
- import { getBlockComponent as kn } from "@chaibuilder/blocks";
16
+ import { flip as gr } from "@floating-ui/dom";
17
+ import { useFloating as xr, shift as br } from "@floating-ui/react-dom";
18
+ import { useDrag as wr } from "react-dnd";
19
+ import { useResizeObserver as Er } from "@react-hookz/web";
20
+ import { tailwindcssPaletteGenerator as Sr } from "@bobthered/tailwindcss-palette-generator";
21
+ import { Provider as Tr } from "react-wrap-balancer";
22
+ import { twMerge as jr } from "tailwind-merge";
23
+ import { S as ct, a as $e } from "./MODIFIERS-c2e02614.js";
24
+ import { getBlockComponent as Cr } from "@chaibuilder/blocks";
25
25
  import Ne from "react-dom";
26
- import { g as _n } from "./_commonjsHelpers-d4512b9c.js";
26
+ import { g as kr } from "./_commonjsHelpers-d4512b9c.js";
27
27
  import "@radix-ui/react-slot";
28
28
  import "class-variance-authority";
29
29
  import "./utils-ac68b2c8.js";
@@ -35,32 +35,34 @@ import "flagged";
35
35
  import "@minoru/react-dnd-treeview";
36
36
  import "react-hotkeys-hook";
37
37
  import "flat-to-nested";
38
- import "./Class-e34b2337.js";
38
+ import "./Class-1fb4c0c4.js";
39
39
  import "redux-undo";
40
+ import "sonner";
41
+ import "lucide-react";
40
42
  import "@radix-ui/react-separator";
41
43
  import "@radix-ui/react-switch";
42
44
  import "@radix-ui/react-hover-card";
43
45
  import "@radix-ui/react-dropdown-menu";
44
46
  import "@radix-ui/react-label";
45
47
  import "@radix-ui/react-alert-dialog";
46
- const Rn = () => {
47
- const { undoCount: e, redoCount: n, undo: r, redo: i } = ke();
48
+ const _r = () => {
49
+ const { undoCount: e, redoCount: r, undo: n, redo: i } = ke();
48
50
  return /* @__PURE__ */ t.jsxs("div", { className: "flex items-center", children: [
49
- /* @__PURE__ */ t.jsx(le, { disabled: !e, size: "sm", onClick: r, className: "rounded-full", variant: "ghost", children: /* @__PURE__ */ t.jsx(De, {}) }),
50
- /* @__PURE__ */ t.jsx(le, { disabled: !n, onClick: i, size: "sm", className: "rounded-full", variant: "ghost", children: /* @__PURE__ */ t.jsx(De, { className: "rotate-180 scale-y-[-1] transform" }) })
51
+ /* @__PURE__ */ t.jsx(le, { disabled: !e, size: "sm", onClick: n, className: "rounded-full", variant: "ghost", children: /* @__PURE__ */ t.jsx(De, {}) }),
52
+ /* @__PURE__ */ t.jsx(le, { disabled: !r, onClick: i, size: "sm", className: "rounded-full", variant: "ghost", children: /* @__PURE__ */ t.jsx(De, { className: "rotate-180 scale-y-[-1] transform" }) })
51
53
  ] });
52
54
  };
53
- function An() {
54
- const [e, n] = tt(), { t: r } = it();
55
+ function Rr() {
56
+ const [e, r] = tt(), { t: n } = it();
55
57
  return /* @__PURE__ */ t.jsxs("div", { className: "flex items-center", children: [
56
- /* @__PURE__ */ t.jsx(ln, { htmlFor: "dark-mode-switch", children: r("dark_mode") }),
58
+ /* @__PURE__ */ t.jsx(cr, { htmlFor: "dark-mode-switch", children: n("dark_mode") }),
57
59
  /* @__PURE__ */ t.jsxs(
58
60
  Jt,
59
61
  {
60
62
  id: "dark-mode-switch",
61
63
  checked: e,
62
64
  onCheckedChange: () => {
63
- n(!e);
65
+ r(!e);
64
66
  },
65
67
  className: `${e ? "bg-violet-600" : "bg-violet-300"}
66
68
  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`,
@@ -145,48 +147,48 @@ const Le = ({ landscape: e = !1 }) => /* @__PURE__ */ t.jsxs(
145
147
  icon: /* @__PURE__ */ t.jsx(_t, {}),
146
148
  width: 1920
147
149
  }
148
- ], Pn = ({
150
+ ], Ar = ({
149
151
  title: e,
150
- content: n,
151
- currentBreakpoint: r,
152
+ content: r,
153
+ currentBreakpoint: n,
152
154
  breakpoint: i,
153
155
  width: d,
154
156
  icon: s,
155
157
  onClick: a
156
- }) => /* @__PURE__ */ t.jsxs(sn, { children: [
157
- /* @__PURE__ */ t.jsx(an, { asChild: !0, children: /* @__PURE__ */ t.jsx(
158
+ }) => /* @__PURE__ */ t.jsxs(sr, { children: [
159
+ /* @__PURE__ */ t.jsx(ar, { asChild: !0, children: /* @__PURE__ */ t.jsx(
158
160
  le,
159
161
  {
160
162
  onClick: () => a(d),
161
163
  size: "sm",
162
- variant: i === r ? "secondary" : "ghost",
164
+ variant: i === n ? "secondary" : "ghost",
163
165
  children: s
164
166
  }
165
167
  ) }),
166
- /* @__PURE__ */ t.jsx(cn, { className: "w-52 border-border", children: /* @__PURE__ */ t.jsx("div", { className: "flex justify-between space-x-4", children: /* @__PURE__ */ t.jsxs("div", { className: "space-y-1", children: [
168
+ /* @__PURE__ */ t.jsx(ir, { className: "w-52 border-border", children: /* @__PURE__ */ t.jsx("div", { className: "flex justify-between space-x-4", children: /* @__PURE__ */ t.jsxs("div", { className: "space-y-1", children: [
167
169
  /* @__PURE__ */ t.jsx("h4", { className: "text-sm font-semibold", children: e }),
168
- /* @__PURE__ */ t.jsx("p", { className: "text-xs", children: n })
170
+ /* @__PURE__ */ t.jsx("p", { className: "text-xs", children: r })
169
171
  ] }) }) })
170
- ] }), In = () => {
171
- const [, e, n] = _e(), [r, i] = Dt(), d = (s) => {
172
- r.includes(s) ? r.length > 2 && i(r.filter((a) => a !== s)) : i((a) => [...a, s]);
172
+ ] }), Pr = () => {
173
+ const [, e, r] = _e(), [n, i] = Dt(), d = (s) => {
174
+ n.includes(s) ? n.length > 2 && i(n.filter((a) => a !== s)) : i((a) => [...a, s]);
173
175
  };
174
176
  return /* @__PURE__ */ t.jsxs("div", { className: "flex items-center rounded-md", children: [
175
177
  ie(
176
- Fe.filter((s) => Me(r, ye(s.breakpoint))),
177
- (s) => /* @__PURE__ */ gt(Pn, { ...s, onClick: n, key: s.breakpoint, currentBreakpoint: e })
178
+ Fe.filter((s) => Me(n, ye(s.breakpoint))),
179
+ (s) => /* @__PURE__ */ gt(Ar, { ...s, onClick: r, key: s.breakpoint, currentBreakpoint: e })
178
180
  ),
179
181
  /* @__PURE__ */ t.jsxs(Qt, { children: [
180
- /* @__PURE__ */ t.jsx(en, { asChild: !0, children: /* @__PURE__ */ t.jsx("span", { className: "cursor-pointer px-2.5 hover:opacity-80", children: /* @__PURE__ */ t.jsx(Ct, { className: "scale-90 transform" }) }) }),
181
- /* @__PURE__ */ t.jsxs(tn, { className: "w-56 border-border text-xs", children: [
182
- /* @__PURE__ */ t.jsx(nn, { children: "Breakpoints" }),
183
- /* @__PURE__ */ t.jsx(rn, {}),
182
+ /* @__PURE__ */ t.jsx(er, { asChild: !0, children: /* @__PURE__ */ t.jsx("span", { className: "cursor-pointer px-2.5 hover:opacity-80", children: /* @__PURE__ */ t.jsx(Ct, { className: "scale-90 transform" }) }) }),
183
+ /* @__PURE__ */ t.jsxs(tr, { className: "w-56 border-border text-xs", children: [
184
+ /* @__PURE__ */ t.jsx(rr, { children: "Breakpoints" }),
185
+ /* @__PURE__ */ t.jsx(nr, {}),
184
186
  ie(Fe, (s) => /* @__PURE__ */ t.jsx(
185
- on,
187
+ or,
186
188
  {
187
189
  disabled: s.breakpoint === "xs",
188
190
  onCheckedChange: () => d(ye(s.breakpoint)),
189
- checked: Me(r, ye(s.breakpoint)),
191
+ checked: Me(n, ye(s.breakpoint)),
190
192
  children: s.title
191
193
  },
192
194
  s.breakpoint
@@ -194,50 +196,50 @@ const Le = ({ landscape: e = !1 }) => /* @__PURE__ */ t.jsxs(
194
196
  ] })
195
197
  ] })
196
198
  ] });
197
- }, On = () => {
198
- const [e] = Bt(), { createSnapshot: n } = ke(), [, r] = X(), [, i] = Z(), d = Q(() => {
199
- e([]), r([]), i([]), n();
200
- }, [e, n]);
201
- return /* @__PURE__ */ t.jsx("div", { className: "flex items-center", children: /* @__PURE__ */ t.jsxs(dn, { children: [
202
- /* @__PURE__ */ t.jsx(un, { asChild: !0, children: /* @__PURE__ */ t.jsxs(le, { size: "sm", variant: "ghost", className: "flex items-center gap-x-1", children: [
199
+ }, Ir = () => {
200
+ const [e] = Bt(), { createSnapshot: r } = ke(), [, n] = X(), [, i] = Z(), d = Q(() => {
201
+ e([]), n([]), i([]), r();
202
+ }, [e, r]);
203
+ return /* @__PURE__ */ t.jsx("div", { className: "flex items-center", children: /* @__PURE__ */ t.jsxs(lr, { children: [
204
+ /* @__PURE__ */ t.jsx(dr, { asChild: !0, children: /* @__PURE__ */ t.jsxs(le, { size: "sm", variant: "ghost", className: "flex items-center gap-x-1", children: [
203
205
  /* @__PURE__ */ t.jsx(Rt, {}),
204
206
  " Clear"
205
207
  ] }) }),
206
- /* @__PURE__ */ t.jsxs(fn, { className: "border-border", children: [
207
- /* @__PURE__ */ t.jsxs(pn, { children: [
208
- /* @__PURE__ */ t.jsx(hn, { children: "Clear whole canvas?" }),
209
- /* @__PURE__ */ t.jsx(mn, { children: "Are you sure you want to clear the whole canvas?" })
208
+ /* @__PURE__ */ t.jsxs(ur, { className: "border-border", children: [
209
+ /* @__PURE__ */ t.jsxs(fr, { children: [
210
+ /* @__PURE__ */ t.jsx(pr, { children: "Clear whole canvas?" }),
211
+ /* @__PURE__ */ t.jsx(hr, { children: "Are you sure you want to clear the whole canvas?" })
210
212
  ] }),
211
- /* @__PURE__ */ t.jsxs(yn, { children: [
212
- /* @__PURE__ */ t.jsx(vn, { children: "Cancel" }),
213
- /* @__PURE__ */ t.jsx(gn, { onClick: d, children: "Yes" })
213
+ /* @__PURE__ */ t.jsxs(mr, { children: [
214
+ /* @__PURE__ */ t.jsx(yr, { children: "Cancel" }),
215
+ /* @__PURE__ */ t.jsx(vr, { onClick: d, children: "Yes" })
214
216
  ] })
215
217
  ] })
216
218
  ] }) });
217
- }, Mn = () => {
218
- const e = $t("darkMode", !1), [n] = nt();
219
+ }, Or = () => {
220
+ const e = $t("darkMode", !1), [r] = rt();
219
221
  return /* @__PURE__ */ t.jsxs("div", { className: "flex h-10 items-center justify-between border-b bg-background/70 px-2", children: [
220
222
  /* @__PURE__ */ t.jsxs("div", { className: "flex h-full space-x-2", children: [
221
223
  e ? /* @__PURE__ */ t.jsxs(t.Fragment, { children: [
222
- /* @__PURE__ */ t.jsx(An, {}),
224
+ /* @__PURE__ */ t.jsx(Rr, {}),
223
225
  /* @__PURE__ */ t.jsx(se, { orientation: "vertical" })
224
226
  ] }) : null,
225
- /* @__PURE__ */ t.jsx(In, {}),
227
+ /* @__PURE__ */ t.jsx(Pr, {}),
226
228
  /* @__PURE__ */ t.jsx(se, { orientation: "vertical" }),
227
229
  /* @__PURE__ */ t.jsxs("div", { className: "flex w-12 items-center justify-center gap-x-1 space-x-0 font-medium", children: [
228
230
  /* @__PURE__ */ t.jsx(At, { className: "h-3.5 w-3.5 flex-shrink-0" }),
229
231
  " ",
230
232
  /* @__PURE__ */ t.jsxs("div", { className: "text-xs leading-3", children: [
231
- St(n, 0),
233
+ St(r, 0),
232
234
  "%"
233
235
  ] })
234
236
  ] }),
235
237
  /* @__PURE__ */ t.jsx(se, { orientation: "vertical" }),
236
- /* @__PURE__ */ t.jsx(Rn, {})
238
+ /* @__PURE__ */ t.jsx(_r, {})
237
239
  ] }),
238
240
  /* @__PURE__ */ t.jsxs("div", { className: "flex h-full items-center space-x-2", children: [
239
241
  /* @__PURE__ */ t.jsx(se, { orientation: "vertical" }),
240
- /* @__PURE__ */ t.jsx(On, {})
242
+ /* @__PURE__ */ t.jsx(Ir, {})
241
243
  ] })
242
244
  ] });
243
245
  }, ve = {
@@ -246,7 +248,7 @@ const Le = ({ landscape: e = !1 }) => /* @__PURE__ */ t.jsxs(
246
248
  EMAIL: "EMAIL",
247
249
  PRESENTATION: "PRESENTATION",
248
250
  GRAPHIC: "GRAPHIC"
249
- }, Dn = `<!doctype html>
251
+ }, Mr = `<!doctype html>
250
252
  <html class="scroll-smooth h-full overflow-y-auto">
251
253
  <head>
252
254
  <meta charset="UTF-8">
@@ -280,24 +282,24 @@ const Le = ({ landscape: e = !1 }) => /* @__PURE__ */ t.jsxs(
280
282
  <body class="font-body antialiased h-full">
281
283
  <div class="frame-root"></div>
282
284
  </body>
283
- </html>`, Bn = (e) => {
284
- const [n] = _e(), [, r] = nt(), [i, d] = H({}), s = Q(() => {
285
+ </html>`, Dr = (e) => {
286
+ const [r] = _e(), [, n] = rt(), [i, d] = H({}), s = Q(() => {
285
287
  const { width: a, height: f } = e;
286
- if (a < n) {
287
- const y = parseFloat((a / n).toString());
288
+ if (a < r) {
289
+ const y = parseFloat((a / r).toString());
288
290
  let p = {};
289
291
  f && (p = { height: f + 2 * f * (1 - y) }), d({
290
292
  transform: `scale(${y})`,
291
293
  transformOrigin: "top left",
292
294
  ...p,
293
295
  maxWidth: "none"
294
- }), r(y * 100);
296
+ }), n(y * 100);
295
297
  } else
296
- d({}), r(100);
297
- }, [n, e, r]);
298
+ d({}), n(100);
299
+ }, [r, e, n]);
298
300
  return F(() => {
299
301
  s();
300
- }, [n, e, r, s]), i;
302
+ }, [r, e, n, s]), i;
301
303
  };
302
304
  var Te = { exports: {} }, ae = { exports: {} }, A = {};
303
305
  /** @license React v16.13.1
@@ -309,16 +311,16 @@ var Te = { exports: {} }, ae = { exports: {} }, A = {};
309
311
  * LICENSE file in the root directory of this source tree.
310
312
  */
311
313
  var We;
312
- function $n() {
314
+ function Br() {
313
315
  if (We)
314
316
  return A;
315
317
  We = 1;
316
- var e = typeof Symbol == "function" && Symbol.for, n = e ? Symbol.for("react.element") : 60103, r = e ? Symbol.for("react.portal") : 60106, i = e ? Symbol.for("react.fragment") : 60107, d = e ? Symbol.for("react.strict_mode") : 60108, s = e ? Symbol.for("react.profiler") : 60114, a = e ? Symbol.for("react.provider") : 60109, f = e ? Symbol.for("react.context") : 60110, y = e ? Symbol.for("react.async_mode") : 60111, p = e ? Symbol.for("react.concurrent_mode") : 60111, m = e ? Symbol.for("react.forward_ref") : 60112, h = e ? Symbol.for("react.suspense") : 60113, b = e ? Symbol.for("react.suspense_list") : 60120, v = e ? Symbol.for("react.memo") : 60115, O = e ? Symbol.for("react.lazy") : 60116, E = e ? Symbol.for("react.block") : 60121, C = e ? Symbol.for("react.fundamental") : 60117, g = e ? Symbol.for("react.responder") : 60118, U = e ? Symbol.for("react.scope") : 60119;
318
+ var e = typeof Symbol == "function" && Symbol.for, r = e ? Symbol.for("react.element") : 60103, n = e ? Symbol.for("react.portal") : 60106, i = e ? Symbol.for("react.fragment") : 60107, d = e ? Symbol.for("react.strict_mode") : 60108, s = e ? Symbol.for("react.profiler") : 60114, a = e ? Symbol.for("react.provider") : 60109, f = e ? Symbol.for("react.context") : 60110, y = e ? Symbol.for("react.async_mode") : 60111, p = e ? Symbol.for("react.concurrent_mode") : 60111, m = e ? Symbol.for("react.forward_ref") : 60112, h = e ? Symbol.for("react.suspense") : 60113, b = e ? Symbol.for("react.suspense_list") : 60120, v = e ? Symbol.for("react.memo") : 60115, O = e ? Symbol.for("react.lazy") : 60116, E = e ? Symbol.for("react.block") : 60121, C = e ? Symbol.for("react.fundamental") : 60117, g = e ? Symbol.for("react.responder") : 60118, U = e ? Symbol.for("react.scope") : 60119;
317
319
  function M(l) {
318
320
  if (typeof l == "object" && l !== null) {
319
321
  var D = l.$$typeof;
320
322
  switch (D) {
321
- case n:
323
+ case r:
322
324
  switch (l = l.type, l) {
323
325
  case y:
324
326
  case p:
@@ -339,7 +341,7 @@ function $n() {
339
341
  return D;
340
342
  }
341
343
  }
342
- case r:
344
+ case n:
343
345
  return D;
344
346
  }
345
347
  }
@@ -347,14 +349,14 @@ function $n() {
347
349
  function B(l) {
348
350
  return M(l) === p;
349
351
  }
350
- return A.AsyncMode = y, A.ConcurrentMode = p, A.ContextConsumer = f, A.ContextProvider = a, A.Element = n, A.ForwardRef = m, A.Fragment = i, A.Lazy = O, A.Memo = v, A.Portal = r, A.Profiler = s, A.StrictMode = d, A.Suspense = h, A.isAsyncMode = function(l) {
352
+ return A.AsyncMode = y, A.ConcurrentMode = p, A.ContextConsumer = f, A.ContextProvider = a, A.Element = r, A.ForwardRef = m, A.Fragment = i, A.Lazy = O, A.Memo = v, A.Portal = n, A.Profiler = s, A.StrictMode = d, A.Suspense = h, A.isAsyncMode = function(l) {
351
353
  return B(l) || M(l) === y;
352
354
  }, A.isConcurrentMode = B, A.isContextConsumer = function(l) {
353
355
  return M(l) === f;
354
356
  }, A.isContextProvider = function(l) {
355
357
  return M(l) === a;
356
358
  }, A.isElement = function(l) {
357
- return typeof l == "object" && l !== null && l.$$typeof === n;
359
+ return typeof l == "object" && l !== null && l.$$typeof === r;
358
360
  }, A.isForwardRef = function(l) {
359
361
  return M(l) === m;
360
362
  }, A.isFragment = function(l) {
@@ -364,7 +366,7 @@ function $n() {
364
366
  }, A.isMemo = function(l) {
365
367
  return M(l) === v;
366
368
  }, A.isPortal = function(l) {
367
- return M(l) === r;
369
+ return M(l) === n;
368
370
  }, A.isProfiler = function(l) {
369
371
  return M(l) === s;
370
372
  }, A.isStrictMode = function(l) {
@@ -385,9 +387,9 @@ var P = {};
385
387
  * LICENSE file in the root directory of this source tree.
386
388
  */
387
389
  var qe;
388
- function Nn() {
390
+ function $r() {
389
391
  return qe || (qe = 1, process.env.NODE_ENV !== "production" && function() {
390
- var e = typeof Symbol == "function" && Symbol.for, n = e ? Symbol.for("react.element") : 60103, r = e ? Symbol.for("react.portal") : 60106, i = e ? Symbol.for("react.fragment") : 60107, d = e ? Symbol.for("react.strict_mode") : 60108, s = e ? Symbol.for("react.profiler") : 60114, a = e ? Symbol.for("react.provider") : 60109, f = e ? Symbol.for("react.context") : 60110, y = e ? Symbol.for("react.async_mode") : 60111, p = e ? Symbol.for("react.concurrent_mode") : 60111, m = e ? Symbol.for("react.forward_ref") : 60112, h = e ? Symbol.for("react.suspense") : 60113, b = e ? Symbol.for("react.suspense_list") : 60120, v = e ? Symbol.for("react.memo") : 60115, O = e ? Symbol.for("react.lazy") : 60116, E = e ? Symbol.for("react.block") : 60121, C = e ? Symbol.for("react.fundamental") : 60117, g = e ? Symbol.for("react.responder") : 60118, U = e ? Symbol.for("react.scope") : 60119;
392
+ var e = typeof Symbol == "function" && Symbol.for, r = e ? Symbol.for("react.element") : 60103, n = e ? Symbol.for("react.portal") : 60106, i = e ? Symbol.for("react.fragment") : 60107, d = e ? Symbol.for("react.strict_mode") : 60108, s = e ? Symbol.for("react.profiler") : 60114, a = e ? Symbol.for("react.provider") : 60109, f = e ? Symbol.for("react.context") : 60110, y = e ? Symbol.for("react.async_mode") : 60111, p = e ? Symbol.for("react.concurrent_mode") : 60111, m = e ? Symbol.for("react.forward_ref") : 60112, h = e ? Symbol.for("react.suspense") : 60113, b = e ? Symbol.for("react.suspense_list") : 60120, v = e ? Symbol.for("react.memo") : 60115, O = e ? Symbol.for("react.lazy") : 60116, E = e ? Symbol.for("react.block") : 60121, C = e ? Symbol.for("react.fundamental") : 60117, g = e ? Symbol.for("react.responder") : 60118, U = e ? Symbol.for("react.scope") : 60119;
391
393
  function M(c) {
392
394
  return typeof c == "string" || typeof c == "function" || // Note: its typeof might be other than 'symbol' or 'number' if it's a polyfill.
393
395
  c === i || c === p || c === s || c === d || c === h || c === b || typeof c == "object" && c !== null && (c.$$typeof === O || c.$$typeof === v || c.$$typeof === a || c.$$typeof === f || c.$$typeof === m || c.$$typeof === C || c.$$typeof === g || c.$$typeof === U || c.$$typeof === E);
@@ -396,7 +398,7 @@ function Nn() {
396
398
  if (typeof c == "object" && c !== null) {
397
399
  var z = c.$$typeof;
398
400
  switch (z) {
399
- case n:
401
+ case r:
400
402
  var oe = c.type;
401
403
  switch (oe) {
402
404
  case y:
@@ -419,14 +421,14 @@ function Nn() {
419
421
  return z;
420
422
  }
421
423
  }
422
- case r:
424
+ case n:
423
425
  return z;
424
426
  }
425
427
  }
426
428
  }
427
- var l = y, D = p, W = f, q = a, de = n, ue = m, ne = i, fe = O, pe = v, J = r, he = s, Y = d, K = h, re = !1;
429
+ var l = y, D = p, W = f, q = a, de = r, ue = m, re = i, fe = O, pe = v, J = n, he = s, Y = d, K = h, ne = !1;
428
430
  function me(c) {
429
- return re || (re = !0, console.warn("The ReactIs.isAsyncMode() alias has been deprecated, and will be removed in React 17+. Update your code to use ReactIs.isConcurrentMode() instead. It has the exact same API.")), o(c) || B(c) === y;
431
+ return ne || (ne = !0, console.warn("The ReactIs.isAsyncMode() alias has been deprecated, and will be removed in React 17+. Update your code to use ReactIs.isConcurrentMode() instead. It has the exact same API.")), o(c) || B(c) === y;
430
432
  }
431
433
  function o(c) {
432
434
  return B(c) === p;
@@ -438,7 +440,7 @@ function Nn() {
438
440
  return B(c) === a;
439
441
  }
440
442
  function S(c) {
441
- return typeof c == "object" && c !== null && c.$$typeof === n;
443
+ return typeof c == "object" && c !== null && c.$$typeof === r;
442
444
  }
443
445
  function x(c) {
444
446
  return B(c) === m;
@@ -453,7 +455,7 @@ function Nn() {
453
455
  return B(c) === v;
454
456
  }
455
457
  function _(c) {
456
- return B(c) === r;
458
+ return B(c) === n;
457
459
  }
458
460
  function I(c) {
459
461
  return B(c) === s;
@@ -464,12 +466,12 @@ function Nn() {
464
466
  function N(c) {
465
467
  return B(c) === h;
466
468
  }
467
- P.AsyncMode = l, P.ConcurrentMode = D, P.ContextConsumer = W, P.ContextProvider = q, P.Element = de, P.ForwardRef = ue, P.Fragment = ne, P.Lazy = fe, P.Memo = pe, P.Portal = J, P.Profiler = he, P.StrictMode = Y, P.Suspense = K, P.isAsyncMode = me, P.isConcurrentMode = o, P.isContextConsumer = u, P.isContextProvider = j, P.isElement = S, P.isForwardRef = x, P.isFragment = k, P.isLazy = w, P.isMemo = T, P.isPortal = _, P.isProfiler = I, P.isStrictMode = R, P.isSuspense = N, P.isValidElementType = M, P.typeOf = B;
469
+ P.AsyncMode = l, P.ConcurrentMode = D, P.ContextConsumer = W, P.ContextProvider = q, P.Element = de, P.ForwardRef = ue, P.Fragment = re, P.Lazy = fe, P.Memo = pe, P.Portal = J, P.Profiler = he, P.StrictMode = Y, P.Suspense = K, P.isAsyncMode = me, P.isConcurrentMode = o, P.isContextConsumer = u, P.isContextProvider = j, P.isElement = S, P.isForwardRef = x, P.isFragment = k, P.isLazy = w, P.isMemo = T, P.isPortal = _, P.isProfiler = I, P.isStrictMode = R, P.isSuspense = N, P.isValidElementType = M, P.typeOf = B;
468
470
  }()), P;
469
471
  }
470
472
  var Ue;
471
473
  function lt() {
472
- return Ue || (Ue = 1, process.env.NODE_ENV === "production" ? ae.exports = $n() : ae.exports = Nn()), ae.exports;
474
+ return Ue || (Ue = 1, process.env.NODE_ENV === "production" ? ae.exports = Br() : ae.exports = $r()), ae.exports;
473
475
  }
474
476
  /*
475
477
  object-assign
@@ -477,11 +479,11 @@ object-assign
477
479
  @license MIT
478
480
  */
479
481
  var ge, Ye;
480
- function Ln() {
482
+ function Nr() {
481
483
  if (Ye)
482
484
  return ge;
483
485
  Ye = 1;
484
- var e = Object.getOwnPropertySymbols, n = Object.prototype.hasOwnProperty, r = Object.prototype.propertyIsEnumerable;
486
+ var e = Object.getOwnPropertySymbols, r = Object.prototype.hasOwnProperty, n = Object.prototype.propertyIsEnumerable;
485
487
  function i(s) {
486
488
  if (s == null)
487
489
  throw new TypeError("Object.assign cannot be called with null or undefined");
@@ -513,11 +515,11 @@ function Ln() {
513
515
  for (var f, y = i(s), p, m = 1; m < arguments.length; m++) {
514
516
  f = Object(arguments[m]);
515
517
  for (var h in f)
516
- n.call(f, h) && (y[h] = f[h]);
518
+ r.call(f, h) && (y[h] = f[h]);
517
519
  if (e) {
518
520
  p = e(f);
519
521
  for (var b = 0; b < p.length; b++)
520
- r.call(f, p[b]) && (y[p[b]] = f[p[b]]);
522
+ n.call(f, p[b]) && (y[p[b]] = f[p[b]]);
521
523
  }
522
524
  }
523
525
  return y;
@@ -536,14 +538,14 @@ function dt() {
536
538
  return He || (He = 1, be = Function.call.bind(Object.prototype.hasOwnProperty)), be;
537
539
  }
538
540
  var we, Ke;
539
- function Fn() {
541
+ function Lr() {
540
542
  if (Ke)
541
543
  return we;
542
544
  Ke = 1;
543
545
  var e = function() {
544
546
  };
545
547
  if (process.env.NODE_ENV !== "production") {
546
- var n = Ae(), r = {}, i = dt();
548
+ var r = Ae(), n = {}, i = dt();
547
549
  e = function(s) {
548
550
  var a = "Warning: " + s;
549
551
  typeof console < "u" && console.error(a);
@@ -565,14 +567,14 @@ function Fn() {
565
567
  );
566
568
  throw b.name = "Invariant Violation", b;
567
569
  }
568
- h = s[m](a, m, y, f, null, n);
570
+ h = s[m](a, m, y, f, null, r);
569
571
  } catch (O) {
570
572
  h = O;
571
573
  }
572
574
  if (h && !(h instanceof Error) && e(
573
575
  (y || "React class") + ": type specification of " + f + " `" + m + "` is invalid; the type checker function must return `null` or an `Error` but returned a " + typeof h + ". You may have forgotten to pass an argument to the type checker creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and shape all require an argument)."
574
- ), h instanceof Error && !(h.message in r)) {
575
- r[h.message] = !0;
576
+ ), h instanceof Error && !(h.message in n)) {
577
+ n[h.message] = !0;
576
578
  var v = p ? p() : "";
577
579
  e(
578
580
  "Failed " + f + " type: " + h.message + (v ?? "")
@@ -582,15 +584,15 @@ function Fn() {
582
584
  }
583
585
  }
584
586
  return d.resetWarningCache = function() {
585
- process.env.NODE_ENV !== "production" && (r = {});
587
+ process.env.NODE_ENV !== "production" && (n = {});
586
588
  }, we = d, we;
587
589
  }
588
590
  var Ee, Ve;
589
- function Wn() {
591
+ function Fr() {
590
592
  if (Ve)
591
593
  return Ee;
592
594
  Ve = 1;
593
- var e = lt(), n = Ln(), r = Ae(), i = dt(), d = Fn(), s = function() {
595
+ var e = lt(), r = Nr(), n = Ae(), i = dt(), d = Lr(), s = function() {
594
596
  };
595
597
  process.env.NODE_ENV !== "production" && (s = function(f) {
596
598
  var y = "Warning: " + f;
@@ -642,7 +644,7 @@ function Wn() {
642
644
  if (process.env.NODE_ENV !== "production")
643
645
  var u = {}, j = 0;
644
646
  function S(k, w, T, _, I, R, N) {
645
- if (_ = _ || b, R = R || T, N !== r) {
647
+ if (_ = _ || b, R = R || T, N !== n) {
646
648
  if (y) {
647
649
  var c = new Error(
648
650
  "Calling PropTypes validators directly is not supported by the `prop-types` package. Use `PropTypes.checkPropTypes()` to call them. Read more at http://fb.me/use-check-prop-types"
@@ -688,7 +690,7 @@ function Wn() {
688
690
  return new E("Invalid " + k + " `" + w + "` of type " + ("`" + _ + "` supplied to `" + x + "`, expected an array."));
689
691
  }
690
692
  for (var I = 0; I < T.length; I++) {
691
- var R = o(T, I, x, k, w + "[" + I + "]", r);
693
+ var R = o(T, I, x, k, w + "[" + I + "]", n);
692
694
  if (R instanceof Error)
693
695
  return R;
694
696
  }
@@ -754,7 +756,7 @@ function Wn() {
754
756
  return new E("Invalid " + k + " `" + w + "` of type " + ("`" + _ + "` supplied to `" + x + "`, expected an object."));
755
757
  for (var I in T)
756
758
  if (i(T, I)) {
757
- var R = o(T, I, x, k, w + "." + I, r);
759
+ var R = o(T, I, x, k, w + "." + I, n);
758
760
  if (R instanceof Error)
759
761
  return R;
760
762
  }
@@ -769,12 +771,12 @@ function Wn() {
769
771
  var j = o[u];
770
772
  if (typeof j != "function")
771
773
  return s(
772
- "Invalid argument supplied to oneOfType. Expected an array of check functions, but received " + re(j) + " at index " + u + "."
774
+ "Invalid argument supplied to oneOfType. Expected an array of check functions, but received " + ne(j) + " at index " + u + "."
773
775
  ), a;
774
776
  }
775
777
  function S(x, k, w, T, _) {
776
778
  for (var I = [], R = 0; R < o.length; R++) {
777
- var N = o[R], c = N(x, k, w, T, _, r);
779
+ var N = o[R], c = N(x, k, w, T, _, n);
778
780
  if (c == null)
779
781
  return null;
780
782
  c.data && i(c.data, "expectedType") && I.push(c.data.expectedType);
@@ -790,7 +792,7 @@ function Wn() {
790
792
  }
791
793
  return C(o);
792
794
  }
793
- function ne(o, u, j, S, x) {
795
+ function re(o, u, j, S, x) {
794
796
  return new E(
795
797
  (o || "React class") + ": " + u + " type `" + j + "." + S + "` is invalid; it must be a function, usually from the `prop-types` package, but received `" + x + "`."
796
798
  );
@@ -803,8 +805,8 @@ function Wn() {
803
805
  for (var I in o) {
804
806
  var R = o[I];
805
807
  if (typeof R != "function")
806
- return ne(x, k, w, I, K(R));
807
- var N = R(T, I, x, k, w + "." + I, r);
808
+ return re(x, k, w, I, K(R));
809
+ var N = R(T, I, x, k, w + "." + I, n);
808
810
  if (N)
809
811
  return N;
810
812
  }
@@ -817,17 +819,17 @@ function Wn() {
817
819
  var T = j[S], _ = Y(T);
818
820
  if (_ !== "object")
819
821
  return new E("Invalid " + k + " `" + w + "` of type `" + _ + "` " + ("supplied to `" + x + "`, expected `object`."));
820
- var I = n({}, j[S], o);
822
+ var I = r({}, j[S], o);
821
823
  for (var R in I) {
822
824
  var N = o[R];
823
825
  if (i(o, R) && typeof N != "function")
824
- return ne(x, k, w, R, K(N));
826
+ return re(x, k, w, R, K(N));
825
827
  if (!N)
826
828
  return new E(
827
829
  "Invalid " + k + " `" + w + "` key `" + R + "` supplied to `" + x + "`.\nBad object: " + JSON.stringify(j[S], null, " ") + `
828
830
  Valid keys: ` + JSON.stringify(Object.keys(o), null, " ")
829
831
  );
830
- var c = N(T, R, x, k, w + "." + R, r);
832
+ var c = N(T, R, x, k, w + "." + R, n);
831
833
  if (c)
832
834
  return c;
833
835
  }
@@ -887,7 +889,7 @@ Valid keys: ` + JSON.stringify(Object.keys(o), null, " ")
887
889
  }
888
890
  return u;
889
891
  }
890
- function re(o) {
892
+ function ne(o) {
891
893
  var u = K(o);
892
894
  switch (u) {
893
895
  case "array":
@@ -908,16 +910,16 @@ Valid keys: ` + JSON.stringify(Object.keys(o), null, " ")
908
910
  }, Ee;
909
911
  }
910
912
  var Se, Ge;
911
- function qn() {
913
+ function Wr() {
912
914
  if (Ge)
913
915
  return Se;
914
916
  Ge = 1;
915
917
  var e = Ae();
916
- function n() {
917
- }
918
918
  function r() {
919
919
  }
920
- return r.resetWarningCache = n, Se = function() {
920
+ function n() {
921
+ }
922
+ return n.resetWarningCache = r, Se = function() {
921
923
  function i(a, f, y, p, m, h) {
922
924
  if (h !== e) {
923
925
  var b = new Error(
@@ -950,23 +952,23 @@ function qn() {
950
952
  oneOfType: d,
951
953
  shape: d,
952
954
  exact: d,
953
- checkPropTypes: r,
954
- resetWarningCache: n
955
+ checkPropTypes: n,
956
+ resetWarningCache: r
955
957
  };
956
958
  return s.PropTypes = s, s;
957
959
  }, Se;
958
960
  }
959
961
  if (process.env.NODE_ENV !== "production") {
960
- var Un = lt(), Yn = !0;
961
- Te.exports = Wn()(Un.isElement, Yn);
962
+ var qr = lt(), Ur = !0;
963
+ Te.exports = Fr()(qr.isElement, Ur);
962
964
  } else
963
- Te.exports = qn()();
964
- var zn = Te.exports;
965
- const L = /* @__PURE__ */ _n(zn);
965
+ Te.exports = Wr()();
966
+ var Yr = Te.exports;
967
+ const L = /* @__PURE__ */ kr(Yr);
966
968
  let ut, ft;
967
969
  typeof document < "u" && (ut = document);
968
970
  typeof window < "u" && (ft = window);
969
- const pt = G.createContext({ document: ut, window: ft }), Pe = () => G.useContext(pt), { Provider: Hn, Consumer: Zr } = pt;
971
+ const pt = G.createContext({ document: ut, window: ft }), Pe = () => G.useContext(pt), { Provider: zr, Consumer: Qn } = pt;
970
972
  class ht extends Xe {
971
973
  componentDidMount() {
972
974
  this.props.contentDidMount();
@@ -984,12 +986,12 @@ V(ht, "propTypes", {
984
986
  contentDidUpdate: L.func.isRequired
985
987
  });
986
988
  class je extends Xe {
987
- constructor(r, i) {
988
- super(r, i);
989
- V(this, "setRef", (r) => {
990
- this.nodeRef.current = r;
989
+ constructor(n, i) {
990
+ super(n, i);
991
+ V(this, "setRef", (n) => {
992
+ this.nodeRef.current = n;
991
993
  const { forwardedRef: i } = this.props;
992
- typeof i == "function" ? i(r) : i && (i.current = r);
994
+ typeof i == "function" ? i(n) : i && (i.current = n);
993
995
  });
994
996
  V(this, "handleLoad", () => {
995
997
  clearInterval(this.loadCheck), this.state.iframeLoaded || this.setState({ iframeLoaded: !0 });
@@ -1011,26 +1013,26 @@ class je extends Xe {
1011
1013
  return this.nodeRef.current ? this.nodeRef.current.contentDocument : null;
1012
1014
  }
1013
1015
  getMountTarget() {
1014
- const r = this.getDoc();
1015
- return this.props.mountTarget ? r.querySelector(this.props.mountTarget) : r.body.children[0];
1016
+ const n = this.getDoc();
1017
+ return this.props.mountTarget ? n.querySelector(this.props.mountTarget) : n.body.children[0];
1016
1018
  }
1017
1019
  renderFrameContents() {
1018
1020
  if (!this._isMounted)
1019
1021
  return null;
1020
- const r = this.getDoc();
1021
- if (!r)
1022
+ const n = this.getDoc();
1023
+ if (!n)
1022
1024
  return null;
1023
- const i = this.props.contentDidMount, d = this.props.contentDidUpdate, s = r.defaultView || r.parentView, a = /* @__PURE__ */ t.jsx(ht, { contentDidMount: i, contentDidUpdate: d, children: /* @__PURE__ */ t.jsx(Hn, { value: { document: r, window: s }, children: /* @__PURE__ */ t.jsx("div", { className: "frame-content", children: this.props.children }) }) }), f = this.getMountTarget();
1025
+ const i = this.props.contentDidMount, d = this.props.contentDidUpdate, s = n.defaultView || n.parentView, a = /* @__PURE__ */ t.jsx(ht, { contentDidMount: i, contentDidUpdate: d, children: /* @__PURE__ */ t.jsx(zr, { value: { document: n, window: s }, children: /* @__PURE__ */ t.jsx("div", { className: "frame-content", children: this.props.children }) }) }), f = this.getMountTarget();
1024
1026
  return [Ne.createPortal(this.props.head, this.getDoc().head), Ne.createPortal(a, f)];
1025
1027
  }
1026
1028
  render() {
1027
- const r = {
1029
+ const n = {
1028
1030
  ...this.props,
1029
1031
  srcDoc: this.props.initialContent,
1030
1032
  children: void 0
1031
1033
  // The iframe isn't ready so we drop children from props here. #12, #17
1032
1034
  };
1033
- return delete r.head, delete r.initialContent, delete r.mountTarget, delete r.contentDidMount, delete r.contentDidUpdate, delete r.forwardedRef, /* @__PURE__ */ t.jsx("iframe", { ...r, ref: this.setRef, onLoad: this.handleLoad, children: this.state.iframeLoaded && this.renderFrameContents() });
1035
+ return delete n.head, delete n.initialContent, delete n.mountTarget, delete n.contentDidMount, delete n.contentDidUpdate, delete n.forwardedRef, /* @__PURE__ */ t.jsx("iframe", { ...n, ref: this.setRef, onLoad: this.handleLoad, children: this.state.iframeLoaded && this.renderFrameContents() });
1034
1036
  }
1035
1037
  }
1036
1038
  // React warns when you render directly into the body since browser extensions
@@ -1057,13 +1059,13 @@ V(je, "propTypes", {
1057
1059
  },
1058
1060
  initialContent: '<!DOCTYPE html><html><head></head><body><div class="frame-root"></div></body></html>'
1059
1061
  });
1060
- const Kn = G.forwardRef((e, n) => /* @__PURE__ */ t.jsx(je, { ...e, forwardedRef: n })), Vn = ({ children: e }) => {
1061
- const { document: n } = Pe(), [r] = X(), [i, d] = Z();
1062
+ const Hr = G.forwardRef((e, r) => /* @__PURE__ */ t.jsx(je, { ...e, forwardedRef: r })), Kr = ({ children: e }) => {
1063
+ const { document: r } = Pe(), [n] = X(), [i, d] = Z();
1062
1064
  return F(() => {
1063
1065
  setTimeout(() => {
1064
1066
  if (!ee(i))
1065
1067
  return;
1066
- const s = mt(n, ce(r));
1068
+ const s = mt(r, ce(n));
1067
1069
  if (s) {
1068
1070
  const a = s.getAttribute("data-style-prop");
1069
1071
  if (a) {
@@ -1072,32 +1074,32 @@ const Kn = G.forwardRef((e, n) => /* @__PURE__ */ t.jsx(je, { ...e, forwardedRef
1072
1074
  }
1073
1075
  }
1074
1076
  }, 100);
1075
- }, [n, r, d, i]), /* @__PURE__ */ t.jsx("div", { id: "canvas", className: "relative h-screen max-w-full outline-2", children: e });
1076
- }, mt = (e, n) => e.querySelector(`[data-block-id="${n}"]`), Gn = () => {
1077
- const { window: e } = Pe(), [n, r] = X(), [, i] = Z(), { undo: d, redo: s } = ke(), a = rt(), [, f] = Nt(), [, y] = Lt(), { pasteBlocks: p } = Ft(), [, m] = ot(), h = st(), { savePage: b } = Wt(), [v] = te(qt), [, O] = te(Ut), E = (C) => {
1078
- C.key === "Enter" && (C.preventDefault(), n.length === 1 && O(ce(n)));
1077
+ }, [r, n, d, i]), /* @__PURE__ */ t.jsx("div", { id: "canvas", className: "relative h-screen max-w-full outline-2", children: e });
1078
+ }, mt = (e, r) => e.querySelector(`[data-block-id="${r}"]`), Vr = () => {
1079
+ const { window: e } = Pe(), [r, n] = X(), [, i] = Z(), { undo: d, redo: s } = ke(), a = nt(), [, f] = Nt(), [, y] = Lt(), { pasteBlocks: p } = Ft(), [, m] = ot(), h = st(), { savePage: b } = Wt(), [v] = te(qt), [, O] = te(Ut), E = (C) => {
1080
+ C.key === "Enter" && (C.preventDefault(), r.length === 1 && O(ce(r)));
1079
1081
  };
1080
1082
  return F(() => {
1081
1083
  const C = (g) => {
1082
1084
  if (g.key === "Escape") {
1083
- r([]), i([]);
1085
+ n([]), i([]);
1084
1086
  return;
1085
1087
  }
1086
- if (E(g), !v && (g.key === "Delete" || g.key === "Backspace") && (g.preventDefault(), h(n)), g.ctrlKey || g.metaKey) {
1088
+ if (E(g), !v && (g.key === "Delete" || g.key === "Backspace") && (g.preventDefault(), h(r)), g.ctrlKey || g.metaKey) {
1087
1089
  if (["z", "y", "d", "x", "c", "p", "s", "v"].includes(g.key)) {
1088
1090
  if (v && ["x", "z", "v"].includes(g.key))
1089
1091
  return !0;
1090
1092
  g.preventDefault();
1091
1093
  }
1092
- g.key === "s" && (g.stopPropagation(), g.preventDefault(), b()), g.key === "z" && d(), g.key === "y" && s(), g.key === "d" && a(n), g.key === "x" && f(n), g.key === "c" && y(n), g.key === "v" && n.length > 0 && p(n[0]);
1094
+ g.key === "s" && (g.stopPropagation(), g.preventDefault(), b()), g.key === "z" && d(), g.key === "y" && s(), g.key === "d" && a(r), g.key === "x" && f(r), g.key === "c" && y(r), g.key === "v" && r.length > 0 && p(r[0]);
1093
1095
  }
1094
1096
  };
1095
1097
  return e.removeEventListener("keydown", C), e.addEventListener("keydown", C), () => {
1096
1098
  e.removeEventListener("keydown", C);
1097
1099
  };
1098
1100
  }, [
1099
- n,
1100
1101
  r,
1102
+ n,
1101
1103
  d,
1102
1104
  h,
1103
1105
  m,
@@ -1110,8 +1112,8 @@ const Kn = G.forwardRef((e, n) => /* @__PURE__ */ t.jsx(je, { ...e, forwardedRef
1110
1112
  b,
1111
1113
  e
1112
1114
  ]), null;
1113
- }, Xn = ({ block: e, label: n }) => {
1114
- const [, r] = En(() => ({
1115
+ }, Gr = ({ block: e, label: r }) => {
1116
+ const [, n] = wr(() => ({
1115
1117
  type: "CANVAS_BLOCK",
1116
1118
  item: e
1117
1119
  }));
@@ -1119,30 +1121,30 @@ const Kn = G.forwardRef((e, n) => /* @__PURE__ */ t.jsx(je, { ...e, forwardedRef
1119
1121
  "div",
1120
1122
  {
1121
1123
  className: "mr-10 flex cursor-grab items-center space-x-1 px-1",
1122
- ref: r,
1124
+ ref: n,
1123
1125
  onDragStart: () => {
1124
1126
  console.log("drag start");
1125
1127
  },
1126
1128
  children: [
1127
1129
  /* @__PURE__ */ t.jsx(Mt, {}),
1128
- n
1130
+ r
1129
1131
  ]
1130
1132
  }
1131
1133
  );
1132
- }, Zn = ({
1134
+ }, Xr = ({
1133
1135
  selectedBlockElement: e,
1134
- block: n
1136
+ block: r
1135
1137
  }) => {
1136
- const r = st(), i = rt(), [, d] = X(), [, s] = Z(), { floatingStyles: a, refs: f, update: y } = bn({
1138
+ const n = st(), i = nt(), [, d] = X(), [, s] = Z(), { floatingStyles: a, refs: f, update: y } = xr({
1137
1139
  placement: "top-start",
1138
- middleware: [wn(), xn()],
1140
+ middleware: [br(), gr()],
1139
1141
  elements: {
1140
1142
  reference: e
1141
1143
  }
1142
1144
  });
1143
- Sn(e, () => y(), e !== null);
1144
- const p = $(n, "_parent", null), m = ee($(n, "_name", "")) ? $(n, "_type", "") : $(n, "_name", "");
1145
- return !e || !n ? null : /* @__PURE__ */ t.jsxs(
1145
+ Er(e, () => y(), e !== null);
1146
+ const p = $(r, "_parent", null), m = ee($(r, "_name", "")) ? $(r, "_type", "") : $(r, "_name", "");
1147
+ return !e || !r ? null : /* @__PURE__ */ t.jsxs(
1146
1148
  "div",
1147
1149
  {
1148
1150
  role: "button",
@@ -1155,7 +1157,7 @@ const Kn = G.forwardRef((e, n) => /* @__PURE__ */ t.jsx(je, { ...e, forwardedRef
1155
1157
  onKeyDown: (h) => h.stopPropagation(),
1156
1158
  className: "z-50 flex h-6 items-center bg-blue-500 py-2 text-xs text-white",
1157
1159
  children: [
1158
- /* @__PURE__ */ t.jsx(Xn, { label: m, block: n }),
1160
+ /* @__PURE__ */ t.jsx(Gr, { label: m, block: r }),
1159
1161
  /* @__PURE__ */ t.jsxs("div", { className: "flex gap-2 px-1 ", children: [
1160
1162
  p && /* @__PURE__ */ t.jsx(
1161
1163
  Pt,
@@ -1166,14 +1168,14 @@ const Kn = G.forwardRef((e, n) => /* @__PURE__ */ t.jsx(je, { ...e, forwardedRef
1166
1168
  }
1167
1169
  }
1168
1170
  ),
1169
- Yt($(n, "_type", "")) ? /* @__PURE__ */ t.jsx(It, { className: "hover:scale-105 ", onClick: () => i([n == null ? void 0 : n._id]) }) : null,
1170
- zt($(n, "_type", "")) ? /* @__PURE__ */ t.jsx(Ot, { className: "hover:scale-105 ", onClick: () => r([n == null ? void 0 : n._id]) }) : null
1171
+ Yt($(r, "_type", "")) ? /* @__PURE__ */ t.jsx(It, { className: "hover:scale-105 ", onClick: () => i([r == null ? void 0 : r._id]) }) : null,
1172
+ zt($(r, "_type", "")) ? /* @__PURE__ */ t.jsx(Ot, { className: "hover:scale-105 ", onClick: () => n([r == null ? void 0 : r._id]) }) : null
1171
1173
  ] })
1172
1174
  ]
1173
1175
  }
1174
1176
  );
1175
- }, Jn = ({ model: e }) => {
1176
- const [n] = Ht(), [r] = X(), [i] = tt(), [d] = Re(), [s] = Z(), { document: a, window: f } = Pe(), [y] = H(a == null ? void 0 : a.getElementById("highlighted-block")), [p] = H(
1177
+ }, Zr = ({ model: e }) => {
1178
+ const [r] = Ht(), [n] = X(), [i] = tt(), [d] = Re(), [s] = Z(), { document: a, window: f } = Pe(), [y] = H(a == null ? void 0 : a.getElementById("highlighted-block")), [p] = H(
1177
1179
  a == null ? void 0 : a.getElementById("selected-block")
1178
1180
  ), [m] = H(
1179
1181
  a == null ? void 0 : a.getElementById("selected-styling-block")
@@ -1181,14 +1183,14 @@ const Kn = G.forwardRef((e, n) => /* @__PURE__ */ t.jsx(je, { ...e, forwardedRef
1181
1183
  F(() => {
1182
1184
  i ? a == null || a.documentElement.classList.add("dark") : a == null || a.documentElement.classList.remove("dark");
1183
1185
  }, [i, a]);
1184
- const h = $(n, "_headingFont", "DM Sans"), b = $(n, "_bodyFont", "DM Sans");
1186
+ const h = $(r, "_headingFont", "DM Sans"), b = $(r, "_bodyFont", "DM Sans");
1185
1187
  return F(() => {
1186
- const v = $(n, "_primaryColor", "#000"), O = $(n, "_secondaryColor", "#FFF"), E = Tn({
1188
+ const v = $(r, "_primaryColor", "#000"), O = $(r, "_secondaryColor", "#FFF"), E = Sr({
1187
1189
  colors: [v, O],
1188
1190
  names: ["primary", "secondary"]
1189
1191
  });
1190
1192
  E.primary.DEFAULT = v, E.secondary.DEFAULT = O;
1191
- const C = $(n, "_roundedCorners", "0");
1193
+ const C = $(r, "_roundedCorners", "0");
1192
1194
  !f || !f.tailwind || (f.tailwind.config = {
1193
1195
  darkMode: "class",
1194
1196
  theme: {
@@ -1217,22 +1219,22 @@ const Kn = G.forwardRef((e, n) => /* @__PURE__ */ t.jsx(je, { ...e, forwardedRef
1217
1219
  })
1218
1220
  ]
1219
1221
  });
1220
- }, [n, f, h, b]), F(() => {
1221
- p && (p.textContent = `${ie(r, (v) => `[data-block-id="${v}"]`).join(",")}{
1222
- outline: 1px solid ${r.length === 1 ? "#42a1fc" : "orange"} !important; outline-offset: -1px;
1222
+ }, [r, f, h, b]), F(() => {
1223
+ p && (p.textContent = `${ie(n, (v) => `[data-block-id="${v}"]`).join(",")}{
1224
+ outline: 1px solid ${n.length === 1 ? "#42a1fc" : "orange"} !important; outline-offset: -1px;
1223
1225
  }`);
1224
- }, [r, p]), F(() => {
1226
+ }, [n, p]), F(() => {
1225
1227
  y && (y.textContent = d ? `[data-style-id="${d}"]{ outline: 1px solid orange !important; outline-offset: -1px;}` : "");
1226
- }, [d, r, y]), F(() => {
1228
+ }, [d, n, y]), F(() => {
1227
1229
  m && (m.textContent = `${ie(s, ({ id: v }) => `[data-style-id="${v}"]`).join(",")}{
1228
1230
  outline: 1px solid orange !important; outline-offset: -1px;
1229
1231
  }`);
1230
1232
  }, [s, m]), F(() => {
1231
1233
  if (e === "section")
1232
1234
  return;
1233
- const v = $(n, "_bodyTextLightColor", "#64748b"), O = $(n, "_bodyTextDarkColor", "#94a3b8"), E = $(n, "_bodyBgLightColor", "#FFFFFF"), C = $(n, "_bodyBgDarkColor", "#0f172a");
1235
+ const v = $(r, "_bodyTextLightColor", "#64748b"), O = $(r, "_bodyTextDarkColor", "#94a3b8"), E = $(r, "_bodyBgLightColor", "#FFFFFF"), C = $(r, "_bodyBgDarkColor", "#0f172a");
1234
1236
  a.body.className = `font-body antialiased text-[${v}] bg-[${E}] dark:text-[${O}] dark:bg-[${C}]`;
1235
- }, [n, a, e]), e === "page" ? /* @__PURE__ */ t.jsxs(t.Fragment, { children: [
1237
+ }, [r, a, e]), e === "page" ? /* @__PURE__ */ t.jsxs(t.Fragment, { children: [
1236
1238
  h && /* @__PURE__ */ t.jsx(
1237
1239
  "link",
1238
1240
  {
@@ -1261,52 +1263,52 @@ const Kn = G.forwardRef((e, n) => /* @__PURE__ */ t.jsx(je, { ...e, forwardedRef
1261
1263
  ),
1262
1264
  h && /* @__PURE__ */ t.jsx("style", { children: `h1,h2,h3,h4,h5,h6{font-family: "${h}",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";}` })
1263
1265
  ] }) : null;
1264
- }, Qn = () => {
1266
+ }, Jr = () => {
1265
1267
  const { t: e } = it();
1266
1268
  return /* @__PURE__ */ t.jsx("div", { className: "my-auto py-24 text-center text-gray-600 dark:text-white", children: /* @__PURE__ */ t.jsx("h1", { className: "mb-10 text-4xl ", children: e("canvas_empty") }) });
1267
- }, er = (e) => {
1268
- const n = {};
1269
- return Object.keys(e).forEach((r) => {
1270
- Je(e[r]) && e[r].startsWith($e) && (n[r] = e[r].replace($e, "").split(","));
1271
- }), n;
1272
- }, tr = Tt((e) => {
1273
- const n = e.replace(ct, "").split(",");
1274
- return Cn(n[0], n[1]);
1269
+ }, Qr = (e) => {
1270
+ const r = {};
1271
+ return Object.keys(e).forEach((n) => {
1272
+ Je(e[n]) && e[n].startsWith($e) && (r[n] = e[n].replace($e, "").split(","));
1273
+ }), r;
1274
+ }, en = Tt((e) => {
1275
+ const r = e.replace(ct, "").split(",");
1276
+ return jr(r[0], r[1]);
1275
1277
  });
1276
- function nr(e, n) {
1277
- return $(e, `${n}_attrs`, {});
1278
+ function tn(e, r) {
1279
+ return $(e, `${r}_attrs`, {});
1278
1280
  }
1279
- function rr(e, n, r, i) {
1281
+ function rn(e, r, n, i) {
1280
1282
  const d = {};
1281
1283
  return Object.keys(e).forEach((s) => {
1282
1284
  if (Je(e[s]) && e[s].startsWith(ct)) {
1283
- const a = tr(e[s]);
1285
+ const a = en(e[s]);
1284
1286
  d[s] = {
1285
1287
  className: a,
1286
1288
  "data-style-prop": s,
1287
1289
  "data-block-parent": e._id,
1288
1290
  "data-style-id": `${s}-${e._id}`,
1289
- onMouseEnter: n,
1290
- onMouseLeave: r,
1291
+ onMouseEnter: r,
1292
+ onMouseLeave: n,
1291
1293
  onClick: i,
1292
- ...nr(e, s)
1294
+ ...tn(e, s)
1293
1295
  };
1294
1296
  }
1295
1297
  }), d;
1296
1298
  }
1297
1299
  function Ce({ blocks: e }) {
1298
- const n = at(), [, r] = Re(), [, i] = Z(), [, d] = X(), s = Q(
1300
+ const r = at(), [, n] = Re(), [, i] = Z(), [, d] = X(), s = Q(
1299
1301
  (p) => {
1300
1302
  var h;
1301
1303
  const m = (h = p.currentTarget) == null ? void 0 : h.getAttribute("data-style-id");
1302
- r(m || ""), p.stopPropagation();
1304
+ n(m || ""), p.stopPropagation();
1303
1305
  },
1304
- [r]
1306
+ [n]
1305
1307
  ), a = Q(
1306
1308
  (p) => {
1307
- r(""), p.stopPropagation();
1309
+ n(""), p.stopPropagation();
1308
1310
  },
1309
- [r]
1311
+ [n]
1310
1312
  ), f = Q(
1311
1313
  (p) => {
1312
1314
  p.stopPropagation();
@@ -1321,20 +1323,20 @@ function Ce({ blocks: e }) {
1321
1323
  },
1322
1324
  [i, d]
1323
1325
  ), y = Q(
1324
- (p) => rr(p, s, a, f),
1326
+ (p) => rn(p, s, a, f),
1325
1327
  [s, a]
1326
1328
  );
1327
1329
  return /* @__PURE__ */ t.jsx(t.Fragment, { children: G.Children.toArray(
1328
1330
  e.map((p, m) => {
1329
- const h = er(p), b = {};
1331
+ const h = Qr(p), b = {};
1330
1332
  ee(h) || Object.keys(h).forEach((C) => {
1331
1333
  b[C] = G.Children.toArray(
1332
- h[C].map((g) => /* @__PURE__ */ t.jsx(Ce, { blocks: [jt(n, { _id: g })] }))
1334
+ h[C].map((g) => /* @__PURE__ */ t.jsx(Ce, { blocks: [jt(r, { _id: g })] }))
1333
1335
  );
1334
1336
  });
1335
- const v = Ze(n, { _parent: p._id });
1337
+ const v = Ze(r, { _parent: p._id });
1336
1338
  b.children = v.length ? /* @__PURE__ */ t.jsx(Ce, { blocks: v }) : null;
1337
- const O = kn(p._type), E = (O == null ? void 0 : O.component) || null;
1339
+ const O = Cr(p._type), E = (O == null ? void 0 : O.component) || null;
1338
1340
  return G.createElement(E, {
1339
1341
  blockProps: {
1340
1342
  onClick: f,
@@ -1350,15 +1352,15 @@ function Ce({ blocks: e }) {
1350
1352
  })
1351
1353
  ) });
1352
1354
  }
1353
- const or = () => {
1355
+ const nn = () => {
1354
1356
  const e = at();
1355
- return /* @__PURE__ */ t.jsx(jn, { children: e.length ? /* @__PURE__ */ t.jsx(Ce, { blocks: Ze(e, (n) => ee(n._parent)) }) : /* @__PURE__ */ t.jsx(Qn, {}) });
1356
- }, sr = (e, n) => e.querySelector(`[data-style-id="${n}"]`), ar = () => {
1357
- const [e] = te(Kt), [n] = ot(), [r] = _e(), [, i] = X(), d = Vt(), [, s] = Re(), a = Oe(null), f = Oe(null), [y, p] = H({ width: 0, height: 0 }), m = Bn(y), [h, b] = H(0), [v, O] = H([]), [, E] = H([]), [, C] = te(Gt), [g, U] = Z(), M = Qe("loadingCanvas", !1);
1357
+ return /* @__PURE__ */ t.jsx(Tr, { children: e.length ? /* @__PURE__ */ t.jsx(Ce, { blocks: Ze(e, (r) => ee(r._parent)) }) : /* @__PURE__ */ t.jsx(Jr, {}) });
1358
+ }, on = (e, r) => e.querySelector(`[data-style-id="${r}"]`), sn = () => {
1359
+ const [e] = te(Kt), [r] = ot(), [n] = _e(), [, i] = X(), d = Vt(), [, s] = Re(), a = Oe(null), f = Oe(null), [y, p] = H({ width: 0, height: 0 }), m = Dr(y), [h, b] = H(0), [v, O] = H([]), [, E] = H([]), [, C] = te(Gt), [g, U] = Z(), M = Qe("loadingCanvas", !1);
1358
1360
  F(() => {
1359
1361
  const { clientWidth: D, clientHeight: W } = f.current;
1360
1362
  p({ width: D, height: W }), h === 0 && b(D);
1361
- }, [f, r, h]);
1363
+ }, [f, n, h]);
1362
1364
  const B = (D, W = 0) => {
1363
1365
  const { top: q } = D.getBoundingClientRect();
1364
1366
  return q + W >= 0 && q - W <= window.innerHeight;
@@ -1371,7 +1373,7 @@ const or = () => {
1371
1373
  }
1372
1374
  }, [d]), F(() => {
1373
1375
  if (!ee(g) && a.current) {
1374
- const D = sr(
1376
+ const D = on(
1375
1377
  a.current.contentDocument,
1376
1378
  ce(g).id
1377
1379
  );
@@ -1380,7 +1382,7 @@ const or = () => {
1380
1382
  E([null]);
1381
1383
  }, [g]);
1382
1384
  const l = bt(() => {
1383
- let D = Dn;
1385
+ let D = Mr;
1384
1386
  return e === "offline" && (D = D.replace(
1385
1387
  "https://cdn.tailwindcss.com?plugins=forms,typography,aspect-ratio",
1386
1388
  "/offline/tailwind.cdn.js"
@@ -1394,29 +1396,29 @@ const or = () => {
1394
1396
  },
1395
1397
  onMouseLeave: () => setTimeout(() => s(""), 300),
1396
1398
  className: "relative mx-auto h-full w-full bg-black/80",
1397
- style: h > 0 && !ee(m) ? { width: n ? "100%" : h } : {},
1399
+ style: h > 0 && !ee(m) ? { width: r ? "100%" : h } : {},
1398
1400
  ref: f,
1399
1401
  children: /* @__PURE__ */ t.jsxs(
1400
- Kn,
1402
+ Hr,
1401
1403
  {
1402
1404
  contentDidMount: () => C(a.current),
1403
1405
  ref: a,
1404
1406
  id: "canvas-iframe",
1405
- style: { width: `${r}px`, ...m },
1407
+ style: { width: `${n}px`, ...m },
1406
1408
  className: "relative mx-auto box-content h-full max-w-full shadow-md transition-all duration-300 ease-linear",
1407
1409
  initialContent: l,
1408
1410
  children: [
1409
- /* @__PURE__ */ t.jsx(Gn, {}),
1411
+ /* @__PURE__ */ t.jsx(Vr, {}),
1410
1412
  /* @__PURE__ */ t.jsx(
1411
- Zn,
1413
+ Xr,
1412
1414
  {
1413
1415
  block: d,
1414
1416
  selectedBlockElement: ce(v)
1415
1417
  }
1416
1418
  ),
1417
- /* @__PURE__ */ t.jsx(Jn, { model: "page" }),
1418
- /* @__PURE__ */ t.jsxs(Vn, { children: [
1419
- M ? /* @__PURE__ */ t.jsx("div", { className: "h-full p-4", children: /* @__PURE__ */ t.jsx(et, { className: "h-full" }) }) : /* @__PURE__ */ t.jsx(or, {}),
1419
+ /* @__PURE__ */ t.jsx(Zr, { model: "page" }),
1420
+ /* @__PURE__ */ t.jsxs(Kr, { children: [
1421
+ M ? /* @__PURE__ */ t.jsx("div", { className: "h-full p-4", children: /* @__PURE__ */ t.jsx(et, { className: "h-full" }) }) : /* @__PURE__ */ t.jsx(nn, {}),
1420
1422
  /* @__PURE__ */ t.jsx("div", { className: "h-60" })
1421
1423
  ] })
1422
1424
  ]
@@ -1424,26 +1426,26 @@ const or = () => {
1424
1426
  )
1425
1427
  }
1426
1428
  );
1427
- }, ir = wt(() => import("./AddBlocks-b6a12d50.js")), Jr = () => {
1428
- const e = Qe("mode", ve.STATIC), [n, r] = te(Xt), i = {
1429
- [ve.STATIC]: /* @__PURE__ */ t.jsx(ar, {}),
1429
+ }, an = wt(() => import("./AddBlocks-671fde09.js")), eo = () => {
1430
+ const e = Qe("mode", ve.STATIC), [r, n] = te(Xt), i = {
1431
+ [ve.STATIC]: /* @__PURE__ */ t.jsx(sn, {}),
1430
1432
  [ve.FRAMEWORK]: null
1431
1433
  }[e];
1432
1434
  return /* @__PURE__ */ t.jsxs("div", { className: "flex h-full w-full flex-col", children: [
1433
- /* @__PURE__ */ t.jsx(Mn, {}),
1435
+ /* @__PURE__ */ t.jsx(Or, {}),
1434
1436
  /* @__PURE__ */ t.jsxs("div", { className: "relative flex-1 overflow-hidden bg-slate-800/20 bg-[linear-gradient(to_right,#EEE_0.5px,transparent_0.5px),linear-gradient(to_bottom,#EEE_0.5px,transparent_0.5px)] bg-[size:12px_12px]", children: [
1435
1437
  /* @__PURE__ */ t.jsx(Et, { fallback: /* @__PURE__ */ t.jsx(et, { className: "h-full" }), children: /* @__PURE__ */ t.jsx(Zt, { children: i }) }),
1436
- n ? /* @__PURE__ */ t.jsx(
1438
+ r ? /* @__PURE__ */ t.jsx(
1437
1439
  "div",
1438
1440
  {
1439
- onClick: () => r(!1),
1441
+ onClick: () => n(!1),
1440
1442
  className: "absolute inset-0 z-50 flex items-center bg-black/30 backdrop-blur-sm",
1441
1443
  children: /* @__PURE__ */ t.jsx(
1442
1444
  "div",
1443
1445
  {
1444
1446
  onClick: (d) => d.stopPropagation(),
1445
1447
  className: "mx-auto h-[90%] w-[90%] max-w-3xl rounded-md bg-white p-4 shadow-lg shadow-black/10 xl:w-[65%]",
1446
- children: /* @__PURE__ */ t.jsx(ir, {})
1448
+ children: /* @__PURE__ */ t.jsx(an, {})
1447
1449
  }
1448
1450
  )
1449
1451
  }
@@ -1452,5 +1454,5 @@ const or = () => {
1452
1454
  ] });
1453
1455
  };
1454
1456
  export {
1455
- Jr as default
1457
+ eo as default
1456
1458
  };