@chaibuilder/sdk 3.2.8 → 4.0.0-beta.2

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 (184) hide show
  1. package/README.md +25 -20
  2. package/dist/2SSKDMRQ-C4VFVd-q.cjs +1 -0
  3. package/dist/2SSKDMRQ-DSnzF_1o.js +42 -0
  4. package/dist/AP7HFJJL-B7YYCY9q.cjs +1228 -0
  5. package/dist/AP7HFJJL-Cxwj01Aq.js +9214 -0
  6. package/dist/IconPicker-C9-ieDWm.cjs +1 -0
  7. package/dist/IconPicker-RqVvq6G2.js +59 -0
  8. package/dist/WDYDFRGG-C7aSUcjs.js +33 -0
  9. package/dist/WDYDFRGG-b3T2SQbz.cjs +1 -0
  10. package/dist/_commonjsHelpers-C6fGbg64.js +6 -0
  11. package/dist/_commonjsHelpers-DwGv2jUC.cjs +1 -0
  12. package/dist/actions-registery-CZ1w0NKa.js +15545 -0
  13. package/dist/actions-registery-YnFmU21O.cjs +418 -0
  14. package/dist/actions.cjs +1 -0
  15. package/dist/actions.d.ts +3202 -0
  16. package/dist/actions.js +216 -0
  17. package/dist/active-in-another-tab-Clng6zpY.cjs +1 -0
  18. package/dist/active-in-another-tab-wb8qolB8.js +34 -0
  19. package/dist/add-new-language-page-C4BuMTaN.cjs +1 -0
  20. package/dist/add-new-language-page-D7NDABl1.js +401 -0
  21. package/dist/add-new-page-B4hc0B-g.js +31 -0
  22. package/dist/add-new-page-BNfwKjRd.cjs +1 -0
  23. package/dist/ai-panel-content-BnbURb7j.js +61 -0
  24. package/dist/ai-panel-content-DPy2jgKw.cjs +1 -0
  25. package/dist/ai-panel-default-lang-3tCHzab5.cjs +3 -0
  26. package/dist/ai-panel-default-lang-oVk4TDeb.js +341 -0
  27. package/dist/ai-panel-other-lang-BBHCCSen.cjs +1 -0
  28. package/dist/ai-panel-other-lang-DmQ3QMDD.js +162 -0
  29. package/dist/ai-prompt-input-DaTyfib-.js +655 -0
  30. package/dist/ai-prompt-input-b5ty81RB.cjs +1 -0
  31. package/dist/ai-translation-prompt-DJPe2O-n.js +28 -0
  32. package/dist/ai-translation-prompt-c0Q3zkT2.cjs +1 -0
  33. package/dist/{apply-binding-DLaiD20q.js → apply-binding-6iwlED02.js} +156 -166
  34. package/dist/apply-binding-KKp5PnpZ.cjs +1 -0
  35. package/dist/{code-display-DuH-UOhl.js → code-display-BzBq5xSn.js} +1 -1
  36. package/dist/code-display-Q3_sK_Ta.cjs +1 -0
  37. package/dist/code-editor-BQZi6-FB.cjs +1 -0
  38. package/dist/code-editor-DWWnphW9.js +50 -0
  39. package/dist/continue-editing-in-this-client-BllU94XG.js +24 -0
  40. package/dist/continue-editing-in-this-client-D9HyD4GP.cjs +1 -0
  41. package/dist/core-BoRDjj4h.cjs +1 -0
  42. package/dist/core-yvI6kCyw.js +56 -0
  43. package/dist/core.cjs +1 -1
  44. package/dist/core.d.ts +2 -393
  45. package/dist/core.js +37 -105
  46. package/dist/css-import-modal-BSMGKA2T.cjs +13 -0
  47. package/dist/{css-import-modal-CFB2YjDT.js → css-import-modal-D72a-16X.js} +39 -38
  48. package/dist/{delete-design-token-BjMakV-b.js → delete-design-token-Cd1ZDtqT.js} +3 -3
  49. package/dist/delete-design-token-D_TLlO3I.cjs +1 -0
  50. package/dist/delete-page-ByQwBupJ.cjs +1 -0
  51. package/dist/delete-page-DC8pzvWW.js +70 -0
  52. package/dist/design-token-usage-BqZeR1sT.cjs +1 -0
  53. package/dist/design-token-usage-DE4XCDdn.js +113 -0
  54. package/dist/digital-asset-manager-BYLKFEYi.cjs +1 -0
  55. package/dist/digital-asset-manager-C_gL_0YY.js +876 -0
  56. package/dist/duplicate-page-BoVhko2q.js +133 -0
  57. package/dist/duplicate-page-vdvwLQLo.cjs +1 -0
  58. package/dist/dynamic-page-selector-CSndg2-y.js +85 -0
  59. package/dist/dynamic-page-selector-DdnbCuQZ.cjs +1 -0
  60. package/dist/fonts-B-Xt29pe.cjs +1 -0
  61. package/dist/fonts-DRly3Wzd.js +78 -0
  62. package/dist/{get-chai-builder-tailwind-config-C6MHaUM0.cjs → get-chai-builder-tailwind-config-B9rCyiQo.cjs} +1 -1
  63. package/dist/{get-chai-builder-tailwind-config-BqaIvg8p.js → get-chai-builder-tailwind-config-DjoVOuAf.js} +13 -10
  64. package/dist/get-chai-builder-theme-BYtp20KD.js +24 -0
  65. package/dist/get-chai-builder-theme-Dl72X7cz.cjs +1 -0
  66. package/dist/get-seo-defaults-9zHebckY.js +65 -0
  67. package/dist/get-seo-defaults-Cw7vFt-B.cjs +1 -0
  68. package/dist/image-compression-DZ9WMmyn.cjs +1 -0
  69. package/dist/image-compression-DsZ1oqpb.js +37 -0
  70. package/dist/image-editor-DTspjj_c.cjs +1 -0
  71. package/dist/image-editor-oypq8asR.js +108 -0
  72. package/dist/index-B-rSiAp_.cjs +1 -0
  73. package/dist/index-BDnwJqMw.js +4732 -0
  74. package/dist/index-CbwxUFy_.cjs +5 -0
  75. package/dist/index-CnSjWE1P.cjs +160 -0
  76. package/dist/index-Dxfyt4d4.js +39 -0
  77. package/dist/index-S8ibZk9Q.js +19069 -0
  78. package/dist/json-diff-viewer-B5dr-Y_L.js +258 -0
  79. package/dist/json-diff-viewer-XX1pgabt.cjs +8 -0
  80. package/dist/lang-panel-BPxex-M2.cjs +1 -0
  81. package/dist/lang-panel-Cn83SRzd.js +215 -0
  82. package/dist/manage-design-tokens-ConiyuPr.cjs +1 -0
  83. package/dist/{manage-design-tokens-DUoMdCBl.js → manage-design-tokens-lP4HLS0P.js} +31 -32
  84. package/dist/mark-as-template-DYRxre1f.cjs +1 -0
  85. package/dist/mark-as-template-jncsjfHm.js +156 -0
  86. package/dist/models-5gOsRC56.cjs +1 -0
  87. package/dist/models-D95ZYr_x.js +70 -0
  88. package/dist/nested-path-selector-content-B-8LqhXI.js +87 -0
  89. package/dist/nested-path-selector-content-BYtLi7mC.cjs +1 -0
  90. package/dist/no-language-page-content-DAbLq0gX.cjs +1 -0
  91. package/dist/no-language-page-content-D_zd9Rb0.js +42 -0
  92. package/dist/no-language-page-dialog-C5Ps6YYL.js +10 -0
  93. package/dist/no-language-page-dialog-fXmbQO7L.cjs +1 -0
  94. package/dist/page-creator-VWIB2VAs.cjs +1 -0
  95. package/dist/page-creator-wCMtlE6Z.js +795 -0
  96. package/dist/page-lock-BPCxfv9J.js +30 -0
  97. package/dist/page-lock-DweiYy1w.cjs +1 -0
  98. package/dist/page-locked-dialog-BlbgvaG2.cjs +1 -0
  99. package/dist/page-locked-dialog-ByGl18_m.js +133 -0
  100. package/dist/page-manager-new-BWFE-S-O.js +394 -0
  101. package/dist/page-manager-new-D0lGfNnS.cjs +1 -0
  102. package/dist/page-manager-search-and-filter-DpGMoOII.cjs +1 -0
  103. package/dist/page-manager-search-and-filter-kNJFWJ86.js +201 -0
  104. package/dist/page-revisions-content-DYxXZqmh.cjs +1 -0
  105. package/dist/page-revisions-content-Ulr8slUN.js +445 -0
  106. package/dist/pages.cjs +1 -0
  107. package/dist/pages.d.ts +492 -0
  108. package/dist/pages.js +27 -0
  109. package/dist/{plugin-BOcGV_IY.js → plugin-3ZKK6RXm.js} +30 -44
  110. package/dist/plugin-C6rgJDNQ.cjs +22 -0
  111. package/dist/publish-pages-content-BTPzt_m4.js +178 -0
  112. package/dist/publish-pages-content-D6g8GAsd.cjs +1 -0
  113. package/dist/register-partial-type-BjtdfKHE.js +36 -0
  114. package/dist/register-partial-type-ig9fUWIJ.cjs +1 -0
  115. package/dist/render.cjs +2 -2
  116. package/dist/render.d.ts +12 -9
  117. package/dist/render.js +97 -99
  118. package/dist/rte-widget-modal-DrMzWWjw.cjs +1 -0
  119. package/dist/rte-widget-modal-Rk_NW3KU.js +38 -0
  120. package/dist/runtime.cjs +1 -1
  121. package/dist/runtime.d.ts +306 -7
  122. package/dist/runtime.js +44 -1
  123. package/dist/save-to-lib-BK3uTFss.js +422 -0
  124. package/dist/save-to-lib-DHHUO12i.cjs +1 -0
  125. package/dist/sdk.css +1 -1
  126. package/dist/selected-block-display-CU3TwIMA.js +319 -0
  127. package/dist/selected-block-display-DSFhddPj.cjs +16 -0
  128. package/dist/seo-panel-Dl0IDV09.cjs +2 -0
  129. package/dist/seo-panel-jbzxFioc.js +798 -0
  130. package/dist/shared-json-ld-BL_dv3_q.js +565 -0
  131. package/dist/shared-json-ld-DPNkqDC1.cjs +1 -0
  132. package/dist/slug-input-1qwKkXhA.js +86 -0
  133. package/dist/slug-input-YVLjtTI3.cjs +1 -0
  134. package/dist/supabase-actions.cjs +1 -0
  135. package/dist/supabase-actions.d.ts +284 -0
  136. package/dist/supabase-actions.js +524 -0
  137. package/dist/take-over-request-DKvKi3mM.js +63 -0
  138. package/dist/take-over-request-DvMIg_cZ.cjs +1 -0
  139. package/dist/theme-panel-footer-BMOaPLWc.cjs +1 -0
  140. package/dist/theme-panel-footer-DbMDLYGI.js +25 -0
  141. package/dist/translation-warning-modal-9wTwIy_9.js +26 -0
  142. package/dist/translation-warning-modal-DjTwz75c.cjs +1 -0
  143. package/dist/unmark-as-template-CdqIJJER.cjs +1 -0
  144. package/dist/unmark-as-template-Dulvf7Zw.js +39 -0
  145. package/dist/unpublish-page-BwSVBf0_.cjs +1 -0
  146. package/dist/unpublish-page-Degu5Cy9.js +27 -0
  147. package/dist/use-page-expand-manager-B6XTvk0E.cjs +1 -0
  148. package/dist/use-page-expand-manager-Cf4MUEJw.js +85 -0
  149. package/dist/utils.cjs +1 -0
  150. package/dist/{tailwind.d.ts → utils.d.ts} +4 -7
  151. package/dist/utils.js +7 -0
  152. package/dist/web-blocks.cjs +1 -1
  153. package/dist/web-blocks.d.ts +0 -6
  154. package/dist/web-blocks.js +48 -47
  155. package/dist/web-preview-DXE4Jnf5.js +73 -0
  156. package/dist/web-preview-YzKxyXft.cjs +1 -0
  157. package/package.json +159 -89
  158. package/dist/IconPicker-6JSublJp.js +0 -64
  159. package/dist/IconPicker-DpQQDK_Q.cjs +0 -1
  160. package/dist/apply-binding-Bn1KC8uC.cjs +0 -1
  161. package/dist/code-display-Dw1tAwiJ.cjs +0 -1
  162. package/dist/code-editor-cnBzYLxk.cjs +0 -1
  163. package/dist/code-editor-vpbOSO05.js +0 -59
  164. package/dist/css-import-modal-bGWZSlqv.cjs +0 -13
  165. package/dist/delete-design-token-Bzxspf8D.cjs +0 -1
  166. package/dist/design-token-usage-BDArZ38H.js +0 -120
  167. package/dist/design-token-usage-CCv4XltM.cjs +0 -1
  168. package/dist/get-chai-builder-theme-B1tr_NJB.cjs +0 -1
  169. package/dist/get-chai-builder-theme-BarMkcGH.js +0 -12
  170. package/dist/index-CuANr9iH.cjs +0 -160
  171. package/dist/index-DvdOXKUE.js +0 -18338
  172. package/dist/manage-design-tokens-DpC46NAy.cjs +0 -1
  173. package/dist/mockServiceWorker.js +0 -349
  174. package/dist/plugin-CSgw-f78.cjs +0 -22
  175. package/dist/rte-widget-modal-CXbmmhcb.js +0 -41
  176. package/dist/rte-widget-modal-DDjf0xui.cjs +0 -1
  177. package/dist/tailwind.cjs +0 -1
  178. package/dist/tailwind.js +0 -8
  179. package/dist/tooltip-Ba1-8jmj.cjs +0 -1
  180. package/dist/tooltip-DUosa-uC.js +0 -1067
  181. package/dist/ui.cjs +0 -1
  182. package/dist/ui.d.ts +0 -415
  183. package/dist/ui.js +0 -129
  184. package/dist/vite.svg +0 -1
