@utahdts/utah-design-system-header 0.9.2 → 0.10.3
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/README.md +2 -2
- package/dist/style.css +1 -1
- package/dist/utah-design-system-header.es.js +706 -673
- package/dist/utah-design-system-header.umd.js +47 -42
- package/package.json +5 -11
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
const
|
|
1
|
+
const Y = {
|
|
2
2
|
FLYOUT: (
|
|
3
3
|
/** @type {ChildrenMenuType} */
|
|
4
4
|
"flyout"
|
|
@@ -11,7 +11,7 @@ const z = {
|
|
|
11
11
|
/** @type {ChildrenMenuType} */
|
|
12
12
|
"mega-menu"
|
|
13
13
|
)
|
|
14
|
-
},
|
|
14
|
+
}, $t = {
|
|
15
15
|
// Fired when the utah header is first loaded (setUtahHeaderSettings does not trigger this)
|
|
16
16
|
HEADER_LOADED: (
|
|
17
17
|
/** @type {Events} */
|
|
@@ -22,7 +22,7 @@ const z = {
|
|
|
22
22
|
/** @type {Events} */
|
|
23
23
|
"utahHeaderUnloaded"
|
|
24
24
|
)
|
|
25
|
-
},
|
|
25
|
+
}, Te = {
|
|
26
26
|
SMALL: (
|
|
27
27
|
/** @type {Size} */
|
|
28
28
|
"SMALL"
|
|
@@ -35,7 +35,7 @@ const z = {
|
|
|
35
35
|
/** @type {Size} */
|
|
36
36
|
"LARGE"
|
|
37
37
|
)
|
|
38
|
-
},
|
|
38
|
+
}, vn = `/* @media is never in scope for --variables, so this is the only way to solve this. :-( */
|
|
39
39
|
|
|
40
40
|
@media screen and (max-width: media-size__tablet-landscape__PLACEHOLDER) {
|
|
41
41
|
/* put your media query here for tablet landscape */
|
|
@@ -105,7 +105,7 @@ const z = {
|
|
|
105
105
|
@media screen and (max-width: media-size__mobile__PLACEHOLDER) {
|
|
106
106
|
/* put your media query here for mobile */
|
|
107
107
|
}
|
|
108
|
-
`,
|
|
108
|
+
`, bn = `<div class="utah-design-system utds-header-mobile-menu" id="utds-header-mobile-menu">
|
|
109
109
|
<div class="utds-header-mobile-menu__backdrop" aria-hidden></div>
|
|
110
110
|
<div class="utds-header-mobile-menu__wrapper">
|
|
111
111
|
<div class="utds-header-mobile-menu__action-bar" role="tablist">
|
|
@@ -188,8 +188,10 @@ const a = {
|
|
|
188
188
|
MAIN_MENU__SEARCH: "main-menu__search",
|
|
189
189
|
MAIN_MENU__TITLE: "main-menu__title",
|
|
190
190
|
MENU_ITEM: "menu-item",
|
|
191
|
+
MENU_ITEM__ARROW: "menu-item__menu-arrow",
|
|
191
192
|
MENU_ITEM__BUTTON_TITLE: "menu-item__button-title",
|
|
192
193
|
MENU_ITEM__LINK_TITLE: "menu-item__link-title",
|
|
194
|
+
MENU_ITEM__LINK_TITLE_SPAN: "menu-item__link-title-span",
|
|
193
195
|
MENU_ITEM__SELECTED: "menu-item--selected",
|
|
194
196
|
MENU_ITEM__TITLE: "menu-item__title",
|
|
195
197
|
MENU_ITEM__FLY_OUT: "menu-item--fly_out",
|
|
@@ -252,21 +254,21 @@ function X(e, t) {
|
|
|
252
254
|
if (e)
|
|
253
255
|
throw new Error(t);
|
|
254
256
|
}
|
|
255
|
-
function
|
|
257
|
+
function O(e, t) {
|
|
256
258
|
if (e == null)
|
|
257
259
|
throw new Error(t);
|
|
258
260
|
return e;
|
|
259
261
|
}
|
|
260
|
-
function
|
|
262
|
+
function wt(e) {
|
|
261
263
|
return typeof e == "string" || e instanceof String;
|
|
262
264
|
}
|
|
263
|
-
function
|
|
265
|
+
function In(e) {
|
|
264
266
|
const t = new DOMParser();
|
|
265
267
|
let n;
|
|
266
|
-
if (
|
|
268
|
+
if (wt(e)) {
|
|
267
269
|
const o = (
|
|
268
270
|
/** @type {Document} */
|
|
269
|
-
|
|
271
|
+
wt(e) ? t.parseFromString(e, "text/html") : e
|
|
270
272
|
), r = o.body.children.length > 1 ? o.body.children : o.body.children.item(0);
|
|
271
273
|
if (!r)
|
|
272
274
|
throw console.error(e), new Error("renderDOM: nothing rendered");
|
|
@@ -280,8 +282,8 @@ function En(e) {
|
|
|
280
282
|
throw e ? (console.error(e), new Error(`renderDOM: str is not a string nor a DOM Element : '${e}'`)) : new Error("renderDOM: falsy string passed; cannot render nothing");
|
|
281
283
|
return n;
|
|
282
284
|
}
|
|
283
|
-
function
|
|
284
|
-
const t = typeof e == "string" ?
|
|
285
|
+
function I(e) {
|
|
286
|
+
const t = typeof e == "string" ? In(e) : e;
|
|
285
287
|
if (t instanceof HTMLCollection && t.length > 1)
|
|
286
288
|
throw new Error("renderDOMSingle: must render a single element");
|
|
287
289
|
const n = (
|
|
@@ -301,16 +303,16 @@ const Ot = {
|
|
|
301
303
|
tabletLandscape: 1024
|
|
302
304
|
},
|
|
303
305
|
showTitle: !0,
|
|
304
|
-
size:
|
|
306
|
+
size: Te.MEDIUM,
|
|
305
307
|
title: "My Utah.gov Site",
|
|
306
308
|
titleURL: "/",
|
|
307
309
|
utahId: !1
|
|
308
310
|
};
|
|
309
|
-
function
|
|
311
|
+
function Tn(e) {
|
|
310
312
|
if (!e.showTitle && !e.logo)
|
|
311
313
|
throw new Error("validateSettings: A title must be shown if there is no logo. Please change the `showTitle` setting to be `true` or provide a logo image.");
|
|
312
314
|
}
|
|
313
|
-
class
|
|
315
|
+
class gn {
|
|
314
316
|
constructor() {
|
|
315
317
|
this.settings = { ...Ot };
|
|
316
318
|
}
|
|
@@ -319,7 +321,7 @@ class bn {
|
|
|
319
321
|
*/
|
|
320
322
|
setSettings(t) {
|
|
321
323
|
const n = { ...Ot, ...this.settings, ...t };
|
|
322
|
-
|
|
324
|
+
Tn(n), this.settings = n;
|
|
323
325
|
}
|
|
324
326
|
/**
|
|
325
327
|
* @returns {Settings}
|
|
@@ -328,11 +330,11 @@ class bn {
|
|
|
328
330
|
return this.settings;
|
|
329
331
|
}
|
|
330
332
|
}
|
|
331
|
-
const
|
|
332
|
-
function
|
|
333
|
-
return
|
|
333
|
+
const je = new gn();
|
|
334
|
+
function L() {
|
|
335
|
+
return je.getSettings();
|
|
334
336
|
}
|
|
335
|
-
const
|
|
337
|
+
const Mn = `<div class="utds-header-mobile-menu__content-item" role="tabpanel">
|
|
336
338
|
</div>
|
|
337
339
|
`;
|
|
338
340
|
function U() {
|
|
@@ -342,32 +344,32 @@ function U() {
|
|
|
342
344
|
(e) => (e ^ crypto.getRandomValues(new Uint8Array(1))[0] & (15 >> e) / 4).toString(16)
|
|
343
345
|
);
|
|
344
346
|
}
|
|
345
|
-
function
|
|
347
|
+
function nt(e) {
|
|
346
348
|
const t = document.querySelector(p(a.MOBILE_MENU__WRAPPER));
|
|
347
349
|
if (!t)
|
|
348
350
|
throw new Error("addMobileMenuContentItem: mobileMenuWrapper not found");
|
|
349
351
|
const n = t.querySelector(p(a.MOBILE_MENU__CONTENT));
|
|
350
352
|
if (!n)
|
|
351
353
|
throw new Error("addMobileMenuContentItem: mobileContentWrapper not found");
|
|
352
|
-
const o =
|
|
354
|
+
const o = I(Mn);
|
|
353
355
|
return o.appendChild(e), n.appendChild(o), o.setAttribute("id", U()), o;
|
|
354
356
|
}
|
|
355
357
|
function K(e) {
|
|
356
358
|
return typeof e == "function" ? e() : e;
|
|
357
359
|
}
|
|
358
|
-
function
|
|
360
|
+
function we(e) {
|
|
359
361
|
const t = (
|
|
360
362
|
/** @type {HTMLElement} */
|
|
361
|
-
|
|
363
|
+
O(
|
|
362
364
|
document.querySelector(p(a.MOBILE_MENU)),
|
|
363
365
|
`${e}: mobileMenu not found`
|
|
364
366
|
)
|
|
365
|
-
), n =
|
|
367
|
+
), n = O(
|
|
366
368
|
document.getElementById(a.MAIN_MENU__HAMBURGER_ID),
|
|
367
369
|
`${e}: hamburger not found (🍔 🎶 I will gladly pay you Tuesday for a hamburger today 🎵 🍔)`
|
|
368
370
|
), o = (
|
|
369
371
|
/** @type {HTMLElement} */
|
|
370
|
-
|
|
372
|
+
O(
|
|
371
373
|
document.getElementById(a.MAIN_MENU__HAMBURGER_ICON_ID),
|
|
372
374
|
`${e}: hamburgerIcon not found`
|
|
373
375
|
)
|
|
@@ -378,18 +380,18 @@ function Ae(e) {
|
|
|
378
380
|
mobileMenu: t
|
|
379
381
|
};
|
|
380
382
|
}
|
|
381
|
-
function
|
|
382
|
-
const { hamburger: e, hamburgerIcon: t, mobileMenu: n } =
|
|
383
|
-
e.setAttribute("aria-expanded", "false"), n.classList.remove(a.IS_OPEN), t.classList.add("utds-icon-before-hamburger"), t.classList.remove("utds-icon-before-x-icon");
|
|
383
|
+
function qe() {
|
|
384
|
+
const { hamburger: e, hamburgerIcon: t, mobileMenu: n } = we("hideMobileMenu");
|
|
385
|
+
e.setAttribute("aria-expanded", "false"), n.classList.remove(a.IS_OPEN), e.setAttribute("aria-label", "Open the mobile menu"), t.classList.add("utds-icon-before-hamburger"), t.classList.remove("utds-icon-before-x-icon");
|
|
384
386
|
}
|
|
385
|
-
function
|
|
387
|
+
function An() {
|
|
386
388
|
var r;
|
|
387
389
|
const e = document.querySelector(p(a.MAIN_MENU));
|
|
388
390
|
e != null && e.classList.contains(a.MOBILE__HIDDEN) && ((r = document.querySelector(`${p(a.UTAH_DESIGN_SYSTEM)}${p(a.MOBILE_MENU)}`)) == null || r.classList.add(a.MAIN_MENU__REMOVED));
|
|
389
|
-
const { hamburger: t, hamburgerIcon: n, mobileMenu: o } =
|
|
390
|
-
t.setAttribute("aria-expanded", "true"), o.classList.add(a.IS_OPEN), n.classList.remove("utds-icon-before-hamburger"), n.classList.add("utds-icon-before-x-icon");
|
|
391
|
+
const { hamburger: t, hamburgerIcon: n, mobileMenu: o } = we("showMobileMenu");
|
|
392
|
+
t.setAttribute("aria-expanded", "true"), o.classList.add(a.IS_OPEN), t.setAttribute("aria-label", "Close the mobile menu"), n.classList.remove("utds-icon-before-hamburger"), n.classList.add("utds-icon-before-x-icon");
|
|
391
393
|
}
|
|
392
|
-
function
|
|
394
|
+
function Ze(e, t) {
|
|
393
395
|
e.querySelectorAll(p(a.MOBILE_MENU_ACTION_BAR__ACTION_ITEM_WRAPPER)).forEach((o) => {
|
|
394
396
|
o.classList.remove(a.ACTION_ITEM__SELECTED);
|
|
395
397
|
const r = o.querySelector("button");
|
|
@@ -402,10 +404,10 @@ function je(e, t) {
|
|
|
402
404
|
throw new Error("showActionItem: actionWrapper does not have actionItem B");
|
|
403
405
|
n.setAttribute("aria-selected", "true"), n.removeAttribute("tabIndex"), n.focus();
|
|
404
406
|
}
|
|
405
|
-
function
|
|
407
|
+
function Lt(e, t) {
|
|
406
408
|
e.querySelectorAll(p(a.MOBILE_MENU__CONTENT_ITEM)).forEach((n) => n.classList.remove(a.IS_OPEN)), t.classList.add(a.IS_OPEN);
|
|
407
409
|
}
|
|
408
|
-
function
|
|
410
|
+
function ot(e, t, n, {
|
|
409
411
|
ariaHasPopupType: o,
|
|
410
412
|
additionalOnClick: r,
|
|
411
413
|
onClickHandler: i,
|
|
@@ -438,10 +440,10 @@ function nt(e, t, n, {
|
|
|
438
440
|
if (t) {
|
|
439
441
|
const E = K(t);
|
|
440
442
|
if (E) {
|
|
441
|
-
const
|
|
442
|
-
if (!
|
|
443
|
+
const b = E.getAttribute("id");
|
|
444
|
+
if (!b)
|
|
443
445
|
throw new Error("mobileMenuInteractionHandler: mobileMenuContentId not found");
|
|
444
|
-
(m || e).setAttribute("aria-controls",
|
|
446
|
+
(m || e).setAttribute("aria-controls", b), E.setAttribute("aria-labelledby", f);
|
|
445
447
|
}
|
|
446
448
|
}
|
|
447
449
|
if (e.onclick)
|
|
@@ -449,40 +451,40 @@ function nt(e, t, n, {
|
|
|
449
451
|
if (e.onclick = (E) => {
|
|
450
452
|
if (!(i != null && i(E)))
|
|
451
453
|
if (r == null || r(E), s.classList.contains(a.IS_OPEN))
|
|
452
|
-
u &&
|
|
454
|
+
u && qe();
|
|
453
455
|
else {
|
|
454
|
-
|
|
455
|
-
const
|
|
456
|
-
|
|
456
|
+
An();
|
|
457
|
+
const g = K(t);
|
|
458
|
+
g && Lt(c, g), Ze(l, K(n));
|
|
457
459
|
}
|
|
458
460
|
}, t) {
|
|
459
461
|
if (d !== e && d.onclick)
|
|
460
462
|
throw new Error("mobileMenuInteractionHandler: actionItemWrapperValue already has onclick");
|
|
461
463
|
d.onclick = (E) => {
|
|
462
464
|
if (!(i != null && i(E))) {
|
|
463
|
-
const
|
|
464
|
-
|
|
465
|
+
const b = K(t);
|
|
466
|
+
b && Lt(c, b), Ze(l, K(n));
|
|
465
467
|
}
|
|
466
468
|
};
|
|
467
469
|
}
|
|
468
470
|
}
|
|
469
|
-
const
|
|
471
|
+
const wn = `<div class="utds-header-mobile-menu__action-item" role="tab">
|
|
470
472
|
<button type="button" class="icon-button icon-button--borderless utds-header-action-item__icon-button">
|
|
471
473
|
<div class="utds-header-action-item__title visually-hidden"></div>
|
|
472
474
|
<span aria-hidden="true" role="presentation">
|
|
473
475
|
</button>
|
|
474
476
|
<span class="menu-chiclet"></span>
|
|
475
477
|
</div>
|
|
476
|
-
`,
|
|
478
|
+
`, On = `<div class="utds-header-action-item-menu">
|
|
477
479
|
<div class="vertical-menu__wrapper-title"></div>
|
|
478
480
|
</div>
|
|
479
|
-
`,
|
|
480
|
-
`,
|
|
481
|
+
`, Ln = `<span class="utds-icon-before-chevron-right vertical-menu__chevron" aria-hidden="true"></span>
|
|
482
|
+
`, Gt = `<span class="utds-new-tab-link-a11y">
|
|
481
483
|
<span class="visually-hidden">opens in a new tab</span>
|
|
482
484
|
<span class="utds-icon-after-external-link" aria-hidden="true"></span>
|
|
483
485
|
</span>
|
|
484
|
-
`,
|
|
485
|
-
`,
|
|
486
|
+
`, yn = `<ul class="vertical-menu" role="menu" />
|
|
487
|
+
`, Pn = `<li class="vertical-menu__item">
|
|
486
488
|
<span class="vertical-menu__title">
|
|
487
489
|
<span class="vertical-menu__plain-title"></span>
|
|
488
490
|
<a href="#" class="vertical-menu__link-title">
|
|
@@ -494,7 +496,7 @@ const gn = `<div class="utds-header-mobile-menu__action-item" role="tab">
|
|
|
494
496
|
</span>
|
|
495
497
|
<span class="vertical-menu__divider" />
|
|
496
498
|
</li>
|
|
497
|
-
`,
|
|
499
|
+
`, rt = {
|
|
498
500
|
AUTO: (
|
|
499
501
|
/** @type {PopupPlacement} */
|
|
500
502
|
"auto"
|
|
@@ -556,20 +558,20 @@ const gn = `<div class="utds-header-mobile-menu__action-item" role="tab">
|
|
|
556
558
|
"top-end"
|
|
557
559
|
)
|
|
558
560
|
};
|
|
559
|
-
function
|
|
561
|
+
function ke(e, t, n) {
|
|
560
562
|
var r;
|
|
561
563
|
let o = !1;
|
|
562
|
-
return e && (Array.isArray(e) ? o = e.some((i) =>
|
|
564
|
+
return e && (Array.isArray(e) ? o = e.some((i) => ke(i, t, n)) : (o = n(e), o || (o = !!((r = t == null ? void 0 : t.filter((i) => e[i])) != null && r.some((i) => ke(e[i], t, n)))))), o;
|
|
563
565
|
}
|
|
564
|
-
var
|
|
566
|
+
var H = "top", V = "bottom", $ = "right", x = "left", it = "auto", Ne = [H, V, $, x], de = "start", Oe = "end", Nn = "clippingParents", zt = "viewport", ve = "popper", Sn = "reference", yt = /* @__PURE__ */ Ne.reduce(function(e, t) {
|
|
565
567
|
return e.concat([t + "-" + de, t + "-" + Oe]);
|
|
566
|
-
}, []),
|
|
568
|
+
}, []), Yt = /* @__PURE__ */ [].concat(Ne, [it]).reduce(function(e, t) {
|
|
567
569
|
return e.concat([t, t + "-" + de, t + "-" + Oe]);
|
|
568
|
-
}, []),
|
|
570
|
+
}, []), Un = "beforeRead", Cn = "read", Rn = "afterRead", Dn = "beforeMain", Bn = "main", Hn = "afterMain", xn = "beforeWrite", Wn = "write", kn = "afterWrite", Fn = [Un, Cn, Rn, Dn, Bn, Hn, xn, Wn, kn];
|
|
569
571
|
function Z(e) {
|
|
570
572
|
return e ? (e.nodeName || "").toLowerCase() : null;
|
|
571
573
|
}
|
|
572
|
-
function
|
|
574
|
+
function F(e) {
|
|
573
575
|
if (e == null)
|
|
574
576
|
return window;
|
|
575
577
|
if (e.toString() !== "[object Window]") {
|
|
@@ -579,30 +581,30 @@ function k(e) {
|
|
|
579
581
|
return e;
|
|
580
582
|
}
|
|
581
583
|
function le(e) {
|
|
582
|
-
var t =
|
|
584
|
+
var t = F(e).Element;
|
|
583
585
|
return e instanceof t || e instanceof Element;
|
|
584
586
|
}
|
|
585
|
-
function
|
|
586
|
-
var t =
|
|
587
|
+
function q(e) {
|
|
588
|
+
var t = F(e).HTMLElement;
|
|
587
589
|
return e instanceof t || e instanceof HTMLElement;
|
|
588
590
|
}
|
|
589
|
-
function
|
|
591
|
+
function at(e) {
|
|
590
592
|
if (typeof ShadowRoot > "u")
|
|
591
593
|
return !1;
|
|
592
|
-
var t =
|
|
594
|
+
var t = F(e).ShadowRoot;
|
|
593
595
|
return e instanceof t || e instanceof ShadowRoot;
|
|
594
596
|
}
|
|
595
|
-
function
|
|
597
|
+
function qn(e) {
|
|
596
598
|
var t = e.state;
|
|
597
599
|
Object.keys(t.elements).forEach(function(n) {
|
|
598
600
|
var o = t.styles[n] || {}, r = t.attributes[n] || {}, i = t.elements[n];
|
|
599
|
-
!
|
|
601
|
+
!q(i) || !Z(i) || (Object.assign(i.style, o), Object.keys(r).forEach(function(u) {
|
|
600
602
|
var s = r[u];
|
|
601
603
|
s === !1 ? i.removeAttribute(u) : i.setAttribute(u, s === !0 ? "" : s);
|
|
602
604
|
}));
|
|
603
605
|
});
|
|
604
606
|
}
|
|
605
|
-
function
|
|
607
|
+
function Vn(e) {
|
|
606
608
|
var t = e.state, n = {
|
|
607
609
|
popper: {
|
|
608
610
|
position: t.options.strategy,
|
|
@@ -620,38 +622,38 @@ function kn(e) {
|
|
|
620
622
|
var r = t.elements[o], i = t.attributes[o] || {}, u = Object.keys(t.styles.hasOwnProperty(o) ? t.styles[o] : n[o]), s = u.reduce(function(l, c) {
|
|
621
623
|
return l[c] = "", l;
|
|
622
624
|
}, {});
|
|
623
|
-
!
|
|
625
|
+
!q(r) || !Z(r) || (Object.assign(r.style, s), Object.keys(i).forEach(function(l) {
|
|
624
626
|
r.removeAttribute(l);
|
|
625
627
|
}));
|
|
626
628
|
});
|
|
627
629
|
};
|
|
628
630
|
}
|
|
629
|
-
const
|
|
631
|
+
const $n = {
|
|
630
632
|
name: "applyStyles",
|
|
631
633
|
enabled: !0,
|
|
632
634
|
phase: "write",
|
|
633
|
-
fn:
|
|
634
|
-
effect:
|
|
635
|
+
fn: qn,
|
|
636
|
+
effect: Vn,
|
|
635
637
|
requires: ["computeStyles"]
|
|
636
638
|
};
|
|
637
639
|
function j(e) {
|
|
638
640
|
return e.split("-")[0];
|
|
639
641
|
}
|
|
640
|
-
var se = Math.max,
|
|
641
|
-
function
|
|
642
|
+
var se = Math.max, Fe = Math.min, pe = Math.round;
|
|
643
|
+
function Xe() {
|
|
642
644
|
var e = navigator.userAgentData;
|
|
643
645
|
return e != null && e.brands && Array.isArray(e.brands) ? e.brands.map(function(t) {
|
|
644
646
|
return t.brand + "/" + t.version;
|
|
645
647
|
}).join(" ") : navigator.userAgent;
|
|
646
648
|
}
|
|
647
|
-
function
|
|
648
|
-
return !/^((?!chrome|android).)*safari/i.test(
|
|
649
|
+
function Kt() {
|
|
650
|
+
return !/^((?!chrome|android).)*safari/i.test(Xe());
|
|
649
651
|
}
|
|
650
652
|
function fe(e, t, n) {
|
|
651
653
|
t === void 0 && (t = !1), n === void 0 && (n = !1);
|
|
652
654
|
var o = e.getBoundingClientRect(), r = 1, i = 1;
|
|
653
|
-
t &&
|
|
654
|
-
var u = le(e) ?
|
|
655
|
+
t && q(e) && (r = e.offsetWidth > 0 && pe(o.width) / e.offsetWidth || 1, i = e.offsetHeight > 0 && pe(o.height) / e.offsetHeight || 1);
|
|
656
|
+
var u = le(e) ? F(e) : window, s = u.visualViewport, l = !Kt() && n, c = (o.left + (l && s ? s.offsetLeft : 0)) / r, d = (o.top + (l && s ? s.offsetTop : 0)) / i, m = o.width / r, f = o.height / i;
|
|
655
657
|
return {
|
|
656
658
|
width: m,
|
|
657
659
|
height: f,
|
|
@@ -663,7 +665,7 @@ function fe(e, t, n) {
|
|
|
663
665
|
y: d
|
|
664
666
|
};
|
|
665
667
|
}
|
|
666
|
-
function
|
|
668
|
+
function st(e) {
|
|
667
669
|
var t = fe(e), n = e.offsetWidth, o = e.offsetHeight;
|
|
668
670
|
return Math.abs(t.width - n) <= 1 && (n = t.width), Math.abs(t.height - o) <= 1 && (o = t.height), {
|
|
669
671
|
x: e.offsetLeft,
|
|
@@ -672,11 +674,11 @@ function at(e) {
|
|
|
672
674
|
height: o
|
|
673
675
|
};
|
|
674
676
|
}
|
|
675
|
-
function
|
|
677
|
+
function jt(e, t) {
|
|
676
678
|
var n = t.getRootNode && t.getRootNode();
|
|
677
679
|
if (e.contains(t))
|
|
678
680
|
return !0;
|
|
679
|
-
if (n &&
|
|
681
|
+
if (n && at(n)) {
|
|
680
682
|
var o = t;
|
|
681
683
|
do {
|
|
682
684
|
if (o && e.isSameNode(o))
|
|
@@ -687,9 +689,9 @@ function zt(e, t) {
|
|
|
687
689
|
return !1;
|
|
688
690
|
}
|
|
689
691
|
function J(e) {
|
|
690
|
-
return
|
|
692
|
+
return F(e).getComputedStyle(e);
|
|
691
693
|
}
|
|
692
|
-
function
|
|
694
|
+
function Gn(e) {
|
|
693
695
|
return ["table", "td", "th"].indexOf(Z(e)) >= 0;
|
|
694
696
|
}
|
|
695
697
|
function ee(e) {
|
|
@@ -698,31 +700,31 @@ function ee(e) {
|
|
|
698
700
|
e.document
|
|
699
701
|
)) || window.document).documentElement;
|
|
700
702
|
}
|
|
701
|
-
function
|
|
703
|
+
function Ve(e) {
|
|
702
704
|
return Z(e) === "html" ? e : (
|
|
703
705
|
// this is a quicker (but less type safe) way to save quite some bytes from the bundle
|
|
704
706
|
// $FlowFixMe[incompatible-return]
|
|
705
707
|
// $FlowFixMe[prop-missing]
|
|
706
708
|
e.assignedSlot || // step into the shadow DOM of the parent of a slotted node
|
|
707
709
|
e.parentNode || // DOM Element detected
|
|
708
|
-
(
|
|
710
|
+
(at(e) ? e.host : null) || // ShadowRoot detected
|
|
709
711
|
// $FlowFixMe[incompatible-call]: HTMLElement is a Node
|
|
710
712
|
ee(e)
|
|
711
713
|
);
|
|
712
714
|
}
|
|
713
|
-
function
|
|
714
|
-
return !
|
|
715
|
+
function Pt(e) {
|
|
716
|
+
return !q(e) || // https://github.com/popperjs/popper-core/issues/837
|
|
715
717
|
J(e).position === "fixed" ? null : e.offsetParent;
|
|
716
718
|
}
|
|
717
|
-
function
|
|
718
|
-
var t = /firefox/i.test(
|
|
719
|
-
if (n &&
|
|
719
|
+
function zn(e) {
|
|
720
|
+
var t = /firefox/i.test(Xe()), n = /Trident/i.test(Xe());
|
|
721
|
+
if (n && q(e)) {
|
|
720
722
|
var o = J(e);
|
|
721
723
|
if (o.position === "fixed")
|
|
722
724
|
return null;
|
|
723
725
|
}
|
|
724
|
-
var r =
|
|
725
|
-
for (
|
|
726
|
+
var r = Ve(e);
|
|
727
|
+
for (at(r) && (r = r.host); q(r) && ["html", "body"].indexOf(Z(r)) < 0; ) {
|
|
726
728
|
var i = J(r);
|
|
727
729
|
if (i.transform !== "none" || i.perspective !== "none" || i.contain === "paint" || ["transform", "perspective"].indexOf(i.willChange) !== -1 || t && i.willChange === "filter" || t && i.filter && i.filter !== "none")
|
|
728
730
|
return r;
|
|
@@ -730,22 +732,22 @@ function Vn(e) {
|
|
|
730
732
|
}
|
|
731
733
|
return null;
|
|
732
734
|
}
|
|
733
|
-
function
|
|
734
|
-
for (var t =
|
|
735
|
-
n =
|
|
736
|
-
return n && (Z(n) === "html" || Z(n) === "body" && J(n).position === "static") ? t : n ||
|
|
735
|
+
function Se(e) {
|
|
736
|
+
for (var t = F(e), n = Pt(e); n && Gn(n) && J(n).position === "static"; )
|
|
737
|
+
n = Pt(n);
|
|
738
|
+
return n && (Z(n) === "html" || Z(n) === "body" && J(n).position === "static") ? t : n || zn(e) || t;
|
|
737
739
|
}
|
|
738
|
-
function
|
|
740
|
+
function lt(e) {
|
|
739
741
|
return ["top", "bottom"].indexOf(e) >= 0 ? "x" : "y";
|
|
740
742
|
}
|
|
741
|
-
function
|
|
742
|
-
return se(e,
|
|
743
|
+
function ge(e, t, n) {
|
|
744
|
+
return se(e, Fe(t, n));
|
|
743
745
|
}
|
|
744
|
-
function
|
|
745
|
-
var o =
|
|
746
|
+
function Yn(e, t, n) {
|
|
747
|
+
var o = ge(e, t, n);
|
|
746
748
|
return o > n ? n : o;
|
|
747
749
|
}
|
|
748
|
-
function
|
|
750
|
+
function Zt() {
|
|
749
751
|
return {
|
|
750
752
|
top: 0,
|
|
751
753
|
right: 0,
|
|
@@ -753,100 +755,100 @@ function Yt() {
|
|
|
753
755
|
left: 0
|
|
754
756
|
};
|
|
755
757
|
}
|
|
756
|
-
function
|
|
757
|
-
return Object.assign({},
|
|
758
|
+
function Xt(e) {
|
|
759
|
+
return Object.assign({}, Zt(), e);
|
|
758
760
|
}
|
|
759
|
-
function
|
|
761
|
+
function Jt(e, t) {
|
|
760
762
|
return t.reduce(function(n, o) {
|
|
761
763
|
return n[o] = e, n;
|
|
762
764
|
}, {});
|
|
763
765
|
}
|
|
764
|
-
var
|
|
766
|
+
var Kn = function(t, n) {
|
|
765
767
|
return t = typeof t == "function" ? t(Object.assign({}, n.rects, {
|
|
766
768
|
placement: n.placement
|
|
767
|
-
})) : t,
|
|
769
|
+
})) : t, Xt(typeof t != "number" ? t : Jt(t, Ne));
|
|
768
770
|
};
|
|
769
|
-
function
|
|
770
|
-
var t, n = e.state, o = e.name, r = e.options, i = n.elements.arrow, u = n.modifiersData.popperOffsets, s = j(n.placement), l =
|
|
771
|
+
function jn(e) {
|
|
772
|
+
var t, n = e.state, o = e.name, r = e.options, i = n.elements.arrow, u = n.modifiersData.popperOffsets, s = j(n.placement), l = lt(s), c = [x, $].indexOf(s) >= 0, d = c ? "height" : "width";
|
|
771
773
|
if (!(!i || !u)) {
|
|
772
|
-
var m =
|
|
773
|
-
n.modifiersData[o] = (t = {}, t[C] = P, t.centerOffset = P -
|
|
774
|
+
var m = Kn(r.padding, n), f = st(i), h = l === "y" ? H : x, _ = l === "y" ? V : $, E = n.rects.reference[d] + n.rects.reference[l] - u[l] - n.rects.popper[d], b = u[l] - n.rects.reference[l], g = Se(i), M = g ? l === "y" ? g.clientHeight || 0 : g.clientWidth || 0 : 0, w = E / 2 - b / 2, v = m[h], T = M - f[d] - m[_], A = M / 2 - f[d] / 2 + w, P = ge(v, A, T), C = l;
|
|
775
|
+
n.modifiersData[o] = (t = {}, t[C] = P, t.centerOffset = P - A, t);
|
|
774
776
|
}
|
|
775
777
|
}
|
|
776
|
-
function
|
|
778
|
+
function Zn(e) {
|
|
777
779
|
var t = e.state, n = e.options, o = n.element, r = o === void 0 ? "[data-popper-arrow]" : o;
|
|
778
|
-
r != null && (typeof r == "string" && (r = t.elements.popper.querySelector(r), !r) ||
|
|
780
|
+
r != null && (typeof r == "string" && (r = t.elements.popper.querySelector(r), !r) || jt(t.elements.popper, r) && (t.elements.arrow = r));
|
|
779
781
|
}
|
|
780
|
-
const
|
|
782
|
+
const Xn = {
|
|
781
783
|
name: "arrow",
|
|
782
784
|
enabled: !0,
|
|
783
785
|
phase: "main",
|
|
784
|
-
fn:
|
|
785
|
-
effect:
|
|
786
|
+
fn: jn,
|
|
787
|
+
effect: Zn,
|
|
786
788
|
requires: ["popperOffsets"],
|
|
787
789
|
requiresIfExists: ["preventOverflow"]
|
|
788
790
|
};
|
|
789
791
|
function _e(e) {
|
|
790
792
|
return e.split("-")[1];
|
|
791
793
|
}
|
|
792
|
-
var
|
|
794
|
+
var Jn = {
|
|
793
795
|
top: "auto",
|
|
794
796
|
right: "auto",
|
|
795
797
|
bottom: "auto",
|
|
796
798
|
left: "auto"
|
|
797
799
|
};
|
|
798
|
-
function
|
|
800
|
+
function Qn(e, t) {
|
|
799
801
|
var n = e.x, o = e.y, r = t.devicePixelRatio || 1;
|
|
800
802
|
return {
|
|
801
803
|
x: pe(n * r) / r || 0,
|
|
802
804
|
y: pe(o * r) / r || 0
|
|
803
805
|
};
|
|
804
806
|
}
|
|
805
|
-
function
|
|
806
|
-
var t, n = e.popper, o = e.popperRect, r = e.placement, i = e.variation, u = e.offsets, s = e.position, l = e.gpuAcceleration, c = e.adaptive, d = e.roundOffsets, m = e.isFixed, f = u.x, h = f === void 0 ? 0 : f, _ = u.y, E = _ === void 0 ? 0 : _,
|
|
807
|
+
function Nt(e) {
|
|
808
|
+
var t, n = e.popper, o = e.popperRect, r = e.placement, i = e.variation, u = e.offsets, s = e.position, l = e.gpuAcceleration, c = e.adaptive, d = e.roundOffsets, m = e.isFixed, f = u.x, h = f === void 0 ? 0 : f, _ = u.y, E = _ === void 0 ? 0 : _, b = typeof d == "function" ? d({
|
|
807
809
|
x: h,
|
|
808
810
|
y: E
|
|
809
811
|
}) : {
|
|
810
812
|
x: h,
|
|
811
813
|
y: E
|
|
812
814
|
};
|
|
813
|
-
h =
|
|
814
|
-
var
|
|
815
|
+
h = b.x, E = b.y;
|
|
816
|
+
var g = u.hasOwnProperty("x"), M = u.hasOwnProperty("y"), w = x, v = H, T = window;
|
|
815
817
|
if (c) {
|
|
816
|
-
var
|
|
817
|
-
if (
|
|
818
|
-
|
|
819
|
-
var S = m &&
|
|
818
|
+
var A = Se(n), P = "clientHeight", C = "clientWidth";
|
|
819
|
+
if (A === F(n) && (A = ee(n), J(A).position !== "static" && s === "absolute" && (P = "scrollHeight", C = "scrollWidth")), A = A, r === H || (r === x || r === $) && i === Oe) {
|
|
820
|
+
v = V;
|
|
821
|
+
var S = m && A === T && T.visualViewport ? T.visualViewport.height : (
|
|
820
822
|
// $FlowFixMe[prop-missing]
|
|
821
|
-
|
|
823
|
+
A[P]
|
|
822
824
|
);
|
|
823
825
|
E -= S - o.height, E *= l ? 1 : -1;
|
|
824
826
|
}
|
|
825
|
-
if (r ===
|
|
826
|
-
|
|
827
|
-
var N = m &&
|
|
827
|
+
if (r === x || (r === H || r === V) && i === Oe) {
|
|
828
|
+
w = $;
|
|
829
|
+
var N = m && A === T && T.visualViewport ? T.visualViewport.width : (
|
|
828
830
|
// $FlowFixMe[prop-missing]
|
|
829
|
-
|
|
831
|
+
A[C]
|
|
830
832
|
);
|
|
831
833
|
h -= N - o.width, h *= l ? 1 : -1;
|
|
832
834
|
}
|
|
833
835
|
}
|
|
834
836
|
var R = Object.assign({
|
|
835
837
|
position: s
|
|
836
|
-
}, c &&
|
|
838
|
+
}, c && Jn), G = d === !0 ? Qn({
|
|
837
839
|
x: h,
|
|
838
840
|
y: E
|
|
839
|
-
},
|
|
841
|
+
}, F(n)) : {
|
|
840
842
|
x: h,
|
|
841
843
|
y: E
|
|
842
844
|
};
|
|
843
845
|
if (h = G.x, E = G.y, l) {
|
|
844
846
|
var D;
|
|
845
|
-
return Object.assign({}, R, (D = {}, D[
|
|
847
|
+
return Object.assign({}, R, (D = {}, D[v] = M ? "0" : "", D[w] = g ? "0" : "", D.transform = (T.devicePixelRatio || 1) <= 1 ? "translate(" + h + "px, " + E + "px)" : "translate3d(" + h + "px, " + E + "px, 0)", D));
|
|
846
848
|
}
|
|
847
|
-
return Object.assign({}, R, (t = {}, t[
|
|
849
|
+
return Object.assign({}, R, (t = {}, t[v] = M ? E + "px" : "", t[w] = g ? h + "px" : "", t.transform = "", t));
|
|
848
850
|
}
|
|
849
|
-
function
|
|
851
|
+
function eo(e) {
|
|
850
852
|
var t = e.state, n = e.options, o = n.gpuAcceleration, r = o === void 0 ? !0 : o, i = n.adaptive, u = i === void 0 ? !0 : i, s = n.roundOffsets, l = s === void 0 ? !0 : s, c = {
|
|
851
853
|
placement: j(t.placement),
|
|
852
854
|
variation: _e(t.placement),
|
|
@@ -855,12 +857,12 @@ function Xn(e) {
|
|
|
855
857
|
gpuAcceleration: r,
|
|
856
858
|
isFixed: t.options.strategy === "fixed"
|
|
857
859
|
};
|
|
858
|
-
t.modifiersData.popperOffsets != null && (t.styles.popper = Object.assign({}, t.styles.popper,
|
|
860
|
+
t.modifiersData.popperOffsets != null && (t.styles.popper = Object.assign({}, t.styles.popper, Nt(Object.assign({}, c, {
|
|
859
861
|
offsets: t.modifiersData.popperOffsets,
|
|
860
862
|
position: t.options.strategy,
|
|
861
863
|
adaptive: u,
|
|
862
864
|
roundOffsets: l
|
|
863
|
-
})))), t.modifiersData.arrow != null && (t.styles.arrow = Object.assign({}, t.styles.arrow,
|
|
865
|
+
})))), t.modifiersData.arrow != null && (t.styles.arrow = Object.assign({}, t.styles.arrow, Nt(Object.assign({}, c, {
|
|
864
866
|
offsets: t.modifiersData.arrow,
|
|
865
867
|
position: "absolute",
|
|
866
868
|
adaptive: !1,
|
|
@@ -869,81 +871,81 @@ function Xn(e) {
|
|
|
869
871
|
"data-popper-placement": t.placement
|
|
870
872
|
});
|
|
871
873
|
}
|
|
872
|
-
const
|
|
874
|
+
const to = {
|
|
873
875
|
name: "computeStyles",
|
|
874
876
|
enabled: !0,
|
|
875
877
|
phase: "beforeWrite",
|
|
876
|
-
fn:
|
|
878
|
+
fn: eo,
|
|
877
879
|
data: {}
|
|
878
880
|
};
|
|
879
|
-
var
|
|
881
|
+
var He = {
|
|
880
882
|
passive: !0
|
|
881
883
|
};
|
|
882
|
-
function
|
|
883
|
-
var t = e.state, n = e.instance, o = e.options, r = o.scroll, i = r === void 0 ? !0 : r, u = o.resize, s = u === void 0 ? !0 : u, l =
|
|
884
|
+
function no(e) {
|
|
885
|
+
var t = e.state, n = e.instance, o = e.options, r = o.scroll, i = r === void 0 ? !0 : r, u = o.resize, s = u === void 0 ? !0 : u, l = F(t.elements.popper), c = [].concat(t.scrollParents.reference, t.scrollParents.popper);
|
|
884
886
|
return i && c.forEach(function(d) {
|
|
885
|
-
d.addEventListener("scroll", n.update,
|
|
886
|
-
}), s && l.addEventListener("resize", n.update,
|
|
887
|
+
d.addEventListener("scroll", n.update, He);
|
|
888
|
+
}), s && l.addEventListener("resize", n.update, He), function() {
|
|
887
889
|
i && c.forEach(function(d) {
|
|
888
|
-
d.removeEventListener("scroll", n.update,
|
|
889
|
-
}), s && l.removeEventListener("resize", n.update,
|
|
890
|
+
d.removeEventListener("scroll", n.update, He);
|
|
891
|
+
}), s && l.removeEventListener("resize", n.update, He);
|
|
890
892
|
};
|
|
891
893
|
}
|
|
892
|
-
const
|
|
894
|
+
const oo = {
|
|
893
895
|
name: "eventListeners",
|
|
894
896
|
enabled: !0,
|
|
895
897
|
phase: "write",
|
|
896
898
|
fn: function() {
|
|
897
899
|
},
|
|
898
|
-
effect:
|
|
900
|
+
effect: no,
|
|
899
901
|
data: {}
|
|
900
902
|
};
|
|
901
|
-
var
|
|
903
|
+
var ro = {
|
|
902
904
|
left: "right",
|
|
903
905
|
right: "left",
|
|
904
906
|
bottom: "top",
|
|
905
907
|
top: "bottom"
|
|
906
908
|
};
|
|
907
|
-
function
|
|
909
|
+
function We(e) {
|
|
908
910
|
return e.replace(/left|right|bottom|top/g, function(t) {
|
|
909
|
-
return
|
|
911
|
+
return ro[t];
|
|
910
912
|
});
|
|
911
913
|
}
|
|
912
|
-
var
|
|
914
|
+
var io = {
|
|
913
915
|
start: "end",
|
|
914
916
|
end: "start"
|
|
915
917
|
};
|
|
916
|
-
function
|
|
918
|
+
function St(e) {
|
|
917
919
|
return e.replace(/start|end/g, function(t) {
|
|
918
|
-
return
|
|
920
|
+
return io[t];
|
|
919
921
|
});
|
|
920
922
|
}
|
|
921
|
-
function
|
|
922
|
-
var t =
|
|
923
|
+
function ct(e) {
|
|
924
|
+
var t = F(e), n = t.pageXOffset, o = t.pageYOffset;
|
|
923
925
|
return {
|
|
924
926
|
scrollLeft: n,
|
|
925
927
|
scrollTop: o
|
|
926
928
|
};
|
|
927
929
|
}
|
|
928
|
-
function
|
|
929
|
-
return fe(ee(e)).left +
|
|
930
|
+
function ut(e) {
|
|
931
|
+
return fe(ee(e)).left + ct(e).scrollLeft;
|
|
930
932
|
}
|
|
931
|
-
function
|
|
932
|
-
var n =
|
|
933
|
+
function ao(e, t) {
|
|
934
|
+
var n = F(e), o = ee(e), r = n.visualViewport, i = o.clientWidth, u = o.clientHeight, s = 0, l = 0;
|
|
933
935
|
if (r) {
|
|
934
936
|
i = r.width, u = r.height;
|
|
935
|
-
var c =
|
|
937
|
+
var c = Kt();
|
|
936
938
|
(c || !c && t === "fixed") && (s = r.offsetLeft, l = r.offsetTop);
|
|
937
939
|
}
|
|
938
940
|
return {
|
|
939
941
|
width: i,
|
|
940
942
|
height: u,
|
|
941
|
-
x: s +
|
|
943
|
+
x: s + ut(e),
|
|
942
944
|
y: l
|
|
943
945
|
};
|
|
944
946
|
}
|
|
945
|
-
function
|
|
946
|
-
var t, n = ee(e), o =
|
|
947
|
+
function so(e) {
|
|
948
|
+
var t, n = ee(e), o = ct(e), r = (t = e.ownerDocument) == null ? void 0 : t.body, i = se(n.scrollWidth, n.clientWidth, r ? r.scrollWidth : 0, r ? r.clientWidth : 0), u = se(n.scrollHeight, n.clientHeight, r ? r.scrollHeight : 0, r ? r.clientHeight : 0), s = -o.scrollLeft + ut(e), l = -o.scrollTop;
|
|
947
949
|
return J(r || n).direction === "rtl" && (s += se(n.clientWidth, r ? r.clientWidth : 0) - i), {
|
|
948
950
|
width: i,
|
|
949
951
|
height: u,
|
|
@@ -951,23 +953,23 @@ function ro(e) {
|
|
|
951
953
|
y: l
|
|
952
954
|
};
|
|
953
955
|
}
|
|
954
|
-
function
|
|
956
|
+
function dt(e) {
|
|
955
957
|
var t = J(e), n = t.overflow, o = t.overflowX, r = t.overflowY;
|
|
956
958
|
return /auto|scroll|overlay|hidden/.test(n + r + o);
|
|
957
959
|
}
|
|
958
|
-
function
|
|
959
|
-
return ["html", "body", "#document"].indexOf(Z(e)) >= 0 ? e.ownerDocument.body :
|
|
960
|
+
function Qt(e) {
|
|
961
|
+
return ["html", "body", "#document"].indexOf(Z(e)) >= 0 ? e.ownerDocument.body : q(e) && dt(e) ? e : Qt(Ve(e));
|
|
960
962
|
}
|
|
961
|
-
function
|
|
963
|
+
function Me(e, t) {
|
|
962
964
|
var n;
|
|
963
965
|
t === void 0 && (t = []);
|
|
964
|
-
var o =
|
|
966
|
+
var o = Qt(e), r = o === ((n = e.ownerDocument) == null ? void 0 : n.body), i = F(o), u = r ? [i].concat(i.visualViewport || [], dt(o) ? o : []) : o, s = t.concat(u);
|
|
965
967
|
return r ? s : (
|
|
966
968
|
// $FlowFixMe[incompatible-call]: isBody tells us target will be an HTMLElement here
|
|
967
|
-
s.concat(
|
|
969
|
+
s.concat(Me(Ve(u)))
|
|
968
970
|
);
|
|
969
971
|
}
|
|
970
|
-
function
|
|
972
|
+
function Je(e) {
|
|
971
973
|
return Object.assign({}, e, {
|
|
972
974
|
left: e.x,
|
|
973
975
|
top: e.y,
|
|
@@ -975,48 +977,48 @@ function Xe(e) {
|
|
|
975
977
|
bottom: e.y + e.height
|
|
976
978
|
});
|
|
977
979
|
}
|
|
978
|
-
function
|
|
980
|
+
function lo(e, t) {
|
|
979
981
|
var n = fe(e, !1, t === "fixed");
|
|
980
982
|
return n.top = n.top + e.clientTop, n.left = n.left + e.clientLeft, n.bottom = n.top + e.clientHeight, n.right = n.left + e.clientWidth, n.width = e.clientWidth, n.height = e.clientHeight, n.x = n.left, n.y = n.top, n;
|
|
981
983
|
}
|
|
982
|
-
function
|
|
983
|
-
return t ===
|
|
984
|
+
function Ut(e, t, n) {
|
|
985
|
+
return t === zt ? Je(ao(e, n)) : le(t) ? lo(t, n) : Je(so(ee(e)));
|
|
984
986
|
}
|
|
985
|
-
function
|
|
986
|
-
var t =
|
|
987
|
+
function co(e) {
|
|
988
|
+
var t = Me(Ve(e)), n = ["absolute", "fixed"].indexOf(J(e).position) >= 0, o = n && q(e) ? Se(e) : e;
|
|
987
989
|
return le(o) ? t.filter(function(r) {
|
|
988
|
-
return le(r) &&
|
|
990
|
+
return le(r) && jt(r, o) && Z(r) !== "body";
|
|
989
991
|
}) : [];
|
|
990
992
|
}
|
|
991
|
-
function
|
|
992
|
-
var r = t === "clippingParents" ?
|
|
993
|
-
var d =
|
|
994
|
-
return l.top = se(d.top, l.top), l.right =
|
|
995
|
-
},
|
|
993
|
+
function uo(e, t, n, o) {
|
|
994
|
+
var r = t === "clippingParents" ? co(e) : [].concat(t), i = [].concat(r, [n]), u = i[0], s = i.reduce(function(l, c) {
|
|
995
|
+
var d = Ut(e, c, o);
|
|
996
|
+
return l.top = se(d.top, l.top), l.right = Fe(d.right, l.right), l.bottom = Fe(d.bottom, l.bottom), l.left = se(d.left, l.left), l;
|
|
997
|
+
}, Ut(e, u, o));
|
|
996
998
|
return s.width = s.right - s.left, s.height = s.bottom - s.top, s.x = s.left, s.y = s.top, s;
|
|
997
999
|
}
|
|
998
|
-
function
|
|
1000
|
+
function en(e) {
|
|
999
1001
|
var t = e.reference, n = e.element, o = e.placement, r = o ? j(o) : null, i = o ? _e(o) : null, u = t.x + t.width / 2 - n.width / 2, s = t.y + t.height / 2 - n.height / 2, l;
|
|
1000
1002
|
switch (r) {
|
|
1001
|
-
case
|
|
1003
|
+
case H:
|
|
1002
1004
|
l = {
|
|
1003
1005
|
x: u,
|
|
1004
1006
|
y: t.y - n.height
|
|
1005
1007
|
};
|
|
1006
1008
|
break;
|
|
1007
|
-
case
|
|
1009
|
+
case V:
|
|
1008
1010
|
l = {
|
|
1009
1011
|
x: u,
|
|
1010
1012
|
y: t.y + t.height
|
|
1011
1013
|
};
|
|
1012
1014
|
break;
|
|
1013
|
-
case
|
|
1015
|
+
case $:
|
|
1014
1016
|
l = {
|
|
1015
1017
|
x: t.x + t.width,
|
|
1016
1018
|
y: s
|
|
1017
1019
|
};
|
|
1018
1020
|
break;
|
|
1019
|
-
case
|
|
1021
|
+
case x:
|
|
1020
1022
|
l = {
|
|
1021
1023
|
x: t.x - n.width,
|
|
1022
1024
|
y: s
|
|
@@ -1028,7 +1030,7 @@ function Xt(e) {
|
|
|
1028
1030
|
y: t.y
|
|
1029
1031
|
};
|
|
1030
1032
|
}
|
|
1031
|
-
var c = r ?
|
|
1033
|
+
var c = r ? lt(r) : null;
|
|
1032
1034
|
if (c != null) {
|
|
1033
1035
|
var d = c === "y" ? "height" : "width";
|
|
1034
1036
|
switch (i) {
|
|
@@ -1042,38 +1044,38 @@ function Xt(e) {
|
|
|
1042
1044
|
}
|
|
1043
1045
|
return l;
|
|
1044
1046
|
}
|
|
1045
|
-
function
|
|
1047
|
+
function Le(e, t) {
|
|
1046
1048
|
t === void 0 && (t = {});
|
|
1047
|
-
var n = t, o = n.placement, r = o === void 0 ? e.placement : o, i = n.strategy, u = i === void 0 ? e.strategy : i, s = n.boundary, l = s === void 0 ?
|
|
1048
|
-
reference:
|
|
1049
|
-
element:
|
|
1049
|
+
var n = t, o = n.placement, r = o === void 0 ? e.placement : o, i = n.strategy, u = i === void 0 ? e.strategy : i, s = n.boundary, l = s === void 0 ? Nn : s, c = n.rootBoundary, d = c === void 0 ? zt : c, m = n.elementContext, f = m === void 0 ? ve : m, h = n.altBoundary, _ = h === void 0 ? !1 : h, E = n.padding, b = E === void 0 ? 0 : E, g = Xt(typeof b != "number" ? b : Jt(b, Ne)), M = f === ve ? Sn : ve, w = e.rects.popper, v = e.elements[_ ? M : f], T = uo(le(v) ? v : v.contextElement || ee(e.elements.popper), l, d, u), A = fe(e.elements.reference), P = en({
|
|
1050
|
+
reference: A,
|
|
1051
|
+
element: w,
|
|
1050
1052
|
strategy: "absolute",
|
|
1051
1053
|
placement: r
|
|
1052
|
-
}), C =
|
|
1053
|
-
top:
|
|
1054
|
-
bottom: S.bottom -
|
|
1055
|
-
left:
|
|
1056
|
-
right: S.right -
|
|
1054
|
+
}), C = Je(Object.assign({}, w, P)), S = f === ve ? C : A, N = {
|
|
1055
|
+
top: T.top - S.top + g.top,
|
|
1056
|
+
bottom: S.bottom - T.bottom + g.bottom,
|
|
1057
|
+
left: T.left - S.left + g.left,
|
|
1058
|
+
right: S.right - T.right + g.right
|
|
1057
1059
|
}, R = e.modifiersData.offset;
|
|
1058
1060
|
if (f === ve && R) {
|
|
1059
1061
|
var G = R[r];
|
|
1060
1062
|
Object.keys(N).forEach(function(D) {
|
|
1061
|
-
var te = [V
|
|
1063
|
+
var te = [$, V].indexOf(D) >= 0 ? 1 : -1, ne = [H, V].indexOf(D) >= 0 ? "y" : "x";
|
|
1062
1064
|
N[D] += G[ne] * te;
|
|
1063
1065
|
});
|
|
1064
1066
|
}
|
|
1065
1067
|
return N;
|
|
1066
1068
|
}
|
|
1067
|
-
function
|
|
1069
|
+
function po(e, t) {
|
|
1068
1070
|
t === void 0 && (t = {});
|
|
1069
|
-
var n = t, o = n.placement, r = n.boundary, i = n.rootBoundary, u = n.padding, s = n.flipVariations, l = n.allowedAutoPlacements, c = l === void 0 ?
|
|
1071
|
+
var n = t, o = n.placement, r = n.boundary, i = n.rootBoundary, u = n.padding, s = n.flipVariations, l = n.allowedAutoPlacements, c = l === void 0 ? Yt : l, d = _e(o), m = d ? s ? yt : yt.filter(function(_) {
|
|
1070
1072
|
return _e(_) === d;
|
|
1071
|
-
}) :
|
|
1073
|
+
}) : Ne, f = m.filter(function(_) {
|
|
1072
1074
|
return c.indexOf(_) >= 0;
|
|
1073
1075
|
});
|
|
1074
1076
|
f.length === 0 && (f = m);
|
|
1075
1077
|
var h = f.reduce(function(_, E) {
|
|
1076
|
-
return _[E] =
|
|
1078
|
+
return _[E] = Le(e, {
|
|
1077
1079
|
placement: E,
|
|
1078
1080
|
boundary: r,
|
|
1079
1081
|
rootBoundary: i,
|
|
@@ -1084,17 +1086,17 @@ function lo(e, t) {
|
|
|
1084
1086
|
return h[_] - h[E];
|
|
1085
1087
|
});
|
|
1086
1088
|
}
|
|
1087
|
-
function
|
|
1088
|
-
if (j(e) ===
|
|
1089
|
+
function fo(e) {
|
|
1090
|
+
if (j(e) === it)
|
|
1089
1091
|
return [];
|
|
1090
|
-
var t =
|
|
1091
|
-
return [
|
|
1092
|
+
var t = We(e);
|
|
1093
|
+
return [St(e), t, St(t)];
|
|
1092
1094
|
}
|
|
1093
|
-
function
|
|
1095
|
+
function _o(e) {
|
|
1094
1096
|
var t = e.state, n = e.options, o = e.name;
|
|
1095
1097
|
if (!t.modifiersData[o]._skip) {
|
|
1096
|
-
for (var r = n.mainAxis, i = r === void 0 ? !0 : r, u = n.altAxis, s = u === void 0 ? !0 : u, l = n.fallbackPlacements, c = n.padding, d = n.boundary, m = n.rootBoundary, f = n.altBoundary, h = n.flipVariations, _ = h === void 0 ? !0 : h, E = n.allowedAutoPlacements,
|
|
1097
|
-
return ce.concat(j(Q) ===
|
|
1098
|
+
for (var r = n.mainAxis, i = r === void 0 ? !0 : r, u = n.altAxis, s = u === void 0 ? !0 : u, l = n.fallbackPlacements, c = n.padding, d = n.boundary, m = n.rootBoundary, f = n.altBoundary, h = n.flipVariations, _ = h === void 0 ? !0 : h, E = n.allowedAutoPlacements, b = t.options.placement, g = j(b), M = g === b, w = l || (M || !_ ? [We(b)] : fo(b)), v = [b].concat(w).reduce(function(ce, Q) {
|
|
1099
|
+
return ce.concat(j(Q) === it ? po(t, {
|
|
1098
1100
|
placement: Q,
|
|
1099
1101
|
boundary: d,
|
|
1100
1102
|
rootBoundary: m,
|
|
@@ -1102,17 +1104,17 @@ function uo(e) {
|
|
|
1102
1104
|
flipVariations: _,
|
|
1103
1105
|
allowedAutoPlacements: E
|
|
1104
1106
|
}) : Q);
|
|
1105
|
-
}, []),
|
|
1106
|
-
var R =
|
|
1107
|
+
}, []), T = t.rects.reference, A = t.rects.popper, P = /* @__PURE__ */ new Map(), C = !0, S = v[0], N = 0; N < v.length; N++) {
|
|
1108
|
+
var R = v[N], G = j(R), D = _e(R) === de, te = [H, V].indexOf(G) >= 0, ne = te ? "width" : "height", W = Le(t, {
|
|
1107
1109
|
placement: R,
|
|
1108
1110
|
boundary: d,
|
|
1109
1111
|
rootBoundary: m,
|
|
1110
1112
|
altBoundary: f,
|
|
1111
1113
|
padding: c
|
|
1112
|
-
}),
|
|
1113
|
-
|
|
1114
|
-
var
|
|
1115
|
-
if (i && oe.push(
|
|
1114
|
+
}), z = te ? D ? $ : x : D ? V : H;
|
|
1115
|
+
T[ne] > A[ne] && (z = We(z));
|
|
1116
|
+
var Ue = We(z), oe = [];
|
|
1117
|
+
if (i && oe.push(W[G] <= 0), s && oe.push(W[z] <= 0, W[Ue] <= 0), oe.every(function(ce) {
|
|
1116
1118
|
return ce;
|
|
1117
1119
|
})) {
|
|
1118
1120
|
S = R, C = !1;
|
|
@@ -1121,9 +1123,9 @@ function uo(e) {
|
|
|
1121
1123
|
P.set(R, oe);
|
|
1122
1124
|
}
|
|
1123
1125
|
if (C)
|
|
1124
|
-
for (var
|
|
1125
|
-
var Ee =
|
|
1126
|
-
var re = P.get(
|
|
1126
|
+
for (var Ce = _ ? 3 : 1, $e = function(Q) {
|
|
1127
|
+
var Ee = v.find(function(De) {
|
|
1128
|
+
var re = P.get(De);
|
|
1127
1129
|
if (re)
|
|
1128
1130
|
return re.slice(0, Q).every(function(Ge) {
|
|
1129
1131
|
return Ge;
|
|
@@ -1131,25 +1133,25 @@ function uo(e) {
|
|
|
1131
1133
|
});
|
|
1132
1134
|
if (Ee)
|
|
1133
1135
|
return S = Ee, "break";
|
|
1134
|
-
}, me =
|
|
1135
|
-
var
|
|
1136
|
-
if (
|
|
1136
|
+
}, me = Ce; me > 0; me--) {
|
|
1137
|
+
var Re = $e(me);
|
|
1138
|
+
if (Re === "break")
|
|
1137
1139
|
break;
|
|
1138
1140
|
}
|
|
1139
1141
|
t.placement !== S && (t.modifiersData[o]._skip = !0, t.placement = S, t.reset = !0);
|
|
1140
1142
|
}
|
|
1141
1143
|
}
|
|
1142
|
-
const
|
|
1144
|
+
const ho = {
|
|
1143
1145
|
name: "flip",
|
|
1144
1146
|
enabled: !0,
|
|
1145
1147
|
phase: "main",
|
|
1146
|
-
fn:
|
|
1148
|
+
fn: _o,
|
|
1147
1149
|
requiresIfExists: ["offset"],
|
|
1148
1150
|
data: {
|
|
1149
1151
|
_skip: !1
|
|
1150
1152
|
}
|
|
1151
1153
|
};
|
|
1152
|
-
function
|
|
1154
|
+
function Ct(e, t, n) {
|
|
1153
1155
|
return n === void 0 && (n = {
|
|
1154
1156
|
x: 0,
|
|
1155
1157
|
y: 0
|
|
@@ -1160,17 +1162,17 @@ function Ut(e, t, n) {
|
|
|
1160
1162
|
left: e.left - t.width - n.x
|
|
1161
1163
|
};
|
|
1162
1164
|
}
|
|
1163
|
-
function
|
|
1164
|
-
return [
|
|
1165
|
+
function Rt(e) {
|
|
1166
|
+
return [H, $, V, x].some(function(t) {
|
|
1165
1167
|
return e[t] >= 0;
|
|
1166
1168
|
});
|
|
1167
1169
|
}
|
|
1168
|
-
function
|
|
1169
|
-
var t = e.state, n = e.name, o = t.rects.reference, r = t.rects.popper, i = t.modifiersData.preventOverflow, u =
|
|
1170
|
+
function mo(e) {
|
|
1171
|
+
var t = e.state, n = e.name, o = t.rects.reference, r = t.rects.popper, i = t.modifiersData.preventOverflow, u = Le(t, {
|
|
1170
1172
|
elementContext: "reference"
|
|
1171
|
-
}), s =
|
|
1173
|
+
}), s = Le(t, {
|
|
1172
1174
|
altBoundary: !0
|
|
1173
|
-
}), l =
|
|
1175
|
+
}), l = Ct(u, o), c = Ct(s, r, i), d = Rt(l), m = Rt(c);
|
|
1174
1176
|
t.modifiersData[n] = {
|
|
1175
1177
|
referenceClippingOffsets: l,
|
|
1176
1178
|
popperEscapeOffsets: c,
|
|
@@ -1181,18 +1183,18 @@ function fo(e) {
|
|
|
1181
1183
|
"data-popper-escaped": m
|
|
1182
1184
|
});
|
|
1183
1185
|
}
|
|
1184
|
-
const
|
|
1186
|
+
const Eo = {
|
|
1185
1187
|
name: "hide",
|
|
1186
1188
|
enabled: !0,
|
|
1187
1189
|
phase: "main",
|
|
1188
1190
|
requiresIfExists: ["preventOverflow"],
|
|
1189
|
-
fn:
|
|
1191
|
+
fn: mo
|
|
1190
1192
|
};
|
|
1191
|
-
function
|
|
1192
|
-
var o = j(e), r = [
|
|
1193
|
+
function vo(e, t, n) {
|
|
1194
|
+
var o = j(e), r = [x, H].indexOf(o) >= 0 ? -1 : 1, i = typeof n == "function" ? n(Object.assign({}, t, {
|
|
1193
1195
|
placement: e
|
|
1194
1196
|
})) : n, u = i[0], s = i[1];
|
|
1195
|
-
return u = u || 0, s = (s || 0) * r, [
|
|
1197
|
+
return u = u || 0, s = (s || 0) * r, [x, $].indexOf(o) >= 0 ? {
|
|
1196
1198
|
x: s,
|
|
1197
1199
|
y: u
|
|
1198
1200
|
} : {
|
|
@@ -1200,45 +1202,45 @@ function ho(e, t, n) {
|
|
|
1200
1202
|
y: s
|
|
1201
1203
|
};
|
|
1202
1204
|
}
|
|
1203
|
-
function
|
|
1204
|
-
var t = e.state, n = e.options, o = e.name, r = n.offset, i = r === void 0 ? [0, 0] : r, u =
|
|
1205
|
-
return d[m] =
|
|
1205
|
+
function bo(e) {
|
|
1206
|
+
var t = e.state, n = e.options, o = e.name, r = n.offset, i = r === void 0 ? [0, 0] : r, u = Yt.reduce(function(d, m) {
|
|
1207
|
+
return d[m] = vo(m, t.rects, i), d;
|
|
1206
1208
|
}, {}), s = u[t.placement], l = s.x, c = s.y;
|
|
1207
1209
|
t.modifiersData.popperOffsets != null && (t.modifiersData.popperOffsets.x += l, t.modifiersData.popperOffsets.y += c), t.modifiersData[o] = u;
|
|
1208
1210
|
}
|
|
1209
|
-
const
|
|
1211
|
+
const Io = {
|
|
1210
1212
|
name: "offset",
|
|
1211
1213
|
enabled: !0,
|
|
1212
1214
|
phase: "main",
|
|
1213
1215
|
requires: ["popperOffsets"],
|
|
1214
|
-
fn:
|
|
1216
|
+
fn: bo
|
|
1215
1217
|
};
|
|
1216
|
-
function
|
|
1218
|
+
function To(e) {
|
|
1217
1219
|
var t = e.state, n = e.name;
|
|
1218
|
-
t.modifiersData[n] =
|
|
1220
|
+
t.modifiersData[n] = en({
|
|
1219
1221
|
reference: t.rects.reference,
|
|
1220
1222
|
element: t.rects.popper,
|
|
1221
1223
|
strategy: "absolute",
|
|
1222
1224
|
placement: t.placement
|
|
1223
1225
|
});
|
|
1224
1226
|
}
|
|
1225
|
-
const
|
|
1227
|
+
const go = {
|
|
1226
1228
|
name: "popperOffsets",
|
|
1227
1229
|
enabled: !0,
|
|
1228
1230
|
phase: "read",
|
|
1229
|
-
fn:
|
|
1231
|
+
fn: To,
|
|
1230
1232
|
data: {}
|
|
1231
1233
|
};
|
|
1232
|
-
function
|
|
1234
|
+
function Mo(e) {
|
|
1233
1235
|
return e === "x" ? "y" : "x";
|
|
1234
1236
|
}
|
|
1235
|
-
function
|
|
1236
|
-
var t = e.state, n = e.options, o = e.name, r = n.mainAxis, i = r === void 0 ? !0 : r, u = n.altAxis, s = u === void 0 ? !1 : u, l = n.boundary, c = n.rootBoundary, d = n.altBoundary, m = n.padding, f = n.tether, h = f === void 0 ? !0 : f, _ = n.tetherOffset, E = _ === void 0 ? 0 : _,
|
|
1237
|
+
function Ao(e) {
|
|
1238
|
+
var t = e.state, n = e.options, o = e.name, r = n.mainAxis, i = r === void 0 ? !0 : r, u = n.altAxis, s = u === void 0 ? !1 : u, l = n.boundary, c = n.rootBoundary, d = n.altBoundary, m = n.padding, f = n.tether, h = f === void 0 ? !0 : f, _ = n.tetherOffset, E = _ === void 0 ? 0 : _, b = Le(t, {
|
|
1237
1239
|
boundary: l,
|
|
1238
1240
|
rootBoundary: c,
|
|
1239
1241
|
padding: m,
|
|
1240
1242
|
altBoundary: d
|
|
1241
|
-
}),
|
|
1243
|
+
}), g = j(t.placement), M = _e(t.placement), w = !M, v = lt(g), T = Mo(v), A = t.modifiersData.popperOffsets, P = t.rects.reference, C = t.rects.popper, S = typeof E == "function" ? E(Object.assign({}, t.rects, {
|
|
1242
1244
|
placement: t.placement
|
|
1243
1245
|
})) : E, N = typeof S == "number" ? {
|
|
1244
1246
|
mainAxis: S,
|
|
@@ -1250,44 +1252,44 @@ function To(e) {
|
|
|
1250
1252
|
x: 0,
|
|
1251
1253
|
y: 0
|
|
1252
1254
|
};
|
|
1253
|
-
if (
|
|
1255
|
+
if (A) {
|
|
1254
1256
|
if (i) {
|
|
1255
|
-
var D, te =
|
|
1257
|
+
var D, te = v === "y" ? H : x, ne = v === "y" ? V : $, W = v === "y" ? "height" : "width", z = A[v], Ue = z + b[te], oe = z - b[ne], Ce = h ? -C[W] / 2 : 0, $e = M === de ? P[W] : C[W], me = M === de ? -C[W] : -P[W], Re = t.elements.arrow, ce = h && Re ? st(Re) : {
|
|
1256
1258
|
width: 0,
|
|
1257
1259
|
height: 0
|
|
1258
|
-
}, Q = t.modifiersData["arrow#persistent"] ? t.modifiersData["arrow#persistent"].padding :
|
|
1259
|
-
|
|
1260
|
+
}, Q = t.modifiersData["arrow#persistent"] ? t.modifiersData["arrow#persistent"].padding : Zt(), Ee = Q[te], De = Q[ne], re = ge(0, P[W], ce[W]), Ge = w ? P[W] / 2 - Ce - re - Ee - N.mainAxis : $e - re - Ee - N.mainAxis, pn = w ? -P[W] / 2 + Ce + re + De + N.mainAxis : me + re + De + N.mainAxis, ze = t.elements.arrow && Se(t.elements.arrow), fn = ze ? v === "y" ? ze.clientTop || 0 : ze.clientLeft || 0 : 0, mt = (D = R == null ? void 0 : R[v]) != null ? D : 0, _n = z + Ge - mt - fn, hn = z + pn - mt, Et = ge(h ? Fe(Ue, _n) : Ue, z, h ? se(oe, hn) : oe);
|
|
1261
|
+
A[v] = Et, G[v] = Et - z;
|
|
1260
1262
|
}
|
|
1261
1263
|
if (s) {
|
|
1262
|
-
var
|
|
1263
|
-
|
|
1264
|
+
var vt, mn = v === "x" ? H : x, En = v === "x" ? V : $, ie = A[T], Be = T === "y" ? "height" : "width", bt = ie + b[mn], It = ie - b[En], Ye = [H, x].indexOf(g) !== -1, Tt = (vt = R == null ? void 0 : R[T]) != null ? vt : 0, gt = Ye ? bt : ie - P[Be] - C[Be] - Tt + N.altAxis, Mt = Ye ? ie + P[Be] + C[Be] - Tt - N.altAxis : It, At = h && Ye ? Yn(gt, ie, Mt) : ge(h ? gt : bt, ie, h ? Mt : It);
|
|
1265
|
+
A[T] = At, G[T] = At - ie;
|
|
1264
1266
|
}
|
|
1265
1267
|
t.modifiersData[o] = G;
|
|
1266
1268
|
}
|
|
1267
1269
|
}
|
|
1268
|
-
const
|
|
1270
|
+
const wo = {
|
|
1269
1271
|
name: "preventOverflow",
|
|
1270
1272
|
enabled: !0,
|
|
1271
1273
|
phase: "main",
|
|
1272
|
-
fn:
|
|
1274
|
+
fn: Ao,
|
|
1273
1275
|
requiresIfExists: ["offset"]
|
|
1274
1276
|
};
|
|
1275
|
-
function
|
|
1277
|
+
function Oo(e) {
|
|
1276
1278
|
return {
|
|
1277
1279
|
scrollLeft: e.scrollLeft,
|
|
1278
1280
|
scrollTop: e.scrollTop
|
|
1279
1281
|
};
|
|
1280
1282
|
}
|
|
1281
|
-
function
|
|
1282
|
-
return e ===
|
|
1283
|
+
function Lo(e) {
|
|
1284
|
+
return e === F(e) || !q(e) ? ct(e) : Oo(e);
|
|
1283
1285
|
}
|
|
1284
|
-
function
|
|
1286
|
+
function yo(e) {
|
|
1285
1287
|
var t = e.getBoundingClientRect(), n = pe(t.width) / e.offsetWidth || 1, o = pe(t.height) / e.offsetHeight || 1;
|
|
1286
1288
|
return n !== 1 || o !== 1;
|
|
1287
1289
|
}
|
|
1288
|
-
function
|
|
1290
|
+
function Po(e, t, n) {
|
|
1289
1291
|
n === void 0 && (n = !1);
|
|
1290
|
-
var o =
|
|
1292
|
+
var o = q(t), r = q(t) && yo(t), i = ee(t), u = fe(e, r, n), s = {
|
|
1291
1293
|
scrollLeft: 0,
|
|
1292
1294
|
scrollTop: 0
|
|
1293
1295
|
}, l = {
|
|
@@ -1295,14 +1297,14 @@ function wo(e, t, n) {
|
|
|
1295
1297
|
y: 0
|
|
1296
1298
|
};
|
|
1297
1299
|
return (o || !o && !n) && ((Z(t) !== "body" || // https://github.com/popperjs/popper-core/issues/1078
|
|
1298
|
-
|
|
1300
|
+
dt(i)) && (s = Lo(t)), q(t) ? (l = fe(t, !0), l.x += t.clientLeft, l.y += t.clientTop) : i && (l.x = ut(i))), {
|
|
1299
1301
|
x: u.left + s.scrollLeft - l.x,
|
|
1300
1302
|
y: u.top + s.scrollTop - l.y,
|
|
1301
1303
|
width: u.width,
|
|
1302
1304
|
height: u.height
|
|
1303
1305
|
};
|
|
1304
1306
|
}
|
|
1305
|
-
function
|
|
1307
|
+
function No(e) {
|
|
1306
1308
|
var t = /* @__PURE__ */ new Map(), n = /* @__PURE__ */ new Set(), o = [];
|
|
1307
1309
|
e.forEach(function(i) {
|
|
1308
1310
|
t.set(i.name, i);
|
|
@@ -1321,15 +1323,15 @@ function Lo(e) {
|
|
|
1321
1323
|
n.has(i.name) || r(i);
|
|
1322
1324
|
}), o;
|
|
1323
1325
|
}
|
|
1324
|
-
function
|
|
1325
|
-
var t =
|
|
1326
|
-
return
|
|
1326
|
+
function So(e) {
|
|
1327
|
+
var t = No(e);
|
|
1328
|
+
return Fn.reduce(function(n, o) {
|
|
1327
1329
|
return n.concat(t.filter(function(r) {
|
|
1328
1330
|
return r.phase === o;
|
|
1329
1331
|
}));
|
|
1330
1332
|
}, []);
|
|
1331
1333
|
}
|
|
1332
|
-
function
|
|
1334
|
+
function Uo(e) {
|
|
1333
1335
|
var t;
|
|
1334
1336
|
return function() {
|
|
1335
1337
|
return t || (t = new Promise(function(n) {
|
|
@@ -1339,7 +1341,7 @@ function Po(e) {
|
|
|
1339
1341
|
})), t;
|
|
1340
1342
|
};
|
|
1341
1343
|
}
|
|
1342
|
-
function
|
|
1344
|
+
function Co(e) {
|
|
1343
1345
|
var t = e.reduce(function(n, o) {
|
|
1344
1346
|
var r = n[o.name];
|
|
1345
1347
|
return n[o.name] = r ? Object.assign({}, r, o, {
|
|
@@ -1351,27 +1353,27 @@ function No(e) {
|
|
|
1351
1353
|
return t[n];
|
|
1352
1354
|
});
|
|
1353
1355
|
}
|
|
1354
|
-
var
|
|
1356
|
+
var Dt = {
|
|
1355
1357
|
placement: "bottom",
|
|
1356
1358
|
modifiers: [],
|
|
1357
1359
|
strategy: "absolute"
|
|
1358
1360
|
};
|
|
1359
|
-
function
|
|
1361
|
+
function Bt() {
|
|
1360
1362
|
for (var e = arguments.length, t = new Array(e), n = 0; n < e; n++)
|
|
1361
1363
|
t[n] = arguments[n];
|
|
1362
1364
|
return !t.some(function(o) {
|
|
1363
1365
|
return !(o && typeof o.getBoundingClientRect == "function");
|
|
1364
1366
|
});
|
|
1365
1367
|
}
|
|
1366
|
-
function
|
|
1368
|
+
function Ro(e) {
|
|
1367
1369
|
e === void 0 && (e = {});
|
|
1368
|
-
var t = e, n = t.defaultModifiers, o = n === void 0 ? [] : n, r = t.defaultOptions, i = r === void 0 ?
|
|
1370
|
+
var t = e, n = t.defaultModifiers, o = n === void 0 ? [] : n, r = t.defaultOptions, i = r === void 0 ? Dt : r;
|
|
1369
1371
|
return function(s, l, c) {
|
|
1370
1372
|
c === void 0 && (c = i);
|
|
1371
1373
|
var d = {
|
|
1372
1374
|
placement: "bottom",
|
|
1373
1375
|
orderedModifiers: [],
|
|
1374
|
-
options: Object.assign({},
|
|
1376
|
+
options: Object.assign({}, Dt, i),
|
|
1375
1377
|
modifiersData: {},
|
|
1376
1378
|
elements: {
|
|
1377
1379
|
reference: s,
|
|
@@ -1381,15 +1383,15 @@ function So(e) {
|
|
|
1381
1383
|
styles: {}
|
|
1382
1384
|
}, m = [], f = !1, h = {
|
|
1383
1385
|
state: d,
|
|
1384
|
-
setOptions: function(
|
|
1385
|
-
var
|
|
1386
|
-
E(), d.options = Object.assign({}, i, d.options,
|
|
1387
|
-
reference: le(s) ?
|
|
1388
|
-
popper:
|
|
1386
|
+
setOptions: function(g) {
|
|
1387
|
+
var M = typeof g == "function" ? g(d.options) : g;
|
|
1388
|
+
E(), d.options = Object.assign({}, i, d.options, M), d.scrollParents = {
|
|
1389
|
+
reference: le(s) ? Me(s) : s.contextElement ? Me(s.contextElement) : [],
|
|
1390
|
+
popper: Me(l)
|
|
1389
1391
|
};
|
|
1390
|
-
var
|
|
1391
|
-
return d.orderedModifiers =
|
|
1392
|
-
return
|
|
1392
|
+
var w = So(Co([].concat(o, d.options.modifiers)));
|
|
1393
|
+
return d.orderedModifiers = w.filter(function(v) {
|
|
1394
|
+
return v.enabled;
|
|
1393
1395
|
}), _(), h.update();
|
|
1394
1396
|
},
|
|
1395
1397
|
// Sync update – it will always be executed, even if not necessary. This
|
|
@@ -1399,21 +1401,21 @@ function So(e) {
|
|
|
1399
1401
|
// prefer the async Popper#update method
|
|
1400
1402
|
forceUpdate: function() {
|
|
1401
1403
|
if (!f) {
|
|
1402
|
-
var
|
|
1403
|
-
if (
|
|
1404
|
+
var g = d.elements, M = g.reference, w = g.popper;
|
|
1405
|
+
if (Bt(M, w)) {
|
|
1404
1406
|
d.rects = {
|
|
1405
|
-
reference:
|
|
1406
|
-
popper:
|
|
1407
|
+
reference: Po(M, Se(w), d.options.strategy === "fixed"),
|
|
1408
|
+
popper: st(w)
|
|
1407
1409
|
}, d.reset = !1, d.placement = d.options.placement, d.orderedModifiers.forEach(function(N) {
|
|
1408
1410
|
return d.modifiersData[N.name] = Object.assign({}, N.data);
|
|
1409
1411
|
});
|
|
1410
|
-
for (var
|
|
1412
|
+
for (var v = 0; v < d.orderedModifiers.length; v++) {
|
|
1411
1413
|
if (d.reset === !0) {
|
|
1412
|
-
d.reset = !1,
|
|
1414
|
+
d.reset = !1, v = -1;
|
|
1413
1415
|
continue;
|
|
1414
1416
|
}
|
|
1415
|
-
var
|
|
1416
|
-
typeof
|
|
1417
|
+
var T = d.orderedModifiers[v], A = T.fn, P = T.options, C = P === void 0 ? {} : P, S = T.name;
|
|
1418
|
+
typeof A == "function" && (d = A({
|
|
1417
1419
|
state: d,
|
|
1418
1420
|
options: C,
|
|
1419
1421
|
name: S,
|
|
@@ -1425,57 +1427,57 @@ function So(e) {
|
|
|
1425
1427
|
},
|
|
1426
1428
|
// Async and optimistically optimized update – it will not be executed if
|
|
1427
1429
|
// not necessary (debounced to run at most once-per-tick)
|
|
1428
|
-
update:
|
|
1429
|
-
return new Promise(function(
|
|
1430
|
-
h.forceUpdate(),
|
|
1430
|
+
update: Uo(function() {
|
|
1431
|
+
return new Promise(function(b) {
|
|
1432
|
+
h.forceUpdate(), b(d);
|
|
1431
1433
|
});
|
|
1432
1434
|
}),
|
|
1433
1435
|
destroy: function() {
|
|
1434
1436
|
E(), f = !0;
|
|
1435
1437
|
}
|
|
1436
1438
|
};
|
|
1437
|
-
if (!
|
|
1439
|
+
if (!Bt(s, l))
|
|
1438
1440
|
return h;
|
|
1439
|
-
h.setOptions(c).then(function(
|
|
1440
|
-
!f && c.onFirstUpdate && c.onFirstUpdate(
|
|
1441
|
+
h.setOptions(c).then(function(b) {
|
|
1442
|
+
!f && c.onFirstUpdate && c.onFirstUpdate(b);
|
|
1441
1443
|
});
|
|
1442
1444
|
function _() {
|
|
1443
|
-
d.orderedModifiers.forEach(function(
|
|
1444
|
-
var
|
|
1445
|
-
if (typeof
|
|
1446
|
-
var
|
|
1445
|
+
d.orderedModifiers.forEach(function(b) {
|
|
1446
|
+
var g = b.name, M = b.options, w = M === void 0 ? {} : M, v = b.effect;
|
|
1447
|
+
if (typeof v == "function") {
|
|
1448
|
+
var T = v({
|
|
1447
1449
|
state: d,
|
|
1448
|
-
name:
|
|
1450
|
+
name: g,
|
|
1449
1451
|
instance: h,
|
|
1450
|
-
options:
|
|
1451
|
-
}),
|
|
1452
|
+
options: w
|
|
1453
|
+
}), A = function() {
|
|
1452
1454
|
};
|
|
1453
|
-
m.push(
|
|
1455
|
+
m.push(T || A);
|
|
1454
1456
|
}
|
|
1455
1457
|
});
|
|
1456
1458
|
}
|
|
1457
1459
|
function E() {
|
|
1458
|
-
m.forEach(function(
|
|
1459
|
-
return
|
|
1460
|
+
m.forEach(function(b) {
|
|
1461
|
+
return b();
|
|
1460
1462
|
}), m = [];
|
|
1461
1463
|
}
|
|
1462
1464
|
return h;
|
|
1463
1465
|
};
|
|
1464
1466
|
}
|
|
1465
|
-
var
|
|
1466
|
-
defaultModifiers:
|
|
1467
|
+
var Do = [oo, go, to, $n, Io, ho, wo, Xn, Eo], tn = /* @__PURE__ */ Ro({
|
|
1468
|
+
defaultModifiers: Do
|
|
1467
1469
|
});
|
|
1468
|
-
function
|
|
1470
|
+
function Qe(e, t, n, o) {
|
|
1469
1471
|
t ? (e.classList.remove(o), e.classList.add(n)) : (e.classList.add(o), e.classList.remove(n));
|
|
1470
1472
|
}
|
|
1471
|
-
let
|
|
1472
|
-
const be = {},
|
|
1473
|
+
let k;
|
|
1474
|
+
const be = {}, et = {
|
|
1473
1475
|
SHIFT: "shift-key"
|
|
1474
1476
|
};
|
|
1475
|
-
function
|
|
1476
|
-
|
|
1477
|
+
function nn() {
|
|
1478
|
+
k && (document.removeEventListener("click", k.globalOnClick), document.removeEventListener("keyup", k.globalOnKeyup), document.removeEventListener("keydown", k.globalOnKeydown), k = null);
|
|
1477
1479
|
}
|
|
1478
|
-
function
|
|
1480
|
+
function tt() {
|
|
1479
1481
|
const e = document.querySelectorAll(
|
|
1480
1482
|
`${p(a.UTAH_DESIGN_SYSTEM)} ${p(a.POPUP_WRAPPER)}`
|
|
1481
1483
|
);
|
|
@@ -1485,35 +1487,35 @@ function et() {
|
|
|
1485
1487
|
const o = document.querySelector(`[aria-controls="${n}"]`);
|
|
1486
1488
|
o && o.setAttribute("aria-expanded", "false");
|
|
1487
1489
|
}
|
|
1488
|
-
|
|
1490
|
+
Qe(t, !1, a.POPUP__VISIBLE, a.POPUP__HIDDEN);
|
|
1489
1491
|
});
|
|
1490
1492
|
}
|
|
1491
|
-
function
|
|
1492
|
-
|
|
1493
|
-
e.key === "Escape" &&
|
|
1494
|
-
}, document.addEventListener("keyup",
|
|
1495
|
-
e.shiftKey && (be[
|
|
1496
|
-
}, document.addEventListener("keydown",
|
|
1493
|
+
function Bo() {
|
|
1494
|
+
k && nn(), k = {}, k.globalOnClick = tt, document.addEventListener("click", k.globalOnClick), k.globalOnKeyup = (e) => {
|
|
1495
|
+
e.key === "Escape" && tt(), e.shiftKey || (be[et.SHIFT] = !1), be[e.key] = !1;
|
|
1496
|
+
}, document.addEventListener("keyup", k.globalOnKeyup), k.globalOnKeydown = (e) => {
|
|
1497
|
+
e.shiftKey && (be[et.SHIFT] = !0), be[e.key] = !0;
|
|
1498
|
+
}, document.addEventListener("keydown", k.globalOnKeydown);
|
|
1497
1499
|
}
|
|
1498
|
-
function
|
|
1500
|
+
function Ho() {
|
|
1499
1501
|
return "ontouchstart" in window || navigator.maxTouchPoints > 0 || navigator.msMaxTouchPoints > 0;
|
|
1500
1502
|
}
|
|
1501
|
-
function
|
|
1503
|
+
function ye(e, t, n, o, r) {
|
|
1502
1504
|
let i = NaN, u = NaN;
|
|
1503
1505
|
const s = 300, l = 150, c = 50;
|
|
1504
1506
|
t.setAttribute("aria-expanded", "false"), t.setAttribute("aria-haspopup", o);
|
|
1505
1507
|
function d(f) {
|
|
1506
1508
|
clearTimeout(i), clearTimeout(u), (!(r != null && r.isPerformPopup) || r != null && r.isPerformPopup && r.isPerformPopup()) && (i = window.setTimeout(
|
|
1507
1509
|
() => {
|
|
1508
|
-
|
|
1509
|
-
placement: (r == null ? void 0 : r.popupPlacement) ||
|
|
1510
|
+
tn(t, n, {
|
|
1511
|
+
placement: (r == null ? void 0 : r.popupPlacement) || rt.BOTTOM,
|
|
1510
1512
|
modifiers: [
|
|
1511
1513
|
{
|
|
1512
1514
|
name: "offset",
|
|
1513
1515
|
options: { offset: [0, 11] }
|
|
1514
1516
|
}
|
|
1515
1517
|
]
|
|
1516
|
-
}),
|
|
1518
|
+
}), Qe(n, !0, a.POPUP__VISIBLE, a.POPUP__HIDDEN), t.setAttribute("aria-expanded", "true"), document.querySelectorAll(p(a.TOOLTIP__WRAPPER)).forEach((h) => h.classList.add(a.TOOLTIP__WRAPPER__HIDDEN));
|
|
1517
1519
|
},
|
|
1518
1520
|
f
|
|
1519
1521
|
));
|
|
@@ -1521,7 +1523,7 @@ function Le(e, t, n, o, r) {
|
|
|
1521
1523
|
function m(f) {
|
|
1522
1524
|
clearTimeout(i), clearTimeout(u), (!(r != null && r.isPerformPopup) || r.isPerformPopup()) && (u = window.setTimeout(
|
|
1523
1525
|
() => {
|
|
1524
|
-
|
|
1526
|
+
Qe(n, !1, a.POPUP__VISIBLE, a.POPUP__HIDDEN), t.setAttribute("aria-expanded", "false");
|
|
1525
1527
|
},
|
|
1526
1528
|
f
|
|
1527
1529
|
));
|
|
@@ -1534,23 +1536,23 @@ function Le(e, t, n, o, r) {
|
|
|
1534
1536
|
t.onclick = (f) => {
|
|
1535
1537
|
var _;
|
|
1536
1538
|
const h = t.getAttribute("aria-expanded") === "true";
|
|
1537
|
-
(!(r != null && r.isPerformPopup) || r.isPerformPopup()) && (f.stopPropagation(), f.preventDefault(), h && t.getAttribute("aria-expanded") === "true" ? (m(c), (_ = document.activeElement) == null || _.blur()) : (
|
|
1539
|
+
(!(r != null && r.isPerformPopup) || r.isPerformPopup()) && (f.stopPropagation(), f.preventDefault(), h && t.getAttribute("aria-expanded") === "true" ? (m(c), (_ = document.activeElement) == null || _.blur()) : (Ho() && tt(), d(c))), r != null && r.onClick && r.onClick(f);
|
|
1538
1540
|
};
|
|
1539
1541
|
}
|
|
1540
1542
|
}
|
|
1541
|
-
const
|
|
1543
|
+
const xo = `<div class="popup__wrapper popup__wrapper--hidden">
|
|
1542
1544
|
<div class="popup__content">
|
|
1543
1545
|
<div class="popup__arrow" data-popper-arrow></div>
|
|
1544
1546
|
</div>
|
|
1545
1547
|
</div>
|
|
1546
1548
|
`;
|
|
1547
|
-
function
|
|
1549
|
+
function pt(e, t) {
|
|
1548
1550
|
const n = e.getAttribute("id");
|
|
1549
1551
|
if (!n)
|
|
1550
1552
|
throw new Error("renderPopup: labelledByElement does not have an `id` attribute");
|
|
1551
1553
|
const o = U();
|
|
1552
1554
|
e.setAttribute("aria-controls", o);
|
|
1553
|
-
const r =
|
|
1555
|
+
const r = I(xo);
|
|
1554
1556
|
if (r.setAttribute("id", o), r.setAttribute("aria-labelledby", n), t != null && t.removePopupArrow) {
|
|
1555
1557
|
const i = r.querySelector(p(a.POPUP_ARROW));
|
|
1556
1558
|
if (!i)
|
|
@@ -1559,7 +1561,7 @@ function dt(e, t) {
|
|
|
1559
1561
|
}
|
|
1560
1562
|
return r;
|
|
1561
1563
|
}
|
|
1562
|
-
function
|
|
1564
|
+
function Wo(e) {
|
|
1563
1565
|
const t = e.closest("li");
|
|
1564
1566
|
if (!t)
|
|
1565
1567
|
throw console.error("element", e), new Error("toggleChildMenuExpansion: parent not found for child");
|
|
@@ -1574,18 +1576,18 @@ function Bo(e) {
|
|
|
1574
1576
|
n.classList.toggle(a.VISUALLY_HIDDEN), n.classList.contains(a.VISUALLY_HIDDEN) ? (o.setAttribute("aria-expanded", "false"), r.classList.add(a.IS_CLOSED), r.classList.remove(a.IS_OPEN)) : (o.setAttribute("aria-expanded", "true"), r.classList.remove(a.IS_CLOSED), r.classList.add(a.IS_OPEN));
|
|
1575
1577
|
});
|
|
1576
1578
|
}
|
|
1577
|
-
function
|
|
1579
|
+
function ko(e) {
|
|
1578
1580
|
return (t) => {
|
|
1579
|
-
t.preventDefault(), t.stopPropagation(),
|
|
1581
|
+
t.preventDefault(), t.stopPropagation(), Wo(e);
|
|
1580
1582
|
};
|
|
1581
1583
|
}
|
|
1582
|
-
function
|
|
1583
|
-
const e =
|
|
1584
|
+
function Ht() {
|
|
1585
|
+
const e = I(Ln);
|
|
1584
1586
|
return e.classList.add(a.IS_CLOSED), e;
|
|
1585
1587
|
}
|
|
1586
|
-
function
|
|
1588
|
+
function Fo(e, t, n) {
|
|
1587
1589
|
var f, h;
|
|
1588
|
-
const o =
|
|
1590
|
+
const o = I(Pn), r = o.querySelector(p(a.POPUP_MENU__TITLE));
|
|
1589
1591
|
if (!r)
|
|
1590
1592
|
throw new Error("renderPopupMenuItem: menuItemTitleWrapper not found");
|
|
1591
1593
|
const i = (
|
|
@@ -1626,9 +1628,9 @@ function xo(e, t, n) {
|
|
|
1626
1628
|
}), m) {
|
|
1627
1629
|
let _;
|
|
1628
1630
|
switch (n.childrenMenuType) {
|
|
1629
|
-
case
|
|
1630
|
-
_ =
|
|
1631
|
-
const E =
|
|
1631
|
+
case Y.FLYOUT: {
|
|
1632
|
+
_ = Ht(), i.appendChild(_), i.setAttribute("id", U());
|
|
1633
|
+
const E = ft(
|
|
1632
1634
|
{
|
|
1633
1635
|
menuItems: m,
|
|
1634
1636
|
title: t.title
|
|
@@ -1639,40 +1641,40 @@ function xo(e, t, n) {
|
|
|
1639
1641
|
removePopupArrow: !0
|
|
1640
1642
|
}
|
|
1641
1643
|
);
|
|
1642
|
-
o.appendChild(E),
|
|
1644
|
+
o.appendChild(E), ye(
|
|
1643
1645
|
o,
|
|
1644
1646
|
i,
|
|
1645
1647
|
E,
|
|
1646
1648
|
"menu",
|
|
1647
1649
|
{
|
|
1648
|
-
popupPlacement:
|
|
1650
|
+
popupPlacement: rt.RIGHT_START,
|
|
1649
1651
|
preventOnClickHandling: !0,
|
|
1650
1652
|
shouldFocusOnHover: !0
|
|
1651
1653
|
}
|
|
1652
1654
|
), u.remove(), s.remove();
|
|
1653
1655
|
break;
|
|
1654
1656
|
}
|
|
1655
|
-
case
|
|
1657
|
+
case Y.INLINE: {
|
|
1656
1658
|
const E = he(
|
|
1657
1659
|
m,
|
|
1658
1660
|
n
|
|
1659
|
-
),
|
|
1660
|
-
E.setAttribute("id",
|
|
1661
|
-
var
|
|
1662
|
-
for (let
|
|
1661
|
+
), b = U();
|
|
1662
|
+
E.setAttribute("id", b), E.classList.add(a.VISUALLY_HIDDEN), o.appendChild(E), i.onclick = ko(i), i.setAttribute("aria-expanded", "false"), i.setAttribute("aria-controls", b), _ = Ht(), i.appendChild(_), u.remove(), s.remove(), o.addEventListener("focusin", (g) => {
|
|
1663
|
+
var M, w, v, T;
|
|
1664
|
+
for (let A = (
|
|
1663
1665
|
/** @type Element | null | undefined */
|
|
1664
|
-
(
|
|
1665
|
-
);
|
|
1666
|
-
|
|
1666
|
+
(M = g.target) == null ? void 0 : M.closest("ul")
|
|
1667
|
+
); A; A = (w = A.parentElement) == null ? void 0 : w.closest("ul"))
|
|
1668
|
+
A.classList.remove(a.VISUALLY_HIDDEN), i.setAttribute("aria-expanded", "true"), g.target !== i && ((v = _ == null ? void 0 : _.classList) == null || v.remove(a.IS_CLOSED), (T = _ == null ? void 0 : _.classList) == null || T.add(a.IS_OPEN));
|
|
1667
1669
|
});
|
|
1668
1670
|
break;
|
|
1669
1671
|
}
|
|
1670
|
-
case
|
|
1672
|
+
case Y.MEGA_MENU: {
|
|
1671
1673
|
const E = he(
|
|
1672
1674
|
m,
|
|
1673
1675
|
n
|
|
1674
|
-
),
|
|
1675
|
-
E.setAttribute("id",
|
|
1676
|
+
), b = U();
|
|
1677
|
+
E.setAttribute("id", b), o.appendChild(E), u.remove(), i.remove(), s.appendChild(document.createTextNode(t.title));
|
|
1676
1678
|
break;
|
|
1677
1679
|
}
|
|
1678
1680
|
default:
|
|
@@ -1685,8 +1687,8 @@ function xo(e, t, n) {
|
|
|
1685
1687
|
u.setAttribute("href", t.actionUrl.url), i.remove(), l.remove(), s.remove();
|
|
1686
1688
|
else if (t.actionFunctionUrl)
|
|
1687
1689
|
u.setAttribute("href", t.actionFunctionUrl.url), u.onclick = (_) => {
|
|
1688
|
-
var E,
|
|
1689
|
-
(E = t.actionFunctionUrl) != null && E.skipHandleEvent || (_.stopPropagation(), _.preventDefault()), (
|
|
1690
|
+
var E, b;
|
|
1691
|
+
(E = t.actionFunctionUrl) != null && E.skipHandleEvent || (_.stopPropagation(), _.preventDefault()), (b = t.actionFunctionUrl) == null || b.actionFunction(_);
|
|
1690
1692
|
}, i.remove(), l.remove(), s.remove();
|
|
1691
1693
|
else if (t.isDivider)
|
|
1692
1694
|
r.remove(), o.setAttribute("aria-hidden", "true"), o.setAttribute("role", "separator");
|
|
@@ -1694,32 +1696,32 @@ function xo(e, t, n) {
|
|
|
1694
1696
|
throw console.error(t), new Error("renderPopupMenuItem: popupMenuItem must have either actionMenu, actionFunction, actionUrl, or isDivider (popupMenuItem.title)");
|
|
1695
1697
|
if (!t.isDivider && (c.appendChild(document.createTextNode(t.title)), d.appendChild(document.createTextNode(t.title)), (f = t.actionUrl) != null && f.openInNewTab || (h = t.actionFunctionUrl) != null && h.openInNewTab)) {
|
|
1696
1698
|
u.setAttribute("target", "_blank");
|
|
1697
|
-
const _ =
|
|
1699
|
+
const _ = I(Gt);
|
|
1698
1700
|
c.appendChild(_), d.appendChild(_);
|
|
1699
1701
|
}
|
|
1700
|
-
return (t.isSelected || t.actionMenu &&
|
|
1702
|
+
return (t.isSelected || t.actionMenu && ke(t.actionMenu, ["actionMenu"], (_) => !!_.isSelected)) && (i.classList.add(a.MENU_ITEM__SELECTED), u.classList.add(a.MENU_ITEM__SELECTED)), t.isSelected ? o.classList.add(a.MENU_ITEM__SELECTED) : o.classList.remove(a.MENU_ITEM__SELECTED), e.appendChild(o), o;
|
|
1701
1703
|
}
|
|
1702
1704
|
function he(e, t) {
|
|
1703
|
-
const n =
|
|
1704
|
-
return e == null || e.forEach((o) =>
|
|
1705
|
+
const n = I(yn);
|
|
1706
|
+
return e == null || e.forEach((o) => Fo(n, o, t)), n;
|
|
1705
1707
|
}
|
|
1706
|
-
function
|
|
1707
|
-
const o =
|
|
1708
|
+
function ft(e, t, n) {
|
|
1709
|
+
const o = pt(t, { removePopupArrow: n.removePopupArrow }), r = o.querySelector(p(a.POPUP_CONTENT_WRAPPER));
|
|
1708
1710
|
if (!r)
|
|
1709
1711
|
throw new Error("renderPopupMenu: contentWrapper not found");
|
|
1710
1712
|
const i = he(e.menuItems, n);
|
|
1711
1713
|
return i.setAttribute("aria-label", e.title), r.appendChild(i), o;
|
|
1712
1714
|
}
|
|
1713
|
-
const
|
|
1715
|
+
const qo = `<div class="utds-badge__wrapper">
|
|
1714
1716
|
<span class="utds-badge__value"></span>
|
|
1715
1717
|
<span class="utds-badge__label visually-hidden"></span>
|
|
1716
1718
|
</div>
|
|
1717
1719
|
`;
|
|
1718
|
-
function
|
|
1720
|
+
function _t(e) {
|
|
1719
1721
|
let t = null;
|
|
1720
1722
|
if (e) {
|
|
1721
1723
|
t = /** @type {HTMLElement} */
|
|
1722
|
-
|
|
1724
|
+
I(qo), t.classList.add(a.BADGE_WRAPPER__ACTION_ITEM);
|
|
1723
1725
|
const n = t.querySelector(p(a.BADGE__LABEL));
|
|
1724
1726
|
if (!n)
|
|
1725
1727
|
throw new Error("renderActionItemBadge: badgeLabel not found");
|
|
@@ -1734,8 +1736,8 @@ function ft(e) {
|
|
|
1734
1736
|
}
|
|
1735
1737
|
return t;
|
|
1736
1738
|
}
|
|
1737
|
-
function
|
|
1738
|
-
const t =
|
|
1739
|
+
function Vo(e) {
|
|
1740
|
+
const t = I(wn);
|
|
1739
1741
|
t.getAttribute("id") || t.setAttribute("id", U());
|
|
1740
1742
|
const n = document.createTextNode(e.title), o = (
|
|
1741
1743
|
/** @type {HTMLElement} */
|
|
@@ -1753,30 +1755,30 @@ function ko(e) {
|
|
|
1753
1755
|
if (!i)
|
|
1754
1756
|
throw new Error("renderActionItem: iconButton not found");
|
|
1755
1757
|
e.className && i.classList.add(e.className);
|
|
1756
|
-
const u =
|
|
1758
|
+
const u = _t(e.badge);
|
|
1757
1759
|
u && i.appendChild(u);
|
|
1758
|
-
const s =
|
|
1760
|
+
const s = I(e.icon);
|
|
1759
1761
|
s.setAttribute("role", "presentation"), i.appendChild(s);
|
|
1760
1762
|
let l = null;
|
|
1761
1763
|
if (e.actionFunction)
|
|
1762
1764
|
i.onclick = e.actionFunction;
|
|
1763
1765
|
else if (e.actionDom) {
|
|
1764
1766
|
const c = U();
|
|
1765
|
-
i.setAttribute("id", c), l =
|
|
1767
|
+
i.setAttribute("id", c), l = I(typeof e.actionDom == "function" ? e.actionDom() : e.actionDom);
|
|
1766
1768
|
} else if (e.actionPopupMenu) {
|
|
1767
1769
|
const c = U();
|
|
1768
|
-
i.setAttribute("id", c), l =
|
|
1770
|
+
i.setAttribute("id", c), l = I(On);
|
|
1769
1771
|
const d = l.querySelector(p(a.POPUP_MENU_WRAPPER__WRAPPER_TITLE));
|
|
1770
1772
|
if (!d)
|
|
1771
1773
|
throw new Error("renderMobileActionItem: actionItemContentTitle not found");
|
|
1772
1774
|
d.appendChild(document.createTextNode(e.actionPopupMenu.title));
|
|
1773
|
-
const m = he(e.actionPopupMenu.menuItems, { childrenMenuType:
|
|
1775
|
+
const m = he(e.actionPopupMenu.menuItems, { childrenMenuType: Y.INLINE });
|
|
1774
1776
|
l.appendChild(m);
|
|
1775
1777
|
} else
|
|
1776
1778
|
throw console.error(e), new Error("Action Item: no defined action; must have either actionFunction, actionDom, or actionPopupMenu");
|
|
1777
1779
|
return { actionItemElement: t, actionItemContent: l };
|
|
1778
1780
|
}
|
|
1779
|
-
function
|
|
1781
|
+
function $o() {
|
|
1780
1782
|
var u, s, l;
|
|
1781
1783
|
const e = document.getElementById(a.MOBILE_MENU_ACTON_BAR__HOME_ID);
|
|
1782
1784
|
if (!e)
|
|
@@ -1787,11 +1789,11 @@ function Fo() {
|
|
|
1787
1789
|
);
|
|
1788
1790
|
if (!t)
|
|
1789
1791
|
throw new Error("renderMobileActionItems: homeActionItemWrapper not found");
|
|
1790
|
-
const o = !!
|
|
1792
|
+
const o = !!L().utahId ? document.getElementById(a.MOBILE_MENU_ACTON_BAR__PROFILE_ID) : null, r = (
|
|
1791
1793
|
/** @type {HTMLElement} */
|
|
1792
1794
|
(u = o == null ? void 0 : o.closest) == null ? void 0 : u.call(o, p(a.MOBILE_MENU_ACTION_BAR__ACTION_ITEM_WRAPPER))
|
|
1793
1795
|
);
|
|
1794
|
-
(l = (s = [...
|
|
1796
|
+
(l = (s = [...L().actionItems || []].reverse()) == null ? void 0 : s.map((c) => ({ actionItem: c, ...Vo(c) }))) == null || l.forEach(({ actionItem: c, actionItemContent: d, actionItemElement: m }) => {
|
|
1795
1797
|
let f;
|
|
1796
1798
|
switch (c.mobileMenuLocation) {
|
|
1797
1799
|
case "left":
|
|
@@ -1806,18 +1808,18 @@ function Fo() {
|
|
|
1806
1808
|
break;
|
|
1807
1809
|
}
|
|
1808
1810
|
if (f && (f.after(m), d)) {
|
|
1809
|
-
const h =
|
|
1811
|
+
const h = nt(d);
|
|
1810
1812
|
let _ = null;
|
|
1811
|
-
c.actionDom ? _ = "dialog" : c.actionPopupMenu && (_ = "menu"),
|
|
1813
|
+
c.actionDom ? _ = "dialog" : c.actionPopupMenu && (_ = "menu"), ot(
|
|
1812
1814
|
m,
|
|
1813
1815
|
h,
|
|
1814
1816
|
m,
|
|
1815
1817
|
{ ariaHasPopupType: _, shouldOnClickCloseMenu: !1 }
|
|
1816
1818
|
);
|
|
1817
1819
|
}
|
|
1818
|
-
}),
|
|
1820
|
+
}), L().mainMenu || (e.remove(), t.remove());
|
|
1819
1821
|
}
|
|
1820
|
-
const
|
|
1822
|
+
const Go = `<div class="utds-footer utah-design-system">
|
|
1821
1823
|
<div class="utds-footer__horizontal-divider">
|
|
1822
1824
|
<hr />
|
|
1823
1825
|
</div>
|
|
@@ -1835,76 +1837,76 @@ const qo = `<div class="utds-footer utah-design-system">
|
|
|
1835
1837
|
</div>
|
|
1836
1838
|
<div class="utds-footer__links">
|
|
1837
1839
|
<ul>
|
|
1838
|
-
<li><a href="
|
|
1839
|
-
<li><a href="
|
|
1840
|
-
<li><a href="
|
|
1841
|
-
<li><a href="
|
|
1842
|
-
<li><a href="
|
|
1840
|
+
<li><a href="https://www.utah.gov" target="__blank" rel="noreferrer">Utah.gov Home</a></li>
|
|
1841
|
+
<li><a href="https://www.utah.gov/disclaimer.html" target="__blank" rel="noreferrer">Terms of Use</a></li>
|
|
1842
|
+
<li><a href="https://www.utah.gov/privacypolicy.html" target="__blank" rel="noreferrer">Privacy Policy</a></li>
|
|
1843
|
+
<li><a href="https://www.utah.gov/accessibility.html" target="__blank" rel="noreferrer">Accessibility</a></li>
|
|
1844
|
+
<li><a href="https://www.utah.gov/translate.html" target="__blank" rel="noreferrer">Translate</a></li>
|
|
1843
1845
|
</ul>
|
|
1844
1846
|
</div>
|
|
1845
1847
|
</div>
|
|
1846
1848
|
`;
|
|
1847
1849
|
let ae = null;
|
|
1848
|
-
function
|
|
1849
|
-
var o, r, i, u, s, l, c, d, m, f, h, _, E,
|
|
1850
|
-
const e =
|
|
1850
|
+
function zo() {
|
|
1851
|
+
var o, r, i, u, s, l, c, d, m, f, h, _, E, b, g, M;
|
|
1852
|
+
const e = L(), t = document.querySelector(p(a.FOOTER));
|
|
1851
1853
|
let n = t;
|
|
1852
1854
|
if (e.footer === null)
|
|
1853
1855
|
t == null || t.remove();
|
|
1854
1856
|
else if (((o = ae == null ? void 0 : ae.footer) == null ? void 0 : o.domLocationTarget) !== ((r = e == null ? void 0 : e.footer) == null ? void 0 : r.domLocationTarget) || ((i = ae == null ? void 0 : ae.footer) == null ? void 0 : i.showHorizontalRule) !== ((u = e == null ? void 0 : e.footer) == null ? void 0 : u.showHorizontalRule) || !t) {
|
|
1855
|
-
t && t.remove(), n =
|
|
1856
|
-
let
|
|
1857
|
+
t && t.remove(), n = I(Go);
|
|
1858
|
+
let v = document.body;
|
|
1857
1859
|
if ((s = e == null ? void 0 : e.footer) != null && s.domLocationTarget) {
|
|
1858
|
-
const
|
|
1860
|
+
const T = [
|
|
1859
1861
|
(l = e == null ? void 0 : e.footer) == null ? void 0 : l.domLocationTarget.cssSelector,
|
|
1860
1862
|
(c = e == null ? void 0 : e.footer) == null ? void 0 : c.domLocationTarget.element,
|
|
1861
1863
|
(d = e == null ? void 0 : e.footer) == null ? void 0 : d.domLocationTarget.elementFunction
|
|
1862
|
-
].filter((
|
|
1863
|
-
if (X(
|
|
1864
|
-
|
|
1864
|
+
].filter((A) => A);
|
|
1865
|
+
if (X(T.length < 1, "renderFooter: footer.domLocationTarget must either have a value for one of its properties or not be specified at all"), X(T.length > 1, "renderFooter: footer.domLocationTarget must only have one target specified"), (m = e == null ? void 0 : e.footer) != null && m.domLocationTarget.cssSelector)
|
|
1866
|
+
v = document.querySelector((f = e == null ? void 0 : e.footer) == null ? void 0 : f.domLocationTarget.cssSelector), X(!v, `renderFooter: element not found for domLocationTarget.cssSelector ${(h = e == null ? void 0 : e.footer) == null ? void 0 : h.domLocationTarget.cssSelector}`);
|
|
1865
1867
|
else if ((_ = e == null ? void 0 : e.footer) != null && _.domLocationTarget.element)
|
|
1866
|
-
|
|
1867
|
-
else if ((
|
|
1868
|
-
|
|
1868
|
+
v = (E = e == null ? void 0 : e.footer) == null ? void 0 : E.domLocationTarget.element;
|
|
1869
|
+
else if ((b = e == null ? void 0 : e.footer) != null && b.domLocationTarget.elementFunction)
|
|
1870
|
+
v = (g = e == null ? void 0 : e.footer) == null ? void 0 : g.domLocationTarget.elementFunction(), X(!v, "renderFooter: element not returned from domLocationTarget.elementFunction");
|
|
1869
1871
|
else
|
|
1870
1872
|
throw new Error("renderFooter: domLocationTarget must have at least one field set");
|
|
1871
1873
|
}
|
|
1872
|
-
if (
|
|
1873
|
-
const
|
|
1874
|
-
X(!
|
|
1874
|
+
if (v == null || v.appendChild(n), !((M = e == null ? void 0 : e.footer) != null && M.showHorizontalRule)) {
|
|
1875
|
+
const T = document.querySelector(p(a.FOOTER_HORIZONTAL_DIVIDER));
|
|
1876
|
+
X(!T, "renderFooter: cannot remove horizontal rule; not found"), T == null || T.remove();
|
|
1875
1877
|
}
|
|
1876
1878
|
ae = JSON.parse(JSON.stringify(e));
|
|
1877
1879
|
}
|
|
1878
1880
|
return n;
|
|
1879
1881
|
}
|
|
1880
|
-
const
|
|
1881
|
-
`,
|
|
1882
|
-
`,
|
|
1883
|
-
`,
|
|
1884
|
-
`,
|
|
1885
|
-
`,
|
|
1886
|
-
`,
|
|
1882
|
+
const Yo = `<div class="utds-citizen-experience-wrapper--mobile"></div>
|
|
1883
|
+
`, Ko = `<h1 class="utds-logo-wrapper"></h1>
|
|
1884
|
+
`, jo = `<div class="utah-design-system utds-header" role="banner" aria-label="Utah.gov Header"></div>
|
|
1885
|
+
`, Zo = `<span class="utds-logo-vert-line"></span>
|
|
1886
|
+
`, Xo = `<div class="utds-citizen-experience-wrapper"></div>
|
|
1887
|
+
`, Jo = `<div class="utds-action-items-wrapper"></div>
|
|
1888
|
+
`, Qo = `<div class="utds-header-action-item">
|
|
1887
1889
|
<button type="button" class="icon-button utds-header-action-item__icon-button">
|
|
1888
1890
|
<div class="utds-header-action-item__title visually-hidden"></div>
|
|
1889
1891
|
</button>
|
|
1890
1892
|
</div>
|
|
1891
|
-
`,
|
|
1893
|
+
`, er = `<div class="tooltip__wrapper tooltip__wrapper--hidden" aria-hidden="true">
|
|
1892
1894
|
<div class="tooltip__content">
|
|
1893
1895
|
<div class="tooltip__arrow" data-popper-arrow></div>
|
|
1894
1896
|
</div>
|
|
1895
1897
|
</div>
|
|
1896
1898
|
`;
|
|
1897
1899
|
let ue = NaN;
|
|
1898
|
-
function
|
|
1899
|
-
const n =
|
|
1900
|
+
function Ae(e, t) {
|
|
1901
|
+
const n = I(er), o = n.querySelector(p(a.TOOLTIP__CONTENT));
|
|
1900
1902
|
if (!o)
|
|
1901
1903
|
throw new Error("hookupToolTip: toolTipContent not found");
|
|
1902
1904
|
o.appendChild(t), e.appendChild(n);
|
|
1903
|
-
const r =
|
|
1905
|
+
const r = tn(
|
|
1904
1906
|
e,
|
|
1905
1907
|
n,
|
|
1906
1908
|
{
|
|
1907
|
-
placement:
|
|
1909
|
+
placement: rt.BOTTOM,
|
|
1908
1910
|
modifiers: [
|
|
1909
1911
|
{
|
|
1910
1912
|
name: "offset",
|
|
@@ -1935,8 +1937,8 @@ function Me(e, t) {
|
|
|
1935
1937
|
);
|
|
1936
1938
|
};
|
|
1937
1939
|
}
|
|
1938
|
-
function
|
|
1939
|
-
const t =
|
|
1940
|
+
function tr(e) {
|
|
1941
|
+
const t = I(Qo), n = document.createTextNode(e.title), o = (
|
|
1940
1942
|
/** @type {HTMLElement} */
|
|
1941
1943
|
t instanceof HTMLCollection ? t[0] : t
|
|
1942
1944
|
);
|
|
@@ -1949,9 +1951,9 @@ function Jo(e) {
|
|
|
1949
1951
|
if (!i)
|
|
1950
1952
|
throw new Error("renderActionItem: iconButton not found");
|
|
1951
1953
|
e.className && i.classList.add(e.className);
|
|
1952
|
-
const u =
|
|
1954
|
+
const u = _t(e.badge);
|
|
1953
1955
|
u && i.appendChild(u);
|
|
1954
|
-
const s =
|
|
1956
|
+
const s = I(e.icon);
|
|
1955
1957
|
if (s.setAttribute("role", "presentation"), i.appendChild(s), !(i instanceof HTMLElement))
|
|
1956
1958
|
throw new Error("renderActionItem: iconButton is not an HTMLElement");
|
|
1957
1959
|
if (e.actionFunction)
|
|
@@ -1959,79 +1961,79 @@ function Jo(e) {
|
|
|
1959
1961
|
else if (e.actionDom) {
|
|
1960
1962
|
const l = U();
|
|
1961
1963
|
i.setAttribute("id", l);
|
|
1962
|
-
const c =
|
|
1964
|
+
const c = pt(i), d = (
|
|
1963
1965
|
/** @type {HTMLElement} */
|
|
1964
1966
|
c.querySelector(p(a.POPUP_CONTENT_WRAPPER))
|
|
1965
1967
|
);
|
|
1966
1968
|
if (!d)
|
|
1967
1969
|
throw new Error("renderPopupMenu: contentWrapper not found");
|
|
1968
|
-
d.appendChild(
|
|
1970
|
+
d.appendChild(I(typeof e.actionDom == "function" ? e.actionDom() : e.actionDom)), t.appendChild(c), ye(o, i, c, "dialog", void 0);
|
|
1969
1971
|
} else if (e.actionPopupMenu) {
|
|
1970
1972
|
const l = U();
|
|
1971
1973
|
i.setAttribute("id", l);
|
|
1972
|
-
const c =
|
|
1974
|
+
const c = ft(
|
|
1973
1975
|
/** @type {PopupMenu} */
|
|
1974
1976
|
e.actionPopupMenu,
|
|
1975
1977
|
i,
|
|
1976
|
-
{ childrenMenuType:
|
|
1978
|
+
{ childrenMenuType: Y.INLINE }
|
|
1977
1979
|
);
|
|
1978
|
-
t.appendChild(c),
|
|
1980
|
+
t.appendChild(c), ye(o, i, c, "menu", void 0);
|
|
1979
1981
|
} else
|
|
1980
1982
|
throw console.error(e), new Error("Action Item: no defined action; must have either actionFunction, actionDom, or actionPopupMenu");
|
|
1981
|
-
return
|
|
1983
|
+
return Ae(t, document.createTextNode(e.title)), t;
|
|
1982
1984
|
}
|
|
1983
|
-
function
|
|
1985
|
+
function nr() {
|
|
1984
1986
|
var n, o;
|
|
1985
|
-
const { actionItems: e } =
|
|
1987
|
+
const { actionItems: e } = L();
|
|
1986
1988
|
let t = null;
|
|
1987
|
-
return e != null && e.length && (t =
|
|
1989
|
+
return e != null && e.length && (t = I(Jo), (o = (n = L().actionItems) == null ? void 0 : n.map((r) => tr(r))) == null || o.forEach((r) => t.appendChild(r))), t;
|
|
1988
1990
|
}
|
|
1989
|
-
const
|
|
1990
|
-
`,
|
|
1991
|
-
`,
|
|
1991
|
+
const or = `<button class="utds-utah-id__button button--solid" type="button">UtahID Sign In</button>
|
|
1992
|
+
`, on = `<div class="utds-utah-id-wrapper"></div>
|
|
1993
|
+
`, Pe = {
|
|
1992
1994
|
PROFILE: "https://id.utah.gov",
|
|
1993
1995
|
SIGN_IN: `https://id.utah.gov/login?goto=${window.location}`,
|
|
1994
1996
|
SIGN_OUT: `https://id.utah.gov/logout?goto=${window.location}`,
|
|
1995
1997
|
USER_INFO: "https://id.utah.gov/api/userInfo"
|
|
1996
|
-
},
|
|
1998
|
+
}, rr = `<div class="vertical-menu__wrapper">
|
|
1997
1999
|
<div class="vertical-menu__wrapper-title"></div>
|
|
1998
2000
|
</div>
|
|
1999
2001
|
`;
|
|
2000
|
-
function
|
|
2001
|
-
const n =
|
|
2002
|
+
function rn(e, t) {
|
|
2003
|
+
const n = I(rr), o = n.querySelector(p(a.POPUP_MENU_WRAPPER__WRAPPER_TITLE));
|
|
2002
2004
|
if (!o)
|
|
2003
2005
|
throw new Error("renderMenuWithTitle: menuTitleDiv not found");
|
|
2004
2006
|
return o.appendChild(document.createTextNode(t)), n.appendChild(e), n;
|
|
2005
2007
|
}
|
|
2006
|
-
let
|
|
2007
|
-
function
|
|
2008
|
-
|
|
2008
|
+
let y = null;
|
|
2009
|
+
function an(e) {
|
|
2010
|
+
y = e, document.querySelectorAll(p(a.UTAH_ID__BUTTON)).forEach((n) => {
|
|
2009
2011
|
var o;
|
|
2010
2012
|
if (n) {
|
|
2011
|
-
if (n.innerHTML = "",
|
|
2013
|
+
if (n.innerHTML = "", y != null && y.userInfo && ((o = y.userInfo) != null && o.authenticated)) {
|
|
2012
2014
|
const u = document.createElement("span");
|
|
2013
|
-
u.appendChild(document.createTextNode("UtahID Account:")), u.classList.add(a.VISUALLY_HIDDEN), n.appendChild(u), n.appendChild(document.createTextNode(`Hello, ${
|
|
2015
|
+
u.appendChild(document.createTextNode("UtahID Account:")), u.classList.add(a.VISUALLY_HIDDEN), n.appendChild(u), n.appendChild(document.createTextNode(`Hello, ${y.userInfo.first || ""}`));
|
|
2014
2016
|
} else
|
|
2015
2017
|
n.appendChild(document.createTextNode("UtahID Sign In"));
|
|
2016
2018
|
const r = n.getAttribute("aria-controls");
|
|
2017
2019
|
if (!r)
|
|
2018
2020
|
throw new Error(`authChangedEventHandler: popup id for button not found - ${r}`);
|
|
2019
2021
|
const i = document.getElementById(r);
|
|
2020
|
-
i &&
|
|
2022
|
+
i && ht(n, i);
|
|
2021
2023
|
}
|
|
2022
2024
|
});
|
|
2023
2025
|
}
|
|
2024
|
-
function
|
|
2026
|
+
function ht(e, t) {
|
|
2025
2027
|
var n;
|
|
2026
|
-
e && t && (!!(
|
|
2028
|
+
e && t && (!!(y != null && y.isDefinitive) && !!((n = y == null ? void 0 : y.userInfo) != null && n.authenticated) ? (e.setAttribute("aria-haspopup", "menu"), e.setAttribute("aria-expanded", "false"), t.removeAttribute("aria-hidden")) : (e.removeAttribute("aria-haspopup"), e.removeAttribute("aria-expanded"), t.setAttribute("aria-hidden", "true")));
|
|
2027
2029
|
}
|
|
2028
|
-
function
|
|
2029
|
-
const e =
|
|
2030
|
-
return e.setAttribute("id", U()),
|
|
2030
|
+
function sn() {
|
|
2031
|
+
const e = I(or);
|
|
2032
|
+
return e.setAttribute("id", U()), y && an(y), e;
|
|
2031
2033
|
}
|
|
2032
|
-
function
|
|
2034
|
+
function ln(e) {
|
|
2033
2035
|
var l, c, d;
|
|
2034
|
-
const t =
|
|
2036
|
+
const t = L(), n = t.utahId !== !1 && t.utahId !== !0 && ((l = t.utahId) == null ? void 0 : l.onProfile), o = t.utahId !== !1 && t.utahId !== !0 && ((c = t.utahId) == null ? void 0 : c.onSignOut), r = [...t.utahId !== !0 && t.utahId !== !1 && ((d = t.utahId) == null ? void 0 : d.menuItems) || []];
|
|
2035
2037
|
r.length && r.push({
|
|
2036
2038
|
isDivider: !0,
|
|
2037
2039
|
title: "--divider--"
|
|
@@ -2039,32 +2041,32 @@ function rn(e) {
|
|
|
2039
2041
|
const i = [
|
|
2040
2042
|
...r,
|
|
2041
2043
|
{
|
|
2042
|
-
actionUrl: n ? void 0 : { url:
|
|
2044
|
+
actionUrl: n ? void 0 : { url: Pe.PROFILE, openInNewTab: !0 },
|
|
2043
2045
|
actionFunction: n || void 0,
|
|
2044
2046
|
className: "external-link",
|
|
2045
2047
|
title: "UtahID Profile"
|
|
2046
2048
|
},
|
|
2047
2049
|
{
|
|
2048
|
-
actionUrl: o ? void 0 : { url:
|
|
2050
|
+
actionUrl: o ? void 0 : { url: Pe.SIGN_OUT },
|
|
2049
2051
|
actionFunction: o || void 0,
|
|
2050
2052
|
title: "Sign Out"
|
|
2051
2053
|
}
|
|
2052
|
-
], u = he(i, { childrenMenuType:
|
|
2054
|
+
], u = he(i, { childrenMenuType: Y.INLINE }), s = e ? rn(u, "Utah ID Menu") : u;
|
|
2053
2055
|
return s.setAttribute("aria-label", "Utah Id Menu"), s.setAttribute("id", U()), s;
|
|
2054
2056
|
}
|
|
2055
|
-
function
|
|
2057
|
+
function ir() {
|
|
2056
2058
|
var s;
|
|
2057
|
-
const e =
|
|
2059
|
+
const e = I(on), t = sn();
|
|
2058
2060
|
t.setAttribute("id", U()), e.appendChild(t);
|
|
2059
|
-
const n =
|
|
2061
|
+
const n = ln(!1), o = pt(t), r = (
|
|
2060
2062
|
/** @type {HTMLElement} */
|
|
2061
2063
|
o.querySelector(p(a.POPUP_CONTENT_WRAPPER))
|
|
2062
2064
|
);
|
|
2063
2065
|
if (!r)
|
|
2064
2066
|
throw new Error("renderUtahIdForDesktop: contentWrapper not found");
|
|
2065
|
-
r.appendChild(n), e.appendChild(o),
|
|
2066
|
-
const i =
|
|
2067
|
-
return
|
|
2067
|
+
r.appendChild(n), e.appendChild(o), ht(t, o);
|
|
2068
|
+
const i = L(), u = i.utahId !== !1 && i.utahId !== !0 && ((s = i.utahId) == null ? void 0 : s.onSignIn);
|
|
2069
|
+
return ye(
|
|
2068
2070
|
e,
|
|
2069
2071
|
t,
|
|
2070
2072
|
o,
|
|
@@ -2072,55 +2074,55 @@ function nr() {
|
|
|
2072
2074
|
{
|
|
2073
2075
|
isPerformPopup: () => {
|
|
2074
2076
|
var l;
|
|
2075
|
-
return !!(
|
|
2077
|
+
return !!(y != null && y.isDefinitive) && !!((l = y == null ? void 0 : y.userInfo) != null && l.authenticated);
|
|
2076
2078
|
},
|
|
2077
2079
|
onClick: (l) => {
|
|
2078
2080
|
var c;
|
|
2079
|
-
(!(
|
|
2081
|
+
(!(y != null && y.isDefinitive) || !((c = y == null ? void 0 : y.userInfo) != null && c.authenticated)) && (u ? u(l) : (l.preventDefault(), l.stopPropagation(), window.location.href = Pe.SIGN_IN));
|
|
2080
2082
|
}
|
|
2081
2083
|
}
|
|
2082
2084
|
), e;
|
|
2083
2085
|
}
|
|
2084
|
-
function
|
|
2085
|
-
const e =
|
|
2086
|
+
function ar() {
|
|
2087
|
+
const e = I(on), t = sn(), n = t.getAttribute("id");
|
|
2086
2088
|
if (!n)
|
|
2087
2089
|
throw new Error("renderUtahIdForMobile: utahIdButton has no id");
|
|
2088
2090
|
e.appendChild(t);
|
|
2089
|
-
const o =
|
|
2091
|
+
const o = ln(!0), r = o.getAttribute("id");
|
|
2090
2092
|
if (!r)
|
|
2091
2093
|
throw new Error("renderUtahIdForMobile: utahIdPopupMenu has no id");
|
|
2092
|
-
return e.appendChild(o), t.setAttribute("aria-controls", r), o.setAttribute("aria-labelledby", n),
|
|
2094
|
+
return e.appendChild(o), t.setAttribute("aria-controls", r), o.setAttribute("aria-labelledby", n), ht(t, o), { button: t, menu: o };
|
|
2093
2095
|
}
|
|
2094
|
-
function
|
|
2095
|
-
const e =
|
|
2096
|
-
return t && e.appendChild(t),
|
|
2096
|
+
function sr() {
|
|
2097
|
+
const e = I(Xo), t = nr();
|
|
2098
|
+
return t && e.appendChild(t), L().utahId !== !1 && e.appendChild(ir()), e;
|
|
2097
2099
|
}
|
|
2098
|
-
const
|
|
2100
|
+
const lr = `<div class="utds-title-wrapper">
|
|
2099
2101
|
<div class="utds-title-wrapper__logo"></div>
|
|
2100
2102
|
<div class="utds-title-wrapper__title"></div>
|
|
2101
2103
|
</div>
|
|
2102
|
-
`,
|
|
2104
|
+
`, cr = `<a class="utds-title-wrapper">
|
|
2103
2105
|
<div class="utds-title-wrapper__logo"></div>
|
|
2104
2106
|
<div class="utds-title-wrapper__title"></div>
|
|
2105
2107
|
</a>
|
|
2106
2108
|
`;
|
|
2107
|
-
function
|
|
2108
|
-
const e =
|
|
2109
|
+
function ur() {
|
|
2110
|
+
const e = L().titleURL, t = I(e ? cr : lr);
|
|
2109
2111
|
if (!t)
|
|
2110
2112
|
throw new Error("LogoTitle: titleWrapper is null");
|
|
2111
2113
|
e && t.setAttribute("href", e);
|
|
2112
2114
|
const n = t.querySelector(p(a.TITLE__LOGO));
|
|
2113
2115
|
if (!n)
|
|
2114
2116
|
throw new Error("LogoTitle: logoWrapper is null");
|
|
2115
|
-
const o =
|
|
2117
|
+
const o = L().logo, r = L().showTitle, i = L().title;
|
|
2116
2118
|
if (o) {
|
|
2117
2119
|
let l;
|
|
2118
2120
|
if (o.htmlString)
|
|
2119
|
-
l =
|
|
2121
|
+
l = I(K(o.htmlString));
|
|
2120
2122
|
else if (o.element)
|
|
2121
2123
|
l = K(o.element);
|
|
2122
2124
|
else if (o.imageUrl)
|
|
2123
|
-
l =
|
|
2125
|
+
l = I(`<img src=${K(o.imageUrl)} id="design-system-logo" />`);
|
|
2124
2126
|
else
|
|
2125
2127
|
throw new Error("LogoTitle: logo set but has no settings");
|
|
2126
2128
|
l.setAttribute("role", "presentation"), n.appendChild(l);
|
|
@@ -2129,7 +2131,7 @@ function sr() {
|
|
|
2129
2131
|
const u = document.createTextNode(i), s = t.querySelector(p(a.TITLE__TITLE));
|
|
2130
2132
|
return s == null || s.appendChild(u), !r && o && (s == null || s.classList.add(a.VISUALLY_HIDDEN)), t;
|
|
2131
2133
|
}
|
|
2132
|
-
const
|
|
2134
|
+
const dr = `<div class="utah-logo-wrapper">
|
|
2133
2135
|
<button class="utah-logo-svg" id="utah-logo-svg" aria-haspopup="dialog">
|
|
2134
2136
|
<span class="visually-hidden" id="utah-logo-description">An official website of the State of Utah. Click to learn
|
|
2135
2137
|
more.</span>
|
|
@@ -2146,7 +2148,7 @@ const lr = `<div class="utah-logo-wrapper">
|
|
|
2146
2148
|
</svg>
|
|
2147
2149
|
</button>
|
|
2148
2150
|
</div>
|
|
2149
|
-
`,
|
|
2151
|
+
`, pr = `<div class="utah-logo-wrapper">
|
|
2150
2152
|
<button class="utah-logo-svg" id="utah-logo-svg" aria-haspopup="dialog">
|
|
2151
2153
|
<span class="visually-hidden" id="utah-logo-description">An official website of the State of Utah. Click to learn
|
|
2152
2154
|
more.</span>
|
|
@@ -2163,45 +2165,51 @@ const lr = `<div class="utah-logo-wrapper">
|
|
|
2163
2165
|
</svg>
|
|
2164
2166
|
</button>
|
|
2165
2167
|
</div>
|
|
2166
|
-
`,
|
|
2168
|
+
`, fr = `<div class="utds-official-website-hover__wrapper">
|
|
2167
2169
|
How do I know it’s official?<br />
|
|
2168
2170
|
Learn more.
|
|
2169
2171
|
</div>
|
|
2170
2172
|
`;
|
|
2171
|
-
function
|
|
2173
|
+
function _r() {
|
|
2172
2174
|
let e;
|
|
2173
|
-
switch (
|
|
2174
|
-
case
|
|
2175
|
-
e =
|
|
2175
|
+
switch (L().size) {
|
|
2176
|
+
case Te.LARGE:
|
|
2177
|
+
e = dr;
|
|
2176
2178
|
break;
|
|
2177
|
-
case
|
|
2178
|
-
case
|
|
2179
|
-
e =
|
|
2179
|
+
case Te.SMALL:
|
|
2180
|
+
case Te.MEDIUM:
|
|
2181
|
+
e = pr;
|
|
2180
2182
|
break;
|
|
2181
2183
|
default:
|
|
2182
|
-
throw new Error(`Unknown settings size: '${
|
|
2184
|
+
throw new Error(`Unknown settings size: '${L().size}'`);
|
|
2183
2185
|
}
|
|
2184
|
-
const t =
|
|
2186
|
+
const t = I(e);
|
|
2185
2187
|
if (!/** @type {HTMLElement} */
|
|
2186
2188
|
t.querySelector(p(a.LOGO_SVG)))
|
|
2187
2189
|
throw new Error("UtahLogo: logoButton not found");
|
|
2188
|
-
return t.setAttribute("id", U()),
|
|
2190
|
+
return t.setAttribute("id", U()), Ae(t, I(fr)), t;
|
|
2189
2191
|
}
|
|
2190
|
-
function
|
|
2192
|
+
function hr() {
|
|
2191
2193
|
var n;
|
|
2192
|
-
const e =
|
|
2193
|
-
e.classList.add(`utds-header--${((n =
|
|
2194
|
-
const t =
|
|
2195
|
-
return e.appendChild(t), t.appendChild(
|
|
2194
|
+
const e = I(jo);
|
|
2195
|
+
e.classList.add(`utds-header--${((n = L().size) == null ? void 0 : n.toLowerCase()) || Te.MEDIUM}`);
|
|
2196
|
+
const t = I(Ko);
|
|
2197
|
+
return e.appendChild(t), t.appendChild(_r()), t.appendChild(I(Zo)), t.appendChild(ur()), e.appendChild(sr()), e.appendChild(I(Yo)), e;
|
|
2196
2198
|
}
|
|
2197
|
-
const
|
|
2199
|
+
const mr = `<li class="menu-item">
|
|
2198
2200
|
<span class="menu-item__title">
|
|
2199
|
-
<button class="menu-item__button-title" type="button"
|
|
2200
|
-
|
|
2201
|
+
<button class="menu-item__button-title" type="button">
|
|
2202
|
+
<span class="menu-item__link-title-span"></span>
|
|
2203
|
+
<span class="menu-item__menu-arrow utds-icon-before-chevron-down" aria-hidden="true"></span>
|
|
2204
|
+
</button>
|
|
2205
|
+
<a class="menu-item__link-title">
|
|
2206
|
+
<span class="menu-item__link-title-span"></span>
|
|
2207
|
+
<span class="menu-item__menu-arrow utds-icon-before-chevron-down" aria-hidden="true"></span>
|
|
2208
|
+
</a>
|
|
2201
2209
|
<span class="menu-chiclet"></span>
|
|
2202
2210
|
</span>
|
|
2203
2211
|
</li>
|
|
2204
|
-
`,
|
|
2212
|
+
`, Er = `<div class="utah-design-system main-menu__outer">
|
|
2205
2213
|
<div class="main-menu__wrapper">
|
|
2206
2214
|
<nav class="horizontal-menu main-menu__nav">
|
|
2207
2215
|
<h2 class="main-menu__title visually-hidden"></h2>
|
|
@@ -2223,12 +2231,11 @@ const fr = `<li class="menu-item">
|
|
|
2223
2231
|
id="utds-main-menu__hamburger">
|
|
2224
2232
|
<div>
|
|
2225
2233
|
<span class="utds-icon-before-hamburger" id="utds-main-menu__hamburger-icon" aria-hidden="true"></span>
|
|
2226
|
-
<span class="visually-hidden">Open Mobile Menu</span>
|
|
2227
2234
|
</div>
|
|
2228
2235
|
</button>
|
|
2229
2236
|
</div>
|
|
2230
2237
|
</div>
|
|
2231
|
-
`,
|
|
2238
|
+
`, vr = `<div class="utah-design-system" id="search-modal">
|
|
2232
2239
|
<div class="search-modal__close-button-wrapper">
|
|
2233
2240
|
<button type="button" class="search-modal__close-button button icon-button icon-button--borderless">
|
|
2234
2241
|
<span class="utds-icon-before-x-icon" aria-hidden="true"></span>
|
|
@@ -2254,7 +2261,7 @@ const fr = `<li class="menu-item">
|
|
|
2254
2261
|
<div class="search-backdrop modal-backdrop backdrop-dark"></div>
|
|
2255
2262
|
</div>
|
|
2256
2263
|
`;
|
|
2257
|
-
function
|
|
2264
|
+
function xe() {
|
|
2258
2265
|
const e = document.getElementById(a.SEARCH__SEARCH_MODAL);
|
|
2259
2266
|
if (!e)
|
|
2260
2267
|
throw new Error("closSearchModal: searchModal not found");
|
|
@@ -2267,8 +2274,8 @@ function He() {
|
|
|
2267
2274
|
throw new Error("closSearchModal: searchIcon not found");
|
|
2268
2275
|
t.focus();
|
|
2269
2276
|
}
|
|
2270
|
-
function
|
|
2271
|
-
const e =
|
|
2277
|
+
function Ke() {
|
|
2278
|
+
const e = I(vr), t = (
|
|
2272
2279
|
/** @type {HTMLElement} */
|
|
2273
2280
|
e.querySelector(p(a.SEARCH__SEARCH_BACKDROP))
|
|
2274
2281
|
);
|
|
@@ -2299,21 +2306,21 @@ function Ye() {
|
|
|
2299
2306
|
if (!i)
|
|
2300
2307
|
throw new Error("showSearchModal: searchInput not found");
|
|
2301
2308
|
o.onclick = (s) => {
|
|
2302
|
-
s.preventDefault(), s.stopPropagation(),
|
|
2303
|
-
const { onSearch: l } =
|
|
2309
|
+
s.preventDefault(), s.stopPropagation(), xe();
|
|
2310
|
+
const { onSearch: l } = L();
|
|
2304
2311
|
l && (l == null || l(i.value));
|
|
2305
2312
|
}, n.onclick = (s) => {
|
|
2306
|
-
s.preventDefault(), s.stopPropagation(),
|
|
2313
|
+
s.preventDefault(), s.stopPropagation(), xe();
|
|
2307
2314
|
}, t.onclick = (s) => {
|
|
2308
|
-
s.preventDefault(), s.stopPropagation(),
|
|
2315
|
+
s.preventDefault(), s.stopPropagation(), xe();
|
|
2309
2316
|
}, document.body.appendChild(e), i.focus(), i.oninput = () => {
|
|
2310
2317
|
r.classList.remove(a.VISUALLY_HIDDEN);
|
|
2311
2318
|
}, o.onfocus = () => {
|
|
2312
2319
|
r.classList.remove(a.VISUALLY_HIDDEN);
|
|
2313
2320
|
}, e.onkeyup = (s) => {
|
|
2314
|
-
(s.code === "Escape" || s.key === "Escape") && (s.preventDefault(), s.stopPropagation(),
|
|
2321
|
+
(s.code === "Escape" || s.key === "Escape") && (s.preventDefault(), s.stopPropagation(), xe());
|
|
2315
2322
|
}, n.addEventListener("focusout", (s) => {
|
|
2316
|
-
s.preventDefault(), s.stopPropagation(), be[
|
|
2323
|
+
s.preventDefault(), s.stopPropagation(), be[et.SHIFT] ? o.focus() : i.focus();
|
|
2317
2324
|
});
|
|
2318
2325
|
const u = e.querySelector(".search-modal__hidden-last-focusable");
|
|
2319
2326
|
if (!u)
|
|
@@ -2322,9 +2329,9 @@ function Ye() {
|
|
|
2322
2329
|
s.preventDefault(), s.stopPropagation(), n.focus();
|
|
2323
2330
|
});
|
|
2324
2331
|
}
|
|
2325
|
-
function
|
|
2332
|
+
function br() {
|
|
2326
2333
|
var s;
|
|
2327
|
-
const e =
|
|
2334
|
+
const e = L(), t = I(Er);
|
|
2328
2335
|
let n = t.querySelector(p(a.MAIN_MENU__NAV));
|
|
2329
2336
|
if (!n)
|
|
2330
2337
|
throw new Error("renderMainMenu(): mainMenu not created");
|
|
@@ -2337,19 +2344,19 @@ function mr() {
|
|
|
2337
2344
|
if (!l)
|
|
2338
2345
|
throw new Error("renderMainMenu(): mainMenuTop not found");
|
|
2339
2346
|
e.mainMenu.menuItems.forEach((c) => {
|
|
2340
|
-
var
|
|
2341
|
-
const d =
|
|
2347
|
+
var b, g;
|
|
2348
|
+
const d = I(mr);
|
|
2342
2349
|
l.appendChild(d);
|
|
2343
|
-
const m =
|
|
2350
|
+
const m = O(
|
|
2344
2351
|
d.querySelector(p(a.MENU_ITEM__TITLE)),
|
|
2345
2352
|
`renderMainMenu(): sub menu title not found for ${c.title}`
|
|
2346
|
-
), f =
|
|
2353
|
+
), f = O(
|
|
2347
2354
|
/** @type {HTMLElement} */
|
|
2348
2355
|
m.querySelector(p(a.MENU_ITEM__BUTTON_TITLE)),
|
|
2349
2356
|
`renderMainMenu(): button title not found for ${c.title}`
|
|
2350
2357
|
);
|
|
2351
2358
|
f.setAttribute("id", `${a.MENU_ITEM__BUTTON_TITLE}__${c.title}-${U()}`);
|
|
2352
|
-
const h =
|
|
2359
|
+
const h = O(
|
|
2353
2360
|
/** @type {HTMLElement} */
|
|
2354
2361
|
m.querySelector(p(a.MENU_ITEM__LINK_TITLE)),
|
|
2355
2362
|
`renderMainMenu(): link title not found for ${c.title}`
|
|
@@ -2362,83 +2369,91 @@ function mr() {
|
|
|
2362
2369
|
_ = f, h.remove();
|
|
2363
2370
|
else
|
|
2364
2371
|
throw new Error(`renderMainMenu(): menuItem is missing an action: ${c.title}`);
|
|
2365
|
-
|
|
2366
|
-
_.
|
|
2367
|
-
|
|
2372
|
+
const E = O(
|
|
2373
|
+
_.querySelector(p(a.MENU_ITEM__LINK_TITLE_SPAN)),
|
|
2374
|
+
`renderMainMenu(): main menu item title span not found for: ${c.title}`
|
|
2375
|
+
);
|
|
2376
|
+
if ((c.isSelected || c.actionMenu && ke(c.actionMenu, ["actionMenu"], (M) => !!M.isSelected)) && _.classList.add(a.MENU_ITEM__SELECTED), c.actionMenu) {
|
|
2377
|
+
E.innerHTML = c.title;
|
|
2378
|
+
const M = {
|
|
2368
2379
|
menuItems: c.actionMenu,
|
|
2369
2380
|
title: c.title
|
|
2370
|
-
},
|
|
2371
|
-
|
|
2381
|
+
}, w = ft(
|
|
2382
|
+
M,
|
|
2372
2383
|
_,
|
|
2373
2384
|
{
|
|
2374
|
-
childrenMenuType: c.childrenMenuType ||
|
|
2385
|
+
childrenMenuType: c.childrenMenuType || Y.FLYOUT
|
|
2375
2386
|
}
|
|
2376
2387
|
);
|
|
2377
|
-
d.appendChild(
|
|
2378
|
-
let
|
|
2388
|
+
d.appendChild(w), ye(d, _, w, "menu", { shouldFocusOnHover: !0 });
|
|
2389
|
+
let v;
|
|
2379
2390
|
switch (c.childrenMenuType) {
|
|
2380
|
-
case
|
|
2381
|
-
|
|
2391
|
+
case Y.INLINE:
|
|
2392
|
+
v = a.MENU_ITEM__INLINE;
|
|
2382
2393
|
break;
|
|
2383
|
-
case
|
|
2384
|
-
|
|
2394
|
+
case Y.MEGA_MENU:
|
|
2395
|
+
v = a.MENU_ITEM__MEGA_MENU;
|
|
2385
2396
|
break;
|
|
2386
|
-
case
|
|
2397
|
+
case Y.FLYOUT:
|
|
2387
2398
|
default:
|
|
2388
|
-
|
|
2399
|
+
v = a.MENU_ITEM__FLY_OUT;
|
|
2389
2400
|
break;
|
|
2390
2401
|
}
|
|
2391
|
-
d.classList.add(
|
|
2392
|
-
}
|
|
2393
|
-
|
|
2394
|
-
|
|
2395
|
-
|
|
2396
|
-
|
|
2402
|
+
d.classList.add(v);
|
|
2403
|
+
} else
|
|
2404
|
+
O(
|
|
2405
|
+
_.querySelector(p(a.MENU_ITEM__ARROW)),
|
|
2406
|
+
`renderMainMenu(): menu arrow not found for ${c.title}`
|
|
2407
|
+
).remove();
|
|
2408
|
+
c.actionFunction ? (E.innerHTML = c.title, _.onclick = c.actionFunction) : c.actionFunctionUrl ? (E.innerHTML = c.title, _.setAttribute("href", c.actionFunctionUrl.url), _.onclick = (M) => {
|
|
2409
|
+
var w, v;
|
|
2410
|
+
(w = c.actionFunctionUrl) != null && w.skipHandleEvent || (M.stopPropagation(), M.preventDefault()), (v = c.actionFunctionUrl) == null || v.actionFunction(M);
|
|
2411
|
+
}) : c.actionUrl && (E.innerHTML = c.title, _.setAttribute("href", c.actionUrl.url)), ((b = c.actionUrl) != null && b.openInNewTab || (g = c.actionFunctionUrl) != null && g.openInNewTab) && (_.setAttribute("target", "_blank"), _.appendChild(I(Gt)));
|
|
2397
2412
|
});
|
|
2398
2413
|
}
|
|
2399
2414
|
let i = null;
|
|
2400
2415
|
if (e.utahId) {
|
|
2401
|
-
const { button: l, menu: c } =
|
|
2402
|
-
i = c,
|
|
2416
|
+
const { button: l, menu: c } = ar();
|
|
2417
|
+
i = c, O(
|
|
2403
2418
|
t.querySelector(p(a.MOBILE__UTAH_ID)),
|
|
2404
2419
|
"renderMainMenu: utahIdButtonWrapper not found"
|
|
2405
2420
|
).appendChild(l);
|
|
2406
2421
|
}
|
|
2407
|
-
const u =
|
|
2422
|
+
const u = O(
|
|
2408
2423
|
/** @type {HTMLElement} */
|
|
2409
2424
|
t.querySelector(p(a.MAIN_MENU__SEARCH)),
|
|
2410
2425
|
"renderMainMenu: searchIcon not found"
|
|
2411
2426
|
);
|
|
2412
2427
|
if (e.onSearch) {
|
|
2413
|
-
if (
|
|
2428
|
+
if (Ae(u, document.createTextNode("Search")), u.onclick)
|
|
2414
2429
|
throw new Error("searchIcon already has onclick");
|
|
2415
|
-
if (u.onclick = () =>
|
|
2416
|
-
const l =
|
|
2430
|
+
if (u.onclick = () => Ke(), !e.mainMenu) {
|
|
2431
|
+
const l = O(
|
|
2417
2432
|
document.querySelector(p(a.CITIZEN_EXPERIENCE)),
|
|
2418
2433
|
"renderMainMenu: citizen experience wrapper not found"
|
|
2419
|
-
), c =
|
|
2420
|
-
if (
|
|
2421
|
-
const d =
|
|
2434
|
+
), c = I(u.outerHTML);
|
|
2435
|
+
if (Ae(c, document.createTextNode("Search")), c.onclick = () => Ke(), u.classList.add(a.DESKTOP__HIDDEN), e.utahId !== !1) {
|
|
2436
|
+
const d = O(document.querySelector(p(a.UTAH_ID)), "renderMainMenu: utahId wrapper not found");
|
|
2422
2437
|
l.insertBefore(c, d);
|
|
2423
2438
|
} else
|
|
2424
2439
|
l.appendChild(c);
|
|
2425
2440
|
}
|
|
2426
2441
|
if (!e.mainMenu && !e.actionItems && e.utahId === !1) {
|
|
2427
|
-
const l =
|
|
2442
|
+
const l = I(
|
|
2428
2443
|
/** @type {HTMLElement} */
|
|
2429
2444
|
u.outerHTML
|
|
2430
2445
|
);
|
|
2431
|
-
if (
|
|
2446
|
+
if (Ae(l, document.createTextNode("Search")), l.onclick)
|
|
2432
2447
|
throw new Error("searchIconMobile already has onclick");
|
|
2433
|
-
l.onclick = () =>
|
|
2448
|
+
l.onclick = () => Ke(), O(
|
|
2434
2449
|
document.querySelector(p(a.CITIZEN_EXPERIENCE_MOBILE)),
|
|
2435
2450
|
"renderMainMenu: citizen-experience--mobile not found"
|
|
2436
2451
|
).appendChild(l);
|
|
2437
2452
|
}
|
|
2438
2453
|
}
|
|
2439
|
-
return e.onSearch || ((e.mainMenu || !e.mainMenu && e.utahId) && ((s = u.parentElement) == null || s.insertBefore(
|
|
2454
|
+
return e.onSearch || ((e.mainMenu || !e.mainMenu && e.utahId) && ((s = u.parentElement) == null || s.insertBefore(I('<div class="main-menu__search-placeholder">'), u)), u.remove()), { mainMenuWrapper: t, utahIdPopup: i };
|
|
2440
2455
|
}
|
|
2441
|
-
const
|
|
2456
|
+
const Ir = `<div class="utah-design-system utds-official-website-popup__wrapper visually-hidden" tabindex="-1">
|
|
2442
2457
|
<h2 class="utds-official-website-popup__heading">
|
|
2443
2458
|
This is an official website of the State of Utah. Here’s how you know:
|
|
2444
2459
|
</h2>
|
|
@@ -2480,17 +2495,17 @@ const Er = `<div class="utah-design-system utds-official-website-popup__wrapper
|
|
|
2480
2495
|
</button>
|
|
2481
2496
|
</div>
|
|
2482
2497
|
`;
|
|
2483
|
-
function
|
|
2484
|
-
const e =
|
|
2498
|
+
function cn() {
|
|
2499
|
+
const e = O(
|
|
2485
2500
|
document.querySelector(p(a.LOGO_OFFICIAL_WRAPPER)),
|
|
2486
2501
|
"openOfficialWebsite: official wrapper not found"
|
|
2487
|
-
), t =
|
|
2502
|
+
), t = O(
|
|
2488
2503
|
document.querySelector(p(a.LOGO)),
|
|
2489
2504
|
"openOfficialWebsite: logoWrapper not found"
|
|
2490
|
-
), n =
|
|
2505
|
+
), n = O(
|
|
2491
2506
|
t.querySelector(p(a.LOGO_SVG)),
|
|
2492
2507
|
"openOfficialWebsite: logoButton not found"
|
|
2493
|
-
), o =
|
|
2508
|
+
), o = O(
|
|
2494
2509
|
e.querySelector(p(a.LOGO_OFFICIAL_CLOSE_BUTTON)),
|
|
2495
2510
|
"openOfficialWebsite: official close button not found"
|
|
2496
2511
|
);
|
|
@@ -2500,17 +2515,17 @@ function an() {
|
|
|
2500
2515
|
i.classList.add(a.TOOLTIP__WRAPPER__HIDDEN), i.classList.remove(a.TOOLTIP__WRAPPER__VISIBLE);
|
|
2501
2516
|
});
|
|
2502
2517
|
}
|
|
2503
|
-
function
|
|
2504
|
-
const e =
|
|
2518
|
+
function Tr() {
|
|
2519
|
+
const e = O(
|
|
2505
2520
|
document.querySelector(p(a.LOGO_OFFICIAL_WRAPPER)),
|
|
2506
2521
|
"openOfficialWebsite: official wrapper not found"
|
|
2507
|
-
), t =
|
|
2522
|
+
), t = O(
|
|
2508
2523
|
document.querySelector(p(a.LOGO)),
|
|
2509
2524
|
"openOfficialWebsite: logoWrapper not found"
|
|
2510
|
-
), n =
|
|
2525
|
+
), n = O(
|
|
2511
2526
|
t.querySelector(p(a.LOGO_SVG)),
|
|
2512
2527
|
"openOfficialWebsite: logoButton not found"
|
|
2513
|
-
), o =
|
|
2528
|
+
), o = O(
|
|
2514
2529
|
e.querySelector(p(a.LOGO_OFFICIAL_CLOSE_BUTTON)),
|
|
2515
2530
|
"openOfficialWebsite: official close button not found"
|
|
2516
2531
|
);
|
|
@@ -2518,10 +2533,10 @@ function vr() {
|
|
|
2518
2533
|
const r = document.querySelectorAll(p(a.TOOLTIP__WRAPPER));
|
|
2519
2534
|
r == null || r.forEach((i) => {
|
|
2520
2535
|
i.classList.add(a.TOOLTIP__WRAPPER__HIDDEN), i.classList.remove(a.TOOLTIP__WRAPPER__VISIBLE);
|
|
2521
|
-
}),
|
|
2536
|
+
}), qe();
|
|
2522
2537
|
}
|
|
2523
|
-
function
|
|
2524
|
-
const e =
|
|
2538
|
+
function gr() {
|
|
2539
|
+
const e = I(Ir), n = (
|
|
2525
2540
|
/** @type {HTMLElement} */
|
|
2526
2541
|
document.querySelector(p(a.LOGO)).querySelector(p(a.LOGO_SVG))
|
|
2527
2542
|
);
|
|
@@ -2533,7 +2548,7 @@ function br() {
|
|
|
2533
2548
|
if (!o)
|
|
2534
2549
|
throw new Error("renderOfficialWebsite: closeButton not found");
|
|
2535
2550
|
return n.onclick = () => {
|
|
2536
|
-
e.classList.toggle(a.VISUALLY_HIDDEN), e.classList.contains(a.VISUALLY_HIDDEN) ?
|
|
2551
|
+
e.classList.toggle(a.VISUALLY_HIDDEN), e.classList.contains(a.VISUALLY_HIDDEN) ? cn() : Tr();
|
|
2537
2552
|
const r = document.querySelectorAll(p(a.TOOLTIP__WRAPPER));
|
|
2538
2553
|
r == null || r.forEach((i) => {
|
|
2539
2554
|
i.classList.add(a.TOOLTIP__WRAPPER__HIDDEN), i.classList.remove(a.TOOLTIP__WRAPPER__VISIBLE);
|
|
@@ -2542,23 +2557,23 @@ function br() {
|
|
|
2542
2557
|
e.classList.toggle(a.VISUALLY_HIDDEN), n.focus(), n.setAttribute("aria-expanded", "false"), e.setAttribute("aria-hidden", "true");
|
|
2543
2558
|
}, o.id || (o.id = U()), e.id || (e.id = U()), n.setAttribute("aria-controls", e.id), n.setAttribute("aria-expanded", "false"), e.setAttribute("aria-hidden", "true"), e.setAttribute("aria-labelledby", n.id), e;
|
|
2544
2559
|
}
|
|
2545
|
-
function
|
|
2560
|
+
function Mr(e) {
|
|
2546
2561
|
var l, c;
|
|
2547
|
-
const { hamburger: t } =
|
|
2562
|
+
const { hamburger: t } = we("hookupHamburger"), n = L();
|
|
2548
2563
|
if ((l = n.actionItems) == null ? void 0 : l.some((d) => !!d.badge)) {
|
|
2549
|
-
const d =
|
|
2564
|
+
const d = _t({ label: "Home Badge" });
|
|
2550
2565
|
d && t.appendChild(d);
|
|
2551
2566
|
}
|
|
2552
|
-
|
|
2567
|
+
qe();
|
|
2553
2568
|
function r() {
|
|
2554
|
-
const d =
|
|
2569
|
+
const d = O(
|
|
2555
2570
|
/** @type {HTMLElement} */
|
|
2556
2571
|
document.querySelectorAll(`.${a.MOBILE_MENU__ACTION_BAR} .${a.MOBILE_MENU_ACTION_BAR__ACTION_ITEM_WRAPPER}`)[0],
|
|
2557
2572
|
"hookupHamburger: no action items to select on mobile hamburger open"
|
|
2558
2573
|
), m = d.querySelector("button"), f = m == null ? void 0 : m.getAttribute("aria-controls");
|
|
2559
2574
|
return { actionItem: d, actionItemWrapper: f ? document.getElementById(f) : null };
|
|
2560
2575
|
}
|
|
2561
|
-
const i =
|
|
2576
|
+
const i = O(
|
|
2562
2577
|
/** @type {HTMLElement} */
|
|
2563
2578
|
document.querySelectorAll(`.${a.MOBILE_MENU__ACTION_BAR} .${a.MOBILE_MENU_ACTION_BAR__ACTION_ITEM_WRAPPER}`)[0],
|
|
2564
2579
|
"hookupHamburger: no action items to select on mobile hamburger open"
|
|
@@ -2571,17 +2586,17 @@ function Ir(e) {
|
|
|
2571
2586
|
throw new Error("mobileMenuInteractionHandler: mobileMainMenuContentItemId not found");
|
|
2572
2587
|
(u || i).setAttribute("aria-controls", d), e.setAttribute("aria-labelledby", s);
|
|
2573
2588
|
}
|
|
2574
|
-
|
|
2589
|
+
ot(
|
|
2575
2590
|
t,
|
|
2576
2591
|
() => r().actionItemWrapper,
|
|
2577
2592
|
() => r().actionItem,
|
|
2578
2593
|
{
|
|
2579
|
-
additionalOnClick: () =>
|
|
2594
|
+
additionalOnClick: () => cn(),
|
|
2580
2595
|
ariaHasPopupType: "menu",
|
|
2581
2596
|
shouldOnClickCloseMenu: !0
|
|
2582
2597
|
}
|
|
2583
2598
|
), X(!!t.onblur, "hookupHamburger: hamburger already has an onblur event"), t.onblur = () => {
|
|
2584
|
-
const { mobileMenu: d } =
|
|
2599
|
+
const { mobileMenu: d } = we("showMobileMenu");
|
|
2585
2600
|
if (d.classList.contains(a.IS_OPEN)) {
|
|
2586
2601
|
const m = p(a.MOBILE_MENU__ACTION_BAR), f = p(a.MOBILE_MENU_ACTION_BAR__ACTION_ITEM_WRAPPER), h = p(a.ICON_BUTTON), _ = (
|
|
2587
2602
|
/** @type {HTMLElement | null} */
|
|
@@ -2589,89 +2604,107 @@ function Ir(e) {
|
|
|
2589
2604
|
);
|
|
2590
2605
|
_ == null || _.focus();
|
|
2591
2606
|
}
|
|
2592
|
-
}, (n.mainMenu || n.actionItems) && !n.onSearch && n.utahId === !1 && (
|
|
2607
|
+
}, (n.mainMenu || n.actionItems) && !n.onSearch && n.utahId === !1 && (O(
|
|
2593
2608
|
document.querySelector(p(a.CITIZEN_EXPERIENCE_MOBILE)),
|
|
2594
2609
|
"hookupHamburger: citizen experience mobile not found"
|
|
2595
|
-
).appendChild(t),
|
|
2610
|
+
).appendChild(t), O(
|
|
2596
2611
|
document.querySelector(p(a.MAIN_MENU)),
|
|
2597
2612
|
"hookupHamburger: main menu not found"
|
|
2598
|
-
).classList.add(a.MOBILE__HIDDEN)), n.onSearch && !n.mainMenu &&
|
|
2613
|
+
).classList.add(a.MOBILE__HIDDEN)), n.onSearch && !n.mainMenu && O(
|
|
2599
2614
|
document.querySelector(p(a.MAIN_MENU)),
|
|
2600
2615
|
"renderMainMenu: main menu not found"
|
|
2601
2616
|
).classList.add(a.DESKTOP__HIDDEN);
|
|
2602
2617
|
}
|
|
2603
|
-
|
|
2604
|
-
|
|
2605
|
-
|
|
2606
|
-
|
|
2607
|
-
|
|
2608
|
-
|
|
2609
|
-
|
|
2610
|
-
|
|
2611
|
-
|
|
2612
|
-
|
|
2613
|
-
}
|
|
2614
|
-
|
|
2615
|
-
|
|
2616
|
-
|
|
2617
|
-
|
|
2618
|
+
const Ie = {
|
|
2619
|
+
AUTOMATIC: (
|
|
2620
|
+
/** @type {UtahIdFetchStyle} */
|
|
2621
|
+
"Automatic"
|
|
2622
|
+
),
|
|
2623
|
+
NONE: (
|
|
2624
|
+
/** @type {UtahIdFetchStyle} */
|
|
2625
|
+
"None"
|
|
2626
|
+
),
|
|
2627
|
+
PROVIDED: (
|
|
2628
|
+
/** @type {UtahIdFetchStyle} */
|
|
2629
|
+
"Provided"
|
|
2630
|
+
)
|
|
2631
|
+
};
|
|
2632
|
+
let xt = Ie.NONE;
|
|
2633
|
+
function Ar(e) {
|
|
2634
|
+
let t;
|
|
2635
|
+
if (e === !0)
|
|
2636
|
+
t = Ie.AUTOMATIC;
|
|
2637
|
+
else if (e === !1)
|
|
2638
|
+
t = Ie.NONE;
|
|
2639
|
+
else if (e === void 0 || e.currentUser === void 0)
|
|
2640
|
+
t = Ie.AUTOMATIC;
|
|
2641
|
+
else if (e.currentUser === null || e.currentUser)
|
|
2642
|
+
t = Ie.PROVIDED;
|
|
2643
|
+
else
|
|
2644
|
+
throw new Error("determineFetchStyle: Unknown utah id fetch style");
|
|
2645
|
+
return t;
|
|
2618
2646
|
}
|
|
2619
|
-
const
|
|
2647
|
+
const B = {
|
|
2620
2648
|
// null = not yet loaded, false = ajaxing, true = have a result (may be error or user data)
|
|
2621
2649
|
isDefinitive: null,
|
|
2622
2650
|
lastError: null,
|
|
2623
2651
|
userInfo: null
|
|
2624
2652
|
};
|
|
2625
|
-
function
|
|
2626
|
-
var t, n, o;
|
|
2627
|
-
e.isDefinitive && (nn(e), (o = (n = (t = w()) == null ? void 0 : t.utahId) == null ? void 0 : n.onAuthChanged) == null || o.call(n, e));
|
|
2628
|
-
}
|
|
2629
|
-
let xt = !0;
|
|
2630
|
-
const gr = 500;
|
|
2631
|
-
async function sn() {
|
|
2653
|
+
function Wt(e) {
|
|
2632
2654
|
var t, n;
|
|
2633
|
-
|
|
2634
|
-
|
|
2635
|
-
|
|
2636
|
-
|
|
2637
|
-
|
|
2638
|
-
|
|
2655
|
+
if (e.isDefinitive) {
|
|
2656
|
+
an(e);
|
|
2657
|
+
const o = (t = L()) == null ? void 0 : t.utahId;
|
|
2658
|
+
typeof o == "object" && ((n = o.onAuthChanged) == null || n.call(o, e));
|
|
2659
|
+
}
|
|
2660
|
+
}
|
|
2661
|
+
let kt = !0;
|
|
2662
|
+
const wr = 500;
|
|
2663
|
+
let Ft = NaN;
|
|
2664
|
+
async function un() {
|
|
2665
|
+
var o, r;
|
|
2666
|
+
let e = Promise.resolve(B);
|
|
2667
|
+
const t = L(), n = Ar(t.utahId);
|
|
2668
|
+
if (B.isDefinitive === !1)
|
|
2669
|
+
e = Promise.resolve(B);
|
|
2670
|
+
else if (kt)
|
|
2671
|
+
clearTimeout(Ft), e = new Promise((i) => {
|
|
2672
|
+
Ft = window.setTimeout(
|
|
2673
|
+
() => {
|
|
2674
|
+
kt = !1, un().then((u) => i(u)).catch((u) => console.error(u));
|
|
2675
|
+
},
|
|
2676
|
+
wr
|
|
2677
|
+
);
|
|
2678
|
+
});
|
|
2679
|
+
else if (t.utahId === !1)
|
|
2680
|
+
e = Promise.resolve({
|
|
2681
|
+
isDefinitive: !0,
|
|
2682
|
+
lastError: "Utah ID is off",
|
|
2683
|
+
userInfo: null
|
|
2639
2684
|
});
|
|
2685
|
+
else if (t.utahId === !0 || ((o = t.utahId) == null ? void 0 : o.currentUser) === void 0)
|
|
2686
|
+
(n !== xt || B.isDefinitive === null) && (B.isDefinitive = !1, e = fetch(Pe.USER_INFO, { credentials: "include" }).then((i) => i.json()).then((i) => {
|
|
2687
|
+
if (i.status === 200)
|
|
2688
|
+
B.lastError = null, B.userInfo = /** @type {UserInfo} */
|
|
2689
|
+
i.data;
|
|
2690
|
+
else
|
|
2691
|
+
throw new Error(i.err);
|
|
2692
|
+
return B;
|
|
2693
|
+
}).catch((i) => (B.lastError = i, B.userInfo = null, B)).finally(() => (B.isDefinitive = !0, Wt(B), B)));
|
|
2640
2694
|
else {
|
|
2641
|
-
const
|
|
2642
|
-
|
|
2643
|
-
|
|
2644
|
-
|
|
2645
|
-
|
|
2646
|
-
|
|
2647
|
-
});
|
|
2648
|
-
else if (o.utahId === !0 || ((t = o.utahId) == null ? void 0 : t.currentUser) === void 0)
|
|
2649
|
-
Y.isDefinitive = !1, e = fetch(ye.USER_INFO, { credentials: "include" }).then((r) => r.json()).then((r) => {
|
|
2650
|
-
if (r.status === 200)
|
|
2651
|
-
Y.lastError = null, Y.userInfo = /** @type UserInfo */
|
|
2652
|
-
r.data;
|
|
2653
|
-
else
|
|
2654
|
-
throw new Error(r.err);
|
|
2655
|
-
}).catch((r) => {
|
|
2656
|
-
Y.lastError = r, Y.userInfo = null;
|
|
2657
|
-
}).finally(() => {
|
|
2658
|
-
Y.isDefinitive = !0, Ht(Y);
|
|
2659
|
-
});
|
|
2660
|
-
else {
|
|
2661
|
-
const r = {
|
|
2662
|
-
isDefinitive: !0,
|
|
2663
|
-
lastError: null,
|
|
2664
|
-
userInfo: (n = o.utahId) == null ? void 0 : n.currentUser
|
|
2665
|
-
};
|
|
2666
|
-
e = Promise.resolve(r), Ht(r);
|
|
2667
|
-
}
|
|
2695
|
+
const i = {
|
|
2696
|
+
isDefinitive: !0,
|
|
2697
|
+
lastError: null,
|
|
2698
|
+
userInfo: (r = t.utahId) == null ? void 0 : r.currentUser
|
|
2699
|
+
};
|
|
2700
|
+
e = Promise.resolve(i), Wt(i);
|
|
2668
2701
|
}
|
|
2669
|
-
return e;
|
|
2702
|
+
return xt = n, e;
|
|
2670
2703
|
}
|
|
2671
|
-
function
|
|
2672
|
-
return
|
|
2704
|
+
function Or() {
|
|
2705
|
+
return B;
|
|
2673
2706
|
}
|
|
2674
|
-
function
|
|
2707
|
+
function Lr() {
|
|
2675
2708
|
const e = document.getElementById(a.MOBILE_MENU_ACTON_BAR__PROFILE_ID);
|
|
2676
2709
|
if (!e)
|
|
2677
2710
|
throw new Error("removeUtahIdInMobileMenu: profileActionItem not found");
|
|
@@ -2683,7 +2716,7 @@ function Ar() {
|
|
|
2683
2716
|
throw new Error("removeUtahIdInMobileMenu: profileActionItemWrapper not found");
|
|
2684
2717
|
t.remove();
|
|
2685
2718
|
}
|
|
2686
|
-
function
|
|
2719
|
+
function yr(e, t) {
|
|
2687
2720
|
const n = document.querySelector(p(a.MOBILE__UTAH_ID));
|
|
2688
2721
|
if (!n)
|
|
2689
2722
|
throw new Error("hookupUtahIdInMobileMenu: utahIdWrapper not found");
|
|
@@ -2704,8 +2737,8 @@ function Or(e, t) {
|
|
|
2704
2737
|
);
|
|
2705
2738
|
if (!u)
|
|
2706
2739
|
throw new Error("hookupHamburger: profileActionItemWrapper not found");
|
|
2707
|
-
const s =
|
|
2708
|
-
|
|
2740
|
+
const s = nt(t);
|
|
2741
|
+
ot(
|
|
2709
2742
|
o,
|
|
2710
2743
|
s,
|
|
2711
2744
|
u,
|
|
@@ -2713,12 +2746,12 @@ function Or(e, t) {
|
|
|
2713
2746
|
ariaHasPopupType: "menu",
|
|
2714
2747
|
onClickHandler: (l) => {
|
|
2715
2748
|
var f;
|
|
2716
|
-
const c =
|
|
2749
|
+
const c = Or(), d = L();
|
|
2717
2750
|
let m = !1;
|
|
2718
2751
|
if (!(c != null && c.isDefinitive) || !((f = c == null ? void 0 : c.userInfo) != null && f.authenticated)) {
|
|
2719
2752
|
m = !0;
|
|
2720
2753
|
const h = d.utahId !== !1 && d.utahId !== !0 && d.utahId.onSignIn;
|
|
2721
|
-
h ? h(l) : (l.preventDefault(), l.stopPropagation(), window.location.href =
|
|
2754
|
+
h ? h(l) : (l.preventDefault(), l.stopPropagation(), window.location.href = Pe.SIGN_IN);
|
|
2722
2755
|
}
|
|
2723
2756
|
return m;
|
|
2724
2757
|
},
|
|
@@ -2726,18 +2759,18 @@ function Or(e, t) {
|
|
|
2726
2759
|
}
|
|
2727
2760
|
);
|
|
2728
2761
|
}
|
|
2729
|
-
function
|
|
2762
|
+
function Pr() {
|
|
2730
2763
|
var t;
|
|
2731
|
-
const e =
|
|
2764
|
+
const e = L();
|
|
2732
2765
|
return he(
|
|
2733
2766
|
e.mainMenu && ((t = e.mainMenu) == null ? void 0 : t.menuItems) || void 0,
|
|
2734
2767
|
{
|
|
2735
|
-
childrenMenuType:
|
|
2768
|
+
childrenMenuType: Y.INLINE,
|
|
2736
2769
|
removePopupArrow: !0
|
|
2737
2770
|
}
|
|
2738
2771
|
);
|
|
2739
2772
|
}
|
|
2740
|
-
function
|
|
2773
|
+
function Nr() {
|
|
2741
2774
|
const t = [...document.querySelectorAll(`
|
|
2742
2775
|
${p(a.MOBILE_MENU__ACTION_BAR)}
|
|
2743
2776
|
${p(a.MOBILE_MENU_ACTION_BAR__ACTION_ITEM_WRAPPER)}
|
|
@@ -2784,26 +2817,26 @@ function Lr() {
|
|
|
2784
2817
|
);
|
|
2785
2818
|
if (!f)
|
|
2786
2819
|
throw new Error("hookupMobileActionItemKeyboarding: mobileMenuWrapper not found");
|
|
2787
|
-
|
|
2820
|
+
Ze(f, c);
|
|
2788
2821
|
}
|
|
2789
2822
|
};
|
|
2790
2823
|
}
|
|
2791
2824
|
);
|
|
2792
|
-
const n =
|
|
2825
|
+
const n = O(
|
|
2793
2826
|
document.querySelector(p(a.MOBILE_MENU__LAST_FOCUSABLE)),
|
|
2794
2827
|
"hookupMobileActionItemKeyboarding: hiddenLastFocusableButton not found"
|
|
2795
|
-
), { hamburger: o } =
|
|
2828
|
+
), { hamburger: o } = we("hookupMobileActionItemKeyboarding");
|
|
2796
2829
|
n.addEventListener("focusin", (r) => {
|
|
2797
2830
|
r.preventDefault(), r.stopPropagation(), o.focus();
|
|
2798
2831
|
});
|
|
2799
2832
|
}
|
|
2800
|
-
function
|
|
2801
|
-
const e =
|
|
2833
|
+
function Sr() {
|
|
2834
|
+
const e = vn.replace(a.MEDIA_SIZE__TABLET_PORTRAIT__PLACEHOLDER, `${L().mediaSizes.tabletPortrait}px`).replace(a.MEDIA_SIZE__TABLET_LANDSCAPE__PLACEHOLDER, `${L().mediaSizes.tabletLandscape}px`).replace(a.MEDIA_SIZE__MOBILE__PLACEHOLDER, `${L().mediaSizes.mobile}px`);
|
|
2802
2835
|
let t = document.getElementById(a.CSS_HEADER_MEDIA_TAG_ID);
|
|
2803
2836
|
t || (t = document.createElement("style"), t.id = a.CSS_HEADER_MEDIA_TAG_ID), t.innerHTML = e, document.body.appendChild(t);
|
|
2804
2837
|
}
|
|
2805
|
-
function
|
|
2806
|
-
const e =
|
|
2838
|
+
function Ur() {
|
|
2839
|
+
const e = L();
|
|
2807
2840
|
let t = document.body;
|
|
2808
2841
|
if (e.domLocationTarget) {
|
|
2809
2842
|
const n = [
|
|
@@ -2824,18 +2857,18 @@ function Pr() {
|
|
|
2824
2857
|
else
|
|
2825
2858
|
throw new Error("loadHeader: domLocationTarget must have at least one field set");
|
|
2826
2859
|
}
|
|
2827
|
-
return
|
|
2860
|
+
return O(t, "loadHeader: domTarget is null (how?!)");
|
|
2828
2861
|
}
|
|
2829
|
-
function
|
|
2862
|
+
function Cr() {
|
|
2830
2863
|
var t;
|
|
2831
2864
|
if (!document.querySelector(p([a.UTAH_DESIGN_SYSTEM, a.HEADER]))) {
|
|
2832
|
-
const n =
|
|
2865
|
+
const n = hr(), o = Ur();
|
|
2833
2866
|
o.insertBefore(n, o.firstChild);
|
|
2834
|
-
const r =
|
|
2867
|
+
const r = gr();
|
|
2835
2868
|
n.after(r);
|
|
2836
|
-
const { mainMenuWrapper: i, utahIdPopup: u } =
|
|
2869
|
+
const { mainMenuWrapper: i, utahIdPopup: u } = br();
|
|
2837
2870
|
i && r.after(i);
|
|
2838
|
-
const s =
|
|
2871
|
+
const s = I(bn);
|
|
2839
2872
|
r.after(s);
|
|
2840
2873
|
const l = (
|
|
2841
2874
|
/** @type {HTMLElement} */
|
|
@@ -2845,43 +2878,43 @@ function Nr() {
|
|
|
2845
2878
|
throw new Error("mobileMenuInteractionHandler: mobileMenuBackdrop not found");
|
|
2846
2879
|
if (l.onclick)
|
|
2847
2880
|
throw new Error("mobileMenuInteractionHandler: mobileMenuBackdrop already has onclick");
|
|
2848
|
-
l.onclick = () =>
|
|
2849
|
-
const c =
|
|
2881
|
+
l.onclick = () => qe();
|
|
2882
|
+
const c = Pr(), d = rn(c, "Main Menu");
|
|
2850
2883
|
d.appendChild(c);
|
|
2851
|
-
const m =
|
|
2852
|
-
|
|
2853
|
-
const f =
|
|
2884
|
+
const m = nt(d);
|
|
2885
|
+
Mr(m), u ? ((t = u.closest("div")) == null || t.removeAttribute("aria-labelledby"), yr(s, u)) : Lr(), $o(), Nr(), Bo(), Sr(), un().catch((h) => console.error(h));
|
|
2886
|
+
const f = L();
|
|
2854
2887
|
(!f.mainMenu && !f.actionItems && f.utahId === !1 && !f.onSearch || !f.mainMenu && !f.actionItems && f.utahId === !1 && f.onSearch || !f.mainMenu && f.actionItems && f.utahId === !1 && !f.onSearch) && (s.classList.add(a.MAIN_MENU__REMOVED), i.remove()), (!f.mainMenu && !f.actionItems && f.utahId && !f.onSearch || !f.mainMenu && f.actionItems && f.utahId && !f.onSearch || !f.mainMenu && f.actionItems && !f.utahId && f.onSearch) && i.classList.add(a.DESKTOP__HIDDEN);
|
|
2855
2888
|
}
|
|
2856
|
-
|
|
2889
|
+
zo();
|
|
2857
2890
|
}
|
|
2858
|
-
function
|
|
2891
|
+
function Rr(e) {
|
|
2859
2892
|
var t, n, o, r;
|
|
2860
|
-
(t = document.querySelector(p([a.UTAH_DESIGN_SYSTEM, a.HEADER]))) == null || t.remove(), (n = document.querySelector(p([a.UTAH_DESIGN_SYSTEM, a.MAIN_MENU__OUTER]))) == null || n.remove(), (o = document.querySelector(p([a.UTAH_DESIGN_SYSTEM, a.MOBILE_MENU]))) == null || o.remove(), (r = document.querySelector(p([a.UTAH_DESIGN_SYSTEM, a.LOGO_OFFICIAL_WRAPPER]))) == null || r.remove(),
|
|
2893
|
+
(t = document.querySelector(p([a.UTAH_DESIGN_SYSTEM, a.HEADER]))) == null || t.remove(), (n = document.querySelector(p([a.UTAH_DESIGN_SYSTEM, a.MAIN_MENU__OUTER]))) == null || n.remove(), (o = document.querySelector(p([a.UTAH_DESIGN_SYSTEM, a.MOBILE_MENU]))) == null || o.remove(), (r = document.querySelector(p([a.UTAH_DESIGN_SYSTEM, a.LOGO_OFFICIAL_WRAPPER]))) == null || r.remove(), nn(), e && setTimeout(() => document.dispatchEvent(new Event($t.HEADER_UNLOADED)), 0);
|
|
2861
2894
|
}
|
|
2862
|
-
function
|
|
2863
|
-
|
|
2895
|
+
function qt() {
|
|
2896
|
+
Rr(!1), Cr();
|
|
2864
2897
|
}
|
|
2865
|
-
let
|
|
2866
|
-
const
|
|
2867
|
-
let
|
|
2868
|
-
const
|
|
2898
|
+
let dn = !1;
|
|
2899
|
+
const Dr = 15e3;
|
|
2900
|
+
let Vt = 0;
|
|
2901
|
+
const Br = setInterval(
|
|
2869
2902
|
() => {
|
|
2870
|
-
|
|
2903
|
+
Vt += 1, Vt >= Dr || dn ? clearInterval(Br) : document.dispatchEvent(new Event($t.HEADER_LOADED));
|
|
2871
2904
|
},
|
|
2872
2905
|
2
|
|
2873
2906
|
);
|
|
2874
|
-
function
|
|
2875
|
-
return
|
|
2907
|
+
function Hr(e) {
|
|
2908
|
+
return je.setSettings(e), dn = !0, document != null && document.body ? qt() : window.addEventListener("load", () => qt()), je.getSettings();
|
|
2876
2909
|
}
|
|
2877
2910
|
export {
|
|
2878
|
-
|
|
2911
|
+
Y as childrenMenuTypes,
|
|
2879
2912
|
Ot as defaultSettings,
|
|
2880
|
-
|
|
2881
|
-
|
|
2882
|
-
|
|
2883
|
-
|
|
2884
|
-
|
|
2885
|
-
|
|
2886
|
-
|
|
2913
|
+
$t as events,
|
|
2914
|
+
L as getUtahHeaderSettings,
|
|
2915
|
+
Cr as loadHeader,
|
|
2916
|
+
Rr as removeHeader,
|
|
2917
|
+
I as renderDOMSingle,
|
|
2918
|
+
Hr as setUtahHeaderSettings,
|
|
2919
|
+
Te as sizes
|
|
2887
2920
|
};
|