@levo-so/studio 0.1.105 → 0.1.106
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/{BillingStep-2cKT5Pir.js → BillingStep-BNRcxjRl.js} +1 -1
- package/{Button-DtPwDEN0.js → Button-BIpdwMrO.js} +29 -29
- package/{EntryCard-j4uZb2cE.js → EntryCard-yFsTPjEj.js} +2 -2
- package/{LoginCard-asvOHIRg.js → LoginCard-CUapIHAo.js} +2 -2
- package/{LoginForm-BdsPVHdO.js → LoginForm-n-6Z7eVb.js} +1 -1
- package/{LoginModal-CyvbEK26.js → LoginModal-wyVhIJk8.js} +3 -3
- package/{MessageCard-lrXKEsBP.js → MessageCard-C2fU_Bo_.js} +1 -1
- package/{MessageFooter-D-dCrzJH.js → MessageFooter-4qIEK91O.js} +1 -1
- package/{ModalManager-BcPk4sbK.js → ModalManager-D-yKU_15.js} +1 -1
- package/{PendingApprovalCard-hYkupl9A.js → PendingApprovalCard-CDZRD8Jm.js} +2 -2
- package/{PopupRenderer-C7OHYphU-IWM6d7gW.js → PopupRenderer-CV5HY1dP-DlAn5Rc8.js} +281 -280
- package/{bookingCard-BdV2YSkq.js → bookingCard-MDpR8SL_.js} +3 -3
- package/collection.d.ts +5 -4
- package/collection.js +3 -3
- package/{dist-CsX9NP5P.js → dist-BjFMATnH.js} +1258 -896
- package/index.js +441 -440
- package/{generateRadiusScale-BpcgkGtN.js → inlineCollectionTheme-WpCvMKrW.js} +19 -4
- package/package.json +3 -3
- package/studio.css +1 -1
- package/{utils-CZLafTgN.js → utils-B01DL3RB.js} +1 -1
- package/widgets-NzmPF3Ji.js +215 -0
- package/widgets-eu5zXTf-.js +0 -230
- /package/{StripePaymentModal-DrLMN18M.js → StripePaymentModal-Do1xHctU.js} +0 -0
- /package/{dialog-C8-iHixJ.js → dialog-DoxC50i0.js} +0 -0
- /package/{useLogin-B2qE8710.js → useLogin-D4A5iRey.js} +0 -0
package/index.js
CHANGED
|
@@ -1,20 +1,21 @@
|
|
|
1
1
|
"use client";
|
|
2
2
|
import { r as e, t } from "./inlineRteTheme-Ajq9PNpQ.js";
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
5
|
-
import {
|
|
6
|
-
import {
|
|
7
|
-
import { n as
|
|
8
|
-
import { n as
|
|
9
|
-
import {
|
|
10
|
-
import { a as
|
|
11
|
-
import { t as
|
|
12
|
-
import { n as
|
|
13
|
-
import {
|
|
14
|
-
import { c as
|
|
15
|
-
import {
|
|
16
|
-
import
|
|
17
|
-
import
|
|
3
|
+
import { t as n } from "./inlineCollectionTheme-WpCvMKrW.js";
|
|
4
|
+
import { _ as r, g as i, v as a } from "./PopupRenderer-CV5HY1dP-DlAn5Rc8.js";
|
|
5
|
+
import { t as o } from "./RteThemeProvider-Cfepkyer.js";
|
|
6
|
+
import { n as s, r as c, t as l } from "./nodeAlignment-DKCIjzlR.js";
|
|
7
|
+
import { _ as u, a as d, b as f, c as p, d as m, f as h, g, h as _, i as v, l as y, m as b, n as x, o as S, p as C, r as w, s as T, t as E, u as D, v as O, y as k } from "./Button-BIpdwMrO.js";
|
|
8
|
+
import { n as A, t as j } from "./AuthProvider-C6bvedwF.js";
|
|
9
|
+
import { n as M, t as N } from "./ModalManager-D-yKU_15.js";
|
|
10
|
+
import { a as ee, i as te, n as ne, o as re, r as ie, s as ae, t as oe } from "./dialog-DoxC50i0.js";
|
|
11
|
+
import { t as se } from "./useLogin-D4A5iRey.js";
|
|
12
|
+
import { n as ce, t as le } from "./StripePaymentModal-Do1xHctU.js";
|
|
13
|
+
import { c as ue } from "./widgets-NzmPF3Ji.js";
|
|
14
|
+
import { a as de, c as fe, i as pe, l as me, n as he, o as ge, r as _e, s as ve, t as ye } from "./authentication-hnV1BI8s.js";
|
|
15
|
+
import { c as be } from "react/compiler-runtime";
|
|
16
|
+
import { LevoInsightsBlock as xe, LevoInsightsPage as Se, Spinner as Ce, cn as P, errorHandler as we, useLevo as F } from "@levo-so/react";
|
|
17
|
+
import * as Te from "react";
|
|
18
|
+
import I, { Fragment as Ee, Suspense as De, createContext as Oe, forwardRef as ke, lazy as L, memo as Ae, use as je, useCallback as Me, useContext as Ne, useEffect as R, useId as Pe, useLayoutEffect as Fe, useMemo as z, useRef as B, useState as V, useSyncExternalStore as Ie } from "react";
|
|
18
19
|
import { Fragment as H, jsx as U, jsxs as W } from "react/jsx-runtime";
|
|
19
20
|
import Le, { clsx as Re } from "clsx";
|
|
20
21
|
import { createRuntimeFn as ze } from "@vanilla-extract/recipes/createRuntimeFn";
|
|
@@ -545,8 +546,8 @@ var gr = ut.create({
|
|
|
545
546
|
},
|
|
546
547
|
addCommands() {
|
|
547
548
|
let e = (e) => (t) => ({ state: n, tr: r }) => {
|
|
548
|
-
let i =
|
|
549
|
-
return i.length === 0 ? !1 :
|
|
549
|
+
let i = c(n.selection, this.options.types);
|
|
550
|
+
return i.length === 0 ? !1 : s(r, i, "backgroundColor", e(i, t));
|
|
550
551
|
};
|
|
551
552
|
return {
|
|
552
553
|
setNodeBackgroundColor: e((e, t) => t || null),
|
|
@@ -795,7 +796,7 @@ function Lr() {
|
|
|
795
796
|
Pr !== null && (cancelAnimationFrame(Pr), Pr = null);
|
|
796
797
|
}
|
|
797
798
|
function Rr(e) {
|
|
798
|
-
let t = B(null), n = B(!1), r = B(/* @__PURE__ */ new Set()), i = Ie(
|
|
799
|
+
let t = B(null), n = B(!1), r = B(/* @__PURE__ */ new Set()), i = Ie(Me((e) => (r.current.add(e), () => r.current.delete(e)), []), Me(() => n.current, []));
|
|
799
800
|
return R(() => {
|
|
800
801
|
if (!e) {
|
|
801
802
|
n.current && (n.current = !1, r.current.forEach((e) => e()));
|
|
@@ -1294,7 +1295,7 @@ var zr = (e) => ({
|
|
|
1294
1295
|
},
|
|
1295
1296
|
children: [
|
|
1296
1297
|
/* @__PURE__ */ U("style", { children: "\n @keyframes shimmer {\n 0% { background-position: 200% 0; }\n 100% { background-position: -200% 0; }\n }\n @keyframes scanLine {\n 0% { top: 0%; opacity: 0; }\n 5% { opacity: 1; }\n 50% { top: calc(100% - 2px); }\n 55% { opacity: 0.6; }\n 95% { opacity: 1; }\n 100% { top: 0%; opacity: 0; }\n }\n " }),
|
|
1297
|
-
Object.keys(f).map((t) => /* @__PURE__ */ W(
|
|
1298
|
+
Object.keys(f).map((t) => /* @__PURE__ */ W(Ee, { children: [/* @__PURE__ */ U(Kr, {
|
|
1298
1299
|
type: t,
|
|
1299
1300
|
item: e.hovered[t],
|
|
1300
1301
|
isSelected: !1,
|
|
@@ -3426,7 +3427,7 @@ var li = (e, t) => e ? e.replace(/\{([\w.-]+)\}/g, (e, n) => {
|
|
|
3426
3427
|
strict: t,
|
|
3427
3428
|
children: e
|
|
3428
3429
|
}), fa = (e) => {
|
|
3429
|
-
let t =
|
|
3430
|
+
let t = F(), { blockData: n, parsedBlockData: r, setParsedBlockData: i, pageContext: a, blockContext: o, workspace_id: s } = k(), c = {
|
|
3430
3431
|
page: 1,
|
|
3431
3432
|
...(r?.source?.find((t) => t.field_key === e))?.params?.query
|
|
3432
3433
|
}, [l, u] = V(c), [d, f] = V(!1), [p, m] = V(o?.[e]), h = (e) => {
|
|
@@ -3475,7 +3476,7 @@ var li = (e, t) => e ? e.replace(/\{([\w.-]+)\}/g, (e, n) => {
|
|
|
3475
3476
|
meta: p?.content?.meta
|
|
3476
3477
|
};
|
|
3477
3478
|
}, pa = (e) => {
|
|
3478
|
-
let t =
|
|
3479
|
+
let t = F(), { parsedBlockData: n, blockContext: r, workspace_id: i } = k(), a = n?.source?.find((t) => t.field_key === e), o = {
|
|
3479
3480
|
page: 1,
|
|
3480
3481
|
...a?.params?.query
|
|
3481
3482
|
}, [s, c] = V(o), [l, u] = V(!1), [d, f] = V(r?.[e]), p = (e) => {
|
|
@@ -3515,10 +3516,10 @@ var li = (e, t) => e ? e.replace(/\{([\w.-]+)\}/g, (e, n) => {
|
|
|
3515
3516
|
response: d?.content
|
|
3516
3517
|
};
|
|
3517
3518
|
}, ma = (e) => {
|
|
3518
|
-
let { pageContext: t, pageSource: n } =
|
|
3519
|
+
let { pageContext: t, pageSource: n } = k(), r = n?.find((t) => t.module === e)?.identifier;
|
|
3519
3520
|
return r ? t?.[r] : {};
|
|
3520
3521
|
}, ha = (e) => {
|
|
3521
|
-
let { pageMeta: t, pageSource: n } =
|
|
3522
|
+
let { pageMeta: t, pageSource: n } = k(), r = n?.find((t) => t.module === e)?.identifier;
|
|
3522
3523
|
return r ? t?.[r] : null;
|
|
3523
3524
|
}, ga = {
|
|
3524
3525
|
REGISTER_BLOCK: "REGISTER_BLOCK",
|
|
@@ -3597,14 +3598,14 @@ var li = (e, t) => e ? e.replace(/\{([\w.-]+)\}/g, (e, n) => {
|
|
|
3597
3598
|
getAllBlocks() {
|
|
3598
3599
|
return this.blocks;
|
|
3599
3600
|
}
|
|
3600
|
-
}, va = _a.getInstance(), ya =
|
|
3601
|
-
let i =
|
|
3601
|
+
}, va = _a.getInstance(), ya = I.memo(({ block_key: e, block_version: t, blocks: n, ...r }) => {
|
|
3602
|
+
let i = I.useMemo(() => `${e}:${t}`, [e, t]), a = n[i];
|
|
3602
3603
|
if (!a) return console.warn(`[LevoBlock.tsx] Block Not Found - ${i}`), null;
|
|
3603
3604
|
let { settings: o, source: s, ...c } = r;
|
|
3604
3605
|
return /* @__PURE__ */ U(a, { ...c });
|
|
3605
3606
|
});
|
|
3606
3607
|
ya.displayName = "BlockSelector";
|
|
3607
|
-
var ba =
|
|
3608
|
+
var ba = I.memo(({ html_id: e, renderMode: t = "live", blocks: n, parsedBlockData: r, blockData: i, pageContext: a, pageMeta: o, blockContext: s, workspace_id: c, pageSource: l }) => /* @__PURE__ */ U(O, {
|
|
3608
3609
|
value: {
|
|
3609
3610
|
parsedBlockData: r,
|
|
3610
3611
|
blockData: i,
|
|
@@ -3619,7 +3620,7 @@ var ba = F.memo(({ html_id: e, renderMode: t = "live", blocks: n, parsedBlockDat
|
|
|
3619
3620
|
id: e ?? r.id,
|
|
3620
3621
|
"data-levo-element": "block",
|
|
3621
3622
|
"data-levo-block-id": r.id,
|
|
3622
|
-
children: [t === "live" && /* @__PURE__ */ U(
|
|
3623
|
+
children: [t === "live" && /* @__PURE__ */ U(xe, { id: r.id }), /* @__PURE__ */ U(ya, {
|
|
3623
3624
|
id: r.id,
|
|
3624
3625
|
block_key: r.key,
|
|
3625
3626
|
block_version: r.version,
|
|
@@ -3819,8 +3820,8 @@ var Ca = ({ site: e }) => {
|
|
|
3819
3820
|
siteSlug: e?.slug,
|
|
3820
3821
|
siteName: e?.name
|
|
3821
3822
|
})] });
|
|
3822
|
-
}, wa = { loadingContainer: "_loadingContainer_1d4on_1" }, Ta =
|
|
3823
|
-
"authentication.NOT_LOGGED_IN": ({ logo: e, siteName: t, page: n }) => /* @__PURE__ */ U(
|
|
3823
|
+
}, wa = { loadingContainer: "_loadingContainer_1d4on_1" }, Ta = L(() => import("./LoginCard-CUapIHAo.js")), Ea = L(() => import("./EntryCard-yFsTPjEj.js")), Da = L(() => import("./MessageCard-C2fU_Bo_.js")), Oa = {
|
|
3824
|
+
"authentication.NOT_LOGGED_IN": ({ logo: e, siteName: t, page: n }) => /* @__PURE__ */ U(De, {
|
|
3824
3825
|
fallback: /* @__PURE__ */ U("div", {}),
|
|
3825
3826
|
children: /* @__PURE__ */ U(Ta, {
|
|
3826
3827
|
logo: e,
|
|
@@ -3828,7 +3829,7 @@ var Ca = ({ site: e }) => {
|
|
|
3828
3829
|
page: n
|
|
3829
3830
|
})
|
|
3830
3831
|
}),
|
|
3831
|
-
"gating.ENTRY_NOT_FOUND": ({ logo: e, siteName: t, accessResponse: n, page: r, onSuccess: i }) => /* @__PURE__ */ U(
|
|
3832
|
+
"gating.ENTRY_NOT_FOUND": ({ logo: e, siteName: t, accessResponse: n, page: r, onSuccess: i }) => /* @__PURE__ */ U(De, {
|
|
3832
3833
|
fallback: /* @__PURE__ */ U("div", {}),
|
|
3833
3834
|
children: /* @__PURE__ */ U(Ea, {
|
|
3834
3835
|
logo: e,
|
|
@@ -3838,7 +3839,7 @@ var Ca = ({ site: e }) => {
|
|
|
3838
3839
|
onSuccess: i
|
|
3839
3840
|
})
|
|
3840
3841
|
}),
|
|
3841
|
-
"gating.ENTRY_CONDITION_NOT_FULFILLED": ({ logo: e, siteName: t, accessResponse: n }) => /* @__PURE__ */ U(
|
|
3842
|
+
"gating.ENTRY_CONDITION_NOT_FULFILLED": ({ logo: e, siteName: t, accessResponse: n }) => /* @__PURE__ */ U(De, {
|
|
3842
3843
|
fallback: /* @__PURE__ */ U("div", {}),
|
|
3843
3844
|
children: /* @__PURE__ */ U(Da, {
|
|
3844
3845
|
logo: e,
|
|
@@ -3848,7 +3849,7 @@ var Ca = ({ site: e }) => {
|
|
|
3848
3849
|
})
|
|
3849
3850
|
})
|
|
3850
3851
|
}, ka = ({ page: e, site: t, children: n, authOverride: r }) => {
|
|
3851
|
-
let i =
|
|
3852
|
+
let i = F(), { isLoggedIn: a, account: o, isAuthLoaded: s } = A(), [c, l] = V(!e.access?.length), [u, d] = V(null), [f, p] = V(!!e.access?.length), [m, h] = V(null), g = async () => {
|
|
3852
3853
|
p(!0);
|
|
3853
3854
|
try {
|
|
3854
3855
|
let t = (await i?.fetch?.url(`/v1/studio/page/${e.id}/check-access`)?.post()?.json())?.content?.data;
|
|
@@ -3870,7 +3871,7 @@ var Ca = ({ site: e }) => {
|
|
|
3870
3871
|
]), c || r?.enabled) return /* @__PURE__ */ U(H, { children: n });
|
|
3871
3872
|
if (f) return /* @__PURE__ */ W("div", {
|
|
3872
3873
|
className: wa.loadingContainer,
|
|
3873
|
-
children: [/* @__PURE__ */ U(
|
|
3874
|
+
children: [/* @__PURE__ */ U(Ce, {}), " Checking access"]
|
|
3874
3875
|
});
|
|
3875
3876
|
if (m && m in Oa) {
|
|
3876
3877
|
let n = Oa[m];
|
|
@@ -3884,7 +3885,7 @@ var Ca = ({ site: e }) => {
|
|
|
3884
3885
|
}
|
|
3885
3886
|
return null;
|
|
3886
3887
|
}, Aa = ({ pageData: e, parsedPageData: t, renderMode: n = "live", context: r, blocks: i, site: a, workspace: o, authOverride: s, disableBranding: c }) => {
|
|
3887
|
-
let { isLoggedIn: l } =
|
|
3888
|
+
let { isLoggedIn: l } = A(), u = si(t, a);
|
|
3888
3889
|
return /* @__PURE__ */ W("div", {
|
|
3889
3890
|
"data-levo-element": "page",
|
|
3890
3891
|
"data-levo-page-id": t?.id,
|
|
@@ -3896,8 +3897,8 @@ var Ca = ({ site: e }) => {
|
|
|
3896
3897
|
page: t,
|
|
3897
3898
|
authOverride: s,
|
|
3898
3899
|
children: [
|
|
3899
|
-
n === "live" && /* @__PURE__ */ U(
|
|
3900
|
-
n === "live" && /* @__PURE__ */ U(
|
|
3900
|
+
n === "live" && /* @__PURE__ */ U(Se, { id: t?.id }),
|
|
3901
|
+
n === "live" && /* @__PURE__ */ U(f, {
|
|
3901
3902
|
siteId: a?.id,
|
|
3902
3903
|
pageId: t?.id
|
|
3903
3904
|
}),
|
|
@@ -3918,14 +3919,14 @@ var Ca = ({ site: e }) => {
|
|
|
3918
3919
|
!c && o?.feature_flag?.branding && /* @__PURE__ */ U(Ca, { site: a })
|
|
3919
3920
|
]
|
|
3920
3921
|
});
|
|
3921
|
-
}, ja = ({ pageData: e, parsedPageData: t, renderMode: n = "live", context: r, blocks: i, site: a, workspace: o, authOverride: s, disableBranding: c }) => /* @__PURE__ */ U(
|
|
3922
|
+
}, ja = ({ pageData: e, parsedPageData: t, renderMode: n = "live", context: r, blocks: i, site: a, workspace: o, authOverride: s, disableBranding: c }) => /* @__PURE__ */ U(De, {
|
|
3922
3923
|
fallback: /* @__PURE__ */ U("center", { className: "flex h-screen w-full items-center justify-center" }),
|
|
3923
3924
|
children: /* @__PURE__ */ U(da, {
|
|
3924
3925
|
strict: !0,
|
|
3925
|
-
children: /* @__PURE__ */ U(
|
|
3926
|
+
children: /* @__PURE__ */ U(j, {
|
|
3926
3927
|
workspace: o,
|
|
3927
3928
|
authOverride: s,
|
|
3928
|
-
children: /* @__PURE__ */ U(
|
|
3929
|
+
children: /* @__PURE__ */ U(N, {
|
|
3929
3930
|
siteName: a?.name,
|
|
3930
3931
|
children: /* @__PURE__ */ U(Aa, {
|
|
3931
3932
|
authOverride: s,
|
|
@@ -4059,7 +4060,7 @@ var La = ({ blocks: e, studioData: t, site: n, workspace_id: r }) => {
|
|
|
4059
4060
|
})
|
|
4060
4061
|
] }) : null;
|
|
4061
4062
|
}, za = ({ blocks: e }) => {
|
|
4062
|
-
let [t, n] = V(null), [r, i] = V({}), [a, o] = V(null), s =
|
|
4063
|
+
let [t, n] = V(null), [r, i] = V({}), [a, o] = V(null), s = Me((e) => {
|
|
4063
4064
|
let { data: t } = e, { type: a, payload: s } = t;
|
|
4064
4065
|
switch (a) {
|
|
4065
4066
|
case J.PREVIEW_TYPE:
|
|
@@ -4138,7 +4139,7 @@ function Va({ className: e, elementKey: t, generatedClassName: n, content: r, co
|
|
|
4138
4139
|
return /* @__PURE__ */ U(An.Root, {
|
|
4139
4140
|
"data-levo_element_key": t,
|
|
4140
4141
|
"data-levo_element_type": "AccordionRoot",
|
|
4141
|
-
className:
|
|
4142
|
+
className: P("AccordionRoot", e, n),
|
|
4142
4143
|
...o
|
|
4143
4144
|
});
|
|
4144
4145
|
}
|
|
@@ -4147,7 +4148,7 @@ function Ha({ className: e, elementKey: t, generatedClassName: n, content: r, co
|
|
|
4147
4148
|
return /* @__PURE__ */ U(An.Item, {
|
|
4148
4149
|
"data-levo_element_key": t,
|
|
4149
4150
|
"data-levo_element_type": "AccordionItem",
|
|
4150
|
-
className:
|
|
4151
|
+
className: P(Ba.accordionItem, e, n),
|
|
4151
4152
|
...o
|
|
4152
4153
|
});
|
|
4153
4154
|
}
|
|
@@ -4158,7 +4159,7 @@ function Ua({ className: e, children: t, elementKey: n, generatedClassName: r, c
|
|
|
4158
4159
|
children: /* @__PURE__ */ W(An.Trigger, {
|
|
4159
4160
|
"data-levo_element_key": n,
|
|
4160
4161
|
"data-levo_element_type": "AccordionTrigger",
|
|
4161
|
-
className:
|
|
4162
|
+
className: P(Ba.accordionTrigger, e, r),
|
|
4162
4163
|
...s,
|
|
4163
4164
|
children: [t, /* @__PURE__ */ U(nn, { className: Ba.accordionChevron })]
|
|
4164
4165
|
})
|
|
@@ -4167,18 +4168,18 @@ function Ua({ className: e, children: t, elementKey: n, generatedClassName: r, c
|
|
|
4167
4168
|
Ua.displayName = "BaseAccordionTrigger";
|
|
4168
4169
|
function Wa({ className: e, children: t, elementKey: n, generatedClassName: r, content: i, config: a, styles: o, ...s }) {
|
|
4169
4170
|
return /* @__PURE__ */ U(An.Content, {
|
|
4170
|
-
className:
|
|
4171
|
+
className: P(Ba.accordionContent, e),
|
|
4171
4172
|
...s,
|
|
4172
4173
|
children: /* @__PURE__ */ U("div", {
|
|
4173
4174
|
"data-levo_element_key": n,
|
|
4174
4175
|
"data-levo_element_type": "AccordionContent",
|
|
4175
|
-
className:
|
|
4176
|
+
className: P(Ba.accordionContentText, r),
|
|
4176
4177
|
children: t
|
|
4177
4178
|
})
|
|
4178
4179
|
});
|
|
4179
4180
|
}
|
|
4180
4181
|
Wa.displayName = "BaseAccordionContent";
|
|
4181
|
-
var Ga =
|
|
4182
|
+
var Ga = v(Va), Ka = v(Ha), qa = v(Ua), Ja = v(Wa), Ya = () => [
|
|
4182
4183
|
cr,
|
|
4183
4184
|
tt,
|
|
4184
4185
|
at,
|
|
@@ -4195,14 +4196,14 @@ var Ga = _(Va), Ka = _(Ha), qa = _(Ua), Ja = _(Wa), Ya = () => [
|
|
|
4195
4196
|
ct,
|
|
4196
4197
|
Ze.configure({ openOnClick: !1 }),
|
|
4197
4198
|
ot,
|
|
4198
|
-
|
|
4199
|
+
i,
|
|
4199
4200
|
st,
|
|
4200
4201
|
it,
|
|
4201
4202
|
rt,
|
|
4202
4203
|
Ge,
|
|
4203
4204
|
Ye.configure({ multicolor: !0 }),
|
|
4204
4205
|
gr,
|
|
4205
|
-
|
|
4206
|
+
r,
|
|
4206
4207
|
lt.configure({ types: [
|
|
4207
4208
|
"table",
|
|
4208
4209
|
"paragraph",
|
|
@@ -4217,7 +4218,7 @@ var Ga = _(Va), Ka = _(Ha), qa = _(Ua), Ja = _(Wa), Ya = () => [
|
|
|
4217
4218
|
bt.configure({ nested: !0 }),
|
|
4218
4219
|
Sr.configure({ table: { cellMinWidth: 120 } }),
|
|
4219
4220
|
mr,
|
|
4220
|
-
|
|
4221
|
+
l,
|
|
4221
4222
|
$n,
|
|
4222
4223
|
tr,
|
|
4223
4224
|
sr,
|
|
@@ -4231,7 +4232,7 @@ var Ga = _(Va), Ka = _(Ha), qa = _(Ua), Ja = _(Wa), Ya = () => [
|
|
|
4231
4232
|
if (e.type === "text") return e.value;
|
|
4232
4233
|
if (e.type === "element") {
|
|
4233
4234
|
let { className: n, ...r } = e.properties || {};
|
|
4234
|
-
return
|
|
4235
|
+
return I.createElement(e.tagName, {
|
|
4235
4236
|
key: t,
|
|
4236
4237
|
...r,
|
|
4237
4238
|
className: Array.isArray(n) ? n.join(" ") : n
|
|
@@ -4254,7 +4255,7 @@ var Ga = _(Va), Ka = _(Ha), qa = _(Ua), Ja = _(Wa), Ya = () => [
|
|
|
4254
4255
|
}
|
|
4255
4256
|
return "";
|
|
4256
4257
|
}, $a = ({ node: e, children: t }) => {
|
|
4257
|
-
let n =
|
|
4258
|
+
let n = je(Xa), r = e?.attrs?.language, i = Qa(e);
|
|
4258
4259
|
if (!i) return /* @__PURE__ */ U("pre", { children: /* @__PURE__ */ U("code", { children: t }) });
|
|
4259
4260
|
let a;
|
|
4260
4261
|
try {
|
|
@@ -4267,19 +4268,19 @@ var Ga = _(Va), Ka = _(Ha), qa = _(Ua), Ja = _(Wa), Ya = () => [
|
|
|
4267
4268
|
children: a.children.map((e, t) => Za(e, `code-${t}`))
|
|
4268
4269
|
}) });
|
|
4269
4270
|
}, eo = (e) => {
|
|
4270
|
-
let t =
|
|
4271
|
+
let t = be(9), n;
|
|
4271
4272
|
t[0] === e.node ? n = t[1] : (n = Qa(e.node), t[0] = e.node, t[1] = n);
|
|
4272
4273
|
let r = n, i;
|
|
4273
4274
|
t[2] === r ? i = t[3] : (i = /* @__PURE__ */ U("pre", { children: /* @__PURE__ */ U("code", { children: r }) }), t[2] = r, t[3] = i);
|
|
4274
4275
|
let a;
|
|
4275
4276
|
t[4] === e ? a = t[5] : (a = /* @__PURE__ */ U($a, { ...e }), t[4] = e, t[5] = a);
|
|
4276
4277
|
let o;
|
|
4277
|
-
return t[6] !== i || t[7] !== a ? (o = /* @__PURE__ */ U(
|
|
4278
|
+
return t[6] !== i || t[7] !== a ? (o = /* @__PURE__ */ U(I.Suspense, {
|
|
4278
4279
|
fallback: i,
|
|
4279
4280
|
children: a
|
|
4280
4281
|
}), t[6] = i, t[7] = a, t[8] = o) : o = t[8], o;
|
|
4281
|
-
}, to =
|
|
4282
|
-
let t =
|
|
4282
|
+
}, to = Oe({ open: !1 }), no = (e) => {
|
|
4283
|
+
let t = be(14), { node: n, children: r } = e, [i, a] = V(n.attrs?.open || !1), o = i && "is-open", s;
|
|
4283
4284
|
t[0] === o ? s = t[1] : (s = Re("details", o), t[0] = o, t[1] = s);
|
|
4284
4285
|
let c;
|
|
4285
4286
|
t[2] === i ? c = t[3] : (c = /* @__PURE__ */ U("button", {
|
|
@@ -4300,10 +4301,10 @@ var Ga = _(Va), Ka = _(Ha), qa = _(Ua), Ja = _(Wa), Ya = () => [
|
|
|
4300
4301
|
children: [c, u]
|
|
4301
4302
|
}), t[9] = i, t[10] = s, t[11] = c, t[12] = u, t[13] = d) : d = t[13], d;
|
|
4302
4303
|
}, ro = (e) => {
|
|
4303
|
-
let t =
|
|
4304
|
+
let t = be(2), { children: n } = e, r;
|
|
4304
4305
|
return t[0] === n ? r = t[1] : (r = /* @__PURE__ */ U("summary", { children: n }), t[0] = n, t[1] = r), r;
|
|
4305
4306
|
}, io = (e) => {
|
|
4306
|
-
let t =
|
|
4307
|
+
let t = be(5), { children: n } = e, { open: r } = Ne(to), i;
|
|
4307
4308
|
t[0] === r ? i = t[1] : (i = r ? {} : { hidden: !0 }, t[0] = r, t[1] = i);
|
|
4308
4309
|
let a;
|
|
4309
4310
|
return t[2] !== n || t[3] !== i ? (a = /* @__PURE__ */ U("div", {
|
|
@@ -4312,13 +4313,13 @@ var Ga = _(Va), Ka = _(Ha), qa = _(Ua), Ja = _(Wa), Ya = () => [
|
|
|
4312
4313
|
children: n
|
|
4313
4314
|
}), t[2] = n, t[3] = i, t[4] = a) : a = t[4], a;
|
|
4314
4315
|
}, ao = "_10kj0ro0", oo = "_10kj0ro1", so = "_10kj0ro3", co = "_10kj0ro4", lo = (e) => {
|
|
4315
|
-
let t =
|
|
4316
|
+
let t = be(3), { node: n, children: r } = e, i;
|
|
4316
4317
|
return t[0] !== r || t[1] !== n ? (i = /* @__PURE__ */ U(uo, {
|
|
4317
4318
|
node: n,
|
|
4318
4319
|
children: r
|
|
4319
4320
|
}), t[0] = r, t[1] = n, t[2] = i) : i = t[2], i;
|
|
4320
4321
|
}, uo = (e) => {
|
|
4321
|
-
let t =
|
|
4322
|
+
let t = be(29), { node: n, children: r, wrapperAs: i, wrapperProps: a, containerRef: o, containerClassName: s, containerStyle: c, containerExtras: l, imageRef: u, imageProps: d, caption: f } = e, p = i === void 0 ? "div" : i, m = n.attrs, { src: h, alt: g, srcset: _, showCaption: v } = m, y = m["data-align"], b = m["data-link-href"], x = n.content.childCount > 0, S = f === void 0 ? r : f, C = (v || x) && S != null;
|
|
4322
4323
|
if (!h) return null;
|
|
4323
4324
|
let w = g || "", T = _ || void 0, E;
|
|
4324
4325
|
t[0] !== d || t[1] !== u || t[2] !== h || t[3] !== w || t[4] !== T ? (E = /* @__PURE__ */ U("img", {
|
|
@@ -4344,13 +4345,13 @@ var Ga = _(Va), Ka = _(Ha), qa = _(Ua), Ja = _(Wa), Ya = () => [
|
|
|
4344
4345
|
rel: "noopener noreferrer",
|
|
4345
4346
|
children: D
|
|
4346
4347
|
}) : D, t[11] = D, t[12] = b, t[13] = j) : j = t[13];
|
|
4347
|
-
let
|
|
4348
|
-
t[14] !== S || t[15] !== C ? (
|
|
4348
|
+
let M;
|
|
4349
|
+
t[14] !== S || t[15] !== C ? (M = C && /* @__PURE__ */ U("div", {
|
|
4349
4350
|
className: Re("figcaption", "_10kj0ro8"),
|
|
4350
4351
|
children: S
|
|
4351
|
-
}), t[14] = S, t[15] = C, t[16] =
|
|
4352
|
-
let
|
|
4353
|
-
t[17] !== l || t[18] !== o || t[19] !== O || t[20] !== A || t[21] !== j || t[22] !==
|
|
4352
|
+
}), t[14] = S, t[15] = C, t[16] = M) : M = t[16];
|
|
4353
|
+
let N;
|
|
4354
|
+
t[17] !== l || t[18] !== o || t[19] !== O || t[20] !== A || t[21] !== j || t[22] !== M ? (N = /* @__PURE__ */ U("div", {
|
|
4354
4355
|
className: so,
|
|
4355
4356
|
children: /* @__PURE__ */ W("div", {
|
|
4356
4357
|
ref: o,
|
|
@@ -4359,20 +4360,20 @@ var Ga = _(Va), Ka = _(Ha), qa = _(Ua), Ja = _(Wa), Ya = () => [
|
|
|
4359
4360
|
children: [
|
|
4360
4361
|
j,
|
|
4361
4362
|
l,
|
|
4362
|
-
|
|
4363
|
+
M
|
|
4363
4364
|
]
|
|
4364
4365
|
})
|
|
4365
|
-
}), t[17] = l, t[18] = o, t[19] = O, t[20] = A, t[21] = j, t[22] =
|
|
4366
|
-
let
|
|
4367
|
-
return t[24] !== p || t[25] !== y || t[26] !==
|
|
4366
|
+
}), t[17] = l, t[18] = o, t[19] = O, t[20] = A, t[21] = j, t[22] = M, t[23] = N) : N = t[23];
|
|
4367
|
+
let ee;
|
|
4368
|
+
return t[24] !== p || t[25] !== y || t[26] !== N || t[27] !== a ? (ee = /* @__PURE__ */ U(p, {
|
|
4368
4369
|
"data-align": y,
|
|
4369
4370
|
className: ao,
|
|
4370
4371
|
...a,
|
|
4371
|
-
children:
|
|
4372
|
-
}), t[24] = p, t[25] = y, t[26] =
|
|
4372
|
+
children: N
|
|
4373
|
+
}), t[24] = p, t[25] = y, t[26] = N, t[27] = a, t[28] = ee) : ee = t[28], ee;
|
|
4373
4374
|
}, fo = Ya(), po = (e) => Be(e, fo), mo = (t) => {
|
|
4374
|
-
let n =
|
|
4375
|
-
n[0] === t ? (r = n[1], i = n[2],
|
|
4375
|
+
let n = be(18), r, i, a, s, c;
|
|
4376
|
+
n[0] === t ? (r = n[1], i = n[2], a = n[3], s = n[4], c = n[5]) : ({content: i, className: r, ref: a, theme: c, ...s} = t, n[0] = t, n[1] = r, n[2] = i, n[3] = a, n[4] = s, n[5] = c);
|
|
4376
4377
|
let l;
|
|
4377
4378
|
n[6] === i ? l = n[7] : (l = Ve({
|
|
4378
4379
|
content: i,
|
|
@@ -4388,18 +4389,18 @@ var Ga = _(Va), Ka = _(Ha), qa = _(Ua), Ja = _(Wa), Ya = () => [
|
|
|
4388
4389
|
let u = l, d;
|
|
4389
4390
|
n[8] === r ? d = n[9] : (d = Le(e, r), n[8] = r, n[9] = d);
|
|
4390
4391
|
let f;
|
|
4391
|
-
n[10] !== u || n[11] !==
|
|
4392
|
-
ref:
|
|
4392
|
+
n[10] !== u || n[11] !== a || n[12] !== s || n[13] !== d ? (f = /* @__PURE__ */ U("div", {
|
|
4393
|
+
ref: a,
|
|
4393
4394
|
className: d,
|
|
4394
4395
|
...s,
|
|
4395
4396
|
children: u
|
|
4396
|
-
}), n[10] = u, n[11] =
|
|
4397
|
+
}), n[10] = u, n[11] = a, n[12] = s, n[13] = d, n[14] = f) : f = n[14];
|
|
4397
4398
|
let p;
|
|
4398
|
-
return n[15] !== f || n[16] !== c ? (p = /* @__PURE__ */ U(
|
|
4399
|
+
return n[15] !== f || n[16] !== c ? (p = /* @__PURE__ */ U(o, {
|
|
4399
4400
|
theme: c,
|
|
4400
4401
|
children: f
|
|
4401
4402
|
}), n[15] = f, n[16] = c, n[17] = p) : p = n[17], p;
|
|
4402
|
-
}, ho = ({ className: e, content: n, config: r, styles:
|
|
4403
|
+
}, ho = ({ className: e, content: n, config: r, styles: i, elementKey: o, generatedClassName: s, ref: c, ...l }) => {
|
|
4403
4404
|
let u = z(() => {
|
|
4404
4405
|
if (n && typeof n == "object") {
|
|
4405
4406
|
if ("json" in n && n.json) return n.json;
|
|
@@ -4410,7 +4411,7 @@ var Ga = _(Va), Ka = _(Ha), qa = _(Ua), Ja = _(Wa), Ya = () => [
|
|
|
4410
4411
|
if (!r?.theme) return;
|
|
4411
4412
|
let { baseSpacing: e, ...n } = r.theme;
|
|
4412
4413
|
return {
|
|
4413
|
-
...
|
|
4414
|
+
...a(n),
|
|
4414
4415
|
...e ? t({ baseSpacing: e }) : void 0
|
|
4415
4416
|
};
|
|
4416
4417
|
}, [r?.theme]);
|
|
@@ -4419,13 +4420,13 @@ var Ga = _(Va), Ka = _(Ha), qa = _(Ua), Ja = _(Wa), Ya = () => [
|
|
|
4419
4420
|
content: u,
|
|
4420
4421
|
"data-levo_element_key": o,
|
|
4421
4422
|
"data-levo_element_type": "BlogContent",
|
|
4422
|
-
className:
|
|
4423
|
+
className: P("mx-0 min-h-6 w-auto max-w-none", e, s),
|
|
4423
4424
|
theme: d ? { style: d } : void 0,
|
|
4424
4425
|
...l
|
|
4425
4426
|
});
|
|
4426
4427
|
};
|
|
4427
4428
|
ho.displayName = "BaseBlogContent";
|
|
4428
|
-
var go =
|
|
4429
|
+
var go = v(ho), _o = ({ backgroundVideo: e }) => e?.media?.location ? /* @__PURE__ */ W(H, { children: [/* @__PURE__ */ U("video", {
|
|
4429
4430
|
className: "background_video",
|
|
4430
4431
|
autoPlay: !0,
|
|
4431
4432
|
loop: !0,
|
|
@@ -4448,30 +4449,30 @@ var go = _(ho), _o = ({ backgroundVideo: e }) => e?.media?.location ? /* @__PURE
|
|
|
4448
4449
|
inset: 0,
|
|
4449
4450
|
zIndex: -1
|
|
4450
4451
|
}
|
|
4451
|
-
})] }) : null, vo =
|
|
4452
|
+
})] }) : null, vo = ke(({ children: e, className: t, elementKey: n, generatedClassName: r, content: i, config: a, styles: o, ...s }, c) => /* @__PURE__ */ W("div", {
|
|
4452
4453
|
ref: c,
|
|
4453
4454
|
"data-levo_element_key": n,
|
|
4454
4455
|
"data-levo_element_type": "Box",
|
|
4455
|
-
className:
|
|
4456
|
+
className: P(t, r),
|
|
4456
4457
|
...s,
|
|
4457
4458
|
children: [/* @__PURE__ */ U(_o, { backgroundVideo: a?.backgroundVideo }), e]
|
|
4458
4459
|
}));
|
|
4459
4460
|
vo.displayName = "BaseBox";
|
|
4460
|
-
var yo =
|
|
4461
|
+
var yo = v(vo), bo = I.createContext(null);
|
|
4461
4462
|
function xo() {
|
|
4462
|
-
let e =
|
|
4463
|
+
let e = I.useContext(bo);
|
|
4463
4464
|
if (!e) throw Error("useCarousel must be used within a <Carousel />");
|
|
4464
4465
|
return e;
|
|
4465
4466
|
}
|
|
4466
4467
|
var So = (e) => {
|
|
4467
|
-
let [t, n] =
|
|
4468
|
+
let [t, n] = I.useState(0), [r, i] = I.useState([]), a = I.useCallback((t) => {
|
|
4468
4469
|
e && e.scrollTo(t);
|
|
4469
|
-
}, [e]), o =
|
|
4470
|
+
}, [e]), o = I.useCallback((e) => {
|
|
4470
4471
|
e && i(e.scrollSnapList());
|
|
4471
|
-
}, []), s =
|
|
4472
|
+
}, []), s = I.useCallback((e) => {
|
|
4472
4473
|
e && n(e.selectedScrollSnap());
|
|
4473
4474
|
}, []);
|
|
4474
|
-
return
|
|
4475
|
+
return I.useEffect(() => {
|
|
4475
4476
|
e && (o(e), s(e), e.on("reInit", o).on("reInit", s).on("select", s));
|
|
4476
4477
|
}, [
|
|
4477
4478
|
e,
|
|
@@ -4482,7 +4483,7 @@ var So = (e) => {
|
|
|
4482
4483
|
scrollSnaps: r,
|
|
4483
4484
|
onDotButtonClick: a
|
|
4484
4485
|
};
|
|
4485
|
-
}, Co =
|
|
4486
|
+
}, Co = I.forwardRef(({ orientation: e = "horizontal", opts: t, setApi: n, className: r, children: i, elementKey: a, config: o, styles: s, generatedClassName: c, ...l }, u) => {
|
|
4486
4487
|
let d = [Bn()];
|
|
4487
4488
|
o?.carousel?.autoScroll && d.push(Ln({
|
|
4488
4489
|
speed: o.carousel.speed ?? 2,
|
|
@@ -4502,18 +4503,18 @@ var So = (e) => {
|
|
|
4502
4503
|
loop: o?.carousel?.loop ?? !1,
|
|
4503
4504
|
direction: o?.carousel?.autoScroll ? void 0 : o?.carousel?.direction ?? "ltr",
|
|
4504
4505
|
axis: e === "horizontal" ? "x" : "y"
|
|
4505
|
-
}, d), [m, h] =
|
|
4506
|
+
}, d), [m, h] = I.useState(!1), [g, _] = I.useState(!1), v = I.useCallback((e) => {
|
|
4506
4507
|
e && (h(e.canScrollPrev()), _(e.canScrollNext()));
|
|
4507
|
-
}, []), y =
|
|
4508
|
+
}, []), y = I.useCallback(() => {
|
|
4508
4509
|
p?.scrollPrev();
|
|
4509
|
-
}, [p]), b =
|
|
4510
|
+
}, [p]), b = I.useCallback(() => {
|
|
4510
4511
|
p?.scrollNext();
|
|
4511
|
-
}, [p]), x =
|
|
4512
|
+
}, [p]), x = I.useCallback((e) => {
|
|
4512
4513
|
e.key === "ArrowLeft" ? (e.preventDefault(), y()) : e.key === "ArrowRight" && (e.preventDefault(), b());
|
|
4513
4514
|
}, [y, b]);
|
|
4514
|
-
return
|
|
4515
|
+
return I.useEffect(() => {
|
|
4515
4516
|
!p || !n || n(p);
|
|
4516
|
-
}, [p, n]),
|
|
4517
|
+
}, [p, n]), I.useEffect(() => {
|
|
4517
4518
|
if (p) return v(p), p.on("reInit", v), p.on("select", v), () => {
|
|
4518
4519
|
p?.off("select", v);
|
|
4519
4520
|
};
|
|
@@ -4535,7 +4536,7 @@ var So = (e) => {
|
|
|
4535
4536
|
ref: u,
|
|
4536
4537
|
"data-levo_element_key": a,
|
|
4537
4538
|
onKeyDownCapture: x,
|
|
4538
|
-
className:
|
|
4539
|
+
className: P("relative", c, r),
|
|
4539
4540
|
role: "region",
|
|
4540
4541
|
"aria-roledescription": "carousel",
|
|
4541
4542
|
...l,
|
|
@@ -4544,35 +4545,35 @@ var So = (e) => {
|
|
|
4544
4545
|
});
|
|
4545
4546
|
});
|
|
4546
4547
|
Co.displayName = "BaseCarousel";
|
|
4547
|
-
var wo =
|
|
4548
|
+
var wo = I.forwardRef(({ className: e, ...t }, n) => {
|
|
4548
4549
|
let { carouselRef: r, orientation: i } = xo();
|
|
4549
4550
|
return /* @__PURE__ */ U("div", {
|
|
4550
4551
|
ref: r,
|
|
4551
4552
|
className: "overflow-hidden",
|
|
4552
4553
|
children: /* @__PURE__ */ U("div", {
|
|
4553
4554
|
ref: n,
|
|
4554
|
-
className:
|
|
4555
|
+
className: P("flex", i === "horizontal" ? "-ml-4" : "-mt-4 flex-col", e),
|
|
4555
4556
|
...t
|
|
4556
4557
|
})
|
|
4557
4558
|
});
|
|
4558
4559
|
});
|
|
4559
4560
|
wo.displayName = "CarouselContent";
|
|
4560
|
-
var To =
|
|
4561
|
+
var To = I.forwardRef(({ className: e, ...t }, n) => {
|
|
4561
4562
|
let { orientation: r } = xo();
|
|
4562
4563
|
return /* @__PURE__ */ U("div", {
|
|
4563
4564
|
ref: n,
|
|
4564
4565
|
role: "group",
|
|
4565
4566
|
"aria-roledescription": "slide",
|
|
4566
|
-
className:
|
|
4567
|
+
className: P("carousel-item min-w-0 shrink-0 grow-0", r === "horizontal" ? "pl-4" : "pt-4", e),
|
|
4567
4568
|
...t
|
|
4568
4569
|
});
|
|
4569
4570
|
});
|
|
4570
4571
|
To.displayName = "CarouselItem";
|
|
4571
|
-
var Eo =
|
|
4572
|
+
var Eo = I.forwardRef(({ className: e, ...t }, n) => {
|
|
4572
4573
|
let { orientation: r, scrollPrev: i, canScrollPrev: a } = xo();
|
|
4573
|
-
return /* @__PURE__ */ W(
|
|
4574
|
+
return /* @__PURE__ */ W(E, {
|
|
4574
4575
|
ref: n,
|
|
4575
|
-
className:
|
|
4576
|
+
className: P("absolute h-8 w-8 rounded-full", r === "horizontal" ? "top-1/2 -left-12 -translate-y-1/2" : "-top-12 left-1/2 -translate-x-1/2 rotate-90", e),
|
|
4576
4577
|
disabled: !a,
|
|
4577
4578
|
onClick: i,
|
|
4578
4579
|
...t,
|
|
@@ -4583,11 +4584,11 @@ var Eo = F.forwardRef(({ className: e, ...t }, n) => {
|
|
|
4583
4584
|
});
|
|
4584
4585
|
});
|
|
4585
4586
|
Eo.displayName = "CarouselPrevious";
|
|
4586
|
-
var Do =
|
|
4587
|
+
var Do = I.forwardRef(({ className: e, ...t }, n) => {
|
|
4587
4588
|
let { orientation: r, scrollNext: i, canScrollNext: a } = xo();
|
|
4588
|
-
return /* @__PURE__ */ W(
|
|
4589
|
+
return /* @__PURE__ */ W(E, {
|
|
4589
4590
|
ref: n,
|
|
4590
|
-
className:
|
|
4591
|
+
className: P("absolute h-8 w-8 rounded-full", r === "horizontal" ? "top-1/2 -right-12 -translate-y-1/2" : "-bottom-12 left-1/2 -translate-x-1/2 rotate-90", e),
|
|
4591
4592
|
disabled: !a,
|
|
4592
4593
|
onClick: i,
|
|
4593
4594
|
...t,
|
|
@@ -4598,41 +4599,41 @@ var Do = F.forwardRef(({ className: e, ...t }, n) => {
|
|
|
4598
4599
|
});
|
|
4599
4600
|
});
|
|
4600
4601
|
Do.displayName = "CarouselNext";
|
|
4601
|
-
var Oo =
|
|
4602
|
+
var Oo = I.forwardRef(({ className: e, children: t, ...n }, r) => /* @__PURE__ */ U("button", {
|
|
4602
4603
|
ref: r,
|
|
4603
4604
|
type: "button",
|
|
4604
|
-
className:
|
|
4605
|
+
className: P("relative inline-flex h-7 w-7 cursor-pointer items-center justify-center rounded-full border-0 bg-transparent p-0 transition-all", "after:flex after:h-3.5 after:w-3.5 after:items-center after:justify-center after:rounded-full after:border-2 after:border-gray-200 after:content-['']", "hover:after:border-gray-400", e),
|
|
4605
4606
|
...n,
|
|
4606
4607
|
children: t
|
|
4607
4608
|
}));
|
|
4608
4609
|
Oo.displayName = "CarouselDotButton";
|
|
4609
|
-
var ko =
|
|
4610
|
+
var ko = I.forwardRef(({ className: e, ...t }, n) => {
|
|
4610
4611
|
let { api: r } = xo(), { selectedIndex: i, scrollSnaps: a, onDotButtonClick: o } = So(r);
|
|
4611
4612
|
return /* @__PURE__ */ U("div", {
|
|
4612
4613
|
ref: n,
|
|
4613
|
-
className:
|
|
4614
|
+
className: P("mt-4 flex flex-wrap items-center justify-center gap-0", e),
|
|
4614
4615
|
...t,
|
|
4615
4616
|
children: a.map((e, t) => /* @__PURE__ */ U(Oo, {
|
|
4616
4617
|
onClick: () => o(t),
|
|
4617
|
-
className:
|
|
4618
|
+
className: P(t === i && "after:border-white after:bg-white"),
|
|
4618
4619
|
"aria-label": `Go to slide ${t + 1}`
|
|
4619
4620
|
}, t))
|
|
4620
4621
|
});
|
|
4621
4622
|
});
|
|
4622
4623
|
ko.displayName = "CarouselDots";
|
|
4623
|
-
var Ao =
|
|
4624
|
+
var Ao = v(Co), jo = ke(({ children: e, className: t, elementKey: n, generatedClassName: r, content: i, config: a, styles: o, ...s }, c) => /* @__PURE__ */ W("div", {
|
|
4624
4625
|
ref: c,
|
|
4625
4626
|
"data-levo_element_key": n,
|
|
4626
4627
|
"data-levo_element_type": "Container",
|
|
4627
|
-
className:
|
|
4628
|
+
className: P(t, r),
|
|
4628
4629
|
...s,
|
|
4629
4630
|
children: [/* @__PURE__ */ U(_o, { backgroundVideo: a?.backgroundVideo }), e]
|
|
4630
4631
|
}));
|
|
4631
4632
|
jo.displayName = "BaseContainer";
|
|
4632
|
-
var Mo =
|
|
4633
|
+
var Mo = v(jo), No = L(() => import("./dist-BjFMATnH.js").then((e) => e.t).then((e) => ({ default: e.CollectionForm }))), Po = v(({ elementKey: e, generatedClassName: t, config: n, className: r, initialValues: i, theme: a, onSubmit: o, isLoading: s }) => /* @__PURE__ */ U("div", {
|
|
4633
4634
|
"data-levo_element_key": e,
|
|
4634
|
-
className:
|
|
4635
|
-
children: /* @__PURE__ */ U(
|
|
4635
|
+
className: P(r, t),
|
|
4636
|
+
children: /* @__PURE__ */ U(De, {
|
|
4636
4637
|
fallback: /* @__PURE__ */ U("div", {}),
|
|
4637
4638
|
children: /* @__PURE__ */ U(No, {
|
|
4638
4639
|
uiConfig: {
|
|
@@ -4651,46 +4652,46 @@ var Mo = _(jo), No = I(() => import("./dist-CsX9NP5P.js").then((e) => e.t).then(
|
|
|
4651
4652
|
isLoading: s
|
|
4652
4653
|
})
|
|
4653
4654
|
})
|
|
4654
|
-
})), Fo =
|
|
4655
|
-
let
|
|
4656
|
-
if (!
|
|
4657
|
-
let e =
|
|
4658
|
-
if (!e) return
|
|
4655
|
+
})), Fo = L(() => import("./dist-BjFMATnH.js").then((e) => e.t).then((e) => ({ default: e.CollectionFormRenderer }))), Io = L(() => import("./bookingCard-MDpR8SL_.js").then((e) => ({ default: e.BookingCard }))), Lo = L(() => import("./BillingStep-BNRcxjRl.js").then((e) => ({ default: e.BillingStep }))), Ro = v(({ elementKey: e, generatedClassName: t, config: r, className: i, initialValues: o, theme: s }) => {
|
|
4656
|
+
let c = F(), { workspace: l } = A(), u = z(() => {
|
|
4657
|
+
if (!r?.theme && !s) return;
|
|
4658
|
+
let e = r?.theme;
|
|
4659
|
+
if (!e) return s;
|
|
4659
4660
|
let t = {
|
|
4660
|
-
...
|
|
4661
|
+
...a({ colors: {
|
|
4661
4662
|
text: e.colors?.text,
|
|
4662
4663
|
mutedForeground: e.colors?.mutedForeground,
|
|
4663
4664
|
input: e.colors?.input,
|
|
4664
4665
|
inputForeground: e.colors?.inputForeground,
|
|
4665
4666
|
border: e.colors?.border
|
|
4666
4667
|
} }),
|
|
4667
|
-
...
|
|
4668
|
+
...n({
|
|
4668
4669
|
form: { gap: e.form?.gap },
|
|
4669
4670
|
input: { borderRadius: e.input?.borderRadius }
|
|
4670
4671
|
}),
|
|
4671
|
-
...
|
|
4672
|
+
...s?.style
|
|
4672
4673
|
};
|
|
4673
4674
|
return {
|
|
4674
|
-
...
|
|
4675
|
+
...s,
|
|
4675
4676
|
style: t
|
|
4676
4677
|
};
|
|
4677
|
-
}, [
|
|
4678
|
+
}, [r?.theme, s]), [d, f] = V({
|
|
4678
4679
|
showCard: !1,
|
|
4679
4680
|
summary: null,
|
|
4680
4681
|
isLoading: !1
|
|
4681
|
-
}), [
|
|
4682
|
+
}), [p, m] = V({
|
|
4682
4683
|
active: !1,
|
|
4683
4684
|
pendingContentId: null,
|
|
4684
4685
|
pendingCollectionKey: null,
|
|
4685
4686
|
formData: null
|
|
4686
|
-
}), [
|
|
4687
|
-
let e =
|
|
4688
|
-
if (e) for (let
|
|
4687
|
+
}), [h, g] = V(null), _ = z(() => {
|
|
4688
|
+
let e = r?.form?.schema, t = [], n = (e) => {
|
|
4689
|
+
if (e) for (let r of e) (r.allow_public_submit === !1 || r.allow_public_view === !1) && t.push(r.key), n(r.fields);
|
|
4689
4690
|
};
|
|
4690
|
-
if (e?.sections) for (let t of e.sections)
|
|
4691
|
-
return [...
|
|
4692
|
-
}, [
|
|
4693
|
-
let e =
|
|
4691
|
+
if (e?.sections) for (let t of e.sections) n(t.fields);
|
|
4692
|
+
return [...r?.form?.hidden_fields ?? [], ...t];
|
|
4693
|
+
}, [r?.form?.schema, r?.form?.hidden_fields]), v = z(() => {
|
|
4694
|
+
let e = r?.form?.success, t = r?.form?.redirect_url;
|
|
4694
4695
|
if (e) {
|
|
4695
4696
|
let n = e.action ?? (t ? {
|
|
4696
4697
|
type: "redirect",
|
|
@@ -4706,17 +4707,17 @@ var Mo = _(jo), No = I(() => import("./dist-CsX9NP5P.js").then((e) => e.t).then(
|
|
|
4706
4707
|
type: "redirect",
|
|
4707
4708
|
value: t
|
|
4708
4709
|
} };
|
|
4709
|
-
}, [
|
|
4710
|
+
}, [r?.form?.success, r?.form?.redirect_url]), y = async (e, t) => {
|
|
4710
4711
|
try {
|
|
4711
|
-
|
|
4712
|
+
f((e) => ({
|
|
4712
4713
|
...e,
|
|
4713
4714
|
isLoading: !0
|
|
4714
4715
|
}));
|
|
4715
|
-
let n = await
|
|
4716
|
+
let n = await c?.fetch?.url("/v1/payment/booking/create")?.options({ headers: { Origin: l?.id || "" } })?.post({
|
|
4716
4717
|
content_id: e,
|
|
4717
4718
|
collection_key: t
|
|
4718
4719
|
}).json();
|
|
4719
|
-
if (n?.status && n?.content?.data) return
|
|
4720
|
+
if (n?.status && n?.content?.data) return f({
|
|
4720
4721
|
showCard: !0,
|
|
4721
4722
|
summary: n.content.data,
|
|
4722
4723
|
isLoading: !1
|
|
@@ -4724,57 +4725,57 @@ var Mo = _(jo), No = I(() => import("./dist-CsX9NP5P.js").then((e) => e.t).then(
|
|
|
4724
4725
|
} catch (e) {
|
|
4725
4726
|
console.error("Failed to create booking:", e);
|
|
4726
4727
|
}
|
|
4727
|
-
return
|
|
4728
|
+
return f((e) => ({
|
|
4728
4729
|
...e,
|
|
4729
4730
|
isLoading: !1
|
|
4730
4731
|
})), !1;
|
|
4731
4732
|
};
|
|
4732
|
-
return
|
|
4733
|
+
return d.isLoading ? /* @__PURE__ */ U("div", {
|
|
4733
4734
|
"data-levo_element_key": e,
|
|
4734
|
-
className:
|
|
4735
|
+
className: P(i, t),
|
|
4735
4736
|
children: /* @__PURE__ */ U("div", {
|
|
4736
4737
|
className: "flex items-center justify-center py-8",
|
|
4737
4738
|
children: /* @__PURE__ */ U("div", { className: "size-6 animate-spin rounded-full border-2 border-gray-300 border-t-orange-500" })
|
|
4738
4739
|
})
|
|
4739
|
-
}) :
|
|
4740
|
+
}) : p.active ? /* @__PURE__ */ U("div", {
|
|
4740
4741
|
"data-levo_element_key": e,
|
|
4741
|
-
className:
|
|
4742
|
-
children: /* @__PURE__ */ U(
|
|
4742
|
+
className: P(i, t),
|
|
4743
|
+
children: /* @__PURE__ */ U(De, {
|
|
4743
4744
|
fallback: /* @__PURE__ */ U("div", {}),
|
|
4744
4745
|
children: /* @__PURE__ */ U(Lo, {
|
|
4745
4746
|
onSubmit: async (e) => {
|
|
4746
|
-
|
|
4747
|
-
let { pendingContentId: t, pendingCollectionKey: n } =
|
|
4748
|
-
|
|
4747
|
+
g(e);
|
|
4748
|
+
let { pendingContentId: t, pendingCollectionKey: n } = p;
|
|
4749
|
+
m((e) => ({
|
|
4749
4750
|
...e,
|
|
4750
4751
|
active: !1
|
|
4751
|
-
})), t && n && await
|
|
4752
|
+
})), t && n && await y(t, n);
|
|
4752
4753
|
},
|
|
4753
|
-
prefillName:
|
|
4754
|
+
prefillName: p.formData?.name
|
|
4754
4755
|
})
|
|
4755
4756
|
})
|
|
4756
|
-
}) :
|
|
4757
|
+
}) : d.showCard && d.summary ? /* @__PURE__ */ U("div", {
|
|
4757
4758
|
"data-levo_element_key": e,
|
|
4758
|
-
className:
|
|
4759
|
-
children: /* @__PURE__ */ U(
|
|
4759
|
+
className: P(i, t),
|
|
4760
|
+
children: /* @__PURE__ */ U(De, {
|
|
4760
4761
|
fallback: /* @__PURE__ */ U("div", {}),
|
|
4761
4762
|
children: /* @__PURE__ */ U(Io, {
|
|
4762
|
-
summary:
|
|
4763
|
-
billingDetails:
|
|
4764
|
-
onBillingEdit:
|
|
4763
|
+
summary: d.summary,
|
|
4764
|
+
billingDetails: h,
|
|
4765
|
+
onBillingEdit: g,
|
|
4765
4766
|
onComplete: () => {
|
|
4766
|
-
|
|
4767
|
+
f({
|
|
4767
4768
|
showCard: !1,
|
|
4768
4769
|
summary: null,
|
|
4769
4770
|
isLoading: !1
|
|
4770
|
-
}),
|
|
4771
|
+
}), g(null), r?.form?.redirect_url && (window.location.href = r.form.redirect_url);
|
|
4771
4772
|
}
|
|
4772
4773
|
})
|
|
4773
4774
|
})
|
|
4774
4775
|
}) : /* @__PURE__ */ U("div", {
|
|
4775
4776
|
"data-levo_element_key": e,
|
|
4776
|
-
className:
|
|
4777
|
-
children: /* @__PURE__ */ U(
|
|
4777
|
+
className: P(i, t),
|
|
4778
|
+
children: /* @__PURE__ */ U(De, {
|
|
4778
4779
|
fallback: /* @__PURE__ */ U("div", {}),
|
|
4779
4780
|
children: /* @__PURE__ */ U(Fo, {
|
|
4780
4781
|
uiConfig: {
|
|
@@ -4783,26 +4784,26 @@ var Mo = _(jo), No = I(() => import("./dist-CsX9NP5P.js").then((e) => e.t).then(
|
|
|
4783
4784
|
},
|
|
4784
4785
|
submitButtonConfig: {
|
|
4785
4786
|
show: !0,
|
|
4786
|
-
text:
|
|
4787
|
+
text: r?.form?.submit_button_label ?? "Submit"
|
|
4787
4788
|
},
|
|
4788
|
-
fetchedSchema:
|
|
4789
|
-
hiddenFields:
|
|
4790
|
-
externalInitialValues:
|
|
4791
|
-
theme:
|
|
4792
|
-
formVariant:
|
|
4789
|
+
fetchedSchema: r?.form?.schema,
|
|
4790
|
+
hiddenFields: _,
|
|
4791
|
+
externalInitialValues: o,
|
|
4792
|
+
theme: u,
|
|
4793
|
+
formVariant: r?.form?.form_variant ?? "default",
|
|
4793
4794
|
onSuccess: async ({ response: e, meta: t }) => {
|
|
4794
|
-
let
|
|
4795
|
-
if (
|
|
4796
|
-
|
|
4795
|
+
let n = e?._id, i = r?.form?.schema?.key;
|
|
4796
|
+
if (n && i && t?.booking_config?.enabled) {
|
|
4797
|
+
m({
|
|
4797
4798
|
active: !0,
|
|
4798
|
-
pendingContentId:
|
|
4799
|
+
pendingContentId: n,
|
|
4799
4800
|
pendingCollectionKey: i,
|
|
4800
4801
|
formData: e
|
|
4801
4802
|
});
|
|
4802
4803
|
return;
|
|
4803
4804
|
}
|
|
4804
4805
|
},
|
|
4805
|
-
successConfig:
|
|
4806
|
+
successConfig: v
|
|
4806
4807
|
})
|
|
4807
4808
|
})
|
|
4808
4809
|
});
|
|
@@ -4812,14 +4813,14 @@ var Mo = _(jo), No = I(() => import("./dist-CsX9NP5P.js").then((e) => e.t).then(
|
|
|
4812
4813
|
function Z({ className: e, ...t }) {
|
|
4813
4814
|
return /* @__PURE__ */ U("div", {
|
|
4814
4815
|
"data-slot": "skeleton",
|
|
4815
|
-
className:
|
|
4816
|
+
className: P("animate-pulse rounded-md bg-gray-200", e),
|
|
4816
4817
|
...t
|
|
4817
4818
|
});
|
|
4818
4819
|
}
|
|
4819
4820
|
//#endregion
|
|
4820
4821
|
//#region src/elements/forum/categoryFilter/CategoryFilter.tsx
|
|
4821
4822
|
var zo = ({ forumKey: e, selectedCategories: t, onCategoryToggle: n, className: r }) => {
|
|
4822
|
-
let { fetch: i, logger: a } =
|
|
4823
|
+
let { fetch: i, logger: a } = F(), [o, s] = V([]), [c, l] = V(!1), [u, d] = V(!1), f = B(!1), p = Me(async () => {
|
|
4823
4824
|
if (!(!e || f.current)) {
|
|
4824
4825
|
l(!0), d(!1);
|
|
4825
4826
|
try {
|
|
@@ -4848,15 +4849,15 @@ var zo = ({ forumKey: e, selectedCategories: t, onCategoryToggle: n, className:
|
|
|
4848
4849
|
,
|
|
4849
4850
|
,
|
|
4850
4851
|
,
|
|
4851
|
-
]].map((e, t) => /* @__PURE__ */ U(Z, { className:
|
|
4852
|
-
className:
|
|
4852
|
+
]].map((e, t) => /* @__PURE__ */ U(Z, { className: P("h-8 w-20 rounded-full", r) }, `category-skeleton-${t}`)) }) : u ? /* @__PURE__ */ U("p", {
|
|
4853
|
+
className: P("text-red-500 text-sm", r),
|
|
4853
4854
|
children: "Failed to load categories"
|
|
4854
4855
|
}) : o.length === 0 ? null : /* @__PURE__ */ U(H, { children: o.map((e) => /* @__PURE__ */ U("button", {
|
|
4855
4856
|
onClick: () => n(e._id),
|
|
4856
|
-
className:
|
|
4857
|
+
className: P("rounded-sm border border-[#E5E5E5] px-3 py-1.5 font-medium text-text-1 text-xs uppercase transition-colors", t.includes(e._id) ? "border-brand/25 bg-brand/5" : "bg-white"),
|
|
4857
4858
|
children: e.name
|
|
4858
4859
|
}, e._id)) });
|
|
4859
|
-
}, Bo =
|
|
4860
|
+
}, Bo = Oe(void 0), Vo = ({ children: e, forum: t, isMember: n, isLoadingMembership: r, isInviteOnly: i, canInteractWithPosts: a, canInteractWithComments: o, joinRequest: s = null, isJoinRequestPending: c = !1, allowJoinRequests: l = !1, submitJoinRequest: u = async () => !1, refreshMembershipStatus: d = async () => {} }) => /* @__PURE__ */ U(Bo.Provider, {
|
|
4860
4861
|
value: {
|
|
4861
4862
|
forum: t,
|
|
4862
4863
|
isMember: n,
|
|
@@ -4886,10 +4887,10 @@ var zo = ({ forumKey: e, selectedCategories: t, onCategoryToggle: n, className:
|
|
|
4886
4887
|
submitJoinRequest: async () => !1,
|
|
4887
4888
|
refreshMembershipStatus: async () => {}
|
|
4888
4889
|
} : e;
|
|
4889
|
-
}, Uo = Fn.Provider, Wo = Fn.Root, Go = Fn.Trigger, Ko = Fn.Portal, qo =
|
|
4890
|
+
}, Uo = Fn.Provider, Wo = Fn.Root, Go = Fn.Trigger, Ko = Fn.Portal, qo = Te.forwardRef(({ className: e, sideOffset: t = 4, ...n }, r) => /* @__PURE__ */ U(Fn.Content, {
|
|
4890
4891
|
ref: r,
|
|
4891
4892
|
sideOffset: t,
|
|
4892
|
-
className:
|
|
4893
|
+
className: P("fade-in-0 zoom-in-95 data-[state=closed]:fade-out-0 data-[state=closed]:zoom-out-95 data-[side=bottom]:slide-in-from-top-2 data-[side=left]:slide-in-from-right-2 data-[side=right]:slide-in-from-left-2 data-[side=top]:slide-in-from-bottom-2 z-50 animate-in overflow-hidden rounded-md border bg-popover px-3 py-1.5 text-popover-foreground text-xs shadow-md data-[state=closed]:animate-out", e),
|
|
4893
4894
|
...n
|
|
4894
4895
|
}));
|
|
4895
4896
|
qo.displayName = Fn.Content.displayName;
|
|
@@ -4905,13 +4906,13 @@ var Jo = ({ children: e, label: t, labelClassName: n, asChild: r = !0, contentPr
|
|
|
4905
4906
|
let u = () => {
|
|
4906
4907
|
o || (i?.(), t(!1));
|
|
4907
4908
|
};
|
|
4908
|
-
return /* @__PURE__ */ U(
|
|
4909
|
+
return /* @__PURE__ */ U(oe, {
|
|
4909
4910
|
open: e,
|
|
4910
4911
|
onOpenChange: (e) => {
|
|
4911
4912
|
!o && !e && u();
|
|
4912
4913
|
},
|
|
4913
|
-
children: /* @__PURE__ */ W(
|
|
4914
|
-
className:
|
|
4914
|
+
children: /* @__PURE__ */ W(ne, {
|
|
4915
|
+
className: P("max-w-md gap-0 space-y-2 overflow-hidden p-0"),
|
|
4915
4916
|
showCloseButton: !1,
|
|
4916
4917
|
children: [/* @__PURE__ */ W("div", {
|
|
4917
4918
|
className: "space-y-2 px-0 py-0",
|
|
@@ -4924,21 +4925,21 @@ var Jo = ({ children: e, label: t, labelClassName: n, asChild: r = !0, contentPr
|
|
|
4924
4925
|
})]
|
|
4925
4926
|
}), /* @__PURE__ */ W("div", {
|
|
4926
4927
|
className: "flex items-center justify-end gap-3 border-[#D1D6E1] border-t pt-2",
|
|
4927
|
-
children: [/* @__PURE__ */ U(
|
|
4928
|
+
children: [/* @__PURE__ */ U(x, {
|
|
4928
4929
|
elementKey: "alert-dialog-cancel",
|
|
4929
4930
|
onClick: u,
|
|
4930
4931
|
disabled: o,
|
|
4931
4932
|
className: "",
|
|
4932
4933
|
config: { selectedVariants: { Button_Variants: "Outline" } },
|
|
4933
4934
|
children: s
|
|
4934
|
-
}), /* @__PURE__ */ U(
|
|
4935
|
+
}), /* @__PURE__ */ U(x, {
|
|
4935
4936
|
elementKey: "alert-dialog-confirm",
|
|
4936
4937
|
onClick: () => {
|
|
4937
4938
|
o || a();
|
|
4938
4939
|
},
|
|
4939
4940
|
disabled: o,
|
|
4940
4941
|
isLoading: o,
|
|
4941
|
-
className:
|
|
4942
|
+
className: P("", l),
|
|
4942
4943
|
children: c
|
|
4943
4944
|
})]
|
|
4944
4945
|
})]
|
|
@@ -4954,15 +4955,15 @@ var Jo = ({ children: e, label: t, labelClassName: n, asChild: r = !0, contentPr
|
|
|
4954
4955
|
slideFromRight: "_slideFromRight_ob3yj_1",
|
|
4955
4956
|
slideFromLeft: "_slideFromLeft_ob3yj_1",
|
|
4956
4957
|
slideFromBottom: "_slideFromBottom_ob3yj_1"
|
|
4957
|
-
}, Zo = Mn.Root, Qo =
|
|
4958
|
+
}, Zo = Mn.Root, Qo = Te.forwardRef(({ className: e, elementKey: t, generatedClassName: n, content: r, config: i, styles: a, ...o }, s) => /* @__PURE__ */ U(Mn.Trigger, {
|
|
4958
4959
|
ref: s,
|
|
4959
4960
|
"data-levo_element_key": t,
|
|
4960
4961
|
"data-levo_element_type": "PopoverTrigger",
|
|
4961
|
-
className:
|
|
4962
|
+
className: P("PopoverTrigger", e, n),
|
|
4962
4963
|
...o
|
|
4963
4964
|
}));
|
|
4964
4965
|
Qo.displayName = "BasePopoverTrigger";
|
|
4965
|
-
var $o =
|
|
4966
|
+
var $o = Te.forwardRef(({ className: e, elementKey: t, generatedClassName: n, content: r, config: i, styles: a, inPortal: o = !0, portalContainer: s, align: c = "center", sideOffset: l = 4, ...u }, d) => /* @__PURE__ */ U(H, { children: o ? /* @__PURE__ */ U(Mn.Portal, {
|
|
4966
4967
|
container: s,
|
|
4967
4968
|
children: /* @__PURE__ */ U(Mn.Content, {
|
|
4968
4969
|
ref: d,
|
|
@@ -4970,7 +4971,7 @@ var $o = Ee.forwardRef(({ className: e, elementKey: t, generatedClassName: n, co
|
|
|
4970
4971
|
sideOffset: l,
|
|
4971
4972
|
"data-levo_element_key": t,
|
|
4972
4973
|
"data-levo_element_type": "PopoverContent",
|
|
4973
|
-
className:
|
|
4974
|
+
className: P(Xo.popoverContent, e, n),
|
|
4974
4975
|
...u
|
|
4975
4976
|
})
|
|
4976
4977
|
}) : /* @__PURE__ */ U(Mn.Content, {
|
|
@@ -4979,42 +4980,42 @@ var $o = Ee.forwardRef(({ className: e, elementKey: t, generatedClassName: n, co
|
|
|
4979
4980
|
sideOffset: l,
|
|
4980
4981
|
"data-levo_element_key": t,
|
|
4981
4982
|
"data-levo_element_type": "PopoverContent",
|
|
4982
|
-
className:
|
|
4983
|
+
className: P(Xo.popoverContent, e, n),
|
|
4983
4984
|
...u
|
|
4984
4985
|
}) }));
|
|
4985
4986
|
$o.displayName = "BasePopoverContent";
|
|
4986
|
-
var es =
|
|
4987
|
-
let [d, f] = V(!1), { account: p, workspace: m } =
|
|
4987
|
+
var es = v(Qo), ts = v($o), ns = ({ children: e, triggerContainerStyles: t, useCustomOpenState: n = !1, isOpen: r, handleCreateForumPostModalOpen: i, isCreateForumPostModalReady: a = !1, forumKey: o, onSuccess: s, onClose: c, mode: l = "create", initialValues: u }) => {
|
|
4988
|
+
let [d, f] = V(!1), { account: p, workspace: m } = A(), { fetch: h, logger: g } = F(), [_] = V("myself"), [v, y] = V(""), [b, S] = V(""), [C, w] = V(!1), [T, E] = V(!1), [D, O] = V(""), [k, j] = V(""), [M, N] = V(!1), [re, ie] = V([]), [se, ce] = V(!1), le = B(!1), [ue, de] = V(l === "create");
|
|
4988
4989
|
R(() => {
|
|
4989
4990
|
if (l === "edit" && u) {
|
|
4990
4991
|
y(u.title || ""), S(u.content || ""), u.kind === "link" && (E(!0), O(u.url || ""));
|
|
4991
4992
|
let e = u.categories?.[0], t = typeof e == "string" ? e : e?._id;
|
|
4992
|
-
t && j(t),
|
|
4993
|
+
t && j(t), de(!0);
|
|
4993
4994
|
}
|
|
4994
4995
|
}, [l, u]);
|
|
4995
|
-
let
|
|
4996
|
-
if (!(!o ||
|
|
4997
|
-
|
|
4996
|
+
let fe = Me(async () => {
|
|
4997
|
+
if (!(!o || le.current || se)) {
|
|
4998
|
+
ce(!0);
|
|
4998
4999
|
try {
|
|
4999
5000
|
let e = await h.url(`/v1/community/${o}/category/list`).post({ limit: -1 }).json();
|
|
5000
|
-
e?.content?.data && (
|
|
5001
|
+
e?.content?.data && (ie(e.content.data), le.current = !0);
|
|
5001
5002
|
} catch (e) {
|
|
5002
5003
|
let t = G(e);
|
|
5003
5004
|
g?.error("Failed to fetch categories", { exception: t });
|
|
5004
5005
|
} finally {
|
|
5005
|
-
|
|
5006
|
+
ce(!1);
|
|
5006
5007
|
}
|
|
5007
5008
|
}
|
|
5008
5009
|
}, [
|
|
5009
5010
|
o,
|
|
5010
5011
|
h,
|
|
5011
5012
|
g,
|
|
5012
|
-
|
|
5013
|
+
se
|
|
5013
5014
|
]);
|
|
5014
5015
|
R(() => {
|
|
5015
|
-
|
|
5016
|
-
}, [
|
|
5017
|
-
let
|
|
5016
|
+
fe();
|
|
5017
|
+
}, [fe]);
|
|
5018
|
+
let pe = z(() => {
|
|
5018
5019
|
if (_ === "workspace" && m?.name) return m.name;
|
|
5019
5020
|
if (p?.username) return p.username;
|
|
5020
5021
|
let e = [p?.first_name, p?.last_name]?.filter(Boolean);
|
|
@@ -5024,24 +5025,24 @@ var es = _(Qo), ts = _($o), ns = ({ children: e, triggerContainerStyles: t, useC
|
|
|
5024
5025
|
p,
|
|
5025
5026
|
m
|
|
5026
5027
|
]);
|
|
5027
|
-
return /* @__PURE__ */ W(
|
|
5028
|
+
return /* @__PURE__ */ W(oe, {
|
|
5028
5029
|
open: n ? r : d,
|
|
5029
5030
|
onOpenChange: n ? i : (e) => {
|
|
5030
5031
|
f(!!e);
|
|
5031
5032
|
},
|
|
5032
|
-
children: [e && /* @__PURE__ */ U(
|
|
5033
|
+
children: [e && /* @__PURE__ */ U(ae, {
|
|
5033
5034
|
asChild: !0,
|
|
5034
5035
|
children: /* @__PURE__ */ U("div", {
|
|
5035
|
-
className:
|
|
5036
|
+
className: P("", t),
|
|
5036
5037
|
children: e
|
|
5037
5038
|
})
|
|
5038
|
-
}), /* @__PURE__ */ W(
|
|
5039
|
+
}), /* @__PURE__ */ W(ne, {
|
|
5039
5040
|
"data-prevent-post-navigation": !0,
|
|
5040
5041
|
className: "!max-w-[638px] flex flex-col gap-y-6",
|
|
5041
5042
|
autoFocus: !1,
|
|
5042
5043
|
showCloseButton: !1,
|
|
5043
5044
|
children: [
|
|
5044
|
-
/* @__PURE__ */ W(
|
|
5045
|
+
/* @__PURE__ */ W(ee, {
|
|
5045
5046
|
className: "!flex-row items-center justify-between",
|
|
5046
5047
|
children: [/* @__PURE__ */ W("div", {
|
|
5047
5048
|
className: "flex items-center gap-3",
|
|
@@ -5066,10 +5067,10 @@ var es = _(Qo), ts = _($o), ns = ({ children: e, triggerContainerStyles: t, useC
|
|
|
5066
5067
|
}), /* @__PURE__ */ W("div", {
|
|
5067
5068
|
className: "flex items-center gap-2",
|
|
5068
5069
|
children: [
|
|
5069
|
-
l === "create" &&
|
|
5070
|
-
l === "create" && !
|
|
5071
|
-
open:
|
|
5072
|
-
onOpenChange:
|
|
5070
|
+
l === "create" && se && /* @__PURE__ */ U("div", { className: "h-8 w-24 animate-pulse rounded-md bg-gray-200" }),
|
|
5071
|
+
l === "create" && !se && re?.length > 0 && /* @__PURE__ */ W(Zo, {
|
|
5072
|
+
open: M,
|
|
5073
|
+
onOpenChange: N,
|
|
5073
5074
|
children: [/* @__PURE__ */ U(es, {
|
|
5074
5075
|
elementKey: "category-trigger",
|
|
5075
5076
|
asChild: !0,
|
|
@@ -5079,37 +5080,37 @@ var es = _(Qo), ts = _($o), ns = ({ children: e, triggerContainerStyles: t, useC
|
|
|
5079
5080
|
className: "flex h-8 cursor-pointer items-center gap-1.5 rounded-md border border-[#D1D6E1] bg-white px-3 py-1.5 font-medium text-sm transition-colors hover:bg-gray-50 disabled:opacity-50",
|
|
5080
5081
|
children: [/* @__PURE__ */ U("span", {
|
|
5081
5082
|
className: "text-text-1",
|
|
5082
|
-
children:
|
|
5083
|
+
children: re.find((e) => e._id === k)?.name || "Category"
|
|
5083
5084
|
}), /* @__PURE__ */ U(nn, { className: "size-4 text-text-2" })]
|
|
5084
5085
|
})
|
|
5085
5086
|
}), /* @__PURE__ */ U(ts, {
|
|
5086
5087
|
elementKey: "category-content",
|
|
5087
5088
|
align: "end",
|
|
5088
5089
|
className: "!w-[unset] !p-1 min-w-36 rounded-lg border border-gray-200 bg-white shadow-lg",
|
|
5089
|
-
children:
|
|
5090
|
+
children: re.map((e) => /* @__PURE__ */ W("button", {
|
|
5090
5091
|
type: "button",
|
|
5091
5092
|
onClick: () => {
|
|
5092
|
-
j(e._id),
|
|
5093
|
+
j(e._id), N(!1);
|
|
5093
5094
|
},
|
|
5094
|
-
className:
|
|
5095
|
-
children: [/* @__PURE__ */ U("span", { children: e.name }),
|
|
5095
|
+
className: P("flex w-full cursor-pointer items-center justify-between rounded-md px-3 py-2 text-left text-sm transition-colors hover:bg-gray-100", k === e._id ? "font-medium text-text-1" : "text-text-2"),
|
|
5096
|
+
children: [/* @__PURE__ */ U("span", { children: e.name }), k === e._id && /* @__PURE__ */ U($t, { className: "size-4 text-brand" })]
|
|
5096
5097
|
}, e._id))
|
|
5097
5098
|
})]
|
|
5098
5099
|
}),
|
|
5099
|
-
/* @__PURE__ */ U(
|
|
5100
|
+
/* @__PURE__ */ U(x, {
|
|
5100
5101
|
elementKey: "add",
|
|
5101
5102
|
onClick: async () => {
|
|
5102
5103
|
if (v.trim()) {
|
|
5103
5104
|
w(!0);
|
|
5104
5105
|
try {
|
|
5105
5106
|
let e;
|
|
5106
|
-
if (l === "edit" && u?._id) e = await h.url(`/v1/community/${o}/post/${u._id}/update-single`).put({ content:
|
|
5107
|
+
if (l === "edit" && u?._id) e = await h.url(`/v1/community/${o}/post/${u._id}/update-single`).put({ content: b.trim() || void 0 }).json();
|
|
5107
5108
|
else {
|
|
5108
5109
|
let t = {
|
|
5109
5110
|
title: v.trim(),
|
|
5110
|
-
content:
|
|
5111
|
+
content: b.trim() || void 0
|
|
5111
5112
|
};
|
|
5112
|
-
T && D.trim() && (t.kind = "link", t.url = D.trim()),
|
|
5113
|
+
T && D.trim() && (t.kind = "link", t.url = D.trim()), k && (t.categories = [k]), e = await h.url(`/v1/community/${o}/post/create-single`).post(t).json();
|
|
5113
5114
|
}
|
|
5114
5115
|
e?.content?.data && (y(""), S(""), E(!1), O(""), j(""), s?.(e.content.data), c?.());
|
|
5115
5116
|
} catch (e) {
|
|
@@ -5120,7 +5121,7 @@ var es = _(Qo), ts = _($o), ns = ({ children: e, triggerContainerStyles: t, useC
|
|
|
5120
5121
|
}
|
|
5121
5122
|
}
|
|
5122
5123
|
},
|
|
5123
|
-
disabled: !
|
|
5124
|
+
disabled: !ue || C || !v.trim(),
|
|
5124
5125
|
className: "!h-8 !border-none flex w-fit flex-nowrap whitespace-nowrap [&_span]:flex [&_span]:items-center [&_span]:gap-2",
|
|
5125
5126
|
isLoading: C,
|
|
5126
5127
|
loadingText: l === "edit" ? "Updating..." : "Creating...",
|
|
@@ -5132,7 +5133,7 @@ var es = _(Qo), ts = _($o), ns = ({ children: e, triggerContainerStyles: t, useC
|
|
|
5132
5133
|
]
|
|
5133
5134
|
})]
|
|
5134
5135
|
}),
|
|
5135
|
-
|
|
5136
|
+
ue ? /* @__PURE__ */ W("div", {
|
|
5136
5137
|
className: "space-y-4",
|
|
5137
5138
|
children: [
|
|
5138
5139
|
/* @__PURE__ */ U(Ds, {
|
|
@@ -5145,12 +5146,12 @@ var es = _(Qo), ts = _($o), ns = ({ children: e, triggerContainerStyles: t, useC
|
|
|
5145
5146
|
value: v,
|
|
5146
5147
|
onChange: (e) => y(e.target.value),
|
|
5147
5148
|
disabled: C || l === "edit",
|
|
5148
|
-
inputStyles:
|
|
5149
|
+
inputStyles: P("h-12 border-[#D1D6E1] bg-white font-medium text-base placeholder:text-[#717C91] focus-visible:ring-1 focus-visible:ring-[#D1D6E1]", l === "edit" && "cursor-not-allowed bg-gray-50")
|
|
5149
5150
|
}),
|
|
5150
5151
|
/* @__PURE__ */ U(nl, {
|
|
5151
5152
|
name: "content",
|
|
5152
5153
|
placeholder: "Body text (optional)",
|
|
5153
|
-
value:
|
|
5154
|
+
value: b,
|
|
5154
5155
|
onChange: (e) => S(e.target.value),
|
|
5155
5156
|
disabled: C,
|
|
5156
5157
|
textAreaStyles: "border-[#D1D6E1] text-sm placeholder:text-[#717C91] bg-white focus-visible:ring-[#D1D6E1] focus-visible:ring-1 resize-none",
|
|
@@ -5172,7 +5173,7 @@ var es = _(Qo), ts = _($o), ns = ({ children: e, triggerContainerStyles: t, useC
|
|
|
5172
5173
|
className: "space-y-4",
|
|
5173
5174
|
children: [/* @__PURE__ */ U("div", { className: "h-12 animate-pulse rounded-md bg-gray-200" }), /* @__PURE__ */ U("div", { className: "h-64 animate-pulse rounded-md bg-gray-200" })]
|
|
5174
5175
|
}),
|
|
5175
|
-
/* @__PURE__ */ W(
|
|
5176
|
+
/* @__PURE__ */ W(te, {
|
|
5176
5177
|
className: "!justify-between flex",
|
|
5177
5178
|
children: [/* @__PURE__ */ U("div", {
|
|
5178
5179
|
className: "flex items-center gap-2",
|
|
@@ -5182,12 +5183,12 @@ var es = _(Qo), ts = _($o), ns = ({ children: e, triggerContainerStyles: t, useC
|
|
|
5182
5183
|
E(!T), T && O("");
|
|
5183
5184
|
},
|
|
5184
5185
|
disabled: C || l === "edit",
|
|
5185
|
-
className:
|
|
5186
|
+
className: P("flex h-8 w-fit cursor-pointer items-center gap-2 rounded-lg border px-2 font-medium text-sm transition-colors", "disabled:cursor-not-allowed disabled:opacity-80", T ? "border-brand bg-brand text-white hover:bg-brand/90" : "border-[#D1D6E1] bg-white text-text-1 hover:bg-gray-50"),
|
|
5186
5187
|
children: /* @__PURE__ */ U(hn, { size: 16 })
|
|
5187
5188
|
})
|
|
5188
5189
|
}), /* @__PURE__ */ W("div", {
|
|
5189
5190
|
className: "flex items-center gap-2 text-sm text-text-2/80",
|
|
5190
|
-
children: [/* @__PURE__ */ W("span", { children: ["Your post will appear as @",
|
|
5191
|
+
children: [/* @__PURE__ */ W("span", { children: ["Your post will appear as @", pe] }), /* @__PURE__ */ U(mn, { className: "size-4 text-text-1" })]
|
|
5191
5192
|
})]
|
|
5192
5193
|
})
|
|
5193
5194
|
]
|
|
@@ -5219,7 +5220,7 @@ var rs = (e) => {
|
|
|
5219
5220
|
return "";
|
|
5220
5221
|
}
|
|
5221
5222
|
}, is = ({ post: e, isRenderedSolo: t, forumKey: n, postListingPageURL: r, onEditClick: i, onPostUpdated: a }) => {
|
|
5222
|
-
let { account: o } =
|
|
5223
|
+
let { account: o } = A(), { fetch: s, logger: c } = F(), [l, u] = V(!1), [d, f] = V(!1), [p, m] = V(!1), [h, g] = V(!1), _ = z(() => !!(e?.organization && e?.organization?.badge_granted_at), [e]), v = z(() => {
|
|
5223
5224
|
let t = e?.organization?.name?.split(" ") || [];
|
|
5224
5225
|
return t?.length > 1 ? t?.map((e) => e?.charAt(0)?.toUpperCase())?.join("") : t?.at(0)?.slice(0, 2)?.toUpperCase();
|
|
5225
5226
|
}, [e?.organization]), y = z(() => {
|
|
@@ -5381,11 +5382,11 @@ var rs = (e) => {
|
|
|
5381
5382
|
className: "max-w-none text-sm text-text-2 leading-relaxed",
|
|
5382
5383
|
children: /* @__PURE__ */ U("div", { dangerouslySetInnerHTML: { __html: e.content || "" } })
|
|
5383
5384
|
}), cs = ({ className: e, children: t, ...n }) => /* @__PURE__ */ U("div", {
|
|
5384
|
-
className:
|
|
5385
|
+
className: P("flex items-center gap-1 rounded-lg border border-[#D1D6E1] bg-[#F0F4FA] px-2 py-1 font-semibold text-sm", e),
|
|
5385
5386
|
...n,
|
|
5386
5387
|
children: t
|
|
5387
5388
|
}), ls = ({ post: e, forumKey: t }) => {
|
|
5388
|
-
let { fetch: n, logger: r } =
|
|
5389
|
+
let { fetch: n, logger: r } = F(), { isLoggedIn: i } = A(), { openModal: a } = M(), { canInteractWithPosts: o } = Ho(), [s, c] = V(!1), [l, u] = V(!!e?.upvoted_at), [d, f] = V(!!e?.downvoted_at), [p, m] = V((e.upvote_count ?? 0) - (e.downvote_count ?? 0)), h = !i || o;
|
|
5389
5390
|
return R(() => {
|
|
5390
5391
|
m((e.upvote_count ?? 0) - (e.downvote_count ?? 0));
|
|
5391
5392
|
}, [e?.upvote_count, e?.downvote_count]), R(() => {
|
|
@@ -5397,7 +5398,7 @@ var rs = (e) => {
|
|
|
5397
5398
|
children: [
|
|
5398
5399
|
/* @__PURE__ */ U("button", {
|
|
5399
5400
|
type: "button",
|
|
5400
|
-
className:
|
|
5401
|
+
className: P("flex cursor-pointer items-center rounded-sm px-0.5 transition-all duration-200", !h && "cursor-not-allowed opacity-50"),
|
|
5401
5402
|
onClick: async (o) => {
|
|
5402
5403
|
if (o.stopPropagation(), o.preventDefault(), !i) {
|
|
5403
5404
|
a("login", {});
|
|
@@ -5426,12 +5427,12 @@ var rs = (e) => {
|
|
|
5426
5427
|
})
|
|
5427
5428
|
}),
|
|
5428
5429
|
/* @__PURE__ */ U("span", {
|
|
5429
|
-
className:
|
|
5430
|
+
className: P("font-semibold text-sm"),
|
|
5430
5431
|
children: p
|
|
5431
5432
|
}),
|
|
5432
5433
|
/* @__PURE__ */ U("button", {
|
|
5433
5434
|
type: "button",
|
|
5434
|
-
className:
|
|
5435
|
+
className: P("flex cursor-pointer items-center rounded-sm px-0.5 transition-all duration-200", !h && "cursor-not-allowed opacity-50"),
|
|
5435
5436
|
onClick: async (o) => {
|
|
5436
5437
|
if (o.stopPropagation(), o.preventDefault(), !i) {
|
|
5437
5438
|
a("login", {});
|
|
@@ -5462,7 +5463,7 @@ var rs = (e) => {
|
|
|
5462
5463
|
]
|
|
5463
5464
|
});
|
|
5464
5465
|
}, us = ({ post: e, postDetailPageURLPattern: t, isRenderedSolo: n = !1, actionsLoadingState: r, forumKey: i }) => /* @__PURE__ */ U("div", {
|
|
5465
|
-
className:
|
|
5466
|
+
className: P("mt-0"),
|
|
5466
5467
|
children: /* @__PURE__ */ U("div", {
|
|
5467
5468
|
className: "flex items-center justify-between",
|
|
5468
5469
|
children: /* @__PURE__ */ W("div", {
|
|
@@ -5473,7 +5474,7 @@ var rs = (e) => {
|
|
|
5473
5474
|
forumKey: i
|
|
5474
5475
|
}),
|
|
5475
5476
|
r?.comments ? /* @__PURE__ */ U(Z, { className: "h-7.5 w-14 rounded-lg" }) : /* @__PURE__ */ W(cs, {
|
|
5476
|
-
className:
|
|
5477
|
+
className: P("cursor-pointer gap-1.5", n && "cursor-default"),
|
|
5477
5478
|
onClick: (r) => {
|
|
5478
5479
|
r.stopPropagation(), r.preventDefault();
|
|
5479
5480
|
let i = t?.replace(/\{[^}]+\}/g, e?.slug);
|
|
@@ -5599,7 +5600,7 @@ var rs = (e) => {
|
|
|
5599
5600
|
})
|
|
5600
5601
|
});
|
|
5601
5602
|
}, ps = ({ option: e, post: t, setPost: n }) => {
|
|
5602
|
-
let { fetch: r, logger: i } =
|
|
5603
|
+
let { fetch: r, logger: i } = F(), a = z(() => {
|
|
5603
5604
|
let e = K(t?.expires_at), n = K();
|
|
5604
5605
|
return e?.isValid() ? !!n?.isAfter(e) : !1;
|
|
5605
5606
|
}, [t?.expires_at]), o = t?.user_voted_option === e?._id, s = !!t?.user_voted_option, c = t?.vote_count, l = z(() => Number.isFinite(c) && Number.isFinite(e?.count) && typeof c == "number" && c > 0 ? (e.count / c * 100)?.toFixed(0) : null, [t, e]), u = async (t, o) => {
|
|
@@ -5634,7 +5635,7 @@ var rs = (e) => {
|
|
|
5634
5635
|
type: "button",
|
|
5635
5636
|
onClick: () => u(t, e._id),
|
|
5636
5637
|
disabled: a,
|
|
5637
|
-
className:
|
|
5638
|
+
className: P("w-full cursor-pointer rounded-lg border-2 p-4 text-left transition-all duration-200", o ? "border-blue-500 bg-blue-50 shadow-sm" : s || a ? "border-gray-200 bg-gray-50" : "border-gray-200 hover:border-blue-300 hover:bg-blue-50/50", a && "cursor-not-allowed"),
|
|
5638
5639
|
children: [
|
|
5639
5640
|
/* @__PURE__ */ W("div", {
|
|
5640
5641
|
className: "mb-2 flex items-center justify-between",
|
|
@@ -5754,7 +5755,7 @@ var rs = (e) => {
|
|
|
5754
5755
|
side: "top",
|
|
5755
5756
|
labelClassName: "bg-[#171717] text-white",
|
|
5756
5757
|
children: /* @__PURE__ */ W("div", {
|
|
5757
|
-
className:
|
|
5758
|
+
className: P("flex cursor-pointer items-center gap-1.5 rounded-md border px-2 py-1 font-medium text-xs", t.className),
|
|
5758
5759
|
children: [t.icon, /* @__PURE__ */ U("span", { children: t.label })]
|
|
5759
5760
|
})
|
|
5760
5761
|
}) }) : null;
|
|
@@ -5793,7 +5794,7 @@ var rs = (e) => {
|
|
|
5793
5794
|
side: "top",
|
|
5794
5795
|
labelClassName: "bg-[#171717] text-white",
|
|
5795
5796
|
children: /* @__PURE__ */ W("div", {
|
|
5796
|
-
className:
|
|
5797
|
+
className: P("flex h-[30px] cursor-pointer items-center gap-1.5 rounded-md border px-2 py-1 font-medium text-xs", t.className),
|
|
5797
5798
|
children: [t.icon, /* @__PURE__ */ U("span", { children: t.label })]
|
|
5798
5799
|
})
|
|
5799
5800
|
}) }) : null;
|
|
@@ -5804,20 +5805,20 @@ function Ss({ className: e, type: t, ...n }) {
|
|
|
5804
5805
|
return /* @__PURE__ */ U("input", {
|
|
5805
5806
|
type: t,
|
|
5806
5807
|
"data-slot": "input",
|
|
5807
|
-
className:
|
|
5808
|
+
className: P("flex h-10 w-full min-w-0 rounded-md border border-border bg-transparent px-3 py-1 text-text-1 text-base shadow-xs outline-none transition-[color,box-shadow] selection:bg-primary selection:text-primary-foreground file:inline-flex file:h-7 file:border-0 file:bg-transparent file:font-medium file:text-foreground file:text-sm placeholder:text-text-2 disabled:pointer-events-none disabled:cursor-not-allowed disabled:opacity-50 md:text-sm dark:bg-input/30", "focus-visible:border-border focus-visible:ring-[3px] focus-visible:ring-brand/80", "aria-invalid:border-destructive aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40", e),
|
|
5808
5809
|
...n
|
|
5809
5810
|
});
|
|
5810
5811
|
}
|
|
5811
5812
|
//#endregion
|
|
5812
5813
|
//#region src/components/ui/form/utils/FieldError.tsx
|
|
5813
5814
|
var Cs = ({ children: e }) => /* @__PURE__ */ U("p", {
|
|
5814
|
-
className:
|
|
5815
|
+
className: P("mt-2 font-medium text-red-400 text-xs"),
|
|
5815
5816
|
children: e
|
|
5816
5817
|
}), ws = ({ children: e, styles: t = "" }) => /* @__PURE__ */ U("p", {
|
|
5817
|
-
className:
|
|
5818
|
+
className: P("font-medium text-muted-foreground text-xs", t),
|
|
5818
5819
|
children: e
|
|
5819
5820
|
}), Ts = ({ children: e, isRequired: t, className: n, ...r }) => /* @__PURE__ */ W("label", {
|
|
5820
|
-
className:
|
|
5821
|
+
className: P("mb-1 block flex-1 select-none text-sm leading-normal peer-disabled:cursor-not-allowed peer-disabled:opacity-70", n),
|
|
5821
5822
|
...r,
|
|
5822
5823
|
children: [
|
|
5823
5824
|
e,
|
|
@@ -5828,9 +5829,9 @@ var Cs = ({ children: e }) => /* @__PURE__ */ U("p", {
|
|
|
5828
5829
|
})
|
|
5829
5830
|
]
|
|
5830
5831
|
}), Es = ({ error: e, touched: t = !1, helperText: n, containerStyles: r, helperTextStyles: i, readOnly: a, children: o, label: s, labelStyles: c, isRequired: l, name: u }) => /* @__PURE__ */ U("div", {
|
|
5831
|
-
className:
|
|
5832
|
+
className: P("form-control w-full", a ? "pointer-events-none" : "", r),
|
|
5832
5833
|
children: /* @__PURE__ */ W("div", {
|
|
5833
|
-
className:
|
|
5834
|
+
className: P("w-full shrink-0", "sm:flex-1"),
|
|
5834
5835
|
children: [
|
|
5835
5836
|
s && /* @__PURE__ */ U(Ts, {
|
|
5836
5837
|
htmlFor: u,
|
|
@@ -5841,7 +5842,7 @@ var Cs = ({ children: e }) => /* @__PURE__ */ U("p", {
|
|
|
5841
5842
|
o,
|
|
5842
5843
|
t && e && /* @__PURE__ */ U(Cs, { children: e }),
|
|
5843
5844
|
n && /* @__PURE__ */ U("div", {
|
|
5844
|
-
className:
|
|
5845
|
+
className: P("break-word mt-2 w-full"),
|
|
5845
5846
|
children: /* @__PURE__ */ U(ws, {
|
|
5846
5847
|
styles: i,
|
|
5847
5848
|
children: n
|
|
@@ -5849,7 +5850,7 @@ var Cs = ({ children: e }) => /* @__PURE__ */ U("p", {
|
|
|
5849
5850
|
})
|
|
5850
5851
|
]
|
|
5851
5852
|
})
|
|
5852
|
-
}), Ds =
|
|
5853
|
+
}), Ds = Te.forwardRef(({ label: e, type: t, name: n, isRequired: r, labelStyles: i, leftIcon: a, rightIcon: o, leftIconBoxStyles: s, rightIconBoxStyles: c, containerStyles: l, helperTextStyles: u, inputStyles: d, value: f, disabled: p, inputProps: m, placeholder: h, readOnly: g, id: _, onChange: v, onBlur: y, error: b, helperText: x, touched: S, inputContainerStyles: C, leftIconBoxProps: w, rightIconBoxProps: T }, E) => /* @__PURE__ */ W(Es, {
|
|
5853
5854
|
containerStyles: l,
|
|
5854
5855
|
helperTextStyles: u,
|
|
5855
5856
|
error: b,
|
|
@@ -5859,13 +5860,13 @@ var Cs = ({ children: e }) => /* @__PURE__ */ U("p", {
|
|
|
5859
5860
|
children: [e && /* @__PURE__ */ U(Ts, {
|
|
5860
5861
|
htmlFor: n,
|
|
5861
5862
|
isRequired: r,
|
|
5862
|
-
className:
|
|
5863
|
+
className: P("text-3", i),
|
|
5863
5864
|
children: e
|
|
5864
5865
|
}), /* @__PURE__ */ W("div", {
|
|
5865
|
-
className:
|
|
5866
|
+
className: P("relative w-full", C),
|
|
5866
5867
|
children: [
|
|
5867
5868
|
a ? /* @__PURE__ */ U("div", {
|
|
5868
|
-
className:
|
|
5869
|
+
className: P("absolute top-0 bottom-0 left-0 flex w-9 items-center justify-center overflow-hidden rounded-l-md", "border border-transparent", s),
|
|
5869
5870
|
...w,
|
|
5870
5871
|
children: a
|
|
5871
5872
|
}) : null,
|
|
@@ -5877,14 +5878,14 @@ var Cs = ({ children: e }) => /* @__PURE__ */ U("p", {
|
|
|
5877
5878
|
value: f,
|
|
5878
5879
|
disabled: p,
|
|
5879
5880
|
readOnly: g,
|
|
5880
|
-
className:
|
|
5881
|
+
className: P("bg-brand-foreground text-brand", g ? "focus-visible:ring-0" : "", a ? "pl-11" : "", o ? "pr-11" : "", d),
|
|
5881
5882
|
onChange: v,
|
|
5882
5883
|
onBlur: y,
|
|
5883
5884
|
ref: E,
|
|
5884
5885
|
...m
|
|
5885
5886
|
}),
|
|
5886
5887
|
o ? /* @__PURE__ */ U("div", {
|
|
5887
|
-
className:
|
|
5888
|
+
className: P("absolute top-0 right-0 bottom-0 flex w-9 items-center justify-center overflow-hidden rounded-r-md", "border border-transparent", c),
|
|
5888
5889
|
...T,
|
|
5889
5890
|
children: o
|
|
5890
5891
|
}) : null
|
|
@@ -5895,7 +5896,7 @@ Ds.displayName = "FormInput";
|
|
|
5895
5896
|
//#endregion
|
|
5896
5897
|
//#region src/elements/forum/comments/ReplyBox.tsx
|
|
5897
5898
|
var Os = ({ isParent: e = !0 }) => {
|
|
5898
|
-
let { isLoggedIn: t, account: n } =
|
|
5899
|
+
let { isLoggedIn: t, account: n } = A(), r = z(() => {
|
|
5899
5900
|
let e = [n?.first_name, n?.last_name]?.filter(Boolean);
|
|
5900
5901
|
return e?.length === 1 ? e?.at(0)?.slice(0, 2)?.toUpperCase() : e?.length > 1 ? e?.map((e) => e?.at(0)?.toUpperCase()).join("") : n?.username?.slice(0, 2)?.toUpperCase();
|
|
5901
5902
|
}, [n]), i = z(() => {
|
|
@@ -5909,17 +5910,17 @@ var Os = ({ isParent: e = !0 }) => {
|
|
|
5909
5910
|
return null;
|
|
5910
5911
|
}, [n]);
|
|
5911
5912
|
return t ? /* @__PURE__ */ W(Wc, {
|
|
5912
|
-
className:
|
|
5913
|
+
className: P(e ? "h-10 w-10" : "h-[40px] w-[40px]"),
|
|
5913
5914
|
children: [/* @__PURE__ */ U(Kc, {
|
|
5914
5915
|
src: i?.media?.location,
|
|
5915
5916
|
alt: i?.alt || "User Profile"
|
|
5916
5917
|
}), /* @__PURE__ */ U(Jc, {
|
|
5917
|
-
className:
|
|
5918
|
+
className: P("bg-brand text-brand-foreground", !e && "text-sm"),
|
|
5918
5919
|
children: r
|
|
5919
5920
|
})]
|
|
5920
5921
|
}) : null;
|
|
5921
5922
|
}, ks = ({ post: e, isParent: t = !1, parentCommentId: n = null, onCommentAdded: r, forumKey: i }) => {
|
|
5922
|
-
let { fetch: a, logger: o } =
|
|
5923
|
+
let { fetch: a, logger: o } = F(), { account: s, isLoggedIn: c } = A(), { openModal: l } = M(), { canInteractWithComments: u } = Ho(), [d, f] = V(!1), [p, m] = V("");
|
|
5923
5924
|
if (c && !u) return null;
|
|
5924
5925
|
let h = () => {
|
|
5925
5926
|
c || l("login", {});
|
|
@@ -5945,7 +5946,7 @@ var Os = ({ isParent: e = !0 }) => {
|
|
|
5945
5946
|
}
|
|
5946
5947
|
};
|
|
5947
5948
|
return /* @__PURE__ */ W("div", {
|
|
5948
|
-
className:
|
|
5949
|
+
className: P("flex w-full items-start gap-3", !t && "gap-2.5"),
|
|
5949
5950
|
children: [/* @__PURE__ */ U(Os, { isParent: t }), /* @__PURE__ */ W("div", {
|
|
5950
5951
|
className: "flex w-full items-start justify-between gap-4",
|
|
5951
5952
|
children: [/* @__PURE__ */ U("div", {
|
|
@@ -5957,7 +5958,7 @@ var Os = ({ isParent: e = !0 }) => {
|
|
|
5957
5958
|
onChange: (e) => m(e?.target?.value),
|
|
5958
5959
|
inputStyles: "border-[#D1D6E1] text-sm sm:placeholder:text-sm placeholder:text-[#717C91] bg-white focus-visible:ring-[#D1D6E1] focus-visible:ring-1"
|
|
5959
5960
|
})
|
|
5960
|
-
}), /* @__PURE__ */ W(
|
|
5961
|
+
}), /* @__PURE__ */ W(x, {
|
|
5961
5962
|
elementKey: "add",
|
|
5962
5963
|
onClick: () => {
|
|
5963
5964
|
if (!c) {
|
|
@@ -6019,7 +6020,7 @@ var As = ({ comment: e, avatarStyles: t }) => {
|
|
|
6019
6020
|
return null;
|
|
6020
6021
|
}, [e]);
|
|
6021
6022
|
return /* @__PURE__ */ W(Wc, {
|
|
6022
|
-
className:
|
|
6023
|
+
className: P("h-[28px] w-[28px]", t),
|
|
6023
6024
|
children: [/* @__PURE__ */ U(Kc, {
|
|
6024
6025
|
src: a?.media?.location,
|
|
6025
6026
|
alt: a?.alt || "User Profile"
|
|
@@ -6070,7 +6071,7 @@ var As = ({ comment: e, avatarStyles: t }) => {
|
|
|
6070
6071
|
children: e
|
|
6071
6072
|
})]
|
|
6072
6073
|
}), Ns = ({ comment: e, forumKey: t, userEngagementHashMap: n, setUserEngagementHashMap: r }) => {
|
|
6073
|
-
let { fetch: i, logger: a } =
|
|
6074
|
+
let { fetch: i, logger: a } = F(), { isLoggedIn: o } = A(), { openModal: s } = M(), { canInteractWithComments: c } = Ho(), l = n?.[e?._id], [u, d] = V(!1), [f, p] = V(!!l?.upvoted_at), [m, h] = V(!!l?.downvoted_at), [g, _] = V((e.upvote_count ?? 0) - (e.downvote_count ?? 0)), v = !o || c;
|
|
6074
6075
|
return R(() => {
|
|
6075
6076
|
_((e.upvote_count ?? 0) - (e.downvote_count ?? 0));
|
|
6076
6077
|
}, [e?.upvote_count, e?.downvote_count]), R(() => {
|
|
@@ -6082,7 +6083,7 @@ var As = ({ comment: e, avatarStyles: t }) => {
|
|
|
6082
6083
|
children: [
|
|
6083
6084
|
/* @__PURE__ */ U("button", {
|
|
6084
6085
|
type: "button",
|
|
6085
|
-
className:
|
|
6086
|
+
className: P("flex cursor-pointer items-center rounded-sm px-0.5 transition-all duration-200", !v && "cursor-not-allowed opacity-50"),
|
|
6086
6087
|
onClick: async (n) => {
|
|
6087
6088
|
if (n.stopPropagation(), n.preventDefault(), !o) {
|
|
6088
6089
|
s("login", {});
|
|
@@ -6121,12 +6122,12 @@ var As = ({ comment: e, avatarStyles: t }) => {
|
|
|
6121
6122
|
})
|
|
6122
6123
|
}),
|
|
6123
6124
|
/* @__PURE__ */ U("span", {
|
|
6124
|
-
className:
|
|
6125
|
+
className: P("font-semibold text-sm"),
|
|
6125
6126
|
children: g
|
|
6126
6127
|
}),
|
|
6127
6128
|
/* @__PURE__ */ U("button", {
|
|
6128
6129
|
type: "button",
|
|
6129
|
-
className:
|
|
6130
|
+
className: P("flex cursor-pointer items-center rounded-sm px-0.5 transition-all duration-200", !v && "cursor-not-allowed opacity-50"),
|
|
6130
6131
|
onClick: async (n) => {
|
|
6131
6132
|
if (n.stopPropagation(), n.preventDefault(), !o) {
|
|
6132
6133
|
s("login", {});
|
|
@@ -6169,7 +6170,7 @@ var As = ({ comment: e, avatarStyles: t }) => {
|
|
|
6169
6170
|
}, Ps = ({ forumKey: e, post: t, comment: n, replyCount: r, onReplyAdded: i, onToggleReplies: a, showReplyBox: o, userEngagementHashMap: s, setUserEngagementHashMap: c }) => {
|
|
6170
6171
|
let l = !!n?.parent;
|
|
6171
6172
|
return /* @__PURE__ */ W("div", {
|
|
6172
|
-
className:
|
|
6173
|
+
className: P("w-full space-y-3"),
|
|
6173
6174
|
children: [/* @__PURE__ */ W("div", {
|
|
6174
6175
|
className: "flex items-center justify-between",
|
|
6175
6176
|
children: [/* @__PURE__ */ W("div", {
|
|
@@ -6209,19 +6210,19 @@ var Fs = ({ wrapperStyles: e }) => /* @__PURE__ */ W("div", {
|
|
|
6209
6210
|
}), Is = ({ comment: e, replyCount: t, showReplies: n, isShowMoreActive: r }) => {
|
|
6210
6211
|
let i = t === 0 ? 2 : t + (n ? 2 : 1) + +!!r;
|
|
6211
6212
|
return n ? /* @__PURE__ */ U(H, { children: Array(i).fill(0).map((e, n) => /* @__PURE__ */ W("div", {
|
|
6212
|
-
className:
|
|
6213
|
+
className: P("relative col-start-1 col-end-2", n === i - 1 && "grid h-full grid-cols-2 grid-rows-4"),
|
|
6213
6214
|
style: {
|
|
6214
6215
|
gridRowStart: n + 2,
|
|
6215
6216
|
gridRowEnd: n + 2 + 1
|
|
6216
6217
|
},
|
|
6217
6218
|
children: [
|
|
6218
|
-
n < i - 1 && /* @__PURE__ */ U("div", { className:
|
|
6219
|
-
t === 0 && n === i - 1 && /* @__PURE__ */ U(H, { children: /* @__PURE__ */ U("div", { className:
|
|
6220
|
-
t > 0 && /* @__PURE__ */ U(H, { children: (n === i - 1 || n > 1) && /* @__PURE__ */ U(H, { children: /* @__PURE__ */ U("div", { className:
|
|
6219
|
+
n < i - 1 && /* @__PURE__ */ U("div", { className: P("absolute top-0 bottom-0 left-1/2 -translate-x-1/2 border-gray-200 border-l", n === 0 && "top-2") }),
|
|
6220
|
+
t === 0 && n === i - 1 && /* @__PURE__ */ U(H, { children: /* @__PURE__ */ U("div", { className: P("absolute top-0 right-0 left-[14px] h-[72px] rounded-bl-md border-gray-200 border-b border-l") }) }),
|
|
6221
|
+
t > 0 && /* @__PURE__ */ U(H, { children: (n === i - 1 || n > 1) && /* @__PURE__ */ U(H, { children: /* @__PURE__ */ U("div", { className: P("absolute top-0 right-0 left-[14px] h-[30px] rounded-bl-md border-gray-200 border-b border-l", r && n === i - 1 && "h-[20px]") }) }) })
|
|
6221
6222
|
]
|
|
6222
6223
|
}, n)) }) : null;
|
|
6223
6224
|
}, Ls = ({ forumKey: e, post: t, comment: n, onChildReplyAdded: r, index: i, userEngagementHashMap: a, setUserEngagementHashMap: o }) => {
|
|
6224
|
-
let { fetch: s, logger: c } =
|
|
6225
|
+
let { fetch: s, logger: c } = F(), [l, u] = V(n?.replies || []), [d, f] = V(1), [p, m] = V((n?.replies?.length ?? 0) >= 5), [h, g] = V(!1), [_, v] = V(!1), [y, b] = V(!1), [x, S] = V(typeof n?.reply_count == "number" ? n.reply_count : 0), C = !n?.parent, w = async (t) => {
|
|
6225
6226
|
if (C) try {
|
|
6226
6227
|
g(!0);
|
|
6227
6228
|
let r = await s.url(`/v1/community/${e}/comment/${n._id}/get-replies`).post({
|
|
@@ -6246,7 +6247,7 @@ var Fs = ({ wrapperStyles: e }) => /* @__PURE__ */ W("div", {
|
|
|
6246
6247
|
v((e) => !e), b((e) => !e);
|
|
6247
6248
|
};
|
|
6248
6249
|
return /* @__PURE__ */ W("div", {
|
|
6249
|
-
className:
|
|
6250
|
+
className: P("grid w-full grid-cols-[30px_1fr] gap-x-1.5 gap-y-0", !C && "col-start-2 row-span-1 mt-4"),
|
|
6250
6251
|
style: {
|
|
6251
6252
|
gridTemplateRows: `repeat(${(_ ? l?.length : 0) + 2},minmax(0px,auto))`,
|
|
6252
6253
|
...C ? {} : { gridRowStart: (i ?? 0) + 3 + 1 }
|
|
@@ -6329,7 +6330,7 @@ var Fs = ({ wrapperStyles: e }) => /* @__PURE__ */ W("div", {
|
|
|
6329
6330
|
]
|
|
6330
6331
|
})]
|
|
6331
6332
|
}), zs = ({ forumKey: e, post: t, onCommentCountChange: n }) => {
|
|
6332
|
-
let { fetch: r, logger: i } =
|
|
6333
|
+
let { fetch: r, logger: i } = F(), [a, o] = V(!0), [s, c] = V(!1), [l, u] = V([]), [d, f] = V(1), [p, m] = V(!1), [h, g] = V("desc"), [_, v] = V(!1), y = B(null), [b, x] = V(t?.comments_count ?? 0), [S, C] = V({}), w = async (n = 1, a = h) => {
|
|
6333
6334
|
try {
|
|
6334
6335
|
let i = n === 1;
|
|
6335
6336
|
i ? o(!0) : c(!0);
|
|
@@ -6448,7 +6449,7 @@ var Fs = ({ wrapperStyles: e }) => /* @__PURE__ */ W("div", {
|
|
|
6448
6449
|
]
|
|
6449
6450
|
});
|
|
6450
6451
|
}, Bs = () => {
|
|
6451
|
-
let { isLoggedIn: e, account: t } =
|
|
6452
|
+
let { isLoggedIn: e, account: t } = A(), n = z(() => {
|
|
6452
6453
|
let e = [t?.first_name, t?.last_name]?.filter(Boolean);
|
|
6453
6454
|
return e?.length === 1 ? e?.at(0)?.slice(0, 2)?.toUpperCase() : e?.length > 1 ? e?.map((e) => e?.at(0)?.toUpperCase()).join("") : t?.username?.slice(0, 2)?.toUpperCase();
|
|
6454
6455
|
}, [t]), r = z(() => {
|
|
@@ -6462,17 +6463,17 @@ var Fs = ({ wrapperStyles: e }) => /* @__PURE__ */ W("div", {
|
|
|
6462
6463
|
return null;
|
|
6463
6464
|
}, [t]);
|
|
6464
6465
|
return e ? /* @__PURE__ */ W(Wc, {
|
|
6465
|
-
className:
|
|
6466
|
+
className: P("h-11 w-11"),
|
|
6466
6467
|
children: [/* @__PURE__ */ U(Kc, {
|
|
6467
6468
|
src: r?.media?.location,
|
|
6468
6469
|
alt: r?.alt || "User Profile"
|
|
6469
6470
|
}), /* @__PURE__ */ U(Jc, {
|
|
6470
|
-
className:
|
|
6471
|
+
className: P("bg-brand text-brand-foreground"),
|
|
6471
6472
|
children: n
|
|
6472
6473
|
})]
|
|
6473
6474
|
}) : null;
|
|
6474
6475
|
}, Vs = ({ forumKey: e, onPostCreated: t }) => {
|
|
6475
|
-
let { forum: n, isMember: r, isLoadingMembership: i, isInviteOnly: a } = Ho(), { isAuthLoaded: o, isLoggedIn: s, account: c } =
|
|
6476
|
+
let { forum: n, isMember: r, isLoadingMembership: i, isInviteOnly: a } = Ho(), { isAuthLoaded: o, isLoggedIn: s, account: c } = A(), [l, u] = V(!1), d = (e) => {
|
|
6476
6477
|
t?.(e), u(!1);
|
|
6477
6478
|
}, f = z(() => {
|
|
6478
6479
|
if (!c) return "there";
|
|
@@ -6551,7 +6552,7 @@ var Fs = ({ wrapperStyles: e }) => /* @__PURE__ */ W("div", {
|
|
|
6551
6552
|
post: e,
|
|
6552
6553
|
postDetailPageURLPattern: t ? null : n,
|
|
6553
6554
|
children: /* @__PURE__ */ W("div", {
|
|
6554
|
-
className:
|
|
6555
|
+
className: P("flex flex-col gap-3 rounded-lg border border-[#E5E5E5] bg-white p-3", t && "border-none px-0 py-0", o),
|
|
6555
6556
|
children: [
|
|
6556
6557
|
/* @__PURE__ */ U(is, {
|
|
6557
6558
|
post: e,
|
|
@@ -6593,7 +6594,7 @@ var Fs = ({ wrapperStyles: e }) => /* @__PURE__ */ W("div", {
|
|
|
6593
6594
|
}) : /* @__PURE__ */ U(H, { children: t }), Ks = ({ onSubmit: e, isSubmitting: t, error: n, communityName: r = "this community", className: i }) => {
|
|
6594
6595
|
let [a, o] = V(""), [s, c] = V("idle");
|
|
6595
6596
|
return s === "success" ? /* @__PURE__ */ W("div", {
|
|
6596
|
-
className:
|
|
6597
|
+
className: P("flex flex-col items-center gap-3", i),
|
|
6597
6598
|
children: [
|
|
6598
6599
|
/* @__PURE__ */ U("div", {
|
|
6599
6600
|
className: "flex size-12 items-center justify-center rounded-full bg-green-100",
|
|
@@ -6613,7 +6614,7 @@ var Fs = ({ wrapperStyles: e }) => /* @__PURE__ */ W("div", {
|
|
|
6613
6614
|
})
|
|
6614
6615
|
]
|
|
6615
6616
|
}) : /* @__PURE__ */ W("div", {
|
|
6616
|
-
className:
|
|
6617
|
+
className: P("flex w-full flex-col gap-4", i),
|
|
6617
6618
|
children: [
|
|
6618
6619
|
/* @__PURE__ */ W("div", {
|
|
6619
6620
|
className: "flex flex-col gap-1.5",
|
|
@@ -6658,7 +6659,7 @@ var Fs = ({ wrapperStyles: e }) => /* @__PURE__ */ W("div", {
|
|
|
6658
6659
|
}
|
|
6659
6660
|
},
|
|
6660
6661
|
disabled: t,
|
|
6661
|
-
className:
|
|
6662
|
+
className: P("inline-flex w-full items-center justify-center rounded-md bg-brand px-4 py-2.5 font-medium text-brand-foreground text-sm transition-colors", "hover:bg-brand/90 focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2", "cursor-pointer disabled:pointer-events-none disabled:opacity-50"),
|
|
6662
6663
|
children: t ? /* @__PURE__ */ W(H, { children: [/* @__PURE__ */ U(gn, { className: "mr-2 size-4 animate-spin" }), "Submitting..."] }) : "Request to Join"
|
|
6663
6664
|
})
|
|
6664
6665
|
]
|
|
@@ -6688,11 +6689,11 @@ var Fs = ({ wrapperStyles: e }) => /* @__PURE__ */ W("div", {
|
|
|
6688
6689
|
]
|
|
6689
6690
|
})]
|
|
6690
6691
|
}), Js = ({ communityName: e = "this community", className: t }) => {
|
|
6691
|
-
let { isLoggedIn: n } =
|
|
6692
|
+
let { isLoggedIn: n } = A(), { openModal: r } = M(), { isJoinRequestPending: i, allowJoinRequests: a, submitJoinRequest: o } = Ho(), [s, c] = V(!1), [l, u] = V(null), d = () => {
|
|
6692
6693
|
r("login", {});
|
|
6693
6694
|
}, f = n && i;
|
|
6694
6695
|
return /* @__PURE__ */ W("div", {
|
|
6695
|
-
className:
|
|
6696
|
+
className: P("relative", t),
|
|
6696
6697
|
children: [/* @__PURE__ */ W("div", {
|
|
6697
6698
|
className: "pointer-events-none flex flex-col gap-y-4 blur-[2px]",
|
|
6698
6699
|
children: [
|
|
@@ -6706,7 +6707,7 @@ var Fs = ({ wrapperStyles: e }) => /* @__PURE__ */ W("div", {
|
|
|
6706
6707
|
className: "flex max-w-sm flex-col items-center gap-3 rounded-xl border border-gray-200 bg-white p-6 text-center shadow-sm",
|
|
6707
6708
|
children: [
|
|
6708
6709
|
/* @__PURE__ */ U("div", {
|
|
6709
|
-
className:
|
|
6710
|
+
className: P("flex size-12 items-center justify-center rounded-full", f ? "bg-amber-100" : "bg-gray-100"),
|
|
6710
6711
|
children: f ? /* @__PURE__ */ U(sn, { className: "size-5 text-amber-600" }) : /* @__PURE__ */ U(_n, { className: "size-5 text-text-2" })
|
|
6711
6712
|
}),
|
|
6712
6713
|
/* @__PURE__ */ U("p", {
|
|
@@ -6748,7 +6749,7 @@ var Fs = ({ wrapperStyles: e }) => /* @__PURE__ */ W("div", {
|
|
|
6748
6749
|
}) : /* @__PURE__ */ W(H, { children: [/* @__PURE__ */ U("p", {
|
|
6749
6750
|
className: "text-text-2 text-xs",
|
|
6750
6751
|
children: "Please log in to view and participate in comments."
|
|
6751
|
-
}), /* @__PURE__ */ U(
|
|
6752
|
+
}), /* @__PURE__ */ U(x, {
|
|
6752
6753
|
elementKey: "login-cta",
|
|
6753
6754
|
onClick: d,
|
|
6754
6755
|
className: "mt-2",
|
|
@@ -6759,7 +6760,7 @@ var Fs = ({ wrapperStyles: e }) => /* @__PURE__ */ W("div", {
|
|
|
6759
6760
|
})]
|
|
6760
6761
|
});
|
|
6761
6762
|
}, Ys = ({ communityName: e = "this community", className: t }) => /* @__PURE__ */ W("div", {
|
|
6762
|
-
className:
|
|
6763
|
+
className: P("flex flex-col items-center gap-3", t),
|
|
6763
6764
|
children: [
|
|
6764
6765
|
/* @__PURE__ */ U("div", {
|
|
6765
6766
|
className: "flex size-14 items-center justify-center rounded-full bg-amber-100",
|
|
@@ -6810,7 +6811,7 @@ var Fs = ({ wrapperStyles: e }) => /* @__PURE__ */ W("div", {
|
|
|
6810
6811
|
})
|
|
6811
6812
|
]
|
|
6812
6813
|
}), Zs = ({ isOpen: e, communityName: t = "this community", className: n }) => {
|
|
6813
|
-
let { isLoggedIn: r } =
|
|
6814
|
+
let { isLoggedIn: r } = A(), { openModal: i } = M(), { isJoinRequestPending: a, allowJoinRequests: o, submitJoinRequest: s } = Ho(), [c, l] = V(!1), [u, d] = V(null), f = () => {
|
|
6814
6815
|
i("login", {});
|
|
6815
6816
|
}, p = async (e) => {
|
|
6816
6817
|
l(!0), d(null);
|
|
@@ -6822,32 +6823,32 @@ var Fs = ({ wrapperStyles: e }) => /* @__PURE__ */ W("div", {
|
|
|
6822
6823
|
l(!1);
|
|
6823
6824
|
}
|
|
6824
6825
|
}, m = r && a;
|
|
6825
|
-
return /* @__PURE__ */ U(
|
|
6826
|
+
return /* @__PURE__ */ U(oe, {
|
|
6826
6827
|
open: e,
|
|
6827
|
-
children: /* @__PURE__ */ U(
|
|
6828
|
-
className:
|
|
6828
|
+
children: /* @__PURE__ */ U(ne, {
|
|
6829
|
+
className: P("max-w-md", n),
|
|
6829
6830
|
showCloseButton: !1,
|
|
6830
6831
|
onPointerDownOutside: (e) => e.preventDefault(),
|
|
6831
6832
|
onEscapeKeyDown: (e) => e.preventDefault(),
|
|
6832
|
-
children: /* @__PURE__ */ W(
|
|
6833
|
+
children: /* @__PURE__ */ W(ee, {
|
|
6833
6834
|
className: "items-center gap-4",
|
|
6834
6835
|
children: [
|
|
6835
6836
|
/* @__PURE__ */ U("div", {
|
|
6836
|
-
className:
|
|
6837
|
+
className: P("flex size-14 items-center justify-center rounded-full", m ? "bg-amber-100" : "bg-gray-100"),
|
|
6837
6838
|
children: m ? /* @__PURE__ */ U(sn, { className: "size-6 text-amber-600" }) : /* @__PURE__ */ U(_n, { className: "size-6 text-text-2" })
|
|
6838
6839
|
}),
|
|
6839
|
-
/* @__PURE__ */ U(
|
|
6840
|
+
/* @__PURE__ */ U(re, {
|
|
6840
6841
|
className: "text-center font-semibold text-lg",
|
|
6841
6842
|
children: m ? "Request Pending" : "Members Only Content"
|
|
6842
6843
|
}),
|
|
6843
|
-
r ? a ? /* @__PURE__ */ W(
|
|
6844
|
+
r ? a ? /* @__PURE__ */ W(ie, {
|
|
6844
6845
|
className: "text-center text-sm text-text-2",
|
|
6845
6846
|
children: [
|
|
6846
6847
|
"Your request to join ",
|
|
6847
6848
|
t,
|
|
6848
6849
|
" is pending approval. You'll be notified once the admins review your request."
|
|
6849
6850
|
]
|
|
6850
|
-
}) : o ? /* @__PURE__ */ W(H, { children: [/* @__PURE__ */ U(
|
|
6851
|
+
}) : o ? /* @__PURE__ */ W(H, { children: [/* @__PURE__ */ U(ie, {
|
|
6851
6852
|
className: "text-center text-sm text-text-2",
|
|
6852
6853
|
children: "This community is invite-only. Submit a request to join and get access to posts."
|
|
6853
6854
|
}), /* @__PURE__ */ U(Ks, {
|
|
@@ -6856,17 +6857,17 @@ var Fs = ({ wrapperStyles: e }) => /* @__PURE__ */ W("div", {
|
|
|
6856
6857
|
error: u,
|
|
6857
6858
|
communityName: t,
|
|
6858
6859
|
className: "mt-2 w-full"
|
|
6859
|
-
})] }) : /* @__PURE__ */ W(
|
|
6860
|
+
})] }) : /* @__PURE__ */ W(ie, {
|
|
6860
6861
|
className: "text-center text-sm text-text-2",
|
|
6861
6862
|
children: [
|
|
6862
6863
|
"You need to be a member of ",
|
|
6863
6864
|
t,
|
|
6864
6865
|
" to view posts. Please contact the community administrators for access."
|
|
6865
6866
|
]
|
|
6866
|
-
}) : /* @__PURE__ */ W(H, { children: [/* @__PURE__ */ U(
|
|
6867
|
+
}) : /* @__PURE__ */ W(H, { children: [/* @__PURE__ */ U(ie, {
|
|
6867
6868
|
className: "text-center text-sm text-text-2",
|
|
6868
6869
|
children: "Please log in to access this community's content."
|
|
6869
|
-
}), /* @__PURE__ */ U(
|
|
6870
|
+
}), /* @__PURE__ */ U(x, {
|
|
6870
6871
|
elementKey: "login-cta",
|
|
6871
6872
|
onClick: f,
|
|
6872
6873
|
children: "Log in"
|
|
@@ -6876,40 +6877,40 @@ var Fs = ({ wrapperStyles: e }) => /* @__PURE__ */ W("div", {
|
|
|
6876
6877
|
})
|
|
6877
6878
|
});
|
|
6878
6879
|
}, Qs = ({ inputStyles: e, ...t }) => /* @__PURE__ */ U(Ds, {
|
|
6879
|
-
inputStyles:
|
|
6880
|
+
inputStyles: P("border-[#D1D6E1] bg-white text-sm placeholder:text-[#717C91] focus-visible:ring-1 focus-visible:ring-[#D1D6E1] sm:placeholder:text-sm", e),
|
|
6880
6881
|
leftIcon: /* @__PURE__ */ U(xn, { size: 16 }),
|
|
6881
6882
|
...t
|
|
6882
|
-
}), $s =
|
|
6883
|
+
}), $s = ke(({ children: e, className: t, config: n, content: r, styles: i, elementKey: a, generatedClassName: o, ...s }, c) => {
|
|
6883
6884
|
let l = e ?? r;
|
|
6884
6885
|
return typeof l == "string" ? /* @__PURE__ */ U(`h${n?.heading?.level ?? 2}`, {
|
|
6885
6886
|
ref: c,
|
|
6886
6887
|
"data-levo_element_key": a,
|
|
6887
6888
|
"data-levo_element_type": "Heading",
|
|
6888
|
-
className:
|
|
6889
|
+
className: P(t, o),
|
|
6889
6890
|
...s,
|
|
6890
6891
|
children: l ? Ft(l) : ""
|
|
6891
6892
|
}) : null;
|
|
6892
6893
|
});
|
|
6893
6894
|
$s.displayName = "BaseHeading";
|
|
6894
|
-
var ec =
|
|
6895
|
-
let { isStudio: s } =
|
|
6895
|
+
var ec = v($s), tc = ke(({ className: e, elementKey: t, generatedClassName: n, content: r, styles: i, ...a }, o) => {
|
|
6896
|
+
let { isStudio: s } = k();
|
|
6896
6897
|
return /* @__PURE__ */ U("div", {
|
|
6897
6898
|
ref: o,
|
|
6898
6899
|
"data-levo_element_key": t,
|
|
6899
6900
|
"data-levo_element_type": "Iframe",
|
|
6900
|
-
className:
|
|
6901
|
+
className: P(e, n, s && "[&>*]:pointer-events-none"),
|
|
6901
6902
|
...a,
|
|
6902
6903
|
children: typeof r == "string" ? Ft(r) : ""
|
|
6903
6904
|
});
|
|
6904
6905
|
});
|
|
6905
6906
|
tc.displayName = "BaseIframe";
|
|
6906
|
-
var nc =
|
|
6907
|
+
var nc = v(tc), rc = ke(({ className: e, image: t, alt: n, width: r, height: i, config: a, content: o, styles: s, elementKey: c, generatedClassName: l, ...u }, d) => {
|
|
6907
6908
|
let f = t ?? o;
|
|
6908
6909
|
return f?.location ? /* @__PURE__ */ U("img", {
|
|
6909
6910
|
ref: d,
|
|
6910
6911
|
"data-levo_element_key": c,
|
|
6911
6912
|
"data-levo_element_type": "Image",
|
|
6912
|
-
className:
|
|
6913
|
+
className: P(e, l),
|
|
6913
6914
|
src: f?.location,
|
|
6914
6915
|
srcSet: f?.srcset?.path,
|
|
6915
6916
|
alt: a?.image?.alt ?? n,
|
|
@@ -6925,26 +6926,26 @@ var nc = _(tc), rc = Ae(({ className: e, image: t, alt: n, width: r, height: i,
|
|
|
6925
6926
|
});
|
|
6926
6927
|
});
|
|
6927
6928
|
rc.displayName = "BaseImage";
|
|
6928
|
-
var ic =
|
|
6929
|
+
var ic = v(rc), ac = ke(({ children: e, className: t, config: n, content: r, styles: i, elementKey: a, generatedClassName: o, ...s }, c) => {
|
|
6929
6930
|
let l = n?.action?.type === "external_link" ? n?.action?.value : n?.action?.type === "email" ? `mailto:${n?.action?.value}` : n?.action?.type === "phone" ? `tel:${n?.action?.value}` : "#";
|
|
6930
6931
|
return /* @__PURE__ */ U("a", {
|
|
6931
6932
|
ref: c,
|
|
6932
6933
|
"data-levo_element_key": a,
|
|
6933
6934
|
"data-levo_element_type": "Link",
|
|
6934
|
-
className:
|
|
6935
|
+
className: P(t, o),
|
|
6935
6936
|
href: l,
|
|
6936
6937
|
...s,
|
|
6937
6938
|
children: e
|
|
6938
6939
|
});
|
|
6939
6940
|
});
|
|
6940
6941
|
ac.displayName = "BaseLink";
|
|
6941
|
-
var oc =
|
|
6942
|
+
var oc = v(ac), sc = ke(({ className: e, media: t, alt: n, width: r, height: i, content: a, config: o, styles: s, elementKey: c, generatedClassName: l, isVideo: u, ...d }, f) => {
|
|
6942
6943
|
let p = t ?? a;
|
|
6943
6944
|
return p?.location ? u || p.type === "video" || p.location.match(/\.(mp4|webm|ogg|mov)$/i) ? /* @__PURE__ */ W("video", {
|
|
6944
6945
|
ref: f,
|
|
6945
6946
|
"data-levo_element_key": c,
|
|
6946
6947
|
"data-levo_element_type": "Media",
|
|
6947
|
-
className:
|
|
6948
|
+
className: P(e, l),
|
|
6948
6949
|
width: o?.media?.width ?? r,
|
|
6949
6950
|
height: o?.media?.height ?? i,
|
|
6950
6951
|
"aria-label": o?.media?.alt ?? n,
|
|
@@ -6967,7 +6968,7 @@ var oc = _(ac), sc = Ae(({ className: e, media: t, alt: n, width: r, height: i,
|
|
|
6967
6968
|
ref: f,
|
|
6968
6969
|
"data-levo_element_key": c,
|
|
6969
6970
|
"data-levo_element_type": "Media",
|
|
6970
|
-
className:
|
|
6971
|
+
className: P(e, l),
|
|
6971
6972
|
src: p.location,
|
|
6972
6973
|
srcSet: p.srcset?.path,
|
|
6973
6974
|
alt: o?.image?.alt ?? n,
|
|
@@ -6983,7 +6984,7 @@ var oc = _(ac), sc = Ae(({ className: e, media: t, alt: n, width: r, height: i,
|
|
|
6983
6984
|
});
|
|
6984
6985
|
});
|
|
6985
6986
|
sc.displayName = "BaseMedia";
|
|
6986
|
-
var cc =
|
|
6987
|
+
var cc = v(sc), lc = [
|
|
6987
6988
|
{
|
|
6988
6989
|
id: "subtle-grid",
|
|
6989
6990
|
name: "Subtle Grid",
|
|
@@ -7166,9 +7167,9 @@ var mc = (e) => dc[e] || null, hc = (e) => {
|
|
|
7166
7167
|
break;
|
|
7167
7168
|
}
|
|
7168
7169
|
return t;
|
|
7169
|
-
}, yc =
|
|
7170
|
+
}, yc = L(() => import("./Beams-DEybrmUZ.js").then((e) => ({ default: e.BackgroundBeams }))), bc = L(() => import("./Dots-CMyy77GM.js").then((e) => ({ default: e.BackgroundDots }))), xc = L(() => import("./Grid-kGCr-6by.js").then((e) => ({ default: e.BackgroundGrid }))), Sc = L(() => import("./Gradient-DBn_zXzI.js").then((e) => ({ default: e.BackgroundGradient }))), Cc = L(() => import("./Waves-DjLcbiBu.js").then((e) => ({ default: e.BackgroundWaves }))), wc = Ae(() => /* @__PURE__ */ U("div", { className: "absolute inset-0 z-[-1] bg-transparent" }));
|
|
7170
7171
|
wc.displayName = "EffectFallback";
|
|
7171
|
-
var Tc =
|
|
7172
|
+
var Tc = Ae(({ config: e }) => {
|
|
7172
7173
|
let { type: t, colors: n, settings: r } = e, i = z(() => {
|
|
7173
7174
|
switch (t) {
|
|
7174
7175
|
case "beams": return {
|
|
@@ -7219,7 +7220,7 @@ var Tc = je(({ config: e }) => {
|
|
|
7219
7220
|
}
|
|
7220
7221
|
});
|
|
7221
7222
|
Tc.displayName = "EffectRenderer";
|
|
7222
|
-
var Ec =
|
|
7223
|
+
var Ec = Ae(({ config: e, presetId: t }) => {
|
|
7223
7224
|
let n = z(() => {
|
|
7224
7225
|
if (t) {
|
|
7225
7226
|
let n = gc(t);
|
|
@@ -7231,7 +7232,7 @@ var Ec = je(({ config: e, presetId: t }) => {
|
|
|
7231
7232
|
}
|
|
7232
7233
|
return e || null;
|
|
7233
7234
|
}, [e, t]);
|
|
7234
|
-
return n ? /* @__PURE__ */ U(
|
|
7235
|
+
return n ? /* @__PURE__ */ U(De, {
|
|
7235
7236
|
fallback: /* @__PURE__ */ U(wc, {}),
|
|
7236
7237
|
children: /* @__PURE__ */ U(Tc, { config: n })
|
|
7237
7238
|
}) : null;
|
|
@@ -7239,11 +7240,11 @@ var Ec = je(({ config: e, presetId: t }) => {
|
|
|
7239
7240
|
Ec.displayName = "BackgroundEffects";
|
|
7240
7241
|
//#endregion
|
|
7241
7242
|
//#region src/elements/Section.tsx
|
|
7242
|
-
var Dc =
|
|
7243
|
+
var Dc = ke(({ children: e, className: t, elementKey: n, generatedClassName: r, content: i, config: a, styles: o, ...s }, c) => /* @__PURE__ */ W("section", {
|
|
7243
7244
|
ref: c,
|
|
7244
7245
|
"data-levo_element_key": n,
|
|
7245
7246
|
"data-levo_element_type": "Section",
|
|
7246
|
-
className:
|
|
7247
|
+
className: P(t, r),
|
|
7247
7248
|
...s,
|
|
7248
7249
|
children: [
|
|
7249
7250
|
/* @__PURE__ */ U(_o, { backgroundVideo: a?.backgroundVideo }),
|
|
@@ -7252,13 +7253,13 @@ var Dc = Ae(({ children: e, className: t, elementKey: n, generatedClassName: r,
|
|
|
7252
7253
|
]
|
|
7253
7254
|
}));
|
|
7254
7255
|
Dc.displayName = "BaseSection";
|
|
7255
|
-
var Oc =
|
|
7256
|
+
var Oc = v(Dc), kc = Pn.Root;
|
|
7256
7257
|
function Ac({ className: e, elementKey: t, generatedClassName: n, content: r, config: i, styles: a, ref: o, ...s }) {
|
|
7257
7258
|
return /* @__PURE__ */ U(Pn.List, {
|
|
7258
7259
|
ref: o,
|
|
7259
7260
|
"data-levo_element_key": t,
|
|
7260
7261
|
"data-levo_element_type": "TabsList",
|
|
7261
|
-
className:
|
|
7262
|
+
className: P("inline-flex h-10 items-center justify-center rounded-md bg-muted p-1 text-muted-foreground", e, n),
|
|
7262
7263
|
...s
|
|
7263
7264
|
});
|
|
7264
7265
|
}
|
|
@@ -7268,7 +7269,7 @@ function jc({ className: e, elementKey: t, generatedClassName: n, content: r, co
|
|
|
7268
7269
|
ref: o,
|
|
7269
7270
|
"data-levo_element_key": t,
|
|
7270
7271
|
"data-levo_element_type": "TabsTrigger",
|
|
7271
|
-
className:
|
|
7272
|
+
className: P("inline-flex items-center justify-center whitespace-nowrap rounded-sm px-3 py-1.5 font-medium text-sm ring-offset-background transition-all focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2 disabled:pointer-events-none disabled:opacity-50 data-[state=active]:bg-background data-[state=active]:text-foreground data-[state=active]:shadow-sm", e, n),
|
|
7272
7273
|
...s,
|
|
7273
7274
|
children: r
|
|
7274
7275
|
});
|
|
@@ -7279,24 +7280,24 @@ function Mc({ className: e, elementKey: t, generatedClassName: n, content: r, co
|
|
|
7279
7280
|
ref: o,
|
|
7280
7281
|
"data-levo_element_key": t,
|
|
7281
7282
|
"data-levo_element_type": "TabsContent",
|
|
7282
|
-
className:
|
|
7283
|
+
className: P("mt-2 ring-offset-background focus-visible:outline-none focus-visible:ring-2 focus-visible:ring-ring focus-visible:ring-offset-2", e, n),
|
|
7283
7284
|
...s
|
|
7284
7285
|
});
|
|
7285
7286
|
}
|
|
7286
7287
|
Mc.displayName = "BaseTabsContent";
|
|
7287
|
-
var Nc =
|
|
7288
|
+
var Nc = v(Ac), Pc = v(jc), Fc = v(Mc), Ic = { TypographyBaseStyles: "_TypographyBaseStyles_wqur5_1" }, Lc = ke(({ children: e, className: t, content: n, config: r, styles: i, elementKey: a, generatedClassName: o, ...s }, c) => {
|
|
7288
7289
|
let l = Un.sanitize(e || n);
|
|
7289
7290
|
return /* @__PURE__ */ U("div", {
|
|
7290
7291
|
ref: c,
|
|
7291
7292
|
"data-levo_element_key": a,
|
|
7292
7293
|
"data-levo_element_type": "Typography",
|
|
7293
|
-
className:
|
|
7294
|
+
className: P(Ic.TypographyBaseStyles, t, o, !l && "text-muted-foreground"),
|
|
7294
7295
|
...s,
|
|
7295
7296
|
children: l ? Ft(l) : ""
|
|
7296
7297
|
});
|
|
7297
7298
|
});
|
|
7298
7299
|
Lc.displayName = "BaseTypography";
|
|
7299
|
-
var Rc =
|
|
7300
|
+
var Rc = v(Lc), Q = {
|
|
7300
7301
|
userMenu: "_userMenu_366z5_1",
|
|
7301
7302
|
userAvatar: "_userAvatar_366z5_5",
|
|
7302
7303
|
avatarCircle: "_avatarCircle_366z5_14",
|
|
@@ -7313,7 +7314,7 @@ var Rc = _(Lc), Q = {
|
|
|
7313
7314
|
spinner: "_spinner_366z5_124",
|
|
7314
7315
|
spin: "_spin_366z5_124"
|
|
7315
7316
|
}, zc = ({ elementKey: e, className: t, config: n }) => {
|
|
7316
|
-
let { isLoggedIn: r, account: i, isSignOutLoading: a } =
|
|
7317
|
+
let { isLoggedIn: r, account: i, isSignOutLoading: a } = A(), { openModal: o } = M(), { signOut: s } = se();
|
|
7317
7318
|
if (!n?.enabled) return null;
|
|
7318
7319
|
let c = () => {
|
|
7319
7320
|
o("login");
|
|
@@ -7327,7 +7328,7 @@ var Rc = _(Lc), Q = {
|
|
|
7327
7328
|
return e && t ? `${e[0]}${t[0]}`.toUpperCase() : e ? e[0]?.toUpperCase() : n ? n[0]?.toUpperCase() : r ? r[0]?.toUpperCase() : "U";
|
|
7328
7329
|
};
|
|
7329
7330
|
return /* @__PURE__ */ U("div", {
|
|
7330
|
-
className:
|
|
7331
|
+
className: P(Q.userMenu, t),
|
|
7331
7332
|
"data-levo_element_key": e,
|
|
7332
7333
|
"data-levo_element_type": "UserMenu",
|
|
7333
7334
|
children: r ? /* @__PURE__ */ W(Zo, { children: [/* @__PURE__ */ U(es, {
|
|
@@ -7368,19 +7369,19 @@ var Rc = _(Lc), Q = {
|
|
|
7368
7369
|
onClick: l,
|
|
7369
7370
|
children: [/* @__PURE__ */ U(Dn, { size: 16 }), /* @__PURE__ */ U("span", { children: "Profile" })]
|
|
7370
7371
|
}), /* @__PURE__ */ W("button", {
|
|
7371
|
-
className:
|
|
7372
|
+
className: P(Q.userMenuItem, Q.logoutItem),
|
|
7372
7373
|
onClick: u,
|
|
7373
7374
|
disabled: a,
|
|
7374
7375
|
children: [a ? /* @__PURE__ */ U("div", { className: Q.spinner }) : /* @__PURE__ */ U(vn, { size: 16 }), /* @__PURE__ */ U("span", { children: a ? "Logging out..." : "Logout" })]
|
|
7375
7376
|
})]
|
|
7376
7377
|
})]
|
|
7377
|
-
})] }) : /* @__PURE__ */ U(
|
|
7378
|
+
})] }) : /* @__PURE__ */ U(x, {
|
|
7378
7379
|
elementKey: `${e}_loginButton`,
|
|
7379
7380
|
onClick: c,
|
|
7380
7381
|
children: "Login"
|
|
7381
7382
|
})
|
|
7382
7383
|
});
|
|
7383
|
-
}, Bc =
|
|
7384
|
+
}, Bc = v(zc), Vc = ({ booking: e, summary: t, onClose: n }) => {
|
|
7384
7385
|
let r = (e, t) => {
|
|
7385
7386
|
let n = e / 100;
|
|
7386
7387
|
return new Intl.NumberFormat("en-IN", {
|
|
@@ -7464,7 +7465,7 @@ var Rc = _(Lc), Q = {
|
|
|
7464
7465
|
] })
|
|
7465
7466
|
]
|
|
7466
7467
|
}),
|
|
7467
|
-
/* @__PURE__ */ U(
|
|
7468
|
+
/* @__PURE__ */ U(E, {
|
|
7468
7469
|
elementKey: "booking-close-btn",
|
|
7469
7470
|
onClick: n,
|
|
7470
7471
|
className: "w-full rounded-lg px-4 py-3 font-semibold",
|
|
@@ -7535,7 +7536,7 @@ var Rc = _(Lc), Q = {
|
|
|
7535
7536
|
})
|
|
7536
7537
|
]
|
|
7537
7538
|
}),
|
|
7538
|
-
/* @__PURE__ */ U(
|
|
7539
|
+
/* @__PURE__ */ U(E, {
|
|
7539
7540
|
elementKey: "booking-pay-btn",
|
|
7540
7541
|
onClick: t,
|
|
7541
7542
|
disabled: n,
|
|
@@ -7545,7 +7546,7 @@ var Rc = _(Lc), Q = {
|
|
|
7545
7546
|
]
|
|
7546
7547
|
});
|
|
7547
7548
|
}, Uc = ({ isOpen: e, onClose: t, contentId: n, collectionKey: r }) => {
|
|
7548
|
-
let i =
|
|
7549
|
+
let i = F(), { workspace: a } = A(), { Razorpay: o } = Wn(), { stripePromise: s, config: c, isOpen: l, openStripeCheckout: u, closeStripeCheckout: d, setOnComplete: f } = ce(), [p, m] = V("loading"), [h, g] = V(null), [_, v] = V(null), [y, b] = V(!1), [x, S] = V(null), C = B(null), w = Me(async (e) => {
|
|
7549
7550
|
try {
|
|
7550
7551
|
let t = await i?.fetch?.url(`/v1/payment/booking/${e}/summary`)?.options({ headers: { Origin: a?.id || "" } })?.get().json();
|
|
7551
7552
|
t?.status && t?.content?.data && v(t.content.data);
|
|
@@ -7558,7 +7559,7 @@ var Rc = _(Lc), Q = {
|
|
|
7558
7559
|
i?.fetch?.url(`/v1/payment/booking/${h._id}/confirm`)?.options({ headers: { Origin: a?.id || "" } })?.post({ session_id: e })?.json().then(async (e) => {
|
|
7559
7560
|
e?.content?.data && (g(e.content.data), await w(e.content.data._id)), d(), C.current = null, m("confirmation");
|
|
7560
7561
|
}).catch((e) => {
|
|
7561
|
-
console.error("Failed to confirm booking after Stripe payment:", e),
|
|
7562
|
+
console.error("Failed to confirm booking after Stripe payment:", e), we(e), d(), C.current = null, m("confirmation");
|
|
7562
7563
|
});
|
|
7563
7564
|
}, E = async () => {
|
|
7564
7565
|
if (h) {
|
|
@@ -7577,7 +7578,7 @@ var Rc = _(Lc), Q = {
|
|
|
7577
7578
|
})) : D(t);
|
|
7578
7579
|
} else S("Failed to initiate payment");
|
|
7579
7580
|
} catch (e) {
|
|
7580
|
-
console.error("Initiate payment error:", e),
|
|
7581
|
+
console.error("Initiate payment error:", e), we(e), S("Failed to initiate payment. Please try again.");
|
|
7581
7582
|
}
|
|
7582
7583
|
b(!1);
|
|
7583
7584
|
}
|
|
@@ -7613,7 +7614,7 @@ var Rc = _(Lc), Q = {
|
|
|
7613
7614
|
let t = await i?.fetch?.url(`/v1/payment/booking/${h._id}/confirm`)?.options({ headers: { Origin: a?.id || "" } })?.post(e).json();
|
|
7614
7615
|
t?.status && t?.content?.data ? (g(t.content.data), await w(t.content.data._id), m("confirmation")) : S("Failed to confirm payment");
|
|
7615
7616
|
} catch (e) {
|
|
7616
|
-
console.error("Confirm payment error:", e),
|
|
7617
|
+
console.error("Confirm payment error:", e), we(e), S("Failed to confirm payment. Please contact support.");
|
|
7617
7618
|
}
|
|
7618
7619
|
b(!1);
|
|
7619
7620
|
}
|
|
@@ -7631,7 +7632,7 @@ var Rc = _(Lc), Q = {
|
|
|
7631
7632
|
g(t), await w(t._id), t.unit_amount === 0 || t.status === "confirmed" ? m("confirmation") : m("summary");
|
|
7632
7633
|
} else S("Failed to create booking");
|
|
7633
7634
|
} catch (e) {
|
|
7634
|
-
console.error("Create booking error:", e),
|
|
7635
|
+
console.error("Create booking error:", e), we(e), S("Failed to create booking. Please try again.");
|
|
7635
7636
|
}
|
|
7636
7637
|
})();
|
|
7637
7638
|
}, [
|
|
@@ -7642,13 +7643,13 @@ var Rc = _(Lc), Q = {
|
|
|
7642
7643
|
a?.id,
|
|
7643
7644
|
w
|
|
7644
7645
|
]);
|
|
7645
|
-
let
|
|
7646
|
+
let k = () => {
|
|
7646
7647
|
g(null), v(null), m("loading"), S(null), t();
|
|
7647
7648
|
};
|
|
7648
7649
|
return e ? /* @__PURE__ */ W(H, { children: [/* @__PURE__ */ U(Nn.Root, { children: /* @__PURE__ */ U("div", {
|
|
7649
7650
|
className: "fixed inset-0 z-100 flex justify-center bg-black/50 pt-24",
|
|
7650
7651
|
children: /* @__PURE__ */ W("div", {
|
|
7651
|
-
className:
|
|
7652
|
+
className: P("flex h-fit w-[90%] max-w-[500px] flex-col rounded-lg bg-white p-6"),
|
|
7652
7653
|
children: [/* @__PURE__ */ W("div", {
|
|
7653
7654
|
className: "mb-4 flex w-full items-start justify-between",
|
|
7654
7655
|
children: [/* @__PURE__ */ W("h2", {
|
|
@@ -7660,7 +7661,7 @@ var Rc = _(Lc), Q = {
|
|
|
7660
7661
|
]
|
|
7661
7662
|
}), /* @__PURE__ */ U("button", {
|
|
7662
7663
|
type: "button",
|
|
7663
|
-
onClick:
|
|
7664
|
+
onClick: k,
|
|
7664
7665
|
className: "rounded-md p-2 hover:bg-gray-100 focus:outline-none",
|
|
7665
7666
|
children: /* @__PURE__ */ U(kn, { className: "size-4" })
|
|
7666
7667
|
})]
|
|
@@ -7684,11 +7685,11 @@ var Rc = _(Lc), Q = {
|
|
|
7684
7685
|
p === "confirmation" && h && /* @__PURE__ */ U(Vc, {
|
|
7685
7686
|
booking: h,
|
|
7686
7687
|
summary: _,
|
|
7687
|
-
onClose:
|
|
7688
|
+
onClose: k
|
|
7688
7689
|
})
|
|
7689
7690
|
] })]
|
|
7690
7691
|
})
|
|
7691
|
-
}) }), l && c && /* @__PURE__ */ U(
|
|
7692
|
+
}) }), l && c && /* @__PURE__ */ U(le, {
|
|
7692
7693
|
isOpen: l,
|
|
7693
7694
|
onClose: d,
|
|
7694
7695
|
stripePromise: s,
|
|
@@ -7701,7 +7702,7 @@ var Rc = _(Lc), Q = {
|
|
|
7701
7702
|
function Wc({ className: e, ...t }) {
|
|
7702
7703
|
return /* @__PURE__ */ U(jn.Root, {
|
|
7703
7704
|
"data-slot": "avatar",
|
|
7704
|
-
className:
|
|
7705
|
+
className: P("relative flex h-10 w-10 shrink-0 overflow-hidden rounded-full", e),
|
|
7705
7706
|
...t
|
|
7706
7707
|
});
|
|
7707
7708
|
}
|
|
@@ -7710,7 +7711,7 @@ function Gc({ className: e, isActive: t, ...n }) {
|
|
|
7710
7711
|
className: "relative inline-block h-full w-full overflow-hidden",
|
|
7711
7712
|
children: [/* @__PURE__ */ U(jn.Image, {
|
|
7712
7713
|
"data-slot": "avatar-image",
|
|
7713
|
-
className:
|
|
7714
|
+
className: P("aspect-square size-full", e),
|
|
7714
7715
|
...n
|
|
7715
7716
|
}), t && /* @__PURE__ */ U("span", { className: "absolute right-0 bottom-0 h-2.5 w-2.5 rounded-full border-2 border-white bg-green-500" })]
|
|
7716
7717
|
});
|
|
@@ -7718,7 +7719,7 @@ function Gc({ className: e, isActive: t, ...n }) {
|
|
|
7718
7719
|
function Kc({ className: e, ...t }) {
|
|
7719
7720
|
return /* @__PURE__ */ U(jn.Image, {
|
|
7720
7721
|
"data-slot": "avatar-image",
|
|
7721
|
-
className:
|
|
7722
|
+
className: P("aspect-square size-full", e),
|
|
7722
7723
|
...t
|
|
7723
7724
|
});
|
|
7724
7725
|
}
|
|
@@ -7727,7 +7728,7 @@ function qc({ className: e, isActive: t, ...n }) {
|
|
|
7727
7728
|
className: "relative inline-block h-full w-full overflow-hidden",
|
|
7728
7729
|
children: [/* @__PURE__ */ U(jn.Fallback, {
|
|
7729
7730
|
"data-slot": "avatar-fallback",
|
|
7730
|
-
className:
|
|
7731
|
+
className: P("flex size-full items-center justify-center rounded-full bg-muted", e),
|
|
7731
7732
|
...n
|
|
7732
7733
|
}), t && /* @__PURE__ */ U("span", { className: "absolute right-0 bottom-0 h-2.5 w-2.5 rounded-full border-2 border-white bg-green-500" })]
|
|
7733
7734
|
});
|
|
@@ -7735,28 +7736,28 @@ function qc({ className: e, isActive: t, ...n }) {
|
|
|
7735
7736
|
function Jc({ className: e, ...t }) {
|
|
7736
7737
|
return /* @__PURE__ */ U(jn.Fallback, {
|
|
7737
7738
|
"data-slot": "avatar-fallback",
|
|
7738
|
-
className:
|
|
7739
|
+
className: P("flex size-full items-center justify-center rounded-full bg-muted", e),
|
|
7739
7740
|
...t
|
|
7740
7741
|
});
|
|
7741
7742
|
}
|
|
7742
7743
|
function Yc({ className: e, ...t }) {
|
|
7743
7744
|
return /* @__PURE__ */ U("span", {
|
|
7744
7745
|
"data-slot": "avatar-badge",
|
|
7745
|
-
className:
|
|
7746
|
+
className: P("absolute right-0 bottom-0 z-10 inline-flex select-none items-center justify-center rounded-full bg-primary text-primary-foreground ring-2 ring-background", "group-data-[size=sm]/avatar:size-2 group-data-[size=sm]/avatar:[&>svg]:hidden", "group-data-[size=default]/avatar:size-2.5 group-data-[size=default]/avatar:[&>svg]:size-2", "group-data-[size=lg]/avatar:size-3 group-data-[size=lg]/avatar:[&>svg]:size-2", e),
|
|
7746
7747
|
...t
|
|
7747
7748
|
});
|
|
7748
7749
|
}
|
|
7749
7750
|
function Xc({ className: e, ...t }) {
|
|
7750
7751
|
return /* @__PURE__ */ U("div", {
|
|
7751
7752
|
"data-slot": "avatar-group",
|
|
7752
|
-
className:
|
|
7753
|
+
className: P("group/avatar-group flex -space-x-2 *:data-[slot=avatar]:ring-2 *:data-[slot=avatar]:ring-background", e),
|
|
7753
7754
|
...t
|
|
7754
7755
|
});
|
|
7755
7756
|
}
|
|
7756
7757
|
function Zc({ className: e, ...t }) {
|
|
7757
7758
|
return /* @__PURE__ */ U("div", {
|
|
7758
7759
|
"data-slot": "avatar-group-count",
|
|
7759
|
-
className:
|
|
7760
|
+
className: P("relative flex size-8 shrink-0 items-center justify-center rounded-full bg-muted text-muted-foreground text-sm ring-2 ring-background group-has-data-[size=lg]/avatar-group:size-10 group-has-data-[size=sm]/avatar-group:size-6 [&>svg]:size-4 group-has-data-[size=lg]/avatar-group:[&>svg]:size-5 group-has-data-[size=sm]/avatar-group:[&>svg]:size-3", e),
|
|
7760
7761
|
...t
|
|
7761
7762
|
});
|
|
7762
7763
|
}
|
|
@@ -7765,14 +7766,14 @@ function Zc({ className: e, ...t }) {
|
|
|
7765
7766
|
function Qc({ className: e, ...t }) {
|
|
7766
7767
|
return /* @__PURE__ */ U("kbd", {
|
|
7767
7768
|
"data-slot": "kbd",
|
|
7768
|
-
className:
|
|
7769
|
+
className: P("pointer-events-none inline-flex h-5 w-fit min-w-5 select-none items-center justify-center gap-1 rounded-sm bg-muted in-data-[slot=tooltip-content]:bg-background/20 px-1 font-medium font-sans in-data-[slot=tooltip-content]:text-background text-muted-foreground text-xs dark:in-data-[slot=tooltip-content]:bg-background/10 [&_svg:not([class*='size-'])]:size-3", e),
|
|
7769
7770
|
...t
|
|
7770
7771
|
});
|
|
7771
7772
|
}
|
|
7772
7773
|
function $c({ className: e, ...t }) {
|
|
7773
7774
|
return /* @__PURE__ */ U("kbd", {
|
|
7774
7775
|
"data-slot": "kbd-group",
|
|
7775
|
-
className:
|
|
7776
|
+
className: P("inline-flex items-center gap-1", e),
|
|
7776
7777
|
...t
|
|
7777
7778
|
});
|
|
7778
7779
|
}
|
|
@@ -7780,7 +7781,7 @@ function $c({ className: e, ...t }) {
|
|
|
7780
7781
|
//#region src/components/ui/Calendar.tsx
|
|
7781
7782
|
var el = ({ className: e, classNames: t, showOutsideDays: n = !0, captionLayout: r = "label", formatters: i, components: a, ...o }) => /* @__PURE__ */ U(Gn, {
|
|
7782
7783
|
showOutsideDays: n,
|
|
7783
|
-
className:
|
|
7784
|
+
className: P("group/calendar bg-background p-0 [--cell-size:--spacing(8)] [[data-slot=card-content]_&]:bg-transparent [[data-slot=popover-content]_&]:bg-transparent", String.raw`rtl:**:[.rdp-button\_next>svg]:rotate-180`, String.raw`rtl:**:[.rdp-button\_previous>svg]:rotate-180`, e),
|
|
7784
7785
|
captionLayout: r,
|
|
7785
7786
|
formatters: {
|
|
7786
7787
|
formatMonthDropdown: (e) => e.toLocaleString("default", { month: "short" }),
|
|
@@ -7797,7 +7798,7 @@ var el = ({ className: e, classNames: t, showOutsideDays: n = !0, captionLayout:
|
|
|
7797
7798
|
dropdowns: "w-full flex items-center text-sm font-medium justify-center h-(--cell-size) gap-1.5",
|
|
7798
7799
|
dropdown_root: "relative focus:border-ring border border-input shadow-xs focus:ring-ring/50 focus:ring-[3px] rounded-md",
|
|
7799
7800
|
dropdown: "absolute bg-popover inset-0 opacity-0",
|
|
7800
|
-
caption_label:
|
|
7801
|
+
caption_label: P("select-none font-medium", r === "label" ? "text-sm" : "flex h-8 items-center gap-1 rounded-md pr-1 pl-2 text-sm [&>svg]:size-3.5 [&>svg]:text-muted-foreground"),
|
|
7801
7802
|
month_grid: "w-full border-collapse",
|
|
7802
7803
|
weekdays: "flex",
|
|
7803
7804
|
weekday: "text-muted-foreground rounded-md flex-1 font-normal text-[0.8rem] select-none",
|
|
@@ -7823,7 +7824,7 @@ var el = ({ className: e, classNames: t, showOutsideDays: n = !0, captionLayout:
|
|
|
7823
7824
|
...n
|
|
7824
7825
|
}),
|
|
7825
7826
|
Chevron: ({ className: e, orientation: t, ...n }) => U(t === "left" ? an : t === "right" ? on : rn, {
|
|
7826
|
-
className:
|
|
7827
|
+
className: P("size-4", e),
|
|
7827
7828
|
...n
|
|
7828
7829
|
}),
|
|
7829
7830
|
WeekNumber: ({ children: e, ...t }) => /* @__PURE__ */ U("td", {
|
|
@@ -7842,13 +7843,13 @@ var el = ({ className: e, classNames: t, showOutsideDays: n = !0, captionLayout:
|
|
|
7842
7843
|
function tl({ className: e, ...t }) {
|
|
7843
7844
|
return /* @__PURE__ */ U("textarea", {
|
|
7844
7845
|
"data-slot": "textarea",
|
|
7845
|
-
className:
|
|
7846
|
+
className: P("field-sizing-content flex min-h-16 w-full rounded-md border border-input bg-transparent px-3 py-2 text-base shadow-xs outline-none transition-[color,box-shadow] placeholder:text-muted-foreground focus-visible:border-ring focus-visible:ring-[3px] focus-visible:ring-ring/50 disabled:cursor-not-allowed disabled:opacity-50 aria-invalid:border-destructive aria-invalid:ring-destructive/20 md:text-sm dark:bg-input/30 dark:aria-invalid:ring-destructive/40", e),
|
|
7846
7847
|
...t
|
|
7847
7848
|
});
|
|
7848
7849
|
}
|
|
7849
7850
|
//#endregion
|
|
7850
7851
|
//#region src/components/ui/form/FormTextarea.tsx
|
|
7851
|
-
var nl =
|
|
7852
|
+
var nl = Te.forwardRef(({ name: e, label: t, isRequired: n, labelStyles: r, containerStyles: i, disabled: a, placeholder: o, readOnly: s, textAreaProps: c, textAreaStyles: l, value: u, id: d, onBlur: f, onChange: p, error: m, helperText: h, touched: g }, _) => /* @__PURE__ */ W(Es, {
|
|
7852
7853
|
containerStyles: i,
|
|
7853
7854
|
error: m,
|
|
7854
7855
|
helperText: h,
|
|
@@ -7862,7 +7863,7 @@ var nl = Ee.forwardRef(({ name: e, label: t, isRequired: n, labelStyles: r, cont
|
|
|
7862
7863
|
}), /* @__PURE__ */ U(tl, {
|
|
7863
7864
|
id: d || e,
|
|
7864
7865
|
name: e,
|
|
7865
|
-
className:
|
|
7866
|
+
className: P(s && "focus-visible:ring-0", l),
|
|
7866
7867
|
ref: _,
|
|
7867
7868
|
onChange: p,
|
|
7868
7869
|
onBlur: f,
|
|
@@ -7974,7 +7975,7 @@ var rl = {
|
|
|
7974
7975
|
})]
|
|
7975
7976
|
})
|
|
7976
7977
|
}), sl = ({ isOpen: e, handleGlobalSearchDialogOpen: t }) => {
|
|
7977
|
-
let n =
|
|
7978
|
+
let n = F(), [r, i] = V(""), [a, o] = V([]), [s, c] = V(!1), [l, u] = V(null), [d, f] = V(!1), p = Kn(Me(async (e) => {
|
|
7978
7979
|
try {
|
|
7979
7980
|
let t = await n.fetch.url("/v1/builder/search").query({
|
|
7980
7981
|
q: e,
|
|
@@ -7987,17 +7988,17 @@ var rl = {
|
|
|
7987
7988
|
} finally {
|
|
7988
7989
|
c(!1);
|
|
7989
7990
|
}
|
|
7990
|
-
}, [n]), 600), m =
|
|
7991
|
+
}, [n]), 600), m = Me((e) => {
|
|
7991
7992
|
if (i(e), e.length < 2) {
|
|
7992
7993
|
p.cancel(), o([]), c(!1), u(null), e.length === 0 && f(!1);
|
|
7993
7994
|
return;
|
|
7994
7995
|
}
|
|
7995
7996
|
c(!0), u(null), p(e);
|
|
7996
7997
|
}, [p]);
|
|
7997
|
-
return /* @__PURE__ */ U(
|
|
7998
|
+
return /* @__PURE__ */ U(oe, {
|
|
7998
7999
|
open: e,
|
|
7999
8000
|
onOpenChange: t,
|
|
8000
|
-
children: /* @__PURE__ */ W(
|
|
8001
|
+
children: /* @__PURE__ */ W(ne, {
|
|
8001
8002
|
className: "flex max-w-[22rem]! animate-none! flex-col sm:max-w-2xl!",
|
|
8002
8003
|
showCloseButton: !1,
|
|
8003
8004
|
style: {
|
|
@@ -8074,7 +8075,7 @@ var rl = {
|
|
|
8074
8075
|
};
|
|
8075
8076
|
return document.addEventListener("keydown", e), () => document.removeEventListener("keydown", e);
|
|
8076
8077
|
}, []);
|
|
8077
|
-
let i =
|
|
8078
|
+
let i = Me((e) => {
|
|
8078
8079
|
r(e);
|
|
8079
8080
|
}, []);
|
|
8080
8081
|
return /* @__PURE__ */ W(H, { children: [
|
|
@@ -8147,8 +8148,8 @@ var rl = {
|
|
|
8147
8148
|
...i,
|
|
8148
8149
|
unstyled: !0,
|
|
8149
8150
|
classNames: {
|
|
8150
|
-
container: () =>
|
|
8151
|
-
control: ({ isFocused: e, isMulti: t, isDisabled: n }) =>
|
|
8151
|
+
container: () => P("h-auto min-h-none w-full min-w-none"),
|
|
8152
|
+
control: ({ isFocused: e, isMulti: t, isDisabled: n }) => P("w-full pl-3", t ? "h-auto min-h-9!" : "!min-h-none h-9", "rounded-md border border-input bg-brand-foreground text-brand text-sm shadow-xs transition-[color,box-shadow] hover:cursor-pointer", "flex", e && "border-ring outline-none ring-[3px] ring-ring/50", o && "ring-0", n && "opacity-50", y),
|
|
8152
8153
|
input: () => "",
|
|
8153
8154
|
valueContainer: () => "gap-[4px] py-1",
|
|
8154
8155
|
singleValue: () => "",
|
|
@@ -8163,9 +8164,9 @@ var rl = {
|
|
|
8163
8164
|
menuPortal: () => "z-9999!",
|
|
8164
8165
|
groupHeading: () => "ml-3 mt-2 mb-1 text-gray-500 text-sm",
|
|
8165
8166
|
placeholder: () => "text-gray-500 pl-1 py-0.5",
|
|
8166
|
-
option: ({ isSelected: e, isFocused: t }) =>
|
|
8167
|
+
option: ({ isSelected: e, isFocused: t }) => P("rounded px-3 py-2 font-medium text-sm hover:cursor-pointer", t && "bg-brand-foreground text-brand", e && "bg-brand-foreground text-brand"),
|
|
8167
8168
|
noOptionsMessage: () => "text-gray-500 p-2 bg-gray-50 border border-dashed border-gray-200 rounded-sm",
|
|
8168
|
-
menuList: () =>
|
|
8169
|
+
menuList: () => P("space-y-1", b)
|
|
8169
8170
|
}
|
|
8170
8171
|
}),
|
|
8171
8172
|
x
|
|
@@ -8253,7 +8254,7 @@ var rl = {
|
|
|
8253
8254
|
let a = z(() => {
|
|
8254
8255
|
let t = e?.sections?.flatMap((e) => e?.fields)?.filter((e) => ml.includes(e?.field_interface))?.filter((e) => i?.includes(e?.key));
|
|
8255
8256
|
return r ? [hl, ...t] : t;
|
|
8256
|
-
}, [e?.sections, r]), o = z(() =>
|
|
8257
|
+
}, [e?.sections, r]), o = z(() => ue({
|
|
8257
8258
|
...e,
|
|
8258
8259
|
sections: e?.sections?.map((e) => ({
|
|
8259
8260
|
...e,
|
|
@@ -8432,14 +8433,14 @@ var rl = {
|
|
|
8432
8433
|
] }),
|
|
8433
8434
|
/* @__PURE__ */ W("div", {
|
|
8434
8435
|
className: "flex flex-col-reverse justify-end gap-4 md:flex-row",
|
|
8435
|
-
children: [/* @__PURE__ */ U(
|
|
8436
|
+
children: [/* @__PURE__ */ U(E, {
|
|
8436
8437
|
elementKey: "",
|
|
8437
8438
|
className: "rounded-lg bg-gray-100 px-6 py-2 font-semibold text-black hover:bg-gray-200",
|
|
8438
8439
|
type: "button",
|
|
8439
8440
|
onClick: a,
|
|
8440
8441
|
disabled: i,
|
|
8441
8442
|
children: "Back"
|
|
8442
|
-
}), /* @__PURE__ */ U(
|
|
8443
|
+
}), /* @__PURE__ */ U(E, {
|
|
8443
8444
|
elementKey: "",
|
|
8444
8445
|
className: "rounded-lg px-6 py-2 font-semibold",
|
|
8445
8446
|
type: "submit",
|
|
@@ -8499,7 +8500,7 @@ var rl = {
|
|
|
8499
8500
|
className: "mt-1 text-red-400 text-xs",
|
|
8500
8501
|
children: n
|
|
8501
8502
|
})]
|
|
8502
|
-
}), /* @__PURE__ */ U(
|
|
8503
|
+
}), /* @__PURE__ */ U(E, {
|
|
8503
8504
|
elementKey: "",
|
|
8504
8505
|
"aria-label": "Apply Coupon",
|
|
8505
8506
|
onClick: () => i(),
|
|
@@ -8760,7 +8761,7 @@ var rl = {
|
|
|
8760
8761
|
children: [/* @__PURE__ */ U("div", {
|
|
8761
8762
|
className: "flex w-full flex-col gap-3 md:w-[55%]",
|
|
8762
8763
|
children: e.map((e) => /* @__PURE__ */ U("div", {
|
|
8763
|
-
className:
|
|
8764
|
+
className: P("flex cursor-pointer items-center justify-between rounded-md border border-gray-300 px-3 py-2 transition duration-300 hover:bg-gray-50", e._id === t?._id ? "border-brand border-l-2 bg-brand/10 hover:bg-brand/20" : ""),
|
|
8764
8765
|
onClick: () => n(e),
|
|
8765
8766
|
children: /* @__PURE__ */ W("div", {
|
|
8766
8767
|
className: `${e._id === t?._id ? "-ml-[2px]" : "ml-0"}`,
|
|
@@ -9039,7 +9040,7 @@ var rl = {
|
|
|
9039
9040
|
})]
|
|
9040
9041
|
})
|
|
9041
9042
|
}) : /* @__PURE__ */ W("div", {
|
|
9042
|
-
className:
|
|
9043
|
+
className: P("flex cursor-pointer items-center justify-between border-b border-b-gray-300 pr-1 pl-4 transition-all duration-200 hover:bg-gray-50", t ? "h-[50px] py-3" : "py-3"),
|
|
9043
9044
|
onClick: () => t ? o() : null,
|
|
9044
9045
|
children: [/* @__PURE__ */ W("span", {
|
|
9045
9046
|
className: "flex items-center gap-2",
|
|
@@ -9052,7 +9053,7 @@ var rl = {
|
|
|
9052
9053
|
})]
|
|
9053
9054
|
}), /* @__PURE__ */ U("div", {
|
|
9054
9055
|
className: "mt-3 flex justify-start",
|
|
9055
|
-
children: /* @__PURE__ */ U(
|
|
9056
|
+
children: /* @__PURE__ */ U(E, {
|
|
9056
9057
|
elementKey: "",
|
|
9057
9058
|
onClick: c,
|
|
9058
9059
|
className: "rounded-lg px-6 py-2 font-semibold",
|
|
@@ -9097,18 +9098,18 @@ var Dl = async (e, t, n) => {
|
|
|
9097
9098
|
console.log(e);
|
|
9098
9099
|
}
|
|
9099
9100
|
}, Ol = ({ eventID: e, title: t, external: n, buttonText: r = "Register Now" }) => {
|
|
9100
|
-
let i =
|
|
9101
|
-
x(null), _(void 0),
|
|
9102
|
-
}, { Razorpay:
|
|
9103
|
-
let e =
|
|
9104
|
-
e && i?.fetch?.url(`/v1/event/booking/${e.bookingId}/confirm-booking`)?.options({ headers: { Origin:
|
|
9105
|
-
e?.content?.data && _(e?.content?.data),
|
|
9101
|
+
let i = F(), [a, o] = V([]), [s, c] = V(!0), { isOpen: l, onOpen: u, onClose: d } = El(), [f, p] = V(!1), [m, h] = V(null), [g, _] = V(void 0), [v, y] = V(""), [b, x] = V(null), [S, C] = V(!1), [w, T] = V(null), [D, O] = V(!1), [k, j] = V(1), [M, N] = V(null), [ee, te] = V([]), { workspace: ne } = A(), re = B(null), ie = () => {
|
|
9102
|
+
x(null), _(void 0), T(null), C(!1), y(""), N(null), d(), j(1), I();
|
|
9103
|
+
}, { Razorpay: ae } = Wn(), { stripePromise: oe, config: se, isOpen: ue, openStripeCheckout: de, closeStripeCheckout: fe, setOnComplete: pe } = ce(), me = () => {
|
|
9104
|
+
let e = re.current;
|
|
9105
|
+
e && i?.fetch?.url(`/v1/event/booking/${e.bookingId}/confirm-booking`)?.options({ headers: { Origin: ne?.id || "" } })?.post({ session_id: e.sessionId })?.json().then((e) => {
|
|
9106
|
+
e?.content?.data && _(e?.content?.data), fe(), re.current = null;
|
|
9106
9107
|
}).catch((e) => {
|
|
9107
|
-
console.error("Failed to confirm booking after Stripe payment:", e),
|
|
9108
|
+
console.error("Failed to confirm booking after Stripe payment:", e), we(e), fe(), re.current = null;
|
|
9108
9109
|
});
|
|
9109
|
-
},
|
|
9110
|
-
p(!0),
|
|
9111
|
-
let { name: t, email: n, is_business_purchase: r, billing_details: a, ...o } = { ...
|
|
9110
|
+
}, he = async () => {
|
|
9111
|
+
p(!0), N(null);
|
|
9112
|
+
let { name: t, email: n, is_business_purchase: r, billing_details: a, ...o } = { ...Se };
|
|
9112
9113
|
try {
|
|
9113
9114
|
let s = {
|
|
9114
9115
|
event: e,
|
|
@@ -9121,24 +9122,24 @@ var Dl = async (e, t, n) => {
|
|
|
9121
9122
|
}]
|
|
9122
9123
|
};
|
|
9123
9124
|
r && (s.is_business_purchase = !0, s.billing_details = a);
|
|
9124
|
-
let c = await i?.fetch?.url(`/v1/event/event/${e}/booking/create-new-booking`)?.options({ headers: { Origin:
|
|
9125
|
-
if (!c.status)
|
|
9125
|
+
let c = await i?.fetch?.url(`/v1/event/event/${e}/booking/create-new-booking`)?.options({ headers: { Origin: ne?.id || "" } })?.post(s).json();
|
|
9126
|
+
if (!c.status) N("Booking failed. Please try again.");
|
|
9126
9127
|
else {
|
|
9127
|
-
|
|
9128
|
+
ie();
|
|
9128
9129
|
let e = c?.content?.meta;
|
|
9129
9130
|
if (e?.key) {
|
|
9130
9131
|
let t = c?.content.data?._id;
|
|
9131
|
-
e.provider === "stripe" && e.client_secret ? (
|
|
9132
|
+
e.provider === "stripe" && e.client_secret ? (re.current = t && e.session_id ? {
|
|
9132
9133
|
bookingId: t,
|
|
9133
9134
|
sessionId: e.session_id
|
|
9134
|
-
} : null, me
|
|
9135
|
+
} : null, pe(me), await de({
|
|
9135
9136
|
key: e.key,
|
|
9136
9137
|
client_secret: e.client_secret,
|
|
9137
9138
|
amount: c?.content.data?.unit_amount || 0,
|
|
9138
9139
|
currency: e.currency || "USD",
|
|
9139
9140
|
provider: "stripe",
|
|
9140
9141
|
reference_id: e.reference_id || ""
|
|
9141
|
-
})) :
|
|
9142
|
+
})) : ge({
|
|
9142
9143
|
key: e.key,
|
|
9143
9144
|
amount: c?.content.data?.unit_amount,
|
|
9144
9145
|
currency: e.currency || "INR",
|
|
@@ -9148,19 +9149,19 @@ var Dl = async (e, t, n) => {
|
|
|
9148
9149
|
} else _(c?.content.data);
|
|
9149
9150
|
}
|
|
9150
9151
|
} catch (e) {
|
|
9151
|
-
|
|
9152
|
+
N(G(e).message || "Something went wrong. Please try again.");
|
|
9152
9153
|
}
|
|
9153
9154
|
p(!1);
|
|
9154
|
-
},
|
|
9155
|
-
let t = new
|
|
9155
|
+
}, ge = async (e) => {
|
|
9156
|
+
let t = new ae({
|
|
9156
9157
|
key: e.key,
|
|
9157
9158
|
amount: e.amount,
|
|
9158
9159
|
currency: e.currency,
|
|
9159
9160
|
order_id: e.order_id,
|
|
9160
|
-
name:
|
|
9161
|
+
name: ne?.name ?? "",
|
|
9161
9162
|
description: "Event Registration",
|
|
9162
9163
|
handler: (t) => {
|
|
9163
|
-
i?.fetch?.url(`/v1/event/booking/${e.booking_id}/confirm-booking`)?.options({ headers: { Origin:
|
|
9164
|
+
i?.fetch?.url(`/v1/event/booking/${e.booking_id}/confirm-booking`)?.options({ headers: { Origin: ne?.id || "" } })?.post({
|
|
9164
9165
|
order_id: t.razorpay_order_id,
|
|
9165
9166
|
payment_id: t.razorpay_payment_id,
|
|
9166
9167
|
signature: t.razorpay_signature
|
|
@@ -9178,18 +9179,18 @@ var Dl = async (e, t, n) => {
|
|
|
9178
9179
|
t.on("payment.failed", (e) => {
|
|
9179
9180
|
console.log(e.error.code, e.error.description, e.error.source, e.error.step, e.error.reason, e.error.metadata.order_id, e.error.metadata.payment_id);
|
|
9180
9181
|
}), t.open();
|
|
9181
|
-
},
|
|
9182
|
+
}, _e = async () => {
|
|
9182
9183
|
try {
|
|
9183
|
-
let t = await i?.fetch?.url(`/v1/event/event/${e}/coupon/list-public-coupons`)?.options({ headers: { Origin:
|
|
9184
|
-
t?.status && t?.content?.data &&
|
|
9184
|
+
let t = await i?.fetch?.url(`/v1/event/event/${e}/coupon/list-public-coupons`)?.options({ headers: { Origin: ne?.id || "" } })?.get().json();
|
|
9185
|
+
t?.status && t?.content?.data && te(t.content.data);
|
|
9185
9186
|
} catch (e) {
|
|
9186
9187
|
i?.logger?.error("Failed to fetch public coupons", { exception: G(e) });
|
|
9187
9188
|
}
|
|
9188
|
-
},
|
|
9189
|
+
}, ve = async (t) => {
|
|
9189
9190
|
let n = t ?? v;
|
|
9190
|
-
C(!0),
|
|
9191
|
+
C(!0), T(null);
|
|
9191
9192
|
try {
|
|
9192
|
-
let t = await i?.fetch?.url(`/v1/event/event/${e}/coupon/validate-coupon-code`)?.options({ headers: { Origin:
|
|
9193
|
+
let t = await i?.fetch?.url(`/v1/event/event/${e}/coupon/validate-coupon-code`)?.options({ headers: { Origin: ne?.id || "" } })?.post({
|
|
9193
9194
|
coupon: n,
|
|
9194
9195
|
event: e,
|
|
9195
9196
|
attendees: [{
|
|
@@ -9200,29 +9201,29 @@ var Dl = async (e, t, n) => {
|
|
|
9200
9201
|
}).json();
|
|
9201
9202
|
t.status && (x(t.content.data), y(n)), O(!1), C(!1);
|
|
9202
9203
|
} catch (e) {
|
|
9203
|
-
|
|
9204
|
+
T(G(e).message), C(!1);
|
|
9204
9205
|
}
|
|
9205
|
-
},
|
|
9206
|
-
y(""), x(null),
|
|
9206
|
+
}, ye = (e) => {
|
|
9207
|
+
y(""), x(null), T(null), C(!1), N(null), h(e);
|
|
9208
|
+
}, be = () => {
|
|
9209
|
+
x(null), T(null), y("");
|
|
9207
9210
|
}, xe = () => {
|
|
9208
|
-
|
|
9209
|
-
}, Se = () => {
|
|
9210
|
-
E(null), C(!1), y(""), O(!1);
|
|
9211
|
+
T(null), C(!1), y(""), O(!1);
|
|
9211
9212
|
};
|
|
9212
9213
|
R(() => {
|
|
9213
9214
|
if (n) {
|
|
9214
9215
|
c(!1);
|
|
9215
9216
|
return;
|
|
9216
9217
|
}
|
|
9217
|
-
e && (c(!0), Dl(i, e,
|
|
9218
|
+
e && (c(!0), Dl(i, e, ne?.id ?? "")?.then((e) => {
|
|
9218
9219
|
o(e), e && e.length > 0 && h(e[0] || null), c(!1);
|
|
9219
9220
|
}));
|
|
9220
9221
|
}, [e, n]), R(() => {
|
|
9221
9222
|
m?.unit_amount === 0 && a?.length === 1 && j(2);
|
|
9222
9223
|
}, [m, l]), R(() => {
|
|
9223
|
-
l && e &&
|
|
9224
|
+
l && e && _e();
|
|
9224
9225
|
}, [l, e]);
|
|
9225
|
-
let { values:
|
|
9226
|
+
let { values: Se, handleBlur: Ce, handleSubmit: Te, resetForm: I, setFieldValue: Ee } = Jn({
|
|
9226
9227
|
initialValues: {
|
|
9227
9228
|
name: "",
|
|
9228
9229
|
email: "",
|
|
@@ -9241,16 +9242,16 @@ var Dl = async (e, t, n) => {
|
|
|
9241
9242
|
}
|
|
9242
9243
|
},
|
|
9243
9244
|
onSubmit: () => {
|
|
9244
|
-
|
|
9245
|
+
he();
|
|
9245
9246
|
},
|
|
9246
9247
|
enableReinitialize: !0
|
|
9247
|
-
}),
|
|
9248
|
+
}), De = (e) => {
|
|
9248
9249
|
let { name: t, value: n, type: r, checked: i } = e.target;
|
|
9249
|
-
r === "checkbox" ?
|
|
9250
|
+
r === "checkbox" ? Ee(t, i) : Ee(t, n);
|
|
9250
9251
|
};
|
|
9251
9252
|
if (n) return /* @__PURE__ */ U("div", {
|
|
9252
9253
|
className: "my-2",
|
|
9253
|
-
children: /* @__PURE__ */ U(
|
|
9254
|
+
children: /* @__PURE__ */ U(E, {
|
|
9254
9255
|
elementKey: "",
|
|
9255
9256
|
className: "rounded-lg px-4 py-3 font-semibold",
|
|
9256
9257
|
onClick: () => window.open(n, "_blank", "noopener,noreferrer"),
|
|
@@ -9259,17 +9260,17 @@ var Dl = async (e, t, n) => {
|
|
|
9259
9260
|
});
|
|
9260
9261
|
if (s) return /* @__PURE__ */ U("div", {
|
|
9261
9262
|
className: "my-2",
|
|
9262
|
-
children: /* @__PURE__ */ U(
|
|
9263
|
+
children: /* @__PURE__ */ U(E, {
|
|
9263
9264
|
elementKey: "",
|
|
9264
9265
|
className: "rounded-lg px-4 py-2 font-bold",
|
|
9265
9266
|
children: "Loading..."
|
|
9266
9267
|
})
|
|
9267
9268
|
});
|
|
9268
|
-
let
|
|
9269
|
+
let Oe = b?.sale_amount === 0 || m?.unit_amount === 0 ? "Complete Registration" : "Pay";
|
|
9269
9270
|
return /* @__PURE__ */ W(H, { children: [
|
|
9270
9271
|
/* @__PURE__ */ U("div", {
|
|
9271
9272
|
className: "my-2",
|
|
9272
|
-
children: a?.length ? /* @__PURE__ */ U(
|
|
9273
|
+
children: a?.length ? /* @__PURE__ */ U(E, {
|
|
9273
9274
|
elementKey: "",
|
|
9274
9275
|
onClick: u,
|
|
9275
9276
|
className: "rounded-lg px-4 py-3 font-semibold",
|
|
@@ -9282,7 +9283,7 @@ var Dl = async (e, t, n) => {
|
|
|
9282
9283
|
/* @__PURE__ */ U(Nn.Root, { children: l && /* @__PURE__ */ U("div", {
|
|
9283
9284
|
className: "fixed inset-0 z-100 flex justify-center bg-black/50 pt-24",
|
|
9284
9285
|
children: /* @__PURE__ */ W("div", {
|
|
9285
|
-
className:
|
|
9286
|
+
className: P("flex h-fit max-w-[90%] flex-col rounded-lg bg-white p-4 md:w-[40%]", D ? "md:max-w-[30%]" : "md:max-w-[40%]"),
|
|
9286
9287
|
children: [/* @__PURE__ */ W("div", {
|
|
9287
9288
|
className: `mb-4 flex w-full items-start justify-between ${D ? "" : "pb-[6px]"} `,
|
|
9288
9289
|
children: [/* @__PURE__ */ W("h2", {
|
|
@@ -9294,40 +9295,40 @@ var Dl = async (e, t, n) => {
|
|
|
9294
9295
|
]
|
|
9295
9296
|
}), /* @__PURE__ */ U("button", {
|
|
9296
9297
|
type: "button",
|
|
9297
|
-
onClick:
|
|
9298
|
+
onClick: ie,
|
|
9298
9299
|
className: "rounded-md p-2 hover:bg-gray-100 focus:outline-none",
|
|
9299
9300
|
children: /* @__PURE__ */ U(kn, { className: "size-4" })
|
|
9300
9301
|
})]
|
|
9301
|
-
}), /* @__PURE__ */ W("div", { children: [
|
|
9302
|
+
}), /* @__PURE__ */ W("div", { children: [M && /* @__PURE__ */ U("div", {
|
|
9302
9303
|
className: "mb-4 rounded-md bg-red-50 p-3 text-red-600 text-sm",
|
|
9303
|
-
children:
|
|
9304
|
-
}),
|
|
9304
|
+
children: M
|
|
9305
|
+
}), k === 1 ? /* @__PURE__ */ U("div", { children: D ? /* @__PURE__ */ U(Cl, {
|
|
9305
9306
|
couponCode: v,
|
|
9306
9307
|
onCouponCodeChange: y,
|
|
9307
9308
|
couponError: w,
|
|
9308
9309
|
couponLoading: S,
|
|
9309
|
-
onValidateCoupon:
|
|
9310
|
-
publicCoupons:
|
|
9311
|
-
onBack:
|
|
9310
|
+
onValidateCoupon: ve,
|
|
9311
|
+
publicCoupons: ee,
|
|
9312
|
+
onBack: xe,
|
|
9312
9313
|
selectedTicket: m
|
|
9313
9314
|
}) : /* @__PURE__ */ U(Tl, {
|
|
9314
9315
|
tickets: a,
|
|
9315
9316
|
selectedTicket: m,
|
|
9316
|
-
onSelectTicket:
|
|
9317
|
+
onSelectTicket: ye,
|
|
9317
9318
|
discount: b,
|
|
9318
9319
|
couponCode: v,
|
|
9319
|
-
publicCouponsCount:
|
|
9320
|
+
publicCouponsCount: ee.length,
|
|
9320
9321
|
onApplyCouponClick: () => O(!0),
|
|
9321
|
-
onRemoveCoupon:
|
|
9322
|
+
onRemoveCoupon: be,
|
|
9322
9323
|
onNext: () => j(2)
|
|
9323
9324
|
}) }) : /* @__PURE__ */ U(_l, {
|
|
9324
|
-
values:
|
|
9325
|
-
handleChange:
|
|
9326
|
-
handleBlur:
|
|
9327
|
-
handleSubmit:
|
|
9325
|
+
values: Se,
|
|
9326
|
+
handleChange: De,
|
|
9327
|
+
handleBlur: Ce,
|
|
9328
|
+
handleSubmit: Te,
|
|
9328
9329
|
registerLoading: f,
|
|
9329
9330
|
onBack: () => j(1),
|
|
9330
|
-
submitLabel:
|
|
9331
|
+
submitLabel: Oe
|
|
9331
9332
|
})] })]
|
|
9332
9333
|
})
|
|
9333
9334
|
}) }),
|
|
@@ -9336,12 +9337,12 @@ var Dl = async (e, t, n) => {
|
|
|
9336
9337
|
ticketData: a,
|
|
9337
9338
|
type: "confirm"
|
|
9338
9339
|
}),
|
|
9339
|
-
|
|
9340
|
-
isOpen:
|
|
9341
|
-
onClose:
|
|
9342
|
-
stripePromise:
|
|
9343
|
-
clientSecret:
|
|
9344
|
-
onComplete:
|
|
9340
|
+
ue && se && /* @__PURE__ */ U(le, {
|
|
9341
|
+
isOpen: ue,
|
|
9342
|
+
onClose: fe,
|
|
9343
|
+
stripePromise: oe,
|
|
9344
|
+
clientSecret: se.clientSecret,
|
|
9345
|
+
onComplete: me
|
|
9345
9346
|
})
|
|
9346
9347
|
] });
|
|
9347
9348
|
}, kl = ({ blockInstance: e, blocks: t, theme: n }) => {
|
|
@@ -9374,7 +9375,7 @@ var Dl = async (e, t, n) => {
|
|
|
9374
9375
|
let e = JSON.stringify(t, null, 2);
|
|
9375
9376
|
e !== c.current && (c.current = e, i(e), o(null));
|
|
9376
9377
|
}, [t]);
|
|
9377
|
-
let l =
|
|
9378
|
+
let l = Me((e) => {
|
|
9378
9379
|
let t = e.target.value;
|
|
9379
9380
|
i(t), s.current && clearTimeout(s.current), s.current = setTimeout(() => {
|
|
9380
9381
|
try {
|
|
@@ -9493,12 +9494,12 @@ var Dl = async (e, t, n) => {
|
|
|
9493
9494
|
e.key,
|
|
9494
9495
|
e.version,
|
|
9495
9496
|
t
|
|
9496
|
-
]), y =
|
|
9497
|
+
]), y = Me((t) => {
|
|
9497
9498
|
let n = Number(t.target.value);
|
|
9498
9499
|
a(n);
|
|
9499
9500
|
let r = Ml(e, n);
|
|
9500
9501
|
f(r.content), m(r.styles), g(r.config);
|
|
9501
|
-
}, [e]), b =
|
|
9502
|
+
}, [e]), b = Me(() => {
|
|
9502
9503
|
let t = Ml(e, i);
|
|
9503
9504
|
f(t.content), m(t.styles), g(t.config);
|
|
9504
9505
|
}, [e, i]);
|
|
@@ -9784,4 +9785,4 @@ var Dl = async (e, t, n) => {
|
|
|
9784
9785
|
"password"
|
|
9785
9786
|
];
|
|
9786
9787
|
//#endregion
|
|
9787
|
-
export {
|
|
9788
|
+
export { ye as ALTERNATE_METHOD_VALUES, he as ALTERNATIVE_AUTH_METHODS, Ja as AccordionContent, Ka as AccordionItem, Ga as AccordionRoot, qa as AccordionTrigger, j as AuthProvider, _e as AuthenticationOptions, Wc as Avatar, Yc as AvatarBadge, qc as AvatarFallback, Jc as AvatarFallbackV2, Xc as AvatarGroup, Zc as AvatarGroupCount, Gc as AvatarImage, Kc as AvatarImageV2, lc as BUILT_IN_PRESETS, Ec as BackgroundEffects, ho as BaseBlogContent, E as BaseButton, jo as BaseContainer, $s as BaseHeading, Dc as BaseSection, Lc as BaseTypography, zc as BaseUserMenu, O as BlockProvider, Zl as BlockSourceModuleList, _a as BlocksRegistry, go as BlogContent, Vc as BookingConfirmation, Uc as BookingModal, Hc as BookingSummary, yo as Box, x as Button, el as Calendar, Ao as Carousel, wo as CarouselContent, Oo as CarouselDotButton, ko as CarouselDots, To as CarouselItem, Do as CarouselNext, Eo as CarouselPrevious, zo as CategoryFilter, xs as CommentStatusBadge, zs as Comments, Js as CommentsRestrictionOverlay, Mo as Container, Vs as CreateForumPost, q as DATA_ATTRIBUTES, b as DEFAULT_FROM_STATE, zi as DEFAULT_THEME, _ as DEFAULT_TRANSITION, g as DEFAULT_VIEWPORT, u as DEFAULT_VISIBLE_STATE, d as DEMO_SCHEMA, Pl as DevTools, kl as DevToolsPreview, Po as EditForm, Ro as Form, Ds as FormInput, nl as FormTextarea, Ws as ForumPost, Vo as ForumProvider, cl as GlobalSearch, ec as Heading, Ql as IMembershipAuthenticationMethods, w as Icon, nc as Iframe, ic as Image, Ss as Input, gl as IntegrationFilters, Ks as JoinRequestForm, jl as JsonEditor, Qc as Kbd, $c as KbdGroup, Jl as KindList, da as LazyMotionProvider, ba as LevoBlock, ja as LevoPage, oc as Link, J as MESSAGE_TYPES, Ca as MadeWithLevo, cc as Media, pe as PENDING_APPROVAL_ERROR_CODE, uc as PRESET_CATEGORIES, dc as PRESET_MAP, de as PRIMARY_AUTH_METHODS, ge as PRIMARY_METHOD_VALUES, Ys as PendingRequestState, ts as PopoverContent, Zo as PopoverRoot, es as PopoverTrigger, f as PopupLoader, us as PostActions, as as PostCategory, ss as PostContent, fs as PostGallery, is as PostHeader, ds as PostLink, Gs as PostLinkWrapper, _s as PostPoll, ys as PostStatusBadge, os as PostTitle, Zs as PostsRestrictionOverlay, oi as PreviewHighlighter, Ol as RegisterModal, qs as SampleCommentSkeleton, Xs as SamplePostSkeleton, Qs as SearchInput, Oc as Section, Jo as SimpleTooltipWrapper, Z as Skeleton, cs as StatContainer, za as StudioPreview, Yl as StudioWidgetList, Xl as StudioWidgetMap, Fc as TabsContent, Nc as TabsList, kc as TabsRoot, Pc as TabsTrigger, Wo as Tooltip, qo as TooltipContent, Ko as TooltipPortal, Uo as TooltipProvider, Go as TooltipTrigger, Rc as Typography, Bc as UserMenu, va as blocksRegistry, xi as colorOptions, po as convertHtmlToJSON, kr as convertKeysToPascalCase, Di as cssOptionsMap, ta as fetchCollectionSchema, ea as fetchSource, C as findFieldSchema, yi as generateAccentColor, si as generateBodyContent, Mr as generateDefaultContent, wr as generateSchemaFromJSX, Ki as generateThemeStyles, Ui as generateThemeVariables, S as generateVariantClasses, pc as getAvailableCategories, gc as getEffectConfigFromPresetId, la as getInitialPageContent, T as getNestedValue, ua as getPageData, oa as getPageSource, fc as getPresetsByCategory, vi as getWcagContrast, mi as hexToOKLCH, ve as isAlternateMethod, p as isConfigWithVariants, fe as isPendingApprovalError, me as isPrimaryMethod, pi as isValidOKLCH, Vi as normalizeColorName, Hi as normalizeFontName, fi as oklchStringToRGBA, _i as oklchToHex, gi as oklchToRGBA, Y as oklchToString, y as parseGroupContext, hi as parseOKLCHString, sa as parseVariablesFromResolvedSource, Bi as processFonts, qi as processTheme, aa as resolveStyles, ia as resolveVariables, ui as rgbaToOKLCH, di as rgbaToOKLCHString, vc as sanitizeBackgroundEffectConfig, D as sanitizeElementKey, Ml as schemaToBlockInstance, A as useAuth, k as useBlockContext, m as useCommonProps, fa as useContentEngine, pa as useContextEngine, So as useDotButton, Ho as useForumContext, h as useGeneratedClassName, se as useLogin, ma as usePageContext, ha as usePageMeta, ce as useStripePayment };
|