@eox/drawtools 1.1.0 → 1.1.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,17 +1,17 @@
1
1
  var vi = Object.defineProperty;
2
- var Vt = (i) => {
2
+ var Ut = (i) => {
3
3
  throw TypeError(i);
4
4
  };
5
- var xi = (i, e, t) => e in i ? vi(i, e, { enumerable: !0, configurable: !0, writable: !0, value: t }) : i[e] = t;
6
- var I = (i, e, t) => xi(i, typeof e != "symbol" ? e + "" : e, t), Ut = (i, e, t) => e.has(i) || Vt("Cannot " + t);
7
- var M = (i, e, t) => (Ut(i, e, "read from private field"), t ? t.call(i) : e.get(i)), A = (i, e, t) => e.has(i) ? Vt("Cannot add the same private member more than once") : e instanceof WeakSet ? e.add(i) : e.set(i, t), P = (i, e, t, r) => (Ut(i, e, "write to private field"), r ? r.call(i, t) : e.set(i, t), t);
5
+ var ki = (i, e, t) => e in i ? vi(i, e, { enumerable: !0, configurable: !0, writable: !0, value: t }) : i[e] = t;
6
+ var I = (i, e, t) => ki(i, typeof e != "symbol" ? e + "" : e, t), Yt = (i, e, t) => e.has(i) || Ut("Cannot " + t);
7
+ var S = (i, e, t) => (Yt(i, e, "read from private field"), t ? t.call(i) : e.get(i)), A = (i, e, t) => e.has(i) ? Ut("Cannot add the same private member more than once") : e instanceof WeakSet ? e.add(i) : e.set(i, t), P = (i, e, t, r) => (Yt(i, e, "write to private field"), r ? r.call(i, t) : e.set(i, t), t);
8
8
  /**
9
9
  * @license
10
10
  * Copyright 2019 Google LLC
11
11
  * SPDX-License-Identifier: BSD-3-Clause
12
12
  */
13
- const Le = globalThis, gt = Le.ShadowRoot && (Le.ShadyCSS === void 0 || Le.ShadyCSS.nativeShadow) && "adoptedStyleSheets" in Document.prototype && "replace" in CSSStyleSheet.prototype, _r = Symbol(), Yt = /* @__PURE__ */ new WeakMap();
14
- let ki = class {
13
+ const Le = globalThis, ft = Le.ShadowRoot && (Le.ShadyCSS === void 0 || Le.ShadyCSS.nativeShadow) && "adoptedStyleSheets" in Document.prototype && "replace" in CSSStyleSheet.prototype, _r = Symbol(), Xt = /* @__PURE__ */ new WeakMap();
14
+ let xi = class {
15
15
  constructor(e, t, r) {
16
16
  if (this._$cssResult$ = !0, r !== _r) throw Error("CSSResult is not constructable. Use `unsafeCSS` or `css` instead.");
17
17
  this.cssText = e, this.t = t;
@@ -19,9 +19,9 @@ let ki = class {
19
19
  get styleSheet() {
20
20
  let e = this.o;
21
21
  const t = this.t;
22
- if (gt && e === void 0) {
22
+ if (ft && e === void 0) {
23
23
  const r = t !== void 0 && t.length === 1;
24
- r && (e = Yt.get(t)), e === void 0 && ((this.o = e = new CSSStyleSheet()).replaceSync(this.cssText), r && Yt.set(t, e));
24
+ r && (e = Xt.get(t)), e === void 0 && ((this.o = e = new CSSStyleSheet()).replaceSync(this.cssText), r && Xt.set(t, e));
25
25
  }
26
26
  return e;
27
27
  }
@@ -29,13 +29,13 @@ let ki = class {
29
29
  return this.cssText;
30
30
  }
31
31
  };
32
- const _i = (i) => new ki(typeof i == "string" ? i : i + "", void 0, _r), wi = (i, e) => {
33
- if (gt) i.adoptedStyleSheets = e.map((t) => t instanceof CSSStyleSheet ? t : t.styleSheet);
32
+ const _i = (i) => new xi(typeof i == "string" ? i : i + "", void 0, _r), wi = (i, e) => {
33
+ if (ft) i.adoptedStyleSheets = e.map((t) => t instanceof CSSStyleSheet ? t : t.styleSheet);
34
34
  else for (const t of e) {
35
35
  const r = document.createElement("style"), n = Le.litNonce;
36
36
  n !== void 0 && r.setAttribute("nonce", n), r.textContent = t.cssText, i.appendChild(r);
37
37
  }
38
- }, Xt = gt ? (i) => i : (i) => i instanceof CSSStyleSheet ? ((e) => {
38
+ }, Bt = ft ? (i) => i : (i) => i instanceof CSSStyleSheet ? ((e) => {
39
39
  let t = "";
40
40
  for (const r of e.cssRules) t += r.cssText;
41
41
  return _i(t);
@@ -45,10 +45,10 @@ const _i = (i) => new ki(typeof i == "string" ? i : i + "", void 0, _r), wi = (i
45
45
  * Copyright 2017 Google LLC
46
46
  * SPDX-License-Identifier: BSD-3-Clause
47
47
  */
48
- const { is: zi, defineProperty: Ci, getOwnPropertyDescriptor: Si, getOwnPropertyNames: Mi, getOwnPropertySymbols: Ei, getPrototypeOf: Pi } = Object, L = globalThis, Bt = L.trustedTypes, $i = Bt ? Bt.emptyScript : "", De = L.reactiveElementPolyfillSupport, he = (i, e) => i, at = { toAttribute(i, e) {
48
+ const { is: zi, defineProperty: Ci, getOwnPropertyDescriptor: Mi, getOwnPropertyNames: Si, getOwnPropertySymbols: $i, getPrototypeOf: Pi } = Object, L = globalThis, qt = L.trustedTypes, Ei = qt ? qt.emptyScript : "", De = L.reactiveElementPolyfillSupport, he = (i, e) => i, st = { toAttribute(i, e) {
49
49
  switch (e) {
50
50
  case Boolean:
51
- i = i ? $i : null;
51
+ i = i ? Ei : null;
52
52
  break;
53
53
  case Object:
54
54
  case Array:
@@ -73,7 +73,7 @@ const { is: zi, defineProperty: Ci, getOwnPropertyDescriptor: Si, getOwnProperty
73
73
  }
74
74
  }
75
75
  return t;
76
- } }, wr = (i, e) => !zi(i, e), qt = { attribute: !0, type: String, converter: at, reflect: !1, hasChanged: wr };
76
+ } }, wr = (i, e) => !zi(i, e), Jt = { attribute: !0, type: String, converter: st, reflect: !1, hasChanged: wr };
77
77
  Symbol.metadata ?? (Symbol.metadata = Symbol("metadata")), L.litPropertyMetadata ?? (L.litPropertyMetadata = /* @__PURE__ */ new WeakMap());
78
78
  class ee extends HTMLElement {
79
79
  static addInitializer(e) {
@@ -82,14 +82,14 @@ class ee extends HTMLElement {
82
82
  static get observedAttributes() {
83
83
  return this.finalize(), this._$Eh && [...this._$Eh.keys()];
84
84
  }
85
- static createProperty(e, t = qt) {
85
+ static createProperty(e, t = Jt) {
86
86
  if (t.state && (t.attribute = !1), this._$Ei(), this.elementProperties.set(e, t), !t.noAccessor) {
87
87
  const r = Symbol(), n = this.getPropertyDescriptor(e, r, t);
88
88
  n !== void 0 && Ci(this.prototype, e, n);
89
89
  }
90
90
  }
91
91
  static getPropertyDescriptor(e, t, r) {
92
- const { get: n, set: o } = Si(this.prototype, e) ?? { get() {
92
+ const { get: n, set: o } = Mi(this.prototype, e) ?? { get() {
93
93
  return this[t];
94
94
  }, set(a) {
95
95
  this[t] = a;
@@ -102,7 +102,7 @@ class ee extends HTMLElement {
102
102
  }, configurable: !0, enumerable: !0 };
103
103
  }
104
104
  static getPropertyOptions(e) {
105
- return this.elementProperties.get(e) ?? qt;
105
+ return this.elementProperties.get(e) ?? Jt;
106
106
  }
107
107
  static _$Ei() {
108
108
  if (this.hasOwnProperty(he("elementProperties"))) return;
@@ -112,7 +112,7 @@ class ee extends HTMLElement {
112
112
  static finalize() {
113
113
  if (this.hasOwnProperty(he("finalized"))) return;
114
114
  if (this.finalized = !0, this._$Ei(), this.hasOwnProperty(he("properties"))) {
115
- const t = this.properties, r = [...Mi(t), ...Ei(t)];
115
+ const t = this.properties, r = [...Si(t), ...$i(t)];
116
116
  for (const n of r) this.createProperty(n, t[n]);
117
117
  }
118
118
  const e = this[Symbol.metadata];
@@ -131,8 +131,8 @@ class ee extends HTMLElement {
131
131
  const t = [];
132
132
  if (Array.isArray(e)) {
133
133
  const r = new Set(e.flat(1 / 0).reverse());
134
- for (const n of r) t.unshift(Xt(n));
135
- } else e !== void 0 && t.push(Xt(e));
134
+ for (const n of r) t.unshift(Bt(n));
135
+ } else e !== void 0 && t.push(Bt(e));
136
136
  return t;
137
137
  }
138
138
  static _$Eu(e, t) {
@@ -186,7 +186,7 @@ class ee extends HTMLElement {
186
186
  var o;
187
187
  const r = this.constructor.elementProperties.get(e), n = this.constructor._$Eu(e, r);
188
188
  if (n !== void 0 && r.reflect === !0) {
189
- const a = (((o = r.converter) == null ? void 0 : o.toAttribute) !== void 0 ? r.converter : at).toAttribute(t, r.type);
189
+ const a = (((o = r.converter) == null ? void 0 : o.toAttribute) !== void 0 ? r.converter : st).toAttribute(t, r.type);
190
190
  this._$Em = e, a == null ? this.removeAttribute(n) : this.setAttribute(n, a), this._$Em = null;
191
191
  }
192
192
  }
@@ -194,7 +194,7 @@ class ee extends HTMLElement {
194
194
  var o;
195
195
  const r = this.constructor, n = r._$Eh.get(e);
196
196
  if (n !== void 0 && this._$Em !== n) {
197
- const a = r.getPropertyOptions(n), s = typeof a.converter == "function" ? { fromAttribute: a.converter } : ((o = a.converter) == null ? void 0 : o.fromAttribute) !== void 0 ? a.converter : at;
197
+ const a = r.getPropertyOptions(n), s = typeof a.converter == "function" ? { fromAttribute: a.converter } : ((o = a.converter) == null ? void 0 : o.fromAttribute) !== void 0 ? a.converter : st;
198
198
  this._$Em = n, this[n] = s.fromAttribute(t, a.type), this._$Em = null;
199
199
  }
200
200
  }
@@ -279,12 +279,12 @@ ee.elementStyles = [], ee.shadowRootOptions = { mode: "open" }, ee[he("elementPr
279
279
  * Copyright 2017 Google LLC
280
280
  * SPDX-License-Identifier: BSD-3-Clause
281
281
  */
282
- const me = globalThis, Ie = me.trustedTypes, Jt = Ie ? Ie.createPolicy("lit-html", { createHTML: (i) => i }) : void 0, zr = "$lit$", F = `lit$${Math.random().toFixed(9).slice(2)}$`, Cr = "?" + F, Ai = `<${Cr}>`, U = document, pe = () => U.createComment(""), ge = (i) => i === null || typeof i != "object" && typeof i != "function", ft = Array.isArray, Fi = (i) => ft(i) || typeof (i == null ? void 0 : i[Symbol.iterator]) == "function", Qe = `[
283
- \f\r]`, ue = /<(?:(!--|\/[^a-zA-Z])|(\/?[a-zA-Z][^>\s]*)|(\/?$))/g, Wt = /-->/g, Zt = />/g, R = RegExp(`>|${Qe}(?:([^\\s"'>=/]+)(${Qe}*=${Qe}*(?:[^
284
- \f\r"'\`<>=]|("|')|))|$)`, "g"), Kt = /'/g, Dt = /"/g, Sr = /^(?:script|style|textarea|title)$/i, Li = (i) => (e, ...t) => ({ _$litType$: i, strings: e, values: t }), x = Li(1), ae = Symbol.for("lit-noChange"), k = Symbol.for("lit-nothing"), Qt = /* @__PURE__ */ new WeakMap(), T = U.createTreeWalker(U, 129);
285
- function Mr(i, e) {
286
- if (!ft(i) || !i.hasOwnProperty("raw")) throw Error("invalid template strings array");
287
- return Jt !== void 0 ? Jt.createHTML(e) : e;
282
+ const me = globalThis, Ie = me.trustedTypes, Wt = Ie ? Ie.createPolicy("lit-html", { createHTML: (i) => i }) : void 0, zr = "$lit$", F = `lit$${Math.random().toFixed(9).slice(2)}$`, Cr = "?" + F, Ai = `<${Cr}>`, U = document, pe = () => U.createComment(""), ge = (i) => i === null || typeof i != "object" && typeof i != "function", bt = Array.isArray, Fi = (i) => bt(i) || typeof (i == null ? void 0 : i[Symbol.iterator]) == "function", Qe = `[
283
+ \f\r]`, ue = /<(?:(!--|\/[^a-zA-Z])|(\/?[a-zA-Z][^>\s]*)|(\/?$))/g, Zt = /-->/g, Kt = />/g, R = RegExp(`>|${Qe}(?:([^\\s"'>=/]+)(${Qe}*=${Qe}*(?:[^
284
+ \f\r"'\`<>=]|("|')|))|$)`, "g"), Dt = /'/g, Qt = /"/g, Mr = /^(?:script|style|textarea|title)$/i, Li = (i) => (e, ...t) => ({ _$litType$: i, strings: e, values: t }), k = Li(1), ae = Symbol.for("lit-noChange"), x = Symbol.for("lit-nothing"), er = /* @__PURE__ */ new WeakMap(), T = U.createTreeWalker(U, 129);
285
+ function Sr(i, e) {
286
+ if (!bt(i) || !i.hasOwnProperty("raw")) throw Error("invalid template strings array");
287
+ return Wt !== void 0 ? Wt.createHTML(e) : e;
288
288
  }
289
289
  const Gi = (i, e) => {
290
290
  const t = i.length - 1, r = [];
@@ -292,11 +292,11 @@ const Gi = (i, e) => {
292
292
  for (let s = 0; s < t; s++) {
293
293
  const l = i[s];
294
294
  let c, d, u = -1, h = 0;
295
- for (; h < l.length && (a.lastIndex = h, d = a.exec(l), d !== null); ) h = a.lastIndex, a === ue ? d[1] === "!--" ? a = Wt : d[1] !== void 0 ? a = Zt : d[2] !== void 0 ? (Sr.test(d[2]) && (n = RegExp("</" + d[2], "g")), a = R) : d[3] !== void 0 && (a = R) : a === R ? d[0] === ">" ? (a = n ?? ue, u = -1) : d[1] === void 0 ? u = -2 : (u = a.lastIndex - d[2].length, c = d[1], a = d[3] === void 0 ? R : d[3] === '"' ? Dt : Kt) : a === Dt || a === Kt ? a = R : a === Wt || a === Zt ? a = ue : (a = R, n = void 0);
295
+ for (; h < l.length && (a.lastIndex = h, d = a.exec(l), d !== null); ) h = a.lastIndex, a === ue ? d[1] === "!--" ? a = Zt : d[1] !== void 0 ? a = Kt : d[2] !== void 0 ? (Mr.test(d[2]) && (n = RegExp("</" + d[2], "g")), a = R) : d[3] !== void 0 && (a = R) : a === R ? d[0] === ">" ? (a = n ?? ue, u = -1) : d[1] === void 0 ? u = -2 : (u = a.lastIndex - d[2].length, c = d[1], a = d[3] === void 0 ? R : d[3] === '"' ? Qt : Dt) : a === Qt || a === Dt ? a = R : a === Zt || a === Kt ? a = ue : (a = R, n = void 0);
296
296
  const m = a === R && i[s + 1].startsWith("/>") ? " " : "";
297
297
  o += a === ue ? l + Ai : u >= 0 ? (r.push(c), l.slice(0, u) + zr + l.slice(u) + F + m) : l + F + (u === -2 ? s : m);
298
298
  }
299
- return [Mr(i, o + (i[t] || "<?>") + (e === 2 ? "</svg>" : e === 3 ? "</math>" : "")), r];
299
+ return [Sr(i, o + (i[t] || "<?>") + (e === 2 ? "</svg>" : e === 3 ? "</math>" : "")), r];
300
300
  };
301
301
  class fe {
302
302
  constructor({ strings: e, _$litType$: t }, r) {
@@ -314,7 +314,7 @@ class fe {
314
314
  const h = d[a++], m = n.getAttribute(u).split(F), p = /([.?@])?(.*)/.exec(h);
315
315
  l.push({ type: 1, index: o, name: p[2], strings: m, ctor: p[1] === "." ? Ri : p[1] === "?" ? Ni : p[1] === "@" ? Ti : Ve }), n.removeAttribute(u);
316
316
  } else u.startsWith(F) && (l.push({ type: 6, index: o }), n.removeAttribute(u));
317
- if (Sr.test(n.tagName)) {
317
+ if (Mr.test(n.tagName)) {
318
318
  const u = n.textContent.split(F), h = u.length - 1;
319
319
  if (h > 0) {
320
320
  n.textContent = Ie ? Ie.emptyScript : "";
@@ -359,7 +359,7 @@ let Ii = class {
359
359
  for (; l !== void 0; ) {
360
360
  if (a === l.index) {
361
361
  let c;
362
- l.type === 2 ? c = new bt(o, o.nextSibling, this, e) : l.type === 1 ? c = new l.ctor(o, l.name, l.strings, this, e) : l.type === 6 && (c = new Oi(o, this, e)), this._$AV.push(c), l = r[++s];
362
+ l.type === 2 ? c = new yt(o, o.nextSibling, this, e) : l.type === 1 ? c = new l.ctor(o, l.name, l.strings, this, e) : l.type === 6 && (c = new Oi(o, this, e)), this._$AV.push(c), l = r[++s];
363
363
  }
364
364
  a !== (l == null ? void 0 : l.index) && (o = T.nextNode(), a++);
365
365
  }
@@ -369,13 +369,13 @@ let Ii = class {
369
369
  let t = 0;
370
370
  for (const r of this._$AV) r !== void 0 && (r.strings !== void 0 ? (r._$AI(e, r, t), t += r.strings.length - 2) : r._$AI(e[t])), t++;
371
371
  }
372
- }, bt = class Er {
372
+ }, yt = class $r {
373
373
  get _$AU() {
374
374
  var e;
375
375
  return ((e = this._$AM) == null ? void 0 : e._$AU) ?? this._$Cv;
376
376
  }
377
377
  constructor(e, t, r, n) {
378
- this.type = 2, this._$AH = k, this._$AN = void 0, this._$AA = e, this._$AB = t, this._$AM = r, this.options = n, this._$Cv = (n == null ? void 0 : n.isConnected) ?? !0;
378
+ this.type = 2, this._$AH = x, this._$AN = void 0, this._$AA = e, this._$AB = t, this._$AM = r, this.options = n, this._$Cv = (n == null ? void 0 : n.isConnected) ?? !0;
379
379
  }
380
380
  get parentNode() {
381
381
  let e = this._$AA.parentNode;
@@ -389,7 +389,7 @@ let Ii = class {
389
389
  return this._$AB;
390
390
  }
391
391
  _$AI(e, t = this) {
392
- e = se(this, e, t), ge(e) ? e === k || e == null || e === "" ? (this._$AH !== k && this._$AR(), this._$AH = k) : e !== this._$AH && e !== ae && this._(e) : e._$litType$ !== void 0 ? this.$(e) : e.nodeType !== void 0 ? this.T(e) : Fi(e) ? this.k(e) : this._(e);
392
+ e = se(this, e, t), ge(e) ? e === x || e == null || e === "" ? (this._$AH !== x && this._$AR(), this._$AH = x) : e !== this._$AH && e !== ae && this._(e) : e._$litType$ !== void 0 ? this.$(e) : e.nodeType !== void 0 ? this.T(e) : Fi(e) ? this.k(e) : this._(e);
393
393
  }
394
394
  O(e) {
395
395
  return this._$AA.parentNode.insertBefore(e, this._$AB);
@@ -398,11 +398,11 @@ let Ii = class {
398
398
  this._$AH !== e && (this._$AR(), this._$AH = this.O(e));
399
399
  }
400
400
  _(e) {
401
- this._$AH !== k && ge(this._$AH) ? this._$AA.nextSibling.data = e : this.T(U.createTextNode(e)), this._$AH = e;
401
+ this._$AH !== x && ge(this._$AH) ? this._$AA.nextSibling.data = e : this.T(U.createTextNode(e)), this._$AH = e;
402
402
  }
403
403
  $(e) {
404
404
  var o;
405
- const { values: t, _$litType$: r } = e, n = typeof r == "number" ? this._$AC(e) : (r.el === void 0 && (r.el = fe.createElement(Mr(r.h, r.h[0]), this.options)), r);
405
+ const { values: t, _$litType$: r } = e, n = typeof r == "number" ? this._$AC(e) : (r.el === void 0 && (r.el = fe.createElement(Sr(r.h, r.h[0]), this.options)), r);
406
406
  if (((o = this._$AH) == null ? void 0 : o._$AD) === n) this._$AH.p(t);
407
407
  else {
408
408
  const a = new Ii(n, this), s = a.u(this.options);
@@ -410,14 +410,14 @@ let Ii = class {
410
410
  }
411
411
  }
412
412
  _$AC(e) {
413
- let t = Qt.get(e.strings);
414
- return t === void 0 && Qt.set(e.strings, t = new fe(e)), t;
413
+ let t = er.get(e.strings);
414
+ return t === void 0 && er.set(e.strings, t = new fe(e)), t;
415
415
  }
416
416
  k(e) {
417
- ft(this._$AH) || (this._$AH = [], this._$AR());
417
+ bt(this._$AH) || (this._$AH = [], this._$AR());
418
418
  const t = this._$AH;
419
419
  let r, n = 0;
420
- for (const o of e) n === t.length ? t.push(r = new Er(this.O(pe()), this.O(pe()), this, this.options)) : r = t[n], r._$AI(o), n++;
420
+ for (const o of e) n === t.length ? t.push(r = new $r(this.O(pe()), this.O(pe()), this, this.options)) : r = t[n], r._$AI(o), n++;
421
421
  n < t.length && (this._$AR(r && r._$AB.nextSibling, n), t.length = n);
422
422
  }
423
423
  _$AR(e = this._$AA.nextSibling, t) {
@@ -440,7 +440,7 @@ class Ve {
440
440
  return this._$AM._$AU;
441
441
  }
442
442
  constructor(e, t, r, n, o) {
443
- this.type = 1, this._$AH = k, this._$AN = void 0, this.element = e, this.name = t, this._$AM = n, this.options = o, r.length > 2 || r[0] !== "" || r[1] !== "" ? (this._$AH = Array(r.length - 1).fill(new String()), this.strings = r) : this._$AH = k;
443
+ this.type = 1, this._$AH = x, this._$AN = void 0, this.element = e, this.name = t, this._$AM = n, this.options = o, r.length > 2 || r[0] !== "" || r[1] !== "" ? (this._$AH = Array(r.length - 1).fill(new String()), this.strings = r) : this._$AH = x;
444
444
  }
445
445
  _$AI(e, t = this, r, n) {
446
446
  const o = this.strings;
@@ -449,12 +449,12 @@ class Ve {
449
449
  else {
450
450
  const s = e;
451
451
  let l, c;
452
- for (e = o[0], l = 0; l < o.length - 1; l++) c = se(this, s[r + l], t, l), c === ae && (c = this._$AH[l]), a || (a = !ge(c) || c !== this._$AH[l]), c === k ? e = k : e !== k && (e += (c ?? "") + o[l + 1]), this._$AH[l] = c;
452
+ for (e = o[0], l = 0; l < o.length - 1; l++) c = se(this, s[r + l], t, l), c === ae && (c = this._$AH[l]), a || (a = !ge(c) || c !== this._$AH[l]), c === x ? e = x : e !== x && (e += (c ?? "") + o[l + 1]), this._$AH[l] = c;
453
453
  }
454
454
  a && !n && this.j(e);
455
455
  }
456
456
  j(e) {
457
- e === k ? this.element.removeAttribute(this.name) : this.element.setAttribute(this.name, e ?? "");
457
+ e === x ? this.element.removeAttribute(this.name) : this.element.setAttribute(this.name, e ?? "");
458
458
  }
459
459
  }
460
460
  class Ri extends Ve {
@@ -462,7 +462,7 @@ class Ri extends Ve {
462
462
  super(...arguments), this.type = 3;
463
463
  }
464
464
  j(e) {
465
- this.element[this.name] = e === k ? void 0 : e;
465
+ this.element[this.name] = e === x ? void 0 : e;
466
466
  }
467
467
  }
468
468
  class Ni extends Ve {
@@ -470,7 +470,7 @@ class Ni extends Ve {
470
470
  super(...arguments), this.type = 4;
471
471
  }
472
472
  j(e) {
473
- this.element.toggleAttribute(this.name, !!e && e !== k);
473
+ this.element.toggleAttribute(this.name, !!e && e !== x);
474
474
  }
475
475
  }
476
476
  class Ti extends Ve {
@@ -478,8 +478,8 @@ class Ti extends Ve {
478
478
  super(e, t, r, n, o), this.type = 5;
479
479
  }
480
480
  _$AI(e, t = this) {
481
- if ((e = se(this, e, t, 0) ?? k) === ae) return;
482
- const r = this._$AH, n = e === k && r !== k || e.capture !== r.capture || e.once !== r.once || e.passive !== r.passive, o = e !== k && (r === k || n);
481
+ if ((e = se(this, e, t, 0) ?? x) === ae) return;
482
+ const r = this._$AH, n = e === x && r !== x || e.capture !== r.capture || e.once !== r.once || e.passive !== r.passive, o = e !== x && (r === x || n);
483
483
  n && this.element.removeEventListener(this.name, this, r), o && this.element.addEventListener(this.name, this, e), this._$AH = e;
484
484
  }
485
485
  handleEvent(e) {
@@ -499,13 +499,13 @@ class Oi {
499
499
  }
500
500
  }
501
501
  const et = me.litHtmlPolyfillSupport;
502
- et == null || et(fe, bt), (me.litHtmlVersions ?? (me.litHtmlVersions = [])).push("3.2.1");
502
+ et == null || et(fe, yt), (me.litHtmlVersions ?? (me.litHtmlVersions = [])).push("3.2.1");
503
503
  const Hi = (i, e, t) => {
504
504
  const r = (t == null ? void 0 : t.renderBefore) ?? e;
505
505
  let n = r._$litPart$;
506
506
  if (n === void 0) {
507
507
  const o = (t == null ? void 0 : t.renderBefore) ?? null;
508
- r._$litPart$ = n = new bt(e.insertBefore(pe(), o), o, void 0, t ?? {});
508
+ r._$litPart$ = n = new yt(e.insertBefore(pe(), o), o, void 0, t ?? {});
509
509
  }
510
510
  return n._$AI(i), n;
511
511
  };
@@ -539,8 +539,8 @@ class j extends ee {
539
539
  return ae;
540
540
  }
541
541
  }
542
- var kr;
543
- j._$litElement$ = !0, j.finalized = !0, (kr = globalThis.litElementHydrateSupport) == null || kr.call(globalThis, { LitElement: j });
542
+ var xr;
543
+ j._$litElement$ = !0, j.finalized = !0, (xr = globalThis.litElementHydrateSupport) == null || xr.call(globalThis, { LitElement: j });
544
544
  const tt = globalThis.litElementPolyfillSupport;
545
545
  tt == null || tt({ LitElement: j });
546
546
  (globalThis.litElementVersions ?? (globalThis.litElementVersions = [])).push("4.1.1");
@@ -579,7 +579,7 @@ const Ui = {}, Yi = (i, e = Ui) => i._$AH = e;
579
579
  */
580
580
  const Xi = ji(class extends Vi {
581
581
  constructor() {
582
- super(...arguments), this.key = k;
582
+ super(...arguments), this.key = x;
583
583
  }
584
584
  render(i, e) {
585
585
  return this.key = i, e;
@@ -607,20 +607,20 @@ const Xi = ji(class extends Vi {
607
607
  i.stopPropagation();
608
608
  const r = Number(i.target.getAttribute("index")), n = e.drawLayer.getSource().getFeatures()[r];
609
609
  e.drawLayer.getSource().removeFeature(n), e.drawnFeatures.splice(r, 1), t.emitDrawnFeatures(), e.requestUpdate();
610
- }, er = {
610
+ }, tr = {
611
611
  duration: 750,
612
612
  padding: [20, 20, 20, 20]
613
- }, tr = {
613
+ }, rr = {
614
614
  type: "FeatureCollection",
615
615
  features: []
616
616
  }, Wi = (i, e) => {
617
617
  const { clickId: t, drawLayer: r, olMap: n, clickInteraction: o } = e, a = o.getId(i);
618
618
  if (t === a) {
619
619
  const l = r.getSource().getExtent();
620
- n.getView().fit(l, er), o.highlightById([]);
620
+ n.getView().fit(l, tr), o.highlightById([]);
621
621
  } else {
622
622
  const l = e.eoxMap.projection || "EPSG:3857", c = e.eoxDrawTools.projection, d = i.clone().getGeometry().transform(c, l).getExtent();
623
- o.highlightById([a]), n.getView().fit(d, er);
623
+ o.highlightById([a]), n.getView().fit(d, tr);
624
624
  }
625
625
  e.requestUpdate();
626
626
  };
@@ -684,7 +684,7 @@ class Pr extends j {
684
684
  render() {
685
685
  var r, n;
686
686
  this.hoverId = (r = this.hoverInteraction) == null ? void 0 : r.selectedFids[0], this.clickId = (n = this.clickInteraction) == null ? void 0 : n.selectedFids[0];
687
- const t = x`<svg
687
+ const t = k`<svg
688
688
  xmlns="http://www.w3.org/2000/svg"
689
689
  viewBox="0 0 24 24"
690
690
  >
@@ -693,18 +693,18 @@ class Pr extends j {
693
693
  d="M9,3V4H4V6H5V19A2,2 0 0,0 7,21H17A2,2 0 0,0 19,19V6H20V4H15V3H9M7,6H17V19H7V6M9,8V17H11V8H9M13,8V17H15V8H13Z"
694
694
  />
695
695
  </svg>`;
696
- return x`
696
+ return k`
697
697
  <ul class="list no-space">
698
698
  ${this.drawnFeatures.map((o, a) => {
699
699
  var g;
700
700
  const s = a + 1, l = Object.values(
701
701
  this.eoxMap.selectInteractions
702
- )[0].getId(o), c = this.hoverId === l, d = this.clickId === l, u = c ? "surface-container-low" : d ? "fill" : k, h = (g = this.featureNameKey) == null ? void 0 : g.split("."), m = o.get(this.featureNameKey) || (h == null ? void 0 : h.reduce((f, _) => f == null ? void 0 : f[_], {
702
+ )[0].getId(o), c = this.hoverId === l, d = this.clickId === l, u = c ? "surface-container-low" : d ? "fill" : x, h = (g = this.featureNameKey) == null ? void 0 : g.split("."), m = o.get(this.featureNameKey) || (h == null ? void 0 : h.reduce((f, _) => f == null ? void 0 : f[_], {
703
703
  ...o.getProperties()
704
704
  })), p = m || `${this.featureName} ${s}`;
705
705
  return Xi(
706
706
  s,
707
- x`
707
+ k`
708
708
  <li
709
709
  class="${u} no-round"
710
710
  @mouseover=${() => this._handleHoverFeature(l)}
@@ -720,7 +720,7 @@ class Pr extends j {
720
720
  class="transparent square small error-text front"
721
721
  @click="${this._handleDelete}"
722
722
  >
723
- ${this.unstyled ? "x" : x`<i class="small">${t}</i>`}
723
+ ${this.unstyled ? "x" : k`<i class="small">${t}</i>`}
724
724
  </button>
725
725
  </li>
726
726
  `
@@ -763,7 +763,7 @@ const Di = {
763
763
  * @api
764
764
  */
765
765
  PROPERTYCHANGE: "propertychange"
766
- }, yt = {
766
+ }, vt = {
767
767
  /**
768
768
  * Generic change event. Triggered when the revision counter is increased.
769
769
  * @event module:ol/events/Event~BaseEvent#change
@@ -790,16 +790,16 @@ class Qi {
790
790
  }
791
791
  function en(i, e, t) {
792
792
  let r, n;
793
- t = t || $r;
793
+ t = t || Er;
794
794
  let o = 0, a = i.length, s = !1;
795
795
  for (; o < a; )
796
796
  r = o + (a - o >> 1), n = +t(i[r], e), n < 0 ? o = r + 1 : (a = r, s = !n);
797
797
  return s ? o : ~o;
798
798
  }
799
- function $r(i, e) {
799
+ function Er(i, e) {
800
800
  return i > e ? 1 : i < e ? -1 : 0;
801
801
  }
802
- function $(i, e) {
802
+ function E(i, e) {
803
803
  const t = Array.isArray(e) ? e : [e], r = t.length;
804
804
  for (let n = 0; n < r; n++)
805
805
  i[i.length] = t[n];
@@ -813,7 +813,7 @@ function tn(i, e) {
813
813
  return !1;
814
814
  return !0;
815
815
  }
816
- function rr() {
816
+ function ir() {
817
817
  }
818
818
  function Ar(i) {
819
819
  let e, t, r;
@@ -904,7 +904,7 @@ class rn extends Qi {
904
904
  if (--a[r] === 0) {
905
905
  let c = s[r];
906
906
  for (delete s[r]; c--; )
907
- this.removeEventListener(r, rr);
907
+ this.removeEventListener(r, ir);
908
908
  delete a[r];
909
909
  }
910
910
  return l;
@@ -945,7 +945,7 @@ class rn extends Qi {
945
945
  if (!r)
946
946
  return;
947
947
  const n = r.indexOf(t);
948
- n !== -1 && (this.pendingRemovals_ && e in this.pendingRemovals_ ? (r[n] = rr, ++this.pendingRemovals_[e]) : (r.splice(n, 1), r.length === 0 && delete this.listeners_[e]));
948
+ n !== -1 && (this.pendingRemovals_ && e in this.pendingRemovals_ ? (r[n] = ir, ++this.pendingRemovals_[e]) : (r.splice(n, 1), r.length === 0 && delete this.listeners_[e]));
949
949
  }
950
950
  }
951
951
  function be(i, e, t, r, n) {
@@ -962,7 +962,7 @@ function be(i, e, t, r, n) {
962
962
  };
963
963
  return i.addEventListener(e, t), o;
964
964
  }
965
- function ir(i, e, t, r) {
965
+ function nr(i, e, t, r) {
966
966
  return be(i, e, t, r, !0);
967
967
  }
968
968
  function Re(i) {
@@ -980,7 +980,7 @@ class Ue extends rn {
980
980
  * @api
981
981
  */
982
982
  changed() {
983
- ++this.revision_, this.dispatchEvent(yt.CHANGE);
983
+ ++this.revision_, this.dispatchEvent(vt.CHANGE);
984
984
  }
985
985
  /**
986
986
  * Get the version number for this object. Each time the object is modified,
@@ -1023,9 +1023,9 @@ class Ue extends rn {
1023
1023
  const n = e.length;
1024
1024
  r = new Array(n);
1025
1025
  for (let o = 0; o < n; ++o)
1026
- r[o] = ir(this, e[o], t);
1026
+ r[o] = nr(this, e[o], t);
1027
1027
  } else
1028
- r = ir(
1028
+ r = nr(
1029
1029
  this,
1030
1030
  /** @type {string} */
1031
1031
  e,
@@ -1073,7 +1073,7 @@ let on = 0;
1073
1073
  function an(i) {
1074
1074
  return i.ol_uid || (i.ol_uid = String(++on));
1075
1075
  }
1076
- class nr extends Gr {
1076
+ class or extends Gr {
1077
1077
  /**
1078
1078
  * @param {string} type The event type.
1079
1079
  * @param {string} key The property name.
@@ -1135,7 +1135,7 @@ class Ir extends Ue {
1135
1135
  */
1136
1136
  notify(e, t) {
1137
1137
  let r;
1138
- r = `change:${e}`, this.hasListener(r) && this.dispatchEvent(new nr(r, e, t)), r = Di.PROPERTYCHANGE, this.hasListener(r) && this.dispatchEvent(new nr(r, e, t));
1138
+ r = `change:${e}`, this.hasListener(r) && this.dispatchEvent(new or(r, e, t)), r = Di.PROPERTYCHANGE, this.hasListener(r) && this.dispatchEvent(new or(r, e, t));
1139
1139
  }
1140
1140
  /**
1141
1141
  * @param {string} key Key name.
@@ -1310,7 +1310,7 @@ class le extends Ir {
1310
1310
  const e = this.getGeometry();
1311
1311
  e && (this.geometryChangeKey_ = be(
1312
1312
  e,
1313
- yt.CHANGE,
1313
+ vt.CHANGE,
1314
1314
  this.handleGeometryChange_,
1315
1315
  this
1316
1316
  )), this.changed();
@@ -1390,12 +1390,12 @@ function W(i, e, t) {
1390
1390
  function Rr(i, e, t) {
1391
1391
  return i[0] <= e && e <= i[2] && i[1] <= t && t <= i[3];
1392
1392
  }
1393
- function or(i, e) {
1393
+ function ar(i, e) {
1394
1394
  const t = i[0], r = i[1], n = i[2], o = i[3], a = e[0], s = e[1];
1395
1395
  let l = w.UNKNOWN;
1396
1396
  return a < t ? l = l | w.LEFT : a > n && (l = l | w.RIGHT), s < r ? l = l | w.BELOW : s > o && (l = l | w.ABOVE), l === w.UNKNOWN && (l = w.INTERSECTING), l;
1397
1397
  }
1398
- function vt() {
1398
+ function kt() {
1399
1399
  return [1 / 0, 1 / 0, -1 / 0, -1 / 0];
1400
1400
  }
1401
1401
  function Nr(i, e, t, r, n) {
@@ -1408,7 +1408,7 @@ function Tr(i, e) {
1408
1408
  const t = i[0], r = i[1];
1409
1409
  return Nr(t, r, t, r, e);
1410
1410
  }
1411
- function kt(i, e, t, r, n) {
1411
+ function _t(i, e, t, r, n) {
1412
1412
  const o = xt(n);
1413
1413
  return Or(o, i, e, t, r);
1414
1414
  }
@@ -1453,7 +1453,7 @@ function bn(i, e) {
1453
1453
  }
1454
1454
  function yn(i, e, t) {
1455
1455
  let r = !1;
1456
- const n = or(i, e), o = or(i, t);
1456
+ const n = ar(i, e), o = ar(i, t);
1457
1457
  if (n === w.INTERSECTING || o === w.INTERSECTING)
1458
1458
  r = !0;
1459
1459
  else {
@@ -1475,22 +1475,22 @@ function V(i, e, t, r) {
1475
1475
  const n = t - i, o = r - e;
1476
1476
  return n * n + o * o;
1477
1477
  }
1478
- function ar(i) {
1478
+ function sr(i) {
1479
1479
  return i * 180 / Math.PI;
1480
1480
  }
1481
1481
  function Ge(i) {
1482
1482
  return i * Math.PI / 180;
1483
1483
  }
1484
- function _t(i, e, t) {
1484
+ function wt(i, e, t) {
1485
1485
  return i + t * (e - i);
1486
1486
  }
1487
- function st(i, e, t) {
1487
+ function lt(i, e, t) {
1488
1488
  if (i >= e && i < t)
1489
1489
  return i;
1490
1490
  const r = t - e;
1491
1491
  return ((i - e) % r + r) % r + e;
1492
1492
  }
1493
- const xn = {
1493
+ const kn = {
1494
1494
  // use the radius of the Normal sphere
1495
1495
  radians: 6370997 / (2 * Math.PI),
1496
1496
  degrees: 2 * Math.PI * 6370997 / 360,
@@ -1498,7 +1498,7 @@ const xn = {
1498
1498
  m: 1,
1499
1499
  "us-ft": 1200 / 3937
1500
1500
  };
1501
- class wt {
1501
+ class zt {
1502
1502
  /**
1503
1503
  * @param {Options} options Projection options.
1504
1504
  */
@@ -1544,7 +1544,7 @@ class wt {
1544
1544
  * @api
1545
1545
  */
1546
1546
  getMetersPerUnit() {
1547
- return this.metersPerUnit_ || xn[this.units_];
1547
+ return this.metersPerUnit_ || kn[this.units_];
1548
1548
  }
1549
1549
  /**
1550
1550
  * Get the world extent for this projection.
@@ -1631,8 +1631,8 @@ class wt {
1631
1631
  return this.getPointResolutionFunc_;
1632
1632
  }
1633
1633
  }
1634
- const Me = 6378137, te = Math.PI * Me, kn = [-te, -te, te, te], _n = [-180, -85, 180, 85], $e = Me * Math.log(Math.tan(Math.PI / 2));
1635
- class D extends wt {
1634
+ const Se = 6378137, te = Math.PI * Se, xn = [-te, -te, te, te], _n = [-180, -85, 180, 85], Ee = Se * Math.log(Math.tan(Math.PI / 2));
1635
+ class D extends zt {
1636
1636
  /**
1637
1637
  * @param {string} code Code.
1638
1638
  */
@@ -1640,16 +1640,16 @@ class D extends wt {
1640
1640
  super({
1641
1641
  code: e,
1642
1642
  units: "m",
1643
- extent: kn,
1643
+ extent: xn,
1644
1644
  global: !0,
1645
1645
  worldExtent: _n,
1646
1646
  getPointResolution: function(t, r) {
1647
- return t / Math.cosh(r[1] / Me);
1647
+ return t / Math.cosh(r[1] / Se);
1648
1648
  }
1649
1649
  });
1650
1650
  }
1651
1651
  }
1652
- const sr = [
1652
+ const lr = [
1653
1653
  new D("EPSG:3857"),
1654
1654
  new D("EPSG:102100"),
1655
1655
  new D("EPSG:102113"),
@@ -1662,8 +1662,8 @@ function wn(i, e, t, r) {
1662
1662
  t = t > 1 ? t : 2, r = r ?? t, e === void 0 && (t > 2 ? e = i.slice() : e = new Array(n));
1663
1663
  for (let o = 0; o < n; o += r) {
1664
1664
  e[o] = te * i[o] / 180;
1665
- let a = Me * Math.log(Math.tan(Math.PI * (+i[o + 1] + 90) / 360));
1666
- a > $e ? a = $e : a < -$e && (a = -$e), e[o + 1] = a;
1665
+ let a = Se * Math.log(Math.tan(Math.PI * (+i[o + 1] + 90) / 360));
1666
+ a > Ee ? a = Ee : a < -Ee && (a = -Ee), e[o + 1] = a;
1667
1667
  }
1668
1668
  return e;
1669
1669
  }
@@ -1671,11 +1671,11 @@ function zn(i, e, t, r) {
1671
1671
  const n = i.length;
1672
1672
  t = t > 1 ? t : 2, r = r ?? t, e === void 0 && (t > 2 ? e = i.slice() : e = new Array(n));
1673
1673
  for (let o = 0; o < n; o += r)
1674
- e[o] = 180 * i[o] / te, e[o + 1] = 360 * Math.atan(Math.exp(i[o + 1] / Me)) / Math.PI - 90;
1674
+ e[o] = 180 * i[o] / te, e[o + 1] = 360 * Math.atan(Math.exp(i[o + 1] / Se)) / Math.PI - 90;
1675
1675
  return e;
1676
1676
  }
1677
- const Cn = 6378137, lr = [-180, -90, 180, 90], Sn = Math.PI * Cn / 180;
1678
- class N extends wt {
1677
+ const Cn = 6378137, cr = [-180, -90, 180, 90], Mn = Math.PI * Cn / 180;
1678
+ class N extends zt {
1679
1679
  /**
1680
1680
  * @param {string} code Code.
1681
1681
  * @param {string} [axisOrientation] Axis orientation.
@@ -1684,15 +1684,15 @@ class N extends wt {
1684
1684
  super({
1685
1685
  code: e,
1686
1686
  units: "degrees",
1687
- extent: lr,
1687
+ extent: cr,
1688
1688
  axisOrientation: t,
1689
1689
  global: !0,
1690
- metersPerUnit: Sn,
1691
- worldExtent: lr
1690
+ metersPerUnit: Mn,
1691
+ worldExtent: cr
1692
1692
  });
1693
1693
  }
1694
1694
  }
1695
- const cr = [
1695
+ const dr = [
1696
1696
  new N("CRS:84"),
1697
1697
  new N("EPSG:4326", "neu"),
1698
1698
  new N("urn:ogc:def:crs:OGC:1.3:CRS84"),
@@ -1701,12 +1701,12 @@ const cr = [
1701
1701
  new N("http://www.opengis.net/gml/srs/epsg.xml#4326", "neu"),
1702
1702
  new N("http://www.opengis.net/def/crs/EPSG/0/4326", "neu")
1703
1703
  ];
1704
- let lt = {};
1705
- function Mn(i) {
1706
- return lt[i] || lt[i.replace(/urn:(x-)?ogc:def:crs:EPSG:(.*:)?(\w+)$/, "EPSG:$3")] || null;
1704
+ let ct = {};
1705
+ function Sn(i) {
1706
+ return ct[i] || ct[i.replace(/urn:(x-)?ogc:def:crs:EPSG:(.*:)?(\w+)$/, "EPSG:$3")] || null;
1707
1707
  }
1708
- function En(i, e) {
1709
- lt[i] = e;
1708
+ function $n(i, e) {
1709
+ ct[i] = e;
1710
1710
  }
1711
1711
  let re = {};
1712
1712
  function ye(i, e, t) {
@@ -1716,21 +1716,21 @@ function ye(i, e, t) {
1716
1716
  function rt(i, e) {
1717
1717
  return i in re && e in re[i] ? re[i][e] : null;
1718
1718
  }
1719
- const Te = 0.9996, S = 669438e-8, Xe = S * S, Be = Xe * S, O = S / (1 - S), dr = Math.sqrt(1 - S), ce = (1 - dr) / (1 + dr), Hr = ce * ce, zt = Hr * ce, Ct = zt * ce, jr = Ct * ce, Vr = 1 - S / 4 - 3 * Xe / 64 - 5 * Be / 256, Pn = 3 * S / 8 + 3 * Xe / 32 + 45 * Be / 1024, $n = 15 * Xe / 256 + 45 * Be / 1024, An = 35 * Be / 3072, Fn = 3 / 2 * ce - 27 / 32 * zt + 269 / 512 * jr, Ln = 21 / 16 * Hr - 55 / 32 * Ct, Gn = 151 / 96 * zt - 417 / 128 * jr, In = 1097 / 512 * Ct, Oe = 6378137;
1719
+ const Te = 0.9996, M = 669438e-8, Xe = M * M, Be = Xe * M, O = M / (1 - M), ur = Math.sqrt(1 - M), ce = (1 - ur) / (1 + ur), Hr = ce * ce, Ct = Hr * ce, Mt = Ct * ce, jr = Mt * ce, Vr = 1 - M / 4 - 3 * Xe / 64 - 5 * Be / 256, Pn = 3 * M / 8 + 3 * Xe / 32 + 45 * Be / 1024, En = 15 * Xe / 256 + 45 * Be / 1024, An = 35 * Be / 3072, Fn = 3 / 2 * ce - 27 / 32 * Ct + 269 / 512 * jr, Ln = 21 / 16 * Hr - 55 / 32 * Mt, Gn = 151 / 96 * Ct - 417 / 128 * jr, In = 1097 / 512 * Mt, Oe = 6378137;
1720
1720
  function Rn(i, e, t) {
1721
- const r = i - 5e5, a = (t.north ? e : e - 1e7) / Te / (Oe * Vr), s = a + Fn * Math.sin(2 * a) + Ln * Math.sin(4 * a) + Gn * Math.sin(6 * a) + In * Math.sin(8 * a), l = Math.sin(s), c = l * l, d = Math.cos(s), u = l / d, h = u * u, m = h * h, p = 1 - S * c, g = Math.sqrt(1 - S * c), f = Oe / g, _ = (1 - S) / p, v = O * d ** 2, E = v * v, z = r / (f * Te), G = z * z, de = G * z, Ht = de * z, jt = Ht * z, bi = jt * z, yi = s - u / _ * (G / 2 - Ht / 24 * (5 + 3 * h + 10 * v - 4 * E - 9 * O)) + bi / 720 * (61 + 90 * h + 298 * v + 45 * m - 252 * O - 3 * E);
1722
- let Ke = (z - de / 6 * (1 + 2 * h + v) + jt / 120 * (5 - 2 * v + 28 * h - 3 * E + 8 * O + 24 * m)) / d;
1723
- return Ke = st(
1721
+ const r = i - 5e5, a = (t.north ? e : e - 1e7) / Te / (Oe * Vr), s = a + Fn * Math.sin(2 * a) + Ln * Math.sin(4 * a) + Gn * Math.sin(6 * a) + In * Math.sin(8 * a), l = Math.sin(s), c = l * l, d = Math.cos(s), u = l / d, h = u * u, m = h * h, p = 1 - M * c, g = Math.sqrt(1 - M * c), f = Oe / g, _ = (1 - M) / p, v = O * d ** 2, $ = v * v, z = r / (f * Te), G = z * z, de = G * z, jt = de * z, Vt = jt * z, bi = Vt * z, yi = s - u / _ * (G / 2 - jt / 24 * (5 + 3 * h + 10 * v - 4 * $ - 9 * O)) + bi / 720 * (61 + 90 * h + 298 * v + 45 * m - 252 * O - 3 * $);
1722
+ let Ke = (z - de / 6 * (1 + 2 * h + v) + Vt / 120 * (5 - 2 * v + 28 * h - 3 * $ + 8 * O + 24 * m)) / d;
1723
+ return Ke = lt(
1724
1724
  Ke + Ge(Ur(t.number)),
1725
1725
  -Math.PI,
1726
1726
  Math.PI
1727
- ), [ar(Ke), ar(yi)];
1727
+ ), [sr(Ke), sr(yi)];
1728
1728
  }
1729
- const ur = -80, hr = 84, Nn = -180, Tn = 180;
1729
+ const hr = -80, mr = 84, Nn = -180, Tn = 180;
1730
1730
  function On(i, e, t) {
1731
- i = st(i, Nn, Tn), e < ur ? e = ur : e > hr && (e = hr);
1732
- const r = Ge(e), n = Math.sin(r), o = Math.cos(r), a = n / o, s = a * a, l = s * s, c = Ge(i), d = Ur(t.number), u = Ge(d), h = Oe / Math.sqrt(1 - S * n ** 2), m = O * o ** 2, p = o * st(c - u, -Math.PI, Math.PI), g = p * p, f = g * p, _ = f * p, v = _ * p, E = v * p, z = Oe * (Vr * r - Pn * Math.sin(2 * r) + $n * Math.sin(4 * r) - An * Math.sin(6 * r)), G = Te * h * (p + f / 6 * (1 - s + m) + v / 120 * (5 - 18 * s + l + 72 * m - 58 * O)) + 5e5;
1733
- let de = Te * (z + h * a * (g / 2 + _ / 24 * (5 - s + 9 * m + 4 * m ** 2) + E / 720 * (61 - 58 * s + l + 600 * m - 330 * O)));
1731
+ i = lt(i, Nn, Tn), e < hr ? e = hr : e > mr && (e = mr);
1732
+ const r = Ge(e), n = Math.sin(r), o = Math.cos(r), a = n / o, s = a * a, l = s * s, c = Ge(i), d = Ur(t.number), u = Ge(d), h = Oe / Math.sqrt(1 - M * n ** 2), m = O * o ** 2, p = o * lt(c - u, -Math.PI, Math.PI), g = p * p, f = g * p, _ = f * p, v = _ * p, $ = v * p, z = Oe * (Vr * r - Pn * Math.sin(2 * r) + En * Math.sin(4 * r) - An * Math.sin(6 * r)), G = Te * h * (p + f / 6 * (1 - s + m) + v / 120 * (5 - 18 * s + l + 72 * m - 58 * O)) + 5e5;
1733
+ let de = Te * (z + h * a * (g / 2 + _ / 24 * (5 - s + 9 * m + 4 * m ** 2) + $ / 720 * (61 - 58 * s + l + 600 * m - 330 * O)));
1734
1734
  return t.north || (de += 1e7), [G, de];
1735
1735
  }
1736
1736
  function Ur(i) {
@@ -1755,7 +1755,7 @@ function Yr(i) {
1755
1755
  let t = 0, r = !1;
1756
1756
  return e > 32700 && e < 32761 ? t = e - 32700 : e > 32600 && e < 32661 && (r = !0, t = e - 32600), t ? { number: t, north: r } : null;
1757
1757
  }
1758
- function mr(i, e) {
1758
+ function pr(i, e) {
1759
1759
  return function(t, r, n, o) {
1760
1760
  const a = t.length;
1761
1761
  n = n > 1 ? n : 2, o = o ?? n, r || (n > 2 ? r = t.slice() : r = new Array(a));
@@ -1767,13 +1767,13 @@ function mr(i, e) {
1767
1767
  };
1768
1768
  }
1769
1769
  function jn(i) {
1770
- return Yr(i) ? new wt({ code: i, units: "m" }) : null;
1770
+ return Yr(i) ? new zt({ code: i, units: "m" }) : null;
1771
1771
  }
1772
1772
  function Vn(i) {
1773
1773
  const e = Yr(i.getCode());
1774
1774
  return e ? {
1775
- forward: mr(On, e),
1776
- inverse: mr(Rn, e)
1775
+ forward: pr(On, e),
1776
+ inverse: pr(Rn, e)
1777
1777
  } : null;
1778
1778
  }
1779
1779
  const Un = [Vn], Yn = [jn];
@@ -1786,16 +1786,16 @@ function St(i, e) {
1786
1786
  e = i.slice();
1787
1787
  return e;
1788
1788
  }
1789
- function ct(i) {
1790
- En(i.getCode(), i), ye(i, i, St);
1789
+ function dt(i) {
1790
+ $n(i.getCode(), i), ye(i, i, St);
1791
1791
  }
1792
1792
  function Xn(i) {
1793
- i.forEach(ct);
1793
+ i.forEach(dt);
1794
1794
  }
1795
1795
  function C(i) {
1796
1796
  if (typeof i != "string")
1797
1797
  return i;
1798
- const e = Mn(i);
1798
+ const e = Sn(i);
1799
1799
  if (e)
1800
1800
  return e;
1801
1801
  for (const t of Yn) {
@@ -1805,7 +1805,7 @@ function C(i) {
1805
1805
  }
1806
1806
  return null;
1807
1807
  }
1808
- function pr(i) {
1808
+ function gr(i) {
1809
1809
  Xn(i), i.forEach(function(e) {
1810
1810
  i.forEach(function(t) {
1811
1811
  e !== t && ye(e, t, St);
@@ -1856,21 +1856,21 @@ function Xr(i, e) {
1856
1856
  l
1857
1857
  ));
1858
1858
  }
1859
- return n && (ct(i), ct(e), ye(i, e, n)), n;
1859
+ return n && (dt(i), dt(e), ye(i, e, n)), n;
1860
1860
  }
1861
1861
  function it(i, e) {
1862
1862
  return function(t, r, n, o) {
1863
1863
  return r = i(t, r, n, o), e(r, r, n, o);
1864
1864
  };
1865
1865
  }
1866
- function dt(i, e) {
1866
+ function ut(i, e) {
1867
1867
  const t = C(i), r = C(e);
1868
1868
  return Xr(t, r);
1869
1869
  }
1870
1870
  function Jn() {
1871
- pr(sr), pr(cr), Bn(
1872
- cr,
1873
- sr,
1871
+ gr(lr), gr(dr), Bn(
1872
+ dr,
1873
+ lr,
1874
1874
  wn,
1875
1875
  zn
1876
1876
  );
@@ -1929,10 +1929,10 @@ function Kn(i, e, t, r, n, o, a) {
1929
1929
  }
1930
1930
  return a && a.length != s && (a.length = s), a;
1931
1931
  }
1932
- const gr = Br(), Dn = [NaN, NaN];
1932
+ const fr = Br(), Dn = [NaN, NaN];
1933
1933
  class Wr extends Ir {
1934
1934
  constructor() {
1935
- super(), this.extent_ = vt(), this.extentRevision_ = -1, this.simplifiedGeometryMaxMinSquaredTolerance = 0, this.simplifiedGeometryRevision = 0, this.simplifyTransformedInternal = Ar(
1935
+ super(), this.extent_ = kt(), this.extentRevision_ = -1, this.simplifiedGeometryMaxMinSquaredTolerance = 0, this.simplifiedGeometryRevision = 0, this.simplifyTransformedInternal = Ar(
1936
1936
  (e, t, r) => {
1937
1937
  if (!r)
1938
1938
  return this.getSimplifiedGeometry(t);
@@ -2131,7 +2131,7 @@ class Wr extends Ir {
2131
2131
  const r = C(e), n = r.getUnits() == "tile-pixels" ? function(o, a, s) {
2132
2132
  const l = r.getExtent(), c = r.getWorldExtent(), d = Ne(c) / Ne(l);
2133
2133
  qr(
2134
- gr,
2134
+ fr,
2135
2135
  c[0],
2136
2136
  c[3],
2137
2137
  d,
@@ -2145,11 +2145,11 @@ class Wr extends Ir {
2145
2145
  0,
2146
2146
  o.length,
2147
2147
  s,
2148
- gr,
2148
+ fr,
2149
2149
  a
2150
- ), h = dt(r, t);
2150
+ ), h = ut(r, t);
2151
2151
  return h ? h(u, u, s) : u;
2152
- } : dt(r, t);
2152
+ } : ut(r, t);
2153
2153
  return this.applyTransform(n), this;
2154
2154
  }
2155
2155
  }
@@ -2164,7 +2164,7 @@ class Z extends Wr {
2164
2164
  * @override
2165
2165
  */
2166
2166
  computeExtent(e) {
2167
- return kt(
2167
+ return _t(
2168
2168
  this.flatCoordinates,
2169
2169
  0,
2170
2170
  this.flatCoordinates.length,
@@ -2242,7 +2242,7 @@ class Z extends Wr {
2242
2242
  * @param {Array<number>} flatCoordinates Flat coordinates.
2243
2243
  */
2244
2244
  setFlatCoordinates(e, t) {
2245
- this.stride = fr(e), this.layout = e, this.flatCoordinates = t;
2245
+ this.stride = br(e), this.layout = e, this.flatCoordinates = t;
2246
2246
  }
2247
2247
  /**
2248
2248
  * @abstract
@@ -2261,7 +2261,7 @@ class Z extends Wr {
2261
2261
  setLayout(e, t, r) {
2262
2262
  let n;
2263
2263
  if (e)
2264
- n = fr(e);
2264
+ n = br(e);
2265
2265
  else {
2266
2266
  for (let o = 0; o < r; ++o) {
2267
2267
  if (t.length === 0) {
@@ -2372,7 +2372,7 @@ function K(i) {
2372
2372
  return i == 2 ? e = "XY" : i == 3 ? e = "XYZ" : i == 4 && (e = "XYZM"), /** @type {import("./Geometry.js").GeometryLayout} */
2373
2373
  e;
2374
2374
  }
2375
- function fr(i) {
2375
+ function br(i) {
2376
2376
  let e;
2377
2377
  return i == "XY" ? e = 2 : i == "XYZ" || i == "XYM" ? e = 3 : i == "XYZM" && (e = 4), /** @type {number} */
2378
2378
  e;
@@ -2390,7 +2390,7 @@ function qe(i, e, t, r) {
2390
2390
  }
2391
2391
  return e;
2392
2392
  }
2393
- function Ee(i, e, t, r, n) {
2393
+ function $e(i, e, t, r, n) {
2394
2394
  n = n || [];
2395
2395
  let o = 0;
2396
2396
  for (let a = 0, s = t.length; a < s; ++a) {
@@ -2408,7 +2408,7 @@ function Zr(i, e, t, r, n) {
2408
2408
  n = n || [];
2409
2409
  let o = 0;
2410
2410
  for (let a = 0, s = t.length; a < s; ++a) {
2411
- const l = Ee(
2411
+ const l = $e(
2412
2412
  i,
2413
2413
  e,
2414
2414
  t[a],
@@ -2421,10 +2421,10 @@ function Zr(i, e, t, r, n) {
2421
2421
  }
2422
2422
  function Kr(i, e, t, r) {
2423
2423
  const n = [];
2424
- let o = vt();
2424
+ let o = kt();
2425
2425
  for (let a = 0, s = t.length; a < s; ++a) {
2426
2426
  const l = t[a];
2427
- o = kt(
2427
+ o = _t(
2428
2428
  i,
2429
2429
  e,
2430
2430
  l[0],
@@ -2460,7 +2460,7 @@ function H(i, e, t, r, n, o) {
2460
2460
  }
2461
2461
  return a !== 0;
2462
2462
  }
2463
- function Mt(i, e, t, r, n, o) {
2463
+ function $t(i, e, t, r, n, o) {
2464
2464
  if (t.length === 0 || !H(i, e, t[0], r, n, o))
2465
2465
  return !1;
2466
2466
  for (let a = 1, s = t.length; a < s; ++a)
@@ -2473,25 +2473,25 @@ function to(i, e, t, r, n, o) {
2473
2473
  return !1;
2474
2474
  for (let a = 0, s = t.length; a < s; ++a) {
2475
2475
  const l = t[a];
2476
- if (Mt(i, e, l, r, n, o))
2476
+ if ($t(i, e, l, r, n, o))
2477
2477
  return !0;
2478
2478
  e = l[l.length - 1];
2479
2479
  }
2480
2480
  return !1;
2481
2481
  }
2482
- function Et(i, e, t, r, n, o, a) {
2482
+ function Pt(i, e, t, r, n, o, a) {
2483
2483
  let s, l, c, d, u, h, m;
2484
2484
  const p = n[o + 1], g = [];
2485
- for (let v = 0, E = t.length; v < E; ++v) {
2485
+ for (let v = 0, $ = t.length; v < $; ++v) {
2486
2486
  const z = t[v];
2487
2487
  for (d = i[z - r], h = i[z - r + 1], s = e; s < z; s += r)
2488
2488
  u = i[s], m = i[s + 1], (p <= h && m <= p || h <= p && p <= m) && (c = (p - h) / (m - h) * (u - d) + d, g.push(c)), d = u, h = m;
2489
2489
  }
2490
2490
  let f = NaN, _ = -1 / 0;
2491
- for (g.sort($r), d = g[0], s = 1, l = g.length; s < l; ++s) {
2491
+ for (g.sort(Er), d = g[0], s = 1, l = g.length; s < l; ++s) {
2492
2492
  u = g[s];
2493
2493
  const v = Math.abs(u - d);
2494
- v > _ && (c = (d + u) / 2, Mt(i, e, t, r, c, p) && (f = c, _ = v)), d = u;
2494
+ v > _ && (c = (d + u) / 2, $t(i, e, t, r, c, p) && (f = c, _ = v)), d = u;
2495
2495
  }
2496
2496
  return isNaN(f) && (f = n[o]), a ? (a.push(f, p, _), a) : [f, p, _];
2497
2497
  }
@@ -2499,7 +2499,7 @@ function Dr(i, e, t, r, n) {
2499
2499
  let o = [];
2500
2500
  for (let a = 0, s = t.length; a < s; ++a) {
2501
2501
  const l = t[a];
2502
- o = Et(
2502
+ o = Pt(
2503
2503
  i,
2504
2504
  e,
2505
2505
  l,
@@ -2530,10 +2530,10 @@ function He(i, e, t, r, n, o, a) {
2530
2530
  }
2531
2531
  a = a > 1 ? a : 2, o = o || new Array(a);
2532
2532
  for (let d = 0; d < a; ++d)
2533
- o[d] = s === void 0 ? NaN : l === void 0 ? i[s + d] : _t(i[s + d], i[s + r + d], l);
2533
+ o[d] = s === void 0 ? NaN : l === void 0 ? i[s + d] : wt(i[s + d], i[s + r + d], l);
2534
2534
  return o;
2535
2535
  }
2536
- function ut(i, e, t, r, n, o) {
2536
+ function ht(i, e, t, r, n, o) {
2537
2537
  if (t == e)
2538
2538
  return null;
2539
2539
  let a;
@@ -2555,7 +2555,7 @@ function ut(i, e, t, r, n, o) {
2555
2555
  a = [];
2556
2556
  for (let h = 0; h < r - 1; ++h)
2557
2557
  a.push(
2558
- _t(
2558
+ wt(
2559
2559
  i[(s - 1) * r + h],
2560
2560
  i[s * r + h],
2561
2561
  u
@@ -2565,7 +2565,7 @@ function ut(i, e, t, r, n, o) {
2565
2565
  }
2566
2566
  function ro(i, e, t, r, n, o, a) {
2567
2567
  if (a)
2568
- return ut(
2568
+ return ht(
2569
2569
  i,
2570
2570
  e,
2571
2571
  t[t.length - 1],
@@ -2584,7 +2584,7 @@ function ro(i, e, t, r, n, o, a) {
2584
2584
  if (n < i[e + r - 1])
2585
2585
  return null;
2586
2586
  if (n <= i[d - 1])
2587
- return ut(
2587
+ return ht(
2588
2588
  i,
2589
2589
  e,
2590
2590
  d,
@@ -2606,7 +2606,7 @@ function io(i, e, t, r) {
2606
2606
  e += r, t -= r;
2607
2607
  }
2608
2608
  }
2609
- function Pt(i, e, t, r) {
2609
+ function Et(i, e, t, r) {
2610
2610
  let n = 0, o = i[t - r], a = i[t - r + 1];
2611
2611
  for (; e < t; e += r) {
2612
2612
  const s = i[e], l = i[e + 1];
@@ -2614,10 +2614,10 @@ function Pt(i, e, t, r) {
2614
2614
  }
2615
2615
  return n === 0 ? void 0 : n > 0;
2616
2616
  }
2617
- function $t(i, e, t, r, n) {
2617
+ function At(i, e, t, r, n) {
2618
2618
  n = n !== void 0 ? n : !1;
2619
2619
  for (let o = 0, a = t.length; o < a; ++o) {
2620
- const s = t[o], l = Pt(
2620
+ const s = t[o], l = Et(
2621
2621
  i,
2622
2622
  e,
2623
2623
  s,
@@ -2635,7 +2635,7 @@ function $t(i, e, t, r, n) {
2635
2635
  function Qr(i, e, t, r, n) {
2636
2636
  for (let o = 0, a = t.length; o < a; ++o) {
2637
2637
  const s = t[o];
2638
- if (!$t(i, e, s, r, n))
2638
+ if (!At(i, e, s, r, n))
2639
2639
  return !1;
2640
2640
  s.length && (e = s[s.length - 1]);
2641
2641
  }
@@ -2644,7 +2644,7 @@ function Qr(i, e, t, r, n) {
2644
2644
  function je(i, e, t, r, n) {
2645
2645
  n = n !== void 0 ? n : !1;
2646
2646
  for (let o = 0, a = t.length; o < a; ++o) {
2647
- const s = t[o], l = Pt(
2647
+ const s = t[o], l = Et(
2648
2648
  i,
2649
2649
  e,
2650
2650
  s,
@@ -2654,7 +2654,7 @@ function je(i, e, t, r, n) {
2654
2654
  }
2655
2655
  return e;
2656
2656
  }
2657
- function ht(i, e, t, r, n) {
2657
+ function mt(i, e, t, r, n) {
2658
2658
  for (let o = 0, a = t.length; o < a; ++o)
2659
2659
  e = je(
2660
2660
  i,
@@ -2669,7 +2669,7 @@ function no(i, e) {
2669
2669
  const t = [];
2670
2670
  let r = 0, n = 0, o;
2671
2671
  for (let a = 0, s = e.length; a < s; ++a) {
2672
- const l = e[a], c = Pt(i, r, l, 2);
2672
+ const l = e[a], c = Et(i, r, l, 2);
2673
2673
  if (o === void 0 && (o = c), c === o)
2674
2674
  t.push(e.slice(n, a + 1));
2675
2675
  else {
@@ -2697,7 +2697,7 @@ function Je(i, e, t, r, n, o, a) {
2697
2697
  let m = 0;
2698
2698
  const p = i[h], g = i[h + 1], f = i[u], _ = i[u + 1];
2699
2699
  for (let v = h + r; v < u; v += r) {
2700
- const E = i[v], z = i[v + 1], G = vn(E, z, p, g, f, _);
2700
+ const $ = i[v], z = i[v + 1], G = vn($, z, p, g, f, _);
2701
2701
  G > m && (d = v, m = G);
2702
2702
  }
2703
2703
  m > n && (l[(d - e) / r] = 1, h + r < d && c.push(h, d), d + r < u && c.push(d, u));
@@ -2747,7 +2747,7 @@ function oo(i, e, t, r, n, o, a) {
2747
2747
  }
2748
2748
  return o[a++] = c, o[a++] = d, a;
2749
2749
  }
2750
- function At(i, e, t, r, n, o, a, s) {
2750
+ function Ft(i, e, t, r, n, o, a, s) {
2751
2751
  for (let l = 0, c = t.length; l < c; ++l) {
2752
2752
  const d = t[l];
2753
2753
  a = oo(
@@ -2765,7 +2765,7 @@ function At(i, e, t, r, n, o, a, s) {
2765
2765
  function ao(i, e, t, r, n, o, a, s) {
2766
2766
  for (let l = 0, c = t.length; l < c; ++l) {
2767
2767
  const d = t[l], u = [];
2768
- a = At(
2768
+ a = Ft(
2769
2769
  i,
2770
2770
  e,
2771
2771
  d,
@@ -2798,7 +2798,7 @@ class Y extends Wr {
2798
2798
  const e = this.geometries_;
2799
2799
  for (let t = 0, r = e.length; t < r; ++t)
2800
2800
  this.changeEventsKeys_.push(
2801
- be(e[t], yt.CHANGE, this.changed, this)
2801
+ be(e[t], vt.CHANGE, this.changed, this)
2802
2802
  );
2803
2803
  }
2804
2804
  /**
@@ -3048,7 +3048,7 @@ function so(i, e, t, r) {
3048
3048
  }
3049
3049
  return n;
3050
3050
  }
3051
- function br(i, e, t, r, n, o, a) {
3051
+ function yr(i, e, t, r, n, o, a) {
3052
3052
  const s = i[e], l = i[e + 1], c = i[t] - s, d = i[t + 1] - l;
3053
3053
  let u;
3054
3054
  if (c === 0 && d === 0)
@@ -3059,7 +3059,7 @@ function br(i, e, t, r, n, o, a) {
3059
3059
  u = t;
3060
3060
  else if (h > 0) {
3061
3061
  for (let m = 0; m < r; ++m)
3062
- a[m] = _t(
3062
+ a[m] = wt(
3063
3063
  i[e + m],
3064
3064
  i[t + m],
3065
3065
  h
@@ -3073,7 +3073,7 @@ function br(i, e, t, r, n, o, a) {
3073
3073
  a[h] = i[u + h];
3074
3074
  a.length = r;
3075
3075
  }
3076
- function Ft(i, e, t, r, n) {
3076
+ function Lt(i, e, t, r, n) {
3077
3077
  let o = i[e], a = i[e + 1];
3078
3078
  for (e += r; e < t; e += r) {
3079
3079
  const s = i[e], l = i[e + 1], c = V(o, a, s, l);
@@ -3081,21 +3081,21 @@ function Ft(i, e, t, r, n) {
3081
3081
  }
3082
3082
  return n;
3083
3083
  }
3084
- function Lt(i, e, t, r, n) {
3084
+ function Gt(i, e, t, r, n) {
3085
3085
  for (let o = 0, a = t.length; o < a; ++o) {
3086
3086
  const s = t[o];
3087
- n = Ft(i, e, s, r, n), e = s;
3087
+ n = Lt(i, e, s, r, n), e = s;
3088
3088
  }
3089
3089
  return n;
3090
3090
  }
3091
3091
  function lo(i, e, t, r, n) {
3092
3092
  for (let o = 0, a = t.length; o < a; ++o) {
3093
3093
  const s = t[o];
3094
- n = Lt(i, e, s, r, n), e = s[s.length - 1];
3094
+ n = Gt(i, e, s, r, n), e = s[s.length - 1];
3095
3095
  }
3096
3096
  return n;
3097
3097
  }
3098
- function Gt(i, e, t, r, n, o, a, s, l, c, d) {
3098
+ function It(i, e, t, r, n, o, a, s, l, c, d) {
3099
3099
  if (e == t)
3100
3100
  return c;
3101
3101
  let u, h;
@@ -3115,7 +3115,7 @@ function Gt(i, e, t, r, n, o, a, s, l, c, d) {
3115
3115
  d = d || [NaN, NaN];
3116
3116
  let m = e + r;
3117
3117
  for (; m < t; )
3118
- if (br(
3118
+ if (yr(
3119
3119
  i,
3120
3120
  m - r,
3121
3121
  m,
@@ -3132,7 +3132,7 @@ function Gt(i, e, t, r, n, o, a, s, l, c, d) {
3132
3132
  (Math.sqrt(h) - Math.sqrt(c)) / n | 0,
3133
3133
  1
3134
3134
  );
3135
- if (o && (br(
3135
+ if (o && (yr(
3136
3136
  i,
3137
3137
  t - r,
3138
3138
  e,
@@ -3147,11 +3147,11 @@ function Gt(i, e, t, r, n, o, a, s, l, c, d) {
3147
3147
  }
3148
3148
  return c;
3149
3149
  }
3150
- function It(i, e, t, r, n, o, a, s, l, c, d) {
3150
+ function Rt(i, e, t, r, n, o, a, s, l, c, d) {
3151
3151
  d = d || [NaN, NaN];
3152
3152
  for (let u = 0, h = t.length; u < h; ++u) {
3153
3153
  const m = t[u];
3154
- c = Gt(
3154
+ c = It(
3155
3155
  i,
3156
3156
  e,
3157
3157
  m,
@@ -3171,7 +3171,7 @@ function co(i, e, t, r, n, o, a, s, l, c, d) {
3171
3171
  d = d || [NaN, NaN];
3172
3172
  for (let u = 0, h = t.length; u < h; ++u) {
3173
3173
  const m = t[u];
3174
- c = It(
3174
+ c = Rt(
3175
3175
  i,
3176
3176
  e,
3177
3177
  m,
@@ -3194,7 +3194,7 @@ function We(i, e, t, r, n) {
3194
3194
  n[o++] = i.slice(a, a + r);
3195
3195
  return n.length = o, n;
3196
3196
  }
3197
- function Rt(i, e, t, r, n) {
3197
+ function Nt(i, e, t, r, n) {
3198
3198
  n = n !== void 0 ? n : [];
3199
3199
  let o = 0;
3200
3200
  for (let a = 0, s = t.length; a < s; ++a) {
@@ -3214,7 +3214,7 @@ function uo(i, e, t, r, n) {
3214
3214
  let o = 0;
3215
3215
  for (let a = 0, s = t.length; a < s; ++a) {
3216
3216
  const l = t[a];
3217
- n[o++] = l.length === 1 && l[0] === e ? [] : Rt(
3217
+ n[o++] = l.length === 1 && l[0] === e ? [] : Nt(
3218
3218
  i,
3219
3219
  e,
3220
3220
  l,
@@ -3260,14 +3260,14 @@ class ve extends Z {
3260
3260
  */
3261
3261
  closestPointXY(e, t, r, n) {
3262
3262
  return n < W(this.getExtent(), e, t) ? n : (this.maxDeltaRevision_ != this.getRevision() && (this.maxDelta_ = Math.sqrt(
3263
- Ft(
3263
+ Lt(
3264
3264
  this.flatCoordinates,
3265
3265
  0,
3266
3266
  this.flatCoordinates.length,
3267
3267
  this.stride,
3268
3268
  0
3269
3269
  )
3270
- ), this.maxDeltaRevision_ = this.getRevision()), Gt(
3270
+ ), this.maxDeltaRevision_ = this.getRevision()), It(
3271
3271
  this.flatCoordinates,
3272
3272
  0,
3273
3273
  this.flatCoordinates.length,
@@ -3371,7 +3371,7 @@ function ii(i, e, t, r, n) {
3371
3371
  return !1;
3372
3372
  }
3373
3373
  function Ze(i, e, t, r, n, o) {
3374
- return o = o ?? Or(vt(), i, e, t, r), fn(n, o) ? o[0] >= n[0] && o[2] <= n[2] || o[1] >= n[1] && o[3] <= n[3] ? !0 : ii(
3374
+ return o = o ?? Or(kt(), i, e, t, r), fn(n, o) ? o[0] >= n[0] && o[2] <= n[2] || o[1] >= n[1] && o[3] <= n[3] ? !0 : ii(
3375
3375
  i,
3376
3376
  e,
3377
3377
  t,
@@ -3488,7 +3488,7 @@ class X extends Z {
3488
3488
  * @api
3489
3489
  */
3490
3490
  appendCoordinate(e) {
3491
- $(this.flatCoordinates, e), this.changed();
3491
+ E(this.flatCoordinates, e), this.changed();
3492
3492
  }
3493
3493
  /**
3494
3494
  * Make a complete copy of the geometry.
@@ -3513,14 +3513,14 @@ class X extends Z {
3513
3513
  */
3514
3514
  closestPointXY(e, t, r, n) {
3515
3515
  return n < W(this.getExtent(), e, t) ? n : (this.maxDeltaRevision_ != this.getRevision() && (this.maxDelta_ = Math.sqrt(
3516
- Ft(
3516
+ Lt(
3517
3517
  this.flatCoordinates,
3518
3518
  0,
3519
3519
  this.flatCoordinates.length,
3520
3520
  this.stride,
3521
3521
  0
3522
3522
  )
3523
- ), this.maxDeltaRevision_ = this.getRevision()), Gt(
3523
+ ), this.maxDeltaRevision_ = this.getRevision()), It(
3524
3524
  this.flatCoordinates,
3525
3525
  0,
3526
3526
  this.flatCoordinates.length,
@@ -3568,7 +3568,7 @@ class X extends Z {
3568
3568
  * @api
3569
3569
  */
3570
3570
  getCoordinateAtM(e, t) {
3571
- return this.layout != "XYM" && this.layout != "XYZM" ? null : (t = t !== void 0 ? t : !1, ut(
3571
+ return this.layout != "XYM" && this.layout != "XYZM" ? null : (t = t !== void 0 ? t : !1, ht(
3572
3572
  this.flatCoordinates,
3573
3573
  0,
3574
3574
  this.flatCoordinates.length,
@@ -3695,7 +3695,7 @@ class X extends Z {
3695
3695
  ), this.changed();
3696
3696
  }
3697
3697
  }
3698
- class xe extends Z {
3698
+ class ke extends Z {
3699
3699
  /**
3700
3700
  * @param {Array<Array<import("../coordinate.js").Coordinate>|LineString>|Array<number>} coordinates
3701
3701
  * Coordinates or LineString geometries. (For internal use, flat coordinates in
@@ -3723,7 +3723,7 @@ class xe extends Z {
3723
3723
  ), o = [], a = [];
3724
3724
  for (let l = 0, c = n.length; l < c; ++l) {
3725
3725
  const d = n[l];
3726
- $(o, d.getFlatCoordinates()), a.push(o.length);
3726
+ E(o, d.getFlatCoordinates()), a.push(o.length);
3727
3727
  }
3728
3728
  const s = n.length === 0 ? this.getLayout() : n[0].getLayout();
3729
3729
  this.setFlatCoordinates(s, o), this.ends_ = a;
@@ -3735,7 +3735,7 @@ class xe extends Z {
3735
3735
  * @api
3736
3736
  */
3737
3737
  appendLineString(e) {
3738
- $(this.flatCoordinates, e.getFlatCoordinates().slice()), this.ends_.push(this.flatCoordinates.length), this.changed();
3738
+ E(this.flatCoordinates, e.getFlatCoordinates().slice()), this.ends_.push(this.flatCoordinates.length), this.changed();
3739
3739
  }
3740
3740
  /**
3741
3741
  * Make a complete copy of the geometry.
@@ -3744,7 +3744,7 @@ class xe extends Z {
3744
3744
  * @override
3745
3745
  */
3746
3746
  clone() {
3747
- const e = new xe(
3747
+ const e = new ke(
3748
3748
  this.flatCoordinates.slice(),
3749
3749
  this.layout,
3750
3750
  this.ends_.slice()
@@ -3761,14 +3761,14 @@ class xe extends Z {
3761
3761
  */
3762
3762
  closestPointXY(e, t, r, n) {
3763
3763
  return n < W(this.getExtent(), e, t) ? n : (this.maxDeltaRevision_ != this.getRevision() && (this.maxDelta_ = Math.sqrt(
3764
- Lt(
3764
+ Gt(
3765
3765
  this.flatCoordinates,
3766
3766
  0,
3767
3767
  this.ends_,
3768
3768
  this.stride,
3769
3769
  0
3770
3770
  )
3771
- ), this.maxDeltaRevision_ = this.getRevision()), It(
3771
+ ), this.maxDeltaRevision_ = this.getRevision()), Rt(
3772
3772
  this.flatCoordinates,
3773
3773
  0,
3774
3774
  this.ends_,
@@ -3821,7 +3821,7 @@ class xe extends Z {
3821
3821
  * @override
3822
3822
  */
3823
3823
  getCoordinates() {
3824
- return Rt(
3824
+ return Nt(
3825
3825
  this.flatCoordinates,
3826
3826
  0,
3827
3827
  this.ends_,
@@ -3881,7 +3881,7 @@ class xe extends Z {
3881
3881
  o,
3882
3882
  0.5
3883
3883
  );
3884
- $(e, c), r = l;
3884
+ E(e, c), r = l;
3885
3885
  }
3886
3886
  return e;
3887
3887
  }
@@ -3902,7 +3902,7 @@ class xe extends Z {
3902
3902
  t,
3903
3903
  0,
3904
3904
  r
3905
- ), new xe(t, "XY", r);
3905
+ ), new ke(t, "XY", r);
3906
3906
  }
3907
3907
  /**
3908
3908
  * Get the type of this geometry.
@@ -3938,7 +3938,7 @@ class xe extends Z {
3938
3938
  */
3939
3939
  setCoordinates(e, t) {
3940
3940
  this.setLayout(t, e, 2), this.flatCoordinates || (this.flatCoordinates = []);
3941
- const r = Ee(
3941
+ const r = $e(
3942
3942
  this.flatCoordinates,
3943
3943
  0,
3944
3944
  e,
@@ -4064,7 +4064,7 @@ class Pe extends Z {
4064
4064
  * @api
4065
4065
  */
4066
4066
  appendPoint(e) {
4067
- $(this.flatCoordinates, e.getFlatCoordinates()), this.changed();
4067
+ E(this.flatCoordinates, e.getFlatCoordinates()), this.changed();
4068
4068
  }
4069
4069
  /**
4070
4070
  * Make a complete copy of the geometry.
@@ -4220,7 +4220,7 @@ class q extends Z {
4220
4220
  * @api
4221
4221
  */
4222
4222
  appendLinearRing(e) {
4223
- this.flatCoordinates ? $(this.flatCoordinates, e.getFlatCoordinates()) : this.flatCoordinates = e.getFlatCoordinates().slice(), this.ends_.push(this.flatCoordinates.length), this.changed();
4223
+ this.flatCoordinates ? E(this.flatCoordinates, e.getFlatCoordinates()) : this.flatCoordinates = e.getFlatCoordinates().slice(), this.ends_.push(this.flatCoordinates.length), this.changed();
4224
4224
  }
4225
4225
  /**
4226
4226
  * Make a complete copy of the geometry.
@@ -4246,14 +4246,14 @@ class q extends Z {
4246
4246
  */
4247
4247
  closestPointXY(e, t, r, n) {
4248
4248
  return n < W(this.getExtent(), e, t) ? n : (this.maxDeltaRevision_ != this.getRevision() && (this.maxDelta_ = Math.sqrt(
4249
- Lt(
4249
+ Gt(
4250
4250
  this.flatCoordinates,
4251
4251
  0,
4252
4252
  this.ends_,
4253
4253
  this.stride,
4254
4254
  0
4255
4255
  )
4256
- ), this.maxDeltaRevision_ = this.getRevision()), It(
4256
+ ), this.maxDeltaRevision_ = this.getRevision()), Rt(
4257
4257
  this.flatCoordinates,
4258
4258
  0,
4259
4259
  this.ends_,
@@ -4273,7 +4273,7 @@ class q extends Z {
4273
4273
  * @override
4274
4274
  */
4275
4275
  containsXY(e, t) {
4276
- return Mt(
4276
+ return $t(
4277
4277
  this.getOrientedFlatCoordinates(),
4278
4278
  0,
4279
4279
  this.ends_,
@@ -4311,7 +4311,7 @@ class q extends Z {
4311
4311
  */
4312
4312
  getCoordinates(e) {
4313
4313
  let t;
4314
- return e !== void 0 ? (t = this.getOrientedFlatCoordinates().slice(), je(t, 0, this.ends_, this.stride, e)) : t = this.flatCoordinates, Rt(t, 0, this.ends_, this.stride);
4314
+ return e !== void 0 ? (t = this.getOrientedFlatCoordinates().slice(), je(t, 0, this.ends_, this.stride, e)) : t = this.flatCoordinates, Nt(t, 0, this.ends_, this.stride);
4315
4315
  }
4316
4316
  /**
4317
4317
  * @return {Array<number>} Ends.
@@ -4325,7 +4325,7 @@ class q extends Z {
4325
4325
  getFlatInteriorPoint() {
4326
4326
  if (this.flatInteriorPointRevision_ != this.getRevision()) {
4327
4327
  const e = Ye(this.getExtent());
4328
- this.flatInteriorPoint_ = Et(
4328
+ this.flatInteriorPoint_ = Pt(
4329
4329
  this.getOrientedFlatCoordinates(),
4330
4330
  0,
4331
4331
  this.ends_,
@@ -4400,7 +4400,7 @@ class q extends Z {
4400
4400
  getOrientedFlatCoordinates() {
4401
4401
  if (this.orientedRevision_ != this.getRevision()) {
4402
4402
  const e = this.flatCoordinates;
4403
- $t(e, 0, this.ends_, this.stride) ? this.orientedFlatCoordinates_ = e : (this.orientedFlatCoordinates_ = e.slice(), this.orientedFlatCoordinates_.length = je(
4403
+ At(e, 0, this.ends_, this.stride) ? this.orientedFlatCoordinates_ = e : (this.orientedFlatCoordinates_ = e.slice(), this.orientedFlatCoordinates_.length = je(
4404
4404
  this.orientedFlatCoordinates_,
4405
4405
  0,
4406
4406
  this.ends_,
@@ -4420,7 +4420,7 @@ class q extends Z {
4420
4420
  */
4421
4421
  getSimplifiedGeometryInternal(e) {
4422
4422
  const t = [], r = [];
4423
- return t.length = At(
4423
+ return t.length = Ft(
4424
4424
  this.flatCoordinates,
4425
4425
  0,
4426
4426
  this.ends_,
@@ -4465,7 +4465,7 @@ class q extends Z {
4465
4465
  */
4466
4466
  setCoordinates(e, t) {
4467
4467
  this.setLayout(t, e, 2), this.flatCoordinates || (this.flatCoordinates = []);
4468
- const r = Ee(
4468
+ const r = $e(
4469
4469
  this.flatCoordinates,
4470
4470
  0,
4471
4471
  e,
@@ -4475,7 +4475,7 @@ class q extends Z {
4475
4475
  this.flatCoordinates.length = r.length === 0 ? 0 : r[r.length - 1], this.changed();
4476
4476
  }
4477
4477
  }
4478
- class ke extends Z {
4478
+ class xe extends Z {
4479
4479
  /**
4480
4480
  * @param {Array<Array<Array<import("../coordinate.js").Coordinate>>|Polygon>|Array<number>} coordinates Coordinates.
4481
4481
  * For internal use, flat coordinates in combination with `layout` and `endss` are also accepted.
@@ -4492,7 +4492,7 @@ class ke extends Z {
4492
4492
  const c = n[s], d = o.length, u = c.getEnds();
4493
4493
  for (let h = 0, m = u.length; h < m; ++h)
4494
4494
  u[h] += d;
4495
- $(o, c.getFlatCoordinates()), a.push(u);
4495
+ E(o, c.getFlatCoordinates()), a.push(u);
4496
4496
  }
4497
4497
  t = n.length === 0 ? this.getLayout() : n[0].getLayout(), e = o, r = a;
4498
4498
  }
@@ -4517,7 +4517,7 @@ class ke extends Z {
4517
4517
  this.flatCoordinates = e.getFlatCoordinates().slice(), t = e.getEnds().slice(), this.endss_.push();
4518
4518
  else {
4519
4519
  const r = this.flatCoordinates.length;
4520
- $(this.flatCoordinates, e.getFlatCoordinates()), t = e.getEnds().slice();
4520
+ E(this.flatCoordinates, e.getFlatCoordinates()), t = e.getEnds().slice();
4521
4521
  for (let n = 0, o = t.length; n < o; ++n)
4522
4522
  t[n] += r;
4523
4523
  }
@@ -4533,7 +4533,7 @@ class ke extends Z {
4533
4533
  const e = this.endss_.length, t = new Array(e);
4534
4534
  for (let n = 0; n < e; ++n)
4535
4535
  t[n] = this.endss_[n].slice();
4536
- const r = new ke(
4536
+ const r = new xe(
4537
4537
  this.flatCoordinates.slice(),
4538
4538
  this.layout,
4539
4539
  t
@@ -4615,7 +4615,7 @@ class ke extends Z {
4615
4615
  */
4616
4616
  getCoordinates(e) {
4617
4617
  let t;
4618
- return e !== void 0 ? (t = this.getOrientedFlatCoordinates().slice(), ht(
4618
+ return e !== void 0 ? (t = this.getOrientedFlatCoordinates().slice(), mt(
4619
4619
  t,
4620
4620
  0,
4621
4621
  this.endss_,
@@ -4673,7 +4673,7 @@ class ke extends Z {
4673
4673
  getOrientedFlatCoordinates() {
4674
4674
  if (this.orientedRevision_ != this.getRevision()) {
4675
4675
  const e = this.flatCoordinates;
4676
- Qr(e, 0, this.endss_, this.stride) ? this.orientedFlatCoordinates_ = e : (this.orientedFlatCoordinates_ = e.slice(), this.orientedFlatCoordinates_.length = ht(
4676
+ Qr(e, 0, this.endss_, this.stride) ? this.orientedFlatCoordinates_ = e : (this.orientedFlatCoordinates_ = e.slice(), this.orientedFlatCoordinates_.length = mt(
4677
4677
  this.orientedFlatCoordinates_,
4678
4678
  0,
4679
4679
  this.endss_,
@@ -4702,7 +4702,7 @@ class ke extends Z {
4702
4702
  t,
4703
4703
  0,
4704
4704
  r
4705
- ), new ke(t, "XY", r);
4705
+ ), new xe(t, "XY", r);
4706
4706
  }
4707
4707
  /**
4708
4708
  * Return the polygon at the specified index.
@@ -4802,7 +4802,7 @@ class ke extends Z {
4802
4802
  this.changed();
4803
4803
  }
4804
4804
  }
4805
- const yr = Br();
4805
+ const vr = Br();
4806
4806
  class J {
4807
4807
  /**
4808
4808
  * @param {Type} type Geometry type.
@@ -4831,7 +4831,7 @@ class J {
4831
4831
  * @api
4832
4832
  */
4833
4833
  getExtent() {
4834
- return this.extent_ || (this.extent_ = this.type_ === "Point" ? Tr(this.flatCoordinates_) : kt(
4834
+ return this.extent_ || (this.extent_ = this.type_ === "Point" ? Tr(this.flatCoordinates_) : _t(
4835
4835
  this.flatCoordinates_,
4836
4836
  0,
4837
4837
  this.flatCoordinates_.length,
@@ -4844,7 +4844,7 @@ class J {
4844
4844
  getFlatInteriorPoint() {
4845
4845
  if (!this.flatInteriorPoints_) {
4846
4846
  const e = Ye(this.getExtent());
4847
- this.flatInteriorPoints_ = Et(
4847
+ this.flatInteriorPoints_ = Pt(
4848
4848
  this.flatCoordinates_,
4849
4849
  0,
4850
4850
  this.ends_,
@@ -4897,7 +4897,7 @@ class J {
4897
4897
  );
4898
4898
  for (let n = 0, o = r.length; n < o; ++n) {
4899
4899
  const a = r[n], s = He(e, t, a, 2, 0.5);
4900
- $(this.flatMidpoints_, s), t = a;
4900
+ E(this.flatMidpoints_, s), t = a;
4901
4901
  }
4902
4902
  }
4903
4903
  return this.flatMidpoints_;
@@ -4989,7 +4989,7 @@ class J {
4989
4989
  if (t && r) {
4990
4990
  const n = Ne(r) / Ne(t);
4991
4991
  qr(
4992
- yr,
4992
+ vr,
4993
4993
  r[0],
4994
4994
  r[3],
4995
4995
  n,
@@ -5002,7 +5002,7 @@ class J {
5002
5002
  0,
5003
5003
  this.flatCoordinates_.length,
5004
5004
  2,
5005
- yr,
5005
+ vr,
5006
5006
  this.flatCoordinates_
5007
5007
  );
5008
5008
  }
@@ -5073,7 +5073,7 @@ class J {
5073
5073
  );
5074
5074
  break;
5075
5075
  case "Polygon":
5076
- n = [], r.length = At(
5076
+ n = [], r.length = Ft(
5077
5077
  r,
5078
5078
  0,
5079
5079
  this.simplifiedGeometry_.ends_,
@@ -5229,7 +5229,7 @@ function _e(i, e, t) {
5229
5229
  e && (o = /** @type {T} */
5230
5230
  i.clone());
5231
5231
  const a = e ? r : n, s = e ? n : r;
5232
- a.getUnits() === "tile-pixels" ? o.transform(a, s) : o.applyTransform(dt(a, s));
5232
+ a.getUnits() === "tile-pixels" ? o.transform(a, s) : o.applyTransform(ut(a, s));
5233
5233
  }
5234
5234
  if (e && t && /** @type {WriteOptions} */
5235
5235
  t.decimals !== void 0) {
@@ -5252,11 +5252,11 @@ const fo = {
5252
5252
  LineString: X,
5253
5253
  Polygon: q,
5254
5254
  MultiPoint: Pe,
5255
- MultiLineString: xe,
5256
- MultiPolygon: ke
5255
+ MultiLineString: ke,
5256
+ MultiPolygon: xe
5257
5257
  };
5258
5258
  function bo(i, e, t) {
5259
- return Array.isArray(e[0]) ? (Qr(i, 0, e, t) || (i = i.slice(), ht(i, 0, e, t)), i) : ($t(i, 0, e, t) || (i = i.slice(), je(i, 0, e, t)), i);
5259
+ return Array.isArray(e[0]) ? (Qr(i, 0, e, t) || (i = i.slice(), mt(i, 0, e, t)), i) : (At(i, 0, e, t) || (i = i.slice(), je(i, 0, e, t)), i);
5260
5260
  }
5261
5261
  function ai(i, e) {
5262
5262
  var o;
@@ -5282,12 +5282,12 @@ function ai(i, e) {
5282
5282
  e
5283
5283
  );
5284
5284
  }
5285
- function Nt(i, e) {
5285
+ function Tt(i, e) {
5286
5286
  if (!i)
5287
5287
  return null;
5288
5288
  if (Array.isArray(i)) {
5289
5289
  const r = i.map(
5290
- (n) => Nt(n, e)
5290
+ (n) => Tt(n, e)
5291
5291
  );
5292
5292
  return new Y(r);
5293
5293
  }
@@ -5507,7 +5507,7 @@ class vo extends yo {
5507
5507
  ),
5508
5508
  properties: null
5509
5509
  };
5510
- const n = Tt(r.geometry);
5510
+ const n = Ot(r.geometry);
5511
5511
  if (this.featureClass === J)
5512
5512
  return (
5513
5513
  /** @type {FeatureType|Array<FeatureType>} */
@@ -5521,7 +5521,7 @@ class vo extends yo {
5521
5521
  )
5522
5522
  );
5523
5523
  const o = new le();
5524
- return this.geometryName_ ? o.setGeometryName(this.geometryName_) : this.extractGeometryName_ && r.geometry_name && o.setGeometryName(r.geometry_name), o.setGeometry(Nt(n, t)), "id" in r && o.setId(r.id), r.properties && o.setProperties(r.properties, !0), /** @type {FeatureType|Array<FeatureType>} */
5524
+ return this.geometryName_ ? o.setGeometryName(this.geometryName_) : this.extractGeometryName_ && r.geometry_name && o.setGeometryName(r.geometry_name), o.setGeometry(Tt(n, t)), "id" in r && o.setId(r.id), r.properties && o.setProperties(r.properties, !0), /** @type {FeatureType|Array<FeatureType>} */
5525
5525
  o;
5526
5526
  }
5527
5527
  /**
@@ -5566,7 +5566,7 @@ class vo extends yo {
5566
5566
  * @override
5567
5567
  */
5568
5568
  readGeometryFromObject(e, t) {
5569
- return xo(e, t);
5569
+ return ko(e, t);
5570
5570
  }
5571
5571
  /**
5572
5572
  * @param {Object} object Object.
@@ -5610,7 +5610,7 @@ class vo extends yo {
5610
5610
  if (n !== void 0 && (r.id = n), !e.hasProperties())
5611
5611
  return r;
5612
5612
  const o = e.getProperties(), a = e.getGeometry();
5613
- return a && (r.geometry = mt(a, t), delete o[e.getGeometryName()]), Lr(o) || (r.properties = o), r;
5613
+ return a && (r.geometry = pt(a, t), delete o[e.getGeometryName()]), Lr(o) || (r.properties = o), r;
5614
5614
  }
5615
5615
  /**
5616
5616
  * Encode an array of features as a GeoJSON object.
@@ -5641,10 +5641,10 @@ class vo extends yo {
5641
5641
  * @override
5642
5642
  */
5643
5643
  writeGeometryObject(e, t) {
5644
- return mt(e, this.adaptOptions(t));
5644
+ return pt(e, this.adaptOptions(t));
5645
5645
  }
5646
5646
  }
5647
- function Tt(i, e) {
5647
+ function Ot(i, e) {
5648
5648
  if (!i)
5649
5649
  return null;
5650
5650
  let t;
@@ -5664,7 +5664,7 @@ function Tt(i, e) {
5664
5664
  break;
5665
5665
  }
5666
5666
  case "Polygon": {
5667
- t = Mo(
5667
+ t = So(
5668
5668
  /** @type {GeoJSONPolygon} */
5669
5669
  i
5670
5670
  );
@@ -5685,14 +5685,14 @@ function Tt(i, e) {
5685
5685
  break;
5686
5686
  }
5687
5687
  case "MultiPolygon": {
5688
- t = So(
5688
+ t = Mo(
5689
5689
  /** @type {GeoJSONMultiPolygon} */
5690
5690
  i
5691
5691
  );
5692
5692
  break;
5693
5693
  }
5694
5694
  case "GeometryCollection": {
5695
- t = ko(
5695
+ t = xo(
5696
5696
  /** @type {GeoJSONGeometryCollection} */
5697
5697
  i
5698
5698
  );
@@ -5703,18 +5703,18 @@ function Tt(i, e) {
5703
5703
  }
5704
5704
  return t;
5705
5705
  }
5706
- function xo(i, e) {
5707
- const t = Tt(i);
5708
- return Nt(t, e);
5709
- }
5710
5706
  function ko(i, e) {
5707
+ const t = Ot(i);
5708
+ return Tt(t, e);
5709
+ }
5710
+ function xo(i, e) {
5711
5711
  return i.geometries.map(
5712
5712
  /**
5713
5713
  * @param {GeoJSONGeometry} geometry Geometry.
5714
5714
  * @return {import("./Feature.js").GeometryObject} geometry Geometry.
5715
5715
  */
5716
5716
  function(r) {
5717
- return Tt(r);
5717
+ return Ot(r);
5718
5718
  }
5719
5719
  );
5720
5720
  }
@@ -5738,7 +5738,7 @@ function wo(i) {
5738
5738
  }
5739
5739
  function zo(i) {
5740
5740
  var o, a;
5741
- const e = i.coordinates, t = ((a = (o = e[0]) == null ? void 0 : o[0]) == null ? void 0 : a.length) || 2, r = [], n = Ee(r, 0, e, t);
5741
+ const e = i.coordinates, t = ((a = (o = e[0]) == null ? void 0 : o[0]) == null ? void 0 : a.length) || 2, r = [], n = $e(r, 0, e, t);
5742
5742
  return {
5743
5743
  type: "MultiLineString",
5744
5744
  flatCoordinates: r,
@@ -5755,7 +5755,7 @@ function Co(i) {
5755
5755
  layout: K(((t = e[0]) == null ? void 0 : t.length) || 2)
5756
5756
  };
5757
5757
  }
5758
- function So(i) {
5758
+ function Mo(i) {
5759
5759
  var o, a;
5760
5760
  const e = i.coordinates, t = [], r = ((a = (o = e[0]) == null ? void 0 : o[0]) == null ? void 0 : a[0].length) || 2, n = Zr(
5761
5761
  t,
@@ -5770,9 +5770,9 @@ function So(i) {
5770
5770
  layout: K(r)
5771
5771
  };
5772
5772
  }
5773
- function Mo(i) {
5773
+ function So(i) {
5774
5774
  var o, a;
5775
- const e = i.coordinates, t = [], r = (a = (o = e[0]) == null ? void 0 : o[0]) == null ? void 0 : a.length, n = Ee(t, 0, e, r);
5775
+ const e = i.coordinates, t = [], r = (a = (o = e[0]) == null ? void 0 : o[0]) == null ? void 0 : a.length, n = $e(t, 0, e, r);
5776
5776
  return {
5777
5777
  type: "Polygon",
5778
5778
  flatCoordinates: t,
@@ -5780,7 +5780,7 @@ function Mo(i) {
5780
5780
  layout: K(r)
5781
5781
  };
5782
5782
  }
5783
- function mt(i, e) {
5783
+ function pt(i, e) {
5784
5784
  i = _e(i, !0, e);
5785
5785
  const t = i.getType();
5786
5786
  let r;
@@ -5815,7 +5815,7 @@ function mt(i, e) {
5815
5815
  break;
5816
5816
  }
5817
5817
  case "MultiLineString": {
5818
- r = $o(
5818
+ r = Eo(
5819
5819
  /** @type {import("../geom/MultiLineString.js").default} */
5820
5820
  i
5821
5821
  );
@@ -5830,7 +5830,7 @@ function mt(i, e) {
5830
5830
  break;
5831
5831
  }
5832
5832
  case "GeometryCollection": {
5833
- r = Eo(
5833
+ r = $o(
5834
5834
  /** @type {import("../geom/GeometryCollection.js").default} */
5835
5835
  i,
5836
5836
  e
@@ -5849,11 +5849,11 @@ function mt(i, e) {
5849
5849
  }
5850
5850
  return r;
5851
5851
  }
5852
- function Eo(i, e) {
5852
+ function $o(i, e) {
5853
5853
  return e = Object.assign({}, e), delete e.featureProjection, {
5854
5854
  type: "GeometryCollection",
5855
5855
  geometries: i.getGeometriesArray().map(function(r) {
5856
- return mt(r, e);
5856
+ return pt(r, e);
5857
5857
  })
5858
5858
  };
5859
5859
  }
@@ -5863,7 +5863,7 @@ function Po(i, e) {
5863
5863
  coordinates: i.getCoordinates()
5864
5864
  };
5865
5865
  }
5866
- function $o(i, e) {
5866
+ function Eo(i, e) {
5867
5867
  return {
5868
5868
  type: "MultiLineString",
5869
5869
  coordinates: i.getCoordinates()
@@ -6076,8 +6076,8 @@ const No = {
6076
6076
  LINESTRING: X,
6077
6077
  POLYGON: q,
6078
6078
  MULTIPOINT: Pe,
6079
- MULTILINESTRING: xe,
6080
- MULTIPOLYGON: ke
6079
+ MULTILINESTRING: ke,
6080
+ MULTIPOLYGON: xe
6081
6081
  }, si = "EMPTY", li = "Z", ci = "M", To = "ZM", y = {
6082
6082
  START: 0,
6083
6083
  TEXT: 1,
@@ -6583,7 +6583,7 @@ function Yo(i) {
6583
6583
  e.push(hi(t[r]));
6584
6584
  return e.join(",");
6585
6585
  }
6586
- function Ot(i) {
6586
+ function Ht(i) {
6587
6587
  const e = i.getCoordinates(), t = [];
6588
6588
  for (let r = 0, n = e.length; r < n; ++r)
6589
6589
  t.push(e[r].join(" "));
@@ -6592,13 +6592,13 @@ function Ot(i) {
6592
6592
  function Xo(i) {
6593
6593
  const e = [], t = i.getLineStrings();
6594
6594
  for (let r = 0, n = t.length; r < n; ++r)
6595
- e.push("(" + Ot(t[r]) + ")");
6595
+ e.push("(" + Ht(t[r]) + ")");
6596
6596
  return e.join(",");
6597
6597
  }
6598
6598
  function ui(i) {
6599
6599
  const e = [], t = i.getLinearRings();
6600
6600
  for (let r = 0, n = t.length; r < n; ++r)
6601
- e.push("(" + Ot(t[r]) + ")");
6601
+ e.push("(" + Ht(t[r]) + ")");
6602
6602
  return e.join(",");
6603
6603
  }
6604
6604
  function Bo(i) {
@@ -6614,7 +6614,7 @@ function qo(i) {
6614
6614
  }
6615
6615
  const Jo = {
6616
6616
  Point: di,
6617
- LineString: Ot,
6617
+ LineString: Ht,
6618
6618
  Polygon: ui,
6619
6619
  MultiPoint: Uo,
6620
6620
  MultiLineString: Xo,
@@ -6673,13 +6673,13 @@ class mi extends j {
6673
6673
  render() {
6674
6674
  this.updateButtonStates();
6675
6675
  const t = this.currentlyDrawing ? "drawing" : "draw", r = {
6676
- Polygon: x`<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24">
6676
+ Polygon: k`<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24">
6677
6677
  <title>shape-polygon-plus</title>
6678
6678
  <path
6679
6679
  d="M17,15.7V13H19V17L10,21L3,14L7,5H11V7H8.3L5.4,13.6L10.4,18.6L17,15.7M22,5V7H19V10H17V7H14V5H17V2H19V5H22Z"
6680
6680
  />
6681
6681
  </svg>`,
6682
- Point: x`
6682
+ Point: k`
6683
6683
  <svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24">
6684
6684
  <title>vector-point-plus</title>
6685
6685
  <path
@@ -6687,7 +6687,7 @@ class mi extends j {
6687
6687
  />
6688
6688
  </svg>
6689
6689
  `,
6690
- Circle: x`
6690
+ Circle: k`
6691
6691
  <svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24">
6692
6692
  <title>shape-circle-plus</title>
6693
6693
  <path
@@ -6695,7 +6695,7 @@ class mi extends j {
6695
6695
  />
6696
6696
  </svg>
6697
6697
  `,
6698
- LineString: x`
6698
+ LineString: k`
6699
6699
  <svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24">
6700
6700
  <title>vector-polyline-plus</title>
6701
6701
  <path
@@ -6703,7 +6703,7 @@ class mi extends j {
6703
6703
  />
6704
6704
  </svg>
6705
6705
  `,
6706
- Box: x`
6706
+ Box: k`
6707
6707
  <svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24">
6708
6708
  <title>shape-rectangle-plus</title>
6709
6709
  <path
@@ -6711,7 +6711,7 @@ class mi extends j {
6711
6711
  />
6712
6712
  </svg>
6713
6713
  `
6714
- }, n = x`<svg
6714
+ }, n = k`<svg
6715
6715
  xmlns="http://www.w3.org/2000/svg"
6716
6716
  viewBox="0 0 24 24"
6717
6717
  >
@@ -6719,7 +6719,7 @@ class mi extends j {
6719
6719
  <path
6720
6720
  d="M10.76,8.69A0.76,0.76 0 0,0 10,9.45V20.9C10,21.32 10.34,21.66 10.76,21.66C10.95,21.66 11.11,21.6 11.24,21.5L13.15,19.95L14.81,23.57C14.94,23.84 15.21,24 15.5,24C15.61,24 15.72,24 15.83,23.92L18.59,22.64C18.97,22.46 19.15,22 18.95,21.63L17.28,18L19.69,17.55C19.85,17.5 20,17.43 20.12,17.29C20.39,16.97 20.35,16.5 20,16.21L11.26,8.86L11.25,8.87C11.12,8.76 10.95,8.69 10.76,8.69M15,10V8H20V10H15M13.83,4.76L16.66,1.93L18.07,3.34L15.24,6.17L13.83,4.76M10,0H12V5H10V0M3.93,14.66L6.76,11.83L8.17,13.24L5.34,16.07L3.93,14.66M3.93,3.34L5.34,1.93L8.17,4.76L6.76,6.17L3.93,3.34M7,10H2V8H7V10"
6721
6721
  />
6722
- </svg>`, o = x`<svg
6722
+ </svg>`, o = k`<svg
6723
6723
  xmlns="http://www.w3.org/2000/svg"
6724
6724
  viewBox="0 0 24 24"
6725
6725
  >
@@ -6727,7 +6727,7 @@ class mi extends j {
6727
6727
  <path
6728
6728
  d="M9,3V4H4V6H5V19A2,2 0 0,0 7,21H17A2,2 0 0,0 19,19V6H20V4H15V3H9M7,6H17V19H7V6M9,8V17H11V8H9M13,8V17H15V8H13Z"
6729
6729
  />
6730
- </svg>`, a = x`<svg
6730
+ </svg>`, a = k`<svg
6731
6731
  xmlns="http://www.w3.org/2000/svg"
6732
6732
  viewBox="0 0 24 24"
6733
6733
  >
@@ -6735,7 +6735,7 @@ class mi extends j {
6735
6735
  <path
6736
6736
  d="M14.06,9L15,9.94L5.92,19H5V18.08L14.06,9M17.66,3C17.41,3 17.15,3.1 16.96,3.29L15.13,5.12L18.88,8.87L20.71,7.04C21.1,6.65 21.1,6 20.71,5.63L18.37,3.29C18.17,3.09 17.92,3 17.66,3M14.06,6.19L3,17.25V21H6.75L17.81,9.94L14.06,6.19Z"
6737
6737
  />
6738
- </svg>`, s = x`<svg
6738
+ </svg>`, s = k`<svg
6739
6739
  xmlns="http://www.w3.org/2000/svg"
6740
6740
  viewBox="0 0 24 24"
6741
6741
  >
@@ -6743,7 +6743,7 @@ class mi extends j {
6743
6743
  <path
6744
6744
  d="M14,12L10,8V11H2V13H10V16M20,18V6C20,4.89 19.1,4 18,4H6A2,2 0 0,0 4,6V9H6V6H18V18H6V15H4V18A2,2 0 0,0 6,20H18A2,2 0 0,0 20,18Z"
6745
6745
  />
6746
- </svg>`, l = x`<svg
6746
+ </svg>`, l = k`<svg
6747
6747
  xmlns="http://www.w3.org/2000/svg"
6748
6748
  viewBox="0 0 24 24"
6749
6749
  >
@@ -6752,7 +6752,7 @@ class mi extends j {
6752
6752
  d="M19,21H8V7H19M19,5H8A2,2 0 0,0 6,7V21A2,2 0 0,0 8,23H19A2,2 0 0,0 21,21V7A2,2 0 0,0 19,5M16,1H4A2,2 0 0,0 2,3V17H4V3H16V1Z"
6753
6753
  />
6754
6754
  </svg>`;
6755
- return x`
6755
+ return k`
6756
6756
  <nav>
6757
6757
  <slot></slot>
6758
6758
  <div class="max">
@@ -6761,10 +6761,10 @@ class mi extends j {
6761
6761
  data-cy="drawBtn"
6762
6762
  class="transparent square primary-text no-margin small"
6763
6763
  title="${this.unstyled ? this.select ? "Select" : "Draw" : ""}"
6764
- ?disabled="${M(this, we) || k}"
6764
+ ?disabled="${S(this, we) || x}"
6765
6765
  @click="${() => this.drawFunc.start()}"
6766
6766
  >
6767
- ${this.unstyled ? t : x`
6767
+ ${this.unstyled ? t : k`
6768
6768
  <i class="small"
6769
6769
  >${this.select ? n : r[this.type]}</i
6770
6770
  >
@@ -6779,10 +6779,10 @@ class mi extends j {
6779
6779
  data-cy="discardBtn"
6780
6780
  class="transparent square error-text no-margin small"
6781
6781
  title="${this.unstyled ? "Discard" : ""}"
6782
- ?disabled="${M(this, ze) || k}"
6782
+ ?disabled="${S(this, ze) || x}"
6783
6783
  @click="${() => this.drawFunc.discard()}"
6784
6784
  >
6785
- ${this.unstyled ? "discard" : x`
6785
+ ${this.unstyled ? "discard" : k`
6786
6786
  <i class="small">${o}</i>
6787
6787
  <div class="tooltip bottom">Discard</div>
6788
6788
  `}
@@ -6792,14 +6792,14 @@ class mi extends j {
6792
6792
  <!-- Editor Button -->
6793
6793
  ${ot(
6794
6794
  this.showEditor,
6795
- () => x`
6795
+ () => k`
6796
6796
  <button
6797
6797
  data-cy="editorBtn"
6798
6798
  class="transparent circle primary-text no-margin small"
6799
6799
  title="${this.unstyled ? "Edit features" : ""}"
6800
6800
  @click=${() => this.renderRoot.querySelector("#editor").classList.toggle("hidden")}
6801
6801
  >
6802
- ${this.unstyled ? "import" : x`
6802
+ ${this.unstyled ? "import" : k`
6803
6803
  <i class="small">${a}</i>
6804
6804
  <div class="tooltip bottom">Edit features</div>
6805
6805
  `}
@@ -6810,7 +6810,7 @@ class mi extends j {
6810
6810
  <!-- Import Button -->
6811
6811
  ${ot(
6812
6812
  this.importFeatures,
6813
- () => x`
6813
+ () => k`
6814
6814
  <!-- Import Input Field : Hidden -->
6815
6815
  <input
6816
6816
  type="file"
@@ -6829,7 +6829,7 @@ class mi extends j {
6829
6829
  this.querySelector("#import-file").click()
6830
6830
  )}
6831
6831
  >
6832
- ${this.unstyled ? "import" : x`
6832
+ ${this.unstyled ? "import" : k`
6833
6833
  <i class="small">${s}</i>
6834
6834
  <div class="tooltip bottom">Import features</div>
6835
6835
  `}
@@ -6841,7 +6841,7 @@ class mi extends j {
6841
6841
  <!-- Geo JSON Wrapper -->
6842
6842
  ${ot(
6843
6843
  this.showEditor,
6844
- () => x`
6844
+ () => k`
6845
6845
  <div id="editor" class="field textarea border extra hidden">
6846
6846
  <!-- Geo JSON Editor -->
6847
6847
  <textarea
@@ -6857,7 +6857,7 @@ class mi extends j {
6857
6857
  class="circle absolute bottom right medium-margin"
6858
6858
  @click=${() => Ki(this.geoJSON)}
6859
6859
  >
6860
- ${this.unstyled ? "copy" : x`
6860
+ ${this.unstyled ? "copy" : k`
6861
6861
  <i class="tiny">${l}</i>
6862
6862
  <div class="tooltip top">Copy</div>
6863
6863
  `}
@@ -6938,31 +6938,34 @@ const Do = `
6938
6938
  }
6939
6939
  `, Qo = (i) => {
6940
6940
  (() => {
6941
+ var t;
6941
6942
  if (i.emitDrawnFeatures(), !i.multipleFeatures)
6942
- i.draw.setActive(!1), i.selectionEvents.removeSelectionEvent(), i.currentlyDrawing = !1;
6943
+ (t = i.draw) == null || t.setActive(!1), i.selectionEvents.removeSelectionEvent(), i.currentlyDrawing = !1;
6943
6944
  else if (i.continuous)
6944
6945
  if (!i.layerId)
6945
6946
  i.drawLayer.getSource().clear(), i.drawnFeatures = [];
6946
6947
  else {
6947
- const r = i.drawLayer.getSource().getFeatures().at(-1);
6948
- if (i.drawLayer.getSource().clear(), !r)
6948
+ const n = i.drawLayer.getSource().getFeatures().at(-1);
6949
+ if (i.drawLayer.getSource().clear(), !n)
6949
6950
  return;
6950
- i.drawLayer.getSource().addFeature(r), i.drawnFeatures = [r];
6951
+ i.drawLayer.getSource().addFeature(n), i.drawnFeatures = [n];
6951
6952
  }
6952
6953
  })(), i.requestUpdate();
6953
6954
  }, ea = (i) => {
6954
6955
  const e = () => {
6955
- i.drawLayer.set("isDrawingEnabled", !0), i.draw.setActive(!0), i.selectionEvents.addSelectionEvent();
6956
+ var r;
6957
+ i.drawLayer.set("isDrawingEnabled", !0), (r = i.draw) == null || r.setActive(!0), i.selectionEvents.addSelectionEvent();
6956
6958
  }, t = () => {
6957
6959
  i.currentlyDrawing = !0, i.requestUpdate();
6958
6960
  };
6959
6961
  e(), t(), document.addEventListener("keydown", ({ key: r }) => {
6960
- r === "Escape" && i.currentlyDrawing && (i.draw.setActive(!1), i.currentlyDrawing = !1, i.requestUpdate());
6962
+ var n;
6963
+ r === "Escape" && i.currentlyDrawing && ((n = i.draw) == null || n.setActive(!1), i.currentlyDrawing = !1, i.requestUpdate());
6961
6964
  });
6962
- }, vr = (i, e) => {
6963
- var a, s, l, c, d;
6965
+ }, at = (i, e) => {
6966
+ var c, d, u, h, m;
6964
6967
  const r = Ko(i.for), n = r.map, o = "0, 65, 112";
6965
- return i.drawLayer = r.addOrUpdateLayer({
6968
+ i.drawLayer = r.addOrUpdateLayer({
6966
6969
  zIndex: 100,
6967
6970
  type: "Vector",
6968
6971
  properties: {
@@ -6974,7 +6977,7 @@ const Do = `
6974
6977
  source: {
6975
6978
  type: "Vector"
6976
6979
  },
6977
- style: ((a = i.featureStyles) == null ? void 0 : a.layer) || {
6980
+ style: ((c = i.featureStyles) == null ? void 0 : c.layer) || {
6978
6981
  "fill-color": `rgba(${o}, 0.1)`,
6979
6982
  "stroke-color": `rgba(${o}, 1)`,
6980
6983
  "stroke-width": 2,
@@ -6990,7 +6993,7 @@ const Do = `
6990
6993
  type: i.type,
6991
6994
  modify: i.allowModify,
6992
6995
  stopClick: !0,
6993
- style: ((s = i.featureStyles) == null ? void 0 : s.layer) || {
6996
+ style: ((d = i.featureStyles) == null ? void 0 : d.layer) || {
6994
6997
  "fill-color": `rgba(${o}, 0.1)`,
6995
6998
  "stroke-color": `rgba(${o}, 1)`,
6996
6999
  "stroke-width": 1,
@@ -7005,7 +7008,7 @@ const Do = `
7005
7008
  options: {
7006
7009
  id: "SelectLayerHoverInteraction",
7007
7010
  condition: "pointermove",
7008
- style: ((l = i.featureStyles) == null ? void 0 : l.hover) || {
7011
+ style: ((u = i.featureStyles) == null ? void 0 : u.hover) || {
7009
7012
  "fill-color": `rgba(${o}, 0.2)`,
7010
7013
  "stroke-color": `rgba(${o}, 1)`,
7011
7014
  "stroke-width": 2
@@ -7019,7 +7022,7 @@ const Do = `
7019
7022
  id: "SelectLayerClickInteraction",
7020
7023
  condition: "click",
7021
7024
  panIn: !0,
7022
- style: ((c = i.featureStyles) == null ? void 0 : c.click) || {
7025
+ style: ((h = i.featureStyles) == null ? void 0 : h.click) || {
7023
7026
  "fill-color": `rgba(${o}, 0.2)`,
7024
7027
  "stroke-color": `rgba(${o}, 1)`,
7025
7028
  "stroke-width": 2
@@ -7031,10 +7034,16 @@ const Do = `
7031
7034
  /** @type {unknown} */
7032
7035
  r.interactions.drawInteraction, i.modify = /** @type {import("ol/interaction").Modify} */
7033
7036
  /** @type {unknown} */
7034
- r.interactions.drawInteractionmodify, pt(i, r, i.layerId), (d = i.modify) == null || d.on("modifyend", () => i.onModifyEnd()), r.addEventListener("addfeatures", () => Qo(i)), { EoxMap: r, OlMap: n };
7037
+ r.interactions.drawInteractionmodify, gt(i, r, i.layerId);
7038
+ const a = () => i.onModifyEnd(), s = () => Qo(i);
7039
+ return (m = i.modify) == null || m.on("modifyend", a), r.addEventListener("addfeatures", s), i.drawnFeatures && i.drawLayer.getSource().addFeatures(i.drawnFeatures), { EoxMap: r, OlMap: n, reset: (p) => {
7040
+ var g;
7041
+ !p.eoxMap || !p.drawLayer || (p.drawLayer.getSource().clear(), p.eoxMap.map.removeLayer(p.drawLayer), (g = p.modify) == null || g.un("modifyend", a), p.eoxMap.removeEventListener("addfeatures", s), p.layerId || (p.draw = null), p.modify = null);
7042
+ } };
7035
7043
  }, ta = (i) => {
7036
7044
  const e = () => {
7037
- i.drawnFeatures = [], i.draw.setActive(!1), i.selectionEvents.removeSelectionEvent(), i.drawLayer.getSource().clear(), i.geoJSON = null;
7045
+ var r;
7046
+ i.drawnFeatures = [], (r = i.draw) == null || r.setActive(!1), i.selectionEvents.removeSelectionEvent(), i.drawLayer.getSource().clear(), i.geoJSON = null;
7038
7047
  }, t = () => {
7039
7048
  i.emitDrawnFeatures(), i.currentlyDrawing = !1, i.requestUpdate();
7040
7049
  };
@@ -7071,14 +7080,17 @@ const Do = `
7071
7080
  ));
7072
7081
  };
7073
7082
  return { addSelectionEvent: () => {
7074
- i.layerId && (i.eoxMap.selectInteractions.SelectLayerHoverInteraction.setActive(!0), i.eoxMap.addEventListener("select", e));
7083
+ if (i.layerId) {
7084
+ const n = i.eoxMap.selectInteractions.SelectLayerHoverInteraction;
7085
+ n == null || n.setActive(!0), i.eoxMap.addEventListener("select", e);
7086
+ }
7075
7087
  }, removeSelectionEvent: () => {
7076
7088
  var o;
7077
7089
  const n = (o = i.eoxMap.selectInteractions) == null ? void 0 : o.SelectLayerHoverInteraction;
7078
- n && (n.selectedFids = [], n.setActive(!1)), i.eoxMap.removeEventListener("select", e);
7090
+ n && (n.selectedFids = [], n == null || n.setActive(!1)), i.eoxMap.removeEventListener("select", e);
7079
7091
  } };
7080
- }, pt = (i, e, t) => {
7081
- var l, c;
7092
+ }, gt = (i, e, t) => {
7093
+ var l, c, d, u;
7082
7094
  if (!t || !e)
7083
7095
  return;
7084
7096
  const r = e.getLayerById(t), n = r ? (
@@ -7118,7 +7130,7 @@ const Do = `
7118
7130
  };
7119
7131
  n.interactions = [o, a], e.addOrUpdateLayer(n), gi(e.layers, t, [n]);
7120
7132
  const s = i.draw;
7121
- i.draw = e.selectInteractions.SelectLayerClickInteraction, s.setActive(!1), e.selectInteractions.SelectLayerClickInteraction.setActive(!1), e.selectInteractions.SelectLayerHoverInteraction.setActive(!1);
7133
+ i.draw = e.selectInteractions.SelectLayerClickInteraction, s == null || s.setActive(!1), (d = e.selectInteractions.SelectLayerClickInteraction) == null || d.setActive(!1), (u = e.selectInteractions.SelectLayerHoverInteraction) == null || u.setActive(!1);
7122
7134
  };
7123
7135
  function gi(i, e, t) {
7124
7136
  const r = i.findIndex(
@@ -7136,16 +7148,16 @@ function gi(i, e, t) {
7136
7148
  const na = (i, e, t, r) => {
7137
7149
  if (e) {
7138
7150
  if (t) {
7139
- r && t !== r && xr(i, e), pt(i, e, t);
7151
+ r && t !== r && kr(i, e), gt(i, e, t);
7140
7152
  return;
7141
7153
  }
7142
7154
  if (!t && r) {
7143
- xr(i, e);
7155
+ kr(i, e);
7144
7156
  return;
7145
7157
  }
7146
7158
  }
7147
7159
  };
7148
- function xr(i, e) {
7160
+ function kr(i, e) {
7149
7161
  e && (i.discardDrawing(), i.selectionEvents.removeSelectionEvent(), i.draw = /** @type {import("ol/interaction").Draw} */
7150
7162
  e.interactions.drawInteraction, e.selectInteractions.SelectLayerClickInteraction.remove(), e.selectInteractions.SelectLayerHoverInteraction.remove());
7151
7163
  }
@@ -7168,11 +7180,9 @@ function aa(i) {
7168
7180
  }
7169
7181
  function fi(i, e) {
7170
7182
  aa(i);
7171
- const t = i.dataTransfer ? i.dataTransfer.files : (
7172
- /**@type {HTMLInputElement}*/
7173
- i.target.files
7174
- );
7175
- Array.from(t).forEach((r) => sa(r, e));
7183
+ let t;
7184
+ "dataTransfer" in i && i.dataTransfer ? t = i.dataTransfer.files : i.target && "files" in i.target ? t = /**@type {HTMLInputElement}*/
7185
+ i.target.files : t = [], Array.from(t).forEach((r) => sa(r, e)), i.target && "value" in i.target && (i.target.value = "");
7176
7186
  }
7177
7187
  function sa(i, e) {
7178
7188
  const t = new FileReader();
@@ -7180,7 +7190,7 @@ function sa(i, e) {
7180
7190
  typeof t.result == "string" && e.handleFeatureChange(t.result);
7181
7191
  };
7182
7192
  }
7183
- var ie, ne, Ce, oe, Se;
7193
+ var ie, ne, Ce, oe, Me;
7184
7194
  class la extends j {
7185
7195
  constructor() {
7186
7196
  super();
@@ -7203,7 +7213,7 @@ class la extends j {
7203
7213
  /**
7204
7214
  * @type boolean
7205
7215
  */
7206
- A(this, Se);
7216
+ A(this, Me);
7207
7217
  this.allowModify = !1, this.for = "eox-map", this.currentlyDrawing = !1, this.draw = null, this.drawLayer = null, this.layerId = "", this.drawnFeatures = [], this.featureName = "Feature", this.featureNameKey = null, this.featureStyles = null, this.modify = null, this.multipleFeatures = !1, this.importFeatures = !1, this.showEditor = !1, this.showList = !1, this.projection = "EPSG:4326", this.type = "Polygon", this.selectionEvents = null, this.format = "feature", this.unstyled = !1, this.noShadow = !1;
7208
7218
  }
7209
7219
  // Define properties with defaults and types
@@ -7238,20 +7248,20 @@ class la extends j {
7238
7248
  * @type {boolean}
7239
7249
  */
7240
7250
  set continuous(t) {
7241
- P(this, Se, t), t && (this.multipleFeatures = !0);
7251
+ P(this, Me, t), t && (this.multipleFeatures = !0);
7242
7252
  }
7243
7253
  get continuous() {
7244
- return M(this, Se);
7254
+ return S(this, Me);
7245
7255
  }
7246
7256
  /**
7247
7257
  * Enables selection mode for the passed layer
7248
7258
  * @type {string}
7249
7259
  */
7250
7260
  set layerId(t) {
7251
- na(this, this.eoxMap, t, M(this, oe)), P(this, oe, t);
7261
+ na(this, this.eoxMap, t, S(this, oe)), P(this, oe, t);
7252
7262
  }
7253
7263
  get layerId() {
7254
- return M(this, oe);
7264
+ return S(this, oe);
7255
7265
  }
7256
7266
  /**
7257
7267
  * @onClick Event handler triggered to start drawing on the map.
@@ -7273,19 +7283,15 @@ class la extends j {
7273
7283
  */
7274
7284
  handleFeatureChange(t, r = !1, n = !0) {
7275
7285
  this.eoxMap.parseTextToFeature(
7276
- t || JSON.stringify(tr),
7286
+ t || JSON.stringify(rr),
7277
7287
  this.drawLayer,
7278
7288
  this.eoxMap,
7279
7289
  r,
7280
- {
7281
- dataProjection: this.eoxMap.projection,
7282
- featureProjection: this.projection
7283
- },
7284
7290
  n
7285
7291
  );
7286
7292
  }
7287
7293
  /**
7288
- * @param {DragEvent} evt - The event object from the file input interaction.
7294
+ * @param {DragEvent | InputEvent & { target: HTMLInputElement }} evt - The event object from the file input interaction.
7289
7295
  */
7290
7296
  handleFilesChange(t) {
7291
7297
  fi(t, this);
@@ -7301,7 +7307,7 @@ class la extends j {
7301
7307
  */
7302
7308
  updateGeoJSON() {
7303
7309
  P(this, Ce, JSON.stringify(
7304
- this.eoxMap.parseFeature(this.drawnFeatures) || tr,
7310
+ this.eoxMap.parseFeature(this.drawnFeatures) || rr,
7305
7311
  void 0,
7306
7312
  2
7307
7313
  ));
@@ -7326,30 +7332,39 @@ class la extends j {
7326
7332
  * It then calls requestUpdate to trigger a re-render.
7327
7333
  */
7328
7334
  firstUpdated() {
7329
- const { EoxMap: t, OlMap: r } = vr(this, this.multipleFeatures);
7330
- this.eoxMap = t, P(this, ne, r), this.selectionEvents = ia(this), this.importFeatures && oa(this, this.eoxMap), this.updateGeoJSON(), this.requestUpdate();
7335
+ const { EoxMap: t, OlMap: r, reset: n } = at(
7336
+ this,
7337
+ this.multipleFeatures
7338
+ );
7339
+ this.resetLayer = n, this.eoxMap = t, P(this, ne, r), this.selectionEvents = ia(this), this.importFeatures && oa(this, this.eoxMap), this.updateGeoJSON(), this.requestUpdate();
7331
7340
  }
7332
7341
  updated(t) {
7333
7342
  if (t.has("for")) {
7334
- const { EoxMap: r, OlMap: n } = vr(this, this.multipleFeatures);
7343
+ const { EoxMap: r, OlMap: n } = at(this, this.multipleFeatures);
7335
7344
  this.eoxMap = r, P(this, ne, n);
7336
7345
  }
7337
7346
  }
7338
7347
  get eoxMap() {
7339
- return M(this, ie);
7348
+ return S(this, ie);
7340
7349
  }
7341
7350
  set eoxMap(t) {
7342
- const r = M(this, ie);
7351
+ const r = S(this, ie);
7343
7352
  P(this, ie, t), this.requestUpdate("eoxMap", r);
7344
7353
  }
7354
+ connectedCallback() {
7355
+ if (super.connectedCallback(), this.drawLayer && this.eoxMap) {
7356
+ const { reset: t } = at(this, this.multipleFeatures);
7357
+ this.resetLayer = t;
7358
+ }
7359
+ }
7345
7360
  disconnectedCallback() {
7346
7361
  var t;
7347
- (t = this.eoxMap) == null || t.map.removeLayer(this.drawLayer), super.disconnectedCallback();
7362
+ super.disconnectedCallback(), (t = this.resetLayer) == null || t.call(this, this);
7348
7363
  }
7349
7364
  // Render method for UI display
7350
7365
  render() {
7351
7366
  var t;
7352
- return x`
7367
+ return k`
7353
7368
  <style>
7354
7369
  :host { display: block; }
7355
7370
  ${!this.unstyled && Do}
@@ -7376,15 +7391,15 @@ class la extends j {
7376
7391
  .multipleFeatures=${this.multipleFeatures}
7377
7392
  .importFeatures=${this.importFeatures}
7378
7393
  .showEditor=${this.showEditor}
7379
- .geoJSON=${M(this, Ce)}
7394
+ .geoJSON=${S(this, Ce)}
7380
7395
  .type=${this.type}
7381
7396
  ></eox-drawtools-controller>
7382
7397
 
7383
7398
  <!-- List Component -->
7384
- ${this.showList && ((t = this.drawnFeatures) != null && t.length) ? x`<eox-drawtools-list
7399
+ ${this.showList && ((t = this.drawnFeatures) != null && t.length) ? k`<eox-drawtools-list
7385
7400
  .eoxDrawTools=${this}
7386
7401
  .eoxMap=${this.eoxMap}
7387
- .olMap=${M(this, ne)}
7402
+ .olMap=${S(this, ne)}
7388
7403
  .draw=${this.draw}
7389
7404
  .drawLayer=${this.drawLayer}
7390
7405
  .drawnFeatures=${this.drawnFeatures}
@@ -7395,11 +7410,11 @@ class la extends j {
7395
7410
  @changed=${() => {
7396
7411
  this.updateGeoJSON(), this.requestUpdate();
7397
7412
  }}
7398
- ></eox-drawtools-list>` : k}
7413
+ ></eox-drawtools-list>` : x}
7399
7414
  `;
7400
7415
  }
7401
7416
  }
7402
- ie = new WeakMap(), ne = new WeakMap(), Ce = new WeakMap(), oe = new WeakMap(), Se = new WeakMap();
7417
+ ie = new WeakMap(), ne = new WeakMap(), Ce = new WeakMap(), oe = new WeakMap(), Me = new WeakMap();
7403
7418
  customElements.define("eox-drawtools", la);
7404
7419
  export {
7405
7420
  la as EOxDrawTools