@chaibuilder/sdk 1.0.24 → 1.1.1
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-P3qHuE5J.cjs +1 -0
- package/dist/AddBlocks-imyQSCbI.js +230 -0
- package/dist/{BrandingOptions-2aNZT1u3.cjs → BrandingOptions-_2XBEPab.cjs} +1 -1
- package/dist/{BrandingOptions-GLVanp1T.js → BrandingOptions-tSNtQ1Kv.js} +1 -1
- package/dist/CanvasArea-JzBGfXSp.js +1412 -0
- package/dist/CanvasArea-rC2E_4eS.cjs +58 -0
- package/dist/{CurrentPage-fyWf5F84.js → CurrentPage-2Hqp8dwp.js} +2 -2
- package/dist/{CurrentPage-JJpZpFko.cjs → CurrentPage-v7RxefU-.cjs} +1 -1
- package/dist/Layers-1H-MUoKM.cjs +1 -0
- package/dist/{Layers-RGy6kyuR.js → Layers-K_1pMZK5.js} +119 -137
- package/dist/{MarkAsGlobalBlock-EsX3-clj.js → MarkAsGlobalBlock-aqik3ouc.js} +1 -1
- package/dist/{MarkAsGlobalBlock-1G5m_8t3.cjs → MarkAsGlobalBlock-p_wvHkQZ.cjs} +1 -1
- package/dist/{PagesPanel-J8uYp1Tp.cjs → PagesPanel-Qt66yy3K.cjs} +1 -1
- package/dist/{PagesPanel-LjiXL4rp.js → PagesPanel-uMZT46fo.js} +3 -3
- package/dist/{ProjectPanel-IXVY1LJ_.cjs → ProjectPanel-g92sgZ-g.cjs} +1 -1
- package/dist/{ProjectPanel-F435j6T2.js → ProjectPanel-nhhdOgSP.js} +3 -3
- package/dist/Settings-IcmgBZm9.cjs +1 -0
- package/dist/{Settings-b3lEaQ7w.js → Settings-pYbQsClt.js} +483 -475
- package/dist/{SidePanels-MnI_uhIo.js → SidePanels-9AjWdvVI.js} +62 -55
- package/dist/{SidePanels-1Ooc-KTb.cjs → SidePanels-CBkl8HgT.cjs} +1 -1
- package/dist/{Topbar-1ClabAix.js → Topbar-Jc74a6oE.js} +1 -1
- package/dist/{Topbar-e0hKiAm_.cjs → Topbar-ZjAs5fDc.cjs} +1 -1
- package/dist/{UnsplashImages-UejSDiRk.js → UnsplashImages-_PxEYx5c.js} +1 -1
- package/dist/{UnsplashImages-OJ5u1mVM.cjs → UnsplashImages-nXceZLmd.cjs} +1 -1
- package/dist/{UploadImages-2SqVkr1u.cjs → UploadImages-tcQb5NZu.cjs} +1 -1
- package/dist/{UploadImages-xBJTMBKX.js → UploadImages-zzSgKmP9.js} +10 -10
- package/dist/{add-page-modal-SdyjVxRW.js → add-page-modal-Ny4uAvWB.js} +3 -3
- package/dist/{add-page-modal-rkF5RqMj.cjs → add-page-modal-eahhWw2b.cjs} +1 -1
- package/dist/{confirm-alert-TCwoZBC3.js → confirm-alert-2JxcNf3T.js} +1 -1
- package/dist/{confirm-alert-uk39UILT.cjs → confirm-alert-mzlwOW9w.cjs} +1 -1
- package/dist/core.cjs +1 -1
- package/dist/core.d.ts +1 -0
- package/dist/core.js +2 -2
- package/dist/{delete-page-modal-PKSlPOAB.cjs → delete-page-modal-07nDpZpj.cjs} +1 -1
- package/dist/{delete-page-modal-pjChqG0d.js → delete-page-modal-4qrgJQ0x.js} +2 -2
- package/dist/{form-aIN_qzKQ.js → form-TQ7vwDYO.js} +1 -1
- package/dist/{form-N6Izl5Ni.cjs → form-bSW-Pkw9.cjs} +1 -1
- package/dist/{index-aPk1Fuat.js → index-ORFlyrBx.js} +536 -534
- package/dist/{index-LL32f5q7.cjs → index-Ua5E0Syv.cjs} +11 -11
- package/dist/{index-0ZqKzbSx.js → index-aDqFUJ8v.js} +165 -160
- package/dist/index-zkc4SQCu.cjs +1 -0
- package/dist/{page-viewer-SMOg1l3b.js → page-viewer-1Eb7ypob.js} +3 -3
- package/dist/{page-viewer-wrYXvC-7.cjs → page-viewer-X8h3FMwb.cjs} +1 -1
- package/dist/{project-general-setting-wDjCo89M.cjs → project-general-setting-I4z0C7PE.cjs} +1 -1
- package/dist/{project-general-setting-CcnnvnwD.js → project-general-setting-TCl_JNdl.js} +3 -3
- package/dist/{project-seo-setting-RJMYUQxR.cjs → project-seo-setting-cERASO9j.cjs} +1 -1
- package/dist/{project-seo-setting-CPtrvtsw.js → project-seo-setting-k0HlefUD.js} +2 -2
- package/dist/{single-page-detail-7NRw-CLc.js → single-page-detail-W5sW6771.js} +4 -4
- package/dist/{single-page-detail-gnpyWcy7.cjs → single-page-detail-sdTzXA5i.cjs} +1 -1
- package/dist/studio.cjs +1 -1
- package/dist/studio.js +2 -2
- package/dist/ui.cjs +1 -1
- package/dist/ui.js +57 -57
- package/dist/useAddBlockByDrop-DPV32UHP.cjs +1 -0
- package/dist/useAddBlockByDrop-UA_Iw_4l.js +20 -0
- package/package.json +2 -2
- package/dist/AddBlocks-F05ZiQnz.cjs +0 -3
- package/dist/AddBlocks-kmAje7cV.js +0 -270
- package/dist/CanvasArea-AHGpIP2x.cjs +0 -56
- package/dist/CanvasArea-gJ_UifbO.js +0 -1349
- package/dist/Layers-YtfF6ty5.cjs +0 -1
- package/dist/Settings-xwTkQuKA.cjs +0 -1
- package/dist/index-4h4Ti2E4.cjs +0 -1
|
@@ -19,13 +19,13 @@ import iS from "i18next";
|
|
|
19
19
|
import { initReactI18next as oS } from "react-i18next";
|
|
20
20
|
import { j as n1 } from "./jsx-runtime-NV737rRe.js";
|
|
21
21
|
import * as O from "react";
|
|
22
|
-
import p, { useState as g1, useRef as z1, useLayoutEffect as L3, useEffect as L1, useCallback as D1, useDebugValue as
|
|
23
|
-
import { u as O3, a as h2, c as qf, b as wt, d as Pe, e as s2, f as d0, g as Wf, h as dS, i as J4, B as S3, S as uS, j as Kf, k as gS, l as fS, m as pS, n as zS, o as MS, p as mS, q as HS, r as VS, s as wS, t as bS, v as yS, T as xS, w as LS, x as OS, y as Uf, z as SS, A as CS, C as BS, D as AS, E as PS, F as ES, G as IS, H as kS, I as NS, J as RS, K as TS } from "./index-
|
|
22
|
+
import p, { useState as g1, useRef as z1, useLayoutEffect as L3, useEffect as L1, useCallback as D1, useDebugValue as o91, useContext as Et, forwardRef as Q, createContext as $t, useReducer as cS, useMemo as fa, cloneElement as Ae, Fragment as hS, Children as br, Component as Ff, isValidElement as sS, createElement as G4, memo as vS, Suspense as Ue, lazy as v0 } from "react";
|
|
23
|
+
import { u as O3, a as h2, c as qf, b as wt, d as Pe, e as s2, f as d0, g as Wf, h as dS, i as J4, B as S3, S as uS, j as Kf, k as gS, l as fS, m as pS, n as zS, o as MS, p as mS, q as HS, r as VS, s as wS, t as bS, v as yS, T as xS, w as LS, x as OS, y as Uf, z as SS, A as CS, C as BS, D as AS, E as PS, F as ES, G as IS, H as kS, I as NS, J as RS, K as TS } from "./index-ORFlyrBx.js";
|
|
24
24
|
import { g as Ii, c as j0 } from "./MODIFIERS-MLfpKQY1.js";
|
|
25
25
|
import Zf from "clsx";
|
|
26
26
|
import { flushSync as DS, createPortal as jS } from "react-dom";
|
|
27
27
|
import * as je from "@radix-ui/react-scroll-area";
|
|
28
|
-
import { getOverflowAncestors as S4, offset as Gf, detectOverflow as
|
|
28
|
+
import { getOverflowAncestors as S4, offset as Gf, detectOverflow as u91, useFloating as FS, autoUpdate as qS, shift as C3, limitShift as WS, flip as Jf, inline as Yf, arrow as Qf, size as KS } from "@floating-ui/react-dom";
|
|
29
29
|
import US from "react-textarea-autosize";
|
|
30
30
|
import { useAtom as ki, atom as ZS, useAtomValue as Xf, getDefaultStore as GS } from "jotai";
|
|
31
31
|
import { FlagsProvider as JS } from "flagged";
|
|
@@ -976,7 +976,7 @@ function pB() {
|
|
|
976
976
|
Z1.AsyncMode = w, Z1.ConcurrentMode = y, Z1.ContextConsumer = x, Z1.ContextProvider = L, Z1.Element = S, Z1.ForwardRef = E, Z1.Fragment = C, Z1.Lazy = N, Z1.Memo = k, Z1.Portal = T, Z1.Profiler = U, Z1.StrictMode = t1, Z1.Suspense = Z, Z1.isAsyncMode = J, Z1.isConcurrentMode = W, Z1.isContextConsumer = G, Z1.isContextProvider = P, Z1.isElement = F, Z1.isForwardRef = a1, Z1.isFragment = _, Z1.isLazy = X, Z1.isMemo = v1, Z1.isPortal = o1, Z1.isProfiler = c1, Z1.isStrictMode = $, Z1.isSuspense = s1, Z1.isValidElementType = V, Z1.typeOf = b;
|
|
977
977
|
}()), Z1;
|
|
978
978
|
}
|
|
979
|
-
var
|
|
979
|
+
var O91 = Q4.exports;
|
|
980
980
|
process.env.NODE_ENV === "production" ? Q4.exports = fB() : Q4.exports = pB();
|
|
981
981
|
var zB = Q4.exports;
|
|
982
982
|
var hp = zB;
|
|
@@ -996,7 +996,7 @@ var MB = {
|
|
|
996
996
|
}, sp = {};
|
|
997
997
|
sp[hp.ForwardRef] = MB;
|
|
998
998
|
sp[hp.Memo] = mB;
|
|
999
|
-
var
|
|
999
|
+
var S91 = Object.prototype;
|
|
1000
1000
|
var HB = !0;
|
|
1001
1001
|
function k3(t, e, a) {
|
|
1002
1002
|
var r = "";
|
|
@@ -1267,7 +1267,7 @@ var B2, ca = function(e, a, r) {
|
|
|
1267
1267
|
}) : null
|
|
1268
1268
|
);
|
|
1269
1269
|
process.env.NODE_ENV !== "production" && (ar.displayName = "EmotionCacheContext");
|
|
1270
|
-
var
|
|
1270
|
+
var C91 = ar.Provider;
|
|
1271
1271
|
var Fi = function(e) {
|
|
1272
1272
|
return /* @__PURE__ */ Q(function(a, r) {
|
|
1273
1273
|
var n = Et(ar);
|
|
@@ -2646,7 +2646,7 @@ function Bp(t) {
|
|
|
2646
2646
|
}
|
|
2647
2647
|
});
|
|
2648
2648
|
}
|
|
2649
|
-
const
|
|
2649
|
+
const B91 = Object.keys(Lp), Ap = ["xs", "sm", "md", "lg", "xl"], iP = {
|
|
2650
2650
|
dir: "ltr",
|
|
2651
2651
|
primaryShade: {
|
|
2652
2652
|
light: 6,
|
|
@@ -3288,7 +3288,7 @@ const Ca = {
|
|
|
3288
3288
|
"pop-top-right": Sa(Oa({}, Ca), {
|
|
3289
3289
|
common: { transformOrigin: "top right" }
|
|
3290
3290
|
})
|
|
3291
|
-
},
|
|
3291
|
+
}, A91 = Object.keys(qa), Gs = ["mousedown", "touchstart"];
|
|
3292
3292
|
function YP(t, e, a) {
|
|
3293
3293
|
const r = z1();
|
|
3294
3294
|
return L1(() => {
|
|
@@ -6730,8 +6730,8 @@ var zT = e1(() => ({
|
|
|
6730
6730
|
* tabbable 6.2.0
|
|
6731
6731
|
* @license MIT, https://github.com/focus-trap/tabbable/blob/master/LICENSE
|
|
6732
6732
|
*/
|
|
6733
|
-
var SM = typeof Element > "u",
|
|
6734
|
-
} : Element.prototype.matches || Element.prototype.msMatchesSelector || Element.prototype.webkitMatchesSelector,
|
|
6733
|
+
var SM = typeof Element > "u", P91 = SM ? function() {
|
|
6734
|
+
} : Element.prototype.matches || Element.prototype.msMatchesSelector || Element.prototype.webkitMatchesSelector, E91 = !SM && Element.prototype.getRootNode ? function(t) {
|
|
6735
6735
|
var e;
|
|
6736
6736
|
return t == null || (e = t.getRootNode) === null || e === void 0 ? void 0 : e.call(t);
|
|
6737
6737
|
} : function(t) {
|
|
@@ -9365,7 +9365,7 @@ const pF = {
|
|
|
9365
9365
|
});
|
|
9366
9366
|
nh.displayName = "@mantine/core/Avatar";
|
|
9367
9367
|
nh.Group = mm;
|
|
9368
|
-
const
|
|
9368
|
+
const I91 = nh;
|
|
9369
9369
|
var zF = Object.defineProperty, MF = Object.defineProperties, mF = Object.getOwnPropertyDescriptors, M6 = Object.getOwnPropertySymbols, HF = Object.prototype.hasOwnProperty, VF = Object.prototype.propertyIsEnumerable, m6 = (t, e, a) => e in t ? zF(t, e, { enumerable: !0, configurable: !0, writable: !0, value: a }) : t[e] = a, wF = (t, e) => {
|
|
9370
9370
|
for (var a in e || (e = {}))
|
|
9371
9371
|
HF.call(e, a) && m6(t, a, e[a]);
|
|
@@ -9411,7 +9411,7 @@ const AF = {
|
|
|
9411
9411
|
}));
|
|
9412
9412
|
});
|
|
9413
9413
|
ym.displayName = "@mantine/core/BackgroundImage";
|
|
9414
|
-
const
|
|
9414
|
+
const k91 = ym;
|
|
9415
9415
|
var PF = Object.defineProperty, EF = Object.defineProperties, IF = Object.getOwnPropertyDescriptors, V6 = Object.getOwnPropertySymbols, kF = Object.prototype.hasOwnProperty, NF = Object.prototype.propertyIsEnumerable, w6 = (t, e, a) => e in t ? PF(t, e, { enumerable: !0, configurable: !0, writable: !0, value: a }) : t[e] = a, Fo = (t, e) => {
|
|
9416
9416
|
for (var a in e || (e = {}))
|
|
9417
9417
|
kF.call(e, a) && w6(t, a, e[a]);
|
|
@@ -10267,7 +10267,7 @@ const rW = {
|
|
|
10267
10267
|
});
|
|
10268
10268
|
oh.Section = Jm;
|
|
10269
10269
|
oh.displayName = "@mantine/core/Card";
|
|
10270
|
-
const
|
|
10270
|
+
const N91 = oh;
|
|
10271
10271
|
var nW = e1((t, { inline: e }) => ({
|
|
10272
10272
|
root: {
|
|
10273
10273
|
display: e ? "inline-flex" : "flex",
|
|
@@ -10298,7 +10298,7 @@ const $m = Q((t, e) => {
|
|
|
10298
10298
|
}, o));
|
|
10299
10299
|
});
|
|
10300
10300
|
$m.displayName = "@mantine/core/Center";
|
|
10301
|
-
const
|
|
10301
|
+
const R91 = $m, tH = $t(null), cW = tH.Provider, hW = () => Et(tH);
|
|
10302
10302
|
var sW = Object.defineProperty, c5 = Object.getOwnPropertySymbols, eH = Object.prototype.hasOwnProperty, aH = Object.prototype.propertyIsEnumerable, j6 = (t, e, a) => e in t ? sW(t, e, { enumerable: !0, configurable: !0, writable: !0, value: a }) : t[e] = a, F6 = (t, e) => {
|
|
10303
10303
|
for (var a in e || (e = {}))
|
|
10304
10304
|
eH.call(e, a) && j6(t, a, e[a]);
|
|
@@ -13598,7 +13598,7 @@ const OJ = {
|
|
|
13598
13598
|
}, h)));
|
|
13599
13599
|
});
|
|
13600
13600
|
QV.displayName = "@mantine/core/Highlight";
|
|
13601
|
-
const
|
|
13601
|
+
const T91 = QV, XV = {
|
|
13602
13602
|
context: "HoverCard component was not found in the tree",
|
|
13603
13603
|
children: "HoverCard.Target component children should be an element or a component that accepts ref. Fragments, strings, numbers and other primitive values are not supported"
|
|
13604
13604
|
}, [SJ, _V] = w2(XV.context);
|
|
@@ -14034,7 +14034,7 @@ const mY = {
|
|
|
14034
14034
|
})));
|
|
14035
14035
|
});
|
|
14036
14036
|
zw.displayName = "@mantine/core/InputBase";
|
|
14037
|
-
const
|
|
14037
|
+
const D91 = zw;
|
|
14038
14038
|
function P8(t, e) {
|
|
14039
14039
|
if (typeof t == "string" && t.trim().length === 0)
|
|
14040
14040
|
return !0;
|
|
@@ -25453,7 +25453,7 @@ var Eh = { exports: {} }, cL = {
|
|
|
25453
25453
|
var Ih = { exports: {} }, gn1 = function(e) {
|
|
25454
25454
|
return !e || typeof e == "string" ? !1 : e instanceof Array || Array.isArray(e) || e.length >= 0 && (e.splice instanceof Function || Object.getOwnPropertyDescriptor(e, e.length - 1) && e.constructor.name !== "String");
|
|
25455
25455
|
};
|
|
25456
|
-
var
|
|
25456
|
+
var j91 = Ih.exports, fn1 = gn1, pn1 = Array.prototype.concat, zn1 = Array.prototype.slice, Sg = Ih.exports = function(e) {
|
|
25457
25457
|
for (var a = [], r = 0, n = e.length; r < n; r++) {
|
|
25458
25458
|
var l = e[r];
|
|
25459
25459
|
fn1(l) ? a = pn1.call(a, zn1.call(l)) : a.push(l);
|
|
@@ -25466,7 +25466,7 @@ Sg.wrap = function(t) {
|
|
|
25466
25466
|
};
|
|
25467
25467
|
};
|
|
25468
25468
|
var Mn1 = Ih.exports;
|
|
25469
|
-
var
|
|
25469
|
+
var F91 = Eh.exports, Xa = cL, Er = Mn1, hL = Object.hasOwnProperty, sL = /* @__PURE__ */ Object.create(null);
|
|
25470
25470
|
for (var zc in Xa)
|
|
25471
25471
|
hL.call(Xa, zc) && (sL[Xa[zc]] = zc);
|
|
25472
25472
|
var o2 = Eh.exports = {
|
|
@@ -25717,7 +25717,7 @@ var kh = { exports: {} }, Hn1 = {
|
|
|
25717
25717
|
yellow: [255, 255, 0],
|
|
25718
25718
|
yellowgreen: [154, 205, 50]
|
|
25719
25719
|
};
|
|
25720
|
-
var
|
|
25720
|
+
var q91 = kh.exports, n0 = Hn1, vL = {};
|
|
25721
25721
|
for (var Mc in n0)
|
|
25722
25722
|
n0.hasOwnProperty(Mc) && (vL[n0[Mc]] = Mc);
|
|
25723
25723
|
var V1 = kh.exports = {
|
|
@@ -30879,7 +30879,7 @@ function El1() {
|
|
|
30879
30879
|
let t = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : [], e = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : [];
|
|
30880
30880
|
return t.length !== e.length || t.some((a, r) => !Object.is(a, e[r]));
|
|
30881
30881
|
}
|
|
30882
|
-
var jh = { exports: {} },
|
|
30882
|
+
var jh = { exports: {} }, K91 = jh.exports;
|
|
30883
30883
|
(function(t) {
|
|
30884
30884
|
var e = function() {
|
|
30885
30885
|
this.Diff_Timeout = 1, this.Diff_EditCost = 4, this.Match_Threshold = 0.5, this.Match_Distance = 1e3, this.Patch_DeleteThreshold = 0.5, this.Patch_Margin = 4, this.Match_MaxBits = 32;
|
|
@@ -31911,7 +31911,7 @@ function Nl1() {
|
|
|
31911
31911
|
});
|
|
31912
31912
|
}), yc = a, yc;
|
|
31913
31913
|
}
|
|
31914
|
-
var
|
|
31914
|
+
var U91 = Fh.exports;
|
|
31915
31915
|
(function(t) {
|
|
31916
31916
|
"use strict";
|
|
31917
31917
|
const e = (h, s) => (...d) => `\x1B[${h(...d) + s}m`, a = (h, s) => (...d) => {
|
|
@@ -33125,7 +33125,7 @@ function We(t) {
|
|
|
33125
33125
|
return a;
|
|
33126
33126
|
};
|
|
33127
33127
|
}
|
|
33128
|
-
const
|
|
33128
|
+
const Z91 = {
|
|
33129
33129
|
added: We("green"),
|
|
33130
33130
|
deleted: We("red"),
|
|
33131
33131
|
movedestination: We("gray"),
|
|
@@ -36288,7 +36288,7 @@ D();
|
|
|
36288
36288
|
D();
|
|
36289
36289
|
D();
|
|
36290
36290
|
D();
|
|
36291
|
-
var
|
|
36291
|
+
var G91 = qf(), iO = $t(
|
|
36292
36292
|
void 0
|
|
36293
36293
|
), Gh = () => {
|
|
36294
36294
|
const t = Et(iO);
|
|
@@ -38530,8 +38530,13 @@ object-assign/index.js:
|
|
|
38530
38530
|
*/
|
|
38531
38531
|
D();
|
|
38532
38532
|
var Ch1 = process.env.NODE_ENV !== "production" ? Sh1 : () => null;
|
|
38533
|
-
|
|
38534
|
-
|
|
38533
|
+
function Bh1() {
|
|
38534
|
+
return new URLSearchParams(window.location.search).has("dnd");
|
|
38535
|
+
}
|
|
38536
|
+
const Ah1 = {
|
|
38537
|
+
dnd: Bh1()
|
|
38538
|
+
};
|
|
38539
|
+
class Ph1 extends p.Component {
|
|
38535
38540
|
constructor(e) {
|
|
38536
38541
|
super(e), this.state = { hasError: !1 };
|
|
38537
38542
|
}
|
|
@@ -38549,13 +38554,13 @@ class Ah1 extends p.Component {
|
|
|
38549
38554
|
] }) : this.props.children;
|
|
38550
38555
|
}
|
|
38551
38556
|
}
|
|
38552
|
-
const
|
|
38557
|
+
const Eh1 = () => {
|
|
38553
38558
|
const [t, e] = dS(), a = J4("previewComponent");
|
|
38554
38559
|
return /* @__PURE__ */ n1.jsxs("div", { className: oC("fixed inset-0 z-[999] bg-background", t ? "block" : "hidden"), children: [
|
|
38555
38560
|
/* @__PURE__ */ n1.jsx(S3, { size: "sm", className: "absolute right-0 top-0 m-4", onClick: () => e(!1), children: "Close Preview" }),
|
|
38556
38561
|
/* @__PURE__ */ n1.jsx("div", { children: a ? /* @__PURE__ */ n1.jsx(Ue, { fallback: /* @__PURE__ */ n1.jsx(uS, { className: "h-96 w-full" }), children: p.createElement(a) }) : null })
|
|
38557
38562
|
] });
|
|
38558
|
-
},
|
|
38563
|
+
}, Ih1 = () => {
|
|
38559
38564
|
const [t, e] = Kf(), [, a] = gS(), r = fS(), n = pS(), [, l] = zS(), { pasteBlocks: i } = MS(), { undo: o, redo: c } = mS();
|
|
38560
38565
|
se("esc", () => e([]), {}, [e]), se("ctrl+c,command+c", () => a(t), {}, [t, a]), se("ctrl+d,command+d", () => n(t), { preventDefault: !0 }, [t, n]), se("ctrl+x,command+x", () => l(t), {}, [t, l]), se("ctrl+v,command+v", () => t.length === 1 ? i(t[0]) : null, {}, [t, i]), se("ctrl+z,command+z", () => o(), {}, [o]), se("ctrl+y,command+y", () => c(), {}, [c]), se(
|
|
38561
38566
|
"del, backspace",
|
|
@@ -38565,21 +38570,21 @@ const Ph1 = () => {
|
|
|
38565
38570
|
{},
|
|
38566
38571
|
[t, r]
|
|
38567
38572
|
);
|
|
38568
|
-
},
|
|
38573
|
+
}, kh1 = (t, e) => {
|
|
38569
38574
|
const a = [];
|
|
38570
38575
|
let r = Bc(t, { _id: e }), n = Ac(r, "_parent", "");
|
|
38571
38576
|
for (; _f(n) && !QS(n); )
|
|
38572
38577
|
a.push(r == null ? void 0 : r._parent), r = Bc(t, { _id: n }), n = r == null ? void 0 : r._parent;
|
|
38573
38578
|
return XS(a);
|
|
38574
|
-
}, FO = ZS([]),
|
|
38579
|
+
}, FO = ZS([]), Nh1 = () => {
|
|
38575
38580
|
const [t] = Kf(), e = Xf(HS), [, a] = ki(FO);
|
|
38576
38581
|
L1(() => {
|
|
38577
38582
|
let r = [];
|
|
38578
38583
|
const n = _S(t);
|
|
38579
|
-
_f(n) && (r = [n, ...
|
|
38584
|
+
_f(n) && (r = [n, ...kh1(e, n)]), a(r);
|
|
38580
38585
|
}, [t, e, a]);
|
|
38581
|
-
},
|
|
38582
|
-
const [, e] =
|
|
38586
|
+
}, J91 = () => Xf(FO), Rh1 = () => ki(VS), Th1 = () => fa(() => cC(), []), Y91 = ({ children: t }) => {
|
|
38587
|
+
const [, e] = Rh1(), [a] = wS(), r = Th1();
|
|
38583
38588
|
return L1(() => (e({}), ls(a, (n) => {
|
|
38584
38589
|
const l = Bc(r, { providerKey: n.providerKey });
|
|
38585
38590
|
if (l) {
|
|
@@ -38593,11 +38598,11 @@ const Ph1 = () => {
|
|
|
38593
38598
|
e((l) => (delete l[n.providerKey], l));
|
|
38594
38599
|
});
|
|
38595
38600
|
}), [r, a, e]), /* @__PURE__ */ n1.jsx(n1.Fragment, { children: t });
|
|
38596
|
-
},
|
|
38601
|
+
}, Dh1 = v0(() => import("./SidePanels-9AjWdvVI.js")), jh1 = v0(() => import("./Topbar-Jc74a6oE.js")), Fh1 = v0(() => import("./CanvasArea-JzBGfXSp.js")), qh1 = v0(() => import("./Settings-pYbQsClt.js")), Wh1 = () => {
|
|
38597
38602
|
const [t] = ki(bS), e = (n) => {
|
|
38598
38603
|
yS() || n.preventDefault();
|
|
38599
38604
|
};
|
|
38600
|
-
|
|
38605
|
+
Ih1(), Nh1(), L1(() => (t !== "SAVED" ? window.onbeforeunload = () => "" : window.onbeforeunload = null, () => {
|
|
38601
38606
|
window.onbeforeunload = null;
|
|
38602
38607
|
}), [t]);
|
|
38603
38608
|
const a = J4("editable", !0), r = J4("nonEditableComponent", null);
|
|
@@ -38608,28 +38613,28 @@ const Ph1 = () => {
|
|
|
38608
38613
|
onContextMenu: e,
|
|
38609
38614
|
className: "flex h-screen flex-col overflow-hidden bg-background text-foreground",
|
|
38610
38615
|
children: [
|
|
38611
|
-
/* @__PURE__ */ n1.jsx("div", { className: "h-14 w-screen shrink-0 border-b border-border", children: /* @__PURE__ */ n1.jsx(Ue, { children: /* @__PURE__ */ n1.jsx(
|
|
38616
|
+
/* @__PURE__ */ n1.jsx("div", { className: "h-14 w-screen shrink-0 border-b border-border", children: /* @__PURE__ */ n1.jsx(Ue, { children: /* @__PURE__ */ n1.jsx(jh1, {}) }) }),
|
|
38612
38617
|
/* @__PURE__ */ n1.jsxs("main", { className: "flex h-full flex-row relative", children: [
|
|
38613
38618
|
a ? null : /* @__PURE__ */ n1.jsx("div", { className: "absolute backdrop-blur-[2px] flex items-center justify-center inset-0 z-[500] h-full w-full", children: /* @__PURE__ */ n1.jsx(Ue, { children: p.createElement(r) }) }),
|
|
38614
|
-
/* @__PURE__ */ n1.jsx("div", { className: "flex h-full w-fit border-border max-h-full", style: { maxHeight: "calc(100vh - 56px)" }, children: /* @__PURE__ */ n1.jsx(Ue, { children: /* @__PURE__ */ n1.jsx(
|
|
38615
|
-
/* @__PURE__ */ n1.jsx("div", { className: "h-full flex-1 bg-slate-800/20", children: /* @__PURE__ */ n1.jsx(Ue, { children: /* @__PURE__ */ n1.jsx(
|
|
38616
|
-
/* @__PURE__ */ n1.jsx("div", { className: "flex h-full w-[280px] min-w-[280px] border-l border-border", children: /* @__PURE__ */ n1.jsx(Ue, { children: /* @__PURE__ */ n1.jsx(
|
|
38619
|
+
/* @__PURE__ */ n1.jsx("div", { className: "flex h-full w-fit border-border max-h-full", style: { maxHeight: "calc(100vh - 56px)" }, children: /* @__PURE__ */ n1.jsx(Ue, { children: /* @__PURE__ */ n1.jsx(Dh1, {}) }) }),
|
|
38620
|
+
/* @__PURE__ */ n1.jsx("div", { className: "h-full flex-1 bg-slate-800/20", children: /* @__PURE__ */ n1.jsx(Ue, { children: /* @__PURE__ */ n1.jsx(Fh1, {}) }) }),
|
|
38621
|
+
/* @__PURE__ */ n1.jsx("div", { className: "flex h-full w-[280px] min-w-[280px] border-l border-border", children: /* @__PURE__ */ n1.jsx(Ue, { children: /* @__PURE__ */ n1.jsx(qh1, {}) }) })
|
|
38617
38622
|
] })
|
|
38618
38623
|
]
|
|
38619
38624
|
}
|
|
38620
38625
|
),
|
|
38621
|
-
/* @__PURE__ */ n1.jsx(
|
|
38626
|
+
/* @__PURE__ */ n1.jsx(Eh1, {})
|
|
38622
38627
|
] }) });
|
|
38623
38628
|
}, Hf = GS();
|
|
38624
|
-
var
|
|
38625
|
-
|
|
38626
|
-
const
|
|
38629
|
+
var Kh1 = { BASE_URL: "/", MODE: "production", DEV: !1, PROD: !0, SSR: !1 };
|
|
38630
|
+
Kh1.NODE_ENV === "development" && console.log("Chai Builder:", xC);
|
|
38631
|
+
const Uh1 = (t) => /* @__PURE__ */ n1.jsx(n1.Fragment, { children: t.children }), Zh1 = (t) => {
|
|
38627
38632
|
const { dndOptions: e = { backend: nC } } = t, [a] = LS(), [, r] = OS(), n = Uf();
|
|
38628
38633
|
return L1(() => {
|
|
38629
38634
|
Hf.set(
|
|
38630
38635
|
// @ts-ignore
|
|
38631
38636
|
SS,
|
|
38632
|
-
$f(t, ["blocks", "subPages", "brandingOptions", "
|
|
38637
|
+
$f(t, ["blocks", "subPages", "brandingOptions", "dataProviders"])
|
|
38633
38638
|
);
|
|
38634
38639
|
}, [t]), L1(() => {
|
|
38635
38640
|
Hf.set(CS, t.dataProviders || []);
|
|
@@ -38637,11 +38642,11 @@ const Kh1 = (t) => /* @__PURE__ */ n1.jsx(n1.Fragment, { children: t.children })
|
|
|
38637
38642
|
a(hC(t.blocks || [])), n();
|
|
38638
38643
|
}, [t.blocks]), L1(() => {
|
|
38639
38644
|
r(t.brandingOptions);
|
|
38640
|
-
}, [t.brandingOptions, r]), /* @__PURE__ */ n1.jsx(YS, { ...e, options: lC(), children: /* @__PURE__ */ n1.jsx(
|
|
38641
|
-
},
|
|
38642
|
-
/* @__PURE__ */ n1.jsxs(JS, { features:
|
|
38645
|
+
}, [t.brandingOptions, r]), /* @__PURE__ */ n1.jsx(YS, { ...e, options: lC(), children: /* @__PURE__ */ n1.jsx(Uh1, { children: /* @__PURE__ */ n1.jsx(Wh1, {}) }) });
|
|
38646
|
+
}, Gh1 = (t) => /* @__PURE__ */ n1.jsxs(Ph1, { children: [
|
|
38647
|
+
/* @__PURE__ */ n1.jsxs(JS, { features: Ah1, children: [
|
|
38643
38648
|
/* @__PURE__ */ n1.jsx(Ch1, {}),
|
|
38644
|
-
/* @__PURE__ */ n1.jsx(
|
|
38649
|
+
/* @__PURE__ */ n1.jsx(Zh1, { ...t })
|
|
38645
38650
|
] }),
|
|
38646
38651
|
/* @__PURE__ */ n1.jsx(BS, {})
|
|
38647
38652
|
] });
|
|
@@ -38664,7 +38669,7 @@ var wa = class {
|
|
|
38664
38669
|
}, ga = typeof window > "u" || "Deno" in window;
|
|
38665
38670
|
function H2() {
|
|
38666
38671
|
}
|
|
38667
|
-
function
|
|
38672
|
+
function Jh1(t, e) {
|
|
38668
38673
|
return typeof t == "function" ? t(e) : t;
|
|
38669
38674
|
}
|
|
38670
38675
|
function u3(t) {
|
|
@@ -38770,15 +38775,15 @@ function xf(t) {
|
|
|
38770
38775
|
function f3(t, e, a) {
|
|
38771
38776
|
return typeof a.structuralSharing == "function" ? a.structuralSharing(t, e) : a.structuralSharing !== !1 ? WO(t, e) : e;
|
|
38772
38777
|
}
|
|
38773
|
-
function
|
|
38778
|
+
function Yh1(t, e, a = 0) {
|
|
38774
38779
|
const r = [...t, e];
|
|
38775
38780
|
return a && r.length > a ? r.slice(1) : r;
|
|
38776
38781
|
}
|
|
38777
|
-
function
|
|
38782
|
+
function Qh1(t, e, a = 0) {
|
|
38778
38783
|
const r = [e, ...t];
|
|
38779
38784
|
return a && r.length > a ? r.slice(0, -1) : r;
|
|
38780
38785
|
}
|
|
38781
|
-
var Ye, pe, U0, Af,
|
|
38786
|
+
var Ye, pe, U0, Af, Xh1 = (Af = class extends wa {
|
|
38782
38787
|
constructor() {
|
|
38783
38788
|
super();
|
|
38784
38789
|
m1(this, Ye, void 0);
|
|
@@ -38818,7 +38823,7 @@ var Ye, pe, U0, Af, Qh1 = (Af = class extends wa {
|
|
|
38818
38823
|
var e;
|
|
38819
38824
|
return typeof B(this, Ye) == "boolean" ? B(this, Ye) : ((e = globalThis.document) == null ? void 0 : e.visibilityState) !== "hidden";
|
|
38820
38825
|
}
|
|
38821
|
-
}, Ye = new WeakMap(), pe = new WeakMap(), U0 = new WeakMap(), Af), Ai = new
|
|
38826
|
+
}, Ye = new WeakMap(), pe = new WeakMap(), U0 = new WeakMap(), Af), Ai = new Xh1(), Z0, ze, G0, Pf, _h1 = (Pf = class extends wa {
|
|
38822
38827
|
constructor() {
|
|
38823
38828
|
super();
|
|
38824
38829
|
m1(this, Z0, !0);
|
|
@@ -38852,8 +38857,8 @@ var Ye, pe, U0, Af, Qh1 = (Af = class extends wa {
|
|
|
38852
38857
|
isOnline() {
|
|
38853
38858
|
return B(this, Z0);
|
|
38854
38859
|
}
|
|
38855
|
-
}, Z0 = new WeakMap(), ze = new WeakMap(), G0 = new WeakMap(), Pf), Pi = new
|
|
38856
|
-
function
|
|
38860
|
+
}, Z0 = new WeakMap(), ze = new WeakMap(), G0 = new WeakMap(), Pf), Pi = new _h1();
|
|
38861
|
+
function $h1(t) {
|
|
38857
38862
|
return Math.min(1e3 * 2 ** t, 3e4);
|
|
38858
38863
|
}
|
|
38859
38864
|
function Ho(t) {
|
|
@@ -38906,7 +38911,7 @@ function ZO(t) {
|
|
|
38906
38911
|
var y;
|
|
38907
38912
|
if (r)
|
|
38908
38913
|
return;
|
|
38909
|
-
const m = t.retry ?? (ga ? 0 : 3), V = t.retryDelay ??
|
|
38914
|
+
const m = t.retry ?? (ga ? 0 : 3), V = t.retryDelay ?? $h1, b = typeof V == "function" ? V(a, M) : V, w = m === !0 || typeof m == "number" && a < m || typeof m == "function" && m(a, M);
|
|
38910
38915
|
if (e || !w) {
|
|
38911
38916
|
u(M);
|
|
38912
38917
|
return;
|
|
@@ -38927,7 +38932,7 @@ function ZO(t) {
|
|
|
38927
38932
|
continueRetry: h
|
|
38928
38933
|
};
|
|
38929
38934
|
}
|
|
38930
|
-
function
|
|
38935
|
+
function ts1() {
|
|
38931
38936
|
let t = [], e = 0, a = (h) => {
|
|
38932
38937
|
h();
|
|
38933
38938
|
}, r = (h) => {
|
|
@@ -38972,7 +38977,7 @@ function $h1() {
|
|
|
38972
38977
|
}
|
|
38973
38978
|
};
|
|
38974
38979
|
}
|
|
38975
|
-
var mt =
|
|
38980
|
+
var mt = ts1(), Qe, Ef, GO = (Ef = class {
|
|
38976
38981
|
constructor() {
|
|
38977
38982
|
m1(this, Qe, void 0);
|
|
38978
38983
|
}
|
|
@@ -38993,7 +38998,7 @@ var mt = $h1(), Qe, Ef, GO = (Ef = class {
|
|
|
38993
38998
|
clearGcTimeout() {
|
|
38994
38999
|
B(this, Qe) && (clearTimeout(B(this, Qe)), u1(this, Qe, void 0));
|
|
38995
39000
|
}
|
|
38996
|
-
}, Qe = new WeakMap(), Ef), J0, Y0, p2, Me, z2, Ot, vr, Xe, Q0, U4, S2, _2, If,
|
|
39001
|
+
}, Qe = new WeakMap(), Ef), J0, Y0, p2, Me, z2, Ot, vr, Xe, Q0, U4, S2, _2, If, es1 = (If = class extends GO {
|
|
38997
39002
|
constructor(e) {
|
|
38998
39003
|
super();
|
|
38999
39004
|
m1(this, Q0);
|
|
@@ -39006,7 +39011,7 @@ var mt = $h1(), Qe, Ef, GO = (Ef = class {
|
|
|
39006
39011
|
m1(this, Ot, void 0);
|
|
39007
39012
|
m1(this, vr, void 0);
|
|
39008
39013
|
m1(this, Xe, void 0);
|
|
39009
|
-
u1(this, Xe, !1), u1(this, vr, e.defaultOptions), P1(this, Q0, U4).call(this, e.options), u1(this, Ot, []), u1(this, p2, e.cache), this.queryKey = e.queryKey, this.queryHash = e.queryHash, u1(this, J0, e.state ||
|
|
39014
|
+
u1(this, Xe, !1), u1(this, vr, e.defaultOptions), P1(this, Q0, U4).call(this, e.options), u1(this, Ot, []), u1(this, p2, e.cache), this.queryKey = e.queryKey, this.queryHash = e.queryHash, u1(this, J0, e.state || as1(this.options)), this.state = B(this, J0), this.scheduleGc();
|
|
39010
39015
|
}
|
|
39011
39016
|
get meta() {
|
|
39012
39017
|
return this.options.meta;
|
|
@@ -39244,7 +39249,7 @@ var mt = $h1(), Qe, Ef, GO = (Ef = class {
|
|
|
39244
39249
|
}), B(this, p2).notify({ query: this, type: "updated", action: e });
|
|
39245
39250
|
});
|
|
39246
39251
|
}, If);
|
|
39247
|
-
function
|
|
39252
|
+
function as1(t) {
|
|
39248
39253
|
const e = typeof t.initialData == "function" ? t.initialData() : t.initialData, a = typeof e < "u", r = a ? typeof t.initialDataUpdatedAt == "function" ? t.initialDataUpdatedAt() : t.initialDataUpdatedAt : 0;
|
|
39249
39254
|
return {
|
|
39250
39255
|
data: e,
|
|
@@ -39261,7 +39266,7 @@ function es1(t) {
|
|
|
39261
39266
|
fetchStatus: "idle"
|
|
39262
39267
|
};
|
|
39263
39268
|
}
|
|
39264
|
-
var T2, kf,
|
|
39269
|
+
var T2, kf, rs1 = (kf = class extends wa {
|
|
39265
39270
|
constructor(e = {}) {
|
|
39266
39271
|
super();
|
|
39267
39272
|
m1(this, T2, void 0);
|
|
@@ -39270,7 +39275,7 @@ var T2, kf, as1 = (kf = class extends wa {
|
|
|
39270
39275
|
build(e, a, r) {
|
|
39271
39276
|
const n = a.queryKey, l = a.queryHash ?? rs(n, a);
|
|
39272
39277
|
let i = this.get(l);
|
|
39273
|
-
return i || (i = new
|
|
39278
|
+
return i || (i = new es1({
|
|
39274
39279
|
cache: this,
|
|
39275
39280
|
queryKey: n,
|
|
39276
39281
|
queryHash: l,
|
|
@@ -39333,7 +39338,7 @@ var T2, kf, as1 = (kf = class extends wa {
|
|
|
39333
39338
|
});
|
|
39334
39339
|
});
|
|
39335
39340
|
}
|
|
39336
|
-
}, T2 = new WeakMap(), kf), D2, dr, n2, X0, j2, fe, Nf,
|
|
39341
|
+
}, T2 = new WeakMap(), kf), D2, dr, n2, X0, j2, fe, Nf, ns1 = (Nf = class extends GO {
|
|
39337
39342
|
constructor(e) {
|
|
39338
39343
|
super();
|
|
39339
39344
|
m1(this, j2);
|
|
@@ -39526,7 +39531,7 @@ function JO() {
|
|
|
39526
39531
|
submittedAt: 0
|
|
39527
39532
|
};
|
|
39528
39533
|
}
|
|
39529
|
-
var M2, ur, _e, Rf,
|
|
39534
|
+
var M2, ur, _e, Rf, ls1 = (Rf = class extends wa {
|
|
39530
39535
|
constructor(e = {}) {
|
|
39531
39536
|
super();
|
|
39532
39537
|
m1(this, M2, void 0);
|
|
@@ -39535,7 +39540,7 @@ var M2, ur, _e, Rf, ns1 = (Rf = class extends wa {
|
|
|
39535
39540
|
this.config = e, u1(this, M2, []), u1(this, ur, 0);
|
|
39536
39541
|
}
|
|
39537
39542
|
build(e, a, r) {
|
|
39538
|
-
const n = new
|
|
39543
|
+
const n = new ns1({
|
|
39539
39544
|
mutationCache: this,
|
|
39540
39545
|
mutationId: ++qr(this, ur)._,
|
|
39541
39546
|
options: e.defaultMutationOptions(a),
|
|
@@ -39591,7 +39596,7 @@ var M2, ur, _e, Rf, ns1 = (Rf = class extends wa {
|
|
|
39591
39596
|
})), B(this, _e);
|
|
39592
39597
|
}
|
|
39593
39598
|
}, M2 = new WeakMap(), ur = new WeakMap(), _e = new WeakMap(), Rf);
|
|
39594
|
-
function
|
|
39599
|
+
function is1(t) {
|
|
39595
39600
|
return {
|
|
39596
39601
|
onFetch: (e, a) => {
|
|
39597
39602
|
const r = async () => {
|
|
@@ -39621,7 +39626,7 @@ function ls1(t) {
|
|
|
39621
39626
|
h(y);
|
|
39622
39627
|
const x = await s(
|
|
39623
39628
|
y
|
|
39624
|
-
), { maxPages: L } = e.options, S = w ?
|
|
39629
|
+
), { maxPages: L } = e.options, S = w ? Qh1 : Yh1;
|
|
39625
39630
|
return {
|
|
39626
39631
|
pages: S(V.pages, x, L),
|
|
39627
39632
|
pageParams: S(V.pageParams, b, L)
|
|
@@ -39629,7 +39634,7 @@ function ls1(t) {
|
|
|
39629
39634
|
};
|
|
39630
39635
|
let u;
|
|
39631
39636
|
if (l && i.length) {
|
|
39632
|
-
const V = l === "backward", b = V ?
|
|
39637
|
+
const V = l === "backward", b = V ? os1 : Lf, w = {
|
|
39633
39638
|
pages: i,
|
|
39634
39639
|
pageParams: o
|
|
39635
39640
|
}, y = b(n, w);
|
|
@@ -39672,7 +39677,7 @@ function Lf(t, { pages: e, pageParams: a }) {
|
|
|
39672
39677
|
a
|
|
39673
39678
|
);
|
|
39674
39679
|
}
|
|
39675
|
-
function
|
|
39680
|
+
function os1(t, { pages: e, pageParams: a }) {
|
|
39676
39681
|
var r;
|
|
39677
39682
|
return (r = t.getPreviousPageParam) == null ? void 0 : r.call(
|
|
39678
39683
|
t,
|
|
@@ -39682,7 +39687,7 @@ function is1(t, { pages: e, pageParams: a }) {
|
|
|
39682
39687
|
a
|
|
39683
39688
|
);
|
|
39684
39689
|
}
|
|
39685
|
-
var Mt, me, He, _0, $0, Ve, ta, ea, Tf,
|
|
39690
|
+
var Mt, me, He, _0, $0, Ve, ta, ea, Tf, cs1 = (Tf = class {
|
|
39686
39691
|
constructor(t = {}) {
|
|
39687
39692
|
m1(this, Mt, void 0);
|
|
39688
39693
|
m1(this, me, void 0);
|
|
@@ -39692,7 +39697,7 @@ var Mt, me, He, _0, $0, Ve, ta, ea, Tf, os1 = (Tf = class {
|
|
|
39692
39697
|
m1(this, Ve, void 0);
|
|
39693
39698
|
m1(this, ta, void 0);
|
|
39694
39699
|
m1(this, ea, void 0);
|
|
39695
|
-
u1(this, Mt, t.queryCache || new
|
|
39700
|
+
u1(this, Mt, t.queryCache || new rs1()), u1(this, me, t.mutationCache || new ls1()), u1(this, He, t.defaultOptions || {}), u1(this, _0, /* @__PURE__ */ new Map()), u1(this, $0, /* @__PURE__ */ new Map()), u1(this, Ve, 0);
|
|
39696
39701
|
}
|
|
39697
39702
|
mount() {
|
|
39698
39703
|
qr(this, Ve)._++, B(this, Ve) === 1 && (u1(this, ta, Ai.subscribe(() => {
|
|
@@ -39726,7 +39731,7 @@ var Mt, me, He, _0, $0, Ve, ta, ea, Tf, os1 = (Tf = class {
|
|
|
39726
39731
|
});
|
|
39727
39732
|
}
|
|
39728
39733
|
setQueryData(t, e, a) {
|
|
39729
|
-
const r = B(this, Mt).find({ queryKey: t }), n = r == null ? void 0 : r.state.data, l =
|
|
39734
|
+
const r = B(this, Mt).find({ queryKey: t }), n = r == null ? void 0 : r.state.data, l = Jh1(e, n);
|
|
39730
39735
|
if (typeof l > "u")
|
|
39731
39736
|
return;
|
|
39732
39737
|
const i = this.defaultQueryOptions({ queryKey: t });
|
|
@@ -39802,7 +39807,7 @@ var Mt, me, He, _0, $0, Ve, ta, ea, Tf, os1 = (Tf = class {
|
|
|
39802
39807
|
return this.fetchQuery(t).then(H2).catch(H2);
|
|
39803
39808
|
}
|
|
39804
39809
|
fetchInfiniteQuery(t) {
|
|
39805
|
-
return t.behavior =
|
|
39810
|
+
return t.behavior = is1(t.pages), this.fetchQuery(t);
|
|
39806
39811
|
}
|
|
39807
39812
|
prefetchInfiniteQuery(t) {
|
|
39808
39813
|
return this.fetchInfiniteQuery(t).then(H2).catch(H2);
|
|
@@ -39873,7 +39878,7 @@ var Mt, me, He, _0, $0, Ve, ta, ea, Tf, os1 = (Tf = class {
|
|
|
39873
39878
|
clear() {
|
|
39874
39879
|
B(this, Mt).clear(), B(this, me).clear();
|
|
39875
39880
|
}
|
|
39876
|
-
}, Mt = new WeakMap(), me = new WeakMap(), He = new WeakMap(), _0 = new WeakMap(), $0 = new WeakMap(), Ve = new WeakMap(), ta = new WeakMap(), ea = new WeakMap(), Tf), Yt, tt, aa, Tt, $e, ra, F2, gr, na, la, t0, e0, we, a0, r0, Ja, fr, p3, pr, z3, zr, M3, Mr, m3, mr, H3, Hr, V3, Vr, w3, Ei, YO, Df,
|
|
39881
|
+
}, Mt = new WeakMap(), me = new WeakMap(), He = new WeakMap(), _0 = new WeakMap(), $0 = new WeakMap(), Ve = new WeakMap(), ta = new WeakMap(), ea = new WeakMap(), Tf), Yt, tt, aa, Tt, $e, ra, F2, gr, na, la, t0, e0, we, a0, r0, Ja, fr, p3, pr, z3, zr, M3, Mr, m3, mr, H3, Hr, V3, Vr, w3, Ei, YO, Df, hs1 = (Df = class extends wa {
|
|
39877
39882
|
constructor(e, a) {
|
|
39878
39883
|
super();
|
|
39879
39884
|
m1(this, r0);
|
|
@@ -39950,7 +39955,7 @@ var Mt, me, He, _0, $0, Ve, ta, ea, Tf, os1 = (Tf = class {
|
|
|
39950
39955
|
}
|
|
39951
39956
|
getOptimisticResult(e) {
|
|
39952
39957
|
const a = B(this, Yt).getQueryCache().build(B(this, Yt), e), r = this.createResult(a, e);
|
|
39953
|
-
return
|
|
39958
|
+
return vs1(this, r) && (u1(this, Tt, r), u1(this, ra, this.options), u1(this, $e, B(this, tt).state)), r;
|
|
39954
39959
|
}
|
|
39955
39960
|
getCurrentResult() {
|
|
39956
39961
|
return B(this, Tt);
|
|
@@ -40119,11 +40124,11 @@ var Mt, me, He, _0, $0, Ve, ta, ea, Tf, os1 = (Tf = class {
|
|
|
40119
40124
|
});
|
|
40120
40125
|
});
|
|
40121
40126
|
}, Df);
|
|
40122
|
-
function
|
|
40127
|
+
function ss1(t, e) {
|
|
40123
40128
|
return e.enabled !== !1 && !t.state.dataUpdatedAt && !(t.state.status === "error" && e.retryOnMount === !1);
|
|
40124
40129
|
}
|
|
40125
40130
|
function Of(t, e) {
|
|
40126
|
-
return
|
|
40131
|
+
return ss1(t, e) || t.state.dataUpdatedAt > 0 && b3(t, e, e.refetchOnMount);
|
|
40127
40132
|
}
|
|
40128
40133
|
function b3(t, e, a) {
|
|
40129
40134
|
if (e.enabled !== !1) {
|
|
@@ -40138,10 +40143,10 @@ function Sf(t, e, a, r) {
|
|
|
40138
40143
|
function ns(t, e) {
|
|
40139
40144
|
return t.isStaleByTime(e.staleTime);
|
|
40140
40145
|
}
|
|
40141
|
-
function
|
|
40146
|
+
function vs1(t, e) {
|
|
40142
40147
|
return !Bi(t.getCurrentResult(), e);
|
|
40143
40148
|
}
|
|
40144
|
-
var be, Kt, m2, te, ia, Z4, wr, y3, jf,
|
|
40149
|
+
var be, Kt, m2, te, ia, Z4, wr, y3, jf, ds1 = (jf = class extends wa {
|
|
40145
40150
|
constructor(a, r) {
|
|
40146
40151
|
super();
|
|
40147
40152
|
m1(this, ia);
|
|
@@ -40232,13 +40237,13 @@ var QO = O.createContext(
|
|
|
40232
40237
|
if (!e)
|
|
40233
40238
|
throw new Error("No QueryClient set, use QueryClientProvider to set one");
|
|
40234
40239
|
return e;
|
|
40235
|
-
},
|
|
40240
|
+
}, us1 = ({
|
|
40236
40241
|
client: t,
|
|
40237
40242
|
children: e
|
|
40238
40243
|
}) => (O.useEffect(() => (t.mount(), () => {
|
|
40239
40244
|
t.unmount();
|
|
40240
|
-
}), [t]), /* @__PURE__ */ O.createElement(QO.Provider, { value: t }, e)), XO = O.createContext(!1),
|
|
40241
|
-
function
|
|
40245
|
+
}), [t]), /* @__PURE__ */ O.createElement(QO.Provider, { value: t }, e)), XO = O.createContext(!1), gs1 = () => O.useContext(XO), X91 = XO.Provider;
|
|
40246
|
+
function fs1() {
|
|
40242
40247
|
let t = !1;
|
|
40243
40248
|
return {
|
|
40244
40249
|
clearReset: () => {
|
|
@@ -40250,35 +40255,35 @@ function gs1() {
|
|
|
40250
40255
|
isReset: () => t
|
|
40251
40256
|
};
|
|
40252
40257
|
}
|
|
40253
|
-
var
|
|
40258
|
+
var ps1 = O.createContext(fs1()), zs1 = () => O.useContext(ps1);
|
|
40254
40259
|
function _O(t, e) {
|
|
40255
40260
|
return typeof t == "function" ? t(...e) : !!t;
|
|
40256
40261
|
}
|
|
40257
|
-
var
|
|
40262
|
+
var Ms1 = (t, e) => {
|
|
40258
40263
|
(t.suspense || t.throwOnError) && (e.isReset() || (t.retryOnMount = !1));
|
|
40259
|
-
},
|
|
40264
|
+
}, ms1 = (t) => {
|
|
40260
40265
|
O.useEffect(() => {
|
|
40261
40266
|
t.clearReset();
|
|
40262
40267
|
}, [t]);
|
|
40263
|
-
},
|
|
40268
|
+
}, Hs1 = ({
|
|
40264
40269
|
result: t,
|
|
40265
40270
|
errorResetBoundary: e,
|
|
40266
40271
|
throwOnError: a,
|
|
40267
40272
|
query: r
|
|
40268
40273
|
}) => t.isError && !e.isReset() && !t.isFetching && _O(a, [t.error, r]);
|
|
40269
|
-
var
|
|
40274
|
+
var Vs1 = (t) => {
|
|
40270
40275
|
t.suspense && typeof t.staleTime != "number" && (t.staleTime = 1e3);
|
|
40271
40276
|
};
|
|
40272
|
-
var
|
|
40277
|
+
var ws1 = (t, e) => (t == null ? void 0 : t.suspense) && e.isPending, bs1 = (t, e, a) => e.fetchOptimistic(t).catch(() => {
|
|
40273
40278
|
a.clearReset();
|
|
40274
40279
|
});
|
|
40275
|
-
function
|
|
40280
|
+
function ys1(t, e, a) {
|
|
40276
40281
|
if (process.env.NODE_ENV !== "production" && (typeof t != "object" || Array.isArray(t)))
|
|
40277
40282
|
throw new Error(
|
|
40278
40283
|
'Bad argument type. Starting with v5, only the "Object" form is allowed when calling query related functions. Please use the error stack to find the culprit call. More info here: https://tanstack.com/query/latest/docs/react/guides/migrating-to-v5#supports-a-single-signature-one-object'
|
|
40279
40284
|
);
|
|
40280
|
-
const r = b2(a), n =
|
|
40281
|
-
i._optimisticResults = n ? "isRestoring" : "optimistic",
|
|
40285
|
+
const r = b2(a), n = gs1(), l = zs1(), i = r.defaultQueryOptions(t);
|
|
40286
|
+
i._optimisticResults = n ? "isRestoring" : "optimistic", Vs1(i), Ms1(i, l), ms1(l);
|
|
40282
40287
|
const [o] = O.useState(
|
|
40283
40288
|
() => new e(
|
|
40284
40289
|
r,
|
|
@@ -40298,9 +40303,9 @@ function bs1(t, e, a) {
|
|
|
40298
40303
|
() => o.getCurrentResult()
|
|
40299
40304
|
), O.useEffect(() => {
|
|
40300
40305
|
o.setOptions(i, { listeners: !1 });
|
|
40301
|
-
}, [i, o]),
|
|
40302
|
-
throw
|
|
40303
|
-
if (
|
|
40306
|
+
}, [i, o]), ws1(i, c))
|
|
40307
|
+
throw bs1(i, o, l);
|
|
40308
|
+
if (Hs1({
|
|
40304
40309
|
result: c,
|
|
40305
40310
|
errorResetBoundary: l,
|
|
40306
40311
|
throwOnError: i.throwOnError,
|
|
@@ -40310,11 +40315,11 @@ function bs1(t, e, a) {
|
|
|
40310
40315
|
return i.notifyOnChangeProps ? c : o.trackResult(c);
|
|
40311
40316
|
}
|
|
40312
40317
|
function Dr(t, e) {
|
|
40313
|
-
return
|
|
40318
|
+
return ys1(t, hs1, e);
|
|
40314
40319
|
}
|
|
40315
40320
|
function k2(t, e) {
|
|
40316
40321
|
const a = b2(e), [r] = O.useState(
|
|
40317
|
-
() => new
|
|
40322
|
+
() => new ds1(
|
|
40318
40323
|
a,
|
|
40319
40324
|
t
|
|
40320
40325
|
)
|
|
@@ -40331,7 +40336,7 @@ function k2(t, e) {
|
|
|
40331
40336
|
() => r.getCurrentResult()
|
|
40332
40337
|
), l = O.useCallback(
|
|
40333
40338
|
(i, o) => {
|
|
40334
|
-
r.mutate(i, o).catch(
|
|
40339
|
+
r.mutate(i, o).catch(xs1);
|
|
40335
40340
|
},
|
|
40336
40341
|
[r]
|
|
40337
40342
|
);
|
|
@@ -40339,7 +40344,7 @@ function k2(t, e) {
|
|
|
40339
40344
|
throw n.error;
|
|
40340
40345
|
return { ...n, mutate: l, mutateAsync: n.mutate };
|
|
40341
40346
|
}
|
|
40342
|
-
function
|
|
40347
|
+
function xs1() {
|
|
40343
40348
|
}
|
|
40344
40349
|
function Ft() {
|
|
40345
40350
|
return b2().getQueryData(["apiBaseUrl"]) || "/api/chaibuilder";
|
|
@@ -40358,14 +40363,14 @@ const b0 = () => {
|
|
|
40358
40363
|
};
|
|
40359
40364
|
let Cf = "";
|
|
40360
40365
|
const jr = () => (Cf = localStorage.getItem("__chai_at"), Cf);
|
|
40361
|
-
function
|
|
40366
|
+
function Ls1(t) {
|
|
40362
40367
|
const e = {
|
|
40363
40368
|
method: "GET",
|
|
40364
40369
|
headers: { "x-chai-access-token": jr() }
|
|
40365
40370
|
};
|
|
40366
40371
|
return fetch(t, e);
|
|
40367
40372
|
}
|
|
40368
|
-
function
|
|
40373
|
+
function Os1(t, e) {
|
|
40369
40374
|
const a = {
|
|
40370
40375
|
method: "POST",
|
|
40371
40376
|
headers: { "x-chai-access-token": jr() },
|
|
@@ -40373,7 +40378,7 @@ function Ls1(t, e) {
|
|
|
40373
40378
|
};
|
|
40374
40379
|
return fetch(t, a);
|
|
40375
40380
|
}
|
|
40376
|
-
function
|
|
40381
|
+
function Ss1(t, e) {
|
|
40377
40382
|
const a = {
|
|
40378
40383
|
method: "PUT",
|
|
40379
40384
|
headers: { "x-chai-access-token": jr() },
|
|
@@ -40381,7 +40386,7 @@ function Os1(t, e) {
|
|
|
40381
40386
|
};
|
|
40382
40387
|
return fetch(t, a);
|
|
40383
40388
|
}
|
|
40384
|
-
function
|
|
40389
|
+
function Cs1(t, e) {
|
|
40385
40390
|
const a = {
|
|
40386
40391
|
method: "DELETE",
|
|
40387
40392
|
headers: { "x-chai-access-token": jr() },
|
|
@@ -40390,10 +40395,10 @@ function Ss1(t, e) {
|
|
|
40390
40395
|
return fetch(t, a);
|
|
40391
40396
|
}
|
|
40392
40397
|
const v2 = {
|
|
40393
|
-
get:
|
|
40394
|
-
post:
|
|
40395
|
-
put:
|
|
40396
|
-
delete:
|
|
40398
|
+
get: Ls1,
|
|
40399
|
+
post: Os1,
|
|
40400
|
+
put: Ss1,
|
|
40401
|
+
delete: Cs1
|
|
40397
40402
|
}, $O = () => {
|
|
40398
40403
|
const [t, e] = b0(), a = Ft();
|
|
40399
40404
|
return Dr({
|
|
@@ -40435,7 +40440,7 @@ const v2 = {
|
|
|
40435
40440
|
/* @__PURE__ */ n1.jsx("div", { className: "w-4 h-4 rounded-full bg-yellow-600 animate-bounce [animation-delay:.0s]" })
|
|
40436
40441
|
] }),
|
|
40437
40442
|
/* @__PURE__ */ n1.jsx("div", { className: "text-gray-700 font-thin", children: "Loading Builder..." })
|
|
40438
|
-
] }) }),
|
|
40443
|
+
] }) }), Bs1 = (t = "Project updated successfully.") => {
|
|
40439
40444
|
const e = b2(), a = Ft();
|
|
40440
40445
|
return k2({
|
|
40441
40446
|
mutationFn: async (r) => await v2.put(`${a}/project`, r).then((n) => n.json()),
|
|
@@ -40443,20 +40448,20 @@ const v2 = {
|
|
|
40443
40448
|
e.invalidateQueries({ queryKey: ["project"] }), ae.success(t);
|
|
40444
40449
|
}
|
|
40445
40450
|
});
|
|
40446
|
-
},
|
|
40451
|
+
}, As1 = () => {
|
|
40447
40452
|
const [t] = ["SAVED"], [e, a] = b0(), r = Uf();
|
|
40448
40453
|
return (n) => t !== "SAVED" ? (ae.error("You have unsaved changes. Please save before changing the page."), !1) : e === n.uuid ? !1 : (r(), setTimeout(() => {
|
|
40449
40454
|
a(n.uuid);
|
|
40450
40455
|
}, 100), !0);
|
|
40451
|
-
},
|
|
40452
|
-
const t = b2(), e =
|
|
40456
|
+
}, _91 = () => {
|
|
40457
|
+
const t = b2(), e = As1(), a = Ft();
|
|
40453
40458
|
return k2({
|
|
40454
40459
|
mutationFn: async (r) => v2.post(`${a}/pages`, r).then((n) => n.json()),
|
|
40455
40460
|
onSuccess: (r) => {
|
|
40456
40461
|
t.invalidateQueries({ queryKey: ["pages"] }), e({ uuid: r.uuid, slug: r.slug }), ae.success("Page added successfully.");
|
|
40457
40462
|
}
|
|
40458
40463
|
});
|
|
40459
|
-
},
|
|
40464
|
+
}, Ps1 = () => {
|
|
40460
40465
|
const t = Ft(), [e] = b0(), a = b2();
|
|
40461
40466
|
return k2({
|
|
40462
40467
|
mutationFn: async (r) => v2.put(`${t}/page`, r).then((n) => n.json()),
|
|
@@ -40469,7 +40474,7 @@ const v2 = {
|
|
|
40469
40474
|
ae.success("Page saved successfully.");
|
|
40470
40475
|
}
|
|
40471
40476
|
});
|
|
40472
|
-
},
|
|
40477
|
+
}, Es1 = () => {
|
|
40473
40478
|
const t = Ft(), { data: e } = tS(), [a] = b0(), { data: r } = $O(), n = b2();
|
|
40474
40479
|
return k2({
|
|
40475
40480
|
mutationFn: async () => {
|
|
@@ -40492,7 +40497,7 @@ const v2 = {
|
|
|
40492
40497
|
});
|
|
40493
40498
|
}
|
|
40494
40499
|
});
|
|
40495
|
-
},
|
|
40500
|
+
}, $91 = () => {
|
|
40496
40501
|
const t = b2(), e = Ft();
|
|
40497
40502
|
return k2({
|
|
40498
40503
|
mutationFn: async (a) => v2.delete(`${e}/page`, a).then((r) => r.json()),
|
|
@@ -40500,7 +40505,7 @@ const v2 = {
|
|
|
40500
40505
|
ae.success("Page deleted successfully."), t.invalidateQueries({ queryKey: ["pages"] });
|
|
40501
40506
|
}
|
|
40502
40507
|
});
|
|
40503
|
-
},
|
|
40508
|
+
}, Is1 = () => {
|
|
40504
40509
|
const t = b2(), e = Ft();
|
|
40505
40510
|
return k2({
|
|
40506
40511
|
mutationFn: async (a) => v2.post(`${e}/take-control`, { uuid: a }).then((r) => r.json()),
|
|
@@ -40508,7 +40513,7 @@ const v2 = {
|
|
|
40508
40513
|
t.invalidateQueries({ queryKey: ["page_data", r] });
|
|
40509
40514
|
}
|
|
40510
40515
|
});
|
|
40511
|
-
},
|
|
40516
|
+
}, ks1 = () => {
|
|
40512
40517
|
const t = Ft();
|
|
40513
40518
|
return k2({
|
|
40514
40519
|
mutationFn: async () => {
|
|
@@ -40519,7 +40524,7 @@ const v2 = {
|
|
|
40519
40524
|
);
|
|
40520
40525
|
}
|
|
40521
40526
|
});
|
|
40522
|
-
},
|
|
40527
|
+
}, Ns1 = () => {
|
|
40523
40528
|
const t = Ft();
|
|
40524
40529
|
return k2({
|
|
40525
40530
|
mutationFn: async (e) => {
|
|
@@ -40533,7 +40538,7 @@ const v2 = {
|
|
|
40533
40538
|
}
|
|
40534
40539
|
}
|
|
40535
40540
|
});
|
|
40536
|
-
},
|
|
40541
|
+
}, Rs1 = () => {
|
|
40537
40542
|
const t = Ft();
|
|
40538
40543
|
return k2({
|
|
40539
40544
|
mutationFn: async (e) => {
|
|
@@ -40563,7 +40568,7 @@ var aS = {
|
|
|
40563
40568
|
}
|
|
40564
40569
|
return t;
|
|
40565
40570
|
}, Se.apply(this, arguments);
|
|
40566
|
-
},
|
|
40571
|
+
}, Ts1 = function(t, e) {
|
|
40567
40572
|
var a = {};
|
|
40568
40573
|
for (var r in t)
|
|
40569
40574
|
Object.prototype.hasOwnProperty.call(t, r) && e.indexOf(r) < 0 && (a[r] = t[r]);
|
|
@@ -40581,14 +40586,14 @@ function rS(t) {
|
|
|
40581
40586
|
}
|
|
40582
40587
|
function nS(t) {
|
|
40583
40588
|
return function(e) {
|
|
40584
|
-
return p.createElement(
|
|
40589
|
+
return p.createElement(Ds1, Se({
|
|
40585
40590
|
attr: Se({}, t.attr)
|
|
40586
40591
|
}, e), rS(t.child));
|
|
40587
40592
|
};
|
|
40588
40593
|
}
|
|
40589
|
-
function
|
|
40594
|
+
function Ds1(t) {
|
|
40590
40595
|
var e = function(a) {
|
|
40591
|
-
var r = t.attr, n = t.size, l = t.title, i =
|
|
40596
|
+
var r = t.attr, n = t.size, l = t.title, i = Ts1(t, ["attr", "size", "title"]), o = n || a.size || "1em", c;
|
|
40592
40597
|
return a.className && (c = a.className), t.className && (c = (c ? c + " " : "") + t.className), p.createElement("svg", Se({
|
|
40593
40598
|
stroke: "currentColor",
|
|
40594
40599
|
fill: "currentColor",
|
|
@@ -40610,11 +40615,11 @@ function Ts1(t) {
|
|
|
40610
40615
|
function lS(t) {
|
|
40611
40616
|
return nS({ tag: "svg", attr: { viewBox: "0 0 24 24" }, child: [{ tag: "path", attr: { fill: "none", d: "M0 0h24v24H0z" } }, { tag: "path", attr: { d: "M20 4H4c-1.1 0-1.99.9-1.99 2L2 18c0 1.1.9 2 2 2h16c1.1 0 2-.9 2-2V6c0-1.1-.9-2-2-2zm0 4l-8 5-8-5V6l8 5 8-5v2z" } }] })(t);
|
|
40612
40617
|
}
|
|
40613
|
-
function
|
|
40618
|
+
function js1(t) {
|
|
40614
40619
|
return nS({ tag: "svg", attr: { viewBox: "0 0 24 24" }, child: [{ tag: "path", attr: { fill: "none", d: "M0 0h24v24H0z" } }, { tag: "path", attr: { d: "M12 12c2.21 0 4-1.79 4-4s-1.79-4-4-4-4 1.79-4 4 1.79 4 4 4zm0 2c-2.67 0-8 1.34-8 4v2h16v-2c0-2.66-5.33-4-8-4z" } }] })(t);
|
|
40615
40620
|
}
|
|
40616
|
-
const
|
|
40617
|
-
const { mutate: t, isPending: e } =
|
|
40621
|
+
const Fs1 = () => {
|
|
40622
|
+
const { mutate: t, isPending: e } = Is1(), [a] = b0(), { data: r } = eS(), n = Ac(r, "lockedBy.name", ""), l = Ac(r, "lockedBy.email", "");
|
|
40618
40623
|
return /* @__PURE__ */ n1.jsxs("div", { className: "bg-white dark:bg-gray-800 rounded-lg drop-shadow-2xl mx-auto p-10 space-y-4 text-center max-w-xl", children: [
|
|
40619
40624
|
/* @__PURE__ */ n1.jsxs("h2", { className: "text-2xl font-bold", children: [
|
|
40620
40625
|
"Page is ",
|
|
@@ -40625,7 +40630,7 @@ const js1 = () => {
|
|
|
40625
40630
|
/* @__PURE__ */ n1.jsx("br", {}),
|
|
40626
40631
|
/* @__PURE__ */ n1.jsxs("div", { className: "flex items-center gap-x-3 w-max mx-auto font-medium text-gray-700 mt-2 text-sm", children: [
|
|
40627
40632
|
/* @__PURE__ */ n1.jsxs("div", { className: "flex items-center gap-x-2 bg-gray-100 py-1 px-2 rounded-md", children: [
|
|
40628
|
-
/* @__PURE__ */ n1.jsx(
|
|
40633
|
+
/* @__PURE__ */ n1.jsx(js1, { className: "w-4 h-4 text-gray-500" }),
|
|
40629
40634
|
" ",
|
|
40630
40635
|
n
|
|
40631
40636
|
] }),
|
|
@@ -40653,7 +40658,7 @@ const js1 = () => {
|
|
|
40653
40658
|
}
|
|
40654
40659
|
)
|
|
40655
40660
|
] });
|
|
40656
|
-
},
|
|
40661
|
+
}, qs1 = () => {
|
|
40657
40662
|
const t = Ft(), e = b2();
|
|
40658
40663
|
return k2({
|
|
40659
40664
|
mutationFn: async (a) => {
|
|
@@ -40674,7 +40679,7 @@ const js1 = () => {
|
|
|
40674
40679
|
ae.error("Invalid login credentials. Please try again.", { position: "top-center" });
|
|
40675
40680
|
}
|
|
40676
40681
|
});
|
|
40677
|
-
},
|
|
40682
|
+
}, Ws1 = () => {
|
|
40678
40683
|
const t = Ft();
|
|
40679
40684
|
return Dr({
|
|
40680
40685
|
queryKey: ["verify"],
|
|
@@ -40683,7 +40688,7 @@ const js1 = () => {
|
|
|
40683
40688
|
return e.ok ? (await e.json()).result === "success" ? { valid: !0 } : (localStorage.removeItem("__chai_at"), { valid: !1 }) : (localStorage.removeItem("__chai_at"), { valid: !0 });
|
|
40684
40689
|
}
|
|
40685
40690
|
});
|
|
40686
|
-
},
|
|
40691
|
+
}, Ks1 = () => {
|
|
40687
40692
|
const t = Ft(), e = b2();
|
|
40688
40693
|
return k2({
|
|
40689
40694
|
mutationFn: async () => {
|
|
@@ -40693,8 +40698,8 @@ const js1 = () => {
|
|
|
40693
40698
|
throw new Error("Invalid session");
|
|
40694
40699
|
}
|
|
40695
40700
|
});
|
|
40696
|
-
},
|
|
40697
|
-
const e =
|
|
40701
|
+
}, Us1 = ({ children: t }) => {
|
|
40702
|
+
const e = Ks1();
|
|
40698
40703
|
return /* @__PURE__ */ n1.jsxs(AS, { children: [
|
|
40699
40704
|
/* @__PURE__ */ n1.jsx(PS, { asChild: !0, children: t }),
|
|
40700
40705
|
/* @__PURE__ */ n1.jsxs(ES, { children: [
|
|
@@ -40723,11 +40728,11 @@ const js1 = () => {
|
|
|
40723
40728
|
] })
|
|
40724
40729
|
] })
|
|
40725
40730
|
] });
|
|
40726
|
-
},
|
|
40727
|
-
const { mutate: t } =
|
|
40731
|
+
}, Zs1 = () => /* @__PURE__ */ n1.jsx(Us1, { children: /* @__PURE__ */ n1.jsx("button", { className: "border-gray-200 rounded-md p-2 mb-2 border", children: /* @__PURE__ */ n1.jsx(zC, { className: "w-4 h-4 text-red-500 cursor-pointer hover:text-red-300 duration-300" }) }) }), Gs1 = v0(() => import("./PagesPanel-uMZT46fo.js")), Js1 = v0(() => import("./ProjectPanel-nhhdOgSP.js")), Ys1 = v0(() => import("./CurrentPage-2Hqp8dwp.js")), Qs1 = () => /* @__PURE__ */ n1.jsx("h2", { children: "Your Logo" }), Xs1 = () => {
|
|
40732
|
+
const { mutate: t } = Es1();
|
|
40728
40733
|
return J4("editable", !0) ? /* @__PURE__ */ n1.jsx(S3, { onClick: t, className: "bg-blue-600 text-white", children: "Publish" }) : null;
|
|
40729
|
-
},
|
|
40730
|
-
const { data: e, isLoading: a } = $O(), { data: r, isLoading: n } = tS(), { data: l } = eS(), { mutate: i } =
|
|
40734
|
+
}, _s1 = (t) => {
|
|
40735
|
+
const { data: e, isLoading: a } = $O(), { data: r, isLoading: n } = tS(), { data: l } = eS(), { mutate: i } = Bs1(), { mutate: o } = Ps1(), [c] = b0(), v = Rs1(), h = ks1(), s = Ns1(), d = Ft(), u = D1(
|
|
40731
40736
|
async (m) => await v.mutateAsync(m),
|
|
40732
40737
|
[v]
|
|
40733
40738
|
), f = D1(async () => await h.mutateAsync(), [h]), g = D1(
|
|
@@ -40736,12 +40741,12 @@ const js1 = () => {
|
|
|
40736
40741
|
), z = async (m = 20, V = 0) => {
|
|
40737
40742
|
const b = `limit=${m}&offset=${V}`;
|
|
40738
40743
|
return await fetch(`${d}/assets?${b}`).then((w) => w.json());
|
|
40739
|
-
}, { logo: M =
|
|
40744
|
+
}, { logo: M = Qs1 } = t;
|
|
40740
40745
|
return a || !e ? /* @__PURE__ */ n1.jsx(x3, {}) : n || !r ? /* @__PURE__ */ n1.jsx(x3, {}) : /* @__PURE__ */ n1.jsx("div", { className: "bg-background text-foreground", children: /* @__PURE__ */ n1.jsx(
|
|
40741
|
-
|
|
40746
|
+
Gh1,
|
|
40742
40747
|
{
|
|
40743
40748
|
editable: l != null && l.lockedBy ? l == null ? void 0 : l.lockedBy.self : !0,
|
|
40744
|
-
nonEditableComponent:
|
|
40749
|
+
nonEditableComponent: Fs1,
|
|
40745
40750
|
blocks: (l == null ? void 0 : l.blocks) || [],
|
|
40746
40751
|
brandingOptions: e.brandingOptions,
|
|
40747
40752
|
darkMode: t.darkMode || !1,
|
|
@@ -40750,15 +40755,15 @@ const js1 = () => {
|
|
|
40750
40755
|
onSaveBrandingOptions: async (m) => (await i({ brandingOptions: m }), !0),
|
|
40751
40756
|
topBarComponents: {
|
|
40752
40757
|
left: [M],
|
|
40753
|
-
center: [
|
|
40754
|
-
right: [
|
|
40758
|
+
center: [Ys1],
|
|
40759
|
+
right: [Xs1]
|
|
40755
40760
|
},
|
|
40756
40761
|
sideBarComponents: {
|
|
40757
40762
|
top: [
|
|
40758
|
-
{ icon: sC, name: "pages", panel:
|
|
40759
|
-
{ icon: vC, name: "settings", panel:
|
|
40763
|
+
{ icon: sC, name: "pages", panel: Gs1 },
|
|
40764
|
+
{ icon: vC, name: "settings", panel: Js1 }
|
|
40760
40765
|
],
|
|
40761
|
-
bottom: [
|
|
40766
|
+
bottom: [Zs1]
|
|
40762
40767
|
},
|
|
40763
40768
|
uploadMediaCallback: u,
|
|
40764
40769
|
fetchMediaCallback: z,
|
|
@@ -40768,8 +40773,8 @@ const js1 = () => {
|
|
|
40768
40773
|
unsplashAccessKey: t.unsplashAccessKey || ""
|
|
40769
40774
|
}
|
|
40770
40775
|
) });
|
|
40771
|
-
},
|
|
40772
|
-
const [e, a] = g1(!1), [r, n] = g1(""), [l, i] = g1(""), { mutate: o, isPending: c } =
|
|
40776
|
+
}, $s1 = ({ logo: t }) => {
|
|
40777
|
+
const [e, a] = g1(!1), [r, n] = g1(""), [l, i] = g1(""), { mutate: o, isPending: c } = qs1(), v = (h) => {
|
|
40773
40778
|
h.preventDefault(), o({ email: r, password: l });
|
|
40774
40779
|
};
|
|
40775
40780
|
return /* @__PURE__ */ n1.jsx("section", { className: "h-screen w-screen flex items-center justify-center bg-[radial-gradient(#AAA,transparent_0.5px)] duration-300 [background-size:6px_6px]", children: /* @__PURE__ */ n1.jsx("div", { className: "overflow-hidden bg-white rounded-xl w-96 drop-shadow-2xl duration-300", children: /* @__PURE__ */ n1.jsxs("div", { className: "p-12", children: [
|
|
@@ -40853,30 +40858,30 @@ const js1 = () => {
|
|
|
40853
40858
|
}
|
|
40854
40859
|
) })
|
|
40855
40860
|
] }) }) });
|
|
40856
|
-
},
|
|
40857
|
-
const { data: e, isLoading: a } =
|
|
40861
|
+
}, t91 = (t) => {
|
|
40862
|
+
const { data: e, isLoading: a } = Ws1(), r = b2();
|
|
40858
40863
|
return L1(() => {
|
|
40859
40864
|
r.setQueryData(["apiBaseUrl"], t.apiBaseUrl || "/api/chaibuilder");
|
|
40860
|
-
}, [t.apiBaseUrl, r]), a ? /* @__PURE__ */ n1.jsx(x3, {}) : e != null && e.valid ? /* @__PURE__ */ n1.jsx(
|
|
40861
|
-
},
|
|
40865
|
+
}, [t.apiBaseUrl, r]), a ? /* @__PURE__ */ n1.jsx(x3, {}) : e != null && e.valid ? /* @__PURE__ */ n1.jsx(_s1, { ...t }) : /* @__PURE__ */ n1.jsx($s1, { logo: t.logo });
|
|
40866
|
+
}, e91 = new cs1(), tv1 = (t) => /* @__PURE__ */ n1.jsxs(us1, { client: e91, children: [
|
|
40862
40867
|
/* @__PURE__ */ n1.jsx(gC, { richColors: !0 }),
|
|
40863
|
-
/* @__PURE__ */ n1.jsx(
|
|
40868
|
+
/* @__PURE__ */ n1.jsx(t91, { ...t })
|
|
40864
40869
|
] });
|
|
40865
40870
|
export {
|
|
40866
|
-
|
|
40867
|
-
|
|
40868
|
-
|
|
40871
|
+
Y91 as B,
|
|
40872
|
+
tv1 as C,
|
|
40873
|
+
Ph1 as E,
|
|
40869
40874
|
tS as a,
|
|
40870
40875
|
$O as b,
|
|
40871
|
-
|
|
40872
|
-
|
|
40876
|
+
Bs1 as c,
|
|
40877
|
+
As1 as d,
|
|
40873
40878
|
b0 as e,
|
|
40874
|
-
|
|
40875
|
-
|
|
40879
|
+
J91 as f,
|
|
40880
|
+
_91 as g,
|
|
40876
40881
|
b2 as h,
|
|
40877
|
-
|
|
40878
|
-
|
|
40879
|
-
|
|
40882
|
+
Ps1 as i,
|
|
40883
|
+
$91 as j,
|
|
40884
|
+
Gh1 as k,
|
|
40880
40885
|
zB as r,
|
|
40881
|
-
|
|
40886
|
+
Rh1 as u
|
|
40882
40887
|
};
|