@eox/layercontrol 0.22.0 → 0.24.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +4 -0
- package/dist/eox-layercontrol.js +836 -839
- package/dist/eox-layercontrol.umd.cjs +119 -122
- package/package.json +24 -17
- package/src/components/add-layers.js +416 -0
- package/src/components/layer-config.js +212 -0
- package/src/components/layer-datetime.js +128 -0
- package/src/components/layer-group.js +193 -0
- package/src/components/layer-legend.js +135 -0
- package/src/components/layer-list.js +209 -0
- package/src/components/layer-tools.js +353 -0
- package/src/components/layer.js +244 -0
- package/src/components/optional-list.js +124 -0
- package/src/components/tab-sliders.js +0 -0
- package/src/components/tools-items.js +199 -0
- package/src/enums/index.js +16 -0
- package/src/enums/stories/assets/cropomhusc-feature-collection.json +5274 -0
- package/src/enums/stories/index.js +536 -0
- package/src/helpers/check-properties.js +41 -0
- package/src/helpers/clean-json-input.js +29 -0
- package/src/helpers/create-sortable.js +104 -0
- package/src/helpers/detect-map-url-type.js +20 -0
- package/src/helpers/fetch-capabilities.js +32 -0
- package/src/helpers/filter-layers.js +45 -0
- package/src/helpers/get-layer-type.js +35 -0
- package/src/helpers/get-legend-config.js +25 -0
- package/src/helpers/get-start-vals.js +73 -0
- package/src/helpers/hide-layers-based-on-property.js +11 -0
- package/src/helpers/index.js +22 -0
- package/src/helpers/is-layer-json-valid.js +19 -0
- package/src/helpers/is-layer-visible-based-on-zoom-state.js +31 -0
- package/src/helpers/is-layer-zoom-state-req.js +17 -0
- package/src/helpers/is-map-url-valid.js +22 -0
- package/src/helpers/layer-tools.js +82 -0
- package/src/helpers/update-url.js +32 -0
- package/src/main.js +269 -0
- package/src/methods/add-layer/add-layer.js +33 -0
- package/src/methods/add-layer/index.js +8 -0
- package/src/methods/add-layer/json-input-change.js +15 -0
- package/src/methods/add-layer/open-close-tab.js +21 -0
- package/src/methods/add-layer/url-input-change.js +17 -0
- package/src/methods/add-layer/url-layer.js +37 -0
- package/src/methods/add-layer/wms-search-url.js +44 -0
- package/src/methods/layer/first-updated.js +65 -0
- package/src/methods/layer/index.js +4 -0
- package/src/methods/layer/input-click.js +43 -0
- package/src/methods/layer-config/apply-updated-styles.js +98 -0
- package/src/methods/layer-config/data-change.js +44 -0
- package/src/methods/layer-config/index.js +7 -0
- package/src/methods/layer-list/first-updated.js +55 -0
- package/src/methods/layer-list/index.js +3 -0
- package/src/methods/layercontrol/first-update.js +22 -0
- package/src/methods/layercontrol/index.js +4 -0
- package/src/methods/layercontrol/layer-list-change.js +23 -0
- package/src/methods/optional-list/add-to-list.js +44 -0
- package/src/methods/optional-list/index.js +3 -0
- package/types/layercontrol/src/components/add-layers.d.ts +80 -0
- package/types/layercontrol/src/components/add-layers.d.ts.map +1 -0
- package/types/layercontrol/src/components/layer-config.d.ts +82 -0
- package/types/layercontrol/src/components/layer-config.d.ts.map +1 -0
- package/types/layercontrol/src/components/layer-datetime.d.ts +66 -0
- package/types/layercontrol/src/components/layer-datetime.d.ts.map +1 -0
- package/types/layercontrol/src/components/layer-group.d.ts +103 -0
- package/types/layercontrol/src/components/layer-group.d.ts.map +1 -0
- package/types/layercontrol/src/components/layer-legend.d.ts +83 -0
- package/types/layercontrol/src/components/layer-legend.d.ts.map +1 -0
- package/types/layercontrol/src/components/layer-list.d.ts +108 -0
- package/types/layercontrol/src/components/layer-list.d.ts.map +1 -0
- package/types/layercontrol/src/components/layer-tools.d.ts +72 -0
- package/types/layercontrol/src/components/layer-tools.d.ts.map +1 -0
- package/types/layercontrol/src/components/layer.d.ts +108 -0
- package/types/layercontrol/src/components/layer.d.ts.map +1 -0
- package/types/layercontrol/src/components/optional-list.d.ts +68 -0
- package/types/layercontrol/src/components/optional-list.d.ts.map +1 -0
- package/types/layercontrol/src/components/tab-sliders.d.ts +1 -0
- package/types/layercontrol/src/components/tab-sliders.d.ts.map +1 -0
- package/types/layercontrol/src/components/tools-items.d.ts +61 -0
- package/types/layercontrol/src/components/tools-items.d.ts.map +1 -0
- package/types/layercontrol/src/enums/index.d.ts +2 -0
- package/types/layercontrol/src/enums/index.d.ts.map +1 -0
- package/types/layercontrol/src/enums/stories/index.d.ts +549 -0
- package/types/layercontrol/src/enums/stories/index.d.ts.map +1 -0
- package/types/layercontrol/src/helpers/check-properties.d.ts +11 -0
- package/types/layercontrol/src/helpers/check-properties.d.ts.map +1 -0
- package/types/layercontrol/src/helpers/clean-json-input.d.ts +8 -0
- package/types/layercontrol/src/helpers/clean-json-input.d.ts.map +1 -0
- package/types/layercontrol/src/helpers/create-sortable.d.ts +11 -0
- package/types/layercontrol/src/helpers/create-sortable.d.ts.map +1 -0
- package/types/layercontrol/src/helpers/detect-map-url-type.d.ts +8 -0
- package/types/layercontrol/src/helpers/detect-map-url-type.d.ts.map +1 -0
- package/types/layercontrol/src/helpers/fetch-capabilities.d.ts +10 -0
- package/types/layercontrol/src/helpers/fetch-capabilities.d.ts.map +1 -0
- package/types/layercontrol/src/helpers/filter-layers.d.ts +10 -0
- package/types/layercontrol/src/helpers/filter-layers.d.ts.map +1 -0
- package/types/layercontrol/src/helpers/get-layer-type.d.ts +9 -0
- package/types/layercontrol/src/helpers/get-layer-type.d.ts.map +1 -0
- package/types/layercontrol/src/helpers/get-legend-config.d.ts +20 -0
- package/types/layercontrol/src/helpers/get-legend-config.d.ts.map +1 -0
- package/types/layercontrol/src/helpers/get-start-vals.d.ts +21 -0
- package/types/layercontrol/src/helpers/get-start-vals.d.ts.map +1 -0
- package/types/layercontrol/src/helpers/hide-layers-based-on-property.d.ts +2 -0
- package/types/layercontrol/src/helpers/hide-layers-based-on-property.d.ts.map +1 -0
- package/types/layercontrol/src/helpers/index.d.ts +17 -0
- package/types/layercontrol/src/helpers/index.d.ts.map +1 -0
- package/types/layercontrol/src/helpers/is-layer-json-valid.d.ts +7 -0
- package/types/layercontrol/src/helpers/is-layer-json-valid.d.ts.map +1 -0
- package/types/layercontrol/src/helpers/is-layer-visible-based-on-zoom-state.d.ts +11 -0
- package/types/layercontrol/src/helpers/is-layer-visible-based-on-zoom-state.d.ts.map +1 -0
- package/types/layercontrol/src/helpers/is-layer-zoom-state-req.d.ts +9 -0
- package/types/layercontrol/src/helpers/is-layer-zoom-state-req.d.ts.map +1 -0
- package/types/layercontrol/src/helpers/is-map-url-valid.d.ts +8 -0
- package/types/layercontrol/src/helpers/is-map-url-valid.d.ts.map +1 -0
- package/types/layercontrol/src/helpers/layer-tools.d.ts +6 -0
- package/types/layercontrol/src/helpers/layer-tools.d.ts.map +1 -0
- package/types/layercontrol/src/helpers/update-url.d.ts +9 -0
- package/types/layercontrol/src/helpers/update-url.d.ts.map +1 -0
- package/types/layercontrol/src/main.d.ts +149 -0
- package/types/layercontrol/src/main.d.ts.map +1 -0
- package/types/layercontrol/src/methods/add-layer/add-layer.d.ts +10 -0
- package/types/layercontrol/src/methods/add-layer/add-layer.d.ts.map +1 -0
- package/types/layercontrol/src/methods/add-layer/index.d.ts +7 -0
- package/types/layercontrol/src/methods/add-layer/index.d.ts.map +1 -0
- package/types/layercontrol/src/methods/add-layer/json-input-change.d.ts +13 -0
- package/types/layercontrol/src/methods/add-layer/json-input-change.d.ts.map +1 -0
- package/types/layercontrol/src/methods/add-layer/open-close-tab.d.ts +10 -0
- package/types/layercontrol/src/methods/add-layer/open-close-tab.d.ts.map +1 -0
- package/types/layercontrol/src/methods/add-layer/url-input-change.d.ts +10 -0
- package/types/layercontrol/src/methods/add-layer/url-input-change.d.ts.map +1 -0
- package/types/layercontrol/src/methods/add-layer/url-layer.d.ts +12 -0
- package/types/layercontrol/src/methods/add-layer/url-layer.d.ts.map +1 -0
- package/types/layercontrol/src/methods/add-layer/wms-search-url.d.ts +11 -0
- package/types/layercontrol/src/methods/add-layer/wms-search-url.d.ts.map +1 -0
- package/types/layercontrol/src/methods/layer/first-updated.d.ts +9 -0
- package/types/layercontrol/src/methods/layer/first-updated.d.ts.map +1 -0
- package/types/layercontrol/src/methods/layer/index.d.ts +3 -0
- package/types/layercontrol/src/methods/layer/index.d.ts.map +1 -0
- package/types/layercontrol/src/methods/layer/input-click.d.ts +13 -0
- package/types/layercontrol/src/methods/layer/input-click.d.ts.map +1 -0
- package/types/layercontrol/src/methods/layer-config/apply-updated-styles.d.ts +8 -0
- package/types/layercontrol/src/methods/layer-config/apply-updated-styles.d.ts.map +1 -0
- package/types/layercontrol/src/methods/layer-config/data-change.d.ts +14 -0
- package/types/layercontrol/src/methods/layer-config/data-change.d.ts.map +1 -0
- package/types/layercontrol/src/methods/layer-config/index.d.ts +3 -0
- package/types/layercontrol/src/methods/layer-config/index.d.ts.map +1 -0
- package/types/layercontrol/src/methods/layer-list/first-updated.d.ts +9 -0
- package/types/layercontrol/src/methods/layer-list/first-updated.d.ts.map +1 -0
- package/types/layercontrol/src/methods/layer-list/index.d.ts +2 -0
- package/types/layercontrol/src/methods/layer-list/index.d.ts.map +1 -0
- package/types/layercontrol/src/methods/layercontrol/first-update.d.ts +10 -0
- package/types/layercontrol/src/methods/layercontrol/first-update.d.ts.map +1 -0
- package/types/layercontrol/src/methods/layercontrol/index.d.ts +3 -0
- package/types/layercontrol/src/methods/layercontrol/index.d.ts.map +1 -0
- package/types/layercontrol/src/methods/layercontrol/layer-list-change.d.ts +11 -0
- package/types/layercontrol/src/methods/layercontrol/layer-list-change.d.ts.map +1 -0
- package/types/layercontrol/src/methods/optional-list/add-to-list.d.ts +8 -0
- package/types/layercontrol/src/methods/optional-list/add-to-list.d.ts.map +1 -0
- package/types/layercontrol/src/methods/optional-list/index.d.ts +2 -0
- package/types/layercontrol/src/methods/optional-list/index.d.ts.map +1 -0
- package/types/map/src/components/compare.d.ts +31 -0
- package/types/map/src/components/compare.d.ts.map +1 -0
- package/types/map/src/components/tooltip.d.ts +36 -0
- package/types/map/src/components/tooltip.d.ts.map +1 -0
- package/types/map/src/controls/controls.d.ts +27 -0
- package/types/map/src/controls/controls.d.ts.map +1 -0
- package/types/map/src/controls/geo-location.d.ts +41 -0
- package/types/map/src/controls/geo-location.d.ts.map +1 -0
- package/types/map/src/controls/loading-indicator.d.ts +20 -0
- package/types/map/src/controls/loading-indicator.d.ts.map +1 -0
- package/types/map/src/enums/index.d.ts +2 -0
- package/types/map/src/enums/index.d.ts.map +1 -0
- package/types/map/src/enums/map.d.ts +5 -0
- package/types/map/src/enums/map.d.ts.map +1 -0
- package/types/map/src/helpers/add-new-feature.d.ts +14 -0
- package/types/map/src/helpers/add-new-feature.d.ts.map +1 -0
- package/types/map/src/helpers/cancel-animation.d.ts +7 -0
- package/types/map/src/helpers/cancel-animation.d.ts.map +1 -0
- package/types/map/src/helpers/center.d.ts +12 -0
- package/types/map/src/helpers/center.d.ts.map +1 -0
- package/types/map/src/helpers/coordinates-roughly-equals.d.ts +12 -0
- package/types/map/src/helpers/coordinates-roughly-equals.d.ts.map +1 -0
- package/types/map/src/helpers/draw.d.ts +22 -0
- package/types/map/src/helpers/draw.d.ts.map +1 -0
- package/types/map/src/helpers/generate.d.ts +30 -0
- package/types/map/src/helpers/generate.d.ts.map +1 -0
- package/types/map/src/helpers/index.d.ts +16 -0
- package/types/map/src/helpers/index.d.ts.map +1 -0
- package/types/map/src/helpers/interactions.d.ts +16 -0
- package/types/map/src/helpers/interactions.d.ts.map +1 -0
- package/types/map/src/helpers/layer.d.ts +24 -0
- package/types/map/src/helpers/layer.d.ts.map +1 -0
- package/types/map/src/helpers/parse-feature.d.ts +8 -0
- package/types/map/src/helpers/parse-feature.d.ts.map +1 -0
- package/types/map/src/helpers/parse-text.d.ts +33 -0
- package/types/map/src/helpers/parse-text.d.ts.map +1 -0
- package/types/map/src/helpers/register-projection-from-code.d.ts +8 -0
- package/types/map/src/helpers/register-projection-from-code.d.ts.map +1 -0
- package/types/map/src/helpers/register-projection.d.ts +11 -0
- package/types/map/src/helpers/register-projection.d.ts.map +1 -0
- package/types/map/src/helpers/select.d.ts +77 -0
- package/types/map/src/helpers/select.d.ts.map +1 -0
- package/types/map/src/helpers/tile-grid.d.ts +14 -0
- package/types/map/src/helpers/tile-grid.d.ts.map +1 -0
- package/types/map/src/helpers/transform.d.ts +19 -0
- package/types/map/src/helpers/transform.d.ts.map +1 -0
- package/types/map/src/main.d.ts +337 -0
- package/types/map/src/main.d.ts.map +1 -0
- package/types/map/src/methods/map/add-update-layer.d.ts +13 -0
- package/types/map/src/methods/map/add-update-layer.d.ts.map +1 -0
- package/types/map/src/methods/map/animate-to-state.d.ts +7 -0
- package/types/map/src/methods/map/animate-to-state.d.ts.map +1 -0
- package/types/map/src/methods/map/first-updated.d.ts +9 -0
- package/types/map/src/methods/map/first-updated.d.ts.map +1 -0
- package/types/map/src/methods/map/getters.d.ts +15 -0
- package/types/map/src/methods/map/getters.d.ts.map +1 -0
- package/types/map/src/methods/map/index.d.ts +7 -0
- package/types/map/src/methods/map/index.d.ts.map +1 -0
- package/types/map/src/methods/map/remove.d.ts +22 -0
- package/types/map/src/methods/map/remove.d.ts.map +1 -0
- package/types/map/src/methods/map/setters.d.ts +82 -0
- package/types/map/src/methods/map/setters.d.ts.map +1 -0
- package/types/map/types.d.ts +146 -0
- package/types/map/types.d.ts.map +1 -0
- package/test/_mockMap.js +0 -154
- package/test/cases/general/check-layer-legend.js +0 -67
- package/test/cases/general/check-layer-size.js +0 -25
- package/test/cases/general/check-pre-open-layer-tools.js +0 -26
- package/test/cases/general/check-pre-open-section.js +0 -29
- package/test/cases/general/disable-drag.js +0 -26
- package/test/cases/general/empty-groups.js +0 -41
- package/test/cases/general/exclusive-layers.js +0 -35
- package/test/cases/general/hide-layers.js +0 -23
- package/test/cases/general/index.js +0 -10
- package/test/cases/general/render-optional-layer.js +0 -31
- package/test/cases/general/show-layer-title.js +0 -23
- package/test/cases/layer-update/add-external-layer.js +0 -96
- package/test/cases/layer-update/add-layer-from-optional.js +0 -51
- package/test/cases/layer-update/check-if-layer-pushed-to-group.js +0 -33
- package/test/cases/layer-update/check-layer-changed-event.js +0 -29
- package/test/cases/layer-update/check-layer-is-pushed-to-root.js +0 -22
- package/test/cases/layer-update/check-layer-removed-from-group.js +0 -33
- package/test/cases/layer-update/check-layer-removed-from-root.js +0 -27
- package/test/cases/layer-update/check-layer-size-after-multiple-calls.js +0 -34
- package/test/cases/layer-update/check-layer-zoom-state.js +0 -54
- package/test/cases/layer-update/index.js +0 -9
- package/test/general.cy.js +0 -61
- package/test/layersUpdate.cy.js +0 -72
|
@@ -1,22 +1,22 @@
|
|
|
1
|
-
(function(D,
|
|
1
|
+
(function(D,C){typeof exports=="object"&&typeof module<"u"?C(exports):typeof define=="function"&&define.amd?define(["exports"],C):(D=typeof globalThis<"u"?globalThis:D||self,C(D["eox-layercontrol"]={}))})(this,function(D){"use strict";var qa=Object.defineProperty;var Ho=D=>{throw TypeError(D)};var Ya=(D,C,B)=>C in D?qa(D,C,{enumerable:!0,configurable:!0,writable:!0,value:B}):D[C]=B;var V=(D,C,B)=>Ya(D,typeof C!="symbol"?C+"":C,B),oi=(D,C,B)=>C.has(D)||Ho("Cannot "+B);var A=(D,C,B)=>(oi(D,C,"read from private field"),B?B.call(D):C.get(D)),O=(D,C,B)=>C.has(D)?Ho("Cannot add the same private member more than once"):C instanceof WeakSet?C.add(D):C.set(D,B),ee=(D,C,B,jt)=>(oi(D,C,"write to private field"),jt?jt.call(D,B):C.set(D,B),B),j=(D,C,B)=>(oi(D,C,"access private method"),B);/**
|
|
2
2
|
* @license
|
|
3
3
|
* Copyright 2019 Google LLC
|
|
4
4
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
5
|
-
*/var Io,We,Ge,
|
|
5
|
+
*/var Io,We,Ge,$t,Qt,$e,xe,ri,Je,Ke,Qe,Vo,tn,en,Ee,nn,on,rn,sn,Pt,bn,Bo,an,ln,dn,un,cn,hn,pn,ko,G,Uo,Fo,si,jo,Zo,vn,fn,gn,Ot,te,zo,Xo,mn;const C=globalThis,B=C.ShadowRoot&&(C.ShadyCSS===void 0||C.ShadyCSS.nativeShadow)&&"adoptedStyleSheets"in Document.prototype&&"replace"in CSSStyleSheet.prototype,jt=Symbol(),ai=new WeakMap;let li=class{constructor(t,n,i){if(this._$cssResult$=!0,i!==jt)throw Error("CSSResult is not constructable. Use `unsafeCSS` or `css` instead.");this.cssText=t,this.t=n}get styleSheet(){let t=this.o;const n=this.t;if(B&&t===void 0){const i=n!==void 0&&n.length===1;i&&(t=ai.get(n)),t===void 0&&((this.o=t=new CSSStyleSheet).replaceSync(this.cssText),i&&ai.set(n,t))}return t}toString(){return this.cssText}};const qo=e=>new li(typeof e=="string"?e:e+"",void 0,jt),di=(e,...t)=>{const n=e.length===1?e[0]:t.reduce((i,o,r)=>i+(s=>{if(s._$cssResult$===!0)return s.cssText;if(typeof s=="number")return s;throw Error("Value passed to 'css' function must be a 'css' function result: "+s+". Use 'unsafeCSS' to pass non-literal values, but take care to ensure page security.")})(o)+e[r+1],e[0]);return new li(n,e,jt)},Yo=(e,t)=>{if(B)e.adoptedStyleSheets=t.map(n=>n instanceof CSSStyleSheet?n:n.styleSheet);else for(const n of t){const i=document.createElement("style"),o=C.litNonce;o!==void 0&&i.setAttribute("nonce",o),i.textContent=n.cssText,e.appendChild(i)}},ui=B?e=>e:e=>e instanceof CSSStyleSheet?(t=>{let n="";for(const i of t.cssRules)n+=i.cssText;return qo(n)})(e):e;/**
|
|
6
6
|
* @license
|
|
7
7
|
* Copyright 2017 Google LLC
|
|
8
8
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
9
|
-
*/const{is:
|
|
9
|
+
*/const{is:Wo,defineProperty:Go,getOwnPropertyDescriptor:Jo,getOwnPropertyNames:Ko,getOwnPropertySymbols:Qo,getPrototypeOf:tr}=Object,Et=globalThis,ci=Et.trustedTypes,er=ci?ci.emptyScript:"",wn=Et.reactiveElementPolyfillSupport,ne=(e,t)=>e,$n={toAttribute(e,t){switch(t){case Boolean:e=e?er:null;break;case Object:case Array:e=e==null?e:JSON.stringify(e)}return e},fromAttribute(e,t){let n=e;switch(t){case Boolean:n=e!==null;break;case Number:n=e===null?null:Number(e);break;case Object:case Array:try{n=JSON.parse(e)}catch{n=null}}return n}},hi=(e,t)=>!Wo(e,t),pi={attribute:!0,type:String,converter:$n,reflect:!1,hasChanged:hi};Symbol.metadata??(Symbol.metadata=Symbol("metadata")),Et.litPropertyMetadata??(Et.litPropertyMetadata=new WeakMap);class Zt extends HTMLElement{static addInitializer(t){this._$Ei(),(this.l??(this.l=[])).push(t)}static get observedAttributes(){return this.finalize(),this._$Eh&&[...this._$Eh.keys()]}static createProperty(t,n=pi){if(n.state&&(n.attribute=!1),this._$Ei(),this.elementProperties.set(t,n),!n.noAccessor){const i=Symbol(),o=this.getPropertyDescriptor(t,i,n);o!==void 0&&Go(this.prototype,t,o)}}static getPropertyDescriptor(t,n,i){const{get:o,set:r}=Jo(this.prototype,t)??{get(){return this[n]},set(s){this[n]=s}};return{get(){return o==null?void 0:o.call(this)},set(s){const a=o==null?void 0:o.call(this);r.call(this,s),this.requestUpdate(t,a,i)},configurable:!0,enumerable:!0}}static getPropertyOptions(t){return this.elementProperties.get(t)??pi}static _$Ei(){if(this.hasOwnProperty(ne("elementProperties")))return;const t=tr(this);t.finalize(),t.l!==void 0&&(this.l=[...t.l]),this.elementProperties=new Map(t.elementProperties)}static finalize(){if(this.hasOwnProperty(ne("finalized")))return;if(this.finalized=!0,this._$Ei(),this.hasOwnProperty(ne("properties"))){const n=this.properties,i=[...Ko(n),...Qo(n)];for(const o of i)this.createProperty(o,n[o])}const t=this[Symbol.metadata];if(t!==null){const n=litPropertyMetadata.get(t);if(n!==void 0)for(const[i,o]of n)this.elementProperties.set(i,o)}this._$Eh=new Map;for(const[n,i]of this.elementProperties){const o=this._$Eu(n,i);o!==void 0&&this._$Eh.set(o,n)}this.elementStyles=this.finalizeStyles(this.styles)}static finalizeStyles(t){const n=[];if(Array.isArray(t)){const i=new Set(t.flat(1/0).reverse());for(const o of i)n.unshift(ui(o))}else t!==void 0&&n.push(ui(t));return n}static _$Eu(t,n){const i=n.attribute;return i===!1?void 0:typeof i=="string"?i:typeof t=="string"?t.toLowerCase():void 0}constructor(){super(),this._$Ep=void 0,this.isUpdatePending=!1,this.hasUpdated=!1,this._$Em=null,this._$Ev()}_$Ev(){var t;this._$ES=new Promise(n=>this.enableUpdating=n),this._$AL=new Map,this._$E_(),this.requestUpdate(),(t=this.constructor.l)==null||t.forEach(n=>n(this))}addController(t){var n;(this._$EO??(this._$EO=new Set)).add(t),this.renderRoot!==void 0&&this.isConnected&&((n=t.hostConnected)==null||n.call(t))}removeController(t){var n;(n=this._$EO)==null||n.delete(t)}_$E_(){const t=new Map,n=this.constructor.elementProperties;for(const i of n.keys())this.hasOwnProperty(i)&&(t.set(i,this[i]),delete this[i]);t.size>0&&(this._$Ep=t)}createRenderRoot(){const t=this.shadowRoot??this.attachShadow(this.constructor.shadowRootOptions);return Yo(t,this.constructor.elementStyles),t}connectedCallback(){var t;this.renderRoot??(this.renderRoot=this.createRenderRoot()),this.enableUpdating(!0),(t=this._$EO)==null||t.forEach(n=>{var i;return(i=n.hostConnected)==null?void 0:i.call(n)})}enableUpdating(t){}disconnectedCallback(){var t;(t=this._$EO)==null||t.forEach(n=>{var i;return(i=n.hostDisconnected)==null?void 0:i.call(n)})}attributeChangedCallback(t,n,i){this._$AK(t,i)}_$EC(t,n){var r;const i=this.constructor.elementProperties.get(t),o=this.constructor._$Eu(t,i);if(o!==void 0&&i.reflect===!0){const s=(((r=i.converter)==null?void 0:r.toAttribute)!==void 0?i.converter:$n).toAttribute(n,i.type);this._$Em=t,s==null?this.removeAttribute(o):this.setAttribute(o,s),this._$Em=null}}_$AK(t,n){var r;const i=this.constructor,o=i._$Eh.get(t);if(o!==void 0&&this._$Em!==o){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:$n;this._$Em=o,this[o]=a.fromAttribute(n,s.type),this._$Em=null}}requestUpdate(t,n,i){if(t!==void 0){if(i??(i=this.constructor.getPropertyOptions(t)),!(i.hasChanged??hi)(this[t],n))return;this.P(t,n,i)}this.isUpdatePending===!1&&(this._$ES=this._$ET())}P(t,n,i){this._$AL.has(t)||this._$AL.set(t,n),i.reflect===!0&&this._$Em!==t&&(this._$Ej??(this._$Ej=new Set)).add(t)}async _$ET(){this.isUpdatePending=!0;try{await this._$ES}catch(n){Promise.reject(n)}const t=this.scheduleUpdate();return t!=null&&await t,!this.isUpdatePending}scheduleUpdate(){return this.performUpdate()}performUpdate(){var i;if(!this.isUpdatePending)return;if(!this.hasUpdated){if(this.renderRoot??(this.renderRoot=this.createRenderRoot()),this._$Ep){for(const[r,s]of this._$Ep)this[r]=s;this._$Ep=void 0}const o=this.constructor.elementProperties;if(o.size>0)for(const[r,s]of o)s.wrapped!==!0||this._$AL.has(r)||this[r]===void 0||this.P(r,this[r],s)}let t=!1;const n=this._$AL;try{t=this.shouldUpdate(n),t?(this.willUpdate(n),(i=this._$EO)==null||i.forEach(o=>{var r;return(r=o.hostUpdate)==null?void 0:r.call(o)}),this.update(n)):this._$EU()}catch(o){throw t=!1,this._$EU(),o}t&&this._$AE(n)}willUpdate(t){}_$AE(t){var n;(n=this._$EO)==null||n.forEach(i=>{var o;return(o=i.hostUpdated)==null?void 0:o.call(i)}),this.hasUpdated||(this.hasUpdated=!0,this.firstUpdated(t)),this.updated(t)}_$EU(){this._$AL=new Map,this.isUpdatePending=!1}get updateComplete(){return this.getUpdateComplete()}getUpdateComplete(){return this._$ES}shouldUpdate(t){return!0}update(t){this._$Ej&&(this._$Ej=this._$Ej.forEach(n=>this._$EC(n,this[n]))),this._$EU()}updated(t){}firstUpdated(t){}}Zt.elementStyles=[],Zt.shadowRootOptions={mode:"open"},Zt[ne("elementProperties")]=new Map,Zt[ne("finalized")]=new Map,wn==null||wn({ReactiveElement:Zt}),(Et.reactiveElementVersions??(Et.reactiveElementVersions=[])).push("2.0.4");/**
|
|
10
10
|
* @license
|
|
11
11
|
* Copyright 2017 Google LLC
|
|
12
12
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
13
|
-
*/const
|
|
14
|
-
\f\r]`,
|
|
15
|
-
\f\r"'\`<>=]|("|')|))|$)`,"g"),bi=/'/g,vi=/"/g,wi=/^(?:script|style|textarea|title)$/i,
|
|
13
|
+
*/const ie=globalThis,Te=ie.trustedTypes,fi=Te?Te.createPolicy("lit-html",{createHTML:e=>e}):void 0,xn="$lit$",gt=`lit$${Math.random().toFixed(9).slice(2)}$`,En="?"+gt,nr=`<${En}>`,Lt=document,oe=()=>Lt.createComment(""),re=e=>e===null||typeof e!="object"&&typeof e!="function",Sn=Array.isArray,gi=e=>Sn(e)||typeof(e==null?void 0:e[Symbol.iterator])=="function",An=`[
|
|
14
|
+
\f\r]`,se=/<(?:(!--|\/[^a-zA-Z])|(\/?[a-zA-Z][^>\s]*)|(\/?$))/g,mi=/-->/g,yi=/>/g,Mt=RegExp(`>|${An}(?:([^\\s"'>=/]+)(${An}*=${An}*(?:[^
|
|
15
|
+
\f\r"'\`<>=]|("|')|))|$)`,"g"),bi=/'/g,vi=/"/g,wi=/^(?:script|style|textarea|title)$/i,ir=e=>(t,...n)=>({_$litType$:e,strings:t,values:n}),$=ir(1),dt=Symbol.for("lit-noChange"),T=Symbol.for("lit-nothing"),$i=new WeakMap,It=Lt.createTreeWalker(Lt,129);function xi(e,t){if(!Sn(e)||!e.hasOwnProperty("raw"))throw Error("invalid template strings array");return fi!==void 0?fi.createHTML(t):t}const Ei=(e,t)=>{const n=e.length-1,i=[];let o,r=t===2?"<svg>":t===3?"<math>":"",s=se;for(let a=0;a<n;a++){const l=e[a];let d,c,u=-1,p=0;for(;p<l.length&&(s.lastIndex=p,c=s.exec(l),c!==null);)p=s.lastIndex,s===se?c[1]==="!--"?s=mi:c[1]!==void 0?s=yi:c[2]!==void 0?(wi.test(c[2])&&(o=RegExp("</"+c[2],"g")),s=Mt):c[3]!==void 0&&(s=Mt):s===Mt?c[0]===">"?(s=o??se,u=-1):c[1]===void 0?u=-2:(u=s.lastIndex-c[2].length,d=c[1],s=c[3]===void 0?Mt:c[3]==='"'?vi:bi):s===vi||s===bi?s=Mt:s===mi||s===yi?s=se:(s=Mt,o=void 0);const f=s===Mt&&e[a+1].startsWith("/>")?" ":"";r+=s===se?l+nr:u>=0?(i.push(d),l.slice(0,u)+xn+l.slice(u)+gt+f):l+gt+(u===-2?a:f)}return[xi(e,r+(e[n]||"<?>")+(t===2?"</svg>":t===3?"</math>":"")),i]};class ae{constructor({strings:t,_$litType$:n},i){let o;this.parts=[];let r=0,s=0;const a=t.length-1,l=this.parts,[d,c]=Ei(t,n);if(this.el=ae.createElement(d,i),It.currentNode=this.el.content,n===2||n===3){const u=this.el.content.firstChild;u.replaceWith(...u.childNodes)}for(;(o=It.nextNode())!==null&&l.length<a;){if(o.nodeType===1){if(o.hasAttributes())for(const u of o.getAttributeNames())if(u.endsWith(xn)){const p=c[s++],f=o.getAttribute(u).split(gt),g=/([.?@])?(.*)/.exec(p);l.push({type:1,index:r,name:g[2],strings:f,ctor:g[1]==="."?Ai:g[1]==="?"?_i:g[1]==="@"?Ci:le}),o.removeAttribute(u)}else u.startsWith(gt)&&(l.push({type:6,index:r}),o.removeAttribute(u));if(wi.test(o.tagName)){const u=o.textContent.split(gt),p=u.length-1;if(p>0){o.textContent=Te?Te.emptyScript:"";for(let f=0;f<p;f++)o.append(u[f],oe()),It.nextNode(),l.push({type:2,index:++r});o.append(u[p],oe())}}}else if(o.nodeType===8)if(o.data===En)l.push({type:2,index:r});else{let u=-1;for(;(u=o.data.indexOf(gt,u+1))!==-1;)l.push({type:7,index:r}),u+=gt.length-1}r++}}static createElement(t,n){const i=Lt.createElement("template");return i.innerHTML=t,i}}function Nt(e,t,n=e,i){var s,a;if(t===dt)return t;let o=i!==void 0?(s=n._$Co)==null?void 0:s[i]:n._$Cl;const r=re(t)?void 0:t._$litDirective$;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._$Co??(n._$Co=[]))[i]=o:n._$Cl=o),o!==void 0&&(t=Nt(e,o._$AS(e,t.values),o,i)),t}let Si=class{constructor(t,n){this._$AV=[],this._$AN=void 0,this._$AD=t,this._$AM=n}get parentNode(){return this._$AM.parentNode}get _$AU(){return this._$AM._$AU}u(t){const{el:{content:n},parts:i}=this._$AD,o=((t==null?void 0:t.creationScope)??Lt).importNode(n,!0);It.currentNode=o;let r=It.nextNode(),s=0,a=0,l=i[0];for(;l!==void 0;){if(s===l.index){let d;l.type===2?d=new zt(r,r.nextSibling,this,t):l.type===1?d=new l.ctor(r,l.name,l.strings,this,t):l.type===6&&(d=new Ti(r,this,t)),this._$AV.push(d),l=i[++a]}s!==(l==null?void 0:l.index)&&(r=It.nextNode(),s++)}return It.currentNode=Lt,o}p(t){let n=0;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++}};class zt{get _$AU(){var t;return((t=this._$AM)==null?void 0:t._$AU)??this._$Cv}constructor(t,n,i,o){this.type=2,this._$AH=T,this._$AN=void 0,this._$AA=t,this._$AB=n,this._$AM=i,this.options=o,this._$Cv=(o==null?void 0:o.isConnected)??!0}get parentNode(){let t=this._$AA.parentNode;const n=this._$AM;return n!==void 0&&(t==null?void 0:t.nodeType)===11&&(t=n.parentNode),t}get startNode(){return this._$AA}get endNode(){return this._$AB}_$AI(t,n=this){t=Nt(this,t,n),re(t)?t===T||t==null||t===""?(this._$AH!==T&&this._$AR(),this._$AH=T):t!==this._$AH&&t!==dt&&this._(t):t._$litType$!==void 0?this.$(t):t.nodeType!==void 0?this.T(t):gi(t)?this.k(t):this._(t)}O(t){return this._$AA.parentNode.insertBefore(t,this._$AB)}T(t){this._$AH!==t&&(this._$AR(),this._$AH=this.O(t))}_(t){this._$AH!==T&&re(this._$AH)?this._$AA.nextSibling.data=t:this.T(Lt.createTextNode(t)),this._$AH=t}$(t){var r;const{values:n,_$litType$:i}=t,o=typeof i=="number"?this._$AC(t):(i.el===void 0&&(i.el=ae.createElement(xi(i.h,i.h[0]),this.options)),i);if(((r=this._$AH)==null?void 0:r._$AD)===o)this._$AH.p(n);else{const s=new Si(o,this),a=s.u(this.options);s.p(n),this.T(a),this._$AH=s}}_$AC(t){let n=$i.get(t.strings);return n===void 0&&$i.set(t.strings,n=new ae(t)),n}k(t){Sn(this._$AH)||(this._$AH=[],this._$AR());const n=this._$AH;let i,o=0;for(const r of t)o===n.length?n.push(i=new zt(this.O(oe()),this.O(oe()),this,this.options)):i=n[o],i._$AI(r),o++;o<n.length&&(this._$AR(i&&i._$AB.nextSibling,o),n.length=o)}_$AR(t=this._$AA.nextSibling,n){var i;for((i=this._$AP)==null?void 0:i.call(this,!1,!0,n);t&&t!==this._$AB;){const o=t.nextSibling;t.remove(),t=o}}setConnected(t){var n;this._$AM===void 0&&(this._$Cv=t,(n=this._$AP)==null||n.call(this,t))}}class le{get tagName(){return this.element.tagName}get _$AU(){return this._$AM._$AU}constructor(t,n,i,o,r){this.type=1,this._$AH=T,this._$AN=void 0,this.element=t,this.name=n,this._$AM=o,this.options=r,i.length>2||i[0]!==""||i[1]!==""?(this._$AH=Array(i.length-1).fill(new String),this.strings=i):this._$AH=T}_$AI(t,n=this,i,o){const r=this.strings;let s=!1;if(r===void 0)t=Nt(this,t,n,0),s=!re(t)||t!==this._$AH&&t!==dt,s&&(this._$AH=t);else{const a=t;let l,d;for(t=r[0],l=0;l<r.length-1;l++)d=Nt(this,a[i+l],n,l),d===dt&&(d=this._$AH[l]),s||(s=!re(d)||d!==this._$AH[l]),d===T?t=T:t!==T&&(t+=(d??"")+r[l+1]),this._$AH[l]=d}s&&!o&&this.j(t)}j(t){t===T?this.element.removeAttribute(this.name):this.element.setAttribute(this.name,t??"")}}class Ai extends le{constructor(){super(...arguments),this.type=3}j(t){this.element[this.name]=t===T?void 0:t}}class _i extends le{constructor(){super(...arguments),this.type=4}j(t){this.element.toggleAttribute(this.name,!!t&&t!==T)}}class Ci extends le{constructor(t,n,i,o,r){super(t,n,i,o,r),this.type=5}_$AI(t,n=this){if((t=Nt(this,t,n,0)??T)===dt)return;const i=this._$AH,o=t===T&&i!==T||t.capture!==i.capture||t.once!==i.once||t.passive!==i.passive,r=t!==T&&(i===T||o);o&&this.element.removeEventListener(this.name,this,i),r&&this.element.addEventListener(this.name,this,t),this._$AH=t}handleEvent(t){var n;typeof this._$AH=="function"?this._$AH.call(((n=this.options)==null?void 0:n.host)??this.element,t):this._$AH.handleEvent(t)}}class Ti{constructor(t,n,i){this.element=t,this.type=6,this._$AN=void 0,this._$AM=n,this.options=i}get _$AU(){return this._$AM._$AU}_$AI(t){Nt(this,t)}}const or={M:xn,P:gt,A:En,C:1,L:Ei,R:Si,D:gi,V:Nt,I:zt,H:le,N:_i,U:Ci,B:Ai,F:Ti},_n=ie.litHtmlPolyfillSupport;_n==null||_n(ae,zt),(ie.litHtmlVersions??(ie.litHtmlVersions=[])).push("3.2.1");const rr=(e,t,n)=>{const i=(n==null?void 0:n.renderBefore)??t;let o=i._$litPart$;if(o===void 0){const r=(n==null?void 0:n.renderBefore)??null;i._$litPart$=o=new zt(t.insertBefore(oe(),r),r,void 0,n??{})}return o._$AI(e),o};/**
|
|
16
16
|
* @license
|
|
17
17
|
* Copyright 2017 Google LLC
|
|
18
18
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
19
|
-
*/
|
|
19
|
+
*/let tt=class extends Zt{constructor(){super(...arguments),this.renderOptions={host:this},this._$Do=void 0}createRenderRoot(){var n;const t=super.createRenderRoot();return(n=this.renderOptions).renderBefore??(n.renderBefore=t.firstChild),t}update(t){const n=this.render();this.hasUpdated||(this.renderOptions.isConnected=this.isConnected),super.update(t),this._$Do=rr(n,this.renderRoot,this.renderOptions)}connectedCallback(){var t;super.connectedCallback(),(t=this._$Do)==null||t.setConnected(!0)}disconnectedCallback(){var t;super.disconnectedCallback(),(t=this._$Do)==null||t.setConnected(!1)}render(){return dt}};tt._$litElement$=!0,tt.finalized=!0,(Io=globalThis.litElementHydrateSupport)==null||Io.call(globalThis,{LitElement:tt});const Cn=globalThis.litElementPolyfillSupport;Cn==null||Cn({LitElement:tt}),(globalThis.litElementVersions??(globalThis.litElementVersions=[])).push("4.1.1");/**
|
|
20
20
|
* @license
|
|
21
21
|
* Copyright 2021 Google LLC
|
|
22
22
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
@@ -24,34 +24,34 @@
|
|
|
24
24
|
* @license
|
|
25
25
|
* Copyright 2017 Google LLC
|
|
26
26
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
27
|
-
*/const St={ATTRIBUTE:1,CHILD:2,PROPERTY:3,BOOLEAN_ATTRIBUTE:4,EVENT:5,ELEMENT:6},Tn=e=>(...t)=>({_$litDirective$:e,values:t});class Pn{constructor(t){}get _$AU(){return this._$AM._$AU}_$AT(t,n,i){this.
|
|
27
|
+
*/const St={ATTRIBUTE:1,CHILD:2,PROPERTY:3,BOOLEAN_ATTRIBUTE:4,EVENT:5,ELEMENT:6},Tn=e=>(...t)=>({_$litDirective$:e,values:t});class Pn{constructor(t){}get _$AU(){return this._$AM._$AU}_$AT(t,n,i){this._$Ct=t,this._$AM=n,this._$Ci=i}_$AS(t,n){return this.update(t,n)}update(t,n){return this.render(...n)}}/**
|
|
28
28
|
* @license
|
|
29
29
|
* Copyright 2020 Google LLC
|
|
30
30
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
31
|
-
*/const{I:
|
|
31
|
+
*/const{I:sr}=or,ar=e=>e.strings===void 0,Pi=()=>document.createComment(""),de=(e,t,n)=>{var r;const i=e._$AA.parentNode,o=t===void 0?e._$AB:t._$AA;if(n===void 0){const s=i.insertBefore(Pi(),o),a=i.insertBefore(Pi(),o);n=new sr(s,a,e,e.options)}else{const s=n._$AB.nextSibling,a=n._$AM,l=a!==e;if(l){let d;(r=n._$AQ)==null||r.call(n,e),n._$AM=e,n._$AP!==void 0&&(d=e._$AU)!==a._$AU&&n._$AP(d)}if(s!==o||l){let d=n._$AA;for(;d!==s;){const c=d.nextSibling;i.insertBefore(d,o),d=c}}}return n},Ht=(e,t,n=e)=>(e._$AI(t,n),e),lr={},Oi=(e,t=lr)=>e._$AH=t,dr=e=>e._$AH,On=e=>{var i;(i=e._$AP)==null||i.call(e,!1,!0);let t=e._$AA;const n=e._$AB.nextSibling;for(;t!==n;){const o=t.nextSibling;t.remove(),t=o}};/**
|
|
32
32
|
* @license
|
|
33
33
|
* Copyright 2017 Google LLC
|
|
34
34
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
35
|
-
*/const Di=(e,t,n)=>{const i=new Map;for(let o=t;o<=n;o++)i.set(e[o],o);return i},
|
|
35
|
+
*/const Di=(e,t,n)=>{const i=new Map;for(let o=t;o<=n;o++)i.set(e[o],o);return i},ur=Tn(class extends Pn{constructor(e){if(super(e),e.type!==St.CHILD)throw Error("repeat() can only be used in text expressions")}dt(e,t,n){let i;n===void 0?n=t:t!==void 0&&(i=t);const o=[],r=[];let s=0;for(const a of e)o[s]=i?i(a,s):s,r[s]=n(a,s),s++;return{values:r,keys:o}}render(e,t,n){return this.dt(e,t,n).values}update(e,[t,n,i]){const o=dr(e),{values:r,keys:s}=this.dt(t,n,i);if(!Array.isArray(o))return this.ut=s,r;const a=this.ut??(this.ut=[]),l=[];let d,c,u=0,p=o.length-1,f=0,g=r.length-1;for(;u<=p&&f<=g;)if(o[u]===null)u++;else if(o[p]===null)p--;else if(a[u]===s[f])l[f]=Ht(o[u],r[f]),u++,f++;else if(a[p]===s[g])l[g]=Ht(o[p],r[g]),p--,g--;else if(a[u]===s[g])l[g]=Ht(o[u],r[g]),de(e,l[g+1],o[u]),u++,g--;else if(a[p]===s[f])l[f]=Ht(o[p],r[f]),de(e,o[u],o[p]),p--,f++;else if(d===void 0&&(d=Di(s,f,g),c=Di(a,u,p)),d.has(a[u]))if(d.has(a[p])){const y=c.get(s[f]),R=y!==void 0?o[y]:null;if(R===null){const H=de(e,o[u]);Ht(H,r[f]),l[f]=H}else l[f]=Ht(R,r[f]),de(e,o[u],R),o[y]=null;f++}else On(o[p]),p--;else On(o[u]),u++;for(;f<=g;){const y=de(e,l[g+1]);Ht(y,r[f]),l[f++]=y}for(;u<=p;){const y=o[u++];y!==null&&On(y)}return this.ut=s,Oi(e,l),dt}});/**
|
|
36
36
|
* wms-capabilities @0.6.0
|
|
37
37
|
* @description WMS service Capabilities > JSON, based on openlayers
|
|
38
38
|
* @license BSD-2-Clause
|
|
39
39
|
* @preserve
|
|
40
|
-
*/var
|
|
40
|
+
*/var E=e=>e!==void 0,Ri=(e,t,n)=>t in e?e[t]:e[t]=n;const ue={ELEMENT:1,ATTRIBUTE:2,TEXT:3,CDATA_SECTION:4,ENTITY_REFERENCE:5,ENTITY:6,PROCESSING_INSTRUCTION:7,COMMENT:8,DOCUMENT:9,DOCUMENT_TYPE:10,DOCUMENT_FRAGMENT:11,NOTATION:12};class cr{constructor(t){this._parser=new t}toDocument(t){return this._parser.parseFromString(t,"application/xml")}getAllTextContent(t,n){return Pe(t,n).join("")}}function Pe(e,t){return Li(e,t,[]).join("")}function Li(e,t,n){if(e.nodeType===ue.CDATA_SECTION||e.nodeType===ue.TEXT)t?n.push(String(e.nodeValue).replace(/(\r\n|\r|\n)/g,"")):n.push(e.nodeValue);else{var i;for(i=e.firstChild;i;i=i.nextSibling)Li(i,t,n)}return n}function hr(e,t,n,i){for(var o=pr(t);o;o=fr(o)){var r=o.namespaceURI||null,s=e[r];if(E(s)){var a=s[o.localName];E(a)&&a.call(i,o,n)}}}function pr(e){let t=e.firstElementChild||e.firstChild;for(;t&&t.nodeType!==ue.ELEMENT;)t=t.nextSibling;return t}function fr(e){let t=e.nextElementSibling||e.nextSibling;for(;t&&t.nodeType!==ue.ELEMENT;)t=t.nextSibling;return t}function q(e,t,n){return gr(e,t,n)}function gr(e,t,n){var i=E(n)?n:{},o,r;for(o=0,r=e.length;o<r;++o)i[e[o]]=t;return i}function Mi(e,t){return function(n,i){var o=e.call(E(t)?t:this,n,i);if(E(o)){var r=i[i.length-1];r.push(o)}}}function X(e,t,n,i,o){return i.push(e),hr(t,n,i,o),i.pop()}function m(e,t,n){return function(i,o){let r=e.call(E(n)?n:this,i,o);if(E(r)){var s=o[o.length-1],a=E(t)?t:i.localName;s[a]=r}}}function ot(e,t,n){return function(i,o){var r=e.call(E(n)?n:this,i,o);if(E(r)){var s=o[o.length-1],a=E(t)?t:i.localName,l=Ri(s,a,[]);l.push(r)}}}const mr=/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g;function yr(e){return e.replace(mr,"")}function Vt(e){const t=/^\s*(true|1)|(false|0)\s*$/.exec(e);if(t)return E(t[1])||!1}function Xt(e){return mt(Pe(e,!1))}function mt(e){const t=/^\s*([+\-]?\d*\.?\d+(?:e[+\-]?\d+)?)\s*$/i.exec(e);if(t)return parseFloat(t[1])}function Dn(e){return Oe(Pe(e,!1))}function Oe(e){const t=/^\s*(\d+)\s*$/.exec(e);if(t)return parseInt(t[1],10)}function _(e){return yr(Pe(e,!1))}const br="http://www.w3.org/1999/xlink";function Rn(e){return e.getAttributeNS(br,"href")}function vr(e,t){return X({},Xr,e,t)}function Ii(e){return[mt(e.getAttribute("minx")),mt(e.getAttribute("miny")),mt(e.getAttribute("maxx")),mt(e.getAttribute("maxy"))]}function wr(e,t){const n=Ii(e),i=[mt(e.getAttribute("resx")),mt(e.getAttribute("resy"))];return{crs:e.getAttribute("CRS")||e.getAttribute("SRS"),extent:n,res:i}}function $r(e,t){const n=Ii(e);if(!(!E(n[0])||!E(n[1])||!E(n[2])||!E(n[3])))return n}function xr(e,t){const n=parseFloat(e.getAttribute("min")),i=parseFloat(e.getAttribute("max"));return{min:n,max:i}}function Er(e,t){const n=X({},qr,e,t);if(!E(n))return;const i=n.westBoundLongitude,o=n.southBoundLatitude,r=n.eastBoundLongitude,s=n.northBoundLatitude;if(!(!E(i)||!E(o)||!E(r)||!E(s)))return[i,o,r,s]}function Sr(e,t){return X({},kr,e,t)}function Ar(e,t){return X({},Ur,e,t)}function _r(e,t){return X({},Fr,e,t)}function Cr(e,t){return X({},jr,e,t)}function Tr(e,t){return X({},Zr,e,t)}function Pr(e,t){return X([],zr,e,t)}function Or(e,t){const n=Vt(e.getAttribute("queryable"));return X({queryable:E(n)?n:!1},Vi,e,t)}function Dr(e,t){var n=t[t.length-1];const i=X({},Vi,e,t);if(!E(i))return;let o=Vt(e.getAttribute("queryable"));E(o)||(o=n.queryable),i.queryable=E(o)?o:!1;let r=Oe(e.getAttribute("cascaded"));E(r)||(r=n.cascaded),i.cascaded=r;let s=Vt(e.getAttribute("opaque"));E(s)||(s=n.opaque),i.opaque=E(s)?s:!1;let a=Vt(e.getAttribute("noSubsets"));E(a)||(a=n.noSubsets),i.noSubsets=E(a)?a:!1;let l=mt(e.getAttribute("fixedWidth"));E(l)||(l=n.fixedWidth),i.fixedWidth=l;let d=mt(e.getAttribute("fixedHeight"));E(d)||(d=n.fixedHeight),i.fixedHeight=d;const c=["Style","CRS","AuthorityURL"];for(let p=0,f=c.length;p<f;p++){const g=c[p],y=n[g];if(E(y)){let R=Ri(i,g,[]);R=R.concat(y),i[g]=R}}const u=["EX_GeographicBoundingBox","BoundingBox","Dimension","Attribution","MinScaleDenominator","MaxScaleDenominator"];for(let p=0,f=u.length;p<f;p++){const g=u[p],y=i[g];if(!E(y)){const R=n[g];i[g]=R}}return i}function Rr(e,t){return{name:e.getAttribute("name"),units:e.getAttribute("units"),unitSymbol:e.getAttribute("unitSymbol"),default:e.getAttribute("default"),multipleValues:Vt(e.getAttribute("multipleValues")),nearestValue:Vt(e.getAttribute("nearestValue")),current:Vt(e.getAttribute("current")),values:_(e)}}function yt(e,t){return X({},Qr,e,t)}function Lr(e,t){return X({},Yr,e,t)}function Mr(e,t){return X({},Gr,e,t)}function Ir(e,t){return X({},Jr,e,t)}function Ln(e,t){return X({},Wr,e,t)}function Ni(e,t){var n=yt(e,t);if(E(n)){const i=[Oe(e.getAttribute("width")),Oe(e.getAttribute("height"))];return n.size=i,n}}function Nr(e,t){var n=yt(e,t);if(E(n))return n.name=e.getAttribute("name"),n}function Hr(e,t){var n=yt(e,t);if(E(n))return n.type=e.getAttribute("type"),n}function Vr(e,t){return X({},Kr,e,t)}function Hi(e,t){return X([],ts,e,t)}const Y=[null,"http://www.opengis.net/wms"],Br=q(Y,{Service:m(Ar),Capability:m(Sr)}),kr=q(Y,{Request:m(Lr),Exception:m(Pr),Layer:m(Or)}),Ur=q(Y,{Name:m(_),Title:m(_),Abstract:m(_),KeywordList:m(Hi),OnlineResource:m(Rn),ContactInformation:m(_r),Fees:m(_),AccessConstraints:m(_),LayerLimit:m(Dn),MaxWidth:m(Dn),MaxHeight:m(Dn)}),Fr=q(Y,{ContactPersonPrimary:m(Cr),ContactPosition:m(_),ContactAddress:m(Tr),ContactVoiceTelephone:m(_),ContactFacsimileTelephone:m(_),ContactElectronicMailAddress:m(_)}),jr=q(Y,{ContactPerson:m(_),ContactOrganization:m(_)}),Zr=q(Y,{AddressType:m(_),Address:m(_),City:m(_),StateOrProvince:m(_),PostCode:m(_),Country:m(_)}),zr=q(Y,{Format:Mi(_)}),Vi=q(Y,{Name:m(_),Title:m(_),Abstract:m(_),KeywordList:m(Hi),CRS:ot(_),SRS:ot(_),EX_GeographicBoundingBox:m(Er),LatLonBoundingBox:m($r),BoundingBox:ot(wr),Dimension:ot(Rr),Attribution:m(vr),AuthorityURL:ot(Nr),Identifier:ot(_),MetadataURL:ot(Hr),DataURL:ot(yt),FeatureListURL:ot(yt),Style:ot(Vr),MinScaleDenominator:m(Xt),MaxScaleDenominator:m(Xt),ScaleHint:m(xr),Layer:ot(Dr)}),Xr=q(Y,{Title:m(_),OnlineResource:m(Rn),LogoURL:m(Ni)}),qr=q(Y,{westBoundLongitude:m(Xt),eastBoundLongitude:m(Xt),southBoundLatitude:m(Xt),northBoundLatitude:m(Xt)}),Yr=q(Y,{GetCapabilities:m(Ln),GetMap:m(Ln),GetFeatureInfo:m(Ln)}),Wr=q(Y,{Format:ot(_),DCPType:ot(Mr)}),Gr=q(Y,{HTTP:m(Ir)}),Jr=q(Y,{Get:m(yt),Post:m(yt)}),Kr=q(Y,{Name:m(_),Title:m(_),Abstract:m(_),LegendURL:ot(Ni),StyleSheetURL:m(yt),StyleURL:m(yt)}),Qr=q(Y,{Format:m(_),OnlineResource:m(Rn)}),ts=q(Y,{Keyword:Mi(_)});class es{constructor(t,n){!n&&typeof window<"u"&&(n=window.DOMParser),this.version=void 0,this._parser=new cr(n),this._data=t}data(t){return this._data=t,this}toJSON(t){return t=t||this._data,this.parse(t)}parse(t){return this.readFromDocument(this._parser.toDocument(t))}readFromDocument(t){for(let n=t.firstChild;n;n=n.nextSibling)if(n.nodeType==ue.ELEMENT)return this.readFromNode(n);return null}readFromNode(t){return this.version=t.getAttribute("version"),X({version:this.version},Br,t,[])||null}}async function ns(e){let t=new URL(e),n=t.searchParams;n.set("SERVICE","WMS"),n.set("REQUEST","GetCapabilities");let i=t.toString();const o=await fetch(i);if(o.ok){const r=await o.text();return new es(r).toJSON()}else throw new Error(`Error: ${o.status}`)}function Mn(e){const t=/\b(?:wms|ows)\b/i,n=/{(?:z|x|y-?)}\/{(?:z|x|y-?)}\/{(?:z|x|y-?)}/i;return t.test(e)?"TileWMS":n.test(e)?"XYZ":!1}function is(e){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=Mn(e);return!!(e&&n&&i)}function Bi(e){return e.replace(/(['"])?([a-zA-Z0-9_]+)(['"])?:/g,'"$2": ').replace(/,\s*}/g,"}").replace(/,\s*]/g,"]").replace(/\s*(\{|}|\[|\]|,)\s*/g,"$1").replaceAll('": //',"://")}function os(e){try{return JSON.parse(Bi(e)),!!e}catch{return!1}}function rs(e,t){const n=new URL(e).searchParams;Object.entries(t).forEach(([s,a])=>{typeof a=="object"&&!Array.isArray(a)&&a!==null?Object.keys(a).forEach(l=>{n.set(l,a[l])}):n.set(s,a)});const i=e.split("?")[0],o=n.toString();return`${i}?${o}`}/**!
|
|
41
41
|
* Sortable 1.15.3
|
|
42
42
|
* @author RubaXa <trash@rubaxa.org>
|
|
43
43
|
* @author owenm <owen23355@gmail.com>
|
|
44
44
|
* @license MIT
|
|
45
|
-
*/function ki(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);t&&(i=i.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),n.push.apply(n,i)}return n}function pt(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?ki(Object(n),!0).forEach(function(i){as(e,i,n[i])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):ki(Object(n)).forEach(function(i){Object.defineProperty(e,i,Object.getOwnPropertyDescriptor(n,i))})}return e}function De(e){"@babel/helpers - typeof";return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?De=function(t){return typeof t}:De=function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},De(e)}function as(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function bt(){return bt=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var i in n)Object.prototype.hasOwnProperty.call(n,i)&&(e[i]=n[i])}return e},bt.apply(this,arguments)}function ls(e,t){if(e==null)return{};var n={},i=Object.keys(e),o,r;for(r=0;r<i.length;r++)o=i[r],!(t.indexOf(o)>=0)&&(n[o]=e[o]);return n}function ds(e,t){if(e==null)return{};var n=ls(e,t),i,o;if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);for(o=0;o<r.length;o++)i=r[o],!(t.indexOf(i)>=0)&&Object.prototype.propertyIsEnumerable.call(e,i)&&(n[i]=e[i])}return n}var us="1.15.3";function vt(e){if(typeof window<"u"&&window.navigator)return!!navigator.userAgent.match(e)}var wt=vt(/(?:Trident.*rv[ :]?11\.|msie|iemobile|Windows Phone)/i),ue=vt(/Edge/i),Ui=vt(/firefox/i),ce=vt(/safari/i)&&!vt(/chrome/i)&&!vt(/android/i),Fi=vt(/iP(ad|od|hone)/i),ji=vt(/chrome/i)&&vt(/android/i),Zi={capture:!1,passive:!1};function P(e,t,n){e.addEventListener(t,n,!wt&&Zi)}function S(e,t,n){e.removeEventListener(t,n,!wt&&Zi)}function Re(e,t){if(t){if(t[0]===">"&&(t=t.substring(1)),e)try{if(e.matches)return e.matches(t);if(e.msMatchesSelector)return e.msMatchesSelector(t);if(e.webkitMatchesSelector)return e.webkitMatchesSelector(t)}catch{return!1}return!1}}function zi(e){return e.host&&e!==document&&e.host.nodeType?e.host:e.parentNode}function ct(e,t,n,i){if(e){n=n||document;do{if(t!=null&&(t[0]===">"?e.parentNode===n&&Re(e,t):Re(e,t))||i&&e===n)return e;if(e===n)break}while(e=zi(e))}return null}var Xi=/\s+/g;function at(e,t,n){if(e&&t)if(e.classList)e.classList[n?"add":"remove"](t);else{var i=(" "+e.className+" ").replace(Xi," ").replace(" "+t+" "," ");e.className=(i+(n?" "+t:"")).replace(Xi," ")}}function v(e,t,n){var i=e&&e.style;if(i){if(n===void 0)return document.defaultView&&document.defaultView.getComputedStyle?n=document.defaultView.getComputedStyle(e,""):e.currentStyle&&(n=e.currentStyle),t===void 0?n:n[t];!(t in i)&&t.indexOf("webkit")===-1&&(t="-webkit-"+t),i[t]=n+(typeof n=="string"?"":"px")}}function Xt(e,t){var n="";if(typeof e=="string")n=e;else do{var i=v(e,"transform");i&&i!=="none"&&(n=i+" "+n)}while(!t&&(e=e.parentNode));var o=window.DOMMatrix||window.WebKitCSSMatrix||window.CSSMatrix||window.MSCSSMatrix;return o&&new o(n)}function qi(e,t,n){if(e){var i=e.getElementsByTagName(t),o=0,r=i.length;if(n)for(;o<r;o++)n(i[o],o);return i}return[]}function ft(){var e=document.scrollingElement;return e||document.documentElement}function U(e,t,n,i,o){if(!(!e.getBoundingClientRect&&e!==window)){var r,s,a,l,d,c,u;if(e!==window&&e.parentNode&&e!==ft()?(r=e.getBoundingClientRect(),s=r.top,a=r.left,l=r.bottom,d=r.right,c=r.height,u=r.width):(s=0,a=0,l=window.innerHeight,d=window.innerWidth,c=window.innerHeight,u=window.innerWidth),(t||n)&&e!==window&&(o=o||e.parentNode,!wt))do if(o&&o.getBoundingClientRect&&(v(o,"transform")!=="none"||n&&v(o,"position")!=="static")){var p=o.getBoundingClientRect();s-=p.top+parseInt(v(o,"border-top-width")),a-=p.left+parseInt(v(o,"border-left-width")),l=s+r.height,d=a+r.width;break}while(o=o.parentNode);if(i&&e!==window){var f=Xt(o||e),g=f&&f.a,y=f&&f.d;f&&(s/=y,a/=g,u/=g,c/=y,l=s+c,d=a+u)}return{top:s,left:a,bottom:l,right:d,width:u,height:c}}}function Yi(e,t,n){for(var i=At(e,!0),o=U(e)[t];i;){var r=U(i)[n],s=void 0;if(s=o>=r,!s)return i;if(i===ft())break;i=At(i,!1)}return!1}function qt(e,t,n,i){for(var o=0,r=0,s=e.children;r<s.length;){if(s[r].style.display!=="none"&&s[r]!==w.ghost&&(i||s[r]!==w.dragged)&&ct(s[r],n.draggable,e,!1)){if(o===t)return s[r];o++}r++}return null}function In(e,t){for(var n=e.lastElementChild;n&&(n===w.ghost||v(n,"display")==="none"||t&&!Re(n,t));)n=n.previousElementSibling;return n||null}function ut(e,t){var n=0;if(!e||!e.parentNode)return-1;for(;e=e.previousElementSibling;)e.nodeName.toUpperCase()!=="TEMPLATE"&&e!==w.clone&&(!t||Re(e,t))&&n++;return n}function Wi(e){var t=0,n=0,i=ft();if(e)do{var o=Xt(e),r=o.a,s=o.d;t+=e.scrollLeft*r,n+=e.scrollTop*s}while(e!==i&&(e=e.parentNode));return[t,n]}function cs(e,t){for(var n in e)if(e.hasOwnProperty(n)){for(var i in t)if(t.hasOwnProperty(i)&&t[i]===e[n][i])return Number(n)}return-1}function At(e,t){if(!e||!e.getBoundingClientRect)return ft();var n=e,i=!1;do if(n.clientWidth<n.scrollWidth||n.clientHeight<n.scrollHeight){var o=v(n);if(n.clientWidth<n.scrollWidth&&(o.overflowX=="auto"||o.overflowX=="scroll")||n.clientHeight<n.scrollHeight&&(o.overflowY=="auto"||o.overflowY=="scroll")){if(!n.getBoundingClientRect||n===document.body)return ft();if(i||t)return n;i=!0}}while(n=n.parentNode);return ft()}function hs(e,t){if(e&&t)for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n]);return e}function Nn(e,t){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)}var he;function Gi(e,t){return function(){if(!he){var n=arguments,i=this;n.length===1?e.call(i,n[0]):e.apply(i,n),he=setTimeout(function(){he=void 0},t)}}}function ps(){clearTimeout(he),he=void 0}function Ji(e,t,n){e.scrollLeft+=t,e.scrollTop+=n}function Ki(e){var t=window.Polymer,n=window.jQuery||window.Zepto;return t&&t.dom?t.dom(e).cloneNode(!0):n?n(e).clone(!0)[0]:e.cloneNode(!0)}function Qi(e,t,n){var i={};return Array.from(e.children).forEach(function(o){var r,s,a,l;if(!(!ct(o,t.draggable,e,!1)||o.animated||o===n)){var d=U(o);i.left=Math.min((r=i.left)!==null&&r!==void 0?r:1/0,d.left),i.top=Math.min((s=i.top)!==null&&s!==void 0?s:1/0,d.top),i.right=Math.max((a=i.right)!==null&&a!==void 0?a:-1/0,d.right),i.bottom=Math.max((l=i.bottom)!==null&&l!==void 0?l:-1/0,d.bottom)}}),i.width=i.right-i.left,i.height=i.bottom-i.top,i.x=i.left,i.y=i.top,i}var rt="Sortable"+new Date().getTime();function fs(){var e=[],t;return{captureAnimationState:function(){if(e=[],!!this.options.animation){var i=[].slice.call(this.el.children);i.forEach(function(o){if(!(v(o,"display")==="none"||o===w.ghost)){e.push({target:o,rect:U(o)});var r=pt({},e[e.length-1].rect);if(o.thisAnimationDuration){var s=Xt(o,!0);s&&(r.top-=s.f,r.left-=s.e)}o.fromRect=r}})}},addAnimationState:function(i){e.push(i)},removeAnimationState:function(i){e.splice(cs(e,{target:i}),1)},animateAll:function(i){var o=this;if(!this.options.animation){clearTimeout(t),typeof i=="function"&&i();return}var r=!1,s=0;e.forEach(function(a){var l=0,d=a.target,c=d.fromRect,u=U(d),p=d.prevFromRect,f=d.prevToRect,g=a.rect,y=Xt(d,!0);y&&(u.top-=y.f,u.left-=y.e),d.toRect=u,d.thisAnimationDuration&&Nn(p,u)&&!Nn(c,u)&&(g.top-u.top)/(g.left-u.left)===(c.top-u.top)/(c.left-u.left)&&(l=ms(g,p,f,o.options)),Nn(u,c)||(d.prevFromRect=c,d.prevToRect=u,l||(l=o.options.animation),o.animate(d,g,u,l)),l&&(r=!0,s=Math.max(s,l),clearTimeout(d.animationResetTimer),d.animationResetTimer=setTimeout(function(){d.animationTime=0,d.prevFromRect=null,d.fromRect=null,d.prevToRect=null,d.thisAnimationDuration=null},l),d.thisAnimationDuration=l)}),clearTimeout(t),r?t=setTimeout(function(){typeof i=="function"&&i()},s):typeof i=="function"&&i(),e=[]},animate:function(i,o,r,s){if(s){v(i,"transition",""),v(i,"transform","");var a=Xt(this.el),l=a&&a.a,d=a&&a.d,c=(o.left-r.left)/(l||1),u=(o.top-r.top)/(d||1);i.animatingX=!!c,i.animatingY=!!u,v(i,"transform","translate3d("+c+"px,"+u+"px,0)"),this.forRepaintDummy=gs(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(){v(i,"transition",""),v(i,"transform",""),i.animated=!1,i.animatingX=!1,i.animatingY=!1},s)}}}}function gs(e){return e.offsetWidth}function ms(e,t,n,i){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}var Yt=[],Hn={initializeByDefault:!0},pe={mount:function(t){for(var n in Hn)Hn.hasOwnProperty(n)&&!(n in t)&&(t[n]=Hn[n]);Yt.forEach(function(i){if(i.pluginName===t.pluginName)throw"Sortable: Cannot mount plugin ".concat(t.pluginName," more than once")}),Yt.push(t)},pluginEvent:function(t,n,i){var o=this;this.eventCanceled=!1,i.cancel=function(){o.eventCanceled=!0};var r=t+"Global";Yt.forEach(function(s){n[s.pluginName]&&(n[s.pluginName][r]&&n[s.pluginName][r](pt({sortable:n},i)),n.options[s.pluginName]&&n[s.pluginName][t]&&n[s.pluginName][t](pt({sortable:n},i)))})},initializePlugins:function(t,n,i,o){Yt.forEach(function(a){var l=a.pluginName;if(!(!t.options[l]&&!a.initializeByDefault)){var d=new a(t,n,t.options);d.sortable=t,d.options=t.options,t[l]=d,bt(i,d.defaults)}});for(var r in t.options)if(t.options.hasOwnProperty(r)){var s=this.modifyOption(t,r,t.options[r]);typeof s<"u"&&(t.options[r]=s)}},getEventProperties:function(t,n){var i={};return Yt.forEach(function(o){typeof o.eventProperties=="function"&&bt(i,o.eventProperties.call(n[o.pluginName],t))}),i},modifyOption:function(t,n,i){var o;return Yt.forEach(function(r){t[r.pluginName]&&r.optionListeners&&typeof r.optionListeners[n]=="function"&&(o=r.optionListeners[n].call(t[r.pluginName],i))}),o}};function ys(e){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,d=e.newIndex,c=e.oldDraggableIndex,u=e.newDraggableIndex,p=e.originalEvent,f=e.putSortable,g=e.extraEventProperties;if(t=t||n&&n[rt],!!t){var y,R=t.options,H="on"+i.charAt(0).toUpperCase()+i.substr(1);window.CustomEvent&&!wt&&!ue?y=new CustomEvent(i,{bubbles:!0,cancelable:!0}):(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=d,y.oldDraggableIndex=c,y.newDraggableIndex=u,y.originalEvent=p,y.pullMode=f?f.lastPutMode:void 0;var k=pt(pt({},g),pe.getEventProperties(i,t));for(var nt in k)y[nt]=k[nt];n&&n.dispatchEvent(y),R[H]&&R[H].call(t,y)}}var bs=["evt"],st=function(t,n){var i=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},o=i.evt,r=ds(i,bs);pe.pluginEvent.bind(w)(t,n,pt({dragEl:h,parentEl:N,ghostEl:E,rootEl:M,nextEl:Bt,lastDownEl:Le,cloneEl:I,cloneHidden:Ct,dragStarted:ge,putSortable:W,activeSortable:w.active,originalEvent:o,oldIndex:Wt,oldDraggableIndex:fe,newIndex:lt,newDraggableIndex:_t,hideGhostForTarget:so,unhideGhostForTarget:ao,cloneNowHidden:function(){Ct=!0},cloneNowShown:function(){Ct=!1},dispatchSortableEvent:function(a){et({sortable:n,name:a,originalEvent:o})}},r))};function et(e){ys(pt({putSortable:W,cloneEl:I,targetEl:h,rootEl:M,oldIndex:Wt,oldDraggableIndex:fe,newIndex:lt,newDraggableIndex:_t},e))}var h,N,E,M,Bt,Le,I,Ct,Wt,lt,fe,_t,Me,W,Gt=!1,Ie=!1,Ne=[],kt,ht,Vn,Bn,to,eo,ge,Jt,me,ye=!1,He=!1,Ve,Q,kn=[],Un=!1,Be=[],ke=typeof document<"u",Ue=Fi,no=ue||wt?"cssFloat":"float",vs=ke&&!ji&&!Fi&&"draggable"in document.createElement("div"),io=function(){if(ke){if(wt)return!1;var e=document.createElement("x");return e.style.cssText="pointer-events:auto",e.style.pointerEvents==="auto"}}(),oo=function(t,n){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),d=a&&parseInt(a.marginLeft)+parseInt(a.marginRight)+U(r).width,c=l&&parseInt(l.marginLeft)+parseInt(l.marginRight)+U(s).width;if(i.display==="flex")return i.flexDirection==="column"||i.flexDirection==="column-reverse"?"vertical":"horizontal";if(i.display==="grid")return i.gridTemplateColumns.split(" ").length<=1?"vertical":"horizontal";if(r&&a.float&&a.float!=="none"){var u=a.float==="left"?"left":"right";return s&&(l.clear==="both"||l.clear===u)?"vertical":"horizontal"}return r&&(a.display==="block"||a.display==="flex"||a.display==="table"||a.display==="grid"||d>=o&&i[no]==="none"||s&&i[no]==="none"&&d+c>o)?"vertical":"horizontal"},ws=function(t,n,i){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,d=i?n.width:n.height;return o===a||r===l||o+s/2===a+d/2},xs=function(t,n){var i;return Ne.some(function(o){var r=o[rt].options.emptyInsertThreshold;if(!(!r||In(o))){var s=U(o),a=t>=s.left-r&&t<=s.right+r,l=n>=s.top-r&&n<=s.bottom+r;if(a&&l)return i=o}}),i},ro=function(t){function n(r,s){return function(a,l,d,c){var u=a.options.group.name&&l.options.group.name&&a.options.group.name===l.options.group.name;if(r==null&&(s||u))return!0;if(r==null||r===!1)return!1;if(s&&r==="clone")return r;if(typeof r=="function")return n(r(a,l,d,c),s)(a,l,d,c);var p=(s?a:l).options.group.name;return r===!0||typeof r=="string"&&r===p||r.join&&r.indexOf(p)>-1}}var i={},o=t.group;(!o||De(o)!="object")&&(o={name:o}),i.name=o.name,i.checkPull=n(o.pull,!0),i.checkPut=n(o.put),i.revertClone=o.revertClone,t.group=i},so=function(){!io&&E&&v(E,"display","none")},ao=function(){!io&&E&&v(E,"display","")};ke&&!ji&&document.addEventListener("click",function(e){if(Ie)return e.preventDefault(),e.stopPropagation&&e.stopPropagation(),e.stopImmediatePropagation&&e.stopImmediatePropagation(),Ie=!1,!1},!0);var Ut=function(t){if(h){t=t.touches?t.touches[0]:t;var n=xs(t.clientX,t.clientY);if(n){var i={};for(var o in t)t.hasOwnProperty(o)&&(i[o]=t[o]);i.target=i.rootEl=n,i.preventDefault=void 0,i.stopPropagation=void 0,n[rt]._onDragOver(i)}}},Es=function(t){h&&h.parentNode[rt]._isOutsideThisEl(t.target)};function w(e,t){if(!(e&&e.nodeType&&e.nodeType===1))throw"Sortable: `el` must be an HTMLElement, not ".concat({}.toString.call(e));this.el=e,this.options=t=bt({},t),e[rt]=this;var n={group:null,sort:!0,disabled:!1,store:null,handle:null,draggable:/^[uo]l$/i.test(e.nodeName)?">li":">*",swapThreshold:1,invertSwap:!1,invertedSwapThreshold:null,removeCloneOnHide:!0,direction:function(){return oo(e,this.options)},ghostClass:"sortable-ghost",chosenClass:"sortable-chosen",dragClass:"sortable-drag",ignore:"a, img",filter:null,preventOnFilter:!0,animation:0,easing:null,setData:function(s,a){s.setData("Text",a.textContent)},dropBubble:!1,dragoverBubble:!1,dataIdAttr:"data-id",delay:0,delayOnTouchOnly:!1,touchStartThreshold:(Number.parseInt?Number:window).parseInt(window.devicePixelRatio,10)||1,forceFallback:!1,fallbackClass:"sortable-fallback",fallbackOnBody:!1,fallbackTolerance:0,fallbackOffset:{x:0,y:0},supportPointer:w.supportPointer!==!1&&"PointerEvent"in window&&!ce,emptyInsertThreshold:5};pe.initializePlugins(this,e,n);for(var i in n)!(i in t)&&(t[i]=n[i]);ro(t);for(var o in this)o.charAt(0)==="_"&&typeof this[o]=="function"&&(this[o]=this[o].bind(this));this.nativeDraggable=t.forceFallback?!1:vs,this.nativeDraggable&&(this.options.touchStartThreshold=1),t.supportPointer?P(e,"pointerdown",this._onTapStart):(P(e,"mousedown",this._onTapStart),P(e,"touchstart",this._onTapStart)),this.nativeDraggable&&(P(e,"dragover",this),P(e,"dragenter",this)),Ne.push(this.el),t.store&&t.store.get&&this.sort(t.store.get(this)||[]),bt(this,fs())}w.prototype={constructor:w,_isOutsideThisEl:function(t){!this.el.contains(t)&&t!==this.el&&(Jt=null)},_getDirection:function(t,n){return typeof this.options.direction=="function"?this.options.direction.call(this,t,n,h):this.options.direction},_onTapStart:function(t){if(t.cancelable){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,d=t.target.shadowRoot&&(t.path&&t.path[0]||t.composedPath&&t.composedPath()[0])||l,c=o.filter;if(Os(i),!h&&!(/mousedown|pointerdown/.test(s)&&t.button!==0||o.disabled)&&!d.isContentEditable&&!(!this.nativeDraggable&&ce&&l&&l.tagName.toUpperCase()==="SELECT")&&(l=ct(l,o.draggable,i,!1),!(l&&l.animated)&&Le!==l)){if(Wt=ut(l),fe=ut(l,o.draggable),typeof c=="function"){if(c.call(this,t,l,this)){et({sortable:n,rootEl:d,name:"filter",targetEl:l,toEl:i,fromEl:i}),st("filter",n,{evt:t}),r&&t.cancelable&&t.preventDefault();return}}else if(c&&(c=c.split(",").some(function(u){if(u=ct(d,u.trim(),i,!1),u)return et({sortable:n,rootEl:u,name:"filter",targetEl:l,fromEl:i,toEl:i}),st("filter",n,{evt:t}),!0}),c)){r&&t.cancelable&&t.preventDefault();return}o.handle&&!ct(d,o.handle,i,!1)||this._prepareDragStart(t,a,l)}}},_prepareDragStart:function(t,n,i){var o=this,r=o.el,s=o.options,a=r.ownerDocument,l;if(i&&!h&&i.parentNode===r){var d=U(i);if(M=r,h=i,N=h.parentNode,Bt=h.nextSibling,Le=i,Me=s.group,w.dragged=h,kt={target:h,clientX:(n||t).clientX,clientY:(n||t).clientY},to=kt.clientX-d.left,eo=kt.clientY-d.top,this._lastX=(n||t).clientX,this._lastY=(n||t).clientY,h.style["will-change"]="all",l=function(){if(st("delayEnded",o,{evt:t}),w.eventCanceled){o._onDrop();return}o._disableDelayedDragEvents(),!Ui&&o.nativeDraggable&&(h.draggable=!0),o._triggerDragStart(t,n),et({sortable:o,name:"choose",originalEvent:t}),at(h,s.chosenClass,!0)},s.ignore.split(",").forEach(function(c){qi(h,c.trim(),Fn)}),P(a,"dragover",Ut),P(a,"mousemove",Ut),P(a,"touchmove",Ut),P(a,"mouseup",o._onDrop),P(a,"touchend",o._onDrop),P(a,"touchcancel",o._onDrop),Ui&&this.nativeDraggable&&(this.options.touchStartThreshold=4,h.draggable=!0),st("delayStart",this,{evt:t}),s.delay&&(!s.delayOnTouchOnly||n)&&(!this.nativeDraggable||!(ue||wt))){if(w.eventCanceled){this._onDrop();return}P(a,"mouseup",o._disableDelayedDrag),P(a,"touchend",o._disableDelayedDrag),P(a,"touchcancel",o._disableDelayedDrag),P(a,"mousemove",o._delayedDragTouchMoveHandler),P(a,"touchmove",o._delayedDragTouchMoveHandler),s.supportPointer&&P(a,"pointermove",o._delayedDragTouchMoveHandler),o._dragStartTimer=setTimeout(l,s.delay)}else l()}},_delayedDragTouchMoveHandler:function(t){var n=t.touches?t.touches[0]:t;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()},_disableDelayedDrag:function(){h&&Fn(h),clearTimeout(this._dragStartTimer),this._disableDelayedDragEvents()},_disableDelayedDragEvents:function(){var t=this.el.ownerDocument;S(t,"mouseup",this._disableDelayedDrag),S(t,"touchend",this._disableDelayedDrag),S(t,"touchcancel",this._disableDelayedDrag),S(t,"mousemove",this._delayedDragTouchMoveHandler),S(t,"touchmove",this._delayedDragTouchMoveHandler),S(t,"pointermove",this._delayedDragTouchMoveHandler)},_triggerDragStart:function(t,n){n=n||t.pointerType=="touch"&&t,!this.nativeDraggable||n?this.options.supportPointer?P(document,"pointermove",this._onTouchMove):n?P(document,"touchmove",this._onTouchMove):P(document,"mousemove",this._onTouchMove):(P(h,"dragend",this),P(M,"dragstart",this._onDragStart));try{document.selection?je(function(){document.selection.empty()}):window.getSelection().removeAllRanges()}catch{}},_dragStarted:function(t,n){if(Gt=!1,M&&h){st("dragStarted",this,{evt:n}),this.nativeDraggable&&P(document,"dragover",Es);var i=this.options;!t&&at(h,i.dragClass,!1),at(h,i.ghostClass,!0),w.active=this,t&&this._appendGhost(),et({sortable:this,name:"start",originalEvent:n})}else this._nulling()},_emulateDragOver:function(){if(ht){this._lastX=ht.clientX,this._lastY=ht.clientY,so();for(var t=document.elementFromPoint(ht.clientX,ht.clientY),n=t;t&&t.shadowRoot&&(t=t.shadowRoot.elementFromPoint(ht.clientX,ht.clientY),t!==n);)n=t;if(h.parentNode[rt]._isOutsideThisEl(t),n)do{if(n[rt]){var i=void 0;if(i=n[rt]._onDragOver({clientX:ht.clientX,clientY:ht.clientY,target:t,rootEl:n}),i&&!this.options.dragoverBubble)break}t=n}while(n=zi(n));ao()}},_onTouchMove:function(t){if(kt){var n=this.options,i=n.fallbackTolerance,o=n.fallbackOffset,r=t.touches?t.touches[0]:t,s=E&&Xt(E,!0),a=E&&s&&s.a,l=E&&s&&s.d,d=Ue&&Q&&Wi(Q),c=(r.clientX-kt.clientX+o.x)/(a||1)+(d?d[0]-kn[0]:0)/(a||1),u=(r.clientY-kt.clientY+o.y)/(l||1)+(d?d[1]-kn[1]:0)/(l||1);if(!w.active&&!Gt){if(i&&Math.max(Math.abs(r.clientX-this._lastX),Math.abs(r.clientY-this._lastY))<i)return;this._onDragStart(t,!0)}if(E){s?(s.e+=c-(Vn||0),s.f+=u-(Bn||0)):s={a:1,b:0,c:0,d:1,e:c,f:u};var p="matrix(".concat(s.a,",").concat(s.b,",").concat(s.c,",").concat(s.d,",").concat(s.e,",").concat(s.f,")");v(E,"webkitTransform",p),v(E,"mozTransform",p),v(E,"msTransform",p),v(E,"transform",p),Vn=c,Bn=u,ht=r}t.cancelable&&t.preventDefault()}},_appendGhost:function(){if(!E){var t=this.options.fallbackOnBody?document.body:M,n=U(h,!0,Ue,!0,t),i=this.options;if(Ue){for(Q=t;v(Q,"position")==="static"&&v(Q,"transform")==="none"&&Q!==document;)Q=Q.parentNode;Q!==document.body&&Q!==document.documentElement?(Q===document&&(Q=ft()),n.top+=Q.scrollTop,n.left+=Q.scrollLeft):Q=ft(),kn=Wi(Q)}E=h.cloneNode(!0),at(E,i.ghostClass,!1),at(E,i.fallbackClass,!0),at(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",Ue?"absolute":"fixed"),v(E,"zIndex","100000"),v(E,"pointerEvents","none"),w.ghost=E,t.appendChild(E),v(E,"transform-origin",to/parseInt(E.style.width)*100+"% "+eo/parseInt(E.style.height)*100+"%")}},_onDragStart:function(t,n){var i=this,o=t.dataTransfer,r=i.options;if(st("dragStart",this,{evt:t}),w.eventCanceled){this._onDrop();return}st("setupClone",this),w.eventCanceled||(I=Ki(h),I.removeAttribute("id"),I.draggable=!1,I.style["will-change"]="",this._hideClone(),at(I,this.options.chosenClass,!1),w.clone=I),i.cloneId=je(function(){st("clone",i),!w.eventCanceled&&(i.options.removeCloneOnHide||M.insertBefore(I,h),i._hideClone(),et({sortable:i,name:"clone"}))}),!n&&at(h,r.dragClass,!0),n?(Ie=!0,i._loopId=setInterval(i._emulateDragOver,50)):(S(document,"mouseup",i._onDrop),S(document,"touchend",i._onDrop),S(document,"touchcancel",i._onDrop),o&&(o.effectAllowed="move",r.setData&&r.setData.call(i,o,h)),P(document,"drop",i),v(h,"transform","translateZ(0)")),Gt=!0,i._dragStartId=je(i._dragStarted.bind(i,n,t)),P(document,"selectstart",i),ge=!0,ce&&v(document.body,"user-select","none")},_onDragOver:function(t){var n=this.el,i=t.target,o,r,s,a=this.options,l=a.group,d=w.active,c=Me===l,u=a.sort,p=W||d,f,g=this,y=!1;if(Un)return;function R(Ce,Xa){st(Ce,g,pt({evt:t,isOwner:c,axis:f?"vertical":"horizontal",revert:s,dragRect:o,targetRect:r,canSort:u,fromSortable:p,target:i,completed:k,onMove:function(No,qa){return Fe(M,n,h,o,No,U(No),t,qa)},changed:nt},Xa))}function H(){R("dragOverAnimationCapture"),g.captureAnimationState(),g!==p&&p.captureAnimationState()}function k(Ce){return R("dragOverCompleted",{insertion:Ce}),Ce&&(c?d._hideClone():d._showClone(g),g!==p&&(at(h,W?W.options.ghostClass:d.options.ghostClass,!1),at(h,a.ghostClass,!0)),W!==g&&g!==w.active?W=g:g===w.active&&W&&(W=null),p===g&&(g._ignoreWhileAnimating=i),g.animateAll(function(){R("dragOverAnimationComplete"),g._ignoreWhileAnimating=null}),g!==p&&(p.animateAll(),p._ignoreWhileAnimating=null)),(i===h&&!h.animated||i===n&&!i.animated)&&(Jt=null),!a.dragoverBubble&&!t.rootEl&&i!==document&&(h.parentNode[rt]._isOutsideThisEl(t.target),!Ce&&Ut(t)),!a.dragoverBubble&&t.stopPropagation&&t.stopPropagation(),y=!0}function nt(){lt=ut(h),_t=ut(h,a.draggable),et({sortable:g,name:"change",toEl:n,newIndex:lt,newDraggableIndex:_t,originalEvent:t})}if(t.preventDefault!==void 0&&t.cancelable&&t.preventDefault(),i=ct(i,a.draggable,n,!0),R("dragOver"),w.eventCanceled)return y;if(h.contains(t.target)||i.animated&&i.animatingX&&i.animatingY||g._ignoreWhileAnimating===i)return k(!1);if(Ie=!1,d&&!a.disabled&&(c?u||(s=N!==M):W===this||(this.lastPutMode=Me.checkPull(this,d,h,t))&&l.checkPut(this,d,h,t))){if(f=this._getDirection(t,i)==="vertical",o=U(h),R("dragOverValid"),w.eventCanceled)return y;if(s)return N=M,H(),this._hideClone(),R("revert"),w.eventCanceled||(Bt?M.insertBefore(h,Bt):M.appendChild(h)),k(!0);var J=In(n,a.draggable);if(!J||Cs(t,f,this)&&!J.animated){if(J===h)return k(!1);if(J&&n===t.target&&(i=J),i&&(r=U(i)),Fe(M,n,h,o,i,r,t,!!i)!==!1)return H(),J&&J.nextSibling?n.insertBefore(h,J.nextSibling):n.appendChild(h),N=n,nt(),k(!0)}else if(J&&As(t,f,this)){var it=qt(n,0,a,!0);if(it===h)return k(!1);if(i=it,r=U(i),Fe(M,n,h,o,i,r,t,!1)!==!1)return H(),n.insertBefore(h,it),N=n,nt(),k(!0)}else if(i.parentNode===n){r=U(i);var b=0,L,K=h.parentNode!==n,z=!ws(h.animated&&h.toRect||o,i.animated&&i.toRect||r,f),$e=f?"top":"left",Dt=Yi(i,"top","top")||Yi(h,"top","top"),Se=Dt?Dt.scrollTop:void 0;Jt!==i&&(L=r[$e],ye=!1,He=!z&&a.invertSwap||K),b=_s(t,i,r,f,z?1:a.swapThreshold,a.invertedSwapThreshold==null?a.swapThreshold:a.invertedSwapThreshold,He,Jt===i);var Et;if(b!==0){var Ft=ut(h);do Ft-=b,Et=N.children[Ft];while(Et&&(v(Et,"display")==="none"||Et===E))}if(b===0||Et===i)return k(!1);Jt=i,me=b;var Ae=i.nextElementSibling,Rt=!1;Rt=b===1;var yn=Fe(M,n,h,o,i,r,t,Rt);if(yn!==!1)return(yn===1||yn===-1)&&(Rt=yn===1),Un=!0,setTimeout(Ss,30),H(),Rt&&!Ae?n.appendChild(h):i.parentNode.insertBefore(h,Rt?Ae:i),Dt&&Ji(Dt,0,Se-Dt.scrollTop),N=h.parentNode,L!==void 0&&!He&&(Ve=Math.abs(L-U(i)[$e])),nt(),k(!0)}if(n.contains(h))return k(!1)}return!1},_ignoreWhileAnimating:null,_offMoveEvents:function(){S(document,"mousemove",this._onTouchMove),S(document,"touchmove",this._onTouchMove),S(document,"pointermove",this._onTouchMove),S(document,"dragover",Ut),S(document,"mousemove",Ut),S(document,"touchmove",Ut)},_offUpEvents:function(){var t=this.el.ownerDocument;S(t,"mouseup",this._onDrop),S(t,"touchend",this._onDrop),S(t,"pointerup",this._onDrop),S(t,"touchcancel",this._onDrop),S(document,"selectstart",this)},_onDrop:function(t){var n=this.el,i=this.options;if(lt=ut(h),_t=ut(h,i.draggable),st("drop",this,{evt:t}),N=h&&h.parentNode,lt=ut(h),_t=ut(h,i.draggable),w.eventCanceled){this._nulling();return}Gt=!1,He=!1,ye=!1,clearInterval(this._loopId),clearTimeout(this._dragStartTimer),jn(this.cloneId),jn(this._dragStartId),this.nativeDraggable&&(S(document,"drop",this),S(n,"dragstart",this._onDragStart)),this._offMoveEvents(),this._offUpEvents(),ce&&v(document.body,"user-select",""),v(h,"transform",""),t&&(ge&&(t.cancelable&&t.preventDefault(),!i.dropBubble&&t.stopPropagation()),E&&E.parentNode&&E.parentNode.removeChild(E),(M===N||W&&W.lastPutMode!=="clone")&&I&&I.parentNode&&I.parentNode.removeChild(I),h&&(this.nativeDraggable&&S(h,"dragend",this),Fn(h),h.style["will-change"]="",ge&&!Gt&&at(h,W?W.options.ghostClass:this.options.ghostClass,!1),at(h,this.options.chosenClass,!1),et({sortable:this,name:"unchoose",toEl:N,newIndex:null,newDraggableIndex:null,originalEvent:t}),M!==N?(lt>=0&&(et({rootEl:N,name:"add",toEl:N,fromEl:M,originalEvent:t}),et({sortable:this,name:"remove",toEl:N,originalEvent:t}),et({rootEl:N,name:"sort",toEl:N,fromEl:M,originalEvent:t}),et({sortable:this,name:"sort",toEl:N,originalEvent:t})),W&&W.save()):lt!==Wt&<>=0&&(et({sortable:this,name:"update",toEl:N,originalEvent:t}),et({sortable:this,name:"sort",toEl:N,originalEvent:t})),w.active&&((lt==null||lt===-1)&&(lt=Wt,_t=fe),et({sortable:this,name:"end",toEl:N,originalEvent:t}),this.save()))),this._nulling()},_nulling:function(){st("nulling",this),M=h=N=E=Bt=I=Le=Ct=kt=ht=ge=lt=_t=Wt=fe=Jt=me=W=Me=w.dragged=w.ghost=w.clone=w.active=null,Be.forEach(function(t){t.checked=!0}),Be.length=Vn=Bn=0},handleEvent:function(t){switch(t.type){case"drop":case"dragend":this._onDrop(t);break;case"dragenter":case"dragover":h&&(this._onDragOver(t),$s(t));break;case"selectstart":t.preventDefault();break}},toArray:function(){for(var t=[],n,i=this.el.children,o=0,r=i.length,s=this.options;o<r;o++)n=i[o],ct(n,s.draggable,this.el,!1)&&t.push(n.getAttribute(s.dataIdAttr)||Ps(n));return t},sort:function(t,n){var i={},o=this.el;this.toArray().forEach(function(r,s){var a=o.children[s];ct(a,this.options.draggable,o,!1)&&(i[r]=a)},this),n&&this.captureAnimationState(),t.forEach(function(r){i[r]&&(o.removeChild(i[r]),o.appendChild(i[r]))}),n&&this.animateAll()},save:function(){var t=this.options.store;t&&t.set&&t.set(this)},closest:function(t,n){return ct(t,n||this.options.draggable,this.el,!1)},option:function(t,n){var i=this.options;if(n===void 0)return i[t];var o=pe.modifyOption(this,t,n);typeof o<"u"?i[t]=o:i[t]=n,t==="group"&&ro(i)},destroy:function(){st("destroy",this);var t=this.el;t[rt]=null,S(t,"mousedown",this._onTapStart),S(t,"touchstart",this._onTapStart),S(t,"pointerdown",this._onTapStart),this.nativeDraggable&&(S(t,"dragover",this),S(t,"dragenter",this)),Array.prototype.forEach.call(t.querySelectorAll("[draggable]"),function(n){n.removeAttribute("draggable")}),this._onDrop(),this._disableDelayedDragEvents(),Ne.splice(Ne.indexOf(this.el),1),this.el=t=null},_hideClone:function(){if(!Ct){if(st("hideClone",this),w.eventCanceled)return;v(I,"display","none"),this.options.removeCloneOnHide&&I.parentNode&&I.parentNode.removeChild(I),Ct=!0}},_showClone:function(t){if(t.lastPutMode!=="clone"){this._hideClone();return}if(Ct){if(st("showClone",this),w.eventCanceled)return;h.parentNode==M&&!this.options.group.revertClone?M.insertBefore(I,h):Bt?M.insertBefore(I,Bt):M.appendChild(I),this.options.group.revertClone&&this.animate(h,I),v(I,"display",""),Ct=!1}}};function $s(e){e.dataTransfer&&(e.dataTransfer.dropEffect="move"),e.cancelable&&e.preventDefault()}function Fe(e,t,n,i,o,r,s,a){var l,d=e[rt],c=d.options.onMove,u;return window.CustomEvent&&!wt&&!ue?l=new CustomEvent("move",{bubbles:!0,cancelable:!0}):(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||U(t),l.willInsertAfter=a,l.originalEvent=s,e.dispatchEvent(l),c&&(u=c.call(d,l,s)),u}function Fn(e){e.draggable=!1}function Ss(){Un=!1}function As(e,t,n){var i=U(qt(n.el,0,n.options,!0)),o=Qi(n.el,n.options,E),r=10;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}function Cs(e,t,n){var i=U(In(n.el,n.options.draggable)),o=Qi(n.el,n.options,E),r=10;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}function _s(e,t,n,i,o,r,s,a){var l=i?e.clientY:e.clientX,d=i?n.height:n.width,c=i?n.top:n.left,u=i?n.bottom:n.right,p=!1;if(!s){if(a&&Ve<d*o){if(!ye&&(me===1?l>c+d*r/2:l<u-d*r/2)&&(ye=!0),ye)p=!0;else if(me===1?l<c+Ve:l>u-Ve)return-me}else if(l>c+d*(1-o)/2&&l<u-d*(1-o)/2)return Ts(t)}return p=p||s,p&&(l<c+d*r/2||l>u-d*r/2)?l>c+d/2?1:-1:0}function Ts(e){return ut(h)<ut(e)?1:-1}function Ps(e){for(var t=e.tagName+e.className+e.src+e.href+e.textContent,n=t.length,i=0;n--;)i+=t.charCodeAt(n);return i.toString(36)}function Os(e){Be.length=0;for(var t=e.getElementsByTagName("input"),n=t.length;n--;){var i=t[n];i.checked&&Be.push(i)}}function je(e){return setTimeout(e,0)}function jn(e){return clearTimeout(e)}ke&&P(document,"touchmove",function(e){(w.active||Gt)&&e.cancelable&&e.preventDefault()}),w.utils={on:P,off:S,css:v,find:qi,is:function(t,n){return!!ct(t,n,t,!1)},extend:hs,throttle:Gi,closest:ct,toggleClass:at,clone:Ki,index:ut,nextTick:je,cancelNextTick:jn,detectDirection:oo,getChild:qt,expando:rt},w.get=function(e){return e[rt]},w.mount=function(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];t[0].constructor===Array&&(t=t[0]),t.forEach(function(i){if(!i.prototype||!i.prototype.constructor)throw"Sortable: Mounted plugin must be a constructor function, not ".concat({}.toString.call(i));i.utils&&(w.utils=pt(pt({},w.utils),i.utils)),pe.mount(i)})},w.create=function(e,t){return new w(e,t)},w.version=us;var F=[],be,Zn,zn=!1,Xn,qn,Ze,ve;function Ds(){function e(){this.defaults={scroll:!0,forceAutoScrollFallback:!1,scrollSensitivity:30,scrollSpeed:10,bubbleScroll:!0};for(var t in this)t.charAt(0)==="_"&&typeof this[t]=="function"&&(this[t]=this[t].bind(this))}return e.prototype={dragStarted:function(n){var i=n.originalEvent;this.sortable.nativeDraggable?P(document,"dragover",this._handleAutoScroll):this.options.supportPointer?P(document,"pointermove",this._handleFallbackAutoScroll):i.touches?P(document,"touchmove",this._handleFallbackAutoScroll):P(document,"mousemove",this._handleFallbackAutoScroll)},dragOverCompleted:function(n){var i=n.originalEvent;!this.options.dragOverBubble&&!i.rootEl&&this._handleAutoScroll(i)},drop:function(){this.sortable.nativeDraggable?S(document,"dragover",this._handleAutoScroll):(S(document,"pointermove",this._handleFallbackAutoScroll),S(document,"touchmove",this._handleFallbackAutoScroll),S(document,"mousemove",this._handleFallbackAutoScroll)),lo(),ze(),ps()},nulling:function(){Ze=Zn=be=zn=ve=Xn=qn=null,F.length=0},_handleFallbackAutoScroll:function(n){this._handleAutoScroll(n,!0)},_handleAutoScroll:function(n,i){var o=this,r=(n.touches?n.touches[0]:n).clientX,s=(n.touches?n.touches[0]:n).clientY,a=document.elementFromPoint(r,s);if(Ze=n,i||this.options.forceAutoScrollFallback||ue||wt||ce){Yn(n,this.options,a,i);var l=At(a,!0);zn&&(!ve||r!==Xn||s!==qn)&&(ve&&lo(),ve=setInterval(function(){var d=At(document.elementFromPoint(r,s),!0);d!==l&&(l=d,ze()),Yn(n,o.options,d,i)},10),Xn=r,qn=s)}else{if(!this.options.bubbleScroll||At(a,!0)===ft()){ze();return}Yn(n,this.options,At(a,!1),!1)}}},bt(e,{pluginName:"scroll",initializeByDefault:!0})}function ze(){F.forEach(function(e){clearInterval(e.pid)}),F=[]}function lo(){clearInterval(ve)}var Yn=Gi(function(e,t,n,i){if(t.scroll){var o=(e.touches?e.touches[0]:e).clientX,r=(e.touches?e.touches[0]:e).clientY,s=t.scrollSensitivity,a=t.scrollSpeed,l=ft(),d=!1,c;Zn!==n&&(Zn=n,ze(),be=t.scroll,c=t.scrollFn,be===!0&&(be=At(n,!0)));var u=0,p=be;do{var f=p,g=U(f),y=g.top,R=g.bottom,H=g.left,k=g.right,nt=g.width,J=g.height,it=void 0,b=void 0,L=f.scrollWidth,K=f.scrollHeight,z=v(f),$e=f.scrollLeft,Dt=f.scrollTop;f===l?(it=nt<L&&(z.overflowX==="auto"||z.overflowX==="scroll"||z.overflowX==="visible"),b=J<K&&(z.overflowY==="auto"||z.overflowY==="scroll"||z.overflowY==="visible")):(it=nt<L&&(z.overflowX==="auto"||z.overflowX==="scroll"),b=J<K&&(z.overflowY==="auto"||z.overflowY==="scroll"));var Se=it&&(Math.abs(k-o)<=s&&$e+nt<L)-(Math.abs(H-o)<=s&&!!$e),Et=b&&(Math.abs(R-r)<=s&&Dt+J<K)-(Math.abs(y-r)<=s&&!!Dt);if(!F[u])for(var Ft=0;Ft<=u;Ft++)F[Ft]||(F[Ft]={});(F[u].vx!=Se||F[u].vy!=Et||F[u].el!==f)&&(F[u].el=f,F[u].vx=Se,F[u].vy=Et,clearInterval(F[u].pid),(Se!=0||Et!=0)&&(d=!0,F[u].pid=setInterval((function(){i&&this.layer===0&&w.active._onTouchMove(Ze);var Ae=F[this.layer].vy?F[this.layer].vy*a:0,Rt=F[this.layer].vx?F[this.layer].vx*a:0;typeof c=="function"&&c.call(w.dragged.parentNode[rt],Rt,Ae,e,Ze,F[this.layer].el)!=="continue"||Ji(F[this.layer].el,Rt,Ae)}).bind({layer:u}),24))),u++}while(t.bubbleScroll&&p!==l&&(p=At(p,!1)));zn=d}},30),uo=function(t){var n=t.originalEvent,i=t.putSortable,o=t.dragEl,r=t.activeSortable,s=t.dispatchSortableEvent,a=t.hideGhostForTarget,l=t.unhideGhostForTarget;if(n){var d=i||r;a();var c=n.changedTouches&&n.changedTouches.length?n.changedTouches[0]:n,u=document.elementFromPoint(c.clientX,c.clientY);l(),d&&!d.el.contains(u)&&(s("spill"),this.onSpill({dragEl:o,putSortable:i}))}};function Wn(){}Wn.prototype={startIndex:null,dragStart:function(t){var n=t.oldDraggableIndex;this.startIndex=n},onSpill:function(t){var n=t.dragEl,i=t.putSortable;this.sortable.captureAnimationState(),i&&i.captureAnimationState();var o=qt(this.sortable.el,this.startIndex,this.options);o?this.sortable.el.insertBefore(n,o):this.sortable.el.appendChild(n),this.sortable.animateAll(),i&&i.animateAll()},drop:uo},bt(Wn,{pluginName:"revertOnSpill"});function Gn(){}Gn.prototype={onSpill:function(t){var n=t.dragEl,i=t.putSortable,o=i||this.sortable;o.captureAnimationState(),n.parentNode&&n.parentNode.removeChild(n),o.animateAll()},drop:uo},bt(Gn,{pluginName:"removeOnSpill"}),w.mount(new Ds),w.mount(Gn,Wn);const Rs=e=>{const t=e.item;let n=Array.prototype.slice.call(t.parentNode.childNodes);return n=n.filter(i=>i.nodeType!=Node.ELEMENT_NODE||!i.classList.contains("sortable-fallback")),n},Ls=(e,t,n,i,o,r)=>{const a=e.item.parentNode;for(const y of n)a.appendChild(y);if(e.oldIndex==e.newIndex)return;const l=i.getArray(),d=e.item.querySelector("eox-layercontrol-layer").layer.get(o),c=l.find(y=>y.get(o)===d),u=r.dataset.layer,p=l.find(y=>y.get(o)==u);let f,g;for(f=0;f<l.length;f++)if(l[f]==c){i.removeAt(f);break}for(g=0;g<l.length;g++)if(l[g]===p){f>g?i.insertAt(g,c):i.insertAt(g+1,c);break}t.requestUpdate()};function Ms(e,t,n,i){let o=[],r=null;e._sortable=w.create(e,{handle:".drag-handle",filter:".drag-handle.disabled",swapThreshold:.5,animation:150,easing:"cubic-bezier(1, 0, 0, 1)",onStart:s=>o=Rs(s),onMove:s=>{r=s.related},onEnd:s=>Ls(s,i,o,t,n,r)})}function Is(e,t,n,i){const o=e.getArray();let r=!1;o.forEach(s=>{const a=s.ol_uid;s.get(t)||(s.set(t,a),r=!0),s.get(n)||(s.set(n,`layer ${a}`),r=!0),r&&i.requestUpdate()})}function Jn(e,t,n){let i=[];const o=(r,s,a)=>{i=[...i,...r.filter(d=>d.get(s)===a)];const l=r.filter(d=>d.getLayers);return l.length>0&&l.forEach(d=>o(d.getLayers().getArray(),s,a)),i};return o(e,t,n),i}function Ns(e,t,n){if(!e||!t)return!1;if(!co(e,n))return!0;const i=e.get("minZoom"),o=e.get("maxZoom"),r=t.getView().getZoom();return r>i&&r<o}function co(e,t){const n=e.get("minZoom"),i=e.get("maxZoom");return!!(t&&(n!==-1/0||i!==1/0))}function Hs(e,t){var o,r,s;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(e.getSource?(r=e.getSource())==null?void 0:r.ol_uid:void 0))?"draw":e.declutter_!==void 0?"vector":"raster"}const Vs=(e,t,n)=>{let i=t;return n.layer.getSource().getTileUrlFunction()&&(i||(i=n.layer.getSource().getTileUrlFunction()),n.layer.getSource().setTileUrlFunction((...o)=>ss(i(...o),e)),n.layer.getSource().setKey(new Date)),i};function Bs(e,t,n){const i="updateStyleVariables"in t,o="setStyle"in t,r=i?t.style_:n.style;let s=r==null?void 0:r.variables;if(s){const a=Kn(e);if(r.variables={...s,...a},i)t.updateStyleVariables(a);else if(o){const l=ks(r);t.setStyle(l)}}}const Kn=e=>{const t={};for(const n in e)if(typeof e[n]=="object"&&e[n]!==null){const i=Kn(e[n]);for(const o in i)t[o]=i==null?void 0:i[o]}else t[n]=e==null?void 0:e[n];return t};function ks(e){let t=e;if("variables"in e){let n=JSON.stringify(e);const{variables:i}=e;for(const o in i)typeof i[o]=="number"?n=n.replaceAll(`["var","${o}"]`,i[o]):n=n.replaceAll(`["var","${o}"]`,`"${i[o]}"`);t=JSON.parse(n)}return t}const Us=(e,t)=>{var n;if(e)return!("domainProperties"in e)||"domain"in e?{...e}:(n=Object.keys(e))==null?void 0:n.reduce((i,o)=>{if(o==="domainProperties"){const r=Kn(t);i.domain=e[o].map(s=>r[s])}else i[o]=e[o];return i},{})};function ho(e,t){var i;let n={};for(const o in e){const r=e[o].type;if(r&&r!=="object")n[o]=r==="number"?Number(t[o]):t[o];else if(typeof e[o]=="object"&&((i=e[o])!=null&&i.properties)){const s=ho(e[o].properties,t);Object.keys(s).length>0&&(n[o]=s)}}return n}function Fs(e,t){var r,s,a,l,d;if(!t)return null;let n={},i="updateStyleVariables"in e?(r=e.style_)==null?void 0:r.variables:(s=t.style)==null?void 0:s.variables;if((t.type==="style"||t.style)&&i)n=i;else if((l=(a=e.getSource())==null?void 0:a.getTileUrlFunction)!=null&&l.call(a)){const c=new URL(e.getSource().getTileUrlFunction()([0,0,0]));n=Object.fromEntries(c.searchParams.entries())}else return null;const o=ho(((d=t.schema)==null?void 0:d.properties)||t.schema,n);return Object.keys(o).length?o:null}const js=(e,t)=>e==null?void 0:e.filter(n=>["remove","sort"].filter(i=>t!=null&&t.get("layerControlDisable")?i!=="sort":!0).includes(n)),Zs=(e,t)=>e==null?void 0:e.filter(n=>{let i=!0;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")),n==="legend"&&(i=t.get("layerLegend")),i}),zs=(e,t)=>x`
|
|
45
|
+
*/function ki(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);t&&(i=i.filter(function(o){return Object.getOwnPropertyDescriptor(e,o).enumerable})),n.push.apply(n,i)}return n}function pt(e){for(var t=1;t<arguments.length;t++){var n=arguments[t]!=null?arguments[t]:{};t%2?ki(Object(n),!0).forEach(function(i){ss(e,i,n[i])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):ki(Object(n)).forEach(function(i){Object.defineProperty(e,i,Object.getOwnPropertyDescriptor(n,i))})}return e}function De(e){"@babel/helpers - typeof";return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?De=function(t){return typeof t}:De=function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},De(e)}function ss(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function bt(){return bt=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var i in n)Object.prototype.hasOwnProperty.call(n,i)&&(e[i]=n[i])}return e},bt.apply(this,arguments)}function as(e,t){if(e==null)return{};var n={},i=Object.keys(e),o,r;for(r=0;r<i.length;r++)o=i[r],!(t.indexOf(o)>=0)&&(n[o]=e[o]);return n}function ls(e,t){if(e==null)return{};var n=as(e,t),i,o;if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);for(o=0;o<r.length;o++)i=r[o],!(t.indexOf(i)>=0)&&Object.prototype.propertyIsEnumerable.call(e,i)&&(n[i]=e[i])}return n}var ds="1.15.3";function vt(e){if(typeof window<"u"&&window.navigator)return!!navigator.userAgent.match(e)}var wt=vt(/(?:Trident.*rv[ :]?11\.|msie|iemobile|Windows Phone)/i),ce=vt(/Edge/i),Ui=vt(/firefox/i),he=vt(/safari/i)&&!vt(/chrome/i)&&!vt(/android/i),Fi=vt(/iP(ad|od|hone)/i),ji=vt(/chrome/i)&&vt(/android/i),Zi={capture:!1,passive:!1};function P(e,t,n){e.addEventListener(t,n,!wt&&Zi)}function S(e,t,n){e.removeEventListener(t,n,!wt&&Zi)}function Re(e,t){if(t){if(t[0]===">"&&(t=t.substring(1)),e)try{if(e.matches)return e.matches(t);if(e.msMatchesSelector)return e.msMatchesSelector(t);if(e.webkitMatchesSelector)return e.webkitMatchesSelector(t)}catch{return!1}return!1}}function zi(e){return e.host&&e!==document&&e.host.nodeType?e.host:e.parentNode}function ct(e,t,n,i){if(e){n=n||document;do{if(t!=null&&(t[0]===">"?e.parentNode===n&&Re(e,t):Re(e,t))||i&&e===n)return e;if(e===n)break}while(e=zi(e))}return null}var Xi=/\s+/g;function at(e,t,n){if(e&&t)if(e.classList)e.classList[n?"add":"remove"](t);else{var i=(" "+e.className+" ").replace(Xi," ").replace(" "+t+" "," ");e.className=(i+(n?" "+t:"")).replace(Xi," ")}}function v(e,t,n){var i=e&&e.style;if(i){if(n===void 0)return document.defaultView&&document.defaultView.getComputedStyle?n=document.defaultView.getComputedStyle(e,""):e.currentStyle&&(n=e.currentStyle),t===void 0?n:n[t];!(t in i)&&t.indexOf("webkit")===-1&&(t="-webkit-"+t),i[t]=n+(typeof n=="string"?"":"px")}}function qt(e,t){var n="";if(typeof e=="string")n=e;else do{var i=v(e,"transform");i&&i!=="none"&&(n=i+" "+n)}while(!t&&(e=e.parentNode));var o=window.DOMMatrix||window.WebKitCSSMatrix||window.CSSMatrix||window.MSCSSMatrix;return o&&new o(n)}function qi(e,t,n){if(e){var i=e.getElementsByTagName(t),o=0,r=i.length;if(n)for(;o<r;o++)n(i[o],o);return i}return[]}function ft(){var e=document.scrollingElement;return e||document.documentElement}function U(e,t,n,i,o){if(!(!e.getBoundingClientRect&&e!==window)){var r,s,a,l,d,c,u;if(e!==window&&e.parentNode&&e!==ft()?(r=e.getBoundingClientRect(),s=r.top,a=r.left,l=r.bottom,d=r.right,c=r.height,u=r.width):(s=0,a=0,l=window.innerHeight,d=window.innerWidth,c=window.innerHeight,u=window.innerWidth),(t||n)&&e!==window&&(o=o||e.parentNode,!wt))do if(o&&o.getBoundingClientRect&&(v(o,"transform")!=="none"||n&&v(o,"position")!=="static")){var p=o.getBoundingClientRect();s-=p.top+parseInt(v(o,"border-top-width")),a-=p.left+parseInt(v(o,"border-left-width")),l=s+r.height,d=a+r.width;break}while(o=o.parentNode);if(i&&e!==window){var f=qt(o||e),g=f&&f.a,y=f&&f.d;f&&(s/=y,a/=g,u/=g,c/=y,l=s+c,d=a+u)}return{top:s,left:a,bottom:l,right:d,width:u,height:c}}}function Yi(e,t,n){for(var i=At(e,!0),o=U(e)[t];i;){var r=U(i)[n],s=void 0;if(s=o>=r,!s)return i;if(i===ft())break;i=At(i,!1)}return!1}function Yt(e,t,n,i){for(var o=0,r=0,s=e.children;r<s.length;){if(s[r].style.display!=="none"&&s[r]!==w.ghost&&(i||s[r]!==w.dragged)&&ct(s[r],n.draggable,e,!1)){if(o===t)return s[r];o++}r++}return null}function In(e,t){for(var n=e.lastElementChild;n&&(n===w.ghost||v(n,"display")==="none"||t&&!Re(n,t));)n=n.previousElementSibling;return n||null}function ut(e,t){var n=0;if(!e||!e.parentNode)return-1;for(;e=e.previousElementSibling;)e.nodeName.toUpperCase()!=="TEMPLATE"&&e!==w.clone&&(!t||Re(e,t))&&n++;return n}function Wi(e){var t=0,n=0,i=ft();if(e)do{var o=qt(e),r=o.a,s=o.d;t+=e.scrollLeft*r,n+=e.scrollTop*s}while(e!==i&&(e=e.parentNode));return[t,n]}function us(e,t){for(var n in e)if(e.hasOwnProperty(n)){for(var i in t)if(t.hasOwnProperty(i)&&t[i]===e[n][i])return Number(n)}return-1}function At(e,t){if(!e||!e.getBoundingClientRect)return ft();var n=e,i=!1;do if(n.clientWidth<n.scrollWidth||n.clientHeight<n.scrollHeight){var o=v(n);if(n.clientWidth<n.scrollWidth&&(o.overflowX=="auto"||o.overflowX=="scroll")||n.clientHeight<n.scrollHeight&&(o.overflowY=="auto"||o.overflowY=="scroll")){if(!n.getBoundingClientRect||n===document.body)return ft();if(i||t)return n;i=!0}}while(n=n.parentNode);return ft()}function cs(e,t){if(e&&t)for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n]);return e}function Nn(e,t){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)}var pe;function Gi(e,t){return function(){if(!pe){var n=arguments,i=this;n.length===1?e.call(i,n[0]):e.apply(i,n),pe=setTimeout(function(){pe=void 0},t)}}}function hs(){clearTimeout(pe),pe=void 0}function Ji(e,t,n){e.scrollLeft+=t,e.scrollTop+=n}function Ki(e){var t=window.Polymer,n=window.jQuery||window.Zepto;return t&&t.dom?t.dom(e).cloneNode(!0):n?n(e).clone(!0)[0]:e.cloneNode(!0)}function Qi(e,t,n){var i={};return Array.from(e.children).forEach(function(o){var r,s,a,l;if(!(!ct(o,t.draggable,e,!1)||o.animated||o===n)){var d=U(o);i.left=Math.min((r=i.left)!==null&&r!==void 0?r:1/0,d.left),i.top=Math.min((s=i.top)!==null&&s!==void 0?s:1/0,d.top),i.right=Math.max((a=i.right)!==null&&a!==void 0?a:-1/0,d.right),i.bottom=Math.max((l=i.bottom)!==null&&l!==void 0?l:-1/0,d.bottom)}}),i.width=i.right-i.left,i.height=i.bottom-i.top,i.x=i.left,i.y=i.top,i}var rt="Sortable"+new Date().getTime();function ps(){var e=[],t;return{captureAnimationState:function(){if(e=[],!!this.options.animation){var i=[].slice.call(this.el.children);i.forEach(function(o){if(!(v(o,"display")==="none"||o===w.ghost)){e.push({target:o,rect:U(o)});var r=pt({},e[e.length-1].rect);if(o.thisAnimationDuration){var s=qt(o,!0);s&&(r.top-=s.f,r.left-=s.e)}o.fromRect=r}})}},addAnimationState:function(i){e.push(i)},removeAnimationState:function(i){e.splice(us(e,{target:i}),1)},animateAll:function(i){var o=this;if(!this.options.animation){clearTimeout(t),typeof i=="function"&&i();return}var r=!1,s=0;e.forEach(function(a){var l=0,d=a.target,c=d.fromRect,u=U(d),p=d.prevFromRect,f=d.prevToRect,g=a.rect,y=qt(d,!0);y&&(u.top-=y.f,u.left-=y.e),d.toRect=u,d.thisAnimationDuration&&Nn(p,u)&&!Nn(c,u)&&(g.top-u.top)/(g.left-u.left)===(c.top-u.top)/(c.left-u.left)&&(l=gs(g,p,f,o.options)),Nn(u,c)||(d.prevFromRect=c,d.prevToRect=u,l||(l=o.options.animation),o.animate(d,g,u,l)),l&&(r=!0,s=Math.max(s,l),clearTimeout(d.animationResetTimer),d.animationResetTimer=setTimeout(function(){d.animationTime=0,d.prevFromRect=null,d.fromRect=null,d.prevToRect=null,d.thisAnimationDuration=null},l),d.thisAnimationDuration=l)}),clearTimeout(t),r?t=setTimeout(function(){typeof i=="function"&&i()},s):typeof i=="function"&&i(),e=[]},animate:function(i,o,r,s){if(s){v(i,"transition",""),v(i,"transform","");var a=qt(this.el),l=a&&a.a,d=a&&a.d,c=(o.left-r.left)/(l||1),u=(o.top-r.top)/(d||1);i.animatingX=!!c,i.animatingY=!!u,v(i,"transform","translate3d("+c+"px,"+u+"px,0)"),this.forRepaintDummy=fs(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(){v(i,"transition",""),v(i,"transform",""),i.animated=!1,i.animatingX=!1,i.animatingY=!1},s)}}}}function fs(e){return e.offsetWidth}function gs(e,t,n,i){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}var Wt=[],Hn={initializeByDefault:!0},fe={mount:function(t){for(var n in Hn)Hn.hasOwnProperty(n)&&!(n in t)&&(t[n]=Hn[n]);Wt.forEach(function(i){if(i.pluginName===t.pluginName)throw"Sortable: Cannot mount plugin ".concat(t.pluginName," more than once")}),Wt.push(t)},pluginEvent:function(t,n,i){var o=this;this.eventCanceled=!1,i.cancel=function(){o.eventCanceled=!0};var r=t+"Global";Wt.forEach(function(s){n[s.pluginName]&&(n[s.pluginName][r]&&n[s.pluginName][r](pt({sortable:n},i)),n.options[s.pluginName]&&n[s.pluginName][t]&&n[s.pluginName][t](pt({sortable:n},i)))})},initializePlugins:function(t,n,i,o){Wt.forEach(function(a){var l=a.pluginName;if(!(!t.options[l]&&!a.initializeByDefault)){var d=new a(t,n,t.options);d.sortable=t,d.options=t.options,t[l]=d,bt(i,d.defaults)}});for(var r in t.options)if(t.options.hasOwnProperty(r)){var s=this.modifyOption(t,r,t.options[r]);typeof s<"u"&&(t.options[r]=s)}},getEventProperties:function(t,n){var i={};return Wt.forEach(function(o){typeof o.eventProperties=="function"&&bt(i,o.eventProperties.call(n[o.pluginName],t))}),i},modifyOption:function(t,n,i){var o;return Wt.forEach(function(r){t[r.pluginName]&&r.optionListeners&&typeof r.optionListeners[n]=="function"&&(o=r.optionListeners[n].call(t[r.pluginName],i))}),o}};function ms(e){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,d=e.newIndex,c=e.oldDraggableIndex,u=e.newDraggableIndex,p=e.originalEvent,f=e.putSortable,g=e.extraEventProperties;if(t=t||n&&n[rt],!!t){var y,R=t.options,H="on"+i.charAt(0).toUpperCase()+i.substr(1);window.CustomEvent&&!wt&&!ce?y=new CustomEvent(i,{bubbles:!0,cancelable:!0}):(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=d,y.oldDraggableIndex=c,y.newDraggableIndex=u,y.originalEvent=p,y.pullMode=f?f.lastPutMode:void 0;var k=pt(pt({},g),fe.getEventProperties(i,t));for(var nt in k)y[nt]=k[nt];n&&n.dispatchEvent(y),R[H]&&R[H].call(t,y)}}var ys=["evt"],st=function(t,n){var i=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},o=i.evt,r=ls(i,ys);fe.pluginEvent.bind(w)(t,n,pt({dragEl:h,parentEl:N,ghostEl:x,rootEl:M,nextEl:Bt,lastDownEl:Le,cloneEl:I,cloneHidden:_t,dragStarted:me,putSortable:W,activeSortable:w.active,originalEvent:o,oldIndex:Gt,oldDraggableIndex:ge,newIndex:lt,newDraggableIndex:Ct,hideGhostForTarget:so,unhideGhostForTarget:ao,cloneNowHidden:function(){_t=!0},cloneNowShown:function(){_t=!1},dispatchSortableEvent:function(a){et({sortable:n,name:a,originalEvent:o})}},r))};function et(e){ms(pt({putSortable:W,cloneEl:I,targetEl:h,rootEl:M,oldIndex:Gt,oldDraggableIndex:ge,newIndex:lt,newDraggableIndex:Ct},e))}var h,N,x,M,Bt,Le,I,_t,Gt,lt,ge,Ct,Me,W,Jt=!1,Ie=!1,Ne=[],kt,ht,Vn,Bn,to,eo,me,Kt,ye,be=!1,He=!1,Ve,Q,kn=[],Un=!1,Be=[],ke=typeof document<"u",Ue=Fi,no=ce||wt?"cssFloat":"float",bs=ke&&!ji&&!Fi&&"draggable"in document.createElement("div"),io=function(){if(ke){if(wt)return!1;var e=document.createElement("x");return e.style.cssText="pointer-events:auto",e.style.pointerEvents==="auto"}}(),oo=function(t,n){var i=v(t),o=parseInt(i.width)-parseInt(i.paddingLeft)-parseInt(i.paddingRight)-parseInt(i.borderLeftWidth)-parseInt(i.borderRightWidth),r=Yt(t,0,n),s=Yt(t,1,n),a=r&&v(r),l=s&&v(s),d=a&&parseInt(a.marginLeft)+parseInt(a.marginRight)+U(r).width,c=l&&parseInt(l.marginLeft)+parseInt(l.marginRight)+U(s).width;if(i.display==="flex")return i.flexDirection==="column"||i.flexDirection==="column-reverse"?"vertical":"horizontal";if(i.display==="grid")return i.gridTemplateColumns.split(" ").length<=1?"vertical":"horizontal";if(r&&a.float&&a.float!=="none"){var u=a.float==="left"?"left":"right";return s&&(l.clear==="both"||l.clear===u)?"vertical":"horizontal"}return r&&(a.display==="block"||a.display==="flex"||a.display==="table"||a.display==="grid"||d>=o&&i[no]==="none"||s&&i[no]==="none"&&d+c>o)?"vertical":"horizontal"},vs=function(t,n,i){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,d=i?n.width:n.height;return o===a||r===l||o+s/2===a+d/2},ws=function(t,n){var i;return Ne.some(function(o){var r=o[rt].options.emptyInsertThreshold;if(!(!r||In(o))){var s=U(o),a=t>=s.left-r&&t<=s.right+r,l=n>=s.top-r&&n<=s.bottom+r;if(a&&l)return i=o}}),i},ro=function(t){function n(r,s){return function(a,l,d,c){var u=a.options.group.name&&l.options.group.name&&a.options.group.name===l.options.group.name;if(r==null&&(s||u))return!0;if(r==null||r===!1)return!1;if(s&&r==="clone")return r;if(typeof r=="function")return n(r(a,l,d,c),s)(a,l,d,c);var p=(s?a:l).options.group.name;return r===!0||typeof r=="string"&&r===p||r.join&&r.indexOf(p)>-1}}var i={},o=t.group;(!o||De(o)!="object")&&(o={name:o}),i.name=o.name,i.checkPull=n(o.pull,!0),i.checkPut=n(o.put),i.revertClone=o.revertClone,t.group=i},so=function(){!io&&x&&v(x,"display","none")},ao=function(){!io&&x&&v(x,"display","")};ke&&!ji&&document.addEventListener("click",function(e){if(Ie)return e.preventDefault(),e.stopPropagation&&e.stopPropagation(),e.stopImmediatePropagation&&e.stopImmediatePropagation(),Ie=!1,!1},!0);var Ut=function(t){if(h){t=t.touches?t.touches[0]:t;var n=ws(t.clientX,t.clientY);if(n){var i={};for(var o in t)t.hasOwnProperty(o)&&(i[o]=t[o]);i.target=i.rootEl=n,i.preventDefault=void 0,i.stopPropagation=void 0,n[rt]._onDragOver(i)}}},$s=function(t){h&&h.parentNode[rt]._isOutsideThisEl(t.target)};function w(e,t){if(!(e&&e.nodeType&&e.nodeType===1))throw"Sortable: `el` must be an HTMLElement, not ".concat({}.toString.call(e));this.el=e,this.options=t=bt({},t),e[rt]=this;var n={group:null,sort:!0,disabled:!1,store:null,handle:null,draggable:/^[uo]l$/i.test(e.nodeName)?">li":">*",swapThreshold:1,invertSwap:!1,invertedSwapThreshold:null,removeCloneOnHide:!0,direction:function(){return oo(e,this.options)},ghostClass:"sortable-ghost",chosenClass:"sortable-chosen",dragClass:"sortable-drag",ignore:"a, img",filter:null,preventOnFilter:!0,animation:0,easing:null,setData:function(s,a){s.setData("Text",a.textContent)},dropBubble:!1,dragoverBubble:!1,dataIdAttr:"data-id",delay:0,delayOnTouchOnly:!1,touchStartThreshold:(Number.parseInt?Number:window).parseInt(window.devicePixelRatio,10)||1,forceFallback:!1,fallbackClass:"sortable-fallback",fallbackOnBody:!1,fallbackTolerance:0,fallbackOffset:{x:0,y:0},supportPointer:w.supportPointer!==!1&&"PointerEvent"in window&&!he,emptyInsertThreshold:5};fe.initializePlugins(this,e,n);for(var i in n)!(i in t)&&(t[i]=n[i]);ro(t);for(var o in this)o.charAt(0)==="_"&&typeof this[o]=="function"&&(this[o]=this[o].bind(this));this.nativeDraggable=t.forceFallback?!1:bs,this.nativeDraggable&&(this.options.touchStartThreshold=1),t.supportPointer?P(e,"pointerdown",this._onTapStart):(P(e,"mousedown",this._onTapStart),P(e,"touchstart",this._onTapStart)),this.nativeDraggable&&(P(e,"dragover",this),P(e,"dragenter",this)),Ne.push(this.el),t.store&&t.store.get&&this.sort(t.store.get(this)||[]),bt(this,ps())}w.prototype={constructor:w,_isOutsideThisEl:function(t){!this.el.contains(t)&&t!==this.el&&(Kt=null)},_getDirection:function(t,n){return typeof this.options.direction=="function"?this.options.direction.call(this,t,n,h):this.options.direction},_onTapStart:function(t){if(t.cancelable){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,d=t.target.shadowRoot&&(t.path&&t.path[0]||t.composedPath&&t.composedPath()[0])||l,c=o.filter;if(Ps(i),!h&&!(/mousedown|pointerdown/.test(s)&&t.button!==0||o.disabled)&&!d.isContentEditable&&!(!this.nativeDraggable&&he&&l&&l.tagName.toUpperCase()==="SELECT")&&(l=ct(l,o.draggable,i,!1),!(l&&l.animated)&&Le!==l)){if(Gt=ut(l),ge=ut(l,o.draggable),typeof c=="function"){if(c.call(this,t,l,this)){et({sortable:n,rootEl:d,name:"filter",targetEl:l,toEl:i,fromEl:i}),st("filter",n,{evt:t}),r&&t.cancelable&&t.preventDefault();return}}else if(c&&(c=c.split(",").some(function(u){if(u=ct(d,u.trim(),i,!1),u)return et({sortable:n,rootEl:u,name:"filter",targetEl:l,fromEl:i,toEl:i}),st("filter",n,{evt:t}),!0}),c)){r&&t.cancelable&&t.preventDefault();return}o.handle&&!ct(d,o.handle,i,!1)||this._prepareDragStart(t,a,l)}}},_prepareDragStart:function(t,n,i){var o=this,r=o.el,s=o.options,a=r.ownerDocument,l;if(i&&!h&&i.parentNode===r){var d=U(i);if(M=r,h=i,N=h.parentNode,Bt=h.nextSibling,Le=i,Me=s.group,w.dragged=h,kt={target:h,clientX:(n||t).clientX,clientY:(n||t).clientY},to=kt.clientX-d.left,eo=kt.clientY-d.top,this._lastX=(n||t).clientX,this._lastY=(n||t).clientY,h.style["will-change"]="all",l=function(){if(st("delayEnded",o,{evt:t}),w.eventCanceled){o._onDrop();return}o._disableDelayedDragEvents(),!Ui&&o.nativeDraggable&&(h.draggable=!0),o._triggerDragStart(t,n),et({sortable:o,name:"choose",originalEvent:t}),at(h,s.chosenClass,!0)},s.ignore.split(",").forEach(function(c){qi(h,c.trim(),Fn)}),P(a,"dragover",Ut),P(a,"mousemove",Ut),P(a,"touchmove",Ut),P(a,"mouseup",o._onDrop),P(a,"touchend",o._onDrop),P(a,"touchcancel",o._onDrop),Ui&&this.nativeDraggable&&(this.options.touchStartThreshold=4,h.draggable=!0),st("delayStart",this,{evt:t}),s.delay&&(!s.delayOnTouchOnly||n)&&(!this.nativeDraggable||!(ce||wt))){if(w.eventCanceled){this._onDrop();return}P(a,"mouseup",o._disableDelayedDrag),P(a,"touchend",o._disableDelayedDrag),P(a,"touchcancel",o._disableDelayedDrag),P(a,"mousemove",o._delayedDragTouchMoveHandler),P(a,"touchmove",o._delayedDragTouchMoveHandler),s.supportPointer&&P(a,"pointermove",o._delayedDragTouchMoveHandler),o._dragStartTimer=setTimeout(l,s.delay)}else l()}},_delayedDragTouchMoveHandler:function(t){var n=t.touches?t.touches[0]:t;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()},_disableDelayedDrag:function(){h&&Fn(h),clearTimeout(this._dragStartTimer),this._disableDelayedDragEvents()},_disableDelayedDragEvents:function(){var t=this.el.ownerDocument;S(t,"mouseup",this._disableDelayedDrag),S(t,"touchend",this._disableDelayedDrag),S(t,"touchcancel",this._disableDelayedDrag),S(t,"mousemove",this._delayedDragTouchMoveHandler),S(t,"touchmove",this._delayedDragTouchMoveHandler),S(t,"pointermove",this._delayedDragTouchMoveHandler)},_triggerDragStart:function(t,n){n=n||t.pointerType=="touch"&&t,!this.nativeDraggable||n?this.options.supportPointer?P(document,"pointermove",this._onTouchMove):n?P(document,"touchmove",this._onTouchMove):P(document,"mousemove",this._onTouchMove):(P(h,"dragend",this),P(M,"dragstart",this._onDragStart));try{document.selection?je(function(){document.selection.empty()}):window.getSelection().removeAllRanges()}catch{}},_dragStarted:function(t,n){if(Jt=!1,M&&h){st("dragStarted",this,{evt:n}),this.nativeDraggable&&P(document,"dragover",$s);var i=this.options;!t&&at(h,i.dragClass,!1),at(h,i.ghostClass,!0),w.active=this,t&&this._appendGhost(),et({sortable:this,name:"start",originalEvent:n})}else this._nulling()},_emulateDragOver:function(){if(ht){this._lastX=ht.clientX,this._lastY=ht.clientY,so();for(var t=document.elementFromPoint(ht.clientX,ht.clientY),n=t;t&&t.shadowRoot&&(t=t.shadowRoot.elementFromPoint(ht.clientX,ht.clientY),t!==n);)n=t;if(h.parentNode[rt]._isOutsideThisEl(t),n)do{if(n[rt]){var i=void 0;if(i=n[rt]._onDragOver({clientX:ht.clientX,clientY:ht.clientY,target:t,rootEl:n}),i&&!this.options.dragoverBubble)break}t=n}while(n=zi(n));ao()}},_onTouchMove:function(t){if(kt){var n=this.options,i=n.fallbackTolerance,o=n.fallbackOffset,r=t.touches?t.touches[0]:t,s=x&&qt(x,!0),a=x&&s&&s.a,l=x&&s&&s.d,d=Ue&&Q&&Wi(Q),c=(r.clientX-kt.clientX+o.x)/(a||1)+(d?d[0]-kn[0]:0)/(a||1),u=(r.clientY-kt.clientY+o.y)/(l||1)+(d?d[1]-kn[1]:0)/(l||1);if(!w.active&&!Jt){if(i&&Math.max(Math.abs(r.clientX-this._lastX),Math.abs(r.clientY-this._lastY))<i)return;this._onDragStart(t,!0)}if(x){s?(s.e+=c-(Vn||0),s.f+=u-(Bn||0)):s={a:1,b:0,c:0,d:1,e:c,f:u};var p="matrix(".concat(s.a,",").concat(s.b,",").concat(s.c,",").concat(s.d,",").concat(s.e,",").concat(s.f,")");v(x,"webkitTransform",p),v(x,"mozTransform",p),v(x,"msTransform",p),v(x,"transform",p),Vn=c,Bn=u,ht=r}t.cancelable&&t.preventDefault()}},_appendGhost:function(){if(!x){var t=this.options.fallbackOnBody?document.body:M,n=U(h,!0,Ue,!0,t),i=this.options;if(Ue){for(Q=t;v(Q,"position")==="static"&&v(Q,"transform")==="none"&&Q!==document;)Q=Q.parentNode;Q!==document.body&&Q!==document.documentElement?(Q===document&&(Q=ft()),n.top+=Q.scrollTop,n.left+=Q.scrollLeft):Q=ft(),kn=Wi(Q)}x=h.cloneNode(!0),at(x,i.ghostClass,!1),at(x,i.fallbackClass,!0),at(x,i.dragClass,!0),v(x,"transition",""),v(x,"transform",""),v(x,"box-sizing","border-box"),v(x,"margin",0),v(x,"top",n.top),v(x,"left",n.left),v(x,"width",n.width),v(x,"height",n.height),v(x,"opacity","0.8"),v(x,"position",Ue?"absolute":"fixed"),v(x,"zIndex","100000"),v(x,"pointerEvents","none"),w.ghost=x,t.appendChild(x),v(x,"transform-origin",to/parseInt(x.style.width)*100+"% "+eo/parseInt(x.style.height)*100+"%")}},_onDragStart:function(t,n){var i=this,o=t.dataTransfer,r=i.options;if(st("dragStart",this,{evt:t}),w.eventCanceled){this._onDrop();return}st("setupClone",this),w.eventCanceled||(I=Ki(h),I.removeAttribute("id"),I.draggable=!1,I.style["will-change"]="",this._hideClone(),at(I,this.options.chosenClass,!1),w.clone=I),i.cloneId=je(function(){st("clone",i),!w.eventCanceled&&(i.options.removeCloneOnHide||M.insertBefore(I,h),i._hideClone(),et({sortable:i,name:"clone"}))}),!n&&at(h,r.dragClass,!0),n?(Ie=!0,i._loopId=setInterval(i._emulateDragOver,50)):(S(document,"mouseup",i._onDrop),S(document,"touchend",i._onDrop),S(document,"touchcancel",i._onDrop),o&&(o.effectAllowed="move",r.setData&&r.setData.call(i,o,h)),P(document,"drop",i),v(h,"transform","translateZ(0)")),Jt=!0,i._dragStartId=je(i._dragStarted.bind(i,n,t)),P(document,"selectstart",i),me=!0,he&&v(document.body,"user-select","none")},_onDragOver:function(t){var n=this.el,i=t.target,o,r,s,a=this.options,l=a.group,d=w.active,c=Me===l,u=a.sort,p=W||d,f,g=this,y=!1;if(Un)return;function R(Ce,za){st(Ce,g,pt({evt:t,isOwner:c,axis:f?"vertical":"horizontal",revert:s,dragRect:o,targetRect:r,canSort:u,fromSortable:p,target:i,completed:k,onMove:function(No,Xa){return Fe(M,n,h,o,No,U(No),t,Xa)},changed:nt},za))}function H(){R("dragOverAnimationCapture"),g.captureAnimationState(),g!==p&&p.captureAnimationState()}function k(Ce){return R("dragOverCompleted",{insertion:Ce}),Ce&&(c?d._hideClone():d._showClone(g),g!==p&&(at(h,W?W.options.ghostClass:d.options.ghostClass,!1),at(h,a.ghostClass,!0)),W!==g&&g!==w.active?W=g:g===w.active&&W&&(W=null),p===g&&(g._ignoreWhileAnimating=i),g.animateAll(function(){R("dragOverAnimationComplete"),g._ignoreWhileAnimating=null}),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[rt]._isOutsideThisEl(t.target),!Ce&&Ut(t)),!a.dragoverBubble&&t.stopPropagation&&t.stopPropagation(),y=!0}function nt(){lt=ut(h),Ct=ut(h,a.draggable),et({sortable:g,name:"change",toEl:n,newIndex:lt,newDraggableIndex:Ct,originalEvent:t})}if(t.preventDefault!==void 0&&t.cancelable&&t.preventDefault(),i=ct(i,a.draggable,n,!0),R("dragOver"),w.eventCanceled)return y;if(h.contains(t.target)||i.animated&&i.animatingX&&i.animatingY||g._ignoreWhileAnimating===i)return k(!1);if(Ie=!1,d&&!a.disabled&&(c?u||(s=N!==M):W===this||(this.lastPutMode=Me.checkPull(this,d,h,t))&&l.checkPut(this,d,h,t))){if(f=this._getDirection(t,i)==="vertical",o=U(h),R("dragOverValid"),w.eventCanceled)return y;if(s)return N=M,H(),this._hideClone(),R("revert"),w.eventCanceled||(Bt?M.insertBefore(h,Bt):M.appendChild(h)),k(!0);var J=In(n,a.draggable);if(!J||As(t,f,this)&&!J.animated){if(J===h)return k(!1);if(J&&n===t.target&&(i=J),i&&(r=U(i)),Fe(M,n,h,o,i,r,t,!!i)!==!1)return H(),J&&J.nextSibling?n.insertBefore(h,J.nextSibling):n.appendChild(h),N=n,nt(),k(!0)}else if(J&&Ss(t,f,this)){var it=Yt(n,0,a,!0);if(it===h)return k(!1);if(i=it,r=U(i),Fe(M,n,h,o,i,r,t,!1)!==!1)return H(),n.insertBefore(h,it),N=n,nt(),k(!0)}else if(i.parentNode===n){r=U(i);var b=0,L,K=h.parentNode!==n,z=!vs(h.animated&&h.toRect||o,i.animated&&i.toRect||r,f),Se=f?"top":"left",Dt=Yi(i,"top","top")||Yi(h,"top","top"),Ae=Dt?Dt.scrollTop:void 0;Kt!==i&&(L=r[Se],be=!1,He=!z&&a.invertSwap||K),b=_s(t,i,r,f,z?1:a.swapThreshold,a.invertedSwapThreshold==null?a.swapThreshold:a.invertedSwapThreshold,He,Kt===i);var xt;if(b!==0){var Ft=ut(h);do Ft-=b,xt=N.children[Ft];while(xt&&(v(xt,"display")==="none"||xt===x))}if(b===0||xt===i)return k(!1);Kt=i,ye=b;var _e=i.nextElementSibling,Rt=!1;Rt=b===1;var yn=Fe(M,n,h,o,i,r,t,Rt);if(yn!==!1)return(yn===1||yn===-1)&&(Rt=yn===1),Un=!0,setTimeout(Es,30),H(),Rt&&!_e?n.appendChild(h):i.parentNode.insertBefore(h,Rt?_e:i),Dt&&Ji(Dt,0,Ae-Dt.scrollTop),N=h.parentNode,L!==void 0&&!He&&(Ve=Math.abs(L-U(i)[Se])),nt(),k(!0)}if(n.contains(h))return k(!1)}return!1},_ignoreWhileAnimating:null,_offMoveEvents:function(){S(document,"mousemove",this._onTouchMove),S(document,"touchmove",this._onTouchMove),S(document,"pointermove",this._onTouchMove),S(document,"dragover",Ut),S(document,"mousemove",Ut),S(document,"touchmove",Ut)},_offUpEvents:function(){var t=this.el.ownerDocument;S(t,"mouseup",this._onDrop),S(t,"touchend",this._onDrop),S(t,"pointerup",this._onDrop),S(t,"touchcancel",this._onDrop),S(document,"selectstart",this)},_onDrop:function(t){var n=this.el,i=this.options;if(lt=ut(h),Ct=ut(h,i.draggable),st("drop",this,{evt:t}),N=h&&h.parentNode,lt=ut(h),Ct=ut(h,i.draggable),w.eventCanceled){this._nulling();return}Jt=!1,He=!1,be=!1,clearInterval(this._loopId),clearTimeout(this._dragStartTimer),jn(this.cloneId),jn(this._dragStartId),this.nativeDraggable&&(S(document,"drop",this),S(n,"dragstart",this._onDragStart)),this._offMoveEvents(),this._offUpEvents(),he&&v(document.body,"user-select",""),v(h,"transform",""),t&&(me&&(t.cancelable&&t.preventDefault(),!i.dropBubble&&t.stopPropagation()),x&&x.parentNode&&x.parentNode.removeChild(x),(M===N||W&&W.lastPutMode!=="clone")&&I&&I.parentNode&&I.parentNode.removeChild(I),h&&(this.nativeDraggable&&S(h,"dragend",this),Fn(h),h.style["will-change"]="",me&&!Jt&&at(h,W?W.options.ghostClass:this.options.ghostClass,!1),at(h,this.options.chosenClass,!1),et({sortable:this,name:"unchoose",toEl:N,newIndex:null,newDraggableIndex:null,originalEvent:t}),M!==N?(lt>=0&&(et({rootEl:N,name:"add",toEl:N,fromEl:M,originalEvent:t}),et({sortable:this,name:"remove",toEl:N,originalEvent:t}),et({rootEl:N,name:"sort",toEl:N,fromEl:M,originalEvent:t}),et({sortable:this,name:"sort",toEl:N,originalEvent:t})),W&&W.save()):lt!==Gt&<>=0&&(et({sortable:this,name:"update",toEl:N,originalEvent:t}),et({sortable:this,name:"sort",toEl:N,originalEvent:t})),w.active&&((lt==null||lt===-1)&&(lt=Gt,Ct=ge),et({sortable:this,name:"end",toEl:N,originalEvent:t}),this.save()))),this._nulling()},_nulling:function(){st("nulling",this),M=h=N=x=Bt=I=Le=_t=kt=ht=me=lt=Ct=Gt=ge=Kt=ye=W=Me=w.dragged=w.ghost=w.clone=w.active=null,Be.forEach(function(t){t.checked=!0}),Be.length=Vn=Bn=0},handleEvent:function(t){switch(t.type){case"drop":case"dragend":this._onDrop(t);break;case"dragenter":case"dragover":h&&(this._onDragOver(t),xs(t));break;case"selectstart":t.preventDefault();break}},toArray:function(){for(var t=[],n,i=this.el.children,o=0,r=i.length,s=this.options;o<r;o++)n=i[o],ct(n,s.draggable,this.el,!1)&&t.push(n.getAttribute(s.dataIdAttr)||Ts(n));return t},sort:function(t,n){var i={},o=this.el;this.toArray().forEach(function(r,s){var a=o.children[s];ct(a,this.options.draggable,o,!1)&&(i[r]=a)},this),n&&this.captureAnimationState(),t.forEach(function(r){i[r]&&(o.removeChild(i[r]),o.appendChild(i[r]))}),n&&this.animateAll()},save:function(){var t=this.options.store;t&&t.set&&t.set(this)},closest:function(t,n){return ct(t,n||this.options.draggable,this.el,!1)},option:function(t,n){var i=this.options;if(n===void 0)return i[t];var o=fe.modifyOption(this,t,n);typeof o<"u"?i[t]=o:i[t]=n,t==="group"&&ro(i)},destroy:function(){st("destroy",this);var t=this.el;t[rt]=null,S(t,"mousedown",this._onTapStart),S(t,"touchstart",this._onTapStart),S(t,"pointerdown",this._onTapStart),this.nativeDraggable&&(S(t,"dragover",this),S(t,"dragenter",this)),Array.prototype.forEach.call(t.querySelectorAll("[draggable]"),function(n){n.removeAttribute("draggable")}),this._onDrop(),this._disableDelayedDragEvents(),Ne.splice(Ne.indexOf(this.el),1),this.el=t=null},_hideClone:function(){if(!_t){if(st("hideClone",this),w.eventCanceled)return;v(I,"display","none"),this.options.removeCloneOnHide&&I.parentNode&&I.parentNode.removeChild(I),_t=!0}},_showClone:function(t){if(t.lastPutMode!=="clone"){this._hideClone();return}if(_t){if(st("showClone",this),w.eventCanceled)return;h.parentNode==M&&!this.options.group.revertClone?M.insertBefore(I,h):Bt?M.insertBefore(I,Bt):M.appendChild(I),this.options.group.revertClone&&this.animate(h,I),v(I,"display",""),_t=!1}}};function xs(e){e.dataTransfer&&(e.dataTransfer.dropEffect="move"),e.cancelable&&e.preventDefault()}function Fe(e,t,n,i,o,r,s,a){var l,d=e[rt],c=d.options.onMove,u;return window.CustomEvent&&!wt&&!ce?l=new CustomEvent("move",{bubbles:!0,cancelable:!0}):(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||U(t),l.willInsertAfter=a,l.originalEvent=s,e.dispatchEvent(l),c&&(u=c.call(d,l,s)),u}function Fn(e){e.draggable=!1}function Es(){Un=!1}function Ss(e,t,n){var i=U(Yt(n.el,0,n.options,!0)),o=Qi(n.el,n.options,x),r=10;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}function As(e,t,n){var i=U(In(n.el,n.options.draggable)),o=Qi(n.el,n.options,x),r=10;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}function _s(e,t,n,i,o,r,s,a){var l=i?e.clientY:e.clientX,d=i?n.height:n.width,c=i?n.top:n.left,u=i?n.bottom:n.right,p=!1;if(!s){if(a&&Ve<d*o){if(!be&&(ye===1?l>c+d*r/2:l<u-d*r/2)&&(be=!0),be)p=!0;else if(ye===1?l<c+Ve:l>u-Ve)return-ye}else if(l>c+d*(1-o)/2&&l<u-d*(1-o)/2)return Cs(t)}return p=p||s,p&&(l<c+d*r/2||l>u-d*r/2)?l>c+d/2?1:-1:0}function Cs(e){return ut(h)<ut(e)?1:-1}function Ts(e){for(var t=e.tagName+e.className+e.src+e.href+e.textContent,n=t.length,i=0;n--;)i+=t.charCodeAt(n);return i.toString(36)}function Ps(e){Be.length=0;for(var t=e.getElementsByTagName("input"),n=t.length;n--;){var i=t[n];i.checked&&Be.push(i)}}function je(e){return setTimeout(e,0)}function jn(e){return clearTimeout(e)}ke&&P(document,"touchmove",function(e){(w.active||Jt)&&e.cancelable&&e.preventDefault()}),w.utils={on:P,off:S,css:v,find:qi,is:function(t,n){return!!ct(t,n,t,!1)},extend:cs,throttle:Gi,closest:ct,toggleClass:at,clone:Ki,index:ut,nextTick:je,cancelNextTick:jn,detectDirection:oo,getChild:Yt,expando:rt},w.get=function(e){return e[rt]},w.mount=function(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];t[0].constructor===Array&&(t=t[0]),t.forEach(function(i){if(!i.prototype||!i.prototype.constructor)throw"Sortable: Mounted plugin must be a constructor function, not ".concat({}.toString.call(i));i.utils&&(w.utils=pt(pt({},w.utils),i.utils)),fe.mount(i)})},w.create=function(e,t){return new w(e,t)},w.version=ds;var F=[],ve,Zn,zn=!1,Xn,qn,Ze,we;function Os(){function e(){this.defaults={scroll:!0,forceAutoScrollFallback:!1,scrollSensitivity:30,scrollSpeed:10,bubbleScroll:!0};for(var t in this)t.charAt(0)==="_"&&typeof this[t]=="function"&&(this[t]=this[t].bind(this))}return e.prototype={dragStarted:function(n){var i=n.originalEvent;this.sortable.nativeDraggable?P(document,"dragover",this._handleAutoScroll):this.options.supportPointer?P(document,"pointermove",this._handleFallbackAutoScroll):i.touches?P(document,"touchmove",this._handleFallbackAutoScroll):P(document,"mousemove",this._handleFallbackAutoScroll)},dragOverCompleted:function(n){var i=n.originalEvent;!this.options.dragOverBubble&&!i.rootEl&&this._handleAutoScroll(i)},drop:function(){this.sortable.nativeDraggable?S(document,"dragover",this._handleAutoScroll):(S(document,"pointermove",this._handleFallbackAutoScroll),S(document,"touchmove",this._handleFallbackAutoScroll),S(document,"mousemove",this._handleFallbackAutoScroll)),lo(),ze(),hs()},nulling:function(){Ze=Zn=ve=zn=we=Xn=qn=null,F.length=0},_handleFallbackAutoScroll:function(n){this._handleAutoScroll(n,!0)},_handleAutoScroll:function(n,i){var o=this,r=(n.touches?n.touches[0]:n).clientX,s=(n.touches?n.touches[0]:n).clientY,a=document.elementFromPoint(r,s);if(Ze=n,i||this.options.forceAutoScrollFallback||ce||wt||he){Yn(n,this.options,a,i);var l=At(a,!0);zn&&(!we||r!==Xn||s!==qn)&&(we&&lo(),we=setInterval(function(){var d=At(document.elementFromPoint(r,s),!0);d!==l&&(l=d,ze()),Yn(n,o.options,d,i)},10),Xn=r,qn=s)}else{if(!this.options.bubbleScroll||At(a,!0)===ft()){ze();return}Yn(n,this.options,At(a,!1),!1)}}},bt(e,{pluginName:"scroll",initializeByDefault:!0})}function ze(){F.forEach(function(e){clearInterval(e.pid)}),F=[]}function lo(){clearInterval(we)}var Yn=Gi(function(e,t,n,i){if(t.scroll){var o=(e.touches?e.touches[0]:e).clientX,r=(e.touches?e.touches[0]:e).clientY,s=t.scrollSensitivity,a=t.scrollSpeed,l=ft(),d=!1,c;Zn!==n&&(Zn=n,ze(),ve=t.scroll,c=t.scrollFn,ve===!0&&(ve=At(n,!0)));var u=0,p=ve;do{var f=p,g=U(f),y=g.top,R=g.bottom,H=g.left,k=g.right,nt=g.width,J=g.height,it=void 0,b=void 0,L=f.scrollWidth,K=f.scrollHeight,z=v(f),Se=f.scrollLeft,Dt=f.scrollTop;f===l?(it=nt<L&&(z.overflowX==="auto"||z.overflowX==="scroll"||z.overflowX==="visible"),b=J<K&&(z.overflowY==="auto"||z.overflowY==="scroll"||z.overflowY==="visible")):(it=nt<L&&(z.overflowX==="auto"||z.overflowX==="scroll"),b=J<K&&(z.overflowY==="auto"||z.overflowY==="scroll"));var Ae=it&&(Math.abs(k-o)<=s&&Se+nt<L)-(Math.abs(H-o)<=s&&!!Se),xt=b&&(Math.abs(R-r)<=s&&Dt+J<K)-(Math.abs(y-r)<=s&&!!Dt);if(!F[u])for(var Ft=0;Ft<=u;Ft++)F[Ft]||(F[Ft]={});(F[u].vx!=Ae||F[u].vy!=xt||F[u].el!==f)&&(F[u].el=f,F[u].vx=Ae,F[u].vy=xt,clearInterval(F[u].pid),(Ae!=0||xt!=0)&&(d=!0,F[u].pid=setInterval((function(){i&&this.layer===0&&w.active._onTouchMove(Ze);var _e=F[this.layer].vy?F[this.layer].vy*a:0,Rt=F[this.layer].vx?F[this.layer].vx*a:0;typeof c=="function"&&c.call(w.dragged.parentNode[rt],Rt,_e,e,Ze,F[this.layer].el)!=="continue"||Ji(F[this.layer].el,Rt,_e)}).bind({layer:u}),24))),u++}while(t.bubbleScroll&&p!==l&&(p=At(p,!1)));zn=d}},30),uo=function(t){var n=t.originalEvent,i=t.putSortable,o=t.dragEl,r=t.activeSortable,s=t.dispatchSortableEvent,a=t.hideGhostForTarget,l=t.unhideGhostForTarget;if(n){var d=i||r;a();var c=n.changedTouches&&n.changedTouches.length?n.changedTouches[0]:n,u=document.elementFromPoint(c.clientX,c.clientY);l(),d&&!d.el.contains(u)&&(s("spill"),this.onSpill({dragEl:o,putSortable:i}))}};function Wn(){}Wn.prototype={startIndex:null,dragStart:function(t){var n=t.oldDraggableIndex;this.startIndex=n},onSpill:function(t){var n=t.dragEl,i=t.putSortable;this.sortable.captureAnimationState(),i&&i.captureAnimationState();var o=Yt(this.sortable.el,this.startIndex,this.options);o?this.sortable.el.insertBefore(n,o):this.sortable.el.appendChild(n),this.sortable.animateAll(),i&&i.animateAll()},drop:uo},bt(Wn,{pluginName:"revertOnSpill"});function Gn(){}Gn.prototype={onSpill:function(t){var n=t.dragEl,i=t.putSortable,o=i||this.sortable;o.captureAnimationState(),n.parentNode&&n.parentNode.removeChild(n),o.animateAll()},drop:uo},bt(Gn,{pluginName:"removeOnSpill"}),w.mount(new Os),w.mount(Gn,Wn);const Ds=e=>{const t=e.item;let n=Array.prototype.slice.call(t.parentNode.childNodes);return n=n.filter(i=>i.nodeType!=Node.ELEMENT_NODE||!i.classList.contains("sortable-fallback")),n},Rs=(e,t,n,i,o,r)=>{const a=e.item.parentNode;for(const y of n)a.appendChild(y);if(e.oldIndex==e.newIndex)return;const l=i.getArray(),d=e.item.querySelector("eox-layercontrol-layer").layer.get(o),c=l.find(y=>y.get(o)===d),u=r.dataset.layer,p=l.find(y=>y.get(o)==u);let f,g;for(f=0;f<l.length;f++)if(l[f]==c){i.removeAt(f);break}for(g=0;g<l.length;g++)if(l[g]===p){f>g?i.insertAt(g,c):i.insertAt(g+1,c);break}t.requestUpdate()};function Ls(e,t,n,i){let o=[],r=null;e._sortable=w.create(e,{handle:".drag-handle",filter:".drag-handle.disabled",swapThreshold:.5,animation:150,easing:"cubic-bezier(1, 0, 0, 1)",onStart:s=>o=Ds(s),onMove:s=>{r=s.related},onEnd:s=>Rs(s,i,o,t,n,r)})}function Ms(e,t,n,i){const o=e.getArray();let r=!1;o.forEach(s=>{const a=s.ol_uid;s.get(t)||(s.set(t,a),r=!0),s.get(n)||(s.set(n,`layer ${a}`),r=!0),r&&i.requestUpdate()})}function Jn(e,t,n){let i=[];const o=(r,s,a)=>{i=[...i,...r.filter(d=>d.get(s)===a)];const l=r.filter(d=>d.getLayers);return l.length>0&&l.forEach(d=>o(d.getLayers().getArray(),s,a)),i};return o(e,t,n),i}function Is(e,t,n){if(!e||!t)return!1;if(!co(e,n))return!0;const i=e.get("minZoom"),o=e.get("maxZoom"),r=t.getView().getZoom();return r>i&&r<o}function co(e,t){const n=e.get("minZoom"),i=e.get("maxZoom");return!!(t&&(n!==-1/0||i!==1/0))}function Ns(e,t){var o,r,s;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(e.getSource?(r=e.getSource())==null?void 0:r.ol_uid:void 0))?"draw":e.declutter_!==void 0?"vector":"raster"}const Hs=(e,t,n)=>{let i=t;return n.layer.getSource().getTileUrlFunction()&&(i||(i=n.layer.getSource().getTileUrlFunction()),n.layer.getSource().setTileUrlFunction((...o)=>rs(i(...o),e)),n.layer.getSource().setKey(new Date)),i};function Vs(e,t,n){const i="updateStyleVariables"in t,o="setStyle"in t,r=i?t.style_:n.style;let s=r==null?void 0:r.variables;if(s){const a=Kn(e);if(r.variables={...s,...a},i)t.updateStyleVariables(a);else if(o){const l=Bs(r);t.setStyle(l)}}}const Kn=e=>{const t={};for(const n in e)if(typeof e[n]=="object"&&e[n]!==null){const i=Kn(e[n]);for(const o in i)t[o]=i==null?void 0:i[o]}else t[n]=e==null?void 0:e[n];return t};function Bs(e){let t=e;if("variables"in e){let n=JSON.stringify(e);const{variables:i}=e;for(const o in i)typeof i[o]=="number"?n=n.replaceAll(`["var","${o}"]`,i[o]):n=n.replaceAll(`["var","${o}"]`,`"${i[o]}"`);t=JSON.parse(n)}return t}const ks=(e,t)=>{var n;if(e)return!("domainProperties"in e)||"domain"in e?{...e}:(n=Object.keys(e))==null?void 0:n.reduce((i,o)=>{if(o==="domainProperties"){const r=Kn(t);i.domain=e[o].map(s=>r[s])}else i[o]=e[o];return i},{})};function ho(e,t){var i;let n={};for(const o in e){const r=e[o].type;if(r&&r!=="object")n[o]=r==="number"?Number(t[o]):t[o];else if(typeof e[o]=="object"&&((i=e[o])!=null&&i.properties)){const s=ho(e[o].properties,t);Object.keys(s).length>0&&(n[o]=s)}}return n}function Us(e,t){var r,s,a,l,d;if(!t)return null;let n={},i="updateStyleVariables"in e?(r=e.style_)==null?void 0:r.variables:(s=t.style)==null?void 0:s.variables;if((t.type==="style"||t.style)&&i)n=i;else if((l=(a=e.getSource())==null?void 0:a.getTileUrlFunction)!=null&&l.call(a)){const c=new URL(e.getSource().getTileUrlFunction()([0,0,0]));n=Object.fromEntries(c.searchParams.entries())}else return null;const o=ho(((d=t.schema)==null?void 0:d.properties)||t.schema,n);return Object.keys(o).length?o:null}const Fs=(e,t)=>e==null?void 0:e.filter(n=>["remove","sort"].filter(i=>t!=null&&t.get("layerControlDisable")?i!=="sort":!0).includes(n)),js=(e,t)=>e==null?void 0:e.filter(n=>{let i=!0;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")),n==="legend"&&(i=t.get("layerLegend")),i}),Zs=(e,t)=>$`
|
|
46
46
|
<button slot="${e}-icon" class="icon">${t?e:T}</button>
|
|
47
|
-
`,
|
|
47
|
+
`,zs=e=>$`
|
|
48
48
|
<button
|
|
49
49
|
class="remove-icon icon"
|
|
50
50
|
@click=${()=>{const{layer:t}=e;t==null||t.set("layerControlOptional",!0),t==null||t.setVisible(!1),e.dispatchEvent(new CustomEvent("changed",{detail:t,bubbles:!0}))}}
|
|
51
51
|
>
|
|
52
52
|
${e.unstyled?"x":T}
|
|
53
53
|
</button>
|
|
54
|
-
`,
|
|
54
|
+
`,Xs=e=>$`
|
|
55
55
|
<span class="button sort-icon icon drag-handle">
|
|
56
56
|
${e?"═":T}
|
|
57
57
|
</span>
|
|
@@ -59,39 +59,37 @@
|
|
|
59
59
|
* @license
|
|
60
60
|
* Copyright 2020 Google LLC
|
|
61
61
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
62
|
-
*/const fo=Tn(class extends Pn{constructor(e){if(super(e),e.type!==St.PROPERTY&&e.type!==St.ATTRIBUTE&&e.type!==St.BOOLEAN_ATTRIBUTE)throw Error("The `live` directive is not allowed on child or event bindings");if(!
|
|
62
|
+
*/const fo=Tn(class extends Pn{constructor(e){if(super(e),e.type!==St.PROPERTY&&e.type!==St.ATTRIBUTE&&e.type!==St.BOOLEAN_ATTRIBUTE)throw Error("The `live` directive is not allowed on child or event bindings");if(!ar(e))throw Error("`live` bindings can only contain a single expression")}render(e){return e}update(e,[t]){if(t===dt||t===T)return t;const n=e.element,i=e.name;if(e.type===St.PROPERTY){if(t===n[i])return dt}else if(e.type===St.BOOLEAN_ATTRIBUTE){if(!!t===n.hasAttribute(i))return dt}else if(e.type===St.ATTRIBUTE&&n.getAttribute(i)===t+"")return dt;return Oi(e),t}});/**
|
|
63
63
|
* @license
|
|
64
64
|
* Copyright 2017 Google LLC
|
|
65
65
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
66
|
-
*/class Qn extends Pn{constructor(t){if(super(t),this.it=T,t.type!==St.CHILD)throw Error(this.constructor.directiveName+"() can only be used in child bindings")}render(t){if(t===T||t==null)return this._t=void 0,this.it=t;if(t===dt)return t;if(typeof t!="string")throw Error(this.constructor.directiveName+"() called with a non-string value");if(t===this.it)return this._t;this.it=t;const n=[t];return n.raw=n,this._t={_$litType$:this.constructor.resultType,strings:n,values:[]}}}Qn.directiveName="unsafeHTML",Qn.resultType=1;const
|
|
66
|
+
*/class Qn extends Pn{constructor(t){if(super(t),this.it=T,t.type!==St.CHILD)throw Error(this.constructor.directiveName+"() can only be used in child bindings")}render(t){if(t===T||t==null)return this._t=void 0,this.it=t;if(t===dt)return t;if(typeof t!="string")throw Error(this.constructor.directiveName+"() called with a non-string value");if(t===this.it)return this._t;this.it=t;const n=[t];return n.raw=n,this._t={_$litType$:this.constructor.resultType,strings:n,values:[]}}}Qn.directiveName="unsafeHTML",Qn.resultType=1;const qs=Tn(Qn);/**
|
|
67
67
|
* @license
|
|
68
68
|
* Copyright 2021 Google LLC
|
|
69
69
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
70
|
-
*/function*Xe(e,t){if(e!==void 0){let n=0;for(const i of e)yield t(i,n++)}}var Tt=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function go(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var mo="Expected a function",yo=NaN,
|
|
70
|
+
*/function*Xe(e,t){if(e!==void 0){let n=0;for(const i of e)yield t(i,n++)}}var Tt=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function go(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var mo="Expected a function",yo=NaN,Ys="[object Symbol]",Ws=/^\s+|\s+$/g,Gs=/^[-+]0x[0-9a-f]+$/i,Js=/^0b[01]+$/i,Ks=/^0o[0-7]+$/i,Qs=parseInt,ta=typeof Tt=="object"&&Tt&&Tt.Object===Object&&Tt,ea=typeof self=="object"&&self&&self.Object===Object&&self,na=ta||ea||Function("return this")(),ia=Object.prototype,oa=ia.toString,ra=Math.max,sa=Math.min,ti=function(){return na.Date.now()};function aa(e,t,n){var i,o,r,s,a,l,d=0,c=!1,u=!1,p=!0;if(typeof e!="function")throw new TypeError(mo);t=bo(t)||0,qe(n)&&(c=!!n.leading,u="maxWait"in n,r=u?ra(bo(n.maxWait)||0,t):r,p="trailing"in n?!!n.trailing:p);function f(b){var L=i,K=o;return i=o=void 0,d=b,s=e.apply(K,L),s}function g(b){return d=b,a=setTimeout(H,t),c?f(b):s}function y(b){var L=b-l,K=b-d,z=t-L;return u?sa(z,r-K):z}function R(b){var L=b-l,K=b-d;return l===void 0||L>=t||L<0||u&&K>=r}function H(){var b=ti();if(R(b))return k(b);a=setTimeout(H,y(b))}function k(b){return a=void 0,p&&i?f(b):(i=o=void 0,s)}function nt(){a!==void 0&&clearTimeout(a),d=0,i=l=o=a=void 0}function J(){return a===void 0?s:k(ti())}function it(){var b=ti(),L=R(b);if(i=arguments,o=this,l=b,L){if(a===void 0)return g(l);if(u)return a=setTimeout(H,t),f(l)}return a===void 0&&(a=setTimeout(H,t)),s}return it.cancel=nt,it.flush=J,it}function la(e,t,n){var i=!0,o=!0;if(typeof e!="function")throw new TypeError(mo);return qe(n)&&(i="leading"in n?!!n.leading:i,o="trailing"in n?!!n.trailing:o),aa(e,t,{leading:i,maxWait:t,trailing:o})}function qe(e){var t=typeof e;return!!e&&(t=="object"||t=="function")}function da(e){return!!e&&typeof e=="object"}function ua(e){return typeof e=="symbol"||da(e)&&oa.call(e)==Ys}function bo(e){if(typeof e=="number")return e;if(ua(e))return yo;if(qe(e)){var t=typeof e.valueOf=="function"?e.valueOf():e;e=qe(t)?t+"":t}if(typeof e!="string")return e===0?e:+e;e=e.replace(Ws,"");var n=Js.test(e);return n||Ks.test(e)?Qs(e.slice(2),n?2:8):Gs.test(e)?yo:+e}var ca=la;const vo=go(ca);/**
|
|
71
71
|
* @license
|
|
72
72
|
* Copyright 2018 Google LLC
|
|
73
73
|
* SPDX-License-Identifier: BSD-3-Clause
|
|
74
74
|
*/const Ye=e=>e??T;class wo extends tt{constructor(){super();O(this,We,di`
|
|
75
|
+
.legend-container {
|
|
76
|
+
display: flex;
|
|
77
|
+
justify-content: center;
|
|
78
|
+
}
|
|
75
79
|
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
--cle-font-size:inherit;
|
|
85
|
-
--cle-font-weight :inherit
|
|
86
|
-
--cle-letter-spacing :inherit;
|
|
87
|
-
--cle-letter-spacing-title :inherit;
|
|
88
|
-
}
|
|
89
|
-
`);O(this,Ge,"");this.unstyled=!1,this.noShadow=!1,this.layerLegend=null,this.layer=null}createRenderRoot(){return this.noShadow?this:super.createRenderRoot()}render(){return customElements.get("color-legend")||console.error("Please import `color-legend-element` in order to use layerLegend"),x`
|
|
80
|
+
color-legend {
|
|
81
|
+
--cle-background: transparent;
|
|
82
|
+
--cle-font-family: inherit;
|
|
83
|
+
--cle-font-size: inherit;
|
|
84
|
+
--cle-font-weight: inherit --cle-letter-spacing: inherit;
|
|
85
|
+
--cle-letter-spacing-title: inherit;
|
|
86
|
+
}
|
|
87
|
+
`);O(this,Ge,"");this.unstyled=!1,this.noShadow=!1,this.layerLegend=null,this.layer=null}createRenderRoot(){return this.noShadow?this:super.createRenderRoot()}render(){return customElements.get("color-legend")||console.error("Please import `color-legend-element` in order to use layerLegend"),$`
|
|
90
88
|
<style>
|
|
91
89
|
${A(this,We)}
|
|
92
90
|
${!this.unstyled&&A(this,Ge)}
|
|
93
91
|
</style>
|
|
94
|
-
${Z(this.layerLegend,()
|
|
92
|
+
${Z(this.layerLegend,()=>$`
|
|
95
93
|
<div class="legend-container">
|
|
96
94
|
<!-- Render color-legend-->
|
|
97
95
|
<color-legend
|
|
@@ -109,43 +107,42 @@
|
|
|
109
107
|
</color-legend>
|
|
110
108
|
</div>
|
|
111
109
|
`)}
|
|
112
|
-
`}}We=new WeakMap,Ge=new WeakMap,V(wo,"properties",{unstyled:{type:Boolean},noShadow:{type:Boolean},layerLegend:{attribute:!1},layer:{attribute:!1}}),customElements.define("eox-layercontrol-layer-legend",wo);class
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
}
|
|
121
|
-
`);O(this,Ke,"");this.layer=null,this.unstyled=!1,this.noShadow=!1,this.layerConfig=null,this.throttleDataChange=vo(j(this,xe,ri),1e3)}updated(n){if(n.has("layerConfig")){const i=this.layerConfig.type==="style"||this.layerConfig.style?100:1e3;this.throttleDataChange=vo(j(this,xe,ri),i),this.requestUpdate()}}createRenderRoot(){return this.noShadow?this:super.createRenderRoot()}render(){te(this,Kt,Fs(this.layer,this.layerConfig)),Object.keys(A(this,xt)).length!==0&&te(this,Kt,A(this,xt)),customElements.get("eox-jsonform")||console.error("Please import @eox/jsonform in order to use layerconfig");const n={disable_edit_json:!0,disable_collapse:!0,disable_properties:!0};return x`
|
|
110
|
+
`}}We=new WeakMap,Ge=new WeakMap,V(wo,"properties",{unstyled:{type:Boolean},noShadow:{type:Boolean},layerLegend:{attribute:!1},layer:{attribute:!1}}),customElements.define("eox-layercontrol-layer-legend",wo);class $o extends tt{constructor(){super();O(this,xe);O(this,$t,{});O(this,Qt,null);O(this,$e);O(this,Je,di`
|
|
111
|
+
color-legend {
|
|
112
|
+
--cle-background: transparent;
|
|
113
|
+
--cle-font-family: inherit;
|
|
114
|
+
--cle-font-size: inherit;
|
|
115
|
+
--cle-font-weight: inherit --cle-letter-spacing: inherit;
|
|
116
|
+
--cle-letter-spacing-title: inherit;
|
|
117
|
+
}
|
|
118
|
+
`);O(this,Ke,"");this.layer=null,this.unstyled=!1,this.noShadow=!1,this.layerConfig=null,this.throttleDataChange=vo(j(this,xe,ri),1e3)}updated(n){if(n.has("layerConfig")){const i=this.layerConfig.type==="style"||this.layerConfig.style?100:1e3;this.throttleDataChange=vo(j(this,xe,ri),i),this.requestUpdate()}}createRenderRoot(){return this.noShadow?this:super.createRenderRoot()}render(){ee(this,Qt,Us(this.layer,this.layerConfig)),Object.keys(A(this,$t)).length!==0&&ee(this,Qt,A(this,$t)),customElements.get("eox-jsonform")||console.error("Please import @eox/jsonform in order to use layerconfig");const n={disable_edit_json:!0,disable_collapse:!0,disable_properties:!0};return $`
|
|
122
119
|
<style>
|
|
123
120
|
${A(this,Je)}
|
|
124
121
|
${!this.unstyled&&A(this,Ke)}
|
|
125
122
|
</style>
|
|
126
|
-
${Z(this.layerConfig,()
|
|
127
|
-
${Z(this.layerConfig.legend,()
|
|
123
|
+
${Z(this.layerConfig,()=>$`
|
|
124
|
+
${Z(this.layerConfig.legend,()=>$`
|
|
128
125
|
<eox-layercontrol-layer-legend
|
|
129
126
|
.noShadow=${!0}
|
|
130
127
|
.unstyled=${this.unstyled}
|
|
131
128
|
.layer=${this.layer}
|
|
132
|
-
.layerLegend=${
|
|
129
|
+
.layerLegend=${ks(this.layerConfig.legend,A(this,$t))}
|
|
133
130
|
></eox-layercontrol-layer-legend>
|
|
134
131
|
`)}
|
|
135
132
|
<!-- Render a JSON form for layer configuration -->
|
|
136
133
|
<eox-jsonform
|
|
137
134
|
.schema=${this.layerConfig.schema}
|
|
138
|
-
.value=${A(this,
|
|
135
|
+
.value=${A(this,Qt)}
|
|
139
136
|
.options=${n}
|
|
140
137
|
@change=${this.throttleDataChange}
|
|
141
138
|
></eox-jsonform>
|
|
142
139
|
`)}
|
|
143
|
-
`}}
|
|
140
|
+
`}}$t=new WeakMap,Qt=new WeakMap,$e=new WeakMap,xe=new WeakSet,ri=function(n){ee(this,$t,n.detail),this.layerConfig.type==="style"||this.layerConfig.style?"setStyle"in this.layer||"updateStyleVariables"in this.layer?Vs(A(this,$t),this.layer,this.layerConfig):console.error(`Layer type ${this.layer.get("type")??""} does not support styles configuration`):ee(this,$e,Hs(A(this,$t),A(this,$e),this)),this.requestUpdate()},Je=new WeakMap,Ke=new WeakMap,V($o,"properties",{layer:{attribute:!1},unstyled:{type:Boolean},noShadow:{type:Boolean},layerConfig:{attribute:!1}}),customElements.define("eox-layercontrol-layerconfig",$o);class xo extends tt{constructor(){super();O(this,Qe);O(this,tn,"");O(this,en,"");this.unstyled=!1,this.noShadow=!1,this.layerDatetime=null,this.layer=null}createRenderRoot(){return this.noShadow?this:super.createRenderRoot()}render(){return customElements.get("eox-timecontrol")||console.error("Please import @eox/timecontrol in order to use layerDatetime"),$`
|
|
144
141
|
<style>
|
|
145
142
|
${A(this,tn)}
|
|
146
143
|
${!this.unstyled&&A(this,en)}
|
|
147
144
|
</style>
|
|
148
|
-
${Z(this.layerDatetime,()
|
|
145
|
+
${Z(this.layerDatetime,()=>$`
|
|
149
146
|
<!-- Render a Timecontrol for layer date time -->
|
|
150
147
|
<eox-timecontrol
|
|
151
148
|
?unstyled=${this.unstyled}
|
|
@@ -156,10 +153,10 @@
|
|
|
156
153
|
.controlValues=${this.layerDatetime.controlValues}
|
|
157
154
|
.controlProperty=${void 0}
|
|
158
155
|
current-step=${this.layerDatetime.currentStep}
|
|
159
|
-
@stepchange=${j(this,Qe,
|
|
156
|
+
@stepchange=${j(this,Qe,Vo)}
|
|
160
157
|
></eox-timecontrol>
|
|
161
158
|
`)}
|
|
162
|
-
`}}Qe=new WeakSet,
|
|
159
|
+
`}}Qe=new WeakSet,Vo=function(n){this.dispatchEvent(new CustomEvent("datetime:updated",{bubbles:!0,detail:{datetime:n.detail.currentStep,layer:this.layer}})),this.layerDatetime.currentStep=n.detail.currentStep,this.requestUpdate()},tn=new WeakMap,en=new WeakMap,V(xo,"properties",{unstyled:{type:Boolean},noShadow:{type:Boolean},layerDatetime:{attribute:!1},layer:{attribute:!1}}),customElements.define("eox-layercontrol-layer-datetime",xo);class Eo extends tt{constructor(){super();O(this,Ee,n=>(this.selectedTab===n||this.toolsAsList)&&"highlighted");O(this,nn,`
|
|
163
160
|
.tabbed figure {
|
|
164
161
|
margin: 0;
|
|
165
162
|
}
|
|
@@ -205,44 +202,44 @@
|
|
|
205
202
|
background: #00417011;
|
|
206
203
|
border-top: 1px solid #0041701a;
|
|
207
204
|
}
|
|
208
|
-
`);this.actions=[],this.selectedTab=0,this.tabs=[],this.unstyled=!1,this.noShadow=!1,this.toolsAsList=!1}createRenderRoot(){return this.noShadow?this:super.createRenderRoot()}render(){const n=this.tabs,i=this.actions,o=i.length+n.length>1;return
|
|
205
|
+
`);this.actions=[],this.selectedTab=0,this.tabs=[],this.unstyled=!1,this.noShadow=!1,this.toolsAsList=!1}createRenderRoot(){return this.noShadow?this:super.createRenderRoot()}render(){const n=this.tabs,i=this.actions,o=i.length+n.length>1;return $`
|
|
209
206
|
<style>
|
|
210
207
|
${A(this,nn)}
|
|
211
208
|
${!this.unstyled&&A(this,on)}
|
|
212
209
|
</style>
|
|
213
210
|
<div class="tabbed">
|
|
214
211
|
<!-- Navigation for tabs and actions -->
|
|
215
|
-
${Z(o,()
|
|
212
|
+
${Z(o,()=>$`
|
|
216
213
|
<nav>
|
|
217
|
-
${Z(!this.toolsAsList,()
|
|
214
|
+
${Z(!this.toolsAsList,()=>$`
|
|
218
215
|
<div>
|
|
219
216
|
<!-- Labels for tabs -->
|
|
220
|
-
${Xe(n,(r,s)
|
|
221
|
-
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
|
|
227
|
-
|
|
228
|
-
|
|
217
|
+
${Xe(n,(r,s)=>$`
|
|
218
|
+
<label
|
|
219
|
+
class=${A(this,Ee).call(this,s)}
|
|
220
|
+
@click=${()=>this.selectedTab=s}
|
|
221
|
+
>
|
|
222
|
+
<!-- Customizable icon for each tab -->
|
|
223
|
+
<slot name=${`${r}-icon`}>${r}</slot>
|
|
224
|
+
</label>
|
|
225
|
+
`)}
|
|
229
226
|
</div>
|
|
230
227
|
<div>
|
|
231
228
|
<!-- Icons for actions -->
|
|
232
|
-
${Xe(i,r
|
|
233
|
-
|
|
234
|
-
|
|
235
|
-
|
|
236
|
-
|
|
237
|
-
|
|
229
|
+
${Xe(i,r=>$`
|
|
230
|
+
<span>
|
|
231
|
+
<!-- Customizable icon for each action -->
|
|
232
|
+
<slot name=${`${r}-icon`}>${r}</slot>
|
|
233
|
+
</span>
|
|
234
|
+
`)}
|
|
238
235
|
</div>
|
|
239
236
|
`)}
|
|
240
237
|
</nav>
|
|
241
238
|
`)}
|
|
242
239
|
<figure>
|
|
243
240
|
<!-- Content for each tab -->
|
|
244
|
-
${Xe(n,(r,s)
|
|
245
|
-
${Z(this.toolsAsList,()
|
|
241
|
+
${Xe(n,(r,s)=>$`
|
|
242
|
+
${Z(this.toolsAsList,()=>$`
|
|
246
243
|
<label class="listed">
|
|
247
244
|
<!-- Customizable icon for each tab -->
|
|
248
245
|
<slot name=${`${r}-icon`}>${r}</slot>
|
|
@@ -255,7 +252,7 @@
|
|
|
255
252
|
`)}
|
|
256
253
|
</figure>
|
|
257
254
|
</div>
|
|
258
|
-
`}}Ee=new WeakMap,nn=new WeakMap,on=new WeakMap,V(
|
|
255
|
+
`}}Ee=new WeakMap,nn=new WeakMap,on=new WeakMap,V(Eo,"properties",{actions:{attribute:!1},selectedTab:{state:!0},tabs:{attribute:!1},unstyled:{type:Boolean},noShadow:{type:Boolean},toolsAsList:{type:Boolean}}),customElements.define("eox-layercontrol-tools-items",Eo);const ha=`
|
|
259
256
|
button,
|
|
260
257
|
.button {
|
|
261
258
|
/* TODO: why does this only work here and not from :root? */
|
|
@@ -379,7 +376,7 @@ button.smallest.icon::before {
|
|
|
379
376
|
width: 16px;
|
|
380
377
|
padding: 0px;
|
|
381
378
|
}
|
|
382
|
-
`,
|
|
379
|
+
`,pa=`
|
|
383
380
|
input[type=radio] {
|
|
384
381
|
appearance: none;
|
|
385
382
|
-webkit-appearance: none;
|
|
@@ -430,7 +427,7 @@ input[type=checkbox]:checked:after {
|
|
|
430
427
|
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");
|
|
431
428
|
|
|
432
429
|
}
|
|
433
|
-
`,
|
|
430
|
+
`,fa=`
|
|
434
431
|
input[type="range"] {
|
|
435
432
|
-webkit-appearance: none;
|
|
436
433
|
width: 90%;
|
|
@@ -507,9 +504,9 @@ input[type="range"]:focus::-webkit-slider-thumb {
|
|
|
507
504
|
input::-moz-focus-inner, input::-moz-focus-outer {
|
|
508
505
|
border: 0;
|
|
509
506
|
}
|
|
510
|
-
`;class Ao extends tt{constructor(){super();V(this,"_removeButton",()=>
|
|
507
|
+
`;class Ao extends tt{constructor(){super();V(this,"_removeButton",()=>zs(this));V(this,"_sortButton",()=>Xs(this.unstyled));V(this,"_button",n=>Zs(n,this.unstyled));V(this,"_getDefaultTools",()=>{var n;return $`
|
|
511
508
|
<div slot="info-content">
|
|
512
|
-
${
|
|
509
|
+
${qs(this.layer.get("description"))}
|
|
513
510
|
</div>
|
|
514
511
|
<div slot="opacity-content">
|
|
515
512
|
<!-- Input for opacity -->
|
|
@@ -524,7 +521,7 @@ input::-moz-focus-inner, input::-moz-focus-outer {
|
|
|
524
521
|
</div>
|
|
525
522
|
<div slot="config-content">
|
|
526
523
|
<!-- Layer configuration -->
|
|
527
|
-
${Z(this.layer.get("layerConfig"),()
|
|
524
|
+
${Z(this.layer.get("layerConfig"),()=>$`
|
|
528
525
|
<eox-layercontrol-layerconfig
|
|
529
526
|
slot="config-content"
|
|
530
527
|
.layer=${this.layer}
|
|
@@ -537,7 +534,7 @@ input::-moz-focus-inner, input::-moz-focus-outer {
|
|
|
537
534
|
</div>
|
|
538
535
|
<div slot="datetime-content">
|
|
539
536
|
<!-- Layer datetime -->
|
|
540
|
-
${Z(this.layer.get("layerDatetime"),()
|
|
537
|
+
${Z(this.layer.get("layerDatetime"),()=>$`
|
|
541
538
|
<eox-layercontrol-layer-datetime
|
|
542
539
|
slot="datetime-content"
|
|
543
540
|
.noShadow=${!0}
|
|
@@ -550,7 +547,7 @@ input::-moz-focus-inner, input::-moz-focus-outer {
|
|
|
550
547
|
</div>
|
|
551
548
|
<div slot="legend-content">
|
|
552
549
|
<!-- Layer legend -->
|
|
553
|
-
${Z(this.layer.get("layerLegend"),()
|
|
550
|
+
${Z(this.layer.get("layerLegend"),()=>$`
|
|
554
551
|
<eox-layercontrol-layer-legend
|
|
555
552
|
slot="legend-content"
|
|
556
553
|
.noShadow=${!0}
|
|
@@ -564,10 +561,10 @@ input::-moz-focus-inner, input::-moz-focus-outer {
|
|
|
564
561
|
<div slot="remove-icon">${this._removeButton()}</div>
|
|
565
562
|
<div slot="sort-icon">${this._sortButton()}</div>
|
|
566
563
|
`});O(this,rn,"");O(this,sn,`
|
|
567
|
-
${
|
|
568
|
-
${
|
|
564
|
+
${ha}
|
|
565
|
+
${pa}
|
|
569
566
|
${So}
|
|
570
|
-
${
|
|
567
|
+
${fa}
|
|
571
568
|
.drag-handle {
|
|
572
569
|
cursor: n-resize;
|
|
573
570
|
}
|
|
@@ -674,17 +671,17 @@ input::-moz-focus-inner, input::-moz-focus-outer {
|
|
|
674
671
|
[slot=opacity-content] {
|
|
675
672
|
padding: 12px 6px;
|
|
676
673
|
}
|
|
677
|
-
`);this.layer=null,this.tools=[],this.unstyled=!1,this.noShadow=!1,this.toolsAsList=!1}createRenderRoot(){return this.noShadow?this:super.createRenderRoot()}render(){var l;const n=
|
|
674
|
+
`);this.layer=null,this.tools=[],this.unstyled=!1,this.noShadow=!1,this.toolsAsList=!1}createRenderRoot(){return this.noShadow?this:super.createRenderRoot()}render(){var l;const n=Fs(this.tools,this.layer),i=js(this.tools,this.layer),o=this[`_${n==null?void 0:n[0]}Button`]?this[`_${n==null?void 0:n[0]}Button`]():T,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;return $`
|
|
678
675
|
<style>
|
|
679
676
|
${A(this,rn)}
|
|
680
677
|
${!this.unstyled&&A(this,sn)}
|
|
681
678
|
</style>
|
|
682
|
-
${Z(s+a>0,()
|
|
683
|
-
${Z(s===1&&a===0,()
|
|
679
|
+
${Z(s+a>0,()=>$`
|
|
680
|
+
${Z(s===1&&a===0,()=>$`
|
|
684
681
|
<div class="single-action-container">
|
|
685
682
|
<div class="single-action">${o}</div>
|
|
686
683
|
</div>
|
|
687
|
-
`,()
|
|
684
|
+
`,()=>$`
|
|
688
685
|
<details
|
|
689
686
|
class="tools"
|
|
690
687
|
open=${this.layer.get("layerControlToolsExpand")||T}
|
|
@@ -708,7 +705,7 @@ input::-moz-focus-inner, input::-moz-focus-outer {
|
|
|
708
705
|
</details>
|
|
709
706
|
`)}
|
|
710
707
|
`)}
|
|
711
|
-
`}}rn=new WeakMap,sn=new WeakMap,V(Ao,"properties",{layer:{attribute:!1},tools:{attribute:!1},unstyled:{type:Boolean},noShadow:{type:Boolean},toolsAsList:{type:Boolean}}),customElements.define("eox-layercontrol-layer-tools",Ao);const
|
|
708
|
+
`}}rn=new WeakMap,sn=new WeakMap,V(Ao,"properties",{layer:{attribute:!1},tools:{attribute:!1},unstyled:{type:Boolean},noShadow:{type:Boolean},toolsAsList:{type:Boolean}}),customElements.define("eox-layercontrol-layer-tools",Ao);const ga=e=>{const t=()=>{const n=Is(e.layer,e.map,e.showLayerZoomState);let i=!1;!n&&e.currLayerVisibilityBasedOnZoom?(e.currLayerVisibilityBasedOnZoom=!1,i=!0):n&&!e.currLayerVisibilityBasedOnZoom&&(e.currLayerVisibilityBasedOnZoom=!0,i=!0),i&&(e.requestUpdate(),e.dispatchEvent(new CustomEvent("change:resolution",{bubbles:!0})))};co(e.layer,e.showLayerZoomState)&&(t(),e.map.getView().on("change:resolution",()=>t()))},ma=(e,t)=>{const n=t.layer;n.setVisible(e.target.checked),e.target.checked&&n.get("layerControlExclusive")&&t.closest(".layers > ul").querySelectorAll("eox-layercontrol-layer").forEach(o=>{var r;o.layer!==n&&((r=o.layer)!=null&&r.get("layerControlExclusive"))&&(o.layer.setVisible(!1),o.requestUpdate())}),t.dispatchEvent(new CustomEvent("changed",{bubbles:!0,detail:n})),t.requestUpdate()};class _o extends tt{constructor(){super();O(this,Pt);V(this,"currLayerVisibilityBasedOnZoom",!0);O(this,an,"");O(this,ln,`
|
|
712
709
|
${So}
|
|
713
710
|
eox-layercontrol-layer {
|
|
714
711
|
width: 100%;
|
|
@@ -749,12 +746,12 @@ input::-moz-focus-inner, input::-moz-focus-outer {
|
|
|
749
746
|
[data-type=draw] .title::before {
|
|
750
747
|
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");
|
|
751
748
|
}
|
|
752
|
-
`);this.layer=null,this.map=null,this.titleProperty="title",this.showLayerZoomState=!1,this.tools=[],this.unstyled=!1,this.noShadow=!1,this.toolsAsList=!1}createRenderRoot(){return this.noShadow?this:super.createRenderRoot()}firstUpdated(){
|
|
749
|
+
`);this.layer=null,this.map=null,this.titleProperty="title",this.showLayerZoomState=!1,this.tools=[],this.unstyled=!1,this.noShadow=!1,this.toolsAsList=!1}createRenderRoot(){return this.noShadow?this:super.createRenderRoot()}firstUpdated(){ga(this)}render(){var l;const n=this.layer.getVisible(),i=n?"visible":"",o=this.currLayerVisibilityBasedOnZoom?"":"zoom-state-invisible",r=j(this,Pt,bn).call(this,"layerControlDisable")?"disabled":"",s=j(this,Pt,bn).call(this,"layerControlExclusive")?"radio":"checkbox",a=((l=this.tools)==null?void 0:l.length)>0;return $`
|
|
753
750
|
<style>
|
|
754
751
|
${A(this,an)}
|
|
755
752
|
${!this.unstyled&&A(this,ln)}
|
|
756
753
|
</style>
|
|
757
|
-
${Z(this.layer,()
|
|
754
|
+
${Z(this.layer,()=>$`
|
|
758
755
|
<!-- Render the layer -->
|
|
759
756
|
<div class="layer ${i} ${o}">
|
|
760
757
|
<label class="drag-handle ${r}">
|
|
@@ -762,12 +759,12 @@ input::-moz-focus-inner, input::-moz-focus-outer {
|
|
|
762
759
|
<input
|
|
763
760
|
type=${s}
|
|
764
761
|
.checked=${fo(n)}
|
|
765
|
-
@click=${j(this,Pt,
|
|
762
|
+
@click=${j(this,Pt,Bo)}
|
|
766
763
|
/>
|
|
767
764
|
|
|
768
765
|
<!-- Layer title -->
|
|
769
766
|
<span class="title">${j(this,Pt,bn).call(this,this.titleProperty)}</span>
|
|
770
|
-
${Z(a,()
|
|
767
|
+
${Z(a,()=>$`<span class="tools-placeholder"></span>`)}
|
|
771
768
|
</label>
|
|
772
769
|
</div>
|
|
773
770
|
|
|
@@ -780,7 +777,7 @@ input::-moz-focus-inner, input::-moz-focus-outer {
|
|
|
780
777
|
.toolsAsList=${this.toolsAsList}
|
|
781
778
|
></eox-layercontrol-layer-tools>
|
|
782
779
|
`)}
|
|
783
|
-
`}}Pt=new WeakSet,bn=function(n){var i;return(i=this.layer)==null?void 0:i.get(n)},
|
|
780
|
+
`}}Pt=new WeakSet,bn=function(n){var i;return(i=this.layer)==null?void 0:i.get(n)},Bo=function(n){ma(n,this)},an=new WeakMap,ln=new WeakMap,V(_o,"properties",{layer:{attribute:!1},map:{attribute:!1,state:!0},titleProperty:{attribute:"title-property",type:String},showLayerZoomState:{attribute:"show-layer-zoom-state",type:Boolean},tools:{attribute:!1},unstyled:{type:Boolean},noShadow:{type:Boolean},toolsAsList:{type:Boolean}}),customElements.define("eox-layercontrol-layer",_o);class Co extends tt{constructor(){super();O(this,dn,"");O(this,un,`
|
|
784
781
|
details summary {
|
|
785
782
|
cursor: pointer;
|
|
786
783
|
display: flex;
|
|
@@ -804,12 +801,12 @@ input::-moz-focus-inner, input::-moz-focus-outer {
|
|
|
804
801
|
details[data-children-length="0"] summary::before {
|
|
805
802
|
display: none;
|
|
806
803
|
}
|
|
807
|
-
`);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}createRenderRoot(){return this.noShadow?this:super.createRenderRoot()}render(){var o,r;const n=!!((o=this.group)!=null&&o.get("layerControlExpand")),i=(r=po(this.group.getLayers()))==null?void 0:r.length;return
|
|
804
|
+
`);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}createRenderRoot(){return this.noShadow?this:super.createRenderRoot()}render(){var o,r;const n=!!((o=this.group)!=null&&o.get("layerControlExpand")),i=(r=po(this.group.getLayers()))==null?void 0:r.length;return $`
|
|
808
805
|
<style>
|
|
809
806
|
${A(this,dn)}
|
|
810
807
|
${!this.unstyled&&A(this,un)}
|
|
811
808
|
</style>
|
|
812
|
-
${Z(this.group,()
|
|
809
|
+
${Z(this.group,()=>$`
|
|
813
810
|
<!-- Render the details element with the layer control -->
|
|
814
811
|
<details
|
|
815
812
|
open=${n||T}
|
|
@@ -845,7 +842,7 @@ input::-moz-focus-inner, input::-moz-focus-outer {
|
|
|
845
842
|
></eox-layercontrol-layer-list>
|
|
846
843
|
</details>
|
|
847
844
|
`)}
|
|
848
|
-
`}}dn=new WeakMap,un=new WeakMap,V(
|
|
845
|
+
`}}dn=new WeakMap,un=new WeakMap,V(Co,"properties",{group:{attribute:!1},idProperty:{attribute:"id-property"},map:{attribute:!1,state:!0},titleProperty:{attribute:"title-property",type:String},showLayerZoomState:{attribute:"show-layer-zoom-state",type:Boolean},tools:{attribute:!1},unstyled:{type:Boolean},noShadow:{type:Boolean},toolsAsList:{type:Boolean}}),customElements.define("eox-layercontrol-layer-group",Co);var ya="Expected a function",To=NaN,ba="[object Symbol]",va=/^\s+|\s+$/g,wa=/^[-+]0x[0-9a-f]+$/i,$a=/^0b[01]+$/i,xa=/^0o[0-7]+$/i,Ea=parseInt,Sa=typeof Tt=="object"&&Tt&&Tt.Object===Object&&Tt,Aa=typeof self=="object"&&self&&self.Object===Object&&self,_a=Sa||Aa||Function("return this")(),Ca=Object.prototype,Ta=Ca.toString,Pa=Math.max,Oa=Math.min,ei=function(){return _a.Date.now()};function Da(e,t,n){var i,o,r,s,a,l,d=0,c=!1,u=!1,p=!0;if(typeof e!="function")throw new TypeError(ya);t=Po(t)||0,ni(n)&&(c=!!n.leading,u="maxWait"in n,r=u?Pa(Po(n.maxWait)||0,t):r,p="trailing"in n?!!n.trailing:p);function f(b){var L=i,K=o;return i=o=void 0,d=b,s=e.apply(K,L),s}function g(b){return d=b,a=setTimeout(H,t),c?f(b):s}function y(b){var L=b-l,K=b-d,z=t-L;return u?Oa(z,r-K):z}function R(b){var L=b-l,K=b-d;return l===void 0||L>=t||L<0||u&&K>=r}function H(){var b=ei();if(R(b))return k(b);a=setTimeout(H,y(b))}function k(b){return a=void 0,p&&i?f(b):(i=o=void 0,s)}function nt(){a!==void 0&&clearTimeout(a),d=0,i=l=o=a=void 0}function J(){return a===void 0?s:k(ei())}function it(){var b=ei(),L=R(b);if(i=arguments,o=this,l=b,L){if(a===void 0)return g(l);if(u)return a=setTimeout(H,t),f(l)}return a===void 0&&(a=setTimeout(H,t)),s}return it.cancel=nt,it.flush=J,it}function ni(e){var t=typeof e;return!!e&&(t=="object"||t=="function")}function Ra(e){return!!e&&typeof e=="object"}function La(e){return typeof e=="symbol"||Ra(e)&&Ta.call(e)==ba}function Po(e){if(typeof e=="number")return e;if(La(e))return To;if(ni(e)){var t=typeof e.valueOf=="function"?e.valueOf():e;e=ni(t)?t+"":t}if(typeof e!="string")return e===0?e:+e;e=e.replace(va,"");var n=$a.test(e);return n||xa.test(e)?Ea(e.slice(2),n?2:8):wa.test(e)?To:+e}var Ma=Da;const Ia=go(Ma),Na=e=>{const{layers:t,idProperty:n,titleProperty:i,renderRoot:o}=e,r=Ia(()=>{e.requestUpdate(),e.dispatchEvent(new CustomEvent("changed",{bubbles:!0}))},50),s=()=>r();if(t&&(t.hasListener("change:length")&&(t==null||t.un("change:length",s)),t.on("change:length",s),t)){const a=o.querySelector("ul");Ms(t,n,i,e),Ls(a,t,n,e)}};class Oo extends tt{constructor(){super();O(this,cn,"");O(this,hn,`
|
|
849
846
|
ul {
|
|
850
847
|
padding: 0;
|
|
851
848
|
margin: 0;
|
|
@@ -871,19 +868,19 @@ input::-moz-focus-inner, input::-moz-focus-outer {
|
|
|
871
868
|
}
|
|
872
869
|
li.sortable-ghost {
|
|
873
870
|
}
|
|
874
|
-
`);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}firstUpdated(){
|
|
871
|
+
`);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}firstUpdated(){Na(this)}createRenderRoot(){return this.noShadow?this:super.createRenderRoot()}render(){const n=this.layers?po(this.layers).reverse():[];return $`
|
|
875
872
|
<style>
|
|
876
873
|
${A(this,cn)}
|
|
877
874
|
${!this.unstyled&&A(this,hn)}
|
|
878
875
|
</style>
|
|
879
876
|
<ul>
|
|
880
|
-
${Z(this.layers,()
|
|
881
|
-
${
|
|
877
|
+
${Z(this.layers,()=>$`
|
|
878
|
+
${ur(n,i=>i,i=>$`
|
|
882
879
|
<li
|
|
883
880
|
data-layer="${i.get(this.idProperty)}"
|
|
884
|
-
data-type="${
|
|
881
|
+
data-type="${Ns(i,this.map)}"
|
|
885
882
|
>
|
|
886
|
-
${i.getLayers
|
|
883
|
+
${i.getLayers?$`
|
|
887
884
|
<eox-layercontrol-layer-group
|
|
888
885
|
.noShadow=${!0}
|
|
889
886
|
.group=${i}
|
|
@@ -897,7 +894,7 @@ input::-moz-focus-inner, input::-moz-focus-outer {
|
|
|
897
894
|
@changed=${()=>this.requestUpdate()}
|
|
898
895
|
>
|
|
899
896
|
</eox-layercontrol-layer-group>
|
|
900
|
-
|
|
897
|
+
`:$`
|
|
901
898
|
<eox-layercontrol-layer
|
|
902
899
|
.noShadow=${!0}
|
|
903
900
|
.layer=${i}
|
|
@@ -914,7 +911,7 @@ input::-moz-focus-inner, input::-moz-focus-outer {
|
|
|
914
911
|
`)}
|
|
915
912
|
`)}
|
|
916
913
|
</ul>
|
|
917
|
-
`}}cn=new WeakMap,hn=new WeakMap,V(Oo,"properties",{idProperty:{attribute:"id-property"},layers:{attribute:!1},map:{attribute:!1,state:!0},titleProperty:{attribute:"title-property",type:String},showLayerZoomState:{attribute:"show-layer-zoom-state",type:Boolean},tools:{attribute:!1},unstyled:{type:Boolean},noShadow:{type:Boolean},toolsAsList:{type:Boolean}}),customElements.define("eox-layercontrol-layer-list",Oo);const
|
|
914
|
+
`}}cn=new WeakMap,hn=new WeakMap,V(Oo,"properties",{idProperty:{attribute:"id-property"},layers:{attribute:!1},map:{attribute:!1,state:!0},titleProperty:{attribute:"title-property",type:String},showLayerZoomState:{attribute:"show-layer-zoom-state",type:Boolean},tools:{attribute:!1},unstyled:{type:Boolean},noShadow:{type:Boolean},toolsAsList:{type:Boolean}}),customElements.define("eox-layercontrol-layer-list",Oo);const Ha=e=>{const t=e.querySelector("select[name=optional]"),n=t?t.value:null,i=Jn(e.layers.getArray(),"layerControlOptional",!0).find(o=>(o.get(e.idProperty)||o.ol_uid)===n);i==null||i.set("layerControlOptional",!1),i==null||i.setVisible(!0),e.dispatchEvent(new CustomEvent("changed",{bubbles:!0})),e.renderRoot.parentNode.querySelectorAll("eox-layercontrol-layer-list").forEach(o=>o.requestUpdate()),e.requestUpdate()};class Do extends tt{constructor(){super();O(this,pn);this.idProperty="id",this.layers=null,this.titleProperty="title",this.unstyled=!1,this.noShadow=!1}createRenderRoot(){return this.noShadow?this:super.createRenderRoot()}render(){const n=Jn(this.layers.getArray(),"layerControlOptional",!0);return $`
|
|
918
915
|
<!-- Label for the dropdown -->
|
|
919
916
|
<label for="optional">Optional layers</label>
|
|
920
917
|
|
|
@@ -926,12 +923,12 @@ input::-moz-focus-inner, input::-moz-focus-outer {
|
|
|
926
923
|
</option>
|
|
927
924
|
|
|
928
925
|
<!-- Mapping through filtered layers list to generate dropdown options -->
|
|
929
|
-
${n.map(i=>{const o=i.get(this.idProperty)||i.ol_uid,r=i.get(this.titleProperty),s=`layer ${i.get(this.idProperty)}`;return
|
|
926
|
+
${n.map(i=>{const o=i.get(this.idProperty)||i.ol_uid,r=i.get(this.titleProperty),s=`layer ${i.get(this.idProperty)}`;return $` <option value="${o}">${r||s}</option> `})}
|
|
930
927
|
</select>
|
|
931
928
|
|
|
932
929
|
<!-- Button to handle adding layers -->
|
|
933
|
-
<button @click="${j(this,pn,
|
|
934
|
-
`}}pn=new WeakSet,
|
|
930
|
+
<button @click="${j(this,pn,ko)}">add</button>
|
|
931
|
+
`}}pn=new WeakSet,ko=function(){Ha(this)},V(Do,"properties",{idProperty:{attribute:"id-property"},layers:{attribute:!1},titleProperty:{attribute:"title-property",type:String},unstyled:{type:Boolean},noShadow:{type:Boolean}}),customElements.define("eox-layercontrol-optional-list",Do);const Va=(e,t)=>{t.jsonInput=e.target.value,t.requestUpdate()},Ro=e=>{const t=JSON.parse(`{"data":${Bi(e.jsonInput)}}`);Array.isArray(t.data)?t.data.forEach(n=>{e.eoxMap.addOrUpdateLayer(n)}):e.eoxMap.addOrUpdateLayer(t.data),e.jsonInput=null,e.requestUpdate()},Ba=(e,t)=>{t.urlInput=e.target.value,t.requestUpdate()};async function ka(e){const t=e.urlInput;if(e.wmsCapabilities=null,e.searchLoad=!0,e.requestUpdate(),!t)return!1;if(Mn(t)==="XYZ")return{Name:t};try{const n=await ns(t);e.wmsCapabilities=n}catch{}finally{e.searchLoad=!1,e.requestUpdate()}return!1}const Ua=(e,t)=>{const{Name:n}=e,i=Mn(t.urlInput)||"XYZ",o={type:"Tile",properties:{id:n,title:n},source:{type:i,url:t.urlInput,params:{LAYERS:n}}};t.jsonInput=JSON.stringify(o)},Fa=(e,t)=>{t.open=e||null,t.urlInput=null,t.jsonInput=null,t.wmsCapabilities=null,t.requestUpdate()};class Lo extends tt{constructor(){super();O(this,G);V(this,"urlInput",null);V(this,"jsonInput",null);V(this,"open",null);V(this,"searchLoad",!1);V(this,"wmsCapabilities",null);O(this,fn,`
|
|
935
932
|
.eox-add-layer-main .open {
|
|
936
933
|
position: relative;
|
|
937
934
|
}
|
|
@@ -1071,7 +1068,7 @@ input::-moz-focus-inner, input::-moz-focus-outer {
|
|
|
1071
1068
|
font-weight: bold;
|
|
1072
1069
|
display: inline-block;
|
|
1073
1070
|
}
|
|
1074
|
-
`);this.eoxMap=null,this.unstyled=!1,this.noShadow=!1}createRenderRoot(){return this.noShadow?this:super.createRenderRoot()}render(){const n=this.open?"open":"close",i=this.open==="url",o=this.open==="json",r=!
|
|
1071
|
+
`);this.eoxMap=null,this.unstyled=!1,this.noShadow=!1}createRenderRoot(){return this.noShadow?this:super.createRenderRoot()}render(){const n=this.open?"open":"close",i=this.open==="url",o=this.open==="json",r=!is(this.urlInput)||this.searchLoad?!0:T;return $`
|
|
1075
1072
|
<style>
|
|
1076
1073
|
${A(this,fn)}
|
|
1077
1074
|
${!this.unstyled&&A(this,gn)}
|
|
@@ -1103,7 +1100,7 @@ input::-moz-focus-inner, input::-moz-focus-outer {
|
|
|
1103
1100
|
</button>
|
|
1104
1101
|
</div>
|
|
1105
1102
|
<div class="eox-add ${n}">
|
|
1106
|
-
${i
|
|
1103
|
+
${i?$`
|
|
1107
1104
|
<!-- Input field for URL -->
|
|
1108
1105
|
<div class="eox-add-layer-col">
|
|
1109
1106
|
<input
|
|
@@ -1111,22 +1108,22 @@ input::-moz-focus-inner, input::-moz-focus-outer {
|
|
|
1111
1108
|
class="add-url"
|
|
1112
1109
|
placeholder="Add URL (WMS/XYZ)"
|
|
1113
1110
|
.value="${this.urlInput}"
|
|
1114
|
-
@input=${j(this,G,
|
|
1111
|
+
@input=${j(this,G,Uo)}
|
|
1115
1112
|
>
|
|
1116
1113
|
</input>
|
|
1117
1114
|
<!-- Search button for URL -->
|
|
1118
1115
|
<button
|
|
1119
1116
|
class="search-icon"
|
|
1120
1117
|
disabled=${r}
|
|
1121
|
-
@click=${j(this,G,
|
|
1118
|
+
@click=${j(this,G,Fo)}
|
|
1122
1119
|
>
|
|
1123
1120
|
${this.unstyled?"Search":""}
|
|
1124
1121
|
</button>
|
|
1125
1122
|
</div>
|
|
1126
1123
|
|
|
1127
1124
|
<!-- Display layers for WMS capabilities -->
|
|
1128
|
-
${this.wmsCapabilities
|
|
1129
|
-
${this.wmsCapabilities.Capability.Layer.Layer.map(s=>{const a=s.Name;return
|
|
1125
|
+
${this.wmsCapabilities?$`<ul class="search-lists">
|
|
1126
|
+
${this.wmsCapabilities.Capability.Layer.Layer.map(s=>{const a=s.Name;return $`
|
|
1130
1127
|
<li class="search-list">
|
|
1131
1128
|
${a}
|
|
1132
1129
|
<!-- Button to add layer -->
|
|
@@ -1139,27 +1136,27 @@ input::-moz-focus-inner, input::-moz-focus-outer {
|
|
|
1139
1136
|
</li>
|
|
1140
1137
|
`})}
|
|
1141
1138
|
</ul>`:T}
|
|
1142
|
-
|
|
1139
|
+
`:$`
|
|
1143
1140
|
<!-- Textarea for JSON input -->
|
|
1144
1141
|
<textarea
|
|
1145
1142
|
class="add-layer-input"
|
|
1146
1143
|
placeholder="Please put a valid eox-map layer JSON."
|
|
1147
|
-
@input=${j(this,G,
|
|
1144
|
+
@input=${j(this,G,Zo)}
|
|
1148
1145
|
.value=${this.jsonInput}
|
|
1149
1146
|
></textarea>
|
|
1150
1147
|
|
|
1151
1148
|
<!-- Button to add JSON layer -->
|
|
1152
1149
|
<button
|
|
1153
1150
|
class="add-layer-icon json-add-layer"
|
|
1154
|
-
disabled=${
|
|
1155
|
-
@click=${j(this,G,
|
|
1151
|
+
disabled=${os(this.jsonInput)?T:!0}
|
|
1152
|
+
@click=${j(this,G,jo)}
|
|
1156
1153
|
>
|
|
1157
1154
|
${this.unstyled?"Add JSON":""}
|
|
1158
1155
|
</button>
|
|
1159
1156
|
`}
|
|
1160
1157
|
</div>
|
|
1161
1158
|
</div>
|
|
1162
|
-
`}}G=new WeakSet,
|
|
1159
|
+
`}}G=new WeakSet,Uo=function(n){Ba(n,this)},Fo=async function(){const n=await ka(this);n&&j(this,G,si).call(this,n)},si=function(n){Ua(n,this),Ro(this)},jo=function(){Ro(this)},Zo=function(n){Va(n,this)},vn=function(n){Fa(n,this)},fn=new WeakMap,gn=new WeakMap,V(Lo,"properties",{eoxMap:{attribute:!1,state:!0},unstyled:{type:Boolean},noShadow:{type:Boolean}}),customElements.define("eox-layercontrol-add-layers",Lo);const ja=(e,t)=>{if(t.requestUpdate(),e.target.tagName==="EOX-LAYERCONTROL-LAYER-TOOLS"){const n=t.renderRoot.querySelector("eox-layercontrol-optional-list");n==null||n.requestUpdate()}},Za=e=>{let t;return typeof e=="string"?t=document.querySelector(e):t=e,t},Mo=e=>{const t=Za(e.for);return t&&t.map!==e.map&&(e.map=t.map),t};class ii extends tt{constructor(){super();O(this,te);O(this,Ot);O(this,mn,`
|
|
1163
1160
|
:host, :root {
|
|
1164
1161
|
font-family: Roboto, sans-serif;
|
|
1165
1162
|
--padding: 0.5rem;
|
|
@@ -1167,14 +1164,14 @@ input::-moz-focus-inner, input::-moz-focus-outer {
|
|
|
1167
1164
|
display: block;
|
|
1168
1165
|
padding: var(--padding) 0;
|
|
1169
1166
|
}
|
|
1170
|
-
`);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}firstUpdated(){this.eoxMap=Mo(this)}updated(n){n.has("for")&&(this.eoxMap=Mo(this))}get eoxMap(){return A(this,Ot)}set eoxMap(n){const i=A(this,Ot);
|
|
1167
|
+
`);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}firstUpdated(){this.eoxMap=Mo(this)}updated(n){n.has("for")&&(this.eoxMap=Mo(this))}get eoxMap(){return A(this,Ot)}set eoxMap(n){const i=A(this,Ot);ee(this,Ot,n),this.requestUpdate("eoxMap",i)}render(){var o,r,s;const n=(o=this.map)==null?void 0:o.getLayers().getArray(),i=n&&((r=Jn(n,"layerControlOptional",!0))==null?void 0:r.length)>0;return $`
|
|
1171
1168
|
<style>
|
|
1172
1169
|
${!this.unstyled&&A(this,mn)}
|
|
1173
1170
|
${this.styleOverride}
|
|
1174
1171
|
</style>
|
|
1175
1172
|
|
|
1176
1173
|
<!-- Conditional rendering of add layers component -->
|
|
1177
|
-
${Z(this.addExternalLayers&&((s=A(this,Ot))==null?void 0:s.addOrUpdateLayer),()
|
|
1174
|
+
${Z(this.addExternalLayers&&((s=A(this,Ot))==null?void 0:s.addOrUpdateLayer),()=>$`
|
|
1178
1175
|
<eox-layercontrol-add-layers
|
|
1179
1176
|
.noShadow=${!0}
|
|
1180
1177
|
.eoxMap=${A(this,Ot)}
|
|
@@ -1183,7 +1180,7 @@ input::-moz-focus-inner, input::-moz-focus-outer {
|
|
|
1183
1180
|
`)}
|
|
1184
1181
|
|
|
1185
1182
|
<!-- Conditional rendering of layer list component -->
|
|
1186
|
-
${Z(this.map,()
|
|
1183
|
+
${Z(this.map,()=>$`
|
|
1187
1184
|
<eox-layercontrol-layer-list
|
|
1188
1185
|
.noShadow=${!0}
|
|
1189
1186
|
class="layers"
|
|
@@ -1195,13 +1192,13 @@ input::-moz-focus-inner, input::-moz-focus-outer {
|
|
|
1195
1192
|
.tools=${this.tools}
|
|
1196
1193
|
.unstyled=${this.unstyled}
|
|
1197
1194
|
.toolsAsList=${this.toolsAsList}
|
|
1198
|
-
@changed=${j(this,
|
|
1199
|
-
@datetime:updated=${j(this,
|
|
1195
|
+
@changed=${j(this,te,zo)}
|
|
1196
|
+
@datetime:updated=${j(this,te,Xo)}
|
|
1200
1197
|
></eox-layercontrol-layer-list>
|
|
1201
1198
|
`)}
|
|
1202
1199
|
|
|
1203
1200
|
<!-- Conditional rendering of optional list component -->
|
|
1204
|
-
${Z(i,()
|
|
1201
|
+
${Z(i,()=>$`
|
|
1205
1202
|
<eox-layercontrol-optional-list
|
|
1206
1203
|
.noShadow=${!0}
|
|
1207
1204
|
.idProperty=${this.idProperty}
|
|
@@ -1210,4 +1207,4 @@ input::-moz-focus-inner, input::-moz-focus-outer {
|
|
|
1210
1207
|
@changed=${()=>this.requestUpdate()}
|
|
1211
1208
|
></eox-layercontrol-optional-list>
|
|
1212
1209
|
`)}
|
|
1213
|
-
`}}Ot=new WeakMap,
|
|
1210
|
+
`}}Ot=new WeakMap,te=new WeakSet,zo=function(n){ja(n,this),this.dispatchEvent(new CustomEvent("layerchange",{detail:n.detail}))},Xo=function(n){this.dispatchEvent(new CustomEvent("datetime:updated",{detail:n.detail}))},mn=new WeakMap,V(ii,"properties",{for:{type:String},idProperty:{attribute:"id-property"},map:{attribute:!1,state:!0},titleProperty:{attribute:"title-property",type:String},showLayerZoomState:{attribute:"show-layer-zoom-state",type:Boolean},tools:{attribute:!1},addExternalLayers:{attribute:!1},unstyled:{type:Boolean},styleOverride:{type:String},toolsAsList:{type:Boolean}}),customElements.define("eox-layercontrol",ii),D.EOxLayerControl=ii,Object.defineProperty(D,Symbol.toStringTag,{value:"Module"})});
|