@datagouv/components-next 1.0.2-dev.9 → 1.0.2-dev.90

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 (96) hide show
  1. package/assets/main.css +4 -0
  2. package/dist/{Control-DuZJdKV_.js → Control-ZFh5ta_U.js} +1 -1
  3. package/dist/Datafair.client-CyZRNADr.js +30 -0
  4. package/dist/{Event--kp8kMdJ.js → Event-DSQcW7OF.js} +24 -24
  5. package/dist/{Image-34hvypZI.js → Image-BijNEG0p.js} +6 -6
  6. package/dist/JsonPreview.client-C9iaPSmQ.js +40 -0
  7. package/dist/{Map-BjUnLyj8.js → Map-BUtPf5GN.js} +756 -756
  8. package/dist/MapContainer.client-BuoZ69XO.js +101 -0
  9. package/dist/{OSM-s40W6sQ2.js → OSM-D4MTdBtk.js} +2 -2
  10. package/dist/{PdfPreview.client-BVjPxlPu.js → PdfPreview.client-MI0bDghc.js} +822 -865
  11. package/dist/{Pmtiles.client-CRJ56yX2.js → Pmtiles.client-CaKEYQBc.js} +574 -579
  12. package/dist/PreviewWrapper.vue_vue_type_script_setup_true_lang-BKqb6TMw.js +61 -0
  13. package/dist/{ScaleLine-KW-nXqp3.js → ScaleLine-hJQIqcZm.js} +2 -2
  14. package/dist/{Tile-DbNFNPfU.js → Tile-Dcl7oIVu.js} +35 -35
  15. package/dist/{TileImage-BsXBxMtq.js → TileImage-BJeHipMX.js} +4 -4
  16. package/dist/{View-BR92hTWP.js → View-xp_P_OHw.js} +412 -401
  17. package/dist/XmlPreview.client-BVAeNK4n.js +34 -0
  18. package/dist/{common-PJfpC179.js → common-BjQlan3k.js} +36 -36
  19. package/dist/components-next.css +6 -6
  20. package/dist/components-next.js +166 -148
  21. package/dist/components.css +1 -1
  22. package/dist/{index-BZsAZ7iw.js → index-BBdS8QKx.js} +32886 -27183
  23. package/dist/{main-qc4CO9Kn.js → main-Dk_66g-3.js} +91331 -75844
  24. package/dist/{proj-DsetBcW7.js → proj-CsNo9yH1.js} +532 -512
  25. package/dist/{tilecoord-Db24Px13.js → tilecoord-A0fLnBZr.js} +28 -28
  26. package/dist/{vue3-xml-viewer.common-CCOV_ohP.js → vue3-xml-viewer.common-B8dNNkOU.js} +1 -1
  27. package/package.json +18 -11
  28. package/src/components/ActivityList/ActivityList.vue +0 -2
  29. package/src/components/Chart/ChartViewer.vue +226 -0
  30. package/src/components/Chart/ChartViewerWrapper.vue +170 -0
  31. package/src/components/Form/Listbox.vue +101 -0
  32. package/src/components/Form/SearchableSelect.vue +2 -1
  33. package/src/components/InfiniteLoader.vue +53 -0
  34. package/src/components/OpenApiViewer/ContentTypeSelect.vue +48 -0
  35. package/src/components/OpenApiViewer/EndpointRequest.vue +164 -0
  36. package/src/components/OpenApiViewer/EndpointResponses.vue +149 -0
  37. package/src/components/OpenApiViewer/OpenApiViewer.vue +308 -0
  38. package/src/components/OpenApiViewer/SchemaPanel.vue +53 -0
  39. package/src/components/OpenApiViewer/SchemaTree.vue +77 -0
  40. package/src/components/OpenApiViewer/openapi.ts +150 -0
  41. package/src/components/OrganizationNameWithCertificate.vue +3 -2
  42. package/src/components/Pagination.vue +8 -5
  43. package/src/components/ReadMore.vue +1 -1
  44. package/src/components/ResourceAccordion/Datafair.client.vue +4 -10
  45. package/src/components/ResourceAccordion/JsonPreview.client.vue +23 -121
  46. package/src/components/ResourceAccordion/MapContainer.client.vue +5 -14
  47. package/src/components/ResourceAccordion/Metadata.vue +1 -2
  48. package/src/components/ResourceAccordion/PdfPreview.client.vue +24 -103
  49. package/src/components/ResourceAccordion/Pmtiles.client.vue +5 -10
  50. package/src/components/ResourceAccordion/Preview.vue +16 -21
  51. package/src/components/ResourceAccordion/PreviewLoader.vue +1 -2
  52. package/src/components/ResourceAccordion/PreviewUnavailable.vue +22 -0
  53. package/src/components/ResourceAccordion/PreviewWrapper.vue +82 -0
  54. package/src/components/ResourceAccordion/ResourceAccordion.vue +5 -7
  55. package/src/components/ResourceAccordion/XmlPreview.client.vue +16 -115
  56. package/src/components/ResourceExplorer/ResourceExplorer.vue +81 -13
  57. package/src/components/ResourceExplorer/ResourceExplorerSidebar.vue +2 -2
  58. package/src/components/ResourceExplorer/ResourceExplorerViewer.vue +30 -11
  59. package/src/components/Search/GlobalSearch.vue +191 -110
  60. package/src/components/Search/SearchInput.vue +5 -4
  61. package/src/components/TabularExplorer/TabularCell.vue +51 -0
  62. package/src/components/TabularExplorer/TabularCellPopover.vue +170 -0
  63. package/src/components/TabularExplorer/TabularExplorer.vue +870 -0
  64. package/src/components/TabularExplorer/TabularFilterContent.vue +351 -0
  65. package/src/components/TabularExplorer/TabularFilterPopover.vue +111 -0
  66. package/src/components/TabularExplorer/types.ts +83 -0
  67. package/src/composables/useHasTabularData.ts +6 -0
  68. package/src/composables/useResourceCapabilities.ts +1 -1
  69. package/src/composables/useSearchFilter.ts +118 -0
  70. package/src/composables/useStableQueryParams.ts +31 -3
  71. package/src/config.ts +3 -0
  72. package/src/functions/api.ts +34 -33
  73. package/src/functions/api.types.ts +1 -0
  74. package/src/functions/charts.ts +68 -0
  75. package/src/functions/datasets.ts +0 -17
  76. package/src/functions/resources.ts +56 -1
  77. package/src/functions/tabular.ts +60 -0
  78. package/src/functions/tabularApi.ts +138 -11
  79. package/src/main.ts +55 -7
  80. package/src/types/dataservices.ts +2 -0
  81. package/src/types/pages.ts +0 -5
  82. package/src/types/posts.ts +2 -2
  83. package/src/types/reports.ts +5 -1
  84. package/src/types/search.ts +52 -1
  85. package/src/types/site.ts +5 -3
  86. package/src/types/users.ts +2 -1
  87. package/src/types/visualizations.ts +89 -0
  88. package/assets/swagger-themes/newspaper.css +0 -1670
  89. package/dist/Datafair.client-0UYUu5yf.js +0 -35
  90. package/dist/JsonPreview.client-BrTMBWHZ.js +0 -87
  91. package/dist/MapContainer.client-CUmKyByc.js +0 -107
  92. package/dist/Swagger.client-2Yn7iF0A.js +0 -4
  93. package/dist/XmlPreview.client-DxqlVnKu.js +0 -79
  94. package/src/components/ResourceAccordion/Swagger.client.vue +0 -48
  95. package/src/functions/pagination.ts +0 -9
  96. /package/assets/illustrations/{_microscope.svg → microscope.svg} +0 -0
