@edugis-org/webmapx 0.1.7 → 0.1.9

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.
Files changed (60) hide show
  1. package/dist-lib/{decorate-CWgUV1hU.js → decorate-DnZTfaod.js} +6 -6
  2. package/dist-lib/dist-BIbq3o-p.js +213 -0
  3. package/dist-lib/{dist-Dm6b7XCs.js → dist-CKAaoSoW.js} +2743 -2491
  4. package/dist-lib/{dist-kKlmcBXq.js → dist-CWCNMXMK.js} +1 -1
  5. package/dist-lib/{dist-Ha9LQCut.js → dist-D-5Gmgwo.js} +1 -1
  6. package/dist-lib/{layer-discovery-afWzu5hY.js → layer-discovery-DFP-WHAh.js} +1 -1
  7. package/dist-lib/{leaflet-adapter-D9djjrKv.js → leaflet-adapter-A0rte-c7.js} +1 -1
  8. package/dist-lib/{maplibre-adapter-TFc3e0G9.js → maplibre-adapter-Cy6yX6o7.js} +1 -1
  9. package/dist-lib/ol-tilegrid-Ct4my3IN.js +24 -0
  10. package/dist-lib/openlayers-adapter-B8WtV1tn.js +1462 -0
  11. package/dist-lib/{toast-Cm28o9U6.js → toast-BsoXOdeA.js} +1 -1
  12. package/dist-lib/{webmapx-3d-tool-D4CTD2gB.js → webmapx-3d-tool-CLppA7mK.js} +13 -13
  13. package/dist-lib/{webmapx-base-tool-Dm9NAWLD.js → webmapx-base-tool-DfRa7TlD.js} +1 -1
  14. package/dist-lib/{webmapx-config-edit-tool-BgcSkmmg.js → webmapx-config-edit-tool-BztWspia.js} +21 -21
  15. package/dist-lib/{webmapx-coordinates-tool-GMfztOzE.js → webmapx-coordinates-tool-DnTSkrRG.js} +20 -20
  16. package/dist-lib/{webmapx-core-bundle-BDImi1RE.js → webmapx-core-bundle-CH-5vYXU.js} +607 -1519
  17. package/dist-lib/webmapx-draw-tool-DxQgUF1Q.js +2117 -0
  18. package/dist-lib/{webmapx-geolocation-tool-Rw3-Iad1.js → webmapx-geolocation-tool-DIMh2kIr.js} +26 -25
  19. package/dist-lib/{webmapx-import-layer-tool-DRYviHd5.js → webmapx-import-layer-tool-DMiC1TpU.js} +16 -16
  20. package/dist-lib/{webmapx-info-tool-BJA157cy.js → webmapx-info-tool-D-XbAU9J.js} +56 -56
  21. package/dist-lib/{webmapx-language-osmvector-M5y_lwOg.js → webmapx-language-osmvector-BAw9TR-M.js} +12 -11
  22. package/dist-lib/{webmapx-measure-tool-BXhMJFC6.js → webmapx-measure-tool-CXlg11s8.js} +34 -34
  23. package/dist-lib/{webmapx-modal-tool-eF6Naluv.js → webmapx-modal-tool-Cs7LRrgW.js} +3 -3
  24. package/dist-lib/{webmapx-plugin-tool-D2Hghf9n.js → webmapx-plugin-tool-qe2yTrWB.js} +7 -7
  25. package/dist-lib/{webmapx-print-tool-ob1bOsR5.js → webmapx-print-tool-DrK9sLC7.js} +27 -26
  26. package/dist-lib/{webmapx-search-tool-Cv8BrYvY.js → webmapx-search-tool-H7NisgWH.js} +11 -11
  27. package/dist-lib/webmapx-settings-EHSm-AGU.js +167 -0
  28. package/dist-lib/{webmapx-truearea-tool-CMB4Orm-.js → webmapx-truearea-tool-CSU9mE1D.js} +26 -26
  29. package/dist-lib/{webmapx-view-mode-tool-CUpLNjOj.js → webmapx-view-mode-tool-D1QyQfq8.js} +9 -9
  30. package/dist-lib/webmapx.css +1 -1
  31. package/dist-lib/webmapx.js +42 -41
  32. package/package.json +1 -1
  33. package/dist-lib/WMTS-DCN4zX0-.js +0 -1169
  34. package/dist-lib/alert-GeHlqlN8.js +0 -310
  35. package/dist-lib/button-DFdGkRPQ.js +0 -741
  36. package/dist-lib/checkbox-QoR4S8tV.js +0 -284
  37. package/dist-lib/chunk.36O46B5H-B6ZL7Sm1.js +0 -77
  38. package/dist-lib/chunk.3RPBFEDE-BFO1fHVm.js +0 -138
  39. package/dist-lib/chunk.5JY5FUCG-DTXsslmx.js +0 -1090
  40. package/dist-lib/chunk.6CTB5ZDJ-DjZrBd6Y.js +0 -99
  41. package/dist-lib/chunk.AJ3ENQ5C-Ci7Gm2b6.js +0 -175
  42. package/dist-lib/chunk.LD4M4QGE-CiCfhE8r.js +0 -8
  43. package/dist-lib/chunk.NYIIDP5N-BikXIStD.js +0 -99
  44. package/dist-lib/chunk.RWUUFNUL-DFztA4uV.js +0 -43
  45. package/dist-lib/chunk.SI4ACBFK-CLb9VfMG.js +0 -61
  46. package/dist-lib/chunk.YHLNUJ7P-D-kanrCf.js +0 -503
  47. package/dist-lib/decorators-B35AgiCU.js +0 -351
  48. package/dist-lib/dist-c1PlDAd1.js +0 -2359
  49. package/dist-lib/divider-CPm675yY.js +0 -41
  50. package/dist-lib/icon-CEOgWlro.js +0 -9
  51. package/dist-lib/icon-button-Da_nBTy3.js +0 -408
  52. package/dist-lib/input-CeGntPlT.js +0 -590
  53. package/dist-lib/ol-tilegrid-9VtyxaLG.js +0 -64
  54. package/dist-lib/openlayers-adapter-DVW1KCRv.js +0 -13307
  55. package/dist-lib/option-CBxl1mZP.js +0 -1106
  56. package/dist-lib/rbush-C8k41T4z.js +0 -254
  57. package/dist-lib/spinner-DysxdNG9.js +0 -6
  58. package/dist-lib/tooltip-Cucn1SiD.js +0 -197
  59. package/dist-lib/webmapx-draw-tool-DooAV8cF.js +0 -4336
  60. package/dist-lib/webmapx-settings-DDEJ8aoV.js +0 -479
@@ -1,31 +1,28 @@
1
1
  import { a as e, t } from "./chunk-HEgqtunE.js";
2
- import { a as n, i as r, o as i, r as a, t as o } from "./decorate-CWgUV1hU.js";
3
- import { t as s } from "./webmapx-base-tool-Dm9NAWLD.js";
4
- import { a as c, i as l, n as u, o as d, r as f, t as p } from "./decorators-B35AgiCU.js";
5
- import "./webmapx-plugin-tool-D2Hghf9n.js";
6
- import { i as m, o as h, r as g, s as _, t as v } from "./chunk.AJ3ENQ5C-Ci7Gm2b6.js";
7
- import { d as y, f as b, l as x, t as S, u as C } from "./chunk.YHLNUJ7P-D-kanrCf.js";
8
- import { a as ee, n as w, t as te } from "./chunk.NYIIDP5N-BikXIStD.js";
9
- import { t as ne } from "./chunk.6CTB5ZDJ-DjZrBd6Y.js";
10
- import "./icon-CEOgWlro.js";
11
- import { t as re } from "./chunk.36O46B5H-B6ZL7Sm1.js";
12
- import { t as ie } from "./chunk.3RPBFEDE-BFO1fHVm.js";
13
- import "./button-DFdGkRPQ.js";
14
- import { t as ae } from "./checkbox-QoR4S8tV.js";
15
- import { n as oe, r as se } from "./input-CeGntPlT.js";
16
- import { t as ce } from "./chunk.SI4ACBFK-CLb9VfMG.js";
17
- import { t as le } from "./tooltip-Cucn1SiD.js";
18
- import "./spinner-DysxdNG9.js";
19
- import { n as ue } from "./chunk.5JY5FUCG-DTXsslmx.js";
20
- import "./icon-button-Da_nBTy3.js";
21
- import { n as T, r as de } from "./attribution-format-B4f05_u0.js";
22
- import { a as fe, i as pe, t as me } from "./zip.js-DVhmtjxZ.js";
23
- import { i as he } from "./geo-calculations-DbFJAUoI.js";
24
- import { t as ge } from "./throttle-BeneRNYK.js";
25
- import "./webmapx-modal-tool-eF6Naluv.js";
26
- import { LitElement as E, css as D, html as O, nothing as k, svg as A } from "lit";
2
+ import { a as n, i as r, o as i, r as a, t as o } from "./decorate-DnZTfaod.js";
3
+ import { t as s } from "./webmapx-base-tool-DfRa7TlD.js";
4
+ import "./webmapx-plugin-tool-qe2yTrWB.js";
5
+ import { n as c, r as l } from "./attribution-format-B4f05_u0.js";
6
+ import { a as u, i as d, t as f } from "./zip.js-DVhmtjxZ.js";
7
+ import { i as p } from "./geo-calculations-DbFJAUoI.js";
8
+ import { t as m } from "./throttle-BeneRNYK.js";
9
+ import "./webmapx-modal-tool-Cs7LRrgW.js";
10
+ import { LitElement as h, css as g, html as _, nothing as v, svg as y } from "lit";
11
+ import { customElement as b, property as x, query as S, queryAssignedElements as C, state as w } from "lit/decorators.js";
12
+ import "@shoelace-style/shoelace/dist/components/button/button.js";
13
+ import "@shoelace-style/shoelace/dist/components/icon/icon.js";
14
+ import "@shoelace-style/shoelace/dist/components/tree/tree.js";
15
+ import "@shoelace-style/shoelace/dist/components/tree-item/tree-item.js";
16
+ import "@shoelace-style/shoelace/dist/components/checkbox/checkbox.js";
17
+ import "@shoelace-style/shoelace/dist/components/spinner/spinner.js";
18
+ import { unsafeHTML as ee } from "lit-html/directives/unsafe-html.js";
19
+ import "@shoelace-style/shoelace/dist/components/dialog/dialog.js";
20
+ import "@shoelace-style/shoelace/dist/components/input/input.js";
21
+ import "@shoelace-style/shoelace/dist/components/icon-button/icon-button.js";
22
+ import "@shoelace-style/shoelace/dist/components/tooltip/tooltip.js";
23
+ import "@shoelace-style/shoelace/dist/components/range/range.js";
27
24
  //#region src/components/webmapx-layout.ts
