@chaibuilder/sdk 4.0.0-beta.3 → 4.0.0-beta.6
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/{2SSKDMRQ-BnsZi3K3.cjs → 2SSKDMRQ-BIryEtW-.cjs} +1 -1
- package/dist/{2SSKDMRQ-CnSDkQcy.js → 2SSKDMRQ-trME0kvt.js} +2 -2
- package/dist/{AP7HFJJL-B31839PG.cjs → AP7HFJJL-5ZR38Hyh.cjs} +1 -1
- package/dist/{AP7HFJJL-CymCmW14.js → AP7HFJJL-CAGB9iMp.js} +1 -1
- package/dist/IconPicker-CQ-BgNNU.cjs +1 -0
- package/dist/{IconPicker-B1rWC-Ex.js → IconPicker-Mu75ni5T.js} +8 -7
- package/dist/{WDYDFRGG-BUVnbAci.js → WDYDFRGG-Cd4hRWj-.js} +2 -2
- package/dist/{WDYDFRGG-BxhOCHc3.cjs → WDYDFRGG-n8sBZVFG.cjs} +1 -1
- package/dist/{actions-registery-YnFmU21O.cjs → actions-registery-JdxhXhT6.cjs} +1 -1
- package/dist/{actions-registery-CZ1w0NKa.js → actions-registery-y_ENc8zj.js} +2 -2
- package/dist/actions.cjs +1 -1
- package/dist/actions.js +2 -2
- package/dist/active-in-another-tab-CZLV-uAW.cjs +1 -0
- package/dist/active-in-another-tab-Cb6tnX9u.js +35 -0
- package/dist/{add-new-language-page-WmlCnytQ.js → add-new-language-page-BKcBaqZu.js} +54 -53
- package/dist/add-new-language-page-C3UzNV7W.cjs +1 -0
- package/dist/{add-new-page-soZ8GAkN.cjs → add-new-page-mULv9r3z.cjs} +1 -1
- package/dist/{add-new-page-VW2wAYZp.js → add-new-page-pH3PwqJe.js} +2 -2
- package/dist/ai-panel-content-BPgRdgye.cjs +1 -0
- package/dist/{ai-panel-content-D_o7Q_A-.js → ai-panel-content-CNxN84pv.js} +12 -11
- package/dist/{ai-panel-default-lang-DnElspF0.js → ai-panel-default-lang-CYcHjk8U.js} +40 -40
- package/dist/{ai-panel-default-lang-COYaxNwn.cjs → ai-panel-default-lang-DhTPtPgD.cjs} +2 -2
- package/dist/{ai-panel-other-lang-CkynNlAU.cjs → ai-panel-other-lang-CGNU3-FI.cjs} +1 -1
- package/dist/{ai-panel-other-lang-Dp0E9_Hx.js → ai-panel-other-lang-D8Ofvj8F.js} +8 -8
- package/dist/ai-prompt-input-CUutJjlf.cjs +1 -0
- package/dist/{ai-prompt-input-Bhc0ds7X.js → ai-prompt-input-Ceuy5bs3.js} +68 -67
- package/dist/{ai-translation-prompt-CZ55HQmo.js → ai-translation-prompt-BiepZRcN.js} +2 -2
- package/dist/ai-translation-prompt-CoCPLEed.cjs +1 -0
- package/dist/{apply-binding-6iwlED02.js → apply-binding-BvWfJCSZ.js} +204 -196
- package/dist/apply-binding-IsUf6UWJ.cjs +1 -0
- package/dist/{code-display-DhD_RBcg.js → code-display-Ck81Id9K.js} +1 -1
- package/dist/code-display-DloSPyPr.cjs +1 -0
- package/dist/code-editor-C1ewJzDJ.cjs +1 -0
- package/dist/{code-editor-DRIAnNbb.js → code-editor-Z14ByBIv.js} +11 -10
- package/dist/{continue-editing-in-this-client-CS2aQ7yY.js → continue-editing-in-this-client-Byi6ER3L.js} +10 -9
- package/dist/continue-editing-in-this-client-k9Ab5E63.cjs +1 -0
- package/dist/core-Dr7QYemB.js +56 -0
- package/dist/core-Y0lXLwkq.cjs +1 -0
- package/dist/core.cjs +1 -1
- package/dist/core.d.ts +3 -3
- package/dist/core.js +32 -31
- package/dist/css-import-modal--bSJR-_y.cjs +13 -0
- package/dist/{css-import-modal-Byg6wV0O.js → css-import-modal-De7Kvg5C.js} +4 -3
- package/dist/{delete-design-token-BRZZiWtQ.js → delete-design-token-B97CnFDU.js} +1 -1
- package/dist/{delete-design-token-DkVs1oBf.cjs → delete-design-token-C6s-ESB_.cjs} +1 -1
- package/dist/delete-page-Djn97HiP.cjs +1 -0
- package/dist/{delete-page-BzyX9TN-.js → delete-page-Dnf97ZHP.js} +11 -10
- package/dist/{design-token-usage-xQs6SlaJ.js → design-token-usage-B-SykAjD.js} +14 -13
- package/dist/design-token-usage-OTd93kS8.cjs +1 -0
- package/dist/digital-asset-manager-DHYRXaaq.cjs +1 -0
- package/dist/{digital-asset-manager-DbtwzxRz.js → digital-asset-manager-b8gDuLnI.js} +6 -5
- package/dist/{duplicate-page-BR7Dlo9d.js → duplicate-page-Bdtpl7_R.js} +19 -18
- package/dist/duplicate-page-C4Ovp8Ff.cjs +1 -0
- package/dist/dynamic-page-selector-B8DdnfrF.cjs +1 -0
- package/dist/{dynamic-page-selector-Cb5r_W8s.js → dynamic-page-selector-BVnIM1Rq.js} +15 -14
- package/dist/get-chai-builder-tailwind-config-DNp8Vhme.cjs +1 -0
- package/dist/{get-chai-builder-tailwind-config-DjoVOuAf.js → get-chai-builder-tailwind-config-k8l5sdcw.js} +5 -5
- package/dist/{get-chai-builder-theme-Dl72X7cz.cjs → get-chai-builder-theme-BApShjRz.cjs} +1 -1
- package/dist/{get-chai-builder-theme-BYtp20KD.js → get-chai-builder-theme-DDVRJQ6Z.js} +1 -1
- package/dist/{image-editor-G-K28aTS.cjs → image-editor-C2zOHeKv.cjs} +1 -1
- package/dist/{image-editor-DV8kUKhl.js → image-editor-cckqPmk5.js} +1 -1
- package/dist/index-B0e71wJ1.cjs +160 -0
- package/dist/{index-ZuacEL1j.js → index-Bn0fFN58.js} +665 -663
- package/dist/{index-Ct7ElCGK.js → index-CAhEmHYP.js} +3744 -3920
- package/dist/index-DKuwxj1x.cjs +5 -0
- package/dist/{json-diff-viewer-D7z4zNvv.cjs → json-diff-viewer-D9DVIBz4.cjs} +3 -3
- package/dist/{json-diff-viewer-krslPepD.js → json-diff-viewer-DNizzMnu.js} +5 -4
- package/dist/lang-panel-C1dbn163.cjs +1 -0
- package/dist/{lang-panel-BwIewMyw.js → lang-panel-DL_BtSRD.js} +15 -14
- package/dist/manage-design-tokens-CXjYkarE.cjs +1 -0
- package/dist/{manage-design-tokens-Caz_20VK.js → manage-design-tokens-xxMO_RYg.js} +12 -11
- package/dist/{mark-as-template-D295ZQtU.js → mark-as-template-Ba2bmVd9.js} +17 -16
- package/dist/mark-as-template-DF1KIMr0.cjs +1 -0
- package/dist/{nested-path-selector-content-CKYYK-C5.js → nested-path-selector-content-Br1IWhK5.js} +24 -23
- package/dist/nested-path-selector-content-Cuk7NB-u.cjs +1 -0
- package/dist/{no-language-page-content-BvqRBP6y.js → no-language-page-content-9B2Fm-on.js} +10 -9
- package/dist/no-language-page-content-CxTp-LIM.cjs +1 -0
- package/dist/{no-language-page-dialog-PjNqTUpl.js → no-language-page-dialog-CPlKMyb8.js} +2 -2
- package/dist/{no-language-page-dialog-BcEoqyQB.cjs → no-language-page-dialog-DynACvgV.cjs} +1 -1
- package/dist/{page-creator-DiOITEMw.js → page-creator-BtyJz2sx.js} +115 -114
- package/dist/page-creator-Cbfv9N0P.cjs +1 -0
- package/dist/{page-lock-Bfbs6RgL.js → page-lock-CzsxrmN5.js} +2 -2
- package/dist/{page-lock-BdYmCks0.cjs → page-lock-fRos9wRU.cjs} +1 -1
- package/dist/{page-locked-dialog-B6MKTRfY.js → page-locked-dialog-D2q9qkPk.js} +18 -15
- package/dist/page-locked-dialog-D57d2gvn.cjs +1 -0
- package/dist/{page-manager-new-CzX22g2n.js → page-manager-new-D6DVIx2S.js} +30 -29
- package/dist/page-manager-new-aE198gKS.cjs +1 -0
- package/dist/{page-manager-search-and-filter-CM0UMb6U.js → page-manager-search-and-filter-CuZkQaZg.js} +13 -12
- package/dist/page-manager-search-and-filter-DGQEgKzy.cjs +1 -0
- package/dist/{page-revisions-content-NH9JK4Ey.js → page-revisions-content-5rbicFbD.js} +34 -31
- package/dist/page-revisions-content-CefqOvKX.cjs +1 -0
- package/dist/pages.cjs +1 -1
- package/dist/pages.d.ts +4 -4
- package/dist/pages.js +1 -1
- package/dist/{plugin-C6rgJDNQ.cjs → plugin-BGlQf0iy.cjs} +1 -1
- package/dist/{plugin-3ZKK6RXm.js → plugin-C-ht41UZ.js} +1 -1
- package/dist/publish-pages-content-DBb8M3TG.cjs +1 -0
- package/dist/{publish-pages-content-D9aixMN5.js → publish-pages-content-WeGk-YLC.js} +66 -65
- package/dist/register-chai-top-bar-BqwKw4uy.cjs +1 -0
- package/dist/register-chai-top-bar-ESJHs5s-.js +237 -0
- package/dist/render.cjs +2 -2
- package/dist/render.d.ts +2 -2
- package/dist/render.js +87 -80
- package/dist/rte-widget-modal-DBoPRXq-.cjs +1 -0
- package/dist/{rte-widget-modal-DOJEXLIf.js → rte-widget-modal-J-_AytmK.js} +15 -14
- package/dist/runtime.cjs +1 -1
- package/dist/runtime.d.ts +168 -4
- package/dist/runtime.js +68 -38
- package/dist/save-to-lib-0ysmXVbI.cjs +1 -0
- package/dist/{save-to-lib-eiOc_SSN.js → save-to-lib-CQQxoovF.js} +39 -38
- package/dist/sdk.css +1 -1
- package/dist/selected-block-display-BWupQFoQ.cjs +16 -0
- package/dist/{selected-block-display-CBFePS19.js → selected-block-display-CgoXS8Hr.js} +37 -36
- package/dist/{seo-panel-C1-iMOR1.js → seo-panel-B798Myp_.js} +12 -11
- package/dist/seo-panel-BkFbXIL0.cjs +2 -0
- package/dist/{shared-json-ld-B4PxAM_0.js → shared-json-ld-Clg_UEhd.js} +68 -67
- package/dist/shared-json-ld-Cn3MCW6I.cjs +1 -0
- package/dist/slug-input-BHyD8cxk.cjs +1 -0
- package/dist/{slug-input-AwNJs9im.js → slug-input-hX5VaZpj.js} +9 -8
- package/dist/supabase-actions.cjs +1 -1
- package/dist/supabase-actions.d.ts +1 -1
- package/dist/supabase-actions.js +1 -1
- package/dist/take-over-request-Dzczo20q.cjs +1 -0
- package/dist/{take-over-request-C4FeDtN_.js → take-over-request-s1L5Yofb.js} +17 -16
- package/dist/theme-panel-footer-NTNCL0SW.cjs +1 -0
- package/dist/{theme-panel-footer-uBQqSJXm.js → theme-panel-footer-sK6bYhEb.js} +11 -10
- package/dist/translation-warning-modal-BfM4HGck.cjs +1 -0
- package/dist/{translation-warning-modal-B64YqlbI.js → translation-warning-modal-Jadkcver.js} +9 -8
- package/dist/unmark-as-template-CqkHI3gR.cjs +1 -0
- package/dist/{unmark-as-template-CZ9sQp_P.js → unmark-as-template-D5b775eR.js} +11 -10
- package/dist/unpublish-page-BT5bCfs6.cjs +1 -0
- package/dist/unpublish-page-DLLLgY43.js +28 -0
- package/dist/utils.cjs +1 -1
- package/dist/utils.d.ts +3 -0
- package/dist/utils.js +2 -2
- package/dist/web-blocks.cjs +1 -1
- package/dist/web-blocks.js +5 -5
- package/dist/{web-preview-Djy6WIyj.js → web-preview-C_yFwxEe.js} +2 -2
- package/dist/web-preview-DU1MgppY.cjs +1 -0
- package/package.json +4 -2
- package/dist/IconPicker-DREyo007.cjs +0 -1
- package/dist/active-in-another-tab-B47YjQGN.cjs +0 -1
- package/dist/active-in-another-tab-CyjngVA6.js +0 -34
- package/dist/add-new-language-page-88xzrUy8.cjs +0 -1
- package/dist/ai-panel-content-7zCil042.cjs +0 -1
- package/dist/ai-prompt-input-CThbVp0_.cjs +0 -1
- package/dist/ai-translation-prompt-C2kJQFDX.cjs +0 -1
- package/dist/apply-binding-KKp5PnpZ.cjs +0 -1
- package/dist/code-display-BnqzqzoP.cjs +0 -1
- package/dist/code-editor-o3___nu2.cjs +0 -1
- package/dist/continue-editing-in-this-client-CtMYsk-A.cjs +0 -1
- package/dist/core-BoRDjj4h.cjs +0 -1
- package/dist/core-yvI6kCyw.js +0 -56
- package/dist/css-import-modal-CyqkXWCO.cjs +0 -13
- package/dist/delete-page-DxX7PFIE.cjs +0 -1
- package/dist/design-token-usage-CAHzEGgJ.cjs +0 -1
- package/dist/digital-asset-manager--uO8Agia.cjs +0 -1
- package/dist/duplicate-page-CaNAbXwV.cjs +0 -1
- package/dist/dynamic-page-selector-Cxk_gjni.cjs +0 -1
- package/dist/get-chai-builder-tailwind-config-B9rCyiQo.cjs +0 -1
- package/dist/index-DF5DEvqb.cjs +0 -160
- package/dist/index-WQwzsC7A.cjs +0 -5
- package/dist/lang-panel-DT96k1xg.cjs +0 -1
- package/dist/manage-design-tokens-CrmLe7UT.cjs +0 -1
- package/dist/mark-as-template-W3LmpiqN.cjs +0 -1
- package/dist/nested-path-selector-content-CoS_d3dc.cjs +0 -1
- package/dist/no-language-page-content-DkfeMl90.cjs +0 -1
- package/dist/page-creator-C4gc5NSC.cjs +0 -1
- package/dist/page-locked-dialog-B1FAtK92.cjs +0 -1
- package/dist/page-manager-new-CHDueBDk.cjs +0 -1
- package/dist/page-manager-search-and-filter-DkkRIH86.cjs +0 -1
- package/dist/page-revisions-content-ChY-4f2V.cjs +0 -1
- package/dist/publish-pages-content-x-JuSFJ9.cjs +0 -1
- package/dist/rte-widget-modal-BaHIuEjF.cjs +0 -1
- package/dist/save-to-lib-Cgpxw8-g.cjs +0 -1
- package/dist/selected-block-display-BgRY82CT.cjs +0 -16
- package/dist/seo-panel-DfAb8U7W.cjs +0 -2
- package/dist/shared-json-ld-DzG398hr.cjs +0 -1
- package/dist/slug-input-C_ijLQ_X.cjs +0 -1
- package/dist/take-over-request-BNxcjY2j.cjs +0 -1
- package/dist/theme-panel-footer-Cq9pljro.cjs +0 -1
- package/dist/translation-warning-modal-BZAcwM2_.cjs +0 -1
- package/dist/unmark-as-template-EVvk0vmp.cjs +0 -1
- package/dist/unpublish-page-D4VwOlxc.js +0 -27
- package/dist/unpublish-page-bdSmwAVQ.cjs +0 -1
- package/dist/web-preview-Cio70gk5.cjs +0 -1
|
@@ -4,20 +4,21 @@ var Qn = (e) => {
|
|
|
4
4
|
var zn = (e, t, n) => t.has(e) || Qn("Cannot " + n);
|
|
5
5
|
var A = (e, t, n) => (zn(e, t, "read from private field"), n ? n.call(e) : t.get(e)), O = (e, t, n) => t.has(e) ? Qn("Cannot add the same private member more than once") : t instanceof WeakSet ? t.add(e) : t.set(e, n), C = (e, t, n, s) => (zn(e, t, "write to private field"), s ? s.call(e, n) : t.set(e, n), n);
|
|
6
6
|
import { jsxs as m, jsx as c, Fragment as he } from "react/jsx-runtime";
|
|
7
|
-
import { n as Pe,
|
|
8
|
-
import {
|
|
9
|
-
import {
|
|
7
|
+
import { n as Pe, aj as Ur, ai as Ss, r as Ln, s as Cn, t as Gn, v as ce, Q as Re, w as en, x as tn, y as nn, aB as _s, aC as Ps, a9 as Mr, aa as Br, aD as Fr, aE as Kr, ar as ws, aF as Vr, ab as Dt, D as vs, aG as Hr, aH as qr, aw as $r, av as Qr, ax as zr, E as Wr, F as jr, G as Yr, H as Jr, I as Zr, J as Xr, K as ea, M as ta, O as na, aI as sa, a6 as ra, a7 as aa, d as ia, e as oa, f as la, as as ca, at as ua, au as cn, aJ as un, T as Wn } from "./index-CAhEmHYP.js";
|
|
8
|
+
import { B as M, h as da, j as fa, v as kt, e as jn, m as ha, q as ga, x as ma, D as Ea, F as pa } from "./register-chai-top-bar-ESJHs5s-.js";
|
|
9
|
+
import { atom as Ee, useAtom as pe, useSetAtom as On, useAtomValue as ya } from "jotai";
|
|
10
|
+
import { get as H, reverse as Aa, sortBy as Ta, find as ie, noop as bs, minBy as Is, values as Ns, first as Ls, groupBy as Sa, keyBy as _a, map as qt, isEmpty as fe, compact as Cs, each as Pa, upperCase as Yn, filter as Gs, includes as wa, has as sn, pickBy as va, pick as xn, endsWith as ba, keys as Ia, isArray as Na, startCase as La, isFunction as Ca, cloneDeep as Ga, isEqual as Jn } from "lodash-es";
|
|
10
11
|
import * as $ from "react";
|
|
11
|
-
import
|
|
12
|
-
import { useQuery as re, useMutation as Y, useQueryClient as J, onlineManager as
|
|
13
|
-
import { CopyPlusIcon as
|
|
12
|
+
import Oa, { useMemo as q, useCallback as z, useState as K, useEffect as se, useRef as Ie, Suspense as X, lazy as V, startTransition as Zn } from "react";
|
|
13
|
+
import { useQuery as re, useMutation as Y, useQueryClient as J, onlineManager as Os, QueryClient as xa, QueryClientProvider as Da } from "@tanstack/react-query";
|
|
14
|
+
import { CopyPlusIcon as ka, Pencil as Ra, Power as Ua, Trash as Ma, SquareLibrary as Xn, LogsIcon as Ba, Folder as Fa, Loader as $t, Hash as Ka, File as Va, MoreHorizontal as es, Languages as ts, ChevronDown as yn, Star as Ha, Plus as xs, History as qa, Palette as $a, Play as Qa, CheckCircle as za, Save as Wa, Send as ns, Rocket as ss, ExternalLink as ja, LanguagesIcon as Ya, User as Ja, X as rs, Trash2 as Za, ImageIcon as as, Code as Xa, Eye as ei, Share2 as ti, FileCode2 as ni, AlertTriangle as si } from "lucide-react";
|
|
14
15
|
import { useTranslation as we } from "react-i18next";
|
|
15
16
|
import { c as Qt } from "./common-functions-D2lMFR6K.js";
|
|
16
17
|
import { toast as R } from "sonner";
|
|
17
|
-
import { j as
|
|
18
|
-
import { g as
|
|
19
|
-
import { loadWebBlocks as
|
|
20
|
-
import { ErrorBoundary as
|
|
18
|
+
import { j as ri, b as ai } from "./core-Dr7QYemB.js";
|
|
19
|
+
import { g as ii } from "./apply-binding-BvWfJCSZ.js";
|
|
20
|
+
import { loadWebBlocks as oi } from "./web-blocks.js";
|
|
21
|
+
import { ErrorBoundary as li } from "react-error-boundary";
|
|
21
22
|
const zt = Ee(null), E = {
|
|
22
23
|
GET_GLOBAL_JSONLD_ITEMS: "GET_GLOBAL_JSONLD_ITEMS",
|
|
23
24
|
GENERATE_SEO_FIELD: "GENERATE_SEO_FIELD",
|
|
@@ -82,17 +83,17 @@ const zt = Ee(null), E = {
|
|
|
82
83
|
UPDATE_ASSET: "UPDATE_ASSET",
|
|
83
84
|
GET_ASSETS: "GET_ASSETS",
|
|
84
85
|
GET_ASSET: "GET_ASSET"
|
|
85
|
-
},
|
|
86
|
+
}, ci = Ee({}), Dn = () => pe(ci), ge = (e, t) => {
|
|
86
87
|
const [n] = Dn();
|
|
87
88
|
return q(() => H(n, e, t), [n, e, t]);
|
|
88
|
-
}, b = () => ge("apiUrl", "/chai/api"),
|
|
89
|
+
}, b = () => ge("apiUrl", "/chai/api"), Ds = () => ge("websocket", null), ui = async (e, t, n = {}) => await fetch(e, {
|
|
89
90
|
method: "POST",
|
|
90
91
|
headers: {
|
|
91
92
|
"Content-Type": "application/json",
|
|
92
93
|
...n
|
|
93
94
|
},
|
|
94
95
|
body: JSON.stringify(t)
|
|
95
|
-
}),
|
|
96
|
+
}), jc = () => {
|
|
96
97
|
const e = I(), t = b();
|
|
97
98
|
return z(
|
|
98
99
|
async ({
|
|
@@ -109,7 +110,7 @@ const zt = Ee(null), E = {
|
|
|
109
110
|
async (s = n, r, a = {}, i = !1) => {
|
|
110
111
|
const o = await t();
|
|
111
112
|
try {
|
|
112
|
-
const l = H(r, "action", "").toLowerCase(), f = await
|
|
113
|
+
const l = H(r, "action", "").toLowerCase(), f = await ui(s + (l ? `?action=${l}` : ""), r, {
|
|
113
114
|
...a,
|
|
114
115
|
Authorization: `Bearer ${o}`
|
|
115
116
|
});
|
|
@@ -160,22 +161,22 @@ const Me = (e) => {
|
|
|
160
161
|
action: E.GET_LANGUAGE_PAGES,
|
|
161
162
|
data: { id: s }
|
|
162
163
|
});
|
|
163
|
-
return
|
|
164
|
+
return Aa(Ta(a, "primaryPage"));
|
|
164
165
|
},
|
|
165
166
|
enabled: !!s
|
|
166
167
|
});
|
|
167
|
-
},
|
|
168
|
-
const [e] =
|
|
168
|
+
}, di = Ee(null), ks = () => pe(di), kn = () => {
|
|
169
|
+
const [e] = ks();
|
|
169
170
|
return (e == null ? void 0 : e.slug) || "";
|
|
170
171
|
};
|
|
171
|
-
function
|
|
172
|
+
function fi(e, t) {
|
|
172
173
|
const [n, s] = K(e);
|
|
173
174
|
return se(() => {
|
|
174
175
|
const r = setTimeout(() => s(e), t);
|
|
175
176
|
return () => clearTimeout(r);
|
|
176
177
|
}, [e, t]), n;
|
|
177
178
|
}
|
|
178
|
-
const
|
|
179
|
+
const hi = ({ query: e, uuid: t }) => {
|
|
179
180
|
const { selectedLang: n, fallbackLang: s } = Pe(), { data: r } = oe(), a = r == null ? void 0 : r.pageType, i = b(), o = I(), { data: l, isFetching: f } = re({
|
|
180
181
|
queryKey: [E.GET_DYNAMIC_PAGES, e, a, t],
|
|
181
182
|
staleTime: 3600 * 1e3,
|
|
@@ -187,8 +188,8 @@ const fi = ({ query: e, uuid: t }) => {
|
|
|
187
188
|
enabled: !!a
|
|
188
189
|
}), d = q(() => n === "" ? l.filter((u) => u.lang === "" || u.lang === s) : l.filter((u) => u.lang === n), [n, s, l]);
|
|
189
190
|
return { allLangPages: l, data: d, isFetching: f };
|
|
190
|
-
},
|
|
191
|
-
const { selectedLang: e, fallbackLang: t } = Pe(), [n, s] =
|
|
191
|
+
}, gi = () => {
|
|
192
|
+
const { selectedLang: e, fallbackLang: t } = Pe(), [n, s] = ks(), [r, a] = K(""), i = fi(r, 500), { allLangPages: o, data: l, isFetching: f } = hi({ query: i }), d = z((h) => s(h), [s]), u = z((h) => a(h), [a]), g = z(() => {
|
|
192
193
|
if (!n) return;
|
|
193
194
|
const h = !(n != null && n.primaryPage), p = e.length === 0, T = h ? n == null ? void 0 : n.id : n == null ? void 0 : n.primaryPage, x = o.filter(
|
|
194
195
|
(y) => (y == null ? void 0 : y.primaryPage) === T || y.id === T
|
|
@@ -206,17 +207,17 @@ const fi = ({ query: e, uuid: t }) => {
|
|
|
206
207
|
updateSearchQuery: u,
|
|
207
208
|
onChangeLanguage: g
|
|
208
209
|
};
|
|
209
|
-
},
|
|
210
|
+
}, mi = Ee({ lastSaved: void 0 }), Rs = () => pe(mi), oe = () => {
|
|
210
211
|
const [e] = ve(), t = e.get("page"), { data: n, isFetching: s } = Me();
|
|
211
212
|
return { data: q(() => ({ ...ie(n, { id: t }) || {} }), [n, t]), isFetching: s };
|
|
212
213
|
}, Le = () => {
|
|
213
214
|
const [e] = ve(), t = e.get("lang") ?? "", { data: n, isFetching: s } = Me();
|
|
214
215
|
return { data: q(() => ie(n, { lang: t }) || {}, [n, t]), isFetching: s };
|
|
215
|
-
},
|
|
216
|
-
const { data: e } = Le(), t = kn(), n = ge("getLiveUrl",
|
|
216
|
+
}, Ei = Ee({}), pi = () => pe(Ei), yi = () => {
|
|
217
|
+
const { data: e } = Le(), t = kn(), n = ge("getLiveUrl", bs), s = e == null ? void 0 : e.slug, r = n(s || "/");
|
|
217
218
|
return t ? r + t : r;
|
|
218
219
|
}, le = {
|
|
219
|
-
...
|
|
220
|
+
...Ur,
|
|
220
221
|
//pages
|
|
221
222
|
ADD_PAGE: "add_page",
|
|
222
223
|
EDIT_PAGE: "edit_page",
|
|
@@ -239,10 +240,10 @@ const fi = ({ query: e, uuid: t }) => {
|
|
|
239
240
|
placeholderData: [],
|
|
240
241
|
queryFn: async () => t(e, { action: E.GET_PAGE_TYPES })
|
|
241
242
|
});
|
|
242
|
-
},
|
|
243
|
+
}, Ai = (e) => {
|
|
243
244
|
const { data: t } = Ce();
|
|
244
245
|
return q(() => t == null ? void 0 : t.find((n) => n.key === e), [t, e]);
|
|
245
|
-
},
|
|
246
|
+
}, Ti = () => {
|
|
246
247
|
const e = b(), t = I();
|
|
247
248
|
return Y({
|
|
248
249
|
mutationFn: async ({ pageType: n, query: s }) => {
|
|
@@ -259,7 +260,7 @@ const fi = ({ query: e, uuid: t }) => {
|
|
|
259
260
|
}
|
|
260
261
|
}
|
|
261
262
|
});
|
|
262
|
-
},
|
|
263
|
+
}, Si = ({
|
|
263
264
|
page: e,
|
|
264
265
|
setDuplicatePage: t,
|
|
265
266
|
setAddEditPage: n,
|
|
@@ -270,7 +271,7 @@ const fi = ({ query: e, uuid: t }) => {
|
|
|
270
271
|
children: o,
|
|
271
272
|
isLanguagePage: l
|
|
272
273
|
}) => {
|
|
273
|
-
const { t: f } = we(), { hasPermission: d } =
|
|
274
|
+
const { t: f } = we(), { hasPermission: d } = Ss(), { data: u } = Ce(), g = q(() => ie(u, { key: e.pageType }), [u, e.pageType]), h = q(() => !!e.isTemplate, [e.isTemplate]), p = q(() => !!(g != null && g.hasSlug), [g == null ? void 0 : g.hasSlug]);
|
|
274
275
|
return !d(le.EDIT_PAGE) && !d(le.DELETE_PAGE) && !d(le.UNPUBLISH_PAGE) || !e ? null : /* @__PURE__ */ m(Ln, { children: [
|
|
275
276
|
/* @__PURE__ */ c(Cn, { asChild: !0, onClick: (S) => S.stopPropagation(), children: o }),
|
|
276
277
|
/* @__PURE__ */ m(Gn, { align: "center", className: "text-sm", children: [
|
|
@@ -282,7 +283,7 @@ const fi = ({ query: e, uuid: t }) => {
|
|
|
282
283
|
S.stopPropagation(), t(e);
|
|
283
284
|
},
|
|
284
285
|
children: [
|
|
285
|
-
/* @__PURE__ */ c(
|
|
286
|
+
/* @__PURE__ */ c(ka, { className: "size-3" }),
|
|
286
287
|
"Duplicate page"
|
|
287
288
|
]
|
|
288
289
|
}
|
|
@@ -298,7 +299,7 @@ const fi = ({ query: e, uuid: t }) => {
|
|
|
298
299
|
});
|
|
299
300
|
},
|
|
300
301
|
children: [
|
|
301
|
-
/* @__PURE__ */ c(
|
|
302
|
+
/* @__PURE__ */ c(Ra, { className: "size-3" }),
|
|
302
303
|
"Edit"
|
|
303
304
|
]
|
|
304
305
|
}
|
|
@@ -311,7 +312,7 @@ const fi = ({ query: e, uuid: t }) => {
|
|
|
311
312
|
S.stopPropagation(), s(e);
|
|
312
313
|
},
|
|
313
314
|
children: [
|
|
314
|
-
/* @__PURE__ */ c(
|
|
315
|
+
/* @__PURE__ */ c(Ua, { className: "size-3" }),
|
|
315
316
|
f("Unpublish")
|
|
316
317
|
]
|
|
317
318
|
}
|
|
@@ -324,7 +325,7 @@ const fi = ({ query: e, uuid: t }) => {
|
|
|
324
325
|
S.stopPropagation(), r(e);
|
|
325
326
|
},
|
|
326
327
|
children: [
|
|
327
|
-
/* @__PURE__ */ c(
|
|
328
|
+
/* @__PURE__ */ c(Ma, { className: "size-3" }),
|
|
328
329
|
f("Delete")
|
|
329
330
|
]
|
|
330
331
|
}
|
|
@@ -337,7 +338,7 @@ const fi = ({ query: e, uuid: t }) => {
|
|
|
337
338
|
S.stopPropagation(), i(e);
|
|
338
339
|
},
|
|
339
340
|
children: [
|
|
340
|
-
/* @__PURE__ */ c(
|
|
341
|
+
/* @__PURE__ */ c(Xn, { className: "size-3" }),
|
|
341
342
|
f("Unmark as template")
|
|
342
343
|
]
|
|
343
344
|
}
|
|
@@ -349,7 +350,7 @@ const fi = ({ query: e, uuid: t }) => {
|
|
|
349
350
|
S.stopPropagation(), a(e);
|
|
350
351
|
},
|
|
351
352
|
children: [
|
|
352
|
-
/* @__PURE__ */ c(
|
|
353
|
+
/* @__PURE__ */ c(Xn, { className: "size-3" }),
|
|
353
354
|
f("Mark as template")
|
|
354
355
|
]
|
|
355
356
|
}
|
|
@@ -396,7 +397,7 @@ const fi = ({ query: e, uuid: t }) => {
|
|
|
396
397
|
FORCE_TAKE_OVER_REQUEST: "FORCE_TAKE_OVER_REQUEST",
|
|
397
398
|
CONTINUE_EDITING_IN_THIS_CLIENT: "CONTINUE_EDITING_IN_THIS_CLIENT",
|
|
398
399
|
CONTINUE_EDITING_IN_THIS_TAB_REQUEST: "CONTINUE_EDITING_IN_THIS_TAB_REQUEST"
|
|
399
|
-
},
|
|
400
|
+
}, _i = ["sync", "join", "leave"], Pi = [
|
|
400
401
|
ne.FORCE_TAKE_OVER,
|
|
401
402
|
ne.TAKE_OVER_REQUEST,
|
|
402
403
|
ne.TAKE_OVER_APPROVED,
|
|
@@ -404,18 +405,18 @@ const fi = ({ query: e, uuid: t }) => {
|
|
|
404
405
|
ne.FORCE_TAKE_OVER_REQUEST,
|
|
405
406
|
ne.CONTINUE_EDITING_IN_THIS_CLIENT,
|
|
406
407
|
ne.CONTINUE_EDITING_IN_THIS_TAB_REQUEST
|
|
407
|
-
],
|
|
408
|
-
const t = {}, n =
|
|
408
|
+
], wi = Ee({}), Us = Ee(null), vi = Ee(te.CHECKING), bi = Ee({}), Ii = (e) => {
|
|
409
|
+
const t = {}, n = Sa(Ns(e).map(Ls).filter(Boolean), "pageId");
|
|
409
410
|
return Object.entries(n).forEach(
|
|
410
|
-
([s, r]) => t[s] =
|
|
411
|
+
([s, r]) => t[s] = Is(r, "onlineAt")
|
|
411
412
|
), t;
|
|
412
|
-
},
|
|
413
|
-
const t =
|
|
413
|
+
}, Ni = (e) => {
|
|
414
|
+
const t = Is(Ns(e).map(Ls).filter(Boolean), "onlineAt"), n = t == null ? void 0 : t.onlineAt;
|
|
414
415
|
return n ? n - 100 : +/* @__PURE__ */ new Date() - 1e3 * 60 * 60 * 4;
|
|
415
416
|
}, rn = () => {
|
|
416
417
|
const { user: e } = Rn();
|
|
417
418
|
return e == null ? void 0 : e.id;
|
|
418
|
-
},
|
|
419
|
+
}, Li = () => {
|
|
419
420
|
const { data: e } = Be();
|
|
420
421
|
return `WEBSITE:${e == null ? void 0 : e.appKey}`;
|
|
421
422
|
}, Ct = () => {
|
|
@@ -423,33 +424,33 @@ const fi = ({ query: e, uuid: t }) => {
|
|
|
423
424
|
return e == null ? void 0 : e.id;
|
|
424
425
|
}, Ue = crypto.randomUUID();
|
|
425
426
|
let dn = null;
|
|
426
|
-
const
|
|
427
|
-
const [e, t] = pe(
|
|
427
|
+
const Ms = () => {
|
|
428
|
+
const [e, t] = pe(wi);
|
|
428
429
|
return { pageToUser: e, setPageToUser: t };
|
|
429
430
|
}, ye = () => {
|
|
430
|
-
const [e, t] = pe(
|
|
431
|
+
const [e, t] = pe(vi), n = [te.LOCKED, te.ACTIVE_IN_ANOTHER_TAB].includes(e), s = [te.EDITING].includes(e);
|
|
431
432
|
return { pageStatus: e, setPageStatus: t, isLocked: n, isEditing: s };
|
|
432
|
-
},
|
|
433
|
-
const [e, t] = pe(
|
|
433
|
+
}, Bs = () => {
|
|
434
|
+
const [e, t] = pe(bi);
|
|
434
435
|
return { pageLockMeta: e, setPageLockMeta: t };
|
|
435
|
-
},
|
|
436
|
-
const e = Ct(), { pageToUser: t } =
|
|
436
|
+
}, Ci = () => {
|
|
437
|
+
const e = Ct(), { pageToUser: t } = Ms();
|
|
437
438
|
return q(() => t[e], [t, e]);
|
|
438
439
|
}, Un = () => {
|
|
439
|
-
const e =
|
|
440
|
+
const e = Ds(), { setPageStatus: t } = ye(), [n] = pe(Us);
|
|
440
441
|
return se(() => {
|
|
441
442
|
if (clearTimeout(dn), !e)
|
|
442
443
|
return dn = setTimeout(() => {
|
|
443
444
|
e || t(te.EDITING);
|
|
444
445
|
}, 500), () => clearTimeout(dn);
|
|
445
446
|
}, [e, t]), n;
|
|
446
|
-
},
|
|
447
|
-
const e = Ct(), t = rn(), n = Un(), { setPageToUser: s } =
|
|
447
|
+
}, Gi = () => {
|
|
448
|
+
const e = Ct(), t = rn(), n = Un(), { setPageToUser: s } = Ms(), { setPageStatus: r, pageStatus: a } = ye(), i = Ie(e);
|
|
448
449
|
return i.current = e, z(
|
|
449
450
|
(o) => {
|
|
450
451
|
const l = o || n;
|
|
451
452
|
if (!l) return [];
|
|
452
|
-
const f = l == null ? void 0 : l.presenceState(), d =
|
|
453
|
+
const f = l == null ? void 0 : l.presenceState(), d = Ii(f);
|
|
453
454
|
s(d);
|
|
454
455
|
const u = d[i.current];
|
|
455
456
|
if (!u)
|
|
@@ -464,8 +465,8 @@ const Us = () => {
|
|
|
464
465
|
},
|
|
465
466
|
[n, s, r, t, a]
|
|
466
467
|
);
|
|
467
|
-
},
|
|
468
|
-
const e = rn(), t = Ct(), n = Un(), s =
|
|
468
|
+
}, Oi = () => {
|
|
469
|
+
const e = rn(), t = Ct(), n = Un(), s = Ci(), { setPageLockMeta: r } = Bs(), a = Ie(t);
|
|
469
470
|
return a.current = t, z(
|
|
470
471
|
async (i, o) => {
|
|
471
472
|
if (!n) return;
|
|
@@ -474,8 +475,8 @@ const Us = () => {
|
|
|
474
475
|
},
|
|
475
476
|
[n, e, s, r]
|
|
476
477
|
);
|
|
477
|
-
},
|
|
478
|
-
const e = rn(), t = Ct(), n = Un(), { setPageStatus: s } = ye(), { setPageLockMeta: r } =
|
|
478
|
+
}, xi = () => {
|
|
479
|
+
const e = rn(), t = Ct(), n = Un(), { setPageStatus: s } = ye(), { setPageLockMeta: r } = Bs(), a = Oi(), i = Ie(t), { savePageAsync: o } = Re();
|
|
479
480
|
return i.current = t, z(
|
|
480
481
|
(l) => async ({ payload: f }) => {
|
|
481
482
|
const d = f || {};
|
|
@@ -496,7 +497,7 @@ const Us = () => {
|
|
|
496
497
|
break;
|
|
497
498
|
}
|
|
498
499
|
case ne.CONTINUE_EDITING_IN_THIS_CLIENT: {
|
|
499
|
-
const u =
|
|
500
|
+
const u = Ni(n == null ? void 0 : n.presenceState());
|
|
500
501
|
s(te.CHECKING), await (n == null ? void 0 : n.track({ onlineAt: u, pageId: i.current, userId: e, clientId: Ue }));
|
|
501
502
|
break;
|
|
502
503
|
}
|
|
@@ -508,8 +509,8 @@ const Us = () => {
|
|
|
508
509
|
},
|
|
509
510
|
[a, r, s, n, e, o]
|
|
510
511
|
);
|
|
511
|
-
},
|
|
512
|
-
const e =
|
|
512
|
+
}, Yc = () => {
|
|
513
|
+
const e = Ds(), t = rn(), n = Ct(), s = Li(), [r, a] = pe(Us), i = xi(), o = Gi(), l = Ie(i), f = Ie(o);
|
|
513
514
|
se(() => {
|
|
514
515
|
l.current = i, f.current = o;
|
|
515
516
|
}, [i, o]), se(() => {
|
|
@@ -517,11 +518,11 @@ const Us = () => {
|
|
|
517
518
|
const d = e.channel(s, {
|
|
518
519
|
config: { presence: { key: Ue } }
|
|
519
520
|
});
|
|
520
|
-
return
|
|
521
|
+
return Pi.forEach((u) => {
|
|
521
522
|
d.on("broadcast", { event: u }, (g) => {
|
|
522
523
|
l.current(u)(g);
|
|
523
524
|
});
|
|
524
|
-
}),
|
|
525
|
+
}), _i.forEach((u) => {
|
|
525
526
|
d.on("presence", { event: u }, () => {
|
|
526
527
|
f.current(d);
|
|
527
528
|
});
|
|
@@ -544,7 +545,7 @@ const Us = () => {
|
|
|
544
545
|
() => (e == null ? void 0 : e.fallbackLang) || "en",
|
|
545
546
|
[e]
|
|
546
547
|
);
|
|
547
|
-
},
|
|
548
|
+
}, Fs = () => {
|
|
548
549
|
const e = I(), t = b();
|
|
549
550
|
return re({
|
|
550
551
|
queryKey: [E.GET_WEBSITE_PAGES],
|
|
@@ -552,7 +553,7 @@ const Us = () => {
|
|
|
552
553
|
queryFn: async () => e(t, { action: E.GET_WEBSITE_PAGES }) || [],
|
|
553
554
|
placeholderData: (n) => n || []
|
|
554
555
|
});
|
|
555
|
-
},
|
|
556
|
+
}, Jc = (e) => {
|
|
556
557
|
const t = I(), n = b(), s = Mn();
|
|
557
558
|
return re({
|
|
558
559
|
queryKey: [E.GET_WEBSITE_PAGES, e, s],
|
|
@@ -561,7 +562,7 @@ const Us = () => {
|
|
|
561
562
|
queryFn: async () => {
|
|
562
563
|
if (s === e) return {};
|
|
563
564
|
const r = await t(n, { action: E.GET_WEBSITE_PAGES, data: { lang: e } }) || [];
|
|
564
|
-
return
|
|
565
|
+
return _a(
|
|
565
566
|
qt(r, (a) => ({ ...a, lang: e })),
|
|
566
567
|
"primaryPage"
|
|
567
568
|
);
|
|
@@ -569,12 +570,12 @@ const Us = () => {
|
|
|
569
570
|
placeholderData: (r) => r || {}
|
|
570
571
|
});
|
|
571
572
|
};
|
|
572
|
-
function
|
|
573
|
+
function Ks(e, t, n = !1) {
|
|
573
574
|
const s = e.toString() ? `?${e.toString()}` : "/";
|
|
574
575
|
n ? window.history.replaceState(null, "", s) : window.history.pushState({}, "", s), t(e), window.dispatchEvent(new PopStateEvent("popstate"));
|
|
575
576
|
}
|
|
576
|
-
const
|
|
577
|
-
const { t } = we(), [n, s] = ve(), r = n.get("page"), { data: a, isFetching: i } = oe(), { data: o, isFetching: l } =
|
|
577
|
+
const Di = V(() => import("./page-manager-new-D6DVIx2S.js")), Vs = ({ children: e }) => {
|
|
578
|
+
const { t } = we(), [n, s] = ve(), r = n.get("page"), { data: a, isFetching: i } = oe(), { data: o, isFetching: l } = Fs(), [f, d] = K(!1), [u, g] = K(!0), { savePage: h } = Re(), p = !!r && !fe(a), { isLocked: T } = ye(), S = q(() => {
|
|
578
579
|
if (!o || l) return !1;
|
|
579
580
|
const v = o.find((U) => U.slug === "/");
|
|
580
581
|
return v == null ? void 0 : v.id;
|
|
@@ -582,7 +583,7 @@ const xi = V(() => import("./page-manager-new-CzX22g2n.js")), Ks = ({ children:
|
|
|
582
583
|
se(() => {
|
|
583
584
|
if (l || !S || o.some((N) => N.id === r)) return;
|
|
584
585
|
const U = new URLSearchParams({ page: S });
|
|
585
|
-
|
|
586
|
+
Ks(U, s), !l && o && g(!1);
|
|
586
587
|
}, [r, l, o, S, s]);
|
|
587
588
|
const x = !u && !r, y = !u && !i && fe(a), w = f || x || y;
|
|
588
589
|
return /* @__PURE__ */ m(he, { children: [
|
|
@@ -594,34 +595,34 @@ const xi = V(() => import("./page-manager-new-CzX22g2n.js")), Ks = ({ children:
|
|
|
594
595
|
onClick: () => {
|
|
595
596
|
T || h(), d(!0);
|
|
596
597
|
},
|
|
597
|
-
children: e || /* @__PURE__ */ c(M, { variant: "outline", className: "flex w-full items-center space-x-2 py-1", children: /* @__PURE__ */ c(
|
|
598
|
+
children: e || /* @__PURE__ */ c(M, { variant: "outline", className: "flex w-full items-center space-x-2 py-1", children: /* @__PURE__ */ c(Ba, { className: "h-4 w-4" }) }, "template-viewer")
|
|
598
599
|
}
|
|
599
600
|
),
|
|
600
601
|
/* @__PURE__ */ c(nn, { side: "right", children: /* @__PURE__ */ c("p", { children: t("Open pages manager") }) })
|
|
601
602
|
] }) }) }),
|
|
602
|
-
/* @__PURE__ */ c(
|
|
603
|
-
|
|
603
|
+
/* @__PURE__ */ c(_s, { open: w, onOpenChange: (v) => !v && p && d(!1), children: /* @__PURE__ */ m(
|
|
604
|
+
Ps,
|
|
604
605
|
{
|
|
605
606
|
side: "left",
|
|
606
607
|
"aria-describedby": "pages-manager-description",
|
|
607
608
|
className: `z-50 !min-w-[50vh] !max-w-[800px] border-border p-0 ${p ? "" : "sheet-hide-close-btn"}`,
|
|
608
609
|
children: [
|
|
609
|
-
/* @__PURE__ */ m(
|
|
610
|
-
/* @__PURE__ */ m(
|
|
611
|
-
/* @__PURE__ */ c("div", { className: "flex h-9 w-9 items-center justify-center rounded-lg bg-primary text-primary-foreground", children: /* @__PURE__ */ c(
|
|
610
|
+
/* @__PURE__ */ m(Mr, { className: "mb-3 px-4 pt-4", children: [
|
|
611
|
+
/* @__PURE__ */ m(Br, { className: "flex items-center gap-2 text-sm font-semibold", children: [
|
|
612
|
+
/* @__PURE__ */ c("div", { className: "flex h-9 w-9 items-center justify-center rounded-lg bg-primary text-primary-foreground", children: /* @__PURE__ */ c(Fa, { className: "h-4 w-4" }) }),
|
|
612
613
|
/* @__PURE__ */ m("div", { className: "flex flex-col", children: [
|
|
613
614
|
/* @__PURE__ */ c("span", { className: "text-sm font-semibold", children: t("Pages") }),
|
|
614
615
|
/* @__PURE__ */ c("span", { id: "pages-manager-description", className: "text-xs font-normal text-muted-foreground", children: t("Manage your site structure") })
|
|
615
616
|
] })
|
|
616
617
|
] }),
|
|
617
|
-
/* @__PURE__ */ c(
|
|
618
|
+
/* @__PURE__ */ c(Fr, { className: "sr-only", children: t("Manage your site structure") })
|
|
618
619
|
] }),
|
|
619
|
-
/* @__PURE__ */ c("div", { className: "h-[calc(100vh-80px)] overflow-y-auto", children: w && /* @__PURE__ */ c(X, { children: /* @__PURE__ */ c(
|
|
620
|
+
/* @__PURE__ */ c("div", { className: "h-[calc(100vh-80px)] overflow-y-auto", children: w && /* @__PURE__ */ c(X, { children: /* @__PURE__ */ c(Di, { close: () => d(!1) }) }) })
|
|
620
621
|
]
|
|
621
622
|
}
|
|
622
623
|
) })
|
|
623
624
|
] });
|
|
624
|
-
},
|
|
625
|
+
}, ki = V(() => import("./add-new-page-pH3PwqJe.js")), Ri = V(() => import("./delete-page-Dnf97ZHP.js")), Ui = V(() => import("./duplicate-page-Bdtpl7_R.js")), Mi = V(() => import("./mark-as-template-Ba2bmVd9.js")), Bi = V(() => import("./unmark-as-template-D5b775eR.js")), Fi = V(() => import("./unpublish-page-DLLLgY43.js")), Ki = () => {
|
|
625
626
|
const [e, t] = K(null), [n, s] = K(null), [r, a] = K(null), [i, o] = K(null), [l, f] = K(null), [d, u] = K(null), { data: g, isFetching: h } = Le(), { selectedLang: p, fallbackLang: T } = Pe(), { data: S } = Me(), x = S == null ? void 0 : S.find((N) => N.lang === p), { isLocked: y } = ye(), w = !(g != null && g.slug), v = On(zt);
|
|
626
627
|
if (!g) return null;
|
|
627
628
|
const U = (N) => {
|
|
@@ -633,13 +634,13 @@ const xi = V(() => import("./page-manager-new-CzX22g2n.js")), Ks = ({ children:
|
|
|
633
634
|
};
|
|
634
635
|
return /* @__PURE__ */ m(he, { children: [
|
|
635
636
|
/* @__PURE__ */ m("div", { className: "flex items-center justify-between rounded px-[2px] transition-colors duration-200", children: [
|
|
636
|
-
/* @__PURE__ */ c(
|
|
637
|
+
/* @__PURE__ */ c(Vs, { children: /* @__PURE__ */ c(
|
|
637
638
|
M,
|
|
638
639
|
{
|
|
639
640
|
className: "flex h-7 max-w-[200px] cursor-pointer items-center truncate rounded px-1 text-xs font-medium",
|
|
640
641
|
variant: "ghost",
|
|
641
642
|
children: h ? /* @__PURE__ */ c($t, { className: "h-4 w-4 animate-spin text-slate-400" }) : /* @__PURE__ */ m("span", { className: "flex w-full cursor-pointer items-end overflow-hidden text-ellipsis whitespace-nowrap rounded-sm text-xs font-medium", children: [
|
|
642
|
-
w ? /* @__PURE__ */ c(
|
|
643
|
+
w ? /* @__PURE__ */ c(Ka, { className: "mr-1 h-4 w-4" }) : /* @__PURE__ */ c(Va, { className: "mr-1 h-4 w-4" }),
|
|
643
644
|
H(x || g, "name") ?? ""
|
|
644
645
|
] })
|
|
645
646
|
}
|
|
@@ -650,10 +651,10 @@ const xi = V(() => import("./page-manager-new-CzX22g2n.js")), Ks = ({ children:
|
|
|
650
651
|
variant: "ghost",
|
|
651
652
|
size: "icon",
|
|
652
653
|
className: "h-7 w-7 cursor-not-allowed rounded opacity-50 hover:bg-transparent",
|
|
653
|
-
children: /* @__PURE__ */ c(
|
|
654
|
+
children: /* @__PURE__ */ c(es, { className: "h-4 w-4" })
|
|
654
655
|
}
|
|
655
656
|
) : /* @__PURE__ */ c(
|
|
656
|
-
|
|
657
|
+
Si,
|
|
657
658
|
{
|
|
658
659
|
page: g,
|
|
659
660
|
setDuplicatePage: (N) => f(N),
|
|
@@ -663,12 +664,12 @@ const xi = V(() => import("./page-manager-new-CzX22g2n.js")), Ks = ({ children:
|
|
|
663
664
|
setMarkAsTemplate: (N) => a(N),
|
|
664
665
|
setUnmarkAsTemplate: (N) => o(N),
|
|
665
666
|
isLanguagePage: p.length > 0 && p !== T,
|
|
666
|
-
children: /* @__PURE__ */ c(M, { variant: "ghost", size: "icon", className: "h-7 w-7 rounded", children: /* @__PURE__ */ c(
|
|
667
|
+
children: /* @__PURE__ */ c(M, { variant: "ghost", size: "icon", className: "h-7 w-7 rounded", children: /* @__PURE__ */ c(es, { className: "h-4 w-4" }) })
|
|
667
668
|
}
|
|
668
669
|
)
|
|
669
670
|
] }),
|
|
670
671
|
d && /* @__PURE__ */ c(X, { children: /* @__PURE__ */ c(
|
|
671
|
-
|
|
672
|
+
ki,
|
|
672
673
|
{
|
|
673
674
|
closePanel: () => u(null),
|
|
674
675
|
editPage: () => {
|
|
@@ -677,12 +678,12 @@ const xi = V(() => import("./page-manager-new-CzX22g2n.js")), Ks = ({ children:
|
|
|
677
678
|
setAddEditPage: u
|
|
678
679
|
}
|
|
679
680
|
) }),
|
|
680
|
-
e && /* @__PURE__ */ c(X, { children: /* @__PURE__ */ c(
|
|
681
|
-
n && /* @__PURE__ */ c(X, { children: /* @__PURE__ */ c(
|
|
682
|
-
r && /* @__PURE__ */ c(X, { children: /* @__PURE__ */ c(
|
|
683
|
-
i && /* @__PURE__ */ c(X, { children: /* @__PURE__ */ c(
|
|
681
|
+
e && /* @__PURE__ */ c(X, { children: /* @__PURE__ */ c(Ri, { page: e, onClose: () => t(null) }) }),
|
|
682
|
+
n && /* @__PURE__ */ c(X, { children: /* @__PURE__ */ c(Fi, { page: n, onClose: () => s(null) }) }),
|
|
683
|
+
r && /* @__PURE__ */ c(X, { children: /* @__PURE__ */ c(Mi, { page: r, onClose: () => a(null) }) }),
|
|
684
|
+
i && /* @__PURE__ */ c(X, { children: /* @__PURE__ */ c(Bi, { page: i, onClose: () => o(null) }) }),
|
|
684
685
|
l && /* @__PURE__ */ c(X, { children: /* @__PURE__ */ c(
|
|
685
|
-
|
|
686
|
+
Ui,
|
|
686
687
|
{
|
|
687
688
|
page: l,
|
|
688
689
|
onClose: () => f(null),
|
|
@@ -690,7 +691,7 @@ const xi = V(() => import("./page-manager-new-CzX22g2n.js")), Ks = ({ children:
|
|
|
690
691
|
}
|
|
691
692
|
) })
|
|
692
693
|
] });
|
|
693
|
-
},
|
|
694
|
+
}, Hs = ({ children: e, className: t = "" }) => /* @__PURE__ */ c(
|
|
694
695
|
"div",
|
|
695
696
|
{
|
|
696
697
|
className: Qt(
|
|
@@ -699,7 +700,7 @@ const xi = V(() => import("./page-manager-new-CzX22g2n.js")), Ks = ({ children:
|
|
|
699
700
|
),
|
|
700
701
|
children: e
|
|
701
702
|
}
|
|
702
|
-
),
|
|
703
|
+
), Vi = ({ hasDynamicPage: e }) => /* @__PURE__ */ c(Hs, { children: /* @__PURE__ */ m("div", { className: "flex min-w-[300px] max-w-[400px] flex-col items-center justify-center rounded-lg border bg-white p-4 shadow-lg", children: [
|
|
703
704
|
/* @__PURE__ */ c("h1", { className: "text-lg font-medium", children: e ? "Select a page" : "No pages found" }),
|
|
704
705
|
/* @__PURE__ */ c("p", { className: "pt-2 text-center text-sm font-light text-gray-600", children: e ? "Please select a page from the list in the top header. This will enable you to edit the page." : "Please add a new page" })
|
|
705
706
|
] }) }), Rt = {
|
|
@@ -890,10 +891,10 @@ const xi = V(() => import("./page-manager-new-CzX22g2n.js")), Ks = ({ children:
|
|
|
890
891
|
yo: "Yoruba",
|
|
891
892
|
za: "Zhuang, Chuang",
|
|
892
893
|
zu: "Zulu"
|
|
893
|
-
},
|
|
894
|
+
}, Hi = V(() => import("./add-new-language-page-BKcBaqZu.js")), qi = () => {
|
|
894
895
|
const e = ge("topLeftCorner", null);
|
|
895
|
-
return e ? /* @__PURE__ */ c("div", { className: "max-h-9 w-full overflow-hidden pr-2", children:
|
|
896
|
-
},
|
|
896
|
+
return e ? /* @__PURE__ */ c("div", { className: "max-h-9 w-full overflow-hidden pr-2", children: Oa.createElement(e, {}) }) : null;
|
|
897
|
+
}, $i = ({
|
|
897
898
|
showAdd: e = !0,
|
|
898
899
|
variant: t = "ghost",
|
|
899
900
|
goToDefaultLang: n = !1
|
|
@@ -904,7 +905,7 @@ const xi = V(() => import("./page-manager-new-CzX22g2n.js")), Ks = ({ children:
|
|
|
904
905
|
w && (r.includes(w) ? i(w) : (y.delete("lang"), l(y), i("")));
|
|
905
906
|
}, [r, l, i]);
|
|
906
907
|
const u = On(zt), { data: g } = oe(), { data: h } = Be(), { data: p } = Me(), T = q(() => {
|
|
907
|
-
const y =
|
|
908
|
+
const y = Cs(
|
|
908
909
|
qt(H(h, "languages"), (w) => {
|
|
909
910
|
const v = ie(p, { lang: w });
|
|
910
911
|
return {
|
|
@@ -938,10 +939,10 @@ const xi = V(() => import("./page-manager-new-CzX22g2n.js")), Ks = ({ children:
|
|
|
938
939
|
}, x = (y) => {
|
|
939
940
|
i(y);
|
|
940
941
|
const w = new URLSearchParams(window.location.search);
|
|
941
|
-
y === s ? w.delete("lang") : w.set("lang", y),
|
|
942
|
+
y === s ? w.delete("lang") : w.set("lang", y), Ks(w, l);
|
|
942
943
|
};
|
|
943
944
|
return fe(r) ? null : f ? /* @__PURE__ */ m(M, { variant: "ghost", size: "sm", className: "ml-px h-max cursor-not-allowed gap-2 py-1.5 opacity-50", children: [
|
|
944
|
-
/* @__PURE__ */ c(
|
|
945
|
+
/* @__PURE__ */ c(ts, { className: "h-4 w-4" }),
|
|
945
946
|
H(Rt, o, o),
|
|
946
947
|
/* @__PURE__ */ c(yn, { className: "h-4 w-4" })
|
|
947
948
|
] }) : n ? /* @__PURE__ */ c(M, { onClick: () => x(s), variant: "link", size: "sm", children: d("Switch to default language") }) : /* @__PURE__ */ c(he, { children: /* @__PURE__ */ m(Ln, { children: [
|
|
@@ -953,7 +954,7 @@ const xi = V(() => import("./page-manager-new-CzX22g2n.js")), Ks = ({ children:
|
|
|
953
954
|
size: "sm",
|
|
954
955
|
className: "ml-px h-max gap-2 py-1.5",
|
|
955
956
|
children: [
|
|
956
|
-
/* @__PURE__ */ c(
|
|
957
|
+
/* @__PURE__ */ c(ts, { className: "h-4 w-4" }),
|
|
957
958
|
H(Rt, o, o),
|
|
958
959
|
/* @__PURE__ */ c(yn, { className: "h-4 w-4" })
|
|
959
960
|
]
|
|
@@ -973,7 +974,7 @@ const xi = V(() => import("./page-manager-new-CzX22g2n.js")), Ks = ({ children:
|
|
|
973
974
|
children: [
|
|
974
975
|
/* @__PURE__ */ c("div", { className: "text-slate-600", children: y.value }),
|
|
975
976
|
y.key === s && /* @__PURE__ */ m("small", { className: "flex items-center gap-x-1 text-[9px] leading-none text-orange-500", children: [
|
|
976
|
-
/* @__PURE__ */ c(
|
|
977
|
+
/* @__PURE__ */ c(Ha, { fill: "orange", className: "h-2 w-2" }),
|
|
977
978
|
"Primary"
|
|
978
979
|
] })
|
|
979
980
|
]
|
|
@@ -982,7 +983,7 @@ const xi = V(() => import("./page-manager-new-CzX22g2n.js")), Ks = ({ children:
|
|
|
982
983
|
)
|
|
983
984
|
),
|
|
984
985
|
e && !fe(T.filter((y) => !y.isLangPageAdded)) && /* @__PURE__ */ m(he, { children: [
|
|
985
|
-
/* @__PURE__ */ c(
|
|
986
|
+
/* @__PURE__ */ c(Kr, {}),
|
|
986
987
|
/* @__PURE__ */ m(
|
|
987
988
|
M,
|
|
988
989
|
{
|
|
@@ -996,7 +997,7 @@ const xi = V(() => import("./page-manager-new-CzX22g2n.js")), Ks = ({ children:
|
|
|
996
997
|
},
|
|
997
998
|
className: "text-xs font-normal duration-200 hover:bg-slate-300 hover:text-slate-800",
|
|
998
999
|
children: [
|
|
999
|
-
/* @__PURE__ */ c(
|
|
1000
|
+
/* @__PURE__ */ c(xs, { className: "mr-1 h-3 w-3" }),
|
|
1000
1001
|
" Add Language"
|
|
1001
1002
|
]
|
|
1002
1003
|
}
|
|
@@ -1005,13 +1006,13 @@ const xi = V(() => import("./page-manager-new-CzX22g2n.js")), Ks = ({ children:
|
|
|
1005
1006
|
] })
|
|
1006
1007
|
] }) });
|
|
1007
1008
|
};
|
|
1008
|
-
function
|
|
1009
|
-
const e =
|
|
1009
|
+
function Qi() {
|
|
1010
|
+
const e = ya(zt), t = On(zt);
|
|
1010
1011
|
return /* @__PURE__ */ m("div", { className: "relative z-10 flex items-center justify-end gap-1", children: [
|
|
1011
|
-
/* @__PURE__ */ c(
|
|
1012
|
-
/* @__PURE__ */ c(
|
|
1012
|
+
/* @__PURE__ */ c(qi, {}),
|
|
1013
|
+
/* @__PURE__ */ c(Vs, {}),
|
|
1013
1014
|
e && /* @__PURE__ */ c(X, { children: /* @__PURE__ */ c(
|
|
1014
|
-
|
|
1015
|
+
Hi,
|
|
1015
1016
|
{
|
|
1016
1017
|
isOpen: !0,
|
|
1017
1018
|
id: e == null ? void 0 : e.id,
|
|
@@ -1023,7 +1024,7 @@ function $i() {
|
|
|
1023
1024
|
) })
|
|
1024
1025
|
] });
|
|
1025
1026
|
}
|
|
1026
|
-
function
|
|
1027
|
+
function zi() {
|
|
1027
1028
|
return /* @__PURE__ */ c("div", { className: "mt-2 space-y-2", children: Array.from({ length: 5 }).map((e, t) => /* @__PURE__ */ m("div", { className: "flex items-start gap-3 rounded-md border p-2", children: [
|
|
1028
1029
|
/* @__PURE__ */ m("div", { className: "flex-1 space-y-1", children: [
|
|
1029
1030
|
/* @__PURE__ */ c(Dt, { className: "h-4 w-3/4" }),
|
|
@@ -1033,19 +1034,19 @@ function Qi() {
|
|
|
1033
1034
|
/* @__PURE__ */ c(Dt, { className: "h-8 w-8 rounded-full" })
|
|
1034
1035
|
] }, t)) });
|
|
1035
1036
|
}
|
|
1036
|
-
const
|
|
1037
|
-
function
|
|
1037
|
+
const Wi = $.lazy(() => import("./page-revisions-content-5rbicFbD.js"));
|
|
1038
|
+
function ji() {
|
|
1038
1039
|
const [e, t] = $.useState(!1);
|
|
1039
|
-
return /* @__PURE__ */ c(
|
|
1040
|
-
/* @__PURE__ */ m(
|
|
1041
|
-
/* @__PURE__ */ c(
|
|
1040
|
+
return /* @__PURE__ */ c(ws, { children: /* @__PURE__ */ m(en, { delayDuration: 0, children: [
|
|
1041
|
+
/* @__PURE__ */ m(_s, { open: e, onOpenChange: t, children: [
|
|
1042
|
+
/* @__PURE__ */ c(Vr, { asChild: !0, children: /* @__PURE__ */ c(tn, { asChild: !0, children: /* @__PURE__ */ m("span", { className: "flex items-center gap-2", children: [
|
|
1042
1043
|
/* @__PURE__ */ m(M, { variant: "ghost", size: "icon", className: "h-8 w-8", children: [
|
|
1043
|
-
/* @__PURE__ */ c(
|
|
1044
|
+
/* @__PURE__ */ c(qa, { className: "h-4 w-4" }),
|
|
1044
1045
|
/* @__PURE__ */ c("span", { className: "sr-only", children: "View revision history" })
|
|
1045
1046
|
] }),
|
|
1046
1047
|
/* @__PURE__ */ c("div", { className: "h-4 w-px bg-gray-200 dark:bg-gray-700" })
|
|
1047
1048
|
] }) }) }),
|
|
1048
|
-
/* @__PURE__ */ c(
|
|
1049
|
+
/* @__PURE__ */ c(Ps, { className: "flex h-[100vh] flex-col", children: e && /* @__PURE__ */ c(X, { fallback: /* @__PURE__ */ c(zi, {}), children: /* @__PURE__ */ c(Wi, { isOpen: e }) }) })
|
|
1049
1050
|
] }),
|
|
1050
1051
|
/* @__PURE__ */ c(nn, { side: "bottom", children: /* @__PURE__ */ c("p", { children: "Revision history" }) })
|
|
1051
1052
|
] }) });
|
|
@@ -1056,11 +1057,11 @@ const fn = ({
|
|
|
1056
1057
|
children: n,
|
|
1057
1058
|
fallback: s = null
|
|
1058
1059
|
}) => {
|
|
1059
|
-
const { hasPermission: r } =
|
|
1060
|
+
const { hasPermission: r } = Ss();
|
|
1060
1061
|
return e && !r(e) || t && !t.some((a) => r(a)) ? s : n;
|
|
1061
|
-
},
|
|
1062
|
+
}, Yi = {
|
|
1062
1063
|
SLUG_ALREADY_USED: "This slug is already in use. Please choose a different one."
|
|
1063
|
-
},
|
|
1064
|
+
}, Zc = () => {
|
|
1064
1065
|
const e = b(), t = J(), n = I(), { data: s } = Ce();
|
|
1065
1066
|
return Y({
|
|
1066
1067
|
mutationFn: async (r) => await n(e, {
|
|
@@ -1082,11 +1083,11 @@ const fn = ({
|
|
|
1082
1083
|
onError: (r, a) => {
|
|
1083
1084
|
const i = ie(s, { key: a.pageType });
|
|
1084
1085
|
R.error(`Failed to add new ${i != null && i.hasSlug ? "page" : i.name}.`, {
|
|
1085
|
-
description: H(
|
|
1086
|
+
description: H(Yi, r.message, r.message)
|
|
1086
1087
|
});
|
|
1087
1088
|
}
|
|
1088
1089
|
});
|
|
1089
|
-
},
|
|
1090
|
+
}, Xc = () => {
|
|
1090
1091
|
const e = b(), t = J(), n = I(), { data: s } = Le(), { data: r } = Ce();
|
|
1091
1092
|
return Y({
|
|
1092
1093
|
mutationFn: async (a) => await n(e, {
|
|
@@ -1111,7 +1112,7 @@ const fn = ({
|
|
|
1111
1112
|
});
|
|
1112
1113
|
}
|
|
1113
1114
|
});
|
|
1114
|
-
},
|
|
1115
|
+
}, eu = () => {
|
|
1115
1116
|
const e = b(), t = J(), n = I(), { data: s } = Ce();
|
|
1116
1117
|
return Y({
|
|
1117
1118
|
mutationFn: async (r) => n(e, {
|
|
@@ -1140,7 +1141,7 @@ const fn = ({
|
|
|
1140
1141
|
});
|
|
1141
1142
|
}
|
|
1142
1143
|
});
|
|
1143
|
-
},
|
|
1144
|
+
}, tu = () => {
|
|
1144
1145
|
const e = b(), t = J(), n = I(), { data: s } = Ce();
|
|
1145
1146
|
return Y({
|
|
1146
1147
|
mutationFn: async (r) => n(e, {
|
|
@@ -1165,7 +1166,7 @@ const fn = ({
|
|
|
1165
1166
|
});
|
|
1166
1167
|
}
|
|
1167
1168
|
});
|
|
1168
|
-
},
|
|
1169
|
+
}, qs = () => {
|
|
1169
1170
|
const e = b(), t = I(), n = J(), { data: s } = oe(), { savePageAsync: r } = Re();
|
|
1170
1171
|
return Y({
|
|
1171
1172
|
mutationFn: async ({ ids: a }) => (await r(), t(e, {
|
|
@@ -1185,7 +1186,7 @@ const fn = ({
|
|
|
1185
1186
|
console.log("##", a), R.error("Failed to publish pages.");
|
|
1186
1187
|
}
|
|
1187
1188
|
});
|
|
1188
|
-
},
|
|
1189
|
+
}, nu = () => {
|
|
1189
1190
|
const e = b(), t = I(), n = J();
|
|
1190
1191
|
return Y({
|
|
1191
1192
|
mutationFn: async (s) => {
|
|
@@ -1210,7 +1211,7 @@ const fn = ({
|
|
|
1210
1211
|
R.error("Failed to mark page as template.");
|
|
1211
1212
|
}
|
|
1212
1213
|
});
|
|
1213
|
-
},
|
|
1214
|
+
}, su = () => {
|
|
1214
1215
|
const e = b(), t = I(), n = J();
|
|
1215
1216
|
return Y({
|
|
1216
1217
|
mutationFn: async (s) => t(e, {
|
|
@@ -1226,7 +1227,7 @@ const fn = ({
|
|
|
1226
1227
|
R.error("Failed to unmark page as template.");
|
|
1227
1228
|
}
|
|
1228
1229
|
});
|
|
1229
|
-
},
|
|
1230
|
+
}, ru = () => {
|
|
1230
1231
|
const e = b(), t = I(), n = J();
|
|
1231
1232
|
return Y({
|
|
1232
1233
|
mutationFn: async ({ id: s, slug: r }) => t(e, {
|
|
@@ -1244,30 +1245,30 @@ const fn = ({
|
|
|
1244
1245
|
R.error("Failed to change slug");
|
|
1245
1246
|
}
|
|
1246
1247
|
});
|
|
1247
|
-
},
|
|
1248
|
-
function
|
|
1248
|
+
}, Ji = V(() => import("./publish-pages-content-WeGk-YLC.js"));
|
|
1249
|
+
function Zi({
|
|
1249
1250
|
showModal: e = !1,
|
|
1250
1251
|
onClose: t = () => console.log("Cancelled")
|
|
1251
1252
|
}) {
|
|
1252
|
-
const { mutate: n, isPending: s } =
|
|
1253
|
-
return /* @__PURE__ */ c(
|
|
1254
|
-
} : t, children: e && /* @__PURE__ */ c(X, { fallback: /* @__PURE__ */ c("div", { className: "h-96 w-96 animate-pulse bg-gray-100" }), children: /* @__PURE__ */ c(
|
|
1253
|
+
const { mutate: n, isPending: s } = qs();
|
|
1254
|
+
return /* @__PURE__ */ c(vs, { open: e, onOpenChange: s ? () => {
|
|
1255
|
+
} : t, children: e && /* @__PURE__ */ c(X, { fallback: /* @__PURE__ */ c("div", { className: "h-96 w-96 animate-pulse bg-gray-100" }), children: /* @__PURE__ */ c(Ji, { onClose: t, isPending: s, publishPage: n }) }) });
|
|
1255
1256
|
}
|
|
1256
|
-
const
|
|
1257
|
+
const Xi = (e) => {
|
|
1257
1258
|
const { fallbackLang: t } = Pe(), { data: n } = Be(), { data: s, isFetching: r } = Me(), a = q(() => {
|
|
1258
1259
|
const i = { [t]: !0 };
|
|
1259
|
-
return
|
|
1260
|
+
return Pa(H(n, "languages"), (o) => {
|
|
1260
1261
|
const l = ie(s, { lang: o });
|
|
1261
1262
|
i[o] = !!l;
|
|
1262
1263
|
}), i;
|
|
1263
1264
|
}, [t, s, n]);
|
|
1264
1265
|
return r || fe(e) || e && a[e];
|
|
1265
|
-
},
|
|
1266
|
+
}, eo = {
|
|
1266
1267
|
particleCount: 350,
|
|
1267
1268
|
spread: 120,
|
|
1268
1269
|
origin: { y: 0.6 },
|
|
1269
1270
|
angle: 90
|
|
1270
|
-
},
|
|
1271
|
+
}, to = {
|
|
1271
1272
|
TOP_RIGHT: {
|
|
1272
1273
|
angle: 225,
|
|
1273
1274
|
origin: { x: 0.9, y: 0 }
|
|
@@ -1276,14 +1277,14 @@ const Zi = (e) => {
|
|
|
1276
1277
|
angle: 100,
|
|
1277
1278
|
origin: { x: 0.9, y: 0.9 }
|
|
1278
1279
|
}
|
|
1279
|
-
},
|
|
1280
|
+
}, no = async () => {
|
|
1280
1281
|
const { default: e } = await import("canvas-confetti");
|
|
1281
1282
|
return e;
|
|
1282
1283
|
}, hn = (e) => {
|
|
1283
|
-
let t =
|
|
1284
|
+
let t = to[e];
|
|
1284
1285
|
t || (t = {});
|
|
1285
|
-
const n = { ...
|
|
1286
|
-
|
|
1286
|
+
const n = { ...eo, ...t };
|
|
1287
|
+
no().then((s) => s(n));
|
|
1287
1288
|
};
|
|
1288
1289
|
function Bn({
|
|
1289
1290
|
children: e,
|
|
@@ -1292,14 +1293,14 @@ function Bn({
|
|
|
1292
1293
|
delayDuration: s = 700,
|
|
1293
1294
|
showTooltip: r = !0
|
|
1294
1295
|
}) {
|
|
1295
|
-
return r ? /* @__PURE__ */ c(
|
|
1296
|
+
return r ? /* @__PURE__ */ c(ws, { children: /* @__PURE__ */ m(en, { delayDuration: s, children: [
|
|
1296
1297
|
/* @__PURE__ */ c(tn, { asChild: !0, children: e }),
|
|
1297
1298
|
/* @__PURE__ */ c(nn, { side: n, sideOffset: 10, children: /* @__PURE__ */ c("p", { children: t }) })
|
|
1298
1299
|
] }) }) : e;
|
|
1299
1300
|
}
|
|
1300
|
-
const
|
|
1301
|
-
() => import("./translation-warning-modal-
|
|
1302
|
-
),
|
|
1301
|
+
const so = V(() => import("./unpublish-page-DLLLgY43.js")), ro = V(
|
|
1302
|
+
() => import("./translation-warning-modal-Jadkcver.js")
|
|
1303
|
+
), ao = () => {
|
|
1303
1304
|
const { t: e } = we(), { selectedLang: t, fallbackLang: n } = Pe(), s = ge("getPreviewUrl", async (g) => g), [r, a] = K(""), { data: i } = oe(), { data: o } = Me(), { data: l } = Ce(), f = q(
|
|
1304
1305
|
() => {
|
|
1305
1306
|
var g;
|
|
@@ -1320,9 +1321,9 @@ const no = V(() => import("./unpublish-page-D4VwOlxc.js")), so = V(
|
|
|
1320
1321
|
} else
|
|
1321
1322
|
a("");
|
|
1322
1323
|
})();
|
|
1323
|
-
}, [s, f, i == null ? void 0 : i.pageType, d, i == null ? void 0 : i.id, u]), /* @__PURE__ */ c(he, { children: /* @__PURE__ */ c(Bn, { content: e("Open preview in new tab"), delayDuration: 0, children: /* @__PURE__ */ c("a", { href: r, target: "_blank", rel: "noopener noreferrer", children: /* @__PURE__ */ c(M, { variant: "ghost", size: "sm", className: "gap-2", children: /* @__PURE__ */ c(
|
|
1324
|
-
},
|
|
1325
|
-
const { t: e } = we(), [t, n] =
|
|
1324
|
+
}, [s, f, i == null ? void 0 : i.pageType, d, i == null ? void 0 : i.id, u]), /* @__PURE__ */ c(he, { children: /* @__PURE__ */ c(Bn, { content: e("Open preview in new tab"), delayDuration: 0, children: /* @__PURE__ */ c("a", { href: r, target: "_blank", rel: "noopener noreferrer", children: /* @__PURE__ */ c(M, { variant: "ghost", size: "sm", className: "gap-2", children: /* @__PURE__ */ c(Qa, { className: "h-4 w-4" }) }) }) }) });
|
|
1325
|
+
}, io = () => {
|
|
1326
|
+
const { t: e } = we(), [t, n] = Hr();
|
|
1326
1327
|
return /* @__PURE__ */ m(he, { children: [
|
|
1327
1328
|
/* @__PURE__ */ c(Bn, { content: e("Theme"), delayDuration: 0, children: /* @__PURE__ */ c(
|
|
1328
1329
|
M,
|
|
@@ -1331,12 +1332,12 @@ const no = V(() => import("./unpublish-page-D4VwOlxc.js")), so = V(
|
|
|
1331
1332
|
size: "icon",
|
|
1332
1333
|
className: "gap-2",
|
|
1333
1334
|
onClick: () => n(t === "theme" ? "block" : "theme"),
|
|
1334
|
-
children: /* @__PURE__ */ c(
|
|
1335
|
+
children: /* @__PURE__ */ c($a, { className: "h-4 w-4" })
|
|
1335
1336
|
}
|
|
1336
1337
|
) }),
|
|
1337
1338
|
/* @__PURE__ */ c("div", { className: "h-4 w-px bg-gray-200 dark:bg-gray-700" })
|
|
1338
1339
|
] });
|
|
1339
|
-
},
|
|
1340
|
+
}, oo = () => {
|
|
1340
1341
|
const { t: e } = we(), [t, n] = K(!1), { isLocked: s } = ye(), { savePageAsync: r, saveState: a } = Re();
|
|
1341
1342
|
se(() => {
|
|
1342
1343
|
const d = (u) => {
|
|
@@ -1353,7 +1354,7 @@ const no = V(() => import("./unpublish-page-D4VwOlxc.js")), so = V(
|
|
|
1353
1354
|
case "UNSAVED":
|
|
1354
1355
|
return {
|
|
1355
1356
|
tooltipContent: e("Save draft"),
|
|
1356
|
-
buttonIcon: /* @__PURE__ */ c(
|
|
1357
|
+
buttonIcon: /* @__PURE__ */ c(Wa, { className: "h-4 w-4" }),
|
|
1357
1358
|
buttonClass: "gap-x-1"
|
|
1358
1359
|
};
|
|
1359
1360
|
case "SAVING":
|
|
@@ -1365,7 +1366,7 @@ const no = V(() => import("./unpublish-page-D4VwOlxc.js")), so = V(
|
|
|
1365
1366
|
case "SAVED":
|
|
1366
1367
|
return {
|
|
1367
1368
|
tooltipContent: e("Saved"),
|
|
1368
|
-
buttonIcon: /* @__PURE__ */ c(
|
|
1369
|
+
buttonIcon: /* @__PURE__ */ c(za, { className: "h-4 w-4" }),
|
|
1369
1370
|
buttonClass: "text-green-500 gap-x-1"
|
|
1370
1371
|
};
|
|
1371
1372
|
}
|
|
@@ -1375,8 +1376,8 @@ const no = V(() => import("./unpublish-page-D4VwOlxc.js")), so = V(
|
|
|
1375
1376
|
" ",
|
|
1376
1377
|
f
|
|
1377
1378
|
] });
|
|
1378
|
-
},
|
|
1379
|
-
const { t: e } = we(), { selectedLang: t } = Pe(), { data: n } = Le(), { data: s } = Me(), [r, a] = K(!1), [i, o] = K(!1), [l, f] = K(null), { savePageAsync: d } = Re(), [u, g] = K(!1), { data: h } = oe(), { mutate: p, isPending: T } =
|
|
1379
|
+
}, lo = () => {
|
|
1380
|
+
const { t: e } = we(), { selectedLang: t } = Pe(), { data: n } = Le(), { data: s } = Me(), [r, a] = K(!1), [i, o] = K(!1), [l, f] = K(null), { savePageAsync: d } = Re(), [u, g] = K(!1), { data: h } = oe(), { mutate: p, isPending: T } = qs(), { needTranslations: S } = Re(), x = S(), { buttonText: y, buttonClassName: w, isPublished: v } = q(() => {
|
|
1380
1381
|
const P = h && (h == null ? void 0 : h.online);
|
|
1381
1382
|
return {
|
|
1382
1383
|
buttonClassName: P ? "hover:bg-green-600 bg-green-500" : "",
|
|
@@ -1391,7 +1392,7 @@ const no = V(() => import("./unpublish-page-D4VwOlxc.js")), so = V(
|
|
|
1391
1392
|
N();
|
|
1392
1393
|
}, N = () => {
|
|
1393
1394
|
const P = [n == null ? void 0 : n.id, n == null ? void 0 : n.primaryPage];
|
|
1394
|
-
p({ ids:
|
|
1395
|
+
p({ ids: Cs(P) }, { onSuccess: () => hn("TOP_RIGHT") });
|
|
1395
1396
|
}, Ae = () => {
|
|
1396
1397
|
g(!1), N();
|
|
1397
1398
|
}, Te = async () => {
|
|
@@ -1413,14 +1414,14 @@ const no = V(() => import("./unpublish-page-D4VwOlxc.js")), so = V(
|
|
|
1413
1414
|
"span",
|
|
1414
1415
|
{
|
|
1415
1416
|
className: `flex items-center transition-transform duration-300 ease-in-out ${i ? "-translate-y-10" : ""}`,
|
|
1416
|
-
children: v ? /* @__PURE__ */ c(
|
|
1417
|
+
children: v ? /* @__PURE__ */ c(ns, { className: "h-4 w-4" }) : /* @__PURE__ */ c(ss, { className: "h-4 w-4" })
|
|
1417
1418
|
}
|
|
1418
1419
|
),
|
|
1419
1420
|
/* @__PURE__ */ c(
|
|
1420
1421
|
"span",
|
|
1421
1422
|
{
|
|
1422
1423
|
className: `absolute inset-0 left-3 flex items-center transition-transform duration-300 ease-in-out ${i ? "" : "translate-y-10"}`,
|
|
1423
|
-
children: v ? /* @__PURE__ */ c(
|
|
1424
|
+
children: v ? /* @__PURE__ */ c(ss, { className: "h-4 w-4" }) : /* @__PURE__ */ c(ns, { className: "h-4 w-4" })
|
|
1424
1425
|
}
|
|
1425
1426
|
),
|
|
1426
1427
|
/* @__PURE__ */ c("span", { children: y }),
|
|
@@ -1475,10 +1476,10 @@ const no = V(() => import("./unpublish-page-D4VwOlxc.js")), so = V(
|
|
|
1475
1476
|
] })
|
|
1476
1477
|
] })
|
|
1477
1478
|
] }),
|
|
1478
|
-
/* @__PURE__ */ c(
|
|
1479
|
-
l && /* @__PURE__ */ c(X, { children: /* @__PURE__ */ c(
|
|
1479
|
+
/* @__PURE__ */ c(Zi, { showModal: r, onClose: () => a(!1) }),
|
|
1480
|
+
l && /* @__PURE__ */ c(X, { children: /* @__PURE__ */ c(so, { page: l, onClose: () => f(null) }) }),
|
|
1480
1481
|
u && /* @__PURE__ */ c(X, { children: /* @__PURE__ */ c(
|
|
1481
|
-
|
|
1482
|
+
ro,
|
|
1482
1483
|
{
|
|
1483
1484
|
isOpen: u,
|
|
1484
1485
|
onClose: Te,
|
|
@@ -1488,24 +1489,24 @@ const no = V(() => import("./unpublish-page-D4VwOlxc.js")), so = V(
|
|
|
1488
1489
|
) })
|
|
1489
1490
|
] });
|
|
1490
1491
|
};
|
|
1491
|
-
function
|
|
1492
|
-
const { isLocked: e } = ye(), [t] = ve(), n = t.get("lang"), s =
|
|
1492
|
+
function co() {
|
|
1493
|
+
const { isLocked: e } = ye(), [t] = ve(), n = t.get("lang"), s = Xi(n);
|
|
1493
1494
|
return e || !s ? /* @__PURE__ */ c("div", {}) : /* @__PURE__ */ m("div", { className: "flex items-center justify-end gap-1", children: [
|
|
1494
|
-
/* @__PURE__ */ c(
|
|
1495
|
-
/* @__PURE__ */ c(fn, { permission: le.EDIT_THEME, children: /* @__PURE__ */ c(
|
|
1496
|
-
/* @__PURE__ */ c(
|
|
1497
|
-
/* @__PURE__ */ c(fn, { permission: le.SAVE_PAGE, children: /* @__PURE__ */ c(
|
|
1498
|
-
/* @__PURE__ */ c(fn, { permission: le.PUBLISH_PAGE, children: /* @__PURE__ */ c(
|
|
1495
|
+
/* @__PURE__ */ c(ji, {}),
|
|
1496
|
+
/* @__PURE__ */ c(fn, { permission: le.EDIT_THEME, children: /* @__PURE__ */ c(io, {}) }),
|
|
1497
|
+
/* @__PURE__ */ c(ao, {}),
|
|
1498
|
+
/* @__PURE__ */ c(fn, { permission: le.SAVE_PAGE, children: /* @__PURE__ */ c(oo, {}) }),
|
|
1499
|
+
/* @__PURE__ */ c(fn, { permission: le.PUBLISH_PAGE, children: /* @__PURE__ */ c(lo, {}) })
|
|
1499
1500
|
] });
|
|
1500
1501
|
}
|
|
1501
|
-
const
|
|
1502
|
-
const { dynamicPage: e, allLangPages: t, isFetching: n } =
|
|
1502
|
+
const uo = V(() => import("./dynamic-page-selector-BVnIM1Rq.js")), fo = () => {
|
|
1503
|
+
const { dynamicPage: e, allLangPages: t, isFetching: n } = gi(), s = t.length > 0;
|
|
1503
1504
|
return n ? null : /* @__PURE__ */ m("div", { className: "relative", children: [
|
|
1504
|
-
!e && /* @__PURE__ */ c(
|
|
1505
|
-
/* @__PURE__ */ c(X, { children: /* @__PURE__ */ c(
|
|
1505
|
+
!e && /* @__PURE__ */ c(Vi, { hasDynamicPage: s }),
|
|
1506
|
+
/* @__PURE__ */ c(X, { children: /* @__PURE__ */ c(uo, {}) })
|
|
1506
1507
|
] });
|
|
1507
|
-
},
|
|
1508
|
-
const { data: e, isFetching: t } = Le(), { data: n, isFetching: s } = oe(), r = H(n, "dynamic", !1), a = kn(), i =
|
|
1508
|
+
}, ho = () => {
|
|
1509
|
+
const { data: e, isFetching: t } = Le(), { data: n, isFetching: s } = oe(), r = H(n, "dynamic", !1), a = kn(), i = da("dynamic-page-selector"), o = e == null ? void 0 : e.slug, l = !o, f = yi(), d = t || s, g = (l ? `Partial: ${e == null ? void 0 : e.name} ` : `${o}${a}`).replace(window.location.host, "");
|
|
1509
1510
|
return /* @__PURE__ */ m("div", { className: "relative flex items-center gap-x-1", children: [
|
|
1510
1511
|
/* @__PURE__ */ c(
|
|
1511
1512
|
"div",
|
|
@@ -1514,7 +1515,7 @@ const co = V(() => import("./dynamic-page-selector-Cb5r_W8s.js")), uo = () => {
|
|
|
1514
1515
|
"flex h-8 w-auto max-w-[600px] items-center rounded-md border border-gray-200 bg-white shadow-sm dark:border-gray-700 dark:bg-gray-800",
|
|
1515
1516
|
d && "max-w-0 overflow-hidden opacity-0"
|
|
1516
1517
|
),
|
|
1517
|
-
children: /* @__PURE__ */ c(
|
|
1518
|
+
children: /* @__PURE__ */ c(Ki, {})
|
|
1518
1519
|
}
|
|
1519
1520
|
),
|
|
1520
1521
|
/* @__PURE__ */ m(
|
|
@@ -1525,7 +1526,7 @@ const co = V(() => import("./dynamic-page-selector-Cb5r_W8s.js")), uo = () => {
|
|
|
1525
1526
|
d && "max-w-0 overflow-hidden opacity-0"
|
|
1526
1527
|
),
|
|
1527
1528
|
children: [
|
|
1528
|
-
/* @__PURE__ */ c(
|
|
1529
|
+
/* @__PURE__ */ c($i, {}),
|
|
1529
1530
|
/* @__PURE__ */ m("div", { className: "flex w-full items-center overflow-hidden", children: [
|
|
1530
1531
|
/* @__PURE__ */ c(
|
|
1531
1532
|
"div",
|
|
@@ -1537,18 +1538,18 @@ const co = V(() => import("./dynamic-page-selector-Cb5r_W8s.js")), uo = () => {
|
|
|
1537
1538
|
] }) : g
|
|
1538
1539
|
}
|
|
1539
1540
|
),
|
|
1540
|
-
!l && /* @__PURE__ */ c("a", { href: f, target: "_blank", rel: "noopener noreferrer", children: /* @__PURE__ */ c("div", { className: "ml-2 mr-px flex-shrink-0 rounded-sm p-1.5 text-gray-500 hover:bg-gray-100 hover:text-gray-700 dark:text-gray-400 dark:hover:text-gray-300", children: /* @__PURE__ */ c(
|
|
1541
|
+
!l && /* @__PURE__ */ c("a", { href: f, target: "_blank", rel: "noopener noreferrer", children: /* @__PURE__ */ c("div", { className: "ml-2 mr-px flex-shrink-0 rounded-sm p-1.5 text-gray-500 hover:bg-gray-100 hover:text-gray-700 dark:text-gray-400 dark:hover:text-gray-300", children: /* @__PURE__ */ c(ja, { className: "h-4 w-4", strokeWidth: 1 }) }) })
|
|
1541
1542
|
] })
|
|
1542
1543
|
]
|
|
1543
1544
|
}
|
|
1544
1545
|
),
|
|
1545
|
-
r && i && /* @__PURE__ */ c(
|
|
1546
|
+
r && i && /* @__PURE__ */ c(fo, {})
|
|
1546
1547
|
] });
|
|
1547
|
-
},
|
|
1548
|
-
/* @__PURE__ */ c(
|
|
1549
|
-
/* @__PURE__ */ c(
|
|
1550
|
-
/* @__PURE__ */ c(
|
|
1551
|
-
] }),
|
|
1548
|
+
}, go = () => /* @__PURE__ */ m("div", { className: "flex h-full w-full items-center justify-between px-2", children: [
|
|
1549
|
+
/* @__PURE__ */ c(Qi, {}),
|
|
1550
|
+
/* @__PURE__ */ c(ho, {}),
|
|
1551
|
+
/* @__PURE__ */ c(co, {})
|
|
1552
|
+
] }), $s = () => {
|
|
1552
1553
|
const e = J(), { data: t } = re({
|
|
1553
1554
|
queryKey: [E.AI_CONTEXT],
|
|
1554
1555
|
initialData: "",
|
|
@@ -1561,8 +1562,8 @@ const co = V(() => import("./dynamic-page-selector-Cb5r_W8s.js")), uo = () => {
|
|
|
1561
1562
|
},
|
|
1562
1563
|
[e]
|
|
1563
1564
|
), aiContext: t };
|
|
1564
|
-
},
|
|
1565
|
-
const e = b(), { aiContext: t } =
|
|
1565
|
+
}, mo = () => {
|
|
1566
|
+
const e = b(), { aiContext: t } = $s(), n = I();
|
|
1566
1567
|
return z(
|
|
1567
1568
|
async (s, r, a, i) => n(e, {
|
|
1568
1569
|
action: E.ASK_AI,
|
|
@@ -1570,26 +1571,26 @@ const co = V(() => import("./dynamic-page-selector-Cb5r_W8s.js")), uo = () => {
|
|
|
1570
1571
|
}),
|
|
1571
1572
|
[e, t, n]
|
|
1572
1573
|
);
|
|
1573
|
-
},
|
|
1574
|
+
}, Eo = (e, t) => t.map((n) => {
|
|
1574
1575
|
if (sn(e, n._type)) {
|
|
1575
|
-
const s =
|
|
1576
|
+
const s = ai(n._type);
|
|
1576
1577
|
return {
|
|
1577
1578
|
...s,
|
|
1578
|
-
...xn(n, [...
|
|
1579
|
-
...
|
|
1579
|
+
...xn(n, [...Ia(s), "_type", "_id", "_name", "_parent", "_bindings"]),
|
|
1580
|
+
...va(n, (r, a) => ba(a, "_attrs")),
|
|
1580
1581
|
...n
|
|
1581
1582
|
};
|
|
1582
1583
|
}
|
|
1583
1584
|
return n;
|
|
1584
|
-
}),
|
|
1585
|
-
const t =
|
|
1585
|
+
}), po = (e) => {
|
|
1586
|
+
const t = ri();
|
|
1586
1587
|
return q(() => {
|
|
1587
1588
|
if (!e || fe(e)) return { blocks: [] };
|
|
1588
|
-
const n =
|
|
1589
|
-
return { blocks:
|
|
1589
|
+
const n = Gs(e, (s) => !wa(s == null ? void 0 : s._type, "@chai/"));
|
|
1590
|
+
return { blocks: Eo(t, n) };
|
|
1590
1591
|
}, [e, t]);
|
|
1591
|
-
},
|
|
1592
|
-
const [e] = ve(), t = e.get("page"), n = b(), { setAiContext: s } =
|
|
1592
|
+
}, yo = () => {
|
|
1593
|
+
const [e] = ve(), t = e.get("page"), n = b(), { setAiContext: s } = $s(), [, r] = Rs(), [, a] = pi(), [, i] = qr(), o = I();
|
|
1593
1594
|
return re({
|
|
1594
1595
|
queryKey: [E.GET_DRAFT_PAGE, t],
|
|
1595
1596
|
staleTime: 1 / 0,
|
|
@@ -1604,7 +1605,7 @@ const co = V(() => import("./dynamic-page-selector-Cb5r_W8s.js")), uo = () => {
|
|
|
1604
1605
|
},
|
|
1605
1606
|
enabled: !!t
|
|
1606
1607
|
});
|
|
1607
|
-
},
|
|
1608
|
+
}, Ao = () => {
|
|
1608
1609
|
const { data: e } = oe(), { data: t } = Le(), n = b(), s = I(), r = Mn(), a = kn();
|
|
1609
1610
|
return re({
|
|
1610
1611
|
queryKey: [E.GET_BUILDER_PAGE_DATA, t == null ? void 0 : t.id, a],
|
|
@@ -1634,7 +1635,7 @@ const co = V(() => import("./dynamic-page-selector-Cb5r_W8s.js")), uo = () => {
|
|
|
1634
1635
|
}),
|
|
1635
1636
|
enabled: !!(e != null && e.pageType) && !!t.id
|
|
1636
1637
|
});
|
|
1637
|
-
},
|
|
1638
|
+
}, To = () => {
|
|
1638
1639
|
const e = b(), t = J(), n = I();
|
|
1639
1640
|
return Y({
|
|
1640
1641
|
mutationFn: async (s) => n(e, {
|
|
@@ -1653,7 +1654,7 @@ const co = V(() => import("./dynamic-page-selector-Cb5r_W8s.js")), uo = () => {
|
|
|
1653
1654
|
});
|
|
1654
1655
|
}
|
|
1655
1656
|
});
|
|
1656
|
-
},
|
|
1657
|
+
}, au = () => {
|
|
1657
1658
|
const e = b(), t = J(), n = I(), { selectedLang: s } = Pe();
|
|
1658
1659
|
return Y({
|
|
1659
1660
|
mutationFn: async (r) => n(e, { action: E.ADD_GLOBAL_SCHEMA, data: { ...r, lang: s } }),
|
|
@@ -1668,7 +1669,7 @@ const co = V(() => import("./dynamic-page-selector-Cb5r_W8s.js")), uo = () => {
|
|
|
1668
1669
|
});
|
|
1669
1670
|
}
|
|
1670
1671
|
});
|
|
1671
|
-
},
|
|
1672
|
+
}, iu = () => {
|
|
1672
1673
|
const e = b(), t = J(), n = I(), { selectedLang: s } = Pe();
|
|
1673
1674
|
return Y({
|
|
1674
1675
|
mutationFn: async (r) => n(e, { action: E.UPDATE_GLOBAL_SCHEMA, data: { ...r, lang: s } }),
|
|
@@ -1683,7 +1684,7 @@ const co = V(() => import("./dynamic-page-selector-Cb5r_W8s.js")), uo = () => {
|
|
|
1683
1684
|
});
|
|
1684
1685
|
}
|
|
1685
1686
|
});
|
|
1686
|
-
},
|
|
1687
|
+
}, ou = () => {
|
|
1687
1688
|
const e = b(), t = J(), n = I();
|
|
1688
1689
|
return Y({
|
|
1689
1690
|
mutationFn: async (s) => n(e, { action: E.DELETE_GLOBAL_SCHEMA, data: { id: s } }),
|
|
@@ -1698,7 +1699,7 @@ const co = V(() => import("./dynamic-page-selector-Cb5r_W8s.js")), uo = () => {
|
|
|
1698
1699
|
});
|
|
1699
1700
|
}
|
|
1700
1701
|
});
|
|
1701
|
-
},
|
|
1702
|
+
}, lu = () => {
|
|
1702
1703
|
const e = b(), t = I();
|
|
1703
1704
|
return Y({
|
|
1704
1705
|
mutationFn: async (n) => t(e, { action: E.TOGGLE_PAGE_GLOBAL_SCHEMA, data: n }),
|
|
@@ -1708,7 +1709,7 @@ const co = V(() => import("./dynamic-page-selector-Cb5r_W8s.js")), uo = () => {
|
|
|
1708
1709
|
});
|
|
1709
1710
|
}
|
|
1710
1711
|
});
|
|
1711
|
-
},
|
|
1712
|
+
}, cu = () => {
|
|
1712
1713
|
const e = b(), t = I();
|
|
1713
1714
|
return Y({
|
|
1714
1715
|
mutationFn: async (n) => t(e, { action: E.APPLY_SCHEMA_TO_ALL_PAGES, data: { schemaId: n } }),
|
|
@@ -1721,7 +1722,7 @@ const co = V(() => import("./dynamic-page-selector-Cb5r_W8s.js")), uo = () => {
|
|
|
1721
1722
|
});
|
|
1722
1723
|
}
|
|
1723
1724
|
});
|
|
1724
|
-
},
|
|
1725
|
+
}, uu = () => {
|
|
1725
1726
|
const e = b(), t = I();
|
|
1726
1727
|
return Y({
|
|
1727
1728
|
mutationFn: async (n) => t(e, { action: E.REMOVE_SCHEMA_FROM_ALL_PAGES, data: { schemaId: n } }),
|
|
@@ -1734,13 +1735,13 @@ const co = V(() => import("./dynamic-page-selector-Cb5r_W8s.js")), uo = () => {
|
|
|
1734
1735
|
});
|
|
1735
1736
|
}
|
|
1736
1737
|
});
|
|
1737
|
-
},
|
|
1738
|
+
}, is = {
|
|
1738
1739
|
async getUILibraryBlock(e, t, n) {
|
|
1739
1740
|
const s = await t(n, {
|
|
1740
1741
|
action: "GET_LIBRARY_ITEM",
|
|
1741
1742
|
data: { id: e.id }
|
|
1742
1743
|
}), r = H(s, "html", ""), a = H(s, "blocks", []);
|
|
1743
|
-
return
|
|
1744
|
+
return Na(a) ? a : ii(r);
|
|
1744
1745
|
},
|
|
1745
1746
|
async getUILibraryBlocks(e, t, n) {
|
|
1746
1747
|
try {
|
|
@@ -1754,7 +1755,7 @@ const co = V(() => import("./dynamic-page-selector-Cb5r_W8s.js")), uo = () => {
|
|
|
1754
1755
|
return console.error(s), [];
|
|
1755
1756
|
}
|
|
1756
1757
|
}
|
|
1757
|
-
},
|
|
1758
|
+
}, So = () => {
|
|
1758
1759
|
const e = b(), t = I();
|
|
1759
1760
|
return re({
|
|
1760
1761
|
queryKey: ["uiLibraries"],
|
|
@@ -1764,16 +1765,16 @@ const co = V(() => import("./dynamic-page-selector-Cb5r_W8s.js")), uo = () => {
|
|
|
1764
1765
|
...r
|
|
1765
1766
|
}));
|
|
1766
1767
|
return s.forEach((r) => {
|
|
1767
|
-
|
|
1768
|
+
fa(r.id, {
|
|
1768
1769
|
name: r.isSiteLibrary ? r.name + " (Current Site) " : r.name,
|
|
1769
1770
|
description: r.description,
|
|
1770
|
-
getBlocksList: (a) =>
|
|
1771
|
-
getBlock: ({ block: a }) =>
|
|
1771
|
+
getBlocksList: (a) => is.getUILibraryBlocks(a, t, e),
|
|
1772
|
+
getBlock: ({ block: a }) => is.getUILibraryBlock(a, t, e)
|
|
1772
1773
|
});
|
|
1773
1774
|
}), s;
|
|
1774
1775
|
}
|
|
1775
1776
|
});
|
|
1776
|
-
},
|
|
1777
|
+
}, _o = () => {
|
|
1777
1778
|
const e = b(), t = I(), { user: n } = Rn(), s = n == null ? void 0 : n.id;
|
|
1778
1779
|
return re({
|
|
1779
1780
|
queryKey: [E.GET_ROLE_AND_PERMISSIONS, s],
|
|
@@ -1784,8 +1785,8 @@ const co = V(() => import("./dynamic-page-selector-Cb5r_W8s.js")), uo = () => {
|
|
|
1784
1785
|
enabled: !!s,
|
|
1785
1786
|
staleTime: 1 / 0
|
|
1786
1787
|
});
|
|
1787
|
-
},
|
|
1788
|
-
const e = b(), t = I(), [, n] =
|
|
1788
|
+
}, Po = () => {
|
|
1789
|
+
const e = b(), t = I(), [, n] = Rs();
|
|
1789
1790
|
return { onSave: async ({
|
|
1790
1791
|
page: r,
|
|
1791
1792
|
blocks: a,
|
|
@@ -1804,15 +1805,15 @@ const co = V(() => import("./dynamic-page-selector-Cb5r_W8s.js")), uo = () => {
|
|
|
1804
1805
|
return console.error(o), new Error("Failed to save blocks");
|
|
1805
1806
|
}
|
|
1806
1807
|
} };
|
|
1807
|
-
},
|
|
1808
|
-
const { data: e } =
|
|
1808
|
+
}, wo = () => {
|
|
1809
|
+
const { data: e } = Fs(), t = b(), n = I();
|
|
1809
1810
|
return {
|
|
1810
1811
|
getPartialBlocks: z(async () => {
|
|
1811
1812
|
const s = {};
|
|
1812
1813
|
for (const r of e ?? [])
|
|
1813
1814
|
fe(r == null ? void 0 : r.slug) && (s[r.id] = {
|
|
1814
1815
|
type: r.pageType,
|
|
1815
|
-
name:
|
|
1816
|
+
name: La(r.name ?? r.slug),
|
|
1816
1817
|
description: ""
|
|
1817
1818
|
});
|
|
1818
1819
|
return s;
|
|
@@ -1825,7 +1826,7 @@ const co = V(() => import("./dynamic-page-selector-Cb5r_W8s.js")), uo = () => {
|
|
|
1825
1826
|
action: "GET_DRAFT_PAGE",
|
|
1826
1827
|
data: { id: s, draft: !0, editor: !1 }
|
|
1827
1828
|
});
|
|
1828
|
-
return
|
|
1829
|
+
return Gs(r.blocks, (a) => sn(a, "_id"));
|
|
1829
1830
|
} catch (r) {
|
|
1830
1831
|
return console.error(r), [];
|
|
1831
1832
|
}
|
|
@@ -1833,7 +1834,7 @@ const co = V(() => import("./dynamic-page-selector-Cb5r_W8s.js")), uo = () => {
|
|
|
1833
1834
|
[n, t]
|
|
1834
1835
|
)
|
|
1835
1836
|
};
|
|
1836
|
-
},
|
|
1837
|
+
}, vo = V(() => import("./ai-panel-content-CNxN84pv.js")), Qs = "chai-chat-panel", bo = ({ className: e = "h-full w-full" }) => /* @__PURE__ */ m("svg", { xmlns: "http://www.w3.org/2000/svg", viewBox: "0 0 512 512", version: "1.1", className: e, children: [
|
|
1837
1838
|
/* @__PURE__ */ c("title", { children: "ai" }),
|
|
1838
1839
|
/* @__PURE__ */ c("g", { id: "Page-1", stroke: "none", strokeWidth: "1", fill: "none", fillRule: "evenodd", children: /* @__PURE__ */ c("g", { id: "icon", fill: "currentColor", transform: "translate(64.000000, 64.000000)", children: /* @__PURE__ */ c(
|
|
1839
1840
|
"path",
|
|
@@ -1842,25 +1843,25 @@ const co = V(() => import("./dynamic-page-selector-Cb5r_W8s.js")), uo = () => {
|
|
|
1842
1843
|
id: "Combined-Shape"
|
|
1843
1844
|
}
|
|
1844
1845
|
) }) })
|
|
1845
|
-
] }),
|
|
1846
|
-
id:
|
|
1846
|
+
] }), Io = ({ isActive: e, show: t }) => /* @__PURE__ */ c(M, { size: "icon", className: "p-0 [&_svg]:size-6", onClick: t, variant: e ? "default" : "ghost", children: /* @__PURE__ */ c(bo, { className: e ? "h-5 w-5 text-white" : "h-5 w-5 text-primary" }) }), No = {
|
|
1847
|
+
id: Qs,
|
|
1847
1848
|
label: "AI Assistant",
|
|
1848
|
-
button:
|
|
1849
|
-
panel:
|
|
1849
|
+
button: Io,
|
|
1850
|
+
panel: vo,
|
|
1850
1851
|
position: "top"
|
|
1851
|
-
},
|
|
1852
|
+
}, Lo = V(() => import("./lang-panel-DL_BtSRD.js")), Co = ({ isActive: e, show: t }) => {
|
|
1852
1853
|
const { data: n } = Be();
|
|
1853
|
-
return !sn(n, "languages") || !H(n, "languages", []).length ? null : /* @__PURE__ */ c(M, { size: "sm", onClick: t, variant: e ? "default" : "ghost", children: /* @__PURE__ */ c(
|
|
1854
|
-
},
|
|
1855
|
-
id:
|
|
1854
|
+
return !sn(n, "languages") || !H(n, "languages", []).length ? null : /* @__PURE__ */ c(M, { size: "sm", onClick: t, variant: e ? "default" : "ghost", children: /* @__PURE__ */ c(Ya, { className: "h-4 w-4" }) });
|
|
1855
|
+
}, zs = "lang", Go = {
|
|
1856
|
+
id: zs,
|
|
1856
1857
|
label: "Languages",
|
|
1857
1858
|
position: "top",
|
|
1858
|
-
panel:
|
|
1859
|
-
button:
|
|
1859
|
+
panel: Lo,
|
|
1860
|
+
button: Co,
|
|
1860
1861
|
view: "modal",
|
|
1861
1862
|
width: 400
|
|
1862
|
-
},
|
|
1863
|
-
const { data: n } = oe(), s =
|
|
1863
|
+
}, Oo = V(() => import("./seo-panel-B798Myp_.js")), Ws = "seo", xo = ({ isActive: e, show: t }) => {
|
|
1864
|
+
const { data: n } = oe(), s = Ai(n == null ? void 0 : n.pageType);
|
|
1864
1865
|
return !sn(s, "hasSlug") || !s.hasSlug ? null : /* @__PURE__ */ c(M, { size: "icon", className: "my-1 p-0", onClick: t, variant: e ? "default" : "ghost", children: /* @__PURE__ */ m(
|
|
1865
1866
|
"svg",
|
|
1866
1867
|
{
|
|
@@ -1879,35 +1880,35 @@ const co = V(() => import("./dynamic-page-selector-Cb5r_W8s.js")), uo = () => {
|
|
|
1879
1880
|
]
|
|
1880
1881
|
}
|
|
1881
1882
|
) });
|
|
1882
|
-
},
|
|
1883
|
-
id:
|
|
1883
|
+
}, Do = {
|
|
1884
|
+
id: Ws,
|
|
1884
1885
|
label: "SEO",
|
|
1885
|
-
panel:
|
|
1886
|
-
button:
|
|
1886
|
+
panel: Oo,
|
|
1887
|
+
button: xo,
|
|
1887
1888
|
position: "top",
|
|
1888
1889
|
width: 600,
|
|
1889
1890
|
view: "modal"
|
|
1890
|
-
},
|
|
1891
|
-
const { t: e } = we(), { user: t, logout: n } = Rn(), s = ge("onLogout",
|
|
1892
|
-
return t ? /* @__PURE__ */ m(
|
|
1893
|
-
/* @__PURE__ */ c(
|
|
1894
|
-
/* @__PURE__ */ m(
|
|
1891
|
+
}, js = "user-info", ko = () => {
|
|
1892
|
+
const { t: e } = we(), { user: t, logout: n } = Rn(), s = ge("onLogout", bs);
|
|
1893
|
+
return t ? /* @__PURE__ */ m($r, { children: [
|
|
1894
|
+
/* @__PURE__ */ c(Qr, { asChild: !0, children: /* @__PURE__ */ c(M, { variant: "ghost", className: "text-sm font-medium", children: /* @__PURE__ */ c(Ja, { className: "h-4 w-4" }) }) }),
|
|
1895
|
+
/* @__PURE__ */ m(zr, { className: "w-auto space-y-2 p-4", children: [
|
|
1895
1896
|
/* @__PURE__ */ c("div", { className: "text-sm font-medium", children: t.name ?? t.email }),
|
|
1896
1897
|
/* @__PURE__ */ c("div", { className: "text-xs text-muted-foreground", children: t.email }),
|
|
1897
|
-
/* @__PURE__ */ m(
|
|
1898
|
-
/* @__PURE__ */ c(
|
|
1899
|
-
/* @__PURE__ */ m(
|
|
1900
|
-
/* @__PURE__ */ m(
|
|
1901
|
-
/* @__PURE__ */ c(
|
|
1902
|
-
/* @__PURE__ */ c(
|
|
1898
|
+
/* @__PURE__ */ m(Wr, { children: [
|
|
1899
|
+
/* @__PURE__ */ c(jr, { asChild: !0, children: /* @__PURE__ */ c(M, { variant: "outline", size: "sm", className: "w-full", children: e("Logout") }) }),
|
|
1900
|
+
/* @__PURE__ */ m(Yr, { children: [
|
|
1901
|
+
/* @__PURE__ */ m(Jr, { children: [
|
|
1902
|
+
/* @__PURE__ */ c(Zr, { children: e("Are you sure you want to logout?") }),
|
|
1903
|
+
/* @__PURE__ */ c(Xr, { children: e("You will be redirected to the login page.") })
|
|
1903
1904
|
] }),
|
|
1904
|
-
/* @__PURE__ */ m(
|
|
1905
|
-
/* @__PURE__ */ c(
|
|
1905
|
+
/* @__PURE__ */ m(ea, { children: [
|
|
1906
|
+
/* @__PURE__ */ c(ta, { children: e("Cancel") }),
|
|
1906
1907
|
/* @__PURE__ */ c(
|
|
1907
|
-
|
|
1908
|
+
na,
|
|
1908
1909
|
{
|
|
1909
1910
|
onClick: () => {
|
|
1910
|
-
n(),
|
|
1911
|
+
n(), Ca(s) && s();
|
|
1911
1912
|
},
|
|
1912
1913
|
children: e("Logout")
|
|
1913
1914
|
}
|
|
@@ -1917,13 +1918,13 @@ const co = V(() => import("./dynamic-page-selector-Cb5r_W8s.js")), uo = () => {
|
|
|
1917
1918
|
] })
|
|
1918
1919
|
] })
|
|
1919
1920
|
] }) : null;
|
|
1920
|
-
},
|
|
1921
|
-
id:
|
|
1921
|
+
}, Ro = {
|
|
1922
|
+
id: js,
|
|
1922
1923
|
label: "User Info",
|
|
1923
|
-
button:
|
|
1924
|
+
button: ko,
|
|
1924
1925
|
position: "bottom"
|
|
1925
|
-
},
|
|
1926
|
-
kt(
|
|
1926
|
+
}, Uo = () => {
|
|
1927
|
+
kt(Ws, Do), kt(zs, Go), kt(js, Ro), kt(Qs, No);
|
|
1927
1928
|
};
|
|
1928
1929
|
var _ = {
|
|
1929
1930
|
context: void 0,
|
|
@@ -1931,29 +1932,29 @@ var _ = {
|
|
|
1931
1932
|
effects: void 0,
|
|
1932
1933
|
done: !1,
|
|
1933
1934
|
getContextId() {
|
|
1934
|
-
return
|
|
1935
|
+
return os(this.context.count);
|
|
1935
1936
|
},
|
|
1936
1937
|
getNextContextId() {
|
|
1937
|
-
return
|
|
1938
|
+
return os(this.context.count++);
|
|
1938
1939
|
}
|
|
1939
1940
|
};
|
|
1940
|
-
function
|
|
1941
|
+
function os(e) {
|
|
1941
1942
|
const t = String(e), n = t.length - 1;
|
|
1942
1943
|
return _.context.id + (n ? String.fromCharCode(96 + n) : "") + t;
|
|
1943
1944
|
}
|
|
1944
1945
|
function ct(e) {
|
|
1945
1946
|
_.context = e;
|
|
1946
1947
|
}
|
|
1947
|
-
var
|
|
1948
|
-
equals:
|
|
1949
|
-
},
|
|
1948
|
+
var Ys = !1, Mo = (e, t) => e === t, Wt = Symbol("solid-proxy"), Js = typeof Proxy == "function", Zs = Symbol("solid-track"), jt = {
|
|
1949
|
+
equals: Mo
|
|
1950
|
+
}, Xs = ir, be = 1, Yt = 2, er = {
|
|
1950
1951
|
owned: null,
|
|
1951
1952
|
cleanups: null,
|
|
1952
1953
|
context: null,
|
|
1953
1954
|
owner: null
|
|
1954
|
-
}, gn = {}, G = null, mn = null,
|
|
1955
|
+
}, gn = {}, G = null, mn = null, Bo = null, D = null, ee = null, _e = null, an = 0;
|
|
1955
1956
|
function De(e, t) {
|
|
1956
|
-
const n = D, s = G, r = e.length === 0, a = t === void 0 ? s : t, i = r ?
|
|
1957
|
+
const n = D, s = G, r = e.length === 0, a = t === void 0 ? s : t, i = r ? er : {
|
|
1957
1958
|
owned: null,
|
|
1958
1959
|
cleanups: null,
|
|
1959
1960
|
context: a ? a.context : null,
|
|
@@ -1973,10 +1974,10 @@ function F(e, t) {
|
|
|
1973
1974
|
observers: null,
|
|
1974
1975
|
observerSlots: null,
|
|
1975
1976
|
comparator: t.equals || void 0
|
|
1976
|
-
}, s = (r) => (typeof r == "function" && (r = r(n.value)),
|
|
1977
|
-
return [
|
|
1977
|
+
}, s = (r) => (typeof r == "function" && (r = r(n.value)), ar(n, r));
|
|
1978
|
+
return [rr.bind(n), s];
|
|
1978
1979
|
}
|
|
1979
|
-
function
|
|
1980
|
+
function Fo(e, t, n) {
|
|
1980
1981
|
const s = on(e, t, !0, be);
|
|
1981
1982
|
lt(s);
|
|
1982
1983
|
}
|
|
@@ -1984,20 +1985,20 @@ function ke(e, t, n) {
|
|
|
1984
1985
|
const s = on(e, t, !1, be);
|
|
1985
1986
|
lt(s);
|
|
1986
1987
|
}
|
|
1987
|
-
function
|
|
1988
|
-
|
|
1988
|
+
function tr(e, t, n) {
|
|
1989
|
+
Xs = jo;
|
|
1989
1990
|
const s = on(e, t, !1, be);
|
|
1990
1991
|
(!n || !n.render) && (s.user = !0), _e ? _e.push(s) : lt(s);
|
|
1991
1992
|
}
|
|
1992
1993
|
function j(e, t, n) {
|
|
1993
1994
|
n = n ? Object.assign({}, jt, n) : jt;
|
|
1994
1995
|
const s = on(e, t, !0, 0);
|
|
1995
|
-
return s.observers = null, s.observerSlots = null, s.comparator = n.equals || void 0, lt(s),
|
|
1996
|
+
return s.observers = null, s.observerSlots = null, s.comparator = n.equals || void 0, lt(s), rr.bind(s);
|
|
1996
1997
|
}
|
|
1997
|
-
function
|
|
1998
|
+
function Ko(e) {
|
|
1998
1999
|
return e && typeof e == "object" && "then" in e;
|
|
1999
2000
|
}
|
|
2000
|
-
function
|
|
2001
|
+
function Vo(e, t, n) {
|
|
2001
2002
|
let s, r, a;
|
|
2002
2003
|
s = !0, r = e, a = {};
|
|
2003
2004
|
let i = null, o = gn, l = null, f = !1, d = "initialValue" in a, u = typeof s == "function" && j(s);
|
|
@@ -2018,7 +2019,7 @@ function Ko(e, t, n) {
|
|
|
2018
2019
|
}, !1);
|
|
2019
2020
|
}
|
|
2020
2021
|
function Ae() {
|
|
2021
|
-
const P =
|
|
2022
|
+
const P = Qo, L = h(), W = T();
|
|
2022
2023
|
if (W !== void 0 && !i) throw W;
|
|
2023
2024
|
return D && D.user, L;
|
|
2024
2025
|
}
|
|
@@ -2044,7 +2045,7 @@ function Ko(e, t, n) {
|
|
|
2044
2045
|
if (W !== void 0) {
|
|
2045
2046
|
U(i, void 0, Vt(W), L);
|
|
2046
2047
|
return;
|
|
2047
|
-
} else if (!
|
|
2048
|
+
} else if (!Ko(Q))
|
|
2048
2049
|
return U(i, Q, void 0, L), Q;
|
|
2049
2050
|
return i = Q, "v" in Q ? (Q.s === 1 ? U(i, Q.v, void 0, L) : U(i, void 0, Vt(Q.v), L), Q) : (f = !0, queueMicrotask(() => f = !1), me(() => {
|
|
2050
2051
|
v(d ? "refreshing" : "pending"), y();
|
|
@@ -2073,12 +2074,12 @@ function Ko(e, t, n) {
|
|
|
2073
2074
|
}
|
|
2074
2075
|
});
|
|
2075
2076
|
let B = G;
|
|
2076
|
-
return u ?
|
|
2077
|
-
refetch: (P) =>
|
|
2077
|
+
return u ? Fo(() => (B = G, Te(!1))) : Te(!1), [Ae, {
|
|
2078
|
+
refetch: (P) => nr(B, () => Te(P)),
|
|
2078
2079
|
mutate: p
|
|
2079
2080
|
}];
|
|
2080
2081
|
}
|
|
2081
|
-
function
|
|
2082
|
+
function du(e) {
|
|
2082
2083
|
return me(e, !1);
|
|
2083
2084
|
}
|
|
2084
2085
|
function Z(e) {
|
|
@@ -2091,7 +2092,7 @@ function Z(e) {
|
|
|
2091
2092
|
D = t;
|
|
2092
2093
|
}
|
|
2093
2094
|
}
|
|
2094
|
-
function
|
|
2095
|
+
function fu(e, t, n) {
|
|
2095
2096
|
const s = Array.isArray(e);
|
|
2096
2097
|
let r, a = n && n.defer;
|
|
2097
2098
|
return (i) => {
|
|
@@ -2106,16 +2107,16 @@ function uu(e, t, n) {
|
|
|
2106
2107
|
return r = o, l;
|
|
2107
2108
|
};
|
|
2108
2109
|
}
|
|
2109
|
-
function
|
|
2110
|
-
|
|
2110
|
+
function Ho(e) {
|
|
2111
|
+
tr(() => Z(e));
|
|
2111
2112
|
}
|
|
2112
2113
|
function ft(e) {
|
|
2113
2114
|
return G === null || (G.cleanups === null ? G.cleanups = [e] : G.cleanups.push(e)), e;
|
|
2114
2115
|
}
|
|
2115
|
-
function
|
|
2116
|
+
function ls() {
|
|
2116
2117
|
return G;
|
|
2117
2118
|
}
|
|
2118
|
-
function
|
|
2119
|
+
function nr(e, t) {
|
|
2119
2120
|
const n = G, s = D;
|
|
2120
2121
|
G = e, D = null;
|
|
2121
2122
|
try {
|
|
@@ -2126,7 +2127,7 @@ function tr(e, t) {
|
|
|
2126
2127
|
G = n, D = s;
|
|
2127
2128
|
}
|
|
2128
2129
|
}
|
|
2129
|
-
function
|
|
2130
|
+
function qo(e) {
|
|
2130
2131
|
const t = D, n = G;
|
|
2131
2132
|
return Promise.resolve().then(() => {
|
|
2132
2133
|
D = t, G = n;
|
|
@@ -2134,31 +2135,31 @@ function Ho(e) {
|
|
|
2134
2135
|
return me(e, !1), D = G = null, s ? s.done : void 0;
|
|
2135
2136
|
});
|
|
2136
2137
|
}
|
|
2137
|
-
var [
|
|
2138
|
-
function
|
|
2139
|
-
return [
|
|
2138
|
+
var [$o, hu] = /* @__PURE__ */ F(!1);
|
|
2139
|
+
function gu() {
|
|
2140
|
+
return [$o, qo];
|
|
2140
2141
|
}
|
|
2141
|
-
function
|
|
2142
|
+
function mu(e, t) {
|
|
2142
2143
|
const n = Symbol("context");
|
|
2143
2144
|
return {
|
|
2144
2145
|
id: n,
|
|
2145
|
-
Provider:
|
|
2146
|
+
Provider: Yo(n),
|
|
2146
2147
|
defaultValue: e
|
|
2147
2148
|
};
|
|
2148
2149
|
}
|
|
2149
|
-
function
|
|
2150
|
+
function Eu(e) {
|
|
2150
2151
|
let t;
|
|
2151
2152
|
return G && G.context && (t = G.context[e.id]) !== void 0 ? t : e.defaultValue;
|
|
2152
2153
|
}
|
|
2153
|
-
function
|
|
2154
|
+
function sr(e) {
|
|
2154
2155
|
const t = j(e), n = j(() => An(t()));
|
|
2155
2156
|
return n.toArray = () => {
|
|
2156
2157
|
const s = n();
|
|
2157
2158
|
return Array.isArray(s) ? s : s != null ? [s] : [];
|
|
2158
2159
|
}, n;
|
|
2159
2160
|
}
|
|
2160
|
-
var
|
|
2161
|
-
function
|
|
2161
|
+
var Qo;
|
|
2162
|
+
function rr() {
|
|
2162
2163
|
if (this.sources && this.state)
|
|
2163
2164
|
if (this.state === be) lt(this);
|
|
2164
2165
|
else {
|
|
@@ -2171,12 +2172,12 @@ function sr() {
|
|
|
2171
2172
|
}
|
|
2172
2173
|
return this.value;
|
|
2173
2174
|
}
|
|
2174
|
-
function
|
|
2175
|
+
function ar(e, t, n) {
|
|
2175
2176
|
let s = e.value;
|
|
2176
2177
|
return (!e.comparator || !e.comparator(s, t)) && (e.value = t, e.observers && e.observers.length && me(() => {
|
|
2177
2178
|
for (let r = 0; r < e.observers.length; r += 1) {
|
|
2178
2179
|
const a = e.observers[r], i = mn && mn.running;
|
|
2179
|
-
i && mn.disposed.has(a), (i ? !a.tState : !a.state) && (a.pure ? ee.push(a) : _e.push(a), a.observers &&
|
|
2180
|
+
i && mn.disposed.has(a), (i ? !a.tState : !a.state) && (a.pure ? ee.push(a) : _e.push(a), a.observers && or(a)), i || (a.state = be);
|
|
2180
2181
|
}
|
|
2181
2182
|
if (ee.length > 1e6)
|
|
2182
2183
|
throw ee = [], new Error();
|
|
@@ -2186,9 +2187,9 @@ function lt(e) {
|
|
|
2186
2187
|
if (!e.fn) return;
|
|
2187
2188
|
ht(e);
|
|
2188
2189
|
const t = an;
|
|
2189
|
-
|
|
2190
|
+
zo(e, e.value, t);
|
|
2190
2191
|
}
|
|
2191
|
-
function
|
|
2192
|
+
function zo(e, t, n) {
|
|
2192
2193
|
let s;
|
|
2193
2194
|
const r = G, a = D;
|
|
2194
2195
|
D = G = e;
|
|
@@ -2199,7 +2200,7 @@ function Qo(e, t, n) {
|
|
|
2199
2200
|
} finally {
|
|
2200
2201
|
D = a, G = r;
|
|
2201
2202
|
}
|
|
2202
|
-
(!e.updatedAt || e.updatedAt <= n) && (e.updatedAt != null && "observers" in e ?
|
|
2203
|
+
(!e.updatedAt || e.updatedAt <= n) && (e.updatedAt != null && "observers" in e ? ar(e, s) : e.value = s, e.updatedAt = n);
|
|
2203
2204
|
}
|
|
2204
2205
|
function on(e, t, n, s = be, r) {
|
|
2205
2206
|
const a = {
|
|
@@ -2215,7 +2216,7 @@ function on(e, t, n, s = be, r) {
|
|
|
2215
2216
|
context: G ? G.context : null,
|
|
2216
2217
|
pure: n
|
|
2217
2218
|
};
|
|
2218
|
-
return G === null || G !==
|
|
2219
|
+
return G === null || G !== er && (G.owned ? G.owned.push(a) : G.owned = [a]), a;
|
|
2219
2220
|
}
|
|
2220
2221
|
function Jt(e) {
|
|
2221
2222
|
if (e.state === 0) return;
|
|
@@ -2238,20 +2239,20 @@ function me(e, t) {
|
|
|
2238
2239
|
t || (ee = []), _e ? n = !0 : _e = [], an++;
|
|
2239
2240
|
try {
|
|
2240
2241
|
const s = e();
|
|
2241
|
-
return
|
|
2242
|
+
return Wo(n), s;
|
|
2242
2243
|
} catch (s) {
|
|
2243
2244
|
n || (_e = null), ee = null, Fn(s);
|
|
2244
2245
|
}
|
|
2245
2246
|
}
|
|
2246
|
-
function
|
|
2247
|
-
if (ee && (
|
|
2247
|
+
function Wo(e) {
|
|
2248
|
+
if (ee && (ir(ee), ee = null), e) return;
|
|
2248
2249
|
const t = _e;
|
|
2249
|
-
_e = null, t.length && me(() =>
|
|
2250
|
+
_e = null, t.length && me(() => Xs(t), !1);
|
|
2250
2251
|
}
|
|
2251
|
-
function
|
|
2252
|
+
function ir(e) {
|
|
2252
2253
|
for (let t = 0; t < e.length; t++) Jt(e[t]);
|
|
2253
2254
|
}
|
|
2254
|
-
function
|
|
2255
|
+
function jo(e) {
|
|
2255
2256
|
let t, n = 0;
|
|
2256
2257
|
for (t = 0; t < e.length; t++) {
|
|
2257
2258
|
const s = e[t];
|
|
@@ -2276,10 +2277,10 @@ function Zt(e, t) {
|
|
|
2276
2277
|
}
|
|
2277
2278
|
}
|
|
2278
2279
|
}
|
|
2279
|
-
function
|
|
2280
|
+
function or(e) {
|
|
2280
2281
|
for (let t = 0; t < e.observers.length; t += 1) {
|
|
2281
2282
|
const n = e.observers[t];
|
|
2282
|
-
n.state || (n.state = Yt, n.pure ? ee.push(n) : _e.push(n), n.observers &&
|
|
2283
|
+
n.state || (n.state = Yt, n.pure ? ee.push(n) : _e.push(n), n.observers && or(n));
|
|
2283
2284
|
}
|
|
2284
2285
|
}
|
|
2285
2286
|
function ht(e) {
|
|
@@ -2326,24 +2327,24 @@ function An(e) {
|
|
|
2326
2327
|
}
|
|
2327
2328
|
return e;
|
|
2328
2329
|
}
|
|
2329
|
-
function
|
|
2330
|
+
function Yo(e, t) {
|
|
2330
2331
|
return function(s) {
|
|
2331
2332
|
let r;
|
|
2332
2333
|
return ke(() => r = Z(() => (G.context = {
|
|
2333
2334
|
...G.context,
|
|
2334
2335
|
[e]: s.value
|
|
2335
|
-
},
|
|
2336
|
+
}, sr(() => s.children))), void 0), r;
|
|
2336
2337
|
};
|
|
2337
2338
|
}
|
|
2338
2339
|
var Tn = Symbol("fallback");
|
|
2339
2340
|
function Xt(e) {
|
|
2340
2341
|
for (let t = 0; t < e.length; t++) e[t]();
|
|
2341
2342
|
}
|
|
2342
|
-
function
|
|
2343
|
+
function Jo(e, t, n = {}) {
|
|
2343
2344
|
let s = [], r = [], a = [], i = 0, o = t.length > 1 ? [] : null;
|
|
2344
2345
|
return ft(() => Xt(a)), () => {
|
|
2345
2346
|
let l = e() || [], f = l.length, d, u;
|
|
2346
|
-
return l[
|
|
2347
|
+
return l[Zs], Z(() => {
|
|
2347
2348
|
let h, p, T, S, x, y, w, v, U;
|
|
2348
2349
|
if (f === 0)
|
|
2349
2350
|
i !== 0 && (Xt(a), a = [], s = [], r = [], i = 0, o && (o = [])), n.fallback && (s = [Tn], r[0] = De((N) => (a[0] = N, n.fallback())), i = 1);
|
|
@@ -2374,11 +2375,11 @@ function Yo(e, t, n = {}) {
|
|
|
2374
2375
|
}
|
|
2375
2376
|
};
|
|
2376
2377
|
}
|
|
2377
|
-
function
|
|
2378
|
+
function Zo(e, t, n = {}) {
|
|
2378
2379
|
let s = [], r = [], a = [], i = [], o = 0, l;
|
|
2379
2380
|
return ft(() => Xt(a)), () => {
|
|
2380
2381
|
const f = e() || [], d = f.length;
|
|
2381
|
-
return f[
|
|
2382
|
+
return f[Zs], Z(() => {
|
|
2382
2383
|
if (d === 0)
|
|
2383
2384
|
return o !== 0 && (Xt(a), a = [], s = [], r = [], o = 0, i = []), n.fallback && (s = [Tn], r[0] = De((g) => (a[0] = g, n.fallback())), o = 1), r;
|
|
2384
2385
|
for (s[0] === Tn && (a[0](), a = [], s = [], r = [], o = 0), l = 0; l < d; l++)
|
|
@@ -2394,7 +2395,7 @@ function Jo(e, t, n = {}) {
|
|
|
2394
2395
|
}
|
|
2395
2396
|
};
|
|
2396
2397
|
}
|
|
2397
|
-
function
|
|
2398
|
+
function lr(e, t) {
|
|
2398
2399
|
return Z(() => e(t || {}));
|
|
2399
2400
|
}
|
|
2400
2401
|
function Ut() {
|
|
@@ -2427,19 +2428,19 @@ var Sn = {
|
|
|
2427
2428
|
function En(e) {
|
|
2428
2429
|
return (e = typeof e == "function" ? e() : e) ? e : {};
|
|
2429
2430
|
}
|
|
2430
|
-
function
|
|
2431
|
+
function Xo() {
|
|
2431
2432
|
for (let e = 0, t = this.length; e < t; ++e) {
|
|
2432
2433
|
const n = this[e]();
|
|
2433
2434
|
if (n !== void 0) return n;
|
|
2434
2435
|
}
|
|
2435
2436
|
}
|
|
2436
|
-
function
|
|
2437
|
+
function cr(...e) {
|
|
2437
2438
|
let t = !1;
|
|
2438
2439
|
for (let i = 0; i < e.length; i++) {
|
|
2439
2440
|
const o = e[i];
|
|
2440
2441
|
t = t || !!o && Wt in o, e[i] = typeof o == "function" ? (t = !0, j(o)) : o;
|
|
2441
2442
|
}
|
|
2442
|
-
if (
|
|
2443
|
+
if (Js && t)
|
|
2443
2444
|
return new Proxy({
|
|
2444
2445
|
get(i) {
|
|
2445
2446
|
for (let o = e.length - 1; o >= 0; o--) {
|
|
@@ -2471,7 +2472,7 @@ function lr(...e) {
|
|
|
2471
2472
|
s[d] = u.get ? {
|
|
2472
2473
|
enumerable: !0,
|
|
2473
2474
|
configurable: !0,
|
|
2474
|
-
get:
|
|
2475
|
+
get: Xo.bind(n[d] = [u.get.bind(o)])
|
|
2475
2476
|
} : u.value !== void 0 ? u : void 0;
|
|
2476
2477
|
else {
|
|
2477
2478
|
const g = n[d];
|
|
@@ -2486,8 +2487,8 @@ function lr(...e) {
|
|
|
2486
2487
|
}
|
|
2487
2488
|
return r;
|
|
2488
2489
|
}
|
|
2489
|
-
function
|
|
2490
|
-
if (
|
|
2490
|
+
function el(e, ...t) {
|
|
2491
|
+
if (Js && Wt in e) {
|
|
2491
2492
|
const r = new Set(t.length > 1 ? t.flat() : t[0]), a = t.map((i) => new Proxy({
|
|
2492
2493
|
get(o) {
|
|
2493
2494
|
return i.includes(o) ? e[o] : void 0;
|
|
@@ -2521,7 +2522,7 @@ function Xo(e, ...t) {
|
|
|
2521
2522
|
}
|
|
2522
2523
|
return [...s, n];
|
|
2523
2524
|
}
|
|
2524
|
-
function
|
|
2525
|
+
function ur(e) {
|
|
2525
2526
|
let t, n;
|
|
2526
2527
|
const s = (r) => {
|
|
2527
2528
|
const a = _.context;
|
|
@@ -2531,7 +2532,7 @@ function cr(e) {
|
|
|
2531
2532
|
!_.done && ct(a), _.count--, l(() => f.default), ct();
|
|
2532
2533
|
}), t = o;
|
|
2533
2534
|
} else if (!t) {
|
|
2534
|
-
const [o] =
|
|
2535
|
+
const [o] = Vo(() => (n || (n = e())).then((l) => l.default));
|
|
2535
2536
|
t = o;
|
|
2536
2537
|
}
|
|
2537
2538
|
let i;
|
|
@@ -2545,24 +2546,24 @@ function cr(e) {
|
|
|
2545
2546
|
};
|
|
2546
2547
|
return s.preload = () => n || ((n = e()).then((r) => t = () => r.default), n), s;
|
|
2547
2548
|
}
|
|
2548
|
-
var
|
|
2549
|
-
function
|
|
2550
|
-
return _.context ? _.getNextContextId() : `cl-${
|
|
2549
|
+
var tl = 0;
|
|
2550
|
+
function pu() {
|
|
2551
|
+
return _.context ? _.getNextContextId() : `cl-${tl++}`;
|
|
2551
2552
|
}
|
|
2552
|
-
var
|
|
2553
|
-
function
|
|
2553
|
+
var dr = (e) => `Stale read from <${e}>.`;
|
|
2554
|
+
function yu(e) {
|
|
2554
2555
|
const t = "fallback" in e && {
|
|
2555
2556
|
fallback: () => e.fallback
|
|
2556
2557
|
};
|
|
2557
|
-
return j(
|
|
2558
|
+
return j(Jo(() => e.each, e.children, t || void 0));
|
|
2558
2559
|
}
|
|
2559
|
-
function
|
|
2560
|
+
function Au(e) {
|
|
2560
2561
|
const t = "fallback" in e && {
|
|
2561
2562
|
fallback: () => e.fallback
|
|
2562
2563
|
};
|
|
2563
|
-
return j(
|
|
2564
|
+
return j(Zo(() => e.each, e.children, t || void 0));
|
|
2564
2565
|
}
|
|
2565
|
-
function
|
|
2566
|
+
function Tu(e) {
|
|
2566
2567
|
const t = e.keyed, n = j(() => e.when, void 0, void 0), s = t ? n : j(n, void 0, {
|
|
2567
2568
|
equals: (r, a) => !r == !a
|
|
2568
2569
|
});
|
|
@@ -2571,15 +2572,15 @@ function yu(e) {
|
|
|
2571
2572
|
if (r) {
|
|
2572
2573
|
const a = e.children;
|
|
2573
2574
|
return typeof a == "function" && a.length > 0 ? Z(() => a(t ? r : () => {
|
|
2574
|
-
if (!Z(s)) throw
|
|
2575
|
+
if (!Z(s)) throw dr("Show");
|
|
2575
2576
|
return n();
|
|
2576
2577
|
})) : a;
|
|
2577
2578
|
}
|
|
2578
2579
|
return e.fallback;
|
|
2579
2580
|
}, void 0, void 0);
|
|
2580
2581
|
}
|
|
2581
|
-
function
|
|
2582
|
-
const t =
|
|
2582
|
+
function Su(e) {
|
|
2583
|
+
const t = sr(() => e.children), n = j(() => {
|
|
2583
2584
|
const s = t(), r = Array.isArray(s) ? s : [s];
|
|
2584
2585
|
let a = () => {
|
|
2585
2586
|
};
|
|
@@ -2597,18 +2598,18 @@ function Au(e) {
|
|
|
2597
2598
|
const [r, a, i] = s, o = i.children;
|
|
2598
2599
|
return typeof o == "function" && o.length > 0 ? Z(() => o(i.keyed ? a() : () => {
|
|
2599
2600
|
var f;
|
|
2600
|
-
if (((f = Z(n)()) == null ? void 0 : f[0]) !== r) throw
|
|
2601
|
+
if (((f = Z(n)()) == null ? void 0 : f[0]) !== r) throw dr("Match");
|
|
2601
2602
|
return a();
|
|
2602
2603
|
})) : o;
|
|
2603
2604
|
}, void 0, void 0);
|
|
2604
2605
|
}
|
|
2605
|
-
function
|
|
2606
|
+
function _u(e) {
|
|
2606
2607
|
return e;
|
|
2607
2608
|
}
|
|
2608
|
-
var
|
|
2609
|
+
var nl = ["allowfullscreen", "async", "autofocus", "autoplay", "checked", "controls", "default", "disabled", "formnovalidate", "hidden", "indeterminate", "inert", "ismap", "loop", "multiple", "muted", "nomodule", "novalidate", "open", "playsinline", "readonly", "required", "reversed", "seamless", "selected"], sl = /* @__PURE__ */ new Set(["className", "value", "readOnly", "noValidate", "formNoValidate", "isMap", "noModule", "playsInline", ...nl]), rl = /* @__PURE__ */ new Set(["innerHTML", "textContent", "innerText", "children"]), al = /* @__PURE__ */ Object.assign(/* @__PURE__ */ Object.create(null), {
|
|
2609
2610
|
className: "class",
|
|
2610
2611
|
htmlFor: "for"
|
|
2611
|
-
}),
|
|
2612
|
+
}), il = /* @__PURE__ */ Object.assign(/* @__PURE__ */ Object.create(null), {
|
|
2612
2613
|
class: "className",
|
|
2613
2614
|
novalidate: {
|
|
2614
2615
|
$: "noValidate",
|
|
@@ -2637,11 +2638,11 @@ var tl = ["allowfullscreen", "async", "autofocus", "autoplay", "checked", "contr
|
|
|
2637
2638
|
TEXTAREA: 1
|
|
2638
2639
|
}
|
|
2639
2640
|
});
|
|
2640
|
-
function
|
|
2641
|
-
const n =
|
|
2641
|
+
function ol(e, t) {
|
|
2642
|
+
const n = il[e];
|
|
2642
2643
|
return typeof n == "object" ? n[t] ? n.$ : void 0 : n;
|
|
2643
2644
|
}
|
|
2644
|
-
var
|
|
2645
|
+
var ll = /* @__PURE__ */ new Set(["beforeinput", "click", "dblclick", "contextmenu", "focusin", "focusout", "input", "keydown", "keyup", "mousedown", "mousemove", "mouseout", "mouseover", "mouseup", "pointerdown", "pointermove", "pointerout", "pointerover", "pointerup", "touchend", "touchmove", "touchstart"]), cl = /* @__PURE__ */ new Set([
|
|
2645
2646
|
"altGlyph",
|
|
2646
2647
|
"altGlyphDef",
|
|
2647
2648
|
"altGlyphItem",
|
|
@@ -2719,11 +2720,11 @@ var ol = /* @__PURE__ */ new Set(["beforeinput", "click", "dblclick", "contextme
|
|
|
2719
2720
|
"use",
|
|
2720
2721
|
"view",
|
|
2721
2722
|
"vkern"
|
|
2722
|
-
]),
|
|
2723
|
+
]), ul = {
|
|
2723
2724
|
xlink: "http://www.w3.org/1999/xlink",
|
|
2724
2725
|
xml: "http://www.w3.org/XML/1998/namespace"
|
|
2725
|
-
},
|
|
2726
|
-
function
|
|
2726
|
+
}, Pu = (e) => j(() => e());
|
|
2727
|
+
function dl(e, t, n) {
|
|
2727
2728
|
let s = n.length, r = t.length, a = s, i = 0, o = 0, l = t[r - 1].nextSibling, f = null;
|
|
2728
2729
|
for (; i < r || o < a; ) {
|
|
2729
2730
|
if (t[i] === n[o]) {
|
|
@@ -2763,7 +2764,7 @@ function ul(e, t, n) {
|
|
|
2763
2764
|
}
|
|
2764
2765
|
}
|
|
2765
2766
|
var ut = "_$DX_DELEGATE";
|
|
2766
|
-
function
|
|
2767
|
+
function fr(e, t, n, s = {}) {
|
|
2767
2768
|
let r;
|
|
2768
2769
|
return De((a) => {
|
|
2769
2770
|
r = a, t === document ? e() : Pn(t, e(), t.firstChild ? null : void 0, n);
|
|
@@ -2771,7 +2772,7 @@ function dr(e, t, n, s = {}) {
|
|
|
2771
2772
|
r(), t.textContent = "";
|
|
2772
2773
|
};
|
|
2773
2774
|
}
|
|
2774
|
-
function
|
|
2775
|
+
function wu(e, t, n, s) {
|
|
2775
2776
|
let r;
|
|
2776
2777
|
const a = () => {
|
|
2777
2778
|
const o = document.createElement("template");
|
|
@@ -2779,32 +2780,32 @@ function _u(e, t, n, s) {
|
|
|
2779
2780
|
}, i = () => (r || (r = a())).cloneNode(!0);
|
|
2780
2781
|
return i.cloneNode = i, i;
|
|
2781
2782
|
}
|
|
2782
|
-
function
|
|
2783
|
+
function fl(e, t = window.document) {
|
|
2783
2784
|
const n = t[ut] || (t[ut] = /* @__PURE__ */ new Set());
|
|
2784
2785
|
for (let s = 0, r = e.length; s < r; s++) {
|
|
2785
2786
|
const a = e[s];
|
|
2786
|
-
n.has(a) || (n.add(a), t.addEventListener(a,
|
|
2787
|
+
n.has(a) || (n.add(a), t.addEventListener(a, hr));
|
|
2787
2788
|
}
|
|
2788
2789
|
}
|
|
2789
|
-
function
|
|
2790
|
+
function vu(e = window.document) {
|
|
2790
2791
|
if (e[ut]) {
|
|
2791
|
-
for (let t of e[ut].keys()) e.removeEventListener(t,
|
|
2792
|
+
for (let t of e[ut].keys()) e.removeEventListener(t, hr);
|
|
2792
2793
|
delete e[ut];
|
|
2793
2794
|
}
|
|
2794
2795
|
}
|
|
2795
2796
|
function _n(e, t, n) {
|
|
2796
2797
|
Fe(e) || (n == null ? e.removeAttribute(t) : e.setAttribute(t, n));
|
|
2797
2798
|
}
|
|
2798
|
-
function
|
|
2799
|
+
function hl(e, t, n, s) {
|
|
2799
2800
|
Fe(e) || (s == null ? e.removeAttributeNS(t, n) : e.setAttributeNS(t, n, s));
|
|
2800
2801
|
}
|
|
2801
|
-
function
|
|
2802
|
+
function gl(e, t, n) {
|
|
2802
2803
|
Fe(e) || (n ? e.setAttribute(t, "") : e.removeAttribute(t));
|
|
2803
2804
|
}
|
|
2804
|
-
function
|
|
2805
|
+
function ml(e, t) {
|
|
2805
2806
|
Fe(e) || (t == null ? e.removeAttribute("class") : e.className = t);
|
|
2806
2807
|
}
|
|
2807
|
-
function
|
|
2808
|
+
function El(e, t, n, s) {
|
|
2808
2809
|
if (s)
|
|
2809
2810
|
Array.isArray(n) ? (e[`$$${t}`] = n[0], e[`$$${t}Data`] = n[1]) : e[`$$${t}`] = n;
|
|
2810
2811
|
else if (Array.isArray(n)) {
|
|
@@ -2812,20 +2813,20 @@ function ml(e, t, n, s) {
|
|
|
2812
2813
|
e.addEventListener(t, n[0] = (a) => r.call(e, n[1], a));
|
|
2813
2814
|
} else e.addEventListener(t, n, typeof n != "function" && n);
|
|
2814
2815
|
}
|
|
2815
|
-
function
|
|
2816
|
+
function pl(e, t, n = {}) {
|
|
2816
2817
|
const s = Object.keys(t || {}), r = Object.keys(n);
|
|
2817
2818
|
let a, i;
|
|
2818
2819
|
for (a = 0, i = r.length; a < i; a++) {
|
|
2819
2820
|
const o = r[a];
|
|
2820
|
-
!o || o === "undefined" || t[o] || (
|
|
2821
|
+
!o || o === "undefined" || t[o] || (cs(e, o, !1), delete n[o]);
|
|
2821
2822
|
}
|
|
2822
2823
|
for (a = 0, i = s.length; a < i; a++) {
|
|
2823
2824
|
const o = s[a], l = !!t[o];
|
|
2824
|
-
!o || o === "undefined" || n[o] === l || !l || (
|
|
2825
|
+
!o || o === "undefined" || n[o] === l || !l || (cs(e, o, !0), n[o] = l);
|
|
2825
2826
|
}
|
|
2826
2827
|
return n;
|
|
2827
2828
|
}
|
|
2828
|
-
function
|
|
2829
|
+
function yl(e, t, n) {
|
|
2829
2830
|
if (!t) return n ? _n(e, "style") : t;
|
|
2830
2831
|
const s = e.style;
|
|
2831
2832
|
if (typeof t == "string") return s.cssText = t;
|
|
@@ -2837,49 +2838,49 @@ function pl(e, t, n) {
|
|
|
2837
2838
|
r = t[a], r !== n[a] && (s.setProperty(a, r), n[a] = r);
|
|
2838
2839
|
return n;
|
|
2839
2840
|
}
|
|
2840
|
-
function
|
|
2841
|
+
function Al(e, t = {}, n, s) {
|
|
2841
2842
|
const r = {};
|
|
2842
|
-
return s || ke(() => r.children = gt(e, t.children, r.children)), ke(() => typeof t.ref == "function" &&
|
|
2843
|
+
return s || ke(() => r.children = gt(e, t.children, r.children)), ke(() => typeof t.ref == "function" && Tl(t.ref, e)), ke(() => Sl(e, t, n, !0, r, !0)), r;
|
|
2843
2844
|
}
|
|
2844
|
-
function
|
|
2845
|
+
function Tl(e, t, n) {
|
|
2845
2846
|
return Z(() => e(t, n));
|
|
2846
2847
|
}
|
|
2847
2848
|
function Pn(e, t, n, s) {
|
|
2848
2849
|
if (n !== void 0 && !s && (s = []), typeof t != "function") return gt(e, t, s, n);
|
|
2849
2850
|
ke((r) => gt(e, t(), r, n), s);
|
|
2850
2851
|
}
|
|
2851
|
-
function
|
|
2852
|
+
function Sl(e, t, n, s, r = {}, a = !1) {
|
|
2852
2853
|
t || (t = {});
|
|
2853
2854
|
for (const i in r)
|
|
2854
2855
|
if (!(i in t)) {
|
|
2855
2856
|
if (i === "children") continue;
|
|
2856
|
-
r[i] =
|
|
2857
|
+
r[i] = us(e, i, null, r[i], n, a, t);
|
|
2857
2858
|
}
|
|
2858
2859
|
for (const i in t) {
|
|
2859
2860
|
if (i === "children")
|
|
2860
2861
|
continue;
|
|
2861
2862
|
const o = t[i];
|
|
2862
|
-
r[i] =
|
|
2863
|
+
r[i] = us(e, i, o, r[i], n, a, t);
|
|
2863
2864
|
}
|
|
2864
2865
|
}
|
|
2865
|
-
function
|
|
2866
|
+
function _l(e) {
|
|
2866
2867
|
let t, n;
|
|
2867
|
-
return !Fe() || !(t = _.registry.get(n =
|
|
2868
|
+
return !Fe() || !(t = _.registry.get(n = wl())) ? e() : (_.completed && _.completed.add(t), _.registry.delete(n), t);
|
|
2868
2869
|
}
|
|
2869
2870
|
function Fe(e) {
|
|
2870
2871
|
return !!_.context && !_.done && (!e || e.isConnected);
|
|
2871
2872
|
}
|
|
2872
|
-
function
|
|
2873
|
+
function Pl(e) {
|
|
2873
2874
|
return e.toLowerCase().replace(/-([a-z])/g, (t, n) => n.toUpperCase());
|
|
2874
2875
|
}
|
|
2875
|
-
function
|
|
2876
|
+
function cs(e, t, n) {
|
|
2876
2877
|
const s = t.trim().split(/\s+/);
|
|
2877
2878
|
for (let r = 0, a = s.length; r < a; r++) e.classList.toggle(s[r], n);
|
|
2878
2879
|
}
|
|
2879
|
-
function
|
|
2880
|
+
function us(e, t, n, s, r, a, i) {
|
|
2880
2881
|
let o, l, f, d, u;
|
|
2881
|
-
if (t === "style") return
|
|
2882
|
-
if (t === "classList") return
|
|
2882
|
+
if (t === "style") return yl(e, n, s);
|
|
2883
|
+
if (t === "classList") return pl(e, n, s);
|
|
2883
2884
|
if (n === s) return s;
|
|
2884
2885
|
if (t === "ref")
|
|
2885
2886
|
a || n(e);
|
|
@@ -2890,28 +2891,28 @@ function cs(e, t, n, s, r, a, i) {
|
|
|
2890
2891
|
const g = t.slice(10);
|
|
2891
2892
|
s && e.removeEventListener(g, s, !0), n && e.addEventListener(g, n, !0);
|
|
2892
2893
|
} else if (t.slice(0, 2) === "on") {
|
|
2893
|
-
const g = t.slice(2).toLowerCase(), h =
|
|
2894
|
+
const g = t.slice(2).toLowerCase(), h = ll.has(g);
|
|
2894
2895
|
if (!h && s) {
|
|
2895
2896
|
const p = Array.isArray(s) ? s[0] : s;
|
|
2896
2897
|
e.removeEventListener(g, p);
|
|
2897
2898
|
}
|
|
2898
|
-
(h || n) && (
|
|
2899
|
+
(h || n) && (El(e, g, n, h), h && fl([g]));
|
|
2899
2900
|
} else if (t.slice(0, 5) === "attr:")
|
|
2900
2901
|
_n(e, t.slice(5), n);
|
|
2901
2902
|
else if (t.slice(0, 5) === "bool:")
|
|
2902
|
-
|
|
2903
|
-
else if ((u = t.slice(0, 5) === "prop:") || (f =
|
|
2903
|
+
gl(e, t.slice(5), n);
|
|
2904
|
+
else if ((u = t.slice(0, 5) === "prop:") || (f = rl.has(t)) || !r && ((d = ol(t, e.tagName)) || (l = sl.has(t))) || (o = e.nodeName.includes("-") || "is" in i)) {
|
|
2904
2905
|
if (u)
|
|
2905
2906
|
t = t.slice(5), l = !0;
|
|
2906
2907
|
else if (Fe(e)) return n;
|
|
2907
|
-
t === "class" || t === "className" ?
|
|
2908
|
+
t === "class" || t === "className" ? ml(e, n) : o && !l && !f ? e[Pl(t)] = n : e[d || t] = n;
|
|
2908
2909
|
} else {
|
|
2909
|
-
const g = r && t.indexOf(":") > -1 &&
|
|
2910
|
-
g ?
|
|
2910
|
+
const g = r && t.indexOf(":") > -1 && ul[t.split(":")[0]];
|
|
2911
|
+
g ? hl(e, g, t, n) : _n(e, al[t] || t, n);
|
|
2911
2912
|
}
|
|
2912
2913
|
return n;
|
|
2913
2914
|
}
|
|
2914
|
-
function
|
|
2915
|
+
function hr(e) {
|
|
2915
2916
|
if (_.registry && _.events && _.events.find(([l, f]) => f === e))
|
|
2916
2917
|
return;
|
|
2917
2918
|
let t = e.target;
|
|
@@ -2994,7 +2995,7 @@ function gt(e, t, n, s, r) {
|
|
|
2994
2995
|
}
|
|
2995
2996
|
if (l.length === 0) {
|
|
2996
2997
|
if (n = Ve(e, n, s), o) return n;
|
|
2997
|
-
} else f ? n.length === 0 ?
|
|
2998
|
+
} else f ? n.length === 0 ? ds(e, l, s) : dl(e, n, l) : (n && Ve(e), ds(e, l));
|
|
2998
2999
|
n = l;
|
|
2999
3000
|
} else if (t.nodeType) {
|
|
3000
3001
|
if (a && t.parentNode) return n = o ? [t] : t;
|
|
@@ -3028,7 +3029,7 @@ function wn(e, t, n, s) {
|
|
|
3028
3029
|
}
|
|
3029
3030
|
return r;
|
|
3030
3031
|
}
|
|
3031
|
-
function
|
|
3032
|
+
function ds(e, t, n = null) {
|
|
3032
3033
|
for (let s = 0, r = t.length; s < r; s++) e.insertBefore(t[s], n);
|
|
3033
3034
|
}
|
|
3034
3035
|
function Ve(e, t, n, s) {
|
|
@@ -3046,26 +3047,26 @@ function Ve(e, t, n, s) {
|
|
|
3046
3047
|
} else e.insertBefore(r, n);
|
|
3047
3048
|
return [r];
|
|
3048
3049
|
}
|
|
3049
|
-
function
|
|
3050
|
+
function wl() {
|
|
3050
3051
|
return _.getNextContextId();
|
|
3051
3052
|
}
|
|
3052
|
-
var
|
|
3053
|
-
function
|
|
3054
|
-
return t ? document.createElementNS(
|
|
3053
|
+
var vl = "http://www.w3.org/2000/svg";
|
|
3054
|
+
function gr(e, t = !1) {
|
|
3055
|
+
return t ? document.createElementNS(vl, e) : document.createElement(e);
|
|
3055
3056
|
}
|
|
3056
|
-
function
|
|
3057
|
+
function bu(e) {
|
|
3057
3058
|
const {
|
|
3058
3059
|
useShadow: t
|
|
3059
|
-
} = e, n = document.createTextNode(""), s = () => e.mount || document.body, r =
|
|
3060
|
+
} = e, n = document.createTextNode(""), s = () => e.mount || document.body, r = ls();
|
|
3060
3061
|
let a, i = !!_.context;
|
|
3061
|
-
return
|
|
3062
|
-
i && (
|
|
3062
|
+
return tr(() => {
|
|
3063
|
+
i && (ls().user = i = !1), a || (a = nr(r, () => j(() => e.children)));
|
|
3063
3064
|
const o = s();
|
|
3064
3065
|
if (o instanceof HTMLHeadElement) {
|
|
3065
3066
|
const [l, f] = F(!1), d = () => f(!0);
|
|
3066
3067
|
De((u) => Pn(o, () => l() ? u() : a(), null)), ft(d);
|
|
3067
3068
|
} else {
|
|
3068
|
-
const l =
|
|
3069
|
+
const l = gr(e.isSVG ? "g" : "div", e.isSVG), f = t && l.attachShadow ? l.attachShadow({
|
|
3069
3070
|
mode: "open"
|
|
3070
3071
|
}) : l;
|
|
3071
3072
|
Object.defineProperty(l, "_$host", {
|
|
@@ -3079,7 +3080,7 @@ function wu(e) {
|
|
|
3079
3080
|
render: !i
|
|
3080
3081
|
}), n;
|
|
3081
3082
|
}
|
|
3082
|
-
function
|
|
3083
|
+
function bl(e, t) {
|
|
3083
3084
|
const n = j(e);
|
|
3084
3085
|
return j(() => {
|
|
3085
3086
|
const s = n();
|
|
@@ -3087,16 +3088,16 @@ function vl(e, t) {
|
|
|
3087
3088
|
case "function":
|
|
3088
3089
|
return Z(() => s(t));
|
|
3089
3090
|
case "string":
|
|
3090
|
-
const r =
|
|
3091
|
-
return
|
|
3091
|
+
const r = cl.has(s), a = _.context ? _l() : gr(s, r);
|
|
3092
|
+
return Al(a, t, r), a;
|
|
3092
3093
|
}
|
|
3093
3094
|
});
|
|
3094
3095
|
}
|
|
3095
|
-
function
|
|
3096
|
-
const [, t] =
|
|
3097
|
-
return
|
|
3096
|
+
function Iu(e) {
|
|
3097
|
+
const [, t] = el(e, ["component"]);
|
|
3098
|
+
return bl(() => e.component, t);
|
|
3098
3099
|
}
|
|
3099
|
-
var
|
|
3100
|
+
var Il = class {
|
|
3100
3101
|
constructor() {
|
|
3101
3102
|
this.keyToValue = /* @__PURE__ */ new Map(), this.valueToKey = /* @__PURE__ */ new Map();
|
|
3102
3103
|
}
|
|
@@ -3112,9 +3113,9 @@ var bl = class {
|
|
|
3112
3113
|
clear() {
|
|
3113
3114
|
this.keyToValue.clear(), this.valueToKey.clear();
|
|
3114
3115
|
}
|
|
3115
|
-
},
|
|
3116
|
+
}, mr = class {
|
|
3116
3117
|
constructor(e) {
|
|
3117
|
-
this.generateIdentifier = e, this.kv = new
|
|
3118
|
+
this.generateIdentifier = e, this.kv = new Il();
|
|
3118
3119
|
}
|
|
3119
3120
|
register(e, t) {
|
|
3120
3121
|
this.kv.getByValue(e) || (t || (t = this.generateIdentifier(e)), this.kv.set(t, e));
|
|
@@ -3128,7 +3129,7 @@ var bl = class {
|
|
|
3128
3129
|
getValue(e) {
|
|
3129
3130
|
return this.kv.getByKey(e);
|
|
3130
3131
|
}
|
|
3131
|
-
},
|
|
3132
|
+
}, Nl = class extends mr {
|
|
3132
3133
|
constructor() {
|
|
3133
3134
|
super((e) => e.name), this.classToAllowedProps = /* @__PURE__ */ new Map();
|
|
3134
3135
|
}
|
|
@@ -3139,7 +3140,7 @@ var bl = class {
|
|
|
3139
3140
|
return this.classToAllowedProps.get(e);
|
|
3140
3141
|
}
|
|
3141
3142
|
};
|
|
3142
|
-
function
|
|
3143
|
+
function Ll(e) {
|
|
3143
3144
|
if ("values" in Object)
|
|
3144
3145
|
return Object.values(e);
|
|
3145
3146
|
const t = [];
|
|
@@ -3147,8 +3148,8 @@ function Nl(e) {
|
|
|
3147
3148
|
e.hasOwnProperty(n) && t.push(e[n]);
|
|
3148
3149
|
return t;
|
|
3149
3150
|
}
|
|
3150
|
-
function
|
|
3151
|
-
const n =
|
|
3151
|
+
function Cl(e, t) {
|
|
3152
|
+
const n = Ll(e);
|
|
3152
3153
|
if ("find" in n)
|
|
3153
3154
|
return n.find(t);
|
|
3154
3155
|
const s = n;
|
|
@@ -3164,14 +3165,14 @@ function ot(e, t) {
|
|
|
3164
3165
|
function Ht(e, t) {
|
|
3165
3166
|
return e.indexOf(t) !== -1;
|
|
3166
3167
|
}
|
|
3167
|
-
function
|
|
3168
|
+
function fs(e, t) {
|
|
3168
3169
|
for (let n = 0; n < e.length; n++) {
|
|
3169
3170
|
const s = e[n];
|
|
3170
3171
|
if (t(s))
|
|
3171
3172
|
return s;
|
|
3172
3173
|
}
|
|
3173
3174
|
}
|
|
3174
|
-
var
|
|
3175
|
+
var Gl = class {
|
|
3175
3176
|
constructor() {
|
|
3176
3177
|
this.transfomers = {};
|
|
3177
3178
|
}
|
|
@@ -3179,12 +3180,12 @@ var Cl = class {
|
|
|
3179
3180
|
this.transfomers[e.name] = e;
|
|
3180
3181
|
}
|
|
3181
3182
|
findApplicable(e) {
|
|
3182
|
-
return
|
|
3183
|
+
return Cl(this.transfomers, (t) => t.isApplicable(e));
|
|
3183
3184
|
}
|
|
3184
3185
|
findByName(e) {
|
|
3185
3186
|
return this.transfomers[e];
|
|
3186
3187
|
}
|
|
3187
|
-
},
|
|
3188
|
+
}, Ol = (e) => Object.prototype.toString.call(e).slice(8, -1), Er = (e) => typeof e > "u", xl = (e) => e === null, mt = (e) => typeof e != "object" || e === null || e === Object.prototype ? !1 : Object.getPrototypeOf(e) === null ? !0 : Object.getPrototypeOf(e) === Object.prototype, vn = (e) => mt(e) && Object.keys(e).length === 0, Ne = (e) => Array.isArray(e), Dl = (e) => typeof e == "string", kl = (e) => typeof e == "number" && !isNaN(e), Rl = (e) => typeof e == "boolean", Ul = (e) => e instanceof RegExp, Et = (e) => e instanceof Map, pt = (e) => e instanceof Set, pr = (e) => Ol(e) === "Symbol", Ml = (e) => e instanceof Date && !isNaN(e.valueOf()), Bl = (e) => e instanceof Error, hs = (e) => typeof e == "number" && isNaN(e), Fl = (e) => Rl(e) || xl(e) || Er(e) || kl(e) || Dl(e) || pr(e), Kl = (e) => typeof e == "bigint", Vl = (e) => e === 1 / 0 || e === -1 / 0, Hl = (e) => ArrayBuffer.isView(e) && !(e instanceof DataView), ql = (e) => e instanceof URL, yr = (e) => e.replace(/\./g, "\\."), pn = (e) => e.map(String).map(yr).join("."), dt = (e) => {
|
|
3188
3189
|
const t = [];
|
|
3189
3190
|
let n = "";
|
|
3190
3191
|
for (let r = 0; r < e.length; r++) {
|
|
@@ -3210,12 +3211,12 @@ function de(e, t, n, s) {
|
|
|
3210
3211
|
untransform: s
|
|
3211
3212
|
};
|
|
3212
3213
|
}
|
|
3213
|
-
var
|
|
3214
|
-
de(
|
|
3214
|
+
var Ar = [
|
|
3215
|
+
de(Er, "undefined", () => null, () => {
|
|
3215
3216
|
}),
|
|
3216
|
-
de(
|
|
3217
|
-
de(
|
|
3218
|
-
de(
|
|
3217
|
+
de(Kl, "bigint", (e) => e.toString(), (e) => typeof BigInt < "u" ? BigInt(e) : e),
|
|
3218
|
+
de(Ml, "Date", (e) => e.toISOString(), (e) => new Date(e)),
|
|
3219
|
+
de(Bl, "Error", (e, t) => {
|
|
3219
3220
|
const n = {
|
|
3220
3221
|
name: e.name,
|
|
3221
3222
|
message: e.message
|
|
@@ -3229,7 +3230,7 @@ var yr = [
|
|
|
3229
3230
|
n[s] = e[s];
|
|
3230
3231
|
}), n;
|
|
3231
3232
|
}),
|
|
3232
|
-
de(
|
|
3233
|
+
de(Ul, "regexp", (e) => "" + e, (e) => {
|
|
3233
3234
|
const t = e.slice(1, e.lastIndexOf("/")), n = e.slice(e.lastIndexOf("/") + 1);
|
|
3234
3235
|
return new RegExp(t, n);
|
|
3235
3236
|
}),
|
|
@@ -3242,9 +3243,9 @@ var yr = [
|
|
|
3242
3243
|
(e) => new Set(e)
|
|
3243
3244
|
),
|
|
3244
3245
|
de(Et, "map", (e) => [...e.entries()], (e) => new Map(e)),
|
|
3245
|
-
de((e) =>
|
|
3246
|
+
de((e) => hs(e) || Vl(e), "number", (e) => hs(e) ? "NaN" : e > 0 ? "Infinity" : "-Infinity", Number),
|
|
3246
3247
|
de((e) => e === 0 && 1 / e === -1 / 0, "number", () => "-0", Number),
|
|
3247
|
-
de(
|
|
3248
|
+
de(ql, "URL", (e) => e.toString(), (e) => new URL(e))
|
|
3248
3249
|
];
|
|
3249
3250
|
function ln(e, t, n, s) {
|
|
3250
3251
|
return {
|
|
@@ -3254,12 +3255,12 @@ function ln(e, t, n, s) {
|
|
|
3254
3255
|
untransform: s
|
|
3255
3256
|
};
|
|
3256
3257
|
}
|
|
3257
|
-
var
|
|
3258
|
+
var Tr = ln((e, t) => pr(e) ? !!t.symbolRegistry.getIdentifier(e) : !1, (e, t) => ["symbol", t.symbolRegistry.getIdentifier(e)], (e) => e.description, (e, t, n) => {
|
|
3258
3259
|
const s = n.symbolRegistry.getValue(t[1]);
|
|
3259
3260
|
if (!s)
|
|
3260
3261
|
throw new Error("Trying to deserialize unknown symbol");
|
|
3261
3262
|
return s;
|
|
3262
|
-
}),
|
|
3263
|
+
}), $l = [
|
|
3263
3264
|
Int8Array,
|
|
3264
3265
|
Uint8Array,
|
|
3265
3266
|
Int16Array,
|
|
@@ -3269,16 +3270,16 @@ var Ar = ln((e, t) => Er(e) ? !!t.symbolRegistry.getIdentifier(e) : !1, (e, t) =
|
|
|
3269
3270
|
Float32Array,
|
|
3270
3271
|
Float64Array,
|
|
3271
3272
|
Uint8ClampedArray
|
|
3272
|
-
].reduce((e, t) => (e[t.name] = t, e), {}),
|
|
3273
|
-
const n =
|
|
3273
|
+
].reduce((e, t) => (e[t.name] = t, e), {}), Sr = ln(Hl, (e) => ["typed-array", e.constructor.name], (e) => [...e], (e, t) => {
|
|
3274
|
+
const n = $l[t[1]];
|
|
3274
3275
|
if (!n)
|
|
3275
3276
|
throw new Error("Trying to deserialize unknown typed array");
|
|
3276
3277
|
return new n(e);
|
|
3277
3278
|
});
|
|
3278
|
-
function
|
|
3279
|
+
function _r(e, t) {
|
|
3279
3280
|
return e != null && e.constructor ? !!t.classRegistry.getIdentifier(e.constructor) : !1;
|
|
3280
3281
|
}
|
|
3281
|
-
var
|
|
3282
|
+
var Pr = ln(_r, (e, t) => ["class", t.classRegistry.getIdentifier(e.constructor)], (e, t) => {
|
|
3282
3283
|
const n = t.classRegistry.getAllowedProps(e.constructor);
|
|
3283
3284
|
if (!n)
|
|
3284
3285
|
return { ...e };
|
|
@@ -3291,44 +3292,44 @@ var _r = ln(Sr, (e, t) => ["class", t.classRegistry.getIdentifier(e.constructor)
|
|
|
3291
3292
|
if (!s)
|
|
3292
3293
|
throw new Error(`Trying to deserialize unknown class '${t[1]}' - check https://github.com/blitz-js/superjson/issues/116#issuecomment-773996564`);
|
|
3293
3294
|
return Object.assign(Object.create(s.prototype), e);
|
|
3294
|
-
}),
|
|
3295
|
+
}), wr = ln((e, t) => !!t.customTransformerRegistry.findApplicable(e), (e, t) => ["custom", t.customTransformerRegistry.findApplicable(e).name], (e, t) => t.customTransformerRegistry.findApplicable(e).serialize(e), (e, t, n) => {
|
|
3295
3296
|
const s = n.customTransformerRegistry.findByName(t[1]);
|
|
3296
3297
|
if (!s)
|
|
3297
3298
|
throw new Error("Trying to deserialize unknown custom value");
|
|
3298
3299
|
return s.deserialize(e);
|
|
3299
|
-
}),
|
|
3300
|
-
const n =
|
|
3300
|
+
}), Ql = [Pr, Tr, wr, Sr], gs = (e, t) => {
|
|
3301
|
+
const n = fs(Ql, (r) => r.isApplicable(e, t));
|
|
3301
3302
|
if (n)
|
|
3302
3303
|
return {
|
|
3303
3304
|
value: n.transform(e, t),
|
|
3304
3305
|
type: n.annotation(e, t)
|
|
3305
3306
|
};
|
|
3306
|
-
const s =
|
|
3307
|
+
const s = fs(Ar, (r) => r.isApplicable(e, t));
|
|
3307
3308
|
if (s)
|
|
3308
3309
|
return {
|
|
3309
3310
|
value: s.transform(e, t),
|
|
3310
3311
|
type: s.annotation
|
|
3311
3312
|
};
|
|
3312
|
-
},
|
|
3313
|
-
|
|
3314
|
-
|
|
3313
|
+
}, vr = {};
|
|
3314
|
+
Ar.forEach((e) => {
|
|
3315
|
+
vr[e.annotation] = e;
|
|
3315
3316
|
});
|
|
3316
|
-
var
|
|
3317
|
+
var zl = (e, t, n) => {
|
|
3317
3318
|
if (Ne(t))
|
|
3318
3319
|
switch (t[0]) {
|
|
3319
3320
|
case "symbol":
|
|
3320
|
-
return
|
|
3321
|
+
return Tr.untransform(e, t, n);
|
|
3321
3322
|
case "class":
|
|
3322
|
-
return _r.untransform(e, t, n);
|
|
3323
|
-
case "custom":
|
|
3324
3323
|
return Pr.untransform(e, t, n);
|
|
3324
|
+
case "custom":
|
|
3325
|
+
return wr.untransform(e, t, n);
|
|
3325
3326
|
case "typed-array":
|
|
3326
|
-
return
|
|
3327
|
+
return Sr.untransform(e, t, n);
|
|
3327
3328
|
default:
|
|
3328
3329
|
throw new Error("Unknown transformation: " + t);
|
|
3329
3330
|
}
|
|
3330
3331
|
else {
|
|
3331
|
-
const s =
|
|
3332
|
+
const s = vr[t];
|
|
3332
3333
|
if (!s)
|
|
3333
3334
|
throw new Error("Unknown transformation: " + t);
|
|
3334
3335
|
return s.untransform(e, n);
|
|
@@ -3341,7 +3342,7 @@ var Ql = (e, t, n) => {
|
|
|
3341
3342
|
n.next(), t--;
|
|
3342
3343
|
return n.next().value;
|
|
3343
3344
|
};
|
|
3344
|
-
function
|
|
3345
|
+
function br(e) {
|
|
3345
3346
|
if (Ht(e, "__proto__"))
|
|
3346
3347
|
throw new Error("__proto__ is not allowed as a property");
|
|
3347
3348
|
if (Ht(e, "prototype"))
|
|
@@ -3349,8 +3350,8 @@ function vr(e) {
|
|
|
3349
3350
|
if (Ht(e, "constructor"))
|
|
3350
3351
|
throw new Error("constructor is not allowed as a property");
|
|
3351
3352
|
}
|
|
3352
|
-
var
|
|
3353
|
-
|
|
3353
|
+
var Wl = (e, t) => {
|
|
3354
|
+
br(t);
|
|
3354
3355
|
for (let n = 0; n < t.length; n++) {
|
|
3355
3356
|
const s = t[n];
|
|
3356
3357
|
if (pt(e))
|
|
@@ -3370,7 +3371,7 @@ var zl = (e, t) => {
|
|
|
3370
3371
|
}
|
|
3371
3372
|
return e;
|
|
3372
3373
|
}, bn = (e, t, n) => {
|
|
3373
|
-
if (
|
|
3374
|
+
if (br(t), t.length === 0)
|
|
3374
3375
|
return n(e);
|
|
3375
3376
|
let s = e;
|
|
3376
3377
|
for (let a = 0; a < t.length - 1; a++) {
|
|
@@ -3430,14 +3431,14 @@ function In(e, t, n = []) {
|
|
|
3430
3431
|
In(a, t, [...n, ...dt(i)]);
|
|
3431
3432
|
}), t(s, n);
|
|
3432
3433
|
}
|
|
3433
|
-
function
|
|
3434
|
+
function jl(e, t, n) {
|
|
3434
3435
|
return In(t, (s, r) => {
|
|
3435
|
-
e = bn(e, r, (a) =>
|
|
3436
|
+
e = bn(e, r, (a) => zl(a, s, n));
|
|
3436
3437
|
}), e;
|
|
3437
3438
|
}
|
|
3438
|
-
function
|
|
3439
|
+
function Yl(e, t) {
|
|
3439
3440
|
function n(s, r) {
|
|
3440
|
-
const a =
|
|
3441
|
+
const a = Wl(e, dt(r));
|
|
3441
3442
|
s.map(dt).forEach((i) => {
|
|
3442
3443
|
e = bn(e, i, () => a);
|
|
3443
3444
|
});
|
|
@@ -3451,12 +3452,12 @@ function jl(e, t) {
|
|
|
3451
3452
|
ot(t, n);
|
|
3452
3453
|
return e;
|
|
3453
3454
|
}
|
|
3454
|
-
var
|
|
3455
|
-
function
|
|
3455
|
+
var Jl = (e, t) => mt(e) || Ne(e) || Et(e) || pt(e) || _r(e, t);
|
|
3456
|
+
function Zl(e, t, n) {
|
|
3456
3457
|
const s = n.get(e);
|
|
3457
3458
|
s ? s.push(t) : n.set(e, [t]);
|
|
3458
3459
|
}
|
|
3459
|
-
function
|
|
3460
|
+
function Xl(e, t) {
|
|
3460
3461
|
const n = {};
|
|
3461
3462
|
let s;
|
|
3462
3463
|
return e.forEach((r) => {
|
|
@@ -3467,18 +3468,18 @@ function Zl(e, t) {
|
|
|
3467
3468
|
a.length === 0 ? s = i.map(pn) : n[pn(a)] = i.map(pn);
|
|
3468
3469
|
}), s ? vn(n) ? [s] : [s, n] : vn(n) ? void 0 : n;
|
|
3469
3470
|
}
|
|
3470
|
-
var
|
|
3471
|
-
const o =
|
|
3471
|
+
var Ir = (e, t, n, s, r = [], a = [], i = /* @__PURE__ */ new Map()) => {
|
|
3472
|
+
const o = Fl(e);
|
|
3472
3473
|
if (!o) {
|
|
3473
|
-
|
|
3474
|
+
Zl(e, r, t);
|
|
3474
3475
|
const h = i.get(e);
|
|
3475
3476
|
if (h)
|
|
3476
3477
|
return s ? {
|
|
3477
3478
|
transformedValue: null
|
|
3478
3479
|
} : h;
|
|
3479
3480
|
}
|
|
3480
|
-
if (!
|
|
3481
|
-
const h =
|
|
3481
|
+
if (!Jl(e, n)) {
|
|
3482
|
+
const h = gs(e, n), p = h ? {
|
|
3482
3483
|
transformedValue: h.value,
|
|
3483
3484
|
annotations: [h.type]
|
|
3484
3485
|
} : {
|
|
@@ -3490,13 +3491,13 @@ var br = (e, t, n, s, r = [], a = [], i = /* @__PURE__ */ new Map()) => {
|
|
|
3490
3491
|
return {
|
|
3491
3492
|
transformedValue: null
|
|
3492
3493
|
};
|
|
3493
|
-
const l =
|
|
3494
|
+
const l = gs(e, n), f = (l == null ? void 0 : l.value) ?? e, d = Ne(f) ? [] : {}, u = {};
|
|
3494
3495
|
ot(f, (h, p) => {
|
|
3495
3496
|
if (p === "__proto__" || p === "constructor" || p === "prototype")
|
|
3496
3497
|
throw new Error(`Detected property ${p}. This is a prototype pollution risk, please remove it from your object.`);
|
|
3497
|
-
const T =
|
|
3498
|
+
const T = Ir(h, t, n, s, [...r, p], [...a, e], i);
|
|
3498
3499
|
d[p] = T.transformedValue, Ne(T.annotations) ? u[p] = T.annotations : mt(T.annotations) && ot(T.annotations, (S, x) => {
|
|
3499
|
-
u[
|
|
3500
|
+
u[yr(p) + "." + x] = S;
|
|
3500
3501
|
});
|
|
3501
3502
|
});
|
|
3502
3503
|
const g = vn(u) ? {
|
|
@@ -3508,19 +3509,19 @@ var br = (e, t, n, s, r = [], a = [], i = /* @__PURE__ */ new Map()) => {
|
|
|
3508
3509
|
};
|
|
3509
3510
|
return o || i.set(e, g), g;
|
|
3510
3511
|
};
|
|
3511
|
-
function
|
|
3512
|
+
function Nr(e) {
|
|
3512
3513
|
return Object.prototype.toString.call(e).slice(8, -1);
|
|
3513
3514
|
}
|
|
3514
|
-
function
|
|
3515
|
-
return
|
|
3515
|
+
function ms(e) {
|
|
3516
|
+
return Nr(e) === "Array";
|
|
3516
3517
|
}
|
|
3517
|
-
function
|
|
3518
|
-
if (
|
|
3518
|
+
function ec(e) {
|
|
3519
|
+
if (Nr(e) !== "Object")
|
|
3519
3520
|
return !1;
|
|
3520
3521
|
const t = Object.getPrototypeOf(e);
|
|
3521
3522
|
return !!t && t.constructor === Object && t === Object.prototype;
|
|
3522
3523
|
}
|
|
3523
|
-
function
|
|
3524
|
+
function tc(e, t, n, s, r) {
|
|
3524
3525
|
const a = {}.propertyIsEnumerable.call(s, t) ? "enumerable" : "nonenumerable";
|
|
3525
3526
|
a === "enumerable" && (e[t] = n), r && a === "nonenumerable" && Object.defineProperty(e, t, {
|
|
3526
3527
|
value: n,
|
|
@@ -3530,16 +3531,16 @@ function ec(e, t, n, s, r) {
|
|
|
3530
3531
|
});
|
|
3531
3532
|
}
|
|
3532
3533
|
function Nn(e, t = {}) {
|
|
3533
|
-
if (
|
|
3534
|
+
if (ms(e))
|
|
3534
3535
|
return e.map((r) => Nn(r, t));
|
|
3535
|
-
if (!
|
|
3536
|
+
if (!ec(e))
|
|
3536
3537
|
return e;
|
|
3537
3538
|
const n = Object.getOwnPropertyNames(e), s = Object.getOwnPropertySymbols(e);
|
|
3538
3539
|
return [...n, ...s].reduce((r, a) => {
|
|
3539
|
-
if (
|
|
3540
|
+
if (ms(t.props) && !t.props.includes(a))
|
|
3540
3541
|
return r;
|
|
3541
3542
|
const i = e[a], o = Nn(i, t);
|
|
3542
|
-
return
|
|
3543
|
+
return tc(r, a, o, e, t.nonenumerable), r;
|
|
3543
3544
|
}, {});
|
|
3544
3545
|
}
|
|
3545
3546
|
var k = class {
|
|
@@ -3547,17 +3548,17 @@ var k = class {
|
|
|
3547
3548
|
* @param dedupeReferentialEqualities If true, SuperJSON will make sure only one instance of referentially equal objects are serialized and the rest are replaced with `null`.
|
|
3548
3549
|
*/
|
|
3549
3550
|
constructor({ dedupe: e = !1 } = {}) {
|
|
3550
|
-
this.classRegistry = new
|
|
3551
|
+
this.classRegistry = new Nl(), this.symbolRegistry = new mr((t) => t.description ?? ""), this.customTransformerRegistry = new Gl(), this.allowedErrorProps = [], this.dedupe = e;
|
|
3551
3552
|
}
|
|
3552
3553
|
serialize(e) {
|
|
3553
|
-
const t = /* @__PURE__ */ new Map(), n =
|
|
3554
|
+
const t = /* @__PURE__ */ new Map(), n = Ir(e, t, this, this.dedupe), s = {
|
|
3554
3555
|
json: n.transformedValue
|
|
3555
3556
|
};
|
|
3556
3557
|
n.annotations && (s.meta = {
|
|
3557
3558
|
...s.meta,
|
|
3558
3559
|
values: n.annotations
|
|
3559
3560
|
});
|
|
3560
|
-
const r =
|
|
3561
|
+
const r = Xl(t, this.dedupe);
|
|
3561
3562
|
return r && (s.meta = {
|
|
3562
3563
|
...s.meta,
|
|
3563
3564
|
referentialEqualities: r
|
|
@@ -3566,7 +3567,7 @@ var k = class {
|
|
|
3566
3567
|
deserialize(e) {
|
|
3567
3568
|
const { json: t, meta: n } = e;
|
|
3568
3569
|
let s = Nn(t);
|
|
3569
|
-
return n != null && n.values && (s =
|
|
3570
|
+
return n != null && n.values && (s = jl(s, n.values, this)), n != null && n.referentialEqualities && (s = Yl(s, n.referentialEqualities)), s;
|
|
3570
3571
|
}
|
|
3571
3572
|
stringify(e) {
|
|
3572
3573
|
return JSON.stringify(this.serialize(e));
|
|
@@ -3599,44 +3600,44 @@ k.registerClass = k.defaultInstance.registerClass.bind(k.defaultInstance);
|
|
|
3599
3600
|
k.registerSymbol = k.defaultInstance.registerSymbol.bind(k.defaultInstance);
|
|
3600
3601
|
k.registerCustom = k.defaultInstance.registerCustom.bind(k.defaultInstance);
|
|
3601
3602
|
k.allowErrorProps = k.defaultInstance.allowErrorProps.bind(k.defaultInstance);
|
|
3602
|
-
var
|
|
3603
|
-
function
|
|
3603
|
+
var nc = k.serialize, Nu = k.stringify;
|
|
3604
|
+
function Lu(e) {
|
|
3604
3605
|
return e.state.fetchStatus === "fetching" ? "fetching" : e.getObserversCount() ? e.state.fetchStatus === "paused" ? "paused" : e.isStale() ? "stale" : "fresh" : "inactive";
|
|
3605
3606
|
}
|
|
3606
|
-
function
|
|
3607
|
+
function Cu(e, t) {
|
|
3607
3608
|
return `${e}${t.charAt(0).toUpperCase() + t.slice(1)}`;
|
|
3608
3609
|
}
|
|
3609
|
-
function
|
|
3610
|
+
function Gu({
|
|
3610
3611
|
queryState: e,
|
|
3611
3612
|
observerCount: t,
|
|
3612
3613
|
isStale: n
|
|
3613
3614
|
}) {
|
|
3614
3615
|
return e.fetchStatus === "fetching" ? "blue" : t ? e.fetchStatus === "paused" ? "purple" : n ? "yellow" : "green" : "gray";
|
|
3615
3616
|
}
|
|
3616
|
-
function
|
|
3617
|
+
function Ou({
|
|
3617
3618
|
status: e,
|
|
3618
3619
|
isPaused: t
|
|
3619
3620
|
}) {
|
|
3620
3621
|
return t ? "purple" : e === "error" ? "red" : e === "pending" ? "yellow" : e === "success" ? "green" : "gray";
|
|
3621
3622
|
}
|
|
3622
|
-
function
|
|
3623
|
+
function xu(e) {
|
|
3623
3624
|
return e === "fresh" ? "green" : e === "stale" ? "yellow" : e === "paused" ? "purple" : e === "inactive" ? "gray" : "blue";
|
|
3624
3625
|
}
|
|
3625
|
-
var
|
|
3626
|
+
var Du = (e, t = !1) => {
|
|
3626
3627
|
const {
|
|
3627
3628
|
json: n
|
|
3628
|
-
} =
|
|
3629
|
+
} = nc(e);
|
|
3629
3630
|
return JSON.stringify(n, null, t ? 2 : void 0);
|
|
3630
|
-
}, Mt = (e) => e.state.fetchStatus !== "idle" ? 0 : e.getObserversCount() ? e.isStale() ? 2 : 1 : 3,
|
|
3631
|
-
status: sc,
|
|
3632
|
-
"query hash": nc,
|
|
3633
|
-
"last updated": Nr
|
|
3634
|
-
}, Bt = (e) => e.state.isPaused ? 0 : e.state.status === "error" ? 2 : e.state.status === "pending" ? 1 : 3, Lr = (e, t) => e.state.submittedAt < t.state.submittedAt ? 1 : -1, rc = (e, t) => Bt(e) === Bt(t) ? Lr(e, t) : Bt(e) > Bt(t) ? 1 : -1, Du = {
|
|
3631
|
+
}, Mt = (e) => e.state.fetchStatus !== "idle" ? 0 : e.getObserversCount() ? e.isStale() ? 2 : 1 : 3, sc = (e, t) => e.queryHash.localeCompare(t.queryHash), Lr = (e, t) => e.state.dataUpdatedAt < t.state.dataUpdatedAt ? 1 : -1, rc = (e, t) => Mt(e) === Mt(t) ? Lr(e, t) : Mt(e) > Mt(t) ? 1 : -1, ku = {
|
|
3635
3632
|
status: rc,
|
|
3633
|
+
"query hash": sc,
|
|
3636
3634
|
"last updated": Lr
|
|
3637
|
-
},
|
|
3635
|
+
}, Bt = (e) => e.state.isPaused ? 0 : e.state.status === "error" ? 2 : e.state.status === "pending" ? 1 : 3, Cr = (e, t) => e.state.submittedAt < t.state.submittedAt ? 1 : -1, ac = (e, t) => Bt(e) === Bt(t) ? Cr(e, t) : Bt(e) > Bt(t) ? 1 : -1, Ru = {
|
|
3636
|
+
status: ac,
|
|
3637
|
+
"last updated": Cr
|
|
3638
|
+
}, Uu = (e) => e * parseFloat(getComputedStyle(document.documentElement).fontSize), Mu = () => {
|
|
3638
3639
|
const [e, t] = F("dark");
|
|
3639
|
-
return
|
|
3640
|
+
return Ho(() => {
|
|
3640
3641
|
const n = window.matchMedia("(prefers-color-scheme: dark)");
|
|
3641
3642
|
t(n.matches ? "dark" : "light");
|
|
3642
3643
|
const s = (r) => {
|
|
@@ -3704,11 +3705,11 @@ var Ou = (e, t = !1) => {
|
|
|
3704
3705
|
return n[s] = Kt(n[s], r), n;
|
|
3705
3706
|
}
|
|
3706
3707
|
return e;
|
|
3707
|
-
},
|
|
3708
|
+
}, Gr = (e, t) => {
|
|
3708
3709
|
if (!e || document.querySelector("#_goober") || (t == null ? void 0 : t.querySelector("#_goober"))) return;
|
|
3709
3710
|
const s = document.createElement("style"), r = document.createTextNode("");
|
|
3710
3711
|
s.appendChild(r), s.id = "_goober", s.setAttribute("nonce", e), t ? t.appendChild(s) : document.head.appendChild(s);
|
|
3711
|
-
}, qe, yt, At, Tt, Oe, St, $e, Qe, ze, We, je, _t, Ye, Je, Pt,
|
|
3712
|
+
}, qe, yt, At, Tt, Oe, St, $e, Qe, ze, We, je, _t, Ye, Je, Pt, As, ic = (As = class {
|
|
3712
3713
|
constructor(e) {
|
|
3713
3714
|
O(this, qe);
|
|
3714
3715
|
O(this, yt);
|
|
@@ -3762,10 +3763,10 @@ var Ou = (e, t = !1) => {
|
|
|
3762
3763
|
mount(e) {
|
|
3763
3764
|
if (A(this, Oe))
|
|
3764
3765
|
throw new Error("Devtools is already mounted");
|
|
3765
|
-
const t =
|
|
3766
|
+
const t = fr(() => {
|
|
3766
3767
|
const n = this, [s] = A(this, Qe), [r] = A(this, ze), [a] = A(this, We), [i] = A(this, je), [o] = A(this, _t), [l] = A(this, qe), [f] = A(this, Je);
|
|
3767
3768
|
let d;
|
|
3768
|
-
return A(this, Ye) ? d = A(this, Ye) : (d =
|
|
3769
|
+
return A(this, Ye) ? d = A(this, Ye) : (d = ur(() => import("./WDYDFRGG-Cd4hRWj-.js")), C(this, Ye, d)), Gr(A(this, St), A(this, $e)), lr(d, cr({
|
|
3769
3770
|
get queryFlavor() {
|
|
3770
3771
|
return A(n, At);
|
|
3771
3772
|
},
|
|
@@ -3810,7 +3811,7 @@ var Ou = (e, t = !1) => {
|
|
|
3810
3811
|
throw new Error("Devtools is not mounted");
|
|
3811
3812
|
(e = A(this, Pt)) == null || e.call(this), C(this, Oe, !1);
|
|
3812
3813
|
}
|
|
3813
|
-
}, qe = new WeakMap(), yt = new WeakMap(), At = new WeakMap(), Tt = new WeakMap(), Oe = new WeakMap(), St = new WeakMap(), $e = new WeakMap(), Qe = new WeakMap(), ze = new WeakMap(), We = new WeakMap(), je = new WeakMap(), _t = new WeakMap(), Ye = new WeakMap(), Je = new WeakMap(), Pt = new WeakMap(),
|
|
3814
|
+
}, qe = new WeakMap(), yt = new WeakMap(), At = new WeakMap(), Tt = new WeakMap(), Oe = new WeakMap(), St = new WeakMap(), $e = new WeakMap(), Qe = new WeakMap(), ze = new WeakMap(), We = new WeakMap(), je = new WeakMap(), _t = new WeakMap(), Ye = new WeakMap(), Je = new WeakMap(), Pt = new WeakMap(), As), Ze, wt, vt, bt, xe, It, Xe, et, tt, nt, st, Nt, rt, at, it, Lt, Ts, oc = (Ts = class {
|
|
3814
3815
|
constructor(e) {
|
|
3815
3816
|
O(this, Ze);
|
|
3816
3817
|
O(this, wt);
|
|
@@ -3869,10 +3870,10 @@ var Ou = (e, t = !1) => {
|
|
|
3869
3870
|
mount(e) {
|
|
3870
3871
|
if (A(this, xe))
|
|
3871
3872
|
throw new Error("Devtools is already mounted");
|
|
3872
|
-
const t =
|
|
3873
|
+
const t = fr(() => {
|
|
3873
3874
|
const n = this, [s] = A(this, et), [r] = A(this, tt), [a] = A(this, nt), [i] = A(this, st), [o] = A(this, Nt), [l] = A(this, Ze), [f] = A(this, rt), [d] = A(this, it);
|
|
3874
3875
|
let u;
|
|
3875
|
-
return A(this, at) ? u = A(this, at) : (u =
|
|
3876
|
+
return A(this, at) ? u = A(this, at) : (u = ur(() => import("./2SSKDMRQ-trME0kvt.js")), C(this, at, u)), Gr(A(this, It), A(this, Xe)), lr(u, cr({
|
|
3876
3877
|
get queryFlavor() {
|
|
3877
3878
|
return A(n, vt);
|
|
3878
3879
|
},
|
|
@@ -3920,8 +3921,8 @@ var Ou = (e, t = !1) => {
|
|
|
3920
3921
|
throw new Error("Devtools is not mounted");
|
|
3921
3922
|
(e = A(this, Lt)) == null || e.call(this), C(this, xe, !1);
|
|
3922
3923
|
}
|
|
3923
|
-
}, Ze = new WeakMap(), wt = new WeakMap(), vt = new WeakMap(), bt = new WeakMap(), xe = new WeakMap(), It = new WeakMap(), Xe = new WeakMap(), et = new WeakMap(), tt = new WeakMap(), nt = new WeakMap(), st = new WeakMap(), Nt = new WeakMap(), rt = new WeakMap(), at = new WeakMap(), it = new WeakMap(), Lt = new WeakMap(),
|
|
3924
|
-
function
|
|
3924
|
+
}, Ze = new WeakMap(), wt = new WeakMap(), vt = new WeakMap(), bt = new WeakMap(), xe = new WeakMap(), It = new WeakMap(), Xe = new WeakMap(), et = new WeakMap(), tt = new WeakMap(), nt = new WeakMap(), st = new WeakMap(), Nt = new WeakMap(), rt = new WeakMap(), at = new WeakMap(), it = new WeakMap(), Lt = new WeakMap(), Ts);
|
|
3925
|
+
function lc(e) {
|
|
3925
3926
|
const t = J(e.client), n = $.useRef(null), {
|
|
3926
3927
|
buttonPosition: s,
|
|
3927
3928
|
position: r,
|
|
@@ -3932,11 +3933,11 @@ function oc(e) {
|
|
|
3932
3933
|
hideDisabledQueries: f,
|
|
3933
3934
|
theme: d
|
|
3934
3935
|
} = e, [u] = $.useState(
|
|
3935
|
-
new
|
|
3936
|
+
new ic({
|
|
3936
3937
|
client: t,
|
|
3937
3938
|
queryFlavor: "React Query",
|
|
3938
3939
|
version: "5",
|
|
3939
|
-
onlineManager:
|
|
3940
|
+
onlineManager: Os,
|
|
3940
3941
|
buttonPosition: s,
|
|
3941
3942
|
position: r,
|
|
3942
3943
|
initialIsOpen: a,
|
|
@@ -3963,7 +3964,7 @@ function oc(e) {
|
|
|
3963
3964
|
u.unmount();
|
|
3964
3965
|
}), [u]), /* @__PURE__ */ c("div", { dir: "ltr", className: "tsqd-parent-container", ref: n });
|
|
3965
3966
|
}
|
|
3966
|
-
function
|
|
3967
|
+
function cc(e) {
|
|
3967
3968
|
const t = J(e.client), n = $.useRef(null), {
|
|
3968
3969
|
errorTypes: s,
|
|
3969
3970
|
styleNonce: r,
|
|
@@ -3971,11 +3972,11 @@ function lc(e) {
|
|
|
3971
3972
|
hideDisabledQueries: i,
|
|
3972
3973
|
theme: o
|
|
3973
3974
|
} = e, [l] = $.useState(
|
|
3974
|
-
new
|
|
3975
|
+
new oc({
|
|
3975
3976
|
client: t,
|
|
3976
3977
|
queryFlavor: "React Query",
|
|
3977
3978
|
version: "5",
|
|
3978
|
-
onlineManager:
|
|
3979
|
+
onlineManager: Os,
|
|
3979
3980
|
buttonPosition: "bottom-left",
|
|
3980
3981
|
position: "bottom",
|
|
3981
3982
|
initialIsOpen: !0,
|
|
@@ -4007,24 +4008,24 @@ function lc(e) {
|
|
|
4007
4008
|
}
|
|
4008
4009
|
);
|
|
4009
4010
|
}
|
|
4010
|
-
var
|
|
4011
|
+
var Es = process.env.NODE_ENV !== "development" ? function() {
|
|
4011
4012
|
return null;
|
|
4012
|
-
} :
|
|
4013
|
+
} : lc;
|
|
4013
4014
|
process.env.NODE_ENV;
|
|
4014
|
-
const
|
|
4015
|
-
|
|
4015
|
+
const uc = Ee(""), dc = () => {
|
|
4016
|
+
jn("dynamic-page-selector", {
|
|
4016
4017
|
description: "Dynamic page selector"
|
|
4017
|
-
}),
|
|
4018
|
+
}), jn("enable-add-page-dropdown", {
|
|
4018
4019
|
description: "Enable add page dropdown"
|
|
4019
4020
|
});
|
|
4020
|
-
},
|
|
4021
|
+
}, fc = () => {
|
|
4021
4022
|
const e = b(), t = I();
|
|
4022
4023
|
return re({
|
|
4023
4024
|
queryKey: [E.GET_COLLECTIONS],
|
|
4024
4025
|
staleTime: 1 / 0,
|
|
4025
4026
|
queryFn: async () => t(e, { action: E.GET_COLLECTIONS })
|
|
4026
4027
|
});
|
|
4027
|
-
},
|
|
4028
|
+
}, hc = () => {
|
|
4028
4029
|
const { data: e } = oe(), { data: t } = Le(), { data: n } = Be(), s = b(), r = I(), a = q(() => (n == null ? void 0 : n.fallbackLang) || "en", [n == null ? void 0 : n.fallbackLang]), i = Ie(/* @__PURE__ */ new Map());
|
|
4029
4030
|
return Y({
|
|
4030
4031
|
mutationFn: async ({ block: o }) => {
|
|
@@ -4055,7 +4056,7 @@ const cc = Ee(""), uc = () => {
|
|
|
4055
4056
|
}), u;
|
|
4056
4057
|
}
|
|
4057
4058
|
});
|
|
4058
|
-
},
|
|
4059
|
+
}, gc = () => {
|
|
4059
4060
|
const [, e] = ve();
|
|
4060
4061
|
return z(
|
|
4061
4062
|
(t, n) => {
|
|
@@ -4064,64 +4065,64 @@ const cc = Ee(""), uc = () => {
|
|
|
4064
4065
|
},
|
|
4065
4066
|
[e]
|
|
4066
4067
|
);
|
|
4067
|
-
},
|
|
4068
|
-
const e =
|
|
4068
|
+
}, mc = () => {
|
|
4069
|
+
const e = gc();
|
|
4069
4070
|
return z(
|
|
4070
4071
|
({ pageId: t }) => {
|
|
4071
4072
|
e(t);
|
|
4072
4073
|
},
|
|
4073
4074
|
[e]
|
|
4074
4075
|
);
|
|
4075
|
-
},
|
|
4076
|
+
}, Ec = {
|
|
4076
4077
|
SITE_WIDE_USAGE: "SITE_WIDE_USAGE"
|
|
4077
|
-
},
|
|
4078
|
+
}, pc = (e) => {
|
|
4078
4079
|
const t = I(), n = b();
|
|
4079
4080
|
return re({
|
|
4080
|
-
queryKey: [
|
|
4081
|
+
queryKey: [Ec.SITE_WIDE_USAGE],
|
|
4081
4082
|
queryFn: async () => e ? t(n, { action: "GET_SITE_WIDE_USAGE" }) : {},
|
|
4082
4083
|
retry: !1
|
|
4083
4084
|
});
|
|
4084
|
-
},
|
|
4085
|
-
() => import("./no-language-page-dialog-
|
|
4086
|
-
),
|
|
4087
|
-
|
|
4088
|
-
|
|
4089
|
-
|
|
4090
|
-
|
|
4091
|
-
|
|
4092
|
-
|
|
4093
|
-
const
|
|
4085
|
+
}, yc = V(() => import("./page-lock-CzsxrmN5.js")), Ac = V(
|
|
4086
|
+
() => import("./no-language-page-dialog-CPlKMyb8.js")
|
|
4087
|
+
), Tc = V(() => import("./digital-asset-manager-b8gDuLnI.js")), Sc = V(() => import("./save-to-lib-CQQxoovF.js")), _c = V(() => import("./theme-panel-footer-sK6bYhEb.js")), Pc = V(() => import("./web-preview-C_yFwxEe.js"));
|
|
4088
|
+
dc();
|
|
4089
|
+
oi();
|
|
4090
|
+
ma(go);
|
|
4091
|
+
Uo();
|
|
4092
|
+
ha(Tc);
|
|
4093
|
+
ga(Sc);
|
|
4094
|
+
const wc = {
|
|
4094
4095
|
role: "",
|
|
4095
4096
|
permissions: null
|
|
4096
|
-
},
|
|
4097
|
+
}, ps = (e) => {
|
|
4097
4098
|
var Hn;
|
|
4098
|
-
const { data: t } =
|
|
4099
|
+
const { data: t } = So(), n = Mn(), { data: s = wc, isFetching: r } = _o(), { data: a, isFetching: i } = Ce(), { data: o, isFetching: l } = fc(), { data: f, isFetching: d } = Be(), u = r || i || l || d, [g] = ve(), h = g.get("page"), { data: p } = oe(), { data: T, isFetching: S } = yo(), { blocks: x } = po(T), { data: y, isFetching: w } = Ao(), { pageStatus: v } = ye(), U = mo(), { onSave: N } = Po(), { mutateAsync: Ae } = hc(), { getPartialBlocks: Te, getPartialBlockBlocks: B } = wo(), { mutateAsync: P } = Ti(), { mutateAsync: L } = To(), { data: W } = pc(((Hn = e.flags) == null ? void 0 : Hn.designTokens) ?? !1), Q = mc(), [ue, Gt] = K(!1), Se = Ie([]), Ke = q(() => H(f, "theme", {}) || {}, [f]), Ge = v === te.EDITING, Or = v === te.CHECKING, Kn = S || Or || w;
|
|
4099
4100
|
Se.current = x;
|
|
4100
|
-
const [
|
|
4101
|
+
const [xr] = pe(uc);
|
|
4101
4102
|
se(() => {
|
|
4102
4103
|
const ae = () => {
|
|
4103
4104
|
document.hidden ? Gt(!0) : Gt(!1);
|
|
4104
4105
|
};
|
|
4105
4106
|
return window.addEventListener("visibilitychange", ae), () => window.removeEventListener("visibilitychange", ae);
|
|
4106
4107
|
}, []);
|
|
4107
|
-
const
|
|
4108
|
+
const Dr = q(() => {
|
|
4108
4109
|
const ae = {};
|
|
4109
4110
|
return s && (ae.permissions = H(s, "permissions", null), ae.role = H(s, "role", "user")), ae;
|
|
4110
|
-
}, [s]), Vn = q(() => t == null ? void 0 : t.some((ae) => ae.isSiteLibrary), [t]),
|
|
4111
|
+
}, [s]), Vn = q(() => t == null ? void 0 : t.some((ae) => ae.isSiteLibrary), [t]), kr = z(
|
|
4111
4112
|
async (ae, Ot) => await P({ pageType: ae, query: Ot }),
|
|
4112
4113
|
[P]
|
|
4113
4114
|
);
|
|
4114
4115
|
return /* @__PURE__ */ m(he, { children: [
|
|
4115
|
-
Kn && /* @__PURE__ */ c(
|
|
4116
|
-
|
|
4116
|
+
Kn && /* @__PURE__ */ c(Hs, { className: u ? "fixed inset-0 bg-white" : "bg-white/75", children: /* @__PURE__ */ c($t, { className: `animate-spin text-primary ${u ? "h-6 w-6" : "h-5 w-5"}` }) }),
|
|
4117
|
+
xr && /* @__PURE__ */ c(
|
|
4117
4118
|
X,
|
|
4118
4119
|
{
|
|
4119
4120
|
fallback: /* @__PURE__ */ c("div", { className: "absolute inset-0 z-[999999] flex min-h-screen w-screen items-center justify-center bg-gray-100", children: /* @__PURE__ */ c($t, { className: "h-6 w-6 animate-spin text-primary" }) }),
|
|
4120
|
-
children: /* @__PURE__ */ c(
|
|
4121
|
+
children: /* @__PURE__ */ c(Pc, {})
|
|
4121
4122
|
}
|
|
4122
4123
|
),
|
|
4123
4124
|
/* @__PURE__ */ c(
|
|
4124
|
-
|
|
4125
|
+
sa,
|
|
4125
4126
|
{
|
|
4126
4127
|
siteWideUsage: W ?? {},
|
|
4127
4128
|
flags: e.flags ? { ...e.flags, librarySite: Vn } : { librarySite: Vn },
|
|
@@ -4145,26 +4146,26 @@ const Pc = {
|
|
|
4145
4146
|
getPartialBlockBlocks: B,
|
|
4146
4147
|
getPartialBlocks: Te,
|
|
4147
4148
|
blocks: S ? [] : x,
|
|
4148
|
-
theme:
|
|
4149
|
+
theme: Ga(Ke),
|
|
4149
4150
|
pageTypes: a,
|
|
4150
|
-
searchPageTypeItems:
|
|
4151
|
+
searchPageTypeItems: kr,
|
|
4151
4152
|
askAiCallBack: U,
|
|
4152
|
-
onSave: async ({ blocks: ae, theme: Ot, needTranslations:
|
|
4153
|
+
onSave: async ({ blocks: ae, theme: Ot, needTranslations: Rr, designTokens: qn }) => {
|
|
4153
4154
|
if (!h) return !0;
|
|
4154
4155
|
Se.current = ae;
|
|
4155
4156
|
const $n = [...ae];
|
|
4156
|
-
await N({ page: h, blocks: $n, needTranslations:
|
|
4157
|
+
await N({ page: h, blocks: $n, needTranslations: Rr }), Se.current = $n;
|
|
4157
4158
|
const xt = {};
|
|
4158
4159
|
return Jn(Ot, Ke) || (xt.theme = Ot), Jn(qn, f == null ? void 0 : f.designTokens) || (xt.designTokens = qn), fe(xt) || await L({ settings: xt }), !0;
|
|
4159
4160
|
},
|
|
4160
|
-
themePanelComponent:
|
|
4161
|
-
...
|
|
4162
|
-
children: /* @__PURE__ */ c(
|
|
4161
|
+
themePanelComponent: _c,
|
|
4162
|
+
...Dr,
|
|
4163
|
+
children: /* @__PURE__ */ c(yc, { isFetchingPageData: Kn })
|
|
4163
4164
|
}
|
|
4164
4165
|
),
|
|
4165
|
-
/* @__PURE__ */ c("div", { children: /* @__PURE__ */ c(
|
|
4166
|
+
/* @__PURE__ */ c("div", { children: /* @__PURE__ */ c(Ac, {}) })
|
|
4166
4167
|
] });
|
|
4167
|
-
},
|
|
4168
|
+
}, vc = new xa({
|
|
4168
4169
|
defaultOptions: {
|
|
4169
4170
|
queries: {
|
|
4170
4171
|
refetchOnWindowFocus: !1,
|
|
@@ -4172,7 +4173,7 @@ const Pc = {
|
|
|
4172
4173
|
refetchOnMount: !1
|
|
4173
4174
|
}
|
|
4174
4175
|
}
|
|
4175
|
-
}),
|
|
4176
|
+
}), Bu = (e) => {
|
|
4176
4177
|
const [, t] = Dn(), [n, s] = K(!1);
|
|
4177
4178
|
return se(() => (t(
|
|
4178
4179
|
xn(e, [
|
|
@@ -4194,18 +4195,18 @@ const Pc = {
|
|
|
4194
4195
|
}, 200), () => {
|
|
4195
4196
|
s(!1), t({});
|
|
4196
4197
|
}), [e, t]), n ? H(e, "hasReactQueryProvider", !1) === !0 ? /* @__PURE__ */ m(he, { children: [
|
|
4197
|
-
/* @__PURE__ */ c(
|
|
4198
|
-
/* @__PURE__ */ c(
|
|
4199
|
-
] }) : /* @__PURE__ */ m(
|
|
4200
|
-
/* @__PURE__ */ c(
|
|
4201
|
-
/* @__PURE__ */ c(
|
|
4198
|
+
/* @__PURE__ */ c(ps, { ...e }),
|
|
4199
|
+
/* @__PURE__ */ c(Es, {})
|
|
4200
|
+
] }) : /* @__PURE__ */ m(Da, { client: vc, children: [
|
|
4201
|
+
/* @__PURE__ */ c(ps, { ...e }),
|
|
4202
|
+
/* @__PURE__ */ c(Es, {})
|
|
4202
4203
|
] }) : /* @__PURE__ */ c("div", {});
|
|
4203
|
-
},
|
|
4204
|
-
function
|
|
4204
|
+
}, bc = $.lazy(() => import("./nested-path-selector-content-Br1IWhK5.js"));
|
|
4205
|
+
function Ic({ data: e, onSelect: t, dataType: n = "value", disabled: s = !1 }) {
|
|
4205
4206
|
const [r, a] = $.useState(!1);
|
|
4206
|
-
return /* @__PURE__ */ m(
|
|
4207
|
+
return /* @__PURE__ */ m(ra, { open: r, onOpenChange: a, children: [
|
|
4207
4208
|
/* @__PURE__ */ m(en, { children: [
|
|
4208
|
-
/* @__PURE__ */ c(tn, { asChild: !0, children: /* @__PURE__ */ c(
|
|
4209
|
+
/* @__PURE__ */ c(tn, { asChild: !0, children: /* @__PURE__ */ c(aa, { asChild: !0, children: /* @__PURE__ */ c(
|
|
4209
4210
|
M,
|
|
4210
4211
|
{
|
|
4211
4212
|
size: "sm",
|
|
@@ -4229,7 +4230,7 @@ function bc({ data: e, onSelect: t, dataType: n = "value", disabled: s = !1 }) {
|
|
|
4229
4230
|
/* @__PURE__ */ c(nn, { children: "Add field" })
|
|
4230
4231
|
] }),
|
|
4231
4232
|
r && /* @__PURE__ */ c($.Suspense, { children: /* @__PURE__ */ c(
|
|
4232
|
-
|
|
4233
|
+
bc,
|
|
4233
4234
|
{
|
|
4234
4235
|
data: e,
|
|
4235
4236
|
onSelect: t,
|
|
@@ -4240,17 +4241,17 @@ function bc({ data: e, onSelect: t, dataType: n = "value", disabled: s = !1 }) {
|
|
|
4240
4241
|
) })
|
|
4241
4242
|
] });
|
|
4242
4243
|
}
|
|
4243
|
-
const
|
|
4244
|
+
const Fu = () => {
|
|
4244
4245
|
const { savePageAsync: e } = Re(), t = J(), { isLocked: n } = ye();
|
|
4245
4246
|
return z(async () => {
|
|
4246
4247
|
n || await e(), t.invalidateQueries({ queryKey: [E.GET_DRAFT_PAGE] }), t.invalidateQueries({ queryKey: [E.GET_BUILDER_PAGE_DATA] });
|
|
4247
4248
|
}, [e, t, n]);
|
|
4248
|
-
},
|
|
4249
|
+
}, Ku = () => {
|
|
4249
4250
|
const e = J();
|
|
4250
4251
|
return z(() => {
|
|
4251
4252
|
e.clear();
|
|
4252
4253
|
}, [e]);
|
|
4253
|
-
},
|
|
4254
|
+
}, Vu = () => {
|
|
4254
4255
|
const e = b(), t = I(), { data: n } = Le(), s = J();
|
|
4255
4256
|
return Y({
|
|
4256
4257
|
mutationFn: async (r) => {
|
|
@@ -4275,7 +4276,7 @@ const Mu = () => {
|
|
|
4275
4276
|
console.error("Failed to update metadata");
|
|
4276
4277
|
}
|
|
4277
4278
|
});
|
|
4278
|
-
},
|
|
4279
|
+
}, Nc = V(() => import("./digital-asset-manager-b8gDuLnI.js")), Hu = ({
|
|
4279
4280
|
assetId: e,
|
|
4280
4281
|
assetUrl: t,
|
|
4281
4282
|
onChange: n,
|
|
@@ -4314,7 +4315,7 @@ const Mu = () => {
|
|
|
4314
4315
|
className: "h-8 w-8 rounded-full bg-white text-red-500",
|
|
4315
4316
|
onClick: g,
|
|
4316
4317
|
disabled: a,
|
|
4317
|
-
children: h ? /* @__PURE__ */ c(
|
|
4318
|
+
children: h ? /* @__PURE__ */ c(rs, { className: "h-4 w-4" }) : /* @__PURE__ */ c(Za, { className: "h-4 w-4" })
|
|
4318
4319
|
}
|
|
4319
4320
|
),
|
|
4320
4321
|
!h && /* @__PURE__ */ c(
|
|
@@ -4326,7 +4327,7 @@ const Mu = () => {
|
|
|
4326
4327
|
className: "h-8 w-8 rounded-full bg-white/80 hover:bg-white/90",
|
|
4327
4328
|
onClick: f,
|
|
4328
4329
|
disabled: a,
|
|
4329
|
-
children: /* @__PURE__ */ c(
|
|
4330
|
+
children: /* @__PURE__ */ c(as, { className: "h-4 w-4" })
|
|
4330
4331
|
}
|
|
4331
4332
|
)
|
|
4332
4333
|
] })
|
|
@@ -4336,14 +4337,14 @@ const Mu = () => {
|
|
|
4336
4337
|
className: `flex cursor-pointer items-center justify-center rounded-md border border-dashed p-6 ${a ? "cursor-not-allowed opacity-50" : "hover:border-gray-400"}`,
|
|
4337
4338
|
onClick: f,
|
|
4338
4339
|
children: /* @__PURE__ */ m("div", { className: "flex flex-col items-center gap-2", children: [
|
|
4339
|
-
/* @__PURE__ */ c(
|
|
4340
|
+
/* @__PURE__ */ c(as, { className: "h-10 w-10 text-gray-400" }),
|
|
4340
4341
|
/* @__PURE__ */ c("p", { className: "text-sm text-gray-500", children: r })
|
|
4341
4342
|
] })
|
|
4342
4343
|
}
|
|
4343
4344
|
),
|
|
4344
|
-
/* @__PURE__ */ c(
|
|
4345
|
-
/* @__PURE__ */ m(
|
|
4346
|
-
/* @__PURE__ */ c(
|
|
4345
|
+
/* @__PURE__ */ c(vs, { open: o, onOpenChange: l, children: /* @__PURE__ */ m(ia, { className: "h-fit w-full max-w-7xl overflow-hidden p-0", children: [
|
|
4346
|
+
/* @__PURE__ */ m(oa, { className: "hidden border-b px-4 py-2", children: [
|
|
4347
|
+
/* @__PURE__ */ c(la, { children: i("Select Image") }),
|
|
4347
4348
|
/* @__PURE__ */ c(
|
|
4348
4349
|
M,
|
|
4349
4350
|
{
|
|
@@ -4352,12 +4353,12 @@ const Mu = () => {
|
|
|
4352
4353
|
size: "icon",
|
|
4353
4354
|
className: "absolute right-4 top-2",
|
|
4354
4355
|
onClick: d,
|
|
4355
|
-
children: /* @__PURE__ */ c(
|
|
4356
|
+
children: /* @__PURE__ */ c(rs, { className: "h-4 w-4" })
|
|
4356
4357
|
}
|
|
4357
4358
|
)
|
|
4358
4359
|
] }),
|
|
4359
4360
|
/* @__PURE__ */ c("div", { className: "h-full flex-1 p-4", children: /* @__PURE__ */ c(X, { children: /* @__PURE__ */ c(
|
|
4360
|
-
|
|
4361
|
+
Nc,
|
|
4361
4362
|
{
|
|
4362
4363
|
close: d,
|
|
4363
4364
|
onSelect: u,
|
|
@@ -4367,7 +4368,7 @@ const Mu = () => {
|
|
|
4367
4368
|
) }) })
|
|
4368
4369
|
] }) })
|
|
4369
4370
|
] });
|
|
4370
|
-
},
|
|
4371
|
+
}, Lc = (e) => e.replace(/[.*+?^${}()|[\]\\]/g, "\\$&"), ys = (e) => {
|
|
4371
4372
|
if (!e.trim())
|
|
4372
4373
|
return { isValid: !1, parsed: null, placeholders: [], error: { message: "JSON is empty" } };
|
|
4373
4374
|
try {
|
|
@@ -4402,13 +4403,13 @@ const Mu = () => {
|
|
|
4402
4403
|
}
|
|
4403
4404
|
};
|
|
4404
4405
|
}
|
|
4405
|
-
},
|
|
4406
|
+
}, Cc = (e, t) => {
|
|
4406
4407
|
let s = JSON.stringify(e, null, 2);
|
|
4407
4408
|
return t.forEach(({ original: r }, a) => {
|
|
4408
|
-
const i = `"__placeholder_${a}__"`, o = new RegExp(
|
|
4409
|
+
const i = `"__placeholder_${a}__"`, o = new RegExp(Lc(i), "g");
|
|
4409
4410
|
s = s.replace(o, r);
|
|
4410
4411
|
}), s;
|
|
4411
|
-
},
|
|
4412
|
+
}, Gc = (e, t) => {
|
|
4412
4413
|
if (!e) return "";
|
|
4413
4414
|
let n = JSON.stringify(e, null, 2);
|
|
4414
4415
|
const s = /{{([^{}]+)}}/g;
|
|
@@ -4418,7 +4419,7 @@ const Mu = () => {
|
|
|
4418
4419
|
n = n.replace(r[0], i);
|
|
4419
4420
|
}
|
|
4420
4421
|
return n;
|
|
4421
|
-
},
|
|
4422
|
+
}, Oc = V(() => import("./shared-json-ld-Clg_UEhd.js")), qu = ({
|
|
4422
4423
|
value: e,
|
|
4423
4424
|
onChange: t,
|
|
4424
4425
|
disabled: n = !1,
|
|
@@ -4468,30 +4469,31 @@ const Mu = () => {
|
|
|
4468
4469
|
}
|
|
4469
4470
|
};
|
|
4470
4471
|
se(() => {
|
|
4471
|
-
const B =
|
|
4472
|
-
|
|
4472
|
+
const B = ys(e);
|
|
4473
|
+
B.isValid ? Zn(() => {
|
|
4473
4474
|
if (p(null), B.parsed) {
|
|
4474
|
-
const P =
|
|
4475
|
+
const P = Gc(B.parsed, o);
|
|
4475
4476
|
S(P);
|
|
4476
4477
|
} else
|
|
4477
4478
|
S("");
|
|
4478
|
-
|
|
4479
|
+
}) : Zn(() => {
|
|
4479
4480
|
p(B.error), S("");
|
|
4481
|
+
});
|
|
4480
4482
|
}, [e, o]);
|
|
4481
4483
|
const Ae = () => {
|
|
4482
|
-
const B =
|
|
4484
|
+
const B = ys(e);
|
|
4483
4485
|
if (B.isValid && B.parsed) {
|
|
4484
|
-
const P =
|
|
4486
|
+
const P = Cc(B.parsed, B.placeholders);
|
|
4485
4487
|
t(P);
|
|
4486
4488
|
}
|
|
4487
4489
|
}, Te = () => {
|
|
4488
4490
|
h != null && h.position && x.current && (x.current.focus(), x.current.setSelectionRange(h.position, h.position + 1));
|
|
4489
4491
|
};
|
|
4490
|
-
return /* @__PURE__ */ c(
|
|
4492
|
+
return /* @__PURE__ */ c(li, { fallback: /* @__PURE__ */ c("div", { children: "Some error" }), children: /* @__PURE__ */ c("div", { className: "space-y-2", children: /* @__PURE__ */ m(ca, { value: u, onValueChange: g, className: "w-full", children: [
|
|
4491
4493
|
/* @__PURE__ */ m("div", { className: "mb-2 flex items-center justify-between", children: [
|
|
4492
|
-
/* @__PURE__ */ m(
|
|
4494
|
+
/* @__PURE__ */ m(ua, { className: "w-max", children: [
|
|
4493
4495
|
/* @__PURE__ */ m(cn, { value: "edit", className: "flex items-center gap-1", children: [
|
|
4494
|
-
/* @__PURE__ */ c(
|
|
4496
|
+
/* @__PURE__ */ c(Xa, { className: "h-4 w-4" }),
|
|
4495
4497
|
/* @__PURE__ */ c("span", { children: "Edit" })
|
|
4496
4498
|
] }),
|
|
4497
4499
|
/* @__PURE__ */ m(
|
|
@@ -4501,7 +4503,7 @@ const Mu = () => {
|
|
|
4501
4503
|
className: "flex items-center gap-1",
|
|
4502
4504
|
disabled: !e.trim() || h !== null || v,
|
|
4503
4505
|
children: [
|
|
4504
|
-
/* @__PURE__ */ c(
|
|
4506
|
+
/* @__PURE__ */ c(ei, { className: "h-4 w-4" }),
|
|
4505
4507
|
/* @__PURE__ */ c("span", { children: "Preview" })
|
|
4506
4508
|
]
|
|
4507
4509
|
}
|
|
@@ -4513,14 +4515,14 @@ const Mu = () => {
|
|
|
4513
4515
|
className: "flex items-center gap-1",
|
|
4514
4516
|
disabled: !e.trim() || h !== null,
|
|
4515
4517
|
children: [
|
|
4516
|
-
/* @__PURE__ */ c(
|
|
4518
|
+
/* @__PURE__ */ c(ti, { className: "h-4 w-4" }),
|
|
4517
4519
|
/* @__PURE__ */ c("span", { children: "Shared" })
|
|
4518
4520
|
]
|
|
4519
4521
|
}
|
|
4520
4522
|
)
|
|
4521
4523
|
] }),
|
|
4522
4524
|
v ? null : u === "edit" && !s && /* @__PURE__ */ c("div", { className: "flex items-center gap-2", children: /* @__PURE__ */ c(
|
|
4523
|
-
|
|
4525
|
+
Ic,
|
|
4524
4526
|
{
|
|
4525
4527
|
dataType: "value",
|
|
4526
4528
|
data: o ?? {},
|
|
@@ -4538,17 +4540,17 @@ const Mu = () => {
|
|
|
4538
4540
|
onClick: Ae,
|
|
4539
4541
|
className: "absolute right-1 top-1 h-6 w-6 p-1",
|
|
4540
4542
|
disabled: !e.trim() || n || h !== null,
|
|
4541
|
-
children: /* @__PURE__ */ c(
|
|
4543
|
+
children: /* @__PURE__ */ c(ni, {})
|
|
4542
4544
|
}
|
|
4543
4545
|
) }),
|
|
4544
4546
|
v ? /* @__PURE__ */ c("div", { className: "flex h-40 items-center justify-center rounded-md bg-black/20", children: /* @__PURE__ */ m("div", { className: "flex max-w-[400px] flex-col items-center gap-2 rounded-md bg-white p-4 shadow-lg", children: [
|
|
4545
4547
|
/* @__PURE__ */ c("div", { className: "max-w-xl text-center text-xs text-gray-500", children: "JSON-LD for is not added for selected language. JSON LD will be used from default language." }),
|
|
4546
4548
|
/* @__PURE__ */ m(M, { type: "button", variant: "default", size: "sm", onClick: d, children: [
|
|
4547
|
-
/* @__PURE__ */ c(
|
|
4549
|
+
/* @__PURE__ */ c(xs, {}),
|
|
4548
4550
|
"Copy & Edit from default language"
|
|
4549
4551
|
] })
|
|
4550
4552
|
] }) }) : /* @__PURE__ */ c(
|
|
4551
|
-
|
|
4553
|
+
Wn,
|
|
4552
4554
|
{
|
|
4553
4555
|
ref: x,
|
|
4554
4556
|
id: i,
|
|
@@ -4563,9 +4565,9 @@ const Mu = () => {
|
|
|
4563
4565
|
readOnly: s
|
|
4564
4566
|
}
|
|
4565
4567
|
),
|
|
4566
|
-
h && /* @__PURE__ */ m(
|
|
4567
|
-
/* @__PURE__ */ c(
|
|
4568
|
-
/* @__PURE__ */ m(
|
|
4568
|
+
h && /* @__PURE__ */ m(Ea, { variant: "destructive", className: "mt-2", children: [
|
|
4569
|
+
/* @__PURE__ */ c(si, { className: "h-4 w-4" }),
|
|
4570
|
+
/* @__PURE__ */ m(pa, { className: "flex flex-col", children: [
|
|
4569
4571
|
/* @__PURE__ */ c("span", { className: "font-medium", children: "Invalid JSON" }),
|
|
4570
4572
|
/* @__PURE__ */ c("span", { className: "text-sm", children: h.message }),
|
|
4571
4573
|
h.line && h.column && /* @__PURE__ */ m("span", { className: "text-sm", children: [
|
|
@@ -4589,12 +4591,12 @@ const Mu = () => {
|
|
|
4589
4591
|
] })
|
|
4590
4592
|
] }),
|
|
4591
4593
|
/* @__PURE__ */ m(un, { value: "preview", className: "mt-0", children: [
|
|
4592
|
-
/* @__PURE__ */ c(
|
|
4594
|
+
/* @__PURE__ */ c(Wn, { rows: a, value: T, readOnly: !0, className: "cursor-default bg-muted font-mono text-sm" }),
|
|
4593
4595
|
/* @__PURE__ */ c("p", { className: "mt-1 text-xs text-muted-foreground", children: "This is how the JSON will look after placeholder substitution." })
|
|
4594
4596
|
] }),
|
|
4595
|
-
w && /* @__PURE__ */ c(un, { value: "shared", className: "mt-0", children: /* @__PURE__ */ c(X, { children: /* @__PURE__ */ c(
|
|
4597
|
+
w && /* @__PURE__ */ c(un, { value: "shared", className: "mt-0", children: /* @__PURE__ */ c(X, { children: /* @__PURE__ */ c(Oc, {}) }) })
|
|
4596
4598
|
] }) }) });
|
|
4597
|
-
},
|
|
4599
|
+
}, $u = (e) => {
|
|
4598
4600
|
const t = b(), n = I();
|
|
4599
4601
|
return re({
|
|
4600
4602
|
queryKey: [E.GET_CHAI_USER, e],
|
|
@@ -4612,121 +4614,121 @@ const Mu = () => {
|
|
|
4612
4614
|
if (typeof window > "u")
|
|
4613
4615
|
throw new Error("@chaibuilder/pages is not available on the server");
|
|
4614
4616
|
export {
|
|
4615
|
-
|
|
4617
|
+
pu as $,
|
|
4616
4618
|
E as A,
|
|
4617
|
-
|
|
4619
|
+
Hs as B,
|
|
4618
4620
|
F as C,
|
|
4619
|
-
|
|
4621
|
+
Ho as D,
|
|
4620
4622
|
ne as E,
|
|
4621
|
-
|
|
4622
|
-
|
|
4623
|
-
|
|
4624
|
-
|
|
4623
|
+
tr as F,
|
|
4624
|
+
bu as G,
|
|
4625
|
+
Pu as H,
|
|
4626
|
+
wu as I,
|
|
4625
4627
|
Pn as J,
|
|
4626
4628
|
ke as K,
|
|
4627
4629
|
Rt as L,
|
|
4628
|
-
|
|
4629
|
-
|
|
4630
|
-
|
|
4630
|
+
ml as M,
|
|
4631
|
+
vu as N,
|
|
4632
|
+
fl as O,
|
|
4631
4633
|
te as P,
|
|
4632
|
-
|
|
4634
|
+
Eu as Q,
|
|
4633
4635
|
ft as R,
|
|
4634
|
-
|
|
4636
|
+
Tu as S,
|
|
4635
4637
|
Bn as T,
|
|
4636
|
-
|
|
4637
|
-
|
|
4638
|
-
|
|
4638
|
+
ku as U,
|
|
4639
|
+
Ru as V,
|
|
4640
|
+
fu as W,
|
|
4639
4641
|
_n as X,
|
|
4640
|
-
|
|
4641
|
-
|
|
4642
|
-
|
|
4642
|
+
Cu as Y,
|
|
4643
|
+
Tl as Z,
|
|
4644
|
+
Uu as _,
|
|
4643
4645
|
ye as a,
|
|
4644
|
-
|
|
4645
|
-
|
|
4646
|
-
|
|
4647
|
-
|
|
4648
|
-
|
|
4649
|
-
|
|
4650
|
-
|
|
4646
|
+
du as a0,
|
|
4647
|
+
Lu as a1,
|
|
4648
|
+
Ou as a2,
|
|
4649
|
+
Gu as a3,
|
|
4650
|
+
xu as a4,
|
|
4651
|
+
Du as a5,
|
|
4652
|
+
yu as a6,
|
|
4651
4653
|
Z as a7,
|
|
4652
|
-
|
|
4653
|
-
|
|
4654
|
+
Zs as a8,
|
|
4655
|
+
gu as a9,
|
|
4654
4656
|
rn as aA,
|
|
4655
|
-
|
|
4656
|
-
|
|
4657
|
-
|
|
4658
|
-
|
|
4659
|
-
|
|
4660
|
-
|
|
4661
|
-
|
|
4662
|
-
|
|
4663
|
-
|
|
4664
|
-
|
|
4665
|
-
|
|
4657
|
+
Ms as aB,
|
|
4658
|
+
au as aC,
|
|
4659
|
+
lu as aD,
|
|
4660
|
+
qu as aE,
|
|
4661
|
+
ys as aF,
|
|
4662
|
+
iu as aG,
|
|
4663
|
+
cu as aH,
|
|
4664
|
+
uu as aI,
|
|
4665
|
+
ou as aJ,
|
|
4666
|
+
Ao as aK,
|
|
4667
|
+
Ai as aL,
|
|
4666
4668
|
Dn as aM,
|
|
4667
|
-
|
|
4668
|
-
|
|
4669
|
-
|
|
4670
|
-
|
|
4671
|
-
|
|
4672
|
-
|
|
4673
|
-
|
|
4669
|
+
$i as aN,
|
|
4670
|
+
Ic as aO,
|
|
4671
|
+
Hu as aP,
|
|
4672
|
+
Si as aQ,
|
|
4673
|
+
Jc as aR,
|
|
4674
|
+
Ks as aS,
|
|
4675
|
+
Bu as aT,
|
|
4674
4676
|
Le as aU,
|
|
4675
|
-
|
|
4676
|
-
|
|
4677
|
-
|
|
4678
|
-
|
|
4677
|
+
Ku as aV,
|
|
4678
|
+
mc as aW,
|
|
4679
|
+
Fu as aX,
|
|
4680
|
+
Vu as aY,
|
|
4679
4681
|
Rn as aZ,
|
|
4680
|
-
|
|
4681
|
-
|
|
4682
|
-
|
|
4682
|
+
_o as a_,
|
|
4683
|
+
Al as aa,
|
|
4684
|
+
cr as ab,
|
|
4683
4685
|
De as ac,
|
|
4684
|
-
|
|
4685
|
-
|
|
4686
|
+
nc as ad,
|
|
4687
|
+
Au as ae,
|
|
4686
4688
|
Ft as af,
|
|
4687
|
-
|
|
4688
|
-
|
|
4689
|
-
|
|
4690
|
-
|
|
4689
|
+
El as ag,
|
|
4690
|
+
Nu as ah,
|
|
4691
|
+
_u as ai,
|
|
4692
|
+
Su as aj,
|
|
4691
4693
|
Kt as ak,
|
|
4692
|
-
|
|
4693
|
-
|
|
4694
|
-
|
|
4695
|
-
|
|
4696
|
-
|
|
4697
|
-
|
|
4694
|
+
el as al,
|
|
4695
|
+
Iu as am,
|
|
4696
|
+
Fo as an,
|
|
4697
|
+
Oi as ao,
|
|
4698
|
+
$u as ap,
|
|
4699
|
+
Ci as aq,
|
|
4698
4700
|
b as ar,
|
|
4699
4701
|
I as as,
|
|
4700
|
-
|
|
4701
|
-
|
|
4702
|
+
gc as at,
|
|
4703
|
+
ru as au,
|
|
4702
4704
|
zt as av,
|
|
4703
4705
|
oe as aw,
|
|
4704
4706
|
fn as ax,
|
|
4705
4707
|
le as ay,
|
|
4706
|
-
|
|
4707
|
-
|
|
4708
|
+
Rs as az,
|
|
4709
|
+
Bs as b,
|
|
4708
4710
|
ve as c,
|
|
4709
|
-
|
|
4710
|
-
|
|
4711
|
-
|
|
4712
|
-
|
|
4713
|
-
|
|
4714
|
-
|
|
4711
|
+
Xi as d,
|
|
4712
|
+
qs as e,
|
|
4713
|
+
To as f,
|
|
4714
|
+
Fs as g,
|
|
4715
|
+
Zc as h,
|
|
4716
|
+
Xc as i,
|
|
4715
4717
|
Be as j,
|
|
4716
4718
|
Mn as k,
|
|
4717
4719
|
Me as l,
|
|
4718
4720
|
Ce as m,
|
|
4719
|
-
|
|
4720
|
-
|
|
4721
|
-
|
|
4722
|
-
|
|
4723
|
-
|
|
4724
|
-
|
|
4721
|
+
gi as n,
|
|
4722
|
+
eu as o,
|
|
4723
|
+
uc as p,
|
|
4724
|
+
nu as q,
|
|
4725
|
+
su as r,
|
|
4726
|
+
tu as s,
|
|
4725
4727
|
hn as t,
|
|
4726
|
-
|
|
4727
|
-
|
|
4728
|
-
|
|
4728
|
+
Yc as u,
|
|
4729
|
+
jc as v,
|
|
4730
|
+
Mu as w,
|
|
4729
4731
|
j as x,
|
|
4730
|
-
|
|
4731
|
-
|
|
4732
|
+
lr as y,
|
|
4733
|
+
mu as z
|
|
4732
4734
|
};
|