@chaibuilder/sdk 0.1.0

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 (80) hide show
  1. package/README.md +41 -0
  2. package/dist/AddBlocks-04c49399.js +258 -0
  3. package/dist/AddBlocks-c27c81fa.cjs +3 -0
  4. package/dist/BrandingOptions-055cf22a.js +157 -0
  5. package/dist/BrandingOptions-c25f6370.cjs +1 -0
  6. package/dist/CONTROLS-031e1de3.cjs +1 -0
  7. package/dist/CONTROLS-442caee5.js +6 -0
  8. package/dist/CanvasArea-97dfbb52.cjs +60 -0
  9. package/dist/CanvasArea-a7901131.js +1455 -0
  10. package/dist/Class-0801d193.cjs +1 -0
  11. package/dist/Class-e6b07b79.js +1138 -0
  12. package/dist/ImagesPanel-160aa664.cjs +1 -0
  13. package/dist/ImagesPanel-815d5e6f.js +27 -0
  14. package/dist/Layers-3aa6aae7.cjs +1 -0
  15. package/dist/Layers-6f1c162e.js +370 -0
  16. package/dist/MarkAsGlobalBlock-209ddfd5.js +73 -0
  17. package/dist/MarkAsGlobalBlock-536770e7.cjs +1 -0
  18. package/dist/Settings-2b1ff1a3.cjs +1 -0
  19. package/dist/Settings-b1afcefe.js +1845 -0
  20. package/dist/SidePanels-f48777bb.js +144 -0
  21. package/dist/SidePanels-f79dbace.cjs +1 -0
  22. package/dist/Topbar-64729901.js +105 -0
  23. package/dist/Topbar-bff765dc.cjs +1 -0
  24. package/dist/UnsplashImages-04fffeed.cjs +1 -0
  25. package/dist/UnsplashImages-315ce7a8.js +160 -0
  26. package/dist/UploadImages-43c16a2d.cjs +1 -0
  27. package/dist/UploadImages-f317eef0.js +107 -0
  28. package/dist/_commonjsHelpers-5a53b418.cjs +1 -0
  29. package/dist/_commonjsHelpers-d4512b9c.js +6 -0
  30. package/dist/accordion-0afd8143.cjs +1 -0
  31. package/dist/accordion-c0176dc5.js +42 -0
  32. package/dist/context-menu-e1c240ce.js +122 -0
  33. package/dist/context-menu-fec580f2.cjs +1 -0
  34. package/dist/core.cjs +1 -0
  35. package/dist/core.d.ts +353 -0
  36. package/dist/core.js +83 -0
  37. package/dist/dialog-170eaad9.cjs +1 -0
  38. package/dist/dialog-3d4e82ed.js +65 -0
  39. package/dist/dropdown-menu-a9b096f9.cjs +1 -0
  40. package/dist/dropdown-menu-d912a52e.js +223 -0
  41. package/dist/html-to-json-d8ac554d.cjs +1 -0
  42. package/dist/html-to-json-fecbbe16.js +178 -0
  43. package/dist/index-aea5c557.cjs +2 -0
  44. package/dist/index-cdd49c4c.js +2651 -0
  45. package/dist/jsx-runtime-5c3ac4f7.cjs +27 -0
  46. package/dist/jsx-runtime-944c88e2.js +631 -0
  47. package/dist/label-167415e5.cjs +1 -0
  48. package/dist/label-e770a087.js +10 -0
  49. package/dist/lib.cjs +1 -0
  50. package/dist/lib.d.ts +29 -0
  51. package/dist/lib.js +223 -0
  52. package/dist/link-43d13383.cjs +1 -0
  53. package/dist/link-8594fd8f.js +211 -0
  54. package/dist/popover-7cb9079b.cjs +1 -0
  55. package/dist/popover-f7addcf4.js +23 -0
  56. package/dist/render.cjs +2 -0
  57. package/dist/render.d.ts +49 -0
  58. package/dist/render.js +1171 -0
  59. package/dist/scroll-area-088530b9.cjs +1 -0
  60. package/dist/scroll-area-9f64a082.js +30 -0
  61. package/dist/select-0e32300c.cjs +1 -0
  62. package/dist/select-7fddd7c3.js +75 -0
  63. package/dist/separator-a597dba7.cjs +1 -0
  64. package/dist/separator-a80d065b.js +18 -0
  65. package/dist/style.css +6 -0
  66. package/dist/tabs-85caa1e8.js +46 -0
  67. package/dist/tabs-860e37aa.cjs +1 -0
  68. package/dist/textarea-0750bcd2.js +73 -0
  69. package/dist/textarea-a338ede6.cjs +1 -0
  70. package/dist/toggle-00c9d11e.js +30 -0
  71. package/dist/toggle-b90fed97.cjs +1 -0
  72. package/dist/ui.cjs +1 -0
  73. package/dist/ui.d.ts +471 -0
  74. package/dist/ui.js +442 -0
  75. package/dist/useBuilderProp-5e57d0c8.cjs +1 -0
  76. package/dist/useBuilderProp-81a14920.js +238 -0
  77. package/dist/utils-3c452dd0.cjs +1 -0
  78. package/dist/utils-ac68b2c8.js +6 -0
  79. package/dist/vite.svg +1 -0
  80. package/package.json +156 -0
