@cntrl-site/components 1.0.107-alpha.6 → 1.0.108-alpha.0
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/{Burger-EMSn7TPB.mjs → Burger-BkVgNMGU.mjs} +464 -436
- package/dist/Burger-C3yVbQcq.js +669 -0
- package/dist/{ChroniclesComponent-CccM-H_s.mjs → ChroniclesComponent-9Fi2A06B.mjs} +484 -333
- package/dist/ChroniclesComponent-DILYPR6b.js +1 -0
- package/dist/Components/Burger/Burger.d.ts +3 -0
- package/dist/Components/Burger/BurgerComponent.d.ts +32 -0
- package/dist/Components/Hive/Hive.d.ts +16 -0
- package/dist/Components/Hive/HiveComponent.d.ts +3 -1
- package/dist/Hive-CzabuuCc.js +328 -0
- package/dist/Hive-DyxYd5eg.mjs +1504 -0
- package/dist/{components-C_iy6uBo.js → components-BJdVsqb6.js} +1 -1
- package/dist/{components-DNKhvmUV.mjs → components-Qpn7IZ0W.mjs} +1 -1
- package/dist/elements.js +1 -1
- package/dist/elements.mjs +2 -2
- package/dist/elements.node.js +1 -1
- package/dist/elements.node.mjs +1 -1
- package/dist/index.js +1 -1
- package/dist/index.mjs +2 -2
- package/dist/sources.js +128 -21
- package/dist/sources.mjs +128 -21
- package/dist/types/Component.d.ts +5 -0
- package/package.json +1 -1
- package/dist/Burger-C6jI6C1c.js +0 -661
- package/dist/ChroniclesComponent-BazDuget.js +0 -1
- package/dist/Hive-BsmFHk2i.mjs +0 -1458
- package/dist/Hive-D1j6wZpV.js +0 -321
|
@@ -1,43 +1,45 @@
|
|
|
1
|
-
import { jsxs as C, jsx as s, Fragment as
|
|
2
|
-
import { useRef as S, useMemo as uo, useState as I, useEffect as N, useLayoutEffect as mo, Fragment as
|
|
1
|
+
import { jsxs as C, jsx as s, Fragment as In } from "react/jsx-runtime";
|
|
2
|
+
import { useRef as S, useMemo as uo, useState as I, useEffect as N, useLayoutEffect as mo, Fragment as _o } from "react";
|
|
3
3
|
import { s as A } from "./scalingValue-C9JH5L6O.mjs";
|
|
4
|
-
import { b as
|
|
5
|
-
import { u as
|
|
6
|
-
import { u as
|
|
7
|
-
import { o as
|
|
8
|
-
import { i as
|
|
9
|
-
const y = 300, v = 300,
|
|
10
|
-
function
|
|
4
|
+
import { b as Rn } from "./buildColorVars-CLyWQm5K.mjs";
|
|
5
|
+
import { u as _n } from "./useScopedStyles-DhBG3557.mjs";
|
|
6
|
+
import { u as Mn } from "./useLightboxScrollLock-VQ07s7EJ.mjs";
|
|
7
|
+
import { o as Wn, t as En } from "./textStylesToCss-05Mn6I_2.mjs";
|
|
8
|
+
import { i as $t, l as Gn } from "./loadSvgMaskUrl-xHgGYgPe.mjs";
|
|
9
|
+
const y = 300, v = 300, Dn = 8 / 1440, U = 4e-3, Un = 50, Vn = 1440, M = Un / Vn;
|
|
10
|
+
function jn(o) {
|
|
11
11
|
if (o === "default" || o === "compact" || o === "open") return o;
|
|
12
12
|
if (o === "onScroll") return "compact";
|
|
13
13
|
}
|
|
14
|
-
function
|
|
14
|
+
function Xn(o) {
|
|
15
15
|
return o === "center" || o === "right" ? o : "left";
|
|
16
16
|
}
|
|
17
|
-
function
|
|
17
|
+
function Yn(o) {
|
|
18
18
|
return o === "left" || o === "right" ? o : "center";
|
|
19
19
|
}
|
|
20
|
-
function
|
|
21
|
-
const
|
|
22
|
-
return o === "center" ? `translateX(calc(-50% + ${
|
|
20
|
+
function Kn(o, t, e) {
|
|
21
|
+
const n = A(t, e);
|
|
22
|
+
return o === "center" ? `translateX(calc(-50% + ${n}))` : `translateX(${n})`;
|
|
23
23
|
}
|
|
24
|
-
function
|
|
24
|
+
function qn(o, t) {
|
|
25
25
|
if (o && typeof o == "object") {
|
|
26
26
|
if (t && typeof o[t] == "string") return o[t];
|
|
27
|
-
for (const
|
|
28
|
-
if (typeof o[
|
|
27
|
+
for (const e in o)
|
|
28
|
+
if (typeof o[e] == "string") return o[e];
|
|
29
29
|
return;
|
|
30
30
|
}
|
|
31
31
|
return o;
|
|
32
32
|
}
|
|
33
|
-
function
|
|
34
|
-
const
|
|
35
|
-
return
|
|
33
|
+
function Eo(o, t) {
|
|
34
|
+
const e = (qn(o, t) ?? "always").trim().toLowerCase().replace(/[_-]+/g, " ");
|
|
35
|
+
return e === "open only" || e === "openonly" ? "open only" : e === "default only" || e === "defaultonly" ? "default only" : e === "open and compact" || e === "openandcompact" ? "open and compact" : e === "default and open" || e === "defaultandopen" ? "default and open" : e === "default and compact" || e === "defaultandcompact" ? "default and compact" : "always";
|
|
36
36
|
}
|
|
37
|
-
function
|
|
38
|
-
switch (
|
|
37
|
+
function Zn(o, t, e) {
|
|
38
|
+
switch (Eo(o.showIn, e)) {
|
|
39
39
|
case "open only":
|
|
40
40
|
return !1;
|
|
41
|
+
case "default only":
|
|
42
|
+
return t === "default";
|
|
41
43
|
case "open and compact":
|
|
42
44
|
return t === "compact";
|
|
43
45
|
case "default and compact":
|
|
@@ -48,54 +50,61 @@ function Un(o, t, n) {
|
|
|
48
50
|
return !0;
|
|
49
51
|
}
|
|
50
52
|
}
|
|
51
|
-
function
|
|
52
|
-
switch (
|
|
53
|
+
function Jn(o, t) {
|
|
54
|
+
switch (Eo(o.showIn, t)) {
|
|
55
|
+
case "default only":
|
|
53
56
|
case "default and compact":
|
|
54
57
|
return !1;
|
|
55
58
|
default:
|
|
56
59
|
return !0;
|
|
57
60
|
}
|
|
58
61
|
}
|
|
59
|
-
function
|
|
62
|
+
function Qn(o, t) {
|
|
63
|
+
return !Array.isArray(o) || o.length === 0 ? !0 : o.some((e) => Eo(e == null ? void 0 : e.showIn, t) !== "default only");
|
|
64
|
+
}
|
|
65
|
+
function Pn(o) {
|
|
60
66
|
return (o == null ? void 0 : o.find((t) => t.slug === "")) ?? (o == null ? void 0 : o[0]);
|
|
61
67
|
}
|
|
62
|
-
function
|
|
63
|
-
const
|
|
64
|
-
return !o && !
|
|
68
|
+
function oa(o, t) {
|
|
69
|
+
const e = o ? t == null ? void 0 : t.find((n) => n.id === o) : Pn(t);
|
|
70
|
+
return !o && !e ? "" : e ? e.slug === "" ? "/" : `/${e.slug}` : o.startsWith("/") || o.startsWith("#") || /^[a-z][a-z\d+\-.]*:/i.test(o) ? o : t ? `/${o}` : o;
|
|
65
71
|
}
|
|
66
|
-
function
|
|
72
|
+
function ut(o) {
|
|
67
73
|
const t = (o ?? "").toLowerCase();
|
|
68
74
|
return t === "blank" || t === "_blank" || t.includes("new");
|
|
69
75
|
}
|
|
70
|
-
function
|
|
76
|
+
function zt(o) {
|
|
71
77
|
const t = o.link;
|
|
72
78
|
if (t && typeof t == "object") {
|
|
73
|
-
const
|
|
79
|
+
const n = ut(t.target) ? "_blank" : void 0;
|
|
74
80
|
if (t.type === "url")
|
|
75
|
-
return { type: "url", value: t.value ?? t.url ?? "", target:
|
|
81
|
+
return { type: "url", value: t.value ?? t.url ?? "", target: n };
|
|
76
82
|
if (t.type === "anchor")
|
|
77
|
-
return { type: "anchor", value: t.value ?? "", target:
|
|
83
|
+
return { type: "anchor", value: t.value ?? "", target: n };
|
|
78
84
|
if (t.type === "page")
|
|
79
|
-
return { type: "page", value: t.value ?? "", target:
|
|
85
|
+
return { type: "page", value: t.value ?? "", target: n, anchor: t.anchor };
|
|
80
86
|
if (typeof t.url == "string")
|
|
81
|
-
return { type: "url", value: t.url, target:
|
|
87
|
+
return { type: "url", value: t.url, target: n };
|
|
82
88
|
}
|
|
83
|
-
const
|
|
84
|
-
return o.mode === "url" ? { type: "url", value: o.url ?? "", target:
|
|
85
|
-
}
|
|
86
|
-
function
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
return { label:
|
|
89
|
+
const e = ut(o.openIn) ? "_blank" : void 0;
|
|
90
|
+
return o.mode === "url" ? { type: "url", value: o.url ?? "", target: e } : { type: "page", value: o.page ?? "", target: e, anchor: o.anchor };
|
|
91
|
+
}
|
|
92
|
+
function ta(o) {
|
|
93
|
+
return /^[a-z][a-z\d+\-.]*:/i.test(o) || o.startsWith("/") || o.startsWith("#") ? o : `https://${o}`;
|
|
94
|
+
}
|
|
95
|
+
function Mo(o, t) {
|
|
96
|
+
const e = o.label || "Link", n = zt(o);
|
|
97
|
+
if (n.type === "url")
|
|
98
|
+
return { label: e, href: n.value, target: n.target };
|
|
99
|
+
if (n.type === "anchor") {
|
|
100
|
+
const p = n.value.replace(/^#/, "");
|
|
101
|
+
return { label: e, href: p ? `#${p}` : "", target: n.target };
|
|
93
102
|
}
|
|
94
|
-
const r =
|
|
95
|
-
return { label:
|
|
103
|
+
const r = oa(n.value, t), c = (n.anchor ?? "").replace(/^#/, ""), g = c ? r ? `${r}#${c}` : `#${c}` : r;
|
|
104
|
+
return { label: e, href: g, target: n.target };
|
|
96
105
|
}
|
|
97
|
-
const R = 24, F = R * 0.125,
|
|
98
|
-
function
|
|
106
|
+
const R = 24, F = R * 0.125, Bt = R * 0.125, Ro = (R - (3 * F + 2 * Bt)) / 2, mt = F + Bt;
|
|
107
|
+
function ea({ className: o, lineClassName: t }) {
|
|
99
108
|
return /* @__PURE__ */ C(
|
|
100
109
|
"svg",
|
|
101
110
|
{
|
|
@@ -108,7 +117,7 @@ function Yn({ className: o, lineClassName: t }) {
|
|
|
108
117
|
{
|
|
109
118
|
className: `${t} ${t}-top`,
|
|
110
119
|
x: "0",
|
|
111
|
-
y:
|
|
120
|
+
y: Ro,
|
|
112
121
|
width: R,
|
|
113
122
|
height: F,
|
|
114
123
|
rx: F / 2
|
|
@@ -119,7 +128,7 @@ function Yn({ className: o, lineClassName: t }) {
|
|
|
119
128
|
{
|
|
120
129
|
className: `${t} ${t}-mid`,
|
|
121
130
|
x: "0",
|
|
122
|
-
y:
|
|
131
|
+
y: Ro + mt,
|
|
123
132
|
width: R,
|
|
124
133
|
height: F,
|
|
125
134
|
rx: F / 2
|
|
@@ -130,7 +139,7 @@ function Yn({ className: o, lineClassName: t }) {
|
|
|
130
139
|
{
|
|
131
140
|
className: `${t} ${t}-bot`,
|
|
132
141
|
x: "0",
|
|
133
|
-
y:
|
|
142
|
+
y: Ro + 2 * mt,
|
|
134
143
|
width: R,
|
|
135
144
|
height: F,
|
|
136
145
|
rx: F / 2
|
|
@@ -140,37 +149,37 @@ function Yn({ className: o, lineClassName: t }) {
|
|
|
140
149
|
}
|
|
141
150
|
);
|
|
142
151
|
}
|
|
143
|
-
function
|
|
144
|
-
return t !== void 0 && t < (o ?? 0.01) ? `${
|
|
152
|
+
function na(o, t, e, n) {
|
|
153
|
+
return t !== void 0 && t < (o ?? 0.01) ? `${e} ${n}` : e;
|
|
145
154
|
}
|
|
146
|
-
function
|
|
155
|
+
function aa(o, t, e, n) {
|
|
147
156
|
const r = o ?? 0.01;
|
|
148
157
|
return t === void 0 || t >= r ? {} : {
|
|
149
|
-
[`--${
|
|
158
|
+
[`--${e}-text-leading-gap`]: A((r - t) / 2, n)
|
|
150
159
|
};
|
|
151
160
|
}
|
|
152
|
-
const
|
|
161
|
+
const Ht = 4e-3;
|
|
153
162
|
let no;
|
|
154
|
-
function
|
|
163
|
+
function ra() {
|
|
155
164
|
return no !== void 0 ? no : typeof document > "u" ? (no = null, null) : (no = document.createElement("canvas").getContext("2d"), no);
|
|
156
165
|
}
|
|
157
|
-
function
|
|
158
|
-
const t = getComputedStyle(o),
|
|
159
|
-
if (
|
|
160
|
-
const
|
|
161
|
-
if (!
|
|
162
|
-
|
|
163
|
-
const r =
|
|
164
|
-
return c <= 0 || p <= 0 && d <= 0 ? 0 : (d - g - (p - c)) / 2 /
|
|
165
|
-
}
|
|
166
|
-
function
|
|
167
|
-
const [
|
|
166
|
+
function ia(o) {
|
|
167
|
+
const t = getComputedStyle(o), e = parseFloat(t.fontSize) || 0;
|
|
168
|
+
if (e <= 0) return 0;
|
|
169
|
+
const n = ra();
|
|
170
|
+
if (!n) return 0;
|
|
171
|
+
n.font = `${t.fontStyle} ${t.fontWeight} ${e}px ${t.fontFamily}`;
|
|
172
|
+
const r = n.measureText("H"), c = r.actualBoundingBoxAscent > 0 ? r.actualBoundingBoxAscent : 0, g = Math.max(0, r.actualBoundingBoxDescent || 0), p = r.fontBoundingBoxAscent || 0, d = r.fontBoundingBoxDescent || 0;
|
|
173
|
+
return c <= 0 || p <= 0 && d <= 0 ? 0 : (d - g - (p - c)) / 2 / e;
|
|
174
|
+
}
|
|
175
|
+
function xt(o, t) {
|
|
176
|
+
const [e, n] = I(0);
|
|
168
177
|
return mo(() => {
|
|
169
178
|
const r = o.current;
|
|
170
179
|
if (!r) return;
|
|
171
180
|
const c = () => {
|
|
172
|
-
const d =
|
|
173
|
-
|
|
181
|
+
const d = ia(r);
|
|
182
|
+
n((u) => Math.abs(u - d) < Ht ? u : d);
|
|
174
183
|
};
|
|
175
184
|
c();
|
|
176
185
|
const g = document.fonts;
|
|
@@ -180,23 +189,23 @@ function pt(o, t) {
|
|
|
180
189
|
return p.observe(r), () => {
|
|
181
190
|
g.removeEventListener("loadingdone", c), p.disconnect();
|
|
182
191
|
};
|
|
183
|
-
}, [o, t]),
|
|
192
|
+
}, [o, t]), e;
|
|
184
193
|
}
|
|
185
|
-
function
|
|
186
|
-
if (!(Math.abs(o) <
|
|
194
|
+
function kt(o) {
|
|
195
|
+
if (!(Math.abs(o) < Ht))
|
|
187
196
|
return `translateY(${o}em)`;
|
|
188
197
|
}
|
|
189
|
-
function
|
|
190
|
-
var t,
|
|
198
|
+
function bt(o) {
|
|
199
|
+
var t, e;
|
|
191
200
|
return [
|
|
192
201
|
o.fontFamily ?? "",
|
|
193
202
|
((t = o.fontSettings) == null ? void 0 : t.fontWeight) ?? 400,
|
|
194
|
-
((
|
|
203
|
+
((e = o.fontSettings) == null ? void 0 : e.fontStyle) ?? "normal",
|
|
195
204
|
o.fontSize ?? "",
|
|
196
205
|
o.lineHeight ?? ""
|
|
197
206
|
].join("\0");
|
|
198
207
|
}
|
|
199
|
-
function
|
|
208
|
+
function St(o) {
|
|
200
209
|
return {
|
|
201
210
|
fontFamily: o.fontFamily,
|
|
202
211
|
fontWeight: o.fontWeight,
|
|
@@ -211,7 +220,7 @@ function $t(o) {
|
|
|
211
220
|
whiteSpace: "nowrap"
|
|
212
221
|
};
|
|
213
222
|
}
|
|
214
|
-
function
|
|
223
|
+
function yt(o, t = {}) {
|
|
215
224
|
return {
|
|
216
225
|
fontFamily: o.fontFamily ?? t.fontFamily,
|
|
217
226
|
fontSettings: o.fontSettings ?? t.fontSettings,
|
|
@@ -223,9 +232,9 @@ function ut(o, t = {}) {
|
|
|
223
232
|
textAppearance: o.textAppearance ?? t.textAppearance
|
|
224
233
|
};
|
|
225
234
|
}
|
|
226
|
-
function
|
|
235
|
+
function Ct(o, t, e) {
|
|
227
236
|
var r, c;
|
|
228
|
-
const
|
|
237
|
+
const n = {
|
|
229
238
|
fontSettings: {
|
|
230
239
|
fontFamily: t.fontFamily,
|
|
231
240
|
fontWeight: ((r = t.fontSettings) == null ? void 0 : r.fontWeight) ?? 400,
|
|
@@ -241,10 +250,10 @@ function mt(o, t, n) {
|
|
|
241
250
|
};
|
|
242
251
|
return {
|
|
243
252
|
css: {
|
|
244
|
-
...
|
|
245
|
-
...
|
|
253
|
+
...Wn(En(n, e)),
|
|
254
|
+
...aa(t.fontSize, t.lineHeight, o, e)
|
|
246
255
|
},
|
|
247
|
-
className:
|
|
256
|
+
className: na(
|
|
248
257
|
t.fontSize,
|
|
249
258
|
t.lineHeight,
|
|
250
259
|
`${o}-link-text`,
|
|
@@ -252,15 +261,15 @@ function mt(o, t, n) {
|
|
|
252
261
|
)
|
|
253
262
|
};
|
|
254
263
|
}
|
|
255
|
-
function
|
|
264
|
+
function Lt(o) {
|
|
256
265
|
const t = o.split(/\r?\n/);
|
|
257
|
-
return t.length === 1 ? o : t.map((
|
|
258
|
-
|
|
259
|
-
|
|
260
|
-
] },
|
|
266
|
+
return t.length === 1 ? o : t.map((e, n) => /* @__PURE__ */ C(_o, { children: [
|
|
267
|
+
e,
|
|
268
|
+
n < t.length - 1 ? /* @__PURE__ */ s("br", {}) : null
|
|
269
|
+
] }, n));
|
|
261
270
|
}
|
|
262
|
-
function
|
|
263
|
-
const r = Math.max(0,
|
|
271
|
+
function wt(o, t, e, n) {
|
|
272
|
+
const r = Math.max(0, e - n), c = o + t;
|
|
264
273
|
if (c <= r || c <= 0)
|
|
265
274
|
return { start: o, end: t };
|
|
266
275
|
const g = r / c;
|
|
@@ -269,13 +278,13 @@ function kt(o, t, n, e) {
|
|
|
269
278
|
end: t * g
|
|
270
279
|
};
|
|
271
280
|
}
|
|
272
|
-
function
|
|
273
|
-
const
|
|
281
|
+
function Ot(o) {
|
|
282
|
+
const e = Math.max(M, o.fontSize ?? M), { start: n, end: r } = wt(
|
|
274
283
|
o.textPaddingTop,
|
|
275
284
|
o.textPaddingBottom,
|
|
276
285
|
1,
|
|
277
|
-
|
|
278
|
-
), { start: c, end: g } =
|
|
286
|
+
e
|
|
287
|
+
), { start: c, end: g } = wt(
|
|
279
288
|
o.textPaddingLeft,
|
|
280
289
|
o.textPaddingRight,
|
|
281
290
|
1,
|
|
@@ -284,27 +293,27 @@ function Nt(o) {
|
|
|
284
293
|
return {
|
|
285
294
|
effectivePaddingLeft: c,
|
|
286
295
|
effectivePaddingRight: g,
|
|
287
|
-
effectivePaddingTop:
|
|
296
|
+
effectivePaddingTop: n,
|
|
288
297
|
effectivePaddingBottom: r,
|
|
289
298
|
panelSize: 1
|
|
290
299
|
};
|
|
291
300
|
}
|
|
292
|
-
function
|
|
301
|
+
function ca(o) {
|
|
293
302
|
if (o === "center" || o === "center-center")
|
|
294
303
|
return { horizontalAlign: "center", verticalAlign: "center" };
|
|
295
|
-
const [t,
|
|
296
|
-
return { horizontalAlign: t, verticalAlign:
|
|
304
|
+
const [t, e] = o.split("-");
|
|
305
|
+
return { horizontalAlign: t, verticalAlign: e };
|
|
297
306
|
}
|
|
298
|
-
function
|
|
299
|
-
return o.position ?
|
|
307
|
+
function la(o) {
|
|
308
|
+
return o.position ? ca(o.position) : {
|
|
300
309
|
horizontalAlign: o.horizontalAlign ?? "left",
|
|
301
310
|
verticalAlign: o.verticalAlign ?? "top"
|
|
302
311
|
};
|
|
303
312
|
}
|
|
304
|
-
function
|
|
313
|
+
function sa(o, t) {
|
|
305
314
|
return o.textPaddingLeft !== t.textPaddingLeft || o.textPaddingRight !== t.textPaddingRight || o.textPaddingTop !== t.textPaddingTop || o.textPaddingBottom !== t.textPaddingBottom;
|
|
306
315
|
}
|
|
307
|
-
const
|
|
316
|
+
const da = [
|
|
308
317
|
["onScrollIconColor", "compactIconColor"],
|
|
309
318
|
["onScrollLinkColor", "compactLinkColor"],
|
|
310
319
|
["onScrollLogoColor", "compactLogoColor"],
|
|
@@ -328,61 +337,61 @@ const ta = [
|
|
|
328
337
|
["onScrollTextAlign", "compactTextAlign"],
|
|
329
338
|
["onScrollTextAppearance", "compactTextAppearance"]
|
|
330
339
|
];
|
|
331
|
-
function
|
|
340
|
+
function Ft(o) {
|
|
332
341
|
var r, c;
|
|
333
|
-
const t = o,
|
|
334
|
-
for (const [g, p] of
|
|
335
|
-
o[p] !== void 0 || t[g] === void 0 || (
|
|
336
|
-
const
|
|
337
|
-
return
|
|
342
|
+
const t = o, e = {};
|
|
343
|
+
for (const [g, p] of da)
|
|
344
|
+
o[p] !== void 0 || t[g] === void 0 || (e[p] = t[g]);
|
|
345
|
+
const n = t.stateOverrides;
|
|
346
|
+
return n && (n.onScroll !== void 0 || n["onScroll-hover"] !== void 0) && (e.stateOverrides = { ...o.stateOverrides }, n.onScroll !== void 0 && ((r = o.stateOverrides) == null ? void 0 : r.compact) === void 0 && (e.stateOverrides.compact = n.onScroll), n["onScroll-hover"] !== void 0 && ((c = o.stateOverrides) == null ? void 0 : c["compact-hover"]) === void 0 && (e.stateOverrides["compact-hover"] = n["onScroll-hover"])), Object.keys(e).length === 0 ? o : { ...o, ...e };
|
|
338
347
|
}
|
|
339
|
-
function
|
|
348
|
+
function Tt(o) {
|
|
340
349
|
var r, c, g, p, d, u, L, z, m, a, B, V, j, X, Y, O;
|
|
341
|
-
o =
|
|
342
|
-
const t = o,
|
|
343
|
-
if (o.backgroundColor === void 0 && t.panelColor !== void 0 && (
|
|
350
|
+
o = Ft(o);
|
|
351
|
+
const t = o, e = {};
|
|
352
|
+
if (o.backgroundColor === void 0 && t.panelColor !== void 0 && (e.backgroundColor = t.panelColor), o.openFontFamily === void 0 && o.fontFamily !== void 0 && (e.openFontFamily = o.fontFamily), o.openFontSettings === void 0 && o.fontSettings !== void 0 && (e.openFontSettings = o.fontSettings), o.openFontSize === void 0 && o.fontSize !== void 0 && (e.openFontSize = o.fontSize), o.openLineHeight === void 0 && o.lineHeight !== void 0 && (e.openLineHeight = o.lineHeight), o.openLetterSpacing === void 0 && o.letterSpacing !== void 0 && (e.openLetterSpacing = o.letterSpacing), o.openWordSpacing === void 0 && o.wordSpacing !== void 0 && (e.openWordSpacing = o.wordSpacing), o.openTextAlign === void 0 && o.textAlign !== void 0 && (e.openTextAlign = o.textAlign), o.openTextAppearance === void 0 && o.textAppearance !== void 0 && (e.openTextAppearance = o.textAppearance), o.openLinkColor === void 0) {
|
|
344
353
|
const f = ((c = (r = o.stateOverrides) == null ? void 0 : r.open) == null ? void 0 : c.openLinkColor) ?? ((p = (g = o.stateOverrides) == null ? void 0 : g.open) == null ? void 0 : p.linkColor) ?? o.linkColor;
|
|
345
|
-
f !== void 0 && (
|
|
354
|
+
f !== void 0 && (e.openLinkColor = f);
|
|
346
355
|
}
|
|
347
356
|
if (o.compactIconColor === void 0) {
|
|
348
357
|
const f = ((u = (d = o.stateOverrides) == null ? void 0 : d.compact) == null ? void 0 : u.iconColor) ?? o.iconColor;
|
|
349
|
-
f !== void 0 && (
|
|
358
|
+
f !== void 0 && (e.compactIconColor = f);
|
|
350
359
|
}
|
|
351
360
|
if (o.compactLinkColor === void 0) {
|
|
352
361
|
const f = ((z = (L = o.stateOverrides) == null ? void 0 : L.compact) == null ? void 0 : z.linkColor) ?? o.linkColor;
|
|
353
|
-
f !== void 0 && (
|
|
362
|
+
f !== void 0 && (e.compactLinkColor = f);
|
|
354
363
|
}
|
|
355
364
|
if (o.compactLogoColor === void 0) {
|
|
356
365
|
const f = ((a = (m = o.stateOverrides) == null ? void 0 : m.compact) == null ? void 0 : a.logoColor) ?? o.logoColor;
|
|
357
|
-
f !== void 0 && (
|
|
366
|
+
f !== void 0 && (e.compactLogoColor = f);
|
|
358
367
|
}
|
|
359
368
|
if (o.openLogoColor === void 0) {
|
|
360
369
|
const f = ((V = (B = o.stateOverrides) == null ? void 0 : B.open) == null ? void 0 : V.logoColor) ?? o.logoColor;
|
|
361
|
-
f !== void 0 && (
|
|
370
|
+
f !== void 0 && (e.openLogoColor = f);
|
|
362
371
|
}
|
|
363
372
|
if (o.compactBackgroundColor === void 0) {
|
|
364
|
-
const f = ((X = (j = o.stateOverrides) == null ? void 0 : j.compact) == null ? void 0 : X.backgroundColor) ?? ((O = (Y = t.stateOverrides) == null ? void 0 : Y.compact) == null ? void 0 : O.panelColor) ?? t.compactPanelColor ?? t.onScrollPanelColor ?? o.backgroundColor ??
|
|
365
|
-
f !== void 0 && (
|
|
373
|
+
const f = ((X = (j = o.stateOverrides) == null ? void 0 : j.compact) == null ? void 0 : X.backgroundColor) ?? ((O = (Y = t.stateOverrides) == null ? void 0 : Y.compact) == null ? void 0 : O.panelColor) ?? t.compactPanelColor ?? t.onScrollPanelColor ?? o.backgroundColor ?? e.backgroundColor;
|
|
374
|
+
f !== void 0 && (e.compactBackgroundColor = f);
|
|
366
375
|
}
|
|
367
|
-
o.logoMaxHeight === void 0 && o.logoMaxWidth !== void 0 && (
|
|
368
|
-
const
|
|
376
|
+
o.logoMaxHeight === void 0 && o.logoMaxWidth !== void 0 && (e.logoMaxHeight = o.logoMaxWidth), o.compactLogoMaxHeight === void 0 && o.compactLogoMaxWidth !== void 0 && (e.compactLogoMaxHeight = o.compactLogoMaxWidth);
|
|
377
|
+
const n = (f, K) => {
|
|
369
378
|
if (o[f] !== void 0) return;
|
|
370
379
|
const q = o[K];
|
|
371
|
-
q !== void 0 && (
|
|
380
|
+
q !== void 0 && (e[f] = q);
|
|
372
381
|
};
|
|
373
|
-
return
|
|
382
|
+
return n("compactLogoMaxHeight", "logoMaxHeight"), n("compactLogoPosition", "logoPosition"), n("compactPanelHeight", "panelHeight"), n("compactShowIcon", "showIcon"), n("compactIconSize", "iconSize"), n("compactNavTextWidth", "navTextWidth"), n("compactNavTextPosition", "navTextPosition"), n("compactNavTextOffset", "navTextOffset"), n("compactNavGap", "navGap"), n("compactNavPaddingLeft", "navPaddingLeft"), n("compactNavPaddingRight", "navPaddingRight"), n("compactFontFamily", "fontFamily"), n("compactFontSettings", "fontSettings"), n("compactFontSize", "fontSize"), n("compactLineHeight", "lineHeight"), n("compactLetterSpacing", "letterSpacing"), n("compactWordSpacing", "wordSpacing"), n("compactTextAlign", "textAlign"), n("compactTextAppearance", "textAppearance"), Object.keys(e).length === 0 ? o : { ...o, ...e };
|
|
374
383
|
}
|
|
375
|
-
function
|
|
376
|
-
const
|
|
384
|
+
function ga(o, t) {
|
|
385
|
+
const e = Ot({
|
|
377
386
|
textPaddingLeft: o.textPaddingLeft ?? 0,
|
|
378
387
|
textPaddingRight: o.textPaddingRight ?? 0,
|
|
379
388
|
textPaddingTop: o.textPaddingTop ?? 0,
|
|
380
389
|
textPaddingBottom: o.textPaddingBottom ?? 0,
|
|
381
390
|
fontSize: o.openFontSize ?? o.fontSize ?? t.openFontSize ?? t.fontSize
|
|
382
|
-
}),
|
|
383
|
-
return (o.textPaddingLeft ?? 0) !==
|
|
391
|
+
}), n = {};
|
|
392
|
+
return (o.textPaddingLeft ?? 0) !== e.effectivePaddingLeft && (n.textPaddingLeft = e.effectivePaddingLeft), (o.textPaddingRight ?? 0) !== e.effectivePaddingRight && (n.textPaddingRight = e.effectivePaddingRight), (o.textPaddingTop ?? 0) !== e.effectivePaddingTop && (n.textPaddingTop = e.effectivePaddingTop), (o.textPaddingBottom ?? 0) !== e.effectivePaddingBottom && (n.textPaddingBottom = e.effectivePaddingBottom), Object.keys(n).length === 0 ? o : { ...o, ...n };
|
|
384
393
|
}
|
|
385
|
-
function
|
|
394
|
+
function fa(o, t) {
|
|
386
395
|
return {
|
|
387
396
|
paddingLeft: A(o.effectivePaddingLeft, t),
|
|
388
397
|
paddingRight: A(o.effectivePaddingRight, t),
|
|
@@ -390,9 +399,9 @@ function na(o, t) {
|
|
|
390
399
|
paddingBottom: A(o.effectivePaddingBottom, t)
|
|
391
400
|
};
|
|
392
401
|
}
|
|
393
|
-
function
|
|
394
|
-
const r = Math.max(M,
|
|
395
|
-
return /* @__PURE__ */ C(
|
|
402
|
+
function pa(o, t, e, n) {
|
|
403
|
+
const r = Math.max(M, e ?? M), c = Math.max(t.effectivePaddingTop, U), g = Math.max(t.effectivePaddingBottom, U), p = Math.max(0, t.panelSize - t.effectivePaddingBottom - r), d = Math.max(0, t.panelSize - t.effectivePaddingTop - r), u = Math.max(t.effectivePaddingLeft, U), L = Math.max(t.effectivePaddingRight, U), z = Math.max(0, t.panelSize - t.effectivePaddingRight - M), m = Math.max(0, t.panelSize - t.effectivePaddingLeft - M);
|
|
404
|
+
return /* @__PURE__ */ C(In, { children: [
|
|
396
405
|
/* @__PURE__ */ s(
|
|
397
406
|
"div",
|
|
398
407
|
{
|
|
@@ -402,7 +411,7 @@ function aa(o, t, n, e) {
|
|
|
402
411
|
"data-controls-min": "0",
|
|
403
412
|
"data-controls-max-fraction": String(p),
|
|
404
413
|
className: `${o}-control-anchor`,
|
|
405
|
-
style: { top: 0, left: 0, width: "100%", height:
|
|
414
|
+
style: { top: 0, left: 0, width: "100%", height: n(c) }
|
|
406
415
|
}
|
|
407
416
|
),
|
|
408
417
|
/* @__PURE__ */ s(
|
|
@@ -415,7 +424,7 @@ function aa(o, t, n, e) {
|
|
|
415
424
|
"data-controls-min": "0",
|
|
416
425
|
"data-controls-max-fraction": String(d),
|
|
417
426
|
className: `${o}-control-anchor`,
|
|
418
|
-
style: { bottom: 0, left: 0, width: "100%", height:
|
|
427
|
+
style: { bottom: 0, left: 0, width: "100%", height: n(g) }
|
|
419
428
|
}
|
|
420
429
|
),
|
|
421
430
|
/* @__PURE__ */ s(
|
|
@@ -427,7 +436,7 @@ function aa(o, t, n, e) {
|
|
|
427
436
|
"data-controls-min": "0",
|
|
428
437
|
"data-controls-max-fraction": String(z),
|
|
429
438
|
className: `${o}-control-anchor`,
|
|
430
|
-
style: { top: 0, left: 0, width:
|
|
439
|
+
style: { top: 0, left: 0, width: n(u), height: "100%" }
|
|
431
440
|
}
|
|
432
441
|
),
|
|
433
442
|
/* @__PURE__ */ s(
|
|
@@ -440,12 +449,12 @@ function aa(o, t, n, e) {
|
|
|
440
449
|
"data-controls-min": "0",
|
|
441
450
|
"data-controls-max-fraction": String(m),
|
|
442
451
|
className: `${o}-control-anchor`,
|
|
443
|
-
style: { top: 0, right: 0, width:
|
|
452
|
+
style: { top: 0, right: 0, width: n(L), height: "100%" }
|
|
444
453
|
}
|
|
445
454
|
)
|
|
446
455
|
] });
|
|
447
456
|
}
|
|
448
|
-
const
|
|
457
|
+
const va = {
|
|
449
458
|
iconColor: "icon-color",
|
|
450
459
|
closeButtonColor: "close-button-color",
|
|
451
460
|
linkColor: "link-color",
|
|
@@ -459,16 +468,16 @@ const ra = {
|
|
|
459
468
|
overlayColor: "overlay-color",
|
|
460
469
|
backgroundColor: "background-color",
|
|
461
470
|
logoColor: "logo-color"
|
|
462
|
-
},
|
|
471
|
+
}, ha = ["hover", "open"], $a = {
|
|
463
472
|
top: "flex-start",
|
|
464
473
|
center: "center",
|
|
465
474
|
bottom: "flex-end"
|
|
466
|
-
},
|
|
475
|
+
}, ua = {
|
|
467
476
|
left: "flex-start",
|
|
468
477
|
center: "center",
|
|
469
478
|
right: "flex-end"
|
|
470
479
|
};
|
|
471
|
-
function
|
|
480
|
+
function ma(o) {
|
|
472
481
|
return `
|
|
473
482
|
.${o}-root {
|
|
474
483
|
position: relative;
|
|
@@ -820,6 +829,14 @@ function sa(o) {
|
|
|
820
829
|
right: 0;
|
|
821
830
|
transform: none;
|
|
822
831
|
}
|
|
832
|
+
.${o}-nav-logo-link {
|
|
833
|
+
display: flex;
|
|
834
|
+
align-items: center;
|
|
835
|
+
height: 100%;
|
|
836
|
+
color: inherit;
|
|
837
|
+
text-decoration: none;
|
|
838
|
+
cursor: pointer;
|
|
839
|
+
}
|
|
823
840
|
.${o}-nav-logo-inner {
|
|
824
841
|
position: relative;
|
|
825
842
|
flex-shrink: 0;
|
|
@@ -1131,13 +1148,13 @@ function sa(o) {
|
|
|
1131
1148
|
}
|
|
1132
1149
|
`;
|
|
1133
1150
|
}
|
|
1134
|
-
function
|
|
1151
|
+
function Wo(o) {
|
|
1135
1152
|
return o ? !o.startsWith("http://") && !o.startsWith("https://") && !o.startsWith("blob:") && !o.startsWith("data:") : !1;
|
|
1136
1153
|
}
|
|
1137
|
-
function
|
|
1138
|
-
var
|
|
1139
|
-
const
|
|
1140
|
-
return !o.logo ||
|
|
1154
|
+
function xa(o, t) {
|
|
1155
|
+
var n;
|
|
1156
|
+
const e = (n = o.logo) == null ? void 0 : n.icon;
|
|
1157
|
+
return !o.logo || Wo(e) || !t ? o : {
|
|
1141
1158
|
...o,
|
|
1142
1159
|
logo: {
|
|
1143
1160
|
...o.logo,
|
|
@@ -1145,62 +1162,62 @@ function da(o, t) {
|
|
|
1145
1162
|
}
|
|
1146
1163
|
};
|
|
1147
1164
|
}
|
|
1148
|
-
function
|
|
1165
|
+
function ka(o) {
|
|
1149
1166
|
return `url("${o.replace(/\\/g, "\\\\").replace(/"/g, '\\"')}")`;
|
|
1150
1167
|
}
|
|
1151
|
-
function
|
|
1168
|
+
function ba(o) {
|
|
1152
1169
|
const t = o.trim().toLowerCase();
|
|
1153
1170
|
return t.startsWith("data:image/svg+xml") || t.includes("image/svg+xml") ? !0 : t.includes(".svg");
|
|
1154
1171
|
}
|
|
1155
|
-
function
|
|
1156
|
-
const t =
|
|
1172
|
+
function Sa(o) {
|
|
1173
|
+
const t = ba(o), [e, n] = I(!1);
|
|
1157
1174
|
return N(() => {
|
|
1158
1175
|
if (t || !o.startsWith("blob:")) {
|
|
1159
|
-
|
|
1176
|
+
n(!1);
|
|
1160
1177
|
return;
|
|
1161
1178
|
}
|
|
1162
1179
|
let r = !1;
|
|
1163
1180
|
return fetch(o).then((c) => c.blob()).then(async (c) => {
|
|
1164
1181
|
if (r) return;
|
|
1165
1182
|
if (c.type.includes("svg")) {
|
|
1166
|
-
|
|
1183
|
+
n(!0);
|
|
1167
1184
|
return;
|
|
1168
1185
|
}
|
|
1169
1186
|
if (c.type.startsWith("image/") && !c.type.includes("svg")) {
|
|
1170
|
-
|
|
1187
|
+
n(!1);
|
|
1171
1188
|
return;
|
|
1172
1189
|
}
|
|
1173
1190
|
const g = await c.text();
|
|
1174
|
-
r ||
|
|
1191
|
+
r || n(/<svg[\s>]/i.test(g.trim()));
|
|
1175
1192
|
}).catch(() => {
|
|
1176
|
-
r ||
|
|
1193
|
+
r || n(!1);
|
|
1177
1194
|
}), () => {
|
|
1178
1195
|
r = !0;
|
|
1179
1196
|
};
|
|
1180
|
-
}, [t, o]), t ||
|
|
1197
|
+
}, [t, o]), t || e;
|
|
1181
1198
|
}
|
|
1182
|
-
function
|
|
1183
|
-
const [
|
|
1199
|
+
function ya(o, t) {
|
|
1200
|
+
const [e, n] = I($t(o) ? o : null);
|
|
1184
1201
|
return N(() => {
|
|
1185
1202
|
if (!t || !o) {
|
|
1186
|
-
|
|
1203
|
+
n(null);
|
|
1187
1204
|
return;
|
|
1188
1205
|
}
|
|
1189
|
-
if (
|
|
1190
|
-
|
|
1206
|
+
if ($t(o)) {
|
|
1207
|
+
n(o);
|
|
1191
1208
|
return;
|
|
1192
1209
|
}
|
|
1193
1210
|
let r = !1;
|
|
1194
|
-
return
|
|
1195
|
-
r ||
|
|
1211
|
+
return Gn(o).then((c) => {
|
|
1212
|
+
r || n(c);
|
|
1196
1213
|
}).catch(() => {
|
|
1197
|
-
r ||
|
|
1214
|
+
r || n(null);
|
|
1198
1215
|
}), () => {
|
|
1199
1216
|
r = !0;
|
|
1200
1217
|
};
|
|
1201
|
-
}, [t, o]), t ?
|
|
1218
|
+
}, [t, o]), t ? e : null;
|
|
1202
1219
|
}
|
|
1203
|
-
function
|
|
1220
|
+
function Ca(o) {
|
|
1204
1221
|
const t = o.indexOf("#");
|
|
1205
1222
|
if (t === -1) return "";
|
|
1206
1223
|
try {
|
|
@@ -1209,7 +1226,7 @@ function ha(o) {
|
|
|
1209
1226
|
return o.slice(t + 1);
|
|
1210
1227
|
}
|
|
1211
1228
|
}
|
|
1212
|
-
function
|
|
1229
|
+
function La(o) {
|
|
1213
1230
|
if (!o || o.startsWith("#")) return !0;
|
|
1214
1231
|
try {
|
|
1215
1232
|
return new URL(o, window.location.href).pathname === window.location.pathname;
|
|
@@ -1217,20 +1234,20 @@ function $a(o) {
|
|
|
1217
1234
|
return !1;
|
|
1218
1235
|
}
|
|
1219
1236
|
}
|
|
1220
|
-
function
|
|
1237
|
+
function It(o) {
|
|
1221
1238
|
if (!o) return null;
|
|
1222
|
-
const t = document.getElementById(o),
|
|
1223
|
-
return
|
|
1239
|
+
const t = document.getElementById(o), e = document.querySelector(`[data-section-id="${CSS.escape(o)}"]`), n = t ?? e;
|
|
1240
|
+
return n instanceof HTMLElement ? n : null;
|
|
1224
1241
|
}
|
|
1225
|
-
function
|
|
1226
|
-
const t =
|
|
1242
|
+
function Nt(o) {
|
|
1243
|
+
const t = It(o);
|
|
1227
1244
|
return t ? (t.scrollIntoView({ behavior: "smooth", block: "start" }), !0) : !1;
|
|
1228
1245
|
}
|
|
1229
|
-
function
|
|
1230
|
-
const { isEditor:
|
|
1246
|
+
function wa(o, t, e = {}) {
|
|
1247
|
+
const { isEditor: n, isPreviewMode: r, item: c, pages: g, onLinkNavigate: p } = e, d = e.runAfterClose ?? ((m) => m()), u = o.currentTarget.getAttribute("href") ?? "", L = Ca(u), z = o.currentTarget.target === "_blank";
|
|
1231
1248
|
if (c && p) {
|
|
1232
1249
|
o.preventDefault(), o.stopPropagation();
|
|
1233
|
-
const m =
|
|
1250
|
+
const m = Mo(c, g), a = zt(c), B = {
|
|
1234
1251
|
mode: a.type === "url" ? "url" : "page",
|
|
1235
1252
|
href: m.href || u,
|
|
1236
1253
|
page: a.type === "page" ? a.value : void 0,
|
|
@@ -1241,19 +1258,19 @@ function ua(o, t, n = {}) {
|
|
|
1241
1258
|
B.target === "_blank" ? p(B) : d(() => p(B)), t();
|
|
1242
1259
|
return;
|
|
1243
1260
|
}
|
|
1244
|
-
if (
|
|
1245
|
-
o.preventDefault(), d(() =>
|
|
1261
|
+
if (n) {
|
|
1262
|
+
o.preventDefault(), d(() => Nt(L)), t();
|
|
1246
1263
|
return;
|
|
1247
1264
|
}
|
|
1248
|
-
!z && L &&
|
|
1265
|
+
!z && L && La(u) && It(L) && (o.preventDefault(), d(() => Nt(L))), t();
|
|
1249
1266
|
}
|
|
1250
|
-
const
|
|
1267
|
+
const Ta = [
|
|
1251
1268
|
"--cntrl-article-width",
|
|
1252
1269
|
"--cntrl-article-top",
|
|
1253
1270
|
"--cntrl-article-left",
|
|
1254
1271
|
"--cntrl-viewport-height"
|
|
1255
1272
|
];
|
|
1256
|
-
function
|
|
1273
|
+
function Na(o) {
|
|
1257
1274
|
let t = o;
|
|
1258
1275
|
for (; t; ) {
|
|
1259
1276
|
if (getComputedStyle(t).getPropertyValue("--cntrl-article-width").trim())
|
|
@@ -1262,26 +1279,26 @@ function xa(o) {
|
|
|
1262
1279
|
}
|
|
1263
1280
|
return o;
|
|
1264
1281
|
}
|
|
1265
|
-
function
|
|
1266
|
-
const t = {},
|
|
1267
|
-
if (!
|
|
1268
|
-
const
|
|
1269
|
-
for (const r of
|
|
1270
|
-
const c =
|
|
1282
|
+
function Aa(o) {
|
|
1283
|
+
const t = {}, e = Na(o);
|
|
1284
|
+
if (!e) return t;
|
|
1285
|
+
const n = getComputedStyle(e);
|
|
1286
|
+
for (const r of Ta) {
|
|
1287
|
+
const c = n.getPropertyValue(r).trim();
|
|
1271
1288
|
c && (t[r] = c);
|
|
1272
1289
|
}
|
|
1273
1290
|
return t;
|
|
1274
1291
|
}
|
|
1275
|
-
function
|
|
1292
|
+
function At(o, t, e, n, r) {
|
|
1276
1293
|
return /* @__PURE__ */ s(
|
|
1277
1294
|
"span",
|
|
1278
1295
|
{
|
|
1279
1296
|
className: `${o}-link-text-box`,
|
|
1280
|
-
style: { width: r(
|
|
1297
|
+
style: { width: r(e), maxWidth: "100%" },
|
|
1281
1298
|
children: /* @__PURE__ */ s(
|
|
1282
1299
|
"span",
|
|
1283
1300
|
{
|
|
1284
|
-
className:
|
|
1301
|
+
className: n ? `${o}-link-text-inner` : `${o}-link-text-inner-hidden`,
|
|
1285
1302
|
style: { width: "100%" },
|
|
1286
1303
|
children: t
|
|
1287
1304
|
}
|
|
@@ -1289,11 +1306,11 @@ function yt(o, t, n, e, r) {
|
|
|
1289
1306
|
}
|
|
1290
1307
|
);
|
|
1291
1308
|
}
|
|
1292
|
-
function
|
|
1309
|
+
function Wa({
|
|
1293
1310
|
settings: o,
|
|
1294
1311
|
isEditor: t,
|
|
1295
|
-
isEditMode:
|
|
1296
|
-
isPreviewMode:
|
|
1312
|
+
isEditMode: e,
|
|
1313
|
+
isPreviewMode: n,
|
|
1297
1314
|
activeEvent: r,
|
|
1298
1315
|
currentState: c,
|
|
1299
1316
|
isSwitchClone: g = !1,
|
|
@@ -1304,216 +1321,217 @@ function Ha({
|
|
|
1304
1321
|
onUpdateSettings: z,
|
|
1305
1322
|
onOpenChange: m
|
|
1306
1323
|
}) {
|
|
1307
|
-
var
|
|
1308
|
-
const { prefix: a } =
|
|
1309
|
-
|
|
1324
|
+
var vt, ht;
|
|
1325
|
+
const { prefix: a } = _n(), B = S(null), V = S(null), j = S(null), X = S(null), Y = S(null), O = S(0), f = S(null), K = S(null), q = S(d), Rt = uo(() => ma(a), [a]), [_t, Z] = I(!1), [W, xo] = I(!1), [Go, ao] = I(!1), _ = jn(c), Mt = uo(() => new Set(p), [p]), ko = (i) => !!(i && Mt.has(i)), Do = Qn(o.link, d), Wt = !!(t && !n && _ === "open" && !ko("open")), h = Do && (Wt || !(t && !n) && _t), bo = !!(t && !n), J = h && !bo;
|
|
1326
|
+
Mn(J), N(() => {
|
|
1310
1327
|
if (!h || !bo) return;
|
|
1311
1328
|
const i = document.documentElement, l = i.style.overflow;
|
|
1312
1329
|
return i.style.overflow = "hidden", () => {
|
|
1313
1330
|
i.style.overflow = l;
|
|
1314
1331
|
};
|
|
1315
1332
|
}, [h, bo]);
|
|
1316
|
-
const
|
|
1317
|
-
w !==
|
|
1318
|
-
const
|
|
1333
|
+
const Et = !ko("compact") && !ko("onScroll"), Gt = !t || !!n && !e, ro = r && r !== "default" ? r : void 0, w = Et && _ === "compact" ? "compact" : "default", [Uo, Dt] = I(w), [So, Vo] = I(!1), jo = !e;
|
|
1334
|
+
w !== Uo && (Dt(w), jo && Vo(!0));
|
|
1335
|
+
const Ut = Ft(o), {
|
|
1319
1336
|
logo: E,
|
|
1320
|
-
|
|
1321
|
-
|
|
1322
|
-
|
|
1323
|
-
|
|
1324
|
-
|
|
1325
|
-
|
|
1326
|
-
|
|
1327
|
-
|
|
1328
|
-
|
|
1329
|
-
|
|
1330
|
-
|
|
1331
|
-
|
|
1332
|
-
|
|
1333
|
-
|
|
1334
|
-
|
|
1335
|
-
|
|
1336
|
-
|
|
1337
|
-
|
|
1338
|
-
|
|
1339
|
-
|
|
1340
|
-
|
|
1341
|
-
|
|
1342
|
-
|
|
1343
|
-
|
|
1344
|
-
|
|
1345
|
-
|
|
1346
|
-
|
|
1347
|
-
|
|
1348
|
-
|
|
1349
|
-
|
|
1350
|
-
|
|
1351
|
-
|
|
1352
|
-
|
|
1353
|
-
|
|
1354
|
-
|
|
1355
|
-
|
|
1356
|
-
|
|
1357
|
-
|
|
1358
|
-
|
|
1359
|
-
|
|
1337
|
+
logoLink: Xo = "",
|
|
1338
|
+
logoMaxHeight: Vt = 120 / 1440,
|
|
1339
|
+
logoPosition: jt = "left",
|
|
1340
|
+
panelHeight: Yo = 60 / 1440,
|
|
1341
|
+
backgroundColor: Xt = "#b3b3b3",
|
|
1342
|
+
logoColor: Yt = "#000000",
|
|
1343
|
+
position: Kt,
|
|
1344
|
+
horizontalAlign: qt,
|
|
1345
|
+
verticalAlign: Zt,
|
|
1346
|
+
iconColor: Jt = "#000000",
|
|
1347
|
+
showIcon: Qt = "on",
|
|
1348
|
+
iconSize: Pt = 16 / 1440,
|
|
1349
|
+
linkColor: oe = "#000000",
|
|
1350
|
+
openLinkColor: te = "#000000",
|
|
1351
|
+
compactIconColor: ee = "#000000",
|
|
1352
|
+
compactLinkColor: ne = "#000000",
|
|
1353
|
+
compactLogoColor: ae = "#000000",
|
|
1354
|
+
compactBackgroundColor: re = "#ffffff",
|
|
1355
|
+
compactLogoMaxHeight: ie = 120 / 1440,
|
|
1356
|
+
compactLogoPosition: ce,
|
|
1357
|
+
compactPanelHeight: le = 60 / 1440,
|
|
1358
|
+
compactShowIcon: se = "on",
|
|
1359
|
+
compactIconSize: de = 16 / 1440,
|
|
1360
|
+
compactNavTextWidth: ge,
|
|
1361
|
+
compactNavTextPosition: fe,
|
|
1362
|
+
compactNavTextOffset: pe,
|
|
1363
|
+
compactNavGap: ve,
|
|
1364
|
+
compactNavPaddingLeft: he = 10 / 1440,
|
|
1365
|
+
compactNavPaddingRight: $e = 10 / 1440,
|
|
1366
|
+
compactFontFamily: ue,
|
|
1367
|
+
compactFontSettings: me,
|
|
1368
|
+
compactFontSize: xe,
|
|
1369
|
+
compactLineHeight: ke,
|
|
1370
|
+
compactLetterSpacing: be = 0,
|
|
1371
|
+
compactWordSpacing: Se = 0,
|
|
1372
|
+
compactTextAlign: ye = "left",
|
|
1373
|
+
compactTextAppearance: Ce,
|
|
1374
|
+
openLogoColor: Le = "#000000",
|
|
1375
|
+
menuBackgroundColor: Ko = "#ffffff",
|
|
1376
|
+
overlayColor: we = "rgba(0, 0, 0, 0.45)",
|
|
1377
|
+
closeButtonColor: Te = "#000000",
|
|
1360
1378
|
effect: yo = "fade",
|
|
1361
|
-
openPanelSize:
|
|
1362
|
-
textWidth:
|
|
1363
|
-
navTextWidth:
|
|
1364
|
-
navTextPosition:
|
|
1365
|
-
navTextOffset:
|
|
1366
|
-
gap:
|
|
1367
|
-
navGap:
|
|
1368
|
-
navPaddingLeft:
|
|
1369
|
-
navPaddingRight:
|
|
1370
|
-
textPaddingLeft:
|
|
1371
|
-
textPaddingRight:
|
|
1372
|
-
textPaddingTop:
|
|
1373
|
-
textPaddingBottom:
|
|
1374
|
-
fontFamily:
|
|
1375
|
-
fontSettings:
|
|
1376
|
-
fontSize:
|
|
1377
|
-
lineHeight:
|
|
1378
|
-
letterSpacing:
|
|
1379
|
-
wordSpacing:
|
|
1380
|
-
textAlign:
|
|
1381
|
-
textAppearance:
|
|
1382
|
-
openFontFamily:
|
|
1383
|
-
openFontSettings:
|
|
1384
|
-
openFontSize:
|
|
1385
|
-
openLineHeight:
|
|
1386
|
-
openLetterSpacing:
|
|
1387
|
-
openWordSpacing:
|
|
1388
|
-
openTextAlign:
|
|
1389
|
-
openTextAppearance:
|
|
1390
|
-
stateOverrides:
|
|
1391
|
-
link:
|
|
1392
|
-
} =
|
|
1393
|
-
position:
|
|
1394
|
-
horizontalAlign:
|
|
1395
|
-
verticalAlign:
|
|
1396
|
-
}), x = w === "compact",
|
|
1397
|
-
iconColor:
|
|
1398
|
-
closeButtonColor:
|
|
1399
|
-
linkColor:
|
|
1400
|
-
openLinkColor:
|
|
1401
|
-
compactIconColor:
|
|
1402
|
-
compactLinkColor:
|
|
1403
|
-
compactLogoColor:
|
|
1404
|
-
compactBackgroundColor:
|
|
1405
|
-
openLogoColor:
|
|
1406
|
-
menuBackgroundColor:
|
|
1407
|
-
overlayColor:
|
|
1408
|
-
backgroundColor:
|
|
1409
|
-
logoColor:
|
|
1410
|
-
},
|
|
1411
|
-
fontFamily:
|
|
1412
|
-
fontSettings:
|
|
1413
|
-
fontSize:
|
|
1414
|
-
lineHeight:
|
|
1415
|
-
letterSpacing:
|
|
1416
|
-
wordSpacing:
|
|
1417
|
-
textAlign:
|
|
1418
|
-
textAppearance:
|
|
1379
|
+
openPanelSize: qo = 100,
|
|
1380
|
+
textWidth: Zo = 280 / 1440,
|
|
1381
|
+
navTextWidth: Ne,
|
|
1382
|
+
navTextPosition: Ae = "center",
|
|
1383
|
+
navTextOffset: ze = 0,
|
|
1384
|
+
gap: Jo = 0,
|
|
1385
|
+
navGap: Be,
|
|
1386
|
+
navPaddingLeft: He = 10 / 1440,
|
|
1387
|
+
navPaddingRight: Oe = 10 / 1440,
|
|
1388
|
+
textPaddingLeft: Qo = 10 / 1440,
|
|
1389
|
+
textPaddingRight: Po = 10 / 1440,
|
|
1390
|
+
textPaddingTop: ot = 10 / 1440,
|
|
1391
|
+
textPaddingBottom: tt = 10 / 1440,
|
|
1392
|
+
fontFamily: Fe,
|
|
1393
|
+
fontSettings: Ie,
|
|
1394
|
+
fontSize: Re,
|
|
1395
|
+
lineHeight: _e,
|
|
1396
|
+
letterSpacing: Me = 0,
|
|
1397
|
+
wordSpacing: We = 0,
|
|
1398
|
+
textAlign: Ee = "left",
|
|
1399
|
+
textAppearance: Ge,
|
|
1400
|
+
openFontFamily: De,
|
|
1401
|
+
openFontSettings: Ue,
|
|
1402
|
+
openFontSize: Ve,
|
|
1403
|
+
openLineHeight: je,
|
|
1404
|
+
openLetterSpacing: Xe,
|
|
1405
|
+
openWordSpacing: Ye,
|
|
1406
|
+
openTextAlign: Ke,
|
|
1407
|
+
openTextAppearance: qe,
|
|
1408
|
+
stateOverrides: et,
|
|
1409
|
+
link: nt
|
|
1410
|
+
} = Ut, { horizontalAlign: Ze, verticalAlign: Je } = la({
|
|
1411
|
+
position: Kt,
|
|
1412
|
+
horizontalAlign: qt,
|
|
1413
|
+
verticalAlign: Zt
|
|
1414
|
+
}), x = w === "compact", Qe = x ? ie : Vt, io = Xn(x ? ce : jt), co = x ? le : Yo, Co = x ? de : Pt, Pe = x ? ge : Ne, at = Yn(x ? fe : Ae), on = (x ? pe : ze) ?? 0, tn = x ? ve : Be, rt = x ? he : He, it = x ? $e : Oe, en = Pe ?? Zo, nn = h || Do && (x ? se : Qt) !== "off", Lo = Rn(a, {
|
|
1415
|
+
iconColor: Jt,
|
|
1416
|
+
closeButtonColor: Te,
|
|
1417
|
+
linkColor: oe,
|
|
1418
|
+
openLinkColor: te,
|
|
1419
|
+
compactIconColor: ee,
|
|
1420
|
+
compactLinkColor: ne,
|
|
1421
|
+
compactLogoColor: ae,
|
|
1422
|
+
compactBackgroundColor: re,
|
|
1423
|
+
openLogoColor: Le,
|
|
1424
|
+
menuBackgroundColor: Ko,
|
|
1425
|
+
overlayColor: we,
|
|
1426
|
+
backgroundColor: Xt,
|
|
1427
|
+
logoColor: Yt
|
|
1428
|
+
}, va, ha, et), wo = yt(x ? {
|
|
1429
|
+
fontFamily: ue,
|
|
1430
|
+
fontSettings: me,
|
|
1431
|
+
fontSize: xe,
|
|
1432
|
+
lineHeight: ke,
|
|
1433
|
+
letterSpacing: be,
|
|
1434
|
+
wordSpacing: Se,
|
|
1435
|
+
textAlign: ye,
|
|
1436
|
+
textAppearance: Ce
|
|
1419
1437
|
} : {
|
|
1420
|
-
fontFamily:
|
|
1421
|
-
fontSettings:
|
|
1422
|
-
fontSize:
|
|
1423
|
-
lineHeight:
|
|
1424
|
-
letterSpacing:
|
|
1425
|
-
wordSpacing:
|
|
1426
|
-
textAlign:
|
|
1427
|
-
textAppearance:
|
|
1428
|
-
}), Q =
|
|
1429
|
-
fontFamily:
|
|
1430
|
-
fontSettings:
|
|
1431
|
-
fontSize:
|
|
1432
|
-
lineHeight:
|
|
1433
|
-
letterSpacing:
|
|
1434
|
-
wordSpacing:
|
|
1435
|
-
textAlign:
|
|
1436
|
-
textAppearance:
|
|
1437
|
-
}, wo), To =
|
|
1438
|
+
fontFamily: Fe,
|
|
1439
|
+
fontSettings: Ie,
|
|
1440
|
+
fontSize: Re,
|
|
1441
|
+
lineHeight: _e,
|
|
1442
|
+
letterSpacing: Me,
|
|
1443
|
+
wordSpacing: We,
|
|
1444
|
+
textAlign: Ee,
|
|
1445
|
+
textAppearance: Ge
|
|
1446
|
+
}), Q = yt({
|
|
1447
|
+
fontFamily: De,
|
|
1448
|
+
fontSettings: Ue,
|
|
1449
|
+
fontSize: Ve,
|
|
1450
|
+
lineHeight: je,
|
|
1451
|
+
letterSpacing: Xe,
|
|
1452
|
+
wordSpacing: Ye,
|
|
1453
|
+
textAlign: Ke,
|
|
1454
|
+
textAppearance: qe
|
|
1455
|
+
}, wo), To = Ct(a, wo, t), No = Ct(a, Q, t), an = xt(j, bt(wo)), rn = xt(X, bt(Q)), cn = {
|
|
1438
1456
|
...No.css,
|
|
1439
1457
|
whiteSpace: "pre-wrap",
|
|
1440
|
-
transform:
|
|
1441
|
-
},
|
|
1442
|
-
() =>
|
|
1443
|
-
textPaddingLeft:
|
|
1444
|
-
textPaddingRight:
|
|
1445
|
-
textPaddingTop:
|
|
1446
|
-
textPaddingBottom:
|
|
1458
|
+
transform: kt(rn)
|
|
1459
|
+
}, ln = No.className, H = (i) => A(i, t), sn = tn ?? Jo, dn = Math.max(rt, U), gn = Math.max(it, U), fn = Math.max(0, 1 - Co), pn = Math.max(0, 1 - Co), lo = e ?? !1, so = lo && !h, ct = uo(
|
|
1460
|
+
() => Ot({
|
|
1461
|
+
textPaddingLeft: Qo,
|
|
1462
|
+
textPaddingRight: Po,
|
|
1463
|
+
textPaddingTop: ot,
|
|
1464
|
+
textPaddingBottom: tt,
|
|
1447
1465
|
fontSize: Q.fontSize
|
|
1448
1466
|
}),
|
|
1449
1467
|
[
|
|
1450
|
-
|
|
1451
|
-
|
|
1452
|
-
|
|
1453
|
-
|
|
1468
|
+
Qo,
|
|
1469
|
+
Po,
|
|
1470
|
+
ot,
|
|
1471
|
+
tt,
|
|
1454
1472
|
Q.fontSize
|
|
1455
1473
|
]
|
|
1456
|
-
),
|
|
1457
|
-
const l = /* @__PURE__ */ s("span", { className:
|
|
1458
|
-
return
|
|
1474
|
+
), lt = (i) => {
|
|
1475
|
+
const l = /* @__PURE__ */ s("span", { className: ln, style: cn, children: Lt(i) });
|
|
1476
|
+
return At(
|
|
1459
1477
|
a,
|
|
1460
1478
|
l,
|
|
1461
|
-
|
|
1479
|
+
Zo,
|
|
1462
1480
|
lo,
|
|
1463
1481
|
H
|
|
1464
1482
|
);
|
|
1465
|
-
},
|
|
1466
|
-
...
|
|
1467
|
-
...
|
|
1468
|
-
alignItems:
|
|
1469
|
-
justifyContent:
|
|
1483
|
+
}, vn = yo === "left" || yo === "right" ? { width: `${qo}%` } : { height: `${qo}%` }, hn = {
|
|
1484
|
+
...fa(ct, t),
|
|
1485
|
+
...vn,
|
|
1486
|
+
alignItems: ua[Ze],
|
|
1487
|
+
justifyContent: $a[Je]
|
|
1470
1488
|
}, P = S(o), go = S(d), Ao = S(null);
|
|
1471
|
-
|
|
1489
|
+
Wo((vt = o.logo) == null ? void 0 : vt.icon) && (Ao.current = o.logo.icon), N(() => {
|
|
1472
1490
|
var ho;
|
|
1473
1491
|
if (!z || !t) {
|
|
1474
1492
|
P.current = o, go.current = d;
|
|
1475
1493
|
return;
|
|
1476
1494
|
}
|
|
1477
1495
|
const i = (ho = o.logo) == null ? void 0 : ho.icon;
|
|
1478
|
-
if (o.logo && !
|
|
1496
|
+
if (o.logo && !Wo(i) && !Ao.current) {
|
|
1479
1497
|
P.current = o, go.current = d;
|
|
1480
1498
|
return;
|
|
1481
1499
|
}
|
|
1482
1500
|
const l = ($o) => {
|
|
1483
|
-
z(
|
|
1501
|
+
z(xa($o, Ao.current));
|
|
1484
1502
|
};
|
|
1485
1503
|
if (go.current !== d) {
|
|
1486
1504
|
P.current = o, go.current = d;
|
|
1487
|
-
const $o =
|
|
1505
|
+
const $o = Tt(o);
|
|
1488
1506
|
$o !== o && l($o);
|
|
1489
1507
|
return;
|
|
1490
1508
|
}
|
|
1491
|
-
const $ =
|
|
1509
|
+
const $ = Tt(o), k = P.current, b = k !== o, T = b ? ga($, k) : $;
|
|
1492
1510
|
P.current = o;
|
|
1493
|
-
const D = $ !== o, eo = b &&
|
|
1511
|
+
const D = $ !== o, eo = b && sa($, T);
|
|
1494
1512
|
!D && !eo || l(T);
|
|
1495
1513
|
}, [o, z, t, d]);
|
|
1496
|
-
const G = A(Co, t),
|
|
1514
|
+
const G = A(Co, t), $n = {
|
|
1497
1515
|
width: G,
|
|
1498
1516
|
height: G,
|
|
1499
1517
|
minWidth: G,
|
|
1500
1518
|
minHeight: G,
|
|
1501
1519
|
maxWidth: G,
|
|
1502
1520
|
maxHeight: G
|
|
1503
|
-
},
|
|
1521
|
+
}, un = {
|
|
1504
1522
|
...To.css,
|
|
1505
1523
|
textDecoration: "none",
|
|
1506
|
-
transform:
|
|
1507
|
-
},
|
|
1524
|
+
transform: kt(an)
|
|
1525
|
+
}, mn = To.className, st = (E == null ? void 0 : E.mode) !== "Off", oo = (E == null ? void 0 : E.icon) ?? "", xn = Sa(oo), to = ya(oo, xn), fo = !!to, kn = H(Math.min(Qe, co)), bn = !!(st && oo && io === "right"), zo = Xo.trim() ? { link: { type: "url", value: ta(Xo.trim()), target: "self" } } : null, Bo = bn ? "left" : "right", dt = Array.isArray(nt) ? nt : [], Ho = [
|
|
1508
1526
|
w !== "default" ? `${a}-state-${w}` : "",
|
|
1509
1527
|
h || _ === "open" ? `${a}-state-open` : "",
|
|
1510
1528
|
ro && ro !== w && ro !== _ ? `${a}-state-${ro}` : ""
|
|
1511
|
-
].filter(Boolean).join(" "),
|
|
1512
|
-
() =>
|
|
1529
|
+
].filter(Boolean).join(" "), Sn = t && !n ? `${a}-editor` : "", gt = Gt ? `${a}-interactive` : "", yn = jo && (w !== Uo || So) ? `${a}-nav-state-anim` : "", Cn = h ? `${a}-open` : "", Ln = uo(
|
|
1530
|
+
() => Aa(B.current),
|
|
1513
1531
|
[W, h, d]
|
|
1514
|
-
),
|
|
1532
|
+
), Oo = () => {
|
|
1515
1533
|
Z(!1);
|
|
1516
|
-
},
|
|
1534
|
+
}, Fo = !t || n, wn = (i) => {
|
|
1517
1535
|
if (J) {
|
|
1518
1536
|
K.current = i;
|
|
1519
1537
|
return;
|
|
@@ -1525,18 +1543,18 @@ function Ha({
|
|
|
1525
1543
|
const i = K.current;
|
|
1526
1544
|
K.current = null, i == null || i();
|
|
1527
1545
|
}, [h]);
|
|
1528
|
-
const
|
|
1529
|
-
|
|
1546
|
+
const Io = (i, l) => {
|
|
1547
|
+
wa(i, Oo, {
|
|
1530
1548
|
isEditor: t,
|
|
1531
|
-
isPreviewMode:
|
|
1549
|
+
isPreviewMode: n,
|
|
1532
1550
|
item: l,
|
|
1533
1551
|
pages: u,
|
|
1534
1552
|
onLinkNavigate: L,
|
|
1535
|
-
runAfterClose:
|
|
1553
|
+
runAfterClose: wn
|
|
1536
1554
|
});
|
|
1537
|
-
},
|
|
1538
|
-
t && !
|
|
1539
|
-
},
|
|
1555
|
+
}, Tn = () => {
|
|
1556
|
+
t && !n || Z((i) => !i);
|
|
1557
|
+
}, Nn = (i) => {
|
|
1540
1558
|
i.pointerType === "touch" && i.currentTarget.blur();
|
|
1541
1559
|
}, po = () => {
|
|
1542
1560
|
f.current !== null && (window.clearTimeout(f.current), f.current = null);
|
|
@@ -1544,7 +1562,7 @@ function Ha({
|
|
|
1544
1562
|
N(() => {
|
|
1545
1563
|
if (!So) return;
|
|
1546
1564
|
const i = window.setTimeout(() => {
|
|
1547
|
-
|
|
1565
|
+
Vo(!1);
|
|
1548
1566
|
}, v);
|
|
1549
1567
|
return () => window.clearTimeout(i);
|
|
1550
1568
|
}, [So, w]), N(() => {
|
|
@@ -1579,44 +1597,44 @@ function Ha({
|
|
|
1579
1597
|
return $.style.backgroundColor = l, k.style.backgroundColor = l, () => {
|
|
1580
1598
|
$.style.backgroundColor = b, k.style.backgroundColor = T;
|
|
1581
1599
|
};
|
|
1582
|
-
}, [J, W,
|
|
1600
|
+
}, [J, W, Ho, Ko, et]), N(() => {
|
|
1583
1601
|
m == null || m(h);
|
|
1584
1602
|
}, [h, m]), N(() => {
|
|
1585
1603
|
if (!h) return;
|
|
1586
1604
|
const i = (l) => {
|
|
1587
|
-
l.key === "Escape" && (t &&
|
|
1605
|
+
l.key === "Escape" && (t && n || Oo());
|
|
1588
1606
|
};
|
|
1589
1607
|
return window.addEventListener("keydown", i), () => window.removeEventListener("keydown", i);
|
|
1590
|
-
}, [h, t,
|
|
1591
|
-
t && !
|
|
1592
|
-
}, [t,
|
|
1593
|
-
|
|
1594
|
-
}, [
|
|
1595
|
-
const
|
|
1596
|
-
const { label: k, href: b, target: T } =
|
|
1608
|
+
}, [h, t, n]), N(() => {
|
|
1609
|
+
t && !n && _ !== "open" && Z(!1);
|
|
1610
|
+
}, [t, n, _]), N(() => {
|
|
1611
|
+
n && Z(!1);
|
|
1612
|
+
}, [n]);
|
|
1613
|
+
const ft = lo && h, An = (i) => dt.filter((l) => Jn(l, d)).map((l, $) => {
|
|
1614
|
+
const { label: k, href: b, target: T } = Mo(l, u), D = b ? /* @__PURE__ */ s(
|
|
1597
1615
|
"a",
|
|
1598
1616
|
{
|
|
1599
1617
|
href: b,
|
|
1600
1618
|
target: T,
|
|
1601
1619
|
rel: T === "_blank" ? "noopener noreferrer" : void 0,
|
|
1602
1620
|
className: `${i} ${a}-has-href`,
|
|
1603
|
-
onClick: (eo) =>
|
|
1604
|
-
children:
|
|
1621
|
+
onClick: (eo) => Io(eo, l),
|
|
1622
|
+
children: lt(k)
|
|
1605
1623
|
}
|
|
1606
|
-
) : /* @__PURE__ */ s("span", { className: i, children:
|
|
1607
|
-
return /* @__PURE__ */ C(
|
|
1624
|
+
) : /* @__PURE__ */ s("span", { className: i, children: lt(k) });
|
|
1625
|
+
return /* @__PURE__ */ C(_o, { children: [
|
|
1608
1626
|
$ > 0 && /* @__PURE__ */ s(
|
|
1609
1627
|
"div",
|
|
1610
1628
|
{
|
|
1611
|
-
"data-controls":
|
|
1629
|
+
"data-controls": ft ? "gap" : void 0,
|
|
1612
1630
|
"data-controls-axis": "y",
|
|
1613
|
-
className:
|
|
1614
|
-
style: { height: H(
|
|
1631
|
+
className: ft ? `${a}-gap-control` : void 0,
|
|
1632
|
+
style: { height: H(Jo) }
|
|
1615
1633
|
}
|
|
1616
1634
|
),
|
|
1617
1635
|
D
|
|
1618
1636
|
] }, $);
|
|
1619
|
-
}),
|
|
1637
|
+
}), zn = W ? /* @__PURE__ */ C(
|
|
1620
1638
|
"div",
|
|
1621
1639
|
{
|
|
1622
1640
|
ref: V,
|
|
@@ -1624,52 +1642,52 @@ function Ha({
|
|
|
1624
1642
|
className: [
|
|
1625
1643
|
`${a}-lightbox`,
|
|
1626
1644
|
`${a}-full-lightbox ${a}-effect-${yo}`,
|
|
1627
|
-
|
|
1645
|
+
Go ? `${a}-lightbox-active` : "",
|
|
1628
1646
|
`${a}-lightbox-editor`,
|
|
1629
|
-
|
|
1630
|
-
|
|
1631
|
-
|
|
1647
|
+
e ? `${a}-lightbox-edit-mode` : "",
|
|
1648
|
+
gt,
|
|
1649
|
+
Ho
|
|
1632
1650
|
].filter(Boolean).join(" "),
|
|
1633
|
-
style: { ...Lo, ...
|
|
1634
|
-
"aria-hidden": !
|
|
1651
|
+
style: { ...Lo, ...Ln },
|
|
1652
|
+
"aria-hidden": !Go,
|
|
1635
1653
|
children: [
|
|
1636
1654
|
/* @__PURE__ */ s(
|
|
1637
1655
|
"div",
|
|
1638
1656
|
{
|
|
1639
|
-
className: [`${a}-backdrop`,
|
|
1657
|
+
className: [`${a}-backdrop`, Fo ? `${a}-backdrop-clickable` : ""].filter(Boolean).join(" "),
|
|
1640
1658
|
"aria-hidden": "true",
|
|
1641
|
-
onClick:
|
|
1659
|
+
onClick: Fo ? Oo : void 0
|
|
1642
1660
|
}
|
|
1643
1661
|
),
|
|
1644
1662
|
/* @__PURE__ */ C(
|
|
1645
1663
|
"nav",
|
|
1646
1664
|
{
|
|
1647
|
-
className: [`${a}-panel`,
|
|
1648
|
-
style:
|
|
1665
|
+
className: [`${a}-panel`, Fo ? `${a}-panel-blocking` : ""].filter(Boolean).join(" "),
|
|
1666
|
+
style: hn,
|
|
1649
1667
|
"aria-label": "Menu",
|
|
1650
1668
|
"data-lightbox-scrollable": "",
|
|
1651
1669
|
children: [
|
|
1652
|
-
lo &&
|
|
1653
|
-
|
|
1670
|
+
lo && pa(a, ct, Q.fontSize, H),
|
|
1671
|
+
An(`${a}-link`)
|
|
1654
1672
|
]
|
|
1655
1673
|
}
|
|
1656
1674
|
),
|
|
1657
1675
|
J ? /* @__PURE__ */ s("div", { ref: Y, className: `${a}-safari-tint`, "aria-hidden": "true" }) : null
|
|
1658
1676
|
]
|
|
1659
1677
|
}
|
|
1660
|
-
) : null,
|
|
1678
|
+
) : null, Bn = () => /* @__PURE__ */ s(
|
|
1661
1679
|
"button",
|
|
1662
1680
|
{
|
|
1663
1681
|
type: "button",
|
|
1664
1682
|
className: `${a}-toggle`,
|
|
1665
|
-
onClick:
|
|
1666
|
-
onPointerUp:
|
|
1683
|
+
onClick: Tn,
|
|
1684
|
+
onPointerUp: Nn,
|
|
1667
1685
|
"aria-expanded": h,
|
|
1668
1686
|
"aria-label": h ? "Close menu" : "Open menu",
|
|
1669
|
-
children: /* @__PURE__ */ s(
|
|
1687
|
+
children: /* @__PURE__ */ s(ea, { className: `${a}-icon`, lineClassName: `${a}-icon-line` })
|
|
1670
1688
|
}
|
|
1671
1689
|
), vo = (i) => {
|
|
1672
|
-
const l = i === "left", $ = l ?
|
|
1690
|
+
const l = i === "left", $ = l ? rt : it, k = l ? dn : gn, b = l ? fn : pn, T = x ? l ? "compactNavPaddingLeft" : "compactNavPaddingRight" : l ? "navPaddingLeft" : "navPaddingRight";
|
|
1673
1691
|
return /* @__PURE__ */ s(
|
|
1674
1692
|
"div",
|
|
1675
1693
|
{
|
|
@@ -1695,11 +1713,11 @@ function Ha({
|
|
|
1695
1713
|
) : null
|
|
1696
1714
|
}
|
|
1697
1715
|
);
|
|
1698
|
-
},
|
|
1699
|
-
const { label: $, href: k, target: b } =
|
|
1716
|
+
}, Hn = (i, l) => {
|
|
1717
|
+
const { label: $, href: k, target: b } = Mo(i, u), T = /* @__PURE__ */ s("span", { className: mn, style: un, children: Lt($) }), D = At(
|
|
1700
1718
|
a,
|
|
1701
1719
|
T,
|
|
1702
|
-
|
|
1720
|
+
en,
|
|
1703
1721
|
so,
|
|
1704
1722
|
H
|
|
1705
1723
|
), eo = k ? /* @__PURE__ */ s(
|
|
@@ -1709,99 +1727,109 @@ function Ha({
|
|
|
1709
1727
|
target: b,
|
|
1710
1728
|
rel: b === "_blank" ? "noopener noreferrer" : void 0,
|
|
1711
1729
|
className: `${a}-nav-link ${a}-has-href`,
|
|
1712
|
-
onClick: (ho) =>
|
|
1730
|
+
onClick: (ho) => Io(ho, i),
|
|
1713
1731
|
children: D
|
|
1714
1732
|
}
|
|
1715
1733
|
) : /* @__PURE__ */ s("span", { className: `${a}-nav-link`, children: D });
|
|
1716
|
-
return /* @__PURE__ */ C(
|
|
1734
|
+
return /* @__PURE__ */ C(_o, { children: [
|
|
1717
1735
|
l > 0 && /* @__PURE__ */ s(
|
|
1718
1736
|
"div",
|
|
1719
1737
|
{
|
|
1720
1738
|
"data-controls": so ? x ? "compactNavGap" : "navGap" : void 0,
|
|
1721
1739
|
"data-controls-axis": "x",
|
|
1722
1740
|
className: so ? `${a}-gap-control ${a}-nav-gap-control` : `${a}-nav-gap-control}`,
|
|
1723
|
-
style: { width: H(
|
|
1741
|
+
style: { width: H(sn), flexShrink: 0 }
|
|
1724
1742
|
}
|
|
1725
1743
|
),
|
|
1726
1744
|
eo
|
|
1727
1745
|
] }, l);
|
|
1728
|
-
},
|
|
1746
|
+
}, pt = /* @__PURE__ */ C(
|
|
1747
|
+
"div",
|
|
1748
|
+
{
|
|
1749
|
+
className: `${a}-nav-logo-inner${fo ? ` ${a}-nav-logo-tinted` : ""}`,
|
|
1750
|
+
style: {
|
|
1751
|
+
height: kn,
|
|
1752
|
+
...fo && to ? { [`--${a}-logo-image`]: ka(to) } : {}
|
|
1753
|
+
},
|
|
1754
|
+
children: [
|
|
1755
|
+
/* @__PURE__ */ s(
|
|
1756
|
+
"img",
|
|
1757
|
+
{
|
|
1758
|
+
src: fo && to ? to : oo,
|
|
1759
|
+
alt: "",
|
|
1760
|
+
className: `${a}-nav-logo-img`
|
|
1761
|
+
}
|
|
1762
|
+
),
|
|
1763
|
+
fo ? /* @__PURE__ */ s("span", { className: `${a}-nav-logo-tint`, "aria-hidden": "true" }) : null
|
|
1764
|
+
]
|
|
1765
|
+
}
|
|
1766
|
+
), On = {
|
|
1729
1767
|
...Lo,
|
|
1730
1768
|
height: A(co, t),
|
|
1731
1769
|
minHeight: A(co, t),
|
|
1732
1770
|
[`--${a}-panel-height`]: A(co, t)
|
|
1733
|
-
},
|
|
1771
|
+
}, Fn = g && w === "default" && _ !== "open" && !n ? H(Yo + Dn) : "0px";
|
|
1734
1772
|
return /* @__PURE__ */ C(
|
|
1735
1773
|
"div",
|
|
1736
1774
|
{
|
|
1737
1775
|
ref: B,
|
|
1738
|
-
className: `${a}-root ${
|
|
1776
|
+
className: `${a}-root ${Ho} ${Sn} ${gt} ${yn}`.trim(),
|
|
1739
1777
|
style: {
|
|
1740
1778
|
width: "100%",
|
|
1741
1779
|
height: "100%",
|
|
1742
1780
|
lineHeight: 0,
|
|
1743
1781
|
fontSize: 0,
|
|
1744
|
-
marginTop:
|
|
1782
|
+
marginTop: Fn,
|
|
1745
1783
|
...Lo
|
|
1746
1784
|
},
|
|
1747
1785
|
children: [
|
|
1748
|
-
/* @__PURE__ */ s("style", { dangerouslySetInnerHTML: { __html:
|
|
1749
|
-
/* @__PURE__ */ s("span", { ref: j, "aria-hidden": !0, style:
|
|
1750
|
-
/* @__PURE__ */ s("span", { ref: X, "aria-hidden": !0, style:
|
|
1751
|
-
/* @__PURE__ */ s("div", { className: `${a}-nav-slide`, children: /* @__PURE__ */ C("div", { className: `${a}-nav-bar`, style:
|
|
1752
|
-
|
|
1786
|
+
/* @__PURE__ */ s("style", { dangerouslySetInnerHTML: { __html: Rt } }),
|
|
1787
|
+
/* @__PURE__ */ s("span", { ref: j, "aria-hidden": !0, style: St(To.css), children: "H" }),
|
|
1788
|
+
/* @__PURE__ */ s("span", { ref: X, "aria-hidden": !0, style: St(No.css), children: "H" }),
|
|
1789
|
+
/* @__PURE__ */ s("div", { className: `${a}-nav-slide`, children: /* @__PURE__ */ C("div", { className: `${a}-nav-bar`, style: On, children: [
|
|
1790
|
+
st && oo ? /* @__PURE__ */ C("div", { className: `${a}-nav-logo ${a}-nav-logo-${io}`, children: [
|
|
1753
1791
|
io === "left" ? vo("left") : null,
|
|
1754
|
-
/* @__PURE__ */
|
|
1755
|
-
"
|
|
1792
|
+
zo ? /* @__PURE__ */ s(
|
|
1793
|
+
"a",
|
|
1756
1794
|
{
|
|
1757
|
-
|
|
1758
|
-
|
|
1759
|
-
|
|
1760
|
-
|
|
1761
|
-
|
|
1762
|
-
children: [
|
|
1763
|
-
/* @__PURE__ */ s(
|
|
1764
|
-
"img",
|
|
1765
|
-
{
|
|
1766
|
-
src: fo && to ? to : oo,
|
|
1767
|
-
alt: "",
|
|
1768
|
-
className: `${a}-nav-logo-img`
|
|
1769
|
-
}
|
|
1770
|
-
),
|
|
1771
|
-
fo ? /* @__PURE__ */ s("span", { className: `${a}-nav-logo-tint`, "aria-hidden": "true" }) : null
|
|
1772
|
-
]
|
|
1795
|
+
href: (ht = zo.link) == null ? void 0 : ht.value,
|
|
1796
|
+
className: `${a}-nav-logo-link`,
|
|
1797
|
+
"aria-label": "Home",
|
|
1798
|
+
onClick: (i) => Io(i, zo),
|
|
1799
|
+
children: pt
|
|
1773
1800
|
}
|
|
1774
|
-
),
|
|
1801
|
+
) : pt,
|
|
1775
1802
|
io === "right" ? vo("right") : null
|
|
1776
1803
|
] }) : null,
|
|
1777
1804
|
/* @__PURE__ */ s(
|
|
1778
1805
|
"nav",
|
|
1779
1806
|
{
|
|
1780
|
-
className: `${a}-nav-links ${a}-nav-links-${
|
|
1781
|
-
style: { transform:
|
|
1807
|
+
className: `${a}-nav-links ${a}-nav-links-${at}`,
|
|
1808
|
+
style: { transform: Kn(at, on, t) },
|
|
1782
1809
|
"aria-label": "Navigation",
|
|
1783
|
-
children: /* @__PURE__ */ s("div", { className: `${a}-nav-links-inner`, children:
|
|
1810
|
+
children: /* @__PURE__ */ s("div", { className: `${a}-nav-links-inner`, children: dt.filter((i) => Zn(i, w, d)).map((i, l) => Hn(i, l)) })
|
|
1784
1811
|
}
|
|
1785
1812
|
)
|
|
1786
1813
|
] }) }),
|
|
1787
|
-
|
|
1788
|
-
/* @__PURE__ */ C("div", { className: `${a}-nav-toggle-wrap ${a}-nav-toggle-wrap-${
|
|
1789
|
-
|
|
1790
|
-
|
|
1814
|
+
zn,
|
|
1815
|
+
/* @__PURE__ */ C("div", { className: `${a}-nav-toggle-wrap ${a}-nav-toggle-wrap-${Bo}`, children: [
|
|
1816
|
+
Bo === "left" ? vo("left") : null,
|
|
1817
|
+
nn ? /* @__PURE__ */ s(
|
|
1791
1818
|
"div",
|
|
1792
1819
|
{
|
|
1793
|
-
className: `${a}-root ${
|
|
1794
|
-
style:
|
|
1795
|
-
children:
|
|
1820
|
+
className: `${a}-root ${Cn}`.trim(),
|
|
1821
|
+
style: $n,
|
|
1822
|
+
children: Bn()
|
|
1796
1823
|
}
|
|
1797
1824
|
) : null,
|
|
1798
|
-
|
|
1825
|
+
Bo === "right" ? vo("right") : null
|
|
1799
1826
|
] })
|
|
1800
1827
|
]
|
|
1801
1828
|
}
|
|
1802
1829
|
);
|
|
1803
1830
|
}
|
|
1804
1831
|
export {
|
|
1805
|
-
|
|
1806
|
-
|
|
1832
|
+
Wa as Burger,
|
|
1833
|
+
ga as applyBurgerSettingsChange,
|
|
1834
|
+
Qn as isBurgerOpenMenuAvailable
|
|
1807
1835
|
};
|