quirk-ui 0.1.112 → 0.1.113

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.
@@ -1,22 +1,22 @@
1
- import { jsx as n, jsxs as i, Fragment as re } from "react/jsx-runtime";
2
- import { useState as v, useRef as U, useCallback as _, useEffect as F } from "react";
3
- import { Modal as se } from "../Modal/index.mjs";
4
- import { B as J, M as ze } from "../../../index-CnlJ2RgH.js";
5
- import { ButtonGroup as ce } from "../ButtonGroup/index.mjs";
6
- import { s as e, N as xe } from "../../../NavLink-C7jlTfri.js";
7
- import { lockScroll as Ae, unlockScroll as oe } from "../../utils/NoScroll/noScroll.mjs";
8
- import { C as Re } from "../../../chevron-right-Cim1KPuL.js";
9
- import { E as X } from "../../../external-link-BOPobeQJ.js";
10
- import { X as Be } from "../../../x-CnsEH4Ox.js";
11
- import { c as de } from "../../../createLucideIcon-C8GTh_Qx.js";
12
- import { C as Oe } from "../../../chevron-down-DSUzBz9F.js";
1
+ import { jsx as a, jsxs as i, Fragment as se } from "react/jsx-runtime";
2
+ import { useState as v, useRef as F, useCallback as _, useEffect as z } from "react";
3
+ import { Modal as ce } from "../Modal/index.mjs";
4
+ import { B as J, M as Ae } from "../../../index-CnlJ2RgH.js";
5
+ import { ButtonGroup as oe } from "../ButtonGroup/index.mjs";
6
+ import { s as e, N as Re } from "../../../NavLink-CaWX-AXn.js";
7
+ import { lockScroll as Be, unlockScroll as de } from "../../utils/NoScroll/noScroll.mjs";
8
+ import { C as Oe } from "../../../chevron-right-Cim1KPuL.js";
9
+ import { E as Y } from "../../../external-link-BOPobeQJ.js";
10
+ import { X as We } from "../../../x-CnsEH4Ox.js";
11
+ import { c as ue } from "../../../createLucideIcon-C8GTh_Qx.js";
12
+ import { C as De } from "../../../chevron-down-DSUzBz9F.js";
13
13
  /**
14
14
  * @license lucide-react v0.488.0 - ISC
15
15
  *
16
16
  * This source code is licensed under the ISC license.
17
17
  * See the LICENSE file in the root directory of this source tree.
18
18
  */