28
- var j = class extends E {
25
+ var te = class extends h {
29
26
  constructor(...e) {
30
27
  super(...e), this.slotDirections = {
31
28
  "top-left": "vertical",
@@ -40,7 +37,7 @@ var j = class extends E {
40
37
  };
41
38
  }
42
39
  static {
43
- this.styles = D`
40
+ this.styles = g`
44
41
  :host {
45
42
  position: absolute;
46
43
  inset: 0;
@@ -188,7 +185,7 @@ var j = class extends E {
188
185
  `;
189
186
  }
190
187
  render() {
191
- return O`
188
+ return _`
192
189
  <div class="overlay-surface">
193
190
  <!-- Edge zones first (lowest stacking order) -->
194
191
  <div class="slot-zone slot-zone--edge-bottom-right">
@@ -250,22 +247,22 @@ var j = class extends E {
250
247
  })?.getAttribute("direction") === "horizontal" ? "horizontal" : "vertical";
251
248
  }
252
249
  };
253
- o([l()], j.prototype, "slotDirections", void 0), j = o([d("webmapx-layout")], j);
250
+ o([w()], te.prototype, "slotDirections", void 0), te = o([b("webmapx-layout")], te);
254
251
  //#endregion
255
252
  //#region src/components/internal/tool-selection-scope.ts
256
- function _e(e, t) {
253
+ function T(e, t) {
257
254
  return !!(t && e.includes(t));
258
255
  }
259
- function M(e, t) {
256
+ function ne(e, t) {
260
257
  return !!(e.sourceToolbar && t && e.sourceToolbar !== t);
261
258
  }
262
- function ve(e) {
259
+ function re(e) {
263
260
  let { toolIds: t, currentActiveToolId: n, detail: r, ownToolbar: i } = e;
264
- if (!M(r, i)) return r.toolId ? _e(t, r.toolId) ? r.toolId : void 0 : r.previousToolId ? _e(t, r.previousToolId) ? null : void 0 : r.toolId === null ? null : void 0;
261
+ if (!ne(r, i)) return r.toolId ? T(t, r.toolId) ? r.toolId : void 0 : r.previousToolId ? T(t, r.previousToolId) ? null : void 0 : r.toolId === null ? null : void 0;
265
262
  }
266
263
  //#endregion
267
264
  //#region src/components/webmapx-toolbar.ts
268
- var ye = class extends E {
265
+ var ie = class extends h {
269
266
  constructor(...e) {
270
267
  super(...e), this.orientation = "vertical", this.toolManager = null, this.toolPanel = null, this.boundHandleToolActivated = (e) => this.handleToolActivated(e), this.boundHandleToolDeactivated = (e) => this.handleToolDeactivated(e), this.boundHandleToolSelect = (e) => this.handleToolSelect(e), this.boundHandlePanelClose = (e) => this.handlePanelClose(e), this.handleArrowKeys = (e) => {
271
268
  let t = this.focusableButtons();
@@ -283,7 +280,7 @@ var ye = class extends E {
283
280
  }, this.boundHandleClick = (e) => this.handleButtonClick(e);
284
281
  }
285
282
  static {
286
- this.styles = D`
283
+ this.styles = g`
287
284
  :host {
288
285
  display: flex;
289
286
  flex-direction: column;
@@ -408,7 +405,7 @@ var ye = class extends E {
408
405
  this.hasButtonForTool(t) && this.clearActiveButtons();
409
406
  }
410
407
  handleToolSelect(e) {
411
- let t = e.detail ?? {}, n = ve({
408
+ let t = e.detail ?? {}, n = re({
412
409
  toolIds: this.getToolIds(),
413
410
  currentActiveToolId: this.getActiveButtonToolId(),
414
411
  detail: t,
@@ -438,7 +435,7 @@ var ye = class extends E {
438
435
  }), this.applyRovingTabindex();
439
436
  }
440
437
  hasButtonForTool(e) {
441
- return _e(this.getToolIds(), e);
438
+ return T(this.getToolIds(), e);
442
439
  }
443
440
  getToolIds() {
444
441
  return this.buttons.map((e) => e.getAttribute("name") || e.getAttribute("data-tool")).filter((e) => !!e);
@@ -448,20 +445,20 @@ var ye = class extends E {
448
445
  return e?.getAttribute("name") || e?.getAttribute("data-tool") || null;
449
446
  }
450
447
  render() {
451
- return O`
448
+ return _`
452
449
  <slot name="before"></slot>
453
450
  <slot @slotchange=${this.handleSlotChange}></slot>
454
451
  <slot name="after"></slot>
455
452
  `;
456
453
  }
457
454
  };
458
- o([c({
455
+ o([x({
459
456
  type: String,
460
457
  reflect: !0
461
- })], ye.prototype, "orientation", void 0), o([p()], ye.prototype, "buttons", void 0), ye = o([d("webmapx-toolbar")], ye);
458
+ })], ie.prototype, "orientation", void 0), o([C()], ie.prototype, "buttons", void 0), ie = o([b("webmapx-toolbar")], ie);
462
459
  //#endregion
463
460
  //#region src/components/webmapx-tool-panel.ts
464
- var N = class extends E {
461
+ var ae = class extends h {
465
462
  constructor(...e) {
466
463
  super(...e), this.label = "Tools", this.active = !1, this.collapsed = !1, this.defaultLabel = "Tools", this.activeToolId = null, this.toolIndex = /* @__PURE__ */ new Map(), this.mapHost = null, this.boundHandleToolActivated = (e) => this.handleToolActivated(e), this.boundHandleToolDeactivated = (e) => this.handleToolDeactivated(e), this.boundHandleToolSelect = (e) => this.handleToolSelect(e), this.boundHandleKeydown = (e) => this.handleKeydown(e), this.triggerButton = null;
467
464
  }
@@ -540,7 +537,7 @@ var N = class extends E {
540
537
  }
541
538
  handleToolSelect(e) {
542
539
  let t = e.detail ?? {};
543
- if (M(t, this.resolveToolbar())) return;
540
+ if (ne(t, this.resolveToolbar())) return;
544
541
  let n = t.toolId ?? null, r = t.previousToolId ?? null;
545
542
  if (!(n && this.mapHost?.toolManager?.getTool(n))) {
546
543
  if (!n) {
@@ -560,7 +557,7 @@ var N = class extends E {
560
557
  return this.mapHost?.querySelector("webmapx-toolbar") ?? null;
561
558
  }
562
559
  static {
563
- this.styles = D`
560
+ this.styles = g`
564
561
  :host {
565
562
  display: none;
566
563
  box-sizing: border-box;
@@ -650,7 +647,7 @@ var N = class extends E {
650
647
  n && n.focus?.();
651
648
  }
652
649
  render() {
653
- return O`
650
+ return _`
654
651
  <div class="panel-header">
655
652
  <slot name="header"><h3>${this.label}</h3></slot>
656
653
  <sl-button size="small" circle variant="text" @click=${this.toggleCollapsed}>
@@ -667,526 +664,21 @@ var N = class extends E {
667
664
  `;
668
665
  }
669
666
  };
670
- o([c({ type: String })], N.prototype, "label", void 0), o([c({
667
+ o([x({ type: String })], ae.prototype, "label", void 0), o([x({
671
668
  type: Boolean,
672
669
  reflect: !0
673
- })], N.prototype, "active", void 0), o([c({
670
+ })], ae.prototype, "active", void 0), o([x({
674
671
  type: Boolean,
675
672
  reflect: !0
676
- })], N.prototype, "collapsed", void 0), N = o([d("webmapx-tool-panel")], N);
677
- //#endregion
678
- //#region node_modules/@shoelace-style/shoelace/dist/chunks/chunk.BWVSW6TI.js
679
- var be = D`
680
- :host {
681
- display: block;
682
- outline: 0;
683
- z-index: 0;
684
- }
685
-
686
- :host(:focus) {
687
- outline: none;
688
- }
689
-
690
- slot:not([name])::slotted(sl-icon) {
691
- margin-inline-end: var(--sl-spacing-x-small);
692
- }
693
-
694
- .tree-item {
695
- position: relative;
696
- display: flex;
697
- align-items: stretch;
698
- flex-direction: column;
699
- color: var(--sl-color-neutral-700);
700
- cursor: pointer;
701
- user-select: none;
702
- -webkit-user-select: none;
703
- }
704
-
705
- .tree-item__checkbox {
706
- pointer-events: none;
707
- }
708
-
709
- .tree-item__expand-button,
710
- .tree-item__checkbox,
711
- .tree-item__label {
712
- font-family: var(--sl-font-sans);
713
- font-size: var(--sl-font-size-medium);
714
- font-weight: var(--sl-font-weight-normal);
715
- line-height: var(--sl-line-height-dense);
716
- letter-spacing: var(--sl-letter-spacing-normal);
717
- }
718
-
719
- .tree-item__checkbox::part(base) {
720
- display: flex;
721
- align-items: center;
722
- }
723
-
724
- .tree-item__indentation {
725
- display: block;
726
- width: 1em;
727
- flex-shrink: 0;
728
- }
729
-
730
- .tree-item__expand-button {
731
- display: flex;
732
- align-items: center;
733
- justify-content: center;
734
- box-sizing: content-box;
735
- color: var(--sl-color-neutral-500);
736
- padding: var(--sl-spacing-x-small);
737
- width: 1rem;
738
- height: 1rem;
739
- flex-shrink: 0;
740
- cursor: pointer;
741
- }
742
-
743
- .tree-item__expand-button {
744
- transition: var(--sl-transition-medium) rotate ease;
745
- }
746
-
747
- .tree-item--expanded .tree-item__expand-button {
748
- rotate: 90deg;
749
- }
750
-
751
- .tree-item--expanded.tree-item--rtl .tree-item__expand-button {
752
- rotate: -90deg;
753
- }
754
-
755
- .tree-item--expanded slot[name='expand-icon'],
756
- .tree-item:not(.tree-item--expanded) slot[name='collapse-icon'] {
757
- display: none;
758
- }
759
-
760
- .tree-item:not(.tree-item--has-expand-button) .tree-item__expand-icon-slot {
761
- display: none;
762
- }
763
-
764
- .tree-item__expand-button--visible {
765
- cursor: pointer;
766
- }
767
-
768
- .tree-item__item {
769
- display: flex;
770
- align-items: center;
771
- border-inline-start: solid 3px transparent;
772
- }
773
-
774
- .tree-item--disabled .tree-item__item {
775
- opacity: 0.5;
776
- outline: none;
777
- cursor: not-allowed;
778
- }
779
-
780
- :host(:focus-visible) .tree-item__item {
781
- outline: var(--sl-focus-ring);
782
- outline-offset: var(--sl-focus-ring-offset);
783
- z-index: 2;
784
- }
785
-
786
- :host(:not([aria-disabled='true'])) .tree-item--selected .tree-item__item {
787
- background-color: var(--sl-color-neutral-100);
788
- border-inline-start-color: var(--sl-color-primary-600);
789
- }
790
-
791
- :host(:not([aria-disabled='true'])) .tree-item__expand-button {
792
- color: var(--sl-color-neutral-600);
793
- }
794
-
795
- .tree-item__label {
796
- display: flex;
797
- align-items: center;
798
- transition: var(--sl-transition-fast) color;
799
- }
800
-
801
- .tree-item__children {
802
- display: block;
803
- font-size: calc(1em + var(--indent-size, var(--sl-spacing-medium)));
804
- }
805
-
806
- /* Indentation lines */
807
- .tree-item__children {
808
- position: relative;
809
- }
810
-
811
- .tree-item__children::before {
812
- content: '';
813
- position: absolute;
814
- top: var(--indent-guide-offset);
815
- bottom: var(--indent-guide-offset);
816
- left: calc(1em - (var(--indent-guide-width) / 2) - 1px);
817
- border-inline-end: var(--indent-guide-width) var(--indent-guide-style) var(--indent-guide-color);
818
- z-index: 1;
819
- }
820
-
821
- .tree-item--rtl .tree-item__children::before {
822
- left: auto;
823
- right: 1em;
824
- }
825
-
826
- @media (forced-colors: active) {
827
- :host(:not([aria-disabled='true'])) .tree-item--selected .tree-item__item {
828
- outline: dashed 1px SelectedItem;
829
- }
830
- }
831
- `;
832
- //#endregion
833
- //#region node_modules/lit-html/directives/when.js
834
- function xe(e, t, n) {
835
- return e ? t(e) : n?.(e);
836
- }
837
- //#endregion
838
- //#region node_modules/@shoelace-style/shoelace/dist/chunks/chunk.P4TU54CC.js
839
- var P = class e extends x {
840
- constructor() {
841
- super(...arguments), this.localize = new ne(this), this.indeterminate = !1, this.isLeaf = !1, this.loading = !1, this.selectable = !1, this.expanded = !1, this.selected = !1, this.disabled = !1, this.lazy = !1;
842
- }
843
- static isTreeItem(e) {
844
- return e instanceof Element && e.getAttribute("role") === "treeitem";
845
- }
846
- connectedCallback() {
847
- super.connectedCallback(), this.setAttribute("role", "treeitem"), this.setAttribute("tabindex", "-1"), this.isNestedItem() && (this.slot = "children");
848
- }
849
- firstUpdated() {
850
- this.childrenContainer.hidden = !this.expanded, this.childrenContainer.style.height = this.expanded ? "auto" : "0", this.isLeaf = !this.lazy && this.getChildrenItems().length === 0, this.handleExpandedChange();
851
- }
852
- async animateCollapse() {
853
- this.emit("sl-collapse"), await m(this.childrenContainer);
854
- let { keyframes: e, options: t } = h(this, "tree-item.collapse", { dir: this.localize.dir() });
855
- await v(this.childrenContainer, g(e, this.childrenContainer.scrollHeight), t), this.childrenContainer.hidden = !0, this.emit("sl-after-collapse");
856
- }
857
- isNestedItem() {
858
- let t = this.parentElement;
859
- return !!t && e.isTreeItem(t);
860
- }
861
- handleChildrenSlotChange() {
862
- this.loading = !1, this.isLeaf = !this.lazy && this.getChildrenItems().length === 0;
863
- }
864
- willUpdate(e) {
865
- e.has("selected") && !e.has("indeterminate") && (this.indeterminate = !1);
866
- }
867
- async animateExpand() {
868
- this.emit("sl-expand"), await m(this.childrenContainer), this.childrenContainer.hidden = !1;
869
- let { keyframes: e, options: t } = h(this, "tree-item.expand", { dir: this.localize.dir() });
870
- await v(this.childrenContainer, g(e, this.childrenContainer.scrollHeight), t), this.childrenContainer.style.height = "auto", this.emit("sl-after-expand");
871
- }
872
- handleLoadingChange() {
873
- this.setAttribute("aria-busy", this.loading ? "true" : "false"), this.loading || this.animateExpand();
874
- }
875
- handleDisabledChange() {
876
- this.setAttribute("aria-disabled", this.disabled ? "true" : "false");
877
- }
878
- handleSelectedChange() {
879
- this.setAttribute("aria-selected", this.selected ? "true" : "false");
880
- }
881
- handleExpandedChange() {
882
- this.isLeaf ? this.removeAttribute("aria-expanded") : this.setAttribute("aria-expanded", this.expanded ? "true" : "false");
883
- }
884
- handleExpandAnimation() {
885
- this.expanded ? this.lazy ? (this.loading = !0, this.emit("sl-lazy-load")) : this.animateExpand() : this.animateCollapse();
886
- }
887
- handleLazyChange() {
888
- this.emit("sl-lazy-change");
889
- }
890
- getChildrenItems({ includeDisabled: t = !0 } = {}) {
891
- return this.childrenSlot ? [...this.childrenSlot.assignedElements({ flatten: !0 })].filter((n) => e.isTreeItem(n) && (t || !n.disabled)) : [];
892
- }
893
- render() {
894
- let e = this.localize.dir() === "rtl", t = !this.loading && (!this.isLeaf || this.lazy);
895
- return O`
896
- <div
897
- part="base"
898
- class="${ee({
899
- "tree-item": !0,
900
- "tree-item--expanded": this.expanded,
901
- "tree-item--selected": this.selected,
902
- "tree-item--disabled": this.disabled,
903
- "tree-item--leaf": this.isLeaf,
904
- "tree-item--has-expand-button": t,
905
- "tree-item--rtl": this.localize.dir() === "rtl"
906
- })}"
907
- >
908
- <div
909
- class="tree-item__item"
910
- part="
911
- item
912
- ${this.disabled ? "item--disabled" : ""}
913
- ${this.expanded ? "item--expanded" : ""}
914
- ${this.indeterminate ? "item--indeterminate" : ""}
915
- ${this.selected ? "item--selected" : ""}
916
- "
917
- >
918
- <div class="tree-item__indentation" part="indentation"></div>
919
-
920
- <div
921
- part="expand-button"
922
- class=${ee({
923
- "tree-item__expand-button": !0,
924
- "tree-item__expand-button--visible": t
925
- })}
926
- aria-hidden="true"
927
- >
928
- ${xe(this.loading, () => O` <sl-spinner part="spinner" exportparts="base:spinner__base"></sl-spinner> `)}
929
- <slot class="tree-item__expand-icon-slot" name="expand-icon">
930
- <sl-icon library="system" name=${e ? "chevron-left" : "chevron-right"}></sl-icon>
931
- </slot>
932
- <slot class="tree-item__expand-icon-slot" name="collapse-icon">
933
- <sl-icon library="system" name=${e ? "chevron-left" : "chevron-right"}></sl-icon>
934
- </slot>
935
- </div>
936
-
937
- ${xe(this.selectable, () => O`
938
- <sl-checkbox
939
- part="checkbox"
940
- exportparts="
941
- base:checkbox__base,
942
- control:checkbox__control,
943
- control--checked:checkbox__control--checked,
944
- control--indeterminate:checkbox__control--indeterminate,
945
- checked-icon:checkbox__checked-icon,
946
- indeterminate-icon:checkbox__indeterminate-icon,
947
- label:checkbox__label
948
- "
949
- class="tree-item__checkbox"
950
- ?disabled="${this.disabled}"
951
- ?checked="${oe(this.selected)}"
952
- ?indeterminate="${this.indeterminate}"
953
- tabindex="-1"
954
- ></sl-checkbox>
955
- `)}
956
-
957
- <slot class="tree-item__label" part="label"></slot>
958
- </div>
959
-
960
- <div class="tree-item__children" part="children" role="group">
961
- <slot name="children" @slotchange="${this.handleChildrenSlotChange}"></slot>
962
- </div>
963
- </div>
964
- `;
965
- }
966
- };
967
- P.styles = [C, be], P.dependencies = {
968
- "sl-checkbox": ae,
969
- "sl-icon": S,
970
- "sl-spinner": re
971
- }, b([l()], P.prototype, "indeterminate", 2), b([l()], P.prototype, "isLeaf", 2), b([l()], P.prototype, "loading", 2), b([l()], P.prototype, "selectable", 2), b([c({
972
- type: Boolean,
973
- reflect: !0
974
- })], P.prototype, "expanded", 2), b([c({
975
- type: Boolean,
976
- reflect: !0
977
- })], P.prototype, "selected", 2), b([c({
978
- type: Boolean,
979
- reflect: !0
980
- })], P.prototype, "disabled", 2), b([c({
981
- type: Boolean,
982
- reflect: !0
983
- })], P.prototype, "lazy", 2), b([u("slot:not([name])")], P.prototype, "defaultSlot", 2), b([u("slot[name=children]")], P.prototype, "childrenSlot", 2), b([u(".tree-item__item")], P.prototype, "itemElement", 2), b([u(".tree-item__children")], P.prototype, "childrenContainer", 2), b([u(".tree-item__expand-button slot")], P.prototype, "expandButtonSlot", 2), b([y("loading", { waitUntilFirstUpdate: !0 })], P.prototype, "handleLoadingChange", 1), b([y("disabled")], P.prototype, "handleDisabledChange", 1), b([y("selected")], P.prototype, "handleSelectedChange", 1), b([y("expanded", { waitUntilFirstUpdate: !0 })], P.prototype, "handleExpandedChange", 1), b([y("expanded", { waitUntilFirstUpdate: !0 })], P.prototype, "handleExpandAnimation", 1), b([y("lazy", { waitUntilFirstUpdate: !0 })], P.prototype, "handleLazyChange", 1);
984
- var Se = P;
985
- _("tree-item.expand", {
986
- keyframes: [{
987
- height: "0",
988
- opacity: "0",
989
- overflow: "hidden"
990
- }, {
991
- height: "auto",
992
- opacity: "1",
993
- overflow: "hidden"
994
- }],
995
- options: {
996
- duration: 250,
997
- easing: "cubic-bezier(0.4, 0.0, 0.2, 1)"
998
- }
999
- }), _("tree-item.collapse", {
1000
- keyframes: [{
1001
- height: "auto",
1002
- opacity: "1",
1003
- overflow: "hidden"
1004
- }, {
1005
- height: "0",
1006
- opacity: "0",
1007
- overflow: "hidden"
1008
- }],
1009
- options: {
1010
- duration: 200,
1011
- easing: "cubic-bezier(0.4, 0.0, 0.2, 1)"
1012
- }
1013
- });
1014
- //#endregion
1015
- //#region node_modules/@shoelace-style/shoelace/dist/chunks/chunk.G7B7WU5W.js
1016
- var Ce = D`
1017
- :host {
1018
- /*
1019
- * These are actually used by tree item, but we define them here so they can more easily be set and all tree items
1020
- * stay consistent.
1021
- */
1022
- --indent-guide-color: var(--sl-color-neutral-200);
1023
- --indent-guide-offset: 0;
1024
- --indent-guide-style: solid;
1025
- --indent-guide-width: 0;
1026
- --indent-size: var(--sl-spacing-large);
1027
-
1028
- display: block;
1029
-
1030
- /*
1031
- * Tree item indentation uses the "em" unit to increment its width on each level, so setting the font size to zero
1032
- * here removes the indentation for all the nodes on the first level.
1033
- */
1034
- font-size: 0;
1035
- }
1036
- `;
1037
- //#endregion
1038
- //#region node_modules/@shoelace-style/shoelace/dist/chunks/chunk.MSDIZVRW.js
1039
- function we(e, t = !1) {
1040
- function n(e) {
1041
- let t = e.getChildrenItems({ includeDisabled: !1 });
1042
- if (t.length) {
1043
- let n = t.every((e) => e.selected), r = t.every((e) => !e.selected && !e.indeterminate);
1044
- e.selected = n, e.indeterminate = !n && !r;
1045
- }
1046
- }
1047
- function r(e) {
1048
- let t = e.parentElement;
1049
- Se.isTreeItem(t) && (n(t), r(t));
1050
- }
1051
- function i(e) {
1052
- for (let n of e.getChildrenItems()) n.selected = t ? e.selected || n.selected : !n.disabled && e.selected, i(n);
1053
- t && n(e);
1054
- }
1055
- i(e), r(e);
1056
- }
1057
- var F = class extends x {
1058
- constructor() {
1059
- super(), this.selection = "single", this.clickTarget = null, this.localize = new ne(this), this.initTreeItem = (e) => {
1060
- e.selectable = this.selection === "multiple", ["expand", "collapse"].filter((e) => !!this.querySelector(`[slot="${e}-icon"]`)).forEach((t) => {
1061
- let n = e.querySelector(`[slot="${t}-icon"]`), r = this.getExpandButtonIcon(t);
1062
- r && (n === null ? e.append(r) : n.hasAttribute("data-default") && n.replaceWith(r));
1063
- });
1064
- }, this.handleTreeChanged = (e) => {
1065
- for (let t of e) {
1066
- let e = [...t.addedNodes].filter(Se.isTreeItem), n = [...t.removedNodes].filter(Se.isTreeItem);
1067
- e.forEach(this.initTreeItem), this.lastFocusedItem && n.includes(this.lastFocusedItem) && (this.lastFocusedItem = null);
1068
- }
1069
- }, this.handleFocusOut = (e) => {
1070
- let t = e.relatedTarget;
1071
- (!t || !this.contains(t)) && (this.tabIndex = 0);
1072
- }, this.handleFocusIn = (e) => {
1073
- let t = e.target;
1074
- e.target === this && this.focusItem(this.lastFocusedItem || this.getAllTreeItems()[0]), Se.isTreeItem(t) && !t.disabled && (this.lastFocusedItem && (this.lastFocusedItem.tabIndex = -1), this.lastFocusedItem = t, this.tabIndex = -1, t.tabIndex = 0);
1075
- }, this.addEventListener("focusin", this.handleFocusIn), this.addEventListener("focusout", this.handleFocusOut), this.addEventListener("sl-lazy-change", this.handleSlotChange);
1076
- }
1077
- async connectedCallback() {
1078
- super.connectedCallback(), this.setAttribute("role", "tree"), this.setAttribute("tabindex", "0"), await this.updateComplete, this.mutationObserver = new MutationObserver(this.handleTreeChanged), this.mutationObserver.observe(this, {
1079
- childList: !0,
1080
- subtree: !0
1081
- });
1082
- }
1083
- disconnectedCallback() {
1084
- var e;
1085
- super.disconnectedCallback(), (e = this.mutationObserver) == null || e.disconnect();
1086
- }
1087
- getExpandButtonIcon(e) {
1088
- let t = (e === "expand" ? this.expandedIconSlot : this.collapsedIconSlot).assignedElements({ flatten: !0 })[0];
1089
- if (t) {
1090
- let n = t.cloneNode(!0);
1091
- return [n, ...n.querySelectorAll("[id]")].forEach((e) => e.removeAttribute("id")), n.setAttribute("data-default", ""), n.slot = `${e}-icon`, n;
1092
- }
1093
- return null;
1094
- }
1095
- selectItem(e) {
1096
- let t = [...this.selectedItems];
1097
- if (this.selection === "multiple") e.selected = !e.selected, e.lazy && (e.expanded = !0), we(e);
1098
- else if (this.selection === "single" || e.isLeaf) {
1099
- let t = this.getAllTreeItems();
1100
- for (let n of t) n.selected = n === e;
1101
- } else this.selection === "leaf" && (e.expanded = !e.expanded);
1102
- let n = this.selectedItems;
1103
- (t.length !== n.length || n.some((e) => !t.includes(e))) && Promise.all(n.map((e) => e.updateComplete)).then(() => {
1104
- this.emit("sl-selection-change", { detail: { selection: n } });
1105
- });
1106
- }
1107
- getAllTreeItems() {
1108
- return [...this.querySelectorAll("sl-tree-item")];
1109
- }
1110
- focusItem(e) {
1111
- e?.focus();
1112
- }
1113
- handleKeyDown(e) {
1114
- if (![
1115
- "ArrowDown",
1116
- "ArrowUp",
1117
- "ArrowRight",
1118
- "ArrowLeft",
1119
- "Home",
1120
- "End",
1121
- "Enter",
1122
- " "
1123
- ].includes(e.key) || e.composedPath().some((e) => ["input", "textarea"].includes((e?.tagName)?.toLowerCase()))) return;
1124
- let t = this.getFocusableItems(), n = this.localize.dir() === "ltr", r = this.localize.dir() === "rtl";
1125
- if (t.length > 0) {
1126
- e.preventDefault();
1127
- let i = t.findIndex((e) => e.matches(":focus")), a = t[i], o = (e) => {
1128
- let n = t[le(e, 0, t.length - 1)];
1129
- this.focusItem(n);
1130
- }, s = (e) => {
1131
- a.expanded = e;
1132
- };
1133
- e.key === "ArrowDown" ? o(i + 1) : e.key === "ArrowUp" ? o(i - 1) : n && e.key === "ArrowRight" || r && e.key === "ArrowLeft" ? !a || a.disabled || a.expanded || a.isLeaf && !a.lazy ? o(i + 1) : s(!0) : n && e.key === "ArrowLeft" || r && e.key === "ArrowRight" ? !a || a.disabled || a.isLeaf || !a.expanded ? o(i - 1) : s(!1) : e.key === "Home" ? o(0) : e.key === "End" ? o(t.length - 1) : (e.key === "Enter" || e.key === " ") && (a.disabled || this.selectItem(a));
1134
- }
1135
- }
1136
- handleClick(e) {
1137
- let t = e.target, n = t.closest("sl-tree-item"), r = e.composedPath().some((e) => (e?.classList)?.contains("tree-item__expand-button"));
1138
- !n || n.disabled || t !== this.clickTarget || (r ? n.expanded = !n.expanded : this.selectItem(n));
1139
- }
1140
- handleMouseDown(e) {
1141
- this.clickTarget = e.target;
1142
- }
1143
- handleSlotChange() {
1144
- this.getAllTreeItems().forEach(this.initTreeItem);
1145
- }
1146
- async handleSelectionChange() {
1147
- let e = this.selection === "multiple", t = this.getAllTreeItems();
1148
- this.setAttribute("aria-multiselectable", e ? "true" : "false");
1149
- for (let n of t) n.selectable = e;
1150
- e && (await this.updateComplete, [...this.querySelectorAll(":scope > sl-tree-item")].forEach((e) => we(e, !0)));
1151
- }
1152
- get selectedItems() {
1153
- return this.getAllTreeItems().filter((e) => e.selected);
1154
- }
1155
- getFocusableItems() {
1156
- let e = this.getAllTreeItems(), t = /* @__PURE__ */ new Set();
1157
- return e.filter((e) => {
1158
- if (e.disabled) return !1;
1159
- let n = e.parentElement?.closest("[role=treeitem]");
1160
- return n && (!n.expanded || n.loading || t.has(n)) && t.add(e), !t.has(e);
1161
- });
1162
- }
1163
- render() {
1164
- return O`
1165
- <div
1166
- part="base"
1167
- class="tree"
1168
- @click=${this.handleClick}
1169
- @keydown=${this.handleKeyDown}
1170
- @mousedown=${this.handleMouseDown}
1171
- >
1172
- <slot @slotchange=${this.handleSlotChange}></slot>
1173
- <span hidden aria-hidden="true"><slot name="expand-icon"></slot></span>
1174
- <span hidden aria-hidden="true"><slot name="collapse-icon"></slot></span>
1175
- </div>
1176
- `;
1177
- }
1178
- };
1179
- //#endregion
1180
- //#region node_modules/@shoelace-style/shoelace/dist/chunks/chunk.GTHX4FOE.js
1181
- F.styles = [C, Ce], b([u("slot:not([name])")], F.prototype, "defaultSlot", 2), b([u("slot[name=expand-icon]")], F.prototype, "expandedIconSlot", 2), b([u("slot[name=collapse-icon]")], F.prototype, "collapsedIconSlot", 2), b([c()], F.prototype, "selection", 2), b([y("selection")], F.prototype, "handleSelectionChange", 1), F.define("sl-tree"), Se.define("sl-tree-item");
673
+ })], ae.prototype, "collapsed", void 0), ae = o([b("webmapx-tool-panel")], ae);
1182
674
  //#endregion
1183
675
  //#region src/components/webmapx-layer-tree.ts
1184
- var Te = class extends E {
676
+ var E = class extends h {
1185
677
  constructor(...e) {
1186
678
  super(...e), this.tree = [], this.toolId = null, this.configTree = [], this.searchQuery = "", this.searchThreshold = 8, this.configHandler = null, this.addLayerFailedHandler = null, this.mapReadyHandler = null, this.adapter = null, this.unsubscribeLayerAdd = null, this.unsubscribeLayerRemove = null, this.nodeByKey = /* @__PURE__ */ new Map(), this.supportStatusByLayerId = /* @__PURE__ */ new Map(), this.capsCache = /* @__PURE__ */ new Map(), this.pendingSupportChecks = /* @__PURE__ */ new Set(), this.supportQueue = [], this.supportChecksInFlight = 0, this.maxConcurrentSupportChecks = 3, this.didQueueRootSupportChecks = !1;
1187
679
  }
1188
680
  static {
1189
- this.styles = D`
681
+ this.styles = g`
1190
682
  :host {
1191
683
  display: block;
1192
684
  height: auto; /* let parent control available height */
@@ -1614,7 +1106,7 @@ var Te = class extends E {
1614
1106
  if (!this.capsCache.has(t)) {
1615
1107
  this.capsCache.set(t, { status: "loading" }), this.requestUpdate();
1616
1108
  try {
1617
- let { discoverWms: n } = await import("./layer-discovery-afWzu5hY.js"), r = await n(e.url), i = this.normalizeLayerList(e.allowedLayers), a = new Set(this.normalizeLayerList(e.deniedLayers)), o = e.tilecacheUrl ? Array.isArray(e.tilecacheUrl) ? e.tilecacheUrl : [e.tilecacheUrl] : void 0, s = r.filter((e) => {
1109
+ let { discoverWms: n } = await import("./layer-discovery-DFP-WHAh.js"), r = await n(e.url), i = this.normalizeLayerList(e.allowedLayers), a = new Set(this.normalizeLayerList(e.deniedLayers)), o = e.tilecacheUrl ? Array.isArray(e.tilecacheUrl) ? e.tilecacheUrl : [e.tilecacheUrl] : void 0, s = r.filter((e) => {
1618
1110
  let t = e.layer.id;
1619
1111
  return !(a.has(t) || i.length > 0 && !i.includes(t));
1620
1112
  }).map((e) => {
@@ -1648,7 +1140,7 @@ var Te = class extends E {
1648
1140
  renderNode(e, t, n = "0") {
1649
1141
  if ((e.type === "getcapabilities" || e.type === "capabilities") && e.url) {
1650
1142
  let r = this.capsKey(e), i = this.capsCache.get(r), a = this.getChildSelectionContext(e, t, n), o;
1651
- return o = !i || i.status === "loading" ? O`<sl-tree-item disabled><sl-spinner style="font-size:0.85rem"></sl-spinner> Loading…</sl-tree-item>` : i.status === "error" ? O`<sl-tree-item disabled style="color:var(--sl-color-danger-600)">⚠ ${i.error}</sl-tree-item>` : O`${i.children.map((e, t) => this.renderNode(e, a, `${n}.${t}`))}`, O`
1143
+ return o = !i || i.status === "loading" ? _`<sl-tree-item disabled><sl-spinner style="font-size:0.85rem"></sl-spinner> Loading…</sl-tree-item>` : i.status === "error" ? _`<sl-tree-item disabled style="color:var(--sl-color-danger-600)">⚠ ${i.error}</sl-tree-item>` : _`${i.children.map((e, t) => this.renderNode(e, a, `${n}.${t}`))}`, _`
1652
1144
  <sl-tree-item ?expanded=${e.expanded} data-node-key=${n}
1653
1145
  @sl-expand=${() => {
1654
1146
  this.fetchCapabilities(e);
@@ -1657,12 +1149,12 @@ var Te = class extends E {
1657
1149
  ${o}
1658
1150
  </sl-tree-item>`;
1659
1151
  }
1660
- if (e.separator) return O`
1152
+ if (e.separator) return _`
1661
1153
  <sl-tree-item class="separator-item" data-node-key=${n} tabindex="-1" aria-hidden="true">
1662
1154
  <span class="tree-separator">${this.resolveNodeLabel(e)}</span>
1663
1155
  </sl-tree-item>`;
1664
1156
  let r = this.getChildSelectionContext(e, t, n);
1665
- if (this.nodeByKey.set(n, e), e.children && e.children.length > 0) return O`
1157
+ if (this.nodeByKey.set(n, e), e.children && e.children.length > 0) return _`
1666
1158
  <sl-tree-item ?expanded=${e.expanded} data-node-key=${n}>
1667
1159
  <span @click=${(e) => {
1668
1160
  let t = e.currentTarget.closest("sl-tree-item");
@@ -1673,11 +1165,11 @@ var Te = class extends E {
1673
1165
  `;
1674
1166
  {
1675
1167
  let t = r.selectionMode === "single", i = this.getExclusiveGroupKey(e, r), a = this.getSupportStatus(e.layerId) === "unsupported", o = this.resolveNodeLabel(e), s = a ? `${o} (unsupported for current engine)` : o;
1676
- return O`
1168
+ return _`
1677
1169
  <sl-tree-item data-node-key=${n} @keydown=${(e) => {
1678
1170
  (e.key === " " || e.key === "Enter") && (e.preventDefault(), e.currentTarget.querySelector("sl-checkbox, input[type=\"radio\"]")?.click()), (e.key === "ArrowUp" || e.key === "ArrowDown" || e.key === "ArrowLeft" || e.key === "ArrowRight") && t && e.preventDefault();
1679
1171
  }}>
1680
- ${t ? O`
1172
+ ${t ? _`
1681
1173
  <label class="layer-radio">
1682
1174
  <input
1683
1175
  type="radio"
@@ -1693,7 +1185,7 @@ var Te = class extends E {
1693
1185
  />
1694
1186
  <span>${s}</span>
1695
1187
  </label>
1696
- ` : O`
1188
+ ` : _`
1697
1189
  <sl-checkbox
1698
1190
  ?checked=${e.checked}
1699
1191
  ?disabled=${a}
@@ -1752,8 +1244,8 @@ var Te = class extends E {
1752
1244
  render() {
1753
1245
  this.nodeByKey.clear();
1754
1246
  let e = this.searchQuery.trim().toLowerCase(), t = e ? this.filterTree(this.effectiveTree, e) : this.effectiveTree;
1755
- return O`
1756
- ${this.showSearch ? O`
1247
+ return _`
1248
+ ${this.showSearch ? _`
1757
1249
  <div class="search">
1758
1250
  <input
1759
1251
  type="text"
@@ -1763,22 +1255,22 @@ var Te = class extends E {
1763
1255
  .value=${this.searchQuery}
1764
1256
  @input=${this.handleSearchInput}
1765
1257
  />
1766
- ${this.searchQuery ? O`<button class="search-clear" @click=${this.handleSearchClear} aria-label="Clear search">&times;</button>` : O``}
1258
+ ${this.searchQuery ? _`<button class="search-clear" @click=${this.handleSearchClear} aria-label="Clear search">&times;</button>` : _``}
1767
1259
  </div>
1768
- ` : O``}
1260
+ ` : _``}
1769
1261
  <sl-tree @sl-expand=${this.handleTreeExpand}>
1770
1262
  ${t.map((e, t) => this.renderNode(e, void 0, `${t}`))}
1771
1263
  </sl-tree>
1772
1264
  `;
1773
1265
  }
1774
1266
  };
1775
- o([c({ type: Array })], Te.prototype, "tree", void 0), o([c({
1267
+ o([x({ type: Array })], E.prototype, "tree", void 0), o([x({
1776
1268
  type: String,
1777
1269
  attribute: "tool-id"
1778
- })], Te.prototype, "toolId", void 0), o([l()], Te.prototype, "configTree", void 0), o([l()], Te.prototype, "searchQuery", void 0), o([l()], Te.prototype, "capsCache", void 0), Te = o([d("webmapx-layer-tree")], Te);
1270
+ })], E.prototype, "toolId", void 0), o([w()], E.prototype, "configTree", void 0), o([w()], E.prototype, "searchQuery", void 0), o([w()], E.prototype, "capsCache", void 0), E = o([b("webmapx-layer-tree")], E);
1779
1271
  //#endregion
1780
1272
  //#region node_modules/@simonwep/pickr/dist/themes/nano.min.css
1781
- var Ee = /* @__PURE__ */ e((/* @__PURE__ */ t(((e, t) => {
1273
+ var oe = /* @__PURE__ */ e((/* @__PURE__ */ t(((e, t) => {
1782
1274
  (function(n, r) {
1783
1275
  typeof e == "object" && typeof t == "object" ? t.exports = r() : typeof define == "function" && define.amd ? define([], r) : typeof e == "object" ? e.Pickr = r() : n.Pickr = r();
1784
1276
  })(self, (() => (() => {
@@ -1794,7 +1286,7 @@ var Ee = /* @__PURE__ */ e((/* @__PURE__ */ t(((e, t) => {
1794
1286
  typeof Symbol < "u" && Symbol.toStringTag && Object.defineProperty(e, Symbol.toStringTag, { value: "Module" }), Object.defineProperty(e, "__esModule", { value: !0 });
1795
1287
  }
1796
1288
  }, t = {};
1797
- e.d(t, { default: () => re });
1289
+ e.d(t, { default: () => ne });
1798
1290
  var n = {};
1799
1291
  function r(e, t, n, r, i = {}) {
1800
1292
  t instanceof HTMLCollection || t instanceof NodeList ? t = Array.from(t) : Array.isArray(t) || (t = [t]), Array.isArray(n) || (n = [n]);
@@ -2038,7 +1530,7 @@ var Ee = /* @__PURE__ */ e((/* @__PURE__ */ t(((e, t) => {
2038
1530
  return a;
2039
1531
  }
2040
1532
  let C = (e) => Math.max(Math.min(e, 1), 0);
2041
- function ee(e) {
1533
+ function w(e) {
2042
1534
  let t = {
2043
1535
  options: Object.assign({
2044
1536
  lock: null,
@@ -2103,7 +1595,7 @@ var Ee = /* @__PURE__ */ e((/* @__PURE__ */ t(((e, t) => {
2103
1595
  }, { options: n, _tapstart: r, _keyboard: o } = t;
2104
1596
  return i([n.wrapper, n.element], "mousedown", r), i([n.wrapper, n.element], "touchstart", r, { passive: !1 }), i(document, ["keydown", "keyup"], o), t;
2105
1597
  }
2106
- function w(e = {}) {
1598
+ function ee(e = {}) {
2107
1599
  e = Object.assign({
2108
1600
  onchange: () => 0,
2109
1601
  className: "",
@@ -2129,7 +1621,7 @@ var Ee = /* @__PURE__ */ e((/* @__PURE__ */ t(((e, t) => {
2129
1621
  position: "bottom",
2130
1622
  margin: 8,
2131
1623
  padding: 0
2132
- }, ne = (e, t, n) => {
1624
+ }, T = (e, t, n) => {
2133
1625
  let r = typeof e != "object" || e instanceof HTMLElement ? {
2134
1626
  reference: e,
2135
1627
  popper: t,
@@ -2184,7 +1676,7 @@ var Ee = /* @__PURE__ */ e((/* @__PURE__ */ t(((e, t) => {
2184
1676
  })(t, n, r);
2185
1677
  } };
2186
1678
  };
2187
- class re {
1679
+ class ne {
2188
1680
  static utils = n;
2189
1681
  static version = "1.9.1";
2190
1682
  static I18N_DEFAULTS = {
@@ -2247,20 +1739,20 @@ var Ee = /* @__PURE__ */ e((/* @__PURE__ */ t(((e, t) => {
2247
1739
  swatchselect: []
2248
1740
  };
2249
1741
  constructor(e) {
2250
- this.options = e = Object.assign({ ...re.DEFAULT_OPTIONS }, e);
1742
+ this.options = e = Object.assign({ ...ne.DEFAULT_OPTIONS }, e);
2251
1743
  let { swatches: t, components: n, theme: r, sliders: i, lockOpacity: a, padding: o } = e;
2252
1744
  ["nano", "monolith"].includes(r) && !i && (e.sliders = "h"), n.interaction ||= {};
2253
1745
  let { preview: s, opacity: c, hue: l, palette: u } = n;
2254
1746
  n.opacity = !a && c, n.palette = u || s || c || l, this._preBuild(), this._buildComponents(), this._bindEvents(), this._finalBuild(), t && t.length && t.forEach(((e) => this.addSwatch(e)));
2255
1747
  let { button: d, app: f } = this._root;
2256
- this._nanopop = ne(d, f, { margin: o }), d.setAttribute("role", "button"), d.setAttribute("aria-label", this._t("btn:toggle"));
1748
+ this._nanopop = T(d, f, { margin: o }), d.setAttribute("role", "button"), d.setAttribute("aria-label", this._t("btn:toggle"));
2257
1749
  let p = this;
2258
1750
  this._setupAnimationFrame = requestAnimationFrame((function t() {
2259
1751
  if (!f.offsetWidth) return requestAnimationFrame(t);
2260
1752
  p.setColor(e.default), p._rePositioningPicker(), e.defaultRepresentation && (p._representation = e.defaultRepresentation, p.setColorRepresentation(p._representation)), e.showAlways && p.show(), p._initializingActive = !1, p._emit("init");
2261
1753
  }));
2262
1754
  }
2263
- static create = (e) => new re(e);
1755
+ static create = (e) => new ne(e);
2264
1756
  _preBuild() {
2265
1757
  let { options: e } = this;
2266
1758
  for (let t of ["el", "container"]) e[t] = l(e[t]);
@@ -2279,7 +1771,7 @@ var Ee = /* @__PURE__ */ e((/* @__PURE__ */ t(((e, t) => {
2279
1771
  }
2280
1772
  _buildComponents() {
2281
1773
  let e = this, t = this.options.components, n = (e.options.sliders || "v").repeat(2), [r, i] = n.match(/^[vh]+$/g) ? n : [], a = () => this._color ||= this._lastColor.clone(), o = {
2282
- palette: ee({
1774
+ palette: w({
2283
1775
  element: e._root.palette.picker,
2284
1776
  wrapper: e._root.palette.palette,
2285
1777
  onstop: () => e._emit("changestop", "slider", e),
@@ -2294,7 +1786,7 @@ var Ee = /* @__PURE__ */ e((/* @__PURE__ */ t(((e, t) => {
2294
1786
  l.style.setProperty("--pcr-color", u);
2295
1787
  }
2296
1788
  }),
2297
- hue: ee({
1789
+ hue: w({
2298
1790
  lock: i === "v" ? "h" : "v",
2299
1791
  element: e._root.hue.picker,
2300
1792
  wrapper: e._root.hue.slider,
@@ -2305,7 +1797,7 @@ var Ee = /* @__PURE__ */ e((/* @__PURE__ */ t(((e, t) => {
2305
1797
  e._recalc && (r.h = 360 * n), this.element.style.backgroundColor = `hsl(${r.h}, 100%, 50%)`, o.palette.trigger();
2306
1798
  }
2307
1799
  }),
2308
- opacity: ee({
1800
+ opacity: w({
2309
1801
  lock: r === "v" ? "h" : "v",
2310
1802
  element: e._root.opacity.picker,
2311
1803
  wrapper: e._root.opacity.slider,
@@ -2316,7 +1808,7 @@ var Ee = /* @__PURE__ */ e((/* @__PURE__ */ t(((e, t) => {
2316
1808
  e._recalc && (r.a = Math.round(100 * n) / 100), this.element.style.background = `rgba(0, 0, 0, ${r.a})`, o.palette.trigger();
2317
1809
  }
2318
1810
  }),
2319
- selectable: w({
1811
+ selectable: ee({
2320
1812
  elements: e._root.interaction.options,
2321
1813
  className: "active",
2322
1814
  onchange(t) {
@@ -2432,7 +1924,7 @@ var Ee = /* @__PURE__ */ e((/* @__PURE__ */ t(((e, t) => {
2432
1924
  };
2433
1925
  }
2434
1926
  _t(e) {
2435
- return this.options.i18n[e] || re.I18N_DEFAULTS[e];
1927
+ return this.options.i18n[e] || ne.I18N_DEFAULTS[e];
2436
1928
  }
2437
1929
  _emit(e, ...t) {
2438
1930
  this._eventListener[e].forEach(((e) => e(...t, this)));
@@ -2527,9 +2019,9 @@ var Ee = /* @__PURE__ */ e((/* @__PURE__ */ t(((e, t) => {
2527
2019
  }
2528
2020
  return t = t.default;
2529
2021
  })()));
2530
- })))(), 1), De, I = class extends s {
2022
+ })))(), 1), se, D = class extends s {
2531
2023
  static {
2532
- De = this;
2024
+ se = this;
2533
2025
  }
2534
2026
  constructor(...e) {
2535
2027
  super(...e), this.layerId = "", this.collapsible = !0, this.meta = null, this.zoom = 2, this.legendCollapsed = !0, this.legendOverflowing = !1, this.editOverrides = {}, this.editorOpenKey = null, this.terrainEnabled = !1, this.legendResizeObserver = null, this.measureLegendQueued = !1, this.pickrInstances = /* @__PURE__ */ new Map(), this.pickrOriginal = /* @__PURE__ */ new Map(), this.pendingPaintUpdates = /* @__PURE__ */ new Map(), this.pendingPaintRaf = null;
@@ -2538,7 +2030,7 @@ var Ee = /* @__PURE__ */ e((/* @__PURE__ */ t(((e, t) => {
2538
2030
  this.collapsedLegendHeight = 180;
2539
2031
  }
2540
2032
  static {
2541
- this.styles = D`
2033
+ this.styles = g`
2542
2034
  :host { display: block; }
2543
2035
  .legend-wrap { display: flex; flex-direction: column; gap: 2px; }
2544
2036
  .legend-collapse {
@@ -2548,7 +2040,7 @@ var Ee = /* @__PURE__ */ e((/* @__PURE__ */ t(((e, t) => {
2548
2040
  overflow: visible;
2549
2041
  }
2550
2042
  .legend-collapse.collapsed .legend-collapse-content {
2551
- max-height: ${De.collapsedLegendHeight}px;
2043
+ max-height: ${se.collapsedLegendHeight}px;
2552
2044
  overflow: hidden;
2553
2045
  }
2554
2046
  .legend-collapse.collapsed::after {
@@ -2643,17 +2135,17 @@ var Ee = /* @__PURE__ */ e((/* @__PURE__ */ t(((e, t) => {
2643
2135
  this.legendOverflowing &&= !1;
2644
2136
  return;
2645
2137
  }
2646
- let e = this.renderRoot?.querySelector(".legend-collapse-content"), t = !!(e && e.scrollHeight > De.collapsedLegendHeight + 1);
2138
+ let e = this.renderRoot?.querySelector(".legend-collapse-content"), t = !!(e && e.scrollHeight > se.collapsedLegendHeight + 1);
2647
2139
  this.legendOverflowing !== t && (this.legendOverflowing = t);
2648
2140
  }
2649
2141
  renderCollapsibleLegend(e) {
2650
2142
  let t = this.collapsible && this.legendOverflowing && this.legendCollapsed, n = this.collapsible && this.legendOverflowing;
2651
- return O`
2143
+ return _`
2652
2144
  <div class="legend-collapse ${t ? "collapsed" : ""}">
2653
2145
  <div class="legend-collapse-content">
2654
2146
  ${e}
2655
2147
  </div>
2656
- ${n ? O`
2148
+ ${n ? _`
2657
2149
  <button
2658
2150
  type="button"
2659
2151
  class="legend-toggle"
@@ -2764,7 +2256,7 @@ var Ee = /* @__PURE__ */ e((/* @__PURE__ */ t(((e, t) => {
2764
2256
  }
2765
2257
  renderZoomHint(e, t, n) {
2766
2258
  let r = n > t;
2767
- return O`<div class="legend-row"><span class="legend-label">${r ? "zoom out" : "zoom in"} to level ${r ? t : e} for display</span></div>`;
2259
+ return _`<div class="legend-row"><span class="legend-label">${r ? "zoom out" : "zoom in"} to level ${r ? t : e} for display</span></div>`;
2768
2260
  }
2769
2261
  renderCompositeLegend(e, t) {
2770
2262
  let n = [], r = /* @__PURE__ */ new Set(), i = /* @__PURE__ */ new Map(), a = e.length === 1, o = Infinity, s = -Infinity;
@@ -2784,49 +2276,49 @@ var Ee = /* @__PURE__ */ e((/* @__PURE__ */ t(((e, t) => {
2784
2276
  for (let [e, n] of Object.entries(u)) h[e] = this.isDataDriven(n) ? n : this.evalAtZoom(n, t);
2785
2277
  let g = {};
2786
2278
  for (let [e, n] of Object.entries(d)) g[e] = this.evalAtZoom(n, t);
2787
- let _ = { ...h }, v = { ...g }, y = this.editOverrides[f];
2788
- y && (Object.assign(h, y), "text-size" in y && (g["text-size"] = y["text-size"]));
2789
- let b = l === "fill" ? "fill-color" : l === "fill-extrusion" ? "fill-extrusion-color" : l === "line" ? "line-color" : l === "circle" ? "circle-color" : l === "symbol" ? "text-color" : null, x = b ? u[b] : null, S = x ? this.extractDataCases(x) : null;
2790
- if (S && S.length > 1) {
2279
+ let v = { ...h }, y = { ...g }, b = this.editOverrides[f];
2280
+ b && (Object.assign(h, b), "text-size" in b && (g["text-size"] = b["text-size"]));
2281
+ let x = l === "fill" ? "fill-color" : l === "fill-extrusion" ? "fill-extrusion-color" : l === "line" ? "line-color" : l === "circle" ? "circle-color" : l === "symbol" ? "text-color" : null, S = x ? u[x] : null, C = S ? this.extractDataCases(S) : null;
2282
+ if (C && C.length > 1) {
2791
2283
  let e = `${l}|${f}`;
2792
2284
  if (r.has(e)) continue;
2793
- r.add(e), i.has(e) || i.set(e, [f]), a || n.push(O`<div class="sub-group-title">${m}</div>`);
2794
- let o = Array.isArray(x) ? x : null, s = o ? this.colorExprStopIndices(o) : null;
2795
- for (let e = 0; e < S.length; e++) {
2796
- let { label: i, paint: a } = S[e], c = {
2285
+ r.add(e), i.has(e) || i.set(e, [f]), a || n.push(_`<div class="sub-group-title">${m}</div>`);
2286
+ let o = Array.isArray(S) ? S : null, s = o ? this.colorExprStopIndices(o) : null;
2287
+ for (let e = 0; e < C.length; e++) {
2288
+ let { label: i, paint: a } = C[e], c = {
2797
2289
  ...h,
2798
- [b]: a
2290
+ [x]: a
2799
2291
  }, u = this.renderSwatch(l, c, t, g);
2800
2292
  if (!u) continue;
2801
2293
  let d = `${l}|${String(a)}`;
2802
2294
  if (r.has(d)) continue;
2803
2295
  r.add(d);
2804
- let p = s?.[e] ?? null, m = typeof a == "string" ? a : "#000", _ = p !== null && o ? O`<button type="button" style="background:none;border:none;padding:0;cursor:pointer;display:flex;align-items:center"
2296
+ let p = s?.[e] ?? null, m = typeof a == "string" ? a : "#000", v = p !== null && o ? _`<button type="button" style="background:none;border:none;padding:0;cursor:pointer;display:flex;align-items:center"
2805
2297
  @click=${(e) => {
2806
- e.stopPropagation(), this.openStopColorPicker(e.currentTarget, [f], b, o, p, m);
2298
+ e.stopPropagation(), this.openStopColorPicker(e.currentTarget, [f], x, o, p, m);
2807
2299
  }}>
2808
2300
  ${u}</button>` : u;
2809
- n.push(O`
2301
+ n.push(_`
2810
2302
  <div class="legend-row sub-row">
2811
- ${_}
2303
+ ${v}
2812
2304
  <span class="legend-label">${i}</span>
2813
2305
  </div>`);
2814
2306
  }
2815
2307
  } else {
2816
- let e = b ? String(_[b] ?? "#aaa") : "#aaa", a = `${l}|${e}`;
2308
+ let e = x ? String(v[x] ?? "#aaa") : "#aaa", a = `${l}|${e}`;
2817
2309
  if (l === "line") {
2818
- let t = _["line-dasharray"];
2310
+ let t = v["line-dasharray"];
2819
2311
  a = `line|${e}|${Array.isArray(t) ? t.join(",") : String(t ?? "")}`;
2820
2312
  } else if (l === "symbol") {
2821
- let t = v["text-size"] ?? _["text-size"], n = Math.round(Number(typeof t == "number" ? t : 12)), r = (Array.isArray(v["text-font"]) ? v["text-font"] : []).join(" ").toLowerCase(), i = r.includes("bold") || r.includes("black") ? "700" : r.includes("semibold") || r.includes("demibold") || r.includes("medium") ? "600" : "400", o = Math.round(Number(_["text-halo-width"] ?? 0) * 2) / 2;
2822
- a = `symbol|${e}|${n}|${i}|${o}|${o > 0 ? String(_["text-halo-color"] ?? "") : ""}`;
2313
+ let t = y["text-size"] ?? v["text-size"], n = Math.round(Number(typeof t == "number" ? t : 12)), r = (Array.isArray(y["text-font"]) ? y["text-font"] : []).join(" ").toLowerCase(), i = r.includes("bold") || r.includes("black") ? "700" : r.includes("semibold") || r.includes("demibold") || r.includes("medium") ? "600" : "400", o = Math.round(Number(v["text-halo-width"] ?? 0) * 2) / 2;
2314
+ a = `symbol|${e}|${n}|${i}|${o}|${o > 0 ? String(v["text-halo-color"] ?? "") : ""}`;
2823
2315
  }
2824
2316
  if (i.has(a) || i.set(a, []), i.get(a).push(f), r.has(a)) continue;
2825
2317
  r.add(a);
2826
2318
  let o = this.renderSwatch(l, h, t, g);
2827
2319
  if (!o) continue;
2828
2320
  let s = this.isEditableType(l, h), c = this.editorOpenKey === a;
2829
- if (n.push(O`
2321
+ if (n.push(_`
2830
2322
  <div class="legend-row ${s ? "editable" : ""}"
2831
2323
  @click=${s ? () => {
2832
2324
  this.editorOpenKey = c ? null : a;
@@ -2842,7 +2334,7 @@ var Ee = /* @__PURE__ */ e((/* @__PURE__ */ t(((e, t) => {
2842
2334
  }
2843
2335
  }
2844
2336
  }
2845
- return O`<div class="legend-wrap">${n}</div>`;
2337
+ return _`<div class="legend-wrap">${n}</div>`;
2846
2338
  }
2847
2339
  resolveSwatchColor(e, t) {
2848
2340
  return typeof e == "string" ? e : t;
@@ -2850,30 +2342,30 @@ var Ee = /* @__PURE__ */ e((/* @__PURE__ */ t(((e, t) => {
2850
2342
  renderSwatch(e, t, n, r) {
2851
2343
  if (e === "fill") {
2852
2344
  let e = this.resolveSwatchColor(t["fill-color"], "#000000");
2853
- return A`<svg width="20" height="12" style="flex-shrink:0">
2345
+ return y`<svg width="20" height="12" style="flex-shrink:0">
2854
2346
  <rect x="1" y="1" width="18" height="10" fill="${e}" fill-opacity="${Number(t["fill-opacity"] ?? .7)}"
2855
2347
  stroke="${String(t["fill-outline-color"] ?? e)}" stroke-width="1" rx="1"/>
2856
2348
  </svg>`;
2857
2349
  }
2858
- if (e === "fill-extrusion") return A`<svg width="20" height="12" style="flex-shrink:0">
2350
+ if (e === "fill-extrusion") return y`<svg width="20" height="12" style="flex-shrink:0">
2859
2351
  <rect x="1" y="1" width="18" height="10" fill="${String(t["fill-extrusion-color"] ?? "#aaa")}" fill-opacity="${Number(t["fill-extrusion-opacity"] ?? .8)}" stroke="none"/>
2860
2352
  <line x1="19" y1="1" x2="19" y2="11" stroke="rgba(0,0,0,0.3)" stroke-width="2"/>
2861
2353
  <line x1="1" y1="11" x2="19" y2="11" stroke="rgba(0,0,0,0.3)" stroke-width="2"/>
2862
2354
  </svg>`;
2863
- if (e === "line") return A`<svg width="20" height="12" style="flex-shrink:0">
2355
+ if (e === "line") return y`<svg width="20" height="12" style="flex-shrink:0">
2864
2356
  <line x1="1" y1="6" x2="19" y2="6" stroke="${this.resolveSwatchColor(t["line-color"], "#616161")}" stroke-width="${Math.min(Number(t["line-width"] ?? 2), 4)}"
2865
2357
  stroke-dasharray="${Array.isArray(t["line-dasharray"]) ? t["line-dasharray"].join(" ") : ""}" stroke-linecap="round"/>
2866
2358
  </svg>`;
2867
2359
  if (e === "circle") {
2868
2360
  let e = String(t["circle-color"] ?? "#aaa");
2869
- return A`<svg width="20" height="12" style="flex-shrink:0">
2361
+ return y`<svg width="20" height="12" style="flex-shrink:0">
2870
2362
  <circle cx="10" cy="6" r="${Math.min(Number(t["circle-radius"] ?? 4), 5)}" fill="${e}" stroke="${String(t["circle-stroke-color"] ?? e)}" stroke-width="${Number(t["circle-stroke-width"] ?? 0)}"/>
2871
2363
  </svg>`;
2872
2364
  }
2873
2365
  if (e === "symbol") {
2874
2366
  let e = String(t["text-color"] ?? "#555"), n = t["text-halo-width"] && Number(t["text-halo-width"]) > 0 ? String(t["text-halo-color"] ?? "rgba(255,255,255,0.8)") : null, i = r?.["text-size"] ?? t["text-size"], a = Math.min(Math.max(Math.round((typeof i == "number" ? i : 12) * .9), 7), 24), o = (Array.isArray(r?.["text-font"]) ? r["text-font"] : []).join(" ").toLowerCase(), s = o.includes("bold") || o.includes("black") ? "700" : o.includes("semibold") || o.includes("demibold") || o.includes("medium") ? "600" : "400", c = o.includes("italic") || o.includes("oblique") ? "italic" : "normal", l = Math.max(20, a + 4);
2875
- return A`<svg width="${l}" height="${a + 4}" style="flex-shrink:0">
2876
- ${n ? A`<text x="${l / 2}" y="${a}" text-anchor="middle"
2367
+ return y`<svg width="${l}" height="${a + 4}" style="flex-shrink:0">
2368
+ ${n ? y`<text x="${l / 2}" y="${a}" text-anchor="middle"
2877
2369
  font-size="${a}" font-weight="${s}" font-style="${c}"
2878
2370
  stroke="${n}" stroke-width="3" stroke-linejoin="round"
2879
2371
  fill="none" font-family="sans-serif">A</text>` : ""}
@@ -2882,9 +2374,9 @@ var Ee = /* @__PURE__ */ e((/* @__PURE__ */ t(((e, t) => {
2882
2374
  fill="${e}" font-family="sans-serif">A</text>
2883
2375
  </svg>`;
2884
2376
  }
2885
- return e === "background" ? A`<svg width="20" height="12" style="flex-shrink:0">
2377
+ return e === "background" ? y`<svg width="20" height="12" style="flex-shrink:0">
2886
2378
  <rect x="1" y="1" width="18" height="10" fill="${String(t["background-color"] ?? "#eee")}" rx="1"/>
2887
- </svg>` : e === "raster" || e === "hillshade" ? A`<svg width="20" height="12" style="flex-shrink:0">
2379
+ </svg>` : e === "raster" || e === "hillshade" ? y`<svg width="20" height="12" style="flex-shrink:0">
2888
2380
  <defs><pattern id="rp" width="4" height="4" patternUnits="userSpaceOnUse">
2889
2381
  <rect width="2" height="2" fill="#ccc"/>
2890
2382
  <rect x="2" y="2" width="2" height="2" fill="#eee"/>
@@ -2943,7 +2435,7 @@ var Ee = /* @__PURE__ */ e((/* @__PURE__ */ t(((e, t) => {
2943
2435
  renderBubbleLegend(e, t, n) {
2944
2436
  let r = Math.min(n, 1.5), i = Math.max(...e.map((e) => e.radius)), a = i + r + 2, o = a * 2, s = i * 2 + r * 2 + 4, c = s - 2, l = o + 8, u = o + 60, d = [...e].sort((e, t) => t.radius - e.radius).map((e) => {
2945
2437
  let n = Math.max(1, e.radius * 1), i = c - n - r, o = i - n;
2946
- return A`
2438
+ return y`
2947
2439
  <circle cx="${a}" cy="${i}" r="${n}"
2948
2440
  fill="${e.color}" fill-opacity="0.75"
2949
2441
  stroke="${t}" stroke-width="${r}"/>
@@ -2951,41 +2443,41 @@ var Ee = /* @__PURE__ */ e((/* @__PURE__ */ t(((e, t) => {
2951
2443
  stroke="#999" stroke-width="0.5" stroke-dasharray="2 2"/>
2952
2444
  <text x="${l}" y="${o + 4}" font-size="9" fill="#555">${e.value}</text>
2953
2445
  `;
2954
- }), f = Math.max(14, Math.floor((o + 60) / e.length)), p = e.length * f, m = e.map((e, t) => A`<rect x="${t * f}" y="0" width="${f}" height="${8}" fill="${e.color}"/>
2446
+ }), f = Math.max(14, Math.floor((o + 60) / e.length)), p = e.length * f, m = e.map((e, t) => y`<rect x="${t * f}" y="0" width="${f}" height="${8}" fill="${e.color}"/>
2955
2447
  <text x="${t * f + f / 2}" y="${17}" font-size="8"
2956
2448
  text-anchor="middle" fill="#555">${e.value}</text>`), h = e.every((t) => t.color === e[0].color);
2957
- return O`
2449
+ return _`
2958
2450
  <div class="legend-row" style="flex-direction:column;align-items:flex-start;gap:6px">
2959
- ${A`<svg width="${u}" height="${s}" style="overflow:visible">
2451
+ ${y`<svg width="${u}" height="${s}" style="overflow:visible">
2960
2452
  <line x1="${a}" y1="${c}" x2="${a}" y2="2" stroke="#bbb" stroke-width="1"/>
2961
2453
  ${d}
2962
2454
  </svg>`}
2963
- ${h ? "" : A`<svg width="${p}" height="${20}" style="overflow:visible">
2455
+ ${h ? "" : y`<svg width="${p}" height="${20}" style="overflow:visible">
2964
2456
  ${m}
2965
2457
  </svg>`}
2966
2458
  </div>`;
2967
2459
  }
2968
2460
  renderCircleRow(e, t, n, r, i) {
2969
2461
  let a = Math.min(Math.max(r, 2), 12), o = Math.min(n, 2), s = (a + o) * 2 + 2;
2970
- return O`
2462
+ return _`
2971
2463
  <div class="legend-row">
2972
- ${A`<svg width="${s}" height="${s}" style="flex-shrink:0">
2464
+ ${y`<svg width="${s}" height="${s}" style="flex-shrink:0">
2973
2465
  <circle cx="${s / 2}" cy="${s / 2}" r="${a}"
2974
2466
  fill="${e}" stroke="${t}" stroke-width="${o}"/>
2975
2467
  </svg>`}
2976
- ${i === null ? "" : O`<span class="legend-label">${i}</span>`}
2468
+ ${i === null ? "" : _`<span class="legend-label">${i}</span>`}
2977
2469
  </div>`;
2978
2470
  }
2979
2471
  renderFillRow(e, t, n, r, i) {
2980
- let a = A`<svg width="24" height="14" style="flex-shrink:0">
2472
+ let a = y`<svg width="24" height="14" style="flex-shrink:0">
2981
2473
  <rect x="1" y="1" width="22" height="12"
2982
2474
  fill="${e}" fill-opacity="${n}"
2983
2475
  stroke="${t}" stroke-width="1.5" rx="2"/>
2984
2476
  </svg>`;
2985
- return O`
2477
+ return _`
2986
2478
  <div class="legend-row">
2987
- ${i ? O`<button type="button" style="background:none;border:none;padding:0;cursor:pointer;display:flex;align-items:center" @click=${i}>${a}</button>` : a}
2988
- ${r === null ? "" : O`<span class="legend-label">${r}</span>`}
2479
+ ${i ? _`<button type="button" style="background:none;border:none;padding:0;cursor:pointer;display:flex;align-items:center" @click=${i}>${a}</button>` : a}
2480
+ ${r === null ? "" : _`<span class="legend-label">${r}</span>`}
2989
2481
  </div>`;
2990
2482
  }
2991
2483
  colorExprStopIndices(e) {
@@ -3015,30 +2507,30 @@ var Ee = /* @__PURE__ */ e((/* @__PURE__ */ t(((e, t) => {
3015
2507
  }, !1);
3016
2508
  }
3017
2509
  renderLineRow(e, t, n, r) {
3018
- return O`
2510
+ return _`
3019
2511
  <div class="legend-row">
3020
- ${A`<svg width="24" height="14" style="flex-shrink:0">
2512
+ ${y`<svg width="24" height="14" style="flex-shrink:0">
3021
2513
  <line x1="2" y1="7" x2="22" y2="7"
3022
2514
  stroke="${e}" stroke-width="${Math.min(t, 4)}"
3023
2515
  stroke-dasharray="${n}" stroke-linecap="round"/>
3024
2516
  </svg>`}
3025
- ${r === null ? "" : O`<span class="legend-label">${r}</span>`}
2517
+ ${r === null ? "" : _`<span class="legend-label">${r}</span>`}
3026
2518
  </div>`;
3027
2519
  }
3028
2520
  renderEditableLineRow(e, t, n, r, i, a, o) {
3029
- return O`
2521
+ return _`
3030
2522
  <div class="legend-row">
3031
2523
  <button type="button" class="color-swatch" style="background:transparent; border:none; padding:0; width:24px; height:14px; flex-shrink:0; cursor:pointer;"
3032
2524
  @click=${(n) => {
3033
2525
  n.stopPropagation(), this.openStopColorPicker(n.currentTarget, e, "line-color", a, o, t);
3034
2526
  }}>
3035
- ${A`<svg width="24" height="14">
2527
+ ${y`<svg width="24" height="14">
3036
2528
  <line x1="2" y1="7" x2="22" y2="7"
3037
2529
  stroke="${t}" stroke-width="${Math.min(n, 4)}"
3038
2530
  stroke-dasharray="${r}" stroke-linecap="round"/>
3039
2531
  </svg>`}
3040
2532
  </button>
3041
- ${i === null ? "" : O`<span class="legend-label">${i}</span>`}
2533
+ ${i === null ? "" : _`<span class="legend-label">${i}</span>`}
3042
2534
  </div>`;
3043
2535
  }
3044
2536
  getAttrTranslations() {
@@ -3215,14 +2707,14 @@ var Ee = /* @__PURE__ */ e((/* @__PURE__ */ t(((e, t) => {
3215
2707
  }
3216
2708
  openColorPicker(e, t, n, r, i, a = !0) {
3217
2709
  let o = `${t.join(",")}::${n}`, s = i ?? ((e) => this.setPaintOverride(t, n, e)), c = this.pickrInstances.get(o);
3218
- c ? (c.setColor(r), this.pickrOriginal.set(o, r)) : (c = Ee.default.create({
2710
+ c ? (c.setColor(r), this.pickrOriginal.set(o, r)) : (c = oe.default.create({
3219
2711
  el: e,
3220
2712
  theme: "nano",
3221
2713
  default: r,
3222
2714
  useAsButton: !0,
3223
2715
  comparison: !1,
3224
2716
  appClass: "webmapx-pickr",
3225
- swatches: De.COLOR_PALETTE,
2717
+ swatches: se.COLOR_PALETTE,
3226
2718
  components: {
3227
2719
  preview: !0,
3228
2720
  opacity: !0,
@@ -3268,7 +2760,7 @@ var Ee = /* @__PURE__ */ e((/* @__PURE__ */ t(((e, t) => {
3268
2760
  this.editOverrides = r, this.pendingPaintRaf === null && (this.pendingPaintRaf = requestAnimationFrame(() => this.flushPaintOverrides()));
3269
2761
  }
3270
2762
  renderRangeRow(e, t, n, r, i, a, o, s = "") {
3271
- return O`
2763
+ return _`
3272
2764
  <div class="style-editor-row">
3273
2765
  <label>${t}
3274
2766
  <input type="range" min=${i} max=${a} step=${o} .value=${String(r)}
@@ -3278,7 +2770,7 @@ var Ee = /* @__PURE__ */ e((/* @__PURE__ */ t(((e, t) => {
3278
2770
  </div>`;
3279
2771
  }
3280
2772
  renderColorRow(e, t, n, r) {
3281
- return O`
2773
+ return _`
3282
2774
  <div class="style-editor-row">
3283
2775
  <label>${t}</label>
3284
2776
  <button type="button" class="color-swatch" style="background:${r}"
@@ -3292,11 +2784,11 @@ var Ee = /* @__PURE__ */ e((/* @__PURE__ */ t(((e, t) => {
3292
2784
  let t = this.toCssColor(n["fill-outline-color"], i);
3293
2785
  s.push(this.renderColorRow(e, "outline color", "fill-outline-color", t));
3294
2786
  }
3295
- return s.push(this.renderRangeRow(e, "opacity", a, o, 0, 1, .05)), O`<div class="style-editor">${s}</div>`;
2787
+ return s.push(this.renderRangeRow(e, "opacity", a, o, 0, 1, .05)), _`<div class="style-editor">${s}</div>`;
3296
2788
  }
3297
2789
  if (t === "line") {
3298
2790
  let t = this.toCssColor(n["line-color"], "#000000"), r = Number(n["line-width"] ?? 2), i = Number(n["line-opacity"] ?? 1);
3299
- return O`<div class="style-editor">
2791
+ return _`<div class="style-editor">
3300
2792
  ${this.renderColorRow(e, "line color", "line-color", t)}
3301
2793
  ${this.renderRangeRow(e, "width", "line-width", r, .5, 10, .5, "px")}
3302
2794
  ${this.renderRangeRow(e, "opacity", "line-opacity", i, 0, 1, .05)}
@@ -3304,7 +2796,7 @@ var Ee = /* @__PURE__ */ e((/* @__PURE__ */ t(((e, t) => {
3304
2796
  }
3305
2797
  if (t === "circle") {
3306
2798
  let t = this.toCssColor(n["circle-color"], "#000000"), r = Number(n["circle-radius"] ?? 5), i = this.toCssColor(n["circle-stroke-color"], t), a = Number(n["circle-stroke-width"] ?? 0), o = Number(n["circle-opacity"] ?? 1);
3307
- return O`<div class="style-editor">
2799
+ return _`<div class="style-editor">
3308
2800
  ${this.renderRangeRow(e, "radius", "circle-radius", r, 1, 30, 1, "px")}
3309
2801
  ${this.renderColorRow(e, "fill color", "circle-color", t)}
3310
2802
  ${this.renderRangeRow(e, "opacity", "circle-opacity", o, 0, 1, .05)}
@@ -3314,17 +2806,17 @@ var Ee = /* @__PURE__ */ e((/* @__PURE__ */ t(((e, t) => {
3314
2806
  }
3315
2807
  if (t === "symbol") {
3316
2808
  let t = this.toCssColor(n["text-color"], "#1f2937"), r = Number(n["text-opacity"] ?? 1), i = Number(n["text-size"] ?? 12), a = n["text-halo-color"] !== void 0 || Number(n["text-halo-width"] ?? 0) > 0, o = this.toCssColor(n["text-halo-color"], "#ffffff");
3317
- return O`<div class="style-editor">
2809
+ return _`<div class="style-editor">
3318
2810
  ${this.renderRangeRow(e, "size", "text-size", i, 8, 32, 1, "px")}
3319
2811
  ${this.renderColorRow(e, "text color", "text-color", t)}
3320
2812
  ${this.renderRangeRow(e, "opacity", "text-opacity", r, 0, 1, .05)}
3321
2813
  ${a ? this.renderColorRow(e, "halo color", "text-halo-color", o) : ""}
3322
2814
  </div>`;
3323
2815
  }
3324
- return O``;
2816
+ return _``;
3325
2817
  }
3326
2818
  renderHillshadeTerrainCheckbox() {
3327
- return O`
2819
+ return _`
3328
2820
  <div class="style-editor-row" style="padding:2px 0">
3329
2821
  <input type="checkbox" id="hillshade-terrain-${this.layerId}" .checked=${this.terrainEnabled}
3330
2822
  @change=${(e) => this.toggleTerrainFromHillshade(e.target.checked)}>
@@ -3416,15 +2908,15 @@ var Ee = /* @__PURE__ */ e((/* @__PURE__ */ t(((e, t) => {
3416
2908
  return o && o.length === r.length ? this.renderEditableLineRow(e, u, c, a, l, t, o[s]) : this.renderLineRow(u, c, a, l);
3417
2909
  });
3418
2910
  }
3419
- return t === "symbol" ? [O`
2911
+ return t === "symbol" ? [_`
3420
2912
  <div class="legend-row">
3421
- ${A`<svg width="24" height="14" style="flex-shrink:0">
2913
+ ${y`<svg width="24" height="14" style="flex-shrink:0">
3422
2914
  <text x="12" y="11" text-anchor="middle" font-size="11"
3423
2915
  fill="${String(n["text-color"] ?? "#1f2937")}" font-family="sans-serif">A</text>
3424
2916
  </svg>`}
3425
- </div>`] : t === "raster" || t === "background" || t === "hillshade" ? [O`
2917
+ </div>`] : t === "raster" || t === "background" || t === "hillshade" ? [_`
3426
2918
  <div class="legend-row">
3427
- ${A`<svg width="24" height="14" style="flex-shrink:0">
2919
+ ${y`<svg width="24" height="14" style="flex-shrink:0">
3428
2920
  <defs>
3429
2921
  <pattern id="grid" width="4" height="4" patternUnits="userSpaceOnUse">
3430
2922
  <rect width="2" height="2" fill="#ccc"/>
@@ -3436,12 +2928,12 @@ var Ee = /* @__PURE__ */ e((/* @__PURE__ */ t(((e, t) => {
3436
2928
  </div>`] : [];
3437
2929
  }
3438
2930
  render() {
3439
- if (!this.layerId) return O``;
2931
+ if (!this.layerId) return _``;
3440
2932
  let e = this.meta, t = typeof e?.layerType == "string" ? e.layerType : null, n = e?.paint && typeof e.paint == "object" ? e.paint : {}, r = typeof e?.legendurl == "string" && e.legendurl.length > 0 ? e.legendurl : null, i = typeof e?.label == "string" ? e.label : this.layerId, a = Array.isArray(e?.sublayers) ? e.sublayers : null, o = typeof e?.minzoom == "number" ? e.minzoom : 0, s = typeof e?.maxzoom == "number" ? e.maxzoom : 24;
3441
2933
  if (this.zoom < o || this.zoom > s) return this.renderZoomHint(o, s, this.zoom);
3442
2934
  if (a && a.length > 0) {
3443
2935
  let e = this.renderCompositeLegend(a, this.zoom);
3444
- return a.length === 1 && typeof a[0]?.type == "string" && a[0].type === "hillshade" ? this.renderCollapsibleLegend(O`
2936
+ return a.length === 1 && typeof a[0]?.type == "string" && a[0].type === "hillshade" ? this.renderCollapsibleLegend(_`
3445
2937
  <div class="legend-wrap">
3446
2938
  ${e}
3447
2939
  ${this.renderHillshadeTerrainCheckbox()}
@@ -3462,9 +2954,9 @@ var Ee = /* @__PURE__ */ e((/* @__PURE__ */ t(((e, t) => {
3462
2954
  ...n,
3463
2955
  ...f
3464
2956
  } : n, m = !a && u && this.isEditableType(t, p), h = this.editorOpenKey === this.layerId;
3465
- return this.renderCollapsibleLegend(O`
2957
+ return this.renderCollapsibleLegend(_`
3466
2958
  <div class="legend-wrap">
3467
- ${u ? O`
2959
+ ${u ? _`
3468
2960
  <div class=${m ? "editable" : ""} @click=${m ? () => {
3469
2961
  this.editorOpenKey = h ? null : this.layerId;
3470
2962
  } : null}>
@@ -3473,7 +2965,7 @@ var Ee = /* @__PURE__ */ e((/* @__PURE__ */ t(((e, t) => {
3473
2965
  ${t === "hillshade" ? this.renderHillshadeTerrainCheckbox() : ""}
3474
2966
  ${m && h ? this.renderStyleEditor(d, t, p) : ""}
3475
2967
  ` : ""}
3476
- ${r ? O`
2968
+ ${r ? _`
3477
2969
  <img class="legend-img" src=${r} alt=${i}
3478
2970
  @error=${(e) => {
3479
2971
  let t = e.target, n = document.createElement("span");
@@ -3484,24 +2976,24 @@ var Ee = /* @__PURE__ */ e((/* @__PURE__ */ t(((e, t) => {
3484
2976
  `);
3485
2977
  }
3486
2978
  };
3487
- o([c({
2979
+ o([x({
3488
2980
  type: String,
3489
2981
  attribute: "layer-id"
3490
- })], I.prototype, "layerId", void 0), o([c({
2982
+ })], D.prototype, "layerId", void 0), o([x({
3491
2983
  type: Boolean,
3492
2984
  reflect: !0
3493
- })], I.prototype, "collapsible", void 0), o([l()], I.prototype, "meta", void 0), o([l()], I.prototype, "zoom", void 0), o([l()], I.prototype, "legendCollapsed", void 0), o([l()], I.prototype, "legendOverflowing", void 0), o([l()], I.prototype, "editOverrides", void 0), o([l()], I.prototype, "editorOpenKey", void 0), o([l()], I.prototype, "terrainEnabled", void 0), I = De = o([d("webmapx-layer-legend")], I);
2985
+ })], D.prototype, "collapsible", void 0), o([w()], D.prototype, "meta", void 0), o([w()], D.prototype, "zoom", void 0), o([w()], D.prototype, "legendCollapsed", void 0), o([w()], D.prototype, "legendOverflowing", void 0), o([w()], D.prototype, "editOverrides", void 0), o([w()], D.prototype, "editorOpenKey", void 0), o([w()], D.prototype, "terrainEnabled", void 0), D = se = o([b("webmapx-layer-legend")], D);
3494
2986
  //#endregion
3495
2987
  //#region node_modules/dompurify/dist/purify.es.mjs
3496
- function Oe(e, t) {
2988
+ function O(e, t) {
3497
2989
  (t == null || t > e.length) && (t = e.length);
3498
2990
  for (var n = 0, r = Array(t); n < t; n++) r[n] = e[n];
3499
2991
  return r;
3500
2992
  }
3501
- function ke(e) {
2993
+ function ce(e) {
3502
2994
  if (Array.isArray(e)) return e;
3503
2995
  }
3504
- function Ae(e, t) {
2996
+ function le(e, t) {
3505
2997
  var n = e == null ? null : typeof Symbol < "u" && e[Symbol.iterator] || e["@@iterator"];
3506
2998
  if (n != null) {
3507
2999
  var r, i, a, o, s = [], c = !0, l = !1;
@@ -3519,113 +3011,113 @@ function Ae(e, t) {
3519
3011
  return s;
3520
3012
  }
3521
3013
  }
3522
- function je() {
3014
+ function ue() {
3523
3015
  throw TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.");
3524
3016
  }
3525
- function Me(e, t) {
3526
- return ke(e) || Ae(e, t) || Ne(e, t) || je();
3017
+ function de(e, t) {
3018
+ return ce(e) || le(e, t) || fe(e, t) || ue();
3527
3019
  }
3528
- function Ne(e, t) {
3020
+ function fe(e, t) {
3529
3021
  if (e) {
3530
- if (typeof e == "string") return Oe(e, t);
3022
+ if (typeof e == "string") return O(e, t);
3531
3023
  var n = {}.toString.call(e).slice(8, -1);
3532
- return n === "Object" && e.constructor && (n = e.constructor.name), n === "Map" || n === "Set" ? Array.from(e) : n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n) ? Oe(e, t) : void 0;
3024
+ return n === "Object" && e.constructor && (n = e.constructor.name), n === "Map" || n === "Set" ? Array.from(e) : n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n) ? O(e, t) : void 0;
3533
3025
  }
3534
3026
  }
3535
- var Pe = Object.entries, Fe = Object.setPrototypeOf, Ie = Object.isFrozen, Le = Object.getPrototypeOf, L = Object.getOwnPropertyDescriptor, R = Object.freeze, z = Object.seal, Re = Object.create, ze = typeof Reflect < "u" && Reflect, Be = ze.apply, Ve = ze.construct;
3536
- R ||= function(e) {
3027
+ var pe = Object.entries, me = Object.setPrototypeOf, he = Object.isFrozen, ge = Object.getPrototypeOf, _e = Object.getOwnPropertyDescriptor, k = Object.freeze, A = Object.seal, ve = Object.create, j = typeof Reflect < "u" && Reflect, ye = j.apply, M = j.construct;
3028
+ k ||= function(e) {
3537
3029
  return e;
3538
- }, z ||= function(e) {
3030
+ }, A ||= function(e) {
3539
3031
  return e;
3540
- }, Be ||= function(e, t) {
3032
+ }, ye ||= function(e, t) {
3541
3033
  var n = [...arguments].slice(2);
3542
3034
  return e.apply(t, n);
3543
- }, Ve ||= function(e) {
3035
+ }, M ||= function(e) {
3544
3036
  return new e(...[...arguments].slice(1));
3545
3037
  };
3546
- var He = U(Array.prototype.forEach), Ue = U(Array.prototype.lastIndexOf), We = U(Array.prototype.pop), Ge = U(Array.prototype.push), Ke = U(Array.prototype.splice), qe = Array.isArray, Je = U(String.prototype.toLowerCase), Ye = U(String.prototype.toString), Xe = U(String.prototype.match), Ze = U(String.prototype.replace), Qe = U(String.prototype.indexOf), $e = U(String.prototype.trim), et = U(Number.prototype.toString), tt = U(Boolean.prototype.toString), nt = typeof BigInt > "u" ? null : U(BigInt.prototype.toString), rt = typeof Symbol > "u" ? null : U(Symbol.prototype.toString), B = U(Object.prototype.hasOwnProperty), V = U(Object.prototype.toString), H = U(RegExp.prototype.test), it = at(TypeError);
3547
- function U(e) {
3038
+ var be = L(Array.prototype.forEach), xe = L(Array.prototype.lastIndexOf), Se = L(Array.prototype.pop), Ce = L(Array.prototype.push), we = L(Array.prototype.splice), Te = Array.isArray, Ee = L(String.prototype.toLowerCase), De = L(String.prototype.toString), Oe = L(String.prototype.match), ke = L(String.prototype.replace), Ae = L(String.prototype.indexOf), je = L(String.prototype.trim), Me = L(Number.prototype.toString), N = L(Boolean.prototype.toString), Ne = typeof BigInt > "u" ? null : L(BigInt.prototype.toString), Pe = typeof Symbol > "u" ? null : L(Symbol.prototype.toString), P = L(Object.prototype.hasOwnProperty), F = L(Object.prototype.toString), I = L(RegExp.prototype.test), Fe = Ie(TypeError);
3039
+ function L(e) {
3548
3040
  return function(t) {
3549
3041
  t instanceof RegExp && (t.lastIndex = 0);
3550
3042
  var n = [...arguments].slice(1);
3551
- return Be(e, t, n);
3043
+ return ye(e, t, n);
3552
3044
  };
3553
3045
  }
3554
- function at(e) {
3046
+ function Ie(e) {
3555
3047
  return function() {
3556
- return Ve(e, [...arguments]);
3048
+ return M(e, [...arguments]);
3557
3049
  };
3558
3050
  }
3559
- function W(e, t) {
3560
- let n = arguments.length > 2 && arguments[2] !== void 0 ? arguments[2] : Je;
3561
- if (Fe && Fe(e, null), !qe(t)) return e;
3051
+ function R(e, t) {
3052
+ let n = arguments.length > 2 && arguments[2] !== void 0 ? arguments[2] : Ee;
3053
+ if (me && me(e, null), !Te(t)) return e;
3562
3054
  let r = t.length;
3563
3055
  for (; r--;) {
3564
3056
  let i = t[r];
3565
3057
  if (typeof i == "string") {
3566
3058
  let e = n(i);
3567
- e !== i && (Ie(t) || (t[r] = e), i = e);
3059
+ e !== i && (he(t) || (t[r] = e), i = e);
3568
3060
  }
3569
3061
  e[i] = !0;
3570
3062
  }
3571
3063
  return e;
3572
3064
  }
3573
- function ot(e) {
3574
- for (let t = 0; t < e.length; t++) B(e, t) || (e[t] = null);
3065
+ function Le(e) {
3066
+ for (let t = 0; t < e.length; t++) P(e, t) || (e[t] = null);
3575
3067
  return e;
3576
3068
  }
3577
- function G(e) {
3578
- let t = Re(null);
3579
- for (let r of Pe(e)) {
3580
- var n = Me(r, 2);
3069
+ function z(e) {
3070
+ let t = ve(null);
3071
+ for (let r of pe(e)) {
3072
+ var n = de(r, 2);
3581
3073
  let i = n[0], a = n[1];
3582
- B(e, i) && (qe(a) ? t[i] = ot(a) : a && typeof a == "object" && a.constructor === Object ? t[i] = G(a) : t[i] = a);
3074
+ P(e, i) && (Te(a) ? t[i] = Le(a) : a && typeof a == "object" && a.constructor === Object ? t[i] = z(a) : t[i] = a);
3583
3075
  }
3584
3076
  return t;
3585
3077
  }
3586
- function st(e) {
3078
+ function Re(e) {
3587
3079
  switch (typeof e) {
3588
3080
  case "string": return e;
3589
- case "number": return et(e);
3590
- case "boolean": return tt(e);
3591
- case "bigint": return nt ? nt(e) : "0";
3592
- case "symbol": return rt ? rt(e) : "Symbol()";
3593
- case "undefined": return V(e);
3081
+ case "number": return Me(e);
3082
+ case "boolean": return N(e);
3083
+ case "bigint": return Ne ? Ne(e) : "0";
3084
+ case "symbol": return Pe ? Pe(e) : "Symbol()";
3085
+ case "undefined": return F(e);
3594
3086
  case "function":
3595
3087
  case "object": {
3596
- if (e === null) return V(e);
3597
- let t = e, n = ct(t, "toString");
3088
+ if (e === null) return F(e);
3089
+ let t = e, n = B(t, "toString");
3598
3090
  if (typeof n == "function") {
3599
3091
  let e = n(t);
3600
- return typeof e == "string" ? e : V(e);
3092
+ return typeof e == "string" ? e : F(e);
3601
3093
  }
3602
- return V(e);
3094
+ return F(e);
3603
3095
  }
3604
- default: return V(e);
3096
+ default: return F(e);
3605
3097
  }
3606
3098
  }
3607
- function ct(e, t) {
3099
+ function B(e, t) {
3608
3100
  for (; e !== null;) {
3609
- let n = L(e, t);
3101
+ let n = _e(e, t);
3610
3102
  if (n) {
3611
- if (n.get) return U(n.get);
3612
- if (typeof n.value == "function") return U(n.value);
3103
+ if (n.get) return L(n.get);
3104
+ if (typeof n.value == "function") return L(n.value);
3613
3105
  }
3614
- e = Le(e);
3106
+ e = ge(e);
3615
3107
  }
3616
3108
  function n() {
3617
3109
  return null;
3618
3110
  }
3619
3111
  return n;
3620
3112
  }
3621
- function lt(e) {
3113
+ function ze(e) {
3622
3114
  try {
3623
- return H(e, ""), !0;
3115
+ return I(e, ""), !0;
3624
3116
  } catch {
3625
3117
  return !1;
3626
3118
  }
3627
3119
  }
3628
- var ut = R(/* @__PURE__ */ "a.abbr.acronym.address.area.article.aside.audio.b.bdi.bdo.big.blink.blockquote.body.br.button.canvas.caption.center.cite.code.col.colgroup.content.data.datalist.dd.decorator.del.details.dfn.dialog.dir.div.dl.dt.element.em.fieldset.figcaption.figure.font.footer.form.h1.h2.h3.h4.h5.h6.head.header.hgroup.hr.html.i.img.input.ins.kbd.label.legend.li.main.map.mark.marquee.menu.menuitem.meter.nav.nobr.ol.optgroup.option.output.p.picture.pre.progress.q.rp.rt.ruby.s.samp.search.section.select.shadow.slot.small.source.spacer.span.strike.strong.style.sub.summary.sup.table.tbody.td.template.textarea.tfoot.th.thead.time.tr.track.tt.u.ul.var.video.wbr".split(".")), dt = R(/* @__PURE__ */ "svg.a.altglyph.altglyphdef.altglyphitem.animatecolor.animatemotion.animatetransform.circle.clippath.defs.desc.ellipse.enterkeyhint.exportparts.filter.font.g.glyph.glyphref.hkern.image.inputmode.line.lineargradient.marker.mask.metadata.mpath.part.path.pattern.polygon.polyline.radialgradient.rect.stop.style.switch.symbol.text.textpath.title.tref.tspan.view.vkern".split(".")), ft = R([
3120
+ var Be = k(/* @__PURE__ */ "a.abbr.acronym.address.area.article.aside.audio.b.bdi.bdo.big.blink.blockquote.body.br.button.canvas.caption.center.cite.code.col.colgroup.content.data.datalist.dd.decorator.del.details.dfn.dialog.dir.div.dl.dt.element.em.fieldset.figcaption.figure.font.footer.form.h1.h2.h3.h4.h5.h6.head.header.hgroup.hr.html.i.img.input.ins.kbd.label.legend.li.main.map.mark.marquee.menu.menuitem.meter.nav.nobr.ol.optgroup.option.output.p.picture.pre.progress.q.rp.rt.ruby.s.samp.search.section.select.shadow.slot.small.source.spacer.span.strike.strong.style.sub.summary.sup.table.tbody.td.template.textarea.tfoot.th.thead.time.tr.track.tt.u.ul.var.video.wbr".split(".")), Ve = k(/* @__PURE__ */ "svg.a.altglyph.altglyphdef.altglyphitem.animatecolor.animatemotion.animatetransform.circle.clippath.defs.desc.ellipse.enterkeyhint.exportparts.filter.font.g.glyph.glyphref.hkern.image.inputmode.line.lineargradient.marker.mask.metadata.mpath.part.path.pattern.polygon.polyline.radialgradient.rect.stop.style.switch.symbol.text.textpath.title.tref.tspan.view.vkern".split(".")), He = k([
3629
3121
  "feBlend",
3630
3122
  "feColorMatrix",
3631
3123
  "feComponentTransfer",
@@ -3651,7 +3143,7 @@ var ut = R(/* @__PURE__ */ "a.abbr.acronym.address.area.article.aside.audio.b.bd
3651
3143
  "feSpotLight",
3652
3144
  "feTile",
3653
3145
  "feTurbulence"
3654
- ]), pt = R([
3146
+ ]), Ue = k([
3655
3147
  "animate",
3656
3148
  "color-profile",
3657
3149
  "cursor",
@@ -3674,7 +3166,7 @@ var ut = R(/* @__PURE__ */ "a.abbr.acronym.address.area.article.aside.audio.b.bd
3674
3166
  "solidcolor",
3675
3167
  "unknown",
3676
3168
  "use"
3677
- ]), mt = R(/* @__PURE__ */ "math.menclose.merror.mfenced.mfrac.mglyph.mi.mlabeledtr.mmultiscripts.mn.mo.mover.mpadded.mphantom.mroot.mrow.ms.mspace.msqrt.mstyle.msub.msup.msubsup.mtable.mtd.mtext.mtr.munder.munderover.mprescripts".split(".")), ht = R([
3169
+ ]), We = k(/* @__PURE__ */ "math.menclose.merror.mfenced.mfrac.mglyph.mi.mlabeledtr.mmultiscripts.mn.mo.mover.mpadded.mphantom.mroot.mrow.ms.mspace.msqrt.mstyle.msub.msup.msubsup.mtable.mtd.mtext.mtr.munder.munderover.mprescripts".split(".")), Ge = k([
3678
3170
  "maction",
3679
3171
  "maligngroup",
3680
3172
  "malignmark",
@@ -3690,13 +3182,13 @@ var ut = R(/* @__PURE__ */ "a.abbr.acronym.address.area.article.aside.audio.b.bd
3690
3182
  "annotation-xml",
3691
3183
  "mprescripts",
3692
3184
  "none"
3693
- ]), gt = R(["#text"]), _t = R(/* @__PURE__ */ "accept.action.align.alt.autocapitalize.autocomplete.autopictureinpicture.autoplay.background.bgcolor.border.capture.cellpadding.cellspacing.checked.cite.class.clear.color.cols.colspan.command.commandfor.controls.controlslist.coords.crossorigin.datetime.decoding.default.dir.disabled.disablepictureinpicture.disableremoteplayback.download.draggable.enctype.enterkeyhint.exportparts.face.for.headers.height.hidden.high.href.hreflang.id.inert.inputmode.integrity.ismap.kind.label.lang.list.loading.loop.low.max.maxlength.media.method.min.minlength.multiple.muted.name.nonce.noshade.novalidate.nowrap.open.optimum.part.pattern.placeholder.playsinline.popover.popovertarget.popovertargetaction.poster.preload.pubdate.radiogroup.readonly.rel.required.rev.reversed.role.rows.rowspan.spellcheck.scope.selected.shape.size.sizes.slot.span.srclang.start.src.srcset.step.style.summary.tabindex.title.translate.type.usemap.valign.value.width.wrap.xmlns".split(".")), vt = R(/* @__PURE__ */ "accent-height.accumulate.additive.alignment-baseline.amplitude.ascent.attributename.attributetype.azimuth.basefrequency.baseline-shift.begin.bias.by.class.clip.clippathunits.clip-path.clip-rule.color.color-interpolation.color-interpolation-filters.color-profile.color-rendering.cx.cy.d.dx.dy.diffuseconstant.direction.display.divisor.dur.edgemode.elevation.end.exponent.fill.fill-opacity.fill-rule.filter.filterunits.flood-color.flood-opacity.font-family.font-size.font-size-adjust.font-stretch.font-style.font-variant.font-weight.fx.fy.g1.g2.glyph-name.glyphref.gradientunits.gradienttransform.height.href.id.image-rendering.in.in2.intercept.k.k1.k2.k3.k4.kerning.keypoints.keysplines.keytimes.lang.lengthadjust.letter-spacing.kernelmatrix.kernelunitlength.lighting-color.local.marker-end.marker-mid.marker-start.markerheight.markerunits.markerwidth.maskcontentunits.maskunits.max.mask.mask-type.media.method.mode.min.name.numoctaves.offset.operator.opacity.order.orient.orientation.origin.overflow.paint-order.path.pathlength.patterncontentunits.patterntransform.patternunits.points.preservealpha.preserveaspectratio.primitiveunits.r.rx.ry.radius.refx.refy.repeatcount.repeatdur.restart.result.rotate.scale.seed.shape-rendering.slope.specularconstant.specularexponent.spreadmethod.startoffset.stddeviation.stitchtiles.stop-color.stop-opacity.stroke-dasharray.stroke-dashoffset.stroke-linecap.stroke-linejoin.stroke-miterlimit.stroke-opacity.stroke.stroke-width.style.surfacescale.systemlanguage.tabindex.tablevalues.targetx.targety.transform.transform-origin.text-anchor.text-decoration.text-rendering.textlength.type.u1.u2.unicode.values.viewbox.visibility.version.vert-adv-y.vert-origin-x.vert-origin-y.width.word-spacing.wrap.writing-mode.xchannelselector.ychannelselector.x.x1.x2.xmlns.y.y1.y2.z.zoomandpan".split(".")), yt = R(/* @__PURE__ */ "accent.accentunder.align.bevelled.close.columnalign.columnlines.columnspacing.columnspan.denomalign.depth.dir.display.displaystyle.encoding.fence.frame.height.href.id.largeop.length.linethickness.lquote.lspace.mathbackground.mathcolor.mathsize.mathvariant.maxsize.minsize.movablelimits.notation.numalign.open.rowalign.rowlines.rowspacing.rowspan.rspace.rquote.scriptlevel.scriptminsize.scriptsizemultiplier.selection.separator.separators.stretchy.subscriptshift.supscriptshift.symmetric.voffset.width.xmlns".split(".")), bt = R([
3185
+ ]), Ke = k(["#text"]), qe = k(/* @__PURE__ */ "accept.action.align.alt.autocapitalize.autocomplete.autopictureinpicture.autoplay.background.bgcolor.border.capture.cellpadding.cellspacing.checked.cite.class.clear.color.cols.colspan.command.commandfor.controls.controlslist.coords.crossorigin.datetime.decoding.default.dir.disabled.disablepictureinpicture.disableremoteplayback.download.draggable.enctype.enterkeyhint.exportparts.face.for.headers.height.hidden.high.href.hreflang.id.inert.inputmode.integrity.ismap.kind.label.lang.list.loading.loop.low.max.maxlength.media.method.min.minlength.multiple.muted.name.nonce.noshade.novalidate.nowrap.open.optimum.part.pattern.placeholder.playsinline.popover.popovertarget.popovertargetaction.poster.preload.pubdate.radiogroup.readonly.rel.required.rev.reversed.role.rows.rowspan.spellcheck.scope.selected.shape.size.sizes.slot.span.srclang.start.src.srcset.step.style.summary.tabindex.title.translate.type.usemap.valign.value.width.wrap.xmlns".split(".")), Je = k(/* @__PURE__ */ "accent-height.accumulate.additive.alignment-baseline.amplitude.ascent.attributename.attributetype.azimuth.basefrequency.baseline-shift.begin.bias.by.class.clip.clippathunits.clip-path.clip-rule.color.color-interpolation.color-interpolation-filters.color-profile.color-rendering.cx.cy.d.dx.dy.diffuseconstant.direction.display.divisor.dur.edgemode.elevation.end.exponent.fill.fill-opacity.fill-rule.filter.filterunits.flood-color.flood-opacity.font-family.font-size.font-size-adjust.font-stretch.font-style.font-variant.font-weight.fx.fy.g1.g2.glyph-name.glyphref.gradientunits.gradienttransform.height.href.id.image-rendering.in.in2.intercept.k.k1.k2.k3.k4.kerning.keypoints.keysplines.keytimes.lang.lengthadjust.letter-spacing.kernelmatrix.kernelunitlength.lighting-color.local.marker-end.marker-mid.marker-start.markerheight.markerunits.markerwidth.maskcontentunits.maskunits.max.mask.mask-type.media.method.mode.min.name.numoctaves.offset.operator.opacity.order.orient.orientation.origin.overflow.paint-order.path.pathlength.patterncontentunits.patterntransform.patternunits.points.preservealpha.preserveaspectratio.primitiveunits.r.rx.ry.radius.refx.refy.repeatcount.repeatdur.restart.result.rotate.scale.seed.shape-rendering.slope.specularconstant.specularexponent.spreadmethod.startoffset.stddeviation.stitchtiles.stop-color.stop-opacity.stroke-dasharray.stroke-dashoffset.stroke-linecap.stroke-linejoin.stroke-miterlimit.stroke-opacity.stroke.stroke-width.style.surfacescale.systemlanguage.tabindex.tablevalues.targetx.targety.transform.transform-origin.text-anchor.text-decoration.text-rendering.textlength.type.u1.u2.unicode.values.viewbox.visibility.version.vert-adv-y.vert-origin-x.vert-origin-y.width.word-spacing.wrap.writing-mode.xchannelselector.ychannelselector.x.x1.x2.xmlns.y.y1.y2.z.zoomandpan".split(".")), Ye = k(/* @__PURE__ */ "accent.accentunder.align.bevelled.close.columnalign.columnlines.columnspacing.columnspan.denomalign.depth.dir.display.displaystyle.encoding.fence.frame.height.href.id.largeop.length.linethickness.lquote.lspace.mathbackground.mathcolor.mathsize.mathvariant.maxsize.minsize.movablelimits.notation.numalign.open.rowalign.rowlines.rowspacing.rowspan.rspace.rquote.scriptlevel.scriptminsize.scriptsizemultiplier.selection.separator.separators.stretchy.subscriptshift.supscriptshift.symmetric.voffset.width.xmlns".split(".")), Xe = k([
3694
3186
  "xlink:href",
3695
3187
  "xml:id",
3696
3188
  "xlink:title",
3697
3189
  "xml:space",
3698
3190
  "xmlns:xlink"
3699
- ]), xt = z(/{{[\w\W]*|^[\w\W]*}}/g), St = z(/<%[\w\W]*|^[\w\W]*%>/g), Ct = z(/\${[\w\W]*/g), wt = z(/^data-[\-\w.\u00B7-\uFFFF]+$/), Tt = z(/^aria-[\-\w]+$/), Et = z(/^(?:(?:(?:f|ht)tps?|mailto|tel|callto|sms|cid|xmpp|matrix):|[^a-z]|[a-z+.\-]+(?:[^a-z+.\-:]|$))/i), Dt = z(/^(?:\w+script|data):/i), Ot = z(/[\u0000-\u0020\u00A0\u1680\u180E\u2000-\u2029\u205F\u3000]/g), kt = z(/^html$/i), At = z(/^[a-z][.\w]*(-[.\w]+)+$/i), jt = z(/<[/\w!]/g), Mt = z(/<[/\w]/g), Nt = z(/<\/no(script|embed|frames)/i), Pt = z(/\/>/i), Ft = {
3191
+ ]), Ze = A(/{{[\w\W]*|^[\w\W]*}}/g), Qe = A(/<%[\w\W]*|^[\w\W]*%>/g), $e = A(/\${[\w\W]*/g), et = A(/^data-[\-\w.\u00B7-\uFFFF]+$/), tt = A(/^aria-[\-\w]+$/), nt = A(/^(?:(?:(?:f|ht)tps?|mailto|tel|callto|sms|cid|xmpp|matrix):|[^a-z]|[a-z+.\-]+(?:[^a-z+.\-:]|$))/i), rt = A(/^(?:\w+script|data):/i), it = A(/[\u0000-\u0020\u00A0\u1680\u180E\u2000-\u2029\u205F\u3000]/g), at = A(/^html$/i), ot = A(/^[a-z][.\w]*(-[.\w]+)+$/i), st = A(/<[/\w!]/g), ct = A(/<[/\w]/g), lt = A(/<\/no(script|embed|frames)/i), ut = A(/\/>/i), V = {
3700
3192
  element: 1,
3701
3193
  attribute: 2,
3702
3194
  text: 3,
@@ -3709,9 +3201,9 @@ var ut = R(/* @__PURE__ */ "a.abbr.acronym.address.area.article.aside.audio.b.bd
3709
3201
  documentType: 10,
3710
3202
  documentFragment: 11,
3711
3203
  notation: 12
3712
- }, It = function() {
3204
+ }, dt = function() {
3713
3205
  return typeof window > "u" ? null : window;
3714
- }, Lt = function(e, t) {
3206
+ }, ft = function(e, t) {
3715
3207
  if (typeof e != "object" || typeof e.createPolicy != "function") return null;
3716
3208
  let n = null, r = "data-tt-policy-suffix";
3717
3209
  t && t.hasAttribute(r) && (n = t.getAttribute(r));
@@ -3728,7 +3220,7 @@ var ut = R(/* @__PURE__ */ "a.abbr.acronym.address.area.article.aside.audio.b.bd
3728
3220
  } catch {
3729
3221
  return console.warn("TrustedTypes policy " + i + " could not be created."), null;
3730
3222
  }
3731
- }, Rt = function() {
3223
+ }, pt = function() {
3732
3224
  return {
3733
3225
  afterSanitizeAttributes: [],
3734
3226
  afterSanitizeElements: [],
@@ -3740,53 +3232,53 @@ var ut = R(/* @__PURE__ */ "a.abbr.acronym.address.area.article.aside.audio.b.bd
3740
3232
  uponSanitizeElement: [],
3741
3233
  uponSanitizeShadowNode: []
3742
3234
  };
3743
- }, zt = function(e, t, n, r) {
3744
- return B(e, t) && qe(e[t]) ? W(r.base ? G(r.base) : {}, e[t], r.transform) : n;
3235
+ }, mt = function(e, t, n, r) {
3236
+ return P(e, t) && Te(e[t]) ? R(r.base ? z(r.base) : {}, e[t], r.transform) : n;
3745
3237
  };
3746
- function Bt() {
3747
- let e = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : It(), t = (e) => Bt(e);
3748
- if (t.version = "3.4.11", t.removed = [], !e || !e.document || e.document.nodeType !== Ft.document || !e.Element) return t.isSupported = !1, t;
3238
+ function ht() {
3239
+ let e = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : dt(), t = (e) => ht(e);
3240
+ if (t.version = "3.4.11", t.removed = [], !e || !e.document || e.document.nodeType !== V.document || !e.Element) return t.isSupported = !1, t;
3749
3241
  let n = e.document, r = n, i = r.currentScript;
3750
3242
  e.DocumentFragment;
3751
3243
  let a = e.HTMLTemplateElement, o = e.Node, s = e.Element, c = e.NodeFilter;
3752
3244
  e.NamedNodeMap === void 0 && (e.NamedNodeMap || e.MozNamedAttrMap), e.HTMLFormElement;
3753
- let l = e.DOMParser, u = e.trustedTypes, d = s.prototype, f = ct(d, "cloneNode"), p = ct(d, "remove"), m = ct(d, "nextSibling"), h = ct(d, "childNodes"), g = ct(d, "parentNode"), _ = ct(d, "shadowRoot"), v = ct(d, "attributes"), y = o && o.prototype ? ct(o.prototype, "nodeType") : null, b = o && o.prototype ? ct(o.prototype, "nodeName") : null;
3245
+ let l = e.DOMParser, u = e.trustedTypes, d = s.prototype, f = B(d, "cloneNode"), p = B(d, "remove"), m = B(d, "nextSibling"), h = B(d, "childNodes"), g = B(d, "parentNode"), _ = B(d, "shadowRoot"), v = B(d, "attributes"), y = o && o.prototype ? B(o.prototype, "nodeType") : null, b = o && o.prototype ? B(o.prototype, "nodeName") : null;
3754
3246
  if (typeof a == "function") {
3755
3247
  let e = n.createElement("template");
3756
3248
  e.content && e.content.ownerDocument && (n = e.content.ownerDocument);
3757
3249
  }
3758
- let x, S = "", C, ee = !1, w = 0, te = function() {
3759
- if (w > 0) throw it("A configured TRUSTED_TYPES_POLICY callback (createHTML or createScriptURL) must not call DOMPurify.sanitize, as that causes infinite recursion. Do not pass a policy whose callbacks wrap DOMPurify as TRUSTED_TYPES_POLICY; see the \"DOMPurify and Trusted Types\" section of the README.");
3760
- }, ne = function(e) {
3761
- te(), w++;
3250
+ let x, S = "", C, w = !1, ee = 0, te = function() {
3251
+ if (ee > 0) throw Fe("A configured TRUSTED_TYPES_POLICY callback (createHTML or createScriptURL) must not call DOMPurify.sanitize, as that causes infinite recursion. Do not pass a policy whose callbacks wrap DOMPurify as TRUSTED_TYPES_POLICY; see the \"DOMPurify and Trusted Types\" section of the README.");
3252
+ }, T = function(e) {
3253
+ te(), ee++;
3762
3254
  try {
3763
3255
  return x.createHTML(e);
3764
3256
  } finally {
3765
- w--;
3257
+ ee--;
3766
3258
  }
3767
- }, re = function(e) {
3768
- te(), w++;
3259
+ }, ne = function(e) {
3260
+ te(), ee++;
3769
3261
  try {
3770
3262
  return x.createScriptURL(e);
3771
3263
  } finally {
3772
- w--;
3773
- }
3774
- }, ie = function() {
3775
- return ee ||= (C = Lt(u, i), !0), C;
3776
- }, ae = n, oe = ae.implementation, se = ae.createNodeIterator, ce = ae.createDocumentFragment, le = ae.getElementsByTagName, ue = r.importNode, T = Rt();
3777
- t.isSupported = typeof Pe == "function" && typeof g == "function" && oe && oe.createHTMLDocument !== void 0;
3778
- let de = xt, fe = St, pe = Ct, me = wt, he = Tt, ge = Dt, E = Ot, D = At, O = Et, k = null, A = W({}, [
3779
- ...ut,
3780
- ...dt,
3781
- ...ft,
3782
- ...mt,
3783
- ...gt
3784
- ]), j = null, _e = W({}, [
3785
- ..._t,
3786
- ...vt,
3787
- ...yt,
3788
- ...bt
3789
- ]), M = Object.seal(Re(null, {
3264
+ ee--;
3265
+ }
3266
+ }, re = function() {
3267
+ return w ||= (C = ft(u, i), !0), C;
3268
+ }, ie = n, ae = ie.implementation, E = ie.createNodeIterator, oe = ie.createDocumentFragment, se = ie.getElementsByTagName, D = r.importNode, O = pt();
3269
+ t.isSupported = typeof pe == "function" && typeof g == "function" && ae && ae.createHTMLDocument !== void 0;
3270
+ let ce = Ze, le = Qe, ue = $e, de = et, fe = tt, me = rt, he = it, ge = ot, _e = nt, j = null, ye = R({}, [
3271
+ ...Be,
3272
+ ...Ve,
3273
+ ...He,
3274
+ ...We,
3275
+ ...Ke
3276
+ ]), M = null, Me = R({}, [
3277
+ ...qe,
3278
+ ...Je,
3279
+ ...Ye,
3280
+ ...Xe
3281
+ ]), N = Object.seal(ve(null, {
3790
3282
  tagNameCheck: {
3791
3283
  writable: !0,
3792
3284
  configurable: !1,
@@ -3805,7 +3297,7 @@ function Bt() {
3805
3297
  enumerable: !0,
3806
3298
  value: !1
3807
3299
  }
3808
- })), ve = null, ye = null, N = Object.seal(Re(null, {
3300
+ })), Ne = null, Pe = null, F = Object.seal(ve(null, {
3809
3301
  tagCheck: {
3810
3302
  writable: !0,
3811
3303
  configurable: !1,
@@ -3818,14 +3310,14 @@ function Bt() {
3818
3310
  enumerable: !0,
3819
3311
  value: null
3820
3312
  }
3821
- })), be = !0, xe = !0, P = !1, Se = !0, Ce = !1, we = !0, F = !1, Te = !1, Ee = null, De = null, I = !1, Oe = !1, ke = !1, Ae = !1, je = !0, Me = !1, Ne = "user-content-", Fe = !0, Ie = !1, Le = {}, L = null, ze = W({}, /* @__PURE__ */ "annotation-xml.audio.colgroup.desc.foreignobject.head.iframe.math.mi.mn.mo.ms.mtext.noembed.noframes.noscript.plaintext.script.selectedcontent.style.svg.template.thead.title.video.xmp".split(".")), Be = null, Ve = W({}, [
3313
+ })), L = !0, Ie = !0, Le = !1, gt = !0, H = !1, _t = !0, vt = !1, yt = !1, U = null, W = null, bt = !1, G = !1, K = !1, q = !1, xt = !0, St = !1, Ct = "user-content-", wt = !0, Tt = !1, Et = {}, J = null, Dt = R({}, /* @__PURE__ */ "annotation-xml.audio.colgroup.desc.foreignobject.head.iframe.math.mi.mn.mo.ms.mtext.noembed.noframes.noscript.plaintext.script.selectedcontent.style.svg.template.thead.title.video.xmp".split(".")), Y = null, Ot = R({}, [
3822
3314
  "audio",
3823
3315
  "video",
3824
3316
  "img",
3825
3317
  "source",
3826
3318
  "image",
3827
3319
  "track"
3828
- ]), et = null, tt = W({}, [
3320
+ ]), X = null, kt = R({}, [
3829
3321
  "alt",
3830
3322
  "class",
3831
3323
  "for",
@@ -3840,83 +3332,83 @@ function Bt() {
3840
3332
  "value",
3841
3333
  "style",
3842
3334
  "xmlns"
3843
- ]), nt = "http://www.w3.org/1998/Math/MathML", rt = "http://www.w3.org/2000/svg", V = "http://www.w3.org/1999/xhtml", U = V, at = !1, ot = null, Vt = W({}, [
3844
- nt,
3845
- rt,
3846
- V
3847
- ], Ye), Ht = R([
3335
+ ]), At = "http://www.w3.org/1998/Math/MathML", jt = "http://www.w3.org/2000/svg", Z = "http://www.w3.org/1999/xhtml", Mt = Z, Nt = !1, Pt = null, Ft = R({}, [
3336
+ At,
3337
+ jt,
3338
+ Z
3339
+ ], De), It = k([
3848
3340
  "mi",
3849
3341
  "mo",
3850
3342
  "mn",
3851
3343
  "ms",
3852
3344
  "mtext"
3853
- ]), Ut = W({}, Ht), Wt = R(["annotation-xml"]), Gt = W({}, Wt), Kt = W({}, [
3345
+ ]), Lt = R({}, It), Rt = k(["annotation-xml"]), zt = R({}, Rt), Bt = R({}, [
3854
3346
  "title",
3855
3347
  "style",
3856
3348
  "font",
3857
3349
  "a",
3858
3350
  "script"
3859
- ]), K = null, qt = ["application/xhtml+xml", "text/html"], q = null, J = null, Jt = n.createElement("form"), Yt = function(e) {
3351
+ ]), Vt = null, Ht = ["application/xhtml+xml", "text/html"], Q = null, Ut = null, Wt = n.createElement("form"), Gt = function(e) {
3860
3352
  return e instanceof RegExp || e instanceof Function;
3861
- }, Xt = function() {
3353
+ }, $ = function() {
3862
3354
  let e = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : {};
3863
- if (J && J === e) return;
3864
- (!e || typeof e != "object") && (e = {}), e = G(e), K = qt.indexOf(e.PARSER_MEDIA_TYPE) === -1 ? "text/html" : e.PARSER_MEDIA_TYPE, q = K === "application/xhtml+xml" ? Ye : Je, k = zt(e, "ALLOWED_TAGS", A, { transform: q }), j = zt(e, "ALLOWED_ATTR", _e, { transform: q }), ot = zt(e, "ALLOWED_NAMESPACES", Vt, { transform: Ye }), et = zt(e, "ADD_URI_SAFE_ATTR", tt, {
3865
- transform: q,
3866
- base: tt
3867
- }), Be = zt(e, "ADD_DATA_URI_TAGS", Ve, {
3868
- transform: q,
3869
- base: Ve
3870
- }), L = zt(e, "FORBID_CONTENTS", ze, { transform: q }), ve = zt(e, "FORBID_TAGS", G({}), { transform: q }), ye = zt(e, "FORBID_ATTR", G({}), { transform: q }), Le = B(e, "USE_PROFILES") ? e.USE_PROFILES && typeof e.USE_PROFILES == "object" ? G(e.USE_PROFILES) : e.USE_PROFILES : !1, be = e.ALLOW_ARIA_ATTR !== !1, xe = e.ALLOW_DATA_ATTR !== !1, P = e.ALLOW_UNKNOWN_PROTOCOLS || !1, Se = e.ALLOW_SELF_CLOSE_IN_ATTR !== !1, Ce = e.SAFE_FOR_TEMPLATES || !1, we = e.SAFE_FOR_XML !== !1, F = e.WHOLE_DOCUMENT || !1, Oe = e.RETURN_DOM || !1, ke = e.RETURN_DOM_FRAGMENT || !1, Ae = e.RETURN_TRUSTED_TYPE || !1, I = e.FORCE_BODY || !1, je = e.SANITIZE_DOM !== !1, Me = e.SANITIZE_NAMED_PROPS || !1, Fe = e.KEEP_CONTENT !== !1, Ie = e.IN_PLACE || !1, O = lt(e.ALLOWED_URI_REGEXP) ? e.ALLOWED_URI_REGEXP : Et, U = typeof e.NAMESPACE == "string" ? e.NAMESPACE : V, Ut = B(e, "MATHML_TEXT_INTEGRATION_POINTS") && e.MATHML_TEXT_INTEGRATION_POINTS && typeof e.MATHML_TEXT_INTEGRATION_POINTS == "object" ? G(e.MATHML_TEXT_INTEGRATION_POINTS) : W({}, Ht), Gt = B(e, "HTML_INTEGRATION_POINTS") && e.HTML_INTEGRATION_POINTS && typeof e.HTML_INTEGRATION_POINTS == "object" ? G(e.HTML_INTEGRATION_POINTS) : W({}, Wt);
3871
- let t = B(e, "CUSTOM_ELEMENT_HANDLING") && e.CUSTOM_ELEMENT_HANDLING && typeof e.CUSTOM_ELEMENT_HANDLING == "object" ? G(e.CUSTOM_ELEMENT_HANDLING) : Re(null);
3872
- if (M = Re(null), B(t, "tagNameCheck") && Yt(t.tagNameCheck) && (M.tagNameCheck = t.tagNameCheck), B(t, "attributeNameCheck") && Yt(t.attributeNameCheck) && (M.attributeNameCheck = t.attributeNameCheck), B(t, "allowCustomizedBuiltInElements") && typeof t.allowCustomizedBuiltInElements == "boolean" && (M.allowCustomizedBuiltInElements = t.allowCustomizedBuiltInElements), z(M), Ce && (xe = !1), ke && (Oe = !0), Le && (k = W({}, gt), j = Re(null), Le.html === !0 && (W(k, ut), W(j, _t)), Le.svg === !0 && (W(k, dt), W(j, vt), W(j, bt)), Le.svgFilters === !0 && (W(k, ft), W(j, vt), W(j, bt)), Le.mathMl === !0 && (W(k, mt), W(j, yt), W(j, bt))), N.tagCheck = null, N.attributeCheck = null, B(e, "ADD_TAGS") && (typeof e.ADD_TAGS == "function" ? N.tagCheck = e.ADD_TAGS : qe(e.ADD_TAGS) && (k === A && (k = G(k)), W(k, e.ADD_TAGS, q))), B(e, "ADD_ATTR") && (typeof e.ADD_ATTR == "function" ? N.attributeCheck = e.ADD_ATTR : qe(e.ADD_ATTR) && (j === _e && (j = G(j)), W(j, e.ADD_ATTR, q))), B(e, "ADD_URI_SAFE_ATTR") && qe(e.ADD_URI_SAFE_ATTR) && W(et, e.ADD_URI_SAFE_ATTR, q), B(e, "FORBID_CONTENTS") && qe(e.FORBID_CONTENTS) && (L === ze && (L = G(L)), W(L, e.FORBID_CONTENTS, q)), B(e, "ADD_FORBID_CONTENTS") && qe(e.ADD_FORBID_CONTENTS) && (L === ze && (L = G(L)), W(L, e.ADD_FORBID_CONTENTS, q)), Fe && (k["#text"] = !0), F && W(k, [
3355
+ if (Ut && Ut === e) return;
3356
+ (!e || typeof e != "object") && (e = {}), e = z(e), Vt = Ht.indexOf(e.PARSER_MEDIA_TYPE) === -1 ? "text/html" : e.PARSER_MEDIA_TYPE, Q = Vt === "application/xhtml+xml" ? De : Ee, j = mt(e, "ALLOWED_TAGS", ye, { transform: Q }), M = mt(e, "ALLOWED_ATTR", Me, { transform: Q }), Pt = mt(e, "ALLOWED_NAMESPACES", Ft, { transform: De }), X = mt(e, "ADD_URI_SAFE_ATTR", kt, {
3357
+ transform: Q,
3358
+ base: kt
3359
+ }), Y = mt(e, "ADD_DATA_URI_TAGS", Ot, {
3360
+ transform: Q,
3361
+ base: Ot
3362
+ }), J = mt(e, "FORBID_CONTENTS", Dt, { transform: Q }), Ne = mt(e, "FORBID_TAGS", z({}), { transform: Q }), Pe = mt(e, "FORBID_ATTR", z({}), { transform: Q }), Et = P(e, "USE_PROFILES") ? e.USE_PROFILES && typeof e.USE_PROFILES == "object" ? z(e.USE_PROFILES) : e.USE_PROFILES : !1, L = e.ALLOW_ARIA_ATTR !== !1, Ie = e.ALLOW_DATA_ATTR !== !1, Le = e.ALLOW_UNKNOWN_PROTOCOLS || !1, gt = e.ALLOW_SELF_CLOSE_IN_ATTR !== !1, H = e.SAFE_FOR_TEMPLATES || !1, _t = e.SAFE_FOR_XML !== !1, vt = e.WHOLE_DOCUMENT || !1, G = e.RETURN_DOM || !1, K = e.RETURN_DOM_FRAGMENT || !1, q = e.RETURN_TRUSTED_TYPE || !1, bt = e.FORCE_BODY || !1, xt = e.SANITIZE_DOM !== !1, St = e.SANITIZE_NAMED_PROPS || !1, wt = e.KEEP_CONTENT !== !1, Tt = e.IN_PLACE || !1, _e = ze(e.ALLOWED_URI_REGEXP) ? e.ALLOWED_URI_REGEXP : nt, Mt = typeof e.NAMESPACE == "string" ? e.NAMESPACE : Z, Lt = P(e, "MATHML_TEXT_INTEGRATION_POINTS") && e.MATHML_TEXT_INTEGRATION_POINTS && typeof e.MATHML_TEXT_INTEGRATION_POINTS == "object" ? z(e.MATHML_TEXT_INTEGRATION_POINTS) : R({}, It), zt = P(e, "HTML_INTEGRATION_POINTS") && e.HTML_INTEGRATION_POINTS && typeof e.HTML_INTEGRATION_POINTS == "object" ? z(e.HTML_INTEGRATION_POINTS) : R({}, Rt);
3363
+ let t = P(e, "CUSTOM_ELEMENT_HANDLING") && e.CUSTOM_ELEMENT_HANDLING && typeof e.CUSTOM_ELEMENT_HANDLING == "object" ? z(e.CUSTOM_ELEMENT_HANDLING) : ve(null);
3364
+ if (N = ve(null), P(t, "tagNameCheck") && Gt(t.tagNameCheck) && (N.tagNameCheck = t.tagNameCheck), P(t, "attributeNameCheck") && Gt(t.attributeNameCheck) && (N.attributeNameCheck = t.attributeNameCheck), P(t, "allowCustomizedBuiltInElements") && typeof t.allowCustomizedBuiltInElements == "boolean" && (N.allowCustomizedBuiltInElements = t.allowCustomizedBuiltInElements), A(N), H && (Ie = !1), K && (G = !0), Et && (j = R({}, Ke), M = ve(null), Et.html === !0 && (R(j, Be), R(M, qe)), Et.svg === !0 && (R(j, Ve), R(M, Je), R(M, Xe)), Et.svgFilters === !0 && (R(j, He), R(M, Je), R(M, Xe)), Et.mathMl === !0 && (R(j, We), R(M, Ye), R(M, Xe))), F.tagCheck = null, F.attributeCheck = null, P(e, "ADD_TAGS") && (typeof e.ADD_TAGS == "function" ? F.tagCheck = e.ADD_TAGS : Te(e.ADD_TAGS) && (j === ye && (j = z(j)), R(j, e.ADD_TAGS, Q))), P(e, "ADD_ATTR") && (typeof e.ADD_ATTR == "function" ? F.attributeCheck = e.ADD_ATTR : Te(e.ADD_ATTR) && (M === Me && (M = z(M)), R(M, e.ADD_ATTR, Q))), P(e, "ADD_URI_SAFE_ATTR") && Te(e.ADD_URI_SAFE_ATTR) && R(X, e.ADD_URI_SAFE_ATTR, Q), P(e, "FORBID_CONTENTS") && Te(e.FORBID_CONTENTS) && (J === Dt && (J = z(J)), R(J, e.FORBID_CONTENTS, Q)), P(e, "ADD_FORBID_CONTENTS") && Te(e.ADD_FORBID_CONTENTS) && (J === Dt && (J = z(J)), R(J, e.ADD_FORBID_CONTENTS, Q)), wt && (j["#text"] = !0), vt && R(j, [
3873
3365
  "html",
3874
3366
  "head",
3875
3367
  "body"
3876
- ]), k.table && (W(k, ["tbody"]), delete ve.tbody), e.TRUSTED_TYPES_POLICY) {
3877
- if (typeof e.TRUSTED_TYPES_POLICY.createHTML != "function") throw it("TRUSTED_TYPES_POLICY configuration option must provide a \"createHTML\" hook.");
3878
- if (typeof e.TRUSTED_TYPES_POLICY.createScriptURL != "function") throw it("TRUSTED_TYPES_POLICY configuration option must provide a \"createScriptURL\" hook.");
3368
+ ]), j.table && (R(j, ["tbody"]), delete Ne.tbody), e.TRUSTED_TYPES_POLICY) {
3369
+ if (typeof e.TRUSTED_TYPES_POLICY.createHTML != "function") throw Fe("TRUSTED_TYPES_POLICY configuration option must provide a \"createHTML\" hook.");
3370
+ if (typeof e.TRUSTED_TYPES_POLICY.createScriptURL != "function") throw Fe("TRUSTED_TYPES_POLICY configuration option must provide a \"createScriptURL\" hook.");
3879
3371
  let t = x;
3880
3372
  x = e.TRUSTED_TYPES_POLICY;
3881
3373
  try {
3882
- S = ne("");
3374
+ S = T("");
3883
3375
  } catch (e) {
3884
3376
  throw x = t, e;
3885
3377
  }
3886
- } else e.TRUSTED_TYPES_POLICY === null ? (x = void 0, S = "") : (x === void 0 && (x = ie()), x && typeof S == "string" && (S = ne("")));
3887
- R && R(e), J = e;
3888
- }, Zt = W({}, [
3889
- ...dt,
3890
- ...ft,
3891
- ...pt
3892
- ]), Qt = W({}, [...mt, ...ht]), $t = function(e, t, n) {
3893
- return t.namespaceURI === V ? e === "svg" : t.namespaceURI === nt ? e === "svg" && (n === "annotation-xml" || Ut[n]) : !!Zt[e];
3894
- }, en = function(e, t, n) {
3895
- return t.namespaceURI === V ? e === "math" : t.namespaceURI === rt ? e === "math" && Gt[n] : !!Qt[e];
3896
- }, Y = function(e, t, n) {
3897
- return t.namespaceURI === rt && !Gt[n] || t.namespaceURI === nt && !Ut[n] ? !1 : !Qt[e] && (Kt[e] || !Zt[e]);
3898
- }, tn = function(e) {
3378
+ } else e.TRUSTED_TYPES_POLICY === null ? (x = void 0, S = "") : (x === void 0 && (x = re()), x && typeof S == "string" && (S = T("")));
3379
+ k && k(e), Ut = e;
3380
+ }, Kt = R({}, [
3381
+ ...Ve,
3382
+ ...He,
3383
+ ...Ue
3384
+ ]), qt = R({}, [...We, ...Ge]), Jt = function(e, t, n) {
3385
+ return t.namespaceURI === Z ? e === "svg" : t.namespaceURI === At ? e === "svg" && (n === "annotation-xml" || Lt[n]) : !!Kt[e];
3386
+ }, Yt = function(e, t, n) {
3387
+ return t.namespaceURI === Z ? e === "math" : t.namespaceURI === jt ? e === "math" && zt[n] : !!qt[e];
3388
+ }, Xt = function(e, t, n) {
3389
+ return t.namespaceURI === jt && !zt[n] || t.namespaceURI === At && !Lt[n] ? !1 : !qt[e] && (Bt[e] || !Kt[e]);
3390
+ }, Zt = function(e) {
3899
3391
  let t = g(e);
3900
3392
  (!t || !t.tagName) && (t = {
3901
- namespaceURI: U,
3393
+ namespaceURI: Mt,
3902
3394
  tagName: "template"
3903
3395
  });
3904
- let n = Je(e.tagName), r = Je(t.tagName);
3905
- return ot[e.namespaceURI] ? e.namespaceURI === rt ? $t(n, t, r) : e.namespaceURI === nt ? en(n, t, r) : e.namespaceURI === V ? Y(n, t, r) : !!(K === "application/xhtml+xml" && ot[e.namespaceURI]) : !1;
3906
- }, X = function(e) {
3907
- Ge(t.removed, { element: e });
3396
+ let n = Ee(e.tagName), r = Ee(t.tagName);
3397
+ return Pt[e.namespaceURI] ? e.namespaceURI === jt ? Jt(n, t, r) : e.namespaceURI === At ? Yt(n, t, r) : e.namespaceURI === Z ? Xt(n, t, r) : !!(Vt === "application/xhtml+xml" && Pt[e.namespaceURI]) : !1;
3398
+ }, Qt = function(e) {
3399
+ Ce(t.removed, { element: e });
3908
3400
  try {
3909
3401
  g(e).removeChild(e);
3910
3402
  } catch {
3911
- if (p(e), !g(e)) throw it("a node selected for removal could not be detached from its tree and cannot be safely returned; refusing to sanitize in place");
3403
+ if (p(e), !g(e)) throw Fe("a node selected for removal could not be detached from its tree and cannot be safely returned; refusing to sanitize in place");
3912
3404
  }
3913
- }, nn = function(e) {
3405
+ }, $t = function(e) {
3914
3406
  let t = h(e);
3915
3407
  if (t) {
3916
3408
  let e = [];
3917
- He(t, (t) => {
3918
- Ge(e, t);
3919
- }), He(e, (e) => {
3409
+ be(t, (t) => {
3410
+ Ce(e, t);
3411
+ }), be(e, (e) => {
3920
3412
  try {
3921
3413
  p(e);
3922
3414
  } catch {}
@@ -3929,83 +3421,83 @@ function Bt() {
3929
3421
  e.removeAttribute(i);
3930
3422
  } catch {}
3931
3423
  }
3932
- }, Z = function(e, n) {
3424
+ }, en = function(e, n) {
3933
3425
  try {
3934
- Ge(t.removed, {
3426
+ Ce(t.removed, {
3935
3427
  attribute: n.getAttributeNode(e),
3936
3428
  from: n
3937
3429
  });
3938
3430
  } catch {
3939
- Ge(t.removed, {
3431
+ Ce(t.removed, {
3940
3432
  attribute: null,
3941
3433
  from: n
3942
3434
  });
3943
3435
  }
3944
- if (n.removeAttribute(e), e === "is") if (Oe || ke) try {
3945
- X(n);
3436
+ if (n.removeAttribute(e), e === "is") if (G || K) try {
3437
+ Qt(n);
3946
3438
  } catch {}
3947
3439
  else try {
3948
3440
  n.setAttribute(e, "");
3949
3441
  } catch {}
3950
- }, rn = function(e) {
3442
+ }, tn = function(e) {
3951
3443
  let t = v(e);
3952
3444
  if (t) for (let n = t.length - 1; n >= 0; --n) {
3953
3445
  let r = t[n], i = r && r.name;
3954
- if (!(typeof i != "string" || j[q(i)])) try {
3446
+ if (!(typeof i != "string" || M[Q(i)])) try {
3955
3447
  e.removeAttribute(i);
3956
3448
  } catch {}
3957
3449
  }
3958
- }, an = function(e) {
3450
+ }, nn = function(e) {
3959
3451
  let t = [e];
3960
3452
  for (; t.length > 0;) {
3961
3453
  let e = t.pop();
3962
- (y ? y(e) : e.nodeType) === Ft.element && rn(e);
3454
+ (y ? y(e) : e.nodeType) === V.element && tn(e);
3963
3455
  let n = h(e);
3964
3456
  if (n) for (let e = n.length - 1; e >= 0; --e) t.push(n[e]);
3965
3457
  }
3966
- }, on = function(e) {
3458
+ }, rn = function(e) {
3967
3459
  let t = null, r = null;
3968
- if (I) e = "<remove></remove>" + e;
3460
+ if (bt) e = "<remove></remove>" + e;
3969
3461
  else {
3970
- let t = Xe(e, /^[\r\n\t ]+/);
3462
+ let t = Oe(e, /^[\r\n\t ]+/);
3971
3463
  r = t && t[0];
3972
3464
  }
3973
- K === "application/xhtml+xml" && U === V && (e = "<html xmlns=\"http://www.w3.org/1999/xhtml\"><head></head><body>" + e + "</body></html>");
3974
- let i = x ? ne(e) : e;
3975
- if (U === V) try {
3976
- t = new l().parseFromString(i, K);
3465
+ Vt === "application/xhtml+xml" && Mt === Z && (e = "<html xmlns=\"http://www.w3.org/1999/xhtml\"><head></head><body>" + e + "</body></html>");
3466
+ let i = x ? T(e) : e;
3467
+ if (Mt === Z) try {
3468
+ t = new l().parseFromString(i, Vt);
3977
3469
  } catch {}
3978
3470
  if (!t || !t.documentElement) {
3979
- t = oe.createDocument(U, "template", null);
3471
+ t = ae.createDocument(Mt, "template", null);
3980
3472
  try {
3981
- t.documentElement.innerHTML = at ? S : i;
3473
+ t.documentElement.innerHTML = Nt ? S : i;
3982
3474
  } catch {}
3983
3475
  }
3984
3476
  let a = t.body || t.documentElement;
3985
- return e && r && a.insertBefore(n.createTextNode(r), a.childNodes[0] || null), U === V ? le.call(t, F ? "html" : "body")[0] : F ? t.documentElement : a;
3477
+ return e && r && a.insertBefore(n.createTextNode(r), a.childNodes[0] || null), Mt === Z ? se.call(t, vt ? "html" : "body")[0] : vt ? t.documentElement : a;
3478
+ }, an = function(e) {
3479
+ return E.call(e.ownerDocument || e, e, c.SHOW_ELEMENT | c.SHOW_COMMENT | c.SHOW_TEXT | c.SHOW_PROCESSING_INSTRUCTION | c.SHOW_CDATA_SECTION, null);
3480
+ }, on = function(e) {
3481
+ return e = ke(e, ce, " "), e = ke(e, le, " "), e = ke(e, ue, " "), e;
3986
3482
  }, sn = function(e) {
3987
- return se.call(e.ownerDocument || e, e, c.SHOW_ELEMENT | c.SHOW_COMMENT | c.SHOW_TEXT | c.SHOW_PROCESSING_INSTRUCTION | c.SHOW_CDATA_SECTION, null);
3988
- }, cn = function(e) {
3989
- return e = Ze(e, de, " "), e = Ze(e, fe, " "), e = Ze(e, pe, " "), e;
3990
- }, ln = function(e) {
3991
3483
  e.normalize();
3992
- let t = se.call(e.ownerDocument || e, e, c.SHOW_TEXT | c.SHOW_COMMENT | c.SHOW_CDATA_SECTION | c.SHOW_PROCESSING_INSTRUCTION, null), n = t.nextNode();
3993
- for (; n;) n.data = cn(n.data), n = t.nextNode();
3484
+ let t = E.call(e.ownerDocument || e, e, c.SHOW_TEXT | c.SHOW_COMMENT | c.SHOW_CDATA_SECTION | c.SHOW_PROCESSING_INSTRUCTION, null), n = t.nextNode();
3485
+ for (; n;) n.data = on(n.data), n = t.nextNode();
3994
3486
  let r = e.querySelectorAll?.call(e, "template");
3995
- r && He(r, (e) => {
3996
- dn(e.content) && ln(e.content);
3487
+ r && be(r, (e) => {
3488
+ ln(e.content) && sn(e.content);
3997
3489
  });
3998
- }, un = function(e) {
3490
+ }, cn = function(e) {
3999
3491
  let t = b ? b(e) : null;
4000
- return typeof t != "string" || q(t) !== "form" ? !1 : typeof e.nodeName != "string" || typeof e.textContent != "string" || typeof e.removeChild != "function" || e.attributes !== v(e) || typeof e.removeAttribute != "function" || typeof e.setAttribute != "function" || typeof e.namespaceURI != "string" || typeof e.insertBefore != "function" || typeof e.hasChildNodes != "function" || e.nodeType !== y(e) || e.childNodes !== h(e);
4001
- }, dn = function(e) {
3492
+ return typeof t != "string" || Q(t) !== "form" ? !1 : typeof e.nodeName != "string" || typeof e.textContent != "string" || typeof e.removeChild != "function" || e.attributes !== v(e) || typeof e.removeAttribute != "function" || typeof e.setAttribute != "function" || typeof e.namespaceURI != "string" || typeof e.insertBefore != "function" || typeof e.hasChildNodes != "function" || e.nodeType !== y(e) || e.childNodes !== h(e);
3493
+ }, ln = function(e) {
4002
3494
  if (!y || typeof e != "object" || !e) return !1;
4003
3495
  try {
4004
- return y(e) === Ft.documentFragment;
3496
+ return y(e) === V.documentFragment;
4005
3497
  } catch {
4006
3498
  return !1;
4007
3499
  }
4008
- }, Q = function(e) {
3500
+ }, un = function(e) {
4009
3501
  if (!y || typeof e != "object" || !e) return !1;
4010
3502
  try {
4011
3503
  return typeof y(e) == "number";
@@ -4013,50 +3505,50 @@ function Bt() {
4013
3505
  return !1;
4014
3506
  }
4015
3507
  };
4016
- function fn(e, n, r) {
4017
- e.length !== 0 && He(e, (e) => {
4018
- e.call(t, n, r, J);
3508
+ function dn(e, n, r) {
3509
+ e.length !== 0 && be(e, (e) => {
3510
+ e.call(t, n, r, Ut);
4019
3511
  });
4020
3512
  }
4021
- let $ = function(e, t) {
4022
- return !!(we && e.hasChildNodes() && !Q(e.firstElementChild) && H(jt, e.textContent) && H(jt, e.innerHTML) || we && e.namespaceURI === V && t === "style" && Q(e.firstElementChild) || e.nodeType === Ft.processingInstruction || we && e.nodeType === Ft.comment && H(Mt, e.data));
3513
+ let fn = function(e, t) {
3514
+ return !!(_t && e.hasChildNodes() && !un(e.firstElementChild) && I(st, e.textContent) && I(st, e.innerHTML) || _t && e.namespaceURI === Z && t === "style" && un(e.firstElementChild) || e.nodeType === V.processingInstruction || _t && e.nodeType === V.comment && I(ct, e.data));
4023
3515
  }, pn = function(e, t) {
4024
- if (!ve[t] && _n(t) && (M.tagNameCheck instanceof RegExp && H(M.tagNameCheck, t) || M.tagNameCheck instanceof Function && M.tagNameCheck(t))) return !1;
4025
- if (Fe && !L[t]) {
3516
+ if (!Ne[t] && _n(t) && (N.tagNameCheck instanceof RegExp && I(N.tagNameCheck, t) || N.tagNameCheck instanceof Function && N.tagNameCheck(t))) return !1;
3517
+ if (wt && !J[t]) {
4026
3518
  let t = g(e), n = h(e);
4027
3519
  if (n && t) {
4028
3520
  let r = n.length;
4029
3521
  for (let i = r - 1; i >= 0; --i) {
4030
- let r = Ie ? n[i] : f(n[i], !0);
3522
+ let r = Tt ? n[i] : f(n[i], !0);
4031
3523
  t.insertBefore(r, m(e));
4032
3524
  }
4033
3525
  }
4034
3526
  }
4035
- return X(e), !0;
3527
+ return Qt(e), !0;
4036
3528
  }, mn = function(e) {
4037
- if (fn(T.beforeSanitizeElements, e, null), un(e)) return X(e), !0;
4038
- let n = q(b ? b(e) : e.nodeName);
4039
- if (fn(T.uponSanitizeElement, e, {
3529
+ if (dn(O.beforeSanitizeElements, e, null), cn(e)) return Qt(e), !0;
3530
+ let n = Q(b ? b(e) : e.nodeName);
3531
+ if (dn(O.uponSanitizeElement, e, {
4040
3532
  tagName: n,
4041
- allowedTags: k
4042
- }), $(e, n)) return X(e), !0;
4043
- if (ve[n] || !(N.tagCheck instanceof Function && N.tagCheck(n)) && !k[n]) return pn(e, n);
4044
- if ((y ? y(e) : e.nodeType) === Ft.element && !tn(e) || (n === "noscript" || n === "noembed" || n === "noframes") && H(Nt, e.innerHTML)) return X(e), !0;
4045
- if (Ce && e.nodeType === Ft.text) {
4046
- let n = cn(e.textContent);
4047
- e.textContent !== n && (Ge(t.removed, { element: e.cloneNode() }), e.textContent = n);
4048
- }
4049
- return fn(T.afterSanitizeElements, e, null), !1;
3533
+ allowedTags: j
3534
+ }), fn(e, n)) return Qt(e), !0;
3535
+ if (Ne[n] || !(F.tagCheck instanceof Function && F.tagCheck(n)) && !j[n]) return pn(e, n);
3536
+ if ((y ? y(e) : e.nodeType) === V.element && !Zt(e) || (n === "noscript" || n === "noembed" || n === "noframes") && I(lt, e.innerHTML)) return Qt(e), !0;
3537
+ if (H && e.nodeType === V.text) {
3538
+ let n = on(e.textContent);
3539
+ e.textContent !== n && (Ce(t.removed, { element: e.cloneNode() }), e.textContent = n);
3540
+ }
3541
+ return dn(O.afterSanitizeElements, e, null), !1;
4050
3542
  }, hn = function(e, t, r) {
4051
- if (ye[t] || je && (t === "id" || t === "name") && (r in n || r in Jt)) return !1;
4052
- let i = j[t] || N.attributeCheck instanceof Function && N.attributeCheck(t, e);
4053
- if (!(xe && H(me, t)) && !(be && H(he, t))) {
3543
+ if (Pe[t] || xt && (t === "id" || t === "name") && (r in n || r in Wt)) return !1;
3544
+ let i = M[t] || F.attributeCheck instanceof Function && F.attributeCheck(t, e);
3545
+ if (!(Ie && I(de, t)) && !(L && I(fe, t))) {
4054
3546
  if (!i) {
4055
- if (!(_n(e) && (M.tagNameCheck instanceof RegExp && H(M.tagNameCheck, e) || M.tagNameCheck instanceof Function && M.tagNameCheck(e)) && (M.attributeNameCheck instanceof RegExp && H(M.attributeNameCheck, t) || M.attributeNameCheck instanceof Function && M.attributeNameCheck(t, e)) || t === "is" && M.allowCustomizedBuiltInElements && (M.tagNameCheck instanceof RegExp && H(M.tagNameCheck, r) || M.tagNameCheck instanceof Function && M.tagNameCheck(r)))) return !1;
4056
- } else if (!et[t] && !H(O, Ze(r, E, "")) && !((t === "src" || t === "xlink:href" || t === "href") && e !== "script" && Qe(r, "data:") === 0 && Be[e]) && !(P && !H(ge, Ze(r, E, ""))) && r) return !1;
3547
+ if (!(_n(e) && (N.tagNameCheck instanceof RegExp && I(N.tagNameCheck, e) || N.tagNameCheck instanceof Function && N.tagNameCheck(e)) && (N.attributeNameCheck instanceof RegExp && I(N.attributeNameCheck, t) || N.attributeNameCheck instanceof Function && N.attributeNameCheck(t, e)) || t === "is" && N.allowCustomizedBuiltInElements && (N.tagNameCheck instanceof RegExp && I(N.tagNameCheck, r) || N.tagNameCheck instanceof Function && N.tagNameCheck(r)))) return !1;
3548
+ } else if (!X[t] && !I(_e, ke(r, he, "")) && !((t === "src" || t === "xlink:href" || t === "href") && e !== "script" && Ae(r, "data:") === 0 && Y[e]) && !(Le && !I(me, ke(r, he, ""))) && r) return !1;
4057
3549
  }
4058
3550
  return !0;
4059
- }, gn = W({}, [
3551
+ }, gn = R({}, [
4060
3552
  "annotation-xml",
4061
3553
  "color-profile",
4062
3554
  "font-face",
@@ -4066,64 +3558,64 @@ function Bt() {
4066
3558
  "font-face-uri",
4067
3559
  "missing-glyph"
4068
3560
  ]), _n = function(e) {
4069
- return !gn[Je(e)] && H(D, e);
3561
+ return !gn[Ee(e)] && I(ge, e);
4070
3562
  }, vn = function(e, t, n, r) {
4071
3563
  if (x && typeof u == "object" && typeof u.getAttributeType == "function" && !n) switch (u.getAttributeType(e, t)) {
4072
- case "TrustedHTML": return ne(r);
4073
- case "TrustedScriptURL": return re(r);
3564
+ case "TrustedHTML": return T(r);
3565
+ case "TrustedScriptURL": return ne(r);
4074
3566
  }
4075
3567
  return r;
4076
3568
  }, yn = function(e, n, r, i) {
4077
3569
  try {
4078
- r ? e.setAttributeNS(r, n, i) : e.setAttribute(n, i), un(e) ? X(e) : We(t.removed);
3570
+ r ? e.setAttributeNS(r, n, i) : e.setAttribute(n, i), cn(e) ? Qt(e) : Se(t.removed);
4079
3571
  } catch {
4080
- Z(n, e);
3572
+ en(n, e);
4081
3573
  }
4082
3574
  }, bn = function(e) {
4083
- fn(T.beforeSanitizeAttributes, e, null);
3575
+ dn(O.beforeSanitizeAttributes, e, null);
4084
3576
  let t = e.attributes;
4085
- if (!t || un(e)) return;
3577
+ if (!t || cn(e)) return;
4086
3578
  let n = {
4087
3579
  attrName: "",
4088
3580
  attrValue: "",
4089
3581
  keepAttr: !0,
4090
- allowedAttributes: j,
3582
+ allowedAttributes: M,
4091
3583
  forceKeepAttr: void 0
4092
- }, r = t.length, i = q(e.nodeName);
3584
+ }, r = t.length, i = Q(e.nodeName);
4093
3585
  for (; r--;) {
4094
- let a = t[r], o = a.name, s = a.namespaceURI, c = a.value, l = q(o), u = c, d = o === "value" ? u : $e(u);
4095
- if (n.attrName = l, n.attrValue = d, n.keepAttr = !0, n.forceKeepAttr = void 0, fn(T.uponSanitizeAttribute, e, n), d = n.attrValue, Me && (l === "id" || l === "name") && Qe(d, Ne) !== 0 && (Z(o, e), d = Ne + d), we && H(/((--!?|])>)|<\/(style|script|title|xmp|textarea|noscript|iframe|noembed|noframes)/i, d)) {
4096
- Z(o, e);
3586
+ let a = t[r], o = a.name, s = a.namespaceURI, c = a.value, l = Q(o), u = c, d = o === "value" ? u : je(u);
3587
+ if (n.attrName = l, n.attrValue = d, n.keepAttr = !0, n.forceKeepAttr = void 0, dn(O.uponSanitizeAttribute, e, n), d = n.attrValue, St && (l === "id" || l === "name") && Ae(d, Ct) !== 0 && (en(o, e), d = Ct + d), _t && I(/((--!?|])>)|<\/(style|script|title|xmp|textarea|noscript|iframe|noembed|noframes)/i, d)) {
3588
+ en(o, e);
4097
3589
  continue;
4098
3590
  }
4099
- if (l === "attributename" && Xe(d, "href")) {
4100
- Z(o, e);
3591
+ if (l === "attributename" && Oe(d, "href")) {
3592
+ en(o, e);
4101
3593
  continue;
4102
3594
  }
4103
3595
  if (!n.forceKeepAttr) {
4104
3596
  if (!n.keepAttr) {
4105
- Z(o, e);
3597
+ en(o, e);
4106
3598
  continue;
4107
3599
  }
4108
- if (!Se && H(Pt, d)) {
4109
- Z(o, e);
3600
+ if (!gt && I(ut, d)) {
3601
+ en(o, e);
4110
3602
  continue;
4111
3603
  }
4112
- if (Ce && (d = cn(d)), !hn(i, l, d)) {
4113
- Z(o, e);
3604
+ if (H && (d = on(d)), !hn(i, l, d)) {
3605
+ en(o, e);
4114
3606
  continue;
4115
3607
  }
4116
3608
  d = vn(i, l, s, d), d !== u && yn(e, o, s, d);
4117
3609
  }
4118
3610
  }
4119
- fn(T.afterSanitizeAttributes, e, null);
3611
+ dn(O.afterSanitizeAttributes, e, null);
4120
3612
  }, xn = function(e) {
4121
- let t = null, n = sn(e);
4122
- for (fn(T.beforeSanitizeShadowDOM, e, null); t = n.nextNode();) if (fn(T.uponSanitizeShadowNode, t, null), mn(t), bn(t), dn(t.content) && xn(t.content), (y ? y(t) : t.nodeType) === Ft.element) {
3613
+ let t = null, n = an(e);
3614
+ for (dn(O.beforeSanitizeShadowDOM, e, null); t = n.nextNode();) if (dn(O.uponSanitizeShadowNode, t, null), mn(t), bn(t), ln(t.content) && xn(t.content), (y ? y(t) : t.nodeType) === V.element) {
4123
3615
  let e = _(t);
4124
- dn(e) && (Sn(e), xn(e));
3616
+ ln(e) && (Sn(e), xn(e));
4125
3617
  }
4126
- fn(T.afterSanitizeShadowDOM, e, null);
3618
+ dn(O.afterSanitizeShadowDOM, e, null);
4127
3619
  }, Sn = function(e) {
4128
3620
  let t = [{
4129
3621
  node: e,
@@ -4135,16 +3627,16 @@ function Bt() {
4135
3627
  xn(e.shadow);
4136
3628
  continue;
4137
3629
  }
4138
- let n = e.node, r = (y ? y(n) : n.nodeType) === Ft.element, i = h(n);
3630
+ let n = e.node, r = (y ? y(n) : n.nodeType) === V.element, i = h(n);
4139
3631
  if (i) for (let e = i.length - 1; e >= 0; --e) t.push({
4140
3632
  node: i[e],
4141
3633
  shadow: null
4142
3634
  });
4143
3635
  if (r) {
4144
3636
  let e = b ? b(n) : null;
4145
- if (typeof e == "string" && q(e) === "template") {
3637
+ if (typeof e == "string" && Q(e) === "template") {
4146
3638
  let e = n.content;
4147
- dn(e) && t.push({
3639
+ ln(e) && t.push({
4148
3640
  node: e,
4149
3641
  shadow: null
4150
3642
  });
@@ -4152,7 +3644,7 @@ function Bt() {
4152
3644
  }
4153
3645
  if (r) {
4154
3646
  let e = _(n);
4155
- dn(e) && t.push({
3647
+ ln(e) && t.push({
4156
3648
  node: null,
4157
3649
  shadow: e
4158
3650
  }, {
@@ -4164,67 +3656,67 @@ function Bt() {
4164
3656
  };
4165
3657
  return t.sanitize = function(e) {
4166
3658
  let n = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : {}, i = null, a = null, o = null, s = null;
4167
- if (at = !e, at && (e = "<!-->"), typeof e != "string" && !Q(e) && (e = st(e), typeof e != "string")) throw it("dirty is not a string, aborting");
3659
+ if (Nt = !e, Nt && (e = "<!-->"), typeof e != "string" && !un(e) && (e = Re(e), typeof e != "string")) throw Fe("dirty is not a string, aborting");
4168
3660
  if (!t.isSupported) return e;
4169
- Te ? (k = Ee, j = De) : Xt(n), (T.uponSanitizeElement.length > 0 || T.uponSanitizeAttribute.length > 0) && (k = G(k)), T.uponSanitizeAttribute.length > 0 && (j = G(j)), t.removed = [];
4170
- let c = Ie && typeof e != "string" && Q(e);
3661
+ yt ? (j = U, M = W) : $(n), (O.uponSanitizeElement.length > 0 || O.uponSanitizeAttribute.length > 0) && (j = z(j)), O.uponSanitizeAttribute.length > 0 && (M = z(M)), t.removed = [];
3662
+ let c = Tt && typeof e != "string" && un(e);
4171
3663
  if (c) {
4172
3664
  let t = b ? b(e) : e.nodeName;
4173
3665
  if (typeof t == "string") {
4174
- let e = q(t);
4175
- if (!k[e] || ve[e]) throw it("root node is forbidden and cannot be sanitized in-place");
3666
+ let e = Q(t);
3667
+ if (!j[e] || Ne[e]) throw Fe("root node is forbidden and cannot be sanitized in-place");
4176
3668
  }
4177
- if (un(e)) throw it("root node is clobbered and cannot be sanitized in-place");
3669
+ if (cn(e)) throw Fe("root node is clobbered and cannot be sanitized in-place");
4178
3670
  try {
4179
3671
  Sn(e);
4180
3672
  } catch (t) {
4181
- throw nn(e), t;
3673
+ throw $t(e), t;
4182
3674
  }
4183
- } else if (Q(e)) i = on("<!---->"), a = i.ownerDocument.importNode(e, !0), a.nodeType === Ft.element && a.nodeName === "BODY" || a.nodeName === "HTML" ? i = a : i.appendChild(a), Sn(a);
3675
+ } else if (un(e)) i = rn("<!---->"), a = i.ownerDocument.importNode(e, !0), a.nodeType === V.element && a.nodeName === "BODY" || a.nodeName === "HTML" ? i = a : i.appendChild(a), Sn(a);
4184
3676
  else {
4185
- if (!Oe && !Ce && !F && e.indexOf("<") === -1) return x && Ae ? ne(e) : e;
4186
- if (i = on(e), !i) return Oe ? null : Ae ? S : "";
3677
+ if (!G && !H && !vt && e.indexOf("<") === -1) return x && q ? T(e) : e;
3678
+ if (i = rn(e), !i) return G ? null : q ? S : "";
4187
3679
  }
4188
- i && I && X(i.firstChild);
4189
- let l = sn(c ? e : i);
3680
+ i && bt && Qt(i.firstChild);
3681
+ let l = an(c ? e : i);
4190
3682
  try {
4191
- for (; o = l.nextNode();) mn(o), bn(o), dn(o.content) && xn(o.content);
3683
+ for (; o = l.nextNode();) mn(o), bn(o), ln(o.content) && xn(o.content);
4192
3684
  } catch (t) {
4193
- throw c && nn(e), t;
3685
+ throw c && $t(e), t;
4194
3686
  }
4195
- if (c) return He(t.removed, (e) => {
4196
- e.element && an(e.element);
4197
- }), Ce && ln(e), e;
4198
- if (Oe) {
4199
- if (Ce && ln(i), ke) for (s = ce.call(i.ownerDocument); i.firstChild;) s.appendChild(i.firstChild);
3687
+ if (c) return be(t.removed, (e) => {
3688
+ e.element && nn(e.element);
3689
+ }), H && sn(e), e;
3690
+ if (G) {
3691
+ if (H && sn(i), K) for (s = oe.call(i.ownerDocument); i.firstChild;) s.appendChild(i.firstChild);
4200
3692
  else s = i;
4201
- return (j.shadowroot || j.shadowrootmode) && (s = ue.call(r, s, !0)), s;
3693
+ return (M.shadowroot || M.shadowrootmode) && (s = D.call(r, s, !0)), s;
4202
3694
  }
4203
- let u = F ? i.outerHTML : i.innerHTML;
4204
- return F && k["!doctype"] && i.ownerDocument && i.ownerDocument.doctype && i.ownerDocument.doctype.name && H(kt, i.ownerDocument.doctype.name) && (u = "<!DOCTYPE " + i.ownerDocument.doctype.name + ">\n" + u), Ce && (u = cn(u)), x && Ae ? ne(u) : u;
3695
+ let u = vt ? i.outerHTML : i.innerHTML;
3696
+ return vt && j["!doctype"] && i.ownerDocument && i.ownerDocument.doctype && i.ownerDocument.doctype.name && I(at, i.ownerDocument.doctype.name) && (u = "<!DOCTYPE " + i.ownerDocument.doctype.name + ">\n" + u), H && (u = on(u)), x && q ? T(u) : u;
4205
3697
  }, t.setConfig = function() {
4206
- Xt(arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : {}), Te = !0, Ee = k, De = j;
3698
+ $(arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : {}), yt = !0, U = j, W = M;
4207
3699
  }, t.clearConfig = function() {
4208
- J = null, Te = !1, Ee = null, De = null, x = C, S = "";
3700
+ Ut = null, yt = !1, U = null, W = null, x = C, S = "";
4209
3701
  }, t.isValidAttribute = function(e, t, n) {
4210
- return J || Xt({}), hn(q(e), q(t), n);
3702
+ return Ut || $({}), hn(Q(e), Q(t), n);
4211
3703
  }, t.addHook = function(e, t) {
4212
- typeof t == "function" && B(T, e) && Ge(T[e], t);
3704
+ typeof t == "function" && P(O, e) && Ce(O[e], t);
4213
3705
  }, t.removeHook = function(e, t) {
4214
- if (B(T, e)) {
3706
+ if (P(O, e)) {
4215
3707
  if (t !== void 0) {
4216
- let n = Ue(T[e], t);
4217
- return n === -1 ? void 0 : Ke(T[e], n, 1)[0];
3708
+ let n = xe(O[e], t);
3709
+ return n === -1 ? void 0 : we(O[e], n, 1)[0];
4218
3710
  }
4219
- return We(T[e]);
3711
+ return Se(O[e]);
4220
3712
  }
4221
3713
  }, t.removeHooks = function(e) {
4222
- B(T, e) && (T[e] = []);
3714
+ P(O, e) && (O[e] = []);
4223
3715
  }, t.removeAllHooks = function() {
4224
- T = Rt();
3716
+ O = pt();
4225
3717
  }, t;
4226
3718
  }
4227
- var Vt = Bt(), Ht = /* @__PURE__ */ "a.b.strong.i.em.u.s.p.br.span.div.ul.ol.li.h1.h2.h3.h4.h5.h6.table.thead.tbody.tfoot.tr.td.th.blockquote.code.pre.hr.img.sub.sup.small".split("."), Ut = [
3719
+ var gt = ht(), H = /* @__PURE__ */ "a.b.strong.i.em.u.s.p.br.span.div.ul.ol.li.h1.h2.h3.h4.h5.h6.table.thead.tbody.tfoot.tr.td.th.blockquote.code.pre.hr.img.sub.sup.small".split("."), _t = [
4228
3720
  "href",
4229
3721
  "title",
4230
3722
  "src",
@@ -4232,10 +3724,10 @@ var Vt = Bt(), Ht = /* @__PURE__ */ "a.b.strong.i.em.u.s.p.br.span.div.ul.ol.li.
4232
3724
  "width",
4233
3725
  "height"
4234
3726
  ];
4235
- function Wt(e) {
4236
- let t = Vt.sanitize(e, {
4237
- ALLOWED_TAGS: Ht,
4238
- ALLOWED_ATTR: Ut,
3727
+ function vt(e) {
3728
+ let t = gt.sanitize(e, {
3729
+ ALLOWED_TAGS: H,
3730
+ ALLOWED_ATTR: _t,
4239
3731
  ALLOWED_URI_REGEXP: /^(?:(?:https?|mailto):|[^a-z]|[a-z+.\-]+(?:[^a-z+.\-:]|$))/i
4240
3732
  }), n = new DOMParser().parseFromString(t, "text/html");
4241
3733
  return n.querySelectorAll("a[href]").forEach((e) => {
@@ -4244,12 +3736,12 @@ function Wt(e) {
4244
3736
  }
4245
3737
  //#endregion
4246
3738
  //#region src/components/webmapx-layer-info-dialog.ts
4247
- var Gt = /^https:\/\/\S+$/i, Kt = class extends E {
3739
+ var yt = /^https:\/\/\S+$/i, U = class extends h {
4248
3740
  constructor(...e) {
4249
3741
  super(...e), this.dialogTitle = "", this.attribution = "", this.featureSummary = "", this.content = { kind: "none" }, this.fetchToken = 0;
4250
3742
  }
4251
3743
  static {
4252
- this.styles = D`
3744
+ this.styles = g`
4253
3745
  :host { display: block; }
4254
3746
 
4255
3747
  sl-dialog::part(panel) {
@@ -4312,13 +3804,13 @@ var Gt = /^https:\/\/\S+$/i, Kt = class extends E {
4312
3804
  this.content = { kind: "none" };
4313
3805
  return;
4314
3806
  }
4315
- if (Gt.test(i)) {
3807
+ if (yt.test(i)) {
4316
3808
  this.loadFromUrl(i);
4317
3809
  return;
4318
3810
  }
4319
3811
  this.content = {
4320
3812
  kind: "html",
4321
- html: Wt(i)
3813
+ html: vt(i)
4322
3814
  };
4323
3815
  }
4324
3816
  close() {
@@ -4334,7 +3826,7 @@ var Gt = /^https:\/\/\S+$/i, Kt = class extends E {
4334
3826
  if (t !== this.fetchToken) return;
4335
3827
  this.content = {
4336
3828
  kind: "html",
4337
- html: Wt(r)
3829
+ html: vt(r)
4338
3830
  };
4339
3831
  } catch {
4340
3832
  if (t !== this.fetchToken) return;
@@ -4346,22 +3838,22 @@ var Gt = /^https:\/\/\S+$/i, Kt = class extends E {
4346
3838
  }
4347
3839
  renderContent() {
4348
3840
  switch (this.content.kind) {
4349
- case "none": return this.featureSummary ? null : O`<p class="placeholder">No detailed layer information available.</p>`;
4350
- case "loading": return O`<div class="loading"><sl-spinner></sl-spinner> Loading layer information…</div>`;
4351
- case "error": return O`<p class="placeholder">${this.content.message}</p>`;
4352
- case "html": return O`<div class="abstract">${ue(this.content.html)}</div>`;
3841
+ case "none": return this.featureSummary ? null : _`<p class="placeholder">No detailed layer information available.</p>`;
3842
+ case "loading": return _`<div class="loading"><sl-spinner></sl-spinner> Loading layer information…</div>`;
3843
+ case "error": return _`<p class="placeholder">${this.content.message}</p>`;
3844
+ case "html": return _`<div class="abstract">${ee(this.content.html)}</div>`;
4353
3845
  }
4354
3846
  }
4355
3847
  render() {
4356
- return O`
3848
+ return _`
4357
3849
  <sl-dialog label=${this.dialogTitle}
4358
3850
  @sl-request-close=${(e) => {
4359
3851
  e.detail?.source === "overlay" && this.close();
4360
3852
  }}>
4361
3853
  ${this.renderContent()}
4362
- ${this.featureSummary || this.attribution ? O`<div class="layer-meta">
4363
- ${this.featureSummary ? O`<div class="feature-summary">${this.featureSummary}</div>` : null}
4364
- ${this.attribution ? O`<div class="attribution"><strong>Attribution:</strong> ${T(this.attribution)}</div>` : null}
3854
+ ${this.featureSummary || this.attribution ? _`<div class="layer-meta">
3855
+ ${this.featureSummary ? _`<div class="feature-summary">${this.featureSummary}</div>` : null}
3856
+ ${this.attribution ? _`<div class="attribution"><strong>Attribution:</strong> ${c(this.attribution)}</div>` : null}
4365
3857
  </div>` : null}
4366
3858
  <div class="footer">
4367
3859
  <sl-button autofocus @click=${this.close}>Close</sl-button>
@@ -4370,15 +3862,15 @@ var Gt = /^https:\/\/\S+$/i, Kt = class extends E {
4370
3862
  `;
4371
3863
  }
4372
3864
  };
4373
- o([l()], Kt.prototype, "dialogTitle", void 0), o([l()], Kt.prototype, "attribution", void 0), o([l()], Kt.prototype, "featureSummary", void 0), o([l()], Kt.prototype, "content", void 0), o([u("sl-dialog")], Kt.prototype, "dialog", void 0), Kt = o([d("webmapx-layer-info-dialog")], Kt);
3865
+ o([w()], U.prototype, "dialogTitle", void 0), o([w()], U.prototype, "attribution", void 0), o([w()], U.prototype, "featureSummary", void 0), o([w()], U.prototype, "content", void 0), o([S("sl-dialog")], U.prototype, "dialog", void 0), U = o([b("webmapx-layer-info-dialog")], U);
4374
3866
  //#endregion
4375
3867
  //#region src/components/webmapx-layer-style-dialog.ts
4376
- var K = class extends E {
3868
+ var W = class extends h {
4377
3869
  constructor(...e) {
4378
3870
  super(...e), this.dialogTitle = "Layer style", this.groups = [], this.analyses = {}, this.visibleAttributeTables = {};
4379
3871
  }
4380
3872
  static {
4381
- this.styles = D`
3873
+ this.styles = g`
4382
3874
  :host { display: block; }
4383
3875
 
4384
3876
  sl-dialog::part(panel) {
@@ -4713,13 +4205,13 @@ var K = class extends E {
4713
4205
  }
4714
4206
  renderValue(e) {
4715
4207
  let t = this.toValidUrl(e);
4716
- if (t) return O`<a href=${t.href} target="_blank" rel="noopener noreferrer">${this.renderShortUrlLabel(t)}</a>`;
4208
+ if (t) return _`<a href=${t.href} target="_blank" rel="noopener noreferrer">${this.renderShortUrlLabel(t)}</a>`;
4717
4209
  let n = this.formatValue(e);
4718
- return n === "" ? k : this.isDateTimeValue(e) ? O`<span class="no-wrap-value">${n}</span>` : n;
4210
+ return n === "" ? v : this.isDateTimeValue(e) ? _`<span class="no-wrap-value">${n}</span>` : n;
4719
4211
  }
4720
4212
  renderSampleValue(e) {
4721
4213
  let t = this.toValidUrl(e);
4722
- return t ? O`<a href=${t.href} target="_blank" rel="noopener noreferrer">${this.renderShortUrlLabel(t)}</a>` : e;
4214
+ return t ? _`<a href=${t.href} target="_blank" rel="noopener noreferrer">${this.renderShortUrlLabel(t)}</a>` : e;
4723
4215
  }
4724
4216
  toValidUrl(e) {
4725
4217
  if (typeof e != "string") return null;
@@ -4751,29 +4243,29 @@ var K = class extends E {
4751
4243
  }
4752
4244
  renderAnalysis(e) {
4753
4245
  let t = this.analyses[e.sourceId];
4754
- return t ? O`
4246
+ return t ? _`
4755
4247
  <div class="attribute-analysis">
4756
4248
  <div class="analysis-row"><span class="analysis-label">Type</span><span class="analysis-value">${t.type}</span></div>
4757
4249
  <div class="analysis-row"><span class="analysis-label">Values</span><span class="analysis-value">${t.presentCount} present, ${t.missingCount} missing</span></div>
4758
4250
  <div class="analysis-row"><span class="analysis-label">Unique</span><span class="analysis-value">${t.uniqueCount}</span></div>
4759
- ${t.rangeLabel ? O`<div class="analysis-row"><span class="analysis-label">Range</span><span class="analysis-value">${t.rangeLabel}</span></div>` : null}
4760
- ${t.sampleValues.length > 0 ? O`<div class="analysis-row">
4251
+ ${t.rangeLabel ? _`<div class="analysis-row"><span class="analysis-label">Range</span><span class="analysis-value">${t.rangeLabel}</span></div>` : null}
4252
+ ${t.sampleValues.length > 0 ? _`<div class="analysis-row">
4761
4253
  <span class="analysis-label">Sample</span>
4762
4254
  <span class="analysis-value">
4763
- ${t.sampleValues.map((e, t) => O`${t > 0 ? "; " : ""}${this.renderSampleValue(e)}`)}
4255
+ ${t.sampleValues.map((e, t) => _`${t > 0 ? "; " : ""}${this.renderSampleValue(e)}`)}
4764
4256
  </span>
4765
4257
  </div>` : null}
4766
4258
  </div>
4767
4259
  ` : null;
4768
4260
  }
4769
4261
  renderAttributeTable(e) {
4770
- return this.visibleAttributeTables[e.sourceId] ? e.featureRows.length === 0 ? O`<p class="placeholder">No loaded feature rows available.</p>` : O`
4262
+ return this.visibleAttributeTables[e.sourceId] ? e.featureRows.length === 0 ? _`<p class="placeholder">No loaded feature rows available.</p>` : _`
4771
4263
  <div class="attribute-table-wrap">
4772
4264
  <table class="attribute-table">
4773
4265
  <thead>
4774
4266
  <tr>
4775
4267
  <th>#</th>
4776
- ${e.attributes.map((t) => O`
4268
+ ${e.attributes.map((t) => _`
4777
4269
  <th class="attribute-heading">
4778
4270
  <button
4779
4271
  type="button"
@@ -4786,10 +4278,10 @@ var K = class extends E {
4786
4278
  </tr>
4787
4279
  </thead>
4788
4280
  <tbody>
4789
- ${e.featureRows.map((t, n) => O`
4281
+ ${e.featureRows.map((t, n) => _`
4790
4282
  <tr>
4791
4283
  <td class="feature-index-cell">${n + 1}</td>
4792
- ${e.attributes.map((e) => O`
4284
+ ${e.attributes.map((e) => _`
4793
4285
  <td class=${this.toValidUrl(t[e.name]) ? "feature-value-cell url-value-cell" : "feature-value-cell"}>
4794
4286
  ${this.renderValue(t[e.name])}
4795
4287
  </td>
@@ -4802,33 +4294,33 @@ var K = class extends E {
4802
4294
  ` : null;
4803
4295
  }
4804
4296
  render() {
4805
- return O`
4297
+ return _`
4806
4298
  <sl-dialog label=${this.dialogTitle}
4807
4299
  @sl-request-close=${(e) => {
4808
4300
  e.detail?.source === "overlay" && this.close();
4809
4301
  }}>
4810
- ${this.groups.length > 0 ? O`<div class="source-list">
4811
- ${this.groups.map((e) => O`
4302
+ ${this.groups.length > 0 ? _`<div class="source-list">
4303
+ ${this.groups.map((e) => _`
4812
4304
  <section class="source-group">
4813
4305
  <h3 class="source-title">${e.sourceId}</h3>
4814
4306
  <div class="source-meta">
4815
4307
  <span class="pill">${e.featureCountLabel}</span>
4816
- ${e.geometryTypes.map((e) => O`<span class="pill">${e}</span>`)}
4308
+ ${e.geometryTypes.map((e) => _`<span class="pill">${e}</span>`)}
4817
4309
  </div>
4818
4310
  <p class="subheading">Table</p>
4819
- ${e.attributes.length > 0 ? O`<div class="table-controls">
4311
+ ${e.attributes.length > 0 ? _`<div class="table-controls">
4820
4312
  <span class="table-hint">
4821
4313
  ${this.visibleAttributeTables[e.sourceId] ? "Click an attribute header to analyze it. Use the button to hide the table." : "Show the feature table. Click an attribute header to analyze it."}
4822
4314
  </span>
4823
4315
  <sl-button size="small" @click=${() => this.toggleAttributeTable(e.sourceId)}>
4824
4316
  ${this.visibleAttributeTables[e.sourceId] ? "Hide table" : "Table"}
4825
4317
  </sl-button>
4826
- </div>` : O`<p class="placeholder">No attributes found in loaded features.</p>`}
4318
+ </div>` : _`<p class="placeholder">No attributes found in loaded features.</p>`}
4827
4319
  ${this.renderAttributeTable(e)}
4828
4320
  ${this.renderAnalysis(e)}
4829
4321
  <p class="subheading">Layers</p>
4830
4322
  <div class="style-targets">
4831
- ${e.layers.map((e) => O`
4323
+ ${e.layers.map((e) => _`
4832
4324
  <div class="style-target">
4833
4325
  <sl-icon name="palette"></sl-icon>
4834
4326
  <span class="target-label">${e.id}</span>
@@ -4838,7 +4330,7 @@ var K = class extends E {
4838
4330
  </div>
4839
4331
  </section>
4840
4332
  `)}
4841
- </div>` : O`<p class="placeholder">No editable style source found.</p>`}
4333
+ </div>` : _`<p class="placeholder">No editable style source found.</p>`}
4842
4334
  <div class="footer">
4843
4335
  <sl-button autofocus @click=${this.close}>Close</sl-button>
4844
4336
  </div>
@@ -4846,18 +4338,18 @@ var K = class extends E {
4846
4338
  `;
4847
4339
  }
4848
4340
  };
4849
- o([l()], K.prototype, "dialogTitle", void 0), o([l()], K.prototype, "groups", void 0), o([l()], K.prototype, "analyses", void 0), o([l()], K.prototype, "visibleAttributeTables", void 0), o([u("sl-dialog")], K.prototype, "dialog", void 0), K = o([d("webmapx-layer-style-dialog")], K);
4341
+ o([w()], W.prototype, "dialogTitle", void 0), o([w()], W.prototype, "groups", void 0), o([w()], W.prototype, "analyses", void 0), o([w()], W.prototype, "visibleAttributeTables", void 0), o([S("sl-dialog")], W.prototype, "dialog", void 0), W = o([b("webmapx-layer-style-dialog")], W);
4850
4342
  //#endregion
4851
4343
  //#region src/components/webmapx-save-layers-dialog.ts
4852
- var qt, q = class extends E {
4344
+ var bt, G = class extends h {
4853
4345
  static {
4854
- qt = this;
4346
+ bt = this;
4855
4347
  }
4856
4348
  constructor(...e) {
4857
4349
  super(...e), this.items = [], this.filename = "map-layers", this.includeStyle = !0, this.zip = !0;
4858
4350
  }
4859
4351
  static {
4860
- this.styles = D`
4352
+ this.styles = g`
4861
4353
  :host { display: block; }
4862
4354
 
4863
4355
  sl-dialog::part(panel) {
@@ -4931,7 +4423,7 @@ var qt, q = class extends E {
4931
4423
  buildFileBases(e) {
4932
4424
  let t = /* @__PURE__ */ new Map(), n = /* @__PURE__ */ new Set();
4933
4425
  for (let r of e) {
4934
- let e = qt.sanitizeFileBase(r.layerId), i = e, a = 2;
4426
+ let e = bt.sanitizeFileBase(r.layerId), i = e, a = 2;
4935
4427
  for (; n.has(i);) i = `${e}_${a++}`;
4936
4428
  n.add(i), t.set(r.layerId, i);
4937
4429
  }
@@ -4974,14 +4466,14 @@ var qt, q = class extends E {
4974
4466
  this.downloadBlob(new Blob([r], { type: "application/geo+json" }), `${t}.geojson`), this.close();
4975
4467
  return;
4976
4468
  }
4977
- let n = [...e].reverse(), r = this.buildFileBases(n), i = new me(new pe("application/zip"));
4469
+ let n = [...e].reverse(), r = this.buildFileBases(n), i = new f(new d("application/zip"));
4978
4470
  for (let e of n) {
4979
4471
  let t = typeof e.data == "string" ? e.data : JSON.stringify(e.data, null, 2);
4980
- await i.add(`${r.get(e.layerId)}.geojson`, new fe(t));
4472
+ await i.add(`${r.get(e.layerId)}.geojson`, new u(t));
4981
4473
  }
4982
4474
  if (this.includeStyle) for (let e of n) {
4983
4475
  let t = this.buildStyleConfig(e, r.get(e.layerId));
4984
- await i.add(`${r.get(e.layerId)}_style.json`, new fe(JSON.stringify(t, null, 2)));
4476
+ await i.add(`${r.get(e.layerId)}_style.json`, new u(JSON.stringify(t, null, 2)));
4985
4477
  }
4986
4478
  this.downloadBlob(await i.close(), `${t}.zip`), this.close();
4987
4479
  }
@@ -4991,13 +4483,13 @@ var qt, q = class extends E {
4991
4483
  }
4992
4484
  render() {
4993
4485
  let e = this.selectedItems.length, t = this.singleFileEligible;
4994
- return O`
4486
+ return _`
4995
4487
  <sl-dialog label="Save layer(s)"
4996
4488
  @sl-request-close=${(e) => {
4997
4489
  e.detail?.source === "overlay" && this.close();
4998
4490
  }}>
4999
4491
  <div class="layer-list">
5000
- ${this.items.map((e) => O`
4492
+ ${this.items.map((e) => _`
5001
4493
  <div class="layer-row">
5002
4494
  <sl-checkbox
5003
4495
  ?checked=${e.checked}
@@ -5005,7 +4497,7 @@ var qt, q = class extends E {
5005
4497
  @sl-change=${(t) => this.toggleItem(e.layerId, t.target.checked)}
5006
4498
  >
5007
4499
  ${e.label}
5008
- ${e.data === null ? O`<span class="unsupported">(no exportable data)</span>` : null}
4500
+ ${e.data === null ? _`<span class="unsupported">(no exportable data)</span>` : null}
5009
4501
  </sl-checkbox>
5010
4502
  </div>
5011
4503
  `)}
@@ -5024,7 +4516,7 @@ var qt, q = class extends E {
5024
4516
  }}>
5025
4517
  Include style
5026
4518
  </sl-checkbox>
5027
- ${t ? O`
4519
+ ${t ? _`
5028
4520
  <sl-checkbox ?checked=${this.zip}
5029
4521
  @sl-change=${(e) => {
5030
4522
  this.zip = e.target.checked;
@@ -5044,15 +4536,15 @@ var qt, q = class extends E {
5044
4536
  `;
5045
4537
  }
5046
4538
  };
5047
- o([l()], q.prototype, "items", void 0), o([l()], q.prototype, "filename", void 0), o([l()], q.prototype, "includeStyle", void 0), o([l()], q.prototype, "zip", void 0), o([u("sl-dialog")], q.prototype, "dialog", void 0), o([u(".filename-input")], q.prototype, "filenameInput", void 0), q = qt = o([d("webmapx-save-layers-dialog")], q);
4539
+ o([w()], G.prototype, "items", void 0), o([w()], G.prototype, "filename", void 0), o([w()], G.prototype, "includeStyle", void 0), o([w()], G.prototype, "zip", void 0), o([S("sl-dialog")], G.prototype, "dialog", void 0), o([S(".filename-input")], G.prototype, "filenameInput", void 0), G = bt = o([b("webmapx-save-layers-dialog")], G);
5048
4540
  //#endregion
5049
4541
  //#region src/components/webmapx-permalink-dialog.ts
5050
- var J = class extends E {
4542
+ var K = class extends h {
5051
4543
  constructor(...e) {
5052
4544
  super(...e), this.url = "", this.hasConfig = !1, this.dynamicLayerIds = [], this.copied = !1;
5053
4545
  }
5054
4546
  static {
5055
- this.styles = D`
4547
+ this.styles = g`
5056
4548
  :host { display: block; }
5057
4549
 
5058
4550
  sl-dialog::part(panel) {
@@ -5101,9 +4593,9 @@ var J = class extends E {
5101
4593
  }, 2e3);
5102
4594
  }
5103
4595
  render() {
5104
- return O`
4596
+ return _`
5105
4597
  <sl-dialog label="Permalink">
5106
- ${this.dynamicLayerIds.length > 0 ? O`
4598
+ ${this.dynamicLayerIds.length > 0 ? _`
5107
4599
  <div class="warning">
5108
4600
  <sl-icon name="exclamation-triangle"></sl-icon>
5109
4601
  <span>
@@ -5113,7 +4605,7 @@ var J = class extends E {
5113
4605
  </span>
5114
4606
  </div>
5115
4607
  ` : null}
5116
- ${this.hasConfig ? null : O`
4608
+ ${this.hasConfig ? null : _`
5117
4609
  <div class="warning">
5118
4610
  <sl-icon name="exclamation-triangle"></sl-icon>
5119
4611
  <span>Config was not loaded from a URL — layer state may not restore for recipients using a different config.</span>
@@ -5131,11 +4623,11 @@ var J = class extends E {
5131
4623
  `;
5132
4624
  }
5133
4625
  };
5134
- o([l()], J.prototype, "url", void 0), o([l()], J.prototype, "hasConfig", void 0), o([l()], J.prototype, "dynamicLayerIds", void 0), o([l()], J.prototype, "copied", void 0), o([u("sl-dialog")], J.prototype, "dialog", void 0), J = o([d("webmapx-permalink-dialog")], J);
4626
+ o([w()], K.prototype, "url", void 0), o([w()], K.prototype, "hasConfig", void 0), o([w()], K.prototype, "dynamicLayerIds", void 0), o([w()], K.prototype, "copied", void 0), o([S("sl-dialog")], K.prototype, "dialog", void 0), K = o([b("webmapx-permalink-dialog")], K);
5135
4627
  //#endregion
5136
4628
  //#region src/components/webmapx-layer-overview.ts
5137
- var Jt;
5138
- function Yt(e) {
4629
+ var q;
4630
+ function xt(e) {
5139
4631
  let t = Infinity, n = Infinity, r = -Infinity, i = -Infinity, a = (e) => {
5140
4632
  if (typeof e[0] == "number") {
5141
4633
  let [a, o] = e;
@@ -5153,7 +4645,7 @@ function Yt(e) {
5153
4645
  Math.min(85.05112878, i)
5154
4646
  ] : null;
5155
4647
  }
5156
- function Xt(e, t) {
4648
+ function St(e, t) {
5157
4649
  return e ? t ? [
5158
4650
  Math.min(e[0], t[0]),
5159
4651
  Math.min(e[1], t[1]),
@@ -5161,10 +4653,10 @@ function Xt(e, t) {
5161
4653
  Math.max(e[3], t[3])
5162
4654
  ] : e : t;
5163
4655
  }
5164
- function Zt(e) {
4656
+ function Ct(e) {
5165
4657
  if (!e) return 0;
5166
4658
  switch (e.type) {
5167
- case "GeometryCollection": return e.geometries.reduce((e, t) => e + Zt(t), 0);
4659
+ case "GeometryCollection": return e.geometries.reduce((e, t) => e + Ct(t), 0);
5168
4660
  case "Point": return 1;
5169
4661
  case "MultiPoint":
5170
4662
  case "LineString": return e.coordinates.length;
@@ -5174,16 +4666,16 @@ function Zt(e) {
5174
4666
  default: return 0;
5175
4667
  }
5176
4668
  }
5177
- function Qt(e) {
4669
+ function wt(e) {
5178
4670
  let t = /* @__PURE__ */ new Map(), n = 0;
5179
4671
  for (let r of e.features ?? []) {
5180
4672
  let e = r.geometry?.type ?? "unknown";
5181
- t.set(e, (t.get(e) ?? 0) + 1), n += Zt(r.geometry);
4673
+ t.set(e, (t.get(e) ?? 0) + 1), n += Ct(r.geometry);
5182
4674
  }
5183
4675
  let r = e.features?.length ?? 0, i = [...t.entries()].map(([e, t]) => `${e}: ${t}`).join(", ");
5184
4676
  return `${i && t.size > 1 ? `${r} features (${i})` : `${r} feature${r === 1 ? "" : "s"}${i ? ` (${[...t.keys()][0]})` : ""}`}, ${n} ${n === 1 ? "vertex" : "vertices"}`;
5185
4677
  }
5186
- function $t(e, t) {
4678
+ function Tt(e, t) {
5187
4679
  if (Array.isArray(t?.sublayers) && t.sublayers.length > 0) {
5188
4680
  let n = /* @__PURE__ */ new Set();
5189
4681
  for (let e of t.sublayers) typeof e.source == "string" && n.add(e.source);
@@ -5191,16 +4683,16 @@ function $t(e, t) {
5191
4683
  }
5192
4684
  return typeof t?.sourceId == "string" ? [[t.sourceId]] : [];
5193
4685
  }
5194
- var en = new Set([
4686
+ var Et = new Set([
5195
4687
  "circle",
5196
4688
  "symbol",
5197
4689
  "label",
5198
4690
  "line",
5199
4691
  "fill",
5200
4692
  "fill-extrusion"
5201
- ]), Y = class extends s {
4693
+ ]), J = class extends s {
5202
4694
  static {
5203
- Jt = this;
4695
+ q = this;
5204
4696
  }
5205
4697
  constructor(...e) {
5206
4698
  super(...e), this.backgroundGroupLabel = "Base Maps", this.backgroundTitle = "Base map", this.overviewTitle = "Active layers", this.backgroundLayers = [], this.overviewLayers = [], this.layerTransparency = /* @__PURE__ */ new Map(), this.dropTargetLayerId = null, this.dropTargetPosition = null, this.sourceExtentCache = /* @__PURE__ */ new Map(), this.layerExtentCache = /* @__PURE__ */ new Map(), this.unsubscribeLayerAdd = null, this.unsubscribeLayerRemove = null, this.dragState = null, this.autoScrollState = null;
@@ -5215,7 +4707,7 @@ var en = new Set([
5215
4707
  this.AUTO_SCROLL_INTERVAL_MS = 20;
5216
4708
  }
5217
4709
  static {
5218
- this.styles = D`
4710
+ this.styles = g`
5219
4711
  :host {
5220
4712
  display: block;
5221
4713
  box-sizing: border-box;
@@ -5486,7 +4978,7 @@ var en = new Set([
5486
4978
  this.unsubscribeLayerAdd?.(), this.unsubscribeLayerRemove?.(), this.unsubscribeLayerAdd = null, this.unsubscribeLayerRemove = null;
5487
4979
  }
5488
4980
  render() {
5489
- return O`
4981
+ return _`
5490
4982
  <div class="panel">
5491
4983
  ${this.renderSection(this.overviewTitle, this.overviewLayers, "No active layers.", !0)}
5492
4984
  ${this.renderSection(this.backgroundTitle, this.backgroundLayers, "No base map selected.")}
@@ -5498,13 +4990,13 @@ var en = new Set([
5498
4990
  `;
5499
4991
  }
5500
4992
  renderSection(e, t, n, r = !1) {
5501
- return O`
4993
+ return _`
5502
4994
  <section class="section">
5503
4995
  <h3 class="section-title">${e}</h3>
5504
- ${t.length > 0 ? O`
4996
+ ${t.length > 0 ? _`
5505
4997
  <div class="layer-list">
5506
- ${t.map((e) => O`
5507
- ${this.dropTargetLayerId === e.layerId && this.dropTargetPosition === "above" ? O`<div class="drop-indicator"></div>` : null}
4998
+ ${t.map((e) => _`
4999
+ ${this.dropTargetLayerId === e.layerId && this.dropTargetPosition === "above" ? _`<div class="drop-indicator"></div>` : null}
5508
5000
  <div class="layer-card" data-layer-id=${e.layerId}>
5509
5001
  <div class="layer-row">
5510
5002
  <sl-icon-button
@@ -5513,7 +5005,7 @@ var en = new Set([
5513
5005
  label=${e.visible ? "Hide layer" : "Show layer"}
5514
5006
  @click=${() => this.handleVisibilityToggle(e.layerId)}
5515
5007
  ></sl-icon-button>
5516
- ${t.length > 1 ? O`
5008
+ ${t.length > 1 ? _`
5517
5009
  <span
5518
5010
  class="layer-label-drag"
5519
5011
  @pointerdown=${(e) => this.onDragHandlePointerDown(e)}
@@ -5521,7 +5013,7 @@ var en = new Set([
5521
5013
  @pointerup=${(e) => this.onDragHandlePointerUp(e)}
5522
5014
  @pointercancel=${(e) => this.onDragHandlePointerUp(e)}
5523
5015
  ><span class="layer-label ${e.outOfZoom ? "out-of-zoom" : ""}">${e.label}</span></span>
5524
- ` : O`<span class="layer-label ${e.outOfZoom ? "out-of-zoom" : ""}">${e.label}</span>`}
5016
+ ` : _`<span class="layer-label ${e.outOfZoom ? "out-of-zoom" : ""}">${e.label}</span>`}
5525
5017
  <sl-icon-button
5526
5018
  class="collapse-toggle"
5527
5019
  name=${this.isLegendCollapsed(e.layerId) ? "chevron-right" : "chevron-down"}
@@ -5531,7 +5023,7 @@ var en = new Set([
5531
5023
  </div>
5532
5024
  <div class="layer-details ${this.isLegendCollapsed(e.layerId) ? "collapsed" : ""}">
5533
5025
  <div class="layer-details-inner">
5534
- ${e.visible ? O`
5026
+ ${e.visible ? _`
5535
5027
  <div class="opacity-row">
5536
5028
  <sl-icon name="circle-half"></sl-icon>
5537
5029
  <input
@@ -5547,24 +5039,24 @@ var en = new Set([
5547
5039
  <webmapx-layer-legend layer-id=${e.layerId}></webmapx-layer-legend>
5548
5040
  </div>
5549
5041
  ` : null}
5550
- ${e.topLevelGroup ? O`<div class="layer-meta">${e.topLevelGroup}</div>` : null}
5042
+ ${e.topLevelGroup ? _`<div class="layer-meta">${e.topLevelGroup}</div>` : null}
5551
5043
  <div class="layer-details-actions">
5552
5044
  <sl-icon-button
5553
5045
  name="info-circle"
5554
5046
  label="About this layer"
5555
5047
  @click=${() => this.handleShowLayerInfo(e.layerId, e.label)}
5556
5048
  ></sl-icon-button>
5557
- ${e.hasStyleDialog ? O`<sl-icon-button
5049
+ ${e.hasStyleDialog ? _`<sl-icon-button
5558
5050
  name="palette"
5559
5051
  label="Layer style"
5560
5052
  @click=${() => this.handleShowLayerStyle(e.layerId, e.label)}
5561
5053
  ></sl-icon-button>` : null}
5562
- ${e.hasExtent ? O`<sl-icon-button
5054
+ ${e.hasExtent ? _`<sl-icon-button
5563
5055
  name="zoom-in"
5564
5056
  label="Zoom to layer"
5565
5057
  @click=${() => this.handleZoomToLayer(e.layerId)}
5566
5058
  ></sl-icon-button>` : null}
5567
- ${r ? O`<sl-icon-button
5059
+ ${r ? _`<sl-icon-button
5568
5060
  class="delete-layer"
5569
5061
  name="trash"
5570
5062
  label="Delete layer"
@@ -5574,11 +5066,11 @@ var en = new Set([
5574
5066
  </div>
5575
5067
  </div>
5576
5068
  </div>
5577
- ${this.dropTargetLayerId === e.layerId && this.dropTargetPosition === "below" ? O`<div class="drop-indicator"></div>` : null}
5069
+ ${this.dropTargetLayerId === e.layerId && this.dropTargetPosition === "below" ? _`<div class="drop-indicator"></div>` : null}
5578
5070
  `)}
5579
5071
  </div>
5580
- ` : O`<div class="empty">${n}</div>`}
5581
- ${r ? O`
5072
+ ` : _`<div class="empty">${n}</div>`}
5073
+ ${r ? _`
5582
5074
  <div class="save-layers-row">
5583
5075
  <sl-tooltip content="Permalink">
5584
5076
  <sl-icon-button
@@ -5587,7 +5079,7 @@ var en = new Set([
5587
5079
  @click=${() => this.handlePermalink()}
5588
5080
  ></sl-icon-button>
5589
5081
  </sl-tooltip>
5590
- ${t.length > 0 ? O`
5082
+ ${t.length > 0 ? _`
5591
5083
  <sl-tooltip content="Save layer(s)…">
5592
5084
  <sl-icon-button
5593
5085
  name="download"
@@ -5681,7 +5173,7 @@ var en = new Set([
5681
5173
  }
5682
5174
  updateAutoScroll(e, t) {
5683
5175
  if (!t) return;
5684
- let n = t.getBoundingClientRect(), r = Jt.AUTO_SCROLL_EDGE_PX, i = null;
5176
+ let n = t.getBoundingClientRect(), r = q.AUTO_SCROLL_EDGE_PX, i = null;
5685
5177
  if (e < n.top + r ? i = "up" : e > n.bottom - r && (i = "down"), !i) {
5686
5178
  this.stopAutoScroll();
5687
5179
  return;
@@ -5700,7 +5192,7 @@ var en = new Set([
5700
5192
  this.stopAutoScroll();
5701
5193
  return;
5702
5194
  }
5703
- t.scrollTop += n === "up" ? -Jt.AUTO_SCROLL_STEP_PX : Jt.AUTO_SCROLL_STEP_PX, e.timer = window.setTimeout(() => this.runAutoScrollStep(), Jt.AUTO_SCROLL_INTERVAL_MS);
5195
+ t.scrollTop += n === "up" ? -q.AUTO_SCROLL_STEP_PX : q.AUTO_SCROLL_STEP_PX, e.timer = window.setTimeout(() => this.runAutoScrollStep(), q.AUTO_SCROLL_INTERVAL_MS);
5704
5196
  }
5705
5197
  stopAutoScroll() {
5706
5198
  this.autoScrollState &&= (window.clearTimeout(this.autoScrollState.timer), null);
@@ -5782,18 +5274,18 @@ var en = new Set([
5782
5274
  this.styleDialog?.open(r, this.getLayerStyleGroups(e, n));
5783
5275
  }
5784
5276
  getLayerFeatureSummary(e, t) {
5785
- let n = $t(e, t), r = [];
5277
+ let n = Tt(e, t), r = [];
5786
5278
  for (let e of n) for (let t of e) {
5787
5279
  let e = this.adapter?.getSourceData(t) ?? null;
5788
5280
  if (e && typeof e == "object") {
5789
- r.push(Qt(e));
5281
+ r.push(wt(e));
5790
5282
  break;
5791
5283
  }
5792
5284
  }
5793
- return r.length === 0 && t?.sourceData && typeof t.sourceData == "object" && r.push(Qt(t.sourceData)), r.length > 0 ? r.join("; ") : void 0;
5285
+ return r.length === 0 && t?.sourceData && typeof t.sourceData == "object" && r.push(wt(t.sourceData)), r.length > 0 ? r.join("; ") : void 0;
5794
5286
  }
5795
5287
  layerHasExtent(e, t) {
5796
- return Array.isArray(t?.bounds) && t.bounds.length === 4 ? !0 : $t(e, t).some((e) => e.some((e) => this.adapter?.getSourceData(e) !== null));
5288
+ return Array.isArray(t?.bounds) && t.bounds.length === 4 ? !0 : Tt(e, t).some((e) => e.some((e) => this.adapter?.getSourceData(e) !== null));
5797
5289
  }
5798
5290
  layerHasStyleDialog(e) {
5799
5291
  return this.getLayerStyleTargets("", e).length > 0;
@@ -5803,7 +5295,7 @@ var en = new Set([
5803
5295
  if (Array.isArray(t?.sublayers) && t.sublayers.length > 0) this.collectStyleTargetsFromSublayers(e, t.sublayers, n);
5804
5296
  else {
5805
5297
  let r = typeof t?.layerType == "string" ? t.layerType : void 0, i = typeof t?.sourceId == "string" ? t.sourceId : "";
5806
- r && en.has(r) && n.push({
5298
+ r && Et.has(r) && n.push({
5807
5299
  id: e,
5808
5300
  type: r,
5809
5301
  sourceId: i
@@ -5815,7 +5307,7 @@ var en = new Set([
5815
5307
  if (Array.isArray(t)) for (let r of t) {
5816
5308
  if (!r || typeof r != "object") continue;
5817
5309
  let t = r, i = typeof t.type == "string" ? t.type : void 0, a = typeof t.id == "string" && t.id.length > 0 ? t.id : i, o = typeof t.source == "string" ? t.source : "", s = o ? `${e}:${o}` : "", c = typeof t["source-layer"] == "string" ? t["source-layer"] : void 0;
5818
- i && a && en.has(i) && n.push({
5310
+ i && a && Et.has(i) && n.push({
5819
5311
  id: a,
5820
5312
  type: i,
5821
5313
  sourceId: s,
@@ -5923,7 +5415,7 @@ var en = new Set([
5923
5415
  for (let t of e) {
5924
5416
  let e = this.adapter?.getSourceData(t) ?? null;
5925
5417
  if (e && typeof e == "object") {
5926
- n = Yt(e);
5418
+ n = xt(e);
5927
5419
  break;
5928
5420
  }
5929
5421
  }
@@ -5933,7 +5425,7 @@ var en = new Set([
5933
5425
  if (this.layerExtentCache.has(e)) return this.layerExtentCache.get(e) ?? null;
5934
5426
  let t = this.adapter?.store.getState().mapLayers?.[e], n = null;
5935
5427
  if (Array.isArray(t?.bounds) && t.bounds.length === 4) n = t.bounds;
5936
- else for (let r of $t(e, t)) n = Xt(n, this.getSourceExtent(r));
5428
+ else for (let r of Tt(e, t)) n = St(n, this.getSourceExtent(r));
5937
5429
  return this.layerExtentCache.set(e, n), n;
5938
5430
  }
5939
5431
  handleZoomToLayer(e) {
@@ -5972,24 +5464,24 @@ var en = new Set([
5972
5464
  } }, "UI"), this.applyVisibleLayers(this.store.getState());
5973
5465
  }
5974
5466
  };
5975
- o([c({
5467
+ o([x({
5976
5468
  type: String,
5977
5469
  attribute: "background-group-label"
5978
- })], Y.prototype, "backgroundGroupLabel", void 0), o([c({
5470
+ })], J.prototype, "backgroundGroupLabel", void 0), o([x({
5979
5471
  type: String,
5980
5472
  attribute: "background-title"
5981
- })], Y.prototype, "backgroundTitle", void 0), o([c({
5473
+ })], J.prototype, "backgroundTitle", void 0), o([x({
5982
5474
  type: String,
5983
5475
  attribute: "overview-title"
5984
- })], Y.prototype, "overviewTitle", void 0), o([l()], Y.prototype, "backgroundLayers", void 0), o([l()], Y.prototype, "overviewLayers", void 0), o([l()], Y.prototype, "layerTransparency", void 0), o([l()], Y.prototype, "dropTargetLayerId", void 0), o([l()], Y.prototype, "dropTargetPosition", void 0), o([u("webmapx-layer-info-dialog")], Y.prototype, "infoDialog", void 0), o([u("webmapx-layer-style-dialog")], Y.prototype, "styleDialog", void 0), o([u("webmapx-save-layers-dialog")], Y.prototype, "saveLayersDialog", void 0), o([u("webmapx-permalink-dialog")], Y.prototype, "permalinkDialog", void 0), Y = Jt = o([d("webmapx-layer-overview")], Y);
5476
+ })], J.prototype, "overviewTitle", void 0), o([w()], J.prototype, "backgroundLayers", void 0), o([w()], J.prototype, "overviewLayers", void 0), o([w()], J.prototype, "layerTransparency", void 0), o([w()], J.prototype, "dropTargetLayerId", void 0), o([w()], J.prototype, "dropTargetPosition", void 0), o([S("webmapx-layer-info-dialog")], J.prototype, "infoDialog", void 0), o([S("webmapx-layer-style-dialog")], J.prototype, "styleDialog", void 0), o([S("webmapx-save-layers-dialog")], J.prototype, "saveLayersDialog", void 0), o([S("webmapx-permalink-dialog")], J.prototype, "permalinkDialog", void 0), J = q = o([b("webmapx-layer-overview")], J);
5985
5477
  //#endregion
5986
5478
  //#region src/components/webmapx-spinner.ts
5987
- var tn = class extends s {
5479
+ var Dt = class extends s {
5988
5480
  constructor(...e) {
5989
5481
  super(...e), this.busy = !1, this.small = !1, this.nocolor = !1;
5990
5482
  }
5991
5483
  static {
5992
- this.styles = D`
5484
+ this.styles = g`
5993
5485
  :host {
5994
5486
  display: block;
5995
5487
  --webmapx-pointer-events: none;
@@ -6023,28 +5515,28 @@ var tn = class extends s {
6023
5515
  this.busy = e.mapBusy;
6024
5516
  }
6025
5517
  render() {
6026
- return O`
5518
+ return _`
6027
5519
  <div class="spinner-container ${this.busy ? "visible" : ""}">
6028
5520
  <sl-spinner></sl-spinner>
6029
5521
  </div>
6030
5522
  `;
6031
5523
  }
6032
5524
  };
6033
- o([l()], tn.prototype, "busy", void 0), o([c({
5525
+ o([w()], Dt.prototype, "busy", void 0), o([x({
6034
5526
  type: Boolean,
6035
5527
  reflect: !0
6036
- })], tn.prototype, "small", void 0), o([c({
5528
+ })], Dt.prototype, "small", void 0), o([x({
6037
5529
  type: Boolean,
6038
5530
  reflect: !0
6039
- })], tn.prototype, "nocolor", void 0), tn = o([d("webmapx-spinner")], tn);
5531
+ })], Dt.prototype, "nocolor", void 0), Dt = o([b("webmapx-spinner")], Dt);
6040
5532
  //#endregion
6041
5533
  //#region src/components/webmapx-control-group.ts
6042
- var X = class extends E {
5534
+ var Y = class extends h {
6043
5535
  constructor(...e) {
6044
5536
  super(...e), this.orientation = "vertical", this.panelPosition = "after", this.alignment = "start", this.slotAnchorY = "top", this.panelActive = !1, this.priority = "normal", this.panelObserver = null;
6045
5537
  }
6046
5538
  static {
6047
- this.styles = D`
5539
+ this.styles = g`
6048
5540
  :host {
6049
5541
  display: flex;
6050
5542
  pointer-events: none;
@@ -6153,39 +5645,39 @@ var X = class extends E {
6153
5645
  e.has("orientation") && this.updateToolbarOrientation(), e.has("slot") && this.updateSlotAnchor();
6154
5646
  }
6155
5647
  render() {
6156
- return O`<slot @slotchange=${this.handleSlotChange}></slot>`;
5648
+ return _`<slot @slotchange=${this.handleSlotChange}></slot>`;
6157
5649
  }
6158
5650
  };
6159
- o([c({
5651
+ o([x({
6160
5652
  type: String,
6161
5653
  reflect: !0
6162
- })], X.prototype, "orientation", void 0), o([c({
5654
+ })], Y.prototype, "orientation", void 0), o([x({
6163
5655
  type: String,
6164
5656
  reflect: !0,
6165
5657
  attribute: "panel-position"
6166
- })], X.prototype, "panelPosition", void 0), o([c({
5658
+ })], Y.prototype, "panelPosition", void 0), o([x({
6167
5659
  type: String,
6168
5660
  reflect: !0
6169
- })], X.prototype, "alignment", void 0), o([c({
5661
+ })], Y.prototype, "alignment", void 0), o([x({
6170
5662
  type: String,
6171
5663
  reflect: !0,
6172
5664
  attribute: "slot-anchor-y"
6173
- })], X.prototype, "slotAnchorY", void 0), o([c({
5665
+ })], Y.prototype, "slotAnchorY", void 0), o([x({
6174
5666
  type: Boolean,
6175
5667
  reflect: !0,
6176
5668
  attribute: "panel-active"
6177
- })], X.prototype, "panelActive", void 0), o([c({
5669
+ })], Y.prototype, "panelActive", void 0), o([x({
6178
5670
  type: String,
6179
5671
  reflect: !0
6180
- })], X.prototype, "priority", void 0), o([p()], X.prototype, "childrenElements", void 0), X = o([d("webmapx-control-group")], X);
5672
+ })], Y.prototype, "priority", void 0), o([C()], Y.prototype, "childrenElements", void 0), Y = o([b("webmapx-control-group")], Y);
6181
5673
  //#endregion
6182
5674
  //#region src/components/webmapx-zoom-level.ts
6183
- var nn = class extends s {
5675
+ var Ot = class extends s {
6184
5676
  constructor(...e) {
6185
5677
  super(...e), this.currentZoom = null, this.inputValue = "", this.unsubscribeEvents = null;
6186
5678
  }
6187
5679
  static {
6188
- this.styles = D`
5680
+ this.styles = g`
6189
5681
  :host {
6190
5682
  position: relative;
6191
5683
  display: inline-flex;
@@ -6260,7 +5752,7 @@ var nn = class extends s {
6260
5752
  !isNaN(e) && e >= 0 && this.adapter.setZoom(e);
6261
5753
  }
6262
5754
  render() {
6263
- return O`
5755
+ return _`
6264
5756
  <div class="tool-container">
6265
5757
  <label for="zoom-input">Zoom:</label>
6266
5758
  <input
@@ -6278,10 +5770,10 @@ var nn = class extends s {
6278
5770
  `;
6279
5771
  }
6280
5772
  };
6281
- o([l()], nn.prototype, "currentZoom", void 0), o([l()], nn.prototype, "inputValue", void 0), nn = o([d("webmapx-zoom-level")], nn);
5773
+ o([w()], Ot.prototype, "currentZoom", void 0), o([w()], Ot.prototype, "inputValue", void 0), Ot = o([b("webmapx-zoom-level")], Ot);
6282
5774
  //#endregion
6283
5775
  //#region src/components/webmapx-navigation-control.ts
6284
- var Z = class extends s {
5776
+ var X = class extends s {
6285
5777
  constructor(...e) {
6286
5778
  super(...e), this.orientation = "vertical", this.showCompass = !0, this.showZoom = !0, this.visualizePitch = !0, this.currentZoom = null, this.bearing = 0, this.pitch = 0, this.compassSupported = !1, this.unsubscribeEvents = [], this.zoomMin = null, this.zoomMax = null, this.compassRect = null, this.compassPointerId = null, this.compassPointerTarget = null, this.startBearing = 0, this.startPitch = 0, this.startPointer = null, this.compassDragMoved = !1, this.suppressNextCompassClick = !1, this.compassClickTolerance = 4, this.compassDragMode = null, this.handleZoomIn = () => {
6287
5779
  if (!this.adapter) return;
@@ -6324,7 +5816,7 @@ var Z = class extends s {
6324
5816
  };
6325
5817
  }
6326
5818
  static {
6327
- this.styles = D`
5819
+ this.styles = g`
6328
5820
  :host {
6329
5821
  display: inline-flex;
6330
5822
  pointer-events: auto;
@@ -6474,7 +5966,7 @@ var Z = class extends s {
6474
5966
  let e = [];
6475
5967
  e.push(`rotate(${this.normalizeBearing(-this.bearing)}deg)`), this.visualizePitch && e.unshift(`rotateX(${this.pitch}deg)`);
6476
5968
  let t = e.join(" ");
6477
- return O`
5969
+ return _`
6478
5970
  <button
6479
5971
  class="nav-btn"
6480
5972
  @click=${this.handleCompassClick}
@@ -6490,12 +5982,12 @@ var Z = class extends s {
6490
5982
  }
6491
5983
  render() {
6492
5984
  let e = this.showCompass && this.compassSupported, t = this.zoomMin ?? -Infinity, n = this.zoomMax ?? Infinity, r = this.currentZoom ?? 0;
6493
- return O`
5985
+ return _`
6494
5986
  <div class="nav-shell">
6495
- ${this.showZoom ? O`<button class="nav-btn" @click=${this.handleZoomIn} ?disabled=${r >= n} title="Zoom in">
5987
+ ${this.showZoom ? _`<button class="nav-btn" @click=${this.handleZoomIn} ?disabled=${r >= n} title="Zoom in">
6496
5988
  <span class="icon">+</span>
6497
5989
  </button>` : null}
6498
- ${this.showZoom ? O`<button class="nav-btn" @click=${this.handleZoomOut} ?disabled=${r <= t} title="Zoom out">
5990
+ ${this.showZoom ? _`<button class="nav-btn" @click=${this.handleZoomOut} ?disabled=${r <= t} title="Zoom out">
6499
5991
  <span class="icon">-</span>
6500
5992
  </button>` : null}
6501
5993
  ${e ? this.renderCompass() : null}
@@ -6503,30 +5995,30 @@ var Z = class extends s {
6503
5995
  `;
6504
5996
  }
6505
5997
  };
6506
- o([c({
5998
+ o([x({
6507
5999
  type: String,
6508
6000
  reflect: !0
6509
- })], Z.prototype, "orientation", void 0), o([c({
6001
+ })], X.prototype, "orientation", void 0), o([x({
6510
6002
  type: Boolean,
6511
6003
  attribute: "show-compass",
6512
6004
  reflect: !0
6513
- })], Z.prototype, "showCompass", void 0), o([c({
6005
+ })], X.prototype, "showCompass", void 0), o([x({
6514
6006
  type: Boolean,
6515
6007
  attribute: "show-zoom",
6516
6008
  reflect: !0
6517
- })], Z.prototype, "showZoom", void 0), o([c({
6009
+ })], X.prototype, "showZoom", void 0), o([x({
6518
6010
  type: Boolean,
6519
6011
  attribute: "visualize-pitch",
6520
6012
  reflect: !0
6521
- })], Z.prototype, "visualizePitch", void 0), o([l()], Z.prototype, "currentZoom", void 0), o([l()], Z.prototype, "bearing", void 0), o([l()], Z.prototype, "pitch", void 0), o([l()], Z.prototype, "compassSupported", void 0), Z = o([d("webmapx-navigation-control")], Z);
6013
+ })], X.prototype, "visualizePitch", void 0), o([w()], X.prototype, "currentZoom", void 0), o([w()], X.prototype, "bearing", void 0), o([w()], X.prototype, "pitch", void 0), o([w()], X.prototype, "compassSupported", void 0), X = o([b("webmapx-navigation-control")], X);
6522
6014
  //#endregion
6523
6015
  //#region src/components/webmapx-scale-control.ts
6524
- var rn = class extends s {
6016
+ var kt = class extends s {
6525
6017
  constructor(...e) {
6526
6018
  super(...e), this.maxWidth = 100, this.unit = "metric", this.barWidth = 0, this.label = "—", this.resizeObserver = null, this.unsubscribeEvents = [], this.lastBounds = null, this.lastCenter = null, this.lastZoom = null, this.hasLiveView = !1, this.attachedAdapter = null, this.lastUnprojectStatus = "none";
6527
6019
  }
6528
6020
  static {
6529
- this.styles = D`
6021
+ this.styles = g`
6530
6022
  :host {
6531
6023
  display: inline-flex;
6532
6024
  margin: var(--webmapx-tool-margin, 0);
@@ -6616,16 +6108,16 @@ var rn = class extends s {
6616
6108
  if (!a || a.status === "off-globe" || a.status === "failed") return this.lastUnprojectStatus = a?.status ?? "failed", null;
6617
6109
  if (this.lastZoom != null) {
6618
6110
  let t = n ?? this.lastCenter?.[1];
6619
- return an(this.lastZoom, t ?? 0) * e;
6111
+ return At(this.lastZoom, t ?? 0) * e;
6620
6112
  }
6621
6113
  let o = this.horizontalMetersAcrossBounds(this.lastBounds, n);
6622
6114
  return o && o > 0 && t > 0 ? o / t * e : null;
6623
6115
  }
6624
6116
  horizontalMetersAcrossBounds(e, t) {
6625
6117
  if (!e) return null;
6626
- let n = on(t ?? (e.sw[1] + e.ne[1]) / 2), r = e.sw[0], i = e.ne[0], a = sn(i - r);
6118
+ let n = jt(t ?? (e.sw[1] + e.ne[1]) / 2), r = e.sw[0], i = e.ne[0], a = Z(i - r);
6627
6119
  if (a <= 0) return null;
6628
- let o = cn * Math.cos(n * Math.PI / 180), s = Math.abs(a) * o;
6120
+ let o = Mt * Math.cos(n * Math.PI / 180), s = Math.abs(a) * o;
6629
6121
  return s > 0 ? s : null;
6630
6122
  }
6631
6123
  buildDisplay(e, t, n) {
@@ -6633,33 +6125,33 @@ var rn = class extends s {
6633
6125
  if (n === "imperial") {
6634
6126
  let n = e * 3.28084;
6635
6127
  if (n > 5280) {
6636
- let e = n / 5280, r = un(e);
6128
+ let e = n / 5280, r = Pt(e);
6637
6129
  return {
6638
6130
  widthPx: r / e * t,
6639
6131
  label: `${r} mi`
6640
6132
  };
6641
6133
  }
6642
- let r = un(n);
6134
+ let r = Pt(n);
6643
6135
  return {
6644
6136
  widthPx: r / n * t,
6645
6137
  label: `${r} ft`
6646
6138
  };
6647
6139
  }
6648
6140
  if (n === "nautical") {
6649
- let n = e / 1852, r = un(n);
6141
+ let n = e / 1852, r = Pt(n);
6650
6142
  return {
6651
6143
  widthPx: r / n * t,
6652
6144
  label: `${r} nm`
6653
6145
  };
6654
6146
  }
6655
6147
  if (e >= 1e3) {
6656
- let n = e / 1e3, r = un(n);
6148
+ let n = e / 1e3, r = Pt(n);
6657
6149
  return {
6658
6150
  widthPx: r / n * t,
6659
6151
  label: `${r} km`
6660
6152
  };
6661
6153
  }
6662
- let r = un(e);
6154
+ let r = Pt(e);
6663
6155
  return {
6664
6156
  widthPx: r / e * t,
6665
6157
  label: `${r} m`
@@ -6703,7 +6195,7 @@ var rn = class extends s {
6703
6195
  if (!isFinite(o) || (a = t, Math.abs(o - e) < .1)) break;
6704
6196
  o > e ? r = t : i = t;
6705
6197
  }
6706
- return on(a);
6198
+ return jt(a);
6707
6199
  }
6708
6200
  getTargetPixel(e) {
6709
6201
  let t = this.mapHost?.mapElement ?? this.mapHost;
@@ -6731,7 +6223,7 @@ var rn = class extends s {
6731
6223
  if (!this.attachedAdapter) return null;
6732
6224
  let l = this.attachedAdapter.unproject(s), u = this.attachedAdapter.unproject(c);
6733
6225
  if (!l || !u) return null;
6734
- let d = he(l, u) / 100;
6226
+ let d = p(l, u) / 100;
6735
6227
  return !isFinite(d) || d <= 0 ? null : { meters: d };
6736
6228
  }, c = n ?? o / 2, l = s(c, "primary");
6737
6229
  if (!l) {
@@ -6755,43 +6247,43 @@ var rn = class extends s {
6755
6247
  }
6756
6248
  render() {
6757
6249
  let e = this.barWidth <= 0, t = this.getSurfaceMetrics()?.width ?? this.getContainerWidth();
6758
- return O`
6250
+ return _`
6759
6251
  <div class="scale-shell" role="presentation" style=${`width: ${this.barWidth > 0 ? Math.max(0, Math.min(this.barWidth, t || Infinity)) : Math.min(this.maxWidthPx, t || this.maxWidthPx)}px`}>
6760
6252
  <div class="scale-label ${e ? "muted" : ""}">${this.label}</div>
6761
6253
  </div>
6762
6254
  `;
6763
6255
  }
6764
6256
  };
6765
- o([c({
6257
+ o([x({
6766
6258
  type: Number,
6767
6259
  attribute: "max-width"
6768
- })], rn.prototype, "maxWidth", void 0), o([c({
6260
+ })], kt.prototype, "maxWidth", void 0), o([x({
6769
6261
  type: String,
6770
6262
  attribute: "unit"
6771
- })], rn.prototype, "unit", void 0), o([l()], rn.prototype, "barWidth", void 0), o([l()], rn.prototype, "label", void 0), rn = o([d("webmapx-scale-control")], rn);
6772
- function an(e, t) {
6773
- let n = on(t) * Math.PI / 180;
6263
+ })], kt.prototype, "unit", void 0), o([w()], kt.prototype, "barWidth", void 0), o([w()], kt.prototype, "label", void 0), kt = o([b("webmapx-scale-control")], kt);
6264
+ function At(e, t) {
6265
+ let n = jt(t) * Math.PI / 180;
6774
6266
  return 40075016.68557849 * Math.cos(n) / (512 * 2 ** e);
6775
6267
  }
6776
- function on(e) {
6268
+ function jt(e) {
6777
6269
  return Math.max(-85.05112878, Math.min(85.05112878, e));
6778
6270
  }
6779
- function sn(e) {
6271
+ function Z(e) {
6780
6272
  let t = e;
6781
6273
  return t < 0 && (t += 360), t === 0 || t > 360 ? 360 : t;
6782
6274
  }
6783
- var cn = 111319.49079327357;
6784
- function ln(e) {
6275
+ var Mt = 111319.49079327357;
6276
+ function Nt(e) {
6785
6277
  let t = 10 ** Math.ceil(-Math.log(e) / Math.LN10);
6786
6278
  return Math.round(e * t) / t;
6787
6279
  }
6788
- function un(e) {
6280
+ function Pt(e) {
6789
6281
  let t = 10 ** (`${Math.floor(e)}`.length - 1), n = e / t;
6790
- return n = n >= 10 ? 10 : n >= 5 ? 5 : n >= 3 ? 3 : n >= 2 ? 2 : n >= 1 ? 1 : ln(n), t * n;
6282
+ return n = n >= 10 ? 10 : n >= 5 ? 5 : n >= 3 ? 3 : n >= 2 ? 2 : n >= 1 ? 1 : Nt(n), t * n;
6791
6283
  }
6792
6284
  //#endregion
6793
6285
  //#region src/components/webmapx-fullscreen-control.ts
6794
- var dn = class extends s {
6286
+ var Ft = class extends s {
6795
6287
  constructor(...e) {
6796
6288
  super(...e), this.isFullscreen = !1, this.handleFullscreenChange = () => {
6797
6289
  this.isFullscreen = document.fullscreenElement === this.fullscreenTarget();
@@ -6800,7 +6292,7 @@ var dn = class extends s {
6800
6292
  };
6801
6293
  }
6802
6294
  static {
6803
- this.styles = D`
6295
+ this.styles = g`
6804
6296
  :host {
6805
6297
  display: inline-flex;
6806
6298
  pointer-events: auto;
@@ -6864,19 +6356,19 @@ var dn = class extends s {
6864
6356
  return a(this) ?? this;
6865
6357
  }
6866
6358
  render() {
6867
- return O`
6359
+ return _`
6868
6360
  <div class="nav-shell">
6869
6361
  <button class="nav-btn" @click=${this.handleToggle} title="${this.isFullscreen ? "Exit fullscreen" : "Fullscreen"}" aria-label="Toggle fullscreen">
6870
- ${this.isFullscreen ? O`<svg viewBox="0 0 24 24"><path d="M9 3v3a2 2 0 0 1-2 2H4M21 9h-3a2 2 0 0 1-2-2V4M3 15h3a2 2 0 0 1 2 2v3M15 21v-3a2 2 0 0 1 2-2h3"/></svg>` : O`<svg viewBox="0 0 24 24"><path d="M4 9V4h5M20 9V4h-5M4 15v5h5M20 15v5h-5"/></svg>`}
6362
+ ${this.isFullscreen ? _`<svg viewBox="0 0 24 24"><path d="M9 3v3a2 2 0 0 1-2 2H4M21 9h-3a2 2 0 0 1-2-2V4M3 15h3a2 2 0 0 1 2 2v3M15 21v-3a2 2 0 0 1 2-2h3"/></svg>` : _`<svg viewBox="0 0 24 24"><path d="M4 9V4h5M20 9V4h-5M4 15v5h5M20 15v5h-5"/></svg>`}
6871
6363
  </button>
6872
6364
  </div>
6873
6365
  `;
6874
6366
  }
6875
6367
  };
6876
- o([l()], dn.prototype, "isFullscreen", void 0), dn = o([d("webmapx-fullscreen-control")], dn);
6368
+ o([w()], Ft.prototype, "isFullscreen", void 0), Ft = o([b("webmapx-fullscreen-control")], Ft);
6877
6369
  //#endregion
6878
6370
  //#region src/components/webmapx-attribution-control.ts
6879
- var Q = class extends s {
6371
+ var It = class extends s {
6880
6372
  constructor(...e) {
6881
6373
  super(...e), this.attributions = [], this._showLeft = !1, this._showRight = !1, this.layerData = null, this.visibleLayerIds = [], this.mapLayersState = {}, this._dragStartX = 0, this._dragStartScroll = 0, this._dragging = !1;
6882
6374
  }
@@ -6918,7 +6410,7 @@ var Q = class extends s {
6918
6410
  t && i(t);
6919
6411
  continue;
6920
6412
  }
6921
- let o = de(a, e);
6413
+ let o = l(a, e);
6922
6414
  o && i(o);
6923
6415
  }
6924
6416
  this.attributions = r, this.updateComplete.then(() => this._updateOverflow());
@@ -6947,23 +6439,23 @@ var Q = class extends s {
6947
6439
  }, { passive: !0 });
6948
6440
  }
6949
6441
  render() {
6950
- return O`
6442
+ return _`
6951
6443
  <div class="attribution-shell" ?hidden=${!(this.attributions.length > 0)} role="region" aria-label="Map attributions">
6952
- ${this._showLeft ? O`<span class="overflow-indicator left" aria-hidden="true">‹</span>` : null}
6444
+ ${this._showLeft ? _`<span class="overflow-indicator left" aria-hidden="true">‹</span>` : null}
6953
6445
  <div class="attribution-scroll">
6954
6446
  <div class="attribution-inner">
6955
- ${this.attributions.map((e, t) => O`
6956
- ${T(e)}
6957
- ${t < this.attributions.length - 1 ? O`<span class="separator">•</span>` : null}
6447
+ ${this.attributions.map((e, t) => _`
6448
+ ${c(e)}
6449
+ ${t < this.attributions.length - 1 ? _`<span class="separator">•</span>` : null}
6958
6450
  `)}
6959
6451
  </div>
6960
6452
  </div>
6961
- ${this._showRight ? O`<span class="overflow-indicator right" aria-hidden="true">›</span>` : null}
6453
+ ${this._showRight ? _`<span class="overflow-indicator right" aria-hidden="true">›</span>` : null}
6962
6454
  </div>
6963
6455
  `;
6964
6456
  }
6965
6457
  static {
6966
- this.styles = D`
6458
+ this.styles = g`
6967
6459
  :host {
6968
6460
  display: flex;
6969
6461
  justify-content: flex-end;
@@ -7039,419 +6531,15 @@ var Q = class extends s {
7039
6531
  `;
7040
6532
  }
7041
6533
  };
7042
- o([l()], Q.prototype, "attributions", void 0), o([l()], Q.prototype, "_showLeft", void 0), o([l()], Q.prototype, "_showRight", void 0), o([u(".attribution-scroll")], Q.prototype, "_scrollEl", void 0), Q = o([d("webmapx-attribution-control")], Q);
7043
- //#endregion
7044
- //#region node_modules/@shoelace-style/shoelace/dist/chunks/chunk.5D6IT2SR.js
7045
- var fn = D`
7046
- :host {
7047
- --thumb-size: 20px;
7048
- --tooltip-offset: 10px;
7049
- --track-color-active: var(--sl-color-neutral-200);
7050
- --track-color-inactive: var(--sl-color-neutral-200);
7051
- --track-active-offset: 0%;
7052
- --track-height: 6px;
7053
-
7054
- display: block;
7055
- }
7056
-
7057
- .range {
7058
- position: relative;
7059
- }
7060
-
7061
- .range__control {
7062
- --percent: 0%;
7063
- -webkit-appearance: none;
7064
- border-radius: 3px;
7065
- width: 100%;
7066
- height: var(--track-height);
7067
- background: transparent;
7068
- line-height: var(--sl-input-height-medium);
7069
- vertical-align: middle;
7070
- margin: 0;
7071
-
7072
- background-image: linear-gradient(
7073
- to right,
7074
- var(--track-color-inactive) 0%,
7075
- var(--track-color-inactive) min(var(--percent), var(--track-active-offset)),
7076
- var(--track-color-active) min(var(--percent), var(--track-active-offset)),
7077
- var(--track-color-active) max(var(--percent), var(--track-active-offset)),
7078
- var(--track-color-inactive) max(var(--percent), var(--track-active-offset)),
7079
- var(--track-color-inactive) 100%
7080
- );
7081
- }
7082
-
7083
- .range--rtl .range__control {
7084
- background-image: linear-gradient(
7085
- to left,
7086
- var(--track-color-inactive) 0%,
7087
- var(--track-color-inactive) min(var(--percent), var(--track-active-offset)),
7088
- var(--track-color-active) min(var(--percent), var(--track-active-offset)),
7089
- var(--track-color-active) max(var(--percent), var(--track-active-offset)),
7090
- var(--track-color-inactive) max(var(--percent), var(--track-active-offset)),
7091
- var(--track-color-inactive) 100%
7092
- );
7093
- }
7094
-
7095
- /* Webkit */
7096
- .range__control::-webkit-slider-runnable-track {
7097
- width: 100%;
7098
- height: var(--track-height);
7099
- border-radius: 3px;
7100
- border: none;
7101
- }
7102
-
7103
- .range__control::-webkit-slider-thumb {
7104
- border: none;
7105
- width: var(--thumb-size);
7106
- height: var(--thumb-size);
7107
- border-radius: 50%;
7108
- background-color: var(--sl-color-primary-600);
7109
- border: solid var(--sl-input-border-width) var(--sl-color-primary-600);
7110
- -webkit-appearance: none;
7111
- margin-top: calc(var(--thumb-size) / -2 + var(--track-height) / 2);
7112
- cursor: pointer;
7113
- }
7114
-
7115
- .range__control:enabled::-webkit-slider-thumb:hover {
7116
- background-color: var(--sl-color-primary-500);
7117
- border-color: var(--sl-color-primary-500);
7118
- }
7119
-
7120
- .range__control:enabled:focus-visible::-webkit-slider-thumb {
7121
- outline: var(--sl-focus-ring);
7122
- outline-offset: var(--sl-focus-ring-offset);
7123
- }
7124
-
7125
- .range__control:enabled::-webkit-slider-thumb:active {
7126
- background-color: var(--sl-color-primary-500);
7127
- border-color: var(--sl-color-primary-500);
7128
- cursor: grabbing;
7129
- }
7130
-
7131
- /* Firefox */
7132
- .range__control::-moz-focus-outer {
7133
- border: 0;
7134
- }
7135
-
7136
- .range__control::-moz-range-progress {
7137
- background-color: var(--track-color-active);
7138
- border-radius: 3px;
7139
- height: var(--track-height);
7140
- }
7141
-
7142
- .range__control::-moz-range-track {
7143
- width: 100%;
7144
- height: var(--track-height);
7145
- background-color: var(--track-color-inactive);
7146
- border-radius: 3px;
7147
- border: none;
7148
- }
7149
-
7150
- .range__control::-moz-range-thumb {
7151
- border: none;
7152
- height: var(--thumb-size);
7153
- width: var(--thumb-size);
7154
- border-radius: 50%;
7155
- background-color: var(--sl-color-primary-600);
7156
- border-color: var(--sl-color-primary-600);
7157
- transition:
7158
- var(--sl-transition-fast) border-color,
7159
- var(--sl-transition-fast) background-color,
7160
- var(--sl-transition-fast) color,
7161
- var(--sl-transition-fast) box-shadow;
7162
- cursor: pointer;
7163
- }
7164
-
7165
- .range__control:enabled::-moz-range-thumb:hover {
7166
- background-color: var(--sl-color-primary-500);
7167
- border-color: var(--sl-color-primary-500);
7168
- }
7169
-
7170
- .range__control:enabled:focus-visible::-moz-range-thumb {
7171
- outline: var(--sl-focus-ring);
7172
- outline-offset: var(--sl-focus-ring-offset);
7173
- }
7174
-
7175
- .range__control:enabled::-moz-range-thumb:active {
7176
- background-color: var(--sl-color-primary-500);
7177
- border-color: var(--sl-color-primary-500);
7178
- cursor: grabbing;
7179
- }
7180
-
7181
- /* States */
7182
- .range__control:focus-visible {
7183
- outline: none;
7184
- }
7185
-
7186
- .range__control:disabled {
7187
- opacity: 0.5;
7188
- }
7189
-
7190
- .range__control:disabled::-webkit-slider-thumb {
7191
- cursor: not-allowed;
7192
- }
7193
-
7194
- .range__control:disabled::-moz-range-thumb {
7195
- cursor: not-allowed;
7196
- }
7197
-
7198
- /* Tooltip output */
7199
- .range__tooltip {
7200
- position: absolute;
7201
- z-index: var(--sl-z-index-tooltip);
7202
- left: 0;
7203
- border-radius: var(--sl-tooltip-border-radius);
7204
- background-color: var(--sl-tooltip-background-color);
7205
- font-family: var(--sl-tooltip-font-family);
7206
- font-size: var(--sl-tooltip-font-size);
7207
- font-weight: var(--sl-tooltip-font-weight);
7208
- line-height: var(--sl-tooltip-line-height);
7209
- color: var(--sl-tooltip-color);
7210
- opacity: 0;
7211
- padding: var(--sl-tooltip-padding);
7212
- transition: var(--sl-transition-fast) opacity;
7213
- pointer-events: none;
7214
- }
7215
-
7216
- .range__tooltip:after {
7217
- content: '';
7218
- position: absolute;
7219
- width: 0;
7220
- height: 0;
7221
- left: 50%;
7222
- translate: calc(-1 * var(--sl-tooltip-arrow-size));
7223
- }
7224
-
7225
- .range--tooltip-visible .range__tooltip {
7226
- opacity: 1;
7227
- }
7228
-
7229
- /* Tooltip on top */
7230
- .range--tooltip-top .range__tooltip {
7231
- top: calc(-1 * var(--thumb-size) - var(--tooltip-offset));
7232
- }
7233
-
7234
- .range--tooltip-top .range__tooltip:after {
7235
- border-top: var(--sl-tooltip-arrow-size) solid var(--sl-tooltip-background-color);
7236
- border-left: var(--sl-tooltip-arrow-size) solid transparent;
7237
- border-right: var(--sl-tooltip-arrow-size) solid transparent;
7238
- top: 100%;
7239
- }
7240
-
7241
- /* Tooltip on bottom */
7242
- .range--tooltip-bottom .range__tooltip {
7243
- bottom: calc(-1 * var(--thumb-size) - var(--tooltip-offset));
7244
- }
7245
-
7246
- .range--tooltip-bottom .range__tooltip:after {
7247
- border-bottom: var(--sl-tooltip-arrow-size) solid var(--sl-tooltip-background-color);
7248
- border-left: var(--sl-tooltip-arrow-size) solid transparent;
7249
- border-right: var(--sl-tooltip-arrow-size) solid transparent;
7250
- bottom: 100%;
7251
- }
7252
-
7253
- @media (forced-colors: active) {
7254
- .range__control,
7255
- .range__tooltip {
7256
- border: solid 1px transparent;
7257
- }
7258
-
7259
- .range__control::-webkit-slider-thumb {
7260
- border: solid 1px transparent;
7261
- }
7262
-
7263
- .range__control::-moz-range-thumb {
7264
- border: solid 1px transparent;
7265
- }
7266
-
7267
- .range__tooltip:after {
7268
- display: none;
7269
- }
7270
- }
7271
- `, $ = class extends x {
7272
- constructor() {
7273
- super(...arguments), this.formControlController = new ie(this), this.hasSlotController = new te(this, "help-text", "label"), this.localize = new ne(this), this.hasFocus = !1, this.hasTooltip = !1, this.title = "", this.name = "", this.value = 0, this.label = "", this.helpText = "", this.disabled = !1, this.min = 0, this.max = 100, this.step = 1, this.tooltip = "top", this.tooltipFormatter = (e) => e.toString(), this.form = "", this.defaultValue = 0;
7274
- }
7275
- get validity() {
7276
- return this.input.validity;
7277
- }
7278
- get validationMessage() {
7279
- return this.input.validationMessage;
7280
- }
7281
- connectedCallback() {
7282
- super.connectedCallback(), this.resizeObserver = new ResizeObserver(() => this.syncRange()), this.value < this.min && (this.value = this.min), this.value > this.max && (this.value = this.max), this.updateComplete.then(() => {
7283
- this.syncRange(), this.resizeObserver.observe(this.input);
7284
- });
7285
- }
7286
- disconnectedCallback() {
7287
- var e;
7288
- super.disconnectedCallback(), (e = this.resizeObserver) == null || e.unobserve(this.input);
7289
- }
7290
- handleChange() {
7291
- this.emit("sl-change");
7292
- }
7293
- handleInput() {
7294
- this.value = parseFloat(this.input.value), this.emit("sl-input"), this.syncRange();
7295
- }
7296
- handleBlur() {
7297
- this.hasFocus = !1, this.hasTooltip = !1, this.emit("sl-blur");
7298
- }
7299
- handleFocus() {
7300
- this.hasFocus = !0, this.hasTooltip = !0, this.emit("sl-focus");
7301
- }
7302
- handleThumbDragStart() {
7303
- this.hasTooltip = !0;
7304
- }
7305
- handleThumbDragEnd() {
7306
- this.hasTooltip = !1;
7307
- }
7308
- syncProgress(e) {
7309
- this.input.style.setProperty("--percent", `${e * 100}%`);
7310
- }
7311
- syncTooltip(e) {
7312
- if (this.output !== null) {
7313
- let t = this.input.offsetWidth, n = this.output.offsetWidth, r = getComputedStyle(this.input).getPropertyValue("--thumb-size"), i = this.localize.dir() === "rtl", a = t * e;
7314
- if (i) {
7315
- let i = `${t - a}px + ${e} * ${r}`;
7316
- this.output.style.translate = `calc((${i} - ${n / 2}px - ${r} / 2))`;
7317
- } else {
7318
- let t = `${a}px - ${e} * ${r}`;
7319
- this.output.style.translate = `calc(${t} - ${n / 2}px + ${r} / 2)`;
7320
- }
7321
- }
7322
- }
7323
- handleValueChange() {
7324
- this.formControlController.updateValidity(), this.input.value = this.value.toString(), this.value = parseFloat(this.input.value), this.syncRange();
7325
- }
7326
- handleDisabledChange() {
7327
- this.formControlController.setValidity(this.disabled);
7328
- }
7329
- syncRange() {
7330
- let e = Math.max(0, (this.value - this.min) / (this.max - this.min));
7331
- this.syncProgress(e), this.tooltip !== "none" && this.hasTooltip && this.updateComplete.then(() => this.syncTooltip(e));
7332
- }
7333
- handleInvalid(e) {
7334
- this.formControlController.setValidity(!1), this.formControlController.emitInvalidEvent(e);
7335
- }
7336
- focus(e) {
7337
- this.input.focus(e);
7338
- }
7339
- blur() {
7340
- this.input.blur();
7341
- }
7342
- stepUp() {
7343
- this.input.stepUp(), this.value !== Number(this.input.value) && (this.value = Number(this.input.value));
7344
- }
7345
- stepDown() {
7346
- this.input.stepDown(), this.value !== Number(this.input.value) && (this.value = Number(this.input.value));
7347
- }
7348
- checkValidity() {
7349
- return this.input.checkValidity();
7350
- }
7351
- getForm() {
7352
- return this.formControlController.getForm();
7353
- }
7354
- reportValidity() {
7355
- return this.input.reportValidity();
7356
- }
7357
- setCustomValidity(e) {
7358
- this.input.setCustomValidity(e), this.formControlController.updateValidity();
7359
- }
7360
- render() {
7361
- let e = this.hasSlotController.test("label"), t = this.hasSlotController.test("help-text"), n = this.label ? !0 : !!e, r = this.helpText ? !0 : !!t;
7362
- return O`
7363
- <div
7364
- part="form-control"
7365
- class=${ee({
7366
- "form-control": !0,
7367
- "form-control--medium": !0,
7368
- "form-control--has-label": n,
7369
- "form-control--has-help-text": r
7370
- })}
7371
- >
7372
- <label
7373
- part="form-control-label"
7374
- class="form-control__label"
7375
- for="input"
7376
- aria-hidden=${n ? "false" : "true"}
7377
- >
7378
- <slot name="label">${this.label}</slot>
7379
- </label>
7380
-
7381
- <div part="form-control-input" class="form-control-input">
7382
- <div
7383
- part="base"
7384
- class=${ee({
7385
- range: !0,
7386
- "range--disabled": this.disabled,
7387
- "range--focused": this.hasFocus,
7388
- "range--rtl": this.localize.dir() === "rtl",
7389
- "range--tooltip-visible": this.hasTooltip,
7390
- "range--tooltip-top": this.tooltip === "top",
7391
- "range--tooltip-bottom": this.tooltip === "bottom"
7392
- })}
7393
- @mousedown=${this.handleThumbDragStart}
7394
- @mouseup=${this.handleThumbDragEnd}
7395
- @touchstart=${this.handleThumbDragStart}
7396
- @touchend=${this.handleThumbDragEnd}
7397
- >
7398
- <input
7399
- part="input"
7400
- id="input"
7401
- class="range__control"
7402
- title=${this.title}
7403
- type="range"
7404
- name=${w(this.name)}
7405
- ?disabled=${this.disabled}
7406
- min=${w(this.min)}
7407
- max=${w(this.max)}
7408
- step=${w(this.step)}
7409
- .value=${oe(this.value.toString())}
7410
- aria-describedby="help-text"
7411
- @change=${this.handleChange}
7412
- @focus=${this.handleFocus}
7413
- @input=${this.handleInput}
7414
- @invalid=${this.handleInvalid}
7415
- @blur=${this.handleBlur}
7416
- />
7417
- ${this.tooltip !== "none" && !this.disabled ? O`
7418
- <output part="tooltip" class="range__tooltip">
7419
- ${typeof this.tooltipFormatter == "function" ? this.tooltipFormatter(this.value) : this.value}
7420
- </output>
7421
- ` : ""}
7422
- </div>
7423
- </div>
7424
-
7425
- <div
7426
- part="form-control-help-text"
7427
- id="help-text"
7428
- class="form-control__help-text"
7429
- aria-hidden=${r ? "false" : "true"}
7430
- >
7431
- <slot name="help-text">${this.helpText}</slot>
7432
- </div>
7433
- </div>
7434
- `;
7435
- }
7436
- };
7437
- //#endregion
7438
- //#region node_modules/@shoelace-style/shoelace/dist/chunks/chunk.CKH4GVK3.js
7439
- $.styles = [
7440
- C,
7441
- ce,
7442
- fn
7443
- ], b([u(".range__control")], $.prototype, "input", 2), b([u(".range__tooltip")], $.prototype, "output", 2), b([l()], $.prototype, "hasFocus", 2), b([l()], $.prototype, "hasTooltip", 2), b([c()], $.prototype, "title", 2), b([c()], $.prototype, "name", 2), b([c({ type: Number })], $.prototype, "value", 2), b([c()], $.prototype, "label", 2), b([c({ attribute: "help-text" })], $.prototype, "helpText", 2), b([c({
7444
- type: Boolean,
7445
- reflect: !0
7446
- })], $.prototype, "disabled", 2), b([c({ type: Number })], $.prototype, "min", 2), b([c({ type: Number })], $.prototype, "max", 2), b([c({ type: Number })], $.prototype, "step", 2), b([c()], $.prototype, "tooltip", 2), b([c({ attribute: !1 })], $.prototype, "tooltipFormatter", 2), b([c({ reflect: !0 })], $.prototype, "form", 2), b([se()], $.prototype, "defaultValue", 2), b([f({ passive: !0 })], $.prototype, "handleThumbDragStart", 1), b([y("value", { waitUntilFirstUpdate: !0 })], $.prototype, "handleValueChange", 1), b([y("disabled", { waitUntilFirstUpdate: !0 })], $.prototype, "handleDisabledChange", 1), b([y("hasTooltip", { waitUntilFirstUpdate: !0 })], $.prototype, "syncRange", 1), $.define("sl-range");
6534
+ o([w()], It.prototype, "attributions", void 0), o([w()], It.prototype, "_showLeft", void 0), o([w()], It.prototype, "_showRight", void 0), o([S(".attribution-scroll")], It.prototype, "_scrollEl", void 0), It = o([b("webmapx-attribution-control")], It);
7447
6535
  //#endregion
7448
6536
  //#region src/components/webmapx-tool-template.ts
7449
- var pn = class extends s {
6537
+ var Lt = class extends s {
7450
6538
  constructor(...e) {
7451
6539
  super(...e), this.bufferRadius = 0, this.isToolActive = !1, this.toolService = null;
7452
6540
  }
7453
6541
  static {
7454
- this.styles = D`
6542
+ this.styles = g`
7455
6543
  :host {
7456
6544
  display: inline-flex;
7457
6545
  pointer-events: auto;
@@ -7497,7 +6585,7 @@ var pn = class extends s {
7497
6585
  this.toolService?.toggleTool();
7498
6586
  }
7499
6587
  render() {
7500
- return O`
6588
+ return _`
7501
6589
  <div class="tool-container">
7502
6590
  <div class="tool-title">Template Tool — Buffer</div>
7503
6591
  <div class="radius-row">
@@ -7521,14 +6609,14 @@ var pn = class extends s {
7521
6609
  `;
7522
6610
  }
7523
6611
  };
7524
- o([l()], pn.prototype, "bufferRadius", void 0), o([l()], pn.prototype, "isToolActive", void 0), pn = o([d("webmapx-tool-template")], pn);
6612
+ o([w()], Lt.prototype, "bufferRadius", void 0), o([w()], Lt.prototype, "isToolActive", void 0), Lt = o([b("webmapx-tool-template")], Lt);
7525
6613
  //#endregion
7526
6614
  //#region src/components/webmapx-inset-map.ts
7527
- var mn = "https://demotiles.maplibre.org/style.json", hn = 0, gn = 22, _n = 85.05112878, vn = 89.999, yn = 1, bn = "viewport", xn = "viewport-fill", Sn = "viewport-outline", Cn = class extends E {
6615
+ var Rt = "https://demotiles.maplibre.org/style.json", zt = 0, Bt = 22, Vt = 85.05112878, Ht = 89.999, Q = 1, Ut = "viewport", Wt = "viewport-fill", Gt = "viewport-outline", $ = class extends h {
7528
6616
  constructor(...e) {
7529
- super(...e), this.zoomOffset = -3, this.baseScale = .5, this.minimizable = !1, this._collapsed = !1, this.adapter = null, this.insetMap = null, this.viewportSource = null, this.unsubscribe = null, this.lastCenter = null, this.lastZoom = null, this.lastSourceZoom = null, this.projectionMode = "mercator", this.lastBoundsKey = null, this.initPromise = null, this.pendingViewportBounds = null, this.throttledViewportUpdate = ge(() => {
6617
+ super(...e), this.zoomOffset = -3, this.baseScale = .5, this.minimizable = !1, this._collapsed = !1, this.adapter = null, this.insetMap = null, this.viewportSource = null, this.unsubscribe = null, this.lastCenter = null, this.lastZoom = null, this.lastSourceZoom = null, this.projectionMode = "mercator", this.lastBoundsKey = null, this.initPromise = null, this.pendingViewportBounds = null, this.throttledViewportUpdate = m(() => {
7530
6618
  this.doUpdateViewportRectangle(this.pendingViewportBounds), this.pendingViewportBounds = void 0;
7531
- }, 50), this.throttledRenderLog = ge((e) => {}, 50), this.throttledApplyStateWithZoomOffset = ge((e, t) => {
6619
+ }, 50), this.throttledRenderLog = m((e) => {}, 50), this.throttledApplyStateWithZoomOffset = m((e, t) => {
7532
6620
  this.applyState(e, t);
7533
6621
  }, 50);
7534
6622
  }
@@ -7536,7 +6624,7 @@ var mn = "https://demotiles.maplibre.org/style.json", hn = 0, gn = 22, _n = 85.0
7536
6624
  return this.renderRoot.querySelector(".inset-map");
7537
6625
  }
7538
6626
  static {
7539
- this.styles = D`
6627
+ this.styles = g`
7540
6628
  :host {
7541
6629
  display: inline-block;
7542
6630
  position: relative;
@@ -7636,7 +6724,7 @@ var mn = "https://demotiles.maplibre.org/style.json", hn = 0, gn = 22, _n = 85.0
7636
6724
  let r = this.adapter.store.getState();
7637
6725
  await this.waitForConfig(t);
7638
6726
  let i = this.resolveInsetToolConfig(t), o = this.resolveInsetNumber("zoom-offset", this.zoomOffset, i.zoomOffset), s = this.resolveInsetNumber("base-scale", this.baseScale, i.baseScale), c = this.backgroundLayer ? this.resolveBackgroundFromLayer(t, this.backgroundLayer) : null, l = this.hasAttribute("style-url") ? this.styleUrl : c?.styleUrl ?? i.styleUrl, u = c ? c.background ?? null : this.resolveInsetBackground(i), d = {
7639
- styleUrl: l ?? mn,
6727
+ styleUrl: l ?? Rt,
7640
6728
  center: r.mapCenter ?? [0, 0],
7641
6729
  zoom: this.clampZoom((r.zoomLevel ?? 0) + o),
7642
6730
  interactive: !1,
@@ -7708,7 +6796,7 @@ var mn = "https://demotiles.maplibre.org/style.json", hn = 0, gn = 22, _n = 85.0
7708
6796
  t.length && t.reduce((e, [, t]) => Math.max(e, Math.abs(t)), 0) > 85.05212878 && (this.projectionMode = "geodetic");
7709
6797
  }
7710
6798
  maxViewportLat() {
7711
- return this.projectionMode === "geodetic" ? vn : _n;
6799
+ return this.projectionMode === "geodetic" ? Ht : Vt;
7712
6800
  }
7713
6801
  setupViewportLayers() {
7714
6802
  if (!this.insetMap) return;
@@ -7716,18 +6804,18 @@ var mn = "https://demotiles.maplibre.org/style.json", hn = 0, gn = 22, _n = 85.0
7716
6804
  type: "FeatureCollection",
7717
6805
  features: []
7718
6806
  };
7719
- this.viewportSource = this.insetMap.createSource(bn, e), this.insetMap.createLayer({
7720
- id: xn,
6807
+ this.viewportSource = this.insetMap.createSource(Ut, e), this.insetMap.createLayer({
6808
+ id: Wt,
7721
6809
  type: "fill",
7722
- sourceId: bn,
6810
+ sourceId: Ut,
7723
6811
  paint: {
7724
6812
  "fill-color": "#0f62fe",
7725
6813
  "fill-opacity": .15
7726
6814
  }
7727
6815
  }), this.insetMap.createLayer({
7728
- id: Sn,
6816
+ id: Gt,
7729
6817
  type: "line",
7730
- sourceId: bn,
6818
+ sourceId: Ut,
7731
6819
  paint: {
7732
6820
  "line-color": "#0f62fe",
7733
6821
  "line-width": 1.5
@@ -8091,29 +7179,29 @@ var mn = "https://demotiles.maplibre.org/style.json", hn = 0, gn = 22, _n = 85.0
8091
7179
  return !Number.isFinite(t) || !Number.isFinite(n) ? null : (n = this.clampLat(n), t = this.normalizeLng(t), [t, n]);
8092
7180
  }
8093
7181
  clampZoom(e) {
8094
- return Math.min(gn, Math.max(hn, e));
7182
+ return Math.min(Bt, Math.max(zt, e));
8095
7183
  }
8096
7184
  resolveViewState(e) {
8097
7185
  if (e <= 0) return {
8098
7186
  mapZoom: 0,
8099
7187
  scale: this.baseScale
8100
7188
  };
8101
- if (e <= yn) return {
7189
+ if (e <= Q) return {
8102
7190
  mapZoom: 0,
8103
- scale: this.baseScale + (1 - this.baseScale) * (e / yn)
7191
+ scale: this.baseScale + (1 - this.baseScale) * (e / Q)
8104
7192
  };
8105
- let t = e - yn;
7193
+ let t = e - Q;
8106
7194
  return {
8107
7195
  mapZoom: this.clampZoom(t),
8108
7196
  scale: 1
8109
7197
  };
8110
7198
  }
8111
7199
  render() {
8112
- return O`
7200
+ return _`
8113
7201
  <div class="inset-map-frame ${this._collapsed ? "hidden" : ""}" tabindex=${this.minimizable ? "0" : "-1"}>
8114
7202
  <div class="inset-map"></div>
8115
7203
  </div>
8116
- ${this.minimizable ? O`
7204
+ ${this.minimizable ? _`
8117
7205
  <div class="toggle-btn">
8118
7206
  <sl-icon-button
8119
7207
  name=${this._collapsed ? "arrows-angle-expand" : "arrows-angle-contract"}
@@ -8127,39 +7215,39 @@ var mn = "https://demotiles.maplibre.org/style.json", hn = 0, gn = 22, _n = 85.0
8127
7215
  `;
8128
7216
  }
8129
7217
  };
8130
- o([c({
7218
+ o([x({
8131
7219
  type: Number,
8132
7220
  attribute: "zoom-offset"
8133
- })], Cn.prototype, "zoomOffset", void 0), o([c({
7221
+ })], $.prototype, "zoomOffset", void 0), o([x({
8134
7222
  type: String,
8135
7223
  attribute: "style-url"
8136
- })], Cn.prototype, "styleUrl", void 0), o([c({
7224
+ })], $.prototype, "styleUrl", void 0), o([x({
8137
7225
  type: String,
8138
7226
  attribute: "background-layer"
8139
- })], Cn.prototype, "backgroundLayer", void 0), o([c({
7227
+ })], $.prototype, "backgroundLayer", void 0), o([x({
8140
7228
  type: Number,
8141
7229
  attribute: "base-scale"
8142
- })], Cn.prototype, "baseScale", void 0), o([c({
7230
+ })], $.prototype, "baseScale", void 0), o([x({
8143
7231
  type: Boolean,
8144
7232
  attribute: "minimizable"
8145
- })], Cn.prototype, "minimizable", void 0), o([c({
7233
+ })], $.prototype, "minimizable", void 0), o([x({
8146
7234
  type: Boolean,
8147
7235
  reflect: !0,
8148
7236
  attribute: "collapsed"
8149
- })], Cn.prototype, "_collapsed", void 0), Cn = o([d("webmapx-inset-map")], Cn);
7237
+ })], $.prototype, "_collapsed", void 0), $ = o([b("webmapx-inset-map")], $);
8150
7238
  //#endregion
8151
7239
  //#region src/components/webmapx-active-adapter.ts
8152
- var wn = {
7240
+ var Kt = {
8153
7241
  maplibre: "MapLibre GL",
8154
7242
  openlayers: "OpenLayers",
8155
7243
  leaflet: "Leaflet",
8156
7244
  cesium: "Cesium"
8157
- }, Tn = class extends s {
7245
+ }, qt = class extends s {
8158
7246
  constructor(...e) {
8159
7247
  super(...e), this.adapterName = "—", this.engineVersion = "";
8160
7248
  }
8161
7249
  static {
8162
- this.styles = D`
7250
+ this.styles = g`
8163
7251
  :host { display: inline-block; }
8164
7252
  .badge {
8165
7253
  display: inline-flex;
@@ -8183,7 +7271,7 @@ var wn = {
8183
7271
  }
8184
7272
  onStateChanged() {}
8185
7273
  onMapAttached(e) {
8186
- this.adapterName = wn[e.engineId] ?? e.engineId;
7274
+ this.adapterName = Kt[e.engineId] ?? e.engineId;
8187
7275
  let t = e.engineVersion?.split(".");
8188
7276
  this.engineVersion = t ? `${t[0]}.${t[1]}` : "";
8189
7277
  }
@@ -8191,7 +7279,7 @@ var wn = {
8191
7279
  this.adapterName = "—", this.engineVersion = "";
8192
7280
  }
8193
7281
  render() {
8194
- return O`
7282
+ return _`
8195
7283
  <span class="badge">
8196
7284
  <span class="dot"></span>
8197
7285
  ${this.adapterName}${this.engineVersion ? ` ${this.engineVersion}` : ""}
@@ -8199,5 +7287,5 @@ var wn = {
8199
7287
  `;
8200
7288
  }
8201
7289
  };
8202
- o([l()], Tn.prototype, "adapterName", void 0), o([l()], Tn.prototype, "engineVersion", void 0), Tn = o([d("webmapx-active-adapter")], Tn);
7290
+ o([w()], qt.prototype, "adapterName", void 0), o([w()], qt.prototype, "engineVersion", void 0), qt = o([b("webmapx-active-adapter")], qt);
8203
7291
  //#endregion