@@ -1,10 +1,11 @@
1
- import { registerChaiBlockSchema as p, StylesProp as u, registerChaiBlock as d, getRegisteredChaiBlock as U, stylesProp as L, closestBlockProp as Z } from "@chaibuilder/runtime";
1
+ import { isEmpty as w, get as k, map as R, isNull as U, omit as M, pick as H } from "lodash-es";
2
2
  import { jsx as i, jsxs as h, Fragment as N } from "react/jsx-runtime";
3
+ import { r as p, S as u, s as L } from "./index-Dxfyt4d4.js";
3
4
  import { c as _, g as I } from "./common-functions-D2lMFR6K.js";
4
5
  import * as b from "react";
5
6
  import { createElement as x } from "react";
6
- import { ButtonIcon as M, CodeIcon as H, FrameIcon as $, SketchLogoIcon as q, LayoutIcon as G, RowsIcon as j, DividerHorizontalIcon as W, CheckboxIcon as O, FileTextIcon as Y, InputIcon as D, LetterCaseToggleIcon as Q, RadiobuttonIcon as J, DropdownMenuIcon as X, HeadingIcon as K, TableIcon as ee, BorderTopIcon as te, BorderAllIcon as oe, ViewHorizontalIcon as le, DragHandleHorizontalIcon as re, ImageIcon as ne, Link1Icon as ie, ColumnsIcon as ae, TextIcon as se, CursorTextIcon as ce, SpaceBetweenVerticallyIcon as de, VideoIcon as pe, ChevronLeftIcon as ue, ChevronRightIcon as me, LoopIcon as V } from "@radix-ui/react-icons";
7
- import { isEmpty as w, get as k, map as R, isNull as ye, omit as z, pick as F } from "lodash-es";
7
+ import { ButtonIcon as $, CodeIcon as j, FrameIcon as D, SketchLogoIcon as Z, RowsIcon as V, LayoutIcon as q, DividerHorizontalIcon as G, CheckboxIcon as W, FileTextIcon as O, InputIcon as z, LetterCaseToggleIcon as Y, RadiobuttonIcon as Q, DropdownMenuIcon as J, HeadingIcon as X, TableIcon as K, BorderTopIcon as ee, BorderAllIcon as te, ViewHorizontalIcon as oe, DragHandleHorizontalIcon as le, ImageIcon as re, Link1Icon as ne, ColumnsIcon as ie, TextIcon as ae, CursorTextIcon as se, SpaceBetweenVerticallyIcon as ce, VideoIcon as de, ChevronLeftIcon as pe, ChevronRightIcon as ue, LoopIcon as F } from "@radix-ui/react-icons";
8
+ import { r as d, e as me, c as ye } from "./core-yvI6kCyw.js";
8
9
  const C = ({ className: e = "", inBuilder: o }) => o ? /* @__PURE__ */ i("div", { className: _("pointer-events-none flex h-20 flex-col items-center justify-center p-2", e), children: /* @__PURE__ */ i("div", { className: "h-full w-full rounded bg-gray-200 p-2 dark:bg-gray-800", children: /* @__PURE__ */ i("div", { className: "flex h-full w-full items-center justify-center outline-dashed outline-1 -outline-offset-1 outline-gray-400 duration-300 dark:outline-gray-700" }) }) }) : null, ge = (e) => {
9
10
  const { blockProps: o, inBuilder: t, backgroundImage: l, children: r, tag: n = "div", styles: a } = e;
10
11
  let s = r;
@@ -80,7 +81,7 @@ const C = ({ className: e = "", inBuilder: o }) => o ? /* @__PURE__ */ i("div",
80
81
  description: "similar to a button element in HTML",
81
82
  label: "Button",
82
83
  category: "core",
83
- icon: M,
84
+ icon: $,
84
85
  group: "basic",
85
86
  ...p({
86
87
  properties: {
@@ -149,7 +150,7 @@ const C = ({ className: e = "", inBuilder: o }) => o ? /* @__PURE__ */ i("div",
149
150
  description: "similar to a div or section elements in HTML",
150
151
  label: "Custom HTML",
151
152
  category: "core",
152
- icon: H,
153
+ icon: j,
153
154
  group: "advanced",
154
155
  ...p({
155
156
  properties: {
@@ -170,7 +171,7 @@ const C = ({ className: e = "", inBuilder: o }) => o ? /* @__PURE__ */ i("div",
170
171
  description: "similar to a script element in HTML",
171
172
  label: "Custom Script",
172
173
  category: "core",
173
- icon: H,
174
+ icon: j,
174
175
  hidden: !0,
175
176
  group: "advanced",
176
177
  ...p({
@@ -204,7 +205,7 @@ const C = ({ className: e = "", inBuilder: o }) => o ? /* @__PURE__ */ i("div",
204
205
  type: "GlobalBlock",
205
206
  description: "A global block component",
206
207
  label: "Global Block",
207
- icon: $,
208
+ icon: D,
208
209
  category: "core",
209
210
  group: "basic",
210
211
  hidden: !0,
@@ -240,7 +241,7 @@ const C = ({ className: e = "", inBuilder: o }) => o ? /* @__PURE__ */ i("div",
240
241
  label: "web_blocks.icon",
241
242
  category: "core",
242
243
  description: "Icon block is used to display an icon/svg.",
243
- icon: q,
244
+ icon: Z,
244
245
  group: "media",
245
246
  ...p({
246
247
  properties: {
@@ -283,7 +284,7 @@ const C = ({ className: e = "", inBuilder: o }) => o ? /* @__PURE__ */ i("div",
283
284
  type: "PartialBlock",
284
285
  description: "A partial block component. Partial blocks are global blocks that can be used in multiple pages.",
285
286
  label: "Partial Block",
286
- icon: $,
287
+ icon: D,
287
288
  category: "core",
288
289
  group: "basic",
289
290
  hidden: !0,
@@ -354,7 +355,7 @@ const C = ({ className: e = "", inBuilder: o }) => o ? /* @__PURE__ */ i("div",
354
355
  label: "Column",
355
356
  group: "basic",
356
357
  category: "core",
357
- icon: G,
358
+ icon: q,
358
359
  wrapper: !0,
359
360
  hidden: !0,
360
361
  canDelete: () => !0,
@@ -393,7 +394,7 @@ const C = ({ className: e = "", inBuilder: o }) => o ? /* @__PURE__ */ i("div",
393
394
  description: "A row component",
394
395
  label: "Row",
395
396
  group: "basic",
396
- icon: j,
397
+ icon: V,
397
398
  hidden: !0,
398
399
  blocks: () => [
399
400
  { _type: "Row", _id: "row", styles: "#styles:,p-1" },
@@ -428,7 +429,7 @@ const C = ({ className: e = "", inBuilder: o }) => o ? /* @__PURE__ */ i("div",
428
429
  description: "A horizontal line component",
429
430
  label: "Divider",
430
431
  category: "core",
431
- icon: W,
432
+ icon: G,
432
433
  group: "basic",
433
434
  ...p({
434
435
  properties: {
@@ -477,7 +478,7 @@ const C = ({ className: e = "", inBuilder: o }) => o ? /* @__PURE__ */ i("div",
477
478
  type: "Checkbox",
478
479
  label: "web_blocks.checkbox",
479
480
  category: "core",
480
- icon: O,
481
+ icon: W,
481
482
  group: "form",
482
483
  ...p({
483
484
  properties: {
@@ -541,7 +542,7 @@ const C = ({ className: e = "", inBuilder: o }) => o ? /* @__PURE__ */ i("div",
541
542
  type: "Form",
542
543
  label: "Form",
543
544
  category: "core",
544
- icon: Y,
545
+ icon: O,
545
546
  group: "form",
546
547
  blocks: () => [
547
548
  { _type: "Form", _id: "form", styles: "#styles:p-1 space-y-2," },
@@ -595,7 +596,7 @@ const C = ({ className: e = "", inBuilder: o }) => o ? /* @__PURE__ */ i("div",
595
596
  type: "FormButton",
596
597
  label: "Submit Button",
597
598
  category: "core",
598
- icon: M,
599
+ icon: $,
599
600
  group: "form",
600
601
  ...p({
601
602
  properties: {
@@ -743,7 +744,7 @@ const C = ({ className: e = "", inBuilder: o }) => o ? /* @__PURE__ */ i("div",
743
744
  type: "Input",
744
745
  label: "web_blocks.input",
745
746
  category: "core",
746
- icon: D,
747
+ icon: z,
747
748
  group: "form",
748
749
  ...p({
749
750
  properties: {
@@ -864,7 +865,7 @@ const C = ({ className: e = "", inBuilder: o }) => o ? /* @__PURE__ */ i("div",
864
865
  type: "Label",
865
866
  label: "Label",
866
867
  category: "core",
867
- icon: Q,
868
+ icon: Y,
868
869
  group: "form",
869
870
  ...p({
870
871
  properties: {
@@ -899,7 +900,7 @@ const C = ({ className: e = "", inBuilder: o }) => o ? /* @__PURE__ */ i("div",
899
900
  type: "Radio",
900
901
  label: "web_blocks.radio",
901
902
  category: "core",
902
- icon: J,
903
+ icon: Q,
903
904
  group: "form",
904
905
  ...p({
905
906
  properties: {
@@ -983,7 +984,7 @@ const C = ({ className: e = "", inBuilder: o }) => o ? /* @__PURE__ */ i("div",
983
984
  type: "Select",
984
985
  label: "web_blocks.select",
985
986
  category: "core",
986
- icon: X,
987
+ icon: J,
987
988
  group: "form",
988
989
  ...p({
989
990
  properties: {
@@ -1080,7 +1081,7 @@ const C = ({ className: e = "", inBuilder: o }) => o ? /* @__PURE__ */ i("div",
1080
1081
  type: "TextArea",
1081
1082
  label: "web_blocks.textarea",
1082
1083
  category: "core",
1083
- icon: D,
1084
+ icon: z,
1084
1085
  group: "form",
1085
1086
  ...p({
1086
1087
  properties: {
@@ -1139,7 +1140,7 @@ const C = ({ className: e = "", inBuilder: o }) => o ? /* @__PURE__ */ i("div",
1139
1140
  description: "A heading component similar to h1, h2, h3, h4, h5, h6 elements in HTML",
1140
1141
  label: "Heading",
1141
1142
  category: "core",
1142
- icon: K,
1143
+ icon: X,
1143
1144
  group: "typography",
1144
1145
  ...p({
1145
1146
  properties: {
@@ -1205,7 +1206,7 @@ d(rt, {
1205
1206
  category: "core",
1206
1207
  group: "table",
1207
1208
  hidden: !0,
1208
- icon: ee,
1209
+ icon: K,
1209
1210
  ...p({
1210
1211
  properties: {
1211
1212
  styles: u("")
@@ -1219,7 +1220,7 @@ d(nt, {
1219
1220
  category: "core",
1220
1221
  group: "table",
1221
1222
  hidden: !0,
1222
- icon: te,
1223
+ icon: ee,
1223
1224
  ...p({
1224
1225
  properties: {
1225
1226
  styles: u("")
@@ -1233,7 +1234,7 @@ d(it, {
1233
1234
  category: "core",
1234
1235
  group: "table",
1235
1236
  hidden: !0,
1236
- icon: oe,
1237
+ icon: te,
1237
1238
  ...p({
1238
1239
  properties: {
1239
1240
  styles: u("")
@@ -1247,7 +1248,7 @@ d(at, {
1247
1248
  category: "core",
1248
1249
  group: "table",
1249
1250
  hidden: !0,
1250
- icon: le,
1251
+ icon: oe,
1251
1252
  ...p({
1252
1253
  properties: {
1253
1254
  styles: u("")
@@ -1261,7 +1262,7 @@ d(st, {
1261
1262
  category: "core",
1262
1263
  group: "table",
1263
1264
  hidden: !0,
1264
- icon: re,
1265
+ icon: le,
1265
1266
  ...p({
1266
1267
  properties: {
1267
1268
  styles: u(""),
@@ -1342,7 +1343,7 @@ const ct = "data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iNTAwIiBoZWlnaHQ9IjQwMCIgeG
1342
1343
  description: "A image component",
1343
1344
  label: "Image",
1344
1345
  category: "core",
1345
- icon: ne,
1346
+ icon: re,
1346
1347
  group: "media",
1347
1348
  ...p({
1348
1349
  properties: {
@@ -1426,7 +1427,7 @@ const ct = "data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iNTAwIiBoZWlnaHQ9IjQwMCIgeG
1426
1427
  description: "A link component",
1427
1428
  label: "Link",
1428
1429
  category: "core",
1429
- icon: ie,
1430
+ icon: ne,
1430
1431
  group: "basic",
1431
1432
  ...p({
1432
1433
  properties: {
@@ -1469,7 +1470,7 @@ const ct = "data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iNTAwIiBoZWlnaHQ9IjQwMCIgeG
1469
1470
  type: "List",
1470
1471
  description: "A list component",
1471
1472
  label: "List",
1472
- icon: j,
1473
+ icon: V,
1473
1474
  category: "core",
1474
1475
  group: "basic",
1475
1476
  ...p({
@@ -1513,7 +1514,7 @@ const ct = "data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iNTAwIiBoZWlnaHQ9IjQwMCIgeG
1513
1514
  type: "ListItem",
1514
1515
  description: "A list item component",
1515
1516
  label: "List Item",
1516
- icon: ae,
1517
+ icon: ie,
1517
1518
  category: "core",
1518
1519
  group: "basic",
1519
1520
  ...p({
@@ -1535,7 +1536,7 @@ const ct = "data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iNTAwIiBoZWlnaHQ9IjQwMCIgeG
1535
1536
  canBeNested: (e) => e === "List" || e === "Repeater"
1536
1537
  }, ht = (e) => {
1537
1538
  const { blockProps: o, styles: t, content: l } = e;
1538
- if (!ye(e.children)) return b.createElement("p", { ...t, ...o }, e.children);
1539
+ if (!U(e.children)) return b.createElement("p", { ...t, ...o }, e.children);
1539
1540
  const r = T(t, "rte");
1540
1541
  return b.createElement("div", {
1541
1542
  ...r,
@@ -1547,7 +1548,7 @@ const ct = "data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iNTAwIiBoZWlnaHQ9IjQwMCIgeG
1547
1548
  description: "A paragraph component",
1548
1549
  label: "Paragraph",
1549
1550
  category: "core",
1550
- icon: se,
1551
+ icon: ae,
1551
1552
  group: "typography",
1552
1553
  ...p({
1553
1554
  properties: {
@@ -1572,7 +1573,7 @@ const ct = "data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iNTAwIiBoZWlnaHQ9IjQwMCIgeG
1572
1573
  label: "Rich Text",
1573
1574
  hidden: !0,
1574
1575
  category: "core",
1575
- icon: ce,
1576
+ icon: se,
1576
1577
  group: "typography",
1577
1578
  ...p({
1578
1579
  properties: {
@@ -1621,7 +1622,7 @@ const ct = "data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iNTAwIiBoZWlnaHQ9IjQwMCIgeG
1621
1622
  category: "core",
1622
1623
  group: "typography",
1623
1624
  blocks: () => [{ _id: "a", _type: "Text", _name: "Text", content: "" }],
1624
- icon: de,
1625
+ icon: ce,
1625
1626
  ...p({
1626
1627
  properties: {
1627
1628
  styles: u("text-black"),
@@ -1686,8 +1687,8 @@ const ct = "data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iNTAwIiBoZWlnaHQ9IjQwMCIgeG
1686
1687
  return null;
1687
1688
  }, Bt = (e) => {
1688
1689
  const { url: o, blockProps: t, styles: l, controls: r, videoSource: n, inBuilder: a, title: s } = e, c = Lt(o, r);
1689
- return /* @__PURE__ */ h("div", { ...z(l, "className"), className: "relative w-full overflow-hidden", style: { paddingBottom: "56.25%" }, children: [
1690
- !c && a ? /* @__PURE__ */ i("div", { className: "absolute flex h-full w-full items-center justify-center bg-gray-300 text-center", children: w(o) ? `Provided ${n} video link in settings Video URL.` : `Provided ${n} video link is invalid.` }) : /* @__PURE__ */ i("iframe", { width: "100%", src: c, title: s || "Video player", ...F(l, "className") }),
1690
+ return /* @__PURE__ */ h("div", { ...M(l, "className"), className: "relative w-full overflow-hidden", style: { paddingBottom: "56.25%" }, children: [
1691
+ !c && a ? /* @__PURE__ */ i("div", { className: "absolute flex h-full w-full items-center justify-center bg-gray-300 text-center", children: w(o) ? `Provided ${n} video link in settings Video URL.` : `Provided ${n} video link is invalid.` }) : /* @__PURE__ */ i("iframe", { width: "100%", src: c, title: s || "Video player", ...H(l, "className") }),
1691
1692
  a && /* @__PURE__ */ i("div", { ...t, className: "absolute top-0 h-full w-full" })
1692
1693
  ] });
1693
1694
  }, St = (e) => {
@@ -1728,7 +1729,7 @@ const ct = "data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iNTAwIiBoZWlnaHQ9IjQwMCIgeG
1728
1729
  type: "Video",
1729
1730
  label: "Video",
1730
1731
  category: "core",
1731
- icon: pe,
1732
+ icon: de,
1732
1733
  group: "media",
1733
1734
  ...p({
1734
1735
  properties: {
@@ -1815,14 +1816,14 @@ const ct = "data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iNTAwIiBoZWlnaHQ9IjQwMCIgeG
1815
1816
  }),
1816
1817
  i18nProps: ["url", "title"]
1817
1818
  }, Tt = (e) => {
1818
- const { paginationStyles: o } = e, t = U("Pagination");
1819
- return /* @__PURE__ */ i("div", { ...o, children: t ? b.createElement(t.component, { ...z(e, ["paginationStyles"]), blockProps: {} }) : /* @__PURE__ */ h(N, { children: [
1819
+ const { paginationStyles: o } = e, t = me("Pagination");
1820
+ return /* @__PURE__ */ i("div", { ...o, children: t ? b.createElement(t.component, { ...M(e, ["paginationStyles"]), blockProps: {} }) : /* @__PURE__ */ h(N, { children: [
1820
1821
  /* @__PURE__ */ i(
1821
1822
  "button",
1822
1823
  {
1823
1824
  className: "flex h-9 w-9 items-center justify-center rounded-md border border-gray-300 bg-white hover:bg-gray-50 disabled:cursor-not-allowed disabled:opacity-50",
1824
1825
  disabled: !0,
1825
- children: /* @__PURE__ */ i(ue, { className: "h-4 w-4" })
1826
+ children: /* @__PURE__ */ i(pe, { className: "h-4 w-4" })
1826
1827
  }
1827
1828
  ),
1828
1829
  /* @__PURE__ */ i("button", { className: "flex h-9 w-9 items-center justify-center rounded-md border border-blue-500 bg-blue-500 font-medium text-white", children: "1" }),
@@ -1830,7 +1831,7 @@ const ct = "data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iNTAwIiBoZWlnaHQ9IjQwMCIgeG
1830
1831
  /* @__PURE__ */ i("button", { className: "flex h-9 w-9 items-center justify-center rounded-md border border-gray-300 bg-white font-medium text-gray-700 hover:bg-gray-50", children: "3" }),
1831
1832
  /* @__PURE__ */ i("button", { className: "flex h-9 w-9 items-center justify-center rounded-md border border-gray-300 bg-white font-medium text-gray-700 hover:bg-gray-50", children: "4" }),
1832
1833
  /* @__PURE__ */ i("button", { className: "flex h-9 w-9 items-center justify-center rounded-md border border-gray-300 bg-white font-medium text-gray-700 hover:bg-gray-50", children: "5" }),
1833
- /* @__PURE__ */ i("button", { className: "flex h-9 w-9 items-center justify-center rounded-md border border-gray-300 bg-white hover:bg-gray-50", children: /* @__PURE__ */ i(me, { className: "h-4 w-4" }) })
1834
+ /* @__PURE__ */ i("button", { className: "flex h-9 w-9 items-center justify-center rounded-md border border-gray-300 bg-white hover:bg-gray-50", children: /* @__PURE__ */ i(ue, { className: "h-4 w-4" }) })
1834
1835
  ] }) });
1835
1836
  }, Rt = (e) => {
1836
1837
  const { children: o, tag: t, styles: l, blockProps: r, $loading: n } = e, { pagination: a, inBuilder: s } = e;
@@ -1850,7 +1851,7 @@ const ct = "data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iNTAwIiBoZWlnaHQ9IjQwMCIgeG
1850
1851
  a && /* @__PURE__ */ i(
1851
1852
  Tt,
1852
1853
  {
1853
- ...F(e, [
1854
+ ...H(e, [
1854
1855
  "limit",
1855
1856
  "totalItems",
1856
1857
  "paginationStrategy",
@@ -1865,7 +1866,7 @@ const ct = "data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iNTAwIiBoZWlnaHQ9IjQwMCIgeG
1865
1866
  }, At = {
1866
1867
  type: "Repeater",
1867
1868
  label: "Repeater",
1868
- icon: V,
1869
+ icon: F,
1869
1870
  group: "basic",
1870
1871
  description: "Repeater block is used to display a list of items based on data binding in repeaterItems",
1871
1872
  dataProviderMode: "live",
@@ -1983,13 +1984,13 @@ const ct = "data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iNTAwIiBoZWlnaHQ9IjQwMCIgeG
1983
1984
  }, Mt = {
1984
1985
  type: "RepeaterItem",
1985
1986
  label: "Repeater Item",
1986
- icon: V,
1987
+ icon: F,
1987
1988
  hidden: !0,
1988
1989
  group: "basic",
1989
1990
  ...p({
1990
1991
  properties: {
1991
1992
  styles: L(""),
1992
- parentTag: Z("Repeater", "tag")
1993
+ parentTag: ye("Repeater", "tag")
1993
1994
  }
1994
1995
  }),
1995
1996
  canAcceptBlock: (e) => e !== "RepeaterItem",
@@ -2012,9 +2013,9 @@ const ct = "data:image/svg+xml;base64,PHN2ZyB3aWR0aD0iNTAwIiBoZWlnaHQ9IjQwMCIgeG
2012
2013
  canDelete: () => !1,
2013
2014
  canMove: () => !1,
2014
2015
  canDuplicate: () => !1
2015
- }, Zt = () => {
2016
+ }, qt = () => {
2016
2017
  d(ge, be), d(Me, He), d(fe, he), d(et, tt), d(ht, kt), d(vt, Ct), d(xt, wt), d(ut, mt), d(yt, gt), d(bt, ft), d(Pe, Le), d(dt, pt), d(Nt, _t), d(ke, xe), d(we, ve), d(It, Pt), d(De, Ve), d(ze, Fe), d(Ze, qe), d($e, je), d(Oe, Ye), d(Qe, Je), d(Xe, Ke), d(Ge, We), d(ot, lt), d(Ae, Ee), d(Ce, Ie), d(Be, Se), d(Te, Re), d(Ne, _e), d(Rt, At), d(Et, Mt), d(Ht, $t);
2017
2018
  };
2018
2019
  export {
2019
- Zt as loadWebBlocks
2020
+ qt as loadWebBlocks
2020
2021
  };
@@ -0,0 +1,73 @@
1
+ import { jsxs as n, jsx as e } from "react/jsx-runtime";
2
+ import { useState as d, createElement as m } from "react";
3
+ import { B as s } from "./index-S8ibZk9Q.js";
4
+ import { useAtom as h } from "jotai";
5
+ import { map as p } from "lodash-es";
6
+ import { Smartphone as w, Tablet as f, Laptop as u, LaptopMinimal as x } from "lucide-react";
7
+ import { p as v, T as _ } from "./index-BDnwJqMw.js";
8
+ const b = [
9
+ {
10
+ title: "mobile_xs_title",
11
+ content: "mobile_xs_content",
12
+ icon: /* @__PURE__ */ e(w, { className: "h-4 w-4" }),
13
+ width: 400
14
+ },
15
+ {
16
+ title: "tablet_md_title",
17
+ content: "tablet_md_content",
18
+ icon: /* @__PURE__ */ e(f, { className: "h-4 w-4" }),
19
+ width: 800
20
+ },
21
+ {
22
+ title: "desktop_xl_title",
23
+ content: "desktop_xl_content",
24
+ icon: /* @__PURE__ */ e(u, { className: "h-4 w-4" }),
25
+ width: 1200
26
+ },
27
+ {
28
+ title: "large_desktop_2xl_title",
29
+ content: "large_desktop_2xl_content",
30
+ icon: /* @__PURE__ */ e(x, { className: "h-4 w-4" }),
31
+ width: 1600
32
+ }
33
+ ], g = ({ currentWidth: t, width: r, icon: l, setIframeWidth: o }) => /* @__PURE__ */ e(
34
+ s,
35
+ {
36
+ className: "px-3 py-3",
37
+ onClick: () => o(r),
38
+ variant: r === t ? "default" : "ghost",
39
+ children: l
40
+ }
41
+ ), j = () => {
42
+ const [t, r] = d(1200), l = (i) => r(i), [o, a] = h(v);
43
+ if (!o) return null;
44
+ const c = () => {
45
+ a("");
46
+ };
47
+ return /* @__PURE__ */ n("div", { className: "absolute inset-0 z-[999999] flex h-screen w-screen flex-col overflow-hidden bg-gray-100", children: [
48
+ /* @__PURE__ */ n("div", { className: "flex h-[50px] items-center justify-center border-b border-gray-200 px-4 shadow-sm", children: [
49
+ /* @__PURE__ */ e("div", { className: "flex items-center justify-center rounded-md border border-gray-300", children: p(b, (i) => /* @__PURE__ */ m(g, { ...i, setIframeWidth: l, key: i.title, currentWidth: t })) }),
50
+ " ",
51
+ /* @__PURE__ */ e(_, { content: "Exit Preview", delayDuration: 0, children: /* @__PURE__ */ e(s, { variant: "destructive", size: "sm", onClick: c, children: /* @__PURE__ */ e("svg", { width: "15", height: "15", viewBox: "0 0 15 15", fill: "none", xmlns: "http://www.w3.org/2000/svg", children: /* @__PURE__ */ e(
52
+ "path",
53
+ {
54
+ d: "M2 3C2 2.44772 2.44772 2 3 2H12C12.5523 2 13 2.44772 13 3V12C13 12.5523 12.5523 13 12 13H3C2.44772 13 2 12.5523 2 12V3ZM12 3H3V12H12V3Z",
55
+ fill: "currentColor",
56
+ fillRule: "evenodd",
57
+ "clip-rule": "evenodd"
58
+ }
59
+ ) }) }) })
60
+ ] }),
61
+ /* @__PURE__ */ e(
62
+ "iframe",
63
+ {
64
+ style: { width: `${t}px`, transition: "width 0.3s ease-in-out" },
65
+ className: "no-scrollbar mx-auto h-full overflow-y-auto border bg-white",
66
+ src: o
67
+ }
68
+ )
69
+ ] });
70
+ };
71
+ export {
72
+ j as default
73
+ };
@@ -0,0 +1 @@
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("react/jsx-runtime"),l=require("react"),a=require("./index-CnSjWE1P.cjs"),h=require("jotai"),x=require("lodash-es"),n=require("lucide-react"),c=require("./index-CbwxUFy_.cjs"),m=[{title:"mobile_xs_title",content:"mobile_xs_content",icon:e.jsx(n.Smartphone,{className:"h-4 w-4"}),width:400},{title:"tablet_md_title",content:"tablet_md_content",icon:e.jsx(n.Tablet,{className:"h-4 w-4"}),width:800},{title:"desktop_xl_title",content:"desktop_xl_content",icon:e.jsx(n.Laptop,{className:"h-4 w-4"}),width:1200},{title:"large_desktop_2xl_title",content:"large_desktop_2xl_content",icon:e.jsx(n.LaptopMinimal,{className:"h-4 w-4"}),width:1600}],w=({currentWidth:t,width:s,icon:o,setIframeWidth:r})=>e.jsx(a.Button,{className:"px-3 py-3",onClick:()=>r(s),variant:s===t?"default":"ghost",children:o}),p=()=>{const[t,s]=l.useState(1200),o=i=>s(i),[r,d]=h.useAtom(c.previewUrlAtom);if(!r)return null;const u=()=>{d("")};return e.jsxs("div",{className:"absolute inset-0 z-[999999] flex h-screen w-screen flex-col overflow-hidden bg-gray-100",children:[e.jsxs("div",{className:"flex h-[50px] items-center justify-center border-b border-gray-200 px-4 shadow-sm",children:[e.jsx("div",{className:"flex items-center justify-center rounded-md border border-gray-300",children:x.map(m,i=>l.createElement(w,{...i,setIframeWidth:o,key:i.title,currentWidth:t}))})," ",e.jsx(c.Tooltip,{content:"Exit Preview",delayDuration:0,children:e.jsx(a.Button,{variant:"destructive",size:"sm",onClick:u,children:e.jsx("svg",{width:"15",height:"15",viewBox:"0 0 15 15",fill:"none",xmlns:"http://www.w3.org/2000/svg",children:e.jsx("path",{d:"M2 3C2 2.44772 2.44772 2 3 2H12C12.5523 2 13 2.44772 13 3V12C13 12.5523 12.5523 13 12 13H3C2.44772 13 2 12.5523 2 12V3ZM12 3H3V12H12V3Z",fill:"currentColor",fillRule:"evenodd","clip-rule":"evenodd"})})})})]}),e.jsx("iframe",{style:{width:`${t}px`,transition:"width 0.3s ease-in-out"},className:"no-scrollbar mx-auto h-full overflow-y-auto border bg-white",src:r})]})};exports.default=p;