@@ -1,9 +1,9 @@
1
- import { B as tt, J as it, E as w, aC as ri, l as T, u as G, aj as Ct, aq as ki, $ as ai, ab as ze, T as qe, aD as Ni, aE as oi, aF as li, a7 as zi, O as Ze, a as Se, d as Fi, a2 as Vi, al as K, f as Ki, a8 as Bi, L as Gi, ah as Wi, ac as Hi, Q as Ot, K as Yi, H as Mt, v as Ui, a0 as $i, aG as Xi } from "./proj-DsetBcW7.js";
2
- import { P as hi, T as Ce, r as qi, f as St, g as Zi, M as ci, t as we, d as E, h as kt, c as he, i as ji, W as oe, j as Ji, k as Qi, l as le, D as en, m as Nt } from "./Image-34hvypZI.js";
3
- import { C as Lt, a as nt, c as At, e as zt, f as We, g as mt, h as tn, M as se } from "./Control-DuZJdKV_.js";
4
- import { a as j, j as Fe, k as nn, d as sn, n as rn, o as an, e as Ft, g as Vt } from "./common-PJfpC179.js";
5
- import { K as ui, u as on, H as ae, V as He } from "./View-BR92hTWP.js";
6
- import { B as ln, f as di, t as fi, w as hn, r as Kt, l as cn, a as st, b as un, N as gi, L as It, i as _i, R as dn, E as Me } from "./Event--kp8kMdJ.js";
1
+ import { B as tt, J as it, E as w, aD as si, l as T, u as G, aj as Ct, ar as ki, $ as ai, ab as ze, T as qe, aE as Ni, aF as oi, aG as li, a7 as zi, O as Ze, a as Se, d as Fi, a2 as Vi, al as K, f as Ki, a8 as Bi, L as Gi, ah as Wi, ac as Hi, Q as Ot, K as Yi, H as Mt, v as Ui, a0 as $i, aH as Xi } from "./proj-CsNo9yH1.js";
2
+ import { P as hi, T as Ce, r as qi, f as St, g as Zi, M as ci, t as we, d as E, h as kt, c as he, i as ji, W as oe, j as Ji, k as Qi, l as le, D as en, m as Nt } from "./Image-BijNEG0p.js";
3
+ import { C as Lt, a as nt, c as At, e as zt, f as We, g as mt, h as tn, M as re } from "./Control-ZFh5ta_U.js";
4
+ import { a as j, j as Fe, k as nn, d as rn, n as sn, o as an, e as Ft, g as Vt } from "./common-BjQlan3k.js";
5
+ import { M as ui, u as on, I as ae, V as He } from "./View-xp_P_OHw.js";
6
+ import { B as ln, f as di, t as fi, w as hn, r as Kt, l as cn, a as rt, b as un, N as gi, L as It, i as _i, c as dn, R as Me } from "./Event-DSQcW7OF.js";
7
7
  const B = {
8
8
  /**
9
9
  * Triggered when an item is added to the collection.
@@ -37,7 +37,7 @@ class Y extends tt {
37
37
  */
38
38
  constructor(e, t) {
39
39
  if (super(), this.on, this.once, this.un, t = t || {}, this.unique_ = !!t.unique, this.array_ = e ?? [], this.unique_)
40
- for (let i = 1, s = this.array_.length; i < s; ++i)
40
+ for (let i = 1, r = this.array_.length; i < r; ++i)
41
41
  this.assertUnique_(this.array_[i], i);
42
42
  this.updateLength_();
43
43
  }
@@ -70,7 +70,7 @@ class Y extends tt {
70
70
  */
71
71
  forEach(e) {
72
72
  const t = this.array_;
73
- for (let i = 0, s = t.length; i < s; ++i)
73
+ for (let i = 0, r = t.length; i < r; ++i)
74
74
  e(t[i], i, t);
75
75
  }
76
76
  /**
@@ -142,7 +142,7 @@ class Y extends tt {
142
142
  */
143
143
  remove(e) {
144
144
  const t = this.array_;
145
- for (let i = 0, s = t.length; i < s; ++i)
145
+ for (let i = 0, r = t.length; i < r; ++i)
146
146
  if (t[i] === e)
147
147
  return this.removeAt(i);
148
148
  }
@@ -177,10 +177,10 @@ class Y extends tt {
177
177
  if (e < 0)
178
178
  throw new Error("Index out of bounds: " + e);
179
179
  this.unique_ && this.assertUnique_(t, e);
180
- const s = this.array_[e];
180
+ const r = this.array_[e];
181
181
  this.array_[e] = t, this.dispatchEvent(
182
182
  /** @type {CollectionEvent<T>} */
183
- new Ye(B.REMOVE, s, e)
183
+ new Ye(B.REMOVE, r, e)
184
184
  ), this.dispatchEvent(
185
185
  /** @type {CollectionEvent<T>} */
186
186
  new Ye(B.ADD, t, e)
@@ -199,8 +199,8 @@ class Y extends tt {
199
199
  */
200
200
  assertUnique_(e, t) {
201
201
  const i = this.array_;
202
- for (let s = 0, r = i.length; s < r; ++s)
203
- if (i[s] === e && s !== t)
202
+ for (let r = 0, s = i.length; r < s; ++r)
203
+ if (i[r] === e && r !== t)
204
204
  throw new Error("Duplicate item added to a unique collection");
205
205
  }
206
206
  }
@@ -223,8 +223,8 @@ class te extends me {
223
223
  * @param {import("./Map.js").FrameState} [frameState] Frame state.
224
224
  * @param {Array<PointerEvent>} [activePointers] Active pointers.
225
225
  */
226
- constructor(e, t, i, s, r, a) {
227
- super(e, t, r), this.originalEvent = i, this.pixel_ = null, this.coordinate_ = null, this.dragging = s !== void 0 ? s : !1, this.activePointers = a;
226
+ constructor(e, t, i, r, s, a) {
227
+ super(e, t, s), this.originalEvent = i, this.pixel_ = null, this.coordinate_ = null, this.dragging = r !== void 0 ? r : !1, this.activePointers = a;
228
228
  }
229
229
  /**
230
230
  * The map pixel relative to the viewport corresponding to the original event.
@@ -312,7 +312,7 @@ const D = {
312
312
  POINTERMOVE: "pointermove",
313
313
  POINTERDOWN: "pointerdown"
314
314
  };
315
- class fn extends ri {
315
+ class fn extends si {
316
316
  /**
317
317
  * @param {import("./Map.js").default} map The map with the viewport to listen to events on.
318
318
  * @param {number} [moveTolerance] The minimal distance the pointer must travel to trigger a move.
@@ -372,9 +372,9 @@ class fn extends ri {
372
372
  const t = e, i = t.pointerId;
373
373
  if (t.type == D.POINTERUP || t.type == D.POINTERCANCEL) {
374
374
  delete this.trackedTouches_[i];
375
- for (const s in this.trackedTouches_)
376
- if (this.trackedTouches_[s].target !== t.target) {
377
- delete this.trackedTouches_[s];
375
+ for (const r in this.trackedTouches_)
376
+ if (this.trackedTouches_[r].target !== t.target) {
377
+ delete this.trackedTouches_[r];
378
378
  break;
379
379
  }
380
380
  } else (t.type == D.POINTERDOWN || t.type == D.POINTERMOVE) && (this.trackedTouches_[i] = t);
@@ -561,8 +561,8 @@ class gn {
561
561
  e.length == 1 ? (e.length = 0, t.length = 0) : (e[0] = /** @type {T} */
562
562
  e.pop(), t[0] = /** @type {number} */
563
563
  t.pop(), this.siftUp_(0));
564
- const s = this.keyFunction_(i);
565
- return delete this.queuedElements_[s], i;
564
+ const r = this.keyFunction_(i);
565
+ return delete this.queuedElements_[r], i;
566
566
  }
567
567
  /**
568
568
  * Enqueue an element. O(log N).
@@ -644,12 +644,12 @@ class gn {
644
644
  * @private
645
645
  */
646
646
  siftUp_(e) {
647
- const t = this.elements_, i = this.priorities_, s = t.length, r = t[e], a = i[e], o = e;
648
- for (; e < s >> 1; ) {
649
- const l = this.getLeftChildIndex_(e), h = this.getRightChildIndex_(e), c = h < s && i[h] < i[l] ? h : l;
647
+ const t = this.elements_, i = this.priorities_, r = t.length, s = t[e], a = i[e], o = e;
648
+ for (; e < r >> 1; ) {
649
+ const l = this.getLeftChildIndex_(e), h = this.getRightChildIndex_(e), c = h < r && i[h] < i[l] ? h : l;
650
650
  t[e] = t[c], i[e] = i[c], e = c;
651
651
  }
652
- t[e] = r, i[e] = a, this.siftDown_(o, e);
652
+ t[e] = s, i[e] = a, this.siftDown_(o, e);
653
653
  }
654
654
  /**
655
655
  * @param {number} startIndex The index of the root.
@@ -657,27 +657,27 @@ class gn {
657
657
  * @private
658
658
  */
659
659
  siftDown_(e, t) {
660
- const i = this.elements_, s = this.priorities_, r = i[t], a = s[t];
660
+ const i = this.elements_, r = this.priorities_, s = i[t], a = r[t];
661
661
  for (; t > e; ) {
662
662
  const o = this.getParentIndex_(t);
663
- if (s[o] > a)
664
- i[t] = i[o], s[t] = s[o], t = o;
663
+ if (r[o] > a)
664
+ i[t] = i[o], r[t] = r[o], t = o;
665
665
  else
666
666
  break;
667
667
  }
668
- i[t] = r, s[t] = a;
668
+ i[t] = s, r[t] = a;
669
669
  }
670
670
  /**
671
671
  * FIXME empty description for jsdoc
672
672
  */
673
673
  reprioritize() {
674
674
  const e = this.priorityFunction_, t = this.elements_, i = this.priorities_;
675
- let s = 0;
676
- const r = t.length;
675
+ let r = 0;
676
+ const s = t.length;
677
677
  let a, o, l;
678
- for (o = 0; o < r; ++o)
679
- a = t[o], l = e(a), l == je ? delete this.queuedElements_[this.keyFunction_(a)] : (i[s] = l, t[s++] = a);
680
- t.length = s, i.length = s, this.heapify_();
678
+ for (o = 0; o < s; ++o)
679
+ a = t[o], l = e(a), l == je ? delete this.queuedElements_[this.keyFunction_(a)] : (i[r] = l, t[r++] = a);
680
+ t.length = r, i.length = r, this.heapify_();
681
681
  }
682
682
  }
683
683
  class _n extends gn {
@@ -717,8 +717,8 @@ class _n extends gn {
717
717
  ), i = t.getState();
718
718
  if (i === Ce.LOADED || i === Ce.ERROR || i === Ce.EMPTY) {
719
719
  i !== Ce.ERROR && t.removeEventListener(w.CHANGE, this.boundHandleTileChange_);
720
- const s = t.getKey();
721
- s in this.tilesLoadingKeys_ && (delete this.tilesLoadingKeys_[s], --this.tilesLoading_), this.tileChangeCallback_();
720
+ const r = t.getKey();
721
+ r in this.tilesLoadingKeys_ && (delete this.tilesLoadingKeys_[r], --this.tilesLoading_), this.tileChangeCallback_();
722
722
  }
723
723
  }
724
724
  /**
@@ -728,16 +728,16 @@ class _n extends gn {
728
728
  loadMoreTiles(e, t) {
729
729
  let i = 0;
730
730
  for (; this.tilesLoading_ < e && i < t && this.getCount() > 0; ) {
731
- const s = this.dequeue()[0], r = s.getKey();
732
- s.getState() === Ce.IDLE && !(r in this.tilesLoadingKeys_) && (this.tilesLoadingKeys_[r] = !0, ++this.tilesLoading_, ++i, s.load());
731
+ const r = this.dequeue()[0], s = r.getKey();
732
+ r.getState() === Ce.IDLE && !(s in this.tilesLoadingKeys_) && (this.tilesLoadingKeys_[s] = !0, ++this.tilesLoading_, ++i, r.load());
733
733
  }
734
734
  }
735
735
  }
736
- function mn(n, e, t, i, s) {
736
+ function mn(n, e, t, i, r) {
737
737
  if (!n || !(t in n.wantedTiles) || !n.wantedTiles[t][e.getKey()])
738
738
  return je;
739
- const r = n.viewState.center, a = i[0] - r[0], o = i[1] - r[1];
740
- return 65536 * Math.log(s) + Math.sqrt(a * a + o * o) / s;
739
+ const s = n.viewState.center, a = i[0] - s[0], o = i[1] - s[1];
740
+ return 65536 * Math.log(r) + Math.sqrt(a * a + o * o) / r;
741
741
  }
742
742
  class yn extends Lt {
743
743
  /**
@@ -749,10 +749,10 @@ class yn extends Lt {
749
749
  render: e.render,
750
750
  target: e.target
751
751
  }), this.ulElement_ = document.createElement("ul"), this.collapsed_ = e.collapsed !== void 0 ? e.collapsed : !0, this.userCollapsed_ = this.collapsed_, this.overrideCollapsible_ = e.collapsible !== void 0, this.collapsible_ = e.collapsible !== void 0 ? e.collapsible : !0, this.collapsible_ || (this.collapsed_ = !1), this.attributions_ = e.attributions;
752
- const t = e.className !== void 0 ? e.className : "ol-attribution", i = e.tipLabel !== void 0 ? e.tipLabel : "Attributions", s = e.expandClassName !== void 0 ? e.expandClassName : t + "-expand", r = e.collapseLabel !== void 0 ? e.collapseLabel : "›", a = e.collapseClassName !== void 0 ? e.collapseClassName : t + "-collapse";
753
- typeof r == "string" ? (this.collapseLabel_ = document.createElement("span"), this.collapseLabel_.textContent = r, this.collapseLabel_.className = a) : this.collapseLabel_ = r;
752
+ const t = e.className !== void 0 ? e.className : "ol-attribution", i = e.tipLabel !== void 0 ? e.tipLabel : "Attributions", r = e.expandClassName !== void 0 ? e.expandClassName : t + "-expand", s = e.collapseLabel !== void 0 ? e.collapseLabel : "›", a = e.collapseClassName !== void 0 ? e.collapseClassName : t + "-collapse";
753
+ typeof s == "string" ? (this.collapseLabel_ = document.createElement("span"), this.collapseLabel_.textContent = s, this.collapseLabel_.className = a) : this.collapseLabel_ = s;
754
754
  const o = e.label !== void 0 ? e.label : "i";
755
- typeof o == "string" ? (this.label_ = document.createElement("span"), this.label_.textContent = o, this.label_.className = s) : this.label_ = o;
755
+ typeof o == "string" ? (this.label_ = document.createElement("span"), this.label_.textContent = o, this.label_.className = r) : this.label_ = o;
756
756
  const l = this.collapsible_ && !this.collapsed_ ? this.collapseLabel_ : this.label_;
757
757
  this.toggleButton_ = document.createElement("button"), this.toggleButton_.setAttribute("type", "button"), this.toggleButton_.setAttribute("aria-expanded", String(!this.collapsed_)), this.toggleButton_.title = i, this.toggleButton_.appendChild(l), this.toggleButton_.addEventListener(
758
758
  w.CLICK,
@@ -770,13 +770,13 @@ class yn extends Lt {
770
770
  */
771
771
  collectSourceAttributions_(e) {
772
772
  const t = this.getMap().getAllLayers(), i = new Set(
773
- t.flatMap((s) => s.getAttributions(e))
773
+ t.flatMap((r) => r.getAttributions(e))
774
774
  );
775
- if (this.attributions_ !== void 0 && (Array.isArray(this.attributions_) ? this.attributions_.forEach((s) => i.add(s)) : i.add(this.attributions_)), !this.overrideCollapsible_) {
776
- const s = !t.some(
777
- (r) => r.getSource()?.getAttributionsCollapsible() === !1
775
+ if (this.attributions_ !== void 0 && (Array.isArray(this.attributions_) ? this.attributions_.forEach((r) => i.add(r)) : i.add(this.attributions_)), !this.overrideCollapsible_) {
776
+ const r = !t.some(
777
+ (s) => s.getSource()?.getAttributionsCollapsible() === !1
778
778
  );
779
- this.setCollapsible(s);
779
+ this.setCollapsible(r);
780
780
  }
781
781
  return Array.from(i);
782
782
  }
@@ -791,14 +791,14 @@ class yn extends Lt {
791
791
  }
792
792
  const t = await Promise.all(
793
793
  this.collectSourceAttributions_(e).map(
794
- (s) => ki(() => s)
794
+ (r) => ki(() => r)
795
795
  )
796
796
  ), i = t.length > 0;
797
797
  if (this.renderedVisible_ != i && (this.element.style.display = i ? "" : "none", this.renderedVisible_ = i), !ai(t, this.renderedAttributions_)) {
798
798
  qi(this.ulElement_);
799
- for (let s = 0, r = t.length; s < r; ++s) {
799
+ for (let r = 0, s = t.length; r < s; ++r) {
800
800
  const a = document.createElement("li");
801
- a.innerHTML = t[s], this.ulElement_.appendChild(a);
801
+ a.innerHTML = t[r], this.ulElement_.appendChild(a);
802
802
  }
803
803
  this.renderedAttributions_ = t;
804
804
  }
@@ -870,10 +870,10 @@ class pn extends Lt {
870
870
  render: e.render,
871
871
  target: e.target
872
872
  });
873
- const t = e.className !== void 0 ? e.className : "ol-rotate", i = e.label !== void 0 ? e.label : "⇧", s = e.compassClassName !== void 0 ? e.compassClassName : "ol-compass";
874
- this.label_ = null, typeof i == "string" ? (this.label_ = document.createElement("span"), this.label_.className = s, this.label_.textContent = i) : (this.label_ = i, this.label_.classList.add(s));
875
- const r = e.tipLabel ? e.tipLabel : "Reset rotation", a = document.createElement("button");
876
- a.className = t + "-reset", a.setAttribute("type", "button"), a.title = r, a.appendChild(this.label_), a.addEventListener(
873
+ const t = e.className !== void 0 ? e.className : "ol-rotate", i = e.label !== void 0 ? e.label : "⇧", r = e.compassClassName !== void 0 ? e.compassClassName : "ol-compass";
874
+ this.label_ = null, typeof i == "string" ? (this.label_ = document.createElement("span"), this.label_.className = r, this.label_.textContent = i) : (this.label_ = i, this.label_.classList.add(r));
875
+ const s = e.tipLabel ? e.tipLabel : "Reset rotation", a = document.createElement("button");
876
+ a.className = t + "-reset", a.setAttribute("type", "button"), a.title = s, a.appendChild(this.label_), a.addEventListener(
877
877
  w.CLICK,
878
878
  this.handleClick_.bind(this),
879
879
  !1
@@ -913,12 +913,12 @@ class pn extends Lt {
913
913
  return;
914
914
  const i = t.viewState.rotation;
915
915
  if (i != this.rotation_) {
916
- const s = "rotate(" + i + "rad)";
916
+ const r = "rotate(" + i + "rad)";
917
917
  if (this.autoHide_) {
918
- const r = this.element.classList.contains(We);
919
- !r && i === 0 ? this.element.classList.add(We) : r && i !== 0 && this.element.classList.remove(We);
918
+ const s = this.element.classList.contains(We);
919
+ !s && i === 0 ? this.element.classList.add(We) : s && i !== 0 && this.element.classList.remove(We);
920
920
  }
921
- this.label_.style.transform = s;
921
+ this.label_.style.transform = r;
922
922
  }
923
923
  this.rotation_ = i;
924
924
  }
@@ -932,8 +932,8 @@ class En extends Lt {
932
932
  element: document.createElement("div"),
933
933
  target: e.target
934
934
  });
935
- const t = e.className !== void 0 ? e.className : "ol-zoom", i = e.delta !== void 0 ? e.delta : 1, s = e.zoomInClassName !== void 0 ? e.zoomInClassName : t + "-in", r = e.zoomOutClassName !== void 0 ? e.zoomOutClassName : t + "-out", a = e.zoomInLabel !== void 0 ? e.zoomInLabel : "+", o = e.zoomOutLabel !== void 0 ? e.zoomOutLabel : "–", l = e.zoomInTipLabel !== void 0 ? e.zoomInTipLabel : "Zoom in", h = e.zoomOutTipLabel !== void 0 ? e.zoomOutTipLabel : "Zoom out", c = document.createElement("button");
936
- c.className = s, c.setAttribute("type", "button"), c.title = l, c.appendChild(
935
+ const t = e.className !== void 0 ? e.className : "ol-zoom", i = e.delta !== void 0 ? e.delta : 1, r = e.zoomInClassName !== void 0 ? e.zoomInClassName : t + "-in", s = e.zoomOutClassName !== void 0 ? e.zoomOutClassName : t + "-out", a = e.zoomInLabel !== void 0 ? e.zoomInLabel : "+", o = e.zoomOutLabel !== void 0 ? e.zoomOutLabel : "–", l = e.zoomInTipLabel !== void 0 ? e.zoomInTipLabel : "Zoom in", h = e.zoomOutTipLabel !== void 0 ? e.zoomOutTipLabel : "Zoom out", c = document.createElement("button");
936
+ c.className = r, c.setAttribute("type", "button"), c.title = l, c.appendChild(
937
937
  typeof a == "string" ? document.createTextNode(a) : a
938
938
  ), c.addEventListener(
939
939
  w.CLICK,
@@ -941,7 +941,7 @@ class En extends Lt {
941
941
  !1
942
942
  );
943
943
  const d = document.createElement("button");
944
- d.className = r, d.setAttribute("type", "button"), d.title = h, d.appendChild(
944
+ d.className = s, d.setAttribute("type", "button"), d.title = h, d.appendChild(
945
945
  typeof o == "string" ? document.createTextNode(o) : o
946
946
  ), d.addEventListener(
947
947
  w.CLICK,
@@ -967,14 +967,14 @@ class En extends Lt {
967
967
  const i = this.getMap().getView();
968
968
  if (!i)
969
969
  return;
970
- const s = i.getZoom();
971
- if (s !== void 0) {
972
- const r = i.getConstrainedZoom(s + e);
970
+ const r = i.getZoom();
971
+ if (r !== void 0) {
972
+ const s = i.getConstrainedZoom(r + e);
973
973
  this.duration_ > 0 ? (i.getAnimating() && i.cancelAnimations(), i.animate({
974
- zoom: r,
974
+ zoom: s,
975
975
  duration: this.duration_,
976
976
  easing: Fe
977
- })) : i.setZoom(r);
977
+ })) : i.setZoom(s);
978
978
  }
979
979
  }
980
980
  }
@@ -1018,11 +1018,11 @@ class vn {
1018
1018
  let i = t - 3;
1019
1019
  for (; i > 0 && this.points_[i + 2] > e; )
1020
1020
  i -= 3;
1021
- const s = this.points_[t + 2] - this.points_[i + 2];
1022
- if (s < 1e3 / 60)
1021
+ const r = this.points_[t + 2] - this.points_[i + 2];
1022
+ if (r < 1e3 / 60)
1023
1023
  return !1;
1024
- const r = this.points_[t] - this.points_[i], a = this.points_[t + 1] - this.points_[i + 1];
1025
- return this.angle_ = Math.atan2(a, r), this.initialVelocity_ = Math.sqrt(r * r + a * a) / s, this.initialVelocity_ > this.minVelocity_;
1024
+ const s = this.points_[t] - this.points_[i], a = this.points_[t + 1] - this.points_[i + 1];
1025
+ return this.angle_ = Math.atan2(a, s), this.initialVelocity_ = Math.sqrt(s * s + a * a) / r, this.initialVelocity_ > this.minVelocity_;
1026
1026
  }
1027
1027
  /**
1028
1028
  * @return {number} Total distance travelled (pixels).
@@ -1098,19 +1098,19 @@ class Ve extends tt {
1098
1098
  function Cn(n, e, t) {
1099
1099
  const i = n.getCenterInternal();
1100
1100
  if (i) {
1101
- const s = [i[0] + e[0], i[1] + e[1]];
1101
+ const r = [i[0] + e[0], i[1] + e[1]];
1102
1102
  n.animateInternal({
1103
1103
  duration: t !== void 0 ? t : 250,
1104
1104
  easing: nn,
1105
- center: n.getConstrainedCenter(s)
1105
+ center: n.getConstrainedCenter(r)
1106
1106
  });
1107
1107
  }
1108
1108
  }
1109
1109
  function bt(n, e, t, i) {
1110
- const s = n.getZoom();
1111
- if (s === void 0)
1110
+ const r = n.getZoom();
1111
+ if (r === void 0)
1112
1112
  return;
1113
- const r = n.getConstrainedZoom(s + e), a = n.getResolutionForZoom(r);
1113
+ const s = n.getConstrainedZoom(r + e), a = n.getResolutionForZoom(s);
1114
1114
  n.getAnimating() && n.cancelAnimations(), n.animate({
1115
1115
  resolution: a,
1116
1116
  anchor: t,
@@ -1138,8 +1138,8 @@ class Ln extends Ve {
1138
1138
  const i = (
1139
1139
  /** @type {MouseEvent} */
1140
1140
  e.originalEvent
1141
- ), s = e.map, r = e.coordinate, a = i.shiftKey ? -this.delta_ : this.delta_, o = s.getView();
1142
- bt(o, a, r, this.duration_), i.preventDefault(), t = !0;
1141
+ ), r = e.map, s = e.coordinate, a = i.shiftKey ? -this.delta_ : this.delta_, o = r.getView();
1142
+ bt(o, a, s, this.duration_), i.preventDefault(), t = !0;
1143
1143
  }
1144
1144
  return !t;
1145
1145
  }
@@ -1148,12 +1148,12 @@ function pt(n) {
1148
1148
  const e = arguments;
1149
1149
  return function(t) {
1150
1150
  let i = !0;
1151
- for (let s = 0, r = e.length; s < r && (i = i && e[s](t), !!i); ++s)
1151
+ for (let r = 0, s = e.length; r < s && (i = i && e[r](t), !!i); ++r)
1152
1152
  ;
1153
1153
  return i;
1154
1154
  };
1155
1155
  }
1156
- const sr = function(n) {
1156
+ const rs = function(n) {
1157
1157
  const e = n.originalEvent;
1158
1158
  return e.altKey && !(e.metaKey || e.ctrlKey) && !e.shiftKey;
1159
1159
  }, An = function(n) {
@@ -1168,9 +1168,9 @@ const sr = function(n) {
1168
1168
  }, bn = qe, yi = function(n) {
1169
1169
  const e = n.originalEvent;
1170
1170
  return "pointerId" in e && e.button == 0 && !(Zi && ci && e.ctrlKey);
1171
- }, rr = ze, ar = function(n) {
1171
+ }, ss = ze, as = function(n) {
1172
1172
  return n.type == "pointermove";
1173
- }, or = function(n) {
1173
+ }, os = function(n) {
1174
1174
  return n.type == D.SINGLECLICK;
1175
1175
  }, pi = function(n) {
1176
1176
  const e = (
@@ -1297,8 +1297,8 @@ class Ke extends Ve {
1297
1297
  function Dt(n) {
1298
1298
  const e = n.length;
1299
1299
  let t = 0, i = 0;
1300
- for (let s = 0; s < e; s++)
1301
- t += n[s].clientX, i += n[s].clientY;
1300
+ for (let r = 0; r < e; r++)
1301
+ t += n[r].clientX, i += n[r].clientY;
1302
1302
  return { clientX: t / e, clientY: i / e };
1303
1303
  }
1304
1304
  class xn extends Ke {
@@ -1320,17 +1320,17 @@ class xn extends Ke {
1320
1320
  handleDragEvent(e) {
1321
1321
  const t = e.map;
1322
1322
  this.panning_ || (this.panning_ = !0, t.getView().beginInteraction());
1323
- const i = this.targetPointers, s = t.getEventPixel(Dt(i));
1323
+ const i = this.targetPointers, r = t.getEventPixel(Dt(i));
1324
1324
  if (i.length == this.lastPointersCount_) {
1325
- if (this.kinetic_ && this.kinetic_.update(s[0], s[1]), this.lastCentroid) {
1326
- const r = [
1327
- this.lastCentroid[0] - s[0],
1328
- s[1] - this.lastCentroid[1]
1325
+ if (this.kinetic_ && this.kinetic_.update(r[0], r[1]), this.lastCentroid) {
1326
+ const s = [
1327
+ this.lastCentroid[0] - r[0],
1328
+ r[1] - this.lastCentroid[1]
1329
1329
  ], o = e.map.getView();
1330
- Ni(r, o.getResolution()), oi(r, o.getRotation()), o.adjustCenterInternal(r);
1330
+ Ni(s, o.getResolution()), oi(s, o.getRotation()), o.adjustCenterInternal(s);
1331
1331
  }
1332
1332
  } else this.kinetic_ && this.kinetic_.begin();
1333
- this.lastCentroid = s, this.lastPointersCount_ = i.length, e.originalEvent.preventDefault();
1333
+ this.lastCentroid = r, this.lastPointersCount_ = i.length, e.originalEvent.preventDefault();
1334
1334
  }
1335
1335
  /**
1336
1336
  * Handle pointer up events.
@@ -1342,9 +1342,9 @@ class xn extends Ke {
1342
1342
  const t = e.map, i = t.getView();
1343
1343
  if (this.targetPointers.length === 0) {
1344
1344
  if (!this.noKinetic_ && this.kinetic_ && this.kinetic_.end()) {
1345
- const s = this.kinetic_.getDistance(), r = this.kinetic_.getAngle(), a = i.getCenterInternal(), o = t.getPixelFromCoordinateInternal(a), l = t.getCoordinateFromPixelInternal([
1346
- o[0] - s * Math.cos(r),
1347
- o[1] - s * Math.sin(r)
1345
+ const r = this.kinetic_.getDistance(), s = this.kinetic_.getAngle(), a = i.getCenterInternal(), o = t.getPixelFromCoordinateInternal(a), l = t.getCoordinateFromPixelInternal([
1346
+ o[0] - r * Math.cos(s),
1347
+ o[1] - r * Math.sin(s)
1348
1348
  ]);
1349
1349
  i.animateInternal({
1350
1350
  center: i.getConstrainedCenter(l),
@@ -1390,7 +1390,7 @@ class Pn extends Ke {
1390
1390
  const t = e.map, i = t.getView();
1391
1391
  if (i.getConstraints().rotation === ui)
1392
1392
  return;
1393
- const s = t.getSize(), r = e.pixel, a = Math.atan2(s[1] / 2 - r[1], r[0] - s[0] / 2);
1393
+ const r = t.getSize(), s = e.pixel, a = Math.atan2(r[1] / 2 - s[1], s[0] - r[0] / 2);
1394
1394
  if (this.lastAngle_ !== void 0) {
1395
1395
  const o = a - this.lastAngle_;
1396
1396
  i.adjustRotationInternal(-o);
@@ -1434,8 +1434,8 @@ class On extends li {
1434
1434
  * @private
1435
1435
  */
1436
1436
  render_() {
1437
- const e = this.startPixel_, t = this.endPixel_, i = "px", s = this.element_.style;
1438
- s.left = Math.min(e[0], t[0]) + i, s.top = Math.min(e[1], t[1]) + i, s.width = Math.abs(t[0] - e[0]) + i, s.height = Math.abs(t[1] - e[1]) + i;
1437
+ const e = this.startPixel_, t = this.endPixel_, i = "px", r = this.element_.style;
1438
+ r.left = Math.min(e[0], t[0]) + i, r.top = Math.min(e[1], t[1]) + i, r.width = Math.abs(t[0] - e[0]) + i, r.height = Math.abs(t[1] - e[1]) + i;
1439
1439
  }
1440
1440
  /**
1441
1441
  * @param {import("../Map.js").default|null} map Map.
@@ -1461,7 +1461,7 @@ class On extends li {
1461
1461
  createOrUpdateGeometry() {
1462
1462
  if (!this.map_)
1463
1463
  return;
1464
- const e = this.startPixel_, t = this.endPixel_, s = [
1464
+ const e = this.startPixel_, t = this.endPixel_, r = [
1465
1465
  e,
1466
1466
  [e[0], t[1]],
1467
1467
  t,
@@ -1470,7 +1470,7 @@ class On extends li {
1470
1470
  this.map_.getCoordinateFromPixelInternal,
1471
1471
  this.map_
1472
1472
  );
1473
- s[4] = s[0].slice(), this.geometry_ ? this.geometry_.setCoordinates([s]) : this.geometry_ = new on([s]);
1473
+ r[4] = r[0].slice(), this.geometry_ ? this.geometry_.setCoordinates([r]) : this.geometry_ = new on([r]);
1474
1474
  }
1475
1475
  /**
1476
1476
  * @return {import("../geom/Polygon.js").default} Geometry.
@@ -1532,8 +1532,8 @@ class Mn extends Ke {
1532
1532
  * @return {boolean} Whether or not the boxend condition should be fired.
1533
1533
  */
1534
1534
  defaultBoxEndCondition(e, t, i) {
1535
- const s = i[0] - t[0], r = i[1] - t[1];
1536
- return s * s + r * r >= this.minArea_;
1535
+ const r = i[0] - t[0], s = i[1] - t[1];
1536
+ return r * r + s * s >= this.minArea_;
1537
1537
  }
1538
1538
  /**
1539
1539
  * Returns geometry of last drawn box.
@@ -1645,18 +1645,18 @@ class Sn extends Mn {
1645
1645
  /** @type {!import("../View.js").default} */
1646
1646
  this.getMap().getView()
1647
1647
  );
1648
- let s = this.getGeometry();
1648
+ let r = this.getGeometry();
1649
1649
  if (this.out_) {
1650
- const r = i.rotatedExtentForGeometry(s), a = i.getResolutionForExtentInternal(r), o = i.getResolution() / a;
1651
- s = s.clone(), s.scale(o * o);
1650
+ const s = i.rotatedExtentForGeometry(r), a = i.getResolutionForExtentInternal(s), o = i.getResolution() / a;
1651
+ r = r.clone(), r.scale(o * o);
1652
1652
  }
1653
- i.fitInternal(s, {
1653
+ i.fitInternal(r, {
1654
1654
  duration: this.duration_,
1655
1655
  easing: Fe
1656
1656
  });
1657
1657
  }
1658
1658
  }
1659
- const re = {
1659
+ const se = {
1660
1660
  LEFT: "ArrowLeft",
1661
1661
  UP: "ArrowUp",
1662
1662
  RIGHT: "ArrowRight",
@@ -1685,11 +1685,11 @@ class kn extends Ve {
1685
1685
  const i = (
1686
1686
  /** @type {KeyboardEvent} */
1687
1687
  e.originalEvent
1688
- ), s = i.key;
1689
- if (this.condition_(e) && (s == re.DOWN || s == re.LEFT || s == re.RIGHT || s == re.UP)) {
1688
+ ), r = i.key;
1689
+ if (this.condition_(e) && (r == se.DOWN || r == se.LEFT || r == se.RIGHT || r == se.UP)) {
1690
1690
  const a = e.map.getView(), o = a.getResolution() * this.pixelDelta_;
1691
1691
  let l = 0, h = 0;
1692
- s == re.DOWN ? h = -o : s == re.LEFT ? l = -o : s == re.RIGHT ? l = o : h = o;
1692
+ r == se.DOWN ? h = -o : r == se.LEFT ? l = -o : r == se.RIGHT ? l = o : h = o;
1693
1693
  const c = [l, h];
1694
1694
  oi(c, a.getRotation()), Cn(a, c, this.duration_), i.preventDefault(), t = !0;
1695
1695
  }
@@ -1720,9 +1720,9 @@ class Nn extends Ve {
1720
1720
  const i = (
1721
1721
  /** @type {KeyboardEvent} */
1722
1722
  e.originalEvent
1723
- ), s = i.key;
1724
- if (this.condition_(e) && (s === "+" || s === "-")) {
1725
- const r = e.map, a = s === "+" ? this.delta_ : -this.delta_, o = r.getView();
1723
+ ), r = i.key;
1724
+ if (this.condition_(e) && (r === "+" || r === "-")) {
1725
+ const s = e.map, a = r === "+" ? this.delta_ : -this.delta_, o = s.getView();
1726
1726
  bt(o, a, void 0, this.duration_), i.preventDefault(), t = !0;
1727
1727
  }
1728
1728
  }
@@ -1766,35 +1766,35 @@ class Vn extends Ve {
1766
1766
  handleEvent(e) {
1767
1767
  if (!this.condition_(e) || e.type !== w.WHEEL)
1768
1768
  return !0;
1769
- const i = e.map, s = (
1769
+ const i = e.map, r = (
1770
1770
  /** @type {WheelEvent} */
1771
1771
  e.originalEvent
1772
1772
  );
1773
- s.preventDefault(), this.useAnchor_ && (this.lastAnchor_ = e.pixel);
1774
- let r = s.deltaY;
1775
- switch (s.deltaMode) {
1773
+ r.preventDefault(), this.useAnchor_ && (this.lastAnchor_ = e.pixel);
1774
+ let s = r.deltaY;
1775
+ switch (r.deltaMode) {
1776
1776
  case WheelEvent.DOM_DELTA_LINE:
1777
- r *= zn;
1777
+ s *= zn;
1778
1778
  break;
1779
1779
  case WheelEvent.DOM_DELTA_PAGE:
1780
- r *= Fn;
1780
+ s *= Fn;
1781
1781
  break;
1782
1782
  }
1783
- if (r === 0)
1783
+ if (s === 0)
1784
1784
  return !1;
1785
- this.lastDelta_ = r;
1785
+ this.lastDelta_ = s;
1786
1786
  const a = Date.now();
1787
- this.startTime_ === void 0 && (this.startTime_ = a), (!this.mode_ || a - this.startTime_ > this.trackpadEventGap_) && (this.mode_ = Math.abs(r) < 4 ? "trackpad" : "wheel");
1787
+ this.startTime_ === void 0 && (this.startTime_ = a), (!this.mode_ || a - this.startTime_ > this.trackpadEventGap_) && (this.mode_ = Math.abs(s) < 4 ? "trackpad" : "wheel");
1788
1788
  const o = i.getView();
1789
1789
  if (this.mode_ === "trackpad" && !(o.getConstrainResolution() || this.constrainResolution_))
1790
1790
  return this.trackpadTimeoutId_ ? clearTimeout(this.trackpadTimeoutId_) : (o.getAnimating() && o.cancelAnimations(), o.beginInteraction()), this.trackpadTimeoutId_ = setTimeout(
1791
1791
  this.endInteraction_.bind(this),
1792
1792
  this.timeout_
1793
1793
  ), o.adjustZoom(
1794
- -r / this.deltaPerZoom_,
1794
+ -s / this.deltaPerZoom_,
1795
1795
  this.lastAnchor_ ? i.getCoordinateFromPixel(this.lastAnchor_) : null
1796
1796
  ), this.startTime_ = a, !1;
1797
- this.totalDelta_ += r;
1797
+ this.totalDelta_ += s;
1798
1798
  const l = Math.max(this.timeout_ - (a - this.startTime_), 0);
1799
1799
  return clearTimeout(this.timeoutId_), this.timeoutId_ = setTimeout(
1800
1800
  this.handleWheelZoom_.bind(this, i),
@@ -1849,15 +1849,15 @@ class Kn extends Ke {
1849
1849
  */
1850
1850
  handleDragEvent(e) {
1851
1851
  let t = 0;
1852
- const i = this.targetPointers[0], s = this.targetPointers[1], r = Math.atan2(
1853
- s.clientY - i.clientY,
1854
- s.clientX - i.clientX
1852
+ const i = this.targetPointers[0], r = this.targetPointers[1], s = Math.atan2(
1853
+ r.clientY - i.clientY,
1854
+ r.clientX - i.clientX
1855
1855
  );
1856
1856
  if (this.lastAngle_ !== void 0) {
1857
- const l = r - this.lastAngle_;
1857
+ const l = s - this.lastAngle_;
1858
1858
  this.rotationDelta_ += l, !this.rotating_ && Math.abs(this.rotationDelta_) > this.threshold_ && (this.rotating_ = !0), t = l;
1859
1859
  }
1860
- this.lastAngle_ = r;
1860
+ this.lastAngle_ = s;
1861
1861
  const a = e.map, o = a.getView();
1862
1862
  o.getConstraints().rotation !== ui && (this.anchor_ = a.getCoordinateFromPixelInternal(
1863
1863
  a.getEventPixel(Dt(this.targetPointers))
@@ -1905,7 +1905,7 @@ class Bn extends Ke {
1905
1905
  */
1906
1906
  handleDragEvent(e) {
1907
1907
  let t = 1;
1908
- const i = this.targetPointers[0], s = this.targetPointers[1], r = i.clientX - s.clientX, a = i.clientY - s.clientY, o = Math.sqrt(r * r + a * a);
1908
+ const i = this.targetPointers[0], r = this.targetPointers[1], s = i.clientX - r.clientX, a = i.clientY - r.clientY, o = Math.sqrt(s * s + a * a);
1909
1909
  this.lastDistance_ !== void 0 && (t = this.lastDistance_ / o), this.lastDistance_ = o;
1910
1910
  const l = e.map, h = l.getView();
1911
1911
  t != 1 && (this.lastScaleDelta_ = t), this.anchor_ = l.getCoordinateFromPixelInternal(
@@ -1920,8 +1920,8 @@ class Bn extends Ke {
1920
1920
  */
1921
1921
  handleUpEvent(e) {
1922
1922
  if (this.targetPointers.length < 2) {
1923
- const i = e.map.getView(), s = this.lastScaleDelta_ > 1 ? 1 : -1;
1924
- return i.endInteraction(this.duration_, s), !1;
1923
+ const i = e.map.getView(), r = this.lastScaleDelta_ > 1 ? 1 : -1;
1924
+ return i.endInteraction(this.duration_, r), !1;
1925
1925
  }
1926
1926
  return !0;
1927
1927
  }
@@ -2041,9 +2041,9 @@ class ve extends ln {
2041
2041
  this.listenerKeys_[i].forEach(G);
2042
2042
  Ct(this.listenerKeys_);
2043
2043
  const t = e.getArray();
2044
- for (let i = 0, s = t.length; i < s; i++) {
2045
- const r = t[i];
2046
- this.registerLayerListeners_(r), this.dispatchEvent(new ie(Q.ADDLAYER, r));
2044
+ for (let i = 0, r = t.length; i < r; i++) {
2045
+ const s = t[i];
2046
+ this.registerLayerListeners_(s), this.dispatchEvent(new ie(Q.ADDLAYER, s));
2047
2047
  }
2048
2048
  this.changed();
2049
2049
  }
@@ -2124,9 +2124,9 @@ class ve extends ln {
2124
2124
  const t = this.getLayers();
2125
2125
  if (t) {
2126
2126
  const i = t.getArray();
2127
- for (let s = 0, r = i.length; s < r; ++s)
2127
+ for (let r = 0, s = i.length; r < s; ++r)
2128
2128
  this.dispatchEvent(
2129
- new ie(Q.REMOVELAYER, i[s])
2129
+ new ie(Q.REMOVELAYER, i[r])
2130
2130
  );
2131
2131
  }
2132
2132
  this.set(ct.LAYERS, e);
@@ -2156,21 +2156,21 @@ class ve extends ln {
2156
2156
  this.getLayers().forEach(function(a) {
2157
2157
  a.getLayerStatesArray(t);
2158
2158
  });
2159
- const s = this.getLayerState();
2160
- let r = s.zIndex;
2161
- !e && s.zIndex === void 0 && (r = 0);
2159
+ const r = this.getLayerState();
2160
+ let s = r.zIndex;
2161
+ !e && r.zIndex === void 0 && (s = 0);
2162
2162
  for (let a = i, o = t.length; a < o; a++) {
2163
2163
  const l = t[a];
2164
- l.opacity *= s.opacity, l.visible = l.visible && s.visible, l.maxResolution = Math.min(
2164
+ l.opacity *= r.opacity, l.visible = l.visible && r.visible, l.maxResolution = Math.min(
2165
2165
  l.maxResolution,
2166
- s.maxResolution
2166
+ r.maxResolution
2167
2167
  ), l.minResolution = Math.max(
2168
2168
  l.minResolution,
2169
- s.minResolution
2170
- ), l.minZoom = Math.max(l.minZoom, s.minZoom), l.maxZoom = Math.min(l.maxZoom, s.maxZoom), s.extent !== void 0 && (l.extent !== void 0 ? l.extent = Fi(
2169
+ r.minResolution
2170
+ ), l.minZoom = Math.max(l.minZoom, r.minZoom), l.maxZoom = Math.min(l.maxZoom, r.maxZoom), r.extent !== void 0 && (l.extent !== void 0 ? l.extent = Fi(
2171
2171
  l.extent,
2172
- s.extent
2173
- ) : l.extent = s.extent), l.zIndex === void 0 && (l.zIndex = r);
2172
+ r.extent
2173
+ ) : l.extent = r.extent), l.zIndex === void 0 && (l.zIndex = s);
2174
2174
  }
2175
2175
  return t;
2176
2176
  }
@@ -2182,19 +2182,19 @@ class ve extends ln {
2182
2182
  return "ready";
2183
2183
  }
2184
2184
  }
2185
- function wi(n, e, t = 0, i = n.length - 1, s = Wn) {
2185
+ function wi(n, e, t = 0, i = n.length - 1, r = Wn) {
2186
2186
  for (; i > t; ) {
2187
2187
  if (i - t > 600) {
2188
2188
  const l = i - t + 1, h = e - t + 1, c = Math.log(l), d = 0.5 * Math.exp(2 * c / 3), f = 0.5 * Math.sqrt(c * d * (l - d) / l) * (h - l / 2 < 0 ? -1 : 1), y = Math.max(t, Math.floor(e - h * d / l + f)), v = Math.min(i, Math.floor(e + (l - h) * d / l + f));
2189
- wi(n, e, y, v, s);
2189
+ wi(n, e, y, v, r);
2190
2190
  }
2191
- const r = n[e];
2191
+ const s = n[e];
2192
2192
  let a = t, o = i;
2193
- for (Ae(n, t, e), s(n[i], r) > 0 && Ae(n, t, i); a < o; ) {
2194
- for (Ae(n, a, o), a++, o--; s(n[a], r) < 0; ) a++;
2195
- for (; s(n[o], r) > 0; ) o--;
2193
+ for (Ae(n, t, e), r(n[i], s) > 0 && Ae(n, t, i); a < o; ) {
2194
+ for (Ae(n, a, o), a++, o--; r(n[a], s) < 0; ) a++;
2195
+ for (; r(n[o], s) > 0; ) o--;
2196
2196
  }
2197
- s(n[t], r) === 0 ? Ae(n, t, o) : (o++, Ae(n, o, i)), o <= e && (t = o + 1), e <= o && (i = o - 1);
2197
+ r(n[t], s) === 0 ? Ae(n, t, o) : (o++, Ae(n, o, i)), o <= e && (t = o + 1), e <= o && (i = o - 1);
2198
2198
  }
2199
2199
  }
2200
2200
  function Ae(n, e, t) {
@@ -2215,13 +2215,13 @@ let Hn = class {
2215
2215
  let t = this.data;
2216
2216
  const i = [];
2217
2217
  if (!$e(e, t)) return i;
2218
- const s = this.toBBox, r = [];
2218
+ const r = this.toBBox, s = [];
2219
2219
  for (; t; ) {
2220
2220
  for (let a = 0; a < t.children.length; a++) {
2221
- const o = t.children[a], l = t.leaf ? s(o) : o;
2222
- $e(e, l) && (t.leaf ? i.push(o) : dt(e, l) ? this._all(o, i) : r.push(o));
2221
+ const o = t.children[a], l = t.leaf ? r(o) : o;
2222
+ $e(e, l) && (t.leaf ? i.push(o) : dt(e, l) ? this._all(o, i) : s.push(o));
2223
2223
  }
2224
- t = r.pop();
2224
+ t = s.pop();
2225
2225
  }
2226
2226
  return i;
2227
2227
  }
@@ -2230,11 +2230,11 @@ let Hn = class {
2230
2230
  if (!$e(e, t)) return !1;
2231
2231
  const i = [];
2232
2232
  for (; t; ) {
2233
- for (let s = 0; s < t.children.length; s++) {
2234
- const r = t.children[s], a = t.leaf ? this.toBBox(r) : r;
2233
+ for (let r = 0; r < t.children.length; r++) {
2234
+ const s = t.children[r], a = t.leaf ? this.toBBox(s) : s;
2235
2235
  if ($e(e, a)) {
2236
2236
  if (t.leaf || dt(e, a)) return !0;
2237
- i.push(r);
2237
+ i.push(s);
2238
2238
  }
2239
2239
  }
2240
2240
  t = i.pop();
@@ -2271,15 +2271,15 @@ let Hn = class {
2271
2271
  remove(e, t) {
2272
2272
  if (!e) return this;
2273
2273
  let i = this.data;
2274
- const s = this.toBBox(e), r = [], a = [];
2274
+ const r = this.toBBox(e), s = [], a = [];
2275
2275
  let o, l, h;
2276
- for (; i || r.length; ) {
2277
- if (i || (i = r.pop(), l = r[r.length - 1], o = a.pop(), h = !0), i.leaf) {
2276
+ for (; i || s.length; ) {
2277
+ if (i || (i = s.pop(), l = s[s.length - 1], o = a.pop(), h = !0), i.leaf) {
2278
2278
  const c = Yn(e, i.children, t);
2279
2279
  if (c !== -1)
2280
- return i.children.splice(c, 1), r.push(i), this._condense(r), this;
2280
+ return i.children.splice(c, 1), s.push(i), this._condense(s), this;
2281
2281
  }
2282
- !h && !i.leaf && dt(i, s) ? (r.push(i), a.push(o), o = 0, l = i, i = i.children[0]) : l ? (o++, i = l.children[o], h = !1) : i = null;
2282
+ !h && !i.leaf && dt(i, r) ? (s.push(i), a.push(o), o = 0, l = i, i = i.children[0]) : l ? (o++, i = l.children[o], h = !1) : i = null;
2283
2283
  }
2284
2284
  return this;
2285
2285
  }
@@ -2304,82 +2304,82 @@ let Hn = class {
2304
2304
  e.leaf ? t.push(...e.children) : i.push(...e.children), e = i.pop();
2305
2305
  return t;
2306
2306
  }
2307
- _build(e, t, i, s) {
2308
- const r = i - t + 1;
2307
+ _build(e, t, i, r) {
2308
+ const s = i - t + 1;
2309
2309
  let a = this._maxEntries, o;
2310
- if (r <= a)
2310
+ if (s <= a)
2311
2311
  return o = ye(e.slice(t, i + 1)), ge(o, this.toBBox), o;
2312
- s || (s = Math.ceil(Math.log(r) / Math.log(a)), a = Math.ceil(r / Math.pow(a, s - 1))), o = ye([]), o.leaf = !1, o.height = s;
2313
- const l = Math.ceil(r / a), h = l * Math.ceil(Math.sqrt(a));
2312
+ r || (r = Math.ceil(Math.log(s) / Math.log(a)), a = Math.ceil(s / Math.pow(a, r - 1))), o = ye([]), o.leaf = !1, o.height = r;
2313
+ const l = Math.ceil(s / a), h = l * Math.ceil(Math.sqrt(a));
2314
2314
  Wt(e, t, i, h, this.compareMinX);
2315
2315
  for (let c = t; c <= i; c += h) {
2316
2316
  const d = Math.min(c + h - 1, i);
2317
2317
  Wt(e, c, d, l, this.compareMinY);
2318
2318
  for (let f = c; f <= d; f += l) {
2319
2319
  const y = Math.min(f + l - 1, d);
2320
- o.children.push(this._build(e, f, y, s - 1));
2320
+ o.children.push(this._build(e, f, y, r - 1));
2321
2321
  }
2322
2322
  }
2323
2323
  return ge(o, this.toBBox), o;
2324
2324
  }
2325
- _chooseSubtree(e, t, i, s) {
2326
- for (; s.push(t), !(t.leaf || s.length - 1 === i); ) {
2327
- let r = 1 / 0, a = 1 / 0, o;
2325
+ _chooseSubtree(e, t, i, r) {
2326
+ for (; r.push(t), !(t.leaf || r.length - 1 === i); ) {
2327
+ let s = 1 / 0, a = 1 / 0, o;
2328
2328
  for (let l = 0; l < t.children.length; l++) {
2329
2329
  const h = t.children[l], c = ut(h), d = Xn(e, h) - c;
2330
- d < a ? (a = d, r = c < r ? c : r, o = h) : d === a && c < r && (r = c, o = h);
2330
+ d < a ? (a = d, s = c < s ? c : s, o = h) : d === a && c < s && (s = c, o = h);
2331
2331
  }
2332
2332
  t = o || t.children[0];
2333
2333
  }
2334
2334
  return t;
2335
2335
  }
2336
2336
  _insert(e, t, i) {
2337
- const s = i ? e : this.toBBox(e), r = [], a = this._chooseSubtree(s, this.data, t, r);
2338
- for (a.children.push(e), Te(a, s); t >= 0 && r[t].children.length > this._maxEntries; )
2339
- this._split(r, t), t--;
2340
- this._adjustParentBBoxes(s, r, t);
2337
+ const r = i ? e : this.toBBox(e), s = [], a = this._chooseSubtree(r, this.data, t, s);
2338
+ for (a.children.push(e), Te(a, r); t >= 0 && s[t].children.length > this._maxEntries; )
2339
+ this._split(s, t), t--;
2340
+ this._adjustParentBBoxes(r, s, t);
2341
2341
  }
2342
2342
  // split overflowed node into two
2343
2343
  _split(e, t) {
2344
- const i = e[t], s = i.children.length, r = this._minEntries;
2345
- this._chooseSplitAxis(i, r, s);
2346
- const a = this._chooseSplitIndex(i, r, s), o = ye(i.children.splice(a, i.children.length - a));
2344
+ const i = e[t], r = i.children.length, s = this._minEntries;
2345
+ this._chooseSplitAxis(i, s, r);
2346
+ const a = this._chooseSplitIndex(i, s, r), o = ye(i.children.splice(a, i.children.length - a));
2347
2347
  o.height = i.height, o.leaf = i.leaf, ge(i, this.toBBox), ge(o, this.toBBox), t ? e[t - 1].children.push(o) : this._splitRoot(i, o);
2348
2348
  }
2349
2349
  _splitRoot(e, t) {
2350
2350
  this.data = ye([e, t]), this.data.height = e.height + 1, this.data.leaf = !1, ge(this.data, this.toBBox);
2351
2351
  }
2352
2352
  _chooseSplitIndex(e, t, i) {
2353
- let s, r = 1 / 0, a = 1 / 0;
2353
+ let r, s = 1 / 0, a = 1 / 0;
2354
2354
  for (let o = t; o <= i - t; o++) {
2355
2355
  const l = De(e, 0, o, this.toBBox), h = De(e, o, i, this.toBBox), c = qn(l, h), d = ut(l) + ut(h);
2356
- c < r ? (r = c, s = o, a = d < a ? d : a) : c === r && d < a && (a = d, s = o);
2356
+ c < s ? (s = c, r = o, a = d < a ? d : a) : c === s && d < a && (a = d, r = o);
2357
2357
  }
2358
- return s || i - t;
2358
+ return r || i - t;
2359
2359
  }
2360
2360
  // sorts node children by the best axis for split
2361
2361
  _chooseSplitAxis(e, t, i) {
2362
- const s = e.leaf ? this.compareMinX : Un, r = e.leaf ? this.compareMinY : $n, a = this._allDistMargin(e, t, i, s), o = this._allDistMargin(e, t, i, r);
2363
- a < o && e.children.sort(s);
2362
+ const r = e.leaf ? this.compareMinX : Un, s = e.leaf ? this.compareMinY : $n, a = this._allDistMargin(e, t, i, r), o = this._allDistMargin(e, t, i, s);
2363
+ a < o && e.children.sort(r);
2364
2364
  }
2365
2365
  // total margin of all possible split distributions where each node is at least m full
2366
- _allDistMargin(e, t, i, s) {
2367
- e.children.sort(s);
2368
- const r = this.toBBox, a = De(e, 0, t, r), o = De(e, i - t, i, r);
2366
+ _allDistMargin(e, t, i, r) {
2367
+ e.children.sort(r);
2368
+ const s = this.toBBox, a = De(e, 0, t, s), o = De(e, i - t, i, s);
2369
2369
  let l = Ue(a) + Ue(o);
2370
2370
  for (let h = t; h < i - t; h++) {
2371
2371
  const c = e.children[h];
2372
- Te(a, e.leaf ? r(c) : c), l += Ue(a);
2372
+ Te(a, e.leaf ? s(c) : c), l += Ue(a);
2373
2373
  }
2374
2374
  for (let h = i - t - 1; h >= t; h--) {
2375
2375
  const c = e.children[h];
2376
- Te(o, e.leaf ? r(c) : c), l += Ue(o);
2376
+ Te(o, e.leaf ? s(c) : c), l += Ue(o);
2377
2377
  }
2378
2378
  return l;
2379
2379
  }
2380
2380
  _adjustParentBBoxes(e, t, i) {
2381
- for (let s = i; s >= 0; s--)
2382
- Te(t[s], e);
2381
+ for (let r = i; r >= 0; r--)
2382
+ Te(t[r], e);
2383
2383
  }
2384
2384
  _condense(e) {
2385
2385
  for (let t = e.length - 1, i; t >= 0; t--)
@@ -2395,13 +2395,13 @@ function Yn(n, e, t) {
2395
2395
  function ge(n, e) {
2396
2396
  De(n, 0, n.children.length, e, n);
2397
2397
  }
2398
- function De(n, e, t, i, s) {
2399
- s || (s = ye(null)), s.minX = 1 / 0, s.minY = 1 / 0, s.maxX = -1 / 0, s.maxY = -1 / 0;
2400
- for (let r = e; r < t; r++) {
2401
- const a = n.children[r];
2402
- Te(s, n.leaf ? i(a) : a);
2398
+ function De(n, e, t, i, r) {
2399
+ r || (r = ye(null)), r.minX = 1 / 0, r.minY = 1 / 0, r.maxX = -1 / 0, r.maxY = -1 / 0;
2400
+ for (let s = e; s < t; s++) {
2401
+ const a = n.children[s];
2402
+ Te(r, n.leaf ? i(a) : a);
2403
2403
  }
2404
- return s;
2404
+ return r;
2405
2405
  }
2406
2406
  function Te(n, e) {
2407
2407
  return n.minX = Math.min(n.minX, e.minX), n.minY = Math.min(n.minY, e.minY), n.maxX = Math.max(n.maxX, e.maxX), n.maxY = Math.max(n.maxY, e.maxY), n;
@@ -2422,8 +2422,8 @@ function Xn(n, e) {
2422
2422
  return (Math.max(e.maxX, n.maxX) - Math.min(e.minX, n.minX)) * (Math.max(e.maxY, n.maxY) - Math.min(e.minY, n.minY));
2423
2423
  }
2424
2424
  function qn(n, e) {
2425
- const t = Math.max(n.minX, e.minX), i = Math.max(n.minY, e.minY), s = Math.min(n.maxX, e.maxX), r = Math.min(n.maxY, e.maxY);
2426
- return Math.max(0, s - t) * Math.max(0, r - i);
2425
+ const t = Math.max(n.minX, e.minX), i = Math.max(n.minY, e.minY), r = Math.min(n.maxX, e.maxX), s = Math.min(n.maxY, e.maxY);
2426
+ return Math.max(0, r - t) * Math.max(0, s - i);
2427
2427
  }
2428
2428
  function dt(n, e) {
2429
2429
  return n.minX <= e.minX && n.minY <= e.minY && e.maxX <= n.maxX && e.maxY <= n.maxY;
@@ -2442,12 +2442,12 @@ function ye(n) {
2442
2442
  maxY: -1 / 0
2443
2443
  };
2444
2444
  }
2445
- function Wt(n, e, t, i, s) {
2446
- const r = [e, t];
2447
- for (; r.length; ) {
2448
- if (t = r.pop(), e = r.pop(), t - e <= i) continue;
2445
+ function Wt(n, e, t, i, r) {
2446
+ const s = [e, t];
2447
+ for (; s.length; ) {
2448
+ if (t = s.pop(), e = s.pop(), t - e <= i) continue;
2449
2449
  const a = e + Math.ceil((t - e) / i / 2) * i;
2450
- wi(n, a, e, t, s), r.push(e, a, a, t);
2450
+ wi(n, a, e, t, r), s.push(e, a, a, t);
2451
2451
  }
2452
2452
  }
2453
2453
  let de = 0;
@@ -2543,7 +2543,7 @@ function M(n, e, t) {
2543
2543
  if (n.length === 0)
2544
2544
  throw new Error("empty expression");
2545
2545
  if (typeof n[0] == "string")
2546
- return hs(n, e, t);
2546
+ return hr(n, e, t);
2547
2547
  for (const i of n)
2548
2548
  if (typeof i != "number")
2549
2549
  throw new Error("expected an array of numbers");
@@ -2619,14 +2619,14 @@ const u = {
2619
2619
  Has: "has"
2620
2620
  }, Qn = {
2621
2621
  [u.Get]: g(_(1, 1 / 0), Ht),
2622
- [u.Var]: g(_(1, 1), es),
2622
+ [u.Var]: g(_(1, 1), er),
2623
2623
  [u.Has]: g(_(1, 1 / 0), Ht),
2624
- [u.Id]: g(ts, _e),
2624
+ [u.Id]: g(tr, _e),
2625
2625
  [u.Concat]: g(
2626
2626
  _(2, 1 / 0),
2627
2627
  p(z)
2628
2628
  ),
2629
- [u.GeometryType]: g(is, _e),
2629
+ [u.GeometryType]: g(ir, _e),
2630
2630
  [u.LineMetric]: g(_e),
2631
2631
  [u.Resolution]: g(ft, _e),
2632
2632
  [u.Zoom]: g(ft, _e),
@@ -2734,7 +2734,7 @@ const u = {
2734
2734
  [u.Match]: g(
2735
2735
  _(4, 1 / 0),
2736
2736
  Ut,
2737
- ss
2737
+ rr
2738
2738
  ),
2739
2739
  [u.Between]: g(
2740
2740
  _(3, 3),
@@ -2743,14 +2743,14 @@ const u = {
2743
2743
  [u.Interpolate]: g(
2744
2744
  _(6, 1 / 0),
2745
2745
  Ut,
2746
- rs
2746
+ sr
2747
2747
  ),
2748
2748
  [u.Case]: g(
2749
2749
  _(3, 1 / 0),
2750
- ns,
2751
- as
2750
+ nr,
2751
+ ar
2752
2752
  ),
2753
- [u.In]: g(_(2, 2), os),
2753
+ [u.In]: g(_(2, 2), or),
2754
2754
  [u.Number]: g(
2755
2755
  _(1, 1 / 0),
2756
2756
  p(Xe)
@@ -2773,7 +2773,7 @@ const u = {
2773
2773
  ),
2774
2774
  [u.Palette]: g(
2775
2775
  _(2, 2),
2776
- ls
2776
+ lr
2777
2777
  ),
2778
2778
  [u.ToString]: g(
2779
2779
  _(1, 1),
@@ -2781,16 +2781,16 @@ const u = {
2781
2781
  )
2782
2782
  };
2783
2783
  function Ht(n, e, t) {
2784
- const i = n.length - 1, s = new Array(i);
2785
- for (let r = 0; r < i; ++r) {
2786
- const a = n[r + 1];
2784
+ const i = n.length - 1, r = new Array(i);
2785
+ for (let s = 0; s < i; ++s) {
2786
+ const a = n[s + 1];
2787
2787
  switch (typeof a) {
2788
2788
  case "number": {
2789
- s[r] = new O(m, a);
2789
+ r[s] = new O(m, a);
2790
2790
  break;
2791
2791
  }
2792
2792
  case "string": {
2793
- s[r] = new O(z, a);
2793
+ r[s] = new O(z, a);
2794
2794
  break;
2795
2795
  }
2796
2796
  default:
@@ -2798,20 +2798,20 @@ function Ht(n, e, t) {
2798
2798
  `expected a string key or numeric array index for a get operation, got ${a}`
2799
2799
  );
2800
2800
  }
2801
- r === 0 && t.properties.add(String(a));
2801
+ s === 0 && t.properties.add(String(a));
2802
2802
  }
2803
- return s;
2803
+ return r;
2804
2804
  }
2805
- function es(n, e, t) {
2805
+ function er(n, e, t) {
2806
2806
  const i = n[1];
2807
2807
  if (typeof i != "string")
2808
2808
  throw new Error("expected a string argument for var operation");
2809
2809
  return t.variables.add(i), [new O(z, i)];
2810
2810
  }
2811
- function ts(n, e, t) {
2811
+ function tr(n, e, t) {
2812
2812
  t.featureId = !0;
2813
2813
  }
2814
- function is(n, e, t) {
2814
+ function ir(n, e, t) {
2815
2815
  t.geometryType = !0;
2816
2816
  }
2817
2817
  function ft(n, e, t) {
@@ -2824,60 +2824,60 @@ function _e(n, e, t) {
2824
2824
  return [];
2825
2825
  }
2826
2826
  function _(n, e) {
2827
- return function(t, i, s) {
2828
- const r = t[0], a = t.length - 1;
2827
+ return function(t, i, r) {
2828
+ const s = t[0], a = t.length - 1;
2829
2829
  if (n === e) {
2830
2830
  if (a !== n) {
2831
2831
  const o = n === 1 ? "" : "s";
2832
2832
  throw new Error(
2833
- `expected ${n} argument${o} for ${r}, got ${a}`
2833
+ `expected ${n} argument${o} for ${s}, got ${a}`
2834
2834
  );
2835
2835
  }
2836
2836
  } else if (a < n || a > e) {
2837
2837
  const o = e === 1 / 0 ? `${n} or more` : `${n} to ${e}`;
2838
2838
  throw new Error(
2839
- `expected ${o} arguments for ${r}, got ${a}`
2839
+ `expected ${o} arguments for ${s}, got ${a}`
2840
2840
  );
2841
2841
  }
2842
2842
  };
2843
2843
  }
2844
2844
  function Yt(n, e, t) {
2845
- const i = n.length - 1, s = new Array(i);
2846
- for (let r = 0; r < i; ++r) {
2847
- const a = M(n[r + 1], e, t);
2848
- s[r] = a;
2845
+ const i = n.length - 1, r = new Array(i);
2846
+ for (let s = 0; s < i; ++s) {
2847
+ const a = M(n[s + 1], e, t);
2848
+ r[s] = a;
2849
2849
  }
2850
- return s;
2850
+ return r;
2851
2851
  }
2852
2852
  function p(n) {
2853
2853
  return function(e, t, i) {
2854
- const s = e.length - 1, r = new Array(s);
2855
- for (let a = 0; a < s; ++a) {
2854
+ const r = e.length - 1, s = new Array(r);
2855
+ for (let a = 0; a < r; ++a) {
2856
2856
  const o = M(e[a + 1], n, i);
2857
- r[a] = o;
2857
+ s[a] = o;
2858
2858
  }
2859
- return r;
2859
+ return s;
2860
2860
  };
2861
2861
  }
2862
- function ns(n, e, t) {
2863
- const i = n[0], s = n.length - 1;
2864
- if (s % 2 === 0)
2862
+ function nr(n, e, t) {
2863
+ const i = n[0], r = n.length - 1;
2864
+ if (r % 2 === 0)
2865
2865
  throw new Error(
2866
- `expected an odd number of arguments for ${i}, got ${s} instead`
2866
+ `expected an odd number of arguments for ${i}, got ${r} instead`
2867
2867
  );
2868
2868
  }
2869
2869
  function Ut(n, e, t) {
2870
- const i = n[0], s = n.length - 1;
2871
- if (s % 2 === 1)
2870
+ const i = n[0], r = n.length - 1;
2871
+ if (r % 2 === 1)
2872
2872
  throw new Error(
2873
- `expected an even number of arguments for operation ${i}, got ${s} instead`
2873
+ `expected an even number of arguments for operation ${i}, got ${r} instead`
2874
2874
  );
2875
2875
  }
2876
- function ss(n, e, t) {
2877
- const i = n.length - 1, s = z | m | N, r = M(n[1], s, t), a = M(n[n.length - 1], e, t), o = new Array(i - 2);
2876
+ function rr(n, e, t) {
2877
+ const i = n.length - 1, r = z | m | N, s = M(n[1], r, t), a = M(n[n.length - 1], e, t), o = new Array(i - 2);
2878
2878
  for (let l = 0; l < i - 2; l += 2) {
2879
2879
  try {
2880
- const h = M(n[l + 2], r.type, t);
2880
+ const h = M(n[l + 2], s.type, t);
2881
2881
  o[l] = h;
2882
2882
  } catch (h) {
2883
2883
  throw new Error(
@@ -2893,14 +2893,14 @@ function ss(n, e, t) {
2893
2893
  );
2894
2894
  }
2895
2895
  }
2896
- return [r, ...o, a];
2896
+ return [s, ...o, a];
2897
2897
  }
2898
- function rs(n, e, t) {
2898
+ function sr(n, e, t) {
2899
2899
  const i = n[1];
2900
- let s;
2900
+ let r;
2901
2901
  switch (i[0]) {
2902
2902
  case "linear":
2903
- s = 1;
2903
+ r = 1;
2904
2904
  break;
2905
2905
  case "exponential":
2906
2906
  const l = i[1];
@@ -2908,14 +2908,14 @@ function rs(n, e, t) {
2908
2908
  throw new Error(
2909
2909
  `expected a number base for exponential interpolation, got ${JSON.stringify(l)} instead`
2910
2910
  );
2911
- s = l;
2911
+ r = l;
2912
2912
  break;
2913
2913
  default:
2914
2914
  throw new Error(
2915
2915
  `invalid interpolation type: ${JSON.stringify(i)}`
2916
2916
  );
2917
2917
  }
2918
- const r = new O(m, s);
2918
+ const s = new O(m, r);
2919
2919
  let a;
2920
2920
  try {
2921
2921
  a = M(n[2], m, t);
@@ -2943,37 +2943,37 @@ function rs(n, e, t) {
2943
2943
  );
2944
2944
  }
2945
2945
  }
2946
- return [r, a, ...o];
2946
+ return [s, a, ...o];
2947
2947
  }
2948
- function as(n, e, t) {
2949
- const i = M(n[n.length - 1], e, t), s = new Array(n.length - 1);
2950
- for (let r = 0; r < s.length - 1; r += 2) {
2948
+ function ar(n, e, t) {
2949
+ const i = M(n[n.length - 1], e, t), r = new Array(n.length - 1);
2950
+ for (let s = 0; s < r.length - 1; s += 2) {
2951
2951
  try {
2952
- const a = M(n[r + 1], N, t);
2953
- s[r] = a;
2952
+ const a = M(n[s + 1], N, t);
2953
+ r[s] = a;
2954
2954
  } catch (a) {
2955
2955
  throw new Error(
2956
- `failed to parse argument ${r} of case expression: ${a.message}`
2956
+ `failed to parse argument ${s} of case expression: ${a.message}`
2957
2957
  );
2958
2958
  }
2959
2959
  try {
2960
- const a = M(n[r + 2], i.type, t);
2961
- s[r + 1] = a;
2960
+ const a = M(n[s + 2], i.type, t);
2961
+ r[s + 1] = a;
2962
2962
  } catch (a) {
2963
2963
  throw new Error(
2964
- `failed to parse argument ${r + 1} of case expression: ${a.message}`
2964
+ `failed to parse argument ${s + 1} of case expression: ${a.message}`
2965
2965
  );
2966
2966
  }
2967
2967
  }
2968
- return s[s.length - 1] = i, s;
2968
+ return r[r.length - 1] = i, r;
2969
2969
  }
2970
- function os(n, e, t) {
2970
+ function or(n, e, t) {
2971
2971
  let i = n[2];
2972
2972
  if (!Array.isArray(i))
2973
2973
  throw new Error(
2974
2974
  'the second argument for the "in" operator must be an array'
2975
2975
  );
2976
- let s;
2976
+ let r;
2977
2977
  if (typeof i[0] == "string") {
2978
2978
  if (i[0] !== "literal")
2979
2979
  throw new Error(
@@ -2983,22 +2983,22 @@ function os(n, e, t) {
2983
2983
  throw new Error(
2984
2984
  'failed to parse "in" expression: the literal operator must be followed by an array'
2985
2985
  );
2986
- i = i[1], s = z;
2986
+ i = i[1], r = z;
2987
2987
  } else
2988
- s = m;
2989
- const r = new Array(i.length);
2990
- for (let o = 0; o < r.length; o++)
2988
+ r = m;
2989
+ const s = new Array(i.length);
2990
+ for (let o = 0; o < s.length; o++)
2991
2991
  try {
2992
- const l = M(i[o], s, t);
2993
- r[o] = l;
2992
+ const l = M(i[o], r, t);
2993
+ s[o] = l;
2994
2994
  } catch (l) {
2995
2995
  throw new Error(
2996
2996
  `failed to parse haystack item ${o} for "in" expression: ${l.message}`
2997
2997
  );
2998
2998
  }
2999
- return [M(n[1], s, t), ...r];
2999
+ return [M(n[1], r, t), ...s];
3000
3000
  }
3001
- function ls(n, e, t) {
3001
+ function lr(n, e, t) {
3002
3002
  let i;
3003
3003
  try {
3004
3004
  i = M(n[1], m, t);
@@ -3007,14 +3007,14 @@ function ls(n, e, t) {
3007
3007
  `failed to parse first argument in palette expression: ${a.message}`
3008
3008
  );
3009
3009
  }
3010
- const s = n[2];
3011
- if (!Array.isArray(s))
3010
+ const r = n[2];
3011
+ if (!Array.isArray(r))
3012
3012
  throw new Error("the second argument of palette must be an array");
3013
- const r = new Array(s.length);
3014
- for (let a = 0; a < r.length; a++) {
3013
+ const s = new Array(r.length);
3014
+ for (let a = 0; a < s.length; a++) {
3015
3015
  let o;
3016
3016
  try {
3017
- o = M(s[a], H, t);
3017
+ o = M(r[a], H, t);
3018
3018
  } catch (l) {
3019
3019
  throw new Error(
3020
3020
  `failed to parse color at index ${a} in palette expression: ${l.message}`
@@ -3024,14 +3024,14 @@ function ls(n, e, t) {
3024
3024
  throw new Error(
3025
3025
  `the palette color at index ${a} must be a literal value`
3026
3026
  );
3027
- r[a] = o;
3027
+ s[a] = o;
3028
3028
  }
3029
- return [i, ...r];
3029
+ return [i, ...s];
3030
3030
  }
3031
3031
  function g(...n) {
3032
3032
  return function(e, t, i) {
3033
- const s = e[0];
3034
- let r;
3033
+ const r = e[0];
3034
+ let s;
3035
3035
  for (let a = 0; a < n.length; a++) {
3036
3036
  const o = n[a](e, t, i);
3037
3037
  if (a == n.length - 1) {
@@ -3039,17 +3039,17 @@ function g(...n) {
3039
3039
  throw new Error(
3040
3040
  "expected last argument validator to return the parsed args"
3041
3041
  );
3042
- r = o;
3042
+ s = o;
3043
3043
  }
3044
3044
  }
3045
- return new Jn(t, s, ...r);
3045
+ return new Jn(t, r, ...s);
3046
3046
  };
3047
3047
  }
3048
- function hs(n, e, t) {
3049
- const i = n[0], s = Qn[i];
3050
- if (!s)
3048
+ function hr(n, e, t) {
3049
+ const i = n[0], r = Qn[i];
3050
+ if (!r)
3051
3051
  throw new Error(`unknown operator: ${i}`);
3052
- return s(n, e, t);
3052
+ return r(n, e, t);
3053
3053
  }
3054
3054
  function Ci(n) {
3055
3055
  if (!n)
@@ -3108,18 +3108,18 @@ function $(n, e) {
3108
3108
  case u.Number:
3109
3109
  case u.String:
3110
3110
  case u.Coalesce:
3111
- return cs(n);
3111
+ return cr(n);
3112
3112
  case u.Get:
3113
3113
  case u.Var:
3114
3114
  case u.Has:
3115
- return us(n);
3115
+ return ur(n);
3116
3116
  case u.Id:
3117
3117
  return (i) => i.featureId;
3118
3118
  case u.GeometryType:
3119
3119
  return (i) => i.geometryType;
3120
3120
  case u.Concat: {
3121
- const i = n.args.map((s) => $(s));
3122
- return (s) => "".concat(...i.map((r) => r(s).toString()));
3121
+ const i = n.args.map((r) => $(r));
3122
+ return (r) => "".concat(...i.map((s) => s(r).toString()));
3123
3123
  }
3124
3124
  case u.Resolution:
3125
3125
  return (i) => i.resolution;
@@ -3128,14 +3128,14 @@ function $(n, e) {
3128
3128
  case u.Between:
3129
3129
  case u.In:
3130
3130
  case u.Not:
3131
- return fs(n);
3131
+ return fr(n);
3132
3132
  case u.Equal:
3133
3133
  case u.NotEqual:
3134
3134
  case u.LessThan:
3135
3135
  case u.LessThanOrEqualTo:
3136
3136
  case u.GreaterThan:
3137
3137
  case u.GreaterThanOrEqualTo:
3138
- return ds(n);
3138
+ return dr(n);
3139
3139
  case u.Multiply:
3140
3140
  case u.Divide:
3141
3141
  case u.Add:
@@ -3151,28 +3151,28 @@ function $(n, e) {
3151
3151
  case u.Cos:
3152
3152
  case u.Atan:
3153
3153
  case u.Sqrt:
3154
- return gs(n);
3154
+ return gr(n);
3155
3155
  case u.Case:
3156
- return _s(n);
3156
+ return _r(n);
3157
3157
  case u.Match:
3158
- return ms(n);
3158
+ return mr(n);
3159
3159
  case u.Interpolate:
3160
- return ys(n);
3160
+ return yr(n);
3161
3161
  case u.ToString:
3162
- return ps(n);
3162
+ return pr(n);
3163
3163
  default:
3164
3164
  throw new Error(`Unsupported operator ${t}`);
3165
3165
  }
3166
3166
  }
3167
- function cs(n, e) {
3168
- const t = n.operator, i = n.args.length, s = new Array(i);
3169
- for (let r = 0; r < i; ++r)
3170
- s[r] = $(n.args[r]);
3167
+ function cr(n, e) {
3168
+ const t = n.operator, i = n.args.length, r = new Array(i);
3169
+ for (let s = 0; s < i; ++s)
3170
+ r[s] = $(n.args[s]);
3171
3171
  switch (t) {
3172
3172
  case u.Coalesce:
3173
- return (r) => {
3173
+ return (s) => {
3174
3174
  for (let a = 0; a < i; ++a) {
3175
- const o = s[a](r);
3175
+ const o = r[a](s);
3176
3176
  if (typeof o < "u" && o !== null)
3177
3177
  return o;
3178
3178
  }
@@ -3180,9 +3180,9 @@ function cs(n, e) {
3180
3180
  };
3181
3181
  case u.Number:
3182
3182
  case u.String:
3183
- return (r) => {
3183
+ return (s) => {
3184
3184
  for (let a = 0; a < i; ++a) {
3185
- const o = s[a](r);
3185
+ const o = r[a](s);
3186
3186
  if (typeof o === t)
3187
3187
  return o;
3188
3188
  }
@@ -3192,7 +3192,7 @@ function cs(n, e) {
3192
3192
  throw new Error(`Unsupported assertion operator ${t}`);
3193
3193
  }
3194
3194
  }
3195
- function us(n, e) {
3195
+ function ur(n, e) {
3196
3196
  const i = (
3197
3197
  /** @type {string} */
3198
3198
  /** @type {LiteralExpression} */
@@ -3200,32 +3200,32 @@ function us(n, e) {
3200
3200
  );
3201
3201
  switch (n.operator) {
3202
3202
  case u.Get:
3203
- return (s) => {
3204
- const r = n.args;
3205
- let a = s.properties[i];
3206
- for (let o = 1, l = r.length; o < l; ++o) {
3203
+ return (r) => {
3204
+ const s = n.args;
3205
+ let a = r.properties[i];
3206
+ for (let o = 1, l = s.length; o < l; ++o) {
3207
3207
  const c = (
3208
3208
  /** @type {string|number} */
3209
3209
  /** @type {LiteralExpression} */
3210
- r[o].value
3210
+ s[o].value
3211
3211
  );
3212
3212
  a = a[c];
3213
3213
  }
3214
3214
  return a;
3215
3215
  };
3216
3216
  case u.Var:
3217
- return (s) => s.variables[i];
3217
+ return (r) => r.variables[i];
3218
3218
  case u.Has:
3219
- return (s) => {
3220
- const r = n.args;
3221
- if (!(i in s.properties))
3219
+ return (r) => {
3220
+ const s = n.args;
3221
+ if (!(i in r.properties))
3222
3222
  return !1;
3223
- let a = s.properties[i];
3224
- for (let o = 1, l = r.length; o < l; ++o) {
3223
+ let a = r.properties[i];
3224
+ for (let o = 1, l = s.length; o < l; ++o) {
3225
3225
  const c = (
3226
3226
  /** @type {string|number} */
3227
3227
  /** @type {LiteralExpression} */
3228
- r[o].value
3228
+ s[o].value
3229
3229
  );
3230
3230
  if (!a || !Object.hasOwn(a, c))
3231
3231
  return !1;
@@ -3237,162 +3237,162 @@ function us(n, e) {
3237
3237
  throw new Error(`Unsupported accessor operator ${n.operator}`);
3238
3238
  }
3239
3239
  }
3240
- function ds(n, e) {
3241
- const t = n.operator, i = $(n.args[0]), s = $(n.args[1]);
3240
+ function dr(n, e) {
3241
+ const t = n.operator, i = $(n.args[0]), r = $(n.args[1]);
3242
3242
  switch (t) {
3243
3243
  case u.Equal:
3244
- return (r) => i(r) === s(r);
3244
+ return (s) => i(s) === r(s);
3245
3245
  case u.NotEqual:
3246
- return (r) => i(r) !== s(r);
3246
+ return (s) => i(s) !== r(s);
3247
3247
  case u.LessThan:
3248
- return (r) => i(r) < s(r);
3248
+ return (s) => i(s) < r(s);
3249
3249
  case u.LessThanOrEqualTo:
3250
- return (r) => i(r) <= s(r);
3250
+ return (s) => i(s) <= r(s);
3251
3251
  case u.GreaterThan:
3252
- return (r) => i(r) > s(r);
3252
+ return (s) => i(s) > r(s);
3253
3253
  case u.GreaterThanOrEqualTo:
3254
- return (r) => i(r) >= s(r);
3254
+ return (s) => i(s) >= r(s);
3255
3255
  default:
3256
3256
  throw new Error(`Unsupported comparison operator ${t}`);
3257
3257
  }
3258
3258
  }
3259
- function fs(n, e) {
3260
- const t = n.operator, i = n.args.length, s = new Array(i);
3261
- for (let r = 0; r < i; ++r)
3262
- s[r] = $(n.args[r]);
3259
+ function fr(n, e) {
3260
+ const t = n.operator, i = n.args.length, r = new Array(i);
3261
+ for (let s = 0; s < i; ++s)
3262
+ r[s] = $(n.args[s]);
3263
3263
  switch (t) {
3264
3264
  case u.Any:
3265
- return (r) => {
3265
+ return (s) => {
3266
3266
  for (let a = 0; a < i; ++a)
3267
- if (s[a](r))
3267
+ if (r[a](s))
3268
3268
  return !0;
3269
3269
  return !1;
3270
3270
  };
3271
3271
  case u.All:
3272
- return (r) => {
3272
+ return (s) => {
3273
3273
  for (let a = 0; a < i; ++a)
3274
- if (!s[a](r))
3274
+ if (!r[a](s))
3275
3275
  return !1;
3276
3276
  return !0;
3277
3277
  };
3278
3278
  case u.Between:
3279
- return (r) => {
3280
- const a = s[0](r), o = s[1](r), l = s[2](r);
3279
+ return (s) => {
3280
+ const a = r[0](s), o = r[1](s), l = r[2](s);
3281
3281
  return a >= o && a <= l;
3282
3282
  };
3283
3283
  case u.In:
3284
- return (r) => {
3285
- const a = s[0](r);
3284
+ return (s) => {
3285
+ const a = r[0](s);
3286
3286
  for (let o = 1; o < i; ++o)
3287
- if (a === s[o](r))
3287
+ if (a === r[o](s))
3288
3288
  return !0;
3289
3289
  return !1;
3290
3290
  };
3291
3291
  case u.Not:
3292
- return (r) => !s[0](r);
3292
+ return (s) => !r[0](s);
3293
3293
  default:
3294
3294
  throw new Error(`Unsupported logical operator ${t}`);
3295
3295
  }
3296
3296
  }
3297
- function gs(n, e) {
3298
- const t = n.operator, i = n.args.length, s = new Array(i);
3299
- for (let r = 0; r < i; ++r)
3300
- s[r] = $(n.args[r]);
3297
+ function gr(n, e) {
3298
+ const t = n.operator, i = n.args.length, r = new Array(i);
3299
+ for (let s = 0; s < i; ++s)
3300
+ r[s] = $(n.args[s]);
3301
3301
  switch (t) {
3302
3302
  case u.Multiply:
3303
- return (r) => {
3303
+ return (s) => {
3304
3304
  let a = 1;
3305
3305
  for (let o = 0; o < i; ++o)
3306
- a *= s[o](r);
3306
+ a *= r[o](s);
3307
3307
  return a;
3308
3308
  };
3309
3309
  case u.Divide:
3310
- return (r) => s[0](r) / s[1](r);
3310
+ return (s) => r[0](s) / r[1](s);
3311
3311
  case u.Add:
3312
- return (r) => {
3312
+ return (s) => {
3313
3313
  let a = 0;
3314
3314
  for (let o = 0; o < i; ++o)
3315
- a += s[o](r);
3315
+ a += r[o](s);
3316
3316
  return a;
3317
3317
  };
3318
3318
  case u.Subtract:
3319
- return (r) => s[0](r) - s[1](r);
3319
+ return (s) => r[0](s) - r[1](s);
3320
3320
  case u.Clamp:
3321
- return (r) => {
3322
- const a = s[0](r), o = s[1](r);
3321
+ return (s) => {
3322
+ const a = r[0](s), o = r[1](s);
3323
3323
  if (a < o)
3324
3324
  return o;
3325
- const l = s[2](r);
3325
+ const l = r[2](s);
3326
3326
  return a > l ? l : a;
3327
3327
  };
3328
3328
  case u.Mod:
3329
- return (r) => s[0](r) % s[1](r);
3329
+ return (s) => r[0](s) % r[1](s);
3330
3330
  case u.Pow:
3331
- return (r) => Math.pow(s[0](r), s[1](r));
3331
+ return (s) => Math.pow(r[0](s), r[1](s));
3332
3332
  case u.Abs:
3333
- return (r) => Math.abs(s[0](r));
3333
+ return (s) => Math.abs(r[0](s));
3334
3334
  case u.Floor:
3335
- return (r) => Math.floor(s[0](r));
3335
+ return (s) => Math.floor(r[0](s));
3336
3336
  case u.Ceil:
3337
- return (r) => Math.ceil(s[0](r));
3337
+ return (s) => Math.ceil(r[0](s));
3338
3338
  case u.Round:
3339
- return (r) => Math.round(s[0](r));
3339
+ return (s) => Math.round(r[0](s));
3340
3340
  case u.Sin:
3341
- return (r) => Math.sin(s[0](r));
3341
+ return (s) => Math.sin(r[0](s));
3342
3342
  case u.Cos:
3343
- return (r) => Math.cos(s[0](r));
3343
+ return (s) => Math.cos(r[0](s));
3344
3344
  case u.Atan:
3345
- return i === 2 ? (r) => Math.atan2(s[0](r), s[1](r)) : (r) => Math.atan(s[0](r));
3345
+ return i === 2 ? (s) => Math.atan2(r[0](s), r[1](s)) : (s) => Math.atan(r[0](s));
3346
3346
  case u.Sqrt:
3347
- return (r) => Math.sqrt(s[0](r));
3347
+ return (s) => Math.sqrt(r[0](s));
3348
3348
  default:
3349
3349
  throw new Error(`Unsupported numeric operator ${t}`);
3350
3350
  }
3351
3351
  }
3352
- function _s(n, e) {
3352
+ function _r(n, e) {
3353
3353
  const t = n.args.length, i = new Array(t);
3354
- for (let s = 0; s < t; ++s)
3355
- i[s] = $(n.args[s]);
3356
- return (s) => {
3357
- for (let r = 0; r < t - 1; r += 2)
3358
- if (i[r](s))
3359
- return i[r + 1](s);
3360
- return i[t - 1](s);
3354
+ for (let r = 0; r < t; ++r)
3355
+ i[r] = $(n.args[r]);
3356
+ return (r) => {
3357
+ for (let s = 0; s < t - 1; s += 2)
3358
+ if (i[s](r))
3359
+ return i[s + 1](r);
3360
+ return i[t - 1](r);
3361
3361
  };
3362
3362
  }
3363
- function ms(n, e) {
3363
+ function mr(n, e) {
3364
3364
  const t = n.args.length, i = new Array(t);
3365
- for (let s = 0; s < t; ++s)
3366
- i[s] = $(n.args[s]);
3367
- return (s) => {
3368
- const r = i[0](s);
3365
+ for (let r = 0; r < t; ++r)
3366
+ i[r] = $(n.args[r]);
3367
+ return (r) => {
3368
+ const s = i[0](r);
3369
3369
  for (let a = 1; a < t - 1; a += 2)
3370
- if (r === i[a](s))
3371
- return i[a + 1](s);
3372
- return i[t - 1](s);
3370
+ if (s === i[a](r))
3371
+ return i[a + 1](r);
3372
+ return i[t - 1](r);
3373
3373
  };
3374
3374
  }
3375
- function ys(n, e) {
3375
+ function yr(n, e) {
3376
3376
  const t = n.args.length, i = new Array(t);
3377
- for (let s = 0; s < t; ++s)
3378
- i[s] = $(n.args[s]);
3379
- return (s) => {
3380
- const r = i[0](s), a = i[1](s);
3377
+ for (let r = 0; r < t; ++r)
3378
+ i[r] = $(n.args[r]);
3379
+ return (r) => {
3380
+ const s = i[0](r), a = i[1](r);
3381
3381
  let o, l;
3382
3382
  for (let h = 2; h < t; h += 2) {
3383
- const c = i[h](s);
3384
- let d = i[h + 1](s);
3383
+ const c = i[h](r);
3384
+ let d = i[h + 1](r);
3385
3385
  const f = Array.isArray(d);
3386
3386
  if (f && (d = hn(d)), c >= a)
3387
- return h === 2 ? d : f ? Es(
3388
- r,
3387
+ return h === 2 ? d : f ? Er(
3388
+ s,
3389
3389
  a,
3390
3390
  o,
3391
3391
  l,
3392
3392
  c,
3393
3393
  d
3394
3394
  ) : Oe(
3395
- r,
3395
+ s,
3396
3396
  a,
3397
3397
  o,
3398
3398
  l,
@@ -3404,42 +3404,42 @@ function ys(n, e) {
3404
3404
  return l;
3405
3405
  };
3406
3406
  }
3407
- function ps(n, e) {
3408
- const t = n.operator, i = n.args.length, s = new Array(i);
3409
- for (let r = 0; r < i; ++r)
3410
- s[r] = $(n.args[r]);
3407
+ function pr(n, e) {
3408
+ const t = n.operator, i = n.args.length, r = new Array(i);
3409
+ for (let s = 0; s < i; ++s)
3410
+ r[s] = $(n.args[s]);
3411
3411
  switch (t) {
3412
3412
  case u.ToString:
3413
- return (r) => {
3414
- const a = s[0](r);
3413
+ return (s) => {
3414
+ const a = r[0](s);
3415
3415
  return n.args[0].type === H ? fi(a) : a.toString();
3416
3416
  };
3417
3417
  default:
3418
3418
  throw new Error(`Unsupported convert operator ${t}`);
3419
3419
  }
3420
3420
  }
3421
- function Oe(n, e, t, i, s, r) {
3422
- const a = s - t;
3421
+ function Oe(n, e, t, i, r, s) {
3422
+ const a = r - t;
3423
3423
  if (a === 0)
3424
3424
  return i;
3425
3425
  const o = e - t, l = n === 1 ? o / a : (Math.pow(n, o) - 1) / (Math.pow(n, a) - 1);
3426
- return i + l * (r - i);
3426
+ return i + l * (s - i);
3427
3427
  }
3428
- function Es(n, e, t, i, s, r) {
3429
- if (s - t === 0)
3428
+ function Er(n, e, t, i, r, s) {
3429
+ if (r - t === 0)
3430
3430
  return i;
3431
- const o = Kt(i), l = Kt(r);
3431
+ const o = Kt(i), l = Kt(s);
3432
3432
  let h = l[2] - o[2];
3433
3433
  h > 180 ? h -= 360 : h < -180 && (h += 360);
3434
3434
  const c = [
3435
- Oe(n, e, t, o[0], s, l[0]),
3436
- Oe(n, e, t, o[1], s, l[1]),
3437
- o[2] + Oe(n, e, t, 0, s, h),
3438
- Oe(n, e, t, i[3], s, r[3])
3435
+ Oe(n, e, t, o[0], r, l[0]),
3436
+ Oe(n, e, t, o[1], r, l[1]),
3437
+ o[2] + Oe(n, e, t, 0, r, h),
3438
+ Oe(n, e, t, i[3], r, s[3])
3439
3439
  ];
3440
3440
  return cn(c);
3441
3441
  }
3442
- class ws {
3442
+ class wr {
3443
3443
  constructor() {
3444
3444
  this.cache_ = {}, this.patternCache_ = {}, this.cacheSize_ = 0, this.maxCacheSize_ = 1024;
3445
3445
  }
@@ -3474,8 +3474,8 @@ class ws {
3474
3474
  * @return {import("./IconImage.js").default} Icon image.
3475
3475
  */
3476
3476
  get(e, t, i) {
3477
- const s = gt(e, t, i);
3478
- return s in this.cache_ ? this.cache_[s] : null;
3477
+ const r = gt(e, t, i);
3478
+ return r in this.cache_ ? this.cache_[r] : null;
3479
3479
  }
3480
3480
  /**
3481
3481
  * @param {string} src Src.
@@ -3484,8 +3484,8 @@ class ws {
3484
3484
  * @return {CanvasPattern} Icon image.
3485
3485
  */
3486
3486
  getPattern(e, t, i) {
3487
- const s = gt(e, t, i);
3488
- return s in this.patternCache_ ? this.patternCache_[s] : null;
3487
+ const r = gt(e, t, i);
3488
+ return r in this.patternCache_ ? this.patternCache_[r] : null;
3489
3489
  }
3490
3490
  /**
3491
3491
  * @param {string} src Src.
@@ -3494,15 +3494,15 @@ class ws {
3494
3494
  * @param {import("./IconImage.js").default|null} iconImage Icon image.
3495
3495
  * @param {boolean} [pattern] Also cache a `'repeat'` pattern with this `iconImage`.
3496
3496
  */
3497
- set(e, t, i, s, r) {
3497
+ set(e, t, i, r, s) {
3498
3498
  const a = gt(e, t, i), o = a in this.cache_;
3499
- this.cache_[a] = s, r && (s.getImageState() === E.IDLE && s.load(), s.getImageState() === E.LOADING ? s.ready().then(() => {
3499
+ this.cache_[a] = r, s && (r.getImageState() === E.IDLE && r.load(), r.getImageState() === E.LOADING ? r.ready().then(() => {
3500
3500
  this.patternCache_[a] = kt().createPattern(
3501
- s.getImage(1),
3501
+ r.getImage(1),
3502
3502
  "repeat"
3503
3503
  );
3504
3504
  }) : this.patternCache_[a] = kt().createPattern(
3505
- s.getImage(1),
3505
+ r.getImage(1),
3506
3506
  "repeat"
3507
3507
  )), o || ++this.cacheSize_;
3508
3508
  }
@@ -3518,12 +3518,12 @@ class ws {
3518
3518
  }
3519
3519
  }
3520
3520
  function gt(n, e, t) {
3521
- const i = t ? st(t) : "null";
3521
+ const i = t ? rt(t) : "null";
3522
3522
  return e + ":" + n + ":" + i;
3523
3523
  }
3524
- const W = new ws();
3524
+ const W = new wr();
3525
3525
  let Ie = null;
3526
- class Ai extends ri {
3526
+ class Ai extends si {
3527
3527
  /**
3528
3528
  * @param {HTMLImageElement|HTMLCanvasElement|OffscreenCanvas|ImageBitmap|null} image Image.
3529
3529
  * @param {string|undefined} src Src.
@@ -3531,8 +3531,8 @@ class Ai extends ri {
3531
3531
  * @param {import("../ImageState.js").default|undefined} imageState Image state.
3532
3532
  * @param {import("../color.js").Color|string|null} color Color.
3533
3533
  */
3534
- constructor(e, t, i, s, r) {
3535
- super(), this.hitDetectionImage_ = null, this.image_ = e, this.crossOrigin_ = i, this.canvas_ = {}, this.color_ = r, this.imageState_ = s === void 0 ? E.IDLE : s, this.size_ = e && e.width && e.height ? [e.width, e.height] : null, this.src_ = t, this.tainted_, this.ready_ = null;
3534
+ constructor(e, t, i, r, s) {
3535
+ super(), this.hitDetectionImage_ = null, this.image_ = e, this.crossOrigin_ = i, this.canvas_ = {}, this.color_ = s, this.imageState_ = r === void 0 ? E.IDLE : r, this.size_ = e && e.width && e.height ? [e.width, e.height] : null, this.src_ = t, this.tainted_, this.ready_ = null;
3536
3536
  }
3537
3537
  /**
3538
3538
  * @private
@@ -3646,8 +3646,8 @@ class Ai extends ri {
3646
3646
  const t = this.image_, i = he(
3647
3647
  Math.ceil(t.width * e),
3648
3648
  Math.ceil(t.height * e)
3649
- ), s = i.canvas;
3650
- i.scale(e, e), i.drawImage(t, 0, 0), i.globalCompositeOperation = "multiply", i.fillStyle = un(this.color_), i.fillRect(0, 0, s.width / e, s.height / e), i.globalCompositeOperation = "destination-in", i.drawImage(t, 0, 0), this.canvas_[e] = s;
3649
+ ), r = i.canvas;
3650
+ i.scale(e, e), i.drawImage(t, 0, 0), i.globalCompositeOperation = "multiply", i.fillStyle = un(this.color_), i.fillRect(0, 0, r.width / e, r.height / e), i.globalCompositeOperation = "destination-in", i.drawImage(t, 0, 0), this.canvas_[e] = r;
3651
3651
  }
3652
3652
  /**
3653
3653
  * @return {Promise<void>} Promise that resolves when the image is loaded.
@@ -3665,20 +3665,20 @@ class Ai extends ri {
3665
3665
  })), this.ready_;
3666
3666
  }
3667
3667
  }
3668
- function Je(n, e, t, i, s, r) {
3669
- let a = e === void 0 ? void 0 : W.get(e, t, s);
3668
+ function Je(n, e, t, i, r, s) {
3669
+ let a = e === void 0 ? void 0 : W.get(e, t, r);
3670
3670
  return a || (a = new Ai(
3671
3671
  n,
3672
3672
  n && "src" in n ? n.src || void 0 : e,
3673
3673
  t,
3674
3674
  i,
3675
- s
3676
- ), W.set(e, t, s, a, r)), r && a && !W.getPattern(e, t, s) && W.set(e, t, s, a, r), a;
3675
+ r
3676
+ ), W.set(e, t, r, a, s)), s && a && !W.getPattern(e, t, r) && W.set(e, t, r, a, s), a;
3677
3677
  }
3678
3678
  function $t(n) {
3679
- return n ? Array.isArray(n) ? fi(n) : typeof n == "object" && "src" in n ? vs(n) : n : null;
3679
+ return n ? Array.isArray(n) ? fi(n) : typeof n == "object" && "src" in n ? vr(n) : n : null;
3680
3680
  }
3681
- function vs(n) {
3681
+ function vr(n) {
3682
3682
  if (!n.offset || !n.size)
3683
3683
  return W.getPattern(n.src, "anonymous", n.color);
3684
3684
  const e = n.src + ":" + n.offset, t = W.getPattern(
@@ -3691,11 +3691,11 @@ function vs(n) {
3691
3691
  const i = W.get(n.src, "anonymous", null);
3692
3692
  if (i.getImageState() !== E.LOADED)
3693
3693
  return null;
3694
- const s = he(
3694
+ const r = he(
3695
3695
  n.size[0],
3696
3696
  n.size[1]
3697
3697
  );
3698
- return s.drawImage(
3698
+ return r.drawImage(
3699
3699
  i.getImage(1),
3700
3700
  n.offset[0],
3701
3701
  n.offset[1],
@@ -3706,7 +3706,7 @@ function vs(n) {
3706
3706
  n.size[0],
3707
3707
  n.size[1]
3708
3708
  ), Je(
3709
- s.canvas,
3709
+ r.canvas,
3710
3710
  e,
3711
3711
  void 0,
3712
3712
  E.LOADED,
@@ -3714,9 +3714,9 @@ function vs(n) {
3714
3714
  !0
3715
3715
  ), W.getPattern(e, void 0, n.color);
3716
3716
  }
3717
- const hr = "10px sans-serif", Xt = "#000", qt = "round", cr = [], ur = 0, Zt = "round", Cs = 10, Ls = "#000", dr = "center", fr = "middle", gr = [0, 0, 0, 0], As = 1, pe = new tt();
3717
+ const hs = "10px sans-serif", Xt = "#000", qt = "round", cs = [], us = 0, Zt = "round", Cr = 10, Lr = "#000", ds = "center", fs = "middle", gs = [0, 0, 0, 0], Ar = 1, pe = new tt();
3718
3718
  let be = null, jt;
3719
- const Et = {}, Is = /* @__PURE__ */ new Set([
3719
+ const Et = {}, Ir = /* @__PURE__ */ new Set([
3720
3720
  "serif",
3721
3721
  "sans-serif",
3722
3722
  "monospace",
@@ -3731,17 +3731,17 @@ const Et = {}, Is = /* @__PURE__ */ new Set([
3731
3731
  "math",
3732
3732
  "fangsong"
3733
3733
  ]);
3734
- function bs(n, e, t) {
3734
+ function br(n, e, t) {
3735
3735
  return `${n} ${e} 16px "${t}"`;
3736
3736
  }
3737
- const _r = /* @__PURE__ */ (function() {
3737
+ const _s = /* @__PURE__ */ (function() {
3738
3738
  let e, t;
3739
- async function i(r) {
3739
+ async function i(s) {
3740
3740
  await t.ready;
3741
- const a = await t.load(r);
3741
+ const a = await t.load(s);
3742
3742
  if (a.length === 0)
3743
3743
  return !1;
3744
- const o = mt(r), l = o.families[0].toLowerCase(), h = o.weight;
3744
+ const o = mt(s), l = o.families[0].toLowerCase(), h = o.weight;
3745
3745
  return a.some(
3746
3746
  /**
3747
3747
  * @param {import('../css.js').FontParameters} f Font.
@@ -3753,42 +3753,42 @@ const _r = /* @__PURE__ */ (function() {
3753
3753
  }
3754
3754
  );
3755
3755
  }
3756
- async function s() {
3756
+ async function r() {
3757
3757
  await t.ready;
3758
- let r = !0;
3758
+ let s = !0;
3759
3759
  const a = pe.getProperties(), o = Object.keys(a).filter(
3760
3760
  (l) => a[l] < 100
3761
3761
  );
3762
3762
  for (let l = o.length - 1; l >= 0; --l) {
3763
3763
  const h = o[l];
3764
3764
  let c = a[h];
3765
- c < 100 && (await i(h) ? (Ct(Et), pe.set(h, 100)) : (c += 10, pe.set(h, c, !0), c < 100 && (r = !1)));
3765
+ c < 100 && (await i(h) ? (Ct(Et), pe.set(h, 100)) : (c += 10, pe.set(h, c, !0), c < 100 && (s = !1)));
3766
3766
  }
3767
- e = void 0, r || (e = setTimeout(s, 100));
3767
+ e = void 0, s || (e = setTimeout(r, 100));
3768
3768
  }
3769
- return async function(r) {
3769
+ return async function(s) {
3770
3770
  t || (t = oe ? self.fonts : document.fonts);
3771
- const a = mt(r);
3771
+ const a = mt(s);
3772
3772
  if (!a)
3773
3773
  return;
3774
3774
  const o = a.families;
3775
3775
  let l = !1;
3776
3776
  for (const h of o) {
3777
- if (Is.has(h))
3777
+ if (Ir.has(h))
3778
3778
  continue;
3779
- const c = bs(a.style, a.weight, h);
3779
+ const c = br(a.style, a.weight, h);
3780
3780
  pe.get(c) === void 0 && (pe.set(c, 0, !0), l = !0);
3781
3781
  }
3782
- l && (clearTimeout(e), e = setTimeout(s, 100));
3782
+ l && (clearTimeout(e), e = setTimeout(r, 100));
3783
3783
  };
3784
- })(), Ds = /* @__PURE__ */ (function() {
3784
+ })(), Dr = /* @__PURE__ */ (function() {
3785
3785
  let n;
3786
3786
  return function(e) {
3787
3787
  let t = Et[e];
3788
3788
  if (t == null) {
3789
3789
  if (oe) {
3790
- const i = mt(e), s = Ii(e, "Žg");
3791
- t = (isNaN(Number(i.lineHeight)) ? 1.2 : Number(i.lineHeight)) * (s.actualBoundingBoxAscent + s.actualBoundingBoxDescent);
3790
+ const i = mt(e), r = Ii(e, "Žg");
3791
+ t = (isNaN(Number(i.lineHeight)) ? 1.2 : Number(i.lineHeight)) * (r.actualBoundingBoxAscent + r.actualBoundingBoxDescent);
3792
3792
  } else
3793
3793
  n || (n = document.createElement("div"), n.innerHTML = "M", n.style.minHeight = "0", n.style.maxHeight = "none", n.style.height = "auto", n.style.padding = "0", n.style.border = "none", n.style.position = "absolute", n.style.display = "block", n.style.left = "-99999px"), n.style.font = e, document.body.appendChild(n), t = n.offsetHeight, document.body.removeChild(n);
3794
3794
  Et[e] = t;
@@ -3802,41 +3802,41 @@ function Ii(n, e) {
3802
3802
  function bi(n, e) {
3803
3803
  return Ii(n, e).width;
3804
3804
  }
3805
- function mr(n, e, t) {
3805
+ function ms(n, e, t) {
3806
3806
  if (e in t)
3807
3807
  return t[e];
3808
3808
  const i = e.split(`
3809
- `).reduce((s, r) => Math.max(s, bi(n, r)), 0);
3809
+ `).reduce((r, s) => Math.max(r, bi(n, s)), 0);
3810
3810
  return t[e] = i, i;
3811
3811
  }
3812
- function yr(n, e) {
3813
- const t = [], i = [], s = [];
3814
- let r = 0, a = 0, o = 0, l = 0;
3812
+ function ys(n, e) {
3813
+ const t = [], i = [], r = [];
3814
+ let s = 0, a = 0, o = 0, l = 0;
3815
3815
  for (let h = 0, c = e.length; h <= c; h += 2) {
3816
3816
  const d = e[h];
3817
3817
  if (d === `
3818
3818
  ` || h === c) {
3819
- r = Math.max(r, a), s.push(a), a = 0, o += l, l = 0;
3819
+ s = Math.max(s, a), r.push(a), a = 0, o += l, l = 0;
3820
3820
  continue;
3821
3821
  }
3822
3822
  const f = e[h + 1] || n.font, y = bi(f, d);
3823
3823
  t.push(y), a += y;
3824
- const v = Ds(f);
3824
+ const v = Dr(f);
3825
3825
  i.push(v), l = Math.max(l, v);
3826
3826
  }
3827
- return { width: r, height: o, widths: t, heights: i, lineWidths: s };
3827
+ return { width: s, height: o, widths: t, heights: i, lineWidths: r };
3828
3828
  }
3829
- function pr(n, e, t, i, s, r, a, o, l, h, c) {
3829
+ function ps(n, e, t, i, r, s, a, o, l, h, c) {
3830
3830
  n.save(), t !== 1 && (n.globalAlpha === void 0 ? n.globalAlpha = (d) => d.globalAlpha *= t : n.globalAlpha *= t), e && n.transform.apply(n, e), /** @type {*} */
3831
- i.contextInstructions ? (n.translate(l, h), n.scale(c[0], c[1]), Ts(
3831
+ i.contextInstructions ? (n.translate(l, h), n.scale(c[0], c[1]), Tr(
3832
3832
  /** @type {Label} */
3833
3833
  i,
3834
3834
  n
3835
3835
  )) : c[0] < 0 || c[1] < 0 ? (n.translate(l, h), n.scale(c[0], c[1]), n.drawImage(
3836
3836
  /** @type {HTMLCanvasElement|HTMLImageElement|HTMLVideoElement} */
3837
3837
  i,
3838
- s,
3839
3838
  r,
3839
+ s,
3840
3840
  a,
3841
3841
  o,
3842
3842
  0,
@@ -3846,8 +3846,8 @@ function pr(n, e, t, i, s, r, a, o, l, h, c) {
3846
3846
  )) : n.drawImage(
3847
3847
  /** @type {HTMLCanvasElement|HTMLImageElement|HTMLVideoElement} */
3848
3848
  i,
3849
- s,
3850
3849
  r,
3850
+ s,
3851
3851
  a,
3852
3852
  o,
3853
3853
  l,
@@ -3856,15 +3856,15 @@ function pr(n, e, t, i, s, r, a, o, l, h, c) {
3856
3856
  o * c[1]
3857
3857
  ), n.restore();
3858
3858
  }
3859
- function Ts(n, e) {
3859
+ function Tr(n, e) {
3860
3860
  const t = n.contextInstructions;
3861
- for (let i = 0, s = t.length; i < s; i += 2)
3861
+ for (let i = 0, r = t.length; i < r; i += 2)
3862
3862
  Array.isArray(t[i + 1]) ? e[t[i]].apply(
3863
3863
  e,
3864
3864
  t[i + 1]
3865
3865
  ) : e[t[i]] = t[i + 1];
3866
3866
  }
3867
- class rt {
3867
+ class st {
3868
3868
  /**
3869
3869
  * @param {Options} options Options.
3870
3870
  */
@@ -3878,7 +3878,7 @@ class rt {
3878
3878
  */
3879
3879
  clone() {
3880
3880
  const e = this.getScale();
3881
- return new rt({
3881
+ return new st({
3882
3882
  opacity: this.getOpacity(),
3883
3883
  scale: Array.isArray(e) ? e.slice() : e,
3884
3884
  rotation: this.getRotation(),
@@ -4078,7 +4078,7 @@ class rt {
4078
4078
  return Promise.resolve();
4079
4079
  }
4080
4080
  }
4081
- class at extends rt {
4081
+ class at extends st {
4082
4082
  /**
4083
4083
  * @param {Options} options Options.
4084
4084
  */
@@ -4170,20 +4170,20 @@ class at extends rt {
4170
4170
  */
4171
4171
  getImage(e) {
4172
4172
  const t = this.fill_?.getKey(), i = `${e},${this.angle_},${this.radius},${this.radius2_},${this.points_},${t}` + Object.values(this.renderOptions_).join(",");
4173
- let s = (
4173
+ let r = (
4174
4174
  /** @type {HTMLCanvasElement|OffscreenCanvas} */
4175
4175
  W.get(i, null, null)?.getImage(1)
4176
4176
  );
4177
- if (!s) {
4178
- const r = this.renderOptions_, a = Math.ceil(r.size * e), o = he(a, a);
4179
- this.draw_(r, o, e), s = o.canvas, W.set(
4177
+ if (!r) {
4178
+ const s = this.renderOptions_, a = Math.ceil(s.size * e), o = he(a, a);
4179
+ this.draw_(s, o, e), r = o.canvas, W.set(
4180
4180
  i,
4181
4181
  null,
4182
4182
  null,
4183
- new Ai(s, void 0, null, E.LOADED, null)
4183
+ new Ai(r, void 0, null, E.LOADED, null)
4184
4184
  );
4185
4185
  }
4186
- return s;
4186
+ return r;
4187
4187
  }
4188
4188
  /**
4189
4189
  * Get the image pixel ratio.
@@ -4295,20 +4295,20 @@ class at extends rt {
4295
4295
  calculateLineJoinSize_(e, t, i) {
4296
4296
  if (t === 0 || this.points_ === 1 / 0 || e !== "bevel" && e !== "miter")
4297
4297
  return t;
4298
- let s = this.radius, r = this.radius2_ === void 0 ? s : this.radius2_;
4299
- if (s < r) {
4300
- const P = s;
4301
- s = r, r = P;
4298
+ let r = this.radius, s = this.radius2_ === void 0 ? r : this.radius2_;
4299
+ if (r < s) {
4300
+ const P = r;
4301
+ r = s, s = P;
4302
4302
  }
4303
- const a = this.radius2_ === void 0 ? this.points_ : this.points_ * 2, o = 2 * Math.PI / a, l = r * Math.sin(o), h = Math.sqrt(r * r - l * l), c = s - h, d = Math.sqrt(l * l + c * c), f = d / l;
4303
+ const a = this.radius2_ === void 0 ? this.points_ : this.points_ * 2, o = 2 * Math.PI / a, l = s * Math.sin(o), h = Math.sqrt(s * s - l * l), c = r - h, d = Math.sqrt(l * l + c * c), f = d / l;
4304
4304
  if (e === "miter" && f <= i)
4305
4305
  return f * t;
4306
- const y = t / 2 / f, v = t / 2 * (c / d), R = Math.sqrt((s + y) * (s + y) + v * v) - s;
4306
+ const y = t / 2 / f, v = t / 2 * (c / d), R = Math.sqrt((r + y) * (r + y) + v * v) - r;
4307
4307
  if (this.radius2_ === void 0 || e === "bevel")
4308
4308
  return R * 2;
4309
- const L = s * Math.sin(o), X = Math.sqrt(s * s - L * L), q = r - X, x = Math.sqrt(L * L + q * q) / L;
4309
+ const L = r * Math.sin(o), X = Math.sqrt(r * r - L * L), q = s - X, x = Math.sqrt(L * L + q * q) / L;
4310
4310
  if (x <= i) {
4311
- const P = x * t / 2 - r - s;
4311
+ const P = x * t / 2 - s - r;
4312
4312
  return 2 * Math.max(R, P);
4313
4313
  }
4314
4314
  return R * 2;
@@ -4318,16 +4318,16 @@ class at extends rt {
4318
4318
  * @protected
4319
4319
  */
4320
4320
  createRenderOptions() {
4321
- let e = qt, t = Zt, i = 0, s = null, r = 0, a, o = 0;
4322
- this.stroke_ && (a = $t(this.stroke_.getColor() ?? Ls), o = this.stroke_.getWidth() ?? As, s = this.stroke_.getLineDash(), r = this.stroke_.getLineDashOffset() ?? 0, t = this.stroke_.getLineJoin() ?? Zt, e = this.stroke_.getLineCap() ?? qt, i = this.stroke_.getMiterLimit() ?? Cs);
4321
+ let e = qt, t = Zt, i = 0, r = null, s = 0, a, o = 0;
4322
+ this.stroke_ && (a = $t(this.stroke_.getColor() ?? Lr), o = this.stroke_.getWidth() ?? Ar, r = this.stroke_.getLineDash(), s = this.stroke_.getLineDashOffset() ?? 0, t = this.stroke_.getLineJoin() ?? Zt, e = this.stroke_.getLineCap() ?? qt, i = this.stroke_.getMiterLimit() ?? Cr);
4323
4323
  const l = this.calculateLineJoinSize_(t, o, i), h = Math.max(this.radius, this.radius2_ || 0), c = Math.ceil(2 * h + l);
4324
4324
  return {
4325
4325
  strokeStyle: a,
4326
4326
  strokeWidth: o,
4327
4327
  size: c,
4328
4328
  lineCap: e,
4329
- lineDash: s,
4330
- lineDashOffset: r,
4329
+ lineDash: r,
4330
+ lineDashOffset: s,
4331
4331
  lineJoin: t,
4332
4332
  miterLimit: i
4333
4333
  };
@@ -4348,8 +4348,8 @@ class at extends rt {
4348
4348
  */
4349
4349
  draw_(e, t, i) {
4350
4350
  if (t.scale(i, i), t.translate(e.size / 2, e.size / 2), this.createPath_(t), this.fill_) {
4351
- let s = this.fill_.getColor();
4352
- s === null && (s = Xt), t.fillStyle = $t(s), t.fill();
4351
+ let r = this.fill_.getColor();
4352
+ r === null && (r = Xt), t.fillStyle = $t(r), t.fill();
4353
4353
  }
4354
4354
  e.strokeStyle && (t.strokeStyle = e.strokeStyle, t.lineWidth = e.strokeWidth, e.lineDash && (t.setLineDash(e.lineDash), t.lineDashOffset = e.lineDashOffset), t.lineCap = e.lineCap, t.lineJoin = e.lineJoin, t.miterLimit = e.miterLimit, t.stroke());
4355
4355
  }
@@ -4361,8 +4361,8 @@ class at extends rt {
4361
4361
  createHitDetectionCanvas_(e) {
4362
4362
  let t;
4363
4363
  if (this.fill_) {
4364
- let i = this.fill_.getColor(), s = 0;
4365
- typeof i == "string" && (i = st(i)), i === null ? s = 1 : Array.isArray(i) && (s = i.length === 4 ? i[3] : 1), s === 0 && (t = he(e.size, e.size), this.drawHitDetectionCanvas_(e, t));
4364
+ let i = this.fill_.getColor(), r = 0;
4365
+ typeof i == "string" && (i = rt(i)), i === null ? r = 1 : Array.isArray(i) && (r = i.length === 4 ? i[3] : 1), r === 0 && (t = he(e.size, e.size), this.drawHitDetectionCanvas_(e, t));
4366
4366
  }
4367
4367
  return t ? t.canvas : this.getImage(1);
4368
4368
  }
@@ -4376,11 +4376,11 @@ class at extends rt {
4376
4376
  if (t === 1 / 0)
4377
4377
  e.arc(0, 0, i, 0, 2 * Math.PI);
4378
4378
  else {
4379
- const s = this.radius2_ === void 0 ? i : this.radius2_;
4379
+ const r = this.radius2_ === void 0 ? i : this.radius2_;
4380
4380
  this.radius2_ !== void 0 && (t *= 2);
4381
- const r = this.angle_ - Math.PI / 2, a = 2 * Math.PI / t;
4381
+ const s = this.angle_ - Math.PI / 2, a = 2 * Math.PI / t;
4382
4382
  for (let o = 0; o < t; o++) {
4383
- const l = r + o * a, h = o % 2 === 0 ? i : s;
4383
+ const l = s + o * a, h = o % 2 === 0 ? i : r;
4384
4384
  e.lineTo(h * Math.cos(l), h * Math.sin(l));
4385
4385
  }
4386
4386
  e.closePath();
@@ -4500,7 +4500,7 @@ class ne {
4500
4500
  */
4501
4501
  getKey() {
4502
4502
  const e = this.getColor();
4503
- return e ? e instanceof CanvasPattern || e instanceof CanvasGradient ? Se(e) : typeof e == "object" && "src" in e ? e.src + ":" + e.offset : st(e).toString() : "";
4503
+ return e ? e instanceof CanvasPattern || e instanceof CanvasGradient ? Se(e) : typeof e == "object" && "src" in e ? e.src + ":" + e.offset : rt(e).toString() : "";
4504
4504
  }
4505
4505
  /**
4506
4506
  * @return {boolean} The fill style is loading an image pattern.
@@ -4518,19 +4518,19 @@ class ne {
4518
4518
  function Jt(n, e, t, i) {
4519
4519
  return t !== void 0 && i !== void 0 ? [t / n, i / e] : t !== void 0 ? t / n : i !== void 0 ? i / e : 1;
4520
4520
  }
4521
- class Rt extends rt {
4521
+ class Rt extends st {
4522
4522
  /**
4523
4523
  * @param {Options} [options] Options.
4524
4524
  */
4525
4525
  constructor(e) {
4526
4526
  e = e || {};
4527
- const t = e.opacity !== void 0 ? e.opacity : 1, i = e.rotation !== void 0 ? e.rotation : 0, s = e.scale !== void 0 ? e.scale : 1, r = e.rotateWithView !== void 0 ? e.rotateWithView : !1;
4527
+ const t = e.opacity !== void 0 ? e.opacity : 1, i = e.rotation !== void 0 ? e.rotation : 0, r = e.scale !== void 0 ? e.scale : 1, s = e.rotateWithView !== void 0 ? e.rotateWithView : !1;
4528
4528
  super({
4529
4529
  opacity: t,
4530
4530
  rotation: i,
4531
- scale: s,
4531
+ scale: r,
4532
4532
  displacement: e.displacement !== void 0 ? e.displacement : [0, 0],
4533
- rotateWithView: r,
4533
+ rotateWithView: s,
4534
4534
  declutterMode: e.declutterMode
4535
4535
  }), this.anchor_ = e.anchor !== void 0 ? e.anchor : [0.5, 0.5], this.normalizedAnchor_ = null, this.anchorOrigin_ = e.anchorOrigin !== void 0 ? e.anchorOrigin : "top-left", this.anchorXUnits_ = e.anchorXUnits !== void 0 ? e.anchorXUnits : "fraction", this.anchorYUnits_ = e.anchorYUnits !== void 0 ? e.anchorYUnits : "fraction", this.crossOrigin_ = e.crossOrigin !== void 0 ? e.crossOrigin : null;
4536
4536
  const a = e.img !== void 0 ? e.img : null;
@@ -4547,7 +4547,7 @@ class Rt extends rt {
4547
4547
  "`width` or `height` cannot be provided together with `scale`"
4548
4548
  );
4549
4549
  let l;
4550
- if (e.src !== void 0 ? l = E.IDLE : a !== void 0 && ("complete" in a ? a.complete ? l = a.src ? E.LOADED : E.IDLE : l = E.LOADING : l = E.LOADED), this.color_ = e.color !== void 0 ? st(e.color) : null, this.iconImage_ = Je(
4550
+ if (e.src !== void 0 ? l = E.IDLE : a !== void 0 && ("complete" in a ? a.complete ? l = a.src ? E.LOADED : E.IDLE : l = E.LOADING : l = E.LOADED), this.color_ = e.color !== void 0 ? rt(e.color) : null, this.iconImage_ = Je(
4551
4551
  a,
4552
4552
  /** @type {string} */
4553
4553
  o,
@@ -4626,16 +4626,16 @@ class Rt extends rt {
4626
4626
  let e = this.normalizedAnchor_;
4627
4627
  if (!e) {
4628
4628
  e = this.anchor_;
4629
- const s = this.getSize();
4629
+ const r = this.getSize();
4630
4630
  if (this.anchorXUnits_ == "fraction" || this.anchorYUnits_ == "fraction") {
4631
- if (!s)
4631
+ if (!r)
4632
4632
  return null;
4633
- e = this.anchor_.slice(), this.anchorXUnits_ == "fraction" && (e[0] *= s[0]), this.anchorYUnits_ == "fraction" && (e[1] *= s[1]);
4633
+ e = this.anchor_.slice(), this.anchorXUnits_ == "fraction" && (e[0] *= r[0]), this.anchorYUnits_ == "fraction" && (e[1] *= r[1]);
4634
4634
  }
4635
4635
  if (this.anchorOrigin_ != "top-left") {
4636
- if (!s)
4636
+ if (!r)
4637
4637
  return null;
4638
- e === this.anchor_ && (e = this.anchor_.slice()), (this.anchorOrigin_ == "top-right" || this.anchorOrigin_ == "bottom-right") && (e[0] = -e[0] + s[0]), (this.anchorOrigin_ == "bottom-left" || this.anchorOrigin_ == "bottom-right") && (e[1] = -e[1] + s[1]);
4638
+ e === this.anchor_ && (e = this.anchor_.slice()), (this.anchorOrigin_ == "top-right" || this.anchorOrigin_ == "bottom-right") && (e[0] = -e[0] + r[0]), (this.anchorOrigin_ == "bottom-left" || this.anchorOrigin_ == "bottom-right") && (e[1] = -e[1] + r[1]);
4639
4639
  }
4640
4640
  this.normalizedAnchor_ = e;
4641
4641
  }
@@ -5147,7 +5147,7 @@ class U {
5147
5147
  this.zIndex_ = e;
5148
5148
  }
5149
5149
  }
5150
- function Rs(n) {
5150
+ function Rr(n) {
5151
5151
  let e;
5152
5152
  if (typeof n == "function")
5153
5153
  e = n;
@@ -5189,7 +5189,7 @@ function Di(n, e) {
5189
5189
  }
5190
5190
  return _t;
5191
5191
  }
5192
- function Er() {
5192
+ function Es() {
5193
5193
  const n = {}, e = [255, 255, 255, 1], t = [0, 153, 255, 1], i = 3;
5194
5194
  return n.Polygon = [
5195
5195
  new U({
@@ -5232,13 +5232,13 @@ function Er() {
5232
5232
  function Qt(n) {
5233
5233
  return n.getGeometry();
5234
5234
  }
5235
- const xs = "#333";
5235
+ const xr = "#333";
5236
5236
  class xt {
5237
5237
  /**
5238
5238
  * @param {Options} [options] Options.
5239
5239
  */
5240
5240
  constructor(e) {
5241
- e = e || {}, this.font_ = e.font, this.rotation_ = e.rotation, this.rotateWithView_ = e.rotateWithView, this.keepUpright_ = e.keepUpright, this.scale_ = e.scale, this.scaleArray_ = we(e.scale !== void 0 ? e.scale : 1), this.text_ = e.text, this.textAlign_ = e.textAlign, this.justify_ = e.justify, this.repeat_ = e.repeat, this.textBaseline_ = e.textBaseline, this.fill_ = e.fill !== void 0 ? e.fill : new ne({ color: xs }), this.maxAngle_ = e.maxAngle !== void 0 ? e.maxAngle : Math.PI / 4, this.placement_ = e.placement !== void 0 ? e.placement : "point", this.overflow_ = !!e.overflow, this.stroke_ = e.stroke !== void 0 ? e.stroke : null, this.offsetX_ = e.offsetX !== void 0 ? e.offsetX : 0, this.offsetY_ = e.offsetY !== void 0 ? e.offsetY : 0, this.backgroundFill_ = e.backgroundFill ? e.backgroundFill : null, this.backgroundStroke_ = e.backgroundStroke ? e.backgroundStroke : null, this.padding_ = e.padding === void 0 ? null : e.padding, this.declutterMode_ = e.declutterMode;
5241
+ e = e || {}, this.font_ = e.font, this.rotation_ = e.rotation, this.rotateWithView_ = e.rotateWithView, this.keepUpright_ = e.keepUpright, this.scale_ = e.scale, this.scaleArray_ = we(e.scale !== void 0 ? e.scale : 1), this.text_ = e.text, this.textAlign_ = e.textAlign, this.justify_ = e.justify, this.repeat_ = e.repeat, this.textBaseline_ = e.textBaseline, this.fill_ = e.fill !== void 0 ? e.fill : new ne({ color: xr }), this.maxAngle_ = e.maxAngle !== void 0 ? e.maxAngle : Math.PI / 4, this.placement_ = e.placement !== void 0 ? e.placement : "point", this.overflow_ = !!e.overflow, this.stroke_ = e.stroke !== void 0 ? e.stroke : null, this.offsetX_ = e.offsetX !== void 0 ? e.offsetX : 0, this.offsetY_ = e.offsetY !== void 0 ? e.offsetY : 0, this.backgroundFill_ = e.backgroundFill ? e.backgroundFill : null, this.backgroundStroke_ = e.backgroundStroke ? e.backgroundStroke : null, this.padding_ = e.padding === void 0 ? null : e.padding, this.declutterMode_ = e.declutterMode;
5242
5242
  }
5243
5243
  /**
5244
5244
  * Clones the style.
@@ -5626,18 +5626,18 @@ class xt {
5626
5626
  this.padding_ = e;
5627
5627
  }
5628
5628
  }
5629
- function Ps(n) {
5629
+ function Pr(n) {
5630
5630
  return !0;
5631
5631
  }
5632
- function Os(n) {
5633
- const e = vi(), t = Ms(n, e), i = Li();
5634
- return function(s, r) {
5635
- if (i.properties = s.getPropertiesInternal(), i.resolution = r, e.featureId) {
5636
- const a = s.getId();
5632
+ function Or(n) {
5633
+ const e = vi(), t = Mr(n, e), i = Li();
5634
+ return function(r, s) {
5635
+ if (i.properties = r.getPropertiesInternal(), i.resolution = s, e.featureId) {
5636
+ const a = r.getId();
5637
5637
  a !== void 0 ? i.featureId = a : i.featureId = null;
5638
5638
  }
5639
5639
  return e.geometryType && (i.geometryType = Ci(
5640
- s.getGeometry()
5640
+ r.getGeometry()
5641
5641
  )), t(i);
5642
5642
  };
5643
5643
  }
@@ -5645,53 +5645,53 @@ function ei(n) {
5645
5645
  const e = vi(), t = n.length, i = new Array(t);
5646
5646
  for (let a = 0; a < t; ++a)
5647
5647
  i[a] = wt(n[a], e);
5648
- const s = Li(), r = new Array(t);
5648
+ const r = Li(), s = new Array(t);
5649
5649
  return function(a, o) {
5650
- if (s.properties = a.getPropertiesInternal(), s.resolution = o, e.featureId) {
5650
+ if (r.properties = a.getPropertiesInternal(), r.resolution = o, e.featureId) {
5651
5651
  const h = a.getId();
5652
- h !== void 0 ? s.featureId = h : s.featureId = null;
5652
+ h !== void 0 ? r.featureId = h : r.featureId = null;
5653
5653
  }
5654
5654
  let l = 0;
5655
5655
  for (let h = 0; h < t; ++h) {
5656
- const c = i[h](s);
5657
- c && (r[l] = c, l += 1);
5656
+ const c = i[h](r);
5657
+ c && (s[l] = c, l += 1);
5658
5658
  }
5659
- return r.length = l, r;
5659
+ return s.length = l, s;
5660
5660
  };
5661
5661
  }
5662
- function Ms(n, e) {
5662
+ function Mr(n, e) {
5663
5663
  const t = n.length, i = new Array(t);
5664
- for (let s = 0; s < t; ++s) {
5665
- const r = n[s], a = "filter" in r ? J(r.filter, N, e) : Ps;
5664
+ for (let r = 0; r < t; ++r) {
5665
+ const s = n[r], a = "filter" in s ? J(s.filter, N, e) : Pr;
5666
5666
  let o;
5667
- if (Array.isArray(r.style)) {
5668
- const l = r.style.length;
5667
+ if (Array.isArray(s.style)) {
5668
+ const l = s.style.length;
5669
5669
  o = new Array(l);
5670
5670
  for (let h = 0; h < l; ++h)
5671
- o[h] = wt(r.style[h], e);
5671
+ o[h] = wt(s.style[h], e);
5672
5672
  } else
5673
- o = [wt(r.style, e)];
5674
- i[s] = { filter: a, styles: o };
5673
+ o = [wt(s.style, e)];
5674
+ i[r] = { filter: a, styles: o };
5675
5675
  }
5676
- return function(s) {
5677
- const r = [];
5676
+ return function(r) {
5677
+ const s = [];
5678
5678
  let a = !1;
5679
5679
  for (let o = 0; o < t; ++o) {
5680
5680
  const l = i[o].filter;
5681
- if (l(s) && !(n[o].else && a)) {
5681
+ if (l(r) && !(n[o].else && a)) {
5682
5682
  a = !0;
5683
5683
  for (const h of i[o].styles) {
5684
- const c = h(s);
5685
- c && r.push(c);
5684
+ const c = h(r);
5685
+ c && s.push(c);
5686
5686
  }
5687
5687
  }
5688
5688
  }
5689
- return r;
5689
+ return s;
5690
5690
  };
5691
5691
  }
5692
5692
  function wt(n, e) {
5693
- const t = ke(n, "", e), i = Ne(n, "", e), s = Ss(n, e), r = ks(n, e), a = F(n, "z-index", e);
5694
- if (!t && !i && !s && !r && !Ki(n))
5693
+ const t = ke(n, "", e), i = Ne(n, "", e), r = Sr(n, e), s = kr(n, e), a = F(n, "z-index", e);
5694
+ if (!t && !i && !r && !s && !Ki(n))
5695
5695
  throw new Error(
5696
5696
  "No fill, stroke, point, or text symbolizer properties in style: " + JSON.stringify(n)
5697
5697
  );
@@ -5706,12 +5706,12 @@ function wt(n, e) {
5706
5706
  const c = i(l);
5707
5707
  c && (h = !1), o.setStroke(c);
5708
5708
  }
5709
- if (s) {
5710
- const c = s(l);
5711
- c && (h = !1), o.setText(c);
5712
- }
5713
5709
  if (r) {
5714
5710
  const c = r(l);
5711
+ c && (h = !1), o.setText(c);
5712
+ }
5713
+ if (s) {
5714
+ const c = s(l);
5715
5715
  c && (h = !1), o.setImage(c);
5716
5716
  }
5717
5717
  return a && o.setZIndex(a(l)), h ? null : o;
@@ -5720,10 +5720,10 @@ function wt(n, e) {
5720
5720
  function ke(n, e, t) {
5721
5721
  let i;
5722
5722
  if (e + "fill-pattern-src" in n)
5723
- i = Vs(n, e + "fill-", t);
5723
+ i = Vr(n, e + "fill-", t);
5724
5724
  else {
5725
5725
  if (n[e + "fill-color"] === "none")
5726
- return (r) => null;
5726
+ return (s) => null;
5727
5727
  i = Pt(
5728
5728
  n,
5729
5729
  e + "fill-color",
@@ -5732,10 +5732,10 @@ function ke(n, e, t) {
5732
5732
  }
5733
5733
  if (!i)
5734
5734
  return null;
5735
- const s = new ne();
5736
- return function(r) {
5737
- const a = i(r);
5738
- return a === gi ? null : (s.setColor(a), s);
5735
+ const r = new ne();
5736
+ return function(s) {
5737
+ const a = i(s);
5738
+ return a === gi ? null : (r.setColor(a), r);
5739
5739
  };
5740
5740
  }
5741
5741
  function Ne(n, e, t) {
@@ -5743,14 +5743,14 @@ function Ne(n, e, t) {
5743
5743
  n,
5744
5744
  e + "stroke-width",
5745
5745
  t
5746
- ), s = Pt(
5746
+ ), r = Pt(
5747
5747
  n,
5748
5748
  e + "stroke-color",
5749
5749
  t
5750
5750
  );
5751
- if (!i && !s)
5751
+ if (!i && !r)
5752
5752
  return null;
5753
- const r = Z(
5753
+ const s = Z(
5754
5754
  n,
5755
5755
  e + "stroke-line-cap",
5756
5756
  t
@@ -5772,14 +5772,14 @@ function Ne(n, e, t) {
5772
5772
  t
5773
5773
  ), c = new ce();
5774
5774
  return function(d) {
5775
- if (s) {
5776
- const f = s(d);
5775
+ if (r) {
5776
+ const f = r(d);
5777
5777
  if (f === gi)
5778
5778
  return null;
5779
5779
  c.setColor(f);
5780
5780
  }
5781
- if (i && c.setWidth(i(d)), r) {
5782
- const f = r(d);
5781
+ if (i && c.setWidth(i(d)), s) {
5782
+ const f = s(d);
5783
5783
  if (f !== "butt" && f !== "round" && f !== "square")
5784
5784
  throw new Error("Expected butt, round, or square line cap");
5785
5785
  c.setLineCap(f);
@@ -5793,11 +5793,11 @@ function Ne(n, e, t) {
5793
5793
  return o && c.setLineDash(o(d)), l && c.setLineDashOffset(l(d)), h && c.setMiterLimit(h(d)), c;
5794
5794
  };
5795
5795
  }
5796
- function Ss(n, e) {
5796
+ function Sr(n, e) {
5797
5797
  const t = "text-", i = Z(n, t + "value", e);
5798
5798
  if (!i)
5799
5799
  return null;
5800
- const s = ke(n, t, e), r = ke(
5800
+ const r = ke(n, t, e), s = ke(
5801
5801
  n,
5802
5802
  t + "background-",
5803
5803
  e
@@ -5854,7 +5854,7 @@ function Ss(n, e) {
5854
5854
  t + "declutter-mode"
5855
5855
  ), A = new xt({ declutterMode: k });
5856
5856
  return function(b) {
5857
- if (A.setText(i(b)), s && A.setFill(s(b)), r && A.setBackgroundFill(r(b)), a && A.setStroke(a(b)), o && A.setBackgroundStroke(o(b)), l && A.setFont(l(b)), h && A.setMaxAngle(h(b)), c && A.setOffsetX(c(b)), d && A.setOffsetY(d(b)), f && A.setOverflow(f(b)), y) {
5857
+ if (A.setText(i(b)), r && A.setFill(r(b)), s && A.setBackgroundFill(s(b)), a && A.setStroke(a(b)), o && A.setBackgroundStroke(o(b)), l && A.setFont(l(b)), h && A.setMaxAngle(h(b)), c && A.setOffsetX(c(b)), d && A.setOffsetY(d(b)), f && A.setOverflow(f(b)), y) {
5858
5858
  const C = y(b);
5859
5859
  if (C !== "point" && C !== "line")
5860
5860
  throw new Error("Expected point or line for text-placement");
@@ -5885,11 +5885,11 @@ function Ss(n, e) {
5885
5885
  return P && A.setPadding(P(b)), x && A.setKeepUpright(x(b)), A;
5886
5886
  };
5887
5887
  }
5888
- function ks(n, e) {
5889
- return "icon-src" in n ? Ns(n, e) : "shape-points" in n ? zs(n, e) : "circle-radius" in n ? Fs(n, e) : null;
5888
+ function kr(n, e) {
5889
+ return "icon-src" in n ? Nr(n, e) : "shape-points" in n ? zr(n, e) : "circle-radius" in n ? Fr(n, e) : null;
5890
5890
  }
5891
- function Ns(n, e) {
5892
- const t = "icon-", i = t + "src", s = Ri(n[i], i), r = Qe(
5891
+ function Nr(n, e) {
5892
+ const t = "icon-", i = t + "src", r = Ri(n[i], i), s = Qe(
5893
5893
  n,
5894
5894
  t + "anchor",
5895
5895
  e
@@ -5915,11 +5915,11 @@ function Ns(n, e) {
5915
5915
  ), y = ni(
5916
5916
  n,
5917
5917
  t + "anchor-y-units"
5918
- ), v = Ws(n, t + "color"), V = Bs(n, t + "cross-origin"), R = Gs(n, t + "offset"), L = ii(n, t + "offset-origin"), X = et(n, t + "width"), q = et(n, t + "height"), I = Ks(n, t + "size"), x = lt(
5918
+ ), v = Wr(n, t + "color"), V = Br(n, t + "cross-origin"), R = Gr(n, t + "offset"), L = ii(n, t + "offset-origin"), X = et(n, t + "width"), q = et(n, t + "height"), I = Kr(n, t + "size"), x = lt(
5919
5919
  n,
5920
5920
  t + "declutter-mode"
5921
5921
  ), P = new Rt({
5922
- src: s,
5922
+ src: r,
5923
5923
  anchorOrigin: d,
5924
5924
  anchorXUnits: f,
5925
5925
  anchorYUnits: y,
@@ -5933,11 +5933,11 @@ function Ns(n, e) {
5933
5933
  declutterMode: x
5934
5934
  });
5935
5935
  return function(k) {
5936
- return o && P.setOpacity(o(k)), l && P.setDisplacement(l(k)), h && P.setRotation(h(k)), c && P.setRotateWithView(c(k)), a && P.setScale(a(k)), r && P.setAnchor(r(k)), P;
5936
+ return o && P.setOpacity(o(k)), l && P.setDisplacement(l(k)), h && P.setRotation(h(k)), c && P.setRotateWithView(c(k)), a && P.setScale(a(k)), s && P.setAnchor(s(k)), P;
5937
5937
  };
5938
5938
  }
5939
- function zs(n, e) {
5940
- const t = "shape-", i = t + "points", s = t + "radius", r = vt(n[i], i), a = vt(n[s], s), o = ke(n, t, e), l = Ne(n, t, e), h = ot(n, t + "scale", e), c = Qe(
5939
+ function zr(n, e) {
5940
+ const t = "shape-", i = t + "points", r = t + "radius", s = vt(n[i], i), a = vt(n[r], r), o = ke(n, t, e), l = Ne(n, t, e), h = ot(n, t + "scale", e), c = Qe(
5941
5941
  n,
5942
5942
  t + "displacement",
5943
5943
  e
@@ -5953,7 +5953,7 @@ function zs(n, e) {
5953
5953
  n,
5954
5954
  t + "declutter-mode"
5955
5955
  ), R = new at({
5956
- points: r,
5956
+ points: s,
5957
5957
  radius: a,
5958
5958
  radius2: y,
5959
5959
  angle: v,
@@ -5963,8 +5963,8 @@ function zs(n, e) {
5963
5963
  return o && R.setFill(o(L)), l && R.setStroke(l(L)), c && R.setDisplacement(c(L)), d && R.setRotation(d(L)), f && R.setRotateWithView(f(L)), h && R.setScale(h(L)), R;
5964
5964
  };
5965
5965
  }
5966
- function Fs(n, e) {
5967
- const t = "circle-", i = ke(n, t, e), s = Ne(n, t, e), r = F(n, t + "radius", e), a = ot(n, t + "scale", e), o = Qe(
5966
+ function Fr(n, e) {
5967
+ const t = "circle-", i = ke(n, t, e), r = Ne(n, t, e), s = F(n, t + "radius", e), a = ot(n, t + "scale", e), o = Qe(
5968
5968
  n,
5969
5969
  t + "displacement",
5970
5970
  e
@@ -5985,35 +5985,35 @@ function Fs(n, e) {
5985
5985
  declutterMode: c
5986
5986
  });
5987
5987
  return function(f) {
5988
- return r && d.setRadius(r(f)), i && d.setFill(i(f)), s && d.setStroke(s(f)), o && d.setDisplacement(o(f)), l && d.setRotation(l(f)), h && d.setRotateWithView(h(f)), a && d.setScale(a(f)), d;
5988
+ return s && d.setRadius(s(f)), i && d.setFill(i(f)), r && d.setStroke(r(f)), o && d.setDisplacement(o(f)), l && d.setRotation(l(f)), h && d.setRotateWithView(h(f)), a && d.setScale(a(f)), d;
5989
5989
  };
5990
5990
  }
5991
5991
  function F(n, e, t) {
5992
5992
  if (!(e in n))
5993
5993
  return;
5994
5994
  const i = J(n[e], m, t);
5995
- return function(s) {
5996
- return vt(i(s), e);
5995
+ return function(r) {
5996
+ return vt(i(r), e);
5997
5997
  };
5998
5998
  }
5999
5999
  function Z(n, e, t) {
6000
6000
  if (!(e in n))
6001
6001
  return null;
6002
6002
  const i = J(n[e], z, t);
6003
- return function(s) {
6004
- return Ri(i(s), e);
6003
+ return function(r) {
6004
+ return Ri(i(r), e);
6005
6005
  };
6006
6006
  }
6007
- function Vs(n, e, t) {
6007
+ function Vr(n, e, t) {
6008
6008
  const i = Z(
6009
6009
  n,
6010
6010
  e + "pattern-src",
6011
6011
  t
6012
- ), s = ti(
6012
+ ), r = ti(
6013
6013
  n,
6014
6014
  e + "pattern-offset",
6015
6015
  t
6016
- ), r = ti(
6016
+ ), s = ti(
6017
6017
  n,
6018
6018
  e + "pattern-size",
6019
6019
  t
@@ -6025,8 +6025,8 @@ function Vs(n, e, t) {
6025
6025
  return function(o) {
6026
6026
  return {
6027
6027
  src: i(o),
6028
- offset: s && s(o),
6029
- size: r && r(o),
6028
+ offset: r && r(o),
6029
+ size: s && s(o),
6030
6030
  color: a && a(o)
6031
6031
  };
6032
6032
  };
@@ -6035,46 +6035,46 @@ function Ee(n, e, t) {
6035
6035
  if (!(e in n))
6036
6036
  return null;
6037
6037
  const i = J(n[e], N, t);
6038
- return function(s) {
6039
- const r = i(s);
6040
- if (typeof r != "boolean")
6038
+ return function(r) {
6039
+ const s = i(r);
6040
+ if (typeof s != "boolean")
6041
6041
  throw new Error(`Expected a boolean for ${e}`);
6042
- return r;
6042
+ return s;
6043
6043
  };
6044
6044
  }
6045
6045
  function Pt(n, e, t) {
6046
6046
  if (!(e in n))
6047
6047
  return null;
6048
6048
  const i = J(n[e], H, t);
6049
- return function(s) {
6050
- return xi(i(s), e);
6049
+ return function(r) {
6050
+ return xi(i(r), e);
6051
6051
  };
6052
6052
  }
6053
6053
  function Ti(n, e, t) {
6054
6054
  if (!(e in n))
6055
6055
  return null;
6056
6056
  const i = J(n[e], ue, t);
6057
- return function(s) {
6058
- return Ge(i(s), e);
6057
+ return function(r) {
6058
+ return Ge(i(r), e);
6059
6059
  };
6060
6060
  }
6061
6061
  function Qe(n, e, t) {
6062
6062
  if (!(e in n))
6063
6063
  return null;
6064
6064
  const i = J(n[e], ue, t);
6065
- return function(s) {
6066
- const r = Ge(i(s), e);
6067
- if (r.length !== 2)
6065
+ return function(r) {
6066
+ const s = Ge(i(r), e);
6067
+ if (s.length !== 2)
6068
6068
  throw new Error(`Expected two numbers for ${e}`);
6069
- return r;
6069
+ return s;
6070
6070
  };
6071
6071
  }
6072
6072
  function ti(n, e, t) {
6073
6073
  if (!(e in n))
6074
6074
  return null;
6075
6075
  const i = J(n[e], ue, t);
6076
- return function(s) {
6077
- return Pi(i(s), e);
6076
+ return function(r) {
6077
+ return Pi(i(r), e);
6078
6078
  };
6079
6079
  }
6080
6080
  function ot(n, e, t) {
@@ -6085,8 +6085,8 @@ function ot(n, e, t) {
6085
6085
  ue | m,
6086
6086
  t
6087
6087
  );
6088
- return function(s) {
6089
- return Hs(i(s), e);
6088
+ return function(r) {
6089
+ return Hr(i(r), e);
6090
6090
  };
6091
6091
  }
6092
6092
  function et(n, e) {
@@ -6097,7 +6097,7 @@ function et(n, e) {
6097
6097
  return t;
6098
6098
  }
6099
6099
  }
6100
- function Ks(n, e) {
6100
+ function Kr(n, e) {
6101
6101
  const t = n[e];
6102
6102
  if (t !== void 0) {
6103
6103
  if (typeof t == "number")
@@ -6109,7 +6109,7 @@ function Ks(n, e) {
6109
6109
  return t;
6110
6110
  }
6111
6111
  }
6112
- function Bs(n, e) {
6112
+ function Br(n, e) {
6113
6113
  const t = n[e];
6114
6114
  if (t !== void 0) {
6115
6115
  if (typeof t != "string")
@@ -6135,7 +6135,7 @@ function ni(n, e) {
6135
6135
  return t;
6136
6136
  }
6137
6137
  }
6138
- function Gs(n, e) {
6138
+ function Gr(n, e) {
6139
6139
  const t = n[e];
6140
6140
  if (t !== void 0)
6141
6141
  return Ge(t, e);
@@ -6150,7 +6150,7 @@ function lt(n, e) {
6150
6150
  return t;
6151
6151
  }
6152
6152
  }
6153
- function Ws(n, e) {
6153
+ function Wr(n, e) {
6154
6154
  const t = n[e];
6155
6155
  if (t !== void 0)
6156
6156
  return xi(t, e);
@@ -6188,13 +6188,13 @@ function Pi(n, e) {
6188
6188
  throw new Error(`Expected an array of two numbers for ${e}`);
6189
6189
  return t;
6190
6190
  }
6191
- function Hs(n, e) {
6191
+ function Hr(n, e) {
6192
6192
  return typeof n == "number" ? n : Pi(n, e);
6193
6193
  }
6194
- const si = {
6194
+ const ri = {
6195
6195
  RENDER_ORDER: "renderOrder"
6196
6196
  };
6197
- class Ys extends It {
6197
+ class Yr extends It {
6198
6198
  /**
6199
6199
  * @param {Options<FeatureType, VectorSourceType>} [options] Options.
6200
6200
  */
@@ -6240,7 +6240,7 @@ class Ys extends It {
6240
6240
  getRenderOrder() {
6241
6241
  return (
6242
6242
  /** @type {import("../render.js").OrderFunction|null|undefined} */
6243
- this.get(si.RENDER_ORDER)
6243
+ this.get(ri.RENDER_ORDER)
6244
6244
  );
6245
6245
  }
6246
6246
  /**
@@ -6289,7 +6289,7 @@ class Ys extends It {
6289
6289
  * Render order.
6290
6290
  */
6291
6291
  setRenderOrder(e) {
6292
- this.set(si.RENDER_ORDER, e);
6292
+ this.set(ri.RENDER_ORDER, e);
6293
6293
  }
6294
6294
  /**
6295
6295
  * Set the style for features. This can be a single style object, an array
@@ -6314,8 +6314,8 @@ class Ys extends It {
6314
6314
  */
6315
6315
  setStyle(e) {
6316
6316
  this.style_ = e === void 0 ? Di : e;
6317
- const t = Us(e);
6318
- this.styleFunction_ = e === null ? void 0 : Rs(t), this.changed();
6317
+ const t = Ur(e);
6318
+ this.styleFunction_ = e === null ? void 0 : Rr(t), this.changed();
6319
6319
  }
6320
6320
  /**
6321
6321
  * @param {boolean|string|number} declutter Declutter images and text.
@@ -6325,7 +6325,7 @@ class Ys extends It {
6325
6325
  this.declutter_ = e ? String(e) : void 0, this.changed();
6326
6326
  }
6327
6327
  }
6328
- function Us(n) {
6328
+ function Ur(n) {
6329
6329
  if (n === void 0)
6330
6330
  return Di;
6331
6331
  if (!n)
@@ -6338,31 +6338,31 @@ function Us(n) {
6338
6338
  return [];
6339
6339
  const e = n.length, t = n[0];
6340
6340
  if (t instanceof U) {
6341
- const s = new Array(e);
6342
- for (let r = 0; r < e; ++r) {
6343
- const a = n[r];
6341
+ const r = new Array(e);
6342
+ for (let s = 0; s < e; ++s) {
6343
+ const a = n[s];
6344
6344
  if (!(a instanceof U))
6345
6345
  throw new Error("Expected a list of style instances");
6346
- s[r] = a;
6346
+ r[s] = a;
6347
6347
  }
6348
- return s;
6348
+ return r;
6349
6349
  }
6350
6350
  if ("style" in t) {
6351
- const s = new Array(e);
6352
- for (let r = 0; r < e; ++r) {
6353
- const a = n[r];
6351
+ const r = new Array(e);
6352
+ for (let s = 0; s < e; ++s) {
6353
+ const a = n[s];
6354
6354
  if (!("style" in a))
6355
6355
  throw new Error("Expected a list of rules with a style property");
6356
- s[r] = a;
6356
+ r[s] = a;
6357
6357
  }
6358
- return Os(s);
6358
+ return Or(r);
6359
6359
  }
6360
6360
  return ei(
6361
6361
  /** @type {Array<import("../style/flat.js").FlatStyle>} */
6362
6362
  n
6363
6363
  );
6364
6364
  }
6365
- class $s extends li {
6365
+ class $r extends li {
6366
6366
  /**
6367
6367
  * @param {import("../Map.js").default} map Map.
6368
6368
  */
@@ -6382,8 +6382,8 @@ class $s extends li {
6382
6382
  * @protected
6383
6383
  */
6384
6384
  calculateMatrices2D(e) {
6385
- const t = e.viewState, i = e.coordinateToPixelTransform, s = e.pixelToCoordinateTransform;
6386
- sn(
6385
+ const t = e.viewState, i = e.coordinateToPixelTransform, r = e.pixelToCoordinateTransform;
6386
+ rn(
6387
6387
  i,
6388
6388
  e.size[0] / 2,
6389
6389
  e.size[1] / 2,
@@ -6392,7 +6392,7 @@ class $s extends li {
6392
6392
  -t.rotation,
6393
6393
  -t.center[0],
6394
6394
  -t.center[1]
6395
- ), rn(s, i);
6395
+ ), sn(r, i);
6396
6396
  }
6397
6397
  /**
6398
6398
  * @param {import("../coordinate.js").Coordinate} coordinate Coordinate.
@@ -6409,14 +6409,14 @@ class $s extends li {
6409
6409
  * @return {T|undefined} Callback result.
6410
6410
  * @template S,T,U
6411
6411
  */
6412
- forEachFeatureAtCoordinate(e, t, i, s, r, a, o, l) {
6412
+ forEachFeatureAtCoordinate(e, t, i, r, s, a, o, l) {
6413
6413
  let h;
6414
6414
  const c = t.viewState;
6415
6415
  function d(I, x, P, k) {
6416
- return r.call(a, x, I ? P : null, k);
6416
+ return s.call(a, x, I ? P : null, k);
6417
6417
  }
6418
6418
  const f = c.projection, y = Bi(e.slice(), f), v = [[0, 0]];
6419
- if (f.canWrapX() && s) {
6419
+ if (f.canWrapX() && r) {
6420
6420
  const I = f.getExtent(), x = Gi(I);
6421
6421
  v.push([-x, 0], [x, 0]);
6422
6422
  }
@@ -6464,15 +6464,15 @@ class $s extends li {
6464
6464
  * @return {boolean} Is there a feature at the given coordinate?
6465
6465
  * @template U
6466
6466
  */
6467
- hasFeatureAtCoordinate(e, t, i, s, r, a) {
6467
+ hasFeatureAtCoordinate(e, t, i, r, s, a) {
6468
6468
  return this.forEachFeatureAtCoordinate(
6469
6469
  e,
6470
6470
  t,
6471
6471
  i,
6472
- s,
6472
+ r,
6473
6473
  qe,
6474
6474
  this,
6475
- r,
6475
+ s,
6476
6476
  a
6477
6477
  ) !== void 0;
6478
6478
  }
@@ -6495,13 +6495,13 @@ class $s extends li {
6495
6495
  * @protected
6496
6496
  */
6497
6497
  scheduleExpireIconCache(e) {
6498
- W.canExpireCache() && e.postRenderFunctions.push(Xs);
6498
+ W.canExpireCache() && e.postRenderFunctions.push(Xr);
6499
6499
  }
6500
6500
  }
6501
- function Xs(n, e) {
6501
+ function Xr(n, e) {
6502
6502
  W.expire();
6503
6503
  }
6504
- class qs extends $s {
6504
+ class qr extends $r {
6505
6505
  /**
6506
6506
  * @param {import("../Map.js").default} map Map.
6507
6507
  */
@@ -6525,8 +6525,8 @@ class qs extends $s {
6525
6525
  dispatchRenderEvent(e, t) {
6526
6526
  const i = this.getMap();
6527
6527
  if (i.hasListener(e)) {
6528
- const s = new dn(e, void 0, t);
6529
- i.dispatchEvent(s);
6528
+ const r = new dn(e, void 0, t);
6529
+ i.dispatchEvent(r);
6530
6530
  }
6531
6531
  }
6532
6532
  /**
@@ -6550,24 +6550,24 @@ class qs extends $s {
6550
6550
  (h, c) => h.zIndex - c.zIndex
6551
6551
  );
6552
6552
  t.some(
6553
- (h) => h.layer instanceof Ys && h.layer.getDeclutter()
6553
+ (h) => h.layer instanceof Yr && h.layer.getDeclutter()
6554
6554
  ) && (e.declutter = {});
6555
- const s = e.viewState;
6555
+ const r = e.viewState;
6556
6556
  this.children_.length = 0;
6557
- const r = [];
6557
+ const s = [];
6558
6558
  let a = null;
6559
6559
  for (let h = 0, c = t.length; h < c; ++h) {
6560
6560
  const d = t[h];
6561
6561
  e.layerIndex = h;
6562
6562
  const f = d.layer, y = f.getSourceState();
6563
- if (!_i(d, s) || y != "ready" && y != "undefined") {
6563
+ if (!_i(d, r) || y != "ready" && y != "undefined") {
6564
6564
  f.unrender();
6565
6565
  continue;
6566
6566
  }
6567
6567
  const v = f.render(e, a);
6568
- v && (v !== a && (this.children_.push(v), a = v), r.push(d));
6568
+ v && (v !== a && (this.children_.push(v), a = v), s.push(d));
6569
6569
  }
6570
- this.declutter(e, r), Qi(this.element_, this.children_);
6570
+ this.declutter(e, s), Qi(this.element_, this.children_);
6571
6571
  const l = this.getMap().getTargetElement();
6572
6572
  if (le(l)) {
6573
6573
  const h = l.getContext("2d");
@@ -6600,8 +6600,8 @@ class qs extends $s {
6600
6600
  declutter(e, t) {
6601
6601
  if (e.declutter) {
6602
6602
  for (let i = t.length - 1; i >= 0; --i) {
6603
- const s = t[i], r = s.layer;
6604
- r.getDeclutter() && r.renderDeclutter(e, s);
6603
+ const r = t[i], s = r.layer;
6604
+ s.getDeclutter() && s.renderDeclutter(e, r);
6605
6605
  }
6606
6606
  t.forEach(
6607
6607
  (i) => i.layer.renderDeferred(e)
@@ -6623,17 +6623,17 @@ function Mi(n, e) {
6623
6623
  }
6624
6624
  if (n instanceof ve) {
6625
6625
  const t = n.getLayers().getArray();
6626
- for (let i = 0, s = t.length; i < s; ++i)
6626
+ for (let i = 0, r = t.length; i < r; ++i)
6627
6627
  Mi(t[i], e);
6628
6628
  }
6629
6629
  }
6630
- class Zs extends tt {
6630
+ class Zr extends tt {
6631
6631
  /**
6632
6632
  * @param {MapOptions} [options] Map options.
6633
6633
  */
6634
6634
  constructor(e) {
6635
6635
  super(), e = e || {}, this.on, this.once, this.un;
6636
- const t = js(e);
6636
+ const t = jr(e);
6637
6637
  this.renderComplete_ = !1, this.loaded_ = !0, this.boundHandleBrowserEvent_ = this.handleBrowserEvent.bind(this), this.maxTilesLoading_ = e.maxTilesLoading !== void 0 ? e.maxTilesLoading : 16, this.pixelRatio_ = e.pixelRatio !== void 0 ? e.pixelRatio : en, this.postRenderTimeoutHandle_, this.animationDelayKey_, this.animationDelay_ = this.animationDelay_.bind(this), this.coordinateToPixelTransform_ = Ft(), this.pixelToCoordinateTransform_ = Ft(), this.frameIndex_ = 0, this.frameState_ = null, this.previousExtent_ = null, this.viewPropertyListenerKey_ = null, this.viewChangeListenerKey_ = null, this.layerGroupPropertyListenerKeys_ = null, oe || (this.viewport_ = document.createElement("div"), this.viewport_.className = "ol-viewport" + ("ontouchstart" in window ? " ol-touch" : ""), this.viewport_.style.position = "relative", this.viewport_.style.overflow = "hidden", this.viewport_.style.width = "100%", this.viewport_.style.height = "100%", this.overlayContainer_ = document.createElement("div"), this.overlayContainer_.style.position = "absolute", this.overlayContainer_.style.zIndex = "0", this.overlayContainer_.style.width = "100%", this.overlayContainer_.style.height = "100%", this.overlayContainer_.style.pointerEvents = "none", this.overlayContainer_.className = "ol-overlaycontainer", this.viewport_.appendChild(this.overlayContainer_), this.overlayContainerStopEvent_ = document.createElement("div"), this.overlayContainerStopEvent_.style.position = "absolute", this.overlayContainerStopEvent_.style.zIndex = "0", this.overlayContainerStopEvent_.style.width = "100%", this.overlayContainerStopEvent_.style.height = "100%", this.overlayContainerStopEvent_.style.pointerEvents = "none", this.overlayContainerStopEvent_.className = "ol-overlaycontainer-stopevent", this.viewport_.appendChild(this.overlayContainerStopEvent_)), this.mapBrowserEventHandler_ = null, this.moveTolerance_ = e.moveTolerance, this.keyboardEventTarget_ = t.keyboardEventTarget, this.targetChangeHandlerKeys_ = null, this.targetElement_ = null, oe || (this.resizeObserver_ = new ResizeObserver(() => this.updateSize())), this.controls = t.controls || (oe ? new Y() : wn()), this.interactions = t.interactions || (oe ? new Y() : Gn({
6638
6638
  onFocusOnly: !0
6639
6639
  })), this.overlays_ = t.overlays, this.overlayIdIndex_ = {}, this.renderer_ = null, this.postRenderFunctions_ = [], this.tileQueue_ = new _n(
@@ -6644,70 +6644,70 @@ class Zs extends tt {
6644
6644
  this.handleLayerGroupChanged_
6645
6645
  ), this.addChangeListener(S.VIEW, this.handleViewChanged_), this.addChangeListener(S.SIZE, this.handleSizeChanged_), this.addChangeListener(S.TARGET, this.handleTargetChanged_), this.setProperties(t.values);
6646
6646
  const i = this;
6647
- e.view && !(e.view instanceof ae) && e.view.then(function(s) {
6648
- i.setView(new ae(s));
6647
+ e.view && !(e.view instanceof ae) && e.view.then(function(r) {
6648
+ i.setView(new ae(r));
6649
6649
  }), this.controls.addEventListener(
6650
6650
  B.ADD,
6651
6651
  /**
6652
6652
  * @param {import("./Collection.js").CollectionEvent<import("./control/Control.js").default>} event CollectionEvent
6653
6653
  */
6654
- (s) => {
6655
- s.element.setMap(this);
6654
+ (r) => {
6655
+ r.element.setMap(this);
6656
6656
  }
6657
6657
  ), this.controls.addEventListener(
6658
6658
  B.REMOVE,
6659
6659
  /**
6660
6660
  * @param {import("./Collection.js").CollectionEvent<import("./control/Control.js").default>} event CollectionEvent.
6661
6661
  */
6662
- (s) => {
6663
- s.element.setMap(null);
6662
+ (r) => {
6663
+ r.element.setMap(null);
6664
6664
  }
6665
6665
  ), this.interactions.addEventListener(
6666
6666
  B.ADD,
6667
6667
  /**
6668
6668
  * @param {import("./Collection.js").CollectionEvent<import("./interaction/Interaction.js").default>} event CollectionEvent.
6669
6669
  */
6670
- (s) => {
6671
- s.element.setMap(this);
6670
+ (r) => {
6671
+ r.element.setMap(this);
6672
6672
  }
6673
6673
  ), this.interactions.addEventListener(
6674
6674
  B.REMOVE,
6675
6675
  /**
6676
6676
  * @param {import("./Collection.js").CollectionEvent<import("./interaction/Interaction.js").default>} event CollectionEvent.
6677
6677
  */
6678
- (s) => {
6679
- s.element.setMap(null);
6678
+ (r) => {
6679
+ r.element.setMap(null);
6680
6680
  }
6681
6681
  ), this.overlays_.addEventListener(
6682
6682
  B.ADD,
6683
6683
  /**
6684
6684
  * @param {import("./Collection.js").CollectionEvent<import("./Overlay.js").default>} event CollectionEvent.
6685
6685
  */
6686
- (s) => {
6687
- this.addOverlayInternal_(s.element);
6686
+ (r) => {
6687
+ this.addOverlayInternal_(r.element);
6688
6688
  }
6689
6689
  ), this.overlays_.addEventListener(
6690
6690
  B.REMOVE,
6691
6691
  /**
6692
6692
  * @param {import("./Collection.js").CollectionEvent<import("./Overlay.js").default>} event CollectionEvent.
6693
6693
  */
6694
- (s) => {
6695
- const r = s.element.getId();
6696
- r !== void 0 && delete this.overlayIdIndex_[r.toString()], s.element.setMap(null);
6694
+ (r) => {
6695
+ const s = r.element.getId();
6696
+ s !== void 0 && delete this.overlayIdIndex_[s.toString()], r.element.setMap(null);
6697
6697
  }
6698
6698
  ), this.controls.forEach(
6699
6699
  /**
6700
6700
  * @param {import("./control/Control.js").default} control Control.
6701
6701
  */
6702
- (s) => {
6703
- s.setMap(this);
6702
+ (r) => {
6703
+ r.setMap(this);
6704
6704
  }
6705
6705
  ), this.interactions.forEach(
6706
6706
  /**
6707
6707
  * @param {import("./interaction/Interaction.js").default} interaction Interaction.
6708
6708
  */
6709
- (s) => {
6710
- s.setMap(this);
6709
+ (r) => {
6710
+ r.setMap(this);
6711
6711
  }
6712
6712
  ), this.overlays_.forEach(this.addOverlayInternal_.bind(this));
6713
6713
  }
@@ -6797,13 +6797,13 @@ class Zs extends tt {
6797
6797
  forEachFeatureAtPixel(e, t, i) {
6798
6798
  if (!this.frameState_ || !this.renderer_)
6799
6799
  return;
6800
- const s = this.getCoordinateFromPixelInternal(e);
6800
+ const r = this.getCoordinateFromPixelInternal(e);
6801
6801
  i = i !== void 0 ? i : {};
6802
- const r = i.hitTolerance !== void 0 ? i.hitTolerance : 0, a = i.layerFilter !== void 0 ? i.layerFilter : qe, o = i.checkWrapped !== !1;
6802
+ const s = i.hitTolerance !== void 0 ? i.hitTolerance : 0, a = i.layerFilter !== void 0 ? i.layerFilter : qe, o = i.checkWrapped !== !1;
6803
6803
  return this.renderer_.forEachFeatureAtCoordinate(
6804
- s,
6805
- this.frameState_,
6806
6804
  r,
6805
+ this.frameState_,
6806
+ s,
6807
6807
  o,
6808
6808
  t,
6809
6809
  null,
@@ -6826,8 +6826,8 @@ class Zs extends tt {
6826
6826
  const i = [];
6827
6827
  return this.forEachFeatureAtPixel(
6828
6828
  e,
6829
- function(s) {
6830
- i.push(s);
6829
+ function(r) {
6830
+ i.push(r);
6831
6831
  },
6832
6832
  t
6833
6833
  ), i;
@@ -6840,8 +6840,8 @@ class Zs extends tt {
6840
6840
  getAllLayers() {
6841
6841
  const e = [];
6842
6842
  function t(i) {
6843
- i.forEach(function(s) {
6844
- s instanceof ve ? t(s.getLayers()) : e.push(s);
6843
+ i.forEach(function(r) {
6844
+ r instanceof ve ? t(r.getLayers()) : e.push(r);
6845
6845
  });
6846
6846
  }
6847
6847
  return t(this.getLayers()), e;
@@ -6862,13 +6862,13 @@ class Zs extends tt {
6862
6862
  return !1;
6863
6863
  const i = this.getCoordinateFromPixelInternal(e);
6864
6864
  t = t !== void 0 ? t : {};
6865
- const s = t.layerFilter !== void 0 ? t.layerFilter : qe, r = t.hitTolerance !== void 0 ? t.hitTolerance : 0, a = t.checkWrapped !== !1;
6865
+ const r = t.layerFilter !== void 0 ? t.layerFilter : qe, s = t.hitTolerance !== void 0 ? t.hitTolerance : 0, a = t.checkWrapped !== !1;
6866
6866
  return this.renderer_.hasFeatureAtCoordinate(
6867
6867
  i,
6868
6868
  this.frameState_,
6869
- r,
6870
- a,
6871
6869
  s,
6870
+ a,
6871
+ r,
6872
6872
  null
6873
6873
  );
6874
6874
  }
@@ -6896,7 +6896,7 @@ class Zs extends tt {
6896
6896
  * @api
6897
6897
  */
6898
6898
  getEventPixel(e) {
6899
- const i = this.viewport_.getBoundingClientRect(), s = this.getSize(), r = i.width / s[0], a = i.height / s[1], o = (
6899
+ const i = this.viewport_.getBoundingClientRect(), r = this.getSize(), s = i.width / r[0], a = i.height / r[1], o = (
6900
6900
  //FIXME Are we really calling this with a TouchEvent anywhere?
6901
6901
  "changedTouches" in e ? (
6902
6902
  /** @type {TouchEvent} */
@@ -6907,7 +6907,7 @@ class Zs extends tt {
6907
6907
  )
6908
6908
  );
6909
6909
  return [
6910
- (o.clientX - i.left) / r,
6910
+ (o.clientX - i.left) / s,
6911
6911
  (o.clientY - i.top) / a
6912
6912
  ];
6913
6913
  }
@@ -7040,13 +7040,13 @@ class Zs extends tt {
7040
7040
  getLoadingOrNotReady() {
7041
7041
  const e = this.getLayerGroup().getLayerStatesArray();
7042
7042
  for (let t = 0, i = e.length; t < i; ++t) {
7043
- const s = e[t];
7044
- if (!s.visible)
7043
+ const r = e[t];
7044
+ if (!r.visible)
7045
7045
  continue;
7046
- const r = s.layer.getRenderer();
7047
- if (r && !r.ready)
7046
+ const s = r.layer.getRenderer();
7047
+ if (s && !s.ready)
7048
7048
  return !0;
7049
- const a = s.layer.getSource();
7049
+ const a = r.layer.getSource();
7050
7050
  if (a && a.loading)
7051
7051
  return !0;
7052
7052
  }
@@ -7153,13 +7153,13 @@ class Zs extends tt {
7153
7153
  * @param {number} tileResolution Tile resolution.
7154
7154
  * @return {number} Tile priority.
7155
7155
  */
7156
- getTilePriority(e, t, i, s) {
7156
+ getTilePriority(e, t, i, r) {
7157
7157
  return mn(
7158
7158
  this.frameState_,
7159
7159
  e,
7160
7160
  t,
7161
7161
  i,
7162
- s
7162
+ r
7163
7163
  );
7164
7164
  }
7165
7165
  /**
@@ -7179,10 +7179,10 @@ class Zs extends tt {
7179
7179
  return;
7180
7180
  const t = e.originalEvent, i = t.type;
7181
7181
  if (i === yt.POINTERDOWN || i === w.WHEEL || i === w.KEYDOWN) {
7182
- const s = this.getOwnerDocument(), r = this.viewport_.getRootNode ? this.viewport_.getRootNode() : s, a = (
7182
+ const r = this.getOwnerDocument(), s = this.viewport_.getRootNode ? this.viewport_.getRootNode() : r, a = (
7183
7183
  /** @type {Node} */
7184
7184
  t.target
7185
- ), o = r instanceof ShadowRoot ? r.host === a ? r.host.ownerDocument : r : r === s ? s.documentElement : r;
7185
+ ), o = s instanceof ShadowRoot ? s.host === a ? s.host.ownerDocument : s : s === r ? r.documentElement : s;
7186
7186
  if (
7187
7187
  // Abort if the target is a child of the container for elements whose events are not meant
7188
7188
  // to be handled by map interactions.
@@ -7195,9 +7195,9 @@ class Zs extends tt {
7195
7195
  return;
7196
7196
  }
7197
7197
  if (e.frameState = this.frameState_, this.dispatchEvent(e) !== !1) {
7198
- const s = this.getInteractions().getArray().slice();
7199
- for (let r = s.length - 1; r >= 0; r--) {
7200
- const a = s[r];
7198
+ const r = this.getInteractions().getArray().slice();
7199
+ for (let s = r.length - 1; s >= 0; s--) {
7200
+ const a = r[s];
7201
7201
  if (a.getMap() !== this || !a.getActive() || !this.getTargetElement())
7202
7202
  continue;
7203
7203
  if (!a.handleEvent(e) || e.propagationStopped)
@@ -7211,28 +7211,28 @@ class Zs extends tt {
7211
7211
  handlePostRender() {
7212
7212
  const e = this.frameState_, t = this.tileQueue_;
7213
7213
  if (!t.isEmpty()) {
7214
- let s = this.maxTilesLoading_, r = s;
7214
+ let r = this.maxTilesLoading_, s = r;
7215
7215
  if (e) {
7216
7216
  const a = e.viewHints;
7217
7217
  if (a[He.ANIMATING] || a[He.INTERACTING]) {
7218
7218
  const o = Date.now() - e.time > 8;
7219
- s = o ? 0 : 8, r = o ? 0 : 2;
7219
+ r = o ? 0 : 8, s = o ? 0 : 2;
7220
7220
  }
7221
7221
  }
7222
- t.getTilesLoading() < s && (t.reprioritize(), t.loadMoreTiles(s, r));
7222
+ t.getTilesLoading() < r && (t.reprioritize(), t.loadMoreTiles(r, s));
7223
7223
  }
7224
7224
  e && this.renderer_ && !e.animate && (this.renderComplete_ ? (this.hasListener(Me.RENDERCOMPLETE) && this.renderer_.dispatchRenderEvent(
7225
7225
  Me.RENDERCOMPLETE,
7226
7226
  e
7227
7227
  ), this.loaded_ === !1 && (this.loaded_ = !0, this.dispatchEvent(
7228
- new me(se.LOADEND, this, e)
7228
+ new me(re.LOADEND, this, e)
7229
7229
  ))) : this.loaded_ === !0 && (this.loaded_ = !1, this.dispatchEvent(
7230
- new me(se.LOADSTART, this, e)
7230
+ new me(re.LOADSTART, this, e)
7231
7231
  )));
7232
7232
  const i = this.postRenderFunctions_;
7233
7233
  if (e)
7234
- for (let s = 0, r = i.length; s < r; ++s)
7235
- i[s](this, e);
7234
+ for (let r = 0, s = i.length; r < s; ++r)
7235
+ i[r](this, e);
7236
7236
  i.length = 0;
7237
7237
  }
7238
7238
  /**
@@ -7246,7 +7246,7 @@ class Zs extends tt {
7246
7246
  */
7247
7247
  handleTargetChanged_() {
7248
7248
  if (this.mapBrowserEventHandler_) {
7249
- for (let i = 0, s = this.targetChangeHandlerKeys_.length; i < s; ++i)
7249
+ for (let i = 0, r = this.targetChangeHandlerKeys_.length; i < r; ++i)
7250
7250
  G(this.targetChangeHandlerKeys_[i]);
7251
7251
  this.targetChangeHandlerKeys_ = null, this.viewport_.removeEventListener(
7252
7252
  w.CONTEXTMENU,
@@ -7265,14 +7265,14 @@ class Zs extends tt {
7265
7265
  if (this.targetElement_ = t, !t)
7266
7266
  this.renderer_ && (clearTimeout(this.postRenderTimeoutHandle_), this.postRenderTimeoutHandle_ = void 0, this.postRenderFunctions_.length = 0, this.renderer_.dispose(), this.renderer_ = null), this.animationDelayKey_ && (cancelAnimationFrame(this.animationDelayKey_), this.animationDelayKey_ = void 0);
7267
7267
  else {
7268
- if (le(t) || t.appendChild(this.viewport_), this.renderer_ || (this.renderer_ = new qs(this)), !le(t)) {
7268
+ if (le(t) || t.appendChild(this.viewport_), this.renderer_ || (this.renderer_ = new qr(this)), !le(t)) {
7269
7269
  this.mapBrowserEventHandler_ = new fn(
7270
7270
  this,
7271
7271
  this.moveTolerance_
7272
7272
  );
7273
- for (const s in D)
7273
+ for (const r in D)
7274
7274
  this.mapBrowserEventHandler_.addEventListener(
7275
- D[s],
7275
+ D[r],
7276
7276
  this.handleMapBrowserEvent.bind(this)
7277
7277
  );
7278
7278
  this.viewport_.addEventListener(
@@ -7288,8 +7288,8 @@ class Zs extends tt {
7288
7288
  if (this.keyboardEventTarget_)
7289
7289
  i = this.keyboardEventTarget_;
7290
7290
  else {
7291
- const s = t.getRootNode();
7292
- i = s instanceof ShadowRoot ? s.host : t;
7291
+ const r = t.getRootNode();
7292
+ i = r instanceof ShadowRoot ? r.host : t;
7293
7293
  }
7294
7294
  if (this.targetChangeHandlerKeys_ = [
7295
7295
  T(
@@ -7305,8 +7305,8 @@ class Zs extends tt {
7305
7305
  this
7306
7306
  )
7307
7307
  ], t instanceof HTMLElement) {
7308
- const s = t.getRootNode();
7309
- s instanceof ShadowRoot && this.resizeObserver_.observe(s.host), this.resizeObserver_?.observe(t);
7308
+ const r = t.getRootNode();
7309
+ r instanceof ShadowRoot && this.resizeObserver_.observe(r.host), this.resizeObserver_?.observe(t);
7310
7310
  }
7311
7311
  }
7312
7312
  this.updateSize();
@@ -7382,8 +7382,8 @@ class Zs extends tt {
7382
7382
  return;
7383
7383
  const e = this.frameState_.layerStatesArray;
7384
7384
  for (let t = 0, i = e.length; t < i; ++t) {
7385
- const s = e[t].layer;
7386
- s.hasRenderer() && s.getRenderer().handleFontsChanged();
7385
+ const r = e[t].layer;
7386
+ r.hasRenderer() && r.getRenderer().handleFontsChanged();
7387
7387
  }
7388
7388
  }
7389
7389
  /**
@@ -7445,13 +7445,13 @@ class Zs extends tt {
7445
7445
  * @private
7446
7446
  */
7447
7447
  renderFrame_(e) {
7448
- const t = this.getSize(), i = this.getView(), s = this.frameState_;
7449
- let r = null;
7448
+ const t = this.getSize(), i = this.getView(), r = this.frameState_;
7449
+ let s = null;
7450
7450
  if (t !== void 0 && Nt(t) && i && i.isDef()) {
7451
7451
  const a = i.getHints(
7452
7452
  this.frameState_ ? this.frameState_.viewHints : void 0
7453
7453
  ), o = i.getState();
7454
- if (r = {
7454
+ if (s = {
7455
7455
  animate: !1,
7456
7456
  coordinateToPixelTransform: this.coordinateToPixelTransform_,
7457
7457
  declutter: null,
@@ -7478,7 +7478,7 @@ class Zs extends tt {
7478
7478
  renderTargets: {}
7479
7479
  }, o.nextCenter && o.nextResolution) {
7480
7480
  const l = isNaN(o.nextRotation) ? o.rotation : o.nextRotation;
7481
- r.nextExtent = Ot(
7481
+ s.nextExtent = Ot(
7482
7482
  o.nextCenter,
7483
7483
  o.nextResolution,
7484
7484
  l,
@@ -7486,14 +7486,14 @@ class Zs extends tt {
7486
7486
  );
7487
7487
  }
7488
7488
  }
7489
- this.frameState_ = r, this.renderer_.renderFrame(r), r && (r.animate && this.render(), Array.prototype.push.apply(
7489
+ this.frameState_ = s, this.renderer_.renderFrame(s), s && (s.animate && this.render(), Array.prototype.push.apply(
7490
7490
  this.postRenderFunctions_,
7491
- r.postRenderFunctions
7492
- ), s && (!this.previousExtent_ || !Yi(this.previousExtent_) && !Mt(r.extent, this.previousExtent_)) && (this.dispatchEvent(
7493
- new me(se.MOVESTART, this, s)
7494
- ), this.previousExtent_ = Ui(this.previousExtent_)), this.previousExtent_ && !r.viewHints[He.ANIMATING] && !r.viewHints[He.INTERACTING] && !Mt(r.extent, this.previousExtent_) && (this.dispatchEvent(
7495
- new me(se.MOVEEND, this, r)
7496
- ), $i(r.extent, this.previousExtent_))), this.dispatchEvent(new me(se.POSTRENDER, this, r)), this.renderComplete_ = (this.hasListener(se.LOADSTART) || this.hasListener(se.LOADEND) || this.hasListener(Me.RENDERCOMPLETE)) && !this.tileQueue_.getTilesLoading() && !this.tileQueue_.getCount() && !this.getLoadingOrNotReady(), this.postRenderTimeoutHandle_ || (this.postRenderTimeoutHandle_ = setTimeout(() => {
7491
+ s.postRenderFunctions
7492
+ ), r && (!this.previousExtent_ || !Yi(this.previousExtent_) && !Mt(s.extent, this.previousExtent_)) && (this.dispatchEvent(
7493
+ new me(re.MOVESTART, this, r)
7494
+ ), this.previousExtent_ = Ui(this.previousExtent_)), this.previousExtent_ && !s.viewHints[He.ANIMATING] && !s.viewHints[He.INTERACTING] && !Mt(s.extent, this.previousExtent_) && (this.dispatchEvent(
7495
+ new me(re.MOVEEND, this, s)
7496
+ ), $i(s.extent, this.previousExtent_))), this.dispatchEvent(new me(re.POSTRENDER, this, s)), this.renderComplete_ = (this.hasListener(re.LOADSTART) || this.hasListener(re.LOADEND) || this.hasListener(Me.RENDERCOMPLETE)) && !this.tileQueue_.getTilesLoading() && !this.tileQueue_.getCount() && !this.getLoadingOrNotReady(), this.postRenderTimeoutHandle_ || (this.postRenderTimeoutHandle_ = setTimeout(() => {
7497
7497
  this.postRenderTimeoutHandle_ = void 0, this.handlePostRender();
7498
7498
  }, 0));
7499
7499
  }
@@ -7558,14 +7558,14 @@ class Zs extends tt {
7558
7558
  const e = this.getTargetElement();
7559
7559
  let t;
7560
7560
  if (e) {
7561
- let s, r;
7561
+ let r, s;
7562
7562
  if (le(e))
7563
- s = e.width, r = e.height;
7563
+ r = e.width, s = e.height;
7564
7564
  else {
7565
7565
  const a = getComputedStyle(e);
7566
- s = e.offsetWidth - parseFloat(a.borderLeftWidth) - parseFloat(a.paddingLeft) - parseFloat(a.paddingRight) - parseFloat(a.borderRightWidth), r = e.offsetHeight - parseFloat(a.borderTopWidth) - parseFloat(a.paddingTop) - parseFloat(a.paddingBottom) - parseFloat(a.borderBottomWidth);
7566
+ r = e.offsetWidth - parseFloat(a.borderLeftWidth) - parseFloat(a.paddingLeft) - parseFloat(a.paddingRight) - parseFloat(a.borderRightWidth), s = e.offsetHeight - parseFloat(a.borderTopWidth) - parseFloat(a.paddingTop) - parseFloat(a.paddingBottom) - parseFloat(a.borderBottomWidth);
7567
7567
  }
7568
- !isNaN(s) && !isNaN(r) && (t = [Math.max(0, s), Math.max(0, r)], !Nt(t) && (e.offsetWidth || e.offsetHeight || e.getClientRects().length) && Xi(
7568
+ !isNaN(r) && !isNaN(s) && (t = [Math.max(0, r), Math.max(0, s)], !Nt(t) && (e.offsetWidth || e.offsetHeight || e.getClientRects().length) && Xi(
7569
7569
  "No map visible because the map container's width or height are 0."
7570
7570
  ));
7571
7571
  }
@@ -7582,7 +7582,7 @@ class Zs extends tt {
7582
7582
  t && t.setViewportSize(e);
7583
7583
  }
7584
7584
  }
7585
- function js(n) {
7585
+ function jr(n) {
7586
7586
  let e = null;
7587
7587
  n.keyboardEventTarget !== void 0 && (e = typeof n.keyboardEventTarget == "string" ? document.getElementById(n.keyboardEventTarget) : n.keyboardEventTarget);
7588
7588
  const t = {}, i = n.layers && typeof /** @type {?} */
@@ -7596,82 +7596,82 @@ function js(n) {
7596
7596
  )
7597
7597
  });
7598
7598
  t[S.LAYERGROUP] = i, t[S.TARGET] = n.target, t[S.VIEW] = n.view instanceof ae ? n.view : new ae();
7599
- let s;
7600
- n.controls !== void 0 && (Array.isArray(n.controls) ? s = new Y(n.controls.slice()) : (j(
7599
+ let r;
7600
+ n.controls !== void 0 && (Array.isArray(n.controls) ? r = new Y(n.controls.slice()) : (j(
7601
7601
  typeof /** @type {?} */
7602
7602
  n.controls.getArray == "function",
7603
7603
  "Expected `controls` to be an array or an `ol/Collection.js`"
7604
- ), s = n.controls));
7605
- let r;
7606
- n.interactions !== void 0 && (Array.isArray(n.interactions) ? r = new Y(n.interactions.slice()) : (j(
7604
+ ), r = n.controls));
7605
+ let s;
7606
+ n.interactions !== void 0 && (Array.isArray(n.interactions) ? s = new Y(n.interactions.slice()) : (j(
7607
7607
  typeof /** @type {?} */
7608
7608
  n.interactions.getArray == "function",
7609
7609
  "Expected `interactions` to be an array or an `ol/Collection.js`"
7610
- ), r = n.interactions));
7610
+ ), s = n.interactions));
7611
7611
  let a;
7612
7612
  return n.overlays !== void 0 ? Array.isArray(n.overlays) ? a = new Y(n.overlays.slice()) : (j(
7613
7613
  typeof /** @type {?} */
7614
7614
  n.overlays.getArray == "function",
7615
7615
  "Expected `overlays` to be an array or an `ol/Collection.js`"
7616
7616
  ), a = n.overlays) : a = new Y(), {
7617
- controls: s,
7618
- interactions: r,
7617
+ controls: r,
7618
+ interactions: s,
7619
7619
  keyboardEventTarget: e,
7620
7620
  overlays: a,
7621
7621
  values: t
7622
7622
  };
7623
7623
  }
7624
- const wr = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
7624
+ const ws = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
7625
7625
  __proto__: null,
7626
- default: Zs
7626
+ default: Zr
7627
7627
  }, Symbol.toStringTag, { value: "Module" }));
7628
7628
  export {
7629
- sr as A,
7630
- Ys as B,
7629
+ rs as A,
7630
+ Yr as B,
7631
7631
  Y as C,
7632
- or as D,
7632
+ os as D,
7633
7633
  Ve as E,
7634
7634
  ne as F,
7635
7635
  U as G,
7636
7636
  Be as H,
7637
7637
  Rt as I,
7638
7638
  pe as J,
7639
- Zs as K,
7640
- ar as L,
7639
+ Zr as K,
7640
+ as as L,
7641
7641
  D as M,
7642
- rt as N,
7642
+ st as N,
7643
7643
  yn as O,
7644
7644
  Ke as P,
7645
7645
  S as Q,
7646
7646
  Hn as R,
7647
7647
  ce as S,
7648
7648
  xt as T,
7649
- wr as U,
7649
+ ws as U,
7650
7650
  En as Z,
7651
7651
  B as a,
7652
7652
  $t as b,
7653
- Ls as c,
7653
+ Lr as c,
7654
7654
  Xt as d,
7655
7655
  qt as e,
7656
- cr as f,
7657
- ur as g,
7656
+ cs as f,
7657
+ us as g,
7658
7658
  Zt as h,
7659
- As as i,
7660
- Cs as j,
7661
- gr as k,
7662
- fr as l,
7663
- dr as m,
7664
- hr as n,
7665
- yr as o,
7666
- pr as p,
7667
- mr as q,
7668
- _r as r,
7659
+ Ar as i,
7660
+ Cr as j,
7661
+ gs as k,
7662
+ fs as l,
7663
+ ds as m,
7664
+ hs as n,
7665
+ ys as o,
7666
+ ps as p,
7667
+ ms as q,
7668
+ _s as r,
7669
7669
  pi as s,
7670
7670
  bn as t,
7671
7671
  Tn as u,
7672
7672
  Gt as v,
7673
7673
  te as w,
7674
- rr as x,
7675
- Er as y,
7674
+ ss as x,
7675
+ Es as y,
7676
7676
  Rn as z
7677
7677
  };