@eox/layercontrol 0.20.1-dev.1726221051.0 → 0.21.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.
- package/dist/eox-layercontrol.js +1316 -1215
- package/dist/eox-layercontrol.umd.cjs +146 -139
- package/package.json +2 -2
package/dist/eox-layercontrol.js
CHANGED
|
@@ -1,27 +1,27 @@
|
|
|
1
|
-
var
|
|
2
|
-
var
|
|
1
|
+
var jo = Object.defineProperty;
|
|
2
|
+
var ei = (e) => {
|
|
3
3
|
throw TypeError(e);
|
|
4
4
|
};
|
|
5
|
-
var
|
|
6
|
-
var
|
|
7
|
-
var P = (e, t, n) => (
|
|
5
|
+
var Zo = (e, t, n) => t in e ? jo(e, t, { enumerable: !0, configurable: !0, writable: !0, value: n }) : e[t] = n;
|
|
6
|
+
var L = (e, t, n) => Zo(e, typeof t != "symbol" ? t + "" : t, n), fn = (e, t, n) => t.has(e) || ei("Cannot " + n);
|
|
7
|
+
var P = (e, t, n) => (fn(e, t, "read from private field"), n ? n.call(e) : t.get(e)), T = (e, t, n) => t.has(e) ? ei("Cannot add the same private member more than once") : t instanceof WeakSet ? t.add(e) : t.set(e, n), Qt = (e, t, n, i) => (fn(e, t, "write to private field"), i ? i.call(e, n) : t.set(e, n), n), B = (e, t, n) => (fn(e, t, "access private method"), n);
|
|
8
8
|
/**
|
|
9
9
|
* @license
|
|
10
10
|
* Copyright 2019 Google LLC
|
|
11
11
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
12
12
|
*/
|
|
13
|
-
const
|
|
14
|
-
let
|
|
13
|
+
const Te = globalThis, Fn = Te.ShadowRoot && (Te.ShadyCSS === void 0 || Te.ShadyCSS.nativeShadow) && "adoptedStyleSheets" in Document.prototype && "replace" in CSSStyleSheet.prototype, Di = Symbol(), ni = /* @__PURE__ */ new WeakMap();
|
|
14
|
+
let zo = class {
|
|
15
15
|
constructor(t, n, i) {
|
|
16
|
-
if (this._$cssResult$ = !0, i !==
|
|
16
|
+
if (this._$cssResult$ = !0, i !== Di) throw Error("CSSResult is not constructable. Use `unsafeCSS` or `css` instead.");
|
|
17
17
|
this.cssText = t, this.t = n;
|
|
18
18
|
}
|
|
19
19
|
get styleSheet() {
|
|
20
20
|
let t = this.o;
|
|
21
21
|
const n = this.t;
|
|
22
|
-
if (
|
|
22
|
+
if (Fn && t === void 0) {
|
|
23
23
|
const i = n !== void 0 && n.length === 1;
|
|
24
|
-
i && (t =
|
|
24
|
+
i && (t = ni.get(n)), t === void 0 && ((this.o = t = new CSSStyleSheet()).replaceSync(this.cssText), i && ni.set(n, t));
|
|
25
25
|
}
|
|
26
26
|
return t;
|
|
27
27
|
}
|
|
@@ -29,26 +29,26 @@ let Lo = class {
|
|
|
29
29
|
return this.cssText;
|
|
30
30
|
}
|
|
31
31
|
};
|
|
32
|
-
const
|
|
33
|
-
if (
|
|
32
|
+
const Xo = (e) => new zo(typeof e == "string" ? e : e + "", void 0, Di), qo = (e, t) => {
|
|
33
|
+
if (Fn) e.adoptedStyleSheets = t.map((n) => n instanceof CSSStyleSheet ? n : n.styleSheet);
|
|
34
34
|
else for (const n of t) {
|
|
35
|
-
const i = document.createElement("style"), o =
|
|
35
|
+
const i = document.createElement("style"), o = Te.litNonce;
|
|
36
36
|
o !== void 0 && i.setAttribute("nonce", o), i.textContent = n.cssText, e.appendChild(i);
|
|
37
37
|
}
|
|
38
|
-
},
|
|
38
|
+
}, ii = Fn ? (e) => e : (e) => e instanceof CSSStyleSheet ? ((t) => {
|
|
39
39
|
let n = "";
|
|
40
40
|
for (const i of t.cssRules) n += i.cssText;
|
|
41
|
-
return
|
|
41
|
+
return Xo(n);
|
|
42
42
|
})(e) : e;
|
|
43
43
|
/**
|
|
44
44
|
* @license
|
|
45
45
|
* Copyright 2017 Google LLC
|
|
46
46
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
47
47
|
*/
|
|
48
|
-
const { is:
|
|
48
|
+
const { is: Yo, defineProperty: Wo, getOwnPropertyDescriptor: Go, getOwnPropertyNames: Jo, getOwnPropertySymbols: Ko, getPrototypeOf: Qo } = Object, Ct = globalThis, oi = Ct.trustedTypes, tr = oi ? oi.emptyScript : "", gn = Ct.reactiveElementPolyfillSupport, re = (e, t) => e, Mn = { toAttribute(e, t) {
|
|
49
49
|
switch (t) {
|
|
50
50
|
case Boolean:
|
|
51
|
-
e = e ?
|
|
51
|
+
e = e ? tr : null;
|
|
52
52
|
break;
|
|
53
53
|
case Object:
|
|
54
54
|
case Array:
|
|
@@ -73,8 +73,8 @@ const { is: Fo, defineProperty: jo, getOwnPropertyDescriptor: Zo, getOwnProperty
|
|
|
73
73
|
}
|
|
74
74
|
}
|
|
75
75
|
return n;
|
|
76
|
-
} },
|
|
77
|
-
Symbol.metadata ?? (Symbol.metadata = Symbol("metadata")),
|
|
76
|
+
} }, Ri = (e, t) => !Yo(e, t), ri = { attribute: !0, type: String, converter: Mn, reflect: !1, hasChanged: Ri };
|
|
77
|
+
Symbol.metadata ?? (Symbol.metadata = Symbol("metadata")), Ct.litPropertyMetadata ?? (Ct.litPropertyMetadata = /* @__PURE__ */ new WeakMap());
|
|
78
78
|
class Ut extends HTMLElement {
|
|
79
79
|
static addInitializer(t) {
|
|
80
80
|
this._$Ei(), (this.l ?? (this.l = [])).push(t);
|
|
@@ -82,14 +82,14 @@ class Ut extends HTMLElement {
|
|
|
82
82
|
static get observedAttributes() {
|
|
83
83
|
return this.finalize(), this._$Eh && [...this._$Eh.keys()];
|
|
84
84
|
}
|
|
85
|
-
static createProperty(t, n =
|
|
85
|
+
static createProperty(t, n = ri) {
|
|
86
86
|
if (n.state && (n.attribute = !1), this._$Ei(), this.elementProperties.set(t, n), !n.noAccessor) {
|
|
87
87
|
const i = Symbol(), o = this.getPropertyDescriptor(t, i, n);
|
|
88
|
-
o !== void 0 &&
|
|
88
|
+
o !== void 0 && Wo(this.prototype, t, o);
|
|
89
89
|
}
|
|
90
90
|
}
|
|
91
91
|
static getPropertyDescriptor(t, n, i) {
|
|
92
|
-
const { get: o, set: r } =
|
|
92
|
+
const { get: o, set: r } = Go(this.prototype, t) ?? { get() {
|
|
93
93
|
return this[n];
|
|
94
94
|
}, set(s) {
|
|
95
95
|
this[n] = s;
|
|
@@ -102,17 +102,17 @@ class Ut extends HTMLElement {
|
|
|
102
102
|
}, configurable: !0, enumerable: !0 };
|
|
103
103
|
}
|
|
104
104
|
static getPropertyOptions(t) {
|
|
105
|
-
return this.elementProperties.get(t) ??
|
|
105
|
+
return this.elementProperties.get(t) ?? ri;
|
|
106
106
|
}
|
|
107
107
|
static _$Ei() {
|
|
108
|
-
if (this.hasOwnProperty(
|
|
109
|
-
const t =
|
|
108
|
+
if (this.hasOwnProperty(re("elementProperties"))) return;
|
|
109
|
+
const t = Qo(this);
|
|
110
110
|
t.finalize(), t.l !== void 0 && (this.l = [...t.l]), this.elementProperties = new Map(t.elementProperties);
|
|
111
111
|
}
|
|
112
112
|
static finalize() {
|
|
113
|
-
if (this.hasOwnProperty(
|
|
114
|
-
if (this.finalized = !0, this._$Ei(), this.hasOwnProperty(
|
|
115
|
-
const n = this.properties, i = [...
|
|
113
|
+
if (this.hasOwnProperty(re("finalized"))) return;
|
|
114
|
+
if (this.finalized = !0, this._$Ei(), this.hasOwnProperty(re("properties"))) {
|
|
115
|
+
const n = this.properties, i = [...Jo(n), ...Ko(n)];
|
|
116
116
|
for (const o of i) this.createProperty(o, n[o]);
|
|
117
117
|
}
|
|
118
118
|
const t = this[Symbol.metadata];
|
|
@@ -131,8 +131,8 @@ class Ut extends HTMLElement {
|
|
|
131
131
|
const n = [];
|
|
132
132
|
if (Array.isArray(t)) {
|
|
133
133
|
const i = new Set(t.flat(1 / 0).reverse());
|
|
134
|
-
for (const o of i) n.unshift(
|
|
135
|
-
} else t !== void 0 && n.push(
|
|
134
|
+
for (const o of i) n.unshift(ii(o));
|
|
135
|
+
} else t !== void 0 && n.push(ii(t));
|
|
136
136
|
return n;
|
|
137
137
|
}
|
|
138
138
|
static _$Eu(t, n) {
|
|
@@ -161,7 +161,7 @@ class Ut extends HTMLElement {
|
|
|
161
161
|
}
|
|
162
162
|
createRenderRoot() {
|
|
163
163
|
const t = this.shadowRoot ?? this.attachShadow(this.constructor.shadowRootOptions);
|
|
164
|
-
return
|
|
164
|
+
return qo(t, this.constructor.elementStyles), t;
|
|
165
165
|
}
|
|
166
166
|
connectedCallback() {
|
|
167
167
|
var t;
|
|
@@ -186,7 +186,7 @@ class Ut extends HTMLElement {
|
|
|
186
186
|
var r;
|
|
187
187
|
const i = this.constructor.elementProperties.get(t), o = this.constructor._$Eu(t, i);
|
|
188
188
|
if (o !== void 0 && i.reflect === !0) {
|
|
189
|
-
const s = (((r = i.converter) == null ? void 0 : r.toAttribute) !== void 0 ? i.converter :
|
|
189
|
+
const s = (((r = i.converter) == null ? void 0 : r.toAttribute) !== void 0 ? i.converter : Mn).toAttribute(n, i.type);
|
|
190
190
|
this._$Em = t, s == null ? this.removeAttribute(o) : this.setAttribute(o, s), this._$Em = null;
|
|
191
191
|
}
|
|
192
192
|
}
|
|
@@ -194,13 +194,13 @@ class Ut extends HTMLElement {
|
|
|
194
194
|
var r;
|
|
195
195
|
const i = this.constructor, o = i._$Eh.get(t);
|
|
196
196
|
if (o !== void 0 && this._$Em !== o) {
|
|
197
|
-
const s = i.getPropertyOptions(o), a = typeof s.converter == "function" ? { fromAttribute: s.converter } : ((r = s.converter) == null ? void 0 : r.fromAttribute) !== void 0 ? s.converter :
|
|
197
|
+
const s = i.getPropertyOptions(o), a = typeof s.converter == "function" ? { fromAttribute: s.converter } : ((r = s.converter) == null ? void 0 : r.fromAttribute) !== void 0 ? s.converter : Mn;
|
|
198
198
|
this._$Em = o, this[o] = a.fromAttribute(n, s.type), this._$Em = null;
|
|
199
199
|
}
|
|
200
200
|
}
|
|
201
201
|
requestUpdate(t, n, i) {
|
|
202
202
|
if (t !== void 0) {
|
|
203
|
-
if (i ?? (i = this.constructor.getPropertyOptions(t)), !(i.hasChanged ??
|
|
203
|
+
if (i ?? (i = this.constructor.getPropertyOptions(t)), !(i.hasChanged ?? Ri)(this[t], n)) return;
|
|
204
204
|
this.P(t, n, i);
|
|
205
205
|
}
|
|
206
206
|
this.isUpdatePending === !1 && (this._$ES = this._$ET());
|
|
@@ -273,76 +273,76 @@ class Ut extends HTMLElement {
|
|
|
273
273
|
firstUpdated(t) {
|
|
274
274
|
}
|
|
275
275
|
}
|
|
276
|
-
Ut.elementStyles = [], Ut.shadowRootOptions = { mode: "open" }, Ut[
|
|
276
|
+
Ut.elementStyles = [], Ut.shadowRootOptions = { mode: "open" }, Ut[re("elementProperties")] = /* @__PURE__ */ new Map(), Ut[re("finalized")] = /* @__PURE__ */ new Map(), gn == null || gn({ ReactiveElement: Ut }), (Ct.reactiveElementVersions ?? (Ct.reactiveElementVersions = [])).push("2.0.4");
|
|
277
277
|
/**
|
|
278
278
|
* @license
|
|
279
279
|
* Copyright 2017 Google LLC
|
|
280
280
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
281
281
|
*/
|
|
282
|
-
const
|
|
283
|
-
\f\r]`,
|
|
284
|
-
\f\r"'\`<>=]|("|')|))|$)`, "g"),
|
|
285
|
-
function
|
|
286
|
-
if (!
|
|
287
|
-
return
|
|
288
|
-
}
|
|
289
|
-
const
|
|
282
|
+
const se = globalThis, Le = se.trustedTypes, si = Le ? Le.createPolicy("lit-html", { createHTML: (e) => e }) : void 0, jn = "$lit$", pt = `lit$${Math.random().toFixed(9).slice(2)}$`, Zn = "?" + pt, er = `<${Zn}>`, Lt = document, he = () => Lt.createComment(""), pe = (e) => e === null || typeof e != "object" && typeof e != "function", zn = Array.isArray, Mi = (e) => zn(e) || typeof (e == null ? void 0 : e[Symbol.iterator]) == "function", mn = `[
|
|
283
|
+
\f\r]`, te = /<(?:(!--|\/[^a-zA-Z])|(\/?[a-zA-Z][^>\s]*)|(\/?$))/g, ai = /-->/g, li = />/g, Ot = RegExp(`>|${mn}(?:([^\\s"'>=/]+)(${mn}*=${mn}*(?:[^
|
|
284
|
+
\f\r"'\`<>=]|("|')|))|$)`, "g"), ui = /'/g, di = /"/g, Ii = /^(?:script|style|textarea|title)$/i, nr = (e) => (t, ...n) => ({ _$litType$: e, strings: t, values: n }), x = nr(1), at = Symbol.for("lit-noChange"), C = Symbol.for("lit-nothing"), ci = /* @__PURE__ */ new WeakMap(), Nt = Lt.createTreeWalker(Lt, 129);
|
|
285
|
+
function Ni(e, t) {
|
|
286
|
+
if (!zn(e) || !e.hasOwnProperty("raw")) throw Error("invalid template strings array");
|
|
287
|
+
return si !== void 0 ? si.createHTML(t) : t;
|
|
288
|
+
}
|
|
289
|
+
const Hi = (e, t) => {
|
|
290
290
|
const n = e.length - 1, i = [];
|
|
291
|
-
let o, r = t === 2 ? "<svg>" : t === 3 ? "<math>" : "", s =
|
|
291
|
+
let o, r = t === 2 ? "<svg>" : t === 3 ? "<math>" : "", s = te;
|
|
292
292
|
for (let a = 0; a < n; a++) {
|
|
293
293
|
const l = e[a];
|
|
294
|
-
let
|
|
295
|
-
for (; p < l.length && (s.lastIndex = p, c = s.exec(l), c !== null); ) p = s.lastIndex, s ===
|
|
296
|
-
const f = s ===
|
|
297
|
-
r += s ===
|
|
294
|
+
let u, c, d = -1, p = 0;
|
|
295
|
+
for (; p < l.length && (s.lastIndex = p, c = s.exec(l), c !== null); ) p = s.lastIndex, s === te ? c[1] === "!--" ? s = ai : c[1] !== void 0 ? s = li : c[2] !== void 0 ? (Ii.test(c[2]) && (o = RegExp("</" + c[2], "g")), s = Ot) : c[3] !== void 0 && (s = Ot) : s === Ot ? c[0] === ">" ? (s = o ?? te, d = -1) : c[1] === void 0 ? d = -2 : (d = s.lastIndex - c[2].length, u = c[1], s = c[3] === void 0 ? Ot : c[3] === '"' ? di : ui) : s === di || s === ui ? s = Ot : s === ai || s === li ? s = te : (s = Ot, o = void 0);
|
|
296
|
+
const f = s === Ot && e[a + 1].startsWith("/>") ? " " : "";
|
|
297
|
+
r += s === te ? l + er : d >= 0 ? (i.push(u), l.slice(0, d) + jn + l.slice(d) + pt + f) : l + pt + (d === -2 ? a : f);
|
|
298
298
|
}
|
|
299
|
-
return [
|
|
299
|
+
return [Ni(e, r + (e[n] || "<?>") + (t === 2 ? "</svg>" : t === 3 ? "</math>" : "")), i];
|
|
300
300
|
};
|
|
301
|
-
class
|
|
301
|
+
class fe {
|
|
302
302
|
constructor({ strings: t, _$litType$: n }, i) {
|
|
303
303
|
let o;
|
|
304
304
|
this.parts = [];
|
|
305
305
|
let r = 0, s = 0;
|
|
306
|
-
const a = t.length - 1, l = this.parts, [
|
|
307
|
-
if (this.el =
|
|
308
|
-
const
|
|
309
|
-
|
|
306
|
+
const a = t.length - 1, l = this.parts, [u, c] = Hi(t, n);
|
|
307
|
+
if (this.el = fe.createElement(u, i), Nt.currentNode = this.el.content, n === 2 || n === 3) {
|
|
308
|
+
const d = this.el.content.firstChild;
|
|
309
|
+
d.replaceWith(...d.childNodes);
|
|
310
310
|
}
|
|
311
311
|
for (; (o = Nt.nextNode()) !== null && l.length < a; ) {
|
|
312
312
|
if (o.nodeType === 1) {
|
|
313
|
-
if (o.hasAttributes()) for (const
|
|
314
|
-
const p = c[s++], f = o.getAttribute(
|
|
315
|
-
l.push({ type: 1, index: r, name: g[2], strings: f, ctor: g[1] === "." ?
|
|
316
|
-
} else
|
|
317
|
-
if (
|
|
318
|
-
const
|
|
313
|
+
if (o.hasAttributes()) for (const d of o.getAttributeNames()) if (d.endsWith(jn)) {
|
|
314
|
+
const p = c[s++], f = o.getAttribute(d).split(pt), g = /([.?@])?(.*)/.exec(p);
|
|
315
|
+
l.push({ type: 1, index: r, name: g[2], strings: f, ctor: g[1] === "." ? Vi : g[1] === "?" ? ki : g[1] === "@" ? Ui : we }), o.removeAttribute(d);
|
|
316
|
+
} else d.startsWith(pt) && (l.push({ type: 6, index: r }), o.removeAttribute(d));
|
|
317
|
+
if (Ii.test(o.tagName)) {
|
|
318
|
+
const d = o.textContent.split(pt), p = d.length - 1;
|
|
319
319
|
if (p > 0) {
|
|
320
|
-
o.textContent =
|
|
321
|
-
for (let f = 0; f < p; f++) o.append(
|
|
322
|
-
o.append(
|
|
320
|
+
o.textContent = Le ? Le.emptyScript : "";
|
|
321
|
+
for (let f = 0; f < p; f++) o.append(d[f], he()), Nt.nextNode(), l.push({ type: 2, index: ++r });
|
|
322
|
+
o.append(d[p], he());
|
|
323
323
|
}
|
|
324
324
|
}
|
|
325
|
-
} else if (o.nodeType === 8) if (o.data ===
|
|
325
|
+
} else if (o.nodeType === 8) if (o.data === Zn) l.push({ type: 2, index: r });
|
|
326
326
|
else {
|
|
327
|
-
let
|
|
328
|
-
for (; (
|
|
327
|
+
let d = -1;
|
|
328
|
+
for (; (d = o.data.indexOf(pt, d + 1)) !== -1; ) l.push({ type: 7, index: r }), d += pt.length - 1;
|
|
329
329
|
}
|
|
330
330
|
r++;
|
|
331
331
|
}
|
|
332
332
|
}
|
|
333
333
|
static createElement(t, n) {
|
|
334
|
-
const i =
|
|
334
|
+
const i = Lt.createElement("template");
|
|
335
335
|
return i.innerHTML = t, i;
|
|
336
336
|
}
|
|
337
337
|
}
|
|
338
338
|
function Bt(e, t, n = e, i) {
|
|
339
339
|
var s, a;
|
|
340
|
-
if (t ===
|
|
340
|
+
if (t === at) return t;
|
|
341
341
|
let o = i !== void 0 ? (s = n.o) == null ? void 0 : s[i] : n.l;
|
|
342
|
-
const r =
|
|
342
|
+
const r = pe(t) ? void 0 : t._$litDirective$;
|
|
343
343
|
return (o == null ? void 0 : o.constructor) !== r && ((a = o == null ? void 0 : o._$AO) == null || a.call(o, !1), r === void 0 ? o = void 0 : (o = new r(e), o._$AT(e, n, i)), i !== void 0 ? (n.o ?? (n.o = []))[i] = o : n.l = o), o !== void 0 && (t = Bt(e, o._$AS(e, t.values), o, i)), t;
|
|
344
344
|
}
|
|
345
|
-
class
|
|
345
|
+
class Li {
|
|
346
346
|
constructor(t, n) {
|
|
347
347
|
this._$AV = [], this._$AN = void 0, this._$AD = t, this._$AM = n;
|
|
348
348
|
}
|
|
@@ -353,24 +353,24 @@ class Oi {
|
|
|
353
353
|
return this._$AM._$AU;
|
|
354
354
|
}
|
|
355
355
|
u(t) {
|
|
356
|
-
const { el: { content: n }, parts: i } = this._$AD, o = ((t == null ? void 0 : t.creationScope) ??
|
|
356
|
+
const { el: { content: n }, parts: i } = this._$AD, o = ((t == null ? void 0 : t.creationScope) ?? Lt).importNode(n, !0);
|
|
357
357
|
Nt.currentNode = o;
|
|
358
358
|
let r = Nt.nextNode(), s = 0, a = 0, l = i[0];
|
|
359
359
|
for (; l !== void 0; ) {
|
|
360
360
|
if (s === l.index) {
|
|
361
|
-
let
|
|
362
|
-
l.type === 2 ?
|
|
361
|
+
let u;
|
|
362
|
+
l.type === 2 ? u = new cn(r, r.nextSibling, this, t) : l.type === 1 ? u = new l.ctor(r, l.name, l.strings, this, t) : l.type === 6 && (u = new Fi(r, this, t)), this._$AV.push(u), l = i[++a];
|
|
363
363
|
}
|
|
364
364
|
s !== (l == null ? void 0 : l.index) && (r = Nt.nextNode(), s++);
|
|
365
365
|
}
|
|
366
|
-
return Nt.currentNode =
|
|
366
|
+
return Nt.currentNode = Lt, o;
|
|
367
367
|
}
|
|
368
368
|
p(t) {
|
|
369
369
|
let n = 0;
|
|
370
370
|
for (const i of this._$AV) i !== void 0 && (i.strings !== void 0 ? (i._$AI(t, i, n), n += i.strings.length - 2) : i._$AI(t[n])), n++;
|
|
371
371
|
}
|
|
372
372
|
}
|
|
373
|
-
let
|
|
373
|
+
let cn = class Bi {
|
|
374
374
|
get _$AU() {
|
|
375
375
|
var t;
|
|
376
376
|
return ((t = this._$AM) == null ? void 0 : t._$AU) ?? this.v;
|
|
@@ -390,7 +390,7 @@ let un = class Ri {
|
|
|
390
390
|
return this._$AB;
|
|
391
391
|
}
|
|
392
392
|
_$AI(t, n = this) {
|
|
393
|
-
t = Bt(this, t, n),
|
|
393
|
+
t = Bt(this, t, n), pe(t) ? t === C || t == null || t === "" ? (this._$AH !== C && this._$AR(), this._$AH = C) : t !== this._$AH && t !== at && this._(t) : t._$litType$ !== void 0 ? this.$(t) : t.nodeType !== void 0 ? this.T(t) : Mi(t) ? this.k(t) : this._(t);
|
|
394
394
|
}
|
|
395
395
|
O(t) {
|
|
396
396
|
return this._$AA.parentNode.insertBefore(t, this._$AB);
|
|
@@ -399,26 +399,26 @@ let un = class Ri {
|
|
|
399
399
|
this._$AH !== t && (this._$AR(), this._$AH = this.O(t));
|
|
400
400
|
}
|
|
401
401
|
_(t) {
|
|
402
|
-
this._$AH !== C &&
|
|
402
|
+
this._$AH !== C && pe(this._$AH) ? this._$AA.nextSibling.data = t : this.T(Lt.createTextNode(t)), this._$AH = t;
|
|
403
403
|
}
|
|
404
404
|
$(t) {
|
|
405
405
|
var r;
|
|
406
|
-
const { values: n, _$litType$: i } = t, o = typeof i == "number" ? this._$AC(t) : (i.el === void 0 && (i.el =
|
|
406
|
+
const { values: n, _$litType$: i } = t, o = typeof i == "number" ? this._$AC(t) : (i.el === void 0 && (i.el = fe.createElement(Ni(i.h, i.h[0]), this.options)), i);
|
|
407
407
|
if (((r = this._$AH) == null ? void 0 : r._$AD) === o) this._$AH.p(n);
|
|
408
408
|
else {
|
|
409
|
-
const s = new
|
|
409
|
+
const s = new Li(o, this), a = s.u(this.options);
|
|
410
410
|
s.p(n), this.T(a), this._$AH = s;
|
|
411
411
|
}
|
|
412
412
|
}
|
|
413
413
|
_$AC(t) {
|
|
414
|
-
let n =
|
|
415
|
-
return n === void 0 &&
|
|
414
|
+
let n = ci.get(t.strings);
|
|
415
|
+
return n === void 0 && ci.set(t.strings, n = new fe(t)), n;
|
|
416
416
|
}
|
|
417
417
|
k(t) {
|
|
418
|
-
|
|
418
|
+
zn(this._$AH) || (this._$AH = [], this._$AR());
|
|
419
419
|
const n = this._$AH;
|
|
420
420
|
let i, o = 0;
|
|
421
|
-
for (const r of t) o === n.length ? n.push(i = new
|
|
421
|
+
for (const r of t) o === n.length ? n.push(i = new Bi(this.O(he()), this.O(he()), this, this.options)) : i = n[o], i._$AI(r), o++;
|
|
422
422
|
o < n.length && (this._$AR(i && i._$AB.nextSibling, o), n.length = o);
|
|
423
423
|
}
|
|
424
424
|
_$AR(t = this._$AA.nextSibling, n) {
|
|
@@ -433,7 +433,7 @@ let un = class Ri {
|
|
|
433
433
|
this._$AM === void 0 && (this.v = t, (n = this._$AP) == null || n.call(this, t));
|
|
434
434
|
}
|
|
435
435
|
};
|
|
436
|
-
class
|
|
436
|
+
class we {
|
|
437
437
|
get tagName() {
|
|
438
438
|
return this.element.tagName;
|
|
439
439
|
}
|
|
@@ -446,11 +446,11 @@ class be {
|
|
|
446
446
|
_$AI(t, n = this, i, o) {
|
|
447
447
|
const r = this.strings;
|
|
448
448
|
let s = !1;
|
|
449
|
-
if (r === void 0) t = Bt(this, t, n, 0), s = !
|
|
449
|
+
if (r === void 0) t = Bt(this, t, n, 0), s = !pe(t) || t !== this._$AH && t !== at, s && (this._$AH = t);
|
|
450
450
|
else {
|
|
451
451
|
const a = t;
|
|
452
|
-
let l,
|
|
453
|
-
for (t = r[0], l = 0; l < r.length - 1; l++)
|
|
452
|
+
let l, u;
|
|
453
|
+
for (t = r[0], l = 0; l < r.length - 1; l++) u = Bt(this, a[i + l], n, l), u === at && (u = this._$AH[l]), s || (s = !pe(u) || u !== this._$AH[l]), u === C ? t = C : t !== C && (t += (u ?? "") + r[l + 1]), this._$AH[l] = u;
|
|
454
454
|
}
|
|
455
455
|
s && !o && this.j(t);
|
|
456
456
|
}
|
|
@@ -458,7 +458,7 @@ class be {
|
|
|
458
458
|
t === C ? this.element.removeAttribute(this.name) : this.element.setAttribute(this.name, t ?? "");
|
|
459
459
|
}
|
|
460
460
|
}
|
|
461
|
-
class
|
|
461
|
+
class Vi extends we {
|
|
462
462
|
constructor() {
|
|
463
463
|
super(...arguments), this.type = 3;
|
|
464
464
|
}
|
|
@@ -466,7 +466,7 @@ class Mi extends be {
|
|
|
466
466
|
this.element[this.name] = t === C ? void 0 : t;
|
|
467
467
|
}
|
|
468
468
|
}
|
|
469
|
-
class
|
|
469
|
+
class ki extends we {
|
|
470
470
|
constructor() {
|
|
471
471
|
super(...arguments), this.type = 4;
|
|
472
472
|
}
|
|
@@ -474,12 +474,12 @@ class Ni extends be {
|
|
|
474
474
|
this.element.toggleAttribute(this.name, !!t && t !== C);
|
|
475
475
|
}
|
|
476
476
|
}
|
|
477
|
-
class
|
|
477
|
+
class Ui extends we {
|
|
478
478
|
constructor(t, n, i, o, r) {
|
|
479
479
|
super(t, n, i, o, r), this.type = 5;
|
|
480
480
|
}
|
|
481
481
|
_$AI(t, n = this) {
|
|
482
|
-
if ((t = Bt(this, t, n, 0) ?? C) ===
|
|
482
|
+
if ((t = Bt(this, t, n, 0) ?? C) === at) return;
|
|
483
483
|
const i = this._$AH, o = t === C && i !== C || t.capture !== i.capture || t.once !== i.once || t.passive !== i.passive, r = t !== C && (i === C || o);
|
|
484
484
|
o && this.element.removeEventListener(this.name, this, i), r && this.element.addEventListener(this.name, this, t), this._$AH = t;
|
|
485
485
|
}
|
|
@@ -488,7 +488,7 @@ class Ii extends be {
|
|
|
488
488
|
typeof this._$AH == "function" ? this._$AH.call(((n = this.options) == null ? void 0 : n.host) ?? this.element, t) : this._$AH.handleEvent(t);
|
|
489
489
|
}
|
|
490
490
|
}
|
|
491
|
-
class
|
|
491
|
+
class Fi {
|
|
492
492
|
constructor(t, n, i) {
|
|
493
493
|
this.element = t, this.type = 6, this._$AN = void 0, this._$AM = n, this.options = i;
|
|
494
494
|
}
|
|
@@ -499,14 +499,14 @@ class Hi {
|
|
|
499
499
|
Bt(this, t);
|
|
500
500
|
}
|
|
501
501
|
}
|
|
502
|
-
const
|
|
503
|
-
|
|
504
|
-
const
|
|
502
|
+
const ir = { M: jn, P: pt, A: Zn, C: 1, L: Hi, R: Li, D: Mi, V: Bt, I: cn, H: we, N: ki, U: Ui, B: Vi, F: Fi }, yn = se.litHtmlPolyfillSupport;
|
|
503
|
+
yn == null || yn(fe, cn), (se.litHtmlVersions ?? (se.litHtmlVersions = [])).push("3.2.0");
|
|
504
|
+
const or = (e, t, n) => {
|
|
505
505
|
const i = (n == null ? void 0 : n.renderBefore) ?? t;
|
|
506
506
|
let o = i._$litPart$;
|
|
507
507
|
if (o === void 0) {
|
|
508
508
|
const r = (n == null ? void 0 : n.renderBefore) ?? null;
|
|
509
|
-
i._$litPart$ = o = new
|
|
509
|
+
i._$litPart$ = o = new cn(t.insertBefore(he(), r), r, void 0, n ?? {});
|
|
510
510
|
}
|
|
511
511
|
return o._$AI(e), o;
|
|
512
512
|
};
|
|
@@ -515,7 +515,7 @@ const Ko = (e, t, n) => {
|
|
|
515
515
|
* Copyright 2017 Google LLC
|
|
516
516
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
517
517
|
*/
|
|
518
|
-
class
|
|
518
|
+
class it extends Ut {
|
|
519
519
|
constructor() {
|
|
520
520
|
super(...arguments), this.renderOptions = { host: this }, this.o = void 0;
|
|
521
521
|
}
|
|
@@ -526,7 +526,7 @@ class tt extends Ut {
|
|
|
526
526
|
}
|
|
527
527
|
update(t) {
|
|
528
528
|
const n = this.render();
|
|
529
|
-
this.hasUpdated || (this.renderOptions.isConnected = this.isConnected), super.update(t), this.o =
|
|
529
|
+
this.hasUpdated || (this.renderOptions.isConnected = this.isConnected), super.update(t), this.o = or(n, this.renderRoot, this.renderOptions);
|
|
530
530
|
}
|
|
531
531
|
connectedCallback() {
|
|
532
532
|
var t;
|
|
@@ -537,20 +537,20 @@ class tt extends Ut {
|
|
|
537
537
|
super.disconnectedCallback(), (t = this.o) == null || t.setConnected(!1);
|
|
538
538
|
}
|
|
539
539
|
render() {
|
|
540
|
-
return
|
|
540
|
+
return at;
|
|
541
541
|
}
|
|
542
542
|
}
|
|
543
|
-
var
|
|
544
|
-
|
|
545
|
-
const
|
|
546
|
-
|
|
543
|
+
var Oi;
|
|
544
|
+
it._$litElement$ = !0, it.finalized = !0, (Oi = globalThis.litElementHydrateSupport) == null || Oi.call(globalThis, { LitElement: it });
|
|
545
|
+
const bn = globalThis.litElementPolyfillSupport;
|
|
546
|
+
bn == null || bn({ LitElement: it });
|
|
547
547
|
(globalThis.litElementVersions ?? (globalThis.litElementVersions = [])).push("4.1.0");
|
|
548
548
|
/**
|
|
549
549
|
* @license
|
|
550
550
|
* Copyright 2021 Google LLC
|
|
551
551
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
552
552
|
*/
|
|
553
|
-
function
|
|
553
|
+
function G(e, t, n) {
|
|
554
554
|
return e ? t(e) : n == null ? void 0 : n(e);
|
|
555
555
|
}
|
|
556
556
|
/**
|
|
@@ -558,8 +558,8 @@ function Y(e, t, n) {
|
|
|
558
558
|
* Copyright 2017 Google LLC
|
|
559
559
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
560
560
|
*/
|
|
561
|
-
const Et = { ATTRIBUTE: 1, CHILD: 2, PROPERTY: 3, BOOLEAN_ATTRIBUTE: 4, EVENT: 5, ELEMENT: 6 },
|
|
562
|
-
class
|
|
561
|
+
const Et = { ATTRIBUTE: 1, CHILD: 2, PROPERTY: 3, BOOLEAN_ATTRIBUTE: 4, EVENT: 5, ELEMENT: 6 }, Xn = (e) => (...t) => ({ _$litDirective$: e, values: t });
|
|
562
|
+
class qn {
|
|
563
563
|
constructor(t) {
|
|
564
564
|
}
|
|
565
565
|
get _$AU() {
|
|
@@ -580,28 +580,28 @@ class Zn {
|
|
|
580
580
|
* Copyright 2020 Google LLC
|
|
581
581
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
582
582
|
*/
|
|
583
|
-
const { I:
|
|
583
|
+
const { I: rr } = ir, sr = (e) => e.strings === void 0, hi = () => document.createComment(""), ee = (e, t, n) => {
|
|
584
584
|
var r;
|
|
585
585
|
const i = e._$AA.parentNode, o = t === void 0 ? e._$AB : t._$AA;
|
|
586
586
|
if (n === void 0) {
|
|
587
|
-
const s = i.insertBefore(
|
|
588
|
-
n = new
|
|
587
|
+
const s = i.insertBefore(hi(), o), a = i.insertBefore(hi(), o);
|
|
588
|
+
n = new rr(s, a, e, e.options);
|
|
589
589
|
} else {
|
|
590
590
|
const s = n._$AB.nextSibling, a = n._$AM, l = a !== e;
|
|
591
591
|
if (l) {
|
|
592
|
-
let
|
|
593
|
-
(r = n._$AQ) == null || r.call(n, e), n._$AM = e, n._$AP !== void 0 && (
|
|
592
|
+
let u;
|
|
593
|
+
(r = n._$AQ) == null || r.call(n, e), n._$AM = e, n._$AP !== void 0 && (u = e._$AU) !== a._$AU && n._$AP(u);
|
|
594
594
|
}
|
|
595
595
|
if (s !== o || l) {
|
|
596
|
-
let
|
|
597
|
-
for (;
|
|
598
|
-
const c =
|
|
599
|
-
i.insertBefore(
|
|
596
|
+
let u = n._$AA;
|
|
597
|
+
for (; u !== s; ) {
|
|
598
|
+
const c = u.nextSibling;
|
|
599
|
+
i.insertBefore(u, o), u = c;
|
|
600
600
|
}
|
|
601
601
|
}
|
|
602
602
|
}
|
|
603
603
|
return n;
|
|
604
|
-
}, Dt = (e, t, n = e) => (e._$AI(t, n), e),
|
|
604
|
+
}, Dt = (e, t, n = e) => (e._$AI(t, n), e), ar = {}, ji = (e, t = ar) => e._$AH = t, lr = (e) => e._$AH, vn = (e) => {
|
|
605
605
|
var i;
|
|
606
606
|
(i = e._$AP) == null || i.call(e, !1, !0);
|
|
607
607
|
let t = e._$AA;
|
|
@@ -616,11 +616,11 @@ const { I: Qo } = Jo, tr = (e) => e.strings === void 0, di = () => document.crea
|
|
|
616
616
|
* Copyright 2017 Google LLC
|
|
617
617
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
618
618
|
*/
|
|
619
|
-
const
|
|
619
|
+
const pi = (e, t, n) => {
|
|
620
620
|
const i = /* @__PURE__ */ new Map();
|
|
621
621
|
for (let o = t; o <= n; o++) i.set(e[o], o);
|
|
622
622
|
return i;
|
|
623
|
-
},
|
|
623
|
+
}, ur = Xn(class extends qn {
|
|
624
624
|
constructor(e) {
|
|
625
625
|
if (super(e), e.type !== Et.CHILD) throw Error("repeat() can only be used in text expressions");
|
|
626
626
|
}
|
|
@@ -636,34 +636,34 @@ const ui = (e, t, n) => {
|
|
|
636
636
|
return this.dt(e, t, n).values;
|
|
637
637
|
}
|
|
638
638
|
update(e, [t, n, i]) {
|
|
639
|
-
const o =
|
|
639
|
+
const o = lr(e), { values: r, keys: s } = this.dt(t, n, i);
|
|
640
640
|
if (!Array.isArray(o)) return this.ut = s, r;
|
|
641
641
|
const a = this.ut ?? (this.ut = []), l = [];
|
|
642
|
-
let
|
|
643
|
-
for (;
|
|
642
|
+
let u, c, d = 0, p = o.length - 1, f = 0, g = r.length - 1;
|
|
643
|
+
for (; d <= p && f <= g; ) if (o[d] === null) d++;
|
|
644
644
|
else if (o[p] === null) p--;
|
|
645
|
-
else if (a[
|
|
645
|
+
else if (a[d] === s[f]) l[f] = Dt(o[d], r[f]), d++, f++;
|
|
646
646
|
else if (a[p] === s[g]) l[g] = Dt(o[p], r[g]), p--, g--;
|
|
647
|
-
else if (a[
|
|
648
|
-
else if (a[p] === s[f]) l[f] = Dt(o[p], r[f]),
|
|
649
|
-
else if (
|
|
650
|
-
const y = c.get(s[f]),
|
|
651
|
-
if (
|
|
652
|
-
const
|
|
653
|
-
Dt(
|
|
654
|
-
} else l[f] = Dt(
|
|
647
|
+
else if (a[d] === s[g]) l[g] = Dt(o[d], r[g]), ee(e, l[g + 1], o[d]), d++, g--;
|
|
648
|
+
else if (a[p] === s[f]) l[f] = Dt(o[p], r[f]), ee(e, o[d], o[p]), p--, f++;
|
|
649
|
+
else if (u === void 0 && (u = pi(s, f, g), c = pi(a, d, p)), u.has(a[d])) if (u.has(a[p])) {
|
|
650
|
+
const y = c.get(s[f]), O = y !== void 0 ? o[y] : null;
|
|
651
|
+
if (O === null) {
|
|
652
|
+
const I = ee(e, o[d]);
|
|
653
|
+
Dt(I, r[f]), l[f] = I;
|
|
654
|
+
} else l[f] = Dt(O, r[f]), ee(e, o[d], O), o[y] = null;
|
|
655
655
|
f++;
|
|
656
|
-
} else
|
|
657
|
-
else
|
|
656
|
+
} else vn(o[p]), p--;
|
|
657
|
+
else vn(o[d]), d++;
|
|
658
658
|
for (; f <= g; ) {
|
|
659
|
-
const y =
|
|
659
|
+
const y = ee(e, l[g + 1]);
|
|
660
660
|
Dt(y, r[f]), l[f++] = y;
|
|
661
661
|
}
|
|
662
|
-
for (;
|
|
663
|
-
const y = o[
|
|
664
|
-
y !== null &&
|
|
662
|
+
for (; d <= p; ) {
|
|
663
|
+
const y = o[d++];
|
|
664
|
+
y !== null && vn(y);
|
|
665
665
|
}
|
|
666
|
-
return this.ut = s,
|
|
666
|
+
return this.ut = s, ji(e, l), at;
|
|
667
667
|
}
|
|
668
668
|
});
|
|
669
669
|
/**
|
|
@@ -672,8 +672,8 @@ const ui = (e, t, n) => {
|
|
|
672
672
|
* @license BSD-2-Clause
|
|
673
673
|
* @preserve
|
|
674
674
|
*/
|
|
675
|
-
var
|
|
676
|
-
const
|
|
675
|
+
var S = (e) => e !== void 0, Zi = (e, t, n) => t in e ? e[t] : e[t] = n;
|
|
676
|
+
const ge = {
|
|
677
677
|
ELEMENT: 1,
|
|
678
678
|
ATTRIBUTE: 2,
|
|
679
679
|
TEXT: 3,
|
|
@@ -687,7 +687,7 @@ const fe = {
|
|
|
687
687
|
DOCUMENT_FRAGMENT: 11,
|
|
688
688
|
NOTATION: 12
|
|
689
689
|
};
|
|
690
|
-
class
|
|
690
|
+
class dr {
|
|
691
691
|
/**
|
|
692
692
|
* XML DOM parser
|
|
693
693
|
* @constructor
|
|
@@ -712,56 +712,56 @@ class or {
|
|
|
712
712
|
* @api
|
|
713
713
|
*/
|
|
714
714
|
getAllTextContent(t, n) {
|
|
715
|
-
return
|
|
715
|
+
return hn(t, n).join("");
|
|
716
716
|
}
|
|
717
717
|
}
|
|
718
|
-
function
|
|
719
|
-
return
|
|
718
|
+
function hn(e, t) {
|
|
719
|
+
return zi(e, t, []).join("");
|
|
720
720
|
}
|
|
721
|
-
function
|
|
722
|
-
if (e.nodeType ===
|
|
721
|
+
function zi(e, t, n) {
|
|
722
|
+
if (e.nodeType === ge.CDATA_SECTION || e.nodeType === ge.TEXT)
|
|
723
723
|
t ? n.push(String(e.nodeValue).replace(/(\r\n|\r|\n)/g, "")) : n.push(e.nodeValue);
|
|
724
724
|
else {
|
|
725
725
|
var i;
|
|
726
726
|
for (i = e.firstChild; i; i = i.nextSibling)
|
|
727
|
-
|
|
727
|
+
zi(i, t, n);
|
|
728
728
|
}
|
|
729
729
|
return n;
|
|
730
730
|
}
|
|
731
|
-
function
|
|
732
|
-
for (var o =
|
|
731
|
+
function cr(e, t, n, i) {
|
|
732
|
+
for (var o = hr(t); o; o = pr(o)) {
|
|
733
733
|
var r = o.namespaceURI || null, s = e[r];
|
|
734
|
-
if (
|
|
734
|
+
if (S(s)) {
|
|
735
735
|
var a = s[o.localName];
|
|
736
|
-
|
|
736
|
+
S(a) && a.call(i, o, n);
|
|
737
737
|
}
|
|
738
738
|
}
|
|
739
739
|
}
|
|
740
|
-
function
|
|
740
|
+
function hr(e) {
|
|
741
741
|
let t = e.firstElementChild || e.firstChild;
|
|
742
|
-
for (; t && t.nodeType !==
|
|
742
|
+
for (; t && t.nodeType !== ge.ELEMENT; )
|
|
743
743
|
t = t.nextSibling;
|
|
744
744
|
return t;
|
|
745
745
|
}
|
|
746
|
-
function
|
|
746
|
+
function pr(e) {
|
|
747
747
|
let t = e.nextElementSibling || e.nextSibling;
|
|
748
|
-
for (; t && t.nodeType !==
|
|
748
|
+
for (; t && t.nodeType !== ge.ELEMENT; )
|
|
749
749
|
t = t.nextSibling;
|
|
750
750
|
return t;
|
|
751
751
|
}
|
|
752
|
-
function
|
|
752
|
+
function q(e, t, n) {
|
|
753
753
|
return (
|
|
754
754
|
/** @type {Object.<string, Object.<string, XMLParser.Parser>>} */
|
|
755
|
-
|
|
755
|
+
fr(e, t, n)
|
|
756
756
|
);
|
|
757
757
|
}
|
|
758
|
-
function
|
|
759
|
-
var i =
|
|
758
|
+
function fr(e, t, n) {
|
|
759
|
+
var i = S(n) ? n : {}, o, r;
|
|
760
760
|
for (o = 0, r = e.length; o < r; ++o)
|
|
761
761
|
i[e[o]] = t;
|
|
762
762
|
return i;
|
|
763
763
|
}
|
|
764
|
-
function
|
|
764
|
+
function Xi(e, t) {
|
|
765
765
|
return (
|
|
766
766
|
/**
|
|
767
767
|
* @param {Node} node Node.
|
|
@@ -769,19 +769,19 @@ function Ui(e, t) {
|
|
|
769
769
|
*/
|
|
770
770
|
function(n, i) {
|
|
771
771
|
var o = e.call(
|
|
772
|
-
|
|
772
|
+
S(t) ? t : this,
|
|
773
773
|
n,
|
|
774
774
|
i
|
|
775
775
|
);
|
|
776
|
-
if (
|
|
776
|
+
if (S(o)) {
|
|
777
777
|
var r = i[i.length - 1];
|
|
778
778
|
r.push(o);
|
|
779
779
|
}
|
|
780
780
|
}
|
|
781
781
|
);
|
|
782
782
|
}
|
|
783
|
-
function
|
|
784
|
-
return i.push(e),
|
|
783
|
+
function F(e, t, n, i, o) {
|
|
784
|
+
return i.push(e), cr(t, n, i, o), i.pop();
|
|
785
785
|
}
|
|
786
786
|
function m(e, t, n) {
|
|
787
787
|
return (
|
|
@@ -791,21 +791,21 @@ function m(e, t, n) {
|
|
|
791
791
|
*/
|
|
792
792
|
function(i, o) {
|
|
793
793
|
let r = e.call(
|
|
794
|
-
|
|
794
|
+
S(n) ? n : this,
|
|
795
795
|
i,
|
|
796
796
|
o
|
|
797
797
|
);
|
|
798
|
-
if (
|
|
798
|
+
if (S(r)) {
|
|
799
799
|
var s = (
|
|
800
800
|
/** @type {Object} */
|
|
801
801
|
o[o.length - 1]
|
|
802
|
-
), a =
|
|
802
|
+
), a = S(t) ? t : i.localName;
|
|
803
803
|
s[a] = r;
|
|
804
804
|
}
|
|
805
805
|
}
|
|
806
806
|
);
|
|
807
807
|
}
|
|
808
|
-
function
|
|
808
|
+
function et(e, t, n) {
|
|
809
809
|
return (
|
|
810
810
|
/**
|
|
811
811
|
* @param {Node} node Node.
|
|
@@ -813,56 +813,56 @@ function K(e, t, n) {
|
|
|
813
813
|
*/
|
|
814
814
|
function(i, o) {
|
|
815
815
|
var r = e.call(
|
|
816
|
-
|
|
816
|
+
S(n) ? n : this,
|
|
817
817
|
i,
|
|
818
818
|
o
|
|
819
819
|
);
|
|
820
|
-
if (
|
|
820
|
+
if (S(r)) {
|
|
821
821
|
var s = (
|
|
822
822
|
/** @type {Object} */
|
|
823
823
|
o[o.length - 1]
|
|
824
|
-
), a =
|
|
824
|
+
), a = S(t) ? t : i.localName, l = Zi(s, a, []);
|
|
825
825
|
l.push(r);
|
|
826
826
|
}
|
|
827
827
|
}
|
|
828
828
|
);
|
|
829
829
|
}
|
|
830
|
-
const
|
|
831
|
-
function
|
|
832
|
-
return e.replace(
|
|
830
|
+
const gr = /^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g;
|
|
831
|
+
function mr(e) {
|
|
832
|
+
return e.replace(gr, "");
|
|
833
833
|
}
|
|
834
|
-
function
|
|
834
|
+
function Ht(e) {
|
|
835
835
|
const t = /^\s*(true|1)|(false|0)\s*$/.exec(e);
|
|
836
836
|
if (t)
|
|
837
|
-
return
|
|
837
|
+
return S(t[1]) || !1;
|
|
838
838
|
}
|
|
839
|
-
function
|
|
840
|
-
return ft(
|
|
839
|
+
function jt(e) {
|
|
840
|
+
return ft(hn(e, !1));
|
|
841
841
|
}
|
|
842
842
|
function ft(e) {
|
|
843
843
|
const t = /^\s*([+\-]?\d*\.?\d+(?:e[+\-]?\d+)?)\s*$/i.exec(e);
|
|
844
844
|
if (t)
|
|
845
845
|
return parseFloat(t[1]);
|
|
846
846
|
}
|
|
847
|
-
function
|
|
848
|
-
return Be(
|
|
847
|
+
function wn(e) {
|
|
848
|
+
return Be(hn(e, !1));
|
|
849
849
|
}
|
|
850
850
|
function Be(e) {
|
|
851
851
|
const t = /^\s*(\d+)\s*$/.exec(e);
|
|
852
852
|
if (t)
|
|
853
853
|
return parseInt(t[1], 10);
|
|
854
854
|
}
|
|
855
|
-
function
|
|
856
|
-
return
|
|
855
|
+
function A(e) {
|
|
856
|
+
return mr(hn(e, !1));
|
|
857
857
|
}
|
|
858
|
-
const
|
|
859
|
-
function
|
|
860
|
-
return e.getAttributeNS(
|
|
858
|
+
const yr = "http://www.w3.org/1999/xlink";
|
|
859
|
+
function Yn(e) {
|
|
860
|
+
return e.getAttributeNS(yr, "href");
|
|
861
861
|
}
|
|
862
|
-
function
|
|
863
|
-
return
|
|
862
|
+
function br(e, t) {
|
|
863
|
+
return F({}, zr, e, t);
|
|
864
864
|
}
|
|
865
|
-
function
|
|
865
|
+
function qi(e) {
|
|
866
866
|
return [
|
|
867
867
|
ft(e.getAttribute("minx")),
|
|
868
868
|
ft(e.getAttribute("miny")),
|
|
@@ -870,8 +870,8 @@ function ki(e) {
|
|
|
870
870
|
ft(e.getAttribute("maxy"))
|
|
871
871
|
];
|
|
872
872
|
}
|
|
873
|
-
function
|
|
874
|
-
const n =
|
|
873
|
+
function vr(e, t) {
|
|
874
|
+
const n = qi(e), i = [
|
|
875
875
|
ft(e.getAttribute("resx")),
|
|
876
876
|
ft(e.getAttribute("resy"))
|
|
877
877
|
];
|
|
@@ -881,23 +881,23 @@ function pr(e, t) {
|
|
|
881
881
|
res: i
|
|
882
882
|
};
|
|
883
883
|
}
|
|
884
|
-
function
|
|
885
|
-
const n =
|
|
886
|
-
if (!(!
|
|
884
|
+
function wr(e, t) {
|
|
885
|
+
const n = qi(e);
|
|
886
|
+
if (!(!S(n[0]) || !S(n[1]) || !S(n[2]) || !S(n[3])))
|
|
887
887
|
return n;
|
|
888
888
|
}
|
|
889
|
-
function
|
|
889
|
+
function Er(e, t) {
|
|
890
890
|
const n = parseFloat(e.getAttribute("min")), i = parseFloat(e.getAttribute("max"));
|
|
891
891
|
return { min: n, max: i };
|
|
892
892
|
}
|
|
893
|
-
function
|
|
894
|
-
const n =
|
|
893
|
+
function xr(e, t) {
|
|
894
|
+
const n = F(
|
|
895
895
|
{},
|
|
896
|
-
|
|
896
|
+
Xr,
|
|
897
897
|
e,
|
|
898
898
|
t
|
|
899
899
|
);
|
|
900
|
-
if (!
|
|
900
|
+
if (!S(n)) return;
|
|
901
901
|
const i = (
|
|
902
902
|
/** @type {number|undefined} */
|
|
903
903
|
n.westBoundLongitude
|
|
@@ -911,7 +911,7 @@ function mr(e, t) {
|
|
|
911
911
|
/** @type {number|undefined} */
|
|
912
912
|
n.northBoundLatitude
|
|
913
913
|
);
|
|
914
|
-
if (!(!
|
|
914
|
+
if (!(!S(i) || !S(o) || !S(r) || !S(s)))
|
|
915
915
|
return [
|
|
916
916
|
i,
|
|
917
917
|
o,
|
|
@@ -919,91 +919,91 @@ function mr(e, t) {
|
|
|
919
919
|
s
|
|
920
920
|
];
|
|
921
921
|
}
|
|
922
|
-
function
|
|
923
|
-
return
|
|
922
|
+
function Sr(e, t) {
|
|
923
|
+
return F({}, Vr, e, t);
|
|
924
924
|
}
|
|
925
|
-
function
|
|
926
|
-
return
|
|
925
|
+
function $r(e, t) {
|
|
926
|
+
return F({}, kr, e, t);
|
|
927
927
|
}
|
|
928
|
-
function
|
|
929
|
-
return
|
|
928
|
+
function Ar(e, t) {
|
|
929
|
+
return F(
|
|
930
930
|
{},
|
|
931
|
-
|
|
931
|
+
Ur,
|
|
932
932
|
e,
|
|
933
933
|
t
|
|
934
934
|
);
|
|
935
935
|
}
|
|
936
|
-
function
|
|
937
|
-
return
|
|
936
|
+
function _r(e, t) {
|
|
937
|
+
return F(
|
|
938
938
|
{},
|
|
939
|
-
|
|
939
|
+
Fr,
|
|
940
940
|
e,
|
|
941
941
|
t
|
|
942
942
|
);
|
|
943
943
|
}
|
|
944
|
-
function
|
|
945
|
-
return
|
|
944
|
+
function Cr(e, t) {
|
|
945
|
+
return F(
|
|
946
946
|
{},
|
|
947
|
-
|
|
947
|
+
jr,
|
|
948
948
|
e,
|
|
949
949
|
t
|
|
950
950
|
);
|
|
951
951
|
}
|
|
952
|
-
function
|
|
953
|
-
return
|
|
952
|
+
function Tr(e, t) {
|
|
953
|
+
return F(
|
|
954
954
|
[],
|
|
955
|
-
|
|
955
|
+
Zr,
|
|
956
956
|
e,
|
|
957
957
|
t
|
|
958
958
|
);
|
|
959
959
|
}
|
|
960
|
-
function
|
|
961
|
-
const n =
|
|
962
|
-
return
|
|
960
|
+
function Pr(e, t) {
|
|
961
|
+
const n = Ht(e.getAttribute("queryable"));
|
|
962
|
+
return F(
|
|
963
963
|
{
|
|
964
|
-
queryable:
|
|
964
|
+
queryable: S(n) ? n : !1
|
|
965
965
|
},
|
|
966
|
-
|
|
966
|
+
Gi,
|
|
967
967
|
e,
|
|
968
968
|
t
|
|
969
969
|
);
|
|
970
970
|
}
|
|
971
|
-
function
|
|
971
|
+
function Or(e, t) {
|
|
972
972
|
var n = (
|
|
973
973
|
/** @type {Object.<string,*>} */
|
|
974
974
|
t[t.length - 1]
|
|
975
975
|
);
|
|
976
976
|
const i = (
|
|
977
977
|
/** @type {Object.<string,*>} */
|
|
978
|
-
|
|
978
|
+
F(
|
|
979
979
|
{},
|
|
980
|
-
|
|
980
|
+
Gi,
|
|
981
981
|
e,
|
|
982
982
|
t
|
|
983
983
|
)
|
|
984
984
|
);
|
|
985
|
-
if (!
|
|
986
|
-
let o =
|
|
987
|
-
|
|
985
|
+
if (!S(i)) return;
|
|
986
|
+
let o = Ht(e.getAttribute("queryable"));
|
|
987
|
+
S(o) || (o = n.queryable), i.queryable = S(o) ? o : !1;
|
|
988
988
|
let r = Be(e.getAttribute("cascaded"));
|
|
989
|
-
|
|
990
|
-
let s =
|
|
991
|
-
|
|
992
|
-
let a =
|
|
993
|
-
|
|
989
|
+
S(r) || (r = n.cascaded), i.cascaded = r;
|
|
990
|
+
let s = Ht(e.getAttribute("opaque"));
|
|
991
|
+
S(s) || (s = n.opaque), i.opaque = S(s) ? s : !1;
|
|
992
|
+
let a = Ht(e.getAttribute("noSubsets"));
|
|
993
|
+
S(a) || (a = n.noSubsets), i.noSubsets = S(a) ? a : !1;
|
|
994
994
|
let l = ft(e.getAttribute("fixedWidth"));
|
|
995
|
-
|
|
996
|
-
let
|
|
997
|
-
|
|
995
|
+
S(l) || (l = n.fixedWidth), i.fixedWidth = l;
|
|
996
|
+
let u = ft(e.getAttribute("fixedHeight"));
|
|
997
|
+
S(u) || (u = n.fixedHeight), i.fixedHeight = u;
|
|
998
998
|
const c = ["Style", "CRS", "AuthorityURL"];
|
|
999
999
|
for (let p = 0, f = c.length; p < f; p++) {
|
|
1000
1000
|
const g = c[p], y = n[g];
|
|
1001
|
-
if (
|
|
1002
|
-
let
|
|
1003
|
-
|
|
1001
|
+
if (S(y)) {
|
|
1002
|
+
let O = Zi(i, g, []);
|
|
1003
|
+
O = O.concat(y), i[g] = O;
|
|
1004
1004
|
}
|
|
1005
1005
|
}
|
|
1006
|
-
const
|
|
1006
|
+
const d = [
|
|
1007
1007
|
"EX_GeographicBoundingBox",
|
|
1008
1008
|
"BoundingBox",
|
|
1009
1009
|
"Dimension",
|
|
@@ -1011,50 +1011,50 @@ function $r(e, t) {
|
|
|
1011
1011
|
"MinScaleDenominator",
|
|
1012
1012
|
"MaxScaleDenominator"
|
|
1013
1013
|
];
|
|
1014
|
-
for (let p = 0, f =
|
|
1015
|
-
const g =
|
|
1016
|
-
if (!
|
|
1017
|
-
const
|
|
1018
|
-
i[g] =
|
|
1014
|
+
for (let p = 0, f = d.length; p < f; p++) {
|
|
1015
|
+
const g = d[p], y = i[g];
|
|
1016
|
+
if (!S(y)) {
|
|
1017
|
+
const O = n[g];
|
|
1018
|
+
i[g] = O;
|
|
1019
1019
|
}
|
|
1020
1020
|
}
|
|
1021
1021
|
return i;
|
|
1022
1022
|
}
|
|
1023
|
-
function
|
|
1023
|
+
function Dr(e, t) {
|
|
1024
1024
|
return {
|
|
1025
1025
|
name: e.getAttribute("name"),
|
|
1026
1026
|
units: e.getAttribute("units"),
|
|
1027
1027
|
unitSymbol: e.getAttribute("unitSymbol"),
|
|
1028
1028
|
default: e.getAttribute("default"),
|
|
1029
|
-
multipleValues:
|
|
1030
|
-
nearestValue:
|
|
1031
|
-
current:
|
|
1032
|
-
values:
|
|
1029
|
+
multipleValues: Ht(e.getAttribute("multipleValues")),
|
|
1030
|
+
nearestValue: Ht(e.getAttribute("nearestValue")),
|
|
1031
|
+
current: Ht(e.getAttribute("current")),
|
|
1032
|
+
values: A(e)
|
|
1033
1033
|
};
|
|
1034
1034
|
}
|
|
1035
1035
|
function mt(e, t) {
|
|
1036
|
-
return
|
|
1036
|
+
return F(
|
|
1037
1037
|
{},
|
|
1038
|
-
|
|
1038
|
+
Kr,
|
|
1039
1039
|
e,
|
|
1040
1040
|
t
|
|
1041
1041
|
);
|
|
1042
1042
|
}
|
|
1043
|
-
function
|
|
1044
|
-
return
|
|
1043
|
+
function Rr(e, t) {
|
|
1044
|
+
return F({}, qr, e, t);
|
|
1045
1045
|
}
|
|
1046
|
-
function
|
|
1047
|
-
return
|
|
1046
|
+
function Mr(e, t) {
|
|
1047
|
+
return F({}, Wr, e, t);
|
|
1048
1048
|
}
|
|
1049
|
-
function
|
|
1050
|
-
return
|
|
1049
|
+
function Ir(e, t) {
|
|
1050
|
+
return F({}, Gr, e, t);
|
|
1051
1051
|
}
|
|
1052
|
-
function
|
|
1053
|
-
return
|
|
1052
|
+
function En(e, t) {
|
|
1053
|
+
return F({}, Yr, e, t);
|
|
1054
1054
|
}
|
|
1055
|
-
function
|
|
1055
|
+
function Yi(e, t) {
|
|
1056
1056
|
var n = mt(e, t);
|
|
1057
|
-
if (
|
|
1057
|
+
if (S(n)) {
|
|
1058
1058
|
const i = [
|
|
1059
1059
|
Be(e.getAttribute("width")),
|
|
1060
1060
|
Be(e.getAttribute("height"))
|
|
@@ -1062,156 +1062,156 @@ function Fi(e, t) {
|
|
|
1062
1062
|
return n.size = i, n;
|
|
1063
1063
|
}
|
|
1064
1064
|
}
|
|
1065
|
-
function
|
|
1065
|
+
function Nr(e, t) {
|
|
1066
1066
|
var n = mt(e, t);
|
|
1067
|
-
if (
|
|
1067
|
+
if (S(n))
|
|
1068
1068
|
return n.name = e.getAttribute("name"), n;
|
|
1069
1069
|
}
|
|
1070
|
-
function
|
|
1070
|
+
function Hr(e, t) {
|
|
1071
1071
|
var n = mt(e, t);
|
|
1072
|
-
if (
|
|
1072
|
+
if (S(n))
|
|
1073
1073
|
return n.type = e.getAttribute("type"), n;
|
|
1074
1074
|
}
|
|
1075
|
-
function
|
|
1076
|
-
return
|
|
1075
|
+
function Lr(e, t) {
|
|
1076
|
+
return F({}, Jr, e, t);
|
|
1077
1077
|
}
|
|
1078
|
-
function
|
|
1079
|
-
return
|
|
1078
|
+
function Wi(e, t) {
|
|
1079
|
+
return F(
|
|
1080
1080
|
[],
|
|
1081
|
-
|
|
1081
|
+
Qr,
|
|
1082
1082
|
e,
|
|
1083
1083
|
t
|
|
1084
1084
|
);
|
|
1085
1085
|
}
|
|
1086
|
-
const
|
|
1086
|
+
const Y = [
|
|
1087
1087
|
null,
|
|
1088
1088
|
"http://www.opengis.net/wms"
|
|
1089
|
-
],
|
|
1090
|
-
|
|
1089
|
+
], Br = q(
|
|
1090
|
+
Y,
|
|
1091
1091
|
{
|
|
1092
|
-
Service: m(
|
|
1093
|
-
Capability: m(
|
|
1092
|
+
Service: m($r),
|
|
1093
|
+
Capability: m(Sr)
|
|
1094
1094
|
}
|
|
1095
|
-
),
|
|
1096
|
-
|
|
1095
|
+
), Vr = q(
|
|
1096
|
+
Y,
|
|
1097
1097
|
{
|
|
1098
|
-
Request: m(
|
|
1099
|
-
Exception: m(
|
|
1100
|
-
Layer: m(
|
|
1098
|
+
Request: m(Rr),
|
|
1099
|
+
Exception: m(Tr),
|
|
1100
|
+
Layer: m(Pr)
|
|
1101
1101
|
}
|
|
1102
|
-
),
|
|
1103
|
-
|
|
1102
|
+
), kr = q(
|
|
1103
|
+
Y,
|
|
1104
1104
|
{
|
|
1105
|
-
Name: m(
|
|
1106
|
-
Title: m(
|
|
1107
|
-
Abstract: m(
|
|
1108
|
-
KeywordList: m(
|
|
1109
|
-
OnlineResource: m(
|
|
1110
|
-
ContactInformation: m(
|
|
1111
|
-
Fees: m(
|
|
1112
|
-
AccessConstraints: m(
|
|
1113
|
-
LayerLimit: m(
|
|
1114
|
-
MaxWidth: m(
|
|
1115
|
-
MaxHeight: m(
|
|
1116
|
-
}
|
|
1117
|
-
),
|
|
1118
|
-
|
|
1105
|
+
Name: m(A),
|
|
1106
|
+
Title: m(A),
|
|
1107
|
+
Abstract: m(A),
|
|
1108
|
+
KeywordList: m(Wi),
|
|
1109
|
+
OnlineResource: m(Yn),
|
|
1110
|
+
ContactInformation: m(Ar),
|
|
1111
|
+
Fees: m(A),
|
|
1112
|
+
AccessConstraints: m(A),
|
|
1113
|
+
LayerLimit: m(wn),
|
|
1114
|
+
MaxWidth: m(wn),
|
|
1115
|
+
MaxHeight: m(wn)
|
|
1116
|
+
}
|
|
1117
|
+
), Ur = q(
|
|
1118
|
+
Y,
|
|
1119
1119
|
{
|
|
1120
|
-
ContactPersonPrimary: m(
|
|
1121
|
-
ContactPosition: m(
|
|
1122
|
-
ContactAddress: m(
|
|
1123
|
-
ContactVoiceTelephone: m(
|
|
1124
|
-
ContactFacsimileTelephone: m(
|
|
1125
|
-
ContactElectronicMailAddress: m(
|
|
1126
|
-
}
|
|
1127
|
-
),
|
|
1128
|
-
|
|
1120
|
+
ContactPersonPrimary: m(_r),
|
|
1121
|
+
ContactPosition: m(A),
|
|
1122
|
+
ContactAddress: m(Cr),
|
|
1123
|
+
ContactVoiceTelephone: m(A),
|
|
1124
|
+
ContactFacsimileTelephone: m(A),
|
|
1125
|
+
ContactElectronicMailAddress: m(A)
|
|
1126
|
+
}
|
|
1127
|
+
), Fr = q(
|
|
1128
|
+
Y,
|
|
1129
1129
|
{
|
|
1130
|
-
ContactPerson: m(
|
|
1131
|
-
ContactOrganization: m(
|
|
1130
|
+
ContactPerson: m(A),
|
|
1131
|
+
ContactOrganization: m(A)
|
|
1132
1132
|
}
|
|
1133
|
-
),
|
|
1134
|
-
|
|
1133
|
+
), jr = q(
|
|
1134
|
+
Y,
|
|
1135
1135
|
{
|
|
1136
|
-
AddressType: m(
|
|
1137
|
-
Address: m(
|
|
1138
|
-
City: m(
|
|
1139
|
-
StateOrProvince: m(
|
|
1140
|
-
PostCode: m(
|
|
1141
|
-
Country: m(
|
|
1142
|
-
}
|
|
1143
|
-
),
|
|
1144
|
-
|
|
1136
|
+
AddressType: m(A),
|
|
1137
|
+
Address: m(A),
|
|
1138
|
+
City: m(A),
|
|
1139
|
+
StateOrProvince: m(A),
|
|
1140
|
+
PostCode: m(A),
|
|
1141
|
+
Country: m(A)
|
|
1142
|
+
}
|
|
1143
|
+
), Zr = q(
|
|
1144
|
+
Y,
|
|
1145
1145
|
{
|
|
1146
|
-
Format:
|
|
1146
|
+
Format: Xi(A)
|
|
1147
1147
|
}
|
|
1148
|
-
),
|
|
1149
|
-
|
|
1148
|
+
), Gi = q(
|
|
1149
|
+
Y,
|
|
1150
1150
|
{
|
|
1151
|
-
Name: m(
|
|
1152
|
-
Title: m(
|
|
1153
|
-
Abstract: m(
|
|
1154
|
-
KeywordList: m(
|
|
1155
|
-
CRS:
|
|
1156
|
-
SRS:
|
|
1157
|
-
EX_GeographicBoundingBox: m(
|
|
1158
|
-
LatLonBoundingBox: m(
|
|
1159
|
-
BoundingBox:
|
|
1160
|
-
Dimension:
|
|
1161
|
-
Attribution: m(
|
|
1162
|
-
AuthorityURL:
|
|
1163
|
-
Identifier:
|
|
1164
|
-
MetadataURL:
|
|
1165
|
-
DataURL:
|
|
1166
|
-
FeatureListURL:
|
|
1167
|
-
Style:
|
|
1168
|
-
MinScaleDenominator: m(
|
|
1169
|
-
MaxScaleDenominator: m(
|
|
1170
|
-
ScaleHint: m(
|
|
1171
|
-
Layer:
|
|
1172
|
-
}
|
|
1173
|
-
),
|
|
1174
|
-
|
|
1151
|
+
Name: m(A),
|
|
1152
|
+
Title: m(A),
|
|
1153
|
+
Abstract: m(A),
|
|
1154
|
+
KeywordList: m(Wi),
|
|
1155
|
+
CRS: et(A),
|
|
1156
|
+
SRS: et(A),
|
|
1157
|
+
EX_GeographicBoundingBox: m(xr),
|
|
1158
|
+
LatLonBoundingBox: m(wr),
|
|
1159
|
+
BoundingBox: et(vr),
|
|
1160
|
+
Dimension: et(Dr),
|
|
1161
|
+
Attribution: m(br),
|
|
1162
|
+
AuthorityURL: et(Nr),
|
|
1163
|
+
Identifier: et(A),
|
|
1164
|
+
MetadataURL: et(Hr),
|
|
1165
|
+
DataURL: et(mt),
|
|
1166
|
+
FeatureListURL: et(mt),
|
|
1167
|
+
Style: et(Lr),
|
|
1168
|
+
MinScaleDenominator: m(jt),
|
|
1169
|
+
MaxScaleDenominator: m(jt),
|
|
1170
|
+
ScaleHint: m(Er),
|
|
1171
|
+
Layer: et(Or)
|
|
1172
|
+
}
|
|
1173
|
+
), zr = q(
|
|
1174
|
+
Y,
|
|
1175
1175
|
{
|
|
1176
|
-
Title: m(
|
|
1177
|
-
OnlineResource: m(
|
|
1178
|
-
LogoURL: m(
|
|
1179
|
-
}
|
|
1180
|
-
),
|
|
1181
|
-
westBoundLongitude: m(
|
|
1182
|
-
eastBoundLongitude: m(
|
|
1183
|
-
southBoundLatitude: m(
|
|
1184
|
-
northBoundLatitude: m(
|
|
1185
|
-
}),
|
|
1186
|
-
|
|
1176
|
+
Title: m(A),
|
|
1177
|
+
OnlineResource: m(Yn),
|
|
1178
|
+
LogoURL: m(Yi)
|
|
1179
|
+
}
|
|
1180
|
+
), Xr = q(Y, {
|
|
1181
|
+
westBoundLongitude: m(jt),
|
|
1182
|
+
eastBoundLongitude: m(jt),
|
|
1183
|
+
southBoundLatitude: m(jt),
|
|
1184
|
+
northBoundLatitude: m(jt)
|
|
1185
|
+
}), qr = q(
|
|
1186
|
+
Y,
|
|
1187
1187
|
{
|
|
1188
1188
|
GetCapabilities: m(
|
|
1189
|
-
|
|
1189
|
+
En
|
|
1190
1190
|
),
|
|
1191
1191
|
GetMap: m(
|
|
1192
|
-
|
|
1192
|
+
En
|
|
1193
1193
|
),
|
|
1194
1194
|
GetFeatureInfo: m(
|
|
1195
|
-
|
|
1195
|
+
En
|
|
1196
1196
|
)
|
|
1197
1197
|
}
|
|
1198
|
-
),
|
|
1199
|
-
|
|
1198
|
+
), Yr = q(
|
|
1199
|
+
Y,
|
|
1200
1200
|
{
|
|
1201
|
-
Format:
|
|
1202
|
-
DCPType:
|
|
1203
|
-
|
|
1201
|
+
Format: et(A),
|
|
1202
|
+
DCPType: et(
|
|
1203
|
+
Mr
|
|
1204
1204
|
)
|
|
1205
1205
|
}
|
|
1206
|
-
),
|
|
1207
|
-
|
|
1206
|
+
), Wr = q(
|
|
1207
|
+
Y,
|
|
1208
1208
|
{
|
|
1209
1209
|
HTTP: m(
|
|
1210
|
-
|
|
1210
|
+
Ir
|
|
1211
1211
|
)
|
|
1212
1212
|
}
|
|
1213
|
-
),
|
|
1214
|
-
|
|
1213
|
+
), Gr = q(
|
|
1214
|
+
Y,
|
|
1215
1215
|
{
|
|
1216
1216
|
Get: m(
|
|
1217
1217
|
mt
|
|
@@ -1220,29 +1220,29 @@ const Z = [
|
|
|
1220
1220
|
mt
|
|
1221
1221
|
)
|
|
1222
1222
|
}
|
|
1223
|
-
),
|
|
1224
|
-
|
|
1223
|
+
), Jr = q(
|
|
1224
|
+
Y,
|
|
1225
1225
|
{
|
|
1226
|
-
Name: m(
|
|
1227
|
-
Title: m(
|
|
1228
|
-
Abstract: m(
|
|
1229
|
-
LegendURL:
|
|
1226
|
+
Name: m(A),
|
|
1227
|
+
Title: m(A),
|
|
1228
|
+
Abstract: m(A),
|
|
1229
|
+
LegendURL: et(Yi),
|
|
1230
1230
|
StyleSheetURL: m(mt),
|
|
1231
1231
|
StyleURL: m(mt)
|
|
1232
1232
|
}
|
|
1233
|
-
),
|
|
1234
|
-
|
|
1233
|
+
), Kr = q(
|
|
1234
|
+
Y,
|
|
1235
1235
|
{
|
|
1236
|
-
Format: m(
|
|
1237
|
-
OnlineResource: m(
|
|
1236
|
+
Format: m(A),
|
|
1237
|
+
OnlineResource: m(Yn)
|
|
1238
1238
|
}
|
|
1239
|
-
),
|
|
1240
|
-
|
|
1239
|
+
), Qr = q(
|
|
1240
|
+
Y,
|
|
1241
1241
|
{
|
|
1242
|
-
Keyword:
|
|
1242
|
+
Keyword: Xi(A)
|
|
1243
1243
|
}
|
|
1244
1244
|
);
|
|
1245
|
-
class
|
|
1245
|
+
class ts {
|
|
1246
1246
|
/**
|
|
1247
1247
|
* WMS Capabilities parser
|
|
1248
1248
|
*
|
|
@@ -1250,7 +1250,7 @@ class Yr {
|
|
|
1250
1250
|
* @constructor
|
|
1251
1251
|
*/
|
|
1252
1252
|
constructor(t, n) {
|
|
1253
|
-
!n && typeof window < "u" && (n = window.DOMParser), this.version = void 0, this._parser = new
|
|
1253
|
+
!n && typeof window < "u" && (n = window.DOMParser), this.version = void 0, this._parser = new dr(n), this._data = t;
|
|
1254
1254
|
}
|
|
1255
1255
|
/**
|
|
1256
1256
|
* @param {String} xmlString
|
|
@@ -1279,7 +1279,7 @@ class Yr {
|
|
|
1279
1279
|
*/
|
|
1280
1280
|
readFromDocument(t) {
|
|
1281
1281
|
for (let n = t.firstChild; n; n = n.nextSibling)
|
|
1282
|
-
if (n.nodeType ==
|
|
1282
|
+
if (n.nodeType == ge.ELEMENT)
|
|
1283
1283
|
return this.readFromNode(n);
|
|
1284
1284
|
return null;
|
|
1285
1285
|
}
|
|
@@ -1288,44 +1288,44 @@ class Yr {
|
|
|
1288
1288
|
* @return {Object}
|
|
1289
1289
|
*/
|
|
1290
1290
|
readFromNode(t) {
|
|
1291
|
-
return this.version = t.getAttribute("version"),
|
|
1291
|
+
return this.version = t.getAttribute("version"), F({
|
|
1292
1292
|
version: this.version
|
|
1293
|
-
},
|
|
1293
|
+
}, Br, t, []) || null;
|
|
1294
1294
|
}
|
|
1295
1295
|
}
|
|
1296
|
-
async function
|
|
1296
|
+
async function es(e) {
|
|
1297
1297
|
let t = new URL(e), n = t.searchParams;
|
|
1298
1298
|
n.set("SERVICE", "WMS"), n.set("REQUEST", "GetCapabilities");
|
|
1299
1299
|
let i = t.toString();
|
|
1300
1300
|
const o = await fetch(i);
|
|
1301
1301
|
if (o.ok) {
|
|
1302
1302
|
const r = await o.text();
|
|
1303
|
-
return new
|
|
1303
|
+
return new ts(r).toJSON();
|
|
1304
1304
|
} else
|
|
1305
1305
|
throw new Error(`Error: ${o.status}`);
|
|
1306
1306
|
}
|
|
1307
|
-
function
|
|
1307
|
+
function Wn(e) {
|
|
1308
1308
|
const t = /\b(?:wms|ows)\b/i, n = /{(?:z|x|y-?)}\/{(?:z|x|y-?)}\/{(?:z|x|y-?)}/i;
|
|
1309
1309
|
return t.test(e) ? "TileWMS" : n.test(e) ? "XYZ" : !1;
|
|
1310
1310
|
}
|
|
1311
|
-
function
|
|
1312
|
-
const n = /^(?:(?:https?|ftp):\/\/|\/\/)?(?:localhost|\d{1,3}\.\d{1,3}\.\d{1,3}\.\d{1,3}|(?:\w+[\w-]*\.)+\w+)(?::\d+)?(?:\/\S*)?$/.test(e), i =
|
|
1311
|
+
function ns(e) {
|
|
1312
|
+
const n = /^(?:(?:https?|ftp):\/\/|\/\/)?(?:localhost|\d{1,3}\.\d{1,3}\.\d{1,3}\.\d{1,3}|(?:\w+[\w-]*\.)+\w+)(?::\d+)?(?:\/\S*)?$/.test(e), i = Wn(e);
|
|
1313
1313
|
return !!(e && n && i);
|
|
1314
1314
|
}
|
|
1315
|
-
function
|
|
1315
|
+
function Ji(e) {
|
|
1316
1316
|
return e.replace(
|
|
1317
1317
|
/(['"])?([a-zA-Z0-9_]+)(['"])?:/g,
|
|
1318
1318
|
'"$2": '
|
|
1319
1319
|
).replace(/,\s*}/g, "}").replace(/,\s*]/g, "]").replace(/\s*(\{|}|\[|\]|,)\s*/g, "$1").replaceAll('": //', "://");
|
|
1320
1320
|
}
|
|
1321
|
-
function
|
|
1321
|
+
function is(e) {
|
|
1322
1322
|
try {
|
|
1323
|
-
return JSON.parse(
|
|
1323
|
+
return JSON.parse(Ji(e)), !!e;
|
|
1324
1324
|
} catch {
|
|
1325
1325
|
return !1;
|
|
1326
1326
|
}
|
|
1327
1327
|
}
|
|
1328
|
-
function
|
|
1328
|
+
function os(e, t) {
|
|
1329
1329
|
const n = new URL(e).searchParams;
|
|
1330
1330
|
Object.entries(t).forEach(([s, a]) => {
|
|
1331
1331
|
typeof a == "object" && !Array.isArray(a) && a !== null ? Object.keys(a).forEach((l) => {
|
|
@@ -1341,7 +1341,7 @@ function Kr(e, t) {
|
|
|
1341
1341
|
* @author owenm <owen23355@gmail.com>
|
|
1342
1342
|
* @license MIT
|
|
1343
1343
|
*/
|
|
1344
|
-
function
|
|
1344
|
+
function fi(e, t) {
|
|
1345
1345
|
var n = Object.keys(e);
|
|
1346
1346
|
if (Object.getOwnPropertySymbols) {
|
|
1347
1347
|
var i = Object.getOwnPropertySymbols(e);
|
|
@@ -1354,23 +1354,23 @@ function ci(e, t) {
|
|
|
1354
1354
|
function ct(e) {
|
|
1355
1355
|
for (var t = 1; t < arguments.length; t++) {
|
|
1356
1356
|
var n = arguments[t] != null ? arguments[t] : {};
|
|
1357
|
-
t % 2 ?
|
|
1358
|
-
|
|
1359
|
-
}) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(n)) :
|
|
1357
|
+
t % 2 ? fi(Object(n), !0).forEach(function(i) {
|
|
1358
|
+
rs(e, i, n[i]);
|
|
1359
|
+
}) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(n)) : fi(Object(n)).forEach(function(i) {
|
|
1360
1360
|
Object.defineProperty(e, i, Object.getOwnPropertyDescriptor(n, i));
|
|
1361
1361
|
});
|
|
1362
1362
|
}
|
|
1363
1363
|
return e;
|
|
1364
1364
|
}
|
|
1365
|
-
function
|
|
1365
|
+
function Pe(e) {
|
|
1366
1366
|
"@babel/helpers - typeof";
|
|
1367
|
-
return typeof Symbol == "function" && typeof Symbol.iterator == "symbol" ?
|
|
1367
|
+
return typeof Symbol == "function" && typeof Symbol.iterator == "symbol" ? Pe = function(t) {
|
|
1368
1368
|
return typeof t;
|
|
1369
|
-
} :
|
|
1369
|
+
} : Pe = function(t) {
|
|
1370
1370
|
return t && typeof Symbol == "function" && t.constructor === Symbol && t !== Symbol.prototype ? "symbol" : typeof t;
|
|
1371
|
-
},
|
|
1371
|
+
}, Pe(e);
|
|
1372
1372
|
}
|
|
1373
|
-
function
|
|
1373
|
+
function rs(e, t, n) {
|
|
1374
1374
|
return t in e ? Object.defineProperty(e, t, {
|
|
1375
1375
|
value: n,
|
|
1376
1376
|
enumerable: !0,
|
|
@@ -1388,16 +1388,16 @@ function yt() {
|
|
|
1388
1388
|
return e;
|
|
1389
1389
|
}, yt.apply(this, arguments);
|
|
1390
1390
|
}
|
|
1391
|
-
function
|
|
1391
|
+
function ss(e, t) {
|
|
1392
1392
|
if (e == null) return {};
|
|
1393
1393
|
var n = {}, i = Object.keys(e), o, r;
|
|
1394
1394
|
for (r = 0; r < i.length; r++)
|
|
1395
1395
|
o = i[r], !(t.indexOf(o) >= 0) && (n[o] = e[o]);
|
|
1396
1396
|
return n;
|
|
1397
1397
|
}
|
|
1398
|
-
function
|
|
1398
|
+
function as(e, t) {
|
|
1399
1399
|
if (e == null) return {};
|
|
1400
|
-
var n =
|
|
1400
|
+
var n = ss(e, t), i, o;
|
|
1401
1401
|
if (Object.getOwnPropertySymbols) {
|
|
1402
1402
|
var r = Object.getOwnPropertySymbols(e);
|
|
1403
1403
|
for (o = 0; o < r.length; o++)
|
|
@@ -1405,20 +1405,20 @@ function es(e, t) {
|
|
|
1405
1405
|
}
|
|
1406
1406
|
return n;
|
|
1407
1407
|
}
|
|
1408
|
-
var
|
|
1408
|
+
var ls = "1.15.3";
|
|
1409
1409
|
function gt(e) {
|
|
1410
1410
|
if (typeof window < "u" && window.navigator)
|
|
1411
1411
|
return !!/* @__PURE__ */ navigator.userAgent.match(e);
|
|
1412
1412
|
}
|
|
1413
|
-
var bt = gt(/(?:Trident.*rv[ :]?11\.|msie|iemobile|Windows Phone)/i),
|
|
1413
|
+
var bt = gt(/(?:Trident.*rv[ :]?11\.|msie|iemobile|Windows Phone)/i), Ee = gt(/Edge/i), gi = gt(/firefox/i), ae = gt(/safari/i) && !gt(/chrome/i) && !gt(/android/i), Ki = gt(/iP(ad|od|hone)/i), Qi = gt(/chrome/i) && gt(/android/i), to = {
|
|
1414
1414
|
capture: !1,
|
|
1415
1415
|
passive: !1
|
|
1416
1416
|
};
|
|
1417
1417
|
function _(e, t, n) {
|
|
1418
|
-
e.addEventListener(t, n, !bt &&
|
|
1418
|
+
e.addEventListener(t, n, !bt && to);
|
|
1419
1419
|
}
|
|
1420
|
-
function
|
|
1421
|
-
e.removeEventListener(t, n, !bt &&
|
|
1420
|
+
function $(e, t, n) {
|
|
1421
|
+
e.removeEventListener(t, n, !bt && to);
|
|
1422
1422
|
}
|
|
1423
1423
|
function Ve(e, t) {
|
|
1424
1424
|
if (t) {
|
|
@@ -1436,31 +1436,31 @@ function Ve(e, t) {
|
|
|
1436
1436
|
return !1;
|
|
1437
1437
|
}
|
|
1438
1438
|
}
|
|
1439
|
-
function
|
|
1439
|
+
function eo(e) {
|
|
1440
1440
|
return e.host && e !== document && e.host.nodeType ? e.host : e.parentNode;
|
|
1441
1441
|
}
|
|
1442
|
-
function
|
|
1442
|
+
function ut(e, t, n, i) {
|
|
1443
1443
|
if (e) {
|
|
1444
1444
|
n = n || document;
|
|
1445
1445
|
do {
|
|
1446
1446
|
if (t != null && (t[0] === ">" ? e.parentNode === n && Ve(e, t) : Ve(e, t)) || i && e === n)
|
|
1447
1447
|
return e;
|
|
1448
1448
|
if (e === n) break;
|
|
1449
|
-
} while (e =
|
|
1449
|
+
} while (e = eo(e));
|
|
1450
1450
|
}
|
|
1451
1451
|
return null;
|
|
1452
1452
|
}
|
|
1453
|
-
var
|
|
1454
|
-
function
|
|
1453
|
+
var mi = /\s+/g;
|
|
1454
|
+
function ot(e, t, n) {
|
|
1455
1455
|
if (e && t)
|
|
1456
1456
|
if (e.classList)
|
|
1457
1457
|
e.classList[n ? "add" : "remove"](t);
|
|
1458
1458
|
else {
|
|
1459
|
-
var i = (" " + e.className + " ").replace(
|
|
1460
|
-
e.className = (i + (n ? " " + t : "")).replace(
|
|
1459
|
+
var i = (" " + e.className + " ").replace(mi, " ").replace(" " + t + " ", " ");
|
|
1460
|
+
e.className = (i + (n ? " " + t : "")).replace(mi, " ");
|
|
1461
1461
|
}
|
|
1462
1462
|
}
|
|
1463
|
-
function
|
|
1463
|
+
function v(e, t, n) {
|
|
1464
1464
|
var i = e && e.style;
|
|
1465
1465
|
if (i) {
|
|
1466
1466
|
if (n === void 0)
|
|
@@ -1468,19 +1468,19 @@ function b(e, t, n) {
|
|
|
1468
1468
|
!(t in i) && t.indexOf("webkit") === -1 && (t = "-webkit-" + t), i[t] = n + (typeof n == "string" ? "" : "px");
|
|
1469
1469
|
}
|
|
1470
1470
|
}
|
|
1471
|
-
function
|
|
1471
|
+
function zt(e, t) {
|
|
1472
1472
|
var n = "";
|
|
1473
1473
|
if (typeof e == "string")
|
|
1474
1474
|
n = e;
|
|
1475
1475
|
else
|
|
1476
1476
|
do {
|
|
1477
|
-
var i =
|
|
1477
|
+
var i = v(e, "transform");
|
|
1478
1478
|
i && i !== "none" && (n = i + " " + n);
|
|
1479
1479
|
} while (!t && (e = e.parentNode));
|
|
1480
1480
|
var o = window.DOMMatrix || window.WebKitCSSMatrix || window.CSSMatrix || window.MSCSSMatrix;
|
|
1481
1481
|
return o && new o(n);
|
|
1482
1482
|
}
|
|
1483
|
-
function
|
|
1483
|
+
function no(e, t, n) {
|
|
1484
1484
|
if (e) {
|
|
1485
1485
|
var i = e.getElementsByTagName(t), o = 0, r = i.length;
|
|
1486
1486
|
if (n)
|
|
@@ -1490,47 +1490,47 @@ function Gi(e, t, n) {
|
|
|
1490
1490
|
}
|
|
1491
1491
|
return [];
|
|
1492
1492
|
}
|
|
1493
|
-
function
|
|
1493
|
+
function dt() {
|
|
1494
1494
|
var e = document.scrollingElement;
|
|
1495
1495
|
return e || document.documentElement;
|
|
1496
1496
|
}
|
|
1497
|
-
function
|
|
1497
|
+
function k(e, t, n, i, o) {
|
|
1498
1498
|
if (!(!e.getBoundingClientRect && e !== window)) {
|
|
1499
|
-
var r, s, a, l,
|
|
1500
|
-
if (e !== window && e.parentNode && e !==
|
|
1499
|
+
var r, s, a, l, u, c, d;
|
|
1500
|
+
if (e !== window && e.parentNode && e !== dt() ? (r = e.getBoundingClientRect(), s = r.top, a = r.left, l = r.bottom, u = r.right, c = r.height, d = r.width) : (s = 0, a = 0, l = window.innerHeight, u = window.innerWidth, c = window.innerHeight, d = window.innerWidth), (t || n) && e !== window && (o = o || e.parentNode, !bt))
|
|
1501
1501
|
do
|
|
1502
|
-
if (o && o.getBoundingClientRect && (
|
|
1502
|
+
if (o && o.getBoundingClientRect && (v(o, "transform") !== "none" || n && v(o, "position") !== "static")) {
|
|
1503
1503
|
var p = o.getBoundingClientRect();
|
|
1504
|
-
s -= p.top + parseInt(
|
|
1504
|
+
s -= p.top + parseInt(v(o, "border-top-width")), a -= p.left + parseInt(v(o, "border-left-width")), l = s + r.height, u = a + r.width;
|
|
1505
1505
|
break;
|
|
1506
1506
|
}
|
|
1507
1507
|
while (o = o.parentNode);
|
|
1508
1508
|
if (i && e !== window) {
|
|
1509
|
-
var f =
|
|
1510
|
-
f && (s /= y, a /= g,
|
|
1509
|
+
var f = zt(o || e), g = f && f.a, y = f && f.d;
|
|
1510
|
+
f && (s /= y, a /= g, d /= g, c /= y, l = s + c, u = a + d);
|
|
1511
1511
|
}
|
|
1512
1512
|
return {
|
|
1513
1513
|
top: s,
|
|
1514
1514
|
left: a,
|
|
1515
1515
|
bottom: l,
|
|
1516
|
-
right:
|
|
1517
|
-
width:
|
|
1516
|
+
right: u,
|
|
1517
|
+
width: d,
|
|
1518
1518
|
height: c
|
|
1519
1519
|
};
|
|
1520
1520
|
}
|
|
1521
1521
|
}
|
|
1522
|
-
function
|
|
1523
|
-
for (var i =
|
|
1524
|
-
var r =
|
|
1522
|
+
function yi(e, t, n) {
|
|
1523
|
+
for (var i = At(e, !0), o = k(e)[t]; i; ) {
|
|
1524
|
+
var r = k(i)[n], s = void 0;
|
|
1525
1525
|
if (s = o >= r, !s) return i;
|
|
1526
|
-
if (i ===
|
|
1527
|
-
i =
|
|
1526
|
+
if (i === dt()) break;
|
|
1527
|
+
i = At(i, !1);
|
|
1528
1528
|
}
|
|
1529
1529
|
return !1;
|
|
1530
1530
|
}
|
|
1531
|
-
function
|
|
1531
|
+
function qt(e, t, n, i) {
|
|
1532
1532
|
for (var o = 0, r = 0, s = e.children; r < s.length; ) {
|
|
1533
|
-
if (s[r].style.display !== "none" && s[r] !==
|
|
1533
|
+
if (s[r].style.display !== "none" && s[r] !== w.ghost && (i || s[r] !== w.dragged) && ut(s[r], n.draggable, e, !1)) {
|
|
1534
1534
|
if (o === t)
|
|
1535
1535
|
return s[r];
|
|
1536
1536
|
o++;
|
|
@@ -1539,29 +1539,29 @@ function Xt(e, t, n, i) {
|
|
|
1539
1539
|
}
|
|
1540
1540
|
return null;
|
|
1541
1541
|
}
|
|
1542
|
-
function
|
|
1543
|
-
for (var n = e.lastElementChild; n && (n ===
|
|
1542
|
+
function Gn(e, t) {
|
|
1543
|
+
for (var n = e.lastElementChild; n && (n === w.ghost || v(n, "display") === "none" || t && !Ve(n, t)); )
|
|
1544
1544
|
n = n.previousElementSibling;
|
|
1545
1545
|
return n || null;
|
|
1546
1546
|
}
|
|
1547
|
-
function
|
|
1547
|
+
function st(e, t) {
|
|
1548
1548
|
var n = 0;
|
|
1549
1549
|
if (!e || !e.parentNode)
|
|
1550
1550
|
return -1;
|
|
1551
1551
|
for (; e = e.previousElementSibling; )
|
|
1552
|
-
e.nodeName.toUpperCase() !== "TEMPLATE" && e !==
|
|
1552
|
+
e.nodeName.toUpperCase() !== "TEMPLATE" && e !== w.clone && (!t || Ve(e, t)) && n++;
|
|
1553
1553
|
return n;
|
|
1554
1554
|
}
|
|
1555
|
-
function
|
|
1556
|
-
var t = 0, n = 0, i =
|
|
1555
|
+
function bi(e) {
|
|
1556
|
+
var t = 0, n = 0, i = dt();
|
|
1557
1557
|
if (e)
|
|
1558
1558
|
do {
|
|
1559
|
-
var o =
|
|
1559
|
+
var o = zt(e), r = o.a, s = o.d;
|
|
1560
1560
|
t += e.scrollLeft * r, n += e.scrollTop * s;
|
|
1561
1561
|
} while (e !== i && (e = e.parentNode));
|
|
1562
1562
|
return [t, n];
|
|
1563
1563
|
}
|
|
1564
|
-
function
|
|
1564
|
+
function us(e, t) {
|
|
1565
1565
|
for (var n in e)
|
|
1566
1566
|
if (e.hasOwnProperty(n)) {
|
|
1567
1567
|
for (var i in t)
|
|
@@ -1569,77 +1569,77 @@ function is(e, t) {
|
|
|
1569
1569
|
}
|
|
1570
1570
|
return -1;
|
|
1571
1571
|
}
|
|
1572
|
-
function
|
|
1573
|
-
if (!e || !e.getBoundingClientRect) return
|
|
1572
|
+
function At(e, t) {
|
|
1573
|
+
if (!e || !e.getBoundingClientRect) return dt();
|
|
1574
1574
|
var n = e, i = !1;
|
|
1575
1575
|
do
|
|
1576
1576
|
if (n.clientWidth < n.scrollWidth || n.clientHeight < n.scrollHeight) {
|
|
1577
|
-
var o =
|
|
1577
|
+
var o = v(n);
|
|
1578
1578
|
if (n.clientWidth < n.scrollWidth && (o.overflowX == "auto" || o.overflowX == "scroll") || n.clientHeight < n.scrollHeight && (o.overflowY == "auto" || o.overflowY == "scroll")) {
|
|
1579
|
-
if (!n.getBoundingClientRect || n === document.body) return
|
|
1579
|
+
if (!n.getBoundingClientRect || n === document.body) return dt();
|
|
1580
1580
|
if (i || t) return n;
|
|
1581
1581
|
i = !0;
|
|
1582
1582
|
}
|
|
1583
1583
|
}
|
|
1584
1584
|
while (n = n.parentNode);
|
|
1585
|
-
return
|
|
1585
|
+
return dt();
|
|
1586
1586
|
}
|
|
1587
|
-
function
|
|
1587
|
+
function ds(e, t) {
|
|
1588
1588
|
if (e && t)
|
|
1589
1589
|
for (var n in t)
|
|
1590
1590
|
t.hasOwnProperty(n) && (e[n] = t[n]);
|
|
1591
1591
|
return e;
|
|
1592
1592
|
}
|
|
1593
|
-
function
|
|
1593
|
+
function xn(e, t) {
|
|
1594
1594
|
return Math.round(e.top) === Math.round(t.top) && Math.round(e.left) === Math.round(t.left) && Math.round(e.height) === Math.round(t.height) && Math.round(e.width) === Math.round(t.width);
|
|
1595
1595
|
}
|
|
1596
|
-
var
|
|
1597
|
-
function
|
|
1596
|
+
var le;
|
|
1597
|
+
function io(e, t) {
|
|
1598
1598
|
return function() {
|
|
1599
|
-
if (!
|
|
1599
|
+
if (!le) {
|
|
1600
1600
|
var n = arguments, i = this;
|
|
1601
|
-
n.length === 1 ? e.call(i, n[0]) : e.apply(i, n),
|
|
1602
|
-
|
|
1601
|
+
n.length === 1 ? e.call(i, n[0]) : e.apply(i, n), le = setTimeout(function() {
|
|
1602
|
+
le = void 0;
|
|
1603
1603
|
}, t);
|
|
1604
1604
|
}
|
|
1605
1605
|
};
|
|
1606
1606
|
}
|
|
1607
|
-
function
|
|
1608
|
-
clearTimeout(
|
|
1607
|
+
function cs() {
|
|
1608
|
+
clearTimeout(le), le = void 0;
|
|
1609
1609
|
}
|
|
1610
|
-
function
|
|
1610
|
+
function oo(e, t, n) {
|
|
1611
1611
|
e.scrollLeft += t, e.scrollTop += n;
|
|
1612
1612
|
}
|
|
1613
|
-
function
|
|
1613
|
+
function ro(e) {
|
|
1614
1614
|
var t = window.Polymer, n = window.jQuery || window.Zepto;
|
|
1615
1615
|
return t && t.dom ? t.dom(e).cloneNode(!0) : n ? n(e).clone(!0)[0] : e.cloneNode(!0);
|
|
1616
1616
|
}
|
|
1617
|
-
function
|
|
1617
|
+
function so(e, t, n) {
|
|
1618
1618
|
var i = {};
|
|
1619
1619
|
return Array.from(e.children).forEach(function(o) {
|
|
1620
1620
|
var r, s, a, l;
|
|
1621
|
-
if (!(!
|
|
1622
|
-
var
|
|
1623
|
-
i.left = Math.min((r = i.left) !== null && r !== void 0 ? r : 1 / 0,
|
|
1621
|
+
if (!(!ut(o, t.draggable, e, !1) || o.animated || o === n)) {
|
|
1622
|
+
var u = k(o);
|
|
1623
|
+
i.left = Math.min((r = i.left) !== null && r !== void 0 ? r : 1 / 0, u.left), i.top = Math.min((s = i.top) !== null && s !== void 0 ? s : 1 / 0, u.top), i.right = Math.max((a = i.right) !== null && a !== void 0 ? a : -1 / 0, u.right), i.bottom = Math.max((l = i.bottom) !== null && l !== void 0 ? l : -1 / 0, u.bottom);
|
|
1624
1624
|
}
|
|
1625
1625
|
}), i.width = i.right - i.left, i.height = i.bottom - i.top, i.x = i.left, i.y = i.top, i;
|
|
1626
1626
|
}
|
|
1627
|
-
var
|
|
1628
|
-
function
|
|
1627
|
+
var nt = "Sortable" + (/* @__PURE__ */ new Date()).getTime();
|
|
1628
|
+
function hs() {
|
|
1629
1629
|
var e = [], t;
|
|
1630
1630
|
return {
|
|
1631
1631
|
captureAnimationState: function() {
|
|
1632
1632
|
if (e = [], !!this.options.animation) {
|
|
1633
1633
|
var i = [].slice.call(this.el.children);
|
|
1634
1634
|
i.forEach(function(o) {
|
|
1635
|
-
if (!(
|
|
1635
|
+
if (!(v(o, "display") === "none" || o === w.ghost)) {
|
|
1636
1636
|
e.push({
|
|
1637
1637
|
target: o,
|
|
1638
|
-
rect:
|
|
1638
|
+
rect: k(o)
|
|
1639
1639
|
});
|
|
1640
1640
|
var r = ct({}, e[e.length - 1].rect);
|
|
1641
1641
|
if (o.thisAnimationDuration) {
|
|
1642
|
-
var s =
|
|
1642
|
+
var s = zt(o, !0);
|
|
1643
1643
|
s && (r.top -= s.f, r.left -= s.e);
|
|
1644
1644
|
}
|
|
1645
1645
|
o.fromRect = r;
|
|
@@ -1651,7 +1651,7 @@ function ss() {
|
|
|
1651
1651
|
e.push(i);
|
|
1652
1652
|
},
|
|
1653
1653
|
removeAnimationState: function(i) {
|
|
1654
|
-
e.splice(
|
|
1654
|
+
e.splice(us(e, {
|
|
1655
1655
|
target: i
|
|
1656
1656
|
}), 1);
|
|
1657
1657
|
},
|
|
@@ -1663,38 +1663,38 @@ function ss() {
|
|
|
1663
1663
|
}
|
|
1664
1664
|
var r = !1, s = 0;
|
|
1665
1665
|
e.forEach(function(a) {
|
|
1666
|
-
var l = 0,
|
|
1667
|
-
y && (
|
|
1668
|
-
(g.top -
|
|
1669
|
-
|
|
1670
|
-
}, l),
|
|
1666
|
+
var l = 0, u = a.target, c = u.fromRect, d = k(u), p = u.prevFromRect, f = u.prevToRect, g = a.rect, y = zt(u, !0);
|
|
1667
|
+
y && (d.top -= y.f, d.left -= y.e), u.toRect = d, u.thisAnimationDuration && xn(p, d) && !xn(c, d) && // Make sure animatingRect is on line between toRect & fromRect
|
|
1668
|
+
(g.top - d.top) / (g.left - d.left) === (c.top - d.top) / (c.left - d.left) && (l = fs(g, p, f, o.options)), xn(d, c) || (u.prevFromRect = c, u.prevToRect = d, l || (l = o.options.animation), o.animate(u, g, d, l)), l && (r = !0, s = Math.max(s, l), clearTimeout(u.animationResetTimer), u.animationResetTimer = setTimeout(function() {
|
|
1669
|
+
u.animationTime = 0, u.prevFromRect = null, u.fromRect = null, u.prevToRect = null, u.thisAnimationDuration = null;
|
|
1670
|
+
}, l), u.thisAnimationDuration = l);
|
|
1671
1671
|
}), clearTimeout(t), r ? t = setTimeout(function() {
|
|
1672
1672
|
typeof i == "function" && i();
|
|
1673
1673
|
}, s) : typeof i == "function" && i(), e = [];
|
|
1674
1674
|
},
|
|
1675
1675
|
animate: function(i, o, r, s) {
|
|
1676
1676
|
if (s) {
|
|
1677
|
-
|
|
1678
|
-
var a =
|
|
1679
|
-
i.animatingX = !!c, i.animatingY = !!
|
|
1680
|
-
|
|
1677
|
+
v(i, "transition", ""), v(i, "transform", "");
|
|
1678
|
+
var a = zt(this.el), l = a && a.a, u = a && a.d, c = (o.left - r.left) / (l || 1), d = (o.top - r.top) / (u || 1);
|
|
1679
|
+
i.animatingX = !!c, i.animatingY = !!d, v(i, "transform", "translate3d(" + c + "px," + d + "px,0)"), this.forRepaintDummy = ps(i), v(i, "transition", "transform " + s + "ms" + (this.options.easing ? " " + this.options.easing : "")), v(i, "transform", "translate3d(0,0,0)"), typeof i.animated == "number" && clearTimeout(i.animated), i.animated = setTimeout(function() {
|
|
1680
|
+
v(i, "transition", ""), v(i, "transform", ""), i.animated = !1, i.animatingX = !1, i.animatingY = !1;
|
|
1681
1681
|
}, s);
|
|
1682
1682
|
}
|
|
1683
1683
|
}
|
|
1684
1684
|
};
|
|
1685
1685
|
}
|
|
1686
|
-
function
|
|
1686
|
+
function ps(e) {
|
|
1687
1687
|
return e.offsetWidth;
|
|
1688
1688
|
}
|
|
1689
|
-
function
|
|
1689
|
+
function fs(e, t, n, i) {
|
|
1690
1690
|
return Math.sqrt(Math.pow(t.top - e.top, 2) + Math.pow(t.left - e.left, 2)) / Math.sqrt(Math.pow(t.top - n.top, 2) + Math.pow(t.left - n.left, 2)) * i.animation;
|
|
1691
1691
|
}
|
|
1692
|
-
var Vt = [],
|
|
1692
|
+
var Vt = [], Sn = {
|
|
1693
1693
|
initializeByDefault: !0
|
|
1694
|
-
},
|
|
1694
|
+
}, xe = {
|
|
1695
1695
|
mount: function(t) {
|
|
1696
|
-
for (var n in
|
|
1697
|
-
|
|
1696
|
+
for (var n in Sn)
|
|
1697
|
+
Sn.hasOwnProperty(n) && !(n in t) && (t[n] = Sn[n]);
|
|
1698
1698
|
Vt.forEach(function(i) {
|
|
1699
1699
|
if (i.pluginName === t.pluginName)
|
|
1700
1700
|
throw "Sortable: Cannot mount plugin ".concat(t.pluginName, " more than once");
|
|
@@ -1718,8 +1718,8 @@ var Vt = [], xn = {
|
|
|
1718
1718
|
Vt.forEach(function(a) {
|
|
1719
1719
|
var l = a.pluginName;
|
|
1720
1720
|
if (!(!t.options[l] && !a.initializeByDefault)) {
|
|
1721
|
-
var
|
|
1722
|
-
|
|
1721
|
+
var u = new a(t, n, t.options);
|
|
1722
|
+
u.sortable = t, u.options = t.options, t[l] = u, yt(i, u.defaults);
|
|
1723
1723
|
}
|
|
1724
1724
|
});
|
|
1725
1725
|
for (var r in t.options)
|
|
@@ -1741,41 +1741,41 @@ var Vt = [], xn = {
|
|
|
1741
1741
|
}), o;
|
|
1742
1742
|
}
|
|
1743
1743
|
};
|
|
1744
|
-
function
|
|
1745
|
-
var t = e.sortable, n = e.rootEl, i = e.name, o = e.targetEl, r = e.cloneEl, s = e.toEl, a = e.fromEl, l = e.oldIndex,
|
|
1746
|
-
if (t = t || n && n[
|
|
1747
|
-
var y,
|
|
1748
|
-
window.CustomEvent && !bt && !
|
|
1744
|
+
function gs(e) {
|
|
1745
|
+
var t = e.sortable, n = e.rootEl, i = e.name, o = e.targetEl, r = e.cloneEl, s = e.toEl, a = e.fromEl, l = e.oldIndex, u = e.newIndex, c = e.oldDraggableIndex, d = e.newDraggableIndex, p = e.originalEvent, f = e.putSortable, g = e.extraEventProperties;
|
|
1746
|
+
if (t = t || n && n[nt], !!t) {
|
|
1747
|
+
var y, O = t.options, I = "on" + i.charAt(0).toUpperCase() + i.substr(1);
|
|
1748
|
+
window.CustomEvent && !bt && !Ee ? y = new CustomEvent(i, {
|
|
1749
1749
|
bubbles: !0,
|
|
1750
1750
|
cancelable: !0
|
|
1751
|
-
}) : (y = document.createEvent("Event"), y.initEvent(i, !0, !0)), y.to = s || n, y.from = a || n, y.item = o || n, y.clone = r, y.oldIndex = l, y.newIndex =
|
|
1752
|
-
var
|
|
1753
|
-
for (var
|
|
1754
|
-
y[
|
|
1755
|
-
n && n.dispatchEvent(y),
|
|
1751
|
+
}) : (y = document.createEvent("Event"), y.initEvent(i, !0, !0)), y.to = s || n, y.from = a || n, y.item = o || n, y.clone = r, y.oldIndex = l, y.newIndex = u, y.oldDraggableIndex = c, y.newDraggableIndex = d, y.originalEvent = p, y.pullMode = f ? f.lastPutMode : void 0;
|
|
1752
|
+
var H = ct(ct({}, g), xe.getEventProperties(i, t));
|
|
1753
|
+
for (var J in H)
|
|
1754
|
+
y[J] = H[J];
|
|
1755
|
+
n && n.dispatchEvent(y), O[I] && O[I].call(t, y);
|
|
1756
1756
|
}
|
|
1757
1757
|
}
|
|
1758
|
-
var
|
|
1759
|
-
var i = arguments.length > 2 && arguments[2] !== void 0 ? arguments[2] : {}, o = i.evt, r =
|
|
1760
|
-
|
|
1758
|
+
var ms = ["evt"], tt = function(t, n) {
|
|
1759
|
+
var i = arguments.length > 2 && arguments[2] !== void 0 ? arguments[2] : {}, o = i.evt, r = as(i, ms);
|
|
1760
|
+
xe.pluginEvent.bind(w)(t, n, ct({
|
|
1761
1761
|
dragEl: h,
|
|
1762
|
-
parentEl:
|
|
1763
|
-
ghostEl:
|
|
1764
|
-
rootEl:
|
|
1765
|
-
nextEl:
|
|
1766
|
-
lastDownEl:
|
|
1767
|
-
cloneEl:
|
|
1762
|
+
parentEl: N,
|
|
1763
|
+
ghostEl: E,
|
|
1764
|
+
rootEl: R,
|
|
1765
|
+
nextEl: It,
|
|
1766
|
+
lastDownEl: Oe,
|
|
1767
|
+
cloneEl: M,
|
|
1768
1768
|
cloneHidden: St,
|
|
1769
|
-
dragStarted:
|
|
1770
|
-
putSortable:
|
|
1771
|
-
activeSortable:
|
|
1769
|
+
dragStarted: ne,
|
|
1770
|
+
putSortable: z,
|
|
1771
|
+
activeSortable: w.active,
|
|
1772
1772
|
originalEvent: o,
|
|
1773
|
-
oldIndex:
|
|
1774
|
-
oldDraggableIndex:
|
|
1775
|
-
newIndex:
|
|
1773
|
+
oldIndex: Zt,
|
|
1774
|
+
oldDraggableIndex: ue,
|
|
1775
|
+
newIndex: rt,
|
|
1776
1776
|
newDraggableIndex: xt,
|
|
1777
|
-
hideGhostForTarget:
|
|
1778
|
-
unhideGhostForTarget:
|
|
1777
|
+
hideGhostForTarget: co,
|
|
1778
|
+
unhideGhostForTarget: ho,
|
|
1779
1779
|
cloneNowHidden: function() {
|
|
1780
1780
|
St = !0;
|
|
1781
1781
|
},
|
|
@@ -1783,7 +1783,7 @@ var us = ["evt"], J = function(t, n) {
|
|
|
1783
1783
|
St = !1;
|
|
1784
1784
|
},
|
|
1785
1785
|
dispatchSortableEvent: function(a) {
|
|
1786
|
-
|
|
1786
|
+
Q({
|
|
1787
1787
|
sortable: n,
|
|
1788
1788
|
name: a,
|
|
1789
1789
|
originalEvent: o
|
|
@@ -1791,96 +1791,96 @@ var us = ["evt"], J = function(t, n) {
|
|
|
1791
1791
|
}
|
|
1792
1792
|
}, r));
|
|
1793
1793
|
};
|
|
1794
|
-
function
|
|
1795
|
-
|
|
1796
|
-
putSortable:
|
|
1797
|
-
cloneEl:
|
|
1794
|
+
function Q(e) {
|
|
1795
|
+
gs(ct({
|
|
1796
|
+
putSortable: z,
|
|
1797
|
+
cloneEl: M,
|
|
1798
1798
|
targetEl: h,
|
|
1799
|
-
rootEl:
|
|
1800
|
-
oldIndex:
|
|
1801
|
-
oldDraggableIndex:
|
|
1802
|
-
newIndex:
|
|
1799
|
+
rootEl: R,
|
|
1800
|
+
oldIndex: Zt,
|
|
1801
|
+
oldDraggableIndex: ue,
|
|
1802
|
+
newIndex: rt,
|
|
1803
1803
|
newDraggableIndex: xt
|
|
1804
1804
|
}, e));
|
|
1805
1805
|
}
|
|
1806
|
-
var h,
|
|
1807
|
-
if (
|
|
1806
|
+
var h, N, E, R, It, Oe, M, St, Zt, rt, ue, xt, $e, z, Ft = !1, ke = !1, Ue = [], Rt, lt, $n, An, vi, wi, ne, kt, de, ce = !1, Ae = !1, De, W, _n = [], In = !1, Fe = [], pn = typeof document < "u", _e = Ki, Ei = Ee || bt ? "cssFloat" : "float", ys = pn && !Qi && !Ki && "draggable" in document.createElement("div"), ao = function() {
|
|
1807
|
+
if (pn) {
|
|
1808
1808
|
if (bt)
|
|
1809
1809
|
return !1;
|
|
1810
1810
|
var e = document.createElement("x");
|
|
1811
1811
|
return e.style.cssText = "pointer-events:auto", e.style.pointerEvents === "auto";
|
|
1812
1812
|
}
|
|
1813
|
-
}(),
|
|
1814
|
-
var i =
|
|
1813
|
+
}(), lo = function(t, n) {
|
|
1814
|
+
var i = v(t), o = parseInt(i.width) - parseInt(i.paddingLeft) - parseInt(i.paddingRight) - parseInt(i.borderLeftWidth) - parseInt(i.borderRightWidth), r = qt(t, 0, n), s = qt(t, 1, n), a = r && v(r), l = s && v(s), u = a && parseInt(a.marginLeft) + parseInt(a.marginRight) + k(r).width, c = l && parseInt(l.marginLeft) + parseInt(l.marginRight) + k(s).width;
|
|
1815
1815
|
if (i.display === "flex")
|
|
1816
1816
|
return i.flexDirection === "column" || i.flexDirection === "column-reverse" ? "vertical" : "horizontal";
|
|
1817
1817
|
if (i.display === "grid")
|
|
1818
1818
|
return i.gridTemplateColumns.split(" ").length <= 1 ? "vertical" : "horizontal";
|
|
1819
1819
|
if (r && a.float && a.float !== "none") {
|
|
1820
|
-
var
|
|
1821
|
-
return s && (l.clear === "both" || l.clear ===
|
|
1822
|
-
}
|
|
1823
|
-
return r && (a.display === "block" || a.display === "flex" || a.display === "table" || a.display === "grid" ||
|
|
1824
|
-
},
|
|
1825
|
-
var o = i ? t.left : t.top, r = i ? t.right : t.bottom, s = i ? t.width : t.height, a = i ? n.left : n.top, l = i ? n.right : n.bottom,
|
|
1826
|
-
return o === a || r === l || o + s / 2 === a +
|
|
1827
|
-
},
|
|
1820
|
+
var d = a.float === "left" ? "left" : "right";
|
|
1821
|
+
return s && (l.clear === "both" || l.clear === d) ? "vertical" : "horizontal";
|
|
1822
|
+
}
|
|
1823
|
+
return r && (a.display === "block" || a.display === "flex" || a.display === "table" || a.display === "grid" || u >= o && i[Ei] === "none" || s && i[Ei] === "none" && u + c > o) ? "vertical" : "horizontal";
|
|
1824
|
+
}, bs = function(t, n, i) {
|
|
1825
|
+
var o = i ? t.left : t.top, r = i ? t.right : t.bottom, s = i ? t.width : t.height, a = i ? n.left : n.top, l = i ? n.right : n.bottom, u = i ? n.width : n.height;
|
|
1826
|
+
return o === a || r === l || o + s / 2 === a + u / 2;
|
|
1827
|
+
}, vs = function(t, n) {
|
|
1828
1828
|
var i;
|
|
1829
1829
|
return Ue.some(function(o) {
|
|
1830
|
-
var r = o[
|
|
1831
|
-
if (!(!r ||
|
|
1832
|
-
var s =
|
|
1830
|
+
var r = o[nt].options.emptyInsertThreshold;
|
|
1831
|
+
if (!(!r || Gn(o))) {
|
|
1832
|
+
var s = k(o), a = t >= s.left - r && t <= s.right + r, l = n >= s.top - r && n <= s.bottom + r;
|
|
1833
1833
|
if (a && l)
|
|
1834
1834
|
return i = o;
|
|
1835
1835
|
}
|
|
1836
1836
|
}), i;
|
|
1837
|
-
},
|
|
1837
|
+
}, uo = function(t) {
|
|
1838
1838
|
function n(r, s) {
|
|
1839
|
-
return function(a, l,
|
|
1840
|
-
var
|
|
1841
|
-
if (r == null && (s ||
|
|
1839
|
+
return function(a, l, u, c) {
|
|
1840
|
+
var d = a.options.group.name && l.options.group.name && a.options.group.name === l.options.group.name;
|
|
1841
|
+
if (r == null && (s || d))
|
|
1842
1842
|
return !0;
|
|
1843
1843
|
if (r == null || r === !1)
|
|
1844
1844
|
return !1;
|
|
1845
1845
|
if (s && r === "clone")
|
|
1846
1846
|
return r;
|
|
1847
1847
|
if (typeof r == "function")
|
|
1848
|
-
return n(r(a, l,
|
|
1848
|
+
return n(r(a, l, u, c), s)(a, l, u, c);
|
|
1849
1849
|
var p = (s ? a : l).options.group.name;
|
|
1850
1850
|
return r === !0 || typeof r == "string" && r === p || r.join && r.indexOf(p) > -1;
|
|
1851
1851
|
};
|
|
1852
1852
|
}
|
|
1853
1853
|
var i = {}, o = t.group;
|
|
1854
|
-
(!o ||
|
|
1854
|
+
(!o || Pe(o) != "object") && (o = {
|
|
1855
1855
|
name: o
|
|
1856
1856
|
}), i.name = o.name, i.checkPull = n(o.pull, !0), i.checkPut = n(o.put), i.revertClone = o.revertClone, t.group = i;
|
|
1857
|
-
},
|
|
1858
|
-
!
|
|
1859
|
-
},
|
|
1860
|
-
!
|
|
1857
|
+
}, co = function() {
|
|
1858
|
+
!ao && E && v(E, "display", "none");
|
|
1859
|
+
}, ho = function() {
|
|
1860
|
+
!ao && E && v(E, "display", "");
|
|
1861
1861
|
};
|
|
1862
|
-
|
|
1863
|
-
if (
|
|
1864
|
-
return e.preventDefault(), e.stopPropagation && e.stopPropagation(), e.stopImmediatePropagation && e.stopImmediatePropagation(),
|
|
1862
|
+
pn && !Qi && document.addEventListener("click", function(e) {
|
|
1863
|
+
if (ke)
|
|
1864
|
+
return e.preventDefault(), e.stopPropagation && e.stopPropagation(), e.stopImmediatePropagation && e.stopImmediatePropagation(), ke = !1, !1;
|
|
1865
1865
|
}, !0);
|
|
1866
|
-
var
|
|
1866
|
+
var Mt = function(t) {
|
|
1867
1867
|
if (h) {
|
|
1868
1868
|
t = t.touches ? t.touches[0] : t;
|
|
1869
|
-
var n =
|
|
1869
|
+
var n = vs(t.clientX, t.clientY);
|
|
1870
1870
|
if (n) {
|
|
1871
1871
|
var i = {};
|
|
1872
1872
|
for (var o in t)
|
|
1873
1873
|
t.hasOwnProperty(o) && (i[o] = t[o]);
|
|
1874
|
-
i.target = i.rootEl = n, i.preventDefault = void 0, i.stopPropagation = void 0, n[
|
|
1874
|
+
i.target = i.rootEl = n, i.preventDefault = void 0, i.stopPropagation = void 0, n[nt]._onDragOver(i);
|
|
1875
1875
|
}
|
|
1876
1876
|
}
|
|
1877
|
-
},
|
|
1878
|
-
h && h.parentNode[
|
|
1877
|
+
}, ws = function(t) {
|
|
1878
|
+
h && h.parentNode[nt]._isOutsideThisEl(t.target);
|
|
1879
1879
|
};
|
|
1880
|
-
function
|
|
1880
|
+
function w(e, t) {
|
|
1881
1881
|
if (!(e && e.nodeType && e.nodeType === 1))
|
|
1882
1882
|
throw "Sortable: `el` must be an HTMLElement, not ".concat({}.toString.call(e));
|
|
1883
|
-
this.el = e, this.options = t = yt({}, t), e[
|
|
1883
|
+
this.el = e, this.options = t = yt({}, t), e[nt] = this;
|
|
1884
1884
|
var n = {
|
|
1885
1885
|
group: null,
|
|
1886
1886
|
sort: !0,
|
|
@@ -1896,7 +1896,7 @@ function v(e, t) {
|
|
|
1896
1896
|
// will be set to same as swapThreshold if default
|
|
1897
1897
|
removeCloneOnHide: !0,
|
|
1898
1898
|
direction: function() {
|
|
1899
|
-
return
|
|
1899
|
+
return lo(e, this.options);
|
|
1900
1900
|
},
|
|
1901
1901
|
ghostClass: "sortable-ghost",
|
|
1902
1902
|
chosenClass: "sortable-chosen",
|
|
@@ -1923,90 +1923,90 @@ function v(e, t) {
|
|
|
1923
1923
|
x: 0,
|
|
1924
1924
|
y: 0
|
|
1925
1925
|
},
|
|
1926
|
-
supportPointer:
|
|
1926
|
+
supportPointer: w.supportPointer !== !1 && "PointerEvent" in window && !ae,
|
|
1927
1927
|
emptyInsertThreshold: 5
|
|
1928
1928
|
};
|
|
1929
|
-
|
|
1929
|
+
xe.initializePlugins(this, e, n);
|
|
1930
1930
|
for (var i in n)
|
|
1931
1931
|
!(i in t) && (t[i] = n[i]);
|
|
1932
|
-
|
|
1932
|
+
uo(t);
|
|
1933
1933
|
for (var o in this)
|
|
1934
1934
|
o.charAt(0) === "_" && typeof this[o] == "function" && (this[o] = this[o].bind(this));
|
|
1935
|
-
this.nativeDraggable = t.forceFallback ? !1 :
|
|
1935
|
+
this.nativeDraggable = t.forceFallback ? !1 : ys, this.nativeDraggable && (this.options.touchStartThreshold = 1), t.supportPointer ? _(e, "pointerdown", this._onTapStart) : (_(e, "mousedown", this._onTapStart), _(e, "touchstart", this._onTapStart)), this.nativeDraggable && (_(e, "dragover", this), _(e, "dragenter", this)), Ue.push(this.el), t.store && t.store.get && this.sort(t.store.get(this) || []), yt(this, hs());
|
|
1936
1936
|
}
|
|
1937
|
-
|
|
1937
|
+
w.prototype = /** @lends Sortable.prototype */
|
|
1938
1938
|
{
|
|
1939
|
-
constructor:
|
|
1939
|
+
constructor: w,
|
|
1940
1940
|
_isOutsideThisEl: function(t) {
|
|
1941
|
-
!this.el.contains(t) && t !== this.el && (
|
|
1941
|
+
!this.el.contains(t) && t !== this.el && (kt = null);
|
|
1942
1942
|
},
|
|
1943
1943
|
_getDirection: function(t, n) {
|
|
1944
1944
|
return typeof this.options.direction == "function" ? this.options.direction.call(this, t, n, h) : this.options.direction;
|
|
1945
1945
|
},
|
|
1946
1946
|
_onTapStart: function(t) {
|
|
1947
1947
|
if (t.cancelable) {
|
|
1948
|
-
var n = this, i = this.el, o = this.options, r = o.preventOnFilter, s = t.type, a = t.touches && t.touches[0] || t.pointerType && t.pointerType === "touch" && t, l = (a || t).target,
|
|
1949
|
-
if (
|
|
1950
|
-
if (
|
|
1948
|
+
var n = this, i = this.el, o = this.options, r = o.preventOnFilter, s = t.type, a = t.touches && t.touches[0] || t.pointerType && t.pointerType === "touch" && t, l = (a || t).target, u = t.target.shadowRoot && (t.path && t.path[0] || t.composedPath && t.composedPath()[0]) || l, c = o.filter;
|
|
1949
|
+
if (Ts(i), !h && !(/mousedown|pointerdown/.test(s) && t.button !== 0 || o.disabled) && !u.isContentEditable && !(!this.nativeDraggable && ae && l && l.tagName.toUpperCase() === "SELECT") && (l = ut(l, o.draggable, i, !1), !(l && l.animated) && Oe !== l)) {
|
|
1950
|
+
if (Zt = st(l), ue = st(l, o.draggable), typeof c == "function") {
|
|
1951
1951
|
if (c.call(this, t, l, this)) {
|
|
1952
|
-
|
|
1952
|
+
Q({
|
|
1953
1953
|
sortable: n,
|
|
1954
|
-
rootEl:
|
|
1954
|
+
rootEl: u,
|
|
1955
1955
|
name: "filter",
|
|
1956
1956
|
targetEl: l,
|
|
1957
1957
|
toEl: i,
|
|
1958
1958
|
fromEl: i
|
|
1959
|
-
}),
|
|
1959
|
+
}), tt("filter", n, {
|
|
1960
1960
|
evt: t
|
|
1961
1961
|
}), r && t.cancelable && t.preventDefault();
|
|
1962
1962
|
return;
|
|
1963
1963
|
}
|
|
1964
|
-
} else if (c && (c = c.split(",").some(function(
|
|
1965
|
-
if (
|
|
1966
|
-
return
|
|
1964
|
+
} else if (c && (c = c.split(",").some(function(d) {
|
|
1965
|
+
if (d = ut(u, d.trim(), i, !1), d)
|
|
1966
|
+
return Q({
|
|
1967
1967
|
sortable: n,
|
|
1968
|
-
rootEl:
|
|
1968
|
+
rootEl: d,
|
|
1969
1969
|
name: "filter",
|
|
1970
1970
|
targetEl: l,
|
|
1971
1971
|
fromEl: i,
|
|
1972
1972
|
toEl: i
|
|
1973
|
-
}),
|
|
1973
|
+
}), tt("filter", n, {
|
|
1974
1974
|
evt: t
|
|
1975
1975
|
}), !0;
|
|
1976
1976
|
}), c)) {
|
|
1977
1977
|
r && t.cancelable && t.preventDefault();
|
|
1978
1978
|
return;
|
|
1979
1979
|
}
|
|
1980
|
-
o.handle && !
|
|
1980
|
+
o.handle && !ut(u, o.handle, i, !1) || this._prepareDragStart(t, a, l);
|
|
1981
1981
|
}
|
|
1982
1982
|
}
|
|
1983
1983
|
},
|
|
1984
1984
|
_prepareDragStart: function(t, n, i) {
|
|
1985
1985
|
var o = this, r = o.el, s = o.options, a = r.ownerDocument, l;
|
|
1986
1986
|
if (i && !h && i.parentNode === r) {
|
|
1987
|
-
var
|
|
1988
|
-
if (
|
|
1987
|
+
var u = k(i);
|
|
1988
|
+
if (R = r, h = i, N = h.parentNode, It = h.nextSibling, Oe = i, $e = s.group, w.dragged = h, Rt = {
|
|
1989
1989
|
target: h,
|
|
1990
1990
|
clientX: (n || t).clientX,
|
|
1991
1991
|
clientY: (n || t).clientY
|
|
1992
|
-
},
|
|
1993
|
-
if (
|
|
1992
|
+
}, vi = Rt.clientX - u.left, wi = Rt.clientY - u.top, this._lastX = (n || t).clientX, this._lastY = (n || t).clientY, h.style["will-change"] = "all", l = function() {
|
|
1993
|
+
if (tt("delayEnded", o, {
|
|
1994
1994
|
evt: t
|
|
1995
|
-
}),
|
|
1995
|
+
}), w.eventCanceled) {
|
|
1996
1996
|
o._onDrop();
|
|
1997
1997
|
return;
|
|
1998
1998
|
}
|
|
1999
|
-
o._disableDelayedDragEvents(), !
|
|
1999
|
+
o._disableDelayedDragEvents(), !gi && o.nativeDraggable && (h.draggable = !0), o._triggerDragStart(t, n), Q({
|
|
2000
2000
|
sortable: o,
|
|
2001
2001
|
name: "choose",
|
|
2002
2002
|
originalEvent: t
|
|
2003
|
-
}),
|
|
2003
|
+
}), ot(h, s.chosenClass, !0);
|
|
2004
2004
|
}, s.ignore.split(",").forEach(function(c) {
|
|
2005
|
-
|
|
2006
|
-
}), _(a, "dragover",
|
|
2005
|
+
no(h, c.trim(), Cn);
|
|
2006
|
+
}), _(a, "dragover", Mt), _(a, "mousemove", Mt), _(a, "touchmove", Mt), _(a, "mouseup", o._onDrop), _(a, "touchend", o._onDrop), _(a, "touchcancel", o._onDrop), gi && this.nativeDraggable && (this.options.touchStartThreshold = 4, h.draggable = !0), tt("delayStart", this, {
|
|
2007
2007
|
evt: t
|
|
2008
|
-
}), s.delay && (!s.delayOnTouchOnly || n) && (!this.nativeDraggable || !(
|
|
2009
|
-
if (
|
|
2008
|
+
}), s.delay && (!s.delayOnTouchOnly || n) && (!this.nativeDraggable || !(Ee || bt))) {
|
|
2009
|
+
if (w.eventCanceled) {
|
|
2010
2010
|
this._onDrop();
|
|
2011
2011
|
return;
|
|
2012
2012
|
}
|
|
@@ -2020,28 +2020,28 @@ v.prototype = /** @lends Sortable.prototype */
|
|
|
2020
2020
|
Math.max(Math.abs(n.clientX - this._lastX), Math.abs(n.clientY - this._lastY)) >= Math.floor(this.options.touchStartThreshold / (this.nativeDraggable && window.devicePixelRatio || 1)) && this._disableDelayedDrag();
|
|
2021
2021
|
},
|
|
2022
2022
|
_disableDelayedDrag: function() {
|
|
2023
|
-
h &&
|
|
2023
|
+
h && Cn(h), clearTimeout(this._dragStartTimer), this._disableDelayedDragEvents();
|
|
2024
2024
|
},
|
|
2025
2025
|
_disableDelayedDragEvents: function() {
|
|
2026
2026
|
var t = this.el.ownerDocument;
|
|
2027
|
-
|
|
2027
|
+
$(t, "mouseup", this._disableDelayedDrag), $(t, "touchend", this._disableDelayedDrag), $(t, "touchcancel", this._disableDelayedDrag), $(t, "mousemove", this._delayedDragTouchMoveHandler), $(t, "touchmove", this._delayedDragTouchMoveHandler), $(t, "pointermove", this._delayedDragTouchMoveHandler);
|
|
2028
2028
|
},
|
|
2029
2029
|
_triggerDragStart: function(t, n) {
|
|
2030
|
-
n = n || t.pointerType == "touch" && t, !this.nativeDraggable || n ? this.options.supportPointer ? _(document, "pointermove", this._onTouchMove) : n ? _(document, "touchmove", this._onTouchMove) : _(document, "mousemove", this._onTouchMove) : (_(h, "dragend", this), _(
|
|
2030
|
+
n = n || t.pointerType == "touch" && t, !this.nativeDraggable || n ? this.options.supportPointer ? _(document, "pointermove", this._onTouchMove) : n ? _(document, "touchmove", this._onTouchMove) : _(document, "mousemove", this._onTouchMove) : (_(h, "dragend", this), _(R, "dragstart", this._onDragStart));
|
|
2031
2031
|
try {
|
|
2032
|
-
document.selection ?
|
|
2032
|
+
document.selection ? Re(function() {
|
|
2033
2033
|
document.selection.empty();
|
|
2034
2034
|
}) : window.getSelection().removeAllRanges();
|
|
2035
2035
|
} catch {
|
|
2036
2036
|
}
|
|
2037
2037
|
},
|
|
2038
2038
|
_dragStarted: function(t, n) {
|
|
2039
|
-
if (
|
|
2040
|
-
|
|
2039
|
+
if (Ft = !1, R && h) {
|
|
2040
|
+
tt("dragStarted", this, {
|
|
2041
2041
|
evt: n
|
|
2042
|
-
}), this.nativeDraggable && _(document, "dragover",
|
|
2042
|
+
}), this.nativeDraggable && _(document, "dragover", ws);
|
|
2043
2043
|
var i = this.options;
|
|
2044
|
-
!t &&
|
|
2044
|
+
!t && ot(h, i.dragClass, !1), ot(h, i.ghostClass, !0), w.active = this, t && this._appendGhost(), Q({
|
|
2045
2045
|
sortable: this,
|
|
2046
2046
|
name: "start",
|
|
2047
2047
|
originalEvent: n
|
|
@@ -2051,14 +2051,14 @@ v.prototype = /** @lends Sortable.prototype */
|
|
|
2051
2051
|
},
|
|
2052
2052
|
_emulateDragOver: function() {
|
|
2053
2053
|
if (lt) {
|
|
2054
|
-
this._lastX = lt.clientX, this._lastY = lt.clientY,
|
|
2054
|
+
this._lastX = lt.clientX, this._lastY = lt.clientY, co();
|
|
2055
2055
|
for (var t = document.elementFromPoint(lt.clientX, lt.clientY), n = t; t && t.shadowRoot && (t = t.shadowRoot.elementFromPoint(lt.clientX, lt.clientY), t !== n); )
|
|
2056
2056
|
n = t;
|
|
2057
|
-
if (h.parentNode[
|
|
2057
|
+
if (h.parentNode[nt]._isOutsideThisEl(t), n)
|
|
2058
2058
|
do {
|
|
2059
|
-
if (n[
|
|
2059
|
+
if (n[nt]) {
|
|
2060
2060
|
var i = void 0;
|
|
2061
|
-
if (i = n[
|
|
2061
|
+
if (i = n[nt]._onDragOver({
|
|
2062
2062
|
clientX: lt.clientX,
|
|
2063
2063
|
clientY: lt.clientY,
|
|
2064
2064
|
target: t,
|
|
@@ -2067,211 +2067,211 @@ v.prototype = /** @lends Sortable.prototype */
|
|
|
2067
2067
|
break;
|
|
2068
2068
|
}
|
|
2069
2069
|
t = n;
|
|
2070
|
-
} while (n =
|
|
2071
|
-
|
|
2070
|
+
} while (n = eo(n));
|
|
2071
|
+
ho();
|
|
2072
2072
|
}
|
|
2073
2073
|
},
|
|
2074
2074
|
_onTouchMove: function(t) {
|
|
2075
|
-
if (
|
|
2076
|
-
var n = this.options, i = n.fallbackTolerance, o = n.fallbackOffset, r = t.touches ? t.touches[0] : t, s =
|
|
2077
|
-
if (!
|
|
2075
|
+
if (Rt) {
|
|
2076
|
+
var n = this.options, i = n.fallbackTolerance, o = n.fallbackOffset, r = t.touches ? t.touches[0] : t, s = E && zt(E, !0), a = E && s && s.a, l = E && s && s.d, u = _e && W && bi(W), c = (r.clientX - Rt.clientX + o.x) / (a || 1) + (u ? u[0] - _n[0] : 0) / (a || 1), d = (r.clientY - Rt.clientY + o.y) / (l || 1) + (u ? u[1] - _n[1] : 0) / (l || 1);
|
|
2077
|
+
if (!w.active && !Ft) {
|
|
2078
2078
|
if (i && Math.max(Math.abs(r.clientX - this._lastX), Math.abs(r.clientY - this._lastY)) < i)
|
|
2079
2079
|
return;
|
|
2080
2080
|
this._onDragStart(t, !0);
|
|
2081
2081
|
}
|
|
2082
|
-
if (
|
|
2083
|
-
s ? (s.e += c - (
|
|
2082
|
+
if (E) {
|
|
2083
|
+
s ? (s.e += c - ($n || 0), s.f += d - (An || 0)) : s = {
|
|
2084
2084
|
a: 1,
|
|
2085
2085
|
b: 0,
|
|
2086
2086
|
c: 0,
|
|
2087
2087
|
d: 1,
|
|
2088
2088
|
e: c,
|
|
2089
|
-
f:
|
|
2089
|
+
f: d
|
|
2090
2090
|
};
|
|
2091
2091
|
var p = "matrix(".concat(s.a, ",").concat(s.b, ",").concat(s.c, ",").concat(s.d, ",").concat(s.e, ",").concat(s.f, ")");
|
|
2092
|
-
|
|
2092
|
+
v(E, "webkitTransform", p), v(E, "mozTransform", p), v(E, "msTransform", p), v(E, "transform", p), $n = c, An = d, lt = r;
|
|
2093
2093
|
}
|
|
2094
2094
|
t.cancelable && t.preventDefault();
|
|
2095
2095
|
}
|
|
2096
2096
|
},
|
|
2097
2097
|
_appendGhost: function() {
|
|
2098
|
-
if (!
|
|
2099
|
-
var t = this.options.fallbackOnBody ? document.body :
|
|
2100
|
-
if (
|
|
2101
|
-
for (
|
|
2102
|
-
|
|
2103
|
-
|
|
2098
|
+
if (!E) {
|
|
2099
|
+
var t = this.options.fallbackOnBody ? document.body : R, n = k(h, !0, _e, !0, t), i = this.options;
|
|
2100
|
+
if (_e) {
|
|
2101
|
+
for (W = t; v(W, "position") === "static" && v(W, "transform") === "none" && W !== document; )
|
|
2102
|
+
W = W.parentNode;
|
|
2103
|
+
W !== document.body && W !== document.documentElement ? (W === document && (W = dt()), n.top += W.scrollTop, n.left += W.scrollLeft) : W = dt(), _n = bi(W);
|
|
2104
2104
|
}
|
|
2105
|
-
|
|
2105
|
+
E = h.cloneNode(!0), ot(E, i.ghostClass, !1), ot(E, i.fallbackClass, !0), ot(E, i.dragClass, !0), v(E, "transition", ""), v(E, "transform", ""), v(E, "box-sizing", "border-box"), v(E, "margin", 0), v(E, "top", n.top), v(E, "left", n.left), v(E, "width", n.width), v(E, "height", n.height), v(E, "opacity", "0.8"), v(E, "position", _e ? "absolute" : "fixed"), v(E, "zIndex", "100000"), v(E, "pointerEvents", "none"), w.ghost = E, t.appendChild(E), v(E, "transform-origin", vi / parseInt(E.style.width) * 100 + "% " + wi / parseInt(E.style.height) * 100 + "%");
|
|
2106
2106
|
}
|
|
2107
2107
|
},
|
|
2108
2108
|
_onDragStart: function(t, n) {
|
|
2109
2109
|
var i = this, o = t.dataTransfer, r = i.options;
|
|
2110
|
-
if (
|
|
2110
|
+
if (tt("dragStart", this, {
|
|
2111
2111
|
evt: t
|
|
2112
|
-
}),
|
|
2112
|
+
}), w.eventCanceled) {
|
|
2113
2113
|
this._onDrop();
|
|
2114
2114
|
return;
|
|
2115
2115
|
}
|
|
2116
|
-
|
|
2117
|
-
|
|
2116
|
+
tt("setupClone", this), w.eventCanceled || (M = ro(h), M.removeAttribute("id"), M.draggable = !1, M.style["will-change"] = "", this._hideClone(), ot(M, this.options.chosenClass, !1), w.clone = M), i.cloneId = Re(function() {
|
|
2117
|
+
tt("clone", i), !w.eventCanceled && (i.options.removeCloneOnHide || R.insertBefore(M, h), i._hideClone(), Q({
|
|
2118
2118
|
sortable: i,
|
|
2119
2119
|
name: "clone"
|
|
2120
2120
|
}));
|
|
2121
|
-
}), !n &&
|
|
2121
|
+
}), !n && ot(h, r.dragClass, !0), n ? (ke = !0, i._loopId = setInterval(i._emulateDragOver, 50)) : ($(document, "mouseup", i._onDrop), $(document, "touchend", i._onDrop), $(document, "touchcancel", i._onDrop), o && (o.effectAllowed = "move", r.setData && r.setData.call(i, o, h)), _(document, "drop", i), v(h, "transform", "translateZ(0)")), Ft = !0, i._dragStartId = Re(i._dragStarted.bind(i, n, t)), _(document, "selectstart", i), ne = !0, ae && v(document.body, "user-select", "none");
|
|
2122
2122
|
},
|
|
2123
2123
|
// Returns true - if no further action is needed (either inserted or another condition)
|
|
2124
2124
|
_onDragOver: function(t) {
|
|
2125
|
-
var n = this.el, i = t.target, o, r, s, a = this.options, l = a.group,
|
|
2126
|
-
if (
|
|
2127
|
-
function
|
|
2128
|
-
|
|
2125
|
+
var n = this.el, i = t.target, o, r, s, a = this.options, l = a.group, u = w.active, c = $e === l, d = a.sort, p = z || u, f, g = this, y = !1;
|
|
2126
|
+
if (In) return;
|
|
2127
|
+
function O(Kt, Uo) {
|
|
2128
|
+
tt(Kt, g, ct({
|
|
2129
2129
|
evt: t,
|
|
2130
2130
|
isOwner: c,
|
|
2131
2131
|
axis: f ? "vertical" : "horizontal",
|
|
2132
2132
|
revert: s,
|
|
2133
2133
|
dragRect: o,
|
|
2134
2134
|
targetRect: r,
|
|
2135
|
-
canSort:
|
|
2135
|
+
canSort: d,
|
|
2136
2136
|
fromSortable: p,
|
|
2137
2137
|
target: i,
|
|
2138
|
-
completed:
|
|
2139
|
-
onMove: function(
|
|
2140
|
-
return
|
|
2138
|
+
completed: H,
|
|
2139
|
+
onMove: function(ti, Fo) {
|
|
2140
|
+
return Ce(R, n, h, o, ti, k(ti), t, Fo);
|
|
2141
2141
|
},
|
|
2142
|
-
changed:
|
|
2143
|
-
},
|
|
2142
|
+
changed: J
|
|
2143
|
+
}, Uo));
|
|
2144
2144
|
}
|
|
2145
|
-
function
|
|
2146
|
-
|
|
2145
|
+
function I() {
|
|
2146
|
+
O("dragOverAnimationCapture"), g.captureAnimationState(), g !== p && p.captureAnimationState();
|
|
2147
2147
|
}
|
|
2148
|
-
function
|
|
2149
|
-
return
|
|
2150
|
-
insertion:
|
|
2151
|
-
}),
|
|
2152
|
-
|
|
2153
|
-
}), g !== p && (p.animateAll(), p._ignoreWhileAnimating = null)), (i === h && !h.animated || i === n && !i.animated) && (
|
|
2148
|
+
function H(Kt) {
|
|
2149
|
+
return O("dragOverCompleted", {
|
|
2150
|
+
insertion: Kt
|
|
2151
|
+
}), Kt && (c ? u._hideClone() : u._showClone(g), g !== p && (ot(h, z ? z.options.ghostClass : u.options.ghostClass, !1), ot(h, a.ghostClass, !0)), z !== g && g !== w.active ? z = g : g === w.active && z && (z = null), p === g && (g._ignoreWhileAnimating = i), g.animateAll(function() {
|
|
2152
|
+
O("dragOverAnimationComplete"), g._ignoreWhileAnimating = null;
|
|
2153
|
+
}), g !== p && (p.animateAll(), p._ignoreWhileAnimating = null)), (i === h && !h.animated || i === n && !i.animated) && (kt = null), !a.dragoverBubble && !t.rootEl && i !== document && (h.parentNode[nt]._isOutsideThisEl(t.target), !Kt && Mt(t)), !a.dragoverBubble && t.stopPropagation && t.stopPropagation(), y = !0;
|
|
2154
2154
|
}
|
|
2155
|
-
function
|
|
2156
|
-
|
|
2155
|
+
function J() {
|
|
2156
|
+
rt = st(h), xt = st(h, a.draggable), Q({
|
|
2157
2157
|
sortable: g,
|
|
2158
2158
|
name: "change",
|
|
2159
2159
|
toEl: n,
|
|
2160
|
-
newIndex:
|
|
2160
|
+
newIndex: rt,
|
|
2161
2161
|
newDraggableIndex: xt,
|
|
2162
2162
|
originalEvent: t
|
|
2163
2163
|
});
|
|
2164
2164
|
}
|
|
2165
|
-
if (t.preventDefault !== void 0 && t.cancelable && t.preventDefault(), i =
|
|
2165
|
+
if (t.preventDefault !== void 0 && t.cancelable && t.preventDefault(), i = ut(i, a.draggable, n, !0), O("dragOver"), w.eventCanceled) return y;
|
|
2166
2166
|
if (h.contains(t.target) || i.animated && i.animatingX && i.animatingY || g._ignoreWhileAnimating === i)
|
|
2167
|
-
return
|
|
2168
|
-
if (
|
|
2169
|
-
if (f = this._getDirection(t, i) === "vertical", o =
|
|
2167
|
+
return H(!1);
|
|
2168
|
+
if (ke = !1, u && !a.disabled && (c ? d || (s = N !== R) : z === this || (this.lastPutMode = $e.checkPull(this, u, h, t)) && l.checkPut(this, u, h, t))) {
|
|
2169
|
+
if (f = this._getDirection(t, i) === "vertical", o = k(h), O("dragOverValid"), w.eventCanceled) return y;
|
|
2170
2170
|
if (s)
|
|
2171
|
-
return
|
|
2172
|
-
var
|
|
2173
|
-
if (!
|
|
2174
|
-
if (
|
|
2175
|
-
return
|
|
2176
|
-
if (
|
|
2177
|
-
return
|
|
2178
|
-
} else if (
|
|
2179
|
-
var
|
|
2180
|
-
if (
|
|
2181
|
-
return
|
|
2182
|
-
if (i =
|
|
2183
|
-
return
|
|
2171
|
+
return N = R, I(), this._hideClone(), O("revert"), w.eventCanceled || (It ? R.insertBefore(h, It) : R.appendChild(h)), H(!0);
|
|
2172
|
+
var j = Gn(n, a.draggable);
|
|
2173
|
+
if (!j || $s(t, f, this) && !j.animated) {
|
|
2174
|
+
if (j === h)
|
|
2175
|
+
return H(!1);
|
|
2176
|
+
if (j && n === t.target && (i = j), i && (r = k(i)), Ce(R, n, h, o, i, r, t, !!i) !== !1)
|
|
2177
|
+
return I(), j && j.nextSibling ? n.insertBefore(h, j.nextSibling) : n.appendChild(h), N = n, J(), H(!0);
|
|
2178
|
+
} else if (j && Ss(t, f, this)) {
|
|
2179
|
+
var K = qt(n, 0, a, !0);
|
|
2180
|
+
if (K === h)
|
|
2181
|
+
return H(!1);
|
|
2182
|
+
if (i = K, r = k(i), Ce(R, n, h, o, i, r, t, !1) !== !1)
|
|
2183
|
+
return I(), n.insertBefore(h, K), N = n, J(), H(!0);
|
|
2184
2184
|
} else if (i.parentNode === n) {
|
|
2185
|
-
r =
|
|
2186
|
-
var
|
|
2187
|
-
|
|
2185
|
+
r = k(i);
|
|
2186
|
+
var b = 0, D, Z = h.parentNode !== n, U = !bs(h.animated && h.toRect || o, i.animated && i.toRect || r, f), Wt = f ? "top" : "left", vt = yi(i, "top", "top") || yi(h, "top", "top"), Gt = vt ? vt.scrollTop : void 0;
|
|
2187
|
+
kt !== i && (D = r[Wt], ce = !1, Ae = !U && a.invertSwap || Z), b = As(t, i, r, f, U ? 1 : a.swapThreshold, a.invertedSwapThreshold == null ? a.swapThreshold : a.invertedSwapThreshold, Ae, kt === i);
|
|
2188
2188
|
var ht;
|
|
2189
|
-
if (
|
|
2190
|
-
var
|
|
2189
|
+
if (b !== 0) {
|
|
2190
|
+
var Pt = st(h);
|
|
2191
2191
|
do
|
|
2192
|
-
|
|
2193
|
-
while (ht && (
|
|
2192
|
+
Pt -= b, ht = N.children[Pt];
|
|
2193
|
+
while (ht && (v(ht, "display") === "none" || ht === E));
|
|
2194
2194
|
}
|
|
2195
|
-
if (
|
|
2196
|
-
return
|
|
2197
|
-
|
|
2198
|
-
var
|
|
2199
|
-
wt =
|
|
2200
|
-
var
|
|
2201
|
-
if (
|
|
2202
|
-
return (
|
|
2195
|
+
if (b === 0 || ht === i)
|
|
2196
|
+
return H(!1);
|
|
2197
|
+
kt = i, de = b;
|
|
2198
|
+
var Jt = i.nextElementSibling, wt = !1;
|
|
2199
|
+
wt = b === 1;
|
|
2200
|
+
var Se = Ce(R, n, h, o, i, r, t, wt);
|
|
2201
|
+
if (Se !== !1)
|
|
2202
|
+
return (Se === 1 || Se === -1) && (wt = Se === 1), In = !0, setTimeout(xs, 30), I(), wt && !Jt ? n.appendChild(h) : i.parentNode.insertBefore(h, wt ? Jt : i), vt && oo(vt, 0, Gt - vt.scrollTop), N = h.parentNode, D !== void 0 && !Ae && (De = Math.abs(D - k(i)[Wt])), J(), H(!0);
|
|
2203
2203
|
}
|
|
2204
2204
|
if (n.contains(h))
|
|
2205
|
-
return
|
|
2205
|
+
return H(!1);
|
|
2206
2206
|
}
|
|
2207
2207
|
return !1;
|
|
2208
2208
|
},
|
|
2209
2209
|
_ignoreWhileAnimating: null,
|
|
2210
2210
|
_offMoveEvents: function() {
|
|
2211
|
-
|
|
2211
|
+
$(document, "mousemove", this._onTouchMove), $(document, "touchmove", this._onTouchMove), $(document, "pointermove", this._onTouchMove), $(document, "dragover", Mt), $(document, "mousemove", Mt), $(document, "touchmove", Mt);
|
|
2212
2212
|
},
|
|
2213
2213
|
_offUpEvents: function() {
|
|
2214
2214
|
var t = this.el.ownerDocument;
|
|
2215
|
-
|
|
2215
|
+
$(t, "mouseup", this._onDrop), $(t, "touchend", this._onDrop), $(t, "pointerup", this._onDrop), $(t, "touchcancel", this._onDrop), $(document, "selectstart", this);
|
|
2216
2216
|
},
|
|
2217
2217
|
_onDrop: function(t) {
|
|
2218
2218
|
var n = this.el, i = this.options;
|
|
2219
|
-
if (
|
|
2219
|
+
if (rt = st(h), xt = st(h, i.draggable), tt("drop", this, {
|
|
2220
2220
|
evt: t
|
|
2221
|
-
}),
|
|
2221
|
+
}), N = h && h.parentNode, rt = st(h), xt = st(h, i.draggable), w.eventCanceled) {
|
|
2222
2222
|
this._nulling();
|
|
2223
2223
|
return;
|
|
2224
2224
|
}
|
|
2225
|
-
|
|
2225
|
+
Ft = !1, Ae = !1, ce = !1, clearInterval(this._loopId), clearTimeout(this._dragStartTimer), Nn(this.cloneId), Nn(this._dragStartId), this.nativeDraggable && ($(document, "drop", this), $(n, "dragstart", this._onDragStart)), this._offMoveEvents(), this._offUpEvents(), ae && v(document.body, "user-select", ""), v(h, "transform", ""), t && (ne && (t.cancelable && t.preventDefault(), !i.dropBubble && t.stopPropagation()), E && E.parentNode && E.parentNode.removeChild(E), (R === N || z && z.lastPutMode !== "clone") && M && M.parentNode && M.parentNode.removeChild(M), h && (this.nativeDraggable && $(h, "dragend", this), Cn(h), h.style["will-change"] = "", ne && !Ft && ot(h, z ? z.options.ghostClass : this.options.ghostClass, !1), ot(h, this.options.chosenClass, !1), Q({
|
|
2226
2226
|
sortable: this,
|
|
2227
2227
|
name: "unchoose",
|
|
2228
|
-
toEl:
|
|
2228
|
+
toEl: N,
|
|
2229
2229
|
newIndex: null,
|
|
2230
2230
|
newDraggableIndex: null,
|
|
2231
2231
|
originalEvent: t
|
|
2232
|
-
}),
|
|
2233
|
-
rootEl:
|
|
2232
|
+
}), R !== N ? (rt >= 0 && (Q({
|
|
2233
|
+
rootEl: N,
|
|
2234
2234
|
name: "add",
|
|
2235
|
-
toEl:
|
|
2236
|
-
fromEl:
|
|
2235
|
+
toEl: N,
|
|
2236
|
+
fromEl: R,
|
|
2237
2237
|
originalEvent: t
|
|
2238
|
-
}),
|
|
2238
|
+
}), Q({
|
|
2239
2239
|
sortable: this,
|
|
2240
2240
|
name: "remove",
|
|
2241
|
-
toEl:
|
|
2241
|
+
toEl: N,
|
|
2242
2242
|
originalEvent: t
|
|
2243
|
-
}),
|
|
2244
|
-
rootEl:
|
|
2243
|
+
}), Q({
|
|
2244
|
+
rootEl: N,
|
|
2245
2245
|
name: "sort",
|
|
2246
|
-
toEl:
|
|
2247
|
-
fromEl:
|
|
2246
|
+
toEl: N,
|
|
2247
|
+
fromEl: R,
|
|
2248
2248
|
originalEvent: t
|
|
2249
|
-
}),
|
|
2249
|
+
}), Q({
|
|
2250
2250
|
sortable: this,
|
|
2251
2251
|
name: "sort",
|
|
2252
|
-
toEl:
|
|
2252
|
+
toEl: N,
|
|
2253
2253
|
originalEvent: t
|
|
2254
|
-
})),
|
|
2254
|
+
})), z && z.save()) : rt !== Zt && rt >= 0 && (Q({
|
|
2255
2255
|
sortable: this,
|
|
2256
2256
|
name: "update",
|
|
2257
|
-
toEl:
|
|
2257
|
+
toEl: N,
|
|
2258
2258
|
originalEvent: t
|
|
2259
|
-
}),
|
|
2259
|
+
}), Q({
|
|
2260
2260
|
sortable: this,
|
|
2261
2261
|
name: "sort",
|
|
2262
|
-
toEl:
|
|
2262
|
+
toEl: N,
|
|
2263
2263
|
originalEvent: t
|
|
2264
|
-
})),
|
|
2264
|
+
})), w.active && ((rt == null || rt === -1) && (rt = Zt, xt = ue), Q({
|
|
2265
2265
|
sortable: this,
|
|
2266
2266
|
name: "end",
|
|
2267
|
-
toEl:
|
|
2267
|
+
toEl: N,
|
|
2268
2268
|
originalEvent: t
|
|
2269
2269
|
}), this.save()))), this._nulling();
|
|
2270
2270
|
},
|
|
2271
2271
|
_nulling: function() {
|
|
2272
|
-
|
|
2272
|
+
tt("nulling", this), R = h = N = E = It = M = Oe = St = Rt = lt = ne = rt = xt = Zt = ue = kt = de = z = $e = w.dragged = w.ghost = w.clone = w.active = null, Fe.forEach(function(t) {
|
|
2273
2273
|
t.checked = !0;
|
|
2274
|
-
}),
|
|
2274
|
+
}), Fe.length = $n = An = 0;
|
|
2275
2275
|
},
|
|
2276
2276
|
handleEvent: function(t) {
|
|
2277
2277
|
switch (t.type) {
|
|
@@ -2281,7 +2281,7 @@ v.prototype = /** @lends Sortable.prototype */
|
|
|
2281
2281
|
break;
|
|
2282
2282
|
case "dragenter":
|
|
2283
2283
|
case "dragover":
|
|
2284
|
-
h && (this._onDragOver(t),
|
|
2284
|
+
h && (this._onDragOver(t), Es(t));
|
|
2285
2285
|
break;
|
|
2286
2286
|
case "selectstart":
|
|
2287
2287
|
t.preventDefault();
|
|
@@ -2294,7 +2294,7 @@ v.prototype = /** @lends Sortable.prototype */
|
|
|
2294
2294
|
*/
|
|
2295
2295
|
toArray: function() {
|
|
2296
2296
|
for (var t = [], n, i = this.el.children, o = 0, r = i.length, s = this.options; o < r; o++)
|
|
2297
|
-
n = i[o],
|
|
2297
|
+
n = i[o], ut(n, s.draggable, this.el, !1) && t.push(n.getAttribute(s.dataIdAttr) || Cs(n));
|
|
2298
2298
|
return t;
|
|
2299
2299
|
},
|
|
2300
2300
|
/**
|
|
@@ -2305,7 +2305,7 @@ v.prototype = /** @lends Sortable.prototype */
|
|
|
2305
2305
|
var i = {}, o = this.el;
|
|
2306
2306
|
this.toArray().forEach(function(r, s) {
|
|
2307
2307
|
var a = o.children[s];
|
|
2308
|
-
|
|
2308
|
+
ut(a, this.options.draggable, o, !1) && (i[r] = a);
|
|
2309
2309
|
}, this), n && this.captureAnimationState(), t.forEach(function(r) {
|
|
2310
2310
|
i[r] && (o.removeChild(i[r]), o.appendChild(i[r]));
|
|
2311
2311
|
}), n && this.animateAll();
|
|
@@ -2324,7 +2324,7 @@ v.prototype = /** @lends Sortable.prototype */
|
|
|
2324
2324
|
* @returns {HTMLElement|null}
|
|
2325
2325
|
*/
|
|
2326
2326
|
closest: function(t, n) {
|
|
2327
|
-
return
|
|
2327
|
+
return ut(t, n || this.options.draggable, this.el, !1);
|
|
2328
2328
|
},
|
|
2329
2329
|
/**
|
|
2330
2330
|
* Set/get option
|
|
@@ -2336,23 +2336,23 @@ v.prototype = /** @lends Sortable.prototype */
|
|
|
2336
2336
|
var i = this.options;
|
|
2337
2337
|
if (n === void 0)
|
|
2338
2338
|
return i[t];
|
|
2339
|
-
var o =
|
|
2340
|
-
typeof o < "u" ? i[t] = o : i[t] = n, t === "group" &&
|
|
2339
|
+
var o = xe.modifyOption(this, t, n);
|
|
2340
|
+
typeof o < "u" ? i[t] = o : i[t] = n, t === "group" && uo(i);
|
|
2341
2341
|
},
|
|
2342
2342
|
/**
|
|
2343
2343
|
* Destroy
|
|
2344
2344
|
*/
|
|
2345
2345
|
destroy: function() {
|
|
2346
|
-
|
|
2346
|
+
tt("destroy", this);
|
|
2347
2347
|
var t = this.el;
|
|
2348
|
-
t[
|
|
2348
|
+
t[nt] = null, $(t, "mousedown", this._onTapStart), $(t, "touchstart", this._onTapStart), $(t, "pointerdown", this._onTapStart), this.nativeDraggable && ($(t, "dragover", this), $(t, "dragenter", this)), Array.prototype.forEach.call(t.querySelectorAll("[draggable]"), function(n) {
|
|
2349
2349
|
n.removeAttribute("draggable");
|
|
2350
2350
|
}), this._onDrop(), this._disableDelayedDragEvents(), Ue.splice(Ue.indexOf(this.el), 1), this.el = t = null;
|
|
2351
2351
|
},
|
|
2352
2352
|
_hideClone: function() {
|
|
2353
2353
|
if (!St) {
|
|
2354
|
-
if (
|
|
2355
|
-
|
|
2354
|
+
if (tt("hideClone", this), w.eventCanceled) return;
|
|
2355
|
+
v(M, "display", "none"), this.options.removeCloneOnHide && M.parentNode && M.parentNode.removeChild(M), St = !0;
|
|
2356
2356
|
}
|
|
2357
2357
|
},
|
|
2358
2358
|
_showClone: function(t) {
|
|
@@ -2361,110 +2361,110 @@ v.prototype = /** @lends Sortable.prototype */
|
|
|
2361
2361
|
return;
|
|
2362
2362
|
}
|
|
2363
2363
|
if (St) {
|
|
2364
|
-
if (
|
|
2365
|
-
h.parentNode ==
|
|
2364
|
+
if (tt("showClone", this), w.eventCanceled) return;
|
|
2365
|
+
h.parentNode == R && !this.options.group.revertClone ? R.insertBefore(M, h) : It ? R.insertBefore(M, It) : R.appendChild(M), this.options.group.revertClone && this.animate(h, M), v(M, "display", ""), St = !1;
|
|
2366
2366
|
}
|
|
2367
2367
|
}
|
|
2368
2368
|
};
|
|
2369
|
-
function
|
|
2369
|
+
function Es(e) {
|
|
2370
2370
|
e.dataTransfer && (e.dataTransfer.dropEffect = "move"), e.cancelable && e.preventDefault();
|
|
2371
2371
|
}
|
|
2372
|
-
function
|
|
2373
|
-
var l,
|
|
2374
|
-
return window.CustomEvent && !bt && !
|
|
2372
|
+
function Ce(e, t, n, i, o, r, s, a) {
|
|
2373
|
+
var l, u = e[nt], c = u.options.onMove, d;
|
|
2374
|
+
return window.CustomEvent && !bt && !Ee ? l = new CustomEvent("move", {
|
|
2375
2375
|
bubbles: !0,
|
|
2376
2376
|
cancelable: !0
|
|
2377
|
-
}) : (l = document.createEvent("Event"), l.initEvent("move", !0, !0)), l.to = t, l.from = e, l.dragged = n, l.draggedRect = i, l.related = o || t, l.relatedRect = r ||
|
|
2377
|
+
}) : (l = document.createEvent("Event"), l.initEvent("move", !0, !0)), l.to = t, l.from = e, l.dragged = n, l.draggedRect = i, l.related = o || t, l.relatedRect = r || k(t), l.willInsertAfter = a, l.originalEvent = s, e.dispatchEvent(l), c && (d = c.call(u, l, s)), d;
|
|
2378
2378
|
}
|
|
2379
|
-
function
|
|
2379
|
+
function Cn(e) {
|
|
2380
2380
|
e.draggable = !1;
|
|
2381
2381
|
}
|
|
2382
|
-
function
|
|
2383
|
-
|
|
2382
|
+
function xs() {
|
|
2383
|
+
In = !1;
|
|
2384
2384
|
}
|
|
2385
|
-
function
|
|
2386
|
-
var i =
|
|
2385
|
+
function Ss(e, t, n) {
|
|
2386
|
+
var i = k(qt(n.el, 0, n.options, !0)), o = so(n.el, n.options, E), r = 10;
|
|
2387
2387
|
return t ? e.clientX < o.left - r || e.clientY < i.top && e.clientX < i.right : e.clientY < o.top - r || e.clientY < i.bottom && e.clientX < i.left;
|
|
2388
2388
|
}
|
|
2389
|
-
function
|
|
2390
|
-
var i =
|
|
2389
|
+
function $s(e, t, n) {
|
|
2390
|
+
var i = k(Gn(n.el, n.options.draggable)), o = so(n.el, n.options, E), r = 10;
|
|
2391
2391
|
return t ? e.clientX > o.right + r || e.clientY > i.bottom && e.clientX > i.left : e.clientY > o.bottom + r || e.clientX > i.right && e.clientY > i.top;
|
|
2392
2392
|
}
|
|
2393
|
-
function
|
|
2394
|
-
var l = i ? e.clientY : e.clientX,
|
|
2393
|
+
function As(e, t, n, i, o, r, s, a) {
|
|
2394
|
+
var l = i ? e.clientY : e.clientX, u = i ? n.height : n.width, c = i ? n.top : n.left, d = i ? n.bottom : n.right, p = !1;
|
|
2395
2395
|
if (!s) {
|
|
2396
|
-
if (a && De <
|
|
2397
|
-
if (!
|
|
2396
|
+
if (a && De < u * o) {
|
|
2397
|
+
if (!ce && (de === 1 ? l > c + u * r / 2 : l < d - u * r / 2) && (ce = !0), ce)
|
|
2398
2398
|
p = !0;
|
|
2399
|
-
else if (de === 1 ? l < c + De : l >
|
|
2399
|
+
else if (de === 1 ? l < c + De : l > d - De)
|
|
2400
2400
|
return -de;
|
|
2401
|
-
} else if (l > c +
|
|
2402
|
-
return
|
|
2401
|
+
} else if (l > c + u * (1 - o) / 2 && l < d - u * (1 - o) / 2)
|
|
2402
|
+
return _s(t);
|
|
2403
2403
|
}
|
|
2404
|
-
return p = p || s, p && (l < c +
|
|
2404
|
+
return p = p || s, p && (l < c + u * r / 2 || l > d - u * r / 2) ? l > c + u / 2 ? 1 : -1 : 0;
|
|
2405
2405
|
}
|
|
2406
|
-
function
|
|
2407
|
-
return
|
|
2406
|
+
function _s(e) {
|
|
2407
|
+
return st(h) < st(e) ? 1 : -1;
|
|
2408
2408
|
}
|
|
2409
|
-
function
|
|
2409
|
+
function Cs(e) {
|
|
2410
2410
|
for (var t = e.tagName + e.className + e.src + e.href + e.textContent, n = t.length, i = 0; n--; )
|
|
2411
2411
|
i += t.charCodeAt(n);
|
|
2412
2412
|
return i.toString(36);
|
|
2413
2413
|
}
|
|
2414
|
-
function
|
|
2415
|
-
|
|
2414
|
+
function Ts(e) {
|
|
2415
|
+
Fe.length = 0;
|
|
2416
2416
|
for (var t = e.getElementsByTagName("input"), n = t.length; n--; ) {
|
|
2417
2417
|
var i = t[n];
|
|
2418
|
-
i.checked &&
|
|
2418
|
+
i.checked && Fe.push(i);
|
|
2419
2419
|
}
|
|
2420
2420
|
}
|
|
2421
|
-
function
|
|
2421
|
+
function Re(e) {
|
|
2422
2422
|
return setTimeout(e, 0);
|
|
2423
2423
|
}
|
|
2424
|
-
function
|
|
2424
|
+
function Nn(e) {
|
|
2425
2425
|
return clearTimeout(e);
|
|
2426
2426
|
}
|
|
2427
|
-
|
|
2428
|
-
(
|
|
2427
|
+
pn && _(document, "touchmove", function(e) {
|
|
2428
|
+
(w.active || Ft) && e.cancelable && e.preventDefault();
|
|
2429
2429
|
});
|
|
2430
|
-
|
|
2430
|
+
w.utils = {
|
|
2431
2431
|
on: _,
|
|
2432
|
-
off:
|
|
2433
|
-
css:
|
|
2434
|
-
find:
|
|
2432
|
+
off: $,
|
|
2433
|
+
css: v,
|
|
2434
|
+
find: no,
|
|
2435
2435
|
is: function(t, n) {
|
|
2436
|
-
return !!
|
|
2436
|
+
return !!ut(t, n, t, !1);
|
|
2437
2437
|
},
|
|
2438
|
-
extend:
|
|
2439
|
-
throttle:
|
|
2440
|
-
closest:
|
|
2441
|
-
toggleClass:
|
|
2442
|
-
clone:
|
|
2443
|
-
index:
|
|
2444
|
-
nextTick:
|
|
2445
|
-
cancelNextTick:
|
|
2446
|
-
detectDirection:
|
|
2447
|
-
getChild:
|
|
2448
|
-
expando:
|
|
2438
|
+
extend: ds,
|
|
2439
|
+
throttle: io,
|
|
2440
|
+
closest: ut,
|
|
2441
|
+
toggleClass: ot,
|
|
2442
|
+
clone: ro,
|
|
2443
|
+
index: st,
|
|
2444
|
+
nextTick: Re,
|
|
2445
|
+
cancelNextTick: Nn,
|
|
2446
|
+
detectDirection: lo,
|
|
2447
|
+
getChild: qt,
|
|
2448
|
+
expando: nt
|
|
2449
2449
|
};
|
|
2450
|
-
|
|
2451
|
-
return e[
|
|
2450
|
+
w.get = function(e) {
|
|
2451
|
+
return e[nt];
|
|
2452
2452
|
};
|
|
2453
|
-
|
|
2453
|
+
w.mount = function() {
|
|
2454
2454
|
for (var e = arguments.length, t = new Array(e), n = 0; n < e; n++)
|
|
2455
2455
|
t[n] = arguments[n];
|
|
2456
2456
|
t[0].constructor === Array && (t = t[0]), t.forEach(function(i) {
|
|
2457
2457
|
if (!i.prototype || !i.prototype.constructor)
|
|
2458
2458
|
throw "Sortable: Mounted plugin must be a constructor function, not ".concat({}.toString.call(i));
|
|
2459
|
-
i.utils && (
|
|
2459
|
+
i.utils && (w.utils = ct(ct({}, w.utils), i.utils)), xe.mount(i);
|
|
2460
2460
|
});
|
|
2461
2461
|
};
|
|
2462
|
-
|
|
2463
|
-
return new
|
|
2462
|
+
w.create = function(e, t) {
|
|
2463
|
+
return new w(e, t);
|
|
2464
2464
|
};
|
|
2465
|
-
|
|
2466
|
-
var
|
|
2467
|
-
function
|
|
2465
|
+
w.version = ls;
|
|
2466
|
+
var V = [], ie, Hn, Ln = !1, Tn, Pn, je, oe;
|
|
2467
|
+
function Ps() {
|
|
2468
2468
|
function e() {
|
|
2469
2469
|
this.defaults = {
|
|
2470
2470
|
scroll: !0,
|
|
@@ -2486,29 +2486,29 @@ function Ss() {
|
|
|
2486
2486
|
!this.options.dragOverBubble && !i.rootEl && this._handleAutoScroll(i);
|
|
2487
2487
|
},
|
|
2488
2488
|
drop: function() {
|
|
2489
|
-
this.sortable.nativeDraggable ?
|
|
2489
|
+
this.sortable.nativeDraggable ? $(document, "dragover", this._handleAutoScroll) : ($(document, "pointermove", this._handleFallbackAutoScroll), $(document, "touchmove", this._handleFallbackAutoScroll), $(document, "mousemove", this._handleFallbackAutoScroll)), xi(), Me(), cs();
|
|
2490
2490
|
},
|
|
2491
2491
|
nulling: function() {
|
|
2492
|
-
|
|
2492
|
+
je = Hn = ie = Ln = oe = Tn = Pn = null, V.length = 0;
|
|
2493
2493
|
},
|
|
2494
2494
|
_handleFallbackAutoScroll: function(n) {
|
|
2495
2495
|
this._handleAutoScroll(n, !0);
|
|
2496
2496
|
},
|
|
2497
2497
|
_handleAutoScroll: function(n, i) {
|
|
2498
2498
|
var o = this, r = (n.touches ? n.touches[0] : n).clientX, s = (n.touches ? n.touches[0] : n).clientY, a = document.elementFromPoint(r, s);
|
|
2499
|
-
if (
|
|
2500
|
-
|
|
2501
|
-
var l =
|
|
2502
|
-
|
|
2503
|
-
var
|
|
2504
|
-
|
|
2505
|
-
}, 10),
|
|
2499
|
+
if (je = n, i || this.options.forceAutoScrollFallback || Ee || bt || ae) {
|
|
2500
|
+
On(n, this.options, a, i);
|
|
2501
|
+
var l = At(a, !0);
|
|
2502
|
+
Ln && (!oe || r !== Tn || s !== Pn) && (oe && xi(), oe = setInterval(function() {
|
|
2503
|
+
var u = At(document.elementFromPoint(r, s), !0);
|
|
2504
|
+
u !== l && (l = u, Me()), On(n, o.options, u, i);
|
|
2505
|
+
}, 10), Tn = r, Pn = s);
|
|
2506
2506
|
} else {
|
|
2507
|
-
if (!this.options.bubbleScroll ||
|
|
2508
|
-
|
|
2507
|
+
if (!this.options.bubbleScroll || At(a, !0) === dt()) {
|
|
2508
|
+
Me();
|
|
2509
2509
|
return;
|
|
2510
2510
|
}
|
|
2511
|
-
|
|
2511
|
+
On(n, this.options, At(a, !1), !1);
|
|
2512
2512
|
}
|
|
2513
2513
|
}
|
|
2514
2514
|
}, yt(e, {
|
|
@@ -2516,51 +2516,51 @@ function Ss() {
|
|
|
2516
2516
|
initializeByDefault: !0
|
|
2517
2517
|
});
|
|
2518
2518
|
}
|
|
2519
|
-
function
|
|
2520
|
-
|
|
2519
|
+
function Me() {
|
|
2520
|
+
V.forEach(function(e) {
|
|
2521
2521
|
clearInterval(e.pid);
|
|
2522
|
-
}),
|
|
2522
|
+
}), V = [];
|
|
2523
2523
|
}
|
|
2524
|
-
function
|
|
2525
|
-
clearInterval(
|
|
2524
|
+
function xi() {
|
|
2525
|
+
clearInterval(oe);
|
|
2526
2526
|
}
|
|
2527
|
-
var
|
|
2527
|
+
var On = io(function(e, t, n, i) {
|
|
2528
2528
|
if (t.scroll) {
|
|
2529
|
-
var o = (e.touches ? e.touches[0] : e).clientX, r = (e.touches ? e.touches[0] : e).clientY, s = t.scrollSensitivity, a = t.scrollSpeed, l =
|
|
2530
|
-
|
|
2531
|
-
var
|
|
2529
|
+
var o = (e.touches ? e.touches[0] : e).clientX, r = (e.touches ? e.touches[0] : e).clientY, s = t.scrollSensitivity, a = t.scrollSpeed, l = dt(), u = !1, c;
|
|
2530
|
+
Hn !== n && (Hn = n, Me(), ie = t.scroll, c = t.scrollFn, ie === !0 && (ie = At(n, !0)));
|
|
2531
|
+
var d = 0, p = ie;
|
|
2532
2532
|
do {
|
|
2533
|
-
var f = p, g =
|
|
2534
|
-
f === l ? (
|
|
2535
|
-
var
|
|
2536
|
-
if (!
|
|
2537
|
-
for (var
|
|
2538
|
-
|
|
2539
|
-
(
|
|
2540
|
-
i && this.layer === 0 &&
|
|
2541
|
-
var
|
|
2542
|
-
typeof c == "function" && c.call(
|
|
2533
|
+
var f = p, g = k(f), y = g.top, O = g.bottom, I = g.left, H = g.right, J = g.width, j = g.height, K = void 0, b = void 0, D = f.scrollWidth, Z = f.scrollHeight, U = v(f), Wt = f.scrollLeft, vt = f.scrollTop;
|
|
2534
|
+
f === l ? (K = J < D && (U.overflowX === "auto" || U.overflowX === "scroll" || U.overflowX === "visible"), b = j < Z && (U.overflowY === "auto" || U.overflowY === "scroll" || U.overflowY === "visible")) : (K = J < D && (U.overflowX === "auto" || U.overflowX === "scroll"), b = j < Z && (U.overflowY === "auto" || U.overflowY === "scroll"));
|
|
2535
|
+
var Gt = K && (Math.abs(H - o) <= s && Wt + J < D) - (Math.abs(I - o) <= s && !!Wt), ht = b && (Math.abs(O - r) <= s && vt + j < Z) - (Math.abs(y - r) <= s && !!vt);
|
|
2536
|
+
if (!V[d])
|
|
2537
|
+
for (var Pt = 0; Pt <= d; Pt++)
|
|
2538
|
+
V[Pt] || (V[Pt] = {});
|
|
2539
|
+
(V[d].vx != Gt || V[d].vy != ht || V[d].el !== f) && (V[d].el = f, V[d].vx = Gt, V[d].vy = ht, clearInterval(V[d].pid), (Gt != 0 || ht != 0) && (u = !0, V[d].pid = setInterval((function() {
|
|
2540
|
+
i && this.layer === 0 && w.active._onTouchMove(je);
|
|
2541
|
+
var Jt = V[this.layer].vy ? V[this.layer].vy * a : 0, wt = V[this.layer].vx ? V[this.layer].vx * a : 0;
|
|
2542
|
+
typeof c == "function" && c.call(w.dragged.parentNode[nt], wt, Jt, e, je, V[this.layer].el) !== "continue" || oo(V[this.layer].el, wt, Jt);
|
|
2543
2543
|
}).bind({
|
|
2544
|
-
layer:
|
|
2545
|
-
}), 24))),
|
|
2546
|
-
} while (t.bubbleScroll && p !== l && (p =
|
|
2547
|
-
|
|
2544
|
+
layer: d
|
|
2545
|
+
}), 24))), d++;
|
|
2546
|
+
} while (t.bubbleScroll && p !== l && (p = At(p, !1)));
|
|
2547
|
+
Ln = u;
|
|
2548
2548
|
}
|
|
2549
|
-
}, 30),
|
|
2549
|
+
}, 30), po = function(t) {
|
|
2550
2550
|
var n = t.originalEvent, i = t.putSortable, o = t.dragEl, r = t.activeSortable, s = t.dispatchSortableEvent, a = t.hideGhostForTarget, l = t.unhideGhostForTarget;
|
|
2551
2551
|
if (n) {
|
|
2552
|
-
var
|
|
2552
|
+
var u = i || r;
|
|
2553
2553
|
a();
|
|
2554
|
-
var c = n.changedTouches && n.changedTouches.length ? n.changedTouches[0] : n,
|
|
2555
|
-
l(),
|
|
2554
|
+
var c = n.changedTouches && n.changedTouches.length ? n.changedTouches[0] : n, d = document.elementFromPoint(c.clientX, c.clientY);
|
|
2555
|
+
l(), u && !u.el.contains(d) && (s("spill"), this.onSpill({
|
|
2556
2556
|
dragEl: o,
|
|
2557
2557
|
putSortable: i
|
|
2558
2558
|
}));
|
|
2559
2559
|
}
|
|
2560
2560
|
};
|
|
2561
|
-
function
|
|
2561
|
+
function Jn() {
|
|
2562
2562
|
}
|
|
2563
|
-
|
|
2563
|
+
Jn.prototype = {
|
|
2564
2564
|
startIndex: null,
|
|
2565
2565
|
dragStart: function(t) {
|
|
2566
2566
|
var n = t.oldDraggableIndex;
|
|
@@ -2569,44 +2569,44 @@ Yn.prototype = {
|
|
|
2569
2569
|
onSpill: function(t) {
|
|
2570
2570
|
var n = t.dragEl, i = t.putSortable;
|
|
2571
2571
|
this.sortable.captureAnimationState(), i && i.captureAnimationState();
|
|
2572
|
-
var o =
|
|
2572
|
+
var o = qt(this.sortable.el, this.startIndex, this.options);
|
|
2573
2573
|
o ? this.sortable.el.insertBefore(n, o) : this.sortable.el.appendChild(n), this.sortable.animateAll(), i && i.animateAll();
|
|
2574
2574
|
},
|
|
2575
|
-
drop:
|
|
2575
|
+
drop: po
|
|
2576
2576
|
};
|
|
2577
|
-
yt(
|
|
2577
|
+
yt(Jn, {
|
|
2578
2578
|
pluginName: "revertOnSpill"
|
|
2579
2579
|
});
|
|
2580
|
-
function
|
|
2580
|
+
function Kn() {
|
|
2581
2581
|
}
|
|
2582
|
-
|
|
2582
|
+
Kn.prototype = {
|
|
2583
2583
|
onSpill: function(t) {
|
|
2584
2584
|
var n = t.dragEl, i = t.putSortable, o = i || this.sortable;
|
|
2585
2585
|
o.captureAnimationState(), n.parentNode && n.parentNode.removeChild(n), o.animateAll();
|
|
2586
2586
|
},
|
|
2587
|
-
drop:
|
|
2587
|
+
drop: po
|
|
2588
2588
|
};
|
|
2589
|
-
yt(
|
|
2589
|
+
yt(Kn, {
|
|
2590
2590
|
pluginName: "removeOnSpill"
|
|
2591
2591
|
});
|
|
2592
|
-
|
|
2593
|
-
|
|
2594
|
-
const
|
|
2592
|
+
w.mount(new Ps());
|
|
2593
|
+
w.mount(Kn, Jn);
|
|
2594
|
+
const Os = (e) => {
|
|
2595
2595
|
const t = e.item;
|
|
2596
2596
|
let n = Array.prototype.slice.call(t.parentNode.childNodes);
|
|
2597
2597
|
return n = n.filter(
|
|
2598
2598
|
(i) => i.nodeType != Node.ELEMENT_NODE || !i.classList.contains("sortable-fallback")
|
|
2599
2599
|
), n;
|
|
2600
|
-
},
|
|
2600
|
+
}, Ds = (e, t, n, i, o, r) => {
|
|
2601
2601
|
const a = e.item.parentNode;
|
|
2602
2602
|
for (const y of n)
|
|
2603
2603
|
a.appendChild(y);
|
|
2604
2604
|
if (e.oldIndex == e.newIndex) return;
|
|
2605
|
-
const l = i.getArray(),
|
|
2605
|
+
const l = i.getArray(), u = (
|
|
2606
2606
|
/** @type {Element & {layer: import("ol/layer").Layer}} */
|
|
2607
2607
|
e.item.querySelector("eox-layercontrol-layer").layer.get(o)
|
|
2608
|
-
), c = l.find((y) => y.get(o) ===
|
|
2609
|
-
(y) => y.get(o) ==
|
|
2608
|
+
), c = l.find((y) => y.get(o) === u), d = r.dataset.layer, p = l.find(
|
|
2609
|
+
(y) => y.get(o) == d
|
|
2610
2610
|
);
|
|
2611
2611
|
let f, g;
|
|
2612
2612
|
for (f = 0; f < l.length; f++)
|
|
@@ -2621,22 +2621,22 @@ const $s = (e) => {
|
|
|
2621
2621
|
}
|
|
2622
2622
|
t.requestUpdate();
|
|
2623
2623
|
};
|
|
2624
|
-
function
|
|
2624
|
+
function Rs(e, t, n, i) {
|
|
2625
2625
|
let o = [], r = null;
|
|
2626
|
-
e._sortable =
|
|
2626
|
+
e._sortable = w.create(e, {
|
|
2627
2627
|
handle: ".drag-handle",
|
|
2628
2628
|
filter: ".drag-handle.disabled",
|
|
2629
2629
|
swapThreshold: 0.5,
|
|
2630
2630
|
animation: 150,
|
|
2631
2631
|
easing: "cubic-bezier(1, 0, 0, 1)",
|
|
2632
|
-
onStart: (s) => o =
|
|
2632
|
+
onStart: (s) => o = Os(s),
|
|
2633
2633
|
onMove: (s) => {
|
|
2634
2634
|
r = s.related;
|
|
2635
2635
|
},
|
|
2636
|
-
onEnd: (s) =>
|
|
2636
|
+
onEnd: (s) => Ds(s, i, o, t, n, r)
|
|
2637
2637
|
});
|
|
2638
2638
|
}
|
|
2639
|
-
function
|
|
2639
|
+
function Ms(e, t, n, i) {
|
|
2640
2640
|
const o = e.getArray();
|
|
2641
2641
|
let r = !1;
|
|
2642
2642
|
o.forEach((s) => {
|
|
@@ -2644,46 +2644,46 @@ function Cs(e, t, n, i) {
|
|
|
2644
2644
|
s.get(t) || (s.set(t, a), r = !0), s.get(n) || (s.set(n, `layer ${a}`), r = !0), r && i.requestUpdate();
|
|
2645
2645
|
});
|
|
2646
2646
|
}
|
|
2647
|
-
function
|
|
2647
|
+
function Qn(e, t, n) {
|
|
2648
2648
|
let i = [];
|
|
2649
2649
|
const o = (r, s, a) => {
|
|
2650
2650
|
i = [
|
|
2651
2651
|
...i,
|
|
2652
|
-
...r.filter((
|
|
2652
|
+
...r.filter((u) => u.get(s) === a)
|
|
2653
2653
|
];
|
|
2654
2654
|
const l = r.filter(
|
|
2655
|
-
(
|
|
2655
|
+
(u) => (
|
|
2656
2656
|
/** @type {import("ol/layer").Group} */
|
|
2657
|
-
|
|
2657
|
+
u.getLayers
|
|
2658
2658
|
)
|
|
2659
2659
|
);
|
|
2660
2660
|
return l.length > 0 && l.forEach(
|
|
2661
|
-
(
|
|
2661
|
+
(u) => (
|
|
2662
2662
|
// @ts-ignore
|
|
2663
|
-
o(
|
|
2663
|
+
o(u.getLayers().getArray(), s, a)
|
|
2664
2664
|
)
|
|
2665
2665
|
), i;
|
|
2666
2666
|
};
|
|
2667
2667
|
return o(e, t, n), i;
|
|
2668
2668
|
}
|
|
2669
|
-
function
|
|
2669
|
+
function Is(e, t, n) {
|
|
2670
2670
|
if (!e || !t) return !1;
|
|
2671
|
-
if (!
|
|
2671
|
+
if (!fo(e, n)) return !0;
|
|
2672
2672
|
const i = e.get("minZoom"), o = e.get("maxZoom"), r = t.getView().getZoom();
|
|
2673
2673
|
return r > i && r < o;
|
|
2674
2674
|
}
|
|
2675
|
-
function
|
|
2675
|
+
function fo(e, t) {
|
|
2676
2676
|
const n = e.get("minZoom"), i = e.get("maxZoom");
|
|
2677
2677
|
return !!(t && (n !== -1 / 0 || i !== 1 / 0));
|
|
2678
2678
|
}
|
|
2679
|
-
function
|
|
2679
|
+
function Ns(e, t) {
|
|
2680
2680
|
var o, r, s;
|
|
2681
2681
|
return !e || !t ? void 0 : e.getLayers ? "group" : ((s = (o = t.getInteractions().getArray().filter((a) => a.freehand_ !== void 0).map((a) => a.source_)) == null ? void 0 : o.ol_uid) == null ? void 0 : s.includes(
|
|
2682
2682
|
// @ts-ignore
|
|
2683
2683
|
e.getSource ? (r = e.getSource()) == null ? void 0 : r.ol_uid : void 0
|
|
2684
2684
|
)) ? "draw" : e.declutter_ !== void 0 ? "vector" : "raster";
|
|
2685
2685
|
}
|
|
2686
|
-
function
|
|
2686
|
+
function go(e, t) {
|
|
2687
2687
|
var i;
|
|
2688
2688
|
let n = {};
|
|
2689
2689
|
for (const o in e) {
|
|
@@ -2691,7 +2691,7 @@ function lo(e, t) {
|
|
|
2691
2691
|
if (r && r !== "object")
|
|
2692
2692
|
n[o] = r === "number" ? Number(t[o]) : t[o];
|
|
2693
2693
|
else if (typeof e[o] == "object" && ((i = e[o]) != null && i.properties)) {
|
|
2694
|
-
const s =
|
|
2694
|
+
const s = go(
|
|
2695
2695
|
e[o].properties,
|
|
2696
2696
|
t
|
|
2697
2697
|
);
|
|
@@ -2700,8 +2700,8 @@ function lo(e, t) {
|
|
|
2700
2700
|
}
|
|
2701
2701
|
return n;
|
|
2702
2702
|
}
|
|
2703
|
-
function
|
|
2704
|
-
var r, s, a, l,
|
|
2703
|
+
function Hs(e, t) {
|
|
2704
|
+
var r, s, a, l, u;
|
|
2705
2705
|
if (!t) return null;
|
|
2706
2706
|
let n = {}, i = "updateStyleVariables" in e ? (
|
|
2707
2707
|
/** @type {import("ol/layer/WebGLTile").default} */
|
|
@@ -2713,20 +2713,20 @@ function Ds(e, t) {
|
|
|
2713
2713
|
const c = new URL(e.getSource().getTileUrlFunction()([0, 0, 0]));
|
|
2714
2714
|
n = Object.fromEntries(c.searchParams.entries());
|
|
2715
2715
|
} else return null;
|
|
2716
|
-
const o =
|
|
2717
|
-
((
|
|
2716
|
+
const o = go(
|
|
2717
|
+
((u = t.schema) == null ? void 0 : u.properties) || t.schema,
|
|
2718
2718
|
n
|
|
2719
2719
|
);
|
|
2720
2720
|
return Object.keys(o).length ? o : null;
|
|
2721
2721
|
}
|
|
2722
|
-
const
|
|
2722
|
+
const Ls = (e, t) => e == null ? void 0 : e.filter(
|
|
2723
2723
|
(n) => ["remove", "sort"].filter((i) => t != null && t.get("layerControlDisable") ? i !== "sort" : !0).includes(n)
|
|
2724
|
-
),
|
|
2724
|
+
), Bs = (e, t) => e == null ? void 0 : e.filter((n) => {
|
|
2725
2725
|
let i = !0;
|
|
2726
2726
|
return ["remove", "sort"].includes(n) && (i = !1), n === "info" && (i = t.get("description")), n === "config" && (i = t.get("layerConfig")), n === "datetime" && (i = t.get("layerDatetime")), i;
|
|
2727
|
-
}),
|
|
2727
|
+
}), Vs = (e, t) => x`
|
|
2728
2728
|
<button slot="${e}-icon" class="icon">${t ? e : C}</button>
|
|
2729
|
-
`,
|
|
2729
|
+
`, ks = (e) => x`
|
|
2730
2730
|
<button
|
|
2731
2731
|
class="remove-icon icon"
|
|
2732
2732
|
@click=${() => {
|
|
@@ -2741,11 +2741,11 @@ const Os = (e, t) => e == null ? void 0 : e.filter(
|
|
|
2741
2741
|
>
|
|
2742
2742
|
${e.unstyled ? "x" : C}
|
|
2743
2743
|
</button>
|
|
2744
|
-
`,
|
|
2744
|
+
`, Us = (e) => x`
|
|
2745
2745
|
<span class="button sort-icon icon drag-handle">
|
|
2746
2746
|
${e ? "═" : C}
|
|
2747
2747
|
</span>
|
|
2748
|
-
`,
|
|
2748
|
+
`, mo = (e) => {
|
|
2749
2749
|
var n;
|
|
2750
2750
|
const t = ["layerControlHide", "layerControlOptional"];
|
|
2751
2751
|
return (n = e == null ? void 0 : e.getArray()) == null ? void 0 : n.filter((i) => t.every((o) => !i.get(o)));
|
|
@@ -2755,23 +2755,23 @@ const Os = (e, t) => e == null ? void 0 : e.filter(
|
|
|
2755
2755
|
* Copyright 2020 Google LLC
|
|
2756
2756
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
2757
2757
|
*/
|
|
2758
|
-
const
|
|
2758
|
+
const yo = Xn(class extends qn {
|
|
2759
2759
|
constructor(e) {
|
|
2760
2760
|
if (super(e), e.type !== Et.PROPERTY && e.type !== Et.ATTRIBUTE && e.type !== Et.BOOLEAN_ATTRIBUTE) throw Error("The `live` directive is not allowed on child or event bindings");
|
|
2761
|
-
if (!
|
|
2761
|
+
if (!sr(e)) throw Error("`live` bindings can only contain a single expression");
|
|
2762
2762
|
}
|
|
2763
2763
|
render(e) {
|
|
2764
2764
|
return e;
|
|
2765
2765
|
}
|
|
2766
2766
|
update(e, [t]) {
|
|
2767
|
-
if (t ===
|
|
2767
|
+
if (t === at || t === C) return t;
|
|
2768
2768
|
const n = e.element, i = e.name;
|
|
2769
2769
|
if (e.type === Et.PROPERTY) {
|
|
2770
|
-
if (t === n[i]) return
|
|
2770
|
+
if (t === n[i]) return at;
|
|
2771
2771
|
} else if (e.type === Et.BOOLEAN_ATTRIBUTE) {
|
|
2772
|
-
if (!!t === n.hasAttribute(i)) return
|
|
2773
|
-
} else if (e.type === Et.ATTRIBUTE && n.getAttribute(i) === t + "") return
|
|
2774
|
-
return
|
|
2772
|
+
if (!!t === n.hasAttribute(i)) return at;
|
|
2773
|
+
} else if (e.type === Et.ATTRIBUTE && n.getAttribute(i) === t + "") return at;
|
|
2774
|
+
return ji(e), t;
|
|
2775
2775
|
}
|
|
2776
2776
|
});
|
|
2777
2777
|
/**
|
|
@@ -2779,13 +2779,13 @@ const co = jn(class extends Zn {
|
|
|
2779
2779
|
* Copyright 2017 Google LLC
|
|
2780
2780
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
2781
2781
|
*/
|
|
2782
|
-
class
|
|
2782
|
+
class Bn extends qn {
|
|
2783
2783
|
constructor(t) {
|
|
2784
2784
|
if (super(t), this.it = C, t.type !== Et.CHILD) throw Error(this.constructor.directiveName + "() can only be used in child bindings");
|
|
2785
2785
|
}
|
|
2786
2786
|
render(t) {
|
|
2787
2787
|
if (t === C || t == null) return this._t = void 0, this.it = t;
|
|
2788
|
-
if (t ===
|
|
2788
|
+
if (t === at) return t;
|
|
2789
2789
|
if (typeof t != "string") throw Error(this.constructor.directiveName + "() called with a non-string value");
|
|
2790
2790
|
if (t === this.it) return this._t;
|
|
2791
2791
|
this.it = t;
|
|
@@ -2793,51 +2793,51 @@ class Hn extends Zn {
|
|
|
2793
2793
|
return n.raw = n, this._t = { _$litType$: this.constructor.resultType, strings: n, values: [] };
|
|
2794
2794
|
}
|
|
2795
2795
|
}
|
|
2796
|
-
|
|
2797
|
-
const
|
|
2796
|
+
Bn.directiveName = "unsafeHTML", Bn.resultType = 1;
|
|
2797
|
+
const Fs = Xn(Bn);
|
|
2798
2798
|
/**
|
|
2799
2799
|
* @license
|
|
2800
2800
|
* Copyright 2021 Google LLC
|
|
2801
2801
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
2802
2802
|
*/
|
|
2803
|
-
function*
|
|
2803
|
+
function* Ie(e, t) {
|
|
2804
2804
|
if (e !== void 0) {
|
|
2805
2805
|
let n = 0;
|
|
2806
2806
|
for (const i of e) yield t(i, n++);
|
|
2807
2807
|
}
|
|
2808
2808
|
}
|
|
2809
|
-
const
|
|
2809
|
+
const js = (e, t, n) => {
|
|
2810
2810
|
let i = t;
|
|
2811
2811
|
return n.layer.getSource().getTileUrlFunction() && (i || (i = n.layer.getSource().getTileUrlFunction()), n.layer.getSource().setTileUrlFunction(
|
|
2812
|
-
(...o) =>
|
|
2812
|
+
(...o) => os(i(...o), e)
|
|
2813
2813
|
), n.layer.getSource().setKey(/* @__PURE__ */ new Date())), i;
|
|
2814
2814
|
};
|
|
2815
|
-
function
|
|
2815
|
+
function Zs(e, t, n) {
|
|
2816
2816
|
const i = "updateStyleVariables" in t, o = "setStyle" in t, r = i ? (
|
|
2817
2817
|
/** @type {import('ol/layer/WebGLTile').default} */
|
|
2818
2818
|
t.style_
|
|
2819
2819
|
) : n.style;
|
|
2820
2820
|
let s = r == null ? void 0 : r.variables;
|
|
2821
2821
|
if (s) {
|
|
2822
|
-
const a =
|
|
2822
|
+
const a = bo(e);
|
|
2823
2823
|
if (r.variables = {
|
|
2824
2824
|
...s,
|
|
2825
2825
|
...a
|
|
2826
2826
|
}, i)
|
|
2827
2827
|
t.updateStyleVariables(a);
|
|
2828
2828
|
else if (o) {
|
|
2829
|
-
const l =
|
|
2829
|
+
const l = zs(r);
|
|
2830
2830
|
t.setStyle(
|
|
2831
2831
|
l
|
|
2832
2832
|
);
|
|
2833
2833
|
}
|
|
2834
2834
|
}
|
|
2835
2835
|
}
|
|
2836
|
-
const
|
|
2836
|
+
const bo = (e) => {
|
|
2837
2837
|
const t = {};
|
|
2838
2838
|
for (const n in e)
|
|
2839
2839
|
if (typeof e[n] == "object" && e[n] !== null) {
|
|
2840
|
-
const i =
|
|
2840
|
+
const i = bo(
|
|
2841
2841
|
/** @type {Record<string,any>} */
|
|
2842
2842
|
e[n]
|
|
2843
2843
|
);
|
|
@@ -2847,7 +2847,7 @@ const ho = (e) => {
|
|
|
2847
2847
|
t[n] = e == null ? void 0 : e[n];
|
|
2848
2848
|
return t;
|
|
2849
2849
|
};
|
|
2850
|
-
function
|
|
2850
|
+
function zs(e) {
|
|
2851
2851
|
let t = e;
|
|
2852
2852
|
if ("variables" in e) {
|
|
2853
2853
|
let n = JSON.stringify(e);
|
|
@@ -2861,115 +2861,133 @@ function Ls(e) {
|
|
|
2861
2861
|
}
|
|
2862
2862
|
return t;
|
|
2863
2863
|
}
|
|
2864
|
-
var
|
|
2865
|
-
function
|
|
2864
|
+
var _t = typeof globalThis < "u" ? globalThis : typeof window < "u" ? window : typeof global < "u" ? global : typeof self < "u" ? self : {};
|
|
2865
|
+
function vo(e) {
|
|
2866
2866
|
return e && e.__esModule && Object.prototype.hasOwnProperty.call(e, "default") ? e.default : e;
|
|
2867
2867
|
}
|
|
2868
|
-
var
|
|
2869
|
-
return
|
|
2868
|
+
var wo = "Expected a function", Si = NaN, Xs = "[object Symbol]", qs = /^\s+|\s+$/g, Ys = /^[-+]0x[0-9a-f]+$/i, Ws = /^0b[01]+$/i, Gs = /^0o[0-7]+$/i, Js = parseInt, Ks = typeof _t == "object" && _t && _t.Object === Object && _t, Qs = typeof self == "object" && self && self.Object === Object && self, ta = Ks || Qs || Function("return this")(), ea = Object.prototype, na = ea.toString, ia = Math.max, oa = Math.min, Dn = function() {
|
|
2869
|
+
return ta.Date.now();
|
|
2870
2870
|
};
|
|
2871
|
-
function
|
|
2872
|
-
var i, o, r, s, a, l,
|
|
2871
|
+
function ra(e, t, n) {
|
|
2872
|
+
var i, o, r, s, a, l, u = 0, c = !1, d = !1, p = !0;
|
|
2873
2873
|
if (typeof e != "function")
|
|
2874
|
-
throw new TypeError(
|
|
2875
|
-
t =
|
|
2876
|
-
function f(
|
|
2877
|
-
var
|
|
2878
|
-
return i = o = void 0,
|
|
2874
|
+
throw new TypeError(wo);
|
|
2875
|
+
t = $i(t) || 0, Ze(n) && (c = !!n.leading, d = "maxWait" in n, r = d ? ia($i(n.maxWait) || 0, t) : r, p = "trailing" in n ? !!n.trailing : p);
|
|
2876
|
+
function f(b) {
|
|
2877
|
+
var D = i, Z = o;
|
|
2878
|
+
return i = o = void 0, u = b, s = e.apply(Z, D), s;
|
|
2879
2879
|
}
|
|
2880
|
-
function g(
|
|
2881
|
-
return
|
|
2880
|
+
function g(b) {
|
|
2881
|
+
return u = b, a = setTimeout(I, t), c ? f(b) : s;
|
|
2882
2882
|
}
|
|
2883
|
-
function y(
|
|
2884
|
-
var
|
|
2885
|
-
return
|
|
2883
|
+
function y(b) {
|
|
2884
|
+
var D = b - l, Z = b - u, U = t - D;
|
|
2885
|
+
return d ? oa(U, r - Z) : U;
|
|
2886
2886
|
}
|
|
2887
|
-
function
|
|
2888
|
-
var
|
|
2889
|
-
return l === void 0 ||
|
|
2887
|
+
function O(b) {
|
|
2888
|
+
var D = b - l, Z = b - u;
|
|
2889
|
+
return l === void 0 || D >= t || D < 0 || d && Z >= r;
|
|
2890
2890
|
}
|
|
2891
|
-
function
|
|
2892
|
-
var
|
|
2893
|
-
if (
|
|
2894
|
-
return
|
|
2895
|
-
a = setTimeout(
|
|
2891
|
+
function I() {
|
|
2892
|
+
var b = Dn();
|
|
2893
|
+
if (O(b))
|
|
2894
|
+
return H(b);
|
|
2895
|
+
a = setTimeout(I, y(b));
|
|
2896
2896
|
}
|
|
2897
|
-
function
|
|
2898
|
-
return a = void 0, p && i ? f(
|
|
2897
|
+
function H(b) {
|
|
2898
|
+
return a = void 0, p && i ? f(b) : (i = o = void 0, s);
|
|
2899
2899
|
}
|
|
2900
|
-
function
|
|
2901
|
-
a !== void 0 && clearTimeout(a),
|
|
2900
|
+
function J() {
|
|
2901
|
+
a !== void 0 && clearTimeout(a), u = 0, i = l = o = a = void 0;
|
|
2902
2902
|
}
|
|
2903
|
-
function
|
|
2904
|
-
return a === void 0 ? s :
|
|
2903
|
+
function j() {
|
|
2904
|
+
return a === void 0 ? s : H(Dn());
|
|
2905
2905
|
}
|
|
2906
|
-
function
|
|
2907
|
-
var
|
|
2908
|
-
if (i = arguments, o = this, l =
|
|
2906
|
+
function K() {
|
|
2907
|
+
var b = Dn(), D = O(b);
|
|
2908
|
+
if (i = arguments, o = this, l = b, D) {
|
|
2909
2909
|
if (a === void 0)
|
|
2910
2910
|
return g(l);
|
|
2911
|
-
if (
|
|
2912
|
-
return a = setTimeout(
|
|
2911
|
+
if (d)
|
|
2912
|
+
return a = setTimeout(I, t), f(l);
|
|
2913
2913
|
}
|
|
2914
|
-
return a === void 0 && (a = setTimeout(
|
|
2914
|
+
return a === void 0 && (a = setTimeout(I, t)), s;
|
|
2915
2915
|
}
|
|
2916
|
-
return
|
|
2916
|
+
return K.cancel = J, K.flush = j, K;
|
|
2917
|
+
}
|
|
2918
|
+
function sa(e, t, n) {
|
|
2919
|
+
var i = !0, o = !0;
|
|
2920
|
+
if (typeof e != "function")
|
|
2921
|
+
throw new TypeError(wo);
|
|
2922
|
+
return Ze(n) && (i = "leading" in n ? !!n.leading : i, o = "trailing" in n ? !!n.trailing : o), ra(e, t, {
|
|
2923
|
+
leading: i,
|
|
2924
|
+
maxWait: t,
|
|
2925
|
+
trailing: o
|
|
2926
|
+
});
|
|
2917
2927
|
}
|
|
2918
|
-
function
|
|
2928
|
+
function Ze(e) {
|
|
2919
2929
|
var t = typeof e;
|
|
2920
2930
|
return !!e && (t == "object" || t == "function");
|
|
2921
2931
|
}
|
|
2922
|
-
function
|
|
2932
|
+
function aa(e) {
|
|
2923
2933
|
return !!e && typeof e == "object";
|
|
2924
2934
|
}
|
|
2925
|
-
function
|
|
2926
|
-
return typeof e == "symbol" ||
|
|
2935
|
+
function la(e) {
|
|
2936
|
+
return typeof e == "symbol" || aa(e) && na.call(e) == Xs;
|
|
2927
2937
|
}
|
|
2928
|
-
function
|
|
2938
|
+
function $i(e) {
|
|
2929
2939
|
if (typeof e == "number")
|
|
2930
2940
|
return e;
|
|
2931
|
-
if (
|
|
2932
|
-
return
|
|
2933
|
-
if (
|
|
2941
|
+
if (la(e))
|
|
2942
|
+
return Si;
|
|
2943
|
+
if (Ze(e)) {
|
|
2934
2944
|
var t = typeof e.valueOf == "function" ? e.valueOf() : e;
|
|
2935
|
-
e =
|
|
2945
|
+
e = Ze(t) ? t + "" : t;
|
|
2936
2946
|
}
|
|
2937
2947
|
if (typeof e != "string")
|
|
2938
2948
|
return e === 0 ? e : +e;
|
|
2939
|
-
e = e.replace(
|
|
2940
|
-
var n =
|
|
2941
|
-
return n ||
|
|
2942
|
-
}
|
|
2943
|
-
var
|
|
2944
|
-
const
|
|
2945
|
-
var
|
|
2946
|
-
class
|
|
2949
|
+
e = e.replace(qs, "");
|
|
2950
|
+
var n = Ws.test(e);
|
|
2951
|
+
return n || Gs.test(e) ? Js(e.slice(2), n ? 2 : 8) : Ys.test(e) ? Si : +e;
|
|
2952
|
+
}
|
|
2953
|
+
var ua = sa;
|
|
2954
|
+
const Ai = /* @__PURE__ */ vo(ua);
|
|
2955
|
+
var Xt, me, ye, be, Vn, ze, Xe;
|
|
2956
|
+
class Eo extends it {
|
|
2947
2957
|
constructor() {
|
|
2948
2958
|
super();
|
|
2949
|
-
T(this,
|
|
2959
|
+
T(this, be);
|
|
2950
2960
|
/**
|
|
2951
2961
|
* data input by the user
|
|
2952
2962
|
*
|
|
2953
2963
|
* @type {{[key: string]: any}}
|
|
2954
2964
|
*/
|
|
2955
|
-
T(this,
|
|
2965
|
+
T(this, Xt, {});
|
|
2956
2966
|
/**
|
|
2957
2967
|
* data input by the user
|
|
2958
2968
|
*
|
|
2959
2969
|
* @type {{[key: string]: any}}
|
|
2960
2970
|
*/
|
|
2961
|
-
T(this,
|
|
2971
|
+
T(this, me, null);
|
|
2962
2972
|
/**
|
|
2963
2973
|
* Original tile url function, if it exist
|
|
2964
2974
|
*
|
|
2965
2975
|
* @type {Function}
|
|
2966
2976
|
*/
|
|
2967
|
-
T(this,
|
|
2968
|
-
T(this, Ze, "");
|
|
2977
|
+
T(this, ye);
|
|
2969
2978
|
T(this, ze, "");
|
|
2970
|
-
|
|
2971
|
-
|
|
2972
|
-
|
|
2979
|
+
T(this, Xe, "");
|
|
2980
|
+
this.layer = null, this.unstyled = !1, this.noShadow = !1, this.layerConfig = null, this.throttleDataChange = Ai(B(this, be, Vn), 1e3);
|
|
2981
|
+
}
|
|
2982
|
+
/** Decide what type of throttling to do based on layerConfig type
|
|
2983
|
+
*
|
|
2984
|
+
* @param {import("lit").PropertyValues} changedProperties - The changed properties.
|
|
2985
|
+
*/
|
|
2986
|
+
updated(n) {
|
|
2987
|
+
if (n.has("layerConfig")) {
|
|
2988
|
+
const i = this.layerConfig.type === "style" || this.layerConfig.style ? 100 : 1e3;
|
|
2989
|
+
this.throttleDataChange = Ai(B(this, be, Vn), i), this.requestUpdate();
|
|
2990
|
+
}
|
|
2973
2991
|
}
|
|
2974
2992
|
/**
|
|
2975
2993
|
* Overrides createRenderRoot to handle shadow DOM creation based on the noShadow property.
|
|
@@ -2981,47 +2999,47 @@ class fo extends tt {
|
|
|
2981
2999
|
* Renders a JSON form for configuration options of a layer.
|
|
2982
3000
|
*/
|
|
2983
3001
|
render() {
|
|
2984
|
-
|
|
3002
|
+
Qt(this, me, Hs(this.layer, this.layerConfig)), customElements.get("eox-jsonform") || console.error("Please import @eox/jsonform in order to use layerconfig");
|
|
2985
3003
|
const n = {
|
|
2986
3004
|
disable_edit_json: !0,
|
|
2987
3005
|
disable_collapse: !0,
|
|
2988
3006
|
disable_properties: !0
|
|
2989
3007
|
};
|
|
2990
|
-
return
|
|
3008
|
+
return x`
|
|
2991
3009
|
<style>
|
|
2992
|
-
${P(this,
|
|
2993
|
-
${!this.unstyled && P(this,
|
|
3010
|
+
${P(this, ze)}
|
|
3011
|
+
${!this.unstyled && P(this, Xe)}
|
|
2994
3012
|
</style>
|
|
2995
|
-
${
|
|
3013
|
+
${G(
|
|
2996
3014
|
this.layerConfig,
|
|
2997
|
-
() =>
|
|
3015
|
+
() => x`
|
|
2998
3016
|
<!-- Render a JSON form for layer configuration -->
|
|
2999
3017
|
<eox-jsonform
|
|
3000
3018
|
.schema=${this.layerConfig.schema}
|
|
3001
|
-
.value=${P(this,
|
|
3019
|
+
.value=${P(this, me)}
|
|
3002
3020
|
.options=${n}
|
|
3003
|
-
@change=${this.
|
|
3021
|
+
@change=${this.throttleDataChange}
|
|
3004
3022
|
></eox-jsonform>
|
|
3005
3023
|
`
|
|
3006
3024
|
)}
|
|
3007
3025
|
`;
|
|
3008
3026
|
}
|
|
3009
3027
|
}
|
|
3010
|
-
|
|
3028
|
+
Xt = new WeakMap(), me = new WeakMap(), ye = new WeakMap(), be = new WeakSet(), /**
|
|
3011
3029
|
* Handles changes in eox-jsonform values.
|
|
3012
3030
|
*
|
|
3013
3031
|
* @param {{ detail: { value: string; }; }} e
|
|
3014
3032
|
*/
|
|
3015
|
-
|
|
3016
|
-
|
|
3033
|
+
Vn = function(n) {
|
|
3034
|
+
Qt(this, Xt, n.detail), this.layerConfig.type === "style" || this.layerConfig.style ? "setStyle" in this.layer || "updateStyleVariables" in this.layer ? Zs(P(this, Xt), this.layer, this.layerConfig) : console.error(
|
|
3017
3035
|
`Layer type ${this.layer.get("type") ?? ""} does not support styles configuration`
|
|
3018
|
-
) : (
|
|
3019
|
-
P(this,
|
|
3020
|
-
P(this,
|
|
3036
|
+
) : (Qt(this, ye, js(
|
|
3037
|
+
P(this, Xt),
|
|
3038
|
+
P(this, ye),
|
|
3021
3039
|
this
|
|
3022
3040
|
)), this.requestUpdate());
|
|
3023
|
-
},
|
|
3024
|
-
|
|
3041
|
+
}, ze = new WeakMap(), Xe = new WeakMap(), // Define static properties for the component
|
|
3042
|
+
L(Eo, "properties", {
|
|
3025
3043
|
layer: { attribute: !1 },
|
|
3026
3044
|
unstyled: { type: Boolean },
|
|
3027
3045
|
noShadow: { type: Boolean },
|
|
@@ -3029,15 +3047,15 @@ N(fo, "properties", {
|
|
|
3029
3047
|
});
|
|
3030
3048
|
customElements.define(
|
|
3031
3049
|
"eox-layercontrol-layerconfig",
|
|
3032
|
-
|
|
3050
|
+
Eo
|
|
3033
3051
|
);
|
|
3034
|
-
var
|
|
3035
|
-
class
|
|
3052
|
+
var qe, So, Ye, We;
|
|
3053
|
+
class xo extends it {
|
|
3036
3054
|
constructor() {
|
|
3037
3055
|
super();
|
|
3038
|
-
T(this,
|
|
3039
|
-
T(this, qe, "");
|
|
3056
|
+
T(this, qe);
|
|
3040
3057
|
T(this, Ye, "");
|
|
3058
|
+
T(this, We, "");
|
|
3041
3059
|
this.unstyled = !1, this.noShadow = !1, this.layerDatetime = null, this.layer = null;
|
|
3042
3060
|
}
|
|
3043
3061
|
/**
|
|
@@ -3052,14 +3070,14 @@ class mo extends tt {
|
|
|
3052
3070
|
render() {
|
|
3053
3071
|
return customElements.get("eox-timecontrol") || console.error(
|
|
3054
3072
|
"Please import @eox/timecontrol in order to use layerDatetime"
|
|
3055
|
-
),
|
|
3073
|
+
), x`
|
|
3056
3074
|
<style>
|
|
3057
|
-
${P(this,
|
|
3058
|
-
${!this.unstyled && P(this,
|
|
3075
|
+
${P(this, Ye)}
|
|
3076
|
+
${!this.unstyled && P(this, We)}
|
|
3059
3077
|
</style>
|
|
3060
|
-
${
|
|
3078
|
+
${G(
|
|
3061
3079
|
this.layerDatetime,
|
|
3062
|
-
() =>
|
|
3080
|
+
() => x`
|
|
3063
3081
|
<!-- Render a Timecontrol for layer date time -->
|
|
3064
3082
|
<eox-timecontrol
|
|
3065
3083
|
?unstyled=${this.unstyled}
|
|
@@ -3070,20 +3088,20 @@ class mo extends tt {
|
|
|
3070
3088
|
.controlValues=${this.layerDatetime.controlValues}
|
|
3071
3089
|
.controlProperty=${void 0}
|
|
3072
3090
|
current-step=${this.layerDatetime.currentStep}
|
|
3073
|
-
@stepchange=${B(this,
|
|
3091
|
+
@stepchange=${B(this, qe, So)}
|
|
3074
3092
|
></eox-timecontrol>
|
|
3075
3093
|
`
|
|
3076
3094
|
)}
|
|
3077
3095
|
`;
|
|
3078
3096
|
}
|
|
3079
3097
|
}
|
|
3080
|
-
|
|
3098
|
+
qe = new WeakSet(), /**
|
|
3081
3099
|
* Handles timecontrol Stepchange &
|
|
3082
3100
|
* triggers `datetime:updated` event on step change
|
|
3083
3101
|
*
|
|
3084
3102
|
* @param {CustomEvent<{currentStep:string|number}>} evt
|
|
3085
3103
|
**/
|
|
3086
|
-
|
|
3104
|
+
So = function(n) {
|
|
3087
3105
|
this.dispatchEvent(
|
|
3088
3106
|
new CustomEvent("datetime:updated", {
|
|
3089
3107
|
bubbles: !0,
|
|
@@ -3093,8 +3111,8 @@ yo = function(n) {
|
|
|
3093
3111
|
}
|
|
3094
3112
|
})
|
|
3095
3113
|
), this.layerDatetime.currentStep = n.detail.currentStep, this.requestUpdate();
|
|
3096
|
-
},
|
|
3097
|
-
|
|
3114
|
+
}, Ye = new WeakMap(), We = new WeakMap(), // Define static properties for the component
|
|
3115
|
+
L(xo, "properties", {
|
|
3098
3116
|
unstyled: { type: Boolean },
|
|
3099
3117
|
noShadow: { type: Boolean },
|
|
3100
3118
|
layerDatetime: { attribute: !1 },
|
|
@@ -3102,15 +3120,15 @@ N(mo, "properties", {
|
|
|
3102
3120
|
});
|
|
3103
3121
|
customElements.define(
|
|
3104
3122
|
"eox-layercontrol-layer-datetime",
|
|
3105
|
-
|
|
3123
|
+
xo
|
|
3106
3124
|
);
|
|
3107
|
-
var
|
|
3108
|
-
class
|
|
3125
|
+
var ve, Ge, Je;
|
|
3126
|
+
class $o extends it {
|
|
3109
3127
|
constructor() {
|
|
3110
3128
|
super();
|
|
3111
3129
|
/** @param {number} index */
|
|
3112
|
-
T(this,
|
|
3113
|
-
T(this,
|
|
3130
|
+
T(this, ve, (n) => (this.selectedTab === n || this.toolsAsList) && "highlighted");
|
|
3131
|
+
T(this, Ge, `
|
|
3114
3132
|
.tabbed figure {
|
|
3115
3133
|
margin: 0;
|
|
3116
3134
|
}
|
|
@@ -3131,7 +3149,7 @@ class bo extends tt {
|
|
|
3131
3149
|
background: lightgrey;
|
|
3132
3150
|
}
|
|
3133
3151
|
`);
|
|
3134
|
-
T(this,
|
|
3152
|
+
T(this, Je, `
|
|
3135
3153
|
.listed {
|
|
3136
3154
|
background: #ffffff !important;
|
|
3137
3155
|
display: flex;
|
|
@@ -3158,7 +3176,7 @@ class bo extends tt {
|
|
|
3158
3176
|
border-top: 1px solid #0041701a;
|
|
3159
3177
|
}
|
|
3160
3178
|
`);
|
|
3161
|
-
this.actions = [], this.selectedTab = 0, this.tabs = [], this.unstyled = !1, this.noShadow = !1, this.
|
|
3179
|
+
this.actions = [], this.selectedTab = 0, this.tabs = [], this.unstyled = !1, this.noShadow = !1, this.toolsAsList = !1;
|
|
3162
3180
|
}
|
|
3163
3181
|
/**
|
|
3164
3182
|
* Overrides createRenderRoot to handle shadow DOM creation based on the noShadow property.
|
|
@@ -3172,27 +3190,27 @@ class bo extends tt {
|
|
|
3172
3190
|
*/
|
|
3173
3191
|
render() {
|
|
3174
3192
|
const n = this.tabs, i = this.actions, o = i.length + n.length > 1;
|
|
3175
|
-
return
|
|
3193
|
+
return x`
|
|
3176
3194
|
<style>
|
|
3177
|
-
${P(this,
|
|
3178
|
-
${!this.unstyled && P(this,
|
|
3195
|
+
${P(this, Ge)}
|
|
3196
|
+
${!this.unstyled && P(this, Je)}
|
|
3179
3197
|
</style>
|
|
3180
3198
|
<div class="tabbed">
|
|
3181
3199
|
<!-- Navigation for tabs and actions -->
|
|
3182
|
-
${
|
|
3200
|
+
${G(
|
|
3183
3201
|
o,
|
|
3184
|
-
() =>
|
|
3202
|
+
() => x`
|
|
3185
3203
|
<nav>
|
|
3186
|
-
${
|
|
3187
|
-
!this.
|
|
3188
|
-
() =>
|
|
3204
|
+
${G(
|
|
3205
|
+
!this.toolsAsList,
|
|
3206
|
+
() => x`
|
|
3189
3207
|
<div>
|
|
3190
3208
|
<!-- Labels for tabs -->
|
|
3191
|
-
${
|
|
3209
|
+
${Ie(
|
|
3192
3210
|
n,
|
|
3193
|
-
(r, s) =>
|
|
3211
|
+
(r, s) => x`
|
|
3194
3212
|
<label
|
|
3195
|
-
class=${P(this,
|
|
3213
|
+
class=${P(this, ve).call(this, s)}
|
|
3196
3214
|
@click=${() => this.selectedTab = s}
|
|
3197
3215
|
>
|
|
3198
3216
|
<!-- Customizable icon for each tab -->
|
|
@@ -3203,9 +3221,9 @@ class bo extends tt {
|
|
|
3203
3221
|
</div>
|
|
3204
3222
|
<div>
|
|
3205
3223
|
<!-- Icons for actions -->
|
|
3206
|
-
${
|
|
3224
|
+
${Ie(
|
|
3207
3225
|
i,
|
|
3208
|
-
(r) =>
|
|
3226
|
+
(r) => x`
|
|
3209
3227
|
<span>
|
|
3210
3228
|
<!-- Customizable icon for each action -->
|
|
3211
3229
|
<slot name=${`${r}-icon`}>${r}</slot>
|
|
@@ -3220,19 +3238,19 @@ class bo extends tt {
|
|
|
3220
3238
|
)}
|
|
3221
3239
|
<figure>
|
|
3222
3240
|
<!-- Content for each tab -->
|
|
3223
|
-
${
|
|
3241
|
+
${Ie(
|
|
3224
3242
|
n,
|
|
3225
|
-
(r, s) =>
|
|
3226
|
-
${
|
|
3227
|
-
this.
|
|
3228
|
-
() =>
|
|
3243
|
+
(r, s) => x`
|
|
3244
|
+
${G(
|
|
3245
|
+
this.toolsAsList,
|
|
3246
|
+
() => x`
|
|
3229
3247
|
<label class="listed">
|
|
3230
3248
|
<!-- Customizable icon for each tab -->
|
|
3231
3249
|
<slot name=${`${r}-icon`}>${r}</slot>
|
|
3232
3250
|
</label>
|
|
3233
3251
|
`
|
|
3234
3252
|
)}
|
|
3235
|
-
<div class="tab ${P(this,
|
|
3253
|
+
<div class="tab ${P(this, ve).call(this, s)}">
|
|
3236
3254
|
<!-- Content slot for each tab -->
|
|
3237
3255
|
<slot name=${`${r}-content`}>${r}</slot>
|
|
3238
3256
|
</div>
|
|
@@ -3243,17 +3261,17 @@ class bo extends tt {
|
|
|
3243
3261
|
`;
|
|
3244
3262
|
}
|
|
3245
3263
|
}
|
|
3246
|
-
|
|
3247
|
-
|
|
3264
|
+
ve = new WeakMap(), Ge = new WeakMap(), Je = new WeakMap(), // Define static properties for the component
|
|
3265
|
+
L($o, "properties", {
|
|
3248
3266
|
actions: { attribute: !1 },
|
|
3249
3267
|
selectedTab: { state: !0 },
|
|
3250
3268
|
tabs: { attribute: !1 },
|
|
3251
3269
|
unstyled: { type: Boolean },
|
|
3252
3270
|
noShadow: { type: Boolean },
|
|
3253
|
-
|
|
3271
|
+
toolsAsList: { type: Boolean }
|
|
3254
3272
|
});
|
|
3255
|
-
customElements.define("eox-layercontrol-tools-items",
|
|
3256
|
-
const
|
|
3273
|
+
customElements.define("eox-layercontrol-tools-items", $o);
|
|
3274
|
+
const da = `
|
|
3257
3275
|
button,
|
|
3258
3276
|
.button {
|
|
3259
3277
|
/* TODO: why does this only work here and not from :root? */
|
|
@@ -3377,7 +3395,7 @@ button.smallest.icon::before {
|
|
|
3377
3395
|
width: 16px;
|
|
3378
3396
|
padding: 0px;
|
|
3379
3397
|
}
|
|
3380
|
-
`,
|
|
3398
|
+
`, ca = `
|
|
3381
3399
|
input[type=radio] {
|
|
3382
3400
|
appearance: none;
|
|
3383
3401
|
-webkit-appearance: none;
|
|
@@ -3405,7 +3423,7 @@ input[type=radio]:checked:after {
|
|
|
3405
3423
|
content: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='%23004170' viewBox='0 0 24 24'%3E%3Ctitle%3Eradiobox-marked%3C/title%3E%3Cpath d='M12,20A8,8 0 0,1 4,12A8,8 0 0,1 12,4A8,8 0 0,1 20,12A8,8 0 0,1 12,20M12,2A10,10 0 0,0 2,12A10,10 0 0,0 12,22A10,10 0 0,0 22,12A10,10 0 0,0 12,2M12,7A5,5 0 0,0 7,12A5,5 0 0,0 12,17A5,5 0 0,0 17,12A5,5 0 0,0 12,7Z' /%3E%3C/svg%3E");
|
|
3406
3424
|
|
|
3407
3425
|
}
|
|
3408
|
-
`,
|
|
3426
|
+
`, Ao = `
|
|
3409
3427
|
input[type=checkbox] {
|
|
3410
3428
|
appearance: none;
|
|
3411
3429
|
-webkit-appearance: none;
|
|
@@ -3428,7 +3446,7 @@ input[type=checkbox]:checked:after {
|
|
|
3428
3446
|
content: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='%23004170' viewBox='0 0 24 24'%3E%3Ctitle%3Echeckbox-marked%3C/title%3E%3Cpath d='M10,17L5,12L6.41,10.58L10,14.17L17.59,6.58L19,8M19,3H5C3.89,3 3,3.89 3,5V19A2,2 0 0,0 5,21H19A2,2 0 0,0 21,19V5C21,3.89 20.1,3 19,3Z' /%3E%3C/svg%3E");
|
|
3429
3447
|
|
|
3430
3448
|
}
|
|
3431
|
-
`,
|
|
3449
|
+
`, ha = `
|
|
3432
3450
|
input[type="range"] {
|
|
3433
3451
|
-webkit-appearance: none;
|
|
3434
3452
|
width: 90%;
|
|
@@ -3506,14 +3524,14 @@ input::-moz-focus-inner, input::-moz-focus-outer {
|
|
|
3506
3524
|
border: 0;
|
|
3507
3525
|
}
|
|
3508
3526
|
`;
|
|
3509
|
-
var
|
|
3510
|
-
class
|
|
3527
|
+
var Ke, Qe;
|
|
3528
|
+
class _o extends it {
|
|
3511
3529
|
constructor() {
|
|
3512
3530
|
super();
|
|
3513
3531
|
// Initializes '_removeButton' invoking 'removeButton' function with 'this' context.
|
|
3514
|
-
|
|
3532
|
+
L(this, "_removeButton", () => ks(this));
|
|
3515
3533
|
// Initializes '_sortButton' invoking 'sortButton' function with 'unstyled' property as a parameter.
|
|
3516
|
-
|
|
3534
|
+
L(this, "_sortButton", () => Us(this.unstyled));
|
|
3517
3535
|
/**
|
|
3518
3536
|
* Initializes '_button' as a function accepting 'tool' parameter to generate a Button.
|
|
3519
3537
|
* Uses 'this.unstyled' as a context parameter for Button generation.
|
|
@@ -3521,18 +3539,18 @@ class wo extends tt {
|
|
|
3521
3539
|
* @param {string} tool - Tool parameter for Button generation.
|
|
3522
3540
|
* @returns {import("lit").HTMLTemplateResult} - The generated Button element.
|
|
3523
3541
|
*/
|
|
3524
|
-
|
|
3525
|
-
|
|
3542
|
+
L(this, "_button", (n) => Vs(n, this.unstyled));
|
|
3543
|
+
L(this, "_getDefaultTools", () => {
|
|
3526
3544
|
var n;
|
|
3527
|
-
return
|
|
3545
|
+
return x`
|
|
3528
3546
|
<div slot="info-content">
|
|
3529
|
-
${
|
|
3547
|
+
${Fs(this.layer.get("description"))}
|
|
3530
3548
|
</div>
|
|
3531
3549
|
<div slot="datetime-content">
|
|
3532
3550
|
<!-- Layer datetime -->
|
|
3533
|
-
${
|
|
3551
|
+
${G(
|
|
3534
3552
|
this.layer.get("layerDatetime"),
|
|
3535
|
-
() =>
|
|
3553
|
+
() => x`
|
|
3536
3554
|
<eox-layercontrol-layer-datetime
|
|
3537
3555
|
slot="datetime-content"
|
|
3538
3556
|
.noShadow=${!0}
|
|
@@ -3551,15 +3569,15 @@ class wo extends tt {
|
|
|
3551
3569
|
min="0"
|
|
3552
3570
|
max="1"
|
|
3553
3571
|
step="0.01"
|
|
3554
|
-
value=${
|
|
3572
|
+
value=${yo((n = this.layer) == null ? void 0 : n.getOpacity())}
|
|
3555
3573
|
@input=${(i) => this.layer.setOpacity(parseFloat(i.target.value))}
|
|
3556
3574
|
/>
|
|
3557
3575
|
</div>
|
|
3558
3576
|
<div slot="config-content">
|
|
3559
3577
|
<!-- Layer configuration -->
|
|
3560
|
-
${
|
|
3578
|
+
${G(
|
|
3561
3579
|
this.layer.get("layerConfig"),
|
|
3562
|
-
() =>
|
|
3580
|
+
() => x`
|
|
3563
3581
|
<eox-layercontrol-layerconfig
|
|
3564
3582
|
slot="config-content"
|
|
3565
3583
|
.layer=${this.layer}
|
|
@@ -3575,12 +3593,12 @@ class wo extends tt {
|
|
|
3575
3593
|
<div slot="sort-icon">${this._sortButton()}</div>
|
|
3576
3594
|
`;
|
|
3577
3595
|
});
|
|
3578
|
-
T(this,
|
|
3579
|
-
T(this,
|
|
3580
|
-
${
|
|
3581
|
-
${
|
|
3582
|
-
${
|
|
3583
|
-
${
|
|
3596
|
+
T(this, Ke, "");
|
|
3597
|
+
T(this, Qe, `
|
|
3598
|
+
${da}
|
|
3599
|
+
${ca}
|
|
3600
|
+
${Ao}
|
|
3601
|
+
${ha}
|
|
3584
3602
|
.drag-handle {
|
|
3585
3603
|
cursor: n-resize;
|
|
3586
3604
|
}
|
|
@@ -3643,6 +3661,7 @@ class wo extends tt {
|
|
|
3643
3661
|
details.tools summary .icon::before {
|
|
3644
3662
|
height: 16px;
|
|
3645
3663
|
width: 16px;
|
|
3664
|
+
margin-right: var(--padding);
|
|
3646
3665
|
}
|
|
3647
3666
|
eox-layercontrol-tools-items button.icon,
|
|
3648
3667
|
eox-layercontrol-tools-items .button.icon {
|
|
@@ -3683,7 +3702,7 @@ class wo extends tt {
|
|
|
3683
3702
|
padding: 12px 6px;
|
|
3684
3703
|
}
|
|
3685
3704
|
`);
|
|
3686
|
-
this.layer = null, this.tools = [], this.unstyled = !1, this.noShadow = !1, this.
|
|
3705
|
+
this.layer = null, this.tools = [], this.unstyled = !1, this.noShadow = !1, this.toolsAsList = !1;
|
|
3687
3706
|
}
|
|
3688
3707
|
/**
|
|
3689
3708
|
* Overrides createRenderRoot to handle shadow DOM creation based on the noShadow property.
|
|
@@ -3693,26 +3712,26 @@ class wo extends tt {
|
|
|
3693
3712
|
}
|
|
3694
3713
|
render() {
|
|
3695
3714
|
var l;
|
|
3696
|
-
const n =
|
|
3715
|
+
const n = Ls(this.tools, this.layer), i = Bs(this.tools, this.layer), o = this[`_${n == null ? void 0 : n[0]}Button`] ? (
|
|
3697
3716
|
// @ts-ignore
|
|
3698
3717
|
this[`_${n == null ? void 0 : n[0]}Button`]()
|
|
3699
3718
|
) : C, r = ((l = this.tools) == null ? void 0 : l.length) === 1 ? `${this.tools[0]}-icon` : "", s = n == null ? void 0 : n.length, a = i == null ? void 0 : i.length;
|
|
3700
|
-
return
|
|
3719
|
+
return x`
|
|
3701
3720
|
<style>
|
|
3702
|
-
${P(this,
|
|
3703
|
-
${!this.unstyled && P(this,
|
|
3721
|
+
${P(this, Ke)}
|
|
3722
|
+
${!this.unstyled && P(this, Qe)}
|
|
3704
3723
|
</style>
|
|
3705
|
-
${
|
|
3724
|
+
${G(
|
|
3706
3725
|
s + a > 0,
|
|
3707
|
-
() =>
|
|
3708
|
-
${
|
|
3726
|
+
() => x`
|
|
3727
|
+
${G(
|
|
3709
3728
|
s === 1 && a === 0,
|
|
3710
|
-
() =>
|
|
3729
|
+
() => x`
|
|
3711
3730
|
<div class="single-action-container">
|
|
3712
3731
|
<div class="single-action">${o}</div>
|
|
3713
3732
|
</div>
|
|
3714
3733
|
`,
|
|
3715
|
-
() =>
|
|
3734
|
+
() => x`
|
|
3716
3735
|
<details
|
|
3717
3736
|
class="tools"
|
|
3718
3737
|
open=${this.layer.get("layerControlToolsExpand") || C}
|
|
@@ -3721,15 +3740,15 @@ class wo extends tt {
|
|
|
3721
3740
|
<button class="icon ${r}">Tools</button>
|
|
3722
3741
|
</summary>
|
|
3723
3742
|
<eox-layercontrol-tools-items
|
|
3724
|
-
class="${this.
|
|
3743
|
+
class="${this.toolsAsList ? "tools-list" : "tools-tab"}"
|
|
3725
3744
|
.noShadow=${!1}
|
|
3726
3745
|
.actions=${n}
|
|
3727
3746
|
.tabs=${i}
|
|
3728
3747
|
.unstyled=${this.unstyled}
|
|
3729
|
-
.
|
|
3748
|
+
.toolsAsList=${this.toolsAsList}
|
|
3730
3749
|
>
|
|
3731
3750
|
<!-- Rendering tabs and content -->
|
|
3732
|
-
${
|
|
3751
|
+
${Ie(i, (u) => this._button(u))}
|
|
3733
3752
|
<!-- Including default tools -->
|
|
3734
3753
|
${this._getDefaultTools()}
|
|
3735
3754
|
</eox-layercontrol-tools-items>
|
|
@@ -3741,21 +3760,21 @@ class wo extends tt {
|
|
|
3741
3760
|
`;
|
|
3742
3761
|
}
|
|
3743
3762
|
}
|
|
3744
|
-
|
|
3745
|
-
|
|
3763
|
+
Ke = new WeakMap(), Qe = new WeakMap(), // Define static properties for the component
|
|
3764
|
+
L(_o, "properties", {
|
|
3746
3765
|
layer: { attribute: !1 },
|
|
3747
3766
|
tools: { attribute: !1 },
|
|
3748
3767
|
unstyled: { type: Boolean },
|
|
3749
3768
|
noShadow: { type: Boolean },
|
|
3750
|
-
|
|
3769
|
+
toolsAsList: { type: Boolean }
|
|
3751
3770
|
});
|
|
3752
3771
|
customElements.define(
|
|
3753
3772
|
"eox-layercontrol-layer-tools",
|
|
3754
|
-
|
|
3773
|
+
_o
|
|
3755
3774
|
);
|
|
3756
|
-
const
|
|
3775
|
+
const pa = (e) => {
|
|
3757
3776
|
const t = () => {
|
|
3758
|
-
const n =
|
|
3777
|
+
const n = Is(
|
|
3759
3778
|
e.layer,
|
|
3760
3779
|
e.map,
|
|
3761
3780
|
e.showLayerZoomState
|
|
@@ -3765,11 +3784,11 @@ const la = (e) => {
|
|
|
3765
3784
|
new CustomEvent("change:resolution", { bubbles: !0 })
|
|
3766
3785
|
));
|
|
3767
3786
|
};
|
|
3768
|
-
|
|
3787
|
+
fo(
|
|
3769
3788
|
e.layer,
|
|
3770
3789
|
e.showLayerZoomState
|
|
3771
3790
|
) && (t(), e.map.getView().on("change:resolution", () => t()));
|
|
3772
|
-
},
|
|
3791
|
+
}, fa = (e, t) => {
|
|
3773
3792
|
const n = t.layer;
|
|
3774
3793
|
n.setVisible(e.target.checked), e.target.checked && n.get("layerControlExclusive") && t.closest(
|
|
3775
3794
|
".layers > ul"
|
|
@@ -3780,20 +3799,20 @@ const la = (e) => {
|
|
|
3780
3799
|
new CustomEvent("changed", { bubbles: !0, detail: n })
|
|
3781
3800
|
), t.requestUpdate();
|
|
3782
3801
|
};
|
|
3783
|
-
var
|
|
3784
|
-
class
|
|
3802
|
+
var Tt, Ne, To, tn, en;
|
|
3803
|
+
class Co extends it {
|
|
3785
3804
|
constructor() {
|
|
3786
3805
|
super();
|
|
3787
|
-
T(this,
|
|
3806
|
+
T(this, Tt);
|
|
3788
3807
|
/**
|
|
3789
3808
|
* Represents the current layer visibility based on zoom level.
|
|
3790
3809
|
*
|
|
3791
3810
|
* @type {Boolean}
|
|
3792
3811
|
*/
|
|
3793
|
-
|
|
3794
|
-
T(this,
|
|
3795
|
-
T(this,
|
|
3796
|
-
${
|
|
3812
|
+
L(this, "currLayerVisibilityBasedOnZoom", !0);
|
|
3813
|
+
T(this, tn, "");
|
|
3814
|
+
T(this, en, `
|
|
3815
|
+
${Ao}
|
|
3797
3816
|
eox-layercontrol-layer {
|
|
3798
3817
|
width: 100%;
|
|
3799
3818
|
}
|
|
@@ -3834,7 +3853,7 @@ class Eo extends tt {
|
|
|
3834
3853
|
content: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='%230041703a' viewBox='0 0 24 24'%3E%3Ctitle%3Evector-square-edit%3C/title%3E%3Cpath d='M22.7 14.4L21.7 15.4L19.6 13.3L20.6 12.3C20.8 12.1 21.2 12.1 21.4 12.3L22.7 13.6C22.9 13.8 22.9 14.1 22.7 14.4M13 19.9L19.1 13.8L21.2 15.9L15.1 22H13V19.9M11 19.9V19.1L11.6 18.5L12.1 18H8V16H6V8H8V6H16V8H18V12.1L19.1 11L19.3 10.8C19.5 10.6 19.8 10.4 20.1 10.3V8H22.1V2H16.1V4H8V2H2V8H4V16H2V22H8V20L11 19.9M18 4H20V6H18V4M4 4H6V6H4V4M6 20H4V18H6V20Z' /%3E%3C/svg%3E");
|
|
3835
3854
|
}
|
|
3836
3855
|
`);
|
|
3837
|
-
this.layer = null, this.map = null, this.titleProperty = "title", this.showLayerZoomState = !1, this.tools = [], this.unstyled = !1, this.noShadow = !1, this.
|
|
3856
|
+
this.layer = null, this.map = null, this.titleProperty = "title", this.showLayerZoomState = !1, this.tools = [], this.unstyled = !1, this.noShadow = !1, this.toolsAsList = !1;
|
|
3838
3857
|
}
|
|
3839
3858
|
/**
|
|
3840
3859
|
* Overrides createRenderRoot to handle shadow DOM creation based on the noShadow property.
|
|
@@ -3847,7 +3866,7 @@ class Eo extends tt {
|
|
|
3847
3866
|
* and register "change:resolution" ones at the beginning if `showLayerZoomState` is present
|
|
3848
3867
|
*/
|
|
3849
3868
|
firstUpdated() {
|
|
3850
|
-
|
|
3869
|
+
pa(this);
|
|
3851
3870
|
}
|
|
3852
3871
|
/**
|
|
3853
3872
|
* Renders layer controls and tools with conditional display based on certain properties.
|
|
@@ -3856,30 +3875,30 @@ class Eo extends tt {
|
|
|
3856
3875
|
*/
|
|
3857
3876
|
render() {
|
|
3858
3877
|
var l;
|
|
3859
|
-
const n = this.layer.getVisible(), i = n ? "visible" : "", o = this.currLayerVisibilityBasedOnZoom ? "" : "zoom-state-invisible", r = B(this,
|
|
3860
|
-
return
|
|
3878
|
+
const n = this.layer.getVisible(), i = n ? "visible" : "", o = this.currLayerVisibilityBasedOnZoom ? "" : "zoom-state-invisible", r = B(this, Tt, Ne).call(this, "layerControlDisable") ? "disabled" : "", s = B(this, Tt, Ne).call(this, "layerControlExclusive") ? "radio" : "checkbox", a = ((l = this.tools) == null ? void 0 : l.length) > 0;
|
|
3879
|
+
return x`
|
|
3861
3880
|
<style>
|
|
3862
|
-
${P(this,
|
|
3863
|
-
${!this.unstyled && P(this,
|
|
3881
|
+
${P(this, tn)}
|
|
3882
|
+
${!this.unstyled && P(this, en)}
|
|
3864
3883
|
</style>
|
|
3865
|
-
${
|
|
3884
|
+
${G(
|
|
3866
3885
|
this.layer,
|
|
3867
|
-
() =>
|
|
3886
|
+
() => x`
|
|
3868
3887
|
<!-- Render the layer -->
|
|
3869
3888
|
<div class="layer ${i} ${o}">
|
|
3870
3889
|
<label class="drag-handle ${r}">
|
|
3871
3890
|
<!-- Input element for layer visibility -->
|
|
3872
3891
|
<input
|
|
3873
3892
|
type=${s}
|
|
3874
|
-
.checked=${
|
|
3875
|
-
@click=${B(this,
|
|
3893
|
+
.checked=${yo(n)}
|
|
3894
|
+
@click=${B(this, Tt, To)}
|
|
3876
3895
|
/>
|
|
3877
3896
|
|
|
3878
3897
|
<!-- Layer title -->
|
|
3879
|
-
<span class="title">${B(this,
|
|
3880
|
-
${
|
|
3898
|
+
<span class="title">${B(this, Tt, Ne).call(this, this.titleProperty)}</span>
|
|
3899
|
+
${G(
|
|
3881
3900
|
a,
|
|
3882
|
-
() =>
|
|
3901
|
+
() => x`<span class="tools-placeholder"></span>`
|
|
3883
3902
|
)}
|
|
3884
3903
|
</label>
|
|
3885
3904
|
</div>
|
|
@@ -3890,14 +3909,14 @@ class Eo extends tt {
|
|
|
3890
3909
|
.layer=${this.layer}
|
|
3891
3910
|
.tools=${this.tools}
|
|
3892
3911
|
.unstyled=${this.unstyled}
|
|
3893
|
-
.
|
|
3912
|
+
.toolsAsList=${this.toolsAsList}
|
|
3894
3913
|
></eox-layercontrol-layer-tools>
|
|
3895
3914
|
`
|
|
3896
3915
|
)}
|
|
3897
3916
|
`;
|
|
3898
3917
|
}
|
|
3899
3918
|
}
|
|
3900
|
-
|
|
3919
|
+
Tt = new WeakSet(), /**
|
|
3901
3920
|
* Private method to get layer property by key if available.
|
|
3902
3921
|
*
|
|
3903
3922
|
* @param {string} key - The key for the layer property.
|
|
@@ -3911,10 +3930,10 @@ Ne = function(n) {
|
|
|
3911
3930
|
*
|
|
3912
3931
|
* @param {{target: { checked: boolean }}} evt - The input change event.
|
|
3913
3932
|
*/
|
|
3914
|
-
|
|
3915
|
-
|
|
3916
|
-
},
|
|
3917
|
-
|
|
3933
|
+
To = function(n) {
|
|
3934
|
+
fa(n, this);
|
|
3935
|
+
}, tn = new WeakMap(), en = new WeakMap(), // Define static properties for the component
|
|
3936
|
+
L(Co, "properties", {
|
|
3918
3937
|
layer: { attribute: !1 },
|
|
3919
3938
|
map: { attribute: !1, state: !0 },
|
|
3920
3939
|
titleProperty: { attribute: "title-property", type: String },
|
|
@@ -3922,15 +3941,15 @@ N(Eo, "properties", {
|
|
|
3922
3941
|
tools: { attribute: !1 },
|
|
3923
3942
|
unstyled: { type: Boolean },
|
|
3924
3943
|
noShadow: { type: Boolean },
|
|
3925
|
-
|
|
3944
|
+
toolsAsList: { type: Boolean }
|
|
3926
3945
|
});
|
|
3927
|
-
customElements.define("eox-layercontrol-layer",
|
|
3928
|
-
var
|
|
3929
|
-
class
|
|
3946
|
+
customElements.define("eox-layercontrol-layer", Co);
|
|
3947
|
+
var nn, on;
|
|
3948
|
+
class Po extends it {
|
|
3930
3949
|
constructor() {
|
|
3931
3950
|
super();
|
|
3932
|
-
T(this,
|
|
3933
|
-
T(this,
|
|
3951
|
+
T(this, nn, "");
|
|
3952
|
+
T(this, on, `
|
|
3934
3953
|
details summary {
|
|
3935
3954
|
cursor: pointer;
|
|
3936
3955
|
display: flex;
|
|
@@ -3955,7 +3974,7 @@ class So extends tt {
|
|
|
3955
3974
|
display: none;
|
|
3956
3975
|
}
|
|
3957
3976
|
`);
|
|
3958
|
-
this.group = null, this.idProperty = "id", this.map = null, this.titleProperty = "title", this.showLayerZoomState = !1, this.tools = [], this.unstyled = !1, this.noShadow = !1, this.
|
|
3977
|
+
this.group = null, this.idProperty = "id", this.map = null, this.titleProperty = "title", this.showLayerZoomState = !1, this.tools = [], this.unstyled = !1, this.noShadow = !1, this.toolsAsList = !1;
|
|
3959
3978
|
}
|
|
3960
3979
|
/**
|
|
3961
3980
|
* Overrides the default behavior of creating the render root element.
|
|
@@ -3970,17 +3989,17 @@ class So extends tt {
|
|
|
3970
3989
|
*/
|
|
3971
3990
|
render() {
|
|
3972
3991
|
var o, r;
|
|
3973
|
-
const n = !!((o = this.group) != null && o.get("layerControlExpand")), i = (r =
|
|
3992
|
+
const n = !!((o = this.group) != null && o.get("layerControlExpand")), i = (r = mo(
|
|
3974
3993
|
this.group.getLayers()
|
|
3975
3994
|
)) == null ? void 0 : r.length;
|
|
3976
|
-
return
|
|
3995
|
+
return x`
|
|
3977
3996
|
<style>
|
|
3978
|
-
${P(this,
|
|
3979
|
-
${!this.unstyled && P(this,
|
|
3997
|
+
${P(this, nn)}
|
|
3998
|
+
${!this.unstyled && P(this, on)}
|
|
3980
3999
|
</style>
|
|
3981
|
-
${
|
|
4000
|
+
${G(
|
|
3982
4001
|
this.group,
|
|
3983
|
-
() =>
|
|
4002
|
+
() => x`
|
|
3984
4003
|
<!-- Render the details element with the layer control -->
|
|
3985
4004
|
<details
|
|
3986
4005
|
open=${n || C}
|
|
@@ -3996,7 +4015,7 @@ class So extends tt {
|
|
|
3996
4015
|
.showLayerZoomState=${this.showLayerZoomState}
|
|
3997
4016
|
.tools=${this.tools}
|
|
3998
4017
|
.unstyled=${this.unstyled}
|
|
3999
|
-
.
|
|
4018
|
+
.toolsAsList=${this.toolsAsList}
|
|
4000
4019
|
@changed=${() => this.requestUpdate()}
|
|
4001
4020
|
></eox-layercontrol-layer>
|
|
4002
4021
|
</summary>
|
|
@@ -4011,7 +4030,7 @@ class So extends tt {
|
|
|
4011
4030
|
.showLayerZoomState=${this.showLayerZoomState}
|
|
4012
4031
|
.tools=${this.tools}
|
|
4013
4032
|
.unstyled=${this.unstyled}
|
|
4014
|
-
.
|
|
4033
|
+
.toolsAsList=${this.toolsAsList}
|
|
4015
4034
|
@changed=${() => this.requestUpdate()}
|
|
4016
4035
|
></eox-layercontrol-layer-list>
|
|
4017
4036
|
</details>
|
|
@@ -4020,8 +4039,8 @@ class So extends tt {
|
|
|
4020
4039
|
`;
|
|
4021
4040
|
}
|
|
4022
4041
|
}
|
|
4023
|
-
|
|
4024
|
-
|
|
4042
|
+
nn = new WeakMap(), on = new WeakMap(), // Define static properties for the component
|
|
4043
|
+
L(Po, "properties", {
|
|
4025
4044
|
group: { attribute: !1 },
|
|
4026
4045
|
idProperty: { attribute: "id-property" },
|
|
4027
4046
|
map: { attribute: !1, state: !0 },
|
|
@@ -4030,34 +4049,110 @@ N(So, "properties", {
|
|
|
4030
4049
|
tools: { attribute: !1 },
|
|
4031
4050
|
unstyled: { type: Boolean },
|
|
4032
4051
|
noShadow: { type: Boolean },
|
|
4033
|
-
|
|
4052
|
+
toolsAsList: { type: Boolean }
|
|
4034
4053
|
});
|
|
4035
4054
|
customElements.define(
|
|
4036
4055
|
"eox-layercontrol-layer-group",
|
|
4037
|
-
|
|
4056
|
+
Po
|
|
4038
4057
|
);
|
|
4039
|
-
|
|
4040
|
-
|
|
4058
|
+
var ga = "Expected a function", _i = NaN, ma = "[object Symbol]", ya = /^\s+|\s+$/g, ba = /^[-+]0x[0-9a-f]+$/i, va = /^0b[01]+$/i, wa = /^0o[0-7]+$/i, Ea = parseInt, xa = typeof _t == "object" && _t && _t.Object === Object && _t, Sa = typeof self == "object" && self && self.Object === Object && self, $a = xa || Sa || Function("return this")(), Aa = Object.prototype, _a = Aa.toString, Ca = Math.max, Ta = Math.min, Rn = function() {
|
|
4059
|
+
return $a.Date.now();
|
|
4060
|
+
};
|
|
4061
|
+
function Pa(e, t, n) {
|
|
4062
|
+
var i, o, r, s, a, l, u = 0, c = !1, d = !1, p = !0;
|
|
4063
|
+
if (typeof e != "function")
|
|
4064
|
+
throw new TypeError(ga);
|
|
4065
|
+
t = Ci(t) || 0, kn(n) && (c = !!n.leading, d = "maxWait" in n, r = d ? Ca(Ci(n.maxWait) || 0, t) : r, p = "trailing" in n ? !!n.trailing : p);
|
|
4066
|
+
function f(b) {
|
|
4067
|
+
var D = i, Z = o;
|
|
4068
|
+
return i = o = void 0, u = b, s = e.apply(Z, D), s;
|
|
4069
|
+
}
|
|
4070
|
+
function g(b) {
|
|
4071
|
+
return u = b, a = setTimeout(I, t), c ? f(b) : s;
|
|
4072
|
+
}
|
|
4073
|
+
function y(b) {
|
|
4074
|
+
var D = b - l, Z = b - u, U = t - D;
|
|
4075
|
+
return d ? Ta(U, r - Z) : U;
|
|
4076
|
+
}
|
|
4077
|
+
function O(b) {
|
|
4078
|
+
var D = b - l, Z = b - u;
|
|
4079
|
+
return l === void 0 || D >= t || D < 0 || d && Z >= r;
|
|
4080
|
+
}
|
|
4081
|
+
function I() {
|
|
4082
|
+
var b = Rn();
|
|
4083
|
+
if (O(b))
|
|
4084
|
+
return H(b);
|
|
4085
|
+
a = setTimeout(I, y(b));
|
|
4086
|
+
}
|
|
4087
|
+
function H(b) {
|
|
4088
|
+
return a = void 0, p && i ? f(b) : (i = o = void 0, s);
|
|
4089
|
+
}
|
|
4090
|
+
function J() {
|
|
4091
|
+
a !== void 0 && clearTimeout(a), u = 0, i = l = o = a = void 0;
|
|
4092
|
+
}
|
|
4093
|
+
function j() {
|
|
4094
|
+
return a === void 0 ? s : H(Rn());
|
|
4095
|
+
}
|
|
4096
|
+
function K() {
|
|
4097
|
+
var b = Rn(), D = O(b);
|
|
4098
|
+
if (i = arguments, o = this, l = b, D) {
|
|
4099
|
+
if (a === void 0)
|
|
4100
|
+
return g(l);
|
|
4101
|
+
if (d)
|
|
4102
|
+
return a = setTimeout(I, t), f(l);
|
|
4103
|
+
}
|
|
4104
|
+
return a === void 0 && (a = setTimeout(I, t)), s;
|
|
4105
|
+
}
|
|
4106
|
+
return K.cancel = J, K.flush = j, K;
|
|
4107
|
+
}
|
|
4108
|
+
function kn(e) {
|
|
4109
|
+
var t = typeof e;
|
|
4110
|
+
return !!e && (t == "object" || t == "function");
|
|
4111
|
+
}
|
|
4112
|
+
function Oa(e) {
|
|
4113
|
+
return !!e && typeof e == "object";
|
|
4114
|
+
}
|
|
4115
|
+
function Da(e) {
|
|
4116
|
+
return typeof e == "symbol" || Oa(e) && _a.call(e) == ma;
|
|
4117
|
+
}
|
|
4118
|
+
function Ci(e) {
|
|
4119
|
+
if (typeof e == "number")
|
|
4120
|
+
return e;
|
|
4121
|
+
if (Da(e))
|
|
4122
|
+
return _i;
|
|
4123
|
+
if (kn(e)) {
|
|
4124
|
+
var t = typeof e.valueOf == "function" ? e.valueOf() : e;
|
|
4125
|
+
e = kn(t) ? t + "" : t;
|
|
4126
|
+
}
|
|
4127
|
+
if (typeof e != "string")
|
|
4128
|
+
return e === 0 ? e : +e;
|
|
4129
|
+
e = e.replace(ya, "");
|
|
4130
|
+
var n = va.test(e);
|
|
4131
|
+
return n || wa.test(e) ? Ea(e.slice(2), n ? 2 : 8) : ba.test(e) ? _i : +e;
|
|
4132
|
+
}
|
|
4133
|
+
var Ra = Pa;
|
|
4134
|
+
const Ma = /* @__PURE__ */ vo(Ra), Ia = (e) => {
|
|
4135
|
+
const { layers: t, idProperty: n, titleProperty: i, renderRoot: o } = e, r = Ma(() => {
|
|
4041
4136
|
e.requestUpdate(), e.dispatchEvent(
|
|
4042
4137
|
new CustomEvent("changed", { bubbles: !0 })
|
|
4043
4138
|
);
|
|
4044
4139
|
}, 50), s = () => r();
|
|
4045
4140
|
if (t && (t.hasListener("change:length") && (t == null || t.un("change:length", s)), t.on("change:length", s), t)) {
|
|
4046
4141
|
const a = o.querySelector("ul");
|
|
4047
|
-
|
|
4142
|
+
Ms(
|
|
4048
4143
|
t,
|
|
4049
4144
|
n,
|
|
4050
4145
|
i,
|
|
4051
4146
|
e
|
|
4052
|
-
),
|
|
4147
|
+
), Rs(a, t, n, e);
|
|
4053
4148
|
}
|
|
4054
4149
|
};
|
|
4055
|
-
var
|
|
4056
|
-
class
|
|
4150
|
+
var rn, sn;
|
|
4151
|
+
class Oo extends it {
|
|
4057
4152
|
constructor() {
|
|
4058
4153
|
super();
|
|
4059
|
-
T(this,
|
|
4060
|
-
T(this,
|
|
4154
|
+
T(this, rn, "");
|
|
4155
|
+
T(this, sn, `
|
|
4061
4156
|
ul {
|
|
4062
4157
|
padding: 0;
|
|
4063
4158
|
margin: 0;
|
|
@@ -4067,13 +4162,11 @@ class $o extends tt {
|
|
|
4067
4162
|
}
|
|
4068
4163
|
li {
|
|
4069
4164
|
list-style: none;
|
|
4165
|
+
padding-left: var(--padding);
|
|
4070
4166
|
}
|
|
4071
4167
|
li {
|
|
4072
4168
|
border-bottom: 1px solid #0041703a;
|
|
4073
4169
|
}
|
|
4074
|
-
li:first-child {
|
|
4075
|
-
border-top: 1px solid #0041703a;
|
|
4076
|
-
}
|
|
4077
4170
|
li:last-child {
|
|
4078
4171
|
border: none;
|
|
4079
4172
|
}
|
|
@@ -4086,13 +4179,13 @@ class $o extends tt {
|
|
|
4086
4179
|
li.sortable-ghost {
|
|
4087
4180
|
}
|
|
4088
4181
|
`);
|
|
4089
|
-
this.idProperty = "id", this.layers = null, this.map = null, this.tools = void 0, this.titleProperty = "title", this.showLayerZoomState = !1, this.unstyled = !1, this.noShadow = !1, this.
|
|
4182
|
+
this.idProperty = "id", this.layers = null, this.map = null, this.tools = void 0, this.titleProperty = "title", this.showLayerZoomState = !1, this.unstyled = !1, this.noShadow = !1, this.toolsAsList = !1;
|
|
4090
4183
|
}
|
|
4091
4184
|
/**
|
|
4092
4185
|
* Executes specific logic after the initial render of the component.
|
|
4093
4186
|
*/
|
|
4094
4187
|
firstUpdated() {
|
|
4095
|
-
|
|
4188
|
+
Ia(this);
|
|
4096
4189
|
}
|
|
4097
4190
|
/**
|
|
4098
4191
|
* Overrides createRenderRoot to handle shadow DOM creation based on the noShadow property.
|
|
@@ -4105,27 +4198,27 @@ class $o extends tt {
|
|
|
4105
4198
|
* layer groups or individual layers accordingly. Utilizes conditional rendering and iterates through available layers.
|
|
4106
4199
|
*/
|
|
4107
4200
|
render() {
|
|
4108
|
-
const n = this.layers ?
|
|
4109
|
-
return
|
|
4201
|
+
const n = this.layers ? mo(this.layers).reverse() : [];
|
|
4202
|
+
return x`
|
|
4110
4203
|
<style>
|
|
4111
|
-
${P(this,
|
|
4112
|
-
${!this.unstyled && P(this,
|
|
4204
|
+
${P(this, rn)}
|
|
4205
|
+
${!this.unstyled && P(this, sn)}
|
|
4113
4206
|
</style>
|
|
4114
4207
|
<ul>
|
|
4115
|
-
${
|
|
4208
|
+
${G(
|
|
4116
4209
|
this.layers,
|
|
4117
|
-
() =>
|
|
4118
|
-
${
|
|
4210
|
+
() => x`
|
|
4211
|
+
${ur(
|
|
4119
4212
|
n,
|
|
4120
4213
|
(i) => i,
|
|
4121
|
-
(i) =>
|
|
4214
|
+
(i) => x`
|
|
4122
4215
|
<li
|
|
4123
4216
|
data-layer="${i.get(this.idProperty)}"
|
|
4124
|
-
data-type="${
|
|
4217
|
+
data-type="${Ns(i, this.map)}"
|
|
4125
4218
|
>
|
|
4126
4219
|
${/** Checks if the layer is a group or individual layer and renders accordingly */
|
|
4127
4220
|
/** @type {import("ol/layer").Group} */
|
|
4128
|
-
i.getLayers ?
|
|
4221
|
+
i.getLayers ? x`
|
|
4129
4222
|
<eox-layercontrol-layer-group
|
|
4130
4223
|
.noShadow=${!0}
|
|
4131
4224
|
.group=${i}
|
|
@@ -4135,11 +4228,11 @@ class $o extends tt {
|
|
|
4135
4228
|
.showLayerZoomState=${this.showLayerZoomState}
|
|
4136
4229
|
.tools=${this.tools}
|
|
4137
4230
|
.unstyled=${this.unstyled}
|
|
4138
|
-
.
|
|
4231
|
+
.toolsAsList=${this.toolsAsList}
|
|
4139
4232
|
@changed=${() => this.requestUpdate()}
|
|
4140
4233
|
>
|
|
4141
4234
|
</eox-layercontrol-layer-group>
|
|
4142
|
-
` :
|
|
4235
|
+
` : x`
|
|
4143
4236
|
<eox-layercontrol-layer
|
|
4144
4237
|
.noShadow=${!0}
|
|
4145
4238
|
.layer=${i}
|
|
@@ -4148,7 +4241,7 @@ class $o extends tt {
|
|
|
4148
4241
|
.showLayerZoomState=${this.showLayerZoomState}
|
|
4149
4242
|
.tools=${this.tools}
|
|
4150
4243
|
.unstyled=${this.unstyled}
|
|
4151
|
-
.
|
|
4244
|
+
.toolsAsList=${this.toolsAsList}
|
|
4152
4245
|
@changed=${() => this.requestUpdate()}
|
|
4153
4246
|
></eox-layercontrol-layer>
|
|
4154
4247
|
`}
|
|
@@ -4161,8 +4254,8 @@ class $o extends tt {
|
|
|
4161
4254
|
`;
|
|
4162
4255
|
}
|
|
4163
4256
|
}
|
|
4164
|
-
|
|
4165
|
-
|
|
4257
|
+
rn = new WeakMap(), sn = new WeakMap(), // Define static properties for the component
|
|
4258
|
+
L(Oo, "properties", {
|
|
4166
4259
|
idProperty: { attribute: "id-property" },
|
|
4167
4260
|
layers: { attribute: !1 },
|
|
4168
4261
|
map: { attribute: !1, state: !0 },
|
|
@@ -4171,13 +4264,13 @@ N($o, "properties", {
|
|
|
4171
4264
|
tools: { attribute: !1 },
|
|
4172
4265
|
unstyled: { type: Boolean },
|
|
4173
4266
|
noShadow: { type: Boolean },
|
|
4174
|
-
|
|
4267
|
+
toolsAsList: { type: Boolean }
|
|
4175
4268
|
});
|
|
4176
|
-
customElements.define("eox-layercontrol-layer-list",
|
|
4177
|
-
const
|
|
4269
|
+
customElements.define("eox-layercontrol-layer-list", Oo);
|
|
4270
|
+
const Na = (e) => {
|
|
4178
4271
|
const t = e.querySelector(
|
|
4179
4272
|
"select[name=optional]"
|
|
4180
|
-
), n = t ? t.value : null, i =
|
|
4273
|
+
), n = t ? t.value : null, i = Qn(
|
|
4181
4274
|
e.layers.getArray(),
|
|
4182
4275
|
"layerControlOptional",
|
|
4183
4276
|
!0
|
|
@@ -4196,11 +4289,11 @@ const ca = (e) => {
|
|
|
4196
4289
|
)
|
|
4197
4290
|
), e.requestUpdate();
|
|
4198
4291
|
};
|
|
4199
|
-
var
|
|
4200
|
-
class
|
|
4292
|
+
var an, Ro;
|
|
4293
|
+
class Do extends it {
|
|
4201
4294
|
constructor() {
|
|
4202
4295
|
super();
|
|
4203
|
-
T(this,
|
|
4296
|
+
T(this, an);
|
|
4204
4297
|
this.idProperty = "id", this.layers = null, this.titleProperty = "title", this.unstyled = !1, this.noShadow = !1;
|
|
4205
4298
|
}
|
|
4206
4299
|
/**
|
|
@@ -4215,12 +4308,12 @@ class _o extends tt {
|
|
|
4215
4308
|
* Generates dropdown options based on the extracted layer information.
|
|
4216
4309
|
*/
|
|
4217
4310
|
render() {
|
|
4218
|
-
const n =
|
|
4311
|
+
const n = Qn(
|
|
4219
4312
|
this.layers.getArray(),
|
|
4220
4313
|
"layerControlOptional",
|
|
4221
4314
|
!0
|
|
4222
4315
|
);
|
|
4223
|
-
return
|
|
4316
|
+
return x`
|
|
4224
4317
|
<!-- Label for the dropdown -->
|
|
4225
4318
|
<label for="optional">Optional layers</label>
|
|
4226
4319
|
|
|
@@ -4234,23 +4327,23 @@ class _o extends tt {
|
|
|
4234
4327
|
<!-- Mapping through filtered layers list to generate dropdown options -->
|
|
4235
4328
|
${n.map((i) => {
|
|
4236
4329
|
const o = i.get(this.idProperty) || i.ol_uid, r = i.get(this.titleProperty), s = `layer ${i.get(this.idProperty)}`;
|
|
4237
|
-
return
|
|
4330
|
+
return x` <option value="${o}">${r || s}</option> `;
|
|
4238
4331
|
})}
|
|
4239
4332
|
</select>
|
|
4240
4333
|
|
|
4241
4334
|
<!-- Button to handle adding layers -->
|
|
4242
|
-
<button @click="${B(this,
|
|
4335
|
+
<button @click="${B(this, an, Ro)}">add</button>
|
|
4243
4336
|
`;
|
|
4244
4337
|
}
|
|
4245
4338
|
}
|
|
4246
|
-
|
|
4339
|
+
an = new WeakSet(), /**
|
|
4247
4340
|
* Handles the addition of selected layers to a list.
|
|
4248
4341
|
* Invokes the 'addToListMethod' with the current context.
|
|
4249
4342
|
*/
|
|
4250
|
-
|
|
4251
|
-
|
|
4343
|
+
Ro = function() {
|
|
4344
|
+
Na(this);
|
|
4252
4345
|
}, // Define static properties for the component
|
|
4253
|
-
|
|
4346
|
+
L(Do, "properties", {
|
|
4254
4347
|
idProperty: { attribute: "id-property" },
|
|
4255
4348
|
layers: { attribute: !1 },
|
|
4256
4349
|
titleProperty: { attribute: "title-property", type: String },
|
|
@@ -4259,27 +4352,27 @@ N(_o, "properties", {
|
|
|
4259
4352
|
});
|
|
4260
4353
|
customElements.define(
|
|
4261
4354
|
"eox-layercontrol-optional-list",
|
|
4262
|
-
|
|
4355
|
+
Do
|
|
4263
4356
|
);
|
|
4264
|
-
const
|
|
4357
|
+
const Ha = (e, t) => {
|
|
4265
4358
|
t.jsonInput = e.target.value, t.requestUpdate();
|
|
4266
|
-
},
|
|
4359
|
+
}, Ti = (e) => {
|
|
4267
4360
|
const t = JSON.parse(
|
|
4268
|
-
`{"data":${
|
|
4361
|
+
`{"data":${Ji(e.jsonInput)}}`
|
|
4269
4362
|
);
|
|
4270
4363
|
Array.isArray(t.data) ? t.data.forEach((n) => {
|
|
4271
4364
|
e.eoxMap.addOrUpdateLayer(n);
|
|
4272
4365
|
}) : e.eoxMap.addOrUpdateLayer(t.data), e.jsonInput = null, e.requestUpdate();
|
|
4273
|
-
},
|
|
4366
|
+
}, La = (e, t) => {
|
|
4274
4367
|
t.urlInput = e.target.value, t.requestUpdate();
|
|
4275
4368
|
};
|
|
4276
|
-
async function
|
|
4369
|
+
async function Ba(e) {
|
|
4277
4370
|
const t = e.urlInput;
|
|
4278
4371
|
if (e.wmsCapabilities = null, e.searchLoad = !0, e.requestUpdate(), !t) return !1;
|
|
4279
|
-
if (
|
|
4372
|
+
if (Wn(t) === "XYZ")
|
|
4280
4373
|
return { Name: t };
|
|
4281
4374
|
try {
|
|
4282
|
-
const n = await
|
|
4375
|
+
const n = await es(t);
|
|
4283
4376
|
e.wmsCapabilities = n;
|
|
4284
4377
|
} catch {
|
|
4285
4378
|
} finally {
|
|
@@ -4287,8 +4380,8 @@ async function fa(e) {
|
|
|
4287
4380
|
}
|
|
4288
4381
|
return !1;
|
|
4289
4382
|
}
|
|
4290
|
-
const
|
|
4291
|
-
const { Name: n } = e, i =
|
|
4383
|
+
const Va = (e, t) => {
|
|
4384
|
+
const { Name: n } = e, i = Wn(t.urlInput) || "XYZ", o = {
|
|
4292
4385
|
type: "Tile",
|
|
4293
4386
|
properties: {
|
|
4294
4387
|
id: n,
|
|
@@ -4306,45 +4399,45 @@ const ga = (e, t) => {
|
|
|
4306
4399
|
}
|
|
4307
4400
|
};
|
|
4308
4401
|
t.jsonInput = JSON.stringify(o);
|
|
4309
|
-
},
|
|
4402
|
+
}, ka = (e, t) => {
|
|
4310
4403
|
t.open = e || null, t.urlInput = null, t.jsonInput = null, t.wmsCapabilities = null, t.requestUpdate();
|
|
4311
4404
|
};
|
|
4312
|
-
var
|
|
4313
|
-
class
|
|
4405
|
+
var X, Io, No, Un, Ho, Lo, He, ln, un;
|
|
4406
|
+
class Mo extends it {
|
|
4314
4407
|
constructor() {
|
|
4315
4408
|
super();
|
|
4316
|
-
T(this,
|
|
4409
|
+
T(this, X);
|
|
4317
4410
|
/**
|
|
4318
4411
|
* State for URL Input for WMS/XYZ URLs
|
|
4319
4412
|
*
|
|
4320
4413
|
* @type {String}
|
|
4321
4414
|
*/
|
|
4322
|
-
|
|
4415
|
+
L(this, "urlInput", null);
|
|
4323
4416
|
/**
|
|
4324
4417
|
* State for JSON Textarea - For EOxMap JSON
|
|
4325
4418
|
*
|
|
4326
4419
|
* @type {String}
|
|
4327
4420
|
*/
|
|
4328
|
-
|
|
4421
|
+
L(this, "jsonInput", null);
|
|
4329
4422
|
/**
|
|
4330
4423
|
* State for add layer - consist of url/json
|
|
4331
4424
|
*
|
|
4332
4425
|
* @type {"url" | "json" | null}
|
|
4333
4426
|
*/
|
|
4334
|
-
|
|
4427
|
+
L(this, "open", null);
|
|
4335
4428
|
/**
|
|
4336
4429
|
* Loader state when search is triggered
|
|
4337
4430
|
*
|
|
4338
4431
|
* @type {Boolean}
|
|
4339
4432
|
*/
|
|
4340
|
-
|
|
4433
|
+
L(this, "searchLoad", !1);
|
|
4341
4434
|
/**
|
|
4342
4435
|
* State for `WMS Capabilities JSON`
|
|
4343
4436
|
*
|
|
4344
4437
|
* @type {import("wms-capabilities").WMSCapabilitiesJSON}
|
|
4345
4438
|
*/
|
|
4346
|
-
|
|
4347
|
-
T(this,
|
|
4439
|
+
L(this, "wmsCapabilities", null);
|
|
4440
|
+
T(this, ln, `
|
|
4348
4441
|
.eox-add-layer-main .open {
|
|
4349
4442
|
position: relative;
|
|
4350
4443
|
}
|
|
@@ -4352,7 +4445,7 @@ class Co extends tt {
|
|
|
4352
4445
|
display: none;
|
|
4353
4446
|
}
|
|
4354
4447
|
`);
|
|
4355
|
-
T(this,
|
|
4448
|
+
T(this, un, `
|
|
4356
4449
|
.eox-add {
|
|
4357
4450
|
background: #f0f2f5;
|
|
4358
4451
|
border-top: 1px solid #0041701a;
|
|
@@ -4501,24 +4594,24 @@ class Co extends tt {
|
|
|
4501
4594
|
* Handles input fields, search, and addition of layers.
|
|
4502
4595
|
*/
|
|
4503
4596
|
render() {
|
|
4504
|
-
const n = this.open ? "open" : "close", i = this.open === "url", o = this.open === "json", r = !
|
|
4505
|
-
return
|
|
4597
|
+
const n = this.open ? "open" : "close", i = this.open === "url", o = this.open === "json", r = !ns(this.urlInput) || this.searchLoad ? !0 : C;
|
|
4598
|
+
return x`
|
|
4506
4599
|
<style>
|
|
4507
|
-
${P(this,
|
|
4508
|
-
${!this.unstyled && P(this,
|
|
4600
|
+
${P(this, ln)}
|
|
4601
|
+
${!this.unstyled && P(this, un)}
|
|
4509
4602
|
</style>
|
|
4510
4603
|
<div class="eox-add-layer-main">
|
|
4511
4604
|
<div class="eox-add-layer-col">
|
|
4512
4605
|
<!-- Tabbed interface for URL and JSON -->
|
|
4513
4606
|
<ul class="eox-add-layer-tab ${n}">
|
|
4514
4607
|
<li
|
|
4515
|
-
@click=${() => B(this,
|
|
4608
|
+
@click=${() => B(this, X, He).call(this, "url")}
|
|
4516
4609
|
class="${i ? "active" : ""}"
|
|
4517
4610
|
>
|
|
4518
4611
|
URL
|
|
4519
4612
|
</li>
|
|
4520
4613
|
<li
|
|
4521
|
-
@click=${() => B(this,
|
|
4614
|
+
@click=${() => B(this, X, He).call(this, "json")}
|
|
4522
4615
|
class="${o ? "active" : ""}"
|
|
4523
4616
|
>
|
|
4524
4617
|
JSON
|
|
@@ -4528,13 +4621,13 @@ class Co extends tt {
|
|
|
4528
4621
|
<!-- Button to toggle tabs -->
|
|
4529
4622
|
<button
|
|
4530
4623
|
class="add-icon icon"
|
|
4531
|
-
@click=${() => B(this,
|
|
4624
|
+
@click=${() => B(this, X, He).call(this, this.open ? null : "url")}
|
|
4532
4625
|
>
|
|
4533
4626
|
${this.unstyled ? "Add Layer" : ""}
|
|
4534
4627
|
</button>
|
|
4535
4628
|
</div>
|
|
4536
4629
|
<div class="eox-add ${n}">
|
|
4537
|
-
${i ?
|
|
4630
|
+
${i ? x`
|
|
4538
4631
|
<!-- Input field for URL -->
|
|
4539
4632
|
<div class="eox-add-layer-col">
|
|
4540
4633
|
<input
|
|
@@ -4542,25 +4635,25 @@ class Co extends tt {
|
|
|
4542
4635
|
class="add-url"
|
|
4543
4636
|
placeholder="Add URL (WMS/XYZ)"
|
|
4544
4637
|
.value="${this.urlInput}"
|
|
4545
|
-
@input=${B(this,
|
|
4638
|
+
@input=${B(this, X, Io)}
|
|
4546
4639
|
>
|
|
4547
4640
|
</input>
|
|
4548
4641
|
<!-- Search button for URL -->
|
|
4549
4642
|
<button
|
|
4550
4643
|
class="search-icon"
|
|
4551
4644
|
disabled=${r}
|
|
4552
|
-
@click=${B(this,
|
|
4645
|
+
@click=${B(this, X, No)}
|
|
4553
4646
|
>
|
|
4554
4647
|
${this.unstyled ? "Search" : ""}
|
|
4555
4648
|
</button>
|
|
4556
4649
|
</div>
|
|
4557
4650
|
|
|
4558
4651
|
<!-- Display layers for WMS capabilities -->
|
|
4559
|
-
${this.wmsCapabilities ?
|
|
4652
|
+
${this.wmsCapabilities ? x`<ul class="search-lists">
|
|
4560
4653
|
${this.wmsCapabilities.Capability.Layer.Layer.map(
|
|
4561
4654
|
(s) => {
|
|
4562
4655
|
const a = s.Name;
|
|
4563
|
-
return
|
|
4656
|
+
return x`
|
|
4564
4657
|
<li class="search-list">
|
|
4565
4658
|
${a}
|
|
4566
4659
|
<!-- Button to add layer -->
|
|
@@ -4568,7 +4661,7 @@ class Co extends tt {
|
|
|
4568
4661
|
class="add-layer-icon icon"
|
|
4569
4662
|
@click=${() => (
|
|
4570
4663
|
//@ts-ignore
|
|
4571
|
-
B(this,
|
|
4664
|
+
B(this, X, Un).call(this, s)
|
|
4572
4665
|
)}
|
|
4573
4666
|
>
|
|
4574
4667
|
${this.unstyled ? "+" : ""}
|
|
@@ -4578,20 +4671,20 @@ class Co extends tt {
|
|
|
4578
4671
|
}
|
|
4579
4672
|
)}
|
|
4580
4673
|
</ul>` : C}
|
|
4581
|
-
` :
|
|
4674
|
+
` : x`
|
|
4582
4675
|
<!-- Textarea for JSON input -->
|
|
4583
4676
|
<textarea
|
|
4584
4677
|
class="add-layer-input"
|
|
4585
4678
|
placeholder="Please put a valid eox-map layer JSON."
|
|
4586
|
-
@input=${B(this,
|
|
4679
|
+
@input=${B(this, X, Lo)}
|
|
4587
4680
|
.value=${this.jsonInput}
|
|
4588
4681
|
></textarea>
|
|
4589
4682
|
|
|
4590
4683
|
<!-- Button to add JSON layer -->
|
|
4591
4684
|
<button
|
|
4592
4685
|
class="add-layer-icon json-add-layer"
|
|
4593
|
-
disabled=${
|
|
4594
|
-
@click=${B(this,
|
|
4686
|
+
disabled=${is(this.jsonInput) ? C : !0}
|
|
4687
|
+
@click=${B(this, X, Ho)}
|
|
4595
4688
|
>
|
|
4596
4689
|
${this.unstyled ? "Add JSON" : ""}
|
|
4597
4690
|
</button>
|
|
@@ -4601,110 +4694,118 @@ class Co extends tt {
|
|
|
4601
4694
|
`;
|
|
4602
4695
|
}
|
|
4603
4696
|
}
|
|
4604
|
-
|
|
4697
|
+
X = new WeakSet(), /**
|
|
4605
4698
|
* Handles changes in the input field by invoking the 'urlInputChangeMethod'.
|
|
4606
4699
|
* This method is triggered upon an @input change event.
|
|
4607
4700
|
*
|
|
4608
4701
|
* @param {Event} evt - The input change event triggering the method.
|
|
4609
4702
|
*/
|
|
4610
|
-
|
|
4611
|
-
|
|
4612
|
-
},
|
|
4613
|
-
const n = await
|
|
4614
|
-
n && B(this,
|
|
4703
|
+
Io = function(n) {
|
|
4704
|
+
La(n, this);
|
|
4705
|
+
}, No = async function() {
|
|
4706
|
+
const n = await Ba(this);
|
|
4707
|
+
n && B(this, X, Un).call(this, n);
|
|
4615
4708
|
}, /**
|
|
4616
4709
|
* Handles input field changes by triggering layer processing and adding layers.
|
|
4617
4710
|
*
|
|
4618
4711
|
* @param {{"Name": string}} layer - The layer information triggering the method.
|
|
4619
4712
|
*/
|
|
4620
|
-
|
|
4621
|
-
|
|
4713
|
+
Un = function(n) {
|
|
4714
|
+
Va(n, this), Ti(this);
|
|
4622
4715
|
}, /**
|
|
4623
4716
|
* Initiates the addition of layers, triggering the handleAddLayerMethod.
|
|
4624
4717
|
*/
|
|
4625
|
-
|
|
4626
|
-
|
|
4718
|
+
Ho = function() {
|
|
4719
|
+
Ti(this);
|
|
4627
4720
|
}, /**
|
|
4628
4721
|
* Handles input field changes by invoking the 'handleJsonInputChangeMethod'.
|
|
4629
4722
|
*
|
|
4630
4723
|
* @param {{target: { value: string }}} evt - The input change event triggering the method.
|
|
4631
4724
|
*/
|
|
4632
|
-
|
|
4633
|
-
|
|
4725
|
+
Lo = function(n) {
|
|
4726
|
+
Ha(n, this);
|
|
4634
4727
|
}, /**
|
|
4635
4728
|
* Handles tab changes by invoking the 'openCloseTabMethod'.
|
|
4636
4729
|
*
|
|
4637
4730
|
* @param {"url" | "json" | null} tab - The tab identifier triggering the method.
|
|
4638
4731
|
*/
|
|
4639
|
-
|
|
4640
|
-
|
|
4641
|
-
},
|
|
4642
|
-
|
|
4732
|
+
He = function(n) {
|
|
4733
|
+
ka(n, this);
|
|
4734
|
+
}, ln = new WeakMap(), un = new WeakMap(), // Define static properties for the component
|
|
4735
|
+
L(Mo, "properties", {
|
|
4643
4736
|
eoxMap: { attribute: !1, state: !0 },
|
|
4644
4737
|
unstyled: { type: Boolean },
|
|
4645
4738
|
noShadow: { type: Boolean }
|
|
4646
4739
|
});
|
|
4647
|
-
customElements.define("eox-layercontrol-add-layers",
|
|
4648
|
-
const
|
|
4740
|
+
customElements.define("eox-layercontrol-add-layers", Mo);
|
|
4741
|
+
const Ua = (e, t) => {
|
|
4649
4742
|
if (t.requestUpdate(), e.target.tagName === "EOX-LAYERCONTROL-LAYER-TOOLS") {
|
|
4650
4743
|
const n = t.renderRoot.querySelector(
|
|
4651
4744
|
"eox-layercontrol-optional-list"
|
|
4652
4745
|
);
|
|
4653
4746
|
n == null || n.requestUpdate();
|
|
4654
4747
|
}
|
|
4655
|
-
},
|
|
4748
|
+
}, Fa = (e) => {
|
|
4656
4749
|
let t;
|
|
4657
4750
|
return typeof e == "string" ? t = /** @type {HTMLElement} */
|
|
4658
4751
|
document.querySelector(e) : t = e, t;
|
|
4659
|
-
},
|
|
4660
|
-
const t =
|
|
4752
|
+
}, Pi = (e) => {
|
|
4753
|
+
const t = Fa(e.for);
|
|
4661
4754
|
return t && t.map !== e.map && (e.map = t.map), t;
|
|
4662
4755
|
};
|
|
4663
|
-
var $t,
|
|
4664
|
-
class
|
|
4756
|
+
var $t, Yt, Vo, ko, dn;
|
|
4757
|
+
class Bo extends it {
|
|
4665
4758
|
// Constructor to set default values for properties
|
|
4666
4759
|
constructor() {
|
|
4667
4760
|
super();
|
|
4668
|
-
T(this,
|
|
4761
|
+
T(this, Yt);
|
|
4669
4762
|
/**
|
|
4670
4763
|
* Instance of `eox-map` which is a wrapper for the OL
|
|
4671
4764
|
*
|
|
4672
4765
|
* @type {import("../../map/main").EOxMap}
|
|
4673
4766
|
*/
|
|
4674
4767
|
T(this, $t);
|
|
4675
|
-
T(this, dn,
|
|
4676
|
-
|
|
4768
|
+
T(this, dn, `
|
|
4769
|
+
:host, :root {
|
|
4770
|
+
font-family: Roboto, sans-serif;
|
|
4771
|
+
--padding: 0.5rem;
|
|
4772
|
+
|
|
4773
|
+
display: block;
|
|
4774
|
+
padding: var(--padding) 0;
|
|
4775
|
+
}
|
|
4776
|
+
`);
|
|
4777
|
+
this.for = "eox-map", this.idProperty = "id", this.map = null, this.titleProperty = "title", this.showLayerZoomState = !1, this.tools = ["info", "opacity", "datetime", "config", "remove", "sort"], this.addExternalLayers = !1, this.unstyled = !1, this.styleOverride = "", this.toolsAsList = !1;
|
|
4677
4778
|
}
|
|
4678
4779
|
/**
|
|
4679
4780
|
* Called when the component is first updated
|
|
4680
4781
|
* Updated #eoxMap after first update.
|
|
4681
4782
|
*/
|
|
4682
4783
|
firstUpdated() {
|
|
4683
|
-
this.eoxMap =
|
|
4784
|
+
this.eoxMap = Pi(this);
|
|
4684
4785
|
}
|
|
4685
4786
|
updated(n) {
|
|
4686
|
-
n.has("for") && (this.eoxMap =
|
|
4787
|
+
n.has("for") && (this.eoxMap = Pi(this));
|
|
4687
4788
|
}
|
|
4688
4789
|
get eoxMap() {
|
|
4689
4790
|
return P(this, $t);
|
|
4690
4791
|
}
|
|
4691
4792
|
set eoxMap(n) {
|
|
4692
4793
|
const i = P(this, $t);
|
|
4693
|
-
|
|
4794
|
+
Qt(this, $t, n), this.requestUpdate("eoxMap", i);
|
|
4694
4795
|
}
|
|
4695
4796
|
render() {
|
|
4696
4797
|
var o, r, s;
|
|
4697
|
-
const n = (o = this.map) == null ? void 0 : o.getLayers().getArray(), i = n && ((r =
|
|
4698
|
-
return
|
|
4798
|
+
const n = (o = this.map) == null ? void 0 : o.getLayers().getArray(), i = n && ((r = Qn(n, "layerControlOptional", !0)) == null ? void 0 : r.length) > 0;
|
|
4799
|
+
return x`
|
|
4699
4800
|
<style>
|
|
4700
4801
|
${!this.unstyled && P(this, dn)}
|
|
4701
4802
|
${this.styleOverride}
|
|
4702
4803
|
</style>
|
|
4703
4804
|
|
|
4704
4805
|
<!-- Conditional rendering of add layers component -->
|
|
4705
|
-
${
|
|
4806
|
+
${G(
|
|
4706
4807
|
this.addExternalLayers && ((s = P(this, $t)) == null ? void 0 : s.addOrUpdateLayer),
|
|
4707
|
-
() =>
|
|
4808
|
+
() => x`
|
|
4708
4809
|
<eox-layercontrol-add-layers
|
|
4709
4810
|
.noShadow=${!0}
|
|
4710
4811
|
.eoxMap=${P(this, $t)}
|
|
@@ -4714,9 +4815,9 @@ class Ro extends tt {
|
|
|
4714
4815
|
)}
|
|
4715
4816
|
|
|
4716
4817
|
<!-- Conditional rendering of layer list component -->
|
|
4717
|
-
${
|
|
4818
|
+
${G(
|
|
4718
4819
|
this.map,
|
|
4719
|
-
() =>
|
|
4820
|
+
() => x`
|
|
4720
4821
|
<eox-layercontrol-layer-list
|
|
4721
4822
|
.noShadow=${!0}
|
|
4722
4823
|
class="layers"
|
|
@@ -4727,17 +4828,17 @@ class Ro extends tt {
|
|
|
4727
4828
|
.showLayerZoomState=${this.showLayerZoomState}
|
|
4728
4829
|
.tools=${this.tools}
|
|
4729
4830
|
.unstyled=${this.unstyled}
|
|
4730
|
-
.
|
|
4731
|
-
@changed=${B(this,
|
|
4732
|
-
@datetime:updated=${B(this,
|
|
4831
|
+
.toolsAsList=${this.toolsAsList}
|
|
4832
|
+
@changed=${B(this, Yt, Vo)}
|
|
4833
|
+
@datetime:updated=${B(this, Yt, ko)}
|
|
4733
4834
|
></eox-layercontrol-layer-list>
|
|
4734
4835
|
`
|
|
4735
4836
|
)}
|
|
4736
4837
|
|
|
4737
4838
|
<!-- Conditional rendering of optional list component -->
|
|
4738
|
-
${
|
|
4839
|
+
${G(
|
|
4739
4840
|
i,
|
|
4740
|
-
() =>
|
|
4841
|
+
() => x`
|
|
4741
4842
|
<eox-layercontrol-optional-list
|
|
4742
4843
|
.noShadow=${!0}
|
|
4743
4844
|
.idProperty=${this.idProperty}
|
|
@@ -4750,23 +4851,23 @@ class Ro extends tt {
|
|
|
4750
4851
|
`;
|
|
4751
4852
|
}
|
|
4752
4853
|
}
|
|
4753
|
-
$t = new WeakMap(),
|
|
4854
|
+
$t = new WeakMap(), Yt = new WeakSet(), /**
|
|
4754
4855
|
* Event handler for changes in the layer list
|
|
4755
4856
|
*
|
|
4756
4857
|
* @param {CustomEvent & {target: Element}} evt
|
|
4757
4858
|
*/
|
|
4758
|
-
|
|
4759
|
-
|
|
4859
|
+
Vo = function(n) {
|
|
4860
|
+
Ua(n, this), this.dispatchEvent(new CustomEvent("layerchange", { detail: n.detail }));
|
|
4760
4861
|
}, /**
|
|
4761
4862
|
* Dispatches datetime updates from layer datetime to the layercontrol
|
|
4762
4863
|
* @param {CustomEvent} evt
|
|
4763
4864
|
*/
|
|
4764
|
-
|
|
4865
|
+
ko = function(n) {
|
|
4765
4866
|
this.dispatchEvent(
|
|
4766
4867
|
new CustomEvent("datetime:updated", { detail: n.detail })
|
|
4767
4868
|
);
|
|
4768
4869
|
}, dn = new WeakMap(), // Define static properties for the component
|
|
4769
|
-
|
|
4870
|
+
L(Bo, "properties", {
|
|
4770
4871
|
for: { type: String },
|
|
4771
4872
|
idProperty: { attribute: "id-property" },
|
|
4772
4873
|
map: { attribute: !1, state: !0 },
|
|
@@ -4776,9 +4877,9 @@ N(Ro, "properties", {
|
|
|
4776
4877
|
addExternalLayers: { attribute: !1 },
|
|
4777
4878
|
unstyled: { type: Boolean },
|
|
4778
4879
|
styleOverride: { type: String },
|
|
4779
|
-
|
|
4880
|
+
toolsAsList: { type: Boolean }
|
|
4780
4881
|
});
|
|
4781
|
-
customElements.define("eox-layercontrol",
|
|
4882
|
+
customElements.define("eox-layercontrol", Bo);
|
|
4782
4883
|
export {
|
|
4783
|
-
|
|
4884
|
+
Bo as EOxLayerControl
|
|
4784
4885
|
};
|