19
- const We = [
19
+ const Ue = [
20
20
  ["path", { d: "M21.54 15H17a2 2 0 0 0-2 2v4.54", key: "1djwo0" }],
21
21
  [
22
22
  "path",
@@ -27,47 +27,47 @@ const We = [
27
27
  ],
28
28
  ["path", { d: "M11 21.95V18a2 2 0 0 0-2-2a2 2 0 0 1-2-2v-1a2 2 0 0 0-2-2H2.05", key: "14pb5j" }],
29
29
  ["circle", { cx: "12", cy: "12", r: "10", key: "1mglay" }]
30
- ], De = de("earth", We);
30
+ ], Fe = ue("earth", Ue);
31
31
  /**
32
32
  * @license lucide-react v0.488.0 - ISC
33
33
  *
34
34
  * This source code is licensed under the ISC license.
35
35
  * See the LICENSE file in the root directory of this source tree.
36
36
  */
37
- const Ue = [
37
+ const je = [
38
38
  ["circle", { cx: "11", cy: "11", r: "8", key: "4ej97u" }],
39
39
  ["path", { d: "m21 21-4.3-4.3", key: "1qie3q" }]
40
- ], Fe = de("search", Ue), je = {
40
+ ], Ge = ue("search", je), Pe = {
41
41
  standard: e.standard,
42
42
  transparent: e.transparent
43
- }, Ge = {
43
+ }, qe = {
44
44
  left: e.left,
45
45
  center: e.center,
46
46
  right: e.right
47
- }, Pe = ({
47
+ }, Ke = ({
48
48
  spotlight: s,
49
49
  renderText: k
50
50
  }) => {
51
- var h, z, g, w, C, x;
51
+ var h, x, g, w, C, A;
52
52
  const o = s.callToAction;
53
53
  if (!o) return null;
54
54
  const $ = ((h = o.linkOptions) == null ? void 0 : h.linkType) === "external";
55
55
  let m = "#";
56
- return $ && ((z = o.linkOptions) != null && z.externalUrl) ? m = o.linkOptions.externalUrl : ((g = o.linkOptions) == null ? void 0 : g.linkType) === "internal" && ((C = (w = o.linkOptions) == null ? void 0 : w.internalUrl) != null && C.slug.current) && (m = `/${o.linkOptions.internalUrl.slug.current}`), /* @__PURE__ */ i("div", { className: e.spotlight, children: [
57
- s.image && /* @__PURE__ */ n("div", { className: e.imageWrapper, children: /* @__PURE__ */ n(
56
+ return $ && ((x = o.linkOptions) != null && x.externalUrl) ? m = o.linkOptions.externalUrl : ((g = o.linkOptions) == null ? void 0 : g.linkType) === "internal" && ((C = (w = o.linkOptions) == null ? void 0 : w.internalUrl) != null && C.slug.current) && (m = `/${o.linkOptions.internalUrl.slug.current}`), /* @__PURE__ */ i("div", { className: e.spotlight, children: [
57
+ s.image && /* @__PURE__ */ a("div", { className: e.imageWrapper, children: /* @__PURE__ */ a(
58
58
  "img",
59
59
  {
60
- src: ((x = s.image.imageUrls) == null ? void 0 : x.medium) ?? "",
60
+ src: ((A = s.image.imageUrls) == null ? void 0 : A.medium) ?? "",
61
61
  alt: s.image.asset.altText || s.image.asset.description || "Content image",
62
62
  width: 600,
63
63
  height: 400
64
64
  }
65
65
  ) }),
66
66
  /* @__PURE__ */ i("div", { className: e.content, children: [
67
- s.title && /* @__PURE__ */ n("div", { className: e.title, children: k == null ? void 0 : k(s.title, e.title) }),
68
- s.description && /* @__PURE__ */ n("div", { className: e.description, children: k == null ? void 0 : k(s.description, e.description) })
67
+ s.title && /* @__PURE__ */ a("div", { className: e.title, children: k == null ? void 0 : k(s.title, e.title) }),
68
+ s.description && /* @__PURE__ */ a("div", { className: e.description, children: k == null ? void 0 : k(s.description, e.description) })
69
69
  ] }),
70
- o.linkOptions && /* @__PURE__ */ n("div", { className: e.actions, children: /* @__PURE__ */ n(
70
+ o.linkOptions && /* @__PURE__ */ a("div", { className: e.actions, children: /* @__PURE__ */ a(
71
71
  J,
72
72
  {
73
73
  as: "a",
@@ -81,193 +81,197 @@ const Ue = [
81
81
  ) })
82
82
  ] });
83
83
  };
84
- function an({
84
+ function rn({
85
85
  renderText: s,
86
86
  title: k,
87
87
  logo: o,
88
88
  items: $,
89
89
  groups: m,
90
90
  utilityItems: h,
91
- isSticky: z = !1,
91
+ isSticky: x = !1,
92
92
  showSearch: g = !0,
93
93
  showLocaleSelect: w = !0,
94
94
  showThemeToggle: C = !0,
95
- themeToggleComponent: x,
95
+ themeToggleComponent: A,
96
96
  alignment: j = "right",
97
- variant: ue = "standard",
98
- navigationType: A = "default",
99
- searchComponent: me,
100
- localeSelectComponent: he,
101
- className: fe,
102
- style: be,
103
- ...pe
97
+ variant: me = "standard",
98
+ navigationType: R = "default",
99
+ searchComponent: he,
100
+ localeSelectComponent: fe,
101
+ className: be,
102
+ style: pe,
103
+ ...ve
104
104
  }) {
105
- const [f, Q] = v(!1), [Y, N] = v(null), [ve, ke] = v(0), [ge, Ne] = v(!1), [ye, $e] = v(null), [d, E] = v([]), [R, G] = v(
105
+ const [f, Q] = v(!1), [Z, N] = v(null), [ke, ge] = v(0), [Ne, ye] = v(!1), [G, $e] = v(!1), [we, Ce] = v(null), [d, M] = v([]), [B, P] = v(
106
106
  0
107
- ), [we, Z] = v(null), [I, Ce] = v(!1), [B, O] = v("forward"), P = U(null), y = U(null), T = U(null), q = U(/* @__PURE__ */ new Map()), ee = () => /* @__PURE__ */ n(
107
+ ), [Ee, T] = v(null), [I, Me] = v(!1), [O, W] = v("forward"), q = F(null), y = F(null), ee = F(null), K = F(/* @__PURE__ */ new Map()), ne = () => /* @__PURE__ */ a(
108
108
  "div",
109
109
  {
110
110
  className: `${e.linkWrapper} ${e.parent}`,
111
111
  role: "presentation",
112
- children: /* @__PURE__ */ n(
112
+ children: /* @__PURE__ */ a(
113
113
  "div",
114
114
  {
115
115
  className: `${e.linkItem} ${e.themeToggle}`,
116
116
  role: "presentation",
117
- children: x
117
+ children: A
118
118
  }
119
119
  )
120
120
  }
121
- ), K = () => /* @__PURE__ */ n(
121
+ ), V = () => /* @__PURE__ */ a(
122
122
  "div",
123
123
  {
124
124
  className: `${e.linkWrapper} ${e.parent} ${e.searchWrapper}`,
125
- children: /* @__PURE__ */ n("div", { className: e.linkItem, children: /* @__PURE__ */ n(
126
- se,
125
+ children: /* @__PURE__ */ a("div", { className: e.linkItem, children: /* @__PURE__ */ a(
126
+ ce,
127
127
  {
128
128
  size: "lg",
129
129
  className: e.searchModal,
130
- trigger: /* @__PURE__ */ n(
130
+ trigger: /* @__PURE__ */ a(
131
131
  "button",
132
132
  {
133
133
  title: "Search",
134
134
  "aria-label": "Search",
135
135
  className: e.search,
136
- children: /* @__PURE__ */ n(Fe, { size: 16, "aria-hidden": "true" })
136
+ children: /* @__PURE__ */ a(Ge, { size: 16, "aria-hidden": "true" })
137
137
  }
138
138
  ),
139
- content: me
139
+ content: he
140
140
  }
141
141
  ) })
142
142
  }
143
- ), ne = () => /* @__PURE__ */ n("div", { className: `${e.linkWrapper} ${e.parent}`, children: /* @__PURE__ */ n("div", { className: e.linkItem, children: /* @__PURE__ */ n(
144
- se,
143
+ ), ae = () => /* @__PURE__ */ a("div", { className: `${e.linkWrapper} ${e.parent}`, children: /* @__PURE__ */ a("div", { className: e.linkItem, children: /* @__PURE__ */ a(
144
+ ce,
145
145
  {
146
146
  className: e.localeModal,
147
- trigger: /* @__PURE__ */ n(
147
+ trigger: /* @__PURE__ */ a(
148
148
  "button",
149
149
  {
150
150
  title: "Locale Select",
151
151
  "aria-label": "Locale Select",
152
152
  className: e.locale,
153
- children: /* @__PURE__ */ n(De, { size: 16, "aria-hidden": "true" })
153
+ children: /* @__PURE__ */ a(Fe, { size: 16, "aria-hidden": "true" })
154
154
  }
155
155
  ),
156
- content: he
156
+ content: fe
157
157
  }
158
- ) }) }), W = _(() => {
159
- y.current && ke(y.current.getBoundingClientRect().width);
160
- }, []), ae = () => {
161
- Q((a) => {
162
- const l = !a;
163
- return l || (E([]), O("forward"), N(null)), l;
158
+ ) }) }), D = _(() => {
159
+ y.current && ge(y.current.getBoundingClientRect().width);
160
+ }, []), le = () => {
161
+ Q((n) => {
162
+ const l = !n;
163
+ return l || (M([]), W("forward"), N(null)), l;
164
164
  });
165
- }, le = _((a) => {
166
- const l = q.current.get(a);
165
+ }, ie = _((n) => {
166
+ const l = K.current.get(n);
167
167
  if (l && y.current) {
168
- const c = l.getBoundingClientRect(), r = y.current.getBoundingClientRect();
169
- $e(c.left - r.left + c.width / 2);
168
+ const c = l.getBoundingClientRect(), t = y.current.getBoundingClientRect();
169
+ Ce(c.left - t.left + c.width / 2);
170
170
  }
171
- }, []), Me = _((a) => {
172
- N((l) => l === a ? null : a);
173
- }, []), V = _((a) => {
174
- P.current && !P.current.contains(a.target) && N(null);
175
- }, []), H = _(() => {
176
- W(), typeof window < "u" && window.innerWidth > 768 && (Q(!1), N(null));
177
- }, [W]), Ee = () => E([]), Ie = (a) => {
178
- O("forward"), E([
171
+ }, []), Ie = _((n) => {
172
+ N((l) => l === n ? null : n);
173
+ }, []), H = _((n) => {
174
+ q.current && !q.current.contains(n.target) && N(null);
175
+ }, []), X = _(() => {
176
+ D(), typeof window < "u" && window.innerWidth > 768 && (Q(!1), N(null));
177
+ }, [D]), Le = () => M([]), Se = (n) => {
178
+ W("forward"), M([
179
179
  {
180
- title: a.title,
181
- primary: a.primaryItems ?? [],
182
- secondary: a.secondaryItems ?? [],
180
+ title: n.title,
181
+ primary: n.primaryItems ?? [],
182
+ secondary: n.secondaryItems ?? [],
183
183
  description: ""
184
184
  }
185
185
  ]);
186
- }, ie = (a) => {
187
- O("forward"), E((l) => [
186
+ }, re = (n) => {
187
+ W("forward"), M((l) => [
188
188
  ...l,
189
189
  {
190
- title: a.label,
191
- primary: a.sublinks ?? [],
190
+ title: n.label,
191
+ primary: n.sublinks ?? [],
192
192
  secondary: [],
193
- description: a.description
193
+ description: n.description
194
194
  }
195
195
  ]);
196
- }, Le = () => {
197
- O("backward"), E((a) => a.slice(0, -1));
196
+ }, _e = () => {
197
+ W("backward"), M((n) => n.slice(0, -1));
198
198
  };
199
- F(() => {
199
+ z(() => {
200
200
  if (typeof window > "u") return;
201
- const a = () => Ce(window.innerWidth < 768);
202
- return a(), window.addEventListener("resize", a), () => window.removeEventListener("resize", a);
203
- }, []), F(() => {
204
- const a = typeof window < "u", l = typeof document < "u";
205
- return a && window.addEventListener("resize", H), l && document.addEventListener("click", V), W(), Ne(!0), () => {
206
- a && window.removeEventListener("resize", H), l && document.removeEventListener("click", V);
201
+ const n = () => Me(window.innerWidth < 768);
202
+ return n(), window.addEventListener("resize", n), () => window.removeEventListener("resize", n);
203
+ }, []), z(() => {
204
+ if (typeof window > "u") return;
205
+ const n = () => $e(window.scrollY > 10);
206
+ return n(), window.addEventListener("scroll", n, { passive: !0 }), () => window.removeEventListener("scroll", n);
207
+ }, []), z(() => {
208
+ const n = typeof window < "u", l = typeof document < "u";
209
+ return n && window.addEventListener("resize", X), l && document.addEventListener("click", H), D(), ye(!0), () => {
210
+ n && window.removeEventListener("resize", X), l && document.removeEventListener("click", H);
207
211
  };
208
- }, [H, V, W]), F(() => {
212
+ }, [X, H, D]), z(() => {
209
213
  if (!(typeof document > "u"))
210
- return f ? setTimeout(() => Ae(), 0) : oe(), () => oe();
211
- }, [f]), F(() => {
214
+ return f ? setTimeout(() => Be(), 0) : de(), () => de();
215
+ }, [f]), z(() => {
212
216
  var c;
213
217
  if (!f) return;
214
218
  if (typeof window < "u" && typeof window.matchMedia == "function" && window.matchMedia("(pointer: fine)").matches) {
215
- const r = (c = y.current) == null ? void 0 : c.querySelector(
219
+ const t = (c = y.current) == null ? void 0 : c.querySelector(
216
220
  'a[href], button:not([disabled]), input, select, textarea, [tabindex]:not([tabindex="-1"])'
217
221
  );
218
- r == null || r.focus();
222
+ t == null || t.focus();
219
223
  }
220
- const l = (r) => {
224
+ const l = (t) => {
221
225
  var S;
222
- if (r.key === "Escape") {
223
- ae(), (S = T.current) == null || S.focus();
226
+ if (t.key === "Escape") {
227
+ le(), (S = ee.current) == null || S.focus();
224
228
  return;
225
229
  }
226
- if (r.key !== "Tab" || !y.current) return;
230
+ if (t.key !== "Tab" || !y.current) return;
227
231
  const p = Array.from(
228
232
  y.current.querySelectorAll(
229
233
  'a[href], button:not([disabled]), input, select, textarea, [tabindex]:not([tabindex="-1"])'
230
234
  )
231
- ).filter((t) => !t.closest("[aria-hidden=true]"));
235
+ ).filter((r) => !r.closest("[aria-hidden=true]"));
232
236
  if (p.length === 0) return;
233
237
  const b = p[0], L = p[p.length - 1];
234
- r.shiftKey ? document.activeElement === b && (r.preventDefault(), L.focus()) : document.activeElement === L && (r.preventDefault(), b.focus());
238
+ t.shiftKey ? document.activeElement === b && (t.preventDefault(), L.focus()) : document.activeElement === L && (t.preventDefault(), b.focus());
235
239
  };
236
240
  return document.addEventListener("keydown", l), () => document.removeEventListener("keydown", l);
237
241
  }, [f]);
238
- const D = (a, l = "") => a.map((c, r) => {
239
- const p = `${l}/${c._key ?? c.label}-${r}`;
240
- return /* @__PURE__ */ n(
241
- xe,
242
+ const U = (n, l = "") => n.map((c, t) => {
243
+ const p = `${l}/${c._key ?? c.label}-${t}`;
244
+ return /* @__PURE__ */ a(
245
+ Re,
242
246
  {
243
247
  link: c,
244
248
  path: p,
245
249
  parentPath: l,
246
- openPath: Y,
247
- togglePath: Me,
248
- updateTriangleIndicator: le,
250
+ openPath: Z,
251
+ togglePath: Ie,
252
+ updateTriangleIndicator: ie,
249
253
  setOpenPath: N,
250
- renderLinks: D,
251
- buttonRefs: q
254
+ renderLinks: U,
255
+ buttonRefs: K
252
256
  },
253
257
  p
254
258
  );
255
- }), Se = (a) => a.map((l, c) => {
259
+ }), ze = (n) => n.map((l, c) => {
256
260
  var L, S;
257
- const r = `group-${c}`, p = we === c, b = (L = l.primaryItems) == null ? void 0 : L[R ?? 0];
261
+ const t = `group-${c}`, p = Ee === c, b = (L = l.primaryItems) == null ? void 0 : L[B ?? 0];
258
262
  return /* @__PURE__ */ i(
259
263
  "div",
260
264
  {
261
265
  className: `${e.linkWrapper} ${e.parent}`,
262
266
  onMouseEnter: () => {
263
- Z(c), N(r), le(r);
267
+ T(c), N(t), ie(t);
264
268
  },
265
269
  children: [
266
- /* @__PURE__ */ n("div", { className: e.linkItem, children: /* @__PURE__ */ i(
270
+ /* @__PURE__ */ a("div", { className: e.linkItem, children: /* @__PURE__ */ i(
267
271
  "button",
268
272
  {
269
- ref: (t) => {
270
- q.current.set(r, t);
273
+ ref: (r) => {
274
+ K.current.set(t, r);
271
275
  },
272
276
  "aria-haspopup": !0,
273
277
  "aria-expanded": p,
@@ -275,8 +279,8 @@ function an({
275
279
  className: `${e.sublinkToggle} ${p ? e.open : ""}`,
276
280
  children: [
277
281
  l.title,
278
- /* @__PURE__ */ n(
279
- Oe,
282
+ /* @__PURE__ */ a(
283
+ De,
280
284
  {
281
285
  size: 18,
282
286
  className: e.chevron,
@@ -286,7 +290,7 @@ function an({
286
290
  ]
287
291
  }
288
292
  ) }),
289
- /* @__PURE__ */ n(
293
+ /* @__PURE__ */ a(
290
294
  "div",
291
295
  {
292
296
  id: `submenu-${c}`,
@@ -294,9 +298,9 @@ function an({
294
298
  role: "menu",
295
299
  "aria-label": `${l.title} submenu`,
296
300
  onMouseLeave: () => {
297
- Z(null), G(0), N(null);
301
+ T(null), P(0), N(null);
298
302
  },
299
- children: /* @__PURE__ */ n("div", { children: /* @__PURE__ */ i(
303
+ children: /* @__PURE__ */ a("div", { children: /* @__PURE__ */ i(
300
304
  "div",
301
305
  {
302
306
  className: `${e.sublinksInner} ${l.spotlight ? e.withSpotlight : e.withoutSpotlight}`,
@@ -306,27 +310,27 @@ function an({
306
310
  {
307
311
  className: `${e.sublinksColumn} ${e.primaryColumn}`,
308
312
  children: [
309
- /* @__PURE__ */ n("div", { className: e.linkItem }),
313
+ /* @__PURE__ */ a("div", { className: e.linkItem }),
310
314
  (S = l.primaryItems) == null ? void 0 : S.map(
311
- (t, M) => t.href ? /* @__PURE__ */ n("div", { role: "menuitem", children: /* @__PURE__ */ i(
315
+ (r, E) => r.href ? /* @__PURE__ */ a("div", { role: "menuitem", children: /* @__PURE__ */ i(
312
316
  "a",
313
317
  {
314
- href: t.href,
315
- className: `${e.link} ${R === M ? e.open : ""}`,
316
- target: t.isExternal ? "_blank" : "_self",
317
- rel: t.isExternal ? "noopener noreferrer" : void 0,
318
+ href: r.href,
319
+ className: `${e.link} ${B === E ? e.open : ""}`,
320
+ target: r.isExternal ? "_blank" : "_self",
321
+ rel: r.isExternal ? "noopener noreferrer" : void 0,
318
322
  onClick: () => {
319
323
  var te;
320
- N(null), (te = t.onClick) == null || te.call(t);
324
+ N(null), (te = r.onClick) == null || te.call(r);
321
325
  },
322
- onMouseEnter: () => G(M),
326
+ onMouseEnter: () => P(E),
323
327
  children: [
324
328
  /* @__PURE__ */ i("span", { className: e.linkContent, children: [
325
- t.label,
326
- t.subtitle && /* @__PURE__ */ n("span", { className: e.subtitle, children: t.subtitle })
329
+ r.label,
330
+ r.subtitle && /* @__PURE__ */ a("span", { className: e.subtitle, children: r.subtitle })
327
331
  ] }),
328
- t.isExternal && /* @__PURE__ */ n(
329
- X,
332
+ r.isExternal && /* @__PURE__ */ a(
333
+ Y,
330
334
  {
331
335
  className: e.newTabIcon,
332
336
  size: 16,
@@ -335,17 +339,17 @@ function an({
335
339
  )
336
340
  ]
337
341
  }
338
- ) }, t._key ?? M) : /* @__PURE__ */ n("div", { role: "menuitem", children: /* @__PURE__ */ n(
342
+ ) }, r._key ?? E) : /* @__PURE__ */ a("div", { role: "menuitem", children: /* @__PURE__ */ a(
339
343
  "button",
340
344
  {
341
- className: `${e.sublinkToggle} ${R === M ? e.open : ""}`,
342
- onMouseEnter: () => G(M),
345
+ className: `${e.sublinkToggle} ${B === E ? e.open : ""}`,
346
+ onMouseEnter: () => P(E),
343
347
  children: /* @__PURE__ */ i("span", { className: e.linkContent, children: [
344
- t.label,
345
- t.subtitle && /* @__PURE__ */ n("span", { className: e.subtitle, children: t.subtitle })
348
+ r.label,
349
+ r.subtitle && /* @__PURE__ */ a("span", { className: e.subtitle, children: r.subtitle })
346
350
  ] })
347
351
  }
348
- ) }, t._key ?? M)
352
+ ) }, r._key ?? E)
349
353
  )
350
354
  ]
351
355
  }
@@ -355,28 +359,28 @@ function an({
355
359
  {
356
360
  className: `${e.sublinksColumn} ${e.fadeInFromLeft}`,
357
361
  children: [
358
- b.description && /* @__PURE__ */ n("div", { className: e.sublinksDescription, children: s == null ? void 0 : s(b.description) }),
359
- D(
362
+ b.description && /* @__PURE__ */ a("div", { className: e.sublinksDescription, children: s == null ? void 0 : s(b.description) }),
363
+ U(
360
364
  b.sublinks,
361
- `${r}-${R}`
365
+ `${t}-${B}`
362
366
  )
363
367
  ]
364
368
  },
365
369
  `${b.label}-${b.sublinks.length}`
366
370
  ),
367
- l.secondaryItems && l.secondaryItems.length > 0 && /* @__PURE__ */ n(
371
+ l.secondaryItems && l.secondaryItems.length > 0 && /* @__PURE__ */ a(
368
372
  "div",
369
373
  {
370
374
  className: `${e.sublinksColumn} ${e.secondaryColumn}`,
371
- children: D(l.secondaryItems, `${r}-secondary`)
375
+ children: U(l.secondaryItems, `${t}-secondary`)
372
376
  }
373
377
  ),
374
- l.spotlight && /* @__PURE__ */ n(
378
+ l.spotlight && /* @__PURE__ */ a(
375
379
  "div",
376
380
  {
377
381
  className: `${e.sublinksColumn} ${e.spotlightColumn}`,
378
- children: /* @__PURE__ */ n(
379
- Pe,
382
+ children: /* @__PURE__ */ a(
383
+ Ke,
380
384
  {
381
385
  spotlight: l.spotlight,
382
386
  renderText: s
@@ -393,51 +397,52 @@ function an({
393
397
  },
394
398
  l._key ?? `group-${c}`
395
399
  );
396
- }), _e = [
400
+ }), xe = [
397
401
  e.navbar,
398
- Ge[j],
399
- je[ue],
400
- z ? e.sticky : "",
402
+ qe[j],
403
+ Pe[me],
404
+ x ? e.sticky : "",
405
+ G ? e.scrolled : "",
401
406
  m != null && m.length ? e.advanced : e.default,
402
- fe ?? ""
407
+ be ?? ""
403
408
  ].filter(Boolean).join(" "), u = h && h.length > 0 ? h[Math.min(1, h.length - 1)] : null;
404
- return /* @__PURE__ */ n(
409
+ return /* @__PURE__ */ a(
405
410
  "header",
406
411
  {
407
- ref: P,
408
- className: _e,
409
- style: be,
412
+ ref: q,
413
+ className: xe,
414
+ style: pe,
410
415
  "aria-label": "Site header",
411
- ...pe,
416
+ ...ve,
412
417
  children: /* @__PURE__ */ i(
413
418
  "div",
414
419
  {
415
420
  className: `${e.container} ${(!h || h.length === 0) && j !== "center" ? e.twoColumn : ""}`,
416
421
  children: [
417
- o ? /* @__PURE__ */ n("div", { className: e.logo, children: o }) : k ? /* @__PURE__ */ n("div", { className: e.title, children: k }) : null,
418
- /* @__PURE__ */ n(
422
+ o ? /* @__PURE__ */ a("div", { className: e.logo, children: o }) : k ? /* @__PURE__ */ a("div", { className: e.title, children: k }) : null,
423
+ /* @__PURE__ */ a(
419
424
  "nav",
420
425
  {
421
426
  ref: y,
422
427
  style: {
423
- left: j === "center" ? `calc(50% - ${ve / 2}px)` : "0"
428
+ left: j === "center" ? `calc(50% - ${ke / 2}px)` : "0"
424
429
  },
425
430
  "aria-modal": f ? "true" : void 0,
426
- className: `${e.nav} ${f ? e.open : ""} ${ge ? e.visible : e.hidden}`,
431
+ className: `${e.nav} ${f ? e.open : ""} ${Ne ? e.visible : e.hidden}`,
427
432
  id: "main-menu",
428
433
  "aria-label": "Primary navigation",
429
434
  children: /* @__PURE__ */ i("div", { className: e.navInner, children: [
430
- /* @__PURE__ */ n(
435
+ /* @__PURE__ */ a(
431
436
  "svg",
432
437
  {
433
- style: { left: `${ye}px` },
434
- className: `${e.triangle} ${Y ? e.show : ""}`,
438
+ style: { left: `${we}px` },
439
+ className: `${e.triangle} ${Z ? e.show : ""}`,
435
440
  width: 16,
436
441
  height: 12,
437
442
  viewBox: "0 0 100 75",
438
443
  xmlns: "http://www.w3.org/2000/svg",
439
444
  "aria-hidden": "true",
440
- children: /* @__PURE__ */ n(
445
+ children: /* @__PURE__ */ a(
441
446
  "polygon",
442
447
  {
443
448
  points: "50,5 95,70 5,70",
@@ -448,10 +453,10 @@ function an({
448
453
  )
449
454
  }
450
455
  ),
451
- A === "default" && $ && /* @__PURE__ */ i("div", { className: e.grid, children: [
452
- $.length > 0 && /* @__PURE__ */ n("div", { role: "menubar", className: e.menubar, children: D($) }),
453
- (g || w || C) && /* @__PURE__ */ i(re, { children: [
454
- /* @__PURE__ */ n("span", { className: e.separator, "aria-hidden": "true" }),
456
+ R === "default" && $ && /* @__PURE__ */ i("div", { className: e.grid, children: [
457
+ $.length > 0 && /* @__PURE__ */ a("div", { role: "menubar", className: e.menubar, children: U($) }),
458
+ (g || w || C) && /* @__PURE__ */ i(se, { children: [
459
+ /* @__PURE__ */ a("span", { className: e.separator, "aria-hidden": "true" }),
455
460
  /* @__PURE__ */ i(
456
461
  "div",
457
462
  {
@@ -459,18 +464,18 @@ function an({
459
464
  "aria-label": "Site controls",
460
465
  className: e.toolbar,
461
466
  children: [
462
- C && /* @__PURE__ */ n(ee, {}),
463
- g && !I && /* @__PURE__ */ n(K, {}),
464
- w && /* @__PURE__ */ n(ne, {})
467
+ C && /* @__PURE__ */ a(ne, {}),
468
+ g && !I && /* @__PURE__ */ a(V, {}),
469
+ w && /* @__PURE__ */ a(ae, {})
465
470
  ]
466
471
  }
467
472
  )
468
473
  ] })
469
474
  ] }),
470
- !I && A === "advanced" && m && /* @__PURE__ */ i("div", { className: e.grid, children: [
471
- m.length > 0 && /* @__PURE__ */ n("div", { role: "menubar", className: e.menubar, children: Se(m) }),
472
- (g || w || C) && /* @__PURE__ */ i(re, { children: [
473
- /* @__PURE__ */ n("span", { className: e.separator, "aria-hidden": "true" }),
475
+ !I && R === "advanced" && m && /* @__PURE__ */ i("div", { className: e.grid, children: [
476
+ m.length > 0 && /* @__PURE__ */ a("div", { role: "menubar", className: e.menubar, children: ze(m) }),
477
+ (g || w || C) && /* @__PURE__ */ i(se, { children: [
478
+ /* @__PURE__ */ a("span", { className: e.separator, "aria-hidden": "true" }),
474
479
  /* @__PURE__ */ i(
475
480
  "div",
476
481
  {
@@ -478,81 +483,81 @@ function an({
478
483
  "aria-label": "Site controls",
479
484
  className: e.toolbar,
480
485
  children: [
481
- C && /* @__PURE__ */ n(ee, {}),
482
- g && /* @__PURE__ */ n(K, {}),
483
- w && /* @__PURE__ */ n(ne, {})
486
+ C && /* @__PURE__ */ a(ne, {}),
487
+ g && /* @__PURE__ */ a(V, {}),
488
+ w && /* @__PURE__ */ a(ae, {})
484
489
  ]
485
490
  }
486
491
  )
487
492
  ] })
488
493
  ] }),
489
- I && A === "advanced" && f && d.length === 0 && m && /* @__PURE__ */ n("div", { className: e.mobileMenu, children: m.map((a, l) => /* @__PURE__ */ n(
494
+ I && R === "advanced" && f && d.length === 0 && m && /* @__PURE__ */ a("div", { className: e.mobileMenu, children: m.map((n, l) => /* @__PURE__ */ a(
490
495
  "div",
491
496
  {
492
- className: `${e.mobileMenuItem} ${B === "forward" ? e.fadeInFromLeft : e.fadeInFromRight}`,
493
- children: /* @__PURE__ */ n(
497
+ className: `${e.mobileMenuItem} ${O === "forward" ? e.fadeInFromLeft : e.fadeInFromRight}`,
498
+ children: /* @__PURE__ */ a(
494
499
  "button",
495
500
  {
496
501
  className: e.sublinkToggle,
497
- onClick: () => Ie(a),
498
- children: a.title
502
+ onClick: () => Se(n),
503
+ children: n.title
499
504
  }
500
505
  )
501
506
  },
502
- a._key ?? l
507
+ n._key ?? l
503
508
  )) }),
504
- I && A === "advanced" && f && d.length > 0 && /* @__PURE__ */ i(
509
+ I && R === "advanced" && f && d.length > 0 && /* @__PURE__ */ i(
505
510
  "div",
506
511
  {
507
512
  className: e.mobileMenuSlide,
508
513
  children: [
509
- /* @__PURE__ */ n(
514
+ /* @__PURE__ */ a(
510
515
  "button",
511
516
  {
512
517
  className: e.back,
513
518
  "aria-label": "Go back",
514
- onClick: d.length === 1 ? Ee : Le,
515
- children: /* @__PURE__ */ n(Re, { size: 18, "aria-hidden": "true" })
519
+ onClick: d.length === 1 ? Le : _e,
520
+ children: /* @__PURE__ */ a(Oe, { size: 18, "aria-hidden": "true" })
516
521
  }
517
522
  ),
518
- d[d.length - 1].description && /* @__PURE__ */ n(
523
+ d[d.length - 1].description && /* @__PURE__ */ a(
519
524
  "div",
520
525
  {
521
- className: `${e.sublinksDescription} ${B === "forward" ? e.fadeInFromLeft : e.fadeInFromRight}`,
526
+ className: `${e.sublinksDescription} ${O === "forward" ? e.fadeInFromLeft : e.fadeInFromRight}`,
522
527
  children: s == null ? void 0 : s(
523
528
  d[d.length - 1].description
524
529
  )
525
530
  }
526
531
  ),
527
- d[d.length - 1].primary.map((a, l) => /* @__PURE__ */ n(
532
+ d[d.length - 1].primary.map((n, l) => /* @__PURE__ */ a(
528
533
  "div",
529
534
  {
530
535
  role: "menuitem",
531
- className: `${e.mobileMenuItem} ${B === "forward" ? e.fadeInFromLeft : e.fadeInFromRight}`,
532
- children: a.sublinks ? /* @__PURE__ */ n(
536
+ className: `${e.mobileMenuItem} ${O === "forward" ? e.fadeInFromLeft : e.fadeInFromRight}`,
537
+ children: n.sublinks ? /* @__PURE__ */ a(
533
538
  "button",
534
539
  {
535
540
  className: e.sublinkToggle,
536
- onClick: () => ie(a),
541
+ onClick: () => re(n),
537
542
  children: /* @__PURE__ */ i("span", { className: e.linkContent, children: [
538
- a.label,
539
- a.subtitle && /* @__PURE__ */ n("span", { className: e.subtitle, children: a.subtitle })
543
+ n.label,
544
+ n.subtitle && /* @__PURE__ */ a("span", { className: e.subtitle, children: n.subtitle })
540
545
  ] })
541
546
  }
542
547
  ) : /* @__PURE__ */ i(
543
548
  "a",
544
549
  {
545
- href: a.href,
550
+ href: n.href,
546
551
  className: e.link,
547
- target: a.isExternal ? "_blank" : "_self",
548
- rel: a.isExternal ? "noopener noreferrer" : void 0,
552
+ target: n.isExternal ? "_blank" : "_self",
553
+ rel: n.isExternal ? "noopener noreferrer" : void 0,
549
554
  children: [
550
555
  /* @__PURE__ */ i("span", { className: e.linkContent, children: [
551
- a.label,
552
- a.subtitle && /* @__PURE__ */ n("span", { className: e.subtitle, children: a.subtitle })
556
+ n.label,
557
+ n.subtitle && /* @__PURE__ */ a("span", { className: e.subtitle, children: n.subtitle })
553
558
  ] }),
554
- a.isExternal && /* @__PURE__ */ n(
555
- X,
559
+ n.isExternal && /* @__PURE__ */ a(
560
+ Y,
556
561
  {
557
562
  className: e.newTabIcon,
558
563
  size: 16,
@@ -563,33 +568,33 @@ function an({
563
568
  }
564
569
  )
565
570
  },
566
- a._key ?? `primary-${l}`
571
+ n._key ?? `primary-${l}`
567
572
  )),
568
- d[d.length - 1].secondary.length > 0 && /* @__PURE__ */ n("hr", { className: e.groupDivider }),
573
+ d[d.length - 1].secondary.length > 0 && /* @__PURE__ */ a("hr", { className: e.groupDivider }),
569
574
  d[d.length - 1].secondary.map(
570
- (a, l) => /* @__PURE__ */ n(
575
+ (n, l) => /* @__PURE__ */ a(
571
576
  "div",
572
577
  {
573
578
  role: "menuitem",
574
- className: `${e.mobileMenuItem} ${B === "forward" ? e.fadeInFromLeft : e.fadeInFromRight}`,
575
- children: a.sublinks ? /* @__PURE__ */ n(
579
+ className: `${e.mobileMenuItem} ${O === "forward" ? e.fadeInFromLeft : e.fadeInFromRight}`,
580
+ children: n.sublinks ? /* @__PURE__ */ a(
576
581
  "button",
577
582
  {
578
583
  className: e.sublinkToggle,
579
- onClick: () => ie(a),
580
- children: a.label
584
+ onClick: () => re(n),
585
+ children: n.label
581
586
  }
582
587
  ) : /* @__PURE__ */ i(
583
588
  "a",
584
589
  {
585
- href: a.href,
590
+ href: n.href,
586
591
  className: e.link,
587
- target: a.isExternal ? "_blank" : "_self",
588
- rel: a.isExternal ? "noopener noreferrer" : void 0,
592
+ target: n.isExternal ? "_blank" : "_self",
593
+ rel: n.isExternal ? "noopener noreferrer" : void 0,
589
594
  children: [
590
- a.label,
591
- a.isExternal && /* @__PURE__ */ n(
592
- X,
595
+ n.label,
596
+ n.isExternal && /* @__PURE__ */ a(
597
+ Y,
593
598
  {
594
599
  className: e.newTabIcon,
595
600
  size: 16,
@@ -600,7 +605,7 @@ function an({
600
605
  }
601
606
  )
602
607
  },
603
- a._key ?? `secondary-${l}`
608
+ n._key ?? `secondary-${l}`
604
609
  )
605
610
  )
606
611
  ]
@@ -610,35 +615,43 @@ function an({
610
615
  ] })
611
616
  }
612
617
  ),
613
- h && h.length > 0 && /* @__PURE__ */ n("nav", { className: e.utility, "aria-label": "Utility navigation", children: /* @__PURE__ */ n(ce, { children: h.map((a, l) => /* @__PURE__ */ n(
614
- J,
618
+ h && h.length > 0 && /* @__PURE__ */ a(
619
+ "nav",
615
620
  {
616
- as: "a",
617
- size: "sm",
618
- href: a.href ?? "/",
619
- variant: a.variant ?? "primary",
620
- displayType: a.displayType ?? "text",
621
- imageSrc: a.imageSrc,
622
- imageAlt: a.imageAlt,
623
- "aria-label": a.ariaLabel,
624
- icon: a.icon,
625
- iconAlignment: a.iconAlignment,
626
- children: a.imageSrc ? /* @__PURE__ */ n(
627
- "img",
621
+ className: e.utility,
622
+ "data-scrolled": G,
623
+ "aria-label": "Utility navigation",
624
+ children: /* @__PURE__ */ a(oe, { children: h.map((n, l) => /* @__PURE__ */ a(
625
+ J,
628
626
  {
629
- src: a.imageSrc,
630
- alt: a.imageAlt ?? a.ariaLabel
631
- }
632
- ) : a.label
633
- },
634
- a._key ?? l
635
- )) }) }),
636
- u && /* @__PURE__ */ n(
627
+ as: "a",
628
+ size: "sm",
629
+ href: n.href ?? "/",
630
+ variant: n.variant === "link" && G ? "blurred" : n.variant ?? "primary",
631
+ displayType: n.displayType ?? "text",
632
+ imageSrc: n.imageSrc,
633
+ imageAlt: n.imageAlt,
634
+ "aria-label": n.ariaLabel,
635
+ icon: n.icon,
636
+ iconAlignment: n.iconAlignment,
637
+ children: n.imageSrc ? /* @__PURE__ */ a(
638
+ "img",
639
+ {
640
+ src: n.imageSrc,
641
+ alt: n.imageAlt ?? n.ariaLabel
642
+ }
643
+ ) : n.label
644
+ },
645
+ n._key ?? l
646
+ )) })
647
+ }
648
+ ),
649
+ u && /* @__PURE__ */ a(
637
650
  "nav",
638
651
  {
639
652
  "aria-label": "Utility navigation",
640
653
  className: `${e.utilityMobile} ${f ? e.open : ""}`,
641
- children: /* @__PURE__ */ n(ce, { alignment: "center", children: /* @__PURE__ */ n(
654
+ children: /* @__PURE__ */ a(oe, { alignment: "center", children: /* @__PURE__ */ a(
642
655
  J,
643
656
  {
644
657
  as: "a",
@@ -651,7 +664,7 @@ function an({
651
664
  "aria-label": u.ariaLabel,
652
665
  icon: u.icon,
653
666
  iconAlignment: u.iconAlignment,
654
- children: u.imageSrc ? /* @__PURE__ */ n(
667
+ children: u.imageSrc ? /* @__PURE__ */ a(
655
668
  "img",
656
669
  {
657
670
  src: u.imageSrc,
@@ -663,17 +676,17 @@ function an({
663
676
  }
664
677
  ),
665
678
  /* @__PURE__ */ i("div", { className: e.mobileButtons, children: [
666
- I && g && /* @__PURE__ */ n(K, {}),
667
- /* @__PURE__ */ n(
679
+ I && g && /* @__PURE__ */ a(V, {}),
680
+ /* @__PURE__ */ a(
668
681
  "button",
669
682
  {
670
- ref: T,
683
+ ref: ee,
671
684
  className: e.menuToggle,
672
- onClick: ae,
685
+ onClick: le,
673
686
  "aria-label": f ? "Close menu" : "Open menu",
674
687
  "aria-expanded": f,
675
688
  "aria-controls": "main-menu",
676
- children: f ? /* @__PURE__ */ n(Be, { size: 24, "aria-hidden": "true" }) : /* @__PURE__ */ n(ze, { size: 24, "aria-hidden": "true" })
689
+ children: f ? /* @__PURE__ */ a(We, { size: 24, "aria-hidden": "true" }) : /* @__PURE__ */ a(Ae, { size: 24, "aria-hidden": "true" })
677
690
  }
678
691
  )
679
692
  ] })
@@ -684,5 +697,5 @@ function an({
684
697
  );
685
698
  }
686
699
  export {
687
- an as Navbar
700
+ rn as Navbar
688
701
  };