diff --git a/pr-preview/pr-17/assets/DashboardLayout-B8MEdnS8.js b/pr-preview/pr-17/assets/DashboardLayout-Bklr6-8p.js similarity index 94% rename from pr-preview/pr-17/assets/DashboardLayout-B8MEdnS8.js rename to pr-preview/pr-17/assets/DashboardLayout-Bklr6-8p.js index f5d7d03..418dcc2 100644 --- a/pr-preview/pr-17/assets/DashboardLayout-B8MEdnS8.js +++ b/pr-preview/pr-17/assets/DashboardLayout-Bklr6-8p.js @@ -1,4 +1,4 @@ -import{_ as m,x as y,W as x,X as d,$ as t,a0 as r,a1 as l,a9 as _,a3 as n,a6 as u,a2 as c,a4 as p,d as h,a5 as g,F as f,a7 as v,ab as w}from"./index-BHzPgH2J.js";import{V as k}from"./VMain-CoJ_6Ucg.js";import"./ssrBoot-7hoALQc5.js";class A extends HTMLElement{static get observedAttributes(){return["gap"]}constructor(){super(),this.attachShadow({mode:"open"}),this.render()}render(){this.shadowRoot.innerHTML=` +import{_ as m,x as y,W as x,X as d,$ as t,a0 as r,a1 as l,a9 as _,a3 as n,a6 as u,a2 as c,a4 as p,d as h,a5 as g,F as f,a7 as v,ab as w}from"./index-Dvu417lt.js";import{V as k}from"./VMain-CoSaaYTf.js";import"./ssrBoot-Uu_-yAhn.js";class A extends HTMLElement{static get observedAttributes(){return["gap"]}constructor(){super(),this.attachShadow({mode:"open"}),this.render()}render(){this.shadowRoot.innerHTML=` `,this.shadowRoot)}};cU([Er()],tI.prototype,"propertyTransform");customElements.define("eox-map-tooltip",tI);let uU=class{constructor(t,e,i){var n,r;this.eoxMap=t,this.selectLayer=e,this.options=i,this.active=i.active||e.getVisible(),this.panIn=i.panIn||!1;const o=this.eoxMap.map.getOverlayById("eox-map-tooltip");let a;this.selectedFids=[],o?(this.tooltip=o.getElement(),a=o):(this.tooltip=this.eoxMap.querySelector("eox-map-tooltip")||((n=i.overlay)==null?void 0:n.element),this.tooltip&&(a=new bR({element:this.tooltip,position:void 0,offset:[0,0],positioning:"top-left",className:"eox-map-tooltip",id:"eox-map-tooltip",...i.overlay}),this.eoxMap.map.addOverlay(a)));const l=()=>{a&&i.condition==="pointermove"&&a.setPosition(void 0)};t.map.on("change:target",f=>{var p,m;(p=f.oldValue)==null||p.removeEventListener("pointerleave",l),(m=f.target.getTargetElement())==null||m.addEventListener("pointerleave",l)}),(r=t.map.getTargetElement())==null||r.addEventListener("pointerleave",l);let h;if(this.options.layer)h=this.options.layer;else{const f=this.selectLayer.get("_jsonDefinition");h={...f,style:i.style,properties:{id:this.selectLayer.get("id")+"_select"},source:{type:f.type}}}h.renderMode="vector",delete h.interactions,this.selectStyleLayer=sc(t,h),this.selectStyleLayer.setSource(this.selectLayer.getSource()),this.selectStyleLayer.setMap(this.eoxMap.map);const c=this.selectStyleLayer.getStyleFunction();this.selectStyleLayer.setStyle((f,p)=>this.selectedFids.length&&this.selectedFids.includes(this.getId(f))?c(f,p):null);const u=f=>{this.panIn&&this.eoxMap.map.getView().fit(f.getGeometry().getExtent(),{duration:750})},d=f=>{if(!this.active)return;const p=this.eoxMap.map.getView().getZoom();f.dragging||!this.active||pthis.selectLayer.getMaxZoom()||this.selectLayer.getFeatures(f.pixel).then(m=>{const _=m.length?m[0]:null,y=_?[this.getId(_)]:[],v=this.selectedFids[0]!==y[0];if(this.selectedFids=y,v&&(this.selectStyleLayer.changed(),_&&u(_)),a){const w=f.pixel[0]>this.eoxMap.offsetWidth/2?"right":"left",T=f.pixel[1]>this.eoxMap.offsetHeight/2?"bottom":"top";a.setPositioning(`${T}-${w}`),a.setPosition(_?f.coordinate:null),_&&this.tooltip.renderContent&&this.tooltip.renderContent(_)}const S=new CustomEvent("select",{detail:{id:i.id,originalEvent:f,feature:_}});this.eoxMap.dispatchEvent(S)})};this.eoxMap.map.on(i.condition||"click",d),this.selectLayer.on("change:opacity",()=>{this.selectStyleLayer.setOpacity(this.selectLayer.getOpacity())}),this.selectLayer.on("change:visible",()=>{const f=this.selectLayer.getVisible();this.selectStyleLayer.setVisible(f),this.setActive(f)}),this.changeSourceListener=()=>{this.selectStyleLayer.setSource(this.selectLayer.getSource())},this.selectLayer.on("change:source",this.changeSourceListener);const g=()=>{var f,p,m,_;t.getLayerById(e.get("id"))?((f=t.selectInteractions[i.id])==null||f.setActive(!0),(p=this.selectStyleLayer)==null||p.setMap(this.eoxMap.map),a?.setMap(this.eoxMap.map)):((m=t.selectInteractions[i.id])==null||m.setActive(!1),(_=this.selectStyleLayer)==null||_.setMap(null),a?.setMap(null))};t.map.getLayerGroup().on("change",g)}setActive(t){this.active=t}highlightById(t){this.selectedFids=t,this.selectStyleLayer.changed()}remove(){this.selectStyleLayer.setMap(null),delete this.eoxMap.selectInteractions[this.options.id],this.selectLayer.un("change:source",this.changeSourceListener)}getId(t){if(this.options.idProperty)return t.get(this.options.idProperty);if(t.getId()!==void 0)return t.getId();if(t.get("id")!==void 0)return t.get("id");throw Error("No feature id found. Please provide which feature property should be taken instead using idProperty.")}};function dU(s,t,e){if(s.interactions[e.id])throw Error(`Interaction with id: ${e.id} already exists.`);return s.selectInteractions[e.id]=new uU(s,t,e),s.selectInteractions[e.id]}function gU(s){var t;let e;if((t=s.source)!=null&&t.tileGrid){if(s.source.tileGrid)if(s.source.type==="WMTS"){const i=Bt("EPSG:3857").getExtent(),n=Ht(i)/128,r=new Array(19),o=new Array(19);for(let a=0;a<19;++a)r[a]=n/Math.pow(2,a),o[a]=a;e=new RG({resolutions:r,origin:Vn(i),projection:s.source.tileGrid.projection||"EPSG:3857",matrixIds:o,...s.source.tileGrid})}else e=Px({...s.source.tileGrid});return e}}const fU={GeoJSON:Em,MVT:p$},pU={Group:el,Image:wG,Tile:MG,Vector:og,VectorTile:CG},mU={ImageWMS:qG,OSM:t4,Tile:_R,TileWMS:e4,Vector:Rm,VectorTile:KG,WMTS:s4,XYZ:wR};function sc(s,t,e=!0){var i,n;t=JSON.parse(JSON.stringify(t));const r={...window.eoxMapAdvancedOlFormats,...fU},o={...window.eoxMapAdvancedOlLayers,...pU},a={...window.eoxMapAdvancedOlSources,...mU},l=o[t.type],h=a[(i=t.source)==null?void 0:i.type];if(!l)throw window.eoxMapAdvancedOlLayers?new Error(`Layer type ${t.type} not supported!`):new Error(`Layer type ${t.type} not created! Forgot to import advanced layers & sources plugin from @eox/map/dist/eox-map-advanced-layers-and-sources.js?`);if(t.source&&!h)throw window.eoxMapAdvancedOlSources?new Error(`Source type ${t.source.type} not supported!`):new Error(`Source type ${t.source.type} not created! Forgot to import advanced layers & sources plugin from @eox/map/dist/eox-map-advanced-layers-and-sources.js?`);const c=gU(t),u=new l({...t,...t.source&&{source:new h({...t.source,...t.source.format&&t.source.type!=="WMTS"&&{format:new r[typeof t.source.format=="object"?t.source.format.type:t.source.format]({...typeof t.source.format=="object"&&{...t.source.format}})},...t.source.tileGrid&&{tileGrid:c},...t.source.projection&&{projection:Bt(t.source.projection)}})},...t.type==="Group"&&{layers:[]},...t.properties,style:void 0});if(u.set("_jsonDefinition",t,!0),t.type==="Group"){const d=t.layers.reverse().map(g=>sc(s,g));d.forEach(g=>g.set("_group",u,!0)),u.setLayers(new ni(d))}if(t.style&&u.setStyle(t.style),e&&(n=t.interactions)!=null&&n.length)for(let d=0,g=t.interactions.length;d{const c=t.interactions.find(u=>u.type===h.type);c?c.type==="draw"?(s.interactions[c.options.id].setActive(c.options.active),s.interactions[`${c.options.id}_modify`].setActive(c.options.modify)):s.selectInteractions[c.options.id].setActive(c.options.active):s.removeInteraction(h.options.id)}),(o=t.interactions)==null||o.forEach(h=>{a.interactions.find(c=>c.type===h.type)||eI(s,e,h)})),t.type==="Group"){const h=t.layers.map(u=>{var d;return(d=u.properties)==null?void 0:d.id}),c=e.getLayers();c.getArray().slice().forEach(u=>{h.includes(u.get("id"))||c.remove(u)}),t.layers.forEach(u=>{const d=u.properties.id;if(c.getArray().map(g=>g.get("id")).includes(d))sI(s,u,s.getLayerById(d));else{const g=sc(s,u);c.push(g)}}),c.getArray().sort((u,d)=>h.indexOf(u.get("id"))-h.indexOf(d.get("id"))),c.changed()}return iI(e,t),e.set("_jsonDefinition",t,!0),e}const _U=(s,t)=>t?[...t].reverse().map(e=>sc(s,e)):[];function iI(s,t){s.on("change:opacity",()=>{t.opacity=s.getOpacity()}),s.on("change:visible",()=>{t.visible=s.getVisible()}),s.on("change:zIndex",()=>{t.zIndex=s.getZIndex()}),s.on("propertychange",e=>{e.key!=="map"&&(t.properties[e.key]=e.target.get(e.key))})}function d_(s,t){return nI(s.map.getLayers().getArray()).find(e=>e.get("id")===t)}function nI(s){const t=[];t.push(...s);let e=t.filter(i=>i instanceof el);for(;e.length;){const i=[];for(let n=0,r=e.length;na instanceof el))}e=i}return t}function XS(s){if(s){const t=s;return!en(t,[0,0])&&t[0]>=-180&&t[0]<=180&&t[1]>=-90&&t[1]<=90?f3(t):t}return[0,0]}const VS=["fullscreenchange","webkitfullscreenchange","MSFullscreenChange"],YS={ENTERFULLSCREEN:"enterfullscreen",LEAVEFULLSCREEN:"leavefullscreen"};let yU=class extends Yn{constructor(t){t=t||{},super({element:document.createElement("div"),target:t.target}),this.on,this.once,this.un,this.keys_=t.keys!==void 0?t.keys:!1,this.source_=t.source,this.isInFullscreen_=!1,this.boundHandleMapTargetChange_=this.handleMapTargetChange_.bind(this),this.cssClassName_=t.className!==void 0?t.className:"ol-full-screen",this.documentListeners_=[],this.activeClassName_=t.activeClassName!==void 0?t.activeClassName.split(" "):[this.cssClassName_+"-true"],this.inactiveClassName_=t.inactiveClassName!==void 0?t.inactiveClassName.split(" "):[this.cssClassName_+"-false"];const e=t.label!==void 0?t.label:"⤢";this.labelNode_=typeof e=="string"?document.createTextNode(e):e;const i=t.labelActive!==void 0?t.labelActive:"×";this.labelActiveNode_=typeof i=="string"?document.createTextNode(i):i;const n=t.tipLabel?t.tipLabel:"Toggle full-screen";this.button_=document.createElement("button"),this.button_.title=n,this.button_.setAttribute("type","button"),this.button_.appendChild(this.labelNode_),this.button_.addEventListener(_t.CLICK,this.handleClick_.bind(this),!1),this.setClassName_(this.button_,this.isInFullscreen_),this.element.className=`${this.cssClassName_} ${yr} ${pl}`,this.element.appendChild(this.button_)}handleClick_(t){t.preventDefault(),this.handleFullScreen_()}handleFullScreen_(){const t=this.getMap();if(!t)return;const e=t.getOwnerDocument();if(qS(e))if(ZS(e))vU(e);else{let i;this.source_?i=typeof this.source_=="string"?e.getElementById(this.source_):this.source_:i=t.getTargetElement(),this.keys_?xU(i):rI(i)}}handleFullScreenChange_(){const t=this.getMap();if(!t)return;const e=this.isInFullscreen_;this.isInFullscreen_=ZS(t.getOwnerDocument()),e!==this.isInFullscreen_&&(this.setClassName_(this.button_,this.isInFullscreen_),this.isInFullscreen_?(Hh(this.labelActiveNode_,this.labelNode_),this.dispatchEvent(YS.ENTERFULLSCREEN)):(Hh(this.labelNode_,this.labelActiveNode_),this.dispatchEvent(YS.LEAVEFULLSCREEN)),t.updateSize())}setClassName_(t,e){e?(t.classList.remove(...this.inactiveClassName_),t.classList.add(...this.activeClassName_)):(t.classList.remove(...this.activeClassName_),t.classList.add(...this.inactiveClassName_))}setMap(t){const e=this.getMap();e&&e.removeChangeListener(Qe.TARGET,this.boundHandleMapTargetChange_),super.setMap(t),this.handleMapTargetChange_(),t&&t.addChangeListener(Qe.TARGET,this.boundHandleMapTargetChange_)}handleMapTargetChange_(){const t=this.documentListeners_;for(let i=0,n=t.length;iu*f_||c>d*f_?this.resetExtent_():ln(o,n)||this.recenter_()}resetExtent_(){const t=this.getMap(),e=this.ovmap_,i=t.getSize(),n=t.getView().calculateExtentInternal(i),r=e.getView(),o=Math.log(f_/uf)/Math.LN2,a=1/(Math.pow(2,o/2)*uf);r3(n,a),r.fitInternal(Qf(n))}recenter_(){const t=this.getMap(),e=this.ovmap_,i=t.getView();e.getView().setCenterInternal(i.getCenterInternal())}updateBox_(){const t=this.getMap(),e=this.ovmap_;if(!t.isRendered()||!e.isRendered())return;const i=t.getSize(),n=t.getView(),r=e.getView(),o=this.rotateWithView_?0:-n.getRotation(),a=this.boxOverlay_,l=this.boxOverlay_.getElement(),h=n.getCenter(),c=n.getResolution(),u=r.getResolution(),d=i[0]*c/u,g=i[1]*c/u;if(a.setPosition(h),l){l.style.width=d+"px",l.style.height=g+"px";const f="rotate("+o+"rad)";l.style.transform=f}}updateBoxAfterOvmapIsRendered_(){this.ovmapPostrenderKey_||(this.ovmapPostrenderKey_=od(this.ovmap_,sr.POSTRENDER,t=>{delete this.ovmapPostrenderKey_,this.updateBox_()}))}handleClick_(t){t.preventDefault(),this.handleToggle_()}handleToggle_(){this.element.classList.toggle(ep),this.collapsed_?Hh(this.collapseLabel_,this.label_):Hh(this.label_,this.collapseLabel_),this.collapsed_=!this.collapsed_;const t=this.ovmap_;if(!this.collapsed_){if(t.isRendered()){this.viewExtent_=void 0,t.render();return}t.updateSize(),this.resetExtent_(),this.updateBoxAfterOvmapIsRendered_()}}getCollapsible(){return this.collapsible_}setCollapsible(t){this.collapsible_!==t&&(this.collapsible_=t,this.element.classList.toggle("ol-uncollapsible"),!t&&this.collapsed_&&this.handleToggle_())}setCollapsed(t){!this.collapsible_||this.collapsed_===t||this.handleToggle_()}getCollapsed(){return this.collapsed_}getRotateWithView(){return this.rotateWithView_}setRotateWithView(t){this.rotateWithView_!==t&&(this.rotateWithView_=t,this.getMap().getView().getRotation()!==0&&(this.rotateWithView_?this.handleRotationChanged_():this.ovmap_.getView().setRotation(0),this.viewExtent_=void 0,this.validateExtent_(),this.updateBox_()))}getOverviewMap(){return this.ovmap_}render(t){this.validateExtent_(),this.updateBox_()}};const bU=MU,p_="units",TU=[1,2,5],Qc=25.4/.28;let CU=class extends Yn{constructor(t){t=t||{};const e=document.createElement("div");e.style.pointerEvents="none",super({element:e,render:t.render,target:t.target}),this.on,this.once,this.un;const i=t.className!==void 0?t.className:t.bar?"ol-scale-bar":"ol-scale-line";this.innerElement_=document.createElement("div"),this.innerElement_.className=i+"-inner",this.element.className=i+" "+yr,this.element.appendChild(this.innerElement_),this.viewState_=null,this.minWidth_=t.minWidth!==void 0?t.minWidth:64,this.maxWidth_=t.maxWidth,this.renderedVisible_=!1,this.renderedWidth_=void 0,this.renderedHTML_="",this.addChangeListener(p_,this.handleUnitsChanged_),this.setUnits(t.units||"metric"),this.scaleBar_=t.bar||!1,this.scaleBarSteps_=t.steps||4,this.scaleBarText_=t.text||!1,this.dpi_=t.dpi||void 0}getUnits(){return this.get(p_)}handleUnitsChanged_(){this.updateElement_()}setUnits(t){this.set(p_,t)}setDpi(t){this.dpi_=t}updateElement_(){const t=this.viewState_;if(!t){this.renderedVisible_&&(this.element.style.display="none",this.renderedVisible_=!1);return}const e=t.center,i=t.projection,n=this.getUnits(),r=n=="degrees"?"degrees":"m";let o=Yh(i,t.resolution,e,r);const a=this.minWidth_*(this.dpi_||Qc)/Qc,l=this.maxWidth_!==void 0?this.maxWidth_*(this.dpi_||Qc)/Qc:void 0;let h=a*o,c="";if(n=="degrees"){const v=Bh.degrees;h*=v,h=l){d=p,g=m,f=_;break}else if(g>=a)break;p=d,m=g,_=f,++u}const y=this.scaleBar_?this.createScaleBar(g,d,c):d.toFixed(f<0?-f:0)+" "+c;this.renderedHTML_!=y&&(this.innerElement_.innerHTML=y,this.renderedHTML_=y),this.renderedWidth_!=g&&(this.innerElement_.style.width=g+"px",this.renderedWidth_=g),this.renderedVisible_||(this.element.style.display="",this.renderedVisible_=!0)}createScaleBar(t,e,i){const n=this.getScaleForResolution(),r=n<1?Math.round(1/n).toLocaleString()+" : 1":"1 : "+Math.round(n).toLocaleString(),o=this.scaleBarSteps_,a=t/o,l=[this.createMarker("absolute")];for(let h=0;h
`+this.createMarker("relative")+(h%2===0||o===2?this.createStepText(h,t,!1,e,i):"")+"")}return l.push(this.createStepText(o,t,!0,e,i)),(this.scaleBarText_?`
`+r+"
":"")+l.join("")}createMarker(t){return`
`}createStepText(t,e,i,n,r){const o=(t===0?0:Math.round(n/this.scaleBarSteps_*t*100)/100)+(t===0?"":" "+r),a=t===0?-3:e/this.scaleBarSteps_*-1,l=t===0?0:e/this.scaleBarSteps_*2;return`
`+o+"
"}getScaleForResolution(){const t=Yh(this.viewState_.projection,this.viewState_.resolution,this.viewState_.center,"m"),e=this.dpi_||Qc,i=1e3/25.4;return t*i*e}render(t){const e=t.frameState;e?this.viewState_=e.viewState:this.viewState_=null,this.updateElement_()}};const RU=CU,tu={VERTICAL:0,HORIZONTAL:1};let IU=class extends Yn{constructor(t){t=t||{},super({target:t.target,element:document.createElement("div"),render:t.render}),this.dragListenerKeys_=[],this.currentResolution_=void 0,this.direction_=tu.VERTICAL,this.dragging_,this.heightLimit_=0,this.widthLimit_=0,this.startX_,this.startY_,this.thumbSize_=null,this.sliderInitialized_=!1,this.duration_=t.duration!==void 0?t.duration:200;const e=t.className!==void 0?t.className:"ol-zoomslider",i=document.createElement("button");i.setAttribute("type","button"),i.className=e+"-thumb "+yr;const n=this.element;n.className=e+" "+yr+" "+pl,n.appendChild(i),n.addEventListener(ir.POINTERDOWN,this.handleDraggerStart_.bind(this),!1),n.addEventListener(ir.POINTERMOVE,this.handleDraggerDrag_.bind(this),!1),n.addEventListener(ir.POINTERUP,this.handleDraggerEnd_.bind(this),!1),n.addEventListener(_t.CLICK,this.handleContainerClick_.bind(this),!1),i.addEventListener(_t.CLICK,GF,!1)}setMap(t){super.setMap(t),t&&t.render()}initSlider_(){const t=this.element;let e=t.offsetWidth,i=t.offsetHeight;if(e===0&&i===0)return this.sliderInitialized_=!1;const n=getComputedStyle(t);e-=parseFloat(n.paddingRight)+parseFloat(n.paddingLeft),i-=parseFloat(n.paddingTop)+parseFloat(n.paddingBottom);const r=t.firstElementChild,o=getComputedStyle(r),a=r.offsetWidth+parseFloat(o.marginRight)+parseFloat(o.marginLeft),l=r.offsetHeight+parseFloat(o.marginTop)+parseFloat(o.marginBottom);return this.thumbSize_=[a,l],e>i?(this.direction_=tu.HORIZONTAL,this.widthLimit_=e-a):(this.direction_=tu.VERTICAL,this.heightLimit_=i-l),this.sliderInitialized_=!0}handleContainerClick_(t){const e=this.getMap().getView(),i=this.getRelativePosition_(t.offsetX-this.thumbSize_[0]/2,t.offsetY-this.thumbSize_[1]/2),n=this.getResolutionForPosition_(i),r=e.getConstrainedZoom(e.getZoomForResolution(n));e.animateInternal({zoom:r,duration:this.duration_,easing:gl})}handleDraggerStart_(t){if(!this.dragging_&&t.target===this.element.firstElementChild){const e=this.element.firstElementChild;if(this.getMap().getView().beginInteraction(),this.startX_=t.clientX-parseFloat(e.style.left),this.startY_=t.clientY-parseFloat(e.style.top),this.dragging_=!0,this.dragListenerKeys_.length===0){const i=this.handleDraggerDrag_,n=this.handleDraggerEnd_,r=this.getMap().getOwnerDocument();this.dragListenerKeys_.push(zt(r,ir.POINTERMOVE,i,this),zt(r,ir.POINTERUP,n,this))}}}handleDraggerDrag_(t){if(this.dragging_){const e=t.clientX-this.startX_,i=t.clientY-this.startY_,n=this.getRelativePosition_(e,i);this.currentResolution_=this.getResolutionForPosition_(n),this.getMap().getView().setResolution(this.currentResolution_)}}handleDraggerEnd_(t){this.dragging_&&(this.getMap().getView().endInteraction(),this.dragging_=!1,this.startX_=void 0,this.startY_=void 0,this.dragListenerKeys_.forEach(fe),this.dragListenerKeys_.length=0)}setThumbPosition_(t){const e=this.getPositionForResolution_(t),i=this.element.firstElementChild;this.direction_==tu.HORIZONTAL?i.style.left=this.widthLimit_*e+"px":i.style.top=this.heightLimit_*e+"px"}getRelativePosition_(t,e){let i;return this.direction_===tu.HORIZONTAL?i=t/this.widthLimit_:i=e/this.heightLimit_,Ce(i,0,1)}getResolutionForPosition_(t){return this.getMap().getView().getResolutionForValueFunction()(1-t)}getPositionForResolution_(t){const e=this.getMap().getView().getValueForResolutionFunction();return Ce(1-e(t),0,1)}render(t){if(!t.frameState||!this.sliderInitialized_&&!this.initSlider_())return;const e=t.frameState.viewState.resolution;this.currentResolution_=e,this.setThumbPosition_(e)}};const PU=IU;let AU=class extends Yn{constructor(t){t=t||{},super({element:document.createElement("div"),target:t.target}),this.extent=t.extent?t.extent:null;const e=t.className!==void 0?t.className:"ol-zoom-extent",i=t.label!==void 0?t.label:"E",n=t.tipLabel!==void 0?t.tipLabel:"Fit to extent",r=document.createElement("button");r.setAttribute("type","button"),r.title=n,r.appendChild(typeof i=="string"?document.createTextNode(i):i),r.addEventListener(_t.CLICK,this.handleClick_.bind(this),!1);const o=e+" "+yr+" "+pl,a=this.element;a.className=o,a.appendChild(r)}handleClick_(t){t.preventDefault(),this.handleZoomToExtent()}handleZoomToExtent(){const t=this.getMap().getView(),e=this.extent?hn(this.extent,t.getProjection()):t.getProjection().getExtent();t.fitInternal(Qf(e))}};const LU=AU,OU=Object.freeze(Object.defineProperty({__proto__:null,Attribution:uC,Control:Yn,FullScreen:wU,MousePosition:SU,OverviewMap:bU,Rotate:dC,ScaleLine:RU,Zoom:gC,ZoomSlider:PU,ZoomToExtent:LU,defaults:fC},Symbol.toStringTag,{value:"Module"}));let FU=class extends Yn{constructor(t){const e=t||{},i=document.createElement("div");i.className="geolocation ol-unselectable ol-control";const n=document.createElement("button");n.title="Show your location";const r=document.createElement("img");if(e.buttonIcon)r.src=e.buttonIcon;else{const o=`url( + `,this.shadowRoot)}};cU([Er()],tI.prototype,"propertyTransform");customElements.define("eox-map-tooltip",tI);let uU=class{constructor(t,e,i){var n,r;this.eoxMap=t,this.selectLayer=e,this.options=i,this.active=i.active||e.getVisible(),this.panIn=i.panIn||!1;const o=this.eoxMap.map.getOverlayById("eox-map-tooltip");let a;this.selectedFids=[],o?(this.tooltip=o.getElement(),a=o):(this.tooltip=this.eoxMap.querySelector("eox-map-tooltip")||((n=i.overlay)==null?void 0:n.element),this.tooltip&&(a=new bR({element:this.tooltip,position:void 0,offset:[0,0],positioning:"top-left",className:"eox-map-tooltip",id:"eox-map-tooltip",...i.overlay}),this.eoxMap.map.addOverlay(a)));const l=()=>{a&&i.condition==="pointermove"&&a.setPosition(void 0)};t.map.on("change:target",f=>{var p,m;(p=f.oldValue)==null||p.removeEventListener("pointerleave",l),(m=f.target.getTargetElement())==null||m.addEventListener("pointerleave",l)}),(r=t.map.getTargetElement())==null||r.addEventListener("pointerleave",l);let h;if(this.options.layer)h=this.options.layer;else{const f=this.selectLayer.get("_jsonDefinition");h={...f,style:i.style,properties:{id:this.selectLayer.get("id")+"_select"},source:{type:f.type}}}h.renderMode="vector",delete h.interactions,this.selectStyleLayer=sc(t,h),this.selectStyleLayer.setSource(this.selectLayer.getSource()),this.selectStyleLayer.setMap(this.eoxMap.map);const c=this.selectStyleLayer.getStyleFunction();this.selectStyleLayer.setStyle((f,p)=>this.selectedFids.length&&this.selectedFids.includes(this.getId(f))?c(f,p):null);const u=f=>{this.panIn&&this.eoxMap.map.getView().fit(f.getGeometry().getExtent(),{duration:750})},d=f=>{if(!this.active)return;const p=this.eoxMap.map.getView().getZoom();f.dragging||!this.active||pthis.selectLayer.getMaxZoom()||this.selectLayer.getFeatures(f.pixel).then(m=>{const _=m.length?m[0]:null,y=_?[this.getId(_)]:[],v=this.selectedFids[0]!==y[0];if(this.selectedFids=y,v&&(this.selectStyleLayer.changed(),_&&u(_)),a){const w=f.pixel[0]>this.eoxMap.offsetWidth/2?"right":"left",C=f.pixel[1]>this.eoxMap.offsetHeight/2?"bottom":"top";a.setPositioning(`${C}-${w}`),a.setPosition(_?f.coordinate:null),_&&this.tooltip.renderContent&&this.tooltip.renderContent(_)}const S=new CustomEvent("select",{detail:{id:i.id,originalEvent:f,feature:_}});this.eoxMap.dispatchEvent(S)})};this.eoxMap.map.on(i.condition||"click",d),this.selectLayer.on("change:opacity",()=>{this.selectStyleLayer.setOpacity(this.selectLayer.getOpacity())}),this.selectLayer.on("change:visible",()=>{const f=this.selectLayer.getVisible();this.selectStyleLayer.setVisible(f),this.setActive(f)}),this.changeSourceListener=()=>{this.selectStyleLayer.setSource(this.selectLayer.getSource())},this.selectLayer.on("change:source",this.changeSourceListener);const g=()=>{var f,p,m,_;t.getLayerById(e.get("id"))?((f=t.selectInteractions[i.id])==null||f.setActive(!0),(p=this.selectStyleLayer)==null||p.setMap(this.eoxMap.map),a?.setMap(this.eoxMap.map)):((m=t.selectInteractions[i.id])==null||m.setActive(!1),(_=this.selectStyleLayer)==null||_.setMap(null),a?.setMap(null))};t.map.getLayerGroup().on("change",g)}setActive(t){this.active=t}highlightById(t){this.selectedFids=t,this.selectStyleLayer.changed()}remove(){this.selectStyleLayer.setMap(null),delete this.eoxMap.selectInteractions[this.options.id],this.selectLayer.un("change:source",this.changeSourceListener)}getId(t){if(this.options.idProperty)return t.get(this.options.idProperty);if(t.getId()!==void 0)return t.getId();if(t.get("id")!==void 0)return t.get("id");throw Error("No feature id found. Please provide which feature property should be taken instead using idProperty.")}};function dU(s,t,e){if(s.interactions[e.id])throw Error(`Interaction with id: ${e.id} already exists.`);return s.selectInteractions[e.id]=new uU(s,t,e),s.selectInteractions[e.id]}function gU(s){var t;let e;if((t=s.source)!=null&&t.tileGrid){if(s.source.tileGrid)if(s.source.type==="WMTS"){const i=Bt("EPSG:3857").getExtent(),n=Ht(i)/128,r=new Array(19),o=new Array(19);for(let a=0;a<19;++a)r[a]=n/Math.pow(2,a),o[a]=a;e=new RG({resolutions:r,origin:Vn(i),projection:s.source.tileGrid.projection||"EPSG:3857",matrixIds:o,...s.source.tileGrid})}else e=Px({...s.source.tileGrid});return e}}const fU={GeoJSON:Em,MVT:p$},pU={Group:el,Image:wG,Tile:MG,Vector:og,VectorTile:TG},mU={ImageWMS:qG,OSM:t4,Tile:_R,TileWMS:e4,Vector:Rm,VectorTile:KG,WMTS:s4,XYZ:wR};function sc(s,t,e=!0){var i,n;t=JSON.parse(JSON.stringify(t));const r={...window.eoxMapAdvancedOlFormats,...fU},o={...window.eoxMapAdvancedOlLayers,...pU},a={...window.eoxMapAdvancedOlSources,...mU},l=o[t.type],h=a[(i=t.source)==null?void 0:i.type];if(!l)throw window.eoxMapAdvancedOlLayers?new Error(`Layer type ${t.type} not supported!`):new Error(`Layer type ${t.type} not created! Forgot to import advanced layers & sources plugin from @eox/map/dist/eox-map-advanced-layers-and-sources.js?`);if(t.source&&!h)throw window.eoxMapAdvancedOlSources?new Error(`Source type ${t.source.type} not supported!`):new Error(`Source type ${t.source.type} not created! Forgot to import advanced layers & sources plugin from @eox/map/dist/eox-map-advanced-layers-and-sources.js?`);const c=gU(t),u=new l({...t,...t.source&&{source:new h({...t.source,...t.source.format&&t.source.type!=="WMTS"&&{format:new r[typeof t.source.format=="object"?t.source.format.type:t.source.format]({...typeof t.source.format=="object"&&{...t.source.format}})},...t.source.tileGrid&&{tileGrid:c},...t.source.projection&&{projection:Bt(t.source.projection)}})},...t.type==="Group"&&{layers:[]},...t.properties,style:void 0});if(u.set("_jsonDefinition",t,!0),t.type==="Group"){const d=t.layers.reverse().map(g=>sc(s,g));d.forEach(g=>g.set("_group",u,!0)),u.setLayers(new ni(d))}if(t.style&&u.setStyle(t.style),e&&(n=t.interactions)!=null&&n.length)for(let d=0,g=t.interactions.length;d{const c=t.interactions.find(u=>u.type===h.type);c?c.type==="draw"?(s.interactions[c.options.id].setActive(c.options.active),s.interactions[`${c.options.id}_modify`].setActive(c.options.modify)):s.selectInteractions[c.options.id].setActive(c.options.active):s.removeInteraction(h.options.id)}),(o=t.interactions)==null||o.forEach(h=>{a.interactions.find(c=>c.type===h.type)||eI(s,e,h)})),t.type==="Group"){const h=t.layers.map(u=>{var d;return(d=u.properties)==null?void 0:d.id}),c=e.getLayers();c.getArray().slice().forEach(u=>{h.includes(u.get("id"))||c.remove(u)}),t.layers.forEach(u=>{const d=u.properties.id;if(c.getArray().map(g=>g.get("id")).includes(d))sI(s,u,s.getLayerById(d));else{const g=sc(s,u);c.push(g)}}),c.getArray().sort((u,d)=>h.indexOf(u.get("id"))-h.indexOf(d.get("id"))),c.changed()}return iI(e,t),e.set("_jsonDefinition",t,!0),e}const _U=(s,t)=>t?[...t].reverse().map(e=>sc(s,e)):[];function iI(s,t){s.on("change:opacity",()=>{t.opacity=s.getOpacity()}),s.on("change:visible",()=>{t.visible=s.getVisible()}),s.on("change:zIndex",()=>{t.zIndex=s.getZIndex()}),s.on("propertychange",e=>{e.key!=="map"&&(t.properties[e.key]=e.target.get(e.key))})}function d_(s,t){return nI(s.map.getLayers().getArray()).find(e=>e.get("id")===t)}function nI(s){const t=[];t.push(...s);let e=t.filter(i=>i instanceof el);for(;e.length;){const i=[];for(let n=0,r=e.length;na instanceof el))}e=i}return t}function XS(s){if(s){const t=s;return!en(t,[0,0])&&t[0]>=-180&&t[0]<=180&&t[1]>=-90&&t[1]<=90?f3(t):t}return[0,0]}const VS=["fullscreenchange","webkitfullscreenchange","MSFullscreenChange"],YS={ENTERFULLSCREEN:"enterfullscreen",LEAVEFULLSCREEN:"leavefullscreen"};let yU=class extends Yn{constructor(t){t=t||{},super({element:document.createElement("div"),target:t.target}),this.on,this.once,this.un,this.keys_=t.keys!==void 0?t.keys:!1,this.source_=t.source,this.isInFullscreen_=!1,this.boundHandleMapTargetChange_=this.handleMapTargetChange_.bind(this),this.cssClassName_=t.className!==void 0?t.className:"ol-full-screen",this.documentListeners_=[],this.activeClassName_=t.activeClassName!==void 0?t.activeClassName.split(" "):[this.cssClassName_+"-true"],this.inactiveClassName_=t.inactiveClassName!==void 0?t.inactiveClassName.split(" "):[this.cssClassName_+"-false"];const e=t.label!==void 0?t.label:"⤢";this.labelNode_=typeof e=="string"?document.createTextNode(e):e;const i=t.labelActive!==void 0?t.labelActive:"×";this.labelActiveNode_=typeof i=="string"?document.createTextNode(i):i;const n=t.tipLabel?t.tipLabel:"Toggle full-screen";this.button_=document.createElement("button"),this.button_.title=n,this.button_.setAttribute("type","button"),this.button_.appendChild(this.labelNode_),this.button_.addEventListener(_t.CLICK,this.handleClick_.bind(this),!1),this.setClassName_(this.button_,this.isInFullscreen_),this.element.className=`${this.cssClassName_} ${yr} ${pl}`,this.element.appendChild(this.button_)}handleClick_(t){t.preventDefault(),this.handleFullScreen_()}handleFullScreen_(){const t=this.getMap();if(!t)return;const e=t.getOwnerDocument();if(qS(e))if(ZS(e))vU(e);else{let i;this.source_?i=typeof this.source_=="string"?e.getElementById(this.source_):this.source_:i=t.getTargetElement(),this.keys_?xU(i):rI(i)}}handleFullScreenChange_(){const t=this.getMap();if(!t)return;const e=this.isInFullscreen_;this.isInFullscreen_=ZS(t.getOwnerDocument()),e!==this.isInFullscreen_&&(this.setClassName_(this.button_,this.isInFullscreen_),this.isInFullscreen_?(Hh(this.labelActiveNode_,this.labelNode_),this.dispatchEvent(YS.ENTERFULLSCREEN)):(Hh(this.labelNode_,this.labelActiveNode_),this.dispatchEvent(YS.LEAVEFULLSCREEN)),t.updateSize())}setClassName_(t,e){e?(t.classList.remove(...this.inactiveClassName_),t.classList.add(...this.activeClassName_)):(t.classList.remove(...this.activeClassName_),t.classList.add(...this.inactiveClassName_))}setMap(t){const e=this.getMap();e&&e.removeChangeListener(Qe.TARGET,this.boundHandleMapTargetChange_),super.setMap(t),this.handleMapTargetChange_(),t&&t.addChangeListener(Qe.TARGET,this.boundHandleMapTargetChange_)}handleMapTargetChange_(){const t=this.documentListeners_;for(let i=0,n=t.length;iu*f_||c>d*f_?this.resetExtent_():ln(o,n)||this.recenter_()}resetExtent_(){const t=this.getMap(),e=this.ovmap_,i=t.getSize(),n=t.getView().calculateExtentInternal(i),r=e.getView(),o=Math.log(f_/uf)/Math.LN2,a=1/(Math.pow(2,o/2)*uf);r3(n,a),r.fitInternal(Qf(n))}recenter_(){const t=this.getMap(),e=this.ovmap_,i=t.getView();e.getView().setCenterInternal(i.getCenterInternal())}updateBox_(){const t=this.getMap(),e=this.ovmap_;if(!t.isRendered()||!e.isRendered())return;const i=t.getSize(),n=t.getView(),r=e.getView(),o=this.rotateWithView_?0:-n.getRotation(),a=this.boxOverlay_,l=this.boxOverlay_.getElement(),h=n.getCenter(),c=n.getResolution(),u=r.getResolution(),d=i[0]*c/u,g=i[1]*c/u;if(a.setPosition(h),l){l.style.width=d+"px",l.style.height=g+"px";const f="rotate("+o+"rad)";l.style.transform=f}}updateBoxAfterOvmapIsRendered_(){this.ovmapPostrenderKey_||(this.ovmapPostrenderKey_=od(this.ovmap_,sr.POSTRENDER,t=>{delete this.ovmapPostrenderKey_,this.updateBox_()}))}handleClick_(t){t.preventDefault(),this.handleToggle_()}handleToggle_(){this.element.classList.toggle(ep),this.collapsed_?Hh(this.collapseLabel_,this.label_):Hh(this.label_,this.collapseLabel_),this.collapsed_=!this.collapsed_;const t=this.ovmap_;if(!this.collapsed_){if(t.isRendered()){this.viewExtent_=void 0,t.render();return}t.updateSize(),this.resetExtent_(),this.updateBoxAfterOvmapIsRendered_()}}getCollapsible(){return this.collapsible_}setCollapsible(t){this.collapsible_!==t&&(this.collapsible_=t,this.element.classList.toggle("ol-uncollapsible"),!t&&this.collapsed_&&this.handleToggle_())}setCollapsed(t){!this.collapsible_||this.collapsed_===t||this.handleToggle_()}getCollapsed(){return this.collapsed_}getRotateWithView(){return this.rotateWithView_}setRotateWithView(t){this.rotateWithView_!==t&&(this.rotateWithView_=t,this.getMap().getView().getRotation()!==0&&(this.rotateWithView_?this.handleRotationChanged_():this.ovmap_.getView().setRotation(0),this.viewExtent_=void 0,this.validateExtent_(),this.updateBox_()))}getOverviewMap(){return this.ovmap_}render(t){this.validateExtent_(),this.updateBox_()}};const bU=MU,p_="units",CU=[1,2,5],Qc=25.4/.28;let TU=class extends Yn{constructor(t){t=t||{};const e=document.createElement("div");e.style.pointerEvents="none",super({element:e,render:t.render,target:t.target}),this.on,this.once,this.un;const i=t.className!==void 0?t.className:t.bar?"ol-scale-bar":"ol-scale-line";this.innerElement_=document.createElement("div"),this.innerElement_.className=i+"-inner",this.element.className=i+" "+yr,this.element.appendChild(this.innerElement_),this.viewState_=null,this.minWidth_=t.minWidth!==void 0?t.minWidth:64,this.maxWidth_=t.maxWidth,this.renderedVisible_=!1,this.renderedWidth_=void 0,this.renderedHTML_="",this.addChangeListener(p_,this.handleUnitsChanged_),this.setUnits(t.units||"metric"),this.scaleBar_=t.bar||!1,this.scaleBarSteps_=t.steps||4,this.scaleBarText_=t.text||!1,this.dpi_=t.dpi||void 0}getUnits(){return this.get(p_)}handleUnitsChanged_(){this.updateElement_()}setUnits(t){this.set(p_,t)}setDpi(t){this.dpi_=t}updateElement_(){const t=this.viewState_;if(!t){this.renderedVisible_&&(this.element.style.display="none",this.renderedVisible_=!1);return}const e=t.center,i=t.projection,n=this.getUnits(),r=n=="degrees"?"degrees":"m";let o=Yh(i,t.resolution,e,r);const a=this.minWidth_*(this.dpi_||Qc)/Qc,l=this.maxWidth_!==void 0?this.maxWidth_*(this.dpi_||Qc)/Qc:void 0;let h=a*o,c="";if(n=="degrees"){const v=Bh.degrees;h*=v,h=l){d=p,g=m,f=_;break}else if(g>=a)break;p=d,m=g,_=f,++u}const y=this.scaleBar_?this.createScaleBar(g,d,c):d.toFixed(f<0?-f:0)+" "+c;this.renderedHTML_!=y&&(this.innerElement_.innerHTML=y,this.renderedHTML_=y),this.renderedWidth_!=g&&(this.innerElement_.style.width=g+"px",this.renderedWidth_=g),this.renderedVisible_||(this.element.style.display="",this.renderedVisible_=!0)}createScaleBar(t,e,i){const n=this.getScaleForResolution(),r=n<1?Math.round(1/n).toLocaleString()+" : 1":"1 : "+Math.round(n).toLocaleString(),o=this.scaleBarSteps_,a=t/o,l=[this.createMarker("absolute")];for(let h=0;h
`+this.createMarker("relative")+(h%2===0||o===2?this.createStepText(h,t,!1,e,i):"")+"")}return l.push(this.createStepText(o,t,!0,e,i)),(this.scaleBarText_?`
`+r+"
":"")+l.join("")}createMarker(t){return`
`}createStepText(t,e,i,n,r){const o=(t===0?0:Math.round(n/this.scaleBarSteps_*t*100)/100)+(t===0?"":" "+r),a=t===0?-3:e/this.scaleBarSteps_*-1,l=t===0?0:e/this.scaleBarSteps_*2;return`
`+o+"
"}getScaleForResolution(){const t=Yh(this.viewState_.projection,this.viewState_.resolution,this.viewState_.center,"m"),e=this.dpi_||Qc,i=1e3/25.4;return t*i*e}render(t){const e=t.frameState;e?this.viewState_=e.viewState:this.viewState_=null,this.updateElement_()}};const RU=TU,tu={VERTICAL:0,HORIZONTAL:1};let IU=class extends Yn{constructor(t){t=t||{},super({target:t.target,element:document.createElement("div"),render:t.render}),this.dragListenerKeys_=[],this.currentResolution_=void 0,this.direction_=tu.VERTICAL,this.dragging_,this.heightLimit_=0,this.widthLimit_=0,this.startX_,this.startY_,this.thumbSize_=null,this.sliderInitialized_=!1,this.duration_=t.duration!==void 0?t.duration:200;const e=t.className!==void 0?t.className:"ol-zoomslider",i=document.createElement("button");i.setAttribute("type","button"),i.className=e+"-thumb "+yr;const n=this.element;n.className=e+" "+yr+" "+pl,n.appendChild(i),n.addEventListener(ir.POINTERDOWN,this.handleDraggerStart_.bind(this),!1),n.addEventListener(ir.POINTERMOVE,this.handleDraggerDrag_.bind(this),!1),n.addEventListener(ir.POINTERUP,this.handleDraggerEnd_.bind(this),!1),n.addEventListener(_t.CLICK,this.handleContainerClick_.bind(this),!1),i.addEventListener(_t.CLICK,GF,!1)}setMap(t){super.setMap(t),t&&t.render()}initSlider_(){const t=this.element;let e=t.offsetWidth,i=t.offsetHeight;if(e===0&&i===0)return this.sliderInitialized_=!1;const n=getComputedStyle(t);e-=parseFloat(n.paddingRight)+parseFloat(n.paddingLeft),i-=parseFloat(n.paddingTop)+parseFloat(n.paddingBottom);const r=t.firstElementChild,o=getComputedStyle(r),a=r.offsetWidth+parseFloat(o.marginRight)+parseFloat(o.marginLeft),l=r.offsetHeight+parseFloat(o.marginTop)+parseFloat(o.marginBottom);return this.thumbSize_=[a,l],e>i?(this.direction_=tu.HORIZONTAL,this.widthLimit_=e-a):(this.direction_=tu.VERTICAL,this.heightLimit_=i-l),this.sliderInitialized_=!0}handleContainerClick_(t){const e=this.getMap().getView(),i=this.getRelativePosition_(t.offsetX-this.thumbSize_[0]/2,t.offsetY-this.thumbSize_[1]/2),n=this.getResolutionForPosition_(i),r=e.getConstrainedZoom(e.getZoomForResolution(n));e.animateInternal({zoom:r,duration:this.duration_,easing:gl})}handleDraggerStart_(t){if(!this.dragging_&&t.target===this.element.firstElementChild){const e=this.element.firstElementChild;if(this.getMap().getView().beginInteraction(),this.startX_=t.clientX-parseFloat(e.style.left),this.startY_=t.clientY-parseFloat(e.style.top),this.dragging_=!0,this.dragListenerKeys_.length===0){const i=this.handleDraggerDrag_,n=this.handleDraggerEnd_,r=this.getMap().getOwnerDocument();this.dragListenerKeys_.push(zt(r,ir.POINTERMOVE,i,this),zt(r,ir.POINTERUP,n,this))}}}handleDraggerDrag_(t){if(this.dragging_){const e=t.clientX-this.startX_,i=t.clientY-this.startY_,n=this.getRelativePosition_(e,i);this.currentResolution_=this.getResolutionForPosition_(n),this.getMap().getView().setResolution(this.currentResolution_)}}handleDraggerEnd_(t){this.dragging_&&(this.getMap().getView().endInteraction(),this.dragging_=!1,this.startX_=void 0,this.startY_=void 0,this.dragListenerKeys_.forEach(fe),this.dragListenerKeys_.length=0)}setThumbPosition_(t){const e=this.getPositionForResolution_(t),i=this.element.firstElementChild;this.direction_==tu.HORIZONTAL?i.style.left=this.widthLimit_*e+"px":i.style.top=this.heightLimit_*e+"px"}getRelativePosition_(t,e){let i;return this.direction_===tu.HORIZONTAL?i=t/this.widthLimit_:i=e/this.heightLimit_,Te(i,0,1)}getResolutionForPosition_(t){return this.getMap().getView().getResolutionForValueFunction()(1-t)}getPositionForResolution_(t){const e=this.getMap().getView().getValueForResolutionFunction();return Te(1-e(t),0,1)}render(t){if(!t.frameState||!this.sliderInitialized_&&!this.initSlider_())return;const e=t.frameState.viewState.resolution;this.currentResolution_=e,this.setThumbPosition_(e)}};const PU=IU;let AU=class extends Yn{constructor(t){t=t||{},super({element:document.createElement("div"),target:t.target}),this.extent=t.extent?t.extent:null;const e=t.className!==void 0?t.className:"ol-zoom-extent",i=t.label!==void 0?t.label:"E",n=t.tipLabel!==void 0?t.tipLabel:"Fit to extent",r=document.createElement("button");r.setAttribute("type","button"),r.title=n,r.appendChild(typeof i=="string"?document.createTextNode(i):i),r.addEventListener(_t.CLICK,this.handleClick_.bind(this),!1);const o=e+" "+yr+" "+pl,a=this.element;a.className=o,a.appendChild(r)}handleClick_(t){t.preventDefault(),this.handleZoomToExtent()}handleZoomToExtent(){const t=this.getMap().getView(),e=this.extent?hn(this.extent,t.getProjection()):t.getProjection().getExtent();t.fitInternal(Qf(e))}};const LU=AU,OU=Object.freeze(Object.defineProperty({__proto__:null,Attribution:uT,Control:Yn,FullScreen:wU,MousePosition:SU,OverviewMap:bU,Rotate:dT,ScaleLine:RU,Zoom:gT,ZoomSlider:PU,ZoomToExtent:LU,defaults:fT},Symbol.toStringTag,{value:"Module"}));let FU=class extends Yn{constructor(t){const e=t||{},i=document.createElement("div");i.className="geolocation ol-unselectable ol-control";const n=document.createElement("button");n.title="Show your location";const r=document.createElement("img");if(e.buttonIcon)r.src=e.buttonIcon;else{const o=`url( "data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='-6 -6 36 36'%3E %3Cpath d='M12,8A4,4 0 0,1 16,12A4,4 0 0,1 12,16A4,4 0 0,1 8,12A4,4 0 0,1 12,8M3.05,13H1V11H3.05C3.5,6.83 6.83,3.5 11,3.05V1H13V3.05C17.17,3.5 20.5,6.83 20.95,11H23V13H20.95C20.5,17.17 17.17,20.5 13,20.95V23H11V20.95C6.83,20.5 3.5,17.17 3.05,13M12,5A7,7 0 0,0 5,12A7,7 0 0,0 12,19A7,7 0 0,0 19,12A7,7 0 0,0 12,5Z' /%3E%3C/svg%3E" )`;r.style.background="var(--ol-subtle-foreground-color)",r.style.maskImage=o,r.style.webkitMaskImage=o}r.style.height="100%",r.style.width="100%",r.style.position="absolute",r.style.pointerEvents="none",i.appendChild(r),i.appendChild(n),super({element:i}),this._centerWhenReady=e.centerWhenReady,this._highAccuracy=e.highAccuracy,this._trackAccuracy=e.trackAccuracy,this._trackHeading=e.trackHeading,this._positionFeature=new Bi({geometry:new qi([NaN,NaN]),heading:0}),this._source=new Rm({features:[this._positionFeature]}),this._trackAccuracy&&(this._accuracyFeature=new Bi,this._accuracyFeature.setStyle(new Vs({fill:new to({color:"rgba(0, 0, 0, 0.2)"}),stroke:new Vr({width:2,color:"rgba(0, 0, 0, 0.7)"})})),this._source.addFeature(this._accuracyFeature)),this._layer=new og({source:this._source}),e.style&&this._layer.setStyle(e.style),n.addEventListener("click",this.centerOnPosition.bind(this),!1)}setMap(t){this._layer.setMap(t),super.setMap(t),t&&this._centerWhenReady&&this.initGeolocation()}initGeolocation(){return new Promise((t,e)=>{const i=this.getMap();i&&(this._geolocation=new r4({tracking:!0,trackingOptions:{enableHighAccuracy:this._highAccuracy},projection:i.getView().getProjection()})),this._centerWhenReady&&this._geolocation.once("change:position",n=>{i.getView().setCenter(n.target.getPosition())}),this._geolocation.on("error",function(n){e(n)}),this._geolocation.on("change:accuracyGeometry",()=>{this._trackAccuracy&&this._accuracyFeature.setGeometry(this._geolocation.getAccuracyGeometry())}),this._geolocation.on("change:heading",n=>{this._trackHeading&&this._highAccuracy&&this._positionFeature.set("heading",n.target.getHeading())}),this._geolocation.on("change:position",()=>{const n=this._geolocation.getPosition();this._positionFeature.getGeometry().setCoordinates(n||null),t(n)}),this._geolocation.on("change:accuracyGeometry",()=>{this._trackAccuracy&&this._accuracyFeature&&this._accuracyFeature.setGeometry(this._geolocation.getAccuracyGeometry())})})}getElement(){return this.element}async centerOnPosition(){var t,e;try{await this.initGeolocation();const i=(t=this._geolocation)==null?void 0:t.getPosition();i&&((e=this.getMap())==null||e.getView().setCenter(i))}catch(i){console.error(i)}}};const NU={...OU,Geolocation:FU};function DU(s,t,e,i){t&&t[e]?JSON.stringify(t[e])!==JSON.stringify(i)&&(s.removeControl(e),KS(s,e,i)):KS(s,e,i)}function KS(s,t,e){const i=Object.assign({},e);e&&e.layers&&(i.layers=_U(s,e.layers));const n=new NU[t](i);s.map.addControl(n),s.mapControls[t]=n}/** * @license @@ -173,7 +173,7 @@ northing meters`+s;var d=u/2,g=0,f=0,p,m,_,y,v;return d>0&&(p=1e5/Math.pow(10,d) /> `)} - `}};oI([Er()],Gx.prototype,"value");oI([Er({type:String})],Gx.prototype,"enabled");customElements.define("eox-map-compare",Gx);function GU(s,t,e=.001){let i=!0;for(let n=s.length-1;n>=0;--n)if(!jU(s[n],t[n],e)){i=!1;break}return i}function jU(s,t,e=.001){return Math.abs(s-t)0?s.addInteraction(new Ou({condition:function(e){return this.getPointerCount()===2||ZE(e)}})):s.addInteraction(new Ou)):(s.addInteraction(new ap),s.addInteraction(new Ou))}function zU(s){s.getInteractions().getArray().forEach(t=>{(t instanceof ap||t instanceof Ou)&&s.removeInteraction(t)})}const UU=s=>{let t;return typeof s=="string"?t=document.querySelector(s):t=s,t};var BU=Object.defineProperty,WU=Object.getOwnPropertyDescriptor,qn=(s,t,e,i)=>{for(var n=i>1?void 0:i?WU(t,e):t,r=s.length-1,o;r>=0;r--)(o=s[r])&&(n=(i?o(t,e,n):o(n))||n);return i&&n&&BU(t,e,n),n};let yn=class extends Mh{constructor(){super(...arguments),this._center=[0,0],this._zoom=0,this._animationOptions={},this.map=new EC({controls:[],layers:[],view:new nn({center:[0,0],zoom:0,projection:this.projection})}),this.interactions={},this.selectInteractions={},this.mapControls={},this.addOrUpdateLayer=t=>{var e;t.interactions||(t.interactions=[]);const i=(e=t.properties)==null?void 0:e.id,n=i?d_(this,i):!1;let r;return n?(sI(this,t,n),r=n):(r=sc(this,t),this.map.addLayer(r)),r},this.removeInteraction=t=>{this.map.removeInteraction(this.interactions[t]),delete this.interactions[t],this.interactions[`${t}_modify`]&&(this.map.removeInteraction(this.interactions[`${t}_modify`]),delete this.interactions[`${t}_modify`])},this.removeSelect=t=>{this.selectInteractions[t].remove(),delete this.selectInteractions[t]},this.removeControl=t=>{this.map.removeControl(this.mapControls[t]),delete this.mapControls[t]},this.getLayerById=t=>d_(this,t),this.parseFeature=t=>new Em().writeFeaturesObject(t,$x),this.parseTextToFeature=(t,e,i=!1)=>{eU(t,e,this,i)},this.registerProjectionFromCode=oU,this.registerProjection=aU,this.getFlatLayersArray=nI}set center(t){const e=t?.length&&GU(t,this.map.getView().getCenter());if(t&&!e){if(!this.projection||this.projection==="EPSG:3857"){const i=XS(t);this._center=i}else this._center=t;this._animateToState()}}get center(){return this._center}set zoom(t){t!==void 0&&(this._zoom=t,this._animateToState())}get zoom(){return this._zoom}set zoomExtent(t){if(!t||!t.length){this._zoomExtent=void 0;return}const e=this.map.getView();WS(e),setTimeout(()=>{e.fit(t,this.animationOptions)},0),this._zoomExtent=t}set controls(t){const e=this._controls,i=t;if(e){const n=Object.keys(e),r=Object.keys(i);for(let o=0,a=n.length;o{var o,a,l;if(!((o=r.properties)!=null&&o.id)||!i.find(h=>h.properties.id===r.properties.id)){const h=d_(this,(a=r.properties)==null?void 0:a.id);(l=h.get("_jsonDefinition").interactions)==null||l.forEach(c=>{c.type==="select"?this.removeSelect(c.options.id):this.removeInteraction(c.options.id)}),this.map.removeLayer(h)}}),i.forEach(r=>{this.addOrUpdateLayer(r)});const n=i.map(r=>{var o;return(o=r.properties)==null?void 0:o.id});this.map.getLayers().getArray().sort((r,o)=>n.indexOf(r.get("id"))-n.indexOf(o.get("id"))),this._layers=i}get layers(){return this._layers}set preventScroll(t){t?(zU(this.map),JS(this.map,!0)):JS(this.map),this._preventScroll=t}get preventScroll(){return this._preventScroll}set config(t){var e,i,n,r;this._config=t,t?.animationOptions!==void 0&&(this.animationOptions=t.animationOptions),this.projection=((e=t?.view)==null?void 0:e.projection)||"EPSG:3857",this.layers=t?.layers||[],this.controls=t?.controls||{},this.preventScroll===void 0&&(this.preventScroll=t?.preventScroll),this.zoom=((i=t?.view)==null?void 0:i.zoom)||0,this.center=((n=t?.view)==null?void 0:n.center)||[0,0],this.zoomExtent=(r=t?.view)==null?void 0:r.zoomExtent}set animationOptions(t){this._animationOptions=t}get animationOptions(){return this._animationOptions}get config(){return this._config}get projection(){return this._projection}set projection(t){const e=this.map.getView();if(t&&Bt(t)&&t!==e.getProjection().getCode()){const i=Qd(e.getCenter(),e.getProjection().getCode(),t),n=Bt(t),r=e.getResolution(),o=e.getProjection().getMetersPerUnit(),a=n.getMetersPerUnit(),l=Yh(e.getProjection(),1/o,e.getCenter(),"m")*o,h=Yh(n,1/a,i,"m")*a,c=r*l/h,u=new nn({zoom:e.getZoom(),center:i,resolution:c,rotation:e.getRotation(),projection:t});["change:center","change:resolution","change:rotation","propertychange"].forEach(d=>{const g=e.getListeners(d);if(g!=null&&g.length)for(let f=g.length-1;f>=0;f--){const p=g[f];e.un(d,p),u.on(d,p)}}),this.map.setView(u),this.getFlatLayersArray(this.map.getLayers().getArray()).filter(d=>d instanceof og).forEach(d=>d.getSource().refresh()),this._projection=t,this.center=i}}set sync(t){this._sync=t,t&&setTimeout(()=>{const e=UU(t);e&&this.map.setView(e.map.getView())})}get sync(){return this._sync}_animateToState(){const t=Object.assign({},this.animationOptions),e=this.map.getView();if(WS(e),!t||!Object.keys(t).length){e.setCenter(this.center),e.setZoom(this.zoom);return}t.center=XS(this.center),t.zoom=this.zoom,e.animate(t)}render(){return Gr` + `}};oI([Er()],Gx.prototype,"value");oI([Er({type:String})],Gx.prototype,"enabled");customElements.define("eox-map-compare",Gx);function GU(s,t,e=.001){let i=!0;for(let n=s.length-1;n>=0;--n)if(!jU(s[n],t[n],e)){i=!1;break}return i}function jU(s,t,e=.001){return Math.abs(s-t)0?s.addInteraction(new Ou({condition:function(e){return this.getPointerCount()===2||ZE(e)}})):s.addInteraction(new Ou)):(s.addInteraction(new ap),s.addInteraction(new Ou))}function zU(s){s.getInteractions().getArray().forEach(t=>{(t instanceof ap||t instanceof Ou)&&s.removeInteraction(t)})}const UU=s=>{let t;return typeof s=="string"?t=document.querySelector(s):t=s,t};var BU=Object.defineProperty,WU=Object.getOwnPropertyDescriptor,qn=(s,t,e,i)=>{for(var n=i>1?void 0:i?WU(t,e):t,r=s.length-1,o;r>=0;r--)(o=s[r])&&(n=(i?o(t,e,n):o(n))||n);return i&&n&&BU(t,e,n),n};let yn=class extends Mh{constructor(){super(...arguments),this._center=[0,0],this._zoom=0,this._animationOptions={},this.map=new ET({controls:[],layers:[],view:new nn({center:[0,0],zoom:0,projection:this.projection})}),this.interactions={},this.selectInteractions={},this.mapControls={},this.addOrUpdateLayer=t=>{var e;t.interactions||(t.interactions=[]);const i=(e=t.properties)==null?void 0:e.id,n=i?d_(this,i):!1;let r;return n?(sI(this,t,n),r=n):(r=sc(this,t),this.map.addLayer(r)),r},this.removeInteraction=t=>{this.map.removeInteraction(this.interactions[t]),delete this.interactions[t],this.interactions[`${t}_modify`]&&(this.map.removeInteraction(this.interactions[`${t}_modify`]),delete this.interactions[`${t}_modify`])},this.removeSelect=t=>{this.selectInteractions[t].remove(),delete this.selectInteractions[t]},this.removeControl=t=>{this.map.removeControl(this.mapControls[t]),delete this.mapControls[t]},this.getLayerById=t=>d_(this,t),this.parseFeature=t=>new Em().writeFeaturesObject(t,$x),this.parseTextToFeature=(t,e,i=!1)=>{eU(t,e,this,i)},this.registerProjectionFromCode=oU,this.registerProjection=aU,this.getFlatLayersArray=nI}set center(t){const e=t?.length&&GU(t,this.map.getView().getCenter());if(t&&!e){if(!this.projection||this.projection==="EPSG:3857"){const i=XS(t);this._center=i}else this._center=t;this._animateToState()}}get center(){return this._center}set zoom(t){t!==void 0&&(this._zoom=t,this._animateToState())}get zoom(){return this._zoom}set zoomExtent(t){if(!t||!t.length){this._zoomExtent=void 0;return}const e=this.map.getView();WS(e),setTimeout(()=>{e.fit(t,this.animationOptions)},0),this._zoomExtent=t}set controls(t){const e=this._controls,i=t;if(e){const n=Object.keys(e),r=Object.keys(i);for(let o=0,a=n.length;o{var o,a,l;if(!((o=r.properties)!=null&&o.id)||!i.find(h=>h.properties.id===r.properties.id)){const h=d_(this,(a=r.properties)==null?void 0:a.id);(l=h.get("_jsonDefinition").interactions)==null||l.forEach(c=>{c.type==="select"?this.removeSelect(c.options.id):this.removeInteraction(c.options.id)}),this.map.removeLayer(h)}}),i.forEach(r=>{this.addOrUpdateLayer(r)});const n=i.map(r=>{var o;return(o=r.properties)==null?void 0:o.id});this.map.getLayers().getArray().sort((r,o)=>n.indexOf(r.get("id"))-n.indexOf(o.get("id"))),this._layers=i}get layers(){return this._layers}set preventScroll(t){t?(zU(this.map),JS(this.map,!0)):JS(this.map),this._preventScroll=t}get preventScroll(){return this._preventScroll}set config(t){var e,i,n,r;this._config=t,t?.animationOptions!==void 0&&(this.animationOptions=t.animationOptions),this.projection=((e=t?.view)==null?void 0:e.projection)||"EPSG:3857",this.layers=t?.layers||[],this.controls=t?.controls||{},this.preventScroll===void 0&&(this.preventScroll=t?.preventScroll),this.zoom=((i=t?.view)==null?void 0:i.zoom)||0,this.center=((n=t?.view)==null?void 0:n.center)||[0,0],this.zoomExtent=(r=t?.view)==null?void 0:r.zoomExtent}set animationOptions(t){this._animationOptions=t}get animationOptions(){return this._animationOptions}get config(){return this._config}get projection(){return this._projection}set projection(t){const e=this.map.getView();if(t&&Bt(t)&&t!==e.getProjection().getCode()){const i=Qd(e.getCenter(),e.getProjection().getCode(),t),n=Bt(t),r=e.getResolution(),o=e.getProjection().getMetersPerUnit(),a=n.getMetersPerUnit(),l=Yh(e.getProjection(),1/o,e.getCenter(),"m")*o,h=Yh(n,1/a,i,"m")*a,c=r*l/h,u=new nn({zoom:e.getZoom(),center:i,resolution:c,rotation:e.getRotation(),projection:t});["change:center","change:resolution","change:rotation","propertychange"].forEach(d=>{const g=e.getListeners(d);if(g!=null&&g.length)for(let f=g.length-1;f>=0;f--){const p=g[f];e.un(d,p),u.on(d,p)}}),this.map.setView(u),this.getFlatLayersArray(this.map.getLayers().getArray()).filter(d=>d instanceof og).forEach(d=>d.getSource().refresh()),this._projection=t,this.center=i}}set sync(t){this._sync=t,t&&setTimeout(()=>{const e=UU(t);e&&this.map.setView(e.map.getView())})}get sync(){return this._sync}_animateToState(){const t=Object.assign({},this.animationOptions),e=this.map.getView();if(WS(e),!t||!Object.keys(t).length){e.setCenter(this.center),e.setZoom(this.zoom);return}t.center=XS(this.center),t.zoom=this.zoom,e.animate(t)}render(){return Gr`
- `}buffer(t,e){return gn(t,e)}firstUpdated(){this.map.once("change:target",t=>{t.target.getView().setCenter(this.center)}),this.map.setTarget(this.renderRoot.querySelector("div")),this._zoomExtent?this.map.getView().fit(this._zoomExtent,this.animationOptions):this._animateToState(),this.map.on("loadend",()=>{this.dispatchEvent(new CustomEvent("loadend",{detail:this.map}))}),this.dispatchEvent(new CustomEvent("mapmounted",{detail:this.map}))}updated(t){}};qn([Er({attribute:!1,type:Array})],yn.prototype,"center",1);qn([Er({attribute:!1,type:Array})],yn.prototype,"layers",1);qn([Er({attribute:"prevent-scroll",type:Boolean})],yn.prototype,"preventScroll",1);qn([Er({attribute:!1,type:Object})],yn.prototype,"config",1);qn([Er({attribute:"projection",type:String})],yn.prototype,"projection",1);qn([Er()],yn.prototype,"sync",1);qn([hm()],yn.prototype,"map",2);qn([hm()],yn.prototype,"interactions",2);qn([hm()],yn.prototype,"selectInteractions",2);qn([hm()],yn.prototype,"mapControls",2);yn=qn([DF("eox-map")],yn);var XU=Object.defineProperty,VU=(s,t,e)=>t in s?XU(s,t,{enumerable:!0,configurable:!0,writable:!0,value:e}):s[t]=e,jx=(s,t,e)=>VU(s,typeof t!="symbol"?t+"":t,e);class Sr{constructor(t){this.propagationStopped,this.defaultPrevented,this.type=t,this.target=null}preventDefault(){this.defaultPrevented=!0}stopPropagation(){this.propagationStopped=!0}}const zx={PROPERTYCHANGE:"propertychange"};class Ux{constructor(){this.disposed=!1}dispose(){this.disposed||(this.disposed=!0,this.disposeInternal())}disposeInternal(){}}function YU(s,t,e){let i,n;e=e||fr;let r=0,o=s.length,a=!1;for(;r>1),n=+e(s[i],t),n<0?r=i+1:(o=i,a=!n);return a?r:~r}function fr(s,t){return s>t?1:st?-1:0}function Om(s,t,e){if(s[0]<=t)return 0;const i=s.length;if(t<=s[i-1])return i-1;if(typeof e=="function"){for(let n=1;n0?n-1:n}return i-1}if(e>0){for(let n=1;n0||o===0)})}function KU(){return!0}function Md(){}function aI(s){let t,e,i;return function(){const n=Array.prototype.slice.call(arguments);return(!e||this!==i||!vl(n,e))&&(i=this,e=n,t=s.apply(this,arguments)),t}}function lI(s){function t(){let e;try{e=s()}catch(i){return Promise.reject(i)}return e instanceof Promise?e:Promise.resolve(e)}return t()}function Mc(s){for(const t in s)delete s[t]}function eo(s){let t;for(t in s)return!1;return!t}class fg extends Ux{constructor(t){super(),this.eventTarget_=t,this.pendingRemovals_=null,this.dispatching_=null,this.listeners_=null}addEventListener(t,e){if(!t||!e)return;const i=this.listeners_||(this.listeners_={}),n=i[t]||(i[t]=[]);n.includes(e)||n.push(e)}dispatchEvent(t){const e=typeof t=="string",i=e?t:t.type,n=this.listeners_&&this.listeners_[i];if(!n)return;const r=e?new Sr(t):t;r.target||(r.target=this.eventTarget_||this);const o=this.dispatching_||(this.dispatching_={}),a=this.pendingRemovals_||(this.pendingRemovals_={});i in o||(o[i]=0,a[i]=0),++o[i];let l;for(let h=0,c=n.length;h0:!1}removeEventListener(t,e){if(!this.listeners_)return;const i=this.listeners_[t];if(!i)return;const n=i.indexOf(e);n!==-1&&(this.pendingRemovals_&&t in this.pendingRemovals_?(i[n]=Md,++this.pendingRemovals_[t]):(i.splice(n,1),i.length===0&&delete this.listeners_[t]))}}const Zt={CHANGE:"change",ERROR:"error",BLUR:"blur",CLEAR:"clear",CONTEXTMENU:"contextmenu",CLICK:"click",DBLCLICK:"dblclick",DRAGENTER:"dragenter",DRAGOVER:"dragover",DROP:"drop",FOCUS:"focus",KEYDOWN:"keydown",KEYPRESS:"keypress",LOAD:"load",RESIZE:"resize",TOUCHMOVE:"touchmove",WHEEL:"wheel"};function We(s,t,e,i,n){if(n){const o=e;e=function(){s.removeEventListener(t,e),o.apply(i??this,arguments)}}else i&&i!==s&&(e=e.bind(i));const r={target:s,type:t,listener:e};return s.addEventListener(t,e),r}function bd(s,t,e,i){return We(s,t,e,i,!0)}function ms(s){s&&s.target&&(s.target.removeEventListener(s.type,s.listener),Mc(s))}class pg extends fg{constructor(){super(),this.on=this.onInternal,this.once=this.onceInternal,this.un=this.unInternal,this.revision_=0}changed(){++this.revision_,this.dispatchEvent(Zt.CHANGE)}getRevision(){return this.revision_}onInternal(t,e){if(Array.isArray(t)){const i=t.length,n=new Array(i);for(let r=0;rMath.round(t*t2[e])/t2[e]).join(", ")+")"}const Ss={UNKNOWN:0,INTERSECTING:1,ABOVE:2,RIGHT:4,BELOW:8,LEFT:16};function ic(s){const t=Zs();for(let e=0,i=s.length;en&&(l=l|Ss.RIGHT),ar&&(l=l|Ss.ABOVE),l===Ss.UNKNOWN&&(l=Ss.INTERSECTING),l}function Zs(){return[1/0,1/0,-1/0,-1/0]}function Un(s,t,e,i,n){return n?(n[0]=s,n[1]=t,n[2]=e,n[3]=i,n):[s,t,e,i]}function mg(s){return Un(1/0,1/0,-1/0,-1/0,s)}function Vx(s,t){const e=s[0],i=s[1];return Un(e,i,e,i,t)}function Yx(s,t,e,i,n){const r=mg(n);return uI(r,s,t,e,i)}function so(s,t){return s[0]==t[0]&&s[2]==t[2]&&s[1]==t[1]&&s[3]==t[3]}function a9(s,t,e){return Math.abs(s[0]-t[0])s[2]&&(s[2]=t[2]),t[1]s[3]&&(s[3]=t[3]),s}function Wu(s,t){t[0]s[2]&&(s[2]=t[0]),t[1]s[3]&&(s[3]=t[1])}function uI(s,t,e,i,n){for(;et[0]?i[0]=s[0]:i[0]=t[0],s[1]>t[1]?i[1]=s[1]:i[1]=t[1],s[2]=t[0]&&s[1]<=t[3]&&s[3]>=t[1]}function po(s){return s[2]=o&&p<=l),!i&&r&Ss.RIGHT&&!(n&Ss.RIGHT)&&(m=g-(d-l)*f,i=m>=a&&m<=h),!i&&r&Ss.BELOW&&!(n&Ss.BELOW)&&(p=d-(g-a)/f,i=p>=o&&p<=l),!i&&r&Ss.LEFT&&!(n&Ss.LEFT)&&(m=g-(d-o)*f,i=m>=a&&m<=h)}return i}function nc(s,t,e,i){if(po(s))return mg(e);let n=[];if(i>1){const a=s[2]-s[0],l=s[3]-s[1];for(let h=0;h=e[2])){const n=Rt(e),r=Math.floor((i[0]-e[0])/n)*n;s[0]-=r,s[2]-=r}return s}function Hx(s,t,e){if(t.canWrapX()){const i=t.getExtent();if(!isFinite(s[0])||!isFinite(s[2]))return[[i[0],s[1],i[2],s[3]]];Zx(s,t);const n=Rt(i);if(Rt(s)>n&&!e)return[[i[0],s[1],i[2],s[3]]];if(s[0]i[2])return[[s[0],s[1],i[2],s[3]],[i[0],s[1],s[2]-n,s[3]]]}return[s]}const g9={9001:"m",9002:"ft",9003:"us-ft",9101:"radians",9102:"degrees"};function e2(s){return g9[s]}const Kx={radians:6370997/(2*Math.PI),degrees:2*Math.PI*6370997/360,ft:.3048,m:1,"us-ft":1200/3937};let rc=class{constructor(s){this.code_=s.code,this.units_=s.units,this.extent_=s.extent!==void 0?s.extent:null,this.worldExtent_=s.worldExtent!==void 0?s.worldExtent:null,this.axisOrientation_=s.axisOrientation!==void 0?s.axisOrientation:"enu",this.global_=s.global!==void 0?s.global:!1,this.canWrapX_=!!(this.global_&&this.extent_),this.getPointResolutionFunc_=s.getPointResolution,this.defaultTileGrid_=null,this.metersPerUnit_=s.metersPerUnit}canWrapX(){return this.canWrapX_}getCode(){return this.code_}getExtent(){return this.extent_}getUnits(){return this.units_}getMetersPerUnit(){return this.metersPerUnit_||Kx[this.units_]}getWorldExtent(){return this.worldExtent_}getAxisOrientation(){return this.axisOrientation_}isGlobal(){return this.global_}setGlobal(s){this.global_=s,this.canWrapX_=!!(s&&this.extent_)}getDefaultTileGrid(){return this.defaultTileGrid_}setDefaultTileGrid(s){this.defaultTileGrid_=s}setExtent(s){this.extent_=s,this.canWrapX_=!!(this.global_&&s)}setWorldExtent(s){this.worldExtent_=s}setGetPointResolution(s){this.getPointResolutionFunc_=s}getPointResolutionFunc(){return this.getPointResolutionFunc_}};const xg=6378137,gh=Math.PI*xg,f9=[-gh,-gh,gh,gh],p9=[-180,-85,180,85],df=xg*Math.log(Math.tan(Math.PI/2));class Fl extends rc{constructor(t){super({code:t,units:"m",extent:f9,global:!0,worldExtent:p9,getPointResolution:function(e,i){return e/Math.cosh(i[1]/xg)}})}}const s2=[new Fl("EPSG:3857"),new Fl("EPSG:102100"),new Fl("EPSG:102113"),new Fl("EPSG:900913"),new Fl("http://www.opengis.net/def/crs/EPSG/0/3857"),new Fl("http://www.opengis.net/gml/srs/epsg.xml#3857")];function m9(s,t,e){const i=s.length;e=e>1?e:2,t===void 0&&(e>2?t=s.slice():t=new Array(i));for(let n=0;ndf?r=df:r<-df&&(r=-df),t[n+1]=r}return t}function _9(s,t,e){const i=s.length;e=e>1?e:2,t===void 0&&(e>2?t=s.slice():t=new Array(i));for(let n=0;n1?(e=n,i=r):l>0&&(e+=o*l,i+=a*l)}return Xa(s,t,e,i)}function Xa(s,t,e,i){const n=e-s,r=i-t;return n*n+r*r}function E9(s){const t=s.length;for(let i=0;ir&&(r=l,n=a)}if(r===0)return null;const o=s[n];s[n]=s[i],s[i]=o;for(let a=i+1;a=0;i--){e[i]=s[i][t]/s[i][i];for(let n=i-1;n>=0;n--)s[n][t]-=s[n][i]*e[i]}return e}function Xu(s){return s*Math.PI/180}function kn(s,t){const e=s%t;return e*t<0?e+t:e}function Ui(s,t,e){return s+e*(t-s)}function vg(s,t){const e=Math.pow(10,t);return Math.round(s*e)/e}function Mp(s,t){return Math.round(vg(s,t))}function fh(s,t){return Math.floor(vg(s,t))}function Xo(s,t){return Math.ceil(vg(s,t))}function Oa(s,t,e){const i=e!==void 0?s.toFixed(e):""+s;let n=i.indexOf(".");return n=n===-1?i.length:n,n>t?i:new Array(1+t-n).join("0")+i}function Jx(s,t){const e=(""+s).split("."),i=(""+t).split(".");for(let n=0;no)return 1;if(o>r)return-1}return 0}function mI(s,t){return s[0]+=+t[0],s[1]+=+t[1],s}function r2(s,t,e){const i=kn(t+180,360)-180,n=Math.abs(3600*i),r=e||0;let o=Math.floor(n/3600),a=Math.floor((n-o*3600)/60),l=vg(n-o*3600-a*60,r);l>=60&&(l=0,a+=1),a>=60&&(a=0,o+=1);let h=o+"°";return(a!==0||l!==0)&&(h+=" "+Oa(a,2)+"′"),l!==0&&(h+=" "+Oa(l,2,r)+"″"),i!==0&&(h+=" "+s.charAt(i<0?1:0)),h}function bp(s,t){let e=!0;for(let i=s.length-1;i>=0;--i)if(s[i]!=t[i]){e=!1;break}return e}function S9(s,t){const e=Math.cos(t),i=Math.sin(t),n=s[0]*e-s[1]*i,r=s[1]*e+s[0]*i;return s[0]=n,s[1]=r,s}function M9(s,t){return s[0]*=t,s[1]*=t,s}function _I(s,t){if(t.canWrapX()){const e=Rt(t.getExtent()),i=yI(s,t,e);i&&(s[0]-=i*e)}return s}function yI(s,t,e){const i=t.getExtent();let n=0;return t.canWrapX()&&(s[0]i[2])&&(e=e||Rt(i),n=Math.floor((s[0]-i[0])/e)),n}const b9=63710088e-1;function o2(s,t,e){e=e||b9;const i=Xu(s[1]),n=Xu(t[1]),r=(n-i)/2,o=Xu(t[0]-s[0])/2,a=Math.sin(r)*Math.sin(r)+Math.sin(o)*Math.sin(o)*Math.cos(i)*Math.cos(n);return 2*e*Math.atan2(Math.sqrt(a),Math.sqrt(1-a))}function T9(...s){console.warn(...s)}function Cd(...s){console.error(...s)}let B1=!0;function C9(s){B1=!1}function Qx(s,t){if(t!==void 0){for(let e=0,i=s.length;e=a?t[r+l]:o[l]}return e}}function P9(s,t,e,i){const n=st(s),r=st(t);oc(n,r,l2(e)),oc(r,n,l2(i))}function h2(s,t){const e=Dm(s,t!==void 0?t:"EPSG:3857","EPSG:4326"),i=e[0];return(i<-180||i>180)&&(e[0]=kn(i+180,360)-180),e}function qs(s,t){if(s===t)return!0;const e=s.getUnits()===t.getUnits();return(s.getCode()===t.getCode()||Sl(s,t)===Qx)&&e}function Sl(s,t){const e=s.getCode(),i=t.getCode();let n=fI(e,i);return n||(n=xI),n}function vr(s,t){const e=st(s),i=st(t);return Sl(e,i)}function Dm(s,t,e){return vr(t,e)(s,void 0,s.length)}function ev(s,t,e,i){const n=vr(t,e);return nc(s,n,void 0,i)}let A9=null;function L9(){return A9}function X1(s,t){return s}function bo(s,t){return B1&&!bp(s,[0,0])&&s[0]>=-180&&s[0]<=180&&s[1]>=-90&&s[1]<=90&&(B1=!1,T9("Call useGeographic() from ol/proj once to work with [longitude, latitude] coordinates.")),s}function km(s,t){return s}function cn(s,t){return s}function c2(s,t,e){return function(i){let n,r;if(s.canWrapX()){const o=s.getExtent(),a=Rt(o);i=i.slice(0),r=yI(i,s,a),r&&(i[0]=i[0]-r*a),i[0]=Dt(i[0],o[0],o[2]),i[1]=Dt(i[1],o[1],o[3]),n=e(i)}else n=e(i);return r&&t.canWrapX()&&(n[0]+=r*Rt(t.getExtent())),n}}function O9(){W1(s2),W1(n2),I9(n2,s2,m9,_9)}O9();function Jo(s,t,e,i,n,r){r=r||[];let o=0;for(let a=t;a{if(!i)return this.getSimplifiedGeometry(e);const n=this.clone();return n.applyTransform(i),n.getSimplifiedGeometry(e)})}simplifyTransformed(t,e){return this.simplifyTransformedInternal(this.getRevision(),t,e)}clone(){return vt()}closestPointXY(t,e,i,n){return vt()}containsXY(t,e){const i=this.getClosestPoint([t,e]);return i[0]===t&&i[1]===e}getClosestPoint(t,e){return e=e||[NaN,NaN],this.closestPointXY(t[0],t[1],e,1/0),e}intersectsCoordinate(t){return this.containsXY(t[0],t[1])}computeExtent(t){return vt()}getExtent(t){if(this.extentRevision_!=this.getRevision()){const e=this.computeExtent(this.extent_);(isNaN(e[0])||isNaN(e[1]))&&mg(e),this.extentRevision_=this.getRevision()}return u9(this.extent_,t)}rotate(t,e){vt()}scale(t,e,i){vt()}simplify(t){return this.getSimplifiedGeometry(t*t)}getSimplifiedGeometry(t){return vt()}getType(){return vt()}applyTransform(t){vt()}intersectsExtent(t){return vt()}translate(t,e){vt()}transform(t,e){const i=st(t),n=i.getUnits()=="tile-pixels"?function(r,o,a){const l=i.getExtent(),h=i.getWorldExtent(),c=Ee(h)/Ee(l);return xn(u2,h[0],h[3],c,-c,0,0,0),Jo(r,0,r.length,a,u2,o),vr(i,e)(r,o,a)}:vr(i,e);return this.applyTransform(n),this}}class D9 extends sv{constructor(){super(),this.layout="XY",this.stride=2,this.flatCoordinates}computeExtent(t){return Yx(this.flatCoordinates,0,this.flatCoordinates.length,this.stride,t)}getCoordinates(){return vt()}getFirstCoordinate(){return this.flatCoordinates.slice(0,this.stride)}getFlatCoordinates(){return this.flatCoordinates}getLastCoordinate(){return this.flatCoordinates.slice(this.flatCoordinates.length-this.stride)}getLayout(){return this.layout}getSimplifiedGeometry(t){if(this.simplifiedGeometryRevision!==this.getRevision()&&(this.simplifiedGeometryMaxMinSquaredTolerance=0,this.simplifiedGeometryRevision=this.getRevision()),t<0||this.simplifiedGeometryMaxMinSquaredTolerance!==0&&t<=this.simplifiedGeometryMaxMinSquaredTolerance)return this;const e=this.getSimplifiedGeometryInternal(t);return e.getFlatCoordinates().lengtht.clone())}function d2(s,t,e,i,n,r,o){const a=s[t],l=s[t+1],h=s[e]-a,c=s[e+1]-l;let u;if(h===0&&c===0)u=t;else{const d=((n-a)*h+(r-l)*c)/(h*h+c*c);if(d>1)u=e;else if(d>0){for(let g=0;gn&&(n=h),r=a,o=l}return n}function nv(s,t,e,i,n){for(let r=0,o=e.length;r0;){const u=h.pop(),d=h.pop();let g=0;const f=s[d],p=s[d+1],m=s[u],_=s[u+1];for(let y=d+i;yg&&(c=y,g=w)}g>n&&(l[(c-t)/i]=1,d+i0&&p>g)&&(f<0&&m0&&m>f)){h=u,c=d;continue}r[o++]=h,r[o++]=c,a=h,l=c,h=u,c=d}return r[o++]=h,r[o++]=c,o}function av(s,t,e,i,n,r,o,a){for(let l=0,h=e.length;l1?o:2,r=r||new Array(o);for(let c=0;c>1;nr&&(h-a)*(r-l)-(n-a)*(c-l)>0&&o++:c<=r&&(h-a)*(r-l)-(n-a)*(c-l)<0&&o--,a=h,l=c}return o!==0}function lv(s,t,e,i,n,r){if(e.length===0||!ja(s,t,e[0],i,n,r))return!1;for(let o=1,a=e.length;o=n[0]&&r[2]<=n[2]||r[1]>=n[1]&&r[3]<=n[3]?!0:TI(s,t,e,i,function(o,a){return d9(n,o,a)}):!1}function Y9(s,t,e,i,n){for(let r=0,o=e.length;r_&&(h=(c+u)/2,lv(s,t,e,i,h,f)&&(m=h,_=y)),c=u}return isNaN(m)&&(m=n[r]),o?(o.push(m,f,_),o):[m,f,_]}function AI(s,t,e,i,n){let r=[];for(let o=0,a=e.length;o0}function cv(s,t,e,i,n){n=n!==void 0?n:!1;for(let r=0,o=e.length;r{if(t===this.squaredTolerance_)return this.simplifiedGeometry_;this.simplifiedGeometry_=this.clone(),e&&this.simplifiedGeometry_.applyTransform(e);const i=this.simplifiedGeometry_.getFlatCoordinates();let n;switch(this.type_){case"LineString":i.length=$m(i,0,this.simplifiedGeometry_.flatCoordinates_.length,this.simplifiedGeometry_.stride_,t,i,0),n=[i.length];break;case"MultiLineString":n=[],i.length=SI(i,0,this.simplifiedGeometry_.ends_,this.simplifiedGeometry_.stride_,t,i,0,n);break;case"Polygon":n=[],i.length=av(i,0,this.simplifiedGeometry_.ends_,this.simplifiedGeometry_.stride_,Math.sqrt(t),i,0,n);break}return n&&(this.simplifiedGeometry_=new si(this.type_,i,n,2,this.properties_,this.id_)),this.squaredTolerance_=t,this.simplifiedGeometry_}),this}}si.prototype.getFlatCoordinates=si.prototype.getOrientedFlatCoordinates;class H9{constructor(){this.dataProjection=void 0,this.defaultFeatureProjection=void 0,this.featureClass=ys,this.supportedMediaTypes=null}getReadOptions(t,e){if(e){let i=e.dataProjection?st(e.dataProjection):this.readProjection(t);e.extent&&i&&i.getUnits()==="tile-pixels"&&(i=st(i),i.setWorldExtent(e.extent)),e={dataProjection:i,featureProjection:e.featureProjection}}return this.adaptOptions(e)}adaptOptions(t){return Object.assign({dataProjection:this.dataProjection,featureProjection:this.defaultFeatureProjection,featureClass:this.featureClass},t)}getType(){return vt()}readFeature(t,e){return vt()}readFeatures(t,e){return vt()}readGeometry(t,e){return vt()}readProjection(t){return vt()}writeFeature(t,e){return vt()}writeFeatures(t,e){return vt()}writeGeometry(t,e){return vt()}}const Sg=H9;function De(s,t,e){const i=e?st(e.featureProjection):null,n=e?st(e.dataProjection):null;let r=s;if(i&&n&&!qs(i,n)){t&&(r=s.clone());const o=t?i:n,a=t?n:i;o.getUnits()==="tile-pixels"?r.transform(o,a):r.applyTransform(vr(o,a))}if(t&&e&&e.decimals!==void 0){const o=Math.pow(10,e.decimals),a=function(l){for(let h=0,c=l.length;hNI({...s,geometry:o})).flat();const n=i.type==="MultiPolygon"?"Polygon":i.type;if(n==="GeometryCollection"||n==="Circle")throw new Error("Unsupported geometry type: "+n);const r=i.layout.length;return De(new si(n,n==="Polygon"?J9(i.flatCoordinates,i.ends,r):i.flatCoordinates,(e=i.ends)==null?void 0:e.flat(),r,s.properties||{},s.id).enableSimplifyTransformed(),!1,t)}function dv(s,t){if(!s)return null;if(Array.isArray(s)){const i=s.map(n=>dv(n,t));return new _s(i)}const e=K9[s.type];return De(new e(s.flatCoordinates,s.layout,s.ends),!1,t)}class gv extends Sg{constructor(){super()}getType(){return"json"}readFeature(t,e){return this.readFeatureFromObject(gf(t),this.getReadOptions(t,e))}readFeatures(t,e){return this.readFeaturesFromObject(gf(t),this.getReadOptions(t,e))}readFeatureFromObject(t,e){return vt()}readFeaturesFromObject(t,e){return vt()}readGeometry(t,e){return this.readGeometryFromObject(gf(t),this.getReadOptions(t,e))}readGeometryFromObject(t,e){return vt()}readProjection(t){return this.readProjectionFromObject(gf(t))}readProjectionFromObject(t){return vt()}writeFeature(t,e){return JSON.stringify(this.writeFeatureObject(t,e))}writeFeatureObject(t,e){return vt()}writeFeatures(t,e){return JSON.stringify(this.writeFeaturesObject(t,e))}writeFeaturesObject(t,e){return vt()}writeGeometry(t,e){return JSON.stringify(this.writeGeometryObject(t,e))}writeGeometryObject(t,e){return vt()}}function gf(s){return typeof s=="string"?JSON.parse(s)||null:s!==null?s:null}const Q9={Point:i7,LineString:n7,Polygon:l7,MultiPoint:o7,MultiLineString:r7,MultiPolygon:a7},t7={Point:h7,LineString:c7,Polygon:u7,MultiPoint:g7,MultiLineString:d7,MultiPolygon:f7};class e7 extends gv{constructor(t){t=t||{},super(),this.geometryName_=t.geometryName}readFeatureFromObject(t,e,i){const n=t,r=p2(n.geometry,e),o=new ys;if(this.geometryName_&&o.setGeometryName(this.geometryName_),o.setGeometry(r),n.attributes){o.setProperties(n.attributes,!0);const a=n.attributes[i];a!==void 0&&o.setId(a)}return o}readFeaturesFromObject(t,e){if(e=e||{},t.features){const i=t,n=[],r=i.features;for(let o=0,a=r.length;o=0;r--){const h=i[r][0];if(ai(new aa(h).getExtent(),new aa(a).getExtent())){i[r].push(a),l=!0;break}}l||i.push([a.reverse()])}return i}function i7(s){let t;return s.m!==void 0&&s.z!==void 0?t=new Ts([s.x,s.y,s.z,s.m],"XYZM"):s.z!==void 0?t=new Ts([s.x,s.y,s.z],"XYZ"):s.m!==void 0?t=new Ts([s.x,s.y,s.m],"XYM"):t=new Ts([s.x,s.y]),t}function n7(s){const t=Tc(s);return new ls(s.paths[0],t)}function r7(s){const t=Tc(s);return new Pi(s.paths,t)}function Tc(s){let t="XY";return s.hasZ===!0&&s.hasM===!0?t="XYZM":s.hasZ===!0?t="XYZ":s.hasM===!0&&(t="XYM"),t}function o7(s){const t=Tc(s);return new Zn(s.points,t)}function a7(s){const t=Tc(s);return new vn(s.rings,t)}function l7(s){const t=Tc(s);return new Hs(s.rings,t)}function h7(s,t){const e=s.getCoordinates();let i;const n=s.getLayout();if(n==="XYZ")i={x:e[0],y:e[1],z:e[2]};else if(n==="XYM")i={x:e[0],y:e[1],m:e[2]};else if(n==="XYZM")i={x:e[0],y:e[1],z:e[2],m:e[3]};else if(n==="XY")i={x:e[0],y:e[1]};else throw new Error("Invalid geometry layout");return i}function Mg(s){const t=s.getLayout();return{hasZ:t==="XYZ"||t==="XYZM",hasM:t==="XYM"||t==="XYZM"}}function c7(s,t){const e=Mg(s);return{hasZ:e.hasZ,hasM:e.hasM,paths:[s.getCoordinates()]}}function u7(s,t){const e=Mg(s);return{hasZ:e.hasZ,hasM:e.hasM,rings:s.getCoordinates(!1)}}function d7(s,t){const e=Mg(s);return{hasZ:e.hasZ,hasM:e.hasM,paths:s.getCoordinates()}}function g7(s,t){const e=Mg(s);return{hasZ:e.hasZ,hasM:e.hasM,points:s.getCoordinates()}}function f7(s,t){const e=Mg(s),i=s.getCoordinates(!1),n=[];for(let r=0;r=0;o--)n.push(i[r][o]);return{hasZ:e.hasZ,hasM:e.hasM,rings:n}}function m2(s,t){const e=t7[s.getType()];return e(De(s,!0,t),t)}const p7=e7;class m7 extends gv{constructor(t){t=t||{},super(),this.dataProjection=st(t.dataProjection?t.dataProjection:"EPSG:4326"),t.featureProjection&&(this.defaultFeatureProjection=st(t.featureProjection)),t.featureClass&&(this.featureClass=t.featureClass),this.geometryName_=t.geometryName,this.extractGeometryName_=t.extractGeometryName,this.supportedMediaTypes=["application/geo+json","application/vnd.geo+json"]}readFeatureFromObject(t,e){let i=null;t.type==="Feature"?i=t:i={type:"Feature",geometry:t,properties:null};const n=fv(i.geometry);if(this.featureClass===si)return NI({geometry:n,id:i.id,properties:i.properties},e);const r=new ys;return this.geometryName_?r.setGeometryName(this.geometryName_):this.extractGeometryName_&&i.geometry_name&&r.setGeometryName(i.geometry_name),r.setGeometry(dv(n,e)),"id"in i&&r.setId(i.id),i.properties&&r.setProperties(i.properties,!0),r}readFeaturesFromObject(t,e){const i=t;let n=null;if(i.type==="FeatureCollection"){const r=t;n=[];const o=r.features;for(let a=0,l=o.length;a0?i[0]:null}readFeatureFromNode(t,e){return null}readFeatures(t,e){if(!t)return[];if(typeof t=="string"){const i=dn(t);return this.readFeaturesFromDocument(i,e)}return un(t)?this.readFeaturesFromDocument(t,e):this.readFeaturesFromNode(t,e)}readFeaturesFromDocument(t,e){const i=[];for(let n=t.firstChild;n;n=n.nextSibling)n.nodeType==Node.ELEMENT_NODE&&ee(i,this.readFeaturesFromNode(n,e));return i}readFeaturesFromNode(t,e){return vt()}readGeometry(t,e){if(!t)return null;if(typeof t=="string"){const i=dn(t);return this.readGeometryFromDocument(i,e)}return un(t)?this.readGeometryFromDocument(t,e):this.readGeometryFromNode(t,e)}readGeometryFromDocument(t,e){return null}readGeometryFromNode(t,e){return null}readProjection(t){if(!t)return null;if(typeof t=="string"){const e=dn(t);return this.readProjectionFromDocument(e)}return un(t)?this.readProjectionFromDocument(t):this.readProjectionFromNode(t)}readProjectionFromDocument(t){return this.dataProjection}readProjectionFromNode(t){return this.dataProjection}writeFeature(t,e){const i=this.writeFeatureNode(t,e);return this.xmlSerializer_.serializeToString(i)}writeFeatureNode(t,e){return null}writeFeatures(t,e){const i=this.writeFeaturesNode(t,e);return this.xmlSerializer_.serializeToString(i)}writeFeaturesNode(t,e){return null}writeGeometry(t,e){const i=this.writeGeometryNode(t,e);return this.xmlSerializer_.serializeToString(i)}writeGeometryNode(t,e){return null}}const Zr="http://www.opengis.net/gml",F7=/^\s*$/;class ut extends bg{constructor(t){super(),t=t||{},this.featureType=t.featureType,this.featureNS=t.featureNS,this.srsName=t.srsName,this.schemaLocation="",this.FEATURE_COLLECTION_PARSERS={},this.FEATURE_COLLECTION_PARSERS[this.namespace]={featureMember:dt(this.readFeaturesInternal),featureMembers:xt(this.readFeaturesInternal)},this.supportedMediaTypes=["application/gml+xml"]}readFeaturesInternal(t,e){const i=t.localName;let n=null;if(i=="FeatureCollection")n=Y([],this.FEATURE_COLLECTION_PARSERS,t,e,this);else if(i=="featureMembers"||i=="featureMember"||i=="member"){const r=e[0];let o=r.featureType,a=r.featureNS;const l="p",h="p0";if(!o&&t.childNodes){o=[],a={};for(let d=0,g=t.childNodes.length;d0&&!(h instanceof sv)){h={_content_:h};for(let d=0;d1,i=e&&s.imageInfo.profile[1].supports?s.imageInfo.profile[1].supports:[],n=e&&s.imageInfo.profile[1].formats?s.imageInfo.profile[1].formats:[],r=e&&s.imageInfo.profile[1].qualities?s.imageInfo.profile[1].qualities:[];return{url:s.imageInfo["@id"].replace(/\/?(?:info\.json)?$/g,""),sizes:s.imageInfo.sizes===void 0?void 0:s.imageInfo.sizes.map(function(o){return[o.width,o.height]}),tileSize:s.imageInfo.tiles===void 0?void 0:[s.imageInfo.tiles.map(function(o){return o.width})[0],s.imageInfo.tiles.map(function(o){return o.height===void 0?o.width:o.height})[0]],resolutions:s.imageInfo.tiles===void 0?void 0:s.imageInfo.tiles.map(function(o){return o.scaleFactors})[0],supports:[...t.supports,...i],formats:[...t.formats,...n],qualities:[...t.qualities,...r]}}function GB(s){const t=s.getComplianceLevelSupportedFeatures(),e=s.imageInfo.extraFormats===void 0?t.formats:[...t.formats,...s.imageInfo.extraFormats],i=s.imageInfo.preferredFormats!==void 0&&Array.isArray(s.imageInfo.preferredFormats)&&s.imageInfo.preferredFormats.length>0?s.imageInfo.preferredFormats.filter(function(n){return["jpg","png","gif"].includes(n)}).reduce(function(n,r){return n===void 0&&e.includes(r)?r:n},void 0):void 0;return{url:s.imageInfo.id,sizes:s.imageInfo.sizes===void 0?void 0:s.imageInfo.sizes.map(function(n){return[n.width,n.height]}),tileSize:s.imageInfo.tiles===void 0?void 0:[s.imageInfo.tiles.map(function(n){return n.width})[0],s.imageInfo.tiles.map(function(n){return n.height})[0]],resolutions:s.imageInfo.tiles===void 0?void 0:s.imageInfo.tiles.map(function(n){return n.scaleFactors})[0],supports:s.imageInfo.extraFeatures===void 0?t.supports:[...t.supports,...s.imageInfo.extraFeatures],formats:e,qualities:s.imageInfo.extraQualities===void 0?t.qualities:[...t.qualities,...s.imageInfo.extraQualities],preferredFormat:i}}const Bm={};Bm[os.VERSION1]=kB;Bm[os.VERSION2]=$B;Bm[os.VERSION3]=GB;class jB{constructor(t){this.setImageInfo(t)}setImageInfo(t){typeof t=="string"?this.imageInfo=JSON.parse(t):this.imageInfo=t}getImageApiVersion(){if(this.imageInfo===void 0)return;let t=this.imageInfo["@context"]||"ol-no-context";typeof t=="string"&&(t=[t]);for(let e=0;e0&&typeof this.imageInfo.profile[0]=="string"&&_2.test(this.imageInfo.profile[0]))return this.imageInfo.profile[0];break}}getComplianceLevelFromProfile(t){const e=this.getComplianceLevelEntryFromProfile(t);if(e===void 0)return;const i=e.match(/level[0-2](?:\.json)?$/g);return Array.isArray(i)?i[0].replace(".json",""):void 0}getComplianceLevelSupportedFeatures(){if(this.imageInfo===void 0)return;const t=this.getImageApiVersion(),e=this.getComplianceLevelFromProfile(t);return e===void 0?rl.none.none:rl[t][e]}getTileSourceOptions(t){const e=t||{},i=this.getImageApiVersion();if(i===void 0)return;const n=i===void 0?void 0:Bm[i](this);if(n!==void 0)return{url:n.url,version:i,size:[this.imageInfo.width,this.imageInfo.height],sizes:n.sizes,format:e.format!==void 0&&n.formats.includes(e.format)?e.format:n.preferredFormat!==void 0?n.preferredFormat:"jpg",supports:n.supports,quality:e.quality&&n.qualities.includes(e.quality)?e.quality:n.qualities.includes("native")?"native":"default",resolutions:Array.isArray(n.resolutions)?n.resolutions.sort(function(r,o){return o-r}):void 0,tileSize:n.tileSize}}}const zB=jB,it={IDLE:0,LOADING:1,LOADED:2,ERROR:3,EMPTY:4},Id={name:"rgb",min:[0,0,0],max:[255,255,255],channel:["red","green","blue"],alias:["RGB"]};var Ds={name:"xyz",min:[0,0,0],channel:["X","Y","Z"],alias:["XYZ","ciexyz","cie1931"]};Ds.whitepoint={2:{A:[109.85,100,35.585],C:[98.074,100,118.232],D50:[96.422,100,82.521],D55:[95.682,100,92.149],D65:[95.045592705167,100,108.9057750759878],D75:[94.972,100,122.638],F2:[99.187,100,67.395],F7:[95.044,100,108.755],F11:[100.966,100,64.37],E:[100,100,100]},10:{A:[111.144,100,35.2],C:[97.285,100,116.145],D50:[96.72,100,81.427],D55:[95.799,100,90.926],D65:[94.811,100,107.304],D75:[94.416,100,120.641],F2:[103.28,100,69.026],F7:[95.792,100,107.687],F11:[103.866,100,65.627],E:[100,100,100]}};Ds.max=Ds.whitepoint[2].D65;Ds.rgb=function(s,t){t=t||Ds.whitepoint[2].E;var e=s[0]/t[0],i=s[1]/t[1],n=s[2]/t[2],r,o,a;return r=e*3.240969941904521+i*-1.537383177570093+n*-.498610760293,o=e*-.96924363628087+i*1.87596750150772+n*.041555057407175,a=e*.055630079696993+i*-.20397695888897+n*1.056971514242878,r=r>.0031308?1.055*Math.pow(r,1/2.4)-.055:r=r*12.92,o=o>.0031308?1.055*Math.pow(o,1/2.4)-.055:o=o*12.92,a=a>.0031308?1.055*Math.pow(a,1/2.4)-.055:a=a*12.92,r=Math.min(Math.max(0,r),1),o=Math.min(Math.max(0,o),1),a=Math.min(Math.max(0,a),1),[r*255,o*255,a*255]};Id.xyz=function(s,t){var e=s[0]/255,i=s[1]/255,n=s[2]/255;e=e>.04045?Math.pow((e+.055)/1.055,2.4):e/12.92,i=i>.04045?Math.pow((i+.055)/1.055,2.4):i/12.92,n=n>.04045?Math.pow((n+.055)/1.055,2.4):n/12.92;var r=e*.41239079926595+i*.35758433938387+n*.18048078840183,o=e*.21263900587151+i*.71516867876775+n*.072192315360733,a=e*.019330818715591+i*.11919477979462+n*.95053215224966;return t=t||Ds.whitepoint[2].E,[r*t[0],o*t[1],a*t[2]]};const wv={name:"luv",min:[0,-134,-140],max:[100,224,122],channel:["lightness","u","v"],alias:["LUV","cieluv","cie1976"],xyz:function(s,t,e){var i,n,r,o,a,l,h,c,u,d,g,f,p;if(r=s[0],o=s[1],a=s[2],r===0)return[0,0,0];var m=.0011070564598794539;return t=t||"D65",e=e||2,u=Ds.whitepoint[e][t][0],d=Ds.whitepoint[e][t][1],g=Ds.whitepoint[e][t][2],f=4*u/(u+15*d+3*g),p=9*d/(u+15*d+3*g),i=o/(13*r)+f||0,n=a/(13*r)+p||0,h=r>8?d*Math.pow((r+16)/116,3):d*r*m,l=h*9*i/(4*n)||0,c=h*(12-3*i-20*n)/(4*n)||0,[l,h,c]}};Ds.luv=function(s,t,e){var i,n,r,o,a,l,h,c,u,d,g,f,p,m=.008856451679035631,_=903.2962962962961;t=t||"D65",e=e||2,u=Ds.whitepoint[e][t][0],d=Ds.whitepoint[e][t][1],g=Ds.whitepoint[e][t][2],f=4*u/(u+15*d+3*g),p=9*d/(u+15*d+3*g),l=s[0],h=s[1],c=s[2],i=4*l/(l+15*h+3*c)||0,n=9*h/(l+15*h+3*c)||0;var y=h/d;return r=y<=m?_*y:116*Math.pow(y,1/3)-16,o=13*r*(i-f),a=13*r*(n-p),[r,o,a]};var BI={name:"lchuv",channel:["lightness","chroma","hue"],alias:["LCHuv","cielchuv"],min:[0,0,0],max:[100,100,360],luv:function(s){var t=s[0],e=s[1],i=s[2],n,r,o;return o=i/360*2*Math.PI,n=e*Math.cos(o),r=e*Math.sin(o),[t,n,r]},xyz:function(s){return wv.xyz(BI.luv(s))}};wv.lchuv=function(s){var t=s[0],e=s[1],i=s[2],n=Math.sqrt(e*e+i*i),r=Math.atan2(i,e),o=r*360/2/Math.PI;return o<0&&(o+=360),[t,n,o]};Ds.lchuv=function(s){return wv.lchuv(Ds.luv(s))};const y2={aliceblue:[240,248,255],antiquewhite:[250,235,215],aqua:[0,255,255],aquamarine:[127,255,212],azure:[240,255,255],beige:[245,245,220],bisque:[255,228,196],black:[0,0,0],blanchedalmond:[255,235,205],blue:[0,0,255],blueviolet:[138,43,226],brown:[165,42,42],burlywood:[222,184,135],cadetblue:[95,158,160],chartreuse:[127,255,0],chocolate:[210,105,30],coral:[255,127,80],cornflowerblue:[100,149,237],cornsilk:[255,248,220],crimson:[220,20,60],cyan:[0,255,255],darkblue:[0,0,139],darkcyan:[0,139,139],darkgoldenrod:[184,134,11],darkgray:[169,169,169],darkgreen:[0,100,0],darkgrey:[169,169,169],darkkhaki:[189,183,107],darkmagenta:[139,0,139],darkolivegreen:[85,107,47],darkorange:[255,140,0],darkorchid:[153,50,204],darkred:[139,0,0],darksalmon:[233,150,122],darkseagreen:[143,188,143],darkslateblue:[72,61,139],darkslategray:[47,79,79],darkslategrey:[47,79,79],darkturquoise:[0,206,209],darkviolet:[148,0,211],deeppink:[255,20,147],deepskyblue:[0,191,255],dimgray:[105,105,105],dimgrey:[105,105,105],dodgerblue:[30,144,255],firebrick:[178,34,34],floralwhite:[255,250,240],forestgreen:[34,139,34],fuchsia:[255,0,255],gainsboro:[220,220,220],ghostwhite:[248,248,255],gold:[255,215,0],goldenrod:[218,165,32],gray:[128,128,128],green:[0,128,0],greenyellow:[173,255,47],grey:[128,128,128],honeydew:[240,255,240],hotpink:[255,105,180],indianred:[205,92,92],indigo:[75,0,130],ivory:[255,255,240],khaki:[240,230,140],lavender:[230,230,250],lavenderblush:[255,240,245],lawngreen:[124,252,0],lemonchiffon:[255,250,205],lightblue:[173,216,230],lightcoral:[240,128,128],lightcyan:[224,255,255],lightgoldenrodyellow:[250,250,210],lightgray:[211,211,211],lightgreen:[144,238,144],lightgrey:[211,211,211],lightpink:[255,182,193],lightsalmon:[255,160,122],lightseagreen:[32,178,170],lightskyblue:[135,206,250],lightslategray:[119,136,153],lightslategrey:[119,136,153],lightsteelblue:[176,196,222],lightyellow:[255,255,224],lime:[0,255,0],limegreen:[50,205,50],linen:[250,240,230],magenta:[255,0,255],maroon:[128,0,0],mediumaquamarine:[102,205,170],mediumblue:[0,0,205],mediumorchid:[186,85,211],mediumpurple:[147,112,219],mediumseagreen:[60,179,113],mediumslateblue:[123,104,238],mediumspringgreen:[0,250,154],mediumturquoise:[72,209,204],mediumvioletred:[199,21,133],midnightblue:[25,25,112],mintcream:[245,255,250],mistyrose:[255,228,225],moccasin:[255,228,181],navajowhite:[255,222,173],navy:[0,0,128],oldlace:[253,245,230],olive:[128,128,0],olivedrab:[107,142,35],orange:[255,165,0],orangered:[255,69,0],orchid:[218,112,214],palegoldenrod:[238,232,170],palegreen:[152,251,152],paleturquoise:[175,238,238],palevioletred:[219,112,147],papayawhip:[255,239,213],peachpuff:[255,218,185],peru:[205,133,63],pink:[255,192,203],plum:[221,160,221],powderblue:[176,224,230],purple:[128,0,128],rebeccapurple:[102,51,153],red:[255,0,0],rosybrown:[188,143,143],royalblue:[65,105,225],saddlebrown:[139,69,19],salmon:[250,128,114],sandybrown:[244,164,96],seagreen:[46,139,87],seashell:[255,245,238],sienna:[160,82,45],silver:[192,192,192],skyblue:[135,206,235],slateblue:[106,90,205],slategray:[112,128,144],slategrey:[112,128,144],snow:[255,250,250],springgreen:[0,255,127],steelblue:[70,130,180],tan:[210,180,140],teal:[0,128,128],thistle:[216,191,216],tomato:[255,99,71],turquoise:[64,224,208],violet:[238,130,238],wheat:[245,222,179],white:[255,255,255],whitesmoke:[245,245,245],yellow:[255,255,0],yellowgreen:[154,205,50]};var x2={red:0,orange:60,yellow:120,green:180,blue:240,purple:300};function UB(s){var t,e,i,n=[],r=1,o;if(typeof s=="number")return{space:"rgb",values:[s>>>16,(s&65280)>>>8,s&255],alpha:1};if(typeof s=="number")return{space:"rgb",values:[s>>>16,(s&65280)>>>8,s&255],alpha:1};if(s=String(s).toLowerCase(),y2[s])n=y2[s].slice(),o="rgb";else if(s==="transparent")r=0,o="rgb",n=[0,0,0];else if(s[0]==="#"){var a=s.slice(1),l=a.length,h=l<=4;r=1,h?(n=[parseInt(a[0]+a[0],16),parseInt(a[1]+a[1],16),parseInt(a[2]+a[2],16)],l===4&&(r=parseInt(a[3]+a[3],16)/255)):(n=[parseInt(a[0]+a[1],16),parseInt(a[2]+a[3],16),parseInt(a[4]+a[5],16)],l===8&&(r=parseInt(a[6]+a[7],16)/255)),n[0]||(n[0]=0),n[1]||(n[1]=0),n[2]||(n[2]=0),o="rgb"}else if(i=/^((?:rgba?|hs[lvb]a?|hwba?|cmyk?|xy[zy]|gray|lab|lchu?v?|[ly]uv|lms|oklch|oklab|color))\s*\(([^\)]*)\)/.exec(s)){var c=i[1];o=c.replace(/a$/,"");var u=o==="cmyk"?4:o==="gray"?1:3;n=i[2].trim().split(/\s*[,\/]\s*|\s+/),o==="color"&&(o=n.shift()),n=n.map(function(d,g){if(d[d.length-1]==="%")return d=parseFloat(d)/100,g===3?d:o==="rgb"?d*255:o[0]==="h"||o[0]==="l"&&!g?d*100:o==="lab"?d*125:o==="lch"?g<2?d*150:d*360:o[0]==="o"&&!g?d:o==="oklab"?d*.4:o==="oklch"?g<2?d*.4:d*360:d;if(o[g]==="h"||g===2&&o[o.length-1]==="h"){if(x2[d]!==void 0)return x2[d];if(d.endsWith("deg"))return parseFloat(d);if(d.endsWith("turn"))return parseFloat(d)*360;if(d.endsWith("grad"))return parseFloat(d)*360/400;if(d.endsWith("rad"))return parseFloat(d)*180/Math.PI}return d==="none"?0:parseFloat(d)}),r=n.length>u?n.pop():1}else/[0-9](?:\s|\/|,)/.test(s)&&(n=s.match(/([0-9]+)/g).map(function(d){return parseFloat(d)}),o=((e=(t=s.match(/([a-z])/ig))==null?void 0:t.join(""))==null?void 0:e.toLowerCase())||"rgb");return{space:o,values:n,alpha:r}}const x_={name:"hsl",min:[0,0,0],max:[360,100,100],channel:["hue","saturation","lightness"],alias:["HSL"],rgb:function(s){var t=s[0]/360,e=s[1]/100,i=s[2]/100,n,r,o,a,l,h=0;if(e===0)return l=i*255,[l,l,l];for(r=i<.5?i*(1+e):i+e-i*e,n=2*i-r,a=[0,0,0];h<3;)o=t+1/3*-(h-1),o<0?o++:o>1&&o--,l=6*o<1?n+(r-n)*6*o:2*o<1?r:3*o<2?n+(r-n)*(2/3-o)*6:n,a[h++]=l*255;return a}};Id.hsl=function(s){var t=s[0]/255,e=s[1]/255,i=s[2]/255,n=Math.min(t,e,i),r=Math.max(t,e,i),o=r-n,a,l,h;return r===n?a=0:t===r?a=(e-i)/o:e===r?a=2+(i-t)/o:i===r&&(a=4+(t-e)/o),a=Math.min(a*60,360),a<0&&(a+=360),h=(n+r)/2,r===n?l=0:h<=.5?l=o/(r+n):l=o/(2-r-n),[a,l*100,h*100]};function BB(s){Array.isArray(s)&&s.raw&&(s=String.raw(...arguments)),s instanceof Number&&(s=+s);var t,e=UB(s);if(!e.space)return[];const i=e.space[0]==="h"?x_.min:Id.min,n=e.space[0]==="h"?x_.max:Id.max;return t=Array(3),t[0]=Math.min(Math.max(e.values[0],i[0]),n[0]),t[1]=Math.min(Math.max(e.values[1],i[1]),n[1]),t[2]=Math.min(Math.max(e.values[2],i[2]),n[2]),e.space[0]==="h"&&(t=x_.rgb(t)),t.push(Math.min(Math.max(e.alpha,0),1)),t}function WB(s){return typeof s=="string"?s:Sv(s)}const XB=1024,eu={};let v_=0;function VB(s){if(s.length===4)return s;const t=s.slice();return t[3]=1,t}function v2(s){const t=Ds.lchuv(Id.xyz(s));return t[3]=s[3],t}function YB(s){const t=Ds.rgb(BI.xyz(s));return t[3]=s[3],t}function Ev(s){if(eu.hasOwnProperty(s))return eu[s];if(v_>=XB){let e=0;for(const i in eu)e++&3||(delete eu[i],--v_)}const t=BB(s);if(t.length!==4)throw new Error('failed to parse "'+s+'" as color');for(const e of t)if(isNaN(e))throw new Error('failed to parse "'+s+'" as color');return WI(t),eu[s]=t,++v_,t}function Bn(s){return Array.isArray(s)?s:Ev(s)}function WI(s){return s[0]=Dt(s[0]+.5|0,0,255),s[1]=Dt(s[1]+.5|0,0,255),s[2]=Dt(s[2]+.5|0,0,255),s[3]=Dt(s[3],0,1),s}function Sv(s){let t=s[0];t!=(t|0)&&(t=t+.5|0);let e=s[1];e!=(e|0)&&(e=e+.5|0);let i=s[2];i!=(i|0)&&(i=i+.5|0);const n=s[3]===void 0?1:Math.round(s[3]*1e3)/1e3;return"rgba("+t+","+e+","+i+","+n+")"}const ha=typeof navigator<"u"&&typeof navigator.userAgent<"u"?navigator.userAgent.toLowerCase():"";ha.includes("firefox");const qB=ha.includes("safari")&&!ha.includes("chrom"),ZB=qB&&(ha.includes("version/15.4")||/cpu (os|iphone os) 15_4 like mac os x/.test(ha));ha.includes("webkit")&&ha.includes("edge");ha.includes("macintosh");const XI=typeof WorkerGlobalScope<"u"&&typeof OffscreenCanvas<"u"&&self instanceof WorkerGlobalScope,Mv=typeof Image<"u"&&Image.prototype.decode,HB=typeof createImageBitmap=="function";(function(){let s=!1;try{const t=Object.defineProperty({},"passive",{get:function(){s=!0}});window.addEventListener("_",null,t),window.removeEventListener("_",null,t)}catch{}return s})();function Se(s,t,e,i){let n;return e&&e.length?n=e.shift():XI?n=new OffscreenCanvas(s||300,t||300):n=document.createElement("canvas"),s&&(n.width=s),t&&(n.height=t),n.getContext("2d",i)}let w_;function Pp(){return w_||(w_=Se(1,1)),w_}function ol(s){const t=s.canvas;t.width=1,t.height=1,s.clearRect(0,0,1,1)}class Wm extends fg{constructor(t,e,i,n){super(),this.extent=t,this.pixelRatio_=i,this.resolution=e,this.state=typeof n=="function"?it.IDLE:n,this.image_=null,this.loader=typeof n=="function"?n:null}changed(){this.dispatchEvent(Zt.CHANGE)}getExtent(){return this.extent}getImage(){return this.image_}getPixelRatio(){return this.pixelRatio_}getResolution(){return this.resolution}getState(){return this.state}load(){if(this.state==it.IDLE&&this.loader){this.state=it.LOADING,this.changed();const t=this.getResolution(),e=Array.isArray(t)?t[0]:t;lI(()=>this.loader(this.getExtent(),e,this.getPixelRatio())).then(i=>{"image"in i&&(this.image_=i.image),"extent"in i&&(this.extent=i.extent),"resolution"in i&&(this.resolution=i.resolution),"pixelRatio"in i&&(this.pixelRatio_=i.pixelRatio),(i instanceof HTMLImageElement||i instanceof ImageBitmap||i instanceof HTMLCanvasElement||i instanceof HTMLVideoElement)&&(this.image_=i),this.state=it.LOADED}).catch(i=>{this.state=it.ERROR,console.error(i)}).finally(()=>this.changed())}}setImage(t){this.image_=t}setResolution(t){this.resolution=t}}function KB(s,t,e){const i=s;let n=!0,r=!1,o=!1;const a=[bd(i,Zt.LOAD,function(){o=!0,r||t()})];return i.src&&Mv?(r=!0,i.decode().then(function(){n&&t()}).catch(function(l){n&&(o?t():e())})):a.push(bd(i,Zt.ERROR,e)),function(){n=!1,a.forEach(ms)}}function JB(s,t){return new Promise((e,i)=>{function n(){o(),e(s)}function r(){o(),i(new Error("Image load error"))}function o(){s.removeEventListener("load",n),s.removeEventListener("error",r)}s.addEventListener("load",n),s.addEventListener("error",r)})}function VI(s,t){return t&&(s.src=t),s.src&&Mv?new Promise((e,i)=>s.decode().then(()=>e(s)).catch(n=>s.complete&&s.width?e(s):i(n))):JB(s)}function pa(s,t){return t&&(s.src=t),s.src&&Mv&&HB?s.decode().then(()=>createImageBitmap(s)).catch(e=>{if(s.complete&&s.width)return s;throw e}):VI(s)}class QB{constructor(){this.cache_={},this.patternCache_={},this.cacheSize_=0,this.maxCacheSize_=32}clear(){this.cache_={},this.patternCache_={},this.cacheSize_=0}canExpireCache(){return this.cacheSize_>this.maxCacheSize_}expire(){if(this.canExpireCache()){let t=0;for(const e in this.cache_){const i=this.cache_[e];!(t++&3)&&!i.hasListener()&&(delete this.cache_[e],delete this.patternCache_[e],--this.cacheSize_)}}}get(t,e,i){const n=E_(t,e,i);return n in this.cache_?this.cache_[n]:null}getPattern(t,e,i){const n=E_(t,e,i);return n in this.patternCache_?this.patternCache_[n]:null}set(t,e,i,n,r){const o=E_(t,e,i),a=o in this.cache_;this.cache_[o]=n,r&&(n.getImageState()===it.IDLE&&n.load(),n.getImageState()===it.LOADING?n.ready().then(()=>{this.patternCache_[o]=Pp().createPattern(n.getImage(1),"repeat")}):this.patternCache_[o]=Pp().createPattern(n.getImage(1),"repeat")),a||++this.cacheSize_}setSize(t){this.maxCacheSize_=t,this.expire()}}function E_(s,t,e){const i=e?Bn(e):"null";return t+":"+s+":"+i}const Vo=new QB;let su=null;class tW extends fg{constructor(t,e,i,n,r){super(),this.hitDetectionImage_=null,this.image_=t,this.crossOrigin_=i,this.canvas_={},this.color_=r,this.imageState_=n===void 0?it.IDLE:n,this.size_=t&&t.width&&t.height?[t.width,t.height]:null,this.src_=e,this.tainted_,this.ready_=null}initializeImage_(){this.image_=new Image,this.crossOrigin_!==null&&(this.image_.crossOrigin=this.crossOrigin_)}isTainted_(){if(this.tainted_===void 0&&this.imageState_===it.LOADED){su||(su=Se(1,1,void 0,{willReadFrequently:!0})),su.drawImage(this.image_,0,0);try{su.getImageData(0,0,1,1),this.tainted_=!1}catch{su=null,this.tainted_=!0}}return this.tainted_===!0}dispatchChangeEvent_(){this.dispatchEvent(Zt.CHANGE)}handleImageError_(){this.imageState_=it.ERROR,this.dispatchChangeEvent_()}handleImageLoad_(){this.imageState_=it.LOADED,this.size_=[this.image_.width,this.image_.height],this.dispatchChangeEvent_()}getImage(t){return this.image_||this.initializeImage_(),this.replaceColor_(t),this.canvas_[t]?this.canvas_[t]:this.image_}getPixelRatio(t){return this.replaceColor_(t),this.canvas_[t]?t:1}getImageState(){return this.imageState_}getHitDetectionImage(){if(this.image_||this.initializeImage_(),!this.hitDetectionImage_)if(this.isTainted_()){const t=this.size_[0],e=this.size_[1],i=Se(t,e);i.fillRect(0,0,t,e),this.hitDetectionImage_=i.canvas}else this.hitDetectionImage_=this.image_;return this.hitDetectionImage_}getSize(){return this.size_}getSrc(){return this.src_}load(){if(this.imageState_===it.IDLE){this.image_||this.initializeImage_(),this.imageState_=it.LOADING;try{this.src_!==void 0&&(this.image_.src=this.src_)}catch{this.handleImageError_()}this.image_ instanceof HTMLImageElement&&VI(this.image_,this.src_).then(t=>{this.image_=t,this.handleImageLoad_()}).catch(this.handleImageError_.bind(this))}}replaceColor_(t){if(!this.color_||this.canvas_[t]||this.imageState_!==it.LOADED)return;const e=this.image_,i=document.createElement("canvas");i.width=Math.ceil(e.width*t),i.height=Math.ceil(e.height*t);const n=i.getContext("2d");n.scale(t,t),n.drawImage(e,0,0),n.globalCompositeOperation="multiply",n.fillStyle=WB(this.color_),n.fillRect(0,0,i.width/t,i.height/t),n.globalCompositeOperation="destination-in",n.drawImage(e,0,0),this.canvas_[t]=i}ready(){return this.ready_||(this.ready_=new Promise(t=>{if(this.imageState_===it.LOADED||this.imageState_===it.ERROR)t();else{const e=()=>{(this.imageState_===it.LOADED||this.imageState_===it.ERROR)&&(this.removeEventListener(Zt.CHANGE,e),t())};this.addEventListener(Zt.CHANGE,e)}})),this.ready_}}function bv(s,t,e,i,n,r){let o=t===void 0?void 0:Vo.get(t,e,n);return o||(o=new tW(s,s&&"src"in s?s.src||void 0:t,e,i,n),Vo.set(t,e,n,o,r)),r&&o&&!Vo.getPattern(t,e,n)&&Vo.set(t,e,n,o,r),o}class Wn{constructor(t){t=t||{},this.patternImage_=null,this.color_=null,t.color!==void 0&&this.setColor(t.color)}clone(){const t=this.getColor();return new Wn({color:Array.isArray(t)?t.slice():t||void 0})}getColor(){return this.color_}setColor(t){if(t!==null&&typeof t=="object"&&"src"in t){const e=bv(null,t.src,"anonymous",void 0,t.offset?null:t.color?t.color:null,!(t.offset&&t.size));e.ready().then(()=>{this.patternImage_=null}),e.getImageState()===it.IDLE&&e.load(),e.getImageState()===it.LOADING&&(this.patternImage_=e)}this.color_=t}loading(){return!!this.patternImage_}ready(){return this.patternImage_?this.patternImage_.ready():Promise.resolve()}}function YI(s,t,e){return e===void 0&&(e=[0,0]),e[0]=s[0]*t+.5|0,e[1]=s[1]*t+.5|0,e}function Re(s,t){return Array.isArray(s)?s:(t===void 0?t=[s,s]:(t[0]=s,t[1]=s),t)}class Xm{constructor(t){this.opacity_=t.opacity,this.rotateWithView_=t.rotateWithView,this.rotation_=t.rotation,this.scale_=t.scale,this.scaleArray_=Re(t.scale),this.displacement_=t.displacement,this.declutterMode_=t.declutterMode}clone(){const t=this.getScale();return new Xm({opacity:this.getOpacity(),scale:Array.isArray(t)?t.slice():t,rotation:this.getRotation(),rotateWithView:this.getRotateWithView(),displacement:this.getDisplacement().slice(),declutterMode:this.getDeclutterMode()})}getOpacity(){return this.opacity_}getRotateWithView(){return this.rotateWithView_}getRotation(){return this.rotation_}getScale(){return this.scale_}getScaleArray(){return this.scaleArray_}getDisplacement(){return this.displacement_}getDeclutterMode(){return this.declutterMode_}getAnchor(){return vt()}getImage(t){return vt()}getHitDetectionImage(){return vt()}getPixelRatio(t){return 1}getImageState(){return vt()}getImageSize(){return vt()}getOrigin(){return vt()}getSize(){return vt()}setDisplacement(t){this.displacement_=t}setOpacity(t){this.opacity_=t}setRotateWithView(t){this.rotateWithView_=t}setRotation(t){this.rotation_=t}setScale(t){this.scale_=t,this.scaleArray_=Re(t)}listenImageChange(t){vt()}load(){vt()}unlistenImageChange(t){vt()}ready(){return Promise.resolve()}}function w2(s,t,e,i){return e!==void 0&&i!==void 0?[e/s,i/t]:e!==void 0?e/s:i!==void 0?i/t:1}class Rc extends Xm{constructor(t){t=t||{};const e=t.opacity!==void 0?t.opacity:1,i=t.rotation!==void 0?t.rotation:0,n=t.scale!==void 0?t.scale:1,r=t.rotateWithView!==void 0?t.rotateWithView:!1;super({opacity:e,rotation:i,scale:n,displacement:t.displacement!==void 0?t.displacement:[0,0],rotateWithView:r,declutterMode:t.declutterMode}),this.anchor_=t.anchor!==void 0?t.anchor:[.5,.5],this.normalizedAnchor_=null,this.anchorOrigin_=t.anchorOrigin!==void 0?t.anchorOrigin:"top-left",this.anchorXUnits_=t.anchorXUnits!==void 0?t.anchorXUnits:"fraction",this.anchorYUnits_=t.anchorYUnits!==void 0?t.anchorYUnits:"fraction",this.crossOrigin_=t.crossOrigin!==void 0?t.crossOrigin:null;const o=t.img!==void 0?t.img:null;let a=t.src;qt(!(a!==void 0&&o),"`image` and `src` cannot be provided at the same time"),(a===void 0||a.length===0)&&o&&(a=o.src||mt(o)),qt(a!==void 0&&a.length>0,"A defined and non-empty `src` or `image` must be provided"),qt(!((t.width!==void 0||t.height!==void 0)&&t.scale!==void 0),"`width` or `height` cannot be provided together with `scale`");let l;if(t.src!==void 0?l=it.IDLE:o!==void 0&&("complete"in o?o.complete?l=o.src?it.LOADED:it.IDLE:l=it.LOADING:l=it.LOADED),this.color_=t.color!==void 0?Bn(t.color):null,this.iconImage_=bv(o,a,this.crossOrigin_,l,this.color_),this.offset_=t.offset!==void 0?t.offset:[0,0],this.offsetOrigin_=t.offsetOrigin!==void 0?t.offsetOrigin:"top-left",this.origin_=null,this.size_=t.size!==void 0?t.size:null,this.initialOptions_,t.width!==void 0||t.height!==void 0){let h,c;if(t.size)[h,c]=t.size;else{const u=this.getImage(1);if(u.width&&u.height)h=u.width,c=u.height;else if(u instanceof HTMLImageElement){this.initialOptions_=t;const d=()=>{if(this.unlistenImageChange(d),!this.initialOptions_)return;const g=this.iconImage_.getSize();this.setScale(w2(g[0],g[1],t.width,t.height))};this.listenImageChange(d);return}}h!==void 0&&this.setScale(w2(h,c,t.width,t.height))}}clone(){let t,e,i;return this.initialOptions_?(e=this.initialOptions_.width,i=this.initialOptions_.height):(t=this.getScale(),t=Array.isArray(t)?t.slice():t),new Rc({anchor:this.anchor_.slice(),anchorOrigin:this.anchorOrigin_,anchorXUnits:this.anchorXUnits_,anchorYUnits:this.anchorYUnits_,color:this.color_&&this.color_.slice?this.color_.slice():this.color_||void 0,crossOrigin:this.crossOrigin_,offset:this.offset_.slice(),offsetOrigin:this.offsetOrigin_,opacity:this.getOpacity(),rotateWithView:this.getRotateWithView(),rotation:this.getRotation(),scale:t,width:e,height:i,size:this.size_!==null?this.size_.slice():void 0,src:this.getSrc(),displacement:this.getDisplacement().slice(),declutterMode:this.getDeclutterMode()})}getAnchor(){let t=this.normalizedAnchor_;if(!t){t=this.anchor_;const n=this.getSize();if(this.anchorXUnits_=="fraction"||this.anchorYUnits_=="fraction"){if(!n)return null;t=this.anchor_.slice(),this.anchorXUnits_=="fraction"&&(t[0]*=n[0]),this.anchorYUnits_=="fraction"&&(t[1]*=n[1])}if(this.anchorOrigin_!="top-left"){if(!n)return null;t===this.anchor_&&(t=this.anchor_.slice()),(this.anchorOrigin_=="top-right"||this.anchorOrigin_=="bottom-right")&&(t[0]=-t[0]+n[0]),(this.anchorOrigin_=="bottom-left"||this.anchorOrigin_=="bottom-right")&&(t[1]=-t[1]+n[1])}this.normalizedAnchor_=t}const e=this.getDisplacement(),i=this.getScaleArray();return[t[0]-e[0]/i[0],t[1]+e[1]/i[1]]}setAnchor(t){this.anchor_=t,this.normalizedAnchor_=null}getColor(){return this.color_}getImage(t){return this.iconImage_.getImage(t)}getPixelRatio(t){return this.iconImage_.getPixelRatio(t)}getImageSize(){return this.iconImage_.getSize()}getImageState(){return this.iconImage_.getImageState()}getHitDetectionImage(){return this.iconImage_.getHitDetectionImage()}getOrigin(){if(this.origin_)return this.origin_;let t=this.offset_;if(this.offsetOrigin_!="top-left"){const e=this.getSize(),i=this.iconImage_.getSize();if(!e||!i)return null;t=t.slice(),(this.offsetOrigin_=="top-right"||this.offsetOrigin_=="bottom-right")&&(t[0]=i[0]-e[0]-t[0]),(this.offsetOrigin_=="bottom-left"||this.offsetOrigin_=="bottom-right")&&(t[1]=i[1]-e[1]-t[1])}return this.origin_=t,this.origin_}getSrc(){return this.iconImage_.getSrc()}getSize(){return this.size_?this.size_:this.iconImage_.getSize()}getWidth(){const t=this.getScaleArray();if(this.size_)return this.size_[0]*t[0];if(this.iconImage_.getImageState()==it.LOADED)return this.iconImage_.getSize()[0]*t[0]}getHeight(){const t=this.getScaleArray();if(this.size_)return this.size_[1]*t[1];if(this.iconImage_.getImageState()==it.LOADED)return this.iconImage_.getSize()[1]*t[1]}setScale(t){delete this.initialOptions_,super.setScale(t)}listenImageChange(t){this.iconImage_.addEventListener(Zt.CHANGE,t)}load(){this.iconImage_.load()}unlistenImageChange(t){this.iconImage_.removeEventListener(Zt.CHANGE,t)}ready(){return this.iconImage_.ready()}}class wn{constructor(t){t=t||{},this.color_=t.color!==void 0?t.color:null,this.lineCap_=t.lineCap,this.lineDash_=t.lineDash!==void 0?t.lineDash:null,this.lineDashOffset_=t.lineDashOffset,this.lineJoin_=t.lineJoin,this.miterLimit_=t.miterLimit,this.width_=t.width}clone(){const t=this.getColor();return new wn({color:Array.isArray(t)?t.slice():t||void 0,lineCap:this.getLineCap(),lineDash:this.getLineDash()?this.getLineDash().slice():void 0,lineDashOffset:this.getLineDashOffset(),lineJoin:this.getLineJoin(),miterLimit:this.getMiterLimit(),width:this.getWidth()})}getColor(){return this.color_}getLineCap(){return this.lineCap_}getLineDash(){return this.lineDash_}getLineDashOffset(){return this.lineDashOffset_}getLineJoin(){return this.lineJoin_}getMiterLimit(){return this.miterLimit_}getWidth(){return this.width_}setColor(t){this.color_=t}setLineCap(t){this.lineCap_=t}setLineDash(t){this.lineDash_=t}setLineDashOffset(t){this.lineDashOffset_=t}setLineJoin(t){this.lineJoin_=t}setMiterLimit(t){this.miterLimit_=t}setWidth(t){this.width_=t}}function hr(s){return s?Array.isArray(s)?Sv(s):typeof s=="object"&&"src"in s?eW(s):s:null}function eW(s){if(!s.offset||!s.size)return Vo.getPattern(s.src,"anonymous",s.color);const t=s.src+":"+s.offset,e=Vo.getPattern(t,void 0,s.color);if(e)return e;const i=Vo.get(s.src,"anonymous",null);if(i.getImageState()!==it.LOADED)return null;const n=Se(s.size[0],s.size[1]);return n.drawImage(i.getImage(1),s.offset[0],s.offset[1],s.size[0],s.size[1],0,0,s.size[0],s.size[1]),bv(n.canvas,t,void 0,it.LOADED,s.color,!0),Vo.getPattern(t,void 0,s.color)}const sW=new RegExp(["^\\s*(?=(?:(?:[-a-z]+\\s*){0,2}(italic|oblique))?)","(?=(?:(?:[-a-z]+\\s*){0,2}(small-caps))?)","(?=(?:(?:[-a-z]+\\s*){0,2}(bold(?:er)?|lighter|[1-9]00 ))?)","(?:(?:normal|\\1|\\2|\\3)\\s*){0,3}((?:xx?-)?","(?:small|large)|medium|smaller|larger|[\\.\\d]+(?:\\%|in|[cem]m|ex|p[ctx]))","(?:\\s*\\/\\s*(normal|[\\.\\d]+(?:\\%|in|[cem]m|ex|p[ctx])?))",`?\\s*([-,\\"\\'\\sa-z]+?)\\s*$`].join(""),"i"),E2=["style","variant","weight","size","lineHeight","family"],qI=function(s){const t=s.match(sW);if(!t)return null;const e={lineHeight:"normal",size:"1.2em",style:"normal",weight:"normal",variant:"normal"};for(let i=0,n=E2.length;i{t.target.getView().setCenter(this.center)}),this.map.setTarget(this.renderRoot.querySelector("div")),this._zoomExtent?this.map.getView().fit(this._zoomExtent,this.animationOptions):this._animateToState(),this.map.on("loadend",()=>{this.dispatchEvent(new CustomEvent("loadend",{detail:this.map}))}),this.dispatchEvent(new CustomEvent("mapmounted",{detail:this.map}))}updated(t){}};qn([Er({attribute:!1,type:Array})],yn.prototype,"center",1);qn([Er({attribute:!1,type:Array})],yn.prototype,"layers",1);qn([Er({attribute:"prevent-scroll",type:Boolean})],yn.prototype,"preventScroll",1);qn([Er({attribute:!1,type:Object})],yn.prototype,"config",1);qn([Er({attribute:"projection",type:String})],yn.prototype,"projection",1);qn([Er()],yn.prototype,"sync",1);qn([hm()],yn.prototype,"map",2);qn([hm()],yn.prototype,"interactions",2);qn([hm()],yn.prototype,"selectInteractions",2);qn([hm()],yn.prototype,"mapControls",2);yn=qn([DF("eox-map")],yn);var XU=Object.defineProperty,VU=(s,t,e)=>t in s?XU(s,t,{enumerable:!0,configurable:!0,writable:!0,value:e}):s[t]=e,jx=(s,t,e)=>VU(s,typeof t!="symbol"?t+"":t,e);class Sr{constructor(t){this.propagationStopped,this.defaultPrevented,this.type=t,this.target=null}preventDefault(){this.defaultPrevented=!0}stopPropagation(){this.propagationStopped=!0}}const zx={PROPERTYCHANGE:"propertychange"};class Ux{constructor(){this.disposed=!1}dispose(){this.disposed||(this.disposed=!0,this.disposeInternal())}disposeInternal(){}}function YU(s,t,e){let i,n;e=e||fr;let r=0,o=s.length,a=!1;for(;r>1),n=+e(s[i],t),n<0?r=i+1:(o=i,a=!n);return a?r:~r}function fr(s,t){return s>t?1:st?-1:0}function Om(s,t,e){if(s[0]<=t)return 0;const i=s.length;if(t<=s[i-1])return i-1;if(typeof e=="function"){for(let n=1;n0?n-1:n}return i-1}if(e>0){for(let n=1;n0||o===0)})}function KU(){return!0}function Md(){}function aI(s){let t,e,i;return function(){const n=Array.prototype.slice.call(arguments);return(!e||this!==i||!vl(n,e))&&(i=this,e=n,t=s.apply(this,arguments)),t}}function lI(s){function t(){let e;try{e=s()}catch(i){return Promise.reject(i)}return e instanceof Promise?e:Promise.resolve(e)}return t()}function Mc(s){for(const t in s)delete s[t]}function eo(s){let t;for(t in s)return!1;return!t}class fg extends Ux{constructor(t){super(),this.eventTarget_=t,this.pendingRemovals_=null,this.dispatching_=null,this.listeners_=null}addEventListener(t,e){if(!t||!e)return;const i=this.listeners_||(this.listeners_={}),n=i[t]||(i[t]=[]);n.includes(e)||n.push(e)}dispatchEvent(t){const e=typeof t=="string",i=e?t:t.type,n=this.listeners_&&this.listeners_[i];if(!n)return;const r=e?new Sr(t):t;r.target||(r.target=this.eventTarget_||this);const o=this.dispatching_||(this.dispatching_={}),a=this.pendingRemovals_||(this.pendingRemovals_={});i in o||(o[i]=0,a[i]=0),++o[i];let l;for(let h=0,c=n.length;h0:!1}removeEventListener(t,e){if(!this.listeners_)return;const i=this.listeners_[t];if(!i)return;const n=i.indexOf(e);n!==-1&&(this.pendingRemovals_&&t in this.pendingRemovals_?(i[n]=Md,++this.pendingRemovals_[t]):(i.splice(n,1),i.length===0&&delete this.listeners_[t]))}}const Zt={CHANGE:"change",ERROR:"error",BLUR:"blur",CLEAR:"clear",CONTEXTMENU:"contextmenu",CLICK:"click",DBLCLICK:"dblclick",DRAGENTER:"dragenter",DRAGOVER:"dragover",DROP:"drop",FOCUS:"focus",KEYDOWN:"keydown",KEYPRESS:"keypress",LOAD:"load",RESIZE:"resize",TOUCHMOVE:"touchmove",WHEEL:"wheel"};function We(s,t,e,i,n){if(n){const o=e;e=function(){s.removeEventListener(t,e),o.apply(i??this,arguments)}}else i&&i!==s&&(e=e.bind(i));const r={target:s,type:t,listener:e};return s.addEventListener(t,e),r}function bd(s,t,e,i){return We(s,t,e,i,!0)}function ms(s){s&&s.target&&(s.target.removeEventListener(s.type,s.listener),Mc(s))}class pg extends fg{constructor(){super(),this.on=this.onInternal,this.once=this.onceInternal,this.un=this.unInternal,this.revision_=0}changed(){++this.revision_,this.dispatchEvent(Zt.CHANGE)}getRevision(){return this.revision_}onInternal(t,e){if(Array.isArray(t)){const i=t.length,n=new Array(i);for(let r=0;rMath.round(t*t2[e])/t2[e]).join(", ")+")"}const Ss={UNKNOWN:0,INTERSECTING:1,ABOVE:2,RIGHT:4,BELOW:8,LEFT:16};function ic(s){const t=Zs();for(let e=0,i=s.length;en&&(l=l|Ss.RIGHT),ar&&(l=l|Ss.ABOVE),l===Ss.UNKNOWN&&(l=Ss.INTERSECTING),l}function Zs(){return[1/0,1/0,-1/0,-1/0]}function Un(s,t,e,i,n){return n?(n[0]=s,n[1]=t,n[2]=e,n[3]=i,n):[s,t,e,i]}function mg(s){return Un(1/0,1/0,-1/0,-1/0,s)}function Vx(s,t){const e=s[0],i=s[1];return Un(e,i,e,i,t)}function Yx(s,t,e,i,n){const r=mg(n);return uI(r,s,t,e,i)}function so(s,t){return s[0]==t[0]&&s[2]==t[2]&&s[1]==t[1]&&s[3]==t[3]}function a9(s,t,e){return Math.abs(s[0]-t[0])s[2]&&(s[2]=t[2]),t[1]s[3]&&(s[3]=t[3]),s}function Wu(s,t){t[0]s[2]&&(s[2]=t[0]),t[1]s[3]&&(s[3]=t[1])}function uI(s,t,e,i,n){for(;et[0]?i[0]=s[0]:i[0]=t[0],s[1]>t[1]?i[1]=s[1]:i[1]=t[1],s[2]=t[0]&&s[1]<=t[3]&&s[3]>=t[1]}function po(s){return s[2]=o&&p<=l),!i&&r&Ss.RIGHT&&!(n&Ss.RIGHT)&&(m=g-(d-l)*f,i=m>=a&&m<=h),!i&&r&Ss.BELOW&&!(n&Ss.BELOW)&&(p=d-(g-a)/f,i=p>=o&&p<=l),!i&&r&Ss.LEFT&&!(n&Ss.LEFT)&&(m=g-(d-o)*f,i=m>=a&&m<=h)}return i}function nc(s,t,e,i){if(po(s))return mg(e);let n=[];if(i>1){const a=s[2]-s[0],l=s[3]-s[1];for(let h=0;h=e[2])){const n=Rt(e),r=Math.floor((i[0]-e[0])/n)*n;s[0]-=r,s[2]-=r}return s}function Hx(s,t,e){if(t.canWrapX()){const i=t.getExtent();if(!isFinite(s[0])||!isFinite(s[2]))return[[i[0],s[1],i[2],s[3]]];Zx(s,t);const n=Rt(i);if(Rt(s)>n&&!e)return[[i[0],s[1],i[2],s[3]]];if(s[0]i[2])return[[s[0],s[1],i[2],s[3]],[i[0],s[1],s[2]-n,s[3]]]}return[s]}const g9={9001:"m",9002:"ft",9003:"us-ft",9101:"radians",9102:"degrees"};function e2(s){return g9[s]}const Kx={radians:6370997/(2*Math.PI),degrees:2*Math.PI*6370997/360,ft:.3048,m:1,"us-ft":1200/3937};let rc=class{constructor(s){this.code_=s.code,this.units_=s.units,this.extent_=s.extent!==void 0?s.extent:null,this.worldExtent_=s.worldExtent!==void 0?s.worldExtent:null,this.axisOrientation_=s.axisOrientation!==void 0?s.axisOrientation:"enu",this.global_=s.global!==void 0?s.global:!1,this.canWrapX_=!!(this.global_&&this.extent_),this.getPointResolutionFunc_=s.getPointResolution,this.defaultTileGrid_=null,this.metersPerUnit_=s.metersPerUnit}canWrapX(){return this.canWrapX_}getCode(){return this.code_}getExtent(){return this.extent_}getUnits(){return this.units_}getMetersPerUnit(){return this.metersPerUnit_||Kx[this.units_]}getWorldExtent(){return this.worldExtent_}getAxisOrientation(){return this.axisOrientation_}isGlobal(){return this.global_}setGlobal(s){this.global_=s,this.canWrapX_=!!(s&&this.extent_)}getDefaultTileGrid(){return this.defaultTileGrid_}setDefaultTileGrid(s){this.defaultTileGrid_=s}setExtent(s){this.extent_=s,this.canWrapX_=!!(this.global_&&s)}setWorldExtent(s){this.worldExtent_=s}setGetPointResolution(s){this.getPointResolutionFunc_=s}getPointResolutionFunc(){return this.getPointResolutionFunc_}};const xg=6378137,gh=Math.PI*xg,f9=[-gh,-gh,gh,gh],p9=[-180,-85,180,85],df=xg*Math.log(Math.tan(Math.PI/2));class Fl extends rc{constructor(t){super({code:t,units:"m",extent:f9,global:!0,worldExtent:p9,getPointResolution:function(e,i){return e/Math.cosh(i[1]/xg)}})}}const s2=[new Fl("EPSG:3857"),new Fl("EPSG:102100"),new Fl("EPSG:102113"),new Fl("EPSG:900913"),new Fl("http://www.opengis.net/def/crs/EPSG/0/3857"),new Fl("http://www.opengis.net/gml/srs/epsg.xml#3857")];function m9(s,t,e){const i=s.length;e=e>1?e:2,t===void 0&&(e>2?t=s.slice():t=new Array(i));for(let n=0;ndf?r=df:r<-df&&(r=-df),t[n+1]=r}return t}function _9(s,t,e){const i=s.length;e=e>1?e:2,t===void 0&&(e>2?t=s.slice():t=new Array(i));for(let n=0;n1?(e=n,i=r):l>0&&(e+=o*l,i+=a*l)}return Xa(s,t,e,i)}function Xa(s,t,e,i){const n=e-s,r=i-t;return n*n+r*r}function E9(s){const t=s.length;for(let i=0;ir&&(r=l,n=a)}if(r===0)return null;const o=s[n];s[n]=s[i],s[i]=o;for(let a=i+1;a=0;i--){e[i]=s[i][t]/s[i][i];for(let n=i-1;n>=0;n--)s[n][t]-=s[n][i]*e[i]}return e}function Xu(s){return s*Math.PI/180}function kn(s,t){const e=s%t;return e*t<0?e+t:e}function Ui(s,t,e){return s+e*(t-s)}function vg(s,t){const e=Math.pow(10,t);return Math.round(s*e)/e}function Mp(s,t){return Math.round(vg(s,t))}function fh(s,t){return Math.floor(vg(s,t))}function Xo(s,t){return Math.ceil(vg(s,t))}function Oa(s,t,e){const i=e!==void 0?s.toFixed(e):""+s;let n=i.indexOf(".");return n=n===-1?i.length:n,n>t?i:new Array(1+t-n).join("0")+i}function Jx(s,t){const e=(""+s).split("."),i=(""+t).split(".");for(let n=0;no)return 1;if(o>r)return-1}return 0}function mI(s,t){return s[0]+=+t[0],s[1]+=+t[1],s}function r2(s,t,e){const i=kn(t+180,360)-180,n=Math.abs(3600*i),r=e||0;let o=Math.floor(n/3600),a=Math.floor((n-o*3600)/60),l=vg(n-o*3600-a*60,r);l>=60&&(l=0,a+=1),a>=60&&(a=0,o+=1);let h=o+"°";return(a!==0||l!==0)&&(h+=" "+Oa(a,2)+"′"),l!==0&&(h+=" "+Oa(l,2,r)+"″"),i!==0&&(h+=" "+s.charAt(i<0?1:0)),h}function bp(s,t){let e=!0;for(let i=s.length-1;i>=0;--i)if(s[i]!=t[i]){e=!1;break}return e}function S9(s,t){const e=Math.cos(t),i=Math.sin(t),n=s[0]*e-s[1]*i,r=s[1]*e+s[0]*i;return s[0]=n,s[1]=r,s}function M9(s,t){return s[0]*=t,s[1]*=t,s}function _I(s,t){if(t.canWrapX()){const e=Rt(t.getExtent()),i=yI(s,t,e);i&&(s[0]-=i*e)}return s}function yI(s,t,e){const i=t.getExtent();let n=0;return t.canWrapX()&&(s[0]i[2])&&(e=e||Rt(i),n=Math.floor((s[0]-i[0])/e)),n}const b9=63710088e-1;function o2(s,t,e){e=e||b9;const i=Xu(s[1]),n=Xu(t[1]),r=(n-i)/2,o=Xu(t[0]-s[0])/2,a=Math.sin(r)*Math.sin(r)+Math.sin(o)*Math.sin(o)*Math.cos(i)*Math.cos(n);return 2*e*Math.atan2(Math.sqrt(a),Math.sqrt(1-a))}function C9(...s){console.warn(...s)}function Td(...s){console.error(...s)}let B1=!0;function T9(s){B1=!1}function Qx(s,t){if(t!==void 0){for(let e=0,i=s.length;e=a?t[r+l]:o[l]}return e}}function P9(s,t,e,i){const n=st(s),r=st(t);oc(n,r,l2(e)),oc(r,n,l2(i))}function h2(s,t){const e=Dm(s,t!==void 0?t:"EPSG:3857","EPSG:4326"),i=e[0];return(i<-180||i>180)&&(e[0]=kn(i+180,360)-180),e}function qs(s,t){if(s===t)return!0;const e=s.getUnits()===t.getUnits();return(s.getCode()===t.getCode()||Sl(s,t)===Qx)&&e}function Sl(s,t){const e=s.getCode(),i=t.getCode();let n=fI(e,i);return n||(n=xI),n}function vr(s,t){const e=st(s),i=st(t);return Sl(e,i)}function Dm(s,t,e){return vr(t,e)(s,void 0,s.length)}function ev(s,t,e,i){const n=vr(t,e);return nc(s,n,void 0,i)}let A9=null;function L9(){return A9}function X1(s,t){return s}function bo(s,t){return B1&&!bp(s,[0,0])&&s[0]>=-180&&s[0]<=180&&s[1]>=-90&&s[1]<=90&&(B1=!1,C9("Call useGeographic() from ol/proj once to work with [longitude, latitude] coordinates.")),s}function km(s,t){return s}function cn(s,t){return s}function c2(s,t,e){return function(i){let n,r;if(s.canWrapX()){const o=s.getExtent(),a=Rt(o);i=i.slice(0),r=yI(i,s,a),r&&(i[0]=i[0]-r*a),i[0]=Dt(i[0],o[0],o[2]),i[1]=Dt(i[1],o[1],o[3]),n=e(i)}else n=e(i);return r&&t.canWrapX()&&(n[0]+=r*Rt(t.getExtent())),n}}function O9(){W1(s2),W1(n2),I9(n2,s2,m9,_9)}O9();function Jo(s,t,e,i,n,r){r=r||[];let o=0;for(let a=t;a{if(!i)return this.getSimplifiedGeometry(e);const n=this.clone();return n.applyTransform(i),n.getSimplifiedGeometry(e)})}simplifyTransformed(t,e){return this.simplifyTransformedInternal(this.getRevision(),t,e)}clone(){return vt()}closestPointXY(t,e,i,n){return vt()}containsXY(t,e){const i=this.getClosestPoint([t,e]);return i[0]===t&&i[1]===e}getClosestPoint(t,e){return e=e||[NaN,NaN],this.closestPointXY(t[0],t[1],e,1/0),e}intersectsCoordinate(t){return this.containsXY(t[0],t[1])}computeExtent(t){return vt()}getExtent(t){if(this.extentRevision_!=this.getRevision()){const e=this.computeExtent(this.extent_);(isNaN(e[0])||isNaN(e[1]))&&mg(e),this.extentRevision_=this.getRevision()}return u9(this.extent_,t)}rotate(t,e){vt()}scale(t,e,i){vt()}simplify(t){return this.getSimplifiedGeometry(t*t)}getSimplifiedGeometry(t){return vt()}getType(){return vt()}applyTransform(t){vt()}intersectsExtent(t){return vt()}translate(t,e){vt()}transform(t,e){const i=st(t),n=i.getUnits()=="tile-pixels"?function(r,o,a){const l=i.getExtent(),h=i.getWorldExtent(),c=Ee(h)/Ee(l);return xn(u2,h[0],h[3],c,-c,0,0,0),Jo(r,0,r.length,a,u2,o),vr(i,e)(r,o,a)}:vr(i,e);return this.applyTransform(n),this}}class D9 extends sv{constructor(){super(),this.layout="XY",this.stride=2,this.flatCoordinates}computeExtent(t){return Yx(this.flatCoordinates,0,this.flatCoordinates.length,this.stride,t)}getCoordinates(){return vt()}getFirstCoordinate(){return this.flatCoordinates.slice(0,this.stride)}getFlatCoordinates(){return this.flatCoordinates}getLastCoordinate(){return this.flatCoordinates.slice(this.flatCoordinates.length-this.stride)}getLayout(){return this.layout}getSimplifiedGeometry(t){if(this.simplifiedGeometryRevision!==this.getRevision()&&(this.simplifiedGeometryMaxMinSquaredTolerance=0,this.simplifiedGeometryRevision=this.getRevision()),t<0||this.simplifiedGeometryMaxMinSquaredTolerance!==0&&t<=this.simplifiedGeometryMaxMinSquaredTolerance)return this;const e=this.getSimplifiedGeometryInternal(t);return e.getFlatCoordinates().lengtht.clone())}function d2(s,t,e,i,n,r,o){const a=s[t],l=s[t+1],h=s[e]-a,c=s[e+1]-l;let u;if(h===0&&c===0)u=t;else{const d=((n-a)*h+(r-l)*c)/(h*h+c*c);if(d>1)u=e;else if(d>0){for(let g=0;gn&&(n=h),r=a,o=l}return n}function nv(s,t,e,i,n){for(let r=0,o=e.length;r0;){const u=h.pop(),d=h.pop();let g=0;const f=s[d],p=s[d+1],m=s[u],_=s[u+1];for(let y=d+i;yg&&(c=y,g=w)}g>n&&(l[(c-t)/i]=1,d+i0&&p>g)&&(f<0&&m0&&m>f)){h=u,c=d;continue}r[o++]=h,r[o++]=c,a=h,l=c,h=u,c=d}return r[o++]=h,r[o++]=c,o}function av(s,t,e,i,n,r,o,a){for(let l=0,h=e.length;l1?o:2,r=r||new Array(o);for(let c=0;c>1;nr&&(h-a)*(r-l)-(n-a)*(c-l)>0&&o++:c<=r&&(h-a)*(r-l)-(n-a)*(c-l)<0&&o--,a=h,l=c}return o!==0}function lv(s,t,e,i,n,r){if(e.length===0||!ja(s,t,e[0],i,n,r))return!1;for(let o=1,a=e.length;o=n[0]&&r[2]<=n[2]||r[1]>=n[1]&&r[3]<=n[3]?!0:CI(s,t,e,i,function(o,a){return d9(n,o,a)}):!1}function Y9(s,t,e,i,n){for(let r=0,o=e.length;r_&&(h=(c+u)/2,lv(s,t,e,i,h,f)&&(m=h,_=y)),c=u}return isNaN(m)&&(m=n[r]),o?(o.push(m,f,_),o):[m,f,_]}function AI(s,t,e,i,n){let r=[];for(let o=0,a=e.length;o0}function cv(s,t,e,i,n){n=n!==void 0?n:!1;for(let r=0,o=e.length;r{if(t===this.squaredTolerance_)return this.simplifiedGeometry_;this.simplifiedGeometry_=this.clone(),e&&this.simplifiedGeometry_.applyTransform(e);const i=this.simplifiedGeometry_.getFlatCoordinates();let n;switch(this.type_){case"LineString":i.length=$m(i,0,this.simplifiedGeometry_.flatCoordinates_.length,this.simplifiedGeometry_.stride_,t,i,0),n=[i.length];break;case"MultiLineString":n=[],i.length=SI(i,0,this.simplifiedGeometry_.ends_,this.simplifiedGeometry_.stride_,t,i,0,n);break;case"Polygon":n=[],i.length=av(i,0,this.simplifiedGeometry_.ends_,this.simplifiedGeometry_.stride_,Math.sqrt(t),i,0,n);break}return n&&(this.simplifiedGeometry_=new si(this.type_,i,n,2,this.properties_,this.id_)),this.squaredTolerance_=t,this.simplifiedGeometry_}),this}}si.prototype.getFlatCoordinates=si.prototype.getOrientedFlatCoordinates;class H9{constructor(){this.dataProjection=void 0,this.defaultFeatureProjection=void 0,this.featureClass=ys,this.supportedMediaTypes=null}getReadOptions(t,e){if(e){let i=e.dataProjection?st(e.dataProjection):this.readProjection(t);e.extent&&i&&i.getUnits()==="tile-pixels"&&(i=st(i),i.setWorldExtent(e.extent)),e={dataProjection:i,featureProjection:e.featureProjection}}return this.adaptOptions(e)}adaptOptions(t){return Object.assign({dataProjection:this.dataProjection,featureProjection:this.defaultFeatureProjection,featureClass:this.featureClass},t)}getType(){return vt()}readFeature(t,e){return vt()}readFeatures(t,e){return vt()}readGeometry(t,e){return vt()}readProjection(t){return vt()}writeFeature(t,e){return vt()}writeFeatures(t,e){return vt()}writeGeometry(t,e){return vt()}}const Sg=H9;function De(s,t,e){const i=e?st(e.featureProjection):null,n=e?st(e.dataProjection):null;let r=s;if(i&&n&&!qs(i,n)){t&&(r=s.clone());const o=t?i:n,a=t?n:i;o.getUnits()==="tile-pixels"?r.transform(o,a):r.applyTransform(vr(o,a))}if(t&&e&&e.decimals!==void 0){const o=Math.pow(10,e.decimals),a=function(l){for(let h=0,c=l.length;hNI({...s,geometry:o})).flat();const n=i.type==="MultiPolygon"?"Polygon":i.type;if(n==="GeometryCollection"||n==="Circle")throw new Error("Unsupported geometry type: "+n);const r=i.layout.length;return De(new si(n,n==="Polygon"?J9(i.flatCoordinates,i.ends,r):i.flatCoordinates,(e=i.ends)==null?void 0:e.flat(),r,s.properties||{},s.id).enableSimplifyTransformed(),!1,t)}function dv(s,t){if(!s)return null;if(Array.isArray(s)){const i=s.map(n=>dv(n,t));return new _s(i)}const e=K9[s.type];return De(new e(s.flatCoordinates,s.layout,s.ends),!1,t)}class gv extends Sg{constructor(){super()}getType(){return"json"}readFeature(t,e){return this.readFeatureFromObject(gf(t),this.getReadOptions(t,e))}readFeatures(t,e){return this.readFeaturesFromObject(gf(t),this.getReadOptions(t,e))}readFeatureFromObject(t,e){return vt()}readFeaturesFromObject(t,e){return vt()}readGeometry(t,e){return this.readGeometryFromObject(gf(t),this.getReadOptions(t,e))}readGeometryFromObject(t,e){return vt()}readProjection(t){return this.readProjectionFromObject(gf(t))}readProjectionFromObject(t){return vt()}writeFeature(t,e){return JSON.stringify(this.writeFeatureObject(t,e))}writeFeatureObject(t,e){return vt()}writeFeatures(t,e){return JSON.stringify(this.writeFeaturesObject(t,e))}writeFeaturesObject(t,e){return vt()}writeGeometry(t,e){return JSON.stringify(this.writeGeometryObject(t,e))}writeGeometryObject(t,e){return vt()}}function gf(s){return typeof s=="string"?JSON.parse(s)||null:s!==null?s:null}const Q9={Point:i7,LineString:n7,Polygon:l7,MultiPoint:o7,MultiLineString:r7,MultiPolygon:a7},t7={Point:h7,LineString:c7,Polygon:u7,MultiPoint:g7,MultiLineString:d7,MultiPolygon:f7};class e7 extends gv{constructor(t){t=t||{},super(),this.geometryName_=t.geometryName}readFeatureFromObject(t,e,i){const n=t,r=p2(n.geometry,e),o=new ys;if(this.geometryName_&&o.setGeometryName(this.geometryName_),o.setGeometry(r),n.attributes){o.setProperties(n.attributes,!0);const a=n.attributes[i];a!==void 0&&o.setId(a)}return o}readFeaturesFromObject(t,e){if(e=e||{},t.features){const i=t,n=[],r=i.features;for(let o=0,a=r.length;o=0;r--){const h=i[r][0];if(ai(new aa(h).getExtent(),new aa(a).getExtent())){i[r].push(a),l=!0;break}}l||i.push([a.reverse()])}return i}function i7(s){let t;return s.m!==void 0&&s.z!==void 0?t=new Cs([s.x,s.y,s.z,s.m],"XYZM"):s.z!==void 0?t=new Cs([s.x,s.y,s.z],"XYZ"):s.m!==void 0?t=new Cs([s.x,s.y,s.m],"XYM"):t=new Cs([s.x,s.y]),t}function n7(s){const t=Cc(s);return new ls(s.paths[0],t)}function r7(s){const t=Cc(s);return new Pi(s.paths,t)}function Cc(s){let t="XY";return s.hasZ===!0&&s.hasM===!0?t="XYZM":s.hasZ===!0?t="XYZ":s.hasM===!0&&(t="XYM"),t}function o7(s){const t=Cc(s);return new Zn(s.points,t)}function a7(s){const t=Cc(s);return new vn(s.rings,t)}function l7(s){const t=Cc(s);return new Hs(s.rings,t)}function h7(s,t){const e=s.getCoordinates();let i;const n=s.getLayout();if(n==="XYZ")i={x:e[0],y:e[1],z:e[2]};else if(n==="XYM")i={x:e[0],y:e[1],m:e[2]};else if(n==="XYZM")i={x:e[0],y:e[1],z:e[2],m:e[3]};else if(n==="XY")i={x:e[0],y:e[1]};else throw new Error("Invalid geometry layout");return i}function Mg(s){const t=s.getLayout();return{hasZ:t==="XYZ"||t==="XYZM",hasM:t==="XYM"||t==="XYZM"}}function c7(s,t){const e=Mg(s);return{hasZ:e.hasZ,hasM:e.hasM,paths:[s.getCoordinates()]}}function u7(s,t){const e=Mg(s);return{hasZ:e.hasZ,hasM:e.hasM,rings:s.getCoordinates(!1)}}function d7(s,t){const e=Mg(s);return{hasZ:e.hasZ,hasM:e.hasM,paths:s.getCoordinates()}}function g7(s,t){const e=Mg(s);return{hasZ:e.hasZ,hasM:e.hasM,points:s.getCoordinates()}}function f7(s,t){const e=Mg(s),i=s.getCoordinates(!1),n=[];for(let r=0;r=0;o--)n.push(i[r][o]);return{hasZ:e.hasZ,hasM:e.hasM,rings:n}}function m2(s,t){const e=t7[s.getType()];return e(De(s,!0,t),t)}const p7=e7;class m7 extends gv{constructor(t){t=t||{},super(),this.dataProjection=st(t.dataProjection?t.dataProjection:"EPSG:4326"),t.featureProjection&&(this.defaultFeatureProjection=st(t.featureProjection)),t.featureClass&&(this.featureClass=t.featureClass),this.geometryName_=t.geometryName,this.extractGeometryName_=t.extractGeometryName,this.supportedMediaTypes=["application/geo+json","application/vnd.geo+json"]}readFeatureFromObject(t,e){let i=null;t.type==="Feature"?i=t:i={type:"Feature",geometry:t,properties:null};const n=fv(i.geometry);if(this.featureClass===si)return NI({geometry:n,id:i.id,properties:i.properties},e);const r=new ys;return this.geometryName_?r.setGeometryName(this.geometryName_):this.extractGeometryName_&&i.geometry_name&&r.setGeometryName(i.geometry_name),r.setGeometry(dv(n,e)),"id"in i&&r.setId(i.id),i.properties&&r.setProperties(i.properties,!0),r}readFeaturesFromObject(t,e){const i=t;let n=null;if(i.type==="FeatureCollection"){const r=t;n=[];const o=r.features;for(let a=0,l=o.length;a0?i[0]:null}readFeatureFromNode(t,e){return null}readFeatures(t,e){if(!t)return[];if(typeof t=="string"){const i=dn(t);return this.readFeaturesFromDocument(i,e)}return un(t)?this.readFeaturesFromDocument(t,e):this.readFeaturesFromNode(t,e)}readFeaturesFromDocument(t,e){const i=[];for(let n=t.firstChild;n;n=n.nextSibling)n.nodeType==Node.ELEMENT_NODE&&ee(i,this.readFeaturesFromNode(n,e));return i}readFeaturesFromNode(t,e){return vt()}readGeometry(t,e){if(!t)return null;if(typeof t=="string"){const i=dn(t);return this.readGeometryFromDocument(i,e)}return un(t)?this.readGeometryFromDocument(t,e):this.readGeometryFromNode(t,e)}readGeometryFromDocument(t,e){return null}readGeometryFromNode(t,e){return null}readProjection(t){if(!t)return null;if(typeof t=="string"){const e=dn(t);return this.readProjectionFromDocument(e)}return un(t)?this.readProjectionFromDocument(t):this.readProjectionFromNode(t)}readProjectionFromDocument(t){return this.dataProjection}readProjectionFromNode(t){return this.dataProjection}writeFeature(t,e){const i=this.writeFeatureNode(t,e);return this.xmlSerializer_.serializeToString(i)}writeFeatureNode(t,e){return null}writeFeatures(t,e){const i=this.writeFeaturesNode(t,e);return this.xmlSerializer_.serializeToString(i)}writeFeaturesNode(t,e){return null}writeGeometry(t,e){const i=this.writeGeometryNode(t,e);return this.xmlSerializer_.serializeToString(i)}writeGeometryNode(t,e){return null}}const Zr="http://www.opengis.net/gml",F7=/^\s*$/;class ut extends bg{constructor(t){super(),t=t||{},this.featureType=t.featureType,this.featureNS=t.featureNS,this.srsName=t.srsName,this.schemaLocation="",this.FEATURE_COLLECTION_PARSERS={},this.FEATURE_COLLECTION_PARSERS[this.namespace]={featureMember:dt(this.readFeaturesInternal),featureMembers:xt(this.readFeaturesInternal)},this.supportedMediaTypes=["application/gml+xml"]}readFeaturesInternal(t,e){const i=t.localName;let n=null;if(i=="FeatureCollection")n=Y([],this.FEATURE_COLLECTION_PARSERS,t,e,this);else if(i=="featureMembers"||i=="featureMember"||i=="member"){const r=e[0];let o=r.featureType,a=r.featureNS;const l="p",h="p0";if(!o&&t.childNodes){o=[],a={};for(let d=0,g=t.childNodes.length;d0&&!(h instanceof sv)){h={_content_:h};for(let d=0;d1,i=e&&s.imageInfo.profile[1].supports?s.imageInfo.profile[1].supports:[],n=e&&s.imageInfo.profile[1].formats?s.imageInfo.profile[1].formats:[],r=e&&s.imageInfo.profile[1].qualities?s.imageInfo.profile[1].qualities:[];return{url:s.imageInfo["@id"].replace(/\/?(?:info\.json)?$/g,""),sizes:s.imageInfo.sizes===void 0?void 0:s.imageInfo.sizes.map(function(o){return[o.width,o.height]}),tileSize:s.imageInfo.tiles===void 0?void 0:[s.imageInfo.tiles.map(function(o){return o.width})[0],s.imageInfo.tiles.map(function(o){return o.height===void 0?o.width:o.height})[0]],resolutions:s.imageInfo.tiles===void 0?void 0:s.imageInfo.tiles.map(function(o){return o.scaleFactors})[0],supports:[...t.supports,...i],formats:[...t.formats,...n],qualities:[...t.qualities,...r]}}function GB(s){const t=s.getComplianceLevelSupportedFeatures(),e=s.imageInfo.extraFormats===void 0?t.formats:[...t.formats,...s.imageInfo.extraFormats],i=s.imageInfo.preferredFormats!==void 0&&Array.isArray(s.imageInfo.preferredFormats)&&s.imageInfo.preferredFormats.length>0?s.imageInfo.preferredFormats.filter(function(n){return["jpg","png","gif"].includes(n)}).reduce(function(n,r){return n===void 0&&e.includes(r)?r:n},void 0):void 0;return{url:s.imageInfo.id,sizes:s.imageInfo.sizes===void 0?void 0:s.imageInfo.sizes.map(function(n){return[n.width,n.height]}),tileSize:s.imageInfo.tiles===void 0?void 0:[s.imageInfo.tiles.map(function(n){return n.width})[0],s.imageInfo.tiles.map(function(n){return n.height})[0]],resolutions:s.imageInfo.tiles===void 0?void 0:s.imageInfo.tiles.map(function(n){return n.scaleFactors})[0],supports:s.imageInfo.extraFeatures===void 0?t.supports:[...t.supports,...s.imageInfo.extraFeatures],formats:e,qualities:s.imageInfo.extraQualities===void 0?t.qualities:[...t.qualities,...s.imageInfo.extraQualities],preferredFormat:i}}const Bm={};Bm[os.VERSION1]=kB;Bm[os.VERSION2]=$B;Bm[os.VERSION3]=GB;class jB{constructor(t){this.setImageInfo(t)}setImageInfo(t){typeof t=="string"?this.imageInfo=JSON.parse(t):this.imageInfo=t}getImageApiVersion(){if(this.imageInfo===void 0)return;let t=this.imageInfo["@context"]||"ol-no-context";typeof t=="string"&&(t=[t]);for(let e=0;e0&&typeof this.imageInfo.profile[0]=="string"&&_2.test(this.imageInfo.profile[0]))return this.imageInfo.profile[0];break}}getComplianceLevelFromProfile(t){const e=this.getComplianceLevelEntryFromProfile(t);if(e===void 0)return;const i=e.match(/level[0-2](?:\.json)?$/g);return Array.isArray(i)?i[0].replace(".json",""):void 0}getComplianceLevelSupportedFeatures(){if(this.imageInfo===void 0)return;const t=this.getImageApiVersion(),e=this.getComplianceLevelFromProfile(t);return e===void 0?rl.none.none:rl[t][e]}getTileSourceOptions(t){const e=t||{},i=this.getImageApiVersion();if(i===void 0)return;const n=i===void 0?void 0:Bm[i](this);if(n!==void 0)return{url:n.url,version:i,size:[this.imageInfo.width,this.imageInfo.height],sizes:n.sizes,format:e.format!==void 0&&n.formats.includes(e.format)?e.format:n.preferredFormat!==void 0?n.preferredFormat:"jpg",supports:n.supports,quality:e.quality&&n.qualities.includes(e.quality)?e.quality:n.qualities.includes("native")?"native":"default",resolutions:Array.isArray(n.resolutions)?n.resolutions.sort(function(r,o){return o-r}):void 0,tileSize:n.tileSize}}}const zB=jB,it={IDLE:0,LOADING:1,LOADED:2,ERROR:3,EMPTY:4},Id={name:"rgb",min:[0,0,0],max:[255,255,255],channel:["red","green","blue"],alias:["RGB"]};var Ds={name:"xyz",min:[0,0,0],channel:["X","Y","Z"],alias:["XYZ","ciexyz","cie1931"]};Ds.whitepoint={2:{A:[109.85,100,35.585],C:[98.074,100,118.232],D50:[96.422,100,82.521],D55:[95.682,100,92.149],D65:[95.045592705167,100,108.9057750759878],D75:[94.972,100,122.638],F2:[99.187,100,67.395],F7:[95.044,100,108.755],F11:[100.966,100,64.37],E:[100,100,100]},10:{A:[111.144,100,35.2],C:[97.285,100,116.145],D50:[96.72,100,81.427],D55:[95.799,100,90.926],D65:[94.811,100,107.304],D75:[94.416,100,120.641],F2:[103.28,100,69.026],F7:[95.792,100,107.687],F11:[103.866,100,65.627],E:[100,100,100]}};Ds.max=Ds.whitepoint[2].D65;Ds.rgb=function(s,t){t=t||Ds.whitepoint[2].E;var e=s[0]/t[0],i=s[1]/t[1],n=s[2]/t[2],r,o,a;return r=e*3.240969941904521+i*-1.537383177570093+n*-.498610760293,o=e*-.96924363628087+i*1.87596750150772+n*.041555057407175,a=e*.055630079696993+i*-.20397695888897+n*1.056971514242878,r=r>.0031308?1.055*Math.pow(r,1/2.4)-.055:r=r*12.92,o=o>.0031308?1.055*Math.pow(o,1/2.4)-.055:o=o*12.92,a=a>.0031308?1.055*Math.pow(a,1/2.4)-.055:a=a*12.92,r=Math.min(Math.max(0,r),1),o=Math.min(Math.max(0,o),1),a=Math.min(Math.max(0,a),1),[r*255,o*255,a*255]};Id.xyz=function(s,t){var e=s[0]/255,i=s[1]/255,n=s[2]/255;e=e>.04045?Math.pow((e+.055)/1.055,2.4):e/12.92,i=i>.04045?Math.pow((i+.055)/1.055,2.4):i/12.92,n=n>.04045?Math.pow((n+.055)/1.055,2.4):n/12.92;var r=e*.41239079926595+i*.35758433938387+n*.18048078840183,o=e*.21263900587151+i*.71516867876775+n*.072192315360733,a=e*.019330818715591+i*.11919477979462+n*.95053215224966;return t=t||Ds.whitepoint[2].E,[r*t[0],o*t[1],a*t[2]]};const wv={name:"luv",min:[0,-134,-140],max:[100,224,122],channel:["lightness","u","v"],alias:["LUV","cieluv","cie1976"],xyz:function(s,t,e){var i,n,r,o,a,l,h,c,u,d,g,f,p;if(r=s[0],o=s[1],a=s[2],r===0)return[0,0,0];var m=.0011070564598794539;return t=t||"D65",e=e||2,u=Ds.whitepoint[e][t][0],d=Ds.whitepoint[e][t][1],g=Ds.whitepoint[e][t][2],f=4*u/(u+15*d+3*g),p=9*d/(u+15*d+3*g),i=o/(13*r)+f||0,n=a/(13*r)+p||0,h=r>8?d*Math.pow((r+16)/116,3):d*r*m,l=h*9*i/(4*n)||0,c=h*(12-3*i-20*n)/(4*n)||0,[l,h,c]}};Ds.luv=function(s,t,e){var i,n,r,o,a,l,h,c,u,d,g,f,p,m=.008856451679035631,_=903.2962962962961;t=t||"D65",e=e||2,u=Ds.whitepoint[e][t][0],d=Ds.whitepoint[e][t][1],g=Ds.whitepoint[e][t][2],f=4*u/(u+15*d+3*g),p=9*d/(u+15*d+3*g),l=s[0],h=s[1],c=s[2],i=4*l/(l+15*h+3*c)||0,n=9*h/(l+15*h+3*c)||0;var y=h/d;return r=y<=m?_*y:116*Math.pow(y,1/3)-16,o=13*r*(i-f),a=13*r*(n-p),[r,o,a]};var BI={name:"lchuv",channel:["lightness","chroma","hue"],alias:["LCHuv","cielchuv"],min:[0,0,0],max:[100,100,360],luv:function(s){var t=s[0],e=s[1],i=s[2],n,r,o;return o=i/360*2*Math.PI,n=e*Math.cos(o),r=e*Math.sin(o),[t,n,r]},xyz:function(s){return wv.xyz(BI.luv(s))}};wv.lchuv=function(s){var t=s[0],e=s[1],i=s[2],n=Math.sqrt(e*e+i*i),r=Math.atan2(i,e),o=r*360/2/Math.PI;return o<0&&(o+=360),[t,n,o]};Ds.lchuv=function(s){return wv.lchuv(Ds.luv(s))};const y2={aliceblue:[240,248,255],antiquewhite:[250,235,215],aqua:[0,255,255],aquamarine:[127,255,212],azure:[240,255,255],beige:[245,245,220],bisque:[255,228,196],black:[0,0,0],blanchedalmond:[255,235,205],blue:[0,0,255],blueviolet:[138,43,226],brown:[165,42,42],burlywood:[222,184,135],cadetblue:[95,158,160],chartreuse:[127,255,0],chocolate:[210,105,30],coral:[255,127,80],cornflowerblue:[100,149,237],cornsilk:[255,248,220],crimson:[220,20,60],cyan:[0,255,255],darkblue:[0,0,139],darkcyan:[0,139,139],darkgoldenrod:[184,134,11],darkgray:[169,169,169],darkgreen:[0,100,0],darkgrey:[169,169,169],darkkhaki:[189,183,107],darkmagenta:[139,0,139],darkolivegreen:[85,107,47],darkorange:[255,140,0],darkorchid:[153,50,204],darkred:[139,0,0],darksalmon:[233,150,122],darkseagreen:[143,188,143],darkslateblue:[72,61,139],darkslategray:[47,79,79],darkslategrey:[47,79,79],darkturquoise:[0,206,209],darkviolet:[148,0,211],deeppink:[255,20,147],deepskyblue:[0,191,255],dimgray:[105,105,105],dimgrey:[105,105,105],dodgerblue:[30,144,255],firebrick:[178,34,34],floralwhite:[255,250,240],forestgreen:[34,139,34],fuchsia:[255,0,255],gainsboro:[220,220,220],ghostwhite:[248,248,255],gold:[255,215,0],goldenrod:[218,165,32],gray:[128,128,128],green:[0,128,0],greenyellow:[173,255,47],grey:[128,128,128],honeydew:[240,255,240],hotpink:[255,105,180],indianred:[205,92,92],indigo:[75,0,130],ivory:[255,255,240],khaki:[240,230,140],lavender:[230,230,250],lavenderblush:[255,240,245],lawngreen:[124,252,0],lemonchiffon:[255,250,205],lightblue:[173,216,230],lightcoral:[240,128,128],lightcyan:[224,255,255],lightgoldenrodyellow:[250,250,210],lightgray:[211,211,211],lightgreen:[144,238,144],lightgrey:[211,211,211],lightpink:[255,182,193],lightsalmon:[255,160,122],lightseagreen:[32,178,170],lightskyblue:[135,206,250],lightslategray:[119,136,153],lightslategrey:[119,136,153],lightsteelblue:[176,196,222],lightyellow:[255,255,224],lime:[0,255,0],limegreen:[50,205,50],linen:[250,240,230],magenta:[255,0,255],maroon:[128,0,0],mediumaquamarine:[102,205,170],mediumblue:[0,0,205],mediumorchid:[186,85,211],mediumpurple:[147,112,219],mediumseagreen:[60,179,113],mediumslateblue:[123,104,238],mediumspringgreen:[0,250,154],mediumturquoise:[72,209,204],mediumvioletred:[199,21,133],midnightblue:[25,25,112],mintcream:[245,255,250],mistyrose:[255,228,225],moccasin:[255,228,181],navajowhite:[255,222,173],navy:[0,0,128],oldlace:[253,245,230],olive:[128,128,0],olivedrab:[107,142,35],orange:[255,165,0],orangered:[255,69,0],orchid:[218,112,214],palegoldenrod:[238,232,170],palegreen:[152,251,152],paleturquoise:[175,238,238],palevioletred:[219,112,147],papayawhip:[255,239,213],peachpuff:[255,218,185],peru:[205,133,63],pink:[255,192,203],plum:[221,160,221],powderblue:[176,224,230],purple:[128,0,128],rebeccapurple:[102,51,153],red:[255,0,0],rosybrown:[188,143,143],royalblue:[65,105,225],saddlebrown:[139,69,19],salmon:[250,128,114],sandybrown:[244,164,96],seagreen:[46,139,87],seashell:[255,245,238],sienna:[160,82,45],silver:[192,192,192],skyblue:[135,206,235],slateblue:[106,90,205],slategray:[112,128,144],slategrey:[112,128,144],snow:[255,250,250],springgreen:[0,255,127],steelblue:[70,130,180],tan:[210,180,140],teal:[0,128,128],thistle:[216,191,216],tomato:[255,99,71],turquoise:[64,224,208],violet:[238,130,238],wheat:[245,222,179],white:[255,255,255],whitesmoke:[245,245,245],yellow:[255,255,0],yellowgreen:[154,205,50]};var x2={red:0,orange:60,yellow:120,green:180,blue:240,purple:300};function UB(s){var t,e,i,n=[],r=1,o;if(typeof s=="number")return{space:"rgb",values:[s>>>16,(s&65280)>>>8,s&255],alpha:1};if(typeof s=="number")return{space:"rgb",values:[s>>>16,(s&65280)>>>8,s&255],alpha:1};if(s=String(s).toLowerCase(),y2[s])n=y2[s].slice(),o="rgb";else if(s==="transparent")r=0,o="rgb",n=[0,0,0];else if(s[0]==="#"){var a=s.slice(1),l=a.length,h=l<=4;r=1,h?(n=[parseInt(a[0]+a[0],16),parseInt(a[1]+a[1],16),parseInt(a[2]+a[2],16)],l===4&&(r=parseInt(a[3]+a[3],16)/255)):(n=[parseInt(a[0]+a[1],16),parseInt(a[2]+a[3],16),parseInt(a[4]+a[5],16)],l===8&&(r=parseInt(a[6]+a[7],16)/255)),n[0]||(n[0]=0),n[1]||(n[1]=0),n[2]||(n[2]=0),o="rgb"}else if(i=/^((?:rgba?|hs[lvb]a?|hwba?|cmyk?|xy[zy]|gray|lab|lchu?v?|[ly]uv|lms|oklch|oklab|color))\s*\(([^\)]*)\)/.exec(s)){var c=i[1];o=c.replace(/a$/,"");var u=o==="cmyk"?4:o==="gray"?1:3;n=i[2].trim().split(/\s*[,\/]\s*|\s+/),o==="color"&&(o=n.shift()),n=n.map(function(d,g){if(d[d.length-1]==="%")return d=parseFloat(d)/100,g===3?d:o==="rgb"?d*255:o[0]==="h"||o[0]==="l"&&!g?d*100:o==="lab"?d*125:o==="lch"?g<2?d*150:d*360:o[0]==="o"&&!g?d:o==="oklab"?d*.4:o==="oklch"?g<2?d*.4:d*360:d;if(o[g]==="h"||g===2&&o[o.length-1]==="h"){if(x2[d]!==void 0)return x2[d];if(d.endsWith("deg"))return parseFloat(d);if(d.endsWith("turn"))return parseFloat(d)*360;if(d.endsWith("grad"))return parseFloat(d)*360/400;if(d.endsWith("rad"))return parseFloat(d)*180/Math.PI}return d==="none"?0:parseFloat(d)}),r=n.length>u?n.pop():1}else/[0-9](?:\s|\/|,)/.test(s)&&(n=s.match(/([0-9]+)/g).map(function(d){return parseFloat(d)}),o=((e=(t=s.match(/([a-z])/ig))==null?void 0:t.join(""))==null?void 0:e.toLowerCase())||"rgb");return{space:o,values:n,alpha:r}}const x_={name:"hsl",min:[0,0,0],max:[360,100,100],channel:["hue","saturation","lightness"],alias:["HSL"],rgb:function(s){var t=s[0]/360,e=s[1]/100,i=s[2]/100,n,r,o,a,l,h=0;if(e===0)return l=i*255,[l,l,l];for(r=i<.5?i*(1+e):i+e-i*e,n=2*i-r,a=[0,0,0];h<3;)o=t+1/3*-(h-1),o<0?o++:o>1&&o--,l=6*o<1?n+(r-n)*6*o:2*o<1?r:3*o<2?n+(r-n)*(2/3-o)*6:n,a[h++]=l*255;return a}};Id.hsl=function(s){var t=s[0]/255,e=s[1]/255,i=s[2]/255,n=Math.min(t,e,i),r=Math.max(t,e,i),o=r-n,a,l,h;return r===n?a=0:t===r?a=(e-i)/o:e===r?a=2+(i-t)/o:i===r&&(a=4+(t-e)/o),a=Math.min(a*60,360),a<0&&(a+=360),h=(n+r)/2,r===n?l=0:h<=.5?l=o/(r+n):l=o/(2-r-n),[a,l*100,h*100]};function BB(s){Array.isArray(s)&&s.raw&&(s=String.raw(...arguments)),s instanceof Number&&(s=+s);var t,e=UB(s);if(!e.space)return[];const i=e.space[0]==="h"?x_.min:Id.min,n=e.space[0]==="h"?x_.max:Id.max;return t=Array(3),t[0]=Math.min(Math.max(e.values[0],i[0]),n[0]),t[1]=Math.min(Math.max(e.values[1],i[1]),n[1]),t[2]=Math.min(Math.max(e.values[2],i[2]),n[2]),e.space[0]==="h"&&(t=x_.rgb(t)),t.push(Math.min(Math.max(e.alpha,0),1)),t}function WB(s){return typeof s=="string"?s:Sv(s)}const XB=1024,eu={};let v_=0;function VB(s){if(s.length===4)return s;const t=s.slice();return t[3]=1,t}function v2(s){const t=Ds.lchuv(Id.xyz(s));return t[3]=s[3],t}function YB(s){const t=Ds.rgb(BI.xyz(s));return t[3]=s[3],t}function Ev(s){if(eu.hasOwnProperty(s))return eu[s];if(v_>=XB){let e=0;for(const i in eu)e++&3||(delete eu[i],--v_)}const t=BB(s);if(t.length!==4)throw new Error('failed to parse "'+s+'" as color');for(const e of t)if(isNaN(e))throw new Error('failed to parse "'+s+'" as color');return WI(t),eu[s]=t,++v_,t}function Bn(s){return Array.isArray(s)?s:Ev(s)}function WI(s){return s[0]=Dt(s[0]+.5|0,0,255),s[1]=Dt(s[1]+.5|0,0,255),s[2]=Dt(s[2]+.5|0,0,255),s[3]=Dt(s[3],0,1),s}function Sv(s){let t=s[0];t!=(t|0)&&(t=t+.5|0);let e=s[1];e!=(e|0)&&(e=e+.5|0);let i=s[2];i!=(i|0)&&(i=i+.5|0);const n=s[3]===void 0?1:Math.round(s[3]*1e3)/1e3;return"rgba("+t+","+e+","+i+","+n+")"}const ha=typeof navigator<"u"&&typeof navigator.userAgent<"u"?navigator.userAgent.toLowerCase():"";ha.includes("firefox");const qB=ha.includes("safari")&&!ha.includes("chrom"),ZB=qB&&(ha.includes("version/15.4")||/cpu (os|iphone os) 15_4 like mac os x/.test(ha));ha.includes("webkit")&&ha.includes("edge");ha.includes("macintosh");const XI=typeof WorkerGlobalScope<"u"&&typeof OffscreenCanvas<"u"&&self instanceof WorkerGlobalScope,Mv=typeof Image<"u"&&Image.prototype.decode,HB=typeof createImageBitmap=="function";(function(){let s=!1;try{const t=Object.defineProperty({},"passive",{get:function(){s=!0}});window.addEventListener("_",null,t),window.removeEventListener("_",null,t)}catch{}return s})();function Se(s,t,e,i){let n;return e&&e.length?n=e.shift():XI?n=new OffscreenCanvas(s||300,t||300):n=document.createElement("canvas"),s&&(n.width=s),t&&(n.height=t),n.getContext("2d",i)}let w_;function Pp(){return w_||(w_=Se(1,1)),w_}function ol(s){const t=s.canvas;t.width=1,t.height=1,s.clearRect(0,0,1,1)}class Wm extends fg{constructor(t,e,i,n){super(),this.extent=t,this.pixelRatio_=i,this.resolution=e,this.state=typeof n=="function"?it.IDLE:n,this.image_=null,this.loader=typeof n=="function"?n:null}changed(){this.dispatchEvent(Zt.CHANGE)}getExtent(){return this.extent}getImage(){return this.image_}getPixelRatio(){return this.pixelRatio_}getResolution(){return this.resolution}getState(){return this.state}load(){if(this.state==it.IDLE&&this.loader){this.state=it.LOADING,this.changed();const t=this.getResolution(),e=Array.isArray(t)?t[0]:t;lI(()=>this.loader(this.getExtent(),e,this.getPixelRatio())).then(i=>{"image"in i&&(this.image_=i.image),"extent"in i&&(this.extent=i.extent),"resolution"in i&&(this.resolution=i.resolution),"pixelRatio"in i&&(this.pixelRatio_=i.pixelRatio),(i instanceof HTMLImageElement||i instanceof ImageBitmap||i instanceof HTMLCanvasElement||i instanceof HTMLVideoElement)&&(this.image_=i),this.state=it.LOADED}).catch(i=>{this.state=it.ERROR,console.error(i)}).finally(()=>this.changed())}}setImage(t){this.image_=t}setResolution(t){this.resolution=t}}function KB(s,t,e){const i=s;let n=!0,r=!1,o=!1;const a=[bd(i,Zt.LOAD,function(){o=!0,r||t()})];return i.src&&Mv?(r=!0,i.decode().then(function(){n&&t()}).catch(function(l){n&&(o?t():e())})):a.push(bd(i,Zt.ERROR,e)),function(){n=!1,a.forEach(ms)}}function JB(s,t){return new Promise((e,i)=>{function n(){o(),e(s)}function r(){o(),i(new Error("Image load error"))}function o(){s.removeEventListener("load",n),s.removeEventListener("error",r)}s.addEventListener("load",n),s.addEventListener("error",r)})}function VI(s,t){return t&&(s.src=t),s.src&&Mv?new Promise((e,i)=>s.decode().then(()=>e(s)).catch(n=>s.complete&&s.width?e(s):i(n))):JB(s)}function pa(s,t){return t&&(s.src=t),s.src&&Mv&&HB?s.decode().then(()=>createImageBitmap(s)).catch(e=>{if(s.complete&&s.width)return s;throw e}):VI(s)}class QB{constructor(){this.cache_={},this.patternCache_={},this.cacheSize_=0,this.maxCacheSize_=32}clear(){this.cache_={},this.patternCache_={},this.cacheSize_=0}canExpireCache(){return this.cacheSize_>this.maxCacheSize_}expire(){if(this.canExpireCache()){let t=0;for(const e in this.cache_){const i=this.cache_[e];!(t++&3)&&!i.hasListener()&&(delete this.cache_[e],delete this.patternCache_[e],--this.cacheSize_)}}}get(t,e,i){const n=E_(t,e,i);return n in this.cache_?this.cache_[n]:null}getPattern(t,e,i){const n=E_(t,e,i);return n in this.patternCache_?this.patternCache_[n]:null}set(t,e,i,n,r){const o=E_(t,e,i),a=o in this.cache_;this.cache_[o]=n,r&&(n.getImageState()===it.IDLE&&n.load(),n.getImageState()===it.LOADING?n.ready().then(()=>{this.patternCache_[o]=Pp().createPattern(n.getImage(1),"repeat")}):this.patternCache_[o]=Pp().createPattern(n.getImage(1),"repeat")),a||++this.cacheSize_}setSize(t){this.maxCacheSize_=t,this.expire()}}function E_(s,t,e){const i=e?Bn(e):"null";return t+":"+s+":"+i}const Vo=new QB;let su=null;class tW extends fg{constructor(t,e,i,n,r){super(),this.hitDetectionImage_=null,this.image_=t,this.crossOrigin_=i,this.canvas_={},this.color_=r,this.imageState_=n===void 0?it.IDLE:n,this.size_=t&&t.width&&t.height?[t.width,t.height]:null,this.src_=e,this.tainted_,this.ready_=null}initializeImage_(){this.image_=new Image,this.crossOrigin_!==null&&(this.image_.crossOrigin=this.crossOrigin_)}isTainted_(){if(this.tainted_===void 0&&this.imageState_===it.LOADED){su||(su=Se(1,1,void 0,{willReadFrequently:!0})),su.drawImage(this.image_,0,0);try{su.getImageData(0,0,1,1),this.tainted_=!1}catch{su=null,this.tainted_=!0}}return this.tainted_===!0}dispatchChangeEvent_(){this.dispatchEvent(Zt.CHANGE)}handleImageError_(){this.imageState_=it.ERROR,this.dispatchChangeEvent_()}handleImageLoad_(){this.imageState_=it.LOADED,this.size_=[this.image_.width,this.image_.height],this.dispatchChangeEvent_()}getImage(t){return this.image_||this.initializeImage_(),this.replaceColor_(t),this.canvas_[t]?this.canvas_[t]:this.image_}getPixelRatio(t){return this.replaceColor_(t),this.canvas_[t]?t:1}getImageState(){return this.imageState_}getHitDetectionImage(){if(this.image_||this.initializeImage_(),!this.hitDetectionImage_)if(this.isTainted_()){const t=this.size_[0],e=this.size_[1],i=Se(t,e);i.fillRect(0,0,t,e),this.hitDetectionImage_=i.canvas}else this.hitDetectionImage_=this.image_;return this.hitDetectionImage_}getSize(){return this.size_}getSrc(){return this.src_}load(){if(this.imageState_===it.IDLE){this.image_||this.initializeImage_(),this.imageState_=it.LOADING;try{this.src_!==void 0&&(this.image_.src=this.src_)}catch{this.handleImageError_()}this.image_ instanceof HTMLImageElement&&VI(this.image_,this.src_).then(t=>{this.image_=t,this.handleImageLoad_()}).catch(this.handleImageError_.bind(this))}}replaceColor_(t){if(!this.color_||this.canvas_[t]||this.imageState_!==it.LOADED)return;const e=this.image_,i=document.createElement("canvas");i.width=Math.ceil(e.width*t),i.height=Math.ceil(e.height*t);const n=i.getContext("2d");n.scale(t,t),n.drawImage(e,0,0),n.globalCompositeOperation="multiply",n.fillStyle=WB(this.color_),n.fillRect(0,0,i.width/t,i.height/t),n.globalCompositeOperation="destination-in",n.drawImage(e,0,0),this.canvas_[t]=i}ready(){return this.ready_||(this.ready_=new Promise(t=>{if(this.imageState_===it.LOADED||this.imageState_===it.ERROR)t();else{const e=()=>{(this.imageState_===it.LOADED||this.imageState_===it.ERROR)&&(this.removeEventListener(Zt.CHANGE,e),t())};this.addEventListener(Zt.CHANGE,e)}})),this.ready_}}function bv(s,t,e,i,n,r){let o=t===void 0?void 0:Vo.get(t,e,n);return o||(o=new tW(s,s&&"src"in s?s.src||void 0:t,e,i,n),Vo.set(t,e,n,o,r)),r&&o&&!Vo.getPattern(t,e,n)&&Vo.set(t,e,n,o,r),o}class Wn{constructor(t){t=t||{},this.patternImage_=null,this.color_=null,t.color!==void 0&&this.setColor(t.color)}clone(){const t=this.getColor();return new Wn({color:Array.isArray(t)?t.slice():t||void 0})}getColor(){return this.color_}setColor(t){if(t!==null&&typeof t=="object"&&"src"in t){const e=bv(null,t.src,"anonymous",void 0,t.offset?null:t.color?t.color:null,!(t.offset&&t.size));e.ready().then(()=>{this.patternImage_=null}),e.getImageState()===it.IDLE&&e.load(),e.getImageState()===it.LOADING&&(this.patternImage_=e)}this.color_=t}loading(){return!!this.patternImage_}ready(){return this.patternImage_?this.patternImage_.ready():Promise.resolve()}}function YI(s,t,e){return e===void 0&&(e=[0,0]),e[0]=s[0]*t+.5|0,e[1]=s[1]*t+.5|0,e}function Re(s,t){return Array.isArray(s)?s:(t===void 0?t=[s,s]:(t[0]=s,t[1]=s),t)}class Xm{constructor(t){this.opacity_=t.opacity,this.rotateWithView_=t.rotateWithView,this.rotation_=t.rotation,this.scale_=t.scale,this.scaleArray_=Re(t.scale),this.displacement_=t.displacement,this.declutterMode_=t.declutterMode}clone(){const t=this.getScale();return new Xm({opacity:this.getOpacity(),scale:Array.isArray(t)?t.slice():t,rotation:this.getRotation(),rotateWithView:this.getRotateWithView(),displacement:this.getDisplacement().slice(),declutterMode:this.getDeclutterMode()})}getOpacity(){return this.opacity_}getRotateWithView(){return this.rotateWithView_}getRotation(){return this.rotation_}getScale(){return this.scale_}getScaleArray(){return this.scaleArray_}getDisplacement(){return this.displacement_}getDeclutterMode(){return this.declutterMode_}getAnchor(){return vt()}getImage(t){return vt()}getHitDetectionImage(){return vt()}getPixelRatio(t){return 1}getImageState(){return vt()}getImageSize(){return vt()}getOrigin(){return vt()}getSize(){return vt()}setDisplacement(t){this.displacement_=t}setOpacity(t){this.opacity_=t}setRotateWithView(t){this.rotateWithView_=t}setRotation(t){this.rotation_=t}setScale(t){this.scale_=t,this.scaleArray_=Re(t)}listenImageChange(t){vt()}load(){vt()}unlistenImageChange(t){vt()}ready(){return Promise.resolve()}}function w2(s,t,e,i){return e!==void 0&&i!==void 0?[e/s,i/t]:e!==void 0?e/s:i!==void 0?i/t:1}class Rc extends Xm{constructor(t){t=t||{};const e=t.opacity!==void 0?t.opacity:1,i=t.rotation!==void 0?t.rotation:0,n=t.scale!==void 0?t.scale:1,r=t.rotateWithView!==void 0?t.rotateWithView:!1;super({opacity:e,rotation:i,scale:n,displacement:t.displacement!==void 0?t.displacement:[0,0],rotateWithView:r,declutterMode:t.declutterMode}),this.anchor_=t.anchor!==void 0?t.anchor:[.5,.5],this.normalizedAnchor_=null,this.anchorOrigin_=t.anchorOrigin!==void 0?t.anchorOrigin:"top-left",this.anchorXUnits_=t.anchorXUnits!==void 0?t.anchorXUnits:"fraction",this.anchorYUnits_=t.anchorYUnits!==void 0?t.anchorYUnits:"fraction",this.crossOrigin_=t.crossOrigin!==void 0?t.crossOrigin:null;const o=t.img!==void 0?t.img:null;let a=t.src;qt(!(a!==void 0&&o),"`image` and `src` cannot be provided at the same time"),(a===void 0||a.length===0)&&o&&(a=o.src||mt(o)),qt(a!==void 0&&a.length>0,"A defined and non-empty `src` or `image` must be provided"),qt(!((t.width!==void 0||t.height!==void 0)&&t.scale!==void 0),"`width` or `height` cannot be provided together with `scale`");let l;if(t.src!==void 0?l=it.IDLE:o!==void 0&&("complete"in o?o.complete?l=o.src?it.LOADED:it.IDLE:l=it.LOADING:l=it.LOADED),this.color_=t.color!==void 0?Bn(t.color):null,this.iconImage_=bv(o,a,this.crossOrigin_,l,this.color_),this.offset_=t.offset!==void 0?t.offset:[0,0],this.offsetOrigin_=t.offsetOrigin!==void 0?t.offsetOrigin:"top-left",this.origin_=null,this.size_=t.size!==void 0?t.size:null,this.initialOptions_,t.width!==void 0||t.height!==void 0){let h,c;if(t.size)[h,c]=t.size;else{const u=this.getImage(1);if(u.width&&u.height)h=u.width,c=u.height;else if(u instanceof HTMLImageElement){this.initialOptions_=t;const d=()=>{if(this.unlistenImageChange(d),!this.initialOptions_)return;const g=this.iconImage_.getSize();this.setScale(w2(g[0],g[1],t.width,t.height))};this.listenImageChange(d);return}}h!==void 0&&this.setScale(w2(h,c,t.width,t.height))}}clone(){let t,e,i;return this.initialOptions_?(e=this.initialOptions_.width,i=this.initialOptions_.height):(t=this.getScale(),t=Array.isArray(t)?t.slice():t),new Rc({anchor:this.anchor_.slice(),anchorOrigin:this.anchorOrigin_,anchorXUnits:this.anchorXUnits_,anchorYUnits:this.anchorYUnits_,color:this.color_&&this.color_.slice?this.color_.slice():this.color_||void 0,crossOrigin:this.crossOrigin_,offset:this.offset_.slice(),offsetOrigin:this.offsetOrigin_,opacity:this.getOpacity(),rotateWithView:this.getRotateWithView(),rotation:this.getRotation(),scale:t,width:e,height:i,size:this.size_!==null?this.size_.slice():void 0,src:this.getSrc(),displacement:this.getDisplacement().slice(),declutterMode:this.getDeclutterMode()})}getAnchor(){let t=this.normalizedAnchor_;if(!t){t=this.anchor_;const n=this.getSize();if(this.anchorXUnits_=="fraction"||this.anchorYUnits_=="fraction"){if(!n)return null;t=this.anchor_.slice(),this.anchorXUnits_=="fraction"&&(t[0]*=n[0]),this.anchorYUnits_=="fraction"&&(t[1]*=n[1])}if(this.anchorOrigin_!="top-left"){if(!n)return null;t===this.anchor_&&(t=this.anchor_.slice()),(this.anchorOrigin_=="top-right"||this.anchorOrigin_=="bottom-right")&&(t[0]=-t[0]+n[0]),(this.anchorOrigin_=="bottom-left"||this.anchorOrigin_=="bottom-right")&&(t[1]=-t[1]+n[1])}this.normalizedAnchor_=t}const e=this.getDisplacement(),i=this.getScaleArray();return[t[0]-e[0]/i[0],t[1]+e[1]/i[1]]}setAnchor(t){this.anchor_=t,this.normalizedAnchor_=null}getColor(){return this.color_}getImage(t){return this.iconImage_.getImage(t)}getPixelRatio(t){return this.iconImage_.getPixelRatio(t)}getImageSize(){return this.iconImage_.getSize()}getImageState(){return this.iconImage_.getImageState()}getHitDetectionImage(){return this.iconImage_.getHitDetectionImage()}getOrigin(){if(this.origin_)return this.origin_;let t=this.offset_;if(this.offsetOrigin_!="top-left"){const e=this.getSize(),i=this.iconImage_.getSize();if(!e||!i)return null;t=t.slice(),(this.offsetOrigin_=="top-right"||this.offsetOrigin_=="bottom-right")&&(t[0]=i[0]-e[0]-t[0]),(this.offsetOrigin_=="bottom-left"||this.offsetOrigin_=="bottom-right")&&(t[1]=i[1]-e[1]-t[1])}return this.origin_=t,this.origin_}getSrc(){return this.iconImage_.getSrc()}getSize(){return this.size_?this.size_:this.iconImage_.getSize()}getWidth(){const t=this.getScaleArray();if(this.size_)return this.size_[0]*t[0];if(this.iconImage_.getImageState()==it.LOADED)return this.iconImage_.getSize()[0]*t[0]}getHeight(){const t=this.getScaleArray();if(this.size_)return this.size_[1]*t[1];if(this.iconImage_.getImageState()==it.LOADED)return this.iconImage_.getSize()[1]*t[1]}setScale(t){delete this.initialOptions_,super.setScale(t)}listenImageChange(t){this.iconImage_.addEventListener(Zt.CHANGE,t)}load(){this.iconImage_.load()}unlistenImageChange(t){this.iconImage_.removeEventListener(Zt.CHANGE,t)}ready(){return this.iconImage_.ready()}}class wn{constructor(t){t=t||{},this.color_=t.color!==void 0?t.color:null,this.lineCap_=t.lineCap,this.lineDash_=t.lineDash!==void 0?t.lineDash:null,this.lineDashOffset_=t.lineDashOffset,this.lineJoin_=t.lineJoin,this.miterLimit_=t.miterLimit,this.width_=t.width}clone(){const t=this.getColor();return new wn({color:Array.isArray(t)?t.slice():t||void 0,lineCap:this.getLineCap(),lineDash:this.getLineDash()?this.getLineDash().slice():void 0,lineDashOffset:this.getLineDashOffset(),lineJoin:this.getLineJoin(),miterLimit:this.getMiterLimit(),width:this.getWidth()})}getColor(){return this.color_}getLineCap(){return this.lineCap_}getLineDash(){return this.lineDash_}getLineDashOffset(){return this.lineDashOffset_}getLineJoin(){return this.lineJoin_}getMiterLimit(){return this.miterLimit_}getWidth(){return this.width_}setColor(t){this.color_=t}setLineCap(t){this.lineCap_=t}setLineDash(t){this.lineDash_=t}setLineDashOffset(t){this.lineDashOffset_=t}setLineJoin(t){this.lineJoin_=t}setMiterLimit(t){this.miterLimit_=t}setWidth(t){this.width_=t}}function hr(s){return s?Array.isArray(s)?Sv(s):typeof s=="object"&&"src"in s?eW(s):s:null}function eW(s){if(!s.offset||!s.size)return Vo.getPattern(s.src,"anonymous",s.color);const t=s.src+":"+s.offset,e=Vo.getPattern(t,void 0,s.color);if(e)return e;const i=Vo.get(s.src,"anonymous",null);if(i.getImageState()!==it.LOADED)return null;const n=Se(s.size[0],s.size[1]);return n.drawImage(i.getImage(1),s.offset[0],s.offset[1],s.size[0],s.size[1],0,0,s.size[0],s.size[1]),bv(n.canvas,t,void 0,it.LOADED,s.color,!0),Vo.getPattern(t,void 0,s.color)}const sW=new RegExp(["^\\s*(?=(?:(?:[-a-z]+\\s*){0,2}(italic|oblique))?)","(?=(?:(?:[-a-z]+\\s*){0,2}(small-caps))?)","(?=(?:(?:[-a-z]+\\s*){0,2}(bold(?:er)?|lighter|[1-9]00 ))?)","(?:(?:normal|\\1|\\2|\\3)\\s*){0,3}((?:xx?-)?","(?:small|large)|medium|smaller|larger|[\\.\\d]+(?:\\%|in|[cem]m|ex|p[ctx]))","(?:\\s*\\/\\s*(normal|[\\.\\d]+(?:\\%|in|[cem]m|ex|p[ctx])?))",`?\\s*([-,\\"\\'\\sa-z]+?)\\s*$`].join(""),"i"),E2=["style","variant","weight","size","lineHeight","family"],qI=function(s){const t=s.match(sW);if(!t)return null;const e={lineHeight:"normal",size:"1.2em",style:"normal",weight:"normal",variant:"normal"};for(let i=0,n=E2.length;iMath.max(n,Lp(s,r)),0);return e[t]=i,i}function rW(s,t){const e=[],i=[],n=[];let r=0,o=0,a=0,l=0;for(let h=0,c=t.length;h<=c;h+=2){const u=t[h];if(u===` -`||h===c){r=Math.max(r,o),n.push(o),o=0,a+=l,l=0;continue}const d=t[h+1]||s.font,g=Lp(d,u);e.push(g),o+=g;const f=nW(d);i.push(f),l=Math.max(l,f)}return{width:r,height:a,widths:e,heights:i,lineWidths:n}}function oW(s,t,e,i,n,r,o,a,l,h,c){s.save(),e!==1&&(s.globalAlpha===void 0?s.globalAlpha=u=>u.globalAlpha*=e:s.globalAlpha*=e),t&&s.transform.apply(s,t),i.contextInstructions?(s.translate(l,h),s.scale(c[0],c[1]),aW(i,s)):c[0]<0||c[1]<0?(s.translate(l,h),s.scale(c[0],c[1]),s.drawImage(i,n,r,o,a,0,0,o,a)):s.drawImage(i,n,r,o,a,l,h,o*c[0],a*c[1]),s.restore()}function aW(s,t){const e=s.contextInstructions;for(let i=0,n=e.length;ithis.imageState_=it.LOADED),this.render()}clone(){const t=this.getScale(),e=new Vm({fill:this.getFill()?this.getFill().clone():void 0,points:this.getPoints(),radius:this.getRadius(),radius2:this.getRadius2(),angle:this.getAngle(),stroke:this.getStroke()?this.getStroke().clone():void 0,rotation:this.getRotation(),rotateWithView:this.getRotateWithView(),scale:Array.isArray(t)?t.slice():t,displacement:this.getDisplacement().slice(),declutterMode:this.getDeclutterMode()});return e.setOpacity(this.getOpacity()),e}getAnchor(){const t=this.size_,e=this.getDisplacement(),i=this.getScaleArray();return[t[0]/2-e[0]/i[0],t[1]/2+e[1]/i[1]]}getAngle(){return this.angle_}getFill(){return this.fill_}setFill(t){this.fill_=t,this.render()}getHitDetectionImage(){return this.hitDetectionCanvas_||(this.hitDetectionCanvas_=this.createHitDetectionCanvas_(this.renderOptions_)),this.hitDetectionCanvas_}getImage(t){let e=this.canvases_[t];if(!e){const i=this.renderOptions_,n=Se(i.size*t,i.size*t);this.draw_(i,n,t),e=n.canvas,this.canvases_[t]=e}return e}getPixelRatio(t){return t}getImageSize(){return this.size_}getImageState(){return this.imageState_}getOrigin(){return this.origin_}getPoints(){return this.points_}getRadius(){return this.radius}getRadius2(){return this.radius2_}getSize(){return this.size_}getStroke(){return this.stroke_}setStroke(t){this.stroke_=t,this.render()}listenImageChange(t){}load(){}unlistenImageChange(t){}calculateLineJoinSize_(t,e,i){if(e===0||this.points_===1/0||t!=="bevel"&&t!=="miter")return e;let n=this.radius,r=this.radius2_===void 0?n:this.radius2_;if(n1?o.Document=t:t.length==1&&(o.Placemark=t[0]);const a=pW[i.namespaceURI],l=Ai(o,a);return Ct(r,mW,Is,l,[e],a,this),i}}function vW(s,t){const e=[0,0];let i="start";const n=s.getImage();if(n){const o=n.getSize();if(o&&o.length==2){const a=n.getScaleArray(),l=n.getAnchor();e[0]=a[0]*(o[0]-l[0]),e[1]=a[1]*(o[1]/2-l[1]),i="left"}}let r=s.getText();return r?(r=r.clone(),r.setFont(r.getFont()||Ua.getFont()),r.setScale(r.getScale()||Ua.getScale()),r.setFill(r.getFill()||Ua.getFill()),r.setStroke(r.getStroke()||sy)):r=Ua.clone(),r.setText(t),r.setOffsetX(e[0]),r.setOffsetY(e[1]),r.setTextAlign(i),new Ps({image:n,text:r})}function wW(s,t,e,i,n){return function(r,o){let a=n,l="",h=[];if(a){const u=r.getGeometry();if(u)if(u instanceof _s)h=u.getGeometriesArrayRecursive().filter(function(d){const g=d.getType();return g==="Point"||g==="MultiPoint"}),a=h.length>0;else{const d=u.getType();a=d==="Point"||d==="MultiPoint"}}a&&(l=r.get("name"),a=a&&!!l,a&&/&[^&]+;/.test(l)&&(pf||(pf=document.createElement("textarea")),pf.innerHTML=l,l=pf.value));let c=e;if(s?c=s:t&&(c=QI(t,e,i)),a){const u=vW(c[0],l);if(h.length>0){u.setGeometry(new _s(h));const d=new Ps({geometry:c[0].getGeometry(),image:null,fill:c[0].getFill(),stroke:c[0].getStroke(),text:null});return[u,d].concat(c.slice(1))}return u}return c}}function QI(s,t,e){return Array.isArray(s)?s:typeof s=="string"?QI(e[s],t,e):t}function qm(s){const t=ci(s,!1),e=/^\s*#?\s*([0-9A-Fa-f]{8})\s*$/.exec(t);if(e){const i=e[1];return[parseInt(i.substr(6,2),16),parseInt(i.substr(4,2),16),parseInt(i.substr(2,2),16),parseInt(i.substr(0,2),16)/255]}}function tP(s){let t=ci(s,!1);const e=[];t=t.replace(/\s*,\s*/g,",");const i=/^\s*([+\-]?\d*\.?\d+(?:e[+\-]?\d+)?),([+\-]?\d*\.?\d+(?:e[+\-]?\d+)?)(?:\s+|,|$)(?:([+\-]?\d*\.?\d+(?:e[+\-]?\d+)?)(?:\s+|$))?\s*/i;let n;for(;n=i.exec(t);){const r=parseFloat(n[1]),o=parseFloat(n[2]),a=n[3]?parseFloat(n[3]):0;e.push(r,o,a),t=t.substr(n[0].length)}if(t==="")return e}function eP(s){const t=ci(s,!1).trim();let e=s.baseURI;return(!e||e=="about:blank")&&(e=window.location.href),e?new URL(t,e).href:t}function sP(s){const t=ci(s,!1).trim().replace(/^(?!.*#)/,"#");let e=s.baseURI;return(!e||e=="about:blank")&&(e=window.location.href),e?new URL(t,e).href:t}function EW(s){const t=s.getAttribute("xunits"),e=s.getAttribute("yunits");let i;return t!=="insetPixels"?e!=="insetPixels"?i="bottom-left":i="top-left":e!=="insetPixels"?i="bottom-right":i="top-right",{x:parseFloat(s.getAttribute("x")),xunits:b2[t],y:parseFloat(s.getAttribute("y")),yunits:b2[e],origin:i}}function iP(s){return Yt(s)}const SW=B(ft,{Pair:YW});function nP(s,t){return Y(void 0,SW,s,t,this)}const MW=B(ft,{Icon:L($W),color:L(qm),heading:L(Yt),hotSpot:L(EW),scale:L(iP)});function bW(s,t){const e=Y({},MW,s,t);if(!e)return;const i=t[t.length-1],n="Icon"in e?e.Icon:{},r=!("Icon"in e)||Object.keys(n).length>0;let o;const a=n.href;a?o=a:r&&(o=Op);let l,h,c,u="bottom-left";const d=e.hotSpot;d?(l=[d.x,d.y],h=d.xunits,c=d.yunits,u=d.origin):/^https?:\/\/maps\.(?:google|gstatic)\.com\//.test(o)&&(o.includes("pushpin")?(l=Q1,h=Vu,c=Yu):o.includes("arrow-reverse")?(l=[54,42],h=Vu,c=Yu):o.includes("paddle")&&(l=[32,1],h=Vu,c=Yu));let g;const f=n.x,p=n.y;f!==void 0&&p!==void 0&&(g=[f,p]);let m;const _=n.w,y=n.h;_!==void 0&&y!==void 0&&(m=[_,y]);let v;const S=e.heading;S!==void 0&&(v=Xu(S));const w=e.scale,T=e.color;if(r){o==Op&&(m=qu);const M=new Rc({anchor:l,anchorOrigin:u,anchorXUnits:h,anchorYUnits:c,crossOrigin:this.crossOrigin_,offset:g,offsetOrigin:"bottom-left",rotation:v,scale:w,size:m,src:this.iconUrlFunction_(o),color:T}),C=M.getScaleArray()[0],I=M.getSize();if(I===null){const O=M.getImageState();if(O===it.IDLE||O===it.LOADING){const P=function(){const D=M.getImageState();if(!(D===it.IDLE||D===it.LOADING)){const x=M.getSize();if(x&&x.length==2){const E=Fp(x);M.setScale(C*E)}M.unlistenImageChange(P)}};M.listenImageChange(P),O===it.IDLE&&M.load()}}else if(I.length==2){const O=Fp(I);M.setScale(C*O)}i.imageStyle=M}else i.imageStyle=Tv}const TW=B(ft,{color:L(qm),scale:L(iP)});function CW(s,t){const e=Y({},TW,s,t);if(!e)return;const i=t[t.length-1],n=new al({fill:new Wn({color:"color"in e?e.color:Lh}),scale:e.scale});i.textStyle=n}const RW=B(ft,{color:L(qm),width:L(Yt)});function IW(s,t){const e=Y({},RW,s,t);if(!e)return;const i=t[t.length-1],n=new wn({color:"color"in e?e.color:Lh,width:"width"in e?e.width:1});i.strokeStyle=n}const PW=B(ft,{color:L(qm),fill:L(la),outline:L(la)});function AW(s,t){const e=Y({},PW,s,t);if(!e)return;const i=t[t.length-1],n=new Wn({color:"color"in e?e.color:Lh});i.fillStyle=n;const r=e.fill;r!==void 0&&(i.fill=r);const o=e.outline;o!==void 0&&(i.outline=o)}const LW=B(ft,{coordinates:xt(tP)});function rP(s,t){return Y(null,LW,s,t)}function OW(s,t){const e=t[t.length-1].coordinates,i=ci(s,!1),n=/^\s*([+\-]?\d+(?:\.\d*)?(?:e[+\-]?\d*)?)\s+([+\-]?\d+(?:\.\d*)?(?:e[+\-]?\d*)?)\s+([+\-]?\d+(?:\.\d*)?(?:e[+\-]?\d*)?)\s*$/i.exec(i);if(n){const r=parseFloat(n[1]),o=parseFloat(n[2]),a=parseFloat(n[3]);e.push([r,o,a])}else e.push([])}const FW=B(mo,{Track:dt(oP)});function NW(s,t){const e=Y([],FW,s,t);if(e)return new Pi(e)}const DW=B(ft,{when:aX},B(mo,{coord:OW}));function oP(s,t){const e=Y({coordinates:[],whens:[]},DW,s,t);if(!e)return;const i=[],n=e.coordinates,r=e.whens;for(let o=0,a=Math.min(n.length,r.length);o0&&t[t.length-1].push(...e)}const nX=B(ft,{LinearRing:xt(rP)});function rX(s,t){const e=Y(void 0,nX,s,t);if(e){const i=t[t.length-1];i[0]=e}}function oX(s,t){Ii(gW,s,t)}function aX(s,t){const e=t[t.length-1].whens,i=ci(s,!1),n=Date.parse(i);e.push(isNaN(n)?0:n)}function Hm(s,t){const e=Bn(t),i=[(e.length==4?e[3]:1)*255,e[2],e[1],e[0]];for(let n=0;n<4;++n){const r=Math.floor(i[n]).toString(16);i[n]=r.length==1?"0"+r:r}Tt(s,i.join(""))}function lX(s,t,e){const i=e[e.length-1],n=i.layout,r=i.stride;let o;if(n=="XY"||n=="XYM")o=2;else if(n=="XYZ"||n=="XYZM")o=3;else throw new Error("Invalid geometry layout");const a=t.length;let l="";if(a>0){l+=t[0];for(let h=1;h0){const g=Ai(n,o);Ct(i,b_,DX,[{names:o,values:g}],e)}const u=e[0];let d=t.getGeometry();d&&(d=De(d,!0,u)),Ct(i,b_,fP,[d],e)}const kX=B(ft,["extrude","tessellate","altitudeMode","coordinates"]),$X=B(ft,{extrude:N(ac),tessellate:N(ac),altitudeMode:N(Tt),coordinates:N(lX)});function Oh(s,t,e){const i=t.getFlatCoordinates(),n={node:s};n.layout=t.getLayout(),n.stride=t.getStride();const r=t.getProperties();r.coordinates=i;const o=e[e.length-1].node,a=kX[o.namespaceURI],l=Ai(r,a);Ct(n,$X,Is,l,e,a)}const GX=B(ft,["color","fill","outline"]),P2=B(ft,{outerBoundaryIs:N(I2),innerBoundaryIs:N(I2)}),jX=Xe("innerBoundaryIs"),zX=Xe("outerBoundaryIs");function _P(s,t,e){const i=t.getLinearRings(),n=i.shift(),r={node:s};Ct(r,P2,jX,i,e),Ct(r,P2,zX,[n],e)}const UX=B(ft,{color:N(Hm),fill:N(ac),outline:N(ac)});function BX(s,t,e){const i={node:s},n=t.getFill(),r=t.getStroke(),o={color:n?n.getColor():void 0,fill:n?void 0:!1,outline:r?void 0:!1},a=e[e.length-1].node,l=GX[a.namespaceURI],h=Ai(o,l);Ct(i,UX,Is,h,e,l)}function yP(s,t){vi(s,Math.round(t*1e6)/1e6)}const WX=B(ft,["IconStyle","LabelStyle","LineStyle","PolyStyle"]),XX=B(ft,{IconStyle:N(wX),LabelStyle:N(MX),LineStyle:N(CX),PolyStyle:N(BX)});function VX(s,t,e){const i={node:s},n={};if(t.pointStyles.length){const l=t.pointStyles[0].getText();l&&(n.LabelStyle=l);const h=t.pointStyles[0].getImage();h&&typeof h.getSrc=="function"&&(n.IconStyle=h)}if(t.lineStyles.length){const l=t.lineStyles[0].getStroke();l&&(n.LineStyle=l)}if(t.polyStyles.length){const l=t.polyStyles[0].getStroke();l&&!n.LineStyle&&(n.LineStyle=l),n.PolyStyle=t.polyStyles[0]}const r=e[e.length-1].node,o=WX[r.namespaceURI],a=Ai(n,o);Ct(i,XX,Is,a,e,o)}function YX(s,t){s.setAttribute("x",String(t.x)),s.setAttribute("y",String(t.y)),s.setAttribute("xunits",t.xunits),s.setAttribute("yunits",t.yunits)}const qX=xW,ny=65536*65536,A2=1/ny,ZX=12,L2=typeof TextDecoder>"u"?null:new TextDecoder("utf-8"),T_=0,mf=1,iu=2,_f=5;class HX{constructor(t=new Uint8Array(16)){this.buf=ArrayBuffer.isView(t)?t:new Uint8Array(t),this.dataView=new DataView(this.buf.buffer),this.pos=0,this.type=0,this.length=this.buf.length}readFields(t,e,i=this.length){for(;this.pos>3,o=this.pos;this.type=n&7,t(r,e,this),this.pos===o&&this.skip(n)}return e}readMessage(t,e){return this.readFields(t,e,this.readVarint()+this.pos)}readFixed32(){const t=this.dataView.getUint32(this.pos,!0);return this.pos+=4,t}readSFixed32(){const t=this.dataView.getInt32(this.pos,!0);return this.pos+=4,t}readFixed64(){const t=this.dataView.getUint32(this.pos,!0)+this.dataView.getUint32(this.pos+4,!0)*ny;return this.pos+=8,t}readSFixed64(){const t=this.dataView.getUint32(this.pos,!0)+this.dataView.getInt32(this.pos+4,!0)*ny;return this.pos+=8,t}readFloat(){const t=this.dataView.getFloat32(this.pos,!0);return this.pos+=4,t}readDouble(){const t=this.dataView.getFloat64(this.pos,!0);return this.pos+=8,t}readVarint(t){const e=this.buf;let i,n;return n=e[this.pos++],i=n&127,n<128||(n=e[this.pos++],i|=(n&127)<<7,n<128)||(n=e[this.pos++],i|=(n&127)<<14,n<128)||(n=e[this.pos++],i|=(n&127)<<21,n<128)?i:(n=e[this.pos],i|=(n&15)<<28,KX(i,t,this))}readVarint64(){return this.readVarint(!0)}readSVarint(){const t=this.readVarint();return t%2===1?(t+1)/-2:t/2}readBoolean(){return!!this.readVarint()}readString(){const t=this.readVarint()+this.pos,e=this.pos;return this.pos=t,t-e>=ZX&&L2?L2.decode(this.buf.subarray(e,t)):uV(this.buf,e,t)}readBytes(){const t=this.readVarint()+this.pos,e=this.buf.subarray(this.pos,t);return this.pos=t,e}readPackedVarint(t=[],e){const i=this.readPackedEnd();for(;this.pos127;);else if(e===iu)this.pos=this.readVarint()+this.pos;else if(e===_f)this.pos+=4;else if(e===mf)this.pos+=8;else throw new Error(`Unimplemented type: ${e}`)}writeTag(t,e){this.writeVarint(t<<3|e)}realloc(t){let e=this.length||16;for(;e268435455||t<0){QX(t,this);return}this.realloc(4),this.buf[this.pos++]=t&127|(t>127?128:0),!(t<=127)&&(this.buf[this.pos++]=(t>>>=7)&127|(t>127?128:0),!(t<=127)&&(this.buf[this.pos++]=(t>>>=7)&127|(t>127?128:0),!(t<=127)&&(this.buf[this.pos++]=t>>>7&127)))}writeSVarint(t){this.writeVarint(t<0?-t*2-1:t*2)}writeBoolean(t){this.writeVarint(+t)}writeString(t){t=String(t),this.realloc(t.length*4),this.pos++;const e=this.pos;this.pos=dV(this.buf,t,this.pos);const i=this.pos-e;i>=128&&O2(e,i,this),this.pos=e-1,this.writeVarint(i),this.pos+=i}writeFloat(t){this.realloc(4),this.dataView.setFloat32(this.pos,t,!0),this.pos+=4}writeDouble(t){this.realloc(8),this.dataView.setFloat64(this.pos,t,!0),this.pos+=8}writeBytes(t){const e=t.length;this.writeVarint(e),this.realloc(e);for(let i=0;i=128&&O2(i,n,this),this.pos=i-1,this.writeVarint(n),this.pos+=n}writeMessage(t,e,i){this.writeTag(t,iu),this.writeRawMessage(e,i)}writePackedVarint(t,e){e.length&&this.writeMessage(t,sV,e)}writePackedSVarint(t,e){e.length&&this.writeMessage(t,iV,e)}writePackedBoolean(t,e){e.length&&this.writeMessage(t,oV,e)}writePackedFloat(t,e){e.length&&this.writeMessage(t,nV,e)}writePackedDouble(t,e){e.length&&this.writeMessage(t,rV,e)}writePackedFixed32(t,e){e.length&&this.writeMessage(t,aV,e)}writePackedSFixed32(t,e){e.length&&this.writeMessage(t,lV,e)}writePackedFixed64(t,e){e.length&&this.writeMessage(t,hV,e)}writePackedSFixed64(t,e){e.length&&this.writeMessage(t,cV,e)}writeBytesField(t,e){this.writeTag(t,iu),this.writeBytes(e)}writeFixed32Field(t,e){this.writeTag(t,_f),this.writeFixed32(e)}writeSFixed32Field(t,e){this.writeTag(t,_f),this.writeSFixed32(e)}writeFixed64Field(t,e){this.writeTag(t,mf),this.writeFixed64(e)}writeSFixed64Field(t,e){this.writeTag(t,mf),this.writeSFixed64(e)}writeVarintField(t,e){this.writeTag(t,T_),this.writeVarint(e)}writeSVarintField(t,e){this.writeTag(t,T_),this.writeSVarint(e)}writeStringField(t,e){this.writeTag(t,iu),this.writeString(e)}writeFloatField(t,e){this.writeTag(t,_f),this.writeFloat(e)}writeDoubleField(t,e){this.writeTag(t,mf),this.writeDouble(e)}writeBooleanField(t,e){this.writeVarintField(t,+e)}}function KX(s,t,e){const i=e.buf;let n,r;if(r=i[e.pos++],n=(r&112)>>4,r<128||(r=i[e.pos++],n|=(r&127)<<3,r<128)||(r=i[e.pos++],n|=(r&127)<<10,r<128)||(r=i[e.pos++],n|=(r&127)<<17,r<128)||(r=i[e.pos++],n|=(r&127)<<24,r<128)||(r=i[e.pos++],n|=(r&1)<<31,r<128))return JX(s,n,t);throw new Error("Expected varint not more than 10 bytes")}function JX(s,t,e){return e?t*4294967296+(s>>>0):(t>>>0)*4294967296+(s>>>0)}function QX(s,t){let e,i;if(s>=0?(e=s%4294967296|0,i=s/4294967296|0):(e=~(-s%4294967296),i=~(-s/4294967296),e^4294967295?e=e+1|0:(e=0,i=i+1|0)),s>=18446744073709552e3||s<-18446744073709552e3)throw new Error("Given varint doesn't fit into 10 bytes");t.realloc(10),tV(e,i,t),eV(i,t)}function tV(s,t,e){e.buf[e.pos++]=s&127|128,s>>>=7,e.buf[e.pos++]=s&127|128,s>>>=7,e.buf[e.pos++]=s&127|128,s>>>=7,e.buf[e.pos++]=s&127|128,s>>>=7,e.buf[e.pos]=s&127}function eV(s,t){const e=(s&7)<<4;t.buf[t.pos++]|=e|((s>>>=3)?128:0),s&&(t.buf[t.pos++]=s&127|((s>>>=7)?128:0),s&&(t.buf[t.pos++]=s&127|((s>>>=7)?128:0),s&&(t.buf[t.pos++]=s&127|((s>>>=7)?128:0),s&&(t.buf[t.pos++]=s&127|((s>>>=7)?128:0),s&&(t.buf[t.pos++]=s&127)))))}function O2(s,t,e){const i=t<=16383?1:t<=2097151?2:t<=268435455?3:Math.floor(Math.log(t)/(Math.LN2*7));e.realloc(i);for(let n=e.pos-1;n>=s;n--)e.buf[n+i]=e.buf[n]}function sV(s,t){for(let e=0;e239?4:r>223?3:r>191?2:1;if(n+a>e)break;let l,h,c;a===1?r<128&&(o=r):a===2?(l=s[n+1],(l&192)===128&&(o=(r&31)<<6|l&63,o<=127&&(o=null))):a===3?(l=s[n+1],h=s[n+2],(l&192)===128&&(h&192)===128&&(o=(r&15)<<12|(l&63)<<6|h&63,(o<=2047||o>=55296&&o<=57343)&&(o=null))):a===4&&(l=s[n+1],h=s[n+2],c=s[n+3],(l&192)===128&&(h&192)===128&&(c&192)===128&&(o=(r&15)<<18|(l&63)<<12|(h&63)<<6|c&63,(o<=65535||o>=1114112)&&(o=null))),o===null?(o=65533,a=1):o>65535&&(o-=65536,i+=String.fromCharCode(o>>>10&1023|55296),o=56320|o&1023),i+=String.fromCharCode(o),n+=a}return i}function dV(s,t,e){for(let i=0,n,r;i55295&&n<57344)if(r)if(n<56320){s[e++]=239,s[e++]=191,s[e++]=189,r=n;continue}else n=r-55296<<10|n-56320|65536,r=null;else{n>56319||i+1===t.length?(s[e++]=239,s[e++]=191,s[e++]=189):r=n;continue}else r&&(s[e++]=239,s[e++]=191,s[e++]=189,r=null);n<128?s[e++]=n:(n<2048?s[e++]=n>>6|192:(n<65536?s[e++]=n>>12|224:(s[e++]=n>>18|240,s[e++]=n>>12&63|128),s[e++]=n>>6&63|128),s[e++]=n&63|128)}return e}class gV extends Sg{constructor(t){super(),t=t||{},this.dataProjection=new rc({code:"",units:"tile-pixels"}),this.featureClass=t.featureClass?t.featureClass:si,this.geometryName_=t.geometryName,this.layerName_=t.layerName?t.layerName:"layer",this.layers_=t.layers?t.layers:null,this.idProperty_=t.idProperty,this.supportedMediaTypes=["application/vnd.mapbox-vector-tile","application/x-protobuf"]}readRawGeometry_(t,e,i,n){t.pos=e.geometry;const r=t.readVarint()+t.pos;let o=1,a=0,l=0,h=0,c=0,u=0;for(;t.pos>3}if(a--,o===1||o===2)l+=t.readSVarint(),h+=t.readSVarint(),o===1&&c>u&&(n.push(c),u=c),i.push(l,h),c+=2;else if(o===7)c>u&&(i.push(i[u],i[u+1]),c+=2);else throw new Error("Invalid command found in the PBF")}c>u&&(n.push(c),u=c)}createFeature_(t,e,i){const n=e.type;if(n===0)return null;let r;const o=e.properties;let a;this.idProperty_?(a=o[this.idProperty_],delete o[this.idProperty_]):a=e.id,o[this.layerName_]=e.layer.name;const l=[],h=[];this.readRawGeometry_(t,e,l,h);const c=yV(n,h.length);if(this.featureClass===si)r=new this.featureClass(c,l,h,2,o,a),r.transform(i.dataProjection);else{let u;if(c=="Polygon"){const f=OI(l,h);u=f.length>1?new vn(l,"XY",f):new Hs(l,"XY",h)}else u=c==="Point"?new Ts(l,"XY"):c==="LineString"?new ls(l,"XY"):c==="MultiPoint"?new Zn(l,"XY"):c==="MultiLineString"?new Pi(l,"XY",h):null;const d=this.featureClass;r=new d,this.geometryName_&&r.setGeometryName(this.geometryName_);const g=De(u,!1,i);r.setGeometry(g),a!==void 0&&r.setId(a),r.setProperties(o,!0)}return r}getType(){return"arraybuffer"}readFeatures(t,e){const i=this.layers_;e=this.adaptOptions(e);const n=st(e.dataProjection);n.setWorldExtent(e.extent),e.dataProjection=n;const r=new HX(t),o=r.readFields(fV,{}),a=[];for(const l in o){if(i&&!i.includes(l))continue;const h=o[l],c=h?[0,0,h.extent,h.extent]:null;n.setExtent(c);for(let u=0,d=h.length;u>3,i=s===1?e.readString():s===2?e.readFloat():s===3?e.readDouble():s===4?e.readVarint64():s===5?e.readVarint():s===6?e.readSVarint():s===7?e.readBoolean():null;t.values.push(i)}}function mV(s,t,e){if(s==1)t.id=e.readVarint();else if(s==2){const i=e.readVarint()+e.pos;for(;e.pos>1):n>>1}return t}function sY(s){let t="";for(let e=0,i=s.length;e=32;)t=(32|s&31)+63,e+=String.fromCharCode(t),s>>=5;return t=s+63,e+=String.fromCharCode(t),e}const rY=ZV;class oY extends gv{constructor(t){super(),t=t||{},this.layerName_=t.layerName,this.layers_=t.layers?t.layers:null,this.dataProjection=st(t.dataProjection?t.dataProjection:"EPSG:4326")}readFeaturesFromObject(t,e){if(t.type=="Topology"){const i=t;let n,r=null,o=null;i.transform&&(n=i.transform,r=n.scale,o=n.translate);const a=i.arcs;n&&pY(a,r,o);const l=[],h=i.objects,c=this.layerName_;let u;for(const d in h)this.layers_&&!this.layers_.includes(d)||(h[d].type==="GeometryCollection"?(u=h[d],l.push.apply(l,fY(u,a,r,o,c,d,e))):(u=h[d],l.push(wP(u,a,r,o,c,d,e))));return l}return[]}readProjectionFromObject(t){return this.dataProjection}}const aY={Point:lY,LineString:cY,Polygon:dY,MultiPoint:hY,MultiLineString:uY,MultiPolygon:gY};function Km(s,t){const e=[];let i;for(let n=0,r=s.length;n0&&e.pop(),i>=0){const o=t[i];for(let a=0,l=o.length;a=0;--a)e.push(o[a].slice(0))}return e}function lY(s,t,e){const i=s.coordinates;return t&&e&&Pv(i,t,e),new Ts(i)}function hY(s,t,e){const i=s.coordinates;if(t&&e)for(let n=0,r=i.length;n=2,"At least 2 conditions are required")}}class xY extends yY{constructor(t){super("And",Array.prototype.slice.call(arguments))}}class vY extends EP{constructor(t,e,i){if(super("BBOX"),this.geometryName=t,this.extent=e,e.length!==4)throw new Error("Expected an extent with four values ([minX, minY, maxX, maxY])");this.srsName=i}}function wY(s){const t=[null].concat(Array.prototype.slice.call(arguments));return new(Function.prototype.bind.apply(xY,t))}function EY(s,t,e){return new vY(s,t,e)}const N2={"http://www.opengis.net/gml":{boundedBy:L(ut.prototype.readExtentElement,"bounds")},"http://www.opengis.net/wfs/2.0":{member:dt(ut.prototype.readFeaturesInternal)}},SY={"http://www.opengis.net/wfs":{totalInserted:L(qe),totalUpdated:L(qe),totalDeleted:L(qe)},"http://www.opengis.net/wfs/2.0":{totalInserted:L(qe),totalUpdated:L(qe),totalDeleted:L(qe)}},MY={"http://www.opengis.net/wfs":{TransactionSummary:L(k2,"transactionSummary"),InsertResults:L(G2,"insertIds")},"http://www.opengis.net/wfs/2.0":{TransactionSummary:L(k2,"transactionSummary"),InsertResults:L(G2,"insertIds")}},bY={"http://www.opengis.net/wfs":{PropertyName:N(Tt)},"http://www.opengis.net/wfs/2.0":{PropertyName:N(Tt)}},SP={"http://www.opengis.net/wfs":{Insert:N(j2),Update:N(U2),Delete:N(z2),Property:N(B2),Native:N(W2)},"http://www.opengis.net/wfs/2.0":{Insert:N(j2),Update:N(U2),Delete:N(z2),Property:N(B2),Native:N(W2)}},MP="feature",Av="http://www.w3.org/2000/xmlns/",Lv={"2.0.0":"http://www.opengis.net/ogc/1.1","1.1.0":"http://www.opengis.net/ogc","1.0.0":"http://www.opengis.net/ogc"},ry={"2.0.0":"http://www.opengis.net/wfs/2.0","1.1.0":"http://www.opengis.net/wfs","1.0.0":"http://www.opengis.net/wfs"},Ov={"2.0.0":"http://www.opengis.net/fes/2.0","1.1.0":"http://www.opengis.net/fes","1.0.0":"http://www.opengis.net/fes"},D2={"2.0.0":"http://www.opengis.net/wfs/2.0 http://schemas.opengis.net/wfs/2.0/wfs.xsd","1.1.0":"http://www.opengis.net/wfs http://schemas.opengis.net/wfs/1.1.0/wfs.xsd","1.0.0":"http://www.opengis.net/wfs http://schemas.opengis.net/wfs/1.0.0/wfs.xsd"},Fv={"2.0.0":ne,"1.1.0":Z,"1.0.0":Vt},TY="1.1.0";class CY extends bg{constructor(t){super(),t=t||{},this.version_=t.version?t.version:TY,this.featureType_=t.featureType,this.featureNS_=t.featureNS,this.gmlFormat_=t.gmlFormat?t.gmlFormat:new Fv[this.version_],this.schemaLocation_=t.schemaLocation?t.schemaLocation:D2[this.version_]}getFeatureType(){return this.featureType_}setFeatureType(t){this.featureType_=t}readFeaturesFromNode(t,e){const i={node:t};Object.assign(i,{featureType:this.featureType_,featureNS:this.featureNS_}),Object.assign(i,this.getReadOptions(t,e||{}));const n=[i];let r;this.version_==="2.0.0"?r=N2:r=this.gmlFormat_.FEATURE_COLLECTION_PARSERS;let o=Y([],r,t,n,this.gmlFormat_);return o||(o=[]),o}readTransactionResponse(t){if(t){if(typeof t=="string"){const e=dn(t);return this.readTransactionResponseFromDocument(e)}return un(t)?this.readTransactionResponseFromDocument(t):this.readTransactionResponseFromNode(t)}}readFeatureCollectionMetadata(t){if(t){if(typeof t=="string"){const e=dn(t);return this.readFeatureCollectionMetadataFromDocument(e)}return un(t)?this.readFeatureCollectionMetadataFromDocument(t):this.readFeatureCollectionMetadataFromNode(t)}}readFeatureCollectionMetadataFromDocument(t){for(let e=t.firstChild;e;e=e.nextSibling)if(e.nodeType==Node.ELEMENT_NODE)return this.readFeatureCollectionMetadataFromNode(e)}readFeatureCollectionMetadataFromNode(t){const e={},i=zr(t.getAttribute("numberOfFeatures"));return e.numberOfFeatures=i,Y(e,N2,t,[],this.gmlFormat_)}readTransactionResponseFromDocument(t){for(let e=t.firstChild;e;e=e.nextSibling)if(e.nodeType==Node.ELEMENT_NODE)return this.readTransactionResponseFromNode(e)}readTransactionResponseFromNode(t){return Y({},MY,t,[])}writeGetFeature(t){const e=It(ry[this.version_],"GetFeature");e.setAttribute("service","WFS"),e.setAttribute("version",this.version_),t.handle&&e.setAttribute("handle",t.handle),t.outputFormat&&e.setAttribute("outputFormat",t.outputFormat),t.maxFeatures!==void 0&&e.setAttribute("maxFeatures",String(t.maxFeatures)),t.resultType&&e.setAttribute("resultType",t.resultType),t.startIndex!==void 0&&e.setAttribute("startIndex",String(t.startIndex)),t.count!==void 0&&e.setAttribute("count",String(t.count)),t.viewParams!==void 0&&e.setAttribute("viewParams",t.viewParams),e.setAttributeNS(nl,"xsi:schemaLocation",this.schemaLocation_);const i={node:e};if(Object.assign(i,{version:this.version_,srsName:t.srsName,featureNS:t.featureNS?t.featureNS:this.featureNS_,featurePrefix:t.featurePrefix,propertyNames:t.propertyNames?t.propertyNames:[]}),qt(Array.isArray(t.featureTypes),"`options.featureTypes` must be an Array"),typeof t.featureTypes[0]=="string"){let n=t.filter;t.bbox&&(qt(t.geometryName,"`options.geometryName` must also be provided when `options.bbox` is set"),n=this.combineBboxAndFilter(t.geometryName,t.bbox,t.srsName,n)),Object.assign(i,{geometryName:t.geometryName,filter:n}),tM(e,t.featureTypes,[i])}else t.featureTypes.forEach(n=>{const r=this.combineBboxAndFilter(n.geometryName,n.bbox,t.srsName,t.filter);Object.assign(i,{geometryName:n.geometryName,filter:r}),tM(e,[n.name],[i])});return e}combineBboxAndFilter(t,e,i,n){const r=EY(t,e,i);return n?wY(n,r):r}writeTransaction(t,e,i,n){const r=[],o=n.version?n.version:this.version_,a=It(ry[o],"Transaction");a.setAttribute("service","WFS"),a.setAttribute("version",o);let l;n&&(l=n.gmlOptions?n.gmlOptions:{},n.handle&&a.setAttribute("handle",n.handle)),a.setAttributeNS(nl,"xsi:schemaLocation",D2[o]);const h=RY(a,l,o,n);return t&&yf("Insert",t,r,h),e&&yf("Update",e,r,h),i&&yf("Delete",i,r,h),n.nativeElements&&yf("Native",n.nativeElements,r,h),a}readProjectionFromDocument(t){for(let e=t.firstChild;e;e=e.nextSibling)if(e.nodeType==Node.ELEMENT_NODE)return this.readProjectionFromNode(e);return null}readProjectionFromNode(t){if(t.firstElementChild&&t.firstElementChild.firstElementChild){t=t.firstElementChild.firstElementChild;for(let e=t.firstElementChild;e;e=e.nextElementSibling)if(!(e.childNodes.length===0||e.childNodes.length===1&&e.firstChild.nodeType===3)){const i=[{}];return this.gmlFormat_.readGeometryElement(e,i),st(i.pop().srsName)}}return null}}function RY(s,t,e,i){const n=i.featurePrefix?i.featurePrefix:MP;let r;return e==="1.0.0"?r=2:e==="1.1.0"?r=3:e==="2.0.0"&&(r=3.2),Object.assign({node:s},{version:e,featureNS:i.featureNS,featureType:i.featureType,featurePrefix:n,gmlVersion:r,hasZ:i.hasZ,srsName:i.srsName},t)}function yf(s,t,e,i){Ct(i,SP,Xe(s),t,e)}function k2(s,t){return Y({},SY,s,t)}const IY={"http://www.opengis.net/ogc":{FeatureId:dt(function(s,t){return s.getAttribute("fid")})},"http://www.opengis.net/ogc/1.1":{FeatureId:dt(function(s,t){return s.getAttribute("fid")})}};function $2(s,t){Ii(IY,s,t)}const PY={"http://www.opengis.net/wfs":{Feature:$2},"http://www.opengis.net/wfs/2.0":{Feature:$2}};function G2(s,t){return Y([],PY,s,t)}function j2(s,t,e){const i=e[e.length-1],n=i.featureType,r=i.featureNS,o=i.gmlVersion,a=It(r,n);s.appendChild(a),o===2?Vt.prototype.writeFeatureElement(a,t,e):o===3?Z.prototype.writeFeatureElement(a,t,e):ne.prototype.writeFeatureElement(a,t,e)}function bP(s,t,e){const i=e[e.length-1].version,n=Lv[i],r=It(n,"Filter"),o=It(n,"FeatureId");r.appendChild(o),o.setAttribute("fid",t),s.appendChild(r)}function Nv(s,t){s=s||MP;const e=s+":";return t.startsWith(e)?t:e+t}function z2(s,t,e){const i=e[e.length-1];qt(t.getId()!==void 0,"Features must have an id set");const n=i.featureType,r=i.featurePrefix,o=i.featureNS,a=Nv(r,n);s.setAttribute("typeName",a),s.setAttributeNS(Av,"xmlns:"+r,o);const l=t.getId();l!==void 0&&bP(s,l,e)}function U2(s,t,e){const i=e[e.length-1];qt(t.getId()!==void 0,"Features must have an id set");const n=i.version,r=i.featureType,o=i.featurePrefix,a=i.featureNS,l=Nv(o,r),h=t.getGeometryName();s.setAttribute("typeName",l),s.setAttributeNS(Av,"xmlns:"+o,a);const c=t.getId();if(c!==void 0){const u=t.getKeys(),d=[];for(let g=0,f=u.length;g0,i=this.readUint32(e),n=Math.floor((i&268435455)/1e3),r=!!(i&2147483648)||n===1||n===3,o=!!(i&1073741824)||n===2||n===3,a=!!(i&536870912),l=(i&268435455)%1e3,h=["XY",r?"Z":"",o?"M":""].join(""),c=a?this.readUint32(e):null;if(t!==void 0&&t!==l)throw new Error("Unexpected WKB geometry type "+l);if(this.initialized_){if(this.isLittleEndian_!==e)throw new Error("Inconsistent endian");if(this.layout_!==h)throw new Error("Inconsistent geometry layout");if(c&&this.srid_!==c)throw new Error("Inconsistent coordinate system (SRID)")}else this.isLittleEndian_=e,this.hasZ_=r,this.hasM_=o,this.layout_=h,this.srid_=c,this.initialized_=!0;return l}readWkbPayload(t){switch(t){case pe.POINT:return this.readPoint();case pe.LINE_STRING:return this.readLineString();case pe.POLYGON:case pe.TRIANGLE:return this.readPolygon();case pe.MULTI_POINT:return this.readMultiPoint();case pe.MULTI_LINE_STRING:return this.readMultiLineString();case pe.MULTI_POLYGON:case pe.POLYHEDRAL_SURFACE:case pe.TIN:return this.readMultiPolygon();case pe.GEOMETRY_COLLECTION:return this.readGeometryCollection();default:throw new Error("Unsupported WKB geometry type "+t+" is found")}}readWkbBlock(t){return this.readWkbPayload(this.readWkbHeader(t))}readWkbCollection(t,e){const i=this.readUint32(),n=[];for(let r=0;r({[n]:t[r]})));for(const n of this.layout_)this.writeDouble(n in i?i[n]:this.nodata_[n])}writeLineString(t,e){this.writeUint32(t.length);for(let i=0;in===r?n:n==="XYZM"?r:r==="XYZM"?n:"XY";if(t instanceof io)return i(t.getLayout(),e);if(t instanceof _s){const n=t.getGeometriesArray();for(let r=0;rr+o[0],0),e=new ArrayBuffer(t),i=new DataView(e);let n=0;return this.writeQueue_.forEach(r=>{switch(r[0]){case 1:i.setUint8(n,r[1]);break;case 4:i.setUint32(n,r[1],this.isLittleEndian_);break;case 8:i.setFloat64(n,r[1],this.isLittleEndian_);break}n+=r[0]}),e}}class NY extends Sg{constructor(t){super(),t=t||{},this.splitCollection=!!t.splitCollection,this.viewCache_=null,this.hex_=t.hex!==!1,this.littleEndian_=t.littleEndian!==!1,this.ewkb_=t.ewkb!==!1,this.layout_=t.geometryLayout,this.nodataZ_=t.nodataZ||0,this.nodataM_=t.nodataM||0,this.srid_=t.srid}getType(){return this.hex_?"text":"arraybuffer"}readFeature(t,e){return new ys({geometry:this.readGeometry(t,e)})}readFeatures(t,e){let i=[];const n=this.readGeometry(t,e);return this.splitCollection&&n instanceof _s?i=n.getGeometriesArray():i=[n],i.map(r=>new ys({geometry:r}))}readGeometry(t,e){const i=sM(t);if(!i)return null;const n=new eM(i).readGeometry();return this.viewCache_=i,e=this.getReadOptions(t,e),this.viewCache_=null,De(n,!1,e)}readProjection(t){const e=this.viewCache_||sM(t);if(!e)return;const i=new eM(e);return i.readWkbHeader(),i.getSrid()&&st("EPSG:"+i.getSrid())||void 0}writeFeature(t,e){return this.writeGeometry(t.getGeometry(),e)}writeFeatures(t,e){return this.writeGeometry(new _s(t.map(i=>i.getGeometry())),e)}writeGeometry(t,e){e=this.adaptOptions(e);const i=new FY({layout:this.layout_,littleEndian:this.littleEndian_,ewkb:this.ewkb_,nodata:{Z:this.nodataZ_,M:this.nodataM_}});let n=Number.isInteger(this.srid_)?Number(this.srid_):null;if(this.srid_!==!1&&!Number.isInteger(this.srid_)){const o=e.dataProjection&&st(e.dataProjection);if(o){const a=o.getCode();a.startsWith("EPSG:")&&(n=Number(a.substring(5)))}}i.writeGeometry(De(t,!0,e),n);const r=i.getBuffer();return this.hex_?DY(r):r}}function DY(s){const t=new Uint8Array(s);return Array.from(t.values()).map(e=>(e<16?"0":"")+Number(e).toString(16).toUpperCase()).join("")}function kY(s){const t=new Uint8Array(s.length/2);for(let e=0;e="a"&&t<="z"||t>="A"&&t<="Z"}isNumeric_(t,e){return e=e!==void 0?e:!1,t>="0"&&t<="9"||t=="."&&!e}isWhiteSpace_(t){return t==" "||t==" "||t=="\r"||t==` -`}nextChar_(){return this.wkt.charAt(++this.index_)}nextToken(){const t=this.nextChar_(),e=this.index_;let i=t,n;if(t=="(")n=ce.LEFT_PAREN;else if(t==",")n=ce.COMMA;else if(t==")")n=ce.RIGHT_PAREN;else if(this.isNumeric_(t)||t=="-")n=ce.NUMBER,i=this.readNumber_();else if(this.isAlpha_(t))n=ce.TEXT,i=this.readText_();else{if(this.isWhiteSpace_(t))return this.nextToken();if(t==="")n=ce.EOF;else throw new Error("Unexpected character: "+t)}return{position:e,value:i,type:n}}readNumber_(){let t;const e=this.index_;let i=!1,n=!1;do t=="."?i=!0:(t=="e"||t=="E")&&(n=!0),t=this.nextChar_();while(this.isNumeric_(t,i)||!n&&(t=="e"||t=="E")||n&&(t=="-"||t=="+"));return parseFloat(this.wkt.substring(e,this.index_--))}readText_(){let t;const e=this.index_;do t=this.nextChar_();while(this.isAlpha_(t));return this.wkt.substring(e,this.index_--).toUpperCase()}}let BY=class{constructor(s){this.lexer_=s,this.token_={position:0,type:ce.START},this.layout_="XY"}consume_(){this.token_=this.lexer_.nextToken()}isTokenType(s){return this.token_.type==s}match(s){const t=this.isTokenType(s);return t&&this.consume_(),t}parse(){return this.consume_(),this.parseGeometry_()}parseGeometryLayout_(){let s="XY";const t=this.token_;if(this.isTokenType(ce.TEXT)){const e=t.value;e===CP?s="XYZ":e===RP?s="XYM":e===jY&&(s="XYZM"),s!=="XY"&&this.consume_()}return s}parseGeometryCollectionText_(){if(this.match(ce.LEFT_PAREN)){const s=[];do s.push(this.parseGeometry_());while(this.match(ce.COMMA));if(this.match(ce.RIGHT_PAREN))return s}throw new Error(this.formatErrorMessage_())}parsePointText_(){if(this.match(ce.LEFT_PAREN)){const s=this.parsePoint_();if(this.match(ce.RIGHT_PAREN))return s}throw new Error(this.formatErrorMessage_())}parseLineStringText_(){if(this.match(ce.LEFT_PAREN)){const s=this.parsePointList_();if(this.match(ce.RIGHT_PAREN))return s}throw new Error(this.formatErrorMessage_())}parsePolygonText_(){if(this.match(ce.LEFT_PAREN)){const s=this.parseLineStringTextList_();if(this.match(ce.RIGHT_PAREN))return s}throw new Error(this.formatErrorMessage_())}parseMultiPointText_(){if(this.match(ce.LEFT_PAREN)){let s;if(this.token_.type==ce.LEFT_PAREN?s=this.parsePointTextList_():s=this.parsePointList_(),this.match(ce.RIGHT_PAREN))return s}throw new Error(this.formatErrorMessage_())}parseMultiLineStringText_(){if(this.match(ce.LEFT_PAREN)){const s=this.parseLineStringTextList_();if(this.match(ce.RIGHT_PAREN))return s}throw new Error(this.formatErrorMessage_())}parseMultiPolygonText_(){if(this.match(ce.LEFT_PAREN)){const s=this.parsePolygonTextList_();if(this.match(ce.RIGHT_PAREN))return s}throw new Error(this.formatErrorMessage_())}parsePoint_(){const s=[],t=this.layout_.length;for(let e=0;e0&&(n+=" "+r)}return i.length===0?n+" "+TP:n+"("+i+")"}const KY=WY,$s=[null,"http://www.opengis.net/wms"],JY=B($s,{Service:L(xq),Capability:L(yq)}),QY=B($s,{Request:L(Tq),Exception:L(Sq),Layer:L(Mq)});class tq extends Iv{constructor(){super(),this.version=void 0}readFromNode(t){return this.version=t.getAttribute("version").trim(),Y({version:this.version},JY,t,[])||null}}const eq=B($s,{Name:L(q),Title:L(q),Abstract:L(q),KeywordList:L(NP),OnlineResource:L(Ic),ContactInformation:L(vq),Fees:L(q),AccessConstraints:L(q),LayerLimit:L(qe),MaxWidth:L(qe),MaxHeight:L(qe)}),sq=B($s,{ContactPersonPrimary:L(wq),ContactPosition:L(q),ContactAddress:L(Eq),ContactVoiceTelephone:L(q),ContactFacsimileTelephone:L(q),ContactElectronicMailAddress:L(q)}),iq=B($s,{ContactPerson:L(q),ContactOrganization:L(q)}),nq=B($s,{AddressType:L(q),Address:L(q),City:L(q),StateOrProvince:L(q),PostCode:L(q),Country:L(q)}),rq=B($s,{Format:dt(q)}),LP=B($s,{Name:L(q),Title:L(q),Abstract:L(q),KeywordList:L(NP),CRS:Me(q),EX_GeographicBoundingBox:L(_q),BoundingBox:Me(mq),Dimension:Me(bq),Attribution:L(pq),AuthorityURL:Me(Iq),Identifier:Me(q),MetadataURL:Me(Pq),DataURL:Me(no),FeatureListURL:Me(no),Style:Me(Aq),MinScaleDenominator:L(Yt),MaxScaleDenominator:L(Yt),Layer:Me(OP)}),oq=B($s,{Title:L(q),OnlineResource:L(Ic),LogoURL:L(FP)}),aq=B($s,{westBoundLongitude:L(Yt),eastBoundLongitude:L(Yt),southBoundLatitude:L(Yt),northBoundLatitude:L(Yt)}),lq=B($s,{GetCapabilities:L(C_),GetMap:L(C_),GetFeatureInfo:L(C_)}),hq=B($s,{Format:Me(q),DCPType:Me(Cq)}),cq=B($s,{HTTP:L(Rq)}),uq=B($s,{Get:L(no),Post:L(no)}),dq=B($s,{Name:L(q),Title:L(q),Abstract:L(q),LegendURL:Me(FP),StyleSheetURL:L(no),StyleURL:L(no)}),gq=B($s,{Format:L(q),OnlineResource:L(Ic)}),fq=B($s,{Keyword:dt(q)});function pq(s,t){return Y({},oq,s,t)}function mq(s,t){const e=[Dr(s.getAttribute("minx")),Dr(s.getAttribute("miny")),Dr(s.getAttribute("maxx")),Dr(s.getAttribute("maxy"))],i=[Dr(s.getAttribute("resx")),Dr(s.getAttribute("resy"))];return{crs:s.getAttribute("CRS"),extent:e,res:i}}function _q(s,t){const e=Y({},aq,s,t);if(!e)return;const i=e.westBoundLongitude,n=e.southBoundLatitude,r=e.eastBoundLongitude,o=e.northBoundLatitude;if(!(i===void 0||n===void 0||r===void 0||o===void 0))return[i,n,r,o]}function yq(s,t){return Y({},QY,s,t)}function xq(s,t){return Y({},eq,s,t)}function vq(s,t){return Y({},sq,s,t)}function wq(s,t){return Y({},iq,s,t)}function Eq(s,t){return Y({},nq,s,t)}function Sq(s,t){return Y([],rq,s,t)}function Mq(s,t){const e=Y({},LP,s,t);return e.Layer===void 0?Object.assign(e,OP(s,t)):e}function OP(s,t){const e=t[t.length-1],i=Y({},LP,s,t);if(!i)return;let n=Va(s.getAttribute("queryable"));n===void 0&&(n=e.queryable),i.queryable=n!==void 0?n:!1;let r=zr(s.getAttribute("cascaded"));r===void 0&&(r=e.cascaded),i.cascaded=r;let o=Va(s.getAttribute("opaque"));o===void 0&&(o=e.opaque),i.opaque=o!==void 0?o:!1;let a=Va(s.getAttribute("noSubsets"));a===void 0&&(a=e.noSubsets),i.noSubsets=a!==void 0?a:!1;let l=Dr(s.getAttribute("fixedWidth"));l||(l=e.fixedWidth),i.fixedWidth=l;let h=Dr(s.getAttribute("fixedHeight"));return h||(h=e.fixedHeight),i.fixedHeight=h,["Style","CRS","AuthorityURL"].forEach(function(c){if(c in e){const u=i[c]||[];i[c]=u.concat(e[c])}}),["EX_GeographicBoundingBox","BoundingBox","Dimension","Attribution","MinScaleDenominator","MaxScaleDenominator"].forEach(function(c){if(!(c in i)){const u=e[c];i[c]=u}}),i}function bq(s,t){return{name:s.getAttribute("name"),units:s.getAttribute("units"),unitSymbol:s.getAttribute("unitSymbol"),default:s.getAttribute("default"),multipleValues:Va(s.getAttribute("multipleValues")),nearestValue:Va(s.getAttribute("nearestValue")),current:Va(s.getAttribute("current")),values:q(s)}}function no(s,t){return Y({},gq,s,t)}function Tq(s,t){return Y({},lq,s,t)}function Cq(s,t){return Y({},cq,s,t)}function Rq(s,t){return Y({},uq,s,t)}function C_(s,t){return Y({},hq,s,t)}function FP(s,t){const e=no(s,t);if(e){const i=[zr(s.getAttribute("width")),zr(s.getAttribute("height"))];return e.size=i,e}}function Iq(s,t){const e=no(s,t);if(e)return e.name=s.getAttribute("name"),e}function Pq(s,t){const e=no(s,t);if(e)return e.type=s.getAttribute("type"),e}function Aq(s,t){return Y({},dq,s,t)}function NP(s,t){return Y([],fq,s,t)}const Lq=tq,Oq="_feature",Fq="_layer";class Nq extends bg{constructor(t){super(),t=t||{},this.featureNS_="http://mapserver.gis.umn.edu/mapserver",this.gmlFormat_=new Vt,this.layers_=t.layers?t.layers:null}getLayers(){return this.layers_}setLayers(t){this.layers_=t}readFeatures_(t,e){t.setAttribute("namespaceURI",this.featureNS_);const i=t.localName;let n=[];if(t.childNodes.length===0)return n;if(i=="msGMLOutput")for(let r=0,o=t.childNodes.length;r0;)this.pop()}extend(s){for(let t=0,e=s.length;tthis.getLength())throw new Error("Index out of bounds: "+s);this.unique_&&this.assertUnique_(t),this.array_.splice(s,0,t),this.updateLength_(),this.dispatchEvent(new vf(Yo.ADD,t,s))}pop(){return this.removeAt(this.getLength()-1)}push(s){this.unique_&&this.assertUnique_(s);const t=this.getLength();return this.insertAt(t,s),this.getLength()}remove(s){const t=this.array_;for(let e=0,i=t.length;e=this.getLength())return;const t=this.array_[s];return this.array_.splice(s,1),this.updateLength_(),this.dispatchEvent(new vf(Yo.REMOVE,t,s)),t}setAt(s,t){const e=this.getLength();if(s>=e){this.insertAt(s,t);return}if(s<0)throw new Error("Index out of bounds: "+s);this.unique_&&this.assertUnique_(t,s);const i=this.array_[s];this.array_[s]=t,this.dispatchEvent(new vf(Yo.REMOVE,i,s)),this.dispatchEvent(new vf(Yo.ADD,t,s))}updateLength_(){this.set(iM.LENGTH,this.array_.length)}assertUnique_(s,t){for(let e=0,i=this.array_.length;eg&&(d=(g+d)/2,g=d),f>p&&(f=(p+f)/2,p=f);let m=Dt(i[0],d,g),_=Dt(i[1],f,p);if(o&&e&&n){const y=30*n;m+=-y*Math.log(1+Math.max(0,d-i[0])/y)+y*Math.log(1+Math.max(0,i[0]-g)/y),_+=-y*Math.log(1+Math.max(0,f-i[1])/y)+y*Math.log(1+Math.max(0,i[1]-p)/y)}return[m,_]}}function aZ(s){return s}function $v(s,t,e,i){const n=Rt(t)/e[0],r=Ee(t)/e[1];return i?Math.min(s,Math.max(n,r)):Math.min(s,Math.min(n,r))}function Gv(s,t,e){let i=Math.min(s,t);const n=50;return i*=Math.log(1+n*Math.max(0,s/t-1))/n+1,e&&(i=Math.max(i,e),i/=Math.log(1+n*Math.max(0,e/s-1))/n+1),Dt(i,e/2,t*2)}function lZ(s,t,e,i){return t=t!==void 0?t:!0,function(n,r,o,a){if(n!==void 0){const l=s[0],h=s[s.length-1],c=e?$v(l,e,o,i):l;if(a)return t?Gv(n,c,h):Dt(n,h,c);const u=Math.min(c,n),d=Math.floor(Om(s,u,r));return s[d]>c&&d1&&typeof arguments[e-1]=="function"&&(i=arguments[e-1],--e);let n=0;for(;n0}getInteracting(){return this.hints_[Ie.INTERACTING]>0}cancelAnimations(){this.setHint(Ie.ANIMATING,-this.hints_[Ie.ANIMATING]);let t;for(let e=0,i=this.animations_.length;e=0;--i){const n=this.animations_[i];let r=!0;for(let o=0,a=n.length;o0?h/l.duration:1;c>=1?(l.complete=!0,c=1):r=!1;const u=l.easing(c);if(l.sourceCenter){const d=l.sourceCenter[0],g=l.sourceCenter[1],f=l.targetCenter[0],p=l.targetCenter[1];this.nextCenter_=l.targetCenter;const m=d+u*(f-d),_=g+u*(p-g);this.targetCenter_=[m,_]}if(l.sourceResolution&&l.targetResolution){const d=u===1?l.targetResolution:l.sourceResolution+u*(l.targetResolution-l.sourceResolution);if(l.anchor){const g=this.getViewportSize_(this.getRotation()),f=this.constraints_.resolution(d,0,g,!0);this.targetCenter_=this.calculateCenterZoom(f,l.anchor)}this.nextResolution_=l.targetResolution,this.targetResolution_=d,this.applyTargetState_(!0)}if(l.sourceRotation!==void 0&&l.targetRotation!==void 0){const d=u===1?kn(l.targetRotation+Math.PI,2*Math.PI)-Math.PI:l.sourceRotation+u*(l.targetRotation-l.sourceRotation);if(l.anchor){const g=this.constraints_.rotation(d,!0);this.targetCenter_=this.calculateCenterRotate(g,l.anchor)}this.nextRotation_=l.targetRotation,this.targetRotation_=d}if(this.applyTargetState_(!0),e=!0,!l.complete)break}if(r){this.animations_[i]=null,this.setHint(Ie.ANIMATING,-1),this.nextCenter_=null,this.nextResolution_=NaN,this.nextRotation_=NaN;const o=n[0].callback;o&&wf(o,!0)}}this.animations_=this.animations_.filter(Boolean),e&&this.updateAnimationKey_===void 0&&(this.updateAnimationKey_=requestAnimationFrame(this.updateAnimations_.bind(this)))}calculateCenterRotate(t,e){let i;const n=this.getCenterInternal();return n!==void 0&&(i=[n[0]-e[0],n[1]-e[1]],S9(i,t-this.getRotation()),mI(i,e)),i}calculateCenterZoom(t,e){let i;const n=this.getCenterInternal(),r=this.getResolution();if(n!==void 0&&r!==void 0){const o=e[0]-t*(e[0]-n[0])/r,a=e[1]-t*(e[1]-n[1])/r;i=[o,a]}return i}getViewportSize_(t){const e=this.viewportSize_;if(t){const i=e[0],n=e[1];return[Math.abs(i*Math.cos(t))+Math.abs(n*Math.sin(t)),Math.abs(i*Math.sin(t))+Math.abs(n*Math.cos(t))]}return e}setViewportSize(t){this.viewportSize_=Array.isArray(t)?t.slice():[100,100],this.getAnimating()||this.resolveConstraints(0)}getCenter(){const t=this.getCenterInternal();return t&&X1(t,this.getProjection())}getCenterInternal(){return this.get(Rn.CENTER)}getConstraints(){return this.constraints_}getConstrainResolution(){return this.get("constrainResolution")}getHints(t){return t!==void 0?(t[0]=this.hints_[0],t[1]=this.hints_[1],t):this.hints_.slice()}calculateExtent(t){const e=this.calculateExtentInternal(t);return km(e,this.getProjection())}calculateExtentInternal(t){t=t||this.getViewportSizeMinusPadding_();const e=this.getCenterInternal();qt(e,"The view center is not defined");const i=this.getResolution();qt(i!==void 0,"The view resolution is not defined");const n=this.getRotation();return qt(n!==void 0,"The view rotation is not defined"),qx(e,i,n,t)}getMaxResolution(){return this.maxResolution_}getMinResolution(){return this.minResolution_}getMaxZoom(){return this.getZoomForResolution(this.minResolution_)}setMaxZoom(t){this.applyOptions_(this.getUpdatedOptions_({maxZoom:t}))}getMinZoom(){return this.getZoomForResolution(this.maxResolution_)}setMinZoom(t){this.applyOptions_(this.getUpdatedOptions_({minZoom:t}))}setConstrainResolution(t){this.applyOptions_(this.getUpdatedOptions_({constrainResolution:t}))}getProjection(){return this.projection_}getResolution(){return this.get(Rn.RESOLUTION)}getResolutions(){return this.resolutions_}getResolutionForExtent(t,e){return this.getResolutionForExtentInternal(cn(t,this.getProjection()),e)}getResolutionForExtentInternal(t,e){e=e||this.getViewportSizeMinusPadding_();const i=Rt(t)/e[0],n=Ee(t)/e[1];return Math.max(i,n)}getResolutionForValueFunction(t){t=t||2;const e=this.getConstrainedResolution(this.maxResolution_),i=this.minResolution_,n=Math.log(e/i)/Math.log(t);return function(r){return e/Math.pow(t,r*n)}}getRotation(){return this.get(Rn.ROTATION)}getValueForResolutionFunction(t){const e=Math.log(t||2),i=this.getConstrainedResolution(this.maxResolution_),n=this.minResolution_,r=Math.log(i/n)/e;return function(o){return Math.log(i/o)/e/r}}getViewportSizeMinusPadding_(t){let e=this.getViewportSize_(t);const i=this.padding_;return i&&(e=[e[0]-i[1]-i[3],e[1]-i[0]-i[2]]),e}getState(){const t=this.getProjection(),e=this.getResolution(),i=this.getRotation();let n=this.getCenterInternal();const r=this.padding_;if(r){const o=this.getViewportSizeMinusPadding_();n=I_(n,this.getViewportSize_(),[o[0]/2+r[3],o[1]/2+r[0]],e,i)}return{center:n.slice(0),projection:t!==void 0?t:null,resolution:e,nextCenter:this.nextCenter_,nextResolution:this.nextResolution_,nextRotation:this.nextRotation_,rotation:i,zoom:this.getZoom()}}getViewStateAndExtent(){return{viewState:this.getState(),extent:this.calculateExtent()}}getZoom(){let t;const e=this.getResolution();return e!==void 0&&(t=this.getZoomForResolution(e)),t}getZoomForResolution(t){let e=this.minZoom_||0,i,n;if(this.resolutions_){const r=Om(this.resolutions_,t,1);e=r,i=this.resolutions_[r],r==this.resolutions_.length-1?n=2:n=i/this.resolutions_[r+1]}else i=this.maxResolution_,n=this.zoomFactor_;return e+Math.log(i/t)/Math.log(n)}getResolutionForZoom(t){if(this.resolutions_){if(this.resolutions_.length<=1)return 0;const e=Dt(Math.floor(t),0,this.resolutions_.length-2),i=this.resolutions_[e]/this.resolutions_[e+1];return this.resolutions_[e]/Math.pow(i,Dt(t-e,0,1))}return this.maxResolution_/Math.pow(this.zoomFactor_,t-this.minZoom_)}fit(t,e){let i;if(qt(Array.isArray(t)||typeof t.getSimplifiedGeometry=="function","Invalid extent or geometry provided as `geometry`"),Array.isArray(t)){qt(!po(t),"Cannot fit empty extent provided as `geometry`");const n=cn(t,this.getProjection());i=g2(n)}else if(t.getType()==="Circle"){const n=cn(t.getExtent(),this.getProjection());i=g2(n),i.rotate(this.getRotation(),Rs(n))}else i=t;this.fitInternal(i,e)}rotatedExtentForGeometry(t){const e=this.getRotation(),i=Math.cos(e),n=Math.sin(-e),r=t.getFlatCoordinates(),o=t.getStride();let a=1/0,l=1/0,h=-1/0,c=-1/0;for(let u=0,d=r.length;u{this.dispatchEvent("sourceready")},0))),this.changed()}getFeatures(t){return this.renderer_?this.renderer_.getFeatures(t):Promise.resolve([])}getData(t){return!this.renderer_||!this.rendered?null:this.renderer_.getData(t)}isVisible(t){let e;const i=this.getMapInternal();!t&&i&&(t=i.getView()),t instanceof aM?e={viewState:t.getState(),extent:t.calculateExtent()}:e=t,!e.layerStatesArray&&i&&(e.layerStatesArray=i.getLayerGroup().getLayerStatesArray());let n;e.layerStatesArray?n=e.layerStatesArray.find(o=>o.layer===this):n=this.getLayerState();const r=this.getExtent();return vZ(n,e.viewState)&&(!r||Te(r,e.extent))}getAttributions(t){var e;if(!this.isVisible(t))return[];const i=(e=this.getSource())==null?void 0:e.getAttributions();if(!i)return[];const n=t instanceof aM?t.getViewStateAndExtent():t;let r=i(n);return Array.isArray(r)||(r=[r]),r}render(t,e){const i=this.getRenderer();return i.prepareFrame(t)?(this.rendered=!0,i.renderFrame(t,e)):null}unrender(){this.rendered=!1}getDeclutter(){}renderDeclutter(t,e){}renderDeferred(t){const e=this.getRenderer();e&&e.renderDeferred(t)}setMapInternal(t){t||this.unrender(),this.set(ue.MAP,t)}getMapInternal(){return this.get(ue.MAP)}setMap(t){this.mapPrecomposeKey_&&(ms(this.mapPrecomposeKey_),this.mapPrecomposeKey_=null),t||this.changed(),this.mapRenderKey_&&(ms(this.mapRenderKey_),this.mapRenderKey_=null),t&&(this.mapPrecomposeKey_=We(t,Mi.PRECOMPOSE,e=>{const i=e.frameState.layerStatesArray,n=this.getLayerState(!1);qt(!i.some(function(r){return r.layer===n.layer}),"A layer can only be added to the map once. Use either `layer.setMap()` or `map.addLayer()`, not both."),i.push(n)}),this.mapRenderKey_=We(this,Zt.CHANGE,t.render,t),this.changed())}setSource(t){this.set(ue.SOURCE,t)}getRenderer(){return this.renderer_||(this.renderer_=this.createRenderer()),this.renderer_}hasRenderer(){return!!this.renderer_}createRenderer(){return null}disposeInternal(){this.renderer_&&(this.renderer_.dispose(),delete this.renderer_),this.setSource(null),super.disposeInternal()}}function vZ(s,t){if(!s.visible)return!1;const e=t.resolution;if(e=s.maxResolution)return!1;const i=t.zoom;return i>s.minZoom&&i<=s.maxZoom}const Cg=xZ;function wZ(s,t,e,i,n){zP(s,t,e||0,i||s.length-1,n||EZ)}function zP(s,t,e,i,n){for(;i>e;){if(i-e>600){var r=i-e+1,o=t-e+1,a=Math.log(r),l=.5*Math.exp(2*a/3),h=.5*Math.sqrt(a*l*(r-l)/r)*(o-r/2<0?-1:1),c=Math.max(e,Math.floor(t-o*l/r+h)),u=Math.min(i,Math.floor(t+(r-o)*l/r+h));zP(s,t,c,u,n)}var d=s[t],g=e,f=i;for(nu(s,e,t),n(s[i],d)>0&&nu(s,e,i);g0;)f--}n(s[e],d)===0?nu(s,e,f):(f++,nu(s,f,i)),f<=t&&(e=f+1),t<=f&&(i=f-1)}}function nu(s,t,e){var i=s[t];s[t]=s[e],s[e]=i}function EZ(s,t){return st?1:0}let jv=class{constructor(s=9){this._maxEntries=Math.max(4,s),this._minEntries=Math.max(2,Math.ceil(this._maxEntries*.4)),this.clear()}all(){return this._all(this.data,[])}search(s){let t=this.data;const e=[];if(!Sf(s,t))return e;const i=this.toBBox,n=[];for(;t;){for(let r=0;r=0&&n[t].children.length>this._maxEntries;)this._split(n,t),t--;this._adjustParentBBoxes(i,n,t)}_split(s,t){const e=s[t],i=e.children.length,n=this._minEntries;this._chooseSplitAxis(e,n,i);const r=this._chooseSplitIndex(e,n,i),o=Kl(e.children.splice(r,e.children.length-r));o.height=e.height,o.leaf=e.leaf,Nl(e,this.toBBox),Nl(o,this.toBBox),t?s[t-1].children.push(o):this._splitRoot(e,o)}_splitRoot(s,t){this.data=Kl([s,t]),this.data.height=s.height+1,this.data.leaf=!1,Nl(this.data,this.toBBox)}_chooseSplitIndex(s,t,e){let i,n=1/0,r=1/0;for(let o=t;o<=e-t;o++){const a=vu(s,0,o,this.toBBox),l=vu(s,o,e,this.toBBox),h=CZ(a,l),c=P_(a)+P_(l);h=t;l--){const h=s.children[l];wu(o,s.leaf?n(h):h),a+=Ef(o)}return a}_adjustParentBBoxes(s,t,e){for(let i=e;i>=0;i--)wu(t[i],s)}_condense(s){for(let t=s.length-1,e;t>=0;t--)s[t].children.length===0?t>0?(e=s[t-1].children,e.splice(e.indexOf(s[t]),1)):this.clear():Nl(s[t],this.toBBox)}};function SZ(s,t,e){if(!e)return t.indexOf(s);for(let i=0;i=s.minX&&t.maxY>=s.minY}function Kl(s){return{children:s,height:1,leaf:!0,minX:1/0,minY:1/0,maxX:-1/0,maxY:-1/0}}function lM(s,t,e,i,n){const r=[t,e];for(;r.length;){if(e=r.pop(),t=r.pop(),e-t<=i)continue;const o=t+Math.ceil((e-t)/i/2)*i;wZ(s,o,t,e,n),r.push(t,o,o,e)}}let bl=0;const Os=1<",GreaterThanOrEqualTo:">=",LessThan:"<",LessThanOrEqualTo:"<=",Multiply:"*",Divide:"/",Add:"+",Subtract:"-",Clamp:"clamp",Mod:"%",Pow:"^",Abs:"abs",Floor:"floor",Ceil:"ceil",Round:"round",Sin:"sin",Cos:"cos",Atan:"atan",Sqrt:"sqrt",Match:"match",Between:"between",Interpolate:"interpolate",Coalesce:"coalesce",Case:"case",In:"in",Number:"number",String:"string",Array:"array",Color:"color",Id:"id",Band:"band",Palette:"palette",ToString:"to-string"},PZ={[U.Get]:Nt(Xt(1,1/0),AZ),[U.Var]:Nt(Xt(1,1),LZ),[U.Id]:Nt(OZ,ru),[U.Concat]:Nt(Xt(2,1/0),he(bs)),[U.GeometryType]:Nt(FZ,ru),[U.Resolution]:Nt(ru),[U.Zoom]:Nt(ru),[U.Time]:Nt(ru),[U.Any]:Nt(Xt(2,1/0),he(Os)),[U.All]:Nt(Xt(2,1/0),he(Os)),[U.Not]:Nt(Xt(1,1),he(Os)),[U.Equal]:Nt(Xt(2,2),he(Mf)),[U.NotEqual]:Nt(Xt(2,2),he(Mf)),[U.GreaterThan]:Nt(Xt(2,2),he(lt)),[U.GreaterThanOrEqualTo]:Nt(Xt(2,2),he(lt)),[U.LessThan]:Nt(Xt(2,2),he(lt)),[U.LessThanOrEqualTo]:Nt(Xt(2,2),he(lt)),[U.Multiply]:Nt(Xt(2,1/0),hM),[U.Coalesce]:Nt(Xt(2,1/0),hM),[U.Divide]:Nt(Xt(2,2),he(lt)),[U.Add]:Nt(Xt(2,1/0),he(lt)),[U.Subtract]:Nt(Xt(2,2),he(lt)),[U.Clamp]:Nt(Xt(3,3),he(lt)),[U.Mod]:Nt(Xt(2,2),he(lt)),[U.Pow]:Nt(Xt(2,2),he(lt)),[U.Abs]:Nt(Xt(1,1),he(lt)),[U.Floor]:Nt(Xt(1,1),he(lt)),[U.Ceil]:Nt(Xt(1,1),he(lt)),[U.Round]:Nt(Xt(1,1),he(lt)),[U.Sin]:Nt(Xt(1,1),he(lt)),[U.Cos]:Nt(Xt(1,1),he(lt)),[U.Atan]:Nt(Xt(1,2),he(lt)),[U.Sqrt]:Nt(Xt(1,1),he(lt)),[U.Match]:Nt(Xt(4,1/0),cM,DZ),[U.Between]:Nt(Xt(3,3),he(lt)),[U.Interpolate]:Nt(Xt(6,1/0),cM,kZ),[U.Case]:Nt(Xt(3,1/0),NZ,$Z),[U.In]:Nt(Xt(2,2),GZ),[U.Number]:Nt(Xt(1,1/0),he(Mf)),[U.String]:Nt(Xt(1,1/0),he(Mf)),[U.Array]:Nt(Xt(1,1/0),he(lt)),[U.Color]:Nt(Xt(1,4),he(lt)),[U.Band]:Nt(Xt(1,3),he(lt)),[U.Palette]:Nt(Xt(2,2),jZ),[U.ToString]:Nt(Xt(1,1),he(Os|lt|bs|$e))};function AZ(s,t,e){const i=s.length-1,n=new Array(i);for(let r=0;rt){const a=t===1/0?`${s} or more`:`${s} to ${t}`;throw new Error(`expected ${a} arguments for ${r}, got ${o}`)}}}function hM(s,t,e){const i=s.length-1,n=new Array(i);for(let r=0;ri.featureId;case U.GeometryType:return i=>i.geometryType;case U.Concat:{const i=s.args.map(n=>Xn(n));return n=>"".concat(...i.map(r=>r(n).toString()))}case U.Resolution:return i=>i.resolution;case U.Any:case U.All:case U.Between:case U.In:case U.Not:return XZ(s);case U.Equal:case U.NotEqual:case U.LessThan:case U.LessThanOrEqualTo:case U.GreaterThan:case U.GreaterThanOrEqualTo:return WZ(s);case U.Multiply:case U.Divide:case U.Add:case U.Subtract:case U.Clamp:case U.Mod:case U.Pow:case U.Abs:case U.Floor:case U.Ceil:case U.Round:case U.Sin:case U.Cos:case U.Atan:case U.Sqrt:return VZ(s);case U.Case:return YZ(s);case U.Match:return qZ(s);case U.Interpolate:return ZZ(s);case U.ToString:return HZ(s);default:throw new Error(`Unsupported operator ${e}`)}}function UZ(s,t){const e=s.operator,i=s.args.length,n=new Array(i);for(let r=0;r{for(let o=0;o{for(let o=0;o{const n=s.args;let r=i.properties[e];for(let o=1,a=n.length;oi.variables[e];default:throw new Error(`Unsupported accessor operator ${s.operator}`)}}function WZ(s,t){const e=s.operator,i=Xn(s.args[0]),n=Xn(s.args[1]);switch(e){case U.Equal:return r=>i(r)===n(r);case U.NotEqual:return r=>i(r)!==n(r);case U.LessThan:return r=>i(r)i(r)<=n(r);case U.GreaterThan:return r=>i(r)>n(r);case U.GreaterThanOrEqualTo:return r=>i(r)>=n(r);default:throw new Error(`Unsupported comparison operator ${e}`)}}function XZ(s,t){const e=s.operator,i=s.args.length,n=new Array(i);for(let r=0;r{for(let o=0;o{for(let o=0;o{const o=n[0](r),a=n[1](r),l=n[2](r);return o>=a&&o<=l};case U.In:return r=>{const o=n[0](r);for(let a=1;a!n[0](r);default:throw new Error(`Unsupported logical operator ${e}`)}}function VZ(s,t){const e=s.operator,i=s.args.length,n=new Array(i);for(let r=0;r{let o=1;for(let a=0;an[0](r)/n[1](r);case U.Add:return r=>{let o=0;for(let a=0;an[0](r)-n[1](r);case U.Clamp:return r=>{const o=n[0](r),a=n[1](r);if(ol?l:o};case U.Mod:return r=>n[0](r)%n[1](r);case U.Pow:return r=>Math.pow(n[0](r),n[1](r));case U.Abs:return r=>Math.abs(n[0](r));case U.Floor:return r=>Math.floor(n[0](r));case U.Ceil:return r=>Math.ceil(n[0](r));case U.Round:return r=>Math.round(n[0](r));case U.Sin:return r=>Math.sin(n[0](r));case U.Cos:return r=>Math.cos(n[0](r));case U.Atan:return i===2?r=>Math.atan2(n[0](r),n[1](r)):r=>Math.atan(n[0](r));case U.Sqrt:return r=>Math.sqrt(n[0](r));default:throw new Error(`Unsupported numeric operator ${e}`)}}function YZ(s,t){const e=s.args.length,i=new Array(e);for(let n=0;n{for(let r=0;r{const r=i[0](n);for(let o=1;o{const r=i[0](n),o=i[1](n);let a,l;for(let h=2;h=o)return h===2?u:d?KZ(r,o,a,l,c,u):Su(r,o,a,l,c,u);a=c,l=u}return l}}function HZ(s,t){const e=s.operator,i=s.args.length,n=new Array(i);for(let r=0;r{const o=n[0](r);return s.args[0].type===$e?Sv(o):o.toString()};default:throw new Error(`Unsupported convert operator ${e}`)}}function Su(s,t,e,i,n,r){const o=n-e;if(o===0)return i;const a=t-e,l=s===1?a/o:(Math.pow(s,a)-1)/(Math.pow(s,o)-1);return i+l*(r-i)}function KZ(s,t,e,i,n,r){if(n-e===0)return i;const o=v2(i),a=v2(r);let l=a[2]-o[2];l>180?l-=360:l<-180&&(l+=360);const h=[Su(s,t,e,o[0],n,a[0]),Su(s,t,e,o[1],n,a[1]),o[2]+Su(s,t,e,0,n,l),Su(s,t,e,i[3],n,r[3])];return WI(YB(h))}function JZ(s){return!0}function QZ(s){const t=Uv(),e=tH(s,t),i=BP();return function(n,r){if(i.properties=n.getPropertiesInternal(),i.resolution=r,t.featureId){const o=n.getId();o!==void 0?i.featureId=o:i.featureId=null}return t.geometryType&&(i.geometryType=Bv(n.getGeometry())),e(i)}}function uM(s){const t=Uv(),e=s.length,i=new Array(e);for(let o=0;onull;i=Wv(s,t+"fill-color",e)}if(!i)return null;const n=new Wn;return function(r){const o=i(r);return o==="none"?null:(n.setColor(o),n)}}function Nd(s,t,e){const i=Ci(s,t+"stroke-width",e),n=Wv(s,t+"stroke-color",e);if(!i&&!n)return null;const r=kr(s,t+"stroke-line-cap",e),o=kr(s,t+"stroke-line-join",e),a=WP(s,t+"stroke-line-dash",e),l=Ci(s,t+"stroke-line-dash-offset",e),h=Ci(s,t+"stroke-miter-limit",e),c=new wn;return function(u){if(n){const d=n(u);if(d==="none")return null;c.setColor(d)}if(i&&c.setWidth(i(u)),r){const d=r(u);if(d!=="butt"&&d!=="round"&&d!=="square")throw new Error("Expected butt, round, or square line cap");c.setLineCap(d)}if(o){const d=o(u);if(d!=="bevel"&&d!=="round"&&d!=="miter")throw new Error("Expected bevel, round, or miter line join");c.setLineJoin(d)}return a&&c.setLineDash(a(u)),l&&c.setLineDashOffset(l(u)),h&&c.setMiterLimit(h(u)),c}}function eH(s,t){const e="text-",i=kr(s,e+"value",t);if(!i)return null;const n=Fd(s,e,t),r=Fd(s,e+"background-",t),o=Nd(s,e,t),a=Nd(s,e+"background-",t),l=kr(s,e+"font",t),h=Ci(s,e+"max-angle",t),c=Ci(s,e+"offset-x",t),u=Ci(s,e+"offset-y",t),d=Dd(s,e+"overflow",t),g=kr(s,e+"placement",t),f=Ci(s,e+"repeat",t),p=t0(s,e+"scale",t),m=Dd(s,e+"rotate-with-view",t),_=Ci(s,e+"rotation",t),y=kr(s,e+"align",t),v=kr(s,e+"justify",t),S=kr(s,e+"baseline",t),w=WP(s,e+"padding",t),T=e0(s,e+"declutter-mode"),M=new al({declutterMode:T});return function(C){if(M.setText(i(C)),n&&M.setFill(n(C)),r&&M.setBackgroundFill(r(C)),o&&M.setStroke(o(C)),a&&M.setBackgroundStroke(a(C)),l&&M.setFont(l(C)),h&&M.setMaxAngle(h(C)),c&&M.setOffsetX(c(C)),u&&M.setOffsetY(u(C)),d&&M.setOverflow(d(C)),g){const I=g(C);if(I!=="point"&&I!=="line")throw new Error("Expected point or line for text-placement");M.setPlacement(I)}if(f&&M.setRepeat(f(C)),p&&M.setScale(p(C)),m&&M.setRotateWithView(m(C)),_&&M.setRotation(_(C)),y){const I=y(C);if(I!=="left"&&I!=="center"&&I!=="right"&&I!=="end"&&I!=="start")throw new Error("Expected left, right, center, start, or end for text-align");M.setTextAlign(I)}if(v){const I=v(C);if(I!=="left"&&I!=="right"&&I!=="center")throw new Error("Expected left, right, or center for text-justify");M.setJustify(I)}if(S){const I=S(C);if(I!=="bottom"&&I!=="top"&&I!=="middle"&&I!=="alphabetic"&&I!=="hanging")throw new Error("Expected bottom, top, middle, alphabetic, or hanging for text-baseline");M.setTextBaseline(I)}return w&&M.setPadding(w(C)),M}}function sH(s,t){return"icon-src"in s?iH(s,t):"shape-points"in s?nH(s,t):"circle-radius"in s?rH(s,t):null}function iH(s,t){const e="icon-",i=e+"src",n=XP(s[i],i),r=$p(s,e+"anchor",t),o=t0(s,e+"scale",t),a=Ci(s,e+"opacity",t),l=$p(s,e+"displacement",t),h=Ci(s,e+"rotation",t),c=Dd(s,e+"rotate-with-view",t),u=gM(s,e+"anchor-origin"),d=fM(s,e+"anchor-x-units"),g=fM(s,e+"anchor-y-units"),f=cH(s,e+"color"),p=lH(s,e+"cross-origin"),m=hH(s,e+"offset"),_=gM(s,e+"offset-origin"),y=Gp(s,e+"width"),v=Gp(s,e+"height"),S=aH(s,e+"size"),w=e0(s,e+"declutter-mode"),T=new Rc({src:n,anchorOrigin:u,anchorXUnits:d,anchorYUnits:g,color:f,crossOrigin:p,offset:m,offsetOrigin:_,height:v,width:y,size:S,declutterMode:w});return function(M){return a&&T.setOpacity(a(M)),l&&T.setDisplacement(l(M)),h&&T.setRotation(h(M)),c&&T.setRotateWithView(c(M)),o&&T.setScale(o(M)),r&&T.setAnchor(r(M)),T}}function nH(s,t){const e="shape-",i=e+"points",n=e+"radius",r=ly(s[i],i),o=ly(s[n],n),a=Fd(s,e,t),l=Nd(s,e,t),h=t0(s,e+"scale",t),c=$p(s,e+"displacement",t),u=Ci(s,e+"rotation",t),d=Dd(s,e+"rotate-with-view",t),g=Gp(s,e+"radius2"),f=Gp(s,e+"angle"),p=e0(s,e+"declutter-mode"),m=new Vm({points:r,radius:o,radius2:g,angle:f,declutterMode:p});return function(_){return a&&m.setFill(a(_)),l&&m.setStroke(l(_)),c&&m.setDisplacement(c(_)),u&&m.setRotation(u(_)),d&&m.setRotateWithView(d(_)),h&&m.setScale(h(_)),m}}function rH(s,t){const e="circle-",i=Fd(s,e,t),n=Nd(s,e,t),r=Ci(s,e+"radius",t),o=t0(s,e+"scale",t),a=$p(s,e+"displacement",t),l=Ci(s,e+"rotation",t),h=Dd(s,e+"rotate-with-view",t),c=e0(s,e+"declutter-mode"),u=new Ym({radius:5,declutterMode:c});return function(d){return r&&u.setRadius(r(d)),i&&u.setFill(i(d)),n&&u.setStroke(n(d)),a&&u.setDisplacement(a(d)),l&&u.setRotation(l(d)),h&&u.setRotateWithView(h(d)),o&&u.setScale(o(d)),u}}function Ci(s,t,e){if(!(t in s))return;const i=_o(s[t],lt,e);return function(n){return ly(i(n),t)}}function kr(s,t,e){if(!(t in s))return null;const i=_o(s[t],bs,e);return function(n){return XP(i(n),t)}}function oH(s,t,e){const i=kr(s,t+"pattern-src",e),n=dM(s,t+"pattern-offset",e),r=dM(s,t+"pattern-size",e),o=Wv(s,t+"color",e);return function(a){return{src:i(a),offset:n&&n(a),size:r&&r(a),color:o&&o(a)}}}function Dd(s,t,e){if(!(t in s))return null;const i=_o(s[t],Os,e);return function(n){const r=i(n);if(typeof r!="boolean")throw new Error(`Expected a boolean for ${t}`);return r}}function Wv(s,t,e){if(!(t in s))return null;const i=_o(s[t],$e,e);return function(n){return VP(i(n),t)}}function WP(s,t,e){if(!(t in s))return null;const i=_o(s[t],ui,e);return function(n){return Rg(i(n),t)}}function $p(s,t,e){if(!(t in s))return null;const i=_o(s[t],ui,e);return function(n){const r=Rg(i(n),t);if(r.length!==2)throw new Error(`Expected two numbers for ${t}`);return r}}function dM(s,t,e){if(!(t in s))return null;const i=_o(s[t],ui,e);return function(n){return YP(i(n),t)}}function t0(s,t,e){if(!(t in s))return null;const i=_o(s[t],ui|lt,e);return function(n){return uH(i(n),t)}}function Gp(s,t){const e=s[t];if(e!==void 0){if(typeof e!="number")throw new Error(`Expected a number for ${t}`);return e}}function aH(s,t){const e=s[t];if(e!==void 0){if(typeof e=="number")return Re(e);if(!Array.isArray(e))throw new Error(`Expected a number or size array for ${t}`);if(e.length!==2||typeof e[0]!="number"||typeof e[1]!="number")throw new Error(`Expected a number or size array for ${t}`);return e}}function lH(s,t){const e=s[t];if(e!==void 0){if(typeof e!="string")throw new Error(`Expected a string for ${t}`);return e}}function gM(s,t){const e=s[t];if(e!==void 0){if(e!=="bottom-left"&&e!=="bottom-right"&&e!=="top-left"&&e!=="top-right")throw new Error(`Expected bottom-left, bottom-right, top-left, or top-right for ${t}`);return e}}function fM(s,t){const e=s[t];if(e!==void 0){if(e!=="pixels"&&e!=="fraction")throw new Error(`Expected pixels or fraction for ${t}`);return e}}function hH(s,t){const e=s[t];if(e!==void 0)return Rg(e,t)}function e0(s,t){const e=s[t];if(e!==void 0){if(typeof e!="string")throw new Error(`Expected a string for ${t}`);if(e!=="declutter"&&e!=="obstacle"&&e!=="none")throw new Error(`Expected declutter, obstacle, or none for ${t}`);return e}}function cH(s,t){const e=s[t];if(e!==void 0)return VP(e,t)}function Rg(s,t){if(!Array.isArray(s))throw new Error(`Expected an array for ${t}`);const e=s.length;for(let i=0;i4)throw new Error(`Expected a color with 3 or 4 values for ${t}`);return e}function YP(s,t){const e=Rg(s,t);if(e.length!==2)throw new Error(`Expected an array of two numbers for ${t}`);return e}function uH(s,t){return typeof s=="number"?s:YP(s,t)}const pM={RENDER_ORDER:"renderOrder"};class Ig extends Cg{constructor(t){t=t||{};const e=Object.assign({},t);delete e.style,delete e.renderBuffer,delete e.updateWhileAnimating,delete e.updateWhileInteracting,super(e),this.declutter_=t.declutter?String(t.declutter):void 0,this.renderBuffer_=t.renderBuffer!==void 0?t.renderBuffer:100,this.style_=null,this.styleFunction_=void 0,this.setStyle(t.style),this.updateWhileAnimating_=t.updateWhileAnimating!==void 0?t.updateWhileAnimating:!1,this.updateWhileInteracting_=t.updateWhileInteracting!==void 0?t.updateWhileInteracting:!1}getDeclutter(){return this.declutter_}getFeatures(t){return super.getFeatures(t)}getRenderBuffer(){return this.renderBuffer_}getRenderOrder(){return this.get(pM.RENDER_ORDER)}getStyle(){return this.style_}getStyleFunction(){return this.styleFunction_}getUpdateWhileAnimating(){return this.updateWhileAnimating_}getUpdateWhileInteracting(){return this.updateWhileInteracting_}renderDeclutter(t,e){const i=this.getDeclutter();i in t.declutter||(t.declutter[i]=new jv(9)),this.getRenderer().renderDeclutter(t,e)}setRenderOrder(t){this.set(pM.RENDER_ORDER,t)}setStyle(t){this.style_=t===void 0?KI:t;const e=dH(t);this.styleFunction_=t===null?void 0:lW(e),this.changed()}}function dH(s){if(s===void 0)return KI;if(!s)return null;if(typeof s=="function"||s instanceof Ps)return s;if(!Array.isArray(s))return uM([s]);if(s.length===0)return[];const t=s.length,e=s[0];if(e instanceof Ps){const i=new Array(t);for(let n=0;nl&&(this.instructions.push([Et.CUSTOM,l,c,t,i,jr,r]),this.hitDetectionInstructions.push([Et.CUSTOM,l,c,t,n||i,jr,r]));break;case"Point":h=t.getFlatCoordinates(),this.coordinates.push(h[0],h[1]),c=this.coordinates.length,this.instructions.push([Et.CUSTOM,l,c,t,i,void 0,r]),this.hitDetectionInstructions.push([Et.CUSTOM,l,c,t,n||i,void 0,r]);break}this.endGeometry(e)}beginGeometry(t,e,i){this.beginGeometryInstruction1_=[Et.BEGIN_GEOMETRY,e,0,t,i],this.instructions.push(this.beginGeometryInstruction1_),this.beginGeometryInstruction2_=[Et.BEGIN_GEOMETRY,e,0,t,i],this.hitDetectionInstructions.push(this.beginGeometryInstruction2_)}finish(){return{instructions:this.instructions,hitDetectionInstructions:this.hitDetectionInstructions,coordinates:this.coordinates}}reverseHitDetectionInstructions(){const t=this.hitDetectionInstructions;t.reverse();let e;const i=t.length;let n,r,o=-1;for(e=0;ethis.maxLineWidth&&(this.maxLineWidth=i.lineWidth,this.bufferedMaxExtent_=null)}else i.strokeStyle=void 0,i.lineCap=void 0,i.lineDash=null,i.lineDashOffset=void 0,i.lineJoin=void 0,i.lineWidth=void 0,i.miterLimit=void 0}createFill(t){const e=t.fillStyle,i=[Et.SET_FILL_STYLE,e];return typeof e!="string"&&i.push(t.fillPatternScale),i}applyStroke(t){this.instructions.push(this.createStroke(t))}createStroke(t){return[Et.SET_STROKE_STYLE,t.strokeStyle,t.lineWidth*this.pixelRatio,t.lineCap,t.lineJoin,t.miterLimit,this.applyPixelRatio(t.lineDash),t.lineDashOffset*this.pixelRatio]}updateFillStyle(t,e){const i=t.fillStyle;(typeof i!="string"||t.currentFillStyle!=i)&&(i!==void 0&&this.instructions.push(e.call(this,t)),t.currentFillStyle=i)}updateStrokeStyle(t,e){const i=t.strokeStyle,n=t.lineCap,r=t.lineDash,o=t.lineDashOffset,a=t.lineJoin,l=t.lineWidth,h=t.miterLimit;(t.currentStrokeStyle!=i||t.currentLineCap!=n||r!=t.currentLineDash&&!vl(t.currentLineDash,r)||t.currentLineDashOffset!=o||t.currentLineJoin!=a||t.currentLineWidth!=l||t.currentMiterLimit!=h)&&(i!==void 0&&e.call(this,t),t.currentStrokeStyle=i,t.currentLineCap=n,t.currentLineDash=r,t.currentLineDashOffset=o,t.currentLineJoin=a,t.currentLineWidth=l,t.currentMiterLimit=h)}endGeometry(t){this.beginGeometryInstruction1_[2]=this.instructions.length,this.beginGeometryInstruction1_=null,this.beginGeometryInstruction2_[2]=this.hitDetectionInstructions.length,this.beginGeometryInstruction2_=null;const e=[Et.END_GEOMETRY,t];this.instructions.push(e),this.hitDetectionInstructions.push(e)}getBufferedMaxExtent(){if(!this.bufferedMaxExtent_&&(this.bufferedMaxExtent_=o9(this.maxExtent),this.maxLineWidth>0)){const t=this.resolution*(this.maxLineWidth+1)/2;_n(this.bufferedMaxExtent_,t,this.bufferedMaxExtent_)}return this.bufferedMaxExtent_}}class gH extends Pg{constructor(t,e,i,n){super(t,e,i,n),this.hitDetectionImage_=null,this.image_=null,this.imagePixelRatio_=void 0,this.anchorX_=void 0,this.anchorY_=void 0,this.height_=void 0,this.opacity_=void 0,this.originX_=void 0,this.originY_=void 0,this.rotateWithView_=void 0,this.rotation_=void 0,this.scale_=void 0,this.width_=void 0,this.declutterMode_=void 0,this.declutterImageWithText_=void 0}drawPoint(t,e,i){if(!this.image_||this.maxExtent&&!Yi(this.maxExtent,t.getFlatCoordinates()))return;this.beginGeometry(t,e,i);const n=t.getFlatCoordinates(),r=t.getStride(),o=this.coordinates.length,a=this.appendFlatPointCoordinates(n,r);this.instructions.push([Et.DRAW_IMAGE,o,a,this.image_,this.anchorX_*this.imagePixelRatio_,this.anchorY_*this.imagePixelRatio_,Math.ceil(this.height_*this.imagePixelRatio_),this.opacity_,this.originX_*this.imagePixelRatio_,this.originY_*this.imagePixelRatio_,this.rotateWithView_,this.rotation_,[this.scale_[0]*this.pixelRatio/this.imagePixelRatio_,this.scale_[1]*this.pixelRatio/this.imagePixelRatio_],Math.ceil(this.width_*this.imagePixelRatio_),this.declutterMode_,this.declutterImageWithText_]),this.hitDetectionInstructions.push([Et.DRAW_IMAGE,o,a,this.hitDetectionImage_,this.anchorX_,this.anchorY_,this.height_,1,this.originX_,this.originY_,this.rotateWithView_,this.rotation_,this.scale_,this.width_,this.declutterMode_,this.declutterImageWithText_]),this.endGeometry(e)}drawMultiPoint(t,e,i){if(!this.image_)return;this.beginGeometry(t,e,i);const n=t.getFlatCoordinates(),r=[];for(let l=0,h=n.length;l=s){const f=(s-a+g)/g,p=Ui(h,u,f),m=Ui(c,d,f);l.push(p,m),r.push(l),l=[p,m],a==s&&(o+=n),a=0}else if(a0&&r.push(l),r}function mH(s,t,e,i,n){let r=e,o=e,a=0,l=0,h=e,c,u,d,g,f,p,m,_,y,v;for(u=e;us&&(l>a&&(a=l,r=h,o=u),l=0,h=u-n)),d=g,m=y,_=v),f=S,p=w}return l+=g,l>a?[h,u]:[r,o]}const jp={left:0,center:.5,right:1,top:0,middle:.5,hanging:.2,alphabetic:.8,ideographic:.8,bottom:1};class _H extends Pg{constructor(t,e,i,n){super(t,e,i,n),this.labels_=null,this.text_="",this.textOffsetX_=0,this.textOffsetY_=0,this.textRotateWithView_=void 0,this.textRotation_=0,this.textFillState_=null,this.fillStates={},this.fillStates[Si]={fillStyle:Si},this.textStrokeState_=null,this.strokeStates={},this.textState_={},this.textStates={},this.textKey_="",this.fillKey_="",this.strokeKey_="",this.declutterMode_=void 0,this.declutterImageWithText_=void 0}finish(){const t=super.finish();return t.textStates=this.textStates,t.fillStates=this.fillStates,t.strokeStates=this.strokeStates,t}drawText(t,e,i){const n=this.textFillState_,r=this.textStrokeState_,o=this.textState_;if(this.text_===""||!o||!n&&!r)return;const a=this.coordinates;let l=a.length;const h=t.getType();let c=null,u=t.getStride();if(o.placement==="line"&&(h=="LineString"||h=="MultiLineString"||h=="Polygon"||h=="MultiPolygon")){if(!Te(this.maxExtent,t.getExtent()))return;let d;if(c=t.getFlatCoordinates(),h=="LineString")d=[c.length];else if(h=="MultiLineString")d=t.getEnds();else if(h=="Polygon")d=t.getEnds().slice(0,1);else if(h=="MultiPolygon"){const m=t.getEndss();d=[];for(let _=0,y=m.length;_{const w=a[(y+S)*2]===c[S*u]&&a[(y+S)*2+1]===c[S*u+1];return w||--y,w})}this.saveTextStates_(),(o.backgroundFill||o.backgroundStroke)&&(this.setFillStrokeStyle(o.backgroundFill,o.backgroundStroke),o.backgroundFill&&this.updateFillStyle(this.state,this.createFill),o.backgroundStroke&&(this.updateStrokeStyle(this.state,this.applyStroke),this.hitDetectionInstructions.push(this.createStroke(this.state)))),this.beginGeometry(t,e,i);let f=o.padding;if(f!=za&&(o.scale[0]<0||o.scale[1]<0)){let y=o.padding[0],v=o.padding[1],S=o.padding[2],w=o.padding[3];o.scale[0]<0&&(v=-v,w=-w),o.scale[1]<0&&(y=-y,S=-S),f=[y,v,S,w]}const p=this.pixelRatio;this.instructions.push([Et.DRAW_IMAGE,l,g,null,NaN,NaN,NaN,1,0,0,this.textRotateWithView_,this.textRotation_,[1,1],NaN,this.declutterMode_,this.declutterImageWithText_,f==za?za:f.map(function(y){return y*p}),!!o.backgroundFill,!!o.backgroundStroke,this.text_,this.textKey_,this.strokeKey_,this.fillKey_,this.textOffsetX_,this.textOffsetY_,d]);const m=1/p,_=this.state.fillStyle;o.backgroundFill&&(this.state.fillStyle=Si,this.hitDetectionInstructions.push(this.createFill(this.state))),this.hitDetectionInstructions.push([Et.DRAW_IMAGE,l,g,null,NaN,NaN,NaN,1,0,0,this.textRotateWithView_,this.textRotation_,[m,m],NaN,this.declutterMode_,this.declutterImageWithText_,f,!!o.backgroundFill,!!o.backgroundStroke,this.text_,this.textKey_,this.strokeKey_,this.fillKey_?Si:this.fillKey_,this.textOffsetX_,this.textOffsetY_,d]),o.backgroundFill&&(this.state.fillStyle=_,this.hitDetectionInstructions.push(this.createFill(this.state))),this.endGeometry(e)}}saveTextStates_(){const t=this.textStrokeState_,e=this.textState_,i=this.textFillState_,n=this.strokeKey_;t&&(n in this.strokeStates||(this.strokeStates[n]={strokeStyle:t.strokeStyle,lineCap:t.lineCap,lineDashOffset:t.lineDashOffset,lineWidth:t.lineWidth,lineJoin:t.lineJoin,miterLimit:t.miterLimit,lineDash:t.lineDash}));const r=this.textKey_;r in this.textStates||(this.textStates[r]={font:e.font,textAlign:e.textAlign||Ld,justify:e.justify,textBaseline:e.textBaseline||Ap,scale:e.scale});const o=this.fillKey_;i&&(o in this.fillStates||(this.fillStates[o]={fillStyle:i.fillStyle}))}drawChars_(t,e){const i=this.textStrokeState_,n=this.textState_,r=this.strokeKey_,o=this.textKey_,a=this.fillKey_;this.saveTextStates_();const l=this.pixelRatio,h=jp[n.textBaseline],c=this.textOffsetY_*l,u=this.text_,d=i?i.lineWidth*Math.abs(n.scale[0])/2:0;this.instructions.push([Et.DRAW_CHARS,t,e,h,n.overflow,a,n.maxAngle,l,c,r,d*l,u,o,1,this.declutterMode_]),this.hitDetectionInstructions.push([Et.DRAW_CHARS,t,e,h,n.overflow,a&&Si,n.maxAngle,l,c,r,d*l,u,o,1/l,this.declutterMode_])}setTextStyle(t,e){let i,n,r;if(!t)this.text_="";else{const o=t.getFill();o?(n=this.textFillState_,n||(n={},this.textFillState_=n),n.fillStyle=hr(o.getColor()||Si)):(n=null,this.textFillState_=n);const a=t.getStroke();if(!a)r=null,this.textStrokeState_=r;else{r=this.textStrokeState_,r||(r={},this.textStrokeState_=r);const f=a.getLineDash(),p=a.getLineDashOffset(),m=a.getWidth(),_=a.getMiterLimit();r.lineCap=a.getLineCap()||lc,r.lineDash=f?f.slice():Hr,r.lineDashOffset=p===void 0?Kr:p,r.lineJoin=a.getLineJoin()||hc,r.lineWidth=m===void 0?Od:m,r.miterLimit=_===void 0?Pd:_,r.strokeStyle=hr(a.getColor()||Ad)}i=this.textState_;const l=t.getFont()||ZI;iW(l);const h=t.getScaleArray();i.overflow=t.getOverflow(),i.font=l,i.maxAngle=t.getMaxAngle(),i.placement=t.getPlacement(),i.textAlign=t.getTextAlign(),i.repeat=t.getRepeat(),i.justify=t.getJustify(),i.textBaseline=t.getTextBaseline()||Ap,i.backgroundFill=t.getBackgroundFill(),i.backgroundStroke=t.getBackgroundStroke(),i.padding=t.getPadding()||za,i.scale=h===void 0?[1,1]:h;const c=t.getOffsetX(),u=t.getOffsetY(),d=t.getRotateWithView(),g=t.getRotation();this.text_=t.getText()||"",this.textOffsetX_=c===void 0?0:c,this.textOffsetY_=u===void 0?0:u,this.textRotateWithView_=d===void 0?!1:d,this.textRotation_=g===void 0?0:g,this.strokeKey_=r?(typeof r.strokeStyle=="string"?r.strokeStyle:mt(r.strokeStyle))+r.lineCap+r.lineDashOffset+"|"+r.lineWidth+r.lineJoin+r.miterLimit+"["+r.lineDash.join()+"]":"",this.textKey_=i.font+i.scale+(i.textAlign||"?")+(i.repeat||"?")+(i.justify||"?")+(i.textBaseline||"?"),this.fillKey_=n&&n.fillStyle?typeof n.fillStyle=="string"?n.fillStyle:"|"+mt(n.fillStyle):""}this.declutterMode_=t.getDeclutterMode(),this.declutterImageWithText_=e}}const yH={Circle:_M,Default:Pg,Image:gH,LineString:fH,Polygon:_M,Text:_H};class ZP{constructor(t,e,i,n){this.tolerance_=t,this.maxExtent_=e,this.pixelRatio_=n,this.resolution_=i,this.buildersByZIndex_={}}finish(){const t={};for(const e in this.buildersByZIndex_){t[e]=t[e]||{};const i=this.buildersByZIndex_[e];for(const n in i){const r=i[n].finish();t[e][n]=r}}return t}getBuilder(t,e){const i=t!==void 0?t.toString():"0";let n=this.buildersByZIndex_[i];n===void 0&&(n={},this.buildersByZIndex_[i]=n);let r=n[e];if(r===void 0){const o=yH[e];r=new o(this.tolerance_,this.maxExtent_,this.resolution_,this.pixelRatio_),n[e]=r}return r}}const xH=5;class HP extends pg{constructor(t){super(),this.ready=!0,this.boundHandleImageChange_=this.handleImageChange_.bind(this),this.layer_=t,this.staleKeys_=new Array,this.maxStaleKeys=xH}getStaleKeys(){return this.staleKeys_}prependStaleKey(t){this.staleKeys_.unshift(t),this.staleKeys_.length>this.maxStaleKeys&&(this.staleKeys_.length=this.maxStaleKeys)}getFeatures(t){return vt()}getData(t){return null}prepareFrame(t){return vt()}renderFrame(t,e){return vt()}forEachFeatureAtCoordinate(t,e,i,n,r){}getLayer(){return this.layer_}handleFontsChanged(){}handleImageChange_(t){const e=t.target;(e.getState()===it.LOADED||e.getState()===it.ERROR)&&this.renderIfReadyAndVisible()}loadImage(t){let e=t.getState();return e!=it.LOADED&&e!=it.ERROR&&t.addEventListener(Zt.CHANGE,this.boundHandleImageChange_),e==it.IDLE&&(t.load(),e=t.getState()),e==it.LOADED}renderIfReadyAndVisible(){const t=this.getLayer();t&&t.getVisible()&&t.getSourceState()==="ready"&&t.changed()}renderDeferred(t){}disposeInternal(){delete this.layer_,super.disposeInternal()}}class $f extends Sr{constructor(t,e,i,n){super(t),this.inversePixelTransform=e,this.frameState=i,this.context=n}}class Xv{constructor(){jx(this,"pushMethodArgs_",(...t)=>(this.instructions_[this.zIndex+this.offset_].push(t),this)),this.instructions_=[],this.zIndex=0,this.offset_=0,this.context_=new Proxy(Pp(),{get:(t,e)=>{if(typeof Pp()[e]=="function")return this.instructions_[this.zIndex+this.offset_]||(this.instructions_[this.zIndex+this.offset_]=[]),this.instructions_[this.zIndex+this.offset_].push(e),this.pushMethodArgs_},set:(t,e,i)=>(this.instructions_[this.zIndex+this.offset_]||(this.instructions_[this.zIndex+this.offset_]=[]),this.instructions_[this.zIndex+this.offset_].push(e,i),!0)})}pushFunction(t){this.instructions_[this.zIndex+this.offset_].push(t)}getContext(){return this.context_}draw(t){this.instructions_.forEach(e=>{for(let i=0,n=e.length;iR[2]}else P=S>I;const D=Math.PI,x=[],E=T+i===t;t=T,m=0,_=M,d=s[t],g=s[t+1];let b;if(E){y(),b=Math.atan2(g-p,d-f),P&&(b+=b>0?-D:D);const R=(I+S)/2,A=(O+w)/2;return x[0]=[R,A,(C-r)/2,b,n],x}n=n.replace(/\n/g," ");for(let R=0,A=n.length;R0?-D:D),b!==void 0){let F=$-b;if(F+=F>D?-2*D:F<-D?2*D:0,Math.abs(F)>o)return null}b=$;const G=R;let k=0;for(;R0&&s.push(` +`||h===c){r=Math.max(r,o),n.push(o),o=0,a+=l,l=0;continue}const d=t[h+1]||s.font,g=Lp(d,u);e.push(g),o+=g;const f=nW(d);i.push(f),l=Math.max(l,f)}return{width:r,height:a,widths:e,heights:i,lineWidths:n}}function oW(s,t,e,i,n,r,o,a,l,h,c){s.save(),e!==1&&(s.globalAlpha===void 0?s.globalAlpha=u=>u.globalAlpha*=e:s.globalAlpha*=e),t&&s.transform.apply(s,t),i.contextInstructions?(s.translate(l,h),s.scale(c[0],c[1]),aW(i,s)):c[0]<0||c[1]<0?(s.translate(l,h),s.scale(c[0],c[1]),s.drawImage(i,n,r,o,a,0,0,o,a)):s.drawImage(i,n,r,o,a,l,h,o*c[0],a*c[1]),s.restore()}function aW(s,t){const e=s.contextInstructions;for(let i=0,n=e.length;ithis.imageState_=it.LOADED),this.render()}clone(){const t=this.getScale(),e=new Vm({fill:this.getFill()?this.getFill().clone():void 0,points:this.getPoints(),radius:this.getRadius(),radius2:this.getRadius2(),angle:this.getAngle(),stroke:this.getStroke()?this.getStroke().clone():void 0,rotation:this.getRotation(),rotateWithView:this.getRotateWithView(),scale:Array.isArray(t)?t.slice():t,displacement:this.getDisplacement().slice(),declutterMode:this.getDeclutterMode()});return e.setOpacity(this.getOpacity()),e}getAnchor(){const t=this.size_,e=this.getDisplacement(),i=this.getScaleArray();return[t[0]/2-e[0]/i[0],t[1]/2+e[1]/i[1]]}getAngle(){return this.angle_}getFill(){return this.fill_}setFill(t){this.fill_=t,this.render()}getHitDetectionImage(){return this.hitDetectionCanvas_||(this.hitDetectionCanvas_=this.createHitDetectionCanvas_(this.renderOptions_)),this.hitDetectionCanvas_}getImage(t){let e=this.canvases_[t];if(!e){const i=this.renderOptions_,n=Se(i.size*t,i.size*t);this.draw_(i,n,t),e=n.canvas,this.canvases_[t]=e}return e}getPixelRatio(t){return t}getImageSize(){return this.size_}getImageState(){return this.imageState_}getOrigin(){return this.origin_}getPoints(){return this.points_}getRadius(){return this.radius}getRadius2(){return this.radius2_}getSize(){return this.size_}getStroke(){return this.stroke_}setStroke(t){this.stroke_=t,this.render()}listenImageChange(t){}load(){}unlistenImageChange(t){}calculateLineJoinSize_(t,e,i){if(e===0||this.points_===1/0||t!=="bevel"&&t!=="miter")return e;let n=this.radius,r=this.radius2_===void 0?n:this.radius2_;if(n1?o.Document=t:t.length==1&&(o.Placemark=t[0]);const a=pW[i.namespaceURI],l=Ai(o,a);return Tt(r,mW,Is,l,[e],a,this),i}}function vW(s,t){const e=[0,0];let i="start";const n=s.getImage();if(n){const o=n.getSize();if(o&&o.length==2){const a=n.getScaleArray(),l=n.getAnchor();e[0]=a[0]*(o[0]-l[0]),e[1]=a[1]*(o[1]/2-l[1]),i="left"}}let r=s.getText();return r?(r=r.clone(),r.setFont(r.getFont()||Ua.getFont()),r.setScale(r.getScale()||Ua.getScale()),r.setFill(r.getFill()||Ua.getFill()),r.setStroke(r.getStroke()||sy)):r=Ua.clone(),r.setText(t),r.setOffsetX(e[0]),r.setOffsetY(e[1]),r.setTextAlign(i),new Ps({image:n,text:r})}function wW(s,t,e,i,n){return function(r,o){let a=n,l="",h=[];if(a){const u=r.getGeometry();if(u)if(u instanceof _s)h=u.getGeometriesArrayRecursive().filter(function(d){const g=d.getType();return g==="Point"||g==="MultiPoint"}),a=h.length>0;else{const d=u.getType();a=d==="Point"||d==="MultiPoint"}}a&&(l=r.get("name"),a=a&&!!l,a&&/&[^&]+;/.test(l)&&(pf||(pf=document.createElement("textarea")),pf.innerHTML=l,l=pf.value));let c=e;if(s?c=s:t&&(c=QI(t,e,i)),a){const u=vW(c[0],l);if(h.length>0){u.setGeometry(new _s(h));const d=new Ps({geometry:c[0].getGeometry(),image:null,fill:c[0].getFill(),stroke:c[0].getStroke(),text:null});return[u,d].concat(c.slice(1))}return u}return c}}function QI(s,t,e){return Array.isArray(s)?s:typeof s=="string"?QI(e[s],t,e):t}function qm(s){const t=ci(s,!1),e=/^\s*#?\s*([0-9A-Fa-f]{8})\s*$/.exec(t);if(e){const i=e[1];return[parseInt(i.substr(6,2),16),parseInt(i.substr(4,2),16),parseInt(i.substr(2,2),16),parseInt(i.substr(0,2),16)/255]}}function tP(s){let t=ci(s,!1);const e=[];t=t.replace(/\s*,\s*/g,",");const i=/^\s*([+\-]?\d*\.?\d+(?:e[+\-]?\d+)?),([+\-]?\d*\.?\d+(?:e[+\-]?\d+)?)(?:\s+|,|$)(?:([+\-]?\d*\.?\d+(?:e[+\-]?\d+)?)(?:\s+|$))?\s*/i;let n;for(;n=i.exec(t);){const r=parseFloat(n[1]),o=parseFloat(n[2]),a=n[3]?parseFloat(n[3]):0;e.push(r,o,a),t=t.substr(n[0].length)}if(t==="")return e}function eP(s){const t=ci(s,!1).trim();let e=s.baseURI;return(!e||e=="about:blank")&&(e=window.location.href),e?new URL(t,e).href:t}function sP(s){const t=ci(s,!1).trim().replace(/^(?!.*#)/,"#");let e=s.baseURI;return(!e||e=="about:blank")&&(e=window.location.href),e?new URL(t,e).href:t}function EW(s){const t=s.getAttribute("xunits"),e=s.getAttribute("yunits");let i;return t!=="insetPixels"?e!=="insetPixels"?i="bottom-left":i="top-left":e!=="insetPixels"?i="bottom-right":i="top-right",{x:parseFloat(s.getAttribute("x")),xunits:b2[t],y:parseFloat(s.getAttribute("y")),yunits:b2[e],origin:i}}function iP(s){return Yt(s)}const SW=B(ft,{Pair:YW});function nP(s,t){return Y(void 0,SW,s,t,this)}const MW=B(ft,{Icon:L($W),color:L(qm),heading:L(Yt),hotSpot:L(EW),scale:L(iP)});function bW(s,t){const e=Y({},MW,s,t);if(!e)return;const i=t[t.length-1],n="Icon"in e?e.Icon:{},r=!("Icon"in e)||Object.keys(n).length>0;let o;const a=n.href;a?o=a:r&&(o=Op);let l,h,c,u="bottom-left";const d=e.hotSpot;d?(l=[d.x,d.y],h=d.xunits,c=d.yunits,u=d.origin):/^https?:\/\/maps\.(?:google|gstatic)\.com\//.test(o)&&(o.includes("pushpin")?(l=Q1,h=Vu,c=Yu):o.includes("arrow-reverse")?(l=[54,42],h=Vu,c=Yu):o.includes("paddle")&&(l=[32,1],h=Vu,c=Yu));let g;const f=n.x,p=n.y;f!==void 0&&p!==void 0&&(g=[f,p]);let m;const _=n.w,y=n.h;_!==void 0&&y!==void 0&&(m=[_,y]);let v;const S=e.heading;S!==void 0&&(v=Xu(S));const w=e.scale,C=e.color;if(r){o==Op&&(m=qu);const M=new Rc({anchor:l,anchorOrigin:u,anchorXUnits:h,anchorYUnits:c,crossOrigin:this.crossOrigin_,offset:g,offsetOrigin:"bottom-left",rotation:v,scale:w,size:m,src:this.iconUrlFunction_(o),color:C}),T=M.getScaleArray()[0],I=M.getSize();if(I===null){const O=M.getImageState();if(O===it.IDLE||O===it.LOADING){const P=function(){const D=M.getImageState();if(!(D===it.IDLE||D===it.LOADING)){const x=M.getSize();if(x&&x.length==2){const E=Fp(x);M.setScale(T*E)}M.unlistenImageChange(P)}};M.listenImageChange(P),O===it.IDLE&&M.load()}}else if(I.length==2){const O=Fp(I);M.setScale(T*O)}i.imageStyle=M}else i.imageStyle=Cv}const CW=B(ft,{color:L(qm),scale:L(iP)});function TW(s,t){const e=Y({},CW,s,t);if(!e)return;const i=t[t.length-1],n=new al({fill:new Wn({color:"color"in e?e.color:Lh}),scale:e.scale});i.textStyle=n}const RW=B(ft,{color:L(qm),width:L(Yt)});function IW(s,t){const e=Y({},RW,s,t);if(!e)return;const i=t[t.length-1],n=new wn({color:"color"in e?e.color:Lh,width:"width"in e?e.width:1});i.strokeStyle=n}const PW=B(ft,{color:L(qm),fill:L(la),outline:L(la)});function AW(s,t){const e=Y({},PW,s,t);if(!e)return;const i=t[t.length-1],n=new Wn({color:"color"in e?e.color:Lh});i.fillStyle=n;const r=e.fill;r!==void 0&&(i.fill=r);const o=e.outline;o!==void 0&&(i.outline=o)}const LW=B(ft,{coordinates:xt(tP)});function rP(s,t){return Y(null,LW,s,t)}function OW(s,t){const e=t[t.length-1].coordinates,i=ci(s,!1),n=/^\s*([+\-]?\d+(?:\.\d*)?(?:e[+\-]?\d*)?)\s+([+\-]?\d+(?:\.\d*)?(?:e[+\-]?\d*)?)\s+([+\-]?\d+(?:\.\d*)?(?:e[+\-]?\d*)?)\s*$/i.exec(i);if(n){const r=parseFloat(n[1]),o=parseFloat(n[2]),a=parseFloat(n[3]);e.push([r,o,a])}else e.push([])}const FW=B(mo,{Track:dt(oP)});function NW(s,t){const e=Y([],FW,s,t);if(e)return new Pi(e)}const DW=B(ft,{when:aX},B(mo,{coord:OW}));function oP(s,t){const e=Y({coordinates:[],whens:[]},DW,s,t);if(!e)return;const i=[],n=e.coordinates,r=e.whens;for(let o=0,a=Math.min(n.length,r.length);o0&&t[t.length-1].push(...e)}const nX=B(ft,{LinearRing:xt(rP)});function rX(s,t){const e=Y(void 0,nX,s,t);if(e){const i=t[t.length-1];i[0]=e}}function oX(s,t){Ii(gW,s,t)}function aX(s,t){const e=t[t.length-1].whens,i=ci(s,!1),n=Date.parse(i);e.push(isNaN(n)?0:n)}function Hm(s,t){const e=Bn(t),i=[(e.length==4?e[3]:1)*255,e[2],e[1],e[0]];for(let n=0;n<4;++n){const r=Math.floor(i[n]).toString(16);i[n]=r.length==1?"0"+r:r}Ct(s,i.join(""))}function lX(s,t,e){const i=e[e.length-1],n=i.layout,r=i.stride;let o;if(n=="XY"||n=="XYM")o=2;else if(n=="XYZ"||n=="XYZM")o=3;else throw new Error("Invalid geometry layout");const a=t.length;let l="";if(a>0){l+=t[0];for(let h=1;h0){const g=Ai(n,o);Tt(i,b_,DX,[{names:o,values:g}],e)}const u=e[0];let d=t.getGeometry();d&&(d=De(d,!0,u)),Tt(i,b_,fP,[d],e)}const kX=B(ft,["extrude","tessellate","altitudeMode","coordinates"]),$X=B(ft,{extrude:N(ac),tessellate:N(ac),altitudeMode:N(Ct),coordinates:N(lX)});function Oh(s,t,e){const i=t.getFlatCoordinates(),n={node:s};n.layout=t.getLayout(),n.stride=t.getStride();const r=t.getProperties();r.coordinates=i;const o=e[e.length-1].node,a=kX[o.namespaceURI],l=Ai(r,a);Tt(n,$X,Is,l,e,a)}const GX=B(ft,["color","fill","outline"]),P2=B(ft,{outerBoundaryIs:N(I2),innerBoundaryIs:N(I2)}),jX=Xe("innerBoundaryIs"),zX=Xe("outerBoundaryIs");function _P(s,t,e){const i=t.getLinearRings(),n=i.shift(),r={node:s};Tt(r,P2,jX,i,e),Tt(r,P2,zX,[n],e)}const UX=B(ft,{color:N(Hm),fill:N(ac),outline:N(ac)});function BX(s,t,e){const i={node:s},n=t.getFill(),r=t.getStroke(),o={color:n?n.getColor():void 0,fill:n?void 0:!1,outline:r?void 0:!1},a=e[e.length-1].node,l=GX[a.namespaceURI],h=Ai(o,l);Tt(i,UX,Is,h,e,l)}function yP(s,t){vi(s,Math.round(t*1e6)/1e6)}const WX=B(ft,["IconStyle","LabelStyle","LineStyle","PolyStyle"]),XX=B(ft,{IconStyle:N(wX),LabelStyle:N(MX),LineStyle:N(TX),PolyStyle:N(BX)});function VX(s,t,e){const i={node:s},n={};if(t.pointStyles.length){const l=t.pointStyles[0].getText();l&&(n.LabelStyle=l);const h=t.pointStyles[0].getImage();h&&typeof h.getSrc=="function"&&(n.IconStyle=h)}if(t.lineStyles.length){const l=t.lineStyles[0].getStroke();l&&(n.LineStyle=l)}if(t.polyStyles.length){const l=t.polyStyles[0].getStroke();l&&!n.LineStyle&&(n.LineStyle=l),n.PolyStyle=t.polyStyles[0]}const r=e[e.length-1].node,o=WX[r.namespaceURI],a=Ai(n,o);Tt(i,XX,Is,a,e,o)}function YX(s,t){s.setAttribute("x",String(t.x)),s.setAttribute("y",String(t.y)),s.setAttribute("xunits",t.xunits),s.setAttribute("yunits",t.yunits)}const qX=xW,ny=65536*65536,A2=1/ny,ZX=12,L2=typeof TextDecoder>"u"?null:new TextDecoder("utf-8"),C_=0,mf=1,iu=2,_f=5;class HX{constructor(t=new Uint8Array(16)){this.buf=ArrayBuffer.isView(t)?t:new Uint8Array(t),this.dataView=new DataView(this.buf.buffer),this.pos=0,this.type=0,this.length=this.buf.length}readFields(t,e,i=this.length){for(;this.pos>3,o=this.pos;this.type=n&7,t(r,e,this),this.pos===o&&this.skip(n)}return e}readMessage(t,e){return this.readFields(t,e,this.readVarint()+this.pos)}readFixed32(){const t=this.dataView.getUint32(this.pos,!0);return this.pos+=4,t}readSFixed32(){const t=this.dataView.getInt32(this.pos,!0);return this.pos+=4,t}readFixed64(){const t=this.dataView.getUint32(this.pos,!0)+this.dataView.getUint32(this.pos+4,!0)*ny;return this.pos+=8,t}readSFixed64(){const t=this.dataView.getUint32(this.pos,!0)+this.dataView.getInt32(this.pos+4,!0)*ny;return this.pos+=8,t}readFloat(){const t=this.dataView.getFloat32(this.pos,!0);return this.pos+=4,t}readDouble(){const t=this.dataView.getFloat64(this.pos,!0);return this.pos+=8,t}readVarint(t){const e=this.buf;let i,n;return n=e[this.pos++],i=n&127,n<128||(n=e[this.pos++],i|=(n&127)<<7,n<128)||(n=e[this.pos++],i|=(n&127)<<14,n<128)||(n=e[this.pos++],i|=(n&127)<<21,n<128)?i:(n=e[this.pos],i|=(n&15)<<28,KX(i,t,this))}readVarint64(){return this.readVarint(!0)}readSVarint(){const t=this.readVarint();return t%2===1?(t+1)/-2:t/2}readBoolean(){return!!this.readVarint()}readString(){const t=this.readVarint()+this.pos,e=this.pos;return this.pos=t,t-e>=ZX&&L2?L2.decode(this.buf.subarray(e,t)):uV(this.buf,e,t)}readBytes(){const t=this.readVarint()+this.pos,e=this.buf.subarray(this.pos,t);return this.pos=t,e}readPackedVarint(t=[],e){const i=this.readPackedEnd();for(;this.pos127;);else if(e===iu)this.pos=this.readVarint()+this.pos;else if(e===_f)this.pos+=4;else if(e===mf)this.pos+=8;else throw new Error(`Unimplemented type: ${e}`)}writeTag(t,e){this.writeVarint(t<<3|e)}realloc(t){let e=this.length||16;for(;e268435455||t<0){QX(t,this);return}this.realloc(4),this.buf[this.pos++]=t&127|(t>127?128:0),!(t<=127)&&(this.buf[this.pos++]=(t>>>=7)&127|(t>127?128:0),!(t<=127)&&(this.buf[this.pos++]=(t>>>=7)&127|(t>127?128:0),!(t<=127)&&(this.buf[this.pos++]=t>>>7&127)))}writeSVarint(t){this.writeVarint(t<0?-t*2-1:t*2)}writeBoolean(t){this.writeVarint(+t)}writeString(t){t=String(t),this.realloc(t.length*4),this.pos++;const e=this.pos;this.pos=dV(this.buf,t,this.pos);const i=this.pos-e;i>=128&&O2(e,i,this),this.pos=e-1,this.writeVarint(i),this.pos+=i}writeFloat(t){this.realloc(4),this.dataView.setFloat32(this.pos,t,!0),this.pos+=4}writeDouble(t){this.realloc(8),this.dataView.setFloat64(this.pos,t,!0),this.pos+=8}writeBytes(t){const e=t.length;this.writeVarint(e),this.realloc(e);for(let i=0;i=128&&O2(i,n,this),this.pos=i-1,this.writeVarint(n),this.pos+=n}writeMessage(t,e,i){this.writeTag(t,iu),this.writeRawMessage(e,i)}writePackedVarint(t,e){e.length&&this.writeMessage(t,sV,e)}writePackedSVarint(t,e){e.length&&this.writeMessage(t,iV,e)}writePackedBoolean(t,e){e.length&&this.writeMessage(t,oV,e)}writePackedFloat(t,e){e.length&&this.writeMessage(t,nV,e)}writePackedDouble(t,e){e.length&&this.writeMessage(t,rV,e)}writePackedFixed32(t,e){e.length&&this.writeMessage(t,aV,e)}writePackedSFixed32(t,e){e.length&&this.writeMessage(t,lV,e)}writePackedFixed64(t,e){e.length&&this.writeMessage(t,hV,e)}writePackedSFixed64(t,e){e.length&&this.writeMessage(t,cV,e)}writeBytesField(t,e){this.writeTag(t,iu),this.writeBytes(e)}writeFixed32Field(t,e){this.writeTag(t,_f),this.writeFixed32(e)}writeSFixed32Field(t,e){this.writeTag(t,_f),this.writeSFixed32(e)}writeFixed64Field(t,e){this.writeTag(t,mf),this.writeFixed64(e)}writeSFixed64Field(t,e){this.writeTag(t,mf),this.writeSFixed64(e)}writeVarintField(t,e){this.writeTag(t,C_),this.writeVarint(e)}writeSVarintField(t,e){this.writeTag(t,C_),this.writeSVarint(e)}writeStringField(t,e){this.writeTag(t,iu),this.writeString(e)}writeFloatField(t,e){this.writeTag(t,_f),this.writeFloat(e)}writeDoubleField(t,e){this.writeTag(t,mf),this.writeDouble(e)}writeBooleanField(t,e){this.writeVarintField(t,+e)}}function KX(s,t,e){const i=e.buf;let n,r;if(r=i[e.pos++],n=(r&112)>>4,r<128||(r=i[e.pos++],n|=(r&127)<<3,r<128)||(r=i[e.pos++],n|=(r&127)<<10,r<128)||(r=i[e.pos++],n|=(r&127)<<17,r<128)||(r=i[e.pos++],n|=(r&127)<<24,r<128)||(r=i[e.pos++],n|=(r&1)<<31,r<128))return JX(s,n,t);throw new Error("Expected varint not more than 10 bytes")}function JX(s,t,e){return e?t*4294967296+(s>>>0):(t>>>0)*4294967296+(s>>>0)}function QX(s,t){let e,i;if(s>=0?(e=s%4294967296|0,i=s/4294967296|0):(e=~(-s%4294967296),i=~(-s/4294967296),e^4294967295?e=e+1|0:(e=0,i=i+1|0)),s>=18446744073709552e3||s<-18446744073709552e3)throw new Error("Given varint doesn't fit into 10 bytes");t.realloc(10),tV(e,i,t),eV(i,t)}function tV(s,t,e){e.buf[e.pos++]=s&127|128,s>>>=7,e.buf[e.pos++]=s&127|128,s>>>=7,e.buf[e.pos++]=s&127|128,s>>>=7,e.buf[e.pos++]=s&127|128,s>>>=7,e.buf[e.pos]=s&127}function eV(s,t){const e=(s&7)<<4;t.buf[t.pos++]|=e|((s>>>=3)?128:0),s&&(t.buf[t.pos++]=s&127|((s>>>=7)?128:0),s&&(t.buf[t.pos++]=s&127|((s>>>=7)?128:0),s&&(t.buf[t.pos++]=s&127|((s>>>=7)?128:0),s&&(t.buf[t.pos++]=s&127|((s>>>=7)?128:0),s&&(t.buf[t.pos++]=s&127)))))}function O2(s,t,e){const i=t<=16383?1:t<=2097151?2:t<=268435455?3:Math.floor(Math.log(t)/(Math.LN2*7));e.realloc(i);for(let n=e.pos-1;n>=s;n--)e.buf[n+i]=e.buf[n]}function sV(s,t){for(let e=0;e239?4:r>223?3:r>191?2:1;if(n+a>e)break;let l,h,c;a===1?r<128&&(o=r):a===2?(l=s[n+1],(l&192)===128&&(o=(r&31)<<6|l&63,o<=127&&(o=null))):a===3?(l=s[n+1],h=s[n+2],(l&192)===128&&(h&192)===128&&(o=(r&15)<<12|(l&63)<<6|h&63,(o<=2047||o>=55296&&o<=57343)&&(o=null))):a===4&&(l=s[n+1],h=s[n+2],c=s[n+3],(l&192)===128&&(h&192)===128&&(c&192)===128&&(o=(r&15)<<18|(l&63)<<12|(h&63)<<6|c&63,(o<=65535||o>=1114112)&&(o=null))),o===null?(o=65533,a=1):o>65535&&(o-=65536,i+=String.fromCharCode(o>>>10&1023|55296),o=56320|o&1023),i+=String.fromCharCode(o),n+=a}return i}function dV(s,t,e){for(let i=0,n,r;i55295&&n<57344)if(r)if(n<56320){s[e++]=239,s[e++]=191,s[e++]=189,r=n;continue}else n=r-55296<<10|n-56320|65536,r=null;else{n>56319||i+1===t.length?(s[e++]=239,s[e++]=191,s[e++]=189):r=n;continue}else r&&(s[e++]=239,s[e++]=191,s[e++]=189,r=null);n<128?s[e++]=n:(n<2048?s[e++]=n>>6|192:(n<65536?s[e++]=n>>12|224:(s[e++]=n>>18|240,s[e++]=n>>12&63|128),s[e++]=n>>6&63|128),s[e++]=n&63|128)}return e}class gV extends Sg{constructor(t){super(),t=t||{},this.dataProjection=new rc({code:"",units:"tile-pixels"}),this.featureClass=t.featureClass?t.featureClass:si,this.geometryName_=t.geometryName,this.layerName_=t.layerName?t.layerName:"layer",this.layers_=t.layers?t.layers:null,this.idProperty_=t.idProperty,this.supportedMediaTypes=["application/vnd.mapbox-vector-tile","application/x-protobuf"]}readRawGeometry_(t,e,i,n){t.pos=e.geometry;const r=t.readVarint()+t.pos;let o=1,a=0,l=0,h=0,c=0,u=0;for(;t.pos>3}if(a--,o===1||o===2)l+=t.readSVarint(),h+=t.readSVarint(),o===1&&c>u&&(n.push(c),u=c),i.push(l,h),c+=2;else if(o===7)c>u&&(i.push(i[u],i[u+1]),c+=2);else throw new Error("Invalid command found in the PBF")}c>u&&(n.push(c),u=c)}createFeature_(t,e,i){const n=e.type;if(n===0)return null;let r;const o=e.properties;let a;this.idProperty_?(a=o[this.idProperty_],delete o[this.idProperty_]):a=e.id,o[this.layerName_]=e.layer.name;const l=[],h=[];this.readRawGeometry_(t,e,l,h);const c=yV(n,h.length);if(this.featureClass===si)r=new this.featureClass(c,l,h,2,o,a),r.transform(i.dataProjection);else{let u;if(c=="Polygon"){const f=OI(l,h);u=f.length>1?new vn(l,"XY",f):new Hs(l,"XY",h)}else u=c==="Point"?new Cs(l,"XY"):c==="LineString"?new ls(l,"XY"):c==="MultiPoint"?new Zn(l,"XY"):c==="MultiLineString"?new Pi(l,"XY",h):null;const d=this.featureClass;r=new d,this.geometryName_&&r.setGeometryName(this.geometryName_);const g=De(u,!1,i);r.setGeometry(g),a!==void 0&&r.setId(a),r.setProperties(o,!0)}return r}getType(){return"arraybuffer"}readFeatures(t,e){const i=this.layers_;e=this.adaptOptions(e);const n=st(e.dataProjection);n.setWorldExtent(e.extent),e.dataProjection=n;const r=new HX(t),o=r.readFields(fV,{}),a=[];for(const l in o){if(i&&!i.includes(l))continue;const h=o[l],c=h?[0,0,h.extent,h.extent]:null;n.setExtent(c);for(let u=0,d=h.length;u>3,i=s===1?e.readString():s===2?e.readFloat():s===3?e.readDouble():s===4?e.readVarint64():s===5?e.readVarint():s===6?e.readSVarint():s===7?e.readBoolean():null;t.values.push(i)}}function mV(s,t,e){if(s==1)t.id=e.readVarint();else if(s==2){const i=e.readVarint()+e.pos;for(;e.pos>1):n>>1}return t}function sY(s){let t="";for(let e=0,i=s.length;e=32;)t=(32|s&31)+63,e+=String.fromCharCode(t),s>>=5;return t=s+63,e+=String.fromCharCode(t),e}const rY=ZV;class oY extends gv{constructor(t){super(),t=t||{},this.layerName_=t.layerName,this.layers_=t.layers?t.layers:null,this.dataProjection=st(t.dataProjection?t.dataProjection:"EPSG:4326")}readFeaturesFromObject(t,e){if(t.type=="Topology"){const i=t;let n,r=null,o=null;i.transform&&(n=i.transform,r=n.scale,o=n.translate);const a=i.arcs;n&&pY(a,r,o);const l=[],h=i.objects,c=this.layerName_;let u;for(const d in h)this.layers_&&!this.layers_.includes(d)||(h[d].type==="GeometryCollection"?(u=h[d],l.push.apply(l,fY(u,a,r,o,c,d,e))):(u=h[d],l.push(wP(u,a,r,o,c,d,e))));return l}return[]}readProjectionFromObject(t){return this.dataProjection}}const aY={Point:lY,LineString:cY,Polygon:dY,MultiPoint:hY,MultiLineString:uY,MultiPolygon:gY};function Km(s,t){const e=[];let i;for(let n=0,r=s.length;n0&&e.pop(),i>=0){const o=t[i];for(let a=0,l=o.length;a=0;--a)e.push(o[a].slice(0))}return e}function lY(s,t,e){const i=s.coordinates;return t&&e&&Pv(i,t,e),new Cs(i)}function hY(s,t,e){const i=s.coordinates;if(t&&e)for(let n=0,r=i.length;n=2,"At least 2 conditions are required")}}class xY extends yY{constructor(t){super("And",Array.prototype.slice.call(arguments))}}class vY extends EP{constructor(t,e,i){if(super("BBOX"),this.geometryName=t,this.extent=e,e.length!==4)throw new Error("Expected an extent with four values ([minX, minY, maxX, maxY])");this.srsName=i}}function wY(s){const t=[null].concat(Array.prototype.slice.call(arguments));return new(Function.prototype.bind.apply(xY,t))}function EY(s,t,e){return new vY(s,t,e)}const N2={"http://www.opengis.net/gml":{boundedBy:L(ut.prototype.readExtentElement,"bounds")},"http://www.opengis.net/wfs/2.0":{member:dt(ut.prototype.readFeaturesInternal)}},SY={"http://www.opengis.net/wfs":{totalInserted:L(qe),totalUpdated:L(qe),totalDeleted:L(qe)},"http://www.opengis.net/wfs/2.0":{totalInserted:L(qe),totalUpdated:L(qe),totalDeleted:L(qe)}},MY={"http://www.opengis.net/wfs":{TransactionSummary:L(k2,"transactionSummary"),InsertResults:L(G2,"insertIds")},"http://www.opengis.net/wfs/2.0":{TransactionSummary:L(k2,"transactionSummary"),InsertResults:L(G2,"insertIds")}},bY={"http://www.opengis.net/wfs":{PropertyName:N(Ct)},"http://www.opengis.net/wfs/2.0":{PropertyName:N(Ct)}},SP={"http://www.opengis.net/wfs":{Insert:N(j2),Update:N(U2),Delete:N(z2),Property:N(B2),Native:N(W2)},"http://www.opengis.net/wfs/2.0":{Insert:N(j2),Update:N(U2),Delete:N(z2),Property:N(B2),Native:N(W2)}},MP="feature",Av="http://www.w3.org/2000/xmlns/",Lv={"2.0.0":"http://www.opengis.net/ogc/1.1","1.1.0":"http://www.opengis.net/ogc","1.0.0":"http://www.opengis.net/ogc"},ry={"2.0.0":"http://www.opengis.net/wfs/2.0","1.1.0":"http://www.opengis.net/wfs","1.0.0":"http://www.opengis.net/wfs"},Ov={"2.0.0":"http://www.opengis.net/fes/2.0","1.1.0":"http://www.opengis.net/fes","1.0.0":"http://www.opengis.net/fes"},D2={"2.0.0":"http://www.opengis.net/wfs/2.0 http://schemas.opengis.net/wfs/2.0/wfs.xsd","1.1.0":"http://www.opengis.net/wfs http://schemas.opengis.net/wfs/1.1.0/wfs.xsd","1.0.0":"http://www.opengis.net/wfs http://schemas.opengis.net/wfs/1.0.0/wfs.xsd"},Fv={"2.0.0":ne,"1.1.0":Z,"1.0.0":Vt},CY="1.1.0";class TY extends bg{constructor(t){super(),t=t||{},this.version_=t.version?t.version:CY,this.featureType_=t.featureType,this.featureNS_=t.featureNS,this.gmlFormat_=t.gmlFormat?t.gmlFormat:new Fv[this.version_],this.schemaLocation_=t.schemaLocation?t.schemaLocation:D2[this.version_]}getFeatureType(){return this.featureType_}setFeatureType(t){this.featureType_=t}readFeaturesFromNode(t,e){const i={node:t};Object.assign(i,{featureType:this.featureType_,featureNS:this.featureNS_}),Object.assign(i,this.getReadOptions(t,e||{}));const n=[i];let r;this.version_==="2.0.0"?r=N2:r=this.gmlFormat_.FEATURE_COLLECTION_PARSERS;let o=Y([],r,t,n,this.gmlFormat_);return o||(o=[]),o}readTransactionResponse(t){if(t){if(typeof t=="string"){const e=dn(t);return this.readTransactionResponseFromDocument(e)}return un(t)?this.readTransactionResponseFromDocument(t):this.readTransactionResponseFromNode(t)}}readFeatureCollectionMetadata(t){if(t){if(typeof t=="string"){const e=dn(t);return this.readFeatureCollectionMetadataFromDocument(e)}return un(t)?this.readFeatureCollectionMetadataFromDocument(t):this.readFeatureCollectionMetadataFromNode(t)}}readFeatureCollectionMetadataFromDocument(t){for(let e=t.firstChild;e;e=e.nextSibling)if(e.nodeType==Node.ELEMENT_NODE)return this.readFeatureCollectionMetadataFromNode(e)}readFeatureCollectionMetadataFromNode(t){const e={},i=zr(t.getAttribute("numberOfFeatures"));return e.numberOfFeatures=i,Y(e,N2,t,[],this.gmlFormat_)}readTransactionResponseFromDocument(t){for(let e=t.firstChild;e;e=e.nextSibling)if(e.nodeType==Node.ELEMENT_NODE)return this.readTransactionResponseFromNode(e)}readTransactionResponseFromNode(t){return Y({},MY,t,[])}writeGetFeature(t){const e=It(ry[this.version_],"GetFeature");e.setAttribute("service","WFS"),e.setAttribute("version",this.version_),t.handle&&e.setAttribute("handle",t.handle),t.outputFormat&&e.setAttribute("outputFormat",t.outputFormat),t.maxFeatures!==void 0&&e.setAttribute("maxFeatures",String(t.maxFeatures)),t.resultType&&e.setAttribute("resultType",t.resultType),t.startIndex!==void 0&&e.setAttribute("startIndex",String(t.startIndex)),t.count!==void 0&&e.setAttribute("count",String(t.count)),t.viewParams!==void 0&&e.setAttribute("viewParams",t.viewParams),e.setAttributeNS(nl,"xsi:schemaLocation",this.schemaLocation_);const i={node:e};if(Object.assign(i,{version:this.version_,srsName:t.srsName,featureNS:t.featureNS?t.featureNS:this.featureNS_,featurePrefix:t.featurePrefix,propertyNames:t.propertyNames?t.propertyNames:[]}),qt(Array.isArray(t.featureTypes),"`options.featureTypes` must be an Array"),typeof t.featureTypes[0]=="string"){let n=t.filter;t.bbox&&(qt(t.geometryName,"`options.geometryName` must also be provided when `options.bbox` is set"),n=this.combineBboxAndFilter(t.geometryName,t.bbox,t.srsName,n)),Object.assign(i,{geometryName:t.geometryName,filter:n}),tM(e,t.featureTypes,[i])}else t.featureTypes.forEach(n=>{const r=this.combineBboxAndFilter(n.geometryName,n.bbox,t.srsName,t.filter);Object.assign(i,{geometryName:n.geometryName,filter:r}),tM(e,[n.name],[i])});return e}combineBboxAndFilter(t,e,i,n){const r=EY(t,e,i);return n?wY(n,r):r}writeTransaction(t,e,i,n){const r=[],o=n.version?n.version:this.version_,a=It(ry[o],"Transaction");a.setAttribute("service","WFS"),a.setAttribute("version",o);let l;n&&(l=n.gmlOptions?n.gmlOptions:{},n.handle&&a.setAttribute("handle",n.handle)),a.setAttributeNS(nl,"xsi:schemaLocation",D2[o]);const h=RY(a,l,o,n);return t&&yf("Insert",t,r,h),e&&yf("Update",e,r,h),i&&yf("Delete",i,r,h),n.nativeElements&&yf("Native",n.nativeElements,r,h),a}readProjectionFromDocument(t){for(let e=t.firstChild;e;e=e.nextSibling)if(e.nodeType==Node.ELEMENT_NODE)return this.readProjectionFromNode(e);return null}readProjectionFromNode(t){if(t.firstElementChild&&t.firstElementChild.firstElementChild){t=t.firstElementChild.firstElementChild;for(let e=t.firstElementChild;e;e=e.nextElementSibling)if(!(e.childNodes.length===0||e.childNodes.length===1&&e.firstChild.nodeType===3)){const i=[{}];return this.gmlFormat_.readGeometryElement(e,i),st(i.pop().srsName)}}return null}}function RY(s,t,e,i){const n=i.featurePrefix?i.featurePrefix:MP;let r;return e==="1.0.0"?r=2:e==="1.1.0"?r=3:e==="2.0.0"&&(r=3.2),Object.assign({node:s},{version:e,featureNS:i.featureNS,featureType:i.featureType,featurePrefix:n,gmlVersion:r,hasZ:i.hasZ,srsName:i.srsName},t)}function yf(s,t,e,i){Tt(i,SP,Xe(s),t,e)}function k2(s,t){return Y({},SY,s,t)}const IY={"http://www.opengis.net/ogc":{FeatureId:dt(function(s,t){return s.getAttribute("fid")})},"http://www.opengis.net/ogc/1.1":{FeatureId:dt(function(s,t){return s.getAttribute("fid")})}};function $2(s,t){Ii(IY,s,t)}const PY={"http://www.opengis.net/wfs":{Feature:$2},"http://www.opengis.net/wfs/2.0":{Feature:$2}};function G2(s,t){return Y([],PY,s,t)}function j2(s,t,e){const i=e[e.length-1],n=i.featureType,r=i.featureNS,o=i.gmlVersion,a=It(r,n);s.appendChild(a),o===2?Vt.prototype.writeFeatureElement(a,t,e):o===3?Z.prototype.writeFeatureElement(a,t,e):ne.prototype.writeFeatureElement(a,t,e)}function bP(s,t,e){const i=e[e.length-1].version,n=Lv[i],r=It(n,"Filter"),o=It(n,"FeatureId");r.appendChild(o),o.setAttribute("fid",t),s.appendChild(r)}function Nv(s,t){s=s||MP;const e=s+":";return t.startsWith(e)?t:e+t}function z2(s,t,e){const i=e[e.length-1];qt(t.getId()!==void 0,"Features must have an id set");const n=i.featureType,r=i.featurePrefix,o=i.featureNS,a=Nv(r,n);s.setAttribute("typeName",a),s.setAttributeNS(Av,"xmlns:"+r,o);const l=t.getId();l!==void 0&&bP(s,l,e)}function U2(s,t,e){const i=e[e.length-1];qt(t.getId()!==void 0,"Features must have an id set");const n=i.version,r=i.featureType,o=i.featurePrefix,a=i.featureNS,l=Nv(o,r),h=t.getGeometryName();s.setAttribute("typeName",l),s.setAttributeNS(Av,"xmlns:"+o,a);const c=t.getId();if(c!==void 0){const u=t.getKeys(),d=[];for(let g=0,f=u.length;g0,i=this.readUint32(e),n=Math.floor((i&268435455)/1e3),r=!!(i&2147483648)||n===1||n===3,o=!!(i&1073741824)||n===2||n===3,a=!!(i&536870912),l=(i&268435455)%1e3,h=["XY",r?"Z":"",o?"M":""].join(""),c=a?this.readUint32(e):null;if(t!==void 0&&t!==l)throw new Error("Unexpected WKB geometry type "+l);if(this.initialized_){if(this.isLittleEndian_!==e)throw new Error("Inconsistent endian");if(this.layout_!==h)throw new Error("Inconsistent geometry layout");if(c&&this.srid_!==c)throw new Error("Inconsistent coordinate system (SRID)")}else this.isLittleEndian_=e,this.hasZ_=r,this.hasM_=o,this.layout_=h,this.srid_=c,this.initialized_=!0;return l}readWkbPayload(t){switch(t){case pe.POINT:return this.readPoint();case pe.LINE_STRING:return this.readLineString();case pe.POLYGON:case pe.TRIANGLE:return this.readPolygon();case pe.MULTI_POINT:return this.readMultiPoint();case pe.MULTI_LINE_STRING:return this.readMultiLineString();case pe.MULTI_POLYGON:case pe.POLYHEDRAL_SURFACE:case pe.TIN:return this.readMultiPolygon();case pe.GEOMETRY_COLLECTION:return this.readGeometryCollection();default:throw new Error("Unsupported WKB geometry type "+t+" is found")}}readWkbBlock(t){return this.readWkbPayload(this.readWkbHeader(t))}readWkbCollection(t,e){const i=this.readUint32(),n=[];for(let r=0;r({[n]:t[r]})));for(const n of this.layout_)this.writeDouble(n in i?i[n]:this.nodata_[n])}writeLineString(t,e){this.writeUint32(t.length);for(let i=0;in===r?n:n==="XYZM"?r:r==="XYZM"?n:"XY";if(t instanceof io)return i(t.getLayout(),e);if(t instanceof _s){const n=t.getGeometriesArray();for(let r=0;rr+o[0],0),e=new ArrayBuffer(t),i=new DataView(e);let n=0;return this.writeQueue_.forEach(r=>{switch(r[0]){case 1:i.setUint8(n,r[1]);break;case 4:i.setUint32(n,r[1],this.isLittleEndian_);break;case 8:i.setFloat64(n,r[1],this.isLittleEndian_);break}n+=r[0]}),e}}class NY extends Sg{constructor(t){super(),t=t||{},this.splitCollection=!!t.splitCollection,this.viewCache_=null,this.hex_=t.hex!==!1,this.littleEndian_=t.littleEndian!==!1,this.ewkb_=t.ewkb!==!1,this.layout_=t.geometryLayout,this.nodataZ_=t.nodataZ||0,this.nodataM_=t.nodataM||0,this.srid_=t.srid}getType(){return this.hex_?"text":"arraybuffer"}readFeature(t,e){return new ys({geometry:this.readGeometry(t,e)})}readFeatures(t,e){let i=[];const n=this.readGeometry(t,e);return this.splitCollection&&n instanceof _s?i=n.getGeometriesArray():i=[n],i.map(r=>new ys({geometry:r}))}readGeometry(t,e){const i=sM(t);if(!i)return null;const n=new eM(i).readGeometry();return this.viewCache_=i,e=this.getReadOptions(t,e),this.viewCache_=null,De(n,!1,e)}readProjection(t){const e=this.viewCache_||sM(t);if(!e)return;const i=new eM(e);return i.readWkbHeader(),i.getSrid()&&st("EPSG:"+i.getSrid())||void 0}writeFeature(t,e){return this.writeGeometry(t.getGeometry(),e)}writeFeatures(t,e){return this.writeGeometry(new _s(t.map(i=>i.getGeometry())),e)}writeGeometry(t,e){e=this.adaptOptions(e);const i=new FY({layout:this.layout_,littleEndian:this.littleEndian_,ewkb:this.ewkb_,nodata:{Z:this.nodataZ_,M:this.nodataM_}});let n=Number.isInteger(this.srid_)?Number(this.srid_):null;if(this.srid_!==!1&&!Number.isInteger(this.srid_)){const o=e.dataProjection&&st(e.dataProjection);if(o){const a=o.getCode();a.startsWith("EPSG:")&&(n=Number(a.substring(5)))}}i.writeGeometry(De(t,!0,e),n);const r=i.getBuffer();return this.hex_?DY(r):r}}function DY(s){const t=new Uint8Array(s);return Array.from(t.values()).map(e=>(e<16?"0":"")+Number(e).toString(16).toUpperCase()).join("")}function kY(s){const t=new Uint8Array(s.length/2);for(let e=0;e="a"&&t<="z"||t>="A"&&t<="Z"}isNumeric_(t,e){return e=e!==void 0?e:!1,t>="0"&&t<="9"||t=="."&&!e}isWhiteSpace_(t){return t==" "||t==" "||t=="\r"||t==` +`}nextChar_(){return this.wkt.charAt(++this.index_)}nextToken(){const t=this.nextChar_(),e=this.index_;let i=t,n;if(t=="(")n=ce.LEFT_PAREN;else if(t==",")n=ce.COMMA;else if(t==")")n=ce.RIGHT_PAREN;else if(this.isNumeric_(t)||t=="-")n=ce.NUMBER,i=this.readNumber_();else if(this.isAlpha_(t))n=ce.TEXT,i=this.readText_();else{if(this.isWhiteSpace_(t))return this.nextToken();if(t==="")n=ce.EOF;else throw new Error("Unexpected character: "+t)}return{position:e,value:i,type:n}}readNumber_(){let t;const e=this.index_;let i=!1,n=!1;do t=="."?i=!0:(t=="e"||t=="E")&&(n=!0),t=this.nextChar_();while(this.isNumeric_(t,i)||!n&&(t=="e"||t=="E")||n&&(t=="-"||t=="+"));return parseFloat(this.wkt.substring(e,this.index_--))}readText_(){let t;const e=this.index_;do t=this.nextChar_();while(this.isAlpha_(t));return this.wkt.substring(e,this.index_--).toUpperCase()}}let BY=class{constructor(s){this.lexer_=s,this.token_={position:0,type:ce.START},this.layout_="XY"}consume_(){this.token_=this.lexer_.nextToken()}isTokenType(s){return this.token_.type==s}match(s){const t=this.isTokenType(s);return t&&this.consume_(),t}parse(){return this.consume_(),this.parseGeometry_()}parseGeometryLayout_(){let s="XY";const t=this.token_;if(this.isTokenType(ce.TEXT)){const e=t.value;e===TP?s="XYZ":e===RP?s="XYM":e===jY&&(s="XYZM"),s!=="XY"&&this.consume_()}return s}parseGeometryCollectionText_(){if(this.match(ce.LEFT_PAREN)){const s=[];do s.push(this.parseGeometry_());while(this.match(ce.COMMA));if(this.match(ce.RIGHT_PAREN))return s}throw new Error(this.formatErrorMessage_())}parsePointText_(){if(this.match(ce.LEFT_PAREN)){const s=this.parsePoint_();if(this.match(ce.RIGHT_PAREN))return s}throw new Error(this.formatErrorMessage_())}parseLineStringText_(){if(this.match(ce.LEFT_PAREN)){const s=this.parsePointList_();if(this.match(ce.RIGHT_PAREN))return s}throw new Error(this.formatErrorMessage_())}parsePolygonText_(){if(this.match(ce.LEFT_PAREN)){const s=this.parseLineStringTextList_();if(this.match(ce.RIGHT_PAREN))return s}throw new Error(this.formatErrorMessage_())}parseMultiPointText_(){if(this.match(ce.LEFT_PAREN)){let s;if(this.token_.type==ce.LEFT_PAREN?s=this.parsePointTextList_():s=this.parsePointList_(),this.match(ce.RIGHT_PAREN))return s}throw new Error(this.formatErrorMessage_())}parseMultiLineStringText_(){if(this.match(ce.LEFT_PAREN)){const s=this.parseLineStringTextList_();if(this.match(ce.RIGHT_PAREN))return s}throw new Error(this.formatErrorMessage_())}parseMultiPolygonText_(){if(this.match(ce.LEFT_PAREN)){const s=this.parsePolygonTextList_();if(this.match(ce.RIGHT_PAREN))return s}throw new Error(this.formatErrorMessage_())}parsePoint_(){const s=[],t=this.layout_.length;for(let e=0;e0&&(n+=" "+r)}return i.length===0?n+" "+CP:n+"("+i+")"}const KY=WY,$s=[null,"http://www.opengis.net/wms"],JY=B($s,{Service:L(xq),Capability:L(yq)}),QY=B($s,{Request:L(Cq),Exception:L(Sq),Layer:L(Mq)});class tq extends Iv{constructor(){super(),this.version=void 0}readFromNode(t){return this.version=t.getAttribute("version").trim(),Y({version:this.version},JY,t,[])||null}}const eq=B($s,{Name:L(q),Title:L(q),Abstract:L(q),KeywordList:L(NP),OnlineResource:L(Ic),ContactInformation:L(vq),Fees:L(q),AccessConstraints:L(q),LayerLimit:L(qe),MaxWidth:L(qe),MaxHeight:L(qe)}),sq=B($s,{ContactPersonPrimary:L(wq),ContactPosition:L(q),ContactAddress:L(Eq),ContactVoiceTelephone:L(q),ContactFacsimileTelephone:L(q),ContactElectronicMailAddress:L(q)}),iq=B($s,{ContactPerson:L(q),ContactOrganization:L(q)}),nq=B($s,{AddressType:L(q),Address:L(q),City:L(q),StateOrProvince:L(q),PostCode:L(q),Country:L(q)}),rq=B($s,{Format:dt(q)}),LP=B($s,{Name:L(q),Title:L(q),Abstract:L(q),KeywordList:L(NP),CRS:Me(q),EX_GeographicBoundingBox:L(_q),BoundingBox:Me(mq),Dimension:Me(bq),Attribution:L(pq),AuthorityURL:Me(Iq),Identifier:Me(q),MetadataURL:Me(Pq),DataURL:Me(no),FeatureListURL:Me(no),Style:Me(Aq),MinScaleDenominator:L(Yt),MaxScaleDenominator:L(Yt),Layer:Me(OP)}),oq=B($s,{Title:L(q),OnlineResource:L(Ic),LogoURL:L(FP)}),aq=B($s,{westBoundLongitude:L(Yt),eastBoundLongitude:L(Yt),southBoundLatitude:L(Yt),northBoundLatitude:L(Yt)}),lq=B($s,{GetCapabilities:L(T_),GetMap:L(T_),GetFeatureInfo:L(T_)}),hq=B($s,{Format:Me(q),DCPType:Me(Tq)}),cq=B($s,{HTTP:L(Rq)}),uq=B($s,{Get:L(no),Post:L(no)}),dq=B($s,{Name:L(q),Title:L(q),Abstract:L(q),LegendURL:Me(FP),StyleSheetURL:L(no),StyleURL:L(no)}),gq=B($s,{Format:L(q),OnlineResource:L(Ic)}),fq=B($s,{Keyword:dt(q)});function pq(s,t){return Y({},oq,s,t)}function mq(s,t){const e=[Dr(s.getAttribute("minx")),Dr(s.getAttribute("miny")),Dr(s.getAttribute("maxx")),Dr(s.getAttribute("maxy"))],i=[Dr(s.getAttribute("resx")),Dr(s.getAttribute("resy"))];return{crs:s.getAttribute("CRS"),extent:e,res:i}}function _q(s,t){const e=Y({},aq,s,t);if(!e)return;const i=e.westBoundLongitude,n=e.southBoundLatitude,r=e.eastBoundLongitude,o=e.northBoundLatitude;if(!(i===void 0||n===void 0||r===void 0||o===void 0))return[i,n,r,o]}function yq(s,t){return Y({},QY,s,t)}function xq(s,t){return Y({},eq,s,t)}function vq(s,t){return Y({},sq,s,t)}function wq(s,t){return Y({},iq,s,t)}function Eq(s,t){return Y({},nq,s,t)}function Sq(s,t){return Y([],rq,s,t)}function Mq(s,t){const e=Y({},LP,s,t);return e.Layer===void 0?Object.assign(e,OP(s,t)):e}function OP(s,t){const e=t[t.length-1],i=Y({},LP,s,t);if(!i)return;let n=Va(s.getAttribute("queryable"));n===void 0&&(n=e.queryable),i.queryable=n!==void 0?n:!1;let r=zr(s.getAttribute("cascaded"));r===void 0&&(r=e.cascaded),i.cascaded=r;let o=Va(s.getAttribute("opaque"));o===void 0&&(o=e.opaque),i.opaque=o!==void 0?o:!1;let a=Va(s.getAttribute("noSubsets"));a===void 0&&(a=e.noSubsets),i.noSubsets=a!==void 0?a:!1;let l=Dr(s.getAttribute("fixedWidth"));l||(l=e.fixedWidth),i.fixedWidth=l;let h=Dr(s.getAttribute("fixedHeight"));return h||(h=e.fixedHeight),i.fixedHeight=h,["Style","CRS","AuthorityURL"].forEach(function(c){if(c in e){const u=i[c]||[];i[c]=u.concat(e[c])}}),["EX_GeographicBoundingBox","BoundingBox","Dimension","Attribution","MinScaleDenominator","MaxScaleDenominator"].forEach(function(c){if(!(c in i)){const u=e[c];i[c]=u}}),i}function bq(s,t){return{name:s.getAttribute("name"),units:s.getAttribute("units"),unitSymbol:s.getAttribute("unitSymbol"),default:s.getAttribute("default"),multipleValues:Va(s.getAttribute("multipleValues")),nearestValue:Va(s.getAttribute("nearestValue")),current:Va(s.getAttribute("current")),values:q(s)}}function no(s,t){return Y({},gq,s,t)}function Cq(s,t){return Y({},lq,s,t)}function Tq(s,t){return Y({},cq,s,t)}function Rq(s,t){return Y({},uq,s,t)}function T_(s,t){return Y({},hq,s,t)}function FP(s,t){const e=no(s,t);if(e){const i=[zr(s.getAttribute("width")),zr(s.getAttribute("height"))];return e.size=i,e}}function Iq(s,t){const e=no(s,t);if(e)return e.name=s.getAttribute("name"),e}function Pq(s,t){const e=no(s,t);if(e)return e.type=s.getAttribute("type"),e}function Aq(s,t){return Y({},dq,s,t)}function NP(s,t){return Y([],fq,s,t)}const Lq=tq,Oq="_feature",Fq="_layer";class Nq extends bg{constructor(t){super(),t=t||{},this.featureNS_="http://mapserver.gis.umn.edu/mapserver",this.gmlFormat_=new Vt,this.layers_=t.layers?t.layers:null}getLayers(){return this.layers_}setLayers(t){this.layers_=t}readFeatures_(t,e){t.setAttribute("namespaceURI",this.featureNS_);const i=t.localName;let n=[];if(t.childNodes.length===0)return n;if(i=="msGMLOutput")for(let r=0,o=t.childNodes.length;r0;)this.pop()}extend(s){for(let t=0,e=s.length;tthis.getLength())throw new Error("Index out of bounds: "+s);this.unique_&&this.assertUnique_(t),this.array_.splice(s,0,t),this.updateLength_(),this.dispatchEvent(new vf(Yo.ADD,t,s))}pop(){return this.removeAt(this.getLength()-1)}push(s){this.unique_&&this.assertUnique_(s);const t=this.getLength();return this.insertAt(t,s),this.getLength()}remove(s){const t=this.array_;for(let e=0,i=t.length;e=this.getLength())return;const t=this.array_[s];return this.array_.splice(s,1),this.updateLength_(),this.dispatchEvent(new vf(Yo.REMOVE,t,s)),t}setAt(s,t){const e=this.getLength();if(s>=e){this.insertAt(s,t);return}if(s<0)throw new Error("Index out of bounds: "+s);this.unique_&&this.assertUnique_(t,s);const i=this.array_[s];this.array_[s]=t,this.dispatchEvent(new vf(Yo.REMOVE,i,s)),this.dispatchEvent(new vf(Yo.ADD,t,s))}updateLength_(){this.set(iM.LENGTH,this.array_.length)}assertUnique_(s,t){for(let e=0,i=this.array_.length;eg&&(d=(g+d)/2,g=d),f>p&&(f=(p+f)/2,p=f);let m=Dt(i[0],d,g),_=Dt(i[1],f,p);if(o&&e&&n){const y=30*n;m+=-y*Math.log(1+Math.max(0,d-i[0])/y)+y*Math.log(1+Math.max(0,i[0]-g)/y),_+=-y*Math.log(1+Math.max(0,f-i[1])/y)+y*Math.log(1+Math.max(0,i[1]-p)/y)}return[m,_]}}function aZ(s){return s}function $v(s,t,e,i){const n=Rt(t)/e[0],r=Ee(t)/e[1];return i?Math.min(s,Math.max(n,r)):Math.min(s,Math.min(n,r))}function Gv(s,t,e){let i=Math.min(s,t);const n=50;return i*=Math.log(1+n*Math.max(0,s/t-1))/n+1,e&&(i=Math.max(i,e),i/=Math.log(1+n*Math.max(0,e/s-1))/n+1),Dt(i,e/2,t*2)}function lZ(s,t,e,i){return t=t!==void 0?t:!0,function(n,r,o,a){if(n!==void 0){const l=s[0],h=s[s.length-1],c=e?$v(l,e,o,i):l;if(a)return t?Gv(n,c,h):Dt(n,h,c);const u=Math.min(c,n),d=Math.floor(Om(s,u,r));return s[d]>c&&d1&&typeof arguments[e-1]=="function"&&(i=arguments[e-1],--e);let n=0;for(;n0}getInteracting(){return this.hints_[Ie.INTERACTING]>0}cancelAnimations(){this.setHint(Ie.ANIMATING,-this.hints_[Ie.ANIMATING]);let t;for(let e=0,i=this.animations_.length;e=0;--i){const n=this.animations_[i];let r=!0;for(let o=0,a=n.length;o0?h/l.duration:1;c>=1?(l.complete=!0,c=1):r=!1;const u=l.easing(c);if(l.sourceCenter){const d=l.sourceCenter[0],g=l.sourceCenter[1],f=l.targetCenter[0],p=l.targetCenter[1];this.nextCenter_=l.targetCenter;const m=d+u*(f-d),_=g+u*(p-g);this.targetCenter_=[m,_]}if(l.sourceResolution&&l.targetResolution){const d=u===1?l.targetResolution:l.sourceResolution+u*(l.targetResolution-l.sourceResolution);if(l.anchor){const g=this.getViewportSize_(this.getRotation()),f=this.constraints_.resolution(d,0,g,!0);this.targetCenter_=this.calculateCenterZoom(f,l.anchor)}this.nextResolution_=l.targetResolution,this.targetResolution_=d,this.applyTargetState_(!0)}if(l.sourceRotation!==void 0&&l.targetRotation!==void 0){const d=u===1?kn(l.targetRotation+Math.PI,2*Math.PI)-Math.PI:l.sourceRotation+u*(l.targetRotation-l.sourceRotation);if(l.anchor){const g=this.constraints_.rotation(d,!0);this.targetCenter_=this.calculateCenterRotate(g,l.anchor)}this.nextRotation_=l.targetRotation,this.targetRotation_=d}if(this.applyTargetState_(!0),e=!0,!l.complete)break}if(r){this.animations_[i]=null,this.setHint(Ie.ANIMATING,-1),this.nextCenter_=null,this.nextResolution_=NaN,this.nextRotation_=NaN;const o=n[0].callback;o&&wf(o,!0)}}this.animations_=this.animations_.filter(Boolean),e&&this.updateAnimationKey_===void 0&&(this.updateAnimationKey_=requestAnimationFrame(this.updateAnimations_.bind(this)))}calculateCenterRotate(t,e){let i;const n=this.getCenterInternal();return n!==void 0&&(i=[n[0]-e[0],n[1]-e[1]],S9(i,t-this.getRotation()),mI(i,e)),i}calculateCenterZoom(t,e){let i;const n=this.getCenterInternal(),r=this.getResolution();if(n!==void 0&&r!==void 0){const o=e[0]-t*(e[0]-n[0])/r,a=e[1]-t*(e[1]-n[1])/r;i=[o,a]}return i}getViewportSize_(t){const e=this.viewportSize_;if(t){const i=e[0],n=e[1];return[Math.abs(i*Math.cos(t))+Math.abs(n*Math.sin(t)),Math.abs(i*Math.sin(t))+Math.abs(n*Math.cos(t))]}return e}setViewportSize(t){this.viewportSize_=Array.isArray(t)?t.slice():[100,100],this.getAnimating()||this.resolveConstraints(0)}getCenter(){const t=this.getCenterInternal();return t&&X1(t,this.getProjection())}getCenterInternal(){return this.get(Rn.CENTER)}getConstraints(){return this.constraints_}getConstrainResolution(){return this.get("constrainResolution")}getHints(t){return t!==void 0?(t[0]=this.hints_[0],t[1]=this.hints_[1],t):this.hints_.slice()}calculateExtent(t){const e=this.calculateExtentInternal(t);return km(e,this.getProjection())}calculateExtentInternal(t){t=t||this.getViewportSizeMinusPadding_();const e=this.getCenterInternal();qt(e,"The view center is not defined");const i=this.getResolution();qt(i!==void 0,"The view resolution is not defined");const n=this.getRotation();return qt(n!==void 0,"The view rotation is not defined"),qx(e,i,n,t)}getMaxResolution(){return this.maxResolution_}getMinResolution(){return this.minResolution_}getMaxZoom(){return this.getZoomForResolution(this.minResolution_)}setMaxZoom(t){this.applyOptions_(this.getUpdatedOptions_({maxZoom:t}))}getMinZoom(){return this.getZoomForResolution(this.maxResolution_)}setMinZoom(t){this.applyOptions_(this.getUpdatedOptions_({minZoom:t}))}setConstrainResolution(t){this.applyOptions_(this.getUpdatedOptions_({constrainResolution:t}))}getProjection(){return this.projection_}getResolution(){return this.get(Rn.RESOLUTION)}getResolutions(){return this.resolutions_}getResolutionForExtent(t,e){return this.getResolutionForExtentInternal(cn(t,this.getProjection()),e)}getResolutionForExtentInternal(t,e){e=e||this.getViewportSizeMinusPadding_();const i=Rt(t)/e[0],n=Ee(t)/e[1];return Math.max(i,n)}getResolutionForValueFunction(t){t=t||2;const e=this.getConstrainedResolution(this.maxResolution_),i=this.minResolution_,n=Math.log(e/i)/Math.log(t);return function(r){return e/Math.pow(t,r*n)}}getRotation(){return this.get(Rn.ROTATION)}getValueForResolutionFunction(t){const e=Math.log(t||2),i=this.getConstrainedResolution(this.maxResolution_),n=this.minResolution_,r=Math.log(i/n)/e;return function(o){return Math.log(i/o)/e/r}}getViewportSizeMinusPadding_(t){let e=this.getViewportSize_(t);const i=this.padding_;return i&&(e=[e[0]-i[1]-i[3],e[1]-i[0]-i[2]]),e}getState(){const t=this.getProjection(),e=this.getResolution(),i=this.getRotation();let n=this.getCenterInternal();const r=this.padding_;if(r){const o=this.getViewportSizeMinusPadding_();n=I_(n,this.getViewportSize_(),[o[0]/2+r[3],o[1]/2+r[0]],e,i)}return{center:n.slice(0),projection:t!==void 0?t:null,resolution:e,nextCenter:this.nextCenter_,nextResolution:this.nextResolution_,nextRotation:this.nextRotation_,rotation:i,zoom:this.getZoom()}}getViewStateAndExtent(){return{viewState:this.getState(),extent:this.calculateExtent()}}getZoom(){let t;const e=this.getResolution();return e!==void 0&&(t=this.getZoomForResolution(e)),t}getZoomForResolution(t){let e=this.minZoom_||0,i,n;if(this.resolutions_){const r=Om(this.resolutions_,t,1);e=r,i=this.resolutions_[r],r==this.resolutions_.length-1?n=2:n=i/this.resolutions_[r+1]}else i=this.maxResolution_,n=this.zoomFactor_;return e+Math.log(i/t)/Math.log(n)}getResolutionForZoom(t){if(this.resolutions_){if(this.resolutions_.length<=1)return 0;const e=Dt(Math.floor(t),0,this.resolutions_.length-2),i=this.resolutions_[e]/this.resolutions_[e+1];return this.resolutions_[e]/Math.pow(i,Dt(t-e,0,1))}return this.maxResolution_/Math.pow(this.zoomFactor_,t-this.minZoom_)}fit(t,e){let i;if(qt(Array.isArray(t)||typeof t.getSimplifiedGeometry=="function","Invalid extent or geometry provided as `geometry`"),Array.isArray(t)){qt(!po(t),"Cannot fit empty extent provided as `geometry`");const n=cn(t,this.getProjection());i=g2(n)}else if(t.getType()==="Circle"){const n=cn(t.getExtent(),this.getProjection());i=g2(n),i.rotate(this.getRotation(),Rs(n))}else i=t;this.fitInternal(i,e)}rotatedExtentForGeometry(t){const e=this.getRotation(),i=Math.cos(e),n=Math.sin(-e),r=t.getFlatCoordinates(),o=t.getStride();let a=1/0,l=1/0,h=-1/0,c=-1/0;for(let u=0,d=r.length;u{this.dispatchEvent("sourceready")},0))),this.changed()}getFeatures(t){return this.renderer_?this.renderer_.getFeatures(t):Promise.resolve([])}getData(t){return!this.renderer_||!this.rendered?null:this.renderer_.getData(t)}isVisible(t){let e;const i=this.getMapInternal();!t&&i&&(t=i.getView()),t instanceof aM?e={viewState:t.getState(),extent:t.calculateExtent()}:e=t,!e.layerStatesArray&&i&&(e.layerStatesArray=i.getLayerGroup().getLayerStatesArray());let n;e.layerStatesArray?n=e.layerStatesArray.find(o=>o.layer===this):n=this.getLayerState();const r=this.getExtent();return vZ(n,e.viewState)&&(!r||Ce(r,e.extent))}getAttributions(t){var e;if(!this.isVisible(t))return[];const i=(e=this.getSource())==null?void 0:e.getAttributions();if(!i)return[];const n=t instanceof aM?t.getViewStateAndExtent():t;let r=i(n);return Array.isArray(r)||(r=[r]),r}render(t,e){const i=this.getRenderer();return i.prepareFrame(t)?(this.rendered=!0,i.renderFrame(t,e)):null}unrender(){this.rendered=!1}getDeclutter(){}renderDeclutter(t,e){}renderDeferred(t){const e=this.getRenderer();e&&e.renderDeferred(t)}setMapInternal(t){t||this.unrender(),this.set(ue.MAP,t)}getMapInternal(){return this.get(ue.MAP)}setMap(t){this.mapPrecomposeKey_&&(ms(this.mapPrecomposeKey_),this.mapPrecomposeKey_=null),t||this.changed(),this.mapRenderKey_&&(ms(this.mapRenderKey_),this.mapRenderKey_=null),t&&(this.mapPrecomposeKey_=We(t,Mi.PRECOMPOSE,e=>{const i=e.frameState.layerStatesArray,n=this.getLayerState(!1);qt(!i.some(function(r){return r.layer===n.layer}),"A layer can only be added to the map once. Use either `layer.setMap()` or `map.addLayer()`, not both."),i.push(n)}),this.mapRenderKey_=We(this,Zt.CHANGE,t.render,t),this.changed())}setSource(t){this.set(ue.SOURCE,t)}getRenderer(){return this.renderer_||(this.renderer_=this.createRenderer()),this.renderer_}hasRenderer(){return!!this.renderer_}createRenderer(){return null}disposeInternal(){this.renderer_&&(this.renderer_.dispose(),delete this.renderer_),this.setSource(null),super.disposeInternal()}}function vZ(s,t){if(!s.visible)return!1;const e=t.resolution;if(e=s.maxResolution)return!1;const i=t.zoom;return i>s.minZoom&&i<=s.maxZoom}const Tg=xZ;function wZ(s,t,e,i,n){zP(s,t,e||0,i||s.length-1,n||EZ)}function zP(s,t,e,i,n){for(;i>e;){if(i-e>600){var r=i-e+1,o=t-e+1,a=Math.log(r),l=.5*Math.exp(2*a/3),h=.5*Math.sqrt(a*l*(r-l)/r)*(o-r/2<0?-1:1),c=Math.max(e,Math.floor(t-o*l/r+h)),u=Math.min(i,Math.floor(t+(r-o)*l/r+h));zP(s,t,c,u,n)}var d=s[t],g=e,f=i;for(nu(s,e,t),n(s[i],d)>0&&nu(s,e,i);g0;)f--}n(s[e],d)===0?nu(s,e,f):(f++,nu(s,f,i)),f<=t&&(e=f+1),t<=f&&(i=f-1)}}function nu(s,t,e){var i=s[t];s[t]=s[e],s[e]=i}function EZ(s,t){return st?1:0}let jv=class{constructor(s=9){this._maxEntries=Math.max(4,s),this._minEntries=Math.max(2,Math.ceil(this._maxEntries*.4)),this.clear()}all(){return this._all(this.data,[])}search(s){let t=this.data;const e=[];if(!Sf(s,t))return e;const i=this.toBBox,n=[];for(;t;){for(let r=0;r=0&&n[t].children.length>this._maxEntries;)this._split(n,t),t--;this._adjustParentBBoxes(i,n,t)}_split(s,t){const e=s[t],i=e.children.length,n=this._minEntries;this._chooseSplitAxis(e,n,i);const r=this._chooseSplitIndex(e,n,i),o=Kl(e.children.splice(r,e.children.length-r));o.height=e.height,o.leaf=e.leaf,Nl(e,this.toBBox),Nl(o,this.toBBox),t?s[t-1].children.push(o):this._splitRoot(e,o)}_splitRoot(s,t){this.data=Kl([s,t]),this.data.height=s.height+1,this.data.leaf=!1,Nl(this.data,this.toBBox)}_chooseSplitIndex(s,t,e){let i,n=1/0,r=1/0;for(let o=t;o<=e-t;o++){const a=vu(s,0,o,this.toBBox),l=vu(s,o,e,this.toBBox),h=TZ(a,l),c=P_(a)+P_(l);h=t;l--){const h=s.children[l];wu(o,s.leaf?n(h):h),a+=Ef(o)}return a}_adjustParentBBoxes(s,t,e){for(let i=e;i>=0;i--)wu(t[i],s)}_condense(s){for(let t=s.length-1,e;t>=0;t--)s[t].children.length===0?t>0?(e=s[t-1].children,e.splice(e.indexOf(s[t]),1)):this.clear():Nl(s[t],this.toBBox)}};function SZ(s,t,e){if(!e)return t.indexOf(s);for(let i=0;i=s.minX&&t.maxY>=s.minY}function Kl(s){return{children:s,height:1,leaf:!0,minX:1/0,minY:1/0,maxX:-1/0,maxY:-1/0}}function lM(s,t,e,i,n){const r=[t,e];for(;r.length;){if(e=r.pop(),t=r.pop(),e-t<=i)continue;const o=t+Math.ceil((e-t)/i/2)*i;wZ(s,o,t,e,n),r.push(t,o,o,e)}}let bl=0;const Os=1<",GreaterThanOrEqualTo:">=",LessThan:"<",LessThanOrEqualTo:"<=",Multiply:"*",Divide:"/",Add:"+",Subtract:"-",Clamp:"clamp",Mod:"%",Pow:"^",Abs:"abs",Floor:"floor",Ceil:"ceil",Round:"round",Sin:"sin",Cos:"cos",Atan:"atan",Sqrt:"sqrt",Match:"match",Between:"between",Interpolate:"interpolate",Coalesce:"coalesce",Case:"case",In:"in",Number:"number",String:"string",Array:"array",Color:"color",Id:"id",Band:"band",Palette:"palette",ToString:"to-string"},PZ={[U.Get]:Nt(Xt(1,1/0),AZ),[U.Var]:Nt(Xt(1,1),LZ),[U.Id]:Nt(OZ,ru),[U.Concat]:Nt(Xt(2,1/0),he(bs)),[U.GeometryType]:Nt(FZ,ru),[U.Resolution]:Nt(ru),[U.Zoom]:Nt(ru),[U.Time]:Nt(ru),[U.Any]:Nt(Xt(2,1/0),he(Os)),[U.All]:Nt(Xt(2,1/0),he(Os)),[U.Not]:Nt(Xt(1,1),he(Os)),[U.Equal]:Nt(Xt(2,2),he(Mf)),[U.NotEqual]:Nt(Xt(2,2),he(Mf)),[U.GreaterThan]:Nt(Xt(2,2),he(lt)),[U.GreaterThanOrEqualTo]:Nt(Xt(2,2),he(lt)),[U.LessThan]:Nt(Xt(2,2),he(lt)),[U.LessThanOrEqualTo]:Nt(Xt(2,2),he(lt)),[U.Multiply]:Nt(Xt(2,1/0),hM),[U.Coalesce]:Nt(Xt(2,1/0),hM),[U.Divide]:Nt(Xt(2,2),he(lt)),[U.Add]:Nt(Xt(2,1/0),he(lt)),[U.Subtract]:Nt(Xt(2,2),he(lt)),[U.Clamp]:Nt(Xt(3,3),he(lt)),[U.Mod]:Nt(Xt(2,2),he(lt)),[U.Pow]:Nt(Xt(2,2),he(lt)),[U.Abs]:Nt(Xt(1,1),he(lt)),[U.Floor]:Nt(Xt(1,1),he(lt)),[U.Ceil]:Nt(Xt(1,1),he(lt)),[U.Round]:Nt(Xt(1,1),he(lt)),[U.Sin]:Nt(Xt(1,1),he(lt)),[U.Cos]:Nt(Xt(1,1),he(lt)),[U.Atan]:Nt(Xt(1,2),he(lt)),[U.Sqrt]:Nt(Xt(1,1),he(lt)),[U.Match]:Nt(Xt(4,1/0),cM,DZ),[U.Between]:Nt(Xt(3,3),he(lt)),[U.Interpolate]:Nt(Xt(6,1/0),cM,kZ),[U.Case]:Nt(Xt(3,1/0),NZ,$Z),[U.In]:Nt(Xt(2,2),GZ),[U.Number]:Nt(Xt(1,1/0),he(Mf)),[U.String]:Nt(Xt(1,1/0),he(Mf)),[U.Array]:Nt(Xt(1,1/0),he(lt)),[U.Color]:Nt(Xt(1,4),he(lt)),[U.Band]:Nt(Xt(1,3),he(lt)),[U.Palette]:Nt(Xt(2,2),jZ),[U.ToString]:Nt(Xt(1,1),he(Os|lt|bs|$e))};function AZ(s,t,e){const i=s.length-1,n=new Array(i);for(let r=0;rt){const a=t===1/0?`${s} or more`:`${s} to ${t}`;throw new Error(`expected ${a} arguments for ${r}, got ${o}`)}}}function hM(s,t,e){const i=s.length-1,n=new Array(i);for(let r=0;ri.featureId;case U.GeometryType:return i=>i.geometryType;case U.Concat:{const i=s.args.map(n=>Xn(n));return n=>"".concat(...i.map(r=>r(n).toString()))}case U.Resolution:return i=>i.resolution;case U.Any:case U.All:case U.Between:case U.In:case U.Not:return XZ(s);case U.Equal:case U.NotEqual:case U.LessThan:case U.LessThanOrEqualTo:case U.GreaterThan:case U.GreaterThanOrEqualTo:return WZ(s);case U.Multiply:case U.Divide:case U.Add:case U.Subtract:case U.Clamp:case U.Mod:case U.Pow:case U.Abs:case U.Floor:case U.Ceil:case U.Round:case U.Sin:case U.Cos:case U.Atan:case U.Sqrt:return VZ(s);case U.Case:return YZ(s);case U.Match:return qZ(s);case U.Interpolate:return ZZ(s);case U.ToString:return HZ(s);default:throw new Error(`Unsupported operator ${e}`)}}function UZ(s,t){const e=s.operator,i=s.args.length,n=new Array(i);for(let r=0;r{for(let o=0;o{for(let o=0;o{const n=s.args;let r=i.properties[e];for(let o=1,a=n.length;oi.variables[e];default:throw new Error(`Unsupported accessor operator ${s.operator}`)}}function WZ(s,t){const e=s.operator,i=Xn(s.args[0]),n=Xn(s.args[1]);switch(e){case U.Equal:return r=>i(r)===n(r);case U.NotEqual:return r=>i(r)!==n(r);case U.LessThan:return r=>i(r)i(r)<=n(r);case U.GreaterThan:return r=>i(r)>n(r);case U.GreaterThanOrEqualTo:return r=>i(r)>=n(r);default:throw new Error(`Unsupported comparison operator ${e}`)}}function XZ(s,t){const e=s.operator,i=s.args.length,n=new Array(i);for(let r=0;r{for(let o=0;o{for(let o=0;o{const o=n[0](r),a=n[1](r),l=n[2](r);return o>=a&&o<=l};case U.In:return r=>{const o=n[0](r);for(let a=1;a!n[0](r);default:throw new Error(`Unsupported logical operator ${e}`)}}function VZ(s,t){const e=s.operator,i=s.args.length,n=new Array(i);for(let r=0;r{let o=1;for(let a=0;an[0](r)/n[1](r);case U.Add:return r=>{let o=0;for(let a=0;an[0](r)-n[1](r);case U.Clamp:return r=>{const o=n[0](r),a=n[1](r);if(ol?l:o};case U.Mod:return r=>n[0](r)%n[1](r);case U.Pow:return r=>Math.pow(n[0](r),n[1](r));case U.Abs:return r=>Math.abs(n[0](r));case U.Floor:return r=>Math.floor(n[0](r));case U.Ceil:return r=>Math.ceil(n[0](r));case U.Round:return r=>Math.round(n[0](r));case U.Sin:return r=>Math.sin(n[0](r));case U.Cos:return r=>Math.cos(n[0](r));case U.Atan:return i===2?r=>Math.atan2(n[0](r),n[1](r)):r=>Math.atan(n[0](r));case U.Sqrt:return r=>Math.sqrt(n[0](r));default:throw new Error(`Unsupported numeric operator ${e}`)}}function YZ(s,t){const e=s.args.length,i=new Array(e);for(let n=0;n{for(let r=0;r{const r=i[0](n);for(let o=1;o{const r=i[0](n),o=i[1](n);let a,l;for(let h=2;h=o)return h===2?u:d?KZ(r,o,a,l,c,u):Su(r,o,a,l,c,u);a=c,l=u}return l}}function HZ(s,t){const e=s.operator,i=s.args.length,n=new Array(i);for(let r=0;r{const o=n[0](r);return s.args[0].type===$e?Sv(o):o.toString()};default:throw new Error(`Unsupported convert operator ${e}`)}}function Su(s,t,e,i,n,r){const o=n-e;if(o===0)return i;const a=t-e,l=s===1?a/o:(Math.pow(s,a)-1)/(Math.pow(s,o)-1);return i+l*(r-i)}function KZ(s,t,e,i,n,r){if(n-e===0)return i;const o=v2(i),a=v2(r);let l=a[2]-o[2];l>180?l-=360:l<-180&&(l+=360);const h=[Su(s,t,e,o[0],n,a[0]),Su(s,t,e,o[1],n,a[1]),o[2]+Su(s,t,e,0,n,l),Su(s,t,e,i[3],n,r[3])];return WI(YB(h))}function JZ(s){return!0}function QZ(s){const t=Uv(),e=tH(s,t),i=BP();return function(n,r){if(i.properties=n.getPropertiesInternal(),i.resolution=r,t.featureId){const o=n.getId();o!==void 0?i.featureId=o:i.featureId=null}return t.geometryType&&(i.geometryType=Bv(n.getGeometry())),e(i)}}function uM(s){const t=Uv(),e=s.length,i=new Array(e);for(let o=0;onull;i=Wv(s,t+"fill-color",e)}if(!i)return null;const n=new Wn;return function(r){const o=i(r);return o==="none"?null:(n.setColor(o),n)}}function Nd(s,t,e){const i=Ti(s,t+"stroke-width",e),n=Wv(s,t+"stroke-color",e);if(!i&&!n)return null;const r=kr(s,t+"stroke-line-cap",e),o=kr(s,t+"stroke-line-join",e),a=WP(s,t+"stroke-line-dash",e),l=Ti(s,t+"stroke-line-dash-offset",e),h=Ti(s,t+"stroke-miter-limit",e),c=new wn;return function(u){if(n){const d=n(u);if(d==="none")return null;c.setColor(d)}if(i&&c.setWidth(i(u)),r){const d=r(u);if(d!=="butt"&&d!=="round"&&d!=="square")throw new Error("Expected butt, round, or square line cap");c.setLineCap(d)}if(o){const d=o(u);if(d!=="bevel"&&d!=="round"&&d!=="miter")throw new Error("Expected bevel, round, or miter line join");c.setLineJoin(d)}return a&&c.setLineDash(a(u)),l&&c.setLineDashOffset(l(u)),h&&c.setMiterLimit(h(u)),c}}function eH(s,t){const e="text-",i=kr(s,e+"value",t);if(!i)return null;const n=Fd(s,e,t),r=Fd(s,e+"background-",t),o=Nd(s,e,t),a=Nd(s,e+"background-",t),l=kr(s,e+"font",t),h=Ti(s,e+"max-angle",t),c=Ti(s,e+"offset-x",t),u=Ti(s,e+"offset-y",t),d=Dd(s,e+"overflow",t),g=kr(s,e+"placement",t),f=Ti(s,e+"repeat",t),p=t0(s,e+"scale",t),m=Dd(s,e+"rotate-with-view",t),_=Ti(s,e+"rotation",t),y=kr(s,e+"align",t),v=kr(s,e+"justify",t),S=kr(s,e+"baseline",t),w=WP(s,e+"padding",t),C=e0(s,e+"declutter-mode"),M=new al({declutterMode:C});return function(T){if(M.setText(i(T)),n&&M.setFill(n(T)),r&&M.setBackgroundFill(r(T)),o&&M.setStroke(o(T)),a&&M.setBackgroundStroke(a(T)),l&&M.setFont(l(T)),h&&M.setMaxAngle(h(T)),c&&M.setOffsetX(c(T)),u&&M.setOffsetY(u(T)),d&&M.setOverflow(d(T)),g){const I=g(T);if(I!=="point"&&I!=="line")throw new Error("Expected point or line for text-placement");M.setPlacement(I)}if(f&&M.setRepeat(f(T)),p&&M.setScale(p(T)),m&&M.setRotateWithView(m(T)),_&&M.setRotation(_(T)),y){const I=y(T);if(I!=="left"&&I!=="center"&&I!=="right"&&I!=="end"&&I!=="start")throw new Error("Expected left, right, center, start, or end for text-align");M.setTextAlign(I)}if(v){const I=v(T);if(I!=="left"&&I!=="right"&&I!=="center")throw new Error("Expected left, right, or center for text-justify");M.setJustify(I)}if(S){const I=S(T);if(I!=="bottom"&&I!=="top"&&I!=="middle"&&I!=="alphabetic"&&I!=="hanging")throw new Error("Expected bottom, top, middle, alphabetic, or hanging for text-baseline");M.setTextBaseline(I)}return w&&M.setPadding(w(T)),M}}function sH(s,t){return"icon-src"in s?iH(s,t):"shape-points"in s?nH(s,t):"circle-radius"in s?rH(s,t):null}function iH(s,t){const e="icon-",i=e+"src",n=XP(s[i],i),r=$p(s,e+"anchor",t),o=t0(s,e+"scale",t),a=Ti(s,e+"opacity",t),l=$p(s,e+"displacement",t),h=Ti(s,e+"rotation",t),c=Dd(s,e+"rotate-with-view",t),u=gM(s,e+"anchor-origin"),d=fM(s,e+"anchor-x-units"),g=fM(s,e+"anchor-y-units"),f=cH(s,e+"color"),p=lH(s,e+"cross-origin"),m=hH(s,e+"offset"),_=gM(s,e+"offset-origin"),y=Gp(s,e+"width"),v=Gp(s,e+"height"),S=aH(s,e+"size"),w=e0(s,e+"declutter-mode"),C=new Rc({src:n,anchorOrigin:u,anchorXUnits:d,anchorYUnits:g,color:f,crossOrigin:p,offset:m,offsetOrigin:_,height:v,width:y,size:S,declutterMode:w});return function(M){return a&&C.setOpacity(a(M)),l&&C.setDisplacement(l(M)),h&&C.setRotation(h(M)),c&&C.setRotateWithView(c(M)),o&&C.setScale(o(M)),r&&C.setAnchor(r(M)),C}}function nH(s,t){const e="shape-",i=e+"points",n=e+"radius",r=ly(s[i],i),o=ly(s[n],n),a=Fd(s,e,t),l=Nd(s,e,t),h=t0(s,e+"scale",t),c=$p(s,e+"displacement",t),u=Ti(s,e+"rotation",t),d=Dd(s,e+"rotate-with-view",t),g=Gp(s,e+"radius2"),f=Gp(s,e+"angle"),p=e0(s,e+"declutter-mode"),m=new Vm({points:r,radius:o,radius2:g,angle:f,declutterMode:p});return function(_){return a&&m.setFill(a(_)),l&&m.setStroke(l(_)),c&&m.setDisplacement(c(_)),u&&m.setRotation(u(_)),d&&m.setRotateWithView(d(_)),h&&m.setScale(h(_)),m}}function rH(s,t){const e="circle-",i=Fd(s,e,t),n=Nd(s,e,t),r=Ti(s,e+"radius",t),o=t0(s,e+"scale",t),a=$p(s,e+"displacement",t),l=Ti(s,e+"rotation",t),h=Dd(s,e+"rotate-with-view",t),c=e0(s,e+"declutter-mode"),u=new Ym({radius:5,declutterMode:c});return function(d){return r&&u.setRadius(r(d)),i&&u.setFill(i(d)),n&&u.setStroke(n(d)),a&&u.setDisplacement(a(d)),l&&u.setRotation(l(d)),h&&u.setRotateWithView(h(d)),o&&u.setScale(o(d)),u}}function Ti(s,t,e){if(!(t in s))return;const i=_o(s[t],lt,e);return function(n){return ly(i(n),t)}}function kr(s,t,e){if(!(t in s))return null;const i=_o(s[t],bs,e);return function(n){return XP(i(n),t)}}function oH(s,t,e){const i=kr(s,t+"pattern-src",e),n=dM(s,t+"pattern-offset",e),r=dM(s,t+"pattern-size",e),o=Wv(s,t+"color",e);return function(a){return{src:i(a),offset:n&&n(a),size:r&&r(a),color:o&&o(a)}}}function Dd(s,t,e){if(!(t in s))return null;const i=_o(s[t],Os,e);return function(n){const r=i(n);if(typeof r!="boolean")throw new Error(`Expected a boolean for ${t}`);return r}}function Wv(s,t,e){if(!(t in s))return null;const i=_o(s[t],$e,e);return function(n){return VP(i(n),t)}}function WP(s,t,e){if(!(t in s))return null;const i=_o(s[t],ui,e);return function(n){return Rg(i(n),t)}}function $p(s,t,e){if(!(t in s))return null;const i=_o(s[t],ui,e);return function(n){const r=Rg(i(n),t);if(r.length!==2)throw new Error(`Expected two numbers for ${t}`);return r}}function dM(s,t,e){if(!(t in s))return null;const i=_o(s[t],ui,e);return function(n){return YP(i(n),t)}}function t0(s,t,e){if(!(t in s))return null;const i=_o(s[t],ui|lt,e);return function(n){return uH(i(n),t)}}function Gp(s,t){const e=s[t];if(e!==void 0){if(typeof e!="number")throw new Error(`Expected a number for ${t}`);return e}}function aH(s,t){const e=s[t];if(e!==void 0){if(typeof e=="number")return Re(e);if(!Array.isArray(e))throw new Error(`Expected a number or size array for ${t}`);if(e.length!==2||typeof e[0]!="number"||typeof e[1]!="number")throw new Error(`Expected a number or size array for ${t}`);return e}}function lH(s,t){const e=s[t];if(e!==void 0){if(typeof e!="string")throw new Error(`Expected a string for ${t}`);return e}}function gM(s,t){const e=s[t];if(e!==void 0){if(e!=="bottom-left"&&e!=="bottom-right"&&e!=="top-left"&&e!=="top-right")throw new Error(`Expected bottom-left, bottom-right, top-left, or top-right for ${t}`);return e}}function fM(s,t){const e=s[t];if(e!==void 0){if(e!=="pixels"&&e!=="fraction")throw new Error(`Expected pixels or fraction for ${t}`);return e}}function hH(s,t){const e=s[t];if(e!==void 0)return Rg(e,t)}function e0(s,t){const e=s[t];if(e!==void 0){if(typeof e!="string")throw new Error(`Expected a string for ${t}`);if(e!=="declutter"&&e!=="obstacle"&&e!=="none")throw new Error(`Expected declutter, obstacle, or none for ${t}`);return e}}function cH(s,t){const e=s[t];if(e!==void 0)return VP(e,t)}function Rg(s,t){if(!Array.isArray(s))throw new Error(`Expected an array for ${t}`);const e=s.length;for(let i=0;i4)throw new Error(`Expected a color with 3 or 4 values for ${t}`);return e}function YP(s,t){const e=Rg(s,t);if(e.length!==2)throw new Error(`Expected an array of two numbers for ${t}`);return e}function uH(s,t){return typeof s=="number"?s:YP(s,t)}const pM={RENDER_ORDER:"renderOrder"};class Ig extends Tg{constructor(t){t=t||{};const e=Object.assign({},t);delete e.style,delete e.renderBuffer,delete e.updateWhileAnimating,delete e.updateWhileInteracting,super(e),this.declutter_=t.declutter?String(t.declutter):void 0,this.renderBuffer_=t.renderBuffer!==void 0?t.renderBuffer:100,this.style_=null,this.styleFunction_=void 0,this.setStyle(t.style),this.updateWhileAnimating_=t.updateWhileAnimating!==void 0?t.updateWhileAnimating:!1,this.updateWhileInteracting_=t.updateWhileInteracting!==void 0?t.updateWhileInteracting:!1}getDeclutter(){return this.declutter_}getFeatures(t){return super.getFeatures(t)}getRenderBuffer(){return this.renderBuffer_}getRenderOrder(){return this.get(pM.RENDER_ORDER)}getStyle(){return this.style_}getStyleFunction(){return this.styleFunction_}getUpdateWhileAnimating(){return this.updateWhileAnimating_}getUpdateWhileInteracting(){return this.updateWhileInteracting_}renderDeclutter(t,e){const i=this.getDeclutter();i in t.declutter||(t.declutter[i]=new jv(9)),this.getRenderer().renderDeclutter(t,e)}setRenderOrder(t){this.set(pM.RENDER_ORDER,t)}setStyle(t){this.style_=t===void 0?KI:t;const e=dH(t);this.styleFunction_=t===null?void 0:lW(e),this.changed()}}function dH(s){if(s===void 0)return KI;if(!s)return null;if(typeof s=="function"||s instanceof Ps)return s;if(!Array.isArray(s))return uM([s]);if(s.length===0)return[];const t=s.length,e=s[0];if(e instanceof Ps){const i=new Array(t);for(let n=0;nl&&(this.instructions.push([Et.CUSTOM,l,c,t,i,jr,r]),this.hitDetectionInstructions.push([Et.CUSTOM,l,c,t,n||i,jr,r]));break;case"Point":h=t.getFlatCoordinates(),this.coordinates.push(h[0],h[1]),c=this.coordinates.length,this.instructions.push([Et.CUSTOM,l,c,t,i,void 0,r]),this.hitDetectionInstructions.push([Et.CUSTOM,l,c,t,n||i,void 0,r]);break}this.endGeometry(e)}beginGeometry(t,e,i){this.beginGeometryInstruction1_=[Et.BEGIN_GEOMETRY,e,0,t,i],this.instructions.push(this.beginGeometryInstruction1_),this.beginGeometryInstruction2_=[Et.BEGIN_GEOMETRY,e,0,t,i],this.hitDetectionInstructions.push(this.beginGeometryInstruction2_)}finish(){return{instructions:this.instructions,hitDetectionInstructions:this.hitDetectionInstructions,coordinates:this.coordinates}}reverseHitDetectionInstructions(){const t=this.hitDetectionInstructions;t.reverse();let e;const i=t.length;let n,r,o=-1;for(e=0;ethis.maxLineWidth&&(this.maxLineWidth=i.lineWidth,this.bufferedMaxExtent_=null)}else i.strokeStyle=void 0,i.lineCap=void 0,i.lineDash=null,i.lineDashOffset=void 0,i.lineJoin=void 0,i.lineWidth=void 0,i.miterLimit=void 0}createFill(t){const e=t.fillStyle,i=[Et.SET_FILL_STYLE,e];return typeof e!="string"&&i.push(t.fillPatternScale),i}applyStroke(t){this.instructions.push(this.createStroke(t))}createStroke(t){return[Et.SET_STROKE_STYLE,t.strokeStyle,t.lineWidth*this.pixelRatio,t.lineCap,t.lineJoin,t.miterLimit,this.applyPixelRatio(t.lineDash),t.lineDashOffset*this.pixelRatio]}updateFillStyle(t,e){const i=t.fillStyle;(typeof i!="string"||t.currentFillStyle!=i)&&(i!==void 0&&this.instructions.push(e.call(this,t)),t.currentFillStyle=i)}updateStrokeStyle(t,e){const i=t.strokeStyle,n=t.lineCap,r=t.lineDash,o=t.lineDashOffset,a=t.lineJoin,l=t.lineWidth,h=t.miterLimit;(t.currentStrokeStyle!=i||t.currentLineCap!=n||r!=t.currentLineDash&&!vl(t.currentLineDash,r)||t.currentLineDashOffset!=o||t.currentLineJoin!=a||t.currentLineWidth!=l||t.currentMiterLimit!=h)&&(i!==void 0&&e.call(this,t),t.currentStrokeStyle=i,t.currentLineCap=n,t.currentLineDash=r,t.currentLineDashOffset=o,t.currentLineJoin=a,t.currentLineWidth=l,t.currentMiterLimit=h)}endGeometry(t){this.beginGeometryInstruction1_[2]=this.instructions.length,this.beginGeometryInstruction1_=null,this.beginGeometryInstruction2_[2]=this.hitDetectionInstructions.length,this.beginGeometryInstruction2_=null;const e=[Et.END_GEOMETRY,t];this.instructions.push(e),this.hitDetectionInstructions.push(e)}getBufferedMaxExtent(){if(!this.bufferedMaxExtent_&&(this.bufferedMaxExtent_=o9(this.maxExtent),this.maxLineWidth>0)){const t=this.resolution*(this.maxLineWidth+1)/2;_n(this.bufferedMaxExtent_,t,this.bufferedMaxExtent_)}return this.bufferedMaxExtent_}}class gH extends Pg{constructor(t,e,i,n){super(t,e,i,n),this.hitDetectionImage_=null,this.image_=null,this.imagePixelRatio_=void 0,this.anchorX_=void 0,this.anchorY_=void 0,this.height_=void 0,this.opacity_=void 0,this.originX_=void 0,this.originY_=void 0,this.rotateWithView_=void 0,this.rotation_=void 0,this.scale_=void 0,this.width_=void 0,this.declutterMode_=void 0,this.declutterImageWithText_=void 0}drawPoint(t,e,i){if(!this.image_||this.maxExtent&&!Yi(this.maxExtent,t.getFlatCoordinates()))return;this.beginGeometry(t,e,i);const n=t.getFlatCoordinates(),r=t.getStride(),o=this.coordinates.length,a=this.appendFlatPointCoordinates(n,r);this.instructions.push([Et.DRAW_IMAGE,o,a,this.image_,this.anchorX_*this.imagePixelRatio_,this.anchorY_*this.imagePixelRatio_,Math.ceil(this.height_*this.imagePixelRatio_),this.opacity_,this.originX_*this.imagePixelRatio_,this.originY_*this.imagePixelRatio_,this.rotateWithView_,this.rotation_,[this.scale_[0]*this.pixelRatio/this.imagePixelRatio_,this.scale_[1]*this.pixelRatio/this.imagePixelRatio_],Math.ceil(this.width_*this.imagePixelRatio_),this.declutterMode_,this.declutterImageWithText_]),this.hitDetectionInstructions.push([Et.DRAW_IMAGE,o,a,this.hitDetectionImage_,this.anchorX_,this.anchorY_,this.height_,1,this.originX_,this.originY_,this.rotateWithView_,this.rotation_,this.scale_,this.width_,this.declutterMode_,this.declutterImageWithText_]),this.endGeometry(e)}drawMultiPoint(t,e,i){if(!this.image_)return;this.beginGeometry(t,e,i);const n=t.getFlatCoordinates(),r=[];for(let l=0,h=n.length;l=s){const f=(s-a+g)/g,p=Ui(h,u,f),m=Ui(c,d,f);l.push(p,m),r.push(l),l=[p,m],a==s&&(o+=n),a=0}else if(a0&&r.push(l),r}function mH(s,t,e,i,n){let r=e,o=e,a=0,l=0,h=e,c,u,d,g,f,p,m,_,y,v;for(u=e;us&&(l>a&&(a=l,r=h,o=u),l=0,h=u-n)),d=g,m=y,_=v),f=S,p=w}return l+=g,l>a?[h,u]:[r,o]}const jp={left:0,center:.5,right:1,top:0,middle:.5,hanging:.2,alphabetic:.8,ideographic:.8,bottom:1};class _H extends Pg{constructor(t,e,i,n){super(t,e,i,n),this.labels_=null,this.text_="",this.textOffsetX_=0,this.textOffsetY_=0,this.textRotateWithView_=void 0,this.textRotation_=0,this.textFillState_=null,this.fillStates={},this.fillStates[Si]={fillStyle:Si},this.textStrokeState_=null,this.strokeStates={},this.textState_={},this.textStates={},this.textKey_="",this.fillKey_="",this.strokeKey_="",this.declutterMode_=void 0,this.declutterImageWithText_=void 0}finish(){const t=super.finish();return t.textStates=this.textStates,t.fillStates=this.fillStates,t.strokeStates=this.strokeStates,t}drawText(t,e,i){const n=this.textFillState_,r=this.textStrokeState_,o=this.textState_;if(this.text_===""||!o||!n&&!r)return;const a=this.coordinates;let l=a.length;const h=t.getType();let c=null,u=t.getStride();if(o.placement==="line"&&(h=="LineString"||h=="MultiLineString"||h=="Polygon"||h=="MultiPolygon")){if(!Ce(this.maxExtent,t.getExtent()))return;let d;if(c=t.getFlatCoordinates(),h=="LineString")d=[c.length];else if(h=="MultiLineString")d=t.getEnds();else if(h=="Polygon")d=t.getEnds().slice(0,1);else if(h=="MultiPolygon"){const m=t.getEndss();d=[];for(let _=0,y=m.length;_{const w=a[(y+S)*2]===c[S*u]&&a[(y+S)*2+1]===c[S*u+1];return w||--y,w})}this.saveTextStates_(),(o.backgroundFill||o.backgroundStroke)&&(this.setFillStrokeStyle(o.backgroundFill,o.backgroundStroke),o.backgroundFill&&this.updateFillStyle(this.state,this.createFill),o.backgroundStroke&&(this.updateStrokeStyle(this.state,this.applyStroke),this.hitDetectionInstructions.push(this.createStroke(this.state)))),this.beginGeometry(t,e,i);let f=o.padding;if(f!=za&&(o.scale[0]<0||o.scale[1]<0)){let y=o.padding[0],v=o.padding[1],S=o.padding[2],w=o.padding[3];o.scale[0]<0&&(v=-v,w=-w),o.scale[1]<0&&(y=-y,S=-S),f=[y,v,S,w]}const p=this.pixelRatio;this.instructions.push([Et.DRAW_IMAGE,l,g,null,NaN,NaN,NaN,1,0,0,this.textRotateWithView_,this.textRotation_,[1,1],NaN,this.declutterMode_,this.declutterImageWithText_,f==za?za:f.map(function(y){return y*p}),!!o.backgroundFill,!!o.backgroundStroke,this.text_,this.textKey_,this.strokeKey_,this.fillKey_,this.textOffsetX_,this.textOffsetY_,d]);const m=1/p,_=this.state.fillStyle;o.backgroundFill&&(this.state.fillStyle=Si,this.hitDetectionInstructions.push(this.createFill(this.state))),this.hitDetectionInstructions.push([Et.DRAW_IMAGE,l,g,null,NaN,NaN,NaN,1,0,0,this.textRotateWithView_,this.textRotation_,[m,m],NaN,this.declutterMode_,this.declutterImageWithText_,f,!!o.backgroundFill,!!o.backgroundStroke,this.text_,this.textKey_,this.strokeKey_,this.fillKey_?Si:this.fillKey_,this.textOffsetX_,this.textOffsetY_,d]),o.backgroundFill&&(this.state.fillStyle=_,this.hitDetectionInstructions.push(this.createFill(this.state))),this.endGeometry(e)}}saveTextStates_(){const t=this.textStrokeState_,e=this.textState_,i=this.textFillState_,n=this.strokeKey_;t&&(n in this.strokeStates||(this.strokeStates[n]={strokeStyle:t.strokeStyle,lineCap:t.lineCap,lineDashOffset:t.lineDashOffset,lineWidth:t.lineWidth,lineJoin:t.lineJoin,miterLimit:t.miterLimit,lineDash:t.lineDash}));const r=this.textKey_;r in this.textStates||(this.textStates[r]={font:e.font,textAlign:e.textAlign||Ld,justify:e.justify,textBaseline:e.textBaseline||Ap,scale:e.scale});const o=this.fillKey_;i&&(o in this.fillStates||(this.fillStates[o]={fillStyle:i.fillStyle}))}drawChars_(t,e){const i=this.textStrokeState_,n=this.textState_,r=this.strokeKey_,o=this.textKey_,a=this.fillKey_;this.saveTextStates_();const l=this.pixelRatio,h=jp[n.textBaseline],c=this.textOffsetY_*l,u=this.text_,d=i?i.lineWidth*Math.abs(n.scale[0])/2:0;this.instructions.push([Et.DRAW_CHARS,t,e,h,n.overflow,a,n.maxAngle,l,c,r,d*l,u,o,1,this.declutterMode_]),this.hitDetectionInstructions.push([Et.DRAW_CHARS,t,e,h,n.overflow,a&&Si,n.maxAngle,l,c,r,d*l,u,o,1/l,this.declutterMode_])}setTextStyle(t,e){let i,n,r;if(!t)this.text_="";else{const o=t.getFill();o?(n=this.textFillState_,n||(n={},this.textFillState_=n),n.fillStyle=hr(o.getColor()||Si)):(n=null,this.textFillState_=n);const a=t.getStroke();if(!a)r=null,this.textStrokeState_=r;else{r=this.textStrokeState_,r||(r={},this.textStrokeState_=r);const f=a.getLineDash(),p=a.getLineDashOffset(),m=a.getWidth(),_=a.getMiterLimit();r.lineCap=a.getLineCap()||lc,r.lineDash=f?f.slice():Hr,r.lineDashOffset=p===void 0?Kr:p,r.lineJoin=a.getLineJoin()||hc,r.lineWidth=m===void 0?Od:m,r.miterLimit=_===void 0?Pd:_,r.strokeStyle=hr(a.getColor()||Ad)}i=this.textState_;const l=t.getFont()||ZI;iW(l);const h=t.getScaleArray();i.overflow=t.getOverflow(),i.font=l,i.maxAngle=t.getMaxAngle(),i.placement=t.getPlacement(),i.textAlign=t.getTextAlign(),i.repeat=t.getRepeat(),i.justify=t.getJustify(),i.textBaseline=t.getTextBaseline()||Ap,i.backgroundFill=t.getBackgroundFill(),i.backgroundStroke=t.getBackgroundStroke(),i.padding=t.getPadding()||za,i.scale=h===void 0?[1,1]:h;const c=t.getOffsetX(),u=t.getOffsetY(),d=t.getRotateWithView(),g=t.getRotation();this.text_=t.getText()||"",this.textOffsetX_=c===void 0?0:c,this.textOffsetY_=u===void 0?0:u,this.textRotateWithView_=d===void 0?!1:d,this.textRotation_=g===void 0?0:g,this.strokeKey_=r?(typeof r.strokeStyle=="string"?r.strokeStyle:mt(r.strokeStyle))+r.lineCap+r.lineDashOffset+"|"+r.lineWidth+r.lineJoin+r.miterLimit+"["+r.lineDash.join()+"]":"",this.textKey_=i.font+i.scale+(i.textAlign||"?")+(i.repeat||"?")+(i.justify||"?")+(i.textBaseline||"?"),this.fillKey_=n&&n.fillStyle?typeof n.fillStyle=="string"?n.fillStyle:"|"+mt(n.fillStyle):""}this.declutterMode_=t.getDeclutterMode(),this.declutterImageWithText_=e}}const yH={Circle:_M,Default:Pg,Image:gH,LineString:fH,Polygon:_M,Text:_H};class ZP{constructor(t,e,i,n){this.tolerance_=t,this.maxExtent_=e,this.pixelRatio_=n,this.resolution_=i,this.buildersByZIndex_={}}finish(){const t={};for(const e in this.buildersByZIndex_){t[e]=t[e]||{};const i=this.buildersByZIndex_[e];for(const n in i){const r=i[n].finish();t[e][n]=r}}return t}getBuilder(t,e){const i=t!==void 0?t.toString():"0";let n=this.buildersByZIndex_[i];n===void 0&&(n={},this.buildersByZIndex_[i]=n);let r=n[e];if(r===void 0){const o=yH[e];r=new o(this.tolerance_,this.maxExtent_,this.resolution_,this.pixelRatio_),n[e]=r}return r}}const xH=5;class HP extends pg{constructor(t){super(),this.ready=!0,this.boundHandleImageChange_=this.handleImageChange_.bind(this),this.layer_=t,this.staleKeys_=new Array,this.maxStaleKeys=xH}getStaleKeys(){return this.staleKeys_}prependStaleKey(t){this.staleKeys_.unshift(t),this.staleKeys_.length>this.maxStaleKeys&&(this.staleKeys_.length=this.maxStaleKeys)}getFeatures(t){return vt()}getData(t){return null}prepareFrame(t){return vt()}renderFrame(t,e){return vt()}forEachFeatureAtCoordinate(t,e,i,n,r){}getLayer(){return this.layer_}handleFontsChanged(){}handleImageChange_(t){const e=t.target;(e.getState()===it.LOADED||e.getState()===it.ERROR)&&this.renderIfReadyAndVisible()}loadImage(t){let e=t.getState();return e!=it.LOADED&&e!=it.ERROR&&t.addEventListener(Zt.CHANGE,this.boundHandleImageChange_),e==it.IDLE&&(t.load(),e=t.getState()),e==it.LOADED}renderIfReadyAndVisible(){const t=this.getLayer();t&&t.getVisible()&&t.getSourceState()==="ready"&&t.changed()}renderDeferred(t){}disposeInternal(){delete this.layer_,super.disposeInternal()}}class $f extends Sr{constructor(t,e,i,n){super(t),this.inversePixelTransform=e,this.frameState=i,this.context=n}}class Xv{constructor(){jx(this,"pushMethodArgs_",(...t)=>(this.instructions_[this.zIndex+this.offset_].push(t),this)),this.instructions_=[],this.zIndex=0,this.offset_=0,this.context_=new Proxy(Pp(),{get:(t,e)=>{if(typeof Pp()[e]=="function")return this.instructions_[this.zIndex+this.offset_]||(this.instructions_[this.zIndex+this.offset_]=[]),this.instructions_[this.zIndex+this.offset_].push(e),this.pushMethodArgs_},set:(t,e,i)=>(this.instructions_[this.zIndex+this.offset_]||(this.instructions_[this.zIndex+this.offset_]=[]),this.instructions_[this.zIndex+this.offset_].push(e,i),!0)})}pushFunction(t){this.instructions_[this.zIndex+this.offset_].push(t)}getContext(){return this.context_}draw(t){this.instructions_.forEach(e=>{for(let i=0,n=e.length;iR[2]}else P=S>I;const D=Math.PI,x=[],E=C+i===t;t=C,m=0,_=M,d=s[t],g=s[t+1];let b;if(E){y(),b=Math.atan2(g-p,d-f),P&&(b+=b>0?-D:D);const R=(I+S)/2,A=(O+w)/2;return x[0]=[R,A,(T-r)/2,b,n],x}n=n.replace(/\n/g," ");for(let R=0,A=n.length;R0?-D:D),b!==void 0){let F=$-b;if(F+=F>D?-2*D:F<-D?2*D:0,Math.abs(F)>o)return null}b=$;const G=R;let k=0;for(;R0&&s.push(` `,""),s.push(t,""),s}class SH{constructor(t,e,i,n,r){this.overlaps=i,this.pixelRatio=e,this.resolution=t,this.alignAndScaleFill_,this.instructions=n.instructions,this.coordinates=n.coordinates,this.coordinateCache_={},this.renderedTransform_=ss(),this.hitDetectionInstructions=n.hitDetectionInstructions,this.pixelCoordinates_=null,this.viewRotation_=0,this.fillStates=n.fillStates||{},this.strokeStates=n.strokeStates||{},this.textStates=n.textStates||{},this.widths_={},this.labels_={},this.zIndexContext_=r?new Xv:null}getZIndexContext(){return this.zIndexContext_}createLabel(t,e,i,n){const r=t+e+i+n;if(this.labels_[r])return this.labels_[r];const o=n?this.strokeStates[n]:null,a=i?this.fillStates[i]:null,l=this.textStates[e],h=this.pixelRatio,c=[l.scale[0]*h,l.scale[1]*h],u=l.justify?jp[l.justify]:L_(Array.isArray(t)?t[0]:t,l.textAlign||Ld),d=n&&o.lineWidth?o.lineWidth:0,g=Array.isArray(t)?t:String(t).split(` -`).reduce(EH,[]),{width:f,height:p,widths:m,heights:_,lineWidths:y}=rW(l,g),v=f+d,S=[],w=(v+2)*c[0],T=(p+d)*c[1],M={width:w<0?Math.floor(w):Math.ceil(w),height:T<0?Math.floor(T):Math.ceil(T),contextInstructions:S};(c[0]!=1||c[1]!=1)&&S.push("scale",c),n&&(S.push("strokeStyle",o.strokeStyle),S.push("lineWidth",d),S.push("lineCap",o.lineCap),S.push("lineJoin",o.lineJoin),S.push("miterLimit",o.miterLimit),S.push("setLineDash",[o.lineDash]),S.push("lineDashOffset",o.lineDashOffset)),i&&S.push("fillStyle",a.fillStyle),S.push("textBaseline","middle"),S.push("textAlign","center");const C=.5-u;let I=u*v+C*d;const O=[],P=[];let D=0,x=0,E=0,b=0,R;for(let A=0,$=g.length;A<$;A+=2){const G=g[A];if(G===` -`){x+=D,D=0,I=u*v+C*d,++b;continue}const k=g[A+1]||l.font;k!==R&&(n&&O.push("font",k),i&&P.push("font",k),R=k),D=Math.max(D,_[E]);const z=[G,I+C*m[E]+u*(m[E]-y[b]),.5*(d+D)+x];I+=m[E],n&&O.push("strokeText",z),i&&P.push("fillText",z),++E}return Array.prototype.push.apply(S,O),Array.prototype.push.apply(S,P),this.labels_[r]=M,M}replayTextBackground_(t,e,i,n,r,o,a){t.beginPath(),t.moveTo.apply(t,e),t.lineTo.apply(t,i),t.lineTo.apply(t,n),t.lineTo.apply(t,r),t.lineTo.apply(t,e),o&&(this.alignAndScaleFill_=o[2],this.fill_(t)),a&&(this.setStrokeStyle_(t,a),t.stroke())}calculateImageOrLabelDimensions_(t,e,i,n,r,o,a,l,h,c,u,d,g,f,p,m){a*=d[0],l*=d[1];let _=i-a,y=n-l;const v=r+h>t?t-h:r,S=o+c>e?e-c:o,w=f[3]+v*d[0]+f[1],T=f[0]+S*d[1]+f[2],M=_-f[3],C=y-f[0];(p||u!==0)&&(Ro[0]=M,Io[0]=M,Ro[1]=C,Ir[1]=C,Ir[0]=M+w,Pr[0]=Ir[0],Pr[1]=C+T,Io[1]=Pr[1]);let I;return u!==0?(I=xn(ss(),i,n,1,1,u,-i,-n),Ye(I,Ro),Ye(I,Ir),Ye(I,Pr),Ye(I,Io),Un(Math.min(Ro[0],Ir[0],Pr[0],Io[0]),Math.min(Ro[1],Ir[1],Pr[1],Io[1]),Math.max(Ro[0],Ir[0],Pr[0],Io[0]),Math.max(Ro[1],Ir[1],Pr[1],Io[1]),Dl)):Un(Math.min(M,M+w),Math.min(C,C+T),Math.max(M,M+w),Math.max(C,C+T),Dl),g&&(_=Math.round(_),y=Math.round(y)),{drawImageX:_,drawImageY:y,drawImageW:v,drawImageH:S,originX:h,originY:c,declutterBox:{minX:Dl[0],minY:Dl[1],maxX:Dl[2],maxY:Dl[3],value:m},canvasTransform:I,scale:d}}replayImageOrLabel_(t,e,i,n,r,o,a){const l=!!(o||a),h=n.declutterBox,c=a?a[2]*n.scale[0]/2:0;return h.minX-c<=e[0]&&h.maxX+c>=0&&h.minY-c<=e[1]&&h.maxY+c>=0&&(l&&this.replayTextBackground_(t,Ro,Ir,Pr,Io,o,a),oW(t,n.canvasTransform,r,i,n.originX,n.originY,n.drawImageW,n.drawImageH,n.drawImageX,n.drawImageY,n.scale)),!0}fill_(t){const e=this.alignAndScaleFill_;if(e){const i=Ye(this.renderedTransform_,[0,0]),n=512*this.pixelRatio;t.save(),t.translate(i[0]%n,i[1]%n),e!==1&&t.scale(e,e),t.rotate(this.viewRotation_)}t.fill(),e&&t.restore()}setStrokeStyle_(t,e){t.strokeStyle=e[1],t.lineWidth=e[2],t.lineCap=e[3],t.lineJoin=e[4],t.miterLimit=e[5],t.lineDashOffset=e[7],t.setLineDash(e[6])}drawLabelWithPointPlacement_(t,e,i,n){const r=this.textStates[e],o=this.createLabel(t,e,n,i),a=this.strokeStates[i],l=this.pixelRatio,h=L_(Array.isArray(t)?t[0]:t,r.textAlign||Ld),c=jp[r.textBaseline||Ap],u=a&&a.lineWidth?a.lineWidth:0,d=o.width/l-2*r.scale[0],g=h*d+2*(.5-h)*u,f=c*o.height/l+2*(.5-c)*u;return{label:o,anchorX:g,anchorY:f}}execute_(t,e,i,n,r,o,a,l){const h=this.zIndexContext_;let c;this.pixelCoordinates_&&vl(i,this.renderedTransform_)?c=this.pixelCoordinates_:(this.pixelCoordinates_||(this.pixelCoordinates_=[]),c=Jo(this.coordinates,0,this.coordinates.length,2,i,this.pixelCoordinates_),e9(this.renderedTransform_,i));let u=0;const d=n.length;let g=0,f,p,m,_,y,v,S,w,T,M,C,I,O,P=0,D=0,x=null,E=null;const b=this.coordinateCache_,R=this.viewRotation_,A=Math.round(Math.atan2(-i[1],i[0])*1e12)/1e12,$={context:t,pixelRatio:this.pixelRatio,resolution:this.resolution,rotation:R},G=this.instructions!=n||this.overlaps?0:200;let k,z,V,et;for(;uG&&(this.fill_(t),P=0),D>G&&(t.stroke(),D=0),!P&&!D&&(t.beginPath(),y=NaN,v=NaN),++u;break;case Et.CIRCLE:g=F[1];const ot=c[g],ht=c[g+1],pt=c[g+2],Gt=c[g+3],Kt=pt-ot,bt=Gt-ht,oe=Math.sqrt(Kt*Kt+bt*bt);t.moveTo(ot+oe,ht),t.arc(ot,ht,oe,0,2*Math.PI,!0),++u;break;case Et.CLOSE_PATH:t.closePath(),++u;break;case Et.CUSTOM:g=F[1],f=F[2];const Pe=F[3],hs=F[4],rs=F[5];$.geometry=Pe,$.feature=k,u in b||(b[u]=[]);const Ge=b[u];rs?rs(c,g,f,2,Ge):(Ge[0]=c[g],Ge[1]=c[g+1],Ge.length=2),h&&(h.zIndex=F[6]),hs(Ge,$),++u;break;case Et.DRAW_IMAGE:g=F[1],f=F[2],T=F[3],p=F[4],m=F[5];let ve=F[6];const Ke=F[7],Ni=F[8],Di=F[9],Mn=F[10];let Ks=F[11];const ki=F[12];let $i=F[13];_=F[14]||"declutter";const Jt=F[15];if(!T&&F.length>=20){M=F[19],C=F[20],I=F[21],O=F[22];const Ae=this.drawLabelWithPointPlacement_(M,C,I,O);T=Ae.label,F[3]=T;const Js=F[23];p=(Ae.anchorX-Js)*this.pixelRatio,F[4]=p;const Le=F[24];m=(Ae.anchorY-Le)*this.pixelRatio,F[5]=m,ve=T.height,F[6]=ve,$i=T.width,F[13]=$i}let xa;F.length>25&&(xa=F[25]);let va,br,Tr;F.length>17?(va=F[16],br=F[17],Tr=F[18]):(va=za,br=!1,Tr=!1),Mn&&A?Ks+=R:!Mn&&!A&&(Ks-=R);let S0=0;for(;g!zp.includes(s));class KP{constructor(t,e,i,n,r,o,a){this.maxExtent_=t,this.overlaps_=n,this.pixelRatio_=i,this.resolution_=e,this.renderBuffer_=o,this.executorsByZIndex_={},this.hitDetectionContext_=null,this.hitDetectionTransform_=ss(),this.renderedContext_=null,this.deferredZIndexContexts_={},this.createExecutors_(r,a)}clip(t,e){const i=this.getClipCoords(e);t.beginPath(),t.moveTo(i[0],i[1]),t.lineTo(i[2],i[3]),t.lineTo(i[4],i[5]),t.lineTo(i[6],i[7]),t.clip()}createExecutors_(t,e){for(const i in t){let n=this.executorsByZIndex_[i];n===void 0&&(n={},this.executorsByZIndex_[i]=n);const r=t[i];for(const o in r){const a=r[o];n[o]=new SH(this.resolution_,this.pixelRatio_,this.overlaps_,a,e)}}}hasExecutors(t){for(const e in this.executorsByZIndex_){const i=this.executorsByZIndex_[e];for(let n=0,r=t.length;n0){if(!o||M==="none"||g!=="Image"&&g!=="Text"||o.includes(w)){const P=(d[I]-3)/4,D=n-P%a,x=n-(P/a|0),E=r(w,T,D*D+x*x);if(E)return E}c.clearRect(0,0,a,a);break}}const p=Object.keys(this.executorsByZIndex_).map(Number);p.sort(fr);let m,_,y,v,S;for(m=p.length-1;m>=0;--m){const w=p[m].toString();for(y=this.executorsByZIndex_[w],_=mh.length-1;_>=0;--_)if(g=mh[_],v=y[g],v!==void 0&&(S=v.executeHitDetection(c,l,i,f,u),S))return S}}getClipCoords(t){const e=this.maxExtent_;if(!e)return null;const i=e[0],n=e[1],r=e[2],o=e[3],a=[i,n,i,o,r,o,r,n];return Jo(a,0,8,2,t,a),a}isEmpty(){return eo(this.executorsByZIndex_)}execute(t,e,i,n,r,o,a){const l=Object.keys(this.executorsByZIndex_).map(Number);l.sort(fr),o=o||mh;const h=mh.length;let c,u,d,g,f;for(a&&l.reverse(),c=0,u=l.length;c_.execute(w,e,i,n,r,a)),S&&v.restore(),y){y.offset();const w=l[c]*h+d;this.deferredZIndexContexts_[w]||(this.deferredZIndexContexts_[w]=[]),this.deferredZIndexContexts_[w].push(y)}}}}this.renderedContext_=t}getDeferredZIndexContexts(){return this.deferredZIndexContexts_}getRenderedContext(){return this.renderedContext_}renderDeferred(){const t=this.deferredZIndexContexts_,e=Object.keys(t).map(Number).sort(fr);for(let i=0,n=e.length;i{r.draw(this.renderedContext_),r.clear()}),t[e[i]].length=0}}const O_={};function bH(s){if(O_[s]!==void 0)return O_[s];const t=s*2+1,e=s*s,i=new Array(e+1);for(let r=0;r<=s;++r)for(let o=0;o<=s;++o){const a=r*r+o*o;if(a>e)break;let l=i[a];l||(l=[],i[a]=l),l.push(((s+r)*t+(s+o))*4+3),r>0&&l.push(((s-r)*t+(s+o))*4+3),o>0&&(l.push(((s+r)*t+(s-o))*4+3),r>0&&l.push(((s-r)*t+(s-o))*4+3))}const n=[];for(let r=0,o=i.length;ru*this.pixelRatio_),lineDashOffset:(o||Kr)*this.pixelRatio_,lineJoin:a!==void 0?a:hc,lineWidth:(l!==void 0?l:Od)*this.pixelRatio_,miterLimit:h!==void 0?h:Pd,strokeStyle:hr(i||Ad)}}}setImageStyle(t){let e;if(!t||!(e=t.getSize())){this.image_=null;return}const i=t.getPixelRatio(this.pixelRatio_),n=t.getAnchor(),r=t.getOrigin();this.image_=t.getImage(this.pixelRatio_),this.imageAnchorX_=n[0]*i,this.imageAnchorY_=n[1]*i,this.imageHeight_=e[1]*i,this.imageOpacity_=t.getOpacity(),this.imageOriginX_=r[0],this.imageOriginY_=r[1],this.imageRotateWithView_=t.getRotateWithView(),this.imageRotation_=t.getRotation();const o=t.getScaleArray();this.imageScale_=[o[0]*this.pixelRatio_/i,o[1]*this.pixelRatio_/i],this.imageWidth_=e[0]*i}setTextStyle(t){if(!t)this.text_="";else{const e=t.getFill();if(!e)this.textFillState_=null;else{const g=e.getColor();this.textFillState_={fillStyle:hr(g||Si)}}const i=t.getStroke();if(!i)this.textStrokeState_=null;else{const g=i.getColor(),f=i.getLineCap(),p=i.getLineDash(),m=i.getLineDashOffset(),_=i.getLineJoin(),y=i.getWidth(),v=i.getMiterLimit();this.textStrokeState_={lineCap:f!==void 0?f:lc,lineDash:p||Hr,lineDashOffset:m||Kr,lineJoin:_!==void 0?_:hc,lineWidth:y!==void 0?y:Od,miterLimit:v!==void 0?v:Pd,strokeStyle:hr(g||Ad)}}const n=t.getFont(),r=t.getOffsetX(),o=t.getOffsetY(),a=t.getRotateWithView(),l=t.getRotation(),h=t.getScaleArray(),c=t.getText(),u=t.getTextAlign(),d=t.getTextBaseline();this.textState_={font:n!==void 0?n:ZI,textAlign:u!==void 0?u:Ld,textBaseline:d!==void 0?d:Ap},this.text_=c!==void 0?Array.isArray(c)?c.reduce((g,f,p)=>g+=p%2?" ":f,""):c:"",this.textOffsetX_=r!==void 0?this.pixelRatio_*r:0,this.textOffsetY_=o!==void 0?this.pixelRatio_*o:0,this.textRotateWithView_=a!==void 0?a:!1,this.textRotation_=l!==void 0?l:0,this.textScale_=[this.pixelRatio_*h[0],this.pixelRatio_*h[1]]}}}const Xi=.5;function QP(s,t,e,i,n,r,o,a,l){const h=l?km(n):n,c=s[0]*Xi,u=s[1]*Xi,d=Se(c,u);d.imageSmoothingEnabled=!1;const g=d.canvas,f=new JP(d,Xi,n,null,o,a,l?Sl(L9(),l):null),p=e.length,m=Math.floor((256*256*256-1)/p),_={};for(let v=1;v<=p;++v){const S=e[v-1],w=S.getStyleFunction()||i;if(!w)continue;let T=w(S,r);if(!T)continue;Array.isArray(T)||(T=[T]);const M=(v*m).toString(16).padStart(7,"#00000");for(let C=0,I=T.length;C0;return u&&Promise.all(l).then(()=>n(null)),IH(s,t,e,i,r,o,a),u}function IH(s,t,e,i,n,r,o){const a=e.getGeometryFunction()(t);if(!a)return;const l=a.simplifyTransformed(i,n);if(e.getRenderer())iA(s,l,e,t,o);else{const h=eA[l.getType()];h(s,l,e,t,o,r)}}function iA(s,t,e,i,n){if(t.getType()=="GeometryCollection"){const r=t.getGeometries();for(let o=0,a=r.length;o{if(this.frameState&&!this.hitDetectionImageData_&&!this.animatingOrInteracting_){const i=this.frameState.size.slice(),n=this.renderedCenter_,r=this.renderedResolution_,o=this.renderedRotation_,a=this.renderedProjection_,l=this.wrappedRenderedExtent_,h=this.getLayer(),c=[],u=i[0]*Xi,d=i[1]*Xi;c.push(this.getRenderTransform(n,r,o,Xi,u,d,0).slice());const g=h.getSource(),f=a.getExtent();if(g.getWrapX()&&a.canWrapX()&&!ai(f,l)){let p=l[0];const m=Rt(f);let _=0,y;for(;pf[2];)++_,y=m*_,c.push(this.getRenderTransform(n,r,o,Xi,u,d,y).slice()),p-=m}this.hitDetectionImageData_=QP(i,c,this.renderedFeatures_,h.getStyleFunction(),l,r,o,Up(r,this.renderedPixelRatio_),null)}e(tA(t,this.renderedFeatures_,this.hitDetectionImageData_))})}forEachFeatureAtCoordinate(t,e,i,n,r){if(!this.replayGroup_)return;const o=e.viewState.resolution,a=e.viewState.rotation,l=this.getLayer(),h={},c=function(f,p,m){const _=mt(f),y=h[_];if(y){if(y!==!0&&mu=f.forEachFeatureAtCoordinate(t,o,a,i,c,g&&e.declutter[g]?e.declutter[g].all().map(p=>p.value):null)),u}handleFontsChanged(){const t=this.getLayer();t.getVisible()&&this.replayGroup_&&t.changed()}handleStyleImageChange_(t){this.renderIfReadyAndVisible()}prepareFrame(t){const e=this.getLayer(),i=e.getSource();if(!i)return!1;const n=t.viewHints[Ie.ANIMATING],r=t.viewHints[Ie.INTERACTING],o=e.getUpdateWhileAnimating(),a=e.getUpdateWhileInteracting();if(this.ready&&!o&&n||!a&&r)return this.animatingOrInteracting_=!0,!0;this.animatingOrInteracting_=!1;const l=t.extent,h=t.viewState,c=h.projection,u=h.resolution,d=t.pixelRatio,g=e.getRevision(),f=e.getRenderBuffer();let p=e.getRenderOrder();p===void 0&&(p=CH);const m=h.center.slice(),_=_n(l,f*u),y=_.slice(),v=[_.slice()],S=c.getExtent();if(i.getWrapX()&&c.canWrapX()&&!ai(S,t.extent)){const E=Rt(S),b=Math.max(Rt(_)/2,E);_[0]=S[0]-b,_[2]=S[2]+b,_I(m,c);const R=Zx(v[0],c);R[0]S[0]&&R[2]>S[2]&&v.push([R[0]-E,R[1],R[2]-E,R[3]])}if(this.ready&&this.renderedResolution_==u&&this.renderedRevision_==g&&this.renderedRenderOrder_==p&&this.renderedFrameDeclutter_===!!t.declutter&&ai(this.wrappedRenderedExtent_,_))return vl(this.renderedExtent_,y)||(this.hitDetectionImageData_=null,this.renderedExtent_=y),this.renderedCenter_=m,this.replayGroupChanged=!1,!0;this.replayGroup_=null;const w=new ZP(sA(u,d),_,u,d);let T;for(let E=0,b=v.length;E{let R;const A=E.getStyleFunction()||e.getStyleFunction();if(A&&(R=A(E,u)),R){const $=this.renderFeature(E,M,R,w,T,this.getLayer().getDeclutter(),b);C=C&&!$}},O=km(_),P=i.getFeaturesInExtent(O);p&&P.sort(p);for(let E=0,b=P.length;Es):null}const Lc=kH,zs={ADDFEATURE:"addfeature",CHANGEFEATURE:"changefeature",CLEAR:"clear",REMOVEFEATURE:"removefeature",FEATURESLOADSTART:"featuresloadstart",FEATURESLOADEND:"featuresloadend",FEATURESLOADERROR:"featuresloaderror"};function $H(s,t){return[[-1/0,-1/0,1/0,1/0]]}let GH=!1;function rA(s,t,e,i,n,r,o){const a=new XMLHttpRequest;a.open("GET",typeof s=="function"?s(e,i,n):s,!0),t.getType()=="arraybuffer"&&(a.responseType="arraybuffer"),a.withCredentials=GH,a.onload=function(l){if(!a.status||a.status>=200&&a.status<300){const h=t.getType();try{let c;h=="text"||h=="json"?c=a.responseText:h=="xml"?c=a.responseXML||a.responseText:h=="arraybuffer"&&(c=a.response),c?r(t.readFeatures(c,{extent:e,featureProjection:n}),t.readProjection(c)):o()}catch{o()}}else o()},a.onerror=o,a.send()}function SM(s,t){return function(e,i,n,r,o){const a=this;rA(s,t,e,i,n,function(l,h){a.addFeatures(l),r!==void 0&&r(l)},o||Md)}}class Po extends Sr{constructor(t,e,i){super(t),this.feature=e,this.features=i}}class s0 extends Lc{constructor(t){t=t||{},super({attributions:t.attributions,interpolate:!0,projection:void 0,state:"ready",wrapX:t.wrapX!==void 0?t.wrapX:!0}),this.on,this.once,this.un,this.loader_=Md,this.format_=t.format||null,this.overlaps_=t.overlaps===void 0?!0:t.overlaps,this.url_=t.url,t.loader!==void 0?this.loader_=t.loader:this.url_!==void 0&&(qt(this.format_,"`format` must be set when `url` is set"),this.loader_=SM(this.url_,this.format_)),this.strategy_=t.strategy!==void 0?t.strategy:$H;const e=t.useSpatialIndex!==void 0?t.useSpatialIndex:!0;this.featuresRtree_=e?new wM:null,this.loadedExtentsRtree_=new wM,this.loadingExtentsCount_=0,this.nullGeometryFeatures_={},this.idIndex_={},this.uidIndex_={},this.featureChangeKeys_={},this.featuresCollection_=null;let i,n;Array.isArray(t.features)?n=t.features:t.features&&(i=t.features,n=i.getArray()),!e&&i===void 0&&(i=new kp(n)),n!==void 0&&this.addFeaturesInternal(n),i!==void 0&&this.bindFeaturesCollection_(i)}addFeature(t){this.addFeatureInternal(t),this.changed()}addFeatureInternal(t){const e=mt(t);if(!this.addToIndex_(e,t)){this.featuresCollection_&&this.featuresCollection_.remove(t);return}this.setupChangeEvents_(e,t);const i=t.getGeometry();if(i){const n=i.getExtent();this.featuresRtree_&&this.featuresRtree_.insert(n,t)}else this.nullGeometryFeatures_[e]=t;this.dispatchEvent(new Po(zs.ADDFEATURE,t))}setupChangeEvents_(t,e){e instanceof si||(this.featureChangeKeys_[t]=[We(e,Zt.CHANGE,this.handleFeatureChange_,this),We(e,zx.PROPERTYCHANGE,this.handleFeatureChange_,this)])}addToIndex_(t,e){let i=!0;if(e.getId()!==void 0){const n=String(e.getId());if(!(n in this.idIndex_))this.idIndex_[n]=e;else if(e instanceof si){const r=this.idIndex_[n];r instanceof si?Array.isArray(r)?r.push(e):this.idIndex_[n]=[r,e]:i=!1}else i=!1}return i&&(qt(!(t in this.uidIndex_),"The passed `feature` was already added to the source"),this.uidIndex_[t]=e),i}addFeatures(t){this.addFeaturesInternal(t),this.changed()}addFeaturesInternal(t){const e=[],i=[],n=[];for(let r=0,o=t.length;r{e||(e=!0,this.addFeature(i.element),e=!1)}),t.addEventListener(Yo.REMOVE,i=>{e||(e=!0,this.removeFeature(i.element),e=!1)}),this.featuresCollection_=t}clear(t){if(t){for(const i in this.featureChangeKeys_)this.featureChangeKeys_[i].forEach(ms);this.featuresCollection_||(this.featureChangeKeys_={},this.idIndex_={},this.uidIndex_={})}else if(this.featuresRtree_){const i=n=>{this.removeFeatureInternal(n)};this.featuresRtree_.forEach(i);for(const n in this.nullGeometryFeatures_)this.removeFeatureInternal(this.nullGeometryFeatures_[n])}this.featuresCollection_&&this.featuresCollection_.clear(),this.featuresRtree_&&this.featuresRtree_.clear(),this.nullGeometryFeatures_={};const e=new Po(zs.CLEAR);this.dispatchEvent(e),this.changed()}forEachFeature(t){if(this.featuresRtree_)return this.featuresRtree_.forEach(t);this.featuresCollection_&&this.featuresCollection_.forEach(t)}forEachFeatureAtCoordinateDirect(t,e){const i=[t[0],t[1],t[0],t[1]];return this.forEachFeatureInExtent(i,function(n){const r=n.getGeometry();if(r instanceof si||r.intersectsCoordinate(t))return e(n)})}forEachFeatureInExtent(t,e){if(this.featuresRtree_)return this.featuresRtree_.forEachInExtent(t,e);this.featuresCollection_&&this.featuresCollection_.forEach(e)}forEachFeatureIntersectingExtent(t,e){return this.forEachFeatureInExtent(t,function(i){const n=i.getGeometry();if(n instanceof si||n.intersectsExtent(t)){const r=e(i);if(r)return r}})}getFeaturesCollection(){return this.featuresCollection_}getFeatures(){let t;return this.featuresCollection_?t=this.featuresCollection_.getArray().slice(0):this.featuresRtree_&&(t=this.featuresRtree_.getAll(),eo(this.nullGeometryFeatures_)||ee(t,Object.values(this.nullGeometryFeatures_))),t}getFeaturesAtCoordinate(t){const e=[];return this.forEachFeatureAtCoordinateDirect(t,function(i){e.push(i)}),e}getFeaturesInExtent(t,e){if(this.featuresRtree_){if(!(e&&e.canWrapX()&&this.getWrapX()))return this.featuresRtree_.getInExtent(t);const i=Hx(t,e);return[].concat(...i.map(n=>this.featuresRtree_.getInExtent(n)))}return this.featuresCollection_?this.featuresCollection_.getArray().slice(0):[]}getClosestFeatureToCoordinate(t,e){const i=t[0],n=t[1];let r=null;const o=[NaN,NaN];let a=1/0;const l=[-1/0,-1/0,1/0,1/0];return e=e||KU,this.featuresRtree_.forEachInExtent(l,function(h){if(e(h)){const c=h.getGeometry(),u=a;if(a=c instanceof si?0:c.closestPointXY(i,n,o,a),a{--this.loadingExtentsCount_,this.dispatchEvent(new Po(zs.FEATURESLOADEND,void 0,h))},()=>{--this.loadingExtentsCount_,this.dispatchEvent(new Po(zs.FEATURESLOADERROR))}),n.insert(l,{extent:l.slice()}))}this.loading=this.loader_.length<4?!1:this.loadingExtentsCount_>0}refresh(){this.clear(!0),this.loadedExtentsRtree_.clear(),super.refresh()}removeLoadedExtent(t){const e=this.loadedExtentsRtree_;let i;e.forEachInExtent(t,function(n){if(so(n.extent,t))return i=n,!0}),i&&e.remove(i)}removeFeatures(t){let e=!1;for(let i=0,n=t.length;i0&&c.length>0;)p=c.pop(),n=l.pop(),o=h.pop(),y=p.toString(),y in u||(i.push(o[0],o[1]),u[y]=!0),m=c.pop(),r=l.pop(),a=h.pop(),_=(p+m)/2,g=s(_),f=t(g),pI(f[0],f[1],o[0],o[1],a[0],a[1]){const n=i.get("graticule_label");return this.lonLabelStyleBase_.getText().setText(n),this.lonLabelStyleBase_},this.latLabelStyleBase_=new Ps({text:t.latLabelStyle!==void 0?t.latLabelStyle.clone():new al({font:"12px Calibri,sans-serif",textAlign:"right",fill:new Wn({color:"rgba(0,0,0,1)"}),stroke:new wn({color:"rgba(255,255,255,1)",width:3})})}),this.latLabelStyle_=i=>{const n=i.get("graticule_label");return this.latLabelStyleBase_.getText().setText(n),this.latLabelStyleBase_},this.meridiansLabels_=[],this.parallelsLabels_=[],this.addEventListener(Mi.POSTRENDER,this.drawLabels_.bind(this))),this.intervals_=t.intervals!==void 0?t.intervals:WH,this.setSource(new s0({loader:this.loaderFunction.bind(this),strategy:this.strategyFunction.bind(this),features:new kp,overlaps:!1,useSpatialIndex:!1,wrapX:t.wrapX})),this.featurePool_=[],this.lineStyle_=new Ps({stroke:this.strokeStyle_}),this.loadedExtent_=null,this.renderedExtent_=null,this.renderedResolution_=null,this.setRenderOrder(null)}strategyFunction(t,e){let i=t.slice();return this.projection_&&this.getSource().getWrapX()&&Zx(i,this.projection_),this.loadedExtent_&&(a9(this.loadedExtent_,i,e)?i=this.loadedExtent_.slice():this.getSource().removeLoadedExtent(this.loadedExtent_)),[i]}loaderFunction(t,e,i){this.loadedExtent_=t;const n=this.getSource(),r=this.getExtent()||[-1/0,-1/0,1/0,1/0],o=He(r,t);if(this.renderedExtent_&&so(this.renderedExtent_,o)&&this.renderedResolution_===e||(this.renderedExtent_=o,this.renderedResolution_=e,po(o)))return;const a=Rs(o),l=e*e/4;(!this.projection_||!qs(this.projection_,i))&&this.updateProjectionInfo_(i),this.createGraticule_(o,a,e,l);let h=this.meridians_.length+this.parallels_.length;this.meridiansLabels_&&(h+=this.meridians_.length),this.parallelsLabels_&&(h+=this.parallels_.length);let c;for(;h>this.featurePool_.length;)c=new ys,this.featurePool_.push(c);const u=n.getFeaturesCollection();u.clear();let d=0,g,f;for(g=0,f=this.meridians_.length;gMath.PI/2;c=c!==f}const g=jH(t);for(let f=l;f<=h;++f){let p=this.meridians_.length+this.parallels_.length,m,_,y,v;if(this.meridiansLabels_)for(_=0,y=this.meridiansLabels_.length;_=l?(t[0]=a[0],t[2]=a[2]):o=!0);const h=[Dt(e[0],this.minX_,this.maxX_),Dt(e[1],this.minY_,this.maxY_)],c=this.toLonLatTransform_(h);isNaN(c[1])&&(c[1]=Math.abs(this.maxLat_)>=Math.abs(this.minLat_)?this.maxLat_:this.minLat_);let u=Dt(c[0],this.minLon_,this.maxLon_),d=Dt(c[1],this.minLat_,this.maxLat_);const g=this.maxLines_;let f,p,m,_,y=t;o||(y=[Dt(t[0],this.minX_,this.maxX_),Dt(t[1],this.minY_,this.maxY_),Dt(t[2],this.minX_,this.maxX_),Dt(t[3],this.minY_,this.maxY_)]);const v=nc(y,this.toLonLatTransform_,void 0,8);let S=v[3],w=v[2],T=v[1],M=v[0];if(o||(Yi(y,this.bottomLeft_)&&(M=this.minLon_,T=this.minLat_),Yi(y,this.bottomRight_)&&(w=this.maxLon_,T=this.minLat_),Yi(y,this.topLeft_)&&(M=this.minLon_,S=this.maxLat_),Yi(y,this.topRight_)&&(w=this.maxLon_,S=this.maxLat_),S=Dt(S,d,this.maxLat_),w=Dt(w,u,this.maxLon_),T=Dt(T,this.minLat_,d),M=Dt(M,this.minLon_,u)),u=Math.floor(u/r)*r,_=Dt(u,this.minLon_,this.maxLon_),p=this.addMeridian_(_,T,S,n,t,0),f=0,o)for(;(_-=r)>=M&&f++n[o]&&(r=o,o=1);const a=Math.max(e[1],n[r]),l=Math.min(e[3],n[o]),h=Dt(e[1]+Math.abs(e[1]-e[3])*this.lonLabelPosition_,a,l),c=[n[r-1]+(n[o-1]-n[r-1])*(h-n[r])/(n[o]-n[r]),h],u=this.meridiansLabels_[i].geom;return u.setCoordinates(c),u}getMeridians(){return this.meridians_}getParallel_(t,e,i,n,r){const o=UH(t,e,i,this.projection_,n);let a=this.parallels_[r];return a?(a.setFlatCoordinates("XY",o),a.changed()):a=new ls(o,"XY"),a}getParallelPoint_(t,e,i){const n=t.getFlatCoordinates();let r=0,o=n.length-2;n[r]>n[o]&&(r=o,o=0);const a=Math.max(e[0],n[r]),l=Math.min(e[2],n[o]),h=Dt(e[0]+Math.abs(e[0]-e[2])*this.latLabelPosition_,a,l),c=n[r+1]+(n[o+1]-n[r+1])*(h-n[r])/(n[o]-n[r]),u=[h,c],d=this.parallelsLabels_[i].geom;return d.setCoordinates(u),d}getParallels(){return this.parallels_}updateProjectionInfo_(t){const e=st("EPSG:4326"),i=t.getWorldExtent();this.maxLat_=i[3],this.maxLon_=i[2],this.minLat_=i[1],this.minLon_=i[0];const n=vr(t,e);if(this.minLon_=Math.abs(this.minLat_)?this.maxLat_:this.minLat_),this.projection_=t}}const VH=XH;class kl extends Sr{constructor(t,e){super(t),this.layer=e}}const F_={LAYERS:"layers"};class i0 extends $P{constructor(t){t=t||{};const e=Object.assign({},t);delete e.layers;let i=t.layers;super(e),this.on,this.once,this.un,this.layersListenerKeys_=[],this.listenerKeys_={},this.addChangeListener(F_.LAYERS,this.handleLayersChanged_),i?Array.isArray(i)?i=new kp(i.slice(),{unique:!0}):qt(typeof i.getArray=="function","Expected `layers` to be an array or a `Collection`"):i=new kp(void 0,{unique:!0}),this.setLayers(i)}handleLayerChange_(){this.changed()}handleLayersChanged_(){this.layersListenerKeys_.forEach(ms),this.layersListenerKeys_.length=0;const t=this.getLayers();this.layersListenerKeys_.push(We(t,Yo.ADD,this.handleLayersAdd_,this),We(t,Yo.REMOVE,this.handleLayersRemove_,this));for(const i in this.listenerKeys_)this.listenerKeys_[i].forEach(ms);Mc(this.listenerKeys_);const e=t.getArray();for(let i=0,n=e.length;it?t-h:r,S=o+c>e?e-c:o,w=f[3]+v*d[0]+f[1],C=f[0]+S*d[1]+f[2],M=_-f[3],T=y-f[0];(p||u!==0)&&(Ro[0]=M,Io[0]=M,Ro[1]=T,Ir[1]=T,Ir[0]=M+w,Pr[0]=Ir[0],Pr[1]=T+C,Io[1]=Pr[1]);let I;return u!==0?(I=xn(ss(),i,n,1,1,u,-i,-n),Ye(I,Ro),Ye(I,Ir),Ye(I,Pr),Ye(I,Io),Un(Math.min(Ro[0],Ir[0],Pr[0],Io[0]),Math.min(Ro[1],Ir[1],Pr[1],Io[1]),Math.max(Ro[0],Ir[0],Pr[0],Io[0]),Math.max(Ro[1],Ir[1],Pr[1],Io[1]),Dl)):Un(Math.min(M,M+w),Math.min(T,T+C),Math.max(M,M+w),Math.max(T,T+C),Dl),g&&(_=Math.round(_),y=Math.round(y)),{drawImageX:_,drawImageY:y,drawImageW:v,drawImageH:S,originX:h,originY:c,declutterBox:{minX:Dl[0],minY:Dl[1],maxX:Dl[2],maxY:Dl[3],value:m},canvasTransform:I,scale:d}}replayImageOrLabel_(t,e,i,n,r,o,a){const l=!!(o||a),h=n.declutterBox,c=a?a[2]*n.scale[0]/2:0;return h.minX-c<=e[0]&&h.maxX+c>=0&&h.minY-c<=e[1]&&h.maxY+c>=0&&(l&&this.replayTextBackground_(t,Ro,Ir,Pr,Io,o,a),oW(t,n.canvasTransform,r,i,n.originX,n.originY,n.drawImageW,n.drawImageH,n.drawImageX,n.drawImageY,n.scale)),!0}fill_(t){const e=this.alignAndScaleFill_;if(e){const i=Ye(this.renderedTransform_,[0,0]),n=512*this.pixelRatio;t.save(),t.translate(i[0]%n,i[1]%n),e!==1&&t.scale(e,e),t.rotate(this.viewRotation_)}t.fill(),e&&t.restore()}setStrokeStyle_(t,e){t.strokeStyle=e[1],t.lineWidth=e[2],t.lineCap=e[3],t.lineJoin=e[4],t.miterLimit=e[5],t.lineDashOffset=e[7],t.setLineDash(e[6])}drawLabelWithPointPlacement_(t,e,i,n){const r=this.textStates[e],o=this.createLabel(t,e,n,i),a=this.strokeStates[i],l=this.pixelRatio,h=L_(Array.isArray(t)?t[0]:t,r.textAlign||Ld),c=jp[r.textBaseline||Ap],u=a&&a.lineWidth?a.lineWidth:0,d=o.width/l-2*r.scale[0],g=h*d+2*(.5-h)*u,f=c*o.height/l+2*(.5-c)*u;return{label:o,anchorX:g,anchorY:f}}execute_(t,e,i,n,r,o,a,l){const h=this.zIndexContext_;let c;this.pixelCoordinates_&&vl(i,this.renderedTransform_)?c=this.pixelCoordinates_:(this.pixelCoordinates_||(this.pixelCoordinates_=[]),c=Jo(this.coordinates,0,this.coordinates.length,2,i,this.pixelCoordinates_),e9(this.renderedTransform_,i));let u=0;const d=n.length;let g=0,f,p,m,_,y,v,S,w,C,M,T,I,O,P=0,D=0,x=null,E=null;const b=this.coordinateCache_,R=this.viewRotation_,A=Math.round(Math.atan2(-i[1],i[0])*1e12)/1e12,$={context:t,pixelRatio:this.pixelRatio,resolution:this.resolution,rotation:R},G=this.instructions!=n||this.overlaps?0:200;let k,z,V,et;for(;uG&&(this.fill_(t),P=0),D>G&&(t.stroke(),D=0),!P&&!D&&(t.beginPath(),y=NaN,v=NaN),++u;break;case Et.CIRCLE:g=F[1];const ot=c[g],ht=c[g+1],pt=c[g+2],Gt=c[g+3],Kt=pt-ot,bt=Gt-ht,oe=Math.sqrt(Kt*Kt+bt*bt);t.moveTo(ot+oe,ht),t.arc(ot,ht,oe,0,2*Math.PI,!0),++u;break;case Et.CLOSE_PATH:t.closePath(),++u;break;case Et.CUSTOM:g=F[1],f=F[2];const Pe=F[3],hs=F[4],rs=F[5];$.geometry=Pe,$.feature=k,u in b||(b[u]=[]);const Ge=b[u];rs?rs(c,g,f,2,Ge):(Ge[0]=c[g],Ge[1]=c[g+1],Ge.length=2),h&&(h.zIndex=F[6]),hs(Ge,$),++u;break;case Et.DRAW_IMAGE:g=F[1],f=F[2],C=F[3],p=F[4],m=F[5];let ve=F[6];const Ke=F[7],Ni=F[8],Di=F[9],Mn=F[10];let Ks=F[11];const ki=F[12];let $i=F[13];_=F[14]||"declutter";const Jt=F[15];if(!C&&F.length>=20){M=F[19],T=F[20],I=F[21],O=F[22];const Ae=this.drawLabelWithPointPlacement_(M,T,I,O);C=Ae.label,F[3]=C;const Js=F[23];p=(Ae.anchorX-Js)*this.pixelRatio,F[4]=p;const Le=F[24];m=(Ae.anchorY-Le)*this.pixelRatio,F[5]=m,ve=C.height,F[6]=ve,$i=C.width,F[13]=$i}let xa;F.length>25&&(xa=F[25]);let va,br,Cr;F.length>17?(va=F[16],br=F[17],Cr=F[18]):(va=za,br=!1,Cr=!1),Mn&&A?Ks+=R:!Mn&&!A&&(Ks-=R);let S0=0;for(;g!zp.includes(s));class KP{constructor(t,e,i,n,r,o,a){this.maxExtent_=t,this.overlaps_=n,this.pixelRatio_=i,this.resolution_=e,this.renderBuffer_=o,this.executorsByZIndex_={},this.hitDetectionContext_=null,this.hitDetectionTransform_=ss(),this.renderedContext_=null,this.deferredZIndexContexts_={},this.createExecutors_(r,a)}clip(t,e){const i=this.getClipCoords(e);t.beginPath(),t.moveTo(i[0],i[1]),t.lineTo(i[2],i[3]),t.lineTo(i[4],i[5]),t.lineTo(i[6],i[7]),t.clip()}createExecutors_(t,e){for(const i in t){let n=this.executorsByZIndex_[i];n===void 0&&(n={},this.executorsByZIndex_[i]=n);const r=t[i];for(const o in r){const a=r[o];n[o]=new SH(this.resolution_,this.pixelRatio_,this.overlaps_,a,e)}}}hasExecutors(t){for(const e in this.executorsByZIndex_){const i=this.executorsByZIndex_[e];for(let n=0,r=t.length;n0){if(!o||M==="none"||g!=="Image"&&g!=="Text"||o.includes(w)){const P=(d[I]-3)/4,D=n-P%a,x=n-(P/a|0),E=r(w,C,D*D+x*x);if(E)return E}c.clearRect(0,0,a,a);break}}const p=Object.keys(this.executorsByZIndex_).map(Number);p.sort(fr);let m,_,y,v,S;for(m=p.length-1;m>=0;--m){const w=p[m].toString();for(y=this.executorsByZIndex_[w],_=mh.length-1;_>=0;--_)if(g=mh[_],v=y[g],v!==void 0&&(S=v.executeHitDetection(c,l,i,f,u),S))return S}}getClipCoords(t){const e=this.maxExtent_;if(!e)return null;const i=e[0],n=e[1],r=e[2],o=e[3],a=[i,n,i,o,r,o,r,n];return Jo(a,0,8,2,t,a),a}isEmpty(){return eo(this.executorsByZIndex_)}execute(t,e,i,n,r,o,a){const l=Object.keys(this.executorsByZIndex_).map(Number);l.sort(fr),o=o||mh;const h=mh.length;let c,u,d,g,f;for(a&&l.reverse(),c=0,u=l.length;c_.execute(w,e,i,n,r,a)),S&&v.restore(),y){y.offset();const w=l[c]*h+d;this.deferredZIndexContexts_[w]||(this.deferredZIndexContexts_[w]=[]),this.deferredZIndexContexts_[w].push(y)}}}}this.renderedContext_=t}getDeferredZIndexContexts(){return this.deferredZIndexContexts_}getRenderedContext(){return this.renderedContext_}renderDeferred(){const t=this.deferredZIndexContexts_,e=Object.keys(t).map(Number).sort(fr);for(let i=0,n=e.length;i{r.draw(this.renderedContext_),r.clear()}),t[e[i]].length=0}}const O_={};function bH(s){if(O_[s]!==void 0)return O_[s];const t=s*2+1,e=s*s,i=new Array(e+1);for(let r=0;r<=s;++r)for(let o=0;o<=s;++o){const a=r*r+o*o;if(a>e)break;let l=i[a];l||(l=[],i[a]=l),l.push(((s+r)*t+(s+o))*4+3),r>0&&l.push(((s-r)*t+(s+o))*4+3),o>0&&(l.push(((s+r)*t+(s-o))*4+3),r>0&&l.push(((s-r)*t+(s-o))*4+3))}const n=[];for(let r=0,o=i.length;ru*this.pixelRatio_),lineDashOffset:(o||Kr)*this.pixelRatio_,lineJoin:a!==void 0?a:hc,lineWidth:(l!==void 0?l:Od)*this.pixelRatio_,miterLimit:h!==void 0?h:Pd,strokeStyle:hr(i||Ad)}}}setImageStyle(t){let e;if(!t||!(e=t.getSize())){this.image_=null;return}const i=t.getPixelRatio(this.pixelRatio_),n=t.getAnchor(),r=t.getOrigin();this.image_=t.getImage(this.pixelRatio_),this.imageAnchorX_=n[0]*i,this.imageAnchorY_=n[1]*i,this.imageHeight_=e[1]*i,this.imageOpacity_=t.getOpacity(),this.imageOriginX_=r[0],this.imageOriginY_=r[1],this.imageRotateWithView_=t.getRotateWithView(),this.imageRotation_=t.getRotation();const o=t.getScaleArray();this.imageScale_=[o[0]*this.pixelRatio_/i,o[1]*this.pixelRatio_/i],this.imageWidth_=e[0]*i}setTextStyle(t){if(!t)this.text_="";else{const e=t.getFill();if(!e)this.textFillState_=null;else{const g=e.getColor();this.textFillState_={fillStyle:hr(g||Si)}}const i=t.getStroke();if(!i)this.textStrokeState_=null;else{const g=i.getColor(),f=i.getLineCap(),p=i.getLineDash(),m=i.getLineDashOffset(),_=i.getLineJoin(),y=i.getWidth(),v=i.getMiterLimit();this.textStrokeState_={lineCap:f!==void 0?f:lc,lineDash:p||Hr,lineDashOffset:m||Kr,lineJoin:_!==void 0?_:hc,lineWidth:y!==void 0?y:Od,miterLimit:v!==void 0?v:Pd,strokeStyle:hr(g||Ad)}}const n=t.getFont(),r=t.getOffsetX(),o=t.getOffsetY(),a=t.getRotateWithView(),l=t.getRotation(),h=t.getScaleArray(),c=t.getText(),u=t.getTextAlign(),d=t.getTextBaseline();this.textState_={font:n!==void 0?n:ZI,textAlign:u!==void 0?u:Ld,textBaseline:d!==void 0?d:Ap},this.text_=c!==void 0?Array.isArray(c)?c.reduce((g,f,p)=>g+=p%2?" ":f,""):c:"",this.textOffsetX_=r!==void 0?this.pixelRatio_*r:0,this.textOffsetY_=o!==void 0?this.pixelRatio_*o:0,this.textRotateWithView_=a!==void 0?a:!1,this.textRotation_=l!==void 0?l:0,this.textScale_=[this.pixelRatio_*h[0],this.pixelRatio_*h[1]]}}}const Xi=.5;function QP(s,t,e,i,n,r,o,a,l){const h=l?km(n):n,c=s[0]*Xi,u=s[1]*Xi,d=Se(c,u);d.imageSmoothingEnabled=!1;const g=d.canvas,f=new JP(d,Xi,n,null,o,a,l?Sl(L9(),l):null),p=e.length,m=Math.floor((256*256*256-1)/p),_={};for(let v=1;v<=p;++v){const S=e[v-1],w=S.getStyleFunction()||i;if(!w)continue;let C=w(S,r);if(!C)continue;Array.isArray(C)||(C=[C]);const M=(v*m).toString(16).padStart(7,"#00000");for(let T=0,I=C.length;T0;return u&&Promise.all(l).then(()=>n(null)),IH(s,t,e,i,r,o,a),u}function IH(s,t,e,i,n,r,o){const a=e.getGeometryFunction()(t);if(!a)return;const l=a.simplifyTransformed(i,n);if(e.getRenderer())iA(s,l,e,t,o);else{const h=eA[l.getType()];h(s,l,e,t,o,r)}}function iA(s,t,e,i,n){if(t.getType()=="GeometryCollection"){const r=t.getGeometries();for(let o=0,a=r.length;o{if(this.frameState&&!this.hitDetectionImageData_&&!this.animatingOrInteracting_){const i=this.frameState.size.slice(),n=this.renderedCenter_,r=this.renderedResolution_,o=this.renderedRotation_,a=this.renderedProjection_,l=this.wrappedRenderedExtent_,h=this.getLayer(),c=[],u=i[0]*Xi,d=i[1]*Xi;c.push(this.getRenderTransform(n,r,o,Xi,u,d,0).slice());const g=h.getSource(),f=a.getExtent();if(g.getWrapX()&&a.canWrapX()&&!ai(f,l)){let p=l[0];const m=Rt(f);let _=0,y;for(;pf[2];)++_,y=m*_,c.push(this.getRenderTransform(n,r,o,Xi,u,d,y).slice()),p-=m}this.hitDetectionImageData_=QP(i,c,this.renderedFeatures_,h.getStyleFunction(),l,r,o,Up(r,this.renderedPixelRatio_),null)}e(tA(t,this.renderedFeatures_,this.hitDetectionImageData_))})}forEachFeatureAtCoordinate(t,e,i,n,r){if(!this.replayGroup_)return;const o=e.viewState.resolution,a=e.viewState.rotation,l=this.getLayer(),h={},c=function(f,p,m){const _=mt(f),y=h[_];if(y){if(y!==!0&&mu=f.forEachFeatureAtCoordinate(t,o,a,i,c,g&&e.declutter[g]?e.declutter[g].all().map(p=>p.value):null)),u}handleFontsChanged(){const t=this.getLayer();t.getVisible()&&this.replayGroup_&&t.changed()}handleStyleImageChange_(t){this.renderIfReadyAndVisible()}prepareFrame(t){const e=this.getLayer(),i=e.getSource();if(!i)return!1;const n=t.viewHints[Ie.ANIMATING],r=t.viewHints[Ie.INTERACTING],o=e.getUpdateWhileAnimating(),a=e.getUpdateWhileInteracting();if(this.ready&&!o&&n||!a&&r)return this.animatingOrInteracting_=!0,!0;this.animatingOrInteracting_=!1;const l=t.extent,h=t.viewState,c=h.projection,u=h.resolution,d=t.pixelRatio,g=e.getRevision(),f=e.getRenderBuffer();let p=e.getRenderOrder();p===void 0&&(p=TH);const m=h.center.slice(),_=_n(l,f*u),y=_.slice(),v=[_.slice()],S=c.getExtent();if(i.getWrapX()&&c.canWrapX()&&!ai(S,t.extent)){const E=Rt(S),b=Math.max(Rt(_)/2,E);_[0]=S[0]-b,_[2]=S[2]+b,_I(m,c);const R=Zx(v[0],c);R[0]S[0]&&R[2]>S[2]&&v.push([R[0]-E,R[1],R[2]-E,R[3]])}if(this.ready&&this.renderedResolution_==u&&this.renderedRevision_==g&&this.renderedRenderOrder_==p&&this.renderedFrameDeclutter_===!!t.declutter&&ai(this.wrappedRenderedExtent_,_))return vl(this.renderedExtent_,y)||(this.hitDetectionImageData_=null,this.renderedExtent_=y),this.renderedCenter_=m,this.replayGroupChanged=!1,!0;this.replayGroup_=null;const w=new ZP(sA(u,d),_,u,d);let C;for(let E=0,b=v.length;E{let R;const A=E.getStyleFunction()||e.getStyleFunction();if(A&&(R=A(E,u)),R){const $=this.renderFeature(E,M,R,w,C,this.getLayer().getDeclutter(),b);T=T&&!$}},O=km(_),P=i.getFeaturesInExtent(O);p&&P.sort(p);for(let E=0,b=P.length;Es):null}const Lc=kH,zs={ADDFEATURE:"addfeature",CHANGEFEATURE:"changefeature",CLEAR:"clear",REMOVEFEATURE:"removefeature",FEATURESLOADSTART:"featuresloadstart",FEATURESLOADEND:"featuresloadend",FEATURESLOADERROR:"featuresloaderror"};function $H(s,t){return[[-1/0,-1/0,1/0,1/0]]}let GH=!1;function rA(s,t,e,i,n,r,o){const a=new XMLHttpRequest;a.open("GET",typeof s=="function"?s(e,i,n):s,!0),t.getType()=="arraybuffer"&&(a.responseType="arraybuffer"),a.withCredentials=GH,a.onload=function(l){if(!a.status||a.status>=200&&a.status<300){const h=t.getType();try{let c;h=="text"||h=="json"?c=a.responseText:h=="xml"?c=a.responseXML||a.responseText:h=="arraybuffer"&&(c=a.response),c?r(t.readFeatures(c,{extent:e,featureProjection:n}),t.readProjection(c)):o()}catch{o()}}else o()},a.onerror=o,a.send()}function SM(s,t){return function(e,i,n,r,o){const a=this;rA(s,t,e,i,n,function(l,h){a.addFeatures(l),r!==void 0&&r(l)},o||Md)}}class Po extends Sr{constructor(t,e,i){super(t),this.feature=e,this.features=i}}class s0 extends Lc{constructor(t){t=t||{},super({attributions:t.attributions,interpolate:!0,projection:void 0,state:"ready",wrapX:t.wrapX!==void 0?t.wrapX:!0}),this.on,this.once,this.un,this.loader_=Md,this.format_=t.format||null,this.overlaps_=t.overlaps===void 0?!0:t.overlaps,this.url_=t.url,t.loader!==void 0?this.loader_=t.loader:this.url_!==void 0&&(qt(this.format_,"`format` must be set when `url` is set"),this.loader_=SM(this.url_,this.format_)),this.strategy_=t.strategy!==void 0?t.strategy:$H;const e=t.useSpatialIndex!==void 0?t.useSpatialIndex:!0;this.featuresRtree_=e?new wM:null,this.loadedExtentsRtree_=new wM,this.loadingExtentsCount_=0,this.nullGeometryFeatures_={},this.idIndex_={},this.uidIndex_={},this.featureChangeKeys_={},this.featuresCollection_=null;let i,n;Array.isArray(t.features)?n=t.features:t.features&&(i=t.features,n=i.getArray()),!e&&i===void 0&&(i=new kp(n)),n!==void 0&&this.addFeaturesInternal(n),i!==void 0&&this.bindFeaturesCollection_(i)}addFeature(t){this.addFeatureInternal(t),this.changed()}addFeatureInternal(t){const e=mt(t);if(!this.addToIndex_(e,t)){this.featuresCollection_&&this.featuresCollection_.remove(t);return}this.setupChangeEvents_(e,t);const i=t.getGeometry();if(i){const n=i.getExtent();this.featuresRtree_&&this.featuresRtree_.insert(n,t)}else this.nullGeometryFeatures_[e]=t;this.dispatchEvent(new Po(zs.ADDFEATURE,t))}setupChangeEvents_(t,e){e instanceof si||(this.featureChangeKeys_[t]=[We(e,Zt.CHANGE,this.handleFeatureChange_,this),We(e,zx.PROPERTYCHANGE,this.handleFeatureChange_,this)])}addToIndex_(t,e){let i=!0;if(e.getId()!==void 0){const n=String(e.getId());if(!(n in this.idIndex_))this.idIndex_[n]=e;else if(e instanceof si){const r=this.idIndex_[n];r instanceof si?Array.isArray(r)?r.push(e):this.idIndex_[n]=[r,e]:i=!1}else i=!1}return i&&(qt(!(t in this.uidIndex_),"The passed `feature` was already added to the source"),this.uidIndex_[t]=e),i}addFeatures(t){this.addFeaturesInternal(t),this.changed()}addFeaturesInternal(t){const e=[],i=[],n=[];for(let r=0,o=t.length;r{e||(e=!0,this.addFeature(i.element),e=!1)}),t.addEventListener(Yo.REMOVE,i=>{e||(e=!0,this.removeFeature(i.element),e=!1)}),this.featuresCollection_=t}clear(t){if(t){for(const i in this.featureChangeKeys_)this.featureChangeKeys_[i].forEach(ms);this.featuresCollection_||(this.featureChangeKeys_={},this.idIndex_={},this.uidIndex_={})}else if(this.featuresRtree_){const i=n=>{this.removeFeatureInternal(n)};this.featuresRtree_.forEach(i);for(const n in this.nullGeometryFeatures_)this.removeFeatureInternal(this.nullGeometryFeatures_[n])}this.featuresCollection_&&this.featuresCollection_.clear(),this.featuresRtree_&&this.featuresRtree_.clear(),this.nullGeometryFeatures_={};const e=new Po(zs.CLEAR);this.dispatchEvent(e),this.changed()}forEachFeature(t){if(this.featuresRtree_)return this.featuresRtree_.forEach(t);this.featuresCollection_&&this.featuresCollection_.forEach(t)}forEachFeatureAtCoordinateDirect(t,e){const i=[t[0],t[1],t[0],t[1]];return this.forEachFeatureInExtent(i,function(n){const r=n.getGeometry();if(r instanceof si||r.intersectsCoordinate(t))return e(n)})}forEachFeatureInExtent(t,e){if(this.featuresRtree_)return this.featuresRtree_.forEachInExtent(t,e);this.featuresCollection_&&this.featuresCollection_.forEach(e)}forEachFeatureIntersectingExtent(t,e){return this.forEachFeatureInExtent(t,function(i){const n=i.getGeometry();if(n instanceof si||n.intersectsExtent(t)){const r=e(i);if(r)return r}})}getFeaturesCollection(){return this.featuresCollection_}getFeatures(){let t;return this.featuresCollection_?t=this.featuresCollection_.getArray().slice(0):this.featuresRtree_&&(t=this.featuresRtree_.getAll(),eo(this.nullGeometryFeatures_)||ee(t,Object.values(this.nullGeometryFeatures_))),t}getFeaturesAtCoordinate(t){const e=[];return this.forEachFeatureAtCoordinateDirect(t,function(i){e.push(i)}),e}getFeaturesInExtent(t,e){if(this.featuresRtree_){if(!(e&&e.canWrapX()&&this.getWrapX()))return this.featuresRtree_.getInExtent(t);const i=Hx(t,e);return[].concat(...i.map(n=>this.featuresRtree_.getInExtent(n)))}return this.featuresCollection_?this.featuresCollection_.getArray().slice(0):[]}getClosestFeatureToCoordinate(t,e){const i=t[0],n=t[1];let r=null;const o=[NaN,NaN];let a=1/0;const l=[-1/0,-1/0,1/0,1/0];return e=e||KU,this.featuresRtree_.forEachInExtent(l,function(h){if(e(h)){const c=h.getGeometry(),u=a;if(a=c instanceof si?0:c.closestPointXY(i,n,o,a),a{--this.loadingExtentsCount_,this.dispatchEvent(new Po(zs.FEATURESLOADEND,void 0,h))},()=>{--this.loadingExtentsCount_,this.dispatchEvent(new Po(zs.FEATURESLOADERROR))}),n.insert(l,{extent:l.slice()}))}this.loading=this.loader_.length<4?!1:this.loadingExtentsCount_>0}refresh(){this.clear(!0),this.loadedExtentsRtree_.clear(),super.refresh()}removeLoadedExtent(t){const e=this.loadedExtentsRtree_;let i;e.forEachInExtent(t,function(n){if(so(n.extent,t))return i=n,!0}),i&&e.remove(i)}removeFeatures(t){let e=!1;for(let i=0,n=t.length;i0&&c.length>0;)p=c.pop(),n=l.pop(),o=h.pop(),y=p.toString(),y in u||(i.push(o[0],o[1]),u[y]=!0),m=c.pop(),r=l.pop(),a=h.pop(),_=(p+m)/2,g=s(_),f=t(g),pI(f[0],f[1],o[0],o[1],a[0],a[1]){const n=i.get("graticule_label");return this.lonLabelStyleBase_.getText().setText(n),this.lonLabelStyleBase_},this.latLabelStyleBase_=new Ps({text:t.latLabelStyle!==void 0?t.latLabelStyle.clone():new al({font:"12px Calibri,sans-serif",textAlign:"right",fill:new Wn({color:"rgba(0,0,0,1)"}),stroke:new wn({color:"rgba(255,255,255,1)",width:3})})}),this.latLabelStyle_=i=>{const n=i.get("graticule_label");return this.latLabelStyleBase_.getText().setText(n),this.latLabelStyleBase_},this.meridiansLabels_=[],this.parallelsLabels_=[],this.addEventListener(Mi.POSTRENDER,this.drawLabels_.bind(this))),this.intervals_=t.intervals!==void 0?t.intervals:WH,this.setSource(new s0({loader:this.loaderFunction.bind(this),strategy:this.strategyFunction.bind(this),features:new kp,overlaps:!1,useSpatialIndex:!1,wrapX:t.wrapX})),this.featurePool_=[],this.lineStyle_=new Ps({stroke:this.strokeStyle_}),this.loadedExtent_=null,this.renderedExtent_=null,this.renderedResolution_=null,this.setRenderOrder(null)}strategyFunction(t,e){let i=t.slice();return this.projection_&&this.getSource().getWrapX()&&Zx(i,this.projection_),this.loadedExtent_&&(a9(this.loadedExtent_,i,e)?i=this.loadedExtent_.slice():this.getSource().removeLoadedExtent(this.loadedExtent_)),[i]}loaderFunction(t,e,i){this.loadedExtent_=t;const n=this.getSource(),r=this.getExtent()||[-1/0,-1/0,1/0,1/0],o=He(r,t);if(this.renderedExtent_&&so(this.renderedExtent_,o)&&this.renderedResolution_===e||(this.renderedExtent_=o,this.renderedResolution_=e,po(o)))return;const a=Rs(o),l=e*e/4;(!this.projection_||!qs(this.projection_,i))&&this.updateProjectionInfo_(i),this.createGraticule_(o,a,e,l);let h=this.meridians_.length+this.parallels_.length;this.meridiansLabels_&&(h+=this.meridians_.length),this.parallelsLabels_&&(h+=this.parallels_.length);let c;for(;h>this.featurePool_.length;)c=new ys,this.featurePool_.push(c);const u=n.getFeaturesCollection();u.clear();let d=0,g,f;for(g=0,f=this.meridians_.length;gMath.PI/2;c=c!==f}const g=jH(t);for(let f=l;f<=h;++f){let p=this.meridians_.length+this.parallels_.length,m,_,y,v;if(this.meridiansLabels_)for(_=0,y=this.meridiansLabels_.length;_=l?(t[0]=a[0],t[2]=a[2]):o=!0);const h=[Dt(e[0],this.minX_,this.maxX_),Dt(e[1],this.minY_,this.maxY_)],c=this.toLonLatTransform_(h);isNaN(c[1])&&(c[1]=Math.abs(this.maxLat_)>=Math.abs(this.minLat_)?this.maxLat_:this.minLat_);let u=Dt(c[0],this.minLon_,this.maxLon_),d=Dt(c[1],this.minLat_,this.maxLat_);const g=this.maxLines_;let f,p,m,_,y=t;o||(y=[Dt(t[0],this.minX_,this.maxX_),Dt(t[1],this.minY_,this.maxY_),Dt(t[2],this.minX_,this.maxX_),Dt(t[3],this.minY_,this.maxY_)]);const v=nc(y,this.toLonLatTransform_,void 0,8);let S=v[3],w=v[2],C=v[1],M=v[0];if(o||(Yi(y,this.bottomLeft_)&&(M=this.minLon_,C=this.minLat_),Yi(y,this.bottomRight_)&&(w=this.maxLon_,C=this.minLat_),Yi(y,this.topLeft_)&&(M=this.minLon_,S=this.maxLat_),Yi(y,this.topRight_)&&(w=this.maxLon_,S=this.maxLat_),S=Dt(S,d,this.maxLat_),w=Dt(w,u,this.maxLon_),C=Dt(C,this.minLat_,d),M=Dt(M,this.minLon_,u)),u=Math.floor(u/r)*r,_=Dt(u,this.minLon_,this.maxLon_),p=this.addMeridian_(_,C,S,n,t,0),f=0,o)for(;(_-=r)>=M&&f++n[o]&&(r=o,o=1);const a=Math.max(e[1],n[r]),l=Math.min(e[3],n[o]),h=Dt(e[1]+Math.abs(e[1]-e[3])*this.lonLabelPosition_,a,l),c=[n[r-1]+(n[o-1]-n[r-1])*(h-n[r])/(n[o]-n[r]),h],u=this.meridiansLabels_[i].geom;return u.setCoordinates(c),u}getMeridians(){return this.meridians_}getParallel_(t,e,i,n,r){const o=UH(t,e,i,this.projection_,n);let a=this.parallels_[r];return a?(a.setFlatCoordinates("XY",o),a.changed()):a=new ls(o,"XY"),a}getParallelPoint_(t,e,i){const n=t.getFlatCoordinates();let r=0,o=n.length-2;n[r]>n[o]&&(r=o,o=0);const a=Math.max(e[0],n[r]),l=Math.min(e[2],n[o]),h=Dt(e[0]+Math.abs(e[0]-e[2])*this.latLabelPosition_,a,l),c=n[r+1]+(n[o+1]-n[r+1])*(h-n[r])/(n[o]-n[r]),u=[h,c],d=this.parallelsLabels_[i].geom;return d.setCoordinates(u),d}getParallels(){return this.parallels_}updateProjectionInfo_(t){const e=st("EPSG:4326"),i=t.getWorldExtent();this.maxLat_=i[3],this.maxLon_=i[2],this.minLat_=i[1],this.minLon_=i[0];const n=vr(t,e);if(this.minLon_=Math.abs(this.minLat_)?this.maxLat_:this.minLat_),this.projection_=t}}const VH=XH;class kl extends Sr{constructor(t,e){super(t),this.layer=e}}const F_={LAYERS:"layers"};class i0 extends $P{constructor(t){t=t||{};const e=Object.assign({},t);delete e.layers;let i=t.layers;super(e),this.on,this.once,this.un,this.layersListenerKeys_=[],this.listenerKeys_={},this.addChangeListener(F_.LAYERS,this.handleLayersChanged_),i?Array.isArray(i)?i=new kp(i.slice(),{unique:!0}):qt(typeof i.getArray=="function","Expected `layers` to be an array or a `Collection`"):i=new kp(void 0,{unique:!0}),this.setLayers(i)}handleLayerChange_(){this.changed()}handleLayersChanged_(){this.layersListenerKeys_.forEach(ms),this.layersListenerKeys_.length=0;const t=this.getLayers();this.layersListenerKeys_.push(We(t,Yo.ADD,this.handleLayersAdd_,this),We(t,Yo.REMOVE,this.handleLayersRemove_,this));for(const i in this.listenerKeys_)this.listenerKeys_[i].forEach(ms);Mc(this.listenerKeys_);const e=t.getArray();for(let i=0,n=e.length;i0&&(p=1e5/Math.pow(10,d) void main() { gl_FragColor = texture2D(u_image, v_texCoord) * u_opacity; } -`;class bM{constructor(t){this.gl_=t.webGlContext;const e=this.gl_;this.scaleRatio_=t.scaleRatio||1,this.renderTargetTexture_=e.createTexture(),this.renderTargetTextureSize_=null,this.frameBuffer_=e.createFramebuffer(),this.depthBuffer_=e.createRenderbuffer();const i=e.createShader(e.VERTEX_SHADER);e.shaderSource(i,t.vertexShader||QH),e.compileShader(i);const n=e.createShader(e.FRAGMENT_SHADER);e.shaderSource(n,t.fragmentShader||tK),e.compileShader(n),this.renderTargetProgram_=e.createProgram(),e.attachShader(this.renderTargetProgram_,i),e.attachShader(this.renderTargetProgram_,n),e.linkProgram(this.renderTargetProgram_),this.renderTargetVerticesBuffer_=e.createBuffer();const r=[-1,-1,1,-1,-1,1,1,-1,1,1,-1,1];e.bindBuffer(e.ARRAY_BUFFER,this.renderTargetVerticesBuffer_),e.bufferData(e.ARRAY_BUFFER,new Float32Array(r),e.STATIC_DRAW),this.renderTargetAttribLocation_=e.getAttribLocation(this.renderTargetProgram_,"a_position"),this.renderTargetUniformLocation_=e.getUniformLocation(this.renderTargetProgram_,"u_screenSize"),this.renderTargetOpacityLocation_=e.getUniformLocation(this.renderTargetProgram_,"u_opacity"),this.renderTargetTextureLocation_=e.getUniformLocation(this.renderTargetProgram_,"u_image"),this.uniforms_=[],t.uniforms&&Object.keys(t.uniforms).forEach(o=>{this.uniforms_.push({value:t.uniforms[o],location:e.getUniformLocation(this.renderTargetProgram_,o)})})}getGL(){return this.gl_}init(t){const e=this.getGL(),i=[e.drawingBufferWidth*this.scaleRatio_,e.drawingBufferHeight*this.scaleRatio_];if(e.bindFramebuffer(e.FRAMEBUFFER,this.getFrameBuffer()),e.bindRenderbuffer(e.RENDERBUFFER,this.getDepthBuffer()),e.viewport(0,0,i[0],i[1]),!this.renderTargetTextureSize_||this.renderTargetTextureSize_[0]!==i[0]||this.renderTargetTextureSize_[1]!==i[1]){this.renderTargetTextureSize_=i;const n=0,r=e.RGBA,o=0,a=e.RGBA,l=e.UNSIGNED_BYTE;e.bindTexture(e.TEXTURE_2D,this.renderTargetTexture_),e.texImage2D(e.TEXTURE_2D,n,r,i[0],i[1],o,a,l,null),e.texParameteri(e.TEXTURE_2D,e.TEXTURE_MIN_FILTER,e.LINEAR),e.texParameteri(e.TEXTURE_2D,e.TEXTURE_WRAP_S,e.CLAMP_TO_EDGE),e.texParameteri(e.TEXTURE_2D,e.TEXTURE_WRAP_T,e.CLAMP_TO_EDGE),e.framebufferTexture2D(e.FRAMEBUFFER,e.COLOR_ATTACHMENT0,e.TEXTURE_2D,this.renderTargetTexture_,0),e.renderbufferStorage(e.RENDERBUFFER,e.DEPTH_COMPONENT16,i[0],i[1]),e.framebufferRenderbuffer(e.FRAMEBUFFER,e.DEPTH_ATTACHMENT,e.RENDERBUFFER,this.depthBuffer_)}}apply(t,e,i,n){const r=this.getGL(),o=t.size;if(r.bindFramebuffer(r.FRAMEBUFFER,e?e.getFrameBuffer():null),r.activeTexture(r.TEXTURE0),r.bindTexture(r.TEXTURE_2D,this.renderTargetTexture_),!e){const l=mt(r.canvas);if(!t.renderTargets[l]){const h=r.getContextAttributes();h&&h.preserveDrawingBuffer&&(r.clearColor(0,0,0,0),r.clearDepth(1),r.clear(r.COLOR_BUFFER_BIT|r.DEPTH_BUFFER_BIT)),t.renderTargets[l]=!0}}r.disable(r.DEPTH_TEST),r.enable(r.BLEND),r.blendFunc(r.ONE,r.ONE_MINUS_SRC_ALPHA),r.viewport(0,0,r.drawingBufferWidth,r.drawingBufferHeight),r.bindBuffer(r.ARRAY_BUFFER,this.renderTargetVerticesBuffer_),r.useProgram(this.renderTargetProgram_),r.enableVertexAttribArray(this.renderTargetAttribLocation_),r.vertexAttribPointer(this.renderTargetAttribLocation_,2,r.FLOAT,!1,0,0),r.uniform2f(this.renderTargetUniformLocation_,o[0],o[1]),r.uniform1i(this.renderTargetTextureLocation_,0);const a=t.layerStatesArray[t.layerIndex].opacity;r.uniform1f(this.renderTargetOpacityLocation_,a),this.applyUniforms(t),i&&i(r,t),r.drawArrays(r.TRIANGLES,0,6),n&&n(r,t)}getFrameBuffer(){return this.frameBuffer_}getDepthBuffer(){return this.depthBuffer_}applyUniforms(t){const e=this.getGL();let i,n=1;this.uniforms_.forEach(function(r){if(i=typeof r.value=="function"?r.value(t):r.value,i instanceof HTMLCanvasElement||i instanceof ImageData)r.texture||(r.texture=e.createTexture()),e.activeTexture(e[`TEXTURE${n}`]),e.bindTexture(e.TEXTURE_2D,r.texture),e.texParameteri(e.TEXTURE_2D,e.TEXTURE_MIN_FILTER,e.LINEAR),e.texParameteri(e.TEXTURE_2D,e.TEXTURE_WRAP_S,e.CLAMP_TO_EDGE),e.texParameteri(e.TEXTURE_2D,e.TEXTURE_WRAP_T,e.CLAMP_TO_EDGE),i instanceof ImageData?e.texImage2D(e.TEXTURE_2D,0,e.RGBA,e.RGBA,i.width,i.height,0,e.UNSIGNED_BYTE,new Uint8Array(i.data)):e.texImage2D(e.TEXTURE_2D,0,e.RGBA,e.RGBA,e.UNSIGNED_BYTE,i),e.uniform1i(r.location,n++);else if(Array.isArray(i))switch(i.length){case 2:e.uniform2f(r.location,i[0],i[1]);return;case 3:e.uniform3f(r.location,i[0],i[1],i[2]);return;case 4:e.uniform4f(r.location,i[0],i[1],i[2],i[3]);return;default:return}else typeof i=="number"&&e.uniform1f(r.location,i)})}}function lA(){return[1,0,0,0,0,1,0,0,0,0,1,0,0,0,0,1]}function hA(s,t){return s[0]=t[0],s[1]=t[1],s[4]=t[2],s[5]=t[3],s[12]=t[4],s[13]=t[5],s}const Or={PROJECTION_MATRIX:"u_projectionMatrix",SCREEN_TO_WORLD_MATRIX:"u_screenToWorldMatrix",TIME:"u_time",ZOOM:"u_zoom",RESOLUTION:"u_resolution",ROTATION:"u_rotation",VIEWPORT_SIZE_PX:"u_viewportSizePx",PIXEL_RATIO:"u_pixelRatio",HIT_DETECTION:"u_hitDetection"},nr={UNSIGNED_BYTE:qH,UNSIGNED_SHORT:ZH,UNSIGNED_INT:HH,FLOAT:aA},Xp={};function TM(s){return"shared/"+s}let CM=0;function eK(){const s="unique/"+CM;return CM+=1,s}function sK(s){let t=Xp[s];if(!t){const e=document.createElement("canvas");e.width=1,e.height=1,e.style.position="absolute",e.style.left="0",t={users:0,context:KH(e)},Xp[s]=t}return t.users+=1,t.context}function iK(s){const t=Xp[s];if(!t||(t.users-=1,t.users>0))return;const e=t.context,i=e.getExtension("WEBGL_lose_context");i&&i.loseContext();const n=e.canvas;n.width=1,n.height=1,delete Xp[s]}class nK extends Ux{constructor(t){super(),t=t||{},this.boundHandleWebGLContextLost_=this.handleWebGLContextLost.bind(this),this.boundHandleWebGLContextRestored_=this.handleWebGLContextRestored.bind(this),this.canvasCacheKey_=t.canvasCacheKey?TM(t.canvasCacheKey):eK(),this.gl_=sK(this.canvasCacheKey_),this.bufferCache_={},this.extensionCache_={},this.currentProgram_=null,this.needsToBeRecreated_=!1;const e=this.gl_.canvas;e.addEventListener(Tf.LOST,this.boundHandleWebGLContextLost_),e.addEventListener(Tf.RESTORED,this.boundHandleWebGLContextRestored_),this.offsetRotateMatrix_=ss(),this.offsetScaleMatrix_=ss(),this.tmpMat4_=lA(),this.uniformLocationsByProgram_={},this.attribLocationsByProgram_={},this.uniforms_=[],t.uniforms&&this.setUniforms(t.uniforms),this.postProcessPasses_=t.postProcesses?t.postProcesses.map(i=>new bM({webGlContext:this.gl_,scaleRatio:i.scaleRatio,vertexShader:i.vertexShader,fragmentShader:i.fragmentShader,uniforms:i.uniforms})):[new bM({webGlContext:this.gl_})],this.shaderCompileErrors_=null,this.startTime_=Date.now()}setUniforms(t){this.uniforms_=[],this.addUniforms(t)}addUniforms(t){for(const e in t)this.uniforms_.push({name:e,value:t[e]})}canvasCacheKeyMatches(t){return this.canvasCacheKey_===TM(t)}getExtension(t){if(t in this.extensionCache_)return this.extensionCache_[t];const e=this.gl_.getExtension(t);return this.extensionCache_[t]=e,e}bindBuffer(t){const e=this.gl_,i=mt(t);let n=this.bufferCache_[i];if(!n){const r=e.createBuffer();n={buffer:t,webGlBuffer:r},this.bufferCache_[i]=n}e.bindBuffer(t.getType(),n.webGlBuffer)}flushBufferData(t){const e=this.gl_;this.bindBuffer(t),e.bufferData(t.getType(),t.getArray(),t.getUsage())}deleteBuffer(t){const e=this.gl_,i=mt(t),n=this.bufferCache_[i];n&&!e.isContextLost()&&e.deleteBuffer(n.webGlBuffer),delete this.bufferCache_[i]}disposeInternal(){const t=this.gl_.canvas;t.removeEventListener(Tf.LOST,this.boundHandleWebGLContextLost_),t.removeEventListener(Tf.RESTORED,this.boundHandleWebGLContextRestored_),iK(this.canvasCacheKey_),delete this.gl_}prepareDraw(t,e,i){const n=this.gl_,r=this.getCanvas(),o=t.size,a=t.pixelRatio;(r.width!==o[0]*a||r.height!==o[1]*a)&&(r.width=o[0]*a,r.height=o[1]*a,r.style.width=o[0]+"px",r.style.height=o[1]+"px");for(let l=this.postProcessPasses_.length-1;l>=0;l--)this.postProcessPasses_[l].init(t);n.bindTexture(n.TEXTURE_2D,null),n.clearColor(0,0,0,0),n.depthRange(0,1),n.clearDepth(1),n.clear(n.COLOR_BUFFER_BIT|n.DEPTH_BUFFER_BIT),n.enable(n.BLEND),n.blendFunc(n.ONE,e?n.ZERO:n.ONE_MINUS_SRC_ALPHA),i?(n.enable(n.DEPTH_TEST),n.depthFunc(n.LEQUAL)):n.disable(n.DEPTH_TEST)}bindTexture(t,e,i){const n=this.gl_;n.activeTexture(n.TEXTURE0+e),n.bindTexture(n.TEXTURE_2D,t),n.uniform1i(this.getUniformLocation(i),e)}prepareDrawToRenderTarget(t,e,i,n){const r=this.gl_,o=e.getSize();r.bindFramebuffer(r.FRAMEBUFFER,e.getFramebuffer()),r.bindRenderbuffer(r.RENDERBUFFER,e.getDepthbuffer()),r.viewport(0,0,o[0],o[1]),r.bindTexture(r.TEXTURE_2D,e.getTexture()),r.clearColor(0,0,0,0),r.depthRange(0,1),r.clearDepth(1),r.clear(r.COLOR_BUFFER_BIT|r.DEPTH_BUFFER_BIT),r.enable(r.BLEND),r.blendFunc(r.ONE,i?r.ZERO:r.ONE_MINUS_SRC_ALPHA),n?(r.enable(r.DEPTH_TEST),r.depthFunc(r.LEQUAL)):r.disable(r.DEPTH_TEST)}drawElements(t,e){const i=this.gl_;this.getExtension("OES_element_index_uint");const n=i.UNSIGNED_INT,r=4,o=e-t,a=t*r;i.drawElements(i.TRIANGLES,o,n,a)}finalizeDraw(t,e,i){for(let n=0,r=this.postProcessPasses_.length;n{if(i=typeof r.value=="function"?r.value(t):r.value,i instanceof HTMLCanvasElement||i instanceof HTMLImageElement||i instanceof ImageData||i instanceof WebGLTexture){i instanceof WebGLTexture&&!r.texture?(r.prevValue=void 0,r.texture=i):r.texture||(r.prevValue=void 0,r.texture=e.createTexture()),this.bindTexture(r.texture,n,r.name),e.texParameteri(e.TEXTURE_2D,e.TEXTURE_MIN_FILTER,e.LINEAR),e.texParameteri(e.TEXTURE_2D,e.TEXTURE_WRAP_S,e.CLAMP_TO_EDGE),e.texParameteri(e.TEXTURE_2D,e.TEXTURE_WRAP_T,e.CLAMP_TO_EDGE);const o=!(i instanceof HTMLImageElement)||i.complete;!(i instanceof WebGLTexture)&&o&&r.prevValue!==i&&(r.prevValue=i,e.texImage2D(e.TEXTURE_2D,0,e.RGBA,e.RGBA,e.UNSIGNED_BYTE,i)),n++}else if(Array.isArray(i)&&i.length===6)this.setUniformMatrixValue(r.name,hA(this.tmpMat4_,i));else if(Array.isArray(i)&&i.length<=4)switch(i.length){case 2:e.uniform2f(this.getUniformLocation(r.name),i[0],i[1]);return;case 3:e.uniform3f(this.getUniformLocation(r.name),i[0],i[1],i[2]);return;case 4:e.uniform4f(this.getUniformLocation(r.name),i[0],i[1],i[2],i[3]);return;default:return}else typeof i=="number"&&e.uniform1f(this.getUniformLocation(r.name),i)})}useProgram(t,e){this.gl_.useProgram(t),this.currentProgram_=t,this.applyFrameState(e),this.applyUniforms(e)}compileShader(t,e){const i=this.gl_,n=i.createShader(e);return i.shaderSource(n,t),i.compileShader(n),n}getProgram(t,e){const i=this.gl_,n=this.compileShader(t,i.FRAGMENT_SHADER),r=this.compileShader(e,i.VERTEX_SHADER),o=i.createProgram();if(i.attachShader(o,n),i.attachShader(o,r),i.linkProgram(o),!i.getShaderParameter(n,i.COMPILE_STATUS)){const a=`Fragment shader compilation failed: ${i.getShaderInfoLog(n)}`;throw new Error(a)}if(i.deleteShader(n),!i.getShaderParameter(r,i.COMPILE_STATUS)){const a=`Vertex shader compilation failed: ${i.getShaderInfoLog(r)}`;throw new Error(a)}if(i.deleteShader(r),!i.getProgramParameter(o,i.LINK_STATUS)){const a=`GL program linking failed: ${i.getProgramInfoLog(o)}`;throw new Error(a)}return o}getUniformLocation(t){const e=mt(this.currentProgram_);return this.uniformLocationsByProgram_[e]===void 0&&(this.uniformLocationsByProgram_[e]={}),this.uniformLocationsByProgram_[e][t]===void 0&&(this.uniformLocationsByProgram_[e][t]=this.gl_.getUniformLocation(this.currentProgram_,t)),this.uniformLocationsByProgram_[e][t]}getAttributeLocation(t){const e=mt(this.currentProgram_);return this.attribLocationsByProgram_[e]===void 0&&(this.attribLocationsByProgram_[e]={}),this.attribLocationsByProgram_[e][t]===void 0&&(this.attribLocationsByProgram_[e][t]=this.gl_.getAttribLocation(this.currentProgram_,t)),this.attribLocationsByProgram_[e][t]}makeProjectionTransform(t,e){const i=t.size,n=t.viewState.rotation,r=t.viewState.resolution,o=t.viewState.center;return xn(e,0,0,2/(r*i[0]),2/(r*i[1]),-n,-o[0],-o[1]),e}setUniformFloatValue(t,e){this.gl_.uniform1f(this.getUniformLocation(t),e)}setUniformFloatVec2(t,e){this.gl_.uniform2fv(this.getUniformLocation(t),e)}setUniformFloatVec4(t,e){this.gl_.uniform4fv(this.getUniformLocation(t),e)}setUniformMatrixValue(t,e){this.gl_.uniformMatrix4fv(this.getUniformLocation(t),!1,e)}enableAttributeArray_(t,e,i,n,r){const o=this.getAttributeLocation(t);o<0||(this.gl_.enableVertexAttribArray(o),this.gl_.vertexAttribPointer(o,e,i,!1,n,r))}enableAttributes(t){const e=rK(t);let i=0;for(let n=0;nthis.size_[0]||e>=this.size_[1])return Kn[0]=0,Kn[1]=0,Kn[2]=0,Kn[3]=0,Kn;this.readAll();const i=Math.floor(t)+(this.size_[1]-Math.floor(e)-1)*this.size_[0];return Kn[0]=this.data_[i*4],Kn[1]=this.data_[i*4+1],Kn[2]=this.data_[i*4+2],Kn[3]=this.data_[i*4+3],Kn}getTexture(){return this.texture_}getFramebuffer(){return this.framebuffer_}getDepthbuffer(){return this.depthbuffer_}updateSize_(){const t=this.size_,e=this.helper_.getGL();this.texture_=this.helper_.createTexture(t,null,this.texture_),e.bindFramebuffer(e.FRAMEBUFFER,this.framebuffer_),e.viewport(0,0,t[0],t[1]),e.framebufferTexture2D(e.FRAMEBUFFER,e.COLOR_ATTACHMENT0,e.TEXTURE_2D,this.texture_,0),e.bindRenderbuffer(e.RENDERBUFFER,this.depthbuffer_),e.renderbufferStorage(e.RENDERBUFFER,e.DEPTH_COMPONENT16,t[0],t[1]),e.framebufferRenderbuffer(e.FRAMEBUFFER,e.DEPTH_ATTACHMENT,e.RENDERBUFFER,this.depthbuffer_),this.data_=new Uint8Array(t[0]*t[1]*4)}}const RM={GENERATE_POLYGON_BUFFERS:"GENERATE_POLYGON_BUFFERS",GENERATE_POINT_BUFFERS:"GENERATE_POINT_BUFFERS",GENERATE_LINE_STRING_BUFFERS:"GENERATE_LINE_STRING_BUFFERS"},IM=.985;function aK(s,t){t=t||[];const e=256,i=e-1;return t[0]=Math.floor(s/e/e/e)/i,t[1]=Math.floor(s/e/e)%e/i,t[2]=Math.floor(s/e)%e/i,t[3]=s%e/i,t}function lK(s){let t=0;const e=256,i=e-1;return t+=Math.round(s[0]*e*e*e*i),t+=Math.round(s[1]*e*e*i),t+=Math.round(s[2]*e*i),t+=Math.round(s[3]*i),t}function hK(){const s='const t="GENERATE_POLYGON_BUFFERS",e="GENERATE_POINT_BUFFERS",n="GENERATE_LINE_STRING_BUFFERS";function r(t,e){const n=e[0],r=e[1];return e[0]=t[0]*n+t[2]*r+t[4],e[1]=t[1]*n+t[3]*r+t[5],e}function x(t,e){const n=(r=e)[0]*r[3]-r[1]*r[2];var r;!function(t,e){if(!t)throw new Error(e)}(0!==n,"Transformation matrix cannot be inverted");const x=e[0],o=e[1],u=e[2],i=e[3],f=e[4],s=e[5];return t[0]=i/n,t[1]=-o/n,t[2]=-u/n,t[3]=x/n,t[4]=(u*s-i*f)/n,t[5]=-(x*s-o*f)/n,t}function o(t,e,n=2){const r=e&&e.length,x=r?e[0]*n:t.length;let o=u(t,0,x,n,!0);const i=[];if(!o||o.next===o.prev)return i;let s,l,c;if(r&&(o=function(t,e,n,r){const x=[];for(let n=0,o=e.length;n80*n){s=1/0,l=1/0;let e=-1/0,r=-1/0;for(let o=n;oe&&(e=n),x>r&&(r=x)}c=Math.max(e-s,r-l),c=0!==c?32767/c:0}return f(o,i,n,s,l,c,0),i}function u(t,e,n,r,x){let o;if(x===function(t,e,n,r){let x=0;for(let o=e,u=n-r;o0)for(let x=e;x=e;x-=r)o=z(x/r|0,t[x],t[x+1],o);return o&&M(o,o.next)&&(F(o),o=o.next),o}function i(t,e){if(!t)return t;e||(e=t);let n,r=t;do{if(n=!1,r.steiner||!M(r,r.next)&&0!==d(r.prev,r,r.next))r=r.next;else{if(F(r),r=e=r.prev,r===r.next)break;n=!0}}while(n||r!==e);return e}function f(t,e,n,r,x,o,u){if(!t)return;!u&&o&&function(t,e,n,r){let x=t;do{0===x.z&&(x.z=v(x.x,x.y,e,n,r)),x.prevZ=x.prev,x.nextZ=x.next,x=x.next}while(x!==t);x.prevZ.nextZ=null,x.prevZ=null,function(t){let e,n=1;do{let r,x=t;t=null;let o=null;for(e=0;x;){e++;let u=x,i=0;for(let t=0;t0||f>0&&u;)0!==i&&(0===f||!u||x.z<=u.z)?(r=x,x=x.nextZ,i--):(r=u,u=u.nextZ,f--),o?o.nextZ=r:t=r,r.prevZ=o,o=r;x=u}o.nextZ=null,n*=2}while(e>1)}(x)}(t,r,x,o);let y=t;for(;t.prev!==t.next;){const h=t.prev,p=t.next;if(o?l(t,r,x,o):s(t))e.push(h.i,t.i,p.i),F(t),t=p.next,y=p.next;else if((t=p)===y){u?1===u?f(t=c(i(t),e),e,n,r,x,o,2):2===u&&a(t,e,n,r,x,o):f(i(t),e,n,r,x,o,1);break}}}function s(t){const e=t.prev,n=t,r=t.next;if(d(e,n,r)>=0)return!1;const x=e.x,o=n.x,u=r.x,i=e.y,f=n.y,s=r.y,l=xo?x>u?x:u:o>u?o:u,y=i>f?i>s?i:s:f>s?f:s;let h=r.next;for(;h!==e;){if(h.x>=l&&h.x<=a&&h.y>=c&&h.y<=y&&b(x,i,o,f,u,s,h.x,h.y)&&d(h.prev,h,h.next)>=0)return!1;h=h.next}return!0}function l(t,e,n,r){const x=t.prev,o=t,u=t.next;if(d(x,o,u)>=0)return!1;const i=x.x,f=o.x,s=u.x,l=x.y,c=o.y,a=u.y,y=if?i>s?i:s:f>s?f:s,g=l>c?l>a?l:a:c>a?c:a,Z=v(y,h,e,n,r),M=v(p,g,e,n,r);let w=t.prevZ,m=t.nextZ;for(;w&&w.z>=Z&&m&&m.z<=M;){if(w.x>=y&&w.x<=p&&w.y>=h&&w.y<=g&&w!==x&&w!==u&&b(i,l,f,c,s,a,w.x,w.y)&&d(w.prev,w,w.next)>=0)return!1;if(w=w.prevZ,m.x>=y&&m.x<=p&&m.y>=h&&m.y<=g&&m!==x&&m!==u&&b(i,l,f,c,s,a,m.x,m.y)&&d(m.prev,m,m.next)>=0)return!1;m=m.nextZ}for(;w&&w.z>=Z;){if(w.x>=y&&w.x<=p&&w.y>=h&&w.y<=g&&w!==x&&w!==u&&b(i,l,f,c,s,a,w.x,w.y)&&d(w.prev,w,w.next)>=0)return!1;w=w.prevZ}for(;m&&m.z<=M;){if(m.x>=y&&m.x<=p&&m.y>=h&&m.y<=g&&m!==x&&m!==u&&b(i,l,f,c,s,a,m.x,m.y)&&d(m.prev,m,m.next)>=0)return!1;m=m.nextZ}return!0}function c(t,e){let n=t;do{const r=n.prev,x=n.next.next;!M(r,x)&&w(r,n,n.next,x)&&E(r,x)&&E(x,r)&&(e.push(r.i,n.i,x.i),F(n),F(n.next),n=t=x),n=n.next}while(n!==t);return i(n)}function a(t,e,n,r,x,o){let u=t;do{let t=u.next.next;for(;t!==u.prev;){if(u.i!==t.i&&Z(u,t)){let s=I(u,t);return u=i(u,u.next),s=i(s,s.next),f(u,e,n,r,x,o,0),void f(s,e,n,r,x,o,0)}t=t.next}u=u.next}while(u!==t)}function y(t,e){return t.x-e.x}function h(t,e){const n=function(t,e){let n=e;const r=t.x,x=t.y;let o,u=-1/0;do{if(x<=n.y&&x>=n.next.y&&n.next.y!==n.y){const t=n.x+(x-n.y)*(n.next.x-n.x)/(n.next.y-n.y);if(t<=r&&t>u&&(u=t,o=n.x=n.x&&n.x>=f&&r!==n.x&&b(xo.x||n.x===o.x&&p(o,n)))&&(o=n,l=e)}n=n.next}while(n!==i);return o}(t,e);if(!n)return e;const r=I(n,t);return i(r,r.next),i(n,n.next)}function p(t,e){return d(t.prev,t,e.prev)<0&&d(e.next,t,t.next)<0}function v(t,e,n,r,x){return(t=1431655765&((t=858993459&((t=252645135&((t=16711935&((t=(t-n)*x|0)|t<<8))|t<<4))|t<<2))|t<<1))|(e=1431655765&((e=858993459&((e=252645135&((e=16711935&((e=(e-r)*x|0)|e<<8))|e<<4))|e<<2))|e<<1))<<1}function g(t){let e=t,n=t;do{(e.x=(t-u)*(o-i)&&(t-u)*(r-i)>=(n-u)*(e-i)&&(n-u)*(o-i)>=(x-u)*(r-i)}function Z(t,e){return t.next.i!==e.i&&t.prev.i!==e.i&&!function(t,e){let n=t;do{if(n.i!==t.i&&n.next.i!==t.i&&n.i!==e.i&&n.next.i!==e.i&&w(n,n.next,t,e))return!0;n=n.next}while(n!==t);return!1}(t,e)&&(E(t,e)&&E(e,t)&&function(t,e){let n=t,r=!1;const x=(t.x+e.x)/2,o=(t.y+e.y)/2;do{n.y>o!=n.next.y>o&&n.next.y!==n.y&&x<(n.next.x-n.x)*(o-n.y)/(n.next.y-n.y)+n.x&&(r=!r),n=n.next}while(n!==t);return r}(t,e)&&(d(t.prev,t,e.prev)||d(t,e.prev,e))||M(t,e)&&d(t.prev,t,t.next)>0&&d(e.prev,e,e.next)>0)}function d(t,e,n){return(e.y-t.y)*(n.x-e.x)-(e.x-t.x)*(n.y-e.y)}function M(t,e){return t.x===e.x&&t.y===e.y}function w(t,e,n,r){const x=A(d(t,e,n)),o=A(d(t,e,r)),u=A(d(n,r,t)),i=A(d(n,r,e));return x!==o&&u!==i||(!(0!==x||!m(t,n,e))||(!(0!==o||!m(t,r,e))||(!(0!==u||!m(n,t,r))||!(0!==i||!m(n,e,r)))))}function m(t,e,n){return e.x<=Math.max(t.x,n.x)&&e.x>=Math.min(t.x,n.x)&&e.y<=Math.max(t.y,n.y)&&e.y>=Math.min(t.y,n.y)}function A(t){return t>0?1:t<0?-1:0}function E(t,e){return d(t.prev,t,t.next)<0?d(t,e,t.next)>=0&&d(t,t.prev,e)>=0:d(t,e,t.prev)<0||d(t,t.next,e)<0}function I(t,e){const n=P(t.i,t.x,t.y),r=P(e.i,e.x,e.y),x=t.next,o=e.prev;return t.next=e,e.prev=t,n.next=x,x.prev=n,r.next=n,n.prev=r,o.next=r,r.prev=o,r}function z(t,e,n,r){const x=P(t,e,n);return r?(x.next=r.next,x.prev=r,r.next.prev=x,r.next=x):(x.prev=x,x.next=x),x}function F(t){t.next.prev=t.prev,t.prev.next=t.next,t.prevZ&&(t.prevZ.nextZ=t.nextZ),t.nextZ&&(t.nextZ.prevZ=t.prevZ)}function P(t,e,n){return{i:t,x:e,y:n,prev:null,next:null,z:0,prevZ:null,nextZ:null,steiner:!1}}new Array(6);const B=[],N={vertexPosition:0,indexPosition:0};function R(t,e,n,r,x){t[e+0]=n,t[e+1]=r,t[e+2]=x}function S(t,e,n,r,x,o){const u=3+x,i=t[e+0],f=t[e+1],s=B;s.length=x;for(let n=0;n0?f:2*Math.PI-f}let Z=-1,d=-1,M=c;const w=null!==o;if(null!==x){Z=b(v,g,r(s,[...[t[x],t[x+1]]])),Math.cos(Z)<=.985&&(M+=Math.tan((Z-Math.PI)/2))}if(w){d=b(g,v,r(s,[...[t[o],t[o+1]]])),Math.cos(d)<=.985&&(M+=Math.tan((Math.PI-d)/2))}function m(t,e){return 0===e?1e4*t:Math.sign(e)*(1e4*t+Math.abs(e))}return u.push(h[0],h[1],p[0],p[1],Z,d,l,m(0,c)),u.push(...f),u.push(h[0],h[1],p[0],p[1],Z,d,l,m(1,c)),u.push(...f),u.push(h[0],h[1],p[0],p[1],Z,d,l,m(2,c)),u.push(...f),u.push(h[0],h[1],p[0],p[1],Z,d,l,m(3,c)),u.push(...f),i.push(y,y+1,y+2,y+1,y+3,y+2),{length:l+Math.sqrt((g[0]-v[0])*(g[0]-v[0])+(g[1]-v[1])*(g[1]-v[1])),angle:M}}function _(t,e,n,r,x){const u=2+x;let i=e;const f=t.slice(i,i+x);i+=x;const s=t[i++];let l=0;const c=new Array(s-1);for(let e=0;e{const o=r.data;switch(o.type){case e:{const t=3,e=2,n=o.customAttributesSize,r=e+n,x=new Float32Array(o.renderInstructions),u=x.length/r,i=4*u*(n+t),f=new Uint32Array(6*u),s=new Float32Array(i);let l;for(let t=0;t0?h=i+(n-1)*r:c&&(h=o-r);let p=null;n"u"?"data:application/javascript;base64,"+Buffer.from(s,"binary").toString("base64"):URL.createObjectURL(new Blob([s],{type:"application/javascript"})))}function cK(s,t){const e=s.viewState.projection,i=t.getSource().getWrapX()&&e.canWrapX(),n=e.getExtent(),r=s.extent,o=i?Rt(n):null,a=i?Math.ceil((r[2]-n[2])/o)+1:1;return[i?Math.floor((r[0]-n[0])/o):0,a,o]}class uA extends o0{constructor(t,e){const i=e.uniforms||{},n=ss();i[Or.PROJECTION_MATRIX]=n,super(t,{uniforms:i,postProcesses:e.postProcesses}),this.sourceRevision_=-1,this.verticesBuffer_=new Wp(n0,hy),this.indicesBuffer_=new Wp(r0,hy),this.vertexShader_=e.vertexShader,this.fragmentShader_=e.fragmentShader,this.program_,this.hitDetectionEnabled_=e.hitDetectionEnabled??!0;const r=e.attributes?e.attributes.map(function(a){return{name:"a_prop_"+a.name,size:1,type:nr.FLOAT}}):[];this.attributes=[{name:"a_position",size:2,type:nr.FLOAT},{name:"a_index",size:1,type:nr.FLOAT}],this.hitDetectionEnabled_&&(this.attributes.push({name:"a_prop_hitColor",size:4,type:nr.FLOAT}),this.attributes.push({name:"a_featureUid",size:1,type:nr.FLOAT})),this.attributes.push(...r),this.customAttributes=e.attributes?e.attributes:[],this.previousExtent_=Zs(),this.currentTransform_=n,this.renderTransform_=ss(),this.invertRenderTransform_=ss(),this.renderInstructions_=new Float32Array(0),this.hitRenderTarget_,this.lastSentId=0,this.worker_=hK(),this.worker_.addEventListener("message",a=>{const l=a.data;if(l.type===RM.GENERATE_POINT_BUFFERS){const h=l.projectionTransform;this.verticesBuffer_.fromArrayBuffer(l.vertexBuffer),this.helper.flushBufferData(this.verticesBuffer_),this.indicesBuffer_.fromArrayBuffer(l.indexBuffer),this.helper.flushBufferData(this.indicesBuffer_),this.renderTransform_=h,hI(this.invertRenderTransform_,this.renderTransform_),this.renderInstructions_=new Float32Array(a.data.renderInstructions),l.id===this.lastSentId&&(this.ready=!0),this.getLayer().changed()}}),this.featureCache_={},this.featureCount_=0;const o=this.getLayer().getSource();this.sourceListenKeys_=[We(o,zs.ADDFEATURE,this.handleSourceFeatureAdded_,this),We(o,zs.CHANGEFEATURE,this.handleSourceFeatureChanged_,this),We(o,zs.REMOVEFEATURE,this.handleSourceFeatureDelete_,this),We(o,zs.CLEAR,this.handleSourceFeatureClear_,this)],o.forEachFeature(a=>{this.featureCache_[mt(a)]={feature:a,properties:a.getProperties(),geometry:a.getGeometry()},this.featureCount_++})}afterHelperCreated(){this.program_=this.helper.getProgram(this.fragmentShader_,this.vertexShader_),this.hitDetectionEnabled_&&(this.hitRenderTarget_=new oK(this.helper))}handleSourceFeatureAdded_(t){const e=t.feature;this.featureCache_[mt(e)]={feature:e,properties:e.getProperties(),geometry:e.getGeometry()},this.featureCount_++}handleSourceFeatureChanged_(t){const e=t.feature;this.featureCache_[mt(e)]={feature:e,properties:e.getProperties(),geometry:e.getGeometry()}}handleSourceFeatureDelete_(t){const e=t.feature;delete this.featureCache_[mt(e)],this.featureCount_--}handleSourceFeatureClear_(){this.featureCache_={},this.featureCount_=0}renderFrame(t){const e=this.helper.getGL();this.preRender(e,t);const[i,n,r]=cK(t,this.getLayer());return this.renderWorlds(t,!1,i,n,r),this.helper.finalizeDraw(t,this.dispatchPreComposeEvent,this.dispatchPostComposeEvent),this.hitDetectionEnabled_&&(this.renderWorlds(t,!0,i,n,r),this.hitRenderTarget_.clearCachedData()),this.postRender(e,t),this.helper.getCanvas()}prepareFrameInternal(t){const e=this.getLayer(),i=e.getSource(),n=t.viewState,r=!t.viewHints[Ie.ANIMATING]&&!t.viewHints[Ie.INTERACTING],o=!so(this.previousExtent_,t.extent),a=this.sourceRevision_t)throw new Error("Tile load sequence violation");this.state=t,this.changed()}load(){vt()}getAlpha(t,e){if(!this.transition_)return 1;let i=this.transitionStarts_[t];if(!i)i=e,this.transitionStarts_[t]=i;else if(i===-1)return 1;const n=e-i+1e3/60;return n>=this.transition_?1:jP(n/this.transition_)}inTransition(t){return this.transition_?this.transitionStarts_[t]!==-1:!1}endTransition(t){this.transition_&&(this.transitionStarts_[t]=-1)}}function uc(s){return s instanceof Image||s instanceof HTMLCanvasElement||s instanceof HTMLVideoElement||s instanceof ImageBitmap?s:null}function cy(s){return s instanceof Uint8Array||s instanceof Uint8ClampedArray||s instanceof Float32Array||s instanceof DataView?s:null}const dK=new Error("disposed");let $l=null;function gK(s){$l||($l=Se(s.width,s.height,void 0,{willReadFrequently:!0}));const t=$l.canvas,e=s.width;t.width!==e&&(t.width=e);const i=s.height;return t.height!==i&&(t.height=i),$l.clearRect(0,0,e,i),$l.drawImage(s,0,0),$l.getImageData(0,0,e,i).data}const fK=[256,256];class kd extends Oc{constructor(t){const e=X.IDLE;super(t.tileCoord,e,{transition:t.transition,interpolate:t.interpolate}),this.loader_=t.loader,this.data_=null,this.error_=null,this.size_=t.size||null,this.controller_=t.controller||null}getSize(){if(this.size_)return this.size_;const t=uc(this.data_);return t?[t.width,t.height]:fK}getData(){return this.data_}getError(){return this.error_}load(){if(this.state!==X.IDLE&&this.state!==X.ERROR)return;this.state=X.LOADING,this.changed();const t=this;this.loader_().then(function(e){t.data_=e,t.state=X.LOADED,t.changed()}).catch(function(e){t.error_=e,t.state=X.ERROR,t.changed()})}disposeInternal(){this.controller_&&(this.controller_.abort(dK),this.controller_=null),super.disposeInternal()}}const pK=10,PM=.25;class Hv{constructor(t,e,i,n,r,o){this.sourceProj_=t,this.targetProj_=e;let a={};const l=vr(this.targetProj_,this.sourceProj_);this.transformInv_=function(y){const v=y[0]+"/"+y[1];return a[v]||(a[v]=l(y)),a[v]},this.maxSourceExtent_=n,this.errorThresholdSquared_=r*r,this.triangles_=[],this.wrapsXInSource_=!1,this.canWrapXInSource_=this.sourceProj_.canWrapX()&&!!n&&!!this.sourceProj_.getExtent()&&Rt(n)>=Rt(this.sourceProj_.getExtent()),this.sourceWorldWidth_=this.sourceProj_.getExtent()?Rt(this.sourceProj_.getExtent()):null,this.targetWorldWidth_=this.targetProj_.getExtent()?Rt(this.targetProj_.getExtent()):null;const h=fo(i),c=yg(i),u=Nm(i),d=_g(i),g=this.transformInv_(h),f=this.transformInv_(c),p=this.transformInv_(u),m=this.transformInv_(d),_=pK+(o?Math.max(0,Math.ceil(Math.log2(Td(i)/(o*o*256*256)))):0);if(this.addQuad_(h,c,u,d,g,f,p,m,_),this.wrapsXInSource_){let y=1/0;this.triangles_.forEach(function(v,S,w){y=Math.min(y,v.source[0][0],v.source[1][0],v.source[2][0])}),this.triangles_.forEach(v=>{if(Math.max(v.source[0][0],v.source[1][0],v.source[2][0])-y>this.sourceWorldWidth_/2){const S=[[v.source[0][0],v.source[0][1]],[v.source[1][0],v.source[1][1]],[v.source[2][0],v.source[2][1]]];S[0][0]-y>this.sourceWorldWidth_/2&&(S[0][0]-=this.sourceWorldWidth_),S[1][0]-y>this.sourceWorldWidth_/2&&(S[1][0]-=this.sourceWorldWidth_),S[2][0]-y>this.sourceWorldWidth_/2&&(S[2][0]-=this.sourceWorldWidth_);const w=Math.min(S[0][0],S[1][0],S[2][0]);Math.max(S[0][0],S[1][0],S[2][0])-w.5&&u<1;let f=!1;if(h>0){if(this.targetProj_.isGlobal()&&this.targetWorldWidth_){const m=ic([t,e,i,n]);f=Rt(m)/this.targetWorldWidth_>PM||f}!g&&this.sourceProj_.isGlobal()&&u&&(f=u>PM||f)}if(!f&&this.maxSourceExtent_&&isFinite(c[0])&&isFinite(c[1])&&isFinite(c[2])&&isFinite(c[3])&&!Te(c,this.maxSourceExtent_))return;let p=0;if(!f&&(!isFinite(r[0])||!isFinite(r[1])||!isFinite(o[0])||!isFinite(o[1])||!isFinite(a[0])||!isFinite(a[1])||!isFinite(l[0])||!isFinite(l[1]))){if(h>0)f=!0;else if(p=(!isFinite(r[0])||!isFinite(r[1])?8:0)+(!isFinite(o[0])||!isFinite(o[1])?4:0)+(!isFinite(a[0])||!isFinite(a[1])?2:0)+(!isFinite(l[0])||!isFinite(l[1])?1:0),p!=1&&p!=2&&p!=4&&p!=8)return}if(h>0){if(!f){const m=[(t[0]+i[0])/2,(t[1]+i[1])/2],_=this.transformInv_(m);let y;g?y=(kn(r[0],d)+kn(a[0],d))/2-kn(_[0],d):y=(r[0]+a[0])/2-_[0];const v=(r[1]+a[1])/2-_[1];f=y*y+v*v>this.errorThresholdSquared_}if(f){if(Math.abs(t[0]-i[0])<=Math.abs(t[1]-i[1])){const m=[(e[0]+i[0])/2,(e[1]+i[1])/2],_=this.transformInv_(m),y=[(n[0]+t[0])/2,(n[1]+t[1])/2],v=this.transformInv_(y);this.addQuad_(t,e,m,y,r,o,_,v,h-1),this.addQuad_(y,m,i,n,v,_,a,l,h-1)}else{const m=[(t[0]+e[0])/2,(t[1]+e[1])/2],_=this.transformInv_(m),y=[(i[0]+n[0])/2,(i[1]+n[1])/2],v=this.transformInv_(y);this.addQuad_(t,m,y,n,r,_,v,l,h-1),this.addQuad_(m,e,i,y,_,o,a,v,h-1)}return}}if(g){if(!this.canWrapXInSource_)return;this.wrapsXInSource_=!0}p&11||this.addTriangle_(t,i,n,r,a,l),p&14||this.addTriangle_(t,i,e,r,a,o),p&&(p&13||this.addTriangle_(e,n,t,o,l,r),p&7||this.addTriangle_(e,n,i,o,l,a))}calculateSourceExtent(){const t=Zs();return this.triangles_.forEach(function(e,i,n){const r=e.source;Wu(t,r[0]),Wu(t,r[1]),Wu(t,r[2])}),t}getTriangles(){return this.triangles_}}let D_;const Jr=[];function AM(s,t,e,i,n){s.beginPath(),s.moveTo(0,0),s.lineTo(t,e),s.lineTo(i,n),s.closePath(),s.save(),s.clip(),s.fillRect(0,0,Math.max(t,i)+1,Math.max(e,n)),s.restore()}function k_(s,t){return Math.abs(s[t*4]-210)>2||Math.abs(s[t*4+3]-.75*255)>2}function mK(){if(D_===void 0){const s=Se(6,6,Jr);s.globalCompositeOperation="lighter",s.fillStyle="rgba(210, 0, 0, 0.75)",AM(s,4,5,4,0),AM(s,4,5,0,5);const t=s.getImageData(0,0,3,3).data;D_=k_(t,0)||k_(t,4)||k_(t,8),ol(s),Jr.push(s.canvas)}return D_}function $d(s,t,e,i){const n=Dm(e,t,s);let r=a2(t,i,e);const o=t.getMetersPerUnit();o!==void 0&&(r*=o);const a=s.getMetersPerUnit();a!==void 0&&(r/=a);const l=s.getExtent();if(!l||Yi(l,n)){const h=a2(s,r,n)/r;isFinite(h)&&h>0&&(r/=h)}return r}function dA(s,t,e,i){const n=Rs(e);let r=$d(s,t,n,i);return(!isFinite(r)||r<=0)&&dI(e,function(o){return r=$d(s,t,o,i),isFinite(r)&&r>0}),r}function Kv(s,t,e,i,n,r,o,a,l,h,c,u,d,g){const f=Se(Math.round(e*s),Math.round(e*t),Jr);if(u||(f.imageSmoothingEnabled=!1),l.length===0)return f.canvas;f.scale(e,e);function p(w){return Math.round(w*e)/e}f.globalCompositeOperation="lighter";const m=Zs();l.forEach(function(w,T,M){cI(m,w.extent)});let _;const y=e/i,v=(u?1:1+Math.pow(2,-24))/y;if(!d||l.length!==1||h!==0){if(_=Se(Math.round(Rt(m)*y),Math.round(Ee(m)*y),Jr),u||(_.imageSmoothingEnabled=!1),n&&g){const w=(n[0]-m[0])*y,T=-(n[3]-m[3])*y,M=Rt(n)*y,C=Ee(n)*y;_.rect(w,T,M,C),_.clip()}l.forEach(function(w,T,M){if(w.image.width>0&&w.image.height>0){if(w.clipExtent){_.save();const D=(w.clipExtent[0]-m[0])*y,x=-(w.clipExtent[3]-m[3])*y,E=Rt(w.clipExtent)*y,b=Ee(w.clipExtent)*y;_.rect(u?D:Math.round(D),u?x:Math.round(x),u?E:Math.round(D+E)-Math.round(D),u?b:Math.round(x+b)-Math.round(x)),_.clip()}const C=(w.extent[0]-m[0])*y,I=-(w.extent[3]-m[3])*y,O=Rt(w.extent)*y,P=Ee(w.extent)*y;_.drawImage(w.image,h,h,w.image.width-2*h,w.image.height-2*h,u?C:Math.round(C),u?I:Math.round(I),u?O:Math.round(C+O)-Math.round(C),u?P:Math.round(I+P)-Math.round(I)),w.clipExtent&&_.restore()}})}const S=fo(o);return a.getTriangles().forEach(function(w,T,M){const C=w.source,I=w.target;let O=C[0][0],P=C[0][1],D=C[1][0],x=C[1][1],E=C[2][0],b=C[2][1];const R=p((I[0][0]-S[0])/r),A=p(-(I[0][1]-S[1])/r),$=p((I[1][0]-S[0])/r),G=p(-(I[1][1]-S[1])/r),k=p((I[2][0]-S[0])/r),z=p(-(I[2][1]-S[1])/r),V=O,et=P;O=0,P=0,D-=V,x-=et,E-=V,b-=et;const F=[[D,x,0,0,$-R],[E,b,0,0,k-R],[0,0,D,x,G-A],[0,0,E,b,z-A]],ot=E9(F);if(!ot)return;if(f.save(),f.beginPath(),mK()||!u){f.moveTo($,G);const pt=4,Gt=R-$,Kt=A-G;for(let bt=0;btPromise.resolve(new Uint8ClampedArray(4)),interpolate:t.interpolate,transition:t.transition}),this.pixelRatio_=t.pixelRatio,this.gutter_=t.gutter,this.reprojData_=null,this.reprojError_=null,this.reprojSize_=void 0,this.sourceTileGrid_=t.sourceTileGrid,this.targetTileGrid_=t.targetTileGrid,this.wrappedTileCoord_=t.wrappedTileCoord||t.tileCoord,this.sourceTiles_=[],this.sourcesListenerKeys_=null,this.sourceZ_=0;const e=t.sourceProj,i=e.getExtent(),n=t.sourceTileGrid.getExtent();this.clipExtent_=e.canWrapX()?n?He(i,n):i:n;const r=this.targetTileGrid_.getTileCoordExtent(this.wrappedTileCoord_),o=this.targetTileGrid_.getExtent();let a=this.sourceTileGrid_.getExtent();const l=o?He(r,o):r;if(Td(l)===0){this.state=X.EMPTY;return}i&&(a?a=He(a,i):a=i);const h=this.targetTileGrid_.getResolution(this.wrappedTileCoord_[0]),c=t.targetProj,u=dA(e,c,l,h);if(!isFinite(u)||u<=0){this.state=X.EMPTY;return}const d=t.errorThreshold!==void 0?t.errorThreshold:Zv;if(this.triangulation_=new Hv(e,c,l,a,u*d,h),this.triangulation_.getTriangles().length===0){this.state=X.EMPTY;return}this.sourceZ_=this.sourceTileGrid_.getZForResolution(u);let g=this.triangulation_.calculateSourceExtent();if(a&&(e.canWrapX()?(g[1]=Dt(g[1],a[1],a[3]),g[3]=Dt(g[3],a[1],a[3])):g=He(g,a)),!Td(g))this.state=X.EMPTY;else{let f=0,p=0;e.canWrapX()&&(f=Rt(i),p=Math.floor((g[0]-i[0])/f)),Hx(g.slice(),e,!0).forEach(m=>{const _=this.sourceTileGrid_.getTileRangeForExtentAndZ(m,this.sourceZ_),y=t.getTileFunction;for(let v=_.minX;v<=_.maxX;v++)for(let S=_.minY;S<=_.maxY;S++){const w=y(this.sourceZ_,v,S,this.pixelRatio_);if(w){const T=p*f;this.sourceTiles_.push({tile:w,offset:T})}}++p}),this.sourceTiles_.length===0&&(this.state=X.EMPTY)}}getSize(){return this.reprojSize_}getData(){return this.reprojData_}getError(){return this.reprojError_}reproject_(){const t=[];let e=!1;if(this.sourceTiles_.forEach(f=>{var p;const m=f.tile;if(!m||m.getState()!==X.LOADED)return;const _=m.getSize(),y=this.gutter_;let v;const S=cy(m.getData());S?v=S:(e=!0,v=gK(uc(m.getData())));const w=[_[0]+2*y,_[1]+2*y],T=v instanceof Float32Array,M=w[0]*w[1],C=T?Float32Array:Uint8ClampedArray,I=new C(v.buffer),O=C.BYTES_PER_ELEMENT,P=O*I.length/M,D=I.byteLength/w[1],x=Math.floor(D/O/w[0]),E=M*x;let b=I;if(I.length!==E){b=new C(E);let $=0,G=0;const k=w[0]*x;for(let z=0;z=0;--f){const p=[];for(let w=0,T=t.length;w{const i=e.getState();if(i!==X.IDLE&&i!==X.LOADING)return;t++;const n=We(e,Zt.CHANGE,()=>{const r=e.getState();(r==X.LOADED||r==X.ERROR||r==X.EMPTY)&&(ms(n),t--,t===0&&(this.unlistenSources_(),this.reproject_()))});this.sourcesListenerKeys_.push(n)}),t===0?setTimeout(this.reproject_.bind(this),0):this.sourceTiles_.forEach(function({tile:e}){e.getState()==X.IDLE&&e.load()})}unlistenSources_(){this.sourcesListenerKeys_.forEach(ms),this.sourcesListenerKeys_=null}}class Ag extends Oc{constructor(t,e,i,n,r,o,a,l,h,c,u,d){super(r,X.IDLE,d),this.renderEdges_=u!==void 0?u:!1,this.pixelRatio_=a,this.gutter_=l,this.canvas_=null,this.sourceTileGrid_=e,this.targetTileGrid_=n,this.wrappedTileCoord_=o||r,this.sourceTiles_=[],this.sourcesListenerKeys_=null,this.sourceZ_=0,this.clipExtent_=t.canWrapX()?t.getExtent():void 0;const g=n.getTileCoordExtent(this.wrappedTileCoord_),f=this.targetTileGrid_.getExtent();let p=this.sourceTileGrid_.getExtent();const m=f?He(g,f):g;if(Td(m)===0){this.state=X.EMPTY;return}const _=t.getExtent();_&&(p?p=He(p,_):p=_);const y=n.getResolution(this.wrappedTileCoord_[0]),v=dA(t,i,m,y);if(!isFinite(v)||v<=0){this.state=X.EMPTY;return}const S=c!==void 0?c:Zv;if(this.triangulation_=new Hv(t,i,m,p,v*S,y),this.triangulation_.getTriangles().length===0){this.state=X.EMPTY;return}this.sourceZ_=e.getZForResolution(v);let w=this.triangulation_.calculateSourceExtent();if(p&&(t.canWrapX()?(w[1]=Dt(w[1],p[1],p[3]),w[3]=Dt(w[3],p[1],p[3])):w=He(w,p)),!Td(w))this.state=X.EMPTY;else{let T=0,M=0;t.canWrapX()&&(T=Rt(_),M=Math.floor((w[0]-_[0])/T)),Hx(w.slice(),t,!0).forEach(C=>{const I=e.getTileRangeForExtentAndZ(C,this.sourceZ_);for(let O=I.minX;O<=I.maxX;O++)for(let P=I.minY;P<=I.maxY;P++){const D=h(this.sourceZ_,O,P,a);if(D){const x=M*T;this.sourceTiles_.push({tile:D,offset:x})}}++M}),this.sourceTiles_.length===0&&(this.state=X.EMPTY)}}getImage(){return this.canvas_}reproject_(){const t=[];if(this.sourceTiles_.forEach(e=>{var i;const n=e.tile;if(n&&n.getState()==X.LOADED){const r=this.sourceTileGrid_.getTileCoordExtent(n.tileCoord);r[0]+=e.offset,r[2]+=e.offset;const o=(i=this.clipExtent_)==null?void 0:i.slice();o&&(o[0]+=e.offset,o[2]+=e.offset),t.push({extent:r,clipExtent:o,image:n.getImage()})}}),this.sourceTiles_.length=0,t.length===0)this.state=X.ERROR;else{const e=this.wrappedTileCoord_[0],i=this.targetTileGrid_.getTileSize(e),n=typeof i=="number"?i:i[0],r=typeof i=="number"?i:i[1],o=this.targetTileGrid_.getResolution(e),a=this.sourceTileGrid_.getResolution(this.sourceZ_),l=this.targetTileGrid_.getTileCoordExtent(this.wrappedTileCoord_);this.canvas_=Kv(n,r,this.pixelRatio_,a,this.sourceTileGrid_.getExtent(),o,l,this.triangulation_,t,this.gutter_,this.renderEdges_,this.interpolate),this.state=X.LOADED}this.changed()}load(){if(this.state==X.IDLE){this.state=X.LOADING,this.changed();let t=0;this.sourcesListenerKeys_=[],this.sourceTiles_.forEach(({tile:e})=>{const i=e.getState();if(i==X.IDLE||i==X.LOADING){t++;const n=We(e,Zt.CHANGE,r=>{const o=e.getState();(o==X.LOADED||o==X.ERROR||o==X.EMPTY)&&(ms(n),t--,t===0&&(this.unlistenSources_(),this.reproject_()))});this.sourcesListenerKeys_.push(n)}}),t===0?setTimeout(this.reproject_.bind(this),0):this.sourceTiles_.forEach(function({tile:e},i,n){e.getState()==X.IDLE&&e.load()})}}unlistenSources_(){this.sourcesListenerKeys_.forEach(ms),this.sourcesListenerKeys_=null}release(){this.canvas_&&(ol(this.canvas_.getContext("2d")),Jr.push(this.canvas_),this.canvas_=null),super.release()}}class Lg extends Oc{constructor(t,e,i,n,r,o){super(t,e,o),this.crossOrigin_=n,this.src_=i,this.key=i,this.image_=new Image,n!==null&&(this.image_.crossOrigin=n),this.unlisten_=null,this.tileLoadFunction_=r}getImage(){return this.image_}setImage(t){this.image_=t,this.state=X.LOADED,this.unlistenImage_(),this.changed()}handleImageError_(){this.state=X.ERROR,this.unlistenImage_(),this.image_=_K(),this.changed()}handleImageLoad_(){const t=this.image_;t.naturalWidth&&t.naturalHeight?this.state=X.LOADED:this.state=X.EMPTY,this.unlistenImage_(),this.changed()}load(){this.state==X.ERROR&&(this.state=X.IDLE,this.image_=new Image,this.crossOrigin_!==null&&(this.image_.crossOrigin=this.crossOrigin_)),this.state==X.IDLE&&(this.state=X.LOADING,this.changed(),this.tileLoadFunction_(this,this.src_),this.unlisten_=KB(this.image_,this.handleImageLoad_.bind(this),this.handleImageError_.bind(this)))}unlistenImage_(){this.unlisten_&&(this.unlisten_(),this.unlisten_=null)}}function _K(){const s=Se(1,1);return s.fillStyle="rgba(0,0,0,0)",s.fillRect(0,0,1,1),s.canvas}class yK extends fg{constructor(t){super(),this.tile,this.handleTileChange_=this.handleTileChange_.bind(this),this.gutter=t.gutter||0,this.helper=t.helper,this.loaded=!1,this.ready=!1}setTile(t){if(t!==this.tile)if(this.tile&&this.tile.removeEventListener(Zt.CHANGE,this.handleTileChange_),this.tile=t,this.loaded=t.getState()===X.LOADED,this.loaded)this.uploadTile();else{if(t instanceof Lg){const e=t.getImage();e instanceof Image&&!e.crossOrigin&&(e.crossOrigin="anonymous")}t.addEventListener(Zt.CHANGE,this.handleTileChange_)}}uploadTile(){vt()}setReady(){this.ready=!0,this.dispatchEvent(Zt.CHANGE)}handleTileChange_(){this.tile.getState()===X.LOADED&&(this.loaded=!0,this.uploadTile())}disposeInternal(){this.tile.removeEventListener(Zt.CHANGE,this.handleTileChange_)}}function gA(s,t,e){const i=e?s.LINEAR:s.NEAREST;s.bindTexture(s.TEXTURE_2D,t),s.texParameteri(s.TEXTURE_2D,s.TEXTURE_WRAP_S,s.CLAMP_TO_EDGE),s.texParameteri(s.TEXTURE_2D,s.TEXTURE_WRAP_T,s.CLAMP_TO_EDGE),s.texParameteri(s.TEXTURE_2D,s.TEXTURE_MIN_FILTER,i),s.texParameteri(s.TEXTURE_2D,s.TEXTURE_MAG_FILTER,i)}function xK(s,t,e,i){gA(s,t,i),s.texImage2D(s.TEXTURE_2D,0,s.RGBA,s.RGBA,s.UNSIGNED_BYTE,e)}function LM(s,t,e,i,n,r){const o=s.getGL();let a,l;e instanceof Float32Array?(a=o.FLOAT,s.getExtension("OES_texture_float"),l=s.getExtension("OES_texture_float_linear")!==null):(a=o.UNSIGNED_BYTE,l=!0),gA(o,t,r&&l);const h=e.byteLength/i[1];let c=1;h%8===0?c=8:h%4===0?c=4:h%2===0&&(c=2);let u;switch(n){case 1:{u=o.LUMINANCE;break}case 2:{u=o.LUMINANCE_ALPHA;break}case 3:{u=o.RGB;break}case 4:{u=o.RGBA;break}default:throw new Error(`Unsupported number of bands: ${n}`)}const d=o.getParameter(o.UNPACK_ALIGNMENT);o.pixelStorei(o.UNPACK_ALIGNMENT,c),o.texImage2D(o.TEXTURE_2D,0,u,i[0],i[1],0,u,a,e),o.pixelStorei(o.UNPACK_ALIGNMENT,d)}let Ql=null;function vK(){Ql=Se(1,1,void 0,{willReadFrequently:!0})}class wK extends yK{constructor(t){super(t),this.textures=[],this.renderSize_=Re(t.grid.getTileSize(t.tile.tileCoord[0])),this.bandCount=NaN;const e=new Wp(n0,qv);e.fromArray([0,1,1,1,1,0,0,0]),this.helper.flushBufferData(e),this.coords=e,this.setTile(t.tile)}uploadTile(){const t=this.helper,e=t.getGL(),i=this.tile;this.textures.length=0;let n;i instanceof Lg||i instanceof Ag?n=i.getImage():n=i.getData();const r=uc(n);if(r){const y=e.createTexture();this.textures.push(y),this.bandCount=4,xK(e,y,r,i.interpolate),this.setReady();return}n=cy(n);const o=i.getSize(),a=[o[0]+2*this.gutter,o[1]+2*this.gutter],l=n instanceof Float32Array,h=a[0]*a[1],c=l?Float32Array:Uint8Array,u=c.BYTES_PER_ELEMENT,d=n.byteLength/a[1];this.bandCount=Math.floor(d/u/a[0]);const g=Math.ceil(this.bandCount/4);if(g===1){const y=e.createTexture();this.textures.push(y),LM(t,y,n,a,this.bandCount,i.interpolate),this.setReady();return}const f=new Array(g);for(let y=0;y0&&this.getCount()>this.highWaterMark}expireCache(t){for(;this.canExpireCache();)this.pop()}clear(){this.count_=0,this.entries_={},this.oldest_=null,this.newest_=null}containsKey(t){return this.entries_.hasOwnProperty(t)}forEach(t){let e=this.oldest_;for(;e;)t(e.value_,e.key_,this),e=e.newer}get(t,e){const i=this.entries_[t];return qt(i!==void 0,"Tried to get a value for a key that does not exist in the cache"),i===this.newest_||(i===this.oldest_?(this.oldest_=this.oldest_.newer,this.oldest_.older=null):(i.newer.older=i.older,i.older.newer=i.newer),i.newer=null,i.older=this.newest_,this.newest_.newer=i,this.newest_=i),i.value_}remove(t){const e=this.entries_[t];return qt(e!==void 0,"Tried to get a value for a key that does not exist in the cache"),e===this.newest_?(this.newest_=e.older,this.newest_&&(this.newest_.newer=null)):e===this.oldest_?(this.oldest_=e.newer,this.oldest_&&(this.oldest_.older=null)):(e.newer.older=e.older,e.older.newer=e.newer),delete this.entries_[t],--this.count_,e.value_}getCount(){return this.count_}getKeys(){const t=new Array(this.count_);let e=0,i;for(i=this.newest_;i;i=i.older)t[e++]=i.key_;return t}getValues(){const t=new Array(this.count_);let e=0,i;for(i=this.newest_;i;i=i.older)t[e++]=i.value_;return t}peekLast(){return this.oldest_.value_}peekLastKey(){return this.oldest_.key_}peekFirstKey(){return this.newest_.key_}peek(t){var e;return(e=this.entries_[t])==null?void 0:e.value_}pop(){const t=this.oldest_;return delete this.entries_[t.key_],t.newer&&(t.newer.older=null),this.oldest_=t.newer,this.oldest_||(this.newest_=null),--this.count_,t.value_}replace(t,e){this.get(t),this.entries_[t].value_=e}set(t,e){qt(!(t in this.entries_),"Tried to set a value for a key that is used already");const i={key_:t,newer:null,older:this.newest_,value_:e};this.newest_?this.newest_.newer=i:this.oldest_=i,this.newest_=i,this.entries_[t]=i,++this.count_}setSize(t){this.highWaterMark=t}}class h0{constructor(t,e,i,n){this.minX=t,this.maxX=e,this.minY=i,this.maxY=n}contains(t){return this.containsXY(t[1],t[2])}containsTileRange(t){return this.minX<=t.minX&&t.maxX<=this.maxX&&this.minY<=t.minY&&t.maxY<=this.maxY}containsXY(t,e){return this.minX<=t&&t<=this.maxX&&this.minY<=e&&e<=this.maxY}equals(t){return this.minX==t.minX&&this.minY==t.minY&&this.maxX==t.maxX&&this.maxY==t.maxY}extend(t){t.minXthis.maxX&&(this.maxX=t.maxX),t.minYthis.maxY&&(this.maxY=t.maxY)}getHeight(){return this.maxY-this.minY+1}getSize(){return[this.getWidth(),this.getHeight()]}getWidth(){return this.maxX-this.minX+1}intersects(t){return this.minX<=t.maxX&&this.maxX>=t.minX&&this.minY<=t.maxY&&this.maxY>=t.minY}}function Gl(s,t,e,i,n){return n!==void 0?(n.minX=s,n.maxX=t,n.minY=e,n.maxY=i,n):new h0(s,t,e,i)}function ll(s,t,e,i){return i!==void 0?(i[0]=s,i[1]=t,i[2]=e,i):[s,t,e]}function ro(s,t,e){return s+"/"+t+"/"+e}function Do(s){return ro(s[0],s[1],s[2])}function EK(s){const[t,e,i]=s.substring(s.lastIndexOf("/")+1,s.length).split(",").map(Number);return ro(t,e,i)}function SK(s){return s.split("/").map(Number)}function Jv(s){return fA(s[0],s[1],s[2])}function fA(s,t,e){return(t<e||e>t.getMaxZoom())return!1;const r=t.getFullTileRange(e);return r?r.containsXY(i,n):!0}const bK={TILE_TRANSFORM:"u_tileTransform",TRANSITION_ALPHA:"u_transitionAlpha",DEPTH:"u_depth",RENDER_EXTENT:"u_renderExtent",PATTERN_ORIGIN:"u_patternOrigin",RESOLUTION:"u_resolution",ZOOM:"u_zoom",GLOBAL_ALPHA:"u_globalAlpha",PROJECTION_MATRIX:"u_projectionMatrix",SCREEN_TO_WORLD_MATRIX:"u_screenToWorldMatrix"},TK={};function OM(s){return 1/(s+2)}function CK(){return{tileIds:new Set,representationsByZ:{}}}function FM(s,t){return s.tileIds.has(mt(t))}function NM(s,t,e){const i=s.representationsByZ;e in i||(i[e]=new Set),i[e].add(t),s.tileIds.add(mt(t.tile))}function $_(s,t){const e=s.layerStatesArray[s.layerIndex];e.extent&&(t=He(t,cn(e.extent,s.viewState.projection)));const i=e.layer.getRenderSource();if(!i.getWrapX()){const n=i.getTileGridForProjection(s.viewState.projection).getExtent();n&&(t=He(t,n))}return t}function uy(s,t){return`${s.getKey()},${Do(t)}`}class RK extends o0{constructor(t,e){super(t,{uniforms:e.uniforms,postProcesses:e.postProcesses}),this.renderComplete=!1,this.tileTransform_=ss(),this.tempMat4=lA(),this.tempTileRange_=new h0(0,0,0,0),this.tempTileCoord_=ll(0,0,0),this.tempSize_=[0,0];const i=e.cacheSize!==void 0?e.cacheSize:512;this.tileRepresentationCache=new l0(i),this.frameState=null,this.projection_=void 0}reset(t){super.reset({uniforms:t.uniforms})}prepareFrameInternal(t){this.projection_?t.viewState.projection!==this.projection_&&(this.clearCache(),this.projection_=t.viewState.projection):this.projection_=t.viewState.projection;const e=this.getLayer().getRenderSource();return!e||po($_(t,t.extent))?!1:e.getState()==="ready"}createTileRepresentation(t){return vt()}enqueueTiles(t,e,i,n,r){const o=t.viewState,a=this.getLayer(),l=a.getRenderSource(),h=l.getTileGridForProjection(o.projection),c=l.getGutterForProjection(o.projection),u=mt(l);u in t.wantedTiles||(t.wantedTiles[u]={});const d=t.wantedTiles[u],g=this.tileRepresentationCache,f=a.getMapInternal(),p=Math.max(i-r,h.getMinZoom(),h.getZForResolution(Math.min(a.getMaxResolution(),f?f.getView().getResolutionForZoom(Math.max(a.getMinZoom(),0)):h.getResolution(0)),l.zDirection));for(let m=i;m>=p;--m){const _=h.getTileRangeForExtentAndZ(e,m,this.tempTileRange_),y=h.getResolution(m);for(let v=_.minX;v<=_.maxX;++v)for(let S=_.minY;S<=_.maxY;++S){const w=ll(m,v,S,this.tempTileCoord_),T=uy(l,w);let M,C;if(g.containsKey(T)&&(M=g.get(T),C=M.tile),(!M||M.tile.key!==l.getKey())&&(C=l.getTile(m,v,S,t.pixelRatio,o.projection),!C)||FM(n,C))continue;M?M.setTile(C):(M=this.createTileRepresentation({tile:C,grid:h,helper:this.helper,gutter:c}),g.set(T,M)),NM(n,M,m);const I=C.getKey();d[I]=!0,C.getState()===X.IDLE&&(t.tileQueue.isKeyQueued(I)||t.tileQueue.enqueue([C,u,h.getTileCoordCenter(w),y]))}}}beforeTilesRender(t,e){this.helper.prepareDraw(this.frameState,!e,!0)}beforeTilesMaskRender(t){return!1}renderTile(t,e,i,n,r,o,a,l,h,c,u){}renderTileMask(t,e,i,n){}drawTile_(t,e,i,n,r,o,a){if(!e.ready)return;const l=e.tile.tileCoord,h=Do(l),c=h in o?o[h]:1,u=a.getResolution(i),d=Re(a.getTileSize(i),this.tempSize_),g=a.getOrigin(i),f=a.getTileCoordExtent(l),p=c<1?-1:OM(i);c<1&&(t.animate=!0);const m=t.viewState,_=m.center[0],y=m.center[1],v=d[0]+2*n,S=d[1]+2*n,w=v/S,T=(_-g[0])/(d[0]*u),M=(g[1]-y)/(d[1]*u),C=m.resolution/u,I=l[1],O=l[2];j1(this.tileTransform_),Bu(this.tileTransform_,2/(t.size[0]*C/v),-2/(t.size[1]*C/v)),s9(this.tileTransform_,m.rotation),Bu(this.tileTransform_,1,1/w),Wx(this.tileTransform_,(d[0]*(I-T)-n)/v,(d[1]*(O-M)-n)/S),this.renderTile(e,this.tileTransform_,t,r,u,d,g,f,p,n,c)}renderFrame(t){this.frameState=t,this.renderComplete=!0;const e=this.helper.getGL();this.preRender(e,t);const i=t.viewState,n=this.getLayer(),r=n.getRenderSource(),o=r.getTileGridForProjection(i.projection),a=r.getGutterForProjection(i.projection),l=$_(t,t.extent),h=o.getZForResolution(i.resolution,r.zDirection),c=CK(),u=n.getPreload();if(t.nextExtent){const w=o.getZForResolution(i.nextResolution,r.zDirection),T=$_(t,t.nextExtent);this.enqueueTiles(t,T,w,c,u)}this.enqueueTiles(t,l,h,c,0),u>0&&setTimeout(()=>{this.enqueueTiles(t,l,h-1,c,u-1)},0);const d={},g=mt(this),f=t.time;let p=!1;const m=c.representationsByZ;if(h in m)for(const w of m[h]){const T=w.tile;if((T instanceof Ag||T instanceof a0)&&T.getState()===X.EMPTY)continue;const M=T.tileCoord;if(w.ready){const I=T.getAlpha(g,f);if(I===1){T.endTransition(g);continue}p=!0;const O=Do(M);d[O]=I}if(this.renderComplete=!1,this.findAltTiles_(o,M,h+1,c))continue;const C=o.getMinZoom();for(let I=h-1;I>=C&&!this.findAltTiles_(o,M,I,c);--I);}const _=Object.keys(m).map(Number).sort(qU);if(this.beforeTilesMaskRender(t))for(let w=0,T=_.length;we.dispose()),t.clear()}removeHelper(){this.helper&&this.clearCache(),super.removeHelper()}disposeInternal(){super.disposeInternal(),delete this.frameState}}const jt={...bK,TILE_TEXTURE_ARRAY:"u_tileTextures",TEXTURE_PIXEL_WIDTH:"u_texturePixelWidth",TEXTURE_PIXEL_HEIGHT:"u_texturePixelHeight",TEXTURE_RESOLUTION:"u_textureResolution",TEXTURE_ORIGIN_X:"u_textureOriginX",TEXTURE_ORIGIN_Y:"u_textureOriginY"},Gf={TEXTURE_COORD:"a_textureCoord"},IK=[{name:Gf.TEXTURE_COORD,size:2,type:nr.FLOAT}];class PK extends RK{constructor(t,e){super(t,e),this.program_,this.vertexShader_=e.vertexShader,this.fragmentShader_=e.fragmentShader,this.indices_=new Wp(r0,qv),this.indices_.fromArray([0,1,3,1,2,3]),this.paletteTextures_=e.paletteTextures||[]}reset(t){if(super.reset(t),this.helper){const e=this.helper.getGL();for(const i of this.paletteTextures_)i.delete(e)}this.vertexShader_=t.vertexShader,this.fragmentShader_=t.fragmentShader,this.paletteTextures_=t.paletteTextures||[],this.helper&&(this.program_=this.helper.getProgram(this.fragmentShader_,this.vertexShader_))}afterHelperCreated(){this.program_=this.helper.getProgram(this.fragmentShader_,this.vertexShader_),this.helper.flushBufferData(this.indices_)}removeHelper(){if(this.helper){const t=this.helper.getGL();for(const e of this.paletteTextures_)e.delete(t)}super.removeHelper()}createTileRepresentation(t){return new wK(t)}beforeTilesRender(t,e){super.beforeTilesRender(t,e),this.helper.useProgram(this.program_,t)}renderTile(t,e,i,n,r,o,a,l,h,c,u){const d=this.helper.getGL();this.helper.bindBuffer(t.coords),this.helper.bindBuffer(this.indices_),this.helper.enableAttributes(IK);let g=0;for(;g0&&(S=l,He(S,n,S)),this.helper.setUniformFloatVec4(jt.RENDER_EXTENT,S),this.helper.setUniformFloatValue(jt.RESOLUTION,f.resolution),this.helper.setUniformFloatValue(jt.ZOOM,f.zoom),this.helper.setUniformFloatValue(jt.TEXTURE_PIXEL_WIDTH,p),this.helper.setUniformFloatValue(jt.TEXTURE_PIXEL_HEIGHT,m),this.helper.setUniformFloatValue(jt.TEXTURE_RESOLUTION,r),this.helper.setUniformFloatValue(jt.TEXTURE_ORIGIN_X,a[0]+y*o[0]*r-c*r),this.helper.setUniformFloatValue(jt.TEXTURE_ORIGIN_Y,a[1]-v*o[1]*r+c*r),this.helper.drawElements(0,this.indices_.getSize())}getData(t){if(!this.helper.getGL())return null;const e=this.frameState;if(!e)return null;const i=this.getLayer(),n=Ye(e.pixelToCoordinateTransform,t.slice()),r=e.viewState,o=i.getExtent();if(o&&!Yi(cn(o,r.projection),n))return null;const a=i.getSources(ic([n]),r.resolution);let l,h,c;for(l=a.length-1;l>=0;--l)if(h=a[l],h.getState()==="ready"){if(c=h.getTileGridForProjection(r.projection),h.getWrapX())break;const d=c.getExtent();if(!d||Yi(d,n))break}if(l<0)return null;const u=this.tileRepresentationCache;for(let d=c.getZForResolution(r.resolution);d>=c.getMinZoom();--d){const g=c.getTileCoordForCoordAndZ(n,d),f=uy(h,g);if(!u.containsKey(f))continue;const p=u.get(f),m=p.tile;if((m instanceof Ag||m instanceof a0)&&m.getState()===X.EMPTY)return null;if(!p.loaded)continue;const _=c.getOrigin(d),y=Re(c.getTileSize(d)),v=c.getResolution(d),S=(n[0]-_[0])/v-g[1]*y[0],w=(_[1]-n[1])/v-g[2]*y[1];return p.getPixelData(S,w)}return null}disposeInternal(){const t=this.helper;if(t){const e=t.getGL();for(const i of this.paletteTextures_)i.delete(e);this.paletteTextures_.length=0,e.deleteProgram(this.program_),delete this.program_,t.deleteBuffer(this.indices_)}super.disposeInternal(),delete this.indices_}}function AK(s,t){return`operator_${s}_${Object.keys(t.functions).length}`}function Ya(s){const t=s.toString();return t.includes(".")?t:t+".0"}function c0(s){if(s.length<2||s.length>4)throw new Error("`formatArray` can only output `vec2`, `vec3` or `vec4` arrays.");return`vec${s.length}(${s.map(Ya).join(", ")})`}function jf(s){const t=Bn(s),e=t.length>3?t[3]:1;return c0([t[0]/255*e,t[1]/255*e,t[2]/255*e,e])}function LK(s){const t=Re(s);return c0(t)}const G_={};let OK=0;function Vp(s){return s in G_||(G_[s]=OK++),G_[s]}function $r(s){return Ya(Vp(s))}function Qv(s){return"u_var_"+s}function FK(){return{inFragmentShader:!1,variables:{},properties:{},functions:{},bandCount:0,style:{}}}const j_="getBandValue",pA="u_paletteTextures";function NK(s,t,e,i){const n=Cs(s,t,e);return tw(n,t,i)}function re(s){return(t,e,i)=>{const n=e.args.length,r=new Array(n);for(let o=0;o{const e=t.args[0].value;return e in s.properties||(s.properties[e]={name:e,type:t.type}),(s.inFragmentShader?"v_prop_":"a_prop_")+e},[U.GeometryType]:(s,t,e)=>{const i="geometryType";return i in s.properties||(s.properties[i]={name:i,type:bs,evaluator:n=>Bv(n.getGeometry())}),(s.inFragmentShader?"v_prop_":"a_prop_")+i},[U.Var]:(s,t)=>{const e=t.args[0].value;return e in s.variables||(s.variables[e]={name:e,type:t.type}),Qv(e)},[U.Resolution]:()=>"u_resolution",[U.Zoom]:()=>"u_zoom",[U.Time]:()=>"u_time",[U.Any]:re(s=>`(${s.join(" || ")})`),[U.All]:re(s=>`(${s.join(" && ")})`),[U.Not]:re(([s])=>`(!${s})`),[U.Equal]:re(([s,t])=>`(${s} == ${t})`),[U.NotEqual]:re(([s,t])=>`(${s} != ${t})`),[U.GreaterThan]:re(([s,t])=>`(${s} > ${t})`),[U.GreaterThanOrEqualTo]:re(([s,t])=>`(${s} >= ${t})`),[U.LessThan]:re(([s,t])=>`(${s} < ${t})`),[U.LessThanOrEqualTo]:re(([s,t])=>`(${s} <= ${t})`),[U.Multiply]:re(s=>`(${s.join(" * ")})`),[U.Divide]:re(([s,t])=>`(${s} / ${t})`),[U.Add]:re(s=>`(${s.join(" + ")})`),[U.Subtract]:re(([s,t])=>`(${s} - ${t})`),[U.Clamp]:re(([s,t,e])=>`clamp(${s}, ${t}, ${e})`),[U.Mod]:re(([s,t])=>`mod(${s}, ${t})`),[U.Pow]:re(([s,t])=>`pow(${s}, ${t})`),[U.Abs]:re(([s])=>`abs(${s})`),[U.Floor]:re(([s])=>`floor(${s})`),[U.Ceil]:re(([s])=>`ceil(${s})`),[U.Round]:re(([s])=>`floor(${s} + 0.5)`),[U.Sin]:re(([s])=>`sin(${s})`),[U.Cos]:re(([s])=>`cos(${s})`),[U.Atan]:re(([s,t])=>t!==void 0?`atan(${s}, ${t})`:`atan(${s})`),[U.Sqrt]:re(([s])=>`sqrt(${s})`),[U.Match]:re(s=>{const t=s[0],e=s[s.length-1];let i=null;for(let n=s.length-3;n>=1;n-=2){const r=s[n],o=s[n+1];i=`(${t} == ${r} ? ${o} : ${i||e})`}return i}),[U.Between]:re(([s,t,e])=>`(${s} >= ${t} && ${s} <= ${e})`),[U.Interpolate]:re(([s,t,...e])=>{let i="";for(let n=0;n{const t=s[s.length-1];let e=null;for(let i=s.length-3;i>=0;i-=2){const n=s[i],r=s[i+1];e=`(${n} ? ${r} : ${e||t})`}return e}),[U.In]:re(([s,...t],e)=>{const i=AK("in",e),n=[];for(let r=0;r{this.uniforms_.push({value:t.uniforms[o],location:e.getUniformLocation(this.renderTargetProgram_,o)})})}getGL(){return this.gl_}init(t){const e=this.getGL(),i=[e.drawingBufferWidth*this.scaleRatio_,e.drawingBufferHeight*this.scaleRatio_];if(e.bindFramebuffer(e.FRAMEBUFFER,this.getFrameBuffer()),e.bindRenderbuffer(e.RENDERBUFFER,this.getDepthBuffer()),e.viewport(0,0,i[0],i[1]),!this.renderTargetTextureSize_||this.renderTargetTextureSize_[0]!==i[0]||this.renderTargetTextureSize_[1]!==i[1]){this.renderTargetTextureSize_=i;const n=0,r=e.RGBA,o=0,a=e.RGBA,l=e.UNSIGNED_BYTE;e.bindTexture(e.TEXTURE_2D,this.renderTargetTexture_),e.texImage2D(e.TEXTURE_2D,n,r,i[0],i[1],o,a,l,null),e.texParameteri(e.TEXTURE_2D,e.TEXTURE_MIN_FILTER,e.LINEAR),e.texParameteri(e.TEXTURE_2D,e.TEXTURE_WRAP_S,e.CLAMP_TO_EDGE),e.texParameteri(e.TEXTURE_2D,e.TEXTURE_WRAP_T,e.CLAMP_TO_EDGE),e.framebufferTexture2D(e.FRAMEBUFFER,e.COLOR_ATTACHMENT0,e.TEXTURE_2D,this.renderTargetTexture_,0),e.renderbufferStorage(e.RENDERBUFFER,e.DEPTH_COMPONENT16,i[0],i[1]),e.framebufferRenderbuffer(e.FRAMEBUFFER,e.DEPTH_ATTACHMENT,e.RENDERBUFFER,this.depthBuffer_)}}apply(t,e,i,n){const r=this.getGL(),o=t.size;if(r.bindFramebuffer(r.FRAMEBUFFER,e?e.getFrameBuffer():null),r.activeTexture(r.TEXTURE0),r.bindTexture(r.TEXTURE_2D,this.renderTargetTexture_),!e){const l=mt(r.canvas);if(!t.renderTargets[l]){const h=r.getContextAttributes();h&&h.preserveDrawingBuffer&&(r.clearColor(0,0,0,0),r.clearDepth(1),r.clear(r.COLOR_BUFFER_BIT|r.DEPTH_BUFFER_BIT)),t.renderTargets[l]=!0}}r.disable(r.DEPTH_TEST),r.enable(r.BLEND),r.blendFunc(r.ONE,r.ONE_MINUS_SRC_ALPHA),r.viewport(0,0,r.drawingBufferWidth,r.drawingBufferHeight),r.bindBuffer(r.ARRAY_BUFFER,this.renderTargetVerticesBuffer_),r.useProgram(this.renderTargetProgram_),r.enableVertexAttribArray(this.renderTargetAttribLocation_),r.vertexAttribPointer(this.renderTargetAttribLocation_,2,r.FLOAT,!1,0,0),r.uniform2f(this.renderTargetUniformLocation_,o[0],o[1]),r.uniform1i(this.renderTargetTextureLocation_,0);const a=t.layerStatesArray[t.layerIndex].opacity;r.uniform1f(this.renderTargetOpacityLocation_,a),this.applyUniforms(t),i&&i(r,t),r.drawArrays(r.TRIANGLES,0,6),n&&n(r,t)}getFrameBuffer(){return this.frameBuffer_}getDepthBuffer(){return this.depthBuffer_}applyUniforms(t){const e=this.getGL();let i,n=1;this.uniforms_.forEach(function(r){if(i=typeof r.value=="function"?r.value(t):r.value,i instanceof HTMLCanvasElement||i instanceof ImageData)r.texture||(r.texture=e.createTexture()),e.activeTexture(e[`TEXTURE${n}`]),e.bindTexture(e.TEXTURE_2D,r.texture),e.texParameteri(e.TEXTURE_2D,e.TEXTURE_MIN_FILTER,e.LINEAR),e.texParameteri(e.TEXTURE_2D,e.TEXTURE_WRAP_S,e.CLAMP_TO_EDGE),e.texParameteri(e.TEXTURE_2D,e.TEXTURE_WRAP_T,e.CLAMP_TO_EDGE),i instanceof ImageData?e.texImage2D(e.TEXTURE_2D,0,e.RGBA,e.RGBA,i.width,i.height,0,e.UNSIGNED_BYTE,new Uint8Array(i.data)):e.texImage2D(e.TEXTURE_2D,0,e.RGBA,e.RGBA,e.UNSIGNED_BYTE,i),e.uniform1i(r.location,n++);else if(Array.isArray(i))switch(i.length){case 2:e.uniform2f(r.location,i[0],i[1]);return;case 3:e.uniform3f(r.location,i[0],i[1],i[2]);return;case 4:e.uniform4f(r.location,i[0],i[1],i[2],i[3]);return;default:return}else typeof i=="number"&&e.uniform1f(r.location,i)})}}function lA(){return[1,0,0,0,0,1,0,0,0,0,1,0,0,0,0,1]}function hA(s,t){return s[0]=t[0],s[1]=t[1],s[4]=t[2],s[5]=t[3],s[12]=t[4],s[13]=t[5],s}const Or={PROJECTION_MATRIX:"u_projectionMatrix",SCREEN_TO_WORLD_MATRIX:"u_screenToWorldMatrix",TIME:"u_time",ZOOM:"u_zoom",RESOLUTION:"u_resolution",ROTATION:"u_rotation",VIEWPORT_SIZE_PX:"u_viewportSizePx",PIXEL_RATIO:"u_pixelRatio",HIT_DETECTION:"u_hitDetection"},nr={UNSIGNED_BYTE:qH,UNSIGNED_SHORT:ZH,UNSIGNED_INT:HH,FLOAT:aA},Xp={};function CM(s){return"shared/"+s}let TM=0;function eK(){const s="unique/"+TM;return TM+=1,s}function sK(s){let t=Xp[s];if(!t){const e=document.createElement("canvas");e.width=1,e.height=1,e.style.position="absolute",e.style.left="0",t={users:0,context:KH(e)},Xp[s]=t}return t.users+=1,t.context}function iK(s){const t=Xp[s];if(!t||(t.users-=1,t.users>0))return;const e=t.context,i=e.getExtension("WEBGL_lose_context");i&&i.loseContext();const n=e.canvas;n.width=1,n.height=1,delete Xp[s]}class nK extends Ux{constructor(t){super(),t=t||{},this.boundHandleWebGLContextLost_=this.handleWebGLContextLost.bind(this),this.boundHandleWebGLContextRestored_=this.handleWebGLContextRestored.bind(this),this.canvasCacheKey_=t.canvasCacheKey?CM(t.canvasCacheKey):eK(),this.gl_=sK(this.canvasCacheKey_),this.bufferCache_={},this.extensionCache_={},this.currentProgram_=null,this.needsToBeRecreated_=!1;const e=this.gl_.canvas;e.addEventListener(Cf.LOST,this.boundHandleWebGLContextLost_),e.addEventListener(Cf.RESTORED,this.boundHandleWebGLContextRestored_),this.offsetRotateMatrix_=ss(),this.offsetScaleMatrix_=ss(),this.tmpMat4_=lA(),this.uniformLocationsByProgram_={},this.attribLocationsByProgram_={},this.uniforms_=[],t.uniforms&&this.setUniforms(t.uniforms),this.postProcessPasses_=t.postProcesses?t.postProcesses.map(i=>new bM({webGlContext:this.gl_,scaleRatio:i.scaleRatio,vertexShader:i.vertexShader,fragmentShader:i.fragmentShader,uniforms:i.uniforms})):[new bM({webGlContext:this.gl_})],this.shaderCompileErrors_=null,this.startTime_=Date.now()}setUniforms(t){this.uniforms_=[],this.addUniforms(t)}addUniforms(t){for(const e in t)this.uniforms_.push({name:e,value:t[e]})}canvasCacheKeyMatches(t){return this.canvasCacheKey_===CM(t)}getExtension(t){if(t in this.extensionCache_)return this.extensionCache_[t];const e=this.gl_.getExtension(t);return this.extensionCache_[t]=e,e}bindBuffer(t){const e=this.gl_,i=mt(t);let n=this.bufferCache_[i];if(!n){const r=e.createBuffer();n={buffer:t,webGlBuffer:r},this.bufferCache_[i]=n}e.bindBuffer(t.getType(),n.webGlBuffer)}flushBufferData(t){const e=this.gl_;this.bindBuffer(t),e.bufferData(t.getType(),t.getArray(),t.getUsage())}deleteBuffer(t){const e=this.gl_,i=mt(t),n=this.bufferCache_[i];n&&!e.isContextLost()&&e.deleteBuffer(n.webGlBuffer),delete this.bufferCache_[i]}disposeInternal(){const t=this.gl_.canvas;t.removeEventListener(Cf.LOST,this.boundHandleWebGLContextLost_),t.removeEventListener(Cf.RESTORED,this.boundHandleWebGLContextRestored_),iK(this.canvasCacheKey_),delete this.gl_}prepareDraw(t,e,i){const n=this.gl_,r=this.getCanvas(),o=t.size,a=t.pixelRatio;(r.width!==o[0]*a||r.height!==o[1]*a)&&(r.width=o[0]*a,r.height=o[1]*a,r.style.width=o[0]+"px",r.style.height=o[1]+"px");for(let l=this.postProcessPasses_.length-1;l>=0;l--)this.postProcessPasses_[l].init(t);n.bindTexture(n.TEXTURE_2D,null),n.clearColor(0,0,0,0),n.depthRange(0,1),n.clearDepth(1),n.clear(n.COLOR_BUFFER_BIT|n.DEPTH_BUFFER_BIT),n.enable(n.BLEND),n.blendFunc(n.ONE,e?n.ZERO:n.ONE_MINUS_SRC_ALPHA),i?(n.enable(n.DEPTH_TEST),n.depthFunc(n.LEQUAL)):n.disable(n.DEPTH_TEST)}bindTexture(t,e,i){const n=this.gl_;n.activeTexture(n.TEXTURE0+e),n.bindTexture(n.TEXTURE_2D,t),n.uniform1i(this.getUniformLocation(i),e)}prepareDrawToRenderTarget(t,e,i,n){const r=this.gl_,o=e.getSize();r.bindFramebuffer(r.FRAMEBUFFER,e.getFramebuffer()),r.bindRenderbuffer(r.RENDERBUFFER,e.getDepthbuffer()),r.viewport(0,0,o[0],o[1]),r.bindTexture(r.TEXTURE_2D,e.getTexture()),r.clearColor(0,0,0,0),r.depthRange(0,1),r.clearDepth(1),r.clear(r.COLOR_BUFFER_BIT|r.DEPTH_BUFFER_BIT),r.enable(r.BLEND),r.blendFunc(r.ONE,i?r.ZERO:r.ONE_MINUS_SRC_ALPHA),n?(r.enable(r.DEPTH_TEST),r.depthFunc(r.LEQUAL)):r.disable(r.DEPTH_TEST)}drawElements(t,e){const i=this.gl_;this.getExtension("OES_element_index_uint");const n=i.UNSIGNED_INT,r=4,o=e-t,a=t*r;i.drawElements(i.TRIANGLES,o,n,a)}finalizeDraw(t,e,i){for(let n=0,r=this.postProcessPasses_.length;n{if(i=typeof r.value=="function"?r.value(t):r.value,i instanceof HTMLCanvasElement||i instanceof HTMLImageElement||i instanceof ImageData||i instanceof WebGLTexture){i instanceof WebGLTexture&&!r.texture?(r.prevValue=void 0,r.texture=i):r.texture||(r.prevValue=void 0,r.texture=e.createTexture()),this.bindTexture(r.texture,n,r.name),e.texParameteri(e.TEXTURE_2D,e.TEXTURE_MIN_FILTER,e.LINEAR),e.texParameteri(e.TEXTURE_2D,e.TEXTURE_WRAP_S,e.CLAMP_TO_EDGE),e.texParameteri(e.TEXTURE_2D,e.TEXTURE_WRAP_T,e.CLAMP_TO_EDGE);const o=!(i instanceof HTMLImageElement)||i.complete;!(i instanceof WebGLTexture)&&o&&r.prevValue!==i&&(r.prevValue=i,e.texImage2D(e.TEXTURE_2D,0,e.RGBA,e.RGBA,e.UNSIGNED_BYTE,i)),n++}else if(Array.isArray(i)&&i.length===6)this.setUniformMatrixValue(r.name,hA(this.tmpMat4_,i));else if(Array.isArray(i)&&i.length<=4)switch(i.length){case 2:e.uniform2f(this.getUniformLocation(r.name),i[0],i[1]);return;case 3:e.uniform3f(this.getUniformLocation(r.name),i[0],i[1],i[2]);return;case 4:e.uniform4f(this.getUniformLocation(r.name),i[0],i[1],i[2],i[3]);return;default:return}else typeof i=="number"&&e.uniform1f(this.getUniformLocation(r.name),i)})}useProgram(t,e){this.gl_.useProgram(t),this.currentProgram_=t,this.applyFrameState(e),this.applyUniforms(e)}compileShader(t,e){const i=this.gl_,n=i.createShader(e);return i.shaderSource(n,t),i.compileShader(n),n}getProgram(t,e){const i=this.gl_,n=this.compileShader(t,i.FRAGMENT_SHADER),r=this.compileShader(e,i.VERTEX_SHADER),o=i.createProgram();if(i.attachShader(o,n),i.attachShader(o,r),i.linkProgram(o),!i.getShaderParameter(n,i.COMPILE_STATUS)){const a=`Fragment shader compilation failed: ${i.getShaderInfoLog(n)}`;throw new Error(a)}if(i.deleteShader(n),!i.getShaderParameter(r,i.COMPILE_STATUS)){const a=`Vertex shader compilation failed: ${i.getShaderInfoLog(r)}`;throw new Error(a)}if(i.deleteShader(r),!i.getProgramParameter(o,i.LINK_STATUS)){const a=`GL program linking failed: ${i.getProgramInfoLog(o)}`;throw new Error(a)}return o}getUniformLocation(t){const e=mt(this.currentProgram_);return this.uniformLocationsByProgram_[e]===void 0&&(this.uniformLocationsByProgram_[e]={}),this.uniformLocationsByProgram_[e][t]===void 0&&(this.uniformLocationsByProgram_[e][t]=this.gl_.getUniformLocation(this.currentProgram_,t)),this.uniformLocationsByProgram_[e][t]}getAttributeLocation(t){const e=mt(this.currentProgram_);return this.attribLocationsByProgram_[e]===void 0&&(this.attribLocationsByProgram_[e]={}),this.attribLocationsByProgram_[e][t]===void 0&&(this.attribLocationsByProgram_[e][t]=this.gl_.getAttribLocation(this.currentProgram_,t)),this.attribLocationsByProgram_[e][t]}makeProjectionTransform(t,e){const i=t.size,n=t.viewState.rotation,r=t.viewState.resolution,o=t.viewState.center;return xn(e,0,0,2/(r*i[0]),2/(r*i[1]),-n,-o[0],-o[1]),e}setUniformFloatValue(t,e){this.gl_.uniform1f(this.getUniformLocation(t),e)}setUniformFloatVec2(t,e){this.gl_.uniform2fv(this.getUniformLocation(t),e)}setUniformFloatVec4(t,e){this.gl_.uniform4fv(this.getUniformLocation(t),e)}setUniformMatrixValue(t,e){this.gl_.uniformMatrix4fv(this.getUniformLocation(t),!1,e)}enableAttributeArray_(t,e,i,n,r){const o=this.getAttributeLocation(t);o<0||(this.gl_.enableVertexAttribArray(o),this.gl_.vertexAttribPointer(o,e,i,!1,n,r))}enableAttributes(t){const e=rK(t);let i=0;for(let n=0;nthis.size_[0]||e>=this.size_[1])return Kn[0]=0,Kn[1]=0,Kn[2]=0,Kn[3]=0,Kn;this.readAll();const i=Math.floor(t)+(this.size_[1]-Math.floor(e)-1)*this.size_[0];return Kn[0]=this.data_[i*4],Kn[1]=this.data_[i*4+1],Kn[2]=this.data_[i*4+2],Kn[3]=this.data_[i*4+3],Kn}getTexture(){return this.texture_}getFramebuffer(){return this.framebuffer_}getDepthbuffer(){return this.depthbuffer_}updateSize_(){const t=this.size_,e=this.helper_.getGL();this.texture_=this.helper_.createTexture(t,null,this.texture_),e.bindFramebuffer(e.FRAMEBUFFER,this.framebuffer_),e.viewport(0,0,t[0],t[1]),e.framebufferTexture2D(e.FRAMEBUFFER,e.COLOR_ATTACHMENT0,e.TEXTURE_2D,this.texture_,0),e.bindRenderbuffer(e.RENDERBUFFER,this.depthbuffer_),e.renderbufferStorage(e.RENDERBUFFER,e.DEPTH_COMPONENT16,t[0],t[1]),e.framebufferRenderbuffer(e.FRAMEBUFFER,e.DEPTH_ATTACHMENT,e.RENDERBUFFER,this.depthbuffer_),this.data_=new Uint8Array(t[0]*t[1]*4)}}const RM={GENERATE_POLYGON_BUFFERS:"GENERATE_POLYGON_BUFFERS",GENERATE_POINT_BUFFERS:"GENERATE_POINT_BUFFERS",GENERATE_LINE_STRING_BUFFERS:"GENERATE_LINE_STRING_BUFFERS"},IM=.985;function aK(s,t){t=t||[];const e=256,i=e-1;return t[0]=Math.floor(s/e/e/e)/i,t[1]=Math.floor(s/e/e)%e/i,t[2]=Math.floor(s/e)%e/i,t[3]=s%e/i,t}function lK(s){let t=0;const e=256,i=e-1;return t+=Math.round(s[0]*e*e*e*i),t+=Math.round(s[1]*e*e*i),t+=Math.round(s[2]*e*i),t+=Math.round(s[3]*i),t}function hK(){const s='const t="GENERATE_POLYGON_BUFFERS",e="GENERATE_POINT_BUFFERS",n="GENERATE_LINE_STRING_BUFFERS";function r(t,e){const n=e[0],r=e[1];return e[0]=t[0]*n+t[2]*r+t[4],e[1]=t[1]*n+t[3]*r+t[5],e}function x(t,e){const n=(r=e)[0]*r[3]-r[1]*r[2];var r;!function(t,e){if(!t)throw new Error(e)}(0!==n,"Transformation matrix cannot be inverted");const x=e[0],o=e[1],u=e[2],i=e[3],f=e[4],s=e[5];return t[0]=i/n,t[1]=-o/n,t[2]=-u/n,t[3]=x/n,t[4]=(u*s-i*f)/n,t[5]=-(x*s-o*f)/n,t}function o(t,e,n=2){const r=e&&e.length,x=r?e[0]*n:t.length;let o=u(t,0,x,n,!0);const i=[];if(!o||o.next===o.prev)return i;let s,l,c;if(r&&(o=function(t,e,n,r){const x=[];for(let n=0,o=e.length;n80*n){s=1/0,l=1/0;let e=-1/0,r=-1/0;for(let o=n;oe&&(e=n),x>r&&(r=x)}c=Math.max(e-s,r-l),c=0!==c?32767/c:0}return f(o,i,n,s,l,c,0),i}function u(t,e,n,r,x){let o;if(x===function(t,e,n,r){let x=0;for(let o=e,u=n-r;o0)for(let x=e;x=e;x-=r)o=z(x/r|0,t[x],t[x+1],o);return o&&M(o,o.next)&&(F(o),o=o.next),o}function i(t,e){if(!t)return t;e||(e=t);let n,r=t;do{if(n=!1,r.steiner||!M(r,r.next)&&0!==d(r.prev,r,r.next))r=r.next;else{if(F(r),r=e=r.prev,r===r.next)break;n=!0}}while(n||r!==e);return e}function f(t,e,n,r,x,o,u){if(!t)return;!u&&o&&function(t,e,n,r){let x=t;do{0===x.z&&(x.z=v(x.x,x.y,e,n,r)),x.prevZ=x.prev,x.nextZ=x.next,x=x.next}while(x!==t);x.prevZ.nextZ=null,x.prevZ=null,function(t){let e,n=1;do{let r,x=t;t=null;let o=null;for(e=0;x;){e++;let u=x,i=0;for(let t=0;t0||f>0&&u;)0!==i&&(0===f||!u||x.z<=u.z)?(r=x,x=x.nextZ,i--):(r=u,u=u.nextZ,f--),o?o.nextZ=r:t=r,r.prevZ=o,o=r;x=u}o.nextZ=null,n*=2}while(e>1)}(x)}(t,r,x,o);let y=t;for(;t.prev!==t.next;){const h=t.prev,p=t.next;if(o?l(t,r,x,o):s(t))e.push(h.i,t.i,p.i),F(t),t=p.next,y=p.next;else if((t=p)===y){u?1===u?f(t=c(i(t),e),e,n,r,x,o,2):2===u&&a(t,e,n,r,x,o):f(i(t),e,n,r,x,o,1);break}}}function s(t){const e=t.prev,n=t,r=t.next;if(d(e,n,r)>=0)return!1;const x=e.x,o=n.x,u=r.x,i=e.y,f=n.y,s=r.y,l=xo?x>u?x:u:o>u?o:u,y=i>f?i>s?i:s:f>s?f:s;let h=r.next;for(;h!==e;){if(h.x>=l&&h.x<=a&&h.y>=c&&h.y<=y&&b(x,i,o,f,u,s,h.x,h.y)&&d(h.prev,h,h.next)>=0)return!1;h=h.next}return!0}function l(t,e,n,r){const x=t.prev,o=t,u=t.next;if(d(x,o,u)>=0)return!1;const i=x.x,f=o.x,s=u.x,l=x.y,c=o.y,a=u.y,y=if?i>s?i:s:f>s?f:s,g=l>c?l>a?l:a:c>a?c:a,Z=v(y,h,e,n,r),M=v(p,g,e,n,r);let w=t.prevZ,m=t.nextZ;for(;w&&w.z>=Z&&m&&m.z<=M;){if(w.x>=y&&w.x<=p&&w.y>=h&&w.y<=g&&w!==x&&w!==u&&b(i,l,f,c,s,a,w.x,w.y)&&d(w.prev,w,w.next)>=0)return!1;if(w=w.prevZ,m.x>=y&&m.x<=p&&m.y>=h&&m.y<=g&&m!==x&&m!==u&&b(i,l,f,c,s,a,m.x,m.y)&&d(m.prev,m,m.next)>=0)return!1;m=m.nextZ}for(;w&&w.z>=Z;){if(w.x>=y&&w.x<=p&&w.y>=h&&w.y<=g&&w!==x&&w!==u&&b(i,l,f,c,s,a,w.x,w.y)&&d(w.prev,w,w.next)>=0)return!1;w=w.prevZ}for(;m&&m.z<=M;){if(m.x>=y&&m.x<=p&&m.y>=h&&m.y<=g&&m!==x&&m!==u&&b(i,l,f,c,s,a,m.x,m.y)&&d(m.prev,m,m.next)>=0)return!1;m=m.nextZ}return!0}function c(t,e){let n=t;do{const r=n.prev,x=n.next.next;!M(r,x)&&w(r,n,n.next,x)&&E(r,x)&&E(x,r)&&(e.push(r.i,n.i,x.i),F(n),F(n.next),n=t=x),n=n.next}while(n!==t);return i(n)}function a(t,e,n,r,x,o){let u=t;do{let t=u.next.next;for(;t!==u.prev;){if(u.i!==t.i&&Z(u,t)){let s=I(u,t);return u=i(u,u.next),s=i(s,s.next),f(u,e,n,r,x,o,0),void f(s,e,n,r,x,o,0)}t=t.next}u=u.next}while(u!==t)}function y(t,e){return t.x-e.x}function h(t,e){const n=function(t,e){let n=e;const r=t.x,x=t.y;let o,u=-1/0;do{if(x<=n.y&&x>=n.next.y&&n.next.y!==n.y){const t=n.x+(x-n.y)*(n.next.x-n.x)/(n.next.y-n.y);if(t<=r&&t>u&&(u=t,o=n.x=n.x&&n.x>=f&&r!==n.x&&b(xo.x||n.x===o.x&&p(o,n)))&&(o=n,l=e)}n=n.next}while(n!==i);return o}(t,e);if(!n)return e;const r=I(n,t);return i(r,r.next),i(n,n.next)}function p(t,e){return d(t.prev,t,e.prev)<0&&d(e.next,t,t.next)<0}function v(t,e,n,r,x){return(t=1431655765&((t=858993459&((t=252645135&((t=16711935&((t=(t-n)*x|0)|t<<8))|t<<4))|t<<2))|t<<1))|(e=1431655765&((e=858993459&((e=252645135&((e=16711935&((e=(e-r)*x|0)|e<<8))|e<<4))|e<<2))|e<<1))<<1}function g(t){let e=t,n=t;do{(e.x=(t-u)*(o-i)&&(t-u)*(r-i)>=(n-u)*(e-i)&&(n-u)*(o-i)>=(x-u)*(r-i)}function Z(t,e){return t.next.i!==e.i&&t.prev.i!==e.i&&!function(t,e){let n=t;do{if(n.i!==t.i&&n.next.i!==t.i&&n.i!==e.i&&n.next.i!==e.i&&w(n,n.next,t,e))return!0;n=n.next}while(n!==t);return!1}(t,e)&&(E(t,e)&&E(e,t)&&function(t,e){let n=t,r=!1;const x=(t.x+e.x)/2,o=(t.y+e.y)/2;do{n.y>o!=n.next.y>o&&n.next.y!==n.y&&x<(n.next.x-n.x)*(o-n.y)/(n.next.y-n.y)+n.x&&(r=!r),n=n.next}while(n!==t);return r}(t,e)&&(d(t.prev,t,e.prev)||d(t,e.prev,e))||M(t,e)&&d(t.prev,t,t.next)>0&&d(e.prev,e,e.next)>0)}function d(t,e,n){return(e.y-t.y)*(n.x-e.x)-(e.x-t.x)*(n.y-e.y)}function M(t,e){return t.x===e.x&&t.y===e.y}function w(t,e,n,r){const x=A(d(t,e,n)),o=A(d(t,e,r)),u=A(d(n,r,t)),i=A(d(n,r,e));return x!==o&&u!==i||(!(0!==x||!m(t,n,e))||(!(0!==o||!m(t,r,e))||(!(0!==u||!m(n,t,r))||!(0!==i||!m(n,e,r)))))}function m(t,e,n){return e.x<=Math.max(t.x,n.x)&&e.x>=Math.min(t.x,n.x)&&e.y<=Math.max(t.y,n.y)&&e.y>=Math.min(t.y,n.y)}function A(t){return t>0?1:t<0?-1:0}function E(t,e){return d(t.prev,t,t.next)<0?d(t,e,t.next)>=0&&d(t,t.prev,e)>=0:d(t,e,t.prev)<0||d(t,t.next,e)<0}function I(t,e){const n=P(t.i,t.x,t.y),r=P(e.i,e.x,e.y),x=t.next,o=e.prev;return t.next=e,e.prev=t,n.next=x,x.prev=n,r.next=n,n.prev=r,o.next=r,r.prev=o,r}function z(t,e,n,r){const x=P(t,e,n);return r?(x.next=r.next,x.prev=r,r.next.prev=x,r.next=x):(x.prev=x,x.next=x),x}function F(t){t.next.prev=t.prev,t.prev.next=t.next,t.prevZ&&(t.prevZ.nextZ=t.nextZ),t.nextZ&&(t.nextZ.prevZ=t.prevZ)}function P(t,e,n){return{i:t,x:e,y:n,prev:null,next:null,z:0,prevZ:null,nextZ:null,steiner:!1}}new Array(6);const B=[],N={vertexPosition:0,indexPosition:0};function R(t,e,n,r,x){t[e+0]=n,t[e+1]=r,t[e+2]=x}function S(t,e,n,r,x,o){const u=3+x,i=t[e+0],f=t[e+1],s=B;s.length=x;for(let n=0;n0?f:2*Math.PI-f}let Z=-1,d=-1,M=c;const w=null!==o;if(null!==x){Z=b(v,g,r(s,[...[t[x],t[x+1]]])),Math.cos(Z)<=.985&&(M+=Math.tan((Z-Math.PI)/2))}if(w){d=b(g,v,r(s,[...[t[o],t[o+1]]])),Math.cos(d)<=.985&&(M+=Math.tan((Math.PI-d)/2))}function m(t,e){return 0===e?1e4*t:Math.sign(e)*(1e4*t+Math.abs(e))}return u.push(h[0],h[1],p[0],p[1],Z,d,l,m(0,c)),u.push(...f),u.push(h[0],h[1],p[0],p[1],Z,d,l,m(1,c)),u.push(...f),u.push(h[0],h[1],p[0],p[1],Z,d,l,m(2,c)),u.push(...f),u.push(h[0],h[1],p[0],p[1],Z,d,l,m(3,c)),u.push(...f),i.push(y,y+1,y+2,y+1,y+3,y+2),{length:l+Math.sqrt((g[0]-v[0])*(g[0]-v[0])+(g[1]-v[1])*(g[1]-v[1])),angle:M}}function _(t,e,n,r,x){const u=2+x;let i=e;const f=t.slice(i,i+x);i+=x;const s=t[i++];let l=0;const c=new Array(s-1);for(let e=0;e{const o=r.data;switch(o.type){case e:{const t=3,e=2,n=o.customAttributesSize,r=e+n,x=new Float32Array(o.renderInstructions),u=x.length/r,i=4*u*(n+t),f=new Uint32Array(6*u),s=new Float32Array(i);let l;for(let t=0;t0?h=i+(n-1)*r:c&&(h=o-r);let p=null;n"u"?"data:application/javascript;base64,"+Buffer.from(s,"binary").toString("base64"):URL.createObjectURL(new Blob([s],{type:"application/javascript"})))}function cK(s,t){const e=s.viewState.projection,i=t.getSource().getWrapX()&&e.canWrapX(),n=e.getExtent(),r=s.extent,o=i?Rt(n):null,a=i?Math.ceil((r[2]-n[2])/o)+1:1;return[i?Math.floor((r[0]-n[0])/o):0,a,o]}class uA extends o0{constructor(t,e){const i=e.uniforms||{},n=ss();i[Or.PROJECTION_MATRIX]=n,super(t,{uniforms:i,postProcesses:e.postProcesses}),this.sourceRevision_=-1,this.verticesBuffer_=new Wp(n0,hy),this.indicesBuffer_=new Wp(r0,hy),this.vertexShader_=e.vertexShader,this.fragmentShader_=e.fragmentShader,this.program_,this.hitDetectionEnabled_=e.hitDetectionEnabled??!0;const r=e.attributes?e.attributes.map(function(a){return{name:"a_prop_"+a.name,size:1,type:nr.FLOAT}}):[];this.attributes=[{name:"a_position",size:2,type:nr.FLOAT},{name:"a_index",size:1,type:nr.FLOAT}],this.hitDetectionEnabled_&&(this.attributes.push({name:"a_prop_hitColor",size:4,type:nr.FLOAT}),this.attributes.push({name:"a_featureUid",size:1,type:nr.FLOAT})),this.attributes.push(...r),this.customAttributes=e.attributes?e.attributes:[],this.previousExtent_=Zs(),this.currentTransform_=n,this.renderTransform_=ss(),this.invertRenderTransform_=ss(),this.renderInstructions_=new Float32Array(0),this.hitRenderTarget_,this.lastSentId=0,this.worker_=hK(),this.worker_.addEventListener("message",a=>{const l=a.data;if(l.type===RM.GENERATE_POINT_BUFFERS){const h=l.projectionTransform;this.verticesBuffer_.fromArrayBuffer(l.vertexBuffer),this.helper.flushBufferData(this.verticesBuffer_),this.indicesBuffer_.fromArrayBuffer(l.indexBuffer),this.helper.flushBufferData(this.indicesBuffer_),this.renderTransform_=h,hI(this.invertRenderTransform_,this.renderTransform_),this.renderInstructions_=new Float32Array(a.data.renderInstructions),l.id===this.lastSentId&&(this.ready=!0),this.getLayer().changed()}}),this.featureCache_={},this.featureCount_=0;const o=this.getLayer().getSource();this.sourceListenKeys_=[We(o,zs.ADDFEATURE,this.handleSourceFeatureAdded_,this),We(o,zs.CHANGEFEATURE,this.handleSourceFeatureChanged_,this),We(o,zs.REMOVEFEATURE,this.handleSourceFeatureDelete_,this),We(o,zs.CLEAR,this.handleSourceFeatureClear_,this)],o.forEachFeature(a=>{this.featureCache_[mt(a)]={feature:a,properties:a.getProperties(),geometry:a.getGeometry()},this.featureCount_++})}afterHelperCreated(){this.program_=this.helper.getProgram(this.fragmentShader_,this.vertexShader_),this.hitDetectionEnabled_&&(this.hitRenderTarget_=new oK(this.helper))}handleSourceFeatureAdded_(t){const e=t.feature;this.featureCache_[mt(e)]={feature:e,properties:e.getProperties(),geometry:e.getGeometry()},this.featureCount_++}handleSourceFeatureChanged_(t){const e=t.feature;this.featureCache_[mt(e)]={feature:e,properties:e.getProperties(),geometry:e.getGeometry()}}handleSourceFeatureDelete_(t){const e=t.feature;delete this.featureCache_[mt(e)],this.featureCount_--}handleSourceFeatureClear_(){this.featureCache_={},this.featureCount_=0}renderFrame(t){const e=this.helper.getGL();this.preRender(e,t);const[i,n,r]=cK(t,this.getLayer());return this.renderWorlds(t,!1,i,n,r),this.helper.finalizeDraw(t,this.dispatchPreComposeEvent,this.dispatchPostComposeEvent),this.hitDetectionEnabled_&&(this.renderWorlds(t,!0,i,n,r),this.hitRenderTarget_.clearCachedData()),this.postRender(e,t),this.helper.getCanvas()}prepareFrameInternal(t){const e=this.getLayer(),i=e.getSource(),n=t.viewState,r=!t.viewHints[Ie.ANIMATING]&&!t.viewHints[Ie.INTERACTING],o=!so(this.previousExtent_,t.extent),a=this.sourceRevision_t)throw new Error("Tile load sequence violation");this.state=t,this.changed()}load(){vt()}getAlpha(t,e){if(!this.transition_)return 1;let i=this.transitionStarts_[t];if(!i)i=e,this.transitionStarts_[t]=i;else if(i===-1)return 1;const n=e-i+1e3/60;return n>=this.transition_?1:jP(n/this.transition_)}inTransition(t){return this.transition_?this.transitionStarts_[t]!==-1:!1}endTransition(t){this.transition_&&(this.transitionStarts_[t]=-1)}}function uc(s){return s instanceof Image||s instanceof HTMLCanvasElement||s instanceof HTMLVideoElement||s instanceof ImageBitmap?s:null}function cy(s){return s instanceof Uint8Array||s instanceof Uint8ClampedArray||s instanceof Float32Array||s instanceof DataView?s:null}const dK=new Error("disposed");let $l=null;function gK(s){$l||($l=Se(s.width,s.height,void 0,{willReadFrequently:!0}));const t=$l.canvas,e=s.width;t.width!==e&&(t.width=e);const i=s.height;return t.height!==i&&(t.height=i),$l.clearRect(0,0,e,i),$l.drawImage(s,0,0),$l.getImageData(0,0,e,i).data}const fK=[256,256];class kd extends Oc{constructor(t){const e=X.IDLE;super(t.tileCoord,e,{transition:t.transition,interpolate:t.interpolate}),this.loader_=t.loader,this.data_=null,this.error_=null,this.size_=t.size||null,this.controller_=t.controller||null}getSize(){if(this.size_)return this.size_;const t=uc(this.data_);return t?[t.width,t.height]:fK}getData(){return this.data_}getError(){return this.error_}load(){if(this.state!==X.IDLE&&this.state!==X.ERROR)return;this.state=X.LOADING,this.changed();const t=this;this.loader_().then(function(e){t.data_=e,t.state=X.LOADED,t.changed()}).catch(function(e){t.error_=e,t.state=X.ERROR,t.changed()})}disposeInternal(){this.controller_&&(this.controller_.abort(dK),this.controller_=null),super.disposeInternal()}}const pK=10,PM=.25;class Hv{constructor(t,e,i,n,r,o){this.sourceProj_=t,this.targetProj_=e;let a={};const l=vr(this.targetProj_,this.sourceProj_);this.transformInv_=function(y){const v=y[0]+"/"+y[1];return a[v]||(a[v]=l(y)),a[v]},this.maxSourceExtent_=n,this.errorThresholdSquared_=r*r,this.triangles_=[],this.wrapsXInSource_=!1,this.canWrapXInSource_=this.sourceProj_.canWrapX()&&!!n&&!!this.sourceProj_.getExtent()&&Rt(n)>=Rt(this.sourceProj_.getExtent()),this.sourceWorldWidth_=this.sourceProj_.getExtent()?Rt(this.sourceProj_.getExtent()):null,this.targetWorldWidth_=this.targetProj_.getExtent()?Rt(this.targetProj_.getExtent()):null;const h=fo(i),c=yg(i),u=Nm(i),d=_g(i),g=this.transformInv_(h),f=this.transformInv_(c),p=this.transformInv_(u),m=this.transformInv_(d),_=pK+(o?Math.max(0,Math.ceil(Math.log2(Cd(i)/(o*o*256*256)))):0);if(this.addQuad_(h,c,u,d,g,f,p,m,_),this.wrapsXInSource_){let y=1/0;this.triangles_.forEach(function(v,S,w){y=Math.min(y,v.source[0][0],v.source[1][0],v.source[2][0])}),this.triangles_.forEach(v=>{if(Math.max(v.source[0][0],v.source[1][0],v.source[2][0])-y>this.sourceWorldWidth_/2){const S=[[v.source[0][0],v.source[0][1]],[v.source[1][0],v.source[1][1]],[v.source[2][0],v.source[2][1]]];S[0][0]-y>this.sourceWorldWidth_/2&&(S[0][0]-=this.sourceWorldWidth_),S[1][0]-y>this.sourceWorldWidth_/2&&(S[1][0]-=this.sourceWorldWidth_),S[2][0]-y>this.sourceWorldWidth_/2&&(S[2][0]-=this.sourceWorldWidth_);const w=Math.min(S[0][0],S[1][0],S[2][0]);Math.max(S[0][0],S[1][0],S[2][0])-w.5&&u<1;let f=!1;if(h>0){if(this.targetProj_.isGlobal()&&this.targetWorldWidth_){const m=ic([t,e,i,n]);f=Rt(m)/this.targetWorldWidth_>PM||f}!g&&this.sourceProj_.isGlobal()&&u&&(f=u>PM||f)}if(!f&&this.maxSourceExtent_&&isFinite(c[0])&&isFinite(c[1])&&isFinite(c[2])&&isFinite(c[3])&&!Ce(c,this.maxSourceExtent_))return;let p=0;if(!f&&(!isFinite(r[0])||!isFinite(r[1])||!isFinite(o[0])||!isFinite(o[1])||!isFinite(a[0])||!isFinite(a[1])||!isFinite(l[0])||!isFinite(l[1]))){if(h>0)f=!0;else if(p=(!isFinite(r[0])||!isFinite(r[1])?8:0)+(!isFinite(o[0])||!isFinite(o[1])?4:0)+(!isFinite(a[0])||!isFinite(a[1])?2:0)+(!isFinite(l[0])||!isFinite(l[1])?1:0),p!=1&&p!=2&&p!=4&&p!=8)return}if(h>0){if(!f){const m=[(t[0]+i[0])/2,(t[1]+i[1])/2],_=this.transformInv_(m);let y;g?y=(kn(r[0],d)+kn(a[0],d))/2-kn(_[0],d):y=(r[0]+a[0])/2-_[0];const v=(r[1]+a[1])/2-_[1];f=y*y+v*v>this.errorThresholdSquared_}if(f){if(Math.abs(t[0]-i[0])<=Math.abs(t[1]-i[1])){const m=[(e[0]+i[0])/2,(e[1]+i[1])/2],_=this.transformInv_(m),y=[(n[0]+t[0])/2,(n[1]+t[1])/2],v=this.transformInv_(y);this.addQuad_(t,e,m,y,r,o,_,v,h-1),this.addQuad_(y,m,i,n,v,_,a,l,h-1)}else{const m=[(t[0]+e[0])/2,(t[1]+e[1])/2],_=this.transformInv_(m),y=[(i[0]+n[0])/2,(i[1]+n[1])/2],v=this.transformInv_(y);this.addQuad_(t,m,y,n,r,_,v,l,h-1),this.addQuad_(m,e,i,y,_,o,a,v,h-1)}return}}if(g){if(!this.canWrapXInSource_)return;this.wrapsXInSource_=!0}p&11||this.addTriangle_(t,i,n,r,a,l),p&14||this.addTriangle_(t,i,e,r,a,o),p&&(p&13||this.addTriangle_(e,n,t,o,l,r),p&7||this.addTriangle_(e,n,i,o,l,a))}calculateSourceExtent(){const t=Zs();return this.triangles_.forEach(function(e,i,n){const r=e.source;Wu(t,r[0]),Wu(t,r[1]),Wu(t,r[2])}),t}getTriangles(){return this.triangles_}}let D_;const Jr=[];function AM(s,t,e,i,n){s.beginPath(),s.moveTo(0,0),s.lineTo(t,e),s.lineTo(i,n),s.closePath(),s.save(),s.clip(),s.fillRect(0,0,Math.max(t,i)+1,Math.max(e,n)),s.restore()}function k_(s,t){return Math.abs(s[t*4]-210)>2||Math.abs(s[t*4+3]-.75*255)>2}function mK(){if(D_===void 0){const s=Se(6,6,Jr);s.globalCompositeOperation="lighter",s.fillStyle="rgba(210, 0, 0, 0.75)",AM(s,4,5,4,0),AM(s,4,5,0,5);const t=s.getImageData(0,0,3,3).data;D_=k_(t,0)||k_(t,4)||k_(t,8),ol(s),Jr.push(s.canvas)}return D_}function $d(s,t,e,i){const n=Dm(e,t,s);let r=a2(t,i,e);const o=t.getMetersPerUnit();o!==void 0&&(r*=o);const a=s.getMetersPerUnit();a!==void 0&&(r/=a);const l=s.getExtent();if(!l||Yi(l,n)){const h=a2(s,r,n)/r;isFinite(h)&&h>0&&(r/=h)}return r}function dA(s,t,e,i){const n=Rs(e);let r=$d(s,t,n,i);return(!isFinite(r)||r<=0)&&dI(e,function(o){return r=$d(s,t,o,i),isFinite(r)&&r>0}),r}function Kv(s,t,e,i,n,r,o,a,l,h,c,u,d,g){const f=Se(Math.round(e*s),Math.round(e*t),Jr);if(u||(f.imageSmoothingEnabled=!1),l.length===0)return f.canvas;f.scale(e,e);function p(w){return Math.round(w*e)/e}f.globalCompositeOperation="lighter";const m=Zs();l.forEach(function(w,C,M){cI(m,w.extent)});let _;const y=e/i,v=(u?1:1+Math.pow(2,-24))/y;if(!d||l.length!==1||h!==0){if(_=Se(Math.round(Rt(m)*y),Math.round(Ee(m)*y),Jr),u||(_.imageSmoothingEnabled=!1),n&&g){const w=(n[0]-m[0])*y,C=-(n[3]-m[3])*y,M=Rt(n)*y,T=Ee(n)*y;_.rect(w,C,M,T),_.clip()}l.forEach(function(w,C,M){if(w.image.width>0&&w.image.height>0){if(w.clipExtent){_.save();const D=(w.clipExtent[0]-m[0])*y,x=-(w.clipExtent[3]-m[3])*y,E=Rt(w.clipExtent)*y,b=Ee(w.clipExtent)*y;_.rect(u?D:Math.round(D),u?x:Math.round(x),u?E:Math.round(D+E)-Math.round(D),u?b:Math.round(x+b)-Math.round(x)),_.clip()}const T=(w.extent[0]-m[0])*y,I=-(w.extent[3]-m[3])*y,O=Rt(w.extent)*y,P=Ee(w.extent)*y;_.drawImage(w.image,h,h,w.image.width-2*h,w.image.height-2*h,u?T:Math.round(T),u?I:Math.round(I),u?O:Math.round(T+O)-Math.round(T),u?P:Math.round(I+P)-Math.round(I)),w.clipExtent&&_.restore()}})}const S=fo(o);return a.getTriangles().forEach(function(w,C,M){const T=w.source,I=w.target;let O=T[0][0],P=T[0][1],D=T[1][0],x=T[1][1],E=T[2][0],b=T[2][1];const R=p((I[0][0]-S[0])/r),A=p(-(I[0][1]-S[1])/r),$=p((I[1][0]-S[0])/r),G=p(-(I[1][1]-S[1])/r),k=p((I[2][0]-S[0])/r),z=p(-(I[2][1]-S[1])/r),V=O,et=P;O=0,P=0,D-=V,x-=et,E-=V,b-=et;const F=[[D,x,0,0,$-R],[E,b,0,0,k-R],[0,0,D,x,G-A],[0,0,E,b,z-A]],ot=E9(F);if(!ot)return;if(f.save(),f.beginPath(),mK()||!u){f.moveTo($,G);const pt=4,Gt=R-$,Kt=A-G;for(let bt=0;btPromise.resolve(new Uint8ClampedArray(4)),interpolate:t.interpolate,transition:t.transition}),this.pixelRatio_=t.pixelRatio,this.gutter_=t.gutter,this.reprojData_=null,this.reprojError_=null,this.reprojSize_=void 0,this.sourceTileGrid_=t.sourceTileGrid,this.targetTileGrid_=t.targetTileGrid,this.wrappedTileCoord_=t.wrappedTileCoord||t.tileCoord,this.sourceTiles_=[],this.sourcesListenerKeys_=null,this.sourceZ_=0;const e=t.sourceProj,i=e.getExtent(),n=t.sourceTileGrid.getExtent();this.clipExtent_=e.canWrapX()?n?He(i,n):i:n;const r=this.targetTileGrid_.getTileCoordExtent(this.wrappedTileCoord_),o=this.targetTileGrid_.getExtent();let a=this.sourceTileGrid_.getExtent();const l=o?He(r,o):r;if(Cd(l)===0){this.state=X.EMPTY;return}i&&(a?a=He(a,i):a=i);const h=this.targetTileGrid_.getResolution(this.wrappedTileCoord_[0]),c=t.targetProj,u=dA(e,c,l,h);if(!isFinite(u)||u<=0){this.state=X.EMPTY;return}const d=t.errorThreshold!==void 0?t.errorThreshold:Zv;if(this.triangulation_=new Hv(e,c,l,a,u*d,h),this.triangulation_.getTriangles().length===0){this.state=X.EMPTY;return}this.sourceZ_=this.sourceTileGrid_.getZForResolution(u);let g=this.triangulation_.calculateSourceExtent();if(a&&(e.canWrapX()?(g[1]=Dt(g[1],a[1],a[3]),g[3]=Dt(g[3],a[1],a[3])):g=He(g,a)),!Cd(g))this.state=X.EMPTY;else{let f=0,p=0;e.canWrapX()&&(f=Rt(i),p=Math.floor((g[0]-i[0])/f)),Hx(g.slice(),e,!0).forEach(m=>{const _=this.sourceTileGrid_.getTileRangeForExtentAndZ(m,this.sourceZ_),y=t.getTileFunction;for(let v=_.minX;v<=_.maxX;v++)for(let S=_.minY;S<=_.maxY;S++){const w=y(this.sourceZ_,v,S,this.pixelRatio_);if(w){const C=p*f;this.sourceTiles_.push({tile:w,offset:C})}}++p}),this.sourceTiles_.length===0&&(this.state=X.EMPTY)}}getSize(){return this.reprojSize_}getData(){return this.reprojData_}getError(){return this.reprojError_}reproject_(){const t=[];let e=!1;if(this.sourceTiles_.forEach(f=>{var p;const m=f.tile;if(!m||m.getState()!==X.LOADED)return;const _=m.getSize(),y=this.gutter_;let v;const S=cy(m.getData());S?v=S:(e=!0,v=gK(uc(m.getData())));const w=[_[0]+2*y,_[1]+2*y],C=v instanceof Float32Array,M=w[0]*w[1],T=C?Float32Array:Uint8ClampedArray,I=new T(v.buffer),O=T.BYTES_PER_ELEMENT,P=O*I.length/M,D=I.byteLength/w[1],x=Math.floor(D/O/w[0]),E=M*x;let b=I;if(I.length!==E){b=new T(E);let $=0,G=0;const k=w[0]*x;for(let z=0;z=0;--f){const p=[];for(let w=0,C=t.length;w{const i=e.getState();if(i!==X.IDLE&&i!==X.LOADING)return;t++;const n=We(e,Zt.CHANGE,()=>{const r=e.getState();(r==X.LOADED||r==X.ERROR||r==X.EMPTY)&&(ms(n),t--,t===0&&(this.unlistenSources_(),this.reproject_()))});this.sourcesListenerKeys_.push(n)}),t===0?setTimeout(this.reproject_.bind(this),0):this.sourceTiles_.forEach(function({tile:e}){e.getState()==X.IDLE&&e.load()})}unlistenSources_(){this.sourcesListenerKeys_.forEach(ms),this.sourcesListenerKeys_=null}}class Ag extends Oc{constructor(t,e,i,n,r,o,a,l,h,c,u,d){super(r,X.IDLE,d),this.renderEdges_=u!==void 0?u:!1,this.pixelRatio_=a,this.gutter_=l,this.canvas_=null,this.sourceTileGrid_=e,this.targetTileGrid_=n,this.wrappedTileCoord_=o||r,this.sourceTiles_=[],this.sourcesListenerKeys_=null,this.sourceZ_=0,this.clipExtent_=t.canWrapX()?t.getExtent():void 0;const g=n.getTileCoordExtent(this.wrappedTileCoord_),f=this.targetTileGrid_.getExtent();let p=this.sourceTileGrid_.getExtent();const m=f?He(g,f):g;if(Cd(m)===0){this.state=X.EMPTY;return}const _=t.getExtent();_&&(p?p=He(p,_):p=_);const y=n.getResolution(this.wrappedTileCoord_[0]),v=dA(t,i,m,y);if(!isFinite(v)||v<=0){this.state=X.EMPTY;return}const S=c!==void 0?c:Zv;if(this.triangulation_=new Hv(t,i,m,p,v*S,y),this.triangulation_.getTriangles().length===0){this.state=X.EMPTY;return}this.sourceZ_=e.getZForResolution(v);let w=this.triangulation_.calculateSourceExtent();if(p&&(t.canWrapX()?(w[1]=Dt(w[1],p[1],p[3]),w[3]=Dt(w[3],p[1],p[3])):w=He(w,p)),!Cd(w))this.state=X.EMPTY;else{let C=0,M=0;t.canWrapX()&&(C=Rt(_),M=Math.floor((w[0]-_[0])/C)),Hx(w.slice(),t,!0).forEach(T=>{const I=e.getTileRangeForExtentAndZ(T,this.sourceZ_);for(let O=I.minX;O<=I.maxX;O++)for(let P=I.minY;P<=I.maxY;P++){const D=h(this.sourceZ_,O,P,a);if(D){const x=M*C;this.sourceTiles_.push({tile:D,offset:x})}}++M}),this.sourceTiles_.length===0&&(this.state=X.EMPTY)}}getImage(){return this.canvas_}reproject_(){const t=[];if(this.sourceTiles_.forEach(e=>{var i;const n=e.tile;if(n&&n.getState()==X.LOADED){const r=this.sourceTileGrid_.getTileCoordExtent(n.tileCoord);r[0]+=e.offset,r[2]+=e.offset;const o=(i=this.clipExtent_)==null?void 0:i.slice();o&&(o[0]+=e.offset,o[2]+=e.offset),t.push({extent:r,clipExtent:o,image:n.getImage()})}}),this.sourceTiles_.length=0,t.length===0)this.state=X.ERROR;else{const e=this.wrappedTileCoord_[0],i=this.targetTileGrid_.getTileSize(e),n=typeof i=="number"?i:i[0],r=typeof i=="number"?i:i[1],o=this.targetTileGrid_.getResolution(e),a=this.sourceTileGrid_.getResolution(this.sourceZ_),l=this.targetTileGrid_.getTileCoordExtent(this.wrappedTileCoord_);this.canvas_=Kv(n,r,this.pixelRatio_,a,this.sourceTileGrid_.getExtent(),o,l,this.triangulation_,t,this.gutter_,this.renderEdges_,this.interpolate),this.state=X.LOADED}this.changed()}load(){if(this.state==X.IDLE){this.state=X.LOADING,this.changed();let t=0;this.sourcesListenerKeys_=[],this.sourceTiles_.forEach(({tile:e})=>{const i=e.getState();if(i==X.IDLE||i==X.LOADING){t++;const n=We(e,Zt.CHANGE,r=>{const o=e.getState();(o==X.LOADED||o==X.ERROR||o==X.EMPTY)&&(ms(n),t--,t===0&&(this.unlistenSources_(),this.reproject_()))});this.sourcesListenerKeys_.push(n)}}),t===0?setTimeout(this.reproject_.bind(this),0):this.sourceTiles_.forEach(function({tile:e},i,n){e.getState()==X.IDLE&&e.load()})}}unlistenSources_(){this.sourcesListenerKeys_.forEach(ms),this.sourcesListenerKeys_=null}release(){this.canvas_&&(ol(this.canvas_.getContext("2d")),Jr.push(this.canvas_),this.canvas_=null),super.release()}}class Lg extends Oc{constructor(t,e,i,n,r,o){super(t,e,o),this.crossOrigin_=n,this.src_=i,this.key=i,this.image_=new Image,n!==null&&(this.image_.crossOrigin=n),this.unlisten_=null,this.tileLoadFunction_=r}getImage(){return this.image_}setImage(t){this.image_=t,this.state=X.LOADED,this.unlistenImage_(),this.changed()}handleImageError_(){this.state=X.ERROR,this.unlistenImage_(),this.image_=_K(),this.changed()}handleImageLoad_(){const t=this.image_;t.naturalWidth&&t.naturalHeight?this.state=X.LOADED:this.state=X.EMPTY,this.unlistenImage_(),this.changed()}load(){this.state==X.ERROR&&(this.state=X.IDLE,this.image_=new Image,this.crossOrigin_!==null&&(this.image_.crossOrigin=this.crossOrigin_)),this.state==X.IDLE&&(this.state=X.LOADING,this.changed(),this.tileLoadFunction_(this,this.src_),this.unlisten_=KB(this.image_,this.handleImageLoad_.bind(this),this.handleImageError_.bind(this)))}unlistenImage_(){this.unlisten_&&(this.unlisten_(),this.unlisten_=null)}}function _K(){const s=Se(1,1);return s.fillStyle="rgba(0,0,0,0)",s.fillRect(0,0,1,1),s.canvas}class yK extends fg{constructor(t){super(),this.tile,this.handleTileChange_=this.handleTileChange_.bind(this),this.gutter=t.gutter||0,this.helper=t.helper,this.loaded=!1,this.ready=!1}setTile(t){if(t!==this.tile)if(this.tile&&this.tile.removeEventListener(Zt.CHANGE,this.handleTileChange_),this.tile=t,this.loaded=t.getState()===X.LOADED,this.loaded)this.uploadTile();else{if(t instanceof Lg){const e=t.getImage();e instanceof Image&&!e.crossOrigin&&(e.crossOrigin="anonymous")}t.addEventListener(Zt.CHANGE,this.handleTileChange_)}}uploadTile(){vt()}setReady(){this.ready=!0,this.dispatchEvent(Zt.CHANGE)}handleTileChange_(){this.tile.getState()===X.LOADED&&(this.loaded=!0,this.uploadTile())}disposeInternal(){this.tile.removeEventListener(Zt.CHANGE,this.handleTileChange_)}}function gA(s,t,e){const i=e?s.LINEAR:s.NEAREST;s.bindTexture(s.TEXTURE_2D,t),s.texParameteri(s.TEXTURE_2D,s.TEXTURE_WRAP_S,s.CLAMP_TO_EDGE),s.texParameteri(s.TEXTURE_2D,s.TEXTURE_WRAP_T,s.CLAMP_TO_EDGE),s.texParameteri(s.TEXTURE_2D,s.TEXTURE_MIN_FILTER,i),s.texParameteri(s.TEXTURE_2D,s.TEXTURE_MAG_FILTER,i)}function xK(s,t,e,i){gA(s,t,i),s.texImage2D(s.TEXTURE_2D,0,s.RGBA,s.RGBA,s.UNSIGNED_BYTE,e)}function LM(s,t,e,i,n,r){const o=s.getGL();let a,l;e instanceof Float32Array?(a=o.FLOAT,s.getExtension("OES_texture_float"),l=s.getExtension("OES_texture_float_linear")!==null):(a=o.UNSIGNED_BYTE,l=!0),gA(o,t,r&&l);const h=e.byteLength/i[1];let c=1;h%8===0?c=8:h%4===0?c=4:h%2===0&&(c=2);let u;switch(n){case 1:{u=o.LUMINANCE;break}case 2:{u=o.LUMINANCE_ALPHA;break}case 3:{u=o.RGB;break}case 4:{u=o.RGBA;break}default:throw new Error(`Unsupported number of bands: ${n}`)}const d=o.getParameter(o.UNPACK_ALIGNMENT);o.pixelStorei(o.UNPACK_ALIGNMENT,c),o.texImage2D(o.TEXTURE_2D,0,u,i[0],i[1],0,u,a,e),o.pixelStorei(o.UNPACK_ALIGNMENT,d)}let Ql=null;function vK(){Ql=Se(1,1,void 0,{willReadFrequently:!0})}class wK extends yK{constructor(t){super(t),this.textures=[],this.renderSize_=Re(t.grid.getTileSize(t.tile.tileCoord[0])),this.bandCount=NaN;const e=new Wp(n0,qv);e.fromArray([0,1,1,1,1,0,0,0]),this.helper.flushBufferData(e),this.coords=e,this.setTile(t.tile)}uploadTile(){const t=this.helper,e=t.getGL(),i=this.tile;this.textures.length=0;let n;i instanceof Lg||i instanceof Ag?n=i.getImage():n=i.getData();const r=uc(n);if(r){const y=e.createTexture();this.textures.push(y),this.bandCount=4,xK(e,y,r,i.interpolate),this.setReady();return}n=cy(n);const o=i.getSize(),a=[o[0]+2*this.gutter,o[1]+2*this.gutter],l=n instanceof Float32Array,h=a[0]*a[1],c=l?Float32Array:Uint8Array,u=c.BYTES_PER_ELEMENT,d=n.byteLength/a[1];this.bandCount=Math.floor(d/u/a[0]);const g=Math.ceil(this.bandCount/4);if(g===1){const y=e.createTexture();this.textures.push(y),LM(t,y,n,a,this.bandCount,i.interpolate),this.setReady();return}const f=new Array(g);for(let y=0;y0&&this.getCount()>this.highWaterMark}expireCache(t){for(;this.canExpireCache();)this.pop()}clear(){this.count_=0,this.entries_={},this.oldest_=null,this.newest_=null}containsKey(t){return this.entries_.hasOwnProperty(t)}forEach(t){let e=this.oldest_;for(;e;)t(e.value_,e.key_,this),e=e.newer}get(t,e){const i=this.entries_[t];return qt(i!==void 0,"Tried to get a value for a key that does not exist in the cache"),i===this.newest_||(i===this.oldest_?(this.oldest_=this.oldest_.newer,this.oldest_.older=null):(i.newer.older=i.older,i.older.newer=i.newer),i.newer=null,i.older=this.newest_,this.newest_.newer=i,this.newest_=i),i.value_}remove(t){const e=this.entries_[t];return qt(e!==void 0,"Tried to get a value for a key that does not exist in the cache"),e===this.newest_?(this.newest_=e.older,this.newest_&&(this.newest_.newer=null)):e===this.oldest_?(this.oldest_=e.newer,this.oldest_&&(this.oldest_.older=null)):(e.newer.older=e.older,e.older.newer=e.newer),delete this.entries_[t],--this.count_,e.value_}getCount(){return this.count_}getKeys(){const t=new Array(this.count_);let e=0,i;for(i=this.newest_;i;i=i.older)t[e++]=i.key_;return t}getValues(){const t=new Array(this.count_);let e=0,i;for(i=this.newest_;i;i=i.older)t[e++]=i.value_;return t}peekLast(){return this.oldest_.value_}peekLastKey(){return this.oldest_.key_}peekFirstKey(){return this.newest_.key_}peek(t){var e;return(e=this.entries_[t])==null?void 0:e.value_}pop(){const t=this.oldest_;return delete this.entries_[t.key_],t.newer&&(t.newer.older=null),this.oldest_=t.newer,this.oldest_||(this.newest_=null),--this.count_,t.value_}replace(t,e){this.get(t),this.entries_[t].value_=e}set(t,e){qt(!(t in this.entries_),"Tried to set a value for a key that is used already");const i={key_:t,newer:null,older:this.newest_,value_:e};this.newest_?this.newest_.newer=i:this.oldest_=i,this.newest_=i,this.entries_[t]=i,++this.count_}setSize(t){this.highWaterMark=t}}class h0{constructor(t,e,i,n){this.minX=t,this.maxX=e,this.minY=i,this.maxY=n}contains(t){return this.containsXY(t[1],t[2])}containsTileRange(t){return this.minX<=t.minX&&t.maxX<=this.maxX&&this.minY<=t.minY&&t.maxY<=this.maxY}containsXY(t,e){return this.minX<=t&&t<=this.maxX&&this.minY<=e&&e<=this.maxY}equals(t){return this.minX==t.minX&&this.minY==t.minY&&this.maxX==t.maxX&&this.maxY==t.maxY}extend(t){t.minXthis.maxX&&(this.maxX=t.maxX),t.minYthis.maxY&&(this.maxY=t.maxY)}getHeight(){return this.maxY-this.minY+1}getSize(){return[this.getWidth(),this.getHeight()]}getWidth(){return this.maxX-this.minX+1}intersects(t){return this.minX<=t.maxX&&this.maxX>=t.minX&&this.minY<=t.maxY&&this.maxY>=t.minY}}function Gl(s,t,e,i,n){return n!==void 0?(n.minX=s,n.maxX=t,n.minY=e,n.maxY=i,n):new h0(s,t,e,i)}function ll(s,t,e,i){return i!==void 0?(i[0]=s,i[1]=t,i[2]=e,i):[s,t,e]}function ro(s,t,e){return s+"/"+t+"/"+e}function Do(s){return ro(s[0],s[1],s[2])}function EK(s){const[t,e,i]=s.substring(s.lastIndexOf("/")+1,s.length).split(",").map(Number);return ro(t,e,i)}function SK(s){return s.split("/").map(Number)}function Jv(s){return fA(s[0],s[1],s[2])}function fA(s,t,e){return(t<e||e>t.getMaxZoom())return!1;const r=t.getFullTileRange(e);return r?r.containsXY(i,n):!0}const bK={TILE_TRANSFORM:"u_tileTransform",TRANSITION_ALPHA:"u_transitionAlpha",DEPTH:"u_depth",RENDER_EXTENT:"u_renderExtent",PATTERN_ORIGIN:"u_patternOrigin",RESOLUTION:"u_resolution",ZOOM:"u_zoom",GLOBAL_ALPHA:"u_globalAlpha",PROJECTION_MATRIX:"u_projectionMatrix",SCREEN_TO_WORLD_MATRIX:"u_screenToWorldMatrix"},CK={};function OM(s){return 1/(s+2)}function TK(){return{tileIds:new Set,representationsByZ:{}}}function FM(s,t){return s.tileIds.has(mt(t))}function NM(s,t,e){const i=s.representationsByZ;e in i||(i[e]=new Set),i[e].add(t),s.tileIds.add(mt(t.tile))}function $_(s,t){const e=s.layerStatesArray[s.layerIndex];e.extent&&(t=He(t,cn(e.extent,s.viewState.projection)));const i=e.layer.getRenderSource();if(!i.getWrapX()){const n=i.getTileGridForProjection(s.viewState.projection).getExtent();n&&(t=He(t,n))}return t}function uy(s,t){return`${s.getKey()},${Do(t)}`}class RK extends o0{constructor(t,e){super(t,{uniforms:e.uniforms,postProcesses:e.postProcesses}),this.renderComplete=!1,this.tileTransform_=ss(),this.tempMat4=lA(),this.tempTileRange_=new h0(0,0,0,0),this.tempTileCoord_=ll(0,0,0),this.tempSize_=[0,0];const i=e.cacheSize!==void 0?e.cacheSize:512;this.tileRepresentationCache=new l0(i),this.frameState=null,this.projection_=void 0}reset(t){super.reset({uniforms:t.uniforms})}prepareFrameInternal(t){this.projection_?t.viewState.projection!==this.projection_&&(this.clearCache(),this.projection_=t.viewState.projection):this.projection_=t.viewState.projection;const e=this.getLayer().getRenderSource();return!e||po($_(t,t.extent))?!1:e.getState()==="ready"}createTileRepresentation(t){return vt()}enqueueTiles(t,e,i,n,r){const o=t.viewState,a=this.getLayer(),l=a.getRenderSource(),h=l.getTileGridForProjection(o.projection),c=l.getGutterForProjection(o.projection),u=mt(l);u in t.wantedTiles||(t.wantedTiles[u]={});const d=t.wantedTiles[u],g=this.tileRepresentationCache,f=a.getMapInternal(),p=Math.max(i-r,h.getMinZoom(),h.getZForResolution(Math.min(a.getMaxResolution(),f?f.getView().getResolutionForZoom(Math.max(a.getMinZoom(),0)):h.getResolution(0)),l.zDirection));for(let m=i;m>=p;--m){const _=h.getTileRangeForExtentAndZ(e,m,this.tempTileRange_),y=h.getResolution(m);for(let v=_.minX;v<=_.maxX;++v)for(let S=_.minY;S<=_.maxY;++S){const w=ll(m,v,S,this.tempTileCoord_),C=uy(l,w);let M,T;if(g.containsKey(C)&&(M=g.get(C),T=M.tile),(!M||M.tile.key!==l.getKey())&&(T=l.getTile(m,v,S,t.pixelRatio,o.projection),!T)||FM(n,T))continue;M?M.setTile(T):(M=this.createTileRepresentation({tile:T,grid:h,helper:this.helper,gutter:c}),g.set(C,M)),NM(n,M,m);const I=T.getKey();d[I]=!0,T.getState()===X.IDLE&&(t.tileQueue.isKeyQueued(I)||t.tileQueue.enqueue([T,u,h.getTileCoordCenter(w),y]))}}}beforeTilesRender(t,e){this.helper.prepareDraw(this.frameState,!e,!0)}beforeTilesMaskRender(t){return!1}renderTile(t,e,i,n,r,o,a,l,h,c,u){}renderTileMask(t,e,i,n){}drawTile_(t,e,i,n,r,o,a){if(!e.ready)return;const l=e.tile.tileCoord,h=Do(l),c=h in o?o[h]:1,u=a.getResolution(i),d=Re(a.getTileSize(i),this.tempSize_),g=a.getOrigin(i),f=a.getTileCoordExtent(l),p=c<1?-1:OM(i);c<1&&(t.animate=!0);const m=t.viewState,_=m.center[0],y=m.center[1],v=d[0]+2*n,S=d[1]+2*n,w=v/S,C=(_-g[0])/(d[0]*u),M=(g[1]-y)/(d[1]*u),T=m.resolution/u,I=l[1],O=l[2];j1(this.tileTransform_),Bu(this.tileTransform_,2/(t.size[0]*T/v),-2/(t.size[1]*T/v)),s9(this.tileTransform_,m.rotation),Bu(this.tileTransform_,1,1/w),Wx(this.tileTransform_,(d[0]*(I-C)-n)/v,(d[1]*(O-M)-n)/S),this.renderTile(e,this.tileTransform_,t,r,u,d,g,f,p,n,c)}renderFrame(t){this.frameState=t,this.renderComplete=!0;const e=this.helper.getGL();this.preRender(e,t);const i=t.viewState,n=this.getLayer(),r=n.getRenderSource(),o=r.getTileGridForProjection(i.projection),a=r.getGutterForProjection(i.projection),l=$_(t,t.extent),h=o.getZForResolution(i.resolution,r.zDirection),c=TK(),u=n.getPreload();if(t.nextExtent){const w=o.getZForResolution(i.nextResolution,r.zDirection),C=$_(t,t.nextExtent);this.enqueueTiles(t,C,w,c,u)}this.enqueueTiles(t,l,h,c,0),u>0&&setTimeout(()=>{this.enqueueTiles(t,l,h-1,c,u-1)},0);const d={},g=mt(this),f=t.time;let p=!1;const m=c.representationsByZ;if(h in m)for(const w of m[h]){const C=w.tile;if((C instanceof Ag||C instanceof a0)&&C.getState()===X.EMPTY)continue;const M=C.tileCoord;if(w.ready){const I=C.getAlpha(g,f);if(I===1){C.endTransition(g);continue}p=!0;const O=Do(M);d[O]=I}if(this.renderComplete=!1,this.findAltTiles_(o,M,h+1,c))continue;const T=o.getMinZoom();for(let I=h-1;I>=T&&!this.findAltTiles_(o,M,I,c);--I);}const _=Object.keys(m).map(Number).sort(qU);if(this.beforeTilesMaskRender(t))for(let w=0,C=_.length;we.dispose()),t.clear()}removeHelper(){this.helper&&this.clearCache(),super.removeHelper()}disposeInternal(){super.disposeInternal(),delete this.frameState}}const jt={...bK,TILE_TEXTURE_ARRAY:"u_tileTextures",TEXTURE_PIXEL_WIDTH:"u_texturePixelWidth",TEXTURE_PIXEL_HEIGHT:"u_texturePixelHeight",TEXTURE_RESOLUTION:"u_textureResolution",TEXTURE_ORIGIN_X:"u_textureOriginX",TEXTURE_ORIGIN_Y:"u_textureOriginY"},Gf={TEXTURE_COORD:"a_textureCoord"},IK=[{name:Gf.TEXTURE_COORD,size:2,type:nr.FLOAT}];class PK extends RK{constructor(t,e){super(t,e),this.program_,this.vertexShader_=e.vertexShader,this.fragmentShader_=e.fragmentShader,this.indices_=new Wp(r0,qv),this.indices_.fromArray([0,1,3,1,2,3]),this.paletteTextures_=e.paletteTextures||[]}reset(t){if(super.reset(t),this.helper){const e=this.helper.getGL();for(const i of this.paletteTextures_)i.delete(e)}this.vertexShader_=t.vertexShader,this.fragmentShader_=t.fragmentShader,this.paletteTextures_=t.paletteTextures||[],this.helper&&(this.program_=this.helper.getProgram(this.fragmentShader_,this.vertexShader_))}afterHelperCreated(){this.program_=this.helper.getProgram(this.fragmentShader_,this.vertexShader_),this.helper.flushBufferData(this.indices_)}removeHelper(){if(this.helper){const t=this.helper.getGL();for(const e of this.paletteTextures_)e.delete(t)}super.removeHelper()}createTileRepresentation(t){return new wK(t)}beforeTilesRender(t,e){super.beforeTilesRender(t,e),this.helper.useProgram(this.program_,t)}renderTile(t,e,i,n,r,o,a,l,h,c,u){const d=this.helper.getGL();this.helper.bindBuffer(t.coords),this.helper.bindBuffer(this.indices_),this.helper.enableAttributes(IK);let g=0;for(;g0&&(S=l,He(S,n,S)),this.helper.setUniformFloatVec4(jt.RENDER_EXTENT,S),this.helper.setUniformFloatValue(jt.RESOLUTION,f.resolution),this.helper.setUniformFloatValue(jt.ZOOM,f.zoom),this.helper.setUniformFloatValue(jt.TEXTURE_PIXEL_WIDTH,p),this.helper.setUniformFloatValue(jt.TEXTURE_PIXEL_HEIGHT,m),this.helper.setUniformFloatValue(jt.TEXTURE_RESOLUTION,r),this.helper.setUniformFloatValue(jt.TEXTURE_ORIGIN_X,a[0]+y*o[0]*r-c*r),this.helper.setUniformFloatValue(jt.TEXTURE_ORIGIN_Y,a[1]-v*o[1]*r+c*r),this.helper.drawElements(0,this.indices_.getSize())}getData(t){if(!this.helper.getGL())return null;const e=this.frameState;if(!e)return null;const i=this.getLayer(),n=Ye(e.pixelToCoordinateTransform,t.slice()),r=e.viewState,o=i.getExtent();if(o&&!Yi(cn(o,r.projection),n))return null;const a=i.getSources(ic([n]),r.resolution);let l,h,c;for(l=a.length-1;l>=0;--l)if(h=a[l],h.getState()==="ready"){if(c=h.getTileGridForProjection(r.projection),h.getWrapX())break;const d=c.getExtent();if(!d||Yi(d,n))break}if(l<0)return null;const u=this.tileRepresentationCache;for(let d=c.getZForResolution(r.resolution);d>=c.getMinZoom();--d){const g=c.getTileCoordForCoordAndZ(n,d),f=uy(h,g);if(!u.containsKey(f))continue;const p=u.get(f),m=p.tile;if((m instanceof Ag||m instanceof a0)&&m.getState()===X.EMPTY)return null;if(!p.loaded)continue;const _=c.getOrigin(d),y=Re(c.getTileSize(d)),v=c.getResolution(d),S=(n[0]-_[0])/v-g[1]*y[0],w=(_[1]-n[1])/v-g[2]*y[1];return p.getPixelData(S,w)}return null}disposeInternal(){const t=this.helper;if(t){const e=t.getGL();for(const i of this.paletteTextures_)i.delete(e);this.paletteTextures_.length=0,e.deleteProgram(this.program_),delete this.program_,t.deleteBuffer(this.indices_)}super.disposeInternal(),delete this.indices_}}function AK(s,t){return`operator_${s}_${Object.keys(t.functions).length}`}function Ya(s){const t=s.toString();return t.includes(".")?t:t+".0"}function c0(s){if(s.length<2||s.length>4)throw new Error("`formatArray` can only output `vec2`, `vec3` or `vec4` arrays.");return`vec${s.length}(${s.map(Ya).join(", ")})`}function jf(s){const t=Bn(s),e=t.length>3?t[3]:1;return c0([t[0]/255*e,t[1]/255*e,t[2]/255*e,e])}function LK(s){const t=Re(s);return c0(t)}const G_={};let OK=0;function Vp(s){return s in G_||(G_[s]=OK++),G_[s]}function $r(s){return Ya(Vp(s))}function Qv(s){return"u_var_"+s}function FK(){return{inFragmentShader:!1,variables:{},properties:{},functions:{},bandCount:0,style:{}}}const j_="getBandValue",pA="u_paletteTextures";function NK(s,t,e,i){const n=Ts(s,t,e);return tw(n,t,i)}function re(s){return(t,e,i)=>{const n=e.args.length,r=new Array(n);for(let o=0;o{const e=t.args[0].value;return e in s.properties||(s.properties[e]={name:e,type:t.type}),(s.inFragmentShader?"v_prop_":"a_prop_")+e},[U.GeometryType]:(s,t,e)=>{const i="geometryType";return i in s.properties||(s.properties[i]={name:i,type:bs,evaluator:n=>Bv(n.getGeometry())}),(s.inFragmentShader?"v_prop_":"a_prop_")+i},[U.Var]:(s,t)=>{const e=t.args[0].value;return e in s.variables||(s.variables[e]={name:e,type:t.type}),Qv(e)},[U.Resolution]:()=>"u_resolution",[U.Zoom]:()=>"u_zoom",[U.Time]:()=>"u_time",[U.Any]:re(s=>`(${s.join(" || ")})`),[U.All]:re(s=>`(${s.join(" && ")})`),[U.Not]:re(([s])=>`(!${s})`),[U.Equal]:re(([s,t])=>`(${s} == ${t})`),[U.NotEqual]:re(([s,t])=>`(${s} != ${t})`),[U.GreaterThan]:re(([s,t])=>`(${s} > ${t})`),[U.GreaterThanOrEqualTo]:re(([s,t])=>`(${s} >= ${t})`),[U.LessThan]:re(([s,t])=>`(${s} < ${t})`),[U.LessThanOrEqualTo]:re(([s,t])=>`(${s} <= ${t})`),[U.Multiply]:re(s=>`(${s.join(" * ")})`),[U.Divide]:re(([s,t])=>`(${s} / ${t})`),[U.Add]:re(s=>`(${s.join(" + ")})`),[U.Subtract]:re(([s,t])=>`(${s} - ${t})`),[U.Clamp]:re(([s,t,e])=>`clamp(${s}, ${t}, ${e})`),[U.Mod]:re(([s,t])=>`mod(${s}, ${t})`),[U.Pow]:re(([s,t])=>`pow(${s}, ${t})`),[U.Abs]:re(([s])=>`abs(${s})`),[U.Floor]:re(([s])=>`floor(${s})`),[U.Ceil]:re(([s])=>`ceil(${s})`),[U.Round]:re(([s])=>`floor(${s} + 0.5)`),[U.Sin]:re(([s])=>`sin(${s})`),[U.Cos]:re(([s])=>`cos(${s})`),[U.Atan]:re(([s,t])=>t!==void 0?`atan(${s}, ${t})`:`atan(${s})`),[U.Sqrt]:re(([s])=>`sqrt(${s})`),[U.Match]:re(s=>{const t=s[0],e=s[s.length-1];let i=null;for(let n=s.length-3;n>=1;n-=2){const r=s[n],o=s[n+1];i=`(${t} == ${r} ? ${o} : ${i||e})`}return i}),[U.Between]:re(([s,t,e])=>`(${s} >= ${t} && ${s} <= ${e})`),[U.Interpolate]:re(([s,t,...e])=>{let i="";for(let n=0;n{const t=s[s.length-1];let e=null;for(let i=s.length-3;i>=0;i-=2){const n=s[i],r=s[i+1];e=`(${n} ? ${r} : ${e||t})`}return e}),[U.In]:re(([s,...t],e)=>{const i=AK("in",e),n=[];for(let r=0;rthis.gradient_,u_opacity:()=>this.getOpacity()}}]})}renderDeclutter(){}}function jK(s){const t=Se(1,256),e=t.createLinearGradient(0,0,1,256),i=1/(s.length-1);for(let n=0,r=s.length;n=a.width)return null;const c=Ee(o),u=Math.floor(a.height*((o[3]-n[1])/c));return u<0||u>=a.height?null:this.getImageData(a,h,u)}renderFrame(t,e){const i=this.image,n=i.getExtent(),r=i.getResolution(),[o,a]=Array.isArray(r)?r:[r,r],l=i.getPixelRatio(),h=t.layerStatesArray[t.layerIndex],c=t.pixelRatio,u=t.viewState,d=u.center,g=u.resolution,f=c*o/(g*l),p=c*a/(g*l);this.prepareContainer(t,e);const m=this.context.canvas.width,_=this.context.canvas.height,y=this.getRenderContext(t);let v=!1,S=!0;if(h.extent){const I=cn(h.extent,u.projection);S=Te(I,t.extent),v=S&&!ai(I,t.extent),v&&this.clipUnrotated(y,t,I)}const w=i.getImage(),T=xn(this.tempTransform,m/2,_/2,f,p,0,l*(n[0]-d[0])/o,l*(d[1]-n[3])/a);this.renderedResolution=a*c/l;const M=w.width*T[0],C=w.height*T[3];if(this.getLayer().getSource().getInterpolate()||(y.imageSmoothingEnabled=!1),this.preRender(y,t),S&&M>=.5&&C>=.5){const I=T[4],O=T[5],P=h.opacity;P!==1&&(y.save(),y.globalAlpha=P),y.drawImage(w,0,0,+w.width,+w.height,I,O,M,C),P!==1&&y.restore()}return this.postRender(this.context,t),v&&y.restore(),y.imageSmoothingEnabled=!0,this.container}}class ew extends UK{constructor(t){super(t)}createRenderer(){return new _A(this)}getData(t){return super.getData(t)}}const Zo={PRELOAD:"preload",USE_INTERIM_TILES_ON_ERROR:"useInterimTilesOnError"};class yA extends Cg{constructor(t){t=t||{};const e=Object.assign({},t),i=t.cacheSize;delete t.cacheSize,delete e.preload,delete e.useInterimTilesOnError,super(e),this.on,this.once,this.un,this.cacheSize_=i,this.setPreload(t.preload!==void 0?t.preload:0),this.setUseInterimTilesOnError(t.useInterimTilesOnError!==void 0?t.useInterimTilesOnError:!0)}getCacheSize(){return this.cacheSize_}getPreload(){return this.get(Zo.PRELOAD)}setPreload(t){this.set(Zo.PRELOAD,t)}getUseInterimTilesOnError(){return this.get(Zo.USE_INTERIM_TILES_ON_ERROR)}setUseInterimTilesOnError(t){this.set(Zo.USE_INTERIM_TILES_ON_ERROR,t)}getData(t){return super.getData(t)}}function z_(s,t,e,i){return`${s},${ro(t,e,i)}`}function U_(s,t,e){if(!(e in s))return s[e]=new Set([t]),!0;const i=s[e],n=i.has(t);return n||i.add(t),!n}function BK(s,t,e){const i=s[e];return i?i.delete(t):!1}function DM(s,t){const e=s.layerStatesArray[s.layerIndex];e.extent&&(t=He(t,cn(e.extent,s.viewState.projection)));const i=e.layer.getRenderSource();if(!i.getWrapX()){const n=i.getTileGridForProjection(s.viewState.projection).getExtent();n&&(t=He(t,n))}return t}class xA extends Vv{constructor(t,e){super(t),e=e||{},this.extentChanged=!0,this.renderComplete=!1,this.renderedExtent_=null,this.renderedPixelRatio,this.renderedProjection=null,this.renderedRevision,this.renderedTiles=[],this.renderedSourceKey_,this.renderedSourceRevision_,this.tempExtent=Zs(),this.tempTileRange_=new h0(0,0,0,0),this.tempTileCoord_=ll(0,0,0);const i=e.cacheSize!==void 0?e.cacheSize:512;this.tileCache_=new l0(i),this.maxStaleKeys=i*.5}getTileCache(){return this.tileCache_}getOrCreateTile(t,e,i,n){const r=this.tileCache_,o=this.getLayer().getSource(),a=z_(o.getKey(),t,e,i);let l;if(r.containsKey(a))l=r.get(a);else{if(l=o.getTile(t,e,i,n.pixelRatio,n.viewState.projection),!l)return null;r.set(a,l)}return l}getTile(t,e,i,n){return this.getOrCreateTile(t,e,i,n)||null}getData(t){const e=this.frameState;if(!e)return null;const i=this.getLayer(),n=Ye(e.pixelToCoordinateTransform,t.slice()),r=i.getExtent();if(r&&!Yi(r,n))return null;const o=e.viewState,a=i.getRenderSource(),l=a.getTileGridForProjection(o.projection),h=a.getTilePixelRatio(e.pixelRatio);for(let c=l.getZForResolution(o.resolution);c>=l.getMinZoom();--c){const u=l.getTileCoordForCoordAndZ(n,c),d=this.getTile(c,u[1],u[2],e);if(!d||d.getState()!==X.LOADED)continue;const g=l.getOrigin(c),f=Re(l.getTileSize(c)),p=l.getResolution(c);let m;if(d instanceof Lg)m=d.getImage();else if(d instanceof kd){if(m=uc(d.getData()),!m)continue}else continue;const _=Math.floor(h*((n[0]-g[0])/p-u[1]*f[0])),y=Math.floor(h*((g[1]-n[1])/p-u[2]*f[1])),v=Math.round(h*a.getGutterForProjection(o.projection));return this.getImageData(m,_+v,y+v)}return null}prepareFrame(t){const e=this.getLayer().getSource();if(!e)return!1;const i=this.getLayer().getSource().getRevision();return this.renderedRevision_?this.renderedRevision_!==i&&(this.renderedRevision_=i,this.renderedSourceKey_===e.getKey()&&this.tileCache_.clear()):this.renderedRevision_=i,!0}enqueueTiles(t,e,i,n,r){const o=t.viewState,a=this.getLayer(),l=a.getRenderSource(),h=l.getTileGridForProjection(o.projection),c=mt(l);c in t.wantedTiles||(t.wantedTiles[c]={});const u=t.wantedTiles[c],d=a.getMapInternal(),g=Math.max(i-r,h.getMinZoom(),h.getZForResolution(Math.min(a.getMaxResolution(),d?d.getView().getResolutionForZoom(Math.max(a.getMinZoom(),0)):h.getResolution(0)),l.zDirection));for(let f=i;f>=g;--f){const p=h.getTileRangeForExtentAndZ(e,f,this.tempTileRange_),m=h.getResolution(f);for(let _=p.minX;_<=p.maxX;++_)for(let y=p.minY;y<=p.maxY;++y){const v=this.getTile(f,_,y,t);if(!v||!U_(n,v,f))continue;const S=v.getKey();if(u[S]=!0,v.getState()===X.IDLE&&!t.tileQueue.isKeyQueued(S)){const w=ll(f,_,y,this.tempTileCoord_);t.tileQueue.enqueue([v,c,h.getTileCoordCenter(w),m])}}}}findStaleTile_(t,e){const i=this.tileCache_,n=t[0],r=t[1],o=t[2],a=this.getStaleKeys();for(let l=0;l0&&setTimeout(()=>{this.enqueueTiles(t,O,g-1,C,I-1)},0);const P=mt(this),D=t.time;for(const k of C[g]){const z=k.getState();if((k instanceof Ag||k instanceof a0)&&z===X.EMPTY)continue;const V=k.tileCoord;if(z===X.LOADED&&k.getAlpha(P,D)===1){k.endTransition(P);continue}if(this.renderComplete=!1,this.findStaleTile_(V,C)){BK(C,k,g),t.animate=!0;continue}if(this.findAltTiles_(d,V,g+1,C))continue;const et=d.getMinZoom();for(let F=g-1;F>=et&&!this.findAltTiles_(d,V,F,C);--F);}const x=f/o*l/_,E=this.getRenderContext(t);xn(this.tempTransform,y/2,v/2,x,x,0,-y/2,-v/2),i.extent&&this.clipUnrotated(E,t,S),c.getInterpolate()||(E.imageSmoothingEnabled=!1),this.preRender(E,t),this.renderedTiles.length=0;const b=Object.keys(C).map(Number);b.sort(fr);let R;const A=[],$=[];for(let k=b.length-1;k>=0;--k){const z=b[k],V=c.getTilePixelSize(z,l,r),et=d.getResolution(z)/f,F=V[0]*et*x,ot=V[1]*et*x,ht=d.getTileCoordForCoordAndZ(fo(M),z),pt=d.getTileCoordExtent(ht),Gt=Ye(this.tempTransform,[_*(pt[0]-M[0])/f,_*(M[3]-pt[3])/f]),Kt=_*c.getGutterForProjection(r);for(const bt of C[z]){if(bt.getState()!==X.LOADED)continue;const oe=bt.tileCoord,Pe=ht[1]-oe[1],hs=Math.round(Gt[0]-(Pe-1)*F),rs=ht[2]-oe[2],Ge=Math.round(Gt[1]-(rs-1)*ot),ve=Math.round(Gt[0]-Pe*F),Ke=Math.round(Gt[1]-rs*ot),Ni=hs-ve,Di=Ge-Ke,Mn=b.length===1;let Ks=!1;R=[ve,Ke,ve+Ni,Ke,ve+Ni,Ke+Di,ve,Ke+Di];for(let ki=0,$i=A.length;ki<$i;++ki)if(!Mn&&z<$[ki]){const Jt=A[ki];Te([ve,Ke,ve+Ni,Ke+Di],[Jt[0],Jt[3],Jt[4],Jt[7]])&&(Ks||(E.save(),Ks=!0),E.beginPath(),E.moveTo(R[0],R[1]),E.lineTo(R[2],R[3]),E.lineTo(R[4],R[5]),E.lineTo(R[6],R[7]),E.moveTo(Jt[6],Jt[7]),E.lineTo(Jt[4],Jt[5]),E.lineTo(Jt[2],Jt[3]),E.lineTo(Jt[0],Jt[1]),E.clip())}A.push(R),$.push(z),this.drawTile(bt,t,ve,Ke,Ni,Di,Kt,Mn),Ks&&E.restore(),this.renderedTiles.unshift(bt),this.updateUsedTiles(t.usedTiles,c,bt)}}this.renderedRevision=u,this.renderedResolution=f,this.extentChanged=!this.renderedExtent_||!so(this.renderedExtent_,M),this.renderedExtent_=M,this.renderedPixelRatio=l,this.renderedProjection=r,this.postRender(this.context,t),i.extent&&E.restore(),E.imageSmoothingEnabled=!0;const G=(k,z)=>{const V=mt(c),et=z.wantedTiles[V],F=et?Object.keys(et).length:0;this.updateCacheSize(F),this.tileCache_.expireCache()};return t.postRenderFunctions.push(G),this.container}updateCacheSize(t){this.tileCache_.highWaterMark=Math.max(this.tileCache_.highWaterMark,t*2)}drawTile(t,e,i,n,r,o,a,l){let h;if(t instanceof kd){if(h=uc(t.getData()),!h)throw new Error("Rendering array data is not yet supported")}else h=this.getTileImage(t);if(!h)return;const c=this.getRenderContext(e),u=mt(this),d=e.layerStatesArray[e.layerIndex],g=d.opacity*(l?t.getAlpha(u,e.time):1),f=g!==c.globalAlpha;f&&(c.save(),c.globalAlpha=g),c.drawImage(h,a,a,h.width-2*a,h.height-2*a,i,n,r,o),f&&c.restore(),g!==d.opacity?e.animate=!0:l&&t.endTransition(u)}getImage(){const t=this.context;return t?t.canvas:null}getTileImage(t){return t.getImage()}updateUsedTiles(t,e,i){const n=mt(e);n in t||(t[n]={}),t[n][i.getKey()]=!0}}class Yp extends yA{constructor(t){super(t)}createRenderer(){return new xA(this,{cacheSize:this.getCacheSize()})}}class sw extends Wm{constructor(t,e,i,n,r){const o=r!==void 0?it.IDLE:it.LOADED;super(t,e,i,o),this.loader_=r!==void 0?r:null,this.canvas_=n,this.error_=null}getError(){return this.error_}handleLoad_(t){t?(this.error_=t,this.state=it.ERROR):this.state=it.LOADED,this.changed()}load(){this.state==it.IDLE&&(this.state=it.LOADING,this.changed(),this.loader_(this.handleLoad_.bind(this)))}getImage(){return this.canvas_}}function qp(s){return Array.isArray(s)?Math.min(...s):s}class WK extends _A{constructor(t){super(t),this.vectorRenderer_=new nA(t),this.layerImageRatio_=t.getImageRatio(),this.coordinateToVectorPixelTransform_=ss(),this.renderedPixelToCoordinateTransform_=null}disposeInternal(){this.vectorRenderer_.dispose(),super.disposeInternal()}getFeatures(t){if(!this.vectorRenderer_)return Promise.resolve([]);const e=Ye(this.coordinateToVectorPixelTransform_,Ye(this.renderedPixelToCoordinateTransform_,t.slice()));return this.vectorRenderer_.getFeatures(e)}handleFontsChanged(){this.vectorRenderer_.handleFontsChanged()}prepareFrame(t){const e=t.pixelRatio,i=t.viewState,n=i.resolution,r=t.viewHints,o=this.vectorRenderer_;let a=t.extent;this.layerImageRatio_!==1&&(a=a.slice(0),gI(a,this.layerImageRatio_));const l=Rt(a)/n,h=Ee(a)/n;if(!r[Ie.ANIMATING]&&!r[Ie.INTERACTING]&&!po(a)){o.useContainer(null,null);const c=o.context,u=t.layerStatesArray[t.layerIndex],d=Object.assign({},u,{opacity:1}),g=Object.assign({},t,{extent:a,size:[l,h],viewState:Object.assign({},t.viewState,{rotation:0}),layerStatesArray:[d],layerIndex:0,declutter:null}),f=this.getLayer().getDeclutter();f&&(g.declutter={[f]:new jv(9)});let p=!0;const m=new sw(a,n,e,c.canvas,function(_){o.prepareFrame(g)&&o.replayGroupChanged&&(o.clipping=!1,o.renderFrame(g,null)&&(o.renderDeclutter(g),o.renderDeferred(g),p=!1),_())});m.addEventListener(Zt.CHANGE,()=>{if(m.getState()!==it.LOADED)return;this.image=p?null:m;const _=m.getPixelRatio(),y=qp(m.getResolution())*e/_;this.renderedResolution=y,this.coordinateToVectorPixelTransform_=xn(this.coordinateToVectorPixelTransform_,l/2,h/2,1/y,-1/y,0,-i.center[0],-i.center[1])}),m.load()}return this.image&&(this.renderedPixelToCoordinateTransform_=t.pixelToCoordinateTransform.slice()),!!this.image}preRender(){}postRender(){}renderDeclutter(){}forEachFeatureAtCoordinate(t,e,i,n,r){return this.vectorRenderer_?this.vectorRenderer_.forEachFeatureAtCoordinate(t,e,i,n,r):super.forEachFeatureAtCoordinate(t,e,i,n,r)}}class XK extends Ig{constructor(t){t=t||{};const e=Object.assign({},t);delete e.imageRatio,super(e),this.imageRatio_=t.imageRatio!==void 0?t.imageRatio:1}getImageRatio(){return this.imageRatio_}createRenderer(){return new WK(this)}}const VK=XK,YK={image:["Polygon","Circle","LineString","Image","Text"],hybrid:["Polygon","LineString"],vector:[]},kM={hybrid:["Image","Text","Default"],vector:["Polygon","Circle","LineString","Image","Text","Default"]};class qK extends xA{constructor(t,e){super(t,e),this.boundHandleStyleImageChange_=this.handleStyleImageChange_.bind(this),this.renderedLayerRevision_,this.renderedPixelToCoordinateTransform_=null,this.renderedRotation_,this.renderedOpacity_=1,this.tmpTransform_=ss(),this.tileClipContexts_=null}drawTile(t,e,i,n,r,o,a,l){this.updateExecutorGroup_(t,e.pixelRatio,e.viewState.projection),this.tileImageNeedsRender_(t)&&this.renderTileImage_(t,e),super.drawTile(t,e,i,n,r,o,a,l)}getTile(t,e,i,n){const r=this.getOrCreateTile(t,e,i,n);if(!r)return null;const o=n.viewState.resolution,a=n.viewHints;return(!(a[Ie.ANIMATING]||a[Ie.INTERACTING])||!r.wantedResolution)&&(r.wantedResolution=o),r}prepareFrame(t){const e=this.getLayer().getRevision();return this.renderedLayerRevision_!==e&&(this.renderedLayerRevision_=e,this.renderedTiles.length=0),super.prepareFrame(t)}updateExecutorGroup_(t,e,i){const n=this.getLayer(),r=n.getRevision(),o=n.getRenderOrder()||null,a=t.wantedResolution,l=t.getReplayState(n);if(!l.dirty&&l.renderedResolution===a&&l.renderedRevision==r&&l.renderedRenderOrder==o)return;const h=n.getSource(),c=!!n.getDeclutter(),u=h.getTileGrid(),d=h.getTileGridForProjection(i).getTileCoordExtent(t.wrappedTileCoord),g=h.getSourceTiles(e,i,t),f=mt(n);delete t.hitDetectionImageData[f],t.executorGroups[f]=[],l.dirty=!1;for(let p=0,m=g.length;p{const M=w?e.declutter[w].all().map(C=>C.value):null;for(let C=0,I=T.length;C{const n=this.getLayer(),r=mt(n),o=n.getSource(),a=this.renderedProjection,l=a.getExtent(),h=this.renderedResolution,c=o.getTileGridForProjection(a),u=Ye(this.renderedPixelToCoordinateTransform_,t.slice()),d=c.getTileCoordForCoordAndResolution(u,h);let g;for(let v=0,S=this.renderedTiles.length;v0){e([]);return}const f=c.getTileCoordExtent(g.wrappedTileCoord),p=fo(f),m=[(u[0]-p[0])/h,(p[1]-u[1])/h],_=g.getSourceTiles().reduce(function(v,S){return v.concat(S.getFeatures())},[]);let y=g.hitDetectionImageData[r];if(!y){const v=Re(c.getTileSize(c.getZForResolution(h,o.zDirection))),S=this.renderedRotation_,w=[this.getRenderTransform(c.getTileCoordCenter(g.wrappedTileCoord),h,0,Xi,v[0]*Xi,v[1]*Xi,0)];y=QP(v,w,_,n.getStyleFunction(),c.getTileCoordExtent(g.wrappedTileCoord),g.getReplayState(n).renderedResolution,S),g.hitDetectionImageData[r]=y}e(tA(m,_,y))})}getFeaturesInExtent(t){const e=[],i=this.getTileCache();if(i.getCount()===0)return e;const n=this.getLayer().getSource().tileGrid,r=n.getZForResolution(this.renderedResolution);return i.forEach(o=>{if(o.tileCoord[0]!==r||o.getState()!==X.LOADED)return;const a=o.getSourceTiles();for(let l=0,h=a.length;l=0;--g)u[g].execute(this.context,[this.context.canvas.width,this.context.canvas.height],this.getTileRenderTransform(c,t),t.viewState.rotation,o,zp,d?t.declutter[d]:void 0)}i.globalAlpha=n}renderDeferredInternal(t){const e=this.renderedTiles.reduce((r,o,a)=>(o.executorGroups[mt(this.getLayer())].forEach(l=>r.push({executorGroup:l,index:a})),r),[]),i=e.map(({executorGroup:r})=>r.getDeferredZIndexContexts()),n={};for(let r=0,o=e.length;r{i.forEach((o,a)=>{o[r]&&(o[r].forEach(l=>{const{executorGroup:h,index:c}=e[a],u=h.getRenderedContext(),d=u.globalAlpha;u.globalAlpha=this.renderedOpacity_;const g=this.tileClipContexts_[c];g&&g.draw(u),l.draw(u),g&&u.restore(),u.globalAlpha=d,l.clear()}),o[r].length=0)})})}getTileRenderTransform(t,e){const i=e.pixelRatio,n=e.viewState,r=n.center,o=n.resolution,a=n.rotation,l=e.size,h=Math.round(l[0]*i),c=Math.round(l[1]*i),u=this.getLayer().getSource().getTileGridForProjection(e.viewState.projection),d=t.tileCoord,g=u.getTileCoordExtent(t.wrappedTileCoord),f=u.getTileCoordExtent(d,this.tempExtent)[0]-g[0];return bc(Bu(this.inversePixelTransform.slice(),1/i,1/i),this.getRenderTransform(r,o,a,i,h,c,f))}postRender(t,e){var i;const n=e.viewHints,r=!(n[Ie.ANIMATING]||n[Ie.INTERACTING]);this.renderedPixelToCoordinateTransform_=e.pixelToCoordinateTransform.slice(),this.renderedRotation_=e.viewState.rotation,this.renderedOpacity_=e.layerStatesArray[e.layerIndex].opacity;const o=this.getLayer(),a=o.getRenderMode(),l=t.globalAlpha;t.globalAlpha=this.renderedOpacity_;const h=o.getDeclutter(),c=h?kM[a].filter(S=>!zp.includes(S)):kM[a],u=e.viewState,d=u.rotation,g=o.getSource(),f=g.getTileGridForProjection(u.projection).getZForResolution(u.resolution,g.zDirection),p=this.renderedTiles,m=[],_=[],y=[];let v=!0;for(let S=p.length-1;S>=0;--S){const w=p[S];v=v&&!w.getReplayState(o).dirty;const T=w.executorGroups[mt(o)].filter(x=>x.hasExecutors(c));if(T.length===0)continue;const M=this.getTileRenderTransform(w,e),C=w.tileCoord[0];let I=!1;const O=T[0].getClipCoords(M);let P=t,D;if(O){D=new Xv,P=D.getContext();for(let x=0,E=m.length;xthis.gradient_,u_opacity:()=>this.getOpacity()}}]})}renderDeclutter(){}}function jK(s){const t=Se(1,256),e=t.createLinearGradient(0,0,1,256),i=1/(s.length-1);for(let n=0,r=s.length;n=a.width)return null;const c=Ee(o),u=Math.floor(a.height*((o[3]-n[1])/c));return u<0||u>=a.height?null:this.getImageData(a,h,u)}renderFrame(t,e){const i=this.image,n=i.getExtent(),r=i.getResolution(),[o,a]=Array.isArray(r)?r:[r,r],l=i.getPixelRatio(),h=t.layerStatesArray[t.layerIndex],c=t.pixelRatio,u=t.viewState,d=u.center,g=u.resolution,f=c*o/(g*l),p=c*a/(g*l);this.prepareContainer(t,e);const m=this.context.canvas.width,_=this.context.canvas.height,y=this.getRenderContext(t);let v=!1,S=!0;if(h.extent){const I=cn(h.extent,u.projection);S=Ce(I,t.extent),v=S&&!ai(I,t.extent),v&&this.clipUnrotated(y,t,I)}const w=i.getImage(),C=xn(this.tempTransform,m/2,_/2,f,p,0,l*(n[0]-d[0])/o,l*(d[1]-n[3])/a);this.renderedResolution=a*c/l;const M=w.width*C[0],T=w.height*C[3];if(this.getLayer().getSource().getInterpolate()||(y.imageSmoothingEnabled=!1),this.preRender(y,t),S&&M>=.5&&T>=.5){const I=C[4],O=C[5],P=h.opacity;P!==1&&(y.save(),y.globalAlpha=P),y.drawImage(w,0,0,+w.width,+w.height,I,O,M,T),P!==1&&y.restore()}return this.postRender(this.context,t),v&&y.restore(),y.imageSmoothingEnabled=!0,this.container}}class ew extends UK{constructor(t){super(t)}createRenderer(){return new _A(this)}getData(t){return super.getData(t)}}const Zo={PRELOAD:"preload",USE_INTERIM_TILES_ON_ERROR:"useInterimTilesOnError"};class yA extends Tg{constructor(t){t=t||{};const e=Object.assign({},t),i=t.cacheSize;delete t.cacheSize,delete e.preload,delete e.useInterimTilesOnError,super(e),this.on,this.once,this.un,this.cacheSize_=i,this.setPreload(t.preload!==void 0?t.preload:0),this.setUseInterimTilesOnError(t.useInterimTilesOnError!==void 0?t.useInterimTilesOnError:!0)}getCacheSize(){return this.cacheSize_}getPreload(){return this.get(Zo.PRELOAD)}setPreload(t){this.set(Zo.PRELOAD,t)}getUseInterimTilesOnError(){return this.get(Zo.USE_INTERIM_TILES_ON_ERROR)}setUseInterimTilesOnError(t){this.set(Zo.USE_INTERIM_TILES_ON_ERROR,t)}getData(t){return super.getData(t)}}function z_(s,t,e,i){return`${s},${ro(t,e,i)}`}function U_(s,t,e){if(!(e in s))return s[e]=new Set([t]),!0;const i=s[e],n=i.has(t);return n||i.add(t),!n}function BK(s,t,e){const i=s[e];return i?i.delete(t):!1}function DM(s,t){const e=s.layerStatesArray[s.layerIndex];e.extent&&(t=He(t,cn(e.extent,s.viewState.projection)));const i=e.layer.getRenderSource();if(!i.getWrapX()){const n=i.getTileGridForProjection(s.viewState.projection).getExtent();n&&(t=He(t,n))}return t}class xA extends Vv{constructor(t,e){super(t),e=e||{},this.extentChanged=!0,this.renderComplete=!1,this.renderedExtent_=null,this.renderedPixelRatio,this.renderedProjection=null,this.renderedRevision,this.renderedTiles=[],this.renderedSourceKey_,this.renderedSourceRevision_,this.tempExtent=Zs(),this.tempTileRange_=new h0(0,0,0,0),this.tempTileCoord_=ll(0,0,0);const i=e.cacheSize!==void 0?e.cacheSize:512;this.tileCache_=new l0(i),this.maxStaleKeys=i*.5}getTileCache(){return this.tileCache_}getOrCreateTile(t,e,i,n){const r=this.tileCache_,o=this.getLayer().getSource(),a=z_(o.getKey(),t,e,i);let l;if(r.containsKey(a))l=r.get(a);else{if(l=o.getTile(t,e,i,n.pixelRatio,n.viewState.projection),!l)return null;r.set(a,l)}return l}getTile(t,e,i,n){return this.getOrCreateTile(t,e,i,n)||null}getData(t){const e=this.frameState;if(!e)return null;const i=this.getLayer(),n=Ye(e.pixelToCoordinateTransform,t.slice()),r=i.getExtent();if(r&&!Yi(r,n))return null;const o=e.viewState,a=i.getRenderSource(),l=a.getTileGridForProjection(o.projection),h=a.getTilePixelRatio(e.pixelRatio);for(let c=l.getZForResolution(o.resolution);c>=l.getMinZoom();--c){const u=l.getTileCoordForCoordAndZ(n,c),d=this.getTile(c,u[1],u[2],e);if(!d||d.getState()!==X.LOADED)continue;const g=l.getOrigin(c),f=Re(l.getTileSize(c)),p=l.getResolution(c);let m;if(d instanceof Lg)m=d.getImage();else if(d instanceof kd){if(m=uc(d.getData()),!m)continue}else continue;const _=Math.floor(h*((n[0]-g[0])/p-u[1]*f[0])),y=Math.floor(h*((g[1]-n[1])/p-u[2]*f[1])),v=Math.round(h*a.getGutterForProjection(o.projection));return this.getImageData(m,_+v,y+v)}return null}prepareFrame(t){const e=this.getLayer().getSource();if(!e)return!1;const i=this.getLayer().getSource().getRevision();return this.renderedRevision_?this.renderedRevision_!==i&&(this.renderedRevision_=i,this.renderedSourceKey_===e.getKey()&&this.tileCache_.clear()):this.renderedRevision_=i,!0}enqueueTiles(t,e,i,n,r){const o=t.viewState,a=this.getLayer(),l=a.getRenderSource(),h=l.getTileGridForProjection(o.projection),c=mt(l);c in t.wantedTiles||(t.wantedTiles[c]={});const u=t.wantedTiles[c],d=a.getMapInternal(),g=Math.max(i-r,h.getMinZoom(),h.getZForResolution(Math.min(a.getMaxResolution(),d?d.getView().getResolutionForZoom(Math.max(a.getMinZoom(),0)):h.getResolution(0)),l.zDirection));for(let f=i;f>=g;--f){const p=h.getTileRangeForExtentAndZ(e,f,this.tempTileRange_),m=h.getResolution(f);for(let _=p.minX;_<=p.maxX;++_)for(let y=p.minY;y<=p.maxY;++y){const v=this.getTile(f,_,y,t);if(!v||!U_(n,v,f))continue;const S=v.getKey();if(u[S]=!0,v.getState()===X.IDLE&&!t.tileQueue.isKeyQueued(S)){const w=ll(f,_,y,this.tempTileCoord_);t.tileQueue.enqueue([v,c,h.getTileCoordCenter(w),m])}}}}findStaleTile_(t,e){const i=this.tileCache_,n=t[0],r=t[1],o=t[2],a=this.getStaleKeys();for(let l=0;l0&&setTimeout(()=>{this.enqueueTiles(t,O,g-1,T,I-1)},0);const P=mt(this),D=t.time;for(const k of T[g]){const z=k.getState();if((k instanceof Ag||k instanceof a0)&&z===X.EMPTY)continue;const V=k.tileCoord;if(z===X.LOADED&&k.getAlpha(P,D)===1){k.endTransition(P);continue}if(this.renderComplete=!1,this.findStaleTile_(V,T)){BK(T,k,g),t.animate=!0;continue}if(this.findAltTiles_(d,V,g+1,T))continue;const et=d.getMinZoom();for(let F=g-1;F>=et&&!this.findAltTiles_(d,V,F,T);--F);}const x=f/o*l/_,E=this.getRenderContext(t);xn(this.tempTransform,y/2,v/2,x,x,0,-y/2,-v/2),i.extent&&this.clipUnrotated(E,t,S),c.getInterpolate()||(E.imageSmoothingEnabled=!1),this.preRender(E,t),this.renderedTiles.length=0;const b=Object.keys(T).map(Number);b.sort(fr);let R;const A=[],$=[];for(let k=b.length-1;k>=0;--k){const z=b[k],V=c.getTilePixelSize(z,l,r),et=d.getResolution(z)/f,F=V[0]*et*x,ot=V[1]*et*x,ht=d.getTileCoordForCoordAndZ(fo(M),z),pt=d.getTileCoordExtent(ht),Gt=Ye(this.tempTransform,[_*(pt[0]-M[0])/f,_*(M[3]-pt[3])/f]),Kt=_*c.getGutterForProjection(r);for(const bt of T[z]){if(bt.getState()!==X.LOADED)continue;const oe=bt.tileCoord,Pe=ht[1]-oe[1],hs=Math.round(Gt[0]-(Pe-1)*F),rs=ht[2]-oe[2],Ge=Math.round(Gt[1]-(rs-1)*ot),ve=Math.round(Gt[0]-Pe*F),Ke=Math.round(Gt[1]-rs*ot),Ni=hs-ve,Di=Ge-Ke,Mn=b.length===1;let Ks=!1;R=[ve,Ke,ve+Ni,Ke,ve+Ni,Ke+Di,ve,Ke+Di];for(let ki=0,$i=A.length;ki<$i;++ki)if(!Mn&&z<$[ki]){const Jt=A[ki];Ce([ve,Ke,ve+Ni,Ke+Di],[Jt[0],Jt[3],Jt[4],Jt[7]])&&(Ks||(E.save(),Ks=!0),E.beginPath(),E.moveTo(R[0],R[1]),E.lineTo(R[2],R[3]),E.lineTo(R[4],R[5]),E.lineTo(R[6],R[7]),E.moveTo(Jt[6],Jt[7]),E.lineTo(Jt[4],Jt[5]),E.lineTo(Jt[2],Jt[3]),E.lineTo(Jt[0],Jt[1]),E.clip())}A.push(R),$.push(z),this.drawTile(bt,t,ve,Ke,Ni,Di,Kt,Mn),Ks&&E.restore(),this.renderedTiles.unshift(bt),this.updateUsedTiles(t.usedTiles,c,bt)}}this.renderedRevision=u,this.renderedResolution=f,this.extentChanged=!this.renderedExtent_||!so(this.renderedExtent_,M),this.renderedExtent_=M,this.renderedPixelRatio=l,this.renderedProjection=r,this.postRender(this.context,t),i.extent&&E.restore(),E.imageSmoothingEnabled=!0;const G=(k,z)=>{const V=mt(c),et=z.wantedTiles[V],F=et?Object.keys(et).length:0;this.updateCacheSize(F),this.tileCache_.expireCache()};return t.postRenderFunctions.push(G),this.container}updateCacheSize(t){this.tileCache_.highWaterMark=Math.max(this.tileCache_.highWaterMark,t*2)}drawTile(t,e,i,n,r,o,a,l){let h;if(t instanceof kd){if(h=uc(t.getData()),!h)throw new Error("Rendering array data is not yet supported")}else h=this.getTileImage(t);if(!h)return;const c=this.getRenderContext(e),u=mt(this),d=e.layerStatesArray[e.layerIndex],g=d.opacity*(l?t.getAlpha(u,e.time):1),f=g!==c.globalAlpha;f&&(c.save(),c.globalAlpha=g),c.drawImage(h,a,a,h.width-2*a,h.height-2*a,i,n,r,o),f&&c.restore(),g!==d.opacity?e.animate=!0:l&&t.endTransition(u)}getImage(){const t=this.context;return t?t.canvas:null}getTileImage(t){return t.getImage()}updateUsedTiles(t,e,i){const n=mt(e);n in t||(t[n]={}),t[n][i.getKey()]=!0}}class Yp extends yA{constructor(t){super(t)}createRenderer(){return new xA(this,{cacheSize:this.getCacheSize()})}}class sw extends Wm{constructor(t,e,i,n,r){const o=r!==void 0?it.IDLE:it.LOADED;super(t,e,i,o),this.loader_=r!==void 0?r:null,this.canvas_=n,this.error_=null}getError(){return this.error_}handleLoad_(t){t?(this.error_=t,this.state=it.ERROR):this.state=it.LOADED,this.changed()}load(){this.state==it.IDLE&&(this.state=it.LOADING,this.changed(),this.loader_(this.handleLoad_.bind(this)))}getImage(){return this.canvas_}}function qp(s){return Array.isArray(s)?Math.min(...s):s}class WK extends _A{constructor(t){super(t),this.vectorRenderer_=new nA(t),this.layerImageRatio_=t.getImageRatio(),this.coordinateToVectorPixelTransform_=ss(),this.renderedPixelToCoordinateTransform_=null}disposeInternal(){this.vectorRenderer_.dispose(),super.disposeInternal()}getFeatures(t){if(!this.vectorRenderer_)return Promise.resolve([]);const e=Ye(this.coordinateToVectorPixelTransform_,Ye(this.renderedPixelToCoordinateTransform_,t.slice()));return this.vectorRenderer_.getFeatures(e)}handleFontsChanged(){this.vectorRenderer_.handleFontsChanged()}prepareFrame(t){const e=t.pixelRatio,i=t.viewState,n=i.resolution,r=t.viewHints,o=this.vectorRenderer_;let a=t.extent;this.layerImageRatio_!==1&&(a=a.slice(0),gI(a,this.layerImageRatio_));const l=Rt(a)/n,h=Ee(a)/n;if(!r[Ie.ANIMATING]&&!r[Ie.INTERACTING]&&!po(a)){o.useContainer(null,null);const c=o.context,u=t.layerStatesArray[t.layerIndex],d=Object.assign({},u,{opacity:1}),g=Object.assign({},t,{extent:a,size:[l,h],viewState:Object.assign({},t.viewState,{rotation:0}),layerStatesArray:[d],layerIndex:0,declutter:null}),f=this.getLayer().getDeclutter();f&&(g.declutter={[f]:new jv(9)});let p=!0;const m=new sw(a,n,e,c.canvas,function(_){o.prepareFrame(g)&&o.replayGroupChanged&&(o.clipping=!1,o.renderFrame(g,null)&&(o.renderDeclutter(g),o.renderDeferred(g),p=!1),_())});m.addEventListener(Zt.CHANGE,()=>{if(m.getState()!==it.LOADED)return;this.image=p?null:m;const _=m.getPixelRatio(),y=qp(m.getResolution())*e/_;this.renderedResolution=y,this.coordinateToVectorPixelTransform_=xn(this.coordinateToVectorPixelTransform_,l/2,h/2,1/y,-1/y,0,-i.center[0],-i.center[1])}),m.load()}return this.image&&(this.renderedPixelToCoordinateTransform_=t.pixelToCoordinateTransform.slice()),!!this.image}preRender(){}postRender(){}renderDeclutter(){}forEachFeatureAtCoordinate(t,e,i,n,r){return this.vectorRenderer_?this.vectorRenderer_.forEachFeatureAtCoordinate(t,e,i,n,r):super.forEachFeatureAtCoordinate(t,e,i,n,r)}}class XK extends Ig{constructor(t){t=t||{};const e=Object.assign({},t);delete e.imageRatio,super(e),this.imageRatio_=t.imageRatio!==void 0?t.imageRatio:1}getImageRatio(){return this.imageRatio_}createRenderer(){return new WK(this)}}const VK=XK,YK={image:["Polygon","Circle","LineString","Image","Text"],hybrid:["Polygon","LineString"],vector:[]},kM={hybrid:["Image","Text","Default"],vector:["Polygon","Circle","LineString","Image","Text","Default"]};class qK extends xA{constructor(t,e){super(t,e),this.boundHandleStyleImageChange_=this.handleStyleImageChange_.bind(this),this.renderedLayerRevision_,this.renderedPixelToCoordinateTransform_=null,this.renderedRotation_,this.renderedOpacity_=1,this.tmpTransform_=ss(),this.tileClipContexts_=null}drawTile(t,e,i,n,r,o,a,l){this.updateExecutorGroup_(t,e.pixelRatio,e.viewState.projection),this.tileImageNeedsRender_(t)&&this.renderTileImage_(t,e),super.drawTile(t,e,i,n,r,o,a,l)}getTile(t,e,i,n){const r=this.getOrCreateTile(t,e,i,n);if(!r)return null;const o=n.viewState.resolution,a=n.viewHints;return(!(a[Ie.ANIMATING]||a[Ie.INTERACTING])||!r.wantedResolution)&&(r.wantedResolution=o),r}prepareFrame(t){const e=this.getLayer().getRevision();return this.renderedLayerRevision_!==e&&(this.renderedLayerRevision_=e,this.renderedTiles.length=0),super.prepareFrame(t)}updateExecutorGroup_(t,e,i){const n=this.getLayer(),r=n.getRevision(),o=n.getRenderOrder()||null,a=t.wantedResolution,l=t.getReplayState(n);if(!l.dirty&&l.renderedResolution===a&&l.renderedRevision==r&&l.renderedRenderOrder==o)return;const h=n.getSource(),c=!!n.getDeclutter(),u=h.getTileGrid(),d=h.getTileGridForProjection(i).getTileCoordExtent(t.wrappedTileCoord),g=h.getSourceTiles(e,i,t),f=mt(n);delete t.hitDetectionImageData[f],t.executorGroups[f]=[],l.dirty=!1;for(let p=0,m=g.length;p{const M=w?e.declutter[w].all().map(T=>T.value):null;for(let T=0,I=C.length;T{const n=this.getLayer(),r=mt(n),o=n.getSource(),a=this.renderedProjection,l=a.getExtent(),h=this.renderedResolution,c=o.getTileGridForProjection(a),u=Ye(this.renderedPixelToCoordinateTransform_,t.slice()),d=c.getTileCoordForCoordAndResolution(u,h);let g;for(let v=0,S=this.renderedTiles.length;v0){e([]);return}const f=c.getTileCoordExtent(g.wrappedTileCoord),p=fo(f),m=[(u[0]-p[0])/h,(p[1]-u[1])/h],_=g.getSourceTiles().reduce(function(v,S){return v.concat(S.getFeatures())},[]);let y=g.hitDetectionImageData[r];if(!y){const v=Re(c.getTileSize(c.getZForResolution(h,o.zDirection))),S=this.renderedRotation_,w=[this.getRenderTransform(c.getTileCoordCenter(g.wrappedTileCoord),h,0,Xi,v[0]*Xi,v[1]*Xi,0)];y=QP(v,w,_,n.getStyleFunction(),c.getTileCoordExtent(g.wrappedTileCoord),g.getReplayState(n).renderedResolution,S),g.hitDetectionImageData[r]=y}e(tA(m,_,y))})}getFeaturesInExtent(t){const e=[],i=this.getTileCache();if(i.getCount()===0)return e;const n=this.getLayer().getSource().tileGrid,r=n.getZForResolution(this.renderedResolution);return i.forEach(o=>{if(o.tileCoord[0]!==r||o.getState()!==X.LOADED)return;const a=o.getSourceTiles();for(let l=0,h=a.length;l=0;--g)u[g].execute(this.context,[this.context.canvas.width,this.context.canvas.height],this.getTileRenderTransform(c,t),t.viewState.rotation,o,zp,d?t.declutter[d]:void 0)}i.globalAlpha=n}renderDeferredInternal(t){const e=this.renderedTiles.reduce((r,o,a)=>(o.executorGroups[mt(this.getLayer())].forEach(l=>r.push({executorGroup:l,index:a})),r),[]),i=e.map(({executorGroup:r})=>r.getDeferredZIndexContexts()),n={};for(let r=0,o=e.length;r{i.forEach((o,a)=>{o[r]&&(o[r].forEach(l=>{const{executorGroup:h,index:c}=e[a],u=h.getRenderedContext(),d=u.globalAlpha;u.globalAlpha=this.renderedOpacity_;const g=this.tileClipContexts_[c];g&&g.draw(u),l.draw(u),g&&u.restore(),u.globalAlpha=d,l.clear()}),o[r].length=0)})})}getTileRenderTransform(t,e){const i=e.pixelRatio,n=e.viewState,r=n.center,o=n.resolution,a=n.rotation,l=e.size,h=Math.round(l[0]*i),c=Math.round(l[1]*i),u=this.getLayer().getSource().getTileGridForProjection(e.viewState.projection),d=t.tileCoord,g=u.getTileCoordExtent(t.wrappedTileCoord),f=u.getTileCoordExtent(d,this.tempExtent)[0]-g[0];return bc(Bu(this.inversePixelTransform.slice(),1/i,1/i),this.getRenderTransform(r,o,a,i,h,c,f))}postRender(t,e){var i;const n=e.viewHints,r=!(n[Ie.ANIMATING]||n[Ie.INTERACTING]);this.renderedPixelToCoordinateTransform_=e.pixelToCoordinateTransform.slice(),this.renderedRotation_=e.viewState.rotation,this.renderedOpacity_=e.layerStatesArray[e.layerIndex].opacity;const o=this.getLayer(),a=o.getRenderMode(),l=t.globalAlpha;t.globalAlpha=this.renderedOpacity_;const h=o.getDeclutter(),c=h?kM[a].filter(S=>!zp.includes(S)):kM[a],u=e.viewState,d=u.rotation,g=o.getSource(),f=g.getTileGridForProjection(u.projection).getZForResolution(u.resolution,g.zDirection),p=this.renderedTiles,m=[],_=[],y=[];let v=!0;for(let S=p.length-1;S>=0;--S){const w=p[S];v=v&&!w.getReplayState(o).dirty;const C=w.executorGroups[mt(o)].filter(x=>x.hasExecutors(c));if(C.length===0)continue;const M=this.getTileRenderTransform(w,e),T=w.tileCoord[0];let I=!1;const O=C[0].getClipCoords(M);let P=t,D;if(O){D=new Xv,P=D.getContext();for(let x=0,E=m.length;x{const h=s.variables[a.name];return typeof h=="number"?h:typeof h=="boolean"?h?1:0:a.type===$e?$M([...Bn(h||"#eee")]):typeof h=="string"?Vp(h):h}}for(const o in e.properties){const a=e.properties[o];t.properties[o]||(t.properties[o]=a);let l=B_(a.type),h=`a_prop_${a.name}`;a.type===$e&&(l="vec4",h=`unpackColor(${h})`,i.addVertexShaderFunction(ZK)),i.addVarying(`v_prop_${a.name}`,l,h)}for(const o in t.properties){const a=t.properties[o];i.addAttribute(`${B_(a.type)} a_prop_${a.name}`)}for(const o in t.functions)i.addVertexShaderFunction(t.functions[o]);for(const o in e.functions)i.addFragmentShaderFunction(e.functions[o]);const r={};for(const o in t.properties){const a=t.properties[o];let l;a.evaluator?l=a.evaluator:l=h=>{const c=h.get(a.name);return a.type===$e?$M([...Bn(c||"#eee")]):typeof c=="string"?Vp(c):typeof c=="boolean"?c?1:0:c},r[a.name]={size:wA(a.type),callback:l}}return{builder:i,attributes:r,uniforms:n}}class sJ extends Cg{constructor(t){const e=Object.assign({},t);super(e),this.parseResult_=eJ(t.style),this.styleVariables_=t.style.variables||{},this.hitDetectionDisabled_=!!t.disableHitDetection}createRenderer(){const t=Object.keys(this.parseResult_.attributes).map(e=>({name:e,...this.parseResult_.attributes[e]}));return new uA(this,{vertexShader:this.parseResult_.builder.getSymbolVertexShader(),fragmentShader:this.parseResult_.builder.getSymbolFragmentShader(),hitDetectionEnabled:!this.hitDetectionDisabled_,uniforms:this.parseResult_.uniforms,attributes:t})}updateStyleVariables(t){Object.assign(this.styleVariables_,t),this.changed()}}const iJ=sJ;function GM(s,t){const e=` +}`;const h=`u_texture${r}`;let c="1.";"fill-color"in s&&(c=t.getFillColorExpression()),t.setFillColorExpression(`${c} * sampleFillPattern(${h}, ${o}, ${l}, ${a}, pxOrigin, pxPos)`)}}function eJ(s){const t={inFragmentShader:!1,properties:{},variables:{},functions:{},style:s},e={inFragmentShader:!0,variables:t.variables,properties:{},functions:{},style:s},i=new mA,n={};if("icon-src"in s?JK(s,i,n,t,e):"shape-points"in s?KK(s,i,n,t,e):"circle-radius"in s&&HK(s,i,n,t,e),QK(s,i,n,t,e),tJ(s,i,n,t,e),s.filter){const o=At(e,s.filter,Os);i.setFragmentDiscardExpression(`!${o}`)}for(const o in e.variables){const a=e.variables[o],l=Qv(a.name);i.addUniform(`${B_(a.type)} ${l}`),n[l]=()=>{const h=s.variables[a.name];return typeof h=="number"?h:typeof h=="boolean"?h?1:0:a.type===$e?$M([...Bn(h||"#eee")]):typeof h=="string"?Vp(h):h}}for(const o in e.properties){const a=e.properties[o];t.properties[o]||(t.properties[o]=a);let l=B_(a.type),h=`a_prop_${a.name}`;a.type===$e&&(l="vec4",h=`unpackColor(${h})`,i.addVertexShaderFunction(ZK)),i.addVarying(`v_prop_${a.name}`,l,h)}for(const o in t.properties){const a=t.properties[o];i.addAttribute(`${B_(a.type)} a_prop_${a.name}`)}for(const o in t.functions)i.addVertexShaderFunction(t.functions[o]);for(const o in e.functions)i.addFragmentShaderFunction(e.functions[o]);const r={};for(const o in t.properties){const a=t.properties[o];let l;a.evaluator?l=a.evaluator:l=h=>{const c=h.get(a.name);return a.type===$e?$M([...Bn(c||"#eee")]):typeof c=="string"?Vp(c):typeof c=="boolean"?c?1:0:c},r[a.name]={size:wA(a.type),callback:l}}return{builder:i,attributes:r,uniforms:n}}class sJ extends Tg{constructor(t){const e=Object.assign({},t);super(e),this.parseResult_=eJ(t.style),this.styleVariables_=t.style.variables||{},this.hitDetectionDisabled_=!!t.disableHitDetection}createRenderer(){const t=Object.keys(this.parseResult_.attributes).map(e=>({name:e,...this.parseResult_.attributes[e]}));return new uA(this,{vertexShader:this.parseResult_.builder.getSymbolVertexShader(),fragmentShader:this.parseResult_.builder.getSymbolFragmentShader(),hitDetectionEnabled:!this.hitDetectionDisabled_,uniforms:this.parseResult_.uniforms,attributes:t})}updateStyleVariables(t){Object.assign(this.styleVariables_,t),this.changed()}}const iJ=sJ;function GM(s,t){const e=` attribute vec2 ${Gf.TEXTURE_COORD}; uniform mat4 ${jt.TILE_TRANSFORM}; uniform float ${jt.TEXTURE_PIXEL_WIDTH}; @@ -793,16 +793,16 @@ void main(void) { gl_FragColor = color; gl_FragColor.rgb *= gl_FragColor.a; gl_FragColor *= ${jt.TRANSITION_ALPHA}; - }`;return{vertexShader:e,fragmentShader:c,uniforms:r,paletteTextures:i.paletteTextures}}class Hp extends yA{constructor(t){t=t?Object.assign({},t):{};const e=t.style||{};delete t.style,super(t),this.sources_=t.sources,this.renderedSource_=null,this.renderedResolution_=NaN,this.style_=e,this.styleVariables_=this.style_.variables||{},this.addChangeListener(ue.SOURCE,this.handleSourceUpdate_)}getSources(t,e){const i=this.getSource();return this.sources_?typeof this.sources_=="function"?this.sources_(t,e):this.sources_:i?[i]:[]}getRenderSource(){return this.renderedSource_||this.getSource()}getSourceState(){const t=this.getRenderSource();return t?t.getState():"undefined"}handleSourceUpdate_(){this.hasRenderer()&&this.getRenderer().clearCache(),this.getSource()&&this.setStyle(this.style_)}getSourceBandCount_(){const t=Number.MAX_SAFE_INTEGER,e=this.getSources([-t,-t,t,t],t);return e&&e.length&&"bandCount"in e[0]?e[0].bandCount:4}createRenderer(){const t=GM(this.style_,this.getSourceBandCount_());return new PK(this,{vertexShader:t.vertexShader,fragmentShader:t.fragmentShader,uniforms:t.uniforms,cacheSize:this.getCacheSize(),paletteTextures:t.paletteTextures})}renderSources(t,e){const i=this.getRenderer();let n;for(let r=0,o=e.length;r{h.getState()=="ready"&&(h.removeEventListener("change",u),this.changed())};h.addEventListener("change",u)}r=r&&c=="ready"}const o=this.renderSources(t,n);if(this.getRenderer().renderComplete&&r)return this.renderedResolution_=i.resolution,o;if(this.renderedResolution_>.5*i.resolution){const a=this.getSources(t.extent,this.renderedResolution_).filter(l=>!n.includes(l));if(a.length>0)return this.renderSources(t,a)}return o}setStyle(t){if(this.styleVariables_=t.variables||{},this.style_=t,this.hasRenderer()){const e=GM(this.style_,this.getSourceBandCount_());this.getRenderer().reset({vertexShader:e.vertexShader,fragmentShader:e.fragmentShader,uniforms:e.uniforms,paletteTextures:e.paletteTextures}),this.changed()}}updateStyleVariables(t){Object.assign(this.styleVariables_,t),this.changed()}}Hp.prototype.dispose;const nJ=Object.freeze(Object.defineProperty({__proto__:null,Graticule:VH,Group:i0,Heatmap:zK,Image:ew,Layer:Cg,Tile:Yp,Vector:Yv,VectorImage:VK,VectorTile:vA,WebGLPoints:iJ,WebGLTile:Hp},Symbol.toStringTag,{value:"Module"}));var ii=(s,t,e)=>new Promise((i,n)=>{var r=l=>{try{a(e.next(l))}catch(h){n(h)}},o=l=>{try{a(e.throw(l))}catch(h){n(h)}},a=l=>l.done?i(l.value):Promise.resolve(l.value).then(r,o);a((e=e.apply(s,t)).next())}),Vi=Uint8Array,Zu=Uint16Array,rJ=Int32Array,SA=new Vi([0,0,0,0,0,0,0,0,1,1,1,1,2,2,2,2,3,3,3,3,4,4,4,4,5,5,5,5,0,0,0,0]),MA=new Vi([0,0,0,0,1,1,2,2,3,3,4,4,5,5,6,6,7,7,8,8,9,9,10,10,11,11,12,12,13,13,0,0]),oJ=new Vi([16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15]),bA=function(s,t){for(var e=new Zu(31),i=0;i<31;++i)e[i]=t+=1<>1|(ge&21845)<<1,Ar=(Ar&52428)>>2|(Ar&13107)<<2,Ar=(Ar&61680)>>4|(Ar&3855)<<4,RA[ge]=((Ar&65280)>>8|(Ar&255)<<8)>>1;var Ar,ge,Hu=function(s,t,e){for(var i=s.length,n=0,r=new Zu(t);n>l]=h}return a},Og=new Vi(288);for(ge=0;ge<144;++ge)Og[ge]=8;var ge;for(ge=144;ge<256;++ge)Og[ge]=9;var ge;for(ge=256;ge<280;++ge)Og[ge]=7;var ge;for(ge=280;ge<288;++ge)Og[ge]=8;var ge,IA=new Vi(32);for(ge=0;ge<32;++ge)IA[ge]=5;var ge,cJ=Hu(Og,9),uJ=Hu(IA,5),W_=function(s){for(var t=s[0],e=1;et&&(t=s[e]);return t},Pn=function(s,t,e){var i=t/8|0;return(s[i]|s[i+1]<<8)>>(t&7)&e},X_=function(s,t){var e=t/8|0;return(s[e]|s[e+1]<<8|s[e+2]<<16)>>(t&7)},dJ=function(s){return(s+7)/8|0},gJ=function(s,t,e){(e==null||e>s.length)&&(e=s.length);var i=new Vi(e-t);return i.set(s.subarray(t,e)),i},fJ=["unexpected EOF","invalid block type","invalid length/literal","invalid distance","stream finished","no stream handler",,"no callback","invalid UTF-8 data","extra field too long","date not in range 1980-2099","filename too long","stream finishing","invalid zip data"],ji=function(s,t,e){var i=new Error(t||fJ[s]);if(i.code=s,Error.captureStackTrace&&Error.captureStackTrace(i,ji),!e)throw i;return i},ow=function(s,t,e,i){var n=s.length,r=0;if(!n||t.f&&!t.l)return e||new Vi(0);var o=!e||t.i!=2,a=t.i;e||(e=new Vi(n*3));var l=function(bt){var oe=e.length;if(bt>oe){var Pe=new Vi(Math.max(oe*2,bt));Pe.set(e),e=Pe}},h=t.f||0,c=t.p||0,u=t.b||0,d=t.l,g=t.d,f=t.m,p=t.n,m=n*8;do{if(!d){h=Pn(s,c,1);var _=Pn(s,c+1,3);if(c+=3,_)if(_==1)d=cJ,g=uJ,f=9,p=5;else if(_==2){var y=Pn(s,c,31)+257,v=Pn(s,c+10,15)+4,S=y+Pn(s,c+5,31)+1;c+=14;for(var w=new Vi(S),T=new Vi(19),M=0;M>4;if(D<16)w[M++]=D;else{var x=0,E=0;for(D==16?(E=3+Pn(s,c,3),c+=2,x=w[M-1]):D==17?(E=3+Pn(s,c,7),c+=3):D==18&&(E=11+Pn(s,c,127),c+=7);E--;)w[M++]=x}}var b=w.subarray(0,y),R=w.subarray(y);f=W_(b),p=W_(R),d=Hu(b,f),g=Hu(R,p)}else ji(1);else{var D=dJ(c)+4,A=s[D-4]|s[D-3]<<8,$=D+A;if($>n){a&&ji(0);break}o&&l(u+A),e.set(s.subarray(D,$),u),t.b=u+=A,t.p=c=$*8,t.f=h;continue}if(c>m){a&&ji(0);break}}o&&l(u+131072);for(var G=(1<>4;if(c+=x&15,c>m){a&&ji(0);break}if(x||ji(2),V<256)e[u++]=V;else if(V==256){z=c,d=null;break}else{var et=V-254;if(V>264){var M=V-257,F=SA[M];et=Pn(s,c,(1<>4;ot||ji(3),c+=ot&15;var R=hJ[ht];if(ht>3){var F=MA[ht];R+=X_(s,c)&(1<m){a&&ji(0);break}o&&l(u+131072);var pt=u+et;if(u>3&1)+(t>>4&1);i>0;i-=!s[e++]);return e+(t&2)},_J=function(s){var t=s.length;return(s[t-4]|s[t-3]<<8|s[t-2]<<16|s[t-1]<<24)>>>0},yJ=function(s,t){return((s[0]&15)!=8||s[0]>>4>7||(s[0]<<8|s[1])%31)&&ji(6,"invalid zlib data"),(s[1]>>5&1)==+!t&&ji(6,"invalid zlib data: "+(s[1]&32?"need":"unexpected")+" dictionary"),(s[1]>>3&4)+2};function xJ(s,t){return ow(s,{i:2},t,t)}function vJ(s,t){var e=mJ(s);return e+8>s.length&&ji(6,"invalid gzip data"),ow(s.subarray(e,-8),{i:2},new Vi(_J(s)),t)}function wJ(s,t){return ow(s.subarray(yJ(s,t),-4),{i:2},t,t)}function dy(s,t){return s[0]==31&&s[1]==139&&s[2]==8?vJ(s,t):(s[0]&15)!=8||s[0]>>4>7||(s[0]<<8|s[1])%31?xJ(s,t):wJ(s,t)}var EJ=typeof TextDecoder<"u"&&new TextDecoder,SJ=0;try{EJ.decode(pJ,{stream:!0}),SJ=1}catch{}var PA=(s,t)=>s*Math.pow(2,t),ou=(s,t)=>Math.floor(s/Math.pow(2,t)),Kp=(s,t)=>PA(s.getUint16(t+1,!0),8)+s.getUint8(t),AA=(s,t)=>PA(s.getUint32(t+2,!0),16)+s.getUint16(t,!0),MJ=(s,t,e,i,n)=>{if(s!=i.getUint8(n))return s-i.getUint8(n);const r=Kp(i,n+1);if(t!=r)return t-r;const o=Kp(i,n+4);return e!=o?e-o:0},bJ=(s,t,e,i)=>{const n=LA(s,t|128,e,i);return n?{z:t,x:e,y:i,offset:n[0],length:n[1],is_dir:!0}:null},jM=(s,t,e,i)=>{const n=LA(s,t,e,i);return n?{z:t,x:e,y:i,offset:n[0],length:n[1],is_dir:!1}:null},LA=(s,t,e,i)=>{let n=0,r=s.byteLength/17-1;for(;n<=r;){const o=r+n>>1,a=MJ(t,e,i,s,o*17);if(a>0)n=o+1;else if(a<0)r=o-1;else return[AA(s,o*17+7),s.getUint32(o*17+13,!0)]}return null},TJ=(s,t)=>s.is_dir&&!t.is_dir?1:!s.is_dir&&t.is_dir?-1:s.z!==t.z?s.z-t.z:s.x!==t.x?s.x-t.x:s.y-t.y,OA=(s,t)=>{const e=s.getUint8(t*17);return{z:e&127,x:Kp(s,t*17+1),y:Kp(s,t*17+4),offset:AA(s,t*17+7),length:s.getUint32(t*17+13,!0),is_dir:e>>7===1}},zM=s=>{const t=[],e=new DataView(s);for(let i=0;i{s.sort(TJ);const t=new ArrayBuffer(17*s.length),e=new Uint8Array(t);for(let i=0;i>8&255,e[i*17+3]=n.x>>16&255,e[i*17+4]=n.y&255,e[i*17+5]=n.y>>8&255,e[i*17+6]=n.y>>16&255,e[i*17+7]=n.offset&255,e[i*17+8]=ou(n.offset,8)&255,e[i*17+9]=ou(n.offset,16)&255,e[i*17+10]=ou(n.offset,24)&255,e[i*17+11]=ou(n.offset,32)&255,e[i*17+12]=ou(n.offset,48)&255,e[i*17+13]=n.length&255,e[i*17+14]=n.length>>8&255,e[i*17+15]=n.length>>16&255,e[i*17+16]=n.length>>24&255}return t},RJ=(s,t)=>{if(s.byteLength<17)return null;const e=s.byteLength/17,i=OA(s,e-1);if(i.is_dir){const n=i.z,r=t.z-n,o=Math.trunc(t.x/(1<>>0)*4294967296+(s>>>0)}function LJ(s,t){const e=t.buf;let i,n;if(n=e[t.pos++],i=(n&112)>>4,n<128||(n=e[t.pos++],i|=(n&127)<<3,n<128)||(n=e[t.pos++],i|=(n&127)<<10,n<128)||(n=e[t.pos++],i|=(n&127)<<17,n<128)||(n=e[t.pos++],i|=(n&127)<<24,n<128)||(n=e[t.pos++],i|=(n&1)<<31,n<128))return AJ(s,i);throw new Error("Expected varint not more than 10 bytes")}function au(s){const t=s.buf;let e,i;return i=t[s.pos++],e=i&127,i<128||(i=t[s.pos++],e|=(i&127)<<7,i<128)||(i=t[s.pos++],e|=(i&127)<<14,i<128)||(i=t[s.pos++],e|=(i&127)<<21,i<128)?e:(i=t[s.pos],e|=(i&15)<<28,LJ(e,s))}function OJ(s,t,e,i){if(i==0){e==1&&(t[0]=s-1-t[0],t[1]=s-1-t[1]);const n=t[0];t[0]=t[1],t[1]=n}}var FJ=[0,1,5,21,85,341,1365,5461,21845,87381,349525,1398101,5592405,22369621,89478485,357913941,1431655765,5726623061,22906492245,91625968981,366503875925,1466015503701,5864062014805,23456248059221,93824992236885,375299968947541,0x5555555555555];function NJ(s,t,e){if(s>26)throw Error("Tile zoom level exceeds max safe number limit (26)");if(t>Math.pow(2,s)-1||e>Math.pow(2,s)-1)throw Error("tile x/y outside zoom level bounds");const i=FJ[s],n=Math.pow(2,s);let r=0,o=0,a=0;const l=[t,e];let h=n/2;for(;h>0;)r=(l[0]&h)>0?1:0,o=(l[1]&h)>0?1:0,a+=h*h*(3*r^o),OJ(h,l,r,o),h=h/2;return i+a}function NA(s,t){return ii(this,null,function*(){if(t===1||t===0)return s;if(t===2){if(typeof globalThis.DecompressionStream>"u")return dy(new Uint8Array(s));{let e=new Response(s).body.pipeThrough(new globalThis.DecompressionStream("gzip"));return new Response(e).arrayBuffer()}}else throw Error("Compression method not supported")})}var th=(s=>(s[s.Unknown=0]="Unknown",s[s.Mvt=1]="Mvt",s[s.Png=2]="Png",s[s.Jpeg=3]="Jpeg",s[s.Webp=4]="Webp",s[s.Avif=5]="Avif",s))(th||{}),DJ=127;function kJ(s,t){let e=0,i=s.length-1;for(;e<=i;){const n=i+e>>1,r=t-s[n].tileId;if(r>0)e=n+1;else if(r<0)i=n-1;else return s[n]}return i>=0&&(s[i].runLength===0||t-s[i].tileId=300)throw Error("Bad response code: "+r.status);const o=r.headers.get("Content-Length");if(r.status===200&&(!o||+o>t))throw i&&i.abort(),Error("Server returned no content-length header or content-length exceeding request. Check that your storage backend supports HTTP Byte Serving.");return{data:yield r.arrayBuffer(),etag:r.headers.get("ETag")||void 0,cacheControl:r.headers.get("Cache-Control")||void 0,expires:r.headers.get("Expires")||void 0}})}};function An(s,t){const e=s.getUint32(t+4,!0),i=s.getUint32(t+0,!0);return e*Math.pow(2,32)+i}function GJ(s,t){const e=new DataView(s),i=e.getUint8(7);if(i>3)throw Error(`Archive is spec version ${i} but this library supports up to spec version 3`);return{specVersion:i,rootDirectoryOffset:An(e,8),rootDirectoryLength:An(e,16),jsonMetadataOffset:An(e,24),jsonMetadataLength:An(e,32),leafDirectoryOffset:An(e,40),leafDirectoryLength:An(e,48),tileDataOffset:An(e,56),tileDataLength:An(e,64),numAddressedTiles:An(e,72),numTileEntries:An(e,80),numTileContents:An(e,88),clustered:e.getUint8(96)===1,internalCompression:e.getUint8(97),tileCompression:e.getUint8(98),tileType:e.getUint8(99),minZoom:e.getUint8(100),maxZoom:e.getUint8(101),minLon:e.getInt32(102,!0)/1e7,minLat:e.getInt32(106,!0)/1e7,maxLon:e.getInt32(110,!0)/1e7,maxLat:e.getInt32(114,!0)/1e7,centerZoom:e.getUint8(118),centerLon:e.getInt32(119,!0)/1e7,centerLat:e.getInt32(123,!0)/1e7,etag:t}}function DA(s){const t={buf:new Uint8Array(s),pos:0},e=au(t),i=[];let n=0;for(let r=0;r0?i[r].offset=i[r-1].offset+i[r-1].length:i[r].offset=o-1}return i}function jJ(s){const t=new DataView(s);return t.getUint16(2,!0)===2?(console.warn("PMTiles spec version 2 has been deprecated; please see github.com/protomaps/PMTiles for tools to upgrade"),2):t.getUint16(2,!0)===1?(console.warn("PMTiles spec version 1 has been deprecated; please see github.com/protomaps/PMTiles for tools to upgrade"),1):3}var _h=class extends Error{};function zJ(s,t,e,i){return ii(this,null,function*(){const n=yield s.getBytes(0,16384);if(new DataView(n.data).getUint16(0,!0)!==19792)throw new Error("Wrong magic number for PMTiles archive");if(jJ(n.data)<3)return[yield FA.getHeader(s)];const r=n.data.slice(0,DJ);let o=n.etag;i&&n.etag!=i&&(console.warn("ETag conflict detected; your HTTP server might not support content-based ETag headers. ETags disabled for "+s.getKey()),o=void 0);const a=GJ(r,o);if(e){const l=n.data.slice(a.rootDirectoryOffset,a.rootDirectoryOffset+a.rootDirectoryLength),h=s.getKey()+"|"+(a.etag||"")+"|"+a.rootDirectoryOffset+"|"+a.rootDirectoryLength,c=DA(yield t(l,a.internalCompression));return[a,[h,c.length,c]]}return[a,void 0]})}function UJ(s,t,e,i,n){return ii(this,null,function*(){const r=yield s.getBytes(e,i);if(n.etag&&n.etag!==r.etag)throw new _h(r.etag);const o=yield t(r.data,n.internalCompression),a=DA(o);if(a.length===0)throw new Error("Empty directory is invalid");return a})}var BJ=class{constructor(s=100,t=!0,e=NA){this.cache=new Map,this.maxCacheEntries=s,this.counter=1,this.prefetch=t,this.decompress=e}getHeader(s,t){return ii(this,null,function*(){const e=s.getKey();if(this.cache.has(e))return this.cache.get(e).lastUsed=this.counter++,yield this.cache.get(e).data;const i=new Promise((n,r)=>{zJ(s,this.decompress,this.prefetch,t).then(o=>{o[1]&&this.cache.set(o[1][0],{lastUsed:this.counter++,data:Promise.resolve(o[1][2])}),n(o[0]),this.prune()}).catch(o=>{r(o)})});return this.cache.set(e,{lastUsed:this.counter++,data:i}),i})}getDirectory(s,t,e,i){return ii(this,null,function*(){const n=s.getKey()+"|"+(i.etag||"")+"|"+t+"|"+e;if(this.cache.has(n))return this.cache.get(n).lastUsed=this.counter++,yield this.cache.get(n).data;const r=new Promise((o,a)=>{UJ(s,this.decompress,t,e,i).then(l=>{o(l),this.prune()}).catch(l=>{a(l)})});return this.cache.set(n,{lastUsed:this.counter++,data:r}),r})}getArrayBuffer(s,t,e,i){return ii(this,null,function*(){const n=s.getKey()+"|"+(i.etag||"")+"|"+t+"|"+e;if(this.cache.has(n))return this.cache.get(n).lastUsed=this.counter++,yield this.cache.get(n).data;const r=new Promise((o,a)=>{s.getBytes(t,e).then(l=>{if(i.etag&&i.etag!==l.etag)throw new _h(l.etag);o(l.data),this.cache.has(n),this.prune()}).catch(l=>{a(l)})});return this.cache.set(n,{lastUsed:this.counter++,data:r}),r})}prune(){if(this.cache.size>=this.maxCacheEntries){let s=1/0,t;this.cache.forEach((e,i)=>{e.lastUsedr.maxZoom)return;let o=r.rootDirectoryOffset,a=r.rootDirectoryLength;for(let l=0;l<=3;l++){const h=yield this.cache.getDirectory(this.source,o,a,r),c=kJ(h,n);if(c)if(c.runLength>0){const u=yield this.source.getBytes(r.tileDataOffset+c.offset,c.length,i);if(r.etag&&r.etag!==u.etag)throw new _h(u.etag);return{data:yield this.decompress(u.data,r.tileCompression),cacheControl:u.cacheControl,expires:u.expires}}else o=r.leafDirectoryOffset+c.offset,a=c.length;else return}throw Error("Maximum directory depth exceeded")})}getZxy(s,t,e,i){return ii(this,null,function*(){try{return yield this.getZxyAttempt(s,t,e,i)}catch(n){if(n instanceof _h)return this.cache.invalidate(this.source,n.message),yield this.getZxyAttempt(s,t,e,i);throw n}})}getMetadataAttempt(){return ii(this,null,function*(){const s=yield this.cache.getHeader(this.source),t=yield this.source.getBytes(s.jsonMetadataOffset,s.jsonMetadataLength);if(s.etag&&s.etag!==t.etag)throw new _h(t.etag);const e=yield this.decompress(t.data,s.internalCompression),i=new TextDecoder("utf-8");return JSON.parse(i.decode(e))})}getMetadata(){return ii(this,null,function*(){try{return yield this.getMetadataAttempt()}catch(s){if(s instanceof _h)return this.cache.invalidate(this.source,s.message),yield this.getMetadataAttempt();throw s}})}};class WJ extends Sr{constructor(t){super(Zt.ERROR),this.error=t}}class u0 extends l0{clear(){for(;this.getCount()>0;)this.pop().release();super.clear()}expireCache(t){for(;this.canExpireCache()&&!(this.peekLast().getKey()in t);)this.pop().release()}pruneExceptNewestZ(){if(this.getCount()===0)return;const t=this.peekFirstKey(),e=SK(t)[0];this.forEach(i=>{i.tileCoord[0]!==e&&(this.remove(Do(i.tileCoord)),i.release())})}}const Fh={TILELOADSTART:"tileloadstart",TILELOADEND:"tileloadend",TILELOADERROR:"tileloaderror"},Ul=[0,0,0],Ao=5;class ma{constructor(t){this.minZoom=t.minZoom!==void 0?t.minZoom:0,this.resolutions_=t.resolutions,qt(HU(this.resolutions_,(n,r)=>r-n),"`resolutions` must be sorted in descending order");let e;if(!t.origins){for(let n=0,r=this.resolutions_.length-1;n{const o=new h0(Math.min(0,n[0]),Math.max(n[0]-1,-1),Math.min(0,n[1]),Math.max(n[1]-1,-1));if(i){const a=this.getTileRangeForExtentAndZ(i,r);o.minX=Math.max(a.minX,o.minX),o.maxX=Math.min(a.maxX,o.maxX),o.minY=Math.max(a.minY,o.minY),o.maxY=Math.min(a.maxY,o.maxY)}return o}):i&&this.calculateTileRanges_(i)}forEachTileCoord(t,e,i){const n=this.getTileRangeForExtentAndZ(t,e);for(let r=n.minX,o=n.maxX;r<=o;++r)for(let a=n.minY,l=n.maxY;a<=l;++a)i([e,r,a])}forEachTileCoordParentTileRange(t,e,i,n){let r,o,a,l=null,h=t[0]-1;for(this.zoomFactor_===2?(o=t[1],a=t[2]):l=this.getTileCoordExtent(t,n);h>=this.minZoom;){if(o!==void 0&&a!==void 0?(o=Math.floor(o/2),a=Math.floor(a/2),r=Gl(o,o,a,a,i)):r=this.getTileRangeForExtentAndZ(l,h,i),e(h,r))return!0;--h}return!1}getExtent(){return this.extent_}getMaxZoom(){return this.maxZoom}getMinZoom(){return this.minZoom}getOrigin(t){return this.origin_?this.origin_:this.origins_[t]}getResolution(t){return this.resolutions_[t]}getResolutions(){return this.resolutions_}getTileCoordChildTileRange(t,e,i){if(t[0]this.maxZoom||e0?S=e.find(function(w){return v[c]==w[h]?!0:v[c].includes(":")?!1:s[c]+":"+v[c]===w[h]}):S=!0,S){n.push(v[c]);const w=v[u]*28e-5/_,T=v[g],M=v[f];y?r.push([v[d][1],v[d][0]]):r.push(v[d]),i.push(w),o.push(T==M?T:[T,M]),a.push([v.MatrixWidth,v.MatrixHeight])}}),new XJ({extent:t,origins:r,resolutions:i,matrixIds:n,tileSizes:o,sizes:a})}function lw(s){let t=s.getDefaultTileGrid();return t||(t=ZJ(s),s.setDefaultTileGrid(t)),t}function YJ(s,t,e){const i=t[0],n=s.getTileCoordCenter(t),r=yo(e);if(!Yi(r,n)){const o=Rt(r),a=Math.ceil((r[0]-n[0])/o);return n[0]+=o*a,s.getTileCoordForCoordAndZ(n,i)}return t}function qJ(s,t,e,i){i=i!==void 0?i:"top-left";const n=kA(s,t,e);return new ma({extent:s,origin:h9(s,i),resolutions:n,tileSize:e})}function Tl(s){const t=s||{},e=t.extent||st("EPSG:3857").getExtent(),i={extent:e,minZoom:t.minZoom,tileSize:t.tileSize,resolutions:kA(e,t.maxZoom,t.tileSize,t.maxResolution)};return new ma(i)}function kA(s,t,e,i){t=t!==void 0?t:GP,e=Re(e!==void 0?e:cc);const n=Ee(s),r=Rt(s);i=i>0?i:Math.max(r/e[0],n/e[1]);const o=t+1,a=new Array(o);for(let l=0;l{const y=Re(l.getTileSize(_)),v=this.getTileSize(_);return Math.max(v[0]/y[0],v[1]/y[1])})),c=this.getTileGridForProjection(r),u=this.getTileGridForProjection(n),d=[t,e,i],g=this.getTileCoordForTileUrlFunction(d,n),f=Object.assign({sourceProj:r,sourceTileGrid:c,targetProj:n,targetTileGrid:u,tileCoord:d,wrappedTileCoord:g,pixelRatio:h,gutter:this.getGutterForProjection(r),getTileFunction:(m,_,y,v)=>this.getTile(m,_,y,v,r)},this.tileOptions),p=new a0(f);return p.key=this.getKey(),p}getTile(t,e,i,n,r){const o=this.getProjection();if(o&&r&&!qs(o,r))return this.getReprojTile_(t,e,i,r,o);const a=this.getTileSize(t),l=ro(t,e,i);if(this.tileCache.containsKey(l))return this.tileCache.get(l);const h=this.loader_,c=new AbortController,u={signal:c.signal,crossOrigin:this.crossOrigin_},d=this.getTileCoordForTileUrlFunction([t,e,i]);if(!d)return null;const g=d[0],f=d[1],p=d[2];function m(){return lI(function(){return h(g,f,p,u)})}const _=Object.assign({tileCoord:[t,e,i],loader:m,size:a,controller:c},this.tileOptions),y=new kd(_);return y.key=this.getKey(),y.addEventListener(Zt.CHANGE,this.handleTileChange_),this.tileCache.set(l,y),y}handleTileChange_(t){const e=t.target,i=mt(e),n=e.getState();let r;n==X.LOADING?(this.tileLoadingKeys_[i]=!0,r=Fh.TILELOADSTART):i in this.tileLoadingKeys_&&(delete this.tileLoadingKeys_[i],r=n==X.ERROR?Fh.TILELOADERROR:n==X.LOADED?Fh.TILELOADEND:void 0),r&&this.dispatchEvent(new $A(r,e))}getTileGridForProjection(t){const e=this.getProjection();if(this.tileGrid&&(!e||qs(e,t)))return this.tileGrid;const i=mt(t);return i in this.tileGridForProjection_||(this.tileGridForProjection_[i]=lw(t)),this.tileGridForProjection_[i]}setTileGridForProjection(t,e){const i=st(t);if(i){const n=mt(i);n in this.tileGridForProjection_||(this.tileGridForProjection_[n]=e)}}getTileCacheForProjection(t){const e=this.getProjection();if(!e||qs(e,t))return this.tileCache;const i=mt(t);return i in this.tileCacheForProjection_||(this.tileCacheForProjection_[i]=new u0(.1)),this.tileCacheForProjection_[i]}expireCache(t,e){const i=this.getTileCacheForProjection(t);this.tileCache.expireCache(this.tileCache==i?e:{});for(const n in this.tileCacheForProjection_){const r=this.tileCacheForProjection_[n];r.expireCache(r==i?e:{})}}clear(){super.clear();for(const t in this.tileCacheForProjection_)this.tileCacheForProjection_[t].clear()}}function Gs(s){return(t,...e)=>KJ(s,t,e)}function Fc(s,t){return Gs(GA(s,t).get)}const{apply:KJ,construct:mct,defineProperty:_ct,get:yct,getOwnPropertyDescriptor:GA,getPrototypeOf:hw,has:xct,ownKeys:JJ,set:vct,setPrototypeOf:wct}=Reflect,{iterator:Ng,species:Ect,toStringTag:QJ,for:Sct}=Symbol,tQ=Object,{create:cw,defineProperty:eQ,freeze:Mct,is:bct}=tQ,sQ=Array,iQ=sQ.prototype,jA=iQ[Ng],nQ=Gs(jA),zA=ArrayBuffer,rQ=zA.prototype;Fc(rQ,"byteLength");const UM=typeof SharedArrayBuffer<"u"?SharedArrayBuffer:null;UM&&Fc(UM.prototype,"byteLength");const UA=hw(Uint8Array);UA.from;const di=UA.prototype;di[Ng];Gs(di.keys);Gs(di.values);Gs(di.entries);Gs(di.set);Gs(di.reverse);Gs(di.fill);Gs(di.copyWithin);Gs(di.sort);Gs(di.slice);Gs(di.subarray);Fc(di,"buffer");Fc(di,"byteOffset");Fc(di,"length");Fc(di,QJ);const oQ=Uint8Array,BA=Uint16Array,uw=Uint32Array,aQ=Float32Array,Gd=hw([][Ng]()),WA=Gs(Gd.next),lQ=Gs(function*(){}().next),hQ=hw(Gd),cQ=DataView.prototype,uQ=Gs(cQ.getUint16),dw=WeakMap,XA=dw.prototype,VA=Gs(XA.get),dQ=Gs(XA.set),YA=new dw,gQ=cw(null,{next:{value:function(){const s=VA(YA,this);return WA(s)}},[Ng]:{value:function(){return this}}});function fQ(s){if(s[Ng]===jA&&Gd.next===WA)return s;const t=cw(gQ);return dQ(YA,t,nQ(s)),t}const pQ=new dw,mQ=cw(hQ,{next:{value:function(){const s=VA(pQ,this);return lQ(s)},writable:!0,configurable:!0}});for(const s of JJ(Gd))s!=="next"&&eQ(mQ,s,GA(Gd,s));const qA=new zA(4),_Q=new aQ(qA),yQ=new uw(qA),Jn=new BA(512),Qn=new oQ(512);for(let s=0;s<256;++s){const t=s-127;t<-24?(Jn[s]=0,Jn[s|256]=32768,Qn[s]=24,Qn[s|256]=24):t<-14?(Jn[s]=1024>>-t-14,Jn[s|256]=1024>>-t-14|32768,Qn[s]=-t-1,Qn[s|256]=-t-1):t<=15?(Jn[s]=t+15<<10,Jn[s|256]=t+15<<10|32768,Qn[s]=13,Qn[s|256]=13):t<128?(Jn[s]=31744,Jn[s|256]=64512,Qn[s]=24,Qn[s|256]=24):(Jn[s]=31744,Jn[s|256]=64512,Qn[s]=13,Qn[s|256]=13)}const gw=new uw(2048);for(let s=1;s<1024;++s){let t=s<<13,e=0;for(;!(t&8388608);)t<<=1,e-=8388608;t&=-8388609,e+=947912704,gw[s]=t|e}for(let s=1024;s<2048;++s)gw[s]=939524096+(s-1024<<13);const Nc=new uw(64);for(let s=1;s<31;++s)Nc[s]=s<<23;Nc[31]=1199570944;Nc[32]=2147483648;for(let s=33;s<63;++s)Nc[s]=2147483648+(s-32<<23);Nc[63]=3347054592;const ZA=new BA(64);for(let s=1;s<64;++s)s!==32&&(ZA[s]=1024);function xQ(s){const t=s>>10;return yQ[0]=gw[ZA[t]+(s&1023)]+Nc[t],_Q[0]}function HA(s,t,...e){return xQ(uQ(s,t,...fQ(e)))}var qa=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function g0(s){return s&&s.__esModule&&Object.prototype.hasOwnProperty.call(s,"default")?s.default:s}var fw={exports:{}};function KA(s,t,e){const i=e&&e.debug||!1;i&&console.log("[xml-utils] getting "+t+" in "+s);const n=typeof s=="object"?s.outer:s,r=n.slice(0,n.indexOf(">")+1),o=['"',"'"];for(let a=0;a{h.getState()=="ready"&&(h.removeEventListener("change",u),this.changed())};h.addEventListener("change",u)}r=r&&c=="ready"}const o=this.renderSources(t,n);if(this.getRenderer().renderComplete&&r)return this.renderedResolution_=i.resolution,o;if(this.renderedResolution_>.5*i.resolution){const a=this.getSources(t.extent,this.renderedResolution_).filter(l=>!n.includes(l));if(a.length>0)return this.renderSources(t,a)}return o}setStyle(t){if(this.styleVariables_=t.variables||{},this.style_=t,this.hasRenderer()){const e=GM(this.style_,this.getSourceBandCount_());this.getRenderer().reset({vertexShader:e.vertexShader,fragmentShader:e.fragmentShader,uniforms:e.uniforms,paletteTextures:e.paletteTextures}),this.changed()}}updateStyleVariables(t){Object.assign(this.styleVariables_,t),this.changed()}}Hp.prototype.dispose;const nJ=Object.freeze(Object.defineProperty({__proto__:null,Graticule:VH,Group:i0,Heatmap:zK,Image:ew,Layer:Tg,Tile:Yp,Vector:Yv,VectorImage:VK,VectorTile:vA,WebGLPoints:iJ,WebGLTile:Hp},Symbol.toStringTag,{value:"Module"}));var ii=(s,t,e)=>new Promise((i,n)=>{var r=l=>{try{a(e.next(l))}catch(h){n(h)}},o=l=>{try{a(e.throw(l))}catch(h){n(h)}},a=l=>l.done?i(l.value):Promise.resolve(l.value).then(r,o);a((e=e.apply(s,t)).next())}),Vi=Uint8Array,Zu=Uint16Array,rJ=Int32Array,SA=new Vi([0,0,0,0,0,0,0,0,1,1,1,1,2,2,2,2,3,3,3,3,4,4,4,4,5,5,5,5,0,0,0,0]),MA=new Vi([0,0,0,0,1,1,2,2,3,3,4,4,5,5,6,6,7,7,8,8,9,9,10,10,11,11,12,12,13,13,0,0]),oJ=new Vi([16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15]),bA=function(s,t){for(var e=new Zu(31),i=0;i<31;++i)e[i]=t+=1<>1|(ge&21845)<<1,Ar=(Ar&52428)>>2|(Ar&13107)<<2,Ar=(Ar&61680)>>4|(Ar&3855)<<4,RA[ge]=((Ar&65280)>>8|(Ar&255)<<8)>>1;var Ar,ge,Hu=function(s,t,e){for(var i=s.length,n=0,r=new Zu(t);n>l]=h}return a},Og=new Vi(288);for(ge=0;ge<144;++ge)Og[ge]=8;var ge;for(ge=144;ge<256;++ge)Og[ge]=9;var ge;for(ge=256;ge<280;++ge)Og[ge]=7;var ge;for(ge=280;ge<288;++ge)Og[ge]=8;var ge,IA=new Vi(32);for(ge=0;ge<32;++ge)IA[ge]=5;var ge,cJ=Hu(Og,9),uJ=Hu(IA,5),W_=function(s){for(var t=s[0],e=1;et&&(t=s[e]);return t},Pn=function(s,t,e){var i=t/8|0;return(s[i]|s[i+1]<<8)>>(t&7)&e},X_=function(s,t){var e=t/8|0;return(s[e]|s[e+1]<<8|s[e+2]<<16)>>(t&7)},dJ=function(s){return(s+7)/8|0},gJ=function(s,t,e){(e==null||e>s.length)&&(e=s.length);var i=new Vi(e-t);return i.set(s.subarray(t,e)),i},fJ=["unexpected EOF","invalid block type","invalid length/literal","invalid distance","stream finished","no stream handler",,"no callback","invalid UTF-8 data","extra field too long","date not in range 1980-2099","filename too long","stream finishing","invalid zip data"],ji=function(s,t,e){var i=new Error(t||fJ[s]);if(i.code=s,Error.captureStackTrace&&Error.captureStackTrace(i,ji),!e)throw i;return i},ow=function(s,t,e,i){var n=s.length,r=0;if(!n||t.f&&!t.l)return e||new Vi(0);var o=!e||t.i!=2,a=t.i;e||(e=new Vi(n*3));var l=function(bt){var oe=e.length;if(bt>oe){var Pe=new Vi(Math.max(oe*2,bt));Pe.set(e),e=Pe}},h=t.f||0,c=t.p||0,u=t.b||0,d=t.l,g=t.d,f=t.m,p=t.n,m=n*8;do{if(!d){h=Pn(s,c,1);var _=Pn(s,c+1,3);if(c+=3,_)if(_==1)d=cJ,g=uJ,f=9,p=5;else if(_==2){var y=Pn(s,c,31)+257,v=Pn(s,c+10,15)+4,S=y+Pn(s,c+5,31)+1;c+=14;for(var w=new Vi(S),C=new Vi(19),M=0;M>4;if(D<16)w[M++]=D;else{var x=0,E=0;for(D==16?(E=3+Pn(s,c,3),c+=2,x=w[M-1]):D==17?(E=3+Pn(s,c,7),c+=3):D==18&&(E=11+Pn(s,c,127),c+=7);E--;)w[M++]=x}}var b=w.subarray(0,y),R=w.subarray(y);f=W_(b),p=W_(R),d=Hu(b,f),g=Hu(R,p)}else ji(1);else{var D=dJ(c)+4,A=s[D-4]|s[D-3]<<8,$=D+A;if($>n){a&&ji(0);break}o&&l(u+A),e.set(s.subarray(D,$),u),t.b=u+=A,t.p=c=$*8,t.f=h;continue}if(c>m){a&&ji(0);break}}o&&l(u+131072);for(var G=(1<>4;if(c+=x&15,c>m){a&&ji(0);break}if(x||ji(2),V<256)e[u++]=V;else if(V==256){z=c,d=null;break}else{var et=V-254;if(V>264){var M=V-257,F=SA[M];et=Pn(s,c,(1<>4;ot||ji(3),c+=ot&15;var R=hJ[ht];if(ht>3){var F=MA[ht];R+=X_(s,c)&(1<m){a&&ji(0);break}o&&l(u+131072);var pt=u+et;if(u>3&1)+(t>>4&1);i>0;i-=!s[e++]);return e+(t&2)},_J=function(s){var t=s.length;return(s[t-4]|s[t-3]<<8|s[t-2]<<16|s[t-1]<<24)>>>0},yJ=function(s,t){return((s[0]&15)!=8||s[0]>>4>7||(s[0]<<8|s[1])%31)&&ji(6,"invalid zlib data"),(s[1]>>5&1)==+!t&&ji(6,"invalid zlib data: "+(s[1]&32?"need":"unexpected")+" dictionary"),(s[1]>>3&4)+2};function xJ(s,t){return ow(s,{i:2},t,t)}function vJ(s,t){var e=mJ(s);return e+8>s.length&&ji(6,"invalid gzip data"),ow(s.subarray(e,-8),{i:2},new Vi(_J(s)),t)}function wJ(s,t){return ow(s.subarray(yJ(s,t),-4),{i:2},t,t)}function dy(s,t){return s[0]==31&&s[1]==139&&s[2]==8?vJ(s,t):(s[0]&15)!=8||s[0]>>4>7||(s[0]<<8|s[1])%31?xJ(s,t):wJ(s,t)}var EJ=typeof TextDecoder<"u"&&new TextDecoder,SJ=0;try{EJ.decode(pJ,{stream:!0}),SJ=1}catch{}var PA=(s,t)=>s*Math.pow(2,t),ou=(s,t)=>Math.floor(s/Math.pow(2,t)),Kp=(s,t)=>PA(s.getUint16(t+1,!0),8)+s.getUint8(t),AA=(s,t)=>PA(s.getUint32(t+2,!0),16)+s.getUint16(t,!0),MJ=(s,t,e,i,n)=>{if(s!=i.getUint8(n))return s-i.getUint8(n);const r=Kp(i,n+1);if(t!=r)return t-r;const o=Kp(i,n+4);return e!=o?e-o:0},bJ=(s,t,e,i)=>{const n=LA(s,t|128,e,i);return n?{z:t,x:e,y:i,offset:n[0],length:n[1],is_dir:!0}:null},jM=(s,t,e,i)=>{const n=LA(s,t,e,i);return n?{z:t,x:e,y:i,offset:n[0],length:n[1],is_dir:!1}:null},LA=(s,t,e,i)=>{let n=0,r=s.byteLength/17-1;for(;n<=r;){const o=r+n>>1,a=MJ(t,e,i,s,o*17);if(a>0)n=o+1;else if(a<0)r=o-1;else return[AA(s,o*17+7),s.getUint32(o*17+13,!0)]}return null},CJ=(s,t)=>s.is_dir&&!t.is_dir?1:!s.is_dir&&t.is_dir?-1:s.z!==t.z?s.z-t.z:s.x!==t.x?s.x-t.x:s.y-t.y,OA=(s,t)=>{const e=s.getUint8(t*17);return{z:e&127,x:Kp(s,t*17+1),y:Kp(s,t*17+4),offset:AA(s,t*17+7),length:s.getUint32(t*17+13,!0),is_dir:e>>7===1}},zM=s=>{const t=[],e=new DataView(s);for(let i=0;i{s.sort(CJ);const t=new ArrayBuffer(17*s.length),e=new Uint8Array(t);for(let i=0;i>8&255,e[i*17+3]=n.x>>16&255,e[i*17+4]=n.y&255,e[i*17+5]=n.y>>8&255,e[i*17+6]=n.y>>16&255,e[i*17+7]=n.offset&255,e[i*17+8]=ou(n.offset,8)&255,e[i*17+9]=ou(n.offset,16)&255,e[i*17+10]=ou(n.offset,24)&255,e[i*17+11]=ou(n.offset,32)&255,e[i*17+12]=ou(n.offset,48)&255,e[i*17+13]=n.length&255,e[i*17+14]=n.length>>8&255,e[i*17+15]=n.length>>16&255,e[i*17+16]=n.length>>24&255}return t},RJ=(s,t)=>{if(s.byteLength<17)return null;const e=s.byteLength/17,i=OA(s,e-1);if(i.is_dir){const n=i.z,r=t.z-n,o=Math.trunc(t.x/(1<>>0)*4294967296+(s>>>0)}function LJ(s,t){const e=t.buf;let i,n;if(n=e[t.pos++],i=(n&112)>>4,n<128||(n=e[t.pos++],i|=(n&127)<<3,n<128)||(n=e[t.pos++],i|=(n&127)<<10,n<128)||(n=e[t.pos++],i|=(n&127)<<17,n<128)||(n=e[t.pos++],i|=(n&127)<<24,n<128)||(n=e[t.pos++],i|=(n&1)<<31,n<128))return AJ(s,i);throw new Error("Expected varint not more than 10 bytes")}function au(s){const t=s.buf;let e,i;return i=t[s.pos++],e=i&127,i<128||(i=t[s.pos++],e|=(i&127)<<7,i<128)||(i=t[s.pos++],e|=(i&127)<<14,i<128)||(i=t[s.pos++],e|=(i&127)<<21,i<128)?e:(i=t[s.pos],e|=(i&15)<<28,LJ(e,s))}function OJ(s,t,e,i){if(i==0){e==1&&(t[0]=s-1-t[0],t[1]=s-1-t[1]);const n=t[0];t[0]=t[1],t[1]=n}}var FJ=[0,1,5,21,85,341,1365,5461,21845,87381,349525,1398101,5592405,22369621,89478485,357913941,1431655765,5726623061,22906492245,91625968981,366503875925,1466015503701,5864062014805,23456248059221,93824992236885,375299968947541,0x5555555555555];function NJ(s,t,e){if(s>26)throw Error("Tile zoom level exceeds max safe number limit (26)");if(t>Math.pow(2,s)-1||e>Math.pow(2,s)-1)throw Error("tile x/y outside zoom level bounds");const i=FJ[s],n=Math.pow(2,s);let r=0,o=0,a=0;const l=[t,e];let h=n/2;for(;h>0;)r=(l[0]&h)>0?1:0,o=(l[1]&h)>0?1:0,a+=h*h*(3*r^o),OJ(h,l,r,o),h=h/2;return i+a}function NA(s,t){return ii(this,null,function*(){if(t===1||t===0)return s;if(t===2){if(typeof globalThis.DecompressionStream>"u")return dy(new Uint8Array(s));{let e=new Response(s).body.pipeThrough(new globalThis.DecompressionStream("gzip"));return new Response(e).arrayBuffer()}}else throw Error("Compression method not supported")})}var th=(s=>(s[s.Unknown=0]="Unknown",s[s.Mvt=1]="Mvt",s[s.Png=2]="Png",s[s.Jpeg=3]="Jpeg",s[s.Webp=4]="Webp",s[s.Avif=5]="Avif",s))(th||{}),DJ=127;function kJ(s,t){let e=0,i=s.length-1;for(;e<=i;){const n=i+e>>1,r=t-s[n].tileId;if(r>0)e=n+1;else if(r<0)i=n-1;else return s[n]}return i>=0&&(s[i].runLength===0||t-s[i].tileId=300)throw Error("Bad response code: "+r.status);const o=r.headers.get("Content-Length");if(r.status===200&&(!o||+o>t))throw i&&i.abort(),Error("Server returned no content-length header or content-length exceeding request. Check that your storage backend supports HTTP Byte Serving.");return{data:yield r.arrayBuffer(),etag:r.headers.get("ETag")||void 0,cacheControl:r.headers.get("Cache-Control")||void 0,expires:r.headers.get("Expires")||void 0}})}};function An(s,t){const e=s.getUint32(t+4,!0),i=s.getUint32(t+0,!0);return e*Math.pow(2,32)+i}function GJ(s,t){const e=new DataView(s),i=e.getUint8(7);if(i>3)throw Error(`Archive is spec version ${i} but this library supports up to spec version 3`);return{specVersion:i,rootDirectoryOffset:An(e,8),rootDirectoryLength:An(e,16),jsonMetadataOffset:An(e,24),jsonMetadataLength:An(e,32),leafDirectoryOffset:An(e,40),leafDirectoryLength:An(e,48),tileDataOffset:An(e,56),tileDataLength:An(e,64),numAddressedTiles:An(e,72),numTileEntries:An(e,80),numTileContents:An(e,88),clustered:e.getUint8(96)===1,internalCompression:e.getUint8(97),tileCompression:e.getUint8(98),tileType:e.getUint8(99),minZoom:e.getUint8(100),maxZoom:e.getUint8(101),minLon:e.getInt32(102,!0)/1e7,minLat:e.getInt32(106,!0)/1e7,maxLon:e.getInt32(110,!0)/1e7,maxLat:e.getInt32(114,!0)/1e7,centerZoom:e.getUint8(118),centerLon:e.getInt32(119,!0)/1e7,centerLat:e.getInt32(123,!0)/1e7,etag:t}}function DA(s){const t={buf:new Uint8Array(s),pos:0},e=au(t),i=[];let n=0;for(let r=0;r0?i[r].offset=i[r-1].offset+i[r-1].length:i[r].offset=o-1}return i}function jJ(s){const t=new DataView(s);return t.getUint16(2,!0)===2?(console.warn("PMTiles spec version 2 has been deprecated; please see github.com/protomaps/PMTiles for tools to upgrade"),2):t.getUint16(2,!0)===1?(console.warn("PMTiles spec version 1 has been deprecated; please see github.com/protomaps/PMTiles for tools to upgrade"),1):3}var _h=class extends Error{};function zJ(s,t,e,i){return ii(this,null,function*(){const n=yield s.getBytes(0,16384);if(new DataView(n.data).getUint16(0,!0)!==19792)throw new Error("Wrong magic number for PMTiles archive");if(jJ(n.data)<3)return[yield FA.getHeader(s)];const r=n.data.slice(0,DJ);let o=n.etag;i&&n.etag!=i&&(console.warn("ETag conflict detected; your HTTP server might not support content-based ETag headers. ETags disabled for "+s.getKey()),o=void 0);const a=GJ(r,o);if(e){const l=n.data.slice(a.rootDirectoryOffset,a.rootDirectoryOffset+a.rootDirectoryLength),h=s.getKey()+"|"+(a.etag||"")+"|"+a.rootDirectoryOffset+"|"+a.rootDirectoryLength,c=DA(yield t(l,a.internalCompression));return[a,[h,c.length,c]]}return[a,void 0]})}function UJ(s,t,e,i,n){return ii(this,null,function*(){const r=yield s.getBytes(e,i);if(n.etag&&n.etag!==r.etag)throw new _h(r.etag);const o=yield t(r.data,n.internalCompression),a=DA(o);if(a.length===0)throw new Error("Empty directory is invalid");return a})}var BJ=class{constructor(s=100,t=!0,e=NA){this.cache=new Map,this.maxCacheEntries=s,this.counter=1,this.prefetch=t,this.decompress=e}getHeader(s,t){return ii(this,null,function*(){const e=s.getKey();if(this.cache.has(e))return this.cache.get(e).lastUsed=this.counter++,yield this.cache.get(e).data;const i=new Promise((n,r)=>{zJ(s,this.decompress,this.prefetch,t).then(o=>{o[1]&&this.cache.set(o[1][0],{lastUsed:this.counter++,data:Promise.resolve(o[1][2])}),n(o[0]),this.prune()}).catch(o=>{r(o)})});return this.cache.set(e,{lastUsed:this.counter++,data:i}),i})}getDirectory(s,t,e,i){return ii(this,null,function*(){const n=s.getKey()+"|"+(i.etag||"")+"|"+t+"|"+e;if(this.cache.has(n))return this.cache.get(n).lastUsed=this.counter++,yield this.cache.get(n).data;const r=new Promise((o,a)=>{UJ(s,this.decompress,t,e,i).then(l=>{o(l),this.prune()}).catch(l=>{a(l)})});return this.cache.set(n,{lastUsed:this.counter++,data:r}),r})}getArrayBuffer(s,t,e,i){return ii(this,null,function*(){const n=s.getKey()+"|"+(i.etag||"")+"|"+t+"|"+e;if(this.cache.has(n))return this.cache.get(n).lastUsed=this.counter++,yield this.cache.get(n).data;const r=new Promise((o,a)=>{s.getBytes(t,e).then(l=>{if(i.etag&&i.etag!==l.etag)throw new _h(l.etag);o(l.data),this.cache.has(n),this.prune()}).catch(l=>{a(l)})});return this.cache.set(n,{lastUsed:this.counter++,data:r}),r})}prune(){if(this.cache.size>=this.maxCacheEntries){let s=1/0,t;this.cache.forEach((e,i)=>{e.lastUsedr.maxZoom)return;let o=r.rootDirectoryOffset,a=r.rootDirectoryLength;for(let l=0;l<=3;l++){const h=yield this.cache.getDirectory(this.source,o,a,r),c=kJ(h,n);if(c)if(c.runLength>0){const u=yield this.source.getBytes(r.tileDataOffset+c.offset,c.length,i);if(r.etag&&r.etag!==u.etag)throw new _h(u.etag);return{data:yield this.decompress(u.data,r.tileCompression),cacheControl:u.cacheControl,expires:u.expires}}else o=r.leafDirectoryOffset+c.offset,a=c.length;else return}throw Error("Maximum directory depth exceeded")})}getZxy(s,t,e,i){return ii(this,null,function*(){try{return yield this.getZxyAttempt(s,t,e,i)}catch(n){if(n instanceof _h)return this.cache.invalidate(this.source,n.message),yield this.getZxyAttempt(s,t,e,i);throw n}})}getMetadataAttempt(){return ii(this,null,function*(){const s=yield this.cache.getHeader(this.source),t=yield this.source.getBytes(s.jsonMetadataOffset,s.jsonMetadataLength);if(s.etag&&s.etag!==t.etag)throw new _h(t.etag);const e=yield this.decompress(t.data,s.internalCompression),i=new TextDecoder("utf-8");return JSON.parse(i.decode(e))})}getMetadata(){return ii(this,null,function*(){try{return yield this.getMetadataAttempt()}catch(s){if(s instanceof _h)return this.cache.invalidate(this.source,s.message),yield this.getMetadataAttempt();throw s}})}};class WJ extends Sr{constructor(t){super(Zt.ERROR),this.error=t}}class u0 extends l0{clear(){for(;this.getCount()>0;)this.pop().release();super.clear()}expireCache(t){for(;this.canExpireCache()&&!(this.peekLast().getKey()in t);)this.pop().release()}pruneExceptNewestZ(){if(this.getCount()===0)return;const t=this.peekFirstKey(),e=SK(t)[0];this.forEach(i=>{i.tileCoord[0]!==e&&(this.remove(Do(i.tileCoord)),i.release())})}}const Fh={TILELOADSTART:"tileloadstart",TILELOADEND:"tileloadend",TILELOADERROR:"tileloaderror"},Ul=[0,0,0],Ao=5;class ma{constructor(t){this.minZoom=t.minZoom!==void 0?t.minZoom:0,this.resolutions_=t.resolutions,qt(HU(this.resolutions_,(n,r)=>r-n),"`resolutions` must be sorted in descending order");let e;if(!t.origins){for(let n=0,r=this.resolutions_.length-1;n{const o=new h0(Math.min(0,n[0]),Math.max(n[0]-1,-1),Math.min(0,n[1]),Math.max(n[1]-1,-1));if(i){const a=this.getTileRangeForExtentAndZ(i,r);o.minX=Math.max(a.minX,o.minX),o.maxX=Math.min(a.maxX,o.maxX),o.minY=Math.max(a.minY,o.minY),o.maxY=Math.min(a.maxY,o.maxY)}return o}):i&&this.calculateTileRanges_(i)}forEachTileCoord(t,e,i){const n=this.getTileRangeForExtentAndZ(t,e);for(let r=n.minX,o=n.maxX;r<=o;++r)for(let a=n.minY,l=n.maxY;a<=l;++a)i([e,r,a])}forEachTileCoordParentTileRange(t,e,i,n){let r,o,a,l=null,h=t[0]-1;for(this.zoomFactor_===2?(o=t[1],a=t[2]):l=this.getTileCoordExtent(t,n);h>=this.minZoom;){if(o!==void 0&&a!==void 0?(o=Math.floor(o/2),a=Math.floor(a/2),r=Gl(o,o,a,a,i)):r=this.getTileRangeForExtentAndZ(l,h,i),e(h,r))return!0;--h}return!1}getExtent(){return this.extent_}getMaxZoom(){return this.maxZoom}getMinZoom(){return this.minZoom}getOrigin(t){return this.origin_?this.origin_:this.origins_[t]}getResolution(t){return this.resolutions_[t]}getResolutions(){return this.resolutions_}getTileCoordChildTileRange(t,e,i){if(t[0]this.maxZoom||e0?S=e.find(function(w){return v[c]==w[h]?!0:v[c].includes(":")?!1:s[c]+":"+v[c]===w[h]}):S=!0,S){n.push(v[c]);const w=v[u]*28e-5/_,C=v[g],M=v[f];y?r.push([v[d][1],v[d][0]]):r.push(v[d]),i.push(w),o.push(C==M?C:[C,M]),a.push([v.MatrixWidth,v.MatrixHeight])}}),new XJ({extent:t,origins:r,resolutions:i,matrixIds:n,tileSizes:o,sizes:a})}function lw(s){let t=s.getDefaultTileGrid();return t||(t=ZJ(s),s.setDefaultTileGrid(t)),t}function YJ(s,t,e){const i=t[0],n=s.getTileCoordCenter(t),r=yo(e);if(!Yi(r,n)){const o=Rt(r),a=Math.ceil((r[0]-n[0])/o);return n[0]+=o*a,s.getTileCoordForCoordAndZ(n,i)}return t}function qJ(s,t,e,i){i=i!==void 0?i:"top-left";const n=kA(s,t,e);return new ma({extent:s,origin:h9(s,i),resolutions:n,tileSize:e})}function Cl(s){const t=s||{},e=t.extent||st("EPSG:3857").getExtent(),i={extent:e,minZoom:t.minZoom,tileSize:t.tileSize,resolutions:kA(e,t.maxZoom,t.tileSize,t.maxResolution)};return new ma(i)}function kA(s,t,e,i){t=t!==void 0?t:GP,e=Re(e!==void 0?e:cc);const n=Ee(s),r=Rt(s);i=i>0?i:Math.max(r/e[0],n/e[1]);const o=t+1,a=new Array(o);for(let l=0;l{const y=Re(l.getTileSize(_)),v=this.getTileSize(_);return Math.max(v[0]/y[0],v[1]/y[1])})),c=this.getTileGridForProjection(r),u=this.getTileGridForProjection(n),d=[t,e,i],g=this.getTileCoordForTileUrlFunction(d,n),f=Object.assign({sourceProj:r,sourceTileGrid:c,targetProj:n,targetTileGrid:u,tileCoord:d,wrappedTileCoord:g,pixelRatio:h,gutter:this.getGutterForProjection(r),getTileFunction:(m,_,y,v)=>this.getTile(m,_,y,v,r)},this.tileOptions),p=new a0(f);return p.key=this.getKey(),p}getTile(t,e,i,n,r){const o=this.getProjection();if(o&&r&&!qs(o,r))return this.getReprojTile_(t,e,i,r,o);const a=this.getTileSize(t),l=ro(t,e,i);if(this.tileCache.containsKey(l))return this.tileCache.get(l);const h=this.loader_,c=new AbortController,u={signal:c.signal,crossOrigin:this.crossOrigin_},d=this.getTileCoordForTileUrlFunction([t,e,i]);if(!d)return null;const g=d[0],f=d[1],p=d[2];function m(){return lI(function(){return h(g,f,p,u)})}const _=Object.assign({tileCoord:[t,e,i],loader:m,size:a,controller:c},this.tileOptions),y=new kd(_);return y.key=this.getKey(),y.addEventListener(Zt.CHANGE,this.handleTileChange_),this.tileCache.set(l,y),y}handleTileChange_(t){const e=t.target,i=mt(e),n=e.getState();let r;n==X.LOADING?(this.tileLoadingKeys_[i]=!0,r=Fh.TILELOADSTART):i in this.tileLoadingKeys_&&(delete this.tileLoadingKeys_[i],r=n==X.ERROR?Fh.TILELOADERROR:n==X.LOADED?Fh.TILELOADEND:void 0),r&&this.dispatchEvent(new $A(r,e))}getTileGridForProjection(t){const e=this.getProjection();if(this.tileGrid&&(!e||qs(e,t)))return this.tileGrid;const i=mt(t);return i in this.tileGridForProjection_||(this.tileGridForProjection_[i]=lw(t)),this.tileGridForProjection_[i]}setTileGridForProjection(t,e){const i=st(t);if(i){const n=mt(i);n in this.tileGridForProjection_||(this.tileGridForProjection_[n]=e)}}getTileCacheForProjection(t){const e=this.getProjection();if(!e||qs(e,t))return this.tileCache;const i=mt(t);return i in this.tileCacheForProjection_||(this.tileCacheForProjection_[i]=new u0(.1)),this.tileCacheForProjection_[i]}expireCache(t,e){const i=this.getTileCacheForProjection(t);this.tileCache.expireCache(this.tileCache==i?e:{});for(const n in this.tileCacheForProjection_){const r=this.tileCacheForProjection_[n];r.expireCache(r==i?e:{})}}clear(){super.clear();for(const t in this.tileCacheForProjection_)this.tileCacheForProjection_[t].clear()}}function Gs(s){return(t,...e)=>KJ(s,t,e)}function Fc(s,t){return Gs(GA(s,t).get)}const{apply:KJ,construct:mct,defineProperty:_ct,get:yct,getOwnPropertyDescriptor:GA,getPrototypeOf:hw,has:xct,ownKeys:JJ,set:vct,setPrototypeOf:wct}=Reflect,{iterator:Ng,species:Ect,toStringTag:QJ,for:Sct}=Symbol,tQ=Object,{create:cw,defineProperty:eQ,freeze:Mct,is:bct}=tQ,sQ=Array,iQ=sQ.prototype,jA=iQ[Ng],nQ=Gs(jA),zA=ArrayBuffer,rQ=zA.prototype;Fc(rQ,"byteLength");const UM=typeof SharedArrayBuffer<"u"?SharedArrayBuffer:null;UM&&Fc(UM.prototype,"byteLength");const UA=hw(Uint8Array);UA.from;const di=UA.prototype;di[Ng];Gs(di.keys);Gs(di.values);Gs(di.entries);Gs(di.set);Gs(di.reverse);Gs(di.fill);Gs(di.copyWithin);Gs(di.sort);Gs(di.slice);Gs(di.subarray);Fc(di,"buffer");Fc(di,"byteOffset");Fc(di,"length");Fc(di,QJ);const oQ=Uint8Array,BA=Uint16Array,uw=Uint32Array,aQ=Float32Array,Gd=hw([][Ng]()),WA=Gs(Gd.next),lQ=Gs(function*(){}().next),hQ=hw(Gd),cQ=DataView.prototype,uQ=Gs(cQ.getUint16),dw=WeakMap,XA=dw.prototype,VA=Gs(XA.get),dQ=Gs(XA.set),YA=new dw,gQ=cw(null,{next:{value:function(){const s=VA(YA,this);return WA(s)}},[Ng]:{value:function(){return this}}});function fQ(s){if(s[Ng]===jA&&Gd.next===WA)return s;const t=cw(gQ);return dQ(YA,t,nQ(s)),t}const pQ=new dw,mQ=cw(hQ,{next:{value:function(){const s=VA(pQ,this);return lQ(s)},writable:!0,configurable:!0}});for(const s of JJ(Gd))s!=="next"&&eQ(mQ,s,GA(Gd,s));const qA=new zA(4),_Q=new aQ(qA),yQ=new uw(qA),Jn=new BA(512),Qn=new oQ(512);for(let s=0;s<256;++s){const t=s-127;t<-24?(Jn[s]=0,Jn[s|256]=32768,Qn[s]=24,Qn[s|256]=24):t<-14?(Jn[s]=1024>>-t-14,Jn[s|256]=1024>>-t-14|32768,Qn[s]=-t-1,Qn[s|256]=-t-1):t<=15?(Jn[s]=t+15<<10,Jn[s|256]=t+15<<10|32768,Qn[s]=13,Qn[s|256]=13):t<128?(Jn[s]=31744,Jn[s|256]=64512,Qn[s]=24,Qn[s|256]=24):(Jn[s]=31744,Jn[s|256]=64512,Qn[s]=13,Qn[s|256]=13)}const gw=new uw(2048);for(let s=1;s<1024;++s){let t=s<<13,e=0;for(;!(t&8388608);)t<<=1,e-=8388608;t&=-8388609,e+=947912704,gw[s]=t|e}for(let s=1024;s<2048;++s)gw[s]=939524096+(s-1024<<13);const Nc=new uw(64);for(let s=1;s<31;++s)Nc[s]=s<<23;Nc[31]=1199570944;Nc[32]=2147483648;for(let s=33;s<63;++s)Nc[s]=2147483648+(s-32<<23);Nc[63]=3347054592;const ZA=new BA(64);for(let s=1;s<64;++s)s!==32&&(ZA[s]=1024);function xQ(s){const t=s>>10;return yQ[0]=gw[ZA[t]+(s&1023)]+Nc[t],_Q[0]}function HA(s,t,...e){return xQ(uQ(s,t,...fQ(e)))}var qa=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function g0(s){return s&&s.__esModule&&Object.prototype.hasOwnProperty.call(s,"default")?s.default:s}var fw={exports:{}};function KA(s,t,e){const i=e&&e.debug||!1;i&&console.log("[xml-utils] getting "+t+" in "+s);const n=typeof s=="object"?s.outer:s,r=n.slice(0,n.indexOf(">")+1),o=['"',"'"];for(let a=0;a/]`,r);if(i&&console.log("[xml-utils] start:",o),o===-1)return;const a=s.slice(o+t.length);let l=Y_(a,"^[^<]*[ /]>",0);const h=l!==-1&&a[l-1]==="/";if(i&&console.log("[xml-utils] selfClosing:",h),h===!1)if(n){let g=0,f=1,p=0;for(;(l=Y_(a,"[ /]"+t+">",g))!==-1;){const m=a.substring(g,l+1);if(f+=BM(m,"<"+t+`[ - >]`),p+=BM(m,""),p>=f)break;g=l}}else l=Y_(a,"[ /]"+t+">",0);const c=o+t.length+l+1;if(i&&console.log("[xml-utils] end:",c),c===-1)return;const u=s.slice(o,c);let d;return h?d=null:d=u.slice(u.indexOf(">")+1,u.lastIndexOf("<")),{inner:d,outer:u,start:o,end:c}}mw.exports=eL;mw.exports.default=eL;var bQ=mw.exports;const TQ=bQ;function sL(s,t,e){const i=[],n=e&&e.debug||!1,r=e&&typeof e.nested=="boolean"?e.nested:!0;let o=e&&e.startIndex||0,a;for(;a=TQ(s,t,{debug:n,startIndex:o});)r?o=a.start+1+t.length:o=a.end,i.push(a);return n&&console.log("findTagsByName found",i.length,"tags"),i}pw.exports=sL;pw.exports.default=sL;var CQ=pw.exports;const RQ=g0(CQ),Ku={315:"Artist",258:"BitsPerSample",265:"CellLength",264:"CellWidth",320:"ColorMap",259:"Compression",33432:"Copyright",306:"DateTime",338:"ExtraSamples",266:"FillOrder",289:"FreeByteCounts",288:"FreeOffsets",291:"GrayResponseCurve",290:"GrayResponseUnit",316:"HostComputer",270:"ImageDescription",257:"ImageLength",256:"ImageWidth",271:"Make",281:"MaxSampleValue",280:"MinSampleValue",272:"Model",254:"NewSubfileType",274:"Orientation",262:"PhotometricInterpretation",284:"PlanarConfiguration",296:"ResolutionUnit",278:"RowsPerStrip",277:"SamplesPerPixel",305:"Software",279:"StripByteCounts",273:"StripOffsets",255:"SubfileType",263:"Threshholding",282:"XResolution",283:"YResolution",326:"BadFaxLines",327:"CleanFaxData",343:"ClipPath",328:"ConsecutiveBadFaxLines",433:"Decode",434:"DefaultImageColor",269:"DocumentName",336:"DotRange",321:"HalftoneHints",346:"Indexed",347:"JPEGTables",285:"PageName",297:"PageNumber",317:"Predictor",319:"PrimaryChromaticities",532:"ReferenceBlackWhite",339:"SampleFormat",340:"SMinSampleValue",341:"SMaxSampleValue",559:"StripRowCounts",330:"SubIFDs",292:"T4Options",293:"T6Options",325:"TileByteCounts",323:"TileLength",324:"TileOffsets",322:"TileWidth",301:"TransferFunction",318:"WhitePoint",344:"XClipPathUnits",286:"XPosition",529:"YCbCrCoefficients",531:"YCbCrPositioning",530:"YCbCrSubSampling",345:"YClipPathUnits",287:"YPosition",37378:"ApertureValue",40961:"ColorSpace",36868:"DateTimeDigitized",36867:"DateTimeOriginal",34665:"Exif IFD",36864:"ExifVersion",33434:"ExposureTime",41728:"FileSource",37385:"Flash",40960:"FlashpixVersion",33437:"FNumber",42016:"ImageUniqueID",37384:"LightSource",37500:"MakerNote",37377:"ShutterSpeedValue",37510:"UserComment",33723:"IPTC",34675:"ICC Profile",700:"XMP",42112:"GDAL_METADATA",42113:"GDAL_NODATA",34377:"Photoshop",33550:"ModelPixelScale",33922:"ModelTiepoint",34264:"ModelTransformation",34735:"GeoKeyDirectory",34736:"GeoDoubleParams",34737:"GeoAsciiParams",50674:"LercParameters"},er={};for(const s in Ku)Ku.hasOwnProperty(s)&&(er[Ku[s]]=parseInt(s,10));const IQ=[er.BitsPerSample,er.ExtraSamples,er.SampleFormat,er.StripByteCounts,er.StripOffsets,er.StripRowCounts,er.TileByteCounts,er.TileOffsets,er.SubIFDs],q_={1:"BYTE",2:"ASCII",3:"SHORT",4:"LONG",5:"RATIONAL",6:"SBYTE",7:"UNDEFINED",8:"SSHORT",9:"SLONG",10:"SRATIONAL",11:"FLOAT",12:"DOUBLE",13:"IFD",16:"LONG8",17:"SLONG8",18:"IFD8"},Ut={};for(const s in q_)q_.hasOwnProperty(s)&&(Ut[q_[s]]=parseInt(s,10));const gi={WhiteIsZero:0,BlackIsZero:1,RGB:2,Palette:3,TransparencyMask:4,CMYK:5,YCbCr:6,CIELab:8,ICCLab:9},PQ={Unspecified:0,Assocalpha:1,Unassalpha:2},Tct={Version:0,AddCompression:1},Cct={None:0,Deflate:1,Zstandard:2},AQ={1024:"GTModelTypeGeoKey",1025:"GTRasterTypeGeoKey",1026:"GTCitationGeoKey",2048:"GeographicTypeGeoKey",2049:"GeogCitationGeoKey",2050:"GeogGeodeticDatumGeoKey",2051:"GeogPrimeMeridianGeoKey",2052:"GeogLinearUnitsGeoKey",2053:"GeogLinearUnitSizeGeoKey",2054:"GeogAngularUnitsGeoKey",2055:"GeogAngularUnitSizeGeoKey",2056:"GeogEllipsoidGeoKey",2057:"GeogSemiMajorAxisGeoKey",2058:"GeogSemiMinorAxisGeoKey",2059:"GeogInvFlatteningGeoKey",2060:"GeogAzimuthUnitsGeoKey",2061:"GeogPrimeMeridianLongGeoKey",2062:"GeogTOWGS84GeoKey",3072:"ProjectedCSTypeGeoKey",3073:"PCSCitationGeoKey",3074:"ProjectionGeoKey",3075:"ProjCoordTransGeoKey",3076:"ProjLinearUnitsGeoKey",3077:"ProjLinearUnitSizeGeoKey",3078:"ProjStdParallel1GeoKey",3079:"ProjStdParallel2GeoKey",3080:"ProjNatOriginLongGeoKey",3081:"ProjNatOriginLatGeoKey",3082:"ProjFalseEastingGeoKey",3083:"ProjFalseNorthingGeoKey",3084:"ProjFalseOriginLongGeoKey",3085:"ProjFalseOriginLatGeoKey",3086:"ProjFalseOriginEastingGeoKey",3087:"ProjFalseOriginNorthingGeoKey",3088:"ProjCenterLongGeoKey",3089:"ProjCenterLatGeoKey",3090:"ProjCenterEastingGeoKey",3091:"ProjCenterNorthingGeoKey",3092:"ProjScaleAtNatOriginGeoKey",3093:"ProjScaleAtCenterGeoKey",3094:"ProjAzimuthAngleGeoKey",3095:"ProjStraightVertPoleLongGeoKey",3096:"ProjRectifiedGridAngleGeoKey",4096:"VerticalCSTypeGeoKey",4097:"VerticalCitationGeoKey",4098:"VerticalDatumGeoKey",4099:"VerticalUnitsGeoKey"};function LQ(s,t){const{width:e,height:i}=s,n=new Uint8Array(e*i*3);let r;for(let o=0,a=0;o>24,l=s[n+2]<<24>>24;let h=(o+16)/116,c=a/500+h,u=h-l/200,d,g,f;c=kQ*(c*c*c>.008856?c*c*c:(c-16/116)/7.787),h=$Q*(h*h*h>.008856?h*h*h:(h-16/116)/7.787),u=GQ*(u*u*u>.008856?u*u*u:(u-16/116)/7.787),d=c*3.2406+h*-1.5372+u*-.4986,g=c*-.9689+h*1.8758+u*.0415,f=c*.0557+h*-.204+u*1.057,d=d>.0031308?1.055*d**(1/2.4)-.055:12.92*d,g=g>.0031308?1.055*g**(1/2.4)-.055:12.92*g,f=f>.0031308?1.055*f**(1/2.4)-.055:12.92*f,i[r]=Math.max(0,Math.min(1,d))*255,i[r+1]=Math.max(0,Math.min(1,g))*255,i[r+2]=Math.max(0,Math.min(1,f))*255}return i}const iL=new Map;function _a(s,t){Array.isArray(s)||(s=[s]),s.forEach(e=>iL.set(e,t))}async function nL(s){const t=iL.get(s.Compression);if(!t)throw new Error(`Unknown compression method identifier: ${s.Compression}`);const e=await t();return new e(s)}_a([void 0,1],()=>da(()=>import("./raw-CMGvRjfu-Blplg0lv.js"),__vite__mapDeps([0,1])).then(s=>s.default));_a(5,()=>da(()=>import("./lzw-LAGDNbSC-uvu3SnH0.js"),__vite__mapDeps([2,1])).then(s=>s.default));_a(6,()=>{throw new Error("old style JPEG compression is not supported.")});_a(7,()=>da(()=>import("./jpeg-BAgeD1d3-DG6CHa_P.js"),__vite__mapDeps([3,1])).then(s=>s.default));_a([8,32946],()=>da(()=>import("./deflate-BXt-9JA_-CoW5SAcn.js"),__vite__mapDeps([4,5,1])).then(s=>s.default));_a(32773,()=>da(()=>import("./packbits-BlDR4Kj5-myqVpMVP.js"),__vite__mapDeps([6,1])).then(s=>s.default));_a(34887,()=>da(()=>import("./lerc-B4lXefGh-C409q0WS.js"),__vite__mapDeps([7,5,1,8,9,10,11])).then(async s=>(await s.zstd.init(),s)).then(s=>s.default));_a(50001,()=>da(()=>import("./webimage-BM_pbLN3-BOB8pnha.js"),__vite__mapDeps([12,1])).then(s=>s.default));function f0(s,t,e,i=1){return new(Object.getPrototypeOf(s)).constructor(t*e*i)}function zQ(s,t,e,i,n){const r=t/i,o=e/n;return s.map(a=>{const l=f0(a,i,n);for(let h=0;h{const l=f0(a,i,n);for(let h=0;h>8-n-T&u;else if(T+n<=16)c[S]=a.getUint16(w)>>16-n-T&u;else if(T+n<=24){const M=a.getUint16(w)<<8|a.getUint8(w+2);c[S]=M>>24-n-T&u}else c[S]=a.getUint32(w)>>32-n-T&u}}}}return c.buffer}class rL{constructor(t,e,i,n,r,o){this.fileDirectory=t,this.geoKeys=e,this.dataView=i,this.littleEndian=n,this.tiles=r?{}:null,this.isTiled=!t.StripOffsets;const a=t.PlanarConfiguration;if(this.planarConfiguration=typeof a>"u"?1:a,this.planarConfiguration!==1&&this.planarConfiguration!==2)throw new Error("Invalid planar configuration.");this.source=o}getFileDirectory(){return this.fileDirectory}getGeoKeys(){return this.geoKeys}getWidth(){return this.fileDirectory.ImageWidth}getHeight(){return this.fileDirectory.ImageLength}getSamplesPerPixel(){return typeof this.fileDirectory.SamplesPerPixel<"u"?this.fileDirectory.SamplesPerPixel:1}getTileWidth(){return this.isTiled?this.fileDirectory.TileWidth:this.getWidth()}getTileHeight(){return this.isTiled?this.fileDirectory.TileLength:typeof this.fileDirectory.RowsPerStrip<"u"?Math.min(this.fileDirectory.RowsPerStrip,this.getHeight()):this.getHeight()}getBlockWidth(){return this.getTileWidth()}getBlockHeight(t){return this.isTiled||(t+1)*this.getTileHeight()<=this.getHeight()?this.getTileHeight():this.getHeight()-t*this.getTileHeight()}getBytesPerPixel(){let t=0;for(let e=0;e=this.fileDirectory.BitsPerSample.length)throw new RangeError(`Sample index ${t} is out of range.`);return Math.ceil(this.fileDirectory.BitsPerSample[t]/8)}getReaderForSample(t){const e=this.fileDirectory.SampleFormat?this.fileDirectory.SampleFormat[t]:1,i=this.fileDirectory.BitsPerSample[t];switch(e){case 1:if(i<=8)return DataView.prototype.getUint8;if(i<=16)return DataView.prototype.getUint16;if(i<=32)return DataView.prototype.getUint32;break;case 2:if(i<=8)return DataView.prototype.getInt8;if(i<=16)return DataView.prototype.getInt16;if(i<=32)return DataView.prototype.getInt32;break;case 3:switch(i){case 16:return function(n,r){return HA(this,n,r)};case 32:return DataView.prototype.getFloat32;case 64:return DataView.prototype.getFloat64}break}throw Error("Unsupported data format/bitsPerSample")}getSampleFormat(t=0){return this.fileDirectory.SampleFormat?this.fileDirectory.SampleFormat[t]:1}getBitsPerSample(t=0){return this.fileDirectory.BitsPerSample[t]}getArrayForSample(t,e){const i=this.getSampleFormat(t),n=this.getBitsPerSample(t);return gy(i,n,e)}async getTileOrStrip(t,e,i,n,r){const o=Math.ceil(this.getWidth()/this.getTileWidth()),a=Math.ceil(this.getHeight()/this.getTileHeight());let l;const{tiles:h}=this;this.planarConfiguration===1?l=e*o+t:this.planarConfiguration===2&&(l=i*o*a+e*o+t);let c,u;this.isTiled?(c=this.fileDirectory.TileOffsets[l],u=this.fileDirectory.TileByteCounts[l]):(c=this.fileDirectory.StripOffsets[l],u=this.fileDirectory.StripByteCounts[l]);const d=(await this.source.fetch([{offset:c,length:u}],r))[0];let g;return h===null||!h[l]?(g=(async()=>{let f=await n.decode(this.fileDirectory,d);const p=this.getSampleFormat(),m=this.getBitsPerSample();return qQ(p,m)&&(f=ZQ(f,p,this.planarConfiguration,this.getSamplesPerPixel(),m,this.getTileWidth(),this.getBlockHeight(e))),f})(),h!==null&&(h[l]=g)):g=h[l],{x:t,y:e,sample:i,data:await g}}async _readRaster(t,e,i,n,r,o,a,l,h){const c=this.getTileWidth(),u=this.getTileHeight(),d=this.getWidth(),g=this.getHeight(),f=Math.max(Math.floor(t[0]/c),0),p=Math.min(Math.ceil(t[2]/c),Math.ceil(d/c)),m=Math.max(Math.floor(t[1]/u),0),_=Math.min(Math.ceil(t[3]/u),Math.ceil(g/u)),y=t[2]-t[0];let v=this.getBytesPerPixel();const S=[],w=[];for(let C=0;C{const R=b.data,A=new DataView(R),$=this.getBlockHeight(b.y),G=b.y*u,k=b.x*c,z=G+$,V=(b.x+1)*c,et=w[D],F=Math.min($,$-(z-t[3]),g-G),ot=Math.min(c,c-(V-t[2]),d-k);for(let ht=Math.max(0,t[1]-G);htc[2]||c[1]>c[3])throw new Error("Invalid subsets");const u=c[2]-c[0],d=c[3]-c[1],g=u*d,f=this.getSamplesPerPixel();if(!e||!e.length)for(let _=0;_=f)return Promise.reject(new RangeError(`Invalid sample index '${e[_]}'.`));let p;if(i){const _=this.fileDirectory.SampleFormat?Math.max.apply(null,this.fileDirectory.SampleFormat):1,y=Math.max.apply(null,this.fileDirectory.BitsPerSample);p=gy(_,y,g*e.length),l&&p.fill(l)}else{p=[];for(let _=0;_h[2]||h[1]>h[3])throw new Error("Invalid subsets");const c=this.fileDirectory.PhotometricInterpretation;if(c===gi.RGB){let _=[0,1,2];if(this.fileDirectory.ExtraSamples!==PQ.Unspecified&&a){_=[];for(let y=0;yV_(r,"sample")===void 0):n=n.filter(r=>Number(V_(r,"sample"))===t);for(let r=0;r[a+n*p+r*m,u+l*p+h*m]),g=d.map(p=>p[0]),f=d.map(p=>p[1]);return[Math.min(...g),Math.min(...f),Math.max(...g),Math.max(...f)]}else{const n=this.getOrigin(),r=this.getResolution(),o=n[0],a=n[1],l=o+r[0]*i,h=a+r[1]*e;return[Math.min(o,l),Math.min(a,h),Math.max(o,l),Math.max(a,h)]}}}class HQ{constructor(t){this._dataView=new DataView(t)}get buffer(){return this._dataView.buffer}getUint64(t,e){const i=this.getUint32(t,e),n=this.getUint32(t+4,e);let r;if(e){if(r=i+2**32*n,!Number.isSafeInteger(r))throw new Error(`${r} exceeds MAX_SAFE_INTEGER. Precision may be lost. Please report if you get this message to https://github.com/geotiffjs/geotiff.js/issues`);return r}if(r=2**32*i+n,!Number.isSafeInteger(r))throw new Error(`${r} exceeds MAX_SAFE_INTEGER. Precision may be lost. Please report if you get this message to https://github.com/geotiffjs/geotiff.js/issues`);return r}getInt64(t,e){let i=0;const n=(this._dataView.getUint8(t+(e?7:0))&128)>0;let r=!0;for(let o=0;o<8;o++){let a=this._dataView.getUint8(t+(e?o:7-o));n&&(r?a!==0&&(a=~(a-1)&255,r=!1):a=~a&255),i+=a*256**o}return n&&(i=-i),i}getUint8(t,e){return this._dataView.getUint8(t,e)}getInt8(t,e){return this._dataView.getInt8(t,e)}getUint16(t,e){return this._dataView.getUint16(t,e)}getInt16(t,e){return this._dataView.getInt16(t,e)}getUint32(t,e){return this._dataView.getUint32(t,e)}getInt32(t,e){return this._dataView.getInt32(t,e)}getFloat16(t,e){return HA(this._dataView,t,e)}getFloat32(t,e){return this._dataView.getFloat32(t,e)}getFloat64(t,e){return this._dataView.getFloat64(t,e)}}class KQ{constructor(t,e,i,n){this._dataView=new DataView(t),this._sliceOffset=e,this._littleEndian=i,this._bigTiff=n}get sliceOffset(){return this._sliceOffset}get sliceTop(){return this._sliceOffset+this.buffer.byteLength}get littleEndian(){return this._littleEndian}get bigTiff(){return this._bigTiff}get buffer(){return this._dataView.buffer}covers(t,e){return this.sliceOffset<=t&&this.sliceTop>=t+e}readUint8(t){return this._dataView.getUint8(t-this._sliceOffset,this._littleEndian)}readInt8(t){return this._dataView.getInt8(t-this._sliceOffset,this._littleEndian)}readUint16(t){return this._dataView.getUint16(t-this._sliceOffset,this._littleEndian)}readInt16(t){return this._dataView.getInt16(t-this._sliceOffset,this._littleEndian)}readUint32(t){return this._dataView.getUint32(t-this._sliceOffset,this._littleEndian)}readInt32(t){return this._dataView.getInt32(t-this._sliceOffset,this._littleEndian)}readFloat32(t){return this._dataView.getFloat32(t-this._sliceOffset,this._littleEndian)}readFloat64(t){return this._dataView.getFloat64(t-this._sliceOffset,this._littleEndian)}readUint64(t){const e=this.readUint32(t),i=this.readUint32(t+4);let n;if(this._littleEndian){if(n=e+2**32*i,!Number.isSafeInteger(n))throw new Error(`${n} exceeds MAX_SAFE_INTEGER. Precision may be lost. Please report if you get this message to https://github.com/geotiffjs/geotiff.js/issues`);return n}if(n=2**32*e+i,!Number.isSafeInteger(n))throw new Error(`${n} exceeds MAX_SAFE_INTEGER. Precision may be lost. Please report if you get this message to https://github.com/geotiffjs/geotiff.js/issues`);return n}readInt64(t){let e=0;const i=(this._dataView.getUint8(t+(this._littleEndian?7:0))&128)>0;let n=!0;for(let r=0;r<8;r++){let o=this._dataView.getUint8(t+(this._littleEndian?r:7-r));i&&(n?o!==0&&(o=~(o-1)&255,n=!1):o=~o&255),e+=o*256**r}return i&&(e=-e),e}readOffset(t){return this._bigTiff?this.readUint64(t):this.readUint32(t)}}const JQ=typeof navigator<"u"&&navigator.hardwareConcurrency||2;class QQ{constructor(t=JQ,e){this.workers=null,this._awaitingDecoder=null,this.size=t,this.messageId=0,t&&(this._awaitingDecoder=e?Promise.resolve(e):new Promise(i=>{da(()=>import("./decoder-DJlmx386-CaSv2t6h.js"),[]).then(n=>{i(n.create)})}),this._awaitingDecoder.then(i=>{this._awaitingDecoder=null,this.workers=[];for(let n=0;ni.decode(t,e)):new Promise(i=>{const n=this.workers.find(a=>a.idle)||this.workers[Math.floor(Math.random()*this.size)];n.idle=!1;const r=this.messageId++,o=a=>{a.data.id===r&&(n.idle=!0,i(a.data.decoded),n.worker.removeEventListener("message",o))};n.worker.addEventListener("message",o),n.worker.postMessage({fileDirectory:t,buffer:e,id:r},[e])})}destroy(){this.workers&&(this.workers.forEach(t=>{t.worker.terminate()}),this.workers=null)}}const WM=`\r + >]`),p+=BM(m,""),p>=f)break;g=l}}else l=Y_(a,"[ /]"+t+">",0);const c=o+t.length+l+1;if(i&&console.log("[xml-utils] end:",c),c===-1)return;const u=s.slice(o,c);let d;return h?d=null:d=u.slice(u.indexOf(">")+1,u.lastIndexOf("<")),{inner:d,outer:u,start:o,end:c}}mw.exports=eL;mw.exports.default=eL;var bQ=mw.exports;const CQ=bQ;function sL(s,t,e){const i=[],n=e&&e.debug||!1,r=e&&typeof e.nested=="boolean"?e.nested:!0;let o=e&&e.startIndex||0,a;for(;a=CQ(s,t,{debug:n,startIndex:o});)r?o=a.start+1+t.length:o=a.end,i.push(a);return n&&console.log("findTagsByName found",i.length,"tags"),i}pw.exports=sL;pw.exports.default=sL;var TQ=pw.exports;const RQ=g0(TQ),Ku={315:"Artist",258:"BitsPerSample",265:"CellLength",264:"CellWidth",320:"ColorMap",259:"Compression",33432:"Copyright",306:"DateTime",338:"ExtraSamples",266:"FillOrder",289:"FreeByteCounts",288:"FreeOffsets",291:"GrayResponseCurve",290:"GrayResponseUnit",316:"HostComputer",270:"ImageDescription",257:"ImageLength",256:"ImageWidth",271:"Make",281:"MaxSampleValue",280:"MinSampleValue",272:"Model",254:"NewSubfileType",274:"Orientation",262:"PhotometricInterpretation",284:"PlanarConfiguration",296:"ResolutionUnit",278:"RowsPerStrip",277:"SamplesPerPixel",305:"Software",279:"StripByteCounts",273:"StripOffsets",255:"SubfileType",263:"Threshholding",282:"XResolution",283:"YResolution",326:"BadFaxLines",327:"CleanFaxData",343:"ClipPath",328:"ConsecutiveBadFaxLines",433:"Decode",434:"DefaultImageColor",269:"DocumentName",336:"DotRange",321:"HalftoneHints",346:"Indexed",347:"JPEGTables",285:"PageName",297:"PageNumber",317:"Predictor",319:"PrimaryChromaticities",532:"ReferenceBlackWhite",339:"SampleFormat",340:"SMinSampleValue",341:"SMaxSampleValue",559:"StripRowCounts",330:"SubIFDs",292:"T4Options",293:"T6Options",325:"TileByteCounts",323:"TileLength",324:"TileOffsets",322:"TileWidth",301:"TransferFunction",318:"WhitePoint",344:"XClipPathUnits",286:"XPosition",529:"YCbCrCoefficients",531:"YCbCrPositioning",530:"YCbCrSubSampling",345:"YClipPathUnits",287:"YPosition",37378:"ApertureValue",40961:"ColorSpace",36868:"DateTimeDigitized",36867:"DateTimeOriginal",34665:"Exif IFD",36864:"ExifVersion",33434:"ExposureTime",41728:"FileSource",37385:"Flash",40960:"FlashpixVersion",33437:"FNumber",42016:"ImageUniqueID",37384:"LightSource",37500:"MakerNote",37377:"ShutterSpeedValue",37510:"UserComment",33723:"IPTC",34675:"ICC Profile",700:"XMP",42112:"GDAL_METADATA",42113:"GDAL_NODATA",34377:"Photoshop",33550:"ModelPixelScale",33922:"ModelTiepoint",34264:"ModelTransformation",34735:"GeoKeyDirectory",34736:"GeoDoubleParams",34737:"GeoAsciiParams",50674:"LercParameters"},er={};for(const s in Ku)Ku.hasOwnProperty(s)&&(er[Ku[s]]=parseInt(s,10));const IQ=[er.BitsPerSample,er.ExtraSamples,er.SampleFormat,er.StripByteCounts,er.StripOffsets,er.StripRowCounts,er.TileByteCounts,er.TileOffsets,er.SubIFDs],q_={1:"BYTE",2:"ASCII",3:"SHORT",4:"LONG",5:"RATIONAL",6:"SBYTE",7:"UNDEFINED",8:"SSHORT",9:"SLONG",10:"SRATIONAL",11:"FLOAT",12:"DOUBLE",13:"IFD",16:"LONG8",17:"SLONG8",18:"IFD8"},Ut={};for(const s in q_)q_.hasOwnProperty(s)&&(Ut[q_[s]]=parseInt(s,10));const gi={WhiteIsZero:0,BlackIsZero:1,RGB:2,Palette:3,TransparencyMask:4,CMYK:5,YCbCr:6,CIELab:8,ICCLab:9},PQ={Unspecified:0,Assocalpha:1,Unassalpha:2},Cct={Version:0,AddCompression:1},Tct={None:0,Deflate:1,Zstandard:2},AQ={1024:"GTModelTypeGeoKey",1025:"GTRasterTypeGeoKey",1026:"GTCitationGeoKey",2048:"GeographicTypeGeoKey",2049:"GeogCitationGeoKey",2050:"GeogGeodeticDatumGeoKey",2051:"GeogPrimeMeridianGeoKey",2052:"GeogLinearUnitsGeoKey",2053:"GeogLinearUnitSizeGeoKey",2054:"GeogAngularUnitsGeoKey",2055:"GeogAngularUnitSizeGeoKey",2056:"GeogEllipsoidGeoKey",2057:"GeogSemiMajorAxisGeoKey",2058:"GeogSemiMinorAxisGeoKey",2059:"GeogInvFlatteningGeoKey",2060:"GeogAzimuthUnitsGeoKey",2061:"GeogPrimeMeridianLongGeoKey",2062:"GeogTOWGS84GeoKey",3072:"ProjectedCSTypeGeoKey",3073:"PCSCitationGeoKey",3074:"ProjectionGeoKey",3075:"ProjCoordTransGeoKey",3076:"ProjLinearUnitsGeoKey",3077:"ProjLinearUnitSizeGeoKey",3078:"ProjStdParallel1GeoKey",3079:"ProjStdParallel2GeoKey",3080:"ProjNatOriginLongGeoKey",3081:"ProjNatOriginLatGeoKey",3082:"ProjFalseEastingGeoKey",3083:"ProjFalseNorthingGeoKey",3084:"ProjFalseOriginLongGeoKey",3085:"ProjFalseOriginLatGeoKey",3086:"ProjFalseOriginEastingGeoKey",3087:"ProjFalseOriginNorthingGeoKey",3088:"ProjCenterLongGeoKey",3089:"ProjCenterLatGeoKey",3090:"ProjCenterEastingGeoKey",3091:"ProjCenterNorthingGeoKey",3092:"ProjScaleAtNatOriginGeoKey",3093:"ProjScaleAtCenterGeoKey",3094:"ProjAzimuthAngleGeoKey",3095:"ProjStraightVertPoleLongGeoKey",3096:"ProjRectifiedGridAngleGeoKey",4096:"VerticalCSTypeGeoKey",4097:"VerticalCitationGeoKey",4098:"VerticalDatumGeoKey",4099:"VerticalUnitsGeoKey"};function LQ(s,t){const{width:e,height:i}=s,n=new Uint8Array(e*i*3);let r;for(let o=0,a=0;o>24,l=s[n+2]<<24>>24;let h=(o+16)/116,c=a/500+h,u=h-l/200,d,g,f;c=kQ*(c*c*c>.008856?c*c*c:(c-16/116)/7.787),h=$Q*(h*h*h>.008856?h*h*h:(h-16/116)/7.787),u=GQ*(u*u*u>.008856?u*u*u:(u-16/116)/7.787),d=c*3.2406+h*-1.5372+u*-.4986,g=c*-.9689+h*1.8758+u*.0415,f=c*.0557+h*-.204+u*1.057,d=d>.0031308?1.055*d**(1/2.4)-.055:12.92*d,g=g>.0031308?1.055*g**(1/2.4)-.055:12.92*g,f=f>.0031308?1.055*f**(1/2.4)-.055:12.92*f,i[r]=Math.max(0,Math.min(1,d))*255,i[r+1]=Math.max(0,Math.min(1,g))*255,i[r+2]=Math.max(0,Math.min(1,f))*255}return i}const iL=new Map;function _a(s,t){Array.isArray(s)||(s=[s]),s.forEach(e=>iL.set(e,t))}async function nL(s){const t=iL.get(s.Compression);if(!t)throw new Error(`Unknown compression method identifier: ${s.Compression}`);const e=await t();return new e(s)}_a([void 0,1],()=>da(()=>import("./raw-CMGvRjfu-Blplg0lv.js"),__vite__mapDeps([0,1])).then(s=>s.default));_a(5,()=>da(()=>import("./lzw-LAGDNbSC-uvu3SnH0.js"),__vite__mapDeps([2,1])).then(s=>s.default));_a(6,()=>{throw new Error("old style JPEG compression is not supported.")});_a(7,()=>da(()=>import("./jpeg-BAgeD1d3-DG6CHa_P.js"),__vite__mapDeps([3,1])).then(s=>s.default));_a([8,32946],()=>da(()=>import("./deflate-BXt-9JA_-CoW5SAcn.js"),__vite__mapDeps([4,5,1])).then(s=>s.default));_a(32773,()=>da(()=>import("./packbits-BlDR4Kj5-myqVpMVP.js"),__vite__mapDeps([6,1])).then(s=>s.default));_a(34887,()=>da(()=>import("./lerc-B4lXefGh-AVOSkc8n.js"),__vite__mapDeps([7,5,1,8,9,10,11])).then(async s=>(await s.zstd.init(),s)).then(s=>s.default));_a(50001,()=>da(()=>import("./webimage-BM_pbLN3-BOB8pnha.js"),__vite__mapDeps([12,1])).then(s=>s.default));function f0(s,t,e,i=1){return new(Object.getPrototypeOf(s)).constructor(t*e*i)}function zQ(s,t,e,i,n){const r=t/i,o=e/n;return s.map(a=>{const l=f0(a,i,n);for(let h=0;h{const l=f0(a,i,n);for(let h=0;h>8-n-C&u;else if(C+n<=16)c[S]=a.getUint16(w)>>16-n-C&u;else if(C+n<=24){const M=a.getUint16(w)<<8|a.getUint8(w+2);c[S]=M>>24-n-C&u}else c[S]=a.getUint32(w)>>32-n-C&u}}}}return c.buffer}class rL{constructor(t,e,i,n,r,o){this.fileDirectory=t,this.geoKeys=e,this.dataView=i,this.littleEndian=n,this.tiles=r?{}:null,this.isTiled=!t.StripOffsets;const a=t.PlanarConfiguration;if(this.planarConfiguration=typeof a>"u"?1:a,this.planarConfiguration!==1&&this.planarConfiguration!==2)throw new Error("Invalid planar configuration.");this.source=o}getFileDirectory(){return this.fileDirectory}getGeoKeys(){return this.geoKeys}getWidth(){return this.fileDirectory.ImageWidth}getHeight(){return this.fileDirectory.ImageLength}getSamplesPerPixel(){return typeof this.fileDirectory.SamplesPerPixel<"u"?this.fileDirectory.SamplesPerPixel:1}getTileWidth(){return this.isTiled?this.fileDirectory.TileWidth:this.getWidth()}getTileHeight(){return this.isTiled?this.fileDirectory.TileLength:typeof this.fileDirectory.RowsPerStrip<"u"?Math.min(this.fileDirectory.RowsPerStrip,this.getHeight()):this.getHeight()}getBlockWidth(){return this.getTileWidth()}getBlockHeight(t){return this.isTiled||(t+1)*this.getTileHeight()<=this.getHeight()?this.getTileHeight():this.getHeight()-t*this.getTileHeight()}getBytesPerPixel(){let t=0;for(let e=0;e=this.fileDirectory.BitsPerSample.length)throw new RangeError(`Sample index ${t} is out of range.`);return Math.ceil(this.fileDirectory.BitsPerSample[t]/8)}getReaderForSample(t){const e=this.fileDirectory.SampleFormat?this.fileDirectory.SampleFormat[t]:1,i=this.fileDirectory.BitsPerSample[t];switch(e){case 1:if(i<=8)return DataView.prototype.getUint8;if(i<=16)return DataView.prototype.getUint16;if(i<=32)return DataView.prototype.getUint32;break;case 2:if(i<=8)return DataView.prototype.getInt8;if(i<=16)return DataView.prototype.getInt16;if(i<=32)return DataView.prototype.getInt32;break;case 3:switch(i){case 16:return function(n,r){return HA(this,n,r)};case 32:return DataView.prototype.getFloat32;case 64:return DataView.prototype.getFloat64}break}throw Error("Unsupported data format/bitsPerSample")}getSampleFormat(t=0){return this.fileDirectory.SampleFormat?this.fileDirectory.SampleFormat[t]:1}getBitsPerSample(t=0){return this.fileDirectory.BitsPerSample[t]}getArrayForSample(t,e){const i=this.getSampleFormat(t),n=this.getBitsPerSample(t);return gy(i,n,e)}async getTileOrStrip(t,e,i,n,r){const o=Math.ceil(this.getWidth()/this.getTileWidth()),a=Math.ceil(this.getHeight()/this.getTileHeight());let l;const{tiles:h}=this;this.planarConfiguration===1?l=e*o+t:this.planarConfiguration===2&&(l=i*o*a+e*o+t);let c,u;this.isTiled?(c=this.fileDirectory.TileOffsets[l],u=this.fileDirectory.TileByteCounts[l]):(c=this.fileDirectory.StripOffsets[l],u=this.fileDirectory.StripByteCounts[l]);const d=(await this.source.fetch([{offset:c,length:u}],r))[0];let g;return h===null||!h[l]?(g=(async()=>{let f=await n.decode(this.fileDirectory,d);const p=this.getSampleFormat(),m=this.getBitsPerSample();return qQ(p,m)&&(f=ZQ(f,p,this.planarConfiguration,this.getSamplesPerPixel(),m,this.getTileWidth(),this.getBlockHeight(e))),f})(),h!==null&&(h[l]=g)):g=h[l],{x:t,y:e,sample:i,data:await g}}async _readRaster(t,e,i,n,r,o,a,l,h){const c=this.getTileWidth(),u=this.getTileHeight(),d=this.getWidth(),g=this.getHeight(),f=Math.max(Math.floor(t[0]/c),0),p=Math.min(Math.ceil(t[2]/c),Math.ceil(d/c)),m=Math.max(Math.floor(t[1]/u),0),_=Math.min(Math.ceil(t[3]/u),Math.ceil(g/u)),y=t[2]-t[0];let v=this.getBytesPerPixel();const S=[],w=[];for(let T=0;T{const R=b.data,A=new DataView(R),$=this.getBlockHeight(b.y),G=b.y*u,k=b.x*c,z=G+$,V=(b.x+1)*c,et=w[D],F=Math.min($,$-(z-t[3]),g-G),ot=Math.min(c,c-(V-t[2]),d-k);for(let ht=Math.max(0,t[1]-G);htc[2]||c[1]>c[3])throw new Error("Invalid subsets");const u=c[2]-c[0],d=c[3]-c[1],g=u*d,f=this.getSamplesPerPixel();if(!e||!e.length)for(let _=0;_=f)return Promise.reject(new RangeError(`Invalid sample index '${e[_]}'.`));let p;if(i){const _=this.fileDirectory.SampleFormat?Math.max.apply(null,this.fileDirectory.SampleFormat):1,y=Math.max.apply(null,this.fileDirectory.BitsPerSample);p=gy(_,y,g*e.length),l&&p.fill(l)}else{p=[];for(let _=0;_h[2]||h[1]>h[3])throw new Error("Invalid subsets");const c=this.fileDirectory.PhotometricInterpretation;if(c===gi.RGB){let _=[0,1,2];if(this.fileDirectory.ExtraSamples!==PQ.Unspecified&&a){_=[];for(let y=0;yV_(r,"sample")===void 0):n=n.filter(r=>Number(V_(r,"sample"))===t);for(let r=0;r[a+n*p+r*m,u+l*p+h*m]),g=d.map(p=>p[0]),f=d.map(p=>p[1]);return[Math.min(...g),Math.min(...f),Math.max(...g),Math.max(...f)]}else{const n=this.getOrigin(),r=this.getResolution(),o=n[0],a=n[1],l=o+r[0]*i,h=a+r[1]*e;return[Math.min(o,l),Math.min(a,h),Math.max(o,l),Math.max(a,h)]}}}class HQ{constructor(t){this._dataView=new DataView(t)}get buffer(){return this._dataView.buffer}getUint64(t,e){const i=this.getUint32(t,e),n=this.getUint32(t+4,e);let r;if(e){if(r=i+2**32*n,!Number.isSafeInteger(r))throw new Error(`${r} exceeds MAX_SAFE_INTEGER. Precision may be lost. Please report if you get this message to https://github.com/geotiffjs/geotiff.js/issues`);return r}if(r=2**32*i+n,!Number.isSafeInteger(r))throw new Error(`${r} exceeds MAX_SAFE_INTEGER. Precision may be lost. Please report if you get this message to https://github.com/geotiffjs/geotiff.js/issues`);return r}getInt64(t,e){let i=0;const n=(this._dataView.getUint8(t+(e?7:0))&128)>0;let r=!0;for(let o=0;o<8;o++){let a=this._dataView.getUint8(t+(e?o:7-o));n&&(r?a!==0&&(a=~(a-1)&255,r=!1):a=~a&255),i+=a*256**o}return n&&(i=-i),i}getUint8(t,e){return this._dataView.getUint8(t,e)}getInt8(t,e){return this._dataView.getInt8(t,e)}getUint16(t,e){return this._dataView.getUint16(t,e)}getInt16(t,e){return this._dataView.getInt16(t,e)}getUint32(t,e){return this._dataView.getUint32(t,e)}getInt32(t,e){return this._dataView.getInt32(t,e)}getFloat16(t,e){return HA(this._dataView,t,e)}getFloat32(t,e){return this._dataView.getFloat32(t,e)}getFloat64(t,e){return this._dataView.getFloat64(t,e)}}class KQ{constructor(t,e,i,n){this._dataView=new DataView(t),this._sliceOffset=e,this._littleEndian=i,this._bigTiff=n}get sliceOffset(){return this._sliceOffset}get sliceTop(){return this._sliceOffset+this.buffer.byteLength}get littleEndian(){return this._littleEndian}get bigTiff(){return this._bigTiff}get buffer(){return this._dataView.buffer}covers(t,e){return this.sliceOffset<=t&&this.sliceTop>=t+e}readUint8(t){return this._dataView.getUint8(t-this._sliceOffset,this._littleEndian)}readInt8(t){return this._dataView.getInt8(t-this._sliceOffset,this._littleEndian)}readUint16(t){return this._dataView.getUint16(t-this._sliceOffset,this._littleEndian)}readInt16(t){return this._dataView.getInt16(t-this._sliceOffset,this._littleEndian)}readUint32(t){return this._dataView.getUint32(t-this._sliceOffset,this._littleEndian)}readInt32(t){return this._dataView.getInt32(t-this._sliceOffset,this._littleEndian)}readFloat32(t){return this._dataView.getFloat32(t-this._sliceOffset,this._littleEndian)}readFloat64(t){return this._dataView.getFloat64(t-this._sliceOffset,this._littleEndian)}readUint64(t){const e=this.readUint32(t),i=this.readUint32(t+4);let n;if(this._littleEndian){if(n=e+2**32*i,!Number.isSafeInteger(n))throw new Error(`${n} exceeds MAX_SAFE_INTEGER. Precision may be lost. Please report if you get this message to https://github.com/geotiffjs/geotiff.js/issues`);return n}if(n=2**32*e+i,!Number.isSafeInteger(n))throw new Error(`${n} exceeds MAX_SAFE_INTEGER. Precision may be lost. Please report if you get this message to https://github.com/geotiffjs/geotiff.js/issues`);return n}readInt64(t){let e=0;const i=(this._dataView.getUint8(t+(this._littleEndian?7:0))&128)>0;let n=!0;for(let r=0;r<8;r++){let o=this._dataView.getUint8(t+(this._littleEndian?r:7-r));i&&(n?o!==0&&(o=~(o-1)&255,n=!1):o=~o&255),e+=o*256**r}return i&&(e=-e),e}readOffset(t){return this._bigTiff?this.readUint64(t):this.readUint32(t)}}const JQ=typeof navigator<"u"&&navigator.hardwareConcurrency||2;class QQ{constructor(t=JQ,e){this.workers=null,this._awaitingDecoder=null,this.size=t,this.messageId=0,t&&(this._awaitingDecoder=e?Promise.resolve(e):new Promise(i=>{da(()=>import("./decoder-DJlmx386-CaSv2t6h.js"),[]).then(n=>{i(n.create)})}),this._awaitingDecoder.then(i=>{this._awaitingDecoder=null,this.workers=[];for(let n=0;ni.decode(t,e)):new Promise(i=>{const n=this.workers.find(a=>a.idle)||this.workers[Math.floor(Math.random()*this.size)];n.idle=!1;const r=this.messageId++,o=a=>{a.data.id===r&&(n.idle=!0,i(a.data.decoded),n.worker.removeEventListener("message",o))};n.worker.addEventListener("message",o),n.worker.postMessage({fileDirectory:t,buffer:e,id:r},[e])})}destroy(){this.workers&&(this.workers.forEach(t=>{t.worker.terminate()}),this.workers=null)}}const WM=`\r \r `;function oL(s){if(typeof Object.fromEntries<"u")return Object.fromEntries(s);const t={};for(const[e,i]of s)t[e.toLowerCase()]=i;return t}function ttt(s){const t=s.split(`\r -`).map(e=>{const i=e.split(":").map(n=>n.trim());return i[0]=i[0].toLowerCase(),i});return oL(t)}function ett(s){const[t,...e]=s.split(";").map(n=>n.trim()),i=e.map(n=>n.split("="));return{type:t,params:oL(i)}}function fy(s){let t,e,i;return s&&([,t,e,i]=s.match(/bytes (\d+)-(\d+)\/(\d+)/),t=parseInt(t,10),e=parseInt(e,10),i=parseInt(i,10)),{start:t,end:e,total:i}}function stt(s,t){let e=null;const i=new TextDecoder("ascii"),n=[],r=`--${t}`,o=`${r}--`;for(let a=0;a<10;++a)i.decode(new Uint8Array(s,a,r.length))===r&&(e=a);if(e===null)throw new Error("Could not find initial boundary");for(;ethis.fetchSlice(i,e)))}async fetchSlice(t){throw new Error(`fetching of slice ${t} not possible, not implemented`)}get fileSize(){return null}async close(){}}class itt extends Map{constructor(t={}){if(super(),!(t.maxSize&&t.maxSize>0))throw new TypeError("`maxSize` must be a number greater than 0");if(typeof t.maxAge=="number"&&t.maxAge===0)throw new TypeError("`maxAge` must be a number greater than 0");this.maxSize=t.maxSize,this.maxAge=t.maxAge||Number.POSITIVE_INFINITY,this.onEviction=t.onEviction,this.cache=new Map,this.oldCache=new Map,this._size=0}_emitEvictions(t){if(typeof this.onEviction=="function")for(const[e,i]of t)this.onEviction(e,i.value)}_deleteIfExpired(t,e){return typeof e.expiry=="number"&&e.expiry<=Date.now()?(typeof this.onEviction=="function"&&this.onEviction(t,e.value),this.delete(t)):!1}_getOrDeleteIfExpired(t,e){if(this._deleteIfExpired(t,e)===!1)return e.value}_getItemValue(t,e){return e.expiry?this._getOrDeleteIfExpired(t,e):e.value}_peek(t,e){const i=e.get(t);return this._getItemValue(t,i)}_set(t,e){this.cache.set(t,e),this._size++,this._size>=this.maxSize&&(this._size=0,this._emitEvictions(this.oldCache),this.oldCache=this.cache,this.cache=new Map)}_moveToRecent(t,e){this.oldCache.delete(t),this._set(t,e)}*_entriesAscending(){for(const t of this.oldCache){const[e,i]=t;this.cache.has(e)||this._deleteIfExpired(e,i)===!1&&(yield t)}for(const t of this.cache){const[e,i]=t;this._deleteIfExpired(e,i)===!1&&(yield t)}}get(t){if(this.cache.has(t)){const e=this.cache.get(t);return this._getItemValue(t,e)}if(this.oldCache.has(t)){const e=this.oldCache.get(t);if(this._deleteIfExpired(t,e)===!1)return this._moveToRecent(t,e),e.value}}set(t,e,{maxAge:i=this.maxAge}={}){const n=typeof i=="number"&&i!==Number.POSITIVE_INFINITY?Date.now()+i:void 0;return this.cache.has(t)?this.cache.set(t,{value:e,expiry:n}):this._set(t,{value:e,expiry:n}),this}has(t){return this.cache.has(t)?!this._deleteIfExpired(t,this.cache.get(t)):this.oldCache.has(t)?!this._deleteIfExpired(t,this.oldCache.get(t)):!1}peek(t){if(this.cache.has(t))return this._peek(t,this.cache);if(this.oldCache.has(t))return this._peek(t,this.oldCache)}delete(t){const e=this.cache.delete(t);return e&&this._size--,this.oldCache.delete(t)||e}clear(){this.cache.clear(),this.oldCache.clear(),this._size=0}resize(t){if(!(t&&t>0))throw new TypeError("`maxSize` must be a number greater than 0");const e=[...this._entriesAscending()],i=e.length-t;i<0?(this.cache=new Map(e),this.oldCache=new Map,this._size=e.length):(i>0&&this._emitEvictions(e.slice(0,i)),this.oldCache=new Map(e.slice(i)),this.cache=new Map,this._size=0),this.maxSize=t}*keys(){for(const[t]of this)yield t}*values(){for(const[,t]of this)yield t}*[Symbol.iterator](){for(const t of this.cache){const[e,i]=t;this._deleteIfExpired(e,i)===!1&&(yield[e,i.value])}for(const t of this.oldCache){const[e,i]=t;this.cache.has(e)||this._deleteIfExpired(e,i)===!1&&(yield[e,i.value])}}*entriesDescending(){let t=[...this.cache];for(let e=t.length-1;e>=0;--e){const i=t[e],[n,r]=i;this._deleteIfExpired(n,r)===!1&&(yield[n,r.value])}t=[...this.oldCache];for(let e=t.length-1;e>=0;--e){const i=t[e],[n,r]=i;this.cache.has(n)||this._deleteIfExpired(n,r)===!1&&(yield[n,r.value])}}*entriesAscending(){for(const[t,e]of this._entriesAscending())yield[t,e.value]}get size(){if(!this._size)return this.oldCache.size;let t=0;for(const e of this.oldCache.keys())this.cache.has(e)||t++;return Math.min(this._size+t,this.maxSize)}entries(){return this.entriesAscending()}forEach(t,e=this){for(const[i,n]of this.entriesAscending())t.call(e,n,i,this)}get[Symbol.toStringTag](){return JSON.stringify([...this.entriesAscending()])}}async function ntt(s){return new Promise(t=>setTimeout(t,s))}function rtt(s,t){const e=Array.isArray(s)?s:Array.from(s),i=Array.isArray(t)?t:Array.from(t);return e.map((n,r)=>[n,i[r]])}class dc extends Error{constructor(t){super(t),Error.captureStackTrace&&Error.captureStackTrace(this,dc),this.name="AbortError"}}class ott extends Error{constructor(t,e){super(e),this.errors=t,this.message=e,this.name="AggregateError"}}const att=ott;class ltt{constructor(t,e,i=null){this.offset=t,this.length=e,this.data=i}get top(){return this.offset+this.length}}class XM{constructor(t,e,i){this.offset=t,this.length=e,this.blockIds=i}}class htt extends vw{constructor(t,{blockSize:e=65536,cacheSize:i=100}={}){super(),this.source=t,this.blockSize=e,this.blockCache=new itt({maxSize:i,onEviction:(n,r)=>{this.evictedBlocks.set(n,r)}}),this.evictedBlocks=new Map,this.blockRequests=new Map,this.blockIdsToFetch=new Set,this.abortedBlockIds=new Set}get fileSize(){return this.source.fileSize}async fetch(t,e){const i=[],n=[],r=[];this.evictedBlocks.clear();for(const{offset:d,length:g}of t){let f=d+g;const{fileSize:p}=this;p!==null&&(f=Math.min(f,p));const m=Math.floor(d/this.blockSize)*this.blockSize;for(let _=m;_this.abortedBlockIds.has(d)||!this.blockCache.has(d));if(l.forEach(d=>this.blockIdsToFetch.add(d)),l.length>0&&e&&!e.aborted){this.fetchBlocks(null);for(const d of l){const g=this.blockRequests.get(d);if(!g)throw new Error(`Block ${d} is not in the block requests`);a.push(g)}await Promise.allSettled(a)}if(e&&e.aborted)throw new dc("Request was aborted");const h=r.map(d=>this.blockCache.get(d)||this.evictedBlocks.get(d)),c=h.filter(d=>!d);if(c.length)throw new att(c,"Request failed");const u=new Map(rtt(r,h));return this.readSliceData(t,u)}fetchBlocks(t){if(this.blockIdsToFetch.size>0){const e=this.groupBlocks(this.blockIdsToFetch),i=this.source.fetch(e,t);for(let n=0;n{try{const a=(await i)[n],l=o*this.blockSize,h=l-a.offset,c=Math.min(h+this.blockSize,a.data.byteLength),u=a.data.slice(h,c),d=new ltt(l,u.byteLength,u,o);this.blockCache.set(o,d),this.abortedBlockIds.delete(o)}catch(a){if(a.name==="AbortError")a.signal=t,this.blockCache.delete(o),this.abortedBlockIds.add(o);else throw a}finally{this.blockRequests.delete(o)}})())}this.blockIdsToFetch.clear()}}groupBlocks(t){const e=Array.from(t).sort((o,a)=>o-a);if(e.length===0)return[];let i=[],n=null;const r=[];for(const o of e)n===null||n+1===o?(i.push(o),n=o):(r.push(new XM(i[0]*this.blockSize,i.length*this.blockSize,i)),i=[o],n=o);return r.push(new XM(i[0]*this.blockSize,i.length*this.blockSize,i)),r}readSliceData(t,e){return t.map(i=>{let n=i.offset+i.length;this.fileSize!==null&&(n=Math.min(this.fileSize,n));const r=Math.floor(i.offset/this.blockSize),o=Math.floor(n/this.blockSize),a=new ArrayBuffer(i.length),l=new Uint8Array(a);for(let h=r;h<=o;++h){const c=e.get(h),u=c.offset-i.offset,d=c.top-n;let g=0,f=0,p;u<0?g=-u:u>0&&(f=u),d<0?p=c.length-g:p=n-c.offset-g;const m=new Uint8Array(c.data,g,p);l.set(m,f)}return a})}}class ww{get ok(){return this.status>=200&&this.status<=299}get status(){throw new Error("not implemented")}getHeader(t){throw new Error("not implemented")}async getData(){throw new Error("not implemented")}}class Ew{constructor(t){this.url=t}async request({headers:t,signal:e}={}){throw new Error("request is not implemented")}}class ctt extends ww{constructor(t){super(),this.response=t}get status(){return this.response.status}getHeader(t){return this.response.headers.get(t)}async getData(){return this.response.arrayBuffer?await this.response.arrayBuffer():(await this.response.buffer()).buffer}}class utt extends Ew{constructor(t,e){super(t),this.credentials=e}async request({headers:t,signal:e}={}){const i=await fetch(this.url,{headers:t,credentials:this.credentials,signal:e});return new ctt(i)}}class dtt extends ww{constructor(t,e){super(),this.xhr=t,this.data=e}get status(){return this.xhr.status}getHeader(t){return this.xhr.getResponseHeader(t)}async getData(){return this.data}}class gtt extends Ew{constructRequest(t,e){return new Promise((i,n)=>{const r=new XMLHttpRequest;r.open("GET",this.url),r.responseType="arraybuffer";for(const[o,a]of Object.entries(t))r.setRequestHeader(o,a);r.onload=()=>{const o=r.response;i(new dtt(r,o))},r.onerror=n,r.onabort=()=>n(new dc("Request aborted")),r.send(),e&&(e.aborted&&r.abort(),e.addEventListener("abort",()=>r.abort()))})}async request({headers:t,signal:e}={}){return await this.constructRequest(t,e)}}const VM={};class ftt extends ww{constructor(t,e){super(),this.response=t,this.dataPromise=e}get status(){return this.response.statusCode}getHeader(t){return this.response.headers[t]}async getData(){return await this.dataPromise}}class ptt extends Ew{constructor(t){super(t),this.parsedUrl=VM.parse(this.url),this.httpApi=(this.parsedUrl.protocol,VM)}constructRequest(t,e){return new Promise((i,n)=>{const r=this.httpApi.get({...this.parsedUrl,headers:t},o=>{const a=new Promise(l=>{const h=[];o.on("data",c=>{h.push(c)}),o.on("end",()=>{const c=Buffer.concat(h).buffer;l(c)}),o.on("error",n)});i(new ftt(o,a))});r.on("error",n),e&&(e.aborted&&r.destroy(new dc("Request aborted")),e.addEventListener("abort",()=>r.destroy(new dc("Request aborted"))))})}async request({headers:t,signal:e}={}){return await this.constructRequest(t,e)}}class Sw extends vw{constructor(t,e,i,n){super(),this.client=t,this.headers=e,this.maxRanges=i,this.allowFullFile=n,this._fileSize=null}async fetch(t,e){return this.maxRanges>=t.length?this.fetchSlices(t,e):(this.maxRanges>0&&t.length>1,Promise.all(t.map(i=>this.fetchSlice(i,e))))}async fetchSlices(t,e){const i=await this.client.request({headers:{...this.headers,Range:`bytes=${t.map(({offset:n,length:r})=>`${n}-${n+r}`).join(",")}`},signal:e});if(i.ok)if(i.status===206){const{type:n,params:r}=ett(i.getHeader("content-type"));if(n==="multipart/byteranges"){const u=stt(await i.getData(),r.boundary);return this._fileSize=u[0].fileSize||null,u}const o=await i.getData(),{start:a,end:l,total:h}=fy(i.getHeader("content-range"));this._fileSize=h||null;const c=[{data:o,offset:a,length:l-a}];if(t.length>1){const u=await Promise.all(t.slice(1).map(d=>this.fetchSlice(d,e)));return c.concat(u)}return c}else{if(!this.allowFullFile)throw new Error("Server responded with full file");const n=await i.getData();return this._fileSize=n.byteLength,[{data:n,offset:0,length:n.byteLength}]}else throw new Error("Error fetching data.")}async fetchSlice(t,e){const{offset:i,length:n}=t,r=await this.client.request({headers:{...this.headers,Range:`bytes=${i}-${i+n}`},signal:e});if(r.ok)if(r.status===206){const o=await r.getData(),{total:a}=fy(r.getHeader("content-range"));return this._fileSize=a||null,{data:o,offset:i,length:n}}else{if(!this.allowFullFile)throw new Error("Server responded with full file");const o=await r.getData();return this._fileSize=o.byteLength,{data:o,offset:0,length:o.byteLength}}else throw new Error("Error fetching data.")}get fileSize(){return this._fileSize}}function Mw(s,{blockSize:t,cacheSize:e}){return t===null?s:new htt(s,{blockSize:t,cacheSize:e})}function mtt(s,{headers:t={},credentials:e,maxRanges:i=0,allowFullFile:n=!1,...r}={}){const o=new utt(s,e),a=new Sw(o,t,i,n);return Mw(a,r)}function _tt(s,{headers:t={},maxRanges:e=0,allowFullFile:i=!1,...n}={}){const r=new gtt(s),o=new Sw(r,t,e,i);return Mw(o,n)}function ytt(s,{headers:t={},maxRanges:e=0,allowFullFile:i=!1,...n}={}){const r=new ptt(s),o=new Sw(r,t,e,i);return Mw(o,n)}function py(s,{forceXHR:t=!1,...e}={}){return typeof fetch=="function"&&!t?mtt(s,e):typeof XMLHttpRequest<"u"?_tt(s,e):ytt(s,e)}class xtt extends vw{constructor(t){super(),this.file=t}async fetchSlice(t,e){return new Promise((i,n)=>{const r=this.file.slice(t.offset,t.offset+t.length),o=new FileReader;o.onload=a=>i(a.target.result),o.onerror=n,o.onabort=n,o.readAsArrayBuffer(r),e&&e.addEventListener("abort",()=>o.abort())})}}function vtt(s){return new xtt(s)}function my(s){switch(s){case Ut.BYTE:case Ut.ASCII:case Ut.SBYTE:case Ut.UNDEFINED:return 1;case Ut.SHORT:case Ut.SSHORT:return 2;case Ut.LONG:case Ut.SLONG:case Ut.FLOAT:case Ut.IFD:return 4;case Ut.RATIONAL:case Ut.SRATIONAL:case Ut.DOUBLE:case Ut.LONG8:case Ut.SLONG8:case Ut.IFD8:return 8;default:throw new RangeError(`Invalid field type: ${s}`)}}function wtt(s){const t=s.GeoKeyDirectory;if(!t)return null;const e={};for(let i=4;i<=t[3]*4;i+=4){const n=AQ[t[i]],r=t[i+1]?Ku[t[i+1]]:null,o=t[i+2],a=t[i+3];let l=null;if(!r)l=a;else{if(l=s[r],typeof l>"u"||l===null)throw new Error(`Could not get value of geoKey '${n}'.`);typeof l=="string"?l=l.substring(a,a+o-1):l.subarray&&(l=l.subarray(a,a+o),o===1&&(l=l[0]))}e[n]=l}return e}function Bl(s,t,e,i){let n=null,r=null;const o=my(t);switch(t){case Ut.BYTE:case Ut.ASCII:case Ut.UNDEFINED:n=new Uint8Array(e),r=s.readUint8;break;case Ut.SBYTE:n=new Int8Array(e),r=s.readInt8;break;case Ut.SHORT:n=new Uint16Array(e),r=s.readUint16;break;case Ut.SSHORT:n=new Int16Array(e),r=s.readInt16;break;case Ut.LONG:case Ut.IFD:n=new Uint32Array(e),r=s.readUint32;break;case Ut.SLONG:n=new Int32Array(e),r=s.readInt32;break;case Ut.LONG8:case Ut.IFD8:n=new Array(e),r=s.readUint64;break;case Ut.SLONG8:n=new Array(e),r=s.readInt64;break;case Ut.RATIONAL:n=new Uint32Array(e*2),r=s.readUint32;break;case Ut.SRATIONAL:n=new Int32Array(e*2),r=s.readInt32;break;case Ut.FLOAT:n=new Float32Array(e),r=s.readFloat32;break;case Ut.DOUBLE:n=new Float64Array(e),r=s.readFloat64;break;default:throw new RangeError(`Invalid field type: ${t}`)}if(t===Ut.RATIONAL||t===Ut.SRATIONAL)for(let a=0;af.getWidth()-p.getWidth());for(let f=0;fm||o&&o>_)break}}let d=e;if(a){const[g,f]=l.getOrigin(),[p,m]=h.getResolution(l);d=[Math.round((a[0]-g)/p),Math.round((a[1]-f)/m),Math.round((a[2]-g)/p),Math.round((a[3]-f)/m)],d=[Math.min(d[0],d[2]),Math.min(d[1],d[3]),Math.max(d[0],d[2]),Math.max(d[1],d[3])]}return h.readRasters({...t,window:d})}}class gc extends aL{constructor(t,e,i,n,r={}){super(),this.source=t,this.littleEndian=e,this.bigTiff=i,this.firstIFDOffset=n,this.cache=r.cache||!1,this.ifdRequests=[],this.ghostValues=null}async getSlice(t,e){const i=this.bigTiff?4048:1024;return new KQ((await this.source.fetch([{offset:t,length:typeof e<"u"?e:i}]))[0],t,this.littleEndian,this.bigTiff)}async parseFileDirectoryAt(t){const e=this.bigTiff?20:12,i=this.bigTiff?8:2;let n=await this.getSlice(t);const r=this.bigTiff?n.readUint64(t):n.readUint16(t),o=r*e+(this.bigTiff?16:6);n.covers(t,o)||(n=await this.getSlice(t,o));const a={};let l=t+(this.bigTiff?8:2);for(let u=0;u{const e=await this.ifdRequests[t-1];if(e.nextIFDByteOffset===0)throw new Cf(t);return this.parseFileDirectoryAt(e.nextIFDByteOffset)})(),this.ifdRequests[t]}async getImage(t=0){const e=await this.requestIFD(t);return new rL(e.fileDirectory,e.geoKeyDirectory,this.dataView,this.littleEndian,this.cache,this.source)}async getImageCount(){let t=0,e=!0;for(;e;)try{await this.requestIFD(t),++t}catch(i){if(i instanceof Cf)e=!1;else throw i}return t}async getGhostValues(){const t=this.bigTiff?16:8;if(this.ghostValues)return this.ghostValues;const e="GDAL_STRUCTURAL_METADATA_SIZE=",i=e.length+100;let n=await this.getSlice(t,i);if(e===Bl(n,Ut.ASCII,e.length,t)){const r=Bl(n,Ut.ASCII,i,t).split(` +`).map(e=>{const i=e.split(":").map(n=>n.trim());return i[0]=i[0].toLowerCase(),i});return oL(t)}function ett(s){const[t,...e]=s.split(";").map(n=>n.trim()),i=e.map(n=>n.split("="));return{type:t,params:oL(i)}}function fy(s){let t,e,i;return s&&([,t,e,i]=s.match(/bytes (\d+)-(\d+)\/(\d+)/),t=parseInt(t,10),e=parseInt(e,10),i=parseInt(i,10)),{start:t,end:e,total:i}}function stt(s,t){let e=null;const i=new TextDecoder("ascii"),n=[],r=`--${t}`,o=`${r}--`;for(let a=0;a<10;++a)i.decode(new Uint8Array(s,a,r.length))===r&&(e=a);if(e===null)throw new Error("Could not find initial boundary");for(;ethis.fetchSlice(i,e)))}async fetchSlice(t){throw new Error(`fetching of slice ${t} not possible, not implemented`)}get fileSize(){return null}async close(){}}class itt extends Map{constructor(t={}){if(super(),!(t.maxSize&&t.maxSize>0))throw new TypeError("`maxSize` must be a number greater than 0");if(typeof t.maxAge=="number"&&t.maxAge===0)throw new TypeError("`maxAge` must be a number greater than 0");this.maxSize=t.maxSize,this.maxAge=t.maxAge||Number.POSITIVE_INFINITY,this.onEviction=t.onEviction,this.cache=new Map,this.oldCache=new Map,this._size=0}_emitEvictions(t){if(typeof this.onEviction=="function")for(const[e,i]of t)this.onEviction(e,i.value)}_deleteIfExpired(t,e){return typeof e.expiry=="number"&&e.expiry<=Date.now()?(typeof this.onEviction=="function"&&this.onEviction(t,e.value),this.delete(t)):!1}_getOrDeleteIfExpired(t,e){if(this._deleteIfExpired(t,e)===!1)return e.value}_getItemValue(t,e){return e.expiry?this._getOrDeleteIfExpired(t,e):e.value}_peek(t,e){const i=e.get(t);return this._getItemValue(t,i)}_set(t,e){this.cache.set(t,e),this._size++,this._size>=this.maxSize&&(this._size=0,this._emitEvictions(this.oldCache),this.oldCache=this.cache,this.cache=new Map)}_moveToRecent(t,e){this.oldCache.delete(t),this._set(t,e)}*_entriesAscending(){for(const t of this.oldCache){const[e,i]=t;this.cache.has(e)||this._deleteIfExpired(e,i)===!1&&(yield t)}for(const t of this.cache){const[e,i]=t;this._deleteIfExpired(e,i)===!1&&(yield t)}}get(t){if(this.cache.has(t)){const e=this.cache.get(t);return this._getItemValue(t,e)}if(this.oldCache.has(t)){const e=this.oldCache.get(t);if(this._deleteIfExpired(t,e)===!1)return this._moveToRecent(t,e),e.value}}set(t,e,{maxAge:i=this.maxAge}={}){const n=typeof i=="number"&&i!==Number.POSITIVE_INFINITY?Date.now()+i:void 0;return this.cache.has(t)?this.cache.set(t,{value:e,expiry:n}):this._set(t,{value:e,expiry:n}),this}has(t){return this.cache.has(t)?!this._deleteIfExpired(t,this.cache.get(t)):this.oldCache.has(t)?!this._deleteIfExpired(t,this.oldCache.get(t)):!1}peek(t){if(this.cache.has(t))return this._peek(t,this.cache);if(this.oldCache.has(t))return this._peek(t,this.oldCache)}delete(t){const e=this.cache.delete(t);return e&&this._size--,this.oldCache.delete(t)||e}clear(){this.cache.clear(),this.oldCache.clear(),this._size=0}resize(t){if(!(t&&t>0))throw new TypeError("`maxSize` must be a number greater than 0");const e=[...this._entriesAscending()],i=e.length-t;i<0?(this.cache=new Map(e),this.oldCache=new Map,this._size=e.length):(i>0&&this._emitEvictions(e.slice(0,i)),this.oldCache=new Map(e.slice(i)),this.cache=new Map,this._size=0),this.maxSize=t}*keys(){for(const[t]of this)yield t}*values(){for(const[,t]of this)yield t}*[Symbol.iterator](){for(const t of this.cache){const[e,i]=t;this._deleteIfExpired(e,i)===!1&&(yield[e,i.value])}for(const t of this.oldCache){const[e,i]=t;this.cache.has(e)||this._deleteIfExpired(e,i)===!1&&(yield[e,i.value])}}*entriesDescending(){let t=[...this.cache];for(let e=t.length-1;e>=0;--e){const i=t[e],[n,r]=i;this._deleteIfExpired(n,r)===!1&&(yield[n,r.value])}t=[...this.oldCache];for(let e=t.length-1;e>=0;--e){const i=t[e],[n,r]=i;this.cache.has(n)||this._deleteIfExpired(n,r)===!1&&(yield[n,r.value])}}*entriesAscending(){for(const[t,e]of this._entriesAscending())yield[t,e.value]}get size(){if(!this._size)return this.oldCache.size;let t=0;for(const e of this.oldCache.keys())this.cache.has(e)||t++;return Math.min(this._size+t,this.maxSize)}entries(){return this.entriesAscending()}forEach(t,e=this){for(const[i,n]of this.entriesAscending())t.call(e,n,i,this)}get[Symbol.toStringTag](){return JSON.stringify([...this.entriesAscending()])}}async function ntt(s){return new Promise(t=>setTimeout(t,s))}function rtt(s,t){const e=Array.isArray(s)?s:Array.from(s),i=Array.isArray(t)?t:Array.from(t);return e.map((n,r)=>[n,i[r]])}class dc extends Error{constructor(t){super(t),Error.captureStackTrace&&Error.captureStackTrace(this,dc),this.name="AbortError"}}class ott extends Error{constructor(t,e){super(e),this.errors=t,this.message=e,this.name="AggregateError"}}const att=ott;class ltt{constructor(t,e,i=null){this.offset=t,this.length=e,this.data=i}get top(){return this.offset+this.length}}class XM{constructor(t,e,i){this.offset=t,this.length=e,this.blockIds=i}}class htt extends vw{constructor(t,{blockSize:e=65536,cacheSize:i=100}={}){super(),this.source=t,this.blockSize=e,this.blockCache=new itt({maxSize:i,onEviction:(n,r)=>{this.evictedBlocks.set(n,r)}}),this.evictedBlocks=new Map,this.blockRequests=new Map,this.blockIdsToFetch=new Set,this.abortedBlockIds=new Set}get fileSize(){return this.source.fileSize}async fetch(t,e){const i=[],n=[],r=[];this.evictedBlocks.clear();for(const{offset:d,length:g}of t){let f=d+g;const{fileSize:p}=this;p!==null&&(f=Math.min(f,p));const m=Math.floor(d/this.blockSize)*this.blockSize;for(let _=m;_this.abortedBlockIds.has(d)||!this.blockCache.has(d));if(l.forEach(d=>this.blockIdsToFetch.add(d)),l.length>0&&e&&!e.aborted){this.fetchBlocks(null);for(const d of l){const g=this.blockRequests.get(d);if(!g)throw new Error(`Block ${d} is not in the block requests`);a.push(g)}await Promise.allSettled(a)}if(e&&e.aborted)throw new dc("Request was aborted");const h=r.map(d=>this.blockCache.get(d)||this.evictedBlocks.get(d)),c=h.filter(d=>!d);if(c.length)throw new att(c,"Request failed");const u=new Map(rtt(r,h));return this.readSliceData(t,u)}fetchBlocks(t){if(this.blockIdsToFetch.size>0){const e=this.groupBlocks(this.blockIdsToFetch),i=this.source.fetch(e,t);for(let n=0;n{try{const a=(await i)[n],l=o*this.blockSize,h=l-a.offset,c=Math.min(h+this.blockSize,a.data.byteLength),u=a.data.slice(h,c),d=new ltt(l,u.byteLength,u,o);this.blockCache.set(o,d),this.abortedBlockIds.delete(o)}catch(a){if(a.name==="AbortError")a.signal=t,this.blockCache.delete(o),this.abortedBlockIds.add(o);else throw a}finally{this.blockRequests.delete(o)}})())}this.blockIdsToFetch.clear()}}groupBlocks(t){const e=Array.from(t).sort((o,a)=>o-a);if(e.length===0)return[];let i=[],n=null;const r=[];for(const o of e)n===null||n+1===o?(i.push(o),n=o):(r.push(new XM(i[0]*this.blockSize,i.length*this.blockSize,i)),i=[o],n=o);return r.push(new XM(i[0]*this.blockSize,i.length*this.blockSize,i)),r}readSliceData(t,e){return t.map(i=>{let n=i.offset+i.length;this.fileSize!==null&&(n=Math.min(this.fileSize,n));const r=Math.floor(i.offset/this.blockSize),o=Math.floor(n/this.blockSize),a=new ArrayBuffer(i.length),l=new Uint8Array(a);for(let h=r;h<=o;++h){const c=e.get(h),u=c.offset-i.offset,d=c.top-n;let g=0,f=0,p;u<0?g=-u:u>0&&(f=u),d<0?p=c.length-g:p=n-c.offset-g;const m=new Uint8Array(c.data,g,p);l.set(m,f)}return a})}}class ww{get ok(){return this.status>=200&&this.status<=299}get status(){throw new Error("not implemented")}getHeader(t){throw new Error("not implemented")}async getData(){throw new Error("not implemented")}}class Ew{constructor(t){this.url=t}async request({headers:t,signal:e}={}){throw new Error("request is not implemented")}}class ctt extends ww{constructor(t){super(),this.response=t}get status(){return this.response.status}getHeader(t){return this.response.headers.get(t)}async getData(){return this.response.arrayBuffer?await this.response.arrayBuffer():(await this.response.buffer()).buffer}}class utt extends Ew{constructor(t,e){super(t),this.credentials=e}async request({headers:t,signal:e}={}){const i=await fetch(this.url,{headers:t,credentials:this.credentials,signal:e});return new ctt(i)}}class dtt extends ww{constructor(t,e){super(),this.xhr=t,this.data=e}get status(){return this.xhr.status}getHeader(t){return this.xhr.getResponseHeader(t)}async getData(){return this.data}}class gtt extends Ew{constructRequest(t,e){return new Promise((i,n)=>{const r=new XMLHttpRequest;r.open("GET",this.url),r.responseType="arraybuffer";for(const[o,a]of Object.entries(t))r.setRequestHeader(o,a);r.onload=()=>{const o=r.response;i(new dtt(r,o))},r.onerror=n,r.onabort=()=>n(new dc("Request aborted")),r.send(),e&&(e.aborted&&r.abort(),e.addEventListener("abort",()=>r.abort()))})}async request({headers:t,signal:e}={}){return await this.constructRequest(t,e)}}const VM={};class ftt extends ww{constructor(t,e){super(),this.response=t,this.dataPromise=e}get status(){return this.response.statusCode}getHeader(t){return this.response.headers[t]}async getData(){return await this.dataPromise}}class ptt extends Ew{constructor(t){super(t),this.parsedUrl=VM.parse(this.url),this.httpApi=(this.parsedUrl.protocol,VM)}constructRequest(t,e){return new Promise((i,n)=>{const r=this.httpApi.get({...this.parsedUrl,headers:t},o=>{const a=new Promise(l=>{const h=[];o.on("data",c=>{h.push(c)}),o.on("end",()=>{const c=Buffer.concat(h).buffer;l(c)}),o.on("error",n)});i(new ftt(o,a))});r.on("error",n),e&&(e.aborted&&r.destroy(new dc("Request aborted")),e.addEventListener("abort",()=>r.destroy(new dc("Request aborted"))))})}async request({headers:t,signal:e}={}){return await this.constructRequest(t,e)}}class Sw extends vw{constructor(t,e,i,n){super(),this.client=t,this.headers=e,this.maxRanges=i,this.allowFullFile=n,this._fileSize=null}async fetch(t,e){return this.maxRanges>=t.length?this.fetchSlices(t,e):(this.maxRanges>0&&t.length>1,Promise.all(t.map(i=>this.fetchSlice(i,e))))}async fetchSlices(t,e){const i=await this.client.request({headers:{...this.headers,Range:`bytes=${t.map(({offset:n,length:r})=>`${n}-${n+r}`).join(",")}`},signal:e});if(i.ok)if(i.status===206){const{type:n,params:r}=ett(i.getHeader("content-type"));if(n==="multipart/byteranges"){const u=stt(await i.getData(),r.boundary);return this._fileSize=u[0].fileSize||null,u}const o=await i.getData(),{start:a,end:l,total:h}=fy(i.getHeader("content-range"));this._fileSize=h||null;const c=[{data:o,offset:a,length:l-a}];if(t.length>1){const u=await Promise.all(t.slice(1).map(d=>this.fetchSlice(d,e)));return c.concat(u)}return c}else{if(!this.allowFullFile)throw new Error("Server responded with full file");const n=await i.getData();return this._fileSize=n.byteLength,[{data:n,offset:0,length:n.byteLength}]}else throw new Error("Error fetching data.")}async fetchSlice(t,e){const{offset:i,length:n}=t,r=await this.client.request({headers:{...this.headers,Range:`bytes=${i}-${i+n}`},signal:e});if(r.ok)if(r.status===206){const o=await r.getData(),{total:a}=fy(r.getHeader("content-range"));return this._fileSize=a||null,{data:o,offset:i,length:n}}else{if(!this.allowFullFile)throw new Error("Server responded with full file");const o=await r.getData();return this._fileSize=o.byteLength,{data:o,offset:0,length:o.byteLength}}else throw new Error("Error fetching data.")}get fileSize(){return this._fileSize}}function Mw(s,{blockSize:t,cacheSize:e}){return t===null?s:new htt(s,{blockSize:t,cacheSize:e})}function mtt(s,{headers:t={},credentials:e,maxRanges:i=0,allowFullFile:n=!1,...r}={}){const o=new utt(s,e),a=new Sw(o,t,i,n);return Mw(a,r)}function _tt(s,{headers:t={},maxRanges:e=0,allowFullFile:i=!1,...n}={}){const r=new gtt(s),o=new Sw(r,t,e,i);return Mw(o,n)}function ytt(s,{headers:t={},maxRanges:e=0,allowFullFile:i=!1,...n}={}){const r=new ptt(s),o=new Sw(r,t,e,i);return Mw(o,n)}function py(s,{forceXHR:t=!1,...e}={}){return typeof fetch=="function"&&!t?mtt(s,e):typeof XMLHttpRequest<"u"?_tt(s,e):ytt(s,e)}class xtt extends vw{constructor(t){super(),this.file=t}async fetchSlice(t,e){return new Promise((i,n)=>{const r=this.file.slice(t.offset,t.offset+t.length),o=new FileReader;o.onload=a=>i(a.target.result),o.onerror=n,o.onabort=n,o.readAsArrayBuffer(r),e&&e.addEventListener("abort",()=>o.abort())})}}function vtt(s){return new xtt(s)}function my(s){switch(s){case Ut.BYTE:case Ut.ASCII:case Ut.SBYTE:case Ut.UNDEFINED:return 1;case Ut.SHORT:case Ut.SSHORT:return 2;case Ut.LONG:case Ut.SLONG:case Ut.FLOAT:case Ut.IFD:return 4;case Ut.RATIONAL:case Ut.SRATIONAL:case Ut.DOUBLE:case Ut.LONG8:case Ut.SLONG8:case Ut.IFD8:return 8;default:throw new RangeError(`Invalid field type: ${s}`)}}function wtt(s){const t=s.GeoKeyDirectory;if(!t)return null;const e={};for(let i=4;i<=t[3]*4;i+=4){const n=AQ[t[i]],r=t[i+1]?Ku[t[i+1]]:null,o=t[i+2],a=t[i+3];let l=null;if(!r)l=a;else{if(l=s[r],typeof l>"u"||l===null)throw new Error(`Could not get value of geoKey '${n}'.`);typeof l=="string"?l=l.substring(a,a+o-1):l.subarray&&(l=l.subarray(a,a+o),o===1&&(l=l[0]))}e[n]=l}return e}function Bl(s,t,e,i){let n=null,r=null;const o=my(t);switch(t){case Ut.BYTE:case Ut.ASCII:case Ut.UNDEFINED:n=new Uint8Array(e),r=s.readUint8;break;case Ut.SBYTE:n=new Int8Array(e),r=s.readInt8;break;case Ut.SHORT:n=new Uint16Array(e),r=s.readUint16;break;case Ut.SSHORT:n=new Int16Array(e),r=s.readInt16;break;case Ut.LONG:case Ut.IFD:n=new Uint32Array(e),r=s.readUint32;break;case Ut.SLONG:n=new Int32Array(e),r=s.readInt32;break;case Ut.LONG8:case Ut.IFD8:n=new Array(e),r=s.readUint64;break;case Ut.SLONG8:n=new Array(e),r=s.readInt64;break;case Ut.RATIONAL:n=new Uint32Array(e*2),r=s.readUint32;break;case Ut.SRATIONAL:n=new Int32Array(e*2),r=s.readInt32;break;case Ut.FLOAT:n=new Float32Array(e),r=s.readFloat32;break;case Ut.DOUBLE:n=new Float64Array(e),r=s.readFloat64;break;default:throw new RangeError(`Invalid field type: ${t}`)}if(t===Ut.RATIONAL||t===Ut.SRATIONAL)for(let a=0;af.getWidth()-p.getWidth());for(let f=0;fm||o&&o>_)break}}let d=e;if(a){const[g,f]=l.getOrigin(),[p,m]=h.getResolution(l);d=[Math.round((a[0]-g)/p),Math.round((a[1]-f)/m),Math.round((a[2]-g)/p),Math.round((a[3]-f)/m)],d=[Math.min(d[0],d[2]),Math.min(d[1],d[3]),Math.max(d[0],d[2]),Math.max(d[1],d[3])]}return h.readRasters({...t,window:d})}}class gc extends aL{constructor(t,e,i,n,r={}){super(),this.source=t,this.littleEndian=e,this.bigTiff=i,this.firstIFDOffset=n,this.cache=r.cache||!1,this.ifdRequests=[],this.ghostValues=null}async getSlice(t,e){const i=this.bigTiff?4048:1024;return new KQ((await this.source.fetch([{offset:t,length:typeof e<"u"?e:i}]))[0],t,this.littleEndian,this.bigTiff)}async parseFileDirectoryAt(t){const e=this.bigTiff?20:12,i=this.bigTiff?8:2;let n=await this.getSlice(t);const r=this.bigTiff?n.readUint64(t):n.readUint16(t),o=r*e+(this.bigTiff?16:6);n.covers(t,o)||(n=await this.getSlice(t,o));const a={};let l=t+(this.bigTiff?8:2);for(let u=0;u{const e=await this.ifdRequests[t-1];if(e.nextIFDByteOffset===0)throw new Tf(t);return this.parseFileDirectoryAt(e.nextIFDByteOffset)})(),this.ifdRequests[t]}async getImage(t=0){const e=await this.requestIFD(t);return new rL(e.fileDirectory,e.geoKeyDirectory,this.dataView,this.littleEndian,this.cache,this.source)}async getImageCount(){let t=0,e=!0;for(;e;)try{await this.requestIFD(t),++t}catch(i){if(i instanceof Tf)e=!1;else throw i}return t}async getGhostValues(){const t=this.bigTiff?16:8;if(this.ghostValues)return this.ghostValues;const e="GDAL_STRUCTURAL_METADATA_SIZE=",i=e.length+100;let n=await this.getSlice(t,i);if(e===Bl(n,Ut.ASCII,e.length,t)){const r=Bl(n,Ut.ASCII,i,t).split(` `)[0],o=Number(r.split("=")[1].split(" ")[0])+r.length;o>i&&(n=await this.getSlice(t,o));const a=Bl(n,Ut.ASCII,o,t);this.ghostValues={},a.split(` -`).filter(l=>l.length>0).map(l=>l.split("=")).forEach(([l,h])=>{this.ghostValues[l]=h})}return this.ghostValues}static async fromSource(t,e,i){const n=(await t.fetch([{offset:0,length:1024}],i))[0],r=new HQ(n),o=r.getUint16(0,0);let a;if(o===18761)a=!0;else if(o===19789)a=!1;else throw new TypeError("Invalid byte order value.");const l=r.getUint16(2,a);let h;if(l===42)h=!1;else if(l===43){if(h=!0,r.getUint16(4,a)!==8)throw new Error("Unsupported offset byte-size.")}else throw new TypeError("Invalid magic number.");const c=h?r.getUint64(8,a):r.getUint32(4,a);return new gc(t,a,h,c,e)}close(){return typeof this.source.close=="function"?this.source.close():!1}}class Stt extends aL{constructor(t,e){super(),this.mainFile=t,this.overviewFiles=e,this.imageFiles=[t].concat(e),this.fileDirectoriesPerFile=null,this.fileDirectoriesPerFileParsing=null,this.imageCount=null}async parseFileDirectoriesPerFile(){const t=[this.mainFile.parseFileDirectoryAt(this.mainFile.firstIFDOffset)].concat(this.overviewFiles.map(e=>e.parseFileDirectoryAt(e.firstIFDOffset)));return this.fileDirectoriesPerFile=await Promise.all(t),this.fileDirectoriesPerFile}async getImage(t=0){await this.getImageCount(),await this.parseFileDirectoriesPerFile();let e=0,i=0;for(let n=0;ne.getImageCount()));return this.imageCounts=await Promise.all(t),this.imageCount=this.imageCounts.reduce((e,i)=>e+i,0),this.imageCount}}async function Mtt(s,t={},e){return gc.fromSource(py(s,t),e)}async function btt(s,t){return gc.fromSource(vtt(s),t)}async function Ttt(s,t=[],e={},i){const n=await gc.fromSource(py(s,e),i),r=await Promise.all(t.map(o=>gc.fromSource(py(o,e))));return new Stt(n,r)}function Ctt(s){return((s.fileDirectory.NewSubfileType||0)&4)===4}function Rtt(s,t){if(!s)return!1;if(s===!0)return!0;if(t.getSamplesPerPixel()!==3)return!1;const e=t.fileDirectory.PhotometricInterpretation,i=gi;return e===i.CMYK||e===i.YCbCr||e===i.CIELab||e===i.ICCLab}const YM="STATISTICS_MAXIMUM",qM="STATISTICS_MINIMUM",Z_=256;let H_;function Itt(){return H_||(H_=new QQ),H_}function Ptt(s){try{return s.getBoundingBox()}catch{return[0,0,s.getWidth(),s.getHeight()]}}function Att(s){try{return s.getOrigin().slice(0,2)}catch{return[0,s.getHeight()]}}function Ltt(s,t){try{return s.getResolution(t)}catch{return[t.getWidth()/s.getWidth(),t.getHeight()/s.getHeight()]}}function Ott(s){const t=s.geoKeys;if(!t)return null;if(t.ProjectedCSTypeGeoKey&&t.ProjectedCSTypeGeoKey!==32767){const e="EPSG:"+t.ProjectedCSTypeGeoKey;let i=st(e);if(!i){const n=e2(t.ProjLinearUnitsGeoKey);n&&(i=new rc({code:e,units:n}))}return i}if(t.GeographicTypeGeoKey&&t.GeographicTypeGeoKey!==32767){const e="EPSG:"+t.GeographicTypeGeoKey;let i=st(e);if(!i){const n=e2(t.GeogAngularUnitsGeoKey);n&&(i=new rc({code:e,units:n}))}return i}return null}function Ftt(s){return s.getImageCount().then(function(t){const e=new Array(t);for(let i=0;ie*s)throw new Error(i)}function Dtt(s){return s instanceof Int8Array?-128:s instanceof Int16Array?-32768:s instanceof Int32Array?-2147483648:s instanceof Float32Array?12e-39:0}function ktt(s){return s instanceof Int8Array?127:s instanceof Uint8Array||s instanceof Uint8ClampedArray?255:s instanceof Int16Array?32767:s instanceof Uint16Array?65535:s instanceof Int32Array?2147483647:s instanceof Uint32Array?4294967295:s instanceof Float32Array?34e37:255}class bw extends d0{constructor(t){super({state:"loading",tileGrid:null,projection:t.projection||null,transition:t.transition,interpolate:t.interpolate!==!1,wrapX:t.wrapX}),this.sourceInfo_=t.sources;const e=this.sourceInfo_.length;this.sourceOptions_=t.sourceOptions,this.sourceImagery_=new Array(e),this.sourceMasks_=new Array(e),this.resolutionFactors_=new Array(e),this.samplesPerPixel_,this.nodataValues_,this.metadata_,this.normalize_=t.normalize!==!1,this.addAlpha_=!1,this.error_=null,this.convertToRGB_=t.convertToRGB||!1,this.setKey(this.sourceInfo_.map(r=>r.url).join(","));const i=this,n=new Array(e);for(let r=0;r=0;--i){const n=e[i],r=Ott(n);if(r){this.projection=r;break}}}configure_(t){let e,i,n,r,o;const a=new Array(t.length),l=new Array(t.length),h=new Array(t.length);let c=0;const u=t.length;for(let p=0;p{Ctt(C)?_.push(C):m.push(C)});const y=m.length;if(_.length>0&&_.length!==y)throw new Error(`Expected one mask per image found ${_.length} masks and ${y} images`);let v,S;const w=new Array(y),T=new Array(y),M=new Array(y);l[p]=new Array(y),h[p]=new Array(y);for(let C=0;CM.length&&(c=o.length-M.length);const C=o[o.length-1]/M[M.length-1];this.resolutionFactors_[p]=C;const I=M.map(P=>P*=C),O=`Resolution mismatch for source ${p}, got [${I}] but expected [${o}]`;Mu(o.slice(c,o.length),I,.02,O,this.viewRejector)}n?Mu(n.slice(c,n.length),T,.01,`Tile size mismatch for source ${p}`,this.viewRejector):n=T,r?Mu(r.slice(c,r.length),w,0,`Tile size mismatch for source ${p}`,this.viewRejector):r=w,this.sourceImagery_[p]=m.reverse(),this.sourceMasks_[p]=_.reverse()}for(let p=0,m=this.sourceImagery_.length;p{const i=this.sourceImage_.getState();(i==it.LOADED||i==it.ERROR)&&(this.unlistenSource_(),this.reproject_())}),this.sourceImage_.load())}}unlistenSource_(){ms(this.sourceListenerKey_),this.sourceListenerKey_=null}}const cr=4,K_={IMAGELOADSTART:"imageloadstart",IMAGELOADEND:"imageloadend",IMAGELOADERROR:"imageloaderror"};class Gtt extends Sr{constructor(t,e){super(t),this.image=e}}class jtt extends Lc{constructor(t){super({attributions:t.attributions,projection:t.projection,state:t.state,interpolate:t.interpolate!==void 0?t.interpolate:!0}),this.on,this.once,this.un,this.loader=t.loader||null,this.resolutions_=t.resolutions!==void 0?t.resolutions:null,this.reprojectedImage_=null,this.reprojectedRevision_=0,this.image=null,this.wantedExtent_,this.wantedResolution_,this.static_=t.loader?t.loader.length===0:!1,this.wantedProjection_=null}getResolutions(){return this.resolutions_}setResolutions(t){this.resolutions_=t}findNearestResolution(t){const e=this.getResolutions();if(e){const i=Om(e,t,0);t=e[i]}return t}getImage(t,e,i,n){const r=this.getProjection();if(!r||!n||qs(r,n))return r&&(n=r),this.getImageInternal(t,e,i,n);if(this.reprojectedImage_){if(this.reprojectedRevision_==this.getRevision()&&qs(this.reprojectedImage_.getProjection(),n)&&this.reprojectedImage_.getResolution()==e&&so(this.reprojectedImage_.getExtent(),t))return this.reprojectedImage_;this.reprojectedImage_.dispose(),this.reprojectedImage_=null}return this.reprojectedImage_=new $tt(r,n,t,e,i,(o,a,l)=>this.getImageInternal(o,a,l,r),this.getInterpolate()),this.reprojectedRevision_=this.getRevision(),this.reprojectedImage_}getImageInternal(t,e,i,n){if(this.loader){const r=m0(t,e,i,1),o=this.findNearestResolution(e);if(this.image&&(this.static_||this.wantedProjection_===n&&(this.wantedExtent_&&ai(this.wantedExtent_,r)||ai(this.image.getExtent(),r))&&(this.wantedResolution_&&qp(this.wantedResolution_)===o||qp(this.image.getResolution())===o)))return this.image;this.wantedProjection_=n,this.wantedExtent_=r,this.wantedResolution_=o,this.image=new Wm(r,o,i,this.loader),this.image.addEventListener(Zt.CHANGE,this.handleImageChange.bind(this))}return this.image}handleImageChange(t){const e=t.target;let i;switch(e.getState()){case it.LOADING:this.loading=!0,i=K_.IMAGELOADSTART;break;case it.LOADED:this.loading=!1,i=K_.IMAGELOADEND;break;case it.ERROR:this.loading=!1,i=K_.IMAGELOADERROR;break;default:return}this.hasListener(i)&&this.dispatchEvent(new Gtt(i,e))}}function p0(s,t){s.getImage().src=t}function m0(s,t,e,i){const n=t/e,r=Rs(s),o=Xo(Rt(s)/n,cr),a=Xo(Ee(s)/n,cr),l=Xo((i-1)*o/2,cr),h=o+2*l,c=Xo((i-1)*a/2,cr),u=a+2*c;return qx(r,n,0,[h,u])}const ya=jtt;function lL(s){const t=s.load||pa,e=s.imageExtent,i=s.crossOrigin??null;return()=>{const n=new Image;return n.crossOrigin=i,t(n,s.url).then(r=>{const o=Rt(e)/r.width,a=Ee(e)/r.height;return{image:r,extent:e,resolution:o!==a?[o,a]:a,pixelRatio:1}})}}class hL extends ya{constructor(t){const e=t.crossOrigin!==void 0?t.crossOrigin:null,i=t.imageLoadFunction!==void 0?t.imageLoadFunction:p0;super({attributions:t.attributions,interpolate:t.interpolate,projection:st(t.projection)}),this.url_=t.url,this.imageExtent_=t.imageExtent,this.image=null,this.image=new Wm(this.imageExtent_,void 0,1,lL({url:t.url,imageExtent:t.imageExtent,crossOrigin:e,load:(n,r)=>(this.image.setImage(n),i(this.image,r),pa(n))})),this.image.addEventListener(Zt.CHANGE,this.handleImageChange.bind(this))}getImageExtent(){return this.imageExtent_}getImageInternal(t,e,i,n){return Te(t,this.image.getExtent())?this.image:null}getUrl(){return this.url_}}function oo(s,t){const e=[];Object.keys(t).forEach(function(n){t[n]!==null&&t[n]!==void 0&&e.push(n+"="+encodeURIComponent(t[n]))});const i=e.join("&");return s=s.replace(/[?&]$/,""),s+=s.includes("?")?"&":"?",s+i}const ztt=/\{z\}/g,Utt=/\{x\}/g,Btt=/\{y\}/g,Wtt=/\{-y\}/g;function cL(s,t,e,i,n){return s.replace(ztt,t.toString()).replace(Utt,e.toString()).replace(Btt,i.toString()).replace(Wtt,function(){if(n===void 0)throw new Error("If the URL template has a {-y} placeholder, the grid extent must be known");return(n-i).toString()})}function Xtt(s,t,e,i){const n=fA(t,e,i),r=kn(n,s.length);return s[r]}function _0(s){const t=[];let e=/\{([a-z])-([a-z])\}/.exec(s);if(e){const i=e[1].charCodeAt(0),n=e[2].charCodeAt(0);let r;for(r=i;r<=n;++r)t.push(s.replace(e[0],String.fromCharCode(r)));return t}if(e=/\{(\d+)-(\d+)\}/.exec(s),e){const i=parseInt(e[2],10);for(let n=parseInt(e[1],10);n<=i;n++)t.push(s.replace(e[0],n.toString()));return t}return t.push(s),t}function Vtt(s,t){return function(e,i,n){if(!e)return;let r;const o=e[0];if(t){const a=t.getFullTileRange(o);a&&(r=a.getHeight()-1)}return cL(s,o,e[1],e[2],r)}}function Tw(s,t){const e=s.length,i=new Array(e);for(let n=0;nthis.getTileInternal(m,_,y,v,o),this.reprojectionErrorThreshold_,this.renderReprojectionEdges_,this.tileOptions);return p.key=u,h?a.replace(c,p):a.set(c,p),p}getTileInternal(t,e,i,n,r){const o=ro(t,e,i),a=this.getKey();if(!this.tileCache.containsKey(o)){const h=this.createTile_(t,e,i,n,r,a);return this.tileCache.set(o,h),h}let l=this.tileCache.get(o);return l.key!=a&&(l=this.createTile_(t,e,i,n,r,a),this.tileCache.replace(o,l)),l}setRenderReprojectionEdges(t){if(this.renderReprojectionEdges_!=t){this.renderReprojectionEdges_=t;for(const e in this.tileCacheForProjection)this.tileCacheForProjection[e].clear();this.changed()}}setTileGridForProjection(t,e){const i=st(t);if(i){const n=mt(i);n in this.tileGridForProjection||(this.tileGridForProjection[n]=e)}}clear(){super.clear();for(const t in this.tileCacheForProjection)this.tileCacheForProjection[t].clear()}}function qtt(s,t){s.getImage().src=t}function Iw(s,t,e,i){const n=document.createElement("script"),r="olc_"+mt(t);function o(){delete window[r],n.parentNode.removeChild(n)}n.async=!0,n.src=s+(s.includes("?")?"&":"?")+"callback="+r;const a=setTimeout(function(){o(),e&&e()},1e4);window[r]=function(l){clearTimeout(a),o(),t(l)},document.head.appendChild(n)}class Ztt extends Error{constructor(t){const e="Unexpected response status: "+t.status;super(e),this.name="ResponseError",this.response=t}}class Htt extends Error{constructor(t){super("Failed to issue request"),this.name="ClientError",this.client=t}}function uL(s){return new Promise(function(t,e){function i(o){const a=o.target;if(!a.status||a.status>=200&&a.status<300){let l;try{l=JSON.parse(a.responseText)}catch(h){const c="Error parsing response text as JSON: "+h.message;e(new Error(c));return}t(l);return}e(new Ztt(a))}function n(o){e(new Htt(o.target))}const r=new XMLHttpRequest;r.addEventListener("load",i),r.addEventListener("error",n),r.open("GET",s),r.setRequestHeader("Accept","application/json"),r.send()})}function dL(s,t){return t.includes("://")?t:new URL(t,s).href}class gL extends Sn{constructor(t){if(super({attributions:t.attributions,cacheSize:t.cacheSize,crossOrigin:t.crossOrigin,interpolate:t.interpolate,projection:st("EPSG:3857"),reprojectionErrorThreshold:t.reprojectionErrorThreshold,state:"loading",tileLoadFunction:t.tileLoadFunction,wrapX:t.wrapX!==void 0?t.wrapX:!0,transition:t.transition,zDirection:t.zDirection}),this.tileJSON_=null,this.tileSize_=t.tileSize,t.url)if(t.jsonp)Iw(t.url,this.handleTileJSONResponse.bind(this),this.handleTileJSONError.bind(this));else{const e=new XMLHttpRequest;e.addEventListener("load",this.onXHRLoad_.bind(this)),e.addEventListener("error",this.onXHRError_.bind(this)),e.open("GET",t.url),e.send()}else if(t.tileJSON)this.handleTileJSONResponse(t.tileJSON);else throw new Error("Either `url` or `tileJSON` options must be provided")}onXHRLoad_(t){const e=t.target;if(!e.status||e.status>=200&&e.status<300){let i;try{i=JSON.parse(e.responseText)}catch{this.handleTileJSONError();return}this.handleTileJSONResponse(i)}else this.handleTileJSONError()}onXHRError_(t){this.handleTileJSONError()}getTileJSON(){return this.tileJSON_}handleTileJSONResponse(t){const e=st("EPSG:4326"),i=this.getProjection();let n;if(t.bounds!==void 0){const h=Sl(e,i);n=nc(t.bounds,h)}const r=yo(i),o=t.minzoom||0,a=t.maxzoom||22,l=Tl({extent:r,maxZoom:a,minZoom:o,tileSize:this.tileSize_});if(this.tileGrid=l,this.tileUrlFunction=Tw(t.tiles,l),t.attribution&&!this.getAttributions()){const h=n!==void 0?n:r;this.setAttributions(function(c){return Te(h,c.extent)?[t.attribution]:null})}this.tileJSON_=t,this.setState("ready")}handleTileJSONError(){this.setState("error")}}let Ktt=class extends Oc{constructor(s,t,e,i,n,r){super(s,t,r),this.extent=null,this.format_=i,this.features_=null,this.loader_,this.projection=null,this.resolution,this.tileLoadFunction_=n,this.url_=e,this.key=e}getFormat(){return this.format_}getFeatures(){return this.features_}load(){this.state==X.IDLE&&(this.setState(X.LOADING),this.tileLoadFunction_(this,this.url_),this.loader_&&this.loader_(this.extent,this.resolution,this.projection))}onLoad(s,t){this.setFeatures(s)}onError(){this.setState(X.ERROR)}setFeatures(s){this.features_=s,this.setState(X.LOADED)}setLoader(s){this.loader_=s}};const ZM=[];class Jtt extends Oc{constructor(t,e,i,n){super(t,e,{transition:0}),this.context_=null,this.executorGroups=[],this.loadingSourceTiles=0,this.hitDetectionImageData={},this.replayState_={},this.sourceTiles=[],this.errorTileKeys={},this.wantedResolution,this.getSourceTiles=n.bind(void 0,this),this.wrappedTileCoord=i}getContext(){return this.context_||(this.context_=Se(1,1,ZM)),this.context_}hasContext(){return!!this.context_}getImage(){return this.hasContext()?this.getContext().canvas:null}getReplayState(t){const e=mt(t);return e in this.replayState_||(this.replayState_[e]={dirty:!1,renderedRenderOrder:null,renderedResolution:NaN,renderedRevision:-1,renderedTileResolution:NaN,renderedTileRevision:-1,renderedTileZ:-1}),this.replayState_[e]}load(){this.getSourceTiles()}release(){ol(this.context_),ZM.push(this.context_.canvas),this.context_=null,super.release()}}class y0 extends Rw{constructor(t){const e=t.projection||"EPSG:3857",i=t.extent||yo(e),n=t.tileGrid||Tl({extent:i,maxResolution:t.maxResolution,maxZoom:t.maxZoom!==void 0?t.maxZoom:22,minZoom:t.minZoom,tileSize:t.tileSize||512});super({attributions:t.attributions,attributionsCollapsible:t.attributionsCollapsible,cacheSize:t.cacheSize,interpolate:!0,projection:e,state:t.state,tileGrid:n,tileLoadFunction:t.tileLoadFunction?t.tileLoadFunction:Qtt,tileUrlFunction:t.tileUrlFunction,url:t.url,urls:t.urls,wrapX:t.wrapX===void 0?!0:t.wrapX,transition:t.transition,zDirection:t.zDirection===void 0?1:t.zDirection}),this.format_=t.format?t.format:null,this.sourceTileCache_=new u0(128),this.overlaps_=t.overlaps==null?!0:t.overlaps,this.tileClass=t.tileClass?t.tileClass:Ktt,this.tileGrids_={}}getOverlaps(){return this.overlaps_}clear(){this.sourceTileCache_.clear()}expireCache(t,e){const i=this.getTileCacheForProjection(t),n=Object.keys(e).reduce((r,o)=>{const a=EK(o),l=i.peek(a);if(l){const h=l.sourceTiles;for(let c=0,u=h.length;c{const g=this.tileUrlFunction(d,t,e),f=this.sourceTileCache_.containsKey(g)?this.sourceTileCache_.get(g):new this.tileClass(d,g?X.IDLE:X.EMPTY,g,this.format_,this.tileLoadFunction);i.sourceTiles.push(f);const p=f.getState();if(p{this.handleTileChange(_);const y=f.getState();if(y===X.LOADED||y===X.ERROR){const v=f.getKey();v in i.errorTileKeys?f.getState()===X.LOADED&&delete i.errorTileKeys[v]:i.loadingSourceTiles--,y===X.ERROR?i.errorTileKeys[v]=!0:f.removeEventListener(Zt.CHANGE,m),i.loadingSourceTiles===0&&i.setState(eo(i.errorTileKeys)?X.LOADED:X.ERROR)}};f.addEventListener(Zt.CHANGE,m),i.loadingSourceTiles++}p===X.IDLE&&(f.extent=h.getTileCoordExtent(d),f.projection=e,f.resolution=h.getResolution(d[0]),this.sourceTileCache_.set(g,f),f.load())}),i.loadingSourceTiles||i.setState(i.sourceTiles.some(d=>d.getState()===X.ERROR)?X.ERROR:X.LOADED)}return i.sourceTiles}getTile(t,e,i,n,r){const o=[t,e,i];let a=this.getTileCoordForTileUrlFunction(o,r);const l=this.getTileGrid().getExtent(),h=this.getTileGridForProjection(r);if(a&&l){const d=h.getTileCoordExtent(a);_n(d,-h.getResolution(t),d),Te(l,d)||(a=null)}let c=!0;if(a!==null){const d=this.tileGrid,g=h.getResolution(t),f=d.getZForResolution(g,1),p=h.getTileCoordExtent(a);_n(p,-g,p),d.forEachTileCoord(p,f,m=>{c=c&&!this.tileUrlFunction(m,n,r)})}const u=new Jtt(o,c?X.EMPTY:X.IDLE,a,this.getSourceTiles.bind(this,n,r));return u.key=this.getKey(),u}getTileGridForProjection(t){const e=t.getCode();let i=this.tileGrids_[e];if(!i){const n=this.tileGrid,r=n.getResolutions().slice(),o=r.map(function(h,c){return n.getOrigin(c)}),a=r.map(function(h,c){return n.getTileSize(c)}),l=GP+1;for(let h=r.length;h=0;n[o?"CRS":"SRS"]=i.getCode();const a=o&&r.startsWith("ne")?[t[1],t[0],t[3],t[2]]:t;return n.BBOX=a.join(","),oo(s,n)}function pL(s,t,e,i,n,r,o){r=Object.assign({REQUEST:"GetMap"},r);const a=t/e,l=[Mp(Rt(s)/a,cr),Mp(Ee(s)/a,cr)];if(e!=1)switch(o){case"geoserver":const h=90*e+.5|0;"FORMAT_OPTIONS"in r?r.FORMAT_OPTIONS+=";dpi:"+h:r.FORMAT_OPTIONS="dpi:"+h;break;case"mapserver":r.MAP_RESOLUTION=90*e;break;case"carmentaserver":case"qgis":r.DPI=90*e;break;default:throw new Error("Unknown `serverType` configured")}return fL(n,s,l,i,r)}function Qp(s,t){return Object.assign({REQUEST:t,SERVICE:"WMS",VERSION:Jp,FORMAT:"image/png",STYLES:"",TRANSPARENT:!0},s)}function mL(s){const t=s.hidpi===void 0?!0:s.hidpi,e=st(s.projection||"EPSG:3857"),i=s.ratio||1.5,n=s.load||pa,r=s.crossOrigin??null;return(o,a,l)=>{o=m0(o,a,l,i),l!=1&&(!t||s.serverType===void 0)&&(l=1);const h=pL(o,a,l,e,s.url,Qp(s.params,"GetMap"),s.serverType),c=new Image;return c.crossOrigin=r,n(c,h).then(u=>({image:u,extent:o,pixelRatio:l}))}}function tet(s,t,e){if(s.url===void 0)return;const i=st(s.projection||"EPSG:3857"),n=qx(t,e,0,HM),r={QUERY_LAYERS:s.params.LAYERS,INFO_FORMAT:"application/json"};Object.assign(r,Qp(s.params,"GetFeatureInfo"),s.params);const o=fh((t[0]-n[0])/e,cr),a=fh((n[3]-t[1])/e,cr),l=Jx(r.VERSION,"1.3")>=0;return r[l?"I":"X"]=o,r[l?"J":"Y"]=a,fL(s.url,n,HM,i,r)}function eet(s,t){if(s.url===void 0)return;const e={SERVICE:"WMS",VERSION:Jp,REQUEST:"GetLegendGraphic",FORMAT:"image/png"};if(t!==void 0){const i=st(s.projection||"EPSG:3857").getMetersPerUnit()||1,n=28e-5;e.SCALE=t*i/n}if(Object.assign(e,s.params),s.params!==void 0&&e.LAYER===void 0){const i=e.LAYERS;if(!(!Array.isArray(i)||i.length!==1))return;e.LAYER=i}return oo(s.url,e)}class _L extends Sn{constructor(t){t=t||{};const e=Object.assign({},t.params);super({attributions:t.attributions,attributionsCollapsible:t.attributionsCollapsible,cacheSize:t.cacheSize,crossOrigin:t.crossOrigin,interpolate:t.interpolate,projection:t.projection,reprojectionErrorThreshold:t.reprojectionErrorThreshold,tileClass:t.tileClass,tileGrid:t.tileGrid,tileLoadFunction:t.tileLoadFunction,url:t.url,urls:t.urls,wrapX:t.wrapX!==void 0?t.wrapX:!0,transition:t.transition,zDirection:t.zDirection}),this.gutter_=t.gutter!==void 0?t.gutter:0,this.params_=e,this.v13_=!0,this.serverType_=t.serverType,this.hidpi_=t.hidpi!==void 0?t.hidpi:!0,this.tmpExtent_=Zs(),this.updateV13_(),this.setKey(this.getKeyForParams_())}getFeatureInfoUrl(t,e,i,n){const r=st(i),o=this.getProjection()||r;let a=this.getTileGrid();a||(a=this.getTileGridForProjection(o));const l=Dm(t,r,o),h=$d(o,r,t,e),c=a.getZForResolution(h,this.zDirection),u=a.getResolution(c),d=a.getTileCoordForCoordAndZ(l,c);if(a.getResolutions().length<=d[0])return;let g=a.getTileCoordExtent(d,this.tmpExtent_);const f=this.gutter_;f!==0&&(g=_n(g,u*f,g));const p={QUERY_LAYERS:this.params_.LAYERS};Object.assign(p,Qp(this.params_,"GetFeatureInfo"),n);const m=Math.floor((l[0]-g[0])/u),_=Math.floor((g[3]-l[1])/u);return p[this.v13_?"I":"X"]=m,p[this.v13_?"J":"Y"]=_,this.getRequestUrl_(d,g,1,o||r,p)}getLegendUrl(t,e){if(this.urls[0]===void 0)return;const i={SERVICE:"WMS",VERSION:Jp,REQUEST:"GetLegendGraphic",FORMAT:"image/png"};if(e===void 0||e.LAYER===void 0){const n=this.params_.LAYERS;if(!(!Array.isArray(n)||n.length===1))return;i.LAYER=n}if(t!==void 0){const n=this.getProjection()?this.getProjection().getMetersPerUnit():1,r=28e-5;i.SCALE=t*n/r}return Object.assign(i,e),oo(this.urls[0],i)}getGutter(){return this.gutter_}getParams(){return this.params_}getRequestUrl_(t,e,i,n,r){const o=this.urls;if(!o)return;let a;if(o.length==1)a=o[0];else{const l=kn(Jv(t),o.length);a=o[l]}return pL(e,(this.tileGrid||this.getTileGridForProjection(n)).getResolution(t[0]),i,n,a,r,this.serverType_)}getTilePixelRatio(t){return!this.hidpi_||this.serverType_===void 0?1:t}getKeyForParams_(){let t=0;const e=[];for(const i in this.params_)e[t++]=i+"-"+this.params_[i];return e.join("/")}updateParams(t){Object.assign(this.params_,t),this.updateV13_(),this.setKey(this.getKeyForParams_())}updateV13_(){const t=this.params_.VERSION||Jp;this.v13_=Jx(t,"1.3")>=0}tileUrlFunction(t,e,i){let n=this.getTileGrid();if(n||(n=this.getTileGridForProjection(i)),n.getResolutions().length<=t[0])return;e!=1&&(!this.hidpi_||this.serverType_===void 0)&&(e=1);const r=n.getResolution(t[0]);let o=n.getTileCoordExtent(t,this.tmpExtent_);const a=this.gutter_;a!==0&&(o=_n(o,r*a,o));const l=Object.assign({},Qp(this.params_,"GetMap"));return this.getRequestUrl_(t,o,e,i,l)}}class yL extends Sn{constructor(t){const e=t.requestEncoding!==void 0?t.requestEncoding:"KVP",i=t.tileGrid;let n=t.urls;n===void 0&&t.url!==void 0&&(n=_0(t.url)),super({attributions:t.attributions,attributionsCollapsible:t.attributionsCollapsible,cacheSize:t.cacheSize,crossOrigin:t.crossOrigin,interpolate:t.interpolate,projection:t.projection,reprojectionErrorThreshold:t.reprojectionErrorThreshold,tileClass:t.tileClass,tileGrid:i,tileLoadFunction:t.tileLoadFunction,tilePixelRatio:t.tilePixelRatio,urls:n,wrapX:t.wrapX!==void 0?t.wrapX:!1,transition:t.transition,zDirection:t.zDirection}),this.version_=t.version!==void 0?t.version:"1.0.0",this.format_=t.format!==void 0?t.format:"image/jpeg",this.dimensions_=t.dimensions!==void 0?t.dimensions:{},this.layer_=t.layer,this.matrixSet_=t.matrixSet,this.style_=t.style,this.requestEncoding_=e,this.setKey(this.getKeyForDimensions_()),n&&n.length>0&&(this.tileUrlFunction=fc(n.map(this.createFromWMTSTemplate.bind(this))))}setUrls(t){this.urls=t;const e=t.join(` -`);this.setTileUrlFunction(fc(t.map(this.createFromWMTSTemplate.bind(this))),e)}getDimensions(){return this.dimensions_}getFormat(){return this.format_}getLayer(){return this.layer_}getMatrixSet(){return this.matrixSet_}getRequestEncoding(){return this.requestEncoding_}getStyle(){return this.style_}getVersion(){return this.version_}getKeyForDimensions_(){const t=this.urls?this.urls.slice(0):[];for(const e in this.dimensions_)t.push(e+"-"+this.dimensions_[e]);return t.join("/")}updateDimensions(t){Object.assign(this.dimensions_,t),this.setKey(this.getKeyForDimensions_())}createFromWMTSTemplate(t){const e=this.requestEncoding_,i={layer:this.layer_,style:this.style_,tilematrixset:this.matrixSet_};e=="KVP"&&Object.assign(i,{Service:"WMTS",Request:"GetTile",Version:this.version_,Format:this.format_}),t=e=="KVP"?oo(t,i):t.replace(/\{(\w+?)\}/g,function(o,a){return a.toLowerCase()in i?i[a.toLowerCase()]:o});const n=this.tileGrid,r=this.dimensions_;return function(o,a,l){if(!o)return;const h={TileMatrix:n.getMatrixId(o[0]),TileCol:o[1],TileRow:o[2]};Object.assign(h,r);let c=t;return e=="KVP"?c=oo(c,h):c=c.replace(/\{(\w+?)\}/g,function(u,d){return h[d]}),c}}}function xL(s,t){const e=s.Contents.Layer,i=e?.find(function(P){return P.Identifier==t.layer});if(!i)return null;const n=s.Contents.TileMatrixSet;let r;i.TileMatrixSetLink.length>1?"projection"in t?r=i.TileMatrixSetLink.findIndex(function(P){const D=n.find(function(b){return b.Identifier==P.TileMatrixSet}).SupportedCRS,x=st(D),E=st(t.projection);return x&&E?qs(x,E):D==t.projection}):r=i.TileMatrixSetLink.findIndex(function(P){return P.TileMatrixSet==t.matrixSet}):r=0,r<0&&(r=0);const o=i.TileMatrixSetLink[r].TileMatrixSet,a=i.TileMatrixSetLink[r].TileMatrixSetLimits;let l=i.Format[0];"format"in t&&(l=t.format),r=i.Style.findIndex(function(P){return"style"in t?P.Title==t.style:P.isDefault}),r<0&&(r=0);const h=i.Style[r].Identifier,c={};"Dimension"in i&&i.Dimension.forEach(function(P,D,x){const E=P.Identifier;let b=P.Default;b===void 0&&(b=P.Value[0]),c[E]=b});const u=s.Contents.TileMatrixSet.find(function(P){return P.Identifier==o});let d;const g=u.SupportedCRS;if(g&&(d=st(g)),"projection"in t){const P=st(t.projection);P&&(!d||qs(P,d))&&(d=P)}let f=!1;const p=d.getAxisOrientation().startsWith("ne");let m=u.TileMatrix[0],_={MinTileCol:0,MinTileRow:0,MaxTileCol:m.MatrixWidth-1,MaxTileRow:m.MatrixHeight-1};if(a){_=a[a.length-1];const P=u.TileMatrix.find(D=>D.Identifier===_.TileMatrix||u.Identifier+":"+D.Identifier===_.TileMatrix);P&&(m=P)}const y=m.ScaleDenominator*28e-5/d.getMetersPerUnit(),v=p?[m.TopLeftCorner[1],m.TopLeftCorner[0]]:m.TopLeftCorner,S=m.TileWidth*y,w=m.TileHeight*y;let T=u.BoundingBox;T&&p&&(T=[T[1],T[0],T[3],T[2]]);let M=[v[0]+S*_.MinTileCol,v[1]-w*(1+_.MaxTileRow),v[0]+S*(1+_.MaxTileCol),v[1]-w*_.MinTileRow];if(T!==void 0&&!ai(T,M)){const P=i.WGS84BoundingBox,D=st("EPSG:4326").getExtent();if(M=T,P)f=P[0]===D[0]&&P[2]===D[2];else{const x=ev(T,u.SupportedCRS,"EPSG:4326");f=x[0]-1e-10<=D[0]&&x[2]+1e-10>=D[2]}}const C=VJ(u,M,a),I=[];let O=t.requestEncoding;if(O=O!==void 0?O:"","OperationsMetadata"in s&&"GetTile"in s.OperationsMetadata){const P=s.OperationsMetadata.GetTile.DCP.HTTP.Get;for(let D=0,x=P.length;D_)return 1;if(_>m)return-1}var y=g[g.length-1],v=f[f.length-1];if(y&&v){var S=y.split(".").map(r),w=v.split(".").map(r);for(p=0;pw[p])return 1;if(w[p]>S[p])return-1}}else if(y||v)return y?-1:1;return 0}var l=[">",">=","=","<","<="],h={">":[1],">=":[0,1],"=":[0],"<=":[-1,0],"<":[-1]};function c(u){if(typeof u!="string")throw new TypeError("Invalid operator type, expected string but got "+typeof u);if(l.indexOf(u)===-1)throw new TypeError("Invalid operator, expected one of "+l.join("|"))}return a.validate=function(u){return typeof u=="string"&&e.test(u)},a.compare=function(u,d,g){c(g);var f=a(u,d);return h[g].indexOf(f)>-1},a})})(vL);var set=vL.exports,_y=set;const Pw="1.0.0",St={classification:"https://stac-extensions.github.io/classification/v1.1.0/schema.json",datacube:"https://stac-extensions.github.io/datacube/v2.1.0/schema.json",eo:"https://stac-extensions.github.io/eo/v1.0.0/schema.json",file:"https://stac-extensions.github.io/file/v1.0.0/schema.json","item-assets":"https://stac-extensions.github.io/item-assets/v1.0.0/schema.json",label:"https://stac-extensions.github.io/label/v1.0.1/schema.json",pointcloud:"https://stac-extensions.github.io/pointcloud/v1.0.0/schema.json",processing:"https://stac-extensions.github.io/processing/v1.1.0/schema.json",projection:"https://stac-extensions.github.io/projection/v1.0.0/schema.json",raster:"https://stac-extensions.github.io/raster/v1.1.0/schema.json",sar:"https://stac-extensions.github.io/sar/v1.0.0/schema.json",sat:"https://stac-extensions.github.io/sat/v1.0.0/schema.json",scientific:"https://stac-extensions.github.io/scientific/v1.0.0/schema.json",table:"https://stac-extensions.github.io/table/v1.2.0/schema.json",timestamps:"https://stac-extensions.github.io/timestamps/v1.0.0/schema.json",version:"https://stac-extensions.github.io/version/v1.0.0/schema.json",view:"https://stac-extensions.github.io/view/v1.0.0/schema.json"},Za={itemAndCollection:{"cube:":St.datacube,"eo:":St.eo,"file:":St.file,"label:":St.label,"pc:":St.pointcloud,"processing:":St.processing,"proj:":St.projection,"raster:":St.raster,"sar:":St.sar,"sat:":St.sat,"sci:":St.scientific,"view:":St.view,version:St.version,deprecated:St.version,published:St.timestamps,expires:St.timestamps,unpublished:St.timestamps},catalog:{},collection:{item_assets:St["item-assets"]},item:{}};Za.collection=Object.assign(Za.collection,Za.itemAndCollection);Za.item=Object.assign(Za.item,Za.itemAndCollection);var bu={parseUrl(s){let t=s.match(/^https?:\/\/stac-extensions.github.io\/([^\/]+)\/v([^\/]+)\/[^.]+.json$/i);if(t)return{id:t[1],version:t[2]}}},se={version:Pw,extensions:{},set(s){if(typeof s.stac_version!="string"?se.version="0.6.0":se.version=s.stac_version,Array.isArray(s.stac_extensions))for(let t of s.stac_extensions){let e=bu.parseUrl(t);e&&(se.extensions[e.id]=e.version)}},before(s,t=null){let e=t?se.extensions[t]:se.version;return typeof e>"u"?!1:_y.compare(e,s,"<")}},j={type(s){let t=typeof s;if(t==="object"){if(s===null)return"null";if(Array.isArray(s))return"array"}return t},is(s,t){return j.type(s)===t},isDefined(s){return typeof s<"u"},isObject(s){return typeof s=="object"&&s===Object(s)&&!Array.isArray(s)},rename(s,t,e){return typeof s[t]<"u"&&typeof s[e]>"u"?(s[e]=s[t],delete s[t],!0):!1},forAll(s,t,e){if(s[t]&&typeof s[t]=="object")for(let i in s[t])e(s[t][i])},toArray(s,t){return typeof s[t]<"u"&&!Array.isArray(s[t])?(s[t]=[s[t]],!0):!1},flattenArray(s,t,e,i=!1){if(Array.isArray(s[t])){for(let n in s[t])if(typeof e[n]=="string"){let r=s[t][n];s[e[n]]=i?[r]:r}return delete s[t],!0}return!1},flattenOneElementArray(s,t,e=!1){return!e&&Array.isArray(s[t])?s[t].length===1?(s[t]=s[t][0],!0):!1:!0},removeFromArray(s,t,e){if(Array.isArray(s[t])){let i=s[t].indexOf(e);return i>-1&&s[t].splice(i,1),!0}return!1},ensure(s,t,e){return j.type(e)!==j.type(s[t])&&(s[t]=e),!0},upgradeExtension(s,t){let{id:e,version:i}=bu.parseUrl(t),n=s.stac_extensions.findIndex(r=>{let o=bu.parseUrl(r);return o&&o.id===e&&_y.compare(o.version,i,"<")});return n!==-1?(s.stac_extensions[n]=t,!0):!1},addExtension(s,t){let{id:e,version:i}=bu.parseUrl(t),n=s.stac_extensions.findIndex(r=>{if(r===t)return!0;let o=bu.parseUrl(r);return!!(o&&o.id===e&&_y.compare(o.version,i,"<"))});return n===-1?s.stac_extensions.push(t):s.stac_extensions[n]=t,s.stac_extensions.sort(),!0},removeExtension(s,t){return j.removeFromArray(s,"stac_extensions",t)},migrateExtensionShortnames(s){let t=Object.keys(St),e=Object.values(St);return j.mapValues(s,"stac_extensions",t,e)},populateExtensions(s,t){let e=[];(t=="catalog"||t=="collection")&&e.push(s),(t=="item"||t=="collection")&&j.isObject(s.assets)&&(e=e.concat(Object.values(s.assets))),t=="collection"&&j.isObject(s.item_assets)&&(e=e.concat(Object.values(s.item_assets))),t=="collection"&&j.isObject(s.summaries)&&e.push(s.summaries),t=="item"&&j.isObject(s.properties)&&e.push(s.properties);for(let i of e)Object.keys(i).forEach(n=>{let r=n.match(/^(\w+:|[^:]+$)/i);if(Array.isArray(r)){let o=Za[t][r[0]];j.is(o,"string")&&j.addExtension(s,o)}})},mapValues(s,t,e,i){let n=r=>{let o=e.indexOf(r);return o>=0?i[o]:r};return Array.isArray(s[t])?s[t]=s[t].map(n):typeof s[t]<"u"&&(s[t]=n(s[t])),!0},mapObject(s,t){for(let e in s)s[e]=t(s[e],e)},moveTo(s,t,e,i=!1,n=!1){let r;return i?n?r=o=>Array.isArray(o):r=o=>Array.isArray(o)&&o.length===1:r=j.isDefined,r(s[t])?(e[t]=i&&!n?s[t][0]:s[t],delete s[t],!0):!1},runAll(s,t,e,i){for(let n in s)n.startsWith("migrate")||s[n](t,e,i)},toUTC(s,t){if(typeof s[t]=="string")try{return s[t]=this.toISOString(s[t]),!0}catch{}return delete s[t],!1},toISOString(s){return s instanceof Date||(s=new Date(s)),s.toISOString().replace(".000","")}},rr={multihash:null,hexToUint8(s){if(s.length===0||s.length%2!==0)throw new Error(`The string "${s}" is not valid hex.`);return new Uint8Array(s.match(/.{1,2}/g).map(t=>parseInt(t,16)))},uint8ToHex(s){return s.reduce((t,e)=>t+e.toString(16).padStart(2,"0"),"")},toMultihash(s,t,e){if(!rr.multihash||!j.is(s[t],"string"))return!1;try{const i=rr.multihash.encode(rr.hexToUint8(s[t]),e);return s[t]=rr.uint8ToHex(i),!0}catch(i){return console.warn(i),!1}}},Aw={migrate(s,t=!0){return se.set(s),t&&(s.stac_version=Pw),s.type="Catalog",j.ensure(s,"stac_extensions",[]),se.before("1.0.0-rc.1")&&j.migrateExtensionShortnames(s),j.ensure(s,"id",""),j.ensure(s,"description",""),j.ensure(s,"links",[]),j.runAll(Aw,s,s),se.before("0.8.0")&&j.populateExtensions(s,"catalog"),s}},Lw={migrate(s,t=!0){return Aw.migrate(s,t),s.type="Collection",se.before("1.0.0-rc.1")&&j.migrateExtensionShortnames(s),j.ensure(s,"license","proprietary"),j.ensure(s,"extent",{spatial:{bbox:[]},temporal:{interval:[]}}),j.runAll(Lw,s,s),j.isObject(s.properties)&&(j.removeFromArray(s,"stac_extensions","commons"),delete s.properties),se.before("0.8.0")&&j.populateExtensions(s,"collection"),se.before("1.0.0-beta.1")&&j.mapValues(s,"stac_extensions",["assets"],["item-assets"]),s},extent(s){if(j.ensure(s,"extent",{}),se.before("0.8.0")&&(Array.isArray(s.extent.spatial)&&(s.extent.spatial={bbox:[s.extent.spatial]}),Array.isArray(s.extent.temporal)&&(s.extent.temporal={interval:[s.extent.temporal]})),j.ensure(s.extent,"spatial",{}),j.ensure(s.extent.spatial,"bbox",[]),j.ensure(s.extent,"temporal",{}),j.ensure(s.extent.temporal,"interval",[]),se.before("1.0.0-rc.3")){if(s.extent.temporal.interval.length>1){let t,e;for(let i of s.extent.temporal.interval){if(i[0]===null)t=null;else if(typeof i[0]=="string"&&t!==null)try{let n=new Date(i[0]);(typeof t>"u"||n"u"||n>e)&&(e=n)}catch{}}s.extent.temporal.interval.unshift([t?j.toISOString(t):null,e?j.toISOString(e):null])}if(s.extent.spatial.bbox.length>1){let t=s.extent.spatial.bbox.reduce((e,i)=>Array.isArray(i)?Math.max(i.length,e):e,4);if(t>=4){let e=new Array(t).fill(null),i=t/2;for(let n of s.extent.spatial.bbox){if(!Array.isArray(n)||n.length<4)break;for(let r in n){let o=n[r];e[r]===null?e[r]=o:rn===null)===-1&&s.extent.spatial.bbox.unshift(e)}}}},collectionAssets(s){se.before("1.0.0-rc.1")&&j.removeExtension(s,"collection-assets"),jd.migrateAll(s)},itemAsset(s){se.before("1.0.0-beta.2")&&j.rename(s,"item_assets","assets"),jd.migrateAll(s,"item_assets")},summaries(s){if(j.ensure(s,"summaries",{}),se.before("0.8.0")&&j.isObject(s.other_properties)){for(let t in s.other_properties){let e=s.other_properties[t];Array.isArray(e.extent)&&e.extent.length===2?s.summaries[t]={minimum:e.extent[0],maximum:e.extent[1]}:Array.isArray(e.values)&&(e.values.filter(i=>Array.isArray(i)).length===e.values.length?s.summaries[t]=e.values.reduce((i,n)=>i.concat(n),[]):s.summaries[t]=e.values)}delete s.other_properties}if(se.before("1.0.0-beta.1")&&j.isObject(s.properties)&&!s.links.find(t=>["child","item"].includes(t.rel)))for(let t in s.properties){let e=s.properties[t];Array.isArray(e)||(e=[e]),s.summaries[t]=e}se.before("1.0.0-rc.1")&&j.mapObject(s.summaries,t=>(j.rename(t,"min","minimum"),j.rename(t,"max","maximum"),t)),x0.migrate(s.summaries,s,!0),j.moveTo(s.summaries,"sci:doi",s,!0)&&j.addExtension(s,St.scientific),j.moveTo(s.summaries,"sci:publications",s,!0,!0)&&j.addExtension(s,St.scientific),j.moveTo(s.summaries,"sci:citation",s,!0)&&j.addExtension(s,St.scientific),j.moveTo(s.summaries,"cube:dimensions",s,!0)&&j.addExtension(s,St.datacube),Object.keys(s.summaries).length===0&&delete s.summaries}},Ow={migrate(s,t=null,e=!0){se.set(s),e&&(s.stac_version=Pw),j.ensure(s,"stac_extensions",[]),se.before("1.0.0-rc.1")&&j.migrateExtensionShortnames(s),j.ensure(s,"id",""),j.ensure(s,"type","Feature"),j.isObject(s.geometry)||(s.geometry=null),s.geometry!==null&&j.ensure(s,"bbox",[]),j.ensure(s,"properties",{}),j.ensure(s,"links",[]),j.ensure(s,"assets",{});let i=!1;return j.isObject(t)&&j.isObject(t.properties)&&(j.removeFromArray(s,"stac_extensions","commons"),s.properties=Object.assign({},t.properties,s.properties),i=!0),j.runAll(Ow,s,s),x0.migrate(s.properties,s),jd.migrateAll(s),(se.before("0.8.0")||i)&&j.populateExtensions(s,"item"),s}},wL={migrate(s,t=!0){return j.ensure(s,"collections",[]),j.ensure(s,"links",[]),j.runAll(wL,s,s),s.collections=s.collections.map(e=>Lw.migrate(e,t)),s}},EL={migrate(s,t=!0){return j.ensure(s,"type","FeatureCollection"),j.ensure(s,"features",[]),j.ensure(s,"links",[]),j.runAll(EL,s,s),s.features=s.features.map(e=>Ow.migrate(e,null,t)),s}},jd={migrateAll(s,t="assets"){for(let e in s[t])jd.migrate(s[t][e],s)},migrate(s,t){return j.runAll(jd,s,t),x0.migrate(s,t),s},mediaTypes(s){j.is(s.type,"string")&&j.mapValues(s,"type",["image/vnd.stac.geotiff","image/vnd.stac.geotiff; cloud-optimized=true"],["image/tiff; application=geotiff","image/tiff; application=geotiff; profile=cloud-optimized"])},eo(s,t){let e=j.isObject(t.properties)&&Array.isArray(t.properties["eo:bands"])?t.properties["eo:bands"]:[];if(Array.isArray(s["eo:bands"]))for(let i in s["eo:bands"]){let n=s["eo:bands"][i];j.is(n,"number")&&j.isObject(e[n])?n=e[n]:j.isObject(n)||(n={}),s["eo:bands"][i]=n}}},x0={migrate(s,t,e=!1){return j.runAll(x0,s,t,e),s},_commonMetadata(s){se.before("1.0.0-rc.3")&&(j.toUTC(s,"created"),j.toUTC(s,"updated"))},_timestamps(s,t){j.toUTC(s,"published"),j.toUTC(s,"expires"),j.toUTC(s,"unpublished"),j.upgradeExtension(t,St.timestamps)},_versioningIndicator(s,t){j.upgradeExtension(t,St.version)},checksum(s,t){se.before("0.9.0")&&rr.multihash&&(j.rename(s,"checksum:md5","checksum:multihash")&&rr.toMultihash(s,"checksum:multihash","md5"),j.rename(s,"checksum:sha1","checksum:multihash")&&rr.toMultihash(s,"checksum:multihash","sha1"),j.rename(s,"checksum:sha2","checksum:multihash")&&rr.toMultihash(s,"checksum:multihash","sha2-256"),j.rename(s,"checksum:sha3","checksum:multihash")&&rr.toMultihash(s,"checksum:multihash","sha3-256")),se.before("1.0.0-rc.1")&&j.rename(s,"checksum:multihash","file:checksum")&&j.addExtension(t,St.file),j.removeExtension(t,"checksum")},classification(s,t){se.before("1.1.0","classification")&&j.forAll(s,"classification:classes",e=>j.rename(e,"color-hint","color_hint")),j.upgradeExtension(t,St.classification)},cube(s,t){j.upgradeExtension(t,St.datacube)},dtr(s,t){se.before("0.9.0")&&(j.rename(s,"dtr:start_datetime","start_datetime"),j.rename(s,"dtr:end_datetime","end_datetime"),j.removeExtension(t,"datetime-range"))},eo(s,t){se.before("0.9.0")&&(j.rename(s,"eo:epsg","proj:epsg")&&j.addExtension(t,St.projection),j.rename(s,"eo:platform","platform"),j.rename(s,"eo:instrument","instruments")&&j.toArray(s,"instruments"),j.rename(s,"eo:constellation","constellation"),j.rename(s,"eo:off_nadir","view:off_nadir")&&j.addExtension(t,St.view),j.rename(s,"eo:azimuth","view:azimuth")&&j.addExtension(t,St.view),j.rename(s,"eo:incidence_angle","view:incidence_angle")&&j.addExtension(t,St.view),j.rename(s,"eo:sun_azimuth","view:sun_azimuth")&&j.addExtension(t,St.view),j.rename(s,"eo:sun_elevation","view:sun_elevation")&&j.addExtension(t,St.view)),se.before("1.0.0-beta.1")&&j.rename(s,"eo:gsd","gsd"),j.upgradeExtension(t,St.eo)},file(s,t){j.upgradeExtension(t,St.file)},label(s,t){se.before("0.8.0")&&(j.rename(s,"label:property","label:properties"),j.rename(s,"label:task","label:tasks"),j.rename(s,"label:overview","label:overviews")&&j.toArray(s,"label:overviews"),j.rename(s,"label:method","label:methods"),j.toArray(s,"label:classes")),j.upgradeExtension(t,St.label)},pc(s,t){se.before("0.8.0")&&j.rename(s,"pc:schema","pc:schemas"),j.upgradeExtension(t,St.pointcloud)},processing(s,t){j.upgradeExtension(t,St.processing)},proj(s,t){j.upgradeExtension(t,St.projection)},raster(s,t){j.upgradeExtension(t,St.raster)},sar(s,t,e){j.rename(s,"sar:incidence_angle","view:incidence_angle")&&j.addExtension(t,St.view),j.rename(s,"sar:pass_direction","sat:orbit_state")&&j.mapValues(s,"sat:orbit_state",[null],["geostationary"])&&j.addExtension(t,St.sat),se.before("0.7.0")&&(j.flattenArray(s,"sar:resolution",["sar:resolution_range","sar:resolution_azimuth"],e),j.flattenArray(s,"sar:pixel_spacing",["sar:pixel_spacing_range","sar:pixel_spacing_azimuth"],e),j.flattenArray(s,"sar:looks",["sar:looks_range","sar:looks_azimuth","sar:looks_equivalent_number"],e),j.rename(s,"sar:off_nadir","view:off_nadir")&&j.addExtension(t,St.view)),se.before("0.9.0")&&(j.rename(s,"sar:platform","platform"),j.rename(s,"sar:instrument","instruments")&&j.toArray(s,"instruments"),j.rename(s,"sar:constellation","constellation"),j.rename(s,"sar:type","sar:product_type"),j.rename(s,"sar:polarization","sar:polarizations"),j.flattenOneElementArray(s,"sar:absolute_orbit",e)&&j.rename(s,"sar:absolute_orbit","sat:absolute_orbit")&&j.addExtension(t,St.sat),j.flattenOneElementArray(s,"sar:relative_orbit",e)&&j.rename(s,"sar:relative_orbit","sat:relative_orbit")&&j.addExtension(t,St.sat)),j.upgradeExtension(t,St.sar)},sat(s,t){se.before("0.9.0")&&(j.rename(s,"sat:off_nadir_angle","sat:off_nadir"),j.rename(s,"sat:azimuth_angle","sat:azimuth"),j.rename(s,"sat:sun_azimuth_angle","sat:sun_azimuth"),j.rename(s,"sat:sun_elevation_angle","sat:sun_elevation")),j.upgradeExtension(t,St.sat)},sci(s,t){j.upgradeExtension(t,St.scientific)},item(s){se.before("0.8.0")&&(j.rename(s,"item:license","license"),j.rename(s,"item:providers","providers"))},table(s,t){j.upgradeExtension(t,St.table)},view(s,t){j.upgradeExtension(t,St.view)}},eh={item(s,t=null,e=!0){return Ow.migrate(s,t,e)},catalog(s,t=!0){return Aw.migrate(s,t)},collection(s,t=!0){return Lw.migrate(s,t)},collectionCollection(s,t=!0){return wL.migrate(s,t)},itemCollection(s,t=!0){return EL.migrate(s,t)},stac(s,t=!0){return s.type==="Feature"?eh.item(s,null,t):s.type==="FeatureCollection"?eh.itemCollection(s,t):s.type==="Collection"||!s.type&&j.isDefined(s.extent)&&j.isDefined(s.license)?eh.collection(s,t):!s.type&&Array.isArray(s.collections)?eh.collectionCollection(s,t):eh.catalog(s,t)},enableMultihash(s){rr.multihash=s}},iet=eh;const net=g0(iet);function Dc(s){let t=s.length>=6,e=s[0],i=s[t?3:2],n=s[1],r=s[t?4:3],o={west:e,east:i,south:n,north:r};return t&&(o.base=s[2],o.height=s[5]),o}function J_(s){let{west:t,east:e,south:i,north:n}=Dc(s);return[[[t,n],[t,i],[e,i],[e,n],[t,n]]]}function ret(s){if(!$n(s))return null;let t=Dc(s),e=[];if(ML(s)){let i=(t.west+360+t.east)/2;i>180&&(i-=360),e.push(i)}else e.push((t.west+t.east)/2);return e.push((t.south+t.north)/2),typeof t.base<"u"&&e.push((t.base+t.height)/2),e}function SL(s){if($n(s)?s=[s]:Array.isArray(s)&&(s=s.filter(i=>$n(i))),!Array.isArray(s)||s.length===0)return null;let t=s.reduce((i,n)=>{if(ML(n)){let{west:r,east:o,south:a,north:l}=Dc(n);i.push(J_([-180,a,o,l])),i.push(J_([r,a,180,l]))}else i.push(J_(n));return i},[]),e=null;if(t.length===1?e={type:"Polygon",coordinates:t[0]}:t.length>1&&(e={type:"MultiPolygon",coordinates:t}),e)return{type:"Feature",geometry:e,properties:{}}}function $n(s){if(!Array.isArray(s)||![4,6].includes(s.length)||s.some(r=>typeof r!="number"))return!1;let{west:t,east:e,south:i,north:n}=Dc(s);return i<=n&&t>=-180&&t<=180&&i>=-90&&e<=180&&e>=-180&&n<=90}function ML(s){if(!$n(s))return!1;let{west:t,east:e}=Dc(s);return t>e}function bL(s){if(!Array.isArray(s)||s.length===0)return null;let t={west:180,south:90,east:-180,north:-90};s.forEach(i=>{if(!$n(i))return;let n=Dc(i),r=["west","south"];for(let o in n){let a=r.includes(o)?Math.min:Math.max;t[o]=a(t[o],n[o])}});let e=[t.west,t.south,t.east,t.north];return $n(e)?e:null}function Ri(s){return typeof s=="string"&&s.length>0}function xi(s){return typeof s=="object"&&s===Object(s)&&!Array.isArray(s)}function TL(...s){if(s=s.filter(t=>Array.isArray(t)),s.length>1){let t=Math.max(...s.map(i=>i.length)),e=[];for(let i=0;in[i])));return e}else if(s.length===1)return s[0];return[]}function oet(s){switch(s){case"int8":return-128;case"int16":return-32768;case"int32":return-2147483648}return s.startsWith("u")?0:null}function aet(s){switch(s){case"int8":return 127;case"uint8":return 255;case"int16":return 32767;case"uint16":return 65535;case"int32":return 2147483647;case"uint32":return 4294967295}return null}class v0{constructor(t,e={},i=[]){if(!xi(t))throw new Error("Given data is not an object");if(t instanceof v0){for(let n of i)this[n]=t[n];t=t.toJSON()}this._keyMap=e,this._privateKeys=["_keyMap","_privateKeys"].concat(i);for(let n in t)typeof this[n]>"u"&&(n in e?this[n]=e[n](t[n],this):this[n]=t[n])}isItem(){return this.type==="Feature"}isCatalog(){return this.type==="Catalog"}isCatalogLike(){return this.isCatalog()||this.isCollection()}isCollection(){return this.type==="Collection"}isItemCollection(){return this.type==="FeatureCollection"}isCollectionCollection(){return!1}isAsset(){return!1}isLink(){return!1}getObjectType(){}getAbsoluteUrl(){return null}getMetadata(t){return this[t]}toGeoJSON(){return null}getBoundingBox(){return null}getCenter(){return ret(this.getBoundingBox())}getBoundingBoxes(){return[]}toJSON(){let t={};return Object.keys(this).forEach(e=>{if(typeof this[e]=="function"||this._privateKeys.includes(e))return;let i=this[e];if(e in this._keyMap){let n=Array.isArray(i)?[]:{};for(let r in i)n[r]=i[r].toJSON();i=n}t[e]=i}),t}}var CL={exports:{}},zf={exports:{}};/*! https://mths.be/punycode v1.4.0 by @mathias */zf.exports;var KM;function het(){return KM||(KM=1,function(s,t){(function(e){var i=t&&!t.nodeType&&t,n=s&&!s.nodeType&&s,r=typeof qa=="object"&&qa;(r.global===r||r.window===r||r.self===r)&&(e=r);var o,a=2147483647,l=36,h=1,c=26,u=38,d=700,g=72,f=128,p="-",m=/^xn--/,_=/[^\x20-\x7E]/,y=/[\x2E\u3002\uFF0E\uFF61]/g,v={overflow:"Overflow: input needs wider integers to process","not-basic":"Illegal input >= 0x80 (not a basic code point)","invalid-input":"Invalid input"},S=l-h,w=Math.floor,T=String.fromCharCode,M;function C(k){throw new RangeError(v[k])}function I(k,z){for(var V=k.length,et=[];V--;)et[V]=z(k[V]);return et}function O(k,z){var V=k.split("@"),et="";V.length>1&&(et=V[0]+"@",k=V[1]),k=k.replace(y,".");var F=k.split("."),ot=I(F,z).join(".");return et+ot}function P(k){for(var z=[],V=0,et=k.length,F,ot;V=55296&&F<=56319&&V65535&&(z-=65536,V+=T(z>>>10&1023|55296),z=56320|z&1023),V+=T(z),V}).join("")}function x(k){return k-48<10?k-22:k-65<26?k-65:k-97<26?k-97:l}function E(k,z){return k+22+75*(k<26)-((z!=0)<<5)}function b(k,z,V){var et=0;for(k=V?w(k/d):k>>1,k+=w(k/z);k>S*c>>1;et+=l)k=w(k/S);return w(et+(S+1)*k/(k+u))}function R(k){var z=[],V=k.length,et,F=0,ot=f,ht=g,pt,Gt,Kt,bt,oe,Pe,hs,rs,Ge;for(pt=k.lastIndexOf(p),pt<0&&(pt=0),Gt=0;Gt=128&&C("not-basic"),z.push(k.charCodeAt(Gt));for(Kt=pt>0?pt+1:0;Kt=V&&C("invalid-input"),hs=x(k.charCodeAt(Kt++)),(hs>=l||hs>w((a-F)/oe))&&C("overflow"),F+=hs*oe,rs=Pe<=ht?h:Pe>=ht+c?c:Pe-ht,!(hsw(a/Ge)&&C("overflow"),oe*=Ge;et=z.length+1,ht=b(F-bt,et,bt==0),w(F/et)>a-ot&&C("overflow"),ot+=w(F/et),F%=et,z.splice(F++,0,ot)}return D(z)}function A(k){var z,V,et,F,ot,ht,pt,Gt,Kt,bt,oe,Pe=[],hs,rs,Ge,ve;for(k=P(k),hs=k.length,z=f,V=0,ot=g,ht=0;ht=z&&oew((a-V)/rs)&&C("overflow"),V+=(pt-z)*rs,z=pt,ht=0;hta&&C("overflow"),oe==z){for(Gt=V,Kt=l;bt=Kt<=ot?h:Kt>=ot+c?c:Kt-ot,!(Gtl.length>0).map(l=>l.split("=")).forEach(([l,h])=>{this.ghostValues[l]=h})}return this.ghostValues}static async fromSource(t,e,i){const n=(await t.fetch([{offset:0,length:1024}],i))[0],r=new HQ(n),o=r.getUint16(0,0);let a;if(o===18761)a=!0;else if(o===19789)a=!1;else throw new TypeError("Invalid byte order value.");const l=r.getUint16(2,a);let h;if(l===42)h=!1;else if(l===43){if(h=!0,r.getUint16(4,a)!==8)throw new Error("Unsupported offset byte-size.")}else throw new TypeError("Invalid magic number.");const c=h?r.getUint64(8,a):r.getUint32(4,a);return new gc(t,a,h,c,e)}close(){return typeof this.source.close=="function"?this.source.close():!1}}class Stt extends aL{constructor(t,e){super(),this.mainFile=t,this.overviewFiles=e,this.imageFiles=[t].concat(e),this.fileDirectoriesPerFile=null,this.fileDirectoriesPerFileParsing=null,this.imageCount=null}async parseFileDirectoriesPerFile(){const t=[this.mainFile.parseFileDirectoryAt(this.mainFile.firstIFDOffset)].concat(this.overviewFiles.map(e=>e.parseFileDirectoryAt(e.firstIFDOffset)));return this.fileDirectoriesPerFile=await Promise.all(t),this.fileDirectoriesPerFile}async getImage(t=0){await this.getImageCount(),await this.parseFileDirectoriesPerFile();let e=0,i=0;for(let n=0;ne.getImageCount()));return this.imageCounts=await Promise.all(t),this.imageCount=this.imageCounts.reduce((e,i)=>e+i,0),this.imageCount}}async function Mtt(s,t={},e){return gc.fromSource(py(s,t),e)}async function btt(s,t){return gc.fromSource(vtt(s),t)}async function Ctt(s,t=[],e={},i){const n=await gc.fromSource(py(s,e),i),r=await Promise.all(t.map(o=>gc.fromSource(py(o,e))));return new Stt(n,r)}function Ttt(s){return((s.fileDirectory.NewSubfileType||0)&4)===4}function Rtt(s,t){if(!s)return!1;if(s===!0)return!0;if(t.getSamplesPerPixel()!==3)return!1;const e=t.fileDirectory.PhotometricInterpretation,i=gi;return e===i.CMYK||e===i.YCbCr||e===i.CIELab||e===i.ICCLab}const YM="STATISTICS_MAXIMUM",qM="STATISTICS_MINIMUM",Z_=256;let H_;function Itt(){return H_||(H_=new QQ),H_}function Ptt(s){try{return s.getBoundingBox()}catch{return[0,0,s.getWidth(),s.getHeight()]}}function Att(s){try{return s.getOrigin().slice(0,2)}catch{return[0,s.getHeight()]}}function Ltt(s,t){try{return s.getResolution(t)}catch{return[t.getWidth()/s.getWidth(),t.getHeight()/s.getHeight()]}}function Ott(s){const t=s.geoKeys;if(!t)return null;if(t.ProjectedCSTypeGeoKey&&t.ProjectedCSTypeGeoKey!==32767){const e="EPSG:"+t.ProjectedCSTypeGeoKey;let i=st(e);if(!i){const n=e2(t.ProjLinearUnitsGeoKey);n&&(i=new rc({code:e,units:n}))}return i}if(t.GeographicTypeGeoKey&&t.GeographicTypeGeoKey!==32767){const e="EPSG:"+t.GeographicTypeGeoKey;let i=st(e);if(!i){const n=e2(t.GeogAngularUnitsGeoKey);n&&(i=new rc({code:e,units:n}))}return i}return null}function Ftt(s){return s.getImageCount().then(function(t){const e=new Array(t);for(let i=0;ie*s)throw new Error(i)}function Dtt(s){return s instanceof Int8Array?-128:s instanceof Int16Array?-32768:s instanceof Int32Array?-2147483648:s instanceof Float32Array?12e-39:0}function ktt(s){return s instanceof Int8Array?127:s instanceof Uint8Array||s instanceof Uint8ClampedArray?255:s instanceof Int16Array?32767:s instanceof Uint16Array?65535:s instanceof Int32Array?2147483647:s instanceof Uint32Array?4294967295:s instanceof Float32Array?34e37:255}class bw extends d0{constructor(t){super({state:"loading",tileGrid:null,projection:t.projection||null,transition:t.transition,interpolate:t.interpolate!==!1,wrapX:t.wrapX}),this.sourceInfo_=t.sources;const e=this.sourceInfo_.length;this.sourceOptions_=t.sourceOptions,this.sourceImagery_=new Array(e),this.sourceMasks_=new Array(e),this.resolutionFactors_=new Array(e),this.samplesPerPixel_,this.nodataValues_,this.metadata_,this.normalize_=t.normalize!==!1,this.addAlpha_=!1,this.error_=null,this.convertToRGB_=t.convertToRGB||!1,this.setKey(this.sourceInfo_.map(r=>r.url).join(","));const i=this,n=new Array(e);for(let r=0;r=0;--i){const n=e[i],r=Ott(n);if(r){this.projection=r;break}}}configure_(t){let e,i,n,r,o;const a=new Array(t.length),l=new Array(t.length),h=new Array(t.length);let c=0;const u=t.length;for(let p=0;p{Ttt(T)?_.push(T):m.push(T)});const y=m.length;if(_.length>0&&_.length!==y)throw new Error(`Expected one mask per image found ${_.length} masks and ${y} images`);let v,S;const w=new Array(y),C=new Array(y),M=new Array(y);l[p]=new Array(y),h[p]=new Array(y);for(let T=0;TM.length&&(c=o.length-M.length);const T=o[o.length-1]/M[M.length-1];this.resolutionFactors_[p]=T;const I=M.map(P=>P*=T),O=`Resolution mismatch for source ${p}, got [${I}] but expected [${o}]`;Mu(o.slice(c,o.length),I,.02,O,this.viewRejector)}n?Mu(n.slice(c,n.length),C,.01,`Tile size mismatch for source ${p}`,this.viewRejector):n=C,r?Mu(r.slice(c,r.length),w,0,`Tile size mismatch for source ${p}`,this.viewRejector):r=w,this.sourceImagery_[p]=m.reverse(),this.sourceMasks_[p]=_.reverse()}for(let p=0,m=this.sourceImagery_.length;p{const i=this.sourceImage_.getState();(i==it.LOADED||i==it.ERROR)&&(this.unlistenSource_(),this.reproject_())}),this.sourceImage_.load())}}unlistenSource_(){ms(this.sourceListenerKey_),this.sourceListenerKey_=null}}const cr=4,K_={IMAGELOADSTART:"imageloadstart",IMAGELOADEND:"imageloadend",IMAGELOADERROR:"imageloaderror"};class Gtt extends Sr{constructor(t,e){super(t),this.image=e}}class jtt extends Lc{constructor(t){super({attributions:t.attributions,projection:t.projection,state:t.state,interpolate:t.interpolate!==void 0?t.interpolate:!0}),this.on,this.once,this.un,this.loader=t.loader||null,this.resolutions_=t.resolutions!==void 0?t.resolutions:null,this.reprojectedImage_=null,this.reprojectedRevision_=0,this.image=null,this.wantedExtent_,this.wantedResolution_,this.static_=t.loader?t.loader.length===0:!1,this.wantedProjection_=null}getResolutions(){return this.resolutions_}setResolutions(t){this.resolutions_=t}findNearestResolution(t){const e=this.getResolutions();if(e){const i=Om(e,t,0);t=e[i]}return t}getImage(t,e,i,n){const r=this.getProjection();if(!r||!n||qs(r,n))return r&&(n=r),this.getImageInternal(t,e,i,n);if(this.reprojectedImage_){if(this.reprojectedRevision_==this.getRevision()&&qs(this.reprojectedImage_.getProjection(),n)&&this.reprojectedImage_.getResolution()==e&&so(this.reprojectedImage_.getExtent(),t))return this.reprojectedImage_;this.reprojectedImage_.dispose(),this.reprojectedImage_=null}return this.reprojectedImage_=new $tt(r,n,t,e,i,(o,a,l)=>this.getImageInternal(o,a,l,r),this.getInterpolate()),this.reprojectedRevision_=this.getRevision(),this.reprojectedImage_}getImageInternal(t,e,i,n){if(this.loader){const r=m0(t,e,i,1),o=this.findNearestResolution(e);if(this.image&&(this.static_||this.wantedProjection_===n&&(this.wantedExtent_&&ai(this.wantedExtent_,r)||ai(this.image.getExtent(),r))&&(this.wantedResolution_&&qp(this.wantedResolution_)===o||qp(this.image.getResolution())===o)))return this.image;this.wantedProjection_=n,this.wantedExtent_=r,this.wantedResolution_=o,this.image=new Wm(r,o,i,this.loader),this.image.addEventListener(Zt.CHANGE,this.handleImageChange.bind(this))}return this.image}handleImageChange(t){const e=t.target;let i;switch(e.getState()){case it.LOADING:this.loading=!0,i=K_.IMAGELOADSTART;break;case it.LOADED:this.loading=!1,i=K_.IMAGELOADEND;break;case it.ERROR:this.loading=!1,i=K_.IMAGELOADERROR;break;default:return}this.hasListener(i)&&this.dispatchEvent(new Gtt(i,e))}}function p0(s,t){s.getImage().src=t}function m0(s,t,e,i){const n=t/e,r=Rs(s),o=Xo(Rt(s)/n,cr),a=Xo(Ee(s)/n,cr),l=Xo((i-1)*o/2,cr),h=o+2*l,c=Xo((i-1)*a/2,cr),u=a+2*c;return qx(r,n,0,[h,u])}const ya=jtt;function lL(s){const t=s.load||pa,e=s.imageExtent,i=s.crossOrigin??null;return()=>{const n=new Image;return n.crossOrigin=i,t(n,s.url).then(r=>{const o=Rt(e)/r.width,a=Ee(e)/r.height;return{image:r,extent:e,resolution:o!==a?[o,a]:a,pixelRatio:1}})}}class hL extends ya{constructor(t){const e=t.crossOrigin!==void 0?t.crossOrigin:null,i=t.imageLoadFunction!==void 0?t.imageLoadFunction:p0;super({attributions:t.attributions,interpolate:t.interpolate,projection:st(t.projection)}),this.url_=t.url,this.imageExtent_=t.imageExtent,this.image=null,this.image=new Wm(this.imageExtent_,void 0,1,lL({url:t.url,imageExtent:t.imageExtent,crossOrigin:e,load:(n,r)=>(this.image.setImage(n),i(this.image,r),pa(n))})),this.image.addEventListener(Zt.CHANGE,this.handleImageChange.bind(this))}getImageExtent(){return this.imageExtent_}getImageInternal(t,e,i,n){return Ce(t,this.image.getExtent())?this.image:null}getUrl(){return this.url_}}function oo(s,t){const e=[];Object.keys(t).forEach(function(n){t[n]!==null&&t[n]!==void 0&&e.push(n+"="+encodeURIComponent(t[n]))});const i=e.join("&");return s=s.replace(/[?&]$/,""),s+=s.includes("?")?"&":"?",s+i}const ztt=/\{z\}/g,Utt=/\{x\}/g,Btt=/\{y\}/g,Wtt=/\{-y\}/g;function cL(s,t,e,i,n){return s.replace(ztt,t.toString()).replace(Utt,e.toString()).replace(Btt,i.toString()).replace(Wtt,function(){if(n===void 0)throw new Error("If the URL template has a {-y} placeholder, the grid extent must be known");return(n-i).toString()})}function Xtt(s,t,e,i){const n=fA(t,e,i),r=kn(n,s.length);return s[r]}function _0(s){const t=[];let e=/\{([a-z])-([a-z])\}/.exec(s);if(e){const i=e[1].charCodeAt(0),n=e[2].charCodeAt(0);let r;for(r=i;r<=n;++r)t.push(s.replace(e[0],String.fromCharCode(r)));return t}if(e=/\{(\d+)-(\d+)\}/.exec(s),e){const i=parseInt(e[2],10);for(let n=parseInt(e[1],10);n<=i;n++)t.push(s.replace(e[0],n.toString()));return t}return t.push(s),t}function Vtt(s,t){return function(e,i,n){if(!e)return;let r;const o=e[0];if(t){const a=t.getFullTileRange(o);a&&(r=a.getHeight()-1)}return cL(s,o,e[1],e[2],r)}}function Cw(s,t){const e=s.length,i=new Array(e);for(let n=0;nthis.getTileInternal(m,_,y,v,o),this.reprojectionErrorThreshold_,this.renderReprojectionEdges_,this.tileOptions);return p.key=u,h?a.replace(c,p):a.set(c,p),p}getTileInternal(t,e,i,n,r){const o=ro(t,e,i),a=this.getKey();if(!this.tileCache.containsKey(o)){const h=this.createTile_(t,e,i,n,r,a);return this.tileCache.set(o,h),h}let l=this.tileCache.get(o);return l.key!=a&&(l=this.createTile_(t,e,i,n,r,a),this.tileCache.replace(o,l)),l}setRenderReprojectionEdges(t){if(this.renderReprojectionEdges_!=t){this.renderReprojectionEdges_=t;for(const e in this.tileCacheForProjection)this.tileCacheForProjection[e].clear();this.changed()}}setTileGridForProjection(t,e){const i=st(t);if(i){const n=mt(i);n in this.tileGridForProjection||(this.tileGridForProjection[n]=e)}}clear(){super.clear();for(const t in this.tileCacheForProjection)this.tileCacheForProjection[t].clear()}}function qtt(s,t){s.getImage().src=t}function Iw(s,t,e,i){const n=document.createElement("script"),r="olc_"+mt(t);function o(){delete window[r],n.parentNode.removeChild(n)}n.async=!0,n.src=s+(s.includes("?")?"&":"?")+"callback="+r;const a=setTimeout(function(){o(),e&&e()},1e4);window[r]=function(l){clearTimeout(a),o(),t(l)},document.head.appendChild(n)}class Ztt extends Error{constructor(t){const e="Unexpected response status: "+t.status;super(e),this.name="ResponseError",this.response=t}}class Htt extends Error{constructor(t){super("Failed to issue request"),this.name="ClientError",this.client=t}}function uL(s){return new Promise(function(t,e){function i(o){const a=o.target;if(!a.status||a.status>=200&&a.status<300){let l;try{l=JSON.parse(a.responseText)}catch(h){const c="Error parsing response text as JSON: "+h.message;e(new Error(c));return}t(l);return}e(new Ztt(a))}function n(o){e(new Htt(o.target))}const r=new XMLHttpRequest;r.addEventListener("load",i),r.addEventListener("error",n),r.open("GET",s),r.setRequestHeader("Accept","application/json"),r.send()})}function dL(s,t){return t.includes("://")?t:new URL(t,s).href}class gL extends Sn{constructor(t){if(super({attributions:t.attributions,cacheSize:t.cacheSize,crossOrigin:t.crossOrigin,interpolate:t.interpolate,projection:st("EPSG:3857"),reprojectionErrorThreshold:t.reprojectionErrorThreshold,state:"loading",tileLoadFunction:t.tileLoadFunction,wrapX:t.wrapX!==void 0?t.wrapX:!0,transition:t.transition,zDirection:t.zDirection}),this.tileJSON_=null,this.tileSize_=t.tileSize,t.url)if(t.jsonp)Iw(t.url,this.handleTileJSONResponse.bind(this),this.handleTileJSONError.bind(this));else{const e=new XMLHttpRequest;e.addEventListener("load",this.onXHRLoad_.bind(this)),e.addEventListener("error",this.onXHRError_.bind(this)),e.open("GET",t.url),e.send()}else if(t.tileJSON)this.handleTileJSONResponse(t.tileJSON);else throw new Error("Either `url` or `tileJSON` options must be provided")}onXHRLoad_(t){const e=t.target;if(!e.status||e.status>=200&&e.status<300){let i;try{i=JSON.parse(e.responseText)}catch{this.handleTileJSONError();return}this.handleTileJSONResponse(i)}else this.handleTileJSONError()}onXHRError_(t){this.handleTileJSONError()}getTileJSON(){return this.tileJSON_}handleTileJSONResponse(t){const e=st("EPSG:4326"),i=this.getProjection();let n;if(t.bounds!==void 0){const h=Sl(e,i);n=nc(t.bounds,h)}const r=yo(i),o=t.minzoom||0,a=t.maxzoom||22,l=Cl({extent:r,maxZoom:a,minZoom:o,tileSize:this.tileSize_});if(this.tileGrid=l,this.tileUrlFunction=Cw(t.tiles,l),t.attribution&&!this.getAttributions()){const h=n!==void 0?n:r;this.setAttributions(function(c){return Ce(h,c.extent)?[t.attribution]:null})}this.tileJSON_=t,this.setState("ready")}handleTileJSONError(){this.setState("error")}}let Ktt=class extends Oc{constructor(s,t,e,i,n,r){super(s,t,r),this.extent=null,this.format_=i,this.features_=null,this.loader_,this.projection=null,this.resolution,this.tileLoadFunction_=n,this.url_=e,this.key=e}getFormat(){return this.format_}getFeatures(){return this.features_}load(){this.state==X.IDLE&&(this.setState(X.LOADING),this.tileLoadFunction_(this,this.url_),this.loader_&&this.loader_(this.extent,this.resolution,this.projection))}onLoad(s,t){this.setFeatures(s)}onError(){this.setState(X.ERROR)}setFeatures(s){this.features_=s,this.setState(X.LOADED)}setLoader(s){this.loader_=s}};const ZM=[];class Jtt extends Oc{constructor(t,e,i,n){super(t,e,{transition:0}),this.context_=null,this.executorGroups=[],this.loadingSourceTiles=0,this.hitDetectionImageData={},this.replayState_={},this.sourceTiles=[],this.errorTileKeys={},this.wantedResolution,this.getSourceTiles=n.bind(void 0,this),this.wrappedTileCoord=i}getContext(){return this.context_||(this.context_=Se(1,1,ZM)),this.context_}hasContext(){return!!this.context_}getImage(){return this.hasContext()?this.getContext().canvas:null}getReplayState(t){const e=mt(t);return e in this.replayState_||(this.replayState_[e]={dirty:!1,renderedRenderOrder:null,renderedResolution:NaN,renderedRevision:-1,renderedTileResolution:NaN,renderedTileRevision:-1,renderedTileZ:-1}),this.replayState_[e]}load(){this.getSourceTiles()}release(){ol(this.context_),ZM.push(this.context_.canvas),this.context_=null,super.release()}}class y0 extends Rw{constructor(t){const e=t.projection||"EPSG:3857",i=t.extent||yo(e),n=t.tileGrid||Cl({extent:i,maxResolution:t.maxResolution,maxZoom:t.maxZoom!==void 0?t.maxZoom:22,minZoom:t.minZoom,tileSize:t.tileSize||512});super({attributions:t.attributions,attributionsCollapsible:t.attributionsCollapsible,cacheSize:t.cacheSize,interpolate:!0,projection:e,state:t.state,tileGrid:n,tileLoadFunction:t.tileLoadFunction?t.tileLoadFunction:Qtt,tileUrlFunction:t.tileUrlFunction,url:t.url,urls:t.urls,wrapX:t.wrapX===void 0?!0:t.wrapX,transition:t.transition,zDirection:t.zDirection===void 0?1:t.zDirection}),this.format_=t.format?t.format:null,this.sourceTileCache_=new u0(128),this.overlaps_=t.overlaps==null?!0:t.overlaps,this.tileClass=t.tileClass?t.tileClass:Ktt,this.tileGrids_={}}getOverlaps(){return this.overlaps_}clear(){this.sourceTileCache_.clear()}expireCache(t,e){const i=this.getTileCacheForProjection(t),n=Object.keys(e).reduce((r,o)=>{const a=EK(o),l=i.peek(a);if(l){const h=l.sourceTiles;for(let c=0,u=h.length;c{const g=this.tileUrlFunction(d,t,e),f=this.sourceTileCache_.containsKey(g)?this.sourceTileCache_.get(g):new this.tileClass(d,g?X.IDLE:X.EMPTY,g,this.format_,this.tileLoadFunction);i.sourceTiles.push(f);const p=f.getState();if(p{this.handleTileChange(_);const y=f.getState();if(y===X.LOADED||y===X.ERROR){const v=f.getKey();v in i.errorTileKeys?f.getState()===X.LOADED&&delete i.errorTileKeys[v]:i.loadingSourceTiles--,y===X.ERROR?i.errorTileKeys[v]=!0:f.removeEventListener(Zt.CHANGE,m),i.loadingSourceTiles===0&&i.setState(eo(i.errorTileKeys)?X.LOADED:X.ERROR)}};f.addEventListener(Zt.CHANGE,m),i.loadingSourceTiles++}p===X.IDLE&&(f.extent=h.getTileCoordExtent(d),f.projection=e,f.resolution=h.getResolution(d[0]),this.sourceTileCache_.set(g,f),f.load())}),i.loadingSourceTiles||i.setState(i.sourceTiles.some(d=>d.getState()===X.ERROR)?X.ERROR:X.LOADED)}return i.sourceTiles}getTile(t,e,i,n,r){const o=[t,e,i];let a=this.getTileCoordForTileUrlFunction(o,r);const l=this.getTileGrid().getExtent(),h=this.getTileGridForProjection(r);if(a&&l){const d=h.getTileCoordExtent(a);_n(d,-h.getResolution(t),d),Ce(l,d)||(a=null)}let c=!0;if(a!==null){const d=this.tileGrid,g=h.getResolution(t),f=d.getZForResolution(g,1),p=h.getTileCoordExtent(a);_n(p,-g,p),d.forEachTileCoord(p,f,m=>{c=c&&!this.tileUrlFunction(m,n,r)})}const u=new Jtt(o,c?X.EMPTY:X.IDLE,a,this.getSourceTiles.bind(this,n,r));return u.key=this.getKey(),u}getTileGridForProjection(t){const e=t.getCode();let i=this.tileGrids_[e];if(!i){const n=this.tileGrid,r=n.getResolutions().slice(),o=r.map(function(h,c){return n.getOrigin(c)}),a=r.map(function(h,c){return n.getTileSize(c)}),l=GP+1;for(let h=r.length;h=0;n[o?"CRS":"SRS"]=i.getCode();const a=o&&r.startsWith("ne")?[t[1],t[0],t[3],t[2]]:t;return n.BBOX=a.join(","),oo(s,n)}function pL(s,t,e,i,n,r,o){r=Object.assign({REQUEST:"GetMap"},r);const a=t/e,l=[Mp(Rt(s)/a,cr),Mp(Ee(s)/a,cr)];if(e!=1)switch(o){case"geoserver":const h=90*e+.5|0;"FORMAT_OPTIONS"in r?r.FORMAT_OPTIONS+=";dpi:"+h:r.FORMAT_OPTIONS="dpi:"+h;break;case"mapserver":r.MAP_RESOLUTION=90*e;break;case"carmentaserver":case"qgis":r.DPI=90*e;break;default:throw new Error("Unknown `serverType` configured")}return fL(n,s,l,i,r)}function Qp(s,t){return Object.assign({REQUEST:t,SERVICE:"WMS",VERSION:Jp,FORMAT:"image/png",STYLES:"",TRANSPARENT:!0},s)}function mL(s){const t=s.hidpi===void 0?!0:s.hidpi,e=st(s.projection||"EPSG:3857"),i=s.ratio||1.5,n=s.load||pa,r=s.crossOrigin??null;return(o,a,l)=>{o=m0(o,a,l,i),l!=1&&(!t||s.serverType===void 0)&&(l=1);const h=pL(o,a,l,e,s.url,Qp(s.params,"GetMap"),s.serverType),c=new Image;return c.crossOrigin=r,n(c,h).then(u=>({image:u,extent:o,pixelRatio:l}))}}function tet(s,t,e){if(s.url===void 0)return;const i=st(s.projection||"EPSG:3857"),n=qx(t,e,0,HM),r={QUERY_LAYERS:s.params.LAYERS,INFO_FORMAT:"application/json"};Object.assign(r,Qp(s.params,"GetFeatureInfo"),s.params);const o=fh((t[0]-n[0])/e,cr),a=fh((n[3]-t[1])/e,cr),l=Jx(r.VERSION,"1.3")>=0;return r[l?"I":"X"]=o,r[l?"J":"Y"]=a,fL(s.url,n,HM,i,r)}function eet(s,t){if(s.url===void 0)return;const e={SERVICE:"WMS",VERSION:Jp,REQUEST:"GetLegendGraphic",FORMAT:"image/png"};if(t!==void 0){const i=st(s.projection||"EPSG:3857").getMetersPerUnit()||1,n=28e-5;e.SCALE=t*i/n}if(Object.assign(e,s.params),s.params!==void 0&&e.LAYER===void 0){const i=e.LAYERS;if(!(!Array.isArray(i)||i.length!==1))return;e.LAYER=i}return oo(s.url,e)}class _L extends Sn{constructor(t){t=t||{};const e=Object.assign({},t.params);super({attributions:t.attributions,attributionsCollapsible:t.attributionsCollapsible,cacheSize:t.cacheSize,crossOrigin:t.crossOrigin,interpolate:t.interpolate,projection:t.projection,reprojectionErrorThreshold:t.reprojectionErrorThreshold,tileClass:t.tileClass,tileGrid:t.tileGrid,tileLoadFunction:t.tileLoadFunction,url:t.url,urls:t.urls,wrapX:t.wrapX!==void 0?t.wrapX:!0,transition:t.transition,zDirection:t.zDirection}),this.gutter_=t.gutter!==void 0?t.gutter:0,this.params_=e,this.v13_=!0,this.serverType_=t.serverType,this.hidpi_=t.hidpi!==void 0?t.hidpi:!0,this.tmpExtent_=Zs(),this.updateV13_(),this.setKey(this.getKeyForParams_())}getFeatureInfoUrl(t,e,i,n){const r=st(i),o=this.getProjection()||r;let a=this.getTileGrid();a||(a=this.getTileGridForProjection(o));const l=Dm(t,r,o),h=$d(o,r,t,e),c=a.getZForResolution(h,this.zDirection),u=a.getResolution(c),d=a.getTileCoordForCoordAndZ(l,c);if(a.getResolutions().length<=d[0])return;let g=a.getTileCoordExtent(d,this.tmpExtent_);const f=this.gutter_;f!==0&&(g=_n(g,u*f,g));const p={QUERY_LAYERS:this.params_.LAYERS};Object.assign(p,Qp(this.params_,"GetFeatureInfo"),n);const m=Math.floor((l[0]-g[0])/u),_=Math.floor((g[3]-l[1])/u);return p[this.v13_?"I":"X"]=m,p[this.v13_?"J":"Y"]=_,this.getRequestUrl_(d,g,1,o||r,p)}getLegendUrl(t,e){if(this.urls[0]===void 0)return;const i={SERVICE:"WMS",VERSION:Jp,REQUEST:"GetLegendGraphic",FORMAT:"image/png"};if(e===void 0||e.LAYER===void 0){const n=this.params_.LAYERS;if(!(!Array.isArray(n)||n.length===1))return;i.LAYER=n}if(t!==void 0){const n=this.getProjection()?this.getProjection().getMetersPerUnit():1,r=28e-5;i.SCALE=t*n/r}return Object.assign(i,e),oo(this.urls[0],i)}getGutter(){return this.gutter_}getParams(){return this.params_}getRequestUrl_(t,e,i,n,r){const o=this.urls;if(!o)return;let a;if(o.length==1)a=o[0];else{const l=kn(Jv(t),o.length);a=o[l]}return pL(e,(this.tileGrid||this.getTileGridForProjection(n)).getResolution(t[0]),i,n,a,r,this.serverType_)}getTilePixelRatio(t){return!this.hidpi_||this.serverType_===void 0?1:t}getKeyForParams_(){let t=0;const e=[];for(const i in this.params_)e[t++]=i+"-"+this.params_[i];return e.join("/")}updateParams(t){Object.assign(this.params_,t),this.updateV13_(),this.setKey(this.getKeyForParams_())}updateV13_(){const t=this.params_.VERSION||Jp;this.v13_=Jx(t,"1.3")>=0}tileUrlFunction(t,e,i){let n=this.getTileGrid();if(n||(n=this.getTileGridForProjection(i)),n.getResolutions().length<=t[0])return;e!=1&&(!this.hidpi_||this.serverType_===void 0)&&(e=1);const r=n.getResolution(t[0]);let o=n.getTileCoordExtent(t,this.tmpExtent_);const a=this.gutter_;a!==0&&(o=_n(o,r*a,o));const l=Object.assign({},Qp(this.params_,"GetMap"));return this.getRequestUrl_(t,o,e,i,l)}}class yL extends Sn{constructor(t){const e=t.requestEncoding!==void 0?t.requestEncoding:"KVP",i=t.tileGrid;let n=t.urls;n===void 0&&t.url!==void 0&&(n=_0(t.url)),super({attributions:t.attributions,attributionsCollapsible:t.attributionsCollapsible,cacheSize:t.cacheSize,crossOrigin:t.crossOrigin,interpolate:t.interpolate,projection:t.projection,reprojectionErrorThreshold:t.reprojectionErrorThreshold,tileClass:t.tileClass,tileGrid:i,tileLoadFunction:t.tileLoadFunction,tilePixelRatio:t.tilePixelRatio,urls:n,wrapX:t.wrapX!==void 0?t.wrapX:!1,transition:t.transition,zDirection:t.zDirection}),this.version_=t.version!==void 0?t.version:"1.0.0",this.format_=t.format!==void 0?t.format:"image/jpeg",this.dimensions_=t.dimensions!==void 0?t.dimensions:{},this.layer_=t.layer,this.matrixSet_=t.matrixSet,this.style_=t.style,this.requestEncoding_=e,this.setKey(this.getKeyForDimensions_()),n&&n.length>0&&(this.tileUrlFunction=fc(n.map(this.createFromWMTSTemplate.bind(this))))}setUrls(t){this.urls=t;const e=t.join(` +`);this.setTileUrlFunction(fc(t.map(this.createFromWMTSTemplate.bind(this))),e)}getDimensions(){return this.dimensions_}getFormat(){return this.format_}getLayer(){return this.layer_}getMatrixSet(){return this.matrixSet_}getRequestEncoding(){return this.requestEncoding_}getStyle(){return this.style_}getVersion(){return this.version_}getKeyForDimensions_(){const t=this.urls?this.urls.slice(0):[];for(const e in this.dimensions_)t.push(e+"-"+this.dimensions_[e]);return t.join("/")}updateDimensions(t){Object.assign(this.dimensions_,t),this.setKey(this.getKeyForDimensions_())}createFromWMTSTemplate(t){const e=this.requestEncoding_,i={layer:this.layer_,style:this.style_,tilematrixset:this.matrixSet_};e=="KVP"&&Object.assign(i,{Service:"WMTS",Request:"GetTile",Version:this.version_,Format:this.format_}),t=e=="KVP"?oo(t,i):t.replace(/\{(\w+?)\}/g,function(o,a){return a.toLowerCase()in i?i[a.toLowerCase()]:o});const n=this.tileGrid,r=this.dimensions_;return function(o,a,l){if(!o)return;const h={TileMatrix:n.getMatrixId(o[0]),TileCol:o[1],TileRow:o[2]};Object.assign(h,r);let c=t;return e=="KVP"?c=oo(c,h):c=c.replace(/\{(\w+?)\}/g,function(u,d){return h[d]}),c}}}function xL(s,t){const e=s.Contents.Layer,i=e?.find(function(P){return P.Identifier==t.layer});if(!i)return null;const n=s.Contents.TileMatrixSet;let r;i.TileMatrixSetLink.length>1?"projection"in t?r=i.TileMatrixSetLink.findIndex(function(P){const D=n.find(function(b){return b.Identifier==P.TileMatrixSet}).SupportedCRS,x=st(D),E=st(t.projection);return x&&E?qs(x,E):D==t.projection}):r=i.TileMatrixSetLink.findIndex(function(P){return P.TileMatrixSet==t.matrixSet}):r=0,r<0&&(r=0);const o=i.TileMatrixSetLink[r].TileMatrixSet,a=i.TileMatrixSetLink[r].TileMatrixSetLimits;let l=i.Format[0];"format"in t&&(l=t.format),r=i.Style.findIndex(function(P){return"style"in t?P.Title==t.style:P.isDefault}),r<0&&(r=0);const h=i.Style[r].Identifier,c={};"Dimension"in i&&i.Dimension.forEach(function(P,D,x){const E=P.Identifier;let b=P.Default;b===void 0&&(b=P.Value[0]),c[E]=b});const u=s.Contents.TileMatrixSet.find(function(P){return P.Identifier==o});let d;const g=u.SupportedCRS;if(g&&(d=st(g)),"projection"in t){const P=st(t.projection);P&&(!d||qs(P,d))&&(d=P)}let f=!1;const p=d.getAxisOrientation().startsWith("ne");let m=u.TileMatrix[0],_={MinTileCol:0,MinTileRow:0,MaxTileCol:m.MatrixWidth-1,MaxTileRow:m.MatrixHeight-1};if(a){_=a[a.length-1];const P=u.TileMatrix.find(D=>D.Identifier===_.TileMatrix||u.Identifier+":"+D.Identifier===_.TileMatrix);P&&(m=P)}const y=m.ScaleDenominator*28e-5/d.getMetersPerUnit(),v=p?[m.TopLeftCorner[1],m.TopLeftCorner[0]]:m.TopLeftCorner,S=m.TileWidth*y,w=m.TileHeight*y;let C=u.BoundingBox;C&&p&&(C=[C[1],C[0],C[3],C[2]]);let M=[v[0]+S*_.MinTileCol,v[1]-w*(1+_.MaxTileRow),v[0]+S*(1+_.MaxTileCol),v[1]-w*_.MinTileRow];if(C!==void 0&&!ai(C,M)){const P=i.WGS84BoundingBox,D=st("EPSG:4326").getExtent();if(M=C,P)f=P[0]===D[0]&&P[2]===D[2];else{const x=ev(C,u.SupportedCRS,"EPSG:4326");f=x[0]-1e-10<=D[0]&&x[2]+1e-10>=D[2]}}const T=VJ(u,M,a),I=[];let O=t.requestEncoding;if(O=O!==void 0?O:"","OperationsMetadata"in s&&"GetTile"in s.OperationsMetadata){const P=s.OperationsMetadata.GetTile.DCP.HTTP.Get;for(let D=0,x=P.length;D_)return 1;if(_>m)return-1}var y=g[g.length-1],v=f[f.length-1];if(y&&v){var S=y.split(".").map(r),w=v.split(".").map(r);for(p=0;pw[p])return 1;if(w[p]>S[p])return-1}}else if(y||v)return y?-1:1;return 0}var l=[">",">=","=","<","<="],h={">":[1],">=":[0,1],"=":[0],"<=":[-1,0],"<":[-1]};function c(u){if(typeof u!="string")throw new TypeError("Invalid operator type, expected string but got "+typeof u);if(l.indexOf(u)===-1)throw new TypeError("Invalid operator, expected one of "+l.join("|"))}return a.validate=function(u){return typeof u=="string"&&e.test(u)},a.compare=function(u,d,g){c(g);var f=a(u,d);return h[g].indexOf(f)>-1},a})})(vL);var set=vL.exports,_y=set;const Pw="1.0.0",St={classification:"https://stac-extensions.github.io/classification/v1.1.0/schema.json",datacube:"https://stac-extensions.github.io/datacube/v2.1.0/schema.json",eo:"https://stac-extensions.github.io/eo/v1.0.0/schema.json",file:"https://stac-extensions.github.io/file/v1.0.0/schema.json","item-assets":"https://stac-extensions.github.io/item-assets/v1.0.0/schema.json",label:"https://stac-extensions.github.io/label/v1.0.1/schema.json",pointcloud:"https://stac-extensions.github.io/pointcloud/v1.0.0/schema.json",processing:"https://stac-extensions.github.io/processing/v1.1.0/schema.json",projection:"https://stac-extensions.github.io/projection/v1.0.0/schema.json",raster:"https://stac-extensions.github.io/raster/v1.1.0/schema.json",sar:"https://stac-extensions.github.io/sar/v1.0.0/schema.json",sat:"https://stac-extensions.github.io/sat/v1.0.0/schema.json",scientific:"https://stac-extensions.github.io/scientific/v1.0.0/schema.json",table:"https://stac-extensions.github.io/table/v1.2.0/schema.json",timestamps:"https://stac-extensions.github.io/timestamps/v1.0.0/schema.json",version:"https://stac-extensions.github.io/version/v1.0.0/schema.json",view:"https://stac-extensions.github.io/view/v1.0.0/schema.json"},Za={itemAndCollection:{"cube:":St.datacube,"eo:":St.eo,"file:":St.file,"label:":St.label,"pc:":St.pointcloud,"processing:":St.processing,"proj:":St.projection,"raster:":St.raster,"sar:":St.sar,"sat:":St.sat,"sci:":St.scientific,"view:":St.view,version:St.version,deprecated:St.version,published:St.timestamps,expires:St.timestamps,unpublished:St.timestamps},catalog:{},collection:{item_assets:St["item-assets"]},item:{}};Za.collection=Object.assign(Za.collection,Za.itemAndCollection);Za.item=Object.assign(Za.item,Za.itemAndCollection);var bu={parseUrl(s){let t=s.match(/^https?:\/\/stac-extensions.github.io\/([^\/]+)\/v([^\/]+)\/[^.]+.json$/i);if(t)return{id:t[1],version:t[2]}}},se={version:Pw,extensions:{},set(s){if(typeof s.stac_version!="string"?se.version="0.6.0":se.version=s.stac_version,Array.isArray(s.stac_extensions))for(let t of s.stac_extensions){let e=bu.parseUrl(t);e&&(se.extensions[e.id]=e.version)}},before(s,t=null){let e=t?se.extensions[t]:se.version;return typeof e>"u"?!1:_y.compare(e,s,"<")}},j={type(s){let t=typeof s;if(t==="object"){if(s===null)return"null";if(Array.isArray(s))return"array"}return t},is(s,t){return j.type(s)===t},isDefined(s){return typeof s<"u"},isObject(s){return typeof s=="object"&&s===Object(s)&&!Array.isArray(s)},rename(s,t,e){return typeof s[t]<"u"&&typeof s[e]>"u"?(s[e]=s[t],delete s[t],!0):!1},forAll(s,t,e){if(s[t]&&typeof s[t]=="object")for(let i in s[t])e(s[t][i])},toArray(s,t){return typeof s[t]<"u"&&!Array.isArray(s[t])?(s[t]=[s[t]],!0):!1},flattenArray(s,t,e,i=!1){if(Array.isArray(s[t])){for(let n in s[t])if(typeof e[n]=="string"){let r=s[t][n];s[e[n]]=i?[r]:r}return delete s[t],!0}return!1},flattenOneElementArray(s,t,e=!1){return!e&&Array.isArray(s[t])?s[t].length===1?(s[t]=s[t][0],!0):!1:!0},removeFromArray(s,t,e){if(Array.isArray(s[t])){let i=s[t].indexOf(e);return i>-1&&s[t].splice(i,1),!0}return!1},ensure(s,t,e){return j.type(e)!==j.type(s[t])&&(s[t]=e),!0},upgradeExtension(s,t){let{id:e,version:i}=bu.parseUrl(t),n=s.stac_extensions.findIndex(r=>{let o=bu.parseUrl(r);return o&&o.id===e&&_y.compare(o.version,i,"<")});return n!==-1?(s.stac_extensions[n]=t,!0):!1},addExtension(s,t){let{id:e,version:i}=bu.parseUrl(t),n=s.stac_extensions.findIndex(r=>{if(r===t)return!0;let o=bu.parseUrl(r);return!!(o&&o.id===e&&_y.compare(o.version,i,"<"))});return n===-1?s.stac_extensions.push(t):s.stac_extensions[n]=t,s.stac_extensions.sort(),!0},removeExtension(s,t){return j.removeFromArray(s,"stac_extensions",t)},migrateExtensionShortnames(s){let t=Object.keys(St),e=Object.values(St);return j.mapValues(s,"stac_extensions",t,e)},populateExtensions(s,t){let e=[];(t=="catalog"||t=="collection")&&e.push(s),(t=="item"||t=="collection")&&j.isObject(s.assets)&&(e=e.concat(Object.values(s.assets))),t=="collection"&&j.isObject(s.item_assets)&&(e=e.concat(Object.values(s.item_assets))),t=="collection"&&j.isObject(s.summaries)&&e.push(s.summaries),t=="item"&&j.isObject(s.properties)&&e.push(s.properties);for(let i of e)Object.keys(i).forEach(n=>{let r=n.match(/^(\w+:|[^:]+$)/i);if(Array.isArray(r)){let o=Za[t][r[0]];j.is(o,"string")&&j.addExtension(s,o)}})},mapValues(s,t,e,i){let n=r=>{let o=e.indexOf(r);return o>=0?i[o]:r};return Array.isArray(s[t])?s[t]=s[t].map(n):typeof s[t]<"u"&&(s[t]=n(s[t])),!0},mapObject(s,t){for(let e in s)s[e]=t(s[e],e)},moveTo(s,t,e,i=!1,n=!1){let r;return i?n?r=o=>Array.isArray(o):r=o=>Array.isArray(o)&&o.length===1:r=j.isDefined,r(s[t])?(e[t]=i&&!n?s[t][0]:s[t],delete s[t],!0):!1},runAll(s,t,e,i){for(let n in s)n.startsWith("migrate")||s[n](t,e,i)},toUTC(s,t){if(typeof s[t]=="string")try{return s[t]=this.toISOString(s[t]),!0}catch{}return delete s[t],!1},toISOString(s){return s instanceof Date||(s=new Date(s)),s.toISOString().replace(".000","")}},rr={multihash:null,hexToUint8(s){if(s.length===0||s.length%2!==0)throw new Error(`The string "${s}" is not valid hex.`);return new Uint8Array(s.match(/.{1,2}/g).map(t=>parseInt(t,16)))},uint8ToHex(s){return s.reduce((t,e)=>t+e.toString(16).padStart(2,"0"),"")},toMultihash(s,t,e){if(!rr.multihash||!j.is(s[t],"string"))return!1;try{const i=rr.multihash.encode(rr.hexToUint8(s[t]),e);return s[t]=rr.uint8ToHex(i),!0}catch(i){return console.warn(i),!1}}},Aw={migrate(s,t=!0){return se.set(s),t&&(s.stac_version=Pw),s.type="Catalog",j.ensure(s,"stac_extensions",[]),se.before("1.0.0-rc.1")&&j.migrateExtensionShortnames(s),j.ensure(s,"id",""),j.ensure(s,"description",""),j.ensure(s,"links",[]),j.runAll(Aw,s,s),se.before("0.8.0")&&j.populateExtensions(s,"catalog"),s}},Lw={migrate(s,t=!0){return Aw.migrate(s,t),s.type="Collection",se.before("1.0.0-rc.1")&&j.migrateExtensionShortnames(s),j.ensure(s,"license","proprietary"),j.ensure(s,"extent",{spatial:{bbox:[]},temporal:{interval:[]}}),j.runAll(Lw,s,s),j.isObject(s.properties)&&(j.removeFromArray(s,"stac_extensions","commons"),delete s.properties),se.before("0.8.0")&&j.populateExtensions(s,"collection"),se.before("1.0.0-beta.1")&&j.mapValues(s,"stac_extensions",["assets"],["item-assets"]),s},extent(s){if(j.ensure(s,"extent",{}),se.before("0.8.0")&&(Array.isArray(s.extent.spatial)&&(s.extent.spatial={bbox:[s.extent.spatial]}),Array.isArray(s.extent.temporal)&&(s.extent.temporal={interval:[s.extent.temporal]})),j.ensure(s.extent,"spatial",{}),j.ensure(s.extent.spatial,"bbox",[]),j.ensure(s.extent,"temporal",{}),j.ensure(s.extent.temporal,"interval",[]),se.before("1.0.0-rc.3")){if(s.extent.temporal.interval.length>1){let t,e;for(let i of s.extent.temporal.interval){if(i[0]===null)t=null;else if(typeof i[0]=="string"&&t!==null)try{let n=new Date(i[0]);(typeof t>"u"||n"u"||n>e)&&(e=n)}catch{}}s.extent.temporal.interval.unshift([t?j.toISOString(t):null,e?j.toISOString(e):null])}if(s.extent.spatial.bbox.length>1){let t=s.extent.spatial.bbox.reduce((e,i)=>Array.isArray(i)?Math.max(i.length,e):e,4);if(t>=4){let e=new Array(t).fill(null),i=t/2;for(let n of s.extent.spatial.bbox){if(!Array.isArray(n)||n.length<4)break;for(let r in n){let o=n[r];e[r]===null?e[r]=o:rn===null)===-1&&s.extent.spatial.bbox.unshift(e)}}}},collectionAssets(s){se.before("1.0.0-rc.1")&&j.removeExtension(s,"collection-assets"),jd.migrateAll(s)},itemAsset(s){se.before("1.0.0-beta.2")&&j.rename(s,"item_assets","assets"),jd.migrateAll(s,"item_assets")},summaries(s){if(j.ensure(s,"summaries",{}),se.before("0.8.0")&&j.isObject(s.other_properties)){for(let t in s.other_properties){let e=s.other_properties[t];Array.isArray(e.extent)&&e.extent.length===2?s.summaries[t]={minimum:e.extent[0],maximum:e.extent[1]}:Array.isArray(e.values)&&(e.values.filter(i=>Array.isArray(i)).length===e.values.length?s.summaries[t]=e.values.reduce((i,n)=>i.concat(n),[]):s.summaries[t]=e.values)}delete s.other_properties}if(se.before("1.0.0-beta.1")&&j.isObject(s.properties)&&!s.links.find(t=>["child","item"].includes(t.rel)))for(let t in s.properties){let e=s.properties[t];Array.isArray(e)||(e=[e]),s.summaries[t]=e}se.before("1.0.0-rc.1")&&j.mapObject(s.summaries,t=>(j.rename(t,"min","minimum"),j.rename(t,"max","maximum"),t)),x0.migrate(s.summaries,s,!0),j.moveTo(s.summaries,"sci:doi",s,!0)&&j.addExtension(s,St.scientific),j.moveTo(s.summaries,"sci:publications",s,!0,!0)&&j.addExtension(s,St.scientific),j.moveTo(s.summaries,"sci:citation",s,!0)&&j.addExtension(s,St.scientific),j.moveTo(s.summaries,"cube:dimensions",s,!0)&&j.addExtension(s,St.datacube),Object.keys(s.summaries).length===0&&delete s.summaries}},Ow={migrate(s,t=null,e=!0){se.set(s),e&&(s.stac_version=Pw),j.ensure(s,"stac_extensions",[]),se.before("1.0.0-rc.1")&&j.migrateExtensionShortnames(s),j.ensure(s,"id",""),j.ensure(s,"type","Feature"),j.isObject(s.geometry)||(s.geometry=null),s.geometry!==null&&j.ensure(s,"bbox",[]),j.ensure(s,"properties",{}),j.ensure(s,"links",[]),j.ensure(s,"assets",{});let i=!1;return j.isObject(t)&&j.isObject(t.properties)&&(j.removeFromArray(s,"stac_extensions","commons"),s.properties=Object.assign({},t.properties,s.properties),i=!0),j.runAll(Ow,s,s),x0.migrate(s.properties,s),jd.migrateAll(s),(se.before("0.8.0")||i)&&j.populateExtensions(s,"item"),s}},wL={migrate(s,t=!0){return j.ensure(s,"collections",[]),j.ensure(s,"links",[]),j.runAll(wL,s,s),s.collections=s.collections.map(e=>Lw.migrate(e,t)),s}},EL={migrate(s,t=!0){return j.ensure(s,"type","FeatureCollection"),j.ensure(s,"features",[]),j.ensure(s,"links",[]),j.runAll(EL,s,s),s.features=s.features.map(e=>Ow.migrate(e,null,t)),s}},jd={migrateAll(s,t="assets"){for(let e in s[t])jd.migrate(s[t][e],s)},migrate(s,t){return j.runAll(jd,s,t),x0.migrate(s,t),s},mediaTypes(s){j.is(s.type,"string")&&j.mapValues(s,"type",["image/vnd.stac.geotiff","image/vnd.stac.geotiff; cloud-optimized=true"],["image/tiff; application=geotiff","image/tiff; application=geotiff; profile=cloud-optimized"])},eo(s,t){let e=j.isObject(t.properties)&&Array.isArray(t.properties["eo:bands"])?t.properties["eo:bands"]:[];if(Array.isArray(s["eo:bands"]))for(let i in s["eo:bands"]){let n=s["eo:bands"][i];j.is(n,"number")&&j.isObject(e[n])?n=e[n]:j.isObject(n)||(n={}),s["eo:bands"][i]=n}}},x0={migrate(s,t,e=!1){return j.runAll(x0,s,t,e),s},_commonMetadata(s){se.before("1.0.0-rc.3")&&(j.toUTC(s,"created"),j.toUTC(s,"updated"))},_timestamps(s,t){j.toUTC(s,"published"),j.toUTC(s,"expires"),j.toUTC(s,"unpublished"),j.upgradeExtension(t,St.timestamps)},_versioningIndicator(s,t){j.upgradeExtension(t,St.version)},checksum(s,t){se.before("0.9.0")&&rr.multihash&&(j.rename(s,"checksum:md5","checksum:multihash")&&rr.toMultihash(s,"checksum:multihash","md5"),j.rename(s,"checksum:sha1","checksum:multihash")&&rr.toMultihash(s,"checksum:multihash","sha1"),j.rename(s,"checksum:sha2","checksum:multihash")&&rr.toMultihash(s,"checksum:multihash","sha2-256"),j.rename(s,"checksum:sha3","checksum:multihash")&&rr.toMultihash(s,"checksum:multihash","sha3-256")),se.before("1.0.0-rc.1")&&j.rename(s,"checksum:multihash","file:checksum")&&j.addExtension(t,St.file),j.removeExtension(t,"checksum")},classification(s,t){se.before("1.1.0","classification")&&j.forAll(s,"classification:classes",e=>j.rename(e,"color-hint","color_hint")),j.upgradeExtension(t,St.classification)},cube(s,t){j.upgradeExtension(t,St.datacube)},dtr(s,t){se.before("0.9.0")&&(j.rename(s,"dtr:start_datetime","start_datetime"),j.rename(s,"dtr:end_datetime","end_datetime"),j.removeExtension(t,"datetime-range"))},eo(s,t){se.before("0.9.0")&&(j.rename(s,"eo:epsg","proj:epsg")&&j.addExtension(t,St.projection),j.rename(s,"eo:platform","platform"),j.rename(s,"eo:instrument","instruments")&&j.toArray(s,"instruments"),j.rename(s,"eo:constellation","constellation"),j.rename(s,"eo:off_nadir","view:off_nadir")&&j.addExtension(t,St.view),j.rename(s,"eo:azimuth","view:azimuth")&&j.addExtension(t,St.view),j.rename(s,"eo:incidence_angle","view:incidence_angle")&&j.addExtension(t,St.view),j.rename(s,"eo:sun_azimuth","view:sun_azimuth")&&j.addExtension(t,St.view),j.rename(s,"eo:sun_elevation","view:sun_elevation")&&j.addExtension(t,St.view)),se.before("1.0.0-beta.1")&&j.rename(s,"eo:gsd","gsd"),j.upgradeExtension(t,St.eo)},file(s,t){j.upgradeExtension(t,St.file)},label(s,t){se.before("0.8.0")&&(j.rename(s,"label:property","label:properties"),j.rename(s,"label:task","label:tasks"),j.rename(s,"label:overview","label:overviews")&&j.toArray(s,"label:overviews"),j.rename(s,"label:method","label:methods"),j.toArray(s,"label:classes")),j.upgradeExtension(t,St.label)},pc(s,t){se.before("0.8.0")&&j.rename(s,"pc:schema","pc:schemas"),j.upgradeExtension(t,St.pointcloud)},processing(s,t){j.upgradeExtension(t,St.processing)},proj(s,t){j.upgradeExtension(t,St.projection)},raster(s,t){j.upgradeExtension(t,St.raster)},sar(s,t,e){j.rename(s,"sar:incidence_angle","view:incidence_angle")&&j.addExtension(t,St.view),j.rename(s,"sar:pass_direction","sat:orbit_state")&&j.mapValues(s,"sat:orbit_state",[null],["geostationary"])&&j.addExtension(t,St.sat),se.before("0.7.0")&&(j.flattenArray(s,"sar:resolution",["sar:resolution_range","sar:resolution_azimuth"],e),j.flattenArray(s,"sar:pixel_spacing",["sar:pixel_spacing_range","sar:pixel_spacing_azimuth"],e),j.flattenArray(s,"sar:looks",["sar:looks_range","sar:looks_azimuth","sar:looks_equivalent_number"],e),j.rename(s,"sar:off_nadir","view:off_nadir")&&j.addExtension(t,St.view)),se.before("0.9.0")&&(j.rename(s,"sar:platform","platform"),j.rename(s,"sar:instrument","instruments")&&j.toArray(s,"instruments"),j.rename(s,"sar:constellation","constellation"),j.rename(s,"sar:type","sar:product_type"),j.rename(s,"sar:polarization","sar:polarizations"),j.flattenOneElementArray(s,"sar:absolute_orbit",e)&&j.rename(s,"sar:absolute_orbit","sat:absolute_orbit")&&j.addExtension(t,St.sat),j.flattenOneElementArray(s,"sar:relative_orbit",e)&&j.rename(s,"sar:relative_orbit","sat:relative_orbit")&&j.addExtension(t,St.sat)),j.upgradeExtension(t,St.sar)},sat(s,t){se.before("0.9.0")&&(j.rename(s,"sat:off_nadir_angle","sat:off_nadir"),j.rename(s,"sat:azimuth_angle","sat:azimuth"),j.rename(s,"sat:sun_azimuth_angle","sat:sun_azimuth"),j.rename(s,"sat:sun_elevation_angle","sat:sun_elevation")),j.upgradeExtension(t,St.sat)},sci(s,t){j.upgradeExtension(t,St.scientific)},item(s){se.before("0.8.0")&&(j.rename(s,"item:license","license"),j.rename(s,"item:providers","providers"))},table(s,t){j.upgradeExtension(t,St.table)},view(s,t){j.upgradeExtension(t,St.view)}},eh={item(s,t=null,e=!0){return Ow.migrate(s,t,e)},catalog(s,t=!0){return Aw.migrate(s,t)},collection(s,t=!0){return Lw.migrate(s,t)},collectionCollection(s,t=!0){return wL.migrate(s,t)},itemCollection(s,t=!0){return EL.migrate(s,t)},stac(s,t=!0){return s.type==="Feature"?eh.item(s,null,t):s.type==="FeatureCollection"?eh.itemCollection(s,t):s.type==="Collection"||!s.type&&j.isDefined(s.extent)&&j.isDefined(s.license)?eh.collection(s,t):!s.type&&Array.isArray(s.collections)?eh.collectionCollection(s,t):eh.catalog(s,t)},enableMultihash(s){rr.multihash=s}},iet=eh;const net=g0(iet);function Dc(s){let t=s.length>=6,e=s[0],i=s[t?3:2],n=s[1],r=s[t?4:3],o={west:e,east:i,south:n,north:r};return t&&(o.base=s[2],o.height=s[5]),o}function J_(s){let{west:t,east:e,south:i,north:n}=Dc(s);return[[[t,n],[t,i],[e,i],[e,n],[t,n]]]}function ret(s){if(!$n(s))return null;let t=Dc(s),e=[];if(ML(s)){let i=(t.west+360+t.east)/2;i>180&&(i-=360),e.push(i)}else e.push((t.west+t.east)/2);return e.push((t.south+t.north)/2),typeof t.base<"u"&&e.push((t.base+t.height)/2),e}function SL(s){if($n(s)?s=[s]:Array.isArray(s)&&(s=s.filter(i=>$n(i))),!Array.isArray(s)||s.length===0)return null;let t=s.reduce((i,n)=>{if(ML(n)){let{west:r,east:o,south:a,north:l}=Dc(n);i.push(J_([-180,a,o,l])),i.push(J_([r,a,180,l]))}else i.push(J_(n));return i},[]),e=null;if(t.length===1?e={type:"Polygon",coordinates:t[0]}:t.length>1&&(e={type:"MultiPolygon",coordinates:t}),e)return{type:"Feature",geometry:e,properties:{}}}function $n(s){if(!Array.isArray(s)||![4,6].includes(s.length)||s.some(r=>typeof r!="number"))return!1;let{west:t,east:e,south:i,north:n}=Dc(s);return i<=n&&t>=-180&&t<=180&&i>=-90&&e<=180&&e>=-180&&n<=90}function ML(s){if(!$n(s))return!1;let{west:t,east:e}=Dc(s);return t>e}function bL(s){if(!Array.isArray(s)||s.length===0)return null;let t={west:180,south:90,east:-180,north:-90};s.forEach(i=>{if(!$n(i))return;let n=Dc(i),r=["west","south"];for(let o in n){let a=r.includes(o)?Math.min:Math.max;t[o]=a(t[o],n[o])}});let e=[t.west,t.south,t.east,t.north];return $n(e)?e:null}function Ri(s){return typeof s=="string"&&s.length>0}function xi(s){return typeof s=="object"&&s===Object(s)&&!Array.isArray(s)}function CL(...s){if(s=s.filter(t=>Array.isArray(t)),s.length>1){let t=Math.max(...s.map(i=>i.length)),e=[];for(let i=0;in[i])));return e}else if(s.length===1)return s[0];return[]}function oet(s){switch(s){case"int8":return-128;case"int16":return-32768;case"int32":return-2147483648}return s.startsWith("u")?0:null}function aet(s){switch(s){case"int8":return 127;case"uint8":return 255;case"int16":return 32767;case"uint16":return 65535;case"int32":return 2147483647;case"uint32":return 4294967295}return null}class v0{constructor(t,e={},i=[]){if(!xi(t))throw new Error("Given data is not an object");if(t instanceof v0){for(let n of i)this[n]=t[n];t=t.toJSON()}this._keyMap=e,this._privateKeys=["_keyMap","_privateKeys"].concat(i);for(let n in t)typeof this[n]>"u"&&(n in e?this[n]=e[n](t[n],this):this[n]=t[n])}isItem(){return this.type==="Feature"}isCatalog(){return this.type==="Catalog"}isCatalogLike(){return this.isCatalog()||this.isCollection()}isCollection(){return this.type==="Collection"}isItemCollection(){return this.type==="FeatureCollection"}isCollectionCollection(){return!1}isAsset(){return!1}isLink(){return!1}getObjectType(){}getAbsoluteUrl(){return null}getMetadata(t){return this[t]}toGeoJSON(){return null}getBoundingBox(){return null}getCenter(){return ret(this.getBoundingBox())}getBoundingBoxes(){return[]}toJSON(){let t={};return Object.keys(this).forEach(e=>{if(typeof this[e]=="function"||this._privateKeys.includes(e))return;let i=this[e];if(e in this._keyMap){let n=Array.isArray(i)?[]:{};for(let r in i)n[r]=i[r].toJSON();i=n}t[e]=i}),t}}var TL={exports:{}},zf={exports:{}};/*! https://mths.be/punycode v1.4.0 by @mathias */zf.exports;var KM;function het(){return KM||(KM=1,function(s,t){(function(e){var i=t&&!t.nodeType&&t,n=s&&!s.nodeType&&s,r=typeof qa=="object"&&qa;(r.global===r||r.window===r||r.self===r)&&(e=r);var o,a=2147483647,l=36,h=1,c=26,u=38,d=700,g=72,f=128,p="-",m=/^xn--/,_=/[^\x20-\x7E]/,y=/[\x2E\u3002\uFF0E\uFF61]/g,v={overflow:"Overflow: input needs wider integers to process","not-basic":"Illegal input >= 0x80 (not a basic code point)","invalid-input":"Invalid input"},S=l-h,w=Math.floor,C=String.fromCharCode,M;function T(k){throw new RangeError(v[k])}function I(k,z){for(var V=k.length,et=[];V--;)et[V]=z(k[V]);return et}function O(k,z){var V=k.split("@"),et="";V.length>1&&(et=V[0]+"@",k=V[1]),k=k.replace(y,".");var F=k.split("."),ot=I(F,z).join(".");return et+ot}function P(k){for(var z=[],V=0,et=k.length,F,ot;V=55296&&F<=56319&&V65535&&(z-=65536,V+=C(z>>>10&1023|55296),z=56320|z&1023),V+=C(z),V}).join("")}function x(k){return k-48<10?k-22:k-65<26?k-65:k-97<26?k-97:l}function E(k,z){return k+22+75*(k<26)-((z!=0)<<5)}function b(k,z,V){var et=0;for(k=V?w(k/d):k>>1,k+=w(k/z);k>S*c>>1;et+=l)k=w(k/S);return w(et+(S+1)*k/(k+u))}function R(k){var z=[],V=k.length,et,F=0,ot=f,ht=g,pt,Gt,Kt,bt,oe,Pe,hs,rs,Ge;for(pt=k.lastIndexOf(p),pt<0&&(pt=0),Gt=0;Gt=128&&T("not-basic"),z.push(k.charCodeAt(Gt));for(Kt=pt>0?pt+1:0;Kt=V&&T("invalid-input"),hs=x(k.charCodeAt(Kt++)),(hs>=l||hs>w((a-F)/oe))&&T("overflow"),F+=hs*oe,rs=Pe<=ht?h:Pe>=ht+c?c:Pe-ht,!(hsw(a/Ge)&&T("overflow"),oe*=Ge;et=z.length+1,ht=b(F-bt,et,bt==0),w(F/et)>a-ot&&T("overflow"),ot+=w(F/et),F%=et,z.splice(F++,0,ot)}return D(z)}function A(k){var z,V,et,F,ot,ht,pt,Gt,Kt,bt,oe,Pe=[],hs,rs,Ge,ve;for(k=P(k),hs=k.length,z=f,V=0,ot=g,ht=0;ht=z&&oew((a-V)/rs)&&T("overflow"),V+=(pt-z)*rs,z=pt,ht=0;hta&&T("overflow"),oe==z){for(Gt=V,Kt=l;bt=Kt<=ot?h:Kt>=ot+c?c:Kt-ot,!(Gt=1,R=arguments.length>=2;if(!(this instanceof o))return b?R?new o(x,E):new o(x):new o;if(x===void 0){if(b)throw new TypeError("undefined is not a valid argument for URI");typeof location<"u"?x=location.href+"":x=""}if(x===null&&b)throw new TypeError("null is not a valid argument for URI");return this.href(x),E!==void 0?this.absoluteTo(E):this}function a(x){return/^[0-9]+$/.test(x)}o.version="1.19.11";var l=o.prototype,h=Object.prototype.hasOwnProperty;function c(x){return x.replace(/([.*+?^=!:${}()|[\]\/\\])/g,"\\$1")}function u(x){return x===void 0?"Undefined":String(Object.prototype.toString.call(x)).slice(8,-1)}function d(x){return u(x)==="Array"}function g(x,E){var b={},R,A;if(u(E)==="RegExp")b=null;else if(d(E))for(R=0,A=E.length;R]+|\(([^\s()<>]+|(\([^\s()<>]+\)))*\))+(?:\(([^\s()<>]+|(\([^\s()<>]+\)))*\)|[^\s`!()\[\]{};:'".,<>?«»“”‘’]))/ig,o.findUri={start:/\b(?:([a-z][a-z0-9.+-]*:\/\/)|www\.)/gi,end:/[\s\r\n]|$/,trim:/[`!()\[\]{};:'".,<>?«»“”„‘’]+$/,parens:/(\([^\)]*\)|\[[^\]]*\]|\{[^}]*\}|<[^>]*>)/g},o.leading_whitespace_expression=/^[\x00-\x20\u00a0\u1680\u2000-\u200a\u2028\u2029\u202f\u205f\u3000\ufeff]+/,o.ascii_tab_whitespace=/[\u0009\u000A\u000D]+/g,o.defaultPorts={http:"80",https:"443",ftp:"21",gopher:"70",ws:"80",wss:"443"},o.hostProtocols=["http","https"],o.invalid_hostname_characters=/[^a-zA-Z0-9\.\-:_]/,o.domAttributes={a:"href",blockquote:"cite",link:"href",base:"href",script:"src",form:"action",img:"src",area:"href",iframe:"src",embed:"src",source:"src",track:"src",input:"src",audio:"src",video:"src"},o.getDomAttribute=function(x){if(!(!x||!x.nodeName)){var E=x.nodeName.toLowerCase();if(!(E==="input"&&x.type!=="image"))return o.domAttributes[E]}};function _(x){return escape(x)}function y(x){return encodeURIComponent(x).replace(/[!'()*]/g,_).replace(/\*/g,"%2A")}o.encode=y,o.decode=decodeURIComponent,o.iso8859=function(){o.encode=escape,o.decode=unescape},o.unicode=function(){o.encode=y,o.decode=decodeURIComponent},o.characters={pathname:{encode:{expression:/%(24|26|2B|2C|3B|3D|3A|40)/ig,map:{"%24":"$","%26":"&","%2B":"+","%2C":",","%3B":";","%3D":"=","%3A":":","%40":"@"}},decode:{expression:/[\/\?#]/g,map:{"/":"%2F","?":"%3F","#":"%23"}}},reserved:{encode:{expression:/%(21|23|24|26|27|28|29|2A|2B|2C|2F|3A|3B|3D|3F|40|5B|5D)/ig,map:{"%3A":":","%2F":"/","%3F":"?","%23":"#","%5B":"[","%5D":"]","%40":"@","%21":"!","%24":"$","%26":"&","%27":"'","%28":"(","%29":")","%2A":"*","%2B":"+","%2C":",","%3B":";","%3D":"="}}},urnpath:{encode:{expression:/%(21|24|27|28|29|2A|2B|2C|3B|3D|40)/ig,map:{"%21":"!","%24":"$","%27":"'","%28":"(","%29":")","%2A":"*","%2B":"+","%2C":",","%3B":";","%3D":"=","%40":"@"}},decode:{expression:/[\/\?#:]/g,map:{"/":"%2F","?":"%3F","#":"%23",":":"%3A"}}}},o.encodeQuery=function(x,E){var b=o.encode(x+"");return E===void 0&&(E=o.escapeQuerySpace),E?b.replace(/%20/g,"+"):b},o.decodeQuery=function(x,E){x+="",E===void 0&&(E=o.escapeQuerySpace);try{return o.decode(E?x.replace(/\+/g,"%20"):x)}catch{return x}};var v={encode:"encode",decode:"decode"},S,w=function(x,E){return function(b){try{return o[E](b+"").replace(o.characters[x][E].expression,function(R){return o.characters[x][E].map[R]})}catch{return b}}};for(S in v)o[S+"PathSegment"]=w("pathname",v[S]),o[S+"UrnPathSegment"]=w("urnpath",v[S]);var T=function(x,E,b){return function(R){var A;b?A=function(z){return o[E](o[b](z))}:A=o[E];for(var $=(R+"").split(x),G=0,k=$.length;G-1&&(E.fragment=x.substring(b+1)||null,x=x.substring(0,b)),b=x.indexOf("?"),b>-1&&(E.query=x.substring(b+1)||null,x=x.substring(0,b)),x=x.replace(/^(https?|ftp|wss?)?:+[/\\]*/i,"$1://"),x=x.replace(/^[/\\]{2,}/i,"//"),x.substring(0,2)==="//"?(E.protocol=null,x=x.substring(2),x=o.parseAuthority(x,E)):(b=x.indexOf(":"),b>-1&&(E.protocol=x.substring(0,b)||null,E.protocol&&!E.protocol.match(o.protocol_expression)?E.protocol=void 0:x.substring(b+1,b+3).replace(/\\/g,"/")==="//"?(x=x.substring(b+3),x=o.parseAuthority(x,E)):(x=x.substring(b+1),E.urn=!0))),E.path=x,E},o.parseHost=function(x,E){x||(x=""),x=x.replace(/\\/g,"/");var b=x.indexOf("/"),R,A;if(b===-1&&(b=x.length),x.charAt(0)==="[")R=x.indexOf("]"),E.hostname=x.substring(1,R)||null,E.port=x.substring(R+2,b)||null,E.port==="/"&&(E.port=null);else{var $=x.indexOf(":"),G=x.indexOf("/"),k=x.indexOf(":",$+1);k!==-1&&(G===-1||k-1?A:x.length-1),G;return $>-1&&(A===-1||$-1?ot=ot.slice(0,ht)+ot.slice(ht).replace($,""):ot=ot.replace($,""),!(ot.length<=z[0].length)&&!(b.ignore&&b.ignore.test(ot))){F=V+ot.length;var Kt=E(ot,V,F,x);if(Kt===void 0){R.lastIndex=F;continue}Kt=String(Kt),x=x.slice(0,V)+Kt+x.slice(F),R.lastIndex=V+Kt.length}}return R.lastIndex=0,x},o.ensureValidHostname=function(x,E){var b=!!x,R=!!E,A=!1;if(R&&(A=f(o.hostProtocols,E)),A&&!b)throw new TypeError("Hostname cannot be empty, if protocol is "+E);if(x&&x.match(o.invalid_hostname_characters)){if(!t)throw new TypeError('Hostname "'+x+'" contains characters other than [A-Z0-9.-:_] and Punycode.js is not available');if(t.toASCII(x).match(o.invalid_hostname_characters))throw new TypeError('Hostname "'+x+'" contains characters other than [A-Z0-9.-:_]')}},o.ensureValidPort=function(x){if(x){var E=Number(x);if(!(a(E)&&E>0&&E<65536))throw new TypeError('Port "'+x+'" is not a valid port')}},o.noConflict=function(x){if(x){var E={URI:this.noConflict()};return n.URITemplate&&typeof n.URITemplate.noConflict=="function"&&(E.URITemplate=n.URITemplate.noConflict()),n.IPv6&&typeof n.IPv6.noConflict=="function"&&(E.IPv6=n.IPv6.noConflict()),n.SecondLevelDomains&&typeof n.SecondLevelDomains.noConflict=="function"&&(E.SecondLevelDomains=n.SecondLevelDomains.noConflict()),E}else n.URI===this&&(n.URI=r);return this},l.build=function(x){return x===!0?this._deferred_build=!0:(x===void 0||this._deferred_build)&&(this._string=o.build(this._parts),this._deferred_build=!1),this},l.clone=function(){return new o(this)},l.valueOf=l.toString=function(){return this.build(!1)._string};function M(x){return function(E,b){return E===void 0?this._parts[x]||"":(this._parts[x]=E||null,this.build(!b),this)}}function C(x,E){return function(b,R){return b===void 0?this._parts[x]||"":(b!==null&&(b=b+"",b.charAt(0)===E&&(b=b.substring(1))),this._parts[x]=b,this.build(!R),this)}}l.protocol=M("protocol"),l.username=M("username"),l.password=M("password"),l.hostname=M("hostname"),l.port=M("port"),l.query=C("query","?"),l.fragment=C("fragment","#"),l.search=function(x,E){var b=this.query(x,E);return typeof b=="string"&&b.length?"?"+b:b},l.hash=function(x,E){var b=this.fragment(x,E);return typeof b=="string"&&b.length?"#"+b:b},l.pathname=function(x,E){if(x===void 0||x===!0){var b=this._parts.path||(this._parts.hostname?"/":"");return x?(this._parts.urn?o.decodeUrnPath:o.decodePath)(b):b}else return this._parts.urn?this._parts.path=x?o.recodeUrnPath(x):"":this._parts.path=x?o.recodePath(x):"/",this.build(!E),this},l.path=l.pathname,l.href=function(x,E){var b;if(x===void 0)return this.toString();this._string="",this._parts=o._parts();var R=x instanceof o,A=typeof x=="object"&&(x.hostname||x.path||x.pathname);if(x.nodeName){var $=o.getDomAttribute(x);x=x[$]||"",A=!1}if(!R&&A&&x.pathname!==void 0&&(x=x.toString()),typeof x=="string"||x instanceof String)this._parts=o.parse(String(x),this._parts);else if(R||A){var G=R?x._parts:x;for(b in G)b!=="query"&&h.call(this._parts,b)&&(this._parts[b]=G[b]);G.query&&this.query(G.query,!1)}else throw new TypeError("invalid input");return this.build(!E),this},l.is=function(x){var E=!1,b=!1,R=!1,A=!1,$=!1,G=!1,k=!1,z=!this._parts.urn;switch(this._parts.hostname&&(z=!1,b=o.ip4_expression.test(this._parts.hostname),R=o.ip6_expression.test(this._parts.hostname),E=b||R,A=!E,$=A&&i&&i.has(this._parts.hostname),G=A&&o.idn_expression.test(this._parts.hostname),k=A&&o.punycode_expression.test(this._parts.hostname)),x.toLowerCase()){case"relative":return z;case"absolute":return!z;case"domain":case"name":return A;case"sld":return $;case"ip":return E;case"ip4":case"ipv4":case"inet4":return b;case"ip6":case"ipv6":case"inet6":return R;case"idn":return G;case"url":return!this._parts.urn;case"urn":return!!this._parts.urn;case"punycode":return k}return null};var I=l.protocol,O=l.port,P=l.hostname;l.protocol=function(x,E){if(x&&(x=x.replace(/:(\/\/)?$/,""),!x.match(o.protocol_expression)))throw new TypeError('Protocol "'+x+`" contains characters other than [A-Z0-9.+-] or doesn't start with [A-Z]`);return I.call(this,x,E)},l.scheme=l.protocol,l.port=function(x,E){return this._parts.urn?x===void 0?"":this:(x!==void 0&&(x===0&&(x=null),x&&(x+="",x.charAt(0)===":"&&(x=x.substring(1)),o.ensureValidPort(x))),O.call(this,x,E))},l.hostname=function(x,E){if(this._parts.urn)return x===void 0?"":this;if(x!==void 0){var b={preventInvalidHostname:this._parts.preventInvalidHostname},R=o.parseHost(x,b);if(R!=="/")throw new TypeError('Hostname "'+x+'" contains characters other than [A-Z0-9.-]');x=b.hostname,this._parts.preventInvalidHostname&&o.ensureValidHostname(x,this._parts.protocol)}return P.call(this,x,E)},l.origin=function(x,E){if(this._parts.urn)return x===void 0?"":this;if(x===void 0){var b=this.protocol(),R=this.authority();return R?(b?b+"://":"")+this.authority():""}else{var A=o(x);return this.protocol(A.protocol()).authority(A.authority()).build(!E),this}},l.host=function(x,E){if(this._parts.urn)return x===void 0?"":this;if(x===void 0)return this._parts.hostname?o.buildHost(this._parts):"";var b=o.parseHost(x,this._parts);if(b!=="/")throw new TypeError('Hostname "'+x+'" contains characters other than [A-Z0-9.-]');return this.build(!E),this},l.authority=function(x,E){if(this._parts.urn)return x===void 0?"":this;if(x===void 0)return this._parts.hostname?o.buildAuthority(this._parts):"";var b=o.parseAuthority(x,this._parts);if(b!=="/")throw new TypeError('Hostname "'+x+'" contains characters other than [A-Z0-9.-]');return this.build(!E),this},l.userinfo=function(x,E){if(this._parts.urn)return x===void 0?"":this;if(x===void 0){var b=o.buildUserinfo(this._parts);return b&&b.substring(0,b.length-1)}else return x[x.length-1]!=="@"&&(x+="@"),o.parseUserinfo(x,this._parts),this.build(!E),this},l.resource=function(x,E){var b;return x===void 0?this.path()+this.search()+this.hash():(b=o.parse(x),this._parts.path=b.path,this._parts.query=b.query,this._parts.fragment=b.fragment,this.build(!E),this)},l.subdomain=function(x,E){if(this._parts.urn)return x===void 0?"":this;if(x===void 0){if(!this._parts.hostname||this.is("IP"))return"";var b=this._parts.hostname.length-this.domain().length-1;return this._parts.hostname.substring(0,b)||""}else{var R=this._parts.hostname.length-this.domain().length,A=this._parts.hostname.substring(0,R),$=new RegExp("^"+c(A));if(x&&x.charAt(x.length-1)!=="."&&(x+="."),x.indexOf(":")!==-1)throw new TypeError("Domains cannot contain colons");return x&&o.ensureValidHostname(x,this._parts.protocol),this._parts.hostname=this._parts.hostname.replace($,x),this.build(!E),this}},l.domain=function(x,E){if(this._parts.urn)return x===void 0?"":this;if(typeof x=="boolean"&&(E=x,x=void 0),x===void 0){if(!this._parts.hostname||this.is("IP"))return"";var b=this._parts.hostname.match(/\./g);if(b&&b.length<2)return this._parts.hostname;var R=this._parts.hostname.length-this.tld(E).length-1;return R=this._parts.hostname.lastIndexOf(".",R-1)+1,this._parts.hostname.substring(R)||""}else{if(!x)throw new TypeError("cannot set domain empty");if(x.indexOf(":")!==-1)throw new TypeError("Domains cannot contain colons");if(o.ensureValidHostname(x,this._parts.protocol),!this._parts.hostname||this.is("IP"))this._parts.hostname=x;else{var A=new RegExp(c(this.domain())+"$");this._parts.hostname=this._parts.hostname.replace(A,x)}return this.build(!E),this}},l.tld=function(x,E){if(this._parts.urn)return x===void 0?"":this;if(typeof x=="boolean"&&(E=x,x=void 0),x===void 0){if(!this._parts.hostname||this.is("IP"))return"";var b=this._parts.hostname.lastIndexOf("."),R=this._parts.hostname.substring(b+1);return E!==!0&&i&&i.list[R.toLowerCase()]&&i.get(this._parts.hostname)||R}else{var A;if(x)if(x.match(/[^a-zA-Z0-9-]/))if(i&&i.is(x))A=new RegExp(c(this.tld())+"$"),this._parts.hostname=this._parts.hostname.replace(A,x);else throw new TypeError('TLD "'+x+'" contains characters other than [A-Z0-9]');else{if(!this._parts.hostname||this.is("IP"))throw new ReferenceError("cannot set TLD on non-domain host");A=new RegExp(c(this.tld())+"$"),this._parts.hostname=this._parts.hostname.replace(A,x)}else throw new TypeError("cannot set TLD empty");return this.build(!E),this}},l.directory=function(x,E){if(this._parts.urn)return x===void 0?"":this;if(x===void 0||x===!0){if(!this._parts.path&&!this._parts.hostname)return"";if(this._parts.path==="/")return"/";var b=this._parts.path.length-this.filename().length-1,R=this._parts.path.substring(0,b)||(this._parts.hostname?"/":"");return x?o.decodePath(R):R}else{var A=this._parts.path.length-this.filename().length,$=this._parts.path.substring(0,A),G=new RegExp("^"+c($));return this.is("relative")||(x||(x="/"),x.charAt(0)!=="/"&&(x="/"+x)),x&&x.charAt(x.length-1)!=="/"&&(x+="/"),x=o.recodePath(x),this._parts.path=this._parts.path.replace(G,x),this.build(!E),this}},l.filename=function(x,E){if(this._parts.urn)return x===void 0?"":this;if(typeof x!="string"){if(!this._parts.path||this._parts.path==="/")return"";var b=this._parts.path.lastIndexOf("/"),R=this._parts.path.substring(b+1);return x?o.decodePathSegment(R):R}else{var A=!1;x.charAt(0)==="/"&&(x=x.substring(1)),x.match(/\.?\//)&&(A=!0);var $=new RegExp(c(this.filename())+"$");return x=o.recodePath(x),this._parts.path=this._parts.path.replace($,x),A?this.normalizePath(E):this.build(!E),this}},l.suffix=function(x,E){if(this._parts.urn)return x===void 0?"":this;if(x===void 0||x===!0){if(!this._parts.path||this._parts.path==="/")return"";var b=this.filename(),R=b.lastIndexOf("."),A,$;return R===-1?"":(A=b.substring(R+1),$=/^[a-z0-9%]+$/i.test(A)?A:"",x?o.decodePathSegment($):$)}else{x.charAt(0)==="."&&(x=x.substring(1));var G=this.suffix(),k;if(G)x?k=new RegExp(c(G)+"$"):k=new RegExp(c("."+G)+"$");else{if(!x)return this;this._parts.path+="."+o.recodePath(x)}return k&&(x=o.recodePath(x),this._parts.path=this._parts.path.replace(k,x)),this.build(!E),this}},l.segment=function(x,E,b){var R=this._parts.urn?":":"/",A=this.path(),$=A.substring(0,1)==="/",G=A.split(R);if(x!==void 0&&typeof x!="number"&&(b=E,E=x,x=void 0),x!==void 0&&typeof x!="number")throw new Error('Bad segment "'+x+'", must be 0-based integer');if($&&G.shift(),x<0&&(x=Math.max(G.length+x,0)),E===void 0)return x===void 0?G:G[x];if(x===null||G[x]===void 0)if(d(E)){G=[];for(var k=0,z=E.length;k"u"?!0:typeof s!="string"?!1:(t=t.map(i=>i.toLowerCase()),t.includes(s.toLowerCase()))}function yet(s,t=!1){return Fw(s,_et,t)}class PL extends v0{constructor(t,e=null,i={},n=[]){super(t,i,["_context"].concat(n)),this._context||(this._context=e)}getAbsoluteUrl(t=!0){return this._context?fet(this.href,this._context.getAbsoluteUrl(),t):this.href.includes("://")?this.href:null}getContext(){return this._context}canBrowserDisplayImage(t=!1){if(typeof this.href!="string"||!t&&typeof this.type>"u")return!1;let e=new yy(this.href),i=e.protocol().toLowerCase(),n=e.suffix().toLowerCase();return Ri(i)&&!sb.includes(i)?!1:Ri(this.type)&&ib.includes(this.type.toLowerCase())?!0:!!(typeof this.type>"u"&&Ri(n)&&(n==="jpg"||ib.includes("image/"+n)))}isType(t){return Ri(this.type)&&Fw(this.type,t)}isGeoTIFF(){return this.isType(IL)}isCOG(){return this.isType(RL)}isHTTP(){let t=this.getAbsoluteUrl(!1).protocol().toLowerCase();return Ri(t)&&sb.includes(t)}}class Nw extends PL{constructor(t,e=null){super(t,e)}isLink(){return!0}getObjectType(){return"Link"}static fromLinks(t,e=null){return Array.isArray(t)?t.map(i=>xi(i)?new Nw(i,e):i):[]}}class AL extends v0{constructor(t,e=null,i={},n=[]){if(super(t,Object.assign({links:Nw.fromLinks},i),["_url"].concat(n)),!this._url&&(this._url=e,!this._url)){let r=this.getSelfLink();r&&(this._url=r.href)}}getAbsoluteUrl(){return this._url}setAbsoluteUrl(t){this._url=t}getStacLinksWithRel(t,e=!0){return this.getLinksWithRels([t]).filter(i=>yet(i.type,e))}getStacLinkWithRel(t,e=!0){const i=this.getStacLinksWithRel(t,e);return i.length>0?i[0]:null}getLinks(){return Array.isArray(this.links)?this.links.filter(t=>xi(t)&&Ri(t.href)):[]}getLinkWithRel(t){return this.getLinks().find(e=>e.rel===t)||null}getLinksWithRels(t){return this.getLinks().filter(e=>t.includes(e.rel))}getLinksWithOtherRels(t){return this.getLinks().filter(e=>!t.includes(e.rel))}getSelfLink(){return this.getStacLinkWithRel("self")}getRootLink(){return this.getStacLinkWithRel("root")}getParentLink(){return this.getStacLinkWithRel("parent")}}class LL extends AL{constructor(t,e=null,i={},n=[]){super(t,e,i,n)}getAll(){return[]}}class Qo extends PL{constructor(t,e=null,i=null){super(t,i,{},["_key"]),this._key||(this._key=e)}getObjectType(){return"Asset"}isAsset(){return!0}getAbsoluteUrl(t=!0){return this.isDefinition()?null:super.getAbsoluteUrl(t)}getKey(){return this._key}getMetadata(t){if(typeof this[t]<"u")return this[t];if(this._context)return this._context.getMetadata(t)}getBands(){return TL(this["eo:bands"],this["raster:bands"])}findVisualBands(){let t={red:null,green:null,blue:null},e=this.getBands();for(let i in e){let n=parseInt(i,10),r=e[n];xi(r)&&Ri(r.common_name)&&r.common_name in t&&(t[r.common_name]={index:n,band:r})}return Object.values(t).every(i=>i!==null)?t:null}findBand(t,e="name",i=null){Array.isArray(t)||(t=[t]),xi(i)||(i=this.getBands());let n=i.findIndex(r=>xi(r)&&t.includes(r[e]));return n>=0?{index:n,band:i[n]}:null}getBand(t){return xi(t)||t===null?t:this.getBands()[t]||null}getMinMaxValues(t=null){t=this.getBand(t);const e={minimum:null,maximum:null},i=a=>a.minimum!==null&&a.maximum!==null;if(t&&(xi(t.statistics)&&(typeof t.statistics.minimum=="number"&&(e.minimum=t.statistics.minimum),typeof t.statistics.maximum=="number"&&(e.maximum=t.statistics.maximum),i(e))||xi(t.histogram)&&(typeof t.histogram.min=="number"&&(e.minimum=t.histogram.min),typeof t.histogram.max=="number"&&(e.maximum=t.histogram.max),i(e))))return e;let n=this.getMetadata("classification:classes");if(Array.isArray(n)&&(n.reduce((a,l)=>(a.minimum=Math.min(a.minimum,l.value),a.maximum=Math.max(a.maximum,l.value),a),e),i(e)))return e;let r=this.getMetadata("file:values");if(Array.isArray(r)&&(r.reduce((a,l)=>(a.minimum=Math.min(a.minimum,...l.values),a.maximum=Math.max(a.maximum,...l.values),a),e),i(e)))return e;let o=xi(t)&&t.data_type||this.getMetadata("file:data_type");return o&&(e.minimum=oet(o),e.maximum=aet(o)),e}getNoDataValues(t=null){t=this.getBand(t);let e=[];if(t&&typeof t.nodata<"u")e.push(t.nodata);else{let i=this.getMetadata("file:nodata");if(typeof i<"u")e=i;else{let n=this.getMetadata("classification:classes");Array.isArray(n)&&(e=n.filter(r=>!!r.nodata).map(r=>r.value))}}return e.map(i=>i==="nan"?NaN:i==="+inf"?1/0:i==="-inf"?-1/0:i)}isDefinition(){return!Ri(this.href)}isHTTP(){return this.isDefinition()?null:super.isHTTP()}hasRole(t,e=!1){return Array.isArray(t)||(t=[t]),e&&t.includes(this.getKey())?!0:Array.isArray(this.roles)&&!!this.roles.find(i=>t.includes(i))}static fromAssets(t,e=null){let i={};if(xi(t))for(let n in t)i[n]=new Qo(t[n],n,e);return i}}class Dg extends AL{constructor(t,e=null,i={},n=[]){super(t,e,i,n)}getTemporalExtent(){return null}getTemporalExtents(){return[]}getIcons(t=!0){return this.getLinksWithRels(["icon"]).filter(e=>e.canBrowserDisplayImage(t))}getThumbnails(t=!0,e=null){let i=this.getAssetsWithRoles(["thumbnail","overview"],!0);if(i.length===0&&(i=this.getLinksWithRels(["preview"])),t&&(i=i.filter(n=>n.canBrowserDisplayImage())),e&&i.length>1){let n=r=>Array.isArray(r.roles)&&r.roles.includes(e)||r.getKey()===e;i=i.filter(n).concat(i.filter(r=>!n(r)))}return i}getDefaultGeoTIFF(t=!0,e=!1){var i;return(i=this.rankGeoTIFFs(t,e)[0])==null?void 0:i.asset}rankGeoTIFFs(t=!0,e=!1,i=null,n=null){xi(i)||(i={data:1,visual:2,thumbnail:2,overview:3});let r=[],o=this.getAssetsByTypes(IL);t&&(o=o.filter(l=>l.isHTTP()&&(!e||l.isCOG())));let a=Object.entries(i);for(let l of o){let h=0;if(a.length>0){let c=a.filter(([u])=>l.hasRole(u,!0)).map(([,u])=>u);c.length>0&&(h+=Math.max(...c))}!e&&l.isCOG()&&(h+=2),l.findVisualBands()&&(h+=1),typeof n=="function"&&(h+=n(l)),r.push({asset:l,score:h})}return r.sort((l,h)=>h.score-l.score),r}findVisualAssets(){let t={red:null,green:null,blue:null},e=Object.keys(t),i=this.getAssets();for(let n of i){let r=n.getBands();if(r.length!==1)continue;let o=n.findBand(e,"common_name",r);o&&(t[o.band.common_name]=n)}return Object.values(t).every(n=>n!==null)?t:null}getAsset(t){return xi(this.assets)&&this.assets[t]||null}getAssets(){return xi(this.assets)?Object.values(this.assets):[]}getAssetsWithRoles(t,e=!1){return this.getAssets().filter(i=>i.hasRole(t,e))}getAssetWithRole(t,e=!1){return this.getAssetsWithRoles([t],e)[0]||null}getAssetsByTypes(t){return this.getAssets().filter(e=>Fw(e.type,t))}equals(t){return this===t?!0:!(t instanceof Dg)||this.getObjectType()!==t.getObjectType()?!1:!!(this.id&&this.id===t.id)}}class OL extends Dg{constructor(t,e=null,i={},n=[]){super(t,e,i,n)}getObjectType(){return this.type}getSearchLink(t=null){let e=this.getStacLinksWithRel("search");return t?e[0]||null:e.find(i=>i.method===t||!t&&!i.method)||null}getApiCollectionsLink(){return this.getStacLinkWithRel("data")}getApiItemsLink(){return this.getStacLinkWithRel("items")}getChildLinks(){return this.getStacLinksWithRel("child")}getItemLinks(){return this.getStacLinksWithRel("item")}}class xet extends OL{constructor(t,e=null){super(t,e)}}function Tu(s){if(Ri(s)&&s.length>=10)try{let t=s.match(/^(-?\d{1,})-(\d\d)-(\d\d)[T ](\d\d):(\d\d):(\d\d)(?:\.(\d*))?(?:Z|[+-]00:00)?$/i).slice(1).map(e=>parseInt(e,10));return new Date(Date.UTC(t[0],t[1]-1,t[2],t[3],t[4],t[5],t[6]||0))}catch{return null}return null}function vet(s,t){return new Date(s.valueOf()+(t-s)/2)}function FL(s){if(!Array.isArray(s)||s.length===0)return null;let t,e;const i=(n,r,o)=>typeof n>"u"?r:n===null||r===null?null:o(n,r);return s.forEach(([n,r])=>{t=i(t,n,Math.min),e=i(e,r,Math.max)}),[t===null?null:new Date(t),e===null?null:new Date(e)]}class NL extends OL{constructor(t,e=null){const i={assets:Qo.fromAssets,item_assets:Qo.fromAssets};super(t,e,i)}toGeoJSON(){let t=SL(this.getBoundingBoxes());return t&&(t.id=this.id),t}getBoundingBox(){let t=this.getRawBoundingBoxes();return t.length>0&&$n(t[0])?t[0]:null}getBoundingBoxes(){let t=this.getRawBoundingBoxes();return t.length===1&&$n(t[0])?t:t.length>1?t.filter((e,i)=>i>0&&$n(e)):[]}getRawBoundingBoxes(){var t,e;let i=(e=(t=this.extent)==null?void 0:t.spatial)==null?void 0:e.bbox;return Array.isArray(i)&&i.length>0?i:[]}getTemporalExtent(){return this.getTemporalExtents()[0]||null}getTemporalExtents(){var t,e;let i=(e=(t=this.extent)==null?void 0:t.temporal)==null?void 0:e.interval;return Array.isArray(i)&&i.length>0?i.filter(n=>Array.isArray(n)&&(Ri(n[0])||Ri(n[1]))).map(n=>n.map(r=>Tu(r))):[]}getSummary(t){return this.summaries[t]}getBands(){let t=this.getSummary("eo:bands"),e=this.getSummary("raster:bands"),i=[t,e].filter(n=>Array.isArray(n));return i.length>=2?TL(...i):i.length===1?i[0]:[]}}class wet extends LL{constructor(t,e=null){const i={collections:n=>n.map(r=>new NL(r))};super(t,e,i)}getObjectType(){return"CollectionCollection"}getAll(){return this.collections}isCollectionCollection(){return!0}toGeoJSON(){return{type:"FeatureCollection",features:this.collections.map(t=>t.toGeoJSON()).filter(t=>t!==null)}}getBoundingBox(){return bL(this.getBoundingBoxes())}getBoundingBoxes(){return this.collections.map(t=>t.getBoundingBox())}getTemporalExtent(){return FL(this.getTemporalExtents())}getTemporalExtents(){return this.collections.map(t=>t.getTemporalExtent())}}class DL extends Dg{constructor(t,e=null){super(t,e,{assets:Qo.fromAssets})}getObjectType(){return"Item"}toGeoJSON(){return this.toJSON()}getBoundingBox(){return $n(this.bbox)?this.bbox:null}getBoundingBoxes(){return $n(this.bbox)?[this.bbox]:[]}getDateTime(){let t=Tu(this.properties.datetime);if(!t){let e=Tu(this.properties.start_datetime),i=Tu(this.properties.end_datetime);return e&&i?vet(e,i):e||i}return t}getTemporalExtent(){return this.getTemporalExtents()[0]||null}getTemporalExtents(){let t=[];return Ri(this.properties.start_datetime)||Ri(this.properties.end_datetime)?t=[[this.properties.start_datetime||null,this.properties.end_datetime||null]]:Ri(this.properties.datetime)&&(t=[[this.properties.datetime,this.properties.datetime]]),t.map(e=>e.map(i=>Tu(i)))}getMetadata(t){return this.properties[t]}getBands(){let t=this.getMetadata("eo:bands");return Array.isArray(t)?t:[]}getCollectionLink(){return this.getStacLinkWithRel("collection")}}class Eet extends LL{constructor(t,e=null){const i={features:n=>n.map(r=>new DL(r))};super(t,e,i)}getObjectType(){return"ItemCollection"}getAll(){return this.features}toGeoJSON(){return this.toJSON()}getBoundingBox(){return bL(this.getBoundingBoxes())}getBoundingBoxes(){return this.features.map(t=>t.getBoundingBox())}getTemporalExtent(){return FL(this.getTemporalExtents())}getTemporalExtents(){return this.features.map(t=>t.getTemporalExtent())}}function Met(s,t=!0,e=!1){return t&&(s=net.stac(s,e)),s.type==="Feature"?new DL(s):s.type==="FeatureCollection"?new Eet(s):s.type==="Collection"||!s.type&&typeof s.extent<"u"&&typeof s.license<"u"?new NL(s):!s.type&&Array.isArray(s.collections)?new wet(s):new xet(s)}class nb extends d0{constructor(t){super({...t,state:"loading"}),jx(this,"loadImage",i=>new Promise((n,r)=>{const o=new Image;o.addEventListener("load",()=>n(o)),o.addEventListener("error",()=>r(new Error("load failed"))),o.src=i}));const e=new aw(t.url);e.getHeader().then(i=>{this.tileGrid.minZoom=i.minZoom,this.tileGrid.maxZoom=i.maxZoom,this.setLoader(async(n,r,o)=>{const a=await e.getZxy(n,r,o),l=URL.createObjectURL(new Blob([a.data])),h=await this.loadImage(l);return URL.revokeObjectURL(l),h}),this.setState("ready")})}}class bet extends y0{constructor(t){super({...t,state:"loading",url:"pmtiles://"+t.url+"/{z}/{x}/{y}",format:new xP}),jx(this,"tileLoadFunction",(e,i)=>{const n=new RegExp(/pmtiles:\/\/(.+)\/(\d+)\/(\d+)\/(\d+)/),r=i.match(n),o=+r[2],a=+r[3],l=+r[4];e.setLoader((h,c,u)=>{e.setState(X.LOADING),this.pmtiles_.getZxy(o,a,l).then(d=>{if(d){const g=e.getFormat();e.setFeatures(g.readFeatures(d.data,{extent:h,featureProjection:u})),e.setState(X.LOADED)}else e.setFeatures([]),e.setState(X.EMPTY)}).catch(d=>{e.setFeatures([]),e.setState(X.ERROR)})})}),this.pmtiles_=new aw(t.url),this.pmtiles_.getHeader().then(e=>{this.tileGrid.minZoom=e.minZoom,this.tileGrid.maxZoom=e.maxZoom,this.setTileLoadFunction(this.tileLoadFunction),this.setState("ready")})}}let Dw=null;function Tet(){return!!Dw}function kL(s){Dw=s;const t=Object.keys(s.defs),e=t.length;let i,n;for(i=0;i0&&(e.nodata=o[0]),t.length>0&&(e.bands=t),e}async function rb(s,t=void 0){let e=t;if(Tet()){const i=s.getMetadata("proj:epsg");if(i)try{e=await Ret(i)}catch{}}return e}function ob(s,t){const e=s.clone();return t.hasOnlyBounds()||e.setFill(null),e}function Let(s){let t=s.href;if(t.includes("{s}"))if(Array.isArray(s["href:servers"])&&s["href:servers"].length>0){const e=Math.random()*s["href:servers"].length|0;t=t.replace("{s}",s["href:servers"][e])}else return null;return t}async function Oet(s){try{const t=new URL(s);t.searchParams.set("service","wmts"),t.searchParams.set("request","GetCapabilities");const e=await fetch(t);return new kv().read(await e.text())}catch{return null}}class kw extends i0{constructor(t){const e={};if(["opacity","visible","zIndex","minResolution","maxResolution","minZoom","maxZoom","properties"].forEach(i=>e[i]=t[i]),super(e),this.getSourceOptions_=t.getSourceOptions,this.data_,this.assets_=null,this.bands_=[],this.crossOrigin_=t.crossOrigin||null,this.displayFootprint_=t.displayFootprint!==!1,this.displayGeoTiffByDefault_=!!t.displayGeoTiffByDefault,this.displayPreview_=!!t.displayPreview,this.displayOverview_=t.displayOverview!==!1,this.displayWebMapLink_=t.displayWebMapLink||!1,this.buildTileUrlTemplate_=t.buildTileUrlTemplate||null,this.useTileLayerAsFallback_=t.useTileLayerAsFallback||!1,this.boundsStyle_=t.boundsStyle||Iet,this.collectionStyle_=t.collectionStyle||Pet,this.boundsLayer_=null,t.data){try{this.configure_(t.data,t.url,t.assets,t.bands)}catch(i){this.handleError_(i)}return}if(!t.url)throw new Error("Either url or data must be provided");fetch(t.url).then(i=>i.json()).then(i=>this.configure_(i,t.url,t.assets,t.bands)).catch(i=>this.handleError_(i))}getBoundsLayer(){return this.boundsLayer_}handleError_(t){this.dispatchEvent(new WJ(t))}configure_(t,e=null,i=null,n=[]){t instanceof Qo||t instanceof Dg?this.data_=t:this.data_=Met(t),e&&e.includes("://")&&this.data_.setAbsoluteUrl(e),this.bands_=n,this.boundsLayer_=this.addFootprint_();const r=()=>{this.boundsLayer_&&this.boundsLayer_.setStyle(ob(this.boundsStyle_,this))};this.getLayers().on("add",r),this.getLayers().on("remove",r),this.setAssets(i).then(()=>this.dispatchEvent("assetsready")).catch(o=>this.handleError_(o)),this.dispatchEvent("sourceready")}async addApiCollection_(){const t=this.getData().getAll().map(e=>{const i=new kw({data:e,crossOrigin:this.crossOrigin_,boundsStyle:this.collectionStyle_,displayGeoTiffByDefault:this.displayGeoTiffByDefault_,displayOverview:this.displayOverview_,displayPreview:this.displayPreview_,displayFootprint:this.displayFootprint_});return this.addLayer_(i),i});return await Promise.all(t)}async addStacAssets_(){let t=this.getAssets();if(t===null){t=[];const i=this.getData().getDefaultGeoTIFF(!0,!this.displayGeoTiffByDefault_);if(i)t.push(i);else{const n=this.getData().getThumbnails().filter(r=>!Array.isArray(r.roles)||!r.roles.includes("example"));n.length>0&&t.push(n[0])}}const e=t.map(i=>this.addImagery_(i));return await Promise.all(e)}async addImagery_(t){if(t){if(t.isGeoTIFF())return await this.addGeoTiff_(t);if(t.canBrowserDisplayImage())return await this.addThumbnail_(t)}}async addThumbnail_(t){if(!this.displayPreview_)return;let e={url:t.getAbsoluteUrl(),projection:await rb(t,"EPSG:4326"),imageExtent:t.getContext().getBoundingBox(),crossOrigin:this.crossOrigin_};this.getSourceOptions_&&(e=await this.getSourceOptions_(Fe.ImageStatic,e,t));const i=new ew({source:new hL(e)});return this.addLayer_(i,t),i}async addWebMapLinks_(){const t=this.getWebMapLinks();if(t.length>0)return await this.addLayerForLink(t[0])}async addLayerForLink(t){const e=Let(t);if(!e)return;const i={attributions:t.getMetadata("attribution")||this.data_.getMetadata("attribution"),crossOrigin:this.crossOrigin_,url:e},n=async(o,a)=>(this.getSourceOptions_&&(a=await this.getSourceOptions_(o,a,t)),a),r=[];switch(t.rel){case"pmtiles":const o=await new aw(i.url).getHeader();let a;switch(o.tileType){case th.Mvt:a=new bet(await n(Fe.PMTilesVector,i));break;case th.Avif:case th.Jpeg:case th.Png:case th.Webp:a=new nb(await n(Fe.PMTilesRaster,i));break;default:return}r.push(a);break;case"tilejson":r.push(new gL(await n(Fe.TileJSON,i)));break;case"wms":if(!Array.isArray(t["wms:layers"]))break;for(const c in t["wms:layers"]){const u=t["wms:layers"][c]||"";let d="";Array.isArray(t["wms:styles"])&&typeof t["wms:styles"][c]=="string"&&(d=t["wms:styles"][c]);const g=Object.assign({LAYERS:u,STYLES:d},t["wms:dimensions"]);typeof t["wms:transparent"]=="boolean"&&(g.TRANSPARENT=String(t["wms:transparent"])),typeof t.type=="string"&&t.type.startsWith("image/")&&(g.FORMAT=t.type);const f=await n(Fe.TileWMS,Object.assign({},i,{params:g}));r.push(new _L(f))}break;case"wmts":const l=await Oet(e);if(!l)return;const h=Array.isArray(t["wmts:layer"])?t["wmts:layer"]:[t["wmts:layer"]];for(const c of h){let u=Object.assign({},i,{layer:c});typeof t.type=="string"&&t.type.startsWith("image/")&&(u.format=t.type),u=await n(Fe.WMTS,u),r.push(new yL(xL(l,u)))}break;case"xyz":r.push(new hl(await n(Fe.XYZ,i)));break;default:return}return r.map(o=>{let a;return o instanceof y0?a=new vA({source:o,declutter:!0}):o instanceof nb?a=new Hp({source:o}):a=new Yp({source:o}),this.addLayer_(a,t),a})}async addGeoTiff_(t){if(!this.displayOverview_)return;if(this.buildTileUrlTemplate_&&!this.useTileLayerAsFallback_)return await this.addTileLayerForImagery_(t);let e={sources:[Aet(t,this.bands_)]};const i=await rb(t);i&&(e.projection=i),this.getSourceOptions_&&(e=await this.getSourceOptions_(Fe.GeoTIFF,e,t));const n=async(r,o)=>(o&&this.getLayers().remove(o),await this.addTileLayerForImagery_(r));try{const r=new bw(e),o=new Hp({source:r});if(this.useTileLayerAsFallback_){const a=()=>n(t,o);r.on("error",a),r.on("tileloaderror",a),r.on("change",()=>{r.getState()==="error"&&n(t,o)}),o.on("error",a),await r.getView()}return this.addLayer_(o,t),o}catch(r){if(this.useTileLayerAsFallback_)return await n(t,null);this.handleError_(r)}}async addTileLayerForImagery_(t){let e={crossOrigin:this.crossOrigin_,url:this.buildTileUrlTemplate_(t)};this.getSourceOptions_&&(e=await this.getSourceOptions_(Fe.XYZ,e,t));const i=new Yp({source:new hl(e)});return this.addLayer_(i,t),i}addLayer_(t,e,i=0){t.set("stac",e),t.setZIndex(i),this.getLayers().push(t)}addFootprint_(){let t=null;const e=this.getData();if(e.isItemCollection()||e.isCollectionCollection()?t=SL(e.getBoundingBox()):t=e.toGeoJSON(),t){const i=new DI,n=new s0({format:i,loader:(o,a,l)=>{const h=i.readFeatures(t,{featureProjection:l});n.addFeatures(h)}}),r=new Yv({source:n,style:ob(this.boundsStyle_,this),visible:this.displayFootprint_});return r.set("bounds",!0),this.addLayer_(r,e,1),r}return null}async updateLayers_(){const t=this.getLayers();for(let i=t.getLength()-1;i>=0;i--){const n=t.item(i).get("stac");n&&(n.isLink()||n.isAsset())&&t.removeAt(i)}const e=this.getData();e.isItemCollection()||e.isCollectionCollection()?await this.addApiCollection_():(e.isItem()||e.isCollection())&&await this.addStacAssets_(),this.displayWebMapLink_&&(Array.isArray(this.displayWebMapLink_)||this.hasOnlyBounds())&&await this.addWebMapLinks_()}hasOnlyBounds(){const t=this.getBoundsLayer();return typeof this.getLayersArray().find(e=>e!==t)>"u"}getWebMapLinks(){let t=["xyz","tilejson","pmtiles","wmts","wms"];typeof this.displayWebMapLink_=="string"&&(t=[this.displayWebMapLink_]);let e=this.data_.getLinksWithRels(t);return Array.isArray(this.displayWebMapLink_)?e=this.displayWebMapLink_.map(i=>typeof i=="string"?e.find(r=>r.id===i)||null:i).filter(i=>!!i):e.sort((i,n)=>{const r=t.indexOf(i.rel),o=t.indexOf(n.rel);return r-o}),e}async setAssets(t){Array.isArray(t)?this.assets_=t.map(e=>typeof e=="string"?this.getData().getAsset(e):e instanceof Qo?e:new Qo(e)):this.assets_=null,await this.updateLayers_()}getData(){return this.data_}getAssets(){return this.assets_}getExtent(){if(!this.boundsLayer_)return;const t=this.boundsLayer_.getMapInternal();if(!t)return;const e=t.getView();if(!e)return;const i=this.getData();if(!i)return;const n=i.getBoundingBox();if(n)return ev(n,"EPSG:4326",e.getProjection())}}function Fet(s){s("EPSG:4326","+title=WGS 84 (long/lat) +proj=longlat +ellps=WGS84 +datum=WGS84 +units=degrees"),s("EPSG:4269","+title=NAD83 (long/lat) +proj=longlat +a=6378137.0 +b=6356752.31414036 +ellps=GRS80 +datum=NAD83 +units=degrees"),s("EPSG:3857","+title=WGS 84 / Pseudo-Mercator +proj=merc +a=6378137 +b=6378137 +lat_ts=0.0 +lon_0=0.0 +x_0=0.0 +y_0=0 +k=1.0 +units=m +nadgrids=@null +no_defs"),s.WGS84=s["EPSG:4326"],s["EPSG:3785"]=s["EPSG:3857"],s.GOOGLE=s["EPSG:3857"],s["EPSG:900913"]=s["EPSG:3857"],s["EPSG:102113"]=s["EPSG:3857"]}var cl=1,ul=2,Dh=3,Net=4,xy=5,ab=6378137,Det=6356752314e-3,lb=.0066943799901413165,Ju=484813681109536e-20,K=Math.PI/2,ket=.16666666666666666,$et=.04722222222222222,Get=.022156084656084655,tt=1e-10,Ls=.017453292519943295,ur=57.29577951308232,ye=Math.PI/4,zd=Math.PI*2,es=3.14159265359,Fi={};Fi.greenwich=0;Fi.lisbon=-9.131906111111;Fi.paris=2.337229166667;Fi.bogota=-74.080916666667;Fi.madrid=-3.687938888889;Fi.rome=12.452333333333;Fi.bern=7.439583333333;Fi.jakarta=106.807719444444;Fi.ferro=-17.666666666667;Fi.brussels=4.367975;Fi.stockholm=18.058277777778;Fi.athens=23.7163375;Fi.oslo=10.722916666667;const jet={ft:{to_meter:.3048},"us-ft":{to_meter:1200/3937}};var hb=/[\s_\-\/\(\)]/g;function ca(s,t){if(s[t])return s[t];for(var e=Object.keys(s),i=t.toLowerCase().replace(hb,""),n=-1,r,o;++n=this.text.length)return;s=this.text[this.place++]}switch(this.state){case Ud:return this.neutral(s);case $L:return this.keyword(s);case tm:return this.quoted(s);case jL:return this.afterquote(s);case GL:return this.number(s);case $w:return}};xo.prototype.afterquote=function(s){if(s==='"'){this.word+='"',this.state=tm;return}if(w0.test(s)){this.word=this.word.trim(),this.afterItem(s);return}throw new Error(`havn't handled "`+s+'" in afterquote yet, index '+this.place)};xo.prototype.afterItem=function(s){if(s===","){this.word!==null&&this.currentObject.push(this.word),this.word=null,this.state=Ud;return}if(s==="]"){this.level--,this.word!==null&&(this.currentObject.push(this.word),this.word=null),this.state=Ud,this.currentObject=this.stack.pop(),this.currentObject||(this.state=$w);return}};xo.prototype.number=function(s){if(zL.test(s)){this.word+=s;return}if(w0.test(s)){this.word=parseFloat(this.word),this.afterItem(s);return}throw new Error(`havn't handled "`+s+'" in number yet, index '+this.place)};xo.prototype.quoted=function(s){if(s==='"'){this.state=jL;return}this.word+=s};xo.prototype.keyword=function(s){if(Bet.test(s)){this.word+=s;return}if(s==="["){var t=[];t.push(this.word),this.level++,this.root===null?this.root=t:this.currentObject.push(t),this.stack.push(this.currentObject),this.currentObject=t,this.state=Ud;return}if(w0.test(s)){this.afterItem(s);return}throw new Error(`havn't handled "`+s+'" in keyword yet, index '+this.place)};xo.prototype.neutral=function(s){if(Uet.test(s)){this.word=s,this.state=$L;return}if(s==='"'){this.word="",this.state=tm;return}if(zL.test(s)){this.word=s,this.state=GL;return}if(w0.test(s)){this.afterItem(s);return}throw new Error(`havn't handled "`+s+'" in neutral yet, index '+this.place)};xo.prototype.output=function(){for(;this.place0?90:-90),s.lat_ts=s.lat1):!s.lat_ts&&s.lat0&&s.projName==="Polar_Stereographic"&&(s.lat_ts=s.lat0,s.lat0=tr(s.lat0>0?90:-90))}function UL(s){var t=Wet(s),e=t.shift(),i=t.shift();t.unshift(["name",i]),t.unshift(["type",e]);var n={};return yh(t,n),Yet(n),n}function ti(s){var t=this;if(arguments.length===2){var e=arguments[1];typeof e=="string"?e.charAt(0)==="+"?ti[s]=vy(arguments[1]):ti[s]=UL(arguments[1]):ti[s]=e}else if(arguments.length===1){if(Array.isArray(s))return s.map(function(i){Array.isArray(i)?ti.apply(t,i):ti(i)});if(typeof s=="string"){if(s in ti)return ti[s]}else"EPSG"in s?ti["EPSG:"+s.EPSG]=s:"ESRI"in s?ti["ESRI:"+s.ESRI]=s:"IAU2000"in s?ti["IAU2000:"+s.IAU2000]=s:console.log(s);return}}Fet(ti);function qet(s){return typeof s=="string"}function Zet(s){return s in ti}var Het=["PROJECTEDCRS","PROJCRS","GEOGCS","GEOCCS","PROJCS","LOCAL_CS","GEODCRS","GEODETICCRS","GEODETICDATUM","ENGCRS","ENGINEERINGCRS"];function Ket(s){return Het.some(function(t){return s.indexOf(t)>-1})}var Jet=["3857","900913","3785","102113"];function Qet(s){var t=ca(s,"authority");if(t){var e=ca(t,"epsg");return e&&Jet.indexOf(e)>-1}}function tst(s){var t=ca(s,"extension");if(t)return ca(t,"proj4")}function est(s){return s[0]==="+"}function sst(s){if(qet(s)){if(Zet(s))return ti[s];if(Ket(s)){var t=UL(s);if(Qet(t))return ti["EPSG:3857"];var e=tst(t);return e?vy(e):t}if(est(s))return vy(s)}else return s}function ub(s,t){s=s||{};var e,i;if(!t)return s;for(i in t)e=t[i],e!==void 0&&(s[i]=e);return s}function wr(s,t,e){var i=s*t;return e/Math.sqrt(1-i*i)}function kg(s){return s<0?-1:1}function rt(s){return Math.abs(s)<=es?s:s-kg(s)*zd}function Gn(s,t,e){var i=s*e,n=.5*s;return i=Math.pow((1-i)/(1+i),n),Math.tan(.5*(K-t))/i}function Bd(s,t){for(var e=.5*s,i,n,r=K-2*Math.atan(t),o=0;o<=15;o++)if(i=s*Math.sin(r),n=K-2*Math.atan(t*Math.pow((1-i)/(1+i),e))-r,r+=n,Math.abs(n)<=1e-10)return r;return-9999}function ist(){var s=this.b/this.a;this.es=1-s*s,"x0"in this||(this.x0=0),"y0"in this||(this.y0=0),this.e=Math.sqrt(this.es),this.lat_ts?this.sphere?this.k0=Math.cos(this.lat_ts):this.k0=wr(this.e,Math.sin(this.lat_ts),Math.cos(this.lat_ts)):this.k0||(this.k?this.k0=this.k:this.k0=1)}function nst(s){var t=s.x,e=s.y;if(e*ur>90&&e*ur<-90&&t*ur>180&&t*ur<-180)return null;var i,n;if(Math.abs(Math.abs(e)-K)<=tt)return null;if(this.sphere)i=this.x0+this.a*this.k0*rt(t-this.long0),n=this.y0+this.a*this.k0*Math.log(Math.tan(ye+.5*e));else{var r=Math.sin(e),o=Gn(this.e,e,r);i=this.x0+this.a*this.k0*rt(t-this.long0),n=this.y0-this.a*this.k0*Math.log(o)}return s.x=i,s.y=n,s}function rst(s){var t=s.x-this.x0,e=s.y-this.y0,i,n;if(this.sphere)n=K-2*Math.atan(Math.exp(-e/(this.a*this.k0)));else{var r=Math.exp(-e/(this.a*this.k0));if(n=Bd(this.e,r),n===-9999)return null}return i=rt(this.long0+t/(this.a*this.k0)),s.x=i,s.y=n,s}var ost=["Mercator","Popular Visualisation Pseudo Mercator","Mercator_1SP","Mercator_Auxiliary_Sphere","merc"];const ast={init:ist,forward:nst,inverse:rst,names:ost};function lst(){}function db(s){return s}var hst=["longlat","identity"];const cst={init:lst,forward:db,inverse:db,names:hst};var ust=[ast,cst],Uf={},em=[];function BL(s,t){var e=em.length;return s.names?(em[e]=s,s.names.forEach(function(i){Uf[i.toLowerCase()]=e}),this):(console.log(t),!0)}function dst(s){if(!s)return!1;var t=s.toLowerCase();if(typeof Uf[t]<"u"&&em[Uf[t]])return em[Uf[t]]}function gst(){ust.forEach(BL)}const fst={start:gst,add:BL,get:dst};var $t={};$t.MERIT={a:6378137,rf:298.257,ellipseName:"MERIT 1983"};$t.SGS85={a:6378136,rf:298.257,ellipseName:"Soviet Geodetic System 85"};$t.GRS80={a:6378137,rf:298.257222101,ellipseName:"GRS 1980(IUGG, 1980)"};$t.IAU76={a:6378140,rf:298.257,ellipseName:"IAU 1976"};$t.airy={a:6377563396e-3,b:635625691e-2,ellipseName:"Airy 1830"};$t.APL4={a:6378137,rf:298.25,ellipseName:"Appl. Physics. 1965"};$t.NWL9D={a:6378145,rf:298.25,ellipseName:"Naval Weapons Lab., 1965"};$t.mod_airy={a:6377340189e-3,b:6356034446e-3,ellipseName:"Modified Airy"};$t.andrae={a:637710443e-2,rf:300,ellipseName:"Andrae 1876 (Den., Iclnd.)"};$t.aust_SA={a:6378160,rf:298.25,ellipseName:"Australian Natl & S. Amer. 1969"};$t.GRS67={a:6378160,rf:298.247167427,ellipseName:"GRS 67(IUGG 1967)"};$t.bessel={a:6377397155e-3,rf:299.1528128,ellipseName:"Bessel 1841"};$t.bess_nam={a:6377483865e-3,rf:299.1528128,ellipseName:"Bessel 1841 (Namibia)"};$t.clrk66={a:63782064e-1,b:63565838e-1,ellipseName:"Clarke 1866"};$t.clrk80={a:6378249145e-3,rf:293.4663,ellipseName:"Clarke 1880 mod."};$t.clrk80ign={a:63782492e-1,b:6356515,rf:293.4660213,ellipseName:"Clarke 1880 (IGN)"};$t.clrk58={a:6378293645208759e-9,rf:294.2606763692654,ellipseName:"Clarke 1858"};$t.CPM={a:63757387e-1,rf:334.29,ellipseName:"Comm. des Poids et Mesures 1799"};$t.delmbr={a:6376428,rf:311.5,ellipseName:"Delambre 1810 (Belgium)"};$t.engelis={a:637813605e-2,rf:298.2566,ellipseName:"Engelis 1985"};$t.evrst30={a:6377276345e-3,rf:300.8017,ellipseName:"Everest 1830"};$t.evrst48={a:6377304063e-3,rf:300.8017,ellipseName:"Everest 1948"};$t.evrst56={a:6377301243e-3,rf:300.8017,ellipseName:"Everest 1956"};$t.evrst69={a:6377295664e-3,rf:300.8017,ellipseName:"Everest 1969"};$t.evrstSS={a:6377298556e-3,rf:300.8017,ellipseName:"Everest (Sabah & Sarawak)"};$t.fschr60={a:6378166,rf:298.3,ellipseName:"Fischer (Mercury Datum) 1960"};$t.fschr60m={a:6378155,rf:298.3,ellipseName:"Fischer 1960"};$t.fschr68={a:6378150,rf:298.3,ellipseName:"Fischer 1968"};$t.helmert={a:6378200,rf:298.3,ellipseName:"Helmert 1906"};$t.hough={a:6378270,rf:297,ellipseName:"Hough"};$t.intl={a:6378388,rf:297,ellipseName:"International 1909 (Hayford)"};$t.kaula={a:6378163,rf:298.24,ellipseName:"Kaula 1961"};$t.lerch={a:6378139,rf:298.257,ellipseName:"Lerch 1979"};$t.mprts={a:6397300,rf:191,ellipseName:"Maupertius 1738"};$t.new_intl={a:63781575e-1,b:63567722e-1,ellipseName:"New International 1967"};$t.plessis={a:6376523,rf:6355863,ellipseName:"Plessis 1817 (France)"};$t.krass={a:6378245,rf:298.3,ellipseName:"Krassovsky, 1942"};$t.SEasia={a:6378155,b:63567733205e-4,ellipseName:"Southeast Asia"};$t.walbeck={a:6376896,b:63558348467e-4,ellipseName:"Walbeck"};$t.WGS60={a:6378165,rf:298.3,ellipseName:"WGS 60"};$t.WGS66={a:6378145,rf:298.25,ellipseName:"WGS 66"};$t.WGS7={a:6378135,rf:298.26,ellipseName:"WGS 72"};var pst=$t.WGS84={a:6378137,rf:298.257223563,ellipseName:"WGS 84"};$t.sphere={a:6370997,b:6370997,ellipseName:"Normal Sphere (r=6370997)"};function mst(s,t,e,i){var n=s*s,r=t*t,o=(n-r)/n,a=0;i?(s*=1-o*(ket+o*($et+o*Get)),n=s*s,o=0):a=Math.sqrt(o);var l=(n-r)/r;return{es:o,e:a,ep2:l}}function _st(s,t,e,i,n){if(!s){var r=ca($t,i);r||(r=pst),s=r.a,t=r.b,e=r.rf}return e&&!t&&(t=(1-1/e)*s),(e===0||Math.abs(s-t)3&&(a.datum_params[3]!==0||a.datum_params[4]!==0||a.datum_params[5]!==0||a.datum_params[6]!==0)&&(a.datum_type=ul,a.datum_params[3]*=Ju,a.datum_params[4]*=Ju,a.datum_params[5]*=Ju,a.datum_params[6]=a.datum_params[6]/1e6+1)),o&&(a.datum_type=Dh,a.grids=o),a.a=e,a.b=i,a.es=n,a.ep2=r,a}var WL={};function xst(s,t){var e=new DataView(t),i=Est(e),n=Sst(e,i),r=Mst(e,n,i),o={header:n,subgrids:r};return WL[s]=o,o}function vst(s){if(s===void 0)return null;var t=s.split(",");return t.map(wst)}function wst(s){if(s.length===0)return null;var t=s[0]==="@";return t&&(s=s.slice(1)),s==="null"?{name:"null",mandatory:!t,grid:null,isNull:!0}:{name:s,mandatory:!t,grid:WL[s]||null,isNull:!1}}function xh(s){return s/3600*Math.PI/180}function Est(s){var t=s.getInt32(8,!1);return t===11?!1:(t=s.getInt32(8,!0),t!==11&&console.warn("Failed to detect nadgrid endian-ness, defaulting to little-endian"),!0)}function Sst(s,t){return{nFields:s.getInt32(8,t),nSubgridFields:s.getInt32(24,t),nSubgrids:s.getInt32(40,t),shiftType:wy(s,56,64).trim(),fromSemiMajorAxis:s.getFloat64(120,t),fromSemiMinorAxis:s.getFloat64(136,t),toSemiMajorAxis:s.getFloat64(152,t),toSemiMinorAxis:s.getFloat64(168,t)}}function wy(s,t,e){return String.fromCharCode.apply(null,new Uint8Array(s.buffer.slice(t,e)))}function Mst(s,t,e){for(var i=176,n=[],r=0;r5e-11?!1:s.datum_type===cl?s.datum_params[0]===t.datum_params[0]&&s.datum_params[1]===t.datum_params[1]&&s.datum_params[2]===t.datum_params[2]:s.datum_type===ul?s.datum_params[0]===t.datum_params[0]&&s.datum_params[1]===t.datum_params[1]&&s.datum_params[2]===t.datum_params[2]&&s.datum_params[3]===t.datum_params[3]&&s.datum_params[4]===t.datum_params[4]&&s.datum_params[5]===t.datum_params[5]&&s.datum_params[6]===t.datum_params[6]:!0}function XL(s,t,e){var i=s.x,n=s.y,r=s.z?s.z:0,o,a,l,h;if(n<-K&&n>-1.001*K)n=-K;else if(n>K&&n<1.001*K)n=K;else{if(n<-K)return{x:-1/0,y:-1/0,z:s.z};if(n>K)return{x:1/0,y:1/0,z:s.z}}return i>Math.PI&&(i-=2*Math.PI),a=Math.sin(n),h=Math.cos(n),l=a*a,o=e/Math.sqrt(1-t*l),{x:(o+r)*h*Math.cos(i),y:(o+r)*h*Math.sin(i),z:(o*(1-t)+r)*a}}function VL(s,t,e,i){var n=1e-12,r=n*n,o=30,a,l,h,c,u,d,g,f,p,m,_,y,v,S=s.x,w=s.y,T=s.z?s.z:0,M,C,I;if(a=Math.sqrt(S*S+w*w),l=Math.sqrt(S*S+w*w+T*T),a/er&&vi.y||g>i.x||ma&&Math.abs(l.y)>a);if(o<0)return console.log("Inverse grid shift iterator failed to converge."),i;i.x=rt(r.x+e.ll[0]),i.y=r.y+e.ll[1]}else isNaN(r.x)||(i.x=s.x+r.x,i.y=s.y+r.y);return i}function fb(s,t){var e={x:s.x/t.del[0],y:s.y/t.del[1]},i={x:Math.floor(e.x),y:Math.floor(e.y)},n={x:e.x-1*i.x,y:e.y-1*i.y},r={x:Number.NaN,y:Number.NaN},o;if(i.x<0||i.x>=t.lim[0]||i.y<0||i.y>=t.lim[1])return r;o=i.y*t.lim[0]+i.x;var a={x:t.cvs[o][0],y:t.cvs[o][1]};o++;var l={x:t.cvs[o][0],y:t.cvs[o][1]};o+=t.lim[0];var h={x:t.cvs[o][0],y:t.cvs[o][1]};o--;var c={x:t.cvs[o][0],y:t.cvs[o][1]},u=n.x*n.y,d=n.x*(1-n.y),g=(1-n.x)*(1-n.y),f=(1-n.x)*n.y;return r.x=g*a.x+d*l.x+f*c.x+u*h.x,r.y=g*a.y+d*l.y+f*c.y+u*h.y,r}function pb(s,t,e){var i=e.x,n=e.y,r=e.z||0,o,a,l,h={};for(l=0;l<3;l++)if(!(t&&l===2&&e.z===void 0))switch(l===0?(o=i,"ew".indexOf(s.axis[l])!==-1?a="x":a="y"):l===1?(o=n,"ns".indexOf(s.axis[l])!==-1?a="y":a="x"):(o=r,a="z"),s.axis[l]){case"e":h[a]=o;break;case"w":h[a]=-o;break;case"n":h[a]=o;break;case"s":h[a]=-o;break;case"u":e[a]!==void 0&&(h.z=o);break;case"d":e[a]!==void 0&&(h.z=-o);break;default:return null}return h}function YL(s){var t={x:s[0],y:s[1]};return s.length>2&&(t.z=s[2]),s.length>3&&(t.m=s[3]),t}function Ost(s){mb(s.x),mb(s.y)}function mb(s){if(typeof Number.isFinite=="function"){if(Number.isFinite(s))return;throw new TypeError("coordinates must be finite numbers")}if(typeof s!="number"||s!==s||!isFinite(s))throw new TypeError("coordinates must be finite numbers")}function Fst(s,t){return(s.datum.datum_type===cl||s.datum.datum_type===ul||s.datum.datum_type===Dh)&&t.datumCode!=="WGS84"||(t.datum.datum_type===cl||t.datum.datum_type===ul||t.datum.datum_type===Dh)&&s.datumCode!=="WGS84"}function sm(s,t,e,i){var n;Array.isArray(e)?e=YL(e):e={x:e.x,y:e.y,z:e.z,m:e.m};var r=e.z!==void 0;if(Ost(e),s.datum&&t.datum&&Fst(s,t)&&(n=new pr("WGS84"),e=sm(s,n,e,i),s=n),i&&s.axis!=="enu"&&(e=pb(s,!1,e)),s.projName==="longlat")e={x:e.x*Ls,y:e.y*Ls,z:e.z||0};else if(s.to_meter&&(e={x:e.x*s.to_meter,y:e.y*s.to_meter,z:e.z||0}),e=s.inverse(e),!e)return;if(s.from_greenwich&&(e.x+=s.from_greenwich),e=Ast(s.datum,t.datum,e),!!e)return t.from_greenwich&&(e={x:e.x-t.from_greenwich,y:e.y,z:e.z||0}),t.projName==="longlat"?e={x:e.x*ur,y:e.y*ur,z:e.z||0}:(e=t.forward(e),t.to_meter&&(e={x:e.x/t.to_meter,y:e.y/t.to_meter,z:e.z||0})),i&&t.axis!=="enu"?pb(t,!0,e):(e&&!r&&delete e.z,e)}var _b=pr("WGS84");function Q_(s,t,e,i){var n,r,o;return Array.isArray(e)?(n=sm(s,t,e,i)||{x:NaN,y:NaN},e.length>2?typeof s.name<"u"&&s.name==="geocent"||typeof t.name<"u"&&t.name==="geocent"?typeof n.z=="number"?[n.x,n.y,n.z].concat(e.splice(3)):[n.x,n.y,e[2]].concat(e.splice(3)):[n.x,n.y].concat(e.splice(2)):[n.x,n.y]):(r=sm(s,t,e,i),o=Object.keys(e),o.length===2||o.forEach(function(a){if(typeof s.name<"u"&&s.name==="geocent"||typeof t.name<"u"&&t.name==="geocent"){if(a==="x"||a==="y"||a==="z")return}else if(a==="x"||a==="y")return;r[a]=e[a]}),r)}function yb(s){return s instanceof pr?s:s.oProj?s.oProj:pr(s)}function Hi(s,t,e){s=yb(s);var i=!1,n;return typeof t>"u"?(t=s,s=_b,i=!0):(typeof t.x<"u"||Array.isArray(t))&&(e=t,t=s,s=_b,i=!0),t=yb(t),e?Q_(s,t,e):(n={forward:function(r,o){return Q_(s,t,r,o)},inverse:function(r,o){return Q_(t,s,r,o)}},i&&(n.oProj=t),n)}var xb=6,qL="AJSAJS",ZL="AFAFAF",vh=65,mi=73,tn=79,Cu=86,Ru=90;const Nst={forward:HL,inverse:Dst,toPoint:KL};function HL(s,t){return t=t||5,Gst(kst({lat:s[1],lon:s[0]}),t)}function Dst(s){var t=Gw(QL(s.toUpperCase()));return t.lat&&t.lon?[t.lon,t.lat,t.lon,t.lat]:[t.left,t.bottom,t.right,t.top]}function KL(s){var t=Gw(QL(s.toUpperCase()));return t.lat&&t.lon?[t.lon,t.lat]:[(t.left+t.right)/2,(t.top+t.bottom)/2]}function t1(s){return s*(Math.PI/180)}function vb(s){return 180*(s/Math.PI)}function kst(s){var t=s.lat,e=s.lon,i=6378137,n=.00669438,r=.9996,o,a,l,h,c,u,d,g=t1(t),f=t1(e),p,m;m=Math.floor((e+180)/6)+1,e===180&&(m=60),t>=56&&t<64&&e>=3&&e<12&&(m=32),t>=72&&t<84&&(e>=0&&e<9?m=31:e>=9&&e<21?m=33:e>=21&&e<33?m=35:e>=33&&e<42&&(m=37)),o=(m-1)*6-180+3,p=t1(o),a=n/(1-n),l=i/Math.sqrt(1-n*Math.sin(g)*Math.sin(g)),h=Math.tan(g)*Math.tan(g),c=a*Math.cos(g)*Math.cos(g),u=Math.cos(g)*(f-p),d=i*((1-n/4-3*n*n/64-5*n*n*n/256)*g-(3*n/8+3*n*n/32+45*n*n*n/1024)*Math.sin(2*g)+(15*n*n/256+45*n*n*n/1024)*Math.sin(4*g)-35*n*n*n/3072*Math.sin(6*g));var _=r*l*(u+(1-h+c)*u*u*u/6+(5-18*h+h*h+72*c-58*a)*u*u*u*u*u/120)+5e5,y=r*(d+l*Math.tan(g)*(u*u/2+(5-h+9*c+4*c*c)*u*u*u*u/24+(61-58*h+h*h+600*c-330*a)*u*u*u*u*u*u/720));return t<0&&(y+=1e7),{northing:Math.round(y),easting:Math.round(_),zoneNumber:m,zoneLetter:$st(t)}}function Gw(s){var t=s.northing,e=s.easting,i=s.zoneLetter,n=s.zoneNumber;if(n<0||n>60)return null;var r=.9996,o=6378137,a=.00669438,l,h=(1-Math.sqrt(1-a))/(1+Math.sqrt(1-a)),c,u,d,g,f,p,m,_,y,v=e-5e5,S=t;i<"N"&&(S-=1e7),m=(n-1)*6-180+3,l=a/(1-a),p=S/r,_=p/(o*(1-a/4-3*a*a/64-5*a*a*a/256)),y=_+(3*h/2-27*h*h*h/32)*Math.sin(2*_)+(21*h*h/16-55*h*h*h*h/32)*Math.sin(4*_)+151*h*h*h/96*Math.sin(6*_),c=o/Math.sqrt(1-a*Math.sin(y)*Math.sin(y)),u=Math.tan(y)*Math.tan(y),d=l*Math.cos(y)*Math.cos(y),g=o*(1-a)/Math.pow(1-a*Math.sin(y)*Math.sin(y),1.5),f=v/(c*r);var w=y-c*Math.tan(y)/g*(f*f/2-(5+3*u+10*d-4*d*d-9*l)*f*f*f*f/24+(61+90*u+298*d+45*u*u-252*l-3*d*d)*f*f*f*f*f*f/720);w=vb(w);var T=(f-(1+2*u+d)*f*f*f/6+(5-2*d+28*u-3*d*d+8*l+24*u*u)*f*f*f*f*f/120)/Math.cos(y);T=m+vb(T);var M;if(s.accuracy){var C=Gw({northing:s.northing+s.accuracy,easting:s.easting+s.accuracy,zoneLetter:s.zoneLetter,zoneNumber:s.zoneNumber});M={top:C.lat,right:C.lon,bottom:w,left:T}}else M={lat:w,lon:T};return M}function $st(s){var t="Z";return 84>=s&&s>=72?t="X":72>s&&s>=64?t="W":64>s&&s>=56?t="V":56>s&&s>=48?t="U":48>s&&s>=40?t="T":40>s&&s>=32?t="S":32>s&&s>=24?t="R":24>s&&s>=16?t="Q":16>s&&s>=8?t="P":8>s&&s>=0?t="N":0>s&&s>=-8?t="M":-8>s&&s>=-16?t="L":-16>s&&s>=-24?t="K":-24>s&&s>=-32?t="J":-32>s&&s>=-40?t="H":-40>s&&s>=-48?t="G":-48>s&&s>=-56?t="F":-56>s&&s>=-64?t="E":-64>s&&s>=-72?t="D":-72>s&&s>=-80&&(t="C"),t}function Gst(s,t){var e="00000"+s.easting,i="00000"+s.northing;return s.zoneNumber+s.zoneLetter+jst(s.easting,s.northing,s.zoneNumber)+e.substr(e.length-5,t)+i.substr(i.length-5,t)}function jst(s,t,e){var i=JL(e),n=Math.floor(s/1e5),r=Math.floor(t/1e5)%20;return zst(n,r,i)}function JL(s){var t=s%xb;return t===0&&(t=xb),t}function zst(s,t,e){var i=e-1,n=qL.charCodeAt(i),r=ZL.charCodeAt(i),o=n+s-1,a=r+t,l=!1;o>Ru&&(o=o-Ru+vh-1,l=!0),(o===mi||nmi||(o>mi||ntn||(o>tn||nRu&&(o=o-Ru+vh-1),a>Cu?(a=a-Cu+vh-1,l=!0):l=!1,(a===mi||rmi||(a>mi||rtn||(a>tn||rCu&&(a=a-Cu+vh-1);var h=String.fromCharCode(o)+String.fromCharCode(a);return h}function QL(s){if(s&&s.length===0)throw"MGRSPoint coverting from nothing";for(var t=s.length,e=null,i="",n,r=0;!/[A-Z]/.test(n=s.charAt(r));){if(r>=2)throw"MGRSPoint bad conversion from: "+s;i+=n,r++}var o=parseInt(i,10);if(r===0||r+3>t)throw"MGRSPoint bad conversion from: "+s;var a=s.charAt(r++);if(a<="A"||a==="B"||a==="Y"||a>="Z"||a==="I"||a==="O")throw"MGRSPoint zone letter "+a+" not handled: "+s;e=s.substring(r,r+=2);for(var l=JL(o),h=Ust(e.charAt(0),l),c=Bst(e.charAt(1),l);c=1,R=arguments.length>=2;if(!(this instanceof o))return b?R?new o(x,E):new o(x):new o;if(x===void 0){if(b)throw new TypeError("undefined is not a valid argument for URI");typeof location<"u"?x=location.href+"":x=""}if(x===null&&b)throw new TypeError("null is not a valid argument for URI");return this.href(x),E!==void 0?this.absoluteTo(E):this}function a(x){return/^[0-9]+$/.test(x)}o.version="1.19.11";var l=o.prototype,h=Object.prototype.hasOwnProperty;function c(x){return x.replace(/([.*+?^=!:${}()|[\]\/\\])/g,"\\$1")}function u(x){return x===void 0?"Undefined":String(Object.prototype.toString.call(x)).slice(8,-1)}function d(x){return u(x)==="Array"}function g(x,E){var b={},R,A;if(u(E)==="RegExp")b=null;else if(d(E))for(R=0,A=E.length;R]+|\(([^\s()<>]+|(\([^\s()<>]+\)))*\))+(?:\(([^\s()<>]+|(\([^\s()<>]+\)))*\)|[^\s`!()\[\]{};:'".,<>?«»“”‘’]))/ig,o.findUri={start:/\b(?:([a-z][a-z0-9.+-]*:\/\/)|www\.)/gi,end:/[\s\r\n]|$/,trim:/[`!()\[\]{};:'".,<>?«»“”„‘’]+$/,parens:/(\([^\)]*\)|\[[^\]]*\]|\{[^}]*\}|<[^>]*>)/g},o.leading_whitespace_expression=/^[\x00-\x20\u00a0\u1680\u2000-\u200a\u2028\u2029\u202f\u205f\u3000\ufeff]+/,o.ascii_tab_whitespace=/[\u0009\u000A\u000D]+/g,o.defaultPorts={http:"80",https:"443",ftp:"21",gopher:"70",ws:"80",wss:"443"},o.hostProtocols=["http","https"],o.invalid_hostname_characters=/[^a-zA-Z0-9\.\-:_]/,o.domAttributes={a:"href",blockquote:"cite",link:"href",base:"href",script:"src",form:"action",img:"src",area:"href",iframe:"src",embed:"src",source:"src",track:"src",input:"src",audio:"src",video:"src"},o.getDomAttribute=function(x){if(!(!x||!x.nodeName)){var E=x.nodeName.toLowerCase();if(!(E==="input"&&x.type!=="image"))return o.domAttributes[E]}};function _(x){return escape(x)}function y(x){return encodeURIComponent(x).replace(/[!'()*]/g,_).replace(/\*/g,"%2A")}o.encode=y,o.decode=decodeURIComponent,o.iso8859=function(){o.encode=escape,o.decode=unescape},o.unicode=function(){o.encode=y,o.decode=decodeURIComponent},o.characters={pathname:{encode:{expression:/%(24|26|2B|2C|3B|3D|3A|40)/ig,map:{"%24":"$","%26":"&","%2B":"+","%2C":",","%3B":";","%3D":"=","%3A":":","%40":"@"}},decode:{expression:/[\/\?#]/g,map:{"/":"%2F","?":"%3F","#":"%23"}}},reserved:{encode:{expression:/%(21|23|24|26|27|28|29|2A|2B|2C|2F|3A|3B|3D|3F|40|5B|5D)/ig,map:{"%3A":":","%2F":"/","%3F":"?","%23":"#","%5B":"[","%5D":"]","%40":"@","%21":"!","%24":"$","%26":"&","%27":"'","%28":"(","%29":")","%2A":"*","%2B":"+","%2C":",","%3B":";","%3D":"="}}},urnpath:{encode:{expression:/%(21|24|27|28|29|2A|2B|2C|3B|3D|40)/ig,map:{"%21":"!","%24":"$","%27":"'","%28":"(","%29":")","%2A":"*","%2B":"+","%2C":",","%3B":";","%3D":"=","%40":"@"}},decode:{expression:/[\/\?#:]/g,map:{"/":"%2F","?":"%3F","#":"%23",":":"%3A"}}}},o.encodeQuery=function(x,E){var b=o.encode(x+"");return E===void 0&&(E=o.escapeQuerySpace),E?b.replace(/%20/g,"+"):b},o.decodeQuery=function(x,E){x+="",E===void 0&&(E=o.escapeQuerySpace);try{return o.decode(E?x.replace(/\+/g,"%20"):x)}catch{return x}};var v={encode:"encode",decode:"decode"},S,w=function(x,E){return function(b){try{return o[E](b+"").replace(o.characters[x][E].expression,function(R){return o.characters[x][E].map[R]})}catch{return b}}};for(S in v)o[S+"PathSegment"]=w("pathname",v[S]),o[S+"UrnPathSegment"]=w("urnpath",v[S]);var C=function(x,E,b){return function(R){var A;b?A=function(z){return o[E](o[b](z))}:A=o[E];for(var $=(R+"").split(x),G=0,k=$.length;G-1&&(E.fragment=x.substring(b+1)||null,x=x.substring(0,b)),b=x.indexOf("?"),b>-1&&(E.query=x.substring(b+1)||null,x=x.substring(0,b)),x=x.replace(/^(https?|ftp|wss?)?:+[/\\]*/i,"$1://"),x=x.replace(/^[/\\]{2,}/i,"//"),x.substring(0,2)==="//"?(E.protocol=null,x=x.substring(2),x=o.parseAuthority(x,E)):(b=x.indexOf(":"),b>-1&&(E.protocol=x.substring(0,b)||null,E.protocol&&!E.protocol.match(o.protocol_expression)?E.protocol=void 0:x.substring(b+1,b+3).replace(/\\/g,"/")==="//"?(x=x.substring(b+3),x=o.parseAuthority(x,E)):(x=x.substring(b+1),E.urn=!0))),E.path=x,E},o.parseHost=function(x,E){x||(x=""),x=x.replace(/\\/g,"/");var b=x.indexOf("/"),R,A;if(b===-1&&(b=x.length),x.charAt(0)==="[")R=x.indexOf("]"),E.hostname=x.substring(1,R)||null,E.port=x.substring(R+2,b)||null,E.port==="/"&&(E.port=null);else{var $=x.indexOf(":"),G=x.indexOf("/"),k=x.indexOf(":",$+1);k!==-1&&(G===-1||k-1?A:x.length-1),G;return $>-1&&(A===-1||$-1?ot=ot.slice(0,ht)+ot.slice(ht).replace($,""):ot=ot.replace($,""),!(ot.length<=z[0].length)&&!(b.ignore&&b.ignore.test(ot))){F=V+ot.length;var Kt=E(ot,V,F,x);if(Kt===void 0){R.lastIndex=F;continue}Kt=String(Kt),x=x.slice(0,V)+Kt+x.slice(F),R.lastIndex=V+Kt.length}}return R.lastIndex=0,x},o.ensureValidHostname=function(x,E){var b=!!x,R=!!E,A=!1;if(R&&(A=f(o.hostProtocols,E)),A&&!b)throw new TypeError("Hostname cannot be empty, if protocol is "+E);if(x&&x.match(o.invalid_hostname_characters)){if(!t)throw new TypeError('Hostname "'+x+'" contains characters other than [A-Z0-9.-:_] and Punycode.js is not available');if(t.toASCII(x).match(o.invalid_hostname_characters))throw new TypeError('Hostname "'+x+'" contains characters other than [A-Z0-9.-:_]')}},o.ensureValidPort=function(x){if(x){var E=Number(x);if(!(a(E)&&E>0&&E<65536))throw new TypeError('Port "'+x+'" is not a valid port')}},o.noConflict=function(x){if(x){var E={URI:this.noConflict()};return n.URITemplate&&typeof n.URITemplate.noConflict=="function"&&(E.URITemplate=n.URITemplate.noConflict()),n.IPv6&&typeof n.IPv6.noConflict=="function"&&(E.IPv6=n.IPv6.noConflict()),n.SecondLevelDomains&&typeof n.SecondLevelDomains.noConflict=="function"&&(E.SecondLevelDomains=n.SecondLevelDomains.noConflict()),E}else n.URI===this&&(n.URI=r);return this},l.build=function(x){return x===!0?this._deferred_build=!0:(x===void 0||this._deferred_build)&&(this._string=o.build(this._parts),this._deferred_build=!1),this},l.clone=function(){return new o(this)},l.valueOf=l.toString=function(){return this.build(!1)._string};function M(x){return function(E,b){return E===void 0?this._parts[x]||"":(this._parts[x]=E||null,this.build(!b),this)}}function T(x,E){return function(b,R){return b===void 0?this._parts[x]||"":(b!==null&&(b=b+"",b.charAt(0)===E&&(b=b.substring(1))),this._parts[x]=b,this.build(!R),this)}}l.protocol=M("protocol"),l.username=M("username"),l.password=M("password"),l.hostname=M("hostname"),l.port=M("port"),l.query=T("query","?"),l.fragment=T("fragment","#"),l.search=function(x,E){var b=this.query(x,E);return typeof b=="string"&&b.length?"?"+b:b},l.hash=function(x,E){var b=this.fragment(x,E);return typeof b=="string"&&b.length?"#"+b:b},l.pathname=function(x,E){if(x===void 0||x===!0){var b=this._parts.path||(this._parts.hostname?"/":"");return x?(this._parts.urn?o.decodeUrnPath:o.decodePath)(b):b}else return this._parts.urn?this._parts.path=x?o.recodeUrnPath(x):"":this._parts.path=x?o.recodePath(x):"/",this.build(!E),this},l.path=l.pathname,l.href=function(x,E){var b;if(x===void 0)return this.toString();this._string="",this._parts=o._parts();var R=x instanceof o,A=typeof x=="object"&&(x.hostname||x.path||x.pathname);if(x.nodeName){var $=o.getDomAttribute(x);x=x[$]||"",A=!1}if(!R&&A&&x.pathname!==void 0&&(x=x.toString()),typeof x=="string"||x instanceof String)this._parts=o.parse(String(x),this._parts);else if(R||A){var G=R?x._parts:x;for(b in G)b!=="query"&&h.call(this._parts,b)&&(this._parts[b]=G[b]);G.query&&this.query(G.query,!1)}else throw new TypeError("invalid input");return this.build(!E),this},l.is=function(x){var E=!1,b=!1,R=!1,A=!1,$=!1,G=!1,k=!1,z=!this._parts.urn;switch(this._parts.hostname&&(z=!1,b=o.ip4_expression.test(this._parts.hostname),R=o.ip6_expression.test(this._parts.hostname),E=b||R,A=!E,$=A&&i&&i.has(this._parts.hostname),G=A&&o.idn_expression.test(this._parts.hostname),k=A&&o.punycode_expression.test(this._parts.hostname)),x.toLowerCase()){case"relative":return z;case"absolute":return!z;case"domain":case"name":return A;case"sld":return $;case"ip":return E;case"ip4":case"ipv4":case"inet4":return b;case"ip6":case"ipv6":case"inet6":return R;case"idn":return G;case"url":return!this._parts.urn;case"urn":return!!this._parts.urn;case"punycode":return k}return null};var I=l.protocol,O=l.port,P=l.hostname;l.protocol=function(x,E){if(x&&(x=x.replace(/:(\/\/)?$/,""),!x.match(o.protocol_expression)))throw new TypeError('Protocol "'+x+`" contains characters other than [A-Z0-9.+-] or doesn't start with [A-Z]`);return I.call(this,x,E)},l.scheme=l.protocol,l.port=function(x,E){return this._parts.urn?x===void 0?"":this:(x!==void 0&&(x===0&&(x=null),x&&(x+="",x.charAt(0)===":"&&(x=x.substring(1)),o.ensureValidPort(x))),O.call(this,x,E))},l.hostname=function(x,E){if(this._parts.urn)return x===void 0?"":this;if(x!==void 0){var b={preventInvalidHostname:this._parts.preventInvalidHostname},R=o.parseHost(x,b);if(R!=="/")throw new TypeError('Hostname "'+x+'" contains characters other than [A-Z0-9.-]');x=b.hostname,this._parts.preventInvalidHostname&&o.ensureValidHostname(x,this._parts.protocol)}return P.call(this,x,E)},l.origin=function(x,E){if(this._parts.urn)return x===void 0?"":this;if(x===void 0){var b=this.protocol(),R=this.authority();return R?(b?b+"://":"")+this.authority():""}else{var A=o(x);return this.protocol(A.protocol()).authority(A.authority()).build(!E),this}},l.host=function(x,E){if(this._parts.urn)return x===void 0?"":this;if(x===void 0)return this._parts.hostname?o.buildHost(this._parts):"";var b=o.parseHost(x,this._parts);if(b!=="/")throw new TypeError('Hostname "'+x+'" contains characters other than [A-Z0-9.-]');return this.build(!E),this},l.authority=function(x,E){if(this._parts.urn)return x===void 0?"":this;if(x===void 0)return this._parts.hostname?o.buildAuthority(this._parts):"";var b=o.parseAuthority(x,this._parts);if(b!=="/")throw new TypeError('Hostname "'+x+'" contains characters other than [A-Z0-9.-]');return this.build(!E),this},l.userinfo=function(x,E){if(this._parts.urn)return x===void 0?"":this;if(x===void 0){var b=o.buildUserinfo(this._parts);return b&&b.substring(0,b.length-1)}else return x[x.length-1]!=="@"&&(x+="@"),o.parseUserinfo(x,this._parts),this.build(!E),this},l.resource=function(x,E){var b;return x===void 0?this.path()+this.search()+this.hash():(b=o.parse(x),this._parts.path=b.path,this._parts.query=b.query,this._parts.fragment=b.fragment,this.build(!E),this)},l.subdomain=function(x,E){if(this._parts.urn)return x===void 0?"":this;if(x===void 0){if(!this._parts.hostname||this.is("IP"))return"";var b=this._parts.hostname.length-this.domain().length-1;return this._parts.hostname.substring(0,b)||""}else{var R=this._parts.hostname.length-this.domain().length,A=this._parts.hostname.substring(0,R),$=new RegExp("^"+c(A));if(x&&x.charAt(x.length-1)!=="."&&(x+="."),x.indexOf(":")!==-1)throw new TypeError("Domains cannot contain colons");return x&&o.ensureValidHostname(x,this._parts.protocol),this._parts.hostname=this._parts.hostname.replace($,x),this.build(!E),this}},l.domain=function(x,E){if(this._parts.urn)return x===void 0?"":this;if(typeof x=="boolean"&&(E=x,x=void 0),x===void 0){if(!this._parts.hostname||this.is("IP"))return"";var b=this._parts.hostname.match(/\./g);if(b&&b.length<2)return this._parts.hostname;var R=this._parts.hostname.length-this.tld(E).length-1;return R=this._parts.hostname.lastIndexOf(".",R-1)+1,this._parts.hostname.substring(R)||""}else{if(!x)throw new TypeError("cannot set domain empty");if(x.indexOf(":")!==-1)throw new TypeError("Domains cannot contain colons");if(o.ensureValidHostname(x,this._parts.protocol),!this._parts.hostname||this.is("IP"))this._parts.hostname=x;else{var A=new RegExp(c(this.domain())+"$");this._parts.hostname=this._parts.hostname.replace(A,x)}return this.build(!E),this}},l.tld=function(x,E){if(this._parts.urn)return x===void 0?"":this;if(typeof x=="boolean"&&(E=x,x=void 0),x===void 0){if(!this._parts.hostname||this.is("IP"))return"";var b=this._parts.hostname.lastIndexOf("."),R=this._parts.hostname.substring(b+1);return E!==!0&&i&&i.list[R.toLowerCase()]&&i.get(this._parts.hostname)||R}else{var A;if(x)if(x.match(/[^a-zA-Z0-9-]/))if(i&&i.is(x))A=new RegExp(c(this.tld())+"$"),this._parts.hostname=this._parts.hostname.replace(A,x);else throw new TypeError('TLD "'+x+'" contains characters other than [A-Z0-9]');else{if(!this._parts.hostname||this.is("IP"))throw new ReferenceError("cannot set TLD on non-domain host");A=new RegExp(c(this.tld())+"$"),this._parts.hostname=this._parts.hostname.replace(A,x)}else throw new TypeError("cannot set TLD empty");return this.build(!E),this}},l.directory=function(x,E){if(this._parts.urn)return x===void 0?"":this;if(x===void 0||x===!0){if(!this._parts.path&&!this._parts.hostname)return"";if(this._parts.path==="/")return"/";var b=this._parts.path.length-this.filename().length-1,R=this._parts.path.substring(0,b)||(this._parts.hostname?"/":"");return x?o.decodePath(R):R}else{var A=this._parts.path.length-this.filename().length,$=this._parts.path.substring(0,A),G=new RegExp("^"+c($));return this.is("relative")||(x||(x="/"),x.charAt(0)!=="/"&&(x="/"+x)),x&&x.charAt(x.length-1)!=="/"&&(x+="/"),x=o.recodePath(x),this._parts.path=this._parts.path.replace(G,x),this.build(!E),this}},l.filename=function(x,E){if(this._parts.urn)return x===void 0?"":this;if(typeof x!="string"){if(!this._parts.path||this._parts.path==="/")return"";var b=this._parts.path.lastIndexOf("/"),R=this._parts.path.substring(b+1);return x?o.decodePathSegment(R):R}else{var A=!1;x.charAt(0)==="/"&&(x=x.substring(1)),x.match(/\.?\//)&&(A=!0);var $=new RegExp(c(this.filename())+"$");return x=o.recodePath(x),this._parts.path=this._parts.path.replace($,x),A?this.normalizePath(E):this.build(!E),this}},l.suffix=function(x,E){if(this._parts.urn)return x===void 0?"":this;if(x===void 0||x===!0){if(!this._parts.path||this._parts.path==="/")return"";var b=this.filename(),R=b.lastIndexOf("."),A,$;return R===-1?"":(A=b.substring(R+1),$=/^[a-z0-9%]+$/i.test(A)?A:"",x?o.decodePathSegment($):$)}else{x.charAt(0)==="."&&(x=x.substring(1));var G=this.suffix(),k;if(G)x?k=new RegExp(c(G)+"$"):k=new RegExp(c("."+G)+"$");else{if(!x)return this;this._parts.path+="."+o.recodePath(x)}return k&&(x=o.recodePath(x),this._parts.path=this._parts.path.replace(k,x)),this.build(!E),this}},l.segment=function(x,E,b){var R=this._parts.urn?":":"/",A=this.path(),$=A.substring(0,1)==="/",G=A.split(R);if(x!==void 0&&typeof x!="number"&&(b=E,E=x,x=void 0),x!==void 0&&typeof x!="number")throw new Error('Bad segment "'+x+'", must be 0-based integer');if($&&G.shift(),x<0&&(x=Math.max(G.length+x,0)),E===void 0)return x===void 0?G:G[x];if(x===null||G[x]===void 0)if(d(E)){G=[];for(var k=0,z=E.length;k"u"?!0:typeof s!="string"?!1:(t=t.map(i=>i.toLowerCase()),t.includes(s.toLowerCase()))}function yet(s,t=!1){return Fw(s,_et,t)}class PL extends v0{constructor(t,e=null,i={},n=[]){super(t,i,["_context"].concat(n)),this._context||(this._context=e)}getAbsoluteUrl(t=!0){return this._context?fet(this.href,this._context.getAbsoluteUrl(),t):this.href.includes("://")?this.href:null}getContext(){return this._context}canBrowserDisplayImage(t=!1){if(typeof this.href!="string"||!t&&typeof this.type>"u")return!1;let e=new yy(this.href),i=e.protocol().toLowerCase(),n=e.suffix().toLowerCase();return Ri(i)&&!sb.includes(i)?!1:Ri(this.type)&&ib.includes(this.type.toLowerCase())?!0:!!(typeof this.type>"u"&&Ri(n)&&(n==="jpg"||ib.includes("image/"+n)))}isType(t){return Ri(this.type)&&Fw(this.type,t)}isGeoTIFF(){return this.isType(IL)}isCOG(){return this.isType(RL)}isHTTP(){let t=this.getAbsoluteUrl(!1).protocol().toLowerCase();return Ri(t)&&sb.includes(t)}}class Nw extends PL{constructor(t,e=null){super(t,e)}isLink(){return!0}getObjectType(){return"Link"}static fromLinks(t,e=null){return Array.isArray(t)?t.map(i=>xi(i)?new Nw(i,e):i):[]}}class AL extends v0{constructor(t,e=null,i={},n=[]){if(super(t,Object.assign({links:Nw.fromLinks},i),["_url"].concat(n)),!this._url&&(this._url=e,!this._url)){let r=this.getSelfLink();r&&(this._url=r.href)}}getAbsoluteUrl(){return this._url}setAbsoluteUrl(t){this._url=t}getStacLinksWithRel(t,e=!0){return this.getLinksWithRels([t]).filter(i=>yet(i.type,e))}getStacLinkWithRel(t,e=!0){const i=this.getStacLinksWithRel(t,e);return i.length>0?i[0]:null}getLinks(){return Array.isArray(this.links)?this.links.filter(t=>xi(t)&&Ri(t.href)):[]}getLinkWithRel(t){return this.getLinks().find(e=>e.rel===t)||null}getLinksWithRels(t){return this.getLinks().filter(e=>t.includes(e.rel))}getLinksWithOtherRels(t){return this.getLinks().filter(e=>!t.includes(e.rel))}getSelfLink(){return this.getStacLinkWithRel("self")}getRootLink(){return this.getStacLinkWithRel("root")}getParentLink(){return this.getStacLinkWithRel("parent")}}class LL extends AL{constructor(t,e=null,i={},n=[]){super(t,e,i,n)}getAll(){return[]}}class Qo extends PL{constructor(t,e=null,i=null){super(t,i,{},["_key"]),this._key||(this._key=e)}getObjectType(){return"Asset"}isAsset(){return!0}getAbsoluteUrl(t=!0){return this.isDefinition()?null:super.getAbsoluteUrl(t)}getKey(){return this._key}getMetadata(t){if(typeof this[t]<"u")return this[t];if(this._context)return this._context.getMetadata(t)}getBands(){return CL(this["eo:bands"],this["raster:bands"])}findVisualBands(){let t={red:null,green:null,blue:null},e=this.getBands();for(let i in e){let n=parseInt(i,10),r=e[n];xi(r)&&Ri(r.common_name)&&r.common_name in t&&(t[r.common_name]={index:n,band:r})}return Object.values(t).every(i=>i!==null)?t:null}findBand(t,e="name",i=null){Array.isArray(t)||(t=[t]),xi(i)||(i=this.getBands());let n=i.findIndex(r=>xi(r)&&t.includes(r[e]));return n>=0?{index:n,band:i[n]}:null}getBand(t){return xi(t)||t===null?t:this.getBands()[t]||null}getMinMaxValues(t=null){t=this.getBand(t);const e={minimum:null,maximum:null},i=a=>a.minimum!==null&&a.maximum!==null;if(t&&(xi(t.statistics)&&(typeof t.statistics.minimum=="number"&&(e.minimum=t.statistics.minimum),typeof t.statistics.maximum=="number"&&(e.maximum=t.statistics.maximum),i(e))||xi(t.histogram)&&(typeof t.histogram.min=="number"&&(e.minimum=t.histogram.min),typeof t.histogram.max=="number"&&(e.maximum=t.histogram.max),i(e))))return e;let n=this.getMetadata("classification:classes");if(Array.isArray(n)&&(n.reduce((a,l)=>(a.minimum=Math.min(a.minimum,l.value),a.maximum=Math.max(a.maximum,l.value),a),e),i(e)))return e;let r=this.getMetadata("file:values");if(Array.isArray(r)&&(r.reduce((a,l)=>(a.minimum=Math.min(a.minimum,...l.values),a.maximum=Math.max(a.maximum,...l.values),a),e),i(e)))return e;let o=xi(t)&&t.data_type||this.getMetadata("file:data_type");return o&&(e.minimum=oet(o),e.maximum=aet(o)),e}getNoDataValues(t=null){t=this.getBand(t);let e=[];if(t&&typeof t.nodata<"u")e.push(t.nodata);else{let i=this.getMetadata("file:nodata");if(typeof i<"u")e=i;else{let n=this.getMetadata("classification:classes");Array.isArray(n)&&(e=n.filter(r=>!!r.nodata).map(r=>r.value))}}return e.map(i=>i==="nan"?NaN:i==="+inf"?1/0:i==="-inf"?-1/0:i)}isDefinition(){return!Ri(this.href)}isHTTP(){return this.isDefinition()?null:super.isHTTP()}hasRole(t,e=!1){return Array.isArray(t)||(t=[t]),e&&t.includes(this.getKey())?!0:Array.isArray(this.roles)&&!!this.roles.find(i=>t.includes(i))}static fromAssets(t,e=null){let i={};if(xi(t))for(let n in t)i[n]=new Qo(t[n],n,e);return i}}class Dg extends AL{constructor(t,e=null,i={},n=[]){super(t,e,i,n)}getTemporalExtent(){return null}getTemporalExtents(){return[]}getIcons(t=!0){return this.getLinksWithRels(["icon"]).filter(e=>e.canBrowserDisplayImage(t))}getThumbnails(t=!0,e=null){let i=this.getAssetsWithRoles(["thumbnail","overview"],!0);if(i.length===0&&(i=this.getLinksWithRels(["preview"])),t&&(i=i.filter(n=>n.canBrowserDisplayImage())),e&&i.length>1){let n=r=>Array.isArray(r.roles)&&r.roles.includes(e)||r.getKey()===e;i=i.filter(n).concat(i.filter(r=>!n(r)))}return i}getDefaultGeoTIFF(t=!0,e=!1){var i;return(i=this.rankGeoTIFFs(t,e)[0])==null?void 0:i.asset}rankGeoTIFFs(t=!0,e=!1,i=null,n=null){xi(i)||(i={data:1,visual:2,thumbnail:2,overview:3});let r=[],o=this.getAssetsByTypes(IL);t&&(o=o.filter(l=>l.isHTTP()&&(!e||l.isCOG())));let a=Object.entries(i);for(let l of o){let h=0;if(a.length>0){let c=a.filter(([u])=>l.hasRole(u,!0)).map(([,u])=>u);c.length>0&&(h+=Math.max(...c))}!e&&l.isCOG()&&(h+=2),l.findVisualBands()&&(h+=1),typeof n=="function"&&(h+=n(l)),r.push({asset:l,score:h})}return r.sort((l,h)=>h.score-l.score),r}findVisualAssets(){let t={red:null,green:null,blue:null},e=Object.keys(t),i=this.getAssets();for(let n of i){let r=n.getBands();if(r.length!==1)continue;let o=n.findBand(e,"common_name",r);o&&(t[o.band.common_name]=n)}return Object.values(t).every(n=>n!==null)?t:null}getAsset(t){return xi(this.assets)&&this.assets[t]||null}getAssets(){return xi(this.assets)?Object.values(this.assets):[]}getAssetsWithRoles(t,e=!1){return this.getAssets().filter(i=>i.hasRole(t,e))}getAssetWithRole(t,e=!1){return this.getAssetsWithRoles([t],e)[0]||null}getAssetsByTypes(t){return this.getAssets().filter(e=>Fw(e.type,t))}equals(t){return this===t?!0:!(t instanceof Dg)||this.getObjectType()!==t.getObjectType()?!1:!!(this.id&&this.id===t.id)}}class OL extends Dg{constructor(t,e=null,i={},n=[]){super(t,e,i,n)}getObjectType(){return this.type}getSearchLink(t=null){let e=this.getStacLinksWithRel("search");return t?e[0]||null:e.find(i=>i.method===t||!t&&!i.method)||null}getApiCollectionsLink(){return this.getStacLinkWithRel("data")}getApiItemsLink(){return this.getStacLinkWithRel("items")}getChildLinks(){return this.getStacLinksWithRel("child")}getItemLinks(){return this.getStacLinksWithRel("item")}}class xet extends OL{constructor(t,e=null){super(t,e)}}function Cu(s){if(Ri(s)&&s.length>=10)try{let t=s.match(/^(-?\d{1,})-(\d\d)-(\d\d)[T ](\d\d):(\d\d):(\d\d)(?:\.(\d*))?(?:Z|[+-]00:00)?$/i).slice(1).map(e=>parseInt(e,10));return new Date(Date.UTC(t[0],t[1]-1,t[2],t[3],t[4],t[5],t[6]||0))}catch{return null}return null}function vet(s,t){return new Date(s.valueOf()+(t-s)/2)}function FL(s){if(!Array.isArray(s)||s.length===0)return null;let t,e;const i=(n,r,o)=>typeof n>"u"?r:n===null||r===null?null:o(n,r);return s.forEach(([n,r])=>{t=i(t,n,Math.min),e=i(e,r,Math.max)}),[t===null?null:new Date(t),e===null?null:new Date(e)]}class NL extends OL{constructor(t,e=null){const i={assets:Qo.fromAssets,item_assets:Qo.fromAssets};super(t,e,i)}toGeoJSON(){let t=SL(this.getBoundingBoxes());return t&&(t.id=this.id),t}getBoundingBox(){let t=this.getRawBoundingBoxes();return t.length>0&&$n(t[0])?t[0]:null}getBoundingBoxes(){let t=this.getRawBoundingBoxes();return t.length===1&&$n(t[0])?t:t.length>1?t.filter((e,i)=>i>0&&$n(e)):[]}getRawBoundingBoxes(){var t,e;let i=(e=(t=this.extent)==null?void 0:t.spatial)==null?void 0:e.bbox;return Array.isArray(i)&&i.length>0?i:[]}getTemporalExtent(){return this.getTemporalExtents()[0]||null}getTemporalExtents(){var t,e;let i=(e=(t=this.extent)==null?void 0:t.temporal)==null?void 0:e.interval;return Array.isArray(i)&&i.length>0?i.filter(n=>Array.isArray(n)&&(Ri(n[0])||Ri(n[1]))).map(n=>n.map(r=>Cu(r))):[]}getSummary(t){return this.summaries[t]}getBands(){let t=this.getSummary("eo:bands"),e=this.getSummary("raster:bands"),i=[t,e].filter(n=>Array.isArray(n));return i.length>=2?CL(...i):i.length===1?i[0]:[]}}class wet extends LL{constructor(t,e=null){const i={collections:n=>n.map(r=>new NL(r))};super(t,e,i)}getObjectType(){return"CollectionCollection"}getAll(){return this.collections}isCollectionCollection(){return!0}toGeoJSON(){return{type:"FeatureCollection",features:this.collections.map(t=>t.toGeoJSON()).filter(t=>t!==null)}}getBoundingBox(){return bL(this.getBoundingBoxes())}getBoundingBoxes(){return this.collections.map(t=>t.getBoundingBox())}getTemporalExtent(){return FL(this.getTemporalExtents())}getTemporalExtents(){return this.collections.map(t=>t.getTemporalExtent())}}class DL extends Dg{constructor(t,e=null){super(t,e,{assets:Qo.fromAssets})}getObjectType(){return"Item"}toGeoJSON(){return this.toJSON()}getBoundingBox(){return $n(this.bbox)?this.bbox:null}getBoundingBoxes(){return $n(this.bbox)?[this.bbox]:[]}getDateTime(){let t=Cu(this.properties.datetime);if(!t){let e=Cu(this.properties.start_datetime),i=Cu(this.properties.end_datetime);return e&&i?vet(e,i):e||i}return t}getTemporalExtent(){return this.getTemporalExtents()[0]||null}getTemporalExtents(){let t=[];return Ri(this.properties.start_datetime)||Ri(this.properties.end_datetime)?t=[[this.properties.start_datetime||null,this.properties.end_datetime||null]]:Ri(this.properties.datetime)&&(t=[[this.properties.datetime,this.properties.datetime]]),t.map(e=>e.map(i=>Cu(i)))}getMetadata(t){return this.properties[t]}getBands(){let t=this.getMetadata("eo:bands");return Array.isArray(t)?t:[]}getCollectionLink(){return this.getStacLinkWithRel("collection")}}class Eet extends LL{constructor(t,e=null){const i={features:n=>n.map(r=>new DL(r))};super(t,e,i)}getObjectType(){return"ItemCollection"}getAll(){return this.features}toGeoJSON(){return this.toJSON()}getBoundingBox(){return bL(this.getBoundingBoxes())}getBoundingBoxes(){return this.features.map(t=>t.getBoundingBox())}getTemporalExtent(){return FL(this.getTemporalExtents())}getTemporalExtents(){return this.features.map(t=>t.getTemporalExtent())}}function Met(s,t=!0,e=!1){return t&&(s=net.stac(s,e)),s.type==="Feature"?new DL(s):s.type==="FeatureCollection"?new Eet(s):s.type==="Collection"||!s.type&&typeof s.extent<"u"&&typeof s.license<"u"?new NL(s):!s.type&&Array.isArray(s.collections)?new wet(s):new xet(s)}class nb extends d0{constructor(t){super({...t,state:"loading"}),jx(this,"loadImage",i=>new Promise((n,r)=>{const o=new Image;o.addEventListener("load",()=>n(o)),o.addEventListener("error",()=>r(new Error("load failed"))),o.src=i}));const e=new aw(t.url);e.getHeader().then(i=>{this.tileGrid.minZoom=i.minZoom,this.tileGrid.maxZoom=i.maxZoom,this.setLoader(async(n,r,o)=>{const a=await e.getZxy(n,r,o),l=URL.createObjectURL(new Blob([a.data])),h=await this.loadImage(l);return URL.revokeObjectURL(l),h}),this.setState("ready")})}}class bet extends y0{constructor(t){super({...t,state:"loading",url:"pmtiles://"+t.url+"/{z}/{x}/{y}",format:new xP}),jx(this,"tileLoadFunction",(e,i)=>{const n=new RegExp(/pmtiles:\/\/(.+)\/(\d+)\/(\d+)\/(\d+)/),r=i.match(n),o=+r[2],a=+r[3],l=+r[4];e.setLoader((h,c,u)=>{e.setState(X.LOADING),this.pmtiles_.getZxy(o,a,l).then(d=>{if(d){const g=e.getFormat();e.setFeatures(g.readFeatures(d.data,{extent:h,featureProjection:u})),e.setState(X.LOADED)}else e.setFeatures([]),e.setState(X.EMPTY)}).catch(d=>{e.setFeatures([]),e.setState(X.ERROR)})})}),this.pmtiles_=new aw(t.url),this.pmtiles_.getHeader().then(e=>{this.tileGrid.minZoom=e.minZoom,this.tileGrid.maxZoom=e.maxZoom,this.setTileLoadFunction(this.tileLoadFunction),this.setState("ready")})}}let Dw=null;function Cet(){return!!Dw}function kL(s){Dw=s;const t=Object.keys(s.defs),e=t.length;let i,n;for(i=0;i0&&(e.nodata=o[0]),t.length>0&&(e.bands=t),e}async function rb(s,t=void 0){let e=t;if(Cet()){const i=s.getMetadata("proj:epsg");if(i)try{e=await Ret(i)}catch{}}return e}function ob(s,t){const e=s.clone();return t.hasOnlyBounds()||e.setFill(null),e}function Let(s){let t=s.href;if(t.includes("{s}"))if(Array.isArray(s["href:servers"])&&s["href:servers"].length>0){const e=Math.random()*s["href:servers"].length|0;t=t.replace("{s}",s["href:servers"][e])}else return null;return t}async function Oet(s){try{const t=new URL(s);t.searchParams.set("service","wmts"),t.searchParams.set("request","GetCapabilities");const e=await fetch(t);return new kv().read(await e.text())}catch{return null}}class kw extends i0{constructor(t){const e={};if(["opacity","visible","zIndex","minResolution","maxResolution","minZoom","maxZoom","properties"].forEach(i=>e[i]=t[i]),super(e),this.getSourceOptions_=t.getSourceOptions,this.data_,this.assets_=null,this.bands_=[],this.crossOrigin_=t.crossOrigin||null,this.displayFootprint_=t.displayFootprint!==!1,this.displayGeoTiffByDefault_=!!t.displayGeoTiffByDefault,this.displayPreview_=!!t.displayPreview,this.displayOverview_=t.displayOverview!==!1,this.displayWebMapLink_=t.displayWebMapLink||!1,this.buildTileUrlTemplate_=t.buildTileUrlTemplate||null,this.useTileLayerAsFallback_=t.useTileLayerAsFallback||!1,this.boundsStyle_=t.boundsStyle||Iet,this.collectionStyle_=t.collectionStyle||Pet,this.boundsLayer_=null,t.data){try{this.configure_(t.data,t.url,t.assets,t.bands)}catch(i){this.handleError_(i)}return}if(!t.url)throw new Error("Either url or data must be provided");fetch(t.url).then(i=>i.json()).then(i=>this.configure_(i,t.url,t.assets,t.bands)).catch(i=>this.handleError_(i))}getBoundsLayer(){return this.boundsLayer_}handleError_(t){this.dispatchEvent(new WJ(t))}configure_(t,e=null,i=null,n=[]){t instanceof Qo||t instanceof Dg?this.data_=t:this.data_=Met(t),e&&e.includes("://")&&this.data_.setAbsoluteUrl(e),this.bands_=n,this.boundsLayer_=this.addFootprint_();const r=()=>{this.boundsLayer_&&this.boundsLayer_.setStyle(ob(this.boundsStyle_,this))};this.getLayers().on("add",r),this.getLayers().on("remove",r),this.setAssets(i).then(()=>this.dispatchEvent("assetsready")).catch(o=>this.handleError_(o)),this.dispatchEvent("sourceready")}async addApiCollection_(){const t=this.getData().getAll().map(e=>{const i=new kw({data:e,crossOrigin:this.crossOrigin_,boundsStyle:this.collectionStyle_,displayGeoTiffByDefault:this.displayGeoTiffByDefault_,displayOverview:this.displayOverview_,displayPreview:this.displayPreview_,displayFootprint:this.displayFootprint_});return this.addLayer_(i),i});return await Promise.all(t)}async addStacAssets_(){let t=this.getAssets();if(t===null){t=[];const i=this.getData().getDefaultGeoTIFF(!0,!this.displayGeoTiffByDefault_);if(i)t.push(i);else{const n=this.getData().getThumbnails().filter(r=>!Array.isArray(r.roles)||!r.roles.includes("example"));n.length>0&&t.push(n[0])}}const e=t.map(i=>this.addImagery_(i));return await Promise.all(e)}async addImagery_(t){if(t){if(t.isGeoTIFF())return await this.addGeoTiff_(t);if(t.canBrowserDisplayImage())return await this.addThumbnail_(t)}}async addThumbnail_(t){if(!this.displayPreview_)return;let e={url:t.getAbsoluteUrl(),projection:await rb(t,"EPSG:4326"),imageExtent:t.getContext().getBoundingBox(),crossOrigin:this.crossOrigin_};this.getSourceOptions_&&(e=await this.getSourceOptions_(Fe.ImageStatic,e,t));const i=new ew({source:new hL(e)});return this.addLayer_(i,t),i}async addWebMapLinks_(){const t=this.getWebMapLinks();if(t.length>0)return await this.addLayerForLink(t[0])}async addLayerForLink(t){const e=Let(t);if(!e)return;const i={attributions:t.getMetadata("attribution")||this.data_.getMetadata("attribution"),crossOrigin:this.crossOrigin_,url:e},n=async(o,a)=>(this.getSourceOptions_&&(a=await this.getSourceOptions_(o,a,t)),a),r=[];switch(t.rel){case"pmtiles":const o=await new aw(i.url).getHeader();let a;switch(o.tileType){case th.Mvt:a=new bet(await n(Fe.PMTilesVector,i));break;case th.Avif:case th.Jpeg:case th.Png:case th.Webp:a=new nb(await n(Fe.PMTilesRaster,i));break;default:return}r.push(a);break;case"tilejson":r.push(new gL(await n(Fe.TileJSON,i)));break;case"wms":if(!Array.isArray(t["wms:layers"]))break;for(const c in t["wms:layers"]){const u=t["wms:layers"][c]||"";let d="";Array.isArray(t["wms:styles"])&&typeof t["wms:styles"][c]=="string"&&(d=t["wms:styles"][c]);const g=Object.assign({LAYERS:u,STYLES:d},t["wms:dimensions"]);typeof t["wms:transparent"]=="boolean"&&(g.TRANSPARENT=String(t["wms:transparent"])),typeof t.type=="string"&&t.type.startsWith("image/")&&(g.FORMAT=t.type);const f=await n(Fe.TileWMS,Object.assign({},i,{params:g}));r.push(new _L(f))}break;case"wmts":const l=await Oet(e);if(!l)return;const h=Array.isArray(t["wmts:layer"])?t["wmts:layer"]:[t["wmts:layer"]];for(const c of h){let u=Object.assign({},i,{layer:c});typeof t.type=="string"&&t.type.startsWith("image/")&&(u.format=t.type),u=await n(Fe.WMTS,u),r.push(new yL(xL(l,u)))}break;case"xyz":r.push(new hl(await n(Fe.XYZ,i)));break;default:return}return r.map(o=>{let a;return o instanceof y0?a=new vA({source:o,declutter:!0}):o instanceof nb?a=new Hp({source:o}):a=new Yp({source:o}),this.addLayer_(a,t),a})}async addGeoTiff_(t){if(!this.displayOverview_)return;if(this.buildTileUrlTemplate_&&!this.useTileLayerAsFallback_)return await this.addTileLayerForImagery_(t);let e={sources:[Aet(t,this.bands_)]};const i=await rb(t);i&&(e.projection=i),this.getSourceOptions_&&(e=await this.getSourceOptions_(Fe.GeoTIFF,e,t));const n=async(r,o)=>(o&&this.getLayers().remove(o),await this.addTileLayerForImagery_(r));try{const r=new bw(e),o=new Hp({source:r});if(this.useTileLayerAsFallback_){const a=()=>n(t,o);r.on("error",a),r.on("tileloaderror",a),r.on("change",()=>{r.getState()==="error"&&n(t,o)}),o.on("error",a),await r.getView()}return this.addLayer_(o,t),o}catch(r){if(this.useTileLayerAsFallback_)return await n(t,null);this.handleError_(r)}}async addTileLayerForImagery_(t){let e={crossOrigin:this.crossOrigin_,url:this.buildTileUrlTemplate_(t)};this.getSourceOptions_&&(e=await this.getSourceOptions_(Fe.XYZ,e,t));const i=new Yp({source:new hl(e)});return this.addLayer_(i,t),i}addLayer_(t,e,i=0){t.set("stac",e),t.setZIndex(i),this.getLayers().push(t)}addFootprint_(){let t=null;const e=this.getData();if(e.isItemCollection()||e.isCollectionCollection()?t=SL(e.getBoundingBox()):t=e.toGeoJSON(),t){const i=new DI,n=new s0({format:i,loader:(o,a,l)=>{const h=i.readFeatures(t,{featureProjection:l});n.addFeatures(h)}}),r=new Yv({source:n,style:ob(this.boundsStyle_,this),visible:this.displayFootprint_});return r.set("bounds",!0),this.addLayer_(r,e,1),r}return null}async updateLayers_(){const t=this.getLayers();for(let i=t.getLength()-1;i>=0;i--){const n=t.item(i).get("stac");n&&(n.isLink()||n.isAsset())&&t.removeAt(i)}const e=this.getData();e.isItemCollection()||e.isCollectionCollection()?await this.addApiCollection_():(e.isItem()||e.isCollection())&&await this.addStacAssets_(),this.displayWebMapLink_&&(Array.isArray(this.displayWebMapLink_)||this.hasOnlyBounds())&&await this.addWebMapLinks_()}hasOnlyBounds(){const t=this.getBoundsLayer();return typeof this.getLayersArray().find(e=>e!==t)>"u"}getWebMapLinks(){let t=["xyz","tilejson","pmtiles","wmts","wms"];typeof this.displayWebMapLink_=="string"&&(t=[this.displayWebMapLink_]);let e=this.data_.getLinksWithRels(t);return Array.isArray(this.displayWebMapLink_)?e=this.displayWebMapLink_.map(i=>typeof i=="string"?e.find(r=>r.id===i)||null:i).filter(i=>!!i):e.sort((i,n)=>{const r=t.indexOf(i.rel),o=t.indexOf(n.rel);return r-o}),e}async setAssets(t){Array.isArray(t)?this.assets_=t.map(e=>typeof e=="string"?this.getData().getAsset(e):e instanceof Qo?e:new Qo(e)):this.assets_=null,await this.updateLayers_()}getData(){return this.data_}getAssets(){return this.assets_}getExtent(){if(!this.boundsLayer_)return;const t=this.boundsLayer_.getMapInternal();if(!t)return;const e=t.getView();if(!e)return;const i=this.getData();if(!i)return;const n=i.getBoundingBox();if(n)return ev(n,"EPSG:4326",e.getProjection())}}function Fet(s){s("EPSG:4326","+title=WGS 84 (long/lat) +proj=longlat +ellps=WGS84 +datum=WGS84 +units=degrees"),s("EPSG:4269","+title=NAD83 (long/lat) +proj=longlat +a=6378137.0 +b=6356752.31414036 +ellps=GRS80 +datum=NAD83 +units=degrees"),s("EPSG:3857","+title=WGS 84 / Pseudo-Mercator +proj=merc +a=6378137 +b=6378137 +lat_ts=0.0 +lon_0=0.0 +x_0=0.0 +y_0=0 +k=1.0 +units=m +nadgrids=@null +no_defs"),s.WGS84=s["EPSG:4326"],s["EPSG:3785"]=s["EPSG:3857"],s.GOOGLE=s["EPSG:3857"],s["EPSG:900913"]=s["EPSG:3857"],s["EPSG:102113"]=s["EPSG:3857"]}var cl=1,ul=2,Dh=3,Net=4,xy=5,ab=6378137,Det=6356752314e-3,lb=.0066943799901413165,Ju=484813681109536e-20,K=Math.PI/2,ket=.16666666666666666,$et=.04722222222222222,Get=.022156084656084655,tt=1e-10,Ls=.017453292519943295,ur=57.29577951308232,ye=Math.PI/4,zd=Math.PI*2,es=3.14159265359,Fi={};Fi.greenwich=0;Fi.lisbon=-9.131906111111;Fi.paris=2.337229166667;Fi.bogota=-74.080916666667;Fi.madrid=-3.687938888889;Fi.rome=12.452333333333;Fi.bern=7.439583333333;Fi.jakarta=106.807719444444;Fi.ferro=-17.666666666667;Fi.brussels=4.367975;Fi.stockholm=18.058277777778;Fi.athens=23.7163375;Fi.oslo=10.722916666667;const jet={ft:{to_meter:.3048},"us-ft":{to_meter:1200/3937}};var hb=/[\s_\-\/\(\)]/g;function ca(s,t){if(s[t])return s[t];for(var e=Object.keys(s),i=t.toLowerCase().replace(hb,""),n=-1,r,o;++n=this.text.length)return;s=this.text[this.place++]}switch(this.state){case Ud:return this.neutral(s);case $L:return this.keyword(s);case tm:return this.quoted(s);case jL:return this.afterquote(s);case GL:return this.number(s);case $w:return}};xo.prototype.afterquote=function(s){if(s==='"'){this.word+='"',this.state=tm;return}if(w0.test(s)){this.word=this.word.trim(),this.afterItem(s);return}throw new Error(`havn't handled "`+s+'" in afterquote yet, index '+this.place)};xo.prototype.afterItem=function(s){if(s===","){this.word!==null&&this.currentObject.push(this.word),this.word=null,this.state=Ud;return}if(s==="]"){this.level--,this.word!==null&&(this.currentObject.push(this.word),this.word=null),this.state=Ud,this.currentObject=this.stack.pop(),this.currentObject||(this.state=$w);return}};xo.prototype.number=function(s){if(zL.test(s)){this.word+=s;return}if(w0.test(s)){this.word=parseFloat(this.word),this.afterItem(s);return}throw new Error(`havn't handled "`+s+'" in number yet, index '+this.place)};xo.prototype.quoted=function(s){if(s==='"'){this.state=jL;return}this.word+=s};xo.prototype.keyword=function(s){if(Bet.test(s)){this.word+=s;return}if(s==="["){var t=[];t.push(this.word),this.level++,this.root===null?this.root=t:this.currentObject.push(t),this.stack.push(this.currentObject),this.currentObject=t,this.state=Ud;return}if(w0.test(s)){this.afterItem(s);return}throw new Error(`havn't handled "`+s+'" in keyword yet, index '+this.place)};xo.prototype.neutral=function(s){if(Uet.test(s)){this.word=s,this.state=$L;return}if(s==='"'){this.word="",this.state=tm;return}if(zL.test(s)){this.word=s,this.state=GL;return}if(w0.test(s)){this.afterItem(s);return}throw new Error(`havn't handled "`+s+'" in neutral yet, index '+this.place)};xo.prototype.output=function(){for(;this.place0?90:-90),s.lat_ts=s.lat1):!s.lat_ts&&s.lat0&&s.projName==="Polar_Stereographic"&&(s.lat_ts=s.lat0,s.lat0=tr(s.lat0>0?90:-90))}function UL(s){var t=Wet(s),e=t.shift(),i=t.shift();t.unshift(["name",i]),t.unshift(["type",e]);var n={};return yh(t,n),Yet(n),n}function ti(s){var t=this;if(arguments.length===2){var e=arguments[1];typeof e=="string"?e.charAt(0)==="+"?ti[s]=vy(arguments[1]):ti[s]=UL(arguments[1]):ti[s]=e}else if(arguments.length===1){if(Array.isArray(s))return s.map(function(i){Array.isArray(i)?ti.apply(t,i):ti(i)});if(typeof s=="string"){if(s in ti)return ti[s]}else"EPSG"in s?ti["EPSG:"+s.EPSG]=s:"ESRI"in s?ti["ESRI:"+s.ESRI]=s:"IAU2000"in s?ti["IAU2000:"+s.IAU2000]=s:console.log(s);return}}Fet(ti);function qet(s){return typeof s=="string"}function Zet(s){return s in ti}var Het=["PROJECTEDCRS","PROJCRS","GEOGCS","GEOCCS","PROJCS","LOCAL_CS","GEODCRS","GEODETICCRS","GEODETICDATUM","ENGCRS","ENGINEERINGCRS"];function Ket(s){return Het.some(function(t){return s.indexOf(t)>-1})}var Jet=["3857","900913","3785","102113"];function Qet(s){var t=ca(s,"authority");if(t){var e=ca(t,"epsg");return e&&Jet.indexOf(e)>-1}}function tst(s){var t=ca(s,"extension");if(t)return ca(t,"proj4")}function est(s){return s[0]==="+"}function sst(s){if(qet(s)){if(Zet(s))return ti[s];if(Ket(s)){var t=UL(s);if(Qet(t))return ti["EPSG:3857"];var e=tst(t);return e?vy(e):t}if(est(s))return vy(s)}else return s}function ub(s,t){s=s||{};var e,i;if(!t)return s;for(i in t)e=t[i],e!==void 0&&(s[i]=e);return s}function wr(s,t,e){var i=s*t;return e/Math.sqrt(1-i*i)}function kg(s){return s<0?-1:1}function rt(s){return Math.abs(s)<=es?s:s-kg(s)*zd}function Gn(s,t,e){var i=s*e,n=.5*s;return i=Math.pow((1-i)/(1+i),n),Math.tan(.5*(K-t))/i}function Bd(s,t){for(var e=.5*s,i,n,r=K-2*Math.atan(t),o=0;o<=15;o++)if(i=s*Math.sin(r),n=K-2*Math.atan(t*Math.pow((1-i)/(1+i),e))-r,r+=n,Math.abs(n)<=1e-10)return r;return-9999}function ist(){var s=this.b/this.a;this.es=1-s*s,"x0"in this||(this.x0=0),"y0"in this||(this.y0=0),this.e=Math.sqrt(this.es),this.lat_ts?this.sphere?this.k0=Math.cos(this.lat_ts):this.k0=wr(this.e,Math.sin(this.lat_ts),Math.cos(this.lat_ts)):this.k0||(this.k?this.k0=this.k:this.k0=1)}function nst(s){var t=s.x,e=s.y;if(e*ur>90&&e*ur<-90&&t*ur>180&&t*ur<-180)return null;var i,n;if(Math.abs(Math.abs(e)-K)<=tt)return null;if(this.sphere)i=this.x0+this.a*this.k0*rt(t-this.long0),n=this.y0+this.a*this.k0*Math.log(Math.tan(ye+.5*e));else{var r=Math.sin(e),o=Gn(this.e,e,r);i=this.x0+this.a*this.k0*rt(t-this.long0),n=this.y0-this.a*this.k0*Math.log(o)}return s.x=i,s.y=n,s}function rst(s){var t=s.x-this.x0,e=s.y-this.y0,i,n;if(this.sphere)n=K-2*Math.atan(Math.exp(-e/(this.a*this.k0)));else{var r=Math.exp(-e/(this.a*this.k0));if(n=Bd(this.e,r),n===-9999)return null}return i=rt(this.long0+t/(this.a*this.k0)),s.x=i,s.y=n,s}var ost=["Mercator","Popular Visualisation Pseudo Mercator","Mercator_1SP","Mercator_Auxiliary_Sphere","merc"];const ast={init:ist,forward:nst,inverse:rst,names:ost};function lst(){}function db(s){return s}var hst=["longlat","identity"];const cst={init:lst,forward:db,inverse:db,names:hst};var ust=[ast,cst],Uf={},em=[];function BL(s,t){var e=em.length;return s.names?(em[e]=s,s.names.forEach(function(i){Uf[i.toLowerCase()]=e}),this):(console.log(t),!0)}function dst(s){if(!s)return!1;var t=s.toLowerCase();if(typeof Uf[t]<"u"&&em[Uf[t]])return em[Uf[t]]}function gst(){ust.forEach(BL)}const fst={start:gst,add:BL,get:dst};var $t={};$t.MERIT={a:6378137,rf:298.257,ellipseName:"MERIT 1983"};$t.SGS85={a:6378136,rf:298.257,ellipseName:"Soviet Geodetic System 85"};$t.GRS80={a:6378137,rf:298.257222101,ellipseName:"GRS 1980(IUGG, 1980)"};$t.IAU76={a:6378140,rf:298.257,ellipseName:"IAU 1976"};$t.airy={a:6377563396e-3,b:635625691e-2,ellipseName:"Airy 1830"};$t.APL4={a:6378137,rf:298.25,ellipseName:"Appl. Physics. 1965"};$t.NWL9D={a:6378145,rf:298.25,ellipseName:"Naval Weapons Lab., 1965"};$t.mod_airy={a:6377340189e-3,b:6356034446e-3,ellipseName:"Modified Airy"};$t.andrae={a:637710443e-2,rf:300,ellipseName:"Andrae 1876 (Den., Iclnd.)"};$t.aust_SA={a:6378160,rf:298.25,ellipseName:"Australian Natl & S. Amer. 1969"};$t.GRS67={a:6378160,rf:298.247167427,ellipseName:"GRS 67(IUGG 1967)"};$t.bessel={a:6377397155e-3,rf:299.1528128,ellipseName:"Bessel 1841"};$t.bess_nam={a:6377483865e-3,rf:299.1528128,ellipseName:"Bessel 1841 (Namibia)"};$t.clrk66={a:63782064e-1,b:63565838e-1,ellipseName:"Clarke 1866"};$t.clrk80={a:6378249145e-3,rf:293.4663,ellipseName:"Clarke 1880 mod."};$t.clrk80ign={a:63782492e-1,b:6356515,rf:293.4660213,ellipseName:"Clarke 1880 (IGN)"};$t.clrk58={a:6378293645208759e-9,rf:294.2606763692654,ellipseName:"Clarke 1858"};$t.CPM={a:63757387e-1,rf:334.29,ellipseName:"Comm. des Poids et Mesures 1799"};$t.delmbr={a:6376428,rf:311.5,ellipseName:"Delambre 1810 (Belgium)"};$t.engelis={a:637813605e-2,rf:298.2566,ellipseName:"Engelis 1985"};$t.evrst30={a:6377276345e-3,rf:300.8017,ellipseName:"Everest 1830"};$t.evrst48={a:6377304063e-3,rf:300.8017,ellipseName:"Everest 1948"};$t.evrst56={a:6377301243e-3,rf:300.8017,ellipseName:"Everest 1956"};$t.evrst69={a:6377295664e-3,rf:300.8017,ellipseName:"Everest 1969"};$t.evrstSS={a:6377298556e-3,rf:300.8017,ellipseName:"Everest (Sabah & Sarawak)"};$t.fschr60={a:6378166,rf:298.3,ellipseName:"Fischer (Mercury Datum) 1960"};$t.fschr60m={a:6378155,rf:298.3,ellipseName:"Fischer 1960"};$t.fschr68={a:6378150,rf:298.3,ellipseName:"Fischer 1968"};$t.helmert={a:6378200,rf:298.3,ellipseName:"Helmert 1906"};$t.hough={a:6378270,rf:297,ellipseName:"Hough"};$t.intl={a:6378388,rf:297,ellipseName:"International 1909 (Hayford)"};$t.kaula={a:6378163,rf:298.24,ellipseName:"Kaula 1961"};$t.lerch={a:6378139,rf:298.257,ellipseName:"Lerch 1979"};$t.mprts={a:6397300,rf:191,ellipseName:"Maupertius 1738"};$t.new_intl={a:63781575e-1,b:63567722e-1,ellipseName:"New International 1967"};$t.plessis={a:6376523,rf:6355863,ellipseName:"Plessis 1817 (France)"};$t.krass={a:6378245,rf:298.3,ellipseName:"Krassovsky, 1942"};$t.SEasia={a:6378155,b:63567733205e-4,ellipseName:"Southeast Asia"};$t.walbeck={a:6376896,b:63558348467e-4,ellipseName:"Walbeck"};$t.WGS60={a:6378165,rf:298.3,ellipseName:"WGS 60"};$t.WGS66={a:6378145,rf:298.25,ellipseName:"WGS 66"};$t.WGS7={a:6378135,rf:298.26,ellipseName:"WGS 72"};var pst=$t.WGS84={a:6378137,rf:298.257223563,ellipseName:"WGS 84"};$t.sphere={a:6370997,b:6370997,ellipseName:"Normal Sphere (r=6370997)"};function mst(s,t,e,i){var n=s*s,r=t*t,o=(n-r)/n,a=0;i?(s*=1-o*(ket+o*($et+o*Get)),n=s*s,o=0):a=Math.sqrt(o);var l=(n-r)/r;return{es:o,e:a,ep2:l}}function _st(s,t,e,i,n){if(!s){var r=ca($t,i);r||(r=pst),s=r.a,t=r.b,e=r.rf}return e&&!t&&(t=(1-1/e)*s),(e===0||Math.abs(s-t)3&&(a.datum_params[3]!==0||a.datum_params[4]!==0||a.datum_params[5]!==0||a.datum_params[6]!==0)&&(a.datum_type=ul,a.datum_params[3]*=Ju,a.datum_params[4]*=Ju,a.datum_params[5]*=Ju,a.datum_params[6]=a.datum_params[6]/1e6+1)),o&&(a.datum_type=Dh,a.grids=o),a.a=e,a.b=i,a.es=n,a.ep2=r,a}var WL={};function xst(s,t){var e=new DataView(t),i=Est(e),n=Sst(e,i),r=Mst(e,n,i),o={header:n,subgrids:r};return WL[s]=o,o}function vst(s){if(s===void 0)return null;var t=s.split(",");return t.map(wst)}function wst(s){if(s.length===0)return null;var t=s[0]==="@";return t&&(s=s.slice(1)),s==="null"?{name:"null",mandatory:!t,grid:null,isNull:!0}:{name:s,mandatory:!t,grid:WL[s]||null,isNull:!1}}function xh(s){return s/3600*Math.PI/180}function Est(s){var t=s.getInt32(8,!1);return t===11?!1:(t=s.getInt32(8,!0),t!==11&&console.warn("Failed to detect nadgrid endian-ness, defaulting to little-endian"),!0)}function Sst(s,t){return{nFields:s.getInt32(8,t),nSubgridFields:s.getInt32(24,t),nSubgrids:s.getInt32(40,t),shiftType:wy(s,56,64).trim(),fromSemiMajorAxis:s.getFloat64(120,t),fromSemiMinorAxis:s.getFloat64(136,t),toSemiMajorAxis:s.getFloat64(152,t),toSemiMinorAxis:s.getFloat64(168,t)}}function wy(s,t,e){return String.fromCharCode.apply(null,new Uint8Array(s.buffer.slice(t,e)))}function Mst(s,t,e){for(var i=176,n=[],r=0;r5e-11?!1:s.datum_type===cl?s.datum_params[0]===t.datum_params[0]&&s.datum_params[1]===t.datum_params[1]&&s.datum_params[2]===t.datum_params[2]:s.datum_type===ul?s.datum_params[0]===t.datum_params[0]&&s.datum_params[1]===t.datum_params[1]&&s.datum_params[2]===t.datum_params[2]&&s.datum_params[3]===t.datum_params[3]&&s.datum_params[4]===t.datum_params[4]&&s.datum_params[5]===t.datum_params[5]&&s.datum_params[6]===t.datum_params[6]:!0}function XL(s,t,e){var i=s.x,n=s.y,r=s.z?s.z:0,o,a,l,h;if(n<-K&&n>-1.001*K)n=-K;else if(n>K&&n<1.001*K)n=K;else{if(n<-K)return{x:-1/0,y:-1/0,z:s.z};if(n>K)return{x:1/0,y:1/0,z:s.z}}return i>Math.PI&&(i-=2*Math.PI),a=Math.sin(n),h=Math.cos(n),l=a*a,o=e/Math.sqrt(1-t*l),{x:(o+r)*h*Math.cos(i),y:(o+r)*h*Math.sin(i),z:(o*(1-t)+r)*a}}function VL(s,t,e,i){var n=1e-12,r=n*n,o=30,a,l,h,c,u,d,g,f,p,m,_,y,v,S=s.x,w=s.y,C=s.z?s.z:0,M,T,I;if(a=Math.sqrt(S*S+w*w),l=Math.sqrt(S*S+w*w+C*C),a/er&&vi.y||g>i.x||ma&&Math.abs(l.y)>a);if(o<0)return console.log("Inverse grid shift iterator failed to converge."),i;i.x=rt(r.x+e.ll[0]),i.y=r.y+e.ll[1]}else isNaN(r.x)||(i.x=s.x+r.x,i.y=s.y+r.y);return i}function fb(s,t){var e={x:s.x/t.del[0],y:s.y/t.del[1]},i={x:Math.floor(e.x),y:Math.floor(e.y)},n={x:e.x-1*i.x,y:e.y-1*i.y},r={x:Number.NaN,y:Number.NaN},o;if(i.x<0||i.x>=t.lim[0]||i.y<0||i.y>=t.lim[1])return r;o=i.y*t.lim[0]+i.x;var a={x:t.cvs[o][0],y:t.cvs[o][1]};o++;var l={x:t.cvs[o][0],y:t.cvs[o][1]};o+=t.lim[0];var h={x:t.cvs[o][0],y:t.cvs[o][1]};o--;var c={x:t.cvs[o][0],y:t.cvs[o][1]},u=n.x*n.y,d=n.x*(1-n.y),g=(1-n.x)*(1-n.y),f=(1-n.x)*n.y;return r.x=g*a.x+d*l.x+f*c.x+u*h.x,r.y=g*a.y+d*l.y+f*c.y+u*h.y,r}function pb(s,t,e){var i=e.x,n=e.y,r=e.z||0,o,a,l,h={};for(l=0;l<3;l++)if(!(t&&l===2&&e.z===void 0))switch(l===0?(o=i,"ew".indexOf(s.axis[l])!==-1?a="x":a="y"):l===1?(o=n,"ns".indexOf(s.axis[l])!==-1?a="y":a="x"):(o=r,a="z"),s.axis[l]){case"e":h[a]=o;break;case"w":h[a]=-o;break;case"n":h[a]=o;break;case"s":h[a]=-o;break;case"u":e[a]!==void 0&&(h.z=o);break;case"d":e[a]!==void 0&&(h.z=-o);break;default:return null}return h}function YL(s){var t={x:s[0],y:s[1]};return s.length>2&&(t.z=s[2]),s.length>3&&(t.m=s[3]),t}function Ost(s){mb(s.x),mb(s.y)}function mb(s){if(typeof Number.isFinite=="function"){if(Number.isFinite(s))return;throw new TypeError("coordinates must be finite numbers")}if(typeof s!="number"||s!==s||!isFinite(s))throw new TypeError("coordinates must be finite numbers")}function Fst(s,t){return(s.datum.datum_type===cl||s.datum.datum_type===ul||s.datum.datum_type===Dh)&&t.datumCode!=="WGS84"||(t.datum.datum_type===cl||t.datum.datum_type===ul||t.datum.datum_type===Dh)&&s.datumCode!=="WGS84"}function sm(s,t,e,i){var n;Array.isArray(e)?e=YL(e):e={x:e.x,y:e.y,z:e.z,m:e.m};var r=e.z!==void 0;if(Ost(e),s.datum&&t.datum&&Fst(s,t)&&(n=new pr("WGS84"),e=sm(s,n,e,i),s=n),i&&s.axis!=="enu"&&(e=pb(s,!1,e)),s.projName==="longlat")e={x:e.x*Ls,y:e.y*Ls,z:e.z||0};else if(s.to_meter&&(e={x:e.x*s.to_meter,y:e.y*s.to_meter,z:e.z||0}),e=s.inverse(e),!e)return;if(s.from_greenwich&&(e.x+=s.from_greenwich),e=Ast(s.datum,t.datum,e),!!e)return t.from_greenwich&&(e={x:e.x-t.from_greenwich,y:e.y,z:e.z||0}),t.projName==="longlat"?e={x:e.x*ur,y:e.y*ur,z:e.z||0}:(e=t.forward(e),t.to_meter&&(e={x:e.x/t.to_meter,y:e.y/t.to_meter,z:e.z||0})),i&&t.axis!=="enu"?pb(t,!0,e):(e&&!r&&delete e.z,e)}var _b=pr("WGS84");function Q_(s,t,e,i){var n,r,o;return Array.isArray(e)?(n=sm(s,t,e,i)||{x:NaN,y:NaN},e.length>2?typeof s.name<"u"&&s.name==="geocent"||typeof t.name<"u"&&t.name==="geocent"?typeof n.z=="number"?[n.x,n.y,n.z].concat(e.splice(3)):[n.x,n.y,e[2]].concat(e.splice(3)):[n.x,n.y].concat(e.splice(2)):[n.x,n.y]):(r=sm(s,t,e,i),o=Object.keys(e),o.length===2||o.forEach(function(a){if(typeof s.name<"u"&&s.name==="geocent"||typeof t.name<"u"&&t.name==="geocent"){if(a==="x"||a==="y"||a==="z")return}else if(a==="x"||a==="y")return;r[a]=e[a]}),r)}function yb(s){return s instanceof pr?s:s.oProj?s.oProj:pr(s)}function Hi(s,t,e){s=yb(s);var i=!1,n;return typeof t>"u"?(t=s,s=_b,i=!0):(typeof t.x<"u"||Array.isArray(t))&&(e=t,t=s,s=_b,i=!0),t=yb(t),e?Q_(s,t,e):(n={forward:function(r,o){return Q_(s,t,r,o)},inverse:function(r,o){return Q_(t,s,r,o)}},i&&(n.oProj=t),n)}var xb=6,qL="AJSAJS",ZL="AFAFAF",vh=65,mi=73,tn=79,Tu=86,Ru=90;const Nst={forward:HL,inverse:Dst,toPoint:KL};function HL(s,t){return t=t||5,Gst(kst({lat:s[1],lon:s[0]}),t)}function Dst(s){var t=Gw(QL(s.toUpperCase()));return t.lat&&t.lon?[t.lon,t.lat,t.lon,t.lat]:[t.left,t.bottom,t.right,t.top]}function KL(s){var t=Gw(QL(s.toUpperCase()));return t.lat&&t.lon?[t.lon,t.lat]:[(t.left+t.right)/2,(t.top+t.bottom)/2]}function t1(s){return s*(Math.PI/180)}function vb(s){return 180*(s/Math.PI)}function kst(s){var t=s.lat,e=s.lon,i=6378137,n=.00669438,r=.9996,o,a,l,h,c,u,d,g=t1(t),f=t1(e),p,m;m=Math.floor((e+180)/6)+1,e===180&&(m=60),t>=56&&t<64&&e>=3&&e<12&&(m=32),t>=72&&t<84&&(e>=0&&e<9?m=31:e>=9&&e<21?m=33:e>=21&&e<33?m=35:e>=33&&e<42&&(m=37)),o=(m-1)*6-180+3,p=t1(o),a=n/(1-n),l=i/Math.sqrt(1-n*Math.sin(g)*Math.sin(g)),h=Math.tan(g)*Math.tan(g),c=a*Math.cos(g)*Math.cos(g),u=Math.cos(g)*(f-p),d=i*((1-n/4-3*n*n/64-5*n*n*n/256)*g-(3*n/8+3*n*n/32+45*n*n*n/1024)*Math.sin(2*g)+(15*n*n/256+45*n*n*n/1024)*Math.sin(4*g)-35*n*n*n/3072*Math.sin(6*g));var _=r*l*(u+(1-h+c)*u*u*u/6+(5-18*h+h*h+72*c-58*a)*u*u*u*u*u/120)+5e5,y=r*(d+l*Math.tan(g)*(u*u/2+(5-h+9*c+4*c*c)*u*u*u*u/24+(61-58*h+h*h+600*c-330*a)*u*u*u*u*u*u/720));return t<0&&(y+=1e7),{northing:Math.round(y),easting:Math.round(_),zoneNumber:m,zoneLetter:$st(t)}}function Gw(s){var t=s.northing,e=s.easting,i=s.zoneLetter,n=s.zoneNumber;if(n<0||n>60)return null;var r=.9996,o=6378137,a=.00669438,l,h=(1-Math.sqrt(1-a))/(1+Math.sqrt(1-a)),c,u,d,g,f,p,m,_,y,v=e-5e5,S=t;i<"N"&&(S-=1e7),m=(n-1)*6-180+3,l=a/(1-a),p=S/r,_=p/(o*(1-a/4-3*a*a/64-5*a*a*a/256)),y=_+(3*h/2-27*h*h*h/32)*Math.sin(2*_)+(21*h*h/16-55*h*h*h*h/32)*Math.sin(4*_)+151*h*h*h/96*Math.sin(6*_),c=o/Math.sqrt(1-a*Math.sin(y)*Math.sin(y)),u=Math.tan(y)*Math.tan(y),d=l*Math.cos(y)*Math.cos(y),g=o*(1-a)/Math.pow(1-a*Math.sin(y)*Math.sin(y),1.5),f=v/(c*r);var w=y-c*Math.tan(y)/g*(f*f/2-(5+3*u+10*d-4*d*d-9*l)*f*f*f*f/24+(61+90*u+298*d+45*u*u-252*l-3*d*d)*f*f*f*f*f*f/720);w=vb(w);var C=(f-(1+2*u+d)*f*f*f/6+(5-2*d+28*u-3*d*d+8*l+24*u*u)*f*f*f*f*f/120)/Math.cos(y);C=m+vb(C);var M;if(s.accuracy){var T=Gw({northing:s.northing+s.accuracy,easting:s.easting+s.accuracy,zoneLetter:s.zoneLetter,zoneNumber:s.zoneNumber});M={top:T.lat,right:T.lon,bottom:w,left:C}}else M={lat:w,lon:C};return M}function $st(s){var t="Z";return 84>=s&&s>=72?t="X":72>s&&s>=64?t="W":64>s&&s>=56?t="V":56>s&&s>=48?t="U":48>s&&s>=40?t="T":40>s&&s>=32?t="S":32>s&&s>=24?t="R":24>s&&s>=16?t="Q":16>s&&s>=8?t="P":8>s&&s>=0?t="N":0>s&&s>=-8?t="M":-8>s&&s>=-16?t="L":-16>s&&s>=-24?t="K":-24>s&&s>=-32?t="J":-32>s&&s>=-40?t="H":-40>s&&s>=-48?t="G":-48>s&&s>=-56?t="F":-56>s&&s>=-64?t="E":-64>s&&s>=-72?t="D":-72>s&&s>=-80&&(t="C"),t}function Gst(s,t){var e="00000"+s.easting,i="00000"+s.northing;return s.zoneNumber+s.zoneLetter+jst(s.easting,s.northing,s.zoneNumber)+e.substr(e.length-5,t)+i.substr(i.length-5,t)}function jst(s,t,e){var i=JL(e),n=Math.floor(s/1e5),r=Math.floor(t/1e5)%20;return zst(n,r,i)}function JL(s){var t=s%xb;return t===0&&(t=xb),t}function zst(s,t,e){var i=e-1,n=qL.charCodeAt(i),r=ZL.charCodeAt(i),o=n+s-1,a=r+t,l=!1;o>Ru&&(o=o-Ru+vh-1,l=!0),(o===mi||nmi||(o>mi||ntn||(o>tn||nRu&&(o=o-Ru+vh-1),a>Tu?(a=a-Tu+vh-1,l=!0):l=!1,(a===mi||rmi||(a>mi||rtn||(a>tn||rTu&&(a=a-Tu+vh-1);var h=String.fromCharCode(o)+String.fromCharCode(a);return h}function QL(s){if(s&&s.length===0)throw"MGRSPoint coverting from nothing";for(var t=s.length,e=null,i="",n,r=0;!/[A-Z]/.test(n=s.charAt(r));){if(r>=2)throw"MGRSPoint bad conversion from: "+s;i+=n,r++}var o=parseInt(i,10);if(r===0||r+3>t)throw"MGRSPoint bad conversion from: "+s;var a=s.charAt(r++);if(a<="A"||a==="B"||a==="Y"||a>="Z"||a==="I"||a==="O")throw"MGRSPoint zone letter "+a+" not handled: "+s;e=s.substring(r,r+=2);for(var l=JL(o),h=Ust(e.charAt(0),l),c=Bst(e.charAt(1),l);c0&&(p=1e5/Math.pow(10,d),m=s.substring(r,r+d),g=parseFloat(m)*p,_=s.substring(r+d),f=parseFloat(_)*p),y=g+h,v=f+c,{easting:y,northing:v,zoneLetter:a,zoneNumber:o,accuracy:p}}function Ust(s,t){for(var e=qL.charCodeAt(t-1),i=1e5,n=!1;e!==s.charCodeAt(0);){if(e++,e===mi&&e++,e===tn&&e++,e>Ru){if(n)throw"Bad character: "+s;e=vh,n=!0}i+=1e5}return i}function Bst(s,t){if(s>"V")throw"MGRSPoint given invalid Northing "+s;for(var e=ZL.charCodeAt(t-1),i=0,n=!1;e!==s.charCodeAt(0);){if(e++,e===mi&&e++,e===tn&&e++,e>Cu){if(n)throw"Bad character: "+s;e=vh,n=!0}i+=1e5}return i}function Wst(s){var t;switch(s){case"C":t=11e5;break;case"D":t=2e6;break;case"E":t=28e5;break;case"F":t=37e5;break;case"G":t=46e5;break;case"H":t=55e5;break;case"J":t=64e5;break;case"K":t=73e5;break;case"L":t=82e5;break;case"M":t=91e5;break;case"N":t=0;break;case"P":t=8e5;break;case"Q":t=17e5;break;case"R":t=26e5;break;case"S":t=35e5;break;case"T":t=44e5;break;case"U":t=53e5;break;case"V":t=62e5;break;case"W":t=7e6;break;case"X":t=79e5;break;default:t=-1}if(t>=0)return t;throw"Invalid zone letter: "+s}function pc(s,t,e){if(!(this instanceof pc))return new pc(s,t,e);if(Array.isArray(s))this.x=s[0],this.y=s[1],this.z=s[2]||0;else if(typeof s=="object")this.x=s.x,this.y=s.y,this.z=s.z||0;else if(typeof s=="string"&&typeof t>"u"){var i=s.split(",");this.x=parseFloat(i[0],10),this.y=parseFloat(i[1],10),this.z=parseFloat(i[2],10)||0}else this.x=s,this.y=t,this.z=e||0;console.warn("proj4.Point will be removed in version 3, use proj4.toPoint")}pc.fromMGRS=function(s){return new pc(KL(s))};pc.prototype.toMGRS=function(s){return HL([this.x,this.y],s)};var Xst=1,Vst=.25,wb=.046875,Eb=.01953125,Sb=.01068115234375,Yst=.75,qst=.46875,Zst=.013020833333333334,Hst=.007120768229166667,Kst=.3645833333333333,Jst=.005696614583333333,Qst=.3076171875;function tO(s){var t=[];t[0]=Xst-s*(Vst+s*(wb+s*(Eb+s*Sb))),t[1]=s*(Yst-s*(wb+s*(Eb+s*Sb)));var e=s*s;return t[2]=e*(qst-s*(Zst+s*Hst)),e*=s,t[3]=e*(Kst-s*Jst),t[4]=e*s*Qst,t}function E0(s,t,e,i){return e*=t,t*=t,i[0]*s-e*(i[1]+t*(i[2]+t*(i[3]+t*i[4])))}var tit=20;function eO(s,t,e){for(var i=1/(1-t),n=s,r=tit;r;--r){var o=Math.sin(n),a=1-t*o*o;if(a=(E0(n,o,Math.cos(n),e)-s)*(a*Math.sqrt(a))*i,n-=a,Math.abs(a)tt?Math.tan(e):0,f=Math.pow(g,2),p=Math.pow(f,2);n=1-this.es*Math.pow(a,2),h=h/Math.sqrt(n);var m=E0(e,a,l,this.en);r=this.a*(this.k0*h*(1+c/6*(1-f+u+c/20*(5-18*f+p+14*u-58*f*u+c/42*(61+179*p-p*f-479*f)))))+this.x0,o=this.a*(this.k0*(m-this.ml0+a*i*h/2*(1+c/12*(5-f+9*u+4*d+c/30*(61+p-58*f+270*u-330*f*u+c/56*(1385+543*p-p*f-3111*f))))))+this.y0}else{var _=l*Math.sin(i);if(Math.abs(Math.abs(_)-1)=1){if(_-1>tt)return 93;o=0}else o=Math.acos(o);e<0&&(o=-o),o=this.a*this.k0*(o-this.lat0)+this.y0}return s.x=r,s.y=o,s}function iit(s){var t,e,i,n,r=(s.x-this.x0)*(1/this.a),o=(s.y-this.y0)*(1/this.a);if(this.es)if(t=this.ml0+o/this.k0,e=eO(t,this.es,this.en),Math.abs(e)tt?Math.tan(e):0,c=this.ep2*Math.pow(l,2),u=Math.pow(c,2),d=Math.pow(h,2),g=Math.pow(d,2);t=1-this.es*Math.pow(a,2);var f=r*Math.sqrt(t)/this.k0,p=Math.pow(f,2);t=t*h,i=e-t*p/(1-this.es)*.5*(1-p/12*(5+3*d-9*c*d+c-4*u-p/30*(61+90*d-252*c*d+45*g+46*c-p/56*(1385+3633*d+4095*g+1574*g*d)))),n=rt(this.long0+f*(1-p/6*(1+2*d+c-p/20*(5+28*d+24*g+8*c*d+6*c-p/42*(61+662*d+1320*g+720*g*d))))/l)}else i=K*kg(o),n=0;else{var m=Math.exp(r/this.k0),_=.5*(m-1/m),y=this.lat0+o/this.k0,v=Math.cos(y);t=Math.sqrt((1-Math.pow(v,2))/(1+Math.pow(_,2))),i=Math.asin(t),o<0&&(i=-i),_===0&&v===0?n=0:n=rt(Math.atan2(_,v)+this.long0)}return s.x=n,s.y=i,s}var nit=["Fast_Transverse_Mercator","Fast Transverse Mercator"];const Bf={init:eit,forward:sit,inverse:iit,names:nit};function sO(s){var t=Math.exp(s);return t=(t-1/t)/2,t}function on(s,t){s=Math.abs(s),t=Math.abs(t);var e=Math.max(s,t),i=Math.min(s,t)/(e||1);return e*Math.sqrt(1+Math.pow(i,2))}function rit(s){var t=1+s,e=t-1;return e===0?s:s*Math.log(t)/e}function oit(s){var t=Math.abs(s);return t=rit(t*(1+t/(on(1,t)+1))),s<0?-t:t}function jw(s,t){for(var e=2*Math.cos(2*t),i=s.length-1,n=s[i],r=0,o;--i>=0;)o=-r+e*n+s[i],r=n,n=o;return t+o*Math.sin(2*t)}function ait(s,t){for(var e=2*Math.cos(t),i=s.length-1,n=s[i],r=0,o;--i>=0;)o=-r+e*n+s[i],r=n,n=o;return Math.sin(t)*o}function lit(s){var t=Math.exp(s);return t=(t+1/t)/2,t}function iO(s,t,e){for(var i=Math.sin(t),n=Math.cos(t),r=sO(e),o=lit(e),a=2*n*o,l=-2*i*r,h=s.length-1,c=s[h],u=0,d=0,g=0,f,p;--h>=0;)f=d,p=u,d=c,u=g,c=-f+a*d-l*u+s[h],g=-p+l*d+a*u;return a=i*o,l=n*r,[a*c-l*g,a*g+l*c]}function hit(){if(!this.approx&&(isNaN(this.es)||this.es<=0))throw new Error('Incorrect elliptical usage. Try using the +approx option in the proj string, or PROJECTION["Fast_Transverse_Mercator"] in the WKT.');this.approx&&(Bf.init.apply(this),this.forward=Bf.forward,this.inverse=Bf.inverse),this.x0=this.x0!==void 0?this.x0:0,this.y0=this.y0!==void 0?this.y0:0,this.long0=this.long0!==void 0?this.long0:0,this.lat0=this.lat0!==void 0?this.lat0:0,this.cgb=[],this.cbg=[],this.utg=[],this.gtu=[];var s=this.es/(1+Math.sqrt(1-this.es)),t=s/(2-s),e=t;this.cgb[0]=t*(2+t*(-2/3+t*(-2+t*(116/45+t*(26/45+t*(-2854/675)))))),this.cbg[0]=t*(-2+t*(2/3+t*(4/3+t*(-82/45+t*(32/45+t*(4642/4725)))))),e=e*t,this.cgb[1]=e*(7/3+t*(-8/5+t*(-227/45+t*(2704/315+t*(2323/945))))),this.cbg[1]=e*(5/3+t*(-16/15+t*(-13/9+t*(904/315+t*(-1522/945))))),e=e*t,this.cgb[2]=e*(56/15+t*(-136/35+t*(-1262/105+t*(73814/2835)))),this.cbg[2]=e*(-26/15+t*(34/21+t*(8/5+t*(-12686/2835)))),e=e*t,this.cgb[3]=e*(4279/630+t*(-332/35+t*(-399572/14175))),this.cbg[3]=e*(1237/630+t*(-12/5+t*(-24832/14175))),e=e*t,this.cgb[4]=e*(4174/315+t*(-144838/6237)),this.cbg[4]=e*(-734/315+t*(109598/31185)),e=e*t,this.cgb[5]=e*(601676/22275),this.cbg[5]=e*(444337/155925),e=Math.pow(t,2),this.Qn=this.k0/(1+t)*(1+e*(1/4+e*(1/64+e/256))),this.utg[0]=t*(-.5+t*(2/3+t*(-37/96+t*(1/360+t*(81/512+t*(-96199/604800)))))),this.gtu[0]=t*(.5+t*(-2/3+t*(5/16+t*(41/180+t*(-127/288+t*(7891/37800)))))),this.utg[1]=e*(-1/48+t*(-1/15+t*(437/1440+t*(-46/105+t*(1118711/3870720))))),this.gtu[1]=e*(13/48+t*(-3/5+t*(557/1440+t*(281/630+t*(-1983433/1935360))))),e=e*t,this.utg[2]=e*(-17/480+t*(37/840+t*(209/4480+t*(-5569/90720)))),this.gtu[2]=e*(61/240+t*(-103/140+t*(15061/26880+t*(167603/181440)))),e=e*t,this.utg[3]=e*(-4397/161280+t*(11/504+t*(830251/7257600))),this.gtu[3]=e*(49561/161280+t*(-179/168+t*(6601661/7257600))),e=e*t,this.utg[4]=e*(-4583/161280+t*(108847/3991680)),this.gtu[4]=e*(34729/80640+t*(-3418889/1995840)),e=e*t,this.utg[5]=e*(-20648693/638668800),this.gtu[5]=e*(212378941/319334400);var i=jw(this.cbg,this.lat0);this.Zb=-this.Qn*(i+ait(this.gtu,2*i))}function cit(s){var t=rt(s.x-this.long0),e=s.y;e=jw(this.cbg,e);var i=Math.sin(e),n=Math.cos(e),r=Math.sin(t),o=Math.cos(t);e=Math.atan2(i,o*n),t=Math.atan2(r*n,on(i,n*o)),t=oit(Math.tan(t));var a=iO(this.gtu,2*e,2*t);e=e+a[0],t=t+a[1];var l,h;return Math.abs(t)<=2.623395162778?(l=this.a*(this.Qn*t)+this.x0,h=this.a*(this.Qn*e+this.Zb)+this.y0):(l=1/0,h=1/0),s.x=l,s.y=h,s}function uit(s){var t=(s.x-this.x0)*(1/this.a),e=(s.y-this.y0)*(1/this.a);e=(e-this.Zb)/this.Qn,t=t/this.Qn;var i,n;if(Math.abs(t)<=2.623395162778){var r=iO(this.utg,2*e,2*t);e=e+r[0],t=t+r[1],t=Math.atan(sO(t));var o=Math.sin(e),a=Math.cos(e),l=Math.sin(t),h=Math.cos(t);e=Math.atan2(o*h,on(l,h*a)),t=Math.atan2(l,h*a),i=rt(t+this.long0),n=jw(this.cgb,e)}else i=1/0,n=1/0;return s.x=i,s.y=n,s}var dit=["Extended_Transverse_Mercator","Extended Transverse Mercator","etmerc","Transverse_Mercator","Transverse Mercator","Gauss Kruger","Gauss_Kruger","tmerc"];const Wf={init:hit,forward:cit,inverse:uit,names:dit};function git(s,t){if(s===void 0){if(s=Math.floor((rt(t)+Math.PI)*30/Math.PI)+1,s<0)return 0;if(s>60)return 60}return s}var fit="etmerc";function pit(){var s=git(this.zone,this.long0);if(s===void 0)throw new Error("unknown utm zone");this.lat0=0,this.long0=(6*Math.abs(s)-183)*Ls,this.x0=5e5,this.y0=this.utmSouth?1e7:0,this.k0=.9996,Wf.init.apply(this),this.forward=Wf.forward,this.inverse=Wf.inverse}var mit=["Universal Transverse Mercator System","utm"];const _it={init:pit,names:mit,dependsOn:fit};function zw(s,t){return Math.pow((1-s)/(1+s),t)}var yit=20;function xit(){var s=Math.sin(this.lat0),t=Math.cos(this.lat0);t*=t,this.rc=Math.sqrt(1-this.es)/(1-this.es*s*s),this.C=Math.sqrt(1+this.es*t*t/(1-this.es)),this.phic0=Math.asin(s/this.C),this.ratexp=.5*this.C*this.e,this.K=Math.tan(.5*this.phic0+ye)/(Math.pow(Math.tan(.5*this.lat0+ye),this.C)*zw(this.e*s,this.ratexp))}function vit(s){var t=s.x,e=s.y;return s.y=2*Math.atan(this.K*Math.pow(Math.tan(.5*e+ye),this.C)*zw(this.e*Math.sin(e),this.ratexp))-K,s.x=this.C*t,s}function wit(s){for(var t=1e-14,e=s.x/this.C,i=s.y,n=Math.pow(Math.tan(.5*i+ye)/this.K,1/this.C),r=yit;r>0&&(i=2*Math.atan(n*zw(this.e*Math.sin(s.y),-.5*this.e))-K,!(Math.abs(i-s.y)0?this.con=1:this.con=-1),this.cons=Math.sqrt(Math.pow(1+this.e,1+this.e)*Math.pow(1-this.e,1-this.e)),this.k0===1&&!isNaN(this.lat_ts)&&Math.abs(this.coslat0)<=tt&&Math.abs(Math.cos(this.lat_ts))>tt&&(this.k0=.5*this.cons*wr(this.e,Math.sin(this.lat_ts),Math.cos(this.lat_ts))/Gn(this.e,this.con*this.lat_ts,this.con*Math.sin(this.lat_ts))),this.ms1=wr(this.e,this.sinlat0,this.coslat0),this.X0=2*Math.atan(this.ssfn_(this.lat0,this.sinlat0,this.e))-K,this.cosX0=Math.cos(this.X0),this.sinX0=Math.sin(this.X0))}function Pit(s){var t=s.x,e=s.y,i=Math.sin(e),n=Math.cos(e),r,o,a,l,h,c,u=rt(t-this.long0);return Math.abs(Math.abs(t-this.long0)-Math.PI)<=tt&&Math.abs(e+this.lat0)<=tt?(s.x=NaN,s.y=NaN,s):this.sphere?(r=2*this.k0/(1+this.sinlat0*i+this.coslat0*n*Math.cos(u)),s.x=this.a*r*n*Math.sin(u)+this.x0,s.y=this.a*r*(this.coslat0*i-this.sinlat0*n*Math.cos(u))+this.y0,s):(o=2*Math.atan(this.ssfn_(e,i,this.e))-K,l=Math.cos(o),a=Math.sin(o),Math.abs(this.coslat0)<=tt?(h=Gn(this.e,e*this.con,this.con*i),c=2*this.a*this.k0*h/this.cons,s.x=this.x0+c*Math.sin(t-this.long0),s.y=this.y0-this.con*c*Math.cos(t-this.long0),s):(Math.abs(this.sinlat0)0?t=rt(this.long0+Math.atan2(s.x,-1*s.y)):t=rt(this.long0+Math.atan2(s.x,s.y)):t=rt(this.long0+Math.atan2(s.x*Math.sin(a),o*this.coslat0*Math.cos(a)-s.y*this.sinlat0*Math.sin(a))),s.x=t,s.y=e,s)}else if(Math.abs(this.coslat0)<=tt){if(o<=tt)return e=this.lat0,t=this.long0,s.x=t,s.y=e,s;s.x*=this.con,s.y*=this.con,i=o*this.cons/(2*this.a*this.k0),e=this.con*Bd(this.e,i),t=this.con*rt(this.con*this.long0+Math.atan2(s.x,-1*s.y))}else n=2*Math.atan(o*this.cosX0/(2*this.a*this.k0*this.ms1)),t=this.long0,o<=tt?r=this.X0:(r=Math.asin(Math.cos(n)*this.sinX0+s.y*Math.sin(n)*this.cosX0/o),t=rt(this.long0+Math.atan2(s.x*Math.sin(n),o*this.cosX0*Math.cos(n)-s.y*this.sinX0*Math.sin(n)))),e=-1*Bd(this.e,Math.tan(.5*(K+r)));return s.x=t,s.y=e,s}var Lit=["stere","Stereographic_South_Pole","Polar Stereographic (variant B)","Polar_Stereographic"];const Oit={init:Iit,forward:Pit,inverse:Ait,names:Lit,ssfn_:Rit};function Fit(){var s=this.lat0;this.lambda0=this.long0;var t=Math.sin(s),e=this.a,i=this.rf,n=1/i,r=2*n-Math.pow(n,2),o=this.e=Math.sqrt(r);this.R=this.k0*e*Math.sqrt(1-r)/(1-r*Math.pow(t,2)),this.alpha=Math.sqrt(1+r/(1-r)*Math.pow(Math.cos(s),4)),this.b0=Math.asin(t/this.alpha);var a=Math.log(Math.tan(Math.PI/4+this.b0/2)),l=Math.log(Math.tan(Math.PI/4+s/2)),h=Math.log((1+o*t)/(1-o*t));this.K=a-this.alpha*l+this.alpha*o/2*h}function Nit(s){var t=Math.log(Math.tan(Math.PI/4-s.y/2)),e=this.e/2*Math.log((1+this.e*Math.sin(s.y))/(1-this.e*Math.sin(s.y))),i=-this.alpha*(t+e)+this.K,n=2*(Math.atan(Math.exp(i))-Math.PI/4),r=this.alpha*(s.x-this.lambda0),o=Math.atan(Math.sin(r)/(Math.sin(this.b0)*Math.tan(n)+Math.cos(this.b0)*Math.cos(r))),a=Math.asin(Math.cos(this.b0)*Math.sin(n)-Math.sin(this.b0)*Math.cos(n)*Math.cos(r));return s.y=this.R/2*Math.log((1+Math.sin(a))/(1-Math.sin(a)))+this.y0,s.x=this.R*o+this.x0,s}function Dit(s){for(var t=s.x-this.x0,e=s.y-this.y0,i=t/this.R,n=2*(Math.atan(Math.exp(e/this.R))-Math.PI/4),r=Math.asin(Math.cos(this.b0)*Math.sin(n)+Math.sin(this.b0)*Math.cos(n)*Math.cos(i)),o=Math.atan(Math.sin(i)/(Math.cos(this.b0)*Math.cos(i)-Math.sin(this.b0)*Math.tan(n))),a=this.lambda0+o/this.alpha,l=0,h=r,c=-1e3,u=0;Math.abs(h-c)>1e-7;){if(++u>20)return;l=1/this.alpha*(Math.log(Math.tan(Math.PI/4+r/2))-this.K)+this.e*Math.log(Math.tan(Math.PI/4+Math.asin(this.e*Math.sin(h))/2)),c=h,h=2*Math.atan(Math.exp(l))-Math.PI/2}return s.x=a,s.y=h,s}var kit=["somerc"];const $it={init:Fit,forward:Nit,inverse:Dit,names:kit};var sh=1e-7;function Git(s){var t=["Hotine_Oblique_Mercator","Hotine_Oblique_Mercator_Azimuth_Natural_Origin"],e=typeof s.PROJECTION=="object"?Object.keys(s.PROJECTION)[0]:s.PROJECTION;return"no_uoff"in s||"no_off"in s||t.indexOf(e)!==-1}function jit(){var s,t,e,i,n,r,o,a,l,h,c=0,u,d=0,g=0,f=0,p=0,m=0,_=0;this.no_off=Git(this),this.no_rot="no_rot"in this;var y=!1;"alpha"in this&&(y=!0);var v=!1;if("rectified_grid_angle"in this&&(v=!0),y&&(_=this.alpha),v&&(c=this.rectified_grid_angle*Ls),y||v)d=this.longc;else if(g=this.long1,p=this.lat1,f=this.long2,m=this.lat2,Math.abs(p-m)<=sh||(s=Math.abs(p))<=sh||Math.abs(s-K)<=sh||Math.abs(Math.abs(this.lat0)-K)<=sh||Math.abs(Math.abs(m)-K)<=sh)throw new Error;var S=1-this.es;t=Math.sqrt(S),Math.abs(this.lat0)>tt?(a=Math.sin(this.lat0),e=Math.cos(this.lat0),s=1-this.es*a*a,this.B=e*e,this.B=Math.sqrt(1+this.es*this.B*this.B/S),this.A=this.B*this.k0*t/s,i=this.B*t/(e*Math.sqrt(s)),n=i*i-1,n<=0?n=0:(n=Math.sqrt(n),this.lat0<0&&(n=-n)),this.E=n+=i,this.E*=Math.pow(Gn(this.e,this.lat0,a),this.B)):(this.B=1/t,this.A=this.k0,this.E=i=n=1),y||v?(y?(u=Math.asin(Math.sin(_)/i),v||(c=_)):(u=c,_=Math.asin(i*Math.sin(u))),this.lam0=d-Math.asin(.5*(n-1/n)*Math.tan(u))/this.B):(r=Math.pow(Gn(this.e,p,Math.sin(p)),this.B),o=Math.pow(Gn(this.e,m,Math.sin(m)),this.B),n=this.E/r,l=(o-r)/(o+r),h=this.E*this.E,h=(h-o*r)/(h+o*r),s=g-f,s<-Math.pi?f-=zd:s>Math.pi&&(f+=zd),this.lam0=rt(.5*(g+f)-Math.atan(h*Math.tan(.5*this.B*(g-f))/l)/this.B),u=Math.atan(2*Math.sin(this.B*rt(g-this.lam0))/(n-1/n)),c=_=Math.asin(i*Math.sin(u))),this.singam=Math.sin(u),this.cosgam=Math.cos(u),this.sinrot=Math.sin(c),this.cosrot=Math.cos(c),this.rB=1/this.B,this.ArB=this.A*this.rB,this.BrA=1/this.ArB,this.A*this.B,this.no_off?this.u_0=0:(this.u_0=Math.abs(this.ArB*Math.atan(Math.sqrt(i*i-1)/Math.cos(_))),this.lat0<0&&(this.u_0=-this.u_0)),n=.5*u,this.v_pole_n=this.ArB*Math.log(Math.tan(ye-n)),this.v_pole_s=this.ArB*Math.log(Math.tan(ye+n))}function zit(s){var t={},e,i,n,r,o,a,l,h;if(s.x=s.x-this.lam0,Math.abs(Math.abs(s.y)-K)>tt){if(o=this.E/Math.pow(Gn(this.e,s.y,Math.sin(s.y)),this.B),a=1/o,e=.5*(o-a),i=.5*(o+a),r=Math.sin(this.B*s.x),n=(e*this.singam-r*this.cosgam)/i,Math.abs(Math.abs(n)-1)0?this.v_pole_n:this.v_pole_s,l=this.ArB*s.y;return this.no_rot?(t.x=l,t.y=h):(l-=this.u_0,t.x=h*this.cosrot+l*this.sinrot,t.y=l*this.cosrot-h*this.sinrot),t.x=this.a*t.x+this.x0,t.y=this.a*t.y+this.y0,t}function Uit(s){var t,e,i,n,r,o,a,l={};if(s.x=(s.x-this.x0)*(1/this.a),s.y=(s.y-this.y0)*(1/this.a),this.no_rot?(e=s.y,t=s.x):(e=s.x*this.cosrot-s.y*this.sinrot,t=s.y*this.cosrot+s.x*this.sinrot+this.u_0),i=Math.exp(-this.BrA*e),n=.5*(i-1/i),r=.5*(i+1/i),o=Math.sin(this.BrA*t),a=(o*this.cosgam+n*this.singam)/r,Math.abs(Math.abs(a)-1)tt?this.ns=Math.log(i/a)/Math.log(n/l):this.ns=t,isNaN(this.ns)&&(this.ns=t),this.f0=i/(this.ns*Math.pow(n,this.ns)),this.rh=this.a*this.f0*Math.pow(h,this.ns),this.title||(this.title="Lambert Conformal Conic")}}function Vit(s){var t=s.x,e=s.y;Math.abs(2*Math.abs(e)-Math.PI)<=tt&&(e=kg(e)*(K-2*tt));var i=Math.abs(Math.abs(e)-K),n,r;if(i>tt)n=Gn(this.e,e,Math.sin(e)),r=this.a*this.f0*Math.pow(n,this.ns);else{if(i=e*this.ns,i<=0)return null;r=0}var o=this.ns*rt(t-this.long0);return s.x=this.k0*(r*Math.sin(o))+this.x0,s.y=this.k0*(this.rh-r*Math.cos(o))+this.y0,s}function Yit(s){var t,e,i,n,r,o=(s.x-this.x0)/this.k0,a=this.rh-(s.y-this.y0)/this.k0;this.ns>0?(t=Math.sqrt(o*o+a*a),e=1):(t=-Math.sqrt(o*o+a*a),e=-1);var l=0;if(t!==0&&(l=Math.atan2(e*o,e*a)),t!==0||this.ns>0){if(e=1/this.ns,i=Math.pow(t/(this.a*this.f0),e),n=Bd(this.e,i),n===-9999)return null}else n=-K;return r=rt(l/this.ns+this.long0),s.x=r,s.y=n,s}var qit=["Lambert Tangential Conformal Conic Projection","Lambert_Conformal_Conic","Lambert_Conformal_Conic_1SP","Lambert_Conformal_Conic_2SP","lcc","Lambert Conic Conformal (1SP)","Lambert Conic Conformal (2SP)"];const Zit={init:Xit,forward:Vit,inverse:Yit,names:qit};function Hit(){this.a=6377397155e-3,this.es=.006674372230614,this.e=Math.sqrt(this.es),this.lat0||(this.lat0=.863937979737193),this.long0||(this.long0=.7417649320975901-.308341501185665),this.k0||(this.k0=.9999),this.s45=.785398163397448,this.s90=2*this.s45,this.fi0=this.lat0,this.e2=this.es,this.e=Math.sqrt(this.e2),this.alfa=Math.sqrt(1+this.e2*Math.pow(Math.cos(this.fi0),4)/(1-this.e2)),this.uq=1.04216856380474,this.u0=Math.asin(Math.sin(this.fi0)/this.alfa),this.g=Math.pow((1+this.e*Math.sin(this.fi0))/(1-this.e*Math.sin(this.fi0)),this.alfa*this.e/2),this.k=Math.tan(this.u0/2+this.s45)/Math.pow(Math.tan(this.fi0/2+this.s45),this.alfa)*this.g,this.k1=this.k0,this.n0=this.a*Math.sqrt(1-this.e2)/(1-this.e2*Math.pow(Math.sin(this.fi0),2)),this.s0=1.37008346281555,this.n=Math.sin(this.s0),this.ro0=this.k1*this.n0/Math.tan(this.s0),this.ad=this.s90-this.uq}function Kit(s){var t,e,i,n,r,o,a,l=s.x,h=s.y,c=rt(l-this.long0);return t=Math.pow((1+this.e*Math.sin(h))/(1-this.e*Math.sin(h)),this.alfa*this.e/2),e=2*(Math.atan(this.k*Math.pow(Math.tan(h/2+this.s45),this.alfa)/t)-this.s45),i=-c*this.alfa,n=Math.asin(Math.cos(this.ad)*Math.sin(e)+Math.sin(this.ad)*Math.cos(e)*Math.cos(i)),r=Math.asin(Math.cos(e)*Math.sin(i)/Math.cos(n)),o=this.n*r,a=this.ro0*Math.pow(Math.tan(this.s0/2+this.s45),this.n)/Math.pow(Math.tan(n/2+this.s45),this.n),s.y=a*Math.cos(o)/1,s.x=a*Math.sin(o)/1,this.czech||(s.y*=-1,s.x*=-1),s}function Jit(s){var t,e,i,n,r,o,a,l,h=s.x;s.x=s.y,s.y=h,this.czech||(s.y*=-1,s.x*=-1),o=Math.sqrt(s.x*s.x+s.y*s.y),r=Math.atan2(s.y,s.x),n=r/Math.sin(this.s0),i=2*(Math.atan(Math.pow(this.ro0/o,1/this.n)*Math.tan(this.s0/2+this.s45))-this.s45),t=Math.asin(Math.cos(this.ad)*Math.sin(i)-Math.sin(this.ad)*Math.cos(i)*Math.cos(n)),e=Math.asin(Math.cos(i)*Math.sin(n)/Math.cos(t)),s.x=this.long0-e/this.alfa,a=t,l=0;var c=0;do s.y=2*(Math.atan(Math.pow(this.k,-1/this.alfa)*Math.pow(Math.tan(t/2+this.s45),1/this.alfa)*Math.pow((1+this.e*Math.sin(a))/(1-this.e*Math.sin(a)),this.e/2))-this.s45),Math.abs(a-s.y)<1e-10&&(l=1),a=s.y,c+=1;while(l===0&&c<15);return c>=15?null:s}var Qit=["Krovak","krovak"];const tnt={init:Hit,forward:Kit,inverse:Jit,names:Qit};function li(s,t,e,i,n){return s*n-t*Math.sin(2*n)+e*Math.sin(4*n)-i*Math.sin(6*n)}function $g(s){return 1-.25*s*(1+s/16*(3+1.25*s))}function Gg(s){return .375*s*(1+.25*s*(1+.46875*s))}function jg(s){return .05859375*s*s*(1+.75*s)}function zg(s){return s*s*s*(35/3072)}function mc(s,t,e){var i=t*e;return s/Math.sqrt(1-i*i)}function kc(s){return Math.abs(s)1e-7?(e=s*t,(1-s*s)*(t/(1-e*e)-.5/s*Math.log((1-e)/(1+e)))):2*t}var ont=1,ant=2,lnt=3,hnt=4;function cnt(){var s=Math.abs(this.lat0);if(Math.abs(s-K)0){var t;switch(this.qp=ta(this.e,1),this.mmf=.5/(1-this.es),this.apa=xnt(this.es),this.mode){case this.N_POLE:this.dd=1;break;case this.S_POLE:this.dd=1;break;case this.EQUIT:this.rq=Math.sqrt(.5*this.qp),this.dd=1/this.rq,this.xmf=1,this.ymf=.5*this.qp;break;case this.OBLIQ:this.rq=Math.sqrt(.5*this.qp),t=Math.sin(this.lat0),this.sinb1=ta(this.e,t)/this.qp,this.cosb1=Math.sqrt(1-this.sinb1*this.sinb1),this.dd=Math.cos(this.lat0)/(Math.sqrt(1-this.es*t*t)*this.rq*this.cosb1),this.ymf=(this.xmf=this.rq)/this.dd,this.xmf*=this.dd;break}}else this.mode===this.OBLIQ&&(this.sinph0=Math.sin(this.lat0),this.cosph0=Math.cos(this.lat0))}function unt(s){var t,e,i,n,r,o,a,l,h,c,u=s.x,d=s.y;if(u=rt(u-this.long0),this.sphere){if(r=Math.sin(d),c=Math.cos(d),i=Math.cos(u),this.mode===this.OBLIQ||this.mode===this.EQUIT){if(e=this.mode===this.EQUIT?1+c*i:1+this.sinph0*r+this.cosph0*c*i,e<=tt)return null;e=Math.sqrt(2/e),t=e*c*Math.sin(u),e*=this.mode===this.EQUIT?r:this.cosph0*r-this.sinph0*c*i}else if(this.mode===this.N_POLE||this.mode===this.S_POLE){if(this.mode===this.N_POLE&&(i=-i),Math.abs(d+this.lat0)=0?(t=(h=Math.sqrt(o))*n,e=i*(this.mode===this.S_POLE?h:-h)):t=e=0;break}}return s.x=this.a*t+this.x0,s.y=this.a*e+this.y0,s}function dnt(s){s.x-=this.x0,s.y-=this.y0;var t=s.x/this.a,e=s.y/this.a,i,n,r,o,a,l,h;if(this.sphere){var c=0,u,d=0;if(u=Math.sqrt(t*t+e*e),n=u*.5,n>1)return null;switch(n=2*Math.asin(n),(this.mode===this.OBLIQ||this.mode===this.EQUIT)&&(d=Math.sin(n),c=Math.cos(n)),this.mode){case this.EQUIT:n=Math.abs(u)<=tt?0:Math.asin(e*d/u),t*=d,e=c*u;break;case this.OBLIQ:n=Math.abs(u)<=tt?this.lat0:Math.asin(c*this.sinph0+e*d*this.cosph0/u),t*=d*this.cosph0,e=(c-Math.sin(n)*this.sinph0)*u;break;case this.N_POLE:e=-e,n=K-n;break;case this.S_POLE:n-=K;break}i=e===0&&(this.mode===this.EQUIT||this.mode===this.OBLIQ)?0:Math.atan2(t,e)}else{if(h=0,this.mode===this.OBLIQ||this.mode===this.EQUIT){if(t/=this.dd,e*=this.dd,l=Math.sqrt(t*t+e*e),l1&&(s=s>1?1:-1),Math.asin(s)}function Snt(){Math.abs(this.lat1+this.lat2)tt?this.ns0=(this.ms1*this.ms1-this.ms2*this.ms2)/(this.qs2-this.qs1):this.ns0=this.con,this.c=this.ms1*this.ms1+this.ns0*this.qs1,this.rh=this.a*Math.sqrt(this.c-this.ns0*this.qs0)/this.ns0)}function Mnt(s){var t=s.x,e=s.y;this.sin_phi=Math.sin(e),this.cos_phi=Math.cos(e);var i=ta(this.e3,this.sin_phi),n=this.a*Math.sqrt(this.c-this.ns0*i)/this.ns0,r=this.ns0*rt(t-this.long0),o=n*Math.sin(r)+this.x0,a=this.rh-n*Math.cos(r)+this.y0;return s.x=o,s.y=a,s}function bnt(s){var t,e,i,n,r,o;return s.x-=this.x0,s.y=this.rh-s.y+this.y0,this.ns0>=0?(t=Math.sqrt(s.x*s.x+s.y*s.y),i=1):(t=-Math.sqrt(s.x*s.x+s.y*s.y),i=-1),n=0,t!==0&&(n=Math.atan2(i*s.x,i*s.y)),i=t*this.ns0/this.a,this.sphere?o=Math.asin((this.c-i*i)/(2*this.ns0)):(e=(this.c-i*i)/this.ns0,o=this.phi1z(this.e3,e)),r=rt(n/this.ns0+this.long0),s.x=r,s.y=o,s}function Tnt(s,t){var e,i,n,r,o,a=ua(.5*t);if(s0||Math.abs(o)<=tt?(a=this.x0+this.a*r*e*Math.sin(i)/o,l=this.y0+this.a*r*(this.cos_p14*t-this.sin_p14*e*n)/o):(a=this.x0+this.infinity_dist*e*Math.sin(i),l=this.y0+this.infinity_dist*(this.cos_p14*t-this.sin_p14*e*n)),s.x=a,s.y=l,s}function Ant(s){var t,e,i,n,r,o;return s.x=(s.x-this.x0)/this.a,s.y=(s.y-this.y0)/this.a,s.x/=this.k0,s.y/=this.k0,(t=Math.sqrt(s.x*s.x+s.y*s.y))?(n=Math.atan2(t,this.rc),e=Math.sin(n),i=Math.cos(n),o=ua(i*this.sin_p14+s.y*e*this.cos_p14/t),r=Math.atan2(s.x*e,t*this.cos_p14*i-s.y*this.sin_p14*e),r=rt(this.long0+r)):(o=this.phic0,r=0),s.x=r,s.y=o,s}var Lnt=["gnom"];const Ont={init:Int,forward:Pnt,inverse:Ant,names:Lnt};function Fnt(s,t){var e=1-(1-s*s)/(2*s)*Math.log((1-s)/(1+s));if(Math.abs(Math.abs(t)-e)<1e-6)return t<0?-1*K:K;for(var i=Math.asin(.5*t),n,r,o,a,l=0;l<30;l++)if(r=Math.sin(i),o=Math.cos(i),a=s*r,n=Math.pow(1-a*a,2)/(2*o)*(t/(1-s*s)-r/(1-a*a)+.5/s*Math.log((1-a)/(1+a))),i+=n,Math.abs(n)<=1e-10)return i;return NaN}function Nnt(){this.sphere||(this.k0=wr(this.e,Math.sin(this.lat_ts),Math.cos(this.lat_ts)))}function Dnt(s){var t=s.x,e=s.y,i,n,r=rt(t-this.long0);if(this.sphere)i=this.x0+this.a*r*Math.cos(this.lat_ts),n=this.y0+this.a*Math.sin(e)/Math.cos(this.lat_ts);else{var o=ta(this.e,Math.sin(e));i=this.x0+this.a*this.k0*r,n=this.y0+this.a*o*.5/this.k0}return s.x=i,s.y=n,s}function knt(s){s.x-=this.x0,s.y-=this.y0;var t,e;return this.sphere?(t=rt(this.long0+s.x/this.a/Math.cos(this.lat_ts)),e=Math.asin(s.y/this.a*Math.cos(this.lat_ts))):(e=Fnt(this.e,2*s.y*this.k0/this.a),t=rt(this.long0+s.x/(this.a*this.k0))),s.x=t,s.y=e,s}var $nt=["cea"];const Gnt={init:Nnt,forward:Dnt,inverse:knt,names:$nt};function jnt(){this.x0=this.x0||0,this.y0=this.y0||0,this.lat0=this.lat0||0,this.long0=this.long0||0,this.lat_ts=this.lat_ts||0,this.title=this.title||"Equidistant Cylindrical (Plate Carre)",this.rc=Math.cos(this.lat_ts)}function znt(s){var t=s.x,e=s.y,i=rt(t-this.long0),n=kc(e-this.lat0);return s.x=this.x0+this.a*i*this.rc,s.y=this.y0+this.a*n,s}function Unt(s){var t=s.x,e=s.y;return s.x=rt(this.long0+(t-this.x0)/(this.a*this.rc)),s.y=kc(this.lat0+(e-this.y0)/this.a),s}var Bnt=["Equirectangular","Equidistant_Cylindrical","eqc"];const Wnt={init:jnt,forward:znt,inverse:Unt,names:Bnt};var Mb=20;function Xnt(){this.temp=this.b/this.a,this.es=1-Math.pow(this.temp,2),this.e=Math.sqrt(this.es),this.e0=$g(this.es),this.e1=Gg(this.es),this.e2=jg(this.es),this.e3=zg(this.es),this.ml0=this.a*li(this.e0,this.e1,this.e2,this.e3,this.lat0)}function Vnt(s){var t=s.x,e=s.y,i,n,r,o=rt(t-this.long0);if(r=o*Math.sin(e),this.sphere)Math.abs(e)<=tt?(i=this.a*o,n=-1*this.a*this.lat0):(i=this.a*Math.sin(r)/Math.tan(e),n=this.a*(kc(e-this.lat0)+(1-Math.cos(r))/Math.tan(e)));else if(Math.abs(e)<=tt)i=this.a*o,n=-1*this.ml0;else{var a=mc(this.a,this.e,Math.sin(e))/Math.tan(e);i=a*Math.sin(r),n=this.a*li(this.e0,this.e1,this.e2,this.e3,e)-this.ml0+a*(1-Math.cos(r))}return s.x=i+this.x0,s.y=n+this.y0,s}function Ynt(s){var t,e,i,n,r,o,a,l,h;if(i=s.x-this.x0,n=s.y-this.y0,this.sphere)if(Math.abs(n+this.a*this.lat0)<=tt)t=rt(i/this.a+this.long0),e=0;else{o=this.lat0+n/this.a,a=i*i/this.a/this.a+o*o,l=o;var c;for(r=Mb;r;--r)if(c=Math.tan(l),h=-1*(o*(l*c+1)-l-.5*(l*l+a)*c)/((l-o)/c-1),l+=h,Math.abs(h)<=tt){e=l;break}t=rt(this.long0+Math.asin(i*Math.tan(l)/this.a)/Math.sin(e))}else if(Math.abs(n+this.ml0)<=tt)e=0,t=rt(this.long0+i/this.a);else{o=(this.ml0+n)/this.a,a=i*i/this.a/this.a+o*o,l=o;var u,d,g,f,p;for(r=Mb;r;--r)if(p=this.e*Math.sin(l),u=Math.sqrt(1-p*p)*Math.tan(l),d=this.a*li(this.e0,this.e1,this.e2,this.e3,l),g=this.e0-2*this.e1*Math.cos(2*l)+4*this.e2*Math.cos(4*l)-6*this.e3*Math.cos(6*l),f=d/this.a,h=(o*(u*f+1)-f-.5*u*(f*f+a))/(this.es*Math.sin(2*l)*(f*f+a-2*o*f)/(4*u)+(o-f)*(u*g-2/Math.sin(2*l))-g),l-=h,Math.abs(h)<=tt){e=l;break}u=Math.sqrt(1-this.es*Math.pow(Math.sin(e),2))*Math.tan(e),t=rt(this.long0+Math.asin(i*u/this.a)/Math.sin(e))}return s.x=t,s.y=e,s}var qnt=["Polyconic","poly"];const Znt={init:Xnt,forward:Vnt,inverse:Ynt,names:qnt};function Hnt(){this.A=[],this.A[1]=.6399175073,this.A[2]=-.1358797613,this.A[3]=.063294409,this.A[4]=-.02526853,this.A[5]=.0117879,this.A[6]=-.0055161,this.A[7]=.0026906,this.A[8]=-.001333,this.A[9]=67e-5,this.A[10]=-34e-5,this.B_re=[],this.B_im=[],this.B_re[1]=.7557853228,this.B_im[1]=0,this.B_re[2]=.249204646,this.B_im[2]=.003371507,this.B_re[3]=-.001541739,this.B_im[3]=.04105856,this.B_re[4]=-.10162907,this.B_im[4]=.01727609,this.B_re[5]=-.26623489,this.B_im[5]=-.36249218,this.B_re[6]=-.6870983,this.B_im[6]=-1.1651967,this.C_re=[],this.C_im=[],this.C_re[1]=1.3231270439,this.C_im[1]=0,this.C_re[2]=-.577245789,this.C_im[2]=-.007809598,this.C_re[3]=.508307513,this.C_im[3]=-.112208952,this.C_re[4]=-.15094762,this.C_im[4]=.18200602,this.C_re[5]=1.01418179,this.C_im[5]=1.64497696,this.C_re[6]=1.9660549,this.C_im[6]=2.5127645,this.D=[],this.D[1]=1.5627014243,this.D[2]=.5185406398,this.D[3]=-.03333098,this.D[4]=-.1052906,this.D[5]=-.0368594,this.D[6]=.007317,this.D[7]=.0122,this.D[8]=.00394,this.D[9]=-.0013}function Knt(s){var t,e=s.x,i=s.y,n=i-this.lat0,r=e-this.long0,o=n/Ju*1e-5,a=r,l=1,h=0;for(t=1;t<=10;t++)l=l*o,h=h+this.A[t]*l;var c=h,u=a,d=1,g=0,f,p,m=0,_=0;for(t=1;t<=6;t++)f=d*c-g*u,p=g*c+d*u,d=f,g=p,m=m+this.B_re[t]*d-this.B_im[t]*g,_=_+this.B_im[t]*d+this.B_re[t]*g;return s.x=_*this.a+this.x0,s.y=m*this.a+this.y0,s}function Jnt(s){var t,e=s.x,i=s.y,n=e-this.x0,r=i-this.y0,o=r/this.a,a=n/this.a,l=1,h=0,c,u,d=0,g=0;for(t=1;t<=6;t++)c=l*o-h*a,u=h*o+l*a,l=c,h=u,d=d+this.C_re[t]*l-this.C_im[t]*h,g=g+this.C_im[t]*l+this.C_re[t]*h;for(var f=0;f.999999999999&&(e=.999999999999),t=Math.asin(e);var i=rt(this.long0+s.x/(.900316316158*this.a*Math.cos(t)));i<-Math.PI&&(i=-Math.PI),i>Math.PI&&(i=Math.PI),e=(2*t+Math.sin(2*t))/Math.PI,Math.abs(e)>1&&(e=1);var n=Math.asin(e);return s.x=i,s.y=n,s}var prt=["Mollweide","moll"];const mrt={init:drt,forward:grt,inverse:frt,names:prt};function _rt(){Math.abs(this.lat1+this.lat2)=0?(e=Math.sqrt(s.x*s.x+s.y*s.y),t=1):(e=-Math.sqrt(s.x*s.x+s.y*s.y),t=-1);var r=0;if(e!==0&&(r=Math.atan2(t*s.x,t*s.y)),this.sphere)return n=rt(this.long0+r/this.ns),i=kc(this.g-e/this.a),s.x=n,s.y=i,s;var o=this.g-e/this.a;return i=im(o,this.e0,this.e1,this.e2,this.e3),n=rt(this.long0+r/this.ns),s.x=n,s.y=i,s}var vrt=["Equidistant_Conic","eqdc"];const wrt={init:_rt,forward:yrt,inverse:xrt,names:vrt};function Ert(){this.R=this.a}function Srt(s){var t=s.x,e=s.y,i=rt(t-this.long0),n,r;Math.abs(e)<=tt&&(n=this.x0+this.R*i,r=this.y0);var o=ua(2*Math.abs(e/Math.PI));(Math.abs(i)<=tt||Math.abs(Math.abs(e)-K)<=tt)&&(n=this.x0,e>=0?r=this.y0+Math.PI*this.R*Math.tan(.5*o):r=this.y0+Math.PI*this.R*-Math.tan(.5*o));var a=.5*Math.abs(Math.PI/i-i/Math.PI),l=a*a,h=Math.sin(o),c=Math.cos(o),u=c/(h+c-1),d=u*u,g=u*(2/h-1),f=g*g,p=Math.PI*this.R*(a*(u-f)+Math.sqrt(l*(u-f)*(u-f)-(f+l)*(d-f)))/(f+l);i<0&&(p=-p),n=this.x0+p;var m=l+u;return p=Math.PI*this.R*(g*m-a*Math.sqrt((f+l)*(l+1)-m*m))/(f+l),e>=0?r=this.y0+p:r=this.y0-p,s.x=n,s.y=r,s}function Mrt(s){var t,e,i,n,r,o,a,l,h,c,u,d,g;return s.x-=this.x0,s.y-=this.y0,u=Math.PI*this.R,i=s.x/u,n=s.y/u,r=i*i+n*n,o=-Math.abs(n)*(1+r),a=o-2*n*n+i*i,l=-2*o+1+2*n*n+r*r,g=n*n/l+(2*a*a*a/l/l/l-9*o*a/l/l)/27,h=(o-a*a/3/l)/l,c=2*Math.sqrt(-h/3),u=3*g/h/c,Math.abs(u)>1&&(u>=0?u=1:u=-1),d=Math.acos(u)/3,s.y>=0?e=(-c*Math.cos(d+Math.PI/3)-a/3/l)*Math.PI:e=-(-c*Math.cos(d+Math.PI/3)-a/3/l)*Math.PI,Math.abs(i)2*K*this.a?void 0:(e=t/this.a,i=Math.sin(e),n=Math.cos(e),r=this.long0,Math.abs(t)<=tt?o=this.lat0:(o=ua(n*this.sin_p12+s.y*i*this.cos_p12/t),a=Math.abs(this.lat0)-K,Math.abs(a)<=tt?this.lat0>=0?r=rt(this.long0+Math.atan2(s.x,-s.y)):r=rt(this.long0-Math.atan2(-s.x,s.y)):r=rt(this.long0+Math.atan2(s.x*i,t*this.cos_p12*n-s.y*this.sin_p12*i))),s.x=r,s.y=o,s)):(l=$g(this.es),h=Gg(this.es),c=jg(this.es),u=zg(this.es),Math.abs(this.sin_p12-1)<=tt?(d=this.a*li(l,h,c,u,K),t=Math.sqrt(s.x*s.x+s.y*s.y),g=d-t,o=im(g/this.a,l,h,c,u),r=rt(this.long0+Math.atan2(s.x,-1*s.y)),s.x=r,s.y=o,s):Math.abs(this.sin_p12+1)<=tt?(d=this.a*li(l,h,c,u,K),t=Math.sqrt(s.x*s.x+s.y*s.y),g=t-d,o=im(g/this.a,l,h,c,u),r=rt(this.long0+Math.atan2(s.x,s.y)),s.x=r,s.y=o,s):(t=Math.sqrt(s.x*s.x+s.y*s.y),m=Math.atan2(s.x,s.y),f=mc(this.a,this.e,this.sin_p12),_=Math.cos(m),y=this.e*this.cos_p12*_,v=-y*y/(1-this.es),S=3*this.es*(1-v)*this.sin_p12*this.cos_p12*_/(1-this.es),w=t/f,T=w-v*(1+v)*Math.pow(w,3)/6-S*(1+3*v)*Math.pow(w,4)/24,M=1-v*T*T/2-w*T*T*T/6,p=Math.asin(this.sin_p12*Math.cos(T)+this.cos_p12*Math.sin(T)*_),r=rt(this.long0+Math.asin(Math.sin(m)*Math.sin(T)/Math.cos(p))),C=Math.sin(p),o=Math.atan2((C-this.es*M*this.sin_p12)*Math.tan(p),C*(1-this.es)),s.x=r,s.y=o,s))}var Prt=["Azimuthal_Equidistant","aeqd"];const Art={init:Crt,forward:Rrt,inverse:Irt,names:Prt};function Lrt(){this.sin_p14=Math.sin(this.lat0),this.cos_p14=Math.cos(this.lat0)}function Ort(s){var t,e,i,n,r,o,a,l,h=s.x,c=s.y;return i=rt(h-this.long0),t=Math.sin(c),e=Math.cos(c),n=Math.cos(i),o=this.sin_p14*t+this.cos_p14*e*n,r=1,(o>0||Math.abs(o)<=tt)&&(a=this.a*r*e*Math.sin(i),l=this.y0+this.a*r*(this.cos_p14*t-this.sin_p14*e*n)),s.x=a,s.y=l,s}function Frt(s){var t,e,i,n,r,o,a;return s.x-=this.x0,s.y-=this.y0,t=Math.sqrt(s.x*s.x+s.y*s.y),e=ua(t/this.a),i=Math.sin(e),n=Math.cos(e),o=this.long0,Math.abs(t)<=tt?(a=this.lat0,s.x=o,s.y=a,s):(a=ua(n*this.sin_p14+s.y*i*this.cos_p14/t),r=Math.abs(this.lat0)-K,Math.abs(r)<=tt?(this.lat0>=0?o=rt(this.long0+Math.atan2(s.x,-s.y)):o=rt(this.long0-Math.atan2(-s.x,s.y)),s.x=o,s.y=a,s):(o=rt(this.long0+Math.atan2(s.x*i,t*this.cos_p14*n-s.y*this.sin_p14*i)),s.x=o,s.y=a,s))}var Nrt=["ortho"];const Drt={init:Lrt,forward:Ort,inverse:Frt,names:Nrt};var Ue={FRONT:1,RIGHT:2,BACK:3,LEFT:4,TOP:5,BOTTOM:6},xe={AREA_0:1,AREA_1:2,AREA_2:3,AREA_3:4};function krt(){this.x0=this.x0||0,this.y0=this.y0||0,this.lat0=this.lat0||0,this.long0=this.long0||0,this.lat_ts=this.lat_ts||0,this.title=this.title||"Quadrilateralized Spherical Cube",this.lat0>=K-ye/2?this.face=Ue.TOP:this.lat0<=-(K-ye/2)?this.face=Ue.BOTTOM:Math.abs(this.long0)<=ye?this.face=Ue.FRONT:Math.abs(this.long0)<=K+ye?this.face=this.long0>0?Ue.RIGHT:Ue.LEFT:this.face=Ue.BACK,this.es!==0&&(this.one_minus_f=1-(this.a-this.b)/this.a,this.one_minus_f_squared=this.one_minus_f*this.one_minus_f)}function $rt(s){var t={x:0,y:0},e,i,n,r,o,a,l={value:0};if(s.x-=this.long0,this.es!==0?e=Math.atan(this.one_minus_f_squared*Math.tan(s.y)):e=s.y,i=s.x,this.face===Ue.TOP)r=K-e,i>=ye&&i<=K+ye?(l.value=xe.AREA_0,n=i-K):i>K+ye||i<=-(K+ye)?(l.value=xe.AREA_1,n=i>0?i-es:i+es):i>-(K+ye)&&i<=-ye?(l.value=xe.AREA_2,n=i+K):(l.value=xe.AREA_3,n=i);else if(this.face===Ue.BOTTOM)r=K+e,i>=ye&&i<=K+ye?(l.value=xe.AREA_0,n=-i+K):i=-ye?(l.value=xe.AREA_1,n=-i):i<-ye&&i>=-(K+ye)?(l.value=xe.AREA_2,n=-i-K):(l.value=xe.AREA_3,n=i>0?-i+es:-i-es);else{var h,c,u,d,g,f,p;this.face===Ue.RIGHT?i=kh(i,+K):this.face===Ue.BACK?i=kh(i,+es):this.face===Ue.LEFT&&(i=kh(i,-K)),d=Math.sin(e),g=Math.cos(e),f=Math.sin(i),p=Math.cos(i),h=g*p,c=g*f,u=d,this.face===Ue.FRONT?(r=Math.acos(h),n=If(r,u,c,l)):this.face===Ue.RIGHT?(r=Math.acos(c),n=If(r,u,-h,l)):this.face===Ue.BACK?(r=Math.acos(-h),n=If(r,u,-c,l)):this.face===Ue.LEFT?(r=Math.acos(-c),n=If(r,u,h,l)):(r=n=0,l.value=xe.AREA_0)}return a=Math.atan(12/es*(n+Math.acos(Math.sin(n)*Math.cos(ye))-K)),o=Math.sqrt((1-Math.cos(r))/(Math.cos(a)*Math.cos(a))/(1-Math.cos(Math.atan(1/Math.cos(n))))),l.value===xe.AREA_1?a+=K:l.value===xe.AREA_2?a+=es:l.value===xe.AREA_3&&(a+=1.5*es),t.x=o*Math.cos(a),t.y=o*Math.sin(a),t.x=t.x*this.a+this.x0,t.y=t.y*this.a+this.y0,s.x=t.x,s.y=t.y,s}function Grt(s){var t={lam:0,phi:0},e,i,n,r,o,a,l,h,c,u={value:0};if(s.x=(s.x-this.x0)/this.a,s.y=(s.y-this.y0)/this.a,i=Math.atan(Math.sqrt(s.x*s.x+s.y*s.y)),e=Math.atan2(s.y,s.x),s.x>=0&&s.x>=Math.abs(s.y)?u.value=xe.AREA_0:s.y>=0&&s.y>=Math.abs(s.x)?(u.value=xe.AREA_1,e-=K):s.x<0&&-s.x>=Math.abs(s.y)?(u.value=xe.AREA_2,e=e<0?e+es:e-es):(u.value=xe.AREA_3,e+=K),c=es/12*Math.tan(e),o=Math.sin(c)/(Math.cos(c)-1/Math.sqrt(2)),a=Math.atan(o),n=Math.cos(e),r=Math.tan(i),l=1-n*n*r*r*(1-Math.cos(Math.atan(1/Math.cos(a)))),l<-1?l=-1:l>1&&(l=1),this.face===Ue.TOP)h=Math.acos(l),t.phi=K-h,u.value===xe.AREA_0?t.lam=a+K:u.value===xe.AREA_1?t.lam=a<0?a+es:a-es:u.value===xe.AREA_2?t.lam=a-K:t.lam=a;else if(this.face===Ue.BOTTOM)h=Math.acos(l),t.phi=h-K,u.value===xe.AREA_0?t.lam=-a+K:u.value===xe.AREA_1?t.lam=-a:u.value===xe.AREA_2?t.lam=-a-K:t.lam=a<0?-a-es:-a+es;else{var d,g,f;d=l,c=d*d,c>=1?f=0:f=Math.sqrt(1-c)*Math.sin(a),c+=f*f,c>=1?g=0:g=Math.sqrt(1-c),u.value===xe.AREA_1?(c=g,g=-f,f=c):u.value===xe.AREA_2?(g=-g,f=-f):u.value===xe.AREA_3&&(c=g,g=f,f=-c),this.face===Ue.RIGHT?(c=d,d=-g,g=c):this.face===Ue.BACK?(d=-d,g=-g):this.face===Ue.LEFT&&(c=d,d=g,g=-c),t.phi=Math.acos(-f)-K,t.lam=Math.atan2(g,d),this.face===Ue.RIGHT?t.lam=kh(t.lam,-K):this.face===Ue.BACK?t.lam=kh(t.lam,-es):this.face===Ue.LEFT&&(t.lam=kh(t.lam,+K))}if(this.es!==0){var p,m,_;p=t.phi<0?1:0,m=Math.tan(t.phi),_=this.b/Math.sqrt(m*m+this.one_minus_f_squared),t.phi=Math.atan(Math.sqrt(this.a*this.a-_*_)/(this.one_minus_f*_)),p&&(t.phi=-t.phi)}return t.lam+=this.long0,s.x=t.lam,s.y=t.phi,s}function If(s,t,e,i){var n;return sye&&n<=K+ye?(i.value=xe.AREA_1,n-=K):n>K+ye||n<=-(K+ye)?(i.value=xe.AREA_2,n=n>=0?n-es:n+es):(i.value=xe.AREA_3,n+=K)),n}function kh(s,t){var e=s+t;return e<-es?e+=zd:e>+es&&(e-=zd),e}var jrt=["Quadrilateralized Spherical Cube","Quadrilateralized_Spherical_Cube","qsc"];const zrt={init:krt,forward:$rt,inverse:Grt,names:jrt};var Ey=[[1,22199e-21,-715515e-10,31103e-10],[.9986,-482243e-9,-24897e-9,-13309e-10],[.9954,-83103e-8,-448605e-10,-986701e-12],[.99,-.00135364,-59661e-9,36777e-10],[.9822,-.00167442,-449547e-11,-572411e-11],[.973,-.00214868,-903571e-10,18736e-12],[.96,-.00305085,-900761e-10,164917e-11],[.9427,-.00382792,-653386e-10,-26154e-10],[.9216,-.00467746,-10457e-8,481243e-11],[.8962,-.00536223,-323831e-10,-543432e-11],[.8679,-.00609363,-113898e-9,332484e-11],[.835,-.00698325,-640253e-10,934959e-12],[.7986,-.00755338,-500009e-10,935324e-12],[.7597,-.00798324,-35971e-9,-227626e-11],[.7186,-.00851367,-701149e-10,-86303e-10],[.6732,-.00986209,-199569e-9,191974e-10],[.6213,-.010418,883923e-10,624051e-11],[.5722,-.00906601,182e-6,624051e-11],[.5322,-.00677797,275608e-9,624051e-11]],Iu=[[-520417e-23,.0124,121431e-23,-845284e-16],[.062,.0124,-126793e-14,422642e-15],[.124,.0124,507171e-14,-160604e-14],[.186,.0123999,-190189e-13,600152e-14],[.248,.0124002,710039e-13,-224e-10],[.31,.0123992,-264997e-12,835986e-13],[.372,.0124029,988983e-12,-311994e-12],[.434,.0123893,-369093e-11,-435621e-12],[.4958,.0123198,-102252e-10,-345523e-12],[.5571,.0121916,-154081e-10,-582288e-12],[.6176,.0119938,-241424e-10,-525327e-12],[.6769,.011713,-320223e-10,-516405e-12],[.7346,.0113541,-397684e-10,-609052e-12],[.7903,.0109107,-489042e-10,-104739e-11],[.8435,.0103431,-64615e-9,-140374e-14],[.8936,.00969686,-64636e-9,-8547e-9],[.9394,.00840947,-192841e-9,-42106e-10],[.9761,.00616527,-256e-6,-42106e-10],[1,.00328947,-319159e-9,-42106e-10]],nO=.8487,rO=1.3523,oO=ur/5,Urt=1/oO,wh=18,nm=function(s,t){return s[0]+t*(s[1]+t*(s[2]+t*s[3]))},Brt=function(s,t){return s[1]+t*(2*s[2]+t*3*s[3])};function Wrt(s,t,e,i){for(var n=t;i;--i){var r=s(n);if(n-=r,Math.abs(r)=wh&&(i=wh-1),e=ur*(e-Urt*i);var n={x:nm(Ey[i],e)*t,y:nm(Iu[i],e)};return s.y<0&&(n.y=-n.y),n.x=n.x*this.a*nO+this.x0,n.y=n.y*this.a*rO+this.y0,n}function Yrt(s){var t={x:(s.x-this.x0)/(this.a*nO),y:Math.abs(s.y-this.y0)/(this.a*rO)};if(t.y>=1)t.x/=Ey[wh][0],t.y=s.y<0?-K:K;else{var e=Math.floor(t.y*wh);for(e<0?e=0:e>=wh&&(e=wh-1);;)if(Iu[e][0]>t.y)--e;else if(Iu[e+1][0]<=t.y)++e;else break;var i=Iu[e],n=5*(t.y-i[0])/(Iu[e+1][0]-i[0]);n=Wrt(function(r){return(nm(i,r)-t.y)/Brt(i,r)},n,tt,100),t.x/=nm(Ey[e],n),t.y=(5*e+n)*Ls,s.y<0&&(t.y=-t.y)}return t.x=rt(t.x+this.long0),t}var qrt=["Robinson","robin"];const Zrt={init:Xrt,forward:Vrt,inverse:Yrt,names:qrt};function Hrt(){this.name="geocent"}function Krt(s){var t=XL(s,this.es,this.a);return t}function Jrt(s){var t=VL(s,this.es,this.a,this.b);return t}var Qrt=["Geocentric","geocentric","geocent","Geocent"];const tot={init:Hrt,forward:Krt,inverse:Jrt,names:Qrt};var Bs={N_POLE:0,S_POLE:1,EQUIT:2,OBLIQ:3},lu={h:{def:1e5,num:!0},azi:{def:0,num:!0,degrees:!0},tilt:{def:0,num:!0,degrees:!0},long0:{def:0,num:!0},lat0:{def:0,num:!0}};function eot(){if(Object.keys(lu).forEach(function(e){if(typeof this[e]>"u")this[e]=lu[e].def;else{if(lu[e].num&&isNaN(this[e]))throw new Error("Invalid parameter value, must be numeric "+e+" = "+this[e]);lu[e].num&&(this[e]=parseFloat(this[e]))}lu[e].degrees&&(this[e]=this[e]*Ls)}.bind(this)),Math.abs(Math.abs(this.lat0)-K)1e10)throw new Error("Invalid height");this.p=1+this.pn1,this.rp=1/this.p,this.h1=1/this.pn1,this.pfact=(this.p+1)*this.h1,this.es=0;var s=this.tilt,t=this.azi;this.cg=Math.cos(t),this.sg=Math.sin(t),this.cw=Math.cos(s),this.sw=Math.sin(s)}function sot(s){s.x-=this.long0;var t=Math.sin(s.y),e=Math.cos(s.y),i=Math.cos(s.x),n,r;switch(this.mode){case Bs.OBLIQ:r=this.sinph0*t+this.cosph0*e*i;break;case Bs.EQUIT:r=e*i;break;case Bs.S_POLE:r=-t;break;case Bs.N_POLE:r=t;break}switch(r=this.pn1/(this.p-r),n=r*e*Math.sin(s.x),this.mode){case Bs.OBLIQ:r*=this.cosph0*t-this.sinph0*e*i;break;case Bs.EQUIT:r*=t;break;case Bs.N_POLE:r*=-(e*i);break;case Bs.S_POLE:r*=e*i;break}var o,a;return o=r*this.cg+n*this.sg,a=1/(o*this.sw*this.h1+this.cw),n=(n*this.cg-r*this.sg)*this.cw*a,r=o*a,s.x=n*this.a,s.y=r*this.a,s}function iot(s){s.x/=this.a,s.y/=this.a;var t={x:s.x,y:s.y},e,i,n;n=1/(this.pn1-s.y*this.sw),e=this.pn1*s.x*n,i=this.pn1*s.y*this.cw*n,s.x=e*this.cg+i*this.sg,s.y=i*this.cg-e*this.sg;var r=on(s.x,s.y);if(Math.abs(r)1e10)throw new Error;if(this.radius_g=1+this.radius_g_1,this.C=this.radius_g*this.radius_g-1,this.es!==0){var s=1-this.es,t=1/s;this.radius_p=Math.sqrt(s),this.radius_p2=s,this.radius_p_inv2=t,this.shape="ellipse"}else this.radius_p=1,this.radius_p2=1,this.radius_p_inv2=1,this.shape="sphere";this.title||(this.title="Geostationary Satellite View")}function aot(s){var t=s.x,e=s.y,i,n,r,o;if(t=t-this.long0,this.shape==="ellipse"){e=Math.atan(this.radius_p2*Math.tan(e));var a=this.radius_p/on(this.radius_p*Math.cos(e),Math.sin(e));if(n=a*Math.cos(t)*Math.cos(e),r=a*Math.sin(t)*Math.cos(e),o=a*Math.sin(e),(this.radius_g-n)*n-r*r-o*o*this.radius_p_inv2<0)return s.x=Number.NaN,s.y=Number.NaN,s;i=this.radius_g-n,this.flip_axis?(s.x=this.radius_g_1*Math.atan(r/on(o,i)),s.y=this.radius_g_1*Math.atan(o/i)):(s.x=this.radius_g_1*Math.atan(r/i),s.y=this.radius_g_1*Math.atan(o/on(r,i)))}else this.shape==="sphere"&&(i=Math.cos(e),n=Math.cos(t)*i,r=Math.sin(t)*i,o=Math.sin(e),i=this.radius_g-n,this.flip_axis?(s.x=this.radius_g_1*Math.atan(r/on(o,i)),s.y=this.radius_g_1*Math.atan(o/i)):(s.x=this.radius_g_1*Math.atan(r/i),s.y=this.radius_g_1*Math.atan(o/on(r,i))));return s.x=s.x*this.a,s.y=s.y*this.a,s}function lot(s){var t=-1,e=0,i=0,n,r,o,a;if(s.x=s.x/this.a,s.y=s.y/this.a,this.shape==="ellipse"){this.flip_axis?(i=Math.tan(s.y/this.radius_g_1),e=Math.tan(s.x/this.radius_g_1)*on(1,i)):(e=Math.tan(s.x/this.radius_g_1),i=Math.tan(s.y/this.radius_g_1)*on(1,e));var l=i/this.radius_p;if(n=e*e+l*l+t*t,r=2*this.radius_g*t,o=r*r-4*n*this.C,o<0)return s.x=Number.NaN,s.y=Number.NaN,s;a=(-r-Math.sqrt(o))/(2*n),t=this.radius_g+a*t,e*=a,i*=a,s.x=Math.atan2(e,t),s.y=Math.atan(i*Math.cos(s.x)/t),s.y=Math.atan(this.radius_p_inv2*Math.tan(s.y))}else if(this.shape==="sphere"){if(this.flip_axis?(i=Math.tan(s.y/this.radius_g_1),e=Math.tan(s.x/this.radius_g_1)*Math.sqrt(1+i*i)):(e=Math.tan(s.x/this.radius_g_1),i=Math.tan(s.y/this.radius_g_1)*Math.sqrt(1+e*e)),n=e*e+i*i+t*t,r=2*this.radius_g*t,o=r*r-4*n*this.C,o<0)return s.x=Number.NaN,s.y=Number.NaN,s;a=(-r-Math.sqrt(o))/(2*n),t=this.radius_g+a*t,e*=a,i*=a,s.x=Math.atan2(e,t),s.y=Math.atan(i*Math.cos(s.x)/t)}return s.x=s.x+this.long0,s}var hot=["Geostationary Satellite View","Geostationary_Satellite","geos"];const cot={init:oot,forward:aot,inverse:lot,names:hot};var Qu=1.340264,td=-.081106,ed=893e-6,sd=.003796,rm=Math.sqrt(3)/2;function uot(){this.es=0,this.long0=this.long0!==void 0?this.long0:0}function dot(s){var t=rt(s.x-this.long0),e=s.y,i=Math.asin(rm*Math.sin(e)),n=i*i,r=n*n*n;return s.x=t*Math.cos(i)/(rm*(Qu+3*td*n+r*(7*ed+9*sd*n))),s.y=i*(Qu+td*n+r*(ed+sd*n)),s.x=this.a*s.x+this.x0,s.y=this.a*s.y+this.y0,s}function got(s){s.x=(s.x-this.x0)/this.a,s.y=(s.y-this.y0)/this.a;var t=1e-9,e=12,i=s.y,n,r,o,a,l,h;for(h=0;h>=1;return e.join("")}const yot='Terms of Use';class xot extends Sn{constructor(t){const e=t.hidpi!==void 0?t.hidpi:!1;super({cacheSize:t.cacheSize,crossOrigin:"anonymous",interpolate:t.interpolate,projection:st("EPSG:3857"),reprojectionErrorThreshold:t.reprojectionErrorThreshold,state:"loading",tileLoadFunction:t.tileLoadFunction,tilePixelRatio:e?2:1,wrapX:t.wrapX!==void 0?t.wrapX:!0,transition:t.transition,zDirection:t.zDirection}),this.hidpi_=e,this.culture_=t.culture!==void 0?t.culture:"en-us",this.maxZoom_=t.maxZoom!==void 0?t.maxZoom:-1,this.apiKey_=t.key,this.imagerySet_=t.imagerySet,this.placeholderTiles_=t.placeholderTiles;const i="https://dev.virtualearth.net/REST/v1/Imagery/Metadata/"+this.imagerySet_+"?uriScheme=https&include=ImageryProviders&key="+this.apiKey_+"&c="+this.culture_;fetch(i).then(n=>n.json()).then(n=>this.handleImageryMetadataResponse(n))}getApiKey(){return this.apiKey_}getImagerySet(){return this.imagerySet_}handleImageryMetadataResponse(t){if(t.statusCode!=200||t.statusDescription!="OK"||t.authenticationResultCode!="ValidCredentials"||t.resourceSets.length!=1||t.resourceSets[0].resources.length!=1){this.setState("error");return}const e=t.resourceSets[0].resources[0],i=this.maxZoom_==-1?e.zoomMax:this.maxZoom_,n=this.getProjection(),r=yo(n),o=this.hidpi_?2:1,a=e.imageWidth==e.imageHeight?e.imageWidth/o:[e.imageWidth/o,e.imageHeight/o],l=Tl({extent:r,minZoom:e.zoomMin,maxZoom:i,tileSize:a});this.tileGrid=l;const h=this.culture_,c=this.hidpi_,u=this.placeholderTiles_;if(this.tileUrlFunction=fc(e.imageUrlSubdomains.map(function(d){const g=[0,0,0],f=e.imageUrl.replace("{subdomain}",d).replace("{culture}",h);return function(p,m,_){if(!p)return;ll(p[0],p[1],p[2],g);const y=new URL(f.replace("{quadkey}",_ot(g))),v=y.searchParams;return c&&(v.set("dpi","d1"),v.set("device","mobile")),u===!0?v.delete("n"):u===!1&&v.set("n","z"),y.toString()}})),e.imageryProviders){const d=Sl(st("EPSG:4326"),this.getProjection());this.setAttributions(g=>{const f=[],p=g.viewState,m=this.getTileGrid(),_=m.getZForResolution(p.resolution,this.zDirection),y=m.getTileCoordForCoordAndZ(p.center,_)[0];return e.imageryProviders.map(function(v){let S=!1;const w=v.coverageAreas;for(let T=0,M=w.length;T=C.zoomMin&&y<=C.zoomMax){const I=C.bbox,O=[I[1],I[0],I[3],I[2]],P=nc(O,d);if(Te(P,g.extent)){S=!0;break}}}S&&f.push(v.attribution)}),f.push(yot),f})}this.setState("ready")}}const vot=xot;class wot extends hl{constructor(t){super({attributions:t.attributions,cacheSize:t.cacheSize,crossOrigin:t.crossOrigin,maxZoom:t.maxZoom!==void 0?t.maxZoom:18,minZoom:t.minZoom,projection:t.projection,transition:t.transition,wrapX:t.wrapX,zDirection:t.zDirection}),this.account_=t.account,this.mapId_=t.map||"",this.config_=t.config||{},this.templateCache_={},this.initializeMap_()}getConfig(){return this.config_}updateConfig(t){Object.assign(this.config_,t),this.initializeMap_()}setConfig(t){this.config_=t||{},this.initializeMap_()}initializeMap_(){const t=JSON.stringify(this.config_);if(this.templateCache_[t]){this.applyTemplate_(this.templateCache_[t]);return}let e="https://"+this.account_+".carto.com/api/v1/map";this.mapId_&&(e+="/named/"+this.mapId_);const i=new XMLHttpRequest;i.addEventListener("load",this.handleInitResponse_.bind(this,t)),i.addEventListener("error",this.handleInitError_.bind(this)),i.open("POST",e),i.setRequestHeader("Content-type","application/json"),i.send(JSON.stringify(this.config_))}handleInitResponse_(t,e){const i=e.target;if(!i.status||i.status>=200&&i.status<300){let n;try{n=JSON.parse(i.responseText)}catch{this.setState("error");return}this.applyTemplate_(n),this.templateCache_[t]=n,this.setState("ready")}else this.setState("error")}handleInitError_(t){this.setState("error")}applyTemplate_(t){const e="https://"+t.cdn_url.https+"/"+this.account_+"/api/v1/map/"+t.layergroupid+"/{z}/{x}/{y}.png";this.setUrl(e)}}const Eot=wot;class Sot extends s0{constructor(t){t=t||{},super({attributions:t.attributions,wrapX:t.wrapX}),this.resolution=void 0,this.distance=t.distance!==void 0?t.distance:20,this.minDistance=t.minDistance||0,this.interpolationRatio=0,this.features=[],this.geometryFunction=t.geometryFunction||function(e){const i=e.getGeometry();return qt(!i||i.getType()==="Point","The default `geometryFunction` can only handle `Point` or null geometries"),i},this.createCustomCluster_=t.createCluster,this.source=null,this.boundRefresh_=this.refresh.bind(this),this.updateDistance(this.distance,this.minDistance),this.setSource(t.source||null)}clear(t){this.features.length=0,super.clear(t)}getDistance(){return this.distance}getSource(){return this.source}loadFeatures(t,e,i){var n;(n=this.source)==null||n.loadFeatures(t,e,i),e!==this.resolution&&(this.resolution=e,this.refresh())}setDistance(t){this.updateDistance(t,this.minDistance)}setMinDistance(t){this.updateDistance(this.distance,t)}getMinDistance(){return this.minDistance}setSource(t){this.source&&this.source.removeEventListener(Zt.CHANGE,this.boundRefresh_),this.source=t,t&&t.addEventListener(Zt.CHANGE,this.boundRefresh_),this.refresh()}refresh(){this.clear(),this.cluster(),this.addFeatures(this.features)}updateDistance(t,e){const i=t===0?0:Math.min(e,t)/t,n=t!==this.distance||this.interpolationRatio!==i;this.distance=t,this.minDistance=e,this.interpolationRatio=i,n&&this.refresh()}cluster(){if(this.resolution===void 0||!this.source)return;const t=Zs(),e=this.distance*this.resolution,i=this.source.getFeatures(),n={};for(let r=0,o=i.length;r=0;--a){const l=this.geometryFunction(t[a]);l?mI(i,l.getCoordinates()):t.splice(a,1)}M9(i,1/t.length);const n=Rs(e),r=this.interpolationRatio,o=new Ts([i[0]*(1-r)+n[0]*r,i[1]*(1-r)+n[1]*r]);return this.createCustomCluster_?this.createCustomCluster_(o,t):new ys({geometry:o,features:t})}}const Mot=Sot,bot="https://tile.googleapis.com/v1/createSession",Tot="https://tile.googleapis.com/v1/2dtiles",Cot="https://tile.googleapis.com/tile/v1/viewport",Rot=22;class Iot extends Sn{constructor(t){const e=!!t.highDpi;super({attributionsCollapsible:t.attributionsCollapsible,cacheSize:t.cacheSize,crossOrigin:"anonymous",interpolate:t.interpolate,projection:"EPSG:3857",reprojectionErrorThreshold:t.reprojectionErrorThreshold,state:"loading",tileLoadFunction:t.tileLoadFunction,tilePixelRatio:e?2:1,wrapX:t.wrapX!==void 0?t.wrapX:!0,transition:t.transition,zDirection:t.zDirection}),this.apiKey_=t.key,this.error_=null;const i={mapType:t.mapType||"roadmap",language:t.language||"en-US",region:t.region||"US"};t.imageFormat&&(i.imageFormat=t.imageFormat),t.scale&&(i.scale=t.scale),e&&(i.highDpi=!0),t.layerTypes&&(i.layerTypes=t.layerTypes),t.styles&&(i.styles=t.styles),t.overlay===!0&&(i.overlay=!0),t.apiOptions&&(i.apiOptions=t.apiOptions),this.sessionTokenRequest_=i,this.sessionTokenValue_,this.sessionRefreshId_,this.previousViewportAttribution_,this.previousViewportExtent_,this.createSession_()}getError(){return this.error_}fetchSessionToken(t,e){return fetch(t,e)}async createSession_(){const t=bot+"?key="+this.apiKey_,e={method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify(this.sessionTokenRequest_)},i=await this.fetchSessionToken(t,e);if(!i.ok){try{const u=await i.json();this.error_=new Error(u.error.message)}catch{this.error_=new Error("Error fetching session token")}this.setState("error");return}const n=await i.json(),r=this.getTilePixelRatio(1),o=[n.tileWidth/r,n.tileHeight/r];this.tileGrid=Tl({extent:yo(this.getProjection()),maxZoom:Rot,tileSize:o});const a=n.session;this.sessionTokenValue_=a;const l=this.apiKey_;this.tileUrlFunction=function(u,d,g){const f=u[0],p=u[1],m=u[2];return`${Tot}/${f}/${p}/${m}?session=${a}&key=${l}`};const h=parseInt(n.expiry,10)*1e3,c=Math.max(h-Date.now()-60*1e3,1);this.sessionRefreshId_=setTimeout(()=>this.createSession_(),c),this.setAttributions(this.fetchAttributions_.bind(this)),this.setState("ready")}async fetchAttributions_(t){if(t.viewHints[Ie.ANIMATING]||t.viewHints[Ie.INTERACTING]||t.animate)return this.previousViewportAttribution_;const[e,i]=h2(_g(t.extent),t.viewState.projection),[n,r]=h2(yg(t.extent),t.viewState.projection),o=`zoom=${this.getTileGrid().getZForResolution(t.viewState.resolution,this.zDirection)}&north=${r}&south=${i}&east=${n}&west=${e}`;if(this.previousViewportExtent_==o)return this.previousViewportAttribution_;this.previousViewportExtent_=o;const a=this.sessionTokenValue_,l=this.apiKey_,h=`${Cot}?session=${a}&key=${l}&${o}`;return this.previousViewportAttribution_=await fetch(h).then(c=>c.json()).then(c=>c.copyright),this.previousViewportAttribution_}disposeInternal(){clearTimeout(this.sessionRefreshId_),super.disposeInternal()}}const Pot=Iot;let aO=class extends Lg{constructor(s,t,e,i,n,r,o){super(t,e,i,n,r,o),this.zoomifyImage_=null,this.tileSize_=s}getImage(){if(this.zoomifyImage_)return this.zoomifyImage_;const s=super.getImage();if(this.state==X.LOADED){const t=this.tileSize_;if(s.width==t[0]&&s.height==t[1])return this.zoomifyImage_=s,s;const e=Se(t[0],t[1]);return e.drawImage(s,0,0),this.zoomifyImage_=e.canvas,e.canvas}return s}};class Aot extends Sn{constructor(t){const e=t.size,i=t.tierSizeCalculation!==void 0?t.tierSizeCalculation:"default",n=t.tilePixelRatio||1,r=e[0],o=e[1],a=[],l=t.tileSize||cc;let h=l*n;switch(i){case"default":for(;r>h||o>h;)a.push([Math.ceil(r/h),Math.ceil(o/h)]),h+=h;break;case"truncated":let T=r,M=o;for(;T>h||M>h;)a.push([Math.ceil(T/h),Math.ceil(M/h)]),T>>=1,M>>=1;break;default:throw new Error("Unknown `tierSizeCalculation` configured")}a.push([1,1]),a.reverse();const c=[n],u=[0];for(let T=1,M=a.length;T{p=l,this.changed()}),w.src=S}}const Lot=Aot;function hu(s){return s.toLocaleString("en",{maximumFractionDigits:10})}class Oot extends Sn{constructor(t){const e=t||{};let i=e.url||"";i=i+(i.lastIndexOf("/")===i.length-1||i===""?"":"/");const n=e.version||os.VERSION2,r=e.sizes||[],o=e.size;qt(o!=null&&Array.isArray(o)&&o.length==2&&!isNaN(o[0])&&o[0]>0&&!isNaN(o[1])&&o[1]>0,"Missing or invalid `size`");const a=o[0],l=o[1],h=e.tileSize,c=e.tilePixelRatio||1,u=e.format||"jpg",d=e.quality||(e.version==os.VERSION1?"native":"default");let g=e.resolutions||[];const f=e.supports||[],p=e.extent||[0,-l,a,0],m=r!=null&&Array.isArray(r)&&r.length>0,_=h!==void 0&&(typeof h=="number"&&Number.isInteger(h)&&h>0||Array.isArray(h)&&h.length>0),y=f!=null&&Array.isArray(f)&&(f.includes("regionByPx")||f.includes("regionByPct"))&&(f.includes("sizeByWh")||f.includes("sizeByH")||f.includes("sizeByW")||f.includes("sizeByPct"));let v,S,w;if(g.sort(function(I,O){return O-I}),_||y)if(h!=null&&(typeof h=="number"&&Number.isInteger(h)&&h>0?(v=h,S=h):Array.isArray(h)&&h.length>0&&((h.length==1||h[1]==null&&Number.isInteger(h[0]))&&(v=h[0],S=h[0]),h.length==2&&(Number.isInteger(h[0])&&Number.isInteger(h[1])?(v=h[0],S=h[1]):h[0]==null&&Number.isInteger(h[1])&&(v=h[1],S=h[1])))),(v===void 0||S===void 0)&&(v=cc,S=cc),g.length==0){w=Math.max(Math.ceil(Math.log(a/v)/Math.LN2),Math.ceil(Math.log(l/S)/Math.LN2));for(let I=w;I>=0;I--)g.push(Math.pow(2,I))}else{const I=Math.max(...g);w=Math.round(Math.log(I)/Math.LN2)}else if(v=a,S=l,g=[],m){r.sort(function(O,P){return O[0]-P[0]}),w=-1;const I=[];for(let O=0;O0&&g[g.length-1]==P){I.push(O);continue}g.push(P),w++}if(I.length>0)for(let O=0;Ow)return;const b=I[1],R=I[2],A=g[E];if(!(b===void 0||R===void 0||A===void 0||b<0||Math.ceil(a/A/v)<=b||R<0||Math.ceil(l/A/S)<=R)){if(y||_){const $=b*v*A,G=R*S*A;let k=v*A,z=S*A,V=v,et=S;if($+k>a&&(k=a-$),G+z>l&&(z=l-G),$+v*A>a&&(V=Math.floor((a-$+A-1)/A)),G+S*A>l&&(et=Math.floor((l-G+A-1)/A)),$==0&&k==a&&G==0&&z==l)D="full";else if(!y||f.includes("regionByPx"))D=$+","+G+","+k+","+z;else if(f.includes("regionByPct")){const F=hu($/a*100),ot=hu(G/l*100),ht=hu(k/a*100),pt=hu(z/l*100);D="pct:"+F+","+ot+","+ht+","+pt}n==os.VERSION3&&(!y||f.includes("sizeByWh"))?x=V+","+et:!y||f.includes("sizeByW")?x=V+",":f.includes("sizeByH")?x=","+et:f.includes("sizeByWh")?x=V+","+et:f.includes("sizeByPct")&&(x="pct:"+hu(100/A))}else if(D="full",m){const $=r[E][0],G=r[E][1];n==os.VERSION3?$==a&&G==l?x="max":x=$+","+G:$==a?x="full":x=$+","}else x=n==os.VERSION3?"max":"full";return i+D+"/"+x+"/0/"+d+"."+u}},C=aO.bind(null,Re(h||256).map(function(I){return I*c}));super({attributions:e.attributions,attributionsCollapsible:e.attributionsCollapsible,cacheSize:e.cacheSize,crossOrigin:e.crossOrigin,interpolate:e.interpolate,projection:e.projection,reprojectionErrorThreshold:e.reprojectionErrorThreshold,state:e.state,tileClass:C,tileGrid:T,tilePixelRatio:e.tilePixelRatio,tileUrlFunction:M,transition:e.transition}),this.zDirection=e.zDirection}}const Fot=Oot;function lO(s,t,e,i,n,r){const o=n.getCode().split(/:(?=\d+$)/).pop(),a=e/i,l=[Mp(Rt(t)/a,cr),Mp(Ee(t)/a,cr)];r.SIZE=l[0]+","+l[1],r.BBOX=t.join(","),r.BBOXSR=o,r.IMAGESR=o,r.DPI=Math.round(r.DPI?r.DPI*i:90*i);const h=s.replace(/MapServer\/?$/,"MapServer/export").replace(/ImageServer\/?$/,"ImageServer/exportImage");return oo(h,r)}function hO(s){const t=s.load?s.load:pa,e=st(s.projection||"EPSG:3857"),i=s.ratio??1.5,n=s.crossOrigin??null;return function(r,o,a){a=s.hidpi?a:1;const l={F:"image",FORMAT:"PNG32",TRANSPARENT:!0};Object.assign(l,s.params),r=m0(r,o,a,i);const h=lO(s.url,r,o,a,e,l),c=new Image;return c.crossOrigin=n,t(c,h).then(u=>{const d=Rt(r)/u.width*a;return{image:u,extent:r,resolution:d,pixelRatio:a}})}}class Not extends ya{constructor(t){t=t||{},super({attributions:t.attributions,interpolate:t.interpolate,projection:t.projection,resolutions:t.resolutions}),this.crossOrigin_=t.crossOrigin!==void 0?t.crossOrigin:null,this.hidpi_=t.hidpi!==void 0?t.hidpi:!0,this.url_=t.url,this.imageLoadFunction_=t.imageLoadFunction!==void 0?t.imageLoadFunction:p0,this.params_=Object.assign({},t.params),this.imageSize_=[0,0],this.renderedRevision_=0,this.ratio_=t.ratio!==void 0?t.ratio:1.5,this.loaderProjection_=null}getParams(){return this.params_}getImageInternal(t,e,i,n){return this.url_===void 0?null:((!this.loader||this.loaderProjection_!==n)&&(this.loaderProjection_=n,this.loader=hO({crossOrigin:this.crossOrigin_,params:this.params_,projection:n,hidpi:this.hidpi_,url:this.url_,ratio:this.ratio_,load:(r,o)=>(this.image.setImage(r),this.imageLoadFunction_(this.image,o),pa(r))})),super.getImageInternal(t,e,i,n))}getImageLoadFunction(){return this.imageLoadFunction_}getUrl(){return this.url_}setImageLoadFunction(t){this.imageLoadFunction_=t,this.changed()}setUrl(t){t!=this.url_&&(this.url_=t,this.loader=null,this.changed())}updateParams(t){Object.assign(this.params_,t),this.changed()}changed(){this.image=null,super.changed()}}const Dot=Not;class kot extends ya{constructor(t){t=t||{},super({attributions:t.attributions,interpolate:t.interpolate,projection:t.projection,resolutions:t.resolutions,state:t.state}),this.canvasFunction_=t.canvasFunction,this.canvas_=null,this.renderedRevision_=0,this.ratio_=t.ratio!==void 0?t.ratio:1.5}getImageInternal(t,e,i,n){e=this.findNearestResolution(e);let r=this.canvas_;if(r&&this.renderedRevision_==this.getRevision()&&r.getResolution()==e&&r.getPixelRatio()==i&&ai(r.getExtent(),t))return r;t=t.slice(),gI(t,this.ratio_);const o=Rt(t)/e,a=Ee(t)/e,l=[o*i,a*i],h=this.canvasFunction_.call(this,t,e,i,l,n);return h&&(r=new sw(t,e,i,h)),this.canvas_=r,this.renderedRevision_=this.getRevision(),r}}const $ot=kot;function Got(s,t,e,i){const n=Rt(s),r=Ee(s),o=t[0],a=t[1],l=.0254/i;return a*n>o*r?n*e/(o*l):r*e/(a*l)}function jot(s,t,e,i,n,r,o){const a=Got(e,i,r,o),l=Rs(e),h={OPERATION:n?"GETDYNAMICMAPOVERLAYIMAGE":"GETMAPIMAGE",VERSION:"2.0.0",LOCALE:"en",CLIENTAGENT:"ol/source/ImageMapGuide source",CLIP:"1",SETDISPLAYDPI:o,SETDISPLAYWIDTH:Math.round(i[0]),SETDISPLAYHEIGHT:Math.round(i[1]),SETVIEWSCALE:a,SETVIEWCENTERX:l[0],SETVIEWCENTERY:l[1]};return Object.assign(h,t),oo(s,h)}function cO(s){const t=s.load||pa,e=s.useOverlay??!1,i=s.metersPerUnit||1,n=s.displayDpi||96,r=s.ratio??1,o=s.crossOrigin??null;return function(a,l,h){const c=new Image;c.crossOrigin=o,a=m0(a,l,h,r);const u=Rt(a)/l,d=Ee(a)/l,g=[u*h,d*h],f=jot(s.url,s.params,a,g,e,i,n);return t(c,f).then(p=>({image:p,extent:a,pixelRatio:h}))}}class zot extends ya{constructor(t){super({interpolate:t.interpolate,projection:t.projection,resolutions:t.resolutions}),this.crossOrigin_=t.crossOrigin!==void 0?t.crossOrigin:null,this.displayDpi_=t.displayDpi!==void 0?t.displayDpi:96,this.params_=Object.assign({},t.params),this.url_=t.url,this.imageLoadFunction_=t.imageLoadFunction!==void 0?t.imageLoadFunction:p0,this.hidpi_=t.hidpi!==void 0?t.hidpi:!0,this.metersPerUnit_=t.metersPerUnit!==void 0?t.metersPerUnit:1,this.ratio_=t.ratio!==void 0?t.ratio:1,this.useOverlay_=t.useOverlay!==void 0?t.useOverlay:!1,this.renderedRevision_=0,this.loaderProjection_=null}getParams(){return this.params_}getImageInternal(t,e,i,n){return this.url_===void 0?null:((!this.loader||this.loaderProjection_!==n)&&(this.loaderProjection_=n,this.loader=cO({crossOrigin:this.crossOrigin_,params:this.params_,hidpi:this.hidpi_,metersPerUnit:this.metersPerUnit_,url:this.url_,useOverlay:this.useOverlay_,ratio:this.ratio_,load:(r,o)=>(this.image.setImage(r),this.imageLoadFunction_(this.image,o),pa(r))})),super.getImageInternal(t,e,i,n))}getImageLoadFunction(){return this.imageLoadFunction_}updateParams(t){Object.assign(this.params_,t),this.changed()}setImageLoadFunction(t){this.imageLoadFunction_=t,this.changed()}changed(){this.image=null,super.changed()}}const Uot=zot,Bot=new Error("Image failed to load");function uO(s,t,e,i,n){return new Promise((r,o)=>{const a=new Image;a.crossOrigin=n.crossOrigin??null,a.addEventListener("load",()=>r(a)),a.addEventListener("error",()=>o(Bot)),a.src=cL(s,t,e,i,n.maxY)})}function bb(s){return function(t,e,i,n){const r=Xtt(s,t,e,i);return uO(r,t,e,i,n)}}function Wot(s){return function(t,e,i,n){const r=s(t,e,i,n);return uO(r,t,e,i,n)}}function Tb(s){let t;if(Array.isArray(s))t=bb(s);else if(typeof s=="string"){const e=_0(s);t=bb(e)}else if(typeof s=="function")t=Wot(s);else throw new Error("The url option must be a single template, an array of templates, or a function for getting a URL");return t}let Cb=0;function Rb(s){return Array.isArray(s)?s.join(` -`):typeof s=="string"?s:(++Cb,"url-function-key-"+Cb)}class Xot extends d0{constructor(t){t=t||{};let e=t.loader,i;t.url&&(e=Tb(t.url),i=Rb(t.url));const n=e?t.state:"loading",r=t.wrapX===void 0?!0:t.wrapX;super({loader:e,key:i,attributions:t.attributions,attributionsCollapsible:t.attributionsCollapsible,maxZoom:t.maxZoom,minZoom:t.minZoom,tileSize:t.tileSize,gutter:t.gutter,maxResolution:t.maxResolution,projection:t.projection,tileGrid:t.tileGrid,state:n,wrapX:r,transition:t.transition,interpolate:t.interpolate!==!1,crossOrigin:t.crossOrigin})}setUrl(t){const e=Tb(t);this.setLoader(e),this.setKey(Rb(t)),this.getState()!=="ready"&&this.setState("ready")}}const Vot=Xot;class Yot extends ya{constructor(t){t=t||{},super({attributions:t.attributions,interpolate:t.interpolate,projection:t.projection,resolutions:t.resolutions}),this.crossOrigin_=t.crossOrigin!==void 0?t.crossOrigin:null,this.url_=t.url,this.imageLoadFunction_=t.imageLoadFunction!==void 0?t.imageLoadFunction:p0,this.params_=Object.assign({},t.params),this.serverType_=t.serverType,this.hidpi_=t.hidpi!==void 0?t.hidpi:!0,this.renderedRevision_=0,this.ratio_=t.ratio!==void 0?t.ratio:1.5,this.loaderProjection_=null}getFeatureInfoUrl(t,e,i,n){const r=st(i),o=this.getProjection();o&&o!==r&&(e=$d(o,r,t,e),t=Dm(t,r,o));const a={url:this.url_,params:{...this.params_,...n},projection:o||r};return tet(a,t,e)}getLegendUrl(t,e){return eet({url:this.url_,params:{...this.params_,...e}},t)}getParams(){return this.params_}getImageInternal(t,e,i,n){return this.url_===void 0?null:((!this.loader||this.loaderProjection_!==n)&&(this.loaderProjection_=n,this.loader=mL({crossOrigin:this.crossOrigin_,params:this.params_,projection:n,serverType:this.serverType_,hidpi:this.hidpi_,url:this.url_,ratio:this.ratio_,load:(r,o)=>(this.image.setImage(r),this.imageLoadFunction_(this.image,o),pa(r))})),super.getImageInternal(t,e,i,n))}getImageLoadFunction(){return this.imageLoadFunction_}getUrl(){return this.url_}setImageLoadFunction(t){this.imageLoadFunction_=t,this.changed()}setUrl(t){t!=this.url_&&(this.url_=t,this.loader=null,this.changed())}updateParams(t){Object.assign(this.params_,t),this.changed()}changed(){this.image=null,super.changed()}}const qot=Yot,Zot={"image/png":!0,"image/jpeg":!0,"image/gif":!0,"image/webp":!0},Hot={"application/vnd.mapbox-vector-tile":!0,"application/geo+json":!0};function dO(s,t){if(!t.length)return s;const e=new URL(s,"file:/");if(e.pathname.split("/").includes("collections"))return Cd('The "collections" query parameter cannot be added to collection endpoints'),s;const i=t.map(o=>encodeURIComponent(o)).join(",");e.searchParams.append("collections",i);const n=s.split("?")[0],r=decodeURIComponent(e.searchParams.toString());return`${n}?${r}`}function Kot(s,t,e){let i,n;for(let r=0;rw.replace(/E|X|Lon/i,"e").replace(/N|Y|Lat/i,"n")).join(""):n.getAxisOrientation()).startsWith("en"),a=t.tileMatrices,l={};for(let w=0;wx.maxTileCol||P.tileRowx.maxTileRow)return}Object.assign(P,y);const D=e.replace(/\{(\w+?)\}/g,function(x,E){return P[E]});return dL(v,D)}return{grid:_,urlTemplate:e,urlFunction:S}}function Qot(s,t){const e=t.tileMatrixSetLimits;let i;if(t.dataType==="map")i=Kot(t.links,s.mediaType,s.collections);else if(t.dataType==="vector")i=Jot(t.links,s.mediaType,s.supportedMediaTypes,s.collections);else throw new Error('Expected tileset data type to be "map" or "vector"');if(t.tileMatrixSet)return Ib(s,t.tileMatrixSet,i,e);const n=t.links.find(a=>a.rel==="http://www.opengis.net/def/rel/ogc/1.0/tiling-scheme");if(!n)throw new Error("Expected http://www.opengis.net/def/rel/ogc/1.0/tiling-scheme link or tileMatrixSet");const r=n.href,o=dL(s.url,r);return uL(o).then(function(a){return Ib(s,a,i,e)})}function gO(s){return uL(s.url).then(function(t){return Qot(s,t)})}class tat extends Sn{constructor(t){super({attributions:t.attributions,cacheSize:t.cacheSize,crossOrigin:t.crossOrigin,interpolate:t.interpolate,projection:t.projection,reprojectionErrorThreshold:t.reprojectionErrorThreshold,state:"loading",tileLoadFunction:t.tileLoadFunction,wrapX:t.wrapX!==void 0?t.wrapX:!0,transition:t.transition});const e={url:t.url,projection:this.getProjection(),mediaType:t.mediaType,context:t.context||null,collections:t.collections};gO(e).then(this.handleTileSetInfo_.bind(this)).catch(this.handleError_.bind(this))}handleTileSetInfo_(t){this.tileGrid=t.grid,this.setTileUrlFunction(t.urlFunction,t.urlTemplate),this.setState("ready")}handleError_(t){Cd(t),this.setState("error")}}const eat=tat;class sat extends y0{constructor(t){super({attributions:t.attributions,attributionsCollapsible:t.attributionsCollapsible,cacheSize:t.cacheSize,format:t.format,overlaps:t.overlaps,projection:t.projection,tileClass:t.tileClass,transition:t.transition,wrapX:t.wrapX,zDirection:t.zDirection,state:"loading"});const e={url:t.url,projection:this.getProjection(),mediaType:t.mediaType,supportedMediaTypes:t.format.supportedMediaTypes,context:t.context||null,collections:t.collections};gO(e).then(this.handleTileSetInfo_.bind(this)).catch(this.handleError_.bind(this))}handleTileSetInfo_(t){this.tileGrid=t.grid,this.setTileUrlFunction(t.urlFunction,t.urlTemplate),this.setState("ready")}handleError_(t){Cd(t),this.setState("error")}}const iat=sat,fO='© OpenStreetMap contributors.';class nat extends hl{constructor(t){t=t||{};let e;t.attributions!==void 0?e=t.attributions:e=[fO];const i=t.crossOrigin!==void 0?t.crossOrigin:"anonymous",n=t.url!==void 0?t.url:"https://tile.openstreetmap.org/{z}/{x}/{y}.png";super({attributions:e,attributionsCollapsible:!1,cacheSize:t.cacheSize,crossOrigin:i,interpolate:t.interpolate,maxZoom:t.maxZoom!==void 0?t.maxZoom:19,reprojectionErrorThreshold:t.reprojectionErrorThreshold,tileLoadFunction:t.tileLoadFunction,transition:t.transition,url:n,wrapX:t.wrapX,zDirection:t.zDirection})}}const rat=nat,Pb=1/0;class oat{constructor(t,e){this.priorityFunction_=t,this.keyFunction_=e,this.elements_=[],this.priorities_=[],this.queuedElements_={}}clear(){this.elements_.length=0,this.priorities_.length=0,Mc(this.queuedElements_)}dequeue(){const t=this.elements_,e=this.priorities_,i=t[0];t.length==1?(t.length=0,e.length=0):(t[0]=t.pop(),e[0]=e.pop(),this.siftUp_(0));const n=this.keyFunction_(i);return delete this.queuedElements_[n],i}enqueue(t){qt(!(this.keyFunction_(t)in this.queuedElements_),"Tried to enqueue an `element` that was already added to the queue");const e=this.priorityFunction_(t);return e!=Pb?(this.elements_.push(t),this.priorities_.push(e),this.queuedElements_[this.keyFunction_(t)]=!0,this.siftDown_(0,this.elements_.length-1),!0):!1}getCount(){return this.elements_.length}getLeftChildIndex_(t){return t*2+1}getRightChildIndex_(t){return t*2+2}getParentIndex_(t){return t-1>>1}heapify_(){let t;for(t=(this.elements_.length>>1)-1;t>=0;t--)this.siftUp_(t)}isEmpty(){return this.elements_.length===0}isKeyQueued(t){return t in this.queuedElements_}isQueued(t){return this.isKeyQueued(this.keyFunction_(t))}siftUp_(t){const e=this.elements_,i=this.priorities_,n=e.length,r=e[t],o=i[t],a=t;for(;t>1;){const l=this.getLeftChildIndex_(t),h=this.getRightChildIndex_(t),c=ht;){const a=this.getParentIndex_(e);if(n[a]>o)i[e]=i[a],n[e]=n[a],e=a;else break}i[e]=r,n[e]=o}reprioritize(){const t=this.priorityFunction_,e=this.elements_,i=this.priorities_;let n=0;const r=e.length;let o,a,l;for(a=0;a0;){const n=this.dequeue()[0],r=n.getKey();n.getState()===X.IDLE&&!(r in this.tilesLoadingKeys_)&&(this.tilesLoadingKeys_[r]=!0,++this.tilesLoading_,++i,n.load())}}}function pO(s){return function(t){const e=t.buffers,i=t.meta,n=t.imageOps,r=t.width,o=t.height,a=e.length,l=e[0].byteLength;if(n){const d=new Array(a);for(let g=0;g"u"?"data:text/javascript;base64,"+Buffer.from(e.join(` -`),"binary").toString("base64"):URL.createObjectURL(new Blob(e,{type:"text/javascript"})));return i.addEventListener("message",t),i}function hat(s,t){const e=pO(s.operation);let i=!1;return{postMessage:function(n){setTimeout(function(){i||t({data:{buffer:e(n),meta:n.meta}})},0)},terminate:function(){i=!0}}}class cat extends Ux{constructor(t){super(),this.imageOps_=!!t.imageOps;let e;t.threads===0?e=0:this.imageOps_?e=1:e=t.threads||1;const i=new Array(e);if(e)for(let n=0;nthis.maxQueueLength_;)this.queue_.shift().callback(null,null)}dispatch_(){if(this.running_||this.queue_.length===0)return;const t=this.queue_.shift();this.job_=t;const e=t.inputs[0].width,i=t.inputs[0].height,n=t.inputs.map(function(l){return l.data.buffer}),r=this.workers_.length;if(this.running_=r,r===1){this.workers_[0].postMessage({buffers:n,meta:t.meta,imageOps:this.imageOps_,width:e,height:i},n);return}const o=t.inputs[0].data.length,a=4*Math.ceil(o/4/r);for(let l=0;lStadia Maps',_at='© OpenMapTiles',yat='© Stamen Design',xat={stamen_terrain:{extension:"png"},stamen_terrain_background:{extension:"png"},stamen_terrain_labels:{extension:"png"},stamen_terrain_lines:{extension:"png"},stamen_toner_background:{extension:"png"},stamen_toner:{extension:"png"},stamen_toner_labels:{extension:"png"},stamen_toner_lines:{extension:"png"},stamen_toner_lite:{extension:"png"},stamen_watercolor:{extension:"jpg"},alidade_smooth:{extension:"png"},alidade_smooth_dark:{extension:"png"},alidade_satellite:{extension:"png"},outdoors:{extension:"png"},osm_bright:{extension:"png"}},vat={stamen_terrain:{minZoom:0,maxZoom:18,retina:!0},stamen_toner:{minZoom:0,maxZoom:20,retina:!0},stamen_watercolor:{minZoom:1,maxZoom:18,retina:!1}};class wat extends hl{constructor(t){const e=t.layer.indexOf("-"),i=e==-1?t.layer:t.layer.slice(0,e),n=vat[i]||{minZoom:0,maxZoom:20,retina:!0},r=xat[t.layer],o=t.apiKey?"?api_key="+t.apiKey:"",a=n.retina&&t.retina?"@2x":"",l=t.url!==void 0?t.url:"https://tiles.stadiamaps.com/tiles/"+t.layer+"/{z}/{x}/{y}"+a+"."+r.extension+o,h=[mat,_at,fO];t.layer.startsWith("stamen_")&&h.splice(1,0,yat),super({attributions:h,cacheSize:t.cacheSize,crossOrigin:"anonymous",interpolate:t.interpolate,maxZoom:t.maxZoom!==void 0?t.maxZoom:n.maxZoom,minZoom:t.minZoom!==void 0?t.minZoom:n.minZoom,reprojectionErrorThreshold:t.reprojectionErrorThreshold,tileLoadFunction:t.tileLoadFunction,transition:t.transition,url:l,tilePixelRatio:a?2:1,wrapX:t.wrapX,zDirection:t.zDirection})}}const Eat=wat;class Sat extends Sn{constructor(t){t=t||{},super({attributions:t.attributions,cacheSize:t.cacheSize,crossOrigin:t.crossOrigin,interpolate:t.interpolate,projection:t.projection,reprojectionErrorThreshold:t.reprojectionErrorThreshold,tileGrid:t.tileGrid,tileLoadFunction:t.tileLoadFunction,url:t.url,urls:t.urls,wrapX:t.wrapX!==void 0?t.wrapX:!0,transition:t.transition,zDirection:t.zDirection}),this.params_=Object.assign({},t.params),this.hidpi_=t.hidpi!==void 0?t.hidpi:!0,this.tmpExtent_=Zs(),this.setKey(this.getKeyForParams_())}getKeyForParams_(){let t=0;const e=[];for(const i in this.params_)e[t++]=i+"-"+this.params_[i];return e.join("/")}getParams(){return this.params_}getRequestUrl_(t,e,i,n,r,o){const a=this.urls;if(!a)return;let l;if(a.length==1)l=a[0];else{const h=kn(Jv(t),a.length);l=a[h]}return lO(l,i,(this.tileGrid||this.getTileGridForProjection(r)).getResolution(t[0]),n,r,o)}getTilePixelRatio(t){return this.hidpi_?t:1}updateParams(t){Object.assign(this.params_,t),this.setKey(this.getKeyForParams_())}tileUrlFunction(t,e,i){let n=this.getTileGrid();if(n||(n=this.getTileGridForProjection(i)),n.getResolutions().length<=t[0])return;e!=1&&!this.hidpi_&&(e=1);const r=n.getTileCoordExtent(t,this.tmpExtent_);let o=Re(n.getTileSize(t[0]),this.tmpSize);e!=1&&(o=YI(o,e,this.tmpSize));const a={F:"image",FORMAT:"PNG32",TRANSPARENT:!0};return Object.assign(a,this.params_),this.getRequestUrl_(t,o,r,e,i,a)}}const Mat=Sat;class bat extends hl{constructor(t){t=t||{},super({projection:t.projection,tileGrid:t.tileGrid,wrapX:t.wrapX!==void 0?t.wrapX:!0,zDirection:t.zDirection,url:t.template||"z:{z} x:{x} y:{y}",tileLoadFunction:(e,i)=>{const n=e.getTileCoord()[0],r=Re(this.tileGrid.getTileSize(n)),o=Se(r[0],r[1]);o.strokeStyle="grey",o.strokeRect(.5,.5,r[0]+.5,r[1]+.5),o.fillStyle="grey",o.strokeStyle="white",o.textAlign="center",o.textBaseline="middle",o.font="24px sans-serif",o.lineWidth=4,o.strokeText(i,r[0]/2,r[1]/2,r[0]),o.fillText(i,r[0]/2,r[1]/2,r[0]),e.setImage(o.canvas)}})}}const Tat=bat;class Cat extends Oc{constructor(t,e,i,n,r,o){super(t,e),this.src_=i,this.extent_=n,this.preemptive_=r,this.grid_=null,this.keys_=null,this.data_=null,this.jsonp_=o}getImage(){return null}getData(t){if(!this.grid_||!this.keys_)return null;const e=(t[0]-this.extent_[0])/(this.extent_[2]-this.extent_[0]),i=(t[1]-this.extent_[1])/(this.extent_[3]-this.extent_[1]),n=this.grid_[Math.floor((1-i)*this.grid_.length)];if(typeof n!="string")return null;let r=n.charCodeAt(Math.floor(e*n.length));r>=93&&r--,r>=35&&r--,r-=32;let o=null;if(r in this.keys_){const a=this.keys_[r];this.data_&&a in this.data_?o=this.data_[a]:o=a}return o}forDataAtCoordinate(t,e,i){this.state==X.EMPTY&&i===!0?(this.state=X.IDLE,bd(this,Zt.CHANGE,n=>{e(this.getData(t))}),this.loadInternal_()):i===!0?setTimeout(()=>{e(this.getData(t))},0):e(this.getData(t))}getKey(){return this.src_}handleError_(){this.state=X.ERROR,this.changed()}handleLoad_(t){this.grid_=t.grid,this.keys_=t.keys,this.data_=t.data,this.state=X.LOADED,this.changed()}loadInternal_(){if(this.state==X.IDLE)if(this.state=X.LOADING,this.jsonp_)Iw(this.src_,this.handleLoad_.bind(this),this.handleError_.bind(this));else{const t=new XMLHttpRequest;t.addEventListener("load",this.onXHRLoad_.bind(this)),t.addEventListener("error",this.onXHRError_.bind(this)),t.open("GET",this.src_),t.send()}}onXHRLoad_(t){const e=t.target;if(!e.status||e.status>=200&&e.status<300){let i;try{i=JSON.parse(e.responseText)}catch{this.handleError_();return}this.handleLoad_(i)}else this.handleError_()}onXHRError_(t){this.handleError_()}load(){this.preemptive_?this.loadInternal_():this.setState(X.EMPTY)}}class Rat extends Fg{constructor(t){if(super({projection:st("EPSG:3857"),state:"loading",wrapX:t.wrapX!==void 0?t.wrapX:!0,zDirection:t.zDirection}),this.preemptive_=t.preemptive!==void 0?t.preemptive:!0,this.tileUrlFunction_=Ytt,this.template_=void 0,this.jsonp_=t.jsonp||!1,t.url)if(this.jsonp_)Iw(t.url,this.handleTileJSONResponse.bind(this),this.handleTileJSONError.bind(this));else{const e=new XMLHttpRequest;e.addEventListener("load",this.onXHRLoad_.bind(this)),e.addEventListener("error",this.onXHRError_.bind(this)),e.open("GET",t.url),e.send()}else if(t.tileJSON)this.handleTileJSONResponse(t.tileJSON);else throw new Error("Either `url` or `tileJSON` options must be provided")}onXHRLoad_(t){const e=t.target;if(!e.status||e.status>=200&&e.status<300){let i;try{i=JSON.parse(e.responseText)}catch{this.handleTileJSONError();return}this.handleTileJSONResponse(i)}else this.handleTileJSONError()}onXHRError_(t){this.handleTileJSONError()}getTemplate(){return this.template_}forDataAtCoordinateAndResolution(t,e,i,n){if(this.tileGrid){const r=this.tileGrid.getZForResolution(e,this.zDirection),o=this.tileGrid.getTileCoordForCoordAndZ(t,r);this.getTile(o[0],o[1],o[2],1,this.getProjection()).forDataAtCoordinate(t,i,n)}else n===!0?setTimeout(function(){i(null)},0):i(null)}handleTileJSONError(){this.setState("error")}handleTileJSONResponse(t){const e=st("EPSG:4326"),i=this.getProjection();let n;if(t.bounds!==void 0){const c=Sl(e,i);n=nc(t.bounds,c)}const r=yo(i),o=t.minzoom||0,a=t.maxzoom||22,l=Tl({extent:r,maxZoom:a,minZoom:o});this.tileGrid=l,this.template_=t.template;const h=t.grids;if(!h){this.setState("error");return}if(this.tileUrlFunction_=Tw(h,l),t.attribution){const c=n!==void 0?n:r;this.setAttributions(function(u){return Te(c,u.extent)?[t.attribution]:null})}this.setState("ready")}getTile(t,e,i,n,r){const o=ro(t,e,i);if(this.tileCache.containsKey(o))return this.tileCache.get(o);const a=[t,e,i],l=this.getTileCoordForTileUrlFunction(a,r),h=this.tileUrlFunction_(l,n,r),c=new Cat(a,h!==void 0?X.IDLE:X.EMPTY,h!==void 0?h:"",this.tileGrid.getTileCoordExtent(a),this.preemptive_,this.jsonp_);return this.tileCache.set(o,c),c}useTile(t,e,i){const n=ro(t,e,i);this.tileCache.containsKey(n)&&this.tileCache.get(n)}}const Iat=Rat;function Pat(s,t){const e=new l0(32),i=s.getExtent();return function(n,r){e.expireCache(),i&&(n=He(i,n));const o=s.getZForResolution(r),a=[];return s.forEachTileCoord(n,o,l=>{const h=l.toString();if(!e.containsKey(h)){const c=t(l);e.set(h,c)}a.push(e.get(h))}),a}}const Aat=Object.freeze(Object.defineProperty({__proto__:null,BingMaps:vot,CartoDB:Eot,Cluster:Mot,DataTile:d0,GeoTIFF:bw,Google:Pot,IIIF:Fot,Image:ya,ImageArcGISRest:Dot,ImageCanvas:$ot,ImageMapGuide:Uot,ImageStatic:hL,ImageTile:Vot,ImageWMS:qot,OGCMapTile:eat,OGCVectorTile:iat,OSM:rat,Raster:pat,Source:Lc,StadiaMaps:Eat,Tile:Fg,TileArcGISRest:Mat,TileDebug:Tat,TileImage:Sn,TileJSON:gL,TileWMS:_L,UTFGrid:Iat,UrlTile:Rw,Vector:s0,VectorTile:y0,WMTS:yL,XYZ:hl,Zoomify:Lot,createArcGISRestLoader:hO,createMapGuideLoader:cO,createStaticLoader:lL,createWMSLoader:mL,sourcesFromTileGrid:Pat},Symbol.toStringTag,{value:"Module"}));class Lat extends Sn{constructor(t){super({attributions:t.attributions,cacheSize:t.cacheSize,tilePixelRatio:t.tilePixelRatio,transition:t.transition,interpolate:t.interpolate!==void 0?t.interpolate:!0,key:t.key,attributionsCollapsible:t.attributionsCollapsible,zDirection:t.zDirection,wrapX:t.wrapX}),this.version_=t.version!==void 0?t?.version:"1.0.0",this.dimensions_=t.dimensions!==void 0?t.dimensions:{},this.layer_=t.layer,fetch(t.url).then(e=>e.text()).then(e=>new window.DOMParser().parseFromString(e,"application/xml")).then(e=>{this.handleCapabilitiesResponse(e,t)})}handleCapabilitiesResponse(t,e){const i=new kv().read(t),n=xL(i,e);this.crossOrigin=n.crossOrigin,this.projection=n.projection,this.tileGrid=n.tileGrid,this.requestEncoding_=n.requestEncoding,this.matrixSet_=n.matrixSet,this.style_=n.style,this.format_=n.format,this.dimensions_=n.dimensions,this.setUrls(n.urls),this.urls&&this.urls.length>0&&(this.tileUrlFunction=fc(this.urls.map(this.createFromWMTSTemplate.bind(this)))),this.setState("ready")}createFromWMTSTemplate(t){const e=this.requestEncoding_,i={layer:this.layer_,style:this.style_,tilematrixset:this.matrixSet_};e=="KVP"&&Object.assign(i,{Service:"WMTS",Request:"GetTile",Version:this.version_,Format:this.format_}),t=e=="KVP"?oo(t,i):t.replace(/\{(\w+?)\}/g,function(o,a){return a.toLowerCase()in i?i[a.toLowerCase()]:o});const n=this.tileGrid,r=this.dimensions_;return function(o){if(!o)return;const a={TileMatrix:n.getMatrixId(o[0]),TileCol:o[1],TileRow:o[2]};Object.assign(a,r);let l=t;return e=="KVP"?l=oo(l,a):l=l.replace(/\{(\w+?)\}/g,function(h,c){return a[c]}),l}}}window.eoxMapAdvancedOlSources={...Aat,WMTSCapabilities:Lat};const Oat=["enabled"],Fat=["config"],Nat=["config"],Dat={__name:"EodashMap",props:{enableCompare:{type:Boolean,default:!1}},setup(s){const t=s,e=R0(null),i=R0(null),n=R0("first"),r=Ww({center:[15,48],zoom:4,layers:[{type:"Tile",properties:{id:"osm",title:"Background"},source:{type:"OSM"}}]}),o=Ww({center:[15,48],zoom:4,layers:[]});Ma&&Ma.value&&Ma.value.length===3&&(r.center=[Ma.value?.[0],Ma.value[1]],r.zoom=Ma.value[2]);const a=c=>{const u=c.map,[d,g]=u?.getView().getCenter()??[0,0],f=u?.getView().getZoom();!Number.isNaN(d)&&!Number.isNaN(g)&&!Number.isNaN(f)&&(Ma.value=[d,g,f])},l=MO(),h=async(c,u,d)=>{const f=SO(d.value,c.value).map(M=>new Zw(M)),p=[],m={type:"Group",properties:{id:"AnalysisGroup",title:"Analysis Layers",layerControlExpand:!0},layers:[]};for(const M of f){let C;u?C=await M.createLayersJson(new Date(u)):C=await M.createLayersJson(),C&&m.layers.push(...C)}m.layers.forEach(M=>{M.properties.layerControlExpand=!0,M.properties.layerControlToolsExpand=!0}),p.push(m);const y=await new Zw(I0.value).buildJsonArray(d.value,I0.value,d.value?.title??"",d.value?.endpointtype??!1),v={type:"Group",properties:{id:"BaseLayersGroup",title:"Base Layers"},layers:[]},S=y.filter(M=>M.properties.group==="baselayer");S.length?(v.layers.push(...S),v.layers.forEach(M=>{M.properties.layerControlExclusive=!0})):v.layers.push({type:"Tile",properties:{id:"osm",title:"Background",layerControlExclusive:!0},source:{type:"OSM"}}),v.layers.length&&p.push(v);const w={type:"Group",properties:{id:"OverlayGroup",title:"Overlay Layers"},layers:[]},T=y.filter(M=>M.properties.group==="overlay");return T.length&&(w.layers.push(...T),p.unshift(w)),p};return bO(()=>{TO.value=e.value,e.value?.map?.on("moveend",a);const{selectedStac:c,selectedCompareStac:u}=CO(l);t.enableCompare&&Xw([u,Yw],async([d,g],[f,p])=>{if(d){const m=await h(AO,g,u);i.value.layers=m,n.value=""}}),Xw([c,Yw],async([d,g],[f,p])=>{if(d){const m=await h(I0,g,c);if(e.value.layers=m,f?.id!==d.id){n.value="first";const _=d.extent?.spatial.bbox[0],y=[_[0]>-180?_[0]:-180,_[1]>-90?_[1]:-90,_[2]<180?_[2]:180,_[3]<90?_[3]:90],v=dF(y,"EPSG:4326",e.value?.map?.getView().getProjection());e.value.zoomExtent=v}}},{immediate:!0})}),RO(()=>{e.value?.map?.un("moveend",a)}),(c,u)=>(IO(),PO("eox-map-compare",{class:"fill-height fill-width overflow-none",enabled:n.value},[Vw("eox-map",{class:"fill-height fill-width overflow-none",slot:"first",sync:"eox-map#compare",ref_key:"eoxMap",ref:e,id:"main",config:r},null,8,Fat),Vw("eox-map",{class:"fill-height fill-width overflow-none",id:"compare",slot:"second",ref_key:"compareMap",ref:i,config:o},null,8,Nat)],8,Oat))}},Rct=Object.freeze(Object.defineProperty({__proto__:null,default:Dat},Symbol.toStringTag,{value:"Module"}));export{Rct as E,Cct as a,Tct as o,g0 as x}; +northing meters`+s;var d=u/2,g=0,f=0,p,m,_,y,v;return d>0&&(p=1e5/Math.pow(10,d),m=s.substring(r,r+d),g=parseFloat(m)*p,_=s.substring(r+d),f=parseFloat(_)*p),y=g+h,v=f+c,{easting:y,northing:v,zoneLetter:a,zoneNumber:o,accuracy:p}}function Ust(s,t){for(var e=qL.charCodeAt(t-1),i=1e5,n=!1;e!==s.charCodeAt(0);){if(e++,e===mi&&e++,e===tn&&e++,e>Ru){if(n)throw"Bad character: "+s;e=vh,n=!0}i+=1e5}return i}function Bst(s,t){if(s>"V")throw"MGRSPoint given invalid Northing "+s;for(var e=ZL.charCodeAt(t-1),i=0,n=!1;e!==s.charCodeAt(0);){if(e++,e===mi&&e++,e===tn&&e++,e>Tu){if(n)throw"Bad character: "+s;e=vh,n=!0}i+=1e5}return i}function Wst(s){var t;switch(s){case"C":t=11e5;break;case"D":t=2e6;break;case"E":t=28e5;break;case"F":t=37e5;break;case"G":t=46e5;break;case"H":t=55e5;break;case"J":t=64e5;break;case"K":t=73e5;break;case"L":t=82e5;break;case"M":t=91e5;break;case"N":t=0;break;case"P":t=8e5;break;case"Q":t=17e5;break;case"R":t=26e5;break;case"S":t=35e5;break;case"T":t=44e5;break;case"U":t=53e5;break;case"V":t=62e5;break;case"W":t=7e6;break;case"X":t=79e5;break;default:t=-1}if(t>=0)return t;throw"Invalid zone letter: "+s}function pc(s,t,e){if(!(this instanceof pc))return new pc(s,t,e);if(Array.isArray(s))this.x=s[0],this.y=s[1],this.z=s[2]||0;else if(typeof s=="object")this.x=s.x,this.y=s.y,this.z=s.z||0;else if(typeof s=="string"&&typeof t>"u"){var i=s.split(",");this.x=parseFloat(i[0],10),this.y=parseFloat(i[1],10),this.z=parseFloat(i[2],10)||0}else this.x=s,this.y=t,this.z=e||0;console.warn("proj4.Point will be removed in version 3, use proj4.toPoint")}pc.fromMGRS=function(s){return new pc(KL(s))};pc.prototype.toMGRS=function(s){return HL([this.x,this.y],s)};var Xst=1,Vst=.25,wb=.046875,Eb=.01953125,Sb=.01068115234375,Yst=.75,qst=.46875,Zst=.013020833333333334,Hst=.007120768229166667,Kst=.3645833333333333,Jst=.005696614583333333,Qst=.3076171875;function tO(s){var t=[];t[0]=Xst-s*(Vst+s*(wb+s*(Eb+s*Sb))),t[1]=s*(Yst-s*(wb+s*(Eb+s*Sb)));var e=s*s;return t[2]=e*(qst-s*(Zst+s*Hst)),e*=s,t[3]=e*(Kst-s*Jst),t[4]=e*s*Qst,t}function E0(s,t,e,i){return e*=t,t*=t,i[0]*s-e*(i[1]+t*(i[2]+t*(i[3]+t*i[4])))}var tit=20;function eO(s,t,e){for(var i=1/(1-t),n=s,r=tit;r;--r){var o=Math.sin(n),a=1-t*o*o;if(a=(E0(n,o,Math.cos(n),e)-s)*(a*Math.sqrt(a))*i,n-=a,Math.abs(a)tt?Math.tan(e):0,f=Math.pow(g,2),p=Math.pow(f,2);n=1-this.es*Math.pow(a,2),h=h/Math.sqrt(n);var m=E0(e,a,l,this.en);r=this.a*(this.k0*h*(1+c/6*(1-f+u+c/20*(5-18*f+p+14*u-58*f*u+c/42*(61+179*p-p*f-479*f)))))+this.x0,o=this.a*(this.k0*(m-this.ml0+a*i*h/2*(1+c/12*(5-f+9*u+4*d+c/30*(61+p-58*f+270*u-330*f*u+c/56*(1385+543*p-p*f-3111*f))))))+this.y0}else{var _=l*Math.sin(i);if(Math.abs(Math.abs(_)-1)=1){if(_-1>tt)return 93;o=0}else o=Math.acos(o);e<0&&(o=-o),o=this.a*this.k0*(o-this.lat0)+this.y0}return s.x=r,s.y=o,s}function iit(s){var t,e,i,n,r=(s.x-this.x0)*(1/this.a),o=(s.y-this.y0)*(1/this.a);if(this.es)if(t=this.ml0+o/this.k0,e=eO(t,this.es,this.en),Math.abs(e)tt?Math.tan(e):0,c=this.ep2*Math.pow(l,2),u=Math.pow(c,2),d=Math.pow(h,2),g=Math.pow(d,2);t=1-this.es*Math.pow(a,2);var f=r*Math.sqrt(t)/this.k0,p=Math.pow(f,2);t=t*h,i=e-t*p/(1-this.es)*.5*(1-p/12*(5+3*d-9*c*d+c-4*u-p/30*(61+90*d-252*c*d+45*g+46*c-p/56*(1385+3633*d+4095*g+1574*g*d)))),n=rt(this.long0+f*(1-p/6*(1+2*d+c-p/20*(5+28*d+24*g+8*c*d+6*c-p/42*(61+662*d+1320*g+720*g*d))))/l)}else i=K*kg(o),n=0;else{var m=Math.exp(r/this.k0),_=.5*(m-1/m),y=this.lat0+o/this.k0,v=Math.cos(y);t=Math.sqrt((1-Math.pow(v,2))/(1+Math.pow(_,2))),i=Math.asin(t),o<0&&(i=-i),_===0&&v===0?n=0:n=rt(Math.atan2(_,v)+this.long0)}return s.x=n,s.y=i,s}var nit=["Fast_Transverse_Mercator","Fast Transverse Mercator"];const Bf={init:eit,forward:sit,inverse:iit,names:nit};function sO(s){var t=Math.exp(s);return t=(t-1/t)/2,t}function on(s,t){s=Math.abs(s),t=Math.abs(t);var e=Math.max(s,t),i=Math.min(s,t)/(e||1);return e*Math.sqrt(1+Math.pow(i,2))}function rit(s){var t=1+s,e=t-1;return e===0?s:s*Math.log(t)/e}function oit(s){var t=Math.abs(s);return t=rit(t*(1+t/(on(1,t)+1))),s<0?-t:t}function jw(s,t){for(var e=2*Math.cos(2*t),i=s.length-1,n=s[i],r=0,o;--i>=0;)o=-r+e*n+s[i],r=n,n=o;return t+o*Math.sin(2*t)}function ait(s,t){for(var e=2*Math.cos(t),i=s.length-1,n=s[i],r=0,o;--i>=0;)o=-r+e*n+s[i],r=n,n=o;return Math.sin(t)*o}function lit(s){var t=Math.exp(s);return t=(t+1/t)/2,t}function iO(s,t,e){for(var i=Math.sin(t),n=Math.cos(t),r=sO(e),o=lit(e),a=2*n*o,l=-2*i*r,h=s.length-1,c=s[h],u=0,d=0,g=0,f,p;--h>=0;)f=d,p=u,d=c,u=g,c=-f+a*d-l*u+s[h],g=-p+l*d+a*u;return a=i*o,l=n*r,[a*c-l*g,a*g+l*c]}function hit(){if(!this.approx&&(isNaN(this.es)||this.es<=0))throw new Error('Incorrect elliptical usage. Try using the +approx option in the proj string, or PROJECTION["Fast_Transverse_Mercator"] in the WKT.');this.approx&&(Bf.init.apply(this),this.forward=Bf.forward,this.inverse=Bf.inverse),this.x0=this.x0!==void 0?this.x0:0,this.y0=this.y0!==void 0?this.y0:0,this.long0=this.long0!==void 0?this.long0:0,this.lat0=this.lat0!==void 0?this.lat0:0,this.cgb=[],this.cbg=[],this.utg=[],this.gtu=[];var s=this.es/(1+Math.sqrt(1-this.es)),t=s/(2-s),e=t;this.cgb[0]=t*(2+t*(-2/3+t*(-2+t*(116/45+t*(26/45+t*(-2854/675)))))),this.cbg[0]=t*(-2+t*(2/3+t*(4/3+t*(-82/45+t*(32/45+t*(4642/4725)))))),e=e*t,this.cgb[1]=e*(7/3+t*(-8/5+t*(-227/45+t*(2704/315+t*(2323/945))))),this.cbg[1]=e*(5/3+t*(-16/15+t*(-13/9+t*(904/315+t*(-1522/945))))),e=e*t,this.cgb[2]=e*(56/15+t*(-136/35+t*(-1262/105+t*(73814/2835)))),this.cbg[2]=e*(-26/15+t*(34/21+t*(8/5+t*(-12686/2835)))),e=e*t,this.cgb[3]=e*(4279/630+t*(-332/35+t*(-399572/14175))),this.cbg[3]=e*(1237/630+t*(-12/5+t*(-24832/14175))),e=e*t,this.cgb[4]=e*(4174/315+t*(-144838/6237)),this.cbg[4]=e*(-734/315+t*(109598/31185)),e=e*t,this.cgb[5]=e*(601676/22275),this.cbg[5]=e*(444337/155925),e=Math.pow(t,2),this.Qn=this.k0/(1+t)*(1+e*(1/4+e*(1/64+e/256))),this.utg[0]=t*(-.5+t*(2/3+t*(-37/96+t*(1/360+t*(81/512+t*(-96199/604800)))))),this.gtu[0]=t*(.5+t*(-2/3+t*(5/16+t*(41/180+t*(-127/288+t*(7891/37800)))))),this.utg[1]=e*(-1/48+t*(-1/15+t*(437/1440+t*(-46/105+t*(1118711/3870720))))),this.gtu[1]=e*(13/48+t*(-3/5+t*(557/1440+t*(281/630+t*(-1983433/1935360))))),e=e*t,this.utg[2]=e*(-17/480+t*(37/840+t*(209/4480+t*(-5569/90720)))),this.gtu[2]=e*(61/240+t*(-103/140+t*(15061/26880+t*(167603/181440)))),e=e*t,this.utg[3]=e*(-4397/161280+t*(11/504+t*(830251/7257600))),this.gtu[3]=e*(49561/161280+t*(-179/168+t*(6601661/7257600))),e=e*t,this.utg[4]=e*(-4583/161280+t*(108847/3991680)),this.gtu[4]=e*(34729/80640+t*(-3418889/1995840)),e=e*t,this.utg[5]=e*(-20648693/638668800),this.gtu[5]=e*(212378941/319334400);var i=jw(this.cbg,this.lat0);this.Zb=-this.Qn*(i+ait(this.gtu,2*i))}function cit(s){var t=rt(s.x-this.long0),e=s.y;e=jw(this.cbg,e);var i=Math.sin(e),n=Math.cos(e),r=Math.sin(t),o=Math.cos(t);e=Math.atan2(i,o*n),t=Math.atan2(r*n,on(i,n*o)),t=oit(Math.tan(t));var a=iO(this.gtu,2*e,2*t);e=e+a[0],t=t+a[1];var l,h;return Math.abs(t)<=2.623395162778?(l=this.a*(this.Qn*t)+this.x0,h=this.a*(this.Qn*e+this.Zb)+this.y0):(l=1/0,h=1/0),s.x=l,s.y=h,s}function uit(s){var t=(s.x-this.x0)*(1/this.a),e=(s.y-this.y0)*(1/this.a);e=(e-this.Zb)/this.Qn,t=t/this.Qn;var i,n;if(Math.abs(t)<=2.623395162778){var r=iO(this.utg,2*e,2*t);e=e+r[0],t=t+r[1],t=Math.atan(sO(t));var o=Math.sin(e),a=Math.cos(e),l=Math.sin(t),h=Math.cos(t);e=Math.atan2(o*h,on(l,h*a)),t=Math.atan2(l,h*a),i=rt(t+this.long0),n=jw(this.cgb,e)}else i=1/0,n=1/0;return s.x=i,s.y=n,s}var dit=["Extended_Transverse_Mercator","Extended Transverse Mercator","etmerc","Transverse_Mercator","Transverse Mercator","Gauss Kruger","Gauss_Kruger","tmerc"];const Wf={init:hit,forward:cit,inverse:uit,names:dit};function git(s,t){if(s===void 0){if(s=Math.floor((rt(t)+Math.PI)*30/Math.PI)+1,s<0)return 0;if(s>60)return 60}return s}var fit="etmerc";function pit(){var s=git(this.zone,this.long0);if(s===void 0)throw new Error("unknown utm zone");this.lat0=0,this.long0=(6*Math.abs(s)-183)*Ls,this.x0=5e5,this.y0=this.utmSouth?1e7:0,this.k0=.9996,Wf.init.apply(this),this.forward=Wf.forward,this.inverse=Wf.inverse}var mit=["Universal Transverse Mercator System","utm"];const _it={init:pit,names:mit,dependsOn:fit};function zw(s,t){return Math.pow((1-s)/(1+s),t)}var yit=20;function xit(){var s=Math.sin(this.lat0),t=Math.cos(this.lat0);t*=t,this.rc=Math.sqrt(1-this.es)/(1-this.es*s*s),this.C=Math.sqrt(1+this.es*t*t/(1-this.es)),this.phic0=Math.asin(s/this.C),this.ratexp=.5*this.C*this.e,this.K=Math.tan(.5*this.phic0+ye)/(Math.pow(Math.tan(.5*this.lat0+ye),this.C)*zw(this.e*s,this.ratexp))}function vit(s){var t=s.x,e=s.y;return s.y=2*Math.atan(this.K*Math.pow(Math.tan(.5*e+ye),this.C)*zw(this.e*Math.sin(e),this.ratexp))-K,s.x=this.C*t,s}function wit(s){for(var t=1e-14,e=s.x/this.C,i=s.y,n=Math.pow(Math.tan(.5*i+ye)/this.K,1/this.C),r=yit;r>0&&(i=2*Math.atan(n*zw(this.e*Math.sin(s.y),-.5*this.e))-K,!(Math.abs(i-s.y)0?this.con=1:this.con=-1),this.cons=Math.sqrt(Math.pow(1+this.e,1+this.e)*Math.pow(1-this.e,1-this.e)),this.k0===1&&!isNaN(this.lat_ts)&&Math.abs(this.coslat0)<=tt&&Math.abs(Math.cos(this.lat_ts))>tt&&(this.k0=.5*this.cons*wr(this.e,Math.sin(this.lat_ts),Math.cos(this.lat_ts))/Gn(this.e,this.con*this.lat_ts,this.con*Math.sin(this.lat_ts))),this.ms1=wr(this.e,this.sinlat0,this.coslat0),this.X0=2*Math.atan(this.ssfn_(this.lat0,this.sinlat0,this.e))-K,this.cosX0=Math.cos(this.X0),this.sinX0=Math.sin(this.X0))}function Pit(s){var t=s.x,e=s.y,i=Math.sin(e),n=Math.cos(e),r,o,a,l,h,c,u=rt(t-this.long0);return Math.abs(Math.abs(t-this.long0)-Math.PI)<=tt&&Math.abs(e+this.lat0)<=tt?(s.x=NaN,s.y=NaN,s):this.sphere?(r=2*this.k0/(1+this.sinlat0*i+this.coslat0*n*Math.cos(u)),s.x=this.a*r*n*Math.sin(u)+this.x0,s.y=this.a*r*(this.coslat0*i-this.sinlat0*n*Math.cos(u))+this.y0,s):(o=2*Math.atan(this.ssfn_(e,i,this.e))-K,l=Math.cos(o),a=Math.sin(o),Math.abs(this.coslat0)<=tt?(h=Gn(this.e,e*this.con,this.con*i),c=2*this.a*this.k0*h/this.cons,s.x=this.x0+c*Math.sin(t-this.long0),s.y=this.y0-this.con*c*Math.cos(t-this.long0),s):(Math.abs(this.sinlat0)0?t=rt(this.long0+Math.atan2(s.x,-1*s.y)):t=rt(this.long0+Math.atan2(s.x,s.y)):t=rt(this.long0+Math.atan2(s.x*Math.sin(a),o*this.coslat0*Math.cos(a)-s.y*this.sinlat0*Math.sin(a))),s.x=t,s.y=e,s)}else if(Math.abs(this.coslat0)<=tt){if(o<=tt)return e=this.lat0,t=this.long0,s.x=t,s.y=e,s;s.x*=this.con,s.y*=this.con,i=o*this.cons/(2*this.a*this.k0),e=this.con*Bd(this.e,i),t=this.con*rt(this.con*this.long0+Math.atan2(s.x,-1*s.y))}else n=2*Math.atan(o*this.cosX0/(2*this.a*this.k0*this.ms1)),t=this.long0,o<=tt?r=this.X0:(r=Math.asin(Math.cos(n)*this.sinX0+s.y*Math.sin(n)*this.cosX0/o),t=rt(this.long0+Math.atan2(s.x*Math.sin(n),o*this.cosX0*Math.cos(n)-s.y*this.sinX0*Math.sin(n)))),e=-1*Bd(this.e,Math.tan(.5*(K+r)));return s.x=t,s.y=e,s}var Lit=["stere","Stereographic_South_Pole","Polar Stereographic (variant B)","Polar_Stereographic"];const Oit={init:Iit,forward:Pit,inverse:Ait,names:Lit,ssfn_:Rit};function Fit(){var s=this.lat0;this.lambda0=this.long0;var t=Math.sin(s),e=this.a,i=this.rf,n=1/i,r=2*n-Math.pow(n,2),o=this.e=Math.sqrt(r);this.R=this.k0*e*Math.sqrt(1-r)/(1-r*Math.pow(t,2)),this.alpha=Math.sqrt(1+r/(1-r)*Math.pow(Math.cos(s),4)),this.b0=Math.asin(t/this.alpha);var a=Math.log(Math.tan(Math.PI/4+this.b0/2)),l=Math.log(Math.tan(Math.PI/4+s/2)),h=Math.log((1+o*t)/(1-o*t));this.K=a-this.alpha*l+this.alpha*o/2*h}function Nit(s){var t=Math.log(Math.tan(Math.PI/4-s.y/2)),e=this.e/2*Math.log((1+this.e*Math.sin(s.y))/(1-this.e*Math.sin(s.y))),i=-this.alpha*(t+e)+this.K,n=2*(Math.atan(Math.exp(i))-Math.PI/4),r=this.alpha*(s.x-this.lambda0),o=Math.atan(Math.sin(r)/(Math.sin(this.b0)*Math.tan(n)+Math.cos(this.b0)*Math.cos(r))),a=Math.asin(Math.cos(this.b0)*Math.sin(n)-Math.sin(this.b0)*Math.cos(n)*Math.cos(r));return s.y=this.R/2*Math.log((1+Math.sin(a))/(1-Math.sin(a)))+this.y0,s.x=this.R*o+this.x0,s}function Dit(s){for(var t=s.x-this.x0,e=s.y-this.y0,i=t/this.R,n=2*(Math.atan(Math.exp(e/this.R))-Math.PI/4),r=Math.asin(Math.cos(this.b0)*Math.sin(n)+Math.sin(this.b0)*Math.cos(n)*Math.cos(i)),o=Math.atan(Math.sin(i)/(Math.cos(this.b0)*Math.cos(i)-Math.sin(this.b0)*Math.tan(n))),a=this.lambda0+o/this.alpha,l=0,h=r,c=-1e3,u=0;Math.abs(h-c)>1e-7;){if(++u>20)return;l=1/this.alpha*(Math.log(Math.tan(Math.PI/4+r/2))-this.K)+this.e*Math.log(Math.tan(Math.PI/4+Math.asin(this.e*Math.sin(h))/2)),c=h,h=2*Math.atan(Math.exp(l))-Math.PI/2}return s.x=a,s.y=h,s}var kit=["somerc"];const $it={init:Fit,forward:Nit,inverse:Dit,names:kit};var sh=1e-7;function Git(s){var t=["Hotine_Oblique_Mercator","Hotine_Oblique_Mercator_Azimuth_Natural_Origin"],e=typeof s.PROJECTION=="object"?Object.keys(s.PROJECTION)[0]:s.PROJECTION;return"no_uoff"in s||"no_off"in s||t.indexOf(e)!==-1}function jit(){var s,t,e,i,n,r,o,a,l,h,c=0,u,d=0,g=0,f=0,p=0,m=0,_=0;this.no_off=Git(this),this.no_rot="no_rot"in this;var y=!1;"alpha"in this&&(y=!0);var v=!1;if("rectified_grid_angle"in this&&(v=!0),y&&(_=this.alpha),v&&(c=this.rectified_grid_angle*Ls),y||v)d=this.longc;else if(g=this.long1,p=this.lat1,f=this.long2,m=this.lat2,Math.abs(p-m)<=sh||(s=Math.abs(p))<=sh||Math.abs(s-K)<=sh||Math.abs(Math.abs(this.lat0)-K)<=sh||Math.abs(Math.abs(m)-K)<=sh)throw new Error;var S=1-this.es;t=Math.sqrt(S),Math.abs(this.lat0)>tt?(a=Math.sin(this.lat0),e=Math.cos(this.lat0),s=1-this.es*a*a,this.B=e*e,this.B=Math.sqrt(1+this.es*this.B*this.B/S),this.A=this.B*this.k0*t/s,i=this.B*t/(e*Math.sqrt(s)),n=i*i-1,n<=0?n=0:(n=Math.sqrt(n),this.lat0<0&&(n=-n)),this.E=n+=i,this.E*=Math.pow(Gn(this.e,this.lat0,a),this.B)):(this.B=1/t,this.A=this.k0,this.E=i=n=1),y||v?(y?(u=Math.asin(Math.sin(_)/i),v||(c=_)):(u=c,_=Math.asin(i*Math.sin(u))),this.lam0=d-Math.asin(.5*(n-1/n)*Math.tan(u))/this.B):(r=Math.pow(Gn(this.e,p,Math.sin(p)),this.B),o=Math.pow(Gn(this.e,m,Math.sin(m)),this.B),n=this.E/r,l=(o-r)/(o+r),h=this.E*this.E,h=(h-o*r)/(h+o*r),s=g-f,s<-Math.pi?f-=zd:s>Math.pi&&(f+=zd),this.lam0=rt(.5*(g+f)-Math.atan(h*Math.tan(.5*this.B*(g-f))/l)/this.B),u=Math.atan(2*Math.sin(this.B*rt(g-this.lam0))/(n-1/n)),c=_=Math.asin(i*Math.sin(u))),this.singam=Math.sin(u),this.cosgam=Math.cos(u),this.sinrot=Math.sin(c),this.cosrot=Math.cos(c),this.rB=1/this.B,this.ArB=this.A*this.rB,this.BrA=1/this.ArB,this.A*this.B,this.no_off?this.u_0=0:(this.u_0=Math.abs(this.ArB*Math.atan(Math.sqrt(i*i-1)/Math.cos(_))),this.lat0<0&&(this.u_0=-this.u_0)),n=.5*u,this.v_pole_n=this.ArB*Math.log(Math.tan(ye-n)),this.v_pole_s=this.ArB*Math.log(Math.tan(ye+n))}function zit(s){var t={},e,i,n,r,o,a,l,h;if(s.x=s.x-this.lam0,Math.abs(Math.abs(s.y)-K)>tt){if(o=this.E/Math.pow(Gn(this.e,s.y,Math.sin(s.y)),this.B),a=1/o,e=.5*(o-a),i=.5*(o+a),r=Math.sin(this.B*s.x),n=(e*this.singam-r*this.cosgam)/i,Math.abs(Math.abs(n)-1)0?this.v_pole_n:this.v_pole_s,l=this.ArB*s.y;return this.no_rot?(t.x=l,t.y=h):(l-=this.u_0,t.x=h*this.cosrot+l*this.sinrot,t.y=l*this.cosrot-h*this.sinrot),t.x=this.a*t.x+this.x0,t.y=this.a*t.y+this.y0,t}function Uit(s){var t,e,i,n,r,o,a,l={};if(s.x=(s.x-this.x0)*(1/this.a),s.y=(s.y-this.y0)*(1/this.a),this.no_rot?(e=s.y,t=s.x):(e=s.x*this.cosrot-s.y*this.sinrot,t=s.y*this.cosrot+s.x*this.sinrot+this.u_0),i=Math.exp(-this.BrA*e),n=.5*(i-1/i),r=.5*(i+1/i),o=Math.sin(this.BrA*t),a=(o*this.cosgam+n*this.singam)/r,Math.abs(Math.abs(a)-1)tt?this.ns=Math.log(i/a)/Math.log(n/l):this.ns=t,isNaN(this.ns)&&(this.ns=t),this.f0=i/(this.ns*Math.pow(n,this.ns)),this.rh=this.a*this.f0*Math.pow(h,this.ns),this.title||(this.title="Lambert Conformal Conic")}}function Vit(s){var t=s.x,e=s.y;Math.abs(2*Math.abs(e)-Math.PI)<=tt&&(e=kg(e)*(K-2*tt));var i=Math.abs(Math.abs(e)-K),n,r;if(i>tt)n=Gn(this.e,e,Math.sin(e)),r=this.a*this.f0*Math.pow(n,this.ns);else{if(i=e*this.ns,i<=0)return null;r=0}var o=this.ns*rt(t-this.long0);return s.x=this.k0*(r*Math.sin(o))+this.x0,s.y=this.k0*(this.rh-r*Math.cos(o))+this.y0,s}function Yit(s){var t,e,i,n,r,o=(s.x-this.x0)/this.k0,a=this.rh-(s.y-this.y0)/this.k0;this.ns>0?(t=Math.sqrt(o*o+a*a),e=1):(t=-Math.sqrt(o*o+a*a),e=-1);var l=0;if(t!==0&&(l=Math.atan2(e*o,e*a)),t!==0||this.ns>0){if(e=1/this.ns,i=Math.pow(t/(this.a*this.f0),e),n=Bd(this.e,i),n===-9999)return null}else n=-K;return r=rt(l/this.ns+this.long0),s.x=r,s.y=n,s}var qit=["Lambert Tangential Conformal Conic Projection","Lambert_Conformal_Conic","Lambert_Conformal_Conic_1SP","Lambert_Conformal_Conic_2SP","lcc","Lambert Conic Conformal (1SP)","Lambert Conic Conformal (2SP)"];const Zit={init:Xit,forward:Vit,inverse:Yit,names:qit};function Hit(){this.a=6377397155e-3,this.es=.006674372230614,this.e=Math.sqrt(this.es),this.lat0||(this.lat0=.863937979737193),this.long0||(this.long0=.7417649320975901-.308341501185665),this.k0||(this.k0=.9999),this.s45=.785398163397448,this.s90=2*this.s45,this.fi0=this.lat0,this.e2=this.es,this.e=Math.sqrt(this.e2),this.alfa=Math.sqrt(1+this.e2*Math.pow(Math.cos(this.fi0),4)/(1-this.e2)),this.uq=1.04216856380474,this.u0=Math.asin(Math.sin(this.fi0)/this.alfa),this.g=Math.pow((1+this.e*Math.sin(this.fi0))/(1-this.e*Math.sin(this.fi0)),this.alfa*this.e/2),this.k=Math.tan(this.u0/2+this.s45)/Math.pow(Math.tan(this.fi0/2+this.s45),this.alfa)*this.g,this.k1=this.k0,this.n0=this.a*Math.sqrt(1-this.e2)/(1-this.e2*Math.pow(Math.sin(this.fi0),2)),this.s0=1.37008346281555,this.n=Math.sin(this.s0),this.ro0=this.k1*this.n0/Math.tan(this.s0),this.ad=this.s90-this.uq}function Kit(s){var t,e,i,n,r,o,a,l=s.x,h=s.y,c=rt(l-this.long0);return t=Math.pow((1+this.e*Math.sin(h))/(1-this.e*Math.sin(h)),this.alfa*this.e/2),e=2*(Math.atan(this.k*Math.pow(Math.tan(h/2+this.s45),this.alfa)/t)-this.s45),i=-c*this.alfa,n=Math.asin(Math.cos(this.ad)*Math.sin(e)+Math.sin(this.ad)*Math.cos(e)*Math.cos(i)),r=Math.asin(Math.cos(e)*Math.sin(i)/Math.cos(n)),o=this.n*r,a=this.ro0*Math.pow(Math.tan(this.s0/2+this.s45),this.n)/Math.pow(Math.tan(n/2+this.s45),this.n),s.y=a*Math.cos(o)/1,s.x=a*Math.sin(o)/1,this.czech||(s.y*=-1,s.x*=-1),s}function Jit(s){var t,e,i,n,r,o,a,l,h=s.x;s.x=s.y,s.y=h,this.czech||(s.y*=-1,s.x*=-1),o=Math.sqrt(s.x*s.x+s.y*s.y),r=Math.atan2(s.y,s.x),n=r/Math.sin(this.s0),i=2*(Math.atan(Math.pow(this.ro0/o,1/this.n)*Math.tan(this.s0/2+this.s45))-this.s45),t=Math.asin(Math.cos(this.ad)*Math.sin(i)-Math.sin(this.ad)*Math.cos(i)*Math.cos(n)),e=Math.asin(Math.cos(i)*Math.sin(n)/Math.cos(t)),s.x=this.long0-e/this.alfa,a=t,l=0;var c=0;do s.y=2*(Math.atan(Math.pow(this.k,-1/this.alfa)*Math.pow(Math.tan(t/2+this.s45),1/this.alfa)*Math.pow((1+this.e*Math.sin(a))/(1-this.e*Math.sin(a)),this.e/2))-this.s45),Math.abs(a-s.y)<1e-10&&(l=1),a=s.y,c+=1;while(l===0&&c<15);return c>=15?null:s}var Qit=["Krovak","krovak"];const tnt={init:Hit,forward:Kit,inverse:Jit,names:Qit};function li(s,t,e,i,n){return s*n-t*Math.sin(2*n)+e*Math.sin(4*n)-i*Math.sin(6*n)}function $g(s){return 1-.25*s*(1+s/16*(3+1.25*s))}function Gg(s){return .375*s*(1+.25*s*(1+.46875*s))}function jg(s){return .05859375*s*s*(1+.75*s)}function zg(s){return s*s*s*(35/3072)}function mc(s,t,e){var i=t*e;return s/Math.sqrt(1-i*i)}function kc(s){return Math.abs(s)1e-7?(e=s*t,(1-s*s)*(t/(1-e*e)-.5/s*Math.log((1-e)/(1+e)))):2*t}var ont=1,ant=2,lnt=3,hnt=4;function cnt(){var s=Math.abs(this.lat0);if(Math.abs(s-K)0){var t;switch(this.qp=ta(this.e,1),this.mmf=.5/(1-this.es),this.apa=xnt(this.es),this.mode){case this.N_POLE:this.dd=1;break;case this.S_POLE:this.dd=1;break;case this.EQUIT:this.rq=Math.sqrt(.5*this.qp),this.dd=1/this.rq,this.xmf=1,this.ymf=.5*this.qp;break;case this.OBLIQ:this.rq=Math.sqrt(.5*this.qp),t=Math.sin(this.lat0),this.sinb1=ta(this.e,t)/this.qp,this.cosb1=Math.sqrt(1-this.sinb1*this.sinb1),this.dd=Math.cos(this.lat0)/(Math.sqrt(1-this.es*t*t)*this.rq*this.cosb1),this.ymf=(this.xmf=this.rq)/this.dd,this.xmf*=this.dd;break}}else this.mode===this.OBLIQ&&(this.sinph0=Math.sin(this.lat0),this.cosph0=Math.cos(this.lat0))}function unt(s){var t,e,i,n,r,o,a,l,h,c,u=s.x,d=s.y;if(u=rt(u-this.long0),this.sphere){if(r=Math.sin(d),c=Math.cos(d),i=Math.cos(u),this.mode===this.OBLIQ||this.mode===this.EQUIT){if(e=this.mode===this.EQUIT?1+c*i:1+this.sinph0*r+this.cosph0*c*i,e<=tt)return null;e=Math.sqrt(2/e),t=e*c*Math.sin(u),e*=this.mode===this.EQUIT?r:this.cosph0*r-this.sinph0*c*i}else if(this.mode===this.N_POLE||this.mode===this.S_POLE){if(this.mode===this.N_POLE&&(i=-i),Math.abs(d+this.lat0)=0?(t=(h=Math.sqrt(o))*n,e=i*(this.mode===this.S_POLE?h:-h)):t=e=0;break}}return s.x=this.a*t+this.x0,s.y=this.a*e+this.y0,s}function dnt(s){s.x-=this.x0,s.y-=this.y0;var t=s.x/this.a,e=s.y/this.a,i,n,r,o,a,l,h;if(this.sphere){var c=0,u,d=0;if(u=Math.sqrt(t*t+e*e),n=u*.5,n>1)return null;switch(n=2*Math.asin(n),(this.mode===this.OBLIQ||this.mode===this.EQUIT)&&(d=Math.sin(n),c=Math.cos(n)),this.mode){case this.EQUIT:n=Math.abs(u)<=tt?0:Math.asin(e*d/u),t*=d,e=c*u;break;case this.OBLIQ:n=Math.abs(u)<=tt?this.lat0:Math.asin(c*this.sinph0+e*d*this.cosph0/u),t*=d*this.cosph0,e=(c-Math.sin(n)*this.sinph0)*u;break;case this.N_POLE:e=-e,n=K-n;break;case this.S_POLE:n-=K;break}i=e===0&&(this.mode===this.EQUIT||this.mode===this.OBLIQ)?0:Math.atan2(t,e)}else{if(h=0,this.mode===this.OBLIQ||this.mode===this.EQUIT){if(t/=this.dd,e*=this.dd,l=Math.sqrt(t*t+e*e),l1&&(s=s>1?1:-1),Math.asin(s)}function Snt(){Math.abs(this.lat1+this.lat2)tt?this.ns0=(this.ms1*this.ms1-this.ms2*this.ms2)/(this.qs2-this.qs1):this.ns0=this.con,this.c=this.ms1*this.ms1+this.ns0*this.qs1,this.rh=this.a*Math.sqrt(this.c-this.ns0*this.qs0)/this.ns0)}function Mnt(s){var t=s.x,e=s.y;this.sin_phi=Math.sin(e),this.cos_phi=Math.cos(e);var i=ta(this.e3,this.sin_phi),n=this.a*Math.sqrt(this.c-this.ns0*i)/this.ns0,r=this.ns0*rt(t-this.long0),o=n*Math.sin(r)+this.x0,a=this.rh-n*Math.cos(r)+this.y0;return s.x=o,s.y=a,s}function bnt(s){var t,e,i,n,r,o;return s.x-=this.x0,s.y=this.rh-s.y+this.y0,this.ns0>=0?(t=Math.sqrt(s.x*s.x+s.y*s.y),i=1):(t=-Math.sqrt(s.x*s.x+s.y*s.y),i=-1),n=0,t!==0&&(n=Math.atan2(i*s.x,i*s.y)),i=t*this.ns0/this.a,this.sphere?o=Math.asin((this.c-i*i)/(2*this.ns0)):(e=(this.c-i*i)/this.ns0,o=this.phi1z(this.e3,e)),r=rt(n/this.ns0+this.long0),s.x=r,s.y=o,s}function Cnt(s,t){var e,i,n,r,o,a=ua(.5*t);if(s0||Math.abs(o)<=tt?(a=this.x0+this.a*r*e*Math.sin(i)/o,l=this.y0+this.a*r*(this.cos_p14*t-this.sin_p14*e*n)/o):(a=this.x0+this.infinity_dist*e*Math.sin(i),l=this.y0+this.infinity_dist*(this.cos_p14*t-this.sin_p14*e*n)),s.x=a,s.y=l,s}function Ant(s){var t,e,i,n,r,o;return s.x=(s.x-this.x0)/this.a,s.y=(s.y-this.y0)/this.a,s.x/=this.k0,s.y/=this.k0,(t=Math.sqrt(s.x*s.x+s.y*s.y))?(n=Math.atan2(t,this.rc),e=Math.sin(n),i=Math.cos(n),o=ua(i*this.sin_p14+s.y*e*this.cos_p14/t),r=Math.atan2(s.x*e,t*this.cos_p14*i-s.y*this.sin_p14*e),r=rt(this.long0+r)):(o=this.phic0,r=0),s.x=r,s.y=o,s}var Lnt=["gnom"];const Ont={init:Int,forward:Pnt,inverse:Ant,names:Lnt};function Fnt(s,t){var e=1-(1-s*s)/(2*s)*Math.log((1-s)/(1+s));if(Math.abs(Math.abs(t)-e)<1e-6)return t<0?-1*K:K;for(var i=Math.asin(.5*t),n,r,o,a,l=0;l<30;l++)if(r=Math.sin(i),o=Math.cos(i),a=s*r,n=Math.pow(1-a*a,2)/(2*o)*(t/(1-s*s)-r/(1-a*a)+.5/s*Math.log((1-a)/(1+a))),i+=n,Math.abs(n)<=1e-10)return i;return NaN}function Nnt(){this.sphere||(this.k0=wr(this.e,Math.sin(this.lat_ts),Math.cos(this.lat_ts)))}function Dnt(s){var t=s.x,e=s.y,i,n,r=rt(t-this.long0);if(this.sphere)i=this.x0+this.a*r*Math.cos(this.lat_ts),n=this.y0+this.a*Math.sin(e)/Math.cos(this.lat_ts);else{var o=ta(this.e,Math.sin(e));i=this.x0+this.a*this.k0*r,n=this.y0+this.a*o*.5/this.k0}return s.x=i,s.y=n,s}function knt(s){s.x-=this.x0,s.y-=this.y0;var t,e;return this.sphere?(t=rt(this.long0+s.x/this.a/Math.cos(this.lat_ts)),e=Math.asin(s.y/this.a*Math.cos(this.lat_ts))):(e=Fnt(this.e,2*s.y*this.k0/this.a),t=rt(this.long0+s.x/(this.a*this.k0))),s.x=t,s.y=e,s}var $nt=["cea"];const Gnt={init:Nnt,forward:Dnt,inverse:knt,names:$nt};function jnt(){this.x0=this.x0||0,this.y0=this.y0||0,this.lat0=this.lat0||0,this.long0=this.long0||0,this.lat_ts=this.lat_ts||0,this.title=this.title||"Equidistant Cylindrical (Plate Carre)",this.rc=Math.cos(this.lat_ts)}function znt(s){var t=s.x,e=s.y,i=rt(t-this.long0),n=kc(e-this.lat0);return s.x=this.x0+this.a*i*this.rc,s.y=this.y0+this.a*n,s}function Unt(s){var t=s.x,e=s.y;return s.x=rt(this.long0+(t-this.x0)/(this.a*this.rc)),s.y=kc(this.lat0+(e-this.y0)/this.a),s}var Bnt=["Equirectangular","Equidistant_Cylindrical","eqc"];const Wnt={init:jnt,forward:znt,inverse:Unt,names:Bnt};var Mb=20;function Xnt(){this.temp=this.b/this.a,this.es=1-Math.pow(this.temp,2),this.e=Math.sqrt(this.es),this.e0=$g(this.es),this.e1=Gg(this.es),this.e2=jg(this.es),this.e3=zg(this.es),this.ml0=this.a*li(this.e0,this.e1,this.e2,this.e3,this.lat0)}function Vnt(s){var t=s.x,e=s.y,i,n,r,o=rt(t-this.long0);if(r=o*Math.sin(e),this.sphere)Math.abs(e)<=tt?(i=this.a*o,n=-1*this.a*this.lat0):(i=this.a*Math.sin(r)/Math.tan(e),n=this.a*(kc(e-this.lat0)+(1-Math.cos(r))/Math.tan(e)));else if(Math.abs(e)<=tt)i=this.a*o,n=-1*this.ml0;else{var a=mc(this.a,this.e,Math.sin(e))/Math.tan(e);i=a*Math.sin(r),n=this.a*li(this.e0,this.e1,this.e2,this.e3,e)-this.ml0+a*(1-Math.cos(r))}return s.x=i+this.x0,s.y=n+this.y0,s}function Ynt(s){var t,e,i,n,r,o,a,l,h;if(i=s.x-this.x0,n=s.y-this.y0,this.sphere)if(Math.abs(n+this.a*this.lat0)<=tt)t=rt(i/this.a+this.long0),e=0;else{o=this.lat0+n/this.a,a=i*i/this.a/this.a+o*o,l=o;var c;for(r=Mb;r;--r)if(c=Math.tan(l),h=-1*(o*(l*c+1)-l-.5*(l*l+a)*c)/((l-o)/c-1),l+=h,Math.abs(h)<=tt){e=l;break}t=rt(this.long0+Math.asin(i*Math.tan(l)/this.a)/Math.sin(e))}else if(Math.abs(n+this.ml0)<=tt)e=0,t=rt(this.long0+i/this.a);else{o=(this.ml0+n)/this.a,a=i*i/this.a/this.a+o*o,l=o;var u,d,g,f,p;for(r=Mb;r;--r)if(p=this.e*Math.sin(l),u=Math.sqrt(1-p*p)*Math.tan(l),d=this.a*li(this.e0,this.e1,this.e2,this.e3,l),g=this.e0-2*this.e1*Math.cos(2*l)+4*this.e2*Math.cos(4*l)-6*this.e3*Math.cos(6*l),f=d/this.a,h=(o*(u*f+1)-f-.5*u*(f*f+a))/(this.es*Math.sin(2*l)*(f*f+a-2*o*f)/(4*u)+(o-f)*(u*g-2/Math.sin(2*l))-g),l-=h,Math.abs(h)<=tt){e=l;break}u=Math.sqrt(1-this.es*Math.pow(Math.sin(e),2))*Math.tan(e),t=rt(this.long0+Math.asin(i*u/this.a)/Math.sin(e))}return s.x=t,s.y=e,s}var qnt=["Polyconic","poly"];const Znt={init:Xnt,forward:Vnt,inverse:Ynt,names:qnt};function Hnt(){this.A=[],this.A[1]=.6399175073,this.A[2]=-.1358797613,this.A[3]=.063294409,this.A[4]=-.02526853,this.A[5]=.0117879,this.A[6]=-.0055161,this.A[7]=.0026906,this.A[8]=-.001333,this.A[9]=67e-5,this.A[10]=-34e-5,this.B_re=[],this.B_im=[],this.B_re[1]=.7557853228,this.B_im[1]=0,this.B_re[2]=.249204646,this.B_im[2]=.003371507,this.B_re[3]=-.001541739,this.B_im[3]=.04105856,this.B_re[4]=-.10162907,this.B_im[4]=.01727609,this.B_re[5]=-.26623489,this.B_im[5]=-.36249218,this.B_re[6]=-.6870983,this.B_im[6]=-1.1651967,this.C_re=[],this.C_im=[],this.C_re[1]=1.3231270439,this.C_im[1]=0,this.C_re[2]=-.577245789,this.C_im[2]=-.007809598,this.C_re[3]=.508307513,this.C_im[3]=-.112208952,this.C_re[4]=-.15094762,this.C_im[4]=.18200602,this.C_re[5]=1.01418179,this.C_im[5]=1.64497696,this.C_re[6]=1.9660549,this.C_im[6]=2.5127645,this.D=[],this.D[1]=1.5627014243,this.D[2]=.5185406398,this.D[3]=-.03333098,this.D[4]=-.1052906,this.D[5]=-.0368594,this.D[6]=.007317,this.D[7]=.0122,this.D[8]=.00394,this.D[9]=-.0013}function Knt(s){var t,e=s.x,i=s.y,n=i-this.lat0,r=e-this.long0,o=n/Ju*1e-5,a=r,l=1,h=0;for(t=1;t<=10;t++)l=l*o,h=h+this.A[t]*l;var c=h,u=a,d=1,g=0,f,p,m=0,_=0;for(t=1;t<=6;t++)f=d*c-g*u,p=g*c+d*u,d=f,g=p,m=m+this.B_re[t]*d-this.B_im[t]*g,_=_+this.B_im[t]*d+this.B_re[t]*g;return s.x=_*this.a+this.x0,s.y=m*this.a+this.y0,s}function Jnt(s){var t,e=s.x,i=s.y,n=e-this.x0,r=i-this.y0,o=r/this.a,a=n/this.a,l=1,h=0,c,u,d=0,g=0;for(t=1;t<=6;t++)c=l*o-h*a,u=h*o+l*a,l=c,h=u,d=d+this.C_re[t]*l-this.C_im[t]*h,g=g+this.C_im[t]*l+this.C_re[t]*h;for(var f=0;f.999999999999&&(e=.999999999999),t=Math.asin(e);var i=rt(this.long0+s.x/(.900316316158*this.a*Math.cos(t)));i<-Math.PI&&(i=-Math.PI),i>Math.PI&&(i=Math.PI),e=(2*t+Math.sin(2*t))/Math.PI,Math.abs(e)>1&&(e=1);var n=Math.asin(e);return s.x=i,s.y=n,s}var prt=["Mollweide","moll"];const mrt={init:drt,forward:grt,inverse:frt,names:prt};function _rt(){Math.abs(this.lat1+this.lat2)=0?(e=Math.sqrt(s.x*s.x+s.y*s.y),t=1):(e=-Math.sqrt(s.x*s.x+s.y*s.y),t=-1);var r=0;if(e!==0&&(r=Math.atan2(t*s.x,t*s.y)),this.sphere)return n=rt(this.long0+r/this.ns),i=kc(this.g-e/this.a),s.x=n,s.y=i,s;var o=this.g-e/this.a;return i=im(o,this.e0,this.e1,this.e2,this.e3),n=rt(this.long0+r/this.ns),s.x=n,s.y=i,s}var vrt=["Equidistant_Conic","eqdc"];const wrt={init:_rt,forward:yrt,inverse:xrt,names:vrt};function Ert(){this.R=this.a}function Srt(s){var t=s.x,e=s.y,i=rt(t-this.long0),n,r;Math.abs(e)<=tt&&(n=this.x0+this.R*i,r=this.y0);var o=ua(2*Math.abs(e/Math.PI));(Math.abs(i)<=tt||Math.abs(Math.abs(e)-K)<=tt)&&(n=this.x0,e>=0?r=this.y0+Math.PI*this.R*Math.tan(.5*o):r=this.y0+Math.PI*this.R*-Math.tan(.5*o));var a=.5*Math.abs(Math.PI/i-i/Math.PI),l=a*a,h=Math.sin(o),c=Math.cos(o),u=c/(h+c-1),d=u*u,g=u*(2/h-1),f=g*g,p=Math.PI*this.R*(a*(u-f)+Math.sqrt(l*(u-f)*(u-f)-(f+l)*(d-f)))/(f+l);i<0&&(p=-p),n=this.x0+p;var m=l+u;return p=Math.PI*this.R*(g*m-a*Math.sqrt((f+l)*(l+1)-m*m))/(f+l),e>=0?r=this.y0+p:r=this.y0-p,s.x=n,s.y=r,s}function Mrt(s){var t,e,i,n,r,o,a,l,h,c,u,d,g;return s.x-=this.x0,s.y-=this.y0,u=Math.PI*this.R,i=s.x/u,n=s.y/u,r=i*i+n*n,o=-Math.abs(n)*(1+r),a=o-2*n*n+i*i,l=-2*o+1+2*n*n+r*r,g=n*n/l+(2*a*a*a/l/l/l-9*o*a/l/l)/27,h=(o-a*a/3/l)/l,c=2*Math.sqrt(-h/3),u=3*g/h/c,Math.abs(u)>1&&(u>=0?u=1:u=-1),d=Math.acos(u)/3,s.y>=0?e=(-c*Math.cos(d+Math.PI/3)-a/3/l)*Math.PI:e=-(-c*Math.cos(d+Math.PI/3)-a/3/l)*Math.PI,Math.abs(i)2*K*this.a?void 0:(e=t/this.a,i=Math.sin(e),n=Math.cos(e),r=this.long0,Math.abs(t)<=tt?o=this.lat0:(o=ua(n*this.sin_p12+s.y*i*this.cos_p12/t),a=Math.abs(this.lat0)-K,Math.abs(a)<=tt?this.lat0>=0?r=rt(this.long0+Math.atan2(s.x,-s.y)):r=rt(this.long0-Math.atan2(-s.x,s.y)):r=rt(this.long0+Math.atan2(s.x*i,t*this.cos_p12*n-s.y*this.sin_p12*i))),s.x=r,s.y=o,s)):(l=$g(this.es),h=Gg(this.es),c=jg(this.es),u=zg(this.es),Math.abs(this.sin_p12-1)<=tt?(d=this.a*li(l,h,c,u,K),t=Math.sqrt(s.x*s.x+s.y*s.y),g=d-t,o=im(g/this.a,l,h,c,u),r=rt(this.long0+Math.atan2(s.x,-1*s.y)),s.x=r,s.y=o,s):Math.abs(this.sin_p12+1)<=tt?(d=this.a*li(l,h,c,u,K),t=Math.sqrt(s.x*s.x+s.y*s.y),g=t-d,o=im(g/this.a,l,h,c,u),r=rt(this.long0+Math.atan2(s.x,s.y)),s.x=r,s.y=o,s):(t=Math.sqrt(s.x*s.x+s.y*s.y),m=Math.atan2(s.x,s.y),f=mc(this.a,this.e,this.sin_p12),_=Math.cos(m),y=this.e*this.cos_p12*_,v=-y*y/(1-this.es),S=3*this.es*(1-v)*this.sin_p12*this.cos_p12*_/(1-this.es),w=t/f,C=w-v*(1+v)*Math.pow(w,3)/6-S*(1+3*v)*Math.pow(w,4)/24,M=1-v*C*C/2-w*C*C*C/6,p=Math.asin(this.sin_p12*Math.cos(C)+this.cos_p12*Math.sin(C)*_),r=rt(this.long0+Math.asin(Math.sin(m)*Math.sin(C)/Math.cos(p))),T=Math.sin(p),o=Math.atan2((T-this.es*M*this.sin_p12)*Math.tan(p),T*(1-this.es)),s.x=r,s.y=o,s))}var Prt=["Azimuthal_Equidistant","aeqd"];const Art={init:Trt,forward:Rrt,inverse:Irt,names:Prt};function Lrt(){this.sin_p14=Math.sin(this.lat0),this.cos_p14=Math.cos(this.lat0)}function Ort(s){var t,e,i,n,r,o,a,l,h=s.x,c=s.y;return i=rt(h-this.long0),t=Math.sin(c),e=Math.cos(c),n=Math.cos(i),o=this.sin_p14*t+this.cos_p14*e*n,r=1,(o>0||Math.abs(o)<=tt)&&(a=this.a*r*e*Math.sin(i),l=this.y0+this.a*r*(this.cos_p14*t-this.sin_p14*e*n)),s.x=a,s.y=l,s}function Frt(s){var t,e,i,n,r,o,a;return s.x-=this.x0,s.y-=this.y0,t=Math.sqrt(s.x*s.x+s.y*s.y),e=ua(t/this.a),i=Math.sin(e),n=Math.cos(e),o=this.long0,Math.abs(t)<=tt?(a=this.lat0,s.x=o,s.y=a,s):(a=ua(n*this.sin_p14+s.y*i*this.cos_p14/t),r=Math.abs(this.lat0)-K,Math.abs(r)<=tt?(this.lat0>=0?o=rt(this.long0+Math.atan2(s.x,-s.y)):o=rt(this.long0-Math.atan2(-s.x,s.y)),s.x=o,s.y=a,s):(o=rt(this.long0+Math.atan2(s.x*i,t*this.cos_p14*n-s.y*this.sin_p14*i)),s.x=o,s.y=a,s))}var Nrt=["ortho"];const Drt={init:Lrt,forward:Ort,inverse:Frt,names:Nrt};var Ue={FRONT:1,RIGHT:2,BACK:3,LEFT:4,TOP:5,BOTTOM:6},xe={AREA_0:1,AREA_1:2,AREA_2:3,AREA_3:4};function krt(){this.x0=this.x0||0,this.y0=this.y0||0,this.lat0=this.lat0||0,this.long0=this.long0||0,this.lat_ts=this.lat_ts||0,this.title=this.title||"Quadrilateralized Spherical Cube",this.lat0>=K-ye/2?this.face=Ue.TOP:this.lat0<=-(K-ye/2)?this.face=Ue.BOTTOM:Math.abs(this.long0)<=ye?this.face=Ue.FRONT:Math.abs(this.long0)<=K+ye?this.face=this.long0>0?Ue.RIGHT:Ue.LEFT:this.face=Ue.BACK,this.es!==0&&(this.one_minus_f=1-(this.a-this.b)/this.a,this.one_minus_f_squared=this.one_minus_f*this.one_minus_f)}function $rt(s){var t={x:0,y:0},e,i,n,r,o,a,l={value:0};if(s.x-=this.long0,this.es!==0?e=Math.atan(this.one_minus_f_squared*Math.tan(s.y)):e=s.y,i=s.x,this.face===Ue.TOP)r=K-e,i>=ye&&i<=K+ye?(l.value=xe.AREA_0,n=i-K):i>K+ye||i<=-(K+ye)?(l.value=xe.AREA_1,n=i>0?i-es:i+es):i>-(K+ye)&&i<=-ye?(l.value=xe.AREA_2,n=i+K):(l.value=xe.AREA_3,n=i);else if(this.face===Ue.BOTTOM)r=K+e,i>=ye&&i<=K+ye?(l.value=xe.AREA_0,n=-i+K):i=-ye?(l.value=xe.AREA_1,n=-i):i<-ye&&i>=-(K+ye)?(l.value=xe.AREA_2,n=-i-K):(l.value=xe.AREA_3,n=i>0?-i+es:-i-es);else{var h,c,u,d,g,f,p;this.face===Ue.RIGHT?i=kh(i,+K):this.face===Ue.BACK?i=kh(i,+es):this.face===Ue.LEFT&&(i=kh(i,-K)),d=Math.sin(e),g=Math.cos(e),f=Math.sin(i),p=Math.cos(i),h=g*p,c=g*f,u=d,this.face===Ue.FRONT?(r=Math.acos(h),n=If(r,u,c,l)):this.face===Ue.RIGHT?(r=Math.acos(c),n=If(r,u,-h,l)):this.face===Ue.BACK?(r=Math.acos(-h),n=If(r,u,-c,l)):this.face===Ue.LEFT?(r=Math.acos(-c),n=If(r,u,h,l)):(r=n=0,l.value=xe.AREA_0)}return a=Math.atan(12/es*(n+Math.acos(Math.sin(n)*Math.cos(ye))-K)),o=Math.sqrt((1-Math.cos(r))/(Math.cos(a)*Math.cos(a))/(1-Math.cos(Math.atan(1/Math.cos(n))))),l.value===xe.AREA_1?a+=K:l.value===xe.AREA_2?a+=es:l.value===xe.AREA_3&&(a+=1.5*es),t.x=o*Math.cos(a),t.y=o*Math.sin(a),t.x=t.x*this.a+this.x0,t.y=t.y*this.a+this.y0,s.x=t.x,s.y=t.y,s}function Grt(s){var t={lam:0,phi:0},e,i,n,r,o,a,l,h,c,u={value:0};if(s.x=(s.x-this.x0)/this.a,s.y=(s.y-this.y0)/this.a,i=Math.atan(Math.sqrt(s.x*s.x+s.y*s.y)),e=Math.atan2(s.y,s.x),s.x>=0&&s.x>=Math.abs(s.y)?u.value=xe.AREA_0:s.y>=0&&s.y>=Math.abs(s.x)?(u.value=xe.AREA_1,e-=K):s.x<0&&-s.x>=Math.abs(s.y)?(u.value=xe.AREA_2,e=e<0?e+es:e-es):(u.value=xe.AREA_3,e+=K),c=es/12*Math.tan(e),o=Math.sin(c)/(Math.cos(c)-1/Math.sqrt(2)),a=Math.atan(o),n=Math.cos(e),r=Math.tan(i),l=1-n*n*r*r*(1-Math.cos(Math.atan(1/Math.cos(a)))),l<-1?l=-1:l>1&&(l=1),this.face===Ue.TOP)h=Math.acos(l),t.phi=K-h,u.value===xe.AREA_0?t.lam=a+K:u.value===xe.AREA_1?t.lam=a<0?a+es:a-es:u.value===xe.AREA_2?t.lam=a-K:t.lam=a;else if(this.face===Ue.BOTTOM)h=Math.acos(l),t.phi=h-K,u.value===xe.AREA_0?t.lam=-a+K:u.value===xe.AREA_1?t.lam=-a:u.value===xe.AREA_2?t.lam=-a-K:t.lam=a<0?-a-es:-a+es;else{var d,g,f;d=l,c=d*d,c>=1?f=0:f=Math.sqrt(1-c)*Math.sin(a),c+=f*f,c>=1?g=0:g=Math.sqrt(1-c),u.value===xe.AREA_1?(c=g,g=-f,f=c):u.value===xe.AREA_2?(g=-g,f=-f):u.value===xe.AREA_3&&(c=g,g=f,f=-c),this.face===Ue.RIGHT?(c=d,d=-g,g=c):this.face===Ue.BACK?(d=-d,g=-g):this.face===Ue.LEFT&&(c=d,d=g,g=-c),t.phi=Math.acos(-f)-K,t.lam=Math.atan2(g,d),this.face===Ue.RIGHT?t.lam=kh(t.lam,-K):this.face===Ue.BACK?t.lam=kh(t.lam,-es):this.face===Ue.LEFT&&(t.lam=kh(t.lam,+K))}if(this.es!==0){var p,m,_;p=t.phi<0?1:0,m=Math.tan(t.phi),_=this.b/Math.sqrt(m*m+this.one_minus_f_squared),t.phi=Math.atan(Math.sqrt(this.a*this.a-_*_)/(this.one_minus_f*_)),p&&(t.phi=-t.phi)}return t.lam+=this.long0,s.x=t.lam,s.y=t.phi,s}function If(s,t,e,i){var n;return sye&&n<=K+ye?(i.value=xe.AREA_1,n-=K):n>K+ye||n<=-(K+ye)?(i.value=xe.AREA_2,n=n>=0?n-es:n+es):(i.value=xe.AREA_3,n+=K)),n}function kh(s,t){var e=s+t;return e<-es?e+=zd:e>+es&&(e-=zd),e}var jrt=["Quadrilateralized Spherical Cube","Quadrilateralized_Spherical_Cube","qsc"];const zrt={init:krt,forward:$rt,inverse:Grt,names:jrt};var Ey=[[1,22199e-21,-715515e-10,31103e-10],[.9986,-482243e-9,-24897e-9,-13309e-10],[.9954,-83103e-8,-448605e-10,-986701e-12],[.99,-.00135364,-59661e-9,36777e-10],[.9822,-.00167442,-449547e-11,-572411e-11],[.973,-.00214868,-903571e-10,18736e-12],[.96,-.00305085,-900761e-10,164917e-11],[.9427,-.00382792,-653386e-10,-26154e-10],[.9216,-.00467746,-10457e-8,481243e-11],[.8962,-.00536223,-323831e-10,-543432e-11],[.8679,-.00609363,-113898e-9,332484e-11],[.835,-.00698325,-640253e-10,934959e-12],[.7986,-.00755338,-500009e-10,935324e-12],[.7597,-.00798324,-35971e-9,-227626e-11],[.7186,-.00851367,-701149e-10,-86303e-10],[.6732,-.00986209,-199569e-9,191974e-10],[.6213,-.010418,883923e-10,624051e-11],[.5722,-.00906601,182e-6,624051e-11],[.5322,-.00677797,275608e-9,624051e-11]],Iu=[[-520417e-23,.0124,121431e-23,-845284e-16],[.062,.0124,-126793e-14,422642e-15],[.124,.0124,507171e-14,-160604e-14],[.186,.0123999,-190189e-13,600152e-14],[.248,.0124002,710039e-13,-224e-10],[.31,.0123992,-264997e-12,835986e-13],[.372,.0124029,988983e-12,-311994e-12],[.434,.0123893,-369093e-11,-435621e-12],[.4958,.0123198,-102252e-10,-345523e-12],[.5571,.0121916,-154081e-10,-582288e-12],[.6176,.0119938,-241424e-10,-525327e-12],[.6769,.011713,-320223e-10,-516405e-12],[.7346,.0113541,-397684e-10,-609052e-12],[.7903,.0109107,-489042e-10,-104739e-11],[.8435,.0103431,-64615e-9,-140374e-14],[.8936,.00969686,-64636e-9,-8547e-9],[.9394,.00840947,-192841e-9,-42106e-10],[.9761,.00616527,-256e-6,-42106e-10],[1,.00328947,-319159e-9,-42106e-10]],nO=.8487,rO=1.3523,oO=ur/5,Urt=1/oO,wh=18,nm=function(s,t){return s[0]+t*(s[1]+t*(s[2]+t*s[3]))},Brt=function(s,t){return s[1]+t*(2*s[2]+t*3*s[3])};function Wrt(s,t,e,i){for(var n=t;i;--i){var r=s(n);if(n-=r,Math.abs(r)=wh&&(i=wh-1),e=ur*(e-Urt*i);var n={x:nm(Ey[i],e)*t,y:nm(Iu[i],e)};return s.y<0&&(n.y=-n.y),n.x=n.x*this.a*nO+this.x0,n.y=n.y*this.a*rO+this.y0,n}function Yrt(s){var t={x:(s.x-this.x0)/(this.a*nO),y:Math.abs(s.y-this.y0)/(this.a*rO)};if(t.y>=1)t.x/=Ey[wh][0],t.y=s.y<0?-K:K;else{var e=Math.floor(t.y*wh);for(e<0?e=0:e>=wh&&(e=wh-1);;)if(Iu[e][0]>t.y)--e;else if(Iu[e+1][0]<=t.y)++e;else break;var i=Iu[e],n=5*(t.y-i[0])/(Iu[e+1][0]-i[0]);n=Wrt(function(r){return(nm(i,r)-t.y)/Brt(i,r)},n,tt,100),t.x/=nm(Ey[e],n),t.y=(5*e+n)*Ls,s.y<0&&(t.y=-t.y)}return t.x=rt(t.x+this.long0),t}var qrt=["Robinson","robin"];const Zrt={init:Xrt,forward:Vrt,inverse:Yrt,names:qrt};function Hrt(){this.name="geocent"}function Krt(s){var t=XL(s,this.es,this.a);return t}function Jrt(s){var t=VL(s,this.es,this.a,this.b);return t}var Qrt=["Geocentric","geocentric","geocent","Geocent"];const tot={init:Hrt,forward:Krt,inverse:Jrt,names:Qrt};var Bs={N_POLE:0,S_POLE:1,EQUIT:2,OBLIQ:3},lu={h:{def:1e5,num:!0},azi:{def:0,num:!0,degrees:!0},tilt:{def:0,num:!0,degrees:!0},long0:{def:0,num:!0},lat0:{def:0,num:!0}};function eot(){if(Object.keys(lu).forEach(function(e){if(typeof this[e]>"u")this[e]=lu[e].def;else{if(lu[e].num&&isNaN(this[e]))throw new Error("Invalid parameter value, must be numeric "+e+" = "+this[e]);lu[e].num&&(this[e]=parseFloat(this[e]))}lu[e].degrees&&(this[e]=this[e]*Ls)}.bind(this)),Math.abs(Math.abs(this.lat0)-K)1e10)throw new Error("Invalid height");this.p=1+this.pn1,this.rp=1/this.p,this.h1=1/this.pn1,this.pfact=(this.p+1)*this.h1,this.es=0;var s=this.tilt,t=this.azi;this.cg=Math.cos(t),this.sg=Math.sin(t),this.cw=Math.cos(s),this.sw=Math.sin(s)}function sot(s){s.x-=this.long0;var t=Math.sin(s.y),e=Math.cos(s.y),i=Math.cos(s.x),n,r;switch(this.mode){case Bs.OBLIQ:r=this.sinph0*t+this.cosph0*e*i;break;case Bs.EQUIT:r=e*i;break;case Bs.S_POLE:r=-t;break;case Bs.N_POLE:r=t;break}switch(r=this.pn1/(this.p-r),n=r*e*Math.sin(s.x),this.mode){case Bs.OBLIQ:r*=this.cosph0*t-this.sinph0*e*i;break;case Bs.EQUIT:r*=t;break;case Bs.N_POLE:r*=-(e*i);break;case Bs.S_POLE:r*=e*i;break}var o,a;return o=r*this.cg+n*this.sg,a=1/(o*this.sw*this.h1+this.cw),n=(n*this.cg-r*this.sg)*this.cw*a,r=o*a,s.x=n*this.a,s.y=r*this.a,s}function iot(s){s.x/=this.a,s.y/=this.a;var t={x:s.x,y:s.y},e,i,n;n=1/(this.pn1-s.y*this.sw),e=this.pn1*s.x*n,i=this.pn1*s.y*this.cw*n,s.x=e*this.cg+i*this.sg,s.y=i*this.cg-e*this.sg;var r=on(s.x,s.y);if(Math.abs(r)1e10)throw new Error;if(this.radius_g=1+this.radius_g_1,this.C=this.radius_g*this.radius_g-1,this.es!==0){var s=1-this.es,t=1/s;this.radius_p=Math.sqrt(s),this.radius_p2=s,this.radius_p_inv2=t,this.shape="ellipse"}else this.radius_p=1,this.radius_p2=1,this.radius_p_inv2=1,this.shape="sphere";this.title||(this.title="Geostationary Satellite View")}function aot(s){var t=s.x,e=s.y,i,n,r,o;if(t=t-this.long0,this.shape==="ellipse"){e=Math.atan(this.radius_p2*Math.tan(e));var a=this.radius_p/on(this.radius_p*Math.cos(e),Math.sin(e));if(n=a*Math.cos(t)*Math.cos(e),r=a*Math.sin(t)*Math.cos(e),o=a*Math.sin(e),(this.radius_g-n)*n-r*r-o*o*this.radius_p_inv2<0)return s.x=Number.NaN,s.y=Number.NaN,s;i=this.radius_g-n,this.flip_axis?(s.x=this.radius_g_1*Math.atan(r/on(o,i)),s.y=this.radius_g_1*Math.atan(o/i)):(s.x=this.radius_g_1*Math.atan(r/i),s.y=this.radius_g_1*Math.atan(o/on(r,i)))}else this.shape==="sphere"&&(i=Math.cos(e),n=Math.cos(t)*i,r=Math.sin(t)*i,o=Math.sin(e),i=this.radius_g-n,this.flip_axis?(s.x=this.radius_g_1*Math.atan(r/on(o,i)),s.y=this.radius_g_1*Math.atan(o/i)):(s.x=this.radius_g_1*Math.atan(r/i),s.y=this.radius_g_1*Math.atan(o/on(r,i))));return s.x=s.x*this.a,s.y=s.y*this.a,s}function lot(s){var t=-1,e=0,i=0,n,r,o,a;if(s.x=s.x/this.a,s.y=s.y/this.a,this.shape==="ellipse"){this.flip_axis?(i=Math.tan(s.y/this.radius_g_1),e=Math.tan(s.x/this.radius_g_1)*on(1,i)):(e=Math.tan(s.x/this.radius_g_1),i=Math.tan(s.y/this.radius_g_1)*on(1,e));var l=i/this.radius_p;if(n=e*e+l*l+t*t,r=2*this.radius_g*t,o=r*r-4*n*this.C,o<0)return s.x=Number.NaN,s.y=Number.NaN,s;a=(-r-Math.sqrt(o))/(2*n),t=this.radius_g+a*t,e*=a,i*=a,s.x=Math.atan2(e,t),s.y=Math.atan(i*Math.cos(s.x)/t),s.y=Math.atan(this.radius_p_inv2*Math.tan(s.y))}else if(this.shape==="sphere"){if(this.flip_axis?(i=Math.tan(s.y/this.radius_g_1),e=Math.tan(s.x/this.radius_g_1)*Math.sqrt(1+i*i)):(e=Math.tan(s.x/this.radius_g_1),i=Math.tan(s.y/this.radius_g_1)*Math.sqrt(1+e*e)),n=e*e+i*i+t*t,r=2*this.radius_g*t,o=r*r-4*n*this.C,o<0)return s.x=Number.NaN,s.y=Number.NaN,s;a=(-r-Math.sqrt(o))/(2*n),t=this.radius_g+a*t,e*=a,i*=a,s.x=Math.atan2(e,t),s.y=Math.atan(i*Math.cos(s.x)/t)}return s.x=s.x+this.long0,s}var hot=["Geostationary Satellite View","Geostationary_Satellite","geos"];const cot={init:oot,forward:aot,inverse:lot,names:hot};var Qu=1.340264,td=-.081106,ed=893e-6,sd=.003796,rm=Math.sqrt(3)/2;function uot(){this.es=0,this.long0=this.long0!==void 0?this.long0:0}function dot(s){var t=rt(s.x-this.long0),e=s.y,i=Math.asin(rm*Math.sin(e)),n=i*i,r=n*n*n;return s.x=t*Math.cos(i)/(rm*(Qu+3*td*n+r*(7*ed+9*sd*n))),s.y=i*(Qu+td*n+r*(ed+sd*n)),s.x=this.a*s.x+this.x0,s.y=this.a*s.y+this.y0,s}function got(s){s.x=(s.x-this.x0)/this.a,s.y=(s.y-this.y0)/this.a;var t=1e-9,e=12,i=s.y,n,r,o,a,l,h;for(h=0;h>=1;return e.join("")}const yot='Terms of Use';class xot extends Sn{constructor(t){const e=t.hidpi!==void 0?t.hidpi:!1;super({cacheSize:t.cacheSize,crossOrigin:"anonymous",interpolate:t.interpolate,projection:st("EPSG:3857"),reprojectionErrorThreshold:t.reprojectionErrorThreshold,state:"loading",tileLoadFunction:t.tileLoadFunction,tilePixelRatio:e?2:1,wrapX:t.wrapX!==void 0?t.wrapX:!0,transition:t.transition,zDirection:t.zDirection}),this.hidpi_=e,this.culture_=t.culture!==void 0?t.culture:"en-us",this.maxZoom_=t.maxZoom!==void 0?t.maxZoom:-1,this.apiKey_=t.key,this.imagerySet_=t.imagerySet,this.placeholderTiles_=t.placeholderTiles;const i="https://dev.virtualearth.net/REST/v1/Imagery/Metadata/"+this.imagerySet_+"?uriScheme=https&include=ImageryProviders&key="+this.apiKey_+"&c="+this.culture_;fetch(i).then(n=>n.json()).then(n=>this.handleImageryMetadataResponse(n))}getApiKey(){return this.apiKey_}getImagerySet(){return this.imagerySet_}handleImageryMetadataResponse(t){if(t.statusCode!=200||t.statusDescription!="OK"||t.authenticationResultCode!="ValidCredentials"||t.resourceSets.length!=1||t.resourceSets[0].resources.length!=1){this.setState("error");return}const e=t.resourceSets[0].resources[0],i=this.maxZoom_==-1?e.zoomMax:this.maxZoom_,n=this.getProjection(),r=yo(n),o=this.hidpi_?2:1,a=e.imageWidth==e.imageHeight?e.imageWidth/o:[e.imageWidth/o,e.imageHeight/o],l=Cl({extent:r,minZoom:e.zoomMin,maxZoom:i,tileSize:a});this.tileGrid=l;const h=this.culture_,c=this.hidpi_,u=this.placeholderTiles_;if(this.tileUrlFunction=fc(e.imageUrlSubdomains.map(function(d){const g=[0,0,0],f=e.imageUrl.replace("{subdomain}",d).replace("{culture}",h);return function(p,m,_){if(!p)return;ll(p[0],p[1],p[2],g);const y=new URL(f.replace("{quadkey}",_ot(g))),v=y.searchParams;return c&&(v.set("dpi","d1"),v.set("device","mobile")),u===!0?v.delete("n"):u===!1&&v.set("n","z"),y.toString()}})),e.imageryProviders){const d=Sl(st("EPSG:4326"),this.getProjection());this.setAttributions(g=>{const f=[],p=g.viewState,m=this.getTileGrid(),_=m.getZForResolution(p.resolution,this.zDirection),y=m.getTileCoordForCoordAndZ(p.center,_)[0];return e.imageryProviders.map(function(v){let S=!1;const w=v.coverageAreas;for(let C=0,M=w.length;C=T.zoomMin&&y<=T.zoomMax){const I=T.bbox,O=[I[1],I[0],I[3],I[2]],P=nc(O,d);if(Ce(P,g.extent)){S=!0;break}}}S&&f.push(v.attribution)}),f.push(yot),f})}this.setState("ready")}}const vot=xot;class wot extends hl{constructor(t){super({attributions:t.attributions,cacheSize:t.cacheSize,crossOrigin:t.crossOrigin,maxZoom:t.maxZoom!==void 0?t.maxZoom:18,minZoom:t.minZoom,projection:t.projection,transition:t.transition,wrapX:t.wrapX,zDirection:t.zDirection}),this.account_=t.account,this.mapId_=t.map||"",this.config_=t.config||{},this.templateCache_={},this.initializeMap_()}getConfig(){return this.config_}updateConfig(t){Object.assign(this.config_,t),this.initializeMap_()}setConfig(t){this.config_=t||{},this.initializeMap_()}initializeMap_(){const t=JSON.stringify(this.config_);if(this.templateCache_[t]){this.applyTemplate_(this.templateCache_[t]);return}let e="https://"+this.account_+".carto.com/api/v1/map";this.mapId_&&(e+="/named/"+this.mapId_);const i=new XMLHttpRequest;i.addEventListener("load",this.handleInitResponse_.bind(this,t)),i.addEventListener("error",this.handleInitError_.bind(this)),i.open("POST",e),i.setRequestHeader("Content-type","application/json"),i.send(JSON.stringify(this.config_))}handleInitResponse_(t,e){const i=e.target;if(!i.status||i.status>=200&&i.status<300){let n;try{n=JSON.parse(i.responseText)}catch{this.setState("error");return}this.applyTemplate_(n),this.templateCache_[t]=n,this.setState("ready")}else this.setState("error")}handleInitError_(t){this.setState("error")}applyTemplate_(t){const e="https://"+t.cdn_url.https+"/"+this.account_+"/api/v1/map/"+t.layergroupid+"/{z}/{x}/{y}.png";this.setUrl(e)}}const Eot=wot;class Sot extends s0{constructor(t){t=t||{},super({attributions:t.attributions,wrapX:t.wrapX}),this.resolution=void 0,this.distance=t.distance!==void 0?t.distance:20,this.minDistance=t.minDistance||0,this.interpolationRatio=0,this.features=[],this.geometryFunction=t.geometryFunction||function(e){const i=e.getGeometry();return qt(!i||i.getType()==="Point","The default `geometryFunction` can only handle `Point` or null geometries"),i},this.createCustomCluster_=t.createCluster,this.source=null,this.boundRefresh_=this.refresh.bind(this),this.updateDistance(this.distance,this.minDistance),this.setSource(t.source||null)}clear(t){this.features.length=0,super.clear(t)}getDistance(){return this.distance}getSource(){return this.source}loadFeatures(t,e,i){var n;(n=this.source)==null||n.loadFeatures(t,e,i),e!==this.resolution&&(this.resolution=e,this.refresh())}setDistance(t){this.updateDistance(t,this.minDistance)}setMinDistance(t){this.updateDistance(this.distance,t)}getMinDistance(){return this.minDistance}setSource(t){this.source&&this.source.removeEventListener(Zt.CHANGE,this.boundRefresh_),this.source=t,t&&t.addEventListener(Zt.CHANGE,this.boundRefresh_),this.refresh()}refresh(){this.clear(),this.cluster(),this.addFeatures(this.features)}updateDistance(t,e){const i=t===0?0:Math.min(e,t)/t,n=t!==this.distance||this.interpolationRatio!==i;this.distance=t,this.minDistance=e,this.interpolationRatio=i,n&&this.refresh()}cluster(){if(this.resolution===void 0||!this.source)return;const t=Zs(),e=this.distance*this.resolution,i=this.source.getFeatures(),n={};for(let r=0,o=i.length;r=0;--a){const l=this.geometryFunction(t[a]);l?mI(i,l.getCoordinates()):t.splice(a,1)}M9(i,1/t.length);const n=Rs(e),r=this.interpolationRatio,o=new Cs([i[0]*(1-r)+n[0]*r,i[1]*(1-r)+n[1]*r]);return this.createCustomCluster_?this.createCustomCluster_(o,t):new ys({geometry:o,features:t})}}const Mot=Sot,bot="https://tile.googleapis.com/v1/createSession",Cot="https://tile.googleapis.com/v1/2dtiles",Tot="https://tile.googleapis.com/tile/v1/viewport",Rot=22;class Iot extends Sn{constructor(t){const e=!!t.highDpi;super({attributionsCollapsible:t.attributionsCollapsible,cacheSize:t.cacheSize,crossOrigin:"anonymous",interpolate:t.interpolate,projection:"EPSG:3857",reprojectionErrorThreshold:t.reprojectionErrorThreshold,state:"loading",tileLoadFunction:t.tileLoadFunction,tilePixelRatio:e?2:1,wrapX:t.wrapX!==void 0?t.wrapX:!0,transition:t.transition,zDirection:t.zDirection}),this.apiKey_=t.key,this.error_=null;const i={mapType:t.mapType||"roadmap",language:t.language||"en-US",region:t.region||"US"};t.imageFormat&&(i.imageFormat=t.imageFormat),t.scale&&(i.scale=t.scale),e&&(i.highDpi=!0),t.layerTypes&&(i.layerTypes=t.layerTypes),t.styles&&(i.styles=t.styles),t.overlay===!0&&(i.overlay=!0),t.apiOptions&&(i.apiOptions=t.apiOptions),this.sessionTokenRequest_=i,this.sessionTokenValue_,this.sessionRefreshId_,this.previousViewportAttribution_,this.previousViewportExtent_,this.createSession_()}getError(){return this.error_}fetchSessionToken(t,e){return fetch(t,e)}async createSession_(){const t=bot+"?key="+this.apiKey_,e={method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify(this.sessionTokenRequest_)},i=await this.fetchSessionToken(t,e);if(!i.ok){try{const u=await i.json();this.error_=new Error(u.error.message)}catch{this.error_=new Error("Error fetching session token")}this.setState("error");return}const n=await i.json(),r=this.getTilePixelRatio(1),o=[n.tileWidth/r,n.tileHeight/r];this.tileGrid=Cl({extent:yo(this.getProjection()),maxZoom:Rot,tileSize:o});const a=n.session;this.sessionTokenValue_=a;const l=this.apiKey_;this.tileUrlFunction=function(u,d,g){const f=u[0],p=u[1],m=u[2];return`${Cot}/${f}/${p}/${m}?session=${a}&key=${l}`};const h=parseInt(n.expiry,10)*1e3,c=Math.max(h-Date.now()-60*1e3,1);this.sessionRefreshId_=setTimeout(()=>this.createSession_(),c),this.setAttributions(this.fetchAttributions_.bind(this)),this.setState("ready")}async fetchAttributions_(t){if(t.viewHints[Ie.ANIMATING]||t.viewHints[Ie.INTERACTING]||t.animate)return this.previousViewportAttribution_;const[e,i]=h2(_g(t.extent),t.viewState.projection),[n,r]=h2(yg(t.extent),t.viewState.projection),o=`zoom=${this.getTileGrid().getZForResolution(t.viewState.resolution,this.zDirection)}&north=${r}&south=${i}&east=${n}&west=${e}`;if(this.previousViewportExtent_==o)return this.previousViewportAttribution_;this.previousViewportExtent_=o;const a=this.sessionTokenValue_,l=this.apiKey_,h=`${Tot}?session=${a}&key=${l}&${o}`;return this.previousViewportAttribution_=await fetch(h).then(c=>c.json()).then(c=>c.copyright),this.previousViewportAttribution_}disposeInternal(){clearTimeout(this.sessionRefreshId_),super.disposeInternal()}}const Pot=Iot;let aO=class extends Lg{constructor(s,t,e,i,n,r,o){super(t,e,i,n,r,o),this.zoomifyImage_=null,this.tileSize_=s}getImage(){if(this.zoomifyImage_)return this.zoomifyImage_;const s=super.getImage();if(this.state==X.LOADED){const t=this.tileSize_;if(s.width==t[0]&&s.height==t[1])return this.zoomifyImage_=s,s;const e=Se(t[0],t[1]);return e.drawImage(s,0,0),this.zoomifyImage_=e.canvas,e.canvas}return s}};class Aot extends Sn{constructor(t){const e=t.size,i=t.tierSizeCalculation!==void 0?t.tierSizeCalculation:"default",n=t.tilePixelRatio||1,r=e[0],o=e[1],a=[],l=t.tileSize||cc;let h=l*n;switch(i){case"default":for(;r>h||o>h;)a.push([Math.ceil(r/h),Math.ceil(o/h)]),h+=h;break;case"truncated":let C=r,M=o;for(;C>h||M>h;)a.push([Math.ceil(C/h),Math.ceil(M/h)]),C>>=1,M>>=1;break;default:throw new Error("Unknown `tierSizeCalculation` configured")}a.push([1,1]),a.reverse();const c=[n],u=[0];for(let C=1,M=a.length;C{p=l,this.changed()}),w.src=S}}const Lot=Aot;function hu(s){return s.toLocaleString("en",{maximumFractionDigits:10})}class Oot extends Sn{constructor(t){const e=t||{};let i=e.url||"";i=i+(i.lastIndexOf("/")===i.length-1||i===""?"":"/");const n=e.version||os.VERSION2,r=e.sizes||[],o=e.size;qt(o!=null&&Array.isArray(o)&&o.length==2&&!isNaN(o[0])&&o[0]>0&&!isNaN(o[1])&&o[1]>0,"Missing or invalid `size`");const a=o[0],l=o[1],h=e.tileSize,c=e.tilePixelRatio||1,u=e.format||"jpg",d=e.quality||(e.version==os.VERSION1?"native":"default");let g=e.resolutions||[];const f=e.supports||[],p=e.extent||[0,-l,a,0],m=r!=null&&Array.isArray(r)&&r.length>0,_=h!==void 0&&(typeof h=="number"&&Number.isInteger(h)&&h>0||Array.isArray(h)&&h.length>0),y=f!=null&&Array.isArray(f)&&(f.includes("regionByPx")||f.includes("regionByPct"))&&(f.includes("sizeByWh")||f.includes("sizeByH")||f.includes("sizeByW")||f.includes("sizeByPct"));let v,S,w;if(g.sort(function(I,O){return O-I}),_||y)if(h!=null&&(typeof h=="number"&&Number.isInteger(h)&&h>0?(v=h,S=h):Array.isArray(h)&&h.length>0&&((h.length==1||h[1]==null&&Number.isInteger(h[0]))&&(v=h[0],S=h[0]),h.length==2&&(Number.isInteger(h[0])&&Number.isInteger(h[1])?(v=h[0],S=h[1]):h[0]==null&&Number.isInteger(h[1])&&(v=h[1],S=h[1])))),(v===void 0||S===void 0)&&(v=cc,S=cc),g.length==0){w=Math.max(Math.ceil(Math.log(a/v)/Math.LN2),Math.ceil(Math.log(l/S)/Math.LN2));for(let I=w;I>=0;I--)g.push(Math.pow(2,I))}else{const I=Math.max(...g);w=Math.round(Math.log(I)/Math.LN2)}else if(v=a,S=l,g=[],m){r.sort(function(O,P){return O[0]-P[0]}),w=-1;const I=[];for(let O=0;O0&&g[g.length-1]==P){I.push(O);continue}g.push(P),w++}if(I.length>0)for(let O=0;Ow)return;const b=I[1],R=I[2],A=g[E];if(!(b===void 0||R===void 0||A===void 0||b<0||Math.ceil(a/A/v)<=b||R<0||Math.ceil(l/A/S)<=R)){if(y||_){const $=b*v*A,G=R*S*A;let k=v*A,z=S*A,V=v,et=S;if($+k>a&&(k=a-$),G+z>l&&(z=l-G),$+v*A>a&&(V=Math.floor((a-$+A-1)/A)),G+S*A>l&&(et=Math.floor((l-G+A-1)/A)),$==0&&k==a&&G==0&&z==l)D="full";else if(!y||f.includes("regionByPx"))D=$+","+G+","+k+","+z;else if(f.includes("regionByPct")){const F=hu($/a*100),ot=hu(G/l*100),ht=hu(k/a*100),pt=hu(z/l*100);D="pct:"+F+","+ot+","+ht+","+pt}n==os.VERSION3&&(!y||f.includes("sizeByWh"))?x=V+","+et:!y||f.includes("sizeByW")?x=V+",":f.includes("sizeByH")?x=","+et:f.includes("sizeByWh")?x=V+","+et:f.includes("sizeByPct")&&(x="pct:"+hu(100/A))}else if(D="full",m){const $=r[E][0],G=r[E][1];n==os.VERSION3?$==a&&G==l?x="max":x=$+","+G:$==a?x="full":x=$+","}else x=n==os.VERSION3?"max":"full";return i+D+"/"+x+"/0/"+d+"."+u}},T=aO.bind(null,Re(h||256).map(function(I){return I*c}));super({attributions:e.attributions,attributionsCollapsible:e.attributionsCollapsible,cacheSize:e.cacheSize,crossOrigin:e.crossOrigin,interpolate:e.interpolate,projection:e.projection,reprojectionErrorThreshold:e.reprojectionErrorThreshold,state:e.state,tileClass:T,tileGrid:C,tilePixelRatio:e.tilePixelRatio,tileUrlFunction:M,transition:e.transition}),this.zDirection=e.zDirection}}const Fot=Oot;function lO(s,t,e,i,n,r){const o=n.getCode().split(/:(?=\d+$)/).pop(),a=e/i,l=[Mp(Rt(t)/a,cr),Mp(Ee(t)/a,cr)];r.SIZE=l[0]+","+l[1],r.BBOX=t.join(","),r.BBOXSR=o,r.IMAGESR=o,r.DPI=Math.round(r.DPI?r.DPI*i:90*i);const h=s.replace(/MapServer\/?$/,"MapServer/export").replace(/ImageServer\/?$/,"ImageServer/exportImage");return oo(h,r)}function hO(s){const t=s.load?s.load:pa,e=st(s.projection||"EPSG:3857"),i=s.ratio??1.5,n=s.crossOrigin??null;return function(r,o,a){a=s.hidpi?a:1;const l={F:"image",FORMAT:"PNG32",TRANSPARENT:!0};Object.assign(l,s.params),r=m0(r,o,a,i);const h=lO(s.url,r,o,a,e,l),c=new Image;return c.crossOrigin=n,t(c,h).then(u=>{const d=Rt(r)/u.width*a;return{image:u,extent:r,resolution:d,pixelRatio:a}})}}class Not extends ya{constructor(t){t=t||{},super({attributions:t.attributions,interpolate:t.interpolate,projection:t.projection,resolutions:t.resolutions}),this.crossOrigin_=t.crossOrigin!==void 0?t.crossOrigin:null,this.hidpi_=t.hidpi!==void 0?t.hidpi:!0,this.url_=t.url,this.imageLoadFunction_=t.imageLoadFunction!==void 0?t.imageLoadFunction:p0,this.params_=Object.assign({},t.params),this.imageSize_=[0,0],this.renderedRevision_=0,this.ratio_=t.ratio!==void 0?t.ratio:1.5,this.loaderProjection_=null}getParams(){return this.params_}getImageInternal(t,e,i,n){return this.url_===void 0?null:((!this.loader||this.loaderProjection_!==n)&&(this.loaderProjection_=n,this.loader=hO({crossOrigin:this.crossOrigin_,params:this.params_,projection:n,hidpi:this.hidpi_,url:this.url_,ratio:this.ratio_,load:(r,o)=>(this.image.setImage(r),this.imageLoadFunction_(this.image,o),pa(r))})),super.getImageInternal(t,e,i,n))}getImageLoadFunction(){return this.imageLoadFunction_}getUrl(){return this.url_}setImageLoadFunction(t){this.imageLoadFunction_=t,this.changed()}setUrl(t){t!=this.url_&&(this.url_=t,this.loader=null,this.changed())}updateParams(t){Object.assign(this.params_,t),this.changed()}changed(){this.image=null,super.changed()}}const Dot=Not;class kot extends ya{constructor(t){t=t||{},super({attributions:t.attributions,interpolate:t.interpolate,projection:t.projection,resolutions:t.resolutions,state:t.state}),this.canvasFunction_=t.canvasFunction,this.canvas_=null,this.renderedRevision_=0,this.ratio_=t.ratio!==void 0?t.ratio:1.5}getImageInternal(t,e,i,n){e=this.findNearestResolution(e);let r=this.canvas_;if(r&&this.renderedRevision_==this.getRevision()&&r.getResolution()==e&&r.getPixelRatio()==i&&ai(r.getExtent(),t))return r;t=t.slice(),gI(t,this.ratio_);const o=Rt(t)/e,a=Ee(t)/e,l=[o*i,a*i],h=this.canvasFunction_.call(this,t,e,i,l,n);return h&&(r=new sw(t,e,i,h)),this.canvas_=r,this.renderedRevision_=this.getRevision(),r}}const $ot=kot;function Got(s,t,e,i){const n=Rt(s),r=Ee(s),o=t[0],a=t[1],l=.0254/i;return a*n>o*r?n*e/(o*l):r*e/(a*l)}function jot(s,t,e,i,n,r,o){const a=Got(e,i,r,o),l=Rs(e),h={OPERATION:n?"GETDYNAMICMAPOVERLAYIMAGE":"GETMAPIMAGE",VERSION:"2.0.0",LOCALE:"en",CLIENTAGENT:"ol/source/ImageMapGuide source",CLIP:"1",SETDISPLAYDPI:o,SETDISPLAYWIDTH:Math.round(i[0]),SETDISPLAYHEIGHT:Math.round(i[1]),SETVIEWSCALE:a,SETVIEWCENTERX:l[0],SETVIEWCENTERY:l[1]};return Object.assign(h,t),oo(s,h)}function cO(s){const t=s.load||pa,e=s.useOverlay??!1,i=s.metersPerUnit||1,n=s.displayDpi||96,r=s.ratio??1,o=s.crossOrigin??null;return function(a,l,h){const c=new Image;c.crossOrigin=o,a=m0(a,l,h,r);const u=Rt(a)/l,d=Ee(a)/l,g=[u*h,d*h],f=jot(s.url,s.params,a,g,e,i,n);return t(c,f).then(p=>({image:p,extent:a,pixelRatio:h}))}}class zot extends ya{constructor(t){super({interpolate:t.interpolate,projection:t.projection,resolutions:t.resolutions}),this.crossOrigin_=t.crossOrigin!==void 0?t.crossOrigin:null,this.displayDpi_=t.displayDpi!==void 0?t.displayDpi:96,this.params_=Object.assign({},t.params),this.url_=t.url,this.imageLoadFunction_=t.imageLoadFunction!==void 0?t.imageLoadFunction:p0,this.hidpi_=t.hidpi!==void 0?t.hidpi:!0,this.metersPerUnit_=t.metersPerUnit!==void 0?t.metersPerUnit:1,this.ratio_=t.ratio!==void 0?t.ratio:1,this.useOverlay_=t.useOverlay!==void 0?t.useOverlay:!1,this.renderedRevision_=0,this.loaderProjection_=null}getParams(){return this.params_}getImageInternal(t,e,i,n){return this.url_===void 0?null:((!this.loader||this.loaderProjection_!==n)&&(this.loaderProjection_=n,this.loader=cO({crossOrigin:this.crossOrigin_,params:this.params_,hidpi:this.hidpi_,metersPerUnit:this.metersPerUnit_,url:this.url_,useOverlay:this.useOverlay_,ratio:this.ratio_,load:(r,o)=>(this.image.setImage(r),this.imageLoadFunction_(this.image,o),pa(r))})),super.getImageInternal(t,e,i,n))}getImageLoadFunction(){return this.imageLoadFunction_}updateParams(t){Object.assign(this.params_,t),this.changed()}setImageLoadFunction(t){this.imageLoadFunction_=t,this.changed()}changed(){this.image=null,super.changed()}}const Uot=zot,Bot=new Error("Image failed to load");function uO(s,t,e,i,n){return new Promise((r,o)=>{const a=new Image;a.crossOrigin=n.crossOrigin??null,a.addEventListener("load",()=>r(a)),a.addEventListener("error",()=>o(Bot)),a.src=cL(s,t,e,i,n.maxY)})}function bb(s){return function(t,e,i,n){const r=Xtt(s,t,e,i);return uO(r,t,e,i,n)}}function Wot(s){return function(t,e,i,n){const r=s(t,e,i,n);return uO(r,t,e,i,n)}}function Cb(s){let t;if(Array.isArray(s))t=bb(s);else if(typeof s=="string"){const e=_0(s);t=bb(e)}else if(typeof s=="function")t=Wot(s);else throw new Error("The url option must be a single template, an array of templates, or a function for getting a URL");return t}let Tb=0;function Rb(s){return Array.isArray(s)?s.join(` +`):typeof s=="string"?s:(++Tb,"url-function-key-"+Tb)}class Xot extends d0{constructor(t){t=t||{};let e=t.loader,i;t.url&&(e=Cb(t.url),i=Rb(t.url));const n=e?t.state:"loading",r=t.wrapX===void 0?!0:t.wrapX;super({loader:e,key:i,attributions:t.attributions,attributionsCollapsible:t.attributionsCollapsible,maxZoom:t.maxZoom,minZoom:t.minZoom,tileSize:t.tileSize,gutter:t.gutter,maxResolution:t.maxResolution,projection:t.projection,tileGrid:t.tileGrid,state:n,wrapX:r,transition:t.transition,interpolate:t.interpolate!==!1,crossOrigin:t.crossOrigin})}setUrl(t){const e=Cb(t);this.setLoader(e),this.setKey(Rb(t)),this.getState()!=="ready"&&this.setState("ready")}}const Vot=Xot;class Yot extends ya{constructor(t){t=t||{},super({attributions:t.attributions,interpolate:t.interpolate,projection:t.projection,resolutions:t.resolutions}),this.crossOrigin_=t.crossOrigin!==void 0?t.crossOrigin:null,this.url_=t.url,this.imageLoadFunction_=t.imageLoadFunction!==void 0?t.imageLoadFunction:p0,this.params_=Object.assign({},t.params),this.serverType_=t.serverType,this.hidpi_=t.hidpi!==void 0?t.hidpi:!0,this.renderedRevision_=0,this.ratio_=t.ratio!==void 0?t.ratio:1.5,this.loaderProjection_=null}getFeatureInfoUrl(t,e,i,n){const r=st(i),o=this.getProjection();o&&o!==r&&(e=$d(o,r,t,e),t=Dm(t,r,o));const a={url:this.url_,params:{...this.params_,...n},projection:o||r};return tet(a,t,e)}getLegendUrl(t,e){return eet({url:this.url_,params:{...this.params_,...e}},t)}getParams(){return this.params_}getImageInternal(t,e,i,n){return this.url_===void 0?null:((!this.loader||this.loaderProjection_!==n)&&(this.loaderProjection_=n,this.loader=mL({crossOrigin:this.crossOrigin_,params:this.params_,projection:n,serverType:this.serverType_,hidpi:this.hidpi_,url:this.url_,ratio:this.ratio_,load:(r,o)=>(this.image.setImage(r),this.imageLoadFunction_(this.image,o),pa(r))})),super.getImageInternal(t,e,i,n))}getImageLoadFunction(){return this.imageLoadFunction_}getUrl(){return this.url_}setImageLoadFunction(t){this.imageLoadFunction_=t,this.changed()}setUrl(t){t!=this.url_&&(this.url_=t,this.loader=null,this.changed())}updateParams(t){Object.assign(this.params_,t),this.changed()}changed(){this.image=null,super.changed()}}const qot=Yot,Zot={"image/png":!0,"image/jpeg":!0,"image/gif":!0,"image/webp":!0},Hot={"application/vnd.mapbox-vector-tile":!0,"application/geo+json":!0};function dO(s,t){if(!t.length)return s;const e=new URL(s,"file:/");if(e.pathname.split("/").includes("collections"))return Td('The "collections" query parameter cannot be added to collection endpoints'),s;const i=t.map(o=>encodeURIComponent(o)).join(",");e.searchParams.append("collections",i);const n=s.split("?")[0],r=decodeURIComponent(e.searchParams.toString());return`${n}?${r}`}function Kot(s,t,e){let i,n;for(let r=0;rw.replace(/E|X|Lon/i,"e").replace(/N|Y|Lat/i,"n")).join(""):n.getAxisOrientation()).startsWith("en"),a=t.tileMatrices,l={};for(let w=0;wx.maxTileCol||P.tileRowx.maxTileRow)return}Object.assign(P,y);const D=e.replace(/\{(\w+?)\}/g,function(x,E){return P[E]});return dL(v,D)}return{grid:_,urlTemplate:e,urlFunction:S}}function Qot(s,t){const e=t.tileMatrixSetLimits;let i;if(t.dataType==="map")i=Kot(t.links,s.mediaType,s.collections);else if(t.dataType==="vector")i=Jot(t.links,s.mediaType,s.supportedMediaTypes,s.collections);else throw new Error('Expected tileset data type to be "map" or "vector"');if(t.tileMatrixSet)return Ib(s,t.tileMatrixSet,i,e);const n=t.links.find(a=>a.rel==="http://www.opengis.net/def/rel/ogc/1.0/tiling-scheme");if(!n)throw new Error("Expected http://www.opengis.net/def/rel/ogc/1.0/tiling-scheme link or tileMatrixSet");const r=n.href,o=dL(s.url,r);return uL(o).then(function(a){return Ib(s,a,i,e)})}function gO(s){return uL(s.url).then(function(t){return Qot(s,t)})}class tat extends Sn{constructor(t){super({attributions:t.attributions,cacheSize:t.cacheSize,crossOrigin:t.crossOrigin,interpolate:t.interpolate,projection:t.projection,reprojectionErrorThreshold:t.reprojectionErrorThreshold,state:"loading",tileLoadFunction:t.tileLoadFunction,wrapX:t.wrapX!==void 0?t.wrapX:!0,transition:t.transition});const e={url:t.url,projection:this.getProjection(),mediaType:t.mediaType,context:t.context||null,collections:t.collections};gO(e).then(this.handleTileSetInfo_.bind(this)).catch(this.handleError_.bind(this))}handleTileSetInfo_(t){this.tileGrid=t.grid,this.setTileUrlFunction(t.urlFunction,t.urlTemplate),this.setState("ready")}handleError_(t){Td(t),this.setState("error")}}const eat=tat;class sat extends y0{constructor(t){super({attributions:t.attributions,attributionsCollapsible:t.attributionsCollapsible,cacheSize:t.cacheSize,format:t.format,overlaps:t.overlaps,projection:t.projection,tileClass:t.tileClass,transition:t.transition,wrapX:t.wrapX,zDirection:t.zDirection,state:"loading"});const e={url:t.url,projection:this.getProjection(),mediaType:t.mediaType,supportedMediaTypes:t.format.supportedMediaTypes,context:t.context||null,collections:t.collections};gO(e).then(this.handleTileSetInfo_.bind(this)).catch(this.handleError_.bind(this))}handleTileSetInfo_(t){this.tileGrid=t.grid,this.setTileUrlFunction(t.urlFunction,t.urlTemplate),this.setState("ready")}handleError_(t){Td(t),this.setState("error")}}const iat=sat,fO='© OpenStreetMap contributors.';class nat extends hl{constructor(t){t=t||{};let e;t.attributions!==void 0?e=t.attributions:e=[fO];const i=t.crossOrigin!==void 0?t.crossOrigin:"anonymous",n=t.url!==void 0?t.url:"https://tile.openstreetmap.org/{z}/{x}/{y}.png";super({attributions:e,attributionsCollapsible:!1,cacheSize:t.cacheSize,crossOrigin:i,interpolate:t.interpolate,maxZoom:t.maxZoom!==void 0?t.maxZoom:19,reprojectionErrorThreshold:t.reprojectionErrorThreshold,tileLoadFunction:t.tileLoadFunction,transition:t.transition,url:n,wrapX:t.wrapX,zDirection:t.zDirection})}}const rat=nat,Pb=1/0;class oat{constructor(t,e){this.priorityFunction_=t,this.keyFunction_=e,this.elements_=[],this.priorities_=[],this.queuedElements_={}}clear(){this.elements_.length=0,this.priorities_.length=0,Mc(this.queuedElements_)}dequeue(){const t=this.elements_,e=this.priorities_,i=t[0];t.length==1?(t.length=0,e.length=0):(t[0]=t.pop(),e[0]=e.pop(),this.siftUp_(0));const n=this.keyFunction_(i);return delete this.queuedElements_[n],i}enqueue(t){qt(!(this.keyFunction_(t)in this.queuedElements_),"Tried to enqueue an `element` that was already added to the queue");const e=this.priorityFunction_(t);return e!=Pb?(this.elements_.push(t),this.priorities_.push(e),this.queuedElements_[this.keyFunction_(t)]=!0,this.siftDown_(0,this.elements_.length-1),!0):!1}getCount(){return this.elements_.length}getLeftChildIndex_(t){return t*2+1}getRightChildIndex_(t){return t*2+2}getParentIndex_(t){return t-1>>1}heapify_(){let t;for(t=(this.elements_.length>>1)-1;t>=0;t--)this.siftUp_(t)}isEmpty(){return this.elements_.length===0}isKeyQueued(t){return t in this.queuedElements_}isQueued(t){return this.isKeyQueued(this.keyFunction_(t))}siftUp_(t){const e=this.elements_,i=this.priorities_,n=e.length,r=e[t],o=i[t],a=t;for(;t>1;){const l=this.getLeftChildIndex_(t),h=this.getRightChildIndex_(t),c=ht;){const a=this.getParentIndex_(e);if(n[a]>o)i[e]=i[a],n[e]=n[a],e=a;else break}i[e]=r,n[e]=o}reprioritize(){const t=this.priorityFunction_,e=this.elements_,i=this.priorities_;let n=0;const r=e.length;let o,a,l;for(a=0;a0;){const n=this.dequeue()[0],r=n.getKey();n.getState()===X.IDLE&&!(r in this.tilesLoadingKeys_)&&(this.tilesLoadingKeys_[r]=!0,++this.tilesLoading_,++i,n.load())}}}function pO(s){return function(t){const e=t.buffers,i=t.meta,n=t.imageOps,r=t.width,o=t.height,a=e.length,l=e[0].byteLength;if(n){const d=new Array(a);for(let g=0;g"u"?"data:text/javascript;base64,"+Buffer.from(e.join(` +`),"binary").toString("base64"):URL.createObjectURL(new Blob(e,{type:"text/javascript"})));return i.addEventListener("message",t),i}function hat(s,t){const e=pO(s.operation);let i=!1;return{postMessage:function(n){setTimeout(function(){i||t({data:{buffer:e(n),meta:n.meta}})},0)},terminate:function(){i=!0}}}class cat extends Ux{constructor(t){super(),this.imageOps_=!!t.imageOps;let e;t.threads===0?e=0:this.imageOps_?e=1:e=t.threads||1;const i=new Array(e);if(e)for(let n=0;nthis.maxQueueLength_;)this.queue_.shift().callback(null,null)}dispatch_(){if(this.running_||this.queue_.length===0)return;const t=this.queue_.shift();this.job_=t;const e=t.inputs[0].width,i=t.inputs[0].height,n=t.inputs.map(function(l){return l.data.buffer}),r=this.workers_.length;if(this.running_=r,r===1){this.workers_[0].postMessage({buffers:n,meta:t.meta,imageOps:this.imageOps_,width:e,height:i},n);return}const o=t.inputs[0].data.length,a=4*Math.ceil(o/4/r);for(let l=0;lStadia Maps',_at='© OpenMapTiles',yat='© Stamen Design',xat={stamen_terrain:{extension:"png"},stamen_terrain_background:{extension:"png"},stamen_terrain_labels:{extension:"png"},stamen_terrain_lines:{extension:"png"},stamen_toner_background:{extension:"png"},stamen_toner:{extension:"png"},stamen_toner_labels:{extension:"png"},stamen_toner_lines:{extension:"png"},stamen_toner_lite:{extension:"png"},stamen_watercolor:{extension:"jpg"},alidade_smooth:{extension:"png"},alidade_smooth_dark:{extension:"png"},alidade_satellite:{extension:"png"},outdoors:{extension:"png"},osm_bright:{extension:"png"}},vat={stamen_terrain:{minZoom:0,maxZoom:18,retina:!0},stamen_toner:{minZoom:0,maxZoom:20,retina:!0},stamen_watercolor:{minZoom:1,maxZoom:18,retina:!1}};class wat extends hl{constructor(t){const e=t.layer.indexOf("-"),i=e==-1?t.layer:t.layer.slice(0,e),n=vat[i]||{minZoom:0,maxZoom:20,retina:!0},r=xat[t.layer],o=t.apiKey?"?api_key="+t.apiKey:"",a=n.retina&&t.retina?"@2x":"",l=t.url!==void 0?t.url:"https://tiles.stadiamaps.com/tiles/"+t.layer+"/{z}/{x}/{y}"+a+"."+r.extension+o,h=[mat,_at,fO];t.layer.startsWith("stamen_")&&h.splice(1,0,yat),super({attributions:h,cacheSize:t.cacheSize,crossOrigin:"anonymous",interpolate:t.interpolate,maxZoom:t.maxZoom!==void 0?t.maxZoom:n.maxZoom,minZoom:t.minZoom!==void 0?t.minZoom:n.minZoom,reprojectionErrorThreshold:t.reprojectionErrorThreshold,tileLoadFunction:t.tileLoadFunction,transition:t.transition,url:l,tilePixelRatio:a?2:1,wrapX:t.wrapX,zDirection:t.zDirection})}}const Eat=wat;class Sat extends Sn{constructor(t){t=t||{},super({attributions:t.attributions,cacheSize:t.cacheSize,crossOrigin:t.crossOrigin,interpolate:t.interpolate,projection:t.projection,reprojectionErrorThreshold:t.reprojectionErrorThreshold,tileGrid:t.tileGrid,tileLoadFunction:t.tileLoadFunction,url:t.url,urls:t.urls,wrapX:t.wrapX!==void 0?t.wrapX:!0,transition:t.transition,zDirection:t.zDirection}),this.params_=Object.assign({},t.params),this.hidpi_=t.hidpi!==void 0?t.hidpi:!0,this.tmpExtent_=Zs(),this.setKey(this.getKeyForParams_())}getKeyForParams_(){let t=0;const e=[];for(const i in this.params_)e[t++]=i+"-"+this.params_[i];return e.join("/")}getParams(){return this.params_}getRequestUrl_(t,e,i,n,r,o){const a=this.urls;if(!a)return;let l;if(a.length==1)l=a[0];else{const h=kn(Jv(t),a.length);l=a[h]}return lO(l,i,(this.tileGrid||this.getTileGridForProjection(r)).getResolution(t[0]),n,r,o)}getTilePixelRatio(t){return this.hidpi_?t:1}updateParams(t){Object.assign(this.params_,t),this.setKey(this.getKeyForParams_())}tileUrlFunction(t,e,i){let n=this.getTileGrid();if(n||(n=this.getTileGridForProjection(i)),n.getResolutions().length<=t[0])return;e!=1&&!this.hidpi_&&(e=1);const r=n.getTileCoordExtent(t,this.tmpExtent_);let o=Re(n.getTileSize(t[0]),this.tmpSize);e!=1&&(o=YI(o,e,this.tmpSize));const a={F:"image",FORMAT:"PNG32",TRANSPARENT:!0};return Object.assign(a,this.params_),this.getRequestUrl_(t,o,r,e,i,a)}}const Mat=Sat;class bat extends hl{constructor(t){t=t||{},super({projection:t.projection,tileGrid:t.tileGrid,wrapX:t.wrapX!==void 0?t.wrapX:!0,zDirection:t.zDirection,url:t.template||"z:{z} x:{x} y:{y}",tileLoadFunction:(e,i)=>{const n=e.getTileCoord()[0],r=Re(this.tileGrid.getTileSize(n)),o=Se(r[0],r[1]);o.strokeStyle="grey",o.strokeRect(.5,.5,r[0]+.5,r[1]+.5),o.fillStyle="grey",o.strokeStyle="white",o.textAlign="center",o.textBaseline="middle",o.font="24px sans-serif",o.lineWidth=4,o.strokeText(i,r[0]/2,r[1]/2,r[0]),o.fillText(i,r[0]/2,r[1]/2,r[0]),e.setImage(o.canvas)}})}}const Cat=bat;class Tat extends Oc{constructor(t,e,i,n,r,o){super(t,e),this.src_=i,this.extent_=n,this.preemptive_=r,this.grid_=null,this.keys_=null,this.data_=null,this.jsonp_=o}getImage(){return null}getData(t){if(!this.grid_||!this.keys_)return null;const e=(t[0]-this.extent_[0])/(this.extent_[2]-this.extent_[0]),i=(t[1]-this.extent_[1])/(this.extent_[3]-this.extent_[1]),n=this.grid_[Math.floor((1-i)*this.grid_.length)];if(typeof n!="string")return null;let r=n.charCodeAt(Math.floor(e*n.length));r>=93&&r--,r>=35&&r--,r-=32;let o=null;if(r in this.keys_){const a=this.keys_[r];this.data_&&a in this.data_?o=this.data_[a]:o=a}return o}forDataAtCoordinate(t,e,i){this.state==X.EMPTY&&i===!0?(this.state=X.IDLE,bd(this,Zt.CHANGE,n=>{e(this.getData(t))}),this.loadInternal_()):i===!0?setTimeout(()=>{e(this.getData(t))},0):e(this.getData(t))}getKey(){return this.src_}handleError_(){this.state=X.ERROR,this.changed()}handleLoad_(t){this.grid_=t.grid,this.keys_=t.keys,this.data_=t.data,this.state=X.LOADED,this.changed()}loadInternal_(){if(this.state==X.IDLE)if(this.state=X.LOADING,this.jsonp_)Iw(this.src_,this.handleLoad_.bind(this),this.handleError_.bind(this));else{const t=new XMLHttpRequest;t.addEventListener("load",this.onXHRLoad_.bind(this)),t.addEventListener("error",this.onXHRError_.bind(this)),t.open("GET",this.src_),t.send()}}onXHRLoad_(t){const e=t.target;if(!e.status||e.status>=200&&e.status<300){let i;try{i=JSON.parse(e.responseText)}catch{this.handleError_();return}this.handleLoad_(i)}else this.handleError_()}onXHRError_(t){this.handleError_()}load(){this.preemptive_?this.loadInternal_():this.setState(X.EMPTY)}}class Rat extends Fg{constructor(t){if(super({projection:st("EPSG:3857"),state:"loading",wrapX:t.wrapX!==void 0?t.wrapX:!0,zDirection:t.zDirection}),this.preemptive_=t.preemptive!==void 0?t.preemptive:!0,this.tileUrlFunction_=Ytt,this.template_=void 0,this.jsonp_=t.jsonp||!1,t.url)if(this.jsonp_)Iw(t.url,this.handleTileJSONResponse.bind(this),this.handleTileJSONError.bind(this));else{const e=new XMLHttpRequest;e.addEventListener("load",this.onXHRLoad_.bind(this)),e.addEventListener("error",this.onXHRError_.bind(this)),e.open("GET",t.url),e.send()}else if(t.tileJSON)this.handleTileJSONResponse(t.tileJSON);else throw new Error("Either `url` or `tileJSON` options must be provided")}onXHRLoad_(t){const e=t.target;if(!e.status||e.status>=200&&e.status<300){let i;try{i=JSON.parse(e.responseText)}catch{this.handleTileJSONError();return}this.handleTileJSONResponse(i)}else this.handleTileJSONError()}onXHRError_(t){this.handleTileJSONError()}getTemplate(){return this.template_}forDataAtCoordinateAndResolution(t,e,i,n){if(this.tileGrid){const r=this.tileGrid.getZForResolution(e,this.zDirection),o=this.tileGrid.getTileCoordForCoordAndZ(t,r);this.getTile(o[0],o[1],o[2],1,this.getProjection()).forDataAtCoordinate(t,i,n)}else n===!0?setTimeout(function(){i(null)},0):i(null)}handleTileJSONError(){this.setState("error")}handleTileJSONResponse(t){const e=st("EPSG:4326"),i=this.getProjection();let n;if(t.bounds!==void 0){const c=Sl(e,i);n=nc(t.bounds,c)}const r=yo(i),o=t.minzoom||0,a=t.maxzoom||22,l=Cl({extent:r,maxZoom:a,minZoom:o});this.tileGrid=l,this.template_=t.template;const h=t.grids;if(!h){this.setState("error");return}if(this.tileUrlFunction_=Cw(h,l),t.attribution){const c=n!==void 0?n:r;this.setAttributions(function(u){return Ce(c,u.extent)?[t.attribution]:null})}this.setState("ready")}getTile(t,e,i,n,r){const o=ro(t,e,i);if(this.tileCache.containsKey(o))return this.tileCache.get(o);const a=[t,e,i],l=this.getTileCoordForTileUrlFunction(a,r),h=this.tileUrlFunction_(l,n,r),c=new Tat(a,h!==void 0?X.IDLE:X.EMPTY,h!==void 0?h:"",this.tileGrid.getTileCoordExtent(a),this.preemptive_,this.jsonp_);return this.tileCache.set(o,c),c}useTile(t,e,i){const n=ro(t,e,i);this.tileCache.containsKey(n)&&this.tileCache.get(n)}}const Iat=Rat;function Pat(s,t){const e=new l0(32),i=s.getExtent();return function(n,r){e.expireCache(),i&&(n=He(i,n));const o=s.getZForResolution(r),a=[];return s.forEachTileCoord(n,o,l=>{const h=l.toString();if(!e.containsKey(h)){const c=t(l);e.set(h,c)}a.push(e.get(h))}),a}}const Aat=Object.freeze(Object.defineProperty({__proto__:null,BingMaps:vot,CartoDB:Eot,Cluster:Mot,DataTile:d0,GeoTIFF:bw,Google:Pot,IIIF:Fot,Image:ya,ImageArcGISRest:Dot,ImageCanvas:$ot,ImageMapGuide:Uot,ImageStatic:hL,ImageTile:Vot,ImageWMS:qot,OGCMapTile:eat,OGCVectorTile:iat,OSM:rat,Raster:pat,Source:Lc,StadiaMaps:Eat,Tile:Fg,TileArcGISRest:Mat,TileDebug:Cat,TileImage:Sn,TileJSON:gL,TileWMS:_L,UTFGrid:Iat,UrlTile:Rw,Vector:s0,VectorTile:y0,WMTS:yL,XYZ:hl,Zoomify:Lot,createArcGISRestLoader:hO,createMapGuideLoader:cO,createStaticLoader:lL,createWMSLoader:mL,sourcesFromTileGrid:Pat},Symbol.toStringTag,{value:"Module"}));class Lat extends Sn{constructor(t){super({attributions:t.attributions,cacheSize:t.cacheSize,tilePixelRatio:t.tilePixelRatio,transition:t.transition,interpolate:t.interpolate!==void 0?t.interpolate:!0,key:t.key,attributionsCollapsible:t.attributionsCollapsible,zDirection:t.zDirection,wrapX:t.wrapX}),this.version_=t.version!==void 0?t?.version:"1.0.0",this.dimensions_=t.dimensions!==void 0?t.dimensions:{},this.layer_=t.layer,fetch(t.url).then(e=>e.text()).then(e=>new window.DOMParser().parseFromString(e,"application/xml")).then(e=>{this.handleCapabilitiesResponse(e,t)})}handleCapabilitiesResponse(t,e){const i=new kv().read(t),n=xL(i,e);this.crossOrigin=n.crossOrigin,this.projection=n.projection,this.tileGrid=n.tileGrid,this.requestEncoding_=n.requestEncoding,this.matrixSet_=n.matrixSet,this.style_=n.style,this.format_=n.format,this.dimensions_=n.dimensions,this.setUrls(n.urls),this.urls&&this.urls.length>0&&(this.tileUrlFunction=fc(this.urls.map(this.createFromWMTSTemplate.bind(this)))),this.setState("ready")}createFromWMTSTemplate(t){const e=this.requestEncoding_,i={layer:this.layer_,style:this.style_,tilematrixset:this.matrixSet_};e=="KVP"&&Object.assign(i,{Service:"WMTS",Request:"GetTile",Version:this.version_,Format:this.format_}),t=e=="KVP"?oo(t,i):t.replace(/\{(\w+?)\}/g,function(o,a){return a.toLowerCase()in i?i[a.toLowerCase()]:o});const n=this.tileGrid,r=this.dimensions_;return function(o){if(!o)return;const a={TileMatrix:n.getMatrixId(o[0]),TileCol:o[1],TileRow:o[2]};Object.assign(a,r);let l=t;return e=="KVP"?l=oo(l,a):l=l.replace(/\{(\w+?)\}/g,function(h,c){return a[c]}),l}}}window.eoxMapAdvancedOlSources={...Aat,WMTSCapabilities:Lat};const Oat=["enabled"],Fat=["config"],Nat=["config"],Dat={__name:"EodashMap",props:{enableCompare:{type:Boolean,default:!1}},setup(s){const t=s,e=R0(null),i=R0(null),n=R0("first"),r=Ww({center:[15,48],zoom:4,layers:[{type:"Tile",properties:{id:"osm",title:"Background"},source:{type:"OSM"}}]}),o=Ww({center:[15,48],zoom:4,layers:[]});Ma&&Ma.value&&Ma.value.length===3&&(r.center=[Ma.value?.[0],Ma.value[1]],r.zoom=Ma.value[2]);const a=c=>{const u=c.map,[d,g]=u?.getView().getCenter()??[0,0],f=u?.getView().getZoom();!Number.isNaN(d)&&!Number.isNaN(g)&&!Number.isNaN(f)&&(Ma.value=[d,g,f])},l=MO(),h=async(c,u,d)=>{const f=SO(d.value,c.value).map(M=>new Zw(M)),p=[],m={type:"Group",properties:{id:"AnalysisGroup",title:"Analysis Layers",layerControlExpand:!0},layers:[]};for(const M of f){let T;u?T=await M.createLayersJson(new Date(u)):T=await M.createLayersJson(),T&&m.layers.push(...T)}m.layers.forEach(M=>{M.properties.layerControlExpand=!0,M.properties.layerControlToolsExpand=!0}),p.push(m);const y=await new Zw(I0.value).buildJsonArray(d.value,I0.value,d.value?.title??"",d.value?.endpointtype??!1),v={type:"Group",properties:{id:"BaseLayersGroup",title:"Base Layers"},layers:[]},S=y.filter(M=>M.properties.group==="baselayer");S.length?(v.layers.push(...S),v.layers.forEach(M=>{M.properties.layerControlExclusive=!0})):v.layers.push({type:"Tile",properties:{id:"osm",title:"Background",layerControlExclusive:!0},source:{type:"OSM"}}),v.layers.length&&p.push(v);const w={type:"Group",properties:{id:"OverlayGroup",title:"Overlay Layers"},layers:[]},C=y.filter(M=>M.properties.group==="overlay");return C.length&&(w.layers.push(...C),p.unshift(w)),p};return bO(()=>{CO.value=e.value,e.value?.map?.on("moveend",a);const{selectedStac:c,selectedCompareStac:u}=TO(l);t.enableCompare&&Xw([u,Yw],async([d,g],[f,p])=>{if(d){const m=await h(AO,g,u);i.value.layers=m,n.value=""}}),Xw([c,Yw],async([d,g],[f,p])=>{if(d){const m=await h(I0,g,c);if(e.value.layers=m,f?.id!==d.id){n.value="first";const _=d.extent?.spatial.bbox[0],y=[_[0]>-180?_[0]:-180,_[1]>-90?_[1]:-90,_[2]<180?_[2]:180,_[3]<90?_[3]:90],v=dF(y,"EPSG:4326",e.value?.map?.getView().getProjection());e.value.zoomExtent=v}}},{immediate:!0})}),RO(()=>{e.value?.map?.un("moveend",a)}),(c,u)=>(IO(),PO("eox-map-compare",{class:"fill-height fill-width overflow-none",enabled:n.value},[Vw("eox-map",{class:"fill-height fill-width overflow-none",slot:"first",sync:"eox-map#compare",ref_key:"eoxMap",ref:e,id:"main",config:r},null,8,Fat),Vw("eox-map",{class:"fill-height fill-width overflow-none",id:"compare",slot:"second",ref_key:"compareMap",ref:i,config:o},null,8,Nat)],8,Oat))}},Rct=Object.freeze(Object.defineProperty({__proto__:null,default:Dat},Symbol.toStringTag,{value:"Module"}));export{Rct as E,Tct as a,Cct as o,g0 as x}; diff --git a/pr-preview/pr-17/assets/EodashMapBtns-BBddO65x.js b/pr-preview/pr-17/assets/EodashMapBtns-BBddO65x.js new file mode 100644 index 0000000..f28ac2d --- /dev/null +++ b/pr-preview/pr-17/assets/EodashMapBtns-BBddO65x.js @@ -0,0 +1 @@ +import{_ as c,r as i,aT as f,$ as o,a6 as d,a0 as r,a3 as e,V as u,a5 as s,aU as v,aR as m,aV as k,aS as x}from"./index-Dvu417lt.js";import B from"./ExportState-D-Xz2LGJ.js";import"./PopUp-5-tUIM9N.js";import"./VOverlay-DGc1wXYF.js";import"./forwardRefs-DzUtZcD3.js";import"./transition-BKtsYhmO.js";import"./index-CIIeHcTL.js";import"./VImg-CLLthewK.js";const M={__name:"EodashMapBtns",props:{exportMap:{type:Boolean,default:!0},changeProjection:{type:Boolean,default:!0}},setup(n){const t=i(!1),p=i(null);return f(p),(y,a)=>(o(),d("div",{ref_key:"rootRef",ref:p,class:"d-flex flex-column align-end justify-end my-3 pa-2"},[n.exportMap?(o(),r(u,{key:0,class:"map-btn",icon:[e(v)],onClick:a[0]||(a[0]=l=>t.value=!t.value)},null,8,["icon"])):s("v-if",!0),n.exportMap?(o(),r(B,{key:1,modelValue:t.value,"onUpdate:modelValue":a[1]||(a[1]=l=>t.value=l)},null,8,["modelValue"])):s("v-if",!0),n.changeProjection&&e(m)?(o(),r(u,{key:2,class:"map-btn",icon:[e(k)],onClick:a[2]||(a[2]=l=>e(x)(e(m)))},null,8,["icon"])):s("v-if",!0)],512))}},S=c(M,[["__scopeId","data-v-d7a01370"]]);export{S as default}; diff --git a/pr-preview/pr-17/assets/EodashMapBtns-jNIMsmmc.js b/pr-preview/pr-17/assets/EodashMapBtns-jNIMsmmc.js deleted file mode 100644 index a0ea945..0000000 --- a/pr-preview/pr-17/assets/EodashMapBtns-jNIMsmmc.js +++ /dev/null @@ -1 +0,0 @@ -import{_ as c,r as i,aS as f,$ as o,a6 as d,a0 as l,a3 as e,V as m,a5 as s,aT as v,aQ as u,aU as k,aR as x}from"./index-BHzPgH2J.js";import B from"./ExportState-CN3SVEwD.js";import"./PopUp-BLlcRLMy.js";import"./VOverlay-Di1btkZg.js";import"./forwardRefs-BoZnhoLd.js";import"./transition-zS3yGrDV.js";import"./index-DLx-KgOd.js";import"./VDivider-CnS8Y1Zb.js";import"./VImg-i8uxgNTt.js";const M={__name:"EodashMapBtns",props:{exportMap:{type:Boolean,default:!0},changeProjection:{type:Boolean,default:!0}},setup(n){const t=i(!1),p=i(null);return f(p),(y,a)=>(o(),d("div",{ref_key:"rootRef",ref:p,class:"d-flex flex-column align-end justify-end my-3 pa-2"},[n.exportMap?(o(),l(m,{key:0,class:"map-btn",icon:[e(v)],onClick:a[0]||(a[0]=r=>t.value=!t.value)},null,8,["icon"])):s("v-if",!0),n.exportMap?(o(),l(B,{key:1,modelValue:t.value,"onUpdate:modelValue":a[1]||(a[1]=r=>t.value=r)},null,8,["modelValue"])):s("v-if",!0),n.changeProjection&&e(u)?(o(),l(m,{key:2,class:"map-btn",icon:[e(k)],onClick:a[2]||(a[2]=r=>e(x)(e(u)))},null,8,["icon"])):s("v-if",!0)],512))}},$=c(M,[["__scopeId","data-v-d7a01370"]]);export{$ as default}; diff --git a/pr-preview/pr-17/assets/ExportState-C78fNrFy.css b/pr-preview/pr-17/assets/ExportState-C78fNrFy.css new file mode 100644 index 0000000..389a707 --- /dev/null +++ b/pr-preview/pr-17/assets/ExportState-C78fNrFy.css @@ -0,0 +1 @@ +.code-block[data-v-98028b8c]{background-color:#ddd;font-family:monospace;font-size:small}.v-card{display:block;overflow:hidden;overflow-wrap:break-word;position:relative;padding:0;text-decoration:none;transition-duration:.28s;transition-property:box-shadow,opacity,background;transition-timing-function:cubic-bezier(.4,0,.2,1);z-index:0}.v-card{border-color:rgba(var(--v-border-color),var(--v-border-opacity));border-style:solid;border-width:0}.v-card--border{border-width:thin;box-shadow:none}.v-card--absolute{position:absolute}.v-card--fixed{position:fixed}.v-card{border-radius:4px}.v-card:hover>.v-card__overlay{opacity:calc(var(--v-hover-opacity) * var(--v-theme-overlay-multiplier))}.v-card:focus-visible>.v-card__overlay{opacity:calc(var(--v-focus-opacity) * var(--v-theme-overlay-multiplier))}@supports not selector(:focus-visible){.v-card:focus>.v-card__overlay{opacity:calc(var(--v-focus-opacity) * var(--v-theme-overlay-multiplier))}}.v-card--active>.v-card__overlay,.v-card[aria-haspopup=menu][aria-expanded=true]>.v-card__overlay{opacity:calc(var(--v-activated-opacity) * var(--v-theme-overlay-multiplier))}.v-card--active:hover>.v-card__overlay,.v-card[aria-haspopup=menu][aria-expanded=true]:hover>.v-card__overlay{opacity:calc((var(--v-activated-opacity) + var(--v-hover-opacity)) * var(--v-theme-overlay-multiplier))}.v-card--active:focus-visible>.v-card__overlay,.v-card[aria-haspopup=menu][aria-expanded=true]:focus-visible>.v-card__overlay{opacity:calc((var(--v-activated-opacity) + var(--v-focus-opacity)) * var(--v-theme-overlay-multiplier))}@supports not selector(:focus-visible){.v-card--active:focus>.v-card__overlay,.v-card[aria-haspopup=menu][aria-expanded=true]:focus>.v-card__overlay{opacity:calc((var(--v-activated-opacity) + var(--v-focus-opacity)) * var(--v-theme-overlay-multiplier))}}.v-card--variant-plain,.v-card--variant-outlined,.v-card--variant-text,.v-card--variant-tonal{background:transparent;color:inherit}.v-card--variant-plain{opacity:.62}.v-card--variant-plain:focus,.v-card--variant-plain:hover{opacity:1}.v-card--variant-plain .v-card__overlay{display:none}.v-card--variant-elevated,.v-card--variant-flat{background:rgb(var(--v-theme-surface));color:rgba(var(--v-theme-on-surface),var(--v-high-emphasis-opacity))}.v-card--variant-elevated{box-shadow:0 2px 1px -1px var(--v-shadow-key-umbra-opacity, rgba(0, 0, 0, .2)),0 1px 1px 0 var(--v-shadow-key-penumbra-opacity, rgba(0, 0, 0, .14)),0 1px 3px 0 var(--v-shadow-key-ambient-opacity, rgba(0, 0, 0, .12))}.v-card--variant-flat{box-shadow:0 0 0 0 var(--v-shadow-key-umbra-opacity, rgba(0, 0, 0, .2)),0 0 0 0 var(--v-shadow-key-penumbra-opacity, rgba(0, 0, 0, .14)),0 0 0 0 var(--v-shadow-key-ambient-opacity, rgba(0, 0, 0, .12))}.v-card--variant-outlined{border:thin solid currentColor}.v-card--variant-text .v-card__overlay{background:currentColor}.v-card--variant-tonal .v-card__underlay{background:currentColor;opacity:var(--v-activated-opacity);border-radius:inherit;inset:0;pointer-events:none}.v-card .v-card__underlay{position:absolute}.v-card--disabled{pointer-events:none;user-select:none}.v-card--disabled>:not(.v-card__loader){opacity:.6}.v-card--flat{box-shadow:none}.v-card--hover{cursor:pointer}.v-card--hover:before,.v-card--hover:after{border-radius:inherit;content:"";display:block;inset:0;pointer-events:none;position:absolute;transition:inherit}.v-card--hover:before{opacity:1;z-index:-1}.v-card--hover:before{box-shadow:0 2px 1px -1px var(--v-shadow-key-umbra-opacity, rgba(0, 0, 0, .2)),0 1px 1px 0 var(--v-shadow-key-penumbra-opacity, rgba(0, 0, 0, .14)),0 1px 3px 0 var(--v-shadow-key-ambient-opacity, rgba(0, 0, 0, .12))}.v-card--hover:after{z-index:1;opacity:0}.v-card--hover:after{box-shadow:0 5px 5px -3px var(--v-shadow-key-umbra-opacity, rgba(0, 0, 0, .2)),0 8px 10px 1px var(--v-shadow-key-penumbra-opacity, rgba(0, 0, 0, .14)),0 3px 14px 2px var(--v-shadow-key-ambient-opacity, rgba(0, 0, 0, .12))}.v-card--hover:hover:after{opacity:1}.v-card--hover:hover:before{opacity:0}.v-card--hover:hover{box-shadow:0 5px 5px -3px var(--v-shadow-key-umbra-opacity, rgba(0, 0, 0, .2)),0 8px 10px 1px var(--v-shadow-key-penumbra-opacity, rgba(0, 0, 0, .14)),0 3px 14px 2px var(--v-shadow-key-ambient-opacity, rgba(0, 0, 0, .12))}.v-card--link{cursor:pointer}.v-card-actions{align-items:center;display:flex;flex:none;min-height:52px;padding:.5rem}.v-card-item{align-items:center;display:grid;flex:none;grid-template-areas:"prepend content append";grid-template-columns:max-content auto max-content;padding:.625rem 1rem}.v-card-item+.v-card-text{padding-top:0}.v-card-item__prepend,.v-card-item__append{align-items:center;display:flex}.v-card-item__prepend{grid-area:prepend;padding-inline-end:.5rem}.v-card-item__append{grid-area:append;padding-inline-start:.5rem}.v-card-item__content{align-self:center;grid-area:content;overflow:hidden}.v-card-title{display:block;flex:none;font-size:1.25rem;font-weight:500;hyphens:auto;letter-spacing:.0125em;min-width:0;overflow-wrap:normal;overflow:hidden;padding:.5rem 1rem;text-overflow:ellipsis;text-transform:none;white-space:nowrap;word-break:normal;word-wrap:break-word}.v-card .v-card-title{line-height:1.6}.v-card--density-comfortable .v-card-title{line-height:1.75rem}.v-card--density-compact .v-card-title{line-height:1.55rem}.v-card-item .v-card-title{padding:0}.v-card-title+.v-card-text,.v-card-title+.v-card-actions{padding-top:0}.v-card-subtitle{display:block;flex:none;font-size:.875rem;font-weight:400;letter-spacing:.0178571429em;opacity:var(--v-card-subtitle-opacity, var(--v-medium-emphasis-opacity));overflow:hidden;padding:0 1rem;text-overflow:ellipsis;text-transform:none;white-space:nowrap}.v-card .v-card-subtitle{line-height:1.425}.v-card--density-comfortable .v-card-subtitle{line-height:1.125rem}.v-card--density-compact .v-card-subtitle{line-height:1rem}.v-card-item .v-card-subtitle{padding:0 0 .25rem}.v-card-text{flex:1 1 auto;font-size:.875rem;font-weight:400;letter-spacing:.0178571429em;opacity:var(--v-card-text-opacity, 1);padding:1rem;text-transform:none}.v-card .v-card-text{line-height:1.425}.v-card--density-comfortable .v-card-text{line-height:1.2rem}.v-card--density-compact .v-card-text{line-height:1.15rem}.v-card__image{display:flex;height:100%;flex:1 1 auto;left:0;overflow:hidden;position:absolute;top:0;width:100%;z-index:-1}.v-card__content{border-radius:inherit;overflow:hidden;position:relative}.v-card__loader{inset:0 0 auto;position:absolute;width:100%;z-index:1}.v-card__overlay{background-color:currentColor;border-radius:inherit;position:absolute;inset:0;pointer-events:none;opacity:0;transition:opacity .2s ease-in-out}.v-avatar{flex:none;align-items:center;display:inline-flex;justify-content:center;line-height:normal;overflow:hidden;position:relative;text-align:center;transition:.2s cubic-bezier(.4,0,.2,1);transition-property:width,height;vertical-align:middle}.v-avatar.v-avatar--size-x-small{--v-avatar-height: 24px}.v-avatar.v-avatar--size-small{--v-avatar-height: 32px}.v-avatar.v-avatar--size-default{--v-avatar-height: 40px}.v-avatar.v-avatar--size-large{--v-avatar-height: 48px}.v-avatar.v-avatar--size-x-large{--v-avatar-height: 56px}.v-avatar.v-avatar--density-default{height:calc(var(--v-avatar-height) + 0px);width:calc(var(--v-avatar-height) + 0px)}.v-avatar.v-avatar--density-comfortable{height:calc(var(--v-avatar-height) + -4px);width:calc(var(--v-avatar-height) + -4px)}.v-avatar.v-avatar--density-compact{height:calc(var(--v-avatar-height) + -8px);width:calc(var(--v-avatar-height) + -8px)}.v-avatar{border-radius:50%}.v-avatar--variant-plain,.v-avatar--variant-outlined,.v-avatar--variant-text,.v-avatar--variant-tonal{background:transparent;color:inherit}.v-avatar--variant-plain{opacity:.62}.v-avatar--variant-plain:focus,.v-avatar--variant-plain:hover{opacity:1}.v-avatar--variant-plain .v-avatar__overlay{display:none}.v-avatar--variant-elevated,.v-avatar--variant-flat{background:var(--v-theme-surface);color:rgba(var(--v-theme-on-surface),var(--v-medium-emphasis-opacity))}.v-avatar--variant-elevated{box-shadow:0 2px 1px -1px var(--v-shadow-key-umbra-opacity, rgba(0, 0, 0, .2)),0 1px 1px 0 var(--v-shadow-key-penumbra-opacity, rgba(0, 0, 0, .14)),0 1px 3px 0 var(--v-shadow-key-ambient-opacity, rgba(0, 0, 0, .12))}.v-avatar--variant-flat{box-shadow:0 0 0 0 var(--v-shadow-key-umbra-opacity, rgba(0, 0, 0, .2)),0 0 0 0 var(--v-shadow-key-penumbra-opacity, rgba(0, 0, 0, .14)),0 0 0 0 var(--v-shadow-key-ambient-opacity, rgba(0, 0, 0, .12))}.v-avatar--variant-outlined{border:thin solid currentColor}.v-avatar--variant-text .v-avatar__overlay{background:currentColor}.v-avatar--variant-tonal .v-avatar__underlay{background:currentColor;opacity:var(--v-activated-opacity);border-radius:inherit;inset:0;pointer-events:none}.v-avatar .v-avatar__underlay{position:absolute}.v-avatar--rounded{border-radius:4px}.v-avatar--start{margin-inline-end:8px}.v-avatar--end{margin-inline-start:8px}.v-avatar .v-img{height:100%;width:100%}.v-divider{display:block;flex:1 1 100%;height:0px;max-height:0px;opacity:var(--v-border-opacity);transition:inherit}.v-divider{border-style:solid;border-width:thin 0 0 0}.v-divider--vertical{align-self:stretch;border-width:0 thin 0 0;display:inline-flex;height:auto;margin-left:-1px;max-height:100%;max-width:0px;vertical-align:text-bottom;width:0px}.v-divider--inset:not(.v-divider--vertical){max-width:calc(100% - 72px);margin-inline-start:72px}.v-divider--inset.v-divider--vertical{margin-bottom:8px;margin-top:8px;max-height:calc(100% - 16px)}.v-divider__content{padding:0 16px;text-wrap:nowrap}.v-divider__wrapper--vertical .v-divider__content{padding:4px 0}.v-divider__wrapper{display:flex;align-items:center;justify-content:center}.v-divider__wrapper--vertical{flex-direction:column;height:100%}.v-divider__wrapper--vertical .v-divider{margin:0 auto} diff --git a/pr-preview/pr-17/assets/ExportState-CN3SVEwD.js b/pr-preview/pr-17/assets/ExportState-CN3SVEwD.js deleted file mode 100644 index 8cb9faf..0000000 --- a/pr-preview/pr-17/assets/ExportState-CN3SVEwD.js +++ /dev/null @@ -1,4 +0,0 @@ -import{aV as $,_ as T,aW as k,aX as w,r as B,c as f,$ as u,a0 as F,a1 as t,aY as L,b as e,a9 as l,aa as _,a6 as g,M as N,a3 as x,aZ as E,a5 as M,aC as A,a_ as I,a7 as O,V,a$ as z,a8 as h,F as J,b0 as m,aM as v,ar as D,as as j}from"./index-BHzPgH2J.js";import q from"./PopUp-BLlcRLMy.js";import{a as P}from"./index-DLx-KgOd.js";import{V as R,a as U,b as W,c as X,d as Y}from"./VDivider-CnS8Y1Zb.js";import"./VOverlay-Di1btkZg.js";import"./forwardRefs-BoZnhoLd.js";import"./transition-zS3yGrDV.js";import"./VImg-i8uxgNTt.js";const Z=$("v-spacer","div","VSpacer"),y=o=>(D("data-v-98028b8c"),o=o(),j(),o),G=y(()=>l("h5",{class:"text-h5"},"Storytelling map configuration",-1)),H=y(()=>l("p",{class:"text-body-2"}," Copy and paste this code into the map layers field of the storytelling editor: ",-1)),K={class:"pa-3 code-block"},Q={style:{position:"absolute",bottom:"15px"}},ee={key:0,class:"text-success mr-3"},ae=y(()=>l("small",null,"copied!",-1)),te={__name:"ExportState",props:k({getLayers:{type:Function,default:L}},{modelValue:{type:Boolean,required:!0,default:!1},modelModifiers:{}}),emits:["update:modelValue"],setup(o){const n=w(o,"modelValue"),r=o,c=B(!1),C=[{id:Symbol(),copyFn:async()=>await m(b.value,c),copyAs:"simple map"},{id:Symbol(),copyFn:async()=>await m(JSON.stringify(r.getLayers()),c),copyAs:"layers configuration"},{id:Symbol(),copyFn:async()=>await m(S.value,c),copyAs:"map tour section"}],S=f(()=>{const[i,s,a]=v.value,d="### -#### Tour step title -Text describing the current step of the tour and why it is interesting what the map shows currently -`;return`${d}'${JSON.stringify(r.getLayers())}' ${p}`}),b=f(()=>{const[i,s,a]=v.value,d='## Map Example `;return`${d}'${JSON.stringify(r.getLayers())}' ${p}`});return(i,s)=>(u(),F(q,{modelValue:n.value,"onUpdate:modelValue":s[1]||(s[1]=a=>n.value=a)},{default:t(()=>[e(Y,null,{default:t(()=>[e(R,{class:"bg-primary"},{default:t(()=>[G]),_:1}),e(U,{class:"py-5"},{default:t(()=>[H,l("div",K,_(o.getLayers()),1),l("div",Q,[e(P,null,{default:t(()=>[c.value?(u(),g("div",ee,[e(N,{color:"success",left:"",icon:[x(E)]},null,8,["icon"]),ae])):M("v-if",!0)]),_:1})]),e(A,{class:"d-flex pt-3 justify-end"},{default:t(()=>[e(I,{cols:"6",class:"flex-column align-center text-end"},{default:t(()=>[(u(),g(J,null,O(C,a=>e(V,{class:"text-body-2",onClick:a.copyFn,key:a.id,small:"",variant:"text","prepend-icon":[x(z)]},{default:t(()=>[h(" copy as "+_(a.copyAs),1)]),_:2},1032,["onClick","prepend-icon"])),64))]),_:1})]),_:1})]),_:1}),e(W),e(X,null,{default:t(()=>[e(Z),e(V,{variant:"text",onClick:s[0]||(s[0]=a=>n.value=!n.value)},{default:t(()=>[h(" Close ")]),_:1})]),_:1})]),_:1})]),_:1},8,["modelValue"]))}},pe=T(te,[["__scopeId","data-v-98028b8c"]]);export{pe as default}; diff --git a/pr-preview/pr-17/assets/ExportState-D-Xz2LGJ.js b/pr-preview/pr-17/assets/ExportState-D-Xz2LGJ.js new file mode 100644 index 0000000..2078c86 --- /dev/null +++ b/pr-preview/pr-17/assets/ExportState-D-Xz2LGJ.js @@ -0,0 +1,4 @@ +import{aW as M,g as m,e as y,S as ve,a as g,b as a,p as f,f as x,I as k,O as T,ag as j,aX as me,h as B,aY as J,i as N,aZ as W,P as U,aj as q,a_ as ye,M as S,ak as _,a$ as H,F as P,ae as ge,ac as fe,af as be,b0 as ke,b1 as he,b2 as Ce,b3 as pe,b4 as Ve,ah as Se,ad as _e,ai as xe,b5 as Ie,b6 as Ae,b7 as Pe,b8 as Te,c as h,t as Be,v as Ne,b9 as we,u as Le,R as $e,C as L,_ as De,ba as ze,bb as Fe,r as Re,$ as I,a0 as Ee,a1 as c,bc as Oe,a9 as C,aa as $,a6 as D,a3 as z,bd as Me,a5 as je,aD as Je,be as We,a7 as Ue,V as F,bf as qe,a8 as R,bg as A,aN as E,as as He,at as Xe}from"./index-Dvu417lt.js";import Ye from"./PopUp-5-tUIM9N.js";import{a as Ze}from"./index-CIIeHcTL.js";import{V as X}from"./VImg-CLLthewK.js";import"./VOverlay-DGc1wXYF.js";import"./forwardRefs-DzUtZcD3.js";import"./transition-BKtsYhmO.js";const Ge=M("v-spacer","div","VSpacer"),Y=m()({name:"VCardActions",props:y(),setup(e,l){let{slots:n}=l;return ve({VBtn:{slim:!0,variant:"text"}}),g(()=>a("div",{class:["v-card-actions",e.class],style:e.style},[n.default?.()])),{}}}),Ke=f({opacity:[Number,String],...y(),...x()},"VCardSubtitle"),Qe=m()({name:"VCardSubtitle",props:Ke(),setup(e,l){let{slots:n}=l;return g(()=>a(e.tag,{class:["v-card-subtitle",e.class],style:[{"--v-card-subtitle-opacity":e.opacity},e.style]},n)),{}}}),Z=M("v-card-title"),ea=f({start:Boolean,end:Boolean,icon:k,image:String,text:String,...y(),...T(),...j(),...me(),...x(),...B(),...J({variant:"flat"})},"VAvatar"),O=m()({name:"VAvatar",props:ea(),setup(e,l){let{slots:n}=l;const{themeClasses:t}=N(e),{colorClasses:r,colorStyles:o,variantClasses:u}=W(e),{densityClasses:d}=U(e),{roundedClasses:s}=q(e),{sizeClasses:i,sizeStyles:v}=ye(e);return g(()=>a(e.tag,{class:["v-avatar",{"v-avatar--start":e.start,"v-avatar--end":e.end},t.value,r.value,d.value,s.value,i.value,u.value,e.class],style:[o.value,v.value,e.style]},{default:()=>[n.default?a(_,{key:"content-defaults",defaults:{VImg:{cover:!0,src:e.image},VIcon:{icon:e.icon}}},{default:()=>[n.default()]}):e.image?a(X,{key:"image",src:e.image,alt:"",cover:!0},null):e.icon?a(S,{key:"icon",icon:e.icon},null):e.text,H(!1,"v-avatar")]})),{}}}),aa=f({appendAvatar:String,appendIcon:k,prependAvatar:String,prependIcon:k,subtitle:[String,Number],title:[String,Number],...y(),...T()},"VCardItem"),ta=m()({name:"VCardItem",props:aa(),setup(e,l){let{slots:n}=l;return g(()=>{const t=!!(e.prependAvatar||e.prependIcon),r=!!(t||n.prepend),o=!!(e.appendAvatar||e.appendIcon),u=!!(o||n.append),d=!!(e.title!=null||n.title),s=!!(e.subtitle!=null||n.subtitle);return a("div",{class:["v-card-item",e.class],style:e.style},[r&&a("div",{key:"prepend",class:"v-card-item__prepend"},[n.prepend?a(_,{key:"prepend-defaults",disabled:!t,defaults:{VAvatar:{density:e.density,image:e.prependAvatar},VIcon:{density:e.density,icon:e.prependIcon}}},n.prepend):a(P,null,[e.prependAvatar&&a(O,{key:"prepend-avatar",density:e.density,image:e.prependAvatar},null),e.prependIcon&&a(S,{key:"prepend-icon",density:e.density,icon:e.prependIcon},null)])]),a("div",{class:"v-card-item__content"},[d&&a(Z,{key:"title"},{default:()=>[n.title?.()??e.title]}),s&&a(Qe,{key:"subtitle"},{default:()=>[n.subtitle?.()??e.subtitle]}),n.default?.()]),u&&a("div",{key:"append",class:"v-card-item__append"},[n.append?a(_,{key:"append-defaults",disabled:!o,defaults:{VAvatar:{density:e.density,image:e.appendAvatar},VIcon:{density:e.density,icon:e.appendIcon}}},n.append):a(P,null,[e.appendIcon&&a(S,{key:"append-icon",density:e.density,icon:e.appendIcon},null),e.appendAvatar&&a(O,{key:"append-avatar",density:e.density,image:e.appendAvatar},null)])])])}),{}}}),na=f({opacity:[Number,String],...y(),...x()},"VCardText"),G=m()({name:"VCardText",props:na(),setup(e,l){let{slots:n}=l;return g(()=>a(e.tag,{class:["v-card-text",e.class],style:[{"--v-card-text-opacity":e.opacity},e.style]},n)),{}}}),sa=f({appendAvatar:String,appendIcon:k,disabled:Boolean,flat:Boolean,hover:Boolean,image:String,link:{type:Boolean,default:void 0},prependAvatar:String,prependIcon:k,ripple:{type:[Boolean,Object],default:!0},subtitle:[String,Number],text:[String,Number],title:[String,Number],...ge(),...y(),...T(),...fe(),...be(),...ke(),...he(),...Ce(),...j(),...pe(),...x(),...B(),...J({variant:"elevated"})},"VCard"),la=m()({name:"VCard",directives:{Ripple:Ve},props:sa(),setup(e,l){let{attrs:n,slots:t}=l;const{themeClasses:r}=N(e),{borderClasses:o}=Se(e),{colorClasses:u,colorStyles:d,variantClasses:s}=W(e),{densityClasses:i}=U(e),{dimensionStyles:v}=_e(e),{elevationClasses:b}=xe(e),{loaderClasses:K}=Ie(e),{locationStyles:Q}=Ae(e),{positionClasses:ee}=Pe(e),{roundedClasses:ae}=q(e),p=Te(e,n),te=h(()=>e.link!==!1&&p.isLink.value),V=h(()=>!e.disabled&&e.link!==!1&&(e.link||p.isClickable.value));return g(()=>{const ne=te.value?"a":e.tag,se=!!(t.title||e.title!=null),le=!!(t.subtitle||e.subtitle!=null),ie=se||le,de=!!(t.append||e.appendAvatar||e.appendIcon),oe=!!(t.prepend||e.prependAvatar||e.prependIcon),ce=!!(t.image||e.image),re=ie||oe||de,ue=!!(t.text||e.text!=null);return Be(a(ne,{class:["v-card",{"v-card--disabled":e.disabled,"v-card--flat":e.flat,"v-card--hover":e.hover&&!(e.disabled||e.flat),"v-card--link":V.value},r.value,o.value,u.value,i.value,b.value,K.value,ee.value,ae.value,s.value,e.class],style:[d.value,v.value,Q.value,e.style],href:p.href.value,onClick:V.value&&p.navigate,tabindex:e.disabled?-1:void 0},{default:()=>[ce&&a("div",{key:"image",class:"v-card__image"},[t.image?a(_,{key:"image-defaults",disabled:!e.image,defaults:{VImg:{cover:!0,src:e.image}}},t.image):a(X,{key:"image-img",cover:!0,src:e.image},null)]),a(we,{name:"v-card",active:!!e.loading,color:typeof e.loading=="boolean"?void 0:e.loading},{default:t.loader}),re&&a(ta,{key:"item",prependAvatar:e.prependAvatar,prependIcon:e.prependIcon,title:e.title,subtitle:e.subtitle,appendAvatar:e.appendAvatar,appendIcon:e.appendIcon},{default:t.item,prepend:t.prepend,title:t.title,subtitle:t.subtitle,append:t.append}),ue&&a(G,{key:"text"},{default:()=>[t.text?.()??e.text]}),t.default?.(),t.actions&&a(Y,null,{default:t.actions}),H(V.value,"v-card")]}),[[Ne("ripple"),V.value&&e.ripple]])}),{}}}),ia=f({color:String,inset:Boolean,length:[Number,String],opacity:[Number,String],thickness:[Number,String],vertical:Boolean,...y(),...B()},"VDivider"),da=m()({name:"VDivider",props:ia(),setup(e,l){let{attrs:n,slots:t}=l;const{themeClasses:r}=N(e),{textColorClasses:o,textColorStyles:u}=Le($e(e,"color")),d=h(()=>{const s={};return e.length&&(s[e.vertical?"height":"width"]=L(e.length)),e.thickness&&(s[e.vertical?"borderRightWidth":"borderTopWidth"]=L(e.thickness)),s});return g(()=>{const s=a("hr",{class:[{"v-divider":!0,"v-divider--inset":e.inset,"v-divider--vertical":e.vertical},r.value,o.value,e.class],style:[d.value,u.value,{"--v-border-opacity":e.opacity},e.style],"aria-orientation":!n.role||n.role==="separator"?e.vertical?"vertical":"horizontal":void 0,role:`${n.role||"separator"}`},null);return t.default?a("div",{class:["v-divider__wrapper",{"v-divider__wrapper--vertical":e.vertical,"v-divider__wrapper--inset":e.inset}]},[s,a("div",{class:"v-divider__content"},[t.default()]),s]):s}),{}}}),w=e=>(He("data-v-98028b8c"),e=e(),Xe(),e),oa=w(()=>C("h5",{class:"text-h5"},"Storytelling map configuration",-1)),ca=w(()=>C("p",{class:"text-body-2"}," Copy and paste this code into the map layers field of the storytelling editor: ",-1)),ra={class:"pa-3 code-block"},ua={style:{position:"absolute",bottom:"15px"}},va={key:0,class:"text-success mr-3"},ma=w(()=>C("small",null,"copied!",-1)),ya={__name:"ExportState",props:ze({getLayers:{type:Function,default:Oe}},{modelValue:{type:Boolean,required:!0,default:!1},modelModifiers:{}}),emits:["update:modelValue"],setup(e){const l=Fe(e,"modelValue"),n=e,t=Re(!1),r=[{id:Symbol(),copyFn:async()=>await A(u.value,t),copyAs:"simple map"},{id:Symbol(),copyFn:async()=>await A(JSON.stringify(n.getLayers()),t),copyAs:"layers configuration"},{id:Symbol(),copyFn:async()=>await A(o.value,t),copyAs:"map tour section"}],o=h(()=>{const[d,s,i]=E.value,v="### +#### Tour step title +Text describing the current step of the tour and why it is interesting what the map shows currently +`;return`${v}'${JSON.stringify(n.getLayers())}' ${b}`}),u=h(()=>{const[d,s,i]=E.value,v='## Map Example `;return`${v}'${JSON.stringify(n.getLayers())}' ${b}`});return(d,s)=>(I(),Ee(Ye,{modelValue:l.value,"onUpdate:modelValue":s[1]||(s[1]=i=>l.value=i)},{default:c(()=>[a(la,null,{default:c(()=>[a(Z,{class:"bg-primary"},{default:c(()=>[oa]),_:1}),a(G,{class:"py-5"},{default:c(()=>[ca,C("div",ra,$(e.getLayers()),1),C("div",ua,[a(Ze,null,{default:c(()=>[t.value?(I(),D("div",va,[a(S,{color:"success",left:"",icon:[z(Me)]},null,8,["icon"]),ma])):je("v-if",!0)]),_:1})]),a(Je,{class:"d-flex pt-3 justify-end"},{default:c(()=>[a(We,{cols:"6",class:"flex-column align-center text-end"},{default:c(()=>[(I(),D(P,null,Ue(r,i=>a(F,{class:"text-body-2",onClick:i.copyFn,key:i.id,small:"",variant:"text","prepend-icon":[z(qe)]},{default:c(()=>[R(" copy as "+$(i.copyAs),1)]),_:2},1032,["onClick","prepend-icon"])),64))]),_:1})]),_:1})]),_:1}),a(da),a(Y,null,{default:c(()=>[a(Ge),a(F,{variant:"text",onClick:s[0]||(s[0]=i=>l.value=!l.value)},{default:c(()=>[R(" Close ")]),_:1})]),_:1})]),_:1})]),_:1},8,["modelValue"]))}},Va=De(ya,[["__scopeId","data-v-98028b8c"]]);export{Va as default}; diff --git a/pr-preview/pr-17/assets/ExportState-DyBA6-z0.css b/pr-preview/pr-17/assets/ExportState-DyBA6-z0.css deleted file mode 100644 index 334e003..0000000 --- a/pr-preview/pr-17/assets/ExportState-DyBA6-z0.css +++ /dev/null @@ -1 +0,0 @@ -.code-block[data-v-98028b8c]{background-color:#ddd;font-family:monospace;font-size:small} diff --git a/pr-preview/pr-17/assets/Footer-9K1bUbvk.js b/pr-preview/pr-17/assets/Footer-Bbz6BUHt.js similarity index 98% rename from pr-preview/pr-17/assets/Footer-9K1bUbvk.js rename to pr-preview/pr-17/assets/Footer-Bbz6BUHt.js index 7e78c2a..2584826 100644 --- a/pr-preview/pr-17/assets/Footer-9K1bUbvk.js +++ b/pr-preview/pr-17/assets/Footer-Bbz6BUHt.js @@ -1 +1 @@ -import{p as w,ae as k,e as b,af as C,an as I,ag as S,f as R,h as B,g as P,r as p,s as f,i as z,Q as F,R as g,ah as M,ai as T,aj as V,J as X,c as t,ao as Z,aq as j,ap as L,a as N,b as D,C as E,_ as H,x as $,W as q,H as A,$ as J,a0 as K,a1 as O,a9 as a,aa as Q,a3 as r,a8 as U,ar as W,as as G}from"./index-BHzPgH2J.js";const Y=w({app:Boolean,color:String,height:{type:[Number,String],default:"auto"},...k(),...b(),...C(),...I(),...S(),...R({tag:"footer"}),...B()},"VFooter"),l0=P()({name:"VFooter",props:Y(),setup(l,c){let{slots:n}=c;const o=p(),s=f(),{themeClasses:i}=z(l),{backgroundColorClasses:d,backgroundColorStyles:m}=F(g(l,"color")),{borderClasses:v}=M(l),{elevationClasses:y}=T(l),{roundedClasses:_}=V(l),h=f(32),{resizeRef:x}=X(e=>{e.length&&(h.value=e[0].target.clientHeight)}),u=t(()=>l.height==="auto"?h.value:parseInt(l.height,10));return Z(()=>l.app,()=>{const e=j({id:l.name,order:t(()=>parseInt(l.order,10)),position:t(()=>"bottom"),layoutSize:u,elementSize:t(()=>l.height==="auto"?void 0:u.value),active:t(()=>l.app),absolute:g(l,"absolute")});L(()=>{o.value=e.layoutItemStyles.value,s.value=e.layoutIsReady})}),N(()=>D(l.tag,{ref:x,class:["v-footer",i.value,d.value,v.value,y.value,_.value,l.class],style:[m.value,l.app?o.value:{height:E(l.height)},l.style]},n)),l.app?s.value:{}}}),e0=l=>(W("data-v-7ea19f1b"),l=l(),G(),l),t0={class:"pt-0 footer-text"},a0=e0(()=>a("a",{href:"https://github.com/eodash/eodash",class:"text-white",target:"_blank"},"eodash",-1)),o0={href:"https://eox.at",target:"_blank",class:"text-white"},s0=["src"],c0='',n0={__name:"Footer",setup(l){const c=p(null),n=$(q),{mdAndDown:o}=A(),s=window.btoa(c0);return(i,d)=>(J(),K(l0,{ref_key:"footer",ref:c,height:r(o)?"48px":"auto",color:"secondary",app:"",class:"d-flex justify-space-between"},{default:O(()=>[a("p",t0,Q(r(n).brand.footerText??""),1),a("div",null,[a0,U(" by "),a("a",o0,[a("img",{src:`data:image/svg+xml;base64,${r(s)}`,height:"11px"},null,8,s0)])])]),_:1},8,["height"]))}},i0=H(n0,[["__scopeId","data-v-7ea19f1b"]]);export{i0 as default}; +import{p as w,ae as k,e as b,af as C,an as I,ag as S,f as R,h as B,g as P,r as p,s as f,i as z,Q as F,R as g,ah as M,ai as T,aj as V,J as X,c as t,ao as Z,aq as j,ap as L,a as N,b as D,C as E,_ as H,x as $,W as q,H as A,$ as J,a0 as K,a1 as O,a9 as a,aa as Q,a3 as r,a8 as U,as as W,at as G}from"./index-Dvu417lt.js";const Y=w({app:Boolean,color:String,height:{type:[Number,String],default:"auto"},...k(),...b(),...C(),...I(),...S(),...R({tag:"footer"}),...B()},"VFooter"),l0=P()({name:"VFooter",props:Y(),setup(l,c){let{slots:n}=c;const o=p(),s=f(),{themeClasses:i}=z(l),{backgroundColorClasses:d,backgroundColorStyles:m}=F(g(l,"color")),{borderClasses:v}=M(l),{elevationClasses:y}=T(l),{roundedClasses:_}=V(l),h=f(32),{resizeRef:x}=X(e=>{e.length&&(h.value=e[0].target.clientHeight)}),u=t(()=>l.height==="auto"?h.value:parseInt(l.height,10));return Z(()=>l.app,()=>{const e=j({id:l.name,order:t(()=>parseInt(l.order,10)),position:t(()=>"bottom"),layoutSize:u,elementSize:t(()=>l.height==="auto"?void 0:u.value),active:t(()=>l.app),absolute:g(l,"absolute")});L(()=>{o.value=e.layoutItemStyles.value,s.value=e.layoutIsReady})}),N(()=>D(l.tag,{ref:x,class:["v-footer",i.value,d.value,v.value,y.value,_.value,l.class],style:[m.value,l.app?o.value:{height:E(l.height)},l.style]},n)),l.app?s.value:{}}}),e0=l=>(W("data-v-7ea19f1b"),l=l(),G(),l),t0={class:"pt-0 footer-text"},a0=e0(()=>a("a",{href:"https://github.com/eodash/eodash",class:"text-white",target:"_blank"},"eodash",-1)),o0={href:"https://eox.at",target:"_blank",class:"text-white"},s0=["src"],c0='',n0={__name:"Footer",setup(l){const c=p(null),n=$(q),{mdAndDown:o}=A(),s=window.btoa(c0);return(i,d)=>(J(),K(l0,{ref_key:"footer",ref:c,height:r(o)?"48px":"auto",color:"secondary",app:"",class:"d-flex justify-space-between"},{default:O(()=>[a("p",t0,Q(r(n).brand.footerText??""),1),a("div",null,[a0,U(" by "),a("a",o0,[a("img",{src:`data:image/svg+xml;base64,${r(s)}`,height:"11px"},null,8,s0)])])]),_:1},8,["height"]))}},i0=H(n0,[["__scopeId","data-v-7ea19f1b"]]);export{i0 as default}; diff --git a/pr-preview/pr-17/assets/Header-CWK95wXa.js b/pr-preview/pr-17/assets/Header-LhvQ5ty7.js similarity index 96% rename from pr-preview/pr-17/assets/Header-CWK95wXa.js rename to pr-preview/pr-17/assets/Header-LhvQ5ty7.js index a89fe2c..1cda30d 100644 --- a/pr-preview/pr-17/assets/Header-CWK95wXa.js +++ b/pr-preview/pr-17/assets/Header-LhvQ5ty7.js @@ -1 +1 @@ -import{p as V,e as w,f as N,g as _,a as p,b as o,ae as z,af as F,ag as W,h as $,Q as K,R as k,ah as O,ai as Q,aj as Y,i as Z,j as G,s as y,c as n,S as J,ak as B,C as T,r as R,al as X,w as x,Z as ee,am as te,an as ae,y as le,ao as oe,ap as se,aq as ne,d as E,_ as re,x as ue,W as ie,$ as ce,a0 as de,a1 as P,a8 as ve,aa as me,a3 as C}from"./index-BHzPgH2J.js";import{V as A}from"./VImg-i8uxgNTt.js";import{a as ge}from"./index-DLx-KgOd.js";import{u as fe}from"./ssrBoot-7hoALQc5.js";import"./transition-zS3yGrDV.js";const L=V({text:String,...w(),...N()},"VToolbarTitle"),D=_()({name:"VToolbarTitle",props:L(),setup(e,r){let{slots:t}=r;return p(()=>{const d=!!(t.default||t.text||e.text);return o(e.tag,{class:["v-toolbar-title",e.class],style:e.style},{default:()=>[d&&o("div",{class:"v-toolbar-title__placeholder"},[t.text?t.text():e.text,t.default?.()])]})}),{}}}),he=[null,"prominent","default","comfortable","compact"],U=V({absolute:Boolean,collapse:Boolean,color:String,density:{type:String,default:"default",validator:e=>he.includes(e)},extended:Boolean,extensionHeight:{type:[Number,String],default:48},flat:Boolean,floating:Boolean,height:{type:[Number,String],default:64},image:String,title:String,...z(),...w(),...F(),...W(),...N({tag:"header"}),...$()},"VToolbar"),I=_()({name:"VToolbar",props:U(),setup(e,r){let{slots:t}=r;const{backgroundColorClasses:d,backgroundColorStyles:u}=K(k(e,"color")),{borderClasses:a}=O(e),{elevationClasses:v}=Q(e),{roundedClasses:i}=Y(e),{themeClasses:f}=Z(e),{rtlClasses:S}=G(),c=y(!!(e.extended||t.extension?.())),m=n(()=>parseInt(Number(e.height)+(e.density==="prominent"?Number(e.height):0)-(e.density==="comfortable"?8:0)-(e.density==="compact"?16:0),10)),b=n(()=>c.value?parseInt(Number(e.extensionHeight)+(e.density==="prominent"?Number(e.extensionHeight):0)-(e.density==="comfortable"?4:0)-(e.density==="compact"?8:0),10):0);return J({VBtn:{variant:"text"}}),p(()=>{const h=!!(e.title||t.title),s=!!(t.image||e.image),g=t.extension?.();return c.value=!!(e.extended||g),o(e.tag,{class:["v-toolbar",{"v-toolbar--absolute":e.absolute,"v-toolbar--collapse":e.collapse,"v-toolbar--flat":e.flat,"v-toolbar--floating":e.floating,[`v-toolbar--density-${e.density}`]:!0},d.value,a.value,v.value,i.value,f.value,S.value,e.class],style:[u.value,e.style]},{default:()=>[s&&o("div",{key:"image",class:"v-toolbar__image"},[t.image?o(B,{key:"image-defaults",disabled:!e.image,defaults:{VImg:{cover:!0,src:e.image}}},t.image):o(A,{key:"image-img",cover:!0,src:e.image},null)]),o(B,{defaults:{VTabs:{height:T(m.value)}}},{default:()=>[o("div",{class:"v-toolbar__content",style:{height:T(m.value)}},[t.prepend&&o("div",{class:"v-toolbar__prepend"},[t.prepend?.()]),h&&o(D,{key:"title",text:e.title},{text:t.title}),t.default?.(),t.append&&o("div",{class:"v-toolbar__append"},[t.append?.()])])]}),o(B,{defaults:{VTabs:{height:T(b.value)}}},{default:()=>[o(ge,null,{default:()=>[c.value&&o("div",{class:"v-toolbar__extension",style:{height:T(b.value)}},[g])]})]})]})}),{contentHeight:m,extensionHeight:b}}}),be=V({scrollTarget:{type:String},scrollThreshold:{type:[String,Number],default:300}},"scroll");function ye(e){let r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};const{canScroll:t}=r;let d=0,u=0;const a=R(null),v=y(0),i=y(0),f=y(0),S=y(!1),c=y(!1),m=n(()=>Number(e.scrollThreshold)),b=n(()=>X((m.value-v.value)/m.value||0)),h=()=>{const s=a.value;if(!s||t&&!t.value)return;d=v.value,v.value="window"in s?s.pageYOffset:s.scrollTop;const g=s instanceof Window?document.documentElement.scrollHeight:s.scrollHeight;if(u!==g){u=g;return}c.value=v.value{i.value=i.value||v.value}),x(S,()=>{i.value=0}),ee(()=>{x(()=>e.scrollTarget,s=>{const g=s?document.querySelector(s):window;g&&g!==a.value&&(a.value?.removeEventListener("scroll",h),a.value=g,a.value.addEventListener("scroll",h,{passive:!0}))},{immediate:!0})}),te(()=>{a.value?.removeEventListener("scroll",h)}),t&&x(t,h,{immediate:!0}),{scrollThreshold:m,currentScroll:v,currentThreshold:f,isScrollActive:S,scrollRatio:b,isScrollingUp:c,savedScroll:i}}const Se=V({scrollBehavior:String,modelValue:{type:Boolean,default:!0},location:{type:String,default:"top",validator:e=>["top","bottom"].includes(e)},...U(),...ae(),...be(),height:{type:[Number,String],default:64}},"VAppBar"),Te=_()({name:"VAppBar",props:Se(),emits:{"update:modelValue":e=>!0},setup(e,r){let{slots:t}=r;const d=R(),u=le(e,"modelValue"),a=n(()=>{const l=new Set(e.scrollBehavior?.split(" ")??[]);return{hide:l.has("hide"),fullyHide:l.has("fully-hide"),inverted:l.has("inverted"),collapse:l.has("collapse"),elevate:l.has("elevate"),fadeImage:l.has("fade-image")}}),v=n(()=>{const l=a.value;return l.hide||l.fullyHide||l.inverted||l.collapse||l.elevate||l.fadeImage||!u.value}),{currentScroll:i,scrollThreshold:f,isScrollingUp:S,scrollRatio:c}=ye(e,{canScroll:v}),m=n(()=>a.value.hide||a.value.fullyHide),b=n(()=>e.collapse||a.value.collapse&&(a.value.inverted?c.value>0:c.value===0)),h=n(()=>e.flat||a.value.fullyHide&&!u.value||a.value.elevate&&(a.value.inverted?i.value>0:i.value===0)),s=n(()=>a.value.fadeImage?a.value.inverted?1-c.value:c.value:void 0),g=n(()=>{const l=Number(d.value?.contentHeight??e.height),H=Number(d.value?.extensionHeight??0);return m.value?i.value!!e.scrollBehavior),()=>{se(()=>{m.value?a.value.inverted?u.value=i.value>f.value:u.value=S.value||i.valueparseInt(e.order,10)),position:k(e,"location"),layoutSize:g,elementSize:y(void 0),active:u,absolute:k(e,"absolute")});return p(()=>{const l=I.filterProps(e);return o(I,E({ref:d,class:["v-app-bar",{"v-app-bar--bottom":e.location==="bottom"},e.class],style:[{...M.value,"--v-toolbar-image-opacity":s.value,height:void 0,...j.value},e.style]},l,{collapse:b.value,flat:h.value}),t)}),q}}),xe=_()({name:"VAppBarTitle",props:L(),setup(e,r){let{slots:t}=r;return p(()=>o(D,E(e,{class:"v-app-bar-title"}),t)),{}}}),Ve={__name:"Header",setup(e){const r=ue(ie),t=r.brand?.name;return(d,u)=>(ce(),de(Te,{color:"primary"},{default:P(()=>[o(xe,null,{default:P(()=>[ve(me(C(t)),1)]),_:1}),o(A,{class:"mx-12 logo",src:C(r).brand?.logo},null,8,["src"])]),_:1}))}},Pe=re(Ve,[["__scopeId","data-v-d3a5e05e"]]);export{Pe as default}; +import{p as V,e as w,f as N,g as _,a as p,b as o,ae as z,af as F,ag as W,h as $,Q as K,R as k,ah as O,ai as Q,aj as Y,i as Z,j as G,s as y,c as n,S as J,ak as B,C as T,r as R,al as X,w as x,Z as ee,am as te,an as ae,y as le,ao as oe,ap as se,aq as ne,d as E,_ as re,x as ue,W as ie,$ as ce,a0 as de,a1 as P,a8 as ve,aa as me,a3 as C}from"./index-Dvu417lt.js";import{V as A}from"./VImg-CLLthewK.js";import{a as ge}from"./index-CIIeHcTL.js";import{u as fe}from"./ssrBoot-Uu_-yAhn.js";import"./transition-BKtsYhmO.js";const L=V({text:String,...w(),...N()},"VToolbarTitle"),D=_()({name:"VToolbarTitle",props:L(),setup(e,r){let{slots:t}=r;return p(()=>{const d=!!(t.default||t.text||e.text);return o(e.tag,{class:["v-toolbar-title",e.class],style:e.style},{default:()=>[d&&o("div",{class:"v-toolbar-title__placeholder"},[t.text?t.text():e.text,t.default?.()])]})}),{}}}),he=[null,"prominent","default","comfortable","compact"],U=V({absolute:Boolean,collapse:Boolean,color:String,density:{type:String,default:"default",validator:e=>he.includes(e)},extended:Boolean,extensionHeight:{type:[Number,String],default:48},flat:Boolean,floating:Boolean,height:{type:[Number,String],default:64},image:String,title:String,...z(),...w(),...F(),...W(),...N({tag:"header"}),...$()},"VToolbar"),I=_()({name:"VToolbar",props:U(),setup(e,r){let{slots:t}=r;const{backgroundColorClasses:d,backgroundColorStyles:u}=K(k(e,"color")),{borderClasses:a}=O(e),{elevationClasses:v}=Q(e),{roundedClasses:i}=Y(e),{themeClasses:f}=Z(e),{rtlClasses:S}=G(),c=y(!!(e.extended||t.extension?.())),m=n(()=>parseInt(Number(e.height)+(e.density==="prominent"?Number(e.height):0)-(e.density==="comfortable"?8:0)-(e.density==="compact"?16:0),10)),b=n(()=>c.value?parseInt(Number(e.extensionHeight)+(e.density==="prominent"?Number(e.extensionHeight):0)-(e.density==="comfortable"?4:0)-(e.density==="compact"?8:0),10):0);return J({VBtn:{variant:"text"}}),p(()=>{const h=!!(e.title||t.title),s=!!(t.image||e.image),g=t.extension?.();return c.value=!!(e.extended||g),o(e.tag,{class:["v-toolbar",{"v-toolbar--absolute":e.absolute,"v-toolbar--collapse":e.collapse,"v-toolbar--flat":e.flat,"v-toolbar--floating":e.floating,[`v-toolbar--density-${e.density}`]:!0},d.value,a.value,v.value,i.value,f.value,S.value,e.class],style:[u.value,e.style]},{default:()=>[s&&o("div",{key:"image",class:"v-toolbar__image"},[t.image?o(B,{key:"image-defaults",disabled:!e.image,defaults:{VImg:{cover:!0,src:e.image}}},t.image):o(A,{key:"image-img",cover:!0,src:e.image},null)]),o(B,{defaults:{VTabs:{height:T(m.value)}}},{default:()=>[o("div",{class:"v-toolbar__content",style:{height:T(m.value)}},[t.prepend&&o("div",{class:"v-toolbar__prepend"},[t.prepend?.()]),h&&o(D,{key:"title",text:e.title},{text:t.title}),t.default?.(),t.append&&o("div",{class:"v-toolbar__append"},[t.append?.()])])]}),o(B,{defaults:{VTabs:{height:T(b.value)}}},{default:()=>[o(ge,null,{default:()=>[c.value&&o("div",{class:"v-toolbar__extension",style:{height:T(b.value)}},[g])]})]})]})}),{contentHeight:m,extensionHeight:b}}}),be=V({scrollTarget:{type:String},scrollThreshold:{type:[String,Number],default:300}},"scroll");function ye(e){let r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};const{canScroll:t}=r;let d=0,u=0;const a=R(null),v=y(0),i=y(0),f=y(0),S=y(!1),c=y(!1),m=n(()=>Number(e.scrollThreshold)),b=n(()=>X((m.value-v.value)/m.value||0)),h=()=>{const s=a.value;if(!s||t&&!t.value)return;d=v.value,v.value="window"in s?s.pageYOffset:s.scrollTop;const g=s instanceof Window?document.documentElement.scrollHeight:s.scrollHeight;if(u!==g){u=g;return}c.value=v.value{i.value=i.value||v.value}),x(S,()=>{i.value=0}),ee(()=>{x(()=>e.scrollTarget,s=>{const g=s?document.querySelector(s):window;g&&g!==a.value&&(a.value?.removeEventListener("scroll",h),a.value=g,a.value.addEventListener("scroll",h,{passive:!0}))},{immediate:!0})}),te(()=>{a.value?.removeEventListener("scroll",h)}),t&&x(t,h,{immediate:!0}),{scrollThreshold:m,currentScroll:v,currentThreshold:f,isScrollActive:S,scrollRatio:b,isScrollingUp:c,savedScroll:i}}const Se=V({scrollBehavior:String,modelValue:{type:Boolean,default:!0},location:{type:String,default:"top",validator:e=>["top","bottom"].includes(e)},...U(),...ae(),...be(),height:{type:[Number,String],default:64}},"VAppBar"),Te=_()({name:"VAppBar",props:Se(),emits:{"update:modelValue":e=>!0},setup(e,r){let{slots:t}=r;const d=R(),u=le(e,"modelValue"),a=n(()=>{const l=new Set(e.scrollBehavior?.split(" ")??[]);return{hide:l.has("hide"),fullyHide:l.has("fully-hide"),inverted:l.has("inverted"),collapse:l.has("collapse"),elevate:l.has("elevate"),fadeImage:l.has("fade-image")}}),v=n(()=>{const l=a.value;return l.hide||l.fullyHide||l.inverted||l.collapse||l.elevate||l.fadeImage||!u.value}),{currentScroll:i,scrollThreshold:f,isScrollingUp:S,scrollRatio:c}=ye(e,{canScroll:v}),m=n(()=>a.value.hide||a.value.fullyHide),b=n(()=>e.collapse||a.value.collapse&&(a.value.inverted?c.value>0:c.value===0)),h=n(()=>e.flat||a.value.fullyHide&&!u.value||a.value.elevate&&(a.value.inverted?i.value>0:i.value===0)),s=n(()=>a.value.fadeImage?a.value.inverted?1-c.value:c.value:void 0),g=n(()=>{const l=Number(d.value?.contentHeight??e.height),H=Number(d.value?.extensionHeight??0);return m.value?i.value!!e.scrollBehavior),()=>{se(()=>{m.value?a.value.inverted?u.value=i.value>f.value:u.value=S.value||i.valueparseInt(e.order,10)),position:k(e,"location"),layoutSize:g,elementSize:y(void 0),active:u,absolute:k(e,"absolute")});return p(()=>{const l=I.filterProps(e);return o(I,E({ref:d,class:["v-app-bar",{"v-app-bar--bottom":e.location==="bottom"},e.class],style:[{...M.value,"--v-toolbar-image-opacity":s.value,height:void 0,...j.value},e.style]},l,{collapse:b.value,flat:h.value}),t)}),q}}),xe=_()({name:"VAppBarTitle",props:L(),setup(e,r){let{slots:t}=r;return p(()=>o(D,E(e,{class:"v-app-bar-title"}),t)),{}}}),Ve={__name:"Header",setup(e){const r=ue(ie),t=r.brand?.name;return(d,u)=>(ce(),de(Te,{color:"primary"},{default:P(()=>[o(xe,null,{default:P(()=>[ve(me(C(t)),1)]),_:1}),o(A,{class:"mx-12 logo",src:C(r).brand?.logo},null,8,["src"])]),_:1}))}},Pe=re(Ve,[["__scopeId","data-v-d3a5e05e"]]);export{Pe as default}; diff --git a/pr-preview/pr-17/assets/IframeWrapper-DckIy2sZ.js b/pr-preview/pr-17/assets/IframeWrapper-CJivyMgq.js similarity index 73% rename from pr-preview/pr-17/assets/IframeWrapper-DckIy2sZ.js rename to pr-preview/pr-17/assets/IframeWrapper-CJivyMgq.js index 2ffc1bf..4679e3a 100644 --- a/pr-preview/pr-17/assets/IframeWrapper-DckIy2sZ.js +++ b/pr-preview/pr-17/assets/IframeWrapper-CJivyMgq.js @@ -1 +1 @@ -import{$ as r,a6 as t}from"./index-BHzPgH2J.js";const s=["src"],i={__name:"IframeWrapper",props:{src:{type:String,required:!0}},setup(e){return(c,a)=>(r(),t("iframe",{src:e.src,class:"fill-height fill-width"},null,8,s))}};export{i as default}; +import{$ as r,a6 as t}from"./index-Dvu417lt.js";const s=["src"],i={__name:"IframeWrapper",props:{src:{type:String,required:!0}},setup(e){return(c,a)=>(r(),t("iframe",{src:e.src,class:"fill-height fill-width"},null,8,s))}};export{i as default}; diff --git a/pr-preview/pr-17/assets/List-Ccmb12OW.css b/pr-preview/pr-17/assets/List-Ccmb12OW.css deleted file mode 100644 index c9c6ffd..0000000 --- a/pr-preview/pr-17/assets/List-Ccmb12OW.css +++ /dev/null @@ -1 +0,0 @@ -.v-list{overflow:auto;padding:8px 0;position:relative;outline:none}.v-list{border-color:rgba(var(--v-border-color),var(--v-border-opacity));border-style:solid;border-width:0}.v-list--border{border-width:thin;box-shadow:none}.v-list{box-shadow:0 0 0 0 var(--v-shadow-key-umbra-opacity, rgba(0, 0, 0, .2)),0 0 0 0 var(--v-shadow-key-penumbra-opacity, rgba(0, 0, 0, .14)),0 0 0 0 var(--v-shadow-key-ambient-opacity, rgba(0, 0, 0, .12))}.v-list{border-radius:0}.v-list{background:rgba(var(--v-theme-surface));color:rgba(var(--v-theme-on-surface),var(--v-high-emphasis-opacity))}.v-list--disabled{pointer-events:none;user-select:none}.v-list--nav{padding-inline:8px}.v-list--rounded{border-radius:4px}.v-list--subheader{padding-top:0}.v-list-img{border-radius:inherit;display:flex;height:100%;left:0;overflow:hidden;position:absolute;top:0;width:100%;z-index:-1}.v-list-subheader{align-items:center;background:inherit;color:rgba(var(--v-theme-on-surface),var(--v-medium-emphasis-opacity));display:flex;font-size:.875rem;font-weight:400;line-height:1.375rem;padding-inline-end:16px;min-height:40px;transition:.2s min-height cubic-bezier(.4,0,.2,1)}.v-list-subheader__text{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.v-list--density-default .v-list-subheader{min-height:40px;padding-inline-start:calc(16px + var(--indent-padding))!important}.v-list--density-comfortable .v-list-subheader{min-height:36px;padding-inline-start:calc(16px + var(--indent-padding))!important}.v-list--density-compact .v-list-subheader{min-height:32px;padding-inline-start:calc(16px + var(--indent-padding))!important}.v-list-subheader--inset{--indent-padding: 56px}.v-list--nav .v-list-subheader{font-size:.75rem}.v-list-subheader--sticky{background:inherit;left:0;position:sticky;top:0;z-index:1}.v-list__overlay{background-color:currentColor;border-radius:inherit;inset:0;opacity:0;pointer-events:none;position:absolute;transition:opacity .2s ease-in-out}.v-list-item{align-items:center;display:grid;flex:none;grid-template-areas:"prepend content append";grid-template-columns:max-content 1fr auto;outline:none;max-width:100%;padding:4px 16px;position:relative;text-decoration:none}.v-list-item{border-color:rgba(var(--v-border-color),var(--v-border-opacity));border-style:solid;border-width:0}.v-list-item--border{border-width:thin;box-shadow:none}.v-list-item:hover>.v-list-item__overlay{opacity:calc(var(--v-hover-opacity) * var(--v-theme-overlay-multiplier))}.v-list-item:focus-visible>.v-list-item__overlay{opacity:calc(var(--v-focus-opacity) * var(--v-theme-overlay-multiplier))}@supports not selector(:focus-visible){.v-list-item:focus>.v-list-item__overlay{opacity:calc(var(--v-focus-opacity) * var(--v-theme-overlay-multiplier))}}.v-list-item--active>.v-list-item__overlay,.v-list-item[aria-haspopup=menu][aria-expanded=true]>.v-list-item__overlay{opacity:calc(var(--v-activated-opacity) * var(--v-theme-overlay-multiplier))}.v-list-item--active:hover>.v-list-item__overlay,.v-list-item[aria-haspopup=menu][aria-expanded=true]:hover>.v-list-item__overlay{opacity:calc((var(--v-activated-opacity) + var(--v-hover-opacity)) * var(--v-theme-overlay-multiplier))}.v-list-item--active:focus-visible>.v-list-item__overlay,.v-list-item[aria-haspopup=menu][aria-expanded=true]:focus-visible>.v-list-item__overlay{opacity:calc((var(--v-activated-opacity) + var(--v-focus-opacity)) * var(--v-theme-overlay-multiplier))}@supports not selector(:focus-visible){.v-list-item--active:focus>.v-list-item__overlay,.v-list-item[aria-haspopup=menu][aria-expanded=true]:focus>.v-list-item__overlay{opacity:calc((var(--v-activated-opacity) + var(--v-focus-opacity)) * var(--v-theme-overlay-multiplier))}}.v-list-item{border-radius:0}.v-list-item--variant-plain,.v-list-item--variant-outlined,.v-list-item--variant-text,.v-list-item--variant-tonal{background:transparent;color:inherit}.v-list-item--variant-plain{opacity:.62}.v-list-item--variant-plain:focus,.v-list-item--variant-plain:hover{opacity:1}.v-list-item--variant-plain .v-list-item__overlay{display:none}.v-list-item--variant-elevated,.v-list-item--variant-flat{background:rgba(var(--v-theme-surface));color:rgba(var(--v-theme-on-surface),var(--v-high-emphasis-opacity))}.v-list-item--variant-elevated{box-shadow:0 2px 1px -1px var(--v-shadow-key-umbra-opacity, rgba(0, 0, 0, .2)),0 1px 1px 0 var(--v-shadow-key-penumbra-opacity, rgba(0, 0, 0, .14)),0 1px 3px 0 var(--v-shadow-key-ambient-opacity, rgba(0, 0, 0, .12))}.v-list-item--variant-flat{box-shadow:0 0 0 0 var(--v-shadow-key-umbra-opacity, rgba(0, 0, 0, .2)),0 0 0 0 var(--v-shadow-key-penumbra-opacity, rgba(0, 0, 0, .14)),0 0 0 0 var(--v-shadow-key-ambient-opacity, rgba(0, 0, 0, .12))}.v-list-item--variant-outlined{border:thin solid currentColor}.v-list-item--variant-text .v-list-item__overlay{background:currentColor}.v-list-item--variant-tonal .v-list-item__underlay{background:currentColor;opacity:var(--v-activated-opacity);border-radius:inherit;inset:0;pointer-events:none}.v-list-item .v-list-item__underlay{position:absolute}@supports selector(:focus-visible){.v-list-item:after{pointer-events:none;border:2px solid currentColor;border-radius:4px;opacity:0;transition:opacity .2s ease-in-out}.v-list-item:after{content:"";position:absolute;top:0;left:0;width:100%;height:100%}.v-list-item:focus-visible:after{opacity:calc(.15 * var(--v-theme-overlay-multiplier))}}.v-list-item__prepend>.v-badge .v-icon,.v-list-item__prepend>.v-icon,.v-list-item__append>.v-badge .v-icon,.v-list-item__append>.v-icon{opacity:var(--v-medium-emphasis-opacity)}.v-list-item--active .v-list-item__prepend>.v-badge .v-icon,.v-list-item--active .v-list-item__prepend>.v-icon,.v-list-item--active .v-list-item__append>.v-badge .v-icon,.v-list-item--active .v-list-item__append>.v-icon{opacity:1}.v-list-item--active:not(.v-list-item--link) .v-list-item__overlay{opacity:calc(var(--v-activated-opacity) * var(--v-theme-overlay-multiplier))}.v-list-item--rounded{border-radius:4px}.v-list-item--disabled{pointer-events:none;user-select:none;opacity:.6}.v-list-item--link{cursor:pointer}.v-navigation-drawer--rail:not(.v-navigation-drawer--expand-on-hover) .v-list-item .v-avatar,.v-navigation-drawer--rail.v-navigation-drawer--expand-on-hover:not(.v-navigation-drawer--is-hovering) .v-list-item .v-avatar{--v-avatar-height: 24px}.v-list-item__prepend{align-items:center;align-self:center;display:flex;grid-area:prepend}.v-list-item__prepend>.v-badge~.v-list-item__spacer,.v-list-item__prepend>.v-icon~.v-list-item__spacer,.v-list-item__prepend>.v-tooltip~.v-list-item__spacer{width:32px}.v-list-item__prepend>.v-avatar~.v-list-item__spacer{width:16px}.v-list-item__prepend>.v-list-item-action~.v-list-item__spacer{width:16px}.v-list-item--slim .v-list-item__prepend>.v-badge~.v-list-item__spacer,.v-list-item--slim .v-list-item__prepend>.v-icon~.v-list-item__spacer,.v-list-item--slim .v-list-item__prepend>.v-tooltip~.v-list-item__spacer{width:20px}.v-list-item--slim .v-list-item__prepend>.v-avatar~.v-list-item__spacer{width:4px}.v-list-item--slim .v-list-item__prepend>.v-list-item-action~.v-list-item__spacer{width:4px}.v-list-item--three-line .v-list-item__prepend{align-self:start}.v-list-item__append{align-self:center;display:flex;align-items:center;grid-area:append}.v-list-item__append .v-list-item__spacer{order:-1;transition:.15s width cubic-bezier(.4,0,.2,1)}.v-list-item__append>.v-badge~.v-list-item__spacer,.v-list-item__append>.v-icon~.v-list-item__spacer,.v-list-item__append>.v-tooltip~.v-list-item__spacer{width:32px}.v-list-item__append>.v-avatar~.v-list-item__spacer{width:16px}.v-list-item__append>.v-list-item-action~.v-list-item__spacer{width:16px}.v-list-item--slim .v-list-item__append>.v-badge~.v-list-item__spacer,.v-list-item--slim .v-list-item__append>.v-icon~.v-list-item__spacer,.v-list-item--slim .v-list-item__append>.v-tooltip~.v-list-item__spacer{width:20px}.v-list-item--slim .v-list-item__append>.v-avatar~.v-list-item__spacer{width:4px}.v-list-item--slim .v-list-item__append>.v-list-item-action~.v-list-item__spacer{width:4px}.v-list-item--three-line .v-list-item__append{align-self:start}.v-list-item__content{align-self:center;grid-area:content;overflow:hidden}.v-list-item-action{align-self:center;display:flex;align-items:center;flex:none;transition:inherit;transition-property:height,width}.v-list-item-action--start{margin-inline-end:8px;margin-inline-start:-8px}.v-list-item-action--end{margin-inline-start:8px;margin-inline-end:-8px}.v-list-item-media{margin-top:0;margin-bottom:0}.v-list-item-media--start{margin-inline-end:16px}.v-list-item-media--end{margin-inline-start:16px}.v-list-item--two-line .v-list-item-media{margin-top:-4px;margin-bottom:-4px}.v-list-item--three-line .v-list-item-media{margin-top:0;margin-bottom:0}.v-list-item-subtitle{-webkit-box-orient:vertical;display:-webkit-box;opacity:var(--v-list-item-subtitle-opacity, var(--v-medium-emphasis-opacity));overflow:hidden;padding:0;text-overflow:ellipsis;overflow-wrap:break-word;word-break:initial}.v-list-item--one-line .v-list-item-subtitle{-webkit-line-clamp:1}.v-list-item--two-line .v-list-item-subtitle{-webkit-line-clamp:2}.v-list-item--three-line .v-list-item-subtitle{-webkit-line-clamp:3}.v-list-item-subtitle{font-size:.875rem;font-weight:400;letter-spacing:.0178571429em;line-height:1rem;text-transform:none}.v-list-item--nav .v-list-item-subtitle{font-size:.75rem;font-weight:400;letter-spacing:.0178571429em;line-height:1rem}.v-list-item-title{hyphens:auto;overflow-wrap:normal;overflow:hidden;padding:0;white-space:nowrap;text-overflow:ellipsis;word-break:normal;word-wrap:break-word}.v-list-item-title{font-size:1rem;font-weight:400;letter-spacing:.009375em;line-height:1.5;text-transform:none}.v-list-item--nav .v-list-item-title{font-size:.8125rem;font-weight:500;letter-spacing:normal;line-height:1rem}.v-list-item--density-default{min-height:40px}.v-list-item--density-default.v-list-item--one-line{min-height:48px;padding-top:4px;padding-bottom:4px}.v-list-item--density-default.v-list-item--two-line{min-height:64px;padding-top:12px;padding-bottom:12px}.v-list-item--density-default.v-list-item--three-line{min-height:88px;padding-top:16px;padding-bottom:16px}.v-list-item--density-default.v-list-item--three-line .v-list-item__prepend,.v-list-item--density-default.v-list-item--three-line .v-list-item__append{padding-top:8px}.v-list-item--density-default:not(.v-list-item--nav).v-list-item--one-line{padding-inline:16px}.v-list-item--density-default:not(.v-list-item--nav).v-list-item--two-line{padding-inline:16px}.v-list-item--density-default:not(.v-list-item--nav).v-list-item--three-line{padding-inline:16px}.v-list-item--density-comfortable{min-height:36px}.v-list-item--density-comfortable.v-list-item--one-line{min-height:44px}.v-list-item--density-comfortable.v-list-item--two-line{min-height:60px;padding-top:8px;padding-bottom:8px}.v-list-item--density-comfortable.v-list-item--three-line{min-height:84px;padding-top:12px;padding-bottom:12px}.v-list-item--density-comfortable.v-list-item--three-line .v-list-item__prepend,.v-list-item--density-comfortable.v-list-item--three-line .v-list-item__append{padding-top:6px}.v-list-item--density-comfortable:not(.v-list-item--nav).v-list-item--one-line{padding-inline:16px}.v-list-item--density-comfortable:not(.v-list-item--nav).v-list-item--two-line{padding-inline:16px}.v-list-item--density-comfortable:not(.v-list-item--nav).v-list-item--three-line{padding-inline:16px}.v-list-item--density-compact{min-height:32px}.v-list-item--density-compact.v-list-item--one-line{min-height:40px}.v-list-item--density-compact.v-list-item--two-line{min-height:56px;padding-top:4px;padding-bottom:4px}.v-list-item--density-compact.v-list-item--three-line{min-height:80px;padding-top:8px;padding-bottom:8px}.v-list-item--density-compact.v-list-item--three-line .v-list-item__prepend,.v-list-item--density-compact.v-list-item--three-line .v-list-item__append{padding-top:4px}.v-list-item--density-compact:not(.v-list-item--nav).v-list-item--one-line{padding-inline:16px}.v-list-item--density-compact:not(.v-list-item--nav).v-list-item--two-line{padding-inline:16px}.v-list-item--density-compact:not(.v-list-item--nav).v-list-item--three-line{padding-inline:16px}.v-list-item--nav{padding-inline:8px}.v-list .v-list-item--nav:not(:only-child){margin-bottom:4px}.v-list-item__underlay{position:absolute}.v-list-item__overlay{background-color:currentColor;border-radius:inherit;inset:0;opacity:0;pointer-events:none;position:absolute;transition:opacity .2s ease-in-out}.v-list-item--active.v-list-item--variant-elevated .v-list-item__overlay{--v-theme-overlay-multiplier: 0}.v-list{--indent-padding: 0px}.v-list--nav{--indent-padding: -8px}.v-list-group{--list-indent-size: 16px;--parent-padding: var(--indent-padding);--prepend-width: 40px}.v-list--slim .v-list-group{--prepend-width: 28px}.v-list-group--fluid{--list-indent-size: 0px}.v-list-group--prepend{--parent-padding: calc(var(--indent-padding) + var(--prepend-width))}.v-list-group--fluid.v-list-group--prepend{--parent-padding: var(--indent-padding)}.v-list-group__items{--indent-padding: calc(var(--parent-padding) + var(--list-indent-size))}.v-list-group__items .v-list-item{padding-inline-start:calc(16px + var(--indent-padding))!important}.v-list-group__header:not(.v-treeview-item--activetable-group-activator).v-list-item--active:not(:focus-visible) .v-list-item__overlay{opacity:0}.v-list-group__header:not(.v-treeview-item--activetable-group-activator).v-list-item--active:hover .v-list-item__overlay{opacity:calc(var(--v-hover-opacity) * var(--v-theme-overlay-multiplier))} diff --git a/pr-preview/pr-17/assets/List-DXPnbxiN.js b/pr-preview/pr-17/assets/List-DXPnbxiN.js deleted file mode 100644 index f5ced5b..0000000 --- a/pr-preview/pr-17/assets/List-DXPnbxiN.js +++ /dev/null @@ -1 +0,0 @@ -import{x as R,s as F,q as E,bl as w,bq as ye,r as C,p as P,y as X,c as f,am as me,bh as qe,R as h,aw as ze,br as Qe,I as O,e as D,f as G,g as x,a as N,b as c,ak as Y,t as ge,B as We,aV as Xe,bs as T,ae as Se,O as be,ac as he,af as pe,ag as ke,bt as Je,h as Ce,bu as we,bv as Ye,bw as Ze,w as et,i as Ae,ah as Ie,bx as tt,P as Ve,ad as Pe,ai as Le,aj as Be,by as at,v as nt,bz as lt,F as Z,M as re,u as st,d as oe,bA as it,Q as rt,S as ot,bB as ut,bC as M,o as ct,bD as dt,aA as vt,au as ue,$ as J,a0 as ce,a1 as de,a6 as ft,a7 as yt}from"./index-BHzPgH2J.js";import{e as ve,b as mt,d as gt}from"./VDivider-CnS8Y1Zb.js";import{a as St}from"./index-DLx-KgOd.js";import{u as bt}from"./ssrBoot-7hoALQc5.js";import{M as ht}from"./transition-zS3yGrDV.js";import"./VImg-i8uxgNTt.js";const ee=Symbol.for("vuetify:list");function Oe(){const e=R(ee,{hasPrepend:F(!1),updateHasPrepend:()=>null}),s={hasPrepend:F(!1),updateHasPrepend:a=>{a&&(s.hasPrepend.value=a)}};return E(ee,s),e}function xe(){return R(ee,null)}const ae=e=>{const s={activate:a=>{let{id:n,value:l,activated:t}=a;return n=w(n),e&&!l&&t.size===1&&t.has(n)||(l?t.add(n):t.delete(n)),t},in:(a,n,l)=>{let t=new Set;if(a!=null)for(const i of ye(a))t=s.activate({id:i,value:!0,activated:new Set(t),children:n,parents:l});return t},out:a=>Array.from(a)};return s},_e=e=>{const s=ae(e);return{activate:n=>{let{activated:l,id:t,...i}=n;t=w(t);const o=l.has(t)?new Set([t]):new Set;return s.activate({...i,id:t,activated:o})},in:(n,l,t)=>{let i=new Set;if(n!=null){const o=ye(n);o.length&&(i=s.in(o.slice(0,1),l,t))}return i},out:(n,l,t)=>s.out(n,l,t)}},pt=e=>{const s=ae(e);return{activate:n=>{let{id:l,activated:t,children:i,...o}=n;return l=w(l),i.has(l)?t:s.activate({id:l,activated:t,children:i,...o})},in:s.in,out:s.out}},kt=e=>{const s=_e(e);return{activate:n=>{let{id:l,activated:t,children:i,...o}=n;return l=w(l),i.has(l)?t:s.activate({id:l,activated:t,children:i,...o})},in:s.in,out:s.out}},Ct={open:e=>{let{id:s,value:a,opened:n,parents:l}=e;if(a){const t=new Set;t.add(s);let i=l.get(s);for(;i!=null;)t.add(i),i=l.get(i);return t}else return n.delete(s),n},select:()=>null},Me={open:e=>{let{id:s,value:a,opened:n,parents:l}=e;if(a){let t=l.get(s);for(n.add(s);t!=null&&t!==s;)n.add(t),t=l.get(t);return n}else n.delete(s);return n},select:()=>null},wt={open:Me.open,select:e=>{let{id:s,value:a,opened:n,parents:l}=e;if(!a)return n;const t=[];let i=l.get(s);for(;i!=null;)t.push(i),i=l.get(i);return new Set(t)}},ne=e=>{const s={select:a=>{let{id:n,value:l,selected:t}=a;if(n=w(n),e&&!l){const i=Array.from(t.entries()).reduce((o,g)=>{let[y,d]=g;return d==="on"&&o.push(y),o},[]);if(i.length===1&&i[0]===n)return t}return t.set(n,l?"on":"off"),t},in:(a,n,l)=>{let t=new Map;for(const i of a||[])t=s.select({id:i,value:!0,selected:new Map(t),children:n,parents:l});return t},out:a=>{const n=[];for(const[l,t]of a.entries())t==="on"&&n.push(l);return n}};return s},Te=e=>{const s=ne(e);return{select:n=>{let{selected:l,id:t,...i}=n;t=w(t);const o=l.has(t)?new Map([[t,l.get(t)]]):new Map;return s.select({...i,id:t,selected:o})},in:(n,l,t)=>{let i=new Map;return n?.length&&(i=s.in(n.slice(0,1),l,t)),i},out:(n,l,t)=>s.out(n,l,t)}},At=e=>{const s=ne(e);return{select:n=>{let{id:l,selected:t,children:i,...o}=n;return l=w(l),i.has(l)?t:s.select({id:l,selected:t,children:i,...o})},in:s.in,out:s.out}},It=e=>{const s=Te(e);return{select:n=>{let{id:l,selected:t,children:i,...o}=n;return l=w(l),i.has(l)?t:s.select({id:l,selected:t,children:i,...o})},in:s.in,out:s.out}},Vt=e=>{const s={select:a=>{let{id:n,value:l,selected:t,children:i,parents:o}=a;n=w(n);const g=new Map(t),y=[n];for(;y.length;){const S=y.shift();t.set(S,l?"on":"off"),i.has(S)&&y.push(...i.get(S))}let d=o.get(n);for(;d;){const S=i.get(d),b=S.every(u=>t.get(u)==="on"),r=S.every(u=>!t.has(u)||t.get(u)==="off");t.set(d,b?"on":r?"off":"indeterminate"),d=o.get(d)}return e&&!l&&Array.from(t.entries()).reduce((b,r)=>{let[u,v]=r;return v==="on"&&b.push(u),b},[]).length===0?g:t},in:(a,n,l)=>{let t=new Map;for(const i of a||[])t=s.select({id:i,value:!0,selected:new Map(t),children:n,parents:l});return t},out:(a,n)=>{const l=[];for(const[t,i]of a.entries())i==="on"&&!n.has(t)&&l.push(t);return l}};return s},j=Symbol.for("vuetify:nested"),Fe={id:F(),root:{register:()=>null,unregister:()=>null,parents:C(new Map),children:C(new Map),open:()=>null,openOnSelect:()=>null,activate:()=>null,select:()=>null,activatable:C(!1),selectable:C(!1),opened:C(new Set),activated:C(new Set),selected:C(new Map),selectedValues:C([])}},Pt=P({activatable:Boolean,selectable:Boolean,activeStrategy:[String,Function,Object],selectStrategy:[String,Function,Object],openStrategy:[String,Object],opened:null,activated:null,selected:null,mandatory:Boolean},"nested"),Lt=e=>{let s=!1;const a=C(new Map),n=C(new Map),l=X(e,"opened",e.opened,r=>new Set(r),r=>[...r.values()]),t=f(()=>{if(typeof e.activeStrategy=="object")return e.activeStrategy;if(typeof e.activeStrategy=="function")return e.activeStrategy(e.mandatory);switch(e.activeStrategy){case"leaf":return pt(e.mandatory);case"single-leaf":return kt(e.mandatory);case"independent":return ae(e.mandatory);case"single-independent":default:return _e(e.mandatory)}}),i=f(()=>{if(typeof e.selectStrategy=="object")return e.selectStrategy;if(typeof e.selectStrategy=="function")return e.selectStrategy(e.mandatory);switch(e.selectStrategy){case"single-leaf":return It(e.mandatory);case"leaf":return At(e.mandatory);case"independent":return ne(e.mandatory);case"single-independent":return Te(e.mandatory);case"classic":default:return Vt(e.mandatory)}}),o=f(()=>{if(typeof e.openStrategy=="object")return e.openStrategy;switch(e.openStrategy){case"list":return wt;case"single":return Ct;case"multiple":default:return Me}}),g=X(e,"activated",e.activated,r=>t.value.in(r,a.value,n.value),r=>t.value.out(r,a.value,n.value)),y=X(e,"selected",e.selected,r=>i.value.in(r,a.value,n.value),r=>i.value.out(r,a.value,n.value));me(()=>{s=!0});function d(r){const u=[];let v=r;for(;v!=null;)u.unshift(v),v=n.value.get(v);return u}const S=qe("nested"),b={id:F(),root:{opened:l,activatable:h(e,"activatable"),selectable:h(e,"selectable"),activated:g,selected:y,selectedValues:f(()=>{const r=[];for(const[u,v]of y.value.entries())v==="on"&&r.push(u);return r}),register:(r,u,v)=>{u&&r!==u&&n.value.set(r,u),v&&a.value.set(r,[]),u!=null&&a.value.set(u,[...a.value.get(u)||[],r])},unregister:r=>{if(s)return;a.value.delete(r);const u=n.value.get(r);if(u){const v=a.value.get(u)??[];a.value.set(u,v.filter(m=>m!==r))}n.value.delete(r)},open:(r,u,v)=>{S.emit("click:open",{id:r,value:u,path:d(r),event:v});const m=o.value.open({id:r,value:u,opened:new Set(l.value),children:a.value,parents:n.value,event:v});m&&(l.value=m)},openOnSelect:(r,u,v)=>{const m=o.value.select({id:r,value:u,selected:new Map(y.value),opened:new Set(l.value),children:a.value,parents:n.value,event:v});m&&(l.value=m)},select:(r,u,v)=>{S.emit("click:select",{id:r,value:u,path:d(r),event:v});const m=i.value.select({id:r,value:u,selected:new Map(y.value),children:a.value,parents:n.value,event:v});m&&(y.value=m),b.root.openOnSelect(r,u,v)},activate:(r,u,v)=>{if(!e.activatable)return b.root.select(r,!0,v);S.emit("click:activate",{id:r,value:u,path:d(r),event:v});const m=t.value.activate({id:r,value:u,activated:new Set(g.value),children:a.value,parents:n.value,event:v});m&&(g.value=m)},children:a,parents:n}};return E(j,b),b.root},je=(e,s)=>{const a=R(j,Fe),n=Symbol(ze()),l=f(()=>e.value!==void 0?e.value:n),t={...a,id:l,open:(i,o)=>a.root.open(l.value,i,o),openOnSelect:(i,o)=>a.root.openOnSelect(l.value,i,o),isOpen:f(()=>a.root.opened.value.has(l.value)),parent:f(()=>a.root.parents.value.get(l.value)),activate:(i,o)=>a.root.activate(l.value,i,o),isActivated:f(()=>a.root.activated.value.has(w(l.value))),select:(i,o)=>a.root.select(l.value,i,o),isSelected:f(()=>a.root.selected.value.get(w(l.value))==="on"),isIndeterminate:f(()=>a.root.selected.value.get(l.value)==="indeterminate"),isLeaf:f(()=>!a.root.children.value.get(l.value)),isGroupActivator:a.isGroupActivator};return!a.isGroupActivator&&a.root.register(l.value,a.id.value,s),me(()=>{!a.isGroupActivator&&a.root.unregister(l.value)}),s&&E(j,t),t},Bt=()=>{const e=R(j,Fe);E(j,{...e,isGroupActivator:!0})},Ot=Qe({name:"VListGroupActivator",setup(e,s){let{slots:a}=s;return Bt(),()=>a.default?.()}}),xt=P({activeColor:String,baseColor:String,color:String,collapseIcon:{type:O,default:"$collapse"},expandIcon:{type:O,default:"$expand"},prependIcon:O,appendIcon:O,fluid:Boolean,subgroup:Boolean,title:String,value:null,...D(),...G()},"VListGroup"),fe=x()({name:"VListGroup",props:xt(),setup(e,s){let{slots:a}=s;const{isOpen:n,open:l,id:t}=je(h(e,"value"),!0),i=f(()=>`v-list-group--id-${String(t.value)}`),o=xe(),{isBooted:g}=bt();function y(r){r.stopPropagation(),l(!n.value,r)}const d=f(()=>({onClick:y,class:"v-list-group__header",id:i.value})),S=f(()=>n.value?e.collapseIcon:e.expandIcon),b=f(()=>({VListItem:{active:n.value,activeColor:e.activeColor,baseColor:e.baseColor,color:e.color,prependIcon:e.prependIcon||e.subgroup&&S.value,appendIcon:e.appendIcon||!e.subgroup&&S.value,title:e.title,value:e.value}}));return N(()=>c(e.tag,{class:["v-list-group",{"v-list-group--prepend":o?.hasPrepend.value,"v-list-group--fluid":e.fluid,"v-list-group--subgroup":e.subgroup,"v-list-group--open":n.value},e.class],style:e.style},{default:()=>[a.activator&&c(Y,{defaults:b.value},{default:()=>[c(Ot,null,{default:()=>[a.activator({props:d.value,isOpen:n.value})]})]}),c(ht,{transition:{component:St},disabled:!g.value},{default:()=>[ge(c("div",{class:"v-list-group__items",role:"group","aria-labelledby":i.value},[a.default?.()]),[[We,n.value]])]})]})),{isOpen:n}}}),_t=P({opacity:[Number,String],...D(),...G()},"VListItemSubtitle"),Mt=x()({name:"VListItemSubtitle",props:_t(),setup(e,s){let{slots:a}=s;return N(()=>c(e.tag,{class:["v-list-item-subtitle",e.class],style:[{"--v-list-item-subtitle-opacity":e.opacity},e.style]},a)),{}}}),Tt=Xe("v-list-item-title"),Ft=P({active:{type:Boolean,default:void 0},activeClass:String,activeColor:String,appendAvatar:String,appendIcon:O,baseColor:String,disabled:Boolean,lines:[Boolean,String],link:{type:Boolean,default:void 0},nav:Boolean,prependAvatar:String,prependIcon:O,ripple:{type:[Boolean,Object],default:!0},slim:Boolean,subtitle:[String,Number],title:[String,Number],value:null,onClick:T(),onClickOnce:T(),...Se(),...D(),...be(),...he(),...pe(),...ke(),...Je(),...G(),...Ce(),...we({variant:"text"})},"VListItem"),te=x()({name:"VListItem",directives:{Ripple:Ye},props:Ft(),emits:{click:e=>!0},setup(e,s){let{attrs:a,slots:n,emit:l}=s;const t=Ze(e,a),i=f(()=>e.value===void 0?t.href.value:e.value),{activate:o,isActivated:g,select:y,isSelected:d,isIndeterminate:S,isGroupActivator:b,root:r,parent:u,openOnSelect:v}=je(i,!1),m=xe(),I=f(()=>e.active!==!1&&(e.active||t.isActive?.value||(r.activatable.value?g.value:d.value))),_=f(()=>e.link!==!1&&t.isLink.value),A=f(()=>!e.disabled&&e.link!==!1&&(e.link||t.isClickable.value||!!m&&(r.selectable.value||r.activatable.value||e.value!=null))),L=f(()=>e.rounded||e.nav),B=f(()=>e.color??e.activeColor),$=f(()=>({color:I.value?B.value??e.baseColor:e.baseColor,variant:e.variant}));et(()=>t.isActive?.value,k=>{k&&u.value!=null&&r.open(u.value,!0),k&&v(k)},{immediate:!0});const{themeClasses:U}=Ae(e),{borderClasses:K}=Ie(e),{colorClasses:H,colorStyles:q,variantClasses:V}=tt($),{densityClasses:p}=Ve(e),{dimensionStyles:z}=Pe(e),{elevationClasses:Ne}=Le(e),{roundedClasses:Re}=Be(L),Ee=f(()=>e.lines?`v-list-item--${e.lines}-line`:void 0),Q=f(()=>({isActive:I.value,select:y,isSelected:d.value,isIndeterminate:S.value}));function le(k){l("click",k),A.value&&(t.navigate?.(k),!b&&(r.activatable.value?o(!g.value,k):(r.selectable.value||e.value!=null)&&y(!d.value,k)))}function $e(k){(k.key==="Enter"||k.key===" ")&&(k.preventDefault(),le(k))}return N(()=>{const k=_.value?"a":e.tag,Ue=n.title||e.title!=null,Ke=n.subtitle||e.subtitle!=null,se=!!(e.appendAvatar||e.appendIcon),He=!!(se||n.append),ie=!!(e.prependAvatar||e.prependIcon),W=!!(ie||n.prepend);return m?.updateHasPrepend(W),e.activeColor&&at("active-color",["color","base-color"]),ge(c(k,{class:["v-list-item",{"v-list-item--active":I.value,"v-list-item--disabled":e.disabled,"v-list-item--link":A.value,"v-list-item--nav":e.nav,"v-list-item--prepend":!W&&m?.hasPrepend.value,"v-list-item--slim":e.slim,[`${e.activeClass}`]:e.activeClass&&I.value},U.value,K.value,H.value,p.value,Ne.value,Ee.value,Re.value,V.value,e.class],style:[q.value,z.value,e.style],href:t.href.value,tabindex:A.value?m?-2:0:void 0,onClick:le,onKeydown:A.value&&!_.value&&$e},{default:()=>[lt(A.value||I.value,"v-list-item"),W&&c("div",{key:"prepend",class:"v-list-item__prepend"},[n.prepend?c(Y,{key:"prepend-defaults",disabled:!ie,defaults:{VAvatar:{density:e.density,image:e.prependAvatar},VIcon:{density:e.density,icon:e.prependIcon},VListItemAction:{start:!0}}},{default:()=>[n.prepend?.(Q.value)]}):c(Z,null,[e.prependAvatar&&c(ve,{key:"prepend-avatar",density:e.density,image:e.prependAvatar},null),e.prependIcon&&c(re,{key:"prepend-icon",density:e.density,icon:e.prependIcon},null)]),c("div",{class:"v-list-item__spacer"},null)]),c("div",{class:"v-list-item__content","data-no-activator":""},[Ue&&c(Tt,{key:"title"},{default:()=>[n.title?.({title:e.title})??e.title]}),Ke&&c(Mt,{key:"subtitle"},{default:()=>[n.subtitle?.({subtitle:e.subtitle})??e.subtitle]}),n.default?.(Q.value)]),He&&c("div",{key:"append",class:"v-list-item__append"},[n.append?c(Y,{key:"append-defaults",disabled:!se,defaults:{VAvatar:{density:e.density,image:e.appendAvatar},VIcon:{density:e.density,icon:e.appendIcon},VListItemAction:{end:!0}}},{default:()=>[n.append?.(Q.value)]}):c(Z,null,[e.appendIcon&&c(re,{key:"append-icon",density:e.density,icon:e.appendIcon},null),e.appendAvatar&&c(ve,{key:"append-avatar",density:e.density,image:e.appendAvatar},null)]),c("div",{class:"v-list-item__spacer"},null)])]}),[[nt("ripple"),A.value&&e.ripple]])}),{activate:o,isActivated:g,isGroupActivator:b,isSelected:d,list:m,select:y}}}),jt=P({color:String,inset:Boolean,sticky:Boolean,title:String,...D(),...G()},"VListSubheader"),Dt=x()({name:"VListSubheader",props:jt(),setup(e,s){let{slots:a}=s;const{textColorClasses:n,textColorStyles:l}=st(h(e,"color"));return N(()=>{const t=!!(a.default||e.title);return c(e.tag,{class:["v-list-subheader",{"v-list-subheader--inset":e.inset,"v-list-subheader--sticky":e.sticky},n.value,e.class],style:[{textColorStyles:l},e.style]},{default:()=>[t&&c("div",{class:"v-list-subheader__text"},[a.default?.()??e.title])]})}),{}}}),Gt=P({items:Array,returnObject:Boolean},"VListChildren"),De=x()({name:"VListChildren",props:Gt(),setup(e,s){let{slots:a}=s;return Oe(),()=>a.default?.()??e.items?.map(n=>{let{children:l,props:t,type:i,raw:o}=n;if(i==="divider")return a.divider?.({props:t})??c(mt,t,null);if(i==="subheader")return a.subheader?.({props:t})??c(Dt,t,null);const g={subtitle:a.subtitle?d=>a.subtitle?.({...d,item:o}):void 0,prepend:a.prepend?d=>a.prepend?.({...d,item:o}):void 0,append:a.append?d=>a.append?.({...d,item:o}):void 0,title:a.title?d=>a.title?.({...d,item:o}):void 0},y=fe.filterProps(t);return l?c(fe,oe({value:t?.value},y),{activator:d=>{let{props:S}=d;const b={...t,...S,value:e.returnObject?o:t.value};return a.header?a.header({props:b}):c(te,b,g)},default:()=>c(De,{items:l,returnObject:e.returnObject},a)}):a.item?a.item({props:t}):c(te,oe(t,{value:e.returnObject?o:t.value}),g)})}}),Nt=P({items:{type:Array,default:()=>[]},itemTitle:{type:[String,Array,Function],default:"title"},itemValue:{type:[String,Array,Function],default:"value"},itemChildren:{type:[Boolean,String,Array,Function],default:"children"},itemProps:{type:[Boolean,String,Array,Function],default:"props"},returnObject:Boolean,valueComparator:{type:Function,default:it}},"list-items");function Rt(e){return typeof e=="string"||typeof e=="number"||typeof e=="boolean"}function Et(e,s){const a=M(s,e.itemType,"item"),n=Rt(s)?s:M(s,e.itemTitle),l=M(s,e.itemValue,void 0),t=M(s,e.itemChildren),i=e.itemProps===!0?ct(s,["children"]):M(s,e.itemProps),o={title:n,value:l,...i};return{type:a,title:o.title,value:o.value,props:o,children:a==="item"&&t?Ge(e,t):void 0,raw:s}}function Ge(e,s){const a=[];for(const n of s)a.push(Et(e,n));return a}function $t(e){return{items:f(()=>Ge(e,e.items))}}const Ut=P({baseColor:String,activeColor:String,activeClass:String,bgColor:String,disabled:Boolean,expandIcon:String,collapseIcon:String,lines:{type:[Boolean,String],default:"one"},slim:Boolean,nav:Boolean,"onClick:open":T(),"onClick:select":T(),"onUpdate:opened":T(),...Pt({selectStrategy:"single-leaf",openStrategy:"list"}),...Se(),...D(),...be(),...he(),...pe(),itemType:{type:String,default:"type"},...Nt(),...ke(),...G(),...Ce(),...we({variant:"text"})},"VList"),Kt=x()({name:"VList",props:Ut(),emits:{"update:selected":e=>!0,"update:activated":e=>!0,"update:opened":e=>!0,"click:open":e=>!0,"click:activate":e=>!0,"click:select":e=>!0},setup(e,s){let{slots:a}=s;const{items:n}=$t(e),{themeClasses:l}=Ae(e),{backgroundColorClasses:t,backgroundColorStyles:i}=rt(h(e,"bgColor")),{borderClasses:o}=Ie(e),{densityClasses:g}=Ve(e),{dimensionStyles:y}=Pe(e),{elevationClasses:d}=Le(e),{roundedClasses:S}=Be(e),{children:b,open:r,parents:u,select:v}=Lt(e),m=f(()=>e.lines?`v-list--${e.lines}-line`:void 0),I=h(e,"activeColor"),_=h(e,"baseColor"),A=h(e,"color");Oe(),ot({VListGroup:{activeColor:I,baseColor:_,color:A,expandIcon:h(e,"expandIcon"),collapseIcon:h(e,"collapseIcon")},VListItem:{activeClass:h(e,"activeClass"),activeColor:I,baseColor:_,color:A,density:h(e,"density"),disabled:h(e,"disabled"),lines:h(e,"lines"),nav:h(e,"nav"),slim:h(e,"slim"),variant:h(e,"variant")}});const L=F(!1),B=C();function $(p){L.value=!0}function U(p){L.value=!1}function K(p){!L.value&&!(p.relatedTarget&&B.value?.contains(p.relatedTarget))&&V()}function H(p){const z=p.target;if(!(!B.value||["INPUT","TEXTAREA"].includes(z.tagName))){if(p.key==="ArrowDown")V("next");else if(p.key==="ArrowUp")V("prev");else if(p.key==="Home")V("first");else if(p.key==="End")V("last");else return;p.preventDefault()}}function q(p){L.value=!0}function V(p){if(B.value)return ut(B.value,p)}return N(()=>c(e.tag,{ref:B,class:["v-list",{"v-list--disabled":e.disabled,"v-list--nav":e.nav,"v-list--slim":e.slim},l.value,t.value,o.value,g.value,d.value,m.value,S.value,e.class],style:[i.value,y.value,e.style],tabindex:e.disabled||L.value?-1:0,role:"listbox","aria-activedescendant":void 0,onFocusin:$,onFocusout:U,onFocus:K,onKeydown:H,onMousedown:q},{default:()=>[c(De,{items:n.value,returnObject:e.returnObject},a)]})),{open:r,select:v,focus:V,children:b,parents:u}}}),Jt=dt({__name:"List",props:{outlined:Boolean},setup(e){const{stac:s,selectedStac:a}=vt(ue.stac.useSTAcStore()),{loadSelectedSTAC:n}=ue.stac.useSTAcStore(),l=f(()=>s.value.filter(i=>i?.rel=="child")),t=async i=>{const o=l.value[i];await n(o.href),console.log(a.value)};return(i,o)=>(J(),ce(gt,{class:"mx-auto d-flex flex-column overflow-auto fill-height"},{default:de(()=>[c(Kt,{lines:"one",class:"overflow-y-auto overflow-x-hidden"},{default:de(()=>[(J(!0),ft(Z,null,yt(l.value,(g,y)=>(J(),ce(te,{key:y,onClick:d=>t(y),title:g.title,slim:"",variant:e.outlined?"outlined":"flat",color:"#fff"},null,8,["onClick","title","variant"]))),128))]),_:1})]),_:1}))}});export{Jt as default}; diff --git a/pr-preview/pr-17/assets/MobileLayout-Bse6a_iI.js b/pr-preview/pr-17/assets/MobileLayout-DtBtTe7v.js similarity index 98% rename from pr-preview/pr-17/assets/MobileLayout-Bse6a_iI.js rename to pr-preview/pr-17/assets/MobileLayout-DtBtTe7v.js index afb510f..03bbdeb 100644 --- a/pr-preview/pr-17/assets/MobileLayout-Bse6a_iI.js +++ b/pr-preview/pr-17/assets/MobileLayout-DtBtTe7v.js @@ -1 +1 @@ -import{k as Ie,p as R,o as Pe,m as Xe,g as $,u as Ye,r as I,c as y,a as M,V as G,b as v,F as O,d as z,e as ie,f as ue,h as Ge,i as De,j as pe,l as Ue,n as Be,s as E,w as Ee,q as je,t as q,v as Ne,x as re,y as ze,z as qe,A as Ke,B as le,C as ae,D as Qe,I as fe,E as Je,G as Ze,H as et,J as me,K as tt,L as he,M as ge,N as nt,O as ot,P as st,Q as lt,R as W,S as at,T as it,_ as ut,U as rt,W as ct,X as be,Y as dt,Z as vt,$ as C,a0 as A,a1 as F,a2 as ye,a3 as X,a4 as Se,a5 as se,a6 as Y,a7 as we,a8 as xe,a9 as ft,aa as mt}from"./index-BHzPgH2J.js";import{f as ht,a as gt,s as bt,m as yt,u as St,b as wt}from"./forwardRefs-BoZnhoLd.js";import{u as xt}from"./ssrBoot-7hoALQc5.js";import{M as kt}from"./transition-zS3yGrDV.js";import{V as ke}from"./index-DLx-KgOd.js";import{V as Tt}from"./VMain-CoJ_6Ucg.js";const Vt=e=>{const{touchstartX:n,touchendX:s,touchstartY:t,touchendY:l}=e,u=.5,o=16;e.offsetX=s-n,e.offsetY=l-t,Math.abs(e.offsetY)n+o&&e.right(e)),Math.abs(e.offsetX)t+o&&e.down(e))};function Ct(e,n){const s=e.changedTouches[0];n.touchstartX=s.clientX,n.touchstartY=s.clientY,n.start?.({originalEvent:e,...n})}function _t(e,n){const s=e.changedTouches[0];n.touchendX=s.clientX,n.touchendY=s.clientY,n.end?.({originalEvent:e,...n}),Vt(n)}function It(e,n){const s=e.changedTouches[0];n.touchmoveX=s.clientX,n.touchmoveY=s.clientY,n.move?.({originalEvent:e,...n})}function Pt(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};const n={touchstartX:0,touchstartY:0,touchendX:0,touchendY:0,touchmoveX:0,touchmoveY:0,offsetX:0,offsetY:0,left:e.left,right:e.right,up:e.up,down:e.down,start:e.start,move:e.move,end:e.end};return{touchstart:s=>Ct(s,n),touchend:s=>_t(s,n),touchmove:s=>It(s,n)}}function pt(e,n){const s=n.value,t=s?.parent?e.parentElement:e,l=s?.options??{passive:!0},u=n.instance?.$.uid;if(!t||!u)return;const o=Pt(n.value);t._touchHandlers=t._touchHandlers??Object.create(null),t._touchHandlers[u]=o,Ie(o).forEach(f=>{t.addEventListener(f,o[f],l)})}function Bt(e,n){const s=n.value?.parent?e.parentElement:e,t=n.instance?.$.uid;if(!s?._touchHandlers||!t)return;const l=s._touchHandlers[t];Ie(l).forEach(u=>{s.removeEventListener(u,l[u])}),delete s._touchHandlers[t]}const We={mounted:pt,unmounted:Bt},Et=We,ce=Symbol.for("vuetify:v-tabs"),zt=R({fixed:Boolean,sliderColor:String,hideSlider:Boolean,direction:{type:String,default:"horizontal"},...Pe(Xe({selectedClass:"v-tab--selected",variant:"text"}),["active","block","flat","location","position","symbol"])},"VTab"),Re=$()({name:"VTab",props:zt(),setup(e,n){let{slots:s,attrs:t}=n;const{textColorClasses:l,textColorStyles:u}=Ye(e,"sliderColor"),o=I(),f=I(),r=y(()=>e.direction==="horizontal"),h=y(()=>o.value?.group?.isSelected.value??!1);function x(m){let{value:a}=m;if(a){const g=o.value?.$el.parentElement?.querySelector(".v-tab--selected .v-tab__slider"),d=f.value;if(!g||!d)return;const _=getComputedStyle(g).color,T=g.getBoundingClientRect(),V=d.getBoundingClientRect(),P=r.value?"x":"y",p=r.value?"X":"Y",b=r.value?"right":"bottom",S=r.value?"width":"height",k=T[P],H=V[P],B=k>H?T[b]-V[b]:T[P]-V[P],K=Math.sign(B)>0?r.value?"right":"bottom":Math.sign(B)<0?r.value?"left":"top":"center",Q=(Math.abs(B)+(Math.sign(B)<0?T[S]:V[S]))/Math.max(T[S],V[S])||0,j=T[S]/V[S]||0,N=1.5;gt(d,{backgroundColor:[_,"currentcolor"],transform:[`translate${p}(${B}px) scale${p}(${j})`,`translate${p}(${B/N}px) scale${p}(${(Q-1)/N+1})`,"none"],transformOrigin:Array(3).fill(K)},{duration:225,easing:bt})}}return M(()=>{const m=G.filterProps(e);return v(G,z({symbol:ce,ref:o,class:["v-tab",e.class],style:e.style,tabindex:h.value?0:-1,role:"tab","aria-selected":String(h.value),active:!1},m,t,{block:e.fixed,maxWidth:e.fixed?300:void 0,"onGroup:selected":x}),{...s,default:()=>v(O,null,[s.default?.()??e.text,!e.hideSlider&&v("div",{ref:f,class:["v-tab__slider",l.value],style:u.value},null)])})}),ht({},o)}}),$e=Symbol.for("vuetify:v-window"),Me=Symbol.for("vuetify:v-window-group"),He=R({continuous:Boolean,nextIcon:{type:[Boolean,String,Function,Object],default:"$next"},prevIcon:{type:[Boolean,String,Function,Object],default:"$prev"},reverse:Boolean,showArrows:{type:[Boolean,String],validator:e=>typeof e=="boolean"||e==="hover"},touch:{type:[Object,Boolean],default:void 0},direction:{type:String,default:"horizontal"},modelValue:null,disabled:Boolean,selectedClass:{type:String,default:"v-window-item--active"},mandatory:{type:[Boolean,String],default:"force"},...ie(),...ue(),...Ge()},"VWindow"),Te=$()({name:"VWindow",directives:{Touch:We},props:He(),emits:{"update:modelValue":e=>!0},setup(e,n){let{slots:s}=n;const{themeClasses:t}=De(e),{isRtl:l}=pe(),{t:u}=Ue(),o=Be(e,Me),f=I(),r=y(()=>l.value?!e.reverse:e.reverse),h=E(!1),x=y(()=>{const b=e.direction==="vertical"?"y":"x",k=(r.value?!h.value:h.value)?"-reverse":"";return`v-window-${b}${k}-transition`}),m=E(0),a=I(void 0),g=y(()=>o.items.value.findIndex(b=>o.selected.value.includes(b.id)));Ee(g,(b,S)=>{const k=o.items.value.length,H=k-1;k<=2?h.value=be.continuous||g.value!==0),_=y(()=>e.continuous||g.value!==o.items.value.length-1);function T(){d.value&&o.prev()}function V(){_.value&&o.next()}const P=y(()=>{const b=[],S={icon:l.value?e.nextIcon:e.prevIcon,class:`v-window__${r.value?"right":"left"}`,onClick:o.prev,"aria-label":u("$vuetify.carousel.prev")};b.push(d.value?s.prev?s.prev({props:S}):v(G,S,null):v("div",null,null));const k={icon:l.value?e.prevIcon:e.nextIcon,class:`v-window__${r.value?"left":"right"}`,onClick:o.next,"aria-label":u("$vuetify.carousel.next")};return b.push(_.value?s.next?s.next({props:k}):v(G,k,null):v("div",null,null)),b}),p=y(()=>e.touch===!1?e.touch:{...{left:()=>{r.value?T():V()},right:()=>{r.value?V():T()},start:S=>{let{originalEvent:k}=S;k.stopPropagation()}},...e.touch===!0?{}:e.touch});return M(()=>q(v(e.tag,{ref:f,class:["v-window",{"v-window--show-arrows-on-hover":e.showArrows==="hover"},t.value,e.class],style:e.style},{default:()=>[v("div",{class:"v-window__container",style:{height:a.value}},[s.default?.({group:o}),e.showArrows!==!1&&v("div",{class:"v-window__controls"},[P.value])]),s.additional?.({group:o})]}),[[Ne("touch"),p.value]])),{group:o}}}),Wt=R({...Pe(He(),["continuous","nextIcon","prevIcon","showArrows","touch","mandatory"])},"VTabsWindow"),Rt=$()({name:"VTabsWindow",props:Wt(),emits:{"update:modelValue":e=>!0},setup(e,n){let{slots:s}=n;const t=re(ce,null),l=ze(e,"modelValue"),u=y({get(){return l.value!=null||!t?l.value:t.items.value.find(o=>t.selected.value.includes(o.id))?.value},set(o){l.value=o}});return M(()=>{const o=Te.filterProps(e);return v(Te,z({_as:"VTabsWindow"},o,{modelValue:u.value,"onUpdate:modelValue":f=>u.value=f,class:["v-tabs-window",e.class],style:e.style,mandatory:!1,touch:!1}),s)}),{}}}),Ae=R({reverseTransition:{type:[Boolean,String],default:void 0},transition:{type:[Boolean,String],default:void 0},...ie(),...qe(),...yt()},"VWindowItem"),Ve=$()({name:"VWindowItem",directives:{Touch:Et},props:Ae(),emits:{"group:selected":e=>!0},setup(e,n){let{slots:s}=n;const t=re($e),l=Ke(e,Me),{isBooted:u}=xt();if(!t||!l)throw new Error("[Vuetify] VWindowItem must be used inside VWindow");const o=E(!1),f=y(()=>u.value&&(t.isReversed.value?e.reverseTransition!==!1:e.transition!==!1));function r(){!o.value||!t||(o.value=!1,t.transitionCount.value>0&&(t.transitionCount.value-=1,t.transitionCount.value===0&&(t.transitionHeight.value=void 0)))}function h(){o.value||!t||(o.value=!0,t.transitionCount.value===0&&(t.transitionHeight.value=ae(t.rootRef.value?.clientHeight)),t.transitionCount.value+=1)}function x(){r()}function m(d){o.value&&Qe(()=>{!f.value||!o.value||!t||(t.transitionHeight.value=ae(d.clientHeight))})}const a=y(()=>{const d=t.isReversed.value?e.reverseTransition:e.transition;return f.value?{name:typeof d!="string"?t.transition.value:d,onBeforeEnter:h,onAfterEnter:r,onEnterCancelled:x,onBeforeLeave:h,onAfterLeave:r,onLeaveCancelled:x,onEnter:m}:!1}),{hasContent:g}=St(e,l.isSelected);return M(()=>v(kt,{transition:a.value,disabled:!u.value},{default:()=>[q(v("div",{class:["v-window-item",l.selectedClass.value,e.class],style:e.style},[g.value&&s.default?.()]),[[le,l.isSelected.value]])]})),{groupItem:l}}}),$t=R({...Ae()},"VTabsWindowItem"),Mt=$()({name:"VTabsWindowItem",props:$t(),setup(e,n){let{slots:s}=n;return M(()=>{const t=Ve.filterProps(e);return v(Ve,z({_as:"VTabsWindowItem"},t,{class:["v-tabs-window-item",e.class],style:e.style}),s)}),{}}});function Ht(e){let{selectedElement:n,containerElement:s,isRtl:t,isHorizontal:l}=e;const u=D(l,s),o=Fe(l,t,s),f=D(l,n),r=Oe(l,n),h=f*.4;return o>r?r-h:o+utypeof e=="boolean"||["always","desktop","mobile"].includes(e)},...ie(),...Je({mobile:null}),...ue(),...Ze({selectedClass:"v-slide-group-item--active"})},"VSlideGroup"),_e=$()({name:"VSlideGroup",props:Le(),emits:{"update:modelValue":e=>!0},setup(e,n){let{slots:s}=n;const{isRtl:t}=pe(),{displayClasses:l,mobile:u}=et(e),o=Be(e,e.symbol),f=E(!1),r=E(0),h=E(0),x=E(0),m=y(()=>e.direction==="horizontal"),{resizeRef:a,contentRect:g}=me(),{resizeRef:d,contentRect:_}=me(),T=tt(),V=y(()=>({container:a.el,duration:200,easing:"easeOutQuart"})),P=y(()=>o.selected.value.length?o.items.value.findIndex(i=>i.id===o.selected.value[0]):-1),p=y(()=>o.selected.value.length?o.items.value.findIndex(i=>i.id===o.selected.value[o.selected.value.length-1]):-1);if(he){let i=-1;Ee(()=>[o.selected.value,g.value,_.value,m.value],()=>{cancelAnimationFrame(i),i=requestAnimationFrame(()=>{if(g.value&&_.value){const c=m.value?"width":"height";h.value=g.value[c],x.value=_.value[c],f.value=h.value+1=0&&d.el){const c=d.el.children[p.value];S(c,e.centerActive)}})})}const b=E(!1);function S(i,c){let w=0;c?w=At({containerElement:a.el,isHorizontal:m.value,selectedElement:i}):w=Ht({containerElement:a.el,isHorizontal:m.value,isRtl:t.value,selectedElement:i}),k(w)}function k(i){if(!he||!a.el)return;const c=D(m.value,a.el),w=Fe(m.value,t.value,a.el);if(!(Ce(m.value,a.el)<=c||Math.abs(i-w)<16)){if(m.value&&t.value&&a.el){const{scrollWidth:ne,offsetWidth:oe}=a.el;i=ne-oe-i}m.value?T.horizontal(i,V.value):T(i,V.value)}}function H(i){const{scrollTop:c,scrollLeft:w}=i.target;r.value=m.value?w:c}function B(i){if(b.value=!0,!(!f.value||!d.el)){for(const c of i.composedPath())for(const w of d.el.children)if(w===c){S(w);return}}}function K(i){b.value=!1}let U=!1;function Q(i){!U&&!b.value&&!(i.relatedTarget&&d.el?.contains(i.relatedTarget))&&L(),U=!1}function j(){U=!0}function N(i){if(!d.el)return;function c(w){i.preventDefault(),L(w)}m.value?i.key==="ArrowRight"?c(t.value?"prev":"next"):i.key==="ArrowLeft"&&c(t.value?"next":"prev"):i.key==="ArrowDown"?c("next"):i.key==="ArrowUp"&&c("prev"),i.key==="Home"?c("first"):i.key==="End"&&c("last")}function L(i){if(!d.el)return;let c;if(!i)c=nt(d.el)[0];else if(i==="next"){if(c=d.el.querySelector(":focus")?.nextElementSibling,!c)return L("first")}else if(i==="prev"){if(c=d.el.querySelector(":focus")?.previousElementSibling,!c)return L("last")}else i==="first"?c=d.el.firstElementChild:i==="last"&&(c=d.el.lastElementChild);c&&c.focus({preventScroll:!0})}function J(i){const c=m.value&&t.value?-1:1,w=(i==="prev"?-c:c)*h.value;let te=r.value+w;if(m.value&&t.value&&a.el){const{scrollWidth:ne,offsetWidth:oe}=a.el;te+=ne-oe}k(te)}const Z=y(()=>({next:o.next,prev:o.prev,select:o.select,isSelected:o.isSelected})),ee=y(()=>{switch(e.showArrows){case"always":return!0;case"desktop":return!u.value;case!0:return f.value||Math.abs(r.value)>0;case"mobile":return u.value||f.value||Math.abs(r.value)>0;default:return!u.value&&(f.value||Math.abs(r.value)>0)}}),de=y(()=>Math.abs(r.value)>1),ve=y(()=>{if(!a.value)return!1;const i=Ce(m.value,a.el),c=Ft(m.value,a.el);return i-c-Math.abs(r.value)>1});return M(()=>v(e.tag,{class:["v-slide-group",{"v-slide-group--vertical":!m.value,"v-slide-group--has-affixes":ee.value,"v-slide-group--is-overflowing":f.value},l.value,e.class],style:e.style,tabindex:b.value||o.selected.value.length?-1:0,onFocus:Q},{default:()=>[ee.value&&v("div",{key:"prev",class:["v-slide-group__prev",{"v-slide-group__prev--disabled":!de.value}],onMousedown:j,onClick:()=>de.value&&J("prev")},[s.prev?.(Z.value)??v(ke,null,{default:()=>[v(ge,{icon:t.value?e.nextIcon:e.prevIcon},null)]})]),v("div",{key:"container",ref:a,class:"v-slide-group__container",onScroll:H},[v("div",{ref:d,class:"v-slide-group__content",onFocusin:B,onFocusout:K,onKeydown:N},[s.default?.(Z.value)])]),ee.value&&v("div",{key:"next",class:["v-slide-group__next",{"v-slide-group__next--disabled":!ve.value}],onMousedown:j,onClick:()=>ve.value&&J("next")},[s.next?.(Z.value)??v(ke,null,{default:()=>[v(ge,{icon:t.value?e.prevIcon:e.nextIcon},null)]})])]})),{selected:o.selected,scrollTo:J,scrollOffset:r,focus:L}}});function Lt(e){return e?e.map(n=>it(n)?n:{text:n,value:n}):[]}const Xt=R({alignTabs:{type:String,default:"start"},color:String,fixedTabs:Boolean,items:{type:Array,default:()=>[]},stacked:Boolean,bgColor:String,grow:Boolean,height:{type:[Number,String],default:void 0},hideSlider:Boolean,sliderColor:String,...Le({mandatory:"force",selectedClass:"v-tab-item--selected"}),...ot(),...ue()},"VTabs"),Yt=$()({name:"VTabs",props:Xt(),emits:{"update:modelValue":e=>!0},setup(e,n){let{attrs:s,slots:t}=n;const l=ze(e,"modelValue"),u=y(()=>Lt(e.items)),{densityClasses:o}=st(e),{backgroundColorClasses:f,backgroundColorStyles:r}=lt(W(e,"bgColor")),{scopeId:h}=wt();return at({VTab:{color:W(e,"color"),direction:W(e,"direction"),stacked:W(e,"stacked"),fixed:W(e,"fixedTabs"),sliderColor:W(e,"sliderColor"),hideSlider:W(e,"hideSlider")}}),M(()=>{const x=_e.filterProps(e),m=!!(t.window||e.items.length>0);return v(O,null,[v(_e,z(x,{modelValue:l.value,"onUpdate:modelValue":a=>l.value=a,class:["v-tabs",`v-tabs--${e.direction}`,`v-tabs--align-tabs-${e.alignTabs}`,{"v-tabs--fixed-tabs":e.fixedTabs,"v-tabs--grow":e.grow,"v-tabs--stacked":e.stacked},o.value,f.value,e.class],style:[{"--v-tabs-height":ae(e.height)},r.value,e.style],role:"tablist",symbol:ce},h,s),{default:()=>[t.default?.()??u.value.map(a=>t.tab?.({item:a})??v(Re,z(a,{key:a.text,value:a.value}),{default:t[`tab.${a.value}`]?()=>t[`tab.${a.value}`]?.({item:a}):void 0}))]}),m&&v(Rt,z({modelValue:l.value,"onUpdate:modelValue":a=>l.value=a,key:"tabs-window"},h),{default:()=>[u.value.map(a=>t.item?.({item:a})??v(Mt,{value:a.value},{default:()=>t[`item.${a.value}`]?.({item:a})})),t.window?.()]})])}),{}}}),Gt={key:0,id:"overlay",class:"pa-2 panel bg-surface"},Dt={class:"component-container"},Ut={__name:"MobileLayout",setup(e){rt(m=>({fbf7b91a:h.value,"2c845582":r.value,fdee920e:x.value}));const n=re(ct),s=n.template.widgets,t=be(s),[l]=be([n.template?.background]),{mainRect:u}=dt(),o=I(-1),f=I(null),r=I(""),h=I(""),x=I("");return vt(()=>{h.value=u.value.top+"px",x.value=(u.value.bottom||48)+"px",r.value=u.value.bottom+(f.value?.$el?.clientHeight??0)+"px"}),(m,a)=>(C(),A(Tt,{class:"overflow-hidden main"},{default:F(()=>[(C(),A(ye,{suspensible:""},{default:F(()=>[X(l).component?(C(),A(Se(X(l).component),z({key:0,id:"bg-widget"},X(l).props),null,16)):se("v-if",!0)]),_:1})),(C(!0),Y(O,null,we(X(t),(g,d)=>(C(),Y(O,{key:d},[g.value.component?q((C(),Y("div",Gt,[v(G,{icon:"",variant:"text",class:"close-btn",onClick:a[0]||(a[0]=_=>o.value=-1)},{default:F(()=>[xe("✕")]),_:1}),(C(),A(ye,{suspensible:""},{default:F(()=>[q(ft("div",Dt,[(C(),A(Se(g.value.component),z({key:g.value.id,ref_for:!0},g.value.props),null,16))],512),[[le,o.value===d]])]),_:2},1024))],512)),[[le,o.value===d]]):se("v-if",!0)],64))),128)),v(Yt,{ref_key:"tabs",ref:f,"align-tabs":"center","bg-color":"surface",class:"tabs","show-arrows":"",modelValue:o.value,"onUpdate:modelValue":a[1]||(a[1]=g=>o.value=g)},{default:F(()=>[(C(!0),Y(O,null,we(X(t),(g,d)=>(C(),Y(O,{key:d},[g.value.component?(C(),A(Re,{key:0,value:d},{default:F(()=>[xe(mt(g.value.title),1)]),_:2},1032,["value"])):se("v-if",!0)],64))),128))]),_:1},8,["modelValue"])]),_:1}))}},Zt=ut(Ut,[["__scopeId","data-v-e69b9875"]]);export{Zt as default}; +import{k as Ie,p as R,o as Pe,m as Xe,g as $,u as Ye,r as I,c as y,a as M,V as G,b as v,F as O,d as z,e as ie,f as ue,h as Ge,i as De,j as pe,l as Ue,n as Be,s as E,w as Ee,q as je,t as q,v as Ne,x as re,y as ze,z as qe,A as Ke,B as le,C as ae,D as Qe,I as fe,E as Je,G as Ze,H as et,J as me,K as tt,L as he,M as ge,N as nt,O as ot,P as st,Q as lt,R as W,S as at,T as it,_ as ut,U as rt,W as ct,X as be,Y as dt,Z as vt,$ as C,a0 as A,a1 as F,a2 as ye,a3 as X,a4 as Se,a5 as se,a6 as Y,a7 as we,a8 as xe,a9 as ft,aa as mt}from"./index-Dvu417lt.js";import{f as ht,a as gt,s as bt,m as yt,u as St,b as wt}from"./forwardRefs-DzUtZcD3.js";import{u as xt}from"./ssrBoot-Uu_-yAhn.js";import{M as kt}from"./transition-BKtsYhmO.js";import{V as ke}from"./index-CIIeHcTL.js";import{V as Tt}from"./VMain-CoSaaYTf.js";const Vt=e=>{const{touchstartX:n,touchendX:s,touchstartY:t,touchendY:l}=e,u=.5,o=16;e.offsetX=s-n,e.offsetY=l-t,Math.abs(e.offsetY)n+o&&e.right(e)),Math.abs(e.offsetX)t+o&&e.down(e))};function Ct(e,n){const s=e.changedTouches[0];n.touchstartX=s.clientX,n.touchstartY=s.clientY,n.start?.({originalEvent:e,...n})}function _t(e,n){const s=e.changedTouches[0];n.touchendX=s.clientX,n.touchendY=s.clientY,n.end?.({originalEvent:e,...n}),Vt(n)}function It(e,n){const s=e.changedTouches[0];n.touchmoveX=s.clientX,n.touchmoveY=s.clientY,n.move?.({originalEvent:e,...n})}function Pt(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};const n={touchstartX:0,touchstartY:0,touchendX:0,touchendY:0,touchmoveX:0,touchmoveY:0,offsetX:0,offsetY:0,left:e.left,right:e.right,up:e.up,down:e.down,start:e.start,move:e.move,end:e.end};return{touchstart:s=>Ct(s,n),touchend:s=>_t(s,n),touchmove:s=>It(s,n)}}function pt(e,n){const s=n.value,t=s?.parent?e.parentElement:e,l=s?.options??{passive:!0},u=n.instance?.$.uid;if(!t||!u)return;const o=Pt(n.value);t._touchHandlers=t._touchHandlers??Object.create(null),t._touchHandlers[u]=o,Ie(o).forEach(f=>{t.addEventListener(f,o[f],l)})}function Bt(e,n){const s=n.value?.parent?e.parentElement:e,t=n.instance?.$.uid;if(!s?._touchHandlers||!t)return;const l=s._touchHandlers[t];Ie(l).forEach(u=>{s.removeEventListener(u,l[u])}),delete s._touchHandlers[t]}const We={mounted:pt,unmounted:Bt},Et=We,ce=Symbol.for("vuetify:v-tabs"),zt=R({fixed:Boolean,sliderColor:String,hideSlider:Boolean,direction:{type:String,default:"horizontal"},...Pe(Xe({selectedClass:"v-tab--selected",variant:"text"}),["active","block","flat","location","position","symbol"])},"VTab"),Re=$()({name:"VTab",props:zt(),setup(e,n){let{slots:s,attrs:t}=n;const{textColorClasses:l,textColorStyles:u}=Ye(e,"sliderColor"),o=I(),f=I(),r=y(()=>e.direction==="horizontal"),h=y(()=>o.value?.group?.isSelected.value??!1);function x(m){let{value:a}=m;if(a){const g=o.value?.$el.parentElement?.querySelector(".v-tab--selected .v-tab__slider"),d=f.value;if(!g||!d)return;const _=getComputedStyle(g).color,T=g.getBoundingClientRect(),V=d.getBoundingClientRect(),P=r.value?"x":"y",p=r.value?"X":"Y",b=r.value?"right":"bottom",S=r.value?"width":"height",k=T[P],H=V[P],B=k>H?T[b]-V[b]:T[P]-V[P],K=Math.sign(B)>0?r.value?"right":"bottom":Math.sign(B)<0?r.value?"left":"top":"center",Q=(Math.abs(B)+(Math.sign(B)<0?T[S]:V[S]))/Math.max(T[S],V[S])||0,j=T[S]/V[S]||0,N=1.5;gt(d,{backgroundColor:[_,"currentcolor"],transform:[`translate${p}(${B}px) scale${p}(${j})`,`translate${p}(${B/N}px) scale${p}(${(Q-1)/N+1})`,"none"],transformOrigin:Array(3).fill(K)},{duration:225,easing:bt})}}return M(()=>{const m=G.filterProps(e);return v(G,z({symbol:ce,ref:o,class:["v-tab",e.class],style:e.style,tabindex:h.value?0:-1,role:"tab","aria-selected":String(h.value),active:!1},m,t,{block:e.fixed,maxWidth:e.fixed?300:void 0,"onGroup:selected":x}),{...s,default:()=>v(O,null,[s.default?.()??e.text,!e.hideSlider&&v("div",{ref:f,class:["v-tab__slider",l.value],style:u.value},null)])})}),ht({},o)}}),$e=Symbol.for("vuetify:v-window"),Me=Symbol.for("vuetify:v-window-group"),He=R({continuous:Boolean,nextIcon:{type:[Boolean,String,Function,Object],default:"$next"},prevIcon:{type:[Boolean,String,Function,Object],default:"$prev"},reverse:Boolean,showArrows:{type:[Boolean,String],validator:e=>typeof e=="boolean"||e==="hover"},touch:{type:[Object,Boolean],default:void 0},direction:{type:String,default:"horizontal"},modelValue:null,disabled:Boolean,selectedClass:{type:String,default:"v-window-item--active"},mandatory:{type:[Boolean,String],default:"force"},...ie(),...ue(),...Ge()},"VWindow"),Te=$()({name:"VWindow",directives:{Touch:We},props:He(),emits:{"update:modelValue":e=>!0},setup(e,n){let{slots:s}=n;const{themeClasses:t}=De(e),{isRtl:l}=pe(),{t:u}=Ue(),o=Be(e,Me),f=I(),r=y(()=>l.value?!e.reverse:e.reverse),h=E(!1),x=y(()=>{const b=e.direction==="vertical"?"y":"x",k=(r.value?!h.value:h.value)?"-reverse":"";return`v-window-${b}${k}-transition`}),m=E(0),a=I(void 0),g=y(()=>o.items.value.findIndex(b=>o.selected.value.includes(b.id)));Ee(g,(b,S)=>{const k=o.items.value.length,H=k-1;k<=2?h.value=be.continuous||g.value!==0),_=y(()=>e.continuous||g.value!==o.items.value.length-1);function T(){d.value&&o.prev()}function V(){_.value&&o.next()}const P=y(()=>{const b=[],S={icon:l.value?e.nextIcon:e.prevIcon,class:`v-window__${r.value?"right":"left"}`,onClick:o.prev,"aria-label":u("$vuetify.carousel.prev")};b.push(d.value?s.prev?s.prev({props:S}):v(G,S,null):v("div",null,null));const k={icon:l.value?e.prevIcon:e.nextIcon,class:`v-window__${r.value?"left":"right"}`,onClick:o.next,"aria-label":u("$vuetify.carousel.next")};return b.push(_.value?s.next?s.next({props:k}):v(G,k,null):v("div",null,null)),b}),p=y(()=>e.touch===!1?e.touch:{...{left:()=>{r.value?T():V()},right:()=>{r.value?V():T()},start:S=>{let{originalEvent:k}=S;k.stopPropagation()}},...e.touch===!0?{}:e.touch});return M(()=>q(v(e.tag,{ref:f,class:["v-window",{"v-window--show-arrows-on-hover":e.showArrows==="hover"},t.value,e.class],style:e.style},{default:()=>[v("div",{class:"v-window__container",style:{height:a.value}},[s.default?.({group:o}),e.showArrows!==!1&&v("div",{class:"v-window__controls"},[P.value])]),s.additional?.({group:o})]}),[[Ne("touch"),p.value]])),{group:o}}}),Wt=R({...Pe(He(),["continuous","nextIcon","prevIcon","showArrows","touch","mandatory"])},"VTabsWindow"),Rt=$()({name:"VTabsWindow",props:Wt(),emits:{"update:modelValue":e=>!0},setup(e,n){let{slots:s}=n;const t=re(ce,null),l=ze(e,"modelValue"),u=y({get(){return l.value!=null||!t?l.value:t.items.value.find(o=>t.selected.value.includes(o.id))?.value},set(o){l.value=o}});return M(()=>{const o=Te.filterProps(e);return v(Te,z({_as:"VTabsWindow"},o,{modelValue:u.value,"onUpdate:modelValue":f=>u.value=f,class:["v-tabs-window",e.class],style:e.style,mandatory:!1,touch:!1}),s)}),{}}}),Ae=R({reverseTransition:{type:[Boolean,String],default:void 0},transition:{type:[Boolean,String],default:void 0},...ie(),...qe(),...yt()},"VWindowItem"),Ve=$()({name:"VWindowItem",directives:{Touch:Et},props:Ae(),emits:{"group:selected":e=>!0},setup(e,n){let{slots:s}=n;const t=re($e),l=Ke(e,Me),{isBooted:u}=xt();if(!t||!l)throw new Error("[Vuetify] VWindowItem must be used inside VWindow");const o=E(!1),f=y(()=>u.value&&(t.isReversed.value?e.reverseTransition!==!1:e.transition!==!1));function r(){!o.value||!t||(o.value=!1,t.transitionCount.value>0&&(t.transitionCount.value-=1,t.transitionCount.value===0&&(t.transitionHeight.value=void 0)))}function h(){o.value||!t||(o.value=!0,t.transitionCount.value===0&&(t.transitionHeight.value=ae(t.rootRef.value?.clientHeight)),t.transitionCount.value+=1)}function x(){r()}function m(d){o.value&&Qe(()=>{!f.value||!o.value||!t||(t.transitionHeight.value=ae(d.clientHeight))})}const a=y(()=>{const d=t.isReversed.value?e.reverseTransition:e.transition;return f.value?{name:typeof d!="string"?t.transition.value:d,onBeforeEnter:h,onAfterEnter:r,onEnterCancelled:x,onBeforeLeave:h,onAfterLeave:r,onLeaveCancelled:x,onEnter:m}:!1}),{hasContent:g}=St(e,l.isSelected);return M(()=>v(kt,{transition:a.value,disabled:!u.value},{default:()=>[q(v("div",{class:["v-window-item",l.selectedClass.value,e.class],style:e.style},[g.value&&s.default?.()]),[[le,l.isSelected.value]])]})),{groupItem:l}}}),$t=R({...Ae()},"VTabsWindowItem"),Mt=$()({name:"VTabsWindowItem",props:$t(),setup(e,n){let{slots:s}=n;return M(()=>{const t=Ve.filterProps(e);return v(Ve,z({_as:"VTabsWindowItem"},t,{class:["v-tabs-window-item",e.class],style:e.style}),s)}),{}}});function Ht(e){let{selectedElement:n,containerElement:s,isRtl:t,isHorizontal:l}=e;const u=D(l,s),o=Fe(l,t,s),f=D(l,n),r=Oe(l,n),h=f*.4;return o>r?r-h:o+utypeof e=="boolean"||["always","desktop","mobile"].includes(e)},...ie(),...Je({mobile:null}),...ue(),...Ze({selectedClass:"v-slide-group-item--active"})},"VSlideGroup"),_e=$()({name:"VSlideGroup",props:Le(),emits:{"update:modelValue":e=>!0},setup(e,n){let{slots:s}=n;const{isRtl:t}=pe(),{displayClasses:l,mobile:u}=et(e),o=Be(e,e.symbol),f=E(!1),r=E(0),h=E(0),x=E(0),m=y(()=>e.direction==="horizontal"),{resizeRef:a,contentRect:g}=me(),{resizeRef:d,contentRect:_}=me(),T=tt(),V=y(()=>({container:a.el,duration:200,easing:"easeOutQuart"})),P=y(()=>o.selected.value.length?o.items.value.findIndex(i=>i.id===o.selected.value[0]):-1),p=y(()=>o.selected.value.length?o.items.value.findIndex(i=>i.id===o.selected.value[o.selected.value.length-1]):-1);if(he){let i=-1;Ee(()=>[o.selected.value,g.value,_.value,m.value],()=>{cancelAnimationFrame(i),i=requestAnimationFrame(()=>{if(g.value&&_.value){const c=m.value?"width":"height";h.value=g.value[c],x.value=_.value[c],f.value=h.value+1=0&&d.el){const c=d.el.children[p.value];S(c,e.centerActive)}})})}const b=E(!1);function S(i,c){let w=0;c?w=At({containerElement:a.el,isHorizontal:m.value,selectedElement:i}):w=Ht({containerElement:a.el,isHorizontal:m.value,isRtl:t.value,selectedElement:i}),k(w)}function k(i){if(!he||!a.el)return;const c=D(m.value,a.el),w=Fe(m.value,t.value,a.el);if(!(Ce(m.value,a.el)<=c||Math.abs(i-w)<16)){if(m.value&&t.value&&a.el){const{scrollWidth:ne,offsetWidth:oe}=a.el;i=ne-oe-i}m.value?T.horizontal(i,V.value):T(i,V.value)}}function H(i){const{scrollTop:c,scrollLeft:w}=i.target;r.value=m.value?w:c}function B(i){if(b.value=!0,!(!f.value||!d.el)){for(const c of i.composedPath())for(const w of d.el.children)if(w===c){S(w);return}}}function K(i){b.value=!1}let U=!1;function Q(i){!U&&!b.value&&!(i.relatedTarget&&d.el?.contains(i.relatedTarget))&&L(),U=!1}function j(){U=!0}function N(i){if(!d.el)return;function c(w){i.preventDefault(),L(w)}m.value?i.key==="ArrowRight"?c(t.value?"prev":"next"):i.key==="ArrowLeft"&&c(t.value?"next":"prev"):i.key==="ArrowDown"?c("next"):i.key==="ArrowUp"&&c("prev"),i.key==="Home"?c("first"):i.key==="End"&&c("last")}function L(i){if(!d.el)return;let c;if(!i)c=nt(d.el)[0];else if(i==="next"){if(c=d.el.querySelector(":focus")?.nextElementSibling,!c)return L("first")}else if(i==="prev"){if(c=d.el.querySelector(":focus")?.previousElementSibling,!c)return L("last")}else i==="first"?c=d.el.firstElementChild:i==="last"&&(c=d.el.lastElementChild);c&&c.focus({preventScroll:!0})}function J(i){const c=m.value&&t.value?-1:1,w=(i==="prev"?-c:c)*h.value;let te=r.value+w;if(m.value&&t.value&&a.el){const{scrollWidth:ne,offsetWidth:oe}=a.el;te+=ne-oe}k(te)}const Z=y(()=>({next:o.next,prev:o.prev,select:o.select,isSelected:o.isSelected})),ee=y(()=>{switch(e.showArrows){case"always":return!0;case"desktop":return!u.value;case!0:return f.value||Math.abs(r.value)>0;case"mobile":return u.value||f.value||Math.abs(r.value)>0;default:return!u.value&&(f.value||Math.abs(r.value)>0)}}),de=y(()=>Math.abs(r.value)>1),ve=y(()=>{if(!a.value)return!1;const i=Ce(m.value,a.el),c=Ft(m.value,a.el);return i-c-Math.abs(r.value)>1});return M(()=>v(e.tag,{class:["v-slide-group",{"v-slide-group--vertical":!m.value,"v-slide-group--has-affixes":ee.value,"v-slide-group--is-overflowing":f.value},l.value,e.class],style:e.style,tabindex:b.value||o.selected.value.length?-1:0,onFocus:Q},{default:()=>[ee.value&&v("div",{key:"prev",class:["v-slide-group__prev",{"v-slide-group__prev--disabled":!de.value}],onMousedown:j,onClick:()=>de.value&&J("prev")},[s.prev?.(Z.value)??v(ke,null,{default:()=>[v(ge,{icon:t.value?e.nextIcon:e.prevIcon},null)]})]),v("div",{key:"container",ref:a,class:"v-slide-group__container",onScroll:H},[v("div",{ref:d,class:"v-slide-group__content",onFocusin:B,onFocusout:K,onKeydown:N},[s.default?.(Z.value)])]),ee.value&&v("div",{key:"next",class:["v-slide-group__next",{"v-slide-group__next--disabled":!ve.value}],onMousedown:j,onClick:()=>ve.value&&J("next")},[s.next?.(Z.value)??v(ke,null,{default:()=>[v(ge,{icon:t.value?e.prevIcon:e.nextIcon},null)]})])]})),{selected:o.selected,scrollTo:J,scrollOffset:r,focus:L}}});function Lt(e){return e?e.map(n=>it(n)?n:{text:n,value:n}):[]}const Xt=R({alignTabs:{type:String,default:"start"},color:String,fixedTabs:Boolean,items:{type:Array,default:()=>[]},stacked:Boolean,bgColor:String,grow:Boolean,height:{type:[Number,String],default:void 0},hideSlider:Boolean,sliderColor:String,...Le({mandatory:"force",selectedClass:"v-tab-item--selected"}),...ot(),...ue()},"VTabs"),Yt=$()({name:"VTabs",props:Xt(),emits:{"update:modelValue":e=>!0},setup(e,n){let{attrs:s,slots:t}=n;const l=ze(e,"modelValue"),u=y(()=>Lt(e.items)),{densityClasses:o}=st(e),{backgroundColorClasses:f,backgroundColorStyles:r}=lt(W(e,"bgColor")),{scopeId:h}=wt();return at({VTab:{color:W(e,"color"),direction:W(e,"direction"),stacked:W(e,"stacked"),fixed:W(e,"fixedTabs"),sliderColor:W(e,"sliderColor"),hideSlider:W(e,"hideSlider")}}),M(()=>{const x=_e.filterProps(e),m=!!(t.window||e.items.length>0);return v(O,null,[v(_e,z(x,{modelValue:l.value,"onUpdate:modelValue":a=>l.value=a,class:["v-tabs",`v-tabs--${e.direction}`,`v-tabs--align-tabs-${e.alignTabs}`,{"v-tabs--fixed-tabs":e.fixedTabs,"v-tabs--grow":e.grow,"v-tabs--stacked":e.stacked},o.value,f.value,e.class],style:[{"--v-tabs-height":ae(e.height)},r.value,e.style],role:"tablist",symbol:ce},h,s),{default:()=>[t.default?.()??u.value.map(a=>t.tab?.({item:a})??v(Re,z(a,{key:a.text,value:a.value}),{default:t[`tab.${a.value}`]?()=>t[`tab.${a.value}`]?.({item:a}):void 0}))]}),m&&v(Rt,z({modelValue:l.value,"onUpdate:modelValue":a=>l.value=a,key:"tabs-window"},h),{default:()=>[u.value.map(a=>t.item?.({item:a})??v(Mt,{value:a.value},{default:()=>t[`item.${a.value}`]?.({item:a})})),t.window?.()]})])}),{}}}),Gt={key:0,id:"overlay",class:"pa-2 panel bg-surface"},Dt={class:"component-container"},Ut={__name:"MobileLayout",setup(e){rt(m=>({fbf7b91a:h.value,"2c845582":r.value,fdee920e:x.value}));const n=re(ct),s=n.template.widgets,t=be(s),[l]=be([n.template?.background]),{mainRect:u}=dt(),o=I(-1),f=I(null),r=I(""),h=I(""),x=I("");return vt(()=>{h.value=u.value.top+"px",x.value=(u.value.bottom||48)+"px",r.value=u.value.bottom+(f.value?.$el?.clientHeight??0)+"px"}),(m,a)=>(C(),A(Tt,{class:"overflow-hidden main"},{default:F(()=>[(C(),A(ye,{suspensible:""},{default:F(()=>[X(l).component?(C(),A(Se(X(l).component),z({key:0,id:"bg-widget"},X(l).props),null,16)):se("v-if",!0)]),_:1})),(C(!0),Y(O,null,we(X(t),(g,d)=>(C(),Y(O,{key:d},[g.value.component?q((C(),Y("div",Gt,[v(G,{icon:"",variant:"text",class:"close-btn",onClick:a[0]||(a[0]=_=>o.value=-1)},{default:F(()=>[xe("✕")]),_:1}),(C(),A(ye,{suspensible:""},{default:F(()=>[q(ft("div",Dt,[(C(),A(Se(g.value.component),z({key:g.value.id,ref_for:!0},g.value.props),null,16))],512),[[le,o.value===d]])]),_:2},1024))],512)),[[le,o.value===d]]):se("v-if",!0)],64))),128)),v(Yt,{ref_key:"tabs",ref:f,"align-tabs":"center","bg-color":"surface",class:"tabs","show-arrows":"",modelValue:o.value,"onUpdate:modelValue":a[1]||(a[1]=g=>o.value=g)},{default:F(()=>[(C(!0),Y(O,null,we(X(t),(g,d)=>(C(),Y(O,{key:d},[g.value.component?(C(),A(Re,{key:0,value:d},{default:F(()=>[xe(mt(g.value.title),1)]),_:2},1032,["value"])):se("v-if",!0)],64))),128))]),_:1},8,["modelValue"])]),_:1}))}},Zt=ut(Ut,[["__scopeId","data-v-e69b9875"]]);export{Zt as default}; diff --git a/pr-preview/pr-17/assets/PopUp-5-tUIM9N.js b/pr-preview/pr-17/assets/PopUp-5-tUIM9N.js new file mode 100644 index 0000000..9a10fbc --- /dev/null +++ b/pr-preview/pr-17/assets/PopUp-5-tUIM9N.js @@ -0,0 +1 @@ +import{g as E,b as p,d as h,ab as w,p as V,y as R,r as O,L as M,w as x,a as T,D as q,ak as I,N,ae as W,e as j,ac as U,af as X,b1 as Y,b2 as z,ag as H,f as Q,h as G,i as J,Q as K,R as Z,ah as _,ad as ee,ai as te,b6 as ae,b7 as oe,aj as se,ba as ne,bb as re,X as ie,$ as b,a6 as k,a1 as S,a0 as le,a3 as P,a4 as ce,a5 as C,bm as ue}from"./index-Dvu417lt.js";import{m as de,V as B}from"./VOverlay-DGc1wXYF.js";import{a as y,d as me,s as D,c as fe,g as ge,n as ve,b as pe,f as he}from"./forwardRefs-DzUtZcD3.js";import"./transition-BKtsYhmO.js";const ye=V({target:[Object,Array]},"v-dialog-transition"),be=E()({name:"VDialogTransition",props:ye(),setup(e,i){let{slots:o}=i;const r={onBeforeEnter(t){t.style.pointerEvents="none",t.style.visibility="hidden"},async onEnter(t,c){await new Promise(n=>requestAnimationFrame(n)),await new Promise(n=>requestAnimationFrame(n)),t.style.visibility="";const{x:a,y:l,sx:d,sy:m,speed:s}=L(e.target,t),u=y(t,[{transform:`translate(${a}px, ${l}px) scale(${d}, ${m})`,opacity:0},{}],{duration:225*s,easing:me});A(t)?.forEach(n=>{y(n,[{opacity:0},{opacity:0,offset:.33},{}],{duration:225*2*s,easing:D})}),u.finished.then(()=>c())},onAfterEnter(t){t.style.removeProperty("pointer-events")},onBeforeLeave(t){t.style.pointerEvents="none"},async onLeave(t,c){await new Promise(n=>requestAnimationFrame(n));const{x:a,y:l,sx:d,sy:m,speed:s}=L(e.target,t);y(t,[{},{transform:`translate(${a}px, ${l}px) scale(${d}, ${m})`,opacity:0}],{duration:125*s,easing:fe}).finished.then(()=>c()),A(t)?.forEach(n=>{y(n,[{},{opacity:0,offset:.2},{opacity:0}],{duration:125*2*s,easing:D})})},onAfterLeave(t){t.style.removeProperty("pointer-events")}};return()=>e.target?p(w,h({name:"dialog-transition"},r,{css:!1}),o):p(w,{name:"dialog-transition"},o)}});function A(e){const i=e.querySelector(":scope > .v-card, :scope > .v-sheet, :scope > .v-list")?.children;return i&&[...i]}function L(e,i){const o=ge(e),r=ve(i),[t,c]=getComputedStyle(i).transformOrigin.split(" ").map(F=>parseFloat(F)),[a,l]=getComputedStyle(i).getPropertyValue("--v-overlay-anchor-origin").split(" ");let d=o.left+o.width/2;a==="left"||l==="left"?d-=o.width/2:(a==="right"||l==="right")&&(d+=o.width/2);let m=o.top+o.height/2;a==="top"||l==="top"?m-=o.height/2:(a==="bottom"||l==="bottom")&&(m+=o.height/2);const s=o.width/r.width,u=o.height/r.height,n=Math.max(1,s,u),f=s/n||0,v=u/n||0,g=r.width*r.height/(window.innerWidth*window.innerHeight),$=g>.12?Math.min(1.5,(g-.12)*10+1):1;return{x:d-(t+r.left),y:m-(c+r.top),sx:f,sy:v,speed:$}}const Pe=V({fullscreen:Boolean,retainFocus:{type:Boolean,default:!0},scrollable:Boolean,...de({origin:"center center",scrollStrategy:"block",transition:{component:be},zIndex:2400})},"VDialog"),Ee=E()({name:"VDialog",props:Pe(),emits:{"update:modelValue":e=>!0,afterLeave:()=>!0},setup(e,i){let{emit:o,slots:r}=i;const t=R(e,"modelValue"),{scopeId:c}=pe(),a=O();function l(s){const u=s.relatedTarget,n=s.target;if(u!==n&&a.value?.contentEl&&a.value?.globalTop&&![document,a.value.contentEl].includes(n)&&!a.value.contentEl.contains(n)){const f=N(a.value.contentEl);if(!f.length)return;const v=f[0],g=f[f.length-1];u===v?g.focus():v.focus()}}M&&x(()=>t.value&&e.retainFocus,s=>{s?document.addEventListener("focusin",l):document.removeEventListener("focusin",l)},{immediate:!0});function d(){a.value?.contentEl&&!a.value.contentEl.contains(document.activeElement)&&a.value.contentEl.focus({preventScroll:!0})}function m(){o("afterLeave")}return x(t,async s=>{s||(await q(),a.value.activatorEl?.focus({preventScroll:!0}))}),T(()=>{const s=B.filterProps(e),u=h({"aria-haspopup":"dialog","aria-expanded":String(t.value)},e.activatorProps),n=h({tabindex:-1},e.contentProps);return p(B,h({ref:a,class:["v-dialog",{"v-dialog--fullscreen":e.fullscreen,"v-dialog--scrollable":e.scrollable},e.class],style:e.style},s,{modelValue:t.value,"onUpdate:modelValue":f=>t.value=f,"aria-modal":"true",activatorProps:u,contentProps:n,role:"dialog",onAfterEnter:d,onAfterLeave:m},c),{activator:r.activator,default:function(){for(var f=arguments.length,v=new Array(f),g=0;g[r.default?.(...v)]})}})}),he({},a)}}),Ve=V({color:String,...W(),...j(),...U(),...X(),...Y(),...z(),...H(),...Q(),...G()},"VSheet"),we=E()({name:"VSheet",props:Ve(),setup(e,i){let{slots:o}=i;const{themeClasses:r}=J(e),{backgroundColorClasses:t,backgroundColorStyles:c}=K(Z(e,"color")),{borderClasses:a}=_(e),{dimensionStyles:l}=ee(e),{elevationClasses:d}=te(e),{locationStyles:m}=ae(e),{positionClasses:s}=oe(e),{roundedClasses:u}=se(e);return T(()=>p(e.tag,{class:["v-sheet",r.value,t.value,a.value,d.value,s.value,u.value,e.class],style:[c.value,l.value,m.value,e.style]},o)),{}}}),xe={key:1},De={__name:"PopUp",props:ne({widget:{type:Object,default:void 0}},{modelValue:{type:Boolean,required:!0,default:!1},modelModifiers:{}}),emits:["update:modelValue"],setup(e){const i=re(e,"modelValue"),o=e,[r]=ie([o?.widget]);return(t,c)=>(b(),k("span",null,[p(Ee,{"max-width":"500px","max-height":"500px",absolute:"",scrollable:"","scroll-strategy":"block","close-on-back":"",modelValue:i.value,"onUpdate:modelValue":c[0]||(c[0]=a=>i.value=a)},{default:S(()=>[p(we,null,{default:S(()=>[e.widget?(b(),le(ce(P(r).component),h({key:P(r).id},P(r).props),null,16)):C("v-if",!0),t.$slots.default?(b(),k("span",xe,[ue(t.$slots,"default")])):C("v-if",!0)]),_:3})]),_:3},8,["modelValue"])]))}};export{De as default}; diff --git a/pr-preview/pr-17/assets/PopUp-BLlcRLMy.js b/pr-preview/pr-17/assets/PopUp-BLlcRLMy.js deleted file mode 100644 index 74c6e5a..0000000 --- a/pr-preview/pr-17/assets/PopUp-BLlcRLMy.js +++ /dev/null @@ -1 +0,0 @@ -import{g as E,b as p,d as h,ab as w,p as V,y as R,r as O,L as M,w as x,a as T,D as q,ak as W,N as I,ae as N,e as X,ac as j,af as U,b1 as Y,b2 as z,ag as H,f as Q,h as G,i as J,Q as K,R as Z,ah as _,ad as ee,ai as te,b3 as ae,b4 as oe,aj as se,aW as ne,aX as re,X as ie,$ as P,a6 as k,a1 as S,a0 as le,a3 as b,a4 as ce,a5 as C,b5 as ue}from"./index-BHzPgH2J.js";import{m as de,V as B}from"./VOverlay-Di1btkZg.js";import{a as y,d as me,s as D,c as fe,g as ge,n as ve,b as pe,f as he}from"./forwardRefs-BoZnhoLd.js";import"./transition-zS3yGrDV.js";const ye=V({target:[Object,Array]},"v-dialog-transition"),Pe=E()({name:"VDialogTransition",props:ye(),setup(e,i){let{slots:o}=i;const r={onBeforeEnter(t){t.style.pointerEvents="none",t.style.visibility="hidden"},async onEnter(t,c){await new Promise(n=>requestAnimationFrame(n)),await new Promise(n=>requestAnimationFrame(n)),t.style.visibility="";const{x:a,y:l,sx:d,sy:m,speed:s}=L(e.target,t),u=y(t,[{transform:`translate(${a}px, ${l}px) scale(${d}, ${m})`,opacity:0},{}],{duration:225*s,easing:me});A(t)?.forEach(n=>{y(n,[{opacity:0},{opacity:0,offset:.33},{}],{duration:225*2*s,easing:D})}),u.finished.then(()=>c())},onAfterEnter(t){t.style.removeProperty("pointer-events")},onBeforeLeave(t){t.style.pointerEvents="none"},async onLeave(t,c){await new Promise(n=>requestAnimationFrame(n));const{x:a,y:l,sx:d,sy:m,speed:s}=L(e.target,t);y(t,[{},{transform:`translate(${a}px, ${l}px) scale(${d}, ${m})`,opacity:0}],{duration:125*s,easing:fe}).finished.then(()=>c()),A(t)?.forEach(n=>{y(n,[{},{opacity:0,offset:.2},{opacity:0}],{duration:125*2*s,easing:D})})},onAfterLeave(t){t.style.removeProperty("pointer-events")}};return()=>e.target?p(w,h({name:"dialog-transition"},r,{css:!1}),o):p(w,{name:"dialog-transition"},o)}});function A(e){const i=e.querySelector(":scope > .v-card, :scope > .v-sheet, :scope > .v-list")?.children;return i&&[...i]}function L(e,i){const o=ge(e),r=ve(i),[t,c]=getComputedStyle(i).transformOrigin.split(" ").map(F=>parseFloat(F)),[a,l]=getComputedStyle(i).getPropertyValue("--v-overlay-anchor-origin").split(" ");let d=o.left+o.width/2;a==="left"||l==="left"?d-=o.width/2:(a==="right"||l==="right")&&(d+=o.width/2);let m=o.top+o.height/2;a==="top"||l==="top"?m-=o.height/2:(a==="bottom"||l==="bottom")&&(m+=o.height/2);const s=o.width/r.width,u=o.height/r.height,n=Math.max(1,s,u),f=s/n||0,v=u/n||0,g=r.width*r.height/(window.innerWidth*window.innerHeight),$=g>.12?Math.min(1.5,(g-.12)*10+1):1;return{x:d-(t+r.left),y:m-(c+r.top),sx:f,sy:v,speed:$}}const be=V({fullscreen:Boolean,retainFocus:{type:Boolean,default:!0},scrollable:Boolean,...de({origin:"center center",scrollStrategy:"block",transition:{component:Pe},zIndex:2400})},"VDialog"),Ee=E()({name:"VDialog",props:be(),emits:{"update:modelValue":e=>!0,afterLeave:()=>!0},setup(e,i){let{emit:o,slots:r}=i;const t=R(e,"modelValue"),{scopeId:c}=pe(),a=O();function l(s){const u=s.relatedTarget,n=s.target;if(u!==n&&a.value?.contentEl&&a.value?.globalTop&&![document,a.value.contentEl].includes(n)&&!a.value.contentEl.contains(n)){const f=I(a.value.contentEl);if(!f.length)return;const v=f[0],g=f[f.length-1];u===v?g.focus():v.focus()}}M&&x(()=>t.value&&e.retainFocus,s=>{s?document.addEventListener("focusin",l):document.removeEventListener("focusin",l)},{immediate:!0});function d(){a.value?.contentEl&&!a.value.contentEl.contains(document.activeElement)&&a.value.contentEl.focus({preventScroll:!0})}function m(){o("afterLeave")}return x(t,async s=>{s||(await q(),a.value.activatorEl?.focus({preventScroll:!0}))}),T(()=>{const s=B.filterProps(e),u=h({"aria-haspopup":"dialog","aria-expanded":String(t.value)},e.activatorProps),n=h({tabindex:-1},e.contentProps);return p(B,h({ref:a,class:["v-dialog",{"v-dialog--fullscreen":e.fullscreen,"v-dialog--scrollable":e.scrollable},e.class],style:e.style},s,{modelValue:t.value,"onUpdate:modelValue":f=>t.value=f,"aria-modal":"true",activatorProps:u,contentProps:n,role:"dialog",onAfterEnter:d,onAfterLeave:m},c),{activator:r.activator,default:function(){for(var f=arguments.length,v=new Array(f),g=0;g[r.default?.(...v)]})}})}),he({},a)}}),Ve=V({color:String,...N(),...X(),...j(),...U(),...Y(),...z(),...H(),...Q(),...G()},"VSheet"),we=E()({name:"VSheet",props:Ve(),setup(e,i){let{slots:o}=i;const{themeClasses:r}=J(e),{backgroundColorClasses:t,backgroundColorStyles:c}=K(Z(e,"color")),{borderClasses:a}=_(e),{dimensionStyles:l}=ee(e),{elevationClasses:d}=te(e),{locationStyles:m}=ae(e),{positionClasses:s}=oe(e),{roundedClasses:u}=se(e);return T(()=>p(e.tag,{class:["v-sheet",r.value,t.value,a.value,d.value,s.value,u.value,e.class],style:[c.value,l.value,m.value,e.style]},o)),{}}}),xe={key:1},De={__name:"PopUp",props:ne({widget:{type:Object,default:void 0}},{modelValue:{type:Boolean,required:!0,default:!1},modelModifiers:{}}),emits:["update:modelValue"],setup(e){const i=re(e,"modelValue"),o=e,[r]=ie([o?.widget]);return(t,c)=>(P(),k("span",null,[p(Ee,{"max-width":"500px","max-height":"500px",absolute:"",scrollable:"","scroll-strategy":"block","close-on-back":"",modelValue:i.value,"onUpdate:modelValue":c[0]||(c[0]=a=>i.value=a)},{default:S(()=>[p(we,null,{default:S(()=>[e.widget?(P(),le(ce(b(r).component),h({key:b(r).id},b(r).props),null,16)):C("v-if",!0),t.$slots.default?(P(),k("span",xe,[ue(t.$slots,"default")])):C("v-if",!0)]),_:3})]),_:3},8,["modelValue"])]))}};export{De as default}; diff --git a/pr-preview/pr-17/assets/VDivider-CnS8Y1Zb.js b/pr-preview/pr-17/assets/VDivider-CnS8Y1Zb.js deleted file mode 100644 index 3d9f84b..0000000 --- a/pr-preview/pr-17/assets/VDivider-CnS8Y1Zb.js +++ /dev/null @@ -1 +0,0 @@ -import{g as u,e as v,S as Y,a as o,b as a,p as m,f,aV as Z,I as y,O as I,ag as B,bE as p,h as A,bu as D,i as P,bx as N,P as L,aj as R,bF as ee,M as h,ak as k,bz as w,F as x,ae,ac as te,af as ne,bG as le,b1 as ie,b2 as se,bt as de,bv as re,ah as ce,ad as ue,ai as ve,bH as oe,b3 as me,b4 as ye,bw as be,c as S,t as ge,v as ke,bI as fe,u as Ce,R as Ve,C as _}from"./index-BHzPgH2J.js";import{V as z}from"./VImg-i8uxgNTt.js";const he=u()({name:"VCardActions",props:v(),setup(e,l){let{slots:t}=l;return Y({VBtn:{slim:!0,variant:"text"}}),o(()=>a("div",{class:["v-card-actions",e.class],style:e.style},[t.default?.()])),{}}}),Se=m({opacity:[Number,String],...v(),...f()},"VCardSubtitle"),Ie=u()({name:"VCardSubtitle",props:Se(),setup(e,l){let{slots:t}=l;return o(()=>a(e.tag,{class:["v-card-subtitle",e.class],style:[{"--v-card-subtitle-opacity":e.opacity},e.style]},t)),{}}}),Ae=Z("v-card-title"),Pe=m({start:Boolean,end:Boolean,icon:y,image:String,text:String,...v(),...I(),...B(),...p(),...f(),...A(),...D({variant:"flat"})},"VAvatar"),T=u()({name:"VAvatar",props:Pe(),setup(e,l){let{slots:t}=l;const{themeClasses:n}=P(e),{colorClasses:d,colorStyles:s,variantClasses:r}=N(e),{densityClasses:c}=L(e),{roundedClasses:i}=R(e),{sizeClasses:C,sizeStyles:V}=ee(e);return o(()=>a(e.tag,{class:["v-avatar",{"v-avatar--start":e.start,"v-avatar--end":e.end},n.value,d.value,c.value,i.value,C.value,r.value,e.class],style:[s.value,V.value,e.style]},{default:()=>[t.default?a(k,{key:"content-defaults",defaults:{VImg:{cover:!0,src:e.image},VIcon:{icon:e.icon}}},{default:()=>[t.default()]}):e.image?a(z,{key:"image",src:e.image,alt:"",cover:!0},null):e.icon?a(h,{key:"icon",icon:e.icon},null):e.text,w(!1,"v-avatar")]})),{}}}),xe=m({appendAvatar:String,appendIcon:y,prependAvatar:String,prependIcon:y,subtitle:[String,Number],title:[String,Number],...v(),...I()},"VCardItem"),_e=u()({name:"VCardItem",props:xe(),setup(e,l){let{slots:t}=l;return o(()=>{const n=!!(e.prependAvatar||e.prependIcon),d=!!(n||t.prepend),s=!!(e.appendAvatar||e.appendIcon),r=!!(s||t.append),c=!!(e.title!=null||t.title),i=!!(e.subtitle!=null||t.subtitle);return a("div",{class:["v-card-item",e.class],style:e.style},[d&&a("div",{key:"prepend",class:"v-card-item__prepend"},[t.prepend?a(k,{key:"prepend-defaults",disabled:!n,defaults:{VAvatar:{density:e.density,image:e.prependAvatar},VIcon:{density:e.density,icon:e.prependIcon}}},t.prepend):a(x,null,[e.prependAvatar&&a(T,{key:"prepend-avatar",density:e.density,image:e.prependAvatar},null),e.prependIcon&&a(h,{key:"prepend-icon",density:e.density,icon:e.prependIcon},null)])]),a("div",{class:"v-card-item__content"},[c&&a(Ae,{key:"title"},{default:()=>[t.title?.()??e.title]}),i&&a(Ie,{key:"subtitle"},{default:()=>[t.subtitle?.()??e.subtitle]}),t.default?.()]),r&&a("div",{key:"append",class:"v-card-item__append"},[t.append?a(k,{key:"append-defaults",disabled:!s,defaults:{VAvatar:{density:e.density,image:e.appendAvatar},VIcon:{density:e.density,icon:e.appendIcon}}},t.append):a(x,null,[e.appendIcon&&a(h,{key:"append-icon",density:e.density,icon:e.appendIcon},null),e.appendAvatar&&a(T,{key:"append-avatar",density:e.density,image:e.appendAvatar},null)])])])}),{}}}),Te=m({opacity:[Number,String],...v(),...f()},"VCardText"),Be=u()({name:"VCardText",props:Te(),setup(e,l){let{slots:t}=l;return o(()=>a(e.tag,{class:["v-card-text",e.class],style:[{"--v-card-text-opacity":e.opacity},e.style]},t)),{}}}),De=m({appendAvatar:String,appendIcon:y,disabled:Boolean,flat:Boolean,hover:Boolean,image:String,link:{type:Boolean,default:void 0},prependAvatar:String,prependIcon:y,ripple:{type:[Boolean,Object],default:!0},subtitle:[String,Number],text:[String,Number],title:[String,Number],...ae(),...v(),...I(),...te(),...ne(),...le(),...ie(),...se(),...B(),...de(),...f(),...A(),...D({variant:"elevated"})},"VCard"),we=u()({name:"VCard",directives:{Ripple:re},props:De(),setup(e,l){let{attrs:t,slots:n}=l;const{themeClasses:d}=P(e),{borderClasses:s}=ce(e),{colorClasses:r,colorStyles:c,variantClasses:i}=N(e),{densityClasses:C}=L(e),{dimensionStyles:V}=ue(e),{elevationClasses:F}=ve(e),{loaderClasses:E}=oe(e),{locationStyles:M}=me(e),{positionClasses:O}=ye(e),{roundedClasses:j}=R(e),b=be(e,t),H=S(()=>e.link!==!1&&b.isLink.value),g=S(()=>!e.disabled&&e.link!==!1&&(e.link||b.isClickable.value));return o(()=>{const W=H.value?"a":e.tag,G=!!(n.title||e.title!=null),U=!!(n.subtitle||e.subtitle!=null),$=G||U,q=!!(n.append||e.appendAvatar||e.appendIcon),J=!!(n.prepend||e.prependAvatar||e.prependIcon),K=!!(n.image||e.image),Q=$||J||q,X=!!(n.text||e.text!=null);return ge(a(W,{class:["v-card",{"v-card--disabled":e.disabled,"v-card--flat":e.flat,"v-card--hover":e.hover&&!(e.disabled||e.flat),"v-card--link":g.value},d.value,s.value,r.value,C.value,F.value,E.value,O.value,j.value,i.value,e.class],style:[c.value,V.value,M.value,e.style],href:b.href.value,onClick:g.value&&b.navigate,tabindex:e.disabled?-1:void 0},{default:()=>[K&&a("div",{key:"image",class:"v-card__image"},[n.image?a(k,{key:"image-defaults",disabled:!e.image,defaults:{VImg:{cover:!0,src:e.image}}},n.image):a(z,{key:"image-img",cover:!0,src:e.image},null)]),a(fe,{name:"v-card",active:!!e.loading,color:typeof e.loading=="boolean"?void 0:e.loading},{default:n.loader}),Q&&a(_e,{key:"item",prependAvatar:e.prependAvatar,prependIcon:e.prependIcon,title:e.title,subtitle:e.subtitle,appendAvatar:e.appendAvatar,appendIcon:e.appendIcon},{default:n.item,prepend:n.prepend,title:n.title,subtitle:n.subtitle,append:n.append}),X&&a(Be,{key:"text"},{default:()=>[n.text?.()??e.text]}),n.default?.(),n.actions&&a(he,null,{default:n.actions}),w(g.value,"v-card")]}),[[ke("ripple"),g.value&&e.ripple]])}),{}}}),Ne=m({color:String,inset:Boolean,length:[Number,String],opacity:[Number,String],thickness:[Number,String],vertical:Boolean,...v(),...A()},"VDivider"),ze=u()({name:"VDivider",props:Ne(),setup(e,l){let{attrs:t,slots:n}=l;const{themeClasses:d}=P(e),{textColorClasses:s,textColorStyles:r}=Ce(Ve(e,"color")),c=S(()=>{const i={};return e.length&&(i[e.vertical?"height":"width"]=_(e.length)),e.thickness&&(i[e.vertical?"borderRightWidth":"borderTopWidth"]=_(e.thickness)),i});return o(()=>{const i=a("hr",{class:[{"v-divider":!0,"v-divider--inset":e.inset,"v-divider--vertical":e.vertical},d.value,s.value,e.class],style:[c.value,r.value,{"--v-border-opacity":e.opacity},e.style],"aria-orientation":!t.role||t.role==="separator"?e.vertical?"vertical":"horizontal":void 0,role:`${t.role||"separator"}`},null);return n.default?a("div",{class:["v-divider__wrapper",{"v-divider__wrapper--vertical":e.vertical,"v-divider__wrapper--inset":e.inset}]},[i,a("div",{class:"v-divider__content"},[n.default()]),i]):i}),{}}});export{Ae as V,Be as a,ze as b,he as c,we as d,T as e}; diff --git a/pr-preview/pr-17/assets/VDivider-DIjdKgTP.css b/pr-preview/pr-17/assets/VDivider-DIjdKgTP.css deleted file mode 100644 index 2f59d92..0000000 --- a/pr-preview/pr-17/assets/VDivider-DIjdKgTP.css +++ /dev/null @@ -1 +0,0 @@ -.v-card{display:block;overflow:hidden;overflow-wrap:break-word;position:relative;padding:0;text-decoration:none;transition-duration:.28s;transition-property:box-shadow,opacity,background;transition-timing-function:cubic-bezier(.4,0,.2,1);z-index:0}.v-card{border-color:rgba(var(--v-border-color),var(--v-border-opacity));border-style:solid;border-width:0}.v-card--border{border-width:thin;box-shadow:none}.v-card--absolute{position:absolute}.v-card--fixed{position:fixed}.v-card{border-radius:4px}.v-card:hover>.v-card__overlay{opacity:calc(var(--v-hover-opacity) * var(--v-theme-overlay-multiplier))}.v-card:focus-visible>.v-card__overlay{opacity:calc(var(--v-focus-opacity) * var(--v-theme-overlay-multiplier))}@supports not selector(:focus-visible){.v-card:focus>.v-card__overlay{opacity:calc(var(--v-focus-opacity) * var(--v-theme-overlay-multiplier))}}.v-card--active>.v-card__overlay,.v-card[aria-haspopup=menu][aria-expanded=true]>.v-card__overlay{opacity:calc(var(--v-activated-opacity) * var(--v-theme-overlay-multiplier))}.v-card--active:hover>.v-card__overlay,.v-card[aria-haspopup=menu][aria-expanded=true]:hover>.v-card__overlay{opacity:calc((var(--v-activated-opacity) + var(--v-hover-opacity)) * var(--v-theme-overlay-multiplier))}.v-card--active:focus-visible>.v-card__overlay,.v-card[aria-haspopup=menu][aria-expanded=true]:focus-visible>.v-card__overlay{opacity:calc((var(--v-activated-opacity) + var(--v-focus-opacity)) * var(--v-theme-overlay-multiplier))}@supports not selector(:focus-visible){.v-card--active:focus>.v-card__overlay,.v-card[aria-haspopup=menu][aria-expanded=true]:focus>.v-card__overlay{opacity:calc((var(--v-activated-opacity) + var(--v-focus-opacity)) * var(--v-theme-overlay-multiplier))}}.v-card--variant-plain,.v-card--variant-outlined,.v-card--variant-text,.v-card--variant-tonal{background:transparent;color:inherit}.v-card--variant-plain{opacity:.62}.v-card--variant-plain:focus,.v-card--variant-plain:hover{opacity:1}.v-card--variant-plain .v-card__overlay{display:none}.v-card--variant-elevated,.v-card--variant-flat{background:rgb(var(--v-theme-surface));color:rgba(var(--v-theme-on-surface),var(--v-high-emphasis-opacity))}.v-card--variant-elevated{box-shadow:0 2px 1px -1px var(--v-shadow-key-umbra-opacity, rgba(0, 0, 0, .2)),0 1px 1px 0 var(--v-shadow-key-penumbra-opacity, rgba(0, 0, 0, .14)),0 1px 3px 0 var(--v-shadow-key-ambient-opacity, rgba(0, 0, 0, .12))}.v-card--variant-flat{box-shadow:0 0 0 0 var(--v-shadow-key-umbra-opacity, rgba(0, 0, 0, .2)),0 0 0 0 var(--v-shadow-key-penumbra-opacity, rgba(0, 0, 0, .14)),0 0 0 0 var(--v-shadow-key-ambient-opacity, rgba(0, 0, 0, .12))}.v-card--variant-outlined{border:thin solid currentColor}.v-card--variant-text .v-card__overlay{background:currentColor}.v-card--variant-tonal .v-card__underlay{background:currentColor;opacity:var(--v-activated-opacity);border-radius:inherit;inset:0;pointer-events:none}.v-card .v-card__underlay{position:absolute}.v-card--disabled{pointer-events:none;user-select:none}.v-card--disabled>:not(.v-card__loader){opacity:.6}.v-card--flat{box-shadow:none}.v-card--hover{cursor:pointer}.v-card--hover:before,.v-card--hover:after{border-radius:inherit;content:"";display:block;inset:0;pointer-events:none;position:absolute;transition:inherit}.v-card--hover:before{opacity:1;z-index:-1}.v-card--hover:before{box-shadow:0 2px 1px -1px var(--v-shadow-key-umbra-opacity, rgba(0, 0, 0, .2)),0 1px 1px 0 var(--v-shadow-key-penumbra-opacity, rgba(0, 0, 0, .14)),0 1px 3px 0 var(--v-shadow-key-ambient-opacity, rgba(0, 0, 0, .12))}.v-card--hover:after{z-index:1;opacity:0}.v-card--hover:after{box-shadow:0 5px 5px -3px var(--v-shadow-key-umbra-opacity, rgba(0, 0, 0, .2)),0 8px 10px 1px var(--v-shadow-key-penumbra-opacity, rgba(0, 0, 0, .14)),0 3px 14px 2px var(--v-shadow-key-ambient-opacity, rgba(0, 0, 0, .12))}.v-card--hover:hover:after{opacity:1}.v-card--hover:hover:before{opacity:0}.v-card--hover:hover{box-shadow:0 5px 5px -3px var(--v-shadow-key-umbra-opacity, rgba(0, 0, 0, .2)),0 8px 10px 1px var(--v-shadow-key-penumbra-opacity, rgba(0, 0, 0, .14)),0 3px 14px 2px var(--v-shadow-key-ambient-opacity, rgba(0, 0, 0, .12))}.v-card--link{cursor:pointer}.v-card-actions{align-items:center;display:flex;flex:none;min-height:52px;padding:.5rem}.v-card-item{align-items:center;display:grid;flex:none;grid-template-areas:"prepend content append";grid-template-columns:max-content auto max-content;padding:.625rem 1rem}.v-card-item+.v-card-text{padding-top:0}.v-card-item__prepend,.v-card-item__append{align-items:center;display:flex}.v-card-item__prepend{grid-area:prepend;padding-inline-end:.5rem}.v-card-item__append{grid-area:append;padding-inline-start:.5rem}.v-card-item__content{align-self:center;grid-area:content;overflow:hidden}.v-card-title{display:block;flex:none;font-size:1.25rem;font-weight:500;hyphens:auto;letter-spacing:.0125em;min-width:0;overflow-wrap:normal;overflow:hidden;padding:.5rem 1rem;text-overflow:ellipsis;text-transform:none;white-space:nowrap;word-break:normal;word-wrap:break-word}.v-card .v-card-title{line-height:1.6}.v-card--density-comfortable .v-card-title{line-height:1.75rem}.v-card--density-compact .v-card-title{line-height:1.55rem}.v-card-item .v-card-title{padding:0}.v-card-title+.v-card-text,.v-card-title+.v-card-actions{padding-top:0}.v-card-subtitle{display:block;flex:none;font-size:.875rem;font-weight:400;letter-spacing:.0178571429em;opacity:var(--v-card-subtitle-opacity, var(--v-medium-emphasis-opacity));overflow:hidden;padding:0 1rem;text-overflow:ellipsis;text-transform:none;white-space:nowrap}.v-card .v-card-subtitle{line-height:1.425}.v-card--density-comfortable .v-card-subtitle{line-height:1.125rem}.v-card--density-compact .v-card-subtitle{line-height:1rem}.v-card-item .v-card-subtitle{padding:0 0 .25rem}.v-card-text{flex:1 1 auto;font-size:.875rem;font-weight:400;letter-spacing:.0178571429em;opacity:var(--v-card-text-opacity, 1);padding:1rem;text-transform:none}.v-card .v-card-text{line-height:1.425}.v-card--density-comfortable .v-card-text{line-height:1.2rem}.v-card--density-compact .v-card-text{line-height:1.15rem}.v-card__image{display:flex;height:100%;flex:1 1 auto;left:0;overflow:hidden;position:absolute;top:0;width:100%;z-index:-1}.v-card__content{border-radius:inherit;overflow:hidden;position:relative}.v-card__loader{inset:0 0 auto;position:absolute;width:100%;z-index:1}.v-card__overlay{background-color:currentColor;border-radius:inherit;position:absolute;inset:0;pointer-events:none;opacity:0;transition:opacity .2s ease-in-out}.v-avatar{flex:none;align-items:center;display:inline-flex;justify-content:center;line-height:normal;overflow:hidden;position:relative;text-align:center;transition:.2s cubic-bezier(.4,0,.2,1);transition-property:width,height;vertical-align:middle}.v-avatar.v-avatar--size-x-small{--v-avatar-height: 24px}.v-avatar.v-avatar--size-small{--v-avatar-height: 32px}.v-avatar.v-avatar--size-default{--v-avatar-height: 40px}.v-avatar.v-avatar--size-large{--v-avatar-height: 48px}.v-avatar.v-avatar--size-x-large{--v-avatar-height: 56px}.v-avatar.v-avatar--density-default{height:calc(var(--v-avatar-height) + 0px);width:calc(var(--v-avatar-height) + 0px)}.v-avatar.v-avatar--density-comfortable{height:calc(var(--v-avatar-height) + -4px);width:calc(var(--v-avatar-height) + -4px)}.v-avatar.v-avatar--density-compact{height:calc(var(--v-avatar-height) + -8px);width:calc(var(--v-avatar-height) + -8px)}.v-avatar{border-radius:50%}.v-avatar--variant-plain,.v-avatar--variant-outlined,.v-avatar--variant-text,.v-avatar--variant-tonal{background:transparent;color:inherit}.v-avatar--variant-plain{opacity:.62}.v-avatar--variant-plain:focus,.v-avatar--variant-plain:hover{opacity:1}.v-avatar--variant-plain .v-avatar__overlay{display:none}.v-avatar--variant-elevated,.v-avatar--variant-flat{background:var(--v-theme-surface);color:rgba(var(--v-theme-on-surface),var(--v-medium-emphasis-opacity))}.v-avatar--variant-elevated{box-shadow:0 2px 1px -1px var(--v-shadow-key-umbra-opacity, rgba(0, 0, 0, .2)),0 1px 1px 0 var(--v-shadow-key-penumbra-opacity, rgba(0, 0, 0, .14)),0 1px 3px 0 var(--v-shadow-key-ambient-opacity, rgba(0, 0, 0, .12))}.v-avatar--variant-flat{box-shadow:0 0 0 0 var(--v-shadow-key-umbra-opacity, rgba(0, 0, 0, .2)),0 0 0 0 var(--v-shadow-key-penumbra-opacity, rgba(0, 0, 0, .14)),0 0 0 0 var(--v-shadow-key-ambient-opacity, rgba(0, 0, 0, .12))}.v-avatar--variant-outlined{border:thin solid currentColor}.v-avatar--variant-text .v-avatar__overlay{background:currentColor}.v-avatar--variant-tonal .v-avatar__underlay{background:currentColor;opacity:var(--v-activated-opacity);border-radius:inherit;inset:0;pointer-events:none}.v-avatar .v-avatar__underlay{position:absolute}.v-avatar--rounded{border-radius:4px}.v-avatar--start{margin-inline-end:8px}.v-avatar--end{margin-inline-start:8px}.v-avatar .v-img{height:100%;width:100%}.v-divider{display:block;flex:1 1 100%;height:0px;max-height:0px;opacity:var(--v-border-opacity);transition:inherit}.v-divider{border-style:solid;border-width:thin 0 0 0}.v-divider--vertical{align-self:stretch;border-width:0 thin 0 0;display:inline-flex;height:auto;margin-left:-1px;max-height:100%;max-width:0px;vertical-align:text-bottom;width:0px}.v-divider--inset:not(.v-divider--vertical){max-width:calc(100% - 72px);margin-inline-start:72px}.v-divider--inset.v-divider--vertical{margin-bottom:8px;margin-top:8px;max-height:calc(100% - 16px)}.v-divider__content{padding:0 16px;text-wrap:nowrap}.v-divider__wrapper--vertical .v-divider__content{padding:4px 0}.v-divider__wrapper{display:flex;align-items:center;justify-content:center}.v-divider__wrapper--vertical{flex-direction:column;height:100%}.v-divider__wrapper--vertical .v-divider{margin:0 auto} diff --git a/pr-preview/pr-17/assets/VImg-i8uxgNTt.js b/pr-preview/pr-17/assets/VImg-CLLthewK.js similarity index 88% rename from pr-preview/pr-17/assets/VImg-i8uxgNTt.js rename to pr-preview/pr-17/assets/VImg-CLLthewK.js index f2221df..395d1c3 100644 --- a/pr-preview/pr-17/assets/VImg-i8uxgNTt.js +++ b/pr-preview/pr-17/assets/VImg-CLLthewK.js @@ -1 +1 @@ -import{bJ as O,p as W,e as D,ac as K,g as $,ad as Q,a as E,b as n,c as h,ag as G,Q as X,R as Y,aj as Z,bh as p,s as f,r as ee,w as C,bK as te,D as ne,am as re,t as U,v as ae,F as se,d as ie,C as le,B as oe}from"./index-BHzPgH2J.js";import{m as ue,M as b}from"./transition-zS3yGrDV.js";function ce(e,s){if(!O)return;const i=s.modifiers||{},l=s.value,{handler:v,options:R}=typeof l=="object"?l:{handler:l,options:{}},S=new IntersectionObserver(function(){let c=arguments.length>0&&arguments[0]!==void 0?arguments[0]:[],_=arguments.length>1?arguments[1]:void 0;const r=e._observe?.[s.instance.$.uid];if(!r)return;const a=c.some(d=>d.isIntersecting);v&&(!i.quiet||r.init)&&(!i.once||a||r.init)&&v(a,c,_),a&&i.once?M(e,s):r.init=!0},R);e._observe=Object(e._observe),e._observe[s.instance.$.uid]={init:!1,observer:S},S.observe(e)}function M(e,s){const i=e._observe?.[s.instance.$.uid];i&&(i.observer.unobserve(e),delete e._observe[s.instance.$.uid])}const de={mounted:ce,unmounted:M};function ve(e){return{aspectStyles:h(()=>{const s=Number(e.aspectRatio);return s?{paddingBottom:String(1/s*100)+"%"}:void 0})}}const q=W({aspectRatio:[String,Number],contentClass:null,inline:Boolean,...D(),...K()},"VResponsive"),F=$()({name:"VResponsive",props:q(),setup(e,s){let{slots:i}=s;const{aspectStyles:l}=ve(e),{dimensionStyles:v}=Q(e);return E(()=>n("div",{class:["v-responsive",{"v-responsive--inline":e.inline},e.class],style:[v.value,e.style]},[n("div",{class:"v-responsive__sizer",style:l.value},null),i.additional?.(),i.default&&n("div",{class:["v-responsive__content",e.contentClass]},[i.default()])])),{}}}),ge=W({alt:String,cover:Boolean,color:String,draggable:{type:[Boolean,String],default:void 0},eager:Boolean,gradient:String,lazySrc:String,options:{type:Object,default:()=>({root:void 0,rootMargin:void 0,threshold:void 0})},sizes:String,src:{type:[String,Object],default:""},crossorigin:String,referrerpolicy:String,srcset:String,position:String,...q(),...D(),...G(),...ue()},"VImg"),Se=$()({name:"VImg",directives:{intersect:de},props:ge(),emits:{loadstart:e=>!0,load:e=>!0,error:e=>!0},setup(e,s){let{emit:i,slots:l}=s;const{backgroundColorClasses:v,backgroundColorStyles:R}=X(Y(e,"color")),{roundedClasses:S}=Z(e),c=p("VImg"),_=f(""),r=ee(),a=f(e.eager?"loading":"idle"),d=f(),y=f(),o=h(()=>e.src&&typeof e.src=="object"?{src:e.src.src,srcset:e.srcset||e.src.srcset,lazySrc:e.lazySrc||e.src.lazySrc,aspect:Number(e.aspectRatio||e.src.aspect||0)}:{src:e.src,srcset:e.srcset,lazySrc:e.lazySrc,aspect:Number(e.aspectRatio||0)}),g=h(()=>o.value.aspect||d.value/y.value||0);C(()=>e.src,()=>{z(a.value!=="idle")}),C(g,(t,u)=>{!t&&u&&r.value&&m(r.value)}),te(()=>z());function z(t){if(!(e.eager&&t)&&!(O&&!t&&!e.eager)){if(a.value="loading",o.value.lazySrc){const u=new Image;u.src=o.value.lazySrc,m(u,null)}o.value.src&&ne(()=>{i("loadstart",r.value?.currentSrc||o.value.src),setTimeout(()=>{if(!c.isUnmounted)if(r.value?.complete){if(r.value.naturalWidth||w(),a.value==="error")return;g.value||m(r.value,null),a.value==="loading"&&P()}else g.value||m(r.value),k()})})}}function P(){c.isUnmounted||(k(),m(r.value),a.value="loaded",i("load",r.value?.currentSrc||o.value.src))}function w(){c.isUnmounted||(a.value="error",i("error",r.value?.currentSrc||o.value.src))}function k(){const t=r.value;t&&(_.value=t.currentSrc||t.src)}let I=-1;re(()=>{clearTimeout(I)});function m(t){let u=arguments.length>1&&arguments[1]!==void 0?arguments[1]:100;const B=()=>{if(clearTimeout(I),c.isUnmounted)return;const{naturalHeight:j,naturalWidth:N}=t;j||N?(d.value=N,y.value=j):!t.complete&&a.value==="loading"&&u!=null?I=window.setTimeout(B,u):(t.currentSrc.endsWith(".svg")||t.currentSrc.startsWith("data:image/svg+xml"))&&(d.value=1,y.value=1)};B()}const T=h(()=>({"v-img__img--cover":e.cover,"v-img__img--contain":!e.cover})),x=()=>{if(!o.value.src||a.value==="idle")return null;const t=n("img",{class:["v-img__img",T.value],style:{objectPosition:e.position},src:o.value.src,srcset:o.value.srcset,alt:e.alt,crossorigin:e.crossorigin,referrerpolicy:e.referrerpolicy,draggable:e.draggable,sizes:e.sizes,ref:r,onLoad:P,onError:w},null),u=l.sources?.();return n(b,{transition:e.transition,appear:!0},{default:()=>[U(u?n("picture",{class:"v-img__picture"},[u,t]):t,[[oe,a.value==="loaded"]])]})},A=()=>n(b,{transition:e.transition},{default:()=>[o.value.lazySrc&&a.value!=="loaded"&&n("img",{class:["v-img__img","v-img__img--preload",T.value],style:{objectPosition:e.position},src:o.value.lazySrc,alt:e.alt,crossorigin:e.crossorigin,referrerpolicy:e.referrerpolicy,draggable:e.draggable},null)]}),H=()=>l.placeholder?n(b,{transition:e.transition,appear:!0},{default:()=>[(a.value==="loading"||a.value==="error"&&!l.error)&&n("div",{class:"v-img__placeholder"},[l.placeholder()])]}):null,L=()=>l.error?n(b,{transition:e.transition,appear:!0},{default:()=>[a.value==="error"&&n("div",{class:"v-img__error"},[l.error()])]}):null,J=()=>e.gradient?n("div",{class:"v-img__gradient",style:{backgroundImage:`linear-gradient(${e.gradient})`}},null):null,V=f(!1);{const t=C(g,u=>{u&&(requestAnimationFrame(()=>{requestAnimationFrame(()=>{V.value=!0})}),t())})}return E(()=>{const t=F.filterProps(e);return U(n(F,ie({class:["v-img",{"v-img--booting":!V.value},v.value,S.value,e.class],style:[{width:le(e.width==="auto"?d.value:e.width)},R.value,e.style]},t,{aspectRatio:g.value,"aria-label":e.alt,role:e.alt?"img":void 0}),{additional:()=>n(se,null,[n(x,null,null),n(A,null,null),n(J,null,null),n(H,null,null),n(L,null,null)]),default:l.default}),[[ae("intersect"),{handler:z,options:e.options},null,{once:!0}]])}),{currentSrc:_,image:r,state:a,naturalWidth:d,naturalHeight:y}}});export{Se as V}; +import{bh as O,p as W,e as D,ac as G,g as $,ad as J,a as E,b as n,c as h,ag as K,Q as X,R as Y,aj as Z,bi as p,s as f,r as ee,w as C,bj as te,D as ne,am as re,t as U,v as ae,F as se,d as ie,C as le,B as oe}from"./index-Dvu417lt.js";import{m as ue,M as b}from"./transition-BKtsYhmO.js";function ce(e,s){if(!O)return;const i=s.modifiers||{},l=s.value,{handler:v,options:R}=typeof l=="object"?l:{handler:l,options:{}},S=new IntersectionObserver(function(){let c=arguments.length>0&&arguments[0]!==void 0?arguments[0]:[],_=arguments.length>1?arguments[1]:void 0;const r=e._observe?.[s.instance.$.uid];if(!r)return;const a=c.some(d=>d.isIntersecting);v&&(!i.quiet||r.init)&&(!i.once||a||r.init)&&v(a,c,_),a&&i.once?M(e,s):r.init=!0},R);e._observe=Object(e._observe),e._observe[s.instance.$.uid]={init:!1,observer:S},S.observe(e)}function M(e,s){const i=e._observe?.[s.instance.$.uid];i&&(i.observer.unobserve(e),delete e._observe[s.instance.$.uid])}const de={mounted:ce,unmounted:M};function ve(e){return{aspectStyles:h(()=>{const s=Number(e.aspectRatio);return s?{paddingBottom:String(1/s*100)+"%"}:void 0})}}const q=W({aspectRatio:[String,Number],contentClass:null,inline:Boolean,...D(),...G()},"VResponsive"),F=$()({name:"VResponsive",props:q(),setup(e,s){let{slots:i}=s;const{aspectStyles:l}=ve(e),{dimensionStyles:v}=J(e);return E(()=>n("div",{class:["v-responsive",{"v-responsive--inline":e.inline},e.class],style:[v.value,e.style]},[n("div",{class:"v-responsive__sizer",style:l.value},null),i.additional?.(),i.default&&n("div",{class:["v-responsive__content",e.contentClass]},[i.default()])])),{}}}),ge=W({alt:String,cover:Boolean,color:String,draggable:{type:[Boolean,String],default:void 0},eager:Boolean,gradient:String,lazySrc:String,options:{type:Object,default:()=>({root:void 0,rootMargin:void 0,threshold:void 0})},sizes:String,src:{type:[String,Object],default:""},crossorigin:String,referrerpolicy:String,srcset:String,position:String,...q(),...D(),...K(),...ue()},"VImg"),Se=$()({name:"VImg",directives:{intersect:de},props:ge(),emits:{loadstart:e=>!0,load:e=>!0,error:e=>!0},setup(e,s){let{emit:i,slots:l}=s;const{backgroundColorClasses:v,backgroundColorStyles:R}=X(Y(e,"color")),{roundedClasses:S}=Z(e),c=p("VImg"),_=f(""),r=ee(),a=f(e.eager?"loading":"idle"),d=f(),y=f(),o=h(()=>e.src&&typeof e.src=="object"?{src:e.src.src,srcset:e.srcset||e.src.srcset,lazySrc:e.lazySrc||e.src.lazySrc,aspect:Number(e.aspectRatio||e.src.aspect||0)}:{src:e.src,srcset:e.srcset,lazySrc:e.lazySrc,aspect:Number(e.aspectRatio||0)}),g=h(()=>o.value.aspect||d.value/y.value||0);C(()=>e.src,()=>{z(a.value!=="idle")}),C(g,(t,u)=>{!t&&u&&r.value&&m(r.value)}),te(()=>z());function z(t){if(!(e.eager&&t)&&!(O&&!t&&!e.eager)){if(a.value="loading",o.value.lazySrc){const u=new Image;u.src=o.value.lazySrc,m(u,null)}o.value.src&&ne(()=>{i("loadstart",r.value?.currentSrc||o.value.src),setTimeout(()=>{if(!c.isUnmounted)if(r.value?.complete){if(r.value.naturalWidth||w(),a.value==="error")return;g.value||m(r.value,null),a.value==="loading"&&P()}else g.value||m(r.value),k()})})}}function P(){c.isUnmounted||(k(),m(r.value),a.value="loaded",i("load",r.value?.currentSrc||o.value.src))}function w(){c.isUnmounted||(a.value="error",i("error",r.value?.currentSrc||o.value.src))}function k(){const t=r.value;t&&(_.value=t.currentSrc||t.src)}let I=-1;re(()=>{clearTimeout(I)});function m(t){let u=arguments.length>1&&arguments[1]!==void 0?arguments[1]:100;const B=()=>{if(clearTimeout(I),c.isUnmounted)return;const{naturalHeight:j,naturalWidth:N}=t;j||N?(d.value=N,y.value=j):!t.complete&&a.value==="loading"&&u!=null?I=window.setTimeout(B,u):(t.currentSrc.endsWith(".svg")||t.currentSrc.startsWith("data:image/svg+xml"))&&(d.value=1,y.value=1)};B()}const T=h(()=>({"v-img__img--cover":e.cover,"v-img__img--contain":!e.cover})),x=()=>{if(!o.value.src||a.value==="idle")return null;const t=n("img",{class:["v-img__img",T.value],style:{objectPosition:e.position},src:o.value.src,srcset:o.value.srcset,alt:e.alt,crossorigin:e.crossorigin,referrerpolicy:e.referrerpolicy,draggable:e.draggable,sizes:e.sizes,ref:r,onLoad:P,onError:w},null),u=l.sources?.();return n(b,{transition:e.transition,appear:!0},{default:()=>[U(u?n("picture",{class:"v-img__picture"},[u,t]):t,[[oe,a.value==="loaded"]])]})},A=()=>n(b,{transition:e.transition},{default:()=>[o.value.lazySrc&&a.value!=="loaded"&&n("img",{class:["v-img__img","v-img__img--preload",T.value],style:{objectPosition:e.position},src:o.value.lazySrc,alt:e.alt,crossorigin:e.crossorigin,referrerpolicy:e.referrerpolicy,draggable:e.draggable},null)]}),H=()=>l.placeholder?n(b,{transition:e.transition,appear:!0},{default:()=>[(a.value==="loading"||a.value==="error"&&!l.error)&&n("div",{class:"v-img__placeholder"},[l.placeholder()])]}):null,L=()=>l.error?n(b,{transition:e.transition,appear:!0},{default:()=>[a.value==="error"&&n("div",{class:"v-img__error"},[l.error()])]}):null,Q=()=>e.gradient?n("div",{class:"v-img__gradient",style:{backgroundImage:`linear-gradient(${e.gradient})`}},null):null,V=f(!1);{const t=C(g,u=>{u&&(requestAnimationFrame(()=>{requestAnimationFrame(()=>{V.value=!0})}),t())})}return E(()=>{const t=F.filterProps(e);return U(n(F,ie({class:["v-img",{"v-img--booting":!V.value},v.value,S.value,e.class],style:[{width:le(e.width==="auto"?d.value:e.width)},R.value,e.style]},t,{aspectRatio:g.value,"aria-label":e.alt,role:e.alt?"img":void 0}),{additional:()=>n(se,null,[n(x,null,null),n(A,null,null),n(Q,null,null),n(H,null,null),n(L,null,null)]),default:l.default}),[[ae("intersect"),{handler:z,options:e.options},null,{once:!0}]])}),{currentSrc:_,image:r,state:a,naturalWidth:d,naturalHeight:y}}});export{Se as V}; diff --git a/pr-preview/pr-17/assets/VMain-CoJ_6Ucg.js b/pr-preview/pr-17/assets/VMain-CoSaaYTf.js similarity index 78% rename from pr-preview/pr-17/assets/VMain-CoJ_6Ucg.js rename to pr-preview/pr-17/assets/VMain-CoSaaYTf.js index aa53cce..f8f7fc6 100644 --- a/pr-preview/pr-17/assets/VMain-CoJ_6Ucg.js +++ b/pr-preview/pr-17/assets/VMain-CoSaaYTf.js @@ -1 +1 @@ -import{p as i,e as m,ac as c,f as u,g as d,ad as y,Y as v,a as f,b as e}from"./index-BHzPgH2J.js";import{u as V}from"./ssrBoot-7hoALQc5.js";const b=i({scrollable:Boolean,...m(),...c(),...u({tag:"main"})},"VMain"),k=d()({name:"VMain",props:b(),setup(a,o){let{slots:s}=o;const{dimensionStyles:l}=y(a),{mainStyles:t,layoutIsReady:n}=v(),{ssrBootStyles:r}=V();return f(()=>e(a.tag,{class:["v-main",{"v-main--scrollable":a.scrollable},a.class],style:[t.value,r.value,l.value,a.style]},{default:()=>[a.scrollable?e("div",{class:"v-main__scroller"},[s.default?.()]):s.default?.()]})),n}});export{k as V}; +import{p as i,e as m,ac as c,f as u,g as d,ad as y,Y as v,a as f,b as e}from"./index-Dvu417lt.js";import{u as V}from"./ssrBoot-Uu_-yAhn.js";const b=i({scrollable:Boolean,...m(),...c(),...u({tag:"main"})},"VMain"),k=d()({name:"VMain",props:b(),setup(a,o){let{slots:s}=o;const{dimensionStyles:l}=y(a),{mainStyles:t,layoutIsReady:n}=v(),{ssrBootStyles:r}=V();return f(()=>e(a.tag,{class:["v-main",{"v-main--scrollable":a.scrollable},a.class],style:[t.value,r.value,l.value,a.style]},{default:()=>[a.scrollable?e("div",{class:"v-main__scroller"},[s.default?.()]):s.default?.()]})),n}});export{k as V}; diff --git a/pr-preview/pr-17/assets/VOverlay-Di1btkZg.js b/pr-preview/pr-17/assets/VOverlay-DGc1wXYF.js similarity index 83% rename from pr-preview/pr-17/assets/VOverlay-Di1btkZg.js rename to pr-preview/pr-17/assets/VOverlay-DGc1wXYF.js index 792fbcf..464b8c0 100644 --- a/pr-preview/pr-17/assets/VOverlay-Di1btkZg.js +++ b/pr-preview/pr-17/assets/VOverlay-DGc1wXYF.js @@ -1 +1 @@ -import{b6 as ke,b7 as Oe,p as G,r as V,L as j,ao as se,w as L,b8 as _,b9 as De,ba as ve,bb as te,bc as ne,bd as de,c as P,D as ce,be as me,C as F,al as ye,ap as ue,bf as Pe,bg as Ve,bh as Ce,x as pe,bi as ge,d as W,bj as Ie,s as Y,H as We,Z as je,aL as Ae,q as qe,bk as ze,bl as $e,e as Ye,ac as Ge,h as Ue,g as Xe,y as Ze,i as Ke,j as Qe,Q as Je,R as et,ad as tt,am as nt,bm as ot,a as at,b as D,bn as rt,t as it,B as lt,v as st,F as ct,ab as ut,bo as ft}from"./index-BHzPgH2J.js";import{g as vt,B as oe,e as he,n as dt,m as mt,u as yt,b as gt,a as ht,s as bt}from"./forwardRefs-BoZnhoLd.js";import{m as wt,M as Et}from"./transition-zS3yGrDV.js";const Z=new WeakMap;function St(e,t){Object.keys(t).forEach(n=>{if(ke(n)){const o=Oe(n),r=Z.get(e);if(t[n]==null)r?.forEach(l=>{const[a,s]=l;a===o&&(e.removeEventListener(o,s),r.delete(l))});else if(!r||![...r].some(l=>l[0]===o&&l[1]===t[n])){e.addEventListener(o,t[n]);const l=r||new Set;l.add([o,t[n]]),Z.has(e)||Z.set(e,l)}}else t[n]==null?e.removeAttribute(n):e.setAttribute(n,t[n])})}function xt(e,t){Object.keys(t).forEach(n=>{if(ke(n)){const o=Oe(n),r=Z.get(e);r?.forEach(l=>{const[a,s]=l;a===o&&(e.removeEventListener(o,s),r.delete(l))})}else e.removeAttribute(n)})}function Te(e){if(typeof e.getRootNode!="function"){for(;e.parentNode;)e=e.parentNode;return e!==document?null:document}const t=e.getRootNode();return t!==document&&t.getRootNode({composed:!0})!==document?null:t}function kt(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1;for(;e;){if(t?Ot(e):fe(e))return e;e=e.parentElement}return document.scrollingElement}function K(e,t){const n=[];if(t&&e&&!t.contains(e))return n;for(;e&&(fe(e)&&n.push(e),e!==t);)e=e.parentElement;return n}function fe(e){if(!e||e.nodeType!==Node.ELEMENT_NODE)return!1;const t=window.getComputedStyle(e);return t.overflowY==="scroll"||t.overflowY==="auto"&&e.scrollHeight>e.clientHeight}function Ot(e){if(!e||e.nodeType!==Node.ELEMENT_NODE)return!1;const t=window.getComputedStyle(e);return["scroll","auto"].includes(t.overflowY)}function Pt(e){for(;e;){if(window.getComputedStyle(e).position==="fixed")return!0;e=e.offsetParent}return!1}function Ct(){return!0}function Le(e,t,n){if(!e||Be(e,n)===!1)return!1;const o=Te(t);if(typeof ShadowRoot<"u"&&o instanceof ShadowRoot&&o.host===e.target)return!1;const r=(typeof n.value=="object"&&n.value.include||(()=>[]))();return r.push(t),!r.some(l=>l?.contains(e.target))}function Be(e,t){return(typeof t.value=="object"&&t.value.closeConditional||Ct)(e)}function pt(e,t,n){const o=typeof n.value=="function"?n.value:n.value.handler;t._clickOutside.lastMousedownWasOutside&&Le(e,t,n)&&setTimeout(()=>{Be(e,n)&&o&&o(e)},0)}function be(e,t){const n=Te(e);t(document),typeof ShadowRoot<"u"&&n instanceof ShadowRoot&&t(n)}const At={mounted(e,t){const n=r=>pt(r,e,t),o=r=>{e._clickOutside.lastMousedownWasOutside=Le(r,e,t)};be(e,r=>{r.addEventListener("click",n,!0),r.addEventListener("mousedown",o,!0)}),e._clickOutside||(e._clickOutside={lastMousedownWasOutside:!1}),e._clickOutside[t.instance.$.uid]={onClick:n,onMousedown:o}},unmounted(e,t){e._clickOutside&&(be(e,n=>{if(!n||!e._clickOutside?.[t.instance.$.uid])return;const{onClick:o,onMousedown:r}=e._clickOutside[t.instance.$.uid];n.removeEventListener("click",o,!0),n.removeEventListener("mousedown",r,!0)}),delete e._clickOutside[t.instance.$.uid])}};function ae(e,t){return{x:e.x+t.x,y:e.y+t.y}}function Tt(e,t){return{x:e.x-t.x,y:e.y-t.y}}function we(e,t){if(e.side==="top"||e.side==="bottom"){const{side:n,align:o}=e,r=o==="left"?0:o==="center"?t.width/2:o==="right"?t.width:o,l=n==="top"?0:n==="bottom"?t.height:n;return ae({x:r,y:l},t)}else if(e.side==="left"||e.side==="right"){const{side:n,align:o}=e,r=n==="left"?0:n==="right"?t.width:n,l=o==="top"?0:o==="center"?t.height/2:o==="bottom"?t.height:o;return ae({x:r,y:l},t)}return ae({x:t.width/2,y:t.height/2},t)}const Me={static:Mt,connected:Ft},Lt=G({locationStrategy:{type:[String,Function],default:"static",validator:e=>typeof e=="function"||e in Me},location:{type:String,default:"bottom"},origin:{type:String,default:"auto"},offset:[Number,String,Array]},"VOverlay-location-strategies");function Bt(e,t){const n=V({}),o=V();j&&se(()=>!!(t.isActive.value&&e.locationStrategy),l=>{L(()=>e.locationStrategy,l),_(()=>{window.removeEventListener("resize",r),o.value=void 0}),window.addEventListener("resize",r,{passive:!0}),typeof e.locationStrategy=="function"?o.value=e.locationStrategy(t,e,n)?.updateLocation:o.value=Me[e.locationStrategy](t,e,n)?.updateLocation});function r(l){o.value?.(l)}return{contentStyles:n,updateLocation:o}}function Mt(){}function Rt(e,t){t?e.style.removeProperty("left"):e.style.removeProperty("right");const n=dt(e);return t?n.x+=parseFloat(e.style.right||0):n.x-=parseFloat(e.style.left||0),n.y-=parseFloat(e.style.top||0),n}function Ft(e,t,n){(Array.isArray(e.target.value)||Pt(e.target.value))&&Object.assign(n.value,{position:"fixed",top:0,[e.isRtl.value?"right":"left"]:0});const{preferredAnchor:r,preferredOrigin:l}=De(()=>{const u=ve(t.location,e.isRtl.value),c=t.origin==="overlap"?u:t.origin==="auto"?te(u):ve(t.origin,e.isRtl.value);return u.side===c.side&&u.align===ne(c).align?{preferredAnchor:de(u),preferredOrigin:de(c)}:{preferredAnchor:u,preferredOrigin:c}}),[a,s,d,m]=["minWidth","minHeight","maxWidth","maxHeight"].map(u=>P(()=>{const c=parseFloat(t[u]);return isNaN(c)?1/0:c})),y=P(()=>{if(Array.isArray(t.offset))return t.offset;if(typeof t.offset=="string"){const u=t.offset.split(" ").map(parseFloat);return u.length<2&&u.push(0),u}return typeof t.offset=="number"?[t.offset,0]:[0,0]});let C=!1;const k=new ResizeObserver(()=>{C&&S()});L([e.target,e.contentEl],(u,c)=>{let[x,A]=u,[h,w]=c;h&&!Array.isArray(h)&&k.unobserve(h),x&&!Array.isArray(x)&&k.observe(x),w&&k.unobserve(w),A&&k.observe(A)},{immediate:!0}),_(()=>{k.disconnect()});function S(){if(C=!1,requestAnimationFrame(()=>C=!0),!e.target.value||!e.contentEl.value)return;const u=vt(e.target.value),c=Rt(e.contentEl.value,e.isRtl.value),x=K(e.contentEl.value),A=12;x.length||(x.push(document.documentElement),e.contentEl.value.style.top&&e.contentEl.value.style.left||(c.x-=parseFloat(document.documentElement.style.getPropertyValue("--v-body-scroll-x")||0),c.y-=parseFloat(document.documentElement.style.getPropertyValue("--v-body-scroll-y")||0)));const h=x.reduce((E,g)=>{const f=g.getBoundingClientRect(),v=new oe({x:g===document.documentElement?0:f.x,y:g===document.documentElement?0:f.y,width:g.clientWidth,height:g.clientHeight});return E?new oe({x:Math.max(E.left,v.left),y:Math.max(E.top,v.top),width:Math.min(E.right,v.right)-Math.max(E.left,v.left),height:Math.min(E.bottom,v.bottom)-Math.max(E.top,v.top)}):v},void 0);h.x+=A,h.y+=A,h.width-=A*2,h.height-=A*2;let w={anchor:r.value,origin:l.value};function H(E){const g=new oe(c),f=we(E.anchor,u),v=we(E.origin,g);let{x:M,y:T}=Tt(f,v);switch(E.anchor.side){case"top":T-=y.value[0];break;case"bottom":T+=y.value[0];break;case"left":M-=y.value[0];break;case"right":M+=y.value[0];break}switch(E.anchor.align){case"top":T-=y.value[1];break;case"bottom":T+=y.value[1];break;case"left":M-=y.value[1];break;case"right":M+=y.value[1];break}return g.x+=M,g.y+=T,g.width=Math.min(g.width,d.value),g.height=Math.min(g.height,m.value),{overflows:he(g,h),x:M,y:T}}let B=0,p=0;const i={x:0,y:0},N={x:!1,y:!1};let J=-1;for(;!(J++>10);){const{x:E,y:g,overflows:f}=H(w);B+=E,p+=g,c.x+=E,c.y+=g;{const v=me(w.anchor),M=f.x.before||f.x.after,T=f.y.before||f.y.after;let z=!1;if(["x","y"].forEach(O=>{if(O==="x"&&M&&!N.x||O==="y"&&T&&!N.y){const R={anchor:{...w.anchor},origin:{...w.origin}},U=O==="x"?v==="y"?ne:te:v==="y"?te:ne;R.anchor=U(R.anchor),R.origin=U(R.origin);const{overflows:I}=H(R);(I[O].before<=f[O].before&&I[O].after<=f[O].after||I[O].before+I[O].after<(f[O].before+f[O].after)/2)&&(w=R,z=N[O]=!0)}}),z)continue}f.x.before&&(B+=f.x.before,c.x+=f.x.before),f.x.after&&(B-=f.x.after,c.x-=f.x.after),f.y.before&&(p+=f.y.before,c.y+=f.y.before),f.y.after&&(p-=f.y.after,c.y-=f.y.after);{const v=he(c,h);i.x=h.width-v.x.before-v.x.after,i.y=h.height-v.y.before-v.y.after,B+=v.x.before,c.x+=v.x.before,p+=v.y.before,c.y+=v.y.before}break}const ee=me(w.anchor);return Object.assign(n.value,{"--v-overlay-anchor-origin":`${w.anchor.side} ${w.anchor.align}`,transformOrigin:`${w.origin.side} ${w.origin.align}`,top:F(re(p)),left:e.isRtl.value?void 0:F(re(B)),right:e.isRtl.value?F(re(-B)):void 0,minWidth:F(ee==="y"?Math.min(a.value,u.width):a.value),maxWidth:F(Ee(ye(i.x,a.value===1/0?0:a.value,d.value))),maxHeight:F(Ee(ye(i.y,s.value===1/0?0:s.value,m.value)))}),{available:i,contentBox:c}}return L(()=>[r.value,l.value,t.offset,t.minWidth,t.minHeight,t.maxWidth,t.maxHeight],()=>S()),ce(()=>{const u=S();if(!u)return;const{available:c,contentBox:x}=u;x.height>c.y&&requestAnimationFrame(()=>{S(),requestAnimationFrame(()=>{S()})})}),{updateLocation:S}}function re(e){return Math.round(e*devicePixelRatio)/devicePixelRatio}function Ee(e){return Math.ceil(e*devicePixelRatio)/devicePixelRatio}let ie=!0;const Q=[];function Nt(e){!ie||Q.length?(Q.push(e),le()):(ie=!1,e(),le())}let Se=-1;function le(){cancelAnimationFrame(Se),Se=requestAnimationFrame(()=>{const e=Q.shift();e&&e(),Q.length?le():ie=!0})}const Re={none:null,close:Dt,block:Vt,reposition:It},_t=G({scrollStrategy:{type:[String,Function],default:"block",validator:e=>typeof e=="function"||e in Re}},"VOverlay-scroll-strategies");function Ht(e,t){if(!j)return;let n;ue(async()=>{n?.stop(),t.isActive.value&&e.scrollStrategy&&(n=Pe(),await new Promise(o=>setTimeout(o)),n.active&&n.run(()=>{typeof e.scrollStrategy=="function"?e.scrollStrategy(t,e,n):Re[e.scrollStrategy]?.(t,e,n)}))}),_(()=>{n?.stop()})}function Dt(e){function t(n){e.isActive.value=!1}Fe(e.targetEl.value??e.contentEl.value,t)}function Vt(e,t){const n=e.root.value?.offsetParent,o=[...new Set([...K(e.targetEl.value,t.contained?n:void 0),...K(e.contentEl.value,t.contained?n:void 0)])].filter(a=>!a.classList.contains("v-overlay-scroll-blocked")),r=window.innerWidth-document.documentElement.offsetWidth,l=(a=>fe(a)&&a)(n||document.documentElement);l&&e.root.value.classList.add("v-overlay--scroll-blocked"),o.forEach((a,s)=>{a.style.setProperty("--v-body-scroll-x",F(-a.scrollLeft)),a.style.setProperty("--v-body-scroll-y",F(-a.scrollTop)),a!==document.documentElement&&a.style.setProperty("--v-scrollbar-offset",F(r)),a.classList.add("v-overlay-scroll-blocked")}),_(()=>{o.forEach((a,s)=>{const d=parseFloat(a.style.getPropertyValue("--v-body-scroll-x")),m=parseFloat(a.style.getPropertyValue("--v-body-scroll-y")),y=a.style.scrollBehavior;a.style.scrollBehavior="auto",a.style.removeProperty("--v-body-scroll-x"),a.style.removeProperty("--v-body-scroll-y"),a.style.removeProperty("--v-scrollbar-offset"),a.classList.remove("v-overlay-scroll-blocked"),a.scrollLeft=-d,a.scrollTop=-m,a.style.scrollBehavior=y}),l&&e.root.value.classList.remove("v-overlay--scroll-blocked")})}function It(e,t,n){let o=!1,r=-1,l=-1;function a(s){Nt(()=>{const d=performance.now();e.updateLocation.value?.(s),o=(performance.now()-d)/(1e3/60)>2})}l=(typeof requestIdleCallback>"u"?s=>s():requestIdleCallback)(()=>{n.run(()=>{Fe(e.targetEl.value??e.contentEl.value,s=>{o?(cancelAnimationFrame(r),r=requestAnimationFrame(()=>{r=requestAnimationFrame(()=>{a(s)})})):a(s)})})}),_(()=>{typeof cancelIdleCallback<"u"&&cancelIdleCallback(l),cancelAnimationFrame(r)})}function Fe(e,t){const n=[document,...K(e)];n.forEach(o=>{o.addEventListener("scroll",t,{passive:!0})}),_(()=>{n.forEach(o=>{o.removeEventListener("scroll",t)})})}const Wt=Symbol.for("vuetify:v-menu"),jt=G({closeDelay:[Number,String],openDelay:[Number,String]},"delay");function qt(e,t){let n=()=>{};function o(a){n?.();const s=Number(a?e.openDelay:e.closeDelay);return new Promise(d=>{n=Ve(s,()=>{t?.(a),d(a)})})}function r(){return o(!0)}function l(){return o(!1)}return{clearDelay:n,runOpenDelay:r,runCloseDelay:l}}const zt=G({target:[String,Object],activator:[String,Object],activatorProps:{type:Object,default:()=>({})},openOnClick:{type:Boolean,default:void 0},openOnHover:Boolean,openOnFocus:{type:Boolean,default:void 0},closeOnContentClick:Boolean,...jt()},"VOverlay-activator");function $t(e,t){let{isActive:n,isTop:o}=t;const r=Ce("useActivator"),l=V();let a=!1,s=!1,d=!0;const m=P(()=>e.openOnFocus||e.openOnFocus==null&&e.openOnHover),y=P(()=>e.openOnClick||e.openOnClick==null&&!e.openOnHover&&!m.value),{runOpenDelay:C,runCloseDelay:k}=qt(e,i=>{i===(e.openOnHover&&a||m.value&&s)&&!(e.openOnHover&&n.value&&!o.value)&&(n.value!==i&&(d=!0),n.value=i)}),S=V(),u={onClick:i=>{i.stopPropagation(),l.value=i.currentTarget||i.target,n.value||(S.value=[i.clientX,i.clientY]),n.value=!n.value},onMouseenter:i=>{i.sourceCapabilities?.firesTouchEvents||(a=!0,l.value=i.currentTarget||i.target,C())},onMouseleave:i=>{a=!1,k()},onFocus:i=>{Ie(i.target,":focus-visible")!==!1&&(s=!0,i.stopPropagation(),l.value=i.currentTarget||i.target,C())},onBlur:i=>{s=!1,i.stopPropagation(),k()}},c=P(()=>{const i={};return y.value&&(i.onClick=u.onClick),e.openOnHover&&(i.onMouseenter=u.onMouseenter,i.onMouseleave=u.onMouseleave),m.value&&(i.onFocus=u.onFocus,i.onBlur=u.onBlur),i}),x=P(()=>{const i={};if(e.openOnHover&&(i.onMouseenter=()=>{a=!0,C()},i.onMouseleave=()=>{a=!1,k()}),m.value&&(i.onFocusin=()=>{s=!0,C()},i.onFocusout=()=>{s=!1,k()}),e.closeOnContentClick){const N=pe(Wt,null);i.onClick=()=>{n.value=!1,N?.closeParents()}}return i}),A=P(()=>{const i={};return e.openOnHover&&(i.onMouseenter=()=>{d&&(a=!0,d=!1,C())},i.onMouseleave=()=>{a=!1,k()}),i});L(o,i=>{i&&(e.openOnHover&&!a&&(!m.value||!s)||m.value&&!s&&(!e.openOnHover||!a))&&(n.value=!1)}),L(n,i=>{i||setTimeout(()=>{S.value=void 0})},{flush:"post"});const h=ge();ue(()=>{h.value&&ce(()=>{l.value=h.el})});const w=ge(),H=P(()=>e.target==="cursor"&&S.value?S.value:w.value?w.el:Ne(e.target,r)||l.value),B=P(()=>Array.isArray(H.value)?void 0:H.value);let p;return L(()=>!!e.activator,i=>{i&&j?(p=Pe(),p.run(()=>{Yt(e,r,{activatorEl:l,activatorEvents:c})})):p&&p.stop()},{flush:"post",immediate:!0}),_(()=>{p?.stop()}),{activatorEl:l,activatorRef:h,target:H,targetEl:B,targetRef:w,activatorEvents:c,contentEvents:x,scrimEvents:A}}function Yt(e,t,n){let{activatorEl:o,activatorEvents:r}=n;L(()=>e.activator,(d,m)=>{if(m&&d!==m){const y=s(m);y&&a(y)}d&&ce(()=>l())},{immediate:!0}),L(()=>e.activatorProps,()=>{l()}),_(()=>{a()});function l(){let d=arguments.length>0&&arguments[0]!==void 0?arguments[0]:s(),m=arguments.length>1&&arguments[1]!==void 0?arguments[1]:e.activatorProps;d&&St(d,W(r.value,m))}function a(){let d=arguments.length>0&&arguments[0]!==void 0?arguments[0]:s(),m=arguments.length>1&&arguments[1]!==void 0?arguments[1]:e.activatorProps;d&&xt(d,W(r.value,m))}function s(){let d=arguments.length>0&&arguments[0]!==void 0?arguments[0]:e.activator;const m=Ne(d,t);return o.value=m?.nodeType===Node.ELEMENT_NODE?m:void 0,o.value}}function Ne(e,t){if(!e)return;let n;if(e==="parent"){let o=t?.proxy?.$el?.parentNode;for(;o?.hasAttribute("data-no-activator");)o=o.parentNode;n=o}else typeof e=="string"?n=document.querySelector(e):"$el"in e?n=e.$el:n=e;return n}function Gt(){if(!j)return Y(!1);const{ssr:e}=We();if(e){const t=Y(!1);return je(()=>{t.value=!0}),t}else return Y(!0)}const xe=Symbol.for("vuetify:stack"),$=Ae([]);function Ut(e,t,n){const o=Ce("useStack"),r=!n,l=pe(xe,void 0),a=Ae({activeChildren:new Set});qe(xe,a);const s=Y(+t.value);se(e,()=>{const y=$.at(-1)?.[1];s.value=y?y+10:+t.value,r&&$.push([o.uid,s.value]),l?.activeChildren.add(o.uid),_(()=>{if(r){const C=$e($).findIndex(k=>k[0]===o.uid);$.splice(C,1)}l?.activeChildren.delete(o.uid)})});const d=Y(!0);r&&ue(()=>{const y=$.at(-1)?.[0]===o.uid;setTimeout(()=>d.value=y)});const m=P(()=>!a.activeChildren.size);return{globalTop:ze(d),localTop:m,stackStyles:P(()=>({zIndex:s.value}))}}function Xt(e){return{teleportTarget:P(()=>{const n=e();if(n===!0||!j)return;const o=n===!1?document.body:typeof n=="string"?document.querySelector(n):n;if(o==null)return;let r=o.querySelector(":scope > .v-overlay-container");return r||(r=document.createElement("div"),r.className="v-overlay-container",o.appendChild(r)),r})}}function Zt(e){const{modelValue:t,color:n,...o}=e;return D(ut,{name:"fade-transition",appear:!0},{default:()=>[e.modelValue&&D("div",W({class:["v-overlay__scrim",e.color.backgroundColorClasses.value],style:e.color.backgroundColorStyles.value},o),null)]})}const Kt=G({absolute:Boolean,attach:[Boolean,String,Object],closeOnBack:{type:Boolean,default:!0},contained:Boolean,contentClass:null,contentProps:null,disabled:Boolean,opacity:[Number,String],noClickAnimation:Boolean,modelValue:Boolean,persistent:Boolean,scrim:{type:[Boolean,String],default:!0},zIndex:{type:[Number,String],default:2e3},...zt(),...Ye(),...Ge(),...mt(),...Lt(),..._t(),...Ue(),...wt()},"VOverlay"),tn=Xe()({name:"VOverlay",directives:{ClickOutside:At},inheritAttrs:!1,props:{_disableGlobalStack:Boolean,...Kt()},emits:{"click:outside":e=>!0,"update:modelValue":e=>!0,afterEnter:()=>!0,afterLeave:()=>!0},setup(e,t){let{slots:n,attrs:o,emit:r}=t;const l=Ze(e,"modelValue"),a=P({get:()=>l.value,set:b=>{b&&e.disabled||(l.value=b)}}),{themeClasses:s}=Ke(e),{rtlClasses:d,isRtl:m}=Qe(),{hasContent:y,onAfterLeave:C}=yt(e,a),k=Je(P(()=>typeof e.scrim=="string"?e.scrim:null)),{globalTop:S,localTop:u,stackStyles:c}=Ut(a,et(e,"zIndex"),e._disableGlobalStack),{activatorEl:x,activatorRef:A,target:h,targetEl:w,targetRef:H,activatorEvents:B,contentEvents:p,scrimEvents:i}=$t(e,{isActive:a,isTop:u}),{teleportTarget:N}=Xt(()=>{const b=e.attach||e.contained;if(b)return b;const q=x?.value?.getRootNode();return q instanceof ShadowRoot?q:!1}),{dimensionStyles:J}=tt(e),ee=Gt(),{scopeId:E}=gt();L(()=>e.disabled,b=>{b&&(a.value=!1)});const g=V(),f=V(),v=V(),{contentStyles:M,updateLocation:T}=Bt(e,{isRtl:m,contentEl:v,target:h,isActive:a});Ht(e,{root:g,contentEl:v,targetEl:w,isActive:a,updateLocation:T});function z(b){r("click:outside",b),e.persistent?X():a.value=!1}function O(b){return a.value&&S.value&&(!e.scrim||b.target===f.value)}j&&L(a,b=>{b?window.addEventListener("keydown",R):window.removeEventListener("keydown",R)},{immediate:!0}),nt(()=>{j&&window.removeEventListener("keydown",R)});function R(b){b.key==="Escape"&&S.value&&(e.persistent?X():(a.value=!1,v.value?.contains(document.activeElement)&&x.value?.focus()))}const U=ot();se(()=>e.closeOnBack,()=>{ft(U,b=>{S.value&&a.value?(b(!1),e.persistent?X():a.value=!1):b()})});const I=V();L(()=>a.value&&(e.absolute||e.contained)&&N.value==null,b=>{if(b){const q=kt(g.value);q&&q!==document.scrollingElement&&(I.value=q.scrollTop)}});function X(){e.noClickAnimation||v.value&&ht(v.value,[{transformOrigin:"center"},{transform:"scale(1.03)"},{transformOrigin:"center"}],{duration:150,easing:bt})}function _e(){r("afterEnter")}function He(){C(),r("afterLeave")}return at(()=>D(ct,null,[n.activator?.({isActive:a.value,targetRef:H,props:W({ref:A},B.value,e.activatorProps)}),ee.value&&y.value&&D(rt,{disabled:!N.value,to:N.value},{default:()=>[D("div",W({class:["v-overlay",{"v-overlay--absolute":e.absolute||e.contained,"v-overlay--active":a.value,"v-overlay--contained":e.contained},s.value,d.value,e.class],style:[c.value,{"--v-overlay-opacity":e.opacity,top:F(I.value)},e.style],ref:g},E,o),[D(Zt,W({color:k,modelValue:a.value&&!!e.scrim,ref:f},i.value),null),D(Et,{appear:!0,persisted:!0,transition:e.transition,target:h.value,onAfterEnter:_e,onAfterLeave:He},{default:()=>[it(D("div",W({ref:v,class:["v-overlay__content",e.contentClass],style:[J.value,M.value]},p.value,e.contentProps),[n.default?.({isActive:a})]),[[lt,a.value],[st("click-outside"),{handler:z,closeConditional:O,include:()=>[x.value]}]])]})])]})])),{activatorEl:x,scrimEl:f,target:h,animateClick:X,contentEl:v,globalTop:S,localTop:u,updateLocation:T}}});export{tn as V,Kt as m}; +import{bn as Oe,bo as ke,p as G,r as V,L as q,ao as se,w as L,bp as _,bq as De,br as ve,bs as te,bt as ne,bu as de,c as P,D as ce,bv as me,C as F,al as ye,ap as ue,bw as Pe,bx as Ve,bi as Ce,x as pe,by as ge,d as W,bz as Ie,s as Y,H as We,Z as qe,aM as Ae,q as je,ar as ze,bA as $e,e as Ye,ac as Ge,h as Ue,g as Xe,y as Ze,i as Ke,j as Qe,Q as Je,R as et,ad as tt,am as nt,bB as ot,a as at,b as D,bC as rt,t as it,B as lt,v as st,F as ct,ab as ut,bD as ft}from"./index-Dvu417lt.js";import{g as vt,B as oe,e as he,n as dt,m as mt,u as yt,b as gt,a as ht,s as bt}from"./forwardRefs-DzUtZcD3.js";import{m as wt,M as Et}from"./transition-BKtsYhmO.js";const Z=new WeakMap;function St(e,t){Object.keys(t).forEach(n=>{if(Oe(n)){const o=ke(n),r=Z.get(e);if(t[n]==null)r?.forEach(l=>{const[a,s]=l;a===o&&(e.removeEventListener(o,s),r.delete(l))});else if(!r||![...r].some(l=>l[0]===o&&l[1]===t[n])){e.addEventListener(o,t[n]);const l=r||new Set;l.add([o,t[n]]),Z.has(e)||Z.set(e,l)}}else t[n]==null?e.removeAttribute(n):e.setAttribute(n,t[n])})}function xt(e,t){Object.keys(t).forEach(n=>{if(Oe(n)){const o=ke(n),r=Z.get(e);r?.forEach(l=>{const[a,s]=l;a===o&&(e.removeEventListener(o,s),r.delete(l))})}else e.removeAttribute(n)})}function Te(e){if(typeof e.getRootNode!="function"){for(;e.parentNode;)e=e.parentNode;return e!==document?null:document}const t=e.getRootNode();return t!==document&&t.getRootNode({composed:!0})!==document?null:t}function Ot(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1;for(;e;){if(t?kt(e):fe(e))return e;e=e.parentElement}return document.scrollingElement}function K(e,t){const n=[];if(t&&e&&!t.contains(e))return n;for(;e&&(fe(e)&&n.push(e),e!==t);)e=e.parentElement;return n}function fe(e){if(!e||e.nodeType!==Node.ELEMENT_NODE)return!1;const t=window.getComputedStyle(e);return t.overflowY==="scroll"||t.overflowY==="auto"&&e.scrollHeight>e.clientHeight}function kt(e){if(!e||e.nodeType!==Node.ELEMENT_NODE)return!1;const t=window.getComputedStyle(e);return["scroll","auto"].includes(t.overflowY)}function Pt(e){for(;e;){if(window.getComputedStyle(e).position==="fixed")return!0;e=e.offsetParent}return!1}function Ct(){return!0}function Le(e,t,n){if(!e||Be(e,n)===!1)return!1;const o=Te(t);if(typeof ShadowRoot<"u"&&o instanceof ShadowRoot&&o.host===e.target)return!1;const r=(typeof n.value=="object"&&n.value.include||(()=>[]))();return r.push(t),!r.some(l=>l?.contains(e.target))}function Be(e,t){return(typeof t.value=="object"&&t.value.closeConditional||Ct)(e)}function pt(e,t,n){const o=typeof n.value=="function"?n.value:n.value.handler;t._clickOutside.lastMousedownWasOutside&&Le(e,t,n)&&setTimeout(()=>{Be(e,n)&&o&&o(e)},0)}function be(e,t){const n=Te(e);t(document),typeof ShadowRoot<"u"&&n instanceof ShadowRoot&&t(n)}const At={mounted(e,t){const n=r=>pt(r,e,t),o=r=>{e._clickOutside.lastMousedownWasOutside=Le(r,e,t)};be(e,r=>{r.addEventListener("click",n,!0),r.addEventListener("mousedown",o,!0)}),e._clickOutside||(e._clickOutside={lastMousedownWasOutside:!1}),e._clickOutside[t.instance.$.uid]={onClick:n,onMousedown:o}},unmounted(e,t){e._clickOutside&&(be(e,n=>{if(!n||!e._clickOutside?.[t.instance.$.uid])return;const{onClick:o,onMousedown:r}=e._clickOutside[t.instance.$.uid];n.removeEventListener("click",o,!0),n.removeEventListener("mousedown",r,!0)}),delete e._clickOutside[t.instance.$.uid])}};function ae(e,t){return{x:e.x+t.x,y:e.y+t.y}}function Tt(e,t){return{x:e.x-t.x,y:e.y-t.y}}function we(e,t){if(e.side==="top"||e.side==="bottom"){const{side:n,align:o}=e,r=o==="left"?0:o==="center"?t.width/2:o==="right"?t.width:o,l=n==="top"?0:n==="bottom"?t.height:n;return ae({x:r,y:l},t)}else if(e.side==="left"||e.side==="right"){const{side:n,align:o}=e,r=n==="left"?0:n==="right"?t.width:n,l=o==="top"?0:o==="center"?t.height/2:o==="bottom"?t.height:o;return ae({x:r,y:l},t)}return ae({x:t.width/2,y:t.height/2},t)}const Me={static:Mt,connected:Ft},Lt=G({locationStrategy:{type:[String,Function],default:"static",validator:e=>typeof e=="function"||e in Me},location:{type:String,default:"bottom"},origin:{type:String,default:"auto"},offset:[Number,String,Array]},"VOverlay-location-strategies");function Bt(e,t){const n=V({}),o=V();q&&se(()=>!!(t.isActive.value&&e.locationStrategy),l=>{L(()=>e.locationStrategy,l),_(()=>{window.removeEventListener("resize",r),o.value=void 0}),window.addEventListener("resize",r,{passive:!0}),typeof e.locationStrategy=="function"?o.value=e.locationStrategy(t,e,n)?.updateLocation:o.value=Me[e.locationStrategy](t,e,n)?.updateLocation});function r(l){o.value?.(l)}return{contentStyles:n,updateLocation:o}}function Mt(){}function Rt(e,t){t?e.style.removeProperty("left"):e.style.removeProperty("right");const n=dt(e);return t?n.x+=parseFloat(e.style.right||0):n.x-=parseFloat(e.style.left||0),n.y-=parseFloat(e.style.top||0),n}function Ft(e,t,n){(Array.isArray(e.target.value)||Pt(e.target.value))&&Object.assign(n.value,{position:"fixed",top:0,[e.isRtl.value?"right":"left"]:0});const{preferredAnchor:r,preferredOrigin:l}=De(()=>{const u=ve(t.location,e.isRtl.value),c=t.origin==="overlap"?u:t.origin==="auto"?te(u):ve(t.origin,e.isRtl.value);return u.side===c.side&&u.align===ne(c).align?{preferredAnchor:de(u),preferredOrigin:de(c)}:{preferredAnchor:u,preferredOrigin:c}}),[a,s,d,m]=["minWidth","minHeight","maxWidth","maxHeight"].map(u=>P(()=>{const c=parseFloat(t[u]);return isNaN(c)?1/0:c})),y=P(()=>{if(Array.isArray(t.offset))return t.offset;if(typeof t.offset=="string"){const u=t.offset.split(" ").map(parseFloat);return u.length<2&&u.push(0),u}return typeof t.offset=="number"?[t.offset,0]:[0,0]});let C=!1;const O=new ResizeObserver(()=>{C&&S()});L([e.target,e.contentEl],(u,c)=>{let[x,A]=u,[h,w]=c;h&&!Array.isArray(h)&&O.unobserve(h),x&&!Array.isArray(x)&&O.observe(x),w&&O.unobserve(w),A&&O.observe(A)},{immediate:!0}),_(()=>{O.disconnect()});function S(){if(C=!1,requestAnimationFrame(()=>C=!0),!e.target.value||!e.contentEl.value)return;const u=vt(e.target.value),c=Rt(e.contentEl.value,e.isRtl.value),x=K(e.contentEl.value),A=12;x.length||(x.push(document.documentElement),e.contentEl.value.style.top&&e.contentEl.value.style.left||(c.x-=parseFloat(document.documentElement.style.getPropertyValue("--v-body-scroll-x")||0),c.y-=parseFloat(document.documentElement.style.getPropertyValue("--v-body-scroll-y")||0)));const h=x.reduce((E,g)=>{const f=g.getBoundingClientRect(),v=new oe({x:g===document.documentElement?0:f.x,y:g===document.documentElement?0:f.y,width:g.clientWidth,height:g.clientHeight});return E?new oe({x:Math.max(E.left,v.left),y:Math.max(E.top,v.top),width:Math.min(E.right,v.right)-Math.max(E.left,v.left),height:Math.min(E.bottom,v.bottom)-Math.max(E.top,v.top)}):v},void 0);h.x+=A,h.y+=A,h.width-=A*2,h.height-=A*2;let w={anchor:r.value,origin:l.value};function H(E){const g=new oe(c),f=we(E.anchor,u),v=we(E.origin,g);let{x:M,y:T}=Tt(f,v);switch(E.anchor.side){case"top":T-=y.value[0];break;case"bottom":T+=y.value[0];break;case"left":M-=y.value[0];break;case"right":M+=y.value[0];break}switch(E.anchor.align){case"top":T-=y.value[1];break;case"bottom":T+=y.value[1];break;case"left":M-=y.value[1];break;case"right":M+=y.value[1];break}return g.x+=M,g.y+=T,g.width=Math.min(g.width,d.value),g.height=Math.min(g.height,m.value),{overflows:he(g,h),x:M,y:T}}let B=0,p=0;const i={x:0,y:0},N={x:!1,y:!1};let J=-1;for(;!(J++>10);){const{x:E,y:g,overflows:f}=H(w);B+=E,p+=g,c.x+=E,c.y+=g;{const v=me(w.anchor),M=f.x.before||f.x.after,T=f.y.before||f.y.after;let z=!1;if(["x","y"].forEach(k=>{if(k==="x"&&M&&!N.x||k==="y"&&T&&!N.y){const R={anchor:{...w.anchor},origin:{...w.origin}},U=k==="x"?v==="y"?ne:te:v==="y"?te:ne;R.anchor=U(R.anchor),R.origin=U(R.origin);const{overflows:I}=H(R);(I[k].before<=f[k].before&&I[k].after<=f[k].after||I[k].before+I[k].after<(f[k].before+f[k].after)/2)&&(w=R,z=N[k]=!0)}}),z)continue}f.x.before&&(B+=f.x.before,c.x+=f.x.before),f.x.after&&(B-=f.x.after,c.x-=f.x.after),f.y.before&&(p+=f.y.before,c.y+=f.y.before),f.y.after&&(p-=f.y.after,c.y-=f.y.after);{const v=he(c,h);i.x=h.width-v.x.before-v.x.after,i.y=h.height-v.y.before-v.y.after,B+=v.x.before,c.x+=v.x.before,p+=v.y.before,c.y+=v.y.before}break}const ee=me(w.anchor);return Object.assign(n.value,{"--v-overlay-anchor-origin":`${w.anchor.side} ${w.anchor.align}`,transformOrigin:`${w.origin.side} ${w.origin.align}`,top:F(re(p)),left:e.isRtl.value?void 0:F(re(B)),right:e.isRtl.value?F(re(-B)):void 0,minWidth:F(ee==="y"?Math.min(a.value,u.width):a.value),maxWidth:F(Ee(ye(i.x,a.value===1/0?0:a.value,d.value))),maxHeight:F(Ee(ye(i.y,s.value===1/0?0:s.value,m.value)))}),{available:i,contentBox:c}}return L(()=>[r.value,l.value,t.offset,t.minWidth,t.minHeight,t.maxWidth,t.maxHeight],()=>S()),ce(()=>{const u=S();if(!u)return;const{available:c,contentBox:x}=u;x.height>c.y&&requestAnimationFrame(()=>{S(),requestAnimationFrame(()=>{S()})})}),{updateLocation:S}}function re(e){return Math.round(e*devicePixelRatio)/devicePixelRatio}function Ee(e){return Math.ceil(e*devicePixelRatio)/devicePixelRatio}let ie=!0;const Q=[];function Nt(e){!ie||Q.length?(Q.push(e),le()):(ie=!1,e(),le())}let Se=-1;function le(){cancelAnimationFrame(Se),Se=requestAnimationFrame(()=>{const e=Q.shift();e&&e(),Q.length?le():ie=!0})}const Re={none:null,close:Dt,block:Vt,reposition:It},_t=G({scrollStrategy:{type:[String,Function],default:"block",validator:e=>typeof e=="function"||e in Re}},"VOverlay-scroll-strategies");function Ht(e,t){if(!q)return;let n;ue(async()=>{n?.stop(),t.isActive.value&&e.scrollStrategy&&(n=Pe(),await new Promise(o=>setTimeout(o)),n.active&&n.run(()=>{typeof e.scrollStrategy=="function"?e.scrollStrategy(t,e,n):Re[e.scrollStrategy]?.(t,e,n)}))}),_(()=>{n?.stop()})}function Dt(e){function t(n){e.isActive.value=!1}Fe(e.targetEl.value??e.contentEl.value,t)}function Vt(e,t){const n=e.root.value?.offsetParent,o=[...new Set([...K(e.targetEl.value,t.contained?n:void 0),...K(e.contentEl.value,t.contained?n:void 0)])].filter(a=>!a.classList.contains("v-overlay-scroll-blocked")),r=window.innerWidth-document.documentElement.offsetWidth,l=(a=>fe(a)&&a)(n||document.documentElement);l&&e.root.value.classList.add("v-overlay--scroll-blocked"),o.forEach((a,s)=>{a.style.setProperty("--v-body-scroll-x",F(-a.scrollLeft)),a.style.setProperty("--v-body-scroll-y",F(-a.scrollTop)),a!==document.documentElement&&a.style.setProperty("--v-scrollbar-offset",F(r)),a.classList.add("v-overlay-scroll-blocked")}),_(()=>{o.forEach((a,s)=>{const d=parseFloat(a.style.getPropertyValue("--v-body-scroll-x")),m=parseFloat(a.style.getPropertyValue("--v-body-scroll-y")),y=a.style.scrollBehavior;a.style.scrollBehavior="auto",a.style.removeProperty("--v-body-scroll-x"),a.style.removeProperty("--v-body-scroll-y"),a.style.removeProperty("--v-scrollbar-offset"),a.classList.remove("v-overlay-scroll-blocked"),a.scrollLeft=-d,a.scrollTop=-m,a.style.scrollBehavior=y}),l&&e.root.value.classList.remove("v-overlay--scroll-blocked")})}function It(e,t,n){let o=!1,r=-1,l=-1;function a(s){Nt(()=>{const d=performance.now();e.updateLocation.value?.(s),o=(performance.now()-d)/(1e3/60)>2})}l=(typeof requestIdleCallback>"u"?s=>s():requestIdleCallback)(()=>{n.run(()=>{Fe(e.targetEl.value??e.contentEl.value,s=>{o?(cancelAnimationFrame(r),r=requestAnimationFrame(()=>{r=requestAnimationFrame(()=>{a(s)})})):a(s)})})}),_(()=>{typeof cancelIdleCallback<"u"&&cancelIdleCallback(l),cancelAnimationFrame(r)})}function Fe(e,t){const n=[document,...K(e)];n.forEach(o=>{o.addEventListener("scroll",t,{passive:!0})}),_(()=>{n.forEach(o=>{o.removeEventListener("scroll",t)})})}const Wt=Symbol.for("vuetify:v-menu"),qt=G({closeDelay:[Number,String],openDelay:[Number,String]},"delay");function jt(e,t){let n=()=>{};function o(a){n?.();const s=Number(a?e.openDelay:e.closeDelay);return new Promise(d=>{n=Ve(s,()=>{t?.(a),d(a)})})}function r(){return o(!0)}function l(){return o(!1)}return{clearDelay:n,runOpenDelay:r,runCloseDelay:l}}const zt=G({target:[String,Object],activator:[String,Object],activatorProps:{type:Object,default:()=>({})},openOnClick:{type:Boolean,default:void 0},openOnHover:Boolean,openOnFocus:{type:Boolean,default:void 0},closeOnContentClick:Boolean,...qt()},"VOverlay-activator");function $t(e,t){let{isActive:n,isTop:o}=t;const r=Ce("useActivator"),l=V();let a=!1,s=!1,d=!0;const m=P(()=>e.openOnFocus||e.openOnFocus==null&&e.openOnHover),y=P(()=>e.openOnClick||e.openOnClick==null&&!e.openOnHover&&!m.value),{runOpenDelay:C,runCloseDelay:O}=jt(e,i=>{i===(e.openOnHover&&a||m.value&&s)&&!(e.openOnHover&&n.value&&!o.value)&&(n.value!==i&&(d=!0),n.value=i)}),S=V(),u={onClick:i=>{i.stopPropagation(),l.value=i.currentTarget||i.target,n.value||(S.value=[i.clientX,i.clientY]),n.value=!n.value},onMouseenter:i=>{i.sourceCapabilities?.firesTouchEvents||(a=!0,l.value=i.currentTarget||i.target,C())},onMouseleave:i=>{a=!1,O()},onFocus:i=>{Ie(i.target,":focus-visible")!==!1&&(s=!0,i.stopPropagation(),l.value=i.currentTarget||i.target,C())},onBlur:i=>{s=!1,i.stopPropagation(),O()}},c=P(()=>{const i={};return y.value&&(i.onClick=u.onClick),e.openOnHover&&(i.onMouseenter=u.onMouseenter,i.onMouseleave=u.onMouseleave),m.value&&(i.onFocus=u.onFocus,i.onBlur=u.onBlur),i}),x=P(()=>{const i={};if(e.openOnHover&&(i.onMouseenter=()=>{a=!0,C()},i.onMouseleave=()=>{a=!1,O()}),m.value&&(i.onFocusin=()=>{s=!0,C()},i.onFocusout=()=>{s=!1,O()}),e.closeOnContentClick){const N=pe(Wt,null);i.onClick=()=>{n.value=!1,N?.closeParents()}}return i}),A=P(()=>{const i={};return e.openOnHover&&(i.onMouseenter=()=>{d&&(a=!0,d=!1,C())},i.onMouseleave=()=>{a=!1,O()}),i});L(o,i=>{i&&(e.openOnHover&&!a&&(!m.value||!s)||m.value&&!s&&(!e.openOnHover||!a))&&(n.value=!1)}),L(n,i=>{i||setTimeout(()=>{S.value=void 0})},{flush:"post"});const h=ge();ue(()=>{h.value&&ce(()=>{l.value=h.el})});const w=ge(),H=P(()=>e.target==="cursor"&&S.value?S.value:w.value?w.el:Ne(e.target,r)||l.value),B=P(()=>Array.isArray(H.value)?void 0:H.value);let p;return L(()=>!!e.activator,i=>{i&&q?(p=Pe(),p.run(()=>{Yt(e,r,{activatorEl:l,activatorEvents:c})})):p&&p.stop()},{flush:"post",immediate:!0}),_(()=>{p?.stop()}),{activatorEl:l,activatorRef:h,target:H,targetEl:B,targetRef:w,activatorEvents:c,contentEvents:x,scrimEvents:A}}function Yt(e,t,n){let{activatorEl:o,activatorEvents:r}=n;L(()=>e.activator,(d,m)=>{if(m&&d!==m){const y=s(m);y&&a(y)}d&&ce(()=>l())},{immediate:!0}),L(()=>e.activatorProps,()=>{l()}),_(()=>{a()});function l(){let d=arguments.length>0&&arguments[0]!==void 0?arguments[0]:s(),m=arguments.length>1&&arguments[1]!==void 0?arguments[1]:e.activatorProps;d&&St(d,W(r.value,m))}function a(){let d=arguments.length>0&&arguments[0]!==void 0?arguments[0]:s(),m=arguments.length>1&&arguments[1]!==void 0?arguments[1]:e.activatorProps;d&&xt(d,W(r.value,m))}function s(){let d=arguments.length>0&&arguments[0]!==void 0?arguments[0]:e.activator;const m=Ne(d,t);return o.value=m?.nodeType===Node.ELEMENT_NODE?m:void 0,o.value}}function Ne(e,t){if(!e)return;let n;if(e==="parent"){let o=t?.proxy?.$el?.parentNode;for(;o?.hasAttribute("data-no-activator");)o=o.parentNode;n=o}else typeof e=="string"?n=document.querySelector(e):"$el"in e?n=e.$el:n=e;return n}function Gt(){if(!q)return Y(!1);const{ssr:e}=We();if(e){const t=Y(!1);return qe(()=>{t.value=!0}),t}else return Y(!0)}const xe=Symbol.for("vuetify:stack"),$=Ae([]);function Ut(e,t,n){const o=Ce("useStack"),r=!n,l=pe(xe,void 0),a=Ae({activeChildren:new Set});je(xe,a);const s=Y(+t.value);se(e,()=>{const y=$.at(-1)?.[1];s.value=y?y+10:+t.value,r&&$.push([o.uid,s.value]),l?.activeChildren.add(o.uid),_(()=>{if(r){const C=$e($).findIndex(O=>O[0]===o.uid);$.splice(C,1)}l?.activeChildren.delete(o.uid)})});const d=Y(!0);r&&ue(()=>{const y=$.at(-1)?.[0]===o.uid;setTimeout(()=>d.value=y)});const m=P(()=>!a.activeChildren.size);return{globalTop:ze(d),localTop:m,stackStyles:P(()=>({zIndex:s.value}))}}function Xt(e){return{teleportTarget:P(()=>{const n=e();if(n===!0||!q)return;const o=n===!1?document.body:typeof n=="string"?document.querySelector(n):n;if(o==null)return;let r=o.querySelector(":scope > .v-overlay-container");return r||(r=document.createElement("div"),r.className="v-overlay-container",o.appendChild(r)),r})}}function Zt(e){const{modelValue:t,color:n,...o}=e;return D(ut,{name:"fade-transition",appear:!0},{default:()=>[e.modelValue&&D("div",W({class:["v-overlay__scrim",e.color.backgroundColorClasses.value],style:e.color.backgroundColorStyles.value},o),null)]})}const Kt=G({absolute:Boolean,attach:[Boolean,String,Object],closeOnBack:{type:Boolean,default:!0},contained:Boolean,contentClass:null,contentProps:null,disabled:Boolean,opacity:[Number,String],noClickAnimation:Boolean,modelValue:Boolean,persistent:Boolean,scrim:{type:[Boolean,String],default:!0},zIndex:{type:[Number,String],default:2e3},...zt(),...Ye(),...Ge(),...mt(),...Lt(),..._t(),...Ue(),...wt()},"VOverlay"),tn=Xe()({name:"VOverlay",directives:{ClickOutside:At},inheritAttrs:!1,props:{_disableGlobalStack:Boolean,...Kt()},emits:{"click:outside":e=>!0,"update:modelValue":e=>!0,afterEnter:()=>!0,afterLeave:()=>!0},setup(e,t){let{slots:n,attrs:o,emit:r}=t;const l=Ze(e,"modelValue"),a=P({get:()=>l.value,set:b=>{b&&e.disabled||(l.value=b)}}),{themeClasses:s}=Ke(e),{rtlClasses:d,isRtl:m}=Qe(),{hasContent:y,onAfterLeave:C}=yt(e,a),O=Je(P(()=>typeof e.scrim=="string"?e.scrim:null)),{globalTop:S,localTop:u,stackStyles:c}=Ut(a,et(e,"zIndex"),e._disableGlobalStack),{activatorEl:x,activatorRef:A,target:h,targetEl:w,targetRef:H,activatorEvents:B,contentEvents:p,scrimEvents:i}=$t(e,{isActive:a,isTop:u}),{teleportTarget:N}=Xt(()=>{const b=e.attach||e.contained;if(b)return b;const j=x?.value?.getRootNode();return j instanceof ShadowRoot?j:!1}),{dimensionStyles:J}=tt(e),ee=Gt(),{scopeId:E}=gt();L(()=>e.disabled,b=>{b&&(a.value=!1)});const g=V(),f=V(),v=V(),{contentStyles:M,updateLocation:T}=Bt(e,{isRtl:m,contentEl:v,target:h,isActive:a});Ht(e,{root:g,contentEl:v,targetEl:w,isActive:a,updateLocation:T});function z(b){r("click:outside",b),e.persistent?X():a.value=!1}function k(b){return a.value&&S.value&&(!e.scrim||b.target===f.value)}q&&L(a,b=>{b?window.addEventListener("keydown",R):window.removeEventListener("keydown",R)},{immediate:!0}),nt(()=>{q&&window.removeEventListener("keydown",R)});function R(b){b.key==="Escape"&&S.value&&(e.persistent?X():(a.value=!1,v.value?.contains(document.activeElement)&&x.value?.focus()))}const U=ot();se(()=>e.closeOnBack,()=>{ft(U,b=>{S.value&&a.value?(b(!1),e.persistent?X():a.value=!1):b()})});const I=V();L(()=>a.value&&(e.absolute||e.contained)&&N.value==null,b=>{if(b){const j=Ot(g.value);j&&j!==document.scrollingElement&&(I.value=j.scrollTop)}});function X(){e.noClickAnimation||v.value&&ht(v.value,[{transformOrigin:"center"},{transform:"scale(1.03)"},{transformOrigin:"center"}],{duration:150,easing:bt})}function _e(){r("afterEnter")}function He(){C(),r("afterLeave")}return at(()=>D(ct,null,[n.activator?.({isActive:a.value,targetRef:H,props:W({ref:A},B.value,e.activatorProps)}),ee.value&&y.value&&D(rt,{disabled:!N.value,to:N.value},{default:()=>[D("div",W({class:["v-overlay",{"v-overlay--absolute":e.absolute||e.contained,"v-overlay--active":a.value,"v-overlay--contained":e.contained},s.value,d.value,e.class],style:[c.value,{"--v-overlay-opacity":e.opacity,top:F(I.value)},e.style],ref:g},E,o),[D(Zt,W({color:O,modelValue:a.value&&!!e.scrim,ref:f},i.value),null),D(Et,{appear:!0,persisted:!0,transition:e.transition,target:h.value,onAfterEnter:_e,onAfterLeave:He},{default:()=>[it(D("div",W({ref:v,class:["v-overlay__content",e.contentClass],style:[J.value,M.value]},p.value,e.contentProps),[n.default?.({isActive:a})]),[[lt,a.value],[st("click-outside"),{handler:z,closeConditional:k,include:()=>[x.value]}]])]})])]})])),{activatorEl:x,scrimEl:f,target:h,animateClick:X,contentEl:v,globalTop:S,localTop:u,updateLocation:T}}});export{tn as V,Kt as m}; diff --git a/pr-preview/pr-17/assets/WidgetsContainer-nwexi3P3.js b/pr-preview/pr-17/assets/WidgetsContainer-CFwZEFgj.js similarity index 94% rename from pr-preview/pr-17/assets/WidgetsContainer-nwexi3P3.js rename to pr-preview/pr-17/assets/WidgetsContainer-CFwZEFgj.js index 86ff01c..ad76ace 100644 --- a/pr-preview/pr-17/assets/WidgetsContainer-nwexi3P3.js +++ b/pr-preview/pr-17/assets/WidgetsContainer-CFwZEFgj.js @@ -1 +1 @@ -import{X as g,r as i,Y as y,Z as x,D as v,$ as n,a6 as m,a7 as E,a3 as H,F as k,a9 as f,aa as C,a0 as _,d as w,a4 as A,bp as D}from"./index-BHzPgH2J.js";class F extends HTMLDetailsElement{constructor(){super()}connectedCallback(){this.el=this,this.summary=this.querySelector("summary"),this.content=this.lastElementChild,this.animation=null,this.isClosing=!1,this.isExpanding=!1,this.summary.addEventListener("click",e=>this.onClick(e))}onClick(e){e?.preventDefault(),this.el.style.overflow="hidden",this.isClosing||!this.el.open?this.doOpen():(this.isExpanding||this.el.open)&&this.shrink()}shrink(){this.isClosing=!0;const e=`${this.el.offsetHeight}px`,t=`${this.summary.offsetHeight}px`;this.animation&&this.animation.cancel(),this.animation=this.el.animate({height:[e,t]},{duration:300,easing:"ease-out"}),this.animation.onfinish=()=>this.onAnimationFinish(!1),this.animation.oncancel=()=>this.isClosing=!1}doOpen(){this.el.style.height=`${this.el.offsetHeight}px`,this.el.open=!0,window.requestAnimationFrame(()=>this.expand()),this.parentElement.querySelectorAll("details[open][exclusive]").forEach(t=>{t!==this&&t.onClick()})}expand(){this.isExpanding=!0;const e=`${this.el.offsetHeight}px`,t=`${this.summary.offsetHeight+this.content.offsetHeight}px`;this.animation&&this.animation.cancel(),this.animation=this.el.animate({height:[e,t]},{duration:300,easing:"ease-out"}),this.animation.onfinish=()=>this.onAnimationFinish(!0),this.animation.oncancel=()=>this.isExpanding=!1}onAnimationFinish(e){this.el.open=e,this.animation=null,this.isClosing=!1,this.isExpanding=!1,this.el.style.height=this.el.style.overflow=""}}customElements.define("animated-details",F,{extends:"details"});const b={__name:"WidgetsContainer",props:{widgets:{type:Array,required:!0}},setup(a){const t=g(a.widgets),l=i([]),o=i([]),h=i(""),r=i(0),{mainRect:d}=y();return x(async()=>{await v(()=>{r.value=o.value.reduce((c,u)=>c+=u.clientHeight,0),h.value=(l.value[0].parentElement?.scrollHeight??0)-r.value-d.value.top+"px"})}),(c,u)=>(n(!0),m(k,null,E(H(t),(s,p)=>(n(),m("details",{is:"animated-details",ref_for:!0,ref_key:"detailsEls",ref:l,key:p,class:"overflow-auto",exclusive:""},[f("summary",{ref_for:!0,ref_key:"summaryEls",ref:o},C(s.value.title),513),f("span",{style:D({height:h.value}),class:"d-flex flex-column"},[(n(),_(A(s.value.component),w({ref_for:!0},s.value.props),null,16))],4)]))),128))}};export{b as default}; +import{X as g,r as i,Y as y,Z as x,D as v,$ as n,a6 as m,a7 as E,a3 as H,F as k,a9 as f,aa as C,a0 as _,d as w,a4 as A,bE as D}from"./index-Dvu417lt.js";class F extends HTMLDetailsElement{constructor(){super()}connectedCallback(){this.el=this,this.summary=this.querySelector("summary"),this.content=this.lastElementChild,this.animation=null,this.isClosing=!1,this.isExpanding=!1,this.summary.addEventListener("click",e=>this.onClick(e))}onClick(e){e?.preventDefault(),this.el.style.overflow="hidden",this.isClosing||!this.el.open?this.doOpen():(this.isExpanding||this.el.open)&&this.shrink()}shrink(){this.isClosing=!0;const e=`${this.el.offsetHeight}px`,t=`${this.summary.offsetHeight}px`;this.animation&&this.animation.cancel(),this.animation=this.el.animate({height:[e,t]},{duration:300,easing:"ease-out"}),this.animation.onfinish=()=>this.onAnimationFinish(!1),this.animation.oncancel=()=>this.isClosing=!1}doOpen(){this.el.style.height=`${this.el.offsetHeight}px`,this.el.open=!0,window.requestAnimationFrame(()=>this.expand()),this.parentElement.querySelectorAll("details[open][exclusive]").forEach(t=>{t!==this&&t.onClick()})}expand(){this.isExpanding=!0;const e=`${this.el.offsetHeight}px`,t=`${this.summary.offsetHeight+this.content.offsetHeight}px`;this.animation&&this.animation.cancel(),this.animation=this.el.animate({height:[e,t]},{duration:300,easing:"ease-out"}),this.animation.onfinish=()=>this.onAnimationFinish(!0),this.animation.oncancel=()=>this.isExpanding=!1}onAnimationFinish(e){this.el.open=e,this.animation=null,this.isClosing=!1,this.isExpanding=!1,this.el.style.height=this.el.style.overflow=""}}customElements.define("animated-details",F,{extends:"details"});const b={__name:"WidgetsContainer",props:{widgets:{type:Array,required:!0}},setup(a){const t=g(a.widgets),l=i([]),o=i([]),h=i(""),r=i(0),{mainRect:d}=y();return x(async()=>{await v(()=>{r.value=o.value.reduce((c,u)=>c+=u.clientHeight,0),h.value=(l.value[0].parentElement?.scrollHeight??0)-r.value-d.value.top+"px"})}),(c,u)=>(n(!0),m(k,null,E(H(t),(s,p)=>(n(),m("details",{is:"animated-details",ref_for:!0,ref_key:"detailsEls",ref:l,key:p,class:"overflow-auto",exclusive:""},[f("summary",{ref_for:!0,ref_key:"summaryEls",ref:o},C(s.value.title),513),f("span",{style:D({height:h.value}),class:"d-flex flex-column"},[(n(),_(A(s.value.component),w({ref_for:!0},s.value.props),null,16))],4)]))),128))}};export{b as default}; diff --git a/pr-preview/pr-17/assets/forwardRefs-BoZnhoLd.js b/pr-preview/pr-17/assets/forwardRefs-DzUtZcD3.js similarity index 98% rename from pr-preview/pr-17/assets/forwardRefs-BoZnhoLd.js rename to pr-preview/pr-17/assets/forwardRefs-DzUtZcD3.js index 9c4f788..d7e7145 100644 --- a/pr-preview/pr-17/assets/forwardRefs-BoZnhoLd.js +++ b/pr-preview/pr-17/assets/forwardRefs-DzUtZcD3.js @@ -1 +1 @@ -import{p as v,s as w,c as x,w as R,bh as b}from"./index-BHzPgH2J.js";class d{constructor(r){let{x:n,y:i,width:s,height:t}=r;this.x=n,this.y=i,this.width=s,this.height=t}get top(){return this.y}get bottom(){return this.y+this.height}get left(){return this.x}get right(){return this.x+this.width}}function W(e,r){return{x:{before:Math.max(0,r.left-e.left),after:Math.max(0,e.right-r.right)},y:{before:Math.max(0,r.top-e.top),after:Math.max(0,e.bottom-r.bottom)}}}function O(e){return Array.isArray(e)?new d({x:e[0],y:e[1],width:0,height:0}):e.getBoundingClientRect()}function P(e){const r=e.getBoundingClientRect(),n=getComputedStyle(e),i=n.transform;if(i){let s,t,o,a,f;if(i.startsWith("matrix3d("))s=i.slice(9,-1).split(/, /),t=+s[0],o=+s[5],a=+s[12],f=+s[13];else if(i.startsWith("matrix("))s=i.slice(7,-1).split(/, /),t=+s[0],o=+s[3],a=+s[4],f=+s[5];else return new d(r);const c=n.transformOrigin,u=r.x-a-(1-t)*parseFloat(c),l=r.y-f-(1-o)*parseFloat(c.slice(c.indexOf(" ")+1)),h=t?r.width/t:e.offsetWidth+1,m=o?r.height/o:e.offsetHeight+1;return new d({x:u,y:l,width:h,height:m})}else return new d(r)}function B(e,r,n){if(typeof e.animate>"u")return{finished:Promise.resolve()};let i;try{i=e.animate(r,n)}catch{return{finished:Promise.resolve()}}return typeof i.finished>"u"&&(i.finished=new Promise(s=>{i.onfinish=()=>{s(i)}})),i}const z="cubic-bezier(0.4, 0, 0.2, 1)",I="cubic-bezier(0.0, 0, 0.2, 1)",C="cubic-bezier(0.4, 0, 1, 1)",S=v({eager:Boolean},"lazy");function _(e,r){const n=w(!1),i=x(()=>n.value||e.eager||r.value);R(r,()=>n.value=!0);function s(){e.eager||(n.value=!1)}return{isBooted:n,hasContent:i,onAfterLeave:s}}function A(){const r=b("useScopeId").vnode.scopeId;return{scopeId:r?{[r]:""}:void 0}}const p=Symbol("Forwarded refs");function g(e,r){let n=e;for(;n;){const i=Reflect.getOwnPropertyDescriptor(n,r);if(i)return i;n=Object.getPrototypeOf(n)}}function D(e){for(var r=arguments.length,n=new Array(r>1?r-1:0),i=1;i"u")return{finished:Promise.resolve()};let i;try{i=e.animate(r,n)}catch{return{finished:Promise.resolve()}}return typeof i.finished>"u"&&(i.finished=new Promise(s=>{i.onfinish=()=>{s(i)}})),i}const z="cubic-bezier(0.4, 0, 0.2, 1)",I="cubic-bezier(0.0, 0, 0.2, 1)",C="cubic-bezier(0.4, 0, 1, 1)",S=v({eager:Boolean},"lazy");function _(e,r){const n=w(!1),i=x(()=>n.value||e.eager||r.value);R(r,()=>n.value=!0);function s(){e.eager||(n.value=!1)}return{isBooted:n,hasContent:i,onAfterLeave:s}}function A(){const r=b("useScopeId").vnode.scopeId;return{scopeId:r?{[r]:""}:void 0}}const p=Symbol("Forwarded refs");function g(e,r){let n=e;for(;n;){const i=Reflect.getOwnPropertyDescriptor(n,r);if(i)return i;n=Object.getPrototypeOf(n)}}function D(e){for(var r=arguments.length,n=new Array(r>1?r-1:0),i=1;i= 0x80 (not a basic code point)","invalid-input":"Invalid input"},L=s-P,j=Math.floor,T=String.fromCharCode,H;function D(c){throw new RangeError(C[c])}function J(c,f){for(var g=c.length,w=[];g--;)w[g]=f(c[g]);return w}function K(c,f){var g=c.split("@"),w="";g.length>1&&(w=g[0]+"@",c=g[1]),c=c.replace($,".");var _=c.split("."),x=J(_,f).join(".");return w+x}function X(c){for(var f=[],g=0,w=c.length,_,x;g=55296&&_<=56319&&g65535&&(f-=65536,g+=T(f>>>10&1023|55296),f=56320|f&1023),g+=T(f),g}).join("")}function e(c){return c-48<10?c-22:c-65<26?c-65:c-97<26?c-97:s}function r(c,f){return c+22+75*(c<26)-((f!=0)<<5)}function t(c,f,g){var w=0;for(c=g?j(c/y):c>>1,c+=j(c/f);c>L*z>>1;w+=s)c=j(c/L);return j(w+(L+1)*c/(c+S))}function o(c){var f=[],g=c.length,w,_=0,x=U,k=M,I,q,A,B,Q,E,O,V,Z;for(I=c.lastIndexOf(F),I<0&&(I=0),q=0;q=128&&D("not-basic"),f.push(c.charCodeAt(q));for(A=I>0?I+1:0;A=g&&D("invalid-input"),O=e(c.charCodeAt(A++)),(O>=s||O>j((d-_)/Q))&&D("overflow"),_+=O*Q,V=E<=k?P:E>=k+z?z:E-k,!(Oj(d/Z)&&D("overflow"),Q*=Z;w=f.length+1,k=t(_-B,w,B==0),j(_/w)>d-x&&D("overflow"),x+=j(_/w),_%=w,f.splice(_++,0,x)}return Y(f)}function i(c){var f,g,w,_,x,k,I,q,A,B,Q,E=[],O,V,Z,re;for(c=X(c),O=c.length,f=U,g=0,x=M,k=0;k=f&&Qj((d-g)/V)&&D("overflow"),g+=(I-f)*V,f=I,k=0;kd&&D("overflow"),Q==f){for(q=g,A=s;B=A<=x?P:A>=x+z?z:A-x,!(q= 0x80 (not a basic code point)","invalid-input":"Invalid input"},L=s-P,j=Math.floor,T=String.fromCharCode,H;function D(c){throw new RangeError(C[c])}function J(c,f){for(var g=c.length,w=[];g--;)w[g]=f(c[g]);return w}function K(c,f){var g=c.split("@"),w="";g.length>1&&(w=g[0]+"@",c=g[1]),c=c.replace($,".");var _=c.split("."),x=J(_,f).join(".");return w+x}function X(c){for(var f=[],g=0,w=c.length,_,x;g=55296&&_<=56319&&g65535&&(f-=65536,g+=T(f>>>10&1023|55296),f=56320|f&1023),g+=T(f),g}).join("")}function e(c){return c-48<10?c-22:c-65<26?c-65:c-97<26?c-97:s}function r(c,f){return c+22+75*(c<26)-((f!=0)<<5)}function t(c,f,g){var w=0;for(c=g?j(c/y):c>>1,c+=j(c/f);c>L*z>>1;w+=s)c=j(c/L);return j(w+(L+1)*c/(c+S))}function o(c){var f=[],g=c.length,w,_=0,x=U,k=M,I,q,A,B,Q,E,O,V,Z;for(I=c.lastIndexOf(F),I<0&&(I=0),q=0;q=128&&D("not-basic"),f.push(c.charCodeAt(q));for(A=I>0?I+1:0;A=g&&D("invalid-input"),O=e(c.charCodeAt(A++)),(O>=s||O>j((d-_)/Q))&&D("overflow"),_+=O*Q,V=E<=k?P:E>=k+z?z:E-k,!(Oj(d/Z)&&D("overflow"),Q*=Z;w=f.length+1,k=t(_-B,w,B==0),j(_/w)>d-x&&D("overflow"),x+=j(_/w),_%=w,f.splice(_++,0,x)}return Y(f)}function i(c){var f,g,w,_,x,k,I,q,A,B,Q,E=[],O,V,Z,re;for(c=X(c),O=c.length,f=U,g=0,x=M,k=0;k=f&&Qj((d-g)/V)&&D("overflow"),g+=(I-f)*V,f=I,k=0;kd&&D("overflow"),Q==f){for(q=g,A=s;B=A<=x?P:A>=x+z?z:A-x,!(q{const e=n.group?c:p;return h(e,{name:n.disabled?"":o,css:!n.disabled,...n.group?void 0:{mode:n.mode},...n.disabled?{}:t},a.default)}}})}function m(o,d){let i=arguments.length>2&&arguments[2]!==void 0?arguments[2]:"in-out";return g()({name:o,props:{mode:{type:String,default:i},disabled:Boolean,group:Boolean},setup(n,r){let{slots:a}=r;const t=n.group?c:p;return()=>h(t,{name:n.disabled?"":o,css:!n.disabled,...n.disabled?{}:d},a.default)}})}function v(){let o=arguments.length>0&&arguments[0]!==void 0?arguments[0]:"";const i=(arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1)?"width":"height",n=S(`offset-${i}`);return{onBeforeEnter(t){t._parent=t.parentNode,t._initialStyle={transition:t.style.transition,overflow:t.style.overflow,[i]:t.style[i]}},onEnter(t){const e=t._initialStyle;t.style.setProperty("transition","none","important"),t.style.overflow="hidden";const l=`${t[n]}px`;t.style[i]="0",t.offsetHeight,t.style.transition=e.transition,o&&t._parent&&t._parent.classList.add(o),requestAnimationFrame(()=>{t.style[i]=l})},onAfterEnter:a,onEnterCancelled:a,onLeave(t){t._initialStyle={transition:"",overflow:t.style.overflow,[i]:t.style[i]},t.style.overflow="hidden",t.style[i]=`${t[n]}px`,t.offsetHeight,requestAnimationFrame(()=>t.style[i]="0")},onAfterLeave:r,onLeaveCancelled:r};function r(t){o&&t._parent&&t._parent.classList.remove(o),a(t)}function a(t){const e=t._initialStyle[i];t.style.overflow=t._initialStyle.overflow,e!=null&&(t.style[i]=e),delete t._initialStyle}}s("fab-transition","center center","out-in");s("dialog-bottom-transition");s("dialog-top-transition");const L=s("fade-transition");s("scale-transition");s("scroll-x-transition");s("scroll-x-reverse-transition");s("scroll-y-transition");s("scroll-y-reverse-transition");s("slide-x-transition");s("slide-x-reverse-transition");s("slide-y-transition");s("slide-y-reverse-transition");const T=m("expand-transition",v());m("expand-x-transition",v("",!0));export{L as V,T as a}; +import{g,bk as c,ab as p,aA as h,p as b,bl as S}from"./index-Dvu417lt.js";const _=b({disabled:Boolean,group:Boolean,hideOnLeave:Boolean,leaveAbsolute:Boolean,mode:String,origin:String},"transition");function s(o,d,i){return g()({name:o,props:_({mode:i,origin:d}),setup(n,r){let{slots:a}=r;const t={onBeforeEnter(e){n.origin&&(e.style.transformOrigin=n.origin)},onLeave(e){if(n.leaveAbsolute){const{offsetTop:l,offsetLeft:f,offsetWidth:y,offsetHeight:u}=e;e._transitionInitialStyles={position:e.style.position,top:e.style.top,left:e.style.left,width:e.style.width,height:e.style.height},e.style.position="absolute",e.style.top=`${l}px`,e.style.left=`${f}px`,e.style.width=`${y}px`,e.style.height=`${u}px`}n.hideOnLeave&&e.style.setProperty("display","none","important")},onAfterLeave(e){if(n.leaveAbsolute&&e?._transitionInitialStyles){const{position:l,top:f,left:y,width:u,height:x}=e._transitionInitialStyles;delete e._transitionInitialStyles,e.style.position=l||"",e.style.top=f||"",e.style.left=y||"",e.style.width=u||"",e.style.height=x||""}}};return()=>{const e=n.group?c:p;return h(e,{name:n.disabled?"":o,css:!n.disabled,...n.group?void 0:{mode:n.mode},...n.disabled?{}:t},a.default)}}})}function m(o,d){let i=arguments.length>2&&arguments[2]!==void 0?arguments[2]:"in-out";return g()({name:o,props:{mode:{type:String,default:i},disabled:Boolean,group:Boolean},setup(n,r){let{slots:a}=r;const t=n.group?c:p;return()=>h(t,{name:n.disabled?"":o,css:!n.disabled,...n.disabled?{}:d},a.default)}})}function v(){let o=arguments.length>0&&arguments[0]!==void 0?arguments[0]:"";const i=(arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1)?"width":"height",n=S(`offset-${i}`);return{onBeforeEnter(t){t._parent=t.parentNode,t._initialStyle={transition:t.style.transition,overflow:t.style.overflow,[i]:t.style[i]}},onEnter(t){const e=t._initialStyle;t.style.setProperty("transition","none","important"),t.style.overflow="hidden";const l=`${t[n]}px`;t.style[i]="0",t.offsetHeight,t.style.transition=e.transition,o&&t._parent&&t._parent.classList.add(o),requestAnimationFrame(()=>{t.style[i]=l})},onAfterEnter:a,onEnterCancelled:a,onLeave(t){t._initialStyle={transition:"",overflow:t.style.overflow,[i]:t.style[i]},t.style.overflow="hidden",t.style[i]=`${t[n]}px`,t.offsetHeight,requestAnimationFrame(()=>t.style[i]="0")},onAfterLeave:r,onLeaveCancelled:r};function r(t){o&&t._parent&&t._parent.classList.remove(o),a(t)}function a(t){const e=t._initialStyle[i];t.style.overflow=t._initialStyle.overflow,e!=null&&(t.style[i]=e),delete t._initialStyle}}s("fab-transition","center center","out-in");s("dialog-bottom-transition");s("dialog-top-transition");const L=s("fade-transition");s("scale-transition");s("scroll-x-transition");s("scroll-x-reverse-transition");s("scroll-y-transition");s("scroll-y-reverse-transition");s("slide-x-transition");s("slide-x-reverse-transition");s("slide-y-transition");s("slide-y-reverse-transition");const A=m("expand-transition",v());m("expand-x-transition",v("",!0));export{L as V,A as a}; diff --git a/pr-preview/pr-17/assets/index-BHzPgH2J.js b/pr-preview/pr-17/assets/index-Dvu417lt.js similarity index 53% rename from pr-preview/pr-17/assets/index-BHzPgH2J.js rename to pr-preview/pr-17/assets/index-Dvu417lt.js index ec92dc4..6d93690 100644 --- a/pr-preview/pr-17/assets/index-BHzPgH2J.js +++ b/pr-preview/pr-17/assets/index-Dvu417lt.js @@ -1,29 +1,29 @@ -const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/webfontloader-OEBPRw3i.js","assets/_commonjsHelpers-Cpj98o6Y.js","assets/EodashDatePicker-D2GVtzgD.js","assets/helpers-DVHVKCdb.js","assets/VOverlay-Di1btkZg.js","assets/forwardRefs-BoZnhoLd.js","assets/transition-zS3yGrDV.js","assets/VOverlay-7P9ZDRB1.css","assets/EodashDatePicker-ClB_nEyz.css","assets/EodashMap-BVEvKne5.js","assets/EodashMapBtns-jNIMsmmc.js","assets/ExportState-CN3SVEwD.js","assets/PopUp-BLlcRLMy.js","assets/PopUp-C7scL-fp.css","assets/index-DLx-KgOd.js","assets/VDivider-CnS8Y1Zb.js","assets/VImg-i8uxgNTt.js","assets/VImg-BzNflMvG.css","assets/VDivider-DIjdKgTP.css","assets/ExportState-DyBA6-z0.css","assets/EodashMapBtns-CPcoqvv5.css","assets/List-DXPnbxiN.js","assets/ssrBoot-7hoALQc5.js","assets/List-Ccmb12OW.css","assets/MobileLayout-Bse6a_iI.js","assets/VMain-CoJ_6Ucg.js","assets/VMain-BbSmdCG_.css","assets/MobileLayout-BK_cuoYT.css","assets/DashboardLayout-B8MEdnS8.js","assets/DashboardLayout-1feu1wms.css","assets/Header-CWK95wXa.js","assets/Header-L0dTPwgQ.css","assets/Footer-9K1bUbvk.js","assets/Footer-B-aywIir.css"])))=>i.map(i=>d[i]); +const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/webfontloader-OEBPRw3i.js","assets/_commonjsHelpers-Cpj98o6Y.js","assets/EodashDatePicker-g0QWHEy-.js","assets/helpers-CkhK5_6d.js","assets/VOverlay-DGc1wXYF.js","assets/forwardRefs-DzUtZcD3.js","assets/transition-BKtsYhmO.js","assets/VOverlay-7P9ZDRB1.css","assets/EodashDatePicker-ClB_nEyz.css","assets/EodashMap-BDE_gmHB.js","assets/EodashMapBtns-BBddO65x.js","assets/ExportState-D-Xz2LGJ.js","assets/PopUp-5-tUIM9N.js","assets/PopUp-C7scL-fp.css","assets/index-CIIeHcTL.js","assets/VImg-CLLthewK.js","assets/VImg-BzNflMvG.css","assets/ExportState-C78fNrFy.css","assets/EodashMapBtns-CPcoqvv5.css","assets/MobileLayout-DtBtTe7v.js","assets/ssrBoot-Uu_-yAhn.js","assets/VMain-CoSaaYTf.js","assets/VMain-BbSmdCG_.css","assets/MobileLayout-BK_cuoYT.css","assets/DashboardLayout-Bklr6-8p.js","assets/DashboardLayout-1feu1wms.css","assets/Header-LhvQ5ty7.js","assets/Header-L0dTPwgQ.css","assets/Footer-Bbz6BUHt.js","assets/Footer-B-aywIir.css"])))=>i.map(i=>d[i]); (function(){const t=document.createElement("link").relList;if(t&&t.supports&&t.supports("modulepreload"))return;for(const s of document.querySelectorAll('link[rel="modulepreload"]'))r(s);new MutationObserver(s=>{for(const o of s)if(o.type==="childList")for(const a of o.addedNodes)a.tagName==="LINK"&&a.rel==="modulepreload"&&r(a)}).observe(document,{childList:!0,subtree:!0});function n(s){const o={};return s.integrity&&(o.integrity=s.integrity),s.referrerPolicy&&(o.referrerPolicy=s.referrerPolicy),s.crossOrigin==="use-credentials"?o.credentials="include":s.crossOrigin==="anonymous"?o.credentials="omit":o.credentials="same-origin",o}function r(s){if(s.ep)return;s.ep=!0;const o=n(s);fetch(s.href,o)}})();/** * @vue/shared v3.4.35 * (c) 2018-present Yuxi (Evan) You and Vue contributors * @license MIT -**//*! #__NO_SIDE_EFFECTS__ */function Ml(e,t){const n=new Set(e.split(","));return r=>n.has(r)}const Me={},Ir=[],Lt=()=>{},Ng=()=>!1,Ca=e=>e.charCodeAt(0)===111&&e.charCodeAt(1)===110&&(e.charCodeAt(2)>122||e.charCodeAt(2)<97),xl=e=>e.startsWith("onUpdate:"),Ke=Object.assign,kl=(e,t)=>{const n=e.indexOf(t);n>-1&&e.splice(n,1)},Fg=Object.prototype.hasOwnProperty,De=(e,t)=>Fg.call(e,t),le=Array.isArray,Lr=e=>Sa(e)==="[object Map]",ah=e=>Sa(e)==="[object Set]",ce=e=>typeof e=="function",Ve=e=>typeof e=="string",Vn=e=>typeof e=="symbol",Ie=e=>e!==null&&typeof e=="object",Pl=e=>(Ie(e)||ce(e))&&ce(e.then)&&ce(e.catch),ih=Object.prototype.toString,Sa=e=>ih.call(e),Yg=e=>Sa(e).slice(8,-1),lh=e=>Sa(e)==="[object Object]",Al=e=>Ve(e)&&e!=="NaN"&&e[0]!=="-"&&""+parseInt(e,10)===e,Ms=Ml(",key,ref,ref_for,ref_key,onVnodeBeforeMount,onVnodeMounted,onVnodeBeforeUpdate,onVnodeUpdated,onVnodeBeforeUnmount,onVnodeUnmounted"),$a=e=>{const t=Object.create(null);return n=>t[n]||(t[n]=e(n))},Bg=/-(\w)/g,xt=$a(e=>e.replace(Bg,(t,n)=>n?n.toUpperCase():"")),Hg=/\B([A-Z])/g,_n=$a(e=>e.replace(Hg,"-$1").toLowerCase()),Dn=$a(e=>e.charAt(0).toUpperCase()+e.slice(1)),Io=$a(e=>e?`on${Dn(e)}`:""),yt=(e,t)=>!Object.is(e,t),li=(e,...t)=>{for(let n=0;n{Object.defineProperty(e,t,{configurable:!0,enumerable:!1,writable:r,value:n})},jg=e=>{const t=parseFloat(e);return isNaN(t)?e:t},ch=e=>{const t=Ve(e)?Number(e):NaN;return isNaN(t)?e:t};let tc;const fh=()=>tc||(tc=typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:typeof global<"u"?global:{});function pn(e){if(le(e)){const t={};for(let n=0;n{if(n){const r=n.split(Wg);r.length>1&&(t[r[0].trim()]=r[1].trim())}}),t}function ke(e){let t="";if(Ve(e))t=e;else if(le(e))for(let n=0;n!!(e&&e.__v_isRef===!0),Qe=e=>Ve(e)?e:e==null?"":le(e)||Ie(e)&&(e.toString===ih||!ce(e.toString))?hh(e)?Qe(e.value):JSON.stringify(e,vh,2):String(e),vh=(e,t)=>hh(t)?vh(e,t.value):Lr(t)?{[`Map(${t.size})`]:[...t.entries()].reduce((n,[r,s],o)=>(n[ui(r,o)+" =>"]=s,n),{})}:ah(t)?{[`Set(${t.size})`]:[...t.values()].map(n=>ui(n))}:Vn(t)?ui(t):Ie(t)&&!le(t)&&!lh(t)?String(t):t,ui=(e,t="")=>{var n;return Vn(e)?`Symbol(${(n=e.description)!=null?n:t})`:e};/** +**//*! #__NO_SIDE_EFFECTS__ */function Ol(e,t){const n=new Set(e.split(","));return r=>n.has(r)}const Me={},Ir=[],Lt=()=>{},Rg=()=>!1,Ca=e=>e.charCodeAt(0)===111&&e.charCodeAt(1)===110&&(e.charCodeAt(2)>122||e.charCodeAt(2)<97),Ml=e=>e.startsWith("onUpdate:"),Ke=Object.assign,kl=(e,t)=>{const n=e.indexOf(t);n>-1&&e.splice(n,1)},Ng=Object.prototype.hasOwnProperty,De=(e,t)=>Ng.call(e,t),le=Array.isArray,Lr=e=>Sa(e)==="[object Map]",ah=e=>Sa(e)==="[object Set]",ce=e=>typeof e=="function",Ve=e=>typeof e=="string",Vn=e=>typeof e=="symbol",Ie=e=>e!==null&&typeof e=="object",xl=e=>(Ie(e)||ce(e))&&ce(e.then)&&ce(e.catch),ih=Object.prototype.toString,Sa=e=>ih.call(e),Fg=e=>Sa(e).slice(8,-1),lh=e=>Sa(e)==="[object Object]",Pl=e=>Ve(e)&&e!=="NaN"&&e[0]!=="-"&&""+parseInt(e,10)===e,Ms=Ol(",key,ref,ref_for,ref_key,onVnodeBeforeMount,onVnodeMounted,onVnodeBeforeUpdate,onVnodeUpdated,onVnodeBeforeUnmount,onVnodeUnmounted"),$a=e=>{const t=Object.create(null);return n=>t[n]||(t[n]=e(n))},Yg=/-(\w)/g,kt=$a(e=>e.replace(Yg,(t,n)=>n?n.toUpperCase():"")),Bg=/\B([A-Z])/g,_n=$a(e=>e.replace(Bg,"-$1").toLowerCase()),Dn=$a(e=>e.charAt(0).toUpperCase()+e.slice(1)),Io=$a(e=>e?`on${Dn(e)}`:""),yt=(e,t)=>!Object.is(e,t),li=(e,...t)=>{for(let n=0;n{Object.defineProperty(e,t,{configurable:!0,enumerable:!1,writable:r,value:n})},Hg=e=>{const t=parseFloat(e);return isNaN(t)?e:t},ch=e=>{const t=Ve(e)?Number(e):NaN;return isNaN(t)?e:t};let ec;const fh=()=>ec||(ec=typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:typeof global<"u"?global:{});function pn(e){if(le(e)){const t={};for(let n=0;n{if(n){const r=n.split(Vg);r.length>1&&(t[r[0].trim()]=r[1].trim())}}),t}function xe(e){let t="";if(Ve(e))t=e;else if(le(e))for(let n=0;n!!(e&&e.__v_isRef===!0),Xe=e=>Ve(e)?e:e==null?"":le(e)||Ie(e)&&(e.toString===ih||!ce(e.toString))?hh(e)?Xe(e.value):JSON.stringify(e,vh,2):String(e),vh=(e,t)=>hh(t)?vh(e,t.value):Lr(t)?{[`Map(${t.size})`]:[...t.entries()].reduce((n,[r,s],o)=>(n[ui(r,o)+" =>"]=s,n),{})}:ah(t)?{[`Set(${t.size})`]:[...t.values()].map(n=>ui(n))}:Vn(t)?ui(t):Ie(t)&&!le(t)&&!lh(t)?String(t):t,ui=(e,t="")=>{var n;return Vn(e)?`Symbol(${(n=e.description)!=null?n:t})`:e};/** * @vue/reactivity v3.4.35 * (c) 2018-present Yuxi (Evan) You and Vue contributors * @license MIT -**/let Tt;class mh{constructor(t=!1){this.detached=t,this._active=!0,this.effects=[],this.cleanups=[],this.parent=Tt,!t&&Tt&&(this.index=(Tt.scopes||(Tt.scopes=[])).push(this)-1)}get active(){return this._active}run(t){if(this._active){const n=Tt;try{return Tt=this,t()}finally{Tt=n}}}on(){Tt=this}off(){Tt=this.parent}stop(t){if(this._active){let n,r;for(n=0,r=this.effects.length;n=4))break}this._dirtyLevel===1&&(this._dirtyLevel=0),Un()}return this._dirtyLevel>=4}set dirty(t){this._dirtyLevel=t?4:0}run(){if(this._dirtyLevel=0,!this.active)return this.fn();let t=Fn,n=lr;try{return Fn=!0,lr=this,this._runnings++,nc(this),this.fn()}finally{rc(this),this._runnings--,lr=n,Fn=t}}stop(){this.active&&(nc(this),rc(this),this.onStop&&this.onStop(),this.active=!1)}}function Zg(e){return e.value}function nc(e){e._trackId++,e._depsLength=0}function rc(e){if(e.deps.length>e._depsLength){for(let t=e._depsLength;t{const n=new Map;return n.cleanup=e,n.computed=t,n},Go=new WeakMap,ur=Symbol(""),Yi=Symbol("");function Ct(e,t,n){if(Fn&&lr){let r=Go.get(e);r||Go.set(e,r=new Map);let s=r.get(n);s||r.set(n,s=_h(()=>r.delete(n))),bh(lr,s)}}function gn(e,t,n,r,s,o){const a=Go.get(e);if(!a)return;let i=[];if(t==="clear")i=[...a.values()];else if(n==="length"&&le(e)){const l=Number(r);a.forEach((u,c)=>{(c==="length"||!Vn(c)&&c>=l)&&i.push(u)})}else switch(n!==void 0&&i.push(a.get(n)),t){case"add":le(e)?Al(n)&&i.push(a.get("length")):(i.push(a.get(ur)),Lr(e)&&i.push(a.get(Yi)));break;case"delete":le(e)||(i.push(a.get(ur)),Lr(e)&&i.push(a.get(Yi)));break;case"set":Lr(e)&&i.push(a.get(ur));break}Nl();for(const l of i)l&&wh(l,4);Fl()}function Jg(e,t){const n=Go.get(e);return n&&n.get(t)}const Xg=Ml("__proto__,__v_isRef,__isVue"),Dh=new Set(Object.getOwnPropertyNames(Symbol).filter(e=>e!=="arguments"&&e!=="caller").map(e=>Symbol[e]).filter(Vn)),sc=Qg();function Qg(){const e={};return["includes","indexOf","lastIndexOf"].forEach(t=>{e[t]=function(...n){const r=ge(this);for(let o=0,a=this.length;o{e[t]=function(...n){Wn(),Nl();const r=ge(this)[t].apply(this,n);return Fl(),Un(),r}}),e}function ey(e){Vn(e)||(e=String(e));const t=ge(this);return Ct(t,"has",e),t.hasOwnProperty(e)}class Ch{constructor(t=!1,n=!1){this._isReadonly=t,this._isShallow=n}get(t,n,r){const s=this._isReadonly,o=this._isShallow;if(n==="__v_isReactive")return!s;if(n==="__v_isReadonly")return s;if(n==="__v_isShallow")return o;if(n==="__v_raw")return r===(s?o?hy:Eh:o?Th:$h).get(t)||Object.getPrototypeOf(t)===Object.getPrototypeOf(r)?t:void 0;const a=le(t);if(!s){if(a&&De(sc,n))return Reflect.get(sc,n,r);if(n==="hasOwnProperty")return ey}const i=Reflect.get(t,n,r);return(Vn(n)?Dh.has(n):Xg(n))||(s||Ct(t,"get",n),o)?i:Se(i)?a&&Al(n)?i:i.value:Ie(i)?s?Ea(i):je(i):i}}class Sh extends Ch{constructor(t=!1){super(!1,t)}set(t,n,r,s){let o=t[n];if(!this._isShallow){const l=hr(o);if(!Wr(r)&&!hr(r)&&(o=ge(o),r=ge(r)),!le(t)&&Se(o)&&!Se(r))return l?!1:(o.value=r,!0)}const a=le(t)&&Al(n)?Number(n)e,Ta=e=>Reflect.getPrototypeOf(e);function bo(e,t,n=!1,r=!1){e=e.__v_raw;const s=ge(e),o=ge(t);n||(yt(t,o)&&Ct(s,"get",t),Ct(s,"get",o));const{has:a}=Ta(s),i=r?Yl:n?Vl:Ys;if(a.call(s,t))return i(e.get(t));if(a.call(s,o))return i(e.get(o));e!==s&&e.get(t)}function wo(e,t=!1){const n=this.__v_raw,r=ge(n),s=ge(e);return t||(yt(e,s)&&Ct(r,"has",e),Ct(r,"has",s)),e===s?n.has(e):n.has(e)||n.has(s)}function _o(e,t=!1){return e=e.__v_raw,!t&&Ct(ge(e),"iterate",ur),Reflect.get(e,"size",e)}function oc(e,t=!1){!t&&!Wr(e)&&!hr(e)&&(e=ge(e));const n=ge(this);return Ta(n).has.call(n,e)||(n.add(e),gn(n,"add",e,e)),this}function ac(e,t,n=!1){!n&&!Wr(t)&&!hr(t)&&(t=ge(t));const r=ge(this),{has:s,get:o}=Ta(r);let a=s.call(r,e);a||(e=ge(e),a=s.call(r,e));const i=o.call(r,e);return r.set(e,t),a?yt(t,i)&&gn(r,"set",e,t):gn(r,"add",e,t),this}function ic(e){const t=ge(this),{has:n,get:r}=Ta(t);let s=n.call(t,e);s||(e=ge(e),s=n.call(t,e)),r&&r.call(t,e);const o=t.delete(e);return s&&gn(t,"delete",e,void 0),o}function lc(){const e=ge(this),t=e.size!==0,n=e.clear();return t&&gn(e,"clear",void 0,void 0),n}function Do(e,t){return function(r,s){const o=this,a=o.__v_raw,i=ge(a),l=t?Yl:e?Vl:Ys;return!e&&Ct(i,"iterate",ur),a.forEach((u,c)=>r.call(s,l(u),l(c),o))}}function Co(e,t,n){return function(...r){const s=this.__v_raw,o=ge(s),a=Lr(o),i=e==="entries"||e===Symbol.iterator&&a,l=e==="keys"&&a,u=s[e](...r),c=n?Yl:t?Vl:Ys;return!t&&Ct(o,"iterate",l?Yi:ur),{next(){const{value:f,done:d}=u.next();return d?{value:f,done:d}:{value:i?[c(f[0]),c(f[1])]:c(f),done:d}},[Symbol.iterator](){return this}}}}function Tn(e){return function(...t){return e==="delete"?!1:e==="clear"?void 0:this}}function oy(){const e={get(o){return bo(this,o)},get size(){return _o(this)},has:wo,add:oc,set:ac,delete:ic,clear:lc,forEach:Do(!1,!1)},t={get(o){return bo(this,o,!1,!0)},get size(){return _o(this)},has:wo,add(o){return oc.call(this,o,!0)},set(o,a){return ac.call(this,o,a,!0)},delete:ic,clear:lc,forEach:Do(!1,!0)},n={get(o){return bo(this,o,!0)},get size(){return _o(this,!0)},has(o){return wo.call(this,o,!0)},add:Tn("add"),set:Tn("set"),delete:Tn("delete"),clear:Tn("clear"),forEach:Do(!0,!1)},r={get(o){return bo(this,o,!0,!0)},get size(){return _o(this,!0)},has(o){return wo.call(this,o,!0)},add:Tn("add"),set:Tn("set"),delete:Tn("delete"),clear:Tn("clear"),forEach:Do(!0,!0)};return["keys","values","entries",Symbol.iterator].forEach(o=>{e[o]=Co(o,!1,!1),n[o]=Co(o,!0,!1),t[o]=Co(o,!1,!0),r[o]=Co(o,!0,!0)}),[e,n,t,r]}const[ay,iy,ly,uy]=oy();function Bl(e,t){const n=t?e?uy:ly:e?iy:ay;return(r,s,o)=>s==="__v_isReactive"?!e:s==="__v_isReadonly"?e:s==="__v_raw"?r:Reflect.get(De(n,s)&&s in r?n:r,s,o)}const cy={get:Bl(!1,!1)},fy={get:Bl(!1,!0)},dy={get:Bl(!0,!1)};const $h=new WeakMap,Th=new WeakMap,Eh=new WeakMap,hy=new WeakMap;function vy(e){switch(e){case"Object":case"Array":return 1;case"Map":case"Set":case"WeakMap":case"WeakSet":return 2;default:return 0}}function my(e){return e.__v_skip||!Object.isExtensible(e)?0:vy(Yg(e))}function je(e){return hr(e)?e:Hl(e,!1,ny,cy,$h)}function py(e){return Hl(e,!1,sy,fy,Th)}function Ea(e){return Hl(e,!0,ry,dy,Eh)}function Hl(e,t,n,r,s){if(!Ie(e)||e.__v_raw&&!(t&&e.__v_isReactive))return e;const o=s.get(e);if(o)return o;const a=my(e);if(a===0)return e;const i=new Proxy(e,a===2?r:n);return s.set(e,i),i}function Yn(e){return hr(e)?Yn(e.__v_raw):!!(e&&e.__v_isReactive)}function hr(e){return!!(e&&e.__v_isReadonly)}function Wr(e){return!!(e&&e.__v_isShallow)}function Oh(e){return e?!!e.__v_raw:!1}function ge(e){const t=e&&e.__v_raw;return t?ge(t):e}function jl(e){return Object.isExtensible(e)&&uh(e,"__v_skip",!0),e}const Ys=e=>Ie(e)?je(e):e,Vl=e=>Ie(e)?Ea(e):e;class Mh{constructor(t,n,r,s){this.getter=t,this._setter=n,this.dep=void 0,this.__v_isRef=!0,this.__v_isReadonly=!1,this.effect=new Rl(()=>t(this._value),()=>xs(this,this.effect._dirtyLevel===2?2:3)),this.effect.computed=this,this.effect.active=this._cacheable=!s,this.__v_isReadonly=r}get value(){const t=ge(this);return(!t._cacheable||t.effect.dirty)&&yt(t._value,t._value=t.effect.run())&&xs(t,4),Wl(t),t.effect._dirtyLevel>=2&&xs(t,2),t._value}set value(t){this._setter(t)}get _dirty(){return this.effect.dirty}set _dirty(t){this.effect.dirty=t}}function gy(e,t,n=!1){let r,s;const o=ce(e);return o?(r=e,s=Lt):(r=e.get,s=e.set),new Mh(r,s,o||!s,n)}function Wl(e){var t;Fn&&lr&&(e=ge(e),bh(lr,(t=e.dep)!=null?t:e.dep=_h(()=>e.dep=void 0,e instanceof Mh?e:void 0)))}function xs(e,t=4,n,r){e=ge(e);const s=e.dep;s&&wh(s,t)}function Se(e){return!!(e&&e.__v_isRef===!0)}function oe(e){return xh(e,!1)}function Ut(e){return xh(e,!0)}function xh(e,t){return Se(e)?e:new yy(e,t)}class yy{constructor(t,n){this.__v_isShallow=n,this.dep=void 0,this.__v_isRef=!0,this._rawValue=n?t:ge(t),this._value=n?t:Ys(t)}get value(){return Wl(this),this._value}set value(t){const n=this.__v_isShallow||Wr(t)||hr(t);t=n?t:ge(t),yt(t,this._rawValue)&&(this._rawValue,this._rawValue=t,this._value=n?t:Ys(t),xs(this,4))}}function A(e){return Se(e)?e.value:e}const by={get:(e,t,n)=>A(Reflect.get(e,t,n)),set:(e,t,n,r)=>{const s=e[t];return Se(s)&&!Se(n)?(s.value=n,!0):Reflect.set(e,t,n,r)}};function kh(e){return Yn(e)?e:new Proxy(e,by)}class wy{constructor(t){this.dep=void 0,this.__v_isRef=!0;const{get:n,set:r}=t(()=>Wl(this),()=>xs(this));this._get=n,this._set=r}get value(){return this._get()}set value(t){this._set(t)}}function _y(e){return new wy(e)}function no(e){const t=le(e)?new Array(e.length):{};for(const n in e)t[n]=Ph(e,n);return t}class Dy{constructor(t,n,r){this._object=t,this._key=n,this._defaultValue=r,this.__v_isRef=!0}get value(){const t=this._object[this._key];return t===void 0?this._defaultValue:t}set value(t){this._object[this._key]=t}get dep(){return Jg(ge(this._object),this._key)}}class Cy{constructor(t){this._getter=t,this.__v_isRef=!0,this.__v_isReadonly=!0}get value(){return this._getter()}}function et(e,t,n){return Se(e)?e:ce(e)?new Cy(e):Ie(e)&&arguments.length>1?Ph(e,t,n):oe(e)}function Ph(e,t,n){const r=e[t];return Se(r)?r:new Dy(e,t,n)}/** +**/let Tt;class mh{constructor(t=!1){this.detached=t,this._active=!0,this.effects=[],this.cleanups=[],this.parent=Tt,!t&&Tt&&(this.index=(Tt.scopes||(Tt.scopes=[])).push(this)-1)}get active(){return this._active}run(t){if(this._active){const n=Tt;try{return Tt=this,t()}finally{Tt=n}}}on(){Tt=this}off(){Tt=this.parent}stop(t){if(this._active){let n,r;for(n=0,r=this.effects.length;n=4))break}this._dirtyLevel===1&&(this._dirtyLevel=0),Un()}return this._dirtyLevel>=4}set dirty(t){this._dirtyLevel=t?4:0}run(){if(this._dirtyLevel=0,!this.active)return this.fn();let t=Fn,n=lr;try{return Fn=!0,lr=this,this._runnings++,tc(this),this.fn()}finally{nc(this),this._runnings--,lr=n,Fn=t}}stop(){this.active&&(tc(this),nc(this),this.onStop&&this.onStop(),this.active=!1)}}function qg(e){return e.value}function tc(e){e._trackId++,e._depsLength=0}function nc(e){if(e.deps.length>e._depsLength){for(let t=e._depsLength;t{const n=new Map;return n.cleanup=e,n.computed=t,n},Go=new WeakMap,ur=Symbol(""),Yi=Symbol("");function Ct(e,t,n){if(Fn&&lr){let r=Go.get(e);r||Go.set(e,r=new Map);let s=r.get(n);s||r.set(n,s=_h(()=>r.delete(n))),bh(lr,s)}}function gn(e,t,n,r,s,o){const a=Go.get(e);if(!a)return;let i=[];if(t==="clear")i=[...a.values()];else if(n==="length"&&le(e)){const l=Number(r);a.forEach((u,c)=>{(c==="length"||!Vn(c)&&c>=l)&&i.push(u)})}else switch(n!==void 0&&i.push(a.get(n)),t){case"add":le(e)?Pl(n)&&i.push(a.get("length")):(i.push(a.get(ur)),Lr(e)&&i.push(a.get(Yi)));break;case"delete":le(e)||(i.push(a.get(ur)),Lr(e)&&i.push(a.get(Yi)));break;case"set":Lr(e)&&i.push(a.get(ur));break}Rl();for(const l of i)l&&wh(l,4);Nl()}function Zg(e,t){const n=Go.get(e);return n&&n.get(t)}const Jg=Ol("__proto__,__v_isRef,__isVue"),Dh=new Set(Object.getOwnPropertyNames(Symbol).filter(e=>e!=="arguments"&&e!=="caller").map(e=>Symbol[e]).filter(Vn)),rc=Xg();function Xg(){const e={};return["includes","indexOf","lastIndexOf"].forEach(t=>{e[t]=function(...n){const r=ge(this);for(let o=0,a=this.length;o{e[t]=function(...n){Wn(),Rl();const r=ge(this)[t].apply(this,n);return Nl(),Un(),r}}),e}function Qg(e){Vn(e)||(e=String(e));const t=ge(this);return Ct(t,"has",e),t.hasOwnProperty(e)}class Ch{constructor(t=!1,n=!1){this._isReadonly=t,this._isShallow=n}get(t,n,r){const s=this._isReadonly,o=this._isShallow;if(n==="__v_isReactive")return!s;if(n==="__v_isReadonly")return s;if(n==="__v_isShallow")return o;if(n==="__v_raw")return r===(s?o?dy:Eh:o?Th:$h).get(t)||Object.getPrototypeOf(t)===Object.getPrototypeOf(r)?t:void 0;const a=le(t);if(!s){if(a&&De(rc,n))return Reflect.get(rc,n,r);if(n==="hasOwnProperty")return Qg}const i=Reflect.get(t,n,r);return(Vn(n)?Dh.has(n):Jg(n))||(s||Ct(t,"get",n),o)?i:Se(i)?a&&Pl(n)?i:i.value:Ie(i)?s?Ea(i):je(i):i}}class Sh extends Ch{constructor(t=!1){super(!1,t)}set(t,n,r,s){let o=t[n];if(!this._isShallow){const l=hr(o);if(!Wr(r)&&!hr(r)&&(o=ge(o),r=ge(r)),!le(t)&&Se(o)&&!Se(r))return l?!1:(o.value=r,!0)}const a=le(t)&&Pl(n)?Number(n)e,Ta=e=>Reflect.getPrototypeOf(e);function bo(e,t,n=!1,r=!1){e=e.__v_raw;const s=ge(e),o=ge(t);n||(yt(t,o)&&Ct(s,"get",t),Ct(s,"get",o));const{has:a}=Ta(s),i=r?Fl:n?jl:Ys;if(a.call(s,t))return i(e.get(t));if(a.call(s,o))return i(e.get(o));e!==s&&e.get(t)}function wo(e,t=!1){const n=this.__v_raw,r=ge(n),s=ge(e);return t||(yt(e,s)&&Ct(r,"has",e),Ct(r,"has",s)),e===s?n.has(e):n.has(e)||n.has(s)}function _o(e,t=!1){return e=e.__v_raw,!t&&Ct(ge(e),"iterate",ur),Reflect.get(e,"size",e)}function sc(e,t=!1){!t&&!Wr(e)&&!hr(e)&&(e=ge(e));const n=ge(this);return Ta(n).has.call(n,e)||(n.add(e),gn(n,"add",e,e)),this}function oc(e,t,n=!1){!n&&!Wr(t)&&!hr(t)&&(t=ge(t));const r=ge(this),{has:s,get:o}=Ta(r);let a=s.call(r,e);a||(e=ge(e),a=s.call(r,e));const i=o.call(r,e);return r.set(e,t),a?yt(t,i)&&gn(r,"set",e,t):gn(r,"add",e,t),this}function ac(e){const t=ge(this),{has:n,get:r}=Ta(t);let s=n.call(t,e);s||(e=ge(e),s=n.call(t,e)),r&&r.call(t,e);const o=t.delete(e);return s&&gn(t,"delete",e,void 0),o}function ic(){const e=ge(this),t=e.size!==0,n=e.clear();return t&&gn(e,"clear",void 0,void 0),n}function Do(e,t){return function(r,s){const o=this,a=o.__v_raw,i=ge(a),l=t?Fl:e?jl:Ys;return!e&&Ct(i,"iterate",ur),a.forEach((u,c)=>r.call(s,l(u),l(c),o))}}function Co(e,t,n){return function(...r){const s=this.__v_raw,o=ge(s),a=Lr(o),i=e==="entries"||e===Symbol.iterator&&a,l=e==="keys"&&a,u=s[e](...r),c=n?Fl:t?jl:Ys;return!t&&Ct(o,"iterate",l?Yi:ur),{next(){const{value:f,done:d}=u.next();return d?{value:f,done:d}:{value:i?[c(f[0]),c(f[1])]:c(f),done:d}},[Symbol.iterator](){return this}}}}function Tn(e){return function(...t){return e==="delete"?!1:e==="clear"?void 0:this}}function sy(){const e={get(o){return bo(this,o)},get size(){return _o(this)},has:wo,add:sc,set:oc,delete:ac,clear:ic,forEach:Do(!1,!1)},t={get(o){return bo(this,o,!1,!0)},get size(){return _o(this)},has:wo,add(o){return sc.call(this,o,!0)},set(o,a){return oc.call(this,o,a,!0)},delete:ac,clear:ic,forEach:Do(!1,!0)},n={get(o){return bo(this,o,!0)},get size(){return _o(this,!0)},has(o){return wo.call(this,o,!0)},add:Tn("add"),set:Tn("set"),delete:Tn("delete"),clear:Tn("clear"),forEach:Do(!0,!1)},r={get(o){return bo(this,o,!0,!0)},get size(){return _o(this,!0)},has(o){return wo.call(this,o,!0)},add:Tn("add"),set:Tn("set"),delete:Tn("delete"),clear:Tn("clear"),forEach:Do(!0,!0)};return["keys","values","entries",Symbol.iterator].forEach(o=>{e[o]=Co(o,!1,!1),n[o]=Co(o,!0,!1),t[o]=Co(o,!1,!0),r[o]=Co(o,!0,!0)}),[e,n,t,r]}const[oy,ay,iy,ly]=sy();function Yl(e,t){const n=t?e?ly:iy:e?ay:oy;return(r,s,o)=>s==="__v_isReactive"?!e:s==="__v_isReadonly"?e:s==="__v_raw"?r:Reflect.get(De(n,s)&&s in r?n:r,s,o)}const uy={get:Yl(!1,!1)},cy={get:Yl(!1,!0)},fy={get:Yl(!0,!1)};const $h=new WeakMap,Th=new WeakMap,Eh=new WeakMap,dy=new WeakMap;function hy(e){switch(e){case"Object":case"Array":return 1;case"Map":case"Set":case"WeakMap":case"WeakSet":return 2;default:return 0}}function vy(e){return e.__v_skip||!Object.isExtensible(e)?0:hy(Fg(e))}function je(e){return hr(e)?e:Bl(e,!1,ty,uy,$h)}function my(e){return Bl(e,!1,ry,cy,Th)}function Ea(e){return Bl(e,!0,ny,fy,Eh)}function Bl(e,t,n,r,s){if(!Ie(e)||e.__v_raw&&!(t&&e.__v_isReactive))return e;const o=s.get(e);if(o)return o;const a=vy(e);if(a===0)return e;const i=new Proxy(e,a===2?r:n);return s.set(e,i),i}function Yn(e){return hr(e)?Yn(e.__v_raw):!!(e&&e.__v_isReactive)}function hr(e){return!!(e&&e.__v_isReadonly)}function Wr(e){return!!(e&&e.__v_isShallow)}function Oh(e){return e?!!e.__v_raw:!1}function ge(e){const t=e&&e.__v_raw;return t?ge(t):e}function Hl(e){return Object.isExtensible(e)&&uh(e,"__v_skip",!0),e}const Ys=e=>Ie(e)?je(e):e,jl=e=>Ie(e)?Ea(e):e;class Mh{constructor(t,n,r,s){this.getter=t,this._setter=n,this.dep=void 0,this.__v_isRef=!0,this.__v_isReadonly=!1,this.effect=new Ll(()=>t(this._value),()=>ks(this,this.effect._dirtyLevel===2?2:3)),this.effect.computed=this,this.effect.active=this._cacheable=!s,this.__v_isReadonly=r}get value(){const t=ge(this);return(!t._cacheable||t.effect.dirty)&&yt(t._value,t._value=t.effect.run())&&ks(t,4),Vl(t),t.effect._dirtyLevel>=2&&ks(t,2),t._value}set value(t){this._setter(t)}get _dirty(){return this.effect.dirty}set _dirty(t){this.effect.dirty=t}}function py(e,t,n=!1){let r,s;const o=ce(e);return o?(r=e,s=Lt):(r=e.get,s=e.set),new Mh(r,s,o||!s,n)}function Vl(e){var t;Fn&&lr&&(e=ge(e),bh(lr,(t=e.dep)!=null?t:e.dep=_h(()=>e.dep=void 0,e instanceof Mh?e:void 0)))}function ks(e,t=4,n,r){e=ge(e);const s=e.dep;s&&wh(s,t)}function Se(e){return!!(e&&e.__v_isRef===!0)}function oe(e){return kh(e,!1)}function Ut(e){return kh(e,!0)}function kh(e,t){return Se(e)?e:new gy(e,t)}class gy{constructor(t,n){this.__v_isShallow=n,this.dep=void 0,this.__v_isRef=!0,this._rawValue=n?t:ge(t),this._value=n?t:Ys(t)}get value(){return Vl(this),this._value}set value(t){const n=this.__v_isShallow||Wr(t)||hr(t);t=n?t:ge(t),yt(t,this._rawValue)&&(this._rawValue,this._rawValue=t,this._value=n?t:Ys(t),ks(this,4))}}function A(e){return Se(e)?e.value:e}const yy={get:(e,t,n)=>A(Reflect.get(e,t,n)),set:(e,t,n,r)=>{const s=e[t];return Se(s)&&!Se(n)?(s.value=n,!0):Reflect.set(e,t,n,r)}};function xh(e){return Yn(e)?e:new Proxy(e,yy)}class by{constructor(t){this.dep=void 0,this.__v_isRef=!0;const{get:n,set:r}=t(()=>Vl(this),()=>ks(this));this._get=n,this._set=r}get value(){return this._get()}set value(t){this._set(t)}}function wy(e){return new by(e)}function no(e){const t=le(e)?new Array(e.length):{};for(const n in e)t[n]=Ph(e,n);return t}class _y{constructor(t,n,r){this._object=t,this._key=n,this._defaultValue=r,this.__v_isRef=!0}get value(){const t=this._object[this._key];return t===void 0?this._defaultValue:t}set value(t){this._object[this._key]=t}get dep(){return Zg(ge(this._object),this._key)}}class Dy{constructor(t){this._getter=t,this.__v_isRef=!0,this.__v_isReadonly=!0}get value(){return this._getter()}}function et(e,t,n){return Se(e)?e:ce(e)?new Dy(e):Ie(e)&&arguments.length>1?Ph(e,t,n):oe(e)}function Ph(e,t,n){const r=e[t];return Se(r)?r:new _y(e,t,n)}/** * @vue/runtime-core v3.4.35 * (c) 2018-present Yuxi (Evan) You and Vue contributors * @license MIT -**/function Bn(e,t,n,r){try{return r?e(...r):e()}catch(s){rs(s,t,n)}}function Nt(e,t,n,r){if(ce(e)){const s=Bn(e,t,n,r);return s&&Pl(s)&&s.catch(o=>{rs(o,t,n)}),s}if(le(e)){const s=[];for(let o=0;o>>1,s=rt[r],o=Hs(s);oen&&rt.splice(t,1)}function Hi(e){le(e)?Nr.push(...e):(!Pn||!Pn.includes(e,e.allowRecurse?sr+1:sr))&&Nr.push(e),Ih()}function uc(e,t,n=Bs?en+1:0){for(;nHs(n)-Hs(r));if(Nr.length=0,Pn){Pn.push(...t);return}for(Pn=t,sr=0;sre.id==null?1/0:e.id,Ey=(e,t)=>{const n=Hs(e)-Hs(t);if(n===0){if(e.pre&&!t.pre)return-1;if(t.pre&&!e.pre)return 1}return n};function Rh(e){Bi=!1,Bs=!0,rt.sort(Ey);try{for(en=0;en{r._d&&_c(-1);const o=qo(t);let a;try{a=e(...s)}finally{qo(o),r._d&&_c(1)}return a};return r._n=!0,r._c=!0,r._d=!0,r}function zl(e,t){if(qe===null)return e;const n=La(qe),r=e.dirs||(e.dirs=[]);for(let s=0;s{e.isMounted=!0}),yr(()=>{e.isUnmounting=!0}),e}const It=[Function,Array],Fh={mode:String,appear:Boolean,persisted:Boolean,onBeforeEnter:It,onEnter:It,onAfterEnter:It,onEnterCancelled:It,onBeforeLeave:It,onLeave:It,onAfterLeave:It,onLeaveCancelled:It,onBeforeAppear:It,onAppear:It,onAfterAppear:It,onAppearCancelled:It},Yh=e=>{const t=e.subTree;return t.component?Yh(t.component):t},xy={name:"BaseTransition",props:Fh,setup(e,{slots:t}){const n=os(),r=Nh();return()=>{const s=t.default&&Kl(t.default(),!0);if(!s||!s.length)return;let o=s[0];if(s.length>1){for(const d of s)if(d.type!==st){o=d;break}}const a=ge(e),{mode:i}=a;if(r.isLeaving)return ci(o);const l=cc(o);if(!l)return ci(o);let u=js(l,a,r,n,d=>u=d);Ur(l,u);const c=n.subTree,f=c&&cc(c);if(f&&f.type!==st&&!tn(l,f)&&Yh(n).type!==st){const d=js(f,a,r,n);if(Ur(f,d),i==="out-in"&&l.type!==st)return r.isLeaving=!0,d.afterLeave=()=>{r.isLeaving=!1,n.update.active!==!1&&(n.effect.dirty=!0,n.update())},ci(o);i==="in-out"&&l.type!==st&&(d.delayLeave=(h,v,m)=>{const p=Bh(r,f);p[String(f.key)]=f,h[An]=()=>{v(),h[An]=void 0,delete u.delayedLeave},u.delayedLeave=m})}return o}}},ky=xy;function Bh(e,t){const{leavingVNodes:n}=e;let r=n.get(t.type);return r||(r=Object.create(null),n.set(t.type,r)),r}function js(e,t,n,r,s){const{appear:o,mode:a,persisted:i=!1,onBeforeEnter:l,onEnter:u,onAfterEnter:c,onEnterCancelled:f,onBeforeLeave:d,onLeave:h,onAfterLeave:v,onLeaveCancelled:m,onBeforeAppear:p,onAppear:b,onAfterAppear:S,onAppearCancelled:T}=t,M=String(e.key),D=Bh(n,e),C=($,I)=>{$&&Nt($,r,9,I)},E=($,I)=>{const j=I[1];C($,I),le($)?$.every(O=>O.length<=1)&&j():$.length<=1&&j()},P={mode:a,persisted:i,beforeEnter($){let I=l;if(!n.isMounted)if(o)I=p||l;else return;$[An]&&$[An](!0);const j=D[M];j&&tn(e,j)&&j.el[An]&&j.el[An](),C(I,[$])},enter($){let I=u,j=c,O=f;if(!n.isMounted)if(o)I=b||u,j=S||c,O=T||f;else return;let W=!1;const re=$[So]=X=>{W||(W=!0,X?C(O,[$]):C(j,[$]),P.delayedLeave&&P.delayedLeave(),$[So]=void 0)};I?E(I,[$,re]):re()},leave($,I){const j=String(e.key);if($[So]&&$[So](!0),n.isUnmounting)return I();C(d,[$]);let O=!1;const W=$[An]=re=>{O||(O=!0,I(),re?C(m,[$]):C(v,[$]),$[An]=void 0,D[j]===e&&delete D[j])};D[j]=e,h?E(h,[$,W]):W()},clone($){const I=js($,t,n,r,s);return s&&s(I),I}};return P}function ci(e){if(ro(e))return e=Hn(e),e.children=null,e}function cc(e){if(!ro(e))return e;const{shapeFlag:t,children:n}=e;if(n){if(t&16)return n[0];if(t&32&&ce(n.default))return n.default()}}function Ur(e,t){e.shapeFlag&6&&e.component?Ur(e.component.subTree,t):e.shapeFlag&128?(e.ssContent.transition=t.clone(e.ssContent),e.ssFallback.transition=t.clone(e.ssFallback)):e.transition=t}function Kl(e,t=!1,n){let r=[],s=0;for(let o=0;o1)for(let o=0;o!!e.type.__asyncLoader;/*! #__NO_SIDE_EFFECTS__ */function or(e){ce(e)&&(e={loader:e});const{loader:t,loadingComponent:n,errorComponent:r,delay:s=200,timeout:o,suspensible:a=!0,onError:i}=e;let l=null,u,c=0;const f=()=>(c++,l=null,d()),d=()=>{let h;return l||(h=l=t().catch(v=>{if(v=v instanceof Error?v:new Error(String(v)),i)return new Promise((m,p)=>{i(v,()=>m(f()),()=>p(v),c+1)});throw v}).then(v=>h!==l&&l?l:(v&&(v.__esModule||v[Symbol.toStringTag]==="Module")&&(v=v.default),u=v,v)))};return Ze({name:"AsyncComponentWrapper",__asyncLoader:d,get __asyncResolved(){return u},setup(){const h=Ge;if(u)return()=>fi(u,h);const v=S=>{l=null,rs(S,h,13,!r)};if(a&&h.suspense||io)return d().then(S=>()=>fi(S,h)).catch(S=>(v(S),()=>r?L(r,{error:S}):null));const m=oe(!1),p=oe(),b=oe(!!s);return s&&setTimeout(()=>{b.value=!1},s),o!=null&&setTimeout(()=>{if(!m.value&&!p.value){const S=new Error(`Async component timed out after ${o}ms.`);v(S),p.value=S}},o),d().then(()=>{m.value=!0,h.parent&&ro(h.parent.vnode)&&(h.parent.effect.dirty=!0,Oa(h.parent.update))}).catch(S=>{v(S),p.value=S}),()=>{if(m.value&&u)return fi(u,h);if(p.value&&r)return L(r,{error:p.value});if(n&&!b.value)return L(n)}}})}function fi(e,t){const{ref:n,props:r,children:s,ce:o}=t.vnode,a=L(e,r,s);return a.ref=n,a.ce=o,delete t.vnode.ce,a}const ro=e=>e.type.__isKeepAlive;function Hh(e,t){Vh(e,"a",t)}function jh(e,t){Vh(e,"da",t)}function Vh(e,t,n=Ge){const r=e.__wdc||(e.__wdc=()=>{let s=n;for(;s;){if(s.isDeactivated)return;s=s.parent}return e()});if(xa(t,r,n),n){let s=n.parent;for(;s&&s.parent;)ro(s.parent.vnode)&&Py(r,t,n,s),s=s.parent}}function Py(e,t,n,r){const s=xa(t,e,r,!0);ss(()=>{kl(r[t],s)},n)}function xa(e,t,n=Ge,r=!1){if(n){const s=n[e]||(n[e]=[]),o=t.__weh||(t.__weh=(...a)=>{Wn();const i=vr(n),l=Nt(t,n,e,a);return i(),Un(),l});return r?s.unshift(o):s.push(o),o}}const Cn=e=>(t,n=Ge)=>{(!io||e==="sp")&&xa(e,(...r)=>t(...r),n)},Ay=Cn("bm"),Gt=Cn("m"),Iy=Cn("bu"),Gl=Cn("u"),yr=Cn("bum"),ss=Cn("um"),Ly=Cn("sp"),Ry=Cn("rtg"),Ny=Cn("rtc");function ka(e,t=Ge){xa("ec",e,t)}const ql="components",Fy="directives";function vn(e,t){return Zl(ql,e,!0,t)||e}const Wh=Symbol.for("v-ndc");function Pa(e){return Ve(e)?Zl(ql,e,!1)||e:e||Wh}function Yy(e){return Zl(Fy,e)}function Zl(e,t,n=!0,r=!1){const s=qe||Ge;if(s){const o=s.type;if(e===ql){const i=Rb(o,!1);if(i&&(i===t||i===xt(t)||i===Dn(xt(t))))return o}const a=fc(s[e]||o[e],t)||fc(s.appContext[e],t);return!a&&r?o:a}}function fc(e,t){return e&&(e[t]||e[xt(t)]||e[Dn(xt(t))])}function Ft(e,t,n,r){let s;const o=n;if(le(e)||Ve(e)){s=new Array(e.length);for(let a=0,i=e.length;at(a,i,void 0,o));else{const a=Object.keys(e);s=new Array(a.length);for(let i=0,l=a.length;iWs(t)?!(t.type===st||t.type===be&&!Uh(t.children)):!0)?e:null}function By(e,t){const n={};for(const r in e)n[/[A-Z]/.test(r)?`on:${r}`:Io(r)]=e[r];return n}const ji=e=>e?vv(e)?La(e):ji(e.parent):null,Ps=Ke(Object.create(null),{$:e=>e,$el:e=>e.vnode.el,$data:e=>e.data,$props:e=>e.props,$attrs:e=>e.attrs,$slots:e=>e.slots,$refs:e=>e.refs,$parent:e=>ji(e.parent),$root:e=>ji(e.root),$emit:e=>e.emit,$options:e=>Jl(e),$forceUpdate:e=>e.f||(e.f=()=>{e.effect.dirty=!0,Oa(e.update)}),$nextTick:e=>e.n||(e.n=Ot.bind(e.proxy)),$watch:e=>hb.bind(e)}),di=(e,t)=>e!==Me&&!e.__isScriptSetup&&De(e,t),Hy={get({_:e},t){if(t==="__v_skip")return!0;const{ctx:n,setupState:r,data:s,props:o,accessCache:a,type:i,appContext:l}=e;let u;if(t[0]!=="$"){const h=a[t];if(h!==void 0)switch(h){case 1:return r[t];case 2:return s[t];case 4:return n[t];case 3:return o[t]}else{if(di(r,t))return a[t]=1,r[t];if(s!==Me&&De(s,t))return a[t]=2,s[t];if((u=e.propsOptions[0])&&De(u,t))return a[t]=3,o[t];if(n!==Me&&De(n,t))return a[t]=4,n[t];Vi&&(a[t]=0)}}const c=Ps[t];let f,d;if(c)return t==="$attrs"&&Ct(e.attrs,"get",""),c(e);if((f=i.__cssModules)&&(f=f[t]))return f;if(n!==Me&&De(n,t))return a[t]=4,n[t];if(d=l.config.globalProperties,De(d,t))return d[t]},set({_:e},t,n){const{data:r,setupState:s,ctx:o}=e;return di(s,t)?(s[t]=n,!0):r!==Me&&De(r,t)?(r[t]=n,!0):De(e.props,t)||t[0]==="$"&&t.slice(1)in e?!1:(o[t]=n,!0)},has({_:{data:e,setupState:t,accessCache:n,ctx:r,appContext:s,propsOptions:o}},a){let i;return!!n[a]||e!==Me&&De(e,a)||di(t,a)||(i=o[0])&&De(i,a)||De(r,a)||De(Ps,a)||De(s.config.globalProperties,a)},defineProperty(e,t,n){return n.get!=null?e._.accessCache[t]=0:De(n,"value")&&this.set(e,t,n.value,null),Reflect.defineProperty(e,t,n)}};function Zo(e){return le(e)?e.reduce((t,n)=>(t[n]=null,t),{}):e}function DY(e,t){return!e||!t?e||t:le(e)&&le(t)?e.concat(t):Ke({},Zo(e),Zo(t))}function hi(e){const t=os();let n=e();return Zi(),Pl(n)&&(n=n.catch(r=>{throw vr(t),r})),[n,()=>vr(t)]}let Vi=!0;function jy(e){const t=Jl(e),n=e.proxy,r=e.ctx;Vi=!1,t.beforeCreate&&dc(t.beforeCreate,e,"bc");const{data:s,computed:o,methods:a,watch:i,provide:l,inject:u,created:c,beforeMount:f,mounted:d,beforeUpdate:h,updated:v,activated:m,deactivated:p,beforeDestroy:b,beforeUnmount:S,destroyed:T,unmounted:M,render:D,renderTracked:C,renderTriggered:E,errorCaptured:P,serverPrefetch:$,expose:I,inheritAttrs:j,components:O,directives:W,filters:re}=t;if(u&&Vy(u,r,null),a)for(const J in a){const ue=a[J];ce(ue)&&(r[J]=ue.bind(n))}if(s){const J=s.call(n,n);Ie(J)&&(e.data=je(J))}if(Vi=!0,o)for(const J in o){const ue=o[J],we=ce(ue)?ue.bind(n,n):ce(ue.get)?ue.get.bind(n,n):Lt,V=!ce(ue)&&ce(ue.set)?ue.set.bind(n):Lt,fe=w({get:we,set:V});Object.defineProperty(r,J,{enumerable:!0,configurable:!0,get:()=>fe.value,set:Q=>fe.value=Q})}if(i)for(const J in i)zh(i[J],r,n,J);if(l){const J=ce(l)?l.call(n):l;Reflect.ownKeys(J).forEach(ue=>{Pt(ue,J[ue])})}c&&dc(c,e,"c");function ee(J,ue){le(ue)?ue.forEach(we=>J(we.bind(n))):ue&&J(ue.bind(n))}if(ee(Ay,f),ee(Gt,d),ee(Iy,h),ee(Gl,v),ee(Hh,m),ee(jh,p),ee(ka,P),ee(Ny,C),ee(Ry,E),ee(yr,S),ee(ss,M),ee(Ly,$),le(I))if(I.length){const J=e.exposed||(e.exposed={});I.forEach(ue=>{Object.defineProperty(J,ue,{get:()=>n[ue],set:we=>n[ue]=we})})}else e.exposed||(e.exposed={});D&&e.render===Lt&&(e.render=D),j!=null&&(e.inheritAttrs=j),O&&(e.components=O),W&&(e.directives=W)}function Vy(e,t,n=Lt){le(e)&&(e=Wi(e));for(const r in e){const s=e[r];let o;Ie(s)?"default"in s?o=Pe(s.from||r,s.default,!0):o=Pe(s.from||r):o=Pe(s),Se(o)?Object.defineProperty(t,r,{enumerable:!0,configurable:!0,get:()=>o.value,set:a=>o.value=a}):t[r]=o}}function dc(e,t,n){Nt(le(e)?e.map(r=>r.bind(t.proxy)):e.bind(t.proxy),t,n)}function zh(e,t,n,r){const s=r.includes(".")?iv(n,r):()=>n[r];if(Ve(e)){const o=t[e];ce(o)&&Te(s,o)}else if(ce(e))Te(s,e.bind(n));else if(Ie(e))if(le(e))e.forEach(o=>zh(o,t,n,r));else{const o=ce(e.handler)?e.handler.bind(n):t[e.handler];ce(o)&&Te(s,o,e)}}function Jl(e){const t=e.type,{mixins:n,extends:r}=t,{mixins:s,optionsCache:o,config:{optionMergeStrategies:a}}=e.appContext,i=o.get(t);let l;return i?l=i:!s.length&&!n&&!r?l=t:(l={},s.length&&s.forEach(u=>Jo(l,u,a,!0)),Jo(l,t,a)),Ie(t)&&o.set(t,l),l}function Jo(e,t,n,r=!1){const{mixins:s,extends:o}=t;o&&Jo(e,o,n,!0),s&&s.forEach(a=>Jo(e,a,n,!0));for(const a in t)if(!(r&&a==="expose")){const i=Wy[a]||n&&n[a];e[a]=i?i(e[a],t[a]):t[a]}return e}const Wy={data:hc,props:vc,emits:vc,methods:$s,computed:$s,beforeCreate:dt,created:dt,beforeMount:dt,mounted:dt,beforeUpdate:dt,updated:dt,beforeDestroy:dt,beforeUnmount:dt,destroyed:dt,unmounted:dt,activated:dt,deactivated:dt,errorCaptured:dt,serverPrefetch:dt,components:$s,directives:$s,watch:zy,provide:hc,inject:Uy};function hc(e,t){return t?e?function(){return Ke(ce(e)?e.call(this,this):e,ce(t)?t.call(this,this):t)}:t:e}function Uy(e,t){return $s(Wi(e),Wi(t))}function Wi(e){if(le(e)){const t={};for(let n=0;n1)return n&&ce(t)?t.call(r&&r.proxy):t}}function qy(){return!!(Ge||qe||Fr)}const Gh={},qh=()=>Object.create(Gh),Zh=e=>Object.getPrototypeOf(e)===Gh;function Zy(e,t,n,r=!1){const s={},o=qh();e.propsDefaults=Object.create(null),Jh(e,t,s,o);for(const a in e.propsOptions[0])a in s||(s[a]=void 0);n?e.props=r?s:py(s):e.type.props?e.props=s:e.props=o,e.attrs=o}function Jy(e,t,n,r){const{props:s,attrs:o,vnode:{patchFlag:a}}=e,i=ge(s),[l]=e.propsOptions;let u=!1;if((r||a>0)&&!(a&16)){if(a&8){const c=e.vnode.dynamicProps;for(let f=0;f{l=!0;const[d,h]=Xh(f,t,!0);Ke(a,d),h&&i.push(...h)};!n&&t.mixins.length&&t.mixins.forEach(c),e.extends&&c(e.extends),e.mixins&&e.mixins.forEach(c)}if(!o&&!l)return Ie(e)&&r.set(e,Ir),Ir;if(le(o))for(let c=0;ce[0]==="_"||e==="$stable",Xl=e=>le(e)?e.map(Wt):[Wt(e)],Qy=(e,t,n)=>{if(t._n)return t;const r=Ee((...s)=>Xl(t(...s)),n);return r._c=!1,r},ev=(e,t,n)=>{const r=e._ctx;for(const s in e){if(Qh(s))continue;const o=e[s];if(ce(o))t[s]=Qy(s,o,r);else if(o!=null){const a=Xl(o);t[s]=()=>a}}},tv=(e,t)=>{const n=Xl(t);e.slots.default=()=>n},nv=(e,t,n)=>{for(const r in t)(n||r!=="_")&&(e[r]=t[r])},eb=(e,t,n)=>{const r=e.slots=qh();if(e.vnode.shapeFlag&32){const s=t._;s?(nv(r,t,n),n&&uh(r,"_",s,!0)):ev(t,r)}else t&&tv(e,t)},tb=(e,t,n)=>{const{vnode:r,slots:s}=e;let o=!0,a=Me;if(r.shapeFlag&32){const i=t._;i?n&&i===1?o=!1:nv(s,t,n):(o=!t.$stable,ev(t,s)),a=t}else t&&(tv(e,t),a={default:1});if(o)for(const i in s)!Qh(i)&&a[i]==null&&delete s[i]};function zi(e,t,n,r,s=!1){if(le(e)){e.forEach((d,h)=>zi(d,t&&(le(t)?t[h]:t),n,r,s));return}if(ks(r)&&!s)return;const o=r.shapeFlag&4?La(r.component):r.el,a=s?null:o,{i,r:l}=e,u=t&&t.r,c=i.refs===Me?i.refs={}:i.refs,f=i.setupState;if(u!=null&&u!==l&&(Ve(u)?(c[u]=null,De(f,u)&&(f[u]=null)):Se(u)&&(u.value=null)),ce(l))Bn(l,i,12,[a,c]);else{const d=Ve(l),h=Se(l);if(d||h){const v=()=>{if(e.f){const m=d?De(f,l)?f[l]:c[l]:l.value;s?le(m)&&kl(m,o):le(m)?m.includes(o)||m.push(o):d?(c[l]=[o],De(f,l)&&(f[l]=c[l])):(l.value=[o],e.k&&(c[e.k]=l.value))}else d?(c[l]=a,De(f,l)&&(f[l]=a)):h&&(l.value=a,e.k&&(c[e.k]=a))};a?(v.id=-1,gt(v,n)):v()}}}const rv=Symbol("_vte"),nb=e=>e.__isTeleport,As=e=>e&&(e.disabled||e.disabled===""),pc=e=>typeof SVGElement<"u"&&e instanceof SVGElement,gc=e=>typeof MathMLElement=="function"&&e instanceof MathMLElement,Ki=(e,t)=>{const n=e&&e.to;return Ve(n)?t?t(n):null:n},rb={name:"Teleport",__isTeleport:!0,process(e,t,n,r,s,o,a,i,l,u){const{mc:c,pc:f,pbc:d,o:{insert:h,querySelector:v,createText:m,createComment:p}}=u,b=As(t.props);let{shapeFlag:S,children:T,dynamicChildren:M}=t;if(e==null){const D=t.el=m(""),C=t.anchor=m("");h(D,n,r),h(C,n,r);const E=t.target=Ki(t.props,v),P=ov(E,t,m,h);E&&(a==="svg"||pc(E)?a="svg":(a==="mathml"||gc(E))&&(a="mathml"));const $=(I,j)=>{S&16&&c(T,I,j,s,o,a,i,l)};b?$(n,C):E&&$(E,P)}else{t.el=e.el,t.targetStart=e.targetStart;const D=t.anchor=e.anchor,C=t.target=e.target,E=t.targetAnchor=e.targetAnchor,P=As(e.props),$=P?n:C,I=P?D:E;if(a==="svg"||pc(C)?a="svg":(a==="mathml"||gc(C))&&(a="mathml"),M?(d(e.dynamicChildren,M,$,s,o,a,i),Ql(e,t,!0)):l||f(e,t,$,I,s,o,a,i,!1),b)P?t.props&&e.props&&t.props.to!==e.props.to&&(t.props.to=e.props.to):$o(t,n,D,u,1);else if((t.props&&t.props.to)!==(e.props&&e.props.to)){const j=t.target=Ki(t.props,v);j&&$o(t,j,null,u,0)}else P&&$o(t,C,E,u,1)}sv(t)},remove(e,t,n,{um:r,o:{remove:s}},o){const{shapeFlag:a,children:i,anchor:l,targetStart:u,targetAnchor:c,target:f,props:d}=e;if(f&&(s(u),s(c)),o&&s(l),a&16){const h=o||!As(d);for(let v=0;v{if(g===_)return;g&&!tn(g,_)&&(Y=ye(g),Q(g,R,H,!0),g=null),_.patchFlag===-2&&(z=!1,_.dynamicChildren=null);const{type:B,ref:q,shapeFlag:ne}=_;switch(B){case ao:p(g,_,x,Y);break;case st:b(g,_,x,Y);break;case Lo:g==null&&S(_,x,Y,K);break;case be:O(g,_,x,Y,R,H,K,U,z);break;default:ne&1?D(g,_,x,Y,R,H,K,U,z):ne&6?W(g,_,x,Y,R,H,K,U,z):(ne&64||ne&128)&&B.process(g,_,x,Y,R,H,K,U,z,lt)}q!=null&&R&&zi(q,g&&g.ref,H,_||g,!_)},p=(g,_,x,Y)=>{if(g==null)r(_.el=i(_.children),x,Y);else{const R=_.el=g.el;_.children!==g.children&&u(R,_.children)}},b=(g,_,x,Y)=>{g==null?r(_.el=l(_.children||""),x,Y):_.el=g.el},S=(g,_,x,Y)=>{[g.el,g.anchor]=v(g.children,_,x,Y,g.el,g.anchor)},T=({el:g,anchor:_},x,Y)=>{let R;for(;g&&g!==_;)R=d(g),r(g,x,Y),g=R;r(_,x,Y)},M=({el:g,anchor:_})=>{let x;for(;g&&g!==_;)x=d(g),s(g),g=x;s(_)},D=(g,_,x,Y,R,H,K,U,z)=>{_.type==="svg"?K="svg":_.type==="math"&&(K="mathml"),g==null?C(_,x,Y,R,H,K,U,z):$(g,_,R,H,K,U,z)},C=(g,_,x,Y,R,H,K,U)=>{let z,B;const{props:q,shapeFlag:ne,transition:te,dirs:ie}=g;if(z=g.el=a(g.type,H,q&&q.is,q),ne&8?c(z,g.children):ne&16&&P(g.children,z,null,Y,R,vi(g,H),K,U),ie&&Qn(g,null,Y,"created"),E(z,g,g.scopeId,K,Y),q){for(const Ce in q)Ce!=="value"&&!Ms(Ce)&&o(z,Ce,null,q[Ce],H,Y);"value"in q&&o(z,"value",null,q.value,H),(B=q.onVnodeBeforeMount)&&Qt(B,Y,g)}ie&&Qn(g,null,Y,"beforeMount");const de=ib(R,te);de&&te.beforeEnter(z),r(z,_,x),((B=q&&q.onVnodeMounted)||de||ie)&>(()=>{B&&Qt(B,Y,g),de&&te.enter(z),ie&&Qn(g,null,Y,"mounted")},R)},E=(g,_,x,Y,R)=>{if(x&&h(g,x),Y)for(let H=0;H{for(let B=z;B{const U=_.el=g.el;let{patchFlag:z,dynamicChildren:B,dirs:q}=_;z|=g.patchFlag&16;const ne=g.props||Me,te=_.props||Me;let ie;if(x&&er(x,!1),(ie=te.onVnodeBeforeUpdate)&&Qt(ie,x,_,g),q&&Qn(_,g,x,"beforeUpdate"),x&&er(x,!0),(ne.innerHTML&&te.innerHTML==null||ne.textContent&&te.textContent==null)&&c(U,""),B?I(g.dynamicChildren,B,U,x,Y,vi(_,R),H):K||ue(g,_,U,null,x,Y,vi(_,R),H,!1),z>0){if(z&16)j(U,ne,te,x,R);else if(z&2&&ne.class!==te.class&&o(U,"class",null,te.class,R),z&4&&o(U,"style",ne.style,te.style,R),z&8){const de=_.dynamicProps;for(let Ce=0;Ce{ie&&Qt(ie,x,_,g),q&&Qn(_,g,x,"updated")},Y)},I=(g,_,x,Y,R,H,K)=>{for(let U=0;U<_.length;U++){const z=g[U],B=_[U],q=z.el&&(z.type===be||!tn(z,B)||z.shapeFlag&70)?f(z.el):x;m(z,B,q,null,Y,R,H,K,!0)}},j=(g,_,x,Y,R)=>{if(_!==x){if(_!==Me)for(const H in _)!Ms(H)&&!(H in x)&&o(g,H,_[H],null,R,Y);for(const H in x){if(Ms(H))continue;const K=x[H],U=_[H];K!==U&&H!=="value"&&o(g,H,U,K,R,Y)}"value"in x&&o(g,"value",_.value,x.value,R)}},O=(g,_,x,Y,R,H,K,U,z)=>{const B=_.el=g?g.el:i(""),q=_.anchor=g?g.anchor:i("");let{patchFlag:ne,dynamicChildren:te,slotScopeIds:ie}=_;ie&&(U=U?U.concat(ie):ie),g==null?(r(B,x,Y),r(q,x,Y),P(_.children||[],x,q,R,H,K,U,z)):ne>0&&ne&64&&te&&g.dynamicChildren?(I(g.dynamicChildren,te,x,R,H,K,U),(_.key!=null||R&&_===R.subTree)&&Ql(g,_,!0)):ue(g,_,x,q,R,H,K,U,z)},W=(g,_,x,Y,R,H,K,U,z)=>{_.slotScopeIds=U,g==null?_.shapeFlag&512?R.ctx.activate(_,x,Y,K,z):re(_,x,Y,R,H,K,z):X(g,_,z)},re=(g,_,x,Y,R,H,K)=>{const U=g.component=kb(g,Y,R);if(ro(g)&&(U.ctx.renderer=lt),Pb(U,!1,K),U.asyncDep){if(R&&R.registerDep(U,ee,K),!g.el){const z=U.subTree=L(st);b(null,z,_,x)}}else ee(U,g,_,x,R,H,K)},X=(g,_,x)=>{const Y=_.component=g.component;if(bb(g,_,x))if(Y.asyncDep&&!Y.asyncResolved){J(Y,_,x);return}else Y.next=_,Ty(Y.update),Y.effect.dirty=!0,Y.update();else _.el=g.el,Y.vnode=_},ee=(g,_,x,Y,R,H,K)=>{const U=()=>{if(g.isMounted){let{next:q,bu:ne,u:te,parent:ie,vnode:de}=g;{const Vt=av(g);if(Vt){q&&(q.el=de.el,J(g,q,K)),Vt.asyncDep.then(()=>{g.isUnmounted||U()});return}}let Ce=q,_e;er(g,!1),q?(q.el=de.el,J(g,q,K)):q=de,ne&&li(ne),(_e=q.props&&q.props.onVnodeBeforeUpdate)&&Qt(_e,ie,q,de),er(g,!0);const Be=mi(g),ct=g.subTree;g.subTree=Be,m(ct,Be,f(ct.el),ye(ct),g,R,H),q.el=Be.el,Ce===null&&eu(g,Be.el),te&>(te,R),(_e=q.props&&q.props.onVnodeUpdated)&>(()=>Qt(_e,ie,q,de),R)}else{let q;const{el:ne,props:te}=_,{bm:ie,m:de,parent:Ce}=g,_e=ks(_);if(er(g,!1),ie&&li(ie),!_e&&(q=te&&te.onVnodeBeforeMount)&&Qt(q,Ce,_),er(g,!0),ne&&ut){const Be=()=>{g.subTree=mi(g),ut(ne,g.subTree,g,R,null)};_e?_.type.__asyncLoader().then(()=>!g.isUnmounted&&Be()):Be()}else{const Be=g.subTree=mi(g);m(null,Be,x,Y,g,R,H),_.el=Be.el}if(de&>(de,R),!_e&&(q=te&&te.onVnodeMounted)){const Be=_;gt(()=>Qt(q,Ce,Be),R)}(_.shapeFlag&256||Ce&&ks(Ce.vnode)&&Ce.vnode.shapeFlag&256)&&g.a&>(g.a,R),g.isMounted=!0,_=x=Y=null}},z=g.effect=new Rl(U,Lt,()=>Oa(B),g.scope),B=g.update=()=>{z.dirty&&z.run()};B.i=g,B.id=g.uid,er(g,!0),B()},J=(g,_,x)=>{_.component=g;const Y=g.vnode.props;g.vnode=_,g.next=null,Jy(g,_.props,Y,x),tb(g,_.children,x),Wn(),uc(g),Un()},ue=(g,_,x,Y,R,H,K,U,z=!1)=>{const B=g&&g.children,q=g?g.shapeFlag:0,ne=_.children,{patchFlag:te,shapeFlag:ie}=_;if(te>0){if(te&128){V(B,ne,x,Y,R,H,K,U,z);return}else if(te&256){we(B,ne,x,Y,R,H,K,U,z);return}}ie&8?(q&16&&Re(B,R,H),ne!==B&&c(x,ne)):q&16?ie&16?V(B,ne,x,Y,R,H,K,U,z):Re(B,R,H,!0):(q&8&&c(x,""),ie&16&&P(ne,x,Y,R,H,K,U,z))},we=(g,_,x,Y,R,H,K,U,z)=>{g=g||Ir,_=_||Ir;const B=g.length,q=_.length,ne=Math.min(B,q);let te;for(te=0;teq?Re(g,R,H,!0,!1,ne):P(_,x,Y,R,H,K,U,z,ne)},V=(g,_,x,Y,R,H,K,U,z)=>{let B=0;const q=_.length;let ne=g.length-1,te=q-1;for(;B<=ne&&B<=te;){const ie=g[B],de=_[B]=z?In(_[B]):Wt(_[B]);if(tn(ie,de))m(ie,de,x,null,R,H,K,U,z);else break;B++}for(;B<=ne&&B<=te;){const ie=g[ne],de=_[te]=z?In(_[te]):Wt(_[te]);if(tn(ie,de))m(ie,de,x,null,R,H,K,U,z);else break;ne--,te--}if(B>ne){if(B<=te){const ie=te+1,de=iete)for(;B<=ne;)Q(g[B],R,H,!0),B++;else{const ie=B,de=B,Ce=new Map;for(B=de;B<=te;B++){const Je=_[B]=z?In(_[B]):Wt(_[B]);Je.key!=null&&Ce.set(Je.key,B)}let _e,Be=0;const ct=te-de+1;let Vt=!1,Jn=0;const fn=new Array(ct);for(B=0;B=ct){Q(Je,R,H,!0);continue}let N;if(Je.key!=null)N=Ce.get(Je.key);else for(_e=de;_e<=te;_e++)if(fn[_e-de]===0&&tn(Je,_[_e])){N=_e;break}N===void 0?Q(Je,R,H,!0):(fn[N-de]=B+1,N>=Jn?Jn=N:Vt=!0,m(Je,_[N],x,null,R,H,K,U,z),Be++)}const Xn=Vt?lb(fn):Ir;for(_e=Xn.length-1,B=ct-1;B>=0;B--){const Je=de+B,N=_[Je],y=Je+1{const{el:H,type:K,transition:U,children:z,shapeFlag:B}=g;if(B&6){fe(g.component.subTree,_,x,Y);return}if(B&128){g.suspense.move(_,x,Y);return}if(B&64){K.move(g,_,x,lt);return}if(K===be){r(H,_,x);for(let ne=0;neU.enter(H),R);else{const{leave:ne,delayLeave:te,afterLeave:ie}=U,de=()=>r(H,_,x),Ce=()=>{ne(H,()=>{de(),ie&&ie()})};te?te(H,de,Ce):Ce()}else r(H,_,x)},Q=(g,_,x,Y=!1,R=!1)=>{const{type:H,props:K,ref:U,children:z,dynamicChildren:B,shapeFlag:q,patchFlag:ne,dirs:te,cacheIndex:ie}=g;if(ne===-2&&(R=!1),U!=null&&zi(U,null,x,g,!0),ie!=null&&(_.renderCache[ie]=void 0),q&256){_.ctx.deactivate(g);return}const de=q&1&&te,Ce=!ks(g);let _e;if(Ce&&(_e=K&&K.onVnodeBeforeUnmount)&&Qt(_e,_,g),q&6)Ye(g.component,x,Y);else{if(q&128){g.suspense.unmount(x,Y);return}de&&Qn(g,null,_,"beforeUnmount"),q&64?g.type.remove(g,_,x,lt,Y):B&&!B.hasOnce&&(H!==be||ne>0&&ne&64)?Re(B,_,x,!1,!0):(H===be&&ne&384||!R&&q&16)&&Re(z,_,x),Y&&Le(g)}(Ce&&(_e=K&&K.onVnodeUnmounted)||de)&>(()=>{_e&&Qt(_e,_,g),de&&Qn(g,null,_,"unmounted")},x)},Le=g=>{const{type:_,el:x,anchor:Y,transition:R}=g;if(_===be){pe(x,Y);return}if(_===Lo){M(g);return}const H=()=>{s(x),R&&!R.persisted&&R.afterLeave&&R.afterLeave()};if(g.shapeFlag&1&&R&&!R.persisted){const{leave:K,delayLeave:U}=R,z=()=>K(x,H);U?U(g.el,H,z):z()}else H()},pe=(g,_)=>{let x;for(;g!==_;)x=d(g),s(g),g=x;s(_)},Ye=(g,_,x)=>{const{bum:Y,scope:R,update:H,subTree:K,um:U,m:z,a:B}=g;yc(z),yc(B),Y&&li(Y),R.stop(),H&&(H.active=!1,Q(K,g,_,x)),U&>(U,_),gt(()=>{g.isUnmounted=!0},_),_&&_.pendingBranch&&!_.isUnmounted&&g.asyncDep&&!g.asyncResolved&&g.suspenseId===_.pendingId&&(_.deps--,_.deps===0&&_.resolve())},Re=(g,_,x,Y=!1,R=!1,H=0)=>{for(let K=H;K{if(g.shapeFlag&6)return ye(g.component.subTree);if(g.shapeFlag&128)return g.suspense.next();const _=d(g.anchor||g.el),x=_&&_[rv];return x?d(x):_};let ze=!1;const tt=(g,_,x)=>{g==null?_._vnode&&Q(_._vnode,null,null,!0):m(_._vnode||null,g,_,null,null,null,x),ze||(ze=!0,uc(),Lh(),ze=!1),_._vnode=g},lt={p:m,um:Q,m:fe,r:Le,mt:re,mc:P,pc:ue,pbc:I,n:ye,o:e};let mt,ut;return{render:tt,hydrate:mt,createApp:Gy(tt,mt)}}function vi({type:e,props:t},n){return n==="svg"&&e==="foreignObject"||n==="mathml"&&e==="annotation-xml"&&t&&t.encoding&&t.encoding.includes("html")?void 0:n}function er({effect:e,update:t},n){e.allowRecurse=t.allowRecurse=n}function ib(e,t){return(!e||e&&!e.pendingBranch)&&t&&!t.persisted}function Ql(e,t,n=!1){const r=e.children,s=t.children;if(le(r)&&le(s))for(let o=0;o>1,e[n[i]]0&&(t[r]=n[o-1]),n[o]=r)}}for(o=n.length,a=n[o-1];o-- >0;)n[o]=a,a=t[a];return n}function av(e){const t=e.subTree.component;if(t)return t.asyncDep&&!t.asyncResolved?t:av(t)}function yc(e){if(e)for(let t=0;tPe(ub);function zn(e,t){return oo(e,null,t)}function fb(e,t){return oo(e,null,{flush:"post"})}function db(e,t){return oo(e,null,{flush:"sync"})}const To={};function Te(e,t,n){return oo(e,t,n)}function oo(e,t,{immediate:n,deep:r,flush:s,once:o,onTrack:a,onTrigger:i}=Me){if(t&&o){const C=t;t=(...E)=>{C(...E),D()}}const l=Ge,u=C=>r===!0?C:Ln(C,r===!1?1:void 0);let c,f=!1,d=!1;if(Se(e)?(c=()=>e.value,f=Wr(e)):Yn(e)?(c=()=>u(e),f=!0):le(e)?(d=!0,f=e.some(C=>Yn(C)||Wr(C)),c=()=>e.map(C=>{if(Se(C))return C.value;if(Yn(C))return u(C);if(ce(C))return Bn(C,l,2)})):ce(e)?t?c=()=>Bn(e,l,2):c=()=>(h&&h(),Nt(e,l,3,[v])):c=Lt,t&&r){const C=c;c=()=>Ln(C())}let h,v=C=>{h=T.onStop=()=>{Bn(C,l,4),h=T.onStop=void 0}},m;if(io)if(v=Lt,t?n&&Nt(t,l,3,[c(),d?[]:void 0,v]):c(),s==="sync"){const C=cb();m=C.__watcherHandles||(C.__watcherHandles=[])}else return Lt;let p=d?new Array(e.length).fill(To):To;const b=()=>{if(!(!T.active||!T.dirty))if(t){const C=T.run();(r||f||(d?C.some((E,P)=>yt(E,p[P])):yt(C,p)))&&(h&&h(),Nt(t,l,3,[C,p===To?void 0:d&&p[0]===To?[]:p,v]),p=C)}else T.run()};b.allowRecurse=!!t;let S;s==="sync"?S=b:s==="post"?S=()=>gt(b,l&&l.suspense):(b.pre=!0,l&&(b.id=l.uid),S=()=>Oa(b));const T=new Rl(c,Lt,S),M=ph(),D=()=>{T.stop(),M&&kl(M.effects,T)};return t?n?b():p=T.run():s==="post"?gt(T.run.bind(T),l&&l.suspense):T.run(),m&&m.push(D),D}function hb(e,t,n){const r=this.proxy,s=Ve(e)?e.includes(".")?iv(r,e):()=>r[e]:e.bind(r,r);let o;ce(t)?o=t:(o=t.handler,n=t);const a=vr(this),i=oo(s,o.bind(r),n);return a(),i}function iv(e,t){const n=t.split(".");return()=>{let r=e;for(let s=0;s{Ln(r,t,n)});else if(lh(e)){for(const r in e)Ln(e[r],t,n);for(const r of Object.getOwnPropertySymbols(e))Object.prototype.propertyIsEnumerable.call(e,r)&&Ln(e[r],t,n)}return e}function vb(e,t,n=Me){const r=os(),s=xt(t),o=_n(t),a=lv(e,t),i=_y((l,u)=>{let c,f=Me,d;return db(()=>{const h=e[t];yt(c,h)&&(c=h,u())}),{get(){return l(),n.get?n.get(c):c},set(h){if(!yt(h,c)&&!(f!==Me&&yt(h,f)))return;const v=r.vnode.props;v&&(t in v||s in v||o in v)&&(`onUpdate:${t}`in v||`onUpdate:${s}`in v||`onUpdate:${o}`in v)||(c=h,u());const m=n.set?n.set(h):h;r.emit(`update:${t}`,m),yt(h,m)&&yt(h,f)&&!yt(m,d)&&u(),f=h,d=m}}});return i[Symbol.iterator]=()=>{let l=0;return{next(){return l<2?{value:l++?a||Me:i,done:!1}:{done:!0}}}},i}const lv=(e,t)=>t==="modelValue"||t==="model-value"?e.modelModifiers:e[`${t}Modifiers`]||e[`${xt(t)}Modifiers`]||e[`${_n(t)}Modifiers`];function mb(e,t,...n){if(e.isUnmounted)return;const r=e.vnode.props||Me;let s=n;const o=t.startsWith("update:"),a=o&&lv(r,t.slice(7));a&&(a.trim&&(s=n.map(c=>Ve(c)?c.trim():c)),a.number&&(s=n.map(jg)));let i,l=r[i=Io(t)]||r[i=Io(xt(t))];!l&&o&&(l=r[i=Io(_n(t))]),l&&Nt(l,e,6,s);const u=r[i+"Once"];if(u){if(!e.emitted)e.emitted={};else if(e.emitted[i])return;e.emitted[i]=!0,Nt(u,e,6,s)}}function uv(e,t,n=!1){const r=t.emitsCache,s=r.get(e);if(s!==void 0)return s;const o=e.emits;let a={},i=!1;if(!ce(e)){const l=u=>{const c=uv(u,t,!0);c&&(i=!0,Ke(a,c))};!n&&t.mixins.length&&t.mixins.forEach(l),e.extends&&l(e.extends),e.mixins&&e.mixins.forEach(l)}return!o&&!i?(Ie(e)&&r.set(e,null),null):(le(o)?o.forEach(l=>a[l]=null):Ke(a,o),Ie(e)&&r.set(e,a),a)}function Aa(e,t){return!e||!Ca(t)?!1:(t=t.slice(2).replace(/Once$/,""),De(e,t[0].toLowerCase()+t.slice(1))||De(e,_n(t))||De(e,t))}function mi(e){const{type:t,vnode:n,proxy:r,withProxy:s,propsOptions:[o],slots:a,attrs:i,emit:l,render:u,renderCache:c,props:f,data:d,setupState:h,ctx:v,inheritAttrs:m}=e,p=qo(e);let b,S;try{if(n.shapeFlag&4){const M=s||r,D=M;b=Wt(u.call(D,M,c,f,h,d,v)),S=i}else{const M=t;b=Wt(M.length>1?M(f,{attrs:i,slots:a,emit:l}):M(f,null)),S=t.props?i:gb(i)}}catch(M){Is.length=0,rs(M,e,1),b=L(st)}let T=b;if(S&&m!==!1){const M=Object.keys(S),{shapeFlag:D}=T;M.length&&D&7&&(o&&M.some(xl)&&(S=yb(S,o)),T=Hn(T,S,!1,!0))}return n.dirs&&(T=Hn(T,null,!1,!0),T.dirs=T.dirs?T.dirs.concat(n.dirs):n.dirs),n.transition&&(T.transition=n.transition),b=T,qo(p),b}function pb(e,t=!0){let n;for(let r=0;r{let t;for(const n in e)(n==="class"||n==="style"||Ca(n))&&((t||(t={}))[n]=e[n]);return t},yb=(e,t)=>{const n={};for(const r in e)(!xl(r)||!(r.slice(9)in t))&&(n[r]=e[r]);return n};function bb(e,t,n){const{props:r,children:s,component:o}=e,{props:a,children:i,patchFlag:l}=t,u=o.emitsOptions;if(t.dirs||t.transition)return!0;if(n&&l>=0){if(l&1024)return!0;if(l&16)return r?bc(r,a,u):!!a;if(l&8){const c=t.dynamicProps;for(let f=0;fe.__isSuspense;let Gi=0;const _b={name:"Suspense",__isSuspense:!0,process(e,t,n,r,s,o,a,i,l,u){if(e==null)Db(t,n,r,s,o,a,i,l,u);else{if(o&&o.deps>0&&!e.suspense.isInFallback){t.suspense=e.suspense,t.suspense.vnode=t,t.el=e.el;return}Cb(e,t,n,r,s,a,i,l,u)}},hydrate:Sb,normalize:$b},Ia=_b;function Vs(e,t){const n=e.props&&e.props[t];ce(n)&&n()}function Db(e,t,n,r,s,o,a,i,l){const{p:u,o:{createElement:c}}=l,f=c("div"),d=e.suspense=cv(e,s,r,t,f,n,o,a,i,l);u(null,d.pendingBranch=e.ssContent,f,null,r,d,o,a),d.deps>0?(Vs(e,"onPending"),Vs(e,"onFallback"),u(null,e.ssFallback,t,n,r,null,o,a),Yr(d,e.ssFallback)):d.resolve(!1,!0)}function Cb(e,t,n,r,s,o,a,i,{p:l,um:u,o:{createElement:c}}){const f=t.suspense=e.suspense;f.vnode=t,t.el=e.el;const d=t.ssContent,h=t.ssFallback,{activeBranch:v,pendingBranch:m,isInFallback:p,isHydrating:b}=f;if(m)f.pendingBranch=d,tn(d,m)?(l(m,d,f.hiddenContainer,null,s,f,o,a,i),f.deps<=0?f.resolve():p&&(b||(l(v,h,n,r,s,null,o,a,i),Yr(f,h)))):(f.pendingId=Gi++,b?(f.isHydrating=!1,f.activeBranch=m):u(m,s,f),f.deps=0,f.effects.length=0,f.hiddenContainer=c("div"),p?(l(null,d,f.hiddenContainer,null,s,f,o,a,i),f.deps<=0?f.resolve():(l(v,h,n,r,s,null,o,a,i),Yr(f,h))):v&&tn(d,v)?(l(v,d,n,r,s,f,o,a,i),f.resolve(!0)):(l(null,d,f.hiddenContainer,null,s,f,o,a,i),f.deps<=0&&f.resolve()));else if(v&&tn(d,v))l(v,d,n,r,s,f,o,a,i),Yr(f,d);else if(Vs(t,"onPending"),f.pendingBranch=d,d.shapeFlag&512?f.pendingId=d.component.suspenseId:f.pendingId=Gi++,l(null,d,f.hiddenContainer,null,s,f,o,a,i),f.deps<=0)f.resolve();else{const{timeout:S,pendingId:T}=f;S>0?setTimeout(()=>{f.pendingId===T&&f.fallback(h)},S):S===0&&f.fallback(h)}}function cv(e,t,n,r,s,o,a,i,l,u,c=!1){const{p:f,m:d,um:h,n:v,o:{parentNode:m,remove:p}}=u;let b;const S=Eb(e);S&&t&&t.pendingBranch&&(b=t.pendingId,t.deps++);const T=e.props?ch(e.props.timeout):void 0,M=o,D={vnode:e,parent:t,parentComponent:n,namespace:a,container:r,hiddenContainer:s,deps:0,pendingId:Gi++,timeout:typeof T=="number"?T:-1,activeBranch:null,pendingBranch:null,isInFallback:!c,isHydrating:c,isUnmounted:!1,effects:[],resolve(C=!1,E=!1){const{vnode:P,activeBranch:$,pendingBranch:I,pendingId:j,effects:O,parentComponent:W,container:re}=D;let X=!1;D.isHydrating?D.isHydrating=!1:C||(X=$&&I.transition&&I.transition.mode==="out-in",X&&($.transition.afterLeave=()=>{j===D.pendingId&&(d(I,re,o===M?v($):o,0),Hi(O))}),$&&(m($.el)!==D.hiddenContainer&&(o=v($)),h($,W,D,!0)),X||d(I,re,o,0)),Yr(D,I),D.pendingBranch=null,D.isInFallback=!1;let ee=D.parent,J=!1;for(;ee;){if(ee.pendingBranch){ee.effects.push(...O),J=!0;break}ee=ee.parent}!J&&!X&&Hi(O),D.effects=[],S&&t&&t.pendingBranch&&b===t.pendingId&&(t.deps--,t.deps===0&&!E&&t.resolve()),Vs(P,"onResolve")},fallback(C){if(!D.pendingBranch)return;const{vnode:E,activeBranch:P,parentComponent:$,container:I,namespace:j}=D;Vs(E,"onFallback");const O=v(P),W=()=>{D.isInFallback&&(f(null,C,I,O,$,null,j,i,l),Yr(D,C))},re=C.transition&&C.transition.mode==="out-in";re&&(P.transition.afterLeave=W),D.isInFallback=!0,h(P,$,null,!0),re||W()},move(C,E,P){D.activeBranch&&d(D.activeBranch,C,E,P),D.container=C},next(){return D.activeBranch&&v(D.activeBranch)},registerDep(C,E,P){const $=!!D.pendingBranch;$&&D.deps++;const I=C.vnode.el;C.asyncDep.catch(j=>{rs(j,C,0)}).then(j=>{if(C.isUnmounted||D.isUnmounted||D.pendingId!==C.suspenseId)return;C.asyncResolved=!0;const{vnode:O}=C;Ji(C,j,!1),I&&(O.el=I);const W=!I&&C.subTree.el;E(C,O,m(I||C.subTree.el),I?null:v(C.subTree),D,a,P),W&&p(W),eu(C,O.el),$&&--D.deps===0&&D.resolve()})},unmount(C,E){D.isUnmounted=!0,D.activeBranch&&h(D.activeBranch,n,C,E),D.pendingBranch&&h(D.pendingBranch,n,C,E)}};return D}function Sb(e,t,n,r,s,o,a,i,l){const u=t.suspense=cv(t,r,n,e.parentNode,document.createElement("div"),null,s,o,a,i,!0),c=l(e,u.pendingBranch=t.ssContent,n,u,o,a);return u.deps===0&&u.resolve(!1,!0),c}function $b(e){const{shapeFlag:t,children:n}=e,r=t&32;e.ssContent=wc(r?n.default:n),e.ssFallback=r?wc(n.fallback):L(st)}function wc(e){let t;if(ce(e)){const n=zr&&e._c;n&&(e._d=!1,G()),e=e(),n&&(e._d=!0,t=bt,fv())}return le(e)&&(e=pb(e)),e=Wt(e),t&&!e.dynamicChildren&&(e.dynamicChildren=t.filter(n=>n!==e)),e}function Tb(e,t){t&&t.pendingBranch?le(e)?t.effects.push(...e):t.effects.push(e):Hi(e)}function Yr(e,t){e.activeBranch=t;const{vnode:n,parentComponent:r}=e;let s=t.el;for(;!s&&t.component;)t=t.component.subTree,s=t.el;n.el=s,r&&r.subTree===n&&(r.vnode.el=s,eu(r,s))}function Eb(e){const t=e.props&&e.props.suspensible;return t!=null&&t!==!1}const be=Symbol.for("v-fgt"),ao=Symbol.for("v-txt"),st=Symbol.for("v-cmt"),Lo=Symbol.for("v-stc"),Is=[];let bt=null;function G(e=!1){Is.push(bt=e?null:[])}function fv(){Is.pop(),bt=Is[Is.length-1]||null}let zr=1;function _c(e){zr+=e,e<0&&bt&&(bt.hasOnce=!0)}function dv(e){return e.dynamicChildren=zr>0?bt||Ir:null,fv(),zr>0&&bt&&bt.push(e),e}function ae(e,t,n,r,s,o){return dv(me(e,t,n,r,s,o,!0))}function Ae(e,t,n,r,s){return dv(L(e,t,n,r,s,!0))}function Ws(e){return e?e.__v_isVNode===!0:!1}function tn(e,t){return e.type===t.type&&e.key===t.key}const hv=({key:e})=>e??null,Ro=({ref:e,ref_key:t,ref_for:n})=>(typeof e=="number"&&(e=""+e),e!=null?Ve(e)||Se(e)||ce(e)?{i:qe,r:e,k:t,f:!!n}:e:null);function me(e,t=null,n=null,r=0,s=null,o=e===be?0:1,a=!1,i=!1){const l={__v_isVNode:!0,__v_skip:!0,type:e,props:t,key:t&&hv(t),ref:t&&Ro(t),scopeId:Ma,slotScopeIds:null,children:n,component:null,suspense:null,ssContent:null,ssFallback:null,dirs:null,transition:null,el:null,anchor:null,target:null,targetStart:null,targetAnchor:null,staticCount:0,shapeFlag:o,patchFlag:r,dynamicProps:s,dynamicChildren:null,appContext:null,ctx:qe};return i?(tu(l,n),o&128&&e.normalize(l)):n&&(l.shapeFlag|=Ve(n)?8:16),zr>0&&!a&&bt&&(l.patchFlag>0||o&6)&&l.patchFlag!==32&&bt.push(l),l}const L=Ob;function Ob(e,t=null,n=null,r=0,s=null,o=!1){if((!e||e===Wh)&&(e=st),Ws(e)){const i=Hn(e,t,!0);return n&&tu(i,n),zr>0&&!o&&bt&&(i.shapeFlag&6?bt[bt.indexOf(e)]=i:bt.push(i)),i.patchFlag=-2,i}if(Nb(e)&&(e=e.__vccOpts),t){t=Xo(t);let{class:i,style:l}=t;i&&!Ve(i)&&(t.class=ke(i)),Ie(l)&&(Oh(l)&&!le(l)&&(l=Ke({},l)),t.style=pn(l))}const a=Ve(e)?1:wb(e)?128:nb(e)?64:Ie(e)?4:ce(e)?2:0;return me(e,t,n,r,s,a,o,!0)}function Xo(e){return e?Oh(e)||Zh(e)?Ke({},e):e:null}function Hn(e,t,n=!1,r=!1){const{props:s,ref:o,patchFlag:a,children:i,transition:l}=e,u=t?qt(s||{},t):s,c={__v_isVNode:!0,__v_skip:!0,type:e.type,props:u,key:u&&hv(u),ref:t&&t.ref?n&&o?le(o)?o.concat(Ro(t)):[o,Ro(t)]:Ro(t):o,scopeId:e.scopeId,slotScopeIds:e.slotScopeIds,children:i,target:e.target,targetStart:e.targetStart,targetAnchor:e.targetAnchor,staticCount:e.staticCount,shapeFlag:e.shapeFlag,patchFlag:t&&e.type!==be?a===-1?16:a|16:a,dynamicProps:e.dynamicProps,dynamicChildren:e.dynamicChildren,appContext:e.appContext,dirs:e.dirs,transition:l,component:e.component,suspense:e.suspense,ssContent:e.ssContent&&Hn(e.ssContent),ssFallback:e.ssFallback&&Hn(e.ssFallback),el:e.el,anchor:e.anchor,ctx:e.ctx,ce:e.ce};return l&&r&&Ur(c,l.clone(c)),c}function Kr(e=" ",t=0){return L(ao,null,e,t)}function We(e="",t=!1){return t?(G(),Ae(st,null,e)):L(st,null,e)}function Wt(e){return e==null||typeof e=="boolean"?L(st):le(e)?L(be,null,e.slice()):typeof e=="object"?In(e):L(ao,null,String(e))}function In(e){return e.el===null&&e.patchFlag!==-1||e.memo?e:Hn(e)}function tu(e,t){let n=0;const{shapeFlag:r}=e;if(t==null)t=null;else if(le(t))n=16;else if(typeof t=="object")if(r&65){const s=t.default;s&&(s._c&&(s._d=!1),tu(e,s()),s._c&&(s._d=!0));return}else{n=32;const s=t._;!s&&!Zh(t)?t._ctx=qe:s===3&&qe&&(qe.slots._===1?t._=1:(t._=2,e.patchFlag|=1024))}else ce(t)?(t={default:t,_ctx:qe},n=32):(t=String(t),r&64?(n=16,t=[Kr(t)]):n=8);e.children=t,e.shapeFlag|=n}function qt(...e){const t={};for(let n=0;nGe||qe;let Qo,qi;{const e=fh(),t=(n,r)=>{let s;return(s=e[n])||(s=e[n]=[]),s.push(r),o=>{s.length>1?s.forEach(a=>a(o)):s[0](o)}};Qo=t("__VUE_INSTANCE_SETTERS__",n=>Ge=n),qi=t("__VUE_SSR_SETTERS__",n=>io=n)}const vr=e=>{const t=Ge;return Qo(e),e.scope.on(),()=>{e.scope.off(),Qo(t)}},Zi=()=>{Ge&&Ge.scope.off(),Qo(null)};function vv(e){return e.vnode.shapeFlag&4}let io=!1;function Pb(e,t=!1,n=!1){t&&qi(t);const{props:r,children:s}=e.vnode,o=vv(e);Zy(e,r,o,t),eb(e,s,n);const a=o?Ab(e,t):void 0;return t&&qi(!1),a}function Ab(e,t){const n=e.type;e.accessCache=Object.create(null),e.proxy=new Proxy(e.ctx,Hy);const{setup:r}=n;if(r){const s=e.setupContext=r.length>1?Lb(e):null,o=vr(e);Wn();const a=Bn(r,e,0,[e.props,s]);if(Un(),o(),Pl(a)){if(a.then(Zi,Zi),t)return a.then(i=>{Ji(e,i,t)}).catch(i=>{rs(i,e,0)});e.asyncDep=a}else Ji(e,a,t)}else mv(e,t)}function Ji(e,t,n){ce(t)?e.type.__ssrInlineRender?e.ssrRender=t:e.render=t:Ie(t)&&(e.setupState=kh(t)),mv(e,n)}let Dc;function mv(e,t,n){const r=e.type;if(!e.render){if(!t&&Dc&&!r.render){const s=r.template||Jl(e).template;if(s){const{isCustomElement:o,compilerOptions:a}=e.appContext.config,{delimiters:i,compilerOptions:l}=r,u=Ke(Ke({isCustomElement:o,delimiters:i},a),l);r.render=Dc(s,u)}}e.render=r.render||Lt}{const s=vr(e);Wn();try{jy(e)}finally{Un(),s()}}}const Ib={get(e,t){return Ct(e,"get",""),e[t]}};function Lb(e){const t=n=>{e.exposed=n||{}};return{attrs:new Proxy(e.attrs,Ib),slots:e.slots,emit:e.emit,expose:t}}function La(e){return e.exposed?e.exposeProxy||(e.exposeProxy=new Proxy(kh(jl(e.exposed)),{get(t,n){if(n in t)return t[n];if(n in Ps)return Ps[n](e)},has(t,n){return n in t||n in Ps}})):e.proxy}function Rb(e,t=!0){return ce(e)?e.displayName||e.name:e.name||t&&e.__name}function Nb(e){return ce(e)&&"__vccOpts"in e}const w=(e,t)=>gy(e,t,io);function lo(e,t,n){const r=arguments.length;return r===2?Ie(t)&&!le(t)?Ws(t)?L(e,null,[t]):L(e,t):L(e,null,t):(r>3?n=Array.prototype.slice.call(arguments,2):r===3&&Ws(n)&&(n=[n]),L(e,t,n))}const Fb="3.4.35";/** +**/function Bn(e,t,n,r){try{return r?e(...r):e()}catch(s){rs(s,t,n)}}function Nt(e,t,n,r){if(ce(e)){const s=Bn(e,t,n,r);return s&&xl(s)&&s.catch(o=>{rs(o,t,n)}),s}if(le(e)){const s=[];for(let o=0;o>>1,s=rt[r],o=Hs(s);oen&&rt.splice(t,1)}function Hi(e){le(e)?Nr.push(...e):(!Pn||!Pn.includes(e,e.allowRecurse?sr+1:sr))&&Nr.push(e),Ih()}function lc(e,t,n=Bs?en+1:0){for(;nHs(n)-Hs(r));if(Nr.length=0,Pn){Pn.push(...t);return}for(Pn=t,sr=0;sre.id==null?1/0:e.id,Ty=(e,t)=>{const n=Hs(e)-Hs(t);if(n===0){if(e.pre&&!t.pre)return-1;if(t.pre&&!e.pre)return 1}return n};function Rh(e){Bi=!1,Bs=!0,rt.sort(Ty);try{for(en=0;en{r._d&&wc(-1);const o=qo(t);let a;try{a=e(...s)}finally{qo(o),r._d&&wc(1)}return a};return r._n=!0,r._c=!0,r._d=!0,r}function Ul(e,t){if(qe===null)return e;const n=La(qe),r=e.dirs||(e.dirs=[]);for(let s=0;s{e.isMounted=!0}),yr(()=>{e.isUnmounting=!0}),e}const It=[Function,Array],Fh={mode:String,appear:Boolean,persisted:Boolean,onBeforeEnter:It,onEnter:It,onAfterEnter:It,onEnterCancelled:It,onBeforeLeave:It,onLeave:It,onAfterLeave:It,onLeaveCancelled:It,onBeforeAppear:It,onAppear:It,onAfterAppear:It,onAppearCancelled:It},Yh=e=>{const t=e.subTree;return t.component?Yh(t.component):t},My={name:"BaseTransition",props:Fh,setup(e,{slots:t}){const n=os(),r=Nh();return()=>{const s=t.default&&zl(t.default(),!0);if(!s||!s.length)return;let o=s[0];if(s.length>1){for(const d of s)if(d.type!==st){o=d;break}}const a=ge(e),{mode:i}=a;if(r.isLeaving)return ci(o);const l=uc(o);if(!l)return ci(o);let u=js(l,a,r,n,d=>u=d);Ur(l,u);const c=n.subTree,f=c&&uc(c);if(f&&f.type!==st&&!tn(l,f)&&Yh(n).type!==st){const d=js(f,a,r,n);if(Ur(f,d),i==="out-in"&&l.type!==st)return r.isLeaving=!0,d.afterLeave=()=>{r.isLeaving=!1,n.update.active!==!1&&(n.effect.dirty=!0,n.update())},ci(o);i==="in-out"&&l.type!==st&&(d.delayLeave=(h,v,m)=>{const p=Bh(r,f);p[String(f.key)]=f,h[An]=()=>{v(),h[An]=void 0,delete u.delayedLeave},u.delayedLeave=m})}return o}}},ky=My;function Bh(e,t){const{leavingVNodes:n}=e;let r=n.get(t.type);return r||(r=Object.create(null),n.set(t.type,r)),r}function js(e,t,n,r,s){const{appear:o,mode:a,persisted:i=!1,onBeforeEnter:l,onEnter:u,onAfterEnter:c,onEnterCancelled:f,onBeforeLeave:d,onLeave:h,onAfterLeave:v,onLeaveCancelled:m,onBeforeAppear:p,onAppear:b,onAfterAppear:S,onAppearCancelled:T}=t,M=String(e.key),D=Bh(n,e),C=($,I)=>{$&&Nt($,r,9,I)},E=($,I)=>{const j=I[1];C($,I),le($)?$.every(O=>O.length<=1)&&j():$.length<=1&&j()},P={mode:a,persisted:i,beforeEnter($){let I=l;if(!n.isMounted)if(o)I=p||l;else return;$[An]&&$[An](!0);const j=D[M];j&&tn(e,j)&&j.el[An]&&j.el[An](),C(I,[$])},enter($){let I=u,j=c,O=f;if(!n.isMounted)if(o)I=b||u,j=S||c,O=T||f;else return;let W=!1;const re=$[So]=X=>{W||(W=!0,X?C(O,[$]):C(j,[$]),P.delayedLeave&&P.delayedLeave(),$[So]=void 0)};I?E(I,[$,re]):re()},leave($,I){const j=String(e.key);if($[So]&&$[So](!0),n.isUnmounting)return I();C(d,[$]);let O=!1;const W=$[An]=re=>{O||(O=!0,I(),re?C(m,[$]):C(v,[$]),$[An]=void 0,D[j]===e&&delete D[j])};D[j]=e,h?E(h,[$,W]):W()},clone($){const I=js($,t,n,r,s);return s&&s(I),I}};return P}function ci(e){if(ro(e))return e=Hn(e),e.children=null,e}function uc(e){if(!ro(e))return e;const{shapeFlag:t,children:n}=e;if(n){if(t&16)return n[0];if(t&32&&ce(n.default))return n.default()}}function Ur(e,t){e.shapeFlag&6&&e.component?Ur(e.component.subTree,t):e.shapeFlag&128?(e.ssContent.transition=t.clone(e.ssContent),e.ssFallback.transition=t.clone(e.ssFallback)):e.transition=t}function zl(e,t=!1,n){let r=[],s=0;for(let o=0;o1)for(let o=0;o!!e.type.__asyncLoader;/*! #__NO_SIDE_EFFECTS__ */function or(e){ce(e)&&(e={loader:e});const{loader:t,loadingComponent:n,errorComponent:r,delay:s=200,timeout:o,suspensible:a=!0,onError:i}=e;let l=null,u,c=0;const f=()=>(c++,l=null,d()),d=()=>{let h;return l||(h=l=t().catch(v=>{if(v=v instanceof Error?v:new Error(String(v)),i)return new Promise((m,p)=>{i(v,()=>m(f()),()=>p(v),c+1)});throw v}).then(v=>h!==l&&l?l:(v&&(v.__esModule||v[Symbol.toStringTag]==="Module")&&(v=v.default),u=v,v)))};return Ze({name:"AsyncComponentWrapper",__asyncLoader:d,get __asyncResolved(){return u},setup(){const h=Ge;if(u)return()=>fi(u,h);const v=S=>{l=null,rs(S,h,13,!r)};if(a&&h.suspense||io)return d().then(S=>()=>fi(S,h)).catch(S=>(v(S),()=>r?L(r,{error:S}):null));const m=oe(!1),p=oe(),b=oe(!!s);return s&&setTimeout(()=>{b.value=!1},s),o!=null&&setTimeout(()=>{if(!m.value&&!p.value){const S=new Error(`Async component timed out after ${o}ms.`);v(S),p.value=S}},o),d().then(()=>{m.value=!0,h.parent&&ro(h.parent.vnode)&&(h.parent.effect.dirty=!0,Oa(h.parent.update))}).catch(S=>{v(S),p.value=S}),()=>{if(m.value&&u)return fi(u,h);if(p.value&&r)return L(r,{error:p.value});if(n&&!b.value)return L(n)}}})}function fi(e,t){const{ref:n,props:r,children:s,ce:o}=t.vnode,a=L(e,r,s);return a.ref=n,a.ce=o,delete t.vnode.ce,a}const ro=e=>e.type.__isKeepAlive;function Hh(e,t){Vh(e,"a",t)}function jh(e,t){Vh(e,"da",t)}function Vh(e,t,n=Ge){const r=e.__wdc||(e.__wdc=()=>{let s=n;for(;s;){if(s.isDeactivated)return;s=s.parent}return e()});if(ka(t,r,n),n){let s=n.parent;for(;s&&s.parent;)ro(s.parent.vnode)&&xy(r,t,n,s),s=s.parent}}function xy(e,t,n,r){const s=ka(t,e,r,!0);ss(()=>{kl(r[t],s)},n)}function ka(e,t,n=Ge,r=!1){if(n){const s=n[e]||(n[e]=[]),o=t.__weh||(t.__weh=(...a)=>{Wn();const i=vr(n),l=Nt(t,n,e,a);return i(),Un(),l});return r?s.unshift(o):s.push(o),o}}const Cn=e=>(t,n=Ge)=>{(!io||e==="sp")&&ka(e,(...r)=>t(...r),n)},Py=Cn("bm"),Gt=Cn("m"),Ay=Cn("bu"),Kl=Cn("u"),yr=Cn("bum"),ss=Cn("um"),Iy=Cn("sp"),Ly=Cn("rtg"),Ry=Cn("rtc");function xa(e,t=Ge){ka("ec",e,t)}const Gl="components",Ny="directives";function vn(e,t){return ql(Gl,e,!0,t)||e}const Wh=Symbol.for("v-ndc");function Pa(e){return Ve(e)?ql(Gl,e,!1)||e:e||Wh}function Fy(e){return ql(Ny,e)}function ql(e,t,n=!0,r=!1){const s=qe||Ge;if(s){const o=s.type;if(e===Gl){const i=Lb(o,!1);if(i&&(i===t||i===kt(t)||i===Dn(kt(t))))return o}const a=cc(s[e]||o[e],t)||cc(s.appContext[e],t);return!a&&r?o:a}}function cc(e,t){return e&&(e[t]||e[kt(t)]||e[Dn(kt(t))])}function Ft(e,t,n,r){let s;const o=n;if(le(e)||Ve(e)){s=new Array(e.length);for(let a=0,i=e.length;at(a,i,void 0,o));else{const a=Object.keys(e);s=new Array(a.length);for(let i=0,l=a.length;iWs(t)?!(t.type===st||t.type===be&&!Uh(t.children)):!0)?e:null}function Yy(e,t){const n={};for(const r in e)n[/[A-Z]/.test(r)?`on:${r}`:Io(r)]=e[r];return n}const ji=e=>e?vv(e)?La(e):ji(e.parent):null,Ps=Ke(Object.create(null),{$:e=>e,$el:e=>e.vnode.el,$data:e=>e.data,$props:e=>e.props,$attrs:e=>e.attrs,$slots:e=>e.slots,$refs:e=>e.refs,$parent:e=>ji(e.parent),$root:e=>ji(e.root),$emit:e=>e.emit,$options:e=>Zl(e),$forceUpdate:e=>e.f||(e.f=()=>{e.effect.dirty=!0,Oa(e.update)}),$nextTick:e=>e.n||(e.n=Ot.bind(e.proxy)),$watch:e=>db.bind(e)}),di=(e,t)=>e!==Me&&!e.__isScriptSetup&&De(e,t),By={get({_:e},t){if(t==="__v_skip")return!0;const{ctx:n,setupState:r,data:s,props:o,accessCache:a,type:i,appContext:l}=e;let u;if(t[0]!=="$"){const h=a[t];if(h!==void 0)switch(h){case 1:return r[t];case 2:return s[t];case 4:return n[t];case 3:return o[t]}else{if(di(r,t))return a[t]=1,r[t];if(s!==Me&&De(s,t))return a[t]=2,s[t];if((u=e.propsOptions[0])&&De(u,t))return a[t]=3,o[t];if(n!==Me&&De(n,t))return a[t]=4,n[t];Vi&&(a[t]=0)}}const c=Ps[t];let f,d;if(c)return t==="$attrs"&&Ct(e.attrs,"get",""),c(e);if((f=i.__cssModules)&&(f=f[t]))return f;if(n!==Me&&De(n,t))return a[t]=4,n[t];if(d=l.config.globalProperties,De(d,t))return d[t]},set({_:e},t,n){const{data:r,setupState:s,ctx:o}=e;return di(s,t)?(s[t]=n,!0):r!==Me&&De(r,t)?(r[t]=n,!0):De(e.props,t)||t[0]==="$"&&t.slice(1)in e?!1:(o[t]=n,!0)},has({_:{data:e,setupState:t,accessCache:n,ctx:r,appContext:s,propsOptions:o}},a){let i;return!!n[a]||e!==Me&&De(e,a)||di(t,a)||(i=o[0])&&De(i,a)||De(r,a)||De(Ps,a)||De(s.config.globalProperties,a)},defineProperty(e,t,n){return n.get!=null?e._.accessCache[t]=0:De(n,"value")&&this.set(e,t,n.value,null),Reflect.defineProperty(e,t,n)}};function Zo(e){return le(e)?e.reduce((t,n)=>(t[n]=null,t),{}):e}function bY(e,t){return!e||!t?e||t:le(e)&&le(t)?e.concat(t):Ke({},Zo(e),Zo(t))}function hi(e){const t=os();let n=e();return Zi(),xl(n)&&(n=n.catch(r=>{throw vr(t),r})),[n,()=>vr(t)]}let Vi=!0;function Hy(e){const t=Zl(e),n=e.proxy,r=e.ctx;Vi=!1,t.beforeCreate&&fc(t.beforeCreate,e,"bc");const{data:s,computed:o,methods:a,watch:i,provide:l,inject:u,created:c,beforeMount:f,mounted:d,beforeUpdate:h,updated:v,activated:m,deactivated:p,beforeDestroy:b,beforeUnmount:S,destroyed:T,unmounted:M,render:D,renderTracked:C,renderTriggered:E,errorCaptured:P,serverPrefetch:$,expose:I,inheritAttrs:j,components:O,directives:W,filters:re}=t;if(u&&jy(u,r,null),a)for(const J in a){const ue=a[J];ce(ue)&&(r[J]=ue.bind(n))}if(s){const J=s.call(n,n);Ie(J)&&(e.data=je(J))}if(Vi=!0,o)for(const J in o){const ue=o[J],we=ce(ue)?ue.bind(n,n):ce(ue.get)?ue.get.bind(n,n):Lt,V=!ce(ue)&&ce(ue.set)?ue.set.bind(n):Lt,fe=w({get:we,set:V});Object.defineProperty(r,J,{enumerable:!0,configurable:!0,get:()=>fe.value,set:Q=>fe.value=Q})}if(i)for(const J in i)zh(i[J],r,n,J);if(l){const J=ce(l)?l.call(n):l;Reflect.ownKeys(J).forEach(ue=>{Pt(ue,J[ue])})}c&&fc(c,e,"c");function ee(J,ue){le(ue)?ue.forEach(we=>J(we.bind(n))):ue&&J(ue.bind(n))}if(ee(Py,f),ee(Gt,d),ee(Ay,h),ee(Kl,v),ee(Hh,m),ee(jh,p),ee(xa,P),ee(Ry,C),ee(Ly,E),ee(yr,S),ee(ss,M),ee(Iy,$),le(I))if(I.length){const J=e.exposed||(e.exposed={});I.forEach(ue=>{Object.defineProperty(J,ue,{get:()=>n[ue],set:we=>n[ue]=we})})}else e.exposed||(e.exposed={});D&&e.render===Lt&&(e.render=D),j!=null&&(e.inheritAttrs=j),O&&(e.components=O),W&&(e.directives=W)}function jy(e,t,n=Lt){le(e)&&(e=Wi(e));for(const r in e){const s=e[r];let o;Ie(s)?"default"in s?o=Pe(s.from||r,s.default,!0):o=Pe(s.from||r):o=Pe(s),Se(o)?Object.defineProperty(t,r,{enumerable:!0,configurable:!0,get:()=>o.value,set:a=>o.value=a}):t[r]=o}}function fc(e,t,n){Nt(le(e)?e.map(r=>r.bind(t.proxy)):e.bind(t.proxy),t,n)}function zh(e,t,n,r){const s=r.includes(".")?iv(n,r):()=>n[r];if(Ve(e)){const o=t[e];ce(o)&&Te(s,o)}else if(ce(e))Te(s,e.bind(n));else if(Ie(e))if(le(e))e.forEach(o=>zh(o,t,n,r));else{const o=ce(e.handler)?e.handler.bind(n):t[e.handler];ce(o)&&Te(s,o,e)}}function Zl(e){const t=e.type,{mixins:n,extends:r}=t,{mixins:s,optionsCache:o,config:{optionMergeStrategies:a}}=e.appContext,i=o.get(t);let l;return i?l=i:!s.length&&!n&&!r?l=t:(l={},s.length&&s.forEach(u=>Jo(l,u,a,!0)),Jo(l,t,a)),Ie(t)&&o.set(t,l),l}function Jo(e,t,n,r=!1){const{mixins:s,extends:o}=t;o&&Jo(e,o,n,!0),s&&s.forEach(a=>Jo(e,a,n,!0));for(const a in t)if(!(r&&a==="expose")){const i=Vy[a]||n&&n[a];e[a]=i?i(e[a],t[a]):t[a]}return e}const Vy={data:dc,props:hc,emits:hc,methods:$s,computed:$s,beforeCreate:dt,created:dt,beforeMount:dt,mounted:dt,beforeUpdate:dt,updated:dt,beforeDestroy:dt,beforeUnmount:dt,destroyed:dt,unmounted:dt,activated:dt,deactivated:dt,errorCaptured:dt,serverPrefetch:dt,components:$s,directives:$s,watch:Uy,provide:dc,inject:Wy};function dc(e,t){return t?e?function(){return Ke(ce(e)?e.call(this,this):e,ce(t)?t.call(this,this):t)}:t:e}function Wy(e,t){return $s(Wi(e),Wi(t))}function Wi(e){if(le(e)){const t={};for(let n=0;n1)return n&&ce(t)?t.call(r&&r.proxy):t}}function Gy(){return!!(Ge||qe||Fr)}const Gh={},qh=()=>Object.create(Gh),Zh=e=>Object.getPrototypeOf(e)===Gh;function qy(e,t,n,r=!1){const s={},o=qh();e.propsDefaults=Object.create(null),Jh(e,t,s,o);for(const a in e.propsOptions[0])a in s||(s[a]=void 0);n?e.props=r?s:my(s):e.type.props?e.props=s:e.props=o,e.attrs=o}function Zy(e,t,n,r){const{props:s,attrs:o,vnode:{patchFlag:a}}=e,i=ge(s),[l]=e.propsOptions;let u=!1;if((r||a>0)&&!(a&16)){if(a&8){const c=e.vnode.dynamicProps;for(let f=0;f{l=!0;const[d,h]=Xh(f,t,!0);Ke(a,d),h&&i.push(...h)};!n&&t.mixins.length&&t.mixins.forEach(c),e.extends&&c(e.extends),e.mixins&&e.mixins.forEach(c)}if(!o&&!l)return Ie(e)&&r.set(e,Ir),Ir;if(le(o))for(let c=0;ce[0]==="_"||e==="$stable",Jl=e=>le(e)?e.map(Wt):[Wt(e)],Xy=(e,t,n)=>{if(t._n)return t;const r=Ee((...s)=>Jl(t(...s)),n);return r._c=!1,r},ev=(e,t,n)=>{const r=e._ctx;for(const s in e){if(Qh(s))continue;const o=e[s];if(ce(o))t[s]=Xy(s,o,r);else if(o!=null){const a=Jl(o);t[s]=()=>a}}},tv=(e,t)=>{const n=Jl(t);e.slots.default=()=>n},nv=(e,t,n)=>{for(const r in t)(n||r!=="_")&&(e[r]=t[r])},Qy=(e,t,n)=>{const r=e.slots=qh();if(e.vnode.shapeFlag&32){const s=t._;s?(nv(r,t,n),n&&uh(r,"_",s,!0)):ev(t,r)}else t&&tv(e,t)},eb=(e,t,n)=>{const{vnode:r,slots:s}=e;let o=!0,a=Me;if(r.shapeFlag&32){const i=t._;i?n&&i===1?o=!1:nv(s,t,n):(o=!t.$stable,ev(t,s)),a=t}else t&&(tv(e,t),a={default:1});if(o)for(const i in s)!Qh(i)&&a[i]==null&&delete s[i]};function zi(e,t,n,r,s=!1){if(le(e)){e.forEach((d,h)=>zi(d,t&&(le(t)?t[h]:t),n,r,s));return}if(xs(r)&&!s)return;const o=r.shapeFlag&4?La(r.component):r.el,a=s?null:o,{i,r:l}=e,u=t&&t.r,c=i.refs===Me?i.refs={}:i.refs,f=i.setupState;if(u!=null&&u!==l&&(Ve(u)?(c[u]=null,De(f,u)&&(f[u]=null)):Se(u)&&(u.value=null)),ce(l))Bn(l,i,12,[a,c]);else{const d=Ve(l),h=Se(l);if(d||h){const v=()=>{if(e.f){const m=d?De(f,l)?f[l]:c[l]:l.value;s?le(m)&&kl(m,o):le(m)?m.includes(o)||m.push(o):d?(c[l]=[o],De(f,l)&&(f[l]=c[l])):(l.value=[o],e.k&&(c[e.k]=l.value))}else d?(c[l]=a,De(f,l)&&(f[l]=a)):h&&(l.value=a,e.k&&(c[e.k]=a))};a?(v.id=-1,gt(v,n)):v()}}}const rv=Symbol("_vte"),tb=e=>e.__isTeleport,As=e=>e&&(e.disabled||e.disabled===""),mc=e=>typeof SVGElement<"u"&&e instanceof SVGElement,pc=e=>typeof MathMLElement=="function"&&e instanceof MathMLElement,Ki=(e,t)=>{const n=e&&e.to;return Ve(n)?t?t(n):null:n},nb={name:"Teleport",__isTeleport:!0,process(e,t,n,r,s,o,a,i,l,u){const{mc:c,pc:f,pbc:d,o:{insert:h,querySelector:v,createText:m,createComment:p}}=u,b=As(t.props);let{shapeFlag:S,children:T,dynamicChildren:M}=t;if(e==null){const D=t.el=m(""),C=t.anchor=m("");h(D,n,r),h(C,n,r);const E=t.target=Ki(t.props,v),P=ov(E,t,m,h);E&&(a==="svg"||mc(E)?a="svg":(a==="mathml"||pc(E))&&(a="mathml"));const $=(I,j)=>{S&16&&c(T,I,j,s,o,a,i,l)};b?$(n,C):E&&$(E,P)}else{t.el=e.el,t.targetStart=e.targetStart;const D=t.anchor=e.anchor,C=t.target=e.target,E=t.targetAnchor=e.targetAnchor,P=As(e.props),$=P?n:C,I=P?D:E;if(a==="svg"||mc(C)?a="svg":(a==="mathml"||pc(C))&&(a="mathml"),M?(d(e.dynamicChildren,M,$,s,o,a,i),Xl(e,t,!0)):l||f(e,t,$,I,s,o,a,i,!1),b)P?t.props&&e.props&&t.props.to!==e.props.to&&(t.props.to=e.props.to):$o(t,n,D,u,1);else if((t.props&&t.props.to)!==(e.props&&e.props.to)){const j=t.target=Ki(t.props,v);j&&$o(t,j,null,u,0)}else P&&$o(t,C,E,u,1)}sv(t)},remove(e,t,n,{um:r,o:{remove:s}},o){const{shapeFlag:a,children:i,anchor:l,targetStart:u,targetAnchor:c,target:f,props:d}=e;if(f&&(s(u),s(c)),o&&s(l),a&16){const h=o||!As(d);for(let v=0;v{if(g===_)return;g&&!tn(g,_)&&(Y=ye(g),Q(g,R,H,!0),g=null),_.patchFlag===-2&&(z=!1,_.dynamicChildren=null);const{type:B,ref:q,shapeFlag:ne}=_;switch(B){case ao:p(g,_,k,Y);break;case st:b(g,_,k,Y);break;case Lo:g==null&&S(_,k,Y,K);break;case be:O(g,_,k,Y,R,H,K,U,z);break;default:ne&1?D(g,_,k,Y,R,H,K,U,z):ne&6?W(g,_,k,Y,R,H,K,U,z):(ne&64||ne&128)&&B.process(g,_,k,Y,R,H,K,U,z,lt)}q!=null&&R&&zi(q,g&&g.ref,H,_||g,!_)},p=(g,_,k,Y)=>{if(g==null)r(_.el=i(_.children),k,Y);else{const R=_.el=g.el;_.children!==g.children&&u(R,_.children)}},b=(g,_,k,Y)=>{g==null?r(_.el=l(_.children||""),k,Y):_.el=g.el},S=(g,_,k,Y)=>{[g.el,g.anchor]=v(g.children,_,k,Y,g.el,g.anchor)},T=({el:g,anchor:_},k,Y)=>{let R;for(;g&&g!==_;)R=d(g),r(g,k,Y),g=R;r(_,k,Y)},M=({el:g,anchor:_})=>{let k;for(;g&&g!==_;)k=d(g),s(g),g=k;s(_)},D=(g,_,k,Y,R,H,K,U,z)=>{_.type==="svg"?K="svg":_.type==="math"&&(K="mathml"),g==null?C(_,k,Y,R,H,K,U,z):$(g,_,R,H,K,U,z)},C=(g,_,k,Y,R,H,K,U)=>{let z,B;const{props:q,shapeFlag:ne,transition:te,dirs:ie}=g;if(z=g.el=a(g.type,H,q&&q.is,q),ne&8?c(z,g.children):ne&16&&P(g.children,z,null,Y,R,vi(g,H),K,U),ie&&Qn(g,null,Y,"created"),E(z,g,g.scopeId,K,Y),q){for(const Ce in q)Ce!=="value"&&!Ms(Ce)&&o(z,Ce,null,q[Ce],H,Y);"value"in q&&o(z,"value",null,q.value,H),(B=q.onVnodeBeforeMount)&&Qt(B,Y,g)}ie&&Qn(g,null,Y,"beforeMount");const de=ab(R,te);de&&te.beforeEnter(z),r(z,_,k),((B=q&&q.onVnodeMounted)||de||ie)&>(()=>{B&&Qt(B,Y,g),de&&te.enter(z),ie&&Qn(g,null,Y,"mounted")},R)},E=(g,_,k,Y,R)=>{if(k&&h(g,k),Y)for(let H=0;H{for(let B=z;B{const U=_.el=g.el;let{patchFlag:z,dynamicChildren:B,dirs:q}=_;z|=g.patchFlag&16;const ne=g.props||Me,te=_.props||Me;let ie;if(k&&er(k,!1),(ie=te.onVnodeBeforeUpdate)&&Qt(ie,k,_,g),q&&Qn(_,g,k,"beforeUpdate"),k&&er(k,!0),(ne.innerHTML&&te.innerHTML==null||ne.textContent&&te.textContent==null)&&c(U,""),B?I(g.dynamicChildren,B,U,k,Y,vi(_,R),H):K||ue(g,_,U,null,k,Y,vi(_,R),H,!1),z>0){if(z&16)j(U,ne,te,k,R);else if(z&2&&ne.class!==te.class&&o(U,"class",null,te.class,R),z&4&&o(U,"style",ne.style,te.style,R),z&8){const de=_.dynamicProps;for(let Ce=0;Ce{ie&&Qt(ie,k,_,g),q&&Qn(_,g,k,"updated")},Y)},I=(g,_,k,Y,R,H,K)=>{for(let U=0;U<_.length;U++){const z=g[U],B=_[U],q=z.el&&(z.type===be||!tn(z,B)||z.shapeFlag&70)?f(z.el):k;m(z,B,q,null,Y,R,H,K,!0)}},j=(g,_,k,Y,R)=>{if(_!==k){if(_!==Me)for(const H in _)!Ms(H)&&!(H in k)&&o(g,H,_[H],null,R,Y);for(const H in k){if(Ms(H))continue;const K=k[H],U=_[H];K!==U&&H!=="value"&&o(g,H,U,K,R,Y)}"value"in k&&o(g,"value",_.value,k.value,R)}},O=(g,_,k,Y,R,H,K,U,z)=>{const B=_.el=g?g.el:i(""),q=_.anchor=g?g.anchor:i("");let{patchFlag:ne,dynamicChildren:te,slotScopeIds:ie}=_;ie&&(U=U?U.concat(ie):ie),g==null?(r(B,k,Y),r(q,k,Y),P(_.children||[],k,q,R,H,K,U,z)):ne>0&&ne&64&&te&&g.dynamicChildren?(I(g.dynamicChildren,te,k,R,H,K,U),(_.key!=null||R&&_===R.subTree)&&Xl(g,_,!0)):ue(g,_,k,q,R,H,K,U,z)},W=(g,_,k,Y,R,H,K,U,z)=>{_.slotScopeIds=U,g==null?_.shapeFlag&512?R.ctx.activate(_,k,Y,K,z):re(_,k,Y,R,H,K,z):X(g,_,z)},re=(g,_,k,Y,R,H,K)=>{const U=g.component=kb(g,Y,R);if(ro(g)&&(U.ctx.renderer=lt),xb(U,!1,K),U.asyncDep){if(R&&R.registerDep(U,ee,K),!g.el){const z=U.subTree=L(st);b(null,z,_,k)}}else ee(U,g,_,k,R,H,K)},X=(g,_,k)=>{const Y=_.component=g.component;if(yb(g,_,k))if(Y.asyncDep&&!Y.asyncResolved){J(Y,_,k);return}else Y.next=_,$y(Y.update),Y.effect.dirty=!0,Y.update();else _.el=g.el,Y.vnode=_},ee=(g,_,k,Y,R,H,K)=>{const U=()=>{if(g.isMounted){let{next:q,bu:ne,u:te,parent:ie,vnode:de}=g;{const Vt=av(g);if(Vt){q&&(q.el=de.el,J(g,q,K)),Vt.asyncDep.then(()=>{g.isUnmounted||U()});return}}let Ce=q,_e;er(g,!1),q?(q.el=de.el,J(g,q,K)):q=de,ne&&li(ne),(_e=q.props&&q.props.onVnodeBeforeUpdate)&&Qt(_e,ie,q,de),er(g,!0);const Be=mi(g),ct=g.subTree;g.subTree=Be,m(ct,Be,f(ct.el),ye(ct),g,R,H),q.el=Be.el,Ce===null&&Ql(g,Be.el),te&>(te,R),(_e=q.props&&q.props.onVnodeUpdated)&>(()=>Qt(_e,ie,q,de),R)}else{let q;const{el:ne,props:te}=_,{bm:ie,m:de,parent:Ce}=g,_e=xs(_);if(er(g,!1),ie&&li(ie),!_e&&(q=te&&te.onVnodeBeforeMount)&&Qt(q,Ce,_),er(g,!0),ne&&ut){const Be=()=>{g.subTree=mi(g),ut(ne,g.subTree,g,R,null)};_e?_.type.__asyncLoader().then(()=>!g.isUnmounted&&Be()):Be()}else{const Be=g.subTree=mi(g);m(null,Be,k,Y,g,R,H),_.el=Be.el}if(de&>(de,R),!_e&&(q=te&&te.onVnodeMounted)){const Be=_;gt(()=>Qt(q,Ce,Be),R)}(_.shapeFlag&256||Ce&&xs(Ce.vnode)&&Ce.vnode.shapeFlag&256)&&g.a&>(g.a,R),g.isMounted=!0,_=k=Y=null}},z=g.effect=new Ll(U,Lt,()=>Oa(B),g.scope),B=g.update=()=>{z.dirty&&z.run()};B.i=g,B.id=g.uid,er(g,!0),B()},J=(g,_,k)=>{_.component=g;const Y=g.vnode.props;g.vnode=_,g.next=null,Zy(g,_.props,Y,k),eb(g,_.children,k),Wn(),lc(g),Un()},ue=(g,_,k,Y,R,H,K,U,z=!1)=>{const B=g&&g.children,q=g?g.shapeFlag:0,ne=_.children,{patchFlag:te,shapeFlag:ie}=_;if(te>0){if(te&128){V(B,ne,k,Y,R,H,K,U,z);return}else if(te&256){we(B,ne,k,Y,R,H,K,U,z);return}}ie&8?(q&16&&Re(B,R,H),ne!==B&&c(k,ne)):q&16?ie&16?V(B,ne,k,Y,R,H,K,U,z):Re(B,R,H,!0):(q&8&&c(k,""),ie&16&&P(ne,k,Y,R,H,K,U,z))},we=(g,_,k,Y,R,H,K,U,z)=>{g=g||Ir,_=_||Ir;const B=g.length,q=_.length,ne=Math.min(B,q);let te;for(te=0;teq?Re(g,R,H,!0,!1,ne):P(_,k,Y,R,H,K,U,z,ne)},V=(g,_,k,Y,R,H,K,U,z)=>{let B=0;const q=_.length;let ne=g.length-1,te=q-1;for(;B<=ne&&B<=te;){const ie=g[B],de=_[B]=z?In(_[B]):Wt(_[B]);if(tn(ie,de))m(ie,de,k,null,R,H,K,U,z);else break;B++}for(;B<=ne&&B<=te;){const ie=g[ne],de=_[te]=z?In(_[te]):Wt(_[te]);if(tn(ie,de))m(ie,de,k,null,R,H,K,U,z);else break;ne--,te--}if(B>ne){if(B<=te){const ie=te+1,de=iete)for(;B<=ne;)Q(g[B],R,H,!0),B++;else{const ie=B,de=B,Ce=new Map;for(B=de;B<=te;B++){const Je=_[B]=z?In(_[B]):Wt(_[B]);Je.key!=null&&Ce.set(Je.key,B)}let _e,Be=0;const ct=te-de+1;let Vt=!1,Jn=0;const fn=new Array(ct);for(B=0;B=ct){Q(Je,R,H,!0);continue}let N;if(Je.key!=null)N=Ce.get(Je.key);else for(_e=de;_e<=te;_e++)if(fn[_e-de]===0&&tn(Je,_[_e])){N=_e;break}N===void 0?Q(Je,R,H,!0):(fn[N-de]=B+1,N>=Jn?Jn=N:Vt=!0,m(Je,_[N],k,null,R,H,K,U,z),Be++)}const Xn=Vt?ib(fn):Ir;for(_e=Xn.length-1,B=ct-1;B>=0;B--){const Je=de+B,N=_[Je],y=Je+1{const{el:H,type:K,transition:U,children:z,shapeFlag:B}=g;if(B&6){fe(g.component.subTree,_,k,Y);return}if(B&128){g.suspense.move(_,k,Y);return}if(B&64){K.move(g,_,k,lt);return}if(K===be){r(H,_,k);for(let ne=0;neU.enter(H),R);else{const{leave:ne,delayLeave:te,afterLeave:ie}=U,de=()=>r(H,_,k),Ce=()=>{ne(H,()=>{de(),ie&&ie()})};te?te(H,de,Ce):Ce()}else r(H,_,k)},Q=(g,_,k,Y=!1,R=!1)=>{const{type:H,props:K,ref:U,children:z,dynamicChildren:B,shapeFlag:q,patchFlag:ne,dirs:te,cacheIndex:ie}=g;if(ne===-2&&(R=!1),U!=null&&zi(U,null,k,g,!0),ie!=null&&(_.renderCache[ie]=void 0),q&256){_.ctx.deactivate(g);return}const de=q&1&&te,Ce=!xs(g);let _e;if(Ce&&(_e=K&&K.onVnodeBeforeUnmount)&&Qt(_e,_,g),q&6)Ye(g.component,k,Y);else{if(q&128){g.suspense.unmount(k,Y);return}de&&Qn(g,null,_,"beforeUnmount"),q&64?g.type.remove(g,_,k,lt,Y):B&&!B.hasOnce&&(H!==be||ne>0&&ne&64)?Re(B,_,k,!1,!0):(H===be&&ne&384||!R&&q&16)&&Re(z,_,k),Y&&Le(g)}(Ce&&(_e=K&&K.onVnodeUnmounted)||de)&>(()=>{_e&&Qt(_e,_,g),de&&Qn(g,null,_,"unmounted")},k)},Le=g=>{const{type:_,el:k,anchor:Y,transition:R}=g;if(_===be){pe(k,Y);return}if(_===Lo){M(g);return}const H=()=>{s(k),R&&!R.persisted&&R.afterLeave&&R.afterLeave()};if(g.shapeFlag&1&&R&&!R.persisted){const{leave:K,delayLeave:U}=R,z=()=>K(k,H);U?U(g.el,H,z):z()}else H()},pe=(g,_)=>{let k;for(;g!==_;)k=d(g),s(g),g=k;s(_)},Ye=(g,_,k)=>{const{bum:Y,scope:R,update:H,subTree:K,um:U,m:z,a:B}=g;gc(z),gc(B),Y&&li(Y),R.stop(),H&&(H.active=!1,Q(K,g,_,k)),U&>(U,_),gt(()=>{g.isUnmounted=!0},_),_&&_.pendingBranch&&!_.isUnmounted&&g.asyncDep&&!g.asyncResolved&&g.suspenseId===_.pendingId&&(_.deps--,_.deps===0&&_.resolve())},Re=(g,_,k,Y=!1,R=!1,H=0)=>{for(let K=H;K{if(g.shapeFlag&6)return ye(g.component.subTree);if(g.shapeFlag&128)return g.suspense.next();const _=d(g.anchor||g.el),k=_&&_[rv];return k?d(k):_};let ze=!1;const tt=(g,_,k)=>{g==null?_._vnode&&Q(_._vnode,null,null,!0):m(_._vnode||null,g,_,null,null,null,k),ze||(ze=!0,lc(),Lh(),ze=!1),_._vnode=g},lt={p:m,um:Q,m:fe,r:Le,mt:re,mc:P,pc:ue,pbc:I,n:ye,o:e};let mt,ut;return{render:tt,hydrate:mt,createApp:Ky(tt,mt)}}function vi({type:e,props:t},n){return n==="svg"&&e==="foreignObject"||n==="mathml"&&e==="annotation-xml"&&t&&t.encoding&&t.encoding.includes("html")?void 0:n}function er({effect:e,update:t},n){e.allowRecurse=t.allowRecurse=n}function ab(e,t){return(!e||e&&!e.pendingBranch)&&t&&!t.persisted}function Xl(e,t,n=!1){const r=e.children,s=t.children;if(le(r)&&le(s))for(let o=0;o>1,e[n[i]]0&&(t[r]=n[o-1]),n[o]=r)}}for(o=n.length,a=n[o-1];o-- >0;)n[o]=a,a=t[a];return n}function av(e){const t=e.subTree.component;if(t)return t.asyncDep&&!t.asyncResolved?t:av(t)}function gc(e){if(e)for(let t=0;tPe(lb);function zn(e,t){return oo(e,null,t)}function cb(e,t){return oo(e,null,{flush:"post"})}function fb(e,t){return oo(e,null,{flush:"sync"})}const To={};function Te(e,t,n){return oo(e,t,n)}function oo(e,t,{immediate:n,deep:r,flush:s,once:o,onTrack:a,onTrigger:i}=Me){if(t&&o){const C=t;t=(...E)=>{C(...E),D()}}const l=Ge,u=C=>r===!0?C:Ln(C,r===!1?1:void 0);let c,f=!1,d=!1;if(Se(e)?(c=()=>e.value,f=Wr(e)):Yn(e)?(c=()=>u(e),f=!0):le(e)?(d=!0,f=e.some(C=>Yn(C)||Wr(C)),c=()=>e.map(C=>{if(Se(C))return C.value;if(Yn(C))return u(C);if(ce(C))return Bn(C,l,2)})):ce(e)?t?c=()=>Bn(e,l,2):c=()=>(h&&h(),Nt(e,l,3,[v])):c=Lt,t&&r){const C=c;c=()=>Ln(C())}let h,v=C=>{h=T.onStop=()=>{Bn(C,l,4),h=T.onStop=void 0}},m;if(io)if(v=Lt,t?n&&Nt(t,l,3,[c(),d?[]:void 0,v]):c(),s==="sync"){const C=ub();m=C.__watcherHandles||(C.__watcherHandles=[])}else return Lt;let p=d?new Array(e.length).fill(To):To;const b=()=>{if(!(!T.active||!T.dirty))if(t){const C=T.run();(r||f||(d?C.some((E,P)=>yt(E,p[P])):yt(C,p)))&&(h&&h(),Nt(t,l,3,[C,p===To?void 0:d&&p[0]===To?[]:p,v]),p=C)}else T.run()};b.allowRecurse=!!t;let S;s==="sync"?S=b:s==="post"?S=()=>gt(b,l&&l.suspense):(b.pre=!0,l&&(b.id=l.uid),S=()=>Oa(b));const T=new Ll(c,Lt,S),M=ph(),D=()=>{T.stop(),M&&kl(M.effects,T)};return t?n?b():p=T.run():s==="post"?gt(T.run.bind(T),l&&l.suspense):T.run(),m&&m.push(D),D}function db(e,t,n){const r=this.proxy,s=Ve(e)?e.includes(".")?iv(r,e):()=>r[e]:e.bind(r,r);let o;ce(t)?o=t:(o=t.handler,n=t);const a=vr(this),i=oo(s,o.bind(r),n);return a(),i}function iv(e,t){const n=t.split(".");return()=>{let r=e;for(let s=0;s{Ln(r,t,n)});else if(lh(e)){for(const r in e)Ln(e[r],t,n);for(const r of Object.getOwnPropertySymbols(e))Object.prototype.propertyIsEnumerable.call(e,r)&&Ln(e[r],t,n)}return e}function hb(e,t,n=Me){const r=os(),s=kt(t),o=_n(t),a=lv(e,t),i=wy((l,u)=>{let c,f=Me,d;return fb(()=>{const h=e[t];yt(c,h)&&(c=h,u())}),{get(){return l(),n.get?n.get(c):c},set(h){if(!yt(h,c)&&!(f!==Me&&yt(h,f)))return;const v=r.vnode.props;v&&(t in v||s in v||o in v)&&(`onUpdate:${t}`in v||`onUpdate:${s}`in v||`onUpdate:${o}`in v)||(c=h,u());const m=n.set?n.set(h):h;r.emit(`update:${t}`,m),yt(h,m)&&yt(h,f)&&!yt(m,d)&&u(),f=h,d=m}}});return i[Symbol.iterator]=()=>{let l=0;return{next(){return l<2?{value:l++?a||Me:i,done:!1}:{done:!0}}}},i}const lv=(e,t)=>t==="modelValue"||t==="model-value"?e.modelModifiers:e[`${t}Modifiers`]||e[`${kt(t)}Modifiers`]||e[`${_n(t)}Modifiers`];function vb(e,t,...n){if(e.isUnmounted)return;const r=e.vnode.props||Me;let s=n;const o=t.startsWith("update:"),a=o&&lv(r,t.slice(7));a&&(a.trim&&(s=n.map(c=>Ve(c)?c.trim():c)),a.number&&(s=n.map(Hg)));let i,l=r[i=Io(t)]||r[i=Io(kt(t))];!l&&o&&(l=r[i=Io(_n(t))]),l&&Nt(l,e,6,s);const u=r[i+"Once"];if(u){if(!e.emitted)e.emitted={};else if(e.emitted[i])return;e.emitted[i]=!0,Nt(u,e,6,s)}}function uv(e,t,n=!1){const r=t.emitsCache,s=r.get(e);if(s!==void 0)return s;const o=e.emits;let a={},i=!1;if(!ce(e)){const l=u=>{const c=uv(u,t,!0);c&&(i=!0,Ke(a,c))};!n&&t.mixins.length&&t.mixins.forEach(l),e.extends&&l(e.extends),e.mixins&&e.mixins.forEach(l)}return!o&&!i?(Ie(e)&&r.set(e,null),null):(le(o)?o.forEach(l=>a[l]=null):Ke(a,o),Ie(e)&&r.set(e,a),a)}function Aa(e,t){return!e||!Ca(t)?!1:(t=t.slice(2).replace(/Once$/,""),De(e,t[0].toLowerCase()+t.slice(1))||De(e,_n(t))||De(e,t))}function mi(e){const{type:t,vnode:n,proxy:r,withProxy:s,propsOptions:[o],slots:a,attrs:i,emit:l,render:u,renderCache:c,props:f,data:d,setupState:h,ctx:v,inheritAttrs:m}=e,p=qo(e);let b,S;try{if(n.shapeFlag&4){const M=s||r,D=M;b=Wt(u.call(D,M,c,f,h,d,v)),S=i}else{const M=t;b=Wt(M.length>1?M(f,{attrs:i,slots:a,emit:l}):M(f,null)),S=t.props?i:pb(i)}}catch(M){Is.length=0,rs(M,e,1),b=L(st)}let T=b;if(S&&m!==!1){const M=Object.keys(S),{shapeFlag:D}=T;M.length&&D&7&&(o&&M.some(Ml)&&(S=gb(S,o)),T=Hn(T,S,!1,!0))}return n.dirs&&(T=Hn(T,null,!1,!0),T.dirs=T.dirs?T.dirs.concat(n.dirs):n.dirs),n.transition&&(T.transition=n.transition),b=T,qo(p),b}function mb(e,t=!0){let n;for(let r=0;r{let t;for(const n in e)(n==="class"||n==="style"||Ca(n))&&((t||(t={}))[n]=e[n]);return t},gb=(e,t)=>{const n={};for(const r in e)(!Ml(r)||!(r.slice(9)in t))&&(n[r]=e[r]);return n};function yb(e,t,n){const{props:r,children:s,component:o}=e,{props:a,children:i,patchFlag:l}=t,u=o.emitsOptions;if(t.dirs||t.transition)return!0;if(n&&l>=0){if(l&1024)return!0;if(l&16)return r?yc(r,a,u):!!a;if(l&8){const c=t.dynamicProps;for(let f=0;fe.__isSuspense;let Gi=0;const wb={name:"Suspense",__isSuspense:!0,process(e,t,n,r,s,o,a,i,l,u){if(e==null)_b(t,n,r,s,o,a,i,l,u);else{if(o&&o.deps>0&&!e.suspense.isInFallback){t.suspense=e.suspense,t.suspense.vnode=t,t.el=e.el;return}Db(e,t,n,r,s,a,i,l,u)}},hydrate:Cb,normalize:Sb},Ia=wb;function Vs(e,t){const n=e.props&&e.props[t];ce(n)&&n()}function _b(e,t,n,r,s,o,a,i,l){const{p:u,o:{createElement:c}}=l,f=c("div"),d=e.suspense=cv(e,s,r,t,f,n,o,a,i,l);u(null,d.pendingBranch=e.ssContent,f,null,r,d,o,a),d.deps>0?(Vs(e,"onPending"),Vs(e,"onFallback"),u(null,e.ssFallback,t,n,r,null,o,a),Yr(d,e.ssFallback)):d.resolve(!1,!0)}function Db(e,t,n,r,s,o,a,i,{p:l,um:u,o:{createElement:c}}){const f=t.suspense=e.suspense;f.vnode=t,t.el=e.el;const d=t.ssContent,h=t.ssFallback,{activeBranch:v,pendingBranch:m,isInFallback:p,isHydrating:b}=f;if(m)f.pendingBranch=d,tn(d,m)?(l(m,d,f.hiddenContainer,null,s,f,o,a,i),f.deps<=0?f.resolve():p&&(b||(l(v,h,n,r,s,null,o,a,i),Yr(f,h)))):(f.pendingId=Gi++,b?(f.isHydrating=!1,f.activeBranch=m):u(m,s,f),f.deps=0,f.effects.length=0,f.hiddenContainer=c("div"),p?(l(null,d,f.hiddenContainer,null,s,f,o,a,i),f.deps<=0?f.resolve():(l(v,h,n,r,s,null,o,a,i),Yr(f,h))):v&&tn(d,v)?(l(v,d,n,r,s,f,o,a,i),f.resolve(!0)):(l(null,d,f.hiddenContainer,null,s,f,o,a,i),f.deps<=0&&f.resolve()));else if(v&&tn(d,v))l(v,d,n,r,s,f,o,a,i),Yr(f,d);else if(Vs(t,"onPending"),f.pendingBranch=d,d.shapeFlag&512?f.pendingId=d.component.suspenseId:f.pendingId=Gi++,l(null,d,f.hiddenContainer,null,s,f,o,a,i),f.deps<=0)f.resolve();else{const{timeout:S,pendingId:T}=f;S>0?setTimeout(()=>{f.pendingId===T&&f.fallback(h)},S):S===0&&f.fallback(h)}}function cv(e,t,n,r,s,o,a,i,l,u,c=!1){const{p:f,m:d,um:h,n:v,o:{parentNode:m,remove:p}}=u;let b;const S=Tb(e);S&&t&&t.pendingBranch&&(b=t.pendingId,t.deps++);const T=e.props?ch(e.props.timeout):void 0,M=o,D={vnode:e,parent:t,parentComponent:n,namespace:a,container:r,hiddenContainer:s,deps:0,pendingId:Gi++,timeout:typeof T=="number"?T:-1,activeBranch:null,pendingBranch:null,isInFallback:!c,isHydrating:c,isUnmounted:!1,effects:[],resolve(C=!1,E=!1){const{vnode:P,activeBranch:$,pendingBranch:I,pendingId:j,effects:O,parentComponent:W,container:re}=D;let X=!1;D.isHydrating?D.isHydrating=!1:C||(X=$&&I.transition&&I.transition.mode==="out-in",X&&($.transition.afterLeave=()=>{j===D.pendingId&&(d(I,re,o===M?v($):o,0),Hi(O))}),$&&(m($.el)!==D.hiddenContainer&&(o=v($)),h($,W,D,!0)),X||d(I,re,o,0)),Yr(D,I),D.pendingBranch=null,D.isInFallback=!1;let ee=D.parent,J=!1;for(;ee;){if(ee.pendingBranch){ee.effects.push(...O),J=!0;break}ee=ee.parent}!J&&!X&&Hi(O),D.effects=[],S&&t&&t.pendingBranch&&b===t.pendingId&&(t.deps--,t.deps===0&&!E&&t.resolve()),Vs(P,"onResolve")},fallback(C){if(!D.pendingBranch)return;const{vnode:E,activeBranch:P,parentComponent:$,container:I,namespace:j}=D;Vs(E,"onFallback");const O=v(P),W=()=>{D.isInFallback&&(f(null,C,I,O,$,null,j,i,l),Yr(D,C))},re=C.transition&&C.transition.mode==="out-in";re&&(P.transition.afterLeave=W),D.isInFallback=!0,h(P,$,null,!0),re||W()},move(C,E,P){D.activeBranch&&d(D.activeBranch,C,E,P),D.container=C},next(){return D.activeBranch&&v(D.activeBranch)},registerDep(C,E,P){const $=!!D.pendingBranch;$&&D.deps++;const I=C.vnode.el;C.asyncDep.catch(j=>{rs(j,C,0)}).then(j=>{if(C.isUnmounted||D.isUnmounted||D.pendingId!==C.suspenseId)return;C.asyncResolved=!0;const{vnode:O}=C;Ji(C,j,!1),I&&(O.el=I);const W=!I&&C.subTree.el;E(C,O,m(I||C.subTree.el),I?null:v(C.subTree),D,a,P),W&&p(W),Ql(C,O.el),$&&--D.deps===0&&D.resolve()})},unmount(C,E){D.isUnmounted=!0,D.activeBranch&&h(D.activeBranch,n,C,E),D.pendingBranch&&h(D.pendingBranch,n,C,E)}};return D}function Cb(e,t,n,r,s,o,a,i,l){const u=t.suspense=cv(t,r,n,e.parentNode,document.createElement("div"),null,s,o,a,i,!0),c=l(e,u.pendingBranch=t.ssContent,n,u,o,a);return u.deps===0&&u.resolve(!1,!0),c}function Sb(e){const{shapeFlag:t,children:n}=e,r=t&32;e.ssContent=bc(r?n.default:n),e.ssFallback=r?bc(n.fallback):L(st)}function bc(e){let t;if(ce(e)){const n=zr&&e._c;n&&(e._d=!1,G()),e=e(),n&&(e._d=!0,t=bt,fv())}return le(e)&&(e=mb(e)),e=Wt(e),t&&!e.dynamicChildren&&(e.dynamicChildren=t.filter(n=>n!==e)),e}function $b(e,t){t&&t.pendingBranch?le(e)?t.effects.push(...e):t.effects.push(e):Hi(e)}function Yr(e,t){e.activeBranch=t;const{vnode:n,parentComponent:r}=e;let s=t.el;for(;!s&&t.component;)t=t.component.subTree,s=t.el;n.el=s,r&&r.subTree===n&&(r.vnode.el=s,Ql(r,s))}function Tb(e){const t=e.props&&e.props.suspensible;return t!=null&&t!==!1}const be=Symbol.for("v-fgt"),ao=Symbol.for("v-txt"),st=Symbol.for("v-cmt"),Lo=Symbol.for("v-stc"),Is=[];let bt=null;function G(e=!1){Is.push(bt=e?null:[])}function fv(){Is.pop(),bt=Is[Is.length-1]||null}let zr=1;function wc(e){zr+=e,e<0&&bt&&(bt.hasOnce=!0)}function dv(e){return e.dynamicChildren=zr>0?bt||Ir:null,fv(),zr>0&&bt&&bt.push(e),e}function ae(e,t,n,r,s,o){return dv(me(e,t,n,r,s,o,!0))}function Ae(e,t,n,r,s){return dv(L(e,t,n,r,s,!0))}function Ws(e){return e?e.__v_isVNode===!0:!1}function tn(e,t){return e.type===t.type&&e.key===t.key}const hv=({key:e})=>e??null,Ro=({ref:e,ref_key:t,ref_for:n})=>(typeof e=="number"&&(e=""+e),e!=null?Ve(e)||Se(e)||ce(e)?{i:qe,r:e,k:t,f:!!n}:e:null);function me(e,t=null,n=null,r=0,s=null,o=e===be?0:1,a=!1,i=!1){const l={__v_isVNode:!0,__v_skip:!0,type:e,props:t,key:t&&hv(t),ref:t&&Ro(t),scopeId:Ma,slotScopeIds:null,children:n,component:null,suspense:null,ssContent:null,ssFallback:null,dirs:null,transition:null,el:null,anchor:null,target:null,targetStart:null,targetAnchor:null,staticCount:0,shapeFlag:o,patchFlag:r,dynamicProps:s,dynamicChildren:null,appContext:null,ctx:qe};return i?(eu(l,n),o&128&&e.normalize(l)):n&&(l.shapeFlag|=Ve(n)?8:16),zr>0&&!a&&bt&&(l.patchFlag>0||o&6)&&l.patchFlag!==32&&bt.push(l),l}const L=Eb;function Eb(e,t=null,n=null,r=0,s=null,o=!1){if((!e||e===Wh)&&(e=st),Ws(e)){const i=Hn(e,t,!0);return n&&eu(i,n),zr>0&&!o&&bt&&(i.shapeFlag&6?bt[bt.indexOf(e)]=i:bt.push(i)),i.patchFlag=-2,i}if(Rb(e)&&(e=e.__vccOpts),t){t=Xo(t);let{class:i,style:l}=t;i&&!Ve(i)&&(t.class=xe(i)),Ie(l)&&(Oh(l)&&!le(l)&&(l=Ke({},l)),t.style=pn(l))}const a=Ve(e)?1:bb(e)?128:tb(e)?64:Ie(e)?4:ce(e)?2:0;return me(e,t,n,r,s,a,o,!0)}function Xo(e){return e?Oh(e)||Zh(e)?Ke({},e):e:null}function Hn(e,t,n=!1,r=!1){const{props:s,ref:o,patchFlag:a,children:i,transition:l}=e,u=t?qt(s||{},t):s,c={__v_isVNode:!0,__v_skip:!0,type:e.type,props:u,key:u&&hv(u),ref:t&&t.ref?n&&o?le(o)?o.concat(Ro(t)):[o,Ro(t)]:Ro(t):o,scopeId:e.scopeId,slotScopeIds:e.slotScopeIds,children:i,target:e.target,targetStart:e.targetStart,targetAnchor:e.targetAnchor,staticCount:e.staticCount,shapeFlag:e.shapeFlag,patchFlag:t&&e.type!==be?a===-1?16:a|16:a,dynamicProps:e.dynamicProps,dynamicChildren:e.dynamicChildren,appContext:e.appContext,dirs:e.dirs,transition:l,component:e.component,suspense:e.suspense,ssContent:e.ssContent&&Hn(e.ssContent),ssFallback:e.ssFallback&&Hn(e.ssFallback),el:e.el,anchor:e.anchor,ctx:e.ctx,ce:e.ce};return l&&r&&Ur(c,l.clone(c)),c}function Kr(e=" ",t=0){return L(ao,null,e,t)}function We(e="",t=!1){return t?(G(),Ae(st,null,e)):L(st,null,e)}function Wt(e){return e==null||typeof e=="boolean"?L(st):le(e)?L(be,null,e.slice()):typeof e=="object"?In(e):L(ao,null,String(e))}function In(e){return e.el===null&&e.patchFlag!==-1||e.memo?e:Hn(e)}function eu(e,t){let n=0;const{shapeFlag:r}=e;if(t==null)t=null;else if(le(t))n=16;else if(typeof t=="object")if(r&65){const s=t.default;s&&(s._c&&(s._d=!1),eu(e,s()),s._c&&(s._d=!0));return}else{n=32;const s=t._;!s&&!Zh(t)?t._ctx=qe:s===3&&qe&&(qe.slots._===1?t._=1:(t._=2,e.patchFlag|=1024))}else ce(t)?(t={default:t,_ctx:qe},n=32):(t=String(t),r&64?(n=16,t=[Kr(t)]):n=8);e.children=t,e.shapeFlag|=n}function qt(...e){const t={};for(let n=0;nGe||qe;let Qo,qi;{const e=fh(),t=(n,r)=>{let s;return(s=e[n])||(s=e[n]=[]),s.push(r),o=>{s.length>1?s.forEach(a=>a(o)):s[0](o)}};Qo=t("__VUE_INSTANCE_SETTERS__",n=>Ge=n),qi=t("__VUE_SSR_SETTERS__",n=>io=n)}const vr=e=>{const t=Ge;return Qo(e),e.scope.on(),()=>{e.scope.off(),Qo(t)}},Zi=()=>{Ge&&Ge.scope.off(),Qo(null)};function vv(e){return e.vnode.shapeFlag&4}let io=!1;function xb(e,t=!1,n=!1){t&&qi(t);const{props:r,children:s}=e.vnode,o=vv(e);qy(e,r,o,t),Qy(e,s,n);const a=o?Pb(e,t):void 0;return t&&qi(!1),a}function Pb(e,t){const n=e.type;e.accessCache=Object.create(null),e.proxy=new Proxy(e.ctx,By);const{setup:r}=n;if(r){const s=e.setupContext=r.length>1?Ib(e):null,o=vr(e);Wn();const a=Bn(r,e,0,[e.props,s]);if(Un(),o(),xl(a)){if(a.then(Zi,Zi),t)return a.then(i=>{Ji(e,i,t)}).catch(i=>{rs(i,e,0)});e.asyncDep=a}else Ji(e,a,t)}else mv(e,t)}function Ji(e,t,n){ce(t)?e.type.__ssrInlineRender?e.ssrRender=t:e.render=t:Ie(t)&&(e.setupState=xh(t)),mv(e,n)}let _c;function mv(e,t,n){const r=e.type;if(!e.render){if(!t&&_c&&!r.render){const s=r.template||Zl(e).template;if(s){const{isCustomElement:o,compilerOptions:a}=e.appContext.config,{delimiters:i,compilerOptions:l}=r,u=Ke(Ke({isCustomElement:o,delimiters:i},a),l);r.render=_c(s,u)}}e.render=r.render||Lt}{const s=vr(e);Wn();try{Hy(e)}finally{Un(),s()}}}const Ab={get(e,t){return Ct(e,"get",""),e[t]}};function Ib(e){const t=n=>{e.exposed=n||{}};return{attrs:new Proxy(e.attrs,Ab),slots:e.slots,emit:e.emit,expose:t}}function La(e){return e.exposed?e.exposeProxy||(e.exposeProxy=new Proxy(xh(Hl(e.exposed)),{get(t,n){if(n in t)return t[n];if(n in Ps)return Ps[n](e)},has(t,n){return n in t||n in Ps}})):e.proxy}function Lb(e,t=!0){return ce(e)?e.displayName||e.name:e.name||t&&e.__name}function Rb(e){return ce(e)&&"__vccOpts"in e}const w=(e,t)=>py(e,t,io);function lo(e,t,n){const r=arguments.length;return r===2?Ie(t)&&!le(t)?Ws(t)?L(e,null,[t]):L(e,t):L(e,null,t):(r>3?n=Array.prototype.slice.call(arguments,2):r===3&&Ws(n)&&(n=[n]),L(e,t,n))}const Nb="3.4.35";/** * @vue/runtime-dom v3.4.35 * (c) 2018-present Yuxi (Evan) You and Vue contributors * @license MIT -**/const Yb="http://www.w3.org/2000/svg",Bb="http://www.w3.org/1998/Math/MathML",hn=typeof document<"u"?document:null,Cc=hn&&hn.createElement("template"),Hb={insert:(e,t,n)=>{t.insertBefore(e,n||null)},remove:e=>{const t=e.parentNode;t&&t.removeChild(e)},createElement:(e,t,n,r)=>{const s=t==="svg"?hn.createElementNS(Yb,e):t==="mathml"?hn.createElementNS(Bb,e):n?hn.createElement(e,{is:n}):hn.createElement(e);return e==="select"&&r&&r.multiple!=null&&s.setAttribute("multiple",r.multiple),s},createText:e=>hn.createTextNode(e),createComment:e=>hn.createComment(e),setText:(e,t)=>{e.nodeValue=t},setElementText:(e,t)=>{e.textContent=t},parentNode:e=>e.parentNode,nextSibling:e=>e.nextSibling,querySelector:e=>hn.querySelector(e),setScopeId(e,t){e.setAttribute(t,"")},insertStaticContent(e,t,n,r,s,o){const a=n?n.previousSibling:t.lastChild;if(s&&(s===o||s.nextSibling))for(;t.insertBefore(s.cloneNode(!0),n),!(s===o||!(s=s.nextSibling)););else{Cc.innerHTML=r==="svg"?`${e}`:r==="mathml"?`${e}`:e;const i=Cc.content;if(r==="svg"||r==="mathml"){const l=i.firstChild;for(;l.firstChild;)i.appendChild(l.firstChild);i.removeChild(l)}t.insertBefore(i,n)}return[a?a.nextSibling:t.firstChild,n?n.previousSibling:t.lastChild]}},En="transition",ys="animation",Gr=Symbol("_vtc"),uo=(e,{slots:t})=>lo(ky,gv(e),t);uo.displayName="Transition";const pv={name:String,type:String,css:{type:Boolean,default:!0},duration:[String,Number,Object],enterFromClass:String,enterActiveClass:String,enterToClass:String,appearFromClass:String,appearActiveClass:String,appearToClass:String,leaveFromClass:String,leaveActiveClass:String,leaveToClass:String},jb=uo.props=Ke({},Fh,pv),tr=(e,t=[])=>{le(e)?e.forEach(n=>n(...t)):e&&e(...t)},Sc=e=>e?le(e)?e.some(t=>t.length>1):e.length>1:!1;function gv(e){const t={};for(const O in e)O in pv||(t[O]=e[O]);if(e.css===!1)return t;const{name:n="v",type:r,duration:s,enterFromClass:o=`${n}-enter-from`,enterActiveClass:a=`${n}-enter-active`,enterToClass:i=`${n}-enter-to`,appearFromClass:l=o,appearActiveClass:u=a,appearToClass:c=i,leaveFromClass:f=`${n}-leave-from`,leaveActiveClass:d=`${n}-leave-active`,leaveToClass:h=`${n}-leave-to`}=e,v=Vb(s),m=v&&v[0],p=v&&v[1],{onBeforeEnter:b,onEnter:S,onEnterCancelled:T,onLeave:M,onLeaveCancelled:D,onBeforeAppear:C=b,onAppear:E=S,onAppearCancelled:P=T}=t,$=(O,W,re)=>{xn(O,W?c:i),xn(O,W?u:a),re&&re()},I=(O,W)=>{O._isLeaving=!1,xn(O,f),xn(O,h),xn(O,d),W&&W()},j=O=>(W,re)=>{const X=O?E:S,ee=()=>$(W,O,re);tr(X,[W,ee]),$c(()=>{xn(W,O?l:o),dn(W,O?c:i),Sc(X)||Tc(W,r,m,ee)})};return Ke(t,{onBeforeEnter(O){tr(b,[O]),dn(O,o),dn(O,a)},onBeforeAppear(O){tr(C,[O]),dn(O,l),dn(O,u)},onEnter:j(!1),onAppear:j(!0),onLeave(O,W){O._isLeaving=!0;const re=()=>I(O,W);dn(O,f),dn(O,d),bv(),$c(()=>{O._isLeaving&&(xn(O,f),dn(O,h),Sc(M)||Tc(O,r,p,re))}),tr(M,[O,re])},onEnterCancelled(O){$(O,!1),tr(T,[O])},onAppearCancelled(O){$(O,!0),tr(P,[O])},onLeaveCancelled(O){I(O),tr(D,[O])}})}function Vb(e){if(e==null)return null;if(Ie(e))return[pi(e.enter),pi(e.leave)];{const t=pi(e);return[t,t]}}function pi(e){return ch(e)}function dn(e,t){t.split(/\s+/).forEach(n=>n&&e.classList.add(n)),(e[Gr]||(e[Gr]=new Set)).add(t)}function xn(e,t){t.split(/\s+/).forEach(r=>r&&e.classList.remove(r));const n=e[Gr];n&&(n.delete(t),n.size||(e[Gr]=void 0))}function $c(e){requestAnimationFrame(()=>{requestAnimationFrame(e)})}let Wb=0;function Tc(e,t,n,r){const s=e._endId=++Wb,o=()=>{s===e._endId&&r()};if(n)return setTimeout(o,n);const{type:a,timeout:i,propCount:l}=yv(e,t);if(!a)return r();const u=a+"end";let c=0;const f=()=>{e.removeEventListener(u,d),o()},d=h=>{h.target===e&&++c>=l&&f()};setTimeout(()=>{c(n[v]||"").split(", "),s=r(`${En}Delay`),o=r(`${En}Duration`),a=Ec(s,o),i=r(`${ys}Delay`),l=r(`${ys}Duration`),u=Ec(i,l);let c=null,f=0,d=0;t===En?a>0&&(c=En,f=a,d=o.length):t===ys?u>0&&(c=ys,f=u,d=l.length):(f=Math.max(a,u),c=f>0?a>u?En:ys:null,d=c?c===En?o.length:l.length:0);const h=c===En&&/\b(transform|all)(,|$)/.test(r(`${En}Property`).toString());return{type:c,timeout:f,propCount:d,hasTransform:h}}function Ec(e,t){for(;e.lengthOc(n)+Oc(e[r])))}function Oc(e){return e==="auto"?0:Number(e.slice(0,-1).replace(",","."))*1e3}function bv(){return document.body.offsetHeight}function Ub(e,t,n){const r=e[Gr];r&&(t=(t?[t,...r]:[...r]).join(" ")),t==null?e.removeAttribute("class"):n?e.setAttribute("class",t):e.className=t}const ea=Symbol("_vod"),wv=Symbol("_vsh"),SY={beforeMount(e,{value:t},{transition:n}){e[ea]=e.style.display==="none"?"":e.style.display,n&&t?n.beforeEnter(e):bs(e,t)},mounted(e,{value:t},{transition:n}){n&&t&&n.enter(e)},updated(e,{value:t,oldValue:n},{transition:r}){!t!=!n&&(r?t?(r.beforeEnter(e),bs(e,!0),r.enter(e)):r.leave(e,()=>{bs(e,!1)}):bs(e,t))},beforeUnmount(e,{value:t}){bs(e,t)}};function bs(e,t){e.style.display=t?e[ea]:"none",e[wv]=!t}const _v=Symbol("");function zb(e){const t=os();if(!t)return;const n=t.ut=(s=e(t.proxy))=>{Array.from(document.querySelectorAll(`[data-v-owner="${t.uid}"]`)).forEach(o=>Qi(o,s))},r=()=>{const s=e(t.proxy);Xi(t.subTree,s),n(s)};Gt(()=>{fb(r);const s=new MutationObserver(r);s.observe(t.subTree.el.parentNode,{childList:!0}),ss(()=>s.disconnect())})}function Xi(e,t){if(e.shapeFlag&128){const n=e.suspense;e=n.activeBranch,n.pendingBranch&&!n.isHydrating&&n.effects.push(()=>{Xi(n.activeBranch,t)})}for(;e.component;)e=e.component.subTree;if(e.shapeFlag&1&&e.el)Qi(e.el,t);else if(e.type===be)e.children.forEach(n=>Xi(n,t));else if(e.type===Lo){let{el:n,anchor:r}=e;for(;n&&(Qi(n,t),n!==r);)n=n.nextSibling}}function Qi(e,t){if(e.nodeType===1){const n=e.style;let r="";for(const s in t)n.setProperty(`--${s}`,t[s]),r+=`--${s}: ${t[s]};`;n[_v]=r}}const Kb=/(^|;)\s*display\s*:/;function Gb(e,t,n){const r=e.style,s=Ve(n);let o=!1;if(n&&!s){if(t)if(Ve(t))for(const a of t.split(";")){const i=a.slice(0,a.indexOf(":")).trim();n[i]==null&&No(r,i,"")}else for(const a in t)n[a]==null&&No(r,a,"");for(const a in n)a==="display"&&(o=!0),No(r,a,n[a])}else if(s){if(t!==n){const a=r[_v];a&&(n+=";"+a),r.cssText=n,o=Kb.test(n)}}else t&&e.removeAttribute("style");ea in e&&(e[ea]=o?r.display:"",e[wv]&&(r.display="none"))}const Mc=/\s*!important$/;function No(e,t,n){if(le(n))n.forEach(r=>No(e,t,r));else if(n==null&&(n=""),t.startsWith("--"))e.setProperty(t,n);else{const r=qb(e,t);Mc.test(n)?e.setProperty(_n(r),n.replace(Mc,""),"important"):e[r]=n}}const xc=["Webkit","Moz","ms"],gi={};function qb(e,t){const n=gi[t];if(n)return n;let r=xt(t);if(r!=="filter"&&r in e)return gi[t]=r;r=Dn(r);for(let s=0;syi||(t0.then(()=>yi=0),yi=Date.now());function r0(e,t){const n=r=>{if(!r._vts)r._vts=Date.now();else if(r._vts<=n.attached)return;Nt(s0(r,n.value),t,5,[r])};return n.value=e,n.attached=n0(),n}function s0(e,t){if(le(t)){const n=e.stopImmediatePropagation;return e.stopImmediatePropagation=()=>{n.call(e),e._stopped=!0},t.map(r=>s=>!s._stopped&&r&&r(s))}else return t}const Lc=e=>e.charCodeAt(0)===111&&e.charCodeAt(1)===110&&e.charCodeAt(2)>96&&e.charCodeAt(2)<123,o0=(e,t,n,r,s,o)=>{const a=s==="svg";t==="class"?Ub(e,r,a):t==="style"?Gb(e,n,r):Ca(t)?xl(t)||Qb(e,t,n,r,o):(t[0]==="."?(t=t.slice(1),!0):t[0]==="^"?(t=t.slice(1),!1):a0(e,t,r,a))?(Zb(e,t,r),!e.tagName.includes("-")&&(t==="value"||t==="checked"||t==="selected")&&Pc(e,t,r,a,o,t!=="value")):(t==="true-value"?e._trueValue=r:t==="false-value"&&(e._falseValue=r),Pc(e,t,r,a))};function a0(e,t,n,r){if(r)return!!(t==="innerHTML"||t==="textContent"||t in e&&Lc(t)&&ce(n));if(t==="spellcheck"||t==="draggable"||t==="translate"||t==="form"||t==="list"&&e.tagName==="INPUT"||t==="type"&&e.tagName==="TEXTAREA")return!1;if(t==="width"||t==="height"){const s=e.tagName;if(s==="IMG"||s==="VIDEO"||s==="CANVAS"||s==="SOURCE")return!1}return Lc(t)&&Ve(n)?!1:t in e}const Dv=new WeakMap,Cv=new WeakMap,ta=Symbol("_moveCb"),Rc=Symbol("_enterCb"),Sv={name:"TransitionGroup",props:Ke({},jb,{tag:String,moveClass:String}),setup(e,{slots:t}){const n=os(),r=Nh();let s,o;return Gl(()=>{if(!s.length)return;const a=e.moveClass||`${e.name||"v"}-move`;if(!f0(s[0].el,n.vnode.el,a))return;s.forEach(l0),s.forEach(u0);const i=s.filter(c0);bv(),i.forEach(l=>{const u=l.el,c=u.style;dn(u,a),c.transform=c.webkitTransform=c.transitionDuration="";const f=u[ta]=d=>{d&&d.target!==u||(!d||/transform$/.test(d.propertyName))&&(u.removeEventListener("transitionend",f),u[ta]=null,xn(u,a))};u.addEventListener("transitionend",f)})}),()=>{const a=ge(e),i=gv(a);let l=a.tag||be;if(s=[],o)for(let u=0;udelete e.mode;Sv.props;const $Y=Sv;function l0(e){const t=e.el;t[ta]&&t[ta](),t[Rc]&&t[Rc]()}function u0(e){Cv.set(e,e.el.getBoundingClientRect())}function c0(e){const t=Dv.get(e),n=Cv.get(e),r=t.left-n.left,s=t.top-n.top;if(r||s){const o=e.el.style;return o.transform=o.webkitTransform=`translate(${r}px,${s}px)`,o.transitionDuration="0s",e}}function f0(e,t,n){const r=e.cloneNode(),s=e[Gr];s&&s.forEach(i=>{i.split(/\s+/).forEach(l=>l&&r.classList.remove(l))}),n.split(/\s+/).forEach(i=>i&&r.classList.add(i)),r.style.display="none";const o=t.nodeType===1?t:t.parentNode;o.appendChild(r);const{hasTransform:a}=yv(r);return o.removeChild(r),a}const d0=["ctrl","shift","alt","meta"],h0={stop:e=>e.stopPropagation(),prevent:e=>e.preventDefault(),self:e=>e.target!==e.currentTarget,ctrl:e=>!e.ctrlKey,shift:e=>!e.shiftKey,alt:e=>!e.altKey,meta:e=>!e.metaKey,left:e=>"button"in e&&e.button!==0,middle:e=>"button"in e&&e.button!==1,right:e=>"button"in e&&e.button!==2,exact:(e,t)=>d0.some(n=>e[`${n}Key`]&&!t.includes(n))},v0=(e,t)=>{const n=e._withMods||(e._withMods={}),r=t.join(".");return n[r]||(n[r]=(s,...o)=>{for(let a=0;a{const n=e._withKeys||(e._withKeys={}),r=t.join(".");return n[r]||(n[r]=s=>{if(!("key"in s))return;const o=_n(s.key);if(t.some(a=>a===o||m0[a]===o))return e(s)})},p0=Ke({patchProp:o0},Hb);let Fc;function $v(){return Fc||(Fc=ob(p0))}const TY=(...e)=>{$v().render(...e)},g0=(...e)=>{const t=$v().createApp(...e),{mount:n}=t;return t.mount=r=>{const s=b0(r);if(!s)return;const o=t._component;!ce(o)&&!o.render&&!o.template&&(o.template=s.innerHTML),s.innerHTML="";const a=n(s,!1,y0(s));return s instanceof Element&&(s.removeAttribute("v-cloak"),s.setAttribute("data-v-app","")),a},t};function y0(e){if(e instanceof SVGElement)return"svg";if(typeof MathMLElement=="function"&&e instanceof MathMLElement)return"mathml"}function b0(e){return Ve(e)?document.querySelector(e):e}function w0(e,t){let n;function r(){n=Il(),n.run(()=>t.length?t(()=>{n?.stop(),r()}):t())}Te(e,s=>{s&&!n?r():s||(n?.stop(),n=void 0)},{immediate:!0}),Ll(()=>{n?.stop()})}const ot=typeof window<"u",_0=ot&&"IntersectionObserver"in window,D0=ot&&("ontouchstart"in window||window.navigator.maxTouchPoints>0);function Tv(e,t,n){const r=t.length-1;if(r<0)return e===void 0?n:e;for(let s=0;snu(e[r],t[r]))}function el(e,t,n){return e==null||!t||typeof t!="string"?n:e[t]!==void 0?e[t]:(t=t.replace(/\[(\w+)\]/g,".$1"),t=t.replace(/^\./,""),Tv(e,t.split("."),n))}function EY(e,t,n){if(t===!0)return e===void 0?n:e;if(t==null||typeof t=="boolean")return n;if(e!==Object(e)){if(typeof t!="function")return n;const s=t(e,n);return typeof s>"u"?n:s}if(typeof t=="string")return el(e,t,n);if(Array.isArray(t))return Tv(e,t,n);if(typeof t!="function")return n;const r=t(e,n);return typeof r>"u"?n:r}function Ev(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0;return Array.from({length:e},(n,r)=>t+r)}function Fe(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"px";if(!(e==null||e===""))return isNaN(+e)?String(e):isFinite(+e)?`${Number(e)}${t}`:void 0}function tl(e){return e!==null&&typeof e=="object"&&!Array.isArray(e)}function Ov(e){if(e&&"$el"in e){const t=e.$el;return t?.nodeType===Node.TEXT_NODE?t.nextElementSibling:t}return e}const Yc=Object.freeze({enter:13,tab:9,delete:46,esc:27,space:32,up:38,down:40,left:37,right:39,end:35,home:36,del:46,backspace:8,insert:45,pageup:33,pagedown:34,shift:16});function OY(e){return Object.keys(e)}function bi(e,t){return t.every(n=>e.hasOwnProperty(n))}function C0(e,t){const n={},r=new Set(Object.keys(e));for(const s of t)r.has(s)&&(n[s]=e[s]);return n}function MY(e,t){const n={...e};return t.forEach(r=>delete n[r]),n}const S0=/^on[^a-z]/,xY=e=>S0.test(e);function $0(e){return e==null?[]:Array.isArray(e)?e:[e]}function na(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0,n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:1;return Math.max(t,Math.min(n,e))}function Bc(e,t){let n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:"0";return e+n.repeat(Math.max(0,t-e.length))}function Hc(e,t){return(arguments.length>2&&arguments[2]!==void 0?arguments[2]:"0").repeat(Math.max(0,t-e.length))+e}function T0(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:1;const n=[];let r=0;for(;r0&&arguments[0]!==void 0?arguments[0]:{},t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},n=arguments.length>2?arguments[2]:void 0;const r={};for(const s in e)r[s]=e[s];for(const s in t){const o=e[s],a=t[s];if(tl(o)&&tl(a)){r[s]=at(o,a,n);continue}if(Array.isArray(o)&&Array.isArray(a)&&n){r[s]=n(o,a);continue}r[s]=a}return r}function Mv(e){return e.map(t=>t.type===be?Mv(t.children):t).flat()}function cr(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:"";if(cr.cache.has(e))return cr.cache.get(e);const t=e.replace(/[^a-z]/gi,"-").replace(/\B([A-Z])/g,"-$1").toLowerCase();return cr.cache.set(e,t),t}cr.cache=new Map;function kr(e,t){if(!t||typeof t!="object")return[];if(Array.isArray(t))return t.map(n=>kr(e,n)).flat(1);if(t.suspense)return kr(e,t.ssContent);if(Array.isArray(t.children))return t.children.map(n=>kr(e,n)).flat(1);if(t.component){if(Object.getOwnPropertySymbols(t.component.provides).includes(e))return[t.component];if(t.component.subTree)return kr(e,t.component.subTree).flat(1)}return[]}function xv(e){const t=je({}),n=w(e);return zn(()=>{for(const r in n.value)t[r]=n.value[r]},{flush:"sync"}),no(t)}function ra(e,t){return e.includes(t)}function kY(e){return e[2].toLowerCase()+e.slice(3)}const PY=()=>[Function,Array];function jc(e,t){return t="on"+Dn(t),!!(e[t]||e[`${t}Once`]||e[`${t}Capture`]||e[`${t}OnceCapture`]||e[`${t}CaptureOnce`])}function E0(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!0;const n=["button","[href]",'input:not([type="hidden"])',"select","textarea","[tabindex]"].map(r=>`${r}${t?':not([tabindex="-1"])':""}:not([disabled])`).join(", ");return[...e.querySelectorAll(n)]}function O0(e,t,n){let r,s=e.indexOf(document.activeElement);const o=t==="next"?1:-1;do s+=o,r=e[s];while((!r||r.offsetParent==null)&&s=0);return r}function M0(e,t){const n=E0(e);if(!t)(e===document.activeElement||!e.contains(document.activeElement))&&n[0]?.focus();else if(t==="first")n[0]?.focus();else if(t==="last")n.at(-1)?.focus();else if(typeof t=="number")n[t]?.focus();else{const r=O0(n,t);r?r.focus():M0(e,t==="next"?"first":"last")}}function AY(e,t){if(!(ot&&typeof CSS<"u"&&typeof CSS.supports<"u"&&CSS.supports(`selector(${t})`)))return null;try{return!!e&&e.matches(t)}catch{return null}}function IY(e,t){if(!ot||e===0)return t(),()=>{};const n=window.setTimeout(t,e);return()=>window.clearTimeout(n)}function Vc(e,t){const n=Ut();return zn(()=>{n.value=e()},{flush:"sync",...t}),Ea(n)}function x0(){const e=Ut(),t=n=>{e.value=n};return Object.defineProperty(t,"value",{enumerable:!0,get:()=>e.value,set:n=>e.value=n}),Object.defineProperty(t,"el",{enumerable:!0,get:()=>Ov(e.value)}),t}const kv=["top","bottom"],k0=["start","end","left","right"];function P0(e,t){let[n,r]=e.split(" ");return r||(r=ra(kv,n)?"start":ra(k0,n)?"top":"center"),{side:Wc(n,t),align:Wc(r,t)}}function Wc(e,t){return e==="start"?t?"right":"left":e==="end"?t?"left":"right":e}function LY(e){return{side:{center:"center",top:"bottom",bottom:"top",left:"right",right:"left"}[e.side],align:e.align}}function RY(e){return{side:e.side,align:{center:"center",top:"bottom",bottom:"top",left:"right",right:"left"}[e.align]}}function NY(e){return{side:e.align,align:e.side}}function FY(e){return ra(kv,e.side)?"y":"x"}const Er=2.4,Uc=.2126729,zc=.7151522,Kc=.072175,A0=.55,I0=.58,L0=.57,R0=.62,Eo=.03,Gc=1.45,N0=5e-4,F0=1.25,Y0=1.25,qc=.078,Zc=12.82051282051282,Oo=.06,Jc=.001;function Xc(e,t){const n=(e.r/255)**Er,r=(e.g/255)**Er,s=(e.b/255)**Er,o=(t.r/255)**Er,a=(t.g/255)**Er,i=(t.b/255)**Er;let l=n*Uc+r*zc+s*Kc,u=o*Uc+a*zc+i*Kc;if(l<=Eo&&(l+=(Eo-l)**Gc),u<=Eo&&(u+=(Eo-u)**Gc),Math.abs(u-l)l){const f=(u**A0-l**I0)*F0;c=f-Jc?0:f>-qc?f-f*Zc*Oo:f+Oo}return c*100}function YY(e,t){t=Array.isArray(t)?t.slice(0,-1).map(n=>`'${n}'`).join(", ")+` or '${t.at(-1)}'`:`'${t}'`}const sa=.20689655172413793,B0=e=>e>sa**3?Math.cbrt(e):e/(3*sa**2)+4/29,H0=e=>e>sa?e**3:3*sa**2*(e-4/29);function Pv(e){const t=B0,n=t(e[1]);return[116*n-16,500*(t(e[0]/.95047)-n),200*(n-t(e[2]/1.08883))]}function Av(e){const t=H0,n=(e[0]+16)/116;return[t(n+e[1]/500)*.95047,t(n),t(n-e[2]/200)*1.08883]}const j0=[[3.2406,-1.5372,-.4986],[-.9689,1.8758,.0415],[.0557,-.204,1.057]],V0=e=>e<=.0031308?e*12.92:1.055*e**(1/2.4)-.055,W0=[[.4124,.3576,.1805],[.2126,.7152,.0722],[.0193,.1192,.9505]],U0=e=>e<=.04045?e/12.92:((e+.055)/1.055)**2.4;function Iv(e){const t=Array(3),n=V0,r=j0;for(let s=0;s<3;++s)t[s]=Math.round(na(n(r[s][0]*e[0]+r[s][1]*e[1]+r[s][2]*e[2]))*255);return{r:t[0],g:t[1],b:t[2]}}function ru(e){let{r:t,g:n,b:r}=e;const s=[0,0,0],o=U0,a=W0;t=o(t/255),n=o(n/255),r=o(r/255);for(let i=0;i<3;++i)s[i]=a[i][0]*t+a[i][1]*n+a[i][2]*r;return s}function nl(e){return!!e&&/^(#|var\(--|(rgb|hsl)a?\()/.test(e)}function z0(e){return nl(e)&&!/^((rgb|hsl)a?\()?var\(--/.test(e)}const Qc=/^(?(?:rgb|hsl)a?)\((?.+)\)/,K0={rgb:(e,t,n,r)=>({r:e,g:t,b:n,a:r}),rgba:(e,t,n,r)=>({r:e,g:t,b:n,a:r}),hsl:(e,t,n,r)=>ef({h:e,s:t,l:n,a:r}),hsla:(e,t,n,r)=>ef({h:e,s:t,l:n,a:r}),hsv:(e,t,n,r)=>Us({h:e,s:t,v:n,a:r}),hsva:(e,t,n,r)=>Us({h:e,s:t,v:n,a:r})};function nn(e){if(typeof e=="number")return{r:(e&16711680)>>16,g:(e&65280)>>8,b:e&255};if(typeof e=="string"&&Qc.test(e)){const{groups:t}=e.match(Qc),{fn:n,values:r}=t,s=r.split(/,\s*/).map(o=>o.endsWith("%")&&["hsl","hsla","hsv","hsva"].includes(n)?parseFloat(o)/100:parseFloat(o));return K0[n](...s)}else if(typeof e=="string"){let t=e.startsWith("#")?e.slice(1):e;return[3,4].includes(t.length)?t=t.split("").map(n=>n+n).join(""):[6,8].includes(t.length),q0(t)}else if(typeof e=="object"){if(bi(e,["r","g","b"]))return e;if(bi(e,["h","s","l"]))return Us(Lv(e));if(bi(e,["h","s","v"]))return Us(e)}throw new TypeError(`Invalid color: ${e==null?e:String(e)||e.constructor.name} -Expected #hex, #hexa, rgb(), rgba(), hsl(), hsla(), object or number`)}function Us(e){const{h:t,s:n,v:r,a:s}=e,o=i=>{const l=(i+t/60)%6;return r-r*n*Math.max(Math.min(l,4-l,1),0)},a=[o(5),o(3),o(1)].map(i=>Math.round(i*255));return{r:a[0],g:a[1],b:a[2],a:s}}function ef(e){return Us(Lv(e))}function Lv(e){const{h:t,s:n,l:r,a:s}=e,o=r+n*Math.min(r,1-r),a=o===0?0:2-2*r/o;return{h:t,s:a,v:o,a:s}}function Mo(e){const t=Math.round(e).toString(16);return("00".substr(0,2-t.length)+t).toUpperCase()}function G0(e){let{r:t,g:n,b:r,a:s}=e;return`#${[Mo(t),Mo(n),Mo(r),s!==void 0?Mo(Math.round(s*255)):""].join("")}`}function q0(e){e=Z0(e);let[t,n,r,s]=T0(e,2).map(o=>parseInt(o,16));return s=s===void 0?s:s/255,{r:t,g:n,b:r,a:s}}function Z0(e){return e.startsWith("#")&&(e=e.slice(1)),e=e.replace(/([^0-9a-f])/gi,"F"),(e.length===3||e.length===4)&&(e=e.split("").map(t=>t+t).join("")),e.length!==6&&(e=Bc(Bc(e,6),8,"F")),e}function J0(e,t){const n=Pv(ru(e));return n[0]=n[0]+t*10,Iv(Av(n))}function X0(e,t){const n=Pv(ru(e));return n[0]=n[0]-t*10,Iv(Av(n))}function Q0(e){const t=nn(e);return ru(t)[1]}function Rv(e){const t=Math.abs(Xc(nn(0),nn(e)));return Math.abs(Xc(nn(16777215),nn(e)))>Math.min(t,50)?"#fff":"#000"}function $e(e,t){return n=>Object.keys(e).reduce((r,s)=>{const a=typeof e[s]=="object"&&e[s]!=null&&!Array.isArray(e[s])?e[s]:{type:e[s]};return n&&s in n?r[s]={...a,default:n[s]}:r[s]=a,t&&!r[s].source&&(r[s].source=t),r},{})}const ln=$e({class:[String,Array,Object],style:{type:[String,Array,Object],default:null}},"component");function St(e,t){const n=os();if(!n)throw new Error(`[Vuetify] ${e} must be called from inside a setup function`);return n}function Kn(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:"composables";const t=St(e).type;return cr(t?.aliasName||t?.name)}let Nv=0,Fo=new WeakMap;function Ra(){const e=St("getUid");if(Fo.has(e))return Fo.get(e);{const t=Nv++;return Fo.set(e,t),t}}Ra.reset=()=>{Nv=0,Fo=new WeakMap};function e1(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:St("injectSelf");const{provides:n}=t;if(n&&e in n)return n[e]}const qr=Symbol.for("vuetify:defaults");function t1(e){return oe(e)}function su(){const e=Pe(qr);if(!e)throw new Error("[Vuetify] Could not find defaults instance");return e}function Fv(e,t){const n=su(),r=oe(e),s=w(()=>{if(A(t?.disabled))return n.value;const a=A(t?.scoped),i=A(t?.reset),l=A(t?.root);if(r.value==null&&!(a||i||l))return n.value;let u=at(r.value,{prev:n.value});if(a)return u;if(i||l){const c=Number(i||1/0);for(let f=0;f<=c&&!(!u||!("prev"in u));f++)u=u.prev;return u&&typeof l=="string"&&l in u&&(u=at(at(u,{prev:u}),u[l])),u}return u.prev?at(u.prev,u):u});return Pt(qr,s),s}function n1(e,t){return typeof e.props?.[t]<"u"||typeof e.props?.[cr(t)]<"u"}function r1(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},t=arguments.length>1?arguments[1]:void 0,n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:su();const r=St("useDefaults");if(t=t??r.type.name??r.type.__name,!t)throw new Error("[Vuetify] Could not determine component name");const s=w(()=>n.value?.[e._as??t]),o=new Proxy(e,{get(l,u){const c=Reflect.get(l,u);return u==="class"||u==="style"?[s.value?.[u],c].filter(f=>f!=null):typeof u=="string"&&!n1(r.vnode,u)?s.value?.[u]!==void 0?s.value?.[u]:n.value?.global?.[u]!==void 0?n.value?.global?.[u]:c:c}}),a=Ut();zn(()=>{if(s.value){const l=Object.entries(s.value).filter(u=>{let[c]=u;return c.startsWith(c[0].toUpperCase())});a.value=l.length?Object.fromEntries(l):void 0}else a.value=void 0});function i(){const l=e1(qr,r);Pt(qr,w(()=>a.value?at(l?.value??{},a.value):l?.value))}return{props:o,provideSubDefaults:i}}function co(e){if(e._setup=e._setup??e.setup,!e.name)return e;if(e._setup){e.props=$e(e.props??{},e.name)();const t=Object.keys(e.props).filter(n=>n!=="class"&&n!=="style");e.filterProps=function(r){return C0(r,t)},e.props._as=String,e.setup=function(r,s){const o=su();if(!o.value)return e._setup(r,s);const{props:a,provideSubDefaults:i}=r1(r,r._as??e.name,o),l=e._setup(a,s);return i(),l}}return e}function At(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:!0;return t=>(e?co:Ze)(t)}function s1(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"div",n=arguments.length>2?arguments[2]:void 0;return At()({name:n??Dn(xt(e.replace(/__/g,"-"))),props:{tag:{type:String,default:t},...ln()},setup(r,s){let{slots:o}=s;return()=>lo(r.tag,{class:[e,r.class],style:r.style},o.default?.())}})}function br(e){const t=St("useRender");t.render=e}function Na(e,t,n){let r=arguments.length>3&&arguments[3]!==void 0?arguments[3]:f=>f,s=arguments.length>4&&arguments[4]!==void 0?arguments[4]:f=>f;const o=St("useProxiedModel"),a=oe(e[t]!==void 0?e[t]:n),i=cr(t),u=w(i!==t?()=>(e[t],!!((o.vnode.props?.hasOwnProperty(t)||o.vnode.props?.hasOwnProperty(i))&&(o.vnode.props?.hasOwnProperty(`onUpdate:${t}`)||o.vnode.props?.hasOwnProperty(`onUpdate:${i}`)))):()=>(e[t],!!(o.vnode.props?.hasOwnProperty(t)&&o.vnode.props?.hasOwnProperty(`onUpdate:${t}`))));w0(()=>!u.value,()=>{Te(()=>e[t],f=>{a.value=f})});const c=w({get(){const f=e[t];return r(u.value?f:a.value)},set(f){const d=s(f),h=ge(u.value?e[t]:a.value);h===d||r(h)===f||(a.value=d,o?.emit(`update:${t}`,d))}});return Object.defineProperty(c,"externalValue",{get:()=>u.value?e[t]:a.value}),c}const o1={badge:"Badge",open:"Open",close:"Close",dismiss:"Dismiss",confirmEdit:{ok:"OK",cancel:"Cancel"},dataIterator:{noResultsText:"No matching records found",loadingText:"Loading items..."},dataTable:{itemsPerPageText:"Rows per page:",ariaLabel:{sortDescending:"Sorted descending.",sortAscending:"Sorted ascending.",sortNone:"Not sorted.",activateNone:"Activate to remove sorting.",activateDescending:"Activate to sort descending.",activateAscending:"Activate to sort ascending."},sortBy:"Sort by"},dataFooter:{itemsPerPageText:"Items per page:",itemsPerPageAll:"All",nextPage:"Next page",prevPage:"Previous page",firstPage:"First page",lastPage:"Last page",pageText:"{0}-{1} of {2}"},dateRangeInput:{divider:"to"},datePicker:{itemsSelected:"{0} selected",range:{title:"Select dates",header:"Enter dates"},title:"Select date",header:"Enter date",input:{placeholder:"Enter date"}},noDataText:"No data available",carousel:{prev:"Previous visual",next:"Next visual",ariaLabel:{delimiter:"Carousel slide {0} of {1}"}},calendar:{moreEvents:"{0} more",today:"Today"},input:{clear:"Clear {0}",prependAction:"{0} prepended action",appendAction:"{0} appended action",otp:"Please enter OTP character {0}"},fileInput:{counter:"{0} files",counterSize:"{0} files ({1} in total)"},timePicker:{am:"AM",pm:"PM",title:"Select Time"},pagination:{ariaLabel:{root:"Pagination Navigation",next:"Next page",previous:"Previous page",page:"Go to page {0}",currentPage:"Page {0}, Current page",first:"First page",last:"Last page"}},stepper:{next:"Next",prev:"Previous"},rating:{ariaLabel:{item:"Rating {0} of {1}"}},loading:"Loading...",infiniteScroll:{loadMore:"Load more",empty:"No more"}},tf="$vuetify.",nf=(e,t)=>e.replace(/\{(\d+)\}/g,(n,r)=>String(t[+r])),Yv=(e,t,n)=>function(r){for(var s=arguments.length,o=new Array(s>1?s-1:0),a=1;anew Intl.NumberFormat([e.value,t.value],r).format(n)}function wi(e,t,n){const r=Na(e,t,e[t]??n.value);return r.value=e[t]??n.value,Te(n,s=>{e[t]==null&&(r.value=n.value)}),r}function Hv(e){return t=>{const n=wi(t,"locale",e.current),r=wi(t,"fallback",e.fallback),s=wi(t,"messages",e.messages);return{name:"vuetify",current:n,fallback:r,messages:s,t:Yv(n,r,s),n:Bv(n,r),provide:Hv({current:n,fallback:r,messages:s})}}}function a1(e){const t=Ut(e?.locale??"en"),n=Ut(e?.fallback??"en"),r=oe({en:o1,...e?.messages});return{name:"vuetify",current:t,fallback:n,messages:r,t:Yv(t,n,r),n:Bv(t,n),provide:Hv({current:t,fallback:n,messages:r})}}const oa=Symbol.for("vuetify:locale");function i1(e){return e.name!=null}function l1(e){const t=e?.adapter&&i1(e?.adapter)?e?.adapter:a1(e),n=f1(t,e);return{...t,...n}}function u1(){const e=Pe(oa);if(!e)throw new Error("[Vuetify] Could not find injected locale instance");return e}function c1(){return{af:!1,ar:!0,bg:!1,ca:!1,ckb:!1,cs:!1,de:!1,el:!1,en:!1,es:!1,et:!1,fa:!0,fi:!1,fr:!1,hr:!1,hu:!1,he:!0,id:!1,it:!1,ja:!1,km:!1,ko:!1,lv:!1,lt:!1,nl:!1,no:!1,pl:!1,pt:!1,ro:!1,ru:!1,sk:!1,sl:!1,srCyrl:!1,srLatn:!1,sv:!1,th:!1,tr:!1,az:!1,uk:!1,vi:!1,zhHans:!1,zhHant:!1}}function f1(e,t){const n=oe(t?.rtl??c1()),r=w(()=>n.value[e.current.value]??!1);return{isRtl:r,rtl:n,rtlClasses:w(()=>`v-locale--is-${r.value?"rtl":"ltr"}`)}}function Fa(){const e=Pe(oa);if(!e)throw new Error("[Vuetify] Could not find injected rtl instance");return{isRtl:e.isRtl,rtlClasses:e.rtlClasses}}const Ya={"001":1,AD:1,AE:6,AF:6,AG:0,AI:1,AL:1,AM:1,AN:1,AR:1,AS:0,AT:1,AU:1,AX:1,AZ:1,BA:1,BD:0,BE:1,BG:1,BH:6,BM:1,BN:1,BR:0,BS:0,BT:0,BW:0,BY:1,BZ:0,CA:0,CH:1,CL:1,CM:1,CN:1,CO:0,CR:1,CY:1,CZ:1,DE:1,DJ:6,DK:1,DM:0,DO:0,DZ:6,EC:1,EE:1,EG:6,ES:1,ET:0,FI:1,FJ:1,FO:1,FR:1,GB:1,"GB-alt-variant":0,GE:1,GF:1,GP:1,GR:1,GT:0,GU:0,HK:0,HN:0,HR:1,HU:1,ID:0,IE:1,IL:0,IN:0,IQ:6,IR:6,IS:1,IT:1,JM:0,JO:6,JP:0,KE:0,KG:1,KH:0,KR:0,KW:6,KZ:1,LA:0,LB:1,LI:1,LK:1,LT:1,LU:1,LV:1,LY:6,MC:1,MD:1,ME:1,MH:0,MK:1,MM:0,MN:1,MO:0,MQ:1,MT:0,MV:5,MX:0,MY:1,MZ:0,NI:0,NL:1,NO:1,NP:0,NZ:1,OM:6,PA:0,PE:0,PH:0,PK:0,PL:1,PR:0,PT:0,PY:0,QA:6,RE:1,RO:1,RS:1,RU:1,SA:0,SD:6,SE:1,SG:0,SI:1,SK:1,SM:1,SV:0,SY:6,TH:0,TJ:1,TM:1,TR:1,TT:0,TW:0,UA:1,UM:0,US:0,UY:1,UZ:1,VA:1,VE:0,VI:0,VN:1,WS:0,XK:1,YE:0,ZA:0,ZW:0};function d1(e,t,n){const r=[];let s=[];const o=jv(e),a=Vv(e),i=n??Ya[t.slice(-2).toUpperCase()]??0,l=(o.getDay()-i+7)%7,u=(a.getDay()-i+7)%7;for(let c=0;c0&&r.push(s),r}function h1(e,t,n){const r=n??Ya[t.slice(-2).toUpperCase()]??0,s=new Date(e);for(;s.getDay()!==r;)s.setDate(s.getDate()-1);return s}function v1(e,t){const n=new Date(e),r=((Ya[t.slice(-2).toUpperCase()]??0)+6)%7;for(;n.getDay()!==r;)n.setDate(n.getDate()+1);return n}function jv(e){return new Date(e.getFullYear(),e.getMonth(),1)}function Vv(e){return new Date(e.getFullYear(),e.getMonth()+1,0)}function m1(e){const t=e.split("-").map(Number);return new Date(t[0],t[1]-1,t[2])}const p1=/^([12]\d{3}-([1-9]|0[1-9]|1[0-2])-([1-9]|0[1-9]|[12]\d|3[01]))$/;function Wv(e){if(e==null)return new Date;if(e instanceof Date)return e;if(typeof e=="string"){let t;if(p1.test(e))return m1(e);if(t=Date.parse(e),!isNaN(t))return new Date(t)}return null}const rf=new Date(2e3,0,2);function g1(e,t){const n=t??Ya[e.slice(-2).toUpperCase()]??0;return Ev(7).map(r=>{const s=new Date(rf);return s.setDate(rf.getDate()+n+r),new Intl.DateTimeFormat(e,{weekday:"narrow"}).format(s)})}function y1(e,t,n,r){const s=Wv(e)??new Date,o=r?.[t];if(typeof o=="function")return o(s,t,n);let a={};switch(t){case"fullDate":a={year:"numeric",month:"long",day:"numeric"};break;case"fullDateWithWeekday":a={weekday:"long",year:"numeric",month:"long",day:"numeric"};break;case"normalDate":const i=s.getDate(),l=new Intl.DateTimeFormat(n,{month:"long"}).format(s);return`${i} ${l}`;case"normalDateWithWeekday":a={weekday:"short",day:"numeric",month:"short"};break;case"shortDate":a={month:"short",day:"numeric"};break;case"year":a={year:"numeric"};break;case"month":a={month:"long"};break;case"monthShort":a={month:"short"};break;case"monthAndYear":a={month:"long",year:"numeric"};break;case"monthAndDate":a={month:"long",day:"numeric"};break;case"weekday":a={weekday:"long"};break;case"weekdayShort":a={weekday:"short"};break;case"dayOfMonth":return new Intl.NumberFormat(n).format(s.getDate());case"hours12h":a={hour:"numeric",hour12:!0};break;case"hours24h":a={hour:"numeric",hour12:!1};break;case"minutes":a={minute:"numeric"};break;case"seconds":a={second:"numeric"};break;case"fullTime":a={hour:"numeric",minute:"numeric",second:"numeric",hour12:!0};break;case"fullTime12h":a={hour:"numeric",minute:"numeric",second:"numeric",hour12:!0};break;case"fullTime24h":a={hour:"numeric",minute:"numeric",second:"numeric",hour12:!1};break;case"fullDateTime":a={year:"numeric",month:"long",day:"numeric",hour:"numeric",minute:"numeric",second:"numeric",hour12:!0};break;case"fullDateTime12h":a={year:"numeric",month:"long",day:"numeric",hour:"numeric",minute:"numeric",second:"numeric",hour12:!0};break;case"fullDateTime24h":a={year:"numeric",month:"long",day:"numeric",hour:"numeric",minute:"numeric",second:"numeric",hour12:!1};break;case"keyboardDate":a={year:"numeric",month:"2-digit",day:"2-digit"};break;case"keyboardDateTime":a={year:"numeric",month:"2-digit",day:"2-digit",hour:"numeric",minute:"numeric",second:"numeric",hour12:!1};break;case"keyboardDateTime12h":a={year:"numeric",month:"2-digit",day:"2-digit",hour:"numeric",minute:"numeric",second:"numeric",hour12:!0};break;case"keyboardDateTime24h":a={year:"numeric",month:"2-digit",day:"2-digit",hour:"numeric",minute:"numeric",second:"numeric",hour12:!1};break;default:a=o??{timeZone:"UTC",timeZoneName:"short"}}return new Intl.DateTimeFormat(n,a).format(s)}function b1(e,t){const n=e.toJsDate(t),r=n.getFullYear(),s=Hc(String(n.getMonth()+1),2,"0"),o=Hc(String(n.getDate()),2,"0");return`${r}-${s}-${o}`}function w1(e){const[t,n,r]=e.split("-").map(Number);return new Date(t,n-1,r)}function _1(e,t){const n=new Date(e);return n.setMinutes(n.getMinutes()+t),n}function D1(e,t){const n=new Date(e);return n.setHours(n.getHours()+t),n}function C1(e,t){const n=new Date(e);return n.setDate(n.getDate()+t),n}function S1(e,t){const n=new Date(e);return n.setDate(n.getDate()+t*7),n}function $1(e,t){const n=new Date(e);return n.setDate(1),n.setMonth(n.getMonth()+t),n}function T1(e){return e.getFullYear()}function E1(e){return e.getMonth()}function O1(e){return e.getDate()}function M1(e){return new Date(e.getFullYear(),e.getMonth()+1,1)}function x1(e){return new Date(e.getFullYear(),e.getMonth()-1,1)}function k1(e){return e.getHours()}function P1(e){return e.getMinutes()}function A1(e){return new Date(e.getFullYear(),0,1)}function I1(e){return new Date(e.getFullYear(),11,31)}function L1(e,t){return aa(e,t[0])&&F1(e,t[1])}function R1(e){const t=new Date(e);return t instanceof Date&&!isNaN(t.getTime())}function aa(e,t){return e.getTime()>t.getTime()}function N1(e,t){return aa(rl(e),rl(t))}function F1(e,t){return e.getTime(){n.locale=e.locale[r]??r??n.locale}),n}const Ba=["sm","md","lg","xl","xxl"],sl=Symbol.for("vuetify:display"),af={mobileBreakpoint:"lg",thresholds:{xs:0,sm:600,md:960,lg:1280,xl:1920,xxl:2560}},Q1=function(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:af;return at(af,e)};function lf(e){return ot&&!e?window.innerWidth:typeof e=="object"&&e.clientWidth||0}function uf(e){return ot&&!e?window.innerHeight:typeof e=="object"&&e.clientHeight||0}function cf(e){const t=ot&&!e?window.navigator.userAgent:"ssr";function n(v){return!!t.match(v)}const r=n(/android/i),s=n(/iphone|ipad|ipod/i),o=n(/cordova/i),a=n(/electron/i),i=n(/chrome/i),l=n(/edge/i),u=n(/firefox/i),c=n(/opera/i),f=n(/win/i),d=n(/mac/i),h=n(/linux/i);return{android:r,ios:s,cordova:o,electron:a,chrome:i,edge:l,firefox:u,opera:c,win:f,mac:d,linux:h,touch:D0,ssr:t==="ssr"}}function ew(e,t){const{thresholds:n,mobileBreakpoint:r}=Q1(e),s=Ut(uf(t)),o=Ut(cf(t)),a=je({}),i=Ut(lf(t));function l(){s.value=uf(),i.value=lf()}function u(){l(),o.value=cf()}return zn(()=>{const c=i.value=n.xxl,p=c?"xs":f?"sm":d?"md":h?"lg":v?"xl":"xxl",b=typeof r=="number"?r:n[r],S=i.value0&&arguments[0]!==void 0?arguments[0]:{},t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:Kn();const n=Pe(sl);if(!n)throw new Error("Could not find Vuetify display injection");const r=w(()=>{if(e.mobile!=null)return e.mobile;if(!e.mobileBreakpoint)return n.mobile.value;const o=typeof e.mobileBreakpoint=="number"?e.mobileBreakpoint:n.thresholds.value[e.mobileBreakpoint];return n.width.valuet?{[`${t}--mobile`]:r.value}:{});return{...n,displayClasses:s,mobile:r}}const Uv=Symbol.for("vuetify:goto");function zv(){return{container:void 0,duration:300,layout:!1,offset:0,easing:"easeInOutCubic",patterns:{linear:e=>e,easeInQuad:e=>e**2,easeOutQuad:e=>e*(2-e),easeInOutQuad:e=>e<.5?2*e**2:-1+(4-2*e)*e,easeInCubic:e=>e**3,easeOutCubic:e=>--e**3+1,easeInOutCubic:e=>e<.5?4*e**3:(e-1)*(2*e-2)*(2*e-2)+1,easeInQuart:e=>e**4,easeOutQuart:e=>1- --e**4,easeInOutQuart:e=>e<.5?8*e**4:1-8*--e**4,easeInQuint:e=>e**5,easeOutQuint:e=>1+--e**5,easeInOutQuint:e=>e<.5?16*e**5:1+16*--e**5}}}function nw(e){return ou(e)??(document.scrollingElement||document.body)}function ou(e){return typeof e=="string"?document.querySelector(e):Ov(e)}function _i(e,t,n){if(typeof e=="number")return t&&n?-e:e;let r=ou(e),s=0;for(;r;)s+=t?r.offsetLeft:r.offsetTop,r=r.offsetParent;return s}function rw(e,t){return{rtl:t.isRtl,options:at(zv(),e)}}async function ff(e,t,n,r){const s=n?"scrollLeft":"scrollTop",o=at(r?.options??zv(),t),a=r?.rtl.value,i=(typeof e=="number"?e:ou(e))??0,l=o.container==="parent"&&i instanceof HTMLElement?i.parentElement:nw(o.container),u=typeof o.easing=="function"?o.easing:o.patterns[o.easing];if(!u)throw new TypeError(`Easing function "${o.easing}" not found.`);let c;if(typeof i=="number")c=_i(i,n,a);else if(c=_i(i,n,a)-_i(l,n,a),o.layout){const v=window.getComputedStyle(i).getPropertyValue("--v-layout-top");v&&(c-=parseInt(v,10))}c+=o.offset,c=sw(l,c,!!a,!!n);const f=l[s]??0;if(c===f)return Promise.resolve(c);const d=performance.now();return new Promise(h=>requestAnimationFrame(function v(m){const b=(m-d)/o.duration,S=Math.floor(f+(c-f)*u(na(b,0,1)));if(l[s]=S,b>=1&&Math.abs(S-l[s])<10)return h(c);if(b>2)return h(l[s]);requestAnimationFrame(v)}))}function HY(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};const t=Pe(Uv),{isRtl:n}=Fa();if(!t)throw new Error("[Vuetify] Could not find injected goto instance");const r={...t,rtl:w(()=>t.rtl.value||n.value)};async function s(o,a){return ff(o,at(e,a),!1,r)}return s.horizontal=async(o,a)=>ff(o,at(e,a),!0,r),s}function sw(e,t,n,r){const{scrollWidth:s,scrollHeight:o}=e,[a,i]=e===document.scrollingElement?[window.innerWidth,window.innerHeight]:[e.offsetWidth,e.offsetHeight];let l,u;return r?n?(l=-(s-a),u=0):(l=0,u=s-a):(l=0,u=o+-i),Math.max(Math.min(t,u),l)}const ow={collapse:"mdi-chevron-up",complete:"mdi-check",cancel:"mdi-close-circle",close:"mdi-close",delete:"mdi-close-circle",clear:"mdi-close-circle",success:"mdi-check-circle",info:"mdi-information",warning:"mdi-alert-circle",error:"mdi-close-circle",prev:"mdi-chevron-left",next:"mdi-chevron-right",checkboxOn:"mdi-checkbox-marked",checkboxOff:"mdi-checkbox-blank-outline",checkboxIndeterminate:"mdi-minus-box",delimiter:"mdi-circle",sortAsc:"mdi-arrow-up",sortDesc:"mdi-arrow-down",expand:"mdi-chevron-down",menu:"mdi-menu",subgroup:"mdi-menu-down",dropdown:"mdi-menu-down",radioOn:"mdi-radiobox-marked",radioOff:"mdi-radiobox-blank",edit:"mdi-pencil",ratingEmpty:"mdi-star-outline",ratingFull:"mdi-star",ratingHalf:"mdi-star-half-full",loading:"mdi-cached",first:"mdi-page-first",last:"mdi-page-last",unfold:"mdi-unfold-more-horizontal",file:"mdi-paperclip",plus:"mdi-plus",minus:"mdi-minus",calendar:"mdi-calendar",treeviewCollapse:"mdi-menu-down",treeviewExpand:"mdi-menu-right",eyeDropper:"mdi-eyedropper"},aw={component:e=>lo(Gv,{...e,class:"mdi"})},zs=[String,Function,Object,Array],ol=Symbol.for("vuetify:icons"),Ha=$e({icon:{type:zs},tag:{type:String,required:!0}},"icon"),df=At()({name:"VComponentIcon",props:Ha(),setup(e,t){let{slots:n}=t;return()=>{const r=e.icon;return L(e.tag,null,{default:()=>[e.icon?L(r,null,null):n.default?.()]})}}}),Kv=co({name:"VSvgIcon",inheritAttrs:!1,props:Ha(),setup(e,t){let{attrs:n}=t;return()=>L(e.tag,qt(n,{style:null}),{default:()=>[L("svg",{class:"v-icon__svg",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",role:"img","aria-hidden":"true"},[Array.isArray(e.icon)?e.icon.map(r=>Array.isArray(r)?L("path",{d:r[0],"fill-opacity":r[1]},null):L("path",{d:r},null)):L("path",{d:e.icon},null)])]})}});co({name:"VLigatureIcon",props:Ha(),setup(e){return()=>L(e.tag,null,{default:()=>[e.icon]})}});const Gv=co({name:"VClassIcon",props:Ha(),setup(e){return()=>L(e.tag,{class:e.icon},null)}});function iw(){return{svg:{component:Kv},class:{component:Gv}}}function lw(e){const t=iw(),n=e?.defaultSet??"mdi";return n==="mdi"&&!t.mdi&&(t.mdi=aw),at({defaultSet:n,sets:t,aliases:{...ow,vuetify:["M8.2241 14.2009L12 21L22 3H14.4459L8.2241 14.2009Z",["M7.26303 12.4733L7.00113 12L2 3H12.5261C12.5261 3 12.5261 3 12.5261 3L7.26303 12.4733Z",.6]],"vuetify-outline":"svg:M7.26 12.47 12.53 3H2L7.26 12.47ZM14.45 3 8.22 14.2 12 21 22 3H14.45ZM18.6 5 12 16.88 10.51 14.2 15.62 5ZM7.26 8.35 5.4 5H9.13L7.26 8.35Z","vuetify-play":["m6.376 13.184-4.11-7.192C1.505 4.66 2.467 3 4.003 3h8.532l-.953 1.576-.006.01-.396.677c-.429.732-.214 1.507.194 2.015.404.503 1.092.878 1.869.806a3.72 3.72 0 0 1 1.005.022c.276.053.434.143.523.237.138.146.38.635-.25 2.09-.893 1.63-1.553 1.722-1.847 1.677-.213-.033-.468-.158-.756-.406a4.95 4.95 0 0 1-.8-.927c-.39-.564-1.04-.84-1.66-.846-.625-.006-1.316.27-1.693.921l-.478.826-.911 1.506Z",["M9.093 11.552c.046-.079.144-.15.32-.148a.53.53 0 0 1 .43.207c.285.414.636.847 1.046 1.2.405.35.914.662 1.516.754 1.334.205 2.502-.698 3.48-2.495l.014-.028.013-.03c.687-1.574.774-2.852-.005-3.675-.37-.391-.861-.586-1.333-.676a5.243 5.243 0 0 0-1.447-.044c-.173.016-.393-.073-.54-.257-.145-.18-.127-.316-.082-.392l.393-.672L14.287 3h5.71c1.536 0 2.499 1.659 1.737 2.992l-7.997 13.996c-.768 1.344-2.706 1.344-3.473 0l-3.037-5.314 1.377-2.278.004-.006.004-.007.481-.831Z",.6]]}},e)}const uw=e=>{const t=Pe(ol);if(!t)throw new Error("Missing Vuetify Icons provide!");return{iconData:w(()=>{const r=A(e);if(!r)return{component:df};let s=r;if(typeof s=="string"&&(s=s.trim(),s.startsWith("$")&&(s=t.aliases?.[s.slice(1)])),Array.isArray(s))return{component:Kv,icon:s};if(typeof s!="string")return{component:df,icon:s};const o=Object.keys(t.sets).find(l=>typeof s=="string"&&s.startsWith(`${l}:`)),a=o?s.slice(o.length+1):s;return{component:t.sets[o??t.defaultSet].component,icon:a}})}},Ks=Symbol.for("vuetify:theme"),wr=$e({theme:String},"theme");function hf(){return{defaultTheme:"light",variations:{colors:[],lighten:0,darken:0},themes:{light:{dark:!1,colors:{background:"#FFFFFF",surface:"#FFFFFF","surface-bright":"#FFFFFF","surface-light":"#EEEEEE","surface-variant":"#424242","on-surface-variant":"#EEEEEE",primary:"#1867C0","primary-darken-1":"#1F5592",secondary:"#48A9A6","secondary-darken-1":"#018786",error:"#B00020",info:"#2196F3",success:"#4CAF50",warning:"#FB8C00"},variables:{"border-color":"#000000","border-opacity":.12,"high-emphasis-opacity":.87,"medium-emphasis-opacity":.6,"disabled-opacity":.38,"idle-opacity":.04,"hover-opacity":.04,"focus-opacity":.12,"selected-opacity":.08,"activated-opacity":.12,"pressed-opacity":.12,"dragged-opacity":.08,"theme-kbd":"#212529","theme-on-kbd":"#FFFFFF","theme-code":"#F5F5F5","theme-on-code":"#000000"}},dark:{dark:!0,colors:{background:"#121212",surface:"#212121","surface-bright":"#ccbfd6","surface-light":"#424242","surface-variant":"#a3a3a3","on-surface-variant":"#424242",primary:"#2196F3","primary-darken-1":"#277CC1",secondary:"#54B6B2","secondary-darken-1":"#48A9A6",error:"#CF6679",info:"#2196F3",success:"#4CAF50",warning:"#FB8C00"},variables:{"border-color":"#FFFFFF","border-opacity":.12,"high-emphasis-opacity":1,"medium-emphasis-opacity":.7,"disabled-opacity":.5,"idle-opacity":.1,"hover-opacity":.04,"focus-opacity":.12,"selected-opacity":.08,"activated-opacity":.12,"pressed-opacity":.16,"dragged-opacity":.08,"theme-kbd":"#212529","theme-on-kbd":"#FFFFFF","theme-code":"#343434","theme-on-code":"#CCCCCC"}}}}}function cw(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:hf();const t=hf();if(!e)return{...t,isDisabled:!0};const n={};for(const[r,s]of Object.entries(e.themes??{})){const o=s.dark||r==="dark"?t.themes?.dark:t.themes?.light;n[r]=at(o,s)}return at(t,{...e,themes:n})}function fw(e){const t=cw(e),n=oe(t.defaultTheme),r=oe(t.themes),s=w(()=>{const c={};for(const[f,d]of Object.entries(r.value)){const h=c[f]={...d,colors:{...d.colors}};if(t.variations)for(const v of t.variations.colors){const m=h.colors[v];if(m)for(const p of["lighten","darken"]){const b=p==="lighten"?J0:X0;for(const S of Ev(t.variations[p],1))h.colors[`${v}-${p}-${S}`]=G0(b(nn(m),S))}}for(const v of Object.keys(h.colors)){if(/^on-[a-z]/.test(v)||h.colors[`on-${v}`])continue;const m=`on-${v}`,p=nn(h.colors[v]);h.colors[m]=Rv(p)}}return c}),o=w(()=>s.value[n.value]),a=w(()=>{const c=[];o.value?.dark&&nr(c,":root",["color-scheme: dark"]),nr(c,":root",vf(o.value));for(const[v,m]of Object.entries(s.value))nr(c,`.v-theme--${v}`,[`color-scheme: ${m.dark?"dark":"normal"}`,...vf(m)]);const f=[],d=[],h=new Set(Object.values(s.value).flatMap(v=>Object.keys(v.colors)));for(const v of h)/^on-[a-z]/.test(v)?nr(d,`.${v}`,[`color: rgb(var(--v-theme-${v})) !important`]):(nr(f,`.bg-${v}`,[`--v-theme-overlay-multiplier: var(--v-theme-${v}-overlay-multiplier)`,`background-color: rgb(var(--v-theme-${v})) !important`,`color: rgb(var(--v-theme-on-${v})) !important`]),nr(d,`.text-${v}`,[`color: rgb(var(--v-theme-${v})) !important`]),nr(d,`.border-${v}`,[`--v-border-color: var(--v-theme-${v})`]));return c.push(...f,...d),c.map((v,m)=>m===0?v:` ${v}`).join("")});function i(){return{style:[{children:a.value,id:"vuetify-theme-stylesheet",nonce:t.cspNonce||!1}]}}function l(c){if(t.isDisabled)return;const f=c._context.provides.usehead;if(f)if(f.push){const d=f.push(i);ot&&Te(a,()=>{d.patch(i)})}else ot?(f.addHeadObjs(w(i)),zn(()=>f.updateDOM())):f.addHeadObjs(i());else{let h=function(){if(typeof document<"u"&&!d){const v=document.createElement("style");v.type="text/css",v.id="vuetify-theme-stylesheet",t.cspNonce&&v.setAttribute("nonce",t.cspNonce),d=v,document.head.appendChild(d)}d&&(d.innerHTML=a.value)},d=ot?document.getElementById("vuetify-theme-stylesheet"):null;ot?Te(a,h,{immediate:!0}):h()}}const u=w(()=>t.isDisabled?void 0:`v-theme--${n.value}`);return{install:l,isDisabled:t.isDisabled,name:n,themes:r,current:o,computedThemes:s,themeClasses:u,styles:a,global:{name:n,current:o}}}function _r(e){St("provideTheme");const t=Pe(Ks,null);if(!t)throw new Error("Could not find Vuetify theme injection");const n=w(()=>e.theme??t.name.value),r=w(()=>t.themes.value[n.value]),s=w(()=>t.isDisabled?void 0:`v-theme--${n.value}`),o={...t,name:n,current:r,themeClasses:s};return Pt(Ks,o),o}function dw(){St("useTheme");const e=Pe(Ks,null);if(!e)throw new Error("Could not find Vuetify theme injection");return e}function nr(e,t,n){e.push(`${t} { +**/const Fb="http://www.w3.org/2000/svg",Yb="http://www.w3.org/1998/Math/MathML",hn=typeof document<"u"?document:null,Dc=hn&&hn.createElement("template"),Bb={insert:(e,t,n)=>{t.insertBefore(e,n||null)},remove:e=>{const t=e.parentNode;t&&t.removeChild(e)},createElement:(e,t,n,r)=>{const s=t==="svg"?hn.createElementNS(Fb,e):t==="mathml"?hn.createElementNS(Yb,e):n?hn.createElement(e,{is:n}):hn.createElement(e);return e==="select"&&r&&r.multiple!=null&&s.setAttribute("multiple",r.multiple),s},createText:e=>hn.createTextNode(e),createComment:e=>hn.createComment(e),setText:(e,t)=>{e.nodeValue=t},setElementText:(e,t)=>{e.textContent=t},parentNode:e=>e.parentNode,nextSibling:e=>e.nextSibling,querySelector:e=>hn.querySelector(e),setScopeId(e,t){e.setAttribute(t,"")},insertStaticContent(e,t,n,r,s,o){const a=n?n.previousSibling:t.lastChild;if(s&&(s===o||s.nextSibling))for(;t.insertBefore(s.cloneNode(!0),n),!(s===o||!(s=s.nextSibling)););else{Dc.innerHTML=r==="svg"?`${e}`:r==="mathml"?`${e}`:e;const i=Dc.content;if(r==="svg"||r==="mathml"){const l=i.firstChild;for(;l.firstChild;)i.appendChild(l.firstChild);i.removeChild(l)}t.insertBefore(i,n)}return[a?a.nextSibling:t.firstChild,n?n.previousSibling:t.lastChild]}},En="transition",ys="animation",Gr=Symbol("_vtc"),uo=(e,{slots:t})=>lo(ky,gv(e),t);uo.displayName="Transition";const pv={name:String,type:String,css:{type:Boolean,default:!0},duration:[String,Number,Object],enterFromClass:String,enterActiveClass:String,enterToClass:String,appearFromClass:String,appearActiveClass:String,appearToClass:String,leaveFromClass:String,leaveActiveClass:String,leaveToClass:String},Hb=uo.props=Ke({},Fh,pv),tr=(e,t=[])=>{le(e)?e.forEach(n=>n(...t)):e&&e(...t)},Cc=e=>e?le(e)?e.some(t=>t.length>1):e.length>1:!1;function gv(e){const t={};for(const O in e)O in pv||(t[O]=e[O]);if(e.css===!1)return t;const{name:n="v",type:r,duration:s,enterFromClass:o=`${n}-enter-from`,enterActiveClass:a=`${n}-enter-active`,enterToClass:i=`${n}-enter-to`,appearFromClass:l=o,appearActiveClass:u=a,appearToClass:c=i,leaveFromClass:f=`${n}-leave-from`,leaveActiveClass:d=`${n}-leave-active`,leaveToClass:h=`${n}-leave-to`}=e,v=jb(s),m=v&&v[0],p=v&&v[1],{onBeforeEnter:b,onEnter:S,onEnterCancelled:T,onLeave:M,onLeaveCancelled:D,onBeforeAppear:C=b,onAppear:E=S,onAppearCancelled:P=T}=t,$=(O,W,re)=>{kn(O,W?c:i),kn(O,W?u:a),re&&re()},I=(O,W)=>{O._isLeaving=!1,kn(O,f),kn(O,h),kn(O,d),W&&W()},j=O=>(W,re)=>{const X=O?E:S,ee=()=>$(W,O,re);tr(X,[W,ee]),Sc(()=>{kn(W,O?l:o),dn(W,O?c:i),Cc(X)||$c(W,r,m,ee)})};return Ke(t,{onBeforeEnter(O){tr(b,[O]),dn(O,o),dn(O,a)},onBeforeAppear(O){tr(C,[O]),dn(O,l),dn(O,u)},onEnter:j(!1),onAppear:j(!0),onLeave(O,W){O._isLeaving=!0;const re=()=>I(O,W);dn(O,f),dn(O,d),bv(),Sc(()=>{O._isLeaving&&(kn(O,f),dn(O,h),Cc(M)||$c(O,r,p,re))}),tr(M,[O,re])},onEnterCancelled(O){$(O,!1),tr(T,[O])},onAppearCancelled(O){$(O,!0),tr(P,[O])},onLeaveCancelled(O){I(O),tr(D,[O])}})}function jb(e){if(e==null)return null;if(Ie(e))return[pi(e.enter),pi(e.leave)];{const t=pi(e);return[t,t]}}function pi(e){return ch(e)}function dn(e,t){t.split(/\s+/).forEach(n=>n&&e.classList.add(n)),(e[Gr]||(e[Gr]=new Set)).add(t)}function kn(e,t){t.split(/\s+/).forEach(r=>r&&e.classList.remove(r));const n=e[Gr];n&&(n.delete(t),n.size||(e[Gr]=void 0))}function Sc(e){requestAnimationFrame(()=>{requestAnimationFrame(e)})}let Vb=0;function $c(e,t,n,r){const s=e._endId=++Vb,o=()=>{s===e._endId&&r()};if(n)return setTimeout(o,n);const{type:a,timeout:i,propCount:l}=yv(e,t);if(!a)return r();const u=a+"end";let c=0;const f=()=>{e.removeEventListener(u,d),o()},d=h=>{h.target===e&&++c>=l&&f()};setTimeout(()=>{c(n[v]||"").split(", "),s=r(`${En}Delay`),o=r(`${En}Duration`),a=Tc(s,o),i=r(`${ys}Delay`),l=r(`${ys}Duration`),u=Tc(i,l);let c=null,f=0,d=0;t===En?a>0&&(c=En,f=a,d=o.length):t===ys?u>0&&(c=ys,f=u,d=l.length):(f=Math.max(a,u),c=f>0?a>u?En:ys:null,d=c?c===En?o.length:l.length:0);const h=c===En&&/\b(transform|all)(,|$)/.test(r(`${En}Property`).toString());return{type:c,timeout:f,propCount:d,hasTransform:h}}function Tc(e,t){for(;e.lengthEc(n)+Ec(e[r])))}function Ec(e){return e==="auto"?0:Number(e.slice(0,-1).replace(",","."))*1e3}function bv(){return document.body.offsetHeight}function Wb(e,t,n){const r=e[Gr];r&&(t=(t?[t,...r]:[...r]).join(" ")),t==null?e.removeAttribute("class"):n?e.setAttribute("class",t):e.className=t}const ea=Symbol("_vod"),wv=Symbol("_vsh"),_Y={beforeMount(e,{value:t},{transition:n}){e[ea]=e.style.display==="none"?"":e.style.display,n&&t?n.beforeEnter(e):bs(e,t)},mounted(e,{value:t},{transition:n}){n&&t&&n.enter(e)},updated(e,{value:t,oldValue:n},{transition:r}){!t!=!n&&(r?t?(r.beforeEnter(e),bs(e,!0),r.enter(e)):r.leave(e,()=>{bs(e,!1)}):bs(e,t))},beforeUnmount(e,{value:t}){bs(e,t)}};function bs(e,t){e.style.display=t?e[ea]:"none",e[wv]=!t}const _v=Symbol("");function Ub(e){const t=os();if(!t)return;const n=t.ut=(s=e(t.proxy))=>{Array.from(document.querySelectorAll(`[data-v-owner="${t.uid}"]`)).forEach(o=>Qi(o,s))},r=()=>{const s=e(t.proxy);Xi(t.subTree,s),n(s)};Gt(()=>{cb(r);const s=new MutationObserver(r);s.observe(t.subTree.el.parentNode,{childList:!0}),ss(()=>s.disconnect())})}function Xi(e,t){if(e.shapeFlag&128){const n=e.suspense;e=n.activeBranch,n.pendingBranch&&!n.isHydrating&&n.effects.push(()=>{Xi(n.activeBranch,t)})}for(;e.component;)e=e.component.subTree;if(e.shapeFlag&1&&e.el)Qi(e.el,t);else if(e.type===be)e.children.forEach(n=>Xi(n,t));else if(e.type===Lo){let{el:n,anchor:r}=e;for(;n&&(Qi(n,t),n!==r);)n=n.nextSibling}}function Qi(e,t){if(e.nodeType===1){const n=e.style;let r="";for(const s in t)n.setProperty(`--${s}`,t[s]),r+=`--${s}: ${t[s]};`;n[_v]=r}}const zb=/(^|;)\s*display\s*:/;function Kb(e,t,n){const r=e.style,s=Ve(n);let o=!1;if(n&&!s){if(t)if(Ve(t))for(const a of t.split(";")){const i=a.slice(0,a.indexOf(":")).trim();n[i]==null&&No(r,i,"")}else for(const a in t)n[a]==null&&No(r,a,"");for(const a in n)a==="display"&&(o=!0),No(r,a,n[a])}else if(s){if(t!==n){const a=r[_v];a&&(n+=";"+a),r.cssText=n,o=zb.test(n)}}else t&&e.removeAttribute("style");ea in e&&(e[ea]=o?r.display:"",e[wv]&&(r.display="none"))}const Oc=/\s*!important$/;function No(e,t,n){if(le(n))n.forEach(r=>No(e,t,r));else if(n==null&&(n=""),t.startsWith("--"))e.setProperty(t,n);else{const r=Gb(e,t);Oc.test(n)?e.setProperty(_n(r),n.replace(Oc,""),"important"):e[r]=n}}const Mc=["Webkit","Moz","ms"],gi={};function Gb(e,t){const n=gi[t];if(n)return n;let r=kt(t);if(r!=="filter"&&r in e)return gi[t]=r;r=Dn(r);for(let s=0;syi||(e0.then(()=>yi=0),yi=Date.now());function n0(e,t){const n=r=>{if(!r._vts)r._vts=Date.now();else if(r._vts<=n.attached)return;Nt(r0(r,n.value),t,5,[r])};return n.value=e,n.attached=t0(),n}function r0(e,t){if(le(t)){const n=e.stopImmediatePropagation;return e.stopImmediatePropagation=()=>{n.call(e),e._stopped=!0},t.map(r=>s=>!s._stopped&&r&&r(s))}else return t}const Ic=e=>e.charCodeAt(0)===111&&e.charCodeAt(1)===110&&e.charCodeAt(2)>96&&e.charCodeAt(2)<123,s0=(e,t,n,r,s,o)=>{const a=s==="svg";t==="class"?Wb(e,r,a):t==="style"?Kb(e,n,r):Ca(t)?Ml(t)||Xb(e,t,n,r,o):(t[0]==="."?(t=t.slice(1),!0):t[0]==="^"?(t=t.slice(1),!1):o0(e,t,r,a))?(qb(e,t,r),!e.tagName.includes("-")&&(t==="value"||t==="checked"||t==="selected")&&xc(e,t,r,a,o,t!=="value")):(t==="true-value"?e._trueValue=r:t==="false-value"&&(e._falseValue=r),xc(e,t,r,a))};function o0(e,t,n,r){if(r)return!!(t==="innerHTML"||t==="textContent"||t in e&&Ic(t)&&ce(n));if(t==="spellcheck"||t==="draggable"||t==="translate"||t==="form"||t==="list"&&e.tagName==="INPUT"||t==="type"&&e.tagName==="TEXTAREA")return!1;if(t==="width"||t==="height"){const s=e.tagName;if(s==="IMG"||s==="VIDEO"||s==="CANVAS"||s==="SOURCE")return!1}return Ic(t)&&Ve(n)?!1:t in e}const Dv=new WeakMap,Cv=new WeakMap,ta=Symbol("_moveCb"),Lc=Symbol("_enterCb"),Sv={name:"TransitionGroup",props:Ke({},Hb,{tag:String,moveClass:String}),setup(e,{slots:t}){const n=os(),r=Nh();let s,o;return Kl(()=>{if(!s.length)return;const a=e.moveClass||`${e.name||"v"}-move`;if(!c0(s[0].el,n.vnode.el,a))return;s.forEach(i0),s.forEach(l0);const i=s.filter(u0);bv(),i.forEach(l=>{const u=l.el,c=u.style;dn(u,a),c.transform=c.webkitTransform=c.transitionDuration="";const f=u[ta]=d=>{d&&d.target!==u||(!d||/transform$/.test(d.propertyName))&&(u.removeEventListener("transitionend",f),u[ta]=null,kn(u,a))};u.addEventListener("transitionend",f)})}),()=>{const a=ge(e),i=gv(a);let l=a.tag||be;if(s=[],o)for(let u=0;udelete e.mode;Sv.props;const DY=Sv;function i0(e){const t=e.el;t[ta]&&t[ta](),t[Lc]&&t[Lc]()}function l0(e){Cv.set(e,e.el.getBoundingClientRect())}function u0(e){const t=Dv.get(e),n=Cv.get(e),r=t.left-n.left,s=t.top-n.top;if(r||s){const o=e.el.style;return o.transform=o.webkitTransform=`translate(${r}px,${s}px)`,o.transitionDuration="0s",e}}function c0(e,t,n){const r=e.cloneNode(),s=e[Gr];s&&s.forEach(i=>{i.split(/\s+/).forEach(l=>l&&r.classList.remove(l))}),n.split(/\s+/).forEach(i=>i&&r.classList.add(i)),r.style.display="none";const o=t.nodeType===1?t:t.parentNode;o.appendChild(r);const{hasTransform:a}=yv(r);return o.removeChild(r),a}const f0=["ctrl","shift","alt","meta"],d0={stop:e=>e.stopPropagation(),prevent:e=>e.preventDefault(),self:e=>e.target!==e.currentTarget,ctrl:e=>!e.ctrlKey,shift:e=>!e.shiftKey,alt:e=>!e.altKey,meta:e=>!e.metaKey,left:e=>"button"in e&&e.button!==0,middle:e=>"button"in e&&e.button!==1,right:e=>"button"in e&&e.button!==2,exact:(e,t)=>f0.some(n=>e[`${n}Key`]&&!t.includes(n))},h0=(e,t)=>{const n=e._withMods||(e._withMods={}),r=t.join(".");return n[r]||(n[r]=(s,...o)=>{for(let a=0;a{const n=e._withKeys||(e._withKeys={}),r=t.join(".");return n[r]||(n[r]=s=>{if(!("key"in s))return;const o=_n(s.key);if(t.some(a=>a===o||v0[a]===o))return e(s)})},m0=Ke({patchProp:s0},Bb);let Nc;function $v(){return Nc||(Nc=sb(m0))}const CY=(...e)=>{$v().render(...e)},p0=(...e)=>{const t=$v().createApp(...e),{mount:n}=t;return t.mount=r=>{const s=y0(r);if(!s)return;const o=t._component;!ce(o)&&!o.render&&!o.template&&(o.template=s.innerHTML),s.innerHTML="";const a=n(s,!1,g0(s));return s instanceof Element&&(s.removeAttribute("v-cloak"),s.setAttribute("data-v-app","")),a},t};function g0(e){if(e instanceof SVGElement)return"svg";if(typeof MathMLElement=="function"&&e instanceof MathMLElement)return"mathml"}function y0(e){return Ve(e)?document.querySelector(e):e}function b0(e,t){let n;function r(){n=Al(),n.run(()=>t.length?t(()=>{n?.stop(),r()}):t())}Te(e,s=>{s&&!n?r():s||(n?.stop(),n=void 0)},{immediate:!0}),Il(()=>{n?.stop()})}const ot=typeof window<"u",w0=ot&&"IntersectionObserver"in window,_0=ot&&("ontouchstart"in window||window.navigator.maxTouchPoints>0);function D0(e,t,n){const r=t.length-1;if(r<0)return e===void 0?n:e;for(let s=0;stu(e[r],t[r]))}function Fc(e,t,n){return e==null||!t||typeof t!="string"?n:e[t]!==void 0?e[t]:(t=t.replace(/\[(\w+)\]/g,".$1"),t=t.replace(/^\./,""),D0(e,t.split("."),n))}function Tv(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0;return Array.from({length:e},(n,r)=>t+r)}function Fe(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"px";if(!(e==null||e===""))return isNaN(+e)?String(e):isFinite(+e)?`${Number(e)}${t}`:void 0}function el(e){return e!==null&&typeof e=="object"&&!Array.isArray(e)}function Ev(e){if(e&&"$el"in e){const t=e.$el;return t?.nodeType===Node.TEXT_NODE?t.nextElementSibling:t}return e}const Yc=Object.freeze({enter:13,tab:9,delete:46,esc:27,space:32,up:38,down:40,left:37,right:39,end:35,home:36,del:46,backspace:8,insert:45,pageup:33,pagedown:34,shift:16});function SY(e){return Object.keys(e)}function bi(e,t){return t.every(n=>e.hasOwnProperty(n))}function C0(e,t){const n={},r=new Set(Object.keys(e));for(const s of t)r.has(s)&&(n[s]=e[s]);return n}function $Y(e,t){const n={...e};return t.forEach(r=>delete n[r]),n}const S0=/^on[^a-z]/,TY=e=>S0.test(e);function $0(e){return e==null?[]:Array.isArray(e)?e:[e]}function na(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0,n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:1;return Math.max(t,Math.min(n,e))}function Bc(e,t){let n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:"0";return e+n.repeat(Math.max(0,t-e.length))}function Hc(e,t){return(arguments.length>2&&arguments[2]!==void 0?arguments[2]:"0").repeat(Math.max(0,t-e.length))+e}function T0(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:1;const n=[];let r=0;for(;r0&&arguments[0]!==void 0?arguments[0]:{},t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},n=arguments.length>2?arguments[2]:void 0;const r={};for(const s in e)r[s]=e[s];for(const s in t){const o=e[s],a=t[s];if(el(o)&&el(a)){r[s]=at(o,a,n);continue}if(Array.isArray(o)&&Array.isArray(a)&&n){r[s]=n(o,a);continue}r[s]=a}return r}function Ov(e){return e.map(t=>t.type===be?Ov(t.children):t).flat()}function cr(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:"";if(cr.cache.has(e))return cr.cache.get(e);const t=e.replace(/[^a-z]/gi,"-").replace(/\B([A-Z])/g,"-$1").toLowerCase();return cr.cache.set(e,t),t}cr.cache=new Map;function xr(e,t){if(!t||typeof t!="object")return[];if(Array.isArray(t))return t.map(n=>xr(e,n)).flat(1);if(t.suspense)return xr(e,t.ssContent);if(Array.isArray(t.children))return t.children.map(n=>xr(e,n)).flat(1);if(t.component){if(Object.getOwnPropertySymbols(t.component.provides).includes(e))return[t.component];if(t.component.subTree)return xr(e,t.component.subTree).flat(1)}return[]}function Mv(e){const t=je({}),n=w(e);return zn(()=>{for(const r in n.value)t[r]=n.value[r]},{flush:"sync"}),no(t)}function ra(e,t){return e.includes(t)}function EY(e){return e[2].toLowerCase()+e.slice(3)}function jc(e,t){return t="on"+Dn(t),!!(e[t]||e[`${t}Once`]||e[`${t}Capture`]||e[`${t}OnceCapture`]||e[`${t}CaptureOnce`])}function OY(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!0;const n=["button","[href]",'input:not([type="hidden"])',"select","textarea","[tabindex]"].map(r=>`${r}${t?':not([tabindex="-1"])':""}:not([disabled])`).join(", ");return[...e.querySelectorAll(n)]}function MY(e,t){if(!(ot&&typeof CSS<"u"&&typeof CSS.supports<"u"&&CSS.supports(`selector(${t})`)))return null;try{return!!e&&e.matches(t)}catch{return null}}function kY(e,t){if(!ot||e===0)return t(),()=>{};const n=window.setTimeout(t,e);return()=>window.clearTimeout(n)}function Vc(e,t){const n=Ut();return zn(()=>{n.value=e()},{flush:"sync",...t}),Ea(n)}function E0(){const e=Ut(),t=n=>{e.value=n};return Object.defineProperty(t,"value",{enumerable:!0,get:()=>e.value,set:n=>e.value=n}),Object.defineProperty(t,"el",{enumerable:!0,get:()=>Ev(e.value)}),t}const kv=["top","bottom"],O0=["start","end","left","right"];function M0(e,t){let[n,r]=e.split(" ");return r||(r=ra(kv,n)?"start":ra(O0,n)?"top":"center"),{side:Wc(n,t),align:Wc(r,t)}}function Wc(e,t){return e==="start"?t?"right":"left":e==="end"?t?"left":"right":e}function xY(e){return{side:{center:"center",top:"bottom",bottom:"top",left:"right",right:"left"}[e.side],align:e.align}}function PY(e){return{side:e.side,align:{center:"center",top:"bottom",bottom:"top",left:"right",right:"left"}[e.align]}}function AY(e){return{side:e.align,align:e.side}}function IY(e){return ra(kv,e.side)?"y":"x"}const Er=2.4,Uc=.2126729,zc=.7151522,Kc=.072175,k0=.55,x0=.58,P0=.57,A0=.62,Eo=.03,Gc=1.45,I0=5e-4,L0=1.25,R0=1.25,qc=.078,Zc=12.82051282051282,Oo=.06,Jc=.001;function Xc(e,t){const n=(e.r/255)**Er,r=(e.g/255)**Er,s=(e.b/255)**Er,o=(t.r/255)**Er,a=(t.g/255)**Er,i=(t.b/255)**Er;let l=n*Uc+r*zc+s*Kc,u=o*Uc+a*zc+i*Kc;if(l<=Eo&&(l+=(Eo-l)**Gc),u<=Eo&&(u+=(Eo-u)**Gc),Math.abs(u-l)l){const f=(u**k0-l**x0)*L0;c=f-Jc?0:f>-qc?f-f*Zc*Oo:f+Oo}return c*100}const sa=.20689655172413793,N0=e=>e>sa**3?Math.cbrt(e):e/(3*sa**2)+4/29,F0=e=>e>sa?e**3:3*sa**2*(e-4/29);function xv(e){const t=N0,n=t(e[1]);return[116*n-16,500*(t(e[0]/.95047)-n),200*(n-t(e[2]/1.08883))]}function Pv(e){const t=F0,n=(e[0]+16)/116;return[t(n+e[1]/500)*.95047,t(n),t(n-e[2]/200)*1.08883]}const Y0=[[3.2406,-1.5372,-.4986],[-.9689,1.8758,.0415],[.0557,-.204,1.057]],B0=e=>e<=.0031308?e*12.92:1.055*e**(1/2.4)-.055,H0=[[.4124,.3576,.1805],[.2126,.7152,.0722],[.0193,.1192,.9505]],j0=e=>e<=.04045?e/12.92:((e+.055)/1.055)**2.4;function Av(e){const t=Array(3),n=B0,r=Y0;for(let s=0;s<3;++s)t[s]=Math.round(na(n(r[s][0]*e[0]+r[s][1]*e[1]+r[s][2]*e[2]))*255);return{r:t[0],g:t[1],b:t[2]}}function nu(e){let{r:t,g:n,b:r}=e;const s=[0,0,0],o=j0,a=H0;t=o(t/255),n=o(n/255),r=o(r/255);for(let i=0;i<3;++i)s[i]=a[i][0]*t+a[i][1]*n+a[i][2]*r;return s}function tl(e){return!!e&&/^(#|var\(--|(rgb|hsl)a?\()/.test(e)}function V0(e){return tl(e)&&!/^((rgb|hsl)a?\()?var\(--/.test(e)}const Qc=/^(?(?:rgb|hsl)a?)\((?.+)\)/,W0={rgb:(e,t,n,r)=>({r:e,g:t,b:n,a:r}),rgba:(e,t,n,r)=>({r:e,g:t,b:n,a:r}),hsl:(e,t,n,r)=>ef({h:e,s:t,l:n,a:r}),hsla:(e,t,n,r)=>ef({h:e,s:t,l:n,a:r}),hsv:(e,t,n,r)=>Us({h:e,s:t,v:n,a:r}),hsva:(e,t,n,r)=>Us({h:e,s:t,v:n,a:r})};function nn(e){if(typeof e=="number")return{r:(e&16711680)>>16,g:(e&65280)>>8,b:e&255};if(typeof e=="string"&&Qc.test(e)){const{groups:t}=e.match(Qc),{fn:n,values:r}=t,s=r.split(/,\s*/).map(o=>o.endsWith("%")&&["hsl","hsla","hsv","hsva"].includes(n)?parseFloat(o)/100:parseFloat(o));return W0[n](...s)}else if(typeof e=="string"){let t=e.startsWith("#")?e.slice(1):e;return[3,4].includes(t.length)?t=t.split("").map(n=>n+n).join(""):[6,8].includes(t.length),z0(t)}else if(typeof e=="object"){if(bi(e,["r","g","b"]))return e;if(bi(e,["h","s","l"]))return Us(Iv(e));if(bi(e,["h","s","v"]))return Us(e)}throw new TypeError(`Invalid color: ${e==null?e:String(e)||e.constructor.name} +Expected #hex, #hexa, rgb(), rgba(), hsl(), hsla(), object or number`)}function Us(e){const{h:t,s:n,v:r,a:s}=e,o=i=>{const l=(i+t/60)%6;return r-r*n*Math.max(Math.min(l,4-l,1),0)},a=[o(5),o(3),o(1)].map(i=>Math.round(i*255));return{r:a[0],g:a[1],b:a[2],a:s}}function ef(e){return Us(Iv(e))}function Iv(e){const{h:t,s:n,l:r,a:s}=e,o=r+n*Math.min(r,1-r),a=o===0?0:2-2*r/o;return{h:t,s:a,v:o,a:s}}function Mo(e){const t=Math.round(e).toString(16);return("00".substr(0,2-t.length)+t).toUpperCase()}function U0(e){let{r:t,g:n,b:r,a:s}=e;return`#${[Mo(t),Mo(n),Mo(r),s!==void 0?Mo(Math.round(s*255)):""].join("")}`}function z0(e){e=K0(e);let[t,n,r,s]=T0(e,2).map(o=>parseInt(o,16));return s=s===void 0?s:s/255,{r:t,g:n,b:r,a:s}}function K0(e){return e.startsWith("#")&&(e=e.slice(1)),e=e.replace(/([^0-9a-f])/gi,"F"),(e.length===3||e.length===4)&&(e=e.split("").map(t=>t+t).join("")),e.length!==6&&(e=Bc(Bc(e,6),8,"F")),e}function G0(e,t){const n=xv(nu(e));return n[0]=n[0]+t*10,Av(Pv(n))}function q0(e,t){const n=xv(nu(e));return n[0]=n[0]-t*10,Av(Pv(n))}function Z0(e){const t=nn(e);return nu(t)[1]}function Lv(e){const t=Math.abs(Xc(nn(0),nn(e)));return Math.abs(Xc(nn(16777215),nn(e)))>Math.min(t,50)?"#fff":"#000"}function $e(e,t){return n=>Object.keys(e).reduce((r,s)=>{const a=typeof e[s]=="object"&&e[s]!=null&&!Array.isArray(e[s])?e[s]:{type:e[s]};return n&&s in n?r[s]={...a,default:n[s]}:r[s]=a,t&&!r[s].source&&(r[s].source=t),r},{})}const ln=$e({class:[String,Array,Object],style:{type:[String,Array,Object],default:null}},"component");function St(e,t){const n=os();if(!n)throw new Error(`[Vuetify] ${e} must be called from inside a setup function`);return n}function Kn(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:"composables";const t=St(e).type;return cr(t?.aliasName||t?.name)}let Rv=0,Fo=new WeakMap;function Ra(){const e=St("getUid");if(Fo.has(e))return Fo.get(e);{const t=Rv++;return Fo.set(e,t),t}}Ra.reset=()=>{Rv=0,Fo=new WeakMap};function J0(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:St("injectSelf");const{provides:n}=t;if(n&&e in n)return n[e]}const qr=Symbol.for("vuetify:defaults");function X0(e){return oe(e)}function ru(){const e=Pe(qr);if(!e)throw new Error("[Vuetify] Could not find defaults instance");return e}function Nv(e,t){const n=ru(),r=oe(e),s=w(()=>{if(A(t?.disabled))return n.value;const a=A(t?.scoped),i=A(t?.reset),l=A(t?.root);if(r.value==null&&!(a||i||l))return n.value;let u=at(r.value,{prev:n.value});if(a)return u;if(i||l){const c=Number(i||1/0);for(let f=0;f<=c&&!(!u||!("prev"in u));f++)u=u.prev;return u&&typeof l=="string"&&l in u&&(u=at(at(u,{prev:u}),u[l])),u}return u.prev?at(u.prev,u):u});return Pt(qr,s),s}function Q0(e,t){return typeof e.props?.[t]<"u"||typeof e.props?.[cr(t)]<"u"}function e1(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},t=arguments.length>1?arguments[1]:void 0,n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:ru();const r=St("useDefaults");if(t=t??r.type.name??r.type.__name,!t)throw new Error("[Vuetify] Could not determine component name");const s=w(()=>n.value?.[e._as??t]),o=new Proxy(e,{get(l,u){const c=Reflect.get(l,u);return u==="class"||u==="style"?[s.value?.[u],c].filter(f=>f!=null):typeof u=="string"&&!Q0(r.vnode,u)?s.value?.[u]!==void 0?s.value?.[u]:n.value?.global?.[u]!==void 0?n.value?.global?.[u]:c:c}}),a=Ut();zn(()=>{if(s.value){const l=Object.entries(s.value).filter(u=>{let[c]=u;return c.startsWith(c[0].toUpperCase())});a.value=l.length?Object.fromEntries(l):void 0}else a.value=void 0});function i(){const l=J0(qr,r);Pt(qr,w(()=>a.value?at(l?.value??{},a.value):l?.value))}return{props:o,provideSubDefaults:i}}function co(e){if(e._setup=e._setup??e.setup,!e.name)return e;if(e._setup){e.props=$e(e.props??{},e.name)();const t=Object.keys(e.props).filter(n=>n!=="class"&&n!=="style");e.filterProps=function(r){return C0(r,t)},e.props._as=String,e.setup=function(r,s){const o=ru();if(!o.value)return e._setup(r,s);const{props:a,provideSubDefaults:i}=e1(r,r._as??e.name,o),l=e._setup(a,s);return i(),l}}return e}function At(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:!0;return t=>(e?co:Ze)(t)}function t1(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"div",n=arguments.length>2?arguments[2]:void 0;return At()({name:n??Dn(kt(e.replace(/__/g,"-"))),props:{tag:{type:String,default:t},...ln()},setup(r,s){let{slots:o}=s;return()=>lo(r.tag,{class:[e,r.class],style:r.style},o.default?.())}})}function br(e){const t=St("useRender");t.render=e}function Na(e,t,n){let r=arguments.length>3&&arguments[3]!==void 0?arguments[3]:f=>f,s=arguments.length>4&&arguments[4]!==void 0?arguments[4]:f=>f;const o=St("useProxiedModel"),a=oe(e[t]!==void 0?e[t]:n),i=cr(t),u=w(i!==t?()=>(e[t],!!((o.vnode.props?.hasOwnProperty(t)||o.vnode.props?.hasOwnProperty(i))&&(o.vnode.props?.hasOwnProperty(`onUpdate:${t}`)||o.vnode.props?.hasOwnProperty(`onUpdate:${i}`)))):()=>(e[t],!!(o.vnode.props?.hasOwnProperty(t)&&o.vnode.props?.hasOwnProperty(`onUpdate:${t}`))));b0(()=>!u.value,()=>{Te(()=>e[t],f=>{a.value=f})});const c=w({get(){const f=e[t];return r(u.value?f:a.value)},set(f){const d=s(f),h=ge(u.value?e[t]:a.value);h===d||r(h)===f||(a.value=d,o?.emit(`update:${t}`,d))}});return Object.defineProperty(c,"externalValue",{get:()=>u.value?e[t]:a.value}),c}const n1={badge:"Badge",open:"Open",close:"Close",dismiss:"Dismiss",confirmEdit:{ok:"OK",cancel:"Cancel"},dataIterator:{noResultsText:"No matching records found",loadingText:"Loading items..."},dataTable:{itemsPerPageText:"Rows per page:",ariaLabel:{sortDescending:"Sorted descending.",sortAscending:"Sorted ascending.",sortNone:"Not sorted.",activateNone:"Activate to remove sorting.",activateDescending:"Activate to sort descending.",activateAscending:"Activate to sort ascending."},sortBy:"Sort by"},dataFooter:{itemsPerPageText:"Items per page:",itemsPerPageAll:"All",nextPage:"Next page",prevPage:"Previous page",firstPage:"First page",lastPage:"Last page",pageText:"{0}-{1} of {2}"},dateRangeInput:{divider:"to"},datePicker:{itemsSelected:"{0} selected",range:{title:"Select dates",header:"Enter dates"},title:"Select date",header:"Enter date",input:{placeholder:"Enter date"}},noDataText:"No data available",carousel:{prev:"Previous visual",next:"Next visual",ariaLabel:{delimiter:"Carousel slide {0} of {1}"}},calendar:{moreEvents:"{0} more",today:"Today"},input:{clear:"Clear {0}",prependAction:"{0} prepended action",appendAction:"{0} appended action",otp:"Please enter OTP character {0}"},fileInput:{counter:"{0} files",counterSize:"{0} files ({1} in total)"},timePicker:{am:"AM",pm:"PM",title:"Select Time"},pagination:{ariaLabel:{root:"Pagination Navigation",next:"Next page",previous:"Previous page",page:"Go to page {0}",currentPage:"Page {0}, Current page",first:"First page",last:"Last page"}},stepper:{next:"Next",prev:"Previous"},rating:{ariaLabel:{item:"Rating {0} of {1}"}},loading:"Loading...",infiniteScroll:{loadMore:"Load more",empty:"No more"}},tf="$vuetify.",nf=(e,t)=>e.replace(/\{(\d+)\}/g,(n,r)=>String(t[+r])),Fv=(e,t,n)=>function(r){for(var s=arguments.length,o=new Array(s>1?s-1:0),a=1;anew Intl.NumberFormat([e.value,t.value],r).format(n)}function wi(e,t,n){const r=Na(e,t,e[t]??n.value);return r.value=e[t]??n.value,Te(n,s=>{e[t]==null&&(r.value=n.value)}),r}function Bv(e){return t=>{const n=wi(t,"locale",e.current),r=wi(t,"fallback",e.fallback),s=wi(t,"messages",e.messages);return{name:"vuetify",current:n,fallback:r,messages:s,t:Fv(n,r,s),n:Yv(n,r),provide:Bv({current:n,fallback:r,messages:s})}}}function r1(e){const t=Ut(e?.locale??"en"),n=Ut(e?.fallback??"en"),r=oe({en:n1,...e?.messages});return{name:"vuetify",current:t,fallback:n,messages:r,t:Fv(t,n,r),n:Yv(t,n),provide:Bv({current:t,fallback:n,messages:r})}}const oa=Symbol.for("vuetify:locale");function s1(e){return e.name!=null}function o1(e){const t=e?.adapter&&s1(e?.adapter)?e?.adapter:r1(e),n=l1(t,e);return{...t,...n}}function a1(){const e=Pe(oa);if(!e)throw new Error("[Vuetify] Could not find injected locale instance");return e}function i1(){return{af:!1,ar:!0,bg:!1,ca:!1,ckb:!1,cs:!1,de:!1,el:!1,en:!1,es:!1,et:!1,fa:!0,fi:!1,fr:!1,hr:!1,hu:!1,he:!0,id:!1,it:!1,ja:!1,km:!1,ko:!1,lv:!1,lt:!1,nl:!1,no:!1,pl:!1,pt:!1,ro:!1,ru:!1,sk:!1,sl:!1,srCyrl:!1,srLatn:!1,sv:!1,th:!1,tr:!1,az:!1,uk:!1,vi:!1,zhHans:!1,zhHant:!1}}function l1(e,t){const n=oe(t?.rtl??i1()),r=w(()=>n.value[e.current.value]??!1);return{isRtl:r,rtl:n,rtlClasses:w(()=>`v-locale--is-${r.value?"rtl":"ltr"}`)}}function Fa(){const e=Pe(oa);if(!e)throw new Error("[Vuetify] Could not find injected rtl instance");return{isRtl:e.isRtl,rtlClasses:e.rtlClasses}}const Ya={"001":1,AD:1,AE:6,AF:6,AG:0,AI:1,AL:1,AM:1,AN:1,AR:1,AS:0,AT:1,AU:1,AX:1,AZ:1,BA:1,BD:0,BE:1,BG:1,BH:6,BM:1,BN:1,BR:0,BS:0,BT:0,BW:0,BY:1,BZ:0,CA:0,CH:1,CL:1,CM:1,CN:1,CO:0,CR:1,CY:1,CZ:1,DE:1,DJ:6,DK:1,DM:0,DO:0,DZ:6,EC:1,EE:1,EG:6,ES:1,ET:0,FI:1,FJ:1,FO:1,FR:1,GB:1,"GB-alt-variant":0,GE:1,GF:1,GP:1,GR:1,GT:0,GU:0,HK:0,HN:0,HR:1,HU:1,ID:0,IE:1,IL:0,IN:0,IQ:6,IR:6,IS:1,IT:1,JM:0,JO:6,JP:0,KE:0,KG:1,KH:0,KR:0,KW:6,KZ:1,LA:0,LB:1,LI:1,LK:1,LT:1,LU:1,LV:1,LY:6,MC:1,MD:1,ME:1,MH:0,MK:1,MM:0,MN:1,MO:0,MQ:1,MT:0,MV:5,MX:0,MY:1,MZ:0,NI:0,NL:1,NO:1,NP:0,NZ:1,OM:6,PA:0,PE:0,PH:0,PK:0,PL:1,PR:0,PT:0,PY:0,QA:6,RE:1,RO:1,RS:1,RU:1,SA:0,SD:6,SE:1,SG:0,SI:1,SK:1,SM:1,SV:0,SY:6,TH:0,TJ:1,TM:1,TR:1,TT:0,TW:0,UA:1,UM:0,US:0,UY:1,UZ:1,VA:1,VE:0,VI:0,VN:1,WS:0,XK:1,YE:0,ZA:0,ZW:0};function u1(e,t,n){const r=[];let s=[];const o=Hv(e),a=jv(e),i=n??Ya[t.slice(-2).toUpperCase()]??0,l=(o.getDay()-i+7)%7,u=(a.getDay()-i+7)%7;for(let c=0;c0&&r.push(s),r}function c1(e,t,n){const r=n??Ya[t.slice(-2).toUpperCase()]??0,s=new Date(e);for(;s.getDay()!==r;)s.setDate(s.getDate()-1);return s}function f1(e,t){const n=new Date(e),r=((Ya[t.slice(-2).toUpperCase()]??0)+6)%7;for(;n.getDay()!==r;)n.setDate(n.getDate()+1);return n}function Hv(e){return new Date(e.getFullYear(),e.getMonth(),1)}function jv(e){return new Date(e.getFullYear(),e.getMonth()+1,0)}function d1(e){const t=e.split("-").map(Number);return new Date(t[0],t[1]-1,t[2])}const h1=/^([12]\d{3}-([1-9]|0[1-9]|1[0-2])-([1-9]|0[1-9]|[12]\d|3[01]))$/;function Vv(e){if(e==null)return new Date;if(e instanceof Date)return e;if(typeof e=="string"){let t;if(h1.test(e))return d1(e);if(t=Date.parse(e),!isNaN(t))return new Date(t)}return null}const rf=new Date(2e3,0,2);function v1(e,t){const n=t??Ya[e.slice(-2).toUpperCase()]??0;return Tv(7).map(r=>{const s=new Date(rf);return s.setDate(rf.getDate()+n+r),new Intl.DateTimeFormat(e,{weekday:"narrow"}).format(s)})}function m1(e,t,n,r){const s=Vv(e)??new Date,o=r?.[t];if(typeof o=="function")return o(s,t,n);let a={};switch(t){case"fullDate":a={year:"numeric",month:"long",day:"numeric"};break;case"fullDateWithWeekday":a={weekday:"long",year:"numeric",month:"long",day:"numeric"};break;case"normalDate":const i=s.getDate(),l=new Intl.DateTimeFormat(n,{month:"long"}).format(s);return`${i} ${l}`;case"normalDateWithWeekday":a={weekday:"short",day:"numeric",month:"short"};break;case"shortDate":a={month:"short",day:"numeric"};break;case"year":a={year:"numeric"};break;case"month":a={month:"long"};break;case"monthShort":a={month:"short"};break;case"monthAndYear":a={month:"long",year:"numeric"};break;case"monthAndDate":a={month:"long",day:"numeric"};break;case"weekday":a={weekday:"long"};break;case"weekdayShort":a={weekday:"short"};break;case"dayOfMonth":return new Intl.NumberFormat(n).format(s.getDate());case"hours12h":a={hour:"numeric",hour12:!0};break;case"hours24h":a={hour:"numeric",hour12:!1};break;case"minutes":a={minute:"numeric"};break;case"seconds":a={second:"numeric"};break;case"fullTime":a={hour:"numeric",minute:"numeric",second:"numeric",hour12:!0};break;case"fullTime12h":a={hour:"numeric",minute:"numeric",second:"numeric",hour12:!0};break;case"fullTime24h":a={hour:"numeric",minute:"numeric",second:"numeric",hour12:!1};break;case"fullDateTime":a={year:"numeric",month:"long",day:"numeric",hour:"numeric",minute:"numeric",second:"numeric",hour12:!0};break;case"fullDateTime12h":a={year:"numeric",month:"long",day:"numeric",hour:"numeric",minute:"numeric",second:"numeric",hour12:!0};break;case"fullDateTime24h":a={year:"numeric",month:"long",day:"numeric",hour:"numeric",minute:"numeric",second:"numeric",hour12:!1};break;case"keyboardDate":a={year:"numeric",month:"2-digit",day:"2-digit"};break;case"keyboardDateTime":a={year:"numeric",month:"2-digit",day:"2-digit",hour:"numeric",minute:"numeric",second:"numeric",hour12:!1};break;case"keyboardDateTime12h":a={year:"numeric",month:"2-digit",day:"2-digit",hour:"numeric",minute:"numeric",second:"numeric",hour12:!0};break;case"keyboardDateTime24h":a={year:"numeric",month:"2-digit",day:"2-digit",hour:"numeric",minute:"numeric",second:"numeric",hour12:!1};break;default:a=o??{timeZone:"UTC",timeZoneName:"short"}}return new Intl.DateTimeFormat(n,a).format(s)}function p1(e,t){const n=e.toJsDate(t),r=n.getFullYear(),s=Hc(String(n.getMonth()+1),2,"0"),o=Hc(String(n.getDate()),2,"0");return`${r}-${s}-${o}`}function g1(e){const[t,n,r]=e.split("-").map(Number);return new Date(t,n-1,r)}function y1(e,t){const n=new Date(e);return n.setMinutes(n.getMinutes()+t),n}function b1(e,t){const n=new Date(e);return n.setHours(n.getHours()+t),n}function w1(e,t){const n=new Date(e);return n.setDate(n.getDate()+t),n}function _1(e,t){const n=new Date(e);return n.setDate(n.getDate()+t*7),n}function D1(e,t){const n=new Date(e);return n.setDate(1),n.setMonth(n.getMonth()+t),n}function C1(e){return e.getFullYear()}function S1(e){return e.getMonth()}function $1(e){return e.getDate()}function T1(e){return new Date(e.getFullYear(),e.getMonth()+1,1)}function E1(e){return new Date(e.getFullYear(),e.getMonth()-1,1)}function O1(e){return e.getHours()}function M1(e){return e.getMinutes()}function k1(e){return new Date(e.getFullYear(),0,1)}function x1(e){return new Date(e.getFullYear(),11,31)}function P1(e,t){return aa(e,t[0])&&L1(e,t[1])}function A1(e){const t=new Date(e);return t instanceof Date&&!isNaN(t.getTime())}function aa(e,t){return e.getTime()>t.getTime()}function I1(e,t){return aa(nl(e),nl(t))}function L1(e,t){return e.getTime(){n.locale=e.locale[r]??r??n.locale}),n}const Ba=["sm","md","lg","xl","xxl"],rl=Symbol.for("vuetify:display"),af={mobileBreakpoint:"lg",thresholds:{xs:0,sm:600,md:960,lg:1280,xl:1920,xxl:2560}},Z1=function(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:af;return at(af,e)};function lf(e){return ot&&!e?window.innerWidth:typeof e=="object"&&e.clientWidth||0}function uf(e){return ot&&!e?window.innerHeight:typeof e=="object"&&e.clientHeight||0}function cf(e){const t=ot&&!e?window.navigator.userAgent:"ssr";function n(v){return!!t.match(v)}const r=n(/android/i),s=n(/iphone|ipad|ipod/i),o=n(/cordova/i),a=n(/electron/i),i=n(/chrome/i),l=n(/edge/i),u=n(/firefox/i),c=n(/opera/i),f=n(/win/i),d=n(/mac/i),h=n(/linux/i);return{android:r,ios:s,cordova:o,electron:a,chrome:i,edge:l,firefox:u,opera:c,win:f,mac:d,linux:h,touch:_0,ssr:t==="ssr"}}function J1(e,t){const{thresholds:n,mobileBreakpoint:r}=Z1(e),s=Ut(uf(t)),o=Ut(cf(t)),a=je({}),i=Ut(lf(t));function l(){s.value=uf(),i.value=lf()}function u(){l(),o.value=cf()}return zn(()=>{const c=i.value=n.xxl,p=c?"xs":f?"sm":d?"md":h?"lg":v?"xl":"xxl",b=typeof r=="number"?r:n[r],S=i.value0&&arguments[0]!==void 0?arguments[0]:{},t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:Kn();const n=Pe(rl);if(!n)throw new Error("Could not find Vuetify display injection");const r=w(()=>{if(e.mobile!=null)return e.mobile;if(!e.mobileBreakpoint)return n.mobile.value;const o=typeof e.mobileBreakpoint=="number"?e.mobileBreakpoint:n.thresholds.value[e.mobileBreakpoint];return n.width.valuet?{[`${t}--mobile`]:r.value}:{});return{...n,displayClasses:s,mobile:r}}const Wv=Symbol.for("vuetify:goto");function Uv(){return{container:void 0,duration:300,layout:!1,offset:0,easing:"easeInOutCubic",patterns:{linear:e=>e,easeInQuad:e=>e**2,easeOutQuad:e=>e*(2-e),easeInOutQuad:e=>e<.5?2*e**2:-1+(4-2*e)*e,easeInCubic:e=>e**3,easeOutCubic:e=>--e**3+1,easeInOutCubic:e=>e<.5?4*e**3:(e-1)*(2*e-2)*(2*e-2)+1,easeInQuart:e=>e**4,easeOutQuart:e=>1- --e**4,easeInOutQuart:e=>e<.5?8*e**4:1-8*--e**4,easeInQuint:e=>e**5,easeOutQuint:e=>1+--e**5,easeInOutQuint:e=>e<.5?16*e**5:1+16*--e**5}}}function Q1(e){return su(e)??(document.scrollingElement||document.body)}function su(e){return typeof e=="string"?document.querySelector(e):Ev(e)}function _i(e,t,n){if(typeof e=="number")return t&&n?-e:e;let r=su(e),s=0;for(;r;)s+=t?r.offsetLeft:r.offsetTop,r=r.offsetParent;return s}function ew(e,t){return{rtl:t.isRtl,options:at(Uv(),e)}}async function ff(e,t,n,r){const s=n?"scrollLeft":"scrollTop",o=at(r?.options??Uv(),t),a=r?.rtl.value,i=(typeof e=="number"?e:su(e))??0,l=o.container==="parent"&&i instanceof HTMLElement?i.parentElement:Q1(o.container),u=typeof o.easing=="function"?o.easing:o.patterns[o.easing];if(!u)throw new TypeError(`Easing function "${o.easing}" not found.`);let c;if(typeof i=="number")c=_i(i,n,a);else if(c=_i(i,n,a)-_i(l,n,a),o.layout){const v=window.getComputedStyle(i).getPropertyValue("--v-layout-top");v&&(c-=parseInt(v,10))}c+=o.offset,c=tw(l,c,!!a,!!n);const f=l[s]??0;if(c===f)return Promise.resolve(c);const d=performance.now();return new Promise(h=>requestAnimationFrame(function v(m){const b=(m-d)/o.duration,S=Math.floor(f+(c-f)*u(na(b,0,1)));if(l[s]=S,b>=1&&Math.abs(S-l[s])<10)return h(c);if(b>2)return h(l[s]);requestAnimationFrame(v)}))}function RY(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};const t=Pe(Wv),{isRtl:n}=Fa();if(!t)throw new Error("[Vuetify] Could not find injected goto instance");const r={...t,rtl:w(()=>t.rtl.value||n.value)};async function s(o,a){return ff(o,at(e,a),!1,r)}return s.horizontal=async(o,a)=>ff(o,at(e,a),!0,r),s}function tw(e,t,n,r){const{scrollWidth:s,scrollHeight:o}=e,[a,i]=e===document.scrollingElement?[window.innerWidth,window.innerHeight]:[e.offsetWidth,e.offsetHeight];let l,u;return r?n?(l=-(s-a),u=0):(l=0,u=s-a):(l=0,u=o+-i),Math.max(Math.min(t,u),l)}const nw={collapse:"mdi-chevron-up",complete:"mdi-check",cancel:"mdi-close-circle",close:"mdi-close",delete:"mdi-close-circle",clear:"mdi-close-circle",success:"mdi-check-circle",info:"mdi-information",warning:"mdi-alert-circle",error:"mdi-close-circle",prev:"mdi-chevron-left",next:"mdi-chevron-right",checkboxOn:"mdi-checkbox-marked",checkboxOff:"mdi-checkbox-blank-outline",checkboxIndeterminate:"mdi-minus-box",delimiter:"mdi-circle",sortAsc:"mdi-arrow-up",sortDesc:"mdi-arrow-down",expand:"mdi-chevron-down",menu:"mdi-menu",subgroup:"mdi-menu-down",dropdown:"mdi-menu-down",radioOn:"mdi-radiobox-marked",radioOff:"mdi-radiobox-blank",edit:"mdi-pencil",ratingEmpty:"mdi-star-outline",ratingFull:"mdi-star",ratingHalf:"mdi-star-half-full",loading:"mdi-cached",first:"mdi-page-first",last:"mdi-page-last",unfold:"mdi-unfold-more-horizontal",file:"mdi-paperclip",plus:"mdi-plus",minus:"mdi-minus",calendar:"mdi-calendar",treeviewCollapse:"mdi-menu-down",treeviewExpand:"mdi-menu-right",eyeDropper:"mdi-eyedropper"},rw={component:e=>lo(Kv,{...e,class:"mdi"})},zs=[String,Function,Object,Array],sl=Symbol.for("vuetify:icons"),Ha=$e({icon:{type:zs},tag:{type:String,required:!0}},"icon"),df=At()({name:"VComponentIcon",props:Ha(),setup(e,t){let{slots:n}=t;return()=>{const r=e.icon;return L(e.tag,null,{default:()=>[e.icon?L(r,null,null):n.default?.()]})}}}),zv=co({name:"VSvgIcon",inheritAttrs:!1,props:Ha(),setup(e,t){let{attrs:n}=t;return()=>L(e.tag,qt(n,{style:null}),{default:()=>[L("svg",{class:"v-icon__svg",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",role:"img","aria-hidden":"true"},[Array.isArray(e.icon)?e.icon.map(r=>Array.isArray(r)?L("path",{d:r[0],"fill-opacity":r[1]},null):L("path",{d:r},null)):L("path",{d:e.icon},null)])]})}});co({name:"VLigatureIcon",props:Ha(),setup(e){return()=>L(e.tag,null,{default:()=>[e.icon]})}});const Kv=co({name:"VClassIcon",props:Ha(),setup(e){return()=>L(e.tag,{class:e.icon},null)}});function sw(){return{svg:{component:zv},class:{component:Kv}}}function ow(e){const t=sw(),n=e?.defaultSet??"mdi";return n==="mdi"&&!t.mdi&&(t.mdi=rw),at({defaultSet:n,sets:t,aliases:{...nw,vuetify:["M8.2241 14.2009L12 21L22 3H14.4459L8.2241 14.2009Z",["M7.26303 12.4733L7.00113 12L2 3H12.5261C12.5261 3 12.5261 3 12.5261 3L7.26303 12.4733Z",.6]],"vuetify-outline":"svg:M7.26 12.47 12.53 3H2L7.26 12.47ZM14.45 3 8.22 14.2 12 21 22 3H14.45ZM18.6 5 12 16.88 10.51 14.2 15.62 5ZM7.26 8.35 5.4 5H9.13L7.26 8.35Z","vuetify-play":["m6.376 13.184-4.11-7.192C1.505 4.66 2.467 3 4.003 3h8.532l-.953 1.576-.006.01-.396.677c-.429.732-.214 1.507.194 2.015.404.503 1.092.878 1.869.806a3.72 3.72 0 0 1 1.005.022c.276.053.434.143.523.237.138.146.38.635-.25 2.09-.893 1.63-1.553 1.722-1.847 1.677-.213-.033-.468-.158-.756-.406a4.95 4.95 0 0 1-.8-.927c-.39-.564-1.04-.84-1.66-.846-.625-.006-1.316.27-1.693.921l-.478.826-.911 1.506Z",["M9.093 11.552c.046-.079.144-.15.32-.148a.53.53 0 0 1 .43.207c.285.414.636.847 1.046 1.2.405.35.914.662 1.516.754 1.334.205 2.502-.698 3.48-2.495l.014-.028.013-.03c.687-1.574.774-2.852-.005-3.675-.37-.391-.861-.586-1.333-.676a5.243 5.243 0 0 0-1.447-.044c-.173.016-.393-.073-.54-.257-.145-.18-.127-.316-.082-.392l.393-.672L14.287 3h5.71c1.536 0 2.499 1.659 1.737 2.992l-7.997 13.996c-.768 1.344-2.706 1.344-3.473 0l-3.037-5.314 1.377-2.278.004-.006.004-.007.481-.831Z",.6]]}},e)}const aw=e=>{const t=Pe(sl);if(!t)throw new Error("Missing Vuetify Icons provide!");return{iconData:w(()=>{const r=A(e);if(!r)return{component:df};let s=r;if(typeof s=="string"&&(s=s.trim(),s.startsWith("$")&&(s=t.aliases?.[s.slice(1)])),Array.isArray(s))return{component:zv,icon:s};if(typeof s!="string")return{component:df,icon:s};const o=Object.keys(t.sets).find(l=>typeof s=="string"&&s.startsWith(`${l}:`)),a=o?s.slice(o.length+1):s;return{component:t.sets[o??t.defaultSet].component,icon:a}})}},Ks=Symbol.for("vuetify:theme"),wr=$e({theme:String},"theme");function hf(){return{defaultTheme:"light",variations:{colors:[],lighten:0,darken:0},themes:{light:{dark:!1,colors:{background:"#FFFFFF",surface:"#FFFFFF","surface-bright":"#FFFFFF","surface-light":"#EEEEEE","surface-variant":"#424242","on-surface-variant":"#EEEEEE",primary:"#1867C0","primary-darken-1":"#1F5592",secondary:"#48A9A6","secondary-darken-1":"#018786",error:"#B00020",info:"#2196F3",success:"#4CAF50",warning:"#FB8C00"},variables:{"border-color":"#000000","border-opacity":.12,"high-emphasis-opacity":.87,"medium-emphasis-opacity":.6,"disabled-opacity":.38,"idle-opacity":.04,"hover-opacity":.04,"focus-opacity":.12,"selected-opacity":.08,"activated-opacity":.12,"pressed-opacity":.12,"dragged-opacity":.08,"theme-kbd":"#212529","theme-on-kbd":"#FFFFFF","theme-code":"#F5F5F5","theme-on-code":"#000000"}},dark:{dark:!0,colors:{background:"#121212",surface:"#212121","surface-bright":"#ccbfd6","surface-light":"#424242","surface-variant":"#a3a3a3","on-surface-variant":"#424242",primary:"#2196F3","primary-darken-1":"#277CC1",secondary:"#54B6B2","secondary-darken-1":"#48A9A6",error:"#CF6679",info:"#2196F3",success:"#4CAF50",warning:"#FB8C00"},variables:{"border-color":"#FFFFFF","border-opacity":.12,"high-emphasis-opacity":1,"medium-emphasis-opacity":.7,"disabled-opacity":.5,"idle-opacity":.1,"hover-opacity":.04,"focus-opacity":.12,"selected-opacity":.08,"activated-opacity":.12,"pressed-opacity":.16,"dragged-opacity":.08,"theme-kbd":"#212529","theme-on-kbd":"#FFFFFF","theme-code":"#343434","theme-on-code":"#CCCCCC"}}}}}function iw(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:hf();const t=hf();if(!e)return{...t,isDisabled:!0};const n={};for(const[r,s]of Object.entries(e.themes??{})){const o=s.dark||r==="dark"?t.themes?.dark:t.themes?.light;n[r]=at(o,s)}return at(t,{...e,themes:n})}function lw(e){const t=iw(e),n=oe(t.defaultTheme),r=oe(t.themes),s=w(()=>{const c={};for(const[f,d]of Object.entries(r.value)){const h=c[f]={...d,colors:{...d.colors}};if(t.variations)for(const v of t.variations.colors){const m=h.colors[v];if(m)for(const p of["lighten","darken"]){const b=p==="lighten"?G0:q0;for(const S of Tv(t.variations[p],1))h.colors[`${v}-${p}-${S}`]=U0(b(nn(m),S))}}for(const v of Object.keys(h.colors)){if(/^on-[a-z]/.test(v)||h.colors[`on-${v}`])continue;const m=`on-${v}`,p=nn(h.colors[v]);h.colors[m]=Lv(p)}}return c}),o=w(()=>s.value[n.value]),a=w(()=>{const c=[];o.value?.dark&&nr(c,":root",["color-scheme: dark"]),nr(c,":root",vf(o.value));for(const[v,m]of Object.entries(s.value))nr(c,`.v-theme--${v}`,[`color-scheme: ${m.dark?"dark":"normal"}`,...vf(m)]);const f=[],d=[],h=new Set(Object.values(s.value).flatMap(v=>Object.keys(v.colors)));for(const v of h)/^on-[a-z]/.test(v)?nr(d,`.${v}`,[`color: rgb(var(--v-theme-${v})) !important`]):(nr(f,`.bg-${v}`,[`--v-theme-overlay-multiplier: var(--v-theme-${v}-overlay-multiplier)`,`background-color: rgb(var(--v-theme-${v})) !important`,`color: rgb(var(--v-theme-on-${v})) !important`]),nr(d,`.text-${v}`,[`color: rgb(var(--v-theme-${v})) !important`]),nr(d,`.border-${v}`,[`--v-border-color: var(--v-theme-${v})`]));return c.push(...f,...d),c.map((v,m)=>m===0?v:` ${v}`).join("")});function i(){return{style:[{children:a.value,id:"vuetify-theme-stylesheet",nonce:t.cspNonce||!1}]}}function l(c){if(t.isDisabled)return;const f=c._context.provides.usehead;if(f)if(f.push){const d=f.push(i);ot&&Te(a,()=>{d.patch(i)})}else ot?(f.addHeadObjs(w(i)),zn(()=>f.updateDOM())):f.addHeadObjs(i());else{let h=function(){if(typeof document<"u"&&!d){const v=document.createElement("style");v.type="text/css",v.id="vuetify-theme-stylesheet",t.cspNonce&&v.setAttribute("nonce",t.cspNonce),d=v,document.head.appendChild(d)}d&&(d.innerHTML=a.value)},d=ot?document.getElementById("vuetify-theme-stylesheet"):null;ot?Te(a,h,{immediate:!0}):h()}}const u=w(()=>t.isDisabled?void 0:`v-theme--${n.value}`);return{install:l,isDisabled:t.isDisabled,name:n,themes:r,current:o,computedThemes:s,themeClasses:u,styles:a,global:{name:n,current:o}}}function _r(e){St("provideTheme");const t=Pe(Ks,null);if(!t)throw new Error("Could not find Vuetify theme injection");const n=w(()=>e.theme??t.name.value),r=w(()=>t.themes.value[n.value]),s=w(()=>t.isDisabled?void 0:`v-theme--${n.value}`),o={...t,name:n,current:r,themeClasses:s};return Pt(Ks,o),o}function uw(){St("useTheme");const e=Pe(Ks,null);if(!e)throw new Error("Could not find Vuetify theme injection");return e}function nr(e,t,n){e.push(`${t} { `,...n.map(r=>` ${r}; `),`} -`)}function vf(e){const t=e.dark?2:1,n=e.dark?1:2,r=[];for(const[s,o]of Object.entries(e.colors)){const a=nn(o);r.push(`--v-theme-${s}: ${a.r},${a.g},${a.b}`),s.startsWith("on-")||r.push(`--v-theme-${s}-overlay-multiplier: ${Q0(o)>.18?t:n}`)}for(const[s,o]of Object.entries(e.variables)){const a=typeof o=="string"&&o.startsWith("#")?nn(o):void 0,i=a?`${a.r}, ${a.g}, ${a.b}`:void 0;r.push(`--v-${s}: ${i??o}`)}return r}function qv(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"content";const n=x0(),r=oe();if(ot){const s=new ResizeObserver(o=>{e?.(o,s),o.length&&(t==="content"?r.value=o[0].contentRect:r.value=o[0].target.getBoundingClientRect())});yr(()=>{s.disconnect()}),Te(()=>n.el,(o,a)=>{a&&(s.unobserve(a),r.value=void 0),o&&s.observe(o)},{flush:"post"})}return{resizeRef:n,contentRect:Ea(r)}}const ia=Symbol.for("vuetify:layout"),Zv=Symbol.for("vuetify:layout-item"),mf=1e3,hw=$e({overlaps:{type:Array,default:()=>[]},fullHeight:Boolean},"layout"),jY=$e({name:{type:String},order:{type:[Number,String],default:0},absolute:Boolean},"layout-item");function vw(){const e=Pe(ia);if(!e)throw new Error("[Vuetify] Could not find injected layout");return{layoutIsReady:Ot(),getLayoutItem:e.getLayoutItem,mainRect:e.mainRect,mainStyles:e.mainStyles}}function VY(e){const t=Pe(ia);if(!t)throw new Error("[Vuetify] Could not find injected layout");const n=e.id??`layout-item-${Ra()}`,r=St("useLayoutItem");Pt(Zv,{id:n});const s=Ut(!1);jh(()=>s.value=!0),Hh(()=>s.value=!1);const o=Ot(),{layoutItemStyles:a,layoutItemScrimStyles:i}=t.register(r,{...e,active:w(()=>s.value?!1:e.active.value),id:n});return yr(()=>t.unregister(n)),{layoutItemStyles:a,layoutRect:t.layoutRect,layoutItemScrimStyles:i,layoutIsReady:o}}const mw=(e,t,n,r)=>{let s={top:0,left:0,right:0,bottom:0};const o=[{id:"",layer:{...s}}];for(const a of e){const i=t.get(a),l=n.get(a),u=r.get(a);if(!i||!l||!u)continue;const c={...s,[i.value]:parseInt(s[i.value],10)+(u.value?parseInt(l.value,10):0)};o.push({id:a,layer:c}),s=c}return o};function pw(e){const t=Pe(ia,null),n=w(()=>t?t.rootZIndex.value-100:mf),r=oe([]),s=je(new Map),o=je(new Map),a=je(new Map),i=je(new Map),l=je(new Map),{resizeRef:u,contentRect:c}=qv(),f=Vc(()=>{const D=[...new Set([...a.values()].map(E=>E.value))].sort((E,P)=>E-P),C=[];for(const E of D){const P=r.value.filter($=>a.get($)?.value===E);C.push(...P)}return mw(C,s,o,i)}),d=w(()=>!Array.from(l.values()).some(D=>D.value)),h=w(()=>f.value[f.value.length-1].layer),v=w(()=>({"--v-layout-left":Fe(h.value.left),"--v-layout-right":Fe(h.value.right),"--v-layout-top":Fe(h.value.top),"--v-layout-bottom":Fe(h.value.bottom),...d.value?void 0:{transition:"none"}})),m=Vc(()=>f.value.slice(1).map((D,C)=>{let{id:E}=D;const{layer:P}=f.value[C],$=o.get(E),I=s.get(E);return{id:E,...P,size:Number($.value),position:I.value}})),p=D=>m.value.find(C=>C.id===D),b=St("createLayout"),S=Ot();Pt(ia,{register:(D,C)=>{let{id:E,order:P,position:$,layoutSize:I,elementSize:j,active:O,disableTransitions:W,absolute:re}=C;a.set(E,P),s.set(E,$),o.set(E,I),i.set(E,O),W&&l.set(E,W);const ee=kr(Zv,b?.vnode).indexOf(D);ee>-1?r.value.splice(ee,0,E):r.value.push(E);const J=w(()=>m.value.findIndex(fe=>fe.id===E)),ue=w(()=>n.value+f.value.length*2-J.value*2),we=w(()=>{const fe=$.value==="left"||$.value==="right",Q=$.value==="right",Le=$.value==="bottom",pe=j.value??I.value,Ye=pe===0?"%":"px",Re={[$.value]:0,zIndex:ue.value,transform:`translate${fe?"X":"Y"}(${(O.value?0:-(pe===0?100:pe))*(Q||Le?-1:1)}${Ye})`,position:re.value||n.value!==mf?"absolute":"fixed",...d.value?void 0:{transition:"none"}};if(J.value<0)throw new Error(`Layout item "${E}" is missing`);const ye=m.value[J.value];if(!ye)throw new Error(`[Vuetify] Could not find layout item "${E}"`);return{...Re,height:fe?`calc(100% - ${ye.top}px - ${ye.bottom}px)`:j.value?`${j.value}px`:void 0,left:Q?void 0:`${ye.left}px`,right:Q?`${ye.right}px`:void 0,top:$.value!=="bottom"?`${ye.top}px`:void 0,bottom:$.value!=="top"?`${ye.bottom}px`:void 0,width:fe?j.value?`${j.value}px`:void 0:`calc(100% - ${ye.left}px - ${ye.right}px)`}}),V=w(()=>({zIndex:ue.value-1}));return{layoutItemStyles:we,layoutItemScrimStyles:V,zIndex:ue}},unregister:D=>{a.delete(D),s.delete(D),o.delete(D),i.delete(D),l.delete(D),r.value=r.value.filter(C=>C!==D)},mainRect:h,mainStyles:v,getLayoutItem:p,items:m,layoutRect:c,rootZIndex:n,layoutIsReady:S});const T=w(()=>["v-layout",{"v-layout--full-height":e.fullHeight}]),M=w(()=>({zIndex:t?n.value:void 0,position:t?"relative":void 0,overflow:t?"hidden":void 0}));return{layoutClasses:T,layoutStyles:M,getLayoutItem:p,items:m,layoutRect:c,layoutIsReady:S,layoutRef:u}}function Jv(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};const{blueprint:t,...n}=e,r=at(t,n),{aliases:s={},components:o={},directives:a={}}=r,i=t1(r.defaults),l=ew(r.display,r.ssr),u=fw(r.theme),c=lw(r.icons),f=l1(r.locale),d=J1(r.date,f),h=rw(r.goTo,f);return{install:m=>{for(const p in a)m.directive(p,a[p]);for(const p in o)m.component(p,o[p]);for(const p in s)m.component(p,co({...s[p],name:p,aliasName:s[p].name}));if(u.install(m),m.provide(qr,i),m.provide(sl,l),m.provide(Ks,u),m.provide(ol,c),m.provide(oa,f),m.provide(Z1,d.options),m.provide(of,d.instance),m.provide(Uv,h),ot&&r.ssr)if(m.$nuxt)m.$nuxt.hook("app:suspense:resolve",()=>{l.update()});else{const{mount:p}=m;m.mount=function(){const b=p(...arguments);return Ot(()=>l.update()),m.mount=p,b}}Ra.reset(),m.mixin({computed:{$vuetify(){return je({defaults:Or.call(this,qr),display:Or.call(this,sl),theme:Or.call(this,Ks),icons:Or.call(this,ol),locale:Or.call(this,oa),date:Or.call(this,of)})}}})},defaults:i,display:l,theme:u,icons:c,locale:f,date:d,goTo:h}}const gw="3.6.14";Jv.version=gw;function Or(e){const t=this.$,n=t.parent?.provides??t.vnode.appContext?.provides;if(n&&e in n)return n[e]}var yw="M13,13H11V7H13M13,17H11V15H13M12,2A10,10 0 0,0 2,12A10,10 0 0,0 12,22A10,10 0 0,0 22,12A10,10 0 0,0 12,2Z",bw="M15.41,16.58L10.83,12L15.41,7.41L14,6L8,12L14,18L15.41,16.58Z",ww="M8.59,16.58L13.17,12L8.59,7.41L10,6L16,12L10,18L8.59,16.58Z",WY="M19,3H14.82C14.4,1.84 13.3,1 12,1C10.7,1 9.6,1.84 9.18,3H5A2,2 0 0,0 3,5V19A2,2 0 0,0 5,21H19A2,2 0 0,0 21,19V5A2,2 0 0,0 19,3M12,3A1,1 0 0,1 13,4A1,1 0 0,1 12,5A1,1 0 0,1 11,4A1,1 0 0,1 12,3M7,7H17V5H19V19H5V5H7V7M7.5,13.5L9,12L11,14L15.5,9.5L17,11L11,17L7.5,13.5Z",_w="M19,6.41L17.59,5L12,10.59L6.41,5L5,6.41L10.59,12L5,17.59L6.41,19L12,13.41L17.59,19L19,17.59L13.41,12L19,6.41Z",UY="M19,21H8V7H19M19,5H8A2,2 0 0,0 6,7V21A2,2 0 0,0 8,23H19A2,2 0 0,0 21,21V7A2,2 0 0,0 19,5M16,1H4A2,2 0 0,0 2,3V17H4V3H16V1Z",zY="M5,3C3.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,3H5M15.78,5H19V17.18C18.74,16.38 17.69,15.79 16.8,15.79H15.8V12.79A1,1 0 0,0 14.8,11.79H8.8V9.79H10.8A1,1 0 0,0 11.8,8.79V6.79H13.8C14.83,6.79 15.67,6 15.78,5M5,10.29L9.8,14.79V15.79C9.8,16.9 10.7,17.79 11.8,17.79V19H5V10.29Z",KY="M9,3L3.36,4.9C3.16,4.97 3,5.15 3,5.38V20.5A0.5,0.5 0 0,0 3.5,21C3.55,21 3.6,21 3.66,20.97L9,18.9L13.16,20.36C13.06,19.92 13,19.46 13,19C13,18.77 13,18.54 13.04,18.3L9,16.9V5L15,7.1V14.56C16.07,13.6 17.47,13 19,13C19.7,13 20.37,13.13 21,13.36V3.5A0.5,0.5 0 0,0 20.5,3H20.34L15,5.1L9,3M18,15V18H15V20H18V23H20V20H23V18H20V15H18Z",Dw="M7,10L12,15L17,10H7Z",GY="M1,12L5,16V13H17.17C17.58,14.17 18.69,15 20,15A3,3 0 0,0 23,12A3,3 0 0,0 20,9C18.69,9 17.58,9.83 17.17,11H5V8L1,12Z",qY="M23,12L19,16V13H6.83C6.42,14.17 5.31,15 4,15A3,3 0 0,1 1,12A3,3 0 0,1 4,9C5.31,9 6.42,9.83 6.83,11H19V8L23,12Z";const Cw=Jv({icons:{aliases:{next:[ww],prev:[bw],subgroup:[Dw]}},theme:{themes:{dashboardTheme:{},light:{colors:{primary:"#1867C0",secondary:"#5CBBF6"}}}}});var Sw=!1;/*! +`)}function vf(e){const t=e.dark?2:1,n=e.dark?1:2,r=[];for(const[s,o]of Object.entries(e.colors)){const a=nn(o);r.push(`--v-theme-${s}: ${a.r},${a.g},${a.b}`),s.startsWith("on-")||r.push(`--v-theme-${s}-overlay-multiplier: ${Z0(o)>.18?t:n}`)}for(const[s,o]of Object.entries(e.variables)){const a=typeof o=="string"&&o.startsWith("#")?nn(o):void 0,i=a?`${a.r}, ${a.g}, ${a.b}`:void 0;r.push(`--v-${s}: ${i??o}`)}return r}function Gv(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"content";const n=E0(),r=oe();if(ot){const s=new ResizeObserver(o=>{e?.(o,s),o.length&&(t==="content"?r.value=o[0].contentRect:r.value=o[0].target.getBoundingClientRect())});yr(()=>{s.disconnect()}),Te(()=>n.el,(o,a)=>{a&&(s.unobserve(a),r.value=void 0),o&&s.observe(o)},{flush:"post"})}return{resizeRef:n,contentRect:Ea(r)}}const ia=Symbol.for("vuetify:layout"),qv=Symbol.for("vuetify:layout-item"),mf=1e3,cw=$e({overlaps:{type:Array,default:()=>[]},fullHeight:Boolean},"layout"),NY=$e({name:{type:String},order:{type:[Number,String],default:0},absolute:Boolean},"layout-item");function fw(){const e=Pe(ia);if(!e)throw new Error("[Vuetify] Could not find injected layout");return{layoutIsReady:Ot(),getLayoutItem:e.getLayoutItem,mainRect:e.mainRect,mainStyles:e.mainStyles}}function FY(e){const t=Pe(ia);if(!t)throw new Error("[Vuetify] Could not find injected layout");const n=e.id??`layout-item-${Ra()}`,r=St("useLayoutItem");Pt(qv,{id:n});const s=Ut(!1);jh(()=>s.value=!0),Hh(()=>s.value=!1);const o=Ot(),{layoutItemStyles:a,layoutItemScrimStyles:i}=t.register(r,{...e,active:w(()=>s.value?!1:e.active.value),id:n});return yr(()=>t.unregister(n)),{layoutItemStyles:a,layoutRect:t.layoutRect,layoutItemScrimStyles:i,layoutIsReady:o}}const dw=(e,t,n,r)=>{let s={top:0,left:0,right:0,bottom:0};const o=[{id:"",layer:{...s}}];for(const a of e){const i=t.get(a),l=n.get(a),u=r.get(a);if(!i||!l||!u)continue;const c={...s,[i.value]:parseInt(s[i.value],10)+(u.value?parseInt(l.value,10):0)};o.push({id:a,layer:c}),s=c}return o};function hw(e){const t=Pe(ia,null),n=w(()=>t?t.rootZIndex.value-100:mf),r=oe([]),s=je(new Map),o=je(new Map),a=je(new Map),i=je(new Map),l=je(new Map),{resizeRef:u,contentRect:c}=Gv(),f=Vc(()=>{const D=[...new Set([...a.values()].map(E=>E.value))].sort((E,P)=>E-P),C=[];for(const E of D){const P=r.value.filter($=>a.get($)?.value===E);C.push(...P)}return dw(C,s,o,i)}),d=w(()=>!Array.from(l.values()).some(D=>D.value)),h=w(()=>f.value[f.value.length-1].layer),v=w(()=>({"--v-layout-left":Fe(h.value.left),"--v-layout-right":Fe(h.value.right),"--v-layout-top":Fe(h.value.top),"--v-layout-bottom":Fe(h.value.bottom),...d.value?void 0:{transition:"none"}})),m=Vc(()=>f.value.slice(1).map((D,C)=>{let{id:E}=D;const{layer:P}=f.value[C],$=o.get(E),I=s.get(E);return{id:E,...P,size:Number($.value),position:I.value}})),p=D=>m.value.find(C=>C.id===D),b=St("createLayout"),S=Ot();Pt(ia,{register:(D,C)=>{let{id:E,order:P,position:$,layoutSize:I,elementSize:j,active:O,disableTransitions:W,absolute:re}=C;a.set(E,P),s.set(E,$),o.set(E,I),i.set(E,O),W&&l.set(E,W);const ee=xr(qv,b?.vnode).indexOf(D);ee>-1?r.value.splice(ee,0,E):r.value.push(E);const J=w(()=>m.value.findIndex(fe=>fe.id===E)),ue=w(()=>n.value+f.value.length*2-J.value*2),we=w(()=>{const fe=$.value==="left"||$.value==="right",Q=$.value==="right",Le=$.value==="bottom",pe=j.value??I.value,Ye=pe===0?"%":"px",Re={[$.value]:0,zIndex:ue.value,transform:`translate${fe?"X":"Y"}(${(O.value?0:-(pe===0?100:pe))*(Q||Le?-1:1)}${Ye})`,position:re.value||n.value!==mf?"absolute":"fixed",...d.value?void 0:{transition:"none"}};if(J.value<0)throw new Error(`Layout item "${E}" is missing`);const ye=m.value[J.value];if(!ye)throw new Error(`[Vuetify] Could not find layout item "${E}"`);return{...Re,height:fe?`calc(100% - ${ye.top}px - ${ye.bottom}px)`:j.value?`${j.value}px`:void 0,left:Q?void 0:`${ye.left}px`,right:Q?`${ye.right}px`:void 0,top:$.value!=="bottom"?`${ye.top}px`:void 0,bottom:$.value!=="top"?`${ye.bottom}px`:void 0,width:fe?j.value?`${j.value}px`:void 0:`calc(100% - ${ye.left}px - ${ye.right}px)`}}),V=w(()=>({zIndex:ue.value-1}));return{layoutItemStyles:we,layoutItemScrimStyles:V,zIndex:ue}},unregister:D=>{a.delete(D),s.delete(D),o.delete(D),i.delete(D),l.delete(D),r.value=r.value.filter(C=>C!==D)},mainRect:h,mainStyles:v,getLayoutItem:p,items:m,layoutRect:c,rootZIndex:n,layoutIsReady:S});const T=w(()=>["v-layout",{"v-layout--full-height":e.fullHeight}]),M=w(()=>({zIndex:t?n.value:void 0,position:t?"relative":void 0,overflow:t?"hidden":void 0}));return{layoutClasses:T,layoutStyles:M,getLayoutItem:p,items:m,layoutRect:c,layoutIsReady:S,layoutRef:u}}function Zv(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};const{blueprint:t,...n}=e,r=at(t,n),{aliases:s={},components:o={},directives:a={}}=r,i=X0(r.defaults),l=J1(r.display,r.ssr),u=lw(r.theme),c=ow(r.icons),f=o1(r.locale),d=G1(r.date,f),h=ew(r.goTo,f);return{install:m=>{for(const p in a)m.directive(p,a[p]);for(const p in o)m.component(p,o[p]);for(const p in s)m.component(p,co({...s[p],name:p,aliasName:s[p].name}));if(u.install(m),m.provide(qr,i),m.provide(rl,l),m.provide(Ks,u),m.provide(sl,c),m.provide(oa,f),m.provide(K1,d.options),m.provide(of,d.instance),m.provide(Wv,h),ot&&r.ssr)if(m.$nuxt)m.$nuxt.hook("app:suspense:resolve",()=>{l.update()});else{const{mount:p}=m;m.mount=function(){const b=p(...arguments);return Ot(()=>l.update()),m.mount=p,b}}Ra.reset(),m.mixin({computed:{$vuetify(){return je({defaults:Or.call(this,qr),display:Or.call(this,rl),theme:Or.call(this,Ks),icons:Or.call(this,sl),locale:Or.call(this,oa),date:Or.call(this,of)})}}})},defaults:i,display:l,theme:u,icons:c,locale:f,date:d,goTo:h}}const vw="3.6.14";Zv.version=vw;function Or(e){const t=this.$,n=t.parent?.provides??t.vnode.appContext?.provides;if(n&&e in n)return n[e]}var mw="M13,13H11V7H13M13,17H11V15H13M12,2A10,10 0 0,0 2,12A10,10 0 0,0 12,22A10,10 0 0,0 22,12A10,10 0 0,0 12,2Z",pw="M15.41,16.58L10.83,12L15.41,7.41L14,6L8,12L14,18L15.41,16.58Z",gw="M8.59,16.58L13.17,12L8.59,7.41L10,6L16,12L10,18L8.59,16.58Z",YY="M19,3H14.82C14.4,1.84 13.3,1 12,1C10.7,1 9.6,1.84 9.18,3H5A2,2 0 0,0 3,5V19A2,2 0 0,0 5,21H19A2,2 0 0,0 21,19V5A2,2 0 0,0 19,3M12,3A1,1 0 0,1 13,4A1,1 0 0,1 12,5A1,1 0 0,1 11,4A1,1 0 0,1 12,3M7,7H17V5H19V19H5V5H7V7M7.5,13.5L9,12L11,14L15.5,9.5L17,11L11,17L7.5,13.5Z",yw="M19,6.41L17.59,5L12,10.59L6.41,5L5,6.41L10.59,12L5,17.59L6.41,19L12,13.41L17.59,19L19,17.59L13.41,12L19,6.41Z",BY="M19,21H8V7H19M19,5H8A2,2 0 0,0 6,7V21A2,2 0 0,0 8,23H19A2,2 0 0,0 21,21V7A2,2 0 0,0 19,5M16,1H4A2,2 0 0,0 2,3V17H4V3H16V1Z",HY="M5,3C3.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,3H5M15.78,5H19V17.18C18.74,16.38 17.69,15.79 16.8,15.79H15.8V12.79A1,1 0 0,0 14.8,11.79H8.8V9.79H10.8A1,1 0 0,0 11.8,8.79V6.79H13.8C14.83,6.79 15.67,6 15.78,5M5,10.29L9.8,14.79V15.79C9.8,16.9 10.7,17.79 11.8,17.79V19H5V10.29Z",jY="M9,3L3.36,4.9C3.16,4.97 3,5.15 3,5.38V20.5A0.5,0.5 0 0,0 3.5,21C3.55,21 3.6,21 3.66,20.97L9,18.9L13.16,20.36C13.06,19.92 13,19.46 13,19C13,18.77 13,18.54 13.04,18.3L9,16.9V5L15,7.1V14.56C16.07,13.6 17.47,13 19,13C19.7,13 20.37,13.13 21,13.36V3.5A0.5,0.5 0 0,0 20.5,3H20.34L15,5.1L9,3M18,15V18H15V20H18V23H20V20H23V18H20V15H18Z",bw="M7,10L12,15L17,10H7Z",VY="M1,12L5,16V13H17.17C17.58,14.17 18.69,15 20,15A3,3 0 0,0 23,12A3,3 0 0,0 20,9C18.69,9 17.58,9.83 17.17,11H5V8L1,12Z",WY="M23,12L19,16V13H6.83C6.42,14.17 5.31,15 4,15A3,3 0 0,1 1,12A3,3 0 0,1 4,9C5.31,9 6.42,9.83 6.83,11H19V8L23,12Z";const ww=Zv({icons:{aliases:{next:[gw],prev:[pw],subgroup:[bw]}},theme:{themes:{dashboardTheme:{},light:{colors:{primary:"#1867C0",secondary:"#5CBBF6"}}}}});var _w=!1;/*! * pinia v2.2.0 * (c) 2024 Eduardo San Martin Morote * @license MIT - */let Xv;const ja=e=>Xv=e,Qv=Symbol();function al(e){return e&&typeof e=="object"&&Object.prototype.toString.call(e)==="[object Object]"&&typeof e.toJSON!="function"}var Ls;(function(e){e.direct="direct",e.patchObject="patch object",e.patchFunction="patch function"})(Ls||(Ls={}));function $w(){const e=Il(!0),t=e.run(()=>oe({}));let n=[],r=[];const s=jl({install(o){ja(s),s._a=o,o.provide(Qv,s),o.config.globalProperties.$pinia=s,r.forEach(a=>n.push(a)),r=[]},use(o){return!this._a&&!Sw?r.push(o):n.push(o),this},_p:n,_a:null,_e:e,_s:new Map,state:t});return s}const em=()=>{};function pf(e,t,n,r=em){e.push(t);const s=()=>{const o=e.indexOf(t);o>-1&&(e.splice(o,1),r())};return!n&&ph()&&Ll(s),s}function Mr(e,...t){e.slice().forEach(n=>{n(...t)})}const Tw=e=>e(),gf=Symbol(),Di=Symbol();function il(e,t){e instanceof Map&&t instanceof Map?t.forEach((n,r)=>e.set(r,n)):e instanceof Set&&t instanceof Set&&t.forEach(e.add,e);for(const n in t){if(!t.hasOwnProperty(n))continue;const r=t[n],s=e[n];al(s)&&al(r)&&e.hasOwnProperty(n)&&!Se(r)&&!Yn(r)?e[n]=il(s,r):e[n]=r}return e}const Ew=Symbol();function Ow(e){return!al(e)||!e.hasOwnProperty(Ew)}const{assign:kn}=Object;function Mw(e){return!!(Se(e)&&e.effect)}function xw(e,t,n,r){const{state:s,actions:o,getters:a}=t,i=n.state.value[e];let l;function u(){i||(n.state.value[e]=s?s():{});const c=no(n.state.value[e]);return kn(c,o,Object.keys(a||{}).reduce((f,d)=>(f[d]=jl(w(()=>{ja(n);const h=n._s.get(e);return a[d].call(h,h)})),f),{}))}return l=tm(e,u,t,n,r,!0),l}function tm(e,t,n={},r,s,o){let a;const i=kn({actions:{}},n),l={deep:!0};let u,c,f=[],d=[],h;const v=r.state.value[e];!o&&!v&&(r.state.value[e]={}),oe({});let m;function p(P){let $;u=c=!1,typeof P=="function"?(P(r.state.value[e]),$={type:Ls.patchFunction,storeId:e,events:h}):(il(r.state.value[e],P),$={type:Ls.patchObject,payload:P,storeId:e,events:h});const I=m=Symbol();Ot().then(()=>{m===I&&(u=!0)}),c=!0,Mr(f,$,r.state.value[e])}const b=o?function(){const{state:$}=n,I=$?$():{};this.$patch(j=>{kn(j,I)})}:em;function S(){a.stop(),f=[],d=[],r._s.delete(e)}const T=(P,$="")=>{if(gf in P)return P[Di]=$,P;const I=function(){ja(r);const j=Array.from(arguments),O=[],W=[];function re(J){O.push(J)}function X(J){W.push(J)}Mr(d,{args:j,name:I[Di],store:D,after:re,onError:X});let ee;try{ee=P.apply(this&&this.$id===e?this:D,j)}catch(J){throw Mr(W,J),J}return ee instanceof Promise?ee.then(J=>(Mr(O,J),J)).catch(J=>(Mr(W,J),Promise.reject(J))):(Mr(O,ee),ee)};return I[gf]=!0,I[Di]=$,I},M={_p:r,$id:e,$onAction:pf.bind(null,d),$patch:p,$reset:b,$subscribe(P,$={}){const I=pf(f,P,$.detached,()=>j()),j=a.run(()=>Te(()=>r.state.value[e],O=>{($.flush==="sync"?c:u)&&P({storeId:e,type:Ls.direct,events:h},O)},kn({},l,$)));return I},$dispose:S},D=je(M);r._s.set(e,D);const E=(r._a&&r._a.runWithContext||Tw)(()=>r._e.run(()=>(a=Il()).run(()=>t({action:T}))));for(const P in E){const $=E[P];if(Se($)&&!Mw($)||Yn($))o||(v&&Ow($)&&(Se($)?$.value=v[P]:il($,v[P])),r.state.value[e][P]=$);else if(typeof $=="function"){const I=T($,P);E[P]=I,i.actions[P]=$}}return kn(D,E),kn(ge(D),E),Object.defineProperty(D,"$state",{get:()=>r.state.value[e],set:P=>{p($=>{kn($,P)})}}),r._p.forEach(P=>{kn(D,a.run(()=>P({store:D,app:r._a,pinia:r,options:i})))}),v&&o&&n.hydrate&&n.hydrate(D.$state,v),u=!0,c=!0,D}function kw(e,t,n){let r,s;const o=typeof t=="function";r=e,s=o?n:t;function a(i,l){const u=qy();return i=i||(u?Pe(Qv,null):null),i&&ja(i),i=Xv,i._s.has(r)||(o?tm(r,t,s,i):xw(r,s,i)),i._s.get(r)}return a.$id=r,a}function Pw(e){{e=ge(e);const t={};for(const n in e){const r=e[n];(Se(r)||Yn(r))&&(t[n]=et(e,n))}return t}}const Aw="modulepreload",Iw=function(e){return"/eodash-instance-template/pr-preview/pr-17/"+e},yf={},Xe=function(t,n,r){let s=Promise.resolve();if(n&&n.length>0){document.getElementsByTagName("link");const o=document.querySelector("meta[property=csp-nonce]"),a=o?.nonce||o?.getAttribute("nonce");s=Promise.all(n.map(i=>{if(i=Iw(i),i in yf)return;yf[i]=!0;const l=i.endsWith(".css"),u=l?'[rel="stylesheet"]':"";if(document.querySelector(`link[href="${i}"]${u}`))return;const c=document.createElement("link");if(c.rel=l?"stylesheet":Aw,l||(c.as="script",c.crossOrigin=""),c.href=i,a&&c.setAttribute("nonce",a),document.head.appendChild(c),l)return new Promise((f,d)=>{c.addEventListener("load",f),c.addEventListener("error",()=>d(new Error(`Unable to preload CSS for ${i}`)))})}))}return s.then(()=>t()).catch(o=>{const a=new Event("vite:preloadError",{cancelable:!0});if(a.payload=o,window.dispatchEvent(a),!a.defaultPrevented)throw o})},Pr=oe(""),Ts=oe(""),Yo=oe(new Date().toISOString()),au=oe(""),ll=oe([]),la=["EPSG:4326","EPSG:3857"],Lw=oe(""),Br=oe(null),Rw=Object.freeze(Object.defineProperty({__proto__:null,availableMapProjection:Lw,currentCompareUrl:Ts,currentUrl:Pr,datetime:Yo,indicator:au,mapEl:Br,mapPosition:ll,registeredProjections:la},Symbol.toStringTag,{value:"Module"})),iu=je({id:"demo",stacEndpoint:"https://eodashcatalog.eox.at/test-style/trilateral/catalog.json",brand:{noLayout:!0,name:"Demo",theme:{colors:{primary:"#fff",secondary:"#fff",surface:"#fff"}},footerText:"Demo configuration of eodash client"},template:{loading:{id:Symbol(),type:"web-component",widget:{link:"https://cdn.jsdelivr.net/npm/ldrs/dist/auto/mirage.js",tagName:"l-mirage",properties:{class:"align-self-center justify-self-center",size:"120",speed:"2.5",color:"#004170"}}},background:{id:Symbol(),type:"internal",widget:{name:"EodashMap",properties:{}}},widgets:[{id:Symbol(),type:"internal",title:"Indicators",layout:{x:0,y:0,w:3,h:8},widget:{name:"EodashItemFilter",properties:{aggregateResults:"collection_group"}}},{id:Symbol(),type:"internal",title:"Layer Control",layout:{x:0,y:8,w:3,h:4},widget:{name:"EodashLayerControl"}},{defineWidget:e=>e?{id:"Information",title:"Information",layout:{x:9,y:0,w:3,h:12},type:"web-component",widget:{link:async()=>await Xe(()=>import("./eox-stacinfo-CES29oXd.js"),[]),properties:{for:Pr,allowHtml:"true",styleOverride:`.single-property {columns: 1!important;} + */let Jv;const ja=e=>Jv=e,Xv=Symbol();function ol(e){return e&&typeof e=="object"&&Object.prototype.toString.call(e)==="[object Object]"&&typeof e.toJSON!="function"}var Ls;(function(e){e.direct="direct",e.patchObject="patch object",e.patchFunction="patch function"})(Ls||(Ls={}));function Dw(){const e=Al(!0),t=e.run(()=>oe({}));let n=[],r=[];const s=Hl({install(o){ja(s),s._a=o,o.provide(Xv,s),o.config.globalProperties.$pinia=s,r.forEach(a=>n.push(a)),r=[]},use(o){return!this._a&&!_w?r.push(o):n.push(o),this},_p:n,_a:null,_e:e,_s:new Map,state:t});return s}const Qv=()=>{};function pf(e,t,n,r=Qv){e.push(t);const s=()=>{const o=e.indexOf(t);o>-1&&(e.splice(o,1),r())};return!n&&ph()&&Il(s),s}function Mr(e,...t){e.slice().forEach(n=>{n(...t)})}const Cw=e=>e(),gf=Symbol(),Di=Symbol();function al(e,t){e instanceof Map&&t instanceof Map?t.forEach((n,r)=>e.set(r,n)):e instanceof Set&&t instanceof Set&&t.forEach(e.add,e);for(const n in t){if(!t.hasOwnProperty(n))continue;const r=t[n],s=e[n];ol(s)&&ol(r)&&e.hasOwnProperty(n)&&!Se(r)&&!Yn(r)?e[n]=al(s,r):e[n]=r}return e}const Sw=Symbol();function $w(e){return!ol(e)||!e.hasOwnProperty(Sw)}const{assign:xn}=Object;function Tw(e){return!!(Se(e)&&e.effect)}function Ew(e,t,n,r){const{state:s,actions:o,getters:a}=t,i=n.state.value[e];let l;function u(){i||(n.state.value[e]=s?s():{});const c=no(n.state.value[e]);return xn(c,o,Object.keys(a||{}).reduce((f,d)=>(f[d]=Hl(w(()=>{ja(n);const h=n._s.get(e);return a[d].call(h,h)})),f),{}))}return l=em(e,u,t,n,r,!0),l}function em(e,t,n={},r,s,o){let a;const i=xn({actions:{}},n),l={deep:!0};let u,c,f=[],d=[],h;const v=r.state.value[e];!o&&!v&&(r.state.value[e]={}),oe({});let m;function p(P){let $;u=c=!1,typeof P=="function"?(P(r.state.value[e]),$={type:Ls.patchFunction,storeId:e,events:h}):(al(r.state.value[e],P),$={type:Ls.patchObject,payload:P,storeId:e,events:h});const I=m=Symbol();Ot().then(()=>{m===I&&(u=!0)}),c=!0,Mr(f,$,r.state.value[e])}const b=o?function(){const{state:$}=n,I=$?$():{};this.$patch(j=>{xn(j,I)})}:Qv;function S(){a.stop(),f=[],d=[],r._s.delete(e)}const T=(P,$="")=>{if(gf in P)return P[Di]=$,P;const I=function(){ja(r);const j=Array.from(arguments),O=[],W=[];function re(J){O.push(J)}function X(J){W.push(J)}Mr(d,{args:j,name:I[Di],store:D,after:re,onError:X});let ee;try{ee=P.apply(this&&this.$id===e?this:D,j)}catch(J){throw Mr(W,J),J}return ee instanceof Promise?ee.then(J=>(Mr(O,J),J)).catch(J=>(Mr(W,J),Promise.reject(J))):(Mr(O,ee),ee)};return I[gf]=!0,I[Di]=$,I},M={_p:r,$id:e,$onAction:pf.bind(null,d),$patch:p,$reset:b,$subscribe(P,$={}){const I=pf(f,P,$.detached,()=>j()),j=a.run(()=>Te(()=>r.state.value[e],O=>{($.flush==="sync"?c:u)&&P({storeId:e,type:Ls.direct,events:h},O)},xn({},l,$)));return I},$dispose:S},D=je(M);r._s.set(e,D);const E=(r._a&&r._a.runWithContext||Cw)(()=>r._e.run(()=>(a=Al()).run(()=>t({action:T}))));for(const P in E){const $=E[P];if(Se($)&&!Tw($)||Yn($))o||(v&&$w($)&&(Se($)?$.value=v[P]:al($,v[P])),r.state.value[e][P]=$);else if(typeof $=="function"){const I=T($,P);E[P]=I,i.actions[P]=$}}return xn(D,E),xn(ge(D),E),Object.defineProperty(D,"$state",{get:()=>r.state.value[e],set:P=>{p($=>{xn($,P)})}}),r._p.forEach(P=>{xn(D,a.run(()=>P({store:D,app:r._a,pinia:r,options:i})))}),v&&o&&n.hydrate&&n.hydrate(D.$state,v),u=!0,c=!0,D}function Ow(e,t,n){let r,s;const o=typeof t=="function";r=e,s=o?n:t;function a(i,l){const u=Gy();return i=i||(u?Pe(Xv,null):null),i&&ja(i),i=Jv,i._s.has(r)||(o?em(r,t,s,i):Ew(r,s,i)),i._s.get(r)}return a.$id=r,a}function Mw(e){{e=ge(e);const t={};for(const n in e){const r=e[n];(Se(r)||Yn(r))&&(t[n]=et(e,n))}return t}}const kw="modulepreload",xw=function(e){return"/eodash-instance-template/pr-preview/pr-17/"+e},yf={},Qe=function(t,n,r){let s=Promise.resolve();if(n&&n.length>0){document.getElementsByTagName("link");const o=document.querySelector("meta[property=csp-nonce]"),a=o?.nonce||o?.getAttribute("nonce");s=Promise.all(n.map(i=>{if(i=xw(i),i in yf)return;yf[i]=!0;const l=i.endsWith(".css"),u=l?'[rel="stylesheet"]':"";if(document.querySelector(`link[href="${i}"]${u}`))return;const c=document.createElement("link");if(c.rel=l?"stylesheet":kw,l||(c.as="script",c.crossOrigin=""),c.href=i,a&&c.setAttribute("nonce",a),document.head.appendChild(c),l)return new Promise((f,d)=>{c.addEventListener("load",f),c.addEventListener("error",()=>d(new Error(`Unable to preload CSS for ${i}`)))})}))}return s.then(()=>t()).catch(o=>{const a=new Event("vite:preloadError",{cancelable:!0});if(a.payload=o,window.dispatchEvent(a),!a.defaultPrevented)throw o})},Pr=oe(""),Ts=oe(""),Yo=oe(new Date().toISOString()),ou=oe(""),il=oe([]),la=["EPSG:4326","EPSG:3857"],Pw=oe(""),Br=oe(null),Aw=Object.freeze(Object.defineProperty({__proto__:null,availableMapProjection:Pw,currentCompareUrl:Ts,currentUrl:Pr,datetime:Yo,indicator:ou,mapEl:Br,mapPosition:il,registeredProjections:la},Symbol.toStringTag,{value:"Module"})),au=je({id:"demo",stacEndpoint:"https://eodashcatalog.eox.at/test-style/trilateral/catalog.json",brand:{noLayout:!0,name:"Demo",theme:{colors:{primary:"#fff",secondary:"#fff",surface:"#fff"}},footerText:"Demo configuration of eodash client"},template:{loading:{id:Symbol(),type:"web-component",widget:{link:"https://cdn.jsdelivr.net/npm/ldrs/dist/auto/mirage.js",tagName:"l-mirage",properties:{class:"align-self-center justify-self-center",size:"120",speed:"2.5",color:"#004170"}}},background:{id:Symbol(),type:"internal",widget:{name:"EodashMap",properties:{}}},widgets:[{id:Symbol(),type:"internal",title:"Indicators",layout:{x:0,y:0,w:3,h:8},widget:{name:"EodashItemFilter",properties:{aggregateResults:"collection_group"}}},{id:Symbol(),type:"internal",title:"Layer Control",layout:{x:0,y:8,w:3,h:4},widget:{name:"EodashLayerControl"}},{defineWidget:e=>e?{id:"Information",title:"Information",layout:{x:9,y:0,w:3,h:12},type:"web-component",widget:{link:async()=>await Qe(()=>import("./eox-stacinfo-CES29oXd.js"),[]),properties:{for:Pr,allowHtml:"true",styleOverride:`.single-property {columns: 1!important;} h1 {margin:0px!important;font-size:16px!important;} header h1:after { content:' '; @@ -37,21 +37,21 @@ Expected #hex, #hexa, rgb(), rgba(), hsl(), hsla(), object or number`)}function main {padding-bottom: 10px;} .footer-container {line-height:1;} .footer-container button {margin-top: -10px;} - .footer-container small {font-size:10px;line-height:1;}`,header:'["title"]',tags:'["themes"]',subheader:"[]",properties:'["satellite","sensor","agency","extent"]',featured:'["description","providers","assets","links"]',footer:'["sci:citation"]'},tagName:"eox-stacinfo"}}:null},{defineWidget:e=>e?{id:"Datepicker",type:"internal",layout:{x:5,y:10,w:1,h:1},title:"Datepicker",widget:{name:"EodashDatePicker"}}:null},{defineWidget:e=>e?{id:"Buttons",layout:{x:8,y:0,w:1,h:1},title:"Buttons",type:"internal",widget:{name:"EodashMapBtns"}}:null}]}});var wt="top",Ht="bottom",jt="right",_t="left",lu="auto",fo=[wt,Ht,jt,_t],Zr="start",Gs="end",Nw="clippingParents",nm="viewport",ws="popper",Fw="reference",bf=fo.reduce(function(e,t){return e.concat([t+"-"+Zr,t+"-"+Gs])},[]),rm=[].concat(fo,[lu]).reduce(function(e,t){return e.concat([t,t+"-"+Zr,t+"-"+Gs])},[]),Yw="beforeRead",Bw="read",Hw="afterRead",jw="beforeMain",Vw="main",Ww="afterMain",Uw="beforeWrite",zw="write",Kw="afterWrite",Gw=[Yw,Bw,Hw,jw,Vw,Ww,Uw,zw,Kw];function an(e){return e?(e.nodeName||"").toLowerCase():null}function kt(e){if(e==null)return window;if(e.toString()!=="[object Window]"){var t=e.ownerDocument;return t&&t.defaultView||window}return e}function mr(e){var t=kt(e).Element;return e instanceof t||e instanceof Element}function Yt(e){var t=kt(e).HTMLElement;return e instanceof t||e instanceof HTMLElement}function uu(e){if(typeof ShadowRoot>"u")return!1;var t=kt(e).ShadowRoot;return e instanceof t||e instanceof ShadowRoot}function qw(e){var t=e.state;Object.keys(t.elements).forEach(function(n){var r=t.styles[n]||{},s=t.attributes[n]||{},o=t.elements[n];!Yt(o)||!an(o)||(Object.assign(o.style,r),Object.keys(s).forEach(function(a){var i=s[a];i===!1?o.removeAttribute(a):o.setAttribute(a,i===!0?"":i)}))})}function Zw(e){var t=e.state,n={popper:{position:t.options.strategy,left:"0",top:"0",margin:"0"},arrow:{position:"absolute"},reference:{}};return Object.assign(t.elements.popper.style,n.popper),t.styles=n,t.elements.arrow&&Object.assign(t.elements.arrow.style,n.arrow),function(){Object.keys(t.elements).forEach(function(r){var s=t.elements[r],o=t.attributes[r]||{},a=Object.keys(t.styles.hasOwnProperty(r)?t.styles[r]:n[r]),i=a.reduce(function(l,u){return l[u]="",l},{});!Yt(s)||!an(s)||(Object.assign(s.style,i),Object.keys(o).forEach(function(l){s.removeAttribute(l)}))})}}const Jw={name:"applyStyles",enabled:!0,phase:"write",fn:qw,effect:Zw,requires:["computeStyles"]};function on(e){return e.split("-")[0]}var fr=Math.max,ua=Math.min,Jr=Math.round;function ul(){var e=navigator.userAgentData;return e!=null&&e.brands&&Array.isArray(e.brands)?e.brands.map(function(t){return t.brand+"/"+t.version}).join(" "):navigator.userAgent}function sm(){return!/^((?!chrome|android).)*safari/i.test(ul())}function Xr(e,t,n){t===void 0&&(t=!1),n===void 0&&(n=!1);var r=e.getBoundingClientRect(),s=1,o=1;t&&Yt(e)&&(s=e.offsetWidth>0&&Jr(r.width)/e.offsetWidth||1,o=e.offsetHeight>0&&Jr(r.height)/e.offsetHeight||1);var a=mr(e)?kt(e):window,i=a.visualViewport,l=!sm()&&n,u=(r.left+(l&&i?i.offsetLeft:0))/s,c=(r.top+(l&&i?i.offsetTop:0))/o,f=r.width/s,d=r.height/o;return{width:f,height:d,top:c,right:u+f,bottom:c+d,left:u,x:u,y:c}}function cu(e){var t=Xr(e),n=e.offsetWidth,r=e.offsetHeight;return Math.abs(t.width-n)<=1&&(n=t.width),Math.abs(t.height-r)<=1&&(r=t.height),{x:e.offsetLeft,y:e.offsetTop,width:n,height:r}}function om(e,t){var n=t.getRootNode&&t.getRootNode();if(e.contains(t))return!0;if(n&&uu(n)){var r=t;do{if(r&&e.isSameNode(r))return!0;r=r.parentNode||r.host}while(r)}return!1}function yn(e){return kt(e).getComputedStyle(e)}function Xw(e){return["table","td","th"].indexOf(an(e))>=0}function Gn(e){return((mr(e)?e.ownerDocument:e.document)||window.document).documentElement}function Va(e){return an(e)==="html"?e:e.assignedSlot||e.parentNode||(uu(e)?e.host:null)||Gn(e)}function wf(e){return!Yt(e)||yn(e).position==="fixed"?null:e.offsetParent}function Qw(e){var t=/firefox/i.test(ul()),n=/Trident/i.test(ul());if(n&&Yt(e)){var r=yn(e);if(r.position==="fixed")return null}var s=Va(e);for(uu(s)&&(s=s.host);Yt(s)&&["html","body"].indexOf(an(s))<0;){var o=yn(s);if(o.transform!=="none"||o.perspective!=="none"||o.contain==="paint"||["transform","perspective"].indexOf(o.willChange)!==-1||t&&o.willChange==="filter"||t&&o.filter&&o.filter!=="none")return s;s=s.parentNode}return null}function ho(e){for(var t=kt(e),n=wf(e);n&&Xw(n)&&yn(n).position==="static";)n=wf(n);return n&&(an(n)==="html"||an(n)==="body"&&yn(n).position==="static")?t:n||Qw(e)||t}function fu(e){return["top","bottom"].indexOf(e)>=0?"x":"y"}function Rs(e,t,n){return fr(e,ua(t,n))}function e_(e,t,n){var r=Rs(e,t,n);return r>n?n:r}function am(){return{top:0,right:0,bottom:0,left:0}}function im(e){return Object.assign({},am(),e)}function lm(e,t){return t.reduce(function(n,r){return n[r]=e,n},{})}var t_=function(t,n){return t=typeof t=="function"?t(Object.assign({},n.rects,{placement:n.placement})):t,im(typeof t!="number"?t:lm(t,fo))};function n_(e){var t,n=e.state,r=e.name,s=e.options,o=n.elements.arrow,a=n.modifiersData.popperOffsets,i=on(n.placement),l=fu(i),u=[_t,jt].indexOf(i)>=0,c=u?"height":"width";if(!(!o||!a)){var f=t_(s.padding,n),d=cu(o),h=l==="y"?wt:_t,v=l==="y"?Ht:jt,m=n.rects.reference[c]+n.rects.reference[l]-a[l]-n.rects.popper[c],p=a[l]-n.rects.reference[l],b=ho(o),S=b?l==="y"?b.clientHeight||0:b.clientWidth||0:0,T=m/2-p/2,M=f[h],D=S-d[c]-f[v],C=S/2-d[c]/2+T,E=Rs(M,C,D),P=l;n.modifiersData[r]=(t={},t[P]=E,t.centerOffset=E-C,t)}}function r_(e){var t=e.state,n=e.options,r=n.element,s=r===void 0?"[data-popper-arrow]":r;s!=null&&(typeof s=="string"&&(s=t.elements.popper.querySelector(s),!s)||om(t.elements.popper,s)&&(t.elements.arrow=s))}const s_={name:"arrow",enabled:!0,phase:"main",fn:n_,effect:r_,requires:["popperOffsets"],requiresIfExists:["preventOverflow"]};function Qr(e){return e.split("-")[1]}var o_={top:"auto",right:"auto",bottom:"auto",left:"auto"};function a_(e,t){var n=e.x,r=e.y,s=t.devicePixelRatio||1;return{x:Jr(n*s)/s||0,y:Jr(r*s)/s||0}}function _f(e){var t,n=e.popper,r=e.popperRect,s=e.placement,o=e.variation,a=e.offsets,i=e.position,l=e.gpuAcceleration,u=e.adaptive,c=e.roundOffsets,f=e.isFixed,d=a.x,h=d===void 0?0:d,v=a.y,m=v===void 0?0:v,p=typeof c=="function"?c({x:h,y:m}):{x:h,y:m};h=p.x,m=p.y;var b=a.hasOwnProperty("x"),S=a.hasOwnProperty("y"),T=_t,M=wt,D=window;if(u){var C=ho(n),E="clientHeight",P="clientWidth";if(C===kt(n)&&(C=Gn(n),yn(C).position!=="static"&&i==="absolute"&&(E="scrollHeight",P="scrollWidth")),C=C,s===wt||(s===_t||s===jt)&&o===Gs){M=Ht;var $=f&&C===D&&D.visualViewport?D.visualViewport.height:C[E];m-=$-r.height,m*=l?1:-1}if(s===_t||(s===wt||s===Ht)&&o===Gs){T=jt;var I=f&&C===D&&D.visualViewport?D.visualViewport.width:C[P];h-=I-r.width,h*=l?1:-1}}var j=Object.assign({position:i},u&&o_),O=c===!0?a_({x:h,y:m},kt(n)):{x:h,y:m};if(h=O.x,m=O.y,l){var W;return Object.assign({},j,(W={},W[M]=S?"0":"",W[T]=b?"0":"",W.transform=(D.devicePixelRatio||1)<=1?"translate("+h+"px, "+m+"px)":"translate3d("+h+"px, "+m+"px, 0)",W))}return Object.assign({},j,(t={},t[M]=S?m+"px":"",t[T]=b?h+"px":"",t.transform="",t))}function i_(e){var t=e.state,n=e.options,r=n.gpuAcceleration,s=r===void 0?!0:r,o=n.adaptive,a=o===void 0?!0:o,i=n.roundOffsets,l=i===void 0?!0:i,u={placement:on(t.placement),variation:Qr(t.placement),popper:t.elements.popper,popperRect:t.rects.popper,gpuAcceleration:s,isFixed:t.options.strategy==="fixed"};t.modifiersData.popperOffsets!=null&&(t.styles.popper=Object.assign({},t.styles.popper,_f(Object.assign({},u,{offsets:t.modifiersData.popperOffsets,position:t.options.strategy,adaptive:a,roundOffsets:l})))),t.modifiersData.arrow!=null&&(t.styles.arrow=Object.assign({},t.styles.arrow,_f(Object.assign({},u,{offsets:t.modifiersData.arrow,position:"absolute",adaptive:!1,roundOffsets:l})))),t.attributes.popper=Object.assign({},t.attributes.popper,{"data-popper-placement":t.placement})}const l_={name:"computeStyles",enabled:!0,phase:"beforeWrite",fn:i_,data:{}};var xo={passive:!0};function u_(e){var t=e.state,n=e.instance,r=e.options,s=r.scroll,o=s===void 0?!0:s,a=r.resize,i=a===void 0?!0:a,l=kt(t.elements.popper),u=[].concat(t.scrollParents.reference,t.scrollParents.popper);return o&&u.forEach(function(c){c.addEventListener("scroll",n.update,xo)}),i&&l.addEventListener("resize",n.update,xo),function(){o&&u.forEach(function(c){c.removeEventListener("scroll",n.update,xo)}),i&&l.removeEventListener("resize",n.update,xo)}}const c_={name:"eventListeners",enabled:!0,phase:"write",fn:function(){},effect:u_,data:{}};var f_={left:"right",right:"left",bottom:"top",top:"bottom"};function Bo(e){return e.replace(/left|right|bottom|top/g,function(t){return f_[t]})}var d_={start:"end",end:"start"};function Df(e){return e.replace(/start|end/g,function(t){return d_[t]})}function du(e){var t=kt(e),n=t.pageXOffset,r=t.pageYOffset;return{scrollLeft:n,scrollTop:r}}function hu(e){return Xr(Gn(e)).left+du(e).scrollLeft}function h_(e,t){var n=kt(e),r=Gn(e),s=n.visualViewport,o=r.clientWidth,a=r.clientHeight,i=0,l=0;if(s){o=s.width,a=s.height;var u=sm();(u||!u&&t==="fixed")&&(i=s.offsetLeft,l=s.offsetTop)}return{width:o,height:a,x:i+hu(e),y:l}}function v_(e){var t,n=Gn(e),r=du(e),s=(t=e.ownerDocument)==null?void 0:t.body,o=fr(n.scrollWidth,n.clientWidth,s?s.scrollWidth:0,s?s.clientWidth:0),a=fr(n.scrollHeight,n.clientHeight,s?s.scrollHeight:0,s?s.clientHeight:0),i=-r.scrollLeft+hu(e),l=-r.scrollTop;return yn(s||n).direction==="rtl"&&(i+=fr(n.clientWidth,s?s.clientWidth:0)-o),{width:o,height:a,x:i,y:l}}function vu(e){var t=yn(e),n=t.overflow,r=t.overflowX,s=t.overflowY;return/auto|scroll|overlay|hidden/.test(n+s+r)}function um(e){return["html","body","#document"].indexOf(an(e))>=0?e.ownerDocument.body:Yt(e)&&vu(e)?e:um(Va(e))}function Ns(e,t){var n;t===void 0&&(t=[]);var r=um(e),s=r===((n=e.ownerDocument)==null?void 0:n.body),o=kt(r),a=s?[o].concat(o.visualViewport||[],vu(r)?r:[]):r,i=t.concat(a);return s?i:i.concat(Ns(Va(a)))}function cl(e){return Object.assign({},e,{left:e.x,top:e.y,right:e.x+e.width,bottom:e.y+e.height})}function m_(e,t){var n=Xr(e,!1,t==="fixed");return n.top=n.top+e.clientTop,n.left=n.left+e.clientLeft,n.bottom=n.top+e.clientHeight,n.right=n.left+e.clientWidth,n.width=e.clientWidth,n.height=e.clientHeight,n.x=n.left,n.y=n.top,n}function Cf(e,t,n){return t===nm?cl(h_(e,n)):mr(t)?m_(t,n):cl(v_(Gn(e)))}function p_(e){var t=Ns(Va(e)),n=["absolute","fixed"].indexOf(yn(e).position)>=0,r=n&&Yt(e)?ho(e):e;return mr(r)?t.filter(function(s){return mr(s)&&om(s,r)&&an(s)!=="body"}):[]}function g_(e,t,n,r){var s=t==="clippingParents"?p_(e):[].concat(t),o=[].concat(s,[n]),a=o[0],i=o.reduce(function(l,u){var c=Cf(e,u,r);return l.top=fr(c.top,l.top),l.right=ua(c.right,l.right),l.bottom=ua(c.bottom,l.bottom),l.left=fr(c.left,l.left),l},Cf(e,a,r));return i.width=i.right-i.left,i.height=i.bottom-i.top,i.x=i.left,i.y=i.top,i}function cm(e){var t=e.reference,n=e.element,r=e.placement,s=r?on(r):null,o=r?Qr(r):null,a=t.x+t.width/2-n.width/2,i=t.y+t.height/2-n.height/2,l;switch(s){case wt:l={x:a,y:t.y-n.height};break;case Ht:l={x:a,y:t.y+t.height};break;case jt:l={x:t.x+t.width,y:i};break;case _t:l={x:t.x-n.width,y:i};break;default:l={x:t.x,y:t.y}}var u=s?fu(s):null;if(u!=null){var c=u==="y"?"height":"width";switch(o){case Zr:l[u]=l[u]-(t[c]/2-n[c]/2);break;case Gs:l[u]=l[u]+(t[c]/2-n[c]/2);break}}return l}function qs(e,t){t===void 0&&(t={});var n=t,r=n.placement,s=r===void 0?e.placement:r,o=n.strategy,a=o===void 0?e.strategy:o,i=n.boundary,l=i===void 0?Nw:i,u=n.rootBoundary,c=u===void 0?nm:u,f=n.elementContext,d=f===void 0?ws:f,h=n.altBoundary,v=h===void 0?!1:h,m=n.padding,p=m===void 0?0:m,b=im(typeof p!="number"?p:lm(p,fo)),S=d===ws?Fw:ws,T=e.rects.popper,M=e.elements[v?S:d],D=g_(mr(M)?M:M.contextElement||Gn(e.elements.popper),l,c,a),C=Xr(e.elements.reference),E=cm({reference:C,element:T,strategy:"absolute",placement:s}),P=cl(Object.assign({},T,E)),$=d===ws?P:C,I={top:D.top-$.top+b.top,bottom:$.bottom-D.bottom+b.bottom,left:D.left-$.left+b.left,right:$.right-D.right+b.right},j=e.modifiersData.offset;if(d===ws&&j){var O=j[s];Object.keys(I).forEach(function(W){var re=[jt,Ht].indexOf(W)>=0?1:-1,X=[wt,Ht].indexOf(W)>=0?"y":"x";I[W]+=O[X]*re})}return I}function y_(e,t){t===void 0&&(t={});var n=t,r=n.placement,s=n.boundary,o=n.rootBoundary,a=n.padding,i=n.flipVariations,l=n.allowedAutoPlacements,u=l===void 0?rm:l,c=Qr(r),f=c?i?bf:bf.filter(function(v){return Qr(v)===c}):fo,d=f.filter(function(v){return u.indexOf(v)>=0});d.length===0&&(d=f);var h=d.reduce(function(v,m){return v[m]=qs(e,{placement:m,boundary:s,rootBoundary:o,padding:a})[on(m)],v},{});return Object.keys(h).sort(function(v,m){return h[v]-h[m]})}function b_(e){if(on(e)===lu)return[];var t=Bo(e);return[Df(e),t,Df(t)]}function w_(e){var t=e.state,n=e.options,r=e.name;if(!t.modifiersData[r]._skip){for(var s=n.mainAxis,o=s===void 0?!0:s,a=n.altAxis,i=a===void 0?!0:a,l=n.fallbackPlacements,u=n.padding,c=n.boundary,f=n.rootBoundary,d=n.altBoundary,h=n.flipVariations,v=h===void 0?!0:h,m=n.allowedAutoPlacements,p=t.options.placement,b=on(p),S=b===p,T=l||(S||!v?[Bo(p)]:b_(p)),M=[p].concat(T).reduce(function(pe,Ye){return pe.concat(on(Ye)===lu?y_(t,{placement:Ye,boundary:c,rootBoundary:f,padding:u,flipVariations:v,allowedAutoPlacements:m}):Ye)},[]),D=t.rects.reference,C=t.rects.popper,E=new Map,P=!0,$=M[0],I=0;I=0,X=re?"width":"height",ee=qs(t,{placement:j,boundary:c,rootBoundary:f,altBoundary:d,padding:u}),J=re?W?jt:_t:W?Ht:wt;D[X]>C[X]&&(J=Bo(J));var ue=Bo(J),we=[];if(o&&we.push(ee[O]<=0),i&&we.push(ee[J]<=0,ee[ue]<=0),we.every(function(pe){return pe})){$=j,P=!1;break}E.set(j,we)}if(P)for(var V=v?3:1,fe=function(Ye){var Re=M.find(function(ye){var ze=E.get(ye);if(ze)return ze.slice(0,Ye).every(function(tt){return tt})});if(Re)return $=Re,"break"},Q=V;Q>0;Q--){var Le=fe(Q);if(Le==="break")break}t.placement!==$&&(t.modifiersData[r]._skip=!0,t.placement=$,t.reset=!0)}}const __={name:"flip",enabled:!0,phase:"main",fn:w_,requiresIfExists:["offset"],data:{_skip:!1}};function Sf(e,t,n){return n===void 0&&(n={x:0,y:0}),{top:e.top-t.height-n.y,right:e.right-t.width+n.x,bottom:e.bottom-t.height+n.y,left:e.left-t.width-n.x}}function $f(e){return[wt,jt,Ht,_t].some(function(t){return e[t]>=0})}function D_(e){var t=e.state,n=e.name,r=t.rects.reference,s=t.rects.popper,o=t.modifiersData.preventOverflow,a=qs(t,{elementContext:"reference"}),i=qs(t,{altBoundary:!0}),l=Sf(a,r),u=Sf(i,s,o),c=$f(l),f=$f(u);t.modifiersData[n]={referenceClippingOffsets:l,popperEscapeOffsets:u,isReferenceHidden:c,hasPopperEscaped:f},t.attributes.popper=Object.assign({},t.attributes.popper,{"data-popper-reference-hidden":c,"data-popper-escaped":f})}const C_={name:"hide",enabled:!0,phase:"main",requiresIfExists:["preventOverflow"],fn:D_};function S_(e,t,n){var r=on(e),s=[_t,wt].indexOf(r)>=0?-1:1,o=typeof n=="function"?n(Object.assign({},t,{placement:e})):n,a=o[0],i=o[1];return a=a||0,i=(i||0)*s,[_t,jt].indexOf(r)>=0?{x:i,y:a}:{x:a,y:i}}function $_(e){var t=e.state,n=e.options,r=e.name,s=n.offset,o=s===void 0?[0,0]:s,a=rm.reduce(function(c,f){return c[f]=S_(f,t.rects,o),c},{}),i=a[t.placement],l=i.x,u=i.y;t.modifiersData.popperOffsets!=null&&(t.modifiersData.popperOffsets.x+=l,t.modifiersData.popperOffsets.y+=u),t.modifiersData[r]=a}const T_={name:"offset",enabled:!0,phase:"main",requires:["popperOffsets"],fn:$_};function E_(e){var t=e.state,n=e.name;t.modifiersData[n]=cm({reference:t.rects.reference,element:t.rects.popper,strategy:"absolute",placement:t.placement})}const O_={name:"popperOffsets",enabled:!0,phase:"read",fn:E_,data:{}};function M_(e){return e==="x"?"y":"x"}function x_(e){var t=e.state,n=e.options,r=e.name,s=n.mainAxis,o=s===void 0?!0:s,a=n.altAxis,i=a===void 0?!1:a,l=n.boundary,u=n.rootBoundary,c=n.altBoundary,f=n.padding,d=n.tether,h=d===void 0?!0:d,v=n.tetherOffset,m=v===void 0?0:v,p=qs(t,{boundary:l,rootBoundary:u,padding:f,altBoundary:c}),b=on(t.placement),S=Qr(t.placement),T=!S,M=fu(b),D=M_(M),C=t.modifiersData.popperOffsets,E=t.rects.reference,P=t.rects.popper,$=typeof m=="function"?m(Object.assign({},t.rects,{placement:t.placement})):m,I=typeof $=="number"?{mainAxis:$,altAxis:$}:Object.assign({mainAxis:0,altAxis:0},$),j=t.modifiersData.offset?t.modifiersData.offset[t.placement]:null,O={x:0,y:0};if(C){if(o){var W,re=M==="y"?wt:_t,X=M==="y"?Ht:jt,ee=M==="y"?"height":"width",J=C[M],ue=J+p[re],we=J-p[X],V=h?-P[ee]/2:0,fe=S===Zr?E[ee]:P[ee],Q=S===Zr?-P[ee]:-E[ee],Le=t.elements.arrow,pe=h&&Le?cu(Le):{width:0,height:0},Ye=t.modifiersData["arrow#persistent"]?t.modifiersData["arrow#persistent"].padding:am(),Re=Ye[re],ye=Ye[X],ze=Rs(0,E[ee],pe[ee]),tt=T?E[ee]/2-V-ze-Re-I.mainAxis:fe-ze-Re-I.mainAxis,lt=T?-E[ee]/2+V+ze+ye+I.mainAxis:Q+ze+ye+I.mainAxis,mt=t.elements.arrow&&ho(t.elements.arrow),ut=mt?M==="y"?mt.clientTop||0:mt.clientLeft||0:0,g=(W=j?.[M])!=null?W:0,_=J+tt-g-ut,x=J+lt-g,Y=Rs(h?ua(ue,_):ue,J,h?fr(we,x):we);C[M]=Y,O[M]=Y-J}if(i){var R,H=M==="x"?wt:_t,K=M==="x"?Ht:jt,U=C[D],z=D==="y"?"height":"width",B=U+p[H],q=U-p[K],ne=[wt,_t].indexOf(b)!==-1,te=(R=j?.[D])!=null?R:0,ie=ne?B:U-E[z]-P[z]-te+I.altAxis,de=ne?U+E[z]+P[z]-te-I.altAxis:q,Ce=h&&ne?e_(ie,U,de):Rs(h?ie:B,U,h?de:q);C[D]=Ce,O[D]=Ce-U}t.modifiersData[r]=O}}const k_={name:"preventOverflow",enabled:!0,phase:"main",fn:x_,requiresIfExists:["offset"]};function P_(e){return{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}}function A_(e){return e===kt(e)||!Yt(e)?du(e):P_(e)}function I_(e){var t=e.getBoundingClientRect(),n=Jr(t.width)/e.offsetWidth||1,r=Jr(t.height)/e.offsetHeight||1;return n!==1||r!==1}function L_(e,t,n){n===void 0&&(n=!1);var r=Yt(t),s=Yt(t)&&I_(t),o=Gn(t),a=Xr(e,s,n),i={scrollLeft:0,scrollTop:0},l={x:0,y:0};return(r||!r&&!n)&&((an(t)!=="body"||vu(o))&&(i=A_(t)),Yt(t)?(l=Xr(t,!0),l.x+=t.clientLeft,l.y+=t.clientTop):o&&(l.x=hu(o))),{x:a.left+i.scrollLeft-l.x,y:a.top+i.scrollTop-l.y,width:a.width,height:a.height}}function R_(e){var t=new Map,n=new Set,r=[];e.forEach(function(o){t.set(o.name,o)});function s(o){n.add(o.name);var a=[].concat(o.requires||[],o.requiresIfExists||[]);a.forEach(function(i){if(!n.has(i)){var l=t.get(i);l&&s(l)}}),r.push(o)}return e.forEach(function(o){n.has(o.name)||s(o)}),r}function N_(e){var t=R_(e);return Gw.reduce(function(n,r){return n.concat(t.filter(function(s){return s.phase===r}))},[])}function F_(e){var t;return function(){return t||(t=new Promise(function(n){Promise.resolve().then(function(){t=void 0,n(e())})})),t}}function Y_(e){var t=e.reduce(function(n,r){var s=n[r.name];return n[r.name]=s?Object.assign({},s,r,{options:Object.assign({},s.options,r.options),data:Object.assign({},s.data,r.data)}):r,n},{});return Object.keys(t).map(function(n){return t[n]})}var Tf={placement:"bottom",modifiers:[],strategy:"absolute"};function Ef(){for(var e=arguments.length,t=new Array(e),n=0;nt in e?V_(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,se=(e,t,n)=>(W_(e,typeof t!="symbol"?t+"":t,n),n),ko=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function fm(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var U_=Object.prototype,z_=U_.hasOwnProperty;function K_(e,t){return e!=null&&z_.call(e,t)}var G_=K_,q_=Array.isArray,Zt=q_,Z_=typeof ko=="object"&&ko&&ko.Object===Object&&ko,dm=Z_,J_=dm,X_=typeof self=="object"&&self&&self.Object===Object&&self,Q_=J_||X_||Function("return this")(),un=Q_,eD=un,tD=eD.Symbol,Wa=tD,Of=Wa,hm=Object.prototype,nD=hm.hasOwnProperty,rD=hm.toString,_s=Of?Of.toStringTag:void 0;function sD(e){var t=nD.call(e,_s),n=e[_s];try{e[_s]=void 0;var r=!0}catch{}var s=rD.call(e);return r&&(t?e[_s]=n:delete e[_s]),s}var oD=sD,aD=Object.prototype,iD=aD.toString;function lD(e){return iD.call(e)}var uD=lD,Mf=Wa,cD=oD,fD=uD,dD="[object Null]",hD="[object Undefined]",xf=Mf?Mf.toStringTag:void 0;function vD(e){return e==null?e===void 0?hD:dD:xf&&xf in Object(e)?cD(e):fD(e)}var cn=vD;function mD(e){return e!=null&&typeof e=="object"}var Jt=mD,pD=cn,gD=Jt,yD="[object Symbol]";function bD(e){return typeof e=="symbol"||gD(e)&&pD(e)==yD}var mu=bD,wD=Zt,_D=mu,DD=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,CD=/^\w*$/;function SD(e,t){if(wD(e))return!1;var n=typeof e;return n=="number"||n=="symbol"||n=="boolean"||e==null||_D(e)?!0:CD.test(e)||!DD.test(e)||t!=null&&e in Object(t)}var pu=SD;function $D(e){var t=typeof e;return e!=null&&(t=="object"||t=="function")}var Sn=$D,TD=cn,ED=Sn,OD="[object AsyncFunction]",MD="[object Function]",xD="[object GeneratorFunction]",kD="[object Proxy]";function PD(e){if(!ED(e))return!1;var t=TD(e);return t==MD||t==xD||t==OD||t==kD}var Dr=PD,AD=un,ID=AD["__core-js_shared__"],LD=ID,Ci=LD,kf=function(){var e=/[^.]+$/.exec(Ci&&Ci.keys&&Ci.keys.IE_PROTO||"");return e?"Symbol(src)_1."+e:""}();function RD(e){return!!kf&&kf in e}var ND=RD,FD=Function.prototype,YD=FD.toString;function BD(e){if(e!=null){try{return YD.call(e)}catch{}try{return e+""}catch{}}return""}var vm=BD,HD=Dr,jD=ND,VD=Sn,WD=vm,UD=/[\\^$.*+?()[\]{}|]/g,zD=/^\[object .+?Constructor\]$/,KD=Function.prototype,GD=Object.prototype,qD=KD.toString,ZD=GD.hasOwnProperty,JD=RegExp("^"+qD.call(ZD).replace(UD,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function XD(e){if(!VD(e)||jD(e))return!1;var t=HD(e)?JD:zD;return t.test(WD(e))}var QD=XD;function eC(e,t){return e?.[t]}var tC=eC,nC=QD,rC=tC;function sC(e,t){var n=rC(e,t);return nC(n)?n:void 0}var Cr=sC,oC=Cr,aC=oC(Object,"create"),Ua=aC,Pf=Ua;function iC(){this.__data__=Pf?Pf(null):{},this.size=0}var lC=iC;function uC(e){var t=this.has(e)&&delete this.__data__[e];return this.size-=t?1:0,t}var cC=uC,fC=Ua,dC="__lodash_hash_undefined__",hC=Object.prototype,vC=hC.hasOwnProperty;function mC(e){var t=this.__data__;if(fC){var n=t[e];return n===dC?void 0:n}return vC.call(t,e)?t[e]:void 0}var pC=mC,gC=Ua,yC=Object.prototype,bC=yC.hasOwnProperty;function wC(e){var t=this.__data__;return gC?t[e]!==void 0:bC.call(t,e)}var _C=wC,DC=Ua,CC="__lodash_hash_undefined__";function SC(e,t){var n=this.__data__;return this.size+=this.has(e)?0:1,n[e]=DC&&t===void 0?CC:t,this}var $C=SC,TC=lC,EC=cC,OC=pC,MC=_C,xC=$C;function as(e){var t=-1,n=e==null?0:e.length;for(this.clear();++t-1}var KC=zC,GC=za;function qC(e,t){var n=this.__data__,r=GC(n,e);return r<0?(++this.size,n.push([e,t])):n[r][1]=t,this}var ZC=qC,JC=AC,XC=HC,QC=WC,eS=KC,tS=ZC;function ls(e){var t=-1,n=e==null?0:e.length;for(this.clear();++t-1&&e%1==0&&e-1&&e%1==0&&e<=v$}var Du=m$,p$=mu,g$=1/0;function y$(e){if(typeof e=="string"||p$(e))return e;var t=e+"";return t=="0"&&1/e==-g$?"-0":t}var qa=y$,b$=gm,w$=wu,_$=Zt,D$=_u,C$=Du,S$=qa;function $$(e,t,n){t=b$(t,e);for(var r=-1,s=t.length,o=!1;++ri))return!1;var u=o.get(e),c=o.get(t);if(u&&c)return u==t&&c==e;var f=-1,d=!0,h=n&OT?new ST:void 0;for(o.set(e,t),o.set(t,e);++f0){if(++t>=Ok)return arguments[0]}else t=0;return e.apply(void 0,arguments)}}var Pk=kk,Ak=Ek,Ik=Pk,Lk=Ik(Ak),Rk=Lk,Nk=Eu,Fk=_k,Yk=Rk;function Bk(e,t){return Yk(Fk(e,t,Nk),e+"")}var Mu=Bk;function Hk(e){var t=[];if(e!=null)for(var n in Object(e))t.push(n);return t}var jk=Hk,Vk=Sn,Wk=$u,Uk=jk,zk=Object.prototype,Kk=zk.hasOwnProperty;function Gk(e){if(!Vk(e))return Uk(e);var t=Wk(e),n=[];for(var r in e)r=="constructor"&&(t||!Kk.call(e,r))||n.push(r);return n}var qk=Gk,Zk=$m,Jk=qk,Xk=vo;function Qk(e){return Xk(e)?Zk(e,!0):Jk(e)}var xu=Qk,eP=Mu,tP=is,nP=Ou,rP=xu,Fm=Object.prototype,sP=Fm.hasOwnProperty,oP=eP(function(e,t){e=Object(e);var n=-1,r=t.length,s=r>2?t[2]:void 0;for(s&&nP(t[0],t[1],s)&&(r=1);++n1?n[s-1]:void 0,a=s>2?n[2]:void 0;for(o=e.length>3&&typeof o=="function"?(s--,o):void 0,a&&b2(n[0],n[1],a)&&(o=s<3?void 0:o,s=1),t=Object(t);++rObject.prototype.toString.call(e).slice(8,-1),Hr=e=>Y$(e)&&!isNaN(e.getTime()),bn=e=>A2(e)==="Object",Km=wm,pd=(e,t)=>Gx(t,n=>wm(e,n)),Oe=(e,t,n="0")=>{for(e=e!=null?String(e):"",t=t||2;e.lengthArray.isArray(e),mn=e=>Bt(e)&&e.length>0,da=e=>e==null?null:document&&rn(e)?document.querySelector(e):e.$el??e,Rn=(e,t,n,r=void 0)=>{e.removeEventListener(t,n,r)},Nn=(e,t,n,r=void 0)=>(e.addEventListener(t,n,r),()=>Rn(e,t,n,r)),Ho=(e,t)=>!!e&&!!t&&(e===t||e.contains(t)),Ao=(e,t)=>{(e.key===" "||e.key==="Enter")&&(t(e),e.preventDefault())},Gm=(e,...t)=>{const n={};let r;for(r in e)t.includes(r)||(n[r]=e[r]);return n},qm=(e,t)=>{const n={};return t.forEach(r=>{r in e&&(n[r]=e[r])}),n};function I2(e,t,n){return Math.min(Math.max(e,t),n)}var ha={},L2={get exports(){return ha},set exports(e){ha=e}};(function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.default=n;function n(r){if(r===null||r===!0||r===!1)return NaN;var s=Number(r);return isNaN(s)?s:s<0?Math.ceil(s):Math.floor(s)}e.exports=t.default})(L2,ha);const R2=fm(ha);var va={},N2={get exports(){return va},set exports(e){va=e}};(function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.default=n;function n(r){var s=new Date(Date.UTC(r.getFullYear(),r.getMonth(),r.getDate(),r.getHours(),r.getMinutes(),r.getSeconds(),r.getMilliseconds()));return s.setUTCFullYear(r.getFullYear()),r.getTime()-s.getTime()}e.exports=t.default})(N2,va);const gd=fm(va);function F2(e,t){var n=j2(t);return n.formatToParts?B2(n,e):H2(n,e)}var Y2={year:0,month:1,day:2,hour:3,minute:4,second:5};function B2(e,t){try{for(var n=e.formatToParts(t),r=[],s=0;s=0&&(r[o]=parseInt(n[s].value,10))}return r}catch(a){if(a instanceof RangeError)return[NaN];throw a}}function H2(e,t){var n=e.format(t).replace(/\u200E/g,""),r=/(\d+)\/(\d+)\/(\d+),? (\d+):(\d+):(\d+)/.exec(n);return[r[3],r[1],r[2],r[4],r[5],r[6]]}var Ti={};function j2(e){if(!Ti[e]){var t=new Intl.DateTimeFormat("en-US",{hour12:!1,timeZone:"America/New_York",year:"numeric",month:"numeric",day:"2-digit",hour:"2-digit",minute:"2-digit",second:"2-digit"}).format(new Date("2014-06-25T04:00:00.123Z")),n=t==="06/25/2014, 00:00:00"||t==="‎06‎/‎25‎/‎2014‎ ‎00‎:‎00‎:‎00";Ti[e]=n?new Intl.DateTimeFormat("en-US",{hour12:!1,timeZone:e,year:"numeric",month:"numeric",day:"2-digit",hour:"2-digit",minute:"2-digit",second:"2-digit"}):new Intl.DateTimeFormat("en-US",{hourCycle:"h23",timeZone:e,year:"numeric",month:"numeric",day:"2-digit",hour:"2-digit",minute:"2-digit",second:"2-digit"})}return Ti[e]}function Zm(e,t,n,r,s,o,a){var i=new Date(0);return i.setUTCFullYear(e,t,n),i.setUTCHours(r,s,o,a),i}var yd=36e5,V2=6e4,Ei={timezone:/([Z+-].*)$/,timezoneZ:/^(Z)$/,timezoneHH:/^([+-]\d{2})$/,timezoneHHMM:/^([+-]\d{2}):?(\d{2})$/};function W2(e,t,n){var r,s;if(!e||(r=Ei.timezoneZ.exec(e),r))return 0;var o;if(r=Ei.timezoneHH.exec(e),r)return o=parseInt(r[1],10),bd(o)?-(o*yd):NaN;if(r=Ei.timezoneHHMM.exec(e),r){o=parseInt(r[1],10);var a=parseInt(r[2],10);return bd(o,a)?(s=Math.abs(o)*yd+a*V2,o>0?-s:s):NaN}if(K2(e)){t=new Date(t||Date.now());var i=U2(t),l=pl(i,e),u=z2(t,l,e);return-u}return NaN}function U2(e){return Zm(e.getFullYear(),e.getMonth(),e.getDate(),e.getHours(),e.getMinutes(),e.getSeconds(),e.getMilliseconds())}function pl(e,t){var n=F2(e,t),r=Zm(n[0],n[1]-1,n[2],n[3]%24,n[4],n[5],0).getTime(),s=e.getTime(),o=s%1e3;return s-=o>=0?o:1e3+o,r-s}function z2(e,t,n){var r=e.getTime(),s=r-t,o=pl(new Date(s),n);if(t===o)return t;s-=o-t;var a=pl(new Date(s),n);return o===a?o:Math.max(o,a)}function bd(e,t){return-23<=e&&e<=23&&(t==null||0<=t&&t<=59)}var wd={};function K2(e){if(wd[e])return!0;try{return new Intl.DateTimeFormat(void 0,{timeZone:e}),wd[e]=!0,!0}catch{return!1}}var G2=/(Z|[+-]\d{2}(?::?\d{2})?| UTC| [a-zA-Z]+\/[a-zA-Z_]+(?:\/[a-zA-Z_]+)?)$/;const q2=G2;var Oi=36e5,_d=6e4,Z2=2,vt={dateTimePattern:/^([0-9W+-]+)(T| )(.*)/,datePattern:/^([0-9W+-]+)(.*)/,plainTime:/:/,YY:/^(\d{2})$/,YYY:[/^([+-]\d{2})$/,/^([+-]\d{3})$/,/^([+-]\d{4})$/],YYYY:/^(\d{4})/,YYYYY:[/^([+-]\d{4})/,/^([+-]\d{5})/,/^([+-]\d{6})/],MM:/^-(\d{2})$/,DDD:/^-?(\d{3})$/,MMDD:/^-?(\d{2})-?(\d{2})$/,Www:/^-?W(\d{2})$/,WwwD:/^-?W(\d{2})-?(\d{1})$/,HH:/^(\d{2}([.,]\d*)?)$/,HHMM:/^(\d{2}):?(\d{2}([.,]\d*)?)$/,HHMMSS:/^(\d{2}):?(\d{2}):?(\d{2}([.,]\d*)?)$/,timeZone:q2};function J2(e,t){if(arguments.length<1)throw new TypeError("1 argument required, but only "+arguments.length+" present");if(e===null)return new Date(NaN);var n=t||{},r=n.additionalDigits==null?Z2:R2(n.additionalDigits);if(r!==2&&r!==1&&r!==0)throw new RangeError("additionalDigits must be 0, 1 or 2");if(e instanceof Date||typeof e=="object"&&Object.prototype.toString.call(e)==="[object Date]")return new Date(e.getTime());if(typeof e=="number"||Object.prototype.toString.call(e)==="[object Number]")return new Date(e);if(!(typeof e=="string"||Object.prototype.toString.call(e)==="[object String]"))return new Date(NaN);var s=X2(e),o=Q2(s.date,r),a=o.year,i=o.restDateString,l=eA(i,a);if(isNaN(l))return new Date(NaN);if(l){var u=l.getTime(),c=0,f;if(s.time&&(c=tA(s.time),isNaN(c)))return new Date(NaN);if(s.timeZone||n.timeZone){if(f=W2(s.timeZone||n.timeZone,new Date(u+c)),isNaN(f))return new Date(NaN)}else f=gd(new Date(u+c)),f=gd(new Date(u+c+f));return new Date(u+c+f)}else return new Date(NaN)}function X2(e){var t={},n=vt.dateTimePattern.exec(e),r;if(n?(t.date=n[1],r=n[3]):(n=vt.datePattern.exec(e),n?(t.date=n[1],r=n[2]):(t.date=null,r=e)),r){var s=vt.timeZone.exec(r);s?(t.time=r.replace(s[1],""),t.timeZone=s[1].trim()):t.time=r}return t}function Q2(e,t){var n=vt.YYY[t],r=vt.YYYYY[t],s;if(s=vt.YYYY.exec(e)||r.exec(e),s){var o=s[1];return{year:parseInt(o,10),restDateString:e.slice(o.length)}}if(s=vt.YY.exec(e)||n.exec(e),s){var a=s[1];return{year:parseInt(a,10)*100,restDateString:e.slice(a.length)}}return{year:null}}function eA(e,t){if(t===null)return null;var n,r,s,o;if(e.length===0)return r=new Date(0),r.setUTCFullYear(t),r;if(n=vt.MM.exec(e),n)return r=new Date(0),s=parseInt(n[1],10)-1,Cd(t,s)?(r.setUTCFullYear(t,s),r):new Date(NaN);if(n=vt.DDD.exec(e),n){r=new Date(0);var a=parseInt(n[1],10);return sA(t,a)?(r.setUTCFullYear(t,0,a),r):new Date(NaN)}if(n=vt.MMDD.exec(e),n){r=new Date(0),s=parseInt(n[1],10)-1;var i=parseInt(n[2],10);return Cd(t,s,i)?(r.setUTCFullYear(t,s,i),r):new Date(NaN)}if(n=vt.Www.exec(e),n)return o=parseInt(n[1],10)-1,Sd(t,o)?Dd(t,o):new Date(NaN);if(n=vt.WwwD.exec(e),n){o=parseInt(n[1],10)-1;var l=parseInt(n[2],10)-1;return Sd(t,o,l)?Dd(t,o,l):new Date(NaN)}return null}function tA(e){var t,n,r;if(t=vt.HH.exec(e),t)return n=parseFloat(t[1].replace(",",".")),Mi(n)?n%24*Oi:NaN;if(t=vt.HHMM.exec(e),t)return n=parseInt(t[1],10),r=parseFloat(t[2].replace(",",".")),Mi(n,r)?n%24*Oi+r*_d:NaN;if(t=vt.HHMMSS.exec(e),t){n=parseInt(t[1],10),r=parseInt(t[2],10);var s=parseFloat(t[3].replace(",","."));return Mi(n,r,s)?n%24*Oi+r*_d+s*1e3:NaN}return null}function Dd(e,t,n){t=t||0,n=n||0;var r=new Date(0);r.setUTCFullYear(e,0,4);var s=r.getUTCDay()||7,o=t*7+n+1-s;return r.setUTCDate(r.getUTCDate()+o),r}var nA=[31,28,31,30,31,30,31,31,30,31,30,31],rA=[31,29,31,30,31,30,31,31,30,31,30,31];function Jm(e){return e%400===0||e%4===0&&e%100!==0}function Cd(e,t,n){if(t<0||t>11)return!1;if(n!=null){if(n<1)return!1;var r=Jm(e);if(r&&n>rA[t]||!r&&n>nA[t])return!1}return!0}function sA(e,t){if(t<1)return!1;var n=Jm(e);return!(n&&t>366||!n&&t>365)}function Sd(e,t,n){return!(t<0||t>52||n!=null&&(n<0||n>6))}function Mi(e,t,n){return!(e!=null&&(e<0||e>=25)||t!=null&&(t<0||t>=60)||n!=null&&(n<0||n>=60))}function it(e,t){if(t.length1?"s":"")+" required, but only "+t.length+" present")}function jo(e){"@babel/helpers - typeof";return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?jo=function(n){return typeof n}:jo=function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},jo(e)}function $n(e){it(1,arguments);var t=Object.prototype.toString.call(e);return e instanceof Date||jo(e)==="object"&&t==="[object Date]"?new Date(e.getTime()):typeof e=="number"||t==="[object Number]"?new Date(e):((typeof e=="string"||t==="[object String]")&&typeof console<"u"&&(console.warn("Starting with v2.0.0-beta.1 date-fns doesn't accept strings as date arguments. Please use `parseISO` to parse strings. See: https://github.com/date-fns/date-fns/blob/master/docs/upgradeGuide.md#string-arguments"),console.warn(new Error().stack)),new Date(NaN))}function ds(e){if(e===null||e===!0||e===!1)return NaN;var t=Number(e);return isNaN(t)?t:t<0?Math.ceil(t):Math.floor(t)}var oA={};function ku(){return oA}function pr(e,t){var n,r,s,o,a,i,l,u;it(1,arguments);var c=ku(),f=ds((n=(r=(s=(o=t?.weekStartsOn)!==null&&o!==void 0?o:t==null||(a=t.locale)===null||a===void 0||(i=a.options)===null||i===void 0?void 0:i.weekStartsOn)!==null&&s!==void 0?s:c.weekStartsOn)!==null&&r!==void 0?r:(l=c.locale)===null||l===void 0||(u=l.options)===null||u===void 0?void 0:u.weekStartsOn)!==null&&n!==void 0?n:0);if(!(f>=0&&f<=6))throw new RangeError("weekStartsOn must be between 0 and 6 inclusively");var d=$n(e),h=d.getDay(),v=(h=1&&h<=7))throw new RangeError("firstWeekContainsDate must be between 1 and 7 inclusively");var v=new Date(0);v.setFullYear(f+1,0,h),v.setHours(0,0,0,0);var m=pr(v,t),p=new Date(0);p.setFullYear(f,0,h),p.setHours(0,0,0,0);var b=pr(p,t);return c.getTime()>=m.getTime()?f+1:c.getTime()>=b.getTime()?f:f-1}function dA(e,t){var n,r,s,o,a,i,l,u;it(1,arguments);var c=ku(),f=ds((n=(r=(s=(o=t?.firstWeekContainsDate)!==null&&o!==void 0?o:t==null||(a=t.locale)===null||a===void 0||(i=a.options)===null||i===void 0?void 0:i.firstWeekContainsDate)!==null&&s!==void 0?s:c.firstWeekContainsDate)!==null&&r!==void 0?r:(l=c.locale)===null||l===void 0||(u=l.options)===null||u===void 0?void 0:u.firstWeekContainsDate)!==null&&n!==void 0?n:1),d=fA(e,t),h=new Date(0);h.setFullYear(d,0,f),h.setHours(0,0,0,0);var v=pr(h,t);return v}var hA=6048e5;function vA(e,t){it(1,arguments);var n=$n(e),r=pr(n,t).getTime()-dA(n,t).getTime();return Math.round(r/hA)+1}function ma(e){return it(1,arguments),pr(e,{weekStartsOn:1})}function mA(e){it(1,arguments);var t=$n(e),n=t.getFullYear(),r=new Date(0);r.setFullYear(n+1,0,4),r.setHours(0,0,0,0);var s=ma(r),o=new Date(0);o.setFullYear(n,0,4),o.setHours(0,0,0,0);var a=ma(o);return t.getTime()>=s.getTime()?n+1:t.getTime()>=a.getTime()?n:n-1}function pA(e){it(1,arguments);var t=mA(e),n=new Date(0);n.setFullYear(t,0,4),n.setHours(0,0,0,0);var r=ma(n);return r}var gA=6048e5;function yA(e){it(1,arguments);var t=$n(e),n=ma(t).getTime()-pA(t).getTime();return Math.round(n/gA)+1}function ht(e,t){it(2,arguments);var n=$n(e),r=ds(t);return isNaN(r)?new Date(NaN):(r&&n.setDate(n.getDate()+r),n)}function pa(e,t){it(2,arguments);var n=$n(e),r=ds(t);if(isNaN(r))return new Date(NaN);if(!r)return n;var s=n.getDate(),o=new Date(n.getTime());o.setMonth(n.getMonth()+r+1,0);var a=o.getDate();return s>=a?o:(n.setFullYear(o.getFullYear(),o.getMonth(),s),n)}function Td(e,t){it(2,arguments);var n=ds(t);return pa(e,n*12)}const bA={daily:["year","month","day"],weekly:["year","month","week"],monthly:["year","month"]};function wA({monthComps:e,prevMonthComps:t,nextMonthComps:n},r){const s=[],{firstDayOfWeek:o,firstWeekday:a,isoWeeknumbers:i,weeknumbers:l,numDays:u,numWeeks:c}=e,f=a+(a{const l=Math.floor(i/7);let u=o[l];return u||(u={id:`week-${l+1}`,title:"",week:a.week,weekPosition:a.weekPosition,weeknumber:a.weeknumber,isoWeeknumber:a.isoWeeknumber,weeknumberDisplay:t?a.weeknumber:n?a.isoWeeknumber:void 0,days:[]},o[l]=u),u.days.push(a),o},Array(e.length/nt));return s.forEach(o=>{const a=o.days[0],i=o.days[o.days.length-1];a.month===i.month?o.title=`${r.formatDate(a.date,"MMMM YYYY")}`:a.year===i.year?o.title=`${r.formatDate(a.date,"MMM")} - ${r.formatDate(i.date,"MMM YYYY")}`:o.title=`${r.formatDate(a.date,"MMM YYYY")} - ${r.formatDate(i.date,"MMM YYYY")}`}),s}function DA(e,t){return e.days.map(n=>({label:t.formatDate(n.date,t.masks.weekdays),weekday:n.weekday}))}function CA(e,t){return`${t}.${Oe(e,2)}`}function Xm(e,t,n){return qm(n.getDateParts(n.toDate(e)),bA[t])}function Qm({day:e,week:t,month:n,year:r},s,o,a){if(o==="daily"&&e){const i=new Date(r,n-1,e),l=ht(i,s);return{day:l.getDate(),month:l.getMonth()+1,year:l.getFullYear()}}else if(o==="weekly"&&t){const l=a.getMonthParts(n,r).firstDayOfMonth,u=ht(l,(t-1+s)*7),c=a.getDateParts(u);return{week:c.week,month:c.month,year:c.year}}else{const i=new Date(r,n-1,1),l=pa(i,s);return{month:l.getMonth()+1,year:l.getFullYear()}}}function sn(e){return e!=null&&e.month!=null&&e.year!=null}function gl(e,t){return!sn(e)||!sn(t)?!1:(e=e,t=t,e.year!==t.year?e.yeart.year:e.month&&t.month&&e.month!==t.month?e.month>t.month:e.week&&t.week&&e.week!==t.week?e.week>t.week:e.day&&t.day&&e.day!==t.day?e.day>t.day:!1)}function SA(e,t,n){return(e||!1)&&!gl(e,t)&&!ga(e,n)}function $A(e,t){return!e&&t||e&&!t?!1:!e&&!t?!0:(e=e,t=t,e.year===t.year&&e.month===t.month&&e.week===t.week&&e.day===t.day)}function TA(e,t,n,r){if(!sn(e)||!sn(t))return[];const s=[];for(;!ga(e,t);)s.push(e),e=Qm(e,1,n,r);return s}function ep(e){const{day:t,week:n,month:r,year:s}=e;let o=`${s}-${Oe(r,2)}`;return n&&(o=`${o}-w${n}`),t&&(o=`${o}-${Oe(t,2)}`),o}function EA(e,t){const{month:n,year:r,showWeeknumbers:s,showIsoWeeknumbers:o}=e,a=new Date(r,n-1,15),i=t.getMonthParts(n,r),l=t.getPrevMonthParts(n,r),u=t.getNextMonthParts(n,r),c=wA({monthComps:i,prevMonthComps:l,nextMonthComps:u},t),f=_A(c,s,o,t),d=DA(f[0],t);return{id:ep(e),month:n,year:r,monthTitle:t.formatDate(a,t.masks.title),shortMonthLabel:t.formatDate(a,"MMM"),monthLabel:t.formatDate(a,"MMMM"),shortYearLabel:r.toString().substring(2),yearLabel:r.toString(),monthComps:i,prevMonthComps:l,nextMonthComps:u,days:c,weeks:f,weekdays:d}}function OA(e,t){const{day:n,week:r,view:s,trimWeeks:o}=e,a={...t,...e,title:"",viewDays:[],viewWeeks:[]};switch(s){case"daily":{let i=a.days.find(u=>u.inMonth);n?i=a.days.find(u=>u.day===n&&u.inMonth)||i:r&&(i=a.days.find(u=>u.week===r&&u.inMonth));const l=a.weeks[i.week-1];a.viewWeeks=[l],a.viewDays=[i],a.week=i.week,a.weekTitle=l.title,a.day=i.day,a.dayTitle=i.ariaLabel,a.title=a.dayTitle;break}case"weekly":{a.week=r||1;const i=a.weeks[a.week-1];a.viewWeeks=[i],a.viewDays=i.days,a.weekTitle=i.title,a.title=a.weekTitle;break}default:{a.title=a.monthTitle,a.viewWeeks=a.weeks.slice(0,o?a.monthComps.numWeeks:void 0),a.viewDays=a.days;break}}return a}class Ed{constructor(t,n,r){se(this,"keys",[]),se(this,"store",{}),this.size=t,this.createKey=n,this.createItem=r}get(...t){const n=this.createKey(...t);return this.store[n]}getOrSet(...t){const n=this.createKey(...t);if(this.store[n])return this.store[n];const r=this.createItem(...t);if(this.keys.length>=this.size){const s=this.keys.shift();s!=null&&delete this.store[s]}return this.keys.push(n),this.store[n]=r,r}}class jr{constructor(t,n=new ya){se(this,"order"),se(this,"locale"),se(this,"start",null),se(this,"end",null),se(this,"repeat",null);var r;this.locale=n;const{start:s,end:o,span:a,order:i,repeat:l}=t;Hr(s)&&(this.start=n.getDateParts(s)),Hr(o)?this.end=n.getDateParts(o):this.start!=null&&a&&(this.end=n.getDateParts(ht(this.start.date,a-1))),this.order=i??0,l&&(this.repeat=new ba({from:(r=this.start)==null?void 0:r.date,...l},{locale:this.locale}))}static fromMany(t,n){return(Bt(t)?t:[t]).filter(r=>r).map(r=>jr.from(r,n))}static from(t,n){if(t instanceof jr)return t;const r={start:null,end:null};return t!=null&&(Bt(t)?(r.start=t[0]??null,r.end=t[1]??null):bn(t)?Object.assign(r,t):(r.start=t,r.end=t)),r.start!=null&&(r.start=new Date(r.start)),r.end!=null&&(r.end=new Date(r.end)),new jr(r,n)}get opts(){const{order:t,locale:n}=this;return{order:t,locale:n}}get hasRepeat(){return!!this.repeat}get isSingleDay(){const{start:t,end:n}=this;return t&&n&&t.year===n.year&&t.month===n.month&&t.day===n.day}get isMultiDay(){return!this.isSingleDay}get daySpan(){return this.start==null||this.end==null?this.hasRepeat?1:1/0:this.end.dayIndex-this.start.dayIndex}startsOnDay(t){var n,r;return((n=this.start)==null?void 0:n.dayIndex)===t.dayIndex||!!((r=this.repeat)!=null&&r.passes(t))}intersectsDay(t){return this.intersectsDayRange(t,t)}intersectsRange(t){var n,r;return this.intersectsDayRange(((n=t.start)==null?void 0:n.dayIndex)??-1/0,((r=t.end)==null?void 0:r.dayIndex)??1/0)}intersectsDayRange(t,n){return!(this.start&&this.start.dayIndex>n||this.end&&this.end.dayIndex{var d,h;if(n.startsOnDay(f)){const v=n.daySpan<1/0?n.daySpan:1;l={startDay:f.dayIndex,startTime:((d=n.start)==null?void 0:d.time)??0,endDay:f.dayIndex+v-1,endTime:((h=n.end)==null?void 0:h.time)??Vo},this.getRangeRecords(t).push(l)}}):n.intersectsDayRange(u,c)&&(l={startDay:((s=n.start)==null?void 0:s.dayIndex)??-1/0,startTime:((o=n.start)==null?void 0:o.time)??-1/0,endDay:((a=n.end)==null?void 0:a.dayIndex)??1/0,endTime:((i=n.end)==null?void 0:i.time)??1/0},this.getRangeRecords(t).push(l)),l}getRangeRecords(t){let n=this.records[t.key];return n||(n={ranges:[],data:t},this.records[t.key]=n),n.ranges}getCell(t,n){return this.getCells(n).find(o=>o.data.key===t)}cellExists(t,n){const r=this.records[t];return r==null?!1:r.ranges.some(s=>s.startDay<=n&&s.endDay>=n)}getCells(t){const n=Object.values(this.records),r=[],{dayIndex:s}=t;return n.forEach(({data:o,ranges:a})=>{a.filter(i=>i.startDay<=s&&i.endDay>=s).forEach(i=>{const l=s===i.startDay,u=s===i.endDay,c=l?i.startTime:0,f=new Date(t.startDate.getTime()+c),d=u?i.endTime:Vo,h=new Date(t.endDate.getTime()+d),v=c===0&&d===Vo,m=o.order||0;r.push({...i,data:o,onStart:l,onEnd:u,startTime:c,startDate:f,endTime:d,endDate:h,allDay:v,order:m})})}),r.sort((o,a)=>o.order-a.order),r}}const wn={ar:{dow:7,L:"D/‏M/‏YYYY"},bg:{dow:2,L:"D.MM.YYYY"},ca:{dow:2,L:"DD/MM/YYYY"},"zh-CN":{dow:2,L:"YYYY/MM/DD"},"zh-TW":{dow:1,L:"YYYY/MM/DD"},hr:{dow:2,L:"DD.MM.YYYY"},cs:{dow:2,L:"DD.MM.YYYY"},da:{dow:2,L:"DD.MM.YYYY"},nl:{dow:2,L:"DD-MM-YYYY"},"en-US":{dow:1,L:"MM/DD/YYYY"},"en-AU":{dow:2,L:"DD/MM/YYYY"},"en-CA":{dow:1,L:"YYYY-MM-DD"},"en-GB":{dow:2,L:"DD/MM/YYYY"},"en-IE":{dow:2,L:"DD-MM-YYYY"},"en-NZ":{dow:2,L:"DD/MM/YYYY"},"en-ZA":{dow:1,L:"YYYY/MM/DD"},eo:{dow:2,L:"YYYY-MM-DD"},et:{dow:2,L:"DD.MM.YYYY"},fi:{dow:2,L:"DD.MM.YYYY"},fr:{dow:2,L:"DD/MM/YYYY"},"fr-CA":{dow:1,L:"YYYY-MM-DD"},"fr-CH":{dow:2,L:"DD.MM.YYYY"},de:{dow:2,L:"DD.MM.YYYY"},he:{dow:1,L:"DD.MM.YYYY"},id:{dow:2,L:"DD/MM/YYYY"},it:{dow:2,L:"DD/MM/YYYY"},ja:{dow:1,L:"YYYY年M月D日"},ko:{dow:1,L:"YYYY.MM.DD"},lv:{dow:2,L:"DD.MM.YYYY"},lt:{dow:2,L:"DD.MM.YYYY"},mk:{dow:2,L:"D.MM.YYYY"},nb:{dow:2,L:"D. MMMM YYYY"},nn:{dow:2,L:"D. MMMM YYYY"},pl:{dow:2,L:"DD.MM.YYYY"},pt:{dow:2,L:"DD/MM/YYYY"},ro:{dow:2,L:"DD.MM.YYYY"},ru:{dow:2,L:"DD.MM.YYYY"},sk:{dow:2,L:"DD.MM.YYYY"},"es-ES":{dow:2,L:"DD/MM/YYYY"},"es-MX":{dow:2,L:"DD/MM/YYYY"},sv:{dow:2,L:"YYYY-MM-DD"},th:{dow:1,L:"DD/MM/YYYY"},tr:{dow:2,L:"DD.MM.YYYY"},uk:{dow:2,L:"DD.MM.YYYY"},vi:{dow:2,L:"DD/MM/YYYY"}};wn.en=wn["en-US"];wn.es=wn["es-ES"];wn.no=wn.nb;wn.zh=wn["zh-CN"];const xA=Object.entries(wn).reduce((e,[t,{dow:n,L:r}])=>(e[t]={id:t,firstDayOfWeek:n,masks:{L:r}},e),{}),kA="MMMM YYYY",PA="W",AA="MMM",IA="h A",LA=["L","YYYY-MM-DD","YYYY/MM/DD"],RA=["L h:mm A","YYYY-MM-DD h:mm A","YYYY/MM/DD h:mm A"],NA=["L HH:mm","YYYY-MM-DD HH:mm","YYYY/MM/DD HH:mm"],FA=["h:mm A"],YA=["HH:mm"],BA="WWW, MMM D, YYYY",HA=["L","YYYY-MM-DD","YYYY/MM/DD"],jA="iso",VA="YYYY-MM-DDTHH:mm:ss.SSSZ",WA={title:kA,weekdays:PA,navMonths:AA,hours:IA,input:LA,inputDateTime:RA,inputDateTime24hr:NA,inputTime:FA,inputTime24hr:YA,dayPopover:BA,data:HA,model:jA,iso:VA},UA=300,zA=60,KA=80,GA={maxSwipeTime:UA,minHorizontalSwipeDistance:zA,maxVerticalSwipeDistance:KA},qA={componentPrefix:"V",color:"blue",isDark:!1,navVisibility:"click",titlePosition:"center",transition:"slide-h",touch:GA,masks:WA,locales:xA,datePicker:{updateOnInput:!0,inputDebounce:1e3,popover:{visibility:"hover-focus",placement:"bottom-start",isInteractive:!0}}},Vr=je(qA),ZA=w(()=>gk(Vr.locales,e=>(e.masks=ts(e.masks,Vr.masks),e))),jn=e=>typeof window<"u"&&Km(window.__vcalendar__,e)?ar(window.__vcalendar__,e):ar(Vr,e),JA=(e,t)=>(e.config.globalProperties.$VCalendar=Vr,Object.assign(Vr,ts(t,Vr))),XA=12,QA=5;function eI(e,t){const n=new Intl.DateTimeFormat().resolvedOptions().locale;let r;rn(e)?r=e:Km(e,"id")&&(r=e.id),r=(r||n).toLowerCase();const s=Object.keys(t),o=l=>s.find(u=>u.toLowerCase()===l);r=o(r)||o(r.substring(0,2))||n;const a={...t["en-IE"],...t[r],id:r,monthCacheSize:XA,pageCacheSize:QA};return bn(e)?ts(e,a):a}class ya{constructor(t=void 0,n){se(this,"id"),se(this,"daysInWeek"),se(this,"firstDayOfWeek"),se(this,"masks"),se(this,"timezone"),se(this,"hourLabels"),se(this,"dayNames"),se(this,"dayNamesShort"),se(this,"dayNamesShorter"),se(this,"dayNamesNarrow"),se(this,"monthNames"),se(this,"monthNamesShort"),se(this,"relativeTimeNames"),se(this,"amPm",["am","pm"]),se(this,"monthCache"),se(this,"pageCache");const{id:r,firstDayOfWeek:s,masks:o,monthCacheSize:a,pageCacheSize:i}=eI(t,ZA.value);this.monthCache=new Ed(a,DI,CI),this.pageCache=new Ed(i,ep,EA),this.id=r,this.daysInWeek=nt,this.firstDayOfWeek=I2(s,1,nt),this.masks=o,this.timezone=n||void 0,this.hourLabels=this.getHourLabels(),this.dayNames=xi("long",this.id),this.dayNamesShort=xi("short",this.id),this.dayNamesShorter=this.dayNamesShort.map(l=>l.substring(0,2)),this.dayNamesNarrow=xi("narrow",this.id),this.monthNames=Ad("long",this.id),this.monthNamesShort=Ad("short",this.id),this.relativeTimeNames=TI(this.id)}formatDate(t,n){return kI(t,n,this)}parseDate(t,n){return Id(t,n,this)}toDate(t,n={}){const r=new Date(NaN);let s=r;const{fillDate:o,mask:a,patch:i,rules:l}=n;if(Kt(t)?(n.type="number",s=new Date(+t)):rn(t)?(n.type="string",s=t?Id(t,a||"iso",this):r):Hr(t)?(n.type="date",s=new Date(t.getTime())):Pu(t)&&(n.type="object",s=this.getDateFromParts(t)),s&&(i||l)){let u=this.getDateParts(s);if(i&&o!=null){const c=this.getDateParts(this.toDate(o));u=this.getDateParts(this.toDate({...c,...qm(u,dI[i])}))}l&&(u=xI(u,l)),s=this.getDateFromParts(u)}return s||r}toDateOrNull(t,n={}){const r=this.toDate(t,n);return isNaN(r.getTime())?null:r}fromDate(t,{type:n,mask:r}={}){switch(n){case"number":return t?t.getTime():NaN;case"string":return t?this.formatDate(t,r||"iso"):"";case"object":return t?this.getDateParts(t):null;default:return t?new Date(t):null}}range(t){return jr.from(t,this)}ranges(t){return jr.fromMany(t,this)}getDateParts(t){return _I(t,this)}getDateFromParts(t){return fp(t,this.timezone)}getDateFromParams(t,n,r,s,o,a,i){return this.getDateFromParts({year:t,month:n,day:r,hours:s,minutes:o,seconds:a,milliseconds:i})}getPage(t){const n=this.pageCache.getOrSet(t,this);return OA(t,n)}getMonthParts(t,n){const{firstDayOfWeek:r}=this;return this.monthCache.getOrSet(t,n,r)}getThisMonthParts(){const t=new Date;return this.getMonthParts(t.getMonth()+1,t.getFullYear())}getPrevMonthParts(t,n){return t===1?this.getMonthParts(12,n-1):this.getMonthParts(t-1,n)}getNextMonthParts(t,n){return t===12?this.getMonthParts(1,n+1):this.getMonthParts(t+1,n)}getHourLabels(){return $I().map(t=>this.formatDate(t,this.masks.hours))}getDayId(t){return this.formatDate(t,"YYYY-MM-DD")}}var xr=(e=>(e.Any="any",e.All="all",e))(xr||{}),tp=(e=>(e.Days="days",e.Weeks="weeks",e.Months="months",e.Years="years",e))(tp||{}),np=(e=>(e.Days="days",e.Weekdays="weekdays",e.Weeks="weeks",e.Months="months",e.Years="years",e))(np||{}),rp=(e=>(e.OrdinalWeekdays="ordinalWeekdays",e))(rp||{});class tI{constructor(t,n,r){se(this,"validated",!0),this.type=t,this.interval=n,this.from=r,this.from||(console.error('A valid "from" date is required for date interval rule. This rule will be skipped.'),this.validated=!1)}passes(t){if(!this.validated)return!0;const{date:n}=t;switch(this.type){case"days":return Au(this.from.date,n)%this.interval===0;case"weeks":return bI(this.from.date,n)%this.interval===0;case"months":return wI(this.from.date,n)%this.interval===0;case"years":return cp(this.from.date,n)%this.interval===0;default:return!1}}}class hs{constructor(t,n,r,s){se(this,"components",[]),this.type=t,this.validator=r,this.getter=s,this.components=this.normalizeComponents(n)}static create(t,n){switch(t){case"days":return new nI(n);case"weekdays":return new rI(n);case"weeks":return new sI(n);case"months":return new oI(n);case"years":return new aI(n)}}normalizeComponents(t){if(this.validator(t))return[t];if(!Bt(t))return[];const n=[];return t.forEach(r=>{if(!this.validator(r)){console.error(`Component value ${r} in invalid for "${this.type}" rule. This rule will be skipped.`);return}n.push(r)}),n}passes(t){return this.getter(t).some(s=>this.components.includes(s))}}class nI extends hs{constructor(t){super("days",t,uI,({day:n,dayFromEnd:r})=>[n,-r])}}class rI extends hs{constructor(t){super("weekdays",t,yl,({weekday:n})=>[n])}}class sI extends hs{constructor(t){super("weeks",t,cI,({week:n,weekFromEnd:r})=>[n,-r])}}class oI extends hs{constructor(t){super("months",t,fI,({month:n})=>[n])}}class aI extends hs{constructor(t){super("years",t,Kt,({year:n})=>[n])}}class iI{constructor(t,n){se(this,"components"),this.type=t,this.components=this.normalizeComponents(n)}normalizeArrayConfig(t){const n=[];return t.forEach((r,s)=>{if(Kt(r)){if(s===0)return;if(!Od(t[0])){console.error(`Ordinal range for "${this.type}" rule is from -5 to -1 or 1 to 5. This rule will be skipped.`);return}if(!yl(r)){console.error(`Acceptable range for "${this.type}" rule is from 1 to 5. This rule will be skipped`);return}n.push([t[0],r])}else Bt(r)&&n.push(...this.normalizeArrayConfig(r))}),n}normalizeComponents(t){const n=[];return t.forEach((r,s)=>{if(Kt(r)){if(s===0)return;if(!Od(t[0])){console.error(`Ordinal range for "${this.type}" rule is from -5 to -1 or 1 to 5. This rule will be skipped.`);return}if(!yl(r)){console.error(`Acceptable range for "${this.type}" rule is from 1 to 5. This rule will be skipped`);return}n.push([t[0],r])}else Bt(r)&&n.push(...this.normalizeArrayConfig(r))}),n}passes(t){const{weekday:n,weekdayOrdinal:r,weekdayOrdinalFromEnd:s}=t;return this.components.some(([o,a])=>(o===r||o===-s)&&n===a)}}class lI{constructor(t){se(this,"type","function"),se(this,"validated",!0),this.fn=t,Dr(t)||(console.error("The function rule requires a valid function. This rule will be skipped."),this.validated=!1)}passes(t){return this.validated?this.fn(t):!0}}class ba{constructor(t,n={},r){se(this,"validated",!0),se(this,"config"),se(this,"type",xr.Any),se(this,"from"),se(this,"until"),se(this,"rules",[]),se(this,"locale",new ya),this.parent=r,n.locale&&(this.locale=n.locale),this.config=t,Dr(t)?(this.type=xr.All,this.rules=[new lI(t)]):Bt(t)?(this.type=xr.Any,this.rules=t.map(s=>new ba(s,n,this))):bn(t)?(this.type=xr.All,this.from=t.from?this.locale.getDateParts(t.from):r?.from,this.until=t.until?this.locale.getDateParts(t.until):r?.until,this.rules=this.getObjectRules(t)):(console.error("Rule group configuration must be an object or an array."),this.validated=!1)}getObjectRules(t){const n=[];if(t.every&&(rn(t.every)&&(t.every=[1,`${t.every}s`]),Bt(t.every))){const[r=1,s=tp.Days]=t.every;n.push(new tI(s,r,this.from))}return Object.values(np).forEach(r=>{r in t&&n.push(hs.create(r,t[r]))}),Object.values(rp).forEach(r=>{r in t&&n.push(new iI(r,t[r]))}),t.on!=null&&(Bt(t.on)||(t.on=[t.on]),n.push(new ba(t.on,{locale:this.locale},this.parent))),n}passes(t){return this.validated?this.from&&t.dayIndex<=this.from.dayIndex||this.until&&t.dayIndex>=this.until.dayIndex?!1:this.type===xr.Any?this.rules.some(n=>n.passes(t)):this.rules.every(n=>n.passes(t)):!0}}function uI(e){return Kt(e)?e>=1&&e<=31:!1}function yl(e){return Kt(e)?e>=1&&e<=7:!1}function cI(e){return Kt(e)?e>=-6&&e<=-1||e>=1&&e<=6:!1}function fI(e){return Kt(e)?e>=1&&e<=12:!1}function Od(e){return!(!Kt(e)||e<-5||e>5||e===0)}const dI={dateTime:["year","month","day","hours","minutes","seconds","milliseconds"],date:["year","month","day"],time:["hours","minutes","seconds","milliseconds"]},nt=7,hI=6,sp=1e3,op=sp*60,ap=op*60,Vo=ap*24,vI=[31,28,31,30,31,30,31,31,30,31,30,31],mI=["L","iso"],Es={milliseconds:[0,999,3],seconds:[0,59,2],minutes:[0,59,2],hours:[0,23,2]},ip=/d{1,2}|W{1,4}|M{1,4}|YY(?:YY)?|S{1,3}|Do|Z{1,4}|([HhMsDm])\1?|[aA]|"[^"]*"|'[^']*'/g,pI=/\[([^]*?)\]/gm,Md={D(e){return e.day},DD(e){return Oe(e.day,2)},d(e){return e.weekday-1},dd(e){return Oe(e.weekday-1,2)},W(e,t){return t.dayNamesNarrow[e.weekday-1]},WW(e,t){return t.dayNamesShorter[e.weekday-1]},WWW(e,t){return t.dayNamesShort[e.weekday-1]},WWWW(e,t){return t.dayNames[e.weekday-1]},M(e){return e.month},MM(e){return Oe(e.month,2)},MMM(e,t){return t.monthNamesShort[e.month-1]},MMMM(e,t){return t.monthNames[e.month-1]},YY(e){return String(e.year).substr(2)},YYYY(e){return Oe(e.year,4)},h(e){return e.hours%12||12},hh(e){return Oe(e.hours%12||12,2)},H(e){return e.hours},HH(e){return Oe(e.hours,2)},m(e){return e.minutes},mm(e){return Oe(e.minutes,2)},s(e){return e.seconds},ss(e){return Oe(e.seconds,2)},S(e){return Math.round(e.milliseconds/100)},SS(e){return Oe(Math.round(e.milliseconds/10),2)},SSS(e){return Oe(e.milliseconds,3)},a(e,t){return e.hours<12?t.amPm[0]:t.amPm[1]},A(e,t){return e.hours<12?t.amPm[0].toUpperCase():t.amPm[1].toUpperCase()},Z(){return"Z"},ZZ(e){const t=e.timezoneOffset;return`${t>0?"-":"+"}${Oe(Math.floor(Math.abs(t)/60),2)}`},ZZZ(e){const t=e.timezoneOffset;return`${t>0?"-":"+"}${Oe(Math.floor(Math.abs(t)/60)*100+Math.abs(t)%60,4)}`},ZZZZ(e){const t=e.timezoneOffset;return`${t>0?"-":"+"}${Oe(Math.floor(Math.abs(t)/60),2)}:${Oe(Math.abs(t)%60,2)}`}},On=/\d\d?/,gI=/\d{3}/,yI=/\d{4}/,Ds=/[0-9]*['a-z\u00A0-\u05FF\u0700-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF]+|[\u0600-\u06FF/]+(\s*?[\u0600-\u06FF]+){1,2}/i,xd=()=>{},kd=e=>(t,n,r)=>{const s=r[e].indexOf(n.charAt(0).toUpperCase()+n.substr(1).toLowerCase());~s&&(t.month=s)},xe={D:[On,(e,t)=>{e.day=t}],Do:[new RegExp(On.source+Ds.source),(e,t)=>{e.day=parseInt(t,10)}],d:[On,xd],W:[Ds,xd],M:[On,(e,t)=>{e.month=t-1}],MMM:[Ds,kd("monthNamesShort")],MMMM:[Ds,kd("monthNames")],YY:[On,(e,t)=>{const r=+new Date().getFullYear().toString().substr(0,2);e.year=+`${t>68?r-1:r}${t}`}],YYYY:[yI,(e,t)=>{e.year=t}],S:[/\d/,(e,t)=>{e.milliseconds=t*100}],SS:[/\d{2}/,(e,t)=>{e.milliseconds=t*10}],SSS:[gI,(e,t)=>{e.milliseconds=t}],h:[On,(e,t)=>{e.hours=t}],m:[On,(e,t)=>{e.minutes=t}],s:[On,(e,t)=>{e.seconds=t}],a:[Ds,(e,t,n)=>{const r=t.toLowerCase();r===n.amPm[0]?e.isPm=!1:r===n.amPm[1]&&(e.isPm=!0)}],Z:[/[^\s]*?[+-]\d\d:?\d\d|[^\s]*?Z?/,(e,t)=>{t==="Z"&&(t="+00:00");const n=`${t}`.match(/([+-]|\d\d)/gi);if(n){const r=+n[1]*60+parseInt(n[2],10);e.timezoneOffset=n[0]==="+"?r:-r}}]};xe.DD=xe.D;xe.dd=xe.d;xe.WWWW=xe.WWW=xe.WW=xe.W;xe.MM=xe.M;xe.mm=xe.m;xe.hh=xe.H=xe.HH=xe.h;xe.ss=xe.s;xe.A=xe.a;xe.ZZZZ=xe.ZZZ=xe.ZZ=xe.Z;function lp(e,t){return(mn(e)&&e||[rn(e)&&e||"YYYY-MM-DD"]).map(n=>mI.reduce((r,s)=>r.replace(s,t.masks[s]||""),n))}function Pu(e){return bn(e)&&"year"in e&&"month"in e&&"day"in e}function Pd(e,t=1){const n=e.getDay()+1,r=n>=t?t-n:-(7-(t-n));return ht(e,r)}function up(e,t,n){const r=Date.UTC(e,t-1,n);return Au(new Date(0),new Date(r))}function Au(e,t){return Math.round((t.getTime()-e.getTime())/Vo)}function bI(e,t){return Math.ceil(Au(Pd(e),Pd(t))/7)}function cp(e,t){return t.getUTCFullYear()-e.getUTCFullYear()}function wI(e,t){return cp(e,t)*12+(t.getMonth()-e.getMonth())}function fp(e,t=""){const n=new Date,{year:r=n.getFullYear(),month:s=n.getMonth()+1,day:o=n.getDate(),hours:a=0,minutes:i=0,seconds:l=0,milliseconds:u=0}=e;if(t){const c=`${Oe(r,4)}-${Oe(s,2)}-${Oe(o,2)}T${Oe(a,2)}:${Oe(i,2)}:${Oe(l,2)}.${Oe(u,3)}`;return J2(c,{timeZone:t})}return new Date(r,s-1,o,a,i,l,u)}function _I(e,t){let n=new Date(e.getTime());t.timezone&&(n=new Date(e.toLocaleString("en-US",{timeZone:t.timezone})),n.setMilliseconds(e.getMilliseconds()));const r=n.getMilliseconds(),s=n.getSeconds(),o=n.getMinutes(),a=n.getHours(),i=r+s*sp+o*op+a*ap,l=n.getMonth()+1,u=n.getFullYear(),c=t.getMonthParts(l,u),f=n.getDate(),d=c.numDays-f+1,h=n.getDay()+1,v=Math.floor((f-1)/7+1),m=Math.floor((c.numDays-f)/7+1),p=Math.ceil((f+Math.abs(c.firstWeekday-c.firstDayOfWeek))/7),b=c.numWeeks-p+1,S=c.weeknumbers[p],T=up(u,l,f);return{milliseconds:r,seconds:s,minutes:o,hours:a,time:i,day:f,dayFromEnd:d,weekday:h,weekdayOrdinal:v,weekdayOrdinalFromEnd:m,week:p,weekFromEnd:b,weeknumber:S,month:l,year:u,date:n,dateTime:n.getTime(),dayIndex:T,timezoneOffset:0,isValid:!0}}function DI(e,t,n){return`${t}-${e}-${n}`}function CI(e,t,n){const r=t%4===0&&t%100!==0||t%400===0,s=new Date(t,e-1,1),o=s.getDay()+1,a=e===2&&r?29:vI[e-1],i=n-1,l=cA(s,{weekStartsOn:i}),u=[],c=[];for(let f=0;fn.format(r))}function $I(){const e=[];for(let t=0;t<=24;t++)e.push(new Date(2e3,0,1,t));return e}function TI(e=void 0){const t=["second","minute","hour","day","week","month","quarter","year"],n=new Intl.RelativeTimeFormat(e);return t.reduce((r,s)=>{const o=n.formatToParts(100,s);return r[s]=o[1].unit,r},{})}function dp(){const e=[];for(let t=0;t<12;t++)e.push(new Date(2e3,t,15));return e}function Ad(e,t=void 0){const n=new Intl.DateTimeFormat(t,{month:e,timeZone:"UTC"});return dp().map(r=>n.format(r))}function EI(e,t,n){return Kt(t)?t===e:Bt(t)?t.includes(e):Dr(t)?t(e,n):!(t.min!=null&&t.min>e||t.max!=null&&t.max{if(i.disabled)return a;if(isNaN(a))return i.value;const l=Math.abs(a-n);return Math.abs(i.value-n){const o=Es[r],a=e[r];n[r]=MI(e,o,a,s)}),n}function Id(e,t,n){return lp(t,n).map(s=>{if(typeof s!="string")throw new Error("Invalid mask");let o=e;if(o.length>1e3)return!1;let a=!0;const i={};if(s.replace(ip,c=>{if(xe[c]){const f=xe[c],d=o.search(f[0]);~d?o.replace(f[0],h=>(f[1](i,h,n),o=o.substr(d+h.length),h)):a=!1}return xe[c]?"":c.slice(1,c.length-1)}),!a)return!1;const l=new Date;i.hours!=null&&(i.isPm===!0&&+i.hours!=12?i.hours=+i.hours+12:i.isPm===!1&&+i.hours==12&&(i.hours=0));let u;return i.timezoneOffset!=null?(i.minutes=+(i.minutes||0)-+i.timezoneOffset,u=new Date(Date.UTC(i.year||l.getFullYear(),i.month||0,i.day||1,i.hours||0,i.minutes||0,i.seconds||0,i.milliseconds||0))):u=n.getDateFromParts({year:i.year||l.getFullYear(),month:(i.month||0)+1,day:i.day||1,hours:i.hours||0,minutes:i.minutes||0,seconds:i.seconds||0,milliseconds:i.milliseconds||0}),u}).find(s=>s)||new Date(e)}function kI(e,t,n){if(e==null)return"";let r=lp(t,n)[0];/Z$/.test(r)&&(n.timezone="utc");const s=[];r=r.replace(pI,(a,i)=>(s.push(i),"??"));const o=n.getDateParts(e);return r=r.replace(ip,a=>a in Md?Md[a](o,n):a.slice(1,a.length-1)),r.replace(/\?\?/g,()=>s.shift())}let PI=0;class hp{constructor(t,n,r){se(this,"key",""),se(this,"hashcode",""),se(this,"highlight",null),se(this,"content",null),se(this,"dot",null),se(this,"bar",null),se(this,"event",null),se(this,"popover",null),se(this,"customData",null),se(this,"ranges"),se(this,"hasRanges",!1),se(this,"order",0),se(this,"pinPage",!1),se(this,"maxRepeatSpan",0),se(this,"locale");const{dates:s}=Object.assign(this,{hashcode:"",order:0,pinPage:!1},t);this.key||(this.key=++PI),this.locale=r,n.normalizeGlyphs(this),this.ranges=r.ranges(s??[]),this.hasRanges=!!mn(this.ranges),this.maxRepeatSpan=this.ranges.filter(o=>o.hasRepeat).map(o=>o.daySpan).reduce((o,a)=>Math.max(o,a),0)}intersectsRange({start:t,end:n}){if(t==null||n==null)return!1;const r=this.ranges.filter(a=>!a.hasRepeat);for(const a of r)if(a.intersectsDayRange(t.dayIndex,n.dayIndex))return!0;const s=this.ranges.filter(a=>a.hasRepeat);if(!s.length)return!1;let o=t;for(this.maxRepeatSpan>1&&(o=this.locale.getDateParts(ht(o.date,-this.maxRepeatSpan)));o.dayIndex<=n.dayIndex;){for(const a of s)if(a.startsOnDay(o))return!0;o=this.locale.getDateParts(ht(o.date,1))}return!1}}function bl(e){document&&document.dispatchEvent(new CustomEvent("show-popover",{detail:e}))}function Js(e){document&&document.dispatchEvent(new CustomEvent("hide-popover",{detail:e}))}function vp(e){document&&document.dispatchEvent(new CustomEvent("toggle-popover",{detail:e}))}function mp(e){const{visibility:t}=e,n=t==="click",r=t==="hover",s=t==="hover-focus",o=t==="focus";e.autoHide=!n;let a=!1,i=!1;const l=v=>{n&&(vp({...e,target:e.target||v.currentTarget}),v.stopPropagation())},u=v=>{a||(a=!0,(r||s)&&bl({...e,target:e.target||v.currentTarget}))},c=()=>{a&&(a=!1,(r||s&&!i)&&Js(e))},f=v=>{i||(i=!0,(o||s)&&bl({...e,target:e.target||v.currentTarget}))},d=v=>{i&&!Ho(v.currentTarget,v.relatedTarget)&&(i=!1,(o||s&&!a)&&Js(e))},h={};switch(e.visibility){case"click":h.click=l;break;case"hover":h.mousemove=u,h.mouseleave=c;break;case"focus":h.focusin=f,h.focusout=d;break;case"hover-focus":h.mousemove=u,h.mouseleave=c,h.focusin=f,h.focusout=d;break}return h}const Ld=e=>{const t=da(e);if(t==null)return;const n=t.popoverHandlers;!n||!n.length||(n.forEach(r=>r()),delete t.popoverHandlers)},Rd=(e,t)=>{const n=da(e);if(n==null)return;const r=[],s=mp(t);Object.entries(s).forEach(([o,a])=>{r.push(Nn(n,o,a))}),n.popoverHandlers=r},pp={mounted(e,t){const{value:n}=t;n&&Rd(e,n)},updated(e,t){const{oldValue:n,value:r}=t,s=n?.visibility,o=r?.visibility;s!==o&&(s&&(Ld(e),o||Js(n)),o&&Rd(e,r))},unmounted(e){Ld(e)}},AI=(e,t,{maxSwipeTime:n,minHorizontalSwipeDistance:r,maxVerticalSwipeDistance:s})=>{if(!e||!e.addEventListener||!Dr(t))return null;let o=0,a=0,i=null,l=!1;function u(f){const d=f.changedTouches[0];o=d.screenX,a=d.screenY,i=new Date().getTime(),l=!0}function c(f){if(!l||!i)return;l=!1;const d=f.changedTouches[0],h=d.screenX-o,v=d.screenY-a;if(new Date().getTime()-i=r&&Math.abs(v)<=s){const p={toLeft:!1,toRight:!1};h<0?p.toLeft=!0:p.toRight=!0,t(p)}}return Nn(e,"touchstart",u,{passive:!0}),Nn(e,"touchend",c,{passive:!0}),()=>{Rn(e,"touchstart",u),Rn(e,"touchend",c)}},Wo={},II=(e,t=10)=>{Wo[e]=Date.now()+t},LI=(e,t)=>{if(e in Wo){const n=Wo[e];if(Date.now()t.value?"dark":"light");let r,s;function o(h){t.value=h.matches}function a(){RI("matchMedia")&&(r=window.matchMedia("(prefers-color-scheme: dark)"),r.addEventListener("change",o),t.value=r.matches)}function i(){const{selector:h=":root",darkClass:v="dark"}=e.value,m=document.querySelector(h);t.value=m.classList.contains(v)}function l(h){const{selector:v=":root",darkClass:m="dark"}=h;if(gp()&&v&&m){const p=document.querySelector(v);p&&(s=new MutationObserver(i),s.observe(p,{attributes:!0,attributeFilter:["class"]}),t.value=p.classList.contains(m))}}function u(){f();const h=typeof e.value;h==="string"&&e.value.toLowerCase()==="system"?a():h==="object"?l(e.value):t.value=!!e.value}const c=Te(()=>e.value,()=>u(),{immediate:!0});function f(){r&&(r.removeEventListener("change",o),r=void 0),s&&(s.disconnect(),s=void 0)}function d(){f(),c()}return ss(()=>d()),{isDark:t,displayMode:n,cleanup:d}}const FI=["base","start","end","startEnd"],YI=["class","wrapperClass","contentClass","style","contentStyle","color","fillMode"],BI={base:{},start:{},end:{}};function Iu(e,t,n=BI){let r=e,s={};t===!0||rn(t)?(r=rn(t)?t:r,s={...n}):bn(t)&&(pd(t,FI)?s={...t}:s={base:{...t},start:{...t},end:{...t}});const o=ts(s,{start:s.startEnd,end:s.startEnd},n);return Object.entries(o).forEach(([a,i])=>{let l=r;i===!0||rn(i)?(l=rn(i)?i:l,o[a]={color:l}):bn(i)&&(pd(i,YI)?o[a]={...i}:o[a]={}),ts(o[a],{color:l})}),o}class HI{constructor(){se(this,"type","highlight")}normalizeConfig(t,n){return Iu(t,n,{base:{fillMode:"light"},start:{fillMode:"solid"},end:{fillMode:"solid"}})}prepareRender(t){t.highlights=[],t.content||(t.content=[])}render({data:t,onStart:n,onEnd:r},s){const{key:o,highlight:a}=t;if(!a)return;const{highlights:i}=s,{base:l,start:u,end:c}=a;n&&r?i.push({...u,key:o,wrapperClass:`vc-day-layer vc-day-box-center-center vc-attr vc-${u.color}`,class:[`vc-highlight vc-highlight-bg-${u.fillMode}`,u.class],contentClass:[`vc-attr vc-highlight-content-${u.fillMode} vc-${u.color}`,u.contentClass]}):n?(i.push({...l,key:`${o}-base`,wrapperClass:`vc-day-layer vc-day-box-right-center vc-attr vc-${l.color}`,class:[`vc-highlight vc-highlight-base-start vc-highlight-bg-${l.fillMode}`,l.class]}),i.push({...u,key:o,wrapperClass:`vc-day-layer vc-day-box-center-center vc-attr vc-${u.color}`,class:[`vc-highlight vc-highlight-bg-${u.fillMode}`,u.class],contentClass:[`vc-attr vc-highlight-content-${u.fillMode} vc-${u.color}`,u.contentClass]})):r?(i.push({...l,key:`${o}-base`,wrapperClass:`vc-day-layer vc-day-box-left-center vc-attr vc-${l.color}`,class:[`vc-highlight vc-highlight-base-end vc-highlight-bg-${l.fillMode}`,l.class]}),i.push({...c,key:o,wrapperClass:`vc-day-layer vc-day-box-center-center vc-attr vc-${c.color}`,class:[`vc-highlight vc-highlight-bg-${c.fillMode}`,c.class],contentClass:[`vc-attr vc-highlight-content-${c.fillMode} vc-${c.color}`,c.contentClass]})):i.push({...l,key:`${o}-middle`,wrapperClass:`vc-day-layer vc-day-box-center-center vc-attr vc-${l.color}`,class:[`vc-highlight vc-highlight-base-middle vc-highlight-bg-${l.fillMode}`,l.class],contentClass:[`vc-attr vc-highlight-content-${l.fillMode} vc-${l.color}`,l.contentClass]})}}class Lu{constructor(t,n){se(this,"type",""),se(this,"collectionType",""),this.type=t,this.collectionType=n}normalizeConfig(t,n){return Iu(t,n)}prepareRender(t){t[this.collectionType]=[]}render({data:t,onStart:n,onEnd:r},s){const{key:o}=t,a=t[this.type];if(!o||!a)return;const i=s[this.collectionType],{base:l,start:u,end:c}=a;n?i.push({...u,key:o,class:[`vc-${this.type} vc-${this.type}-start vc-${u.color} vc-attr`,u.class]}):r?i.push({...c,key:o,class:[`vc-${this.type} vc-${this.type}-end vc-${c.color} vc-attr`,c.class]}):i.push({...l,key:o,class:[`vc-${this.type} vc-${this.type}-base vc-${l.color} vc-attr`,l.class]})}}class jI extends Lu{constructor(){super("content","content")}normalizeConfig(t,n){return Iu("base",n)}}class VI extends Lu{constructor(){super("dot","dots")}}class WI extends Lu{constructor(){super("bar","bars")}}class UI{constructor(t){se(this,"color"),se(this,"renderers",[new jI,new HI,new VI,new WI]),this.color=t}normalizeGlyphs(t){this.renderers.forEach(n=>{const r=n.type;t[r]!=null&&(t[r]=n.normalizeConfig(this.color,t[r]))})}prepareRender(t={}){return this.renderers.forEach(n=>{n.prepareRender(t)}),t}render(t,n){this.renderers.forEach(r=>{r.render(t,n)})}}const yp=Symbol("__vc_base_context__"),bp={color:{type:String,default:()=>jn("color")},isDark:{type:[Boolean,String,Object],default:()=>jn("isDark")},firstDayOfWeek:Number,masks:Object,locale:[String,Object],timezone:String,minDate:null,maxDate:null,disabledDates:null};function wp(e){const t=w(()=>e.color??""),n=w(()=>e.isDark??!1),{displayMode:r}=NI(n),s=w(()=>new UI(t.value)),o=w(()=>{if(e.locale instanceof ya)return e.locale;const d=bn(e.locale)?e.locale:{id:e.locale,firstDayOfWeek:e.firstDayOfWeek,masks:e.masks};return new ya(d,e.timezone)}),a=w(()=>o.value.masks),i=w(()=>e.minDate),l=w(()=>e.maxDate),u=w(()=>{const d=e.disabledDates?[...e.disabledDates]:[];return i.value!=null&&d.push({start:null,end:ht(o.value.toDate(i.value),-1)}),l.value!=null&&d.push({start:ht(o.value.toDate(l.value),1),end:null}),o.value.ranges(d)}),c=w(()=>new hp({key:"disabled",dates:u.value,order:100},s.value,o.value)),f={color:t,isDark:n,displayMode:r,theme:s,locale:o,masks:a,minDate:i,maxDate:l,disabledDates:u,disabledAttribute:c};return Pt(yp,f),f}function zI(e){return Pe(yp,()=>wp(e),!0)}function _p(e){return`__vc_slot_${e}__`}function Dp(e,t={}){Object.keys(e).forEach(n=>{Pt(_p(t[n]??n),e[n])})}function Cp(e){return Pe(_p(e),null)}const KI={...bp,view:{type:String,default:"monthly",validator(e){return["daily","weekly","monthly"].includes(e)}},rows:{type:Number,default:1},columns:{type:Number,default:1},step:Number,titlePosition:{type:String,default:()=>jn("titlePosition")},navVisibility:{type:String,default:()=>jn("navVisibility")},showWeeknumbers:[Boolean,String],showIsoWeeknumbers:[Boolean,String],expanded:Boolean,borderless:Boolean,transparent:Boolean,initialPage:Object,initialPagePosition:{type:Number,default:1},minPage:Object,maxPage:Object,transition:String,attributes:Array,trimWeeks:Boolean,disablePageSwipe:Boolean},GI=["dayclick","daymouseenter","daymouseleave","dayfocusin","dayfocusout","daykeydown","weeknumberclick","transition-start","transition-end","did-move","update:view","update:pages"],Sp=Symbol("__vc_calendar_context__");function qI(e,{slots:t,emit:n}){const r=oe(null),s=oe(null),o=oe(new Date().getDate()),a=oe(!1),i=oe(Symbol()),l=oe(Symbol()),u=oe(e.view),c=oe([]),f=oe("");let d=null,h=null;Dp(t);const{theme:v,color:m,displayMode:p,locale:b,masks:S,minDate:T,maxDate:M,disabledAttribute:D,disabledDates:C}=zI(e),E=w(()=>e.rows*e.columns),P=w(()=>e.step||E.value),$=w(()=>zm(c.value)??null),I=w(()=>Ar(c.value)??null),j=w(()=>e.minPage||(T.value?Q(T.value):null)),O=w(()=>e.maxPage||(M.value?Q(M.value):null)),W=w(()=>e.navVisibility),re=w(()=>!!e.showWeeknumbers),X=w(()=>!!e.showIsoWeeknumbers),ee=w(()=>u.value==="monthly"),J=w(()=>u.value==="weekly"),ue=w(()=>u.value==="daily"),we=()=>{a.value=!0,n("transition-start")},V=()=>{a.value=!1,n("transition-end"),d&&(d.resolve(!0),d=null)},fe=(N,y,F=u.value)=>Qm(N,y,F,b.value),Q=N=>Xm(N,u.value,b.value),Le=N=>{!D.value||!tt.value||(N.isDisabled=tt.value.cellExists(D.value.key,N.dayIndex))},pe=N=>{N.isFocusable=N.inMonth&&N.day===o.value},Ye=(N,y)=>{for(const F of N)for(const Z of F.days)if(y(Z)===!1)return},Re=w(()=>c.value.reduce((N,y)=>(N.push(...y.viewDays),N),[])),ye=w(()=>{const N=[];return(e.attributes||[]).forEach((y,F)=>{!y||!y.dates||N.push(new hp({...y,order:y.order||0},v.value,b.value))}),D.value&&N.push(D.value),N}),ze=w(()=>mn(ye.value)),tt=w(()=>{const N=new MA;return ye.value.forEach(y=>{y.ranges.forEach(F=>{N.render(y,F,Re.value)})}),N}),lt=w(()=>Re.value.reduce((N,y)=>(N[y.dayIndex]={day:y,cells:[]},N[y.dayIndex].cells.push(...tt.value.getCells(y)),N),{})),mt=(N,y)=>{const F=e.showWeeknumbers||e.showIsoWeeknumbers;return F==null?"":Qx(F)?F?"left":"":F.startsWith("right")?y>1?"right":F:N>1?"left":F},ut=()=>{var N,y;if(!ze.value)return null;const F=ye.value.find(He=>He.pinPage)||ye.value[0];if(!F||!F.hasRanges)return null;const[Z]=F.ranges,he=((N=Z.start)==null?void 0:N.date)||((y=Z.end)==null?void 0:y.date);return he?Q(he):null},g=()=>{if(sn($.value))return $.value;const N=ut();return sn(N)?N:Q(new Date)},_=(N,y={})=>{const{view:F=u.value,position:Z=1,force:he}=y,He=Z>0?1-Z:-(E.value+Z);let ft=fe(N,He,F),$t=fe(ft,E.value-1,F);return he||(gl(ft,j.value)?ft=j.value:ga($t,O.value)&&(ft=fe(O.value,1-E.value)),$t=fe(ft,E.value-1)),{fromPage:ft,toPage:$t}},x=(N,y,F="")=>{if(F==="none"||F==="fade")return F;if(N?.view!==y?.view)return"fade";const Z=ga(y,N),he=gl(y,N);return!Z&&!he?"fade":F==="slide-v"?he?"slide-down":"slide-up":he?"slide-right":"slide-left"},Y=(N={})=>new Promise((y,F)=>{const{position:Z=1,force:he=!1,transition:He}=N,ft=sn(N.page)?N.page:g(),{fromPage:$t}=_(ft,{position:Z,force:he}),$r=[];for(let Tr=0;Tr{const y=$.value??Q(new Date);return fe(y,N)},H=(N,y={})=>{const F=sn(N)?N:Q(N);return Object.assign(y,_(F,{...y,force:!0})),TA(y.fromPage,y.toPage,u.value,b.value).map(he=>SA(he,j.value,O.value)).some(he=>he)},K=(N,y={})=>H(R(N),y),U=w(()=>K(-P.value)),z=w(()=>K(P.value)),B=async(N,y={})=>!y.force&&!H(N,y)?!1:(y.fromPage&&!$A(y.fromPage,$.value)&&(Js({id:i.value,hideDelay:0}),y.view&&(II("view",10),u.value=y.view),await Y({...y,page:y.fromPage,position:1,force:!0}),n("did-move",c.value)),!0),q=(N,y={})=>B(R(N),y),ne=()=>q(-P.value),te=()=>q(P.value),ie=N=>{const y=ee.value?".in-month":"",F=`.id-${b.value.getDayId(N)}${y}`,Z=`${F}.vc-focusable, ${F} .vc-focusable`,he=r.value;if(he){const He=he.querySelector(Z);if(He)return He.focus(),!0}return!1},de=async(N,y={})=>ie(N)?!0:(await B(N,y),ie(N)),Ce=(N,y)=>{o.value=N.day,n("dayclick",N,y)},_e=(N,y)=>{n("daymouseenter",N,y)},Be=(N,y)=>{n("daymouseleave",N,y)},ct=(N,y)=>{o.value=N.day,s.value=N,N.isFocused=!0,n("dayfocusin",N,y)},Vt=(N,y)=>{s.value=null,N.isFocused=!1,n("dayfocusout",N,y)},Jn=(N,y)=>{n("daykeydown",N,y);const F=N.noonDate;let Z=null;switch(y.key){case"ArrowLeft":{Z=ht(F,-1);break}case"ArrowRight":{Z=ht(F,1);break}case"ArrowUp":{Z=ht(F,-7);break}case"ArrowDown":{Z=ht(F,7);break}case"Home":{Z=ht(F,-N.weekdayPosition+1);break}case"End":{Z=ht(F,N.weekdayPositionFromEnd);break}case"PageUp":{y.altKey?Z=Td(F,-1):Z=pa(F,-1);break}case"PageDown":{y.altKey?Z=Td(F,1):Z=pa(F,1);break}}Z&&(y.preventDefault(),de(Z).catch())},fn=N=>{const y=s.value;y!=null&&Jn(y,N)},Xn=(N,y)=>{n("weeknumberclick",N,y)};Y({page:e.initialPage,position:e.initialPagePosition}),Gt(()=>{!e.disablePageSwipe&&r.value&&(h=AI(r.value,({toLeft:N=!1,toRight:y=!1})=>{N?te():y&&ne()},jn("touch")))}),ss(()=>{c.value=[],h&&h()}),Te(()=>b.value,()=>{Y()}),Te(()=>E.value,()=>Y()),Te(()=>e.view,()=>u.value=e.view),Te(()=>u.value,()=>{LI("view",()=>{Y()}),n("update:view",u.value)}),Te(()=>o.value,()=>{Ye(c.value,N=>pe(N))}),zn(()=>{n("update:pages",c.value),Ye(c.value,N=>{Le(N),pe(N)})});const Je={emit:n,containerRef:r,focusedDay:s,inTransition:a,navPopoverId:i,dayPopoverId:l,view:u,pages:c,transitionName:f,theme:v,color:m,displayMode:p,locale:b,masks:S,attributes:ye,disabledAttribute:D,disabledDates:C,attributeContext:tt,days:Re,dayCells:lt,count:E,step:P,firstPage:$,lastPage:I,canMovePrev:U,canMoveNext:z,minPage:j,maxPage:O,isMonthly:ee,isWeekly:J,isDaily:ue,navVisibility:W,showWeeknumbers:re,showIsoWeeknumbers:X,getDateAddress:Q,canMove:H,canMoveBy:K,move:B,moveBy:q,movePrev:ne,moveNext:te,onTransitionBeforeEnter:we,onTransitionAfterEnter:V,tryFocusDate:ie,focusDate:de,onKeydown:fn,onDayKeydown:Jn,onDayClick:Ce,onDayMouseenter:_e,onDayMouseleave:Be,onDayFocusin:ct,onDayFocusout:Vt,onWeeknumberClick:Xn};return Pt(Sp,Je),Je}function Sr(){const e=Pe(Sp);if(e)return e;throw new Error("Calendar context missing. Please verify this component is nested within a valid context provider.")}const ZI=Ze({inheritAttrs:!1,emits:["before-show","after-show","before-hide","after-hide"],props:{id:{type:[Number,String,Symbol],required:!0},showDelay:{type:Number,default:0},hideDelay:{type:Number,default:110},boundarySelector:{type:String}},setup(e,{emit:t}){let n;const r=oe();let s=null,o=null;const a=je({isVisible:!1,target:null,data:null,transition:"slide-fade",placement:"bottom",direction:"",positionFixed:!1,modifiers:[],isInteractive:!0,visibility:"click",isHovered:!1,isFocused:!1,autoHide:!1,force:!1});function i(V){V&&(a.direction=V.split("-")[0])}function l({placement:V,options:fe}){i(V||fe?.placement)}const u=w(()=>({placement:a.placement,strategy:a.positionFixed?"fixed":"absolute",boundary:"",modifiers:[{name:"onUpdate",enabled:!0,phase:"afterWrite",fn:l},...a.modifiers||[]],onFirstUpdate:l})),c=w(()=>{const V=a.direction==="left"||a.direction==="right";let fe="";if(a.placement){const Q=a.placement.split("-");Q.length>1&&(fe=Q[1])}return["start","top","left"].includes(fe)?V?"top":"left":["end","bottom","right"].includes(fe)?V?"bottom":"right":V?"middle":"center"});function f(){o&&(o.destroy(),o=null)}function d(){Ot(()=>{const V=da(a.target);!V||!r.value||(o&&o.state.elements.reference!==V&&f(),o?o.update():o=j_(V,r.value,u.value))})}function h(V){Object.assign(a,Gm(V,"force"))}function v(V,fe){clearTimeout(n),V>0?n=setTimeout(fe,V):fe()}function m(V){return!V||!o?!1:da(V)===o.state.elements.reference}async function p(V={}){a.force||(V.force&&(a.force=!0),v(V.showDelay??e.showDelay,()=>{a.isVisible&&(a.force=!1),h({...V,isVisible:!0}),d()}))}function b(V={}){o&&(V.target&&!m(V.target)||a.force||(V.force&&(a.force=!0),v(V.hideDelay??e.hideDelay,()=>{a.isVisible||(a.force=!1),a.isVisible=!1})))}function S(V={}){V.target!=null&&(a.isVisible&&m(V.target)?b(V):p(V))}function T(V){if(!o)return;const fe=o.state.elements.reference;if(!r.value||!fe)return;const Q=V.target;Ho(r.value,Q)||Ho(fe,Q)||b({force:!0})}function M(V){(V.key==="Esc"||V.key==="Escape")&&b()}function D({detail:V}){!V.id||V.id!==e.id||p(V)}function C({detail:V}){!V.id||V.id!==e.id||b(V)}function E({detail:V}){!V.id||V.id!==e.id||S(V)}function P(){Nn(document,"keydown",M),Nn(document,"click",T),Nn(document,"show-popover",D),Nn(document,"hide-popover",C),Nn(document,"toggle-popover",E)}function $(){Rn(document,"keydown",M),Rn(document,"click",T),Rn(document,"show-popover",D),Rn(document,"hide-popover",C),Rn(document,"toggle-popover",E)}function I(V){t("before-show",V)}function j(V){a.force=!1,t("after-show",V)}function O(V){t("before-hide",V)}function W(V){a.force=!1,f(),t("after-hide",V)}function re(V){V.stopPropagation()}function X(){a.isHovered=!0,a.isInteractive&&["hover","hover-focus"].includes(a.visibility)&&p()}function ee(){if(a.isHovered=!1,!o)return;const V=o.state.elements.reference;a.autoHide&&!a.isFocused&&(!V||V!==document.activeElement)&&["hover","hover-focus"].includes(a.visibility)&&b()}function J(){a.isFocused=!0,a.isInteractive&&["focus","hover-focus"].includes(a.visibility)&&p()}function ue(V){["focus","hover-focus"].includes(a.visibility)&&(!V.relatedTarget||!Ho(r.value,V.relatedTarget))&&(a.isFocused=!1,!a.isHovered&&a.autoHide&&b())}function we(){s!=null&&(s.disconnect(),s=null)}return Te(()=>r.value,V=>{we(),V&&(s=new ResizeObserver(()=>{o&&o.update()}),s.observe(V))}),Te(()=>a.placement,i,{immediate:!0}),Gt(()=>{P()}),ss(()=>{f(),we(),$()}),{...no(a),popoverRef:r,alignment:c,hide:b,setupPopper:d,beforeEnter:I,afterEnter:j,beforeLeave:O,afterLeave:W,onClick:re,onMouseOver:X,onMouseLeave:ee,onFocusIn:J,onFocusOut:ue}}}),qn=(e,t)=>{const n=e.__vccOpts||e;for(const[r,s]of t)n[r]=s;return n};function JI(e,t,n,r,s,o){return G(),ae("div",{class:ke(["vc-popover-content-wrapper",{"is-interactive":e.isInteractive}]),ref:"popoverRef",onClick:t[0]||(t[0]=(...a)=>e.onClick&&e.onClick(...a)),onMouseover:t[1]||(t[1]=(...a)=>e.onMouseOver&&e.onMouseOver(...a)),onMouseleave:t[2]||(t[2]=(...a)=>e.onMouseLeave&&e.onMouseLeave(...a)),onFocusin:t[3]||(t[3]=(...a)=>e.onFocusIn&&e.onFocusIn(...a)),onFocusout:t[4]||(t[4]=(...a)=>e.onFocusOut&&e.onFocusOut(...a))},[L(uo,{name:`vc-${e.transition}`,appear:"",onBeforeEnter:e.beforeEnter,onAfterEnter:e.afterEnter,onBeforeLeave:e.beforeLeave,onAfterLeave:e.afterLeave},{default:Ee(()=>[e.isVisible?(G(),ae("div",qt({key:0,tabindex:"-1",class:`vc-popover-content direction-${e.direction}`},e.$attrs),[so(e.$slots,"default",{direction:e.direction,alignment:e.alignment,data:e.data,hide:e.hide},()=>[Kr(Qe(e.data),1)]),me("span",{class:ke(["vc-popover-caret",`direction-${e.direction}`,`align-${e.alignment}`])},null,2)],16)):We("",!0)]),_:3},8,["name","onBeforeEnter","onAfterEnter","onBeforeLeave","onAfterLeave"])],34)}const Ja=qn(ZI,[["render",JI]]),XI={class:"vc-day-popover-row"},QI={key:0,class:"vc-day-popover-row-indicator"},eL={class:"vc-day-popover-row-label"},$p=Ze({__name:"PopoverRow",props:{attribute:null},setup(e){const t=e,n=w(()=>{const{content:r,highlight:s,dot:o,bar:a,popover:i}=t.attribute;return i&&i.hideIndicator?null:r?{class:`vc-bar vc-day-popover-row-bar vc-attr vc-${r.base.color}`}:s?{class:`vc-highlight-bg-solid vc-day-popover-row-highlight vc-attr vc-${s.base.color}`}:o?{class:`vc-dot vc-attr vc-${o.base.color}`}:a?{class:`vc-bar vc-day-popover-row-bar vc-attr vc-${a.base.color}`}:null});return(r,s)=>(G(),ae("div",XI,[A(n)?(G(),ae("div",QI,[me("span",{class:ke(A(n).class)},null,2)])):We("",!0),me("div",eL,[so(r.$slots,"default",{},()=>[Kr(Qe(e.attribute.popover?e.attribute.popover.label:"No content provided"),1)])])]))}}),tL={inheritAttrs:!1},Rt=Ze({...tL,__name:"CalendarSlot",props:{name:null},setup(e){const n=Cp(e.name);return(r,s)=>A(n)?(G(),Ae(Pa(A(n)),Rr(qt({key:0},r.$attrs)),null,16)):so(r.$slots,"default",{key:1})}}),nL={class:"vc-day-popover-container"},rL={key:0,class:"vc-day-popover-header"},sL=Ze({__name:"CalendarDayPopover",setup(e){const{dayPopoverId:t,displayMode:n,color:r,masks:s,locale:o}=Sr();function a(l,u){return o.value.formatDate(l,u)}function i(l){return o.value.formatDate(l.date,s.value.dayPopover)}return(l,u)=>(G(),Ae(Ja,{id:A(t),class:ke([`vc-${A(r)}`,`vc-${A(n)}`])},{default:Ee(({data:{day:c,attributes:f},hide:d})=>[L(Rt,{name:"day-popover",day:c,"day-title":i(c),attributes:f,format:a,masks:A(s),hide:d},{default:Ee(()=>[me("div",nL,[A(s).dayPopover?(G(),ae("div",rL,Qe(i(c)),1)):We("",!0),(G(!0),ae(be,null,Ft(f,h=>(G(),Ae($p,{key:h.key,attribute:h},null,8,["attribute"]))),128))])]),_:2},1032,["day","day-title","attributes","masks","hide"])]),_:1},8,["id","class"]))}}),oL={},aL={"stroke-linecap":"round","stroke-linejoin":"round",viewBox:"0 0 24 24"},iL=me("polyline",{points:"9 18 15 12 9 6"},null,-1),lL=[iL];function uL(e,t){return G(),ae("svg",aL,lL)}const cL=qn(oL,[["render",uL]]),fL={},dL={"stroke-linecap":"round","stroke-linejoin":"round",viewBox:"0 0 24 24"},hL=me("polyline",{points:"15 18 9 12 15 6"},null,-1),vL=[hL];function mL(e,t){return G(),ae("svg",dL,vL)}const pL=qn(fL,[["render",mL]]),gL={},yL={"stroke-linecap":"round","stroke-linejoin":"round",viewBox:"0 0 24 24"},bL=me("polyline",{points:"6 9 12 15 18 9"},null,-1),wL=[bL];function _L(e,t){return G(),ae("svg",yL,wL)}const DL=qn(gL,[["render",_L]]),CL={},SL={fill:"none","stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",viewBox:"0 0 24 24"},$L=me("path",{d:"M12 8v4l3 3m6-3a9 9 0 11-18 0 9 9 0 0118 0z"},null,-1),TL=[$L];function EL(e,t){return G(),ae("svg",SL,TL)}const OL=qn(CL,[["render",EL]]),ML=Object.freeze(Object.defineProperty({__proto__:null,IconChevronDown:DL,IconChevronLeft:pL,IconChevronRight:cL,IconClock:OL},Symbol.toStringTag,{value:"Module"})),ns=Ze({__name:"BaseIcon",props:{name:{type:String,required:!0},width:{type:String},height:{type:String},size:{type:String,default:"26"},viewBox:{type:String}},setup(e){const t=e,n=w(()=>t.width||t.size),r=w(()=>t.height||t.size),s=w(()=>ML[`Icon${t.name}`]);return(o,a)=>(G(),Ae(Pa(A(s)),{width:A(n),height:A(r),class:"vc-base-icon"},null,8,["width","height"]))}}),xL=["disabled"],kL={key:1,class:"vc-title-wrapper"},PL={type:"button",class:"vc-title"},AL=["disabled"],Tp=Ze({__name:"CalendarHeader",props:{page:null,layout:null,isLg:{type:Boolean},isXl:{type:Boolean},is2xl:{type:Boolean},hideTitle:{type:Boolean},hideArrows:{type:Boolean}},setup(e){const t=e,{navPopoverId:n,navVisibility:r,canMovePrev:s,movePrev:o,canMoveNext:a,moveNext:i}=Sr(),l=w(()=>{switch(t.page.titlePosition){case"left":return"bottom-start";case"right":return"bottom-end";default:return"bottom"}}),u=w(()=>{const{page:m}=t;return{id:n.value,visibility:r.value,placement:l.value,modifiers:[{name:"flip",options:{fallbackPlacements:["bottom"]}}],data:{page:m},isInteractive:!0}}),c=w(()=>t.page.titlePosition.includes("left")),f=w(()=>t.page.titlePosition.includes("right")),d=w(()=>t.layout?t.layout:c.value?"tu-pn":f.value?"pn-tu":"p-tu-n;"),h=w(()=>({prev:d.value.includes("p")&&!t.hideArrows,title:d.value.includes("t")&&!t.hideTitle,next:d.value.includes("n")&&!t.hideArrows})),v=w(()=>({gridTemplateColumns:d.value.split("").map(p=>{switch(p){case"p":return"[prev] auto";case"n":return"[next] auto";case"t":return"[title] auto";case"-":return"1fr";default:return""}}).join(" ")}));return(m,p)=>(G(),ae("div",{class:ke(["vc-header",{"is-lg":e.isLg,"is-xl":e.isXl,"is-2xl":e.is2xl}]),style:pn(A(v))},[A(h).prev?(G(),ae("button",{key:0,type:"button",class:"vc-arrow vc-prev vc-focus",disabled:!A(s),onClick:p[0]||(p[0]=(...b)=>A(o)&&A(o)(...b)),onKeydown:p[1]||(p[1]=Nc((...b)=>A(o)&&A(o)(...b),["space","enter"]))},[L(Rt,{name:"header-prev-button",disabled:!A(s)},{default:Ee(()=>[L(ns,{name:"ChevronLeft",size:"24"})]),_:1},8,["disabled"])],40,xL)):We("",!0),A(h).title?(G(),ae("div",kL,[L(Rt,{name:"header-title-wrapper"},{default:Ee(()=>[zl((G(),ae("button",PL,[L(Rt,{name:"header-title",title:e.page.title},{default:Ee(()=>[me("span",null,Qe(e.page.title),1)]),_:1},8,["title"])])),[[A(pp),A(u)]])]),_:1})])):We("",!0),A(h).next?(G(),ae("button",{key:2,type:"button",class:"vc-arrow vc-next vc-focus",disabled:!A(a),onClick:p[2]||(p[2]=(...b)=>A(i)&&A(i)(...b)),onKeydown:p[3]||(p[3]=Nc((...b)=>A(i)&&A(i)(...b),["space","enter"]))},[L(Rt,{name:"header-next-button",disabled:!A(a)},{default:Ee(()=>[L(ns,{name:"ChevronRight",size:"24"})]),_:1},8,["disabled"])],40,AL)):We("",!0)],6))}}),Ep=Symbol("__vc_page_context__");function IL(e){const{locale:t,getDateAddress:n,canMove:r}=Sr();function s(i,l){const{month:u,year:c}=n(new Date);return dp().map((f,d)=>{const h=d+1;return{month:h,year:i,id:CA(h,i),label:t.value.formatDate(f,l),ariaLabel:t.value.formatDate(f,"MMMM"),isActive:h===e.value.month&&i===e.value.year,isCurrent:h===u&&i===c,isDisabled:!r({month:h,year:i},{position:e.value.position})}})}function o(i,l){const{year:u}=n(new Date),{position:c}=e.value,f=[];for(let d=i;d<=l;d+=1){const h=[...Array(12).keys()].some(v=>r({month:v+1,year:d},{position:c}));f.push({year:d,id:d.toString(),label:d.toString(),ariaLabel:d.toString(),isActive:d===e.value.year,isCurrent:d===u,isDisabled:!h})}return f}const a={page:e,getMonthItems:s,getYearItems:o};return Pt(Ep,a),a}function Op(){const e=Pe(Ep);if(e)return e;throw new Error("Page context missing. Please verify this component is nested within a valid context provider.")}const LL={class:"vc-nav-header"},RL=["disabled"],NL=["disabled"],FL={class:"vc-nav-items"},YL=["data-id","aria-label","disabled","onClick","onKeydown"],BL=Ze({__name:"CalendarNav",setup(e){const{masks:t,move:n}=Sr(),{page:r,getMonthItems:s,getYearItems:o}=Op(),a=oe(!0),i=12,l=oe(r.value.year),u=oe(d(r.value.year)),c=oe(null);function f(){setTimeout(()=>{if(c.value==null)return;const Q=c.value.querySelector(".vc-nav-item:not(:disabled)");Q&&Q.focus()},10)}function d(Q){return Math.floor(Q/i)}function h(){a.value=!a.value}function v(Q){return Q*i}function m(Q){return i*(Q+1)-1}function p(){J.value&&(a.value&&S(),M())}function b(){ue.value&&(a.value&&T(),D())}function S(){l.value--}function T(){l.value++}function M(){u.value--}function D(){u.value++}const C=w(()=>s(l.value,t.value.navMonths).map(Q=>({...Q,click:()=>n({month:Q.month,year:Q.year},{position:r.value.position})}))),E=w(()=>s(l.value-1,t.value.navMonths)),P=w(()=>E.value.some(Q=>!Q.isDisabled)),$=w(()=>s(l.value+1,t.value.navMonths)),I=w(()=>$.value.some(Q=>!Q.isDisabled)),j=w(()=>o(v(u.value),m(u.value)).map(Q=>({...Q,click:()=>{l.value=Q.year,a.value=!0,f()}}))),O=w(()=>o(v(u.value-1),m(u.value-1))),W=w(()=>O.value.some(Q=>!Q.isDisabled)),re=w(()=>o(v(u.value+1),m(u.value+1))),X=w(()=>re.value.some(Q=>!Q.isDisabled)),ee=w(()=>a.value?C.value:j.value),J=w(()=>a.value?P.value:W.value),ue=w(()=>a.value?I.value:X.value),we=w(()=>zm(j.value.map(Q=>Q.year))),V=w(()=>Ar(j.value.map(Q=>Q.year))),fe=w(()=>a.value?l.value:`${we.value} - ${V.value}`);return zn(()=>{l.value=r.value.year,f()}),Te(()=>l.value,Q=>u.value=d(Q)),Gt(()=>f()),(Q,Le)=>(G(),ae("div",{class:"vc-nav-container",ref_key:"navContainer",ref:c},[me("div",LL,[me("button",{type:"button",class:"vc-nav-arrow is-left vc-focus",disabled:!A(J),onClick:p,onKeydown:Le[0]||(Le[0]=pe=>A(Ao)(pe,p))},[L(Rt,{name:"nav-prev-button",move:p,disabled:!A(J)},{default:Ee(()=>[L(ns,{name:"ChevronLeft",width:"22px",height:"24px"})]),_:1},8,["disabled"])],40,RL),me("button",{type:"button",class:"vc-nav-title vc-focus",onClick:h,onKeydown:Le[1]||(Le[1]=pe=>A(Ao)(pe,h))},Qe(A(fe)),33),me("button",{type:"button",class:"vc-nav-arrow is-right vc-focus",disabled:!A(ue),onClick:b,onKeydown:Le[2]||(Le[2]=pe=>A(Ao)(pe,b))},[L(Rt,{name:"nav-next-button",move:b,disabled:!A(ue)},{default:Ee(()=>[L(ns,{name:"ChevronRight",width:"22px",height:"24px"})]),_:1},8,["disabled"])],40,NL)]),me("div",FL,[(G(!0),ae(be,null,Ft(A(ee),pe=>(G(),ae("button",{key:pe.label,type:"button","data-id":pe.id,"aria-label":pe.ariaLabel,class:ke(["vc-nav-item vc-focus",[pe.isActive?"is-active":pe.isCurrent?"is-current":""]]),disabled:pe.isDisabled,onClick:pe.click,onKeydown:Ye=>A(Ao)(Ye,pe.click)},Qe(pe.label),43,YL))),128))])],512))}}),Mp=Ze({__name:"CalendarPageProvider",props:{page:null},setup(e){return IL(et(e,"page")),(n,r)=>so(n.$slots,"default")}}),HL=Ze({__name:"CalendarNavPopover",setup(e){const{navPopoverId:t,color:n,displayMode:r}=Sr();return(s,o)=>(G(),Ae(Ja,{id:A(t),class:ke(["vc-nav-popover-container",`vc-${A(n)}`,`vc-${A(r)}`])},{default:Ee(({data:a})=>[L(Mp,{page:a.page},{default:Ee(()=>[L(Rt,{name:"nav"},{default:Ee(()=>[L(BL)]),_:1})]),_:2},1032,["page"])]),_:1},8,["id","class"]))}}),jL=Ze({directives:{popover:pp},components:{CalendarSlot:Rt},props:{day:{type:Object,required:!0}},setup(e){const{locale:t,theme:n,attributeContext:r,dayPopoverId:s,onDayClick:o,onDayMouseenter:a,onDayMouseleave:i,onDayFocusin:l,onDayFocusout:u,onDayKeydown:c}=Sr(),f=w(()=>e.day),d=w(()=>r.value.getCells(f.value)),h=w(()=>d.value.map(X=>X.data)),v=w(()=>({...f.value,attributes:h.value,attributeCells:d.value}));function m({data:X},{popovers:ee}){const{key:J,customData:ue,popover:we}=X;if(!we)return;const V=ld({key:J,customData:ue,attribute:X},{...we},{visibility:we.label?"hover":"click",placement:"bottom",isInteractive:!we.label});ee.splice(0,0,V)}const p=w(()=>{const X={...n.value.prepareRender({}),popovers:[]};return d.value.forEach(ee=>{n.value.render(ee,X),m(ee,X)}),X}),b=w(()=>p.value.highlights),S=w(()=>!!mn(b.value)),T=w(()=>p.value.content),M=w(()=>p.value.dots),D=w(()=>!!mn(M.value)),C=w(()=>p.value.bars),E=w(()=>!!mn(C.value)),P=w(()=>p.value.popovers),$=w(()=>P.value.map(X=>X.attribute)),I=Cp("day-content"),j=w(()=>["vc-day",...f.value.classes,{"vc-day-box-center-center":!I},{"is-not-in-month":!e.day.inMonth}]),O=w(()=>{let X;f.value.isFocusable?X="0":X="-1";const ee=["vc-day-content vc-focusable vc-focus vc-attr",{"vc-disabled":f.value.isDisabled},ar(Ar(b.value),"contentClass"),ar(Ar(T.value),"class")||""],J={...ar(Ar(b.value),"contentStyle"),...ar(Ar(T.value),"style")};return{class:ee,style:J,tabindex:X,"aria-label":f.value.ariaLabel,"aria-disabled":!!f.value.isDisabled,role:"button"}}),W=w(()=>({click(X){o(v.value,X)},mouseenter(X){a(v.value,X)},mouseleave(X){i(v.value,X)},focusin(X){l(v.value,X)},focusout(X){u(v.value,X)},keydown(X){c(v.value,X)}})),re=w(()=>mn(P.value)?ld({id:s.value,data:{day:f,attributes:$.value}},...P.value):null);return{attributes:h,attributeCells:d,bars:C,dayClasses:j,dayContentProps:O,dayContentEvents:W,dayPopover:re,glyphs:p,dots:M,hasDots:D,hasBars:E,highlights:b,hasHighlights:S,locale:t,popovers:P}}}),VL={key:0,class:"vc-highlights vc-day-layer"},WL={key:1,class:"vc-day-layer vc-day-box-center-bottom"},UL={class:"vc-dots"},zL={key:2,class:"vc-day-layer vc-day-box-center-bottom"},KL={class:"vc-bars"};function GL(e,t,n,r,s,o){const a=vn("CalendarSlot"),i=Yy("popover");return G(),ae("div",{class:ke(e.dayClasses)},[e.hasHighlights?(G(),ae("div",VL,[(G(!0),ae(be,null,Ft(e.highlights,({key:l,wrapperClass:u,class:c,style:f})=>(G(),ae("div",{key:l,class:ke(u)},[me("div",{class:ke(c),style:pn(f)},null,6)],2))),128))])):We("",!0),L(a,{name:"day-content",day:e.day,attributes:e.attributes,"attribute-cells":e.attributeCells,dayProps:e.dayContentProps,dayEvents:e.dayContentEvents,locale:e.locale},{default:Ee(()=>[zl((G(),ae("div",qt(e.dayContentProps,By(e.dayContentEvents,!0)),[Kr(Qe(e.day.label),1)],16)),[[i,e.dayPopover]])]),_:1},8,["day","attributes","attribute-cells","dayProps","dayEvents","locale"]),e.hasDots?(G(),ae("div",WL,[me("div",UL,[(G(!0),ae(be,null,Ft(e.dots,({key:l,class:u,style:c})=>(G(),ae("span",{key:l,class:ke(u),style:pn(c)},null,6))),128))])])):We("",!0),e.hasBars?(G(),ae("div",zL,[me("div",KL,[(G(!0),ae(be,null,Ft(e.bars,({key:l,class:u,style:c})=>(G(),ae("span",{key:l,class:ke(u),style:pn(c)},null,6))),128))])])):We("",!0)],2)}const qL=qn(jL,[["render",GL]]),ZL={class:"vc-weekdays"},JL=["onClick"],XL={inheritAttrs:!1},QL=Ze({...XL,__name:"CalendarPage",setup(e){const{page:t}=Op(),{onWeeknumberClick:n}=Sr();return(r,s)=>(G(),ae("div",{class:ke(["vc-pane",`row-${A(t).row}`,`row-from-end-${A(t).rowFromEnd}`,`column-${A(t).column}`,`column-from-end-${A(t).columnFromEnd}`]),ref:"pane"},[L(Tp,{page:A(t),"is-lg":"","hide-arrows":""},null,8,["page"]),me("div",{class:ke(["vc-weeks",{[`vc-show-weeknumbers-${A(t).weeknumberPosition}`]:A(t).weeknumberPosition}])},[me("div",ZL,[(G(!0),ae(be,null,Ft(A(t).weekdays,({weekday:o,label:a},i)=>(G(),ae("div",{key:i,class:ke(`vc-weekday vc-weekday-${o}`)},Qe(a),3))),128))]),(G(!0),ae(be,null,Ft(A(t).viewWeeks,o=>(G(),ae("div",{key:`weeknumber-${o.weeknumber}`,class:"vc-week"},[A(t).weeknumberPosition?(G(),ae("div",{key:0,class:ke(["vc-weeknumber",`is-${A(t).weeknumberPosition}`])},[me("span",{class:ke(["vc-weeknumber-content"]),onClick:a=>A(n)(o,a)},Qe(o.weeknumberDisplay),9,JL)],2)):We("",!0),(G(!0),ae(be,null,Ft(o.days,a=>(G(),Ae(qL,{key:a.id,day:a},null,8,["day"]))),128))]))),128))],2)],2))}}),eR=Ze({components:{CalendarHeader:Tp,CalendarPage:QL,CalendarNavPopover:HL,CalendarDayPopover:sL,CalendarPageProvider:Mp,CalendarSlot:Rt},props:KI,emit:GI,setup(e,{emit:t,slots:n}){return qI(e,{emit:t,slots:n})}}),tR={class:"vc-pane-header-wrapper"};function nR(e,t,n,r,s,o){const a=vn("CalendarHeader"),i=vn("CalendarPage"),l=vn("CalendarSlot"),u=vn("CalendarPageProvider"),c=vn("CalendarDayPopover"),f=vn("CalendarNavPopover");return G(),ae(be,null,[me("div",qt({"data-helptext":"Press the arrow keys to navigate by day, Home and End to navigate to week ends, PageUp and PageDown to navigate by month, Alt+PageUp and Alt+PageDown to navigate by year"},e.$attrs,{class:["vc-container",`vc-${e.view}`,`vc-${e.color}`,`vc-${e.displayMode}`,{"vc-expanded":e.expanded,"vc-bordered":!e.borderless,"vc-transparent":e.transparent}],onMouseup:t[0]||(t[0]=v0(()=>{},["prevent"])),ref:"containerRef"}),[me("div",{class:ke(["vc-pane-container",{"in-transition":e.inTransition}])},[me("div",tR,[e.firstPage?(G(),Ae(a,{key:0,page:e.firstPage,"is-lg":"","hide-title":""},null,8,["page"])):We("",!0)]),L(uo,{name:`vc-${e.transitionName}`,onBeforeEnter:e.onTransitionBeforeEnter,onAfterEnter:e.onTransitionAfterEnter},{default:Ee(()=>[(G(),ae("div",{key:e.pages[0].id,class:"vc-pane-layout",style:pn({gridTemplateColumns:`repeat(${e.columns}, 1fr)`})},[(G(!0),ae(be,null,Ft(e.pages,d=>(G(),Ae(u,{key:d.id,page:d},{default:Ee(()=>[L(l,{name:"page",page:d},{default:Ee(()=>[L(i)]),_:2},1032,["page"])]),_:2},1032,["page"]))),128))],4))]),_:1},8,["name","onBeforeEnter","onAfterEnter"]),L(l,{name:"footer"})],2)],16),L(c),L(f)],64)}const xp=qn(eR,[["render",nR]]),kp=Symbol("__vc_date_picker_context__"),rR={...bp,mode:{type:String,default:"date"},modelValue:{type:[Number,String,Date,Object]},modelModifiers:{type:Object,default:()=>({})},rules:[String,Object],is24hr:Boolean,hideTimeHeader:Boolean,timeAccuracy:{type:Number,default:2},isRequired:Boolean,isRange:Boolean,updateOnInput:{type:Boolean,default:()=>jn("datePicker.updateOnInput")},inputDebounce:{type:Number,default:()=>jn("datePicker.inputDebounce")},popover:{type:[Boolean,Object],default:!0},dragAttribute:Object,selectAttribute:Object,attributes:[Object,Array]},sR=["update:modelValue","drag","dayclick","daykeydown","popover-will-show","popover-did-show","popover-will-hide","popover-did-hide"];function oR(e,{emit:t,slots:n}){Dp(n,{footer:"dp-footer"});const r=wp(e),{locale:s,masks:o,disabledAttribute:a}=r,i=oe(!1),l=oe(Symbol()),u=oe(null),c=oe(null),f=oe(["",""]),d=oe(null),h=oe(null);let v,m,p=!0;const b=w(()=>e.isRange||e.modelModifiers.range===!0),S=w(()=>b.value&&u.value!=null?u.value.start:null),T=w(()=>b.value&&u.value!=null?u.value.end:null),M=w(()=>e.mode.toLowerCase()==="date"),D=w(()=>e.mode.toLowerCase()==="datetime"),C=w(()=>e.mode.toLowerCase()==="time"),E=w(()=>!!c.value),P=w(()=>{let y="date";e.modelModifiers.number&&(y="number"),e.modelModifiers.string&&(y="string");const F=o.value.modelValue||"iso";return Le({type:y,mask:F})}),$=w(()=>K(c.value??u.value)),I=w(()=>C.value?e.is24hr?o.value.inputTime24hr:o.value.inputTime:D.value?e.is24hr?o.value.inputDateTime24hr:o.value.inputDateTime:o.value.input),j=w(()=>/[Hh]/g.test(I.value)),O=w(()=>/[dD]{1,2}|Do|W{1,4}|M{1,4}|YY(?:YY)?/g.test(I.value)),W=w(()=>{if(j.value&&O.value)return"dateTime";if(O.value)return"date";if(j.value)return"time"}),re=w(()=>{var y;const F=((y=d.value)==null?void 0:y.$el.previousElementSibling)??void 0;return ts({},e.popover,jn("datePicker.popover"),{target:F})}),X=w(()=>mp({...re.value,id:l.value})),ee=w(()=>b.value?{start:f.value[0],end:f.value[1]}:f.value[0]),J=w(()=>{const y=["start","end"].map(F=>({input:Y(F),change:R(F),keyup:H,...e.popover&&X.value}));return b.value?{start:y[0],end:y[1]}:y[0]}),ue=w(()=>{if(!ye(u.value))return null;const y={key:"select-drag",...e.selectAttribute,dates:u.value,pinPage:!0},{dot:F,bar:Z,highlight:he,content:He}=y;return!F&&!Z&&!he&&!He&&(y.highlight=!0),y}),we=w(()=>{if(!b.value||!ye(c.value))return null;const y={key:"select-drag",...e.dragAttribute,dates:c.value},{dot:F,bar:Z,highlight:he,content:He}=y;return!F&&!Z&&!he&&!He&&(y.highlight={startEnd:{fillMode:"outline"}}),y}),V=w(()=>{const y=Bt(e.attributes)?[...e.attributes]:[];return we.value?y.unshift(we.value):ue.value&&y.unshift(ue.value),y}),fe=w(()=>Le(e.rules==="auto"?Q():e.rules??{}));function Q(){const y={ms:[0,999],sec:[0,59],min:[0,59],hr:[0,23]},F=M.value?0:e.timeAccuracy;return[0,1].map(Z=>{switch(F){case 0:return{hours:y.hr[Z],minutes:y.min[Z],seconds:y.sec[Z],milliseconds:y.ms[Z]};case 1:return{minutes:y.min[Z],seconds:y.sec[Z],milliseconds:y.ms[Z]};case 3:return{milliseconds:y.ms[Z]};case 4:return{};default:return{seconds:y.sec[Z],milliseconds:y.ms[Z]}}})}function Le(y){return Bt(y)?y.length===1?[y[0],y[0]]:y:[y,y]}function pe(y){return Le(y).map((F,Z)=>({...F,rules:fe.value[Z]}))}function Ye(y){return y==null?!1:Kt(y)?!isNaN(y):Hr(y)?!isNaN(y.getTime()):rn(y)?y!=="":Pu(y)}function Re(y){return bn(y)&&"start"in y&&"end"in y&&Ye(y.start??null)&&Ye(y.end??null)}function ye(y){return Re(y)||Ye(y)}function ze(y,F){if(y==null&&F==null)return!0;if(y==null||F==null)return!1;const Z=Hr(y),he=Hr(F);return Z&&he?y.getTime()===F.getTime():Z||he?!1:ze(y.start,F.start)&&ze(y.end,F.end)}function tt(y){return!ye(y)||!a.value?!1:a.value.intersectsRange(s.value.range(y))}function lt(y,F,Z,he){if(!ye(y))return null;if(Re(y)){const He=s.value.toDate(y.start,{...F[0],fillDate:S.value??void 0,patch:Z}),ft=s.value.toDate(y.end,{...F[1],fillDate:T.value??void 0,patch:Z});return Vt({start:He,end:ft},he)}return s.value.toDateOrNull(y,{...F[0],fillDate:u.value,patch:Z})}function mt(y,F){return Re(y)?{start:s.value.fromDate(y.start,F[0]),end:s.value.fromDate(y.end,F[1])}:b.value?null:s.value.fromDate(y,F[0])}function ut(y,F={}){return clearTimeout(v),new Promise(Z=>{const{debounce:he=0,...He}=F;he>0?v=window.setTimeout(()=>{Z(g(y,He))},he):Z(g(y,He))})}function g(y,{config:F=P.value,patch:Z="dateTime",clearIfEqual:he=!1,formatInput:He=!0,hidePopover:ft=!1,dragging:$t=E.value,targetPriority:$r,moveToValue:Tr=!1}={}){const ai=pe(F);let pt=lt(y,ai,Z,$r);if(tt(pt)){if($t)return null;pt=u.value,ft=!1}else pt==null&&e.isRequired?pt=u.value:pt!=null&&ze(u.value,pt)&&he&&(pt=null);const yo=$t?c:u,ps=!ze(yo.value,pt);yo.value=pt,$t||(c.value=null);const gs=mt(pt,P.value);return ps&&(p=!1,t($t?"drag":"update:modelValue",gs),Ot(()=>p=!0)),ft&&!$t&&Be(),He&&_(),Tr&&Ot(()=>Xn($r??"start")),gs}function _(){Ot(()=>{const y=pe({type:"string",mask:I.value}),F=mt(c.value??u.value,y);b.value?f.value=[F&&F.start,F&&F.end]:f.value=[F,""]})}function x(y,F,Z){f.value.splice(F==="start"?0:1,1,y);const he=b.value?{start:f.value[0],end:f.value[1]||f.value[0]}:y,He={type:"string",mask:I.value};ut(he,{...Z,config:He,patch:W.value,targetPriority:F,moveToValue:!0})}function Y(y){return F=>{e.updateOnInput&&x(F.currentTarget.value,y,{formatInput:!1,hidePopover:!1,debounce:e.inputDebounce})}}function R(y){return F=>{x(F.currentTarget.value,y,{formatInput:!0,hidePopover:!1})}}function H(y){y.key==="Escape"&&ut(u.value,{formatInput:!0,hidePopover:!0})}function K(y){return b.value?[y&&y.start?s.value.getDateParts(y.start):null,y&&y.end?s.value.getDateParts(y.end):null]:[y?s.value.getDateParts(y):null]}function U(){c.value=null,_()}function z(y){t("popover-will-show",y)}function B(y){t("popover-did-show",y)}function q(y){U(),t("popover-will-hide",y)}function ne(y){t("popover-did-hide",y)}function te(y){const F={patch:"date",formatInput:!0,hidePopover:!0};if(b.value){const Z=!E.value;Z?m={start:y.startDate,end:y.endDate}:m!=null&&(m.end=y.date),ut(m,{...F,dragging:Z})}else ut(y.date,{...F,clearIfEqual:!e.isRequired})}function ie(y,F){te(y),t("dayclick",y,F)}function de(y,F){switch(F.key){case" ":case"Enter":{te(y),F.preventDefault();break}case"Escape":Be()}t("daykeydown",y,F)}function Ce(y,F){!E.value||m==null||(m.end=y.date,ut(Vt(m),{patch:"date",formatInput:!0}))}function _e(y={}){bl({...re.value,...y,isInteractive:!0,id:l.value})}function Be(y={}){Js({hideDelay:10,force:!0,...re.value,...y,id:l.value})}function ct(y){vp({...re.value,...y,isInteractive:!0,id:l.value})}function Vt(y,F){const{start:Z,end:he}=y;if(Z>he)switch(F){case"start":return{start:Z,end:Z};case"end":return{start:he,end:he};default:return{start:he,end:Z}}return{start:Z,end:he}}async function Jn(y,F={}){return h.value==null?!1:h.value.move(y,F)}async function fn(y,F={}){return h.value==null?!1:h.value.moveBy(y,F)}async function Xn(y,F={}){const Z=u.value;if(h.value==null||!ye(Z))return!1;const he=y!=="end",He=he?1:-1,ft=Re(Z)?he?Z.start:Z.end:Z,$t=Xm(ft,"monthly",s.value);return h.value.move($t,{position:He,...F})}Te(()=>e.isRange,y=>{y&&console.warn("The `is-range` prop will be deprecated in future releases. Please use the `range` modifier.")},{immediate:!0}),Te(()=>b.value,()=>{g(null,{formatInput:!0})}),Te(()=>I.value,()=>_()),Te(()=>e.modelValue,y=>{p&&g(y,{formatInput:!0,hidePopover:!1})}),Te(()=>fe.value,()=>{bn(e.rules)&&g(e.modelValue,{formatInput:!0,hidePopover:!1})}),Te(()=>e.timezone,()=>{g(u.value,{formatInput:!0})});const Je=Le(P.value);u.value=lt(e.modelValue??null,Je,"dateTime"),Gt(()=>{g(e.modelValue,{formatInput:!0,hidePopover:!1})}),Ot(()=>i.value=!0);const N={...r,showCalendar:i,datePickerPopoverId:l,popoverRef:d,popoverEvents:X,calendarRef:h,isRange:b,isTimeMode:C,isDateTimeMode:D,is24hr:et(e,"is24hr"),hideTimeHeader:et(e,"hideTimeHeader"),timeAccuracy:et(e,"timeAccuracy"),isDragging:E,inputValue:ee,inputEvents:J,dateParts:$,attributes:V,rules:fe,move:Jn,moveBy:fn,moveToValue:Xn,updateValue:ut,showPopover:_e,hidePopover:Be,togglePopover:ct,onDayClick:ie,onDayKeydown:de,onDayMouseEnter:Ce,onPopoverBeforeShow:z,onPopoverAfterShow:B,onPopoverBeforeHide:q,onPopoverAfterHide:ne};return Pt(kp,N),N}function Ru(){const e=Pe(kp);if(e)return e;throw new Error("DatePicker context missing. Please verify this component is nested within a valid context provider.")}const aR=[{value:0,label:"12"},{value:1,label:"1"},{value:2,label:"2"},{value:3,label:"3"},{value:4,label:"4"},{value:5,label:"5"},{value:6,label:"6"},{value:7,label:"7"},{value:8,label:"8"},{value:9,label:"9"},{value:10,label:"10"},{value:11,label:"11"}],iR=[{value:12,label:"12"},{value:13,label:"1"},{value:14,label:"2"},{value:15,label:"3"},{value:16,label:"4"},{value:17,label:"5"},{value:18,label:"6"},{value:19,label:"7"},{value:20,label:"8"},{value:21,label:"9"},{value:22,label:"10"},{value:23,label:"11"}];function lR(e){const t=Ru(),{locale:n,isRange:r,isTimeMode:s,dateParts:o,rules:a,is24hr:i,hideTimeHeader:l,timeAccuracy:u,updateValue:c}=t;function f(O){O=Object.assign(h.value,O);let W=null;if(r.value){const re=d.value?O:o.value[0],X=d.value?o.value[1]:O;W={start:re,end:X}}else W=O;c(W,{patch:"time",targetPriority:d.value?"start":"end",moveToValue:!0})}const d=w(()=>e.position===0),h=w(()=>o.value[e.position]||{isValid:!1}),v=w(()=>Pu(h.value)),m=w(()=>!!h.value.isValid),p=w(()=>!l.value&&m.value),b=w(()=>{if(!v.value)return null;let O=n.value.toDate(h.value);return h.value.hours===24&&(O=new Date(O.getTime()-1)),O}),S=w({get(){return h.value.hours},set(O){f({hours:O})}}),T=w({get(){return h.value.minutes},set(O){f({minutes:O})}}),M=w({get(){return h.value.seconds},set(O){f({seconds:O})}}),D=w({get(){return h.value.milliseconds},set(O){f({milliseconds:O})}}),C=w({get(){return h.value.hours<12},set(O){O=String(O).toLowerCase()=="true";let W=S.value;O&&W>=12?W-=12:!O&&W<12&&(W+=12),f({hours:W})}}),E=w(()=>OI(h.value,a.value[e.position])),P=w(()=>aR.filter(O=>E.value.hours.some(W=>W.value===O.value))),$=w(()=>iR.filter(O=>E.value.hours.some(W=>W.value===O.value))),I=w(()=>i.value?E.value.hours:C.value?P.value:$.value),j=w(()=>{const O=[];return mn(P.value)&&O.push({value:!0,label:"AM"}),mn($.value)&&O.push({value:!1,label:"PM"}),O});return{...t,showHeader:p,timeAccuracy:u,parts:h,isValid:m,date:b,hours:S,minutes:T,seconds:M,milliseconds:D,options:E,hourOptions:I,isAM:C,isAMOptions:j,is24hr:i}}const uR=["value"],cR=["value","disabled"],fR={key:1,class:"vc-base-sizer","aria-hidden":"true"},dR={inheritAttrs:!1},Cs=Ze({...dR,__name:"BaseSelect",props:{options:null,modelValue:null,alignRight:{type:Boolean},alignLeft:{type:Boolean},showIcon:{type:Boolean},fitContent:{type:Boolean}},emits:["update:modelValue"],setup(e){const t=e,n=w(()=>{const r=t.options.find(s=>s.value===t.modelValue);return r?.label});return(r,s)=>(G(),ae("div",{class:ke(["vc-base-select",{"vc-fit-content":e.fitContent,"vc-has-icon":e.showIcon}])},[me("select",qt(r.$attrs,{value:e.modelValue,class:["vc-focus",{"vc-align-right":e.alignRight,"vc-align-left":e.alignLeft}],onChange:s[0]||(s[0]=o=>r.$emit("update:modelValue",o.target.value))}),[(G(!0),ae(be,null,Ft(e.options,o=>(G(),ae("option",{key:o.value,value:o.value,disabled:o.disabled},Qe(o.label),9,cR))),128))],16,uR),e.showIcon?(G(),Ae(ns,{key:0,name:"ChevronDown",size:"18"})):We("",!0),e.fitContent?(G(),ae("div",fR,Qe(A(n)),1)):We("",!0)],2))}}),hR={key:0,class:"vc-time-header"},vR={class:"vc-time-weekday"},mR={class:"vc-time-month"},pR={class:"vc-time-day"},gR={class:"vc-time-year"},yR={class:"vc-time-select-group"},bR=me("span",{class:"vc-time-colon"},":",-1),wR=me("span",{class:"vc-time-colon"},":",-1),_R=me("span",{class:"vc-time-decimal"},".",-1),Nd=Ze({__name:"TimePicker",props:{position:null},setup(e,{expose:t}){const r=lR(e);t(r);const{locale:s,isValid:o,date:a,hours:i,minutes:l,seconds:u,milliseconds:c,options:f,hourOptions:d,isTimeMode:h,isAM:v,isAMOptions:m,is24hr:p,showHeader:b,timeAccuracy:S}=r;return(T,M)=>(G(),ae("div",{class:ke(["vc-time-picker",[{"vc-invalid":!A(o),"vc-attached":!A(h)}]])},[L(Rt,{name:"time-header"},{default:Ee(()=>[A(b)&&A(a)?(G(),ae("div",hR,[me("span",vR,Qe(A(s).formatDate(A(a),"WWW")),1),me("span",mR,Qe(A(s).formatDate(A(a),"MMM")),1),me("span",pR,Qe(A(s).formatDate(A(a),"D")),1),me("span",gR,Qe(A(s).formatDate(A(a),"YYYY")),1)])):We("",!0)]),_:1}),me("div",yR,[L(ns,{name:"Clock",size:"17"}),L(Cs,{modelValue:A(i),"onUpdate:modelValue":M[0]||(M[0]=D=>Se(i)?i.value=D:null),modelModifiers:{number:!0},options:A(d),class:"vc-time-select-hours","align-right":""},null,8,["modelValue","options"]),A(S)>1?(G(),ae(be,{key:0},[bR,L(Cs,{modelValue:A(l),"onUpdate:modelValue":M[1]||(M[1]=D=>Se(l)?l.value=D:null),modelModifiers:{number:!0},options:A(f).minutes,class:"vc-time-select-minutes","align-left":A(S)===2},null,8,["modelValue","options","align-left"])],64)):We("",!0),A(S)>2?(G(),ae(be,{key:1},[wR,L(Cs,{modelValue:A(u),"onUpdate:modelValue":M[2]||(M[2]=D=>Se(u)?u.value=D:null),modelModifiers:{number:!0},options:A(f).seconds,class:"vc-time-select-seconds","align-left":A(S)===3},null,8,["modelValue","options","align-left"])],64)):We("",!0),A(S)>3?(G(),ae(be,{key:2},[_R,L(Cs,{modelValue:A(c),"onUpdate:modelValue":M[3]||(M[3]=D=>Se(c)?c.value=D:null),modelModifiers:{number:!0},options:A(f).milliseconds,class:"vc-time-select-milliseconds","align-left":""},null,8,["modelValue","options"])],64)):We("",!0),A(p)?We("",!0):(G(),Ae(Cs,{key:3,modelValue:A(v),"onUpdate:modelValue":M[4]||(M[4]=D=>Se(v)?v.value=D:null),options:A(m)},null,8,["modelValue","options"]))])],2))}}),Pp=Ze({__name:"DatePickerBase",setup(e){const{attributes:t,calendarRef:n,color:r,displayMode:s,isDateTimeMode:o,isTimeMode:a,isRange:i,onDayClick:l,onDayMouseEnter:u,onDayKeydown:c}=Ru(),f=i.value?[0,1]:[0];return(d,h)=>A(a)?(G(),ae("div",{key:0,class:ke(`vc-container vc-bordered vc-${A(r)} vc-${A(s)}`)},[(G(!0),ae(be,null,Ft(A(f),v=>(G(),Ae(Nd,{key:v,position:v},null,8,["position"]))),128))],2)):(G(),Ae(xp,{key:1,attributes:A(t),ref_key:"calendarRef",ref:n,onDayclick:A(l),onDaymouseenter:A(u),onDaykeydown:A(c)},{footer:Ee(()=>[A(o)?(G(!0),ae(be,{key:0},Ft(A(f),v=>(G(),Ae(Nd,{key:v,position:v},null,8,["position"]))),128)):We("",!0),L(Rt,{name:"dp-footer"})]),_:1},8,["attributes","onDayclick","onDaymouseenter","onDaykeydown"]))}}),DR={inheritAttrs:!1},CR=Ze({...DR,__name:"DatePickerPopover",setup(e){const{datePickerPopoverId:t,color:n,displayMode:r,popoverRef:s,onPopoverBeforeShow:o,onPopoverAfterShow:a,onPopoverBeforeHide:i,onPopoverAfterHide:l}=Ru();return(u,c)=>(G(),Ae(Ja,{id:A(t),placement:"bottom-start",class:ke(`vc-date-picker-content vc-${A(n)} vc-${A(r)}`),ref_key:"popoverRef",ref:s,onBeforeShow:A(o),onAfterShow:A(a),onBeforeHide:A(i),onAfterHide:A(l)},{default:Ee(()=>[L(Pp,Rr(Xo(u.$attrs)),null,16)]),_:1},8,["id","class","onBeforeShow","onAfterShow","onBeforeHide","onAfterHide"]))}}),SR=Ze({inheritAttrs:!1,emits:sR,props:rR,components:{DatePickerBase:Pp,DatePickerPopover:CR},setup(e,t){const n=oR(e,t),r=je(Gm(n,"calendarRef","popoverRef"));return{...n,slotCtx:r}}});function $R(e,t,n,r,s,o){const a=vn("DatePickerPopover"),i=vn("DatePickerBase");return e.$slots.default?(G(),ae(be,{key:0},[so(e.$slots,"default",Rr(Xo(e.slotCtx))),L(a,Rr(Xo(e.$attrs)),null,16)],64)):(G(),Ae(i,Rr(qt({key:1},e.$attrs)),null,16))}const TR=qn(SR,[["render",$R]]),Fd=Object.freeze(Object.defineProperty({__proto__:null,Calendar:xp,DatePicker:TR,Popover:Ja,PopoverRow:$p},Symbol.toStringTag,{value:"Module"})),ER=(e,t={})=>{e.use(JA,t);const n=e.config.globalProperties.$VCalendar.componentPrefix;for(const r in Fd){const s=Fd[r];e.component(`${n}${r}`,s)}},OR={install:ER},mo=Symbol("eodash"),MR=()=>Br.value?.layers.toReversed(),Ap=async e=>{e=typeof e=="number"?`EPSG:${e}`:e,!(!e||la.includes(e))&&(la.push(e),await Br.value?.registerProjectionFromCode(e))},xR=async e=>{if(e=typeof e=="number"?`EPSG:${e}`:e,!e){Br.value?.setAttribute("projection","EPSG:3857");return}la.includes(e)||await Ap(e),e=Br.value?.getAttribute("projection")===e?"EPSG:3857":e,Br.value?.setAttribute("projection",e)},kR=Object.freeze(Object.defineProperty({__proto__:null,changeMapProjection:xR,getLayers:MR,registerProjection:Ap},Symbol.toStringTag,{value:"Module"}));function Ip(e,t){return function(){return e.apply(t,arguments)}}const{toString:PR}=Object.prototype,{getPrototypeOf:Nu}=Object,Xa=(e=>t=>{const n=PR.call(t);return e[n]||(e[n]=n.slice(8,-1).toLowerCase())})(Object.create(null)),Xt=e=>(e=e.toLowerCase(),t=>Xa(t)===e),Qa=e=>t=>typeof t===e,{isArray:vs}=Array,Xs=Qa("undefined");function AR(e){return e!==null&&!Xs(e)&&e.constructor!==null&&!Xs(e.constructor)&&Mt(e.constructor.isBuffer)&&e.constructor.isBuffer(e)}const Lp=Xt("ArrayBuffer");function IR(e){let t;return typeof ArrayBuffer<"u"&&ArrayBuffer.isView?t=ArrayBuffer.isView(e):t=e&&e.buffer&&Lp(e.buffer),t}const LR=Qa("string"),Mt=Qa("function"),Rp=Qa("number"),ei=e=>e!==null&&typeof e=="object",RR=e=>e===!0||e===!1,Uo=e=>{if(Xa(e)!=="object")return!1;const t=Nu(e);return(t===null||t===Object.prototype||Object.getPrototypeOf(t)===null)&&!(Symbol.toStringTag in e)&&!(Symbol.iterator in e)},NR=Xt("Date"),FR=Xt("File"),YR=Xt("Blob"),BR=Xt("FileList"),HR=e=>ei(e)&&Mt(e.pipe),jR=e=>{let t;return e&&(typeof FormData=="function"&&e instanceof FormData||Mt(e.append)&&((t=Xa(e))==="formdata"||t==="object"&&Mt(e.toString)&&e.toString()==="[object FormData]"))},VR=Xt("URLSearchParams"),[WR,UR,zR,KR]=["ReadableStream","Request","Response","Headers"].map(Xt),GR=e=>e.trim?e.trim():e.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,"");function po(e,t,{allOwnKeys:n=!1}={}){if(e===null||typeof e>"u")return;let r,s;if(typeof e!="object"&&(e=[e]),vs(e))for(r=0,s=e.length;r0;)if(s=n[r],t===s.toLowerCase())return s;return null}const ir=typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:global,Fp=e=>!Xs(e)&&e!==ir;function wl(){const{caseless:e}=Fp(this)&&this||{},t={},n=(r,s)=>{const o=e&&Np(t,s)||s;Uo(t[o])&&Uo(r)?t[o]=wl(t[o],r):Uo(r)?t[o]=wl({},r):vs(r)?t[o]=r.slice():t[o]=r};for(let r=0,s=arguments.length;r(po(t,(s,o)=>{n&&Mt(s)?e[o]=Ip(s,n):e[o]=s},{allOwnKeys:r}),e),ZR=e=>(e.charCodeAt(0)===65279&&(e=e.slice(1)),e),JR=(e,t,n,r)=>{e.prototype=Object.create(t.prototype,r),e.prototype.constructor=e,Object.defineProperty(e,"super",{value:t.prototype}),n&&Object.assign(e.prototype,n)},XR=(e,t,n,r)=>{let s,o,a;const i={};if(t=t||{},e==null)return t;do{for(s=Object.getOwnPropertyNames(e),o=s.length;o-- >0;)a=s[o],(!r||r(a,e,t))&&!i[a]&&(t[a]=e[a],i[a]=!0);e=n!==!1&&Nu(e)}while(e&&(!n||n(e,t))&&e!==Object.prototype);return t},QR=(e,t,n)=>{e=String(e),(n===void 0||n>e.length)&&(n=e.length),n-=t.length;const r=e.indexOf(t,n);return r!==-1&&r===n},eN=e=>{if(!e)return null;if(vs(e))return e;let t=e.length;if(!Rp(t))return null;const n=new Array(t);for(;t-- >0;)n[t]=e[t];return n},tN=(e=>t=>e&&t instanceof e)(typeof Uint8Array<"u"&&Nu(Uint8Array)),nN=(e,t)=>{const r=(e&&e[Symbol.iterator]).call(e);let s;for(;(s=r.next())&&!s.done;){const o=s.value;t.call(e,o[0],o[1])}},rN=(e,t)=>{let n;const r=[];for(;(n=e.exec(t))!==null;)r.push(n);return r},sN=Xt("HTMLFormElement"),oN=e=>e.toLowerCase().replace(/[-_\s]([a-z\d])(\w*)/g,function(n,r,s){return r.toUpperCase()+s}),Yd=(({hasOwnProperty:e})=>(t,n)=>e.call(t,n))(Object.prototype),aN=Xt("RegExp"),Yp=(e,t)=>{const n=Object.getOwnPropertyDescriptors(e),r={};po(n,(s,o)=>{let a;(a=t(s,o,e))!==!1&&(r[o]=a||s)}),Object.defineProperties(e,r)},iN=e=>{Yp(e,(t,n)=>{if(Mt(e)&&["arguments","caller","callee"].indexOf(n)!==-1)return!1;const r=e[n];if(Mt(r)){if(t.enumerable=!1,"writable"in t){t.writable=!1;return}t.set||(t.set=()=>{throw Error("Can not rewrite read-only method '"+n+"'")})}})},lN=(e,t)=>{const n={},r=s=>{s.forEach(o=>{n[o]=!0})};return vs(e)?r(e):r(String(e).split(t)),n},uN=()=>{},cN=(e,t)=>e!=null&&Number.isFinite(e=+e)?e:t,ki="abcdefghijklmnopqrstuvwxyz",Bd="0123456789",Bp={DIGIT:Bd,ALPHA:ki,ALPHA_DIGIT:ki+ki.toUpperCase()+Bd},fN=(e=16,t=Bp.ALPHA_DIGIT)=>{let n="";const{length:r}=t;for(;e--;)n+=t[Math.random()*r|0];return n};function dN(e){return!!(e&&Mt(e.append)&&e[Symbol.toStringTag]==="FormData"&&e[Symbol.iterator])}const hN=e=>{const t=new Array(10),n=(r,s)=>{if(ei(r)){if(t.indexOf(r)>=0)return;if(!("toJSON"in r)){t[s]=r;const o=vs(r)?[]:{};return po(r,(a,i)=>{const l=n(a,s+1);!Xs(l)&&(o[i]=l)}),t[s]=void 0,o}}return r};return n(e,0)},vN=Xt("AsyncFunction"),mN=e=>e&&(ei(e)||Mt(e))&&Mt(e.then)&&Mt(e.catch),Hp=((e,t)=>e?setImmediate:t?((n,r)=>(ir.addEventListener("message",({source:s,data:o})=>{s===ir&&o===n&&r.length&&r.shift()()},!1),s=>{r.push(s),ir.postMessage(n,"*")}))(`axios@${Math.random()}`,[]):n=>setTimeout(n))(typeof setImmediate=="function",Mt(ir.postMessage)),pN=typeof queueMicrotask<"u"?queueMicrotask.bind(ir):typeof process<"u"&&process.nextTick||Hp,k={isArray:vs,isArrayBuffer:Lp,isBuffer:AR,isFormData:jR,isArrayBufferView:IR,isString:LR,isNumber:Rp,isBoolean:RR,isObject:ei,isPlainObject:Uo,isReadableStream:WR,isRequest:UR,isResponse:zR,isHeaders:KR,isUndefined:Xs,isDate:NR,isFile:FR,isBlob:YR,isRegExp:aN,isFunction:Mt,isStream:HR,isURLSearchParams:VR,isTypedArray:tN,isFileList:BR,forEach:po,merge:wl,extend:qR,trim:GR,stripBOM:ZR,inherits:JR,toFlatObject:XR,kindOf:Xa,kindOfTest:Xt,endsWith:QR,toArray:eN,forEachEntry:nN,matchAll:rN,isHTMLForm:sN,hasOwnProperty:Yd,hasOwnProp:Yd,reduceDescriptors:Yp,freezeMethods:iN,toObjectSet:lN,toCamelCase:oN,noop:uN,toFiniteNumber:cN,findKey:Np,global:ir,isContextDefined:Fp,ALPHABET:Bp,generateString:fN,isSpecCompliantForm:dN,toJSONObject:hN,isAsyncFn:vN,isThenable:mN,setImmediate:Hp,asap:pN};function ve(e,t,n,r,s){Error.call(this),Error.captureStackTrace?Error.captureStackTrace(this,this.constructor):this.stack=new Error().stack,this.message=e,this.name="AxiosError",t&&(this.code=t),n&&(this.config=n),r&&(this.request=r),s&&(this.response=s)}k.inherits(ve,Error,{toJSON:function(){return{message:this.message,name:this.name,description:this.description,number:this.number,fileName:this.fileName,lineNumber:this.lineNumber,columnNumber:this.columnNumber,stack:this.stack,config:k.toJSONObject(this.config),code:this.code,status:this.response&&this.response.status?this.response.status:null}}});const jp=ve.prototype,Vp={};["ERR_BAD_OPTION_VALUE","ERR_BAD_OPTION","ECONNABORTED","ETIMEDOUT","ERR_NETWORK","ERR_FR_TOO_MANY_REDIRECTS","ERR_DEPRECATED","ERR_BAD_RESPONSE","ERR_BAD_REQUEST","ERR_CANCELED","ERR_NOT_SUPPORT","ERR_INVALID_URL"].forEach(e=>{Vp[e]={value:e}});Object.defineProperties(ve,Vp);Object.defineProperty(jp,"isAxiosError",{value:!0});ve.from=(e,t,n,r,s,o)=>{const a=Object.create(jp);return k.toFlatObject(e,a,function(l){return l!==Error.prototype},i=>i!=="isAxiosError"),ve.call(a,e.message,t,n,r,s),a.cause=e,a.name=e.name,o&&Object.assign(a,o),a};const gN=null;function _l(e){return k.isPlainObject(e)||k.isArray(e)}function Wp(e){return k.endsWith(e,"[]")?e.slice(0,-2):e}function Hd(e,t,n){return e?e.concat(t).map(function(s,o){return s=Wp(s),!n&&o?"["+s+"]":s}).join(n?".":""):t}function yN(e){return k.isArray(e)&&!e.some(_l)}const bN=k.toFlatObject(k,{},null,function(t){return/^is[A-Z]/.test(t)});function ti(e,t,n){if(!k.isObject(e))throw new TypeError("target must be an object");t=t||new FormData,n=k.toFlatObject(n,{metaTokens:!0,dots:!1,indexes:!1},!1,function(m,p){return!k.isUndefined(p[m])});const r=n.metaTokens,s=n.visitor||c,o=n.dots,a=n.indexes,l=(n.Blob||typeof Blob<"u"&&Blob)&&k.isSpecCompliantForm(t);if(!k.isFunction(s))throw new TypeError("visitor must be a function");function u(v){if(v===null)return"";if(k.isDate(v))return v.toISOString();if(!l&&k.isBlob(v))throw new ve("Blob is not supported. Use a Buffer instead.");return k.isArrayBuffer(v)||k.isTypedArray(v)?l&&typeof Blob=="function"?new Blob([v]):Buffer.from(v):v}function c(v,m,p){let b=v;if(v&&!p&&typeof v=="object"){if(k.endsWith(m,"{}"))m=r?m:m.slice(0,-2),v=JSON.stringify(v);else if(k.isArray(v)&&yN(v)||(k.isFileList(v)||k.endsWith(m,"[]"))&&(b=k.toArray(v)))return m=Wp(m),b.forEach(function(T,M){!(k.isUndefined(T)||T===null)&&t.append(a===!0?Hd([m],M,o):a===null?m:m+"[]",u(T))}),!1}return _l(v)?!0:(t.append(Hd(p,m,o),u(v)),!1)}const f=[],d=Object.assign(bN,{defaultVisitor:c,convertValue:u,isVisitable:_l});function h(v,m){if(!k.isUndefined(v)){if(f.indexOf(v)!==-1)throw Error("Circular reference detected in "+m.join("."));f.push(v),k.forEach(v,function(b,S){(!(k.isUndefined(b)||b===null)&&s.call(t,b,k.isString(S)?S.trim():S,m,d))===!0&&h(b,m?m.concat(S):[S])}),f.pop()}}if(!k.isObject(e))throw new TypeError("data must be an object");return h(e),t}function jd(e){const t={"!":"%21","'":"%27","(":"%28",")":"%29","~":"%7E","%20":"+","%00":"\0"};return encodeURIComponent(e).replace(/[!'()~]|%20|%00/g,function(r){return t[r]})}function Fu(e,t){this._pairs=[],e&&ti(e,this,t)}const Up=Fu.prototype;Up.append=function(t,n){this._pairs.push([t,n])};Up.toString=function(t){const n=t?function(r){return t.call(this,r,jd)}:jd;return this._pairs.map(function(s){return n(s[0])+"="+n(s[1])},"").join("&")};function wN(e){return encodeURIComponent(e).replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%20/g,"+").replace(/%5B/gi,"[").replace(/%5D/gi,"]")}function zp(e,t,n){if(!t)return e;const r=n&&n.encode||wN,s=n&&n.serialize;let o;if(s?o=s(t,n):o=k.isURLSearchParams(t)?t.toString():new Fu(t,n).toString(r),o){const a=e.indexOf("#");a!==-1&&(e=e.slice(0,a)),e+=(e.indexOf("?")===-1?"?":"&")+o}return e}class Vd{constructor(){this.handlers=[]}use(t,n,r){return this.handlers.push({fulfilled:t,rejected:n,synchronous:r?r.synchronous:!1,runWhen:r?r.runWhen:null}),this.handlers.length-1}eject(t){this.handlers[t]&&(this.handlers[t]=null)}clear(){this.handlers&&(this.handlers=[])}forEach(t){k.forEach(this.handlers,function(r){r!==null&&t(r)})}}const Kp={silentJSONParsing:!0,forcedJSONParsing:!0,clarifyTimeoutError:!1},_N=typeof URLSearchParams<"u"?URLSearchParams:Fu,DN=typeof FormData<"u"?FormData:null,CN=typeof Blob<"u"?Blob:null,SN={isBrowser:!0,classes:{URLSearchParams:_N,FormData:DN,Blob:CN},protocols:["http","https","file","blob","url","data"]},Yu=typeof window<"u"&&typeof document<"u",$N=(e=>Yu&&["ReactNative","NativeScript","NS"].indexOf(e)<0)(typeof navigator<"u"&&navigator.product),TN=typeof WorkerGlobalScope<"u"&&self instanceof WorkerGlobalScope&&typeof self.importScripts=="function",EN=Yu&&window.location.href||"http://localhost",ON=Object.freeze(Object.defineProperty({__proto__:null,hasBrowserEnv:Yu,hasStandardBrowserEnv:$N,hasStandardBrowserWebWorkerEnv:TN,origin:EN},Symbol.toStringTag,{value:"Module"})),zt={...ON,...SN};function MN(e,t){return ti(e,new zt.classes.URLSearchParams,Object.assign({visitor:function(n,r,s,o){return zt.isNode&&k.isBuffer(n)?(this.append(r,n.toString("base64")),!1):o.defaultVisitor.apply(this,arguments)}},t))}function xN(e){return k.matchAll(/\w+|\[(\w*)]/g,e).map(t=>t[0]==="[]"?"":t[1]||t[0])}function kN(e){const t={},n=Object.keys(e);let r;const s=n.length;let o;for(r=0;r=n.length;return a=!a&&k.isArray(s)?s.length:a,l?(k.hasOwnProp(s,a)?s[a]=[s[a],r]:s[a]=r,!i):((!s[a]||!k.isObject(s[a]))&&(s[a]=[]),t(n,r,s[a],o)&&k.isArray(s[a])&&(s[a]=kN(s[a])),!i)}if(k.isFormData(e)&&k.isFunction(e.entries)){const n={};return k.forEachEntry(e,(r,s)=>{t(xN(r),s,n,0)}),n}return null}function PN(e,t,n){if(k.isString(e))try{return(t||JSON.parse)(e),k.trim(e)}catch(r){if(r.name!=="SyntaxError")throw r}return(n||JSON.stringify)(e)}const go={transitional:Kp,adapter:["xhr","http","fetch"],transformRequest:[function(t,n){const r=n.getContentType()||"",s=r.indexOf("application/json")>-1,o=k.isObject(t);if(o&&k.isHTMLForm(t)&&(t=new FormData(t)),k.isFormData(t))return s?JSON.stringify(Gp(t)):t;if(k.isArrayBuffer(t)||k.isBuffer(t)||k.isStream(t)||k.isFile(t)||k.isBlob(t)||k.isReadableStream(t))return t;if(k.isArrayBufferView(t))return t.buffer;if(k.isURLSearchParams(t))return n.setContentType("application/x-www-form-urlencoded;charset=utf-8",!1),t.toString();let i;if(o){if(r.indexOf("application/x-www-form-urlencoded")>-1)return MN(t,this.formSerializer).toString();if((i=k.isFileList(t))||r.indexOf("multipart/form-data")>-1){const l=this.env&&this.env.FormData;return ti(i?{"files[]":t}:t,l&&new l,this.formSerializer)}}return o||s?(n.setContentType("application/json",!1),PN(t)):t}],transformResponse:[function(t){const n=this.transitional||go.transitional,r=n&&n.forcedJSONParsing,s=this.responseType==="json";if(k.isResponse(t)||k.isReadableStream(t))return t;if(t&&k.isString(t)&&(r&&!this.responseType||s)){const a=!(n&&n.silentJSONParsing)&&s;try{return JSON.parse(t)}catch(i){if(a)throw i.name==="SyntaxError"?ve.from(i,ve.ERR_BAD_RESPONSE,this,null,this.response):i}}return t}],timeout:0,xsrfCookieName:"XSRF-TOKEN",xsrfHeaderName:"X-XSRF-TOKEN",maxContentLength:-1,maxBodyLength:-1,env:{FormData:zt.classes.FormData,Blob:zt.classes.Blob},validateStatus:function(t){return t>=200&&t<300},headers:{common:{Accept:"application/json, text/plain, */*","Content-Type":void 0}}};k.forEach(["delete","get","head","post","put","patch"],e=>{go.headers[e]={}});const AN=k.toObjectSet(["age","authorization","content-length","content-type","etag","expires","from","host","if-modified-since","if-unmodified-since","last-modified","location","max-forwards","proxy-authorization","referer","retry-after","user-agent"]),IN=e=>{const t={};let n,r,s;return e&&e.split(` -`).forEach(function(a){s=a.indexOf(":"),n=a.substring(0,s).trim().toLowerCase(),r=a.substring(s+1).trim(),!(!n||t[n]&&AN[n])&&(n==="set-cookie"?t[n]?t[n].push(r):t[n]=[r]:t[n]=t[n]?t[n]+", "+r:r)}),t},Wd=Symbol("internals");function Ss(e){return e&&String(e).trim().toLowerCase()}function zo(e){return e===!1||e==null?e:k.isArray(e)?e.map(zo):String(e)}function LN(e){const t=Object.create(null),n=/([^\s,;=]+)\s*(?:=\s*([^,;]+))?/g;let r;for(;r=n.exec(e);)t[r[1]]=r[2];return t}const RN=e=>/^[-_a-zA-Z0-9^`|~,!#$%&'*+.]+$/.test(e.trim());function Pi(e,t,n,r,s){if(k.isFunction(r))return r.call(this,t,n);if(s&&(t=n),!!k.isString(t)){if(k.isString(r))return t.indexOf(r)!==-1;if(k.isRegExp(r))return r.test(t)}}function NN(e){return e.trim().toLowerCase().replace(/([a-z\d])(\w*)/g,(t,n,r)=>n.toUpperCase()+r)}function FN(e,t){const n=k.toCamelCase(" "+t);["get","set","has"].forEach(r=>{Object.defineProperty(e,r+n,{value:function(s,o,a){return this[r].call(this,t,s,o,a)},configurable:!0})})}class Dt{constructor(t){t&&this.set(t)}set(t,n,r){const s=this;function o(i,l,u){const c=Ss(l);if(!c)throw new Error("header name must be a non-empty string");const f=k.findKey(s,c);(!f||s[f]===void 0||u===!0||u===void 0&&s[f]!==!1)&&(s[f||l]=zo(i))}const a=(i,l)=>k.forEach(i,(u,c)=>o(u,c,l));if(k.isPlainObject(t)||t instanceof this.constructor)a(t,n);else if(k.isString(t)&&(t=t.trim())&&!RN(t))a(IN(t),n);else if(k.isHeaders(t))for(const[i,l]of t.entries())o(l,i,r);else t!=null&&o(n,t,r);return this}get(t,n){if(t=Ss(t),t){const r=k.findKey(this,t);if(r){const s=this[r];if(!n)return s;if(n===!0)return LN(s);if(k.isFunction(n))return n.call(this,s,r);if(k.isRegExp(n))return n.exec(s);throw new TypeError("parser must be boolean|regexp|function")}}}has(t,n){if(t=Ss(t),t){const r=k.findKey(this,t);return!!(r&&this[r]!==void 0&&(!n||Pi(this,this[r],r,n)))}return!1}delete(t,n){const r=this;let s=!1;function o(a){if(a=Ss(a),a){const i=k.findKey(r,a);i&&(!n||Pi(r,r[i],i,n))&&(delete r[i],s=!0)}}return k.isArray(t)?t.forEach(o):o(t),s}clear(t){const n=Object.keys(this);let r=n.length,s=!1;for(;r--;){const o=n[r];(!t||Pi(this,this[o],o,t,!0))&&(delete this[o],s=!0)}return s}normalize(t){const n=this,r={};return k.forEach(this,(s,o)=>{const a=k.findKey(r,o);if(a){n[a]=zo(s),delete n[o];return}const i=t?NN(o):String(o).trim();i!==o&&delete n[o],n[i]=zo(s),r[i]=!0}),this}concat(...t){return this.constructor.concat(this,...t)}toJSON(t){const n=Object.create(null);return k.forEach(this,(r,s)=>{r!=null&&r!==!1&&(n[s]=t&&k.isArray(r)?r.join(", "):r)}),n}[Symbol.iterator](){return Object.entries(this.toJSON())[Symbol.iterator]()}toString(){return Object.entries(this.toJSON()).map(([t,n])=>t+": "+n).join(` -`)}get[Symbol.toStringTag](){return"AxiosHeaders"}static from(t){return t instanceof this?t:new this(t)}static concat(t,...n){const r=new this(t);return n.forEach(s=>r.set(s)),r}static accessor(t){const r=(this[Wd]=this[Wd]={accessors:{}}).accessors,s=this.prototype;function o(a){const i=Ss(a);r[i]||(FN(s,a),r[i]=!0)}return k.isArray(t)?t.forEach(o):o(t),this}}Dt.accessor(["Content-Type","Content-Length","Accept","Accept-Encoding","User-Agent","Authorization"]);k.reduceDescriptors(Dt.prototype,({value:e},t)=>{let n=t[0].toUpperCase()+t.slice(1);return{get:()=>e,set(r){this[n]=r}}});k.freezeMethods(Dt);function Ai(e,t){const n=this||go,r=t||n,s=Dt.from(r.headers);let o=r.data;return k.forEach(e,function(i){o=i.call(n,o,s.normalize(),t?t.status:void 0)}),s.normalize(),o}function qp(e){return!!(e&&e.__CANCEL__)}function ms(e,t,n){ve.call(this,e??"canceled",ve.ERR_CANCELED,t,n),this.name="CanceledError"}k.inherits(ms,ve,{__CANCEL__:!0});function Zp(e,t,n){const r=n.config.validateStatus;!n.status||!r||r(n.status)?e(n):t(new ve("Request failed with status code "+n.status,[ve.ERR_BAD_REQUEST,ve.ERR_BAD_RESPONSE][Math.floor(n.status/100)-4],n.config,n.request,n))}function YN(e){const t=/^([-+\w]{1,25})(:?\/\/|:)/.exec(e);return t&&t[1]||""}function BN(e,t){e=e||10;const n=new Array(e),r=new Array(e);let s=0,o=0,a;return t=t!==void 0?t:1e3,function(l){const u=Date.now(),c=r[o];a||(a=u),n[s]=l,r[s]=u;let f=o,d=0;for(;f!==s;)d+=n[f++],f=f%e;if(s=(s+1)%e,s===o&&(o=(o+1)%e),u-a{n=c,s=null,o&&(clearTimeout(o),o=null),e.apply(null,u)};return[(...u)=>{const c=Date.now(),f=c-n;f>=r?a(u,c):(s=u,o||(o=setTimeout(()=>{o=null,a(s)},r-f)))},()=>s&&a(s)]}const wa=(e,t,n=3)=>{let r=0;const s=BN(50,250);return HN(o=>{const a=o.loaded,i=o.lengthComputable?o.total:void 0,l=a-r,u=s(l),c=a<=i;r=a;const f={loaded:a,total:i,progress:i?a/i:void 0,bytes:l,rate:u||void 0,estimated:u&&i&&c?(i-a)/u:void 0,event:o,lengthComputable:i!=null,[t?"download":"upload"]:!0};e(f)},n)},Ud=(e,t)=>{const n=e!=null;return[r=>t[0]({lengthComputable:n,total:e,loaded:r}),t[1]]},zd=e=>(...t)=>k.asap(()=>e(...t)),jN=zt.hasStandardBrowserEnv?function(){const t=/(msie|trident)/i.test(navigator.userAgent),n=document.createElement("a");let r;function s(o){let a=o;return t&&(n.setAttribute("href",a),a=n.href),n.setAttribute("href",a),{href:n.href,protocol:n.protocol?n.protocol.replace(/:$/,""):"",host:n.host,search:n.search?n.search.replace(/^\?/,""):"",hash:n.hash?n.hash.replace(/^#/,""):"",hostname:n.hostname,port:n.port,pathname:n.pathname.charAt(0)==="/"?n.pathname:"/"+n.pathname}}return r=s(window.location.href),function(a){const i=k.isString(a)?s(a):a;return i.protocol===r.protocol&&i.host===r.host}}():function(){return function(){return!0}}(),VN=zt.hasStandardBrowserEnv?{write(e,t,n,r,s,o){const a=[e+"="+encodeURIComponent(t)];k.isNumber(n)&&a.push("expires="+new Date(n).toGMTString()),k.isString(r)&&a.push("path="+r),k.isString(s)&&a.push("domain="+s),o===!0&&a.push("secure"),document.cookie=a.join("; ")},read(e){const t=document.cookie.match(new RegExp("(^|;\\s*)("+e+")=([^;]*)"));return t?decodeURIComponent(t[3]):null},remove(e){this.write(e,"",Date.now()-864e5)}}:{write(){},read(){return null},remove(){}};function WN(e){return/^([a-z][a-z\d+\-.]*:)?\/\//i.test(e)}function UN(e,t){return t?e.replace(/\/?\/$/,"")+"/"+t.replace(/^\/+/,""):e}function Jp(e,t){return e&&!WN(t)?UN(e,t):t}const Kd=e=>e instanceof Dt?{...e}:e;function gr(e,t){t=t||{};const n={};function r(u,c,f){return k.isPlainObject(u)&&k.isPlainObject(c)?k.merge.call({caseless:f},u,c):k.isPlainObject(c)?k.merge({},c):k.isArray(c)?c.slice():c}function s(u,c,f){if(k.isUndefined(c)){if(!k.isUndefined(u))return r(void 0,u,f)}else return r(u,c,f)}function o(u,c){if(!k.isUndefined(c))return r(void 0,c)}function a(u,c){if(k.isUndefined(c)){if(!k.isUndefined(u))return r(void 0,u)}else return r(void 0,c)}function i(u,c,f){if(f in t)return r(u,c);if(f in e)return r(void 0,u)}const l={url:o,method:o,data:o,baseURL:a,transformRequest:a,transformResponse:a,paramsSerializer:a,timeout:a,timeoutMessage:a,withCredentials:a,withXSRFToken:a,adapter:a,responseType:a,xsrfCookieName:a,xsrfHeaderName:a,onUploadProgress:a,onDownloadProgress:a,decompress:a,maxContentLength:a,maxBodyLength:a,beforeRedirect:a,transport:a,httpAgent:a,httpsAgent:a,cancelToken:a,socketPath:a,responseEncoding:a,validateStatus:i,headers:(u,c)=>s(Kd(u),Kd(c),!0)};return k.forEach(Object.keys(Object.assign({},e,t)),function(c){const f=l[c]||s,d=f(e[c],t[c],c);k.isUndefined(d)&&f!==i||(n[c]=d)}),n}const Xp=e=>{const t=gr({},e);let{data:n,withXSRFToken:r,xsrfHeaderName:s,xsrfCookieName:o,headers:a,auth:i}=t;t.headers=a=Dt.from(a),t.url=zp(Jp(t.baseURL,t.url),e.params,e.paramsSerializer),i&&a.set("Authorization","Basic "+btoa((i.username||"")+":"+(i.password?unescape(encodeURIComponent(i.password)):"")));let l;if(k.isFormData(n)){if(zt.hasStandardBrowserEnv||zt.hasStandardBrowserWebWorkerEnv)a.setContentType(void 0);else if((l=a.getContentType())!==!1){const[u,...c]=l?l.split(";").map(f=>f.trim()).filter(Boolean):[];a.setContentType([u||"multipart/form-data",...c].join("; "))}}if(zt.hasStandardBrowserEnv&&(r&&k.isFunction(r)&&(r=r(t)),r||r!==!1&&jN(t.url))){const u=s&&o&&VN.read(o);u&&a.set(s,u)}return t},zN=typeof XMLHttpRequest<"u",KN=zN&&function(e){return new Promise(function(n,r){const s=Xp(e);let o=s.data;const a=Dt.from(s.headers).normalize();let{responseType:i,onUploadProgress:l,onDownloadProgress:u}=s,c,f,d,h,v;function m(){h&&h(),v&&v(),s.cancelToken&&s.cancelToken.unsubscribe(c),s.signal&&s.signal.removeEventListener("abort",c)}let p=new XMLHttpRequest;p.open(s.method.toUpperCase(),s.url,!0),p.timeout=s.timeout;function b(){if(!p)return;const T=Dt.from("getAllResponseHeaders"in p&&p.getAllResponseHeaders()),D={data:!i||i==="text"||i==="json"?p.responseText:p.response,status:p.status,statusText:p.statusText,headers:T,config:e,request:p};Zp(function(E){n(E),m()},function(E){r(E),m()},D),p=null}"onloadend"in p?p.onloadend=b:p.onreadystatechange=function(){!p||p.readyState!==4||p.status===0&&!(p.responseURL&&p.responseURL.indexOf("file:")===0)||setTimeout(b)},p.onabort=function(){p&&(r(new ve("Request aborted",ve.ECONNABORTED,e,p)),p=null)},p.onerror=function(){r(new ve("Network Error",ve.ERR_NETWORK,e,p)),p=null},p.ontimeout=function(){let M=s.timeout?"timeout of "+s.timeout+"ms exceeded":"timeout exceeded";const D=s.transitional||Kp;s.timeoutErrorMessage&&(M=s.timeoutErrorMessage),r(new ve(M,D.clarifyTimeoutError?ve.ETIMEDOUT:ve.ECONNABORTED,e,p)),p=null},o===void 0&&a.setContentType(null),"setRequestHeader"in p&&k.forEach(a.toJSON(),function(M,D){p.setRequestHeader(D,M)}),k.isUndefined(s.withCredentials)||(p.withCredentials=!!s.withCredentials),i&&i!=="json"&&(p.responseType=s.responseType),u&&([d,v]=wa(u,!0),p.addEventListener("progress",d)),l&&p.upload&&([f,h]=wa(l),p.upload.addEventListener("progress",f),p.upload.addEventListener("loadend",h)),(s.cancelToken||s.signal)&&(c=T=>{p&&(r(!T||T.type?new ms(null,e,p):T),p.abort(),p=null)},s.cancelToken&&s.cancelToken.subscribe(c),s.signal&&(s.signal.aborted?c():s.signal.addEventListener("abort",c)));const S=YN(s.url);if(S&&zt.protocols.indexOf(S)===-1){r(new ve("Unsupported protocol "+S+":",ve.ERR_BAD_REQUEST,e));return}p.send(o||null)})},GN=(e,t)=>{let n=new AbortController,r;const s=function(l){if(!r){r=!0,a();const u=l instanceof Error?l:this.reason;n.abort(u instanceof ve?u:new ms(u instanceof Error?u.message:u))}};let o=t&&setTimeout(()=>{s(new ve(`timeout ${t} of ms exceeded`,ve.ETIMEDOUT))},t);const a=()=>{e&&(o&&clearTimeout(o),o=null,e.forEach(l=>{l&&(l.removeEventListener?l.removeEventListener("abort",s):l.unsubscribe(s))}),e=null)};e.forEach(l=>l&&l.addEventListener&&l.addEventListener("abort",s));const{signal:i}=n;return i.unsubscribe=a,[i,()=>{o&&clearTimeout(o),o=null}]},qN=function*(e,t){let n=e.byteLength;if(!t||n{const o=ZN(e,t,s);let a=0,i,l=u=>{i||(i=!0,r&&r(u))};return new ReadableStream({async pull(u){try{const{done:c,value:f}=await o.next();if(c){l(),u.close();return}let d=f.byteLength;if(n){let h=a+=d;n(h)}u.enqueue(new Uint8Array(f))}catch(c){throw l(c),c}},cancel(u){return l(u),o.return()}},{highWaterMark:2})},ni=typeof fetch=="function"&&typeof Request=="function"&&typeof Response=="function",Qp=ni&&typeof ReadableStream=="function",Dl=ni&&(typeof TextEncoder=="function"?(e=>t=>e.encode(t))(new TextEncoder):async e=>new Uint8Array(await new Response(e).arrayBuffer())),eg=(e,...t)=>{try{return!!e(...t)}catch{return!1}},JN=Qp&&eg(()=>{let e=!1;const t=new Request(zt.origin,{body:new ReadableStream,method:"POST",get duplex(){return e=!0,"half"}}).headers.has("Content-Type");return e&&!t}),qd=64*1024,Cl=Qp&&eg(()=>k.isReadableStream(new Response("").body)),_a={stream:Cl&&(e=>e.body)};ni&&(e=>{["text","arrayBuffer","blob","formData","stream"].forEach(t=>{!_a[t]&&(_a[t]=k.isFunction(e[t])?n=>n[t]():(n,r)=>{throw new ve(`Response type '${t}' is not supported`,ve.ERR_NOT_SUPPORT,r)})})})(new Response);const XN=async e=>{if(e==null)return 0;if(k.isBlob(e))return e.size;if(k.isSpecCompliantForm(e))return(await new Request(e).arrayBuffer()).byteLength;if(k.isArrayBufferView(e)||k.isArrayBuffer(e))return e.byteLength;if(k.isURLSearchParams(e)&&(e=e+""),k.isString(e))return(await Dl(e)).byteLength},QN=async(e,t)=>{const n=k.toFiniteNumber(e.getContentLength());return n??XN(t)},eF=ni&&(async e=>{let{url:t,method:n,data:r,signal:s,cancelToken:o,timeout:a,onDownloadProgress:i,onUploadProgress:l,responseType:u,headers:c,withCredentials:f="same-origin",fetchOptions:d}=Xp(e);u=u?(u+"").toLowerCase():"text";let[h,v]=s||o||a?GN([s,o],a):[],m,p;const b=()=>{!m&&setTimeout(()=>{h&&h.unsubscribe()}),m=!0};let S;try{if(l&&JN&&n!=="get"&&n!=="head"&&(S=await QN(c,r))!==0){let C=new Request(t,{method:"POST",body:r,duplex:"half"}),E;if(k.isFormData(r)&&(E=C.headers.get("content-type"))&&c.setContentType(E),C.body){const[P,$]=Ud(S,wa(zd(l)));r=Gd(C.body,qd,P,$,Dl)}}k.isString(f)||(f=f?"include":"omit"),p=new Request(t,{...d,signal:h,method:n.toUpperCase(),headers:c.normalize().toJSON(),body:r,duplex:"half",credentials:f});let T=await fetch(p);const M=Cl&&(u==="stream"||u==="response");if(Cl&&(i||M)){const C={};["status","statusText","headers"].forEach(I=>{C[I]=T[I]});const E=k.toFiniteNumber(T.headers.get("content-length")),[P,$]=i&&Ud(E,wa(zd(i),!0))||[];T=new Response(Gd(T.body,qd,P,()=>{$&&$(),M&&b()},Dl),C)}u=u||"text";let D=await _a[k.findKey(_a,u)||"text"](T,e);return!M&&b(),v&&v(),await new Promise((C,E)=>{Zp(C,E,{data:D,headers:Dt.from(T.headers),status:T.status,statusText:T.statusText,config:e,request:p})})}catch(T){throw b(),T&&T.name==="TypeError"&&/fetch/i.test(T.message)?Object.assign(new ve("Network Error",ve.ERR_NETWORK,e,p),{cause:T.cause||T}):ve.from(T,T&&T.code,e,p)}}),Sl={http:gN,xhr:KN,fetch:eF};k.forEach(Sl,(e,t)=>{if(e){try{Object.defineProperty(e,"name",{value:t})}catch{}Object.defineProperty(e,"adapterName",{value:t})}});const Zd=e=>`- ${e}`,tF=e=>k.isFunction(e)||e===null||e===!1,tg={getAdapter:e=>{e=k.isArray(e)?e:[e];const{length:t}=e;let n,r;const s={};for(let o=0;o`adapter ${i} `+(l===!1?"is not supported by the environment":"is not available in the build"));let a=t?o.length>1?`since : + .footer-container small {font-size:10px;line-height:1;}`,header:'["title"]',tags:'["themes"]',subheader:"[]",properties:'["satellite","sensor","agency","extent"]',featured:'["description","providers","assets","links"]',footer:'["sci:citation"]'},tagName:"eox-stacinfo"}}:null},{defineWidget:e=>e?{id:"Datepicker",type:"internal",layout:{x:5,y:10,w:1,h:1},title:"Datepicker",widget:{name:"EodashDatePicker"}}:null},{defineWidget:e=>e?{id:"Buttons",layout:{x:8,y:0,w:1,h:1},title:"Buttons",type:"internal",widget:{name:"EodashMapBtns"}}:null}]}});var wt="top",Ht="bottom",jt="right",_t="left",iu="auto",fo=[wt,Ht,jt,_t],Zr="start",Gs="end",Iw="clippingParents",tm="viewport",ws="popper",Lw="reference",bf=fo.reduce(function(e,t){return e.concat([t+"-"+Zr,t+"-"+Gs])},[]),nm=[].concat(fo,[iu]).reduce(function(e,t){return e.concat([t,t+"-"+Zr,t+"-"+Gs])},[]),Rw="beforeRead",Nw="read",Fw="afterRead",Yw="beforeMain",Bw="main",Hw="afterMain",jw="beforeWrite",Vw="write",Ww="afterWrite",Uw=[Rw,Nw,Fw,Yw,Bw,Hw,jw,Vw,Ww];function an(e){return e?(e.nodeName||"").toLowerCase():null}function xt(e){if(e==null)return window;if(e.toString()!=="[object Window]"){var t=e.ownerDocument;return t&&t.defaultView||window}return e}function mr(e){var t=xt(e).Element;return e instanceof t||e instanceof Element}function Yt(e){var t=xt(e).HTMLElement;return e instanceof t||e instanceof HTMLElement}function lu(e){if(typeof ShadowRoot>"u")return!1;var t=xt(e).ShadowRoot;return e instanceof t||e instanceof ShadowRoot}function zw(e){var t=e.state;Object.keys(t.elements).forEach(function(n){var r=t.styles[n]||{},s=t.attributes[n]||{},o=t.elements[n];!Yt(o)||!an(o)||(Object.assign(o.style,r),Object.keys(s).forEach(function(a){var i=s[a];i===!1?o.removeAttribute(a):o.setAttribute(a,i===!0?"":i)}))})}function Kw(e){var t=e.state,n={popper:{position:t.options.strategy,left:"0",top:"0",margin:"0"},arrow:{position:"absolute"},reference:{}};return Object.assign(t.elements.popper.style,n.popper),t.styles=n,t.elements.arrow&&Object.assign(t.elements.arrow.style,n.arrow),function(){Object.keys(t.elements).forEach(function(r){var s=t.elements[r],o=t.attributes[r]||{},a=Object.keys(t.styles.hasOwnProperty(r)?t.styles[r]:n[r]),i=a.reduce(function(l,u){return l[u]="",l},{});!Yt(s)||!an(s)||(Object.assign(s.style,i),Object.keys(o).forEach(function(l){s.removeAttribute(l)}))})}}const Gw={name:"applyStyles",enabled:!0,phase:"write",fn:zw,effect:Kw,requires:["computeStyles"]};function on(e){return e.split("-")[0]}var fr=Math.max,ua=Math.min,Jr=Math.round;function ll(){var e=navigator.userAgentData;return e!=null&&e.brands&&Array.isArray(e.brands)?e.brands.map(function(t){return t.brand+"/"+t.version}).join(" "):navigator.userAgent}function rm(){return!/^((?!chrome|android).)*safari/i.test(ll())}function Xr(e,t,n){t===void 0&&(t=!1),n===void 0&&(n=!1);var r=e.getBoundingClientRect(),s=1,o=1;t&&Yt(e)&&(s=e.offsetWidth>0&&Jr(r.width)/e.offsetWidth||1,o=e.offsetHeight>0&&Jr(r.height)/e.offsetHeight||1);var a=mr(e)?xt(e):window,i=a.visualViewport,l=!rm()&&n,u=(r.left+(l&&i?i.offsetLeft:0))/s,c=(r.top+(l&&i?i.offsetTop:0))/o,f=r.width/s,d=r.height/o;return{width:f,height:d,top:c,right:u+f,bottom:c+d,left:u,x:u,y:c}}function uu(e){var t=Xr(e),n=e.offsetWidth,r=e.offsetHeight;return Math.abs(t.width-n)<=1&&(n=t.width),Math.abs(t.height-r)<=1&&(r=t.height),{x:e.offsetLeft,y:e.offsetTop,width:n,height:r}}function sm(e,t){var n=t.getRootNode&&t.getRootNode();if(e.contains(t))return!0;if(n&&lu(n)){var r=t;do{if(r&&e.isSameNode(r))return!0;r=r.parentNode||r.host}while(r)}return!1}function yn(e){return xt(e).getComputedStyle(e)}function qw(e){return["table","td","th"].indexOf(an(e))>=0}function Gn(e){return((mr(e)?e.ownerDocument:e.document)||window.document).documentElement}function Va(e){return an(e)==="html"?e:e.assignedSlot||e.parentNode||(lu(e)?e.host:null)||Gn(e)}function wf(e){return!Yt(e)||yn(e).position==="fixed"?null:e.offsetParent}function Zw(e){var t=/firefox/i.test(ll()),n=/Trident/i.test(ll());if(n&&Yt(e)){var r=yn(e);if(r.position==="fixed")return null}var s=Va(e);for(lu(s)&&(s=s.host);Yt(s)&&["html","body"].indexOf(an(s))<0;){var o=yn(s);if(o.transform!=="none"||o.perspective!=="none"||o.contain==="paint"||["transform","perspective"].indexOf(o.willChange)!==-1||t&&o.willChange==="filter"||t&&o.filter&&o.filter!=="none")return s;s=s.parentNode}return null}function ho(e){for(var t=xt(e),n=wf(e);n&&qw(n)&&yn(n).position==="static";)n=wf(n);return n&&(an(n)==="html"||an(n)==="body"&&yn(n).position==="static")?t:n||Zw(e)||t}function cu(e){return["top","bottom"].indexOf(e)>=0?"x":"y"}function Rs(e,t,n){return fr(e,ua(t,n))}function Jw(e,t,n){var r=Rs(e,t,n);return r>n?n:r}function om(){return{top:0,right:0,bottom:0,left:0}}function am(e){return Object.assign({},om(),e)}function im(e,t){return t.reduce(function(n,r){return n[r]=e,n},{})}var Xw=function(t,n){return t=typeof t=="function"?t(Object.assign({},n.rects,{placement:n.placement})):t,am(typeof t!="number"?t:im(t,fo))};function Qw(e){var t,n=e.state,r=e.name,s=e.options,o=n.elements.arrow,a=n.modifiersData.popperOffsets,i=on(n.placement),l=cu(i),u=[_t,jt].indexOf(i)>=0,c=u?"height":"width";if(!(!o||!a)){var f=Xw(s.padding,n),d=uu(o),h=l==="y"?wt:_t,v=l==="y"?Ht:jt,m=n.rects.reference[c]+n.rects.reference[l]-a[l]-n.rects.popper[c],p=a[l]-n.rects.reference[l],b=ho(o),S=b?l==="y"?b.clientHeight||0:b.clientWidth||0:0,T=m/2-p/2,M=f[h],D=S-d[c]-f[v],C=S/2-d[c]/2+T,E=Rs(M,C,D),P=l;n.modifiersData[r]=(t={},t[P]=E,t.centerOffset=E-C,t)}}function e_(e){var t=e.state,n=e.options,r=n.element,s=r===void 0?"[data-popper-arrow]":r;s!=null&&(typeof s=="string"&&(s=t.elements.popper.querySelector(s),!s)||sm(t.elements.popper,s)&&(t.elements.arrow=s))}const t_={name:"arrow",enabled:!0,phase:"main",fn:Qw,effect:e_,requires:["popperOffsets"],requiresIfExists:["preventOverflow"]};function Qr(e){return e.split("-")[1]}var n_={top:"auto",right:"auto",bottom:"auto",left:"auto"};function r_(e,t){var n=e.x,r=e.y,s=t.devicePixelRatio||1;return{x:Jr(n*s)/s||0,y:Jr(r*s)/s||0}}function _f(e){var t,n=e.popper,r=e.popperRect,s=e.placement,o=e.variation,a=e.offsets,i=e.position,l=e.gpuAcceleration,u=e.adaptive,c=e.roundOffsets,f=e.isFixed,d=a.x,h=d===void 0?0:d,v=a.y,m=v===void 0?0:v,p=typeof c=="function"?c({x:h,y:m}):{x:h,y:m};h=p.x,m=p.y;var b=a.hasOwnProperty("x"),S=a.hasOwnProperty("y"),T=_t,M=wt,D=window;if(u){var C=ho(n),E="clientHeight",P="clientWidth";if(C===xt(n)&&(C=Gn(n),yn(C).position!=="static"&&i==="absolute"&&(E="scrollHeight",P="scrollWidth")),C=C,s===wt||(s===_t||s===jt)&&o===Gs){M=Ht;var $=f&&C===D&&D.visualViewport?D.visualViewport.height:C[E];m-=$-r.height,m*=l?1:-1}if(s===_t||(s===wt||s===Ht)&&o===Gs){T=jt;var I=f&&C===D&&D.visualViewport?D.visualViewport.width:C[P];h-=I-r.width,h*=l?1:-1}}var j=Object.assign({position:i},u&&n_),O=c===!0?r_({x:h,y:m},xt(n)):{x:h,y:m};if(h=O.x,m=O.y,l){var W;return Object.assign({},j,(W={},W[M]=S?"0":"",W[T]=b?"0":"",W.transform=(D.devicePixelRatio||1)<=1?"translate("+h+"px, "+m+"px)":"translate3d("+h+"px, "+m+"px, 0)",W))}return Object.assign({},j,(t={},t[M]=S?m+"px":"",t[T]=b?h+"px":"",t.transform="",t))}function s_(e){var t=e.state,n=e.options,r=n.gpuAcceleration,s=r===void 0?!0:r,o=n.adaptive,a=o===void 0?!0:o,i=n.roundOffsets,l=i===void 0?!0:i,u={placement:on(t.placement),variation:Qr(t.placement),popper:t.elements.popper,popperRect:t.rects.popper,gpuAcceleration:s,isFixed:t.options.strategy==="fixed"};t.modifiersData.popperOffsets!=null&&(t.styles.popper=Object.assign({},t.styles.popper,_f(Object.assign({},u,{offsets:t.modifiersData.popperOffsets,position:t.options.strategy,adaptive:a,roundOffsets:l})))),t.modifiersData.arrow!=null&&(t.styles.arrow=Object.assign({},t.styles.arrow,_f(Object.assign({},u,{offsets:t.modifiersData.arrow,position:"absolute",adaptive:!1,roundOffsets:l})))),t.attributes.popper=Object.assign({},t.attributes.popper,{"data-popper-placement":t.placement})}const o_={name:"computeStyles",enabled:!0,phase:"beforeWrite",fn:s_,data:{}};var ko={passive:!0};function a_(e){var t=e.state,n=e.instance,r=e.options,s=r.scroll,o=s===void 0?!0:s,a=r.resize,i=a===void 0?!0:a,l=xt(t.elements.popper),u=[].concat(t.scrollParents.reference,t.scrollParents.popper);return o&&u.forEach(function(c){c.addEventListener("scroll",n.update,ko)}),i&&l.addEventListener("resize",n.update,ko),function(){o&&u.forEach(function(c){c.removeEventListener("scroll",n.update,ko)}),i&&l.removeEventListener("resize",n.update,ko)}}const i_={name:"eventListeners",enabled:!0,phase:"write",fn:function(){},effect:a_,data:{}};var l_={left:"right",right:"left",bottom:"top",top:"bottom"};function Bo(e){return e.replace(/left|right|bottom|top/g,function(t){return l_[t]})}var u_={start:"end",end:"start"};function Df(e){return e.replace(/start|end/g,function(t){return u_[t]})}function fu(e){var t=xt(e),n=t.pageXOffset,r=t.pageYOffset;return{scrollLeft:n,scrollTop:r}}function du(e){return Xr(Gn(e)).left+fu(e).scrollLeft}function c_(e,t){var n=xt(e),r=Gn(e),s=n.visualViewport,o=r.clientWidth,a=r.clientHeight,i=0,l=0;if(s){o=s.width,a=s.height;var u=rm();(u||!u&&t==="fixed")&&(i=s.offsetLeft,l=s.offsetTop)}return{width:o,height:a,x:i+du(e),y:l}}function f_(e){var t,n=Gn(e),r=fu(e),s=(t=e.ownerDocument)==null?void 0:t.body,o=fr(n.scrollWidth,n.clientWidth,s?s.scrollWidth:0,s?s.clientWidth:0),a=fr(n.scrollHeight,n.clientHeight,s?s.scrollHeight:0,s?s.clientHeight:0),i=-r.scrollLeft+du(e),l=-r.scrollTop;return yn(s||n).direction==="rtl"&&(i+=fr(n.clientWidth,s?s.clientWidth:0)-o),{width:o,height:a,x:i,y:l}}function hu(e){var t=yn(e),n=t.overflow,r=t.overflowX,s=t.overflowY;return/auto|scroll|overlay|hidden/.test(n+s+r)}function lm(e){return["html","body","#document"].indexOf(an(e))>=0?e.ownerDocument.body:Yt(e)&&hu(e)?e:lm(Va(e))}function Ns(e,t){var n;t===void 0&&(t=[]);var r=lm(e),s=r===((n=e.ownerDocument)==null?void 0:n.body),o=xt(r),a=s?[o].concat(o.visualViewport||[],hu(r)?r:[]):r,i=t.concat(a);return s?i:i.concat(Ns(Va(a)))}function ul(e){return Object.assign({},e,{left:e.x,top:e.y,right:e.x+e.width,bottom:e.y+e.height})}function d_(e,t){var n=Xr(e,!1,t==="fixed");return n.top=n.top+e.clientTop,n.left=n.left+e.clientLeft,n.bottom=n.top+e.clientHeight,n.right=n.left+e.clientWidth,n.width=e.clientWidth,n.height=e.clientHeight,n.x=n.left,n.y=n.top,n}function Cf(e,t,n){return t===tm?ul(c_(e,n)):mr(t)?d_(t,n):ul(f_(Gn(e)))}function h_(e){var t=Ns(Va(e)),n=["absolute","fixed"].indexOf(yn(e).position)>=0,r=n&&Yt(e)?ho(e):e;return mr(r)?t.filter(function(s){return mr(s)&&sm(s,r)&&an(s)!=="body"}):[]}function v_(e,t,n,r){var s=t==="clippingParents"?h_(e):[].concat(t),o=[].concat(s,[n]),a=o[0],i=o.reduce(function(l,u){var c=Cf(e,u,r);return l.top=fr(c.top,l.top),l.right=ua(c.right,l.right),l.bottom=ua(c.bottom,l.bottom),l.left=fr(c.left,l.left),l},Cf(e,a,r));return i.width=i.right-i.left,i.height=i.bottom-i.top,i.x=i.left,i.y=i.top,i}function um(e){var t=e.reference,n=e.element,r=e.placement,s=r?on(r):null,o=r?Qr(r):null,a=t.x+t.width/2-n.width/2,i=t.y+t.height/2-n.height/2,l;switch(s){case wt:l={x:a,y:t.y-n.height};break;case Ht:l={x:a,y:t.y+t.height};break;case jt:l={x:t.x+t.width,y:i};break;case _t:l={x:t.x-n.width,y:i};break;default:l={x:t.x,y:t.y}}var u=s?cu(s):null;if(u!=null){var c=u==="y"?"height":"width";switch(o){case Zr:l[u]=l[u]-(t[c]/2-n[c]/2);break;case Gs:l[u]=l[u]+(t[c]/2-n[c]/2);break}}return l}function qs(e,t){t===void 0&&(t={});var n=t,r=n.placement,s=r===void 0?e.placement:r,o=n.strategy,a=o===void 0?e.strategy:o,i=n.boundary,l=i===void 0?Iw:i,u=n.rootBoundary,c=u===void 0?tm:u,f=n.elementContext,d=f===void 0?ws:f,h=n.altBoundary,v=h===void 0?!1:h,m=n.padding,p=m===void 0?0:m,b=am(typeof p!="number"?p:im(p,fo)),S=d===ws?Lw:ws,T=e.rects.popper,M=e.elements[v?S:d],D=v_(mr(M)?M:M.contextElement||Gn(e.elements.popper),l,c,a),C=Xr(e.elements.reference),E=um({reference:C,element:T,strategy:"absolute",placement:s}),P=ul(Object.assign({},T,E)),$=d===ws?P:C,I={top:D.top-$.top+b.top,bottom:$.bottom-D.bottom+b.bottom,left:D.left-$.left+b.left,right:$.right-D.right+b.right},j=e.modifiersData.offset;if(d===ws&&j){var O=j[s];Object.keys(I).forEach(function(W){var re=[jt,Ht].indexOf(W)>=0?1:-1,X=[wt,Ht].indexOf(W)>=0?"y":"x";I[W]+=O[X]*re})}return I}function m_(e,t){t===void 0&&(t={});var n=t,r=n.placement,s=n.boundary,o=n.rootBoundary,a=n.padding,i=n.flipVariations,l=n.allowedAutoPlacements,u=l===void 0?nm:l,c=Qr(r),f=c?i?bf:bf.filter(function(v){return Qr(v)===c}):fo,d=f.filter(function(v){return u.indexOf(v)>=0});d.length===0&&(d=f);var h=d.reduce(function(v,m){return v[m]=qs(e,{placement:m,boundary:s,rootBoundary:o,padding:a})[on(m)],v},{});return Object.keys(h).sort(function(v,m){return h[v]-h[m]})}function p_(e){if(on(e)===iu)return[];var t=Bo(e);return[Df(e),t,Df(t)]}function g_(e){var t=e.state,n=e.options,r=e.name;if(!t.modifiersData[r]._skip){for(var s=n.mainAxis,o=s===void 0?!0:s,a=n.altAxis,i=a===void 0?!0:a,l=n.fallbackPlacements,u=n.padding,c=n.boundary,f=n.rootBoundary,d=n.altBoundary,h=n.flipVariations,v=h===void 0?!0:h,m=n.allowedAutoPlacements,p=t.options.placement,b=on(p),S=b===p,T=l||(S||!v?[Bo(p)]:p_(p)),M=[p].concat(T).reduce(function(pe,Ye){return pe.concat(on(Ye)===iu?m_(t,{placement:Ye,boundary:c,rootBoundary:f,padding:u,flipVariations:v,allowedAutoPlacements:m}):Ye)},[]),D=t.rects.reference,C=t.rects.popper,E=new Map,P=!0,$=M[0],I=0;I=0,X=re?"width":"height",ee=qs(t,{placement:j,boundary:c,rootBoundary:f,altBoundary:d,padding:u}),J=re?W?jt:_t:W?Ht:wt;D[X]>C[X]&&(J=Bo(J));var ue=Bo(J),we=[];if(o&&we.push(ee[O]<=0),i&&we.push(ee[J]<=0,ee[ue]<=0),we.every(function(pe){return pe})){$=j,P=!1;break}E.set(j,we)}if(P)for(var V=v?3:1,fe=function(Ye){var Re=M.find(function(ye){var ze=E.get(ye);if(ze)return ze.slice(0,Ye).every(function(tt){return tt})});if(Re)return $=Re,"break"},Q=V;Q>0;Q--){var Le=fe(Q);if(Le==="break")break}t.placement!==$&&(t.modifiersData[r]._skip=!0,t.placement=$,t.reset=!0)}}const y_={name:"flip",enabled:!0,phase:"main",fn:g_,requiresIfExists:["offset"],data:{_skip:!1}};function Sf(e,t,n){return n===void 0&&(n={x:0,y:0}),{top:e.top-t.height-n.y,right:e.right-t.width+n.x,bottom:e.bottom-t.height+n.y,left:e.left-t.width-n.x}}function $f(e){return[wt,jt,Ht,_t].some(function(t){return e[t]>=0})}function b_(e){var t=e.state,n=e.name,r=t.rects.reference,s=t.rects.popper,o=t.modifiersData.preventOverflow,a=qs(t,{elementContext:"reference"}),i=qs(t,{altBoundary:!0}),l=Sf(a,r),u=Sf(i,s,o),c=$f(l),f=$f(u);t.modifiersData[n]={referenceClippingOffsets:l,popperEscapeOffsets:u,isReferenceHidden:c,hasPopperEscaped:f},t.attributes.popper=Object.assign({},t.attributes.popper,{"data-popper-reference-hidden":c,"data-popper-escaped":f})}const w_={name:"hide",enabled:!0,phase:"main",requiresIfExists:["preventOverflow"],fn:b_};function __(e,t,n){var r=on(e),s=[_t,wt].indexOf(r)>=0?-1:1,o=typeof n=="function"?n(Object.assign({},t,{placement:e})):n,a=o[0],i=o[1];return a=a||0,i=(i||0)*s,[_t,jt].indexOf(r)>=0?{x:i,y:a}:{x:a,y:i}}function D_(e){var t=e.state,n=e.options,r=e.name,s=n.offset,o=s===void 0?[0,0]:s,a=nm.reduce(function(c,f){return c[f]=__(f,t.rects,o),c},{}),i=a[t.placement],l=i.x,u=i.y;t.modifiersData.popperOffsets!=null&&(t.modifiersData.popperOffsets.x+=l,t.modifiersData.popperOffsets.y+=u),t.modifiersData[r]=a}const C_={name:"offset",enabled:!0,phase:"main",requires:["popperOffsets"],fn:D_};function S_(e){var t=e.state,n=e.name;t.modifiersData[n]=um({reference:t.rects.reference,element:t.rects.popper,strategy:"absolute",placement:t.placement})}const $_={name:"popperOffsets",enabled:!0,phase:"read",fn:S_,data:{}};function T_(e){return e==="x"?"y":"x"}function E_(e){var t=e.state,n=e.options,r=e.name,s=n.mainAxis,o=s===void 0?!0:s,a=n.altAxis,i=a===void 0?!1:a,l=n.boundary,u=n.rootBoundary,c=n.altBoundary,f=n.padding,d=n.tether,h=d===void 0?!0:d,v=n.tetherOffset,m=v===void 0?0:v,p=qs(t,{boundary:l,rootBoundary:u,padding:f,altBoundary:c}),b=on(t.placement),S=Qr(t.placement),T=!S,M=cu(b),D=T_(M),C=t.modifiersData.popperOffsets,E=t.rects.reference,P=t.rects.popper,$=typeof m=="function"?m(Object.assign({},t.rects,{placement:t.placement})):m,I=typeof $=="number"?{mainAxis:$,altAxis:$}:Object.assign({mainAxis:0,altAxis:0},$),j=t.modifiersData.offset?t.modifiersData.offset[t.placement]:null,O={x:0,y:0};if(C){if(o){var W,re=M==="y"?wt:_t,X=M==="y"?Ht:jt,ee=M==="y"?"height":"width",J=C[M],ue=J+p[re],we=J-p[X],V=h?-P[ee]/2:0,fe=S===Zr?E[ee]:P[ee],Q=S===Zr?-P[ee]:-E[ee],Le=t.elements.arrow,pe=h&&Le?uu(Le):{width:0,height:0},Ye=t.modifiersData["arrow#persistent"]?t.modifiersData["arrow#persistent"].padding:om(),Re=Ye[re],ye=Ye[X],ze=Rs(0,E[ee],pe[ee]),tt=T?E[ee]/2-V-ze-Re-I.mainAxis:fe-ze-Re-I.mainAxis,lt=T?-E[ee]/2+V+ze+ye+I.mainAxis:Q+ze+ye+I.mainAxis,mt=t.elements.arrow&&ho(t.elements.arrow),ut=mt?M==="y"?mt.clientTop||0:mt.clientLeft||0:0,g=(W=j?.[M])!=null?W:0,_=J+tt-g-ut,k=J+lt-g,Y=Rs(h?ua(ue,_):ue,J,h?fr(we,k):we);C[M]=Y,O[M]=Y-J}if(i){var R,H=M==="x"?wt:_t,K=M==="x"?Ht:jt,U=C[D],z=D==="y"?"height":"width",B=U+p[H],q=U-p[K],ne=[wt,_t].indexOf(b)!==-1,te=(R=j?.[D])!=null?R:0,ie=ne?B:U-E[z]-P[z]-te+I.altAxis,de=ne?U+E[z]+P[z]-te-I.altAxis:q,Ce=h&&ne?Jw(ie,U,de):Rs(h?ie:B,U,h?de:q);C[D]=Ce,O[D]=Ce-U}t.modifiersData[r]=O}}const O_={name:"preventOverflow",enabled:!0,phase:"main",fn:E_,requiresIfExists:["offset"]};function M_(e){return{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}}function k_(e){return e===xt(e)||!Yt(e)?fu(e):M_(e)}function x_(e){var t=e.getBoundingClientRect(),n=Jr(t.width)/e.offsetWidth||1,r=Jr(t.height)/e.offsetHeight||1;return n!==1||r!==1}function P_(e,t,n){n===void 0&&(n=!1);var r=Yt(t),s=Yt(t)&&x_(t),o=Gn(t),a=Xr(e,s,n),i={scrollLeft:0,scrollTop:0},l={x:0,y:0};return(r||!r&&!n)&&((an(t)!=="body"||hu(o))&&(i=k_(t)),Yt(t)?(l=Xr(t,!0),l.x+=t.clientLeft,l.y+=t.clientTop):o&&(l.x=du(o))),{x:a.left+i.scrollLeft-l.x,y:a.top+i.scrollTop-l.y,width:a.width,height:a.height}}function A_(e){var t=new Map,n=new Set,r=[];e.forEach(function(o){t.set(o.name,o)});function s(o){n.add(o.name);var a=[].concat(o.requires||[],o.requiresIfExists||[]);a.forEach(function(i){if(!n.has(i)){var l=t.get(i);l&&s(l)}}),r.push(o)}return e.forEach(function(o){n.has(o.name)||s(o)}),r}function I_(e){var t=A_(e);return Uw.reduce(function(n,r){return n.concat(t.filter(function(s){return s.phase===r}))},[])}function L_(e){var t;return function(){return t||(t=new Promise(function(n){Promise.resolve().then(function(){t=void 0,n(e())})})),t}}function R_(e){var t=e.reduce(function(n,r){var s=n[r.name];return n[r.name]=s?Object.assign({},s,r,{options:Object.assign({},s.options,r.options),data:Object.assign({},s.data,r.data)}):r,n},{});return Object.keys(t).map(function(n){return t[n]})}var Tf={placement:"bottom",modifiers:[],strategy:"absolute"};function Ef(){for(var e=arguments.length,t=new Array(e),n=0;nt in e?B_(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,se=(e,t,n)=>(H_(e,typeof t!="symbol"?t+"":t,n),n),xo=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function cm(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var j_=Object.prototype,V_=j_.hasOwnProperty;function W_(e,t){return e!=null&&V_.call(e,t)}var U_=W_,z_=Array.isArray,Zt=z_,K_=typeof xo=="object"&&xo&&xo.Object===Object&&xo,fm=K_,G_=fm,q_=typeof self=="object"&&self&&self.Object===Object&&self,Z_=G_||q_||Function("return this")(),un=Z_,J_=un,X_=J_.Symbol,Wa=X_,Of=Wa,dm=Object.prototype,Q_=dm.hasOwnProperty,eD=dm.toString,_s=Of?Of.toStringTag:void 0;function tD(e){var t=Q_.call(e,_s),n=e[_s];try{e[_s]=void 0;var r=!0}catch{}var s=eD.call(e);return r&&(t?e[_s]=n:delete e[_s]),s}var nD=tD,rD=Object.prototype,sD=rD.toString;function oD(e){return sD.call(e)}var aD=oD,Mf=Wa,iD=nD,lD=aD,uD="[object Null]",cD="[object Undefined]",kf=Mf?Mf.toStringTag:void 0;function fD(e){return e==null?e===void 0?cD:uD:kf&&kf in Object(e)?iD(e):lD(e)}var cn=fD;function dD(e){return e!=null&&typeof e=="object"}var Jt=dD,hD=cn,vD=Jt,mD="[object Symbol]";function pD(e){return typeof e=="symbol"||vD(e)&&hD(e)==mD}var vu=pD,gD=Zt,yD=vu,bD=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,wD=/^\w*$/;function _D(e,t){if(gD(e))return!1;var n=typeof e;return n=="number"||n=="symbol"||n=="boolean"||e==null||yD(e)?!0:wD.test(e)||!bD.test(e)||t!=null&&e in Object(t)}var mu=_D;function DD(e){var t=typeof e;return e!=null&&(t=="object"||t=="function")}var Sn=DD,CD=cn,SD=Sn,$D="[object AsyncFunction]",TD="[object Function]",ED="[object GeneratorFunction]",OD="[object Proxy]";function MD(e){if(!SD(e))return!1;var t=CD(e);return t==TD||t==ED||t==$D||t==OD}var Dr=MD,kD=un,xD=kD["__core-js_shared__"],PD=xD,Ci=PD,xf=function(){var e=/[^.]+$/.exec(Ci&&Ci.keys&&Ci.keys.IE_PROTO||"");return e?"Symbol(src)_1."+e:""}();function AD(e){return!!xf&&xf in e}var ID=AD,LD=Function.prototype,RD=LD.toString;function ND(e){if(e!=null){try{return RD.call(e)}catch{}try{return e+""}catch{}}return""}var hm=ND,FD=Dr,YD=ID,BD=Sn,HD=hm,jD=/[\\^$.*+?()[\]{}|]/g,VD=/^\[object .+?Constructor\]$/,WD=Function.prototype,UD=Object.prototype,zD=WD.toString,KD=UD.hasOwnProperty,GD=RegExp("^"+zD.call(KD).replace(jD,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function qD(e){if(!BD(e)||YD(e))return!1;var t=FD(e)?GD:VD;return t.test(HD(e))}var ZD=qD;function JD(e,t){return e?.[t]}var XD=JD,QD=ZD,eC=XD;function tC(e,t){var n=eC(e,t);return QD(n)?n:void 0}var Cr=tC,nC=Cr,rC=nC(Object,"create"),Ua=rC,Pf=Ua;function sC(){this.__data__=Pf?Pf(null):{},this.size=0}var oC=sC;function aC(e){var t=this.has(e)&&delete this.__data__[e];return this.size-=t?1:0,t}var iC=aC,lC=Ua,uC="__lodash_hash_undefined__",cC=Object.prototype,fC=cC.hasOwnProperty;function dC(e){var t=this.__data__;if(lC){var n=t[e];return n===uC?void 0:n}return fC.call(t,e)?t[e]:void 0}var hC=dC,vC=Ua,mC=Object.prototype,pC=mC.hasOwnProperty;function gC(e){var t=this.__data__;return vC?t[e]!==void 0:pC.call(t,e)}var yC=gC,bC=Ua,wC="__lodash_hash_undefined__";function _C(e,t){var n=this.__data__;return this.size+=this.has(e)?0:1,n[e]=bC&&t===void 0?wC:t,this}var DC=_C,CC=oC,SC=iC,$C=hC,TC=yC,EC=DC;function as(e){var t=-1,n=e==null?0:e.length;for(this.clear();++t-1}var WC=VC,UC=za;function zC(e,t){var n=this.__data__,r=UC(n,e);return r<0?(++this.size,n.push([e,t])):n[r][1]=t,this}var KC=zC,GC=kC,qC=FC,ZC=HC,JC=WC,XC=KC;function ls(e){var t=-1,n=e==null?0:e.length;for(this.clear();++t-1&&e%1==0&&e-1&&e%1==0&&e<=f$}var _u=d$,h$=vu,v$=1/0;function m$(e){if(typeof e=="string"||h$(e))return e;var t=e+"";return t=="0"&&1/e==-v$?"-0":t}var qa=m$,p$=pm,g$=bu,y$=Zt,b$=wu,w$=_u,_$=qa;function D$(e,t,n){t=p$(t,e);for(var r=-1,s=t.length,o=!1;++ri))return!1;var u=o.get(e),c=o.get(t);if(u&&c)return u==t&&c==e;var f=-1,d=!0,h=n&$T?new _T:void 0;for(o.set(e,t),o.set(t,e);++f0){if(++t>=$x)return arguments[0]}else t=0;return e.apply(void 0,arguments)}}var Mx=Ox,kx=Sx,xx=Mx,Px=xx(kx),Ax=Px,Ix=Tu,Lx=yx,Rx=Ax;function Nx(e,t){return Rx(Lx(e,t,Ix),e+"")}var Ou=Nx;function Fx(e){var t=[];if(e!=null)for(var n in Object(e))t.push(n);return t}var Yx=Fx,Bx=Sn,Hx=Su,jx=Yx,Vx=Object.prototype,Wx=Vx.hasOwnProperty;function Ux(e){if(!Bx(e))return jx(e);var t=Hx(e),n=[];for(var r in e)r=="constructor"&&(t||!Wx.call(e,r))||n.push(r);return n}var zx=Ux,Kx=Sm,Gx=zx,qx=vo;function Zx(e){return qx(e)?Kx(e,!0):Gx(e)}var Mu=Zx,Jx=Ou,Xx=is,Qx=Eu,e2=Mu,Nm=Object.prototype,t2=Nm.hasOwnProperty,n2=Jx(function(e,t){e=Object(e);var n=-1,r=t.length,s=r>2?t[2]:void 0;for(s&&Qx(t[0],t[1],s)&&(r=1);++n1?n[s-1]:void 0,a=s>2?n[2]:void 0;for(o=e.length>3&&typeof o=="function"?(s--,o):void 0,a&&pP(n[0],n[1],a)&&(o=s<3?void 0:o,s=1),t=Object(t);++rObject.prototype.toString.call(e).slice(8,-1),Hr=e=>R$(e)&&!isNaN(e.getTime()),bn=e=>kP(e)==="Object",zm=bm,pd=(e,t)=>Uk(t,n=>bm(e,n)),Oe=(e,t,n="0")=>{for(e=e!=null?String(e):"",t=t||2;e.lengthArray.isArray(e),mn=e=>Bt(e)&&e.length>0,da=e=>e==null?null:document&&rn(e)?document.querySelector(e):e.$el??e,Rn=(e,t,n,r=void 0)=>{e.removeEventListener(t,n,r)},Nn=(e,t,n,r=void 0)=>(e.addEventListener(t,n,r),()=>Rn(e,t,n,r)),Ho=(e,t)=>!!e&&!!t&&(e===t||e.contains(t)),Ao=(e,t)=>{(e.key===" "||e.key==="Enter")&&(t(e),e.preventDefault())},Km=(e,...t)=>{const n={};let r;for(r in e)t.includes(r)||(n[r]=e[r]);return n},Gm=(e,t)=>{const n={};return t.forEach(r=>{r in e&&(n[r]=e[r])}),n};function xP(e,t,n){return Math.min(Math.max(e,t),n)}var ha={},PP={get exports(){return ha},set exports(e){ha=e}};(function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.default=n;function n(r){if(r===null||r===!0||r===!1)return NaN;var s=Number(r);return isNaN(s)?s:s<0?Math.ceil(s):Math.floor(s)}e.exports=t.default})(PP,ha);const AP=cm(ha);var va={},IP={get exports(){return va},set exports(e){va=e}};(function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.default=n;function n(r){var s=new Date(Date.UTC(r.getFullYear(),r.getMonth(),r.getDate(),r.getHours(),r.getMinutes(),r.getSeconds(),r.getMilliseconds()));return s.setUTCFullYear(r.getFullYear()),r.getTime()-s.getTime()}e.exports=t.default})(IP,va);const gd=cm(va);function LP(e,t){var n=YP(t);return n.formatToParts?NP(n,e):FP(n,e)}var RP={year:0,month:1,day:2,hour:3,minute:4,second:5};function NP(e,t){try{for(var n=e.formatToParts(t),r=[],s=0;s=0&&(r[o]=parseInt(n[s].value,10))}return r}catch(a){if(a instanceof RangeError)return[NaN];throw a}}function FP(e,t){var n=e.format(t).replace(/\u200E/g,""),r=/(\d+)\/(\d+)\/(\d+),? (\d+):(\d+):(\d+)/.exec(n);return[r[3],r[1],r[2],r[4],r[5],r[6]]}var Ti={};function YP(e){if(!Ti[e]){var t=new Intl.DateTimeFormat("en-US",{hour12:!1,timeZone:"America/New_York",year:"numeric",month:"numeric",day:"2-digit",hour:"2-digit",minute:"2-digit",second:"2-digit"}).format(new Date("2014-06-25T04:00:00.123Z")),n=t==="06/25/2014, 00:00:00"||t==="‎06‎/‎25‎/‎2014‎ ‎00‎:‎00‎:‎00";Ti[e]=n?new Intl.DateTimeFormat("en-US",{hour12:!1,timeZone:e,year:"numeric",month:"numeric",day:"2-digit",hour:"2-digit",minute:"2-digit",second:"2-digit"}):new Intl.DateTimeFormat("en-US",{hourCycle:"h23",timeZone:e,year:"numeric",month:"numeric",day:"2-digit",hour:"2-digit",minute:"2-digit",second:"2-digit"})}return Ti[e]}function qm(e,t,n,r,s,o,a){var i=new Date(0);return i.setUTCFullYear(e,t,n),i.setUTCHours(r,s,o,a),i}var yd=36e5,BP=6e4,Ei={timezone:/([Z+-].*)$/,timezoneZ:/^(Z)$/,timezoneHH:/^([+-]\d{2})$/,timezoneHHMM:/^([+-]\d{2}):?(\d{2})$/};function HP(e,t,n){var r,s;if(!e||(r=Ei.timezoneZ.exec(e),r))return 0;var o;if(r=Ei.timezoneHH.exec(e),r)return o=parseInt(r[1],10),bd(o)?-(o*yd):NaN;if(r=Ei.timezoneHHMM.exec(e),r){o=parseInt(r[1],10);var a=parseInt(r[2],10);return bd(o,a)?(s=Math.abs(o)*yd+a*BP,o>0?-s:s):NaN}if(WP(e)){t=new Date(t||Date.now());var i=jP(t),l=ml(i,e),u=VP(t,l,e);return-u}return NaN}function jP(e){return qm(e.getFullYear(),e.getMonth(),e.getDate(),e.getHours(),e.getMinutes(),e.getSeconds(),e.getMilliseconds())}function ml(e,t){var n=LP(e,t),r=qm(n[0],n[1]-1,n[2],n[3]%24,n[4],n[5],0).getTime(),s=e.getTime(),o=s%1e3;return s-=o>=0?o:1e3+o,r-s}function VP(e,t,n){var r=e.getTime(),s=r-t,o=ml(new Date(s),n);if(t===o)return t;s-=o-t;var a=ml(new Date(s),n);return o===a?o:Math.max(o,a)}function bd(e,t){return-23<=e&&e<=23&&(t==null||0<=t&&t<=59)}var wd={};function WP(e){if(wd[e])return!0;try{return new Intl.DateTimeFormat(void 0,{timeZone:e}),wd[e]=!0,!0}catch{return!1}}var UP=/(Z|[+-]\d{2}(?::?\d{2})?| UTC| [a-zA-Z]+\/[a-zA-Z_]+(?:\/[a-zA-Z_]+)?)$/;const zP=UP;var Oi=36e5,_d=6e4,KP=2,vt={dateTimePattern:/^([0-9W+-]+)(T| )(.*)/,datePattern:/^([0-9W+-]+)(.*)/,plainTime:/:/,YY:/^(\d{2})$/,YYY:[/^([+-]\d{2})$/,/^([+-]\d{3})$/,/^([+-]\d{4})$/],YYYY:/^(\d{4})/,YYYYY:[/^([+-]\d{4})/,/^([+-]\d{5})/,/^([+-]\d{6})/],MM:/^-(\d{2})$/,DDD:/^-?(\d{3})$/,MMDD:/^-?(\d{2})-?(\d{2})$/,Www:/^-?W(\d{2})$/,WwwD:/^-?W(\d{2})-?(\d{1})$/,HH:/^(\d{2}([.,]\d*)?)$/,HHMM:/^(\d{2}):?(\d{2}([.,]\d*)?)$/,HHMMSS:/^(\d{2}):?(\d{2}):?(\d{2}([.,]\d*)?)$/,timeZone:zP};function GP(e,t){if(arguments.length<1)throw new TypeError("1 argument required, but only "+arguments.length+" present");if(e===null)return new Date(NaN);var n=t||{},r=n.additionalDigits==null?KP:AP(n.additionalDigits);if(r!==2&&r!==1&&r!==0)throw new RangeError("additionalDigits must be 0, 1 or 2");if(e instanceof Date||typeof e=="object"&&Object.prototype.toString.call(e)==="[object Date]")return new Date(e.getTime());if(typeof e=="number"||Object.prototype.toString.call(e)==="[object Number]")return new Date(e);if(!(typeof e=="string"||Object.prototype.toString.call(e)==="[object String]"))return new Date(NaN);var s=qP(e),o=ZP(s.date,r),a=o.year,i=o.restDateString,l=JP(i,a);if(isNaN(l))return new Date(NaN);if(l){var u=l.getTime(),c=0,f;if(s.time&&(c=XP(s.time),isNaN(c)))return new Date(NaN);if(s.timeZone||n.timeZone){if(f=HP(s.timeZone||n.timeZone,new Date(u+c)),isNaN(f))return new Date(NaN)}else f=gd(new Date(u+c)),f=gd(new Date(u+c+f));return new Date(u+c+f)}else return new Date(NaN)}function qP(e){var t={},n=vt.dateTimePattern.exec(e),r;if(n?(t.date=n[1],r=n[3]):(n=vt.datePattern.exec(e),n?(t.date=n[1],r=n[2]):(t.date=null,r=e)),r){var s=vt.timeZone.exec(r);s?(t.time=r.replace(s[1],""),t.timeZone=s[1].trim()):t.time=r}return t}function ZP(e,t){var n=vt.YYY[t],r=vt.YYYYY[t],s;if(s=vt.YYYY.exec(e)||r.exec(e),s){var o=s[1];return{year:parseInt(o,10),restDateString:e.slice(o.length)}}if(s=vt.YY.exec(e)||n.exec(e),s){var a=s[1];return{year:parseInt(a,10)*100,restDateString:e.slice(a.length)}}return{year:null}}function JP(e,t){if(t===null)return null;var n,r,s,o;if(e.length===0)return r=new Date(0),r.setUTCFullYear(t),r;if(n=vt.MM.exec(e),n)return r=new Date(0),s=parseInt(n[1],10)-1,Cd(t,s)?(r.setUTCFullYear(t,s),r):new Date(NaN);if(n=vt.DDD.exec(e),n){r=new Date(0);var a=parseInt(n[1],10);return tA(t,a)?(r.setUTCFullYear(t,0,a),r):new Date(NaN)}if(n=vt.MMDD.exec(e),n){r=new Date(0),s=parseInt(n[1],10)-1;var i=parseInt(n[2],10);return Cd(t,s,i)?(r.setUTCFullYear(t,s,i),r):new Date(NaN)}if(n=vt.Www.exec(e),n)return o=parseInt(n[1],10)-1,Sd(t,o)?Dd(t,o):new Date(NaN);if(n=vt.WwwD.exec(e),n){o=parseInt(n[1],10)-1;var l=parseInt(n[2],10)-1;return Sd(t,o,l)?Dd(t,o,l):new Date(NaN)}return null}function XP(e){var t,n,r;if(t=vt.HH.exec(e),t)return n=parseFloat(t[1].replace(",",".")),Mi(n)?n%24*Oi:NaN;if(t=vt.HHMM.exec(e),t)return n=parseInt(t[1],10),r=parseFloat(t[2].replace(",",".")),Mi(n,r)?n%24*Oi+r*_d:NaN;if(t=vt.HHMMSS.exec(e),t){n=parseInt(t[1],10),r=parseInt(t[2],10);var s=parseFloat(t[3].replace(",","."));return Mi(n,r,s)?n%24*Oi+r*_d+s*1e3:NaN}return null}function Dd(e,t,n){t=t||0,n=n||0;var r=new Date(0);r.setUTCFullYear(e,0,4);var s=r.getUTCDay()||7,o=t*7+n+1-s;return r.setUTCDate(r.getUTCDate()+o),r}var QP=[31,28,31,30,31,30,31,31,30,31,30,31],eA=[31,29,31,30,31,30,31,31,30,31,30,31];function Zm(e){return e%400===0||e%4===0&&e%100!==0}function Cd(e,t,n){if(t<0||t>11)return!1;if(n!=null){if(n<1)return!1;var r=Zm(e);if(r&&n>eA[t]||!r&&n>QP[t])return!1}return!0}function tA(e,t){if(t<1)return!1;var n=Zm(e);return!(n&&t>366||!n&&t>365)}function Sd(e,t,n){return!(t<0||t>52||n!=null&&(n<0||n>6))}function Mi(e,t,n){return!(e!=null&&(e<0||e>=25)||t!=null&&(t<0||t>=60)||n!=null&&(n<0||n>=60))}function it(e,t){if(t.length1?"s":"")+" required, but only "+t.length+" present")}function jo(e){"@babel/helpers - typeof";return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?jo=function(n){return typeof n}:jo=function(n){return n&&typeof Symbol=="function"&&n.constructor===Symbol&&n!==Symbol.prototype?"symbol":typeof n},jo(e)}function $n(e){it(1,arguments);var t=Object.prototype.toString.call(e);return e instanceof Date||jo(e)==="object"&&t==="[object Date]"?new Date(e.getTime()):typeof e=="number"||t==="[object Number]"?new Date(e):((typeof e=="string"||t==="[object String]")&&typeof console<"u"&&(console.warn("Starting with v2.0.0-beta.1 date-fns doesn't accept strings as date arguments. Please use `parseISO` to parse strings. See: https://github.com/date-fns/date-fns/blob/master/docs/upgradeGuide.md#string-arguments"),console.warn(new Error().stack)),new Date(NaN))}function ds(e){if(e===null||e===!0||e===!1)return NaN;var t=Number(e);return isNaN(t)?t:t<0?Math.ceil(t):Math.floor(t)}var nA={};function ku(){return nA}function pr(e,t){var n,r,s,o,a,i,l,u;it(1,arguments);var c=ku(),f=ds((n=(r=(s=(o=t?.weekStartsOn)!==null&&o!==void 0?o:t==null||(a=t.locale)===null||a===void 0||(i=a.options)===null||i===void 0?void 0:i.weekStartsOn)!==null&&s!==void 0?s:c.weekStartsOn)!==null&&r!==void 0?r:(l=c.locale)===null||l===void 0||(u=l.options)===null||u===void 0?void 0:u.weekStartsOn)!==null&&n!==void 0?n:0);if(!(f>=0&&f<=6))throw new RangeError("weekStartsOn must be between 0 and 6 inclusively");var d=$n(e),h=d.getDay(),v=(h=1&&h<=7))throw new RangeError("firstWeekContainsDate must be between 1 and 7 inclusively");var v=new Date(0);v.setFullYear(f+1,0,h),v.setHours(0,0,0,0);var m=pr(v,t),p=new Date(0);p.setFullYear(f,0,h),p.setHours(0,0,0,0);var b=pr(p,t);return c.getTime()>=m.getTime()?f+1:c.getTime()>=b.getTime()?f:f-1}function uA(e,t){var n,r,s,o,a,i,l,u;it(1,arguments);var c=ku(),f=ds((n=(r=(s=(o=t?.firstWeekContainsDate)!==null&&o!==void 0?o:t==null||(a=t.locale)===null||a===void 0||(i=a.options)===null||i===void 0?void 0:i.firstWeekContainsDate)!==null&&s!==void 0?s:c.firstWeekContainsDate)!==null&&r!==void 0?r:(l=c.locale)===null||l===void 0||(u=l.options)===null||u===void 0?void 0:u.firstWeekContainsDate)!==null&&n!==void 0?n:1),d=lA(e,t),h=new Date(0);h.setFullYear(d,0,f),h.setHours(0,0,0,0);var v=pr(h,t);return v}var cA=6048e5;function fA(e,t){it(1,arguments);var n=$n(e),r=pr(n,t).getTime()-uA(n,t).getTime();return Math.round(r/cA)+1}function ma(e){return it(1,arguments),pr(e,{weekStartsOn:1})}function dA(e){it(1,arguments);var t=$n(e),n=t.getFullYear(),r=new Date(0);r.setFullYear(n+1,0,4),r.setHours(0,0,0,0);var s=ma(r),o=new Date(0);o.setFullYear(n,0,4),o.setHours(0,0,0,0);var a=ma(o);return t.getTime()>=s.getTime()?n+1:t.getTime()>=a.getTime()?n:n-1}function hA(e){it(1,arguments);var t=dA(e),n=new Date(0);n.setFullYear(t,0,4),n.setHours(0,0,0,0);var r=ma(n);return r}var vA=6048e5;function mA(e){it(1,arguments);var t=$n(e),n=ma(t).getTime()-hA(t).getTime();return Math.round(n/vA)+1}function ht(e,t){it(2,arguments);var n=$n(e),r=ds(t);return isNaN(r)?new Date(NaN):(r&&n.setDate(n.getDate()+r),n)}function pa(e,t){it(2,arguments);var n=$n(e),r=ds(t);if(isNaN(r))return new Date(NaN);if(!r)return n;var s=n.getDate(),o=new Date(n.getTime());o.setMonth(n.getMonth()+r+1,0);var a=o.getDate();return s>=a?o:(n.setFullYear(o.getFullYear(),o.getMonth(),s),n)}function Td(e,t){it(2,arguments);var n=ds(t);return pa(e,n*12)}const pA={daily:["year","month","day"],weekly:["year","month","week"],monthly:["year","month"]};function gA({monthComps:e,prevMonthComps:t,nextMonthComps:n},r){const s=[],{firstDayOfWeek:o,firstWeekday:a,isoWeeknumbers:i,weeknumbers:l,numDays:u,numWeeks:c}=e,f=a+(a{const l=Math.floor(i/7);let u=o[l];return u||(u={id:`week-${l+1}`,title:"",week:a.week,weekPosition:a.weekPosition,weeknumber:a.weeknumber,isoWeeknumber:a.isoWeeknumber,weeknumberDisplay:t?a.weeknumber:n?a.isoWeeknumber:void 0,days:[]},o[l]=u),u.days.push(a),o},Array(e.length/nt));return s.forEach(o=>{const a=o.days[0],i=o.days[o.days.length-1];a.month===i.month?o.title=`${r.formatDate(a.date,"MMMM YYYY")}`:a.year===i.year?o.title=`${r.formatDate(a.date,"MMM")} - ${r.formatDate(i.date,"MMM YYYY")}`:o.title=`${r.formatDate(a.date,"MMM YYYY")} - ${r.formatDate(i.date,"MMM YYYY")}`}),s}function bA(e,t){return e.days.map(n=>({label:t.formatDate(n.date,t.masks.weekdays),weekday:n.weekday}))}function wA(e,t){return`${t}.${Oe(e,2)}`}function Jm(e,t,n){return Gm(n.getDateParts(n.toDate(e)),pA[t])}function Xm({day:e,week:t,month:n,year:r},s,o,a){if(o==="daily"&&e){const i=new Date(r,n-1,e),l=ht(i,s);return{day:l.getDate(),month:l.getMonth()+1,year:l.getFullYear()}}else if(o==="weekly"&&t){const l=a.getMonthParts(n,r).firstDayOfMonth,u=ht(l,(t-1+s)*7),c=a.getDateParts(u);return{week:c.week,month:c.month,year:c.year}}else{const i=new Date(r,n-1,1),l=pa(i,s);return{month:l.getMonth()+1,year:l.getFullYear()}}}function sn(e){return e!=null&&e.month!=null&&e.year!=null}function pl(e,t){return!sn(e)||!sn(t)?!1:(e=e,t=t,e.year!==t.year?e.yeart.year:e.month&&t.month&&e.month!==t.month?e.month>t.month:e.week&&t.week&&e.week!==t.week?e.week>t.week:e.day&&t.day&&e.day!==t.day?e.day>t.day:!1)}function _A(e,t,n){return(e||!1)&&!pl(e,t)&&!ga(e,n)}function DA(e,t){return!e&&t||e&&!t?!1:!e&&!t?!0:(e=e,t=t,e.year===t.year&&e.month===t.month&&e.week===t.week&&e.day===t.day)}function CA(e,t,n,r){if(!sn(e)||!sn(t))return[];const s=[];for(;!ga(e,t);)s.push(e),e=Xm(e,1,n,r);return s}function Qm(e){const{day:t,week:n,month:r,year:s}=e;let o=`${s}-${Oe(r,2)}`;return n&&(o=`${o}-w${n}`),t&&(o=`${o}-${Oe(t,2)}`),o}function SA(e,t){const{month:n,year:r,showWeeknumbers:s,showIsoWeeknumbers:o}=e,a=new Date(r,n-1,15),i=t.getMonthParts(n,r),l=t.getPrevMonthParts(n,r),u=t.getNextMonthParts(n,r),c=gA({monthComps:i,prevMonthComps:l,nextMonthComps:u},t),f=yA(c,s,o,t),d=bA(f[0],t);return{id:Qm(e),month:n,year:r,monthTitle:t.formatDate(a,t.masks.title),shortMonthLabel:t.formatDate(a,"MMM"),monthLabel:t.formatDate(a,"MMMM"),shortYearLabel:r.toString().substring(2),yearLabel:r.toString(),monthComps:i,prevMonthComps:l,nextMonthComps:u,days:c,weeks:f,weekdays:d}}function $A(e,t){const{day:n,week:r,view:s,trimWeeks:o}=e,a={...t,...e,title:"",viewDays:[],viewWeeks:[]};switch(s){case"daily":{let i=a.days.find(u=>u.inMonth);n?i=a.days.find(u=>u.day===n&&u.inMonth)||i:r&&(i=a.days.find(u=>u.week===r&&u.inMonth));const l=a.weeks[i.week-1];a.viewWeeks=[l],a.viewDays=[i],a.week=i.week,a.weekTitle=l.title,a.day=i.day,a.dayTitle=i.ariaLabel,a.title=a.dayTitle;break}case"weekly":{a.week=r||1;const i=a.weeks[a.week-1];a.viewWeeks=[i],a.viewDays=i.days,a.weekTitle=i.title,a.title=a.weekTitle;break}default:{a.title=a.monthTitle,a.viewWeeks=a.weeks.slice(0,o?a.monthComps.numWeeks:void 0),a.viewDays=a.days;break}}return a}class Ed{constructor(t,n,r){se(this,"keys",[]),se(this,"store",{}),this.size=t,this.createKey=n,this.createItem=r}get(...t){const n=this.createKey(...t);return this.store[n]}getOrSet(...t){const n=this.createKey(...t);if(this.store[n])return this.store[n];const r=this.createItem(...t);if(this.keys.length>=this.size){const s=this.keys.shift();s!=null&&delete this.store[s]}return this.keys.push(n),this.store[n]=r,r}}class jr{constructor(t,n=new ya){se(this,"order"),se(this,"locale"),se(this,"start",null),se(this,"end",null),se(this,"repeat",null);var r;this.locale=n;const{start:s,end:o,span:a,order:i,repeat:l}=t;Hr(s)&&(this.start=n.getDateParts(s)),Hr(o)?this.end=n.getDateParts(o):this.start!=null&&a&&(this.end=n.getDateParts(ht(this.start.date,a-1))),this.order=i??0,l&&(this.repeat=new ba({from:(r=this.start)==null?void 0:r.date,...l},{locale:this.locale}))}static fromMany(t,n){return(Bt(t)?t:[t]).filter(r=>r).map(r=>jr.from(r,n))}static from(t,n){if(t instanceof jr)return t;const r={start:null,end:null};return t!=null&&(Bt(t)?(r.start=t[0]??null,r.end=t[1]??null):bn(t)?Object.assign(r,t):(r.start=t,r.end=t)),r.start!=null&&(r.start=new Date(r.start)),r.end!=null&&(r.end=new Date(r.end)),new jr(r,n)}get opts(){const{order:t,locale:n}=this;return{order:t,locale:n}}get hasRepeat(){return!!this.repeat}get isSingleDay(){const{start:t,end:n}=this;return t&&n&&t.year===n.year&&t.month===n.month&&t.day===n.day}get isMultiDay(){return!this.isSingleDay}get daySpan(){return this.start==null||this.end==null?this.hasRepeat?1:1/0:this.end.dayIndex-this.start.dayIndex}startsOnDay(t){var n,r;return((n=this.start)==null?void 0:n.dayIndex)===t.dayIndex||!!((r=this.repeat)!=null&&r.passes(t))}intersectsDay(t){return this.intersectsDayRange(t,t)}intersectsRange(t){var n,r;return this.intersectsDayRange(((n=t.start)==null?void 0:n.dayIndex)??-1/0,((r=t.end)==null?void 0:r.dayIndex)??1/0)}intersectsDayRange(t,n){return!(this.start&&this.start.dayIndex>n||this.end&&this.end.dayIndex{var d,h;if(n.startsOnDay(f)){const v=n.daySpan<1/0?n.daySpan:1;l={startDay:f.dayIndex,startTime:((d=n.start)==null?void 0:d.time)??0,endDay:f.dayIndex+v-1,endTime:((h=n.end)==null?void 0:h.time)??Vo},this.getRangeRecords(t).push(l)}}):n.intersectsDayRange(u,c)&&(l={startDay:((s=n.start)==null?void 0:s.dayIndex)??-1/0,startTime:((o=n.start)==null?void 0:o.time)??-1/0,endDay:((a=n.end)==null?void 0:a.dayIndex)??1/0,endTime:((i=n.end)==null?void 0:i.time)??1/0},this.getRangeRecords(t).push(l)),l}getRangeRecords(t){let n=this.records[t.key];return n||(n={ranges:[],data:t},this.records[t.key]=n),n.ranges}getCell(t,n){return this.getCells(n).find(o=>o.data.key===t)}cellExists(t,n){const r=this.records[t];return r==null?!1:r.ranges.some(s=>s.startDay<=n&&s.endDay>=n)}getCells(t){const n=Object.values(this.records),r=[],{dayIndex:s}=t;return n.forEach(({data:o,ranges:a})=>{a.filter(i=>i.startDay<=s&&i.endDay>=s).forEach(i=>{const l=s===i.startDay,u=s===i.endDay,c=l?i.startTime:0,f=new Date(t.startDate.getTime()+c),d=u?i.endTime:Vo,h=new Date(t.endDate.getTime()+d),v=c===0&&d===Vo,m=o.order||0;r.push({...i,data:o,onStart:l,onEnd:u,startTime:c,startDate:f,endTime:d,endDate:h,allDay:v,order:m})})}),r.sort((o,a)=>o.order-a.order),r}}const wn={ar:{dow:7,L:"D/‏M/‏YYYY"},bg:{dow:2,L:"D.MM.YYYY"},ca:{dow:2,L:"DD/MM/YYYY"},"zh-CN":{dow:2,L:"YYYY/MM/DD"},"zh-TW":{dow:1,L:"YYYY/MM/DD"},hr:{dow:2,L:"DD.MM.YYYY"},cs:{dow:2,L:"DD.MM.YYYY"},da:{dow:2,L:"DD.MM.YYYY"},nl:{dow:2,L:"DD-MM-YYYY"},"en-US":{dow:1,L:"MM/DD/YYYY"},"en-AU":{dow:2,L:"DD/MM/YYYY"},"en-CA":{dow:1,L:"YYYY-MM-DD"},"en-GB":{dow:2,L:"DD/MM/YYYY"},"en-IE":{dow:2,L:"DD-MM-YYYY"},"en-NZ":{dow:2,L:"DD/MM/YYYY"},"en-ZA":{dow:1,L:"YYYY/MM/DD"},eo:{dow:2,L:"YYYY-MM-DD"},et:{dow:2,L:"DD.MM.YYYY"},fi:{dow:2,L:"DD.MM.YYYY"},fr:{dow:2,L:"DD/MM/YYYY"},"fr-CA":{dow:1,L:"YYYY-MM-DD"},"fr-CH":{dow:2,L:"DD.MM.YYYY"},de:{dow:2,L:"DD.MM.YYYY"},he:{dow:1,L:"DD.MM.YYYY"},id:{dow:2,L:"DD/MM/YYYY"},it:{dow:2,L:"DD/MM/YYYY"},ja:{dow:1,L:"YYYY年M月D日"},ko:{dow:1,L:"YYYY.MM.DD"},lv:{dow:2,L:"DD.MM.YYYY"},lt:{dow:2,L:"DD.MM.YYYY"},mk:{dow:2,L:"D.MM.YYYY"},nb:{dow:2,L:"D. MMMM YYYY"},nn:{dow:2,L:"D. MMMM YYYY"},pl:{dow:2,L:"DD.MM.YYYY"},pt:{dow:2,L:"DD/MM/YYYY"},ro:{dow:2,L:"DD.MM.YYYY"},ru:{dow:2,L:"DD.MM.YYYY"},sk:{dow:2,L:"DD.MM.YYYY"},"es-ES":{dow:2,L:"DD/MM/YYYY"},"es-MX":{dow:2,L:"DD/MM/YYYY"},sv:{dow:2,L:"YYYY-MM-DD"},th:{dow:1,L:"DD/MM/YYYY"},tr:{dow:2,L:"DD.MM.YYYY"},uk:{dow:2,L:"DD.MM.YYYY"},vi:{dow:2,L:"DD/MM/YYYY"}};wn.en=wn["en-US"];wn.es=wn["es-ES"];wn.no=wn.nb;wn.zh=wn["zh-CN"];const EA=Object.entries(wn).reduce((e,[t,{dow:n,L:r}])=>(e[t]={id:t,firstDayOfWeek:n,masks:{L:r}},e),{}),OA="MMMM YYYY",MA="W",kA="MMM",xA="h A",PA=["L","YYYY-MM-DD","YYYY/MM/DD"],AA=["L h:mm A","YYYY-MM-DD h:mm A","YYYY/MM/DD h:mm A"],IA=["L HH:mm","YYYY-MM-DD HH:mm","YYYY/MM/DD HH:mm"],LA=["h:mm A"],RA=["HH:mm"],NA="WWW, MMM D, YYYY",FA=["L","YYYY-MM-DD","YYYY/MM/DD"],YA="iso",BA="YYYY-MM-DDTHH:mm:ss.SSSZ",HA={title:OA,weekdays:MA,navMonths:kA,hours:xA,input:PA,inputDateTime:AA,inputDateTime24hr:IA,inputTime:LA,inputTime24hr:RA,dayPopover:NA,data:FA,model:YA,iso:BA},jA=300,VA=60,WA=80,UA={maxSwipeTime:jA,minHorizontalSwipeDistance:VA,maxVerticalSwipeDistance:WA},zA={componentPrefix:"V",color:"blue",isDark:!1,navVisibility:"click",titlePosition:"center",transition:"slide-h",touch:UA,masks:HA,locales:EA,datePicker:{updateOnInput:!0,inputDebounce:1e3,popover:{visibility:"hover-focus",placement:"bottom-start",isInteractive:!0}}},Vr=je(zA),KA=w(()=>vx(Vr.locales,e=>(e.masks=ts(e.masks,Vr.masks),e))),jn=e=>typeof window<"u"&&zm(window.__vcalendar__,e)?ar(window.__vcalendar__,e):ar(Vr,e),GA=(e,t)=>(e.config.globalProperties.$VCalendar=Vr,Object.assign(Vr,ts(t,Vr))),qA=12,ZA=5;function JA(e,t){const n=new Intl.DateTimeFormat().resolvedOptions().locale;let r;rn(e)?r=e:zm(e,"id")&&(r=e.id),r=(r||n).toLowerCase();const s=Object.keys(t),o=l=>s.find(u=>u.toLowerCase()===l);r=o(r)||o(r.substring(0,2))||n;const a={...t["en-IE"],...t[r],id:r,monthCacheSize:qA,pageCacheSize:ZA};return bn(e)?ts(e,a):a}class ya{constructor(t=void 0,n){se(this,"id"),se(this,"daysInWeek"),se(this,"firstDayOfWeek"),se(this,"masks"),se(this,"timezone"),se(this,"hourLabels"),se(this,"dayNames"),se(this,"dayNamesShort"),se(this,"dayNamesShorter"),se(this,"dayNamesNarrow"),se(this,"monthNames"),se(this,"monthNamesShort"),se(this,"relativeTimeNames"),se(this,"amPm",["am","pm"]),se(this,"monthCache"),se(this,"pageCache");const{id:r,firstDayOfWeek:s,masks:o,monthCacheSize:a,pageCacheSize:i}=JA(t,KA.value);this.monthCache=new Ed(a,bI,wI),this.pageCache=new Ed(i,Qm,SA),this.id=r,this.daysInWeek=nt,this.firstDayOfWeek=xP(s,1,nt),this.masks=o,this.timezone=n||void 0,this.hourLabels=this.getHourLabels(),this.dayNames=ki("long",this.id),this.dayNamesShort=ki("short",this.id),this.dayNamesShorter=this.dayNamesShort.map(l=>l.substring(0,2)),this.dayNamesNarrow=ki("narrow",this.id),this.monthNames=Ad("long",this.id),this.monthNamesShort=Ad("short",this.id),this.relativeTimeNames=CI(this.id)}formatDate(t,n){return OI(t,n,this)}parseDate(t,n){return Id(t,n,this)}toDate(t,n={}){const r=new Date(NaN);let s=r;const{fillDate:o,mask:a,patch:i,rules:l}=n;if(Kt(t)?(n.type="number",s=new Date(+t)):rn(t)?(n.type="string",s=t?Id(t,a||"iso",this):r):Hr(t)?(n.type="date",s=new Date(t.getTime())):xu(t)&&(n.type="object",s=this.getDateFromParts(t)),s&&(i||l)){let u=this.getDateParts(s);if(i&&o!=null){const c=this.getDateParts(this.toDate(o));u=this.getDateParts(this.toDate({...c,...Gm(u,uI[i])}))}l&&(u=EI(u,l)),s=this.getDateFromParts(u)}return s||r}toDateOrNull(t,n={}){const r=this.toDate(t,n);return isNaN(r.getTime())?null:r}fromDate(t,{type:n,mask:r}={}){switch(n){case"number":return t?t.getTime():NaN;case"string":return t?this.formatDate(t,r||"iso"):"";case"object":return t?this.getDateParts(t):null;default:return t?new Date(t):null}}range(t){return jr.from(t,this)}ranges(t){return jr.fromMany(t,this)}getDateParts(t){return yI(t,this)}getDateFromParts(t){return cp(t,this.timezone)}getDateFromParams(t,n,r,s,o,a,i){return this.getDateFromParts({year:t,month:n,day:r,hours:s,minutes:o,seconds:a,milliseconds:i})}getPage(t){const n=this.pageCache.getOrSet(t,this);return $A(t,n)}getMonthParts(t,n){const{firstDayOfWeek:r}=this;return this.monthCache.getOrSet(t,n,r)}getThisMonthParts(){const t=new Date;return this.getMonthParts(t.getMonth()+1,t.getFullYear())}getPrevMonthParts(t,n){return t===1?this.getMonthParts(12,n-1):this.getMonthParts(t-1,n)}getNextMonthParts(t,n){return t===12?this.getMonthParts(1,n+1):this.getMonthParts(t+1,n)}getHourLabels(){return DI().map(t=>this.formatDate(t,this.masks.hours))}getDayId(t){return this.formatDate(t,"YYYY-MM-DD")}}var kr=(e=>(e.Any="any",e.All="all",e))(kr||{}),ep=(e=>(e.Days="days",e.Weeks="weeks",e.Months="months",e.Years="years",e))(ep||{}),tp=(e=>(e.Days="days",e.Weekdays="weekdays",e.Weeks="weeks",e.Months="months",e.Years="years",e))(tp||{}),np=(e=>(e.OrdinalWeekdays="ordinalWeekdays",e))(np||{});class XA{constructor(t,n,r){se(this,"validated",!0),this.type=t,this.interval=n,this.from=r,this.from||(console.error('A valid "from" date is required for date interval rule. This rule will be skipped.'),this.validated=!1)}passes(t){if(!this.validated)return!0;const{date:n}=t;switch(this.type){case"days":return Pu(this.from.date,n)%this.interval===0;case"weeks":return pI(this.from.date,n)%this.interval===0;case"months":return gI(this.from.date,n)%this.interval===0;case"years":return up(this.from.date,n)%this.interval===0;default:return!1}}}class hs{constructor(t,n,r,s){se(this,"components",[]),this.type=t,this.validator=r,this.getter=s,this.components=this.normalizeComponents(n)}static create(t,n){switch(t){case"days":return new QA(n);case"weekdays":return new eI(n);case"weeks":return new tI(n);case"months":return new nI(n);case"years":return new rI(n)}}normalizeComponents(t){if(this.validator(t))return[t];if(!Bt(t))return[];const n=[];return t.forEach(r=>{if(!this.validator(r)){console.error(`Component value ${r} in invalid for "${this.type}" rule. This rule will be skipped.`);return}n.push(r)}),n}passes(t){return this.getter(t).some(s=>this.components.includes(s))}}class QA extends hs{constructor(t){super("days",t,aI,({day:n,dayFromEnd:r})=>[n,-r])}}class eI extends hs{constructor(t){super("weekdays",t,gl,({weekday:n})=>[n])}}class tI extends hs{constructor(t){super("weeks",t,iI,({week:n,weekFromEnd:r})=>[n,-r])}}class nI extends hs{constructor(t){super("months",t,lI,({month:n})=>[n])}}class rI extends hs{constructor(t){super("years",t,Kt,({year:n})=>[n])}}class sI{constructor(t,n){se(this,"components"),this.type=t,this.components=this.normalizeComponents(n)}normalizeArrayConfig(t){const n=[];return t.forEach((r,s)=>{if(Kt(r)){if(s===0)return;if(!Od(t[0])){console.error(`Ordinal range for "${this.type}" rule is from -5 to -1 or 1 to 5. This rule will be skipped.`);return}if(!gl(r)){console.error(`Acceptable range for "${this.type}" rule is from 1 to 5. This rule will be skipped`);return}n.push([t[0],r])}else Bt(r)&&n.push(...this.normalizeArrayConfig(r))}),n}normalizeComponents(t){const n=[];return t.forEach((r,s)=>{if(Kt(r)){if(s===0)return;if(!Od(t[0])){console.error(`Ordinal range for "${this.type}" rule is from -5 to -1 or 1 to 5. This rule will be skipped.`);return}if(!gl(r)){console.error(`Acceptable range for "${this.type}" rule is from 1 to 5. This rule will be skipped`);return}n.push([t[0],r])}else Bt(r)&&n.push(...this.normalizeArrayConfig(r))}),n}passes(t){const{weekday:n,weekdayOrdinal:r,weekdayOrdinalFromEnd:s}=t;return this.components.some(([o,a])=>(o===r||o===-s)&&n===a)}}class oI{constructor(t){se(this,"type","function"),se(this,"validated",!0),this.fn=t,Dr(t)||(console.error("The function rule requires a valid function. This rule will be skipped."),this.validated=!1)}passes(t){return this.validated?this.fn(t):!0}}class ba{constructor(t,n={},r){se(this,"validated",!0),se(this,"config"),se(this,"type",kr.Any),se(this,"from"),se(this,"until"),se(this,"rules",[]),se(this,"locale",new ya),this.parent=r,n.locale&&(this.locale=n.locale),this.config=t,Dr(t)?(this.type=kr.All,this.rules=[new oI(t)]):Bt(t)?(this.type=kr.Any,this.rules=t.map(s=>new ba(s,n,this))):bn(t)?(this.type=kr.All,this.from=t.from?this.locale.getDateParts(t.from):r?.from,this.until=t.until?this.locale.getDateParts(t.until):r?.until,this.rules=this.getObjectRules(t)):(console.error("Rule group configuration must be an object or an array."),this.validated=!1)}getObjectRules(t){const n=[];if(t.every&&(rn(t.every)&&(t.every=[1,`${t.every}s`]),Bt(t.every))){const[r=1,s=ep.Days]=t.every;n.push(new XA(s,r,this.from))}return Object.values(tp).forEach(r=>{r in t&&n.push(hs.create(r,t[r]))}),Object.values(np).forEach(r=>{r in t&&n.push(new sI(r,t[r]))}),t.on!=null&&(Bt(t.on)||(t.on=[t.on]),n.push(new ba(t.on,{locale:this.locale},this.parent))),n}passes(t){return this.validated?this.from&&t.dayIndex<=this.from.dayIndex||this.until&&t.dayIndex>=this.until.dayIndex?!1:this.type===kr.Any?this.rules.some(n=>n.passes(t)):this.rules.every(n=>n.passes(t)):!0}}function aI(e){return Kt(e)?e>=1&&e<=31:!1}function gl(e){return Kt(e)?e>=1&&e<=7:!1}function iI(e){return Kt(e)?e>=-6&&e<=-1||e>=1&&e<=6:!1}function lI(e){return Kt(e)?e>=1&&e<=12:!1}function Od(e){return!(!Kt(e)||e<-5||e>5||e===0)}const uI={dateTime:["year","month","day","hours","minutes","seconds","milliseconds"],date:["year","month","day"],time:["hours","minutes","seconds","milliseconds"]},nt=7,cI=6,rp=1e3,sp=rp*60,op=sp*60,Vo=op*24,fI=[31,28,31,30,31,30,31,31,30,31,30,31],dI=["L","iso"],Es={milliseconds:[0,999,3],seconds:[0,59,2],minutes:[0,59,2],hours:[0,23,2]},ap=/d{1,2}|W{1,4}|M{1,4}|YY(?:YY)?|S{1,3}|Do|Z{1,4}|([HhMsDm])\1?|[aA]|"[^"]*"|'[^']*'/g,hI=/\[([^]*?)\]/gm,Md={D(e){return e.day},DD(e){return Oe(e.day,2)},d(e){return e.weekday-1},dd(e){return Oe(e.weekday-1,2)},W(e,t){return t.dayNamesNarrow[e.weekday-1]},WW(e,t){return t.dayNamesShorter[e.weekday-1]},WWW(e,t){return t.dayNamesShort[e.weekday-1]},WWWW(e,t){return t.dayNames[e.weekday-1]},M(e){return e.month},MM(e){return Oe(e.month,2)},MMM(e,t){return t.monthNamesShort[e.month-1]},MMMM(e,t){return t.monthNames[e.month-1]},YY(e){return String(e.year).substr(2)},YYYY(e){return Oe(e.year,4)},h(e){return e.hours%12||12},hh(e){return Oe(e.hours%12||12,2)},H(e){return e.hours},HH(e){return Oe(e.hours,2)},m(e){return e.minutes},mm(e){return Oe(e.minutes,2)},s(e){return e.seconds},ss(e){return Oe(e.seconds,2)},S(e){return Math.round(e.milliseconds/100)},SS(e){return Oe(Math.round(e.milliseconds/10),2)},SSS(e){return Oe(e.milliseconds,3)},a(e,t){return e.hours<12?t.amPm[0]:t.amPm[1]},A(e,t){return e.hours<12?t.amPm[0].toUpperCase():t.amPm[1].toUpperCase()},Z(){return"Z"},ZZ(e){const t=e.timezoneOffset;return`${t>0?"-":"+"}${Oe(Math.floor(Math.abs(t)/60),2)}`},ZZZ(e){const t=e.timezoneOffset;return`${t>0?"-":"+"}${Oe(Math.floor(Math.abs(t)/60)*100+Math.abs(t)%60,4)}`},ZZZZ(e){const t=e.timezoneOffset;return`${t>0?"-":"+"}${Oe(Math.floor(Math.abs(t)/60),2)}:${Oe(Math.abs(t)%60,2)}`}},On=/\d\d?/,vI=/\d{3}/,mI=/\d{4}/,Ds=/[0-9]*['a-z\u00A0-\u05FF\u0700-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF]+|[\u0600-\u06FF/]+(\s*?[\u0600-\u06FF]+){1,2}/i,kd=()=>{},xd=e=>(t,n,r)=>{const s=r[e].indexOf(n.charAt(0).toUpperCase()+n.substr(1).toLowerCase());~s&&(t.month=s)},ke={D:[On,(e,t)=>{e.day=t}],Do:[new RegExp(On.source+Ds.source),(e,t)=>{e.day=parseInt(t,10)}],d:[On,kd],W:[Ds,kd],M:[On,(e,t)=>{e.month=t-1}],MMM:[Ds,xd("monthNamesShort")],MMMM:[Ds,xd("monthNames")],YY:[On,(e,t)=>{const r=+new Date().getFullYear().toString().substr(0,2);e.year=+`${t>68?r-1:r}${t}`}],YYYY:[mI,(e,t)=>{e.year=t}],S:[/\d/,(e,t)=>{e.milliseconds=t*100}],SS:[/\d{2}/,(e,t)=>{e.milliseconds=t*10}],SSS:[vI,(e,t)=>{e.milliseconds=t}],h:[On,(e,t)=>{e.hours=t}],m:[On,(e,t)=>{e.minutes=t}],s:[On,(e,t)=>{e.seconds=t}],a:[Ds,(e,t,n)=>{const r=t.toLowerCase();r===n.amPm[0]?e.isPm=!1:r===n.amPm[1]&&(e.isPm=!0)}],Z:[/[^\s]*?[+-]\d\d:?\d\d|[^\s]*?Z?/,(e,t)=>{t==="Z"&&(t="+00:00");const n=`${t}`.match(/([+-]|\d\d)/gi);if(n){const r=+n[1]*60+parseInt(n[2],10);e.timezoneOffset=n[0]==="+"?r:-r}}]};ke.DD=ke.D;ke.dd=ke.d;ke.WWWW=ke.WWW=ke.WW=ke.W;ke.MM=ke.M;ke.mm=ke.m;ke.hh=ke.H=ke.HH=ke.h;ke.ss=ke.s;ke.A=ke.a;ke.ZZZZ=ke.ZZZ=ke.ZZ=ke.Z;function ip(e,t){return(mn(e)&&e||[rn(e)&&e||"YYYY-MM-DD"]).map(n=>dI.reduce((r,s)=>r.replace(s,t.masks[s]||""),n))}function xu(e){return bn(e)&&"year"in e&&"month"in e&&"day"in e}function Pd(e,t=1){const n=e.getDay()+1,r=n>=t?t-n:-(7-(t-n));return ht(e,r)}function lp(e,t,n){const r=Date.UTC(e,t-1,n);return Pu(new Date(0),new Date(r))}function Pu(e,t){return Math.round((t.getTime()-e.getTime())/Vo)}function pI(e,t){return Math.ceil(Pu(Pd(e),Pd(t))/7)}function up(e,t){return t.getUTCFullYear()-e.getUTCFullYear()}function gI(e,t){return up(e,t)*12+(t.getMonth()-e.getMonth())}function cp(e,t=""){const n=new Date,{year:r=n.getFullYear(),month:s=n.getMonth()+1,day:o=n.getDate(),hours:a=0,minutes:i=0,seconds:l=0,milliseconds:u=0}=e;if(t){const c=`${Oe(r,4)}-${Oe(s,2)}-${Oe(o,2)}T${Oe(a,2)}:${Oe(i,2)}:${Oe(l,2)}.${Oe(u,3)}`;return GP(c,{timeZone:t})}return new Date(r,s-1,o,a,i,l,u)}function yI(e,t){let n=new Date(e.getTime());t.timezone&&(n=new Date(e.toLocaleString("en-US",{timeZone:t.timezone})),n.setMilliseconds(e.getMilliseconds()));const r=n.getMilliseconds(),s=n.getSeconds(),o=n.getMinutes(),a=n.getHours(),i=r+s*rp+o*sp+a*op,l=n.getMonth()+1,u=n.getFullYear(),c=t.getMonthParts(l,u),f=n.getDate(),d=c.numDays-f+1,h=n.getDay()+1,v=Math.floor((f-1)/7+1),m=Math.floor((c.numDays-f)/7+1),p=Math.ceil((f+Math.abs(c.firstWeekday-c.firstDayOfWeek))/7),b=c.numWeeks-p+1,S=c.weeknumbers[p],T=lp(u,l,f);return{milliseconds:r,seconds:s,minutes:o,hours:a,time:i,day:f,dayFromEnd:d,weekday:h,weekdayOrdinal:v,weekdayOrdinalFromEnd:m,week:p,weekFromEnd:b,weeknumber:S,month:l,year:u,date:n,dateTime:n.getTime(),dayIndex:T,timezoneOffset:0,isValid:!0}}function bI(e,t,n){return`${t}-${e}-${n}`}function wI(e,t,n){const r=t%4===0&&t%100!==0||t%400===0,s=new Date(t,e-1,1),o=s.getDay()+1,a=e===2&&r?29:fI[e-1],i=n-1,l=iA(s,{weekStartsOn:i}),u=[],c=[];for(let f=0;fn.format(r))}function DI(){const e=[];for(let t=0;t<=24;t++)e.push(new Date(2e3,0,1,t));return e}function CI(e=void 0){const t=["second","minute","hour","day","week","month","quarter","year"],n=new Intl.RelativeTimeFormat(e);return t.reduce((r,s)=>{const o=n.formatToParts(100,s);return r[s]=o[1].unit,r},{})}function fp(){const e=[];for(let t=0;t<12;t++)e.push(new Date(2e3,t,15));return e}function Ad(e,t=void 0){const n=new Intl.DateTimeFormat(t,{month:e,timeZone:"UTC"});return fp().map(r=>n.format(r))}function SI(e,t,n){return Kt(t)?t===e:Bt(t)?t.includes(e):Dr(t)?t(e,n):!(t.min!=null&&t.min>e||t.max!=null&&t.max{if(i.disabled)return a;if(isNaN(a))return i.value;const l=Math.abs(a-n);return Math.abs(i.value-n){const o=Es[r],a=e[r];n[r]=TI(e,o,a,s)}),n}function Id(e,t,n){return ip(t,n).map(s=>{if(typeof s!="string")throw new Error("Invalid mask");let o=e;if(o.length>1e3)return!1;let a=!0;const i={};if(s.replace(ap,c=>{if(ke[c]){const f=ke[c],d=o.search(f[0]);~d?o.replace(f[0],h=>(f[1](i,h,n),o=o.substr(d+h.length),h)):a=!1}return ke[c]?"":c.slice(1,c.length-1)}),!a)return!1;const l=new Date;i.hours!=null&&(i.isPm===!0&&+i.hours!=12?i.hours=+i.hours+12:i.isPm===!1&&+i.hours==12&&(i.hours=0));let u;return i.timezoneOffset!=null?(i.minutes=+(i.minutes||0)-+i.timezoneOffset,u=new Date(Date.UTC(i.year||l.getFullYear(),i.month||0,i.day||1,i.hours||0,i.minutes||0,i.seconds||0,i.milliseconds||0))):u=n.getDateFromParts({year:i.year||l.getFullYear(),month:(i.month||0)+1,day:i.day||1,hours:i.hours||0,minutes:i.minutes||0,seconds:i.seconds||0,milliseconds:i.milliseconds||0}),u}).find(s=>s)||new Date(e)}function OI(e,t,n){if(e==null)return"";let r=ip(t,n)[0];/Z$/.test(r)&&(n.timezone="utc");const s=[];r=r.replace(hI,(a,i)=>(s.push(i),"??"));const o=n.getDateParts(e);return r=r.replace(ap,a=>a in Md?Md[a](o,n):a.slice(1,a.length-1)),r.replace(/\?\?/g,()=>s.shift())}let MI=0;class dp{constructor(t,n,r){se(this,"key",""),se(this,"hashcode",""),se(this,"highlight",null),se(this,"content",null),se(this,"dot",null),se(this,"bar",null),se(this,"event",null),se(this,"popover",null),se(this,"customData",null),se(this,"ranges"),se(this,"hasRanges",!1),se(this,"order",0),se(this,"pinPage",!1),se(this,"maxRepeatSpan",0),se(this,"locale");const{dates:s}=Object.assign(this,{hashcode:"",order:0,pinPage:!1},t);this.key||(this.key=++MI),this.locale=r,n.normalizeGlyphs(this),this.ranges=r.ranges(s??[]),this.hasRanges=!!mn(this.ranges),this.maxRepeatSpan=this.ranges.filter(o=>o.hasRepeat).map(o=>o.daySpan).reduce((o,a)=>Math.max(o,a),0)}intersectsRange({start:t,end:n}){if(t==null||n==null)return!1;const r=this.ranges.filter(a=>!a.hasRepeat);for(const a of r)if(a.intersectsDayRange(t.dayIndex,n.dayIndex))return!0;const s=this.ranges.filter(a=>a.hasRepeat);if(!s.length)return!1;let o=t;for(this.maxRepeatSpan>1&&(o=this.locale.getDateParts(ht(o.date,-this.maxRepeatSpan)));o.dayIndex<=n.dayIndex;){for(const a of s)if(a.startsOnDay(o))return!0;o=this.locale.getDateParts(ht(o.date,1))}return!1}}function yl(e){document&&document.dispatchEvent(new CustomEvent("show-popover",{detail:e}))}function Js(e){document&&document.dispatchEvent(new CustomEvent("hide-popover",{detail:e}))}function hp(e){document&&document.dispatchEvent(new CustomEvent("toggle-popover",{detail:e}))}function vp(e){const{visibility:t}=e,n=t==="click",r=t==="hover",s=t==="hover-focus",o=t==="focus";e.autoHide=!n;let a=!1,i=!1;const l=v=>{n&&(hp({...e,target:e.target||v.currentTarget}),v.stopPropagation())},u=v=>{a||(a=!0,(r||s)&&yl({...e,target:e.target||v.currentTarget}))},c=()=>{a&&(a=!1,(r||s&&!i)&&Js(e))},f=v=>{i||(i=!0,(o||s)&&yl({...e,target:e.target||v.currentTarget}))},d=v=>{i&&!Ho(v.currentTarget,v.relatedTarget)&&(i=!1,(o||s&&!a)&&Js(e))},h={};switch(e.visibility){case"click":h.click=l;break;case"hover":h.mousemove=u,h.mouseleave=c;break;case"focus":h.focusin=f,h.focusout=d;break;case"hover-focus":h.mousemove=u,h.mouseleave=c,h.focusin=f,h.focusout=d;break}return h}const Ld=e=>{const t=da(e);if(t==null)return;const n=t.popoverHandlers;!n||!n.length||(n.forEach(r=>r()),delete t.popoverHandlers)},Rd=(e,t)=>{const n=da(e);if(n==null)return;const r=[],s=vp(t);Object.entries(s).forEach(([o,a])=>{r.push(Nn(n,o,a))}),n.popoverHandlers=r},mp={mounted(e,t){const{value:n}=t;n&&Rd(e,n)},updated(e,t){const{oldValue:n,value:r}=t,s=n?.visibility,o=r?.visibility;s!==o&&(s&&(Ld(e),o||Js(n)),o&&Rd(e,r))},unmounted(e){Ld(e)}},kI=(e,t,{maxSwipeTime:n,minHorizontalSwipeDistance:r,maxVerticalSwipeDistance:s})=>{if(!e||!e.addEventListener||!Dr(t))return null;let o=0,a=0,i=null,l=!1;function u(f){const d=f.changedTouches[0];o=d.screenX,a=d.screenY,i=new Date().getTime(),l=!0}function c(f){if(!l||!i)return;l=!1;const d=f.changedTouches[0],h=d.screenX-o,v=d.screenY-a;if(new Date().getTime()-i=r&&Math.abs(v)<=s){const p={toLeft:!1,toRight:!1};h<0?p.toLeft=!0:p.toRight=!0,t(p)}}return Nn(e,"touchstart",u,{passive:!0}),Nn(e,"touchend",c,{passive:!0}),()=>{Rn(e,"touchstart",u),Rn(e,"touchend",c)}},Wo={},xI=(e,t=10)=>{Wo[e]=Date.now()+t},PI=(e,t)=>{if(e in Wo){const n=Wo[e];if(Date.now()t.value?"dark":"light");let r,s;function o(h){t.value=h.matches}function a(){AI("matchMedia")&&(r=window.matchMedia("(prefers-color-scheme: dark)"),r.addEventListener("change",o),t.value=r.matches)}function i(){const{selector:h=":root",darkClass:v="dark"}=e.value,m=document.querySelector(h);t.value=m.classList.contains(v)}function l(h){const{selector:v=":root",darkClass:m="dark"}=h;if(pp()&&v&&m){const p=document.querySelector(v);p&&(s=new MutationObserver(i),s.observe(p,{attributes:!0,attributeFilter:["class"]}),t.value=p.classList.contains(m))}}function u(){f();const h=typeof e.value;h==="string"&&e.value.toLowerCase()==="system"?a():h==="object"?l(e.value):t.value=!!e.value}const c=Te(()=>e.value,()=>u(),{immediate:!0});function f(){r&&(r.removeEventListener("change",o),r=void 0),s&&(s.disconnect(),s=void 0)}function d(){f(),c()}return ss(()=>d()),{isDark:t,displayMode:n,cleanup:d}}const LI=["base","start","end","startEnd"],RI=["class","wrapperClass","contentClass","style","contentStyle","color","fillMode"],NI={base:{},start:{},end:{}};function Au(e,t,n=NI){let r=e,s={};t===!0||rn(t)?(r=rn(t)?t:r,s={...n}):bn(t)&&(pd(t,LI)?s={...t}:s={base:{...t},start:{...t},end:{...t}});const o=ts(s,{start:s.startEnd,end:s.startEnd},n);return Object.entries(o).forEach(([a,i])=>{let l=r;i===!0||rn(i)?(l=rn(i)?i:l,o[a]={color:l}):bn(i)&&(pd(i,RI)?o[a]={...i}:o[a]={}),ts(o[a],{color:l})}),o}class FI{constructor(){se(this,"type","highlight")}normalizeConfig(t,n){return Au(t,n,{base:{fillMode:"light"},start:{fillMode:"solid"},end:{fillMode:"solid"}})}prepareRender(t){t.highlights=[],t.content||(t.content=[])}render({data:t,onStart:n,onEnd:r},s){const{key:o,highlight:a}=t;if(!a)return;const{highlights:i}=s,{base:l,start:u,end:c}=a;n&&r?i.push({...u,key:o,wrapperClass:`vc-day-layer vc-day-box-center-center vc-attr vc-${u.color}`,class:[`vc-highlight vc-highlight-bg-${u.fillMode}`,u.class],contentClass:[`vc-attr vc-highlight-content-${u.fillMode} vc-${u.color}`,u.contentClass]}):n?(i.push({...l,key:`${o}-base`,wrapperClass:`vc-day-layer vc-day-box-right-center vc-attr vc-${l.color}`,class:[`vc-highlight vc-highlight-base-start vc-highlight-bg-${l.fillMode}`,l.class]}),i.push({...u,key:o,wrapperClass:`vc-day-layer vc-day-box-center-center vc-attr vc-${u.color}`,class:[`vc-highlight vc-highlight-bg-${u.fillMode}`,u.class],contentClass:[`vc-attr vc-highlight-content-${u.fillMode} vc-${u.color}`,u.contentClass]})):r?(i.push({...l,key:`${o}-base`,wrapperClass:`vc-day-layer vc-day-box-left-center vc-attr vc-${l.color}`,class:[`vc-highlight vc-highlight-base-end vc-highlight-bg-${l.fillMode}`,l.class]}),i.push({...c,key:o,wrapperClass:`vc-day-layer vc-day-box-center-center vc-attr vc-${c.color}`,class:[`vc-highlight vc-highlight-bg-${c.fillMode}`,c.class],contentClass:[`vc-attr vc-highlight-content-${c.fillMode} vc-${c.color}`,c.contentClass]})):i.push({...l,key:`${o}-middle`,wrapperClass:`vc-day-layer vc-day-box-center-center vc-attr vc-${l.color}`,class:[`vc-highlight vc-highlight-base-middle vc-highlight-bg-${l.fillMode}`,l.class],contentClass:[`vc-attr vc-highlight-content-${l.fillMode} vc-${l.color}`,l.contentClass]})}}class Iu{constructor(t,n){se(this,"type",""),se(this,"collectionType",""),this.type=t,this.collectionType=n}normalizeConfig(t,n){return Au(t,n)}prepareRender(t){t[this.collectionType]=[]}render({data:t,onStart:n,onEnd:r},s){const{key:o}=t,a=t[this.type];if(!o||!a)return;const i=s[this.collectionType],{base:l,start:u,end:c}=a;n?i.push({...u,key:o,class:[`vc-${this.type} vc-${this.type}-start vc-${u.color} vc-attr`,u.class]}):r?i.push({...c,key:o,class:[`vc-${this.type} vc-${this.type}-end vc-${c.color} vc-attr`,c.class]}):i.push({...l,key:o,class:[`vc-${this.type} vc-${this.type}-base vc-${l.color} vc-attr`,l.class]})}}class YI extends Iu{constructor(){super("content","content")}normalizeConfig(t,n){return Au("base",n)}}class BI extends Iu{constructor(){super("dot","dots")}}class HI extends Iu{constructor(){super("bar","bars")}}class jI{constructor(t){se(this,"color"),se(this,"renderers",[new YI,new FI,new BI,new HI]),this.color=t}normalizeGlyphs(t){this.renderers.forEach(n=>{const r=n.type;t[r]!=null&&(t[r]=n.normalizeConfig(this.color,t[r]))})}prepareRender(t={}){return this.renderers.forEach(n=>{n.prepareRender(t)}),t}render(t,n){this.renderers.forEach(r=>{r.render(t,n)})}}const gp=Symbol("__vc_base_context__"),yp={color:{type:String,default:()=>jn("color")},isDark:{type:[Boolean,String,Object],default:()=>jn("isDark")},firstDayOfWeek:Number,masks:Object,locale:[String,Object],timezone:String,minDate:null,maxDate:null,disabledDates:null};function bp(e){const t=w(()=>e.color??""),n=w(()=>e.isDark??!1),{displayMode:r}=II(n),s=w(()=>new jI(t.value)),o=w(()=>{if(e.locale instanceof ya)return e.locale;const d=bn(e.locale)?e.locale:{id:e.locale,firstDayOfWeek:e.firstDayOfWeek,masks:e.masks};return new ya(d,e.timezone)}),a=w(()=>o.value.masks),i=w(()=>e.minDate),l=w(()=>e.maxDate),u=w(()=>{const d=e.disabledDates?[...e.disabledDates]:[];return i.value!=null&&d.push({start:null,end:ht(o.value.toDate(i.value),-1)}),l.value!=null&&d.push({start:ht(o.value.toDate(l.value),1),end:null}),o.value.ranges(d)}),c=w(()=>new dp({key:"disabled",dates:u.value,order:100},s.value,o.value)),f={color:t,isDark:n,displayMode:r,theme:s,locale:o,masks:a,minDate:i,maxDate:l,disabledDates:u,disabledAttribute:c};return Pt(gp,f),f}function VI(e){return Pe(gp,()=>bp(e),!0)}function wp(e){return`__vc_slot_${e}__`}function _p(e,t={}){Object.keys(e).forEach(n=>{Pt(wp(t[n]??n),e[n])})}function Dp(e){return Pe(wp(e),null)}const WI={...yp,view:{type:String,default:"monthly",validator(e){return["daily","weekly","monthly"].includes(e)}},rows:{type:Number,default:1},columns:{type:Number,default:1},step:Number,titlePosition:{type:String,default:()=>jn("titlePosition")},navVisibility:{type:String,default:()=>jn("navVisibility")},showWeeknumbers:[Boolean,String],showIsoWeeknumbers:[Boolean,String],expanded:Boolean,borderless:Boolean,transparent:Boolean,initialPage:Object,initialPagePosition:{type:Number,default:1},minPage:Object,maxPage:Object,transition:String,attributes:Array,trimWeeks:Boolean,disablePageSwipe:Boolean},UI=["dayclick","daymouseenter","daymouseleave","dayfocusin","dayfocusout","daykeydown","weeknumberclick","transition-start","transition-end","did-move","update:view","update:pages"],Cp=Symbol("__vc_calendar_context__");function zI(e,{slots:t,emit:n}){const r=oe(null),s=oe(null),o=oe(new Date().getDate()),a=oe(!1),i=oe(Symbol()),l=oe(Symbol()),u=oe(e.view),c=oe([]),f=oe("");let d=null,h=null;_p(t);const{theme:v,color:m,displayMode:p,locale:b,masks:S,minDate:T,maxDate:M,disabledAttribute:D,disabledDates:C}=VI(e),E=w(()=>e.rows*e.columns),P=w(()=>e.step||E.value),$=w(()=>Um(c.value)??null),I=w(()=>Ar(c.value)??null),j=w(()=>e.minPage||(T.value?Q(T.value):null)),O=w(()=>e.maxPage||(M.value?Q(M.value):null)),W=w(()=>e.navVisibility),re=w(()=>!!e.showWeeknumbers),X=w(()=>!!e.showIsoWeeknumbers),ee=w(()=>u.value==="monthly"),J=w(()=>u.value==="weekly"),ue=w(()=>u.value==="daily"),we=()=>{a.value=!0,n("transition-start")},V=()=>{a.value=!1,n("transition-end"),d&&(d.resolve(!0),d=null)},fe=(N,y,F=u.value)=>Xm(N,y,F,b.value),Q=N=>Jm(N,u.value,b.value),Le=N=>{!D.value||!tt.value||(N.isDisabled=tt.value.cellExists(D.value.key,N.dayIndex))},pe=N=>{N.isFocusable=N.inMonth&&N.day===o.value},Ye=(N,y)=>{for(const F of N)for(const Z of F.days)if(y(Z)===!1)return},Re=w(()=>c.value.reduce((N,y)=>(N.push(...y.viewDays),N),[])),ye=w(()=>{const N=[];return(e.attributes||[]).forEach((y,F)=>{!y||!y.dates||N.push(new dp({...y,order:y.order||0},v.value,b.value))}),D.value&&N.push(D.value),N}),ze=w(()=>mn(ye.value)),tt=w(()=>{const N=new TA;return ye.value.forEach(y=>{y.ranges.forEach(F=>{N.render(y,F,Re.value)})}),N}),lt=w(()=>Re.value.reduce((N,y)=>(N[y.dayIndex]={day:y,cells:[]},N[y.dayIndex].cells.push(...tt.value.getCells(y)),N),{})),mt=(N,y)=>{const F=e.showWeeknumbers||e.showIsoWeeknumbers;return F==null?"":Zk(F)?F?"left":"":F.startsWith("right")?y>1?"right":F:N>1?"left":F},ut=()=>{var N,y;if(!ze.value)return null;const F=ye.value.find(He=>He.pinPage)||ye.value[0];if(!F||!F.hasRanges)return null;const[Z]=F.ranges,he=((N=Z.start)==null?void 0:N.date)||((y=Z.end)==null?void 0:y.date);return he?Q(he):null},g=()=>{if(sn($.value))return $.value;const N=ut();return sn(N)?N:Q(new Date)},_=(N,y={})=>{const{view:F=u.value,position:Z=1,force:he}=y,He=Z>0?1-Z:-(E.value+Z);let ft=fe(N,He,F),$t=fe(ft,E.value-1,F);return he||(pl(ft,j.value)?ft=j.value:ga($t,O.value)&&(ft=fe(O.value,1-E.value)),$t=fe(ft,E.value-1)),{fromPage:ft,toPage:$t}},k=(N,y,F="")=>{if(F==="none"||F==="fade")return F;if(N?.view!==y?.view)return"fade";const Z=ga(y,N),he=pl(y,N);return!Z&&!he?"fade":F==="slide-v"?he?"slide-down":"slide-up":he?"slide-right":"slide-left"},Y=(N={})=>new Promise((y,F)=>{const{position:Z=1,force:he=!1,transition:He}=N,ft=sn(N.page)?N.page:g(),{fromPage:$t}=_(ft,{position:Z,force:he}),$r=[];for(let Tr=0;Tr{const y=$.value??Q(new Date);return fe(y,N)},H=(N,y={})=>{const F=sn(N)?N:Q(N);return Object.assign(y,_(F,{...y,force:!0})),CA(y.fromPage,y.toPage,u.value,b.value).map(he=>_A(he,j.value,O.value)).some(he=>he)},K=(N,y={})=>H(R(N),y),U=w(()=>K(-P.value)),z=w(()=>K(P.value)),B=async(N,y={})=>!y.force&&!H(N,y)?!1:(y.fromPage&&!DA(y.fromPage,$.value)&&(Js({id:i.value,hideDelay:0}),y.view&&(xI("view",10),u.value=y.view),await Y({...y,page:y.fromPage,position:1,force:!0}),n("did-move",c.value)),!0),q=(N,y={})=>B(R(N),y),ne=()=>q(-P.value),te=()=>q(P.value),ie=N=>{const y=ee.value?".in-month":"",F=`.id-${b.value.getDayId(N)}${y}`,Z=`${F}.vc-focusable, ${F} .vc-focusable`,he=r.value;if(he){const He=he.querySelector(Z);if(He)return He.focus(),!0}return!1},de=async(N,y={})=>ie(N)?!0:(await B(N,y),ie(N)),Ce=(N,y)=>{o.value=N.day,n("dayclick",N,y)},_e=(N,y)=>{n("daymouseenter",N,y)},Be=(N,y)=>{n("daymouseleave",N,y)},ct=(N,y)=>{o.value=N.day,s.value=N,N.isFocused=!0,n("dayfocusin",N,y)},Vt=(N,y)=>{s.value=null,N.isFocused=!1,n("dayfocusout",N,y)},Jn=(N,y)=>{n("daykeydown",N,y);const F=N.noonDate;let Z=null;switch(y.key){case"ArrowLeft":{Z=ht(F,-1);break}case"ArrowRight":{Z=ht(F,1);break}case"ArrowUp":{Z=ht(F,-7);break}case"ArrowDown":{Z=ht(F,7);break}case"Home":{Z=ht(F,-N.weekdayPosition+1);break}case"End":{Z=ht(F,N.weekdayPositionFromEnd);break}case"PageUp":{y.altKey?Z=Td(F,-1):Z=pa(F,-1);break}case"PageDown":{y.altKey?Z=Td(F,1):Z=pa(F,1);break}}Z&&(y.preventDefault(),de(Z).catch())},fn=N=>{const y=s.value;y!=null&&Jn(y,N)},Xn=(N,y)=>{n("weeknumberclick",N,y)};Y({page:e.initialPage,position:e.initialPagePosition}),Gt(()=>{!e.disablePageSwipe&&r.value&&(h=kI(r.value,({toLeft:N=!1,toRight:y=!1})=>{N?te():y&&ne()},jn("touch")))}),ss(()=>{c.value=[],h&&h()}),Te(()=>b.value,()=>{Y()}),Te(()=>E.value,()=>Y()),Te(()=>e.view,()=>u.value=e.view),Te(()=>u.value,()=>{PI("view",()=>{Y()}),n("update:view",u.value)}),Te(()=>o.value,()=>{Ye(c.value,N=>pe(N))}),zn(()=>{n("update:pages",c.value),Ye(c.value,N=>{Le(N),pe(N)})});const Je={emit:n,containerRef:r,focusedDay:s,inTransition:a,navPopoverId:i,dayPopoverId:l,view:u,pages:c,transitionName:f,theme:v,color:m,displayMode:p,locale:b,masks:S,attributes:ye,disabledAttribute:D,disabledDates:C,attributeContext:tt,days:Re,dayCells:lt,count:E,step:P,firstPage:$,lastPage:I,canMovePrev:U,canMoveNext:z,minPage:j,maxPage:O,isMonthly:ee,isWeekly:J,isDaily:ue,navVisibility:W,showWeeknumbers:re,showIsoWeeknumbers:X,getDateAddress:Q,canMove:H,canMoveBy:K,move:B,moveBy:q,movePrev:ne,moveNext:te,onTransitionBeforeEnter:we,onTransitionAfterEnter:V,tryFocusDate:ie,focusDate:de,onKeydown:fn,onDayKeydown:Jn,onDayClick:Ce,onDayMouseenter:_e,onDayMouseleave:Be,onDayFocusin:ct,onDayFocusout:Vt,onWeeknumberClick:Xn};return Pt(Cp,Je),Je}function Sr(){const e=Pe(Cp);if(e)return e;throw new Error("Calendar context missing. Please verify this component is nested within a valid context provider.")}const KI=Ze({inheritAttrs:!1,emits:["before-show","after-show","before-hide","after-hide"],props:{id:{type:[Number,String,Symbol],required:!0},showDelay:{type:Number,default:0},hideDelay:{type:Number,default:110},boundarySelector:{type:String}},setup(e,{emit:t}){let n;const r=oe();let s=null,o=null;const a=je({isVisible:!1,target:null,data:null,transition:"slide-fade",placement:"bottom",direction:"",positionFixed:!1,modifiers:[],isInteractive:!0,visibility:"click",isHovered:!1,isFocused:!1,autoHide:!1,force:!1});function i(V){V&&(a.direction=V.split("-")[0])}function l({placement:V,options:fe}){i(V||fe?.placement)}const u=w(()=>({placement:a.placement,strategy:a.positionFixed?"fixed":"absolute",boundary:"",modifiers:[{name:"onUpdate",enabled:!0,phase:"afterWrite",fn:l},...a.modifiers||[]],onFirstUpdate:l})),c=w(()=>{const V=a.direction==="left"||a.direction==="right";let fe="";if(a.placement){const Q=a.placement.split("-");Q.length>1&&(fe=Q[1])}return["start","top","left"].includes(fe)?V?"top":"left":["end","bottom","right"].includes(fe)?V?"bottom":"right":V?"middle":"center"});function f(){o&&(o.destroy(),o=null)}function d(){Ot(()=>{const V=da(a.target);!V||!r.value||(o&&o.state.elements.reference!==V&&f(),o?o.update():o=Y_(V,r.value,u.value))})}function h(V){Object.assign(a,Km(V,"force"))}function v(V,fe){clearTimeout(n),V>0?n=setTimeout(fe,V):fe()}function m(V){return!V||!o?!1:da(V)===o.state.elements.reference}async function p(V={}){a.force||(V.force&&(a.force=!0),v(V.showDelay??e.showDelay,()=>{a.isVisible&&(a.force=!1),h({...V,isVisible:!0}),d()}))}function b(V={}){o&&(V.target&&!m(V.target)||a.force||(V.force&&(a.force=!0),v(V.hideDelay??e.hideDelay,()=>{a.isVisible||(a.force=!1),a.isVisible=!1})))}function S(V={}){V.target!=null&&(a.isVisible&&m(V.target)?b(V):p(V))}function T(V){if(!o)return;const fe=o.state.elements.reference;if(!r.value||!fe)return;const Q=V.target;Ho(r.value,Q)||Ho(fe,Q)||b({force:!0})}function M(V){(V.key==="Esc"||V.key==="Escape")&&b()}function D({detail:V}){!V.id||V.id!==e.id||p(V)}function C({detail:V}){!V.id||V.id!==e.id||b(V)}function E({detail:V}){!V.id||V.id!==e.id||S(V)}function P(){Nn(document,"keydown",M),Nn(document,"click",T),Nn(document,"show-popover",D),Nn(document,"hide-popover",C),Nn(document,"toggle-popover",E)}function $(){Rn(document,"keydown",M),Rn(document,"click",T),Rn(document,"show-popover",D),Rn(document,"hide-popover",C),Rn(document,"toggle-popover",E)}function I(V){t("before-show",V)}function j(V){a.force=!1,t("after-show",V)}function O(V){t("before-hide",V)}function W(V){a.force=!1,f(),t("after-hide",V)}function re(V){V.stopPropagation()}function X(){a.isHovered=!0,a.isInteractive&&["hover","hover-focus"].includes(a.visibility)&&p()}function ee(){if(a.isHovered=!1,!o)return;const V=o.state.elements.reference;a.autoHide&&!a.isFocused&&(!V||V!==document.activeElement)&&["hover","hover-focus"].includes(a.visibility)&&b()}function J(){a.isFocused=!0,a.isInteractive&&["focus","hover-focus"].includes(a.visibility)&&p()}function ue(V){["focus","hover-focus"].includes(a.visibility)&&(!V.relatedTarget||!Ho(r.value,V.relatedTarget))&&(a.isFocused=!1,!a.isHovered&&a.autoHide&&b())}function we(){s!=null&&(s.disconnect(),s=null)}return Te(()=>r.value,V=>{we(),V&&(s=new ResizeObserver(()=>{o&&o.update()}),s.observe(V))}),Te(()=>a.placement,i,{immediate:!0}),Gt(()=>{P()}),ss(()=>{f(),we(),$()}),{...no(a),popoverRef:r,alignment:c,hide:b,setupPopper:d,beforeEnter:I,afterEnter:j,beforeLeave:O,afterLeave:W,onClick:re,onMouseOver:X,onMouseLeave:ee,onFocusIn:J,onFocusOut:ue}}}),qn=(e,t)=>{const n=e.__vccOpts||e;for(const[r,s]of t)n[r]=s;return n};function GI(e,t,n,r,s,o){return G(),ae("div",{class:xe(["vc-popover-content-wrapper",{"is-interactive":e.isInteractive}]),ref:"popoverRef",onClick:t[0]||(t[0]=(...a)=>e.onClick&&e.onClick(...a)),onMouseover:t[1]||(t[1]=(...a)=>e.onMouseOver&&e.onMouseOver(...a)),onMouseleave:t[2]||(t[2]=(...a)=>e.onMouseLeave&&e.onMouseLeave(...a)),onFocusin:t[3]||(t[3]=(...a)=>e.onFocusIn&&e.onFocusIn(...a)),onFocusout:t[4]||(t[4]=(...a)=>e.onFocusOut&&e.onFocusOut(...a))},[L(uo,{name:`vc-${e.transition}`,appear:"",onBeforeEnter:e.beforeEnter,onAfterEnter:e.afterEnter,onBeforeLeave:e.beforeLeave,onAfterLeave:e.afterLeave},{default:Ee(()=>[e.isVisible?(G(),ae("div",qt({key:0,tabindex:"-1",class:`vc-popover-content direction-${e.direction}`},e.$attrs),[so(e.$slots,"default",{direction:e.direction,alignment:e.alignment,data:e.data,hide:e.hide},()=>[Kr(Xe(e.data),1)]),me("span",{class:xe(["vc-popover-caret",`direction-${e.direction}`,`align-${e.alignment}`])},null,2)],16)):We("",!0)]),_:3},8,["name","onBeforeEnter","onAfterEnter","onBeforeLeave","onAfterLeave"])],34)}const Ja=qn(KI,[["render",GI]]),qI={class:"vc-day-popover-row"},ZI={key:0,class:"vc-day-popover-row-indicator"},JI={class:"vc-day-popover-row-label"},Sp=Ze({__name:"PopoverRow",props:{attribute:null},setup(e){const t=e,n=w(()=>{const{content:r,highlight:s,dot:o,bar:a,popover:i}=t.attribute;return i&&i.hideIndicator?null:r?{class:`vc-bar vc-day-popover-row-bar vc-attr vc-${r.base.color}`}:s?{class:`vc-highlight-bg-solid vc-day-popover-row-highlight vc-attr vc-${s.base.color}`}:o?{class:`vc-dot vc-attr vc-${o.base.color}`}:a?{class:`vc-bar vc-day-popover-row-bar vc-attr vc-${a.base.color}`}:null});return(r,s)=>(G(),ae("div",qI,[A(n)?(G(),ae("div",ZI,[me("span",{class:xe(A(n).class)},null,2)])):We("",!0),me("div",JI,[so(r.$slots,"default",{},()=>[Kr(Xe(e.attribute.popover?e.attribute.popover.label:"No content provided"),1)])])]))}}),XI={inheritAttrs:!1},Rt=Ze({...XI,__name:"CalendarSlot",props:{name:null},setup(e){const n=Dp(e.name);return(r,s)=>A(n)?(G(),Ae(Pa(A(n)),Rr(qt({key:0},r.$attrs)),null,16)):so(r.$slots,"default",{key:1})}}),QI={class:"vc-day-popover-container"},eL={key:0,class:"vc-day-popover-header"},tL=Ze({__name:"CalendarDayPopover",setup(e){const{dayPopoverId:t,displayMode:n,color:r,masks:s,locale:o}=Sr();function a(l,u){return o.value.formatDate(l,u)}function i(l){return o.value.formatDate(l.date,s.value.dayPopover)}return(l,u)=>(G(),Ae(Ja,{id:A(t),class:xe([`vc-${A(r)}`,`vc-${A(n)}`])},{default:Ee(({data:{day:c,attributes:f},hide:d})=>[L(Rt,{name:"day-popover",day:c,"day-title":i(c),attributes:f,format:a,masks:A(s),hide:d},{default:Ee(()=>[me("div",QI,[A(s).dayPopover?(G(),ae("div",eL,Xe(i(c)),1)):We("",!0),(G(!0),ae(be,null,Ft(f,h=>(G(),Ae(Sp,{key:h.key,attribute:h},null,8,["attribute"]))),128))])]),_:2},1032,["day","day-title","attributes","masks","hide"])]),_:1},8,["id","class"]))}}),nL={},rL={"stroke-linecap":"round","stroke-linejoin":"round",viewBox:"0 0 24 24"},sL=me("polyline",{points:"9 18 15 12 9 6"},null,-1),oL=[sL];function aL(e,t){return G(),ae("svg",rL,oL)}const iL=qn(nL,[["render",aL]]),lL={},uL={"stroke-linecap":"round","stroke-linejoin":"round",viewBox:"0 0 24 24"},cL=me("polyline",{points:"15 18 9 12 15 6"},null,-1),fL=[cL];function dL(e,t){return G(),ae("svg",uL,fL)}const hL=qn(lL,[["render",dL]]),vL={},mL={"stroke-linecap":"round","stroke-linejoin":"round",viewBox:"0 0 24 24"},pL=me("polyline",{points:"6 9 12 15 18 9"},null,-1),gL=[pL];function yL(e,t){return G(),ae("svg",mL,gL)}const bL=qn(vL,[["render",yL]]),wL={},_L={fill:"none","stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",viewBox:"0 0 24 24"},DL=me("path",{d:"M12 8v4l3 3m6-3a9 9 0 11-18 0 9 9 0 0118 0z"},null,-1),CL=[DL];function SL(e,t){return G(),ae("svg",_L,CL)}const $L=qn(wL,[["render",SL]]),TL=Object.freeze(Object.defineProperty({__proto__:null,IconChevronDown:bL,IconChevronLeft:hL,IconChevronRight:iL,IconClock:$L},Symbol.toStringTag,{value:"Module"})),ns=Ze({__name:"BaseIcon",props:{name:{type:String,required:!0},width:{type:String},height:{type:String},size:{type:String,default:"26"},viewBox:{type:String}},setup(e){const t=e,n=w(()=>t.width||t.size),r=w(()=>t.height||t.size),s=w(()=>TL[`Icon${t.name}`]);return(o,a)=>(G(),Ae(Pa(A(s)),{width:A(n),height:A(r),class:"vc-base-icon"},null,8,["width","height"]))}}),EL=["disabled"],OL={key:1,class:"vc-title-wrapper"},ML={type:"button",class:"vc-title"},kL=["disabled"],$p=Ze({__name:"CalendarHeader",props:{page:null,layout:null,isLg:{type:Boolean},isXl:{type:Boolean},is2xl:{type:Boolean},hideTitle:{type:Boolean},hideArrows:{type:Boolean}},setup(e){const t=e,{navPopoverId:n,navVisibility:r,canMovePrev:s,movePrev:o,canMoveNext:a,moveNext:i}=Sr(),l=w(()=>{switch(t.page.titlePosition){case"left":return"bottom-start";case"right":return"bottom-end";default:return"bottom"}}),u=w(()=>{const{page:m}=t;return{id:n.value,visibility:r.value,placement:l.value,modifiers:[{name:"flip",options:{fallbackPlacements:["bottom"]}}],data:{page:m},isInteractive:!0}}),c=w(()=>t.page.titlePosition.includes("left")),f=w(()=>t.page.titlePosition.includes("right")),d=w(()=>t.layout?t.layout:c.value?"tu-pn":f.value?"pn-tu":"p-tu-n;"),h=w(()=>({prev:d.value.includes("p")&&!t.hideArrows,title:d.value.includes("t")&&!t.hideTitle,next:d.value.includes("n")&&!t.hideArrows})),v=w(()=>({gridTemplateColumns:d.value.split("").map(p=>{switch(p){case"p":return"[prev] auto";case"n":return"[next] auto";case"t":return"[title] auto";case"-":return"1fr";default:return""}}).join(" ")}));return(m,p)=>(G(),ae("div",{class:xe(["vc-header",{"is-lg":e.isLg,"is-xl":e.isXl,"is-2xl":e.is2xl}]),style:pn(A(v))},[A(h).prev?(G(),ae("button",{key:0,type:"button",class:"vc-arrow vc-prev vc-focus",disabled:!A(s),onClick:p[0]||(p[0]=(...b)=>A(o)&&A(o)(...b)),onKeydown:p[1]||(p[1]=Rc((...b)=>A(o)&&A(o)(...b),["space","enter"]))},[L(Rt,{name:"header-prev-button",disabled:!A(s)},{default:Ee(()=>[L(ns,{name:"ChevronLeft",size:"24"})]),_:1},8,["disabled"])],40,EL)):We("",!0),A(h).title?(G(),ae("div",OL,[L(Rt,{name:"header-title-wrapper"},{default:Ee(()=>[Ul((G(),ae("button",ML,[L(Rt,{name:"header-title",title:e.page.title},{default:Ee(()=>[me("span",null,Xe(e.page.title),1)]),_:1},8,["title"])])),[[A(mp),A(u)]])]),_:1})])):We("",!0),A(h).next?(G(),ae("button",{key:2,type:"button",class:"vc-arrow vc-next vc-focus",disabled:!A(a),onClick:p[2]||(p[2]=(...b)=>A(i)&&A(i)(...b)),onKeydown:p[3]||(p[3]=Rc((...b)=>A(i)&&A(i)(...b),["space","enter"]))},[L(Rt,{name:"header-next-button",disabled:!A(a)},{default:Ee(()=>[L(ns,{name:"ChevronRight",size:"24"})]),_:1},8,["disabled"])],40,kL)):We("",!0)],6))}}),Tp=Symbol("__vc_page_context__");function xL(e){const{locale:t,getDateAddress:n,canMove:r}=Sr();function s(i,l){const{month:u,year:c}=n(new Date);return fp().map((f,d)=>{const h=d+1;return{month:h,year:i,id:wA(h,i),label:t.value.formatDate(f,l),ariaLabel:t.value.formatDate(f,"MMMM"),isActive:h===e.value.month&&i===e.value.year,isCurrent:h===u&&i===c,isDisabled:!r({month:h,year:i},{position:e.value.position})}})}function o(i,l){const{year:u}=n(new Date),{position:c}=e.value,f=[];for(let d=i;d<=l;d+=1){const h=[...Array(12).keys()].some(v=>r({month:v+1,year:d},{position:c}));f.push({year:d,id:d.toString(),label:d.toString(),ariaLabel:d.toString(),isActive:d===e.value.year,isCurrent:d===u,isDisabled:!h})}return f}const a={page:e,getMonthItems:s,getYearItems:o};return Pt(Tp,a),a}function Ep(){const e=Pe(Tp);if(e)return e;throw new Error("Page context missing. Please verify this component is nested within a valid context provider.")}const PL={class:"vc-nav-header"},AL=["disabled"],IL=["disabled"],LL={class:"vc-nav-items"},RL=["data-id","aria-label","disabled","onClick","onKeydown"],NL=Ze({__name:"CalendarNav",setup(e){const{masks:t,move:n}=Sr(),{page:r,getMonthItems:s,getYearItems:o}=Ep(),a=oe(!0),i=12,l=oe(r.value.year),u=oe(d(r.value.year)),c=oe(null);function f(){setTimeout(()=>{if(c.value==null)return;const Q=c.value.querySelector(".vc-nav-item:not(:disabled)");Q&&Q.focus()},10)}function d(Q){return Math.floor(Q/i)}function h(){a.value=!a.value}function v(Q){return Q*i}function m(Q){return i*(Q+1)-1}function p(){J.value&&(a.value&&S(),M())}function b(){ue.value&&(a.value&&T(),D())}function S(){l.value--}function T(){l.value++}function M(){u.value--}function D(){u.value++}const C=w(()=>s(l.value,t.value.navMonths).map(Q=>({...Q,click:()=>n({month:Q.month,year:Q.year},{position:r.value.position})}))),E=w(()=>s(l.value-1,t.value.navMonths)),P=w(()=>E.value.some(Q=>!Q.isDisabled)),$=w(()=>s(l.value+1,t.value.navMonths)),I=w(()=>$.value.some(Q=>!Q.isDisabled)),j=w(()=>o(v(u.value),m(u.value)).map(Q=>({...Q,click:()=>{l.value=Q.year,a.value=!0,f()}}))),O=w(()=>o(v(u.value-1),m(u.value-1))),W=w(()=>O.value.some(Q=>!Q.isDisabled)),re=w(()=>o(v(u.value+1),m(u.value+1))),X=w(()=>re.value.some(Q=>!Q.isDisabled)),ee=w(()=>a.value?C.value:j.value),J=w(()=>a.value?P.value:W.value),ue=w(()=>a.value?I.value:X.value),we=w(()=>Um(j.value.map(Q=>Q.year))),V=w(()=>Ar(j.value.map(Q=>Q.year))),fe=w(()=>a.value?l.value:`${we.value} - ${V.value}`);return zn(()=>{l.value=r.value.year,f()}),Te(()=>l.value,Q=>u.value=d(Q)),Gt(()=>f()),(Q,Le)=>(G(),ae("div",{class:"vc-nav-container",ref_key:"navContainer",ref:c},[me("div",PL,[me("button",{type:"button",class:"vc-nav-arrow is-left vc-focus",disabled:!A(J),onClick:p,onKeydown:Le[0]||(Le[0]=pe=>A(Ao)(pe,p))},[L(Rt,{name:"nav-prev-button",move:p,disabled:!A(J)},{default:Ee(()=>[L(ns,{name:"ChevronLeft",width:"22px",height:"24px"})]),_:1},8,["disabled"])],40,AL),me("button",{type:"button",class:"vc-nav-title vc-focus",onClick:h,onKeydown:Le[1]||(Le[1]=pe=>A(Ao)(pe,h))},Xe(A(fe)),33),me("button",{type:"button",class:"vc-nav-arrow is-right vc-focus",disabled:!A(ue),onClick:b,onKeydown:Le[2]||(Le[2]=pe=>A(Ao)(pe,b))},[L(Rt,{name:"nav-next-button",move:b,disabled:!A(ue)},{default:Ee(()=>[L(ns,{name:"ChevronRight",width:"22px",height:"24px"})]),_:1},8,["disabled"])],40,IL)]),me("div",LL,[(G(!0),ae(be,null,Ft(A(ee),pe=>(G(),ae("button",{key:pe.label,type:"button","data-id":pe.id,"aria-label":pe.ariaLabel,class:xe(["vc-nav-item vc-focus",[pe.isActive?"is-active":pe.isCurrent?"is-current":""]]),disabled:pe.isDisabled,onClick:pe.click,onKeydown:Ye=>A(Ao)(Ye,pe.click)},Xe(pe.label),43,RL))),128))])],512))}}),Op=Ze({__name:"CalendarPageProvider",props:{page:null},setup(e){return xL(et(e,"page")),(n,r)=>so(n.$slots,"default")}}),FL=Ze({__name:"CalendarNavPopover",setup(e){const{navPopoverId:t,color:n,displayMode:r}=Sr();return(s,o)=>(G(),Ae(Ja,{id:A(t),class:xe(["vc-nav-popover-container",`vc-${A(n)}`,`vc-${A(r)}`])},{default:Ee(({data:a})=>[L(Op,{page:a.page},{default:Ee(()=>[L(Rt,{name:"nav"},{default:Ee(()=>[L(NL)]),_:1})]),_:2},1032,["page"])]),_:1},8,["id","class"]))}}),YL=Ze({directives:{popover:mp},components:{CalendarSlot:Rt},props:{day:{type:Object,required:!0}},setup(e){const{locale:t,theme:n,attributeContext:r,dayPopoverId:s,onDayClick:o,onDayMouseenter:a,onDayMouseleave:i,onDayFocusin:l,onDayFocusout:u,onDayKeydown:c}=Sr(),f=w(()=>e.day),d=w(()=>r.value.getCells(f.value)),h=w(()=>d.value.map(X=>X.data)),v=w(()=>({...f.value,attributes:h.value,attributeCells:d.value}));function m({data:X},{popovers:ee}){const{key:J,customData:ue,popover:we}=X;if(!we)return;const V=ld({key:J,customData:ue,attribute:X},{...we},{visibility:we.label?"hover":"click",placement:"bottom",isInteractive:!we.label});ee.splice(0,0,V)}const p=w(()=>{const X={...n.value.prepareRender({}),popovers:[]};return d.value.forEach(ee=>{n.value.render(ee,X),m(ee,X)}),X}),b=w(()=>p.value.highlights),S=w(()=>!!mn(b.value)),T=w(()=>p.value.content),M=w(()=>p.value.dots),D=w(()=>!!mn(M.value)),C=w(()=>p.value.bars),E=w(()=>!!mn(C.value)),P=w(()=>p.value.popovers),$=w(()=>P.value.map(X=>X.attribute)),I=Dp("day-content"),j=w(()=>["vc-day",...f.value.classes,{"vc-day-box-center-center":!I},{"is-not-in-month":!e.day.inMonth}]),O=w(()=>{let X;f.value.isFocusable?X="0":X="-1";const ee=["vc-day-content vc-focusable vc-focus vc-attr",{"vc-disabled":f.value.isDisabled},ar(Ar(b.value),"contentClass"),ar(Ar(T.value),"class")||""],J={...ar(Ar(b.value),"contentStyle"),...ar(Ar(T.value),"style")};return{class:ee,style:J,tabindex:X,"aria-label":f.value.ariaLabel,"aria-disabled":!!f.value.isDisabled,role:"button"}}),W=w(()=>({click(X){o(v.value,X)},mouseenter(X){a(v.value,X)},mouseleave(X){i(v.value,X)},focusin(X){l(v.value,X)},focusout(X){u(v.value,X)},keydown(X){c(v.value,X)}})),re=w(()=>mn(P.value)?ld({id:s.value,data:{day:f,attributes:$.value}},...P.value):null);return{attributes:h,attributeCells:d,bars:C,dayClasses:j,dayContentProps:O,dayContentEvents:W,dayPopover:re,glyphs:p,dots:M,hasDots:D,hasBars:E,highlights:b,hasHighlights:S,locale:t,popovers:P}}}),BL={key:0,class:"vc-highlights vc-day-layer"},HL={key:1,class:"vc-day-layer vc-day-box-center-bottom"},jL={class:"vc-dots"},VL={key:2,class:"vc-day-layer vc-day-box-center-bottom"},WL={class:"vc-bars"};function UL(e,t,n,r,s,o){const a=vn("CalendarSlot"),i=Fy("popover");return G(),ae("div",{class:xe(e.dayClasses)},[e.hasHighlights?(G(),ae("div",BL,[(G(!0),ae(be,null,Ft(e.highlights,({key:l,wrapperClass:u,class:c,style:f})=>(G(),ae("div",{key:l,class:xe(u)},[me("div",{class:xe(c),style:pn(f)},null,6)],2))),128))])):We("",!0),L(a,{name:"day-content",day:e.day,attributes:e.attributes,"attribute-cells":e.attributeCells,dayProps:e.dayContentProps,dayEvents:e.dayContentEvents,locale:e.locale},{default:Ee(()=>[Ul((G(),ae("div",qt(e.dayContentProps,Yy(e.dayContentEvents,!0)),[Kr(Xe(e.day.label),1)],16)),[[i,e.dayPopover]])]),_:1},8,["day","attributes","attribute-cells","dayProps","dayEvents","locale"]),e.hasDots?(G(),ae("div",HL,[me("div",jL,[(G(!0),ae(be,null,Ft(e.dots,({key:l,class:u,style:c})=>(G(),ae("span",{key:l,class:xe(u),style:pn(c)},null,6))),128))])])):We("",!0),e.hasBars?(G(),ae("div",VL,[me("div",WL,[(G(!0),ae(be,null,Ft(e.bars,({key:l,class:u,style:c})=>(G(),ae("span",{key:l,class:xe(u),style:pn(c)},null,6))),128))])])):We("",!0)],2)}const zL=qn(YL,[["render",UL]]),KL={class:"vc-weekdays"},GL=["onClick"],qL={inheritAttrs:!1},ZL=Ze({...qL,__name:"CalendarPage",setup(e){const{page:t}=Ep(),{onWeeknumberClick:n}=Sr();return(r,s)=>(G(),ae("div",{class:xe(["vc-pane",`row-${A(t).row}`,`row-from-end-${A(t).rowFromEnd}`,`column-${A(t).column}`,`column-from-end-${A(t).columnFromEnd}`]),ref:"pane"},[L($p,{page:A(t),"is-lg":"","hide-arrows":""},null,8,["page"]),me("div",{class:xe(["vc-weeks",{[`vc-show-weeknumbers-${A(t).weeknumberPosition}`]:A(t).weeknumberPosition}])},[me("div",KL,[(G(!0),ae(be,null,Ft(A(t).weekdays,({weekday:o,label:a},i)=>(G(),ae("div",{key:i,class:xe(`vc-weekday vc-weekday-${o}`)},Xe(a),3))),128))]),(G(!0),ae(be,null,Ft(A(t).viewWeeks,o=>(G(),ae("div",{key:`weeknumber-${o.weeknumber}`,class:"vc-week"},[A(t).weeknumberPosition?(G(),ae("div",{key:0,class:xe(["vc-weeknumber",`is-${A(t).weeknumberPosition}`])},[me("span",{class:xe(["vc-weeknumber-content"]),onClick:a=>A(n)(o,a)},Xe(o.weeknumberDisplay),9,GL)],2)):We("",!0),(G(!0),ae(be,null,Ft(o.days,a=>(G(),Ae(zL,{key:a.id,day:a},null,8,["day"]))),128))]))),128))],2)],2))}}),JL=Ze({components:{CalendarHeader:$p,CalendarPage:ZL,CalendarNavPopover:FL,CalendarDayPopover:tL,CalendarPageProvider:Op,CalendarSlot:Rt},props:WI,emit:UI,setup(e,{emit:t,slots:n}){return zI(e,{emit:t,slots:n})}}),XL={class:"vc-pane-header-wrapper"};function QL(e,t,n,r,s,o){const a=vn("CalendarHeader"),i=vn("CalendarPage"),l=vn("CalendarSlot"),u=vn("CalendarPageProvider"),c=vn("CalendarDayPopover"),f=vn("CalendarNavPopover");return G(),ae(be,null,[me("div",qt({"data-helptext":"Press the arrow keys to navigate by day, Home and End to navigate to week ends, PageUp and PageDown to navigate by month, Alt+PageUp and Alt+PageDown to navigate by year"},e.$attrs,{class:["vc-container",`vc-${e.view}`,`vc-${e.color}`,`vc-${e.displayMode}`,{"vc-expanded":e.expanded,"vc-bordered":!e.borderless,"vc-transparent":e.transparent}],onMouseup:t[0]||(t[0]=h0(()=>{},["prevent"])),ref:"containerRef"}),[me("div",{class:xe(["vc-pane-container",{"in-transition":e.inTransition}])},[me("div",XL,[e.firstPage?(G(),Ae(a,{key:0,page:e.firstPage,"is-lg":"","hide-title":""},null,8,["page"])):We("",!0)]),L(uo,{name:`vc-${e.transitionName}`,onBeforeEnter:e.onTransitionBeforeEnter,onAfterEnter:e.onTransitionAfterEnter},{default:Ee(()=>[(G(),ae("div",{key:e.pages[0].id,class:"vc-pane-layout",style:pn({gridTemplateColumns:`repeat(${e.columns}, 1fr)`})},[(G(!0),ae(be,null,Ft(e.pages,d=>(G(),Ae(u,{key:d.id,page:d},{default:Ee(()=>[L(l,{name:"page",page:d},{default:Ee(()=>[L(i)]),_:2},1032,["page"])]),_:2},1032,["page"]))),128))],4))]),_:1},8,["name","onBeforeEnter","onAfterEnter"]),L(l,{name:"footer"})],2)],16),L(c),L(f)],64)}const Mp=qn(JL,[["render",QL]]),kp=Symbol("__vc_date_picker_context__"),eR={...yp,mode:{type:String,default:"date"},modelValue:{type:[Number,String,Date,Object]},modelModifiers:{type:Object,default:()=>({})},rules:[String,Object],is24hr:Boolean,hideTimeHeader:Boolean,timeAccuracy:{type:Number,default:2},isRequired:Boolean,isRange:Boolean,updateOnInput:{type:Boolean,default:()=>jn("datePicker.updateOnInput")},inputDebounce:{type:Number,default:()=>jn("datePicker.inputDebounce")},popover:{type:[Boolean,Object],default:!0},dragAttribute:Object,selectAttribute:Object,attributes:[Object,Array]},tR=["update:modelValue","drag","dayclick","daykeydown","popover-will-show","popover-did-show","popover-will-hide","popover-did-hide"];function nR(e,{emit:t,slots:n}){_p(n,{footer:"dp-footer"});const r=bp(e),{locale:s,masks:o,disabledAttribute:a}=r,i=oe(!1),l=oe(Symbol()),u=oe(null),c=oe(null),f=oe(["",""]),d=oe(null),h=oe(null);let v,m,p=!0;const b=w(()=>e.isRange||e.modelModifiers.range===!0),S=w(()=>b.value&&u.value!=null?u.value.start:null),T=w(()=>b.value&&u.value!=null?u.value.end:null),M=w(()=>e.mode.toLowerCase()==="date"),D=w(()=>e.mode.toLowerCase()==="datetime"),C=w(()=>e.mode.toLowerCase()==="time"),E=w(()=>!!c.value),P=w(()=>{let y="date";e.modelModifiers.number&&(y="number"),e.modelModifiers.string&&(y="string");const F=o.value.modelValue||"iso";return Le({type:y,mask:F})}),$=w(()=>K(c.value??u.value)),I=w(()=>C.value?e.is24hr?o.value.inputTime24hr:o.value.inputTime:D.value?e.is24hr?o.value.inputDateTime24hr:o.value.inputDateTime:o.value.input),j=w(()=>/[Hh]/g.test(I.value)),O=w(()=>/[dD]{1,2}|Do|W{1,4}|M{1,4}|YY(?:YY)?/g.test(I.value)),W=w(()=>{if(j.value&&O.value)return"dateTime";if(O.value)return"date";if(j.value)return"time"}),re=w(()=>{var y;const F=((y=d.value)==null?void 0:y.$el.previousElementSibling)??void 0;return ts({},e.popover,jn("datePicker.popover"),{target:F})}),X=w(()=>vp({...re.value,id:l.value})),ee=w(()=>b.value?{start:f.value[0],end:f.value[1]}:f.value[0]),J=w(()=>{const y=["start","end"].map(F=>({input:Y(F),change:R(F),keyup:H,...e.popover&&X.value}));return b.value?{start:y[0],end:y[1]}:y[0]}),ue=w(()=>{if(!ye(u.value))return null;const y={key:"select-drag",...e.selectAttribute,dates:u.value,pinPage:!0},{dot:F,bar:Z,highlight:he,content:He}=y;return!F&&!Z&&!he&&!He&&(y.highlight=!0),y}),we=w(()=>{if(!b.value||!ye(c.value))return null;const y={key:"select-drag",...e.dragAttribute,dates:c.value},{dot:F,bar:Z,highlight:he,content:He}=y;return!F&&!Z&&!he&&!He&&(y.highlight={startEnd:{fillMode:"outline"}}),y}),V=w(()=>{const y=Bt(e.attributes)?[...e.attributes]:[];return we.value?y.unshift(we.value):ue.value&&y.unshift(ue.value),y}),fe=w(()=>Le(e.rules==="auto"?Q():e.rules??{}));function Q(){const y={ms:[0,999],sec:[0,59],min:[0,59],hr:[0,23]},F=M.value?0:e.timeAccuracy;return[0,1].map(Z=>{switch(F){case 0:return{hours:y.hr[Z],minutes:y.min[Z],seconds:y.sec[Z],milliseconds:y.ms[Z]};case 1:return{minutes:y.min[Z],seconds:y.sec[Z],milliseconds:y.ms[Z]};case 3:return{milliseconds:y.ms[Z]};case 4:return{};default:return{seconds:y.sec[Z],milliseconds:y.ms[Z]}}})}function Le(y){return Bt(y)?y.length===1?[y[0],y[0]]:y:[y,y]}function pe(y){return Le(y).map((F,Z)=>({...F,rules:fe.value[Z]}))}function Ye(y){return y==null?!1:Kt(y)?!isNaN(y):Hr(y)?!isNaN(y.getTime()):rn(y)?y!=="":xu(y)}function Re(y){return bn(y)&&"start"in y&&"end"in y&&Ye(y.start??null)&&Ye(y.end??null)}function ye(y){return Re(y)||Ye(y)}function ze(y,F){if(y==null&&F==null)return!0;if(y==null||F==null)return!1;const Z=Hr(y),he=Hr(F);return Z&&he?y.getTime()===F.getTime():Z||he?!1:ze(y.start,F.start)&&ze(y.end,F.end)}function tt(y){return!ye(y)||!a.value?!1:a.value.intersectsRange(s.value.range(y))}function lt(y,F,Z,he){if(!ye(y))return null;if(Re(y)){const He=s.value.toDate(y.start,{...F[0],fillDate:S.value??void 0,patch:Z}),ft=s.value.toDate(y.end,{...F[1],fillDate:T.value??void 0,patch:Z});return Vt({start:He,end:ft},he)}return s.value.toDateOrNull(y,{...F[0],fillDate:u.value,patch:Z})}function mt(y,F){return Re(y)?{start:s.value.fromDate(y.start,F[0]),end:s.value.fromDate(y.end,F[1])}:b.value?null:s.value.fromDate(y,F[0])}function ut(y,F={}){return clearTimeout(v),new Promise(Z=>{const{debounce:he=0,...He}=F;he>0?v=window.setTimeout(()=>{Z(g(y,He))},he):Z(g(y,He))})}function g(y,{config:F=P.value,patch:Z="dateTime",clearIfEqual:he=!1,formatInput:He=!0,hidePopover:ft=!1,dragging:$t=E.value,targetPriority:$r,moveToValue:Tr=!1}={}){const ai=pe(F);let pt=lt(y,ai,Z,$r);if(tt(pt)){if($t)return null;pt=u.value,ft=!1}else pt==null&&e.isRequired?pt=u.value:pt!=null&&ze(u.value,pt)&&he&&(pt=null);const yo=$t?c:u,ps=!ze(yo.value,pt);yo.value=pt,$t||(c.value=null);const gs=mt(pt,P.value);return ps&&(p=!1,t($t?"drag":"update:modelValue",gs),Ot(()=>p=!0)),ft&&!$t&&Be(),He&&_(),Tr&&Ot(()=>Xn($r??"start")),gs}function _(){Ot(()=>{const y=pe({type:"string",mask:I.value}),F=mt(c.value??u.value,y);b.value?f.value=[F&&F.start,F&&F.end]:f.value=[F,""]})}function k(y,F,Z){f.value.splice(F==="start"?0:1,1,y);const he=b.value?{start:f.value[0],end:f.value[1]||f.value[0]}:y,He={type:"string",mask:I.value};ut(he,{...Z,config:He,patch:W.value,targetPriority:F,moveToValue:!0})}function Y(y){return F=>{e.updateOnInput&&k(F.currentTarget.value,y,{formatInput:!1,hidePopover:!1,debounce:e.inputDebounce})}}function R(y){return F=>{k(F.currentTarget.value,y,{formatInput:!0,hidePopover:!1})}}function H(y){y.key==="Escape"&&ut(u.value,{formatInput:!0,hidePopover:!0})}function K(y){return b.value?[y&&y.start?s.value.getDateParts(y.start):null,y&&y.end?s.value.getDateParts(y.end):null]:[y?s.value.getDateParts(y):null]}function U(){c.value=null,_()}function z(y){t("popover-will-show",y)}function B(y){t("popover-did-show",y)}function q(y){U(),t("popover-will-hide",y)}function ne(y){t("popover-did-hide",y)}function te(y){const F={patch:"date",formatInput:!0,hidePopover:!0};if(b.value){const Z=!E.value;Z?m={start:y.startDate,end:y.endDate}:m!=null&&(m.end=y.date),ut(m,{...F,dragging:Z})}else ut(y.date,{...F,clearIfEqual:!e.isRequired})}function ie(y,F){te(y),t("dayclick",y,F)}function de(y,F){switch(F.key){case" ":case"Enter":{te(y),F.preventDefault();break}case"Escape":Be()}t("daykeydown",y,F)}function Ce(y,F){!E.value||m==null||(m.end=y.date,ut(Vt(m),{patch:"date",formatInput:!0}))}function _e(y={}){yl({...re.value,...y,isInteractive:!0,id:l.value})}function Be(y={}){Js({hideDelay:10,force:!0,...re.value,...y,id:l.value})}function ct(y){hp({...re.value,...y,isInteractive:!0,id:l.value})}function Vt(y,F){const{start:Z,end:he}=y;if(Z>he)switch(F){case"start":return{start:Z,end:Z};case"end":return{start:he,end:he};default:return{start:he,end:Z}}return{start:Z,end:he}}async function Jn(y,F={}){return h.value==null?!1:h.value.move(y,F)}async function fn(y,F={}){return h.value==null?!1:h.value.moveBy(y,F)}async function Xn(y,F={}){const Z=u.value;if(h.value==null||!ye(Z))return!1;const he=y!=="end",He=he?1:-1,ft=Re(Z)?he?Z.start:Z.end:Z,$t=Jm(ft,"monthly",s.value);return h.value.move($t,{position:He,...F})}Te(()=>e.isRange,y=>{y&&console.warn("The `is-range` prop will be deprecated in future releases. Please use the `range` modifier.")},{immediate:!0}),Te(()=>b.value,()=>{g(null,{formatInput:!0})}),Te(()=>I.value,()=>_()),Te(()=>e.modelValue,y=>{p&&g(y,{formatInput:!0,hidePopover:!1})}),Te(()=>fe.value,()=>{bn(e.rules)&&g(e.modelValue,{formatInput:!0,hidePopover:!1})}),Te(()=>e.timezone,()=>{g(u.value,{formatInput:!0})});const Je=Le(P.value);u.value=lt(e.modelValue??null,Je,"dateTime"),Gt(()=>{g(e.modelValue,{formatInput:!0,hidePopover:!1})}),Ot(()=>i.value=!0);const N={...r,showCalendar:i,datePickerPopoverId:l,popoverRef:d,popoverEvents:X,calendarRef:h,isRange:b,isTimeMode:C,isDateTimeMode:D,is24hr:et(e,"is24hr"),hideTimeHeader:et(e,"hideTimeHeader"),timeAccuracy:et(e,"timeAccuracy"),isDragging:E,inputValue:ee,inputEvents:J,dateParts:$,attributes:V,rules:fe,move:Jn,moveBy:fn,moveToValue:Xn,updateValue:ut,showPopover:_e,hidePopover:Be,togglePopover:ct,onDayClick:ie,onDayKeydown:de,onDayMouseEnter:Ce,onPopoverBeforeShow:z,onPopoverAfterShow:B,onPopoverBeforeHide:q,onPopoverAfterHide:ne};return Pt(kp,N),N}function Lu(){const e=Pe(kp);if(e)return e;throw new Error("DatePicker context missing. Please verify this component is nested within a valid context provider.")}const rR=[{value:0,label:"12"},{value:1,label:"1"},{value:2,label:"2"},{value:3,label:"3"},{value:4,label:"4"},{value:5,label:"5"},{value:6,label:"6"},{value:7,label:"7"},{value:8,label:"8"},{value:9,label:"9"},{value:10,label:"10"},{value:11,label:"11"}],sR=[{value:12,label:"12"},{value:13,label:"1"},{value:14,label:"2"},{value:15,label:"3"},{value:16,label:"4"},{value:17,label:"5"},{value:18,label:"6"},{value:19,label:"7"},{value:20,label:"8"},{value:21,label:"9"},{value:22,label:"10"},{value:23,label:"11"}];function oR(e){const t=Lu(),{locale:n,isRange:r,isTimeMode:s,dateParts:o,rules:a,is24hr:i,hideTimeHeader:l,timeAccuracy:u,updateValue:c}=t;function f(O){O=Object.assign(h.value,O);let W=null;if(r.value){const re=d.value?O:o.value[0],X=d.value?o.value[1]:O;W={start:re,end:X}}else W=O;c(W,{patch:"time",targetPriority:d.value?"start":"end",moveToValue:!0})}const d=w(()=>e.position===0),h=w(()=>o.value[e.position]||{isValid:!1}),v=w(()=>xu(h.value)),m=w(()=>!!h.value.isValid),p=w(()=>!l.value&&m.value),b=w(()=>{if(!v.value)return null;let O=n.value.toDate(h.value);return h.value.hours===24&&(O=new Date(O.getTime()-1)),O}),S=w({get(){return h.value.hours},set(O){f({hours:O})}}),T=w({get(){return h.value.minutes},set(O){f({minutes:O})}}),M=w({get(){return h.value.seconds},set(O){f({seconds:O})}}),D=w({get(){return h.value.milliseconds},set(O){f({milliseconds:O})}}),C=w({get(){return h.value.hours<12},set(O){O=String(O).toLowerCase()=="true";let W=S.value;O&&W>=12?W-=12:!O&&W<12&&(W+=12),f({hours:W})}}),E=w(()=>$I(h.value,a.value[e.position])),P=w(()=>rR.filter(O=>E.value.hours.some(W=>W.value===O.value))),$=w(()=>sR.filter(O=>E.value.hours.some(W=>W.value===O.value))),I=w(()=>i.value?E.value.hours:C.value?P.value:$.value),j=w(()=>{const O=[];return mn(P.value)&&O.push({value:!0,label:"AM"}),mn($.value)&&O.push({value:!1,label:"PM"}),O});return{...t,showHeader:p,timeAccuracy:u,parts:h,isValid:m,date:b,hours:S,minutes:T,seconds:M,milliseconds:D,options:E,hourOptions:I,isAM:C,isAMOptions:j,is24hr:i}}const aR=["value"],iR=["value","disabled"],lR={key:1,class:"vc-base-sizer","aria-hidden":"true"},uR={inheritAttrs:!1},Cs=Ze({...uR,__name:"BaseSelect",props:{options:null,modelValue:null,alignRight:{type:Boolean},alignLeft:{type:Boolean},showIcon:{type:Boolean},fitContent:{type:Boolean}},emits:["update:modelValue"],setup(e){const t=e,n=w(()=>{const r=t.options.find(s=>s.value===t.modelValue);return r?.label});return(r,s)=>(G(),ae("div",{class:xe(["vc-base-select",{"vc-fit-content":e.fitContent,"vc-has-icon":e.showIcon}])},[me("select",qt(r.$attrs,{value:e.modelValue,class:["vc-focus",{"vc-align-right":e.alignRight,"vc-align-left":e.alignLeft}],onChange:s[0]||(s[0]=o=>r.$emit("update:modelValue",o.target.value))}),[(G(!0),ae(be,null,Ft(e.options,o=>(G(),ae("option",{key:o.value,value:o.value,disabled:o.disabled},Xe(o.label),9,iR))),128))],16,aR),e.showIcon?(G(),Ae(ns,{key:0,name:"ChevronDown",size:"18"})):We("",!0),e.fitContent?(G(),ae("div",lR,Xe(A(n)),1)):We("",!0)],2))}}),cR={key:0,class:"vc-time-header"},fR={class:"vc-time-weekday"},dR={class:"vc-time-month"},hR={class:"vc-time-day"},vR={class:"vc-time-year"},mR={class:"vc-time-select-group"},pR=me("span",{class:"vc-time-colon"},":",-1),gR=me("span",{class:"vc-time-colon"},":",-1),yR=me("span",{class:"vc-time-decimal"},".",-1),Nd=Ze({__name:"TimePicker",props:{position:null},setup(e,{expose:t}){const r=oR(e);t(r);const{locale:s,isValid:o,date:a,hours:i,minutes:l,seconds:u,milliseconds:c,options:f,hourOptions:d,isTimeMode:h,isAM:v,isAMOptions:m,is24hr:p,showHeader:b,timeAccuracy:S}=r;return(T,M)=>(G(),ae("div",{class:xe(["vc-time-picker",[{"vc-invalid":!A(o),"vc-attached":!A(h)}]])},[L(Rt,{name:"time-header"},{default:Ee(()=>[A(b)&&A(a)?(G(),ae("div",cR,[me("span",fR,Xe(A(s).formatDate(A(a),"WWW")),1),me("span",dR,Xe(A(s).formatDate(A(a),"MMM")),1),me("span",hR,Xe(A(s).formatDate(A(a),"D")),1),me("span",vR,Xe(A(s).formatDate(A(a),"YYYY")),1)])):We("",!0)]),_:1}),me("div",mR,[L(ns,{name:"Clock",size:"17"}),L(Cs,{modelValue:A(i),"onUpdate:modelValue":M[0]||(M[0]=D=>Se(i)?i.value=D:null),modelModifiers:{number:!0},options:A(d),class:"vc-time-select-hours","align-right":""},null,8,["modelValue","options"]),A(S)>1?(G(),ae(be,{key:0},[pR,L(Cs,{modelValue:A(l),"onUpdate:modelValue":M[1]||(M[1]=D=>Se(l)?l.value=D:null),modelModifiers:{number:!0},options:A(f).minutes,class:"vc-time-select-minutes","align-left":A(S)===2},null,8,["modelValue","options","align-left"])],64)):We("",!0),A(S)>2?(G(),ae(be,{key:1},[gR,L(Cs,{modelValue:A(u),"onUpdate:modelValue":M[2]||(M[2]=D=>Se(u)?u.value=D:null),modelModifiers:{number:!0},options:A(f).seconds,class:"vc-time-select-seconds","align-left":A(S)===3},null,8,["modelValue","options","align-left"])],64)):We("",!0),A(S)>3?(G(),ae(be,{key:2},[yR,L(Cs,{modelValue:A(c),"onUpdate:modelValue":M[3]||(M[3]=D=>Se(c)?c.value=D:null),modelModifiers:{number:!0},options:A(f).milliseconds,class:"vc-time-select-milliseconds","align-left":""},null,8,["modelValue","options"])],64)):We("",!0),A(p)?We("",!0):(G(),Ae(Cs,{key:3,modelValue:A(v),"onUpdate:modelValue":M[4]||(M[4]=D=>Se(v)?v.value=D:null),options:A(m)},null,8,["modelValue","options"]))])],2))}}),xp=Ze({__name:"DatePickerBase",setup(e){const{attributes:t,calendarRef:n,color:r,displayMode:s,isDateTimeMode:o,isTimeMode:a,isRange:i,onDayClick:l,onDayMouseEnter:u,onDayKeydown:c}=Lu(),f=i.value?[0,1]:[0];return(d,h)=>A(a)?(G(),ae("div",{key:0,class:xe(`vc-container vc-bordered vc-${A(r)} vc-${A(s)}`)},[(G(!0),ae(be,null,Ft(A(f),v=>(G(),Ae(Nd,{key:v,position:v},null,8,["position"]))),128))],2)):(G(),Ae(Mp,{key:1,attributes:A(t),ref_key:"calendarRef",ref:n,onDayclick:A(l),onDaymouseenter:A(u),onDaykeydown:A(c)},{footer:Ee(()=>[A(o)?(G(!0),ae(be,{key:0},Ft(A(f),v=>(G(),Ae(Nd,{key:v,position:v},null,8,["position"]))),128)):We("",!0),L(Rt,{name:"dp-footer"})]),_:1},8,["attributes","onDayclick","onDaymouseenter","onDaykeydown"]))}}),bR={inheritAttrs:!1},wR=Ze({...bR,__name:"DatePickerPopover",setup(e){const{datePickerPopoverId:t,color:n,displayMode:r,popoverRef:s,onPopoverBeforeShow:o,onPopoverAfterShow:a,onPopoverBeforeHide:i,onPopoverAfterHide:l}=Lu();return(u,c)=>(G(),Ae(Ja,{id:A(t),placement:"bottom-start",class:xe(`vc-date-picker-content vc-${A(n)} vc-${A(r)}`),ref_key:"popoverRef",ref:s,onBeforeShow:A(o),onAfterShow:A(a),onBeforeHide:A(i),onAfterHide:A(l)},{default:Ee(()=>[L(xp,Rr(Xo(u.$attrs)),null,16)]),_:1},8,["id","class","onBeforeShow","onAfterShow","onBeforeHide","onAfterHide"]))}}),_R=Ze({inheritAttrs:!1,emits:tR,props:eR,components:{DatePickerBase:xp,DatePickerPopover:wR},setup(e,t){const n=nR(e,t),r=je(Km(n,"calendarRef","popoverRef"));return{...n,slotCtx:r}}});function DR(e,t,n,r,s,o){const a=vn("DatePickerPopover"),i=vn("DatePickerBase");return e.$slots.default?(G(),ae(be,{key:0},[so(e.$slots,"default",Rr(Xo(e.slotCtx))),L(a,Rr(Xo(e.$attrs)),null,16)],64)):(G(),Ae(i,Rr(qt({key:1},e.$attrs)),null,16))}const CR=qn(_R,[["render",DR]]),Fd=Object.freeze(Object.defineProperty({__proto__:null,Calendar:Mp,DatePicker:CR,Popover:Ja,PopoverRow:Sp},Symbol.toStringTag,{value:"Module"})),SR=(e,t={})=>{e.use(GA,t);const n=e.config.globalProperties.$VCalendar.componentPrefix;for(const r in Fd){const s=Fd[r];e.component(`${n}${r}`,s)}},$R={install:SR},mo=Symbol("eodash"),TR=()=>Br.value?.layers.toReversed(),Pp=async e=>{e=typeof e=="number"?`EPSG:${e}`:e,!(!e||la.includes(e))&&(la.push(e),await Br.value?.registerProjectionFromCode(e))},ER=async e=>{if(e=typeof e=="number"?`EPSG:${e}`:e,!e){Br.value?.setAttribute("projection","EPSG:3857");return}la.includes(e)||await Pp(e),e=Br.value?.getAttribute("projection")===e?"EPSG:3857":e,Br.value?.setAttribute("projection",e)},OR=Object.freeze(Object.defineProperty({__proto__:null,changeMapProjection:ER,getLayers:TR,registerProjection:Pp},Symbol.toStringTag,{value:"Module"}));function Ap(e,t){return function(){return e.apply(t,arguments)}}const{toString:MR}=Object.prototype,{getPrototypeOf:Ru}=Object,Xa=(e=>t=>{const n=MR.call(t);return e[n]||(e[n]=n.slice(8,-1).toLowerCase())})(Object.create(null)),Xt=e=>(e=e.toLowerCase(),t=>Xa(t)===e),Qa=e=>t=>typeof t===e,{isArray:vs}=Array,Xs=Qa("undefined");function kR(e){return e!==null&&!Xs(e)&&e.constructor!==null&&!Xs(e.constructor)&&Mt(e.constructor.isBuffer)&&e.constructor.isBuffer(e)}const Ip=Xt("ArrayBuffer");function xR(e){let t;return typeof ArrayBuffer<"u"&&ArrayBuffer.isView?t=ArrayBuffer.isView(e):t=e&&e.buffer&&Ip(e.buffer),t}const PR=Qa("string"),Mt=Qa("function"),Lp=Qa("number"),ei=e=>e!==null&&typeof e=="object",AR=e=>e===!0||e===!1,Uo=e=>{if(Xa(e)!=="object")return!1;const t=Ru(e);return(t===null||t===Object.prototype||Object.getPrototypeOf(t)===null)&&!(Symbol.toStringTag in e)&&!(Symbol.iterator in e)},IR=Xt("Date"),LR=Xt("File"),RR=Xt("Blob"),NR=Xt("FileList"),FR=e=>ei(e)&&Mt(e.pipe),YR=e=>{let t;return e&&(typeof FormData=="function"&&e instanceof FormData||Mt(e.append)&&((t=Xa(e))==="formdata"||t==="object"&&Mt(e.toString)&&e.toString()==="[object FormData]"))},BR=Xt("URLSearchParams"),[HR,jR,VR,WR]=["ReadableStream","Request","Response","Headers"].map(Xt),UR=e=>e.trim?e.trim():e.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,"");function po(e,t,{allOwnKeys:n=!1}={}){if(e===null||typeof e>"u")return;let r,s;if(typeof e!="object"&&(e=[e]),vs(e))for(r=0,s=e.length;r0;)if(s=n[r],t===s.toLowerCase())return s;return null}const ir=typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:global,Np=e=>!Xs(e)&&e!==ir;function bl(){const{caseless:e}=Np(this)&&this||{},t={},n=(r,s)=>{const o=e&&Rp(t,s)||s;Uo(t[o])&&Uo(r)?t[o]=bl(t[o],r):Uo(r)?t[o]=bl({},r):vs(r)?t[o]=r.slice():t[o]=r};for(let r=0,s=arguments.length;r(po(t,(s,o)=>{n&&Mt(s)?e[o]=Ap(s,n):e[o]=s},{allOwnKeys:r}),e),KR=e=>(e.charCodeAt(0)===65279&&(e=e.slice(1)),e),GR=(e,t,n,r)=>{e.prototype=Object.create(t.prototype,r),e.prototype.constructor=e,Object.defineProperty(e,"super",{value:t.prototype}),n&&Object.assign(e.prototype,n)},qR=(e,t,n,r)=>{let s,o,a;const i={};if(t=t||{},e==null)return t;do{for(s=Object.getOwnPropertyNames(e),o=s.length;o-- >0;)a=s[o],(!r||r(a,e,t))&&!i[a]&&(t[a]=e[a],i[a]=!0);e=n!==!1&&Ru(e)}while(e&&(!n||n(e,t))&&e!==Object.prototype);return t},ZR=(e,t,n)=>{e=String(e),(n===void 0||n>e.length)&&(n=e.length),n-=t.length;const r=e.indexOf(t,n);return r!==-1&&r===n},JR=e=>{if(!e)return null;if(vs(e))return e;let t=e.length;if(!Lp(t))return null;const n=new Array(t);for(;t-- >0;)n[t]=e[t];return n},XR=(e=>t=>e&&t instanceof e)(typeof Uint8Array<"u"&&Ru(Uint8Array)),QR=(e,t)=>{const r=(e&&e[Symbol.iterator]).call(e);let s;for(;(s=r.next())&&!s.done;){const o=s.value;t.call(e,o[0],o[1])}},eN=(e,t)=>{let n;const r=[];for(;(n=e.exec(t))!==null;)r.push(n);return r},tN=Xt("HTMLFormElement"),nN=e=>e.toLowerCase().replace(/[-_\s]([a-z\d])(\w*)/g,function(n,r,s){return r.toUpperCase()+s}),Yd=(({hasOwnProperty:e})=>(t,n)=>e.call(t,n))(Object.prototype),rN=Xt("RegExp"),Fp=(e,t)=>{const n=Object.getOwnPropertyDescriptors(e),r={};po(n,(s,o)=>{let a;(a=t(s,o,e))!==!1&&(r[o]=a||s)}),Object.defineProperties(e,r)},sN=e=>{Fp(e,(t,n)=>{if(Mt(e)&&["arguments","caller","callee"].indexOf(n)!==-1)return!1;const r=e[n];if(Mt(r)){if(t.enumerable=!1,"writable"in t){t.writable=!1;return}t.set||(t.set=()=>{throw Error("Can not rewrite read-only method '"+n+"'")})}})},oN=(e,t)=>{const n={},r=s=>{s.forEach(o=>{n[o]=!0})};return vs(e)?r(e):r(String(e).split(t)),n},aN=()=>{},iN=(e,t)=>e!=null&&Number.isFinite(e=+e)?e:t,xi="abcdefghijklmnopqrstuvwxyz",Bd="0123456789",Yp={DIGIT:Bd,ALPHA:xi,ALPHA_DIGIT:xi+xi.toUpperCase()+Bd},lN=(e=16,t=Yp.ALPHA_DIGIT)=>{let n="";const{length:r}=t;for(;e--;)n+=t[Math.random()*r|0];return n};function uN(e){return!!(e&&Mt(e.append)&&e[Symbol.toStringTag]==="FormData"&&e[Symbol.iterator])}const cN=e=>{const t=new Array(10),n=(r,s)=>{if(ei(r)){if(t.indexOf(r)>=0)return;if(!("toJSON"in r)){t[s]=r;const o=vs(r)?[]:{};return po(r,(a,i)=>{const l=n(a,s+1);!Xs(l)&&(o[i]=l)}),t[s]=void 0,o}}return r};return n(e,0)},fN=Xt("AsyncFunction"),dN=e=>e&&(ei(e)||Mt(e))&&Mt(e.then)&&Mt(e.catch),Bp=((e,t)=>e?setImmediate:t?((n,r)=>(ir.addEventListener("message",({source:s,data:o})=>{s===ir&&o===n&&r.length&&r.shift()()},!1),s=>{r.push(s),ir.postMessage(n,"*")}))(`axios@${Math.random()}`,[]):n=>setTimeout(n))(typeof setImmediate=="function",Mt(ir.postMessage)),hN=typeof queueMicrotask<"u"?queueMicrotask.bind(ir):typeof process<"u"&&process.nextTick||Bp,x={isArray:vs,isArrayBuffer:Ip,isBuffer:kR,isFormData:YR,isArrayBufferView:xR,isString:PR,isNumber:Lp,isBoolean:AR,isObject:ei,isPlainObject:Uo,isReadableStream:HR,isRequest:jR,isResponse:VR,isHeaders:WR,isUndefined:Xs,isDate:IR,isFile:LR,isBlob:RR,isRegExp:rN,isFunction:Mt,isStream:FR,isURLSearchParams:BR,isTypedArray:XR,isFileList:NR,forEach:po,merge:bl,extend:zR,trim:UR,stripBOM:KR,inherits:GR,toFlatObject:qR,kindOf:Xa,kindOfTest:Xt,endsWith:ZR,toArray:JR,forEachEntry:QR,matchAll:eN,isHTMLForm:tN,hasOwnProperty:Yd,hasOwnProp:Yd,reduceDescriptors:Fp,freezeMethods:sN,toObjectSet:oN,toCamelCase:nN,noop:aN,toFiniteNumber:iN,findKey:Rp,global:ir,isContextDefined:Np,ALPHABET:Yp,generateString:lN,isSpecCompliantForm:uN,toJSONObject:cN,isAsyncFn:fN,isThenable:dN,setImmediate:Bp,asap:hN};function ve(e,t,n,r,s){Error.call(this),Error.captureStackTrace?Error.captureStackTrace(this,this.constructor):this.stack=new Error().stack,this.message=e,this.name="AxiosError",t&&(this.code=t),n&&(this.config=n),r&&(this.request=r),s&&(this.response=s)}x.inherits(ve,Error,{toJSON:function(){return{message:this.message,name:this.name,description:this.description,number:this.number,fileName:this.fileName,lineNumber:this.lineNumber,columnNumber:this.columnNumber,stack:this.stack,config:x.toJSONObject(this.config),code:this.code,status:this.response&&this.response.status?this.response.status:null}}});const Hp=ve.prototype,jp={};["ERR_BAD_OPTION_VALUE","ERR_BAD_OPTION","ECONNABORTED","ETIMEDOUT","ERR_NETWORK","ERR_FR_TOO_MANY_REDIRECTS","ERR_DEPRECATED","ERR_BAD_RESPONSE","ERR_BAD_REQUEST","ERR_CANCELED","ERR_NOT_SUPPORT","ERR_INVALID_URL"].forEach(e=>{jp[e]={value:e}});Object.defineProperties(ve,jp);Object.defineProperty(Hp,"isAxiosError",{value:!0});ve.from=(e,t,n,r,s,o)=>{const a=Object.create(Hp);return x.toFlatObject(e,a,function(l){return l!==Error.prototype},i=>i!=="isAxiosError"),ve.call(a,e.message,t,n,r,s),a.cause=e,a.name=e.name,o&&Object.assign(a,o),a};const vN=null;function wl(e){return x.isPlainObject(e)||x.isArray(e)}function Vp(e){return x.endsWith(e,"[]")?e.slice(0,-2):e}function Hd(e,t,n){return e?e.concat(t).map(function(s,o){return s=Vp(s),!n&&o?"["+s+"]":s}).join(n?".":""):t}function mN(e){return x.isArray(e)&&!e.some(wl)}const pN=x.toFlatObject(x,{},null,function(t){return/^is[A-Z]/.test(t)});function ti(e,t,n){if(!x.isObject(e))throw new TypeError("target must be an object");t=t||new FormData,n=x.toFlatObject(n,{metaTokens:!0,dots:!1,indexes:!1},!1,function(m,p){return!x.isUndefined(p[m])});const r=n.metaTokens,s=n.visitor||c,o=n.dots,a=n.indexes,l=(n.Blob||typeof Blob<"u"&&Blob)&&x.isSpecCompliantForm(t);if(!x.isFunction(s))throw new TypeError("visitor must be a function");function u(v){if(v===null)return"";if(x.isDate(v))return v.toISOString();if(!l&&x.isBlob(v))throw new ve("Blob is not supported. Use a Buffer instead.");return x.isArrayBuffer(v)||x.isTypedArray(v)?l&&typeof Blob=="function"?new Blob([v]):Buffer.from(v):v}function c(v,m,p){let b=v;if(v&&!p&&typeof v=="object"){if(x.endsWith(m,"{}"))m=r?m:m.slice(0,-2),v=JSON.stringify(v);else if(x.isArray(v)&&mN(v)||(x.isFileList(v)||x.endsWith(m,"[]"))&&(b=x.toArray(v)))return m=Vp(m),b.forEach(function(T,M){!(x.isUndefined(T)||T===null)&&t.append(a===!0?Hd([m],M,o):a===null?m:m+"[]",u(T))}),!1}return wl(v)?!0:(t.append(Hd(p,m,o),u(v)),!1)}const f=[],d=Object.assign(pN,{defaultVisitor:c,convertValue:u,isVisitable:wl});function h(v,m){if(!x.isUndefined(v)){if(f.indexOf(v)!==-1)throw Error("Circular reference detected in "+m.join("."));f.push(v),x.forEach(v,function(b,S){(!(x.isUndefined(b)||b===null)&&s.call(t,b,x.isString(S)?S.trim():S,m,d))===!0&&h(b,m?m.concat(S):[S])}),f.pop()}}if(!x.isObject(e))throw new TypeError("data must be an object");return h(e),t}function jd(e){const t={"!":"%21","'":"%27","(":"%28",")":"%29","~":"%7E","%20":"+","%00":"\0"};return encodeURIComponent(e).replace(/[!'()~]|%20|%00/g,function(r){return t[r]})}function Nu(e,t){this._pairs=[],e&&ti(e,this,t)}const Wp=Nu.prototype;Wp.append=function(t,n){this._pairs.push([t,n])};Wp.toString=function(t){const n=t?function(r){return t.call(this,r,jd)}:jd;return this._pairs.map(function(s){return n(s[0])+"="+n(s[1])},"").join("&")};function gN(e){return encodeURIComponent(e).replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%20/g,"+").replace(/%5B/gi,"[").replace(/%5D/gi,"]")}function Up(e,t,n){if(!t)return e;const r=n&&n.encode||gN,s=n&&n.serialize;let o;if(s?o=s(t,n):o=x.isURLSearchParams(t)?t.toString():new Nu(t,n).toString(r),o){const a=e.indexOf("#");a!==-1&&(e=e.slice(0,a)),e+=(e.indexOf("?")===-1?"?":"&")+o}return e}class Vd{constructor(){this.handlers=[]}use(t,n,r){return this.handlers.push({fulfilled:t,rejected:n,synchronous:r?r.synchronous:!1,runWhen:r?r.runWhen:null}),this.handlers.length-1}eject(t){this.handlers[t]&&(this.handlers[t]=null)}clear(){this.handlers&&(this.handlers=[])}forEach(t){x.forEach(this.handlers,function(r){r!==null&&t(r)})}}const zp={silentJSONParsing:!0,forcedJSONParsing:!0,clarifyTimeoutError:!1},yN=typeof URLSearchParams<"u"?URLSearchParams:Nu,bN=typeof FormData<"u"?FormData:null,wN=typeof Blob<"u"?Blob:null,_N={isBrowser:!0,classes:{URLSearchParams:yN,FormData:bN,Blob:wN},protocols:["http","https","file","blob","url","data"]},Fu=typeof window<"u"&&typeof document<"u",DN=(e=>Fu&&["ReactNative","NativeScript","NS"].indexOf(e)<0)(typeof navigator<"u"&&navigator.product),CN=typeof WorkerGlobalScope<"u"&&self instanceof WorkerGlobalScope&&typeof self.importScripts=="function",SN=Fu&&window.location.href||"http://localhost",$N=Object.freeze(Object.defineProperty({__proto__:null,hasBrowserEnv:Fu,hasStandardBrowserEnv:DN,hasStandardBrowserWebWorkerEnv:CN,origin:SN},Symbol.toStringTag,{value:"Module"})),zt={...$N,..._N};function TN(e,t){return ti(e,new zt.classes.URLSearchParams,Object.assign({visitor:function(n,r,s,o){return zt.isNode&&x.isBuffer(n)?(this.append(r,n.toString("base64")),!1):o.defaultVisitor.apply(this,arguments)}},t))}function EN(e){return x.matchAll(/\w+|\[(\w*)]/g,e).map(t=>t[0]==="[]"?"":t[1]||t[0])}function ON(e){const t={},n=Object.keys(e);let r;const s=n.length;let o;for(r=0;r=n.length;return a=!a&&x.isArray(s)?s.length:a,l?(x.hasOwnProp(s,a)?s[a]=[s[a],r]:s[a]=r,!i):((!s[a]||!x.isObject(s[a]))&&(s[a]=[]),t(n,r,s[a],o)&&x.isArray(s[a])&&(s[a]=ON(s[a])),!i)}if(x.isFormData(e)&&x.isFunction(e.entries)){const n={};return x.forEachEntry(e,(r,s)=>{t(EN(r),s,n,0)}),n}return null}function MN(e,t,n){if(x.isString(e))try{return(t||JSON.parse)(e),x.trim(e)}catch(r){if(r.name!=="SyntaxError")throw r}return(n||JSON.stringify)(e)}const go={transitional:zp,adapter:["xhr","http","fetch"],transformRequest:[function(t,n){const r=n.getContentType()||"",s=r.indexOf("application/json")>-1,o=x.isObject(t);if(o&&x.isHTMLForm(t)&&(t=new FormData(t)),x.isFormData(t))return s?JSON.stringify(Kp(t)):t;if(x.isArrayBuffer(t)||x.isBuffer(t)||x.isStream(t)||x.isFile(t)||x.isBlob(t)||x.isReadableStream(t))return t;if(x.isArrayBufferView(t))return t.buffer;if(x.isURLSearchParams(t))return n.setContentType("application/x-www-form-urlencoded;charset=utf-8",!1),t.toString();let i;if(o){if(r.indexOf("application/x-www-form-urlencoded")>-1)return TN(t,this.formSerializer).toString();if((i=x.isFileList(t))||r.indexOf("multipart/form-data")>-1){const l=this.env&&this.env.FormData;return ti(i?{"files[]":t}:t,l&&new l,this.formSerializer)}}return o||s?(n.setContentType("application/json",!1),MN(t)):t}],transformResponse:[function(t){const n=this.transitional||go.transitional,r=n&&n.forcedJSONParsing,s=this.responseType==="json";if(x.isResponse(t)||x.isReadableStream(t))return t;if(t&&x.isString(t)&&(r&&!this.responseType||s)){const a=!(n&&n.silentJSONParsing)&&s;try{return JSON.parse(t)}catch(i){if(a)throw i.name==="SyntaxError"?ve.from(i,ve.ERR_BAD_RESPONSE,this,null,this.response):i}}return t}],timeout:0,xsrfCookieName:"XSRF-TOKEN",xsrfHeaderName:"X-XSRF-TOKEN",maxContentLength:-1,maxBodyLength:-1,env:{FormData:zt.classes.FormData,Blob:zt.classes.Blob},validateStatus:function(t){return t>=200&&t<300},headers:{common:{Accept:"application/json, text/plain, */*","Content-Type":void 0}}};x.forEach(["delete","get","head","post","put","patch"],e=>{go.headers[e]={}});const kN=x.toObjectSet(["age","authorization","content-length","content-type","etag","expires","from","host","if-modified-since","if-unmodified-since","last-modified","location","max-forwards","proxy-authorization","referer","retry-after","user-agent"]),xN=e=>{const t={};let n,r,s;return e&&e.split(` +`).forEach(function(a){s=a.indexOf(":"),n=a.substring(0,s).trim().toLowerCase(),r=a.substring(s+1).trim(),!(!n||t[n]&&kN[n])&&(n==="set-cookie"?t[n]?t[n].push(r):t[n]=[r]:t[n]=t[n]?t[n]+", "+r:r)}),t},Wd=Symbol("internals");function Ss(e){return e&&String(e).trim().toLowerCase()}function zo(e){return e===!1||e==null?e:x.isArray(e)?e.map(zo):String(e)}function PN(e){const t=Object.create(null),n=/([^\s,;=]+)\s*(?:=\s*([^,;]+))?/g;let r;for(;r=n.exec(e);)t[r[1]]=r[2];return t}const AN=e=>/^[-_a-zA-Z0-9^`|~,!#$%&'*+.]+$/.test(e.trim());function Pi(e,t,n,r,s){if(x.isFunction(r))return r.call(this,t,n);if(s&&(t=n),!!x.isString(t)){if(x.isString(r))return t.indexOf(r)!==-1;if(x.isRegExp(r))return r.test(t)}}function IN(e){return e.trim().toLowerCase().replace(/([a-z\d])(\w*)/g,(t,n,r)=>n.toUpperCase()+r)}function LN(e,t){const n=x.toCamelCase(" "+t);["get","set","has"].forEach(r=>{Object.defineProperty(e,r+n,{value:function(s,o,a){return this[r].call(this,t,s,o,a)},configurable:!0})})}class Dt{constructor(t){t&&this.set(t)}set(t,n,r){const s=this;function o(i,l,u){const c=Ss(l);if(!c)throw new Error("header name must be a non-empty string");const f=x.findKey(s,c);(!f||s[f]===void 0||u===!0||u===void 0&&s[f]!==!1)&&(s[f||l]=zo(i))}const a=(i,l)=>x.forEach(i,(u,c)=>o(u,c,l));if(x.isPlainObject(t)||t instanceof this.constructor)a(t,n);else if(x.isString(t)&&(t=t.trim())&&!AN(t))a(xN(t),n);else if(x.isHeaders(t))for(const[i,l]of t.entries())o(l,i,r);else t!=null&&o(n,t,r);return this}get(t,n){if(t=Ss(t),t){const r=x.findKey(this,t);if(r){const s=this[r];if(!n)return s;if(n===!0)return PN(s);if(x.isFunction(n))return n.call(this,s,r);if(x.isRegExp(n))return n.exec(s);throw new TypeError("parser must be boolean|regexp|function")}}}has(t,n){if(t=Ss(t),t){const r=x.findKey(this,t);return!!(r&&this[r]!==void 0&&(!n||Pi(this,this[r],r,n)))}return!1}delete(t,n){const r=this;let s=!1;function o(a){if(a=Ss(a),a){const i=x.findKey(r,a);i&&(!n||Pi(r,r[i],i,n))&&(delete r[i],s=!0)}}return x.isArray(t)?t.forEach(o):o(t),s}clear(t){const n=Object.keys(this);let r=n.length,s=!1;for(;r--;){const o=n[r];(!t||Pi(this,this[o],o,t,!0))&&(delete this[o],s=!0)}return s}normalize(t){const n=this,r={};return x.forEach(this,(s,o)=>{const a=x.findKey(r,o);if(a){n[a]=zo(s),delete n[o];return}const i=t?IN(o):String(o).trim();i!==o&&delete n[o],n[i]=zo(s),r[i]=!0}),this}concat(...t){return this.constructor.concat(this,...t)}toJSON(t){const n=Object.create(null);return x.forEach(this,(r,s)=>{r!=null&&r!==!1&&(n[s]=t&&x.isArray(r)?r.join(", "):r)}),n}[Symbol.iterator](){return Object.entries(this.toJSON())[Symbol.iterator]()}toString(){return Object.entries(this.toJSON()).map(([t,n])=>t+": "+n).join(` +`)}get[Symbol.toStringTag](){return"AxiosHeaders"}static from(t){return t instanceof this?t:new this(t)}static concat(t,...n){const r=new this(t);return n.forEach(s=>r.set(s)),r}static accessor(t){const r=(this[Wd]=this[Wd]={accessors:{}}).accessors,s=this.prototype;function o(a){const i=Ss(a);r[i]||(LN(s,a),r[i]=!0)}return x.isArray(t)?t.forEach(o):o(t),this}}Dt.accessor(["Content-Type","Content-Length","Accept","Accept-Encoding","User-Agent","Authorization"]);x.reduceDescriptors(Dt.prototype,({value:e},t)=>{let n=t[0].toUpperCase()+t.slice(1);return{get:()=>e,set(r){this[n]=r}}});x.freezeMethods(Dt);function Ai(e,t){const n=this||go,r=t||n,s=Dt.from(r.headers);let o=r.data;return x.forEach(e,function(i){o=i.call(n,o,s.normalize(),t?t.status:void 0)}),s.normalize(),o}function Gp(e){return!!(e&&e.__CANCEL__)}function ms(e,t,n){ve.call(this,e??"canceled",ve.ERR_CANCELED,t,n),this.name="CanceledError"}x.inherits(ms,ve,{__CANCEL__:!0});function qp(e,t,n){const r=n.config.validateStatus;!n.status||!r||r(n.status)?e(n):t(new ve("Request failed with status code "+n.status,[ve.ERR_BAD_REQUEST,ve.ERR_BAD_RESPONSE][Math.floor(n.status/100)-4],n.config,n.request,n))}function RN(e){const t=/^([-+\w]{1,25})(:?\/\/|:)/.exec(e);return t&&t[1]||""}function NN(e,t){e=e||10;const n=new Array(e),r=new Array(e);let s=0,o=0,a;return t=t!==void 0?t:1e3,function(l){const u=Date.now(),c=r[o];a||(a=u),n[s]=l,r[s]=u;let f=o,d=0;for(;f!==s;)d+=n[f++],f=f%e;if(s=(s+1)%e,s===o&&(o=(o+1)%e),u-a{n=c,s=null,o&&(clearTimeout(o),o=null),e.apply(null,u)};return[(...u)=>{const c=Date.now(),f=c-n;f>=r?a(u,c):(s=u,o||(o=setTimeout(()=>{o=null,a(s)},r-f)))},()=>s&&a(s)]}const wa=(e,t,n=3)=>{let r=0;const s=NN(50,250);return FN(o=>{const a=o.loaded,i=o.lengthComputable?o.total:void 0,l=a-r,u=s(l),c=a<=i;r=a;const f={loaded:a,total:i,progress:i?a/i:void 0,bytes:l,rate:u||void 0,estimated:u&&i&&c?(i-a)/u:void 0,event:o,lengthComputable:i!=null,[t?"download":"upload"]:!0};e(f)},n)},Ud=(e,t)=>{const n=e!=null;return[r=>t[0]({lengthComputable:n,total:e,loaded:r}),t[1]]},zd=e=>(...t)=>x.asap(()=>e(...t)),YN=zt.hasStandardBrowserEnv?function(){const t=/(msie|trident)/i.test(navigator.userAgent),n=document.createElement("a");let r;function s(o){let a=o;return t&&(n.setAttribute("href",a),a=n.href),n.setAttribute("href",a),{href:n.href,protocol:n.protocol?n.protocol.replace(/:$/,""):"",host:n.host,search:n.search?n.search.replace(/^\?/,""):"",hash:n.hash?n.hash.replace(/^#/,""):"",hostname:n.hostname,port:n.port,pathname:n.pathname.charAt(0)==="/"?n.pathname:"/"+n.pathname}}return r=s(window.location.href),function(a){const i=x.isString(a)?s(a):a;return i.protocol===r.protocol&&i.host===r.host}}():function(){return function(){return!0}}(),BN=zt.hasStandardBrowserEnv?{write(e,t,n,r,s,o){const a=[e+"="+encodeURIComponent(t)];x.isNumber(n)&&a.push("expires="+new Date(n).toGMTString()),x.isString(r)&&a.push("path="+r),x.isString(s)&&a.push("domain="+s),o===!0&&a.push("secure"),document.cookie=a.join("; ")},read(e){const t=document.cookie.match(new RegExp("(^|;\\s*)("+e+")=([^;]*)"));return t?decodeURIComponent(t[3]):null},remove(e){this.write(e,"",Date.now()-864e5)}}:{write(){},read(){return null},remove(){}};function HN(e){return/^([a-z][a-z\d+\-.]*:)?\/\//i.test(e)}function jN(e,t){return t?e.replace(/\/?\/$/,"")+"/"+t.replace(/^\/+/,""):e}function Zp(e,t){return e&&!HN(t)?jN(e,t):t}const Kd=e=>e instanceof Dt?{...e}:e;function gr(e,t){t=t||{};const n={};function r(u,c,f){return x.isPlainObject(u)&&x.isPlainObject(c)?x.merge.call({caseless:f},u,c):x.isPlainObject(c)?x.merge({},c):x.isArray(c)?c.slice():c}function s(u,c,f){if(x.isUndefined(c)){if(!x.isUndefined(u))return r(void 0,u,f)}else return r(u,c,f)}function o(u,c){if(!x.isUndefined(c))return r(void 0,c)}function a(u,c){if(x.isUndefined(c)){if(!x.isUndefined(u))return r(void 0,u)}else return r(void 0,c)}function i(u,c,f){if(f in t)return r(u,c);if(f in e)return r(void 0,u)}const l={url:o,method:o,data:o,baseURL:a,transformRequest:a,transformResponse:a,paramsSerializer:a,timeout:a,timeoutMessage:a,withCredentials:a,withXSRFToken:a,adapter:a,responseType:a,xsrfCookieName:a,xsrfHeaderName:a,onUploadProgress:a,onDownloadProgress:a,decompress:a,maxContentLength:a,maxBodyLength:a,beforeRedirect:a,transport:a,httpAgent:a,httpsAgent:a,cancelToken:a,socketPath:a,responseEncoding:a,validateStatus:i,headers:(u,c)=>s(Kd(u),Kd(c),!0)};return x.forEach(Object.keys(Object.assign({},e,t)),function(c){const f=l[c]||s,d=f(e[c],t[c],c);x.isUndefined(d)&&f!==i||(n[c]=d)}),n}const Jp=e=>{const t=gr({},e);let{data:n,withXSRFToken:r,xsrfHeaderName:s,xsrfCookieName:o,headers:a,auth:i}=t;t.headers=a=Dt.from(a),t.url=Up(Zp(t.baseURL,t.url),e.params,e.paramsSerializer),i&&a.set("Authorization","Basic "+btoa((i.username||"")+":"+(i.password?unescape(encodeURIComponent(i.password)):"")));let l;if(x.isFormData(n)){if(zt.hasStandardBrowserEnv||zt.hasStandardBrowserWebWorkerEnv)a.setContentType(void 0);else if((l=a.getContentType())!==!1){const[u,...c]=l?l.split(";").map(f=>f.trim()).filter(Boolean):[];a.setContentType([u||"multipart/form-data",...c].join("; "))}}if(zt.hasStandardBrowserEnv&&(r&&x.isFunction(r)&&(r=r(t)),r||r!==!1&&YN(t.url))){const u=s&&o&&BN.read(o);u&&a.set(s,u)}return t},VN=typeof XMLHttpRequest<"u",WN=VN&&function(e){return new Promise(function(n,r){const s=Jp(e);let o=s.data;const a=Dt.from(s.headers).normalize();let{responseType:i,onUploadProgress:l,onDownloadProgress:u}=s,c,f,d,h,v;function m(){h&&h(),v&&v(),s.cancelToken&&s.cancelToken.unsubscribe(c),s.signal&&s.signal.removeEventListener("abort",c)}let p=new XMLHttpRequest;p.open(s.method.toUpperCase(),s.url,!0),p.timeout=s.timeout;function b(){if(!p)return;const T=Dt.from("getAllResponseHeaders"in p&&p.getAllResponseHeaders()),D={data:!i||i==="text"||i==="json"?p.responseText:p.response,status:p.status,statusText:p.statusText,headers:T,config:e,request:p};qp(function(E){n(E),m()},function(E){r(E),m()},D),p=null}"onloadend"in p?p.onloadend=b:p.onreadystatechange=function(){!p||p.readyState!==4||p.status===0&&!(p.responseURL&&p.responseURL.indexOf("file:")===0)||setTimeout(b)},p.onabort=function(){p&&(r(new ve("Request aborted",ve.ECONNABORTED,e,p)),p=null)},p.onerror=function(){r(new ve("Network Error",ve.ERR_NETWORK,e,p)),p=null},p.ontimeout=function(){let M=s.timeout?"timeout of "+s.timeout+"ms exceeded":"timeout exceeded";const D=s.transitional||zp;s.timeoutErrorMessage&&(M=s.timeoutErrorMessage),r(new ve(M,D.clarifyTimeoutError?ve.ETIMEDOUT:ve.ECONNABORTED,e,p)),p=null},o===void 0&&a.setContentType(null),"setRequestHeader"in p&&x.forEach(a.toJSON(),function(M,D){p.setRequestHeader(D,M)}),x.isUndefined(s.withCredentials)||(p.withCredentials=!!s.withCredentials),i&&i!=="json"&&(p.responseType=s.responseType),u&&([d,v]=wa(u,!0),p.addEventListener("progress",d)),l&&p.upload&&([f,h]=wa(l),p.upload.addEventListener("progress",f),p.upload.addEventListener("loadend",h)),(s.cancelToken||s.signal)&&(c=T=>{p&&(r(!T||T.type?new ms(null,e,p):T),p.abort(),p=null)},s.cancelToken&&s.cancelToken.subscribe(c),s.signal&&(s.signal.aborted?c():s.signal.addEventListener("abort",c)));const S=RN(s.url);if(S&&zt.protocols.indexOf(S)===-1){r(new ve("Unsupported protocol "+S+":",ve.ERR_BAD_REQUEST,e));return}p.send(o||null)})},UN=(e,t)=>{let n=new AbortController,r;const s=function(l){if(!r){r=!0,a();const u=l instanceof Error?l:this.reason;n.abort(u instanceof ve?u:new ms(u instanceof Error?u.message:u))}};let o=t&&setTimeout(()=>{s(new ve(`timeout ${t} of ms exceeded`,ve.ETIMEDOUT))},t);const a=()=>{e&&(o&&clearTimeout(o),o=null,e.forEach(l=>{l&&(l.removeEventListener?l.removeEventListener("abort",s):l.unsubscribe(s))}),e=null)};e.forEach(l=>l&&l.addEventListener&&l.addEventListener("abort",s));const{signal:i}=n;return i.unsubscribe=a,[i,()=>{o&&clearTimeout(o),o=null}]},zN=function*(e,t){let n=e.byteLength;if(!t||n{const o=KN(e,t,s);let a=0,i,l=u=>{i||(i=!0,r&&r(u))};return new ReadableStream({async pull(u){try{const{done:c,value:f}=await o.next();if(c){l(),u.close();return}let d=f.byteLength;if(n){let h=a+=d;n(h)}u.enqueue(new Uint8Array(f))}catch(c){throw l(c),c}},cancel(u){return l(u),o.return()}},{highWaterMark:2})},ni=typeof fetch=="function"&&typeof Request=="function"&&typeof Response=="function",Xp=ni&&typeof ReadableStream=="function",_l=ni&&(typeof TextEncoder=="function"?(e=>t=>e.encode(t))(new TextEncoder):async e=>new Uint8Array(await new Response(e).arrayBuffer())),Qp=(e,...t)=>{try{return!!e(...t)}catch{return!1}},GN=Xp&&Qp(()=>{let e=!1;const t=new Request(zt.origin,{body:new ReadableStream,method:"POST",get duplex(){return e=!0,"half"}}).headers.has("Content-Type");return e&&!t}),qd=64*1024,Dl=Xp&&Qp(()=>x.isReadableStream(new Response("").body)),_a={stream:Dl&&(e=>e.body)};ni&&(e=>{["text","arrayBuffer","blob","formData","stream"].forEach(t=>{!_a[t]&&(_a[t]=x.isFunction(e[t])?n=>n[t]():(n,r)=>{throw new ve(`Response type '${t}' is not supported`,ve.ERR_NOT_SUPPORT,r)})})})(new Response);const qN=async e=>{if(e==null)return 0;if(x.isBlob(e))return e.size;if(x.isSpecCompliantForm(e))return(await new Request(e).arrayBuffer()).byteLength;if(x.isArrayBufferView(e)||x.isArrayBuffer(e))return e.byteLength;if(x.isURLSearchParams(e)&&(e=e+""),x.isString(e))return(await _l(e)).byteLength},ZN=async(e,t)=>{const n=x.toFiniteNumber(e.getContentLength());return n??qN(t)},JN=ni&&(async e=>{let{url:t,method:n,data:r,signal:s,cancelToken:o,timeout:a,onDownloadProgress:i,onUploadProgress:l,responseType:u,headers:c,withCredentials:f="same-origin",fetchOptions:d}=Jp(e);u=u?(u+"").toLowerCase():"text";let[h,v]=s||o||a?UN([s,o],a):[],m,p;const b=()=>{!m&&setTimeout(()=>{h&&h.unsubscribe()}),m=!0};let S;try{if(l&&GN&&n!=="get"&&n!=="head"&&(S=await ZN(c,r))!==0){let C=new Request(t,{method:"POST",body:r,duplex:"half"}),E;if(x.isFormData(r)&&(E=C.headers.get("content-type"))&&c.setContentType(E),C.body){const[P,$]=Ud(S,wa(zd(l)));r=Gd(C.body,qd,P,$,_l)}}x.isString(f)||(f=f?"include":"omit"),p=new Request(t,{...d,signal:h,method:n.toUpperCase(),headers:c.normalize().toJSON(),body:r,duplex:"half",credentials:f});let T=await fetch(p);const M=Dl&&(u==="stream"||u==="response");if(Dl&&(i||M)){const C={};["status","statusText","headers"].forEach(I=>{C[I]=T[I]});const E=x.toFiniteNumber(T.headers.get("content-length")),[P,$]=i&&Ud(E,wa(zd(i),!0))||[];T=new Response(Gd(T.body,qd,P,()=>{$&&$(),M&&b()},_l),C)}u=u||"text";let D=await _a[x.findKey(_a,u)||"text"](T,e);return!M&&b(),v&&v(),await new Promise((C,E)=>{qp(C,E,{data:D,headers:Dt.from(T.headers),status:T.status,statusText:T.statusText,config:e,request:p})})}catch(T){throw b(),T&&T.name==="TypeError"&&/fetch/i.test(T.message)?Object.assign(new ve("Network Error",ve.ERR_NETWORK,e,p),{cause:T.cause||T}):ve.from(T,T&&T.code,e,p)}}),Cl={http:vN,xhr:WN,fetch:JN};x.forEach(Cl,(e,t)=>{if(e){try{Object.defineProperty(e,"name",{value:t})}catch{}Object.defineProperty(e,"adapterName",{value:t})}});const Zd=e=>`- ${e}`,XN=e=>x.isFunction(e)||e===null||e===!1,eg={getAdapter:e=>{e=x.isArray(e)?e:[e];const{length:t}=e;let n,r;const s={};for(let o=0;o`adapter ${i} `+(l===!1?"is not supported by the environment":"is not available in the build"));let a=t?o.length>1?`since : `+o.map(Zd).join(` -`):" "+Zd(o[0]):"as no adapter specified";throw new ve("There is no suitable adapter to dispatch the request "+a,"ERR_NOT_SUPPORT")}return r},adapters:Sl};function Ii(e){if(e.cancelToken&&e.cancelToken.throwIfRequested(),e.signal&&e.signal.aborted)throw new ms(null,e)}function Jd(e){return Ii(e),e.headers=Dt.from(e.headers),e.data=Ai.call(e,e.transformRequest),["post","put","patch"].indexOf(e.method)!==-1&&e.headers.setContentType("application/x-www-form-urlencoded",!1),tg.getAdapter(e.adapter||go.adapter)(e).then(function(r){return Ii(e),r.data=Ai.call(e,e.transformResponse,r),r.headers=Dt.from(r.headers),r},function(r){return qp(r)||(Ii(e),r&&r.response&&(r.response.data=Ai.call(e,e.transformResponse,r.response),r.response.headers=Dt.from(r.response.headers))),Promise.reject(r)})}const ng="1.7.3",Bu={};["object","boolean","number","function","string","symbol"].forEach((e,t)=>{Bu[e]=function(r){return typeof r===e||"a"+(t<1?"n ":" ")+e}});const Xd={};Bu.transitional=function(t,n,r){function s(o,a){return"[Axios v"+ng+"] Transitional option '"+o+"'"+a+(r?". "+r:"")}return(o,a,i)=>{if(t===!1)throw new ve(s(a," has been removed"+(n?" in "+n:"")),ve.ERR_DEPRECATED);return n&&!Xd[a]&&(Xd[a]=!0,console.warn(s(a," has been deprecated since v"+n+" and will be removed in the near future"))),t?t(o,a,i):!0}};function nF(e,t,n){if(typeof e!="object")throw new ve("options must be an object",ve.ERR_BAD_OPTION_VALUE);const r=Object.keys(e);let s=r.length;for(;s-- >0;){const o=r[s],a=t[o];if(a){const i=e[o],l=i===void 0||a(i,o,e);if(l!==!0)throw new ve("option "+o+" must be "+l,ve.ERR_BAD_OPTION_VALUE);continue}if(n!==!0)throw new ve("Unknown option "+o,ve.ERR_BAD_OPTION)}}const $l={assertOptions:nF,validators:Bu},Mn=$l.validators;class dr{constructor(t){this.defaults=t,this.interceptors={request:new Vd,response:new Vd}}async request(t,n){try{return await this._request(t,n)}catch(r){if(r instanceof Error){let s;Error.captureStackTrace?Error.captureStackTrace(s={}):s=new Error;const o=s.stack?s.stack.replace(/^.+\n/,""):"";try{r.stack?o&&!String(r.stack).endsWith(o.replace(/^.+\n.+\n/,""))&&(r.stack+=` -`+o):r.stack=o}catch{}}throw r}}_request(t,n){typeof t=="string"?(n=n||{},n.url=t):n=t||{},n=gr(this.defaults,n);const{transitional:r,paramsSerializer:s,headers:o}=n;r!==void 0&&$l.assertOptions(r,{silentJSONParsing:Mn.transitional(Mn.boolean),forcedJSONParsing:Mn.transitional(Mn.boolean),clarifyTimeoutError:Mn.transitional(Mn.boolean)},!1),s!=null&&(k.isFunction(s)?n.paramsSerializer={serialize:s}:$l.assertOptions(s,{encode:Mn.function,serialize:Mn.function},!0)),n.method=(n.method||this.defaults.method||"get").toLowerCase();let a=o&&k.merge(o.common,o[n.method]);o&&k.forEach(["delete","get","head","post","put","patch","common"],v=>{delete o[v]}),n.headers=Dt.concat(a,o);const i=[];let l=!0;this.interceptors.request.forEach(function(m){typeof m.runWhen=="function"&&m.runWhen(n)===!1||(l=l&&m.synchronous,i.unshift(m.fulfilled,m.rejected))});const u=[];this.interceptors.response.forEach(function(m){u.push(m.fulfilled,m.rejected)});let c,f=0,d;if(!l){const v=[Jd.bind(this),void 0];for(v.unshift.apply(v,i),v.push.apply(v,u),d=v.length,c=Promise.resolve(n);f{if(!r._listeners)return;let o=r._listeners.length;for(;o-- >0;)r._listeners[o](s);r._listeners=null}),this.promise.then=s=>{let o;const a=new Promise(i=>{r.subscribe(i),o=i}).then(s);return a.cancel=function(){r.unsubscribe(o)},a},t(function(o,a,i){r.reason||(r.reason=new ms(o,a,i),n(r.reason))})}throwIfRequested(){if(this.reason)throw this.reason}subscribe(t){if(this.reason){t(this.reason);return}this._listeners?this._listeners.push(t):this._listeners=[t]}unsubscribe(t){if(!this._listeners)return;const n=this._listeners.indexOf(t);n!==-1&&this._listeners.splice(n,1)}static source(){let t;return{token:new Hu(function(s){t=s}),cancel:t}}}function rF(e){return function(n){return e.apply(null,n)}}function sF(e){return k.isObject(e)&&e.isAxiosError===!0}const Tl={Continue:100,SwitchingProtocols:101,Processing:102,EarlyHints:103,Ok:200,Created:201,Accepted:202,NonAuthoritativeInformation:203,NoContent:204,ResetContent:205,PartialContent:206,MultiStatus:207,AlreadyReported:208,ImUsed:226,MultipleChoices:300,MovedPermanently:301,Found:302,SeeOther:303,NotModified:304,UseProxy:305,Unused:306,TemporaryRedirect:307,PermanentRedirect:308,BadRequest:400,Unauthorized:401,PaymentRequired:402,Forbidden:403,NotFound:404,MethodNotAllowed:405,NotAcceptable:406,ProxyAuthenticationRequired:407,RequestTimeout:408,Conflict:409,Gone:410,LengthRequired:411,PreconditionFailed:412,PayloadTooLarge:413,UriTooLong:414,UnsupportedMediaType:415,RangeNotSatisfiable:416,ExpectationFailed:417,ImATeapot:418,MisdirectedRequest:421,UnprocessableEntity:422,Locked:423,FailedDependency:424,TooEarly:425,UpgradeRequired:426,PreconditionRequired:428,TooManyRequests:429,RequestHeaderFieldsTooLarge:431,UnavailableForLegalReasons:451,InternalServerError:500,NotImplemented:501,BadGateway:502,ServiceUnavailable:503,GatewayTimeout:504,HttpVersionNotSupported:505,VariantAlsoNegotiates:506,InsufficientStorage:507,LoopDetected:508,NotExtended:510,NetworkAuthenticationRequired:511};Object.entries(Tl).forEach(([e,t])=>{Tl[t]=e});function rg(e){const t=new dr(e),n=Ip(dr.prototype.request,t);return k.extend(n,dr.prototype,t,{allOwnKeys:!0}),k.extend(n,t,null,{allOwnKeys:!0}),n.create=function(s){return rg(gr(e,s))},n}const Ue=rg(go);Ue.Axios=dr;Ue.CanceledError=ms;Ue.CancelToken=Hu;Ue.isCancel=qp;Ue.VERSION=ng;Ue.toFormData=ti;Ue.AxiosError=ve;Ue.Cancel=Ue.CanceledError;Ue.all=function(t){return Promise.all(t)};Ue.spread=rF;Ue.isAxiosError=sF;Ue.mergeConfig=gr;Ue.AxiosHeaders=Dt;Ue.formToJSON=e=>Gp(k.isHTMLForm(e)?new FormData(e):e);Ue.getAdapter=tg.getAdapter;Ue.HttpStatusCode=Tl;Ue.default=Ue;const oF=(e="",t=iu.stacEndpoint)=>{if(!e||e.includes("http"))return Pr.value=t,Pr;const n=t.split("/"),r=e.split("/");n.pop();for(let s=0;s{if(!e||e.includes("http"))return Ts.value=t,Ts;const n=t.split("/"),r=e.split("/");n.pop();for(let s=0;s{const n=dw();return Object.keys(t).forEach(r=>{r==="dark"?n.themes.value[e][r]=t[r]:n.themes.value[e][r]={...n.themes.value[e][r],...t[r]}}),n},lF=()=>{Gt(async()=>{if(window.location.search){const e=new URLSearchParams(window.location.search);let t,n,r;e.forEach(async(s,o)=>{switch(o){case"indicator":{const{loadSelectedSTAC:a,stac:i}=ri(),l=i?.find(u=>u.id==s);l&&await a(l.href);break}case"x":t=Number(s);break;case"y":n=Number(s);break;case"z":r=Number(s);break;case"datetime":try{Yo.value=new Date(s).toISOString()}catch{Yo.value=new Date().toISOString()}break}}),t&&n&&r&&(ll.value=[t,n,r])}Te([au,ll,Yo],([e,t,n])=>{if("URLSearchParams"in window){const r=new URLSearchParams(window.location.search);e!==""&&r.set("indicator",e),t&&t.length===3&&(r.set("x",t[0]?.toFixed(4)??""),r.set("y",t[1]?.toFixed(4)??""),r.set("z",t[2]?.toFixed(4)??"")),n&&r.set("datetime",n.split("T")?.[0]??"");const s=window.location.pathname+"?"+r.toString();history.pushState(null,"",s)}})})},ZY=e=>{Gt(()=>{const t=e.value?.parentElement;t?.tagName==="EOX-LAYOUT-ITEM"&&(t.classList.remove("bg-surface"),t.style.background="transparent",t.style.border="transparent")})},ri=kw("stac",()=>{const e=oe(null),t=oe(null),n=oe(null),r=Pe(mo);async function s(i=r.stacEndpoint){await Ue.get(i).then(l=>{const u=l.data.links.map(c=>(c.title||(c.title=`${c.rel} ${c.href}`),c));e.value=u}).catch(l=>{throw new Error("error loading assigned STAC endpoint",l)})}async function o(i=""){const l=oF(i);await Ue.get(l.value).then(u=>{t.value=u.data,au.value=t.value?.id??""}).catch(u=>{throw new Error("error loading the selected STAC",u)})}async function a(i=""){const l=aF(i);await Ue.get(l.value).then(u=>{n.value=u.data}).catch(u=>{throw new Error("error loading the selected comparison STAC",u)})}return{stac:e,loadSTAC:s,loadSelectedSTAC:o,loadSelectedCompareSTAC:a,selectedStac:t,selectedCompareStac:n}}),uF=Object.freeze(Object.defineProperty({__proto__:null,useSTAcStore:ri},Symbol.toStringTag,{value:"Module"})),cF=Object.assign({"./Actions.js":kR,"./States.js":Rw,"./stac.js":uF}),sg=(()=>{const e={};for(const[t,n]of Object.entries(cF)){const r=t.split("/").at(-1)?.slice(0,-3).toLowerCase()??"";["keys"].includes(r)||(e[r]=n)}return e})(),fF=$w();function dF(e){window.eodashStore=sg,e.use(Cw).use(fF).use(OR,{}).provide(mo,iu)}const hF=async e=>{const t=Pe(mo),n=r=>{Object.keys(t).forEach(s=>{t[s]=r[s]})};if(e)return n((await import(new URL(e,import.meta.url).href)).default),t;try{const r="/config.js";n((await import(new URL(r,import.meta.url).href)).default)}catch{try{n(await Xe(()=>import("./main-DtPEmPHr.js"),[]).then(async r=>await r.default))}catch{console.error("no dashboard configuration defined")}}return t},JY=async e=>e instanceof Function?await e(sg):e,vF=async(e="",t="",n=!1)=>(e&&t&&(await Xe(async()=>{const{default:s}=await import("./webfontloader-OEBPRw3i.js").then(o=>o.w);return{default:s}},__vite__mapDeps([0,1]))).default.load({classes:!1,custom:{families:[e],urls:[t]},fontactive(s,o){const a=new CSSStyleSheet,i=n?`eo-dash {font-family: ${s};}`:`* {font-family: ${s};}`;a.replaceSync(i),document.adoptedStyleSheets.push(a)},fontinactive(s,o){throw new Error(`error loading font: ${s}`)}}),e),XY=async(e,t)=>{await navigator.clipboard.writeText(e),t.value=!0,setTimeout(()=>{t.value=!1},2e3)},mF=(()=>{const e={...Object.assign({"/widgets/EodashDatePicker.vue":()=>Xe(()=>import("./EodashDatePicker-D2GVtzgD.js"),__vite__mapDeps([2,3,1,4,5,6,7,8])),"/widgets/EodashItemFilter.vue":()=>Xe(()=>import("./EodashItemFilter-D8JcG5Hx.js"),[]),"/widgets/EodashLayerControl.vue":()=>Xe(()=>import("./EodashLayerControl-jZQGHRGG.js"),[]),"/widgets/EodashMap.vue":()=>Xe(()=>import("./EodashMap-BVEvKne5.js").then(t=>t.E),__vite__mapDeps([9,1,3])),"/widgets/EodashMapBtns.vue":()=>Xe(()=>import("./EodashMapBtns-jNIMsmmc.js"),__vite__mapDeps([10,11,12,4,5,6,7,13,14,15,16,17,18,19,20])),"/widgets/ExportState.vue":()=>Xe(()=>import("./ExportState-CN3SVEwD.js"),__vite__mapDeps([11,12,4,5,6,7,13,14,15,16,17,18,19])),"/widgets/PopUp.vue":()=>Xe(()=>import("./PopUp-BLlcRLMy.js"),__vite__mapDeps([12,4,5,6,7,13])),"/widgets/WidgetsContainer.vue":()=>Xe(()=>import("./WidgetsContainer-nwexi3P3.js"),[])}),...Object.assign({"../../../src/widgets/List.vue":()=>Xe(()=>import("./List-DXPnbxiN.js"),__vite__mapDeps([21,15,16,6,17,18,14,22,23]))})};for(const t in e){const n=t.split("/").at(-1).slice(0,-4);Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(e,t)),delete e[t]}return e})(),pF=e=>{const t=[];for(const n of e??[]){const r=Ut({component:null,props:{},title:"",id:Symbol(),layout:{x:0,y:0,h:0,w:0}});if("defineWidget"in(n??{})){const{selectedStac:s}=Pw(ri());Te(s,o=>{let a=n?.defineWidget(o);a&&(a=je(a)),r.value=r.value.id===a?.id?r.value:Qd(a)},{immediate:!0})}else r.value=Qd(n);t.push(r)}return t},Qd=e=>{const t={component:null,props:{},title:"",id:Symbol(),layout:je({x:0,y:0,h:0,w:0})};switch(e?.type){case"internal":t.component=or({loader:mF[e?.widget.name],suspensible:!0}),t.props=je(e?.widget.properties??{});break;case"web-component":t.component=or({loader:()=>Xe(()=>import("./DynamicWebComponent-wMhw2Yko.js"),[]),suspensible:!0}),t.props=je(e.widget);break;case"iframe":t.component=or({loader:()=>Xe(()=>import("./IframeWrapper-DckIy2sZ.js"),[]),suspensible:!0}),t.props=je(e.widget);break;default:if(e)console.error("Widget type not found");else return t;break}return t.title=e?.title??"",t.id=e?.id??t.id,"layout"in e&&(t.layout.x=e.layout.x,t.layout.y=e.layout.y,t.layout.h=e.layout.h,t.layout.w=e.layout.w),t},gF=(e,t)=>{const n=e.__vccOpts||e;for(const[r,s]of t)n[r]=s;return n},yF=s1("v-alert-title"),og=$e({border:[Boolean,Number,String]},"border");function ag(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:Kn();return{borderClasses:w(()=>{const r=Se(e)?e.value:e.border,s=[];if(r===!0||r==="")s.push(`${t}--border`);else if(typeof r=="string"||r===0)for(const o of String(r).split(" "))s.push(`border-${o}`);return s})}}const bF=[null,"default","comfortable","compact"],ju=$e({density:{type:String,default:"default",validator:e=>bF.includes(e)}},"density");function Vu(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:Kn();return{densityClasses:w(()=>`${t}--density-${e.density}`)}}const Wu=$e({elevation:{type:[Number,String],validator(e){const t=parseInt(e);return!isNaN(t)&&t>=0&&t<=24}}},"elevation");function Uu(e){return{elevationClasses:w(()=>{const n=Se(e)?e.value:e.elevation,r=[];return n==null||r.push(`elevation-${n}`),r})}}const si=$e({rounded:{type:[Boolean,Number,String],default:void 0},tile:Boolean},"rounded");function oi(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:Kn();return{roundedClasses:w(()=>{const r=Se(e)?e.value:e.rounded,s=Se(e)?e.value:e.tile,o=[];if(r===!0||r==="")o.push(`${t}--rounded`);else if(typeof r=="string"||r===0)for(const a of String(r).split(" "))o.push(`rounded-${a}`);else(s||r===!1)&&o.push("rounded-0");return o})}}const Zn=$e({tag:{type:String,default:"div"}},"tag");function zu(e){return xv(()=>{const t=[],n={};if(e.value.background)if(nl(e.value.background)){if(n.backgroundColor=e.value.background,!e.value.text&&z0(e.value.background)){const r=nn(e.value.background);if(r.a==null||r.a===1){const s=Rv(r);n.color=s,n.caretColor=s}}}else t.push(`bg-${e.value.background}`);return e.value.text&&(nl(e.value.text)?(n.color=e.value.text,n.caretColor=e.value.text):t.push(`text-${e.value.text}`)),{colorClasses:t,colorStyles:n}})}function Qs(e,t){const n=w(()=>({text:Se(e)?e.value:t?e[t]:null})),{colorClasses:r,colorStyles:s}=zu(n);return{textColorClasses:r,textColorStyles:s}}function Li(e,t){const n=w(()=>({background:Se(e)?e.value:t?e[t]:null})),{colorClasses:r,colorStyles:s}=zu(n);return{backgroundColorClasses:r,backgroundColorStyles:s}}const wF=["elevated","flat","tonal","outlined","text","plain"];function ig(e,t){return L(be,null,[e&&L("span",{key:"overlay",class:`${t}__overlay`},null),L("span",{key:"underlay",class:`${t}__underlay`},null)])}const Ku=$e({color:String,variant:{type:String,default:"elevated",validator:e=>wF.includes(e)}},"variant");function lg(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:Kn();const n=w(()=>{const{variant:o}=A(e);return`${t}--variant-${o}`}),{colorClasses:r,colorStyles:s}=zu(w(()=>{const{variant:o,color:a}=A(e);return{[["elevated","flat"].includes(o)?"background":"text"]:a}}));return{colorClasses:r,colorStyles:s,variantClasses:n}}const ug=$e({baseColor:String,divided:Boolean,...og(),...ln(),...ju(),...Wu(),...si(),...Zn(),...wr(),...Ku()},"VBtnGroup"),eh=At()({name:"VBtnGroup",props:ug(),setup(e,t){let{slots:n}=t;const{themeClasses:r}=_r(e),{densityClasses:s}=Vu(e),{borderClasses:o}=ag(e),{elevationClasses:a}=Uu(e),{roundedClasses:i}=oi(e);Fv({VBtn:{height:"auto",baseColor:et(e,"baseColor"),color:et(e,"color"),density:et(e,"density"),flat:!0,variant:et(e,"variant")}}),br(()=>L(e.tag,{class:["v-btn-group",{"v-btn-group--divided":e.divided},r.value,o.value,s.value,a.value,i.value,e.class],style:e.style},n))}}),_F=$e({modelValue:{type:null,default:void 0},multiple:Boolean,mandatory:[Boolean,String],max:Number,selectedClass:String,disabled:Boolean},"group"),DF=$e({value:null,disabled:Boolean,selectedClass:String},"group-item");function CF(e,t){let n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!0;const r=St("useGroupItem");if(!r)throw new Error("[Vuetify] useGroupItem composable must be used inside a component setup function");const s=Ra();Pt(Symbol.for(`${t.description}:id`),s);const o=Pe(t,null);if(!o){if(!n)return o;throw new Error(`[Vuetify] Could not find useGroup injection with symbol ${t.description}`)}const a=et(e,"value"),i=w(()=>!!(o.disabled.value||e.disabled));o.register({id:s,value:a,disabled:i},r),yr(()=>{o.unregister(s)});const l=w(()=>o.isSelected(s)),u=w(()=>o.items.value[0].id===s),c=w(()=>o.items.value[o.items.value.length-1].id===s),f=w(()=>l.value&&[o.selectedClass.value,e.selectedClass]);return Te(l,d=>{r.emit("group:selected",{value:d})},{flush:"sync"}),{id:s,isSelected:l,isFirst:u,isLast:c,toggle:()=>o.select(s,!l.value),select:d=>o.select(s,d),selectedClass:f,value:a,disabled:i,group:o}}function SF(e,t){let n=!1;const r=je([]),s=Na(e,"modelValue",[],d=>d==null?[]:cg(r,$0(d)),d=>{const h=TF(r,d);return e.multiple?h:h[0]}),o=St("useGroup");function a(d,h){const v=d,m=Symbol.for(`${t.description}:id`),b=kr(m,o?.vnode).indexOf(h);A(v.value)==null&&(v.value=b,v.useIndexAsValue=!0),b>-1?r.splice(b,0,v):r.push(v)}function i(d){if(n)return;l();const h=r.findIndex(v=>v.id===d);r.splice(h,1)}function l(){const d=r.find(h=>!h.disabled);d&&e.mandatory==="force"&&!s.value.length&&(s.value=[d.id])}Gt(()=>{l()}),yr(()=>{n=!0}),Gl(()=>{for(let d=0;dm.id===d);if(!(h&&v?.disabled))if(e.multiple){const m=s.value.slice(),p=m.findIndex(S=>S===d),b=~p;if(h=h??!b,b&&e.mandatory&&m.length<=1||!b&&e.max!=null&&m.length+1>e.max)return;p<0&&h?m.push(d):p>=0&&!h&&m.splice(p,1),s.value=m}else{const m=s.value.includes(d);if(e.mandatory&&m)return;s.value=h??!m?[d]:[]}}function c(d){if(e.multiple,s.value.length){const h=s.value[0],v=r.findIndex(b=>b.id===h);let m=(v+d)%r.length,p=r[m];for(;p.disabled&&m!==v;)m=(m+d)%r.length,p=r[m];if(p.disabled)return;s.value=[r[m].id]}else{const h=r.find(v=>!v.disabled);h&&(s.value=[h.id])}}const f={register:a,unregister:i,selected:s,select:u,disabled:et(e,"disabled"),prev:()=>c(r.length-1),next:()=>c(1),isSelected:d=>s.value.includes(d),selectedClass:w(()=>e.selectedClass),items:w(()=>r),getItemIndex:d=>$F(r,d)};return Pt(t,f),f}function $F(e,t){const n=cg(e,[t]);return n.length?e.findIndex(r=>r.id===n[0]):-1}function cg(e,t){const n=[];return t.forEach(r=>{const s=e.find(a=>nu(r,a.value)),o=e[r];s?.value!=null?n.push(s.id):o!=null&&n.push(o.id)}),n}function TF(e,t){const n=[];return t.forEach(r=>{const s=e.findIndex(o=>o.id===r);if(~s){const o=e[s];n.push(o.value!=null?o.value:s)}}),n}const fg=Symbol.for("vuetify:v-btn-toggle"),EF=$e({...ug(),..._F()},"VBtnToggle");At()({name:"VBtnToggle",props:EF(),emits:{"update:modelValue":e=>!0},setup(e,t){let{slots:n}=t;const{isSelected:r,next:s,prev:o,select:a,selected:i}=SF(e,fg);return br(()=>{const l=eh.filterProps(e);return L(eh,qt({class:["v-btn-toggle",e.class]},l,{style:e.style}),{default:()=>[n.default?.({isSelected:r,next:s,prev:o,select:a,selected:i})]})}),{next:s,prev:o,select:a}}});const OF=$e({defaults:Object,disabled:Boolean,reset:[Number,String],root:[Boolean,String],scoped:Boolean},"VDefaultsProvider"),Fs=At(!1)({name:"VDefaultsProvider",props:OF(),setup(e,t){let{slots:n}=t;const{defaults:r,disabled:s,reset:o,root:a,scoped:i}=no(e);return Fv(r,{reset:o,root:a,scoped:i,disabled:s}),()=>n.default?.()}}),MF=["x-small","small","default","large","x-large"],Gu=$e({size:{type:[String,Number],default:"default"}},"size");function qu(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:Kn();return xv(()=>{let n,r;return ra(MF,e.size)?n=`${t}--size-${e.size}`:e.size&&(r={width:Fe(e.size),height:Fe(e.size)}),{sizeClasses:n,sizeStyles:r}})}const xF=$e({color:String,disabled:Boolean,start:Boolean,end:Boolean,icon:zs,...ln(),...Gu(),...Zn({tag:"i"}),...wr()},"VIcon"),Ko=At()({name:"VIcon",props:xF(),setup(e,t){let{attrs:n,slots:r}=t;const s=oe(),{themeClasses:o}=_r(e),{iconData:a}=uw(w(()=>s.value||e.icon)),{sizeClasses:i}=qu(e),{textColorClasses:l,textColorStyles:u}=Qs(et(e,"color"));return br(()=>{const c=r.default?.();c&&(s.value=Mv(c).filter(d=>d.type===ao&&d.children&&typeof d.children=="string")[0]?.children);const f=!!(n.onClick||n.onClickOnce);return L(a.value.component,{tag:e.tag,icon:a.value.icon,class:["v-icon","notranslate",o.value,i.value,l.value,{"v-icon--clickable":f,"v-icon--disabled":e.disabled,"v-icon--start":e.start,"v-icon--end":e.end},e.class],style:[i.value?void 0:{fontSize:Fe(e.size),height:Fe(e.size),width:Fe(e.size)},u.value,e.style],role:f?"button":void 0,"aria-hidden":!f,tabindex:f?e.disabled?-1:0:void 0},{default:()=>[c]})}),{}}});function dg(e,t){const n=oe(),r=Ut(!1);if(_0){const s=new IntersectionObserver(o=>{r.value=!!o.find(a=>a.isIntersecting)},t);yr(()=>{s.disconnect()}),Te(n,(o,a)=>{a&&(s.unobserve(a),r.value=!1),o&&s.observe(o)},{flush:"post"})}return{intersectionRef:n,isIntersecting:r}}const kF=$e({bgColor:String,color:String,indeterminate:[Boolean,String],modelValue:{type:[Number,String],default:0},rotate:{type:[Number,String],default:0},width:{type:[Number,String],default:4},...ln(),...Gu(),...Zn({tag:"div"}),...wr()},"VProgressCircular"),PF=At()({name:"VProgressCircular",props:kF(),setup(e,t){let{slots:n}=t;const r=20,s=2*Math.PI*r,o=oe(),{themeClasses:a}=_r(e),{sizeClasses:i,sizeStyles:l}=qu(e),{textColorClasses:u,textColorStyles:c}=Qs(et(e,"color")),{textColorClasses:f,textColorStyles:d}=Qs(et(e,"bgColor")),{intersectionRef:h,isIntersecting:v}=dg(),{resizeRef:m,contentRect:p}=qv(),b=w(()=>Math.max(0,Math.min(100,parseFloat(e.modelValue)))),S=w(()=>Number(e.width)),T=w(()=>l.value?Number(e.size):p.value?p.value.width:Math.max(S.value,32)),M=w(()=>r/(1-S.value/T.value)*2),D=w(()=>S.value/T.value*M.value),C=w(()=>Fe((100-b.value)/100*s));return zn(()=>{h.value=o.value,m.value=o.value}),br(()=>L(e.tag,{ref:o,class:["v-progress-circular",{"v-progress-circular--indeterminate":!!e.indeterminate,"v-progress-circular--visible":v.value,"v-progress-circular--disable-shrink":e.indeterminate==="disable-shrink"},a.value,i.value,u.value,e.class],style:[l.value,c.value,e.style],role:"progressbar","aria-valuemin":"0","aria-valuemax":"100","aria-valuenow":e.indeterminate?void 0:b.value},{default:()=>[L("svg",{style:{transform:`rotate(calc(-90deg + ${Number(e.rotate)}deg))`},xmlns:"http://www.w3.org/2000/svg",viewBox:`0 0 ${M.value} ${M.value}`},[L("circle",{class:["v-progress-circular__underlay",f.value],style:d.value,fill:"transparent",cx:"50%",cy:"50%",r,"stroke-width":D.value,"stroke-dasharray":s,"stroke-dashoffset":0},null),L("circle",{class:"v-progress-circular__overlay",fill:"transparent",cx:"50%",cy:"50%",r,"stroke-width":D.value,"stroke-dasharray":s,"stroke-dashoffset":C.value},null)]),n.default&&L("div",{class:"v-progress-circular__content"},[n.default({value:b.value})])]})),{}}}),hg=$e({height:[Number,String],maxHeight:[Number,String],maxWidth:[Number,String],minHeight:[Number,String],minWidth:[Number,String],width:[Number,String]},"dimension");function vg(e){return{dimensionStyles:w(()=>{const n={},r=Fe(e.height),s=Fe(e.maxHeight),o=Fe(e.maxWidth),a=Fe(e.minHeight),i=Fe(e.minWidth),l=Fe(e.width);return r!=null&&(n.height=r),s!=null&&(n.maxHeight=s),o!=null&&(n.maxWidth=o),a!=null&&(n.minHeight=a),i!=null&&(n.minWidth=i),l!=null&&(n.width=l),n})}}const th={center:"center",top:"bottom",bottom:"top",left:"right",right:"left"},Zu=$e({location:String},"location");function Ju(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1,n=arguments.length>2?arguments[2]:void 0;const{isRtl:r}=Fa();return{locationStyles:w(()=>{if(!e.location)return{};const{side:o,align:a}=P0(e.location.split(" ").length>1?e.location:`${e.location} center`,r.value);function i(u){return n?n(u):0}const l={};return o!=="center"&&(t?l[th[o]]=`calc(100% - ${i(o)}px)`:l[o]=0),a!=="center"?t?l[th[a]]=`calc(100% - ${i(a)}px)`:l[a]=0:(o==="center"?l.top=l.left="50%":l[{top:"left",bottom:"left",left:"top",right:"top"}[o]]="50%",l.transform={top:"translateX(-50%)",bottom:"translateX(-50%)",left:"translateY(-50%)",right:"translateY(-50%)",center:"translate(-50%, -50%)"}[o]),l})}}const AF=$e({absolute:Boolean,active:{type:Boolean,default:!0},bgColor:String,bgOpacity:[Number,String],bufferValue:{type:[Number,String],default:0},bufferColor:String,bufferOpacity:[Number,String],clickable:Boolean,color:String,height:{type:[Number,String],default:4},indeterminate:Boolean,max:{type:[Number,String],default:100},modelValue:{type:[Number,String],default:0},opacity:[Number,String],reverse:Boolean,stream:Boolean,striped:Boolean,roundedBar:Boolean,...ln(),...Zu({location:"top"}),...si(),...Zn(),...wr()},"VProgressLinear"),IF=At()({name:"VProgressLinear",props:AF(),emits:{"update:modelValue":e=>!0},setup(e,t){let{slots:n}=t;const r=Na(e,"modelValue"),{isRtl:s,rtlClasses:o}=Fa(),{themeClasses:a}=_r(e),{locationStyles:i}=Ju(e),{textColorClasses:l,textColorStyles:u}=Qs(e,"color"),{backgroundColorClasses:c,backgroundColorStyles:f}=Li(w(()=>e.bgColor||e.color)),{backgroundColorClasses:d,backgroundColorStyles:h}=Li(w(()=>e.bufferColor||e.bgColor||e.color)),{backgroundColorClasses:v,backgroundColorStyles:m}=Li(e,"color"),{roundedClasses:p}=oi(e),{intersectionRef:b,isIntersecting:S}=dg(),T=w(()=>parseFloat(e.max)),M=w(()=>parseFloat(e.height)),D=w(()=>na(parseFloat(e.bufferValue)/T.value*100,0,100)),C=w(()=>na(parseFloat(r.value)/T.value*100,0,100)),E=w(()=>s.value!==e.reverse),P=w(()=>e.indeterminate?"fade-transition":"slide-x-transition"),$=ot&&window.matchMedia?.("(forced-colors: active)").matches;function I(j){if(!b.value)return;const{left:O,right:W,width:re}=b.value.getBoundingClientRect(),X=E.value?re-j.clientX+(W-re):j.clientX-O;r.value=Math.round(X/re*T.value)}return br(()=>L(e.tag,{ref:b,class:["v-progress-linear",{"v-progress-linear--absolute":e.absolute,"v-progress-linear--active":e.active&&S.value,"v-progress-linear--reverse":E.value,"v-progress-linear--rounded":e.rounded,"v-progress-linear--rounded-bar":e.roundedBar,"v-progress-linear--striped":e.striped},p.value,a.value,o.value,e.class],style:[{bottom:e.location==="bottom"?0:void 0,top:e.location==="top"?0:void 0,height:e.active?Fe(M.value):0,"--v-progress-linear-height":Fe(M.value),...e.absolute?i.value:{}},e.style],role:"progressbar","aria-hidden":e.active?"false":"true","aria-valuemin":"0","aria-valuemax":e.max,"aria-valuenow":e.indeterminate?void 0:C.value,onClick:e.clickable&&I},{default:()=>[e.stream&&L("div",{key:"stream",class:["v-progress-linear__stream",l.value],style:{...u.value,[E.value?"left":"right"]:Fe(-M.value),borderTop:`${Fe(M.value/2)} dotted`,opacity:parseFloat(e.bufferOpacity),top:`calc(50% - ${Fe(M.value/4)})`,width:Fe(100-D.value,"%"),"--v-progress-linear-stream-to":Fe(M.value*(E.value?1:-1))}},null),L("div",{class:["v-progress-linear__background",$?void 0:c.value],style:[f.value,{opacity:parseFloat(e.bgOpacity),width:e.stream?0:void 0}]},null),L("div",{class:["v-progress-linear__buffer",$?void 0:d.value],style:[h.value,{opacity:parseFloat(e.bufferOpacity),width:Fe(D.value,"%")}]},null),L(uo,{name:P.value},{default:()=>[e.indeterminate?L("div",{class:"v-progress-linear__indeterminate"},[["long","short"].map(j=>L("div",{key:j,class:["v-progress-linear__indeterminate",j,$?void 0:v.value],style:m.value},null))]):L("div",{class:["v-progress-linear__determinate",$?void 0:v.value],style:[m.value,{width:Fe(C.value,"%")}]},null)]}),n.default&&L("div",{class:"v-progress-linear__content"},[n.default({value:C.value,buffer:D.value})])]})),{}}}),LF=$e({loading:[Boolean,String]},"loader");function RF(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:Kn();return{loaderClasses:w(()=>({[`${t}--loading`]:e.loading}))}}function QY(e,t){let{slots:n}=t;return L("div",{class:`${e.name}__loader`},[n.default?.({color:e.color,isActive:e.active})||L(IF,{absolute:e.absolute,active:e.active,color:e.color,height:"2",indeterminate:!0},null)])}const NF=["static","relative","fixed","absolute","sticky"],mg=$e({position:{type:String,validator:e=>NF.includes(e)}},"position");function pg(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:Kn();return{positionClasses:w(()=>e.position?`${t}--${e.position}`:void 0)}}function FF(){const e=St("useRoute");return w(()=>e?.proxy?.$route)}function e3(){return St("useRouter")?.proxy?.$router}function YF(e,t){const n=Pa("RouterLink"),r=w(()=>!!(e.href||e.to)),s=w(()=>r?.value||jc(t,"click")||jc(e,"click"));if(typeof n=="string"||!("useLink"in n))return{isLink:r,isClickable:s,href:et(e,"href")};const o=w(()=>({...e,to:et(()=>e.to||"")})),a=n.useLink(o.value),i=w(()=>e.to?a:void 0),l=FF();return{isLink:r,isClickable:s,route:i.value?.route,navigate:i.value?.navigate,isActive:w(()=>i.value?e.exact?l.value?i.value.isExactActive?.value&&nu(i.value.route.value.query,l.value.query):i.value.isExactActive?.value??!1:i.value.isActive?.value??!1:!1),href:w(()=>e.to?i.value?.route.value.href:e.href)}}const BF=$e({href:String,replace:Boolean,to:[String,Object],exact:Boolean},"router");let Ri=!1;function t3(e,t){let n=!1,r,s;ot&&(Ot(()=>{window.addEventListener("popstate",o),r=e?.beforeEach((a,i,l)=>{Ri?n?t(l):l():setTimeout(()=>n?t(l):l()),Ri=!0}),s=e?.afterEach(()=>{Ri=!1})}),Ll(()=>{window.removeEventListener("popstate",o),r?.(),s?.()}));function o(a){a.state?.replaced||(n=!0,setTimeout(()=>n=!1))}}function HF(e,t){Te(()=>e.isActive?.value,n=>{e.isLink.value&&n&&t&&Ot(()=>{t(!0)})},{immediate:!0})}const El=Symbol("rippleStop"),jF=80;function nh(e,t){e.style.transform=t,e.style.webkitTransform=t}function Ol(e){return e.constructor.name==="TouchEvent"}function gg(e){return e.constructor.name==="KeyboardEvent"}const VF=function(e,t){let n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},r=0,s=0;if(!gg(e)){const f=t.getBoundingClientRect(),d=Ol(e)?e.touches[e.touches.length-1]:e;r=d.clientX-f.left,s=d.clientY-f.top}let o=0,a=.3;t._ripple?.circle?(a=.15,o=t.clientWidth/2,o=n.center?o:o+Math.sqrt((r-o)**2+(s-o)**2)/4):o=Math.sqrt(t.clientWidth**2+t.clientHeight**2)/2;const i=`${(t.clientWidth-o*2)/2}px`,l=`${(t.clientHeight-o*2)/2}px`,u=n.center?i:`${r-o}px`,c=n.center?l:`${s-o}px`;return{radius:o,scale:a,x:u,y:c,centerX:i,centerY:l}},Da={show(e,t){let n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};if(!t?._ripple?.enabled)return;const r=document.createElement("span"),s=document.createElement("span");r.appendChild(s),r.className="v-ripple__container",n.class&&(r.className+=` ${n.class}`);const{radius:o,scale:a,x:i,y:l,centerX:u,centerY:c}=VF(e,t,n),f=`${o*2}px`;s.className="v-ripple__animation",s.style.width=f,s.style.height=f,t.appendChild(r);const d=window.getComputedStyle(t);d&&d.position==="static"&&(t.style.position="relative",t.dataset.previousPosition="static"),s.classList.add("v-ripple__animation--enter"),s.classList.add("v-ripple__animation--visible"),nh(s,`translate(${i}, ${l}) scale3d(${a},${a},${a})`),s.dataset.activated=String(performance.now()),setTimeout(()=>{s.classList.remove("v-ripple__animation--enter"),s.classList.add("v-ripple__animation--in"),nh(s,`translate(${u}, ${c}) scale3d(1,1,1)`)},0)},hide(e){if(!e?._ripple?.enabled)return;const t=e.getElementsByClassName("v-ripple__animation");if(t.length===0)return;const n=t[t.length-1];if(n.dataset.isHiding)return;n.dataset.isHiding="true";const r=performance.now()-Number(n.dataset.activated),s=Math.max(250-r,0);setTimeout(()=>{n.classList.remove("v-ripple__animation--in"),n.classList.add("v-ripple__animation--out"),setTimeout(()=>{e.getElementsByClassName("v-ripple__animation").length===1&&e.dataset.previousPosition&&(e.style.position=e.dataset.previousPosition,delete e.dataset.previousPosition),n.parentNode?.parentNode===e&&e.removeChild(n.parentNode)},300)},s)}};function yg(e){return typeof e>"u"||!!e}function eo(e){const t={},n=e.currentTarget;if(!(!n?._ripple||n._ripple.touched||e[El])){if(e[El]=!0,Ol(e))n._ripple.touched=!0,n._ripple.isTouch=!0;else if(n._ripple.isTouch)return;if(t.center=n._ripple.centered||gg(e),n._ripple.class&&(t.class=n._ripple.class),Ol(e)){if(n._ripple.showTimerCommit)return;n._ripple.showTimerCommit=()=>{Da.show(e,n,t)},n._ripple.showTimer=window.setTimeout(()=>{n?._ripple?.showTimerCommit&&(n._ripple.showTimerCommit(),n._ripple.showTimerCommit=null)},jF)}else Da.show(e,n,t)}}function rh(e){e[El]=!0}function Et(e){const t=e.currentTarget;if(t?._ripple){if(window.clearTimeout(t._ripple.showTimer),e.type==="touchend"&&t._ripple.showTimerCommit){t._ripple.showTimerCommit(),t._ripple.showTimerCommit=null,t._ripple.showTimer=window.setTimeout(()=>{Et(e)});return}window.setTimeout(()=>{t._ripple&&(t._ripple.touched=!1)}),Da.hide(t)}}function bg(e){const t=e.currentTarget;t?._ripple&&(t._ripple.showTimerCommit&&(t._ripple.showTimerCommit=null),window.clearTimeout(t._ripple.showTimer))}let to=!1;function wg(e){!to&&(e.keyCode===Yc.enter||e.keyCode===Yc.space)&&(to=!0,eo(e))}function _g(e){to=!1,Et(e)}function Dg(e){to&&(to=!1,Et(e))}function Cg(e,t,n){const{value:r,modifiers:s}=t,o=yg(r);if(o||Da.hide(e),e._ripple=e._ripple??{},e._ripple.enabled=o,e._ripple.centered=s.center,e._ripple.circle=s.circle,tl(r)&&r.class&&(e._ripple.class=r.class),o&&!n){if(s.stop){e.addEventListener("touchstart",rh,{passive:!0}),e.addEventListener("mousedown",rh);return}e.addEventListener("touchstart",eo,{passive:!0}),e.addEventListener("touchend",Et,{passive:!0}),e.addEventListener("touchmove",bg,{passive:!0}),e.addEventListener("touchcancel",Et),e.addEventListener("mousedown",eo),e.addEventListener("mouseup",Et),e.addEventListener("mouseleave",Et),e.addEventListener("keydown",wg),e.addEventListener("keyup",_g),e.addEventListener("blur",Dg),e.addEventListener("dragstart",Et,{passive:!0})}else!o&&n&&Sg(e)}function Sg(e){e.removeEventListener("mousedown",eo),e.removeEventListener("touchstart",eo),e.removeEventListener("touchend",Et),e.removeEventListener("touchmove",bg),e.removeEventListener("touchcancel",Et),e.removeEventListener("mouseup",Et),e.removeEventListener("mouseleave",Et),e.removeEventListener("keydown",wg),e.removeEventListener("keyup",_g),e.removeEventListener("dragstart",Et),e.removeEventListener("blur",Dg)}function WF(e,t){Cg(e,t,!1)}function UF(e){delete e._ripple,Sg(e)}function zF(e,t){if(t.value===t.oldValue)return;const n=yg(t.oldValue);Cg(e,t,n)}const KF={mounted:WF,unmounted:UF,updated:zF},GF=$e({active:{type:Boolean,default:void 0},baseColor:String,symbol:{type:null,default:fg},flat:Boolean,icon:[Boolean,String,Function,Object],prependIcon:zs,appendIcon:zs,block:Boolean,readonly:Boolean,slim:Boolean,stacked:Boolean,ripple:{type:[Boolean,Object],default:!0},text:String,...og(),...ln(),...ju(),...hg(),...Wu(),...DF(),...LF(),...Zu(),...mg(),...si(),...BF(),...Gu(),...Zn({tag:"button"}),...wr(),...Ku({variant:"elevated"})},"VBtn"),qF=At()({name:"VBtn",props:GF(),emits:{"group:selected":e=>!0},setup(e,t){let{attrs:n,slots:r}=t;const{themeClasses:s}=_r(e),{borderClasses:o}=ag(e),{densityClasses:a}=Vu(e),{dimensionStyles:i}=vg(e),{elevationClasses:l}=Uu(e),{loaderClasses:u}=RF(e),{locationStyles:c}=Ju(e),{positionClasses:f}=pg(e),{roundedClasses:d}=oi(e),{sizeClasses:h,sizeStyles:v}=qu(e),m=CF(e,e.symbol,!1),p=YF(e,n),b=w(()=>e.active!==void 0?e.active:p.isLink.value?p.isActive?.value:m?.isSelected.value),S=w(()=>({color:m?.isSelected.value&&(!p.isLink.value||p.isActive?.value)||!m||p.isActive?.value?e.color??e.baseColor:e.baseColor,variant:e.variant})),{colorClasses:T,colorStyles:M,variantClasses:D}=lg(S),C=w(()=>m?.disabled.value||e.disabled),E=w(()=>e.variant==="elevated"&&!(e.disabled||e.flat||e.border)),P=w(()=>{if(!(e.value===void 0||typeof e.value=="symbol"))return Object(e.value)===e.value?JSON.stringify(e.value,null,0):e.value});function $(I){C.value||p.isLink.value&&(I.metaKey||I.ctrlKey||I.shiftKey||I.button!==0||n.target==="_blank")||(p.navigate?.(I),m?.toggle())}return HF(p,m?.select),br(()=>{const I=p.isLink.value?"a":e.tag,j=!!(e.prependIcon||r.prepend),O=!!(e.appendIcon||r.append),W=!!(e.icon&&e.icon!==!0);return zl(L(I,{type:I==="a"?void 0:"button",class:["v-btn",m?.selectedClass.value,{"v-btn--active":b.value,"v-btn--block":e.block,"v-btn--disabled":C.value,"v-btn--elevated":E.value,"v-btn--flat":e.flat,"v-btn--icon":!!e.icon,"v-btn--loading":e.loading,"v-btn--readonly":e.readonly,"v-btn--slim":e.slim,"v-btn--stacked":e.stacked},s.value,o.value,T.value,a.value,l.value,u.value,f.value,d.value,h.value,D.value,e.class],style:[M.value,i.value,c.value,v.value,e.style],"aria-busy":e.loading?!0:void 0,disabled:C.value||void 0,href:p.href.value,tabindex:e.loading||e.readonly?-1:void 0,onClick:$,value:P.value},{default:()=>[ig(!0,"v-btn"),!e.icon&&j&&L("span",{key:"prepend",class:"v-btn__prepend"},[r.prepend?L(Fs,{key:"prepend-defaults",disabled:!e.prependIcon,defaults:{VIcon:{icon:e.prependIcon}}},r.prepend):L(Ko,{key:"prepend-icon",icon:e.prependIcon},null)]),L("span",{class:"v-btn__content","data-no-activator":""},[!r.default&&W?L(Ko,{key:"content-icon",icon:e.icon},null):L(Fs,{key:"content-defaults",disabled:!W,defaults:{VIcon:{icon:e.icon}}},{default:()=>[r.default?.()??e.text]})]),!e.icon&&O&&L("span",{key:"append",class:"v-btn__append"},[r.append?L(Fs,{key:"append-defaults",disabled:!e.appendIcon,defaults:{VIcon:{icon:e.appendIcon}}},r.append):L(Ko,{key:"append-icon",icon:e.appendIcon},null)]),!!e.loading&&L("span",{key:"loader",class:"v-btn__loader"},[r.loader?.()??L(PF,{color:typeof e.loading=="boolean"?void 0:e.loading,indeterminate:!0,width:"2"},null)])]}),[[KF,!C.value&&e.ripple,"",{center:!!e.icon}]])}),{group:m}}}),ZF=["success","info","warning","error"],JF=$e({border:{type:[Boolean,String],validator:e=>typeof e=="boolean"||["top","end","bottom","start"].includes(e)},borderColor:String,closable:Boolean,closeIcon:{type:zs,default:"$close"},closeLabel:{type:String,default:"$vuetify.close"},icon:{type:[Boolean,String,Function,Object],default:null},modelValue:{type:Boolean,default:!0},prominent:Boolean,title:String,text:String,type:{type:String,validator:e=>ZF.includes(e)},...ln(),...ju(),...hg(),...Wu(),...Zu(),...mg(),...si(),...Zn(),...wr(),...Ku({variant:"flat"})},"VAlert"),XF=At()({name:"VAlert",props:JF(),emits:{"click:close":e=>!0,"update:modelValue":e=>!0},setup(e,t){let{emit:n,slots:r}=t;const s=Na(e,"modelValue"),o=w(()=>{if(e.icon!==!1)return e.type?e.icon??`$${e.type}`:e.icon}),a=w(()=>({color:e.color??e.type,variant:e.variant})),{themeClasses:i}=_r(e),{colorClasses:l,colorStyles:u,variantClasses:c}=lg(a),{densityClasses:f}=Vu(e),{dimensionStyles:d}=vg(e),{elevationClasses:h}=Uu(e),{locationStyles:v}=Ju(e),{positionClasses:m}=pg(e),{roundedClasses:p}=oi(e),{textColorClasses:b,textColorStyles:S}=Qs(et(e,"borderColor")),{t:T}=u1(),M=w(()=>({"aria-label":T(e.closeLabel),onClick(D){s.value=!1,n("click:close",D)}}));return()=>{const D=!!(r.prepend||o.value),C=!!(r.title||e.title),E=!!(r.close||e.closable);return s.value&&L(e.tag,{class:["v-alert",e.border&&{"v-alert--border":!!e.border,[`v-alert--border-${e.border===!0?"start":e.border}`]:!0},{"v-alert--prominent":e.prominent},i.value,l.value,f.value,h.value,m.value,p.value,c.value,e.class],style:[u.value,d.value,v.value,e.style],role:"alert"},{default:()=>[ig(!1,"v-alert"),e.border&&L("div",{key:"border",class:["v-alert__border",b.value],style:S.value},null),D&&L("div",{key:"prepend",class:"v-alert__prepend"},[r.prepend?L(Fs,{key:"prepend-defaults",disabled:!o.value,defaults:{VIcon:{density:e.density,icon:o.value,size:e.prominent?44:28}}},r.prepend):L(Ko,{key:"prepend-icon",density:e.density,icon:o.value,size:e.prominent?44:28},null)]),L("div",{class:"v-alert__content"},[C&&L(yF,{key:"title"},{default:()=>[r.title?.()??e.title]}),r.text?.()??e.text,r.default?.()]),r.append&&L("div",{key:"append",class:"v-alert__append"},[r.append()]),E&&L("div",{key:"close",class:"v-alert__close"},[r.close?L(Fs,{key:"close-defaults",defaults:{VBtn:{icon:e.closeIcon,size:"x-small",variant:"text"}}},{default:()=>[r.close?.({props:M.value})]}):L(qF,qt({key:"close-btn",icon:e.closeIcon,size:"x-small",variant:"text"},M.value),null)])]})}}}),QF=e=>(Oy("data-v-ac10aa7f"),e=e(),My(),e),eY={is:"animated-details"},tY=QF(()=>me("summary",null,"Error",-1)),nY={__name:"ErrorAlert",props:{modelValue:{type:String,required:!0},modelModifiers:{}},emits:["update:modelValue"],setup(e){const t=vb(e,"modelValue"),r=Pe(mo).brand.errorMessage??"something went wrong, please try again later";return(s,o)=>t.value?(G(),Ae(XF,{key:0,translate:"yes",location:"start bottom",type:"error",position:"fixed","onClick:close":o[0]||(o[0]=a=>t.value=""),variant:"elevated",icon:[A(yw)],class:"alert",closable:"","close-icon":[A(_w)]},{default:Ee(()=>[Kr(Qe(A(r))+" ",1),me("details",eY,[tY,Kr(" "+Qe(t.value),1)])]),_:1},8,["icon","close-icon"])):We("v-if",!0)}},Xu=gF(nY,[["__scopeId","data-v-ac10aa7f"]]),$g=Ba.reduce((e,t)=>(e[t]={type:[Boolean,String,Number],default:!1},e),{}),Tg=Ba.reduce((e,t)=>{const n="offset"+Dn(t);return e[n]={type:[String,Number],default:null},e},{}),Eg=Ba.reduce((e,t)=>{const n="order"+Dn(t);return e[n]={type:[String,Number],default:null},e},{}),sh={col:Object.keys($g),offset:Object.keys(Tg),order:Object.keys(Eg)};function rY(e,t,n){let r=e;if(!(n==null||n===!1)){if(t){const s=t.replace(e,"");r+=`-${s}`}return e==="col"&&(r="v-"+r),e==="col"&&(n===""||n===!0)||(r+=`-${n}`),r.toLowerCase()}}const sY=["auto","start","end","center","baseline","stretch"],oY=$e({cols:{type:[Boolean,String,Number],default:!1},...$g,offset:{type:[String,Number],default:null},...Tg,order:{type:[String,Number],default:null},...Eg,alignSelf:{type:String,default:null,validator:e=>sY.includes(e)},...ln(),...Zn()},"VCol"),aY=At()({name:"VCol",props:oY(),setup(e,t){let{slots:n}=t;const r=w(()=>{const s=[];let o;for(o in sh)sh[o].forEach(i=>{const l=e[i],u=rY(o,i,l);u&&s.push(u)});const a=s.some(i=>i.startsWith("v-col-"));return s.push({"v-col":!a||!e.cols,[`v-col-${e.cols}`]:e.cols,[`offset-${e.offset}`]:e.offset,[`order-${e.order}`]:e.order,[`align-self-${e.alignSelf}`]:e.alignSelf}),s});return()=>lo(e.tag,{class:[r.value,e.class],style:e.style},n.default?.())}}),Qu=["start","end","center"],Og=["space-between","space-around","space-evenly"];function ec(e,t){return Ba.reduce((n,r)=>{const s=e+Dn(r);return n[s]=t(),n},{})}const iY=[...Qu,"baseline","stretch"],Mg=e=>iY.includes(e),xg=ec("align",()=>({type:String,default:null,validator:Mg})),lY=[...Qu,...Og],kg=e=>lY.includes(e),Pg=ec("justify",()=>({type:String,default:null,validator:kg})),uY=[...Qu,...Og,"stretch"],Ag=e=>uY.includes(e),Ig=ec("alignContent",()=>({type:String,default:null,validator:Ag})),oh={align:Object.keys(xg),justify:Object.keys(Pg),alignContent:Object.keys(Ig)},cY={align:"align",justify:"justify",alignContent:"align-content"};function fY(e,t,n){let r=cY[e];if(n!=null){if(t){const s=t.replace(e,"");r+=`-${s}`}return r+=`-${n}`,r.toLowerCase()}}const dY=$e({dense:Boolean,noGutters:Boolean,align:{type:String,default:null,validator:Mg},...xg,justify:{type:String,default:null,validator:kg},...Pg,alignContent:{type:String,default:null,validator:Ag},...Ig,...ln(),...Zn()},"VRow"),hY=At()({name:"VRow",props:dY(),setup(e,t){let{slots:n}=t;const r=w(()=>{const s=[];let o;for(o in oh)oh[o].forEach(a=>{const i=e[a],l=fY(o,a,i);l&&s.push(l)});return s.push({"v-row--no-gutters":e.noGutters,"v-row--dense":e.dense,[`align-${e.align}`]:e.align,[`justify-${e.justify}`]:e.justify,[`align-content-${e.alignContent}`]:e.alignContent}),s});return()=>lo(e.tag,{class:["v-row",r.value,e.class],style:e.style},n.default?.())}}),vY={key:1,class:"text-center"},mY=me("div",{class:"text-center"},"Loading...",-1),pY={__name:"Loading",setup(e){const t=Pe(mo),[n]=pF([t.template.loading]),r=oe("");return ka((s,o,a)=>{r.value=` +`):" "+Zd(o[0]):"as no adapter specified";throw new ve("There is no suitable adapter to dispatch the request "+a,"ERR_NOT_SUPPORT")}return r},adapters:Cl};function Ii(e){if(e.cancelToken&&e.cancelToken.throwIfRequested(),e.signal&&e.signal.aborted)throw new ms(null,e)}function Jd(e){return Ii(e),e.headers=Dt.from(e.headers),e.data=Ai.call(e,e.transformRequest),["post","put","patch"].indexOf(e.method)!==-1&&e.headers.setContentType("application/x-www-form-urlencoded",!1),eg.getAdapter(e.adapter||go.adapter)(e).then(function(r){return Ii(e),r.data=Ai.call(e,e.transformResponse,r),r.headers=Dt.from(r.headers),r},function(r){return Gp(r)||(Ii(e),r&&r.response&&(r.response.data=Ai.call(e,e.transformResponse,r.response),r.response.headers=Dt.from(r.response.headers))),Promise.reject(r)})}const tg="1.7.3",Yu={};["object","boolean","number","function","string","symbol"].forEach((e,t)=>{Yu[e]=function(r){return typeof r===e||"a"+(t<1?"n ":" ")+e}});const Xd={};Yu.transitional=function(t,n,r){function s(o,a){return"[Axios v"+tg+"] Transitional option '"+o+"'"+a+(r?". "+r:"")}return(o,a,i)=>{if(t===!1)throw new ve(s(a," has been removed"+(n?" in "+n:"")),ve.ERR_DEPRECATED);return n&&!Xd[a]&&(Xd[a]=!0,console.warn(s(a," has been deprecated since v"+n+" and will be removed in the near future"))),t?t(o,a,i):!0}};function QN(e,t,n){if(typeof e!="object")throw new ve("options must be an object",ve.ERR_BAD_OPTION_VALUE);const r=Object.keys(e);let s=r.length;for(;s-- >0;){const o=r[s],a=t[o];if(a){const i=e[o],l=i===void 0||a(i,o,e);if(l!==!0)throw new ve("option "+o+" must be "+l,ve.ERR_BAD_OPTION_VALUE);continue}if(n!==!0)throw new ve("Unknown option "+o,ve.ERR_BAD_OPTION)}}const Sl={assertOptions:QN,validators:Yu},Mn=Sl.validators;class dr{constructor(t){this.defaults=t,this.interceptors={request:new Vd,response:new Vd}}async request(t,n){try{return await this._request(t,n)}catch(r){if(r instanceof Error){let s;Error.captureStackTrace?Error.captureStackTrace(s={}):s=new Error;const o=s.stack?s.stack.replace(/^.+\n/,""):"";try{r.stack?o&&!String(r.stack).endsWith(o.replace(/^.+\n.+\n/,""))&&(r.stack+=` +`+o):r.stack=o}catch{}}throw r}}_request(t,n){typeof t=="string"?(n=n||{},n.url=t):n=t||{},n=gr(this.defaults,n);const{transitional:r,paramsSerializer:s,headers:o}=n;r!==void 0&&Sl.assertOptions(r,{silentJSONParsing:Mn.transitional(Mn.boolean),forcedJSONParsing:Mn.transitional(Mn.boolean),clarifyTimeoutError:Mn.transitional(Mn.boolean)},!1),s!=null&&(x.isFunction(s)?n.paramsSerializer={serialize:s}:Sl.assertOptions(s,{encode:Mn.function,serialize:Mn.function},!0)),n.method=(n.method||this.defaults.method||"get").toLowerCase();let a=o&&x.merge(o.common,o[n.method]);o&&x.forEach(["delete","get","head","post","put","patch","common"],v=>{delete o[v]}),n.headers=Dt.concat(a,o);const i=[];let l=!0;this.interceptors.request.forEach(function(m){typeof m.runWhen=="function"&&m.runWhen(n)===!1||(l=l&&m.synchronous,i.unshift(m.fulfilled,m.rejected))});const u=[];this.interceptors.response.forEach(function(m){u.push(m.fulfilled,m.rejected)});let c,f=0,d;if(!l){const v=[Jd.bind(this),void 0];for(v.unshift.apply(v,i),v.push.apply(v,u),d=v.length,c=Promise.resolve(n);f{if(!r._listeners)return;let o=r._listeners.length;for(;o-- >0;)r._listeners[o](s);r._listeners=null}),this.promise.then=s=>{let o;const a=new Promise(i=>{r.subscribe(i),o=i}).then(s);return a.cancel=function(){r.unsubscribe(o)},a},t(function(o,a,i){r.reason||(r.reason=new ms(o,a,i),n(r.reason))})}throwIfRequested(){if(this.reason)throw this.reason}subscribe(t){if(this.reason){t(this.reason);return}this._listeners?this._listeners.push(t):this._listeners=[t]}unsubscribe(t){if(!this._listeners)return;const n=this._listeners.indexOf(t);n!==-1&&this._listeners.splice(n,1)}static source(){let t;return{token:new Bu(function(s){t=s}),cancel:t}}}function eF(e){return function(n){return e.apply(null,n)}}function tF(e){return x.isObject(e)&&e.isAxiosError===!0}const $l={Continue:100,SwitchingProtocols:101,Processing:102,EarlyHints:103,Ok:200,Created:201,Accepted:202,NonAuthoritativeInformation:203,NoContent:204,ResetContent:205,PartialContent:206,MultiStatus:207,AlreadyReported:208,ImUsed:226,MultipleChoices:300,MovedPermanently:301,Found:302,SeeOther:303,NotModified:304,UseProxy:305,Unused:306,TemporaryRedirect:307,PermanentRedirect:308,BadRequest:400,Unauthorized:401,PaymentRequired:402,Forbidden:403,NotFound:404,MethodNotAllowed:405,NotAcceptable:406,ProxyAuthenticationRequired:407,RequestTimeout:408,Conflict:409,Gone:410,LengthRequired:411,PreconditionFailed:412,PayloadTooLarge:413,UriTooLong:414,UnsupportedMediaType:415,RangeNotSatisfiable:416,ExpectationFailed:417,ImATeapot:418,MisdirectedRequest:421,UnprocessableEntity:422,Locked:423,FailedDependency:424,TooEarly:425,UpgradeRequired:426,PreconditionRequired:428,TooManyRequests:429,RequestHeaderFieldsTooLarge:431,UnavailableForLegalReasons:451,InternalServerError:500,NotImplemented:501,BadGateway:502,ServiceUnavailable:503,GatewayTimeout:504,HttpVersionNotSupported:505,VariantAlsoNegotiates:506,InsufficientStorage:507,LoopDetected:508,NotExtended:510,NetworkAuthenticationRequired:511};Object.entries($l).forEach(([e,t])=>{$l[t]=e});function ng(e){const t=new dr(e),n=Ap(dr.prototype.request,t);return x.extend(n,dr.prototype,t,{allOwnKeys:!0}),x.extend(n,t,null,{allOwnKeys:!0}),n.create=function(s){return ng(gr(e,s))},n}const Ue=ng(go);Ue.Axios=dr;Ue.CanceledError=ms;Ue.CancelToken=Bu;Ue.isCancel=Gp;Ue.VERSION=tg;Ue.toFormData=ti;Ue.AxiosError=ve;Ue.Cancel=Ue.CanceledError;Ue.all=function(t){return Promise.all(t)};Ue.spread=eF;Ue.isAxiosError=tF;Ue.mergeConfig=gr;Ue.AxiosHeaders=Dt;Ue.formToJSON=e=>Kp(x.isHTMLForm(e)?new FormData(e):e);Ue.getAdapter=eg.getAdapter;Ue.HttpStatusCode=$l;Ue.default=Ue;const nF=(e="",t=au.stacEndpoint)=>{if(!e||e.includes("http"))return Pr.value=t,Pr;const n=t.split("/"),r=e.split("/");n.pop();for(let s=0;s{if(!e||e.includes("http"))return Ts.value=t,Ts;const n=t.split("/"),r=e.split("/");n.pop();for(let s=0;s{const n=uw();return Object.keys(t).forEach(r=>{r==="dark"?n.themes.value[e][r]=t[r]:n.themes.value[e][r]={...n.themes.value[e][r],...t[r]}}),n},oF=()=>{Gt(async()=>{if(window.location.search){const e=new URLSearchParams(window.location.search);let t,n,r;e.forEach(async(s,o)=>{switch(o){case"indicator":{const{loadSelectedSTAC:a,stac:i}=ri(),l=i?.find(u=>u.id==s);l&&await a(l.href);break}case"x":t=Number(s);break;case"y":n=Number(s);break;case"z":r=Number(s);break;case"datetime":try{Yo.value=new Date(s).toISOString()}catch{Yo.value=new Date().toISOString()}break}}),t&&n&&r&&(il.value=[t,n,r])}Te([ou,il,Yo],([e,t,n])=>{if("URLSearchParams"in window){const r=new URLSearchParams(window.location.search);e!==""&&r.set("indicator",e),t&&t.length===3&&(r.set("x",t[0]?.toFixed(4)??""),r.set("y",t[1]?.toFixed(4)??""),r.set("z",t[2]?.toFixed(4)??"")),n&&r.set("datetime",n.split("T")?.[0]??"");const s=window.location.pathname+"?"+r.toString();history.pushState(null,"",s)}})})},UY=e=>{Gt(()=>{const t=e.value?.parentElement;t?.tagName==="EOX-LAYOUT-ITEM"&&(t.classList.remove("bg-surface"),t.style.background="transparent",t.style.border="transparent")})},ri=Ow("stac",()=>{const e=oe(null),t=oe(null),n=oe(null),r=Pe(mo);async function s(i=r.stacEndpoint){await Ue.get(i).then(l=>{const u=l.data.links.map(c=>(c.title||(c.title=`${c.rel} ${c.href}`),c));e.value=u}).catch(l=>{throw new Error("error loading assigned STAC endpoint",l)})}async function o(i=""){const l=nF(i);await Ue.get(l.value).then(u=>{t.value=u.data,ou.value=t.value?.id??""}).catch(u=>{throw new Error("error loading the selected STAC",u)})}async function a(i=""){const l=rF(i);await Ue.get(l.value).then(u=>{n.value=u.data}).catch(u=>{throw new Error("error loading the selected comparison STAC",u)})}return{stac:e,loadSTAC:s,loadSelectedSTAC:o,loadSelectedCompareSTAC:a,selectedStac:t,selectedCompareStac:n}}),aF=Object.freeze(Object.defineProperty({__proto__:null,useSTAcStore:ri},Symbol.toStringTag,{value:"Module"})),iF=Object.assign({"./Actions.js":OR,"./States.js":Aw,"./stac.js":aF}),rg=(()=>{const e={};for(const[t,n]of Object.entries(iF)){const r=t.split("/").at(-1)?.slice(0,-3).toLowerCase()??"";["keys"].includes(r)||(e[r]=n)}return e})(),lF=Dw();function uF(e){window.eodashStore=rg,e.use(ww).use(lF).use($R,{}).provide(mo,au)}const cF=async e=>{const t=Pe(mo),n=r=>{Object.keys(t).forEach(s=>{t[s]=r[s]})};if(e)return n((await import(new URL(e,import.meta.url).href)).default),t;try{const r="/config.js";n((await import(new URL(r,import.meta.url).href)).default)}catch{try{n(await Qe(()=>import("./main-ddE0Djvd.js"),[]).then(async r=>await r.default))}catch{console.error("no dashboard configuration defined")}}return t},zY=async e=>e instanceof Function?await e(rg):e,fF=async(e="",t="",n=!1)=>(e&&t&&(await Qe(async()=>{const{default:s}=await import("./webfontloader-OEBPRw3i.js").then(o=>o.w);return{default:s}},__vite__mapDeps([0,1]))).default.load({classes:!1,custom:{families:[e],urls:[t]},fontactive(s,o){const a=new CSSStyleSheet,i=n?`eo-dash {font-family: ${s};}`:`* {font-family: ${s};}`;a.replaceSync(i),document.adoptedStyleSheets.push(a)},fontinactive(s,o){throw new Error(`error loading font: ${s}`)}}),e),KY=async(e,t)=>{await navigator.clipboard.writeText(e),t.value=!0,setTimeout(()=>{t.value=!1},2e3)},dF=(()=>{const e={...Object.assign({"/widgets/EodashDatePicker.vue":()=>Qe(()=>import("./EodashDatePicker-g0QWHEy-.js"),__vite__mapDeps([2,3,1,4,5,6,7,8])),"/widgets/EodashItemFilter.vue":()=>Qe(()=>import("./EodashItemFilter-BTypMvp7.js"),[]),"/widgets/EodashLayerControl.vue":()=>Qe(()=>import("./EodashLayerControl-C8O3wm-N.js"),[]),"/widgets/EodashMap.vue":()=>Qe(()=>import("./EodashMap-BDE_gmHB.js").then(t=>t.E),__vite__mapDeps([9,1,3])),"/widgets/EodashMapBtns.vue":()=>Qe(()=>import("./EodashMapBtns-BBddO65x.js"),__vite__mapDeps([10,11,12,4,5,6,7,13,14,15,16,17,18])),"/widgets/ExportState.vue":()=>Qe(()=>import("./ExportState-D-Xz2LGJ.js"),__vite__mapDeps([11,12,4,5,6,7,13,14,15,16,17])),"/widgets/PopUp.vue":()=>Qe(()=>import("./PopUp-5-tUIM9N.js"),__vite__mapDeps([12,4,5,6,7,13])),"/widgets/WidgetsContainer.vue":()=>Qe(()=>import("./WidgetsContainer-CFwZEFgj.js"),[])}),...Object.assign({})};for(const t in e){const n=t.split("/").at(-1).slice(0,-4);Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(e,t)),delete e[t]}return e})(),hF=e=>{const t=[];for(const n of e??[]){const r=Ut({component:null,props:{},title:"",id:Symbol(),layout:{x:0,y:0,h:0,w:0}});if("defineWidget"in(n??{})){const{selectedStac:s}=Mw(ri());Te(s,o=>{let a=n?.defineWidget(o);a&&(a=je(a)),r.value=r.value.id===a?.id?r.value:Qd(a)},{immediate:!0})}else r.value=Qd(n);t.push(r)}return t},Qd=e=>{const t={component:null,props:{},title:"",id:Symbol(),layout:je({x:0,y:0,h:0,w:0})};switch(e?.type){case"internal":t.component=or({loader:dF[e?.widget.name],suspensible:!0}),t.props=je(e?.widget.properties??{});break;case"web-component":t.component=or({loader:()=>Qe(()=>import("./DynamicWebComponent-DPZoYKb-.js"),[]),suspensible:!0}),t.props=je(e.widget);break;case"iframe":t.component=or({loader:()=>Qe(()=>import("./IframeWrapper-CJivyMgq.js"),[]),suspensible:!0}),t.props=je(e.widget);break;default:if(e)console.error("Widget type not found");else return t;break}return t.title=e?.title??"",t.id=e?.id??t.id,"layout"in e&&(t.layout.x=e.layout.x,t.layout.y=e.layout.y,t.layout.h=e.layout.h,t.layout.w=e.layout.w),t},vF=(e,t)=>{const n=e.__vccOpts||e;for(const[r,s]of t)n[r]=s;return n},mF=t1("v-alert-title"),sg=$e({border:[Boolean,Number,String]},"border");function og(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:Kn();return{borderClasses:w(()=>{const r=Se(e)?e.value:e.border,s=[];if(r===!0||r==="")s.push(`${t}--border`);else if(typeof r=="string"||r===0)for(const o of String(r).split(" "))s.push(`border-${o}`);return s})}}const pF=[null,"default","comfortable","compact"],Hu=$e({density:{type:String,default:"default",validator:e=>pF.includes(e)}},"density");function ju(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:Kn();return{densityClasses:w(()=>`${t}--density-${e.density}`)}}const Vu=$e({elevation:{type:[Number,String],validator(e){const t=parseInt(e);return!isNaN(t)&&t>=0&&t<=24}}},"elevation");function Wu(e){return{elevationClasses:w(()=>{const n=Se(e)?e.value:e.elevation,r=[];return n==null||r.push(`elevation-${n}`),r})}}const si=$e({rounded:{type:[Boolean,Number,String],default:void 0},tile:Boolean},"rounded");function oi(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:Kn();return{roundedClasses:w(()=>{const r=Se(e)?e.value:e.rounded,s=Se(e)?e.value:e.tile,o=[];if(r===!0||r==="")o.push(`${t}--rounded`);else if(typeof r=="string"||r===0)for(const a of String(r).split(" "))o.push(`rounded-${a}`);else(s||r===!1)&&o.push("rounded-0");return o})}}const Zn=$e({tag:{type:String,default:"div"}},"tag");function Uu(e){return Mv(()=>{const t=[],n={};if(e.value.background)if(tl(e.value.background)){if(n.backgroundColor=e.value.background,!e.value.text&&V0(e.value.background)){const r=nn(e.value.background);if(r.a==null||r.a===1){const s=Lv(r);n.color=s,n.caretColor=s}}}else t.push(`bg-${e.value.background}`);return e.value.text&&(tl(e.value.text)?(n.color=e.value.text,n.caretColor=e.value.text):t.push(`text-${e.value.text}`)),{colorClasses:t,colorStyles:n}})}function Qs(e,t){const n=w(()=>({text:Se(e)?e.value:t?e[t]:null})),{colorClasses:r,colorStyles:s}=Uu(n);return{textColorClasses:r,textColorStyles:s}}function Li(e,t){const n=w(()=>({background:Se(e)?e.value:t?e[t]:null})),{colorClasses:r,colorStyles:s}=Uu(n);return{backgroundColorClasses:r,backgroundColorStyles:s}}const gF=["elevated","flat","tonal","outlined","text","plain"];function ag(e,t){return L(be,null,[e&&L("span",{key:"overlay",class:`${t}__overlay`},null),L("span",{key:"underlay",class:`${t}__underlay`},null)])}const zu=$e({color:String,variant:{type:String,default:"elevated",validator:e=>gF.includes(e)}},"variant");function ig(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:Kn();const n=w(()=>{const{variant:o}=A(e);return`${t}--variant-${o}`}),{colorClasses:r,colorStyles:s}=Uu(w(()=>{const{variant:o,color:a}=A(e);return{[["elevated","flat"].includes(o)?"background":"text"]:a}}));return{colorClasses:r,colorStyles:s,variantClasses:n}}const lg=$e({baseColor:String,divided:Boolean,...sg(),...ln(),...Hu(),...Vu(),...si(),...Zn(),...wr(),...zu()},"VBtnGroup"),eh=At()({name:"VBtnGroup",props:lg(),setup(e,t){let{slots:n}=t;const{themeClasses:r}=_r(e),{densityClasses:s}=ju(e),{borderClasses:o}=og(e),{elevationClasses:a}=Wu(e),{roundedClasses:i}=oi(e);Nv({VBtn:{height:"auto",baseColor:et(e,"baseColor"),color:et(e,"color"),density:et(e,"density"),flat:!0,variant:et(e,"variant")}}),br(()=>L(e.tag,{class:["v-btn-group",{"v-btn-group--divided":e.divided},r.value,o.value,s.value,a.value,i.value,e.class],style:e.style},n))}}),yF=$e({modelValue:{type:null,default:void 0},multiple:Boolean,mandatory:[Boolean,String],max:Number,selectedClass:String,disabled:Boolean},"group"),bF=$e({value:null,disabled:Boolean,selectedClass:String},"group-item");function wF(e,t){let n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!0;const r=St("useGroupItem");if(!r)throw new Error("[Vuetify] useGroupItem composable must be used inside a component setup function");const s=Ra();Pt(Symbol.for(`${t.description}:id`),s);const o=Pe(t,null);if(!o){if(!n)return o;throw new Error(`[Vuetify] Could not find useGroup injection with symbol ${t.description}`)}const a=et(e,"value"),i=w(()=>!!(o.disabled.value||e.disabled));o.register({id:s,value:a,disabled:i},r),yr(()=>{o.unregister(s)});const l=w(()=>o.isSelected(s)),u=w(()=>o.items.value[0].id===s),c=w(()=>o.items.value[o.items.value.length-1].id===s),f=w(()=>l.value&&[o.selectedClass.value,e.selectedClass]);return Te(l,d=>{r.emit("group:selected",{value:d})},{flush:"sync"}),{id:s,isSelected:l,isFirst:u,isLast:c,toggle:()=>o.select(s,!l.value),select:d=>o.select(s,d),selectedClass:f,value:a,disabled:i,group:o}}function _F(e,t){let n=!1;const r=je([]),s=Na(e,"modelValue",[],d=>d==null?[]:ug(r,$0(d)),d=>{const h=CF(r,d);return e.multiple?h:h[0]}),o=St("useGroup");function a(d,h){const v=d,m=Symbol.for(`${t.description}:id`),b=xr(m,o?.vnode).indexOf(h);A(v.value)==null&&(v.value=b,v.useIndexAsValue=!0),b>-1?r.splice(b,0,v):r.push(v)}function i(d){if(n)return;l();const h=r.findIndex(v=>v.id===d);r.splice(h,1)}function l(){const d=r.find(h=>!h.disabled);d&&e.mandatory==="force"&&!s.value.length&&(s.value=[d.id])}Gt(()=>{l()}),yr(()=>{n=!0}),Kl(()=>{for(let d=0;dm.id===d);if(!(h&&v?.disabled))if(e.multiple){const m=s.value.slice(),p=m.findIndex(S=>S===d),b=~p;if(h=h??!b,b&&e.mandatory&&m.length<=1||!b&&e.max!=null&&m.length+1>e.max)return;p<0&&h?m.push(d):p>=0&&!h&&m.splice(p,1),s.value=m}else{const m=s.value.includes(d);if(e.mandatory&&m)return;s.value=h??!m?[d]:[]}}function c(d){if(e.multiple,s.value.length){const h=s.value[0],v=r.findIndex(b=>b.id===h);let m=(v+d)%r.length,p=r[m];for(;p.disabled&&m!==v;)m=(m+d)%r.length,p=r[m];if(p.disabled)return;s.value=[r[m].id]}else{const h=r.find(v=>!v.disabled);h&&(s.value=[h.id])}}const f={register:a,unregister:i,selected:s,select:u,disabled:et(e,"disabled"),prev:()=>c(r.length-1),next:()=>c(1),isSelected:d=>s.value.includes(d),selectedClass:w(()=>e.selectedClass),items:w(()=>r),getItemIndex:d=>DF(r,d)};return Pt(t,f),f}function DF(e,t){const n=ug(e,[t]);return n.length?e.findIndex(r=>r.id===n[0]):-1}function ug(e,t){const n=[];return t.forEach(r=>{const s=e.find(a=>tu(r,a.value)),o=e[r];s?.value!=null?n.push(s.id):o!=null&&n.push(o.id)}),n}function CF(e,t){const n=[];return t.forEach(r=>{const s=e.findIndex(o=>o.id===r);if(~s){const o=e[s];n.push(o.value!=null?o.value:s)}}),n}const cg=Symbol.for("vuetify:v-btn-toggle"),SF=$e({...lg(),...yF()},"VBtnToggle");At()({name:"VBtnToggle",props:SF(),emits:{"update:modelValue":e=>!0},setup(e,t){let{slots:n}=t;const{isSelected:r,next:s,prev:o,select:a,selected:i}=_F(e,cg);return br(()=>{const l=eh.filterProps(e);return L(eh,qt({class:["v-btn-toggle",e.class]},l,{style:e.style}),{default:()=>[n.default?.({isSelected:r,next:s,prev:o,select:a,selected:i})]})}),{next:s,prev:o,select:a}}});const $F=$e({defaults:Object,disabled:Boolean,reset:[Number,String],root:[Boolean,String],scoped:Boolean},"VDefaultsProvider"),Fs=At(!1)({name:"VDefaultsProvider",props:$F(),setup(e,t){let{slots:n}=t;const{defaults:r,disabled:s,reset:o,root:a,scoped:i}=no(e);return Nv(r,{reset:o,root:a,scoped:i,disabled:s}),()=>n.default?.()}}),TF=["x-small","small","default","large","x-large"],Ku=$e({size:{type:[String,Number],default:"default"}},"size");function Gu(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:Kn();return Mv(()=>{let n,r;return ra(TF,e.size)?n=`${t}--size-${e.size}`:e.size&&(r={width:Fe(e.size),height:Fe(e.size)}),{sizeClasses:n,sizeStyles:r}})}const EF=$e({color:String,disabled:Boolean,start:Boolean,end:Boolean,icon:zs,...ln(),...Ku(),...Zn({tag:"i"}),...wr()},"VIcon"),Ko=At()({name:"VIcon",props:EF(),setup(e,t){let{attrs:n,slots:r}=t;const s=oe(),{themeClasses:o}=_r(e),{iconData:a}=aw(w(()=>s.value||e.icon)),{sizeClasses:i}=Gu(e),{textColorClasses:l,textColorStyles:u}=Qs(et(e,"color"));return br(()=>{const c=r.default?.();c&&(s.value=Ov(c).filter(d=>d.type===ao&&d.children&&typeof d.children=="string")[0]?.children);const f=!!(n.onClick||n.onClickOnce);return L(a.value.component,{tag:e.tag,icon:a.value.icon,class:["v-icon","notranslate",o.value,i.value,l.value,{"v-icon--clickable":f,"v-icon--disabled":e.disabled,"v-icon--start":e.start,"v-icon--end":e.end},e.class],style:[i.value?void 0:{fontSize:Fe(e.size),height:Fe(e.size),width:Fe(e.size)},u.value,e.style],role:f?"button":void 0,"aria-hidden":!f,tabindex:f?e.disabled?-1:0:void 0},{default:()=>[c]})}),{}}});function fg(e,t){const n=oe(),r=Ut(!1);if(w0){const s=new IntersectionObserver(o=>{r.value=!!o.find(a=>a.isIntersecting)},t);yr(()=>{s.disconnect()}),Te(n,(o,a)=>{a&&(s.unobserve(a),r.value=!1),o&&s.observe(o)},{flush:"post"})}return{intersectionRef:n,isIntersecting:r}}const OF=$e({bgColor:String,color:String,indeterminate:[Boolean,String],modelValue:{type:[Number,String],default:0},rotate:{type:[Number,String],default:0},width:{type:[Number,String],default:4},...ln(),...Ku(),...Zn({tag:"div"}),...wr()},"VProgressCircular"),MF=At()({name:"VProgressCircular",props:OF(),setup(e,t){let{slots:n}=t;const r=20,s=2*Math.PI*r,o=oe(),{themeClasses:a}=_r(e),{sizeClasses:i,sizeStyles:l}=Gu(e),{textColorClasses:u,textColorStyles:c}=Qs(et(e,"color")),{textColorClasses:f,textColorStyles:d}=Qs(et(e,"bgColor")),{intersectionRef:h,isIntersecting:v}=fg(),{resizeRef:m,contentRect:p}=Gv(),b=w(()=>Math.max(0,Math.min(100,parseFloat(e.modelValue)))),S=w(()=>Number(e.width)),T=w(()=>l.value?Number(e.size):p.value?p.value.width:Math.max(S.value,32)),M=w(()=>r/(1-S.value/T.value)*2),D=w(()=>S.value/T.value*M.value),C=w(()=>Fe((100-b.value)/100*s));return zn(()=>{h.value=o.value,m.value=o.value}),br(()=>L(e.tag,{ref:o,class:["v-progress-circular",{"v-progress-circular--indeterminate":!!e.indeterminate,"v-progress-circular--visible":v.value,"v-progress-circular--disable-shrink":e.indeterminate==="disable-shrink"},a.value,i.value,u.value,e.class],style:[l.value,c.value,e.style],role:"progressbar","aria-valuemin":"0","aria-valuemax":"100","aria-valuenow":e.indeterminate?void 0:b.value},{default:()=>[L("svg",{style:{transform:`rotate(calc(-90deg + ${Number(e.rotate)}deg))`},xmlns:"http://www.w3.org/2000/svg",viewBox:`0 0 ${M.value} ${M.value}`},[L("circle",{class:["v-progress-circular__underlay",f.value],style:d.value,fill:"transparent",cx:"50%",cy:"50%",r,"stroke-width":D.value,"stroke-dasharray":s,"stroke-dashoffset":0},null),L("circle",{class:"v-progress-circular__overlay",fill:"transparent",cx:"50%",cy:"50%",r,"stroke-width":D.value,"stroke-dasharray":s,"stroke-dashoffset":C.value},null)]),n.default&&L("div",{class:"v-progress-circular__content"},[n.default({value:b.value})])]})),{}}}),dg=$e({height:[Number,String],maxHeight:[Number,String],maxWidth:[Number,String],minHeight:[Number,String],minWidth:[Number,String],width:[Number,String]},"dimension");function hg(e){return{dimensionStyles:w(()=>{const n={},r=Fe(e.height),s=Fe(e.maxHeight),o=Fe(e.maxWidth),a=Fe(e.minHeight),i=Fe(e.minWidth),l=Fe(e.width);return r!=null&&(n.height=r),s!=null&&(n.maxHeight=s),o!=null&&(n.maxWidth=o),a!=null&&(n.minHeight=a),i!=null&&(n.minWidth=i),l!=null&&(n.width=l),n})}}const th={center:"center",top:"bottom",bottom:"top",left:"right",right:"left"},qu=$e({location:String},"location");function Zu(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1,n=arguments.length>2?arguments[2]:void 0;const{isRtl:r}=Fa();return{locationStyles:w(()=>{if(!e.location)return{};const{side:o,align:a}=M0(e.location.split(" ").length>1?e.location:`${e.location} center`,r.value);function i(u){return n?n(u):0}const l={};return o!=="center"&&(t?l[th[o]]=`calc(100% - ${i(o)}px)`:l[o]=0),a!=="center"?t?l[th[a]]=`calc(100% - ${i(a)}px)`:l[a]=0:(o==="center"?l.top=l.left="50%":l[{top:"left",bottom:"left",left:"top",right:"top"}[o]]="50%",l.transform={top:"translateX(-50%)",bottom:"translateX(-50%)",left:"translateY(-50%)",right:"translateY(-50%)",center:"translate(-50%, -50%)"}[o]),l})}}const kF=$e({absolute:Boolean,active:{type:Boolean,default:!0},bgColor:String,bgOpacity:[Number,String],bufferValue:{type:[Number,String],default:0},bufferColor:String,bufferOpacity:[Number,String],clickable:Boolean,color:String,height:{type:[Number,String],default:4},indeterminate:Boolean,max:{type:[Number,String],default:100},modelValue:{type:[Number,String],default:0},opacity:[Number,String],reverse:Boolean,stream:Boolean,striped:Boolean,roundedBar:Boolean,...ln(),...qu({location:"top"}),...si(),...Zn(),...wr()},"VProgressLinear"),xF=At()({name:"VProgressLinear",props:kF(),emits:{"update:modelValue":e=>!0},setup(e,t){let{slots:n}=t;const r=Na(e,"modelValue"),{isRtl:s,rtlClasses:o}=Fa(),{themeClasses:a}=_r(e),{locationStyles:i}=Zu(e),{textColorClasses:l,textColorStyles:u}=Qs(e,"color"),{backgroundColorClasses:c,backgroundColorStyles:f}=Li(w(()=>e.bgColor||e.color)),{backgroundColorClasses:d,backgroundColorStyles:h}=Li(w(()=>e.bufferColor||e.bgColor||e.color)),{backgroundColorClasses:v,backgroundColorStyles:m}=Li(e,"color"),{roundedClasses:p}=oi(e),{intersectionRef:b,isIntersecting:S}=fg(),T=w(()=>parseFloat(e.max)),M=w(()=>parseFloat(e.height)),D=w(()=>na(parseFloat(e.bufferValue)/T.value*100,0,100)),C=w(()=>na(parseFloat(r.value)/T.value*100,0,100)),E=w(()=>s.value!==e.reverse),P=w(()=>e.indeterminate?"fade-transition":"slide-x-transition"),$=ot&&window.matchMedia?.("(forced-colors: active)").matches;function I(j){if(!b.value)return;const{left:O,right:W,width:re}=b.value.getBoundingClientRect(),X=E.value?re-j.clientX+(W-re):j.clientX-O;r.value=Math.round(X/re*T.value)}return br(()=>L(e.tag,{ref:b,class:["v-progress-linear",{"v-progress-linear--absolute":e.absolute,"v-progress-linear--active":e.active&&S.value,"v-progress-linear--reverse":E.value,"v-progress-linear--rounded":e.rounded,"v-progress-linear--rounded-bar":e.roundedBar,"v-progress-linear--striped":e.striped},p.value,a.value,o.value,e.class],style:[{bottom:e.location==="bottom"?0:void 0,top:e.location==="top"?0:void 0,height:e.active?Fe(M.value):0,"--v-progress-linear-height":Fe(M.value),...e.absolute?i.value:{}},e.style],role:"progressbar","aria-hidden":e.active?"false":"true","aria-valuemin":"0","aria-valuemax":e.max,"aria-valuenow":e.indeterminate?void 0:C.value,onClick:e.clickable&&I},{default:()=>[e.stream&&L("div",{key:"stream",class:["v-progress-linear__stream",l.value],style:{...u.value,[E.value?"left":"right"]:Fe(-M.value),borderTop:`${Fe(M.value/2)} dotted`,opacity:parseFloat(e.bufferOpacity),top:`calc(50% - ${Fe(M.value/4)})`,width:Fe(100-D.value,"%"),"--v-progress-linear-stream-to":Fe(M.value*(E.value?1:-1))}},null),L("div",{class:["v-progress-linear__background",$?void 0:c.value],style:[f.value,{opacity:parseFloat(e.bgOpacity),width:e.stream?0:void 0}]},null),L("div",{class:["v-progress-linear__buffer",$?void 0:d.value],style:[h.value,{opacity:parseFloat(e.bufferOpacity),width:Fe(D.value,"%")}]},null),L(uo,{name:P.value},{default:()=>[e.indeterminate?L("div",{class:"v-progress-linear__indeterminate"},[["long","short"].map(j=>L("div",{key:j,class:["v-progress-linear__indeterminate",j,$?void 0:v.value],style:m.value},null))]):L("div",{class:["v-progress-linear__determinate",$?void 0:v.value],style:[m.value,{width:Fe(C.value,"%")}]},null)]}),n.default&&L("div",{class:"v-progress-linear__content"},[n.default({value:C.value,buffer:D.value})])]})),{}}}),PF=$e({loading:[Boolean,String]},"loader");function AF(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:Kn();return{loaderClasses:w(()=>({[`${t}--loading`]:e.loading}))}}function GY(e,t){let{slots:n}=t;return L("div",{class:`${e.name}__loader`},[n.default?.({color:e.color,isActive:e.active})||L(xF,{absolute:e.absolute,active:e.active,color:e.color,height:"2",indeterminate:!0},null)])}const IF=["static","relative","fixed","absolute","sticky"],vg=$e({position:{type:String,validator:e=>IF.includes(e)}},"position");function mg(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:Kn();return{positionClasses:w(()=>e.position?`${t}--${e.position}`:void 0)}}function LF(){const e=St("useRoute");return w(()=>e?.proxy?.$route)}function qY(){return St("useRouter")?.proxy?.$router}function RF(e,t){const n=Pa("RouterLink"),r=w(()=>!!(e.href||e.to)),s=w(()=>r?.value||jc(t,"click")||jc(e,"click"));if(typeof n=="string"||!("useLink"in n))return{isLink:r,isClickable:s,href:et(e,"href")};const o=w(()=>({...e,to:et(()=>e.to||"")})),a=n.useLink(o.value),i=w(()=>e.to?a:void 0),l=LF();return{isLink:r,isClickable:s,route:i.value?.route,navigate:i.value?.navigate,isActive:w(()=>i.value?e.exact?l.value?i.value.isExactActive?.value&&tu(i.value.route.value.query,l.value.query):i.value.isExactActive?.value??!1:i.value.isActive?.value??!1:!1),href:w(()=>e.to?i.value?.route.value.href:e.href)}}const NF=$e({href:String,replace:Boolean,to:[String,Object],exact:Boolean},"router");let Ri=!1;function ZY(e,t){let n=!1,r,s;ot&&(Ot(()=>{window.addEventListener("popstate",o),r=e?.beforeEach((a,i,l)=>{Ri?n?t(l):l():setTimeout(()=>n?t(l):l()),Ri=!0}),s=e?.afterEach(()=>{Ri=!1})}),Il(()=>{window.removeEventListener("popstate",o),r?.(),s?.()}));function o(a){a.state?.replaced||(n=!0,setTimeout(()=>n=!1))}}function FF(e,t){Te(()=>e.isActive?.value,n=>{e.isLink.value&&n&&t&&Ot(()=>{t(!0)})},{immediate:!0})}const Tl=Symbol("rippleStop"),YF=80;function nh(e,t){e.style.transform=t,e.style.webkitTransform=t}function El(e){return e.constructor.name==="TouchEvent"}function pg(e){return e.constructor.name==="KeyboardEvent"}const BF=function(e,t){let n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},r=0,s=0;if(!pg(e)){const f=t.getBoundingClientRect(),d=El(e)?e.touches[e.touches.length-1]:e;r=d.clientX-f.left,s=d.clientY-f.top}let o=0,a=.3;t._ripple?.circle?(a=.15,o=t.clientWidth/2,o=n.center?o:o+Math.sqrt((r-o)**2+(s-o)**2)/4):o=Math.sqrt(t.clientWidth**2+t.clientHeight**2)/2;const i=`${(t.clientWidth-o*2)/2}px`,l=`${(t.clientHeight-o*2)/2}px`,u=n.center?i:`${r-o}px`,c=n.center?l:`${s-o}px`;return{radius:o,scale:a,x:u,y:c,centerX:i,centerY:l}},Da={show(e,t){let n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};if(!t?._ripple?.enabled)return;const r=document.createElement("span"),s=document.createElement("span");r.appendChild(s),r.className="v-ripple__container",n.class&&(r.className+=` ${n.class}`);const{radius:o,scale:a,x:i,y:l,centerX:u,centerY:c}=BF(e,t,n),f=`${o*2}px`;s.className="v-ripple__animation",s.style.width=f,s.style.height=f,t.appendChild(r);const d=window.getComputedStyle(t);d&&d.position==="static"&&(t.style.position="relative",t.dataset.previousPosition="static"),s.classList.add("v-ripple__animation--enter"),s.classList.add("v-ripple__animation--visible"),nh(s,`translate(${i}, ${l}) scale3d(${a},${a},${a})`),s.dataset.activated=String(performance.now()),setTimeout(()=>{s.classList.remove("v-ripple__animation--enter"),s.classList.add("v-ripple__animation--in"),nh(s,`translate(${u}, ${c}) scale3d(1,1,1)`)},0)},hide(e){if(!e?._ripple?.enabled)return;const t=e.getElementsByClassName("v-ripple__animation");if(t.length===0)return;const n=t[t.length-1];if(n.dataset.isHiding)return;n.dataset.isHiding="true";const r=performance.now()-Number(n.dataset.activated),s=Math.max(250-r,0);setTimeout(()=>{n.classList.remove("v-ripple__animation--in"),n.classList.add("v-ripple__animation--out"),setTimeout(()=>{e.getElementsByClassName("v-ripple__animation").length===1&&e.dataset.previousPosition&&(e.style.position=e.dataset.previousPosition,delete e.dataset.previousPosition),n.parentNode?.parentNode===e&&e.removeChild(n.parentNode)},300)},s)}};function gg(e){return typeof e>"u"||!!e}function eo(e){const t={},n=e.currentTarget;if(!(!n?._ripple||n._ripple.touched||e[Tl])){if(e[Tl]=!0,El(e))n._ripple.touched=!0,n._ripple.isTouch=!0;else if(n._ripple.isTouch)return;if(t.center=n._ripple.centered||pg(e),n._ripple.class&&(t.class=n._ripple.class),El(e)){if(n._ripple.showTimerCommit)return;n._ripple.showTimerCommit=()=>{Da.show(e,n,t)},n._ripple.showTimer=window.setTimeout(()=>{n?._ripple?.showTimerCommit&&(n._ripple.showTimerCommit(),n._ripple.showTimerCommit=null)},YF)}else Da.show(e,n,t)}}function rh(e){e[Tl]=!0}function Et(e){const t=e.currentTarget;if(t?._ripple){if(window.clearTimeout(t._ripple.showTimer),e.type==="touchend"&&t._ripple.showTimerCommit){t._ripple.showTimerCommit(),t._ripple.showTimerCommit=null,t._ripple.showTimer=window.setTimeout(()=>{Et(e)});return}window.setTimeout(()=>{t._ripple&&(t._ripple.touched=!1)}),Da.hide(t)}}function yg(e){const t=e.currentTarget;t?._ripple&&(t._ripple.showTimerCommit&&(t._ripple.showTimerCommit=null),window.clearTimeout(t._ripple.showTimer))}let to=!1;function bg(e){!to&&(e.keyCode===Yc.enter||e.keyCode===Yc.space)&&(to=!0,eo(e))}function wg(e){to=!1,Et(e)}function _g(e){to&&(to=!1,Et(e))}function Dg(e,t,n){const{value:r,modifiers:s}=t,o=gg(r);if(o||Da.hide(e),e._ripple=e._ripple??{},e._ripple.enabled=o,e._ripple.centered=s.center,e._ripple.circle=s.circle,el(r)&&r.class&&(e._ripple.class=r.class),o&&!n){if(s.stop){e.addEventListener("touchstart",rh,{passive:!0}),e.addEventListener("mousedown",rh);return}e.addEventListener("touchstart",eo,{passive:!0}),e.addEventListener("touchend",Et,{passive:!0}),e.addEventListener("touchmove",yg,{passive:!0}),e.addEventListener("touchcancel",Et),e.addEventListener("mousedown",eo),e.addEventListener("mouseup",Et),e.addEventListener("mouseleave",Et),e.addEventListener("keydown",bg),e.addEventListener("keyup",wg),e.addEventListener("blur",_g),e.addEventListener("dragstart",Et,{passive:!0})}else!o&&n&&Cg(e)}function Cg(e){e.removeEventListener("mousedown",eo),e.removeEventListener("touchstart",eo),e.removeEventListener("touchend",Et),e.removeEventListener("touchmove",yg),e.removeEventListener("touchcancel",Et),e.removeEventListener("mouseup",Et),e.removeEventListener("mouseleave",Et),e.removeEventListener("keydown",bg),e.removeEventListener("keyup",wg),e.removeEventListener("dragstart",Et),e.removeEventListener("blur",_g)}function HF(e,t){Dg(e,t,!1)}function jF(e){delete e._ripple,Cg(e)}function VF(e,t){if(t.value===t.oldValue)return;const n=gg(t.oldValue);Dg(e,t,n)}const WF={mounted:HF,unmounted:jF,updated:VF},UF=$e({active:{type:Boolean,default:void 0},baseColor:String,symbol:{type:null,default:cg},flat:Boolean,icon:[Boolean,String,Function,Object],prependIcon:zs,appendIcon:zs,block:Boolean,readonly:Boolean,slim:Boolean,stacked:Boolean,ripple:{type:[Boolean,Object],default:!0},text:String,...sg(),...ln(),...Hu(),...dg(),...Vu(),...bF(),...PF(),...qu(),...vg(),...si(),...NF(),...Ku(),...Zn({tag:"button"}),...wr(),...zu({variant:"elevated"})},"VBtn"),zF=At()({name:"VBtn",props:UF(),emits:{"group:selected":e=>!0},setup(e,t){let{attrs:n,slots:r}=t;const{themeClasses:s}=_r(e),{borderClasses:o}=og(e),{densityClasses:a}=ju(e),{dimensionStyles:i}=hg(e),{elevationClasses:l}=Wu(e),{loaderClasses:u}=AF(e),{locationStyles:c}=Zu(e),{positionClasses:f}=mg(e),{roundedClasses:d}=oi(e),{sizeClasses:h,sizeStyles:v}=Gu(e),m=wF(e,e.symbol,!1),p=RF(e,n),b=w(()=>e.active!==void 0?e.active:p.isLink.value?p.isActive?.value:m?.isSelected.value),S=w(()=>({color:m?.isSelected.value&&(!p.isLink.value||p.isActive?.value)||!m||p.isActive?.value?e.color??e.baseColor:e.baseColor,variant:e.variant})),{colorClasses:T,colorStyles:M,variantClasses:D}=ig(S),C=w(()=>m?.disabled.value||e.disabled),E=w(()=>e.variant==="elevated"&&!(e.disabled||e.flat||e.border)),P=w(()=>{if(!(e.value===void 0||typeof e.value=="symbol"))return Object(e.value)===e.value?JSON.stringify(e.value,null,0):e.value});function $(I){C.value||p.isLink.value&&(I.metaKey||I.ctrlKey||I.shiftKey||I.button!==0||n.target==="_blank")||(p.navigate?.(I),m?.toggle())}return FF(p,m?.select),br(()=>{const I=p.isLink.value?"a":e.tag,j=!!(e.prependIcon||r.prepend),O=!!(e.appendIcon||r.append),W=!!(e.icon&&e.icon!==!0);return Ul(L(I,{type:I==="a"?void 0:"button",class:["v-btn",m?.selectedClass.value,{"v-btn--active":b.value,"v-btn--block":e.block,"v-btn--disabled":C.value,"v-btn--elevated":E.value,"v-btn--flat":e.flat,"v-btn--icon":!!e.icon,"v-btn--loading":e.loading,"v-btn--readonly":e.readonly,"v-btn--slim":e.slim,"v-btn--stacked":e.stacked},s.value,o.value,T.value,a.value,l.value,u.value,f.value,d.value,h.value,D.value,e.class],style:[M.value,i.value,c.value,v.value,e.style],"aria-busy":e.loading?!0:void 0,disabled:C.value||void 0,href:p.href.value,tabindex:e.loading||e.readonly?-1:void 0,onClick:$,value:P.value},{default:()=>[ag(!0,"v-btn"),!e.icon&&j&&L("span",{key:"prepend",class:"v-btn__prepend"},[r.prepend?L(Fs,{key:"prepend-defaults",disabled:!e.prependIcon,defaults:{VIcon:{icon:e.prependIcon}}},r.prepend):L(Ko,{key:"prepend-icon",icon:e.prependIcon},null)]),L("span",{class:"v-btn__content","data-no-activator":""},[!r.default&&W?L(Ko,{key:"content-icon",icon:e.icon},null):L(Fs,{key:"content-defaults",disabled:!W,defaults:{VIcon:{icon:e.icon}}},{default:()=>[r.default?.()??e.text]})]),!e.icon&&O&&L("span",{key:"append",class:"v-btn__append"},[r.append?L(Fs,{key:"append-defaults",disabled:!e.appendIcon,defaults:{VIcon:{icon:e.appendIcon}}},r.append):L(Ko,{key:"append-icon",icon:e.appendIcon},null)]),!!e.loading&&L("span",{key:"loader",class:"v-btn__loader"},[r.loader?.()??L(MF,{color:typeof e.loading=="boolean"?void 0:e.loading,indeterminate:!0,width:"2"},null)])]}),[[WF,!C.value&&e.ripple,"",{center:!!e.icon}]])}),{group:m}}}),KF=["success","info","warning","error"],GF=$e({border:{type:[Boolean,String],validator:e=>typeof e=="boolean"||["top","end","bottom","start"].includes(e)},borderColor:String,closable:Boolean,closeIcon:{type:zs,default:"$close"},closeLabel:{type:String,default:"$vuetify.close"},icon:{type:[Boolean,String,Function,Object],default:null},modelValue:{type:Boolean,default:!0},prominent:Boolean,title:String,text:String,type:{type:String,validator:e=>KF.includes(e)},...ln(),...Hu(),...dg(),...Vu(),...qu(),...vg(),...si(),...Zn(),...wr(),...zu({variant:"flat"})},"VAlert"),qF=At()({name:"VAlert",props:GF(),emits:{"click:close":e=>!0,"update:modelValue":e=>!0},setup(e,t){let{emit:n,slots:r}=t;const s=Na(e,"modelValue"),o=w(()=>{if(e.icon!==!1)return e.type?e.icon??`$${e.type}`:e.icon}),a=w(()=>({color:e.color??e.type,variant:e.variant})),{themeClasses:i}=_r(e),{colorClasses:l,colorStyles:u,variantClasses:c}=ig(a),{densityClasses:f}=ju(e),{dimensionStyles:d}=hg(e),{elevationClasses:h}=Wu(e),{locationStyles:v}=Zu(e),{positionClasses:m}=mg(e),{roundedClasses:p}=oi(e),{textColorClasses:b,textColorStyles:S}=Qs(et(e,"borderColor")),{t:T}=a1(),M=w(()=>({"aria-label":T(e.closeLabel),onClick(D){s.value=!1,n("click:close",D)}}));return()=>{const D=!!(r.prepend||o.value),C=!!(r.title||e.title),E=!!(r.close||e.closable);return s.value&&L(e.tag,{class:["v-alert",e.border&&{"v-alert--border":!!e.border,[`v-alert--border-${e.border===!0?"start":e.border}`]:!0},{"v-alert--prominent":e.prominent},i.value,l.value,f.value,h.value,m.value,p.value,c.value,e.class],style:[u.value,d.value,v.value,e.style],role:"alert"},{default:()=>[ag(!1,"v-alert"),e.border&&L("div",{key:"border",class:["v-alert__border",b.value],style:S.value},null),D&&L("div",{key:"prepend",class:"v-alert__prepend"},[r.prepend?L(Fs,{key:"prepend-defaults",disabled:!o.value,defaults:{VIcon:{density:e.density,icon:o.value,size:e.prominent?44:28}}},r.prepend):L(Ko,{key:"prepend-icon",density:e.density,icon:o.value,size:e.prominent?44:28},null)]),L("div",{class:"v-alert__content"},[C&&L(mF,{key:"title"},{default:()=>[r.title?.()??e.title]}),r.text?.()??e.text,r.default?.()]),r.append&&L("div",{key:"append",class:"v-alert__append"},[r.append()]),E&&L("div",{key:"close",class:"v-alert__close"},[r.close?L(Fs,{key:"close-defaults",defaults:{VBtn:{icon:e.closeIcon,size:"x-small",variant:"text"}}},{default:()=>[r.close?.({props:M.value})]}):L(zF,qt({key:"close-btn",icon:e.closeIcon,size:"x-small",variant:"text"},M.value),null)])]})}}}),ZF=e=>(Ey("data-v-ac10aa7f"),e=e(),Oy(),e),JF={is:"animated-details"},XF=ZF(()=>me("summary",null,"Error",-1)),QF={__name:"ErrorAlert",props:{modelValue:{type:String,required:!0},modelModifiers:{}},emits:["update:modelValue"],setup(e){const t=hb(e,"modelValue"),r=Pe(mo).brand.errorMessage??"something went wrong, please try again later";return(s,o)=>t.value?(G(),Ae(qF,{key:0,translate:"yes",location:"start bottom",type:"error",position:"fixed","onClick:close":o[0]||(o[0]=a=>t.value=""),variant:"elevated",icon:[A(mw)],class:"alert",closable:"","close-icon":[A(yw)]},{default:Ee(()=>[Kr(Xe(A(r))+" ",1),me("details",JF,[XF,Kr(" "+Xe(t.value),1)])]),_:1},8,["icon","close-icon"])):We("v-if",!0)}},Ju=vF(QF,[["__scopeId","data-v-ac10aa7f"]]),Sg=Ba.reduce((e,t)=>(e[t]={type:[Boolean,String,Number],default:!1},e),{}),$g=Ba.reduce((e,t)=>{const n="offset"+Dn(t);return e[n]={type:[String,Number],default:null},e},{}),Tg=Ba.reduce((e,t)=>{const n="order"+Dn(t);return e[n]={type:[String,Number],default:null},e},{}),sh={col:Object.keys(Sg),offset:Object.keys($g),order:Object.keys(Tg)};function eY(e,t,n){let r=e;if(!(n==null||n===!1)){if(t){const s=t.replace(e,"");r+=`-${s}`}return e==="col"&&(r="v-"+r),e==="col"&&(n===""||n===!0)||(r+=`-${n}`),r.toLowerCase()}}const tY=["auto","start","end","center","baseline","stretch"],nY=$e({cols:{type:[Boolean,String,Number],default:!1},...Sg,offset:{type:[String,Number],default:null},...$g,order:{type:[String,Number],default:null},...Tg,alignSelf:{type:String,default:null,validator:e=>tY.includes(e)},...ln(),...Zn()},"VCol"),rY=At()({name:"VCol",props:nY(),setup(e,t){let{slots:n}=t;const r=w(()=>{const s=[];let o;for(o in sh)sh[o].forEach(i=>{const l=e[i],u=eY(o,i,l);u&&s.push(u)});const a=s.some(i=>i.startsWith("v-col-"));return s.push({"v-col":!a||!e.cols,[`v-col-${e.cols}`]:e.cols,[`offset-${e.offset}`]:e.offset,[`order-${e.order}`]:e.order,[`align-self-${e.alignSelf}`]:e.alignSelf}),s});return()=>lo(e.tag,{class:[r.value,e.class],style:e.style},n.default?.())}}),Xu=["start","end","center"],Eg=["space-between","space-around","space-evenly"];function Qu(e,t){return Ba.reduce((n,r)=>{const s=e+Dn(r);return n[s]=t(),n},{})}const sY=[...Xu,"baseline","stretch"],Og=e=>sY.includes(e),Mg=Qu("align",()=>({type:String,default:null,validator:Og})),oY=[...Xu,...Eg],kg=e=>oY.includes(e),xg=Qu("justify",()=>({type:String,default:null,validator:kg})),aY=[...Xu,...Eg,"stretch"],Pg=e=>aY.includes(e),Ag=Qu("alignContent",()=>({type:String,default:null,validator:Pg})),oh={align:Object.keys(Mg),justify:Object.keys(xg),alignContent:Object.keys(Ag)},iY={align:"align",justify:"justify",alignContent:"align-content"};function lY(e,t,n){let r=iY[e];if(n!=null){if(t){const s=t.replace(e,"");r+=`-${s}`}return r+=`-${n}`,r.toLowerCase()}}const uY=$e({dense:Boolean,noGutters:Boolean,align:{type:String,default:null,validator:Og},...Mg,justify:{type:String,default:null,validator:kg},...xg,alignContent:{type:String,default:null,validator:Pg},...Ag,...ln(),...Zn()},"VRow"),cY=At()({name:"VRow",props:uY(),setup(e,t){let{slots:n}=t;const r=w(()=>{const s=[];let o;for(o in oh)oh[o].forEach(a=>{const i=e[a],l=lY(o,a,i);l&&s.push(l)});return s.push({"v-row--no-gutters":e.noGutters,"v-row--dense":e.dense,[`align-${e.align}`]:e.align,[`justify-${e.justify}`]:e.justify,[`align-content-${e.alignContent}`]:e.alignContent}),s});return()=>lo(e.tag,{class:["v-row",r.value,e.class],style:e.style},n.default?.())}}),fY={key:1,class:"text-center"},dY=me("div",{class:"text-center"},"Loading...",-1),hY={__name:"Loading",setup(e){const t=Pe(mo),[n]=hF([t.template.loading]),r=oe("");return xa((s,o,a)=>{r.value=` ${s}. component: ${o?.$.type.name}. info: ${a}. - `}),(s,o)=>(G(),Ae(hY,{class:"d-flex justify-center align-center"},{default:Ee(()=>[L(aY,{class:"flex-column justify-center align-center"},{default:Ee(()=>[L(Xu,{modelValue:r.value,"onUpdate:modelValue":o[0]||(o[0]=a=>r.value=a)},null,8,["modelValue"]),(G(),Ae(Ia,null,{fallback:Ee(()=>[mY]),default:Ee(()=>[A(n).component?(G(),Ae(Pa(A(n).component),Rr(qt({key:0},A(n).props)),null,16)):(G(),ae("div",vY,"Loading..."))]),_:1}))]),_:1})]),_:1}))}},gY={class:"loading-container"},yY={__name:"Dashboard",props:{config:{type:String},onTemplateMount:{type:Function}},async setup(e){let t,n;zb(b=>({"0e50fc87":A(d)}));const r=e,s=([t,n]=hi(()=>hF(r.config)),t=await t,n(),t);lF();const o=iF("dashboardTheme",s.brand?.theme);o.global.name.value="dashboardTheme",[t,n]=hi(()=>vF(s.brand?.font?.family,s.brand?.font?.link,!!r.onTemplateMount)),await t,n();const{loadSTAC:a}=ri();[t,n]=hi(()=>a()),await t,n();const{smAndDown:i}=tw(),l=i.value?or(()=>Xe(()=>import("./MobileLayout-Bse6a_iI.js"),__vite__mapDeps([24,5,22,6,14,25,26,27]))):or(()=>Xe(()=>import("./DashboardLayout-B8MEdnS8.js"),__vite__mapDeps([28,25,22,26,29]))),u=or(()=>Xe(()=>import("./Header-CWK95wXa.js"),__vite__mapDeps([30,16,6,17,14,22,31]))),c=or(()=>Xe(()=>import("./Footer-9K1bUbvk.js"),__vite__mapDeps([32,33]))),{mainRect:f}=vw(),d=s.brand.noLayout?r.onTemplateMount?"100%":"90dvh":`calc(100dvh - ${f.value.top+f.value.bottom}px)`,h=oe(null),v=oe(null),m=[h,v];Gt(()=>{r.onTemplateMount&&!s.brand.noLayout&&m.forEach(b=>{b.value.$el.style.opacity="0"})});const p=oe("");return ka((b,S,T)=>{p.value=` + `}),(s,o)=>(G(),Ae(cY,{class:"d-flex justify-center align-center"},{default:Ee(()=>[L(rY,{class:"flex-column justify-center align-center"},{default:Ee(()=>[L(Ju,{modelValue:r.value,"onUpdate:modelValue":o[0]||(o[0]=a=>r.value=a)},null,8,["modelValue"]),(G(),Ae(Ia,null,{fallback:Ee(()=>[dY]),default:Ee(()=>[A(n).component?(G(),Ae(Pa(A(n).component),Rr(qt({key:0},A(n).props)),null,16)):(G(),ae("div",fY,"Loading..."))]),_:1}))]),_:1})]),_:1}))}},vY={class:"loading-container"},mY={__name:"Dashboard",props:{config:{type:String},onTemplateMount:{type:Function}},async setup(e){let t,n;Ub(b=>({"0e50fc87":A(d)}));const r=e,s=([t,n]=hi(()=>cF(r.config)),t=await t,n(),t);oF();const o=sF("dashboardTheme",s.brand?.theme);o.global.name.value="dashboardTheme",[t,n]=hi(()=>fF(s.brand?.font?.family,s.brand?.font?.link,!!r.onTemplateMount)),await t,n();const{loadSTAC:a}=ri();[t,n]=hi(()=>a()),await t,n();const{smAndDown:i}=X1(),l=i.value?or(()=>Qe(()=>import("./MobileLayout-DtBtTe7v.js"),__vite__mapDeps([19,5,20,6,14,21,22,23]))):or(()=>Qe(()=>import("./DashboardLayout-Bklr6-8p.js"),__vite__mapDeps([24,21,20,22,25]))),u=or(()=>Qe(()=>import("./Header-LhvQ5ty7.js"),__vite__mapDeps([26,15,6,16,14,20,27]))),c=or(()=>Qe(()=>import("./Footer-Bbz6BUHt.js"),__vite__mapDeps([28,29]))),{mainRect:f}=fw(),d=s.brand.noLayout?r.onTemplateMount?"100%":"90dvh":`calc(100dvh - ${f.value.top+f.value.bottom}px)`,h=oe(null),v=oe(null),m=[h,v];Gt(()=>{r.onTemplateMount&&!s.brand.noLayout&&m.forEach(b=>{b.value.$el.style.opacity="0"})});const p=oe("");return xa((b,S,T)=>{p.value=` ${b}. component: ${S?.$.type.name}. info: ${T}. - `}),(b,S)=>(G(),ae(be,null,[A(s).brand.noLayout?We("v-if",!0):(G(),Ae(A(u),{key:0,ref_key:"headerRef",ref:h},null,512)),L(Xu,{modelValue:p.value,"onUpdate:modelValue":S[0]||(S[0]=T=>p.value=T)},null,8,["modelValue"]),(G(),Ae(Ia,null,{fallback:Ee(()=>[me("div",gY,[L(pY)])]),default:Ee(()=>[L(A(l),{onVnodeMounted:S[1]||(S[1]=T=>e.onTemplateMount?.(m)),class:"template"},null,512)]),_:1})),A(s).brand.noLayout?We("v-if",!0):(G(),Ae(A(c),{key:1,ref_key:"footerRef",ref:v},null,512))],64))}},bY=$e({...ln(),...hw({fullHeight:!0}),...wr()},"VApp"),wY=At()({name:"VApp",props:bY(),setup(e,t){let{slots:n}=t;const r=_r(e),{layoutClasses:s,getLayoutItem:o,items:a,layoutRef:i}=pw(e),{rtlClasses:l}=Fa();return br(()=>L("div",{ref:i,class:["v-application",r.themeClasses.value,s.value,l.value,e.class],style:[e.style]},[L("div",{class:"v-application__wrap"},[L(Ia,null,{default:()=>[L(be,null,[n.default?.()])]})])])),{getLayoutItem:o,items:a,theme:r}}}),_Y={__name:"App",setup(e){const t=oe("");return ka((n,r,s)=>{t.value=` + `}),(b,S)=>(G(),ae(be,null,[A(s).brand.noLayout?We("v-if",!0):(G(),Ae(A(u),{key:0,ref_key:"headerRef",ref:h},null,512)),L(Ju,{modelValue:p.value,"onUpdate:modelValue":S[0]||(S[0]=T=>p.value=T)},null,8,["modelValue"]),(G(),Ae(Ia,null,{fallback:Ee(()=>[me("div",vY,[L(hY)])]),default:Ee(()=>[L(A(l),{onVnodeMounted:S[1]||(S[1]=T=>e.onTemplateMount?.(m)),class:"template"},null,512)]),_:1})),A(s).brand.noLayout?We("v-if",!0):(G(),Ae(A(c),{key:1,ref_key:"footerRef",ref:v},null,512))],64))}},pY=$e({...ln(),...cw({fullHeight:!0}),...wr()},"VApp"),gY=At()({name:"VApp",props:pY(),setup(e,t){let{slots:n}=t;const r=_r(e),{layoutClasses:s,getLayoutItem:o,items:a,layoutRef:i}=hw(e),{rtlClasses:l}=Fa();return br(()=>L("div",{ref:i,class:["v-application",r.themeClasses.value,s.value,l.value,e.class],style:[e.style]},[L("div",{class:"v-application__wrap"},[L(Ia,null,{default:()=>[L(be,null,[n.default?.()])]})])])),{getLayoutItem:o,items:a,theme:r}}}),yY={__name:"App",setup(e){const t=oe("");return xa((n,r,s)=>{t.value=` ${n}. component: ${r?.$.type.name}. info: ${s}. - `}),(n,r)=>(G(),Ae(wY,null,{default:Ee(()=>[(G(),Ae(Ia,null,{fallback:Ee(()=>[L(Xu,{modelValue:t.value,"onUpdate:modelValue":r[0]||(r[0]=s=>t.value=s)},null,8,["modelValue"])]),default:Ee(()=>[L(yY)]),_:1}))]),_:1}))}},Lg=g0(_Y);dF(Lg);Lg.mount("#app");export{G as $,CF as A,SY as B,Fe as C,Ot as D,BY as E,be as F,_F as G,tw as H,zs as I,qv as J,HY as K,ot as L,Ko as M,E0 as N,ju as O,Vu as P,Li as Q,et as R,Fv as S,tl as T,zb as U,qF as V,mo as W,pF as X,vw as Y,Gt as Z,gF as _,br as a,UY as a$,Ae as a0,Ee as a1,Ia as a2,A as a3,Pa as a4,We as a5,ae as a6,Ft as a7,Kr as a8,me as a9,Pw as aA,ri as aB,hY as aC,By as aD,TR as aE,GY as aF,qY as aG,Yo as aH,Ue as aI,Br as aJ,Ap as aK,je as aL,ll as aM,ss as aN,Pr as aO,Ts as aP,Lw as aQ,xR as aR,ZY as aS,KY as aT,zY as aU,s1 as aV,DY as aW,vb as aX,MR as aY,WY as aZ,aY as a_,Qe as aa,uo as ab,hg as ac,vg as ad,og as ae,Wu as af,si as ag,ag as ah,Uu as ai,oi as aj,Fs as ak,na as al,yr as am,jY as an,w0 as ao,zn as ap,VY as aq,Oy as ar,My as as,Xe as at,sg as au,JY as av,Ra as aw,vn as ax,TY as ay,lo as az,L as b,XY as b0,Zu as b1,mg as b2,Ju as b3,pg as b4,so as b5,xY as b6,kY as b7,Ll as b8,xv as b9,nu as bA,M0 as bB,EY as bC,Ze as bD,Gu as bE,qu as bF,LF as bG,RF as bH,QY as bI,_0 as bJ,Ay as bK,$Y as bL,xt as bM,hi as bN,P0 as ba,LY as bb,RY as bc,NY as bd,FY as be,Il as bf,IY as bg,St as bh,x0 as bi,AY as bj,Ea as bk,ge as bl,e3 as bm,CY as bn,t3 as bo,pn as bp,$0 as bq,co as br,PY as bs,BF as bt,Ku as bu,KF as bv,YF as bw,lg as bx,YY as by,ig as bz,w as c,qt as d,ln as e,Zn as f,At as g,wr as h,_r as i,Fa as j,OY as k,u1 as l,GF as m,SF as n,MY as o,$e as p,Pt as q,oe as r,Ut as s,zl as t,Qs as u,Yy as v,Te as w,Pe as x,Na as y,DF as z}; + `}),(n,r)=>(G(),Ae(gY,null,{default:Ee(()=>[(G(),Ae(Ia,null,{fallback:Ee(()=>[L(Ju,{modelValue:t.value,"onUpdate:modelValue":r[0]||(r[0]=s=>t.value=s)},null,8,["modelValue"])]),default:Ee(()=>[L(mY)]),_:1}))]),_:1}))}},Ig=p0(yY);uF(Ig);Ig.mount("#app");export{G as $,wF as A,_Y as B,Fe as C,Ot as D,LY as E,be as F,yF as G,X1 as H,zs as I,Gv as J,RY as K,ot as L,Ko as M,OY as N,Hu as O,ju as P,Li as Q,et as R,Nv as S,el as T,Ub as U,zF as V,mo as W,hF as X,fw as Y,Gt as Z,vF as _,br as a,ag as a$,Ae as a0,Ee as a1,Ia as a2,A as a3,Pa as a4,We as a5,ae as a6,Ft as a7,Kr as a8,me as a9,lo as aA,Mw as aB,ri as aC,cY as aD,Yy as aE,CR as aF,VY as aG,WY as aH,Yo as aI,Ue as aJ,Br as aK,Pp as aL,je as aM,il as aN,ss as aO,Pr as aP,Ts as aQ,Pw as aR,ER as aS,UY as aT,jY as aU,HY as aV,t1 as aW,Ku as aX,zu as aY,ig as aZ,Gu as a_,Xe as aa,uo as ab,dg as ac,hg as ad,sg as ae,Vu as af,si as ag,og as ah,Wu as ai,oi as aj,Fs as ak,na as al,yr as am,NY as an,b0 as ao,zn as ap,FY as aq,Ea as ar,Ey as as,Oy as at,zY as au,Qe as av,rg as aw,Ra as ax,vn as ay,CY as az,L as b,PF as b0,qu as b1,vg as b2,NF as b3,WF as b4,AF as b5,Zu as b6,mg as b7,RF as b8,GY as b9,ge as bA,qY as bB,wY as bC,ZY as bD,pn as bE,hi as bF,bY as ba,hb as bb,TR as bc,YY as bd,rY as be,BY as bf,KY as bg,w0 as bh,St as bi,Py as bj,DY as bk,kt as bl,so as bm,TY as bn,EY as bo,Il as bp,Mv as bq,M0 as br,xY as bs,PY as bt,AY as bu,IY as bv,Al as bw,kY as bx,E0 as by,MY as bz,w as c,qt as d,ln as e,Zn as f,At as g,wr as h,_r as i,Fa as j,SY as k,a1 as l,UF as m,_F as n,$Y as o,$e as p,Pt as q,oe as r,Ut as s,Ul as t,Qs as u,Fy as v,Te as w,Pe as x,Na as y,bF as z}; diff --git a/pr-preview/pr-17/assets/lerc-B4lXefGh-C409q0WS.js b/pr-preview/pr-17/assets/lerc-B4lXefGh-AVOSkc8n.js similarity index 99% rename from pr-preview/pr-17/assets/lerc-B4lXefGh-C409q0WS.js rename to pr-preview/pr-17/assets/lerc-B4lXefGh-AVOSkc8n.js index fd70145..bb96e6f 100644 --- a/pr-preview/pr-17/assets/lerc-B4lXefGh-C409q0WS.js +++ b/pr-preview/pr-17/assets/lerc-B4lXefGh-AVOSkc8n.js @@ -1 +1 @@ -import{b as tA}from"./pako.esm-CB1uQYY0-DQSVoCko.js";import{o as sA,a as gA,x as rA}from"./EodashMap-BVEvKne5.js";import{g as DA}from"./basedecoder-DHcBySSe-gdlnpIMU.js";import"./_commonjsHelpers-Cpj98o6Y.js";import"./helpers-DVHVKCdb.js";import"./index-BHzPgH2J.js";var iA={exports:{}};(function(W){/* Copyright 2015-2021 Esri. Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 @preserve */(function(){var u=function(){var N={};N.defaultNoDataValue=-34027999387901484e22,N.decode=function(I,a){a=a||{};var Q=a.encodedMaskData||a.encodedMaskData===null,g=E(I,a.inputOffset||0,Q),r=a.noDataValue!==null?a.noDataValue:N.defaultNoDataValue,B=d(g,a.pixelType||Float32Array,a.encodedMaskData,r,a.returnMask),C={width:g.width,height:g.height,pixelData:B.resultPixels,minValue:B.minValue,maxValue:g.pixels.maxValue,noDataValue:r};return B.resultMask&&(C.maskData=B.resultMask),a.returnEncodedMask&&g.mask&&(C.encodedMaskData=g.mask.bitset?g.mask.bitset:null),a.returnFileInfo&&(C.fileInfo=m(g),a.computeUsedBitDepths&&(C.fileInfo.bitDepths=z(g))),C};var d=function(I,a,Q,g,r){var B=0,C=I.pixels.numBlocksX,t=I.pixels.numBlocksY,o=Math.floor(I.width/C),s=Math.floor(I.height/t),n=2*I.maxZError,e=Number.MAX_VALUE,i;Q=Q||(I.mask?I.mask.bitset:null);var h,y;h=new a(I.width*I.height),r&&Q&&(y=new Uint8Array(I.width*I.height));for(var S=new Float32Array(o*s),f,c,G=0;G<=t;G++){var M=G!==t?s:I.height%t;if(M!==0)for(var w=0;w<=C;w++){var D=w!==C?o:I.width%C;if(D!==0){var l=G*I.width*s+w*o,F=I.width-D,k=I.pixels.blocks[B],R,U,L;k.encoding<2?(k.encoding===0?R=k.rawData:(A(k.stuffedData,k.bitsPerPixel,k.numValidPixels,k.offset,n,S,I.pixels.maxValue),R=S),U=0):k.encoding===2?L=0:L=k.offset;var J;if(Q)for(c=0;c>3],J<<=l&7),f=0;f>3]),J&128?(y&&(y[l]=1),i=k.encoding<2?R[U++]:L,e=e>i?i:e,h[l++]=i):(y&&(y[l]=0),h[l++]=g),J<<=1;l+=F}else if(k.encoding<2)for(c=0;ci?i:e,h[l++]=i;l+=F}else for(e=e>L?L:e,c=0;c0){var C=new Uint8Array(Math.ceil(g.width*g.height/8));B=new DataView(I,a,g.mask.numBytes);var t=B.getInt16(0,!0),o=2,s=0;do{if(t>0)for(;t--;)C[s++]=B.getUint8(o++);else{var n=B.getUint8(o++);for(t=-t;t--;)C[s++]=n}t=B.getInt16(o,!0),o+=2}while(o0?1:0),y=i+(g.height%i>0?1:0);g.pixels.blocks=new Array(h*y);for(var S=0,f=0;f3)throw"Invalid block encoding ("+w.encoding+")";if(w.encoding===2){a++;continue}if(D!==0&&D!==2){if(D>>=6,w.offsetType=D,D===2)w.offset=B.getInt8(1),G++;else if(D===1)w.offset=B.getInt16(1,!0),G+=2;else if(D===0)w.offset=B.getFloat32(1,!0),G+=4;else throw"Invalid block offset type";if(w.encoding===1)if(D=B.getUint8(G),G++,w.bitsPerPixel=D&63,D>>=6,w.numValidPixelsType=D,D===2)w.numValidPixels=B.getUint8(G),G++;else if(D===1)w.numValidPixels=B.getUint16(G,!0),G+=2;else if(D===0)w.numValidPixels=B.getUint32(G,!0),G+=4;else throw"Invalid valid pixel count type"}if(a+=G,w.encoding!==3){var l,F;if(w.encoding===0){var k=(g.pixels.numBytes-1)/4;if(k!==Math.floor(k))throw"uncompressed block has invalid length";l=new ArrayBuffer(k*4),F=new Uint8Array(l),F.set(new Uint8Array(I,a,k*4));var R=new Float32Array(l);w.rawData=R,a+=k*4}else if(w.encoding===1){var U=Math.ceil(w.numValidPixels*w.bitsPerPixel/8),L=Math.ceil(U/4);l=new ArrayBuffer(L*4),F=new Uint8Array(l),F.set(new Uint8Array(I,a,U)),w.stuffedData=new Uint32Array(l),a+=U}}}return g.eofOffset=a,g},A=function(I,a,Q,g,r,B,C){var t=(1<=a)e=i>>>n-a&t,n-=a;else{var S=a-n;e=(i&t)<>>n}B[s]=e=I?(n=e>>>s-I&C,s-=I):(i=I-s,n=(e&C)<>>s),A[o]=Q[n];else for(h=Math.ceil((B-g)/r),o=0;o=I?(n=e>>>s-I&C,s-=I):(i=I-s,n=(e&C)<>>s),A[o]=n=A?(s=n>>>o-A&r,o-=A):(t=A-o,s=(n&r)<>>o),e[C]=s=I?(e=i>>>n&C,s-=I,n+=I):(h=I-s,e=i>>>n&C,i=E[t++],s=32-h,e|=(i&(1<=I?(e=i>>>n&C,s-=I,n+=I):(h=I-s,e=i>>>n&C,i=E[t++],s=32-h,e|=(i&(1<=A?(s=e>>>n&r,o-=A,n+=A):(t=A-o,s=e>>>n&r,e=E[B++],o=32-t,s|=(e&(1<=I?(C=t>>>B-I&Q,B-=I):(o=I-B,C=(t&Q)<>>B),A[r]=C;return A},originalUnstuff2:function(E,A,I,a){var Q=(1<=I?(t=o>>>C&Q,B-=I,C+=I):(s=I-B,t=o>>>C&Q,o=E[g++],B=32-s,t|=(o&(1<=359?359:Q;Q-=r;do A+=E[g++]<<8,I+=A+=E[g++];while(--r);A=(A&65535)+(A>>>16),I=(I&65535)+(I>>>16)}return a&1&&(I+=A+=E[g]<<8),A=(A&65535)+(A>>>16),I=(I&65535)+(I>>>16),(I<<16|A)>>>0},readHeaderInfo:function(E,A){var I=A.ptr,a=new Uint8Array(E,I,6),Q={};if(Q.fileIdentifierString=String.fromCharCode.apply(null,a),Q.fileIdentifierString.lastIndexOf("Lerc2",0)!==0)throw"Unexpected file identifier string (expect Lerc2 ): "+Q.fileIdentifierString;I+=6;var g=new DataView(E,I,8),r=g.getInt32(0,!0);Q.fileVersion=r,I+=4,r>=3&&(Q.checksum=g.getUint32(4,!0),I+=4),g=new DataView(E,I,12),Q.height=g.getUint32(0,!0),Q.width=g.getUint32(4,!0),I+=8,r>=4?(Q.numDims=g.getUint32(8,!0),I+=4):Q.numDims=1,g=new DataView(E,I,40),Q.numValidPixel=g.getUint32(0,!0),Q.microBlockSize=g.getInt32(4,!0),Q.blobSize=g.getInt32(8,!0),Q.imageType=g.getInt32(12,!0),Q.maxZError=g.getFloat64(16,!0),Q.zMin=g.getFloat64(24,!0),Q.zMax=g.getFloat64(32,!0),I+=40,A.headerInfo=Q,A.ptr=I;var B,C;if(r>=3&&(C=r>=4?52:48,B=this.computeChecksumFletcher32(new Uint8Array(E,I-C,Q.blobSize-14)),B!==Q.checksum))throw"Checksum failed.";return!0},checkMinMaxRanges:function(E,A){var I=A.headerInfo,a=this.getDataTypeArray(I.imageType),Q=I.numDims*this.getDataTypeSize(I.imageType),g=this.readSubArray(E,A.ptr,a,Q),r=this.readSubArray(E,A.ptr+Q,a,Q);A.ptr+=2*Q;var B,C=!0;for(B=0;B0){C=new Uint8Array(Math.ceil(Q/8)),r=new DataView(E,I,B.numBytes);var o=r.getInt16(0,!0),s=2,n=0,e=0;do{if(o>0)for(;o--;)C[n++]=r.getUint8(s++);else for(e=r.getUint8(s++),o=-o;o--;)C[n++]=e;o=r.getInt16(s,!0),s+=2}while(s>3],i<<=h&7):i=C[h>>3],i&128&&(t[h]=1);A.pixels.resultMask=t,B.bitset=C,I+=B.numBytes}return A.ptr=I,A.mask=B,!0},readDataOneSweep:function(E,A,I,a){var Q=A.ptr,g=A.headerInfo,r=g.numDims,B=g.width*g.height,C=g.imageType,t=g.numValidPixel*d.getDataTypeSize(C)*r,o,s=A.pixels.resultMask;if(I===Uint8Array)o=new Uint8Array(E,Q,t);else{var n=new ArrayBuffer(t),e=new Uint8Array(n);e.set(new Uint8Array(E,Q,t)),o=new I(n)}if(o.length===B*r)a?A.pixels.resultPixels=d.swapDimensionOrder(o,B,r,I,!0):A.pixels.resultPixels=o;else{A.pixels.resultPixels=new I(B*r);var i=0,h=0,y=0,S=0;if(r>1){if(a){for(h=0;h=B)return!1;var C=new Uint32Array(B-r);d.decodeBits(E,A,C);var t=[],o,s,n,e;for(o=r;o0&&(t[s].second=G<>>32-e,32-c>=e?(c+=e,c===32&&(c=0,M++,G=f[M])):(c+=e-32,M++,G=f[M],t[s].second|=G>>>32-c));var w=0,D=0,l=new m;for(o=0;o=I?D=I:D=w;var F=[],k,R,U,L,J,q;for(o=r;o0)if(k=[e,s],e<=D)for(R=t[s].second<=0;L--)J=R>>>L&1,J?(q.right||(q.right=new m),q=q.right):(q.left||(q.left=new m),q=q.left),L===0&&!q.val&&(q.val=k[1]);return{decodeLut:F,numBitsLUTQick:D,numBitsLUT:w,tree:l,stuffedData:f,srcPtr:M,bitPos:c}},readHuffman:function(E,A,I,a){var Q=A.headerInfo,g=Q.numDims,r=A.headerInfo.height,B=A.headerInfo.width,C=B*r,t=this.readHuffmanTree(E,A),o=t.decodeLut,s=t.tree,n=t.stuffedData,e=t.srcPtr,i=t.bitPos,h=t.numBitsLUTQick,y=t.numBitsLUT,S=A.headerInfo.imageType===0?128:0,f,c,G,M=A.pixels.resultMask,w,D,l,F,k,R,U,L=0;i>0&&(e++,i=0);var J=n[e],q=A.encodeMode===1,O=new I(C*g),p=O,Y;if(g<2||q){for(Y=0;Y1&&(p=new I(O.buffer,C*Y,C),L=0),A.headerInfo.numValidPixel===B*r)for(R=0,F=0;F>>32-h,D=w,32-i>>64-i-h,D=w),o[D])c=o[D][1],i+=o[D][0];else for(w=J<>>32-y,D=w,32-i>>64-i-y,D=w),f=s,U=0;U>>y-U-1&1,f=l?f.right:f.left,!(f.left||f.right)){c=f.val,i=i+U+1;break}i>=32&&(i-=32,e++,J=n[e]),G=c-S,q?(k>0?G+=L:F>0?G+=p[R-B]:G+=L,G&=255,p[R]=G,L=G):p[R]=G}else for(R=0,F=0;F>>32-h,D=w,32-i>>64-i-h,D=w),o[D])c=o[D][1],i+=o[D][0];else for(w=J<>>32-y,D=w,32-i>>64-i-y,D=w),f=s,U=0;U>>y-U-1&1,f=l?f.right:f.left,!(f.left||f.right)){c=f.val,i=i+U+1;break}i>=32&&(i-=32,e++,J=n[e]),G=c-S,q?(k>0&&M[R-1]?G+=L:F>0&&M[R-B]?G+=p[R-B]:G+=L,G&=255,p[R]=G,L=G):p[R]=G}}else for(R=0,F=0;F>>32-h,D=w,32-i>>64-i-h,D=w),o[D])c=o[D][1],i+=o[D][0];else for(w=J<>>32-y,D=w,32-i>>64-i-y,D=w),f=s,U=0;U>>y-U-1&1,f=l?f.right:f.left,!(f.left||f.right)){c=f.val,i=i+U+1;break}i>=32&&(i-=32,e++,J=n[e]),G=c-S,p[R]=G}A.ptr=A.ptr+(e+1)*4+(i>0?4:0),A.pixels.resultPixels=O,g>1&&!a&&(A.pixels.resultPixels=d.swapDimensionOrder(O,C,g,I))},decodeBits:function(E,A,I,a,Q){{var g=A.headerInfo,r=g.fileVersion,B=0,C=E.byteLength-A.ptr>=5?5:E.byteLength-A.ptr,t=new DataView(E,A.ptr,C),o=t.getUint8(0);B++;var s=o>>6,n=s===0?4:3-s,e=(o&32)>0,i=o&31,h=0;if(n===1)h=t.getUint8(B),B++;else if(n===2)h=t.getUint16(B,!0),B+=2;else if(n===4)h=t.getUint32(B,!0),B+=4;else throw"Invalid valid pixel count type";var y=2*g.maxZError,S,f,c,G,M,w,D,l,F,k=g.numDims>1?g.maxValues[Q]:g.zMax;if(e){for(A.counter.lut++,l=t.getUint8(B),B++,G=Math.ceil((l-1)*i/8),M=Math.ceil(G/4),f=new ArrayBuffer(M*4),c=new Uint8Array(f),A.ptr+=B,c.set(new Uint8Array(E,A.ptr,G)),D=new Uint32Array(f),A.ptr+=G,F=0;l-1>>>F;)F++;G=Math.ceil(h*F/8),M=Math.ceil(G/4),f=new ArrayBuffer(M*4),c=new Uint8Array(f),c.set(new Uint8Array(E,A.ptr,G)),S=new Uint32Array(f),A.ptr+=G,r>=3?w=N.unstuffLUT2(D,i,l-1,a,y,k):w=N.unstuffLUT(D,i,l-1,a,y,k),r>=3?N.unstuff2(S,I,F,h,w):N.unstuff(S,I,F,h,w)}else A.counter.bitstuffer++,F=i,A.ptr+=B,F>0&&(G=Math.ceil(h*F/8),M=Math.ceil(G/4),f=new ArrayBuffer(M*4),c=new Uint8Array(f),c.set(new Uint8Array(E,A.ptr,G)),S=new Uint32Array(f),A.ptr+=G,r>=3?a==null?N.originalUnstuff2(S,I,F,h):N.unstuff2(S,I,F,h,!1,a,y,k):a==null?N.originalUnstuff(S,I,F,h):N.unstuff(S,I,F,h,!1,a,y,k))}},readTiles:function(E,A,I,a){var Q=A.headerInfo,g=Q.width,r=Q.height,B=g*r,C=Q.microBlockSize,t=Q.imageType,o=d.getDataTypeSize(t),s=Math.ceil(g/C),n=Math.ceil(r/C);A.pixels.numBlocksY=n,A.pixels.numBlocksX=s,A.pixels.ptr=0;var e=0,i=0,h=0,y=0,S=0,f=0,c=0,G=0,M=0,w=0,D=0,l=0,F=0,k=0,R=0,U=0,L,J,q,O,p,Y,j=new I(C*C),eA=r%C||C,aA=g%C||C,AA,T,_=Q.numDims,X,H=A.pixels.resultMask,x=A.pixels.resultPixels,oA=Q.fileVersion,CA=oA>=5?14:15,V,IA=Q.zMax,b;for(h=0;h1?(b=x,D=h*g*C+y*C,x=new I(A.pixels.resultPixels.buffer,B*X*o,B),IA=Q.maxValues[X]):b=null,c=E.byteLength-A.ptr,L=new DataView(E,A.ptr,Math.min(10,c)),J={},U=0,G=L.getUint8(0),U++,V=Q.fileVersion>=5?G&4:0,M=G>>6&255,w=G>>2&CA,w!==(y*C>>3&CA)||V&&X===0)throw"integrity issue";if(Y=G&3,Y>3)throw A.ptr+=U,"Invalid block encoding ("+Y+")";if(Y===2){if(V)if(H)for(e=0;e1&&!a&&(A.pixels.resultPixels=d.swapDimensionOrder(A.pixels.resultPixels,B,_,I))},formatFileInfo:function(E){return{fileIdentifierString:E.headerInfo.fileIdentifierString,fileVersion:E.headerInfo.fileVersion,imageType:E.headerInfo.imageType,height:E.headerInfo.height,width:E.headerInfo.width,numValidPixel:E.headerInfo.numValidPixel,microBlockSize:E.headerInfo.microBlockSize,blobSize:E.headerInfo.blobSize,maxZError:E.headerInfo.maxZError,pixelType:d.getPixelType(E.headerInfo.imageType),eofOffset:E.eofOffset,mask:E.mask?{numBytes:E.mask.numBytes}:null,pixels:{numBlocksX:E.pixels.numBlocksX,numBlocksY:E.pixels.numBlocksY,maxValue:E.headerInfo.zMax,minValue:E.headerInfo.zMin,noDataValue:E.noDataValue}}},constructConstantSurface:function(E,A){var I=E.headerInfo.zMax,a=E.headerInfo.zMin,Q=E.headerInfo.maxValues,g=E.headerInfo.numDims,r=E.headerInfo.height*E.headerInfo.width,B=0,C=0,t=0,o=E.pixels.resultMask,s=E.pixels.resultPixels;if(o)if(g>1){if(A)for(B=0;B1&&a!==I)if(A)for(B=0;B=-128&&A<=127;break;case 1:I=A>=0&&A<=255;break;case 2:I=A>=-32768&&A<=32767;break;case 3:I=A>=0&&A<=65536;break;case 4:I=A>=-2147483648&&A<=2147483647;break;case 5:I=A>=0&&A<=4294967296;break;case 6:I=A>=-34027999387901484e22&&A<=34027999387901484e22;break;case 7:I=A>=-17976931348623157e292&&A<=17976931348623157e292;break;default:I=!1}return I},getDataTypeSize:function(E){var A=0;switch(E){case 0:case 1:A=1;break;case 2:case 3:A=2;break;case 4:case 5:case 6:A=4;break;case 7:A=8;break;default:A=E}return A},getDataTypeUsed:function(E,A){var I=E;switch(E){case 2:case 4:I=E-A;break;case 3:case 5:I=E-2*A;break;case 6:A===0?I=E:A===1?I=2:I=1;break;case 7:A===0?I=E:I=E-2*A+1;break;default:I=E;break}return I},getOnePixel:function(E,A,I,a){var Q=0;switch(I){case 0:Q=a.getInt8(A);break;case 1:Q=a.getUint8(A);break;case 2:Q=a.getInt16(A,!0);break;case 3:Q=a.getUint16(A,!0);break;case 4:Q=a.getInt32(A,!0);break;case 5:Q=a.getUInt32(A,!0);break;case 6:Q=a.getFloat32(A,!0);break;case 7:Q=a.getFloat64(A,!0);break;default:throw"the decoder does not understand this pixel type"}return Q},swapDimensionOrder:function(E,A,I,a,Q){var g=0,r=0,B=0,C=0,t=E;if(I>1)if(t=new a(A*I),Q)for(g=0;g5)throw"unsupported lerc version 2."+r;d.readMask(E,Q),g.numValidPixel!==g.width*g.height&&!Q.pixels.resultMask&&(Q.pixels.resultMask=A.maskData);var C=g.width*g.height;Q.pixels.resultPixels=new B(C*g.numDims),Q.counter={onesweep:0,uncompressed:0,lut:0,bitstuffer:0,constant:0,constantoffset:0};var t=!A.returnPixelInterleavedDims;if(g.numValidPixel!==0)if(g.zMax===g.zMin)d.constructConstantSurface(Q,t);else if(r>=4&&d.checkMinMaxRanges(E,Q))d.constructConstantSurface(Q,t);else{var o=new DataView(E,Q.ptr,2),s=o.getUint8(0);if(Q.ptr++,s)d.readDataOneSweep(E,Q,B,t);else if(r>1&&g.imageType<=1&&Math.abs(g.maxZError-.5)<1e-5){var n=o.getUint8(1);if(Q.ptr++,Q.encodeMode=n,n>2||r<4&&n>1)throw"Invalid Huffman flag "+n;n?d.readHuffman(E,Q,B,t):d.readTiles(E,Q,B,t)}else d.readTiles(E,Q,B,t)}Q.eofOffset=Q.ptr;var e;A.inputOffset?(e=Q.headerInfo.blobSize+A.inputOffset-Q.ptr,Math.abs(e)>=1&&(Q.eofOffset=A.inputOffset+Q.headerInfo.blobSize)):(e=Q.headerInfo.blobSize-Q.ptr,Math.abs(e)>=1&&(Q.eofOffset=Q.headerInfo.blobSize));var i={width:g.width,height:g.height,pixelData:Q.pixels.resultPixels,minValue:g.zMin,maxValue:g.zMax,validPixelCount:g.numValidPixel,dimCount:g.numDims,dimStats:{minValues:g.minValues,maxValues:g.maxValues},maskData:Q.pixels.resultMask};if(Q.pixels.resultMask&&d.isValidPixelValue(g.imageType,I)){var h=Q.pixels.resultMask;for(a=0;a1&&(C&&r.push(C),s.fileInfo.mask&&s.fileInfo.mask.numBytes>0&&o++),a++,t.pixels.push(s.pixelData),t.statistics.push({minValue:s.minValue,maxValue:s.maxValue,noDataValue:s.noDataValue,dimStats:s.dimStats})}var n,e,i;if(I>1&&o>1){for(i=t.width*t.height,t.bandMasks=r,C=new Uint8Array(i),C.set(r[0]),n=1;nu.arrayBuffer()).then(u=>WebAssembly.instantiate(u,BA)).then(this._init):$=WebAssembly.instantiate(Buffer.from(EA,"base64"),BA).then(this._init),$)}_init(u){K=u.instance,BA.env.emscripten_notify_memory_growth(0)}decode(u,P=0){if(!K)throw new Error("ZSTDDecoder: Await .init() before decoding.");const Z=u.byteLength,v=K.exports.malloc(Z);QA.set(u,v),P=P||Number(K.exports.ZSTD_findDecompressedSize(v,Z));const N=K.exports.malloc(P),d=K.exports.ZSTD_decompress(N,P,v,Z),m=QA.slice(N,N+d);return K.exports.free(v),K.exports.free(N),m}}const EA="AGFzbQEAAAABpQEVYAF/AX9gAn9/AGADf39/AX9gBX9/f39/AX9gAX8AYAJ/fwF/YAR/f39/AX9gA39/fwBgBn9/f39/fwF/YAd/f39/f39/AX9gAn9/AX5gAn5+AX5gAABgBX9/f39/AGAGf39/f39/AGAIf39/f39/f38AYAl/f39/f39/f38AYAABf2AIf39/f39/f38Bf2ANf39/f39/f39/f39/fwF/YAF/AX4CJwEDZW52H2Vtc2NyaXB0ZW5fbm90aWZ5X21lbW9yeV9ncm93dGgABANpaAEFAAAFAgEFCwACAQABAgIFBQcAAwABDgsBAQcAEhMHAAUBDAQEAAANBwQCAgYCBAgDAwMDBgEACQkHBgICAAYGAgQUBwYGAwIGAAMCAQgBBwUGCgoEEQAEBAEIAwgDBQgDEA8IAAcABAUBcAECAgUEAQCAAgYJAX8BQaCgwAILB2AHBm1lbW9yeQIABm1hbGxvYwAoBGZyZWUAJgxaU1REX2lzRXJyb3IAaBlaU1REX2ZpbmREZWNvbXByZXNzZWRTaXplAFQPWlNURF9kZWNvbXByZXNzAEoGX3N0YXJ0ACQJBwEAQQELASQKussBaA8AIAAgACgCBCABajYCBAsZACAAKAIAIAAoAgRBH3F0QQAgAWtBH3F2CwgAIABBiH9LC34BBH9BAyEBIAAoAgQiA0EgTQRAIAAoAggiASAAKAIQTwRAIAAQDQ8LIAAoAgwiAiABRgRAQQFBAiADQSBJGw8LIAAgASABIAJrIANBA3YiBCABIARrIAJJIgEbIgJrIgQ2AgggACADIAJBA3RrNgIEIAAgBCgAADYCAAsgAQsUAQF/IAAgARACIQIgACABEAEgAgv3AQECfyACRQRAIABCADcCACAAQQA2AhAgAEIANwIIQbh/DwsgACABNgIMIAAgAUEEajYCECACQQRPBEAgACABIAJqIgFBfGoiAzYCCCAAIAMoAAA2AgAgAUF/ai0AACIBBEAgAEEIIAEQFGs2AgQgAg8LIABBADYCBEF/DwsgACABNgIIIAAgAS0AACIDNgIAIAJBfmoiBEEBTQRAIARBAWtFBEAgACABLQACQRB0IANyIgM2AgALIAAgAS0AAUEIdCADajYCAAsgASACakF/ai0AACIBRQRAIABBADYCBEFsDwsgAEEoIAEQFCACQQN0ams2AgQgAgsWACAAIAEpAAA3AAAgACABKQAINwAICy8BAX8gAUECdEGgHWooAgAgACgCAEEgIAEgACgCBGprQR9xdnEhAiAAIAEQASACCyEAIAFCz9bTvtLHq9lCfiAAfEIfiUKHla+vmLbem55/fgsdAQF/IAAoAgggACgCDEYEfyAAKAIEQSBGBUEACwuCBAEDfyACQYDAAE8EQCAAIAEgAhBnIAAPCyAAIAJqIQMCQCAAIAFzQQNxRQRAAkAgAkEBSARAIAAhAgwBCyAAQQNxRQRAIAAhAgwBCyAAIQIDQCACIAEtAAA6AAAgAUEBaiEBIAJBAWoiAiADTw0BIAJBA3ENAAsLAkAgA0F8cSIEQcAASQ0AIAIgBEFAaiIFSw0AA0AgAiABKAIANgIAIAIgASgCBDYCBCACIAEoAgg2AgggAiABKAIMNgIMIAIgASgCEDYCECACIAEoAhQ2AhQgAiABKAIYNgIYIAIgASgCHDYCHCACIAEoAiA2AiAgAiABKAIkNgIkIAIgASgCKDYCKCACIAEoAiw2AiwgAiABKAIwNgIwIAIgASgCNDYCNCACIAEoAjg2AjggAiABKAI8NgI8IAFBQGshASACQUBrIgIgBU0NAAsLIAIgBE8NAQNAIAIgASgCADYCACABQQRqIQEgAkEEaiICIARJDQALDAELIANBBEkEQCAAIQIMAQsgA0F8aiIEIABJBEAgACECDAELIAAhAgNAIAIgAS0AADoAACACIAEtAAE6AAEgAiABLQACOgACIAIgAS0AAzoAAyABQQRqIQEgAkEEaiICIARNDQALCyACIANJBEADQCACIAEtAAA6AAAgAUEBaiEBIAJBAWoiAiADRw0ACwsgAAsMACAAIAEpAAA3AAALQQECfyAAKAIIIgEgACgCEEkEQEEDDwsgACAAKAIEIgJBB3E2AgQgACABIAJBA3ZrIgE2AgggACABKAAANgIAQQALDAAgACABKAIANgAAC/cCAQJ/AkAgACABRg0AAkAgASACaiAASwRAIAAgAmoiBCABSw0BCyAAIAEgAhALDwsgACABc0EDcSEDAkACQCAAIAFJBEAgAwRAIAAhAwwDCyAAQQNxRQRAIAAhAwwCCyAAIQMDQCACRQ0EIAMgAS0AADoAACABQQFqIQEgAkF/aiECIANBAWoiA0EDcQ0ACwwBCwJAIAMNACAEQQNxBEADQCACRQ0FIAAgAkF/aiICaiIDIAEgAmotAAA6AAAgA0EDcQ0ACwsgAkEDTQ0AA0AgACACQXxqIgJqIAEgAmooAgA2AgAgAkEDSw0ACwsgAkUNAgNAIAAgAkF/aiICaiABIAJqLQAAOgAAIAINAAsMAgsgAkEDTQ0AIAIhBANAIAMgASgCADYCACABQQRqIQEgA0EEaiEDIARBfGoiBEEDSw0ACyACQQNxIQILIAJFDQADQCADIAEtAAA6AAAgA0EBaiEDIAFBAWohASACQX9qIgINAAsLIAAL8wICAn8BfgJAIAJFDQAgACACaiIDQX9qIAE6AAAgACABOgAAIAJBA0kNACADQX5qIAE6AAAgACABOgABIANBfWogAToAACAAIAE6AAIgAkEHSQ0AIANBfGogAToAACAAIAE6AAMgAkEJSQ0AIABBACAAa0EDcSIEaiIDIAFB/wFxQYGChAhsIgE2AgAgAyACIARrQXxxIgRqIgJBfGogATYCACAEQQlJDQAgAyABNgIIIAMgATYCBCACQXhqIAE2AgAgAkF0aiABNgIAIARBGUkNACADIAE2AhggAyABNgIUIAMgATYCECADIAE2AgwgAkFwaiABNgIAIAJBbGogATYCACACQWhqIAE2AgAgAkFkaiABNgIAIAQgA0EEcUEYciIEayICQSBJDQAgAa0iBUIghiAFhCEFIAMgBGohAQNAIAEgBTcDGCABIAU3AxAgASAFNwMIIAEgBTcDACABQSBqIQEgAkFgaiICQR9LDQALCyAACy8BAn8gACgCBCAAKAIAQQJ0aiICLQACIQMgACACLwEAIAEgAi0AAxAIajYCACADCy8BAn8gACgCBCAAKAIAQQJ0aiICLQACIQMgACACLwEAIAEgAi0AAxAFajYCACADCx8AIAAgASACKAIEEAg2AgAgARAEGiAAIAJBCGo2AgQLCAAgAGdBH3MLugUBDX8jAEEQayIKJAACfyAEQQNNBEAgCkEANgIMIApBDGogAyAEEAsaIAAgASACIApBDGpBBBAVIgBBbCAAEAMbIAAgACAESxsMAQsgAEEAIAEoAgBBAXRBAmoQECENQVQgAygAACIGQQ9xIgBBCksNABogAiAAQQVqNgIAIAMgBGoiAkF8aiEMIAJBeWohDiACQXtqIRAgAEEGaiELQQQhBSAGQQR2IQRBICAAdCIAQQFyIQkgASgCACEPQQAhAiADIQYCQANAIAlBAkggAiAPS3JFBEAgAiEHAkAgCARAA0AgBEH//wNxQf//A0YEQCAHQRhqIQcgBiAQSQR/IAZBAmoiBigAACAFdgUgBUEQaiEFIARBEHYLIQQMAQsLA0AgBEEDcSIIQQNGBEAgBUECaiEFIARBAnYhBCAHQQNqIQcMAQsLIAcgCGoiByAPSw0EIAVBAmohBQNAIAIgB0kEQCANIAJBAXRqQQA7AQAgAkEBaiECDAELCyAGIA5LQQAgBiAFQQN1aiIHIAxLG0UEQCAHKAAAIAVBB3EiBXYhBAwCCyAEQQJ2IQQLIAYhBwsCfyALQX9qIAQgAEF/anEiBiAAQQF0QX9qIgggCWsiEUkNABogBCAIcSIEQQAgESAEIABIG2shBiALCyEIIA0gAkEBdGogBkF/aiIEOwEAIAlBASAGayAEIAZBAUgbayEJA0AgCSAASARAIABBAXUhACALQX9qIQsMAQsLAn8gByAOS0EAIAcgBSAIaiIFQQN1aiIGIAxLG0UEQCAFQQdxDAELIAUgDCIGIAdrQQN0awshBSACQQFqIQIgBEUhCCAGKAAAIAVBH3F2IQQMAQsLQWwgCUEBRyAFQSBKcg0BGiABIAJBf2o2AgAgBiAFQQdqQQN1aiADawwBC0FQCyEAIApBEGokACAACwkAQQFBBSAAGwsMACAAIAEoAAA2AAALqgMBCn8jAEHwAGsiCiQAIAJBAWohDiAAQQhqIQtBgIAEIAVBf2p0QRB1IQxBACECQQEhBkEBIAV0IglBf2oiDyEIA0AgAiAORkUEQAJAIAEgAkEBdCINai8BACIHQf//A0YEQCALIAhBA3RqIAI2AgQgCEF/aiEIQQEhBwwBCyAGQQAgDCAHQRB0QRB1ShshBgsgCiANaiAHOwEAIAJBAWohAgwBCwsgACAFNgIEIAAgBjYCACAJQQN2IAlBAXZqQQNqIQxBACEAQQAhBkEAIQIDQCAGIA5GBEADQAJAIAAgCUYNACAKIAsgAEEDdGoiASgCBCIGQQF0aiICIAIvAQAiAkEBajsBACABIAUgAhAUayIIOgADIAEgAiAIQf8BcXQgCWs7AQAgASAEIAZBAnQiAmooAgA6AAIgASACIANqKAIANgIEIABBAWohAAwBCwsFIAEgBkEBdGouAQAhDUEAIQcDQCAHIA1ORQRAIAsgAkEDdGogBjYCBANAIAIgDGogD3EiAiAISw0ACyAHQQFqIQcMAQsLIAZBAWohBgwBCwsgCkHwAGokAAsjAEIAIAEQCSAAhUKHla+vmLbem55/fkLj3MqV/M7y9YV/fAsQACAAQn43AwggACABNgIACyQBAX8gAARAIAEoAgQiAgRAIAEoAgggACACEQEADwsgABAmCwsfACAAIAEgAi8BABAINgIAIAEQBBogACACQQRqNgIEC0oBAX9BoCAoAgAiASAAaiIAQX9MBEBBiCBBMDYCAEF/DwsCQCAAPwBBEHRNDQAgABBmDQBBiCBBMDYCAEF/DwtBoCAgADYCACABC9cBAQh/Qbp/IQoCQCACKAIEIgggAigCACIJaiIOIAEgAGtLDQBBbCEKIAkgBCADKAIAIgtrSw0AIAAgCWoiBCACKAIIIgxrIQ0gACABQWBqIg8gCyAJQQAQKSADIAkgC2o2AgACQAJAIAwgBCAFa00EQCANIQUMAQsgDCAEIAZrSw0CIAcgDSAFayIAaiIBIAhqIAdNBEAgBCABIAgQDxoMAgsgBCABQQAgAGsQDyEBIAIgACAIaiIINgIEIAEgAGshBAsgBCAPIAUgCEEBECkLIA4hCgsgCgubAgEBfyMAQYABayINJAAgDSADNgJ8AkAgAkEDSwRAQX8hCQwBCwJAAkACQAJAIAJBAWsOAwADAgELIAZFBEBBuH8hCQwEC0FsIQkgBS0AACICIANLDQMgACAHIAJBAnQiAmooAgAgAiAIaigCABA7IAEgADYCAEEBIQkMAwsgASAJNgIAQQAhCQwCCyAKRQRAQWwhCQwCC0EAIQkgC0UgDEEZSHINAUEIIAR0QQhqIQBBACECA0AgAiAATw0CIAJBQGshAgwAAAsAC0FsIQkgDSANQfwAaiANQfgAaiAFIAYQFSICEAMNACANKAJ4IgMgBEsNACAAIA0gDSgCfCAHIAggAxAYIAEgADYCACACIQkLIA1BgAFqJAAgCQsLACAAIAEgAhALGgsQACAALwAAIAAtAAJBEHRyCy8AAn9BuH8gAUEISQ0AGkFyIAAoAAQiAEF3Sw0AGkG4fyAAQQhqIgAgACABSxsLCwkAIAAgATsAAAsDAAELigYBBX8gACAAKAIAIgVBfnE2AgBBACAAIAVBAXZqQYQgKAIAIgQgAEYbIQECQAJAIAAoAgQiAkUNACACKAIAIgNBAXENACACQQhqIgUgA0EBdkF4aiIDQQggA0EISxtnQR9zQQJ0QYAfaiIDKAIARgRAIAMgAigCDDYCAAsgAigCCCIDBEAgAyACKAIMNgIECyACKAIMIgMEQCADIAIoAgg2AgALIAIgAigCACAAKAIAQX5xajYCAEGEICEAAkACQCABRQ0AIAEgAjYCBCABKAIAIgNBAXENASADQQF2QXhqIgNBCCADQQhLG2dBH3NBAnRBgB9qIgMoAgAgAUEIakYEQCADIAEoAgw2AgALIAEoAggiAwRAIAMgASgCDDYCBAsgASgCDCIDBEAgAyABKAIINgIAQYQgKAIAIQQLIAIgAigCACABKAIAQX5xajYCACABIARGDQAgASABKAIAQQF2akEEaiEACyAAIAI2AgALIAIoAgBBAXZBeGoiAEEIIABBCEsbZ0Efc0ECdEGAH2oiASgCACEAIAEgBTYCACACIAA2AgwgAkEANgIIIABFDQEgACAFNgIADwsCQCABRQ0AIAEoAgAiAkEBcQ0AIAJBAXZBeGoiAkEIIAJBCEsbZ0Efc0ECdEGAH2oiAigCACABQQhqRgRAIAIgASgCDDYCAAsgASgCCCICBEAgAiABKAIMNgIECyABKAIMIgIEQCACIAEoAgg2AgBBhCAoAgAhBAsgACAAKAIAIAEoAgBBfnFqIgI2AgACQCABIARHBEAgASABKAIAQQF2aiAANgIEIAAoAgAhAgwBC0GEICAANgIACyACQQF2QXhqIgFBCCABQQhLG2dBH3NBAnRBgB9qIgIoAgAhASACIABBCGoiAjYCACAAIAE2AgwgAEEANgIIIAFFDQEgASACNgIADwsgBUEBdkF4aiIBQQggAUEISxtnQR9zQQJ0QYAfaiICKAIAIQEgAiAAQQhqIgI2AgAgACABNgIMIABBADYCCCABRQ0AIAEgAjYCAAsLDgAgAARAIABBeGoQJQsLgAIBA38CQCAAQQ9qQXhxQYQgKAIAKAIAQQF2ayICEB1Bf0YNAAJAQYQgKAIAIgAoAgAiAUEBcQ0AIAFBAXZBeGoiAUEIIAFBCEsbZ0Efc0ECdEGAH2oiASgCACAAQQhqRgRAIAEgACgCDDYCAAsgACgCCCIBBEAgASAAKAIMNgIECyAAKAIMIgFFDQAgASAAKAIINgIAC0EBIQEgACAAKAIAIAJBAXRqIgI2AgAgAkEBcQ0AIAJBAXZBeGoiAkEIIAJBCEsbZ0Efc0ECdEGAH2oiAygCACECIAMgAEEIaiIDNgIAIAAgAjYCDCAAQQA2AgggAkUNACACIAM2AgALIAELtwIBA38CQAJAIABBASAAGyICEDgiAA0AAkACQEGEICgCACIARQ0AIAAoAgAiA0EBcQ0AIAAgA0EBcjYCACADQQF2QXhqIgFBCCABQQhLG2dBH3NBAnRBgB9qIgEoAgAgAEEIakYEQCABIAAoAgw2AgALIAAoAggiAQRAIAEgACgCDDYCBAsgACgCDCIBBEAgASAAKAIINgIACyACECchAkEAIQFBhCAoAgAhACACDQEgACAAKAIAQX5xNgIAQQAPCyACQQ9qQXhxIgMQHSICQX9GDQIgAkEHakF4cSIAIAJHBEAgACACaxAdQX9GDQMLAkBBhCAoAgAiAUUEQEGAICAANgIADAELIAAgATYCBAtBhCAgADYCACAAIANBAXRBAXI2AgAMAQsgAEUNAQsgAEEIaiEBCyABC7kDAQJ/IAAgA2ohBQJAIANBB0wEQANAIAAgBU8NAiAAIAItAAA6AAAgAEEBaiEAIAJBAWohAgwAAAsACyAEQQFGBEACQCAAIAJrIgZBB00EQCAAIAItAAA6AAAgACACLQABOgABIAAgAi0AAjoAAiAAIAItAAM6AAMgAEEEaiACIAZBAnQiBkHAHmooAgBqIgIQFyACIAZB4B5qKAIAayECDAELIAAgAhAMCyACQQhqIQIgAEEIaiEACwJAAkACQAJAIAUgAU0EQCAAIANqIQEgBEEBRyAAIAJrQQ9Kcg0BA0AgACACEAwgAkEIaiECIABBCGoiACABSQ0ACwwFCyAAIAFLBEAgACEBDAQLIARBAUcgACACa0EPSnINASAAIQMgAiEEA0AgAyAEEAwgBEEIaiEEIANBCGoiAyABSQ0ACwwCCwNAIAAgAhAHIAJBEGohAiAAQRBqIgAgAUkNAAsMAwsgACEDIAIhBANAIAMgBBAHIARBEGohBCADQRBqIgMgAUkNAAsLIAIgASAAa2ohAgsDQCABIAVPDQEgASACLQAAOgAAIAFBAWohASACQQFqIQIMAAALAAsLQQECfyAAIAAoArjgASIDNgLE4AEgACgCvOABIQQgACABNgK84AEgACABIAJqNgK44AEgACABIAQgA2tqNgLA4AELpgEBAX8gACAAKALs4QEQFjYCyOABIABCADcD+OABIABCADcDuOABIABBwOABakIANwMAIABBqNAAaiIBQYyAgOAANgIAIABBADYCmOIBIABCADcDiOEBIABCAzcDgOEBIABBrNABakHgEikCADcCACAAQbTQAWpB6BIoAgA2AgAgACABNgIMIAAgAEGYIGo2AgggACAAQaAwajYCBCAAIABBEGo2AgALYQEBf0G4fyEDAkAgAUEDSQ0AIAIgABAhIgFBA3YiADYCCCACIAFBAXE2AgQgAiABQQF2QQNxIgM2AgACQCADQX9qIgFBAksNAAJAIAFBAWsOAgEAAgtBbA8LIAAhAwsgAwsMACAAIAEgAkEAEC4LiAQCA38CfiADEBYhBCAAQQBBKBAQIQAgBCACSwRAIAQPCyABRQRAQX8PCwJAAkAgA0EBRg0AIAEoAAAiBkGo6r5pRg0AQXYhAyAGQXBxQdDUtMIBRw0BQQghAyACQQhJDQEgAEEAQSgQECEAIAEoAAQhASAAQQE2AhQgACABrTcDAEEADwsgASACIAMQLyIDIAJLDQAgACADNgIYQXIhAyABIARqIgVBf2otAAAiAkEIcQ0AIAJBIHEiBkUEQEFwIQMgBS0AACIFQacBSw0BIAVBB3GtQgEgBUEDdkEKaq2GIgdCA4h+IAd8IQggBEEBaiEECyACQQZ2IQMgAkECdiEFAkAgAkEDcUF/aiICQQJLBEBBACECDAELAkACQAJAIAJBAWsOAgECAAsgASAEai0AACECIARBAWohBAwCCyABIARqLwAAIQIgBEECaiEEDAELIAEgBGooAAAhAiAEQQRqIQQLIAVBAXEhBQJ+AkACQAJAIANBf2oiA0ECTQRAIANBAWsOAgIDAQtCfyAGRQ0DGiABIARqMQAADAMLIAEgBGovAACtQoACfAwCCyABIARqKAAArQwBCyABIARqKQAACyEHIAAgBTYCICAAIAI2AhwgACAHNwMAQQAhAyAAQQA2AhQgACAHIAggBhsiBzcDCCAAIAdCgIAIIAdCgIAIVBs+AhALIAMLWwEBf0G4fyEDIAIQFiICIAFNBH8gACACakF/ai0AACIAQQNxQQJ0QaAeaigCACACaiAAQQZ2IgFBAnRBsB5qKAIAaiAAQSBxIgBFaiABRSAAQQV2cWoFQbh/CwsdACAAKAKQ4gEQWiAAQQA2AqDiASAAQgA3A5DiAQu1AwEFfyMAQZACayIKJABBuH8hBgJAIAVFDQAgBCwAACIIQf8BcSEHAkAgCEF/TARAIAdBgn9qQQF2IgggBU8NAkFsIQYgB0GBf2oiBUGAAk8NAiAEQQFqIQdBACEGA0AgBiAFTwRAIAUhBiAIIQcMAwUgACAGaiAHIAZBAXZqIgQtAABBBHY6AAAgACAGQQFyaiAELQAAQQ9xOgAAIAZBAmohBgwBCwAACwALIAcgBU8NASAAIARBAWogByAKEFMiBhADDQELIAYhBEEAIQYgAUEAQTQQECEJQQAhBQNAIAQgBkcEQCAAIAZqIggtAAAiAUELSwRAQWwhBgwDBSAJIAFBAnRqIgEgASgCAEEBajYCACAGQQFqIQZBASAILQAAdEEBdSAFaiEFDAILAAsLQWwhBiAFRQ0AIAUQFEEBaiIBQQxLDQAgAyABNgIAQQFBASABdCAFayIDEBQiAXQgA0cNACAAIARqIAFBAWoiADoAACAJIABBAnRqIgAgACgCAEEBajYCACAJKAIEIgBBAkkgAEEBcXINACACIARBAWo2AgAgB0EBaiEGCyAKQZACaiQAIAYLxhEBDH8jAEHwAGsiBSQAQWwhCwJAIANBCkkNACACLwAAIQogAi8AAiEJIAIvAAQhByAFQQhqIAQQDgJAIAMgByAJIApqakEGaiIMSQ0AIAUtAAohCCAFQdgAaiACQQZqIgIgChAGIgsQAw0BIAVBQGsgAiAKaiICIAkQBiILEAMNASAFQShqIAIgCWoiAiAHEAYiCxADDQEgBUEQaiACIAdqIAMgDGsQBiILEAMNASAAIAFqIg9BfWohECAEQQRqIQZBASELIAAgAUEDakECdiIDaiIMIANqIgIgA2oiDiEDIAIhBCAMIQcDQCALIAMgEElxBEAgACAGIAVB2ABqIAgQAkECdGoiCS8BADsAACAFQdgAaiAJLQACEAEgCS0AAyELIAcgBiAFQUBrIAgQAkECdGoiCS8BADsAACAFQUBrIAktAAIQASAJLQADIQogBCAGIAVBKGogCBACQQJ0aiIJLwEAOwAAIAVBKGogCS0AAhABIAktAAMhCSADIAYgBUEQaiAIEAJBAnRqIg0vAQA7AAAgBUEQaiANLQACEAEgDS0AAyENIAAgC2oiCyAGIAVB2ABqIAgQAkECdGoiAC8BADsAACAFQdgAaiAALQACEAEgAC0AAyEAIAcgCmoiCiAGIAVBQGsgCBACQQJ0aiIHLwEAOwAAIAVBQGsgBy0AAhABIActAAMhByAEIAlqIgkgBiAFQShqIAgQAkECdGoiBC8BADsAACAFQShqIAQtAAIQASAELQADIQQgAyANaiIDIAYgBUEQaiAIEAJBAnRqIg0vAQA7AAAgBUEQaiANLQACEAEgACALaiEAIAcgCmohByAEIAlqIQQgAyANLQADaiEDIAVB2ABqEA0gBUFAaxANciAFQShqEA1yIAVBEGoQDXJFIQsMAQsLIAQgDksgByACS3INAEFsIQsgACAMSw0BIAxBfWohCQNAQQAgACAJSSAFQdgAahAEGwRAIAAgBiAFQdgAaiAIEAJBAnRqIgovAQA7AAAgBUHYAGogCi0AAhABIAAgCi0AA2oiACAGIAVB2ABqIAgQAkECdGoiCi8BADsAACAFQdgAaiAKLQACEAEgACAKLQADaiEADAEFIAxBfmohCgNAIAVB2ABqEAQgACAKS3JFBEAgACAGIAVB2ABqIAgQAkECdGoiCS8BADsAACAFQdgAaiAJLQACEAEgACAJLQADaiEADAELCwNAIAAgCk0EQCAAIAYgBUHYAGogCBACQQJ0aiIJLwEAOwAAIAVB2ABqIAktAAIQASAAIAktAANqIQAMAQsLAkAgACAMTw0AIAAgBiAFQdgAaiAIEAIiAEECdGoiDC0AADoAACAMLQADQQFGBEAgBUHYAGogDC0AAhABDAELIAUoAlxBH0sNACAFQdgAaiAGIABBAnRqLQACEAEgBSgCXEEhSQ0AIAVBIDYCXAsgAkF9aiEMA0BBACAHIAxJIAVBQGsQBBsEQCAHIAYgBUFAayAIEAJBAnRqIgAvAQA7AAAgBUFAayAALQACEAEgByAALQADaiIAIAYgBUFAayAIEAJBAnRqIgcvAQA7AAAgBUFAayAHLQACEAEgACAHLQADaiEHDAEFIAJBfmohDANAIAVBQGsQBCAHIAxLckUEQCAHIAYgBUFAayAIEAJBAnRqIgAvAQA7AAAgBUFAayAALQACEAEgByAALQADaiEHDAELCwNAIAcgDE0EQCAHIAYgBUFAayAIEAJBAnRqIgAvAQA7AAAgBUFAayAALQACEAEgByAALQADaiEHDAELCwJAIAcgAk8NACAHIAYgBUFAayAIEAIiAEECdGoiAi0AADoAACACLQADQQFGBEAgBUFAayACLQACEAEMAQsgBSgCREEfSw0AIAVBQGsgBiAAQQJ0ai0AAhABIAUoAkRBIUkNACAFQSA2AkQLIA5BfWohAgNAQQAgBCACSSAFQShqEAQbBEAgBCAGIAVBKGogCBACQQJ0aiIALwEAOwAAIAVBKGogAC0AAhABIAQgAC0AA2oiACAGIAVBKGogCBACQQJ0aiIELwEAOwAAIAVBKGogBC0AAhABIAAgBC0AA2ohBAwBBSAOQX5qIQIDQCAFQShqEAQgBCACS3JFBEAgBCAGIAVBKGogCBACQQJ0aiIALwEAOwAAIAVBKGogAC0AAhABIAQgAC0AA2ohBAwBCwsDQCAEIAJNBEAgBCAGIAVBKGogCBACQQJ0aiIALwEAOwAAIAVBKGogAC0AAhABIAQgAC0AA2ohBAwBCwsCQCAEIA5PDQAgBCAGIAVBKGogCBACIgBBAnRqIgItAAA6AAAgAi0AA0EBRgRAIAVBKGogAi0AAhABDAELIAUoAixBH0sNACAFQShqIAYgAEECdGotAAIQASAFKAIsQSFJDQAgBUEgNgIsCwNAQQAgAyAQSSAFQRBqEAQbBEAgAyAGIAVBEGogCBACQQJ0aiIALwEAOwAAIAVBEGogAC0AAhABIAMgAC0AA2oiACAGIAVBEGogCBACQQJ0aiICLwEAOwAAIAVBEGogAi0AAhABIAAgAi0AA2ohAwwBBSAPQX5qIQIDQCAFQRBqEAQgAyACS3JFBEAgAyAGIAVBEGogCBACQQJ0aiIALwEAOwAAIAVBEGogAC0AAhABIAMgAC0AA2ohAwwBCwsDQCADIAJNBEAgAyAGIAVBEGogCBACQQJ0aiIALwEAOwAAIAVBEGogAC0AAhABIAMgAC0AA2ohAwwBCwsCQCADIA9PDQAgAyAGIAVBEGogCBACIgBBAnRqIgItAAA6AAAgAi0AA0EBRgRAIAVBEGogAi0AAhABDAELIAUoAhRBH0sNACAFQRBqIAYgAEECdGotAAIQASAFKAIUQSFJDQAgBUEgNgIUCyABQWwgBUHYAGoQCiAFQUBrEApxIAVBKGoQCnEgBUEQahAKcRshCwwJCwAACwALAAALAAsAAAsACwAACwALQWwhCwsgBUHwAGokACALC7UEAQ5/IwBBEGsiBiQAIAZBBGogABAOQVQhBQJAIARB3AtJDQAgBi0ABCEHIANB8ARqQQBB7AAQECEIIAdBDEsNACADQdwJaiIJIAggBkEIaiAGQQxqIAEgAhAxIhAQA0UEQCAGKAIMIgQgB0sNASADQdwFaiEPIANBpAVqIREgAEEEaiESIANBqAVqIQEgBCEFA0AgBSICQX9qIQUgCCACQQJ0aigCAEUNAAsgAkEBaiEOQQEhBQNAIAUgDk9FBEAgCCAFQQJ0IgtqKAIAIQwgASALaiAKNgIAIAVBAWohBSAKIAxqIQoMAQsLIAEgCjYCAEEAIQUgBigCCCELA0AgBSALRkUEQCABIAUgCWotAAAiDEECdGoiDSANKAIAIg1BAWo2AgAgDyANQQF0aiINIAw6AAEgDSAFOgAAIAVBAWohBQwBCwtBACEBIANBADYCqAUgBEF/cyAHaiEJQQEhBQNAIAUgDk9FBEAgCCAFQQJ0IgtqKAIAIQwgAyALaiABNgIAIAwgBSAJanQgAWohASAFQQFqIQUMAQsLIAcgBEEBaiIBIAJrIgRrQQFqIQgDQEEBIQUgBCAIT0UEQANAIAUgDk9FBEAgBUECdCIJIAMgBEE0bGpqIAMgCWooAgAgBHY2AgAgBUEBaiEFDAELCyAEQQFqIQQMAQsLIBIgByAPIAogESADIAIgARBkIAZBAToABSAGIAc6AAYgACAGKAIENgIACyAQIQULIAZBEGokACAFC8ENAQt/IwBB8ABrIgUkAEFsIQkCQCADQQpJDQAgAi8AACEKIAIvAAIhDCACLwAEIQYgBUEIaiAEEA4CQCADIAYgCiAMampBBmoiDUkNACAFLQAKIQcgBUHYAGogAkEGaiICIAoQBiIJEAMNASAFQUBrIAIgCmoiAiAMEAYiCRADDQEgBUEoaiACIAxqIgIgBhAGIgkQAw0BIAVBEGogAiAGaiADIA1rEAYiCRADDQEgACABaiIOQX1qIQ8gBEEEaiEGQQEhCSAAIAFBA2pBAnYiAmoiCiACaiIMIAJqIg0hAyAMIQQgCiECA0AgCSADIA9JcQRAIAYgBUHYAGogBxACQQF0aiIILQAAIQsgBUHYAGogCC0AARABIAAgCzoAACAGIAVBQGsgBxACQQF0aiIILQAAIQsgBUFAayAILQABEAEgAiALOgAAIAYgBUEoaiAHEAJBAXRqIggtAAAhCyAFQShqIAgtAAEQASAEIAs6AAAgBiAFQRBqIAcQAkEBdGoiCC0AACELIAVBEGogCC0AARABIAMgCzoAACAGIAVB2ABqIAcQAkEBdGoiCC0AACELIAVB2ABqIAgtAAEQASAAIAs6AAEgBiAFQUBrIAcQAkEBdGoiCC0AACELIAVBQGsgCC0AARABIAIgCzoAASAGIAVBKGogBxACQQF0aiIILQAAIQsgBUEoaiAILQABEAEgBCALOgABIAYgBUEQaiAHEAJBAXRqIggtAAAhCyAFQRBqIAgtAAEQASADIAs6AAEgA0ECaiEDIARBAmohBCACQQJqIQIgAEECaiEAIAkgBUHYAGoQDUVxIAVBQGsQDUVxIAVBKGoQDUVxIAVBEGoQDUVxIQkMAQsLIAQgDUsgAiAMS3INAEFsIQkgACAKSw0BIApBfWohCQNAIAVB2ABqEAQgACAJT3JFBEAgBiAFQdgAaiAHEAJBAXRqIggtAAAhCyAFQdgAaiAILQABEAEgACALOgAAIAYgBUHYAGogBxACQQF0aiIILQAAIQsgBUHYAGogCC0AARABIAAgCzoAASAAQQJqIQAMAQsLA0AgBUHYAGoQBCAAIApPckUEQCAGIAVB2ABqIAcQAkEBdGoiCS0AACEIIAVB2ABqIAktAAEQASAAIAg6AAAgAEEBaiEADAELCwNAIAAgCkkEQCAGIAVB2ABqIAcQAkEBdGoiCS0AACEIIAVB2ABqIAktAAEQASAAIAg6AAAgAEEBaiEADAELCyAMQX1qIQADQCAFQUBrEAQgAiAAT3JFBEAgBiAFQUBrIAcQAkEBdGoiCi0AACEJIAVBQGsgCi0AARABIAIgCToAACAGIAVBQGsgBxACQQF0aiIKLQAAIQkgBUFAayAKLQABEAEgAiAJOgABIAJBAmohAgwBCwsDQCAFQUBrEAQgAiAMT3JFBEAgBiAFQUBrIAcQAkEBdGoiAC0AACEKIAVBQGsgAC0AARABIAIgCjoAACACQQFqIQIMAQsLA0AgAiAMSQRAIAYgBUFAayAHEAJBAXRqIgAtAAAhCiAFQUBrIAAtAAEQASACIAo6AAAgAkEBaiECDAELCyANQX1qIQADQCAFQShqEAQgBCAAT3JFBEAgBiAFQShqIAcQAkEBdGoiAi0AACEKIAVBKGogAi0AARABIAQgCjoAACAGIAVBKGogBxACQQF0aiICLQAAIQogBUEoaiACLQABEAEgBCAKOgABIARBAmohBAwBCwsDQCAFQShqEAQgBCANT3JFBEAgBiAFQShqIAcQAkEBdGoiAC0AACECIAVBKGogAC0AARABIAQgAjoAACAEQQFqIQQMAQsLA0AgBCANSQRAIAYgBUEoaiAHEAJBAXRqIgAtAAAhAiAFQShqIAAtAAEQASAEIAI6AAAgBEEBaiEEDAELCwNAIAVBEGoQBCADIA9PckUEQCAGIAVBEGogBxACQQF0aiIALQAAIQIgBUEQaiAALQABEAEgAyACOgAAIAYgBUEQaiAHEAJBAXRqIgAtAAAhAiAFQRBqIAAtAAEQASADIAI6AAEgA0ECaiEDDAELCwNAIAVBEGoQBCADIA5PckUEQCAGIAVBEGogBxACQQF0aiIALQAAIQIgBUEQaiAALQABEAEgAyACOgAAIANBAWohAwwBCwsDQCADIA5JBEAgBiAFQRBqIAcQAkEBdGoiAC0AACECIAVBEGogAC0AARABIAMgAjoAACADQQFqIQMMAQsLIAFBbCAFQdgAahAKIAVBQGsQCnEgBUEoahAKcSAFQRBqEApxGyEJDAELQWwhCQsgBUHwAGokACAJC8oCAQR/IwBBIGsiBSQAIAUgBBAOIAUtAAIhByAFQQhqIAIgAxAGIgIQA0UEQCAEQQRqIQIgACABaiIDQX1qIQQDQCAFQQhqEAQgACAET3JFBEAgAiAFQQhqIAcQAkEBdGoiBi0AACEIIAVBCGogBi0AARABIAAgCDoAACACIAVBCGogBxACQQF0aiIGLQAAIQggBUEIaiAGLQABEAEgACAIOgABIABBAmohAAwBCwsDQCAFQQhqEAQgACADT3JFBEAgAiAFQQhqIAcQAkEBdGoiBC0AACEGIAVBCGogBC0AARABIAAgBjoAACAAQQFqIQAMAQsLA0AgACADT0UEQCACIAVBCGogBxACQQF0aiIELQAAIQYgBUEIaiAELQABEAEgACAGOgAAIABBAWohAAwBCwsgAUFsIAVBCGoQChshAgsgBUEgaiQAIAILtgMBCX8jAEEQayIGJAAgBkEANgIMIAZBADYCCEFUIQQCQAJAIANBQGsiDCADIAZBCGogBkEMaiABIAIQMSICEAMNACAGQQRqIAAQDiAGKAIMIgcgBi0ABEEBaksNASAAQQRqIQogBkEAOgAFIAYgBzoABiAAIAYoAgQ2AgAgB0EBaiEJQQEhBANAIAQgCUkEQCADIARBAnRqIgEoAgAhACABIAU2AgAgACAEQX9qdCAFaiEFIARBAWohBAwBCwsgB0EBaiEHQQAhBSAGKAIIIQkDQCAFIAlGDQEgAyAFIAxqLQAAIgRBAnRqIgBBASAEdEEBdSILIAAoAgAiAWoiADYCACAHIARrIQhBACEEAkAgC0EDTQRAA0AgBCALRg0CIAogASAEakEBdGoiACAIOgABIAAgBToAACAEQQFqIQQMAAALAAsDQCABIABPDQEgCiABQQF0aiIEIAg6AAEgBCAFOgAAIAQgCDoAAyAEIAU6AAIgBCAIOgAFIAQgBToABCAEIAg6AAcgBCAFOgAGIAFBBGohAQwAAAsACyAFQQFqIQUMAAALAAsgAiEECyAGQRBqJAAgBAutAQECfwJAQYQgKAIAIABHIAAoAgBBAXYiAyABa0F4aiICQXhxQQhHcgR/IAIFIAMQJ0UNASACQQhqC0EQSQ0AIAAgACgCACICQQFxIAAgAWpBD2pBeHEiASAAa0EBdHI2AgAgASAANgIEIAEgASgCAEEBcSAAIAJBAXZqIAFrIgJBAXRyNgIAQYQgIAEgAkH/////B3FqQQRqQYQgKAIAIABGGyABNgIAIAEQJQsLygIBBX8CQAJAAkAgAEEIIABBCEsbZ0EfcyAAaUEBR2oiAUEESSAAIAF2cg0AIAFBAnRB/B5qKAIAIgJFDQADQCACQXhqIgMoAgBBAXZBeGoiBSAATwRAIAIgBUEIIAVBCEsbZ0Efc0ECdEGAH2oiASgCAEYEQCABIAIoAgQ2AgALDAMLIARBHksNASAEQQFqIQQgAigCBCICDQALC0EAIQMgAUEgTw0BA0AgAUECdEGAH2ooAgAiAkUEQCABQR5LIQIgAUEBaiEBIAJFDQEMAwsLIAIgAkF4aiIDKAIAQQF2QXhqIgFBCCABQQhLG2dBH3NBAnRBgB9qIgEoAgBGBEAgASACKAIENgIACwsgAigCACIBBEAgASACKAIENgIECyACKAIEIgEEQCABIAIoAgA2AgALIAMgAygCAEEBcjYCACADIAAQNwsgAwvhCwINfwV+IwBB8ABrIgckACAHIAAoAvDhASIINgJcIAEgAmohDSAIIAAoAoDiAWohDwJAAkAgBUUEQCABIQQMAQsgACgCxOABIRAgACgCwOABIREgACgCvOABIQ4gAEEBNgKM4QFBACEIA0AgCEEDRwRAIAcgCEECdCICaiAAIAJqQazQAWooAgA2AkQgCEEBaiEIDAELC0FsIQwgB0EYaiADIAQQBhADDQEgB0EsaiAHQRhqIAAoAgAQEyAHQTRqIAdBGGogACgCCBATIAdBPGogB0EYaiAAKAIEEBMgDUFgaiESIAEhBEEAIQwDQCAHKAIwIAcoAixBA3RqKQIAIhRCEIinQf8BcSEIIAcoAkAgBygCPEEDdGopAgAiFUIQiKdB/wFxIQsgBygCOCAHKAI0QQN0aikCACIWQiCIpyEJIBVCIIghFyAUQiCIpyECAkAgFkIQiKdB/wFxIgNBAk8EQAJAIAZFIANBGUlyRQRAIAkgB0EYaiADQSAgBygCHGsiCiAKIANLGyIKEAUgAyAKayIDdGohCSAHQRhqEAQaIANFDQEgB0EYaiADEAUgCWohCQwBCyAHQRhqIAMQBSAJaiEJIAdBGGoQBBoLIAcpAkQhGCAHIAk2AkQgByAYNwNIDAELAkAgA0UEQCACBEAgBygCRCEJDAMLIAcoAkghCQwBCwJAAkAgB0EYakEBEAUgCSACRWpqIgNBA0YEQCAHKAJEQX9qIgMgA0VqIQkMAQsgA0ECdCAHaigCRCIJIAlFaiEJIANBAUYNAQsgByAHKAJINgJMCwsgByAHKAJENgJIIAcgCTYCRAsgF6chAyALBEAgB0EYaiALEAUgA2ohAwsgCCALakEUTwRAIAdBGGoQBBoLIAgEQCAHQRhqIAgQBSACaiECCyAHQRhqEAQaIAcgB0EYaiAUQhiIp0H/AXEQCCAUp0H//wNxajYCLCAHIAdBGGogFUIYiKdB/wFxEAggFadB//8DcWo2AjwgB0EYahAEGiAHIAdBGGogFkIYiKdB/wFxEAggFqdB//8DcWo2AjQgByACNgJgIAcoAlwhCiAHIAk2AmggByADNgJkAkACQAJAIAQgAiADaiILaiASSw0AIAIgCmoiEyAPSw0AIA0gBGsgC0Egak8NAQsgByAHKQNoNwMQIAcgBykDYDcDCCAEIA0gB0EIaiAHQdwAaiAPIA4gESAQEB4hCwwBCyACIARqIQggBCAKEAcgAkERTwRAIARBEGohAgNAIAIgCkEQaiIKEAcgAkEQaiICIAhJDQALCyAIIAlrIQIgByATNgJcIAkgCCAOa0sEQCAJIAggEWtLBEBBbCELDAILIBAgAiAOayICaiIKIANqIBBNBEAgCCAKIAMQDxoMAgsgCCAKQQAgAmsQDyEIIAcgAiADaiIDNgJkIAggAmshCCAOIQILIAlBEE8EQCADIAhqIQMDQCAIIAIQByACQRBqIQIgCEEQaiIIIANJDQALDAELAkAgCUEHTQRAIAggAi0AADoAACAIIAItAAE6AAEgCCACLQACOgACIAggAi0AAzoAAyAIQQRqIAIgCUECdCIDQcAeaigCAGoiAhAXIAIgA0HgHmooAgBrIQIgBygCZCEDDAELIAggAhAMCyADQQlJDQAgAyAIaiEDIAhBCGoiCCACQQhqIgJrQQ9MBEADQCAIIAIQDCACQQhqIQIgCEEIaiIIIANJDQAMAgALAAsDQCAIIAIQByACQRBqIQIgCEEQaiIIIANJDQALCyAHQRhqEAQaIAsgDCALEAMiAhshDCAEIAQgC2ogAhshBCAFQX9qIgUNAAsgDBADDQFBbCEMIAdBGGoQBEECSQ0BQQAhCANAIAhBA0cEQCAAIAhBAnQiAmpBrNABaiACIAdqKAJENgIAIAhBAWohCAwBCwsgBygCXCEIC0G6fyEMIA8gCGsiACANIARrSw0AIAQEfyAEIAggABALIABqBUEACyABayEMCyAHQfAAaiQAIAwLkRcCFn8FfiMAQdABayIHJAAgByAAKALw4QEiCDYCvAEgASACaiESIAggACgCgOIBaiETAkACQCAFRQRAIAEhAwwBCyAAKALE4AEhESAAKALA4AEhFSAAKAK84AEhDyAAQQE2AozhAUEAIQgDQCAIQQNHBEAgByAIQQJ0IgJqIAAgAmpBrNABaigCADYCVCAIQQFqIQgMAQsLIAcgETYCZCAHIA82AmAgByABIA9rNgJoQWwhECAHQShqIAMgBBAGEAMNASAFQQQgBUEESBshFyAHQTxqIAdBKGogACgCABATIAdBxABqIAdBKGogACgCCBATIAdBzABqIAdBKGogACgCBBATQQAhBCAHQeAAaiEMIAdB5ABqIQoDQCAHQShqEARBAksgBCAXTnJFBEAgBygCQCAHKAI8QQN0aikCACIdQhCIp0H/AXEhCyAHKAJQIAcoAkxBA3RqKQIAIh5CEIinQf8BcSEJIAcoAkggBygCREEDdGopAgAiH0IgiKchCCAeQiCIISAgHUIgiKchAgJAIB9CEIinQf8BcSIDQQJPBEACQCAGRSADQRlJckUEQCAIIAdBKGogA0EgIAcoAixrIg0gDSADSxsiDRAFIAMgDWsiA3RqIQggB0EoahAEGiADRQ0BIAdBKGogAxAFIAhqIQgMAQsgB0EoaiADEAUgCGohCCAHQShqEAQaCyAHKQJUISEgByAINgJUIAcgITcDWAwBCwJAIANFBEAgAgRAIAcoAlQhCAwDCyAHKAJYIQgMAQsCQAJAIAdBKGpBARAFIAggAkVqaiIDQQNGBEAgBygCVEF/aiIDIANFaiEIDAELIANBAnQgB2ooAlQiCCAIRWohCCADQQFGDQELIAcgBygCWDYCXAsLIAcgBygCVDYCWCAHIAg2AlQLICCnIQMgCQRAIAdBKGogCRAFIANqIQMLIAkgC2pBFE8EQCAHQShqEAQaCyALBEAgB0EoaiALEAUgAmohAgsgB0EoahAEGiAHIAcoAmggAmoiCSADajYCaCAKIAwgCCAJSxsoAgAhDSAHIAdBKGogHUIYiKdB/wFxEAggHadB//8DcWo2AjwgByAHQShqIB5CGIinQf8BcRAIIB6nQf//A3FqNgJMIAdBKGoQBBogB0EoaiAfQhiIp0H/AXEQCCEOIAdB8ABqIARBBHRqIgsgCSANaiAIazYCDCALIAg2AgggCyADNgIEIAsgAjYCACAHIA4gH6dB//8DcWo2AkQgBEEBaiEEDAELCyAEIBdIDQEgEkFgaiEYIAdB4ABqIRogB0HkAGohGyABIQMDQCAHQShqEARBAksgBCAFTnJFBEAgBygCQCAHKAI8QQN0aikCACIdQhCIp0H/AXEhCyAHKAJQIAcoAkxBA3RqKQIAIh5CEIinQf8BcSEIIAcoAkggBygCREEDdGopAgAiH0IgiKchCSAeQiCIISAgHUIgiKchDAJAIB9CEIinQf8BcSICQQJPBEACQCAGRSACQRlJckUEQCAJIAdBKGogAkEgIAcoAixrIgogCiACSxsiChAFIAIgCmsiAnRqIQkgB0EoahAEGiACRQ0BIAdBKGogAhAFIAlqIQkMAQsgB0EoaiACEAUgCWohCSAHQShqEAQaCyAHKQJUISEgByAJNgJUIAcgITcDWAwBCwJAIAJFBEAgDARAIAcoAlQhCQwDCyAHKAJYIQkMAQsCQAJAIAdBKGpBARAFIAkgDEVqaiICQQNGBEAgBygCVEF/aiICIAJFaiEJDAELIAJBAnQgB2ooAlQiCSAJRWohCSACQQFGDQELIAcgBygCWDYCXAsLIAcgBygCVDYCWCAHIAk2AlQLICCnIRQgCARAIAdBKGogCBAFIBRqIRQLIAggC2pBFE8EQCAHQShqEAQaCyALBEAgB0EoaiALEAUgDGohDAsgB0EoahAEGiAHIAcoAmggDGoiGSAUajYCaCAbIBogCSAZSxsoAgAhHCAHIAdBKGogHUIYiKdB/wFxEAggHadB//8DcWo2AjwgByAHQShqIB5CGIinQf8BcRAIIB6nQf//A3FqNgJMIAdBKGoQBBogByAHQShqIB9CGIinQf8BcRAIIB+nQf//A3FqNgJEIAcgB0HwAGogBEEDcUEEdGoiDSkDCCIdNwPIASAHIA0pAwAiHjcDwAECQAJAAkAgBygCvAEiDiAepyICaiIWIBNLDQAgAyAHKALEASIKIAJqIgtqIBhLDQAgEiADayALQSBqTw0BCyAHIAcpA8gBNwMQIAcgBykDwAE3AwggAyASIAdBCGogB0G8AWogEyAPIBUgERAeIQsMAQsgAiADaiEIIAMgDhAHIAJBEU8EQCADQRBqIQIDQCACIA5BEGoiDhAHIAJBEGoiAiAISQ0ACwsgCCAdpyIOayECIAcgFjYCvAEgDiAIIA9rSwRAIA4gCCAVa0sEQEFsIQsMAgsgESACIA9rIgJqIhYgCmogEU0EQCAIIBYgChAPGgwCCyAIIBZBACACaxAPIQggByACIApqIgo2AsQBIAggAmshCCAPIQILIA5BEE8EQCAIIApqIQoDQCAIIAIQByACQRBqIQIgCEEQaiIIIApJDQALDAELAkAgDkEHTQRAIAggAi0AADoAACAIIAItAAE6AAEgCCACLQACOgACIAggAi0AAzoAAyAIQQRqIAIgDkECdCIKQcAeaigCAGoiAhAXIAIgCkHgHmooAgBrIQIgBygCxAEhCgwBCyAIIAIQDAsgCkEJSQ0AIAggCmohCiAIQQhqIgggAkEIaiICa0EPTARAA0AgCCACEAwgAkEIaiECIAhBCGoiCCAKSQ0ADAIACwALA0AgCCACEAcgAkEQaiECIAhBEGoiCCAKSQ0ACwsgCxADBEAgCyEQDAQFIA0gDDYCACANIBkgHGogCWs2AgwgDSAJNgIIIA0gFDYCBCAEQQFqIQQgAyALaiEDDAILAAsLIAQgBUgNASAEIBdrIQtBACEEA0AgCyAFSARAIAcgB0HwAGogC0EDcUEEdGoiAikDCCIdNwPIASAHIAIpAwAiHjcDwAECQAJAAkAgBygCvAEiDCAepyICaiIKIBNLDQAgAyAHKALEASIJIAJqIhBqIBhLDQAgEiADayAQQSBqTw0BCyAHIAcpA8gBNwMgIAcgBykDwAE3AxggAyASIAdBGGogB0G8AWogEyAPIBUgERAeIRAMAQsgAiADaiEIIAMgDBAHIAJBEU8EQCADQRBqIQIDQCACIAxBEGoiDBAHIAJBEGoiAiAISQ0ACwsgCCAdpyIGayECIAcgCjYCvAEgBiAIIA9rSwRAIAYgCCAVa0sEQEFsIRAMAgsgESACIA9rIgJqIgwgCWogEU0EQCAIIAwgCRAPGgwCCyAIIAxBACACaxAPIQggByACIAlqIgk2AsQBIAggAmshCCAPIQILIAZBEE8EQCAIIAlqIQYDQCAIIAIQByACQRBqIQIgCEEQaiIIIAZJDQALDAELAkAgBkEHTQRAIAggAi0AADoAACAIIAItAAE6AAEgCCACLQACOgACIAggAi0AAzoAAyAIQQRqIAIgBkECdCIGQcAeaigCAGoiAhAXIAIgBkHgHmooAgBrIQIgBygCxAEhCQwBCyAIIAIQDAsgCUEJSQ0AIAggCWohBiAIQQhqIgggAkEIaiICa0EPTARAA0AgCCACEAwgAkEIaiECIAhBCGoiCCAGSQ0ADAIACwALA0AgCCACEAcgAkEQaiECIAhBEGoiCCAGSQ0ACwsgEBADDQMgC0EBaiELIAMgEGohAwwBCwsDQCAEQQNHBEAgACAEQQJ0IgJqQazQAWogAiAHaigCVDYCACAEQQFqIQQMAQsLIAcoArwBIQgLQbp/IRAgEyAIayIAIBIgA2tLDQAgAwR/IAMgCCAAEAsgAGoFQQALIAFrIRALIAdB0AFqJAAgEAslACAAQgA3AgAgAEEAOwEIIABBADoACyAAIAE2AgwgACACOgAKC7QFAQN/IwBBMGsiBCQAIABB/wFqIgVBfWohBgJAIAMvAQIEQCAEQRhqIAEgAhAGIgIQAw0BIARBEGogBEEYaiADEBwgBEEIaiAEQRhqIAMQHCAAIQMDQAJAIARBGGoQBCADIAZPckUEQCADIARBEGogBEEYahASOgAAIAMgBEEIaiAEQRhqEBI6AAEgBEEYahAERQ0BIANBAmohAwsgBUF+aiEFAn8DQEG6fyECIAMiASAFSw0FIAEgBEEQaiAEQRhqEBI6AAAgAUEBaiEDIARBGGoQBEEDRgRAQQIhAiAEQQhqDAILIAMgBUsNBSABIARBCGogBEEYahASOgABIAFBAmohA0EDIQIgBEEYahAEQQNHDQALIARBEGoLIQUgAyAFIARBGGoQEjoAACABIAJqIABrIQIMAwsgAyAEQRBqIARBGGoQEjoAAiADIARBCGogBEEYahASOgADIANBBGohAwwAAAsACyAEQRhqIAEgAhAGIgIQAw0AIARBEGogBEEYaiADEBwgBEEIaiAEQRhqIAMQHCAAIQMDQAJAIARBGGoQBCADIAZPckUEQCADIARBEGogBEEYahAROgAAIAMgBEEIaiAEQRhqEBE6AAEgBEEYahAERQ0BIANBAmohAwsgBUF+aiEFAn8DQEG6fyECIAMiASAFSw0EIAEgBEEQaiAEQRhqEBE6AAAgAUEBaiEDIARBGGoQBEEDRgRAQQIhAiAEQQhqDAILIAMgBUsNBCABIARBCGogBEEYahAROgABIAFBAmohA0EDIQIgBEEYahAEQQNHDQALIARBEGoLIQUgAyAFIARBGGoQEToAACABIAJqIABrIQIMAgsgAyAEQRBqIARBGGoQEToAAiADIARBCGogBEEYahAROgADIANBBGohAwwAAAsACyAEQTBqJAAgAgtpAQF/An8CQAJAIAJBB00NACABKAAAQbfIwuF+Rw0AIAAgASgABDYCmOIBQWIgAEEQaiABIAIQPiIDEAMNAhogAEKBgICAEDcDiOEBIAAgASADaiACIANrECoMAQsgACABIAIQKgtBAAsLrQMBBn8jAEGAAWsiAyQAQWIhCAJAIAJBCUkNACAAQZjQAGogAUEIaiIEIAJBeGogAEGY0AAQMyIFEAMiBg0AIANBHzYCfCADIANB/ABqIANB+ABqIAQgBCAFaiAGGyIEIAEgAmoiAiAEaxAVIgUQAw0AIAMoAnwiBkEfSw0AIAMoAngiB0EJTw0AIABBiCBqIAMgBkGAC0GADCAHEBggA0E0NgJ8IAMgA0H8AGogA0H4AGogBCAFaiIEIAIgBGsQFSIFEAMNACADKAJ8IgZBNEsNACADKAJ4IgdBCk8NACAAQZAwaiADIAZBgA1B4A4gBxAYIANBIzYCfCADIANB/ABqIANB+ABqIAQgBWoiBCACIARrEBUiBRADDQAgAygCfCIGQSNLDQAgAygCeCIHQQpPDQAgACADIAZBwBBB0BEgBxAYIAQgBWoiBEEMaiIFIAJLDQAgAiAFayEFQQAhAgNAIAJBA0cEQCAEKAAAIgZBf2ogBU8NAiAAIAJBAnRqQZzQAWogBjYCACACQQFqIQIgBEEEaiEEDAELCyAEIAFrIQgLIANBgAFqJAAgCAtGAQN/IABBCGohAyAAKAIEIQJBACEAA0AgACACdkUEQCABIAMgAEEDdGotAAJBFktqIQEgAEEBaiEADAELCyABQQggAmt0C4YDAQV/Qbh/IQcCQCADRQ0AIAItAAAiBEUEQCABQQA2AgBBAUG4fyADQQFGGw8LAn8gAkEBaiIFIARBGHRBGHUiBkF/Sg0AGiAGQX9GBEAgA0EDSA0CIAUvAABBgP4BaiEEIAJBA2oMAQsgA0ECSA0BIAItAAEgBEEIdHJBgIB+aiEEIAJBAmoLIQUgASAENgIAIAVBAWoiASACIANqIgNLDQBBbCEHIABBEGogACAFLQAAIgVBBnZBI0EJIAEgAyABa0HAEEHQEUHwEiAAKAKM4QEgACgCnOIBIAQQHyIGEAMiCA0AIABBmCBqIABBCGogBUEEdkEDcUEfQQggASABIAZqIAgbIgEgAyABa0GAC0GADEGAFyAAKAKM4QEgACgCnOIBIAQQHyIGEAMiCA0AIABBoDBqIABBBGogBUECdkEDcUE0QQkgASABIAZqIAgbIgEgAyABa0GADUHgDkGQGSAAKAKM4QEgACgCnOIBIAQQHyIAEAMNACAAIAFqIAJrIQcLIAcLrQMBCn8jAEGABGsiCCQAAn9BUiACQf8BSw0AGkFUIANBDEsNABogAkEBaiELIABBBGohCUGAgAQgA0F/anRBEHUhCkEAIQJBASEEQQEgA3QiB0F/aiIMIQUDQCACIAtGRQRAAkAgASACQQF0Ig1qLwEAIgZB//8DRgRAIAkgBUECdGogAjoAAiAFQX9qIQVBASEGDAELIARBACAKIAZBEHRBEHVKGyEECyAIIA1qIAY7AQAgAkEBaiECDAELCyAAIAQ7AQIgACADOwEAIAdBA3YgB0EBdmpBA2ohBkEAIQRBACECA0AgBCALRkUEQCABIARBAXRqLgEAIQpBACEAA0AgACAKTkUEQCAJIAJBAnRqIAQ6AAIDQCACIAZqIAxxIgIgBUsNAAsgAEEBaiEADAELCyAEQQFqIQQMAQsLQX8gAg0AGkEAIQIDfyACIAdGBH9BAAUgCCAJIAJBAnRqIgAtAAJBAXRqIgEgAS8BACIBQQFqOwEAIAAgAyABEBRrIgU6AAMgACABIAVB/wFxdCAHazsBACACQQFqIQIMAQsLCyEFIAhBgARqJAAgBQvjBgEIf0FsIQcCQCACQQNJDQACQAJAAkACQCABLQAAIgNBA3EiCUEBaw4DAwEAAgsgACgCiOEBDQBBYg8LIAJBBUkNAkEDIQYgASgAACEFAn8CQAJAIANBAnZBA3EiCEF+aiIEQQFNBEAgBEEBaw0BDAILIAVBDnZB/wdxIQQgBUEEdkH/B3EhAyAIRQwCCyAFQRJ2IQRBBCEGIAVBBHZB//8AcSEDQQAMAQsgBUEEdkH//w9xIgNBgIAISw0DIAEtAARBCnQgBUEWdnIhBEEFIQZBAAshBSAEIAZqIgogAksNAgJAIANBgQZJDQAgACgCnOIBRQ0AQQAhAgNAIAJBg4ABSw0BIAJBQGshAgwAAAsACwJ/IAlBA0YEQCABIAZqIQEgAEHw4gFqIQIgACgCDCEGIAUEQCACIAMgASAEIAYQXwwCCyACIAMgASAEIAYQXQwBCyAAQbjQAWohAiABIAZqIQEgAEHw4gFqIQYgAEGo0ABqIQggBQRAIAggBiADIAEgBCACEF4MAQsgCCAGIAMgASAEIAIQXAsQAw0CIAAgAzYCgOIBIABBATYCiOEBIAAgAEHw4gFqNgLw4QEgCUECRgRAIAAgAEGo0ABqNgIMCyAAIANqIgBBiOMBakIANwAAIABBgOMBakIANwAAIABB+OIBakIANwAAIABB8OIBakIANwAAIAoPCwJ/AkACQAJAIANBAnZBA3FBf2oiBEECSw0AIARBAWsOAgACAQtBASEEIANBA3YMAgtBAiEEIAEvAABBBHYMAQtBAyEEIAEQIUEEdgsiAyAEaiIFQSBqIAJLBEAgBSACSw0CIABB8OIBaiABIARqIAMQCyEBIAAgAzYCgOIBIAAgATYC8OEBIAEgA2oiAEIANwAYIABCADcAECAAQgA3AAggAEIANwAAIAUPCyAAIAM2AoDiASAAIAEgBGo2AvDhASAFDwsCfwJAAkACQCADQQJ2QQNxQX9qIgRBAksNACAEQQFrDgIAAgELQQEhByADQQN2DAILQQIhByABLwAAQQR2DAELIAJBBEkgARAhIgJBj4CAAUtyDQFBAyEHIAJBBHYLIQIgAEHw4gFqIAEgB2otAAAgAkEgahAQIQEgACACNgKA4gEgACABNgLw4QEgB0EBaiEHCyAHC0sAIABC+erQ0OfJoeThADcDICAAQgA3AxggAELP1tO+0ser2UI3AxAgAELW64Lu6v2J9eAANwMIIABCADcDACAAQShqQQBBKBAQGgviAgICfwV+IABBKGoiASAAKAJIaiECAn4gACkDACIDQiBaBEAgACkDECIEQgeJIAApAwgiBUIBiXwgACkDGCIGQgyJfCAAKQMgIgdCEol8IAUQGSAEEBkgBhAZIAcQGQwBCyAAKQMYQsXP2bLx5brqJ3wLIAN8IQMDQCABQQhqIgAgAk0EQEIAIAEpAAAQCSADhUIbiUKHla+vmLbem55/fkLj3MqV/M7y9YV/fCEDIAAhAQwBCwsCQCABQQRqIgAgAksEQCABIQAMAQsgASgAAK1Ch5Wvr5i23puef34gA4VCF4lCz9bTvtLHq9lCfkL5893xmfaZqxZ8IQMLA0AgACACSQRAIAAxAABCxc/ZsvHluuonfiADhUILiUKHla+vmLbem55/fiEDIABBAWohAAwBCwsgA0IhiCADhULP1tO+0ser2UJ+IgNCHYggA4VC+fPd8Zn2masWfiIDQiCIIAOFC+8CAgJ/BH4gACAAKQMAIAKtfDcDAAJAAkAgACgCSCIDIAJqIgRBH00EQCABRQ0BIAAgA2pBKGogASACECAgACgCSCACaiEEDAELIAEgAmohAgJ/IAMEQCAAQShqIgQgA2ogAUEgIANrECAgACAAKQMIIAQpAAAQCTcDCCAAIAApAxAgACkAMBAJNwMQIAAgACkDGCAAKQA4EAk3AxggACAAKQMgIABBQGspAAAQCTcDICAAKAJIIQMgAEEANgJIIAEgA2tBIGohAQsgAUEgaiACTQsEQCACQWBqIQMgACkDICEFIAApAxghBiAAKQMQIQcgACkDCCEIA0AgCCABKQAAEAkhCCAHIAEpAAgQCSEHIAYgASkAEBAJIQYgBSABKQAYEAkhBSABQSBqIgEgA00NAAsgACAFNwMgIAAgBjcDGCAAIAc3AxAgACAINwMICyABIAJPDQEgAEEoaiABIAIgAWsiBBAgCyAAIAQ2AkgLCy8BAX8gAEUEQEG2f0EAIAMbDwtBun8hBCADIAFNBH8gACACIAMQEBogAwVBun8LCy8BAX8gAEUEQEG2f0EAIAMbDwtBun8hBCADIAFNBH8gACACIAMQCxogAwVBun8LC6gCAQZ/IwBBEGsiByQAIABB2OABaikDAEKAgIAQViEIQbh/IQUCQCAEQf//B0sNACAAIAMgBBBCIgUQAyIGDQAgACgCnOIBIQkgACAHQQxqIAMgAyAFaiAGGyIKIARBACAFIAYbayIGEEAiAxADBEAgAyEFDAELIAcoAgwhBCABRQRAQbp/IQUgBEEASg0BCyAGIANrIQUgAyAKaiEDAkAgCQRAIABBADYCnOIBDAELAkACQAJAIARBBUgNACAAQdjgAWopAwBCgICACFgNAAwBCyAAQQA2ApziAQwBCyAAKAIIED8hBiAAQQA2ApziASAGQRRPDQELIAAgASACIAMgBSAEIAgQOSEFDAELIAAgASACIAMgBSAEIAgQOiEFCyAHQRBqJAAgBQtnACAAQdDgAWogASACIAAoAuzhARAuIgEQAwRAIAEPC0G4fyECAkAgAQ0AIABB7OABaigCACIBBEBBYCECIAAoApjiASABRw0BC0EAIQIgAEHw4AFqKAIARQ0AIABBkOEBahBDCyACCycBAX8QVyIERQRAQUAPCyAEIAAgASACIAMgBBBLEE8hACAEEFYgAAs/AQF/AkACQAJAIAAoAqDiAUEBaiIBQQJLDQAgAUEBaw4CAAECCyAAEDBBAA8LIABBADYCoOIBCyAAKAKU4gELvAMCB38BfiMAQRBrIgkkAEG4fyEGAkAgBCgCACIIQQVBCSAAKALs4QEiBRtJDQAgAygCACIHQQFBBSAFGyAFEC8iBRADBEAgBSEGDAELIAggBUEDakkNACAAIAcgBRBJIgYQAw0AIAEgAmohCiAAQZDhAWohCyAIIAVrIQIgBSAHaiEHIAEhBQNAIAcgAiAJECwiBhADDQEgAkF9aiICIAZJBEBBuH8hBgwCCyAJKAIAIghBAksEQEFsIQYMAgsgB0EDaiEHAn8CQAJAAkAgCEEBaw4CAgABCyAAIAUgCiAFayAHIAYQSAwCCyAFIAogBWsgByAGEEcMAQsgBSAKIAVrIActAAAgCSgCCBBGCyIIEAMEQCAIIQYMAgsgACgC8OABBEAgCyAFIAgQRQsgAiAGayECIAYgB2ohByAFIAhqIQUgCSgCBEUNAAsgACkD0OABIgxCf1IEQEFsIQYgDCAFIAFrrFINAQsgACgC8OABBEBBaiEGIAJBBEkNASALEEQhDCAHKAAAIAynRw0BIAdBBGohByACQXxqIQILIAMgBzYCACAEIAI2AgAgBSABayEGCyAJQRBqJAAgBgsuACAAECsCf0EAQQAQAw0AGiABRSACRXJFBEBBYiAAIAEgAhA9EAMNARoLQQALCzcAIAEEQCAAIAAoAsTgASABKAIEIAEoAghqRzYCnOIBCyAAECtBABADIAFFckUEQCAAIAEQWwsL0QIBB38jAEEQayIGJAAgBiAENgIIIAYgAzYCDCAFBEAgBSgCBCEKIAUoAgghCQsgASEIAkACQANAIAAoAuzhARAWIQsCQANAIAQgC0kNASADKAAAQXBxQdDUtMIBRgRAIAMgBBAiIgcQAw0EIAQgB2shBCADIAdqIQMMAQsLIAYgAzYCDCAGIAQ2AggCQCAFBEAgACAFEE5BACEHQQAQA0UNAQwFCyAAIAogCRBNIgcQAw0ECyAAIAgQUCAMQQFHQQAgACAIIAIgBkEMaiAGQQhqEEwiByIDa0EAIAMQAxtBCkdyRQRAQbh/IQcMBAsgBxADDQMgAiAHayECIAcgCGohCEEBIQwgBigCDCEDIAYoAgghBAwBCwsgBiADNgIMIAYgBDYCCEG4fyEHIAQNASAIIAFrIQcMAQsgBiADNgIMIAYgBDYCCAsgBkEQaiQAIAcLRgECfyABIAAoArjgASICRwRAIAAgAjYCxOABIAAgATYCuOABIAAoArzgASEDIAAgATYCvOABIAAgASADIAJrajYCwOABCwutAgIEfwF+IwBBQGoiBCQAAkACQCACQQhJDQAgASgAAEFwcUHQ1LTCAUcNACABIAIQIiEBIABCADcDCCAAQQA2AgQgACABNgIADAELIARBGGogASACEC0iAxADBEAgACADEBoMAQsgAwRAIABBuH8QGgwBCyACIAQoAjAiA2shAiABIANqIQMDQAJAIAAgAyACIARBCGoQLCIFEAMEfyAFBSACIAVBA2oiBU8NAUG4fwsQGgwCCyAGQQFqIQYgAiAFayECIAMgBWohAyAEKAIMRQ0ACyAEKAI4BEAgAkEDTQRAIABBuH8QGgwCCyADQQRqIQMLIAQoAighAiAEKQMYIQcgAEEANgIEIAAgAyABazYCACAAIAIgBmytIAcgB0J/URs3AwgLIARBQGskAAslAQF/IwBBEGsiAiQAIAIgACABEFEgAigCACEAIAJBEGokACAAC30BBH8jAEGQBGsiBCQAIARB/wE2AggCQCAEQRBqIARBCGogBEEMaiABIAIQFSIGEAMEQCAGIQUMAQtBVCEFIAQoAgwiB0EGSw0AIAMgBEEQaiAEKAIIIAcQQSIFEAMNACAAIAEgBmogAiAGayADEDwhBQsgBEGQBGokACAFC4cBAgJ/An5BABAWIQMCQANAIAEgA08EQAJAIAAoAABBcHFB0NS0wgFGBEAgACABECIiAhADRQ0BQn4PCyAAIAEQVSIEQn1WDQMgBCAFfCIFIARUIQJCfiEEIAINAyAAIAEQUiICEAMNAwsgASACayEBIAAgAmohAAwBCwtCfiAFIAEbIQQLIAQLPwIBfwF+IwBBMGsiAiQAAn5CfiACQQhqIAAgARAtDQAaQgAgAigCHEEBRg0AGiACKQMICyEDIAJBMGokACADC40BAQJ/IwBBMGsiASQAAkAgAEUNACAAKAKI4gENACABIABB/OEBaigCADYCKCABIAApAvThATcDICAAEDAgACgCqOIBIQIgASABKAIoNgIYIAEgASkDIDcDECACIAFBEGoQGyAAQQA2AqjiASABIAEoAig2AgggASABKQMgNwMAIAAgARAbCyABQTBqJAALKgECfyMAQRBrIgAkACAAQQA2AgggAEIANwMAIAAQWCEBIABBEGokACABC4cBAQN/IwBBEGsiAiQAAkAgACgCAEUgACgCBEVzDQAgAiAAKAIINgIIIAIgACkCADcDAAJ/IAIoAgAiAQRAIAIoAghBqOMJIAERBQAMAQtBqOMJECgLIgFFDQAgASAAKQIANwL04QEgAUH84QFqIAAoAgg2AgAgARBZIAEhAwsgAkEQaiQAIAMLywEBAn8jAEEgayIBJAAgAEGBgIDAADYCtOIBIABBADYCiOIBIABBADYC7OEBIABCADcDkOIBIABBADYCpOMJIABBADYC3OIBIABCADcCzOIBIABBADYCvOIBIABBADYCxOABIABCADcCnOIBIABBpOIBakIANwIAIABBrOIBakEANgIAIAFCADcCECABQgA3AhggASABKQMYNwMIIAEgASkDEDcDACABKAIIQQh2QQFxIQIgAEEANgLg4gEgACACNgKM4gEgAUEgaiQAC3YBA38jAEEwayIBJAAgAARAIAEgAEHE0AFqIgIoAgA2AiggASAAKQK80AE3AyAgACgCACEDIAEgAigCADYCGCABIAApArzQATcDECADIAFBEGoQGyABIAEoAig2AgggASABKQMgNwMAIAAgARAbCyABQTBqJAALzAEBAX8gACABKAK00AE2ApjiASAAIAEoAgQiAjYCwOABIAAgAjYCvOABIAAgAiABKAIIaiICNgK44AEgACACNgLE4AEgASgCuNABBEAgAEKBgICAEDcDiOEBIAAgAUGk0ABqNgIMIAAgAUGUIGo2AgggACABQZwwajYCBCAAIAFBDGo2AgAgAEGs0AFqIAFBqNABaigCADYCACAAQbDQAWogAUGs0AFqKAIANgIAIABBtNABaiABQbDQAWooAgA2AgAPCyAAQgA3A4jhAQs7ACACRQRAQbp/DwsgBEUEQEFsDwsgAiAEEGAEQCAAIAEgAiADIAQgBRBhDwsgACABIAIgAyAEIAUQZQtGAQF/IwBBEGsiBSQAIAVBCGogBBAOAn8gBS0ACQRAIAAgASACIAMgBBAyDAELIAAgASACIAMgBBA0CyEAIAVBEGokACAACzQAIAAgAyAEIAUQNiIFEAMEQCAFDwsgBSAESQR/IAEgAiADIAVqIAQgBWsgABA1BUG4fwsLRgEBfyMAQRBrIgUkACAFQQhqIAQQDgJ/IAUtAAkEQCAAIAEgAiADIAQQYgwBCyAAIAEgAiADIAQQNQshACAFQRBqJAAgAAtZAQF/QQ8hAiABIABJBEAgAUEEdCAAbiECCyAAQQh2IgEgAkEYbCIAQYwIaigCAGwgAEGICGooAgBqIgJBA3YgAmogAEGACGooAgAgAEGECGooAgAgAWxqSQs3ACAAIAMgBCAFQYAQEDMiBRADBEAgBQ8LIAUgBEkEfyABIAIgAyAFaiAEIAVrIAAQMgVBuH8LC78DAQN/IwBBIGsiBSQAIAVBCGogAiADEAYiAhADRQRAIAAgAWoiB0F9aiEGIAUgBBAOIARBBGohAiAFLQACIQMDQEEAIAAgBkkgBUEIahAEGwRAIAAgAiAFQQhqIAMQAkECdGoiBC8BADsAACAFQQhqIAQtAAIQASAAIAQtAANqIgQgAiAFQQhqIAMQAkECdGoiAC8BADsAACAFQQhqIAAtAAIQASAEIAAtAANqIQAMAQUgB0F+aiEEA0AgBUEIahAEIAAgBEtyRQRAIAAgAiAFQQhqIAMQAkECdGoiBi8BADsAACAFQQhqIAYtAAIQASAAIAYtAANqIQAMAQsLA0AgACAES0UEQCAAIAIgBUEIaiADEAJBAnRqIgYvAQA7AAAgBUEIaiAGLQACEAEgACAGLQADaiEADAELCwJAIAAgB08NACAAIAIgBUEIaiADEAIiA0ECdGoiAC0AADoAACAALQADQQFGBEAgBUEIaiAALQACEAEMAQsgBSgCDEEfSw0AIAVBCGogAiADQQJ0ai0AAhABIAUoAgxBIUkNACAFQSA2AgwLIAFBbCAFQQhqEAobIQILCwsgBUEgaiQAIAILkgIBBH8jAEFAaiIJJAAgCSADQTQQCyEDAkAgBEECSA0AIAMgBEECdGooAgAhCSADQTxqIAgQIyADQQE6AD8gAyACOgA+QQAhBCADKAI8IQoDQCAEIAlGDQEgACAEQQJ0aiAKNgEAIARBAWohBAwAAAsAC0EAIQkDQCAGIAlGRQRAIAMgBSAJQQF0aiIKLQABIgtBAnRqIgwoAgAhBCADQTxqIAotAABBCHQgCGpB//8DcRAjIANBAjoAPyADIAcgC2siCiACajoAPiAEQQEgASAKa3RqIQogAygCPCELA0AgACAEQQJ0aiALNgEAIARBAWoiBCAKSQ0ACyAMIAo2AgAgCUEBaiEJDAELCyADQUBrJAALowIBCX8jAEHQAGsiCSQAIAlBEGogBUE0EAsaIAcgBmshDyAHIAFrIRADQAJAIAMgCkcEQEEBIAEgByACIApBAXRqIgYtAAEiDGsiCGsiC3QhDSAGLQAAIQ4gCUEQaiAMQQJ0aiIMKAIAIQYgCyAPTwRAIAAgBkECdGogCyAIIAUgCEE0bGogCCAQaiIIQQEgCEEBShsiCCACIAQgCEECdGooAgAiCEEBdGogAyAIayAHIA4QYyAGIA1qIQgMAgsgCUEMaiAOECMgCUEBOgAPIAkgCDoADiAGIA1qIQggCSgCDCELA0AgBiAITw0CIAAgBkECdGogCzYBACAGQQFqIQYMAAALAAsgCUHQAGokAA8LIAwgCDYCACAKQQFqIQoMAAALAAs0ACAAIAMgBCAFEDYiBRADBEAgBQ8LIAUgBEkEfyABIAIgAyAFaiAEIAVrIAAQNAVBuH8LCyMAIAA/AEEQdGtB//8DakEQdkAAQX9GBEBBAA8LQQAQAEEBCzsBAX8gAgRAA0AgACABIAJBgCAgAkGAIEkbIgMQCyEAIAFBgCBqIQEgAEGAIGohACACIANrIgINAAsLCwYAIAAQAwsLqBUJAEGICAsNAQAAAAEAAAACAAAAAgBBoAgLswYBAAAAAQAAAAIAAAACAAAAJgAAAIIAAAAhBQAASgAAAGcIAAAmAAAAwAEAAIAAAABJBQAASgAAAL4IAAApAAAALAIAAIAAAABJBQAASgAAAL4IAAAvAAAAygIAAIAAAACKBQAASgAAAIQJAAA1AAAAcwMAAIAAAACdBQAASgAAAKAJAAA9AAAAgQMAAIAAAADrBQAASwAAAD4KAABEAAAAngMAAIAAAABNBgAASwAAAKoKAABLAAAAswMAAIAAAADBBgAATQAAAB8NAABNAAAAUwQAAIAAAAAjCAAAUQAAAKYPAABUAAAAmQQAAIAAAABLCQAAVwAAALESAABYAAAA2gQAAIAAAABvCQAAXQAAACMUAABUAAAARQUAAIAAAABUCgAAagAAAIwUAABqAAAArwUAAIAAAAB2CQAAfAAAAE4QAAB8AAAA0gIAAIAAAABjBwAAkQAAAJAHAACSAAAAAAAAAAEAAAABAAAABQAAAA0AAAAdAAAAPQAAAH0AAAD9AAAA/QEAAP0DAAD9BwAA/Q8AAP0fAAD9PwAA/X8AAP3/AAD9/wEA/f8DAP3/BwD9/w8A/f8fAP3/PwD9/38A/f//AP3//wH9//8D/f//B/3//w/9//8f/f//P/3//38AAAAAAQAAAAIAAAADAAAABAAAAAUAAAAGAAAABwAAAAgAAAAJAAAACgAAAAsAAAAMAAAADQAAAA4AAAAPAAAAEAAAABEAAAASAAAAEwAAABQAAAAVAAAAFgAAABcAAAAYAAAAGQAAABoAAAAbAAAAHAAAAB0AAAAeAAAAHwAAAAMAAAAEAAAABQAAAAYAAAAHAAAACAAAAAkAAAAKAAAACwAAAAwAAAANAAAADgAAAA8AAAAQAAAAEQAAABIAAAATAAAAFAAAABUAAAAWAAAAFwAAABgAAAAZAAAAGgAAABsAAAAcAAAAHQAAAB4AAAAfAAAAIAAAACEAAAAiAAAAIwAAACUAAAAnAAAAKQAAACsAAAAvAAAAMwAAADsAAABDAAAAUwAAAGMAAACDAAAAAwEAAAMCAAADBAAAAwgAAAMQAAADIAAAA0AAAAOAAAADAAEAQeAPC1EBAAAAAQAAAAEAAAABAAAAAgAAAAIAAAADAAAAAwAAAAQAAAAEAAAABQAAAAcAAAAIAAAACQAAAAoAAAALAAAADAAAAA0AAAAOAAAADwAAABAAQcQQC4sBAQAAAAIAAAADAAAABAAAAAUAAAAGAAAABwAAAAgAAAAJAAAACgAAAAsAAAAMAAAADQAAAA4AAAAPAAAAEAAAABIAAAAUAAAAFgAAABgAAAAcAAAAIAAAACgAAAAwAAAAQAAAAIAAAAAAAQAAAAIAAAAEAAAACAAAABAAAAAgAAAAQAAAAIAAAAAAAQBBkBIL5gQBAAAAAQAAAAEAAAABAAAAAgAAAAIAAAADAAAAAwAAAAQAAAAGAAAABwAAAAgAAAAJAAAACgAAAAsAAAAMAAAADQAAAA4AAAAPAAAAEAAAAAEAAAAEAAAACAAAAAAAAAABAAEBBgAAAAAAAAQAAAAAEAAABAAAAAAgAAAFAQAAAAAAAAUDAAAAAAAABQQAAAAAAAAFBgAAAAAAAAUHAAAAAAAABQkAAAAAAAAFCgAAAAAAAAUMAAAAAAAABg4AAAAAAAEFEAAAAAAAAQUUAAAAAAABBRYAAAAAAAIFHAAAAAAAAwUgAAAAAAAEBTAAAAAgAAYFQAAAAAAABwWAAAAAAAAIBgABAAAAAAoGAAQAAAAADAYAEAAAIAAABAAAAAAAAAAEAQAAAAAAAAUCAAAAIAAABQQAAAAAAAAFBQAAACAAAAUHAAAAAAAABQgAAAAgAAAFCgAAAAAAAAULAAAAAAAABg0AAAAgAAEFEAAAAAAAAQUSAAAAIAABBRYAAAAAAAIFGAAAACAAAwUgAAAAAAADBSgAAAAAAAYEQAAAABAABgRAAAAAIAAHBYAAAAAAAAkGAAIAAAAACwYACAAAMAAABAAAAAAQAAAEAQAAACAAAAUCAAAAIAAABQMAAAAgAAAFBQAAACAAAAUGAAAAIAAABQgAAAAgAAAFCQAAACAAAAULAAAAIAAABQwAAAAAAAAGDwAAACAAAQUSAAAAIAABBRQAAAAgAAIFGAAAACAAAgUcAAAAIAADBSgAAAAgAAQFMAAAAAAAEAYAAAEAAAAPBgCAAAAAAA4GAEAAAAAADQYAIABBgBcLhwIBAAEBBQAAAAAAAAUAAAAAAAAGBD0AAAAAAAkF/QEAAAAADwX9fwAAAAAVBf3/HwAAAAMFBQAAAAAABwR9AAAAAAAMBf0PAAAAABIF/f8DAAAAFwX9/38AAAAFBR0AAAAAAAgE/QAAAAAADgX9PwAAAAAUBf3/DwAAAAIFAQAAABAABwR9AAAAAAALBf0HAAAAABEF/f8BAAAAFgX9/z8AAAAEBQ0AAAAQAAgE/QAAAAAADQX9HwAAAAATBf3/BwAAAAEFAQAAABAABgQ9AAAAAAAKBf0DAAAAABAF/f8AAAAAHAX9//8PAAAbBf3//wcAABoF/f//AwAAGQX9//8BAAAYBf3//wBBkBkLhgQBAAEBBgAAAAAAAAYDAAAAAAAABAQAAAAgAAAFBQAAAAAAAAUGAAAAAAAABQgAAAAAAAAFCQAAAAAAAAULAAAAAAAABg0AAAAAAAAGEAAAAAAAAAYTAAAAAAAABhYAAAAAAAAGGQAAAAAAAAYcAAAAAAAABh8AAAAAAAAGIgAAAAAAAQYlAAAAAAABBikAAAAAAAIGLwAAAAAAAwY7AAAAAAAEBlMAAAAAAAcGgwAAAAAACQYDAgAAEAAABAQAAAAAAAAEBQAAACAAAAUGAAAAAAAABQcAAAAgAAAFCQAAAAAAAAUKAAAAAAAABgwAAAAAAAAGDwAAAAAAAAYSAAAAAAAABhUAAAAAAAAGGAAAAAAAAAYbAAAAAAAABh4AAAAAAAAGIQAAAAAAAQYjAAAAAAABBicAAAAAAAIGKwAAAAAAAwYzAAAAAAAEBkMAAAAAAAUGYwAAAAAACAYDAQAAIAAABAQAAAAwAAAEBAAAABAAAAQFAAAAIAAABQcAAAAgAAAFCAAAACAAAAUKAAAAIAAABQsAAAAAAAAGDgAAAAAAAAYRAAAAAAAABhQAAAAAAAAGFwAAAAAAAAYaAAAAAAAABh0AAAAAAAAGIAAAAAAAEAYDAAEAAAAPBgOAAAAAAA4GA0AAAAAADQYDIAAAAAAMBgMQAAAAAAsGAwgAAAAACgYDBABBpB0L2QEBAAAAAwAAAAcAAAAPAAAAHwAAAD8AAAB/AAAA/wAAAP8BAAD/AwAA/wcAAP8PAAD/HwAA/z8AAP9/AAD//wAA//8BAP//AwD//wcA//8PAP//HwD//z8A//9/AP///wD///8B////A////wf///8P////H////z////9/AAAAAAEAAAACAAAABAAAAAAAAAACAAAABAAAAAgAAAAAAAAAAQAAAAIAAAABAAAABAAAAAQAAAAEAAAABAAAAAgAAAAIAAAACAAAAAcAAAAIAAAACQAAAAoAAAALAEGgIAsDwBBQ",fA=new wA;class UA extends DA{constructor(u){super(),this.planarConfiguration=typeof u.PlanarConfiguration<"u"?u.PlanarConfiguration:1,this.samplesPerPixel=typeof u.SamplesPerPixel<"u"?u.SamplesPerPixel:1,this.addCompression=u.LercParameters[sA.AddCompression]}decodeBlock(u){switch(this.addCompression){case gA.None:break;case gA.Deflate:u=tA(new Uint8Array(u)).buffer;break;case gA.Zstandard:u=fA.decode(new Uint8Array(u)).buffer;break;default:throw new Error(`Unsupported LERC additional compression method identifier: ${this.addCompression}`)}return hA.decode(u,{returnPixelInterleavedDims:this.planarConfiguration===1}).pixels[0].buffer}}export{UA as default,fA as zstd}; +import{b as tA}from"./pako.esm-CB1uQYY0-DQSVoCko.js";import{o as sA,a as gA,x as rA}from"./EodashMap-BDE_gmHB.js";import{g as DA}from"./basedecoder-DHcBySSe-gdlnpIMU.js";import"./_commonjsHelpers-Cpj98o6Y.js";import"./helpers-CkhK5_6d.js";import"./index-Dvu417lt.js";var iA={exports:{}};(function(W){/* Copyright 2015-2021 Esri. Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 @preserve */(function(){var u=function(){var N={};N.defaultNoDataValue=-34027999387901484e22,N.decode=function(I,a){a=a||{};var Q=a.encodedMaskData||a.encodedMaskData===null,g=E(I,a.inputOffset||0,Q),r=a.noDataValue!==null?a.noDataValue:N.defaultNoDataValue,B=d(g,a.pixelType||Float32Array,a.encodedMaskData,r,a.returnMask),C={width:g.width,height:g.height,pixelData:B.resultPixels,minValue:B.minValue,maxValue:g.pixels.maxValue,noDataValue:r};return B.resultMask&&(C.maskData=B.resultMask),a.returnEncodedMask&&g.mask&&(C.encodedMaskData=g.mask.bitset?g.mask.bitset:null),a.returnFileInfo&&(C.fileInfo=m(g),a.computeUsedBitDepths&&(C.fileInfo.bitDepths=z(g))),C};var d=function(I,a,Q,g,r){var B=0,C=I.pixels.numBlocksX,t=I.pixels.numBlocksY,o=Math.floor(I.width/C),s=Math.floor(I.height/t),n=2*I.maxZError,e=Number.MAX_VALUE,i;Q=Q||(I.mask?I.mask.bitset:null);var h,y;h=new a(I.width*I.height),r&&Q&&(y=new Uint8Array(I.width*I.height));for(var S=new Float32Array(o*s),f,c,G=0;G<=t;G++){var M=G!==t?s:I.height%t;if(M!==0)for(var w=0;w<=C;w++){var D=w!==C?o:I.width%C;if(D!==0){var l=G*I.width*s+w*o,F=I.width-D,k=I.pixels.blocks[B],R,U,L;k.encoding<2?(k.encoding===0?R=k.rawData:(A(k.stuffedData,k.bitsPerPixel,k.numValidPixels,k.offset,n,S,I.pixels.maxValue),R=S),U=0):k.encoding===2?L=0:L=k.offset;var J;if(Q)for(c=0;c>3],J<<=l&7),f=0;f>3]),J&128?(y&&(y[l]=1),i=k.encoding<2?R[U++]:L,e=e>i?i:e,h[l++]=i):(y&&(y[l]=0),h[l++]=g),J<<=1;l+=F}else if(k.encoding<2)for(c=0;ci?i:e,h[l++]=i;l+=F}else for(e=e>L?L:e,c=0;c0){var C=new Uint8Array(Math.ceil(g.width*g.height/8));B=new DataView(I,a,g.mask.numBytes);var t=B.getInt16(0,!0),o=2,s=0;do{if(t>0)for(;t--;)C[s++]=B.getUint8(o++);else{var n=B.getUint8(o++);for(t=-t;t--;)C[s++]=n}t=B.getInt16(o,!0),o+=2}while(o0?1:0),y=i+(g.height%i>0?1:0);g.pixels.blocks=new Array(h*y);for(var S=0,f=0;f3)throw"Invalid block encoding ("+w.encoding+")";if(w.encoding===2){a++;continue}if(D!==0&&D!==2){if(D>>=6,w.offsetType=D,D===2)w.offset=B.getInt8(1),G++;else if(D===1)w.offset=B.getInt16(1,!0),G+=2;else if(D===0)w.offset=B.getFloat32(1,!0),G+=4;else throw"Invalid block offset type";if(w.encoding===1)if(D=B.getUint8(G),G++,w.bitsPerPixel=D&63,D>>=6,w.numValidPixelsType=D,D===2)w.numValidPixels=B.getUint8(G),G++;else if(D===1)w.numValidPixels=B.getUint16(G,!0),G+=2;else if(D===0)w.numValidPixels=B.getUint32(G,!0),G+=4;else throw"Invalid valid pixel count type"}if(a+=G,w.encoding!==3){var l,F;if(w.encoding===0){var k=(g.pixels.numBytes-1)/4;if(k!==Math.floor(k))throw"uncompressed block has invalid length";l=new ArrayBuffer(k*4),F=new Uint8Array(l),F.set(new Uint8Array(I,a,k*4));var R=new Float32Array(l);w.rawData=R,a+=k*4}else if(w.encoding===1){var U=Math.ceil(w.numValidPixels*w.bitsPerPixel/8),L=Math.ceil(U/4);l=new ArrayBuffer(L*4),F=new Uint8Array(l),F.set(new Uint8Array(I,a,U)),w.stuffedData=new Uint32Array(l),a+=U}}}return g.eofOffset=a,g},A=function(I,a,Q,g,r,B,C){var t=(1<=a)e=i>>>n-a&t,n-=a;else{var S=a-n;e=(i&t)<>>n}B[s]=e=I?(n=e>>>s-I&C,s-=I):(i=I-s,n=(e&C)<>>s),A[o]=Q[n];else for(h=Math.ceil((B-g)/r),o=0;o=I?(n=e>>>s-I&C,s-=I):(i=I-s,n=(e&C)<>>s),A[o]=n=A?(s=n>>>o-A&r,o-=A):(t=A-o,s=(n&r)<>>o),e[C]=s=I?(e=i>>>n&C,s-=I,n+=I):(h=I-s,e=i>>>n&C,i=E[t++],s=32-h,e|=(i&(1<=I?(e=i>>>n&C,s-=I,n+=I):(h=I-s,e=i>>>n&C,i=E[t++],s=32-h,e|=(i&(1<=A?(s=e>>>n&r,o-=A,n+=A):(t=A-o,s=e>>>n&r,e=E[B++],o=32-t,s|=(e&(1<=I?(C=t>>>B-I&Q,B-=I):(o=I-B,C=(t&Q)<>>B),A[r]=C;return A},originalUnstuff2:function(E,A,I,a){var Q=(1<=I?(t=o>>>C&Q,B-=I,C+=I):(s=I-B,t=o>>>C&Q,o=E[g++],B=32-s,t|=(o&(1<=359?359:Q;Q-=r;do A+=E[g++]<<8,I+=A+=E[g++];while(--r);A=(A&65535)+(A>>>16),I=(I&65535)+(I>>>16)}return a&1&&(I+=A+=E[g]<<8),A=(A&65535)+(A>>>16),I=(I&65535)+(I>>>16),(I<<16|A)>>>0},readHeaderInfo:function(E,A){var I=A.ptr,a=new Uint8Array(E,I,6),Q={};if(Q.fileIdentifierString=String.fromCharCode.apply(null,a),Q.fileIdentifierString.lastIndexOf("Lerc2",0)!==0)throw"Unexpected file identifier string (expect Lerc2 ): "+Q.fileIdentifierString;I+=6;var g=new DataView(E,I,8),r=g.getInt32(0,!0);Q.fileVersion=r,I+=4,r>=3&&(Q.checksum=g.getUint32(4,!0),I+=4),g=new DataView(E,I,12),Q.height=g.getUint32(0,!0),Q.width=g.getUint32(4,!0),I+=8,r>=4?(Q.numDims=g.getUint32(8,!0),I+=4):Q.numDims=1,g=new DataView(E,I,40),Q.numValidPixel=g.getUint32(0,!0),Q.microBlockSize=g.getInt32(4,!0),Q.blobSize=g.getInt32(8,!0),Q.imageType=g.getInt32(12,!0),Q.maxZError=g.getFloat64(16,!0),Q.zMin=g.getFloat64(24,!0),Q.zMax=g.getFloat64(32,!0),I+=40,A.headerInfo=Q,A.ptr=I;var B,C;if(r>=3&&(C=r>=4?52:48,B=this.computeChecksumFletcher32(new Uint8Array(E,I-C,Q.blobSize-14)),B!==Q.checksum))throw"Checksum failed.";return!0},checkMinMaxRanges:function(E,A){var I=A.headerInfo,a=this.getDataTypeArray(I.imageType),Q=I.numDims*this.getDataTypeSize(I.imageType),g=this.readSubArray(E,A.ptr,a,Q),r=this.readSubArray(E,A.ptr+Q,a,Q);A.ptr+=2*Q;var B,C=!0;for(B=0;B0){C=new Uint8Array(Math.ceil(Q/8)),r=new DataView(E,I,B.numBytes);var o=r.getInt16(0,!0),s=2,n=0,e=0;do{if(o>0)for(;o--;)C[n++]=r.getUint8(s++);else for(e=r.getUint8(s++),o=-o;o--;)C[n++]=e;o=r.getInt16(s,!0),s+=2}while(s>3],i<<=h&7):i=C[h>>3],i&128&&(t[h]=1);A.pixels.resultMask=t,B.bitset=C,I+=B.numBytes}return A.ptr=I,A.mask=B,!0},readDataOneSweep:function(E,A,I,a){var Q=A.ptr,g=A.headerInfo,r=g.numDims,B=g.width*g.height,C=g.imageType,t=g.numValidPixel*d.getDataTypeSize(C)*r,o,s=A.pixels.resultMask;if(I===Uint8Array)o=new Uint8Array(E,Q,t);else{var n=new ArrayBuffer(t),e=new Uint8Array(n);e.set(new Uint8Array(E,Q,t)),o=new I(n)}if(o.length===B*r)a?A.pixels.resultPixels=d.swapDimensionOrder(o,B,r,I,!0):A.pixels.resultPixels=o;else{A.pixels.resultPixels=new I(B*r);var i=0,h=0,y=0,S=0;if(r>1){if(a){for(h=0;h=B)return!1;var C=new Uint32Array(B-r);d.decodeBits(E,A,C);var t=[],o,s,n,e;for(o=r;o0&&(t[s].second=G<>>32-e,32-c>=e?(c+=e,c===32&&(c=0,M++,G=f[M])):(c+=e-32,M++,G=f[M],t[s].second|=G>>>32-c));var w=0,D=0,l=new m;for(o=0;o=I?D=I:D=w;var F=[],k,R,U,L,J,q;for(o=r;o0)if(k=[e,s],e<=D)for(R=t[s].second<=0;L--)J=R>>>L&1,J?(q.right||(q.right=new m),q=q.right):(q.left||(q.left=new m),q=q.left),L===0&&!q.val&&(q.val=k[1]);return{decodeLut:F,numBitsLUTQick:D,numBitsLUT:w,tree:l,stuffedData:f,srcPtr:M,bitPos:c}},readHuffman:function(E,A,I,a){var Q=A.headerInfo,g=Q.numDims,r=A.headerInfo.height,B=A.headerInfo.width,C=B*r,t=this.readHuffmanTree(E,A),o=t.decodeLut,s=t.tree,n=t.stuffedData,e=t.srcPtr,i=t.bitPos,h=t.numBitsLUTQick,y=t.numBitsLUT,S=A.headerInfo.imageType===0?128:0,f,c,G,M=A.pixels.resultMask,w,D,l,F,k,R,U,L=0;i>0&&(e++,i=0);var J=n[e],q=A.encodeMode===1,O=new I(C*g),p=O,Y;if(g<2||q){for(Y=0;Y1&&(p=new I(O.buffer,C*Y,C),L=0),A.headerInfo.numValidPixel===B*r)for(R=0,F=0;F>>32-h,D=w,32-i>>64-i-h,D=w),o[D])c=o[D][1],i+=o[D][0];else for(w=J<>>32-y,D=w,32-i>>64-i-y,D=w),f=s,U=0;U>>y-U-1&1,f=l?f.right:f.left,!(f.left||f.right)){c=f.val,i=i+U+1;break}i>=32&&(i-=32,e++,J=n[e]),G=c-S,q?(k>0?G+=L:F>0?G+=p[R-B]:G+=L,G&=255,p[R]=G,L=G):p[R]=G}else for(R=0,F=0;F>>32-h,D=w,32-i>>64-i-h,D=w),o[D])c=o[D][1],i+=o[D][0];else for(w=J<>>32-y,D=w,32-i>>64-i-y,D=w),f=s,U=0;U>>y-U-1&1,f=l?f.right:f.left,!(f.left||f.right)){c=f.val,i=i+U+1;break}i>=32&&(i-=32,e++,J=n[e]),G=c-S,q?(k>0&&M[R-1]?G+=L:F>0&&M[R-B]?G+=p[R-B]:G+=L,G&=255,p[R]=G,L=G):p[R]=G}}else for(R=0,F=0;F>>32-h,D=w,32-i>>64-i-h,D=w),o[D])c=o[D][1],i+=o[D][0];else for(w=J<>>32-y,D=w,32-i>>64-i-y,D=w),f=s,U=0;U>>y-U-1&1,f=l?f.right:f.left,!(f.left||f.right)){c=f.val,i=i+U+1;break}i>=32&&(i-=32,e++,J=n[e]),G=c-S,p[R]=G}A.ptr=A.ptr+(e+1)*4+(i>0?4:0),A.pixels.resultPixels=O,g>1&&!a&&(A.pixels.resultPixels=d.swapDimensionOrder(O,C,g,I))},decodeBits:function(E,A,I,a,Q){{var g=A.headerInfo,r=g.fileVersion,B=0,C=E.byteLength-A.ptr>=5?5:E.byteLength-A.ptr,t=new DataView(E,A.ptr,C),o=t.getUint8(0);B++;var s=o>>6,n=s===0?4:3-s,e=(o&32)>0,i=o&31,h=0;if(n===1)h=t.getUint8(B),B++;else if(n===2)h=t.getUint16(B,!0),B+=2;else if(n===4)h=t.getUint32(B,!0),B+=4;else throw"Invalid valid pixel count type";var y=2*g.maxZError,S,f,c,G,M,w,D,l,F,k=g.numDims>1?g.maxValues[Q]:g.zMax;if(e){for(A.counter.lut++,l=t.getUint8(B),B++,G=Math.ceil((l-1)*i/8),M=Math.ceil(G/4),f=new ArrayBuffer(M*4),c=new Uint8Array(f),A.ptr+=B,c.set(new Uint8Array(E,A.ptr,G)),D=new Uint32Array(f),A.ptr+=G,F=0;l-1>>>F;)F++;G=Math.ceil(h*F/8),M=Math.ceil(G/4),f=new ArrayBuffer(M*4),c=new Uint8Array(f),c.set(new Uint8Array(E,A.ptr,G)),S=new Uint32Array(f),A.ptr+=G,r>=3?w=N.unstuffLUT2(D,i,l-1,a,y,k):w=N.unstuffLUT(D,i,l-1,a,y,k),r>=3?N.unstuff2(S,I,F,h,w):N.unstuff(S,I,F,h,w)}else A.counter.bitstuffer++,F=i,A.ptr+=B,F>0&&(G=Math.ceil(h*F/8),M=Math.ceil(G/4),f=new ArrayBuffer(M*4),c=new Uint8Array(f),c.set(new Uint8Array(E,A.ptr,G)),S=new Uint32Array(f),A.ptr+=G,r>=3?a==null?N.originalUnstuff2(S,I,F,h):N.unstuff2(S,I,F,h,!1,a,y,k):a==null?N.originalUnstuff(S,I,F,h):N.unstuff(S,I,F,h,!1,a,y,k))}},readTiles:function(E,A,I,a){var Q=A.headerInfo,g=Q.width,r=Q.height,B=g*r,C=Q.microBlockSize,t=Q.imageType,o=d.getDataTypeSize(t),s=Math.ceil(g/C),n=Math.ceil(r/C);A.pixels.numBlocksY=n,A.pixels.numBlocksX=s,A.pixels.ptr=0;var e=0,i=0,h=0,y=0,S=0,f=0,c=0,G=0,M=0,w=0,D=0,l=0,F=0,k=0,R=0,U=0,L,J,q,O,p,Y,j=new I(C*C),eA=r%C||C,aA=g%C||C,AA,T,_=Q.numDims,X,H=A.pixels.resultMask,x=A.pixels.resultPixels,oA=Q.fileVersion,CA=oA>=5?14:15,V,IA=Q.zMax,b;for(h=0;h1?(b=x,D=h*g*C+y*C,x=new I(A.pixels.resultPixels.buffer,B*X*o,B),IA=Q.maxValues[X]):b=null,c=E.byteLength-A.ptr,L=new DataView(E,A.ptr,Math.min(10,c)),J={},U=0,G=L.getUint8(0),U++,V=Q.fileVersion>=5?G&4:0,M=G>>6&255,w=G>>2&CA,w!==(y*C>>3&CA)||V&&X===0)throw"integrity issue";if(Y=G&3,Y>3)throw A.ptr+=U,"Invalid block encoding ("+Y+")";if(Y===2){if(V)if(H)for(e=0;e1&&!a&&(A.pixels.resultPixels=d.swapDimensionOrder(A.pixels.resultPixels,B,_,I))},formatFileInfo:function(E){return{fileIdentifierString:E.headerInfo.fileIdentifierString,fileVersion:E.headerInfo.fileVersion,imageType:E.headerInfo.imageType,height:E.headerInfo.height,width:E.headerInfo.width,numValidPixel:E.headerInfo.numValidPixel,microBlockSize:E.headerInfo.microBlockSize,blobSize:E.headerInfo.blobSize,maxZError:E.headerInfo.maxZError,pixelType:d.getPixelType(E.headerInfo.imageType),eofOffset:E.eofOffset,mask:E.mask?{numBytes:E.mask.numBytes}:null,pixels:{numBlocksX:E.pixels.numBlocksX,numBlocksY:E.pixels.numBlocksY,maxValue:E.headerInfo.zMax,minValue:E.headerInfo.zMin,noDataValue:E.noDataValue}}},constructConstantSurface:function(E,A){var I=E.headerInfo.zMax,a=E.headerInfo.zMin,Q=E.headerInfo.maxValues,g=E.headerInfo.numDims,r=E.headerInfo.height*E.headerInfo.width,B=0,C=0,t=0,o=E.pixels.resultMask,s=E.pixels.resultPixels;if(o)if(g>1){if(A)for(B=0;B1&&a!==I)if(A)for(B=0;B=-128&&A<=127;break;case 1:I=A>=0&&A<=255;break;case 2:I=A>=-32768&&A<=32767;break;case 3:I=A>=0&&A<=65536;break;case 4:I=A>=-2147483648&&A<=2147483647;break;case 5:I=A>=0&&A<=4294967296;break;case 6:I=A>=-34027999387901484e22&&A<=34027999387901484e22;break;case 7:I=A>=-17976931348623157e292&&A<=17976931348623157e292;break;default:I=!1}return I},getDataTypeSize:function(E){var A=0;switch(E){case 0:case 1:A=1;break;case 2:case 3:A=2;break;case 4:case 5:case 6:A=4;break;case 7:A=8;break;default:A=E}return A},getDataTypeUsed:function(E,A){var I=E;switch(E){case 2:case 4:I=E-A;break;case 3:case 5:I=E-2*A;break;case 6:A===0?I=E:A===1?I=2:I=1;break;case 7:A===0?I=E:I=E-2*A+1;break;default:I=E;break}return I},getOnePixel:function(E,A,I,a){var Q=0;switch(I){case 0:Q=a.getInt8(A);break;case 1:Q=a.getUint8(A);break;case 2:Q=a.getInt16(A,!0);break;case 3:Q=a.getUint16(A,!0);break;case 4:Q=a.getInt32(A,!0);break;case 5:Q=a.getUInt32(A,!0);break;case 6:Q=a.getFloat32(A,!0);break;case 7:Q=a.getFloat64(A,!0);break;default:throw"the decoder does not understand this pixel type"}return Q},swapDimensionOrder:function(E,A,I,a,Q){var g=0,r=0,B=0,C=0,t=E;if(I>1)if(t=new a(A*I),Q)for(g=0;g5)throw"unsupported lerc version 2."+r;d.readMask(E,Q),g.numValidPixel!==g.width*g.height&&!Q.pixels.resultMask&&(Q.pixels.resultMask=A.maskData);var C=g.width*g.height;Q.pixels.resultPixels=new B(C*g.numDims),Q.counter={onesweep:0,uncompressed:0,lut:0,bitstuffer:0,constant:0,constantoffset:0};var t=!A.returnPixelInterleavedDims;if(g.numValidPixel!==0)if(g.zMax===g.zMin)d.constructConstantSurface(Q,t);else if(r>=4&&d.checkMinMaxRanges(E,Q))d.constructConstantSurface(Q,t);else{var o=new DataView(E,Q.ptr,2),s=o.getUint8(0);if(Q.ptr++,s)d.readDataOneSweep(E,Q,B,t);else if(r>1&&g.imageType<=1&&Math.abs(g.maxZError-.5)<1e-5){var n=o.getUint8(1);if(Q.ptr++,Q.encodeMode=n,n>2||r<4&&n>1)throw"Invalid Huffman flag "+n;n?d.readHuffman(E,Q,B,t):d.readTiles(E,Q,B,t)}else d.readTiles(E,Q,B,t)}Q.eofOffset=Q.ptr;var e;A.inputOffset?(e=Q.headerInfo.blobSize+A.inputOffset-Q.ptr,Math.abs(e)>=1&&(Q.eofOffset=A.inputOffset+Q.headerInfo.blobSize)):(e=Q.headerInfo.blobSize-Q.ptr,Math.abs(e)>=1&&(Q.eofOffset=Q.headerInfo.blobSize));var i={width:g.width,height:g.height,pixelData:Q.pixels.resultPixels,minValue:g.zMin,maxValue:g.zMax,validPixelCount:g.numValidPixel,dimCount:g.numDims,dimStats:{minValues:g.minValues,maxValues:g.maxValues},maskData:Q.pixels.resultMask};if(Q.pixels.resultMask&&d.isValidPixelValue(g.imageType,I)){var h=Q.pixels.resultMask;for(a=0;a1&&(C&&r.push(C),s.fileInfo.mask&&s.fileInfo.mask.numBytes>0&&o++),a++,t.pixels.push(s.pixelData),t.statistics.push({minValue:s.minValue,maxValue:s.maxValue,noDataValue:s.noDataValue,dimStats:s.dimStats})}var n,e,i;if(I>1&&o>1){for(i=t.width*t.height,t.bandMasks=r,C=new Uint8Array(i),C.set(r[0]),n=1;nu.arrayBuffer()).then(u=>WebAssembly.instantiate(u,BA)).then(this._init):$=WebAssembly.instantiate(Buffer.from(EA,"base64"),BA).then(this._init),$)}_init(u){K=u.instance,BA.env.emscripten_notify_memory_growth(0)}decode(u,P=0){if(!K)throw new Error("ZSTDDecoder: Await .init() before decoding.");const Z=u.byteLength,v=K.exports.malloc(Z);QA.set(u,v),P=P||Number(K.exports.ZSTD_findDecompressedSize(v,Z));const N=K.exports.malloc(P),d=K.exports.ZSTD_decompress(N,P,v,Z),m=QA.slice(N,N+d);return K.exports.free(v),K.exports.free(N),m}}const EA="AGFzbQEAAAABpQEVYAF/AX9gAn9/AGADf39/AX9gBX9/f39/AX9gAX8AYAJ/fwF/YAR/f39/AX9gA39/fwBgBn9/f39/fwF/YAd/f39/f39/AX9gAn9/AX5gAn5+AX5gAABgBX9/f39/AGAGf39/f39/AGAIf39/f39/f38AYAl/f39/f39/f38AYAABf2AIf39/f39/f38Bf2ANf39/f39/f39/f39/fwF/YAF/AX4CJwEDZW52H2Vtc2NyaXB0ZW5fbm90aWZ5X21lbW9yeV9ncm93dGgABANpaAEFAAAFAgEFCwACAQABAgIFBQcAAwABDgsBAQcAEhMHAAUBDAQEAAANBwQCAgYCBAgDAwMDBgEACQkHBgICAAYGAgQUBwYGAwIGAAMCAQgBBwUGCgoEEQAEBAEIAwgDBQgDEA8IAAcABAUBcAECAgUEAQCAAgYJAX8BQaCgwAILB2AHBm1lbW9yeQIABm1hbGxvYwAoBGZyZWUAJgxaU1REX2lzRXJyb3IAaBlaU1REX2ZpbmREZWNvbXByZXNzZWRTaXplAFQPWlNURF9kZWNvbXByZXNzAEoGX3N0YXJ0ACQJBwEAQQELASQKussBaA8AIAAgACgCBCABajYCBAsZACAAKAIAIAAoAgRBH3F0QQAgAWtBH3F2CwgAIABBiH9LC34BBH9BAyEBIAAoAgQiA0EgTQRAIAAoAggiASAAKAIQTwRAIAAQDQ8LIAAoAgwiAiABRgRAQQFBAiADQSBJGw8LIAAgASABIAJrIANBA3YiBCABIARrIAJJIgEbIgJrIgQ2AgggACADIAJBA3RrNgIEIAAgBCgAADYCAAsgAQsUAQF/IAAgARACIQIgACABEAEgAgv3AQECfyACRQRAIABCADcCACAAQQA2AhAgAEIANwIIQbh/DwsgACABNgIMIAAgAUEEajYCECACQQRPBEAgACABIAJqIgFBfGoiAzYCCCAAIAMoAAA2AgAgAUF/ai0AACIBBEAgAEEIIAEQFGs2AgQgAg8LIABBADYCBEF/DwsgACABNgIIIAAgAS0AACIDNgIAIAJBfmoiBEEBTQRAIARBAWtFBEAgACABLQACQRB0IANyIgM2AgALIAAgAS0AAUEIdCADajYCAAsgASACakF/ai0AACIBRQRAIABBADYCBEFsDwsgAEEoIAEQFCACQQN0ams2AgQgAgsWACAAIAEpAAA3AAAgACABKQAINwAICy8BAX8gAUECdEGgHWooAgAgACgCAEEgIAEgACgCBGprQR9xdnEhAiAAIAEQASACCyEAIAFCz9bTvtLHq9lCfiAAfEIfiUKHla+vmLbem55/fgsdAQF/IAAoAgggACgCDEYEfyAAKAIEQSBGBUEACwuCBAEDfyACQYDAAE8EQCAAIAEgAhBnIAAPCyAAIAJqIQMCQCAAIAFzQQNxRQRAAkAgAkEBSARAIAAhAgwBCyAAQQNxRQRAIAAhAgwBCyAAIQIDQCACIAEtAAA6AAAgAUEBaiEBIAJBAWoiAiADTw0BIAJBA3ENAAsLAkAgA0F8cSIEQcAASQ0AIAIgBEFAaiIFSw0AA0AgAiABKAIANgIAIAIgASgCBDYCBCACIAEoAgg2AgggAiABKAIMNgIMIAIgASgCEDYCECACIAEoAhQ2AhQgAiABKAIYNgIYIAIgASgCHDYCHCACIAEoAiA2AiAgAiABKAIkNgIkIAIgASgCKDYCKCACIAEoAiw2AiwgAiABKAIwNgIwIAIgASgCNDYCNCACIAEoAjg2AjggAiABKAI8NgI8IAFBQGshASACQUBrIgIgBU0NAAsLIAIgBE8NAQNAIAIgASgCADYCACABQQRqIQEgAkEEaiICIARJDQALDAELIANBBEkEQCAAIQIMAQsgA0F8aiIEIABJBEAgACECDAELIAAhAgNAIAIgAS0AADoAACACIAEtAAE6AAEgAiABLQACOgACIAIgAS0AAzoAAyABQQRqIQEgAkEEaiICIARNDQALCyACIANJBEADQCACIAEtAAA6AAAgAUEBaiEBIAJBAWoiAiADRw0ACwsgAAsMACAAIAEpAAA3AAALQQECfyAAKAIIIgEgACgCEEkEQEEDDwsgACAAKAIEIgJBB3E2AgQgACABIAJBA3ZrIgE2AgggACABKAAANgIAQQALDAAgACABKAIANgAAC/cCAQJ/AkAgACABRg0AAkAgASACaiAASwRAIAAgAmoiBCABSw0BCyAAIAEgAhALDwsgACABc0EDcSEDAkACQCAAIAFJBEAgAwRAIAAhAwwDCyAAQQNxRQRAIAAhAwwCCyAAIQMDQCACRQ0EIAMgAS0AADoAACABQQFqIQEgAkF/aiECIANBAWoiA0EDcQ0ACwwBCwJAIAMNACAEQQNxBEADQCACRQ0FIAAgAkF/aiICaiIDIAEgAmotAAA6AAAgA0EDcQ0ACwsgAkEDTQ0AA0AgACACQXxqIgJqIAEgAmooAgA2AgAgAkEDSw0ACwsgAkUNAgNAIAAgAkF/aiICaiABIAJqLQAAOgAAIAINAAsMAgsgAkEDTQ0AIAIhBANAIAMgASgCADYCACABQQRqIQEgA0EEaiEDIARBfGoiBEEDSw0ACyACQQNxIQILIAJFDQADQCADIAEtAAA6AAAgA0EBaiEDIAFBAWohASACQX9qIgINAAsLIAAL8wICAn8BfgJAIAJFDQAgACACaiIDQX9qIAE6AAAgACABOgAAIAJBA0kNACADQX5qIAE6AAAgACABOgABIANBfWogAToAACAAIAE6AAIgAkEHSQ0AIANBfGogAToAACAAIAE6AAMgAkEJSQ0AIABBACAAa0EDcSIEaiIDIAFB/wFxQYGChAhsIgE2AgAgAyACIARrQXxxIgRqIgJBfGogATYCACAEQQlJDQAgAyABNgIIIAMgATYCBCACQXhqIAE2AgAgAkF0aiABNgIAIARBGUkNACADIAE2AhggAyABNgIUIAMgATYCECADIAE2AgwgAkFwaiABNgIAIAJBbGogATYCACACQWhqIAE2AgAgAkFkaiABNgIAIAQgA0EEcUEYciIEayICQSBJDQAgAa0iBUIghiAFhCEFIAMgBGohAQNAIAEgBTcDGCABIAU3AxAgASAFNwMIIAEgBTcDACABQSBqIQEgAkFgaiICQR9LDQALCyAACy8BAn8gACgCBCAAKAIAQQJ0aiICLQACIQMgACACLwEAIAEgAi0AAxAIajYCACADCy8BAn8gACgCBCAAKAIAQQJ0aiICLQACIQMgACACLwEAIAEgAi0AAxAFajYCACADCx8AIAAgASACKAIEEAg2AgAgARAEGiAAIAJBCGo2AgQLCAAgAGdBH3MLugUBDX8jAEEQayIKJAACfyAEQQNNBEAgCkEANgIMIApBDGogAyAEEAsaIAAgASACIApBDGpBBBAVIgBBbCAAEAMbIAAgACAESxsMAQsgAEEAIAEoAgBBAXRBAmoQECENQVQgAygAACIGQQ9xIgBBCksNABogAiAAQQVqNgIAIAMgBGoiAkF8aiEMIAJBeWohDiACQXtqIRAgAEEGaiELQQQhBSAGQQR2IQRBICAAdCIAQQFyIQkgASgCACEPQQAhAiADIQYCQANAIAlBAkggAiAPS3JFBEAgAiEHAkAgCARAA0AgBEH//wNxQf//A0YEQCAHQRhqIQcgBiAQSQR/IAZBAmoiBigAACAFdgUgBUEQaiEFIARBEHYLIQQMAQsLA0AgBEEDcSIIQQNGBEAgBUECaiEFIARBAnYhBCAHQQNqIQcMAQsLIAcgCGoiByAPSw0EIAVBAmohBQNAIAIgB0kEQCANIAJBAXRqQQA7AQAgAkEBaiECDAELCyAGIA5LQQAgBiAFQQN1aiIHIAxLG0UEQCAHKAAAIAVBB3EiBXYhBAwCCyAEQQJ2IQQLIAYhBwsCfyALQX9qIAQgAEF/anEiBiAAQQF0QX9qIgggCWsiEUkNABogBCAIcSIEQQAgESAEIABIG2shBiALCyEIIA0gAkEBdGogBkF/aiIEOwEAIAlBASAGayAEIAZBAUgbayEJA0AgCSAASARAIABBAXUhACALQX9qIQsMAQsLAn8gByAOS0EAIAcgBSAIaiIFQQN1aiIGIAxLG0UEQCAFQQdxDAELIAUgDCIGIAdrQQN0awshBSACQQFqIQIgBEUhCCAGKAAAIAVBH3F2IQQMAQsLQWwgCUEBRyAFQSBKcg0BGiABIAJBf2o2AgAgBiAFQQdqQQN1aiADawwBC0FQCyEAIApBEGokACAACwkAQQFBBSAAGwsMACAAIAEoAAA2AAALqgMBCn8jAEHwAGsiCiQAIAJBAWohDiAAQQhqIQtBgIAEIAVBf2p0QRB1IQxBACECQQEhBkEBIAV0IglBf2oiDyEIA0AgAiAORkUEQAJAIAEgAkEBdCINai8BACIHQf//A0YEQCALIAhBA3RqIAI2AgQgCEF/aiEIQQEhBwwBCyAGQQAgDCAHQRB0QRB1ShshBgsgCiANaiAHOwEAIAJBAWohAgwBCwsgACAFNgIEIAAgBjYCACAJQQN2IAlBAXZqQQNqIQxBACEAQQAhBkEAIQIDQCAGIA5GBEADQAJAIAAgCUYNACAKIAsgAEEDdGoiASgCBCIGQQF0aiICIAIvAQAiAkEBajsBACABIAUgAhAUayIIOgADIAEgAiAIQf8BcXQgCWs7AQAgASAEIAZBAnQiAmooAgA6AAIgASACIANqKAIANgIEIABBAWohAAwBCwsFIAEgBkEBdGouAQAhDUEAIQcDQCAHIA1ORQRAIAsgAkEDdGogBjYCBANAIAIgDGogD3EiAiAISw0ACyAHQQFqIQcMAQsLIAZBAWohBgwBCwsgCkHwAGokAAsjAEIAIAEQCSAAhUKHla+vmLbem55/fkLj3MqV/M7y9YV/fAsQACAAQn43AwggACABNgIACyQBAX8gAARAIAEoAgQiAgRAIAEoAgggACACEQEADwsgABAmCwsfACAAIAEgAi8BABAINgIAIAEQBBogACACQQRqNgIEC0oBAX9BoCAoAgAiASAAaiIAQX9MBEBBiCBBMDYCAEF/DwsCQCAAPwBBEHRNDQAgABBmDQBBiCBBMDYCAEF/DwtBoCAgADYCACABC9cBAQh/Qbp/IQoCQCACKAIEIgggAigCACIJaiIOIAEgAGtLDQBBbCEKIAkgBCADKAIAIgtrSw0AIAAgCWoiBCACKAIIIgxrIQ0gACABQWBqIg8gCyAJQQAQKSADIAkgC2o2AgACQAJAIAwgBCAFa00EQCANIQUMAQsgDCAEIAZrSw0CIAcgDSAFayIAaiIBIAhqIAdNBEAgBCABIAgQDxoMAgsgBCABQQAgAGsQDyEBIAIgACAIaiIINgIEIAEgAGshBAsgBCAPIAUgCEEBECkLIA4hCgsgCgubAgEBfyMAQYABayINJAAgDSADNgJ8AkAgAkEDSwRAQX8hCQwBCwJAAkACQAJAIAJBAWsOAwADAgELIAZFBEBBuH8hCQwEC0FsIQkgBS0AACICIANLDQMgACAHIAJBAnQiAmooAgAgAiAIaigCABA7IAEgADYCAEEBIQkMAwsgASAJNgIAQQAhCQwCCyAKRQRAQWwhCQwCC0EAIQkgC0UgDEEZSHINAUEIIAR0QQhqIQBBACECA0AgAiAATw0CIAJBQGshAgwAAAsAC0FsIQkgDSANQfwAaiANQfgAaiAFIAYQFSICEAMNACANKAJ4IgMgBEsNACAAIA0gDSgCfCAHIAggAxAYIAEgADYCACACIQkLIA1BgAFqJAAgCQsLACAAIAEgAhALGgsQACAALwAAIAAtAAJBEHRyCy8AAn9BuH8gAUEISQ0AGkFyIAAoAAQiAEF3Sw0AGkG4fyAAQQhqIgAgACABSxsLCwkAIAAgATsAAAsDAAELigYBBX8gACAAKAIAIgVBfnE2AgBBACAAIAVBAXZqQYQgKAIAIgQgAEYbIQECQAJAIAAoAgQiAkUNACACKAIAIgNBAXENACACQQhqIgUgA0EBdkF4aiIDQQggA0EISxtnQR9zQQJ0QYAfaiIDKAIARgRAIAMgAigCDDYCAAsgAigCCCIDBEAgAyACKAIMNgIECyACKAIMIgMEQCADIAIoAgg2AgALIAIgAigCACAAKAIAQX5xajYCAEGEICEAAkACQCABRQ0AIAEgAjYCBCABKAIAIgNBAXENASADQQF2QXhqIgNBCCADQQhLG2dBH3NBAnRBgB9qIgMoAgAgAUEIakYEQCADIAEoAgw2AgALIAEoAggiAwRAIAMgASgCDDYCBAsgASgCDCIDBEAgAyABKAIINgIAQYQgKAIAIQQLIAIgAigCACABKAIAQX5xajYCACABIARGDQAgASABKAIAQQF2akEEaiEACyAAIAI2AgALIAIoAgBBAXZBeGoiAEEIIABBCEsbZ0Efc0ECdEGAH2oiASgCACEAIAEgBTYCACACIAA2AgwgAkEANgIIIABFDQEgACAFNgIADwsCQCABRQ0AIAEoAgAiAkEBcQ0AIAJBAXZBeGoiAkEIIAJBCEsbZ0Efc0ECdEGAH2oiAigCACABQQhqRgRAIAIgASgCDDYCAAsgASgCCCICBEAgAiABKAIMNgIECyABKAIMIgIEQCACIAEoAgg2AgBBhCAoAgAhBAsgACAAKAIAIAEoAgBBfnFqIgI2AgACQCABIARHBEAgASABKAIAQQF2aiAANgIEIAAoAgAhAgwBC0GEICAANgIACyACQQF2QXhqIgFBCCABQQhLG2dBH3NBAnRBgB9qIgIoAgAhASACIABBCGoiAjYCACAAIAE2AgwgAEEANgIIIAFFDQEgASACNgIADwsgBUEBdkF4aiIBQQggAUEISxtnQR9zQQJ0QYAfaiICKAIAIQEgAiAAQQhqIgI2AgAgACABNgIMIABBADYCCCABRQ0AIAEgAjYCAAsLDgAgAARAIABBeGoQJQsLgAIBA38CQCAAQQ9qQXhxQYQgKAIAKAIAQQF2ayICEB1Bf0YNAAJAQYQgKAIAIgAoAgAiAUEBcQ0AIAFBAXZBeGoiAUEIIAFBCEsbZ0Efc0ECdEGAH2oiASgCACAAQQhqRgRAIAEgACgCDDYCAAsgACgCCCIBBEAgASAAKAIMNgIECyAAKAIMIgFFDQAgASAAKAIINgIAC0EBIQEgACAAKAIAIAJBAXRqIgI2AgAgAkEBcQ0AIAJBAXZBeGoiAkEIIAJBCEsbZ0Efc0ECdEGAH2oiAygCACECIAMgAEEIaiIDNgIAIAAgAjYCDCAAQQA2AgggAkUNACACIAM2AgALIAELtwIBA38CQAJAIABBASAAGyICEDgiAA0AAkACQEGEICgCACIARQ0AIAAoAgAiA0EBcQ0AIAAgA0EBcjYCACADQQF2QXhqIgFBCCABQQhLG2dBH3NBAnRBgB9qIgEoAgAgAEEIakYEQCABIAAoAgw2AgALIAAoAggiAQRAIAEgACgCDDYCBAsgACgCDCIBBEAgASAAKAIINgIACyACECchAkEAIQFBhCAoAgAhACACDQEgACAAKAIAQX5xNgIAQQAPCyACQQ9qQXhxIgMQHSICQX9GDQIgAkEHakF4cSIAIAJHBEAgACACaxAdQX9GDQMLAkBBhCAoAgAiAUUEQEGAICAANgIADAELIAAgATYCBAtBhCAgADYCACAAIANBAXRBAXI2AgAMAQsgAEUNAQsgAEEIaiEBCyABC7kDAQJ/IAAgA2ohBQJAIANBB0wEQANAIAAgBU8NAiAAIAItAAA6AAAgAEEBaiEAIAJBAWohAgwAAAsACyAEQQFGBEACQCAAIAJrIgZBB00EQCAAIAItAAA6AAAgACACLQABOgABIAAgAi0AAjoAAiAAIAItAAM6AAMgAEEEaiACIAZBAnQiBkHAHmooAgBqIgIQFyACIAZB4B5qKAIAayECDAELIAAgAhAMCyACQQhqIQIgAEEIaiEACwJAAkACQAJAIAUgAU0EQCAAIANqIQEgBEEBRyAAIAJrQQ9Kcg0BA0AgACACEAwgAkEIaiECIABBCGoiACABSQ0ACwwFCyAAIAFLBEAgACEBDAQLIARBAUcgACACa0EPSnINASAAIQMgAiEEA0AgAyAEEAwgBEEIaiEEIANBCGoiAyABSQ0ACwwCCwNAIAAgAhAHIAJBEGohAiAAQRBqIgAgAUkNAAsMAwsgACEDIAIhBANAIAMgBBAHIARBEGohBCADQRBqIgMgAUkNAAsLIAIgASAAa2ohAgsDQCABIAVPDQEgASACLQAAOgAAIAFBAWohASACQQFqIQIMAAALAAsLQQECfyAAIAAoArjgASIDNgLE4AEgACgCvOABIQQgACABNgK84AEgACABIAJqNgK44AEgACABIAQgA2tqNgLA4AELpgEBAX8gACAAKALs4QEQFjYCyOABIABCADcD+OABIABCADcDuOABIABBwOABakIANwMAIABBqNAAaiIBQYyAgOAANgIAIABBADYCmOIBIABCADcDiOEBIABCAzcDgOEBIABBrNABakHgEikCADcCACAAQbTQAWpB6BIoAgA2AgAgACABNgIMIAAgAEGYIGo2AgggACAAQaAwajYCBCAAIABBEGo2AgALYQEBf0G4fyEDAkAgAUEDSQ0AIAIgABAhIgFBA3YiADYCCCACIAFBAXE2AgQgAiABQQF2QQNxIgM2AgACQCADQX9qIgFBAksNAAJAIAFBAWsOAgEAAgtBbA8LIAAhAwsgAwsMACAAIAEgAkEAEC4LiAQCA38CfiADEBYhBCAAQQBBKBAQIQAgBCACSwRAIAQPCyABRQRAQX8PCwJAAkAgA0EBRg0AIAEoAAAiBkGo6r5pRg0AQXYhAyAGQXBxQdDUtMIBRw0BQQghAyACQQhJDQEgAEEAQSgQECEAIAEoAAQhASAAQQE2AhQgACABrTcDAEEADwsgASACIAMQLyIDIAJLDQAgACADNgIYQXIhAyABIARqIgVBf2otAAAiAkEIcQ0AIAJBIHEiBkUEQEFwIQMgBS0AACIFQacBSw0BIAVBB3GtQgEgBUEDdkEKaq2GIgdCA4h+IAd8IQggBEEBaiEECyACQQZ2IQMgAkECdiEFAkAgAkEDcUF/aiICQQJLBEBBACECDAELAkACQAJAIAJBAWsOAgECAAsgASAEai0AACECIARBAWohBAwCCyABIARqLwAAIQIgBEECaiEEDAELIAEgBGooAAAhAiAEQQRqIQQLIAVBAXEhBQJ+AkACQAJAIANBf2oiA0ECTQRAIANBAWsOAgIDAQtCfyAGRQ0DGiABIARqMQAADAMLIAEgBGovAACtQoACfAwCCyABIARqKAAArQwBCyABIARqKQAACyEHIAAgBTYCICAAIAI2AhwgACAHNwMAQQAhAyAAQQA2AhQgACAHIAggBhsiBzcDCCAAIAdCgIAIIAdCgIAIVBs+AhALIAMLWwEBf0G4fyEDIAIQFiICIAFNBH8gACACakF/ai0AACIAQQNxQQJ0QaAeaigCACACaiAAQQZ2IgFBAnRBsB5qKAIAaiAAQSBxIgBFaiABRSAAQQV2cWoFQbh/CwsdACAAKAKQ4gEQWiAAQQA2AqDiASAAQgA3A5DiAQu1AwEFfyMAQZACayIKJABBuH8hBgJAIAVFDQAgBCwAACIIQf8BcSEHAkAgCEF/TARAIAdBgn9qQQF2IgggBU8NAkFsIQYgB0GBf2oiBUGAAk8NAiAEQQFqIQdBACEGA0AgBiAFTwRAIAUhBiAIIQcMAwUgACAGaiAHIAZBAXZqIgQtAABBBHY6AAAgACAGQQFyaiAELQAAQQ9xOgAAIAZBAmohBgwBCwAACwALIAcgBU8NASAAIARBAWogByAKEFMiBhADDQELIAYhBEEAIQYgAUEAQTQQECEJQQAhBQNAIAQgBkcEQCAAIAZqIggtAAAiAUELSwRAQWwhBgwDBSAJIAFBAnRqIgEgASgCAEEBajYCACAGQQFqIQZBASAILQAAdEEBdSAFaiEFDAILAAsLQWwhBiAFRQ0AIAUQFEEBaiIBQQxLDQAgAyABNgIAQQFBASABdCAFayIDEBQiAXQgA0cNACAAIARqIAFBAWoiADoAACAJIABBAnRqIgAgACgCAEEBajYCACAJKAIEIgBBAkkgAEEBcXINACACIARBAWo2AgAgB0EBaiEGCyAKQZACaiQAIAYLxhEBDH8jAEHwAGsiBSQAQWwhCwJAIANBCkkNACACLwAAIQogAi8AAiEJIAIvAAQhByAFQQhqIAQQDgJAIAMgByAJIApqakEGaiIMSQ0AIAUtAAohCCAFQdgAaiACQQZqIgIgChAGIgsQAw0BIAVBQGsgAiAKaiICIAkQBiILEAMNASAFQShqIAIgCWoiAiAHEAYiCxADDQEgBUEQaiACIAdqIAMgDGsQBiILEAMNASAAIAFqIg9BfWohECAEQQRqIQZBASELIAAgAUEDakECdiIDaiIMIANqIgIgA2oiDiEDIAIhBCAMIQcDQCALIAMgEElxBEAgACAGIAVB2ABqIAgQAkECdGoiCS8BADsAACAFQdgAaiAJLQACEAEgCS0AAyELIAcgBiAFQUBrIAgQAkECdGoiCS8BADsAACAFQUBrIAktAAIQASAJLQADIQogBCAGIAVBKGogCBACQQJ0aiIJLwEAOwAAIAVBKGogCS0AAhABIAktAAMhCSADIAYgBUEQaiAIEAJBAnRqIg0vAQA7AAAgBUEQaiANLQACEAEgDS0AAyENIAAgC2oiCyAGIAVB2ABqIAgQAkECdGoiAC8BADsAACAFQdgAaiAALQACEAEgAC0AAyEAIAcgCmoiCiAGIAVBQGsgCBACQQJ0aiIHLwEAOwAAIAVBQGsgBy0AAhABIActAAMhByAEIAlqIgkgBiAFQShqIAgQAkECdGoiBC8BADsAACAFQShqIAQtAAIQASAELQADIQQgAyANaiIDIAYgBUEQaiAIEAJBAnRqIg0vAQA7AAAgBUEQaiANLQACEAEgACALaiEAIAcgCmohByAEIAlqIQQgAyANLQADaiEDIAVB2ABqEA0gBUFAaxANciAFQShqEA1yIAVBEGoQDXJFIQsMAQsLIAQgDksgByACS3INAEFsIQsgACAMSw0BIAxBfWohCQNAQQAgACAJSSAFQdgAahAEGwRAIAAgBiAFQdgAaiAIEAJBAnRqIgovAQA7AAAgBUHYAGogCi0AAhABIAAgCi0AA2oiACAGIAVB2ABqIAgQAkECdGoiCi8BADsAACAFQdgAaiAKLQACEAEgACAKLQADaiEADAEFIAxBfmohCgNAIAVB2ABqEAQgACAKS3JFBEAgACAGIAVB2ABqIAgQAkECdGoiCS8BADsAACAFQdgAaiAJLQACEAEgACAJLQADaiEADAELCwNAIAAgCk0EQCAAIAYgBUHYAGogCBACQQJ0aiIJLwEAOwAAIAVB2ABqIAktAAIQASAAIAktAANqIQAMAQsLAkAgACAMTw0AIAAgBiAFQdgAaiAIEAIiAEECdGoiDC0AADoAACAMLQADQQFGBEAgBUHYAGogDC0AAhABDAELIAUoAlxBH0sNACAFQdgAaiAGIABBAnRqLQACEAEgBSgCXEEhSQ0AIAVBIDYCXAsgAkF9aiEMA0BBACAHIAxJIAVBQGsQBBsEQCAHIAYgBUFAayAIEAJBAnRqIgAvAQA7AAAgBUFAayAALQACEAEgByAALQADaiIAIAYgBUFAayAIEAJBAnRqIgcvAQA7AAAgBUFAayAHLQACEAEgACAHLQADaiEHDAEFIAJBfmohDANAIAVBQGsQBCAHIAxLckUEQCAHIAYgBUFAayAIEAJBAnRqIgAvAQA7AAAgBUFAayAALQACEAEgByAALQADaiEHDAELCwNAIAcgDE0EQCAHIAYgBUFAayAIEAJBAnRqIgAvAQA7AAAgBUFAayAALQACEAEgByAALQADaiEHDAELCwJAIAcgAk8NACAHIAYgBUFAayAIEAIiAEECdGoiAi0AADoAACACLQADQQFGBEAgBUFAayACLQACEAEMAQsgBSgCREEfSw0AIAVBQGsgBiAAQQJ0ai0AAhABIAUoAkRBIUkNACAFQSA2AkQLIA5BfWohAgNAQQAgBCACSSAFQShqEAQbBEAgBCAGIAVBKGogCBACQQJ0aiIALwEAOwAAIAVBKGogAC0AAhABIAQgAC0AA2oiACAGIAVBKGogCBACQQJ0aiIELwEAOwAAIAVBKGogBC0AAhABIAAgBC0AA2ohBAwBBSAOQX5qIQIDQCAFQShqEAQgBCACS3JFBEAgBCAGIAVBKGogCBACQQJ0aiIALwEAOwAAIAVBKGogAC0AAhABIAQgAC0AA2ohBAwBCwsDQCAEIAJNBEAgBCAGIAVBKGogCBACQQJ0aiIALwEAOwAAIAVBKGogAC0AAhABIAQgAC0AA2ohBAwBCwsCQCAEIA5PDQAgBCAGIAVBKGogCBACIgBBAnRqIgItAAA6AAAgAi0AA0EBRgRAIAVBKGogAi0AAhABDAELIAUoAixBH0sNACAFQShqIAYgAEECdGotAAIQASAFKAIsQSFJDQAgBUEgNgIsCwNAQQAgAyAQSSAFQRBqEAQbBEAgAyAGIAVBEGogCBACQQJ0aiIALwEAOwAAIAVBEGogAC0AAhABIAMgAC0AA2oiACAGIAVBEGogCBACQQJ0aiICLwEAOwAAIAVBEGogAi0AAhABIAAgAi0AA2ohAwwBBSAPQX5qIQIDQCAFQRBqEAQgAyACS3JFBEAgAyAGIAVBEGogCBACQQJ0aiIALwEAOwAAIAVBEGogAC0AAhABIAMgAC0AA2ohAwwBCwsDQCADIAJNBEAgAyAGIAVBEGogCBACQQJ0aiIALwEAOwAAIAVBEGogAC0AAhABIAMgAC0AA2ohAwwBCwsCQCADIA9PDQAgAyAGIAVBEGogCBACIgBBAnRqIgItAAA6AAAgAi0AA0EBRgRAIAVBEGogAi0AAhABDAELIAUoAhRBH0sNACAFQRBqIAYgAEECdGotAAIQASAFKAIUQSFJDQAgBUEgNgIUCyABQWwgBUHYAGoQCiAFQUBrEApxIAVBKGoQCnEgBUEQahAKcRshCwwJCwAACwALAAALAAsAAAsACwAACwALQWwhCwsgBUHwAGokACALC7UEAQ5/IwBBEGsiBiQAIAZBBGogABAOQVQhBQJAIARB3AtJDQAgBi0ABCEHIANB8ARqQQBB7AAQECEIIAdBDEsNACADQdwJaiIJIAggBkEIaiAGQQxqIAEgAhAxIhAQA0UEQCAGKAIMIgQgB0sNASADQdwFaiEPIANBpAVqIREgAEEEaiESIANBqAVqIQEgBCEFA0AgBSICQX9qIQUgCCACQQJ0aigCAEUNAAsgAkEBaiEOQQEhBQNAIAUgDk9FBEAgCCAFQQJ0IgtqKAIAIQwgASALaiAKNgIAIAVBAWohBSAKIAxqIQoMAQsLIAEgCjYCAEEAIQUgBigCCCELA0AgBSALRkUEQCABIAUgCWotAAAiDEECdGoiDSANKAIAIg1BAWo2AgAgDyANQQF0aiINIAw6AAEgDSAFOgAAIAVBAWohBQwBCwtBACEBIANBADYCqAUgBEF/cyAHaiEJQQEhBQNAIAUgDk9FBEAgCCAFQQJ0IgtqKAIAIQwgAyALaiABNgIAIAwgBSAJanQgAWohASAFQQFqIQUMAQsLIAcgBEEBaiIBIAJrIgRrQQFqIQgDQEEBIQUgBCAIT0UEQANAIAUgDk9FBEAgBUECdCIJIAMgBEE0bGpqIAMgCWooAgAgBHY2AgAgBUEBaiEFDAELCyAEQQFqIQQMAQsLIBIgByAPIAogESADIAIgARBkIAZBAToABSAGIAc6AAYgACAGKAIENgIACyAQIQULIAZBEGokACAFC8ENAQt/IwBB8ABrIgUkAEFsIQkCQCADQQpJDQAgAi8AACEKIAIvAAIhDCACLwAEIQYgBUEIaiAEEA4CQCADIAYgCiAMampBBmoiDUkNACAFLQAKIQcgBUHYAGogAkEGaiICIAoQBiIJEAMNASAFQUBrIAIgCmoiAiAMEAYiCRADDQEgBUEoaiACIAxqIgIgBhAGIgkQAw0BIAVBEGogAiAGaiADIA1rEAYiCRADDQEgACABaiIOQX1qIQ8gBEEEaiEGQQEhCSAAIAFBA2pBAnYiAmoiCiACaiIMIAJqIg0hAyAMIQQgCiECA0AgCSADIA9JcQRAIAYgBUHYAGogBxACQQF0aiIILQAAIQsgBUHYAGogCC0AARABIAAgCzoAACAGIAVBQGsgBxACQQF0aiIILQAAIQsgBUFAayAILQABEAEgAiALOgAAIAYgBUEoaiAHEAJBAXRqIggtAAAhCyAFQShqIAgtAAEQASAEIAs6AAAgBiAFQRBqIAcQAkEBdGoiCC0AACELIAVBEGogCC0AARABIAMgCzoAACAGIAVB2ABqIAcQAkEBdGoiCC0AACELIAVB2ABqIAgtAAEQASAAIAs6AAEgBiAFQUBrIAcQAkEBdGoiCC0AACELIAVBQGsgCC0AARABIAIgCzoAASAGIAVBKGogBxACQQF0aiIILQAAIQsgBUEoaiAILQABEAEgBCALOgABIAYgBUEQaiAHEAJBAXRqIggtAAAhCyAFQRBqIAgtAAEQASADIAs6AAEgA0ECaiEDIARBAmohBCACQQJqIQIgAEECaiEAIAkgBUHYAGoQDUVxIAVBQGsQDUVxIAVBKGoQDUVxIAVBEGoQDUVxIQkMAQsLIAQgDUsgAiAMS3INAEFsIQkgACAKSw0BIApBfWohCQNAIAVB2ABqEAQgACAJT3JFBEAgBiAFQdgAaiAHEAJBAXRqIggtAAAhCyAFQdgAaiAILQABEAEgACALOgAAIAYgBUHYAGogBxACQQF0aiIILQAAIQsgBUHYAGogCC0AARABIAAgCzoAASAAQQJqIQAMAQsLA0AgBUHYAGoQBCAAIApPckUEQCAGIAVB2ABqIAcQAkEBdGoiCS0AACEIIAVB2ABqIAktAAEQASAAIAg6AAAgAEEBaiEADAELCwNAIAAgCkkEQCAGIAVB2ABqIAcQAkEBdGoiCS0AACEIIAVB2ABqIAktAAEQASAAIAg6AAAgAEEBaiEADAELCyAMQX1qIQADQCAFQUBrEAQgAiAAT3JFBEAgBiAFQUBrIAcQAkEBdGoiCi0AACEJIAVBQGsgCi0AARABIAIgCToAACAGIAVBQGsgBxACQQF0aiIKLQAAIQkgBUFAayAKLQABEAEgAiAJOgABIAJBAmohAgwBCwsDQCAFQUBrEAQgAiAMT3JFBEAgBiAFQUBrIAcQAkEBdGoiAC0AACEKIAVBQGsgAC0AARABIAIgCjoAACACQQFqIQIMAQsLA0AgAiAMSQRAIAYgBUFAayAHEAJBAXRqIgAtAAAhCiAFQUBrIAAtAAEQASACIAo6AAAgAkEBaiECDAELCyANQX1qIQADQCAFQShqEAQgBCAAT3JFBEAgBiAFQShqIAcQAkEBdGoiAi0AACEKIAVBKGogAi0AARABIAQgCjoAACAGIAVBKGogBxACQQF0aiICLQAAIQogBUEoaiACLQABEAEgBCAKOgABIARBAmohBAwBCwsDQCAFQShqEAQgBCANT3JFBEAgBiAFQShqIAcQAkEBdGoiAC0AACECIAVBKGogAC0AARABIAQgAjoAACAEQQFqIQQMAQsLA0AgBCANSQRAIAYgBUEoaiAHEAJBAXRqIgAtAAAhAiAFQShqIAAtAAEQASAEIAI6AAAgBEEBaiEEDAELCwNAIAVBEGoQBCADIA9PckUEQCAGIAVBEGogBxACQQF0aiIALQAAIQIgBUEQaiAALQABEAEgAyACOgAAIAYgBUEQaiAHEAJBAXRqIgAtAAAhAiAFQRBqIAAtAAEQASADIAI6AAEgA0ECaiEDDAELCwNAIAVBEGoQBCADIA5PckUEQCAGIAVBEGogBxACQQF0aiIALQAAIQIgBUEQaiAALQABEAEgAyACOgAAIANBAWohAwwBCwsDQCADIA5JBEAgBiAFQRBqIAcQAkEBdGoiAC0AACECIAVBEGogAC0AARABIAMgAjoAACADQQFqIQMMAQsLIAFBbCAFQdgAahAKIAVBQGsQCnEgBUEoahAKcSAFQRBqEApxGyEJDAELQWwhCQsgBUHwAGokACAJC8oCAQR/IwBBIGsiBSQAIAUgBBAOIAUtAAIhByAFQQhqIAIgAxAGIgIQA0UEQCAEQQRqIQIgACABaiIDQX1qIQQDQCAFQQhqEAQgACAET3JFBEAgAiAFQQhqIAcQAkEBdGoiBi0AACEIIAVBCGogBi0AARABIAAgCDoAACACIAVBCGogBxACQQF0aiIGLQAAIQggBUEIaiAGLQABEAEgACAIOgABIABBAmohAAwBCwsDQCAFQQhqEAQgACADT3JFBEAgAiAFQQhqIAcQAkEBdGoiBC0AACEGIAVBCGogBC0AARABIAAgBjoAACAAQQFqIQAMAQsLA0AgACADT0UEQCACIAVBCGogBxACQQF0aiIELQAAIQYgBUEIaiAELQABEAEgACAGOgAAIABBAWohAAwBCwsgAUFsIAVBCGoQChshAgsgBUEgaiQAIAILtgMBCX8jAEEQayIGJAAgBkEANgIMIAZBADYCCEFUIQQCQAJAIANBQGsiDCADIAZBCGogBkEMaiABIAIQMSICEAMNACAGQQRqIAAQDiAGKAIMIgcgBi0ABEEBaksNASAAQQRqIQogBkEAOgAFIAYgBzoABiAAIAYoAgQ2AgAgB0EBaiEJQQEhBANAIAQgCUkEQCADIARBAnRqIgEoAgAhACABIAU2AgAgACAEQX9qdCAFaiEFIARBAWohBAwBCwsgB0EBaiEHQQAhBSAGKAIIIQkDQCAFIAlGDQEgAyAFIAxqLQAAIgRBAnRqIgBBASAEdEEBdSILIAAoAgAiAWoiADYCACAHIARrIQhBACEEAkAgC0EDTQRAA0AgBCALRg0CIAogASAEakEBdGoiACAIOgABIAAgBToAACAEQQFqIQQMAAALAAsDQCABIABPDQEgCiABQQF0aiIEIAg6AAEgBCAFOgAAIAQgCDoAAyAEIAU6AAIgBCAIOgAFIAQgBToABCAEIAg6AAcgBCAFOgAGIAFBBGohAQwAAAsACyAFQQFqIQUMAAALAAsgAiEECyAGQRBqJAAgBAutAQECfwJAQYQgKAIAIABHIAAoAgBBAXYiAyABa0F4aiICQXhxQQhHcgR/IAIFIAMQJ0UNASACQQhqC0EQSQ0AIAAgACgCACICQQFxIAAgAWpBD2pBeHEiASAAa0EBdHI2AgAgASAANgIEIAEgASgCAEEBcSAAIAJBAXZqIAFrIgJBAXRyNgIAQYQgIAEgAkH/////B3FqQQRqQYQgKAIAIABGGyABNgIAIAEQJQsLygIBBX8CQAJAAkAgAEEIIABBCEsbZ0EfcyAAaUEBR2oiAUEESSAAIAF2cg0AIAFBAnRB/B5qKAIAIgJFDQADQCACQXhqIgMoAgBBAXZBeGoiBSAATwRAIAIgBUEIIAVBCEsbZ0Efc0ECdEGAH2oiASgCAEYEQCABIAIoAgQ2AgALDAMLIARBHksNASAEQQFqIQQgAigCBCICDQALC0EAIQMgAUEgTw0BA0AgAUECdEGAH2ooAgAiAkUEQCABQR5LIQIgAUEBaiEBIAJFDQEMAwsLIAIgAkF4aiIDKAIAQQF2QXhqIgFBCCABQQhLG2dBH3NBAnRBgB9qIgEoAgBGBEAgASACKAIENgIACwsgAigCACIBBEAgASACKAIENgIECyACKAIEIgEEQCABIAIoAgA2AgALIAMgAygCAEEBcjYCACADIAAQNwsgAwvhCwINfwV+IwBB8ABrIgckACAHIAAoAvDhASIINgJcIAEgAmohDSAIIAAoAoDiAWohDwJAAkAgBUUEQCABIQQMAQsgACgCxOABIRAgACgCwOABIREgACgCvOABIQ4gAEEBNgKM4QFBACEIA0AgCEEDRwRAIAcgCEECdCICaiAAIAJqQazQAWooAgA2AkQgCEEBaiEIDAELC0FsIQwgB0EYaiADIAQQBhADDQEgB0EsaiAHQRhqIAAoAgAQEyAHQTRqIAdBGGogACgCCBATIAdBPGogB0EYaiAAKAIEEBMgDUFgaiESIAEhBEEAIQwDQCAHKAIwIAcoAixBA3RqKQIAIhRCEIinQf8BcSEIIAcoAkAgBygCPEEDdGopAgAiFUIQiKdB/wFxIQsgBygCOCAHKAI0QQN0aikCACIWQiCIpyEJIBVCIIghFyAUQiCIpyECAkAgFkIQiKdB/wFxIgNBAk8EQAJAIAZFIANBGUlyRQRAIAkgB0EYaiADQSAgBygCHGsiCiAKIANLGyIKEAUgAyAKayIDdGohCSAHQRhqEAQaIANFDQEgB0EYaiADEAUgCWohCQwBCyAHQRhqIAMQBSAJaiEJIAdBGGoQBBoLIAcpAkQhGCAHIAk2AkQgByAYNwNIDAELAkAgA0UEQCACBEAgBygCRCEJDAMLIAcoAkghCQwBCwJAAkAgB0EYakEBEAUgCSACRWpqIgNBA0YEQCAHKAJEQX9qIgMgA0VqIQkMAQsgA0ECdCAHaigCRCIJIAlFaiEJIANBAUYNAQsgByAHKAJINgJMCwsgByAHKAJENgJIIAcgCTYCRAsgF6chAyALBEAgB0EYaiALEAUgA2ohAwsgCCALakEUTwRAIAdBGGoQBBoLIAgEQCAHQRhqIAgQBSACaiECCyAHQRhqEAQaIAcgB0EYaiAUQhiIp0H/AXEQCCAUp0H//wNxajYCLCAHIAdBGGogFUIYiKdB/wFxEAggFadB//8DcWo2AjwgB0EYahAEGiAHIAdBGGogFkIYiKdB/wFxEAggFqdB//8DcWo2AjQgByACNgJgIAcoAlwhCiAHIAk2AmggByADNgJkAkACQAJAIAQgAiADaiILaiASSw0AIAIgCmoiEyAPSw0AIA0gBGsgC0Egak8NAQsgByAHKQNoNwMQIAcgBykDYDcDCCAEIA0gB0EIaiAHQdwAaiAPIA4gESAQEB4hCwwBCyACIARqIQggBCAKEAcgAkERTwRAIARBEGohAgNAIAIgCkEQaiIKEAcgAkEQaiICIAhJDQALCyAIIAlrIQIgByATNgJcIAkgCCAOa0sEQCAJIAggEWtLBEBBbCELDAILIBAgAiAOayICaiIKIANqIBBNBEAgCCAKIAMQDxoMAgsgCCAKQQAgAmsQDyEIIAcgAiADaiIDNgJkIAggAmshCCAOIQILIAlBEE8EQCADIAhqIQMDQCAIIAIQByACQRBqIQIgCEEQaiIIIANJDQALDAELAkAgCUEHTQRAIAggAi0AADoAACAIIAItAAE6AAEgCCACLQACOgACIAggAi0AAzoAAyAIQQRqIAIgCUECdCIDQcAeaigCAGoiAhAXIAIgA0HgHmooAgBrIQIgBygCZCEDDAELIAggAhAMCyADQQlJDQAgAyAIaiEDIAhBCGoiCCACQQhqIgJrQQ9MBEADQCAIIAIQDCACQQhqIQIgCEEIaiIIIANJDQAMAgALAAsDQCAIIAIQByACQRBqIQIgCEEQaiIIIANJDQALCyAHQRhqEAQaIAsgDCALEAMiAhshDCAEIAQgC2ogAhshBCAFQX9qIgUNAAsgDBADDQFBbCEMIAdBGGoQBEECSQ0BQQAhCANAIAhBA0cEQCAAIAhBAnQiAmpBrNABaiACIAdqKAJENgIAIAhBAWohCAwBCwsgBygCXCEIC0G6fyEMIA8gCGsiACANIARrSw0AIAQEfyAEIAggABALIABqBUEACyABayEMCyAHQfAAaiQAIAwLkRcCFn8FfiMAQdABayIHJAAgByAAKALw4QEiCDYCvAEgASACaiESIAggACgCgOIBaiETAkACQCAFRQRAIAEhAwwBCyAAKALE4AEhESAAKALA4AEhFSAAKAK84AEhDyAAQQE2AozhAUEAIQgDQCAIQQNHBEAgByAIQQJ0IgJqIAAgAmpBrNABaigCADYCVCAIQQFqIQgMAQsLIAcgETYCZCAHIA82AmAgByABIA9rNgJoQWwhECAHQShqIAMgBBAGEAMNASAFQQQgBUEESBshFyAHQTxqIAdBKGogACgCABATIAdBxABqIAdBKGogACgCCBATIAdBzABqIAdBKGogACgCBBATQQAhBCAHQeAAaiEMIAdB5ABqIQoDQCAHQShqEARBAksgBCAXTnJFBEAgBygCQCAHKAI8QQN0aikCACIdQhCIp0H/AXEhCyAHKAJQIAcoAkxBA3RqKQIAIh5CEIinQf8BcSEJIAcoAkggBygCREEDdGopAgAiH0IgiKchCCAeQiCIISAgHUIgiKchAgJAIB9CEIinQf8BcSIDQQJPBEACQCAGRSADQRlJckUEQCAIIAdBKGogA0EgIAcoAixrIg0gDSADSxsiDRAFIAMgDWsiA3RqIQggB0EoahAEGiADRQ0BIAdBKGogAxAFIAhqIQgMAQsgB0EoaiADEAUgCGohCCAHQShqEAQaCyAHKQJUISEgByAINgJUIAcgITcDWAwBCwJAIANFBEAgAgRAIAcoAlQhCAwDCyAHKAJYIQgMAQsCQAJAIAdBKGpBARAFIAggAkVqaiIDQQNGBEAgBygCVEF/aiIDIANFaiEIDAELIANBAnQgB2ooAlQiCCAIRWohCCADQQFGDQELIAcgBygCWDYCXAsLIAcgBygCVDYCWCAHIAg2AlQLICCnIQMgCQRAIAdBKGogCRAFIANqIQMLIAkgC2pBFE8EQCAHQShqEAQaCyALBEAgB0EoaiALEAUgAmohAgsgB0EoahAEGiAHIAcoAmggAmoiCSADajYCaCAKIAwgCCAJSxsoAgAhDSAHIAdBKGogHUIYiKdB/wFxEAggHadB//8DcWo2AjwgByAHQShqIB5CGIinQf8BcRAIIB6nQf//A3FqNgJMIAdBKGoQBBogB0EoaiAfQhiIp0H/AXEQCCEOIAdB8ABqIARBBHRqIgsgCSANaiAIazYCDCALIAg2AgggCyADNgIEIAsgAjYCACAHIA4gH6dB//8DcWo2AkQgBEEBaiEEDAELCyAEIBdIDQEgEkFgaiEYIAdB4ABqIRogB0HkAGohGyABIQMDQCAHQShqEARBAksgBCAFTnJFBEAgBygCQCAHKAI8QQN0aikCACIdQhCIp0H/AXEhCyAHKAJQIAcoAkxBA3RqKQIAIh5CEIinQf8BcSEIIAcoAkggBygCREEDdGopAgAiH0IgiKchCSAeQiCIISAgHUIgiKchDAJAIB9CEIinQf8BcSICQQJPBEACQCAGRSACQRlJckUEQCAJIAdBKGogAkEgIAcoAixrIgogCiACSxsiChAFIAIgCmsiAnRqIQkgB0EoahAEGiACRQ0BIAdBKGogAhAFIAlqIQkMAQsgB0EoaiACEAUgCWohCSAHQShqEAQaCyAHKQJUISEgByAJNgJUIAcgITcDWAwBCwJAIAJFBEAgDARAIAcoAlQhCQwDCyAHKAJYIQkMAQsCQAJAIAdBKGpBARAFIAkgDEVqaiICQQNGBEAgBygCVEF/aiICIAJFaiEJDAELIAJBAnQgB2ooAlQiCSAJRWohCSACQQFGDQELIAcgBygCWDYCXAsLIAcgBygCVDYCWCAHIAk2AlQLICCnIRQgCARAIAdBKGogCBAFIBRqIRQLIAggC2pBFE8EQCAHQShqEAQaCyALBEAgB0EoaiALEAUgDGohDAsgB0EoahAEGiAHIAcoAmggDGoiGSAUajYCaCAbIBogCSAZSxsoAgAhHCAHIAdBKGogHUIYiKdB/wFxEAggHadB//8DcWo2AjwgByAHQShqIB5CGIinQf8BcRAIIB6nQf//A3FqNgJMIAdBKGoQBBogByAHQShqIB9CGIinQf8BcRAIIB+nQf//A3FqNgJEIAcgB0HwAGogBEEDcUEEdGoiDSkDCCIdNwPIASAHIA0pAwAiHjcDwAECQAJAAkAgBygCvAEiDiAepyICaiIWIBNLDQAgAyAHKALEASIKIAJqIgtqIBhLDQAgEiADayALQSBqTw0BCyAHIAcpA8gBNwMQIAcgBykDwAE3AwggAyASIAdBCGogB0G8AWogEyAPIBUgERAeIQsMAQsgAiADaiEIIAMgDhAHIAJBEU8EQCADQRBqIQIDQCACIA5BEGoiDhAHIAJBEGoiAiAISQ0ACwsgCCAdpyIOayECIAcgFjYCvAEgDiAIIA9rSwRAIA4gCCAVa0sEQEFsIQsMAgsgESACIA9rIgJqIhYgCmogEU0EQCAIIBYgChAPGgwCCyAIIBZBACACaxAPIQggByACIApqIgo2AsQBIAggAmshCCAPIQILIA5BEE8EQCAIIApqIQoDQCAIIAIQByACQRBqIQIgCEEQaiIIIApJDQALDAELAkAgDkEHTQRAIAggAi0AADoAACAIIAItAAE6AAEgCCACLQACOgACIAggAi0AAzoAAyAIQQRqIAIgDkECdCIKQcAeaigCAGoiAhAXIAIgCkHgHmooAgBrIQIgBygCxAEhCgwBCyAIIAIQDAsgCkEJSQ0AIAggCmohCiAIQQhqIgggAkEIaiICa0EPTARAA0AgCCACEAwgAkEIaiECIAhBCGoiCCAKSQ0ADAIACwALA0AgCCACEAcgAkEQaiECIAhBEGoiCCAKSQ0ACwsgCxADBEAgCyEQDAQFIA0gDDYCACANIBkgHGogCWs2AgwgDSAJNgIIIA0gFDYCBCAEQQFqIQQgAyALaiEDDAILAAsLIAQgBUgNASAEIBdrIQtBACEEA0AgCyAFSARAIAcgB0HwAGogC0EDcUEEdGoiAikDCCIdNwPIASAHIAIpAwAiHjcDwAECQAJAAkAgBygCvAEiDCAepyICaiIKIBNLDQAgAyAHKALEASIJIAJqIhBqIBhLDQAgEiADayAQQSBqTw0BCyAHIAcpA8gBNwMgIAcgBykDwAE3AxggAyASIAdBGGogB0G8AWogEyAPIBUgERAeIRAMAQsgAiADaiEIIAMgDBAHIAJBEU8EQCADQRBqIQIDQCACIAxBEGoiDBAHIAJBEGoiAiAISQ0ACwsgCCAdpyIGayECIAcgCjYCvAEgBiAIIA9rSwRAIAYgCCAVa0sEQEFsIRAMAgsgESACIA9rIgJqIgwgCWogEU0EQCAIIAwgCRAPGgwCCyAIIAxBACACaxAPIQggByACIAlqIgk2AsQBIAggAmshCCAPIQILIAZBEE8EQCAIIAlqIQYDQCAIIAIQByACQRBqIQIgCEEQaiIIIAZJDQALDAELAkAgBkEHTQRAIAggAi0AADoAACAIIAItAAE6AAEgCCACLQACOgACIAggAi0AAzoAAyAIQQRqIAIgBkECdCIGQcAeaigCAGoiAhAXIAIgBkHgHmooAgBrIQIgBygCxAEhCQwBCyAIIAIQDAsgCUEJSQ0AIAggCWohBiAIQQhqIgggAkEIaiICa0EPTARAA0AgCCACEAwgAkEIaiECIAhBCGoiCCAGSQ0ADAIACwALA0AgCCACEAcgAkEQaiECIAhBEGoiCCAGSQ0ACwsgEBADDQMgC0EBaiELIAMgEGohAwwBCwsDQCAEQQNHBEAgACAEQQJ0IgJqQazQAWogAiAHaigCVDYCACAEQQFqIQQMAQsLIAcoArwBIQgLQbp/IRAgEyAIayIAIBIgA2tLDQAgAwR/IAMgCCAAEAsgAGoFQQALIAFrIRALIAdB0AFqJAAgEAslACAAQgA3AgAgAEEAOwEIIABBADoACyAAIAE2AgwgACACOgAKC7QFAQN/IwBBMGsiBCQAIABB/wFqIgVBfWohBgJAIAMvAQIEQCAEQRhqIAEgAhAGIgIQAw0BIARBEGogBEEYaiADEBwgBEEIaiAEQRhqIAMQHCAAIQMDQAJAIARBGGoQBCADIAZPckUEQCADIARBEGogBEEYahASOgAAIAMgBEEIaiAEQRhqEBI6AAEgBEEYahAERQ0BIANBAmohAwsgBUF+aiEFAn8DQEG6fyECIAMiASAFSw0FIAEgBEEQaiAEQRhqEBI6AAAgAUEBaiEDIARBGGoQBEEDRgRAQQIhAiAEQQhqDAILIAMgBUsNBSABIARBCGogBEEYahASOgABIAFBAmohA0EDIQIgBEEYahAEQQNHDQALIARBEGoLIQUgAyAFIARBGGoQEjoAACABIAJqIABrIQIMAwsgAyAEQRBqIARBGGoQEjoAAiADIARBCGogBEEYahASOgADIANBBGohAwwAAAsACyAEQRhqIAEgAhAGIgIQAw0AIARBEGogBEEYaiADEBwgBEEIaiAEQRhqIAMQHCAAIQMDQAJAIARBGGoQBCADIAZPckUEQCADIARBEGogBEEYahAROgAAIAMgBEEIaiAEQRhqEBE6AAEgBEEYahAERQ0BIANBAmohAwsgBUF+aiEFAn8DQEG6fyECIAMiASAFSw0EIAEgBEEQaiAEQRhqEBE6AAAgAUEBaiEDIARBGGoQBEEDRgRAQQIhAiAEQQhqDAILIAMgBUsNBCABIARBCGogBEEYahAROgABIAFBAmohA0EDIQIgBEEYahAEQQNHDQALIARBEGoLIQUgAyAFIARBGGoQEToAACABIAJqIABrIQIMAgsgAyAEQRBqIARBGGoQEToAAiADIARBCGogBEEYahAROgADIANBBGohAwwAAAsACyAEQTBqJAAgAgtpAQF/An8CQAJAIAJBB00NACABKAAAQbfIwuF+Rw0AIAAgASgABDYCmOIBQWIgAEEQaiABIAIQPiIDEAMNAhogAEKBgICAEDcDiOEBIAAgASADaiACIANrECoMAQsgACABIAIQKgtBAAsLrQMBBn8jAEGAAWsiAyQAQWIhCAJAIAJBCUkNACAAQZjQAGogAUEIaiIEIAJBeGogAEGY0AAQMyIFEAMiBg0AIANBHzYCfCADIANB/ABqIANB+ABqIAQgBCAFaiAGGyIEIAEgAmoiAiAEaxAVIgUQAw0AIAMoAnwiBkEfSw0AIAMoAngiB0EJTw0AIABBiCBqIAMgBkGAC0GADCAHEBggA0E0NgJ8IAMgA0H8AGogA0H4AGogBCAFaiIEIAIgBGsQFSIFEAMNACADKAJ8IgZBNEsNACADKAJ4IgdBCk8NACAAQZAwaiADIAZBgA1B4A4gBxAYIANBIzYCfCADIANB/ABqIANB+ABqIAQgBWoiBCACIARrEBUiBRADDQAgAygCfCIGQSNLDQAgAygCeCIHQQpPDQAgACADIAZBwBBB0BEgBxAYIAQgBWoiBEEMaiIFIAJLDQAgAiAFayEFQQAhAgNAIAJBA0cEQCAEKAAAIgZBf2ogBU8NAiAAIAJBAnRqQZzQAWogBjYCACACQQFqIQIgBEEEaiEEDAELCyAEIAFrIQgLIANBgAFqJAAgCAtGAQN/IABBCGohAyAAKAIEIQJBACEAA0AgACACdkUEQCABIAMgAEEDdGotAAJBFktqIQEgAEEBaiEADAELCyABQQggAmt0C4YDAQV/Qbh/IQcCQCADRQ0AIAItAAAiBEUEQCABQQA2AgBBAUG4fyADQQFGGw8LAn8gAkEBaiIFIARBGHRBGHUiBkF/Sg0AGiAGQX9GBEAgA0EDSA0CIAUvAABBgP4BaiEEIAJBA2oMAQsgA0ECSA0BIAItAAEgBEEIdHJBgIB+aiEEIAJBAmoLIQUgASAENgIAIAVBAWoiASACIANqIgNLDQBBbCEHIABBEGogACAFLQAAIgVBBnZBI0EJIAEgAyABa0HAEEHQEUHwEiAAKAKM4QEgACgCnOIBIAQQHyIGEAMiCA0AIABBmCBqIABBCGogBUEEdkEDcUEfQQggASABIAZqIAgbIgEgAyABa0GAC0GADEGAFyAAKAKM4QEgACgCnOIBIAQQHyIGEAMiCA0AIABBoDBqIABBBGogBUECdkEDcUE0QQkgASABIAZqIAgbIgEgAyABa0GADUHgDkGQGSAAKAKM4QEgACgCnOIBIAQQHyIAEAMNACAAIAFqIAJrIQcLIAcLrQMBCn8jAEGABGsiCCQAAn9BUiACQf8BSw0AGkFUIANBDEsNABogAkEBaiELIABBBGohCUGAgAQgA0F/anRBEHUhCkEAIQJBASEEQQEgA3QiB0F/aiIMIQUDQCACIAtGRQRAAkAgASACQQF0Ig1qLwEAIgZB//8DRgRAIAkgBUECdGogAjoAAiAFQX9qIQVBASEGDAELIARBACAKIAZBEHRBEHVKGyEECyAIIA1qIAY7AQAgAkEBaiECDAELCyAAIAQ7AQIgACADOwEAIAdBA3YgB0EBdmpBA2ohBkEAIQRBACECA0AgBCALRkUEQCABIARBAXRqLgEAIQpBACEAA0AgACAKTkUEQCAJIAJBAnRqIAQ6AAIDQCACIAZqIAxxIgIgBUsNAAsgAEEBaiEADAELCyAEQQFqIQQMAQsLQX8gAg0AGkEAIQIDfyACIAdGBH9BAAUgCCAJIAJBAnRqIgAtAAJBAXRqIgEgAS8BACIBQQFqOwEAIAAgAyABEBRrIgU6AAMgACABIAVB/wFxdCAHazsBACACQQFqIQIMAQsLCyEFIAhBgARqJAAgBQvjBgEIf0FsIQcCQCACQQNJDQACQAJAAkACQCABLQAAIgNBA3EiCUEBaw4DAwEAAgsgACgCiOEBDQBBYg8LIAJBBUkNAkEDIQYgASgAACEFAn8CQAJAIANBAnZBA3EiCEF+aiIEQQFNBEAgBEEBaw0BDAILIAVBDnZB/wdxIQQgBUEEdkH/B3EhAyAIRQwCCyAFQRJ2IQRBBCEGIAVBBHZB//8AcSEDQQAMAQsgBUEEdkH//w9xIgNBgIAISw0DIAEtAARBCnQgBUEWdnIhBEEFIQZBAAshBSAEIAZqIgogAksNAgJAIANBgQZJDQAgACgCnOIBRQ0AQQAhAgNAIAJBg4ABSw0BIAJBQGshAgwAAAsACwJ/IAlBA0YEQCABIAZqIQEgAEHw4gFqIQIgACgCDCEGIAUEQCACIAMgASAEIAYQXwwCCyACIAMgASAEIAYQXQwBCyAAQbjQAWohAiABIAZqIQEgAEHw4gFqIQYgAEGo0ABqIQggBQRAIAggBiADIAEgBCACEF4MAQsgCCAGIAMgASAEIAIQXAsQAw0CIAAgAzYCgOIBIABBATYCiOEBIAAgAEHw4gFqNgLw4QEgCUECRgRAIAAgAEGo0ABqNgIMCyAAIANqIgBBiOMBakIANwAAIABBgOMBakIANwAAIABB+OIBakIANwAAIABB8OIBakIANwAAIAoPCwJ/AkACQAJAIANBAnZBA3FBf2oiBEECSw0AIARBAWsOAgACAQtBASEEIANBA3YMAgtBAiEEIAEvAABBBHYMAQtBAyEEIAEQIUEEdgsiAyAEaiIFQSBqIAJLBEAgBSACSw0CIABB8OIBaiABIARqIAMQCyEBIAAgAzYCgOIBIAAgATYC8OEBIAEgA2oiAEIANwAYIABCADcAECAAQgA3AAggAEIANwAAIAUPCyAAIAM2AoDiASAAIAEgBGo2AvDhASAFDwsCfwJAAkACQCADQQJ2QQNxQX9qIgRBAksNACAEQQFrDgIAAgELQQEhByADQQN2DAILQQIhByABLwAAQQR2DAELIAJBBEkgARAhIgJBj4CAAUtyDQFBAyEHIAJBBHYLIQIgAEHw4gFqIAEgB2otAAAgAkEgahAQIQEgACACNgKA4gEgACABNgLw4QEgB0EBaiEHCyAHC0sAIABC+erQ0OfJoeThADcDICAAQgA3AxggAELP1tO+0ser2UI3AxAgAELW64Lu6v2J9eAANwMIIABCADcDACAAQShqQQBBKBAQGgviAgICfwV+IABBKGoiASAAKAJIaiECAn4gACkDACIDQiBaBEAgACkDECIEQgeJIAApAwgiBUIBiXwgACkDGCIGQgyJfCAAKQMgIgdCEol8IAUQGSAEEBkgBhAZIAcQGQwBCyAAKQMYQsXP2bLx5brqJ3wLIAN8IQMDQCABQQhqIgAgAk0EQEIAIAEpAAAQCSADhUIbiUKHla+vmLbem55/fkLj3MqV/M7y9YV/fCEDIAAhAQwBCwsCQCABQQRqIgAgAksEQCABIQAMAQsgASgAAK1Ch5Wvr5i23puef34gA4VCF4lCz9bTvtLHq9lCfkL5893xmfaZqxZ8IQMLA0AgACACSQRAIAAxAABCxc/ZsvHluuonfiADhUILiUKHla+vmLbem55/fiEDIABBAWohAAwBCwsgA0IhiCADhULP1tO+0ser2UJ+IgNCHYggA4VC+fPd8Zn2masWfiIDQiCIIAOFC+8CAgJ/BH4gACAAKQMAIAKtfDcDAAJAAkAgACgCSCIDIAJqIgRBH00EQCABRQ0BIAAgA2pBKGogASACECAgACgCSCACaiEEDAELIAEgAmohAgJ/IAMEQCAAQShqIgQgA2ogAUEgIANrECAgACAAKQMIIAQpAAAQCTcDCCAAIAApAxAgACkAMBAJNwMQIAAgACkDGCAAKQA4EAk3AxggACAAKQMgIABBQGspAAAQCTcDICAAKAJIIQMgAEEANgJIIAEgA2tBIGohAQsgAUEgaiACTQsEQCACQWBqIQMgACkDICEFIAApAxghBiAAKQMQIQcgACkDCCEIA0AgCCABKQAAEAkhCCAHIAEpAAgQCSEHIAYgASkAEBAJIQYgBSABKQAYEAkhBSABQSBqIgEgA00NAAsgACAFNwMgIAAgBjcDGCAAIAc3AxAgACAINwMICyABIAJPDQEgAEEoaiABIAIgAWsiBBAgCyAAIAQ2AkgLCy8BAX8gAEUEQEG2f0EAIAMbDwtBun8hBCADIAFNBH8gACACIAMQEBogAwVBun8LCy8BAX8gAEUEQEG2f0EAIAMbDwtBun8hBCADIAFNBH8gACACIAMQCxogAwVBun8LC6gCAQZ/IwBBEGsiByQAIABB2OABaikDAEKAgIAQViEIQbh/IQUCQCAEQf//B0sNACAAIAMgBBBCIgUQAyIGDQAgACgCnOIBIQkgACAHQQxqIAMgAyAFaiAGGyIKIARBACAFIAYbayIGEEAiAxADBEAgAyEFDAELIAcoAgwhBCABRQRAQbp/IQUgBEEASg0BCyAGIANrIQUgAyAKaiEDAkAgCQRAIABBADYCnOIBDAELAkACQAJAIARBBUgNACAAQdjgAWopAwBCgICACFgNAAwBCyAAQQA2ApziAQwBCyAAKAIIED8hBiAAQQA2ApziASAGQRRPDQELIAAgASACIAMgBSAEIAgQOSEFDAELIAAgASACIAMgBSAEIAgQOiEFCyAHQRBqJAAgBQtnACAAQdDgAWogASACIAAoAuzhARAuIgEQAwRAIAEPC0G4fyECAkAgAQ0AIABB7OABaigCACIBBEBBYCECIAAoApjiASABRw0BC0EAIQIgAEHw4AFqKAIARQ0AIABBkOEBahBDCyACCycBAX8QVyIERQRAQUAPCyAEIAAgASACIAMgBBBLEE8hACAEEFYgAAs/AQF/AkACQAJAIAAoAqDiAUEBaiIBQQJLDQAgAUEBaw4CAAECCyAAEDBBAA8LIABBADYCoOIBCyAAKAKU4gELvAMCB38BfiMAQRBrIgkkAEG4fyEGAkAgBCgCACIIQQVBCSAAKALs4QEiBRtJDQAgAygCACIHQQFBBSAFGyAFEC8iBRADBEAgBSEGDAELIAggBUEDakkNACAAIAcgBRBJIgYQAw0AIAEgAmohCiAAQZDhAWohCyAIIAVrIQIgBSAHaiEHIAEhBQNAIAcgAiAJECwiBhADDQEgAkF9aiICIAZJBEBBuH8hBgwCCyAJKAIAIghBAksEQEFsIQYMAgsgB0EDaiEHAn8CQAJAAkAgCEEBaw4CAgABCyAAIAUgCiAFayAHIAYQSAwCCyAFIAogBWsgByAGEEcMAQsgBSAKIAVrIActAAAgCSgCCBBGCyIIEAMEQCAIIQYMAgsgACgC8OABBEAgCyAFIAgQRQsgAiAGayECIAYgB2ohByAFIAhqIQUgCSgCBEUNAAsgACkD0OABIgxCf1IEQEFsIQYgDCAFIAFrrFINAQsgACgC8OABBEBBaiEGIAJBBEkNASALEEQhDCAHKAAAIAynRw0BIAdBBGohByACQXxqIQILIAMgBzYCACAEIAI2AgAgBSABayEGCyAJQRBqJAAgBgsuACAAECsCf0EAQQAQAw0AGiABRSACRXJFBEBBYiAAIAEgAhA9EAMNARoLQQALCzcAIAEEQCAAIAAoAsTgASABKAIEIAEoAghqRzYCnOIBCyAAECtBABADIAFFckUEQCAAIAEQWwsL0QIBB38jAEEQayIGJAAgBiAENgIIIAYgAzYCDCAFBEAgBSgCBCEKIAUoAgghCQsgASEIAkACQANAIAAoAuzhARAWIQsCQANAIAQgC0kNASADKAAAQXBxQdDUtMIBRgRAIAMgBBAiIgcQAw0EIAQgB2shBCADIAdqIQMMAQsLIAYgAzYCDCAGIAQ2AggCQCAFBEAgACAFEE5BACEHQQAQA0UNAQwFCyAAIAogCRBNIgcQAw0ECyAAIAgQUCAMQQFHQQAgACAIIAIgBkEMaiAGQQhqEEwiByIDa0EAIAMQAxtBCkdyRQRAQbh/IQcMBAsgBxADDQMgAiAHayECIAcgCGohCEEBIQwgBigCDCEDIAYoAgghBAwBCwsgBiADNgIMIAYgBDYCCEG4fyEHIAQNASAIIAFrIQcMAQsgBiADNgIMIAYgBDYCCAsgBkEQaiQAIAcLRgECfyABIAAoArjgASICRwRAIAAgAjYCxOABIAAgATYCuOABIAAoArzgASEDIAAgATYCvOABIAAgASADIAJrajYCwOABCwutAgIEfwF+IwBBQGoiBCQAAkACQCACQQhJDQAgASgAAEFwcUHQ1LTCAUcNACABIAIQIiEBIABCADcDCCAAQQA2AgQgACABNgIADAELIARBGGogASACEC0iAxADBEAgACADEBoMAQsgAwRAIABBuH8QGgwBCyACIAQoAjAiA2shAiABIANqIQMDQAJAIAAgAyACIARBCGoQLCIFEAMEfyAFBSACIAVBA2oiBU8NAUG4fwsQGgwCCyAGQQFqIQYgAiAFayECIAMgBWohAyAEKAIMRQ0ACyAEKAI4BEAgAkEDTQRAIABBuH8QGgwCCyADQQRqIQMLIAQoAighAiAEKQMYIQcgAEEANgIEIAAgAyABazYCACAAIAIgBmytIAcgB0J/URs3AwgLIARBQGskAAslAQF/IwBBEGsiAiQAIAIgACABEFEgAigCACEAIAJBEGokACAAC30BBH8jAEGQBGsiBCQAIARB/wE2AggCQCAEQRBqIARBCGogBEEMaiABIAIQFSIGEAMEQCAGIQUMAQtBVCEFIAQoAgwiB0EGSw0AIAMgBEEQaiAEKAIIIAcQQSIFEAMNACAAIAEgBmogAiAGayADEDwhBQsgBEGQBGokACAFC4cBAgJ/An5BABAWIQMCQANAIAEgA08EQAJAIAAoAABBcHFB0NS0wgFGBEAgACABECIiAhADRQ0BQn4PCyAAIAEQVSIEQn1WDQMgBCAFfCIFIARUIQJCfiEEIAINAyAAIAEQUiICEAMNAwsgASACayEBIAAgAmohAAwBCwtCfiAFIAEbIQQLIAQLPwIBfwF+IwBBMGsiAiQAAn5CfiACQQhqIAAgARAtDQAaQgAgAigCHEEBRg0AGiACKQMICyEDIAJBMGokACADC40BAQJ/IwBBMGsiASQAAkAgAEUNACAAKAKI4gENACABIABB/OEBaigCADYCKCABIAApAvThATcDICAAEDAgACgCqOIBIQIgASABKAIoNgIYIAEgASkDIDcDECACIAFBEGoQGyAAQQA2AqjiASABIAEoAig2AgggASABKQMgNwMAIAAgARAbCyABQTBqJAALKgECfyMAQRBrIgAkACAAQQA2AgggAEIANwMAIAAQWCEBIABBEGokACABC4cBAQN/IwBBEGsiAiQAAkAgACgCAEUgACgCBEVzDQAgAiAAKAIINgIIIAIgACkCADcDAAJ/IAIoAgAiAQRAIAIoAghBqOMJIAERBQAMAQtBqOMJECgLIgFFDQAgASAAKQIANwL04QEgAUH84QFqIAAoAgg2AgAgARBZIAEhAwsgAkEQaiQAIAMLywEBAn8jAEEgayIBJAAgAEGBgIDAADYCtOIBIABBADYCiOIBIABBADYC7OEBIABCADcDkOIBIABBADYCpOMJIABBADYC3OIBIABCADcCzOIBIABBADYCvOIBIABBADYCxOABIABCADcCnOIBIABBpOIBakIANwIAIABBrOIBakEANgIAIAFCADcCECABQgA3AhggASABKQMYNwMIIAEgASkDEDcDACABKAIIQQh2QQFxIQIgAEEANgLg4gEgACACNgKM4gEgAUEgaiQAC3YBA38jAEEwayIBJAAgAARAIAEgAEHE0AFqIgIoAgA2AiggASAAKQK80AE3AyAgACgCACEDIAEgAigCADYCGCABIAApArzQATcDECADIAFBEGoQGyABIAEoAig2AgggASABKQMgNwMAIAAgARAbCyABQTBqJAALzAEBAX8gACABKAK00AE2ApjiASAAIAEoAgQiAjYCwOABIAAgAjYCvOABIAAgAiABKAIIaiICNgK44AEgACACNgLE4AEgASgCuNABBEAgAEKBgICAEDcDiOEBIAAgAUGk0ABqNgIMIAAgAUGUIGo2AgggACABQZwwajYCBCAAIAFBDGo2AgAgAEGs0AFqIAFBqNABaigCADYCACAAQbDQAWogAUGs0AFqKAIANgIAIABBtNABaiABQbDQAWooAgA2AgAPCyAAQgA3A4jhAQs7ACACRQRAQbp/DwsgBEUEQEFsDwsgAiAEEGAEQCAAIAEgAiADIAQgBRBhDwsgACABIAIgAyAEIAUQZQtGAQF/IwBBEGsiBSQAIAVBCGogBBAOAn8gBS0ACQRAIAAgASACIAMgBBAyDAELIAAgASACIAMgBBA0CyEAIAVBEGokACAACzQAIAAgAyAEIAUQNiIFEAMEQCAFDwsgBSAESQR/IAEgAiADIAVqIAQgBWsgABA1BUG4fwsLRgEBfyMAQRBrIgUkACAFQQhqIAQQDgJ/IAUtAAkEQCAAIAEgAiADIAQQYgwBCyAAIAEgAiADIAQQNQshACAFQRBqJAAgAAtZAQF/QQ8hAiABIABJBEAgAUEEdCAAbiECCyAAQQh2IgEgAkEYbCIAQYwIaigCAGwgAEGICGooAgBqIgJBA3YgAmogAEGACGooAgAgAEGECGooAgAgAWxqSQs3ACAAIAMgBCAFQYAQEDMiBRADBEAgBQ8LIAUgBEkEfyABIAIgAyAFaiAEIAVrIAAQMgVBuH8LC78DAQN/IwBBIGsiBSQAIAVBCGogAiADEAYiAhADRQRAIAAgAWoiB0F9aiEGIAUgBBAOIARBBGohAiAFLQACIQMDQEEAIAAgBkkgBUEIahAEGwRAIAAgAiAFQQhqIAMQAkECdGoiBC8BADsAACAFQQhqIAQtAAIQASAAIAQtAANqIgQgAiAFQQhqIAMQAkECdGoiAC8BADsAACAFQQhqIAAtAAIQASAEIAAtAANqIQAMAQUgB0F+aiEEA0AgBUEIahAEIAAgBEtyRQRAIAAgAiAFQQhqIAMQAkECdGoiBi8BADsAACAFQQhqIAYtAAIQASAAIAYtAANqIQAMAQsLA0AgACAES0UEQCAAIAIgBUEIaiADEAJBAnRqIgYvAQA7AAAgBUEIaiAGLQACEAEgACAGLQADaiEADAELCwJAIAAgB08NACAAIAIgBUEIaiADEAIiA0ECdGoiAC0AADoAACAALQADQQFGBEAgBUEIaiAALQACEAEMAQsgBSgCDEEfSw0AIAVBCGogAiADQQJ0ai0AAhABIAUoAgxBIUkNACAFQSA2AgwLIAFBbCAFQQhqEAobIQILCwsgBUEgaiQAIAILkgIBBH8jAEFAaiIJJAAgCSADQTQQCyEDAkAgBEECSA0AIAMgBEECdGooAgAhCSADQTxqIAgQIyADQQE6AD8gAyACOgA+QQAhBCADKAI8IQoDQCAEIAlGDQEgACAEQQJ0aiAKNgEAIARBAWohBAwAAAsAC0EAIQkDQCAGIAlGRQRAIAMgBSAJQQF0aiIKLQABIgtBAnRqIgwoAgAhBCADQTxqIAotAABBCHQgCGpB//8DcRAjIANBAjoAPyADIAcgC2siCiACajoAPiAEQQEgASAKa3RqIQogAygCPCELA0AgACAEQQJ0aiALNgEAIARBAWoiBCAKSQ0ACyAMIAo2AgAgCUEBaiEJDAELCyADQUBrJAALowIBCX8jAEHQAGsiCSQAIAlBEGogBUE0EAsaIAcgBmshDyAHIAFrIRADQAJAIAMgCkcEQEEBIAEgByACIApBAXRqIgYtAAEiDGsiCGsiC3QhDSAGLQAAIQ4gCUEQaiAMQQJ0aiIMKAIAIQYgCyAPTwRAIAAgBkECdGogCyAIIAUgCEE0bGogCCAQaiIIQQEgCEEBShsiCCACIAQgCEECdGooAgAiCEEBdGogAyAIayAHIA4QYyAGIA1qIQgMAgsgCUEMaiAOECMgCUEBOgAPIAkgCDoADiAGIA1qIQggCSgCDCELA0AgBiAITw0CIAAgBkECdGogCzYBACAGQQFqIQYMAAALAAsgCUHQAGokAA8LIAwgCDYCACAKQQFqIQoMAAALAAs0ACAAIAMgBCAFEDYiBRADBEAgBQ8LIAUgBEkEfyABIAIgAyAFaiAEIAVrIAAQNAVBuH8LCyMAIAA/AEEQdGtB//8DakEQdkAAQX9GBEBBAA8LQQAQAEEBCzsBAX8gAgRAA0AgACABIAJBgCAgAkGAIEkbIgMQCyEAIAFBgCBqIQEgAEGAIGohACACIANrIgINAAsLCwYAIAAQAwsLqBUJAEGICAsNAQAAAAEAAAACAAAAAgBBoAgLswYBAAAAAQAAAAIAAAACAAAAJgAAAIIAAAAhBQAASgAAAGcIAAAmAAAAwAEAAIAAAABJBQAASgAAAL4IAAApAAAALAIAAIAAAABJBQAASgAAAL4IAAAvAAAAygIAAIAAAACKBQAASgAAAIQJAAA1AAAAcwMAAIAAAACdBQAASgAAAKAJAAA9AAAAgQMAAIAAAADrBQAASwAAAD4KAABEAAAAngMAAIAAAABNBgAASwAAAKoKAABLAAAAswMAAIAAAADBBgAATQAAAB8NAABNAAAAUwQAAIAAAAAjCAAAUQAAAKYPAABUAAAAmQQAAIAAAABLCQAAVwAAALESAABYAAAA2gQAAIAAAABvCQAAXQAAACMUAABUAAAARQUAAIAAAABUCgAAagAAAIwUAABqAAAArwUAAIAAAAB2CQAAfAAAAE4QAAB8AAAA0gIAAIAAAABjBwAAkQAAAJAHAACSAAAAAAAAAAEAAAABAAAABQAAAA0AAAAdAAAAPQAAAH0AAAD9AAAA/QEAAP0DAAD9BwAA/Q8AAP0fAAD9PwAA/X8AAP3/AAD9/wEA/f8DAP3/BwD9/w8A/f8fAP3/PwD9/38A/f//AP3//wH9//8D/f//B/3//w/9//8f/f//P/3//38AAAAAAQAAAAIAAAADAAAABAAAAAUAAAAGAAAABwAAAAgAAAAJAAAACgAAAAsAAAAMAAAADQAAAA4AAAAPAAAAEAAAABEAAAASAAAAEwAAABQAAAAVAAAAFgAAABcAAAAYAAAAGQAAABoAAAAbAAAAHAAAAB0AAAAeAAAAHwAAAAMAAAAEAAAABQAAAAYAAAAHAAAACAAAAAkAAAAKAAAACwAAAAwAAAANAAAADgAAAA8AAAAQAAAAEQAAABIAAAATAAAAFAAAABUAAAAWAAAAFwAAABgAAAAZAAAAGgAAABsAAAAcAAAAHQAAAB4AAAAfAAAAIAAAACEAAAAiAAAAIwAAACUAAAAnAAAAKQAAACsAAAAvAAAAMwAAADsAAABDAAAAUwAAAGMAAACDAAAAAwEAAAMCAAADBAAAAwgAAAMQAAADIAAAA0AAAAOAAAADAAEAQeAPC1EBAAAAAQAAAAEAAAABAAAAAgAAAAIAAAADAAAAAwAAAAQAAAAEAAAABQAAAAcAAAAIAAAACQAAAAoAAAALAAAADAAAAA0AAAAOAAAADwAAABAAQcQQC4sBAQAAAAIAAAADAAAABAAAAAUAAAAGAAAABwAAAAgAAAAJAAAACgAAAAsAAAAMAAAADQAAAA4AAAAPAAAAEAAAABIAAAAUAAAAFgAAABgAAAAcAAAAIAAAACgAAAAwAAAAQAAAAIAAAAAAAQAAAAIAAAAEAAAACAAAABAAAAAgAAAAQAAAAIAAAAAAAQBBkBIL5gQBAAAAAQAAAAEAAAABAAAAAgAAAAIAAAADAAAAAwAAAAQAAAAGAAAABwAAAAgAAAAJAAAACgAAAAsAAAAMAAAADQAAAA4AAAAPAAAAEAAAAAEAAAAEAAAACAAAAAAAAAABAAEBBgAAAAAAAAQAAAAAEAAABAAAAAAgAAAFAQAAAAAAAAUDAAAAAAAABQQAAAAAAAAFBgAAAAAAAAUHAAAAAAAABQkAAAAAAAAFCgAAAAAAAAUMAAAAAAAABg4AAAAAAAEFEAAAAAAAAQUUAAAAAAABBRYAAAAAAAIFHAAAAAAAAwUgAAAAAAAEBTAAAAAgAAYFQAAAAAAABwWAAAAAAAAIBgABAAAAAAoGAAQAAAAADAYAEAAAIAAABAAAAAAAAAAEAQAAAAAAAAUCAAAAIAAABQQAAAAAAAAFBQAAACAAAAUHAAAAAAAABQgAAAAgAAAFCgAAAAAAAAULAAAAAAAABg0AAAAgAAEFEAAAAAAAAQUSAAAAIAABBRYAAAAAAAIFGAAAACAAAwUgAAAAAAADBSgAAAAAAAYEQAAAABAABgRAAAAAIAAHBYAAAAAAAAkGAAIAAAAACwYACAAAMAAABAAAAAAQAAAEAQAAACAAAAUCAAAAIAAABQMAAAAgAAAFBQAAACAAAAUGAAAAIAAABQgAAAAgAAAFCQAAACAAAAULAAAAIAAABQwAAAAAAAAGDwAAACAAAQUSAAAAIAABBRQAAAAgAAIFGAAAACAAAgUcAAAAIAADBSgAAAAgAAQFMAAAAAAAEAYAAAEAAAAPBgCAAAAAAA4GAEAAAAAADQYAIABBgBcLhwIBAAEBBQAAAAAAAAUAAAAAAAAGBD0AAAAAAAkF/QEAAAAADwX9fwAAAAAVBf3/HwAAAAMFBQAAAAAABwR9AAAAAAAMBf0PAAAAABIF/f8DAAAAFwX9/38AAAAFBR0AAAAAAAgE/QAAAAAADgX9PwAAAAAUBf3/DwAAAAIFAQAAABAABwR9AAAAAAALBf0HAAAAABEF/f8BAAAAFgX9/z8AAAAEBQ0AAAAQAAgE/QAAAAAADQX9HwAAAAATBf3/BwAAAAEFAQAAABAABgQ9AAAAAAAKBf0DAAAAABAF/f8AAAAAHAX9//8PAAAbBf3//wcAABoF/f//AwAAGQX9//8BAAAYBf3//wBBkBkLhgQBAAEBBgAAAAAAAAYDAAAAAAAABAQAAAAgAAAFBQAAAAAAAAUGAAAAAAAABQgAAAAAAAAFCQAAAAAAAAULAAAAAAAABg0AAAAAAAAGEAAAAAAAAAYTAAAAAAAABhYAAAAAAAAGGQAAAAAAAAYcAAAAAAAABh8AAAAAAAAGIgAAAAAAAQYlAAAAAAABBikAAAAAAAIGLwAAAAAAAwY7AAAAAAAEBlMAAAAAAAcGgwAAAAAACQYDAgAAEAAABAQAAAAAAAAEBQAAACAAAAUGAAAAAAAABQcAAAAgAAAFCQAAAAAAAAUKAAAAAAAABgwAAAAAAAAGDwAAAAAAAAYSAAAAAAAABhUAAAAAAAAGGAAAAAAAAAYbAAAAAAAABh4AAAAAAAAGIQAAAAAAAQYjAAAAAAABBicAAAAAAAIGKwAAAAAAAwYzAAAAAAAEBkMAAAAAAAUGYwAAAAAACAYDAQAAIAAABAQAAAAwAAAEBAAAABAAAAQFAAAAIAAABQcAAAAgAAAFCAAAACAAAAUKAAAAIAAABQsAAAAAAAAGDgAAAAAAAAYRAAAAAAAABhQAAAAAAAAGFwAAAAAAAAYaAAAAAAAABh0AAAAAAAAGIAAAAAAAEAYDAAEAAAAPBgOAAAAAAA4GA0AAAAAADQYDIAAAAAAMBgMQAAAAAAsGAwgAAAAACgYDBABBpB0L2QEBAAAAAwAAAAcAAAAPAAAAHwAAAD8AAAB/AAAA/wAAAP8BAAD/AwAA/wcAAP8PAAD/HwAA/z8AAP9/AAD//wAA//8BAP//AwD//wcA//8PAP//HwD//z8A//9/AP///wD///8B////A////wf///8P////H////z////9/AAAAAAEAAAACAAAABAAAAAAAAAACAAAABAAAAAgAAAAAAAAAAQAAAAIAAAABAAAABAAAAAQAAAAEAAAABAAAAAgAAAAIAAAACAAAAAcAAAAIAAAACQAAAAoAAAALAEGgIAsDwBBQ",fA=new wA;class UA extends DA{constructor(u){super(),this.planarConfiguration=typeof u.PlanarConfiguration<"u"?u.PlanarConfiguration:1,this.samplesPerPixel=typeof u.SamplesPerPixel<"u"?u.SamplesPerPixel:1,this.addCompression=u.LercParameters[sA.AddCompression]}decodeBlock(u){switch(this.addCompression){case gA.None:break;case gA.Deflate:u=tA(new Uint8Array(u)).buffer;break;case gA.Zstandard:u=fA.decode(new Uint8Array(u)).buffer;break;default:throw new Error(`Unsupported LERC additional compression method identifier: ${this.addCompression}`)}return hA.decode(u,{returnPixelInterleavedDims:this.planarConfiguration===1}).pixels[0].buffer}}export{UA as default,fA as zstd}; diff --git a/pr-preview/pr-17/assets/main-DtPEmPHr.js b/pr-preview/pr-17/assets/main-DtPEmPHr.js deleted file mode 100644 index d2be331..0000000 --- a/pr-preview/pr-17/assets/main-DtPEmPHr.js +++ /dev/null @@ -1 +0,0 @@ -import{at as e,au as o,av as t}from"./index-BHzPgH2J.js";const{currentUrl:I}=o.states,i={defineWidget:g=>g?{id:"Information",title:"Information",layout:{x:9,y:0,w:3,h:8},type:"web-component",widget:{link:()=>e(()=>import("./eox-stacinfo-CES29oXd.js"),[]),properties:{class:"pa-5 fill-height",for:I,allowHtml:"true",header:'["title"]',tags:'["themes"]',subheader:"[]",properties:'["satellite","sensor","agency","extent"]',featured:'["description","providers","assets","links"]',footer:'["sci:citation"]'},tagName:"eox-stacinfo"}}:null},d={id:Symbol(),title:"Container",type:"internal",layout:{x:4,y:9,w:4,h:3},widget:{name:"WidgetsContainer",properties:{widgets:[{id:"reset zoom",title:"Reset Zoom",type:"web-component",widget:{link:new URL("data:text/javascript;base64,ZXhwb3J0IGNsYXNzIFJlc2V0Wm9vbUJ0biBleHRlbmRzIEhUTUxFbGVtZW50IHsKICAvKioKICAgKiBkZWZpbmVzIHRoZSBjdXJyZW50IHpvb20uCiAgICogdHJpZ2dlcnMgYSByZXJlbmRlciB3aGVuIGEgdmFsdWUgaXMgc2V0CiAgICovCiAgI2N1cnJlbnRab29tID0gewogICAgX3RpbWVvdXQ6IHVuZGVmaW5lZCwKICAgIHJlbmRlckVsOiAoKSA9PiB7CiAgICAgIHRoaXMucmVuZGVyKCk7CiAgICAgIGNvbnN0IGJ0biA9IHRoaXMuc2hhZG93Um9vdC5xdWVyeVNlbGVjdG9yKCJidXR0b24iKTsKICAgICAgaWYgKGJ0bikgewogICAgICAgIGJ0bi5vbmNsaWNrID0gdGhpcy4jb25CdG5DbGljazsKICAgICAgfQogICAgfSwKICAgIF92YWx1ZTogMCwKICAgIGdldCB2YWx1ZSgpIHsKICAgICAgcmV0dXJuIHRoaXMuX3ZhbHVlOwogICAgfSwKICAgIHNldCB2YWx1ZSh2YWwpIHsKICAgICAgdGhpcy5fdmFsdWUgPSB2YWw7CiAgICAgIGNsZWFyVGltZW91dCh0aGlzLl90aW1lb3V0KTsKICAgICAgdGhpcy5fdGltZW91dCA9IHNldFRpbWVvdXQoKCkgPT4gewogICAgICAgIHRoaXMucmVuZGVyRWwoKTsKICAgICAgfSk7CiAgICB9LAogIH07CgogIC8qKiBtYXAgZWxlbWVudCBzZWxlY3RvciAqLwogIGZvciA9ICJlb3gtbWFwIjsKICAvKiogdGhlIGRlc2lyZWQgdmFsdWUgdG8gcmVzZXQgdGhlIHpvb20gdG8gKi8KICB0byA9IDQ7CgogIGNvbnN0cnVjdG9yKCkgewogICAgc3VwZXIoKTsKICAgIHRoaXMuYXR0YWNoU2hhZG93KHsgbW9kZTogIm9wZW4iIH0pOwogIH0KCiAgY29ubmVjdGVkQ2FsbGJhY2soKSB7CiAgICB0aGlzLnJlbmRlcigpOwogICAgLyoqCiAgICAgKiB1cGRhdGVzIHRoZSBjdXJyZW50IHpvb20gdmFsdWUgZnJvbSBVUkxTZWFyY2hQYXJhbXMKICAgICAqIEBwYXJhbSB7c3RyaW5nfSBxdWVyeQogICAgICovCiAgICBjb25zdCB1cGRhdGVDdXJyZW50Wm9vbSA9IChxdWVyeSkgPT4gewogICAgICBjb25zdCBzZWFyY2hQYXJhbXMgPSBuZXcgVVJMU2VhcmNoUGFyYW1zKHF1ZXJ5KTsKICAgICAgdGhpcy4jY3VycmVudFpvb20udmFsdWUgPSBOdW1iZXIoc2VhcmNoUGFyYW1zLmdldCgieiIpKTsKICAgIH07CgogICAgLy8gdXBkYXRpbmcgcHVzaFN0YXRlIGZ1bmN0aW9uIHRvIHdhdGNoIHRoZSB1cmwgcXVlcnkKICAgIC8vIGFuZCB1cGRhdGUgdGhlIGN1cnJlbnQgem9vbQogICAgY29uc3QgcHVzaFN0YXRlID0gaGlzdG9yeS5wdXNoU3RhdGU7CiAgICB3aW5kb3cuaGlzdG9yeS5wdXNoU3RhdGUgPSBmdW5jdGlvbiAoLi4uYXJncykgewogICAgICB1cGRhdGVDdXJyZW50Wm9vbSgvKiogQHR5cGUge3N0cmluZ30gKi8gKGFyZ3M/LlsyXSkpOwogICAgICByZXR1cm4gcHVzaFN0YXRlLmFwcGx5KHdpbmRvdy5oaXN0b3J5LCBhcmd1bWVudHMpOwogICAgfTsKICB9CgogIC8vIHJlc2V0IHpvb20gb24gY2xpY2sKICAjb25CdG5DbGljayA9IChlKSA9PiB7CiAgICBjb25zdCBzZWFyY2hQYXJhbXMgPSBuZXcgVVJMU2VhcmNoUGFyYW1zKHdpbmRvdy5sb2NhdGlvbi5zZWFyY2gpOwogICAgc2VhcmNoUGFyYW1zLnNldCgieiIsIHRoaXMudG8udG9TdHJpbmcoKSA/PyAiIik7CiAgICB3aW5kb3cuaGlzdG9yeS5wdXNoU3RhdGUobnVsbCwgIiIsIGA/JHtzZWFyY2hQYXJhbXN9YCk7CiAgICBjb25zdCBtYXAgPSBkb2N1bWVudC5xdWVyeVNlbGVjdG9yKHRoaXMuZm9yKTsKICAgIC8vQHRzLWV4cGVjdC1lcnJvciBlb3gtbWFwIGF0dHJpYnV0ZQogICAgbWFwLnpvb20gPSB0aGlzLnRvOwogIH07CgogIHN0YXRpYyBnZXQgb2JzZXJ2ZWRBdHRyaWJ1dGVzKCkgewogICAgcmV0dXJuIFsidG8iXTsKICB9CgogIGF0dHJpYnV0ZUNoYW5nZWRDYWxsYmFjayhuYW1lLCBfb2xkVmFsdWUsIG5ld1ZhbHVlKSB7CiAgICB0aGlzW25hbWVdID0gbmV3VmFsdWU7CiAgfQoKICByZW5kZXIoKSB7CiAgICByZXR1cm4gKHRoaXMuc2hhZG93Um9vdC5pbm5lckhUTUwgPSBgCiAgICA8c3R5bGU+CiAgICAgICAgOmhvc3QgewogICAgICAgIHdpZHRoOiAxMDAlOwogICAgICAgIGhlaWdodDogMTAwJQogICAgICAgIH0KICAgIDwvc3R5bGU+CgogICAgICA8aDIgY2xhc3M9InRleHQiPiB5b3VyIGN1cnJlbnQgem9vbSBpcyAke3RoaXMuI2N1cnJlbnRab29tLnZhbHVlfSA8L2gyPgogICAgICA8YnV0dG9uIGlkPSJyZXNldCI+IHJlc2V0IHpvb20gPC9idXR0b24+CiAgICAgICAgYCk7CiAgfQp9Cg==",import.meta.url).href,constructorProp:"ResetZoomBtn",tagName:"reset-zoom",properties:{to:3}}},{id:Symbol(),title:"Date Picker",type:"internal",widget:{name:"EodashDatePicker"}}]}}},a=t({id:"template-id",stacEndpoint:"https://eodashcatalog.eox.at/test-style/trilateral/catalog.json",brand:{name:"Dashboard",font:{family:"Poppins",link:new URL("data:text/css;base64,QGZvbnQtZmFjZSB7CiAgZm9udC1mYW1pbHk6ICJQb3BwaW5zIjsKICBzcmM6IGxvY2FsKCJQb3BwaW5zIiksIHVybCgiLi9Qb3BwaW5zL1BvcHBpbnMtUmVndWxhci50dGYiKSBmb3JtYXQoIndvZmYiKTsKfQo=",import.meta.url).href},logo:"/logo.png",errorMessage:"something went wrong, please contact demo@email.com if the issue persists",footerText:"eodash instance template",theme:{colors:{primary:"#004170",secondary:"#004170",background:"#fff",surface:"#eee"}}},template:{gap:0,background:{type:"internal",id:Symbol(),widget:{name:"EodashMap"}},loading:{id:Symbol(),type:"web-component",widget:{link:"https://cdn.jsdelivr.net/npm/ldrs/dist/auto/mirage.js",tagName:"l-mirage",properties:{class:"align-self-center justify-self-center",size:"120",speed:"2.5",color:"#004170"}}},widgets:[i,d,{id:Symbol(),title:"Tools",layout:{x:0,y:0,w:3,h:5},widget:{name:"List",properties:{outlined:!1}},type:"internal"},{defineWidget:g=>g?{id:"layercontrol",layout:{x:9,y:8,w:3,h:4},title:"Layer Control",type:"internal",widget:{name:"EodashLayerControl"}}:null},{id:"mapbtns",layout:{x:8,y:0,w:1,h:2},title:"Map Buttons",type:"internal",widget:{name:"EodashMapBtns"}}]}});export{a as default}; diff --git a/pr-preview/pr-17/assets/main-ddE0Djvd.js b/pr-preview/pr-17/assets/main-ddE0Djvd.js new file mode 100644 index 0000000..ad93cd9 --- /dev/null +++ b/pr-preview/pr-17/assets/main-ddE0Djvd.js @@ -0,0 +1,15 @@ +import{au as e,av as o,aw as a}from"./index-Dvu417lt.js";const{currentUrl:i}=a.states,r=e({id:"template-id",stacEndpoint:"https://eodashcatalog.eox.at/test-style/trilateral/catalog.json",brand:{name:"Dashboard",font:{family:"Poppins",link:new URL("data:text/css;base64,QGZvbnQtZmFjZSB7CiAgZm9udC1mYW1pbHk6ICJQb3BwaW5zIjsKICBzcmM6IGxvY2FsKCJQb3BwaW5zIiksIHVybCgiLi9Qb3BwaW5zL1BvcHBpbnMtUmVndWxhci50dGYiKSBmb3JtYXQoIndvZmYiKTsKfQo=",import.meta.url).href},logo:"/logo.png",errorMessage:"something went wrong, please contact demo@email.com if the issue persists",footerText:"eodash instance template",theme:{colors:{primary:"#004170",secondary:"#004170",background:"#fff",surface:"#fff"}}},template:{gap:0,background:{id:Symbol(),type:"internal",widget:{name:"EodashMap",properties:{}}},widgets:[{id:Symbol(),type:"internal",title:"Indicators",layout:{x:0,y:0,w:3,h:8},widget:{name:"EodashItemFilter",properties:{aggregateResults:"collection_group"}}},{id:Symbol(),type:"internal",title:"Layer Control",layout:{x:0,y:8,w:3,h:4},widget:{name:"EodashLayerControl"}},{defineWidget:t=>t?{id:"Information",title:"Information",layout:{x:9,y:0,w:3,h:12},type:"web-component",widget:{link:async()=>await o(()=>import("./eox-stacinfo-CES29oXd.js"),[]),properties:{for:i,allowHtml:"true",styleOverride:`.single-property {columns: 1!important;} + h1 {margin:0px!important;font-size:16px!important;} + header h1:after { + content:' '; + display:block; + border:1px solid #d0d0d0; + } + h2 {font-size:15px} + h3 {font-size:14px} + summary {cursor: pointer;} + #properties li > .value { font-weight: normal !important;} + main {padding-bottom: 10px;} + .footer-container {line-height:1;} + .footer-container button {margin-top: -10px;} + .footer-container small {font-size:10px;line-height:1;}`,header:'["title"]',tags:'["themes"]',subheader:"[]",properties:'["satellite","sensor","agency","extent"]',featured:'["description","providers","assets","links"]',footer:'["sci:citation"]'},tagName:"eox-stacinfo"}}:null},{defineWidget:t=>t?{id:"Datepicker",type:"internal",layout:{x:5,y:10,w:1,h:1},title:"Datepicker",widget:{name:"EodashDatePicker"}}:null},{defineWidget:t=>t?{id:"Buttons",layout:{x:8,y:0,w:1,h:1},title:"Buttons",type:"internal",widget:{name:"EodashMapBtns"}}:null}]}});export{r as default}; diff --git a/pr-preview/pr-17/assets/ssrBoot-7hoALQc5.js b/pr-preview/pr-17/assets/ssrBoot-Uu_-yAhn.js similarity index 73% rename from pr-preview/pr-17/assets/ssrBoot-7hoALQc5.js rename to pr-preview/pr-17/assets/ssrBoot-Uu_-yAhn.js index df7ebe0..c6f9cbc 100644 --- a/pr-preview/pr-17/assets/ssrBoot-7hoALQc5.js +++ b/pr-preview/pr-17/assets/ssrBoot-Uu_-yAhn.js @@ -1 +1 @@ -import{s,Z as t,c as e,bk as n}from"./index-BHzPgH2J.js";function i(){const o=s(!1);return t(()=>{window.requestAnimationFrame(()=>{o.value=!0})}),{ssrBootStyles:e(()=>o.value?void 0:{transition:"none !important"}),isBooted:n(o)}}export{i as u}; +import{s,Z as t,c as e,ar as n}from"./index-Dvu417lt.js";function i(){const o=s(!1);return t(()=>{window.requestAnimationFrame(()=>{o.value=!0})}),{ssrBootStyles:e(()=>o.value?void 0:{transition:"none !important"}),isBooted:n(o)}}export{i as u}; diff --git a/pr-preview/pr-17/assets/transition-zS3yGrDV.js b/pr-preview/pr-17/assets/transition-BKtsYhmO.js similarity index 87% rename from pr-preview/pr-17/assets/transition-zS3yGrDV.js rename to pr-preview/pr-17/assets/transition-BKtsYhmO.js index 4cd9636..30c61c4 100644 --- a/pr-preview/pr-17/assets/transition-zS3yGrDV.js +++ b/pr-preview/pr-17/assets/transition-BKtsYhmO.js @@ -1 +1 @@ -import{p as m,az as b,d,bL as l,ab as u}from"./index-BHzPgH2J.js";const j=m({transition:{type:[Boolean,String,Object],default:"fade-transition",validator:o=>o!==!0}},"transition"),T=(o,s)=>{let{slots:e}=s;const{transition:t,disabled:n,group:r,...a}=o,{component:i=r?l:u,...p}=typeof t=="object"?t:{};return b(i,d(typeof t=="string"?{name:n?"":t}:p,typeof t=="string"?{}:Object.fromEntries(Object.entries({disabled:n,group:r}).filter(c=>{let[y,f]=c;return f!==void 0})),a),e)};export{T as M,j as m}; +import{p as m,aA as b,d,bk as l,ab as u}from"./index-Dvu417lt.js";const j=m({transition:{type:[Boolean,String,Object],default:"fade-transition",validator:o=>o!==!0}},"transition"),T=(o,s)=>{let{slots:e}=s;const{transition:t,disabled:n,group:r,...a}=o,{component:i=r?l:u,...p}=typeof t=="object"?t:{};return b(i,d(typeof t=="string"?{name:n?"":t}:p,typeof t=="string"?{}:Object.fromEntries(Object.entries({disabled:n,group:r}).filter(c=>{let[y,f]=c;return f!==void 0})),a),e)};export{T as M,j as m}; diff --git a/pr-preview/pr-17/index.html b/pr-preview/pr-17/index.html index c2d94fa..bdbbe65 100644 --- a/pr-preview/pr-17/index.html +++ b/pr-preview/pr-17/index.html @@ -7,7 +7,7 @@ Welcome to Eodash v5 - +