@cntrl-site/components 1.0.17-3 → 1.0.17-4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.js +9 -1
- package/dist/index.mjs +194 -182
- package/package.json +1 -1
package/dist/index.mjs
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { jsx as l, Fragment as Ge, jsxs as
|
|
2
|
-
import en, { useState as de, useEffect as
|
|
1
|
+
import { jsx as l, Fragment as Ge, jsxs as oe } from "react/jsx-runtime";
|
|
2
|
+
import en, { useState as de, useEffect as Ae, useRef as Te, useCallback as ft, useMemo as He, useLayoutEffect as yt } from "react";
|
|
3
3
|
import Fe from "classnames";
|
|
4
4
|
import { s as L, u as an, b as Jn, g as Lr, r as zi } from "./readTestimonialTextMeasure-B1FI-93F.mjs";
|
|
5
5
|
import { createPortal as Vi } from "react-dom";
|
|
@@ -1853,7 +1853,7 @@ const Bl = "SvgImage-module__svg___q3xE-", Dl = "SvgImage-module__img___VsTm-",
|
|
|
1853
1853
|
return t.startsWith("data:image/svg+xml") ? !0 : (t.split(/[?#]/)[0] ?? t).endsWith(".svg");
|
|
1854
1854
|
}, Vl = (e) => `url("${e.replace(/\\/g, "\\\\").replace(/"/g, '\\"')}")`, qt = ({ url: e, fill: t = "#000000", hoverFill: n = "#CCCCCC", className: r = "", style: i }) => {
|
|
1855
1855
|
const [s, o] = de(() => typeof window > "u" ? !0 : CSS.supports("mask-image", 'url("")') || CSS.supports("-webkit-mask-image", 'url("")'));
|
|
1856
|
-
return
|
|
1856
|
+
return Ae(() => {
|
|
1857
1857
|
if (typeof window < "u" && window.CSS) {
|
|
1858
1858
|
const c = CSS.supports("mask-image", 'url("")') || CSS.supports("-webkit-mask-image", 'url("")');
|
|
1859
1859
|
o(c);
|
|
@@ -1886,7 +1886,7 @@ function jl({ settings: e, content: t, styles: n, isEditor: r }) {
|
|
|
1886
1886
|
const [i, s] = de(null), { widthSettings: o, fontSettings: c, letterSpacing: a, textAlign: u, wordSpacing: d, fontSizeLineHeight: w, textAppearance: v, color: h } = n.imageCaption ?? {}, [p, m] = de(void 0), [b, $] = de(null), [x, f] = de(0), [F, S] = de(0), { direction: M, transition: y, controls: T, pagination: O, imageCaption: C, triggers: P } = e, _ = Te(y.type), { x: W, y: V } = e.controls.offset, ee = (k) => {
|
|
1887
1887
|
i && i.go(k);
|
|
1888
1888
|
};
|
|
1889
|
-
return
|
|
1889
|
+
return Ae(() => {
|
|
1890
1890
|
if (!b) return;
|
|
1891
1891
|
const k = new ResizeObserver((R) => {
|
|
1892
1892
|
if (!i) return;
|
|
@@ -1897,9 +1897,9 @@ function jl({ settings: e, content: t, styles: n, isEditor: r }) {
|
|
|
1897
1897
|
});
|
|
1898
1898
|
});
|
|
1899
1899
|
return k.observe(b), () => k.unobserve(b);
|
|
1900
|
-
}, [b]),
|
|
1900
|
+
}, [b]), Ae(() => {
|
|
1901
1901
|
!i || _.current === y.type || (S((k) => k + 1), _.current = y.type);
|
|
1902
|
-
}, [y.type]), /* @__PURE__ */ l("div", { className: Fe(ue.wrapper, { [ue.editor]: r }), ref: $, children: /* @__PURE__ */
|
|
1902
|
+
}, [y.type]), /* @__PURE__ */ l("div", { className: Fe(ue.wrapper, { [ue.editor]: r }), ref: $, children: /* @__PURE__ */ oe(
|
|
1903
1903
|
"div",
|
|
1904
1904
|
{
|
|
1905
1905
|
className: ue.sliderInner,
|
|
@@ -2011,7 +2011,7 @@ function jl({ settings: e, content: t, styles: n, isEditor: r }) {
|
|
|
2011
2011
|
},
|
|
2012
2012
|
F
|
|
2013
2013
|
),
|
|
2014
|
-
T.isActive && /* @__PURE__ */
|
|
2014
|
+
T.isActive && /* @__PURE__ */ oe(Ge, { children: [
|
|
2015
2015
|
/* @__PURE__ */ l(
|
|
2016
2016
|
"div",
|
|
2017
2017
|
{
|
|
@@ -2023,7 +2023,7 @@ function jl({ settings: e, content: t, styles: n, isEditor: r }) {
|
|
|
2023
2023
|
color: T.color,
|
|
2024
2024
|
"--arrow-hover-color": T.hover
|
|
2025
2025
|
},
|
|
2026
|
-
children: /* @__PURE__ */
|
|
2026
|
+
children: /* @__PURE__ */ oe(
|
|
2027
2027
|
"button",
|
|
2028
2028
|
{
|
|
2029
2029
|
onClick: () => {
|
|
@@ -2060,7 +2060,7 @@ function jl({ settings: e, content: t, styles: n, isEditor: r }) {
|
|
|
2060
2060
|
color: T.color,
|
|
2061
2061
|
"--arrow-hover-color": T.hover
|
|
2062
2062
|
},
|
|
2063
|
-
children: /* @__PURE__ */
|
|
2063
|
+
children: /* @__PURE__ */ oe(
|
|
2064
2064
|
"button",
|
|
2065
2065
|
{
|
|
2066
2066
|
className: ue.arrowInner,
|
|
@@ -2804,7 +2804,7 @@ async function Ql(e, t, n, r) {
|
|
|
2804
2804
|
}
|
|
2805
2805
|
function Zl({ settings: e, content: t, isEditor: n }) {
|
|
2806
2806
|
const [r, i] = de(null), [s, o] = de([]), [c, a] = de(0), u = Te(0), [d, w] = de({ x: 0, y: 0 }), [v, h] = de(1), [p, m] = de("none"), b = Te({ x: 0, y: 0 }), [$, x] = de(!1), { sizeType: f, imageWidth: F, randomRangeImageWidth: S } = e.imageSize, { revealPosition: M, visible: y } = e.position, { cursorType: T, target: O, defaultCursorScale: C, defaultCursor: P, hoverCursorScale: _, hoverCursor: W } = e.cursor;
|
|
2807
|
-
|
|
2807
|
+
Ae(() => {
|
|
2808
2808
|
if (!r) return;
|
|
2809
2809
|
const k = (N, A) => {
|
|
2810
2810
|
const j = r.getBoundingClientRect(), X = N - j.left, Q = A - j.top;
|
|
@@ -2838,7 +2838,7 @@ function Zl({ settings: e, content: t, isEditor: n }) {
|
|
|
2838
2838
|
_,
|
|
2839
2839
|
C,
|
|
2840
2840
|
s
|
|
2841
|
-
]),
|
|
2841
|
+
]), Ae(() => {
|
|
2842
2842
|
$ || (m("none"), h(0));
|
|
2843
2843
|
}, [$]);
|
|
2844
2844
|
const V = async (k, R, D, N = {}) => {
|
|
@@ -2861,16 +2861,16 @@ function Zl({ settings: e, content: t, isEditor: n }) {
|
|
|
2861
2861
|
width: X
|
|
2862
2862
|
};
|
|
2863
2863
|
};
|
|
2864
|
-
return
|
|
2864
|
+
return Ae(() => {
|
|
2865
2865
|
if (!r || t.length === 0) return;
|
|
2866
2866
|
const k = r.getBoundingClientRect(), R = k.width, D = k.height, N = [];
|
|
2867
2867
|
(async () => {
|
|
2868
2868
|
const j = t[0], X = await V(j, R, D);
|
|
2869
2869
|
N.push(X), o(N), a(1);
|
|
2870
2870
|
})();
|
|
2871
|
-
}, [f, F, S, M, r]),
|
|
2871
|
+
}, [f, F, S, M, r]), Ae(() => {
|
|
2872
2872
|
y === "last One" && o((k) => k.length > 0 ? [k[k.length - 1]] : []);
|
|
2873
|
-
}, [y]), /* @__PURE__ */
|
|
2873
|
+
}, [y]), /* @__PURE__ */ oe(
|
|
2874
2874
|
"div",
|
|
2875
2875
|
{
|
|
2876
2876
|
ref: i,
|
|
@@ -3421,9 +3421,9 @@ function Hc(e, t) {
|
|
|
3421
3421
|
}
|
|
3422
3422
|
const Oc = ({ settings: e, content: t, styles: n, portalId: r, activeEvent: i, isEditor: s, isPreviewMode: o }) => {
|
|
3423
3423
|
const [c, a] = de(!1), { url: u } = e.thumbnailBlock.cover;
|
|
3424
|
-
return
|
|
3424
|
+
return Ae(() => {
|
|
3425
3425
|
i === "close" && a(!1), i === "open" && a(!0);
|
|
3426
|
-
}, [i]), /* @__PURE__ */
|
|
3426
|
+
}, [i]), /* @__PURE__ */ oe(Ge, { children: [
|
|
3427
3427
|
/* @__PURE__ */ l(
|
|
3428
3428
|
"img",
|
|
3429
3429
|
{
|
|
@@ -3447,48 +3447,48 @@ const Oc = ({ settings: e, content: t, styles: n, portalId: r, activeEvent: i, i
|
|
|
3447
3447
|
)
|
|
3448
3448
|
] });
|
|
3449
3449
|
}, Bc = ({ isOpen: e, onClose: t, content: n, lightboxStyles: r, settings: i, portalId: s, isEditor: o, metadata: c }) => {
|
|
3450
|
-
var
|
|
3450
|
+
var Ie;
|
|
3451
3451
|
const { widthSettings: a, fontSettings: u, letterSpacing: d, textAlign: w, wordSpacing: v, fontSizeLineHeight: h, textAppearance: p, color: m } = r.imageCaption ?? {}, [b, $] = de(0), [x, f] = de(0), [F, S] = de(!1), [M, y] = de(!1), [T, O] = de({}), C = Te(null), P = Te(null), _ = Te(null), W = Te(!1), V = Te(null), ee = Te(null), k = Te(null), R = Te(null), D = Te(!1), N = Te(null), [A, j] = de(!1), { appear: X, triggers: Q, slider: I, thumbnail: te, controls: g, area: J, caption: he, layout: le } = i.lightboxBlock, { appearClass: xe, backdropAppearClass: ne, backdropDisappearClass: ce, disappearClass: B } = Hc(X.type, X.direction), K = (c == null ? void 0 : c.itemId) ?? null;
|
|
3452
|
-
|
|
3452
|
+
Ae(() => {
|
|
3453
3453
|
const H = () => {
|
|
3454
3454
|
setTimeout(() => {
|
|
3455
3455
|
var E, z;
|
|
3456
3456
|
(z = (E = C.current) == null ? void 0 : E.splide) == null || z.refresh();
|
|
3457
3457
|
}, 16);
|
|
3458
|
-
},
|
|
3458
|
+
}, re = () => {
|
|
3459
3459
|
f((E) => E + 1);
|
|
3460
3460
|
};
|
|
3461
|
-
return window.addEventListener("ArticleEditor.Layout:change", H), window.addEventListener("ArticleEditor.ComponentContent:change",
|
|
3462
|
-
window.removeEventListener("ArticleEditor.Layout:change", H), window.removeEventListener("ArticleEditor.ComponentContent:change",
|
|
3461
|
+
return window.addEventListener("ArticleEditor.Layout:change", H), window.addEventListener("ArticleEditor.ComponentContent:change", re), () => {
|
|
3462
|
+
window.removeEventListener("ArticleEditor.Layout:change", H), window.removeEventListener("ArticleEditor.ComponentContent:change", re);
|
|
3463
3463
|
};
|
|
3464
|
-
}, []),
|
|
3464
|
+
}, []), Ae(() => {
|
|
3465
3465
|
if (!e || !te.isActive) {
|
|
3466
3466
|
j(!1);
|
|
3467
3467
|
return;
|
|
3468
3468
|
}
|
|
3469
3469
|
const H = N.current;
|
|
3470
3470
|
if (!H) return;
|
|
3471
|
-
const
|
|
3471
|
+
const re = () => {
|
|
3472
3472
|
I.direction === "horiz" ? j(H.scrollWidth > H.clientWidth) : j(H.scrollHeight > H.clientHeight);
|
|
3473
3473
|
};
|
|
3474
|
-
|
|
3475
|
-
const E = new ResizeObserver(
|
|
3474
|
+
re();
|
|
3475
|
+
const E = new ResizeObserver(re);
|
|
3476
3476
|
return E.observe(H), () => E.disconnect();
|
|
3477
3477
|
}, [e, te.isActive, n.length, T, I.direction]);
|
|
3478
3478
|
const U = ft(() => {
|
|
3479
|
-
const H = window.matchMedia("(max-width: 768px)").matches,
|
|
3480
|
-
H && !o &&
|
|
3479
|
+
const H = window.matchMedia("(max-width: 768px)").matches, re = gi(J.color);
|
|
3480
|
+
H && !o && re > 0.9 && (document.body.style.backgroundColor = ""), S(!0), W.current = !0;
|
|
3481
3481
|
const E = (z) => {
|
|
3482
3482
|
z.target === V.current && z.animationName && (V.current && ee.current && V.current.removeEventListener("animationend", ee.current), ee.current = null, W.current && (W.current = !1, t()), S(!1));
|
|
3483
3483
|
};
|
|
3484
3484
|
V.current && (ee.current = E, V.current.addEventListener("animationend", E));
|
|
3485
|
-
}, [t, J.color, o]), se = (H,
|
|
3485
|
+
}, [t, J.color, o]), se = (H, re, E) => {
|
|
3486
3486
|
var z, q;
|
|
3487
3487
|
if (H) {
|
|
3488
3488
|
if (Q.type === "click" && Q.switch === "image")
|
|
3489
3489
|
Q.repeat === "close" && b === n.length - 1 ? U() : (z = C.current) == null || z.go("+1");
|
|
3490
3490
|
else if (Q.type === "click" && Q.switch === "50/50") {
|
|
3491
|
-
const G = H.getBoundingClientRect(), ae =
|
|
3491
|
+
const G = H.getBoundingClientRect(), ae = re - G.left, ge = E - G.top, Ne = G.width, fe = G.height;
|
|
3492
3492
|
let be;
|
|
3493
3493
|
I.direction === "horiz" ? be = ae < Ne / 2 ? "-1" : "+1" : be = ge < fe / 2 ? "-1" : "+1", (q = C.current) == null || q.go(be);
|
|
3494
3494
|
}
|
|
@@ -3498,7 +3498,7 @@ const Oc = ({ settings: e, content: t, styles: n, portalId: r, activeEvent: i, i
|
|
|
3498
3498
|
D.current = !1;
|
|
3499
3499
|
return;
|
|
3500
3500
|
}
|
|
3501
|
-
const
|
|
3501
|
+
const re = n[b], E = (re == null ? void 0 : re.image.objectFit) === "cover";
|
|
3502
3502
|
let z, q;
|
|
3503
3503
|
if ("changedTouches" in H && H.changedTouches.length > 0)
|
|
3504
3504
|
z = H.changedTouches[0].clientX, q = H.changedTouches[0].clientY;
|
|
@@ -3520,43 +3520,43 @@ const Oc = ({ settings: e, content: t, styles: n, portalId: r, activeEvent: i, i
|
|
|
3520
3520
|
}
|
|
3521
3521
|
G ? se(_.current, z, q) : U();
|
|
3522
3522
|
}, Pe = (H) => {
|
|
3523
|
-
const
|
|
3524
|
-
(
|
|
3523
|
+
const re = H.target;
|
|
3524
|
+
(re.classList.contains(Z.thumbsWrapper) || re.classList.contains(Z.thumbsContainer)) && ve(H);
|
|
3525
3525
|
};
|
|
3526
|
-
|
|
3526
|
+
Ae(() => {
|
|
3527
3527
|
if (!e) return;
|
|
3528
|
-
const H = (
|
|
3528
|
+
const H = (re) => {
|
|
3529
3529
|
var E, z;
|
|
3530
|
-
if (
|
|
3530
|
+
if (re.key === "Escape") {
|
|
3531
3531
|
U();
|
|
3532
3532
|
return;
|
|
3533
3533
|
}
|
|
3534
|
-
if (
|
|
3534
|
+
if (re.key === "ArrowRight") {
|
|
3535
3535
|
$((q) => (q + 1) % Math.max(n.length, 1)), (E = C.current) == null || E.go("+1");
|
|
3536
3536
|
return;
|
|
3537
3537
|
}
|
|
3538
|
-
|
|
3538
|
+
re.key === "ArrowLeft" && ($((q) => (q - 1 + Math.max(n.length, 1)) % Math.max(n.length, 1)), (z = C.current) == null || z.go("-1"));
|
|
3539
3539
|
};
|
|
3540
3540
|
return window.addEventListener("keydown", H), () => {
|
|
3541
3541
|
window.removeEventListener("keydown", H);
|
|
3542
3542
|
};
|
|
3543
|
-
}, [e, U, n.length]),
|
|
3543
|
+
}, [e, U, n.length]), Ae(() => {
|
|
3544
3544
|
if (e) {
|
|
3545
|
-
if ($(0), f((
|
|
3545
|
+
if ($(0), f((re) => re + 1), W.current = !1, S(!1), y(!1), O({}), !K) return;
|
|
3546
3546
|
const H = new CustomEvent("page-overlay", { detail: { itemId: K } });
|
|
3547
3547
|
window.dispatchEvent(H);
|
|
3548
3548
|
}
|
|
3549
3549
|
return () => {
|
|
3550
3550
|
V.current && ee.current && (V.current.removeEventListener("animationend", ee.current), ee.current = null), y(!1);
|
|
3551
3551
|
};
|
|
3552
|
-
}, [e, K]),
|
|
3552
|
+
}, [e, K]), Ae(() => {
|
|
3553
3553
|
P.current !== null && P.current !== I.type && f((H) => H + 1), P.current = I.type;
|
|
3554
|
-
}, [I.type]),
|
|
3554
|
+
}, [I.type]), Ae(() => {
|
|
3555
3555
|
if (!e) return;
|
|
3556
|
-
const H = document.body.style.overflow,
|
|
3556
|
+
const H = document.body.style.overflow, re = window.matchMedia("(max-width: 768px)").matches, E = gi(J.color);
|
|
3557
3557
|
document.body.style.overflow = "hidden", y(!1);
|
|
3558
3558
|
const z = (G) => {
|
|
3559
|
-
G.target === V.current && !W.current && G.animationName && (
|
|
3559
|
+
G.target === V.current && !W.current && G.animationName && (re && !o && E > 0.9 && (document.body.style.backgroundColor = J.color), y(!0), V.current && k.current && V.current.removeEventListener("animationend", k.current), k.current = null);
|
|
3560
3560
|
};
|
|
3561
3561
|
V.current && (k.current = z, V.current.addEventListener("animationend", z));
|
|
3562
3562
|
const q = (G) => {
|
|
@@ -3566,27 +3566,27 @@ const Oc = ({ settings: e, content: t, styles: n, portalId: r, activeEvent: i, i
|
|
|
3566
3566
|
return document.addEventListener("touchmove", q, { passive: !1 }), () => {
|
|
3567
3567
|
document.body.style.overflow = H, document.removeEventListener("touchmove", q), V.current && k.current && (V.current.removeEventListener("animationend", k.current), k.current = null), y(!1);
|
|
3568
3568
|
};
|
|
3569
|
-
}, [e, o, J.color, I.type]),
|
|
3569
|
+
}, [e, o, J.color, I.type]), Ae(() => {
|
|
3570
3570
|
if (!e) return;
|
|
3571
|
-
const H = (
|
|
3571
|
+
const H = (re) => {
|
|
3572
3572
|
var z, q;
|
|
3573
3573
|
if (W.current) {
|
|
3574
|
-
|
|
3574
|
+
re.stopPropagation();
|
|
3575
3575
|
return;
|
|
3576
3576
|
}
|
|
3577
3577
|
if (D.current) {
|
|
3578
3578
|
D.current = !1;
|
|
3579
3579
|
return;
|
|
3580
3580
|
}
|
|
3581
|
-
const E =
|
|
3581
|
+
const E = re.target;
|
|
3582
3582
|
if (!(E && (E.closest(`.${Z.thumbsContainer}`) || E.closest(`.${Z.thumbItem}`) || E.closest(`.${Z.arrow}`) || E.closest(`.${Z.closeButton}`) || E.closest(`.${Z.caption}`)))) {
|
|
3583
3583
|
if (I.type === "slide" && Q.type === "drag" && ((q = (z = C.current) == null ? void 0 : z.splide) != null && q.root)) {
|
|
3584
3584
|
const G = C.current.splide.root;
|
|
3585
3585
|
if (E && (G.contains(E) || G === E))
|
|
3586
3586
|
return;
|
|
3587
3587
|
}
|
|
3588
|
-
if (
|
|
3589
|
-
const G = n[b], ae = (G == null ? void 0 : G.image.objectFit) === "cover", ge =
|
|
3588
|
+
if (re.touches.length === 0 && re.changedTouches.length > 0) {
|
|
3589
|
+
const G = n[b], ae = (G == null ? void 0 : G.image.objectFit) === "cover", ge = re.changedTouches[0];
|
|
3590
3590
|
let Ne;
|
|
3591
3591
|
if (ae && _.current) {
|
|
3592
3592
|
const fe = mi(_.current);
|
|
@@ -3597,7 +3597,7 @@ const Oc = ({ settings: e, content: t, styles: n, portalId: r, activeEvent: i, i
|
|
|
3597
3597
|
Ne = ge.clientX >= fe.x && ge.clientX <= fe.x + fe.width && ge.clientY >= fe.y && ge.clientY <= fe.y + fe.height;
|
|
3598
3598
|
}
|
|
3599
3599
|
if (!Ne) {
|
|
3600
|
-
|
|
3600
|
+
re.stopPropagation(), W.current = !0;
|
|
3601
3601
|
const fe = (be) => {
|
|
3602
3602
|
be.stopPropagation(), be.preventDefault(), document.removeEventListener("click", fe, !0);
|
|
3603
3603
|
};
|
|
@@ -3611,10 +3611,10 @@ const Oc = ({ settings: e, content: t, styles: n, portalId: r, activeEvent: i, i
|
|
|
3611
3611
|
};
|
|
3612
3612
|
}, [e, U, b, n]);
|
|
3613
3613
|
const we = (I.type === "scale" || I.type === "fade") && I.direction === "vert" && Q.type === "drag";
|
|
3614
|
-
|
|
3614
|
+
Ae(() => {
|
|
3615
3615
|
var be, Oe;
|
|
3616
3616
|
if (!e || !we || !((Oe = (be = C.current) == null ? void 0 : be.splide) != null && Oe.root)) return;
|
|
3617
|
-
const H = C.current.splide.root,
|
|
3617
|
+
const H = C.current.splide.root, re = 30, E = (ie, Ce) => {
|
|
3618
3618
|
if (R.current) {
|
|
3619
3619
|
const We = Math.abs(ie - R.current.x), Me = Math.abs(Ce - R.current.y);
|
|
3620
3620
|
(We > 0 || Me > 0) && (D.current = !0);
|
|
@@ -3629,7 +3629,7 @@ const Oc = ({ settings: e, content: t, styles: n, portalId: r, activeEvent: i, i
|
|
|
3629
3629
|
return;
|
|
3630
3630
|
}
|
|
3631
3631
|
const We = Math.abs(ie - R.current.x), Me = Math.abs(Ce - R.current.y);
|
|
3632
|
-
Me >
|
|
3632
|
+
Me > re && Me > We && C.current.go(Ce < R.current.y ? "+1" : "-1"), R.current = null;
|
|
3633
3633
|
}, ae = (ie) => {
|
|
3634
3634
|
R.current && G(ie.clientX, ie.clientY), document.removeEventListener("pointerup", ae), document.removeEventListener("pointercancel", ae), document.removeEventListener("pointermove", z);
|
|
3635
3635
|
}, ge = (ie) => {
|
|
@@ -3657,7 +3657,7 @@ const Oc = ({ settings: e, content: t, styles: n, portalId: r, activeEvent: i, i
|
|
|
3657
3657
|
animationFillMode: "both"
|
|
3658
3658
|
};
|
|
3659
3659
|
return typeof document > "u" || !document.getElementById(s) ? null : Vi(
|
|
3660
|
-
/* @__PURE__ */
|
|
3660
|
+
/* @__PURE__ */ oe(Ge, { children: [
|
|
3661
3661
|
/* @__PURE__ */ l(
|
|
3662
3662
|
"div",
|
|
3663
3663
|
{
|
|
@@ -3669,7 +3669,7 @@ const Oc = ({ settings: e, content: t, styles: n, portalId: r, activeEvent: i, i
|
|
|
3669
3669
|
}
|
|
3670
3670
|
}
|
|
3671
3671
|
),
|
|
3672
|
-
/* @__PURE__ */
|
|
3672
|
+
/* @__PURE__ */ oe(
|
|
3673
3673
|
"div",
|
|
3674
3674
|
{
|
|
3675
3675
|
ref: o ? V : null,
|
|
@@ -3702,7 +3702,7 @@ const Oc = ({ settings: e, content: t, styles: n, portalId: r, activeEvent: i, i
|
|
|
3702
3702
|
start: 0
|
|
3703
3703
|
},
|
|
3704
3704
|
style: { "--splide-speed": I.duration },
|
|
3705
|
-
children: n.map((H,
|
|
3705
|
+
children: n.map((H, re) => {
|
|
3706
3706
|
const E = mr(le.position, le.offset, o), z = `${L(le.padding.top, o)} ${L(le.padding.right, o)} ${L(le.padding.bottom, o)} ${L(le.padding.left, o)}`, q = I.type === "scale" ? (() => {
|
|
3707
3707
|
const { transform: G, ...ae } = E;
|
|
3708
3708
|
return {
|
|
@@ -3716,7 +3716,7 @@ const Oc = ({ settings: e, content: t, styles: n, portalId: r, activeEvent: i, i
|
|
|
3716
3716
|
return /* @__PURE__ */ l(Bo, { children: /* @__PURE__ */ l("div", { className: Z.imgWrapper, onClick: ve, children: /* @__PURE__ */ l(
|
|
3717
3717
|
"img",
|
|
3718
3718
|
{
|
|
3719
|
-
ref:
|
|
3719
|
+
ref: re === b ? _ : null,
|
|
3720
3720
|
className: Fe(Z.imageStyle, {
|
|
3721
3721
|
[Z.contain]: H.image.objectFit === "contain",
|
|
3722
3722
|
[Z.cover]: H.image.objectFit === "cover",
|
|
@@ -3726,18 +3726,18 @@ const Oc = ({ settings: e, content: t, styles: n, portalId: r, activeEvent: i, i
|
|
|
3726
3726
|
alt: H.image.name ?? "",
|
|
3727
3727
|
style: { ...q, pointerEvents: H.image.objectFit === "contain" ? "none" : "auto" }
|
|
3728
3728
|
}
|
|
3729
|
-
) }) },
|
|
3729
|
+
) }) }, re);
|
|
3730
3730
|
})
|
|
3731
3731
|
},
|
|
3732
3732
|
x
|
|
3733
3733
|
),
|
|
3734
|
-
g.isActive && /* @__PURE__ */
|
|
3734
|
+
g.isActive && /* @__PURE__ */ oe(Ge, { children: [
|
|
3735
3735
|
/* @__PURE__ */ l(
|
|
3736
3736
|
"div",
|
|
3737
3737
|
{
|
|
3738
3738
|
className: Fe(Z.arrow, { [Z.arrowVertical]: I.direction === "vert" }),
|
|
3739
3739
|
style: { color: g.color, "--arrow-hover-color": g.hover },
|
|
3740
|
-
children: /* @__PURE__ */
|
|
3740
|
+
children: /* @__PURE__ */ oe(
|
|
3741
3741
|
"button",
|
|
3742
3742
|
{
|
|
3743
3743
|
className: Z.arrowInner,
|
|
@@ -3768,7 +3768,7 @@ const Oc = ({ settings: e, content: t, styles: n, portalId: r, activeEvent: i, i
|
|
|
3768
3768
|
{
|
|
3769
3769
|
className: Fe(Z.arrow, Z.nextArrow, { [Z.arrowVertical]: I.direction === "vert" }),
|
|
3770
3770
|
style: { color: g.color, "--arrow-hover-color": g.hover },
|
|
3771
|
-
children: /* @__PURE__ */
|
|
3771
|
+
children: /* @__PURE__ */ oe(
|
|
3772
3772
|
"button",
|
|
3773
3773
|
{
|
|
3774
3774
|
className: Z.arrowInner,
|
|
@@ -3796,10 +3796,10 @@ const Oc = ({ settings: e, content: t, styles: n, portalId: r, activeEvent: i, i
|
|
|
3796
3796
|
)
|
|
3797
3797
|
] }),
|
|
3798
3798
|
J.closeIconUrl && (() => {
|
|
3799
|
-
const H = mr(J.closeIconAlign, J.closeIconOffset, o),
|
|
3799
|
+
const H = mr(J.closeIconAlign, J.closeIconOffset, o), re = `scale(${J.closeIconScale})`, E = H.transform ? `${H.transform} ${re}` : re;
|
|
3800
3800
|
return /* @__PURE__ */ l("button", { className: Z.closeButton, style: { ...H, transform: E }, onClick: U, "aria-label": "Close lightbox", children: /* @__PURE__ */ l(qt, { url: J.closeIconUrl, fill: J.closeIconColor ?? "#000000", hoverFill: J.closeIconHover ?? "#cccccc" }) });
|
|
3801
3801
|
})(),
|
|
3802
|
-
he && he.isActive && r.imageCaption && ((
|
|
3802
|
+
he && he.isActive && r.imageCaption && ((Ie = n[b]) == null ? void 0 : Ie.imageCaption) && /* @__PURE__ */ l(
|
|
3803
3803
|
"div",
|
|
3804
3804
|
{
|
|
3805
3805
|
className: Z.caption,
|
|
@@ -3835,11 +3835,11 @@ const Oc = ({ settings: e, content: t, styles: n, portalId: r, activeEvent: i, i
|
|
|
3835
3835
|
}
|
|
3836
3836
|
),
|
|
3837
3837
|
te.isActive && (() => {
|
|
3838
|
-
const [H,
|
|
3838
|
+
const [H, re] = te.position.split("-"), E = I.direction === "horiz" ? `${H}-left` : te.position, z = mr(E, te.offset, o), q = () => {
|
|
3839
3839
|
if (I.direction === "horiz") {
|
|
3840
|
-
if (
|
|
3841
|
-
if (
|
|
3842
|
-
if (
|
|
3840
|
+
if (re === "left") return "flex-start";
|
|
3841
|
+
if (re === "center") return "center";
|
|
3842
|
+
if (re === "right") return "flex-end";
|
|
3843
3843
|
} else {
|
|
3844
3844
|
if (H === "top") return "flex-start";
|
|
3845
3845
|
if (H === "middle") return "center";
|
|
@@ -5248,9 +5248,9 @@ function Vc({ settings: e, isEditor: t, isEditMode: n, isPreviewMode: r, metadat
|
|
|
5248
5248
|
statusLetterSpacing: Pe,
|
|
5249
5249
|
statusWordSpacing: we,
|
|
5250
5250
|
statusTextAppearance: Ee,
|
|
5251
|
-
successMessage:
|
|
5251
|
+
successMessage: Ie,
|
|
5252
5252
|
errorMessage: H,
|
|
5253
|
-
stateOverrides:
|
|
5253
|
+
stateOverrides: re
|
|
5254
5254
|
} = e, E = u === "B", z = w.slice(0, Math.min(d, w.length)), q = {
|
|
5255
5255
|
fontSettings: {
|
|
5256
5256
|
fontFamily: k,
|
|
@@ -5329,7 +5329,7 @@ function Vc({ settings: e, isEditor: t, isEditMode: n, isPreviewMode: r, metadat
|
|
|
5329
5329
|
labelTextColor: W,
|
|
5330
5330
|
successColor: V,
|
|
5331
5331
|
errorColor: ee
|
|
5332
|
-
}, qc, jc,
|
|
5332
|
+
}, qc, jc, re), [at, vt] = de(
|
|
5333
5333
|
() => Object.fromEntries(z.map((Se) => [Se.name, ""]))
|
|
5334
5334
|
), [bt, Pt] = de("idle"), [Ft, xt] = de(null), Mt = s === "success" ? "success" : s === "error" ? "error" : bt, me = s === "error" ? H : Ft, ze = s === "filled", Ve = He(() => {
|
|
5335
5335
|
if (!ze) return at;
|
|
@@ -5373,15 +5373,15 @@ function Vc({ settings: e, isEditor: t, isEditMode: n, isPreviewMode: r, metadat
|
|
|
5373
5373
|
Pt("error"), xt(Ke instanceof Error ? Ke.message : "Something went wrong");
|
|
5374
5374
|
}
|
|
5375
5375
|
};
|
|
5376
|
-
return /* @__PURE__ */
|
|
5376
|
+
return /* @__PURE__ */ oe("div", { className: `${a}-wrapper ${a}-type-${u} ${Gt}`.trim(), style: je, children: [
|
|
5377
5377
|
/* @__PURE__ */ l("style", { dangerouslySetInnerHTML: { __html: zc(a) } }),
|
|
5378
|
-
/* @__PURE__ */
|
|
5378
|
+
/* @__PURE__ */ oe(
|
|
5379
5379
|
"form",
|
|
5380
5380
|
{
|
|
5381
5381
|
onSubmit: On,
|
|
5382
5382
|
className: `${a}-form`,
|
|
5383
5383
|
children: [
|
|
5384
|
-
/* @__PURE__ */ l("div", { className: `${a}-fields`, children: z.map((Se, nt) => /* @__PURE__ */
|
|
5384
|
+
/* @__PURE__ */ l("div", { className: `${a}-fields`, children: z.map((Se, nt) => /* @__PURE__ */ oe(en.Fragment, { children: [
|
|
5385
5385
|
nt > 0 && /* @__PURE__ */ l(
|
|
5386
5386
|
"div",
|
|
5387
5387
|
{
|
|
@@ -5390,7 +5390,7 @@ function Vc({ settings: e, isEditor: t, isEditMode: n, isPreviewMode: r, metadat
|
|
|
5390
5390
|
style: { height: L(p ?? 0, t) }
|
|
5391
5391
|
}
|
|
5392
5392
|
),
|
|
5393
|
-
/* @__PURE__ */
|
|
5393
|
+
/* @__PURE__ */ oe("div", { className: `${a}-field-group${E ? ` ${a}-labeled` : ""}`, children: [
|
|
5394
5394
|
E && /* @__PURE__ */ l("span", { className: `${a}-field-label`, style: Ce ? { ...Ce, lineHeight: Ce.fontSize } : void 0, children: Se.label || Se.name }),
|
|
5395
5395
|
Se.type === "textarea" ? /* @__PURE__ */ l(
|
|
5396
5396
|
"textarea",
|
|
@@ -5475,7 +5475,7 @@ function Vc({ settings: e, isEditor: t, isEditMode: n, isPreviewMode: r, metadat
|
|
|
5475
5475
|
{
|
|
5476
5476
|
className: `${a}-success`,
|
|
5477
5477
|
style: { ...Me },
|
|
5478
|
-
children:
|
|
5478
|
+
children: Ie
|
|
5479
5479
|
}
|
|
5480
5480
|
),
|
|
5481
5481
|
Mt === "error" && /* @__PURE__ */ l(
|
|
@@ -7013,7 +7013,7 @@ const Zc = ({ settings: e, isEditor: t, isPreviewMode: n, metadata: r, activeEve
|
|
|
7013
7013
|
for (const Ce of Q)
|
|
7014
7014
|
(I[Ce.name] ?? "").trim().length > 0 || (ie = ie ?? { ...I }, ie[Ce.name] = "Filled");
|
|
7015
7015
|
return ie ?? I;
|
|
7016
|
-
}, [ce, I, Q]), K = xe === "error" ? Lr(Q, B) : null, U = i && i !== "default" ? `${s}-state-${i}` : "", se = Q.some((ie) => (B[ie.name] ?? "").trim().length > 0), ve = U !== `${s}-state-filled` && se ? `${s}-state-filled` : "", Pe = `${U} ${ve}`.trim(), we = r == null ? void 0 : r.submitUrl, Ee = u ?? "",
|
|
7016
|
+
}, [ce, I, Q]), K = xe === "error" ? Lr(Q, B) : null, U = i && i !== "default" ? `${s}-state-${i}` : "", se = Q.some((ie) => (B[ie.name] ?? "").trim().length > 0), ve = U !== `${s}-state-filled` && se ? `${s}-state-filled` : "", Pe = `${U} ${ve}`.trim(), we = r == null ? void 0 : r.submitUrl, Ee = u ?? "", Ie = (a == null ? void 0 : a.icon) ?? "", H = (a == null ? void 0 : a.mode) === "On", re = Ee || "Submit", E = {
|
|
7017
7017
|
fontSettings: {
|
|
7018
7018
|
fontFamily: w,
|
|
7019
7019
|
fontWeight: (v == null ? void 0 : v.fontWeight) ?? 400,
|
|
@@ -7096,9 +7096,9 @@ const Zc = ({ settings: e, isEditor: t, isPreviewMode: n, metadata: r, activeEve
|
|
|
7096
7096
|
J("error"), le(Me instanceof Error ? Me.message : "Something went wrong");
|
|
7097
7097
|
}
|
|
7098
7098
|
};
|
|
7099
|
-
return /* @__PURE__ */
|
|
7099
|
+
return /* @__PURE__ */ oe("div", { className: `${s}-wrapper ${Pe}`.trim(), style: Ne, children: [
|
|
7100
7100
|
/* @__PURE__ */ l("style", { dangerouslySetInnerHTML: { __html: Qc(s) } }),
|
|
7101
|
-
/* @__PURE__ */
|
|
7101
|
+
/* @__PURE__ */ oe(
|
|
7102
7102
|
"form",
|
|
7103
7103
|
{
|
|
7104
7104
|
onSubmit: Oe,
|
|
@@ -7142,7 +7142,7 @@ const Zc = ({ settings: e, isEditor: t, isPreviewMode: n, metadata: r, activeEve
|
|
|
7142
7142
|
{
|
|
7143
7143
|
type: o ? "submit" : "button",
|
|
7144
7144
|
className: `${s}-submitBtn`,
|
|
7145
|
-
"aria-label":
|
|
7145
|
+
"aria-label": re,
|
|
7146
7146
|
style: {
|
|
7147
7147
|
...ae,
|
|
7148
7148
|
...be,
|
|
@@ -7152,10 +7152,10 @@ const Zc = ({ settings: e, isEditor: t, isPreviewMode: n, metadata: r, activeEve
|
|
|
7152
7152
|
paddingBottom: L(A.bottom, t),
|
|
7153
7153
|
pointerEvents: o ? "auto" : void 0
|
|
7154
7154
|
},
|
|
7155
|
-
children: g === "submitting" ? "..." : H ?
|
|
7155
|
+
children: g === "submitting" ? "..." : H ? Ie && /* @__PURE__ */ l(
|
|
7156
7156
|
qt,
|
|
7157
7157
|
{
|
|
7158
|
-
url:
|
|
7158
|
+
url: Ie,
|
|
7159
7159
|
className: `${s}-submitBtnIcon`,
|
|
7160
7160
|
style: { maxWidth: L(V ?? 0, t) },
|
|
7161
7161
|
fill: `var(--${s}-button-text-color)`,
|
|
@@ -8533,28 +8533,28 @@ const ld = 30, cd = 20, to = 2, dd = 2, ud = (e, t) => Array.from({ length: t },
|
|
|
8533
8533
|
), he = F ? dd : 1;
|
|
8534
8534
|
yt(() => {
|
|
8535
8535
|
j.current = 0, D({}), A.current = null, te(to), P(0);
|
|
8536
|
-
}, [Q]),
|
|
8536
|
+
}, [Q]), Ae(() => {
|
|
8537
8537
|
if (!b || p !== "randomize") return;
|
|
8538
8538
|
const K = y.current;
|
|
8539
8539
|
if (!K) return;
|
|
8540
8540
|
const U = (we) => {
|
|
8541
8541
|
D((Ee) => {
|
|
8542
|
-
let
|
|
8542
|
+
let Ie = null;
|
|
8543
8543
|
for (const H of we)
|
|
8544
|
-
H in Ee && (md(K, H) || (
|
|
8545
|
-
return
|
|
8544
|
+
H in Ee && (md(K, H) || (Ie || (Ie = { ...Ee }), delete Ie[H]));
|
|
8545
|
+
return Ie ?? Ee;
|
|
8546
8546
|
});
|
|
8547
8547
|
}, se = new IntersectionObserver((we) => {
|
|
8548
8548
|
const Ee = /* @__PURE__ */ new Set();
|
|
8549
|
-
for (const
|
|
8550
|
-
const H =
|
|
8551
|
-
Number.isNaN(
|
|
8549
|
+
for (const Ie of we) {
|
|
8550
|
+
const H = Ie.target.dataset.marqueeItemIndex, re = H !== void 0 ? Number(H) : NaN;
|
|
8551
|
+
Number.isNaN(re) || Ee.add(re);
|
|
8552
8552
|
}
|
|
8553
8553
|
Ee.size > 0 && U(Ee);
|
|
8554
8554
|
}, { root: K, threshold: 0 });
|
|
8555
8555
|
Object.keys(R).forEach((we) => {
|
|
8556
8556
|
const Ee = Number(we);
|
|
8557
|
-
K.querySelectorAll(`[data-marquee-item-index="${Ee}"]`).forEach((
|
|
8557
|
+
K.querySelectorAll(`[data-marquee-item-index="${Ee}"]`).forEach((Ie) => se.observe(Ie));
|
|
8558
8558
|
});
|
|
8559
8559
|
let ve = 0;
|
|
8560
8560
|
const Pe = () => {
|
|
@@ -8570,9 +8570,9 @@ const ld = 30, cd = 20, to = 2, dd = 2, ud = (e, t) => Array.from({ length: t },
|
|
|
8570
8570
|
if (!K || !U) return;
|
|
8571
8571
|
let se = 0;
|
|
8572
8572
|
const ve = () => {
|
|
8573
|
-
const Ee = K.getBoundingClientRect().width,
|
|
8574
|
-
if (A.current =
|
|
8575
|
-
const E =
|
|
8573
|
+
const Ee = K.getBoundingClientRect().width, Ie = U.getBoundingClientRect().width, H = A.current, re = typeof H == "number" && Math.abs(H - Ie) <= 0.25;
|
|
8574
|
+
if (A.current = Ie, x && Ie > 0 && I > 0) {
|
|
8575
|
+
const E = Ie / I;
|
|
8576
8576
|
if (E > 0 && Ee > 0) {
|
|
8577
8577
|
const z = Math.max(
|
|
8578
8578
|
to,
|
|
@@ -8584,11 +8584,11 @@ const ld = 30, cd = 20, to = 2, dd = 2, ud = (e, t) => Array.from({ length: t },
|
|
|
8584
8584
|
}
|
|
8585
8585
|
}
|
|
8586
8586
|
}
|
|
8587
|
-
if (
|
|
8588
|
-
P(
|
|
8587
|
+
if (Ie > 0 && C <= 0) {
|
|
8588
|
+
P(Ie);
|
|
8589
8589
|
return;
|
|
8590
8590
|
}
|
|
8591
|
-
|
|
8591
|
+
re && Ie !== C ? P(Ie) : !re && C <= 0 && (cancelAnimationFrame(se), se = requestAnimationFrame(ve));
|
|
8592
8592
|
}, Pe = () => {
|
|
8593
8593
|
cancelAnimationFrame(se), se = requestAnimationFrame(ve);
|
|
8594
8594
|
};
|
|
@@ -8640,7 +8640,7 @@ const ld = 30, cd = 20, to = 2, dd = 2, ud = (e, t) => Array.from({ length: t },
|
|
|
8640
8640
|
});
|
|
8641
8641
|
}, [t]), B = (K, U, se, ve) => {
|
|
8642
8642
|
const Pe = b && p === "randomize" && h.display === "Cover" ? R[se] ?? K : K, we = `max(${M(d)}, ${cd}px)`, Ee = `calc(-0.5 * (${we} + ${M(d)}))`;
|
|
8643
|
-
return /* @__PURE__ */
|
|
8643
|
+
return /* @__PURE__ */ oe(
|
|
8644
8644
|
"div",
|
|
8645
8645
|
{
|
|
8646
8646
|
className: `${s}-marquee-card`,
|
|
@@ -8684,7 +8684,7 @@ const ld = 30, cd = 20, to = 2, dd = 2, ud = (e, t) => Array.from({ length: t },
|
|
|
8684
8684
|
};
|
|
8685
8685
|
if (F) {
|
|
8686
8686
|
const K = x ? V && ee ? "paused" : "running" : "paused";
|
|
8687
|
-
return /* @__PURE__ */
|
|
8687
|
+
return /* @__PURE__ */ oe(
|
|
8688
8688
|
"div",
|
|
8689
8689
|
{
|
|
8690
8690
|
ref: y,
|
|
@@ -8725,7 +8725,7 @@ const ld = 30, cd = 20, to = 2, dd = 2, ud = (e, t) => Array.from({ length: t },
|
|
|
8725
8725
|
}
|
|
8726
8726
|
);
|
|
8727
8727
|
}
|
|
8728
|
-
return /* @__PURE__ */
|
|
8728
|
+
return /* @__PURE__ */ oe("div", { ref: y, className: `${s}-wrapper`, children: [
|
|
8729
8729
|
/* @__PURE__ */ l("style", { dangerouslySetInnerHTML: { __html: o } }),
|
|
8730
8730
|
/* @__PURE__ */ l(
|
|
8731
8731
|
"div",
|
|
@@ -9785,7 +9785,7 @@ const bd = 30, yi = 2, xd = ({ settings: e, content: t, isEditor: n, isPreviewMo
|
|
|
9785
9785
|
return "left";
|
|
9786
9786
|
}
|
|
9787
9787
|
}, [o]), Pe = ft(
|
|
9788
|
-
(E, z, q, G) => /* @__PURE__ */
|
|
9788
|
+
(E, z, q, G) => /* @__PURE__ */ oe(
|
|
9789
9789
|
"div",
|
|
9790
9790
|
{
|
|
9791
9791
|
style: {
|
|
@@ -9825,7 +9825,7 @@ const bd = 30, yi = 2, xd = ({ settings: e, content: t, isEditor: n, isPreviewMo
|
|
|
9825
9825
|
), we = ft(
|
|
9826
9826
|
(E, z, q) => {
|
|
9827
9827
|
var G, ae, ge;
|
|
9828
|
-
return /* @__PURE__ */
|
|
9828
|
+
return /* @__PURE__ */ oe(
|
|
9829
9829
|
"div",
|
|
9830
9830
|
{
|
|
9831
9831
|
style: {
|
|
@@ -9840,7 +9840,7 @@ const bd = 30, yi = 2, xd = ({ settings: e, content: t, isEditor: n, isPreviewMo
|
|
|
9840
9840
|
},
|
|
9841
9841
|
children: [
|
|
9842
9842
|
/* @__PURE__ */ l("div", { className: `${s}-cover`, style: { background: m } }),
|
|
9843
|
-
/* @__PURE__ */
|
|
9843
|
+
/* @__PURE__ */ oe(
|
|
9844
9844
|
"div",
|
|
9845
9845
|
{
|
|
9846
9846
|
className: `${s}-elements-overlay`,
|
|
@@ -9852,7 +9852,7 @@ const bd = 30, yi = 2, xd = ({ settings: e, content: t, isEditor: n, isPreviewMo
|
|
|
9852
9852
|
"text",
|
|
9853
9853
|
q != null && q.dataMeasureAttrs ? { dataMeasureKind: "text" } : typeof (q == null ? void 0 : q.textMinHeightPx) == "number" && q.textMinHeightPx > 0 ? { minHeightPx: q.textMinHeightPx } : void 0
|
|
9854
9854
|
),
|
|
9855
|
-
/* @__PURE__ */
|
|
9855
|
+
/* @__PURE__ */ oe(
|
|
9856
9856
|
"div",
|
|
9857
9857
|
{
|
|
9858
9858
|
style: {
|
|
@@ -9936,7 +9936,7 @@ const bd = 30, yi = 2, xd = ({ settings: e, content: t, isEditor: n, isPreviewMo
|
|
|
9936
9936
|
q.disconnect();
|
|
9937
9937
|
};
|
|
9938
9938
|
}, [ce, Ee, t, we]);
|
|
9939
|
-
const
|
|
9939
|
+
const Ie = ce ? { textMinHeightPx: I, captionMinHeightPx: g } : void 0, H = ce ? /* @__PURE__ */ l(
|
|
9940
9940
|
"div",
|
|
9941
9941
|
{
|
|
9942
9942
|
ref: Q,
|
|
@@ -9952,7 +9952,7 @@ const bd = 30, yi = 2, xd = ({ settings: e, content: t, isEditor: n, isPreviewMo
|
|
|
9952
9952
|
},
|
|
9953
9953
|
children: (t ?? []).map((E, z) => we(E, `measure-${z}`, { dataMeasureAttrs: !0 }))
|
|
9954
9954
|
}
|
|
9955
|
-
) : null,
|
|
9955
|
+
) : null, re = (E, z) => /* @__PURE__ */ oe(
|
|
9956
9956
|
"div",
|
|
9957
9957
|
{
|
|
9958
9958
|
style: {
|
|
@@ -9965,7 +9965,7 @@ const bd = 30, yi = 2, xd = ({ settings: e, content: t, isEditor: n, isPreviewMo
|
|
|
9965
9965
|
willChange: "transform"
|
|
9966
9966
|
},
|
|
9967
9967
|
children: [
|
|
9968
|
-
we(E, `card-${z}`,
|
|
9968
|
+
we(E, `card-${z}`, Ie),
|
|
9969
9969
|
S && /* @__PURE__ */ l(
|
|
9970
9970
|
"div",
|
|
9971
9971
|
{
|
|
@@ -9988,7 +9988,7 @@ const bd = 30, yi = 2, xd = ({ settings: e, content: t, isEditor: n, isPreviewMo
|
|
|
9988
9988
|
);
|
|
9989
9989
|
if (T) {
|
|
9990
9990
|
const E = y ? A && j ? "paused" : "running" : "paused";
|
|
9991
|
-
return /* @__PURE__ */
|
|
9991
|
+
return /* @__PURE__ */ oe(
|
|
9992
9992
|
"div",
|
|
9993
9993
|
{
|
|
9994
9994
|
ref: P,
|
|
@@ -10037,7 +10037,7 @@ const bd = 30, yi = 2, xd = ({ settings: e, content: t, isEditor: n, isPreviewMo
|
|
|
10037
10037
|
},
|
|
10038
10038
|
"aria-hidden": q > 0,
|
|
10039
10039
|
children: t == null ? void 0 : t.map(
|
|
10040
|
-
(G, ae) =>
|
|
10040
|
+
(G, ae) => re(G, `${q}-${ae}`)
|
|
10041
10041
|
)
|
|
10042
10042
|
},
|
|
10043
10043
|
`set-${q}`
|
|
@@ -10048,7 +10048,7 @@ const bd = 30, yi = 2, xd = ({ settings: e, content: t, isEditor: n, isPreviewMo
|
|
|
10048
10048
|
}
|
|
10049
10049
|
);
|
|
10050
10050
|
}
|
|
10051
|
-
return /* @__PURE__ */
|
|
10051
|
+
return /* @__PURE__ */ oe("div", { className: `${s}-wrapper`, children: [
|
|
10052
10052
|
/* @__PURE__ */ l("style", { dangerouslySetInnerHTML: { __html: fi(s) } }),
|
|
10053
10053
|
H,
|
|
10054
10054
|
/* @__PURE__ */ l(
|
|
@@ -10063,7 +10063,7 @@ const bd = 30, yi = 2, xd = ({ settings: e, content: t, isEditor: n, isPreviewMo
|
|
|
10063
10063
|
},
|
|
10064
10064
|
"aria-label": "Testimonials",
|
|
10065
10065
|
children: t == null ? void 0 : t.map(
|
|
10066
|
-
(E, z) =>
|
|
10066
|
+
(E, z) => re(E, z)
|
|
10067
10067
|
)
|
|
10068
10068
|
}
|
|
10069
10069
|
)
|
|
@@ -11316,7 +11316,7 @@ const Td = 3e3, Ld = ({ settings: e, content: t, isEditor: n, isPreviewMode: r,
|
|
|
11316
11316
|
return "left";
|
|
11317
11317
|
}
|
|
11318
11318
|
}, [a]);
|
|
11319
|
-
|
|
11319
|
+
Ae(() => {
|
|
11320
11320
|
F(0), M(null), T(!1);
|
|
11321
11321
|
}, [o.length]);
|
|
11322
11322
|
const _ = o[f], W = S === null ? null : o[S], V = (ne) => {
|
|
@@ -11348,7 +11348,7 @@ const Td = 3e3, Ld = ({ settings: e, content: t, isEditor: n, isPreviewMode: r,
|
|
|
11348
11348
|
}, [I, te, o.length]), J = ft(() => {
|
|
11349
11349
|
I && F((ne) => te(ne, (ne + 1) % o.length));
|
|
11350
11350
|
}, [I, te, o.length]);
|
|
11351
|
-
|
|
11351
|
+
Ae(() => {
|
|
11352
11352
|
if (!x || !I) return;
|
|
11353
11353
|
const ne = Math.max(300, Td / c), ce = window.setInterval(() => {
|
|
11354
11354
|
F((B) => te(B, (B + 1) % o.length));
|
|
@@ -11356,14 +11356,14 @@ const Td = 3e3, Ld = ({ settings: e, content: t, isEditor: n, isPreviewMode: r,
|
|
|
11356
11356
|
return () => {
|
|
11357
11357
|
window.clearInterval(ce);
|
|
11358
11358
|
};
|
|
11359
|
-
}, [x, I, te, o.length, c]),
|
|
11359
|
+
}, [x, I, te, o.length, c]), Ae(() => () => {
|
|
11360
11360
|
O.current && window.clearTimeout(O.current);
|
|
11361
11361
|
}, []);
|
|
11362
11362
|
const he = (ne, ce) => {
|
|
11363
11363
|
var ve, Pe, we, Ee;
|
|
11364
11364
|
const B = ce == null ? void 0 : ce.textMinHeightPx, K = ce == null ? void 0 : ce.captionMinHeightPx, U = ce == null ? void 0 : ce.dataMeasureAttrs, se = i && !(ce != null && ce.dataMeasureAttrs) && !(ce != null && ce.hideControls);
|
|
11365
|
-
return /* @__PURE__ */
|
|
11366
|
-
ne.text && /* @__PURE__ */
|
|
11365
|
+
return /* @__PURE__ */ oe(Ge, { children: [
|
|
11366
|
+
ne.text && /* @__PURE__ */ oe("div", { style: { display: "flex", flexDirection: "column", alignItems: C, width: "100%" }, children: [
|
|
11367
11367
|
/* @__PURE__ */ l(
|
|
11368
11368
|
"div",
|
|
11369
11369
|
{
|
|
@@ -11386,7 +11386,7 @@ const Td = 3e3, Ld = ({ settings: e, content: t, isEditor: n, isPreviewMode: r,
|
|
|
11386
11386
|
}
|
|
11387
11387
|
)
|
|
11388
11388
|
] }),
|
|
11389
|
-
/* @__PURE__ */
|
|
11389
|
+
/* @__PURE__ */ oe("div", { style: { display: "flex", flexDirection: "column", alignItems: C, width: "100%" }, children: [
|
|
11390
11390
|
/* @__PURE__ */ l(
|
|
11391
11391
|
"div",
|
|
11392
11392
|
{
|
|
@@ -11405,7 +11405,7 @@ const Td = 3e3, Ld = ({ settings: e, content: t, isEditor: n, isPreviewMode: r,
|
|
|
11405
11405
|
}
|
|
11406
11406
|
) })
|
|
11407
11407
|
] }),
|
|
11408
|
-
ne.caption && /* @__PURE__ */
|
|
11408
|
+
ne.caption && /* @__PURE__ */ oe("div", { style: { display: "flex", flexDirection: "column", alignItems: C, width: "100%" }, children: [
|
|
11409
11409
|
/* @__PURE__ */ l(
|
|
11410
11410
|
"div",
|
|
11411
11411
|
{
|
|
@@ -11449,9 +11449,9 @@ const Td = 3e3, Ld = ({ settings: e, content: t, isEditor: n, isPreviewMode: r,
|
|
|
11449
11449
|
};
|
|
11450
11450
|
}, [R, le, t]), !_) return /* @__PURE__ */ l(Ge, {});
|
|
11451
11451
|
const xe = R ? { textMinHeightPx: N, captionMinHeightPx: j } : void 0;
|
|
11452
|
-
return /* @__PURE__ */ l(Ge, { children: /* @__PURE__ */
|
|
11452
|
+
return /* @__PURE__ */ l(Ge, { children: /* @__PURE__ */ oe("div", { className: `${s}-container`, children: [
|
|
11453
11453
|
/* @__PURE__ */ l("style", { dangerouslySetInnerHTML: { __html: Sd(s) } }),
|
|
11454
|
-
/* @__PURE__ */
|
|
11454
|
+
/* @__PURE__ */ oe(
|
|
11455
11455
|
"div",
|
|
11456
11456
|
{
|
|
11457
11457
|
className: `${s}-wrapper`,
|
|
@@ -11475,14 +11475,14 @@ const Td = 3e3, Ld = ({ settings: e, content: t, isEditor: n, isPreviewMode: r,
|
|
|
11475
11475
|
children: o.map((ne, ce) => /* @__PURE__ */ l("div", { style: { width: "100%" }, children: he(ne, { dataMeasureAttrs: !0 }) }, ce))
|
|
11476
11476
|
}
|
|
11477
11477
|
),
|
|
11478
|
-
/* @__PURE__ */
|
|
11478
|
+
/* @__PURE__ */ oe("div", { className: `${s}-fade-stack`, children: [
|
|
11479
11479
|
W && y && /* @__PURE__ */ l("div", { className: Fe(`${s}-fade-item-prev`, `${s}-fade-out`), children: he(W, { ...xe, hideControls: !0 }) }),
|
|
11480
11480
|
/* @__PURE__ */ l("div", { className: Fe(`${s}-fade-item-current`, y ? `${s}-fade-in` : void 0), children: he(_, xe) })
|
|
11481
11481
|
] })
|
|
11482
11482
|
]
|
|
11483
11483
|
}
|
|
11484
11484
|
),
|
|
11485
|
-
Q.mode === "On" && /* @__PURE__ */
|
|
11485
|
+
Q.mode === "On" && /* @__PURE__ */ oe("div", { className: `${s}-controls`, children: [
|
|
11486
11486
|
/* @__PURE__ */ l(
|
|
11487
11487
|
"div",
|
|
11488
11488
|
{
|
|
@@ -12770,21 +12770,21 @@ function Rd({ images: e, index: t, imageDisplay: n, originRect: r, reverseClose:
|
|
|
12770
12770
|
p({ width: N, height: V, left: _.left + (W - N) / 2, top: _.top });
|
|
12771
12771
|
}
|
|
12772
12772
|
}, [n]);
|
|
12773
|
-
|
|
12773
|
+
Ae(() => {
|
|
12774
12774
|
F();
|
|
12775
12775
|
const C = w.current;
|
|
12776
12776
|
if (!C) return;
|
|
12777
12777
|
const P = new ResizeObserver(() => F());
|
|
12778
12778
|
return P.observe(C), () => P.disconnect();
|
|
12779
|
-
}, [F, t]),
|
|
12779
|
+
}, [F, t]), Ae(() => {
|
|
12780
12780
|
m === "opening" && h && b("open");
|
|
12781
|
-
}, [m, h]),
|
|
12781
|
+
}, [m, h]), Ae(() => {
|
|
12782
12782
|
if (m !== "closing") return;
|
|
12783
12783
|
const C = setTimeout(() => s(), Ht);
|
|
12784
12784
|
return () => clearTimeout(C);
|
|
12785
|
-
}, [m, s]),
|
|
12785
|
+
}, [m, s]), Ae(() => {
|
|
12786
12786
|
f.current !== t && x(!1), f.current = t;
|
|
12787
|
-
}, [t]),
|
|
12787
|
+
}, [t]), Ae(() => {
|
|
12788
12788
|
const C = (P) => {
|
|
12789
12789
|
P.key === "Escape" && (P.preventDefault(), P.stopPropagation(), m !== "closing" && b("closing"));
|
|
12790
12790
|
};
|
|
@@ -12793,7 +12793,7 @@ function Rd({ images: e, index: t, imageDisplay: n, originRect: r, reverseClose:
|
|
|
12793
12793
|
const S = () => {
|
|
12794
12794
|
m !== "closing" && b("closing");
|
|
12795
12795
|
}, M = m === "open", y = m === "closing", T = y && i && !!r, O = m === "opening" ? r ?? h : T ? r : h;
|
|
12796
|
-
return /* @__PURE__ */
|
|
12796
|
+
return /* @__PURE__ */ oe(
|
|
12797
12797
|
"div",
|
|
12798
12798
|
{
|
|
12799
12799
|
style: {
|
|
@@ -12831,7 +12831,7 @@ function Rd({ images: e, index: t, imageDisplay: n, originRect: r, reverseClose:
|
|
|
12831
12831
|
alignItems: "center",
|
|
12832
12832
|
justifyContent: "center"
|
|
12833
12833
|
},
|
|
12834
|
-
children: d ? /* @__PURE__ */
|
|
12834
|
+
children: d ? /* @__PURE__ */ oe(Ge, { children: [
|
|
12835
12835
|
/* @__PURE__ */ l("div", { ref: w, style: { position: "absolute", inset: 0 } }),
|
|
12836
12836
|
/* @__PURE__ */ l(
|
|
12837
12837
|
"div",
|
|
@@ -12851,14 +12851,14 @@ function Rd({ images: e, index: t, imageDisplay: n, originRect: r, reverseClose:
|
|
|
12851
12851
|
pointerEvents: "none",
|
|
12852
12852
|
zIndex: 9999
|
|
12853
12853
|
},
|
|
12854
|
-
children: e.length > 1 && /* @__PURE__ */
|
|
12854
|
+
children: e.length > 1 && /* @__PURE__ */ oe("p", { className: a, style: u, children: [
|
|
12855
12855
|
t + 1,
|
|
12856
12856
|
" / ",
|
|
12857
12857
|
e.length
|
|
12858
12858
|
] })
|
|
12859
12859
|
}
|
|
12860
12860
|
)
|
|
12861
|
-
] }) : /* @__PURE__ */
|
|
12861
|
+
] }) : /* @__PURE__ */ oe(Ge, { children: [
|
|
12862
12862
|
/* @__PURE__ */ l("div", { style: { height: "10%" } }),
|
|
12863
12863
|
/* @__PURE__ */ l(
|
|
12864
12864
|
"div",
|
|
@@ -12885,7 +12885,7 @@ function Rd({ images: e, index: t, imageDisplay: n, originRect: r, reverseClose:
|
|
|
12885
12885
|
opacity: M ? 1 : 0,
|
|
12886
12886
|
transition: `opacity ${Ht}ms ${Yt}`
|
|
12887
12887
|
},
|
|
12888
|
-
children: e.length > 1 && /* @__PURE__ */
|
|
12888
|
+
children: e.length > 1 && /* @__PURE__ */ oe("p", { className: a, style: u, children: [
|
|
12889
12889
|
t + 1,
|
|
12890
12890
|
" / ",
|
|
12891
12891
|
e.length
|
|
@@ -12915,7 +12915,7 @@ function Rd({ images: e, index: t, imageDisplay: n, originRect: r, reverseClose:
|
|
|
12915
12915
|
}
|
|
12916
12916
|
}
|
|
12917
12917
|
),
|
|
12918
|
-
M && h && /* @__PURE__ */
|
|
12918
|
+
M && h && /* @__PURE__ */ oe(Ge, { children: [
|
|
12919
12919
|
/* @__PURE__ */ l(
|
|
12920
12920
|
"div",
|
|
12921
12921
|
{
|
|
@@ -13040,7 +13040,7 @@ function Md({ settings: e, content: t, isEditor: n, isPreviewMode: r, isEditMode
|
|
|
13040
13040
|
wordSpacing: le ?? 0,
|
|
13041
13041
|
textAppearance: xe,
|
|
13042
13042
|
color: O
|
|
13043
|
-
},
|
|
13043
|
+
}, Ie = {
|
|
13044
13044
|
...St(rt(we, n)),
|
|
13045
13045
|
...ro(g, J, a, n)
|
|
13046
13046
|
}, H = no(
|
|
@@ -13048,7 +13048,7 @@ function Md({ settings: e, content: t, isEditor: n, isPreviewMode: r, isEditMode
|
|
|
13048
13048
|
W,
|
|
13049
13049
|
`${a}-item-title`,
|
|
13050
13050
|
`${a}-text-tight-leading`
|
|
13051
|
-
),
|
|
13051
|
+
), re = no(
|
|
13052
13052
|
N,
|
|
13053
13053
|
A,
|
|
13054
13054
|
`${a}-item-subtitle`,
|
|
@@ -13078,7 +13078,7 @@ function Md({ settings: e, content: t, isEditor: n, isPreviewMode: r, isEditMode
|
|
|
13078
13078
|
height: "auto",
|
|
13079
13079
|
maxWidth: "100%"
|
|
13080
13080
|
}, [Gt, Ct] = de("ltr"), [Nt, On] = de(0), Se = Te(null);
|
|
13081
|
-
|
|
13081
|
+
Ae(() => {
|
|
13082
13082
|
const Re = Se.current;
|
|
13083
13083
|
if (!Re) return;
|
|
13084
13084
|
const ut = new ResizeObserver((pt) => {
|
|
@@ -13094,17 +13094,17 @@ function Md({ settings: e, content: t, isEditor: n, isPreviewMode: r, isEditMode
|
|
|
13094
13094
|
const Y = Re.currentTarget.getBoundingClientRect();
|
|
13095
13095
|
cr({ top: Y.top, left: Y.left, width: Y.width, height: Y.height }), lr(ut), yn(pt), Ke(!0);
|
|
13096
13096
|
};
|
|
13097
|
-
|
|
13097
|
+
Ae(() => {
|
|
13098
13098
|
if (!Qe || p !== "on" || typeof document > "u") return;
|
|
13099
13099
|
const Re = document.body.style.overflow;
|
|
13100
13100
|
return document.body.style.overflow = "hidden", () => {
|
|
13101
13101
|
document.body.style.overflow = Re;
|
|
13102
13102
|
};
|
|
13103
|
-
}, [Qe, p]),
|
|
13103
|
+
}, [Qe, p]), Ae(() => {
|
|
13104
13104
|
!n || r || (Ke(!1), cr(null));
|
|
13105
13105
|
}, [n, r]);
|
|
13106
13106
|
const Gr = He(() => kd(a), [a]);
|
|
13107
|
-
return /* @__PURE__ */
|
|
13107
|
+
return /* @__PURE__ */ oe(Ge, { children: [
|
|
13108
13108
|
/* @__PURE__ */ l("style", { dangerouslySetInnerHTML: { __html: Gr } }),
|
|
13109
13109
|
/* @__PURE__ */ l("div", { style: G, children: /* @__PURE__ */ l(
|
|
13110
13110
|
"div",
|
|
@@ -13120,7 +13120,7 @@ function Md({ settings: e, content: t, isEditor: n, isPreviewMode: r, isEditMode
|
|
|
13120
13120
|
},
|
|
13121
13121
|
children: be.map((Re, ut) => {
|
|
13122
13122
|
var et, ht;
|
|
13123
|
-
const pt = xi(Re.title), Y = xi(Re.subtitle), pe = (((et = Re.link) == null ? void 0 : et.length) ?? 0) > 0 && p === "off" ? Re.link : void 0, ye = Math.floor(ut / d.columnsCount) === Math.ceil(be.length / d.columnsCount) - 1, Le = me ? /* @__PURE__ */
|
|
13123
|
+
const pt = xi(Re.title), Y = xi(Re.subtitle), pe = (((et = Re.link) == null ? void 0 : et.length) ?? 0) > 0 && p === "off" ? Re.link : void 0, ye = Math.floor(ut / d.columnsCount) === Math.ceil(be.length / d.columnsCount) - 1, Le = me ? /* @__PURE__ */ oe("div", { className: `${a}-item-text-block`, children: [
|
|
13124
13124
|
pt && /* @__PURE__ */ l("p", { className: H, style: { width: Ve, ...U, ...E }, children: Re.title }),
|
|
13125
13125
|
pt && /* @__PURE__ */ l(
|
|
13126
13126
|
"div",
|
|
@@ -13133,7 +13133,7 @@ function Md({ settings: e, content: t, isEditor: n, isPreviewMode: r, isEditMode
|
|
|
13133
13133
|
}
|
|
13134
13134
|
}
|
|
13135
13135
|
),
|
|
13136
|
-
Y && /* @__PURE__ */ l("p", { className:
|
|
13136
|
+
Y && /* @__PURE__ */ l("p", { className: re, style: { width: Ve, ...Pe, ...z }, children: Re.subtitle }),
|
|
13137
13137
|
Y && /* @__PURE__ */ l(
|
|
13138
13138
|
"div",
|
|
13139
13139
|
{
|
|
@@ -13145,7 +13145,7 @@ function Md({ settings: e, content: t, isEditor: n, isPreviewMode: r, isEditMode
|
|
|
13145
13145
|
}
|
|
13146
13146
|
}
|
|
13147
13147
|
)
|
|
13148
|
-
] }) : null, Ye = me ? /* @__PURE__ */
|
|
13148
|
+
] }) : null, Ye = me ? /* @__PURE__ */ oe("div", { className: `${a}-item-title-row`, children: [
|
|
13149
13149
|
pt && /* @__PURE__ */ l("p", { className: H, style: { width: Ve, ...U, ...E }, children: Re.title }),
|
|
13150
13150
|
pt && /* @__PURE__ */ l(
|
|
13151
13151
|
"div",
|
|
@@ -13158,8 +13158,8 @@ function Md({ settings: e, content: t, isEditor: n, isPreviewMode: r, isEditMode
|
|
|
13158
13158
|
}
|
|
13159
13159
|
}
|
|
13160
13160
|
)
|
|
13161
|
-
] }) : null, Je = me ? /* @__PURE__ */
|
|
13162
|
-
Y && /* @__PURE__ */ l("p", { className:
|
|
13161
|
+
] }) : null, Je = me ? /* @__PURE__ */ oe("div", { className: `${a}-item-subtitle-row`, children: [
|
|
13162
|
+
Y && /* @__PURE__ */ l("p", { className: re, style: { width: Ve, ...Pe, ...z }, children: Re.subtitle }),
|
|
13163
13163
|
Y && /* @__PURE__ */ l(
|
|
13164
13164
|
"div",
|
|
13165
13165
|
{
|
|
@@ -13171,10 +13171,10 @@ function Md({ settings: e, content: t, isEditor: n, isPreviewMode: r, isEditMode
|
|
|
13171
13171
|
}
|
|
13172
13172
|
}
|
|
13173
13173
|
)
|
|
13174
|
-
] }) : null, _e = pe ? /* @__PURE__ */
|
|
13174
|
+
] }) : null, _e = pe ? /* @__PURE__ */ oe("a", { href: pe, target: "_blank", className: `${a}-item-text-link`, children: [
|
|
13175
13175
|
Ye,
|
|
13176
13176
|
Je
|
|
13177
|
-
] }) : /* @__PURE__ */
|
|
13177
|
+
] }) : /* @__PURE__ */ oe(Ge, { children: [
|
|
13178
13178
|
Ye,
|
|
13179
13179
|
Je
|
|
13180
13180
|
] }), mt = /* @__PURE__ */ l("div", { className: Mt, style: xt, children: (((ht = Re.image) == null ? void 0 : ht.length) ?? 0) === 0 ? null : $ === "off" ? (() => {
|
|
@@ -13188,7 +13188,7 @@ function Md({ settings: e, content: t, isEditor: n, isPreviewMode: r, isEditMode
|
|
|
13188
13188
|
onImageClick: Jt(Be) ? void 0 : (ot) => dr(ot, lt, 0)
|
|
13189
13189
|
}
|
|
13190
13190
|
);
|
|
13191
|
-
})() : /* @__PURE__ */
|
|
13191
|
+
})() : /* @__PURE__ */ oe(Ge, { children: [
|
|
13192
13192
|
Ft && /* @__PURE__ */ l("div", { className: `${a}-item-image-wrapper-sizer`, "aria-hidden": "true", children: Re.image.map((Be) => Jt(Be) ? /* @__PURE__ */ l("video", { src: Be.url, muted: !0, playsInline: !0 }, `sizer-${Be.url}`) : /* @__PURE__ */ l("img", { src: Be.url, alt: "" }, `sizer-${Be.url}`)) }),
|
|
13193
13193
|
/* @__PURE__ */ l(
|
|
13194
13194
|
Oo,
|
|
@@ -13232,7 +13232,7 @@ function Md({ settings: e, content: t, isEditor: n, isPreviewMode: r, isEditMode
|
|
|
13232
13232
|
},
|
|
13233
13233
|
`${F}-${Oe}-${f}-${x}-${Nt}-${c}`
|
|
13234
13234
|
)
|
|
13235
|
-
] }) }), gt = me ? null : /* @__PURE__ */
|
|
13235
|
+
] }) }), gt = me ? null : /* @__PURE__ */ oe(Ge, { children: [
|
|
13236
13236
|
/* @__PURE__ */ l(
|
|
13237
13237
|
"div",
|
|
13238
13238
|
{
|
|
@@ -13266,7 +13266,7 @@ function Md({ settings: e, content: t, isEditor: n, isPreviewMode: r, isEditMode
|
|
|
13266
13266
|
/* @__PURE__ */ l(
|
|
13267
13267
|
"p",
|
|
13268
13268
|
{
|
|
13269
|
-
className:
|
|
13269
|
+
className: re,
|
|
13270
13270
|
style: { width: Ve, ...Pe, ...z },
|
|
13271
13271
|
children: Re.subtitle
|
|
13272
13272
|
}
|
|
@@ -13281,10 +13281,10 @@ function Md({ settings: e, content: t, isEditor: n, isPreviewMode: r, isEditMode
|
|
|
13281
13281
|
{
|
|
13282
13282
|
className: `${i ? `${a}-item-inner` : `${a}-item-inner-hidden`}${ze && ye ? ` ${a}-item-inner-last-row` : ""}`.trim(),
|
|
13283
13283
|
style: { width: (w ?? 0) > 100 ? `calc(${L(Oe ?? 0, n)} * (${w} / 100))` : L(Oe ?? 0, n) },
|
|
13284
|
-
children: ze ? /* @__PURE__ */
|
|
13284
|
+
children: ze ? /* @__PURE__ */ oe(Ge, { children: [
|
|
13285
13285
|
_e,
|
|
13286
13286
|
/* @__PURE__ */ l("a", { href: pe, target: "_blank", className: `${a}-item-image-link`, children: mt })
|
|
13287
|
-
] }) : /* @__PURE__ */
|
|
13287
|
+
] }) : /* @__PURE__ */ oe("a", { href: pe, target: "_blank", className: `${a}-item-image-link`, children: [
|
|
13288
13288
|
Le,
|
|
13289
13289
|
mt,
|
|
13290
13290
|
gt
|
|
@@ -13310,7 +13310,7 @@ function Md({ settings: e, content: t, isEditor: n, isPreviewMode: r, isEditMode
|
|
|
13310
13310
|
onPrev: () => yn((Re) => (Re - 1 + dt.length) % dt.length),
|
|
13311
13311
|
onNext: () => yn((Re) => (Re + 1) % dt.length),
|
|
13312
13312
|
counterClassName: q,
|
|
13313
|
-
counterStyle:
|
|
13313
|
+
counterStyle: Ie
|
|
13314
13314
|
}
|
|
13315
13315
|
) }),
|
|
13316
13316
|
document.body
|
|
@@ -15214,7 +15214,7 @@ function qd({
|
|
|
15214
15214
|
style: n
|
|
15215
15215
|
}) {
|
|
15216
15216
|
const r = Te(null);
|
|
15217
|
-
return
|
|
15217
|
+
return Ae(() => {
|
|
15218
15218
|
if (!e.isVideo) return;
|
|
15219
15219
|
const i = r.current;
|
|
15220
15220
|
if (!i) return;
|
|
@@ -16292,9 +16292,9 @@ function Lu({ settings: e, content: t, isEditor: n, isPreviewMode: r, isEditMode
|
|
|
16292
16292
|
for (; Le && !Le.style.getPropertyValue("--cntrl-article-width"); )
|
|
16293
16293
|
Le = Le.parentElement;
|
|
16294
16294
|
return Le && ye.observe(Le), () => ye.disconnect();
|
|
16295
|
-
}, [n, o]),
|
|
16295
|
+
}, [n, o]), Ae(() => {
|
|
16296
16296
|
j(void 0);
|
|
16297
|
-
}, [$, x, t, h]),
|
|
16297
|
+
}, [$, x, t, h]), Ae(() => {
|
|
16298
16298
|
n && !r && j(void 0);
|
|
16299
16299
|
}, [n, r]);
|
|
16300
16300
|
const Pe = Jn(a, {
|
|
@@ -16304,8 +16304,8 @@ function Lu({ settings: e, content: t, isEditor: n, isPreviewMode: r, isEditMode
|
|
|
16304
16304
|
textHoverColor: R,
|
|
16305
16305
|
backgroundHoverColor: D,
|
|
16306
16306
|
dividerHoverColor: N
|
|
16307
|
-
}, cu, du), we = s && s !== "default" ? `${a}-state-${s}` : "",
|
|
16308
|
-
|
|
16307
|
+
}, cu, du), we = s && s !== "default" ? `${a}-state-${s}` : "", Ie = `${!n || r ? y === "default" ? `${a}-entry-hover-default` : y === "blinds" ? `${a}-entry-hover-blinds` : y === "reveal" ? `${a}-entry-hover-reveal` : "" : ""} ${we}`.trim(), H = y === "reveal" && (!n || r), re = (b == null ? void 0 : b[0]) ?? !1, E = (b == null ? void 0 : b[1]) ?? !1, z = Te(e), q = Te(o);
|
|
16308
|
+
Ae(() => {
|
|
16309
16309
|
if (!c || !n) {
|
|
16310
16310
|
z.current = e, q.current = o;
|
|
16311
16311
|
return;
|
|
@@ -16401,7 +16401,7 @@ function Lu({ settings: e, content: t, isEditor: n, isPreviewMode: r, isEditMode
|
|
|
16401
16401
|
link: ye.link
|
|
16402
16402
|
}));
|
|
16403
16403
|
}, [t, h]), at = te ? A ?? $ : je.length, vt = He(() => te ? je.slice(0, at) : je, [je, te, at]), bt = te && at < je.length, Pt = vt.length > 1 || bt, Ft = [
|
|
16404
|
-
|
|
16404
|
+
re ? `${a}-divider-top` : "",
|
|
16405
16405
|
E || Pt ? `${a}-divider-bottom` : ""
|
|
16406
16406
|
].filter(Boolean).join(" "), xt = !n || r, Mt = () => {
|
|
16407
16407
|
if (!xt) return;
|
|
@@ -16414,7 +16414,7 @@ function Lu({ settings: e, content: t, isEditor: n, isPreviewMode: r, isEditMode
|
|
|
16414
16414
|
}, me = (Y) => L(Y, n ?? !1), ze = g ? P ?? 0 : O ?? 0, Ve = C ?? 0, Ze = p ?? 0, Et = ze + Ze / 2, Gt = Math.max(Ve, ao), Ct = Si(
|
|
16415
16415
|
0,
|
|
16416
16416
|
vt.length,
|
|
16417
|
-
|
|
16417
|
+
re,
|
|
16418
16418
|
E,
|
|
16419
16419
|
bt,
|
|
16420
16420
|
m ?? 0,
|
|
@@ -16491,7 +16491,7 @@ function Lu({ settings: e, content: t, isEditor: n, isPreviewMode: r, isEditMode
|
|
|
16491
16491
|
We,
|
|
16492
16492
|
ne,
|
|
16493
16493
|
m,
|
|
16494
|
-
|
|
16494
|
+
re,
|
|
16495
16495
|
E,
|
|
16496
16496
|
bt
|
|
16497
16497
|
]);
|
|
@@ -16609,13 +16609,13 @@ function Lu({ settings: e, content: t, isEditor: n, isPreviewMode: r, isEditMode
|
|
|
16609
16609
|
We
|
|
16610
16610
|
]);
|
|
16611
16611
|
const pt = He(() => Ud(a), [a]);
|
|
16612
|
-
return /* @__PURE__ */
|
|
16612
|
+
return /* @__PURE__ */ oe(Ge, { children: [
|
|
16613
16613
|
/* @__PURE__ */ l("style", { dangerouslySetInnerHTML: { __html: pt } }),
|
|
16614
|
-
/* @__PURE__ */ l("div", { style: Pe, children: /* @__PURE__ */
|
|
16614
|
+
/* @__PURE__ */ l("div", { style: Pe, children: /* @__PURE__ */ oe(
|
|
16615
16615
|
"div",
|
|
16616
16616
|
{
|
|
16617
16617
|
ref: J,
|
|
16618
|
-
className: `${a}-wrapper ${
|
|
16618
|
+
className: `${a}-wrapper ${Ie}${Ft ? ` ${Ft}` : ""}${g ? ` ${a}-type-b` : ""}`.trim(),
|
|
16619
16619
|
style: {
|
|
16620
16620
|
width: L(v ?? 0, n),
|
|
16621
16621
|
...!g && u ? { [`--${a}-first-entry-handle-top`]: Nt } : {}
|
|
@@ -16623,19 +16623,19 @@ function Lu({ settings: e, content: t, isEditor: n, isPreviewMode: r, isEditMode
|
|
|
16623
16623
|
onMouseMove: I ? cr : void 0,
|
|
16624
16624
|
onMouseLeave: I ? dr : void 0,
|
|
16625
16625
|
children: [
|
|
16626
|
-
/* @__PURE__ */
|
|
16626
|
+
/* @__PURE__ */ oe("div", { style: { width: "100%", position: "relative" }, children: [
|
|
16627
16627
|
vt.map((Y, pe) => {
|
|
16628
16628
|
var Je;
|
|
16629
16629
|
const ye = (((Je = Y.link) == null ? void 0 : Je.length) ?? 0) > 0, Le = ye && (!n || r) ? "a" : "div", Ye = Si(
|
|
16630
16630
|
pe,
|
|
16631
16631
|
vt.length,
|
|
16632
|
-
|
|
16632
|
+
re,
|
|
16633
16633
|
E,
|
|
16634
16634
|
bt,
|
|
16635
16635
|
m ?? 0,
|
|
16636
16636
|
n ?? !1
|
|
16637
16637
|
);
|
|
16638
|
-
return /* @__PURE__ */
|
|
16638
|
+
return /* @__PURE__ */ oe(
|
|
16639
16639
|
Le,
|
|
16640
16640
|
{
|
|
16641
16641
|
ref: pe === 0 ? (_e) => {
|
|
@@ -16658,7 +16658,7 @@ function Lu({ settings: e, content: t, isEditor: n, isPreviewMode: r, isEditMode
|
|
|
16658
16658
|
style: { height: me(ze) }
|
|
16659
16659
|
}
|
|
16660
16660
|
),
|
|
16661
|
-
/* @__PURE__ */
|
|
16661
|
+
/* @__PURE__ */ oe(
|
|
16662
16662
|
"div",
|
|
16663
16663
|
{
|
|
16664
16664
|
className: `${a}-list-cols-row${g ? "" : ` ${a}-list-cols-row-h`}${u && pe === 0 && g ? ` ${a}-list-cols-row-controls` : ""}`,
|
|
@@ -16679,7 +16679,7 @@ function Lu({ settings: e, content: t, isEditor: n, isPreviewMode: r, isEditMode
|
|
|
16679
16679
|
e,
|
|
16680
16680
|
vn
|
|
16681
16681
|
), ur = g && Be && u && pe === 0;
|
|
16682
|
-
return /* @__PURE__ */
|
|
16682
|
+
return /* @__PURE__ */ oe(
|
|
16683
16683
|
"div",
|
|
16684
16684
|
{
|
|
16685
16685
|
className: g ? `${a}-list-col-wrap` : void 0,
|
|
@@ -16751,7 +16751,7 @@ function Lu({ settings: e, content: t, isEditor: n, isPreviewMode: r, isEditMode
|
|
|
16751
16751
|
_e.key
|
|
16752
16752
|
);
|
|
16753
16753
|
}),
|
|
16754
|
-
u && pe === 0 && g && /* @__PURE__ */
|
|
16754
|
+
u && pe === 0 && g && /* @__PURE__ */ oe(Ge, { children: [
|
|
16755
16755
|
/* @__PURE__ */ l(
|
|
16756
16756
|
Ot,
|
|
16757
16757
|
{
|
|
@@ -16855,7 +16855,7 @@ function Lu({ settings: e, content: t, isEditor: n, isPreviewMode: r, isEditMode
|
|
|
16855
16855
|
}
|
|
16856
16856
|
}
|
|
16857
16857
|
) }, "row-padding-handles"),
|
|
16858
|
-
u && !g && Se && nt && /* @__PURE__ */
|
|
16858
|
+
u && !g && Se && nt && /* @__PURE__ */ oe("div", { style: { position: "absolute", inset: 0, pointerEvents: "none" }, children: [
|
|
16859
16859
|
/* @__PURE__ */ l(
|
|
16860
16860
|
Ot,
|
|
16861
16861
|
{
|
|
@@ -16912,7 +16912,7 @@ function Lu({ settings: e, content: t, isEditor: n, isPreviewMode: r, isEditMode
|
|
|
16912
16912
|
Je.paddingLeft,
|
|
16913
16913
|
Sn
|
|
16914
16914
|
);
|
|
16915
|
-
return /* @__PURE__ */
|
|
16915
|
+
return /* @__PURE__ */ oe("div", { style: { position: "absolute", inset: 0, pointerEvents: "none" }, children: [
|
|
16916
16916
|
/* @__PURE__ */ l(
|
|
16917
16917
|
Ot,
|
|
16918
16918
|
{
|
|
@@ -21201,10 +21201,14 @@ function Xu({ settings: e, content: t, isEditor: n, isPreviewMode: r, isEditMode
|
|
|
21201
21201
|
answerPaddingTop: le = 0,
|
|
21202
21202
|
answerPaddingBottom: xe = 0
|
|
21203
21203
|
} = e, ne = t ?? [], [ce, B] = de(() => /* @__PURE__ */ new Set()), K = !n || r;
|
|
21204
|
-
|
|
21204
|
+
Ae(() => {
|
|
21205
21205
|
B(/* @__PURE__ */ new Set());
|
|
21206
|
-
}, [h])
|
|
21207
|
-
|
|
21206
|
+
}, [h]), Ae(() => {
|
|
21207
|
+
n && !i && !r && B(/* @__PURE__ */ new Set());
|
|
21208
|
+
}, [n, i, r]);
|
|
21209
|
+
const U = (me) => L(me, n ?? !1), se = Math.max(I, Xt), ve = Math.max(te, Xt), Pe = Math.max(g, Xt), we = Math.max(J, Xt), Ee = Math.max(he, Xt), Ie = Math.max(le, Xt), H = Math.max(xe, Xt), re = Math.max(0, (a ?? 1) - b - m), E = Math.max(0, (a ?? 1) - he), z = Math.max(0, (a ?? 1) - J), q = Math.max(b, Xt), G = Math.max(0, (a ?? 1) - I - m);
|
|
21210
|
+
console.log("questionPaddingLeftMaxFraction", re);
|
|
21211
|
+
const ae = He(() => ce.size === 0 ? 0 : Math.min(...ce), [ce]), ge = ft((me) => ce.has(me), [ce]), Ne = K && v === "default" ? `${o}-entry-hover-default` : "", fe = p ?? "", be = fe !== "", Oe = $.replace(/^rotate /, ""), ie = `${o}-icon-anim-${Oe}`, Ce = St(rt(
|
|
21208
21212
|
Bi(
|
|
21209
21213
|
C,
|
|
21210
21214
|
P,
|
|
@@ -21264,7 +21268,7 @@ function Xu({ settings: e, content: t, isEditor: n, isPreviewMode: r, isEditMode
|
|
|
21264
21268
|
[`--${o}-icon-max-width`]: L(m, n ?? !1),
|
|
21265
21269
|
...u > 0 ? { [`--${o}-question-min-height`]: L(u, n ?? !1) } : {}
|
|
21266
21270
|
};
|
|
21267
|
-
return /* @__PURE__ */
|
|
21271
|
+
return /* @__PURE__ */ oe(Ge, { children: [
|
|
21268
21272
|
/* @__PURE__ */ l("style", { dangerouslySetInnerHTML: { __html: xt } }),
|
|
21269
21273
|
/* @__PURE__ */ l("div", { style: bt, children: /* @__PURE__ */ l(
|
|
21270
21274
|
"div",
|
|
@@ -21278,14 +21282,14 @@ function Xu({ settings: e, content: t, isEditor: n, isPreviewMode: r, isEditMode
|
|
|
21278
21282
|
children: ne.map((me, ze) => {
|
|
21279
21283
|
var Nt;
|
|
21280
21284
|
const Ve = ge(ze), Ze = ((Nt = me.question) == null ? void 0 : Nt.trim()) ?? "", Et = me.answer, Gt = ((Et == null ? void 0 : Et.length) ?? 0) > 0, Ct = c && ze === ae;
|
|
21281
|
-
return /* @__PURE__ */
|
|
21285
|
+
return /* @__PURE__ */ oe(
|
|
21282
21286
|
"div",
|
|
21283
21287
|
{
|
|
21284
21288
|
className: `${o}-item${Ve ? ` ${o}-item-open` : ""}`.trim(),
|
|
21285
21289
|
"data-faq-item": "",
|
|
21286
21290
|
children: [
|
|
21287
|
-
/* @__PURE__ */
|
|
21288
|
-
Ct && /* @__PURE__ */
|
|
21291
|
+
/* @__PURE__ */ oe("div", { className: `${o}-question-controls`, children: [
|
|
21292
|
+
Ct && /* @__PURE__ */ oe(Ge, { children: [
|
|
21289
21293
|
/* @__PURE__ */ l(
|
|
21290
21294
|
Qt,
|
|
21291
21295
|
{
|
|
@@ -21315,7 +21319,7 @@ function Xu({ settings: e, content: t, isEditor: n, isPreviewMode: r, isEditMode
|
|
|
21315
21319
|
"data-controls-axis": "x",
|
|
21316
21320
|
"data-controls-variant": "column-padding",
|
|
21317
21321
|
"data-controls-min": "0",
|
|
21318
|
-
"data-controls-max-fraction": String(
|
|
21322
|
+
"data-controls-max-fraction": String(re),
|
|
21319
21323
|
className: `${o}-padding-control-handle`,
|
|
21320
21324
|
hitPlacement: "center-x",
|
|
21321
21325
|
areaStyle: {
|
|
@@ -21351,7 +21355,7 @@ function Xu({ settings: e, content: t, isEditor: n, isPreviewMode: r, isEditMode
|
|
|
21351
21355
|
}
|
|
21352
21356
|
)
|
|
21353
21357
|
] }),
|
|
21354
|
-
/* @__PURE__ */
|
|
21358
|
+
/* @__PURE__ */ oe(
|
|
21355
21359
|
"button",
|
|
21356
21360
|
{
|
|
21357
21361
|
type: "button",
|
|
@@ -21373,7 +21377,7 @@ function Xu({ settings: e, content: t, isEditor: n, isPreviewMode: r, isEditMode
|
|
|
21373
21377
|
"aria-hidden": "true"
|
|
21374
21378
|
}
|
|
21375
21379
|
),
|
|
21376
|
-
/* @__PURE__ */
|
|
21380
|
+
/* @__PURE__ */ oe("span", { className: `${o}-question-row`, children: [
|
|
21377
21381
|
/* @__PURE__ */ l("span", { className: Me, children: Ze }),
|
|
21378
21382
|
Gt && (be ? /* @__PURE__ */ l("span", { className: `${o}-icon ${o}-icon-custom ${ie}`, "aria-hidden": "true", children: /* @__PURE__ */ l(
|
|
21379
21383
|
qt,
|
|
@@ -21418,8 +21422,8 @@ function Xu({ settings: e, content: t, isEditor: n, isPreviewMode: r, isEditMode
|
|
|
21418
21422
|
}
|
|
21419
21423
|
)
|
|
21420
21424
|
] }),
|
|
21421
|
-
Gt && Et && /* @__PURE__ */ l("div", { className: `${o}-panel`, "aria-hidden": !Ve, children: /* @__PURE__ */ l("div", { className: `${o}-panel-inner`, children: /* @__PURE__ */
|
|
21422
|
-
Ct && /* @__PURE__ */
|
|
21425
|
+
Gt && Et && /* @__PURE__ */ l("div", { className: `${o}-panel`, "aria-hidden": !Ve, children: /* @__PURE__ */ l("div", { className: `${o}-panel-inner`, children: /* @__PURE__ */ oe("div", { className: `${o}-answer-controls`, children: [
|
|
21426
|
+
Ct && /* @__PURE__ */ oe(Ge, { children: [
|
|
21423
21427
|
/* @__PURE__ */ l(
|
|
21424
21428
|
Qt,
|
|
21425
21429
|
{
|
|
@@ -21436,7 +21440,7 @@ function Xu({ settings: e, content: t, isEditor: n, isPreviewMode: r, isEditMode
|
|
|
21436
21440
|
top: 0,
|
|
21437
21441
|
left: 0,
|
|
21438
21442
|
width: "100%",
|
|
21439
|
-
height: U(
|
|
21443
|
+
height: U(Ie),
|
|
21440
21444
|
zIndex: 2
|
|
21441
21445
|
}
|
|
21442
21446
|
}
|
|
@@ -21983,6 +21987,12 @@ export function FAQ({ settings, content, isEditor, isPreviewMode, isEditMode, ac
|
|
|
21983
21987
|
useEffect(() => {
|
|
21984
21988
|
setOpenIndices(new Set());
|
|
21985
21989
|
}, [autoclose]);
|
|
21990
|
+
|
|
21991
|
+
useEffect(() => {
|
|
21992
|
+
if (isEditor && !isEditMode && !isPreviewMode) {
|
|
21993
|
+
setOpenIndices(new Set());
|
|
21994
|
+
}
|
|
21995
|
+
}, [isEditor, isEditMode, isPreviewMode]);
|
|
21986
21996
|
const scaled = (value: number) => scalingValue(value, isEditor ?? false);
|
|
21987
21997
|
const questionPaddingLeftWidth = Math.max(questionPaddingLeft, PADDING_HANDLE_SIZE);
|
|
21988
21998
|
const questionPaddingTopHeight = Math.max(questionPaddingTop, PADDING_HANDLE_SIZE);
|
|
@@ -21997,6 +22007,8 @@ export function FAQ({ settings, content, isEditor, isPreviewMode, isEditMode, ac
|
|
|
21997
22007
|
const iconPaddingRightWidth = Math.max(iconPaddingRight, PADDING_HANDLE_SIZE);
|
|
21998
22008
|
const iconPaddingRightMaxFraction = Math.max(0, (wrapperWidth ?? 1) - questionPaddingLeft - iconMaxWidth);
|
|
21999
22009
|
|
|
22010
|
+
console.log('questionPaddingLeftMaxFraction', questionPaddingLeftMaxFraction);
|
|
22011
|
+
|
|
22000
22012
|
const controlsTargetIndex = useMemo(() => {
|
|
22001
22013
|
if (openIndices.size === 0) {
|
|
22002
22014
|
return 0;
|