@chaibuilder/sdk 1.1.8 → 1.1.9
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/{AddBlocks-EBCXennD.cjs → AddBlocks-Et_v-kdv.cjs} +1 -1
- package/dist/{AddBlocks-a2VUDT5t.js → AddBlocks-VR2XGlgQ.js} +1 -1
- package/dist/{BrandingOptions-uU1nNRzP.js → BrandingOptions-SXbo_LEP.js} +69 -54
- package/dist/BrandingOptions-bZn4TXCB.cjs +1 -0
- package/dist/{CanvasArea-qr3Iv0Xx.js → CanvasArea-h4l0r7Ql.js} +420 -412
- package/dist/{CanvasArea-0dMH8DLY.cjs → CanvasArea-xBMxzh_r.cjs} +7 -7
- package/dist/{CurrentPage-XW_-vuBP.js → CurrentPage-2YpnE3z7.js} +2 -2
- package/dist/{CurrentPage-xRSxWOUz.cjs → CurrentPage-YGM6tLCg.cjs} +1 -1
- package/dist/{Layers-fvXADkdU.cjs → Layers-HZApEk-h.cjs} +1 -1
- package/dist/{Layers-urjdDTKB.js → Layers-Twu9zS3g.js} +4 -4
- package/dist/{MarkAsGlobalBlock-vWOYzFKX.js → MarkAsGlobalBlock-QTujTxNj.js} +1 -1
- package/dist/{MarkAsGlobalBlock-E_w2sPGA.cjs → MarkAsGlobalBlock-u8N_7PBX.cjs} +1 -1
- package/dist/{PagesPanel-SkDUfIP1.cjs → PagesPanel-W68J0fFD.cjs} +1 -1
- package/dist/{PagesPanel-ID_Vm6CO.js → PagesPanel-iRgy80Z4.js} +3 -3
- package/dist/{ProjectPanel-tbw24HmR.cjs → ProjectPanel-agiWUiVb.cjs} +1 -1
- package/dist/{ProjectPanel-_XAgk4uz.js → ProjectPanel-bl_zr1Zy.js} +3 -3
- package/dist/{Settings-b5UJ1CbF.js → Settings-qw8xQXnk.js} +2 -2
- package/dist/{Settings-CchIkXh7.cjs → Settings-veyss6AT.cjs} +1 -1
- package/dist/{SidePanels-BH-IFPaj.js → SidePanels-8tNhVPvi.js} +55 -56
- package/dist/{SidePanels-cPyWHJGN.cjs → SidePanels-BrItHT9y.cjs} +1 -1
- package/dist/{Topbar-b9Vt5SLF.cjs → Topbar-21E00R1y.cjs} +1 -1
- package/dist/{Topbar-oZ167R8x.js → Topbar-pbqGE6Xy.js} +1 -1
- package/dist/{UnsplashImages-dMdYJI8B.cjs → UnsplashImages-J2kiowyR.cjs} +1 -1
- package/dist/{UnsplashImages-yN_5vrmM.js → UnsplashImages-qm48rQ85.js} +1 -1
- package/dist/{UploadImages-yVZs49iB.js → UploadImages-0hJF9pBC.js} +1 -1
- package/dist/{UploadImages-2h2MuCU2.cjs → UploadImages-Hvetk6zO.cjs} +1 -1
- package/dist/{add-page-modal-ZvUYpd4h.js → add-page-modal-R2AAoK3R.js} +3 -3
- package/dist/{add-page-modal-FSnagas1.cjs → add-page-modal-U7Vh5_3P.cjs} +1 -1
- package/dist/{confirm-alert-4bi7bxtP.cjs → confirm-alert-5io1ceQF.cjs} +1 -1
- package/dist/{confirm-alert-iNzeta1I.js → confirm-alert-wEcYtKUU.js} +1 -1
- package/dist/core.cjs +1 -1
- package/dist/core.js +2 -2
- package/dist/{delete-page-modal-4MVbQbIE.js → delete-page-modal-69BK9Amt.js} +2 -2
- package/dist/{delete-page-modal-DAFOspX2.cjs → delete-page-modal-6ogwTW2k.cjs} +1 -1
- package/dist/{form-dmyeQkyn.js → form-_0bVd6F-.js} +1 -1
- package/dist/{form-wY4tsyip.cjs → form-uP2ot_6S.cjs} +1 -1
- package/dist/{index-LOLasIJD.js → index-ebo_5bTI.js} +3 -3
- package/dist/{index-rhyb2TB9.cjs → index-qLYDvpSi.cjs} +2 -2
- package/dist/index-uu0QwUDN.cjs +1 -0
- package/dist/{index-bKgIzodL.js → index-wmzVWtmw.js} +146 -158
- package/dist/{page-viewer-r_ZdpaXh.js → page-viewer-L4MKYffF.js} +3 -3
- package/dist/{page-viewer-V6dlnIHN.cjs → page-viewer-t7cGqLNI.cjs} +1 -1
- package/dist/{project-general-setting-6kSqNVU3.js → project-general-setting-ixBlo6KH.js} +3 -3
- package/dist/{project-general-setting-Dh5ki1wJ.cjs → project-general-setting-sfh80XRT.cjs} +1 -1
- package/dist/{project-seo-setting-dRUW-Zmp.js → project-seo-setting-iJW4zDZz.js} +2 -2
- package/dist/{project-seo-setting-57XXrUTn.cjs → project-seo-setting-pOIFrso5.cjs} +1 -1
- package/dist/{single-page-detail-E3QAv3RO.cjs → single-page-detail-4KlhF5AH.cjs} +1 -1
- package/dist/{single-page-detail-LTirOwox.js → single-page-detail-OwDaEcUN.js} +4 -4
- package/dist/studio.cjs +1 -1
- package/dist/studio.js +2 -2
- package/dist/ui.cjs +1 -1
- package/dist/ui.js +1 -1
- package/dist/{useAddBlockByDrop-qOKe8QVt.cjs → useAddBlockByDrop-3RSPGnwT.cjs} +1 -1
- package/dist/{useAddBlockByDrop-LM3owe-j.js → useAddBlockByDrop-Vcz4iQCH.js} +1 -1
- package/package.json +1 -1
- package/dist/BrandingOptions-kjj0QNch.cjs +0 -1
- package/dist/index-U_pW4Tkc.cjs +0 -1
|
@@ -8,7 +8,7 @@ import * as He from "@radix-ui/react-switch";
|
|
|
8
8
|
import { Slot as Ws } from "@radix-ui/react-slot";
|
|
9
9
|
import * as pe from "@radix-ui/react-accordion";
|
|
10
10
|
import { ChevronDownIcon as Us, Cross2Icon as tt, ChevronRightIcon as st, CheckIcon as Ee, DotFilledIcon as ot, CaretSortIcon as Hs, MagnifyingGlassIcon as qs } from "@radix-ui/react-icons";
|
|
11
|
-
import * as
|
|
11
|
+
import * as F from "@radix-ui/react-alert-dialog";
|
|
12
12
|
import * as B from "@radix-ui/react-dialog";
|
|
13
13
|
import * as Vt from "@radix-ui/react-label";
|
|
14
14
|
import * as me from "@radix-ui/react-scroll-area";
|
|
@@ -20,12 +20,12 @@ import * as Le from "@radix-ui/react-hover-card";
|
|
|
20
20
|
import * as O from "@radix-ui/react-select";
|
|
21
21
|
import * as P from "@radix-ui/react-dropdown-menu";
|
|
22
22
|
import * as $t from "@radix-ui/react-separator";
|
|
23
|
-
import * as
|
|
24
|
-
import { Command as
|
|
23
|
+
import * as q from "@radix-ui/react-toast";
|
|
24
|
+
import { Command as U } from "cmdk";
|
|
25
25
|
import * as T from "@radix-ui/react-context-menu";
|
|
26
26
|
import Ks, { IconPickerItem as Js } from "react-icons-picker";
|
|
27
27
|
import Ys from "react-dom";
|
|
28
|
-
import { flatten as Y, filter as I, omit as at, isEmpty as oe, isString as Qs, find as
|
|
28
|
+
import { flatten as Y, filter as I, omit as at, isEmpty as oe, isString as Qs, find as se, map as V, each as ce, get as E, set as fe, has as nt, includes as $, isUndefined as zr, without as Ft, forIn as Gt, findIndex as Be, last as Xs, first as ee, startsWith as Wt, isNull as qe, pick as wt, sortBy as Nt, isObject as Zs } from "lodash";
|
|
29
29
|
import eo from "react-quill";
|
|
30
30
|
import { atom as y, useAtom as R, useAtomValue as L, useSetAtom as de } from "jotai";
|
|
31
31
|
import Ut from "flat-to-nested";
|
|
@@ -103,7 +103,7 @@ const $e = (e) => "init" in e, Fe = (e) => !!e.write, Me = /* @__PURE__ */ new W
|
|
|
103
103
|
x,
|
|
104
104
|
h
|
|
105
105
|
);
|
|
106
|
-
St(x, _), N(_), (j == null ? void 0 : j.d) !== X.d &&
|
|
106
|
+
St(x, _), N(_), (j == null ? void 0 : j.d) !== X.d && H(d, X, j == null ? void 0 : j.d);
|
|
107
107
|
}
|
|
108
108
|
},
|
|
109
109
|
(_) => {
|
|
@@ -114,7 +114,7 @@ const $e = (e) => "init" in e, Fe = (e) => !!e.write, Me = /* @__PURE__ */ new W
|
|
|
114
114
|
x,
|
|
115
115
|
h
|
|
116
116
|
);
|
|
117
|
-
jt(x, _), M(_), (j == null ? void 0 : j.d) !== X.d &&
|
|
117
|
+
jt(x, _), M(_), (j == null ? void 0 : j.d) !== X.d && H(d, X, j == null ? void 0 : j.d);
|
|
118
118
|
}
|
|
119
119
|
}
|
|
120
120
|
), v = (_) => {
|
|
@@ -167,7 +167,7 @@ const $e = (e) => "init" in e, Fe = (e) => !!e.write, Me = /* @__PURE__ */ new W
|
|
|
167
167
|
get setSelf() {
|
|
168
168
|
return (z ? "production" : void 0) !== "production" && !Fe(d) && console.warn("setSelf function cannot be used with read-only atom"), !N && Fe(d) && (N = (...S) => {
|
|
169
169
|
if ((z ? "production" : void 0) !== "production" && g && console.warn("setSelf function cannot be called in sync"), !g)
|
|
170
|
-
return
|
|
170
|
+
return te(d, ...S);
|
|
171
171
|
}), N;
|
|
172
172
|
}
|
|
173
173
|
};
|
|
@@ -184,12 +184,12 @@ const $e = (e) => "init" in e, Fe = (e) => !!e.write, Me = /* @__PURE__ */ new W
|
|
|
184
184
|
} finally {
|
|
185
185
|
g = !1;
|
|
186
186
|
}
|
|
187
|
-
}, D = (d) => Re(k(d)),
|
|
187
|
+
}, D = (d) => Re(k(d)), W = (d) => {
|
|
188
188
|
let f = t.get(d);
|
|
189
189
|
return f || (f = J(d)), f;
|
|
190
|
-
},
|
|
190
|
+
}, G = (d, f) => !f.l.size && (!f.t.size || f.t.size === 1 && f.t.has(d)), ae = (d) => {
|
|
191
191
|
const f = t.get(d);
|
|
192
|
-
f &&
|
|
192
|
+
f && G(d, f) && ue(d);
|
|
193
193
|
}, he = (d) => {
|
|
194
194
|
const f = /* @__PURE__ */ new Map(), h = /* @__PURE__ */ new WeakMap(), g = (x) => {
|
|
195
195
|
const N = t.get(x);
|
|
@@ -240,7 +240,7 @@ const $e = (e) => "init" in e, Fe = (e) => !!e.write, Me = /* @__PURE__ */ new W
|
|
|
240
240
|
return S;
|
|
241
241
|
}, x = d.write(g, v, ...f);
|
|
242
242
|
return h = !1, x;
|
|
243
|
-
},
|
|
243
|
+
}, te = (d, ...f) => {
|
|
244
244
|
const h = ne(d, ...f), g = re();
|
|
245
245
|
return (z ? "production" : void 0) !== "production" && n.forEach(
|
|
246
246
|
(v) => v({ type: "write", flushed: g })
|
|
@@ -254,7 +254,7 @@ const $e = (e) => "init" in e, Fe = (e) => !!e.write, Me = /* @__PURE__ */ new W
|
|
|
254
254
|
const x = t.get(v);
|
|
255
255
|
x ? x.t.add(d) : v !== d && J(v, d);
|
|
256
256
|
}), k(d), Fe(d) && d.onMount) {
|
|
257
|
-
const g = d.onMount((...v) =>
|
|
257
|
+
const g = d.onMount((...v) => te(d, ...v));
|
|
258
258
|
g && (h.u = g);
|
|
259
259
|
}
|
|
260
260
|
return h;
|
|
@@ -266,10 +266,10 @@ const $e = (e) => "init" in e, Fe = (e) => !!e.write, Me = /* @__PURE__ */ new W
|
|
|
266
266
|
g ? (ye(g) && kt(g.v), g.d.forEach((v, x) => {
|
|
267
267
|
if (x !== d) {
|
|
268
268
|
const N = t.get(x);
|
|
269
|
-
N && (N.t.delete(d),
|
|
269
|
+
N && (N.t.delete(d), G(x, N) && ue(x));
|
|
270
270
|
}
|
|
271
271
|
})) : (z ? "production" : void 0) !== "production" && console.warn("[Bug] could not find atom state to unmount", d);
|
|
272
|
-
},
|
|
272
|
+
}, H = (d, f, h) => {
|
|
273
273
|
const g = new Set(f.d.keys());
|
|
274
274
|
h == null || h.forEach((v, x) => {
|
|
275
275
|
if (g.has(x)) {
|
|
@@ -277,7 +277,7 @@ const $e = (e) => "init" in e, Fe = (e) => !!e.write, Me = /* @__PURE__ */ new W
|
|
|
277
277
|
return;
|
|
278
278
|
}
|
|
279
279
|
const N = t.get(x);
|
|
280
|
-
N && (N.t.delete(d),
|
|
280
|
+
N && (N.t.delete(d), G(x, N) && ue(x));
|
|
281
281
|
}), g.forEach((v) => {
|
|
282
282
|
const x = t.get(v);
|
|
283
283
|
x ? x.t.add(d) : t.has(d) && J(v, d);
|
|
@@ -289,7 +289,7 @@ const $e = (e) => "init" in e, Fe = (e) => !!e.write, Me = /* @__PURE__ */ new W
|
|
|
289
289
|
s.clear(), f.forEach(([h, g]) => {
|
|
290
290
|
const v = i(h);
|
|
291
291
|
if (v) {
|
|
292
|
-
v.d !== (g == null ? void 0 : g.d) &&
|
|
292
|
+
v.d !== (g == null ? void 0 : g.d) && H(h, v, g == null ? void 0 : g.d);
|
|
293
293
|
const x = t.get(h);
|
|
294
294
|
x && !// TODO This seems pretty hacky. Hope to fix it.
|
|
295
295
|
// Maybe we could `mountDependencies` in `setAtomState`?
|
|
@@ -301,7 +301,7 @@ const $e = (e) => "init" in e, Fe = (e) => !!e.write, Me = /* @__PURE__ */ new W
|
|
|
301
301
|
if ((z ? "production" : void 0) !== "production")
|
|
302
302
|
return o.forEach((f) => f("state")), d;
|
|
303
303
|
}, ie = (d, f) => {
|
|
304
|
-
const h =
|
|
304
|
+
const h = W(d), g = re(), v = h.l;
|
|
305
305
|
return v.add(f), (z ? "production" : void 0) !== "production" && (o.forEach((x) => x("sub")), n.forEach(
|
|
306
306
|
(x) => x({ type: "sub", flushed: g })
|
|
307
307
|
)), () => {
|
|
@@ -310,7 +310,7 @@ const $e = (e) => "init" in e, Fe = (e) => !!e.write, Me = /* @__PURE__ */ new W
|
|
|
310
310
|
};
|
|
311
311
|
return (z ? "production" : void 0) !== "production" ? {
|
|
312
312
|
get: D,
|
|
313
|
-
set:
|
|
313
|
+
set: te,
|
|
314
314
|
sub: ie,
|
|
315
315
|
// store dev methods (these are tentative and subject to change without notice)
|
|
316
316
|
dev_subscribe_store: (d, f) => f !== 2 ? (console.warn(
|
|
@@ -333,7 +333,7 @@ const $e = (e) => "init" in e, Fe = (e) => !!e.write, Me = /* @__PURE__ */ new W
|
|
|
333
333
|
}
|
|
334
334
|
} : {
|
|
335
335
|
get: D,
|
|
336
|
-
set:
|
|
336
|
+
set: te,
|
|
337
337
|
sub: ie
|
|
338
338
|
};
|
|
339
339
|
};
|
|
@@ -421,31 +421,31 @@ function ko(e, t) {
|
|
|
421
421
|
return p;
|
|
422
422
|
const l = u && s.get(u), b = [], w = [];
|
|
423
423
|
return i.forEach((k, D) => {
|
|
424
|
-
const
|
|
425
|
-
w[D] =
|
|
426
|
-
const
|
|
427
|
-
if (
|
|
428
|
-
b[D] =
|
|
424
|
+
const W = t ? t(k) : D;
|
|
425
|
+
w[D] = W;
|
|
426
|
+
const G = l && l.atomList[l.keyList.indexOf(W)];
|
|
427
|
+
if (G) {
|
|
428
|
+
b[D] = G;
|
|
429
429
|
return;
|
|
430
430
|
}
|
|
431
431
|
const ae = (ne) => {
|
|
432
|
-
const
|
|
433
|
-
if (
|
|
434
|
-
const re = i[o(i).keyList.indexOf(
|
|
432
|
+
const te = ne(n), J = ne(e), H = o(J, te == null ? void 0 : te.arr).keyList.indexOf(W);
|
|
433
|
+
if (H < 0 || H >= J.length) {
|
|
434
|
+
const re = i[o(i).keyList.indexOf(W)];
|
|
435
435
|
if (re)
|
|
436
436
|
return re;
|
|
437
437
|
throw new Error("splitAtom: index out of bounds for read");
|
|
438
438
|
}
|
|
439
|
-
return J[
|
|
440
|
-
}, he = (ne,
|
|
441
|
-
const ue = ne(n),
|
|
442
|
-
if (ie < 0 || ie >=
|
|
439
|
+
return J[H];
|
|
440
|
+
}, he = (ne, te, J) => {
|
|
441
|
+
const ue = ne(n), H = ne(e), ie = o(H, ue == null ? void 0 : ue.arr).keyList.indexOf(W);
|
|
442
|
+
if (ie < 0 || ie >= H.length)
|
|
443
443
|
throw new Error("splitAtom: index out of bounds for write");
|
|
444
|
-
const d = No(J) ? J(
|
|
445
|
-
|
|
446
|
-
...
|
|
444
|
+
const d = No(J) ? J(H[ie]) : J;
|
|
445
|
+
te(e, [
|
|
446
|
+
...H.slice(0, ie),
|
|
447
447
|
d,
|
|
448
|
-
...
|
|
448
|
+
...H.slice(ie + 1)
|
|
449
449
|
]);
|
|
450
450
|
};
|
|
451
451
|
b[D] = _t(e) ? Z(ae, he) : Z(ae);
|
|
@@ -642,7 +642,7 @@ const Qt = (e) => {
|
|
|
642
642
|
Qs(e[s]) && e[s].startsWith("slot") && (t[s] = e[s].replace("slot:", ""));
|
|
643
643
|
}), t;
|
|
644
644
|
}, Po = (e, t, s = null) => {
|
|
645
|
-
let o =
|
|
645
|
+
let o = se(e, { _id: t });
|
|
646
646
|
o = { ...o, oldId: o._id, _id: le() }, s && (o = { ...o, _parent: s });
|
|
647
647
|
const n = [o];
|
|
648
648
|
I(e, { _parent: t }).length > 0 && n.push(Y(Yt(e, t, o._id)));
|
|
@@ -650,7 +650,7 @@ const Qt = (e) => {
|
|
|
650
650
|
return V(r, (i) => {
|
|
651
651
|
const u = i, p = Qt(u);
|
|
652
652
|
return Object.keys(p).length > 0 && Object.keys(p).forEach((l) => {
|
|
653
|
-
const b =
|
|
653
|
+
const b = se(r, { oldId: p[l].replace("slot:", "") });
|
|
654
654
|
u[l] = `slot:${b._id}`;
|
|
655
655
|
}), at(u, ["global", "oldId"]);
|
|
656
656
|
});
|
|
@@ -714,11 +714,11 @@ const es = y((e) => {
|
|
|
714
714
|
return I(t, (s) => nt(s, "blockId"));
|
|
715
715
|
});
|
|
716
716
|
es.debugLabel = "globalBlocksAtom";
|
|
717
|
-
const
|
|
717
|
+
const K = () => {
|
|
718
718
|
const [, e] = R(Oe);
|
|
719
719
|
return e;
|
|
720
720
|
}, Qr = () => {
|
|
721
|
-
const e =
|
|
721
|
+
const e = K(), t = L(Xt), s = A(
|
|
722
722
|
(o) => {
|
|
723
723
|
const n = Jt(o);
|
|
724
724
|
e({ type: "set_page_blocks", payload: n });
|
|
@@ -727,39 +727,26 @@ const q = () => {
|
|
|
727
727
|
);
|
|
728
728
|
return [t, s];
|
|
729
729
|
}, Xr = () => {
|
|
730
|
-
const e =
|
|
730
|
+
const e = K();
|
|
731
731
|
return [A(
|
|
732
732
|
(s) => {
|
|
733
733
|
e({ type: "set_page_blocks", payload: s });
|
|
734
734
|
},
|
|
735
735
|
[e]
|
|
736
736
|
)];
|
|
737
|
-
},
|
|
738
|
-
|
|
739
|
-
"Slot",
|
|
740
|
-
"Form",
|
|
741
|
-
"DataProvider",
|
|
742
|
-
"Link",
|
|
743
|
-
"List",
|
|
744
|
-
"ListItem",
|
|
745
|
-
"Row",
|
|
746
|
-
"Column",
|
|
747
|
-
"Table",
|
|
748
|
-
"Row",
|
|
749
|
-
"TableCell"
|
|
750
|
-
].includes(e), Zr = (e) => !["Slot"].includes(e), ei = (e) => !["Slot"].includes(e);
|
|
751
|
-
function Eo(e, t) {
|
|
752
|
-
return e === "Slot" || t === "List" && e !== "ListItem" || t === "Row" && e !== "Column" ? !1 : Ye(t);
|
|
737
|
+
}, Eo = (e) => ["Box", "Slot", "Form", "Link", "Heading", "List", "ListItem", "Table", "TableCell"].includes(e), Zr = (e) => !["Slot"].includes(e), ei = (e) => !["Slot"].includes(e);
|
|
738
|
+
function Ye(e, t) {
|
|
739
|
+
return e === "Slot" || t === "List" && e !== "ListItem" || t === "Row" && e !== "Column" || t === "Heading" && !$(["Span", "Text"], e) || t === "Paragraph" && !$(["Span", "Text"], e) ? !1 : Eo(t);
|
|
753
740
|
}
|
|
754
741
|
const ti = (e, { dragSource: t, dropTarget: s }) => {
|
|
755
742
|
const o = E(t, "data._type", ""), n = E(s, "data._type", "");
|
|
756
|
-
return o === "Slot" || E(t, "id") && E(t, "id") === E(s, "id") ? !1 : oe(n) ? !0 :
|
|
743
|
+
return o === "Slot" || E(t, "id") && E(t, "id") === E(s, "id") ? !1 : oe(n) ? !0 : Ye(o, n);
|
|
757
744
|
}, ct = y([]);
|
|
758
745
|
ct.debugLabel = "selectedBlockIdsAtom";
|
|
759
746
|
const dt = y((e) => {
|
|
760
747
|
const t = e(Q), s = e(ct);
|
|
761
748
|
return V(
|
|
762
|
-
I(t, ({ _id: o }) =>
|
|
749
|
+
I(t, ({ _id: o }) => $(s, o)),
|
|
763
750
|
(o) => ({ ...o })
|
|
764
751
|
);
|
|
765
752
|
});
|
|
@@ -774,7 +761,7 @@ const ut = y((e) => {
|
|
|
774
761
|
ut.debugLabel = "selectedBlockAtom";
|
|
775
762
|
const Lo = (e) => E(e, "parent", null), Oo = y((e) => {
|
|
776
763
|
const t = e(dt), s = V(t, Lo);
|
|
777
|
-
return I(e(Q), (o) =>
|
|
764
|
+
return I(e(Q), (o) => $(s, o._id));
|
|
778
765
|
});
|
|
779
766
|
Oo.debugLabel = "selectedBlocksParentsAtom";
|
|
780
767
|
const ts = y(() => !1);
|
|
@@ -792,7 +779,7 @@ const si = () => ({
|
|
|
792
779
|
const Ce = () => {
|
|
793
780
|
const [e, t] = R(ct), s = A(
|
|
794
781
|
(o) => {
|
|
795
|
-
t((n) =>
|
|
782
|
+
t((n) => $(n, o) ? Ft(n, o) : [...n, o]);
|
|
796
783
|
},
|
|
797
784
|
[t]
|
|
798
785
|
);
|
|
@@ -805,7 +792,7 @@ const Ce = () => {
|
|
|
805
792
|
const { properties: t } = e, s = {};
|
|
806
793
|
return Object.keys(t).forEach((r) => {
|
|
807
794
|
const i = t[r];
|
|
808
|
-
if (
|
|
795
|
+
if ($(["slot", "styles"], i.type))
|
|
809
796
|
return;
|
|
810
797
|
const u = r;
|
|
811
798
|
s[u] = Bt(i);
|
|
@@ -816,7 +803,7 @@ const Ce = () => {
|
|
|
816
803
|
};
|
|
817
804
|
return Object.keys(o).forEach((r) => {
|
|
818
805
|
const i = o[r];
|
|
819
|
-
if (
|
|
806
|
+
if ($(["slot", "styles"], i.type))
|
|
820
807
|
return;
|
|
821
808
|
const u = r;
|
|
822
809
|
n.items[u] = Bt(i);
|
|
@@ -836,7 +823,7 @@ const Ce = () => {
|
|
|
836
823
|
};
|
|
837
824
|
return Object.keys(t).forEach((u) => {
|
|
838
825
|
const p = t[u];
|
|
839
|
-
if (
|
|
826
|
+
if ($(["slot", "styles"], p.type))
|
|
840
827
|
return;
|
|
841
828
|
const l = u;
|
|
842
829
|
o.properties[l] = Rt(p);
|
|
@@ -852,7 +839,7 @@ const Ce = () => {
|
|
|
852
839
|
};
|
|
853
840
|
return Object.keys(n).forEach((u) => {
|
|
854
841
|
const p = n[u];
|
|
855
|
-
if (
|
|
842
|
+
if ($(["slot", "styles"], p.type))
|
|
856
843
|
return;
|
|
857
844
|
const l = u;
|
|
858
845
|
i.items.properties[l] = Rt(p), fe(i.items, "title", E(p, "itemTitle", `${r} item`));
|
|
@@ -909,36 +896,37 @@ function Pt(e, t, s, o, n) {
|
|
|
909
896
|
return e.splice(u, 0, ...o), e;
|
|
910
897
|
}
|
|
911
898
|
const ai = () => {
|
|
912
|
-
const e =
|
|
899
|
+
const e = K(), t = $o(), [, s] = Ce(), o = A(
|
|
913
900
|
(r, i, u) => {
|
|
914
|
-
var
|
|
915
|
-
for (let
|
|
916
|
-
const { _id:
|
|
917
|
-
r[
|
|
918
|
-
const
|
|
919
|
-
for (let
|
|
920
|
-
|
|
901
|
+
var w;
|
|
902
|
+
for (let k = 0; k < r.length; k++) {
|
|
903
|
+
const { _id: D } = r[k];
|
|
904
|
+
r[k]._id = le();
|
|
905
|
+
const W = I(r, { _parent: D });
|
|
906
|
+
for (let G = 0; G < W.length; G++)
|
|
907
|
+
W[G]._parent = r[k]._id;
|
|
921
908
|
}
|
|
922
|
-
|
|
923
|
-
|
|
924
|
-
|
|
925
|
-
|
|
909
|
+
const p = ee(r);
|
|
910
|
+
let l;
|
|
911
|
+
i && (l = se(t, { _id: i }), r[0]._parent = i);
|
|
912
|
+
const b = l ? Ye(p._type, l._type) : !0;
|
|
913
|
+
return !b && l && (r[0]._parent = l._parent), e({
|
|
926
914
|
type: "set_blocks",
|
|
927
|
-
payload: Pt(t, i || null, u || null, r,
|
|
928
|
-
}), s([(
|
|
915
|
+
payload: Pt(t, i || null, u || null, r, b)
|
|
916
|
+
}), s([(w = ee(r)) == null ? void 0 : w._id]), ee(r);
|
|
929
917
|
},
|
|
930
918
|
[t, e, s]
|
|
931
919
|
);
|
|
932
920
|
return { addCoreBlock: A(
|
|
933
921
|
(r, i, u) => {
|
|
934
922
|
if (nt(r, "blocks")) {
|
|
935
|
-
const
|
|
936
|
-
return o(
|
|
923
|
+
const G = r.blocks;
|
|
924
|
+
return o(G, i, u);
|
|
937
925
|
}
|
|
938
926
|
const p = le(), l = as(r.props), b = [];
|
|
939
|
-
Gt(l, (
|
|
940
|
-
if (Wt(
|
|
941
|
-
const he =
|
|
927
|
+
Gt(l, (G, ae) => {
|
|
928
|
+
if (Wt(G, Ke)) {
|
|
929
|
+
const he = G.replace(Ke, "");
|
|
942
930
|
b.push({
|
|
943
931
|
_id: he,
|
|
944
932
|
_type: "Slot",
|
|
@@ -955,13 +943,13 @@ const ai = () => {
|
|
|
955
943
|
...l
|
|
956
944
|
};
|
|
957
945
|
let k;
|
|
958
|
-
i && (k =
|
|
959
|
-
const D = k ? Ye(k._type) : !0;
|
|
946
|
+
i && (k = se(t, { _id: i }), w._parent = i);
|
|
947
|
+
const D = k ? Ye(r.type, k._type) : !0;
|
|
960
948
|
!D && k && (w._parent = k._parent);
|
|
961
|
-
const
|
|
949
|
+
const W = [w, ...b];
|
|
962
950
|
return e({
|
|
963
951
|
type: "set_blocks",
|
|
964
|
-
payload: Pt(t, i || null, u || null,
|
|
952
|
+
payload: Pt(t, i || null, u || null, W, D)
|
|
965
953
|
}), s([w._id]), w;
|
|
966
954
|
},
|
|
967
955
|
[o, t, e, s]
|
|
@@ -983,7 +971,7 @@ function Fo(e, t) {
|
|
|
983
971
|
let o = "baseClasses", n = It.indexOf(s);
|
|
984
972
|
for (; n > 0; ) {
|
|
985
973
|
const r = It[n - 1];
|
|
986
|
-
if (
|
|
974
|
+
if (se(e, {
|
|
987
975
|
mq: r,
|
|
988
976
|
property: t.property
|
|
989
977
|
})) {
|
|
@@ -1003,16 +991,16 @@ function Go(e = "", t = "", s = []) {
|
|
|
1003
991
|
), n = I(V(t.split(" "), Pe), (l) => !qe(l));
|
|
1004
992
|
n = I(
|
|
1005
993
|
n,
|
|
1006
|
-
(l) =>
|
|
994
|
+
(l) => !$(Mt, l.property)
|
|
1007
995
|
);
|
|
1008
996
|
const r = [], i = [];
|
|
1009
997
|
ce(s, (l) => {
|
|
1010
|
-
const b = Pe(l), w =
|
|
998
|
+
const b = Pe(l), w = se(o, wt(b, ["dark", "mq", "mod", "property"]));
|
|
1011
999
|
if (w && (o = I(
|
|
1012
1000
|
o,
|
|
1013
1001
|
(k) => k.fullCls !== (w == null ? void 0 : w.fullCls)
|
|
1014
|
-
)), r.push(b), b.mq === "xs" && !b.dark && b.mod === "" && (n = I(n, (k) => k.property !== b.property)), Fo(o, b) === "baseClasses" &&
|
|
1015
|
-
const k =
|
|
1002
|
+
)), r.push(b), b.mq === "xs" && !b.dark && b.mod === "" && (n = I(n, (k) => k.property !== b.property)), Fo(o, b) === "baseClasses" && !$(Mt, b.property)) {
|
|
1003
|
+
const k = se(n, wt(b, ["property"]));
|
|
1016
1004
|
w && (n = I(
|
|
1017
1005
|
n,
|
|
1018
1006
|
(D) => D.fullCls !== (k == null ? void 0 : k.fullCls)
|
|
@@ -1044,7 +1032,7 @@ const ns = () => R(_e), Wo = (e) => {
|
|
|
1044
1032
|
// @ts-ignore
|
|
1045
1033
|
s.includes(e(u)._id)
|
|
1046
1034
|
)
|
|
1047
|
-
), i =
|
|
1035
|
+
), i = ee(e(_e));
|
|
1048
1036
|
ce(r, (u) => {
|
|
1049
1037
|
const p = e(u), l = E(p, i.prop, `${ge},`), { baseClasses: b, classes: w } = Wo(l);
|
|
1050
1038
|
n({
|
|
@@ -1056,7 +1044,7 @@ const ns = () => R(_e), Wo = (e) => {
|
|
|
1056
1044
|
});
|
|
1057
1045
|
});
|
|
1058
1046
|
}), ni = () => {
|
|
1059
|
-
const e =
|
|
1047
|
+
const e = K(), t = de(Uo);
|
|
1060
1048
|
return A(
|
|
1061
1049
|
(s, o, n) => {
|
|
1062
1050
|
t({ blockIds: s, newClasses: o, dispatch: e }), n && setTimeout(() => e({ type: "create_snapshot" }), 500);
|
|
@@ -1111,15 +1099,15 @@ function is(e) {
|
|
|
1111
1099
|
}
|
|
1112
1100
|
function ea(e) {
|
|
1113
1101
|
let t = [];
|
|
1114
|
-
const s = E(
|
|
1115
|
-
fe(
|
|
1102
|
+
const s = E(ee(e), "parent", null);
|
|
1103
|
+
fe(ee(e), "parent", null);
|
|
1116
1104
|
const o = [rs.convert(cs(e))];
|
|
1117
1105
|
ft(o, !0);
|
|
1118
1106
|
let n = pt(o, e[0]._id);
|
|
1119
1107
|
return n = fe(n, "0.parent", s), t = [...t, n, ...is(n)], t;
|
|
1120
1108
|
}
|
|
1121
1109
|
function ls(e) {
|
|
1122
|
-
const t =
|
|
1110
|
+
const t = se(Qe, { _id: e._id });
|
|
1123
1111
|
if (!t)
|
|
1124
1112
|
return [];
|
|
1125
1113
|
const s = [t], o = I(Qe, { _parent: e._id });
|
|
@@ -1132,7 +1120,7 @@ function ta(e) {
|
|
|
1132
1120
|
const t = Zo(cs(e));
|
|
1133
1121
|
ft(t);
|
|
1134
1122
|
const s = pt(t, null), o = is(s), n = {};
|
|
1135
|
-
return ce(o, (r) => fe(n,
|
|
1123
|
+
return ce(o, (r) => fe(n, ee(r).blockId, r)), [s, n];
|
|
1136
1124
|
}
|
|
1137
1125
|
const ds = () => {
|
|
1138
1126
|
const [e] = Yo(), { currentPage: t } = Xo(), s = L(Q);
|
|
@@ -1202,7 +1190,7 @@ const ri = () => {
|
|
|
1202
1190
|
// save only every 5 seconds
|
|
1203
1191
|
), syncState: e, setSyncState: t };
|
|
1204
1192
|
}, bt = () => {
|
|
1205
|
-
const e = L(Oe), [{ undoCount: t, redoCount: s }] = R(ze), o =
|
|
1193
|
+
const e = L(Oe), [{ undoCount: t, redoCount: s }] = R(ze), o = K(), [n] = Ko(), [, r] = Ce(), [, i] = ns(), [u, p] = R(gt), l = ve("onSyncStatusChange", () => {
|
|
1206
1194
|
}), b = A(() => {
|
|
1207
1195
|
o({ type: "create_snapshot" });
|
|
1208
1196
|
}, [o]);
|
|
@@ -1257,7 +1245,7 @@ const ri = () => {
|
|
|
1257
1245
|
const [e, t] = R(ya);
|
|
1258
1246
|
return [e, t];
|
|
1259
1247
|
}, va = () => {
|
|
1260
|
-
const e =
|
|
1248
|
+
const e = K(), t = L(Q), [, s] = Ce();
|
|
1261
1249
|
return A(
|
|
1262
1250
|
(o, n = null) => {
|
|
1263
1251
|
const r = [];
|
|
@@ -1271,13 +1259,13 @@ const ri = () => {
|
|
|
1271
1259
|
}, wa = y([]), mi = () => {
|
|
1272
1260
|
const [e, t] = R(wa), s = A(
|
|
1273
1261
|
(o) => {
|
|
1274
|
-
t((n) =>
|
|
1262
|
+
t((n) => $(n, o) ? Ft(n, o) : [...n, o]);
|
|
1275
1263
|
},
|
|
1276
1264
|
[t]
|
|
1277
1265
|
);
|
|
1278
1266
|
return [e, t, s];
|
|
1279
1267
|
}, Na = y(""), ka = () => R(Na), pi = () => {
|
|
1280
|
-
const e = L(Q), t =
|
|
1268
|
+
const e = L(Q), t = K(), s = ds(), [, , o] = Ho();
|
|
1281
1269
|
return A(
|
|
1282
1270
|
async (n, r) => {
|
|
1283
1271
|
const i = le(16), u = V(e, (p) => (p._id === n && (p._globalBlockId = i, p._name = r), p));
|
|
@@ -1286,10 +1274,10 @@ const ri = () => {
|
|
|
1286
1274
|
[e, t, s, o]
|
|
1287
1275
|
);
|
|
1288
1276
|
}, fi = () => ({}), Sa = () => {
|
|
1289
|
-
const e = L(Q), t =
|
|
1277
|
+
const e = L(Q), t = K();
|
|
1290
1278
|
return A(
|
|
1291
1279
|
(s, o) => {
|
|
1292
|
-
const n = V(e, (r) => (
|
|
1280
|
+
const n = V(e, (r) => ($(s, E(r, "_id")) && fe(r, "_parent", o), r));
|
|
1293
1281
|
t({ type: "set_blocks", payload: n });
|
|
1294
1282
|
},
|
|
1295
1283
|
[e, t]
|
|
@@ -1315,20 +1303,20 @@ const ri = () => {
|
|
|
1315
1303
|
}, []);
|
|
1316
1304
|
return { currentProject: e, createProject: o, deleteProject: t, updateProject: s };
|
|
1317
1305
|
}, xs = (e, t) => {
|
|
1318
|
-
const s = [], o = I(e, (n) =>
|
|
1306
|
+
const s = [], o = I(e, (n) => $(t, n._id) || $(t, n._parent) ? (s.push(n._id), !1) : !0);
|
|
1319
1307
|
return oe(s) ? o : xs(o, s);
|
|
1320
1308
|
}, xi = () => {
|
|
1321
|
-
const e =
|
|
1309
|
+
const e = K(), t = L(Q), [s, o] = Ce();
|
|
1322
1310
|
return A(
|
|
1323
1311
|
(n) => {
|
|
1324
1312
|
var u;
|
|
1325
|
-
const r = ((u =
|
|
1326
|
-
e({ type: "set_blocks", payload: i }), o(r ? [r] : []);
|
|
1313
|
+
const r = ((u = se(t, { _id: n[0] })) == null ? void 0 : u._parent) || null, i = xs(t, n);
|
|
1314
|
+
e({ type: "set_blocks", payload: i }), setTimeout(() => o(r ? [r] : []), 200);
|
|
1327
1315
|
},
|
|
1328
1316
|
[t, o, e, s]
|
|
1329
1317
|
);
|
|
1330
1318
|
}, Aa = y(null, (e, t, { blockIds: s, fullClasses: o, dispatch: n }) => {
|
|
1331
|
-
const r =
|
|
1319
|
+
const r = ee(e(_e)), i = I(
|
|
1332
1320
|
e(lt),
|
|
1333
1321
|
(u) => (
|
|
1334
1322
|
// @ts-ignore
|
|
@@ -1341,8 +1329,8 @@ const ri = () => {
|
|
|
1341
1329
|
ce(l, (k) => {
|
|
1342
1330
|
const D = new RegExp(`(^| )${k.replace("[", "\\[").replace("]", "\\]")}($| )`, "g");
|
|
1343
1331
|
b = b.replace(D, " ").replace(/ +/g, " ").trim();
|
|
1344
|
-
const
|
|
1345
|
-
|
|
1332
|
+
const W = ee(k.split(":"));
|
|
1333
|
+
$(["2xl", "xl", "lg", "md", "sm"], W) && l.push(k.split(":").pop().trim());
|
|
1346
1334
|
}), ce(l, (k) => {
|
|
1347
1335
|
const D = new RegExp(`(^| )${k.replace("[", "\\[").replace("]", "\\]")}($| )`, "g");
|
|
1348
1336
|
w = w.replace(D, " ").replace(/ +/g, " ").trim();
|
|
@@ -1357,7 +1345,7 @@ const ri = () => {
|
|
|
1357
1345
|
});
|
|
1358
1346
|
});
|
|
1359
1347
|
}), hi = () => {
|
|
1360
|
-
const e =
|
|
1348
|
+
const e = K(), t = de(Aa);
|
|
1361
1349
|
return A(
|
|
1362
1350
|
(s, o) => {
|
|
1363
1351
|
t({ blockIds: s, fullClasses: o, dispatch: e }), setTimeout(() => e({ type: "create_snapshot" }));
|
|
@@ -1365,7 +1353,7 @@ const ri = () => {
|
|
|
1365
1353
|
[e, t]
|
|
1366
1354
|
);
|
|
1367
1355
|
}, hs = y((e) => {
|
|
1368
|
-
const t =
|
|
1356
|
+
const t = ee(e(_e)), s = e(ut);
|
|
1369
1357
|
if (!t || t.blockId !== E(s, "_id", null))
|
|
1370
1358
|
return [];
|
|
1371
1359
|
const n = E(s, t.prop, `${ge},`).replace(ge, "").split(",").join(" ");
|
|
@@ -1406,7 +1394,7 @@ const ri = () => {
|
|
|
1406
1394
|
payload: { ids: s, props: o }
|
|
1407
1395
|
});
|
|
1408
1396
|
}), Ni = () => {
|
|
1409
|
-
const { createSnapshot: e } = bt(), t =
|
|
1397
|
+
const { createSnapshot: e } = bt(), t = K(), s = de(ys);
|
|
1410
1398
|
return A(
|
|
1411
1399
|
(o, n) => {
|
|
1412
1400
|
s({ blockIds: o, props: n, dispatch: t }), e();
|
|
@@ -1414,7 +1402,7 @@ const ri = () => {
|
|
|
1414
1402
|
[e, t, s]
|
|
1415
1403
|
);
|
|
1416
1404
|
}, ki = () => {
|
|
1417
|
-
const e =
|
|
1405
|
+
const e = K(), t = de(ys);
|
|
1418
1406
|
return A(
|
|
1419
1407
|
(s, o) => {
|
|
1420
1408
|
t({ blockIds: s, props: o, dispatch: e });
|
|
@@ -1609,10 +1597,10 @@ const Ha = be(
|
|
|
1609
1597
|
variant: "default"
|
|
1610
1598
|
}
|
|
1611
1599
|
}
|
|
1612
|
-
), Mi = ({ className: e, variant: t, ...s }) => /* @__PURE__ */ a.jsx("div", { className: c(Ha({ variant: t }), e), ...s }), Di =
|
|
1613
|
-
ws.displayName =
|
|
1600
|
+
), Mi = ({ className: e, variant: t, ...s }) => /* @__PURE__ */ a.jsx("div", { className: c(Ha({ variant: t }), e), ...s }), Di = F.Root, Ei = F.Trigger, ws = ({ className: e, ...t }) => /* @__PURE__ */ a.jsx(F.Portal, { className: c(e), ...t });
|
|
1601
|
+
ws.displayName = F.Portal.displayName;
|
|
1614
1602
|
const Ns = m.forwardRef(({ className: e, ...t }, s) => /* @__PURE__ */ a.jsx(
|
|
1615
|
-
|
|
1603
|
+
F.Overlay,
|
|
1616
1604
|
{
|
|
1617
1605
|
className: c(
|
|
1618
1606
|
"fixed inset-0 z-50 bg-background/80 backdrop-blur-sm data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0",
|
|
@@ -1622,11 +1610,11 @@ const Ns = m.forwardRef(({ className: e, ...t }, s) => /* @__PURE__ */ a.jsx(
|
|
|
1622
1610
|
ref: s
|
|
1623
1611
|
}
|
|
1624
1612
|
));
|
|
1625
|
-
Ns.displayName =
|
|
1613
|
+
Ns.displayName = F.Overlay.displayName;
|
|
1626
1614
|
const qa = m.forwardRef(({ className: e, ...t }, s) => /* @__PURE__ */ a.jsxs(ws, { children: [
|
|
1627
1615
|
/* @__PURE__ */ a.jsx(Ns, {}),
|
|
1628
1616
|
/* @__PURE__ */ a.jsx(
|
|
1629
|
-
|
|
1617
|
+
F.Content,
|
|
1630
1618
|
{
|
|
1631
1619
|
ref: s,
|
|
1632
1620
|
className: c(
|
|
@@ -1637,26 +1625,26 @@ const qa = m.forwardRef(({ className: e, ...t }, s) => /* @__PURE__ */ a.jsxs(ws
|
|
|
1637
1625
|
}
|
|
1638
1626
|
)
|
|
1639
1627
|
] }));
|
|
1640
|
-
qa.displayName =
|
|
1628
|
+
qa.displayName = F.Content.displayName;
|
|
1641
1629
|
const Ka = ({ className: e, ...t }) => /* @__PURE__ */ a.jsx("div", { className: c("flex flex-col space-y-2 text-center sm:text-left", e), ...t });
|
|
1642
1630
|
Ka.displayName = "AlertDialogHeader";
|
|
1643
1631
|
const Ja = ({ className: e, ...t }) => /* @__PURE__ */ a.jsx("div", { className: c("flex flex-col-reverse sm:flex-row sm:justify-end sm:space-x-2", e), ...t });
|
|
1644
1632
|
Ja.displayName = "AlertDialogFooter";
|
|
1645
|
-
const Ya = m.forwardRef(({ className: e, ...t }, s) => /* @__PURE__ */ a.jsx(
|
|
1646
|
-
Ya.displayName =
|
|
1647
|
-
const Qa = m.forwardRef(({ className: e, ...t }, s) => /* @__PURE__ */ a.jsx(
|
|
1648
|
-
Qa.displayName =
|
|
1649
|
-
const Xa = m.forwardRef(({ className: e, ...t }, s) => /* @__PURE__ */ a.jsx(
|
|
1650
|
-
Xa.displayName =
|
|
1633
|
+
const Ya = m.forwardRef(({ className: e, ...t }, s) => /* @__PURE__ */ a.jsx(F.Title, { ref: s, className: c("text-lg font-semibold", e), ...t }));
|
|
1634
|
+
Ya.displayName = F.Title.displayName;
|
|
1635
|
+
const Qa = m.forwardRef(({ className: e, ...t }, s) => /* @__PURE__ */ a.jsx(F.Description, { ref: s, className: c("text-sm text-muted-foreground", e), ...t }));
|
|
1636
|
+
Qa.displayName = F.Description.displayName;
|
|
1637
|
+
const Xa = m.forwardRef(({ className: e, ...t }, s) => /* @__PURE__ */ a.jsx(F.Action, { ref: s, className: c(ht(), e), ...t }));
|
|
1638
|
+
Xa.displayName = F.Action.displayName;
|
|
1651
1639
|
const Za = m.forwardRef(({ className: e, ...t }, s) => /* @__PURE__ */ a.jsx(
|
|
1652
|
-
|
|
1640
|
+
F.Cancel,
|
|
1653
1641
|
{
|
|
1654
1642
|
ref: s,
|
|
1655
1643
|
className: c(ht({ variant: "outline" }), "mt-2 sm:mt-0", e),
|
|
1656
1644
|
...t
|
|
1657
1645
|
}
|
|
1658
1646
|
));
|
|
1659
|
-
Za.displayName =
|
|
1647
|
+
Za.displayName = F.Cancel.displayName;
|
|
1660
1648
|
const ks = B.Root, en = B.Trigger, Ss = ({ className: e, ...t }) => /* @__PURE__ */ a.jsx(B.Portal, { className: c(e), ...t });
|
|
1661
1649
|
Ss.displayName = B.Portal.displayName;
|
|
1662
1650
|
const js = m.forwardRef(({ className: e, ...t }, s) => /* @__PURE__ */ a.jsx(
|
|
@@ -2292,8 +2280,8 @@ function ar() {
|
|
|
2292
2280
|
dismiss: (s) => ke({ type: "DISMISS_TOAST", toastId: s })
|
|
2293
2281
|
};
|
|
2294
2282
|
}
|
|
2295
|
-
const nr =
|
|
2296
|
-
|
|
2283
|
+
const nr = q.Provider, Rs = m.forwardRef(({ className: e, ...t }, s) => /* @__PURE__ */ a.jsx(
|
|
2284
|
+
q.Viewport,
|
|
2297
2285
|
{
|
|
2298
2286
|
ref: s,
|
|
2299
2287
|
className: c(
|
|
@@ -2303,7 +2291,7 @@ const nr = H.Provider, Rs = m.forwardRef(({ className: e, ...t }, s) => /* @__PU
|
|
|
2303
2291
|
...t
|
|
2304
2292
|
}
|
|
2305
2293
|
));
|
|
2306
|
-
Rs.displayName =
|
|
2294
|
+
Rs.displayName = q.Viewport.displayName;
|
|
2307
2295
|
const rr = be(
|
|
2308
2296
|
"group pointer-events-auto relative flex w-full items-center justify-between space-x-2 overflow-hidden rounded-md border p-4 pr-6 shadow-lg transition-all data-[swipe=cancel]:translate-x-0 data-[swipe=end]:translate-x-[var(--radix-toast-swipe-end-x)] data-[swipe=move]:translate-x-[var(--radix-toast-swipe-move-x)] data-[swipe=move]:transition-none data-[state=open]:animate-in data-[state=closed]:animate-out data-[swipe=end]:animate-out data-[state=closed]:fade-out-80 data-[state=closed]:slide-out-to-right-full data-[state=open]:slide-in-from-top-full data-[state=open]:sm:slide-in-from-bottom-full",
|
|
2309
2297
|
{
|
|
@@ -2317,10 +2305,10 @@ const rr = be(
|
|
|
2317
2305
|
variant: "default"
|
|
2318
2306
|
}
|
|
2319
2307
|
}
|
|
2320
|
-
), Ps = m.forwardRef(({ className: e, variant: t, ...s }, o) => /* @__PURE__ */ a.jsx(
|
|
2321
|
-
Ps.displayName =
|
|
2308
|
+
), Ps = m.forwardRef(({ className: e, variant: t, ...s }, o) => /* @__PURE__ */ a.jsx(q.Root, { ref: o, className: c(rr({ variant: t }), e), ...s }));
|
|
2309
|
+
Ps.displayName = q.Root.displayName;
|
|
2322
2310
|
const ir = m.forwardRef(({ className: e, ...t }, s) => /* @__PURE__ */ a.jsx(
|
|
2323
|
-
|
|
2311
|
+
q.Action,
|
|
2324
2312
|
{
|
|
2325
2313
|
ref: s,
|
|
2326
2314
|
className: c(
|
|
@@ -2330,9 +2318,9 @@ const ir = m.forwardRef(({ className: e, ...t }, s) => /* @__PURE__ */ a.jsx(
|
|
|
2330
2318
|
...t
|
|
2331
2319
|
}
|
|
2332
2320
|
));
|
|
2333
|
-
ir.displayName =
|
|
2321
|
+
ir.displayName = q.Action.displayName;
|
|
2334
2322
|
const Ts = m.forwardRef(({ className: e, ...t }, s) => /* @__PURE__ */ a.jsx(
|
|
2335
|
-
|
|
2323
|
+
q.Close,
|
|
2336
2324
|
{
|
|
2337
2325
|
ref: s,
|
|
2338
2326
|
className: c(
|
|
@@ -2344,11 +2332,11 @@ const Ts = m.forwardRef(({ className: e, ...t }, s) => /* @__PURE__ */ a.jsx(
|
|
|
2344
2332
|
children: /* @__PURE__ */ a.jsx(tt, { className: "h-4 w-4" })
|
|
2345
2333
|
}
|
|
2346
2334
|
));
|
|
2347
|
-
Ts.displayName =
|
|
2348
|
-
const Is = m.forwardRef(({ className: e, ...t }, s) => /* @__PURE__ */ a.jsx(
|
|
2349
|
-
Is.displayName =
|
|
2350
|
-
const Ms = m.forwardRef(({ className: e, ...t }, s) => /* @__PURE__ */ a.jsx(
|
|
2351
|
-
Ms.displayName =
|
|
2335
|
+
Ts.displayName = q.Close.displayName;
|
|
2336
|
+
const Is = m.forwardRef(({ className: e, ...t }, s) => /* @__PURE__ */ a.jsx(q.Title, { ref: s, className: c("text-sm font-semibold [&+div]:text-xs", e), ...t }));
|
|
2337
|
+
Is.displayName = q.Title.displayName;
|
|
2338
|
+
const Ms = m.forwardRef(({ className: e, ...t }, s) => /* @__PURE__ */ a.jsx(q.Description, { ref: s, className: c("text-sm opacity-90", e), ...t }));
|
|
2339
|
+
Ms.displayName = q.Description.displayName;
|
|
2352
2340
|
function ll() {
|
|
2353
2341
|
const { toasts: e } = ar();
|
|
2354
2342
|
return /* @__PURE__ */ a.jsxs(nr, { children: [
|
|
@@ -2364,7 +2352,7 @@ function ll() {
|
|
|
2364
2352
|
] });
|
|
2365
2353
|
}
|
|
2366
2354
|
const cl = ({ className: e, ...t }) => /* @__PURE__ */ a.jsx("div", { className: c("animate-pulse rounded-md bg-primary/10", e), ...t }), Ds = m.forwardRef(({ className: e, ...t }, s) => /* @__PURE__ */ a.jsx(
|
|
2367
|
-
|
|
2355
|
+
U,
|
|
2368
2356
|
{
|
|
2369
2357
|
ref: s,
|
|
2370
2358
|
className: c(
|
|
@@ -2374,11 +2362,11 @@ const cl = ({ className: e, ...t }) => /* @__PURE__ */ a.jsx("div", { className:
|
|
|
2374
2362
|
...t
|
|
2375
2363
|
}
|
|
2376
2364
|
));
|
|
2377
|
-
Ds.displayName =
|
|
2365
|
+
Ds.displayName = U.displayName;
|
|
2378
2366
|
const dl = ({ children: e, ...t }) => /* @__PURE__ */ a.jsx(ks, { ...t, children: /* @__PURE__ */ a.jsx(yt, { className: "overflow-hidden p-0", children: /* @__PURE__ */ a.jsx(Ds, { className: "[&_[cmdk-group-heading]]:px-2 [&_[cmdk-group-heading]]:font-medium [&_[cmdk-group-heading]]:text-muted-foreground [&_[cmdk-group]:not([hidden])_~[cmdk-group]]:pt-0 [&_[cmdk-group]]:px-2 [&_[cmdk-input-wrapper]_svg]:h-5 [&_[cmdk-input-wrapper]_svg]:w-5 [&_[cmdk-input]]:h-12 [&_[cmdk-item]]:px-2 [&_[cmdk-item]]:py-3 [&_[cmdk-item]_svg]:h-5 [&_[cmdk-item]_svg]:w-5", children: e }) }) }), lr = m.forwardRef(({ className: e, ...t }, s) => /* @__PURE__ */ a.jsxs("div", { className: "flex items-center border-b px-3", "cmdk-input-wrapper": "", children: [
|
|
2379
2367
|
/* @__PURE__ */ a.jsx(qs, { className: "mr-2 h-4 w-4 shrink-0 opacity-50" }),
|
|
2380
2368
|
/* @__PURE__ */ a.jsx(
|
|
2381
|
-
|
|
2369
|
+
U.Input,
|
|
2382
2370
|
{
|
|
2383
2371
|
ref: s,
|
|
2384
2372
|
className: c(
|
|
@@ -2389,20 +2377,20 @@ const dl = ({ children: e, ...t }) => /* @__PURE__ */ a.jsx(ks, { ...t, children
|
|
|
2389
2377
|
}
|
|
2390
2378
|
)
|
|
2391
2379
|
] }));
|
|
2392
|
-
lr.displayName =
|
|
2380
|
+
lr.displayName = U.Input.displayName;
|
|
2393
2381
|
const cr = m.forwardRef(({ className: e, ...t }, s) => /* @__PURE__ */ a.jsx(
|
|
2394
|
-
|
|
2382
|
+
U.List,
|
|
2395
2383
|
{
|
|
2396
2384
|
ref: s,
|
|
2397
2385
|
className: c("max-h-[300px] overflow-y-auto overflow-x-hidden", e),
|
|
2398
2386
|
...t
|
|
2399
2387
|
}
|
|
2400
2388
|
));
|
|
2401
|
-
cr.displayName =
|
|
2402
|
-
const dr = m.forwardRef((e, t) => /* @__PURE__ */ a.jsx(
|
|
2403
|
-
dr.displayName =
|
|
2389
|
+
cr.displayName = U.List.displayName;
|
|
2390
|
+
const dr = m.forwardRef((e, t) => /* @__PURE__ */ a.jsx(U.Empty, { ref: t, className: "py-6 text-center text-sm", ...e }));
|
|
2391
|
+
dr.displayName = U.Empty.displayName;
|
|
2404
2392
|
const ur = m.forwardRef(({ className: e, ...t }, s) => /* @__PURE__ */ a.jsx(
|
|
2405
|
-
|
|
2393
|
+
U.Group,
|
|
2406
2394
|
{
|
|
2407
2395
|
ref: s,
|
|
2408
2396
|
className: c(
|
|
@@ -2412,11 +2400,11 @@ const ur = m.forwardRef(({ className: e, ...t }, s) => /* @__PURE__ */ a.jsx(
|
|
|
2412
2400
|
...t
|
|
2413
2401
|
}
|
|
2414
2402
|
));
|
|
2415
|
-
ur.displayName =
|
|
2416
|
-
const mr = m.forwardRef(({ className: e, ...t }, s) => /* @__PURE__ */ a.jsx(
|
|
2417
|
-
mr.displayName =
|
|
2403
|
+
ur.displayName = U.Group.displayName;
|
|
2404
|
+
const mr = m.forwardRef(({ className: e, ...t }, s) => /* @__PURE__ */ a.jsx(U.Separator, { ref: s, className: c("-mx-1 h-px bg-border", e), ...t }));
|
|
2405
|
+
mr.displayName = U.Separator.displayName;
|
|
2418
2406
|
const pr = m.forwardRef(({ className: e, ...t }, s) => /* @__PURE__ */ a.jsx(
|
|
2419
|
-
|
|
2407
|
+
U.Item,
|
|
2420
2408
|
{
|
|
2421
2409
|
ref: s,
|
|
2422
2410
|
className: c(
|
|
@@ -2426,7 +2414,7 @@ const pr = m.forwardRef(({ className: e, ...t }, s) => /* @__PURE__ */ a.jsx(
|
|
|
2426
2414
|
...t
|
|
2427
2415
|
}
|
|
2428
2416
|
));
|
|
2429
|
-
pr.displayName =
|
|
2417
|
+
pr.displayName = U.Item.displayName;
|
|
2430
2418
|
const fr = ({ className: e, ...t }) => /* @__PURE__ */ a.jsx("span", { className: c("ml-auto text-xs tracking-widest text-muted-foreground", e), ...t });
|
|
2431
2419
|
fr.displayName = "CommandShortcut";
|
|
2432
2420
|
const ul = T.Root, ml = T.Trigger, pl = T.Group, fl = T.Portal, gl = T.Sub, bl = T.RadioGroup, gr = m.forwardRef(({ className: e, inset: t, children: s, ...o }, n) => /* @__PURE__ */ a.jsxs(
|
|
@@ -2592,7 +2580,7 @@ const Sr = (e) => {
|
|
|
2592
2580
|
}
|
|
2593
2581
|
)
|
|
2594
2582
|
] });
|
|
2595
|
-
}, jr = et.lazy(() => import("./UnsplashImages-
|
|
2583
|
+
}, jr = et.lazy(() => import("./UnsplashImages-qm48rQ85.js")), Ar = et.lazy(() => import("./UploadImages-0hJF9pBC.js")), Es = ({
|
|
2596
2584
|
isModalView: e = !1,
|
|
2597
2585
|
onSelect: t = () => {
|
|
2598
2586
|
}
|
|
@@ -2792,7 +2780,7 @@ export {
|
|
|
2792
2780
|
fa as aW,
|
|
2793
2781
|
Zr as aX,
|
|
2794
2782
|
ei as aY,
|
|
2795
|
-
|
|
2783
|
+
Eo as aZ,
|
|
2796
2784
|
oa as a_,
|
|
2797
2785
|
Qr as aa,
|
|
2798
2786
|
Ni as ab,
|