package/dist/render.js ADDED
@@ -0,0 +1,1171 @@
1
+ import { j as s } from "./jsx-runtime-944c88e2.js";
2
+ import u from "react";
3
+ import { memoize as S, filter as f, isEmpty as w, omit as E, isString as z, get as i, replace as C, set as F } from "lodash";
4
+ import { twMerge as v } from "tailwind-merge";
5
+ import { S as D, a as k } from "./CONTROLS-442caee5.js";
6
+ import { getBlockComponent as A } from "chaibuilder-blocks";
7
+ import { Provider as L } from "react-wrap-balancer";
8
+ import { createTailwindcss as $ } from "@mhsdesign/jit-browser-tailwindcss";
9
+ import { tailwindcssPaletteGenerator as j } from "@bobthered/tailwindcss-palette-generator";
10
+ import { g as U } from "./_commonjsHelpers-d4512b9c.js";
11
+ import O from "@tailwindcss/forms";
12
+ import R from "@tailwindcss/typography";
13
+ import B from "@tailwindcss/aspect-ratio";
14
+ import H from "@tailwindcss/line-clamp";
15
+ const M = (e) => {
16
+ const t = {};
17
+ return Object.keys(e).forEach((r) => {
18
+ z(e[r]) && e[r].startsWith(k) && (t[r] = e[r].replace(k, "").split(","));
19
+ }), t;
20
+ }, P = S((e) => {
21
+ const t = e.replace(D, "").split(",");
22
+ return v(t[0], t[1]);
23
+ });
24
+ function W(e, t) {
25
+ return i(e, `${t}_attrs`, {});
26
+ }
27
+ function I(e) {
28
+ const t = {};
29
+ return Object.keys(e).forEach((r) => {
30
+ if (z(e[r]) && e[r].startsWith(D)) {
31
+ const n = P(e[r]);
32
+ t[r] = {
33
+ className: n,
34
+ ...W(e, r)
35
+ };
36
+ }
37
+ }), t;
38
+ }
39
+ function y({ blocks: e, parent: t }) {
40
+ const r = e, n = (o) => I(o), a = t ? f(e, { _parent: t }) : f(e, (o) => w(o._parent));
41
+ return /* @__PURE__ */ s.jsx(s.Fragment, { children: u.Children.toArray(
42
+ a.map((o, d) => {
43
+ const p = M(o), m = {};
44
+ w(p) || Object.keys(p).forEach((l) => {
45
+ m[l] = u.Children.toArray(
46
+ p[l].map((x) => /* @__PURE__ */ s.jsx(y, { blocks: r, parent: x }))
47
+ );
48
+ });
49
+ const c = f(r, { _parent: o._id });
50
+ m.children = c.length > 0 ? /* @__PURE__ */ s.jsx(y, { parent: o._id, blocks: r }) : null;
51
+ const g = A(o._type);
52
+ if (g !== null) {
53
+ let l = o;
54
+ const x = g.component;
55
+ return l = { ...g.defaults, ...o }, u.createElement(
56
+ x,
57
+ E(
58
+ {
59
+ blockProps: {},
60
+ ...l,
61
+ index: d,
62
+ ...n(l),
63
+ ...m,
64
+ inBuilder: !1
65
+ },
66
+ ["_parent"]
67
+ )
68
+ );
69
+ }
70
+ return /* @__PURE__ */ s.jsxs("noscript", { children: [
71
+ o._type,
72
+ " not found"
73
+ ] });
74
+ })
75
+ ) });
76
+ }
77
+ const N = (e) => {
78
+ const t = i(e, "_bodyTextLightColor", "#64748b"), r = i(e, "_bodyTextDarkColor", "#94a3b8"), n = i(e, "_bodyBgLightColor", "#FFFFFF"), a = i(e, "_bodyBgDarkColor", "#0f172a");
79
+ return `font-body antialiased text-[${t}] bg-[${n}] dark:text-[${r}] dark:bg-[${a}]`;
80
+ }, me = ({ snapshot: e, before: t = null, after: r = null, classPrefix: n = "c-" }) => {
81
+ const a = i(e.projectData, "brandingOptions", {});
82
+ return /* @__PURE__ */ s.jsxs(s.Fragment, { children: [
83
+ t,
84
+ /* @__PURE__ */ s.jsx("div", { className: n.replace("-", "") + " " + N(a) + " min-h-screen", children: /* @__PURE__ */ s.jsx(L, { children: /* @__PURE__ */ s.jsx(y, { blocks: e.pageData.blocks || [] }) }) }),
85
+ r
86
+ ] });
87
+ };
88
+ var T = {}, _ = {};
89
+ (function(e) {
90
+ Object.defineProperty(e, "__esModule", {
91
+ value: !0
92
+ }), Object.defineProperty(e, "cloneDeep", {
93
+ enumerable: !0,
94
+ get: function() {
95
+ return t;
96
+ }
97
+ });
98
+ function t(r) {
99
+ return Array.isArray(r) ? r.map((n) => t(n)) : typeof r == "object" && r !== null ? Object.fromEntries(Object.entries(r).map(([n, a]) => [
100
+ n,
101
+ t(a)
102
+ ])) : r;
103
+ }
104
+ })(_);
105
+ var q = {
106
+ content: [],
107
+ presets: [],
108
+ darkMode: "media",
109
+ // or 'class'
110
+ theme: {
111
+ accentColor: ({ theme: e }) => ({
112
+ ...e("colors"),
113
+ auto: "auto"
114
+ }),
115
+ animation: {
116
+ none: "none",
117
+ spin: "spin 1s linear infinite",
118
+ ping: "ping 1s cubic-bezier(0, 0, 0.2, 1) infinite",
119
+ pulse: "pulse 2s cubic-bezier(0.4, 0, 0.6, 1) infinite",
120
+ bounce: "bounce 1s infinite"
121
+ },
122
+ aria: {
123
+ busy: 'busy="true"',
124
+ checked: 'checked="true"',
125
+ disabled: 'disabled="true"',
126
+ expanded: 'expanded="true"',
127
+ hidden: 'hidden="true"',
128
+ pressed: 'pressed="true"',
129
+ readonly: 'readonly="true"',
130
+ required: 'required="true"',
131
+ selected: 'selected="true"'
132
+ },
133
+ aspectRatio: {
134
+ auto: "auto",
135
+ square: "1 / 1",
136
+ video: "16 / 9"
137
+ },
138
+ backdropBlur: ({ theme: e }) => e("blur"),
139
+ backdropBrightness: ({ theme: e }) => e("brightness"),
140
+ backdropContrast: ({ theme: e }) => e("contrast"),
141
+ backdropGrayscale: ({ theme: e }) => e("grayscale"),
142
+ backdropHueRotate: ({ theme: e }) => e("hueRotate"),
143
+ backdropInvert: ({ theme: e }) => e("invert"),
144
+ backdropOpacity: ({ theme: e }) => e("opacity"),
145
+ backdropSaturate: ({ theme: e }) => e("saturate"),
146
+ backdropSepia: ({ theme: e }) => e("sepia"),
147
+ backgroundColor: ({ theme: e }) => e("colors"),
148
+ backgroundImage: {
149
+ none: "none",
150
+ "gradient-to-t": "linear-gradient(to top, var(--tw-gradient-stops))",
151
+ "gradient-to-tr": "linear-gradient(to top right, var(--tw-gradient-stops))",
152
+ "gradient-to-r": "linear-gradient(to right, var(--tw-gradient-stops))",
153
+ "gradient-to-br": "linear-gradient(to bottom right, var(--tw-gradient-stops))",
154
+ "gradient-to-b": "linear-gradient(to bottom, var(--tw-gradient-stops))",
155
+ "gradient-to-bl": "linear-gradient(to bottom left, var(--tw-gradient-stops))",
156
+ "gradient-to-l": "linear-gradient(to left, var(--tw-gradient-stops))",
157
+ "gradient-to-tl": "linear-gradient(to top left, var(--tw-gradient-stops))"
158
+ },
159
+ backgroundOpacity: ({ theme: e }) => e("opacity"),
160
+ backgroundPosition: {
161
+ bottom: "bottom",
162
+ center: "center",
163
+ left: "left",
164
+ "left-bottom": "left bottom",
165
+ "left-top": "left top",
166
+ right: "right",
167
+ "right-bottom": "right bottom",
168
+ "right-top": "right top",
169
+ top: "top"
170
+ },
171
+ backgroundSize: {
172
+ auto: "auto",
173
+ cover: "cover",
174
+ contain: "contain"
175
+ },
176
+ blur: {
177
+ 0: "0",
178
+ none: "0",
179
+ sm: "4px",
180
+ DEFAULT: "8px",
181
+ md: "12px",
182
+ lg: "16px",
183
+ xl: "24px",
184
+ "2xl": "40px",
185
+ "3xl": "64px"
186
+ },
187
+ borderColor: ({ theme: e }) => ({
188
+ ...e("colors"),
189
+ DEFAULT: e("colors.gray.200", "currentColor")
190
+ }),
191
+ borderOpacity: ({ theme: e }) => e("opacity"),
192
+ borderRadius: {
193
+ none: "0px",
194
+ sm: "0.125rem",
195
+ DEFAULT: "0.25rem",
196
+ md: "0.375rem",
197
+ lg: "0.5rem",
198
+ xl: "0.75rem",
199
+ "2xl": "1rem",
200
+ "3xl": "1.5rem",
201
+ full: "9999px"
202
+ },
203
+ borderSpacing: ({ theme: e }) => ({
204
+ ...e("spacing")
205
+ }),
206
+ borderWidth: {
207
+ DEFAULT: "1px",
208
+ 0: "0px",
209
+ 2: "2px",
210
+ 4: "4px",
211
+ 8: "8px"
212
+ },
213
+ boxShadow: {
214
+ sm: "0 1px 2px 0 rgb(0 0 0 / 0.05)",
215
+ DEFAULT: "0 1px 3px 0 rgb(0 0 0 / 0.1), 0 1px 2px -1px rgb(0 0 0 / 0.1)",
216
+ md: "0 4px 6px -1px rgb(0 0 0 / 0.1), 0 2px 4px -2px rgb(0 0 0 / 0.1)",
217
+ lg: "0 10px 15px -3px rgb(0 0 0 / 0.1), 0 4px 6px -4px rgb(0 0 0 / 0.1)",
218
+ xl: "0 20px 25px -5px rgb(0 0 0 / 0.1), 0 8px 10px -6px rgb(0 0 0 / 0.1)",
219
+ "2xl": "0 25px 50px -12px rgb(0 0 0 / 0.25)",
220
+ inner: "inset 0 2px 4px 0 rgb(0 0 0 / 0.05)",
221
+ none: "none"
222
+ },
223
+ boxShadowColor: ({ theme: e }) => e("colors"),
224
+ brightness: {
225
+ 0: "0",
226
+ 50: ".5",
227
+ 75: ".75",
228
+ 90: ".9",
229
+ 95: ".95",
230
+ 100: "1",
231
+ 105: "1.05",
232
+ 110: "1.1",
233
+ 125: "1.25",
234
+ 150: "1.5",
235
+ 200: "2"
236
+ },
237
+ caretColor: ({ theme: e }) => e("colors"),
238
+ colors: ({ colors: e }) => ({
239
+ inherit: e.inherit,
240
+ current: e.current,
241
+ transparent: e.transparent,
242
+ black: e.black,
243
+ white: e.white,
244
+ slate: e.slate,
245
+ gray: e.gray,
246
+ zinc: e.zinc,
247
+ neutral: e.neutral,
248
+ stone: e.stone,
249
+ red: e.red,
250
+ orange: e.orange,
251
+ amber: e.amber,
252
+ yellow: e.yellow,
253
+ lime: e.lime,
254
+ green: e.green,
255
+ emerald: e.emerald,
256
+ teal: e.teal,
257
+ cyan: e.cyan,
258
+ sky: e.sky,
259
+ blue: e.blue,
260
+ indigo: e.indigo,
261
+ violet: e.violet,
262
+ purple: e.purple,
263
+ fuchsia: e.fuchsia,
264
+ pink: e.pink,
265
+ rose: e.rose
266
+ }),
267
+ columns: {
268
+ auto: "auto",
269
+ 1: "1",
270
+ 2: "2",
271
+ 3: "3",
272
+ 4: "4",
273
+ 5: "5",
274
+ 6: "6",
275
+ 7: "7",
276
+ 8: "8",
277
+ 9: "9",
278
+ 10: "10",
279
+ 11: "11",
280
+ 12: "12",
281
+ "3xs": "16rem",
282
+ "2xs": "18rem",
283
+ xs: "20rem",
284
+ sm: "24rem",
285
+ md: "28rem",
286
+ lg: "32rem",
287
+ xl: "36rem",
288
+ "2xl": "42rem",
289
+ "3xl": "48rem",
290
+ "4xl": "56rem",
291
+ "5xl": "64rem",
292
+ "6xl": "72rem",
293
+ "7xl": "80rem"
294
+ },
295
+ container: {},
296
+ content: {
297
+ none: "none"
298
+ },
299
+ contrast: {
300
+ 0: "0",
301
+ 50: ".5",
302
+ 75: ".75",
303
+ 100: "1",
304
+ 125: "1.25",
305
+ 150: "1.5",
306
+ 200: "2"
307
+ },
308
+ cursor: {
309
+ auto: "auto",
310
+ default: "default",
311
+ pointer: "pointer",
312
+ wait: "wait",
313
+ text: "text",
314
+ move: "move",
315
+ help: "help",
316
+ "not-allowed": "not-allowed",
317
+ none: "none",
318
+ "context-menu": "context-menu",
319
+ progress: "progress",
320
+ cell: "cell",
321
+ crosshair: "crosshair",
322
+ "vertical-text": "vertical-text",
323
+ alias: "alias",
324
+ copy: "copy",
325
+ "no-drop": "no-drop",
326
+ grab: "grab",
327
+ grabbing: "grabbing",
328
+ "all-scroll": "all-scroll",
329
+ "col-resize": "col-resize",
330
+ "row-resize": "row-resize",
331
+ "n-resize": "n-resize",
332
+ "e-resize": "e-resize",
333
+ "s-resize": "s-resize",
334
+ "w-resize": "w-resize",
335
+ "ne-resize": "ne-resize",
336
+ "nw-resize": "nw-resize",
337
+ "se-resize": "se-resize",
338
+ "sw-resize": "sw-resize",
339
+ "ew-resize": "ew-resize",
340
+ "ns-resize": "ns-resize",
341
+ "nesw-resize": "nesw-resize",
342
+ "nwse-resize": "nwse-resize",
343
+ "zoom-in": "zoom-in",
344
+ "zoom-out": "zoom-out"
345
+ },
346
+ divideColor: ({ theme: e }) => e("borderColor"),
347
+ divideOpacity: ({ theme: e }) => e("borderOpacity"),
348
+ divideWidth: ({ theme: e }) => e("borderWidth"),
349
+ dropShadow: {
350
+ sm: "0 1px 1px rgb(0 0 0 / 0.05)",
351
+ DEFAULT: ["0 1px 2px rgb(0 0 0 / 0.1)", "0 1px 1px rgb(0 0 0 / 0.06)"],
352
+ md: ["0 4px 3px rgb(0 0 0 / 0.07)", "0 2px 2px rgb(0 0 0 / 0.06)"],
353
+ lg: ["0 10px 8px rgb(0 0 0 / 0.04)", "0 4px 3px rgb(0 0 0 / 0.1)"],
354
+ xl: ["0 20px 13px rgb(0 0 0 / 0.03)", "0 8px 5px rgb(0 0 0 / 0.08)"],
355
+ "2xl": "0 25px 25px rgb(0 0 0 / 0.15)",
356
+ none: "0 0 #0000"
357
+ },
358
+ fill: ({ theme: e }) => ({
359
+ none: "none",
360
+ ...e("colors")
361
+ }),
362
+ flex: {
363
+ 1: "1 1 0%",
364
+ auto: "1 1 auto",
365
+ initial: "0 1 auto",
366
+ none: "none"
367
+ },
368
+ flexBasis: ({ theme: e }) => ({
369
+ auto: "auto",
370
+ ...e("spacing"),
371
+ "1/2": "50%",
372
+ "1/3": "33.333333%",
373
+ "2/3": "66.666667%",
374
+ "1/4": "25%",
375
+ "2/4": "50%",
376
+ "3/4": "75%",
377
+ "1/5": "20%",
378
+ "2/5": "40%",
379
+ "3/5": "60%",
380
+ "4/5": "80%",
381
+ "1/6": "16.666667%",
382
+ "2/6": "33.333333%",
383
+ "3/6": "50%",
384
+ "4/6": "66.666667%",
385
+ "5/6": "83.333333%",
386
+ "1/12": "8.333333%",
387
+ "2/12": "16.666667%",
388
+ "3/12": "25%",
389
+ "4/12": "33.333333%",
390
+ "5/12": "41.666667%",
391
+ "6/12": "50%",
392
+ "7/12": "58.333333%",
393
+ "8/12": "66.666667%",
394
+ "9/12": "75%",
395
+ "10/12": "83.333333%",
396
+ "11/12": "91.666667%",
397
+ full: "100%"
398
+ }),
399
+ flexGrow: {
400
+ 0: "0",
401
+ DEFAULT: "1"
402
+ },
403
+ flexShrink: {
404
+ 0: "0",
405
+ DEFAULT: "1"
406
+ },
407
+ fontFamily: {
408
+ sans: [
409
+ "ui-sans-serif",
410
+ "system-ui",
411
+ "-apple-system",
412
+ "BlinkMacSystemFont",
413
+ '"Segoe UI"',
414
+ "Roboto",
415
+ '"Helvetica Neue"',
416
+ "Arial",
417
+ '"Noto Sans"',
418
+ "sans-serif",
419
+ '"Apple Color Emoji"',
420
+ '"Segoe UI Emoji"',
421
+ '"Segoe UI Symbol"',
422
+ '"Noto Color Emoji"'
423
+ ],
424
+ serif: ["ui-serif", "Georgia", "Cambria", '"Times New Roman"', "Times", "serif"],
425
+ mono: [
426
+ "ui-monospace",
427
+ "SFMono-Regular",
428
+ "Menlo",
429
+ "Monaco",
430
+ "Consolas",
431
+ '"Liberation Mono"',
432
+ '"Courier New"',
433
+ "monospace"
434
+ ]
435
+ },
436
+ fontSize: {
437
+ xs: ["0.75rem", { lineHeight: "1rem" }],
438
+ sm: ["0.875rem", { lineHeight: "1.25rem" }],
439
+ base: ["1rem", { lineHeight: "1.5rem" }],
440
+ lg: ["1.125rem", { lineHeight: "1.75rem" }],
441
+ xl: ["1.25rem", { lineHeight: "1.75rem" }],
442
+ "2xl": ["1.5rem", { lineHeight: "2rem" }],
443
+ "3xl": ["1.875rem", { lineHeight: "2.25rem" }],
444
+ "4xl": ["2.25rem", { lineHeight: "2.5rem" }],
445
+ "5xl": ["3rem", { lineHeight: "1" }],
446
+ "6xl": ["3.75rem", { lineHeight: "1" }],
447
+ "7xl": ["4.5rem", { lineHeight: "1" }],
448
+ "8xl": ["6rem", { lineHeight: "1" }],
449
+ "9xl": ["8rem", { lineHeight: "1" }]
450
+ },
451
+ fontWeight: {
452
+ thin: "100",
453
+ extralight: "200",
454
+ light: "300",
455
+ normal: "400",
456
+ medium: "500",
457
+ semibold: "600",
458
+ bold: "700",
459
+ extrabold: "800",
460
+ black: "900"
461
+ },
462
+ gap: ({ theme: e }) => e("spacing"),
463
+ gradientColorStops: ({ theme: e }) => e("colors"),
464
+ gradientColorStopPositions: {
465
+ "0%": "0%",
466
+ "5%": "5%",
467
+ "10%": "10%",
468
+ "15%": "15%",
469
+ "20%": "20%",
470
+ "25%": "25%",
471
+ "30%": "30%",
472
+ "35%": "35%",
473
+ "40%": "40%",
474
+ "45%": "45%",
475
+ "50%": "50%",
476
+ "55%": "55%",
477
+ "60%": "60%",
478
+ "65%": "65%",
479
+ "70%": "70%",
480
+ "75%": "75%",
481
+ "80%": "80%",
482
+ "85%": "85%",
483
+ "90%": "90%",
484
+ "95%": "95%",
485
+ "100%": "100%"
486
+ },
487
+ grayscale: {
488
+ 0: "0",
489
+ DEFAULT: "100%"
490
+ },
491
+ gridAutoColumns: {
492
+ auto: "auto",
493
+ min: "min-content",
494
+ max: "max-content",
495
+ fr: "minmax(0, 1fr)"
496
+ },
497
+ gridAutoRows: {
498
+ auto: "auto",
499
+ min: "min-content",
500
+ max: "max-content",
501
+ fr: "minmax(0, 1fr)"
502
+ },
503
+ gridColumn: {
504
+ auto: "auto",
505
+ "span-1": "span 1 / span 1",
506
+ "span-2": "span 2 / span 2",
507
+ "span-3": "span 3 / span 3",
508
+ "span-4": "span 4 / span 4",
509
+ "span-5": "span 5 / span 5",
510
+ "span-6": "span 6 / span 6",
511
+ "span-7": "span 7 / span 7",
512
+ "span-8": "span 8 / span 8",
513
+ "span-9": "span 9 / span 9",
514
+ "span-10": "span 10 / span 10",
515
+ "span-11": "span 11 / span 11",
516
+ "span-12": "span 12 / span 12",
517
+ "span-full": "1 / -1"
518
+ },
519
+ gridColumnEnd: {
520
+ auto: "auto",
521
+ 1: "1",
522
+ 2: "2",
523
+ 3: "3",
524
+ 4: "4",
525
+ 5: "5",
526
+ 6: "6",
527
+ 7: "7",
528
+ 8: "8",
529
+ 9: "9",
530
+ 10: "10",
531
+ 11: "11",
532
+ 12: "12",
533
+ 13: "13"
534
+ },
535
+ gridColumnStart: {
536
+ auto: "auto",
537
+ 1: "1",
538
+ 2: "2",
539
+ 3: "3",
540
+ 4: "4",
541
+ 5: "5",
542
+ 6: "6",
543
+ 7: "7",
544
+ 8: "8",
545
+ 9: "9",
546
+ 10: "10",
547
+ 11: "11",
548
+ 12: "12",
549
+ 13: "13"
550
+ },
551
+ gridRow: {
552
+ auto: "auto",
553
+ "span-1": "span 1 / span 1",
554
+ "span-2": "span 2 / span 2",
555
+ "span-3": "span 3 / span 3",
556
+ "span-4": "span 4 / span 4",
557
+ "span-5": "span 5 / span 5",
558
+ "span-6": "span 6 / span 6",
559
+ "span-full": "1 / -1"
560
+ },
561
+ gridRowEnd: {
562
+ auto: "auto",
563
+ 1: "1",
564
+ 2: "2",
565
+ 3: "3",
566
+ 4: "4",
567
+ 5: "5",
568
+ 6: "6",
569
+ 7: "7"
570
+ },
571
+ gridRowStart: {
572
+ auto: "auto",
573
+ 1: "1",
574
+ 2: "2",
575
+ 3: "3",
576
+ 4: "4",
577
+ 5: "5",
578
+ 6: "6",
579
+ 7: "7"
580
+ },
581
+ gridTemplateColumns: {
582
+ none: "none",
583
+ 1: "repeat(1, minmax(0, 1fr))",
584
+ 2: "repeat(2, minmax(0, 1fr))",
585
+ 3: "repeat(3, minmax(0, 1fr))",
586
+ 4: "repeat(4, minmax(0, 1fr))",
587
+ 5: "repeat(5, minmax(0, 1fr))",
588
+ 6: "repeat(6, minmax(0, 1fr))",
589
+ 7: "repeat(7, minmax(0, 1fr))",
590
+ 8: "repeat(8, minmax(0, 1fr))",
591
+ 9: "repeat(9, minmax(0, 1fr))",
592
+ 10: "repeat(10, minmax(0, 1fr))",
593
+ 11: "repeat(11, minmax(0, 1fr))",
594
+ 12: "repeat(12, minmax(0, 1fr))"
595
+ },
596
+ gridTemplateRows: {
597
+ none: "none",
598
+ 1: "repeat(1, minmax(0, 1fr))",
599
+ 2: "repeat(2, minmax(0, 1fr))",
600
+ 3: "repeat(3, minmax(0, 1fr))",
601
+ 4: "repeat(4, minmax(0, 1fr))",
602
+ 5: "repeat(5, minmax(0, 1fr))",
603
+ 6: "repeat(6, minmax(0, 1fr))"
604
+ },
605
+ height: ({ theme: e }) => ({
606
+ auto: "auto",
607
+ ...e("spacing"),
608
+ "1/2": "50%",
609
+ "1/3": "33.333333%",
610
+ "2/3": "66.666667%",
611
+ "1/4": "25%",
612
+ "2/4": "50%",
613
+ "3/4": "75%",
614
+ "1/5": "20%",
615
+ "2/5": "40%",
616
+ "3/5": "60%",
617
+ "4/5": "80%",
618
+ "1/6": "16.666667%",
619
+ "2/6": "33.333333%",
620
+ "3/6": "50%",
621
+ "4/6": "66.666667%",
622
+ "5/6": "83.333333%",
623
+ full: "100%",
624
+ screen: "100vh",
625
+ min: "min-content",
626
+ max: "max-content",
627
+ fit: "fit-content"
628
+ }),
629
+ hueRotate: {
630
+ 0: "0deg",
631
+ 15: "15deg",
632
+ 30: "30deg",
633
+ 60: "60deg",
634
+ 90: "90deg",
635
+ 180: "180deg"
636
+ },
637
+ inset: ({ theme: e }) => ({
638
+ auto: "auto",
639
+ ...e("spacing"),
640
+ "1/2": "50%",
641
+ "1/3": "33.333333%",
642
+ "2/3": "66.666667%",
643
+ "1/4": "25%",
644
+ "2/4": "50%",
645
+ "3/4": "75%",
646
+ full: "100%"
647
+ }),
648
+ invert: {
649
+ 0: "0",
650
+ DEFAULT: "100%"
651
+ },
652
+ keyframes: {
653
+ spin: {
654
+ to: {
655
+ transform: "rotate(360deg)"
656
+ }
657
+ },
658
+ ping: {
659
+ "75%, 100%": {
660
+ transform: "scale(2)",
661
+ opacity: "0"
662
+ }
663
+ },
664
+ pulse: {
665
+ "50%": {
666
+ opacity: ".5"
667
+ }
668
+ },
669
+ bounce: {
670
+ "0%, 100%": {
671
+ transform: "translateY(-25%)",
672
+ animationTimingFunction: "cubic-bezier(0.8,0,1,1)"
673
+ },
674
+ "50%": {
675
+ transform: "none",
676
+ animationTimingFunction: "cubic-bezier(0,0,0.2,1)"
677
+ }
678
+ }
679
+ },
680
+ letterSpacing: {
681
+ tighter: "-0.05em",
682
+ tight: "-0.025em",
683
+ normal: "0em",
684
+ wide: "0.025em",
685
+ wider: "0.05em",
686
+ widest: "0.1em"
687
+ },
688
+ lineHeight: {
689
+ none: "1",
690
+ tight: "1.25",
691
+ snug: "1.375",
692
+ normal: "1.5",
693
+ relaxed: "1.625",
694
+ loose: "2",
695
+ 3: ".75rem",
696
+ 4: "1rem",
697
+ 5: "1.25rem",
698
+ 6: "1.5rem",
699
+ 7: "1.75rem",
700
+ 8: "2rem",
701
+ 9: "2.25rem",
702
+ 10: "2.5rem"
703
+ },
704
+ listStyleType: {
705
+ none: "none",
706
+ disc: "disc",
707
+ decimal: "decimal"
708
+ },
709
+ listStyleImage: {
710
+ none: "none"
711
+ },
712
+ margin: ({ theme: e }) => ({
713
+ auto: "auto",
714
+ ...e("spacing")
715
+ }),
716
+ lineClamp: {
717
+ 1: "1",
718
+ 2: "2",
719
+ 3: "3",
720
+ 4: "4",
721
+ 5: "5",
722
+ 6: "6"
723
+ },
724
+ maxHeight: ({ theme: e }) => ({
725
+ ...e("spacing"),
726
+ none: "none",
727
+ full: "100%",
728
+ screen: "100vh",
729
+ min: "min-content",
730
+ max: "max-content",
731
+ fit: "fit-content"
732
+ }),
733
+ maxWidth: ({ theme: e, breakpoints: t }) => ({
734
+ none: "none",
735
+ 0: "0rem",
736
+ xs: "20rem",
737
+ sm: "24rem",
738
+ md: "28rem",
739
+ lg: "32rem",
740
+ xl: "36rem",
741
+ "2xl": "42rem",
742
+ "3xl": "48rem",
743
+ "4xl": "56rem",
744
+ "5xl": "64rem",
745
+ "6xl": "72rem",
746
+ "7xl": "80rem",
747
+ full: "100%",
748
+ min: "min-content",
749
+ max: "max-content",
750
+ fit: "fit-content",
751
+ prose: "65ch",
752
+ ...t(e("screens"))
753
+ }),
754
+ minHeight: {
755
+ 0: "0px",
756
+ full: "100%",
757
+ screen: "100vh",
758
+ min: "min-content",
759
+ max: "max-content",
760
+ fit: "fit-content"
761
+ },
762
+ minWidth: {
763
+ 0: "0px",
764
+ full: "100%",
765
+ min: "min-content",
766
+ max: "max-content",
767
+ fit: "fit-content"
768
+ },
769
+ objectPosition: {
770
+ bottom: "bottom",
771
+ center: "center",
772
+ left: "left",
773
+ "left-bottom": "left bottom",
774
+ "left-top": "left top",
775
+ right: "right",
776
+ "right-bottom": "right bottom",
777
+ "right-top": "right top",
778
+ top: "top"
779
+ },
780
+ opacity: {
781
+ 0: "0",
782
+ 5: "0.05",
783
+ 10: "0.1",
784
+ 20: "0.2",
785
+ 25: "0.25",
786
+ 30: "0.3",
787
+ 40: "0.4",
788
+ 50: "0.5",
789
+ 60: "0.6",
790
+ 70: "0.7",
791
+ 75: "0.75",
792
+ 80: "0.8",
793
+ 90: "0.9",
794
+ 95: "0.95",
795
+ 100: "1"
796
+ },
797
+ order: {
798
+ first: "-9999",
799
+ last: "9999",
800
+ none: "0",
801
+ 1: "1",
802
+ 2: "2",
803
+ 3: "3",
804
+ 4: "4",
805
+ 5: "5",
806
+ 6: "6",
807
+ 7: "7",
808
+ 8: "8",
809
+ 9: "9",
810
+ 10: "10",
811
+ 11: "11",
812
+ 12: "12"
813
+ },
814
+ outlineColor: ({ theme: e }) => e("colors"),
815
+ outlineOffset: {
816
+ 0: "0px",
817
+ 1: "1px",
818
+ 2: "2px",
819
+ 4: "4px",
820
+ 8: "8px"
821
+ },
822
+ outlineWidth: {
823
+ 0: "0px",
824
+ 1: "1px",
825
+ 2: "2px",
826
+ 4: "4px",
827
+ 8: "8px"
828
+ },
829
+ padding: ({ theme: e }) => e("spacing"),
830
+ placeholderColor: ({ theme: e }) => e("colors"),
831
+ placeholderOpacity: ({ theme: e }) => e("opacity"),
832
+ ringColor: ({ theme: e }) => ({
833
+ DEFAULT: e("colors.blue.500", "#3b82f6"),
834
+ ...e("colors")
835
+ }),
836
+ ringOffsetColor: ({ theme: e }) => e("colors"),
837
+ ringOffsetWidth: {
838
+ 0: "0px",
839
+ 1: "1px",
840
+ 2: "2px",
841
+ 4: "4px",
842
+ 8: "8px"
843
+ },
844
+ ringOpacity: ({ theme: e }) => ({
845
+ DEFAULT: "0.5",
846
+ ...e("opacity")
847
+ }),
848
+ ringWidth: {
849
+ DEFAULT: "3px",
850
+ 0: "0px",
851
+ 1: "1px",
852
+ 2: "2px",
853
+ 4: "4px",
854
+ 8: "8px"
855
+ },
856
+ rotate: {
857
+ 0: "0deg",
858
+ 1: "1deg",
859
+ 2: "2deg",
860
+ 3: "3deg",
861
+ 6: "6deg",
862
+ 12: "12deg",
863
+ 45: "45deg",
864
+ 90: "90deg",
865
+ 180: "180deg"
866
+ },
867
+ saturate: {
868
+ 0: "0",
869
+ 50: ".5",
870
+ 100: "1",
871
+ 150: "1.5",
872
+ 200: "2"
873
+ },
874
+ scale: {
875
+ 0: "0",
876
+ 50: ".5",
877
+ 75: ".75",
878
+ 90: ".9",
879
+ 95: ".95",
880
+ 100: "1",
881
+ 105: "1.05",
882
+ 110: "1.1",
883
+ 125: "1.25",
884
+ 150: "1.5"
885
+ },
886
+ screens: {
887
+ sm: "640px",
888
+ md: "768px",
889
+ lg: "1024px",
890
+ xl: "1280px",
891
+ "2xl": "1536px"
892
+ },
893
+ scrollMargin: ({ theme: e }) => ({
894
+ ...e("spacing")
895
+ }),
896
+ scrollPadding: ({ theme: e }) => e("spacing"),
897
+ sepia: {
898
+ 0: "0",
899
+ DEFAULT: "100%"
900
+ },
901
+ skew: {
902
+ 0: "0deg",
903
+ 1: "1deg",
904
+ 2: "2deg",
905
+ 3: "3deg",
906
+ 6: "6deg",
907
+ 12: "12deg"
908
+ },
909
+ space: ({ theme: e }) => ({
910
+ ...e("spacing")
911
+ }),
912
+ spacing: {
913
+ px: "1px",
914
+ 0: "0px",
915
+ 0.5: "0.125rem",
916
+ 1: "0.25rem",
917
+ 1.5: "0.375rem",
918
+ 2: "0.5rem",
919
+ 2.5: "0.625rem",
920
+ 3: "0.75rem",
921
+ 3.5: "0.875rem",
922
+ 4: "1rem",
923
+ 5: "1.25rem",
924
+ 6: "1.5rem",
925
+ 7: "1.75rem",
926
+ 8: "2rem",
927
+ 9: "2.25rem",
928
+ 10: "2.5rem",
929
+ 11: "2.75rem",
930
+ 12: "3rem",
931
+ 14: "3.5rem",
932
+ 16: "4rem",
933
+ 20: "5rem",
934
+ 24: "6rem",
935
+ 28: "7rem",
936
+ 32: "8rem",
937
+ 36: "9rem",
938
+ 40: "10rem",
939
+ 44: "11rem",
940
+ 48: "12rem",
941
+ 52: "13rem",
942
+ 56: "14rem",
943
+ 60: "15rem",
944
+ 64: "16rem",
945
+ 72: "18rem",
946
+ 80: "20rem",
947
+ 96: "24rem"
948
+ },
949
+ stroke: ({ theme: e }) => ({
950
+ none: "none",
951
+ ...e("colors")
952
+ }),
953
+ strokeWidth: {
954
+ 0: "0",
955
+ 1: "1",
956
+ 2: "2"
957
+ },
958
+ supports: {},
959
+ data: {},
960
+ textColor: ({ theme: e }) => e("colors"),
961
+ textDecorationColor: ({ theme: e }) => e("colors"),
962
+ textDecorationThickness: {
963
+ auto: "auto",
964
+ "from-font": "from-font",
965
+ 0: "0px",
966
+ 1: "1px",
967
+ 2: "2px",
968
+ 4: "4px",
969
+ 8: "8px"
970
+ },
971
+ textIndent: ({ theme: e }) => ({
972
+ ...e("spacing")
973
+ }),
974
+ textOpacity: ({ theme: e }) => e("opacity"),
975
+ textUnderlineOffset: {
976
+ auto: "auto",
977
+ 0: "0px",
978
+ 1: "1px",
979
+ 2: "2px",
980
+ 4: "4px",
981
+ 8: "8px"
982
+ },
983
+ transformOrigin: {
984
+ center: "center",
985
+ top: "top",
986
+ "top-right": "top right",
987
+ right: "right",
988
+ "bottom-right": "bottom right",
989
+ bottom: "bottom",
990
+ "bottom-left": "bottom left",
991
+ left: "left",
992
+ "top-left": "top left"
993
+ },
994
+ transitionDelay: {
995
+ 0: "0s",
996
+ 75: "75ms",
997
+ 100: "100ms",
998
+ 150: "150ms",
999
+ 200: "200ms",
1000
+ 300: "300ms",
1001
+ 500: "500ms",
1002
+ 700: "700ms",
1003
+ 1e3: "1000ms"
1004
+ },
1005
+ transitionDuration: {
1006
+ DEFAULT: "150ms",
1007
+ 0: "0s",
1008
+ 75: "75ms",
1009
+ 100: "100ms",
1010
+ 150: "150ms",
1011
+ 200: "200ms",
1012
+ 300: "300ms",
1013
+ 500: "500ms",
1014
+ 700: "700ms",
1015
+ 1e3: "1000ms"
1016
+ },
1017
+ transitionProperty: {
1018
+ none: "none",
1019
+ all: "all",
1020
+ DEFAULT: "color, background-color, border-color, text-decoration-color, fill, stroke, opacity, box-shadow, transform, filter, backdrop-filter",
1021
+ colors: "color, background-color, border-color, text-decoration-color, fill, stroke",
1022
+ opacity: "opacity",
1023
+ shadow: "box-shadow",
1024
+ transform: "transform"
1025
+ },
1026
+ transitionTimingFunction: {
1027
+ DEFAULT: "cubic-bezier(0.4, 0, 0.2, 1)",
1028
+ linear: "linear",
1029
+ in: "cubic-bezier(0.4, 0, 1, 1)",
1030
+ out: "cubic-bezier(0, 0, 0.2, 1)",
1031
+ "in-out": "cubic-bezier(0.4, 0, 0.2, 1)"
1032
+ },
1033
+ translate: ({ theme: e }) => ({
1034
+ ...e("spacing"),
1035
+ "1/2": "50%",
1036
+ "1/3": "33.333333%",
1037
+ "2/3": "66.666667%",
1038
+ "1/4": "25%",
1039
+ "2/4": "50%",
1040
+ "3/4": "75%",
1041
+ full: "100%"
1042
+ }),
1043
+ width: ({ theme: e }) => ({
1044
+ auto: "auto",
1045
+ ...e("spacing"),
1046
+ "1/2": "50%",
1047
+ "1/3": "33.333333%",
1048
+ "2/3": "66.666667%",
1049
+ "1/4": "25%",
1050
+ "2/4": "50%",
1051
+ "3/4": "75%",
1052
+ "1/5": "20%",
1053
+ "2/5": "40%",
1054
+ "3/5": "60%",
1055
+ "4/5": "80%",
1056
+ "1/6": "16.666667%",
1057
+ "2/6": "33.333333%",
1058
+ "3/6": "50%",
1059
+ "4/6": "66.666667%",
1060
+ "5/6": "83.333333%",
1061
+ "1/12": "8.333333%",
1062
+ "2/12": "16.666667%",
1063
+ "3/12": "25%",
1064
+ "4/12": "33.333333%",
1065
+ "5/12": "41.666667%",
1066
+ "6/12": "50%",
1067
+ "7/12": "58.333333%",
1068
+ "8/12": "66.666667%",
1069
+ "9/12": "75%",
1070
+ "10/12": "83.333333%",
1071
+ "11/12": "91.666667%",
1072
+ full: "100%",
1073
+ screen: "100vw",
1074
+ min: "min-content",
1075
+ max: "max-content",
1076
+ fit: "fit-content"
1077
+ }),
1078
+ willChange: {
1079
+ auto: "auto",
1080
+ scroll: "scroll-position",
1081
+ contents: "contents",
1082
+ transform: "transform"
1083
+ },
1084
+ zIndex: {
1085
+ auto: "auto",
1086
+ 0: "0",
1087
+ 10: "10",
1088
+ 20: "20",
1089
+ 30: "30",
1090
+ 40: "40",
1091
+ 50: "50"
1092
+ }
1093
+ },
1094
+ plugins: []
1095
+ };
1096
+ (function(e) {
1097
+ Object.defineProperty(e, "__esModule", {
1098
+ value: !0
1099
+ }), Object.defineProperty(e, "default", {
1100
+ enumerable: !0,
1101
+ get: function() {
1102
+ return a;
1103
+ }
1104
+ });
1105
+ const t = _, r = /* @__PURE__ */ n(q);
1106
+ function n(o) {
1107
+ return o && o.__esModule ? o : {
1108
+ default: o
1109
+ };
1110
+ }
1111
+ const a = (0, t.cloneDeep)(r.default.theme);
1112
+ })(T);
1113
+ let b = T;
1114
+ var G = (b.__esModule ? b : { default: b }).default;
1115
+ const h = /* @__PURE__ */ U(G), Y = (e, t = "c-") => {
1116
+ const r = i(e, "_bodyTextLightColor", "#64748b"), n = i(e, "_bodyTextDarkColor", "#94a3b8"), a = i(e, "_bodyBgLightColor", "#FFFFFF"), o = i(e, "_bodyBgDarkColor", "#0f172a");
1117
+ return `${t}font-body ${t}antialiased ${t}text-[${r}] ${t}bg-[${a}] dark:${t}text-[${n}] dark:${t}bg-[${o}]`;
1118
+ }, pe = (e, t, r, n = "c-") => {
1119
+ const a = Y(r, n);
1120
+ return J(
1121
+ r,
1122
+ [C(JSON.stringify(e), /#styles:/g, ""), C(JSON.stringify(t), /#styles:/g, "")],
1123
+ a.split(" ").concat(`${n}inline-block`, `${n}w-full`, `${n}h-full`)
1124
+ );
1125
+ };
1126
+ async function J(e, t, r = [], n = "c-") {
1127
+ const a = i(e, "_primaryColor", "#000"), o = i(e, "_secondaryColor", "#ccc"), d = i(e, "_headingFont", "Inter"), p = i(e, "_bodyFont", "Inter"), m = i(e, "_roundedCorners", "0"), c = j({
1128
+ colors: [a, o],
1129
+ names: ["primary", "secondary"]
1130
+ });
1131
+ return F(c, "primary.DEFAULT", a), F(c, "secondary.DEFAULT", o), `${await $({
1132
+ tailwindConfig: {
1133
+ prefix: n,
1134
+ darkMode: "class",
1135
+ safelist: r,
1136
+ theme: {
1137
+ fontFamily: {
1138
+ heading: [d, ...h.fontFamily.sans],
1139
+ body: [p, ...h.fontFamily.sans]
1140
+ },
1141
+ extend: {
1142
+ borderRadius: {
1143
+ global: `${m || "0"}px`
1144
+ },
1145
+ colors: c
1146
+ }
1147
+ },
1148
+ plugins: [O, R, B, H],
1149
+ corePlugins: { preflight: !1 }
1150
+ }
1151
+ }).generateStylesFromContent(
1152
+ ` @tailwind components;
1153
+ @tailwind utilities;`,
1154
+ t
1155
+ )} .${n}bg-clip-text{background-clip: text;-webkit-background-clip: text;} h1,h2,h3,h4,h5,h6{font-family: "${d}",${h.fontFamily.sans.join(
1156
+ ", "
1157
+ )};}`;
1158
+ }
1159
+ function ce(e = 6, t = "abcdefghijklmnopqrstuvwxyzABCD") {
1160
+ let r = "";
1161
+ for (let n = e; n > 0; --n)
1162
+ r += t[Math.floor(Math.random() * t.length)];
1163
+ return r;
1164
+ }
1165
+ export {
1166
+ y as RenderChaiBlocks,
1167
+ me as RenderChaiPage,
1168
+ ce as generateUUID,
1169
+ pe as getBlocksTailwindCSS,
1170
+ Y as getBrandingClasses
1171
+ };