var ZA=Object.defineProperty;var HA=(vn,Ee,Xt)=>Ee in vn?ZA(vn,Ee,{enumerable:!0,configurable:!0,writable:!0,value:Xt}):vn[Ee]=Xt;var Um=(vn,Ee,Xt)=>HA(vn,typeof Ee!="symbol"?Ee+"":Ee,Xt);(function(){"use strict";/**
  * @vue/shared v3.5.5
  * (c) 2018-present Yuxi (Evan) You and Vue contributors
  * @license MIT
  **//*! #__NO_SIDE_EFFECTS__ */function vn(e){const t=Object.create(null);for(const n of e.split(","))t[n]=1;return n=>n in t}const Ee={},Xt=[],_n=()=>{},Qm=()=>!1,Ao=e=>e.charCodeAt(0)===111&&e.charCodeAt(1)===110&&(e.charCodeAt(2)>122||e.charCodeAt(2)<97),nl=e=>e.startsWith("onUpdate:"),et=Object.assign,il=(e,t)=>{const n=e.indexOf(t);n>-1&&e.splice(n,1)},Jm=Object.prototype.hasOwnProperty,Pe=(e,t)=>Jm.call(e,t),ae=Array.isArray,ki=e=>mr(e)==="[object Map]",So=e=>mr(e)==="[object Set]",jh=e=>mr(e)==="[object Date]",pe=e=>typeof e=="function",Ne=e=>typeof e=="string",nn=e=>typeof e=="symbol",Oe=e=>e!==null&&typeof e=="object",rl=e=>(Oe(e)||pe(e))&&pe(e.then)&&pe(e.catch),Nh=Object.prototype.toString,mr=e=>Nh.call(e),Gh=e=>mr(e)==="[object Object]",ol=e=>Ne(e)&&e!=="NaN"&&e[0]!=="-"&&""+parseInt(e,10)===e,vr=vn(",key,ref,ref_for,ref_key,onVnodeBeforeMount,onVnodeMounted,onVnodeBeforeUpdate,onVnodeUpdated,onVnodeBeforeUnmount,onVnodeUnmounted"),To=e=>{const t=Object.create(null);return n=>t[n]||(t[n]=e(n))},ev=/-(\w)/g,Wt=To(e=>e.replace(ev,(t,n)=>n?n.toUpperCase():"")),tv=/\B([A-Z])/g,In=To(e=>e.replace(tv,"-$1").toLowerCase()),Ro=To(e=>e.charAt(0).toUpperCase()+e.slice(1)),sl=To(e=>e?`on${Ro(e)}`:""),Mn=(e,t)=>!Object.is(e,t),ko=(e,...t)=>{for(let n=0;n<e.length;n++)e[n](...t)},Vh=(e,t,n,i=!1)=>{Object.defineProperty(e,t,{configurable:!0,enumerable:!1,writable:i,value:n})},nv=e=>{const t=parseFloat(e);return isNaN(t)?e:t},$h=e=>{const t=Ne(e)?Number(e):NaN;return isNaN(t)?e:t};let qh;const Xh=()=>qh||(qh=typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:typeof global<"u"?global:{});function Ln(e){if(ae(e)){const t={};for(let n=0;n<e.length;n++){const i=e[n],r=Ne(i)?sv(i):Ln(i);if(r)for(const s in r)t[s]=r[s]}return t}if(Ne(e)||Oe(e))return e}const iv=/;(?![^(]*\))/g,rv=/:([^]+)/,ov=/\/\*[^]*?\*\//g;function sv(e){const t={};return e.replace(ov,"").split(iv).forEach(n=>{if(n){const i=n.split(rv);i.length>1&&(t[i[0].trim()]=i[1].trim())}}),t}function ve(e){let t="";if(Ne(e))t=e;else if(ae(e))for(let n=0;n<e.length;n++){const i=ve(e[n]);i&&(t+=i+" ")}else if(Oe(e))for(const n in e)e[n]&&(t+=n+" ");return t.trim()}function Po(e){if(!e)return null;let{class:t,style:n}=e;return t&&!Ne(t)&&(e.class=ve(t)),n&&(e.style=Ln(n)),e}const av=vn("itemscope,allowfullscreen,formnovalidate,ismap,nomodule,novalidate,readonly");function Wh(e){return!!e||e===""}function Io(e,t){if(e===t)return!0;let n=jh(e),i=jh(t);if(n||i)return!(!n||!i)&&e.getTime()===t.getTime();if(n=nn(e),i=nn(t),n||i)return e===t;if(n=ae(e),i=ae(t),n||i)return!(!n||!i)&&function(r,s){if(r.length!==s.length)return!1;let o=!0;for(let a=0;o&&a<r.length;a++)o=Io(r[a],s[a]);return o}(e,t);if(n=Oe(e),i=Oe(t),n||i){if(!n||!i||Object.keys(e).length!==Object.keys(t).length)return!1;for(const r in e){const s=e.hasOwnProperty(r),o=t.hasOwnProperty(r);if(s&&!o||!s&&o||!Io(e[r],t[r]))return!1}}return String(e)===String(t)}function Yh(e,t){return e.findIndex(n=>Io(n,t))}const Zh=e=>!(!e||e.__v_isRef!==!0),Z=e=>Ne(e)?e:e==null?"":ae(e)||Oe(e)&&(e.toString===Nh||!pe(e.toString))?Zh(e)?Z(e.value):JSON.stringify(e,Hh,2):String(e),Hh=(e,t)=>Zh(t)?Hh(e,t.value):ki(t)?{[`Map(${t.size})`]:[...t.entries()].reduce((n,[i,r],s)=>(n[al(i,s)+" =>"]=r,n),{})}:So(t)?{[`Set(${t.size})`]:[...t.values()].map(n=>al(n))}:nn(t)?al(t):!Oe(t)||ae(t)||Gh(t)?t:String(t),al=(e,t="")=>{var n;return nn(e)?`Symbol(${(n=e.description)!=null?n:t})`:e};/**
  * @vue/reactivity v3.5.5
  * (c) 2018-present Yuxi (Evan) You and Vue contributors
  * @license MIT
  **/let Lt,De;class lv{constructor(t=!1){this.detached=t,this._active=!0,this.effects=[],this.cleanups=[],this._isPaused=!1,this.parent=Lt,!t&&Lt&&(this.index=(Lt.scopes||(Lt.scopes=[])).push(this)-1)}get active(){return this._active}pause(){if(this._active){let t,n;if(this._isPaused=!0,this.scopes)for(t=0,n=this.scopes.length;t<n;t++)this.scopes[t].pause();for(t=0,n=this.effects.length;t<n;t++)this.effects[t].pause()}}resume(){if(this._active&&this._isPaused){let t,n;if(this._isPaused=!1,this.scopes)for(t=0,n=this.scopes.length;t<n;t++)this.scopes[t].resume();for(t=0,n=this.effects.length;t<n;t++)this.effects[t].resume()}}run(t){if(this._active){const n=Lt;try{return Lt=this,t()}finally{Lt=n}}}on(){Lt=this}off(){Lt=this.parent}stop(t){if(this._active){let n,i;for(n=0,i=this.effects.length;n<i;n++)this.effects[n].stop();for(n=0,i=this.cleanups.length;n<i;n++)this.cleanups[n]();if(this.scopes)for(n=0,i=this.scopes.length;n<i;n++)this.scopes[n].stop(!0);if(!this.detached&&this.parent&&!t){const r=this.parent.scopes.pop();r&&r!==this&&(this.parent.scopes[this.index]=r,r.index=this.index)}this.parent=void 0,this._active=!1}}}const ll=new WeakSet;class Kh{constructor(t){this.fn=t,this.deps=void 0,this.depsTail=void 0,this.flags=5,this.nextEffect=void 0,this.cleanup=void 0,this.scheduler=void 0,Lt&&Lt.active&&Lt.effects.push(this)}pause(){this.flags|=64}resume(){64&this.flags&&(this.flags&=-65,ll.has(this)&&(ll.delete(this),this.trigger()))}notify(){2&this.flags&&!(32&this.flags)||8&this.flags||(this.flags|=8,this.nextEffect=_r,_r=this)}run(){if(!(1&this.flags))return this.fn();this.flags|=2,id(this),Jh(this);const t=De,n=Yt;De=this,Yt=!0;try{return this.fn()}finally{ed(this),De=t,Yt=n,this.flags&=-3}}stop(){if(1&this.flags){for(let t=this.deps;t;t=t.nextDep)dl(t);this.deps=this.depsTail=void 0,id(this),this.onStop&&this.onStop(),this.flags&=-2}}trigger(){64&this.flags?ll.add(this):this.scheduler?this.scheduler():this.runIfDirty()}runIfDirty(){hl(this)&&this.run()}get dirty(){return hl(this)}}let _r,Qh=0;function cl(){Qh++}function ul(){if(--Qh>0)return;let e;for(;_r;){let t=_r;for(_r=void 0;t;){const n=t.nextEffect;if(t.nextEffect=void 0,t.flags&=-9,1&t.flags)try{t.trigger()}catch(i){e||(e=i)}t=n}}if(e)throw e}function Jh(e){for(let t=e.deps;t;t=t.nextDep)t.version=-1,t.prevActiveLink=t.dep.activeLink,t.dep.activeLink=t}function ed(e){let t,n=e.depsTail,i=n;for(;i;){const r=i.prevDep;i.version===-1?(i===n&&(n=r),dl(i),cv(i)):t=i,i.dep.activeLink=i.prevActiveLink,i.prevActiveLink=void 0,i=r}e.deps=t,e.depsTail=n}function hl(e){for(let t=e.deps;t;t=t.nextDep)if(t.dep.version!==t.version||t.dep.computed&&td(t.dep.computed)||t.dep.version!==t.version)return!0;return!!e._dirty}function td(e){if(4&e.flags&&!(16&e.flags)||(e.flags&=-17,e.globalVersion===yr))return;e.globalVersion=yr;const t=e.dep;if(e.flags|=2,t.version>0&&!e.isSSR&&!hl(e))return void(e.flags&=-3);const n=De,i=Yt;De=e,Yt=!0;try{Jh(e);const r=e.fn(e._value);(t.version===0||Mn(r,e._value))&&(e._value=r,t.version++)}catch(r){throw t.version++,r}finally{De=n,Yt=i,ed(e),e.flags&=-3}}function dl(e){const{dep:t,prevSub:n,nextSub:i}=e;if(n&&(n.nextSub=i,e.prevSub=void 0),i&&(i.prevSub=n,e.nextSub=void 0),t.subs===e&&(t.subs=n),!t.subs&&t.computed){t.computed.flags&=-5;for(let r=t.computed.deps;r;r=r.nextDep)dl(r)}}function cv(e){const{prevDep:t,nextDep:n}=e;t&&(t.nextDep=n,e.prevDep=void 0),n&&(n.prevDep=t,e.nextDep=void 0)}let Yt=!0;const nd=[];function Fn(){nd.push(Yt),Yt=!1}function On(){const e=nd.pop();Yt=e===void 0||e}function id(e){const{cleanup:t}=e;if(e.cleanup=void 0,t){const n=De;De=void 0;try{t()}finally{De=n}}}let yr=0;class uv{constructor(t,n){this.sub=t,this.dep=n,this.version=n.version,this.nextDep=this.prevDep=this.nextSub=this.prevSub=this.prevActiveLink=void 0}}class pl{constructor(t){this.computed=t,this.version=0,this.activeLink=void 0,this.subs=void 0}track(t){if(!De||!Yt||De===this.computed)return;let n=this.activeLink;if(n===void 0||n.sub!==De)n=this.activeLink=new uv(De,this),De.deps?(n.prevDep=De.depsTail,De.depsTail.nextDep=n,De.depsTail=n):De.deps=De.depsTail=n,4&De.flags&&rd(n);else if(n.version===-1&&(n.version=this.version,n.nextDep)){const i=n.nextDep;i.prevDep=n.prevDep,n.prevDep&&(n.prevDep.nextDep=i),n.prevDep=De.depsTail,n.nextDep=void 0,De.depsTail.nextDep=n,De.depsTail=n,De.deps===n&&(De.deps=i)}return n}trigger(t){this.version++,yr++,this.notify(t)}notify(t){cl();try{for(let n=this.subs;n;n=n.prevSub)n.sub.notify()}finally{ul()}}}function rd(e){const t=e.dep.computed;if(t&&!e.dep.subs){t.flags|=20;for(let i=t.deps;i;i=i.nextDep)rd(i)}const n=e.dep.subs;n!==e&&(e.prevSub=n,n&&(n.nextSub=e)),e.dep.subs=e}const gl=new WeakMap,ii=Symbol(""),fl=Symbol(""),br=Symbol("");function ht(e,t,n){if(Yt&&De){let i=gl.get(e);i||gl.set(e,i=new Map);let r=i.get(n);r||i.set(n,r=new pl),r.track()}}function yn(e,t,n,i,r,s){const o=gl.get(e);if(!o)return void yr++;const a=l=>{l&&l.trigger()};if(cl(),t==="clear")o.forEach(a);else{const l=ae(e),c=l&&ol(n);if(l&&n==="length"){const u=Number(i);o.forEach((h,p)=>{(p==="length"||p===br||!nn(p)&&p>=u)&&a(h)})}else switch(n!==void 0&&a(o.get(n)),c&&a(o.get(br)),t){case"add":l?c&&a(o.get("length")):(a(o.get(ii)),ki(e)&&a(o.get(fl)));break;case"delete":l||(a(o.get(ii)),ki(e)&&a(o.get(fl)));break;case"set":ki(e)&&a(o.get(ii))}}ul()}function Pi(e){const t=Te(e);return t===e?t:(ht(t,0,br),zt(e)?t:t.map(dt))}function Mo(e){return ht(e=Te(e),0,br),e}const hv={__proto__:null,[Symbol.iterator](){return ml(this,Symbol.iterator,dt)},concat(...e){return Pi(this).concat(...e.map(t=>ae(t)?Pi(t):t))},entries(){return ml(this,"entries",e=>(e[1]=dt(e[1]),e))},every(e,t){return bn(this,"every",e,t,void 0,arguments)},filter(e,t){return bn(this,"filter",e,t,n=>n.map(dt),arguments)},find(e,t){return bn(this,"find",e,t,dt,arguments)},findIndex(e,t){return bn(this,"findIndex",e,t,void 0,arguments)},findLast(e,t){return bn(this,"findLast",e,t,dt,arguments)},findLastIndex(e,t){return bn(this,"findLastIndex",e,t,void 0,arguments)},forEach(e,t){return bn(this,"forEach",e,t,void 0,arguments)},includes(...e){return vl(this,"includes",e)},indexOf(...e){return vl(this,"indexOf",e)},join(e){return Pi(this).join(e)},lastIndexOf(...e){return vl(this,"lastIndexOf",e)},map(e,t){return bn(this,"map",e,t,void 0,arguments)},pop(){return xr(this,"pop")},push(...e){return xr(this,"push",e)},reduce(e,...t){return od(this,"reduce",e,t)},reduceRight(e,...t){return od(this,"reduceRight",e,t)},shift(){return xr(this,"shift")},some(e,t){return bn(this,"some",e,t,void 0,arguments)},splice(...e){return xr(this,"splice",e)},toReversed(){return Pi(this).toReversed()},toSorted(e){return Pi(this).toSorted(e)},toSpliced(...e){return Pi(this).toSpliced(...e)},unshift(...e){return xr(this,"unshift",e)},values(){return ml(this,"values",dt)}};function ml(e,t,n){const i=Mo(e),r=i[t]();return i===e||zt(e)||(r._next=r.next,r.next=()=>{const s=r._next();return s.value&&(s.value=n(s.value)),s}),r}const dv=Array.prototype;function bn(e,t,n,i,r,s){const o=Mo(e),a=o!==e&&!zt(e),l=o[t];if(l!==dv[t]){const h=l.apply(e,s);return a?dt(h):h}let c=n;o!==e&&(a?c=function(h,p){return n.call(this,dt(h),p,e)}:n.length>2&&(c=function(h,p){return n.call(this,h,p,e)}));const u=l.call(o,c,i);return a&&r?r(u):u}function od(e,t,n,i){const r=Mo(e);let s=n;return r!==e&&(zt(e)?n.length>3&&(s=function(o,a,l){return n.call(this,o,a,l,e)}):s=function(o,a,l){return n.call(this,o,dt(a),l,e)}),r[t](s,...i)}function vl(e,t,n){const i=Te(e);ht(i,0,br);const r=i[t](...n);return r!==-1&&r!==!1||!xl(n[0])?r:(n[0]=Te(n[0]),i[t](...n))}function xr(e,t,n=[]){Fn(),cl();const i=Te(e)[t].apply(e,n);return ul(),On(),i}const pv=vn("__proto__,__v_isRef,__isVue"),sd=new Set(Object.getOwnPropertyNames(Symbol).filter(e=>e!=="arguments"&&e!=="caller").map(e=>Symbol[e]).filter(nn));function gv(e){nn(e)||(e=String(e));const t=Te(this);return ht(t,0,e),t.hasOwnProperty(e)}class ad{constructor(t=!1,n=!1){this._isReadonly=t,this._isShallow=n}get(t,n,i){const r=this._isReadonly,s=this._isShallow;if(n==="__v_isReactive")return!r;if(n==="__v_isReadonly")return r;if(n==="__v_isShallow")return s;if(n==="__v_raw")return i===(r?s?Tv:fd:s?gd:pd).get(t)||Object.getPrototypeOf(t)===Object.getPrototypeOf(i)?t:void 0;const o=ae(t);if(!r){let l;if(o&&(l=hv[n]))return l;if(n==="hasOwnProperty")return gv}const a=Reflect.get(t,n,pt(t)?t:i);return(nn(n)?sd.has(n):pv(n))?a:(r||ht(t,0,n),s?a:pt(a)?o&&ol(n)?a:a.value:Oe(a)?r?Bt(a):Xe(a):a)}}class ld extends ad{constructor(t=!1){super(!1,t)}set(t,n,i,r){let s=t[n];if(!this._isShallow){const l=ri(s);if(zt(i)||ri(i)||(s=Te(s),i=Te(i)),!ae(t)&&pt(s)&&!pt(i))return!l&&(s.value=i,!0)}const o=ae(t)&&ol(n)?Number(n)<t.length:Pe(t,n),a=Reflect.set(t,n,i,pt(t)?t:r);return t===Te(r)&&(o?Mn(i,s)&&yn(t,"set",n,i):yn(t,"add",n,i)),a}deleteProperty(t,n){const i=Pe(t,n);t[n];const r=Reflect.deleteProperty(t,n);return r&&i&&yn(t,"delete",n,void 0),r}has(t,n){const i=Reflect.has(t,n);return nn(n)&&sd.has(n)||ht(t,0,n),i}ownKeys(t){return ht(t,0,ae(t)?"length":ii),Reflect.ownKeys(t)}}class fv extends ad{constructor(t=!1){super(!0,t)}set(t,n){return!0}deleteProperty(t,n){return!0}}const mv=new ld,vv=new fv,_v=new ld(!0),_l=e=>e,Lo=e=>Reflect.getPrototypeOf(e);function Fo(e,t,n=!1,i=!1){const r=Te(e=e.__v_raw),s=Te(t);n||(Mn(t,s)&&ht(r,0,t),ht(r,0,s));const{has:o}=Lo(r),a=i?_l:n?wl:dt;return o.call(r,t)?a(e.get(t)):o.call(r,s)?a(e.get(s)):void(e!==r&&e.get(t))}function Oo(e,t=!1){const n=this.__v_raw,i=Te(n),r=Te(e);return t||(Mn(e,r)&&ht(i,0,e),ht(i,0,r)),e===r?n.has(e):n.has(e)||n.has(r)}function Do(e,t=!1){return e=e.__v_raw,!t&&ht(Te(e),0,ii),Reflect.get(e,"size",e)}function cd(e,t=!1){t||zt(e)||ri(e)||(e=Te(e));const n=Te(this);return Lo(n).has.call(n,e)||(n.add(e),yn(n,"add",e,e)),this}function ud(e,t,n=!1){n||zt(t)||ri(t)||(t=Te(t));const i=Te(this),{has:r,get:s}=Lo(i);let o=r.call(i,e);o||(e=Te(e),o=r.call(i,e));const a=s.call(i,e);return i.set(e,t),o?Mn(t,a)&&yn(i,"set",e,t):yn(i,"add",e,t),this}function hd(e){const t=Te(this),{has:n,get:i}=Lo(t);let r=n.call(t,e);r||(e=Te(e),r=n.call(t,e)),i&&i.call(t,e);const s=t.delete(e);return r&&yn(t,"delete",e,void 0),s}function dd(){const e=Te(this),t=e.size!==0,n=e.clear();return t&&yn(e,"clear",void 0,void 0),n}function Uo(e,t){return function(n,i){const r=this,s=r.__v_raw,o=Te(s),a=t?_l:e?wl:dt;return!e&&ht(o,0,ii),s.forEach((l,c)=>n.call(i,a(l),a(c),r))}}function Bo(e,t,n){return function(...i){const r=this.__v_raw,s=Te(r),o=ki(s),a=e==="entries"||e===Symbol.iterator&&o,l=e==="keys"&&o,c=r[e](...i),u=n?_l:t?wl:dt;return!t&&ht(s,0,l?fl:ii),{next(){const{value:h,done:p}=c.next();return p?{value:h,done:p}:{value:a?[u(h[0]),u(h[1])]:u(h),done:p}},[Symbol.iterator](){return this}}}}function Dn(e){return function(...t){return e!=="delete"&&(e==="clear"?void 0:this)}}function yv(){const e={get(r){return Fo(this,r)},get size(){return Do(this)},has:Oo,add:cd,set:ud,delete:hd,clear:dd,forEach:Uo(!1,!1)},t={get(r){return Fo(this,r,!1,!0)},get size(){return Do(this)},has:Oo,add(r){return cd.call(this,r,!0)},set(r,s){return ud.call(this,r,s,!0)},delete:hd,clear:dd,forEach:Uo(!1,!0)},n={get(r){return Fo(this,r,!0)},get size(){return Do(this,!0)},has(r){return Oo.call(this,r,!0)},add:Dn("add"),set:Dn("set"),delete:Dn("delete"),clear:Dn("clear"),forEach:Uo(!0,!1)},i={get(r){return Fo(this,r,!0,!0)},get size(){return Do(this,!0)},has(r){return Oo.call(this,r,!0)},add:Dn("add"),set:Dn("set"),delete:Dn("delete"),clear:Dn("clear"),forEach:Uo(!0,!0)};return["keys","values","entries",Symbol.iterator].forEach(r=>{e[r]=Bo(r,!1,!1),n[r]=Bo(r,!0,!1),t[r]=Bo(r,!1,!0),i[r]=Bo(r,!0,!0)}),[e,n,t,i]}const[bv,xv,wv,Ev]=yv();function yl(e,t){const n=t?e?Ev:wv:e?xv:bv;return(i,r,s)=>r==="__v_isReactive"?!e:r==="__v_isReadonly"?e:r==="__v_raw"?i:Reflect.get(Pe(n,r)&&r in i?n:i,r,s)}const Cv={get:yl(!1,!1)},Av={get:yl(!1,!0)},Sv={get:yl(!0,!1)},pd=new WeakMap,gd=new WeakMap,fd=new WeakMap,Tv=new WeakMap;function Rv(e){return e.__v_skip||!Object.isExtensible(e)?0:function(t){switch(t){case"Object":case"Array":return 1;case"Map":case"Set":case"WeakMap":case"WeakSet":return 2;default:return 0}}((t=>mr(t).slice(8,-1))(e))}function Xe(e){return ri(e)?e:bl(e,!1,mv,Cv,pd)}function Bt(e){return bl(e,!0,vv,Sv,fd)}function bl(e,t,n,i,r){if(!Oe(e)||e.__v_raw&&(!t||!e.__v_isReactive))return e;const s=r.get(e);if(s)return s;const o=Rv(e);if(o===0)return e;const a=new Proxy(e,o===2?i:n);return r.set(e,a),a}function Ii(e){return ri(e)?Ii(e.__v_raw):!(!e||!e.__v_isReactive)}function ri(e){return!(!e||!e.__v_isReadonly)}function zt(e){return!(!e||!e.__v_isShallow)}function xl(e){return!!e&&!!e.__v_raw}function Te(e){const t=e&&e.__v_raw;return t?Te(t):e}const dt=e=>Oe(e)?Xe(e):e,wl=e=>Oe(e)?Bt(e):e;function pt(e){return!!e&&e.__v_isRef===!0}function le(e){return function(t,n){return pt(t)?t:new kv(t,n)}(e,!1)}class kv{constructor(t,n){this.dep=new pl,this.__v_isRef=!0,this.__v_isShallow=!1,this._rawValue=n?t:Te(t),this._value=n?t:dt(t),this.__v_isShallow=n}get value(){return this.dep.track(),this._value}set value(t){const n=this._rawValue,i=this.__v_isShallow||zt(t)||ri(t);t=i?t:Te(t),Mn(t,n)&&(this._rawValue=t,this._value=i?t:dt(t),this.dep.trigger())}}function D(e){return pt(e)?e.value:e}const Pv={get:(e,t,n)=>t==="__v_raw"?e:D(Reflect.get(e,t,n)),set:(e,t,n,i)=>{const r=e[t];return pt(r)&&!pt(n)?(r.value=n,!0):Reflect.set(e,t,n,i)}};function md(e){return Ii(e)?e:new Proxy(e,Pv)}class Iv{constructor(t,n,i){this.fn=t,this.setter=n,this._value=void 0,this.dep=new pl(this),this.__v_isRef=!0,this.deps=void 0,this.depsTail=void 0,this.flags=16,this.globalVersion=yr-1,this.effect=this,this.__v_isReadonly=!n,this.isSSR=i}notify(){this.flags|=16,De!==this&&this.dep.notify()}get value(){const t=this.dep.track();return td(this),t&&(t.version=this.dep.version),this._value}set value(t){this.setter&&this.setter(t)}}const zo={},jo=new WeakMap;let oi;function Mv(e,t,n=Ee){const{immediate:i,deep:r,once:s,scheduler:o,augmentJob:a,call:l}=n,c=R=>r?R:zt(R)||r===!1||r===0?xn(R,1):xn(R);let u,h,p,f,m=!1,_=!1;if(pt(e)?(h=()=>e.value,m=zt(e)):Ii(e)?(h=()=>c(e),m=!0):ae(e)?(_=!0,m=e.some(R=>Ii(R)||zt(R)),h=()=>e.map(R=>pt(R)?R.value:Ii(R)?c(R):pe(R)?l?l(R,2):R():void 0)):h=pe(e)?t?l?()=>l(e,2):e:()=>{if(p){Fn();try{p()}finally{On()}}const R=oi;oi=u;try{return l?l(e,3,[f]):e(f)}finally{oi=R}}:_n,t&&r){const R=h,b=r===!0?1/0:r;h=()=>xn(R(),b)}const y=Lt,x=()=>{u.stop(),y&&il(y.effects,u)};if(s)if(t){const R=t;t=(...b)=>{R(...b),x()}}else{const R=h;h=()=>{R(),x()}}let w=_?new Array(e.length).fill(zo):zo;const T=R=>{if(1&u.flags&&(u.dirty||R))if(t){const b=u.run();if(r||m||(_?b.some((k,F)=>Mn(k,w[F])):Mn(b,w))){p&&p();const k=oi;oi=u;try{const F=[b,w===zo?void 0:_&&w[0]===zo?[]:w,f];l?l(t,3,F):t(...F),w=b}finally{oi=k}}}else u.run()};return a&&a(T),u=new Kh(h),u.scheduler=o?()=>o(T,!1):T,f=R=>function(b,k=!1,F=oi){if(F){let j=jo.get(F);j||jo.set(F,j=[]),j.push(b)}}(R,!1,u),p=u.onStop=()=>{const R=jo.get(u);if(R){if(l)l(R,4);else for(const b of R)b();jo.delete(u)}},t?i?T(!0):w=u.run():o?o(T.bind(null,!0),!0):u.run(),x.pause=u.pause.bind(u),x.resume=u.resume.bind(u),x.stop=x,x}function xn(e,t=1/0,n){if(t<=0||!Oe(e)||e.__v_skip||(n=n||new Set).has(e))return e;if(n.add(e),t--,pt(e))xn(e.value,t,n);else if(ae(e))for(let i=0;i<e.length;i++)xn(e[i],t,n);else if(So(e)||ki(e))e.forEach(i=>{xn(i,t,n)});else if(Gh(e)){for(const i in e)xn(e[i],t,n);for(const i of Object.getOwnPropertySymbols(e))Object.prototype.propertyIsEnumerable.call(e,i)&&xn(e[i],t,n)}return e}/**
  * @vue/runtime-core v3.5.5
  * (c) 2018-present Yuxi (Evan) You and Vue contributors
  * @license MIT
  **/function wr(e,t,n,i){try{return i?e(...i):e()}catch(r){Er(r,t,n)}}function Zt(e,t,n,i){if(pe(e)){const r=wr(e,t,n,i);return r&&rl(r)&&r.catch(s=>{Er(s,t,n)}),r}if(ae(e)){const r=[];for(let s=0;s<e.length;s++)r.push(Zt(e[s],t,n,i));return r}}function Er(e,t,n,i=!0){t&&t.vnode;const{errorHandler:r,throwUnhandledErrorInProduction:s}=t&&t.appContext.config||Ee;if(t){let o=t.parent;const a=t.proxy,l=`https://vuejs.org/error-reference/#runtime-${n}`;for(;o;){const c=o.ec;if(c){for(let u=0;u<c.length;u++)if(c[u](e,a,l)===!1)return}o=o.parent}if(r)return Fn(),wr(r,null,10,[e,a,l]),void On()}(function(o,a,l,c=!0,u=!1){if(u)throw o;console.error(o)})(e,0,0,i,s)}let Cr=!1,El=!1;const _t=[];let rn=0;const Mi=[];let Un=null,Li=0;const vd=Promise.resolve();let Cl=null;function Lv(e){const t=Cl||vd;return e?t.then(this?e.bind(this):e):t}function Al(e){if(!(1&e.flags)){const t=Ar(e),n=_t[_t.length-1];!n||!(2&e.flags)&&t>=Ar(n)?_t.push(e):_t.splice(function(i){let r=Cr?rn+1:0,s=_t.length;for(;r<s;){const o=r+s>>>1,a=_t[o],l=Ar(a);l<i||l===i&&2&a.flags?r=o+1:s=o}return r}(t),0,e),e.flags|=1,_d()}}function _d(){Cr||El||(El=!0,Cl=vd.then(xd))}function Sl(e){ae(e)?Mi.push(...e):Un&&e.id===-1?Un.splice(Li+1,0,e):1&e.flags||(Mi.push(e),e.flags|=1),_d()}function yd(e,t,n=Cr?rn+1:0){for(;n<_t.length;n++){const i=_t[n];if(i&&2&i.flags){if(e&&i.id!==e.uid)continue;_t.splice(n,1),n--,4&i.flags&&(i.flags&=-2),i(),i.flags&=-2}}}function bd(e){if(Mi.length){const t=[...new Set(Mi)].sort((n,i)=>Ar(n)-Ar(i));if(Mi.length=0,Un)return void Un.push(...t);for(Un=t,Li=0;Li<Un.length;Li++){const n=Un[Li];4&n.flags&&(n.flags&=-2),8&n.flags||n(),n.flags&=-2}Un=null,Li=0}}const Ar=e=>e.id==null?2&e.flags?-1:1/0:e.id;function xd(e){El=!1,Cr=!0;try{for(rn=0;rn<_t.length;rn++){const t=_t[rn];!t||8&t.flags||(4&t.flags&&(t.flags&=-2),wr(t,t.i,t.i?15:14),t.flags&=-2)}}finally{for(;rn<_t.length;rn++){const t=_t[rn];t&&(t.flags&=-2)}rn=0,_t.length=0,bd(),Cr=!1,Cl=null,(_t.length||Mi.length)&&xd()}}let tt=null,wd=null;function No(e){const t=tt;return tt=e,wd=e&&e.type.__scopeId||null,t}function ye(e,t=tt,n){if(!t||e._n)return e;const i=(...r)=>{i._d&&fp(-1);const s=No(t);let o;try{o=e(...r)}finally{No(s),i._d&&fp(1)}return o};return i._n=!0,i._c=!0,i._d=!0,i}function yt(e,t){if(tt===null)return e;const n=ts(tt),i=e.dirs||(e.dirs=[]);for(let r=0;r<t.length;r++){let[s,o,a,l=Ee]=t[r];s&&(pe(s)&&(s={mounted:s,updated:s}),s.deep&&xn(o),i.push({dir:s,instance:n,value:o,oldValue:void 0,arg:a,modifiers:l}))}return e}function si(e,t,n,i){const r=e.dirs,s=t&&t.dirs;for(let o=0;o<r.length;o++){const a=r[o];s&&(a.oldValue=s[o].value);let l=a.dir[i];l&&(Fn(),Zt(l,n,8,[e.el,a,e,t]),On())}}const Ed=Symbol("_vte"),Cd=e=>e.__isTeleport,Sr=e=>e&&(e.disabled||e.disabled===""),Ad=e=>typeof SVGElement<"u"&&e instanceof SVGElement,Sd=e=>typeof MathMLElement=="function"&&e instanceof MathMLElement,Tl=(e,t)=>{const n=e&&e.to;return Ne(n)?t?t(n):null:n},Fv={name:"Teleport",__isTeleport:!0,process(e,t,n,i,r,s,o,a,l,c){const{mc:u,pc:h,pbc:p,o:{insert:f,querySelector:m,createText:_,createComment:y}}=c,x=Sr(t.props);let{shapeFlag:w,children:T,dynamicChildren:R}=t;if(e==null){const k=t.el=_(""),F=t.anchor=_("");f(k,n,i),f(F,n,i);const j=(N,Y)=>{16&w&&(r&&r.isCE&&(r.ce._teleportTarget=N),u(T,N,Y,r,s,o,a,l))},B=()=>{const N=t.target=Tl(t.props,m),Y=Td(N,t,_,f);N&&(o!=="svg"&&Ad(N)?o="svg":o!=="mathml"&&Sd(N)&&(o="mathml"),x||(j(N,Y),Vo(t)))};x&&(j(n,F),Vo(t)),(b=t.props)&&(b.defer||b.defer==="")?Ct(B,s):B()}else{t.el=e.el,t.targetStart=e.targetStart;const k=t.anchor=e.anchor,F=t.target=e.target,j=t.targetAnchor=e.targetAnchor,B=Sr(e.props),N=B?n:F,Y=B?k:j;if(o==="svg"||Ad(F)?o="svg":(o==="mathml"||Sd(F))&&(o="mathml"),R?(p(e.dynamicChildren,R,N,r,s,o,a),zl(e,t,!0)):l||h(e,t,N,Y,r,s,o,a,!1),x)B?t.props&&e.props&&t.props.to!==e.props.to&&(t.props.to=e.props.to):Go(t,n,k,c,1);else if((t.props&&t.props.to)!==(e.props&&e.props.to)){const ee=t.target=Tl(t.props,m);ee&&Go(t,ee,null,c,0)}else B&&Go(t,F,j,c,1);Vo(t)}var b},remove(e,t,n,{um:i,o:{remove:r}},s){const{shapeFlag:o,children:a,anchor:l,targetStart:c,targetAnchor:u,target:h,props:p}=e;if(h&&(r(c),r(u)),s&&r(l),16&o){const f=s||!Sr(p);for(let m=0;m<a.length;m++){const _=a[m];i(_,t,n,f,!!_.dynamicChildren)}}},move:Go,hydrate:function(e,t,n,i,r,s,{o:{nextSibling:o,parentNode:a,querySelector:l,insert:c,createText:u}},h){const p=t.target=Tl(t.props,l);if(p){const f=p._lpa||p.firstChild;if(16&t.shapeFlag)if(Sr(t.props))t.anchor=h(o(e),t,a(e),n,i,r,s),t.targetStart=f,t.targetAnchor=f&&o(f);else{t.anchor=o(e);let m=f;for(;m;){if(m&&m.nodeType===8){if(m.data==="teleport start anchor")t.targetStart=m;else if(m.data==="teleport anchor"){t.targetAnchor=m,p._lpa=t.targetAnchor&&o(t.targetAnchor);break}}m=o(m)}t.targetAnchor||Td(p,t,u,c),h(f&&o(f),t,p,n,i,r,s)}Vo(t)}return t.anchor&&o(t.anchor)}};function Go(e,t,n,{o:{insert:i},m:r},s=2){s===0&&i(e.targetAnchor,t,n);const{el:o,anchor:a,shapeFlag:l,children:c,props:u}=e,h=s===2;if(h&&i(o,t,n),(!h||Sr(u))&&16&l)for(let p=0;p<c.length;p++)r(c[p],t,n,2);h&&i(a,t,n)}const Ov=Fv;function Vo(e){const t=e.ctx;if(t&&t.ut){let n=e.targetStart;for(;n&&n!==e.targetAnchor;)n.nodeType===1&&n.setAttribute("data-v-owner",t.uid),n=n.nextSibling;t.ut()}}function Td(e,t,n,i){const r=t.targetStart=n(""),s=t.targetAnchor=n("");return r[Ed]=s,e&&(i(r,e),i(s,e)),s}const Bn=Symbol("_leaveCb"),$o=Symbol("_enterCb"),jt=[Function,Array],Rd={mode:String,appear:Boolean,persisted:Boolean,onBeforeEnter:jt,onEnter:jt,onAfterEnter:jt,onEnterCancelled:jt,onBeforeLeave:jt,onLeave:jt,onAfterLeave:jt,onLeaveCancelled:jt,onBeforeAppear:jt,onAppear:jt,onAfterAppear:jt,onAppearCancelled:jt},kd=e=>{const t=e.subTree;return t.component?kd(t.component):t};function Pd(e){let t=e[0];if(e.length>1){for(const n of e)if(n.type!==st){t=n;break}}return t}const Dv={name:"BaseTransition",props:Rd,setup(e,{slots:t}){const n=Nt(),i=function(){const r={isMounted:!1,isLeaving:!1,isUnmounting:!1,leavingVNodes:new Map};return We(()=>{r.isMounted=!0}),Ud(()=>{r.isUnmounting=!0}),r}();return()=>{const r=t.default&&Ld(t.default(),!0);if(!r||!r.length)return;const s=Pd(r),o=Te(e),{mode:a}=o;if(i.isLeaving)return kl(s);const l=Md(s);if(!l)return kl(s);let c=Rl(l,o,i,n,p=>c=p);l.type!==st&&Tr(l,c);const u=n.subTree,h=u&&Md(u);if(h&&h.type!==st&&!on(l,h)&&kd(n).type!==st){const p=Rl(h,o,i,n);if(Tr(h,p),a==="out-in"&&l.type!==st)return i.isLeaving=!0,p.afterLeave=()=>{i.isLeaving=!1,8&n.job.flags||n.update(),delete p.afterLeave},kl(s);a==="in-out"&&l.type!==st&&(p.delayLeave=(f,m,_)=>{Id(i,h)[String(h.key)]=h,f[Bn]=()=>{m(),f[Bn]=void 0,delete c.delayedLeave},c.delayedLeave=_})}return s}}};function Id(e,t){const{leavingVNodes:n}=e;let i=n.get(t.type);return i||(i=Object.create(null),n.set(t.type,i)),i}function Rl(e,t,n,i,r){const{appear:s,mode:o,persisted:a=!1,onBeforeEnter:l,onEnter:c,onAfterEnter:u,onEnterCancelled:h,onBeforeLeave:p,onLeave:f,onAfterLeave:m,onLeaveCancelled:_,onBeforeAppear:y,onAppear:x,onAfterAppear:w,onAppearCancelled:T}=t,R=String(e.key),b=Id(n,e),k=(B,N)=>{B&&Zt(B,i,9,N)},F=(B,N)=>{const Y=N[1];k(B,N),ae(B)?B.every(ee=>ee.length<=1)&&Y():B.length<=1&&Y()},j={mode:o,persisted:a,beforeEnter(B){let N=l;if(!n.isMounted){if(!s)return;N=y||l}B[Bn]&&B[Bn](!0);const Y=b[R];Y&&on(e,Y)&&Y.el[Bn]&&Y.el[Bn](),k(N,[B])},enter(B){let N=c,Y=u,ee=h;if(!n.isMounted){if(!s)return;N=x||c,Y=w||u,ee=T||h}let ne=!1;const G=B[$o]=V=>{ne||(ne=!0,k(V?ee:Y,[B]),j.delayedLeave&&j.delayedLeave(),B[$o]=void 0)};N?F(N,[B,G]):G()},leave(B,N){const Y=String(e.key);if(B[$o]&&B[$o](!0),n.isUnmounting)return N();k(p,[B]);let ee=!1;const ne=B[Bn]=G=>{ee||(ee=!0,N(),k(G?_:m,[B]),B[Bn]=void 0,b[Y]===e&&delete b[Y])};b[Y]=e,f?F(f,[B,ne]):ne()},clone(B){const N=Rl(B,t,n,i,r);return r&&r(N),N}};return j}function kl(e){if(qo(e))return(e=jn(e)).children=null,e}function Md(e){if(!qo(e))return Cd(e.type)&&e.children?Pd(e.children):e;const{shapeFlag:t,children:n}=e;if(n){if(16&t)return n[0];if(32&t&&pe(n.default))return n.default()}}function Tr(e,t){6&e.shapeFlag&&e.component?(e.transition=t,Tr(e.component.subTree,t)):128&e.shapeFlag?(e.ssContent.transition=t.clone(e.ssContent),e.ssFallback.transition=t.clone(e.ssFallback)):e.transition=t}function Ld(e,t=!1,n){let i=[],r=0;for(let s=0;s<e.length;s++){let o=e[s];const a=n==null?o.key:String(n)+String(o.key!=null?o.key:s);o.type===be?(128&o.patchFlag&&r++,i=i.concat(Ld(o.children,t,a))):(t||o.type!==st)&&i.push(a!=null?jn(o,{key:a}):o)}if(r>1)for(let s=0;s<i.length;s++)i[s].patchFlag=-2;return i}function Fd(e){e.ids=[e.ids[0]+e.ids[2]+++"-",0,0]}function Pl(e,t,n,i,r=!1){if(ae(e))return void e.forEach((m,_)=>Pl(m,t&&(ae(t)?t[_]:t),n,i,r));if(Fi(i)&&!r)return;const s=4&i.shapeFlag?ts(i.component):i.el,o=r?null:s,{i:a,r:l}=e,c=t&&t.r,u=a.refs===Ee?a.refs={}:a.refs,h=a.setupState,p=Te(h),f=h===Ee?()=>!1:m=>Pe(p,m);if(c!=null&&c!==l&&(Ne(c)?(u[c]=null,f(c)&&(h[c]=null)):pt(c)&&(c.value=null)),pe(l))wr(l,a,12,[o,u]);else{const m=Ne(l),_=pt(l);if(m||_){const y=()=>{if(e.f){const x=m?f(l)?h[l]:u[l]:l.value;r?ae(x)&&il(x,s):ae(x)?x.includes(s)||x.push(s):m?(u[l]=[s],f(l)&&(h[l]=u[l])):(l.value=[s],e.k&&(u[e.k]=l.value))}else m?(u[l]=o,f(l)&&(h[l]=o)):_&&(l.value=o,e.k&&(u[e.k]=o))};o?(y.id=-1,Ct(y,n)):y()}}}const Fi=e=>!!e.type.__asyncLoader,qo=e=>e.type.__isKeepAlive;function Uv(e,t){Od(e,"a",t)}function Bv(e,t){Od(e,"da",t)}function Od(e,t,n=at){const i=e.__wdc||(e.__wdc=()=>{let r=n;for(;r;){if(r.isDeactivated)return;r=r.parent}return e()});if(Xo(t,i,n),n){let r=n.parent;for(;r&&r.parent;)qo(r.parent.vnode)&&zv(i,t,n,r),r=r.parent}}function zv(e,t,n,i){const r=Xo(t,e,i,!0);Wo(()=>{il(i[t],r)},n)}function Xo(e,t,n=at,i=!1){if(n){const r=n[e]||(n[e]=[]),s=t.__weh||(t.__weh=(...o)=>{Fn();const a=ci(n),l=Zt(t,n,e,o);return a(),On(),l});return i?r.unshift(s):r.push(s),s}}const wn=e=>(t,n=at)=>{es&&e!=="sp"||Xo(e,(...i)=>t(...i),n)},Dd=wn("bm"),We=wn("m"),jv=wn("bu"),Nv=wn("u"),Ud=wn("bum"),Wo=wn("um"),Gv=wn("sp"),Vv=wn("rtg"),$v=wn("rtc");function qv(e,t=at){Xo("ec",e,t)}const Bd=Symbol.for("v-ndc");function ai(e){return Ne(e)?function(t,n,i=!0,r=!1){const s=tt||at;if(s){const o=s.type;{const l=h_(o,!1);if(l&&(l===n||l===Wt(n)||l===Ro(Wt(n))))return o}const a=zd(s[t]||o[t],n)||zd(s.appContext[t],n);return!a&&r?o:a}}("components",e,!1)||e:e||Bd}function zd(e,t){return e&&(e[t]||e[Wt(t)]||e[Ro(Wt(t))])}function Qe(e,t,n,i){let r;const s=n,o=ae(e);if(o||Ne(e)){let a=!1;o&&Ii(e)&&(a=!zt(e),e=Mo(e)),r=new Array(e.length);for(let l=0,c=e.length;l<c;l++)r[l]=t(a?dt(e[l]):e[l],l,void 0,s)}else if(typeof e=="number"){r=new Array(e);for(let a=0;a<e;a++)r[a]=t(a+1,a,void 0,s)}else if(Oe(e))if(e[Symbol.iterator])r=Array.from(e,(a,l)=>t(a,l,void 0,s));else{const a=Object.keys(e);r=new Array(a.length);for(let l=0,c=a.length;l<c;l++){const u=a[l];r[l]=t(e[u],u,l,s)}}else r=[];return r}function Me(e,t,n={},i,r){if(tt.ce||tt.parent&&Fi(tt.parent)&&tt.parent.ce)return t!=="default"&&(n.name=t),I(),ce(be,null,[Q("slot",n,i&&i())],64);let s=e[t];s&&s._c&&(s._d=!1),I();const o=s&&jd(s(n)),a=ce(be,{key:(n.key||o&&o.key||`_${t}`)+(!o&&i?"_fb":"")},o||(i?i():[]),o&&e._===1?64:-2);return!r&&a.scopeId&&(a.slotScopeIds=[a.scopeId+"-s"]),s&&s._c&&(s._d=!0),a}function jd(e){return e.some(t=>!Lr(t)||t.type!==st&&!(t.type===be&&!jd(t.children)))?e:null}const Il=e=>e?_p(e)?ts(e):Il(e.parent):null,Rr=et(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=>Il(e.parent),$root:e=>Il(e.root),$host:e=>e.ce,$emit:e=>e.emit,$options:e=>Fl(e),$forceUpdate:e=>e.f||(e.f=()=>{Al(e.update)}),$nextTick:e=>e.n||(e.n=Lv.bind(e.proxy)),$watch:e=>i_.bind(e)}),Ml=(e,t)=>e!==Ee&&!e.__isScriptSetup&&Pe(e,t),Xv={get({_:e},t){if(t==="__v_skip")return!0;const{ctx:n,setupState:i,data:r,props:s,accessCache:o,type:a,appContext:l}=e;let c;if(t[0]!=="$"){const f=o[t];if(f!==void 0)switch(f){case 1:return i[t];case 2:return r[t];case 4:return n[t];case 3:return s[t]}else{if(Ml(i,t))return o[t]=1,i[t];if(r!==Ee&&Pe(r,t))return o[t]=2,r[t];if((c=e.propsOptions[0])&&Pe(c,t))return o[t]=3,s[t];if(n!==Ee&&Pe(n,t))return o[t]=4,n[t];Ll&&(o[t]=0)}}const u=Rr[t];let h,p;return u?(t==="$attrs"&&ht(e.attrs,0,""),u(e)):(h=a.__cssModules)&&(h=h[t])?h:n!==Ee&&Pe(n,t)?(o[t]=4,n[t]):(p=l.config.globalProperties,Pe(p,t)?p[t]:void 0)},set({_:e},t,n){const{data:i,setupState:r,ctx:s}=e;return Ml(r,t)?(r[t]=n,!0):i!==Ee&&Pe(i,t)?(i[t]=n,!0):!Pe(e.props,t)&&(t[0]!=="$"||!(t.slice(1)in e))&&(s[t]=n,!0)},has({_:{data:e,setupState:t,accessCache:n,ctx:i,appContext:r,propsOptions:s}},o){let a;return!!n[o]||e!==Ee&&Pe(e,o)||Ml(t,o)||(a=s[0])&&Pe(a,o)||Pe(i,o)||Pe(Rr,o)||Pe(r.config.globalProperties,o)},defineProperty(e,t,n){return n.get!=null?e._.accessCache[t]=0:Pe(n,"value")&&this.set(e,t,n.value,null),Reflect.defineProperty(e,t,n)}};function Nd(){return function(){const e=Nt();return e.setupContext||(e.setupContext=xp(e))}().slots}function Gd(e){return ae(e)?e.reduce((t,n)=>(t[n]=null,t),{}):e}function Vd(e){const t=Nt();let n=e();return Wl(),rl(n)&&(n=n.catch(i=>{throw ci(t),i})),[n,()=>ci(t)]}let Ll=!0;function Wv(e){const t=Fl(e),n=e.proxy,i=e.ctx;Ll=!1,t.beforeCreate&&$d(t.beforeCreate,e,"bc");const{data:r,computed:s,methods:o,watch:a,provide:l,inject:c,created:u,beforeMount:h,mounted:p,beforeUpdate:f,updated:m,activated:_,deactivated:y,beforeDestroy:x,beforeUnmount:w,destroyed:T,unmounted:R,render:b,renderTracked:k,renderTriggered:F,errorCaptured:j,serverPrefetch:B,expose:N,inheritAttrs:Y,components:ee,directives:ne,filters:G}=t;if(c&&function(q,W){ae(q)&&(q=Ol(q));for(const se in q){const he=q[se];let Ie;Ie=Oe(he)?"default"in he?Ye(he.from||se,he.default,!0):Ye(he.from||se):Ye(he),pt(Ie)?Object.defineProperty(W,se,{enumerable:!0,configurable:!0,get:()=>Ie.value,set:Fe=>Ie.value=Fe}):W[se]=Ie}}(c,i,null),o)for(const q in o){const W=o[q];pe(W)&&(i[q]=W.bind(n))}if(r){const q=r.call(n,n);Oe(q)&&(e.data=Xe(q))}if(Ll=!0,s)for(const q in s){const W=s[q],se=pe(W)?W.bind(n,n):pe(W.get)?W.get.bind(n,n):_n,he=!pe(W)&&pe(W.set)?W.set.bind(n):_n,Ie=te({get:se,set:he});Object.defineProperty(i,q,{enumerable:!0,configurable:!0,get:()=>Ie.value,set:Fe=>Ie.value=Fe})}if(a)for(const q in a)qd(a[q],i,n,q);if(l){const q=pe(l)?l.call(n):l;Reflect.ownKeys(q).forEach(W=>{zn(W,q[W])})}function V(q,W){ae(W)?W.forEach(se=>q(se.bind(n))):W&&q(W.bind(n))}if(u&&$d(u,e,"c"),V(Dd,h),V(We,p),V(jv,f),V(Nv,m),V(Uv,_),V(Bv,y),V(qv,j),V($v,k),V(Vv,F),V(Ud,w),V(Wo,R),V(Gv,B),ae(N))if(N.length){const q=e.exposed||(e.exposed={});N.forEach(W=>{Object.defineProperty(q,W,{get:()=>n[W],set:se=>n[W]=se})})}else e.exposed||(e.exposed={});b&&e.render===_n&&(e.render=b),Y!=null&&(e.inheritAttrs=Y),ee&&(e.components=ee),ne&&(e.directives=ne),B&&Fd(e)}function $d(e,t,n){Zt(ae(e)?e.map(i=>i.bind(t.proxy)):e.bind(t.proxy),t,n)}function qd(e,t,n,i){let r=i.includes(".")?ap(n,i):()=>n[i];if(Ne(e)){const s=t[e];pe(s)&&Re(r,s)}else if(pe(e))Re(r,e.bind(n));else if(Oe(e))if(ae(e))e.forEach(s=>qd(s,t,n,i));else{const s=pe(e.handler)?e.handler.bind(n):t[e.handler];pe(s)&&Re(r,s,e)}}function Fl(e){const t=e.type,{mixins:n,extends:i}=t,{mixins:r,optionsCache:s,config:{optionMergeStrategies:o}}=e.appContext,a=s.get(t);let l;return a?l=a:r.length||n||i?(l={},r.length&&r.forEach(c=>Yo(l,c,o,!0)),Yo(l,t,o)):l=t,Oe(t)&&s.set(t,l),l}function Yo(e,t,n,i=!1){const{mixins:r,extends:s}=t;s&&Yo(e,s,n,!0),r&&r.forEach(o=>Yo(e,o,n,!0));for(const o in t)if(!(i&&o==="expose")){const a=Yv[o]||n&&n[o];e[o]=a?a(e[o],t[o]):t[o]}return e}const Yv={data:Xd,props:Wd,emits:Wd,methods:kr,computed:kr,beforeCreate:bt,created:bt,beforeMount:bt,mounted:bt,beforeUpdate:bt,updated:bt,beforeDestroy:bt,beforeUnmount:bt,destroyed:bt,unmounted:bt,activated:bt,deactivated:bt,errorCaptured:bt,serverPrefetch:bt,components:kr,directives:kr,watch:function(e,t){if(!e)return t;if(!t)return e;const n=et(Object.create(null),e);for(const i in t)n[i]=bt(e[i],t[i]);return n},provide:Xd,inject:function(e,t){return kr(Ol(e),Ol(t))}};function Xd(e,t){return t?e?function(){return et(pe(e)?e.call(this,this):e,pe(t)?t.call(this,this):t)}:t:e}function Ol(e){if(ae(e)){const t={};for(let n=0;n<e.length;n++)t[e[n]]=e[n];return t}return e}function bt(e,t){return e?[...new Set([].concat(e,t))]:t}function kr(e,t){return e?et(Object.create(null),e,t):t}function Wd(e,t){return e?ae(e)&&ae(t)?[...new Set([...e,...t])]:et(Object.create(null),Gd(e),Gd(t??{})):t}function Yd(){return{app:null,config:{isNativeTag:Qm,performance:!1,globalProperties:{},optionMergeStrategies:{},errorHandler:void 0,warnHandler:void 0,compilerOptions:{}},mixins:[],components:{},directives:{},provides:Object.create(null),optionsCache:new WeakMap,propsCache:new WeakMap,emitsCache:new WeakMap}}let Zv=0;function Hv(e,t){return function(n,i=null){pe(n)||(n=et({},n)),i==null||Oe(i)||(i=null);const r=Yd(),s=new WeakSet,o=[];let a=!1;const l=r.app={_uid:Zv++,_component:n,_props:i,_container:null,_context:r,_instance:null,version:d_,get config(){return r.config},set config(c){},use:(c,...u)=>(s.has(c)||(c&&pe(c.install)?(s.add(c),c.install(l,...u)):pe(c)&&(s.add(c),c(l,...u))),l),mixin:c=>(r.mixins.includes(c)||r.mixins.push(c),l),component:(c,u)=>u?(r.components[c]=u,l):r.components[c],directive:(c,u)=>u?(r.directives[c]=u,l):r.directives[c],mount(c,u,h){if(!a){const p=l._ceVNode||Q(n,i);return p.appContext=r,h===!0?h="svg":h===!1&&(h=void 0),u&&t?t(p,c):e(p,c,h),a=!0,l._container=c,c.__vue_app__=l,ts(p.component)}},onUnmount(c){o.push(c)},unmount(){a&&(Zt(o,l._instance,16),e(null,l._container),delete l._container.__vue_app__)},provide:(c,u)=>(r.provides[c]=u,l),runWithContext(c){const u=Oi;Oi=l;try{return c()}finally{Oi=u}}};return l}}let Oi=null;function zn(e,t){if(at){let n=at.provides;const i=at.parent&&at.parent.provides;i===n&&(n=at.provides=Object.create(i)),n[e]=t}}function Ye(e,t,n=!1){const i=at||tt;if(i||Oi){const r=Oi?Oi._context.provides:i?i.parent==null?i.vnode.appContext&&i.vnode.appContext.provides:i.parent.provides:void 0;if(r&&e in r)return r[e];if(arguments.length>1)return n&&pe(t)?t.call(i&&i.proxy):t}}const Zd={},Hd=()=>Object.create(Zd),Kd=e=>Object.getPrototypeOf(e)===Zd;function Kv(e,t,n,i=!1){const r={},s=Hd();e.propsDefaults=Object.create(null),Qd(e,t,r,s);for(const o in e.propsOptions[0])o in r||(r[o]=void 0);n?e.props=i?r:bl(r,!1,_v,Av,gd):e.type.props?e.props=r:e.props=s,e.attrs=s}function Qd(e,t,n,i){const[r,s]=e.propsOptions;let o,a=!1;if(t)for(let l in t){if(vr(l))continue;const c=t[l];let u;r&&Pe(r,u=Wt(l))?s&&s.includes(u)?(o||(o={}))[u]=c:n[u]=c:Zo(e.emitsOptions,l)||l in i&&c===i[l]||(i[l]=c,a=!0)}if(s){const l=Te(n),c=o||Ee;for(let u=0;u<s.length;u++){const h=s[u];n[h]=Dl(r,l,h,c[h],e,!Pe(c,h))}}return a}function Dl(e,t,n,i,r,s){const o=e[n];if(o!=null){const a=Pe(o,"default");if(a&&i===void 0){const l=o.default;if(o.type!==Function&&!o.skipFactory&&pe(l)){const{propsDefaults:c}=r;if(n in c)i=c[n];else{const u=ci(r);i=c[n]=l.call(null,t),u()}}else i=l;r.ce&&r.ce._setProp(n,i)}o[0]&&(s&&!a?i=!1:!o[1]||i!==""&&i!==In(n)||(i=!0))}return i}const Qv=new WeakMap;function Jd(e,t,n=!1){const i=n?Qv:t.propsCache,r=i.get(e);if(r)return r;const s=e.props,o={},a=[];let l=!1;if(!pe(e)){const u=h=>{l=!0;const[p,f]=Jd(h,t,!0);et(o,p),f&&a.push(...f)};!n&&t.mixins.length&&t.mixins.forEach(u),e.extends&&u(e.extends),e.mixins&&e.mixins.forEach(u)}if(!s&&!l)return Oe(e)&&i.set(e,Xt),Xt;if(ae(s))for(let u=0;u<s.length;u++){const h=Wt(s[u]);ep(h)&&(o[h]=Ee)}else if(s)for(const u in s){const h=Wt(u);if(ep(h)){const p=s[u],f=o[h]=ae(p)||pe(p)?{type:p}:et({},p),m=f.type;let _=!1,y=!0;if(ae(m))for(let x=0;x<m.length;++x){const w=m[x],T=pe(w)&&w.name;if(T==="Boolean"){_=!0;break}T==="String"&&(y=!1)}else _=pe(m)&&m.name==="Boolean";f[0]=_,f[1]=y,(_||Pe(f,"default"))&&a.push(h)}}const c=[o,a];return Oe(e)&&i.set(e,c),c}function ep(e){return e[0]!=="$"&&!vr(e)}const tp=e=>e[0]==="_"||e==="$stable",Ul=e=>ae(e)?e.map(Ht):[Ht(e)],Jv=(e,t,n)=>{if(t._n)return t;const i=ye((...r)=>Ul(t(...r)),n);return i._c=!1,i},np=(e,t,n)=>{const i=e._ctx;for(const r in e){if(tp(r))continue;const s=e[r];if(pe(s))t[r]=Jv(0,s,i);else if(s!=null){const o=Ul(s);t[r]=()=>o}}},ip=(e,t)=>{const n=Ul(t);e.slots.default=()=>n},rp=(e,t,n)=>{for(const i in t)(n||i!=="_")&&(e[i]=t[i])},Ct=function(e,t){t&&t.pendingBranch?ae(e)?t.effects.push(...e):t.effects.push(e):Sl(e)};function e_(e){return function(t){Xh().__VUE__=!0;const{insert:n,remove:i,patchProp:r,createElement:s,createText:o,createComment:a,setText:l,setElementText:c,parentNode:u,nextSibling:h,setScopeId:p=_n,insertStaticContent:f}=t,m=(P,M,U,X=null,d=null,g=null,v=void 0,E=null,A=!!M.dynamicChildren)=>{if(P===M)return;P&&!on(P,M)&&(X=fe(P),Fe(P,d,g,!0),P=null),M.patchFlag===-2&&(A=!1,M.dynamicChildren=null);const{type:C,ref:L,shapeFlag:z}=M;switch(C){case Ho:_(P,M,U,X);break;case st:y(P,M,U,X);break;case Ir:P==null&&x(M,U,X,v);break;case be:Y(P,M,U,X,d,g,v,E,A);break;default:1&z?R(P,M,U,X,d,g,v,E,A):6&z?ee(P,M,U,X,d,g,v,E,A):(64&z||128&z)&&C.process(P,M,U,X,d,g,v,E,A,_e)}L!=null&&d&&Pl(L,P&&P.ref,g,M||P,!M)},_=(P,M,U,X)=>{if(P==null)n(M.el=o(M.children),U,X);else{const d=M.el=P.el;M.children!==P.children&&l(d,M.children)}},y=(P,M,U,X)=>{P==null?n(M.el=a(M.children||""),U,X):M.el=P.el},x=(P,M,U,X)=>{[P.el,P.anchor]=f(P.children,M,U,X,P.el,P.anchor)},w=({el:P,anchor:M},U,X)=>{let d;for(;P&&P!==M;)d=h(P),n(P,U,X),P=d;n(M,U,X)},T=({el:P,anchor:M})=>{let U;for(;P&&P!==M;)U=h(P),i(P),P=U;i(M)},R=(P,M,U,X,d,g,v,E,A)=>{M.type==="svg"?v="svg":M.type==="math"&&(v="mathml"),P==null?b(M,U,X,d,g,v,E,A):j(P,M,d,g,v,E,A)},b=(P,M,U,X,d,g,v,E)=>{let A,C;const{props:L,shapeFlag:z,transition:$,dirs:H}=P;if(A=P.el=s(P.type,g,L&&L.is,L),8&z?c(A,P.children):16&z&&F(P.children,A,null,X,d,Bl(P,g),v,E),H&&si(P,null,X,"created"),k(A,P,P.scopeId,v,X),L){for(const K in L)K==="value"||vr(K)||r(A,K,null,L[K],g,X);"value"in L&&r(A,"value",null,L.value,g),(C=L.onVnodeBeforeMount)&&sn(C,X,P)}H&&si(P,null,X,"beforeMount");const J=function(K,oe){return(!K||K&&!K.pendingBranch)&&oe&&!oe.persisted}(d,$);J&&$.beforeEnter(A),n(A,M,U),((C=L&&L.onVnodeMounted)||J||H)&&Ct(()=>{C&&sn(C,X,P),J&&$.enter(A),H&&si(P,null,X,"mounted")},d)},k=(P,M,U,X,d)=>{if(U&&p(P,U),X)for(let g=0;g<X.length;g++)p(P,X[g]);if(d){let g=d.subTree;if(M===g||up(g.type)&&(g.ssContent===M||g.ssFallback===M)){const v=d.vnode;k(P,v,v.scopeId,v.slotScopeIds,d.parent)}}},F=(P,M,U,X,d,g,v,E,A=0)=>{for(let C=A;C<P.length;C++){const L=P[C]=E?Nn(P[C]):Ht(P[C]);m(null,L,M,U,X,d,g,v,E)}},j=(P,M,U,X,d,g,v)=>{const E=M.el=P.el;let{patchFlag:A,dynamicChildren:C,dirs:L}=M;A|=16&P.patchFlag;const z=P.props||Ee,$=M.props||Ee;let H;if(U&&li(U,!1),(H=$.onVnodeBeforeUpdate)&&sn(H,U,M,P),L&&si(M,P,U,"beforeUpdate"),U&&li(U,!0),(z.innerHTML&&$.innerHTML==null||z.textContent&&$.textContent==null)&&c(E,""),C?B(P.dynamicChildren,C,E,U,X,Bl(M,d),g):v||W(P,M,E,null,U,X,Bl(M,d),g,!1),A>0){if(16&A)N(E,z,$,U,d);else if(2&A&&z.class!==$.class&&r(E,"class",null,$.class,d),4&A&&r(E,"style",z.style,$.style,d),8&A){const J=M.dynamicProps;for(let K=0;K<J.length;K++){const oe=J[K],qe=z[oe],Ue=$[oe];Ue===qe&&oe!=="value"||r(E,oe,qe,Ue,d,U)}}1&A&&P.children!==M.children&&c(E,M.children)}else v||C!=null||N(E,z,$,U,d);((H=$.onVnodeUpdated)||L)&&Ct(()=>{H&&sn(H,U,M,P),L&&si(M,P,U,"updated")},X)},B=(P,M,U,X,d,g,v)=>{for(let E=0;E<M.length;E++){const A=P[E],C=M[E],L=A.el&&(A.type===be||!on(A,C)||70&A.shapeFlag)?u(A.el):U;m(A,C,L,null,X,d,g,v,!0)}},N=(P,M,U,X,d)=>{if(M!==U){if(M!==Ee)for(const g in M)vr(g)||g in U||r(P,g,M[g],null,d,X);for(const g in U){if(vr(g))continue;const v=U[g],E=M[g];v!==E&&g!=="value"&&r(P,g,E,v,d,X)}"value"in U&&r(P,"value",M.value,U.value,d)}},Y=(P,M,U,X,d,g,v,E,A)=>{const C=M.el=P?P.el:o(""),L=M.anchor=P?P.anchor:o("");let{patchFlag:z,dynamicChildren:$,slotScopeIds:H}=M;H&&(E=E?E.concat(H):H),P==null?(n(C,U,X),n(L,U,X),F(M.children||[],U,L,d,g,v,E,A)):z>0&&64&z&&$&&P.dynamicChildren?(B(P.dynamicChildren,$,U,d,g,v,E),(M.key!=null||d&&M===d.subTree)&&zl(P,M,!0)):W(P,M,U,L,d,g,v,E,A)},ee=(P,M,U,X,d,g,v,E,A)=>{M.slotScopeIds=E,P==null?512&M.shapeFlag?d.ctx.activate(M,U,X,v,A):ne(M,U,X,d,g,v,A):G(P,M,A)},ne=(P,M,U,X,d,g,v)=>{const E=P.component=function(A,C,L){const z=A.type,$=(C?C.appContext:A.appContext)||l_,H={uid:c_++,vnode:A,type:z,parent:C,appContext:$,root:null,next:null,subTree:null,effect:null,update:null,job:null,scope:new lv(!0),render:null,proxy:null,exposed:null,exposeProxy:null,withProxy:null,provides:C?C.provides:Object.create($.provides),ids:C?C.ids:["",0,0],accessCache:null,renderCache:[],components:null,directives:null,propsOptions:Jd(z,$),emitsOptions:lp(z,$),emit:null,emitted:null,propsDefaults:Ee,inheritAttrs:z.inheritAttrs,ctx:Ee,data:Ee,props:Ee,attrs:Ee,slots:Ee,refs:Ee,setupState:Ee,setupContext:null,suspense:L,suspenseId:L?L.pendingId:0,asyncDep:null,asyncResolved:!1,isMounted:!1,isUnmounted:!1,isDeactivated:!1,bc:null,c:null,bm:null,m:null,bu:null,u:null,um:null,bum:null,da:null,a:null,rtg:null,rtc:null,ec:null,sp:null};return H.ctx={_:H},H.root=C?C.root:H,H.emit=o_.bind(null,H),A.ce&&A.ce(H),H}(P,X,d);if(qo(P)&&(E.ctx.renderer=_e),function(A,C=!1,L=!1){C&&Xl(C);const{props:z,children:$}=A.vnode,H=_p(A);Kv(A,z,H,C),((K,oe,qe)=>{const Ue=K.slots=Hd();if(32&K.vnode.shapeFlag){const vt=oe._;vt?(rp(Ue,oe,qe),qe&&Vh(Ue,"_",vt,!0)):np(oe,Ue)}else oe&&ip(K,oe)})(A,$,L);const J=H?function(K,oe){const qe=K.type;K.accessCache=Object.create(null),K.proxy=new Proxy(K.ctx,Xv);const{setup:Ue}=qe;if(Ue){const vt=K.setupContext=Ue.length>1?xp(K):null,wt=ci(K);Fn();const tn=wr(Ue,K,0,[K.props,vt]);if(On(),wt(),rl(tn)){if(Fi(K)||Fd(K),tn.then(Wl,Wl),oe)return tn.then(fr=>{Yl(K,fr,oe)}).catch(fr=>{Er(fr,K,0)});K.asyncDep=tn}else Yl(K,tn,oe)}else bp(K,oe)}(A,C):void 0;C&&Xl(!1)}(E,!1,v),E.asyncDep){if(d&&d.registerDep(E,V,v),!P.el){const A=E.subTree=Q(st);y(null,A,M,U)}}else V(E,P,M,U,d,g,v)},G=(P,M,U)=>{const X=M.component=P.component;if(function(d,g,v){const{props:E,children:A,component:C}=d,{props:L,children:z,patchFlag:$}=g,H=C.emitsOptions;if(g.dirs||g.transition)return!0;if(!(v&&$>=0))return!(!A&&!z||z&&z.$stable)||E!==L&&(E?!L||cp(E,L,H):!!L);if(1024&$)return!0;if(16&$)return E?cp(E,L,H):!!L;if(8&$){const J=g.dynamicProps;for(let K=0;K<J.length;K++){const oe=J[K];if(L[oe]!==E[oe]&&!Zo(H,oe))return!0}}return!1}(P,M,U)){if(X.asyncDep&&!X.asyncResolved)return void q(X,M,U);X.next=M,X.update()}else M.el=P.el,X.vnode=M},V=(P,M,U,X,d,g,v)=>{const E=()=>{if(P.isMounted){let{next:z,bu:$,u:H,parent:J,vnode:K}=P;{const wt=op(P);if(wt)return z&&(z.el=K.el,q(P,z,v)),void wt.asyncDep.then(()=>{P.isUnmounted||E()})}let oe,qe=z;li(P,!1),z?(z.el=K.el,q(P,z,v)):z=K,$&&ko($),(oe=z.props&&z.props.onVnodeBeforeUpdate)&&sn(oe,J,z,K),li(P,!0);const Ue=Nl(P),vt=P.subTree;P.subTree=Ue,m(vt,Ue,u(vt.el),fe(vt),P,d,g),z.el=Ue.el,qe===null&&Gl(P,Ue.el),H&&Ct(H,d),(oe=z.props&&z.props.onVnodeUpdated)&&Ct(()=>sn(oe,J,z,K),d)}else{let z;const{el:$,props:H}=M,{bm:J,m:K,parent:oe,root:qe,type:Ue}=P,vt=Fi(M);if(li(P,!1),J&&ko(J),!vt&&(z=H&&H.onVnodeBeforeMount)&&sn(z,oe,M),li(P,!0),$&&ut){const wt=()=>{P.subTree=Nl(P),ut($,P.subTree,P,d,null)};vt&&Ue.__asyncHydrate?Ue.__asyncHydrate($,P,wt):wt()}else{qe.ce&&qe.ce._injectChildStyle(Ue);const wt=P.subTree=Nl(P);m(null,wt,U,X,P,d,g),M.el=wt.el}if(K&&Ct(K,d),!vt&&(z=H&&H.onVnodeMounted)){const wt=M;Ct(()=>sn(z,oe,wt),d)}(256&M.shapeFlag||oe&&Fi(oe.vnode)&&256&oe.vnode.shapeFlag)&&P.a&&Ct(P.a,d),P.isMounted=!0,M=U=X=null}};P.scope.on();const A=P.effect=new Kh(E);P.scope.off();const C=P.update=A.run.bind(A),L=P.job=A.runIfDirty.bind(A);L.i=P,L.id=P.uid,A.scheduler=()=>Al(L),li(P,!0),C()},q=(P,M,U)=>{M.component=P;const X=P.vnode.props;P.vnode=M,P.next=null,function(d,g,v,E){const{props:A,attrs:C,vnode:{patchFlag:L}}=d,z=Te(A),[$]=d.propsOptions;let H=!1;if(!(E||L>0)||16&L){let J;Qd(d,g,A,C)&&(H=!0);for(const K in z)g&&(Pe(g,K)||(J=In(K))!==K&&Pe(g,J))||($?!v||v[K]===void 0&&v[J]===void 0||(A[K]=Dl($,z,K,void 0,d,!0)):delete A[K]);if(C!==z)for(const K in C)g&&Pe(g,K)||(delete C[K],H=!0)}else if(8&L){const J=d.vnode.dynamicProps;for(let K=0;K<J.length;K++){let oe=J[K];if(Zo(d.emitsOptions,oe))continue;const qe=g[oe];if($)if(Pe(C,oe))qe!==C[oe]&&(C[oe]=qe,H=!0);else{const Ue=Wt(oe);A[Ue]=Dl($,z,Ue,qe,d,!1)}else qe!==C[oe]&&(C[oe]=qe,H=!0)}}H&&yn(d.attrs,"set","")}(P,M.props,X,U),((d,g,v)=>{const{vnode:E,slots:A}=d;let C=!0,L=Ee;if(32&E.shapeFlag){const z=g._;z?v&&z===1?C=!1:rp(A,g,v):(C=!g.$stable,np(g,A)),L=g}else g&&(ip(d,g),L={default:1});if(C)for(const z in A)tp(z)||L[z]!=null||delete A[z]})(P,M.children,U),Fn(),yd(P),On()},W=(P,M,U,X,d,g,v,E,A=!1)=>{const C=P&&P.children,L=P?P.shapeFlag:0,z=M.children,{patchFlag:$,shapeFlag:H}=M;if($>0){if(128&$)return void he(C,z,U,X,d,g,v,E,A);if(256&$)return void se(C,z,U,X,d,g,v,E,A)}8&H?(16&L&&ot(C,d,g),z!==C&&c(U,z)):16&L?16&H?he(C,z,U,X,d,g,v,E,A):ot(C,d,g,!0):(8&L&&c(U,""),16&H&&F(z,U,X,d,g,v,E,A))},se=(P,M,U,X,d,g,v,E,A)=>{M=M||Xt;const C=(P=P||Xt).length,L=M.length,z=Math.min(C,L);let $;for($=0;$<z;$++){const H=M[$]=A?Nn(M[$]):Ht(M[$]);m(P[$],H,U,null,d,g,v,E,A)}C>L?ot(P,d,g,!0,!1,z):F(M,U,X,d,g,v,E,A,z)},he=(P,M,U,X,d,g,v,E,A)=>{let C=0;const L=M.length;let z=P.length-1,$=L-1;for(;C<=z&&C<=$;){const H=P[C],J=M[C]=A?Nn(M[C]):Ht(M[C]);if(!on(H,J))break;m(H,J,U,null,d,g,v,E,A),C++}for(;C<=z&&C<=$;){const H=P[z],J=M[$]=A?Nn(M[$]):Ht(M[$]);if(!on(H,J))break;m(H,J,U,null,d,g,v,E,A),z--,$--}if(C>z){if(C<=$){const H=$+1,J=H<L?M[H].el:X;for(;C<=$;)m(null,M[C]=A?Nn(M[C]):Ht(M[C]),U,J,d,g,v,E,A),C++}}else if(C>$)for(;C<=z;)Fe(P[C],d,g,!0),C++;else{const H=C,J=C,K=new Map;for(C=J;C<=$;C++){const Ke=M[C]=A?Nn(M[C]):Ht(M[C]);Ke.key!=null&&K.set(Ke.key,C)}let oe,qe=0;const Ue=$-J+1;let vt=!1,wt=0;const tn=new Array(Ue);for(C=0;C<Ue;C++)tn[C]=0;for(C=H;C<=z;C++){const Ke=P[C];if(qe>=Ue){Fe(Ke,d,g,!0);continue}let Mt;if(Ke.key!=null)Mt=K.get(Ke.key);else for(oe=J;oe<=$;oe++)if(tn[oe-J]===0&&on(Ke,M[oe])){Mt=oe;break}Mt===void 0?Fe(Ke,d,g,!0):(tn[Mt-J]=C+1,Mt>=wt?wt=Mt:vt=!0,m(Ke,M[Mt],U,null,d,g,v,E,A),qe++)}const fr=vt?function(Ke){const Mt=Ke.slice(),Et=[0];let ti,Mh,qt,ni,el;const YA=Ke.length;for(ti=0;ti<YA;ti++){const tl=Ke[ti];if(tl!==0){if(Mh=Et[Et.length-1],Ke[Mh]<tl){Mt[ti]=Mh,Et.push(ti);continue}for(qt=0,ni=Et.length-1;qt<ni;)el=qt+ni>>1,Ke[Et[el]]<tl?qt=el+1:ni=el;tl<Ke[Et[qt]]&&(qt>0&&(Mt[ti]=Et[qt-1]),Et[qt]=ti)}}for(qt=Et.length,ni=Et[qt-1];qt-- >0;)Et[qt]=ni,ni=Mt[ni];return Et}(tn):Xt;for(oe=fr.length-1,C=Ue-1;C>=0;C--){const Ke=J+C,Mt=M[Ke],Et=Ke+1<L?M[Ke+1].el:X;tn[C]===0?m(null,Mt,U,Et,d,g,v,E,A):vt&&(oe<0||C!==fr[oe]?Ie(Mt,U,Et,2):oe--)}}},Ie=(P,M,U,X,d=null)=>{const{el:g,type:v,transition:E,children:A,shapeFlag:C}=P;if(6&C)return void Ie(P.component.subTree,M,U,X);if(128&C)return void P.suspense.move(M,U,X);if(64&C)return void v.move(P,M,U,_e);if(v===be){n(g,M,U);for(let L=0;L<A.length;L++)Ie(A[L],M,U,X);return void n(P.anchor,M,U)}if(v===Ir)return void w(P,M,U);if(X!==2&&1&C&&E)if(X===0)E.beforeEnter(g),n(g,M,U),Ct(()=>E.enter(g),d);else{const{leave:L,delayLeave:z,afterLeave:$}=E,H=()=>n(g,M,U),J=()=>{L(g,()=>{H(),$&&$()})};z?z(g,H,J):J()}else n(g,M,U)},Fe=(P,M,U,X=!1,d=!1)=>{const{type:g,props:v,ref:E,children:A,dynamicChildren:C,shapeFlag:L,patchFlag:z,dirs:$,cacheIndex:H}=P;if(z===-2&&(d=!1),E!=null&&Pl(E,null,U,P,!0),H!=null&&(M.renderCache[H]=void 0),256&L)return void M.ctx.deactivate(P);const J=1&L&&$,K=!Fi(P);let oe;if(K&&(oe=v&&v.onVnodeBeforeUnmount)&&sn(oe,M,P),6&L)mn(P.component,U,X);else{if(128&L)return void P.suspense.unmount(U,X);J&&si(P,null,M,"beforeUnmount"),64&L?P.type.remove(P,M,U,_e,X):C&&!C.hasOnce&&(g!==be||z>0&&64&z)?ot(C,M,U,!1,!0):(g===be&&384&z||!d&&16&L)&&ot(A,M,U),X&&$t(P)}(K&&(oe=v&&v.onVnodeUnmounted)||J)&&Ct(()=>{oe&&sn(oe,M,P),J&&si(P,null,M,"unmounted")},U)},$t=P=>{const{type:M,el:U,anchor:X,transition:d}=P;if(M===be)return void fn(U,X);if(M===Ir)return void T(P);const g=()=>{i(U),d&&!d.persisted&&d.afterLeave&&d.afterLeave()};if(1&P.shapeFlag&&d&&!d.persisted){const{leave:v,delayLeave:E}=d,A=()=>v(U,g);E?E(P.el,g,A):A()}else g()},fn=(P,M)=>{let U;for(;P!==M;)U=h(P),i(P),P=U;i(M)},mn=(P,M,U)=>{const{bum:X,scope:d,job:g,subTree:v,um:E,m:A,a:C}=P;sp(A),sp(C),X&&ko(X),d.stop(),g&&(g.flags|=8,Fe(v,P,M,U)),E&&Ct(E,M),Ct(()=>{P.isUnmounted=!0},M),M&&M.pendingBranch&&!M.isUnmounted&&P.asyncDep&&!P.asyncResolved&&P.suspenseId===M.pendingId&&(M.deps--,M.deps===0&&M.resolve())},ot=(P,M,U,X=!1,d=!1,g=0)=>{for(let v=g;v<P.length;v++)Fe(P[v],M,U,X,d)},fe=P=>{if(6&P.shapeFlag)return fe(P.component.subTree);if(128&P.shapeFlag)return P.suspense.next();const M=h(P.anchor||P.el),U=M&&M[Ed];return U?h(U):M};let Ve=!1;const Ut=(P,M,U)=>{P==null?M._vnode&&Fe(M._vnode,null,null,!0):m(M._vnode||null,P,M,null,null,null,U),M._vnode=P,Ve||(Ve=!0,yd(),bd(),Ve=!1)},_e={p:m,um:Fe,m:Ie,r:$t,mt:ne,mc:F,pc:W,pbc:B,n:fe,o:t};let mt,ut;return{render:Ut,hydrate:mt,createApp:Hv(Ut,mt)}}(e)}function Bl({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 li({effect:e,job:t},n){n?(e.flags|=32,t.flags|=4):(e.flags&=-33,t.flags&=-5)}function zl(e,t,n=!1){const i=e.children,r=t.children;if(ae(i)&&ae(r))for(let s=0;s<i.length;s++){const o=i[s];let a=r[s];1&a.shapeFlag&&!a.dynamicChildren&&((a.patchFlag<=0||a.patchFlag===32)&&(a=r[s]=Nn(r[s]),a.el=o.el),n||a.patchFlag===-2||zl(o,a)),a.type===Ho&&(a.el=o.el)}}function op(e){const t=e.subTree.component;if(t)return t.asyncDep&&!t.asyncResolved?t:op(t)}function sp(e){if(e)for(let t=0;t<e.length;t++)e[t].flags|=8}const t_=Symbol.for("v-scx"),n_=()=>Ye(t_);function Re(e,t,n){return jl(e,t,n)}function jl(e,t,n=Ee){const{immediate:i,deep:r,flush:s,once:o}=n,a=et({},n);let l;if(es)if(s==="sync"){const p=n_();l=p.__watcherHandles||(p.__watcherHandles=[])}else{if(t&&!i)return{stop:_n,resume:_n,pause:_n};a.once=!0}const c=at;a.call=(p,f,m)=>Zt(p,c,f,m);let u=!1;s==="post"?a.scheduler=p=>{Ct(p,c&&c.suspense)}:s!=="sync"&&(u=!0,a.scheduler=(p,f)=>{f?p():Al(p)}),a.augmentJob=p=>{t&&(p.flags|=4),u&&(p.flags|=2,c&&(p.id=c.uid,p.i=c))};const h=Mv(e,t,a);return l&&l.push(h),h}function i_(e,t,n){const i=this.proxy,r=Ne(e)?e.includes(".")?ap(i,e):()=>i[e]:e.bind(i,i);let s;pe(t)?s=t:(s=t.handler,n=t);const o=ci(this),a=jl(r,s.bind(i),n);return o(),a}function ap(e,t){const n=t.split(".");return()=>{let i=e;for(let r=0;r<n.length&&i;r++)i=i[n[r]];return i}}const r_=(e,t)=>t==="modelValue"||t==="model-value"?e.modelModifiers:e[`${t}Modifiers`]||e[`${Wt(t)}Modifiers`]||e[`${In(t)}Modifiers`];function o_(e,t,...n){if(e.isUnmounted)return;const i=e.vnode.props||Ee;let r=n;const s=t.startsWith("update:"),o=s&&r_(i,t.slice(7));let a;o&&(o.trim&&(r=n.map(u=>Ne(u)?u.trim():u)),o.number&&(r=n.map(nv)));let l=i[a=sl(t)]||i[a=sl(Wt(t))];!l&&s&&(l=i[a=sl(In(t))]),l&&Zt(l,e,6,r);const c=i[a+"Once"];if(c){if(e.emitted){if(e.emitted[a])return}else e.emitted={};e.emitted[a]=!0,Zt(c,e,6,r)}}function lp(e,t,n=!1){const i=t.emitsCache,r=i.get(e);if(r!==void 0)return r;const s=e.emits;let o={},a=!1;if(!pe(e)){const l=c=>{const u=lp(c,t,!0);u&&(a=!0,et(o,u))};!n&&t.mixins.length&&t.mixins.forEach(l),e.extends&&l(e.extends),e.mixins&&e.mixins.forEach(l)}return s||a?(ae(s)?s.forEach(l=>o[l]=null):et(o,s),Oe(e)&&i.set(e,o),o):(Oe(e)&&i.set(e,null),null)}function Zo(e,t){return!(!e||!Ao(t))&&(t=t.slice(2).replace(/Once$/,""),Pe(e,t[0].toLowerCase()+t.slice(1))||Pe(e,In(t))||Pe(e,t))}function Nl(e){const{type:t,vnode:n,proxy:i,withProxy:r,propsOptions:[s],slots:o,attrs:a,emit:l,render:c,renderCache:u,props:h,data:p,setupState:f,ctx:m,inheritAttrs:_}=e,y=No(e);let x,w;try{if(4&n.shapeFlag){const R=r||i,b=R;x=Ht(c.call(b,R,u,h,f,p,m)),w=a}else{const R=t;x=Ht(R.length>1?R(h,{attrs:a,slots:o,emit:l}):R(h,null)),w=t.props?a:s_(a)}}catch(R){Mr.length=0,Er(R,e,1),x=Q(st)}let T=x;if(w&&_!==!1){const R=Object.keys(w),{shapeFlag:b}=T;R.length&&7&b&&(s&&R.some(nl)&&(w=a_(w,s)),T=jn(T,w,!1,!0))}return n.dirs&&(T=jn(T,null,!1,!0),T.dirs=T.dirs?T.dirs.concat(n.dirs):n.dirs),n.transition&&Tr(T,n.transition),x=T,No(y),x}const s_=e=>{let t;for(const n in e)(n==="class"||n==="style"||Ao(n))&&((t||(t={}))[n]=e[n]);return t},a_=(e,t)=>{const n={};for(const i in e)nl(i)&&i.slice(9)in t||(n[i]=e[i]);return n};function cp(e,t,n){const i=Object.keys(t);if(i.length!==Object.keys(e).length)return!0;for(let r=0;r<i.length;r++){const s=i[r];if(t[s]!==e[s]&&!Zo(n,s))return!0}return!1}function Gl({vnode:e,parent:t},n){for(;t;){const i=t.subTree;if(i.suspense&&i.suspense.activeBranch===e&&(i.el=e.el),i!==e)break;(e=t.vnode).el=n,t=t.parent}}const up=e=>e.__isSuspense;let Vl=0;const hp={name:"Suspense",__isSuspense:!0,process(e,t,n,i,r,s,o,a,l,c){if(e==null)(function(u,h,p,f,m,_,y,x,w){const{p:T,o:{createElement:R}}=w,b=R("div"),k=u.suspense=dp(u,m,f,h,b,p,_,y,x,w);T(null,k.pendingBranch=u.ssContent,b,null,f,k,_,y),k.deps>0?(Pr(u,"onPending"),Pr(u,"onFallback"),T(null,u.ssFallback,h,p,f,null,_,y),Di(k,u.ssFallback)):k.resolve(!1,!0)})(t,n,i,r,s,o,a,l,c);else{if(s&&s.deps>0&&!e.suspense.isInFallback)return t.suspense=e.suspense,t.suspense.vnode=t,void(t.el=e.el);(function(u,h,p,f,m,_,y,x,{p:w,um:T,o:{createElement:R}}){const b=h.suspense=u.suspense;b.vnode=h,h.el=u.el;const k=h.ssContent,F=h.ssFallback,{activeBranch:j,pendingBranch:B,isInFallback:N,isHydrating:Y}=b;if(B)b.pendingBranch=k,on(k,B)?(w(B,k,b.hiddenContainer,null,m,b,_,y,x),b.deps<=0?b.resolve():N&&(Y||(w(j,F,p,f,m,null,_,y,x),Di(b,F)))):(b.pendingId=Vl++,Y?(b.isHydrating=!1,b.activeBranch=B):T(B,m,b),b.deps=0,b.effects.length=0,b.hiddenContainer=R("div"),N?(w(null,k,b.hiddenContainer,null,m,b,_,y,x),b.deps<=0?b.resolve():(w(j,F,p,f,m,null,_,y,x),Di(b,F))):j&&on(k,j)?(w(j,k,p,f,m,b,_,y,x),b.resolve(!0)):(w(null,k,b.hiddenContainer,null,m,b,_,y,x),b.deps<=0&&b.resolve()));else if(j&&on(k,j))w(j,k,p,f,m,b,_,y,x),Di(b,k);else if(Pr(h,"onPending"),b.pendingBranch=k,512&k.shapeFlag?b.pendingId=k.component.suspenseId:b.pendingId=Vl++,w(null,k,b.hiddenContainer,null,m,b,_,y,x),b.deps<=0)b.resolve();else{const{timeout:ee,pendingId:ne}=b;ee>0?setTimeout(()=>{b.pendingId===ne&&b.fallback(F)},ee):ee===0&&b.fallback(F)}})(e,t,n,i,r,o,a,l,c)}},hydrate:function(e,t,n,i,r,s,o,a,l){const c=t.suspense=dp(t,i,n,e.parentNode,document.createElement("div"),null,r,s,o,a,!0),u=l(e,c.pendingBranch=t.ssContent,n,c,s,o);return c.deps===0&&c.resolve(!1,!0),u},normalize:function(e){const{shapeFlag:t,children:n}=e,i=32&t;e.ssContent=pp(i?n.default:n),e.ssFallback=i?pp(n.fallback):Q(st)}};function Pr(e,t){const n=e.props&&e.props[t];pe(n)&&n()}function dp(e,t,n,i,r,s,o,a,l,c,u=!1){const{p:h,m:p,um:f,n:m,o:{parentNode:_,remove:y}}=c;let x;const w=function(k){const F=k.props&&k.props.suspensible;return F!=null&&F!==!1}(e);w&&t&&t.pendingBranch&&(x=t.pendingId,t.deps++);const T=e.props?$h(e.props.timeout):void 0,R=s,b={vnode:e,parent:t,parentComponent:n,namespace:o,container:i,hiddenContainer:r,deps:0,pendingId:Vl++,timeout:typeof T=="number"?T:-1,activeBranch:null,pendingBranch:null,isInFallback:!u,isHydrating:u,isUnmounted:!1,effects:[],resolve(k=!1,F=!1){const{vnode:j,activeBranch:B,pendingBranch:N,pendingId:Y,effects:ee,parentComponent:ne,container:G}=b;let V=!1;b.isHydrating?b.isHydrating=!1:k||(V=B&&N.transition&&N.transition.mode==="out-in",V&&(B.transition.afterLeave=()=>{Y===b.pendingId&&(p(N,G,s===R?m(B):s,0),Sl(ee))}),B&&(_(B.el)===G&&(s=m(B)),f(B,ne,b,!0)),V||p(N,G,s,0)),Di(b,N),b.pendingBranch=null,b.isInFallback=!1;let q=b.parent,W=!1;for(;q;){if(q.pendingBranch){q.effects.push(...ee),W=!0;break}q=q.parent}W||V||Sl(ee),b.effects=[],w&&t&&t.pendingBranch&&x===t.pendingId&&(t.deps--,t.deps!==0||F||t.resolve()),Pr(j,"onResolve")},fallback(k){if(!b.pendingBranch)return;const{vnode:F,activeBranch:j,parentComponent:B,container:N,namespace:Y}=b;Pr(F,"onFallback");const ee=m(j),ne=()=>{b.isInFallback&&(h(null,k,N,ee,B,null,Y,a,l),Di(b,k))},G=k.transition&&k.transition.mode==="out-in";G&&(j.transition.afterLeave=ne),b.isInFallback=!0,f(j,B,null,!0),G||ne()},move(k,F,j){b.activeBranch&&p(b.activeBranch,k,F,j),b.container=k},next:()=>b.activeBranch&&m(b.activeBranch),registerDep(k,F,j){const B=!!b.pendingBranch;B&&b.deps++;const N=k.vnode.el;k.asyncDep.catch(Y=>{Er(Y,k,0)}).then(Y=>{if(k.isUnmounted||b.isUnmounted||b.pendingId!==k.suspenseId)return;k.asyncResolved=!0;const{vnode:ee}=k;Yl(k,Y,!1),N&&(ee.el=N);const ne=!N&&k.subTree.el;F(k,ee,_(N||k.subTree.el),N?null:m(k.subTree),b,o,j),ne&&y(ne),Gl(k,ee.el),B&&--b.deps==0&&b.resolve()})},unmount(k,F){b.isUnmounted=!0,b.activeBranch&&f(b.activeBranch,n,k,F),b.pendingBranch&&f(b.pendingBranch,n,k,F)}};return b}function pp(e){let t;if(pe(e)){const n=Ui&&e._c;n&&(e._d=!1,I()),e=e(),n&&(e._d=!0,t=At,gp())}return ae(e)&&(e=function(i){let r;for(let s=0;s<i.length;s++){const o=i[s];if(!Lr(o))return;if(o.type!==st||o.children==="v-if"){if(r)return;r=o}}return r}(e)),e=Ht(e),t&&!e.dynamicChildren&&(e.dynamicChildren=t.filter(n=>n!==e)),e}function Di(e,t){e.activeBranch=t;const{vnode:n,parentComponent:i}=e;let r=t.el;for(;!r&&t.component;)r=(t=t.component.subTree).el;n.el=r,i&&i.subTree===n&&(i.vnode.el=r,Gl(i,r))}const be=Symbol.for("v-fgt"),Ho=Symbol.for("v-txt"),st=Symbol.for("v-cmt"),Ir=Symbol.for("v-stc"),Mr=[];let At=null;function I(e=!1){Mr.push(At=e?null:[])}function gp(){Mr.pop(),At=Mr[Mr.length-1]||null}let Ui=1;function fp(e){Ui+=e,e<0&&At&&(At.hasOnce=!0)}function mp(e){return e.dynamicChildren=Ui>0?At||Xt:null,gp(),Ui>0&&At&&At.push(e),e}function O(e,t,n,i,r,s){return mp(S(e,t,n,i,r,s,!0))}function ce(e,t,n,i,r){return mp(Q(e,t,n,i,r,!0))}function Lr(e){return!!e&&e.__v_isVNode===!0}function on(e,t){return e.type===t.type&&e.key===t.key}const vp=({key:e})=>e??null,Ko=({ref:e,ref_key:t,ref_for:n})=>(typeof e=="number"&&(e=""+e),e!=null?Ne(e)||pt(e)||pe(e)?{i:tt,r:e,k:t,f:!!n}:e:null);function S(e,t=null,n=null,i=0,r=null,s=e===be?0:1,o=!1,a=!1){const l={__v_isVNode:!0,__v_skip:!0,type:e,props:t,key:t&&vp(t),ref:t&&Ko(t),scopeId:wd,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:s,patchFlag:i,dynamicProps:r,dynamicChildren:null,appContext:null,ctx:tt};return a?(ql(l,n),128&s&&e.normalize(l)):n&&(l.shapeFlag|=Ne(n)?8:16),Ui>0&&!o&&At&&(l.patchFlag>0||6&s)&&l.patchFlag!==32&&At.push(l),l}const Q=function(e,t=null,n=null,i=0,r=null,s=!1){if(e&&e!==Bd||(e=st),Lr(e)){const l=jn(e,t,!0);return n&&ql(l,n),Ui>0&&!s&&At&&(6&l.shapeFlag?At[At.indexOf(e)]=l:At.push(l)),l.patchFlag=-2,l}o=e,pe(o)&&"__vccOpts"in o&&(e=e.__vccOpts);var o;if(t){t=$l(t);let{class:l,style:c}=t;l&&!Ne(l)&&(t.class=ve(l)),Oe(c)&&(xl(c)&&!ae(c)&&(c=et({},c)),t.style=Ln(c))}const a=Ne(e)?1:up(e)?128:Cd(e)?64:Oe(e)?4:pe(e)?2:0;return S(e,t,n,i,r,a,s,!0)};function $l(e){return e?xl(e)||Kd(e)?et({},e):e:null}function jn(e,t,n=!1,i=!1){const{props:r,ref:s,patchFlag:o,children:a,transition:l}=e,c=t?Bi(r||{},t):r,u={__v_isVNode:!0,__v_skip:!0,type:e.type,props:c,key:c&&vp(c),ref:t&&t.ref?n&&s?ae(s)?s.concat(Ko(t)):[s,Ko(t)]:Ko(t):s,scopeId:e.scopeId,slotScopeIds:e.slotScopeIds,children:a,target:e.target,targetStart:e.targetStart,targetAnchor:e.targetAnchor,staticCount:e.staticCount,shapeFlag:e.shapeFlag,patchFlag:t&&e.type!==be?o===-1?16:16|o:o,dynamicProps:e.dynamicProps,dynamicChildren:e.dynamicChildren,appContext:e.appContext,dirs:e.dirs,transition:l,component:e.component,suspense:e.suspense,ssContent:e.ssContent&&jn(e.ssContent),ssFallback:e.ssFallback&&jn(e.ssFallback),el:e.el,anchor:e.anchor,ctx:e.ctx,ce:e.ce};return l&&i&&Tr(u,l.clone(u)),u}function je(e=" ",t=0){return Q(Ho,null,e,t)}function Qo(e,t){const n=Q(Ir,null,e);return n.staticCount=t,n}function ie(e="",t=!1){return t?(I(),ce(st,null,e)):Q(st,null,e)}function Ht(e){return e==null||typeof e=="boolean"?Q(st):ae(e)?Q(be,null,e.slice()):typeof e=="object"?Nn(e):Q(Ho,null,String(e))}function Nn(e){return e.el===null&&e.patchFlag!==-1||e.memo?e:jn(e)}function ql(e,t){let n=0;const{shapeFlag:i}=e;if(t==null)t=null;else if(ae(t))n=16;else if(typeof t=="object"){if(65&i){const r=t.default;return void(r&&(r._c&&(r._d=!1),ql(e,r()),r._c&&(r._d=!0)))}{n=32;const r=t._;r||Kd(t)?r===3&&tt&&(tt.slots._===1?t._=1:(t._=2,e.patchFlag|=1024)):t._ctx=tt}}else pe(t)?(t={default:t,_ctx:tt},n=32):(t=String(t),64&i?(n=16,t=[je(t)]):n=8);e.children=t,e.shapeFlag|=n}function Bi(...e){const t={};for(let n=0;n<e.length;n++){const i=e[n];for(const r in i)if(r==="class")t.class!==i.class&&(t.class=ve([t.class,i.class]));else if(r==="style")t.style=Ln([t.style,i.style]);else if(Ao(r)){const s=t[r],o=i[r];!o||s===o||ae(s)&&s.includes(o)||(t[r]=s?[].concat(s,o):o)}else r!==""&&(t[r]=i[r])}return t}function sn(e,t,n,i=null){Zt(e,t,7,[n,i])}const l_=Yd();let c_=0,at=null;const Nt=()=>at||tt;let Jo,Xl;{const e=Xh(),t=(n,i)=>{let r;return(r=e[n])||(r=e[n]=[]),r.push(i),s=>{r.length>1?r.forEach(o=>o(s)):r[0](s)}};Jo=t("__VUE_INSTANCE_SETTERS__",n=>at=n),Xl=t("__VUE_SSR_SETTERS__",n=>es=n)}const ci=e=>{const t=at;return Jo(e),e.scope.on(),()=>{e.scope.off(),Jo(t)}},Wl=()=>{at&&at.scope.off(),Jo(null)};function _p(e){return 4&e.vnode.shapeFlag}let yp,es=!1;function Yl(e,t,n){pe(t)?e.type.__ssrInlineRender?e.ssrRender=t:e.render=t:Oe(t)&&(e.setupState=md(t)),bp(e,n)}function bp(e,t,n){const i=e.type;if(!e.render){if(!t&&yp&&!i.render){const r=i.template||Fl(e).template;if(r){const{isCustomElement:s,compilerOptions:o}=e.appContext.config,{delimiters:a,compilerOptions:l}=i,c=et(et({isCustomElement:s,delimiters:a},o),l);i.render=yp(r,c)}}e.render=i.render||_n}{const r=ci(e);Fn();try{Wv(e)}finally{On(),r()}}}const u_={get:(e,t)=>(ht(e,0,""),e[t])};function xp(e){const t=n=>{e.exposed=n||{}};return{attrs:new Proxy(e.attrs,u_),slots:e.slots,emit:e.emit,expose:t}}function ts(e){return e.exposed?e.exposeProxy||(e.exposeProxy=new Proxy(md((t=e.exposed,!Pe(t,"__v_skip")&&Object.isExtensible(t)&&Vh(t,"__v_skip",!0),t)),{get:(n,i)=>i in n?n[i]:i in Rr?Rr[i](e):void 0,has:(n,i)=>i in n||i in Rr})):e.proxy;var t}function h_(e,t=!0){return pe(e)?e.displayName||e.name:e.name||t&&e.__name}const te=(e,t)=>function(i,r,s=!1){let o,a;return pe(i)?o=i:(o=i.get,a=i.set),new Iv(o,a,s)}(e,0,es),d_="3.5.5";/**
  * @vue/runtime-dom v3.5.5
  * (c) 2018-present Yuxi (Evan) You and Vue contributors
  * @license MIT
  **/let Zl;const wp=typeof window<"u"&&window.trustedTypes;if(wp)try{Zl=wp.createPolicy("vue",{createHTML:e=>e})}catch{}const Ep=Zl?e=>Zl.createHTML(e):e=>e,En=typeof document<"u"?document:null,Cp=En&&En.createElement("template"),p_={insert:(e,t,n)=>{t.insertBefore(e,n||null)},remove:e=>{const t=e.parentNode;t&&t.removeChild(e)},createElement:(e,t,n,i)=>{const r=t==="svg"?En.createElementNS("http://www.w3.org/2000/svg",e):t==="mathml"?En.createElementNS("http://www.w3.org/1998/Math/MathML",e):n?En.createElement(e,{is:n}):En.createElement(e);return e==="select"&&i&&i.multiple!=null&&r.setAttribute("multiple",i.multiple),r},createText:e=>En.createTextNode(e),createComment:e=>En.createComment(e),setText:(e,t)=>{e.nodeValue=t},setElementText:(e,t)=>{e.textContent=t},parentNode:e=>e.parentNode,nextSibling:e=>e.nextSibling,querySelector:e=>En.querySelector(e),setScopeId(e,t){e.setAttribute(t,"")},insertStaticContent(e,t,n,i,r,s){const o=n?n.previousSibling:t.lastChild;if(r&&(r===s||r.nextSibling))for(;t.insertBefore(r.cloneNode(!0),n),r!==s&&(r=r.nextSibling););else{Cp.innerHTML=Ep(i==="svg"?`<svg>${e}</svg>`:i==="mathml"?`<math>${e}</math>`:e);const a=Cp.content;if(i==="svg"||i==="mathml"){const l=a.firstChild;for(;l.firstChild;)a.appendChild(l.firstChild);a.removeChild(l)}t.insertBefore(a,n)}return[o?o.nextSibling:t.firstChild,n?n.previousSibling:t.lastChild]}},Gn="transition",Fr="animation",Or=Symbol("_vtc"),Ap={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},g_=et({},Rd,Ap),f_=e=>(e.displayName="Transition",e.props=g_,e),m_=f_((e,{slots:t})=>function(n,i,r){const s=arguments.length;return s===2?Oe(i)&&!ae(i)?Lr(i)?Q(n,null,[i]):Q(n,i):Q(n,null,i):(s>3?r=Array.prototype.slice.call(arguments,2):s===3&&Lr(r)&&(r=[r]),Q(n,i,r))}(Dv,function(n){const i={};for(const G in n)G in Ap||(i[G]=n[G]);if(n.css===!1)return i;const{name:r="v",type:s,duration:o,enterFromClass:a=`${r}-enter-from`,enterActiveClass:l=`${r}-enter-active`,enterToClass:c=`${r}-enter-to`,appearFromClass:u=a,appearActiveClass:h=l,appearToClass:p=c,leaveFromClass:f=`${r}-leave-from`,leaveActiveClass:m=`${r}-leave-active`,leaveToClass:_=`${r}-leave-to`}=n,y=function(G){if(G==null)return null;if(Oe(G))return[Hl(G.enter),Hl(G.leave)];{const V=Hl(G);return[V,V]}}(o),x=y&&y[0],w=y&&y[1],{onBeforeEnter:T,onEnter:R,onEnterCancelled:b,onLeave:k,onLeaveCancelled:F,onBeforeAppear:j=T,onAppear:B=R,onAppearCancelled:N=b}=i,Y=(G,V,q)=>{hi(G,V?p:c),hi(G,V?h:l),q&&q()},ee=(G,V)=>{G._isLeaving=!1,hi(G,f),hi(G,_),hi(G,m),V&&V()},ne=G=>(V,q)=>{const W=G?B:R,se=()=>Y(V,G,q);ui(W,[V,se]),Tp(()=>{hi(V,G?u:a),Vn(V,G?p:c),Sp(W)||Rp(V,s,x,se)})};return et(i,{onBeforeEnter(G){ui(T,[G]),Vn(G,a),Vn(G,l)},onBeforeAppear(G){ui(j,[G]),Vn(G,u),Vn(G,h)},onEnter:ne(!1),onAppear:ne(!0),onLeave(G,V){G._isLeaving=!0;const q=()=>ee(G,V);Vn(G,f),Vn(G,m),document.body.offsetHeight,Tp(()=>{G._isLeaving&&(hi(G,f),Vn(G,_),Sp(k)||Rp(G,s,w,q))}),ui(k,[G,q])},onEnterCancelled(G){Y(G,!1),ui(b,[G])},onAppearCancelled(G){Y(G,!0),ui(N,[G])},onLeaveCancelled(G){ee(G),ui(F,[G])}})}(e),t)),ui=(e,t=[])=>{ae(e)?e.forEach(n=>n(...t)):e&&e(...t)},Sp=e=>!!e&&(ae(e)?e.some(t=>t.length>1):e.length>1);function Hl(e){return $h(e)}function Vn(e,t){t.split(/\s+/).forEach(n=>n&&e.classList.add(n)),(e[Or]||(e[Or]=new Set)).add(t)}function hi(e,t){t.split(/\s+/).forEach(i=>i&&e.classList.remove(i));const n=e[Or];n&&(n.delete(t),n.size||(e[Or]=void 0))}function Tp(e){requestAnimationFrame(()=>{requestAnimationFrame(e)})}let v_=0;function Rp(e,t,n,i){const r=e._endId=++v_,s=()=>{r===e._endId&&i()};if(n)return setTimeout(s,n);const{type:o,timeout:a,propCount:l}=function(f,m){const _=window.getComputedStyle(f),y=Y=>(_[Y]||"").split(", "),x=y(`${Gn}Delay`),w=y(`${Gn}Duration`),T=kp(x,w),R=y(`${Fr}Delay`),b=y(`${Fr}Duration`),k=kp(R,b);let F=null,j=0,B=0;m===Gn?T>0&&(F=Gn,j=T,B=w.length):m===Fr?k>0&&(F=Fr,j=k,B=b.length):(j=Math.max(T,k),F=j>0?T>k?Gn:Fr:null,B=F?F===Gn?w.length:b.length:0);const N=F===Gn&&/\b(transform|all)(,|$)/.test(y(`${Gn}Property`).toString());return{type:F,timeout:j,propCount:B,hasTransform:N}}(e,t);if(!o)return i();const c=o+"end";let u=0;const h=()=>{e.removeEventListener(c,p),s()},p=f=>{f.target===e&&++u>=l&&h()};setTimeout(()=>{u<l&&h()},a+1),e.addEventListener(c,p)}function kp(e,t){for(;e.length<t.length;)e=e.concat(e);return Math.max(...t.map((n,i)=>Pp(n)+Pp(e[i])))}function Pp(e){return e==="auto"?0:1e3*Number(e.slice(0,-1).replace(",","."))}const ns=Symbol("_vod"),Ip=Symbol("_vsh"),Ft={beforeMount(e,{value:t},{transition:n}){e[ns]=e.style.display==="none"?"":e.style.display,n&&t?n.beforeEnter(e):Dr(e,t)},mounted(e,{value:t},{transition:n}){n&&t&&n.enter(e)},updated(e,{value:t,oldValue:n},{transition:i}){!t!=!n&&(i?t?(i.beforeEnter(e),Dr(e,!0),i.enter(e)):i.leave(e,()=>{Dr(e,!1)}):Dr(e,t))},beforeUnmount(e,{value:t}){Dr(e,t)}};function Dr(e,t){e.style.display=t?e[ns]:"none",e[Ip]=!t}const Mp=Symbol("");function Lp(e){const t=Nt();if(!t)return;const n=t.ut=(r=e(t.proxy))=>{Array.from(document.querySelectorAll(`[data-v-owner="${t.uid}"]`)).forEach(s=>is(s,r))},i=()=>{const r=e(t.proxy);t.ce?is(t.ce,r):Kl(t.subTree,r),n(r)};Dd(()=>{jl(i,null,{flush:"post"})}),We(()=>{const r=new MutationObserver(i);r.observe(t.subTree.el.parentNode,{childList:!0}),Wo(()=>r.disconnect())})}function Kl(e,t){if(128&e.shapeFlag){const n=e.suspense;e=n.activeBranch,n.pendingBranch&&!n.isHydrating&&n.effects.push(()=>{Kl(n.activeBranch,t)})}for(;e.component;)e=e.component.subTree;if(1&e.shapeFlag&&e.el)is(e.el,t);else if(e.type===be)e.children.forEach(n=>Kl(n,t));else if(e.type===Ir){let{el:n,anchor:i}=e;for(;n&&(is(n,t),n!==i);)n=n.nextSibling}}function is(e,t){if(e.nodeType===1){const n=e.style;let i="";for(const r in t)n.setProperty(`--${r}`,t[r]),i+=`--${r}: ${t[r]};`;n[Mp]=i}}const __=/(^|;)\s*display\s*:/,Fp=/\s*!important$/;function rs(e,t,n){if(ae(n))n.forEach(i=>rs(e,t,i));else if(n==null&&(n=""),t.startsWith("--"))e.setProperty(t,n);else{const i=function(r,s){const o=Ql[s];if(o)return o;let a=Wt(s);if(a!=="filter"&&a in r)return Ql[s]=a;a=Ro(a);for(let l=0;l<Op.length;l++){const c=Op[l]+a;if(c in r)return Ql[s]=c}return s}(e,t);Fp.test(n)?e.setProperty(In(i),n.replace(Fp,""),"important"):e[i]=n}}const Op=["Webkit","Moz","ms"],Ql={},Dp="http://www.w3.org/1999/xlink";function Up(e,t,n,i,r,s=av(t)){i&&t.startsWith("xlink:")?n==null?e.removeAttributeNS(Dp,t.slice(6,t.length)):e.setAttributeNS(Dp,t,n):n==null||s&&!Wh(n)?e.removeAttribute(t):e.setAttribute(t,s?"":nn(n)?String(n):n)}function Bp(e,t,n,i){e.addEventListener(t,n,i)}const zp=Symbol("_vei");function y_(e,t,n,i,r=null){const s=e[zp]||(e[zp]={}),o=s[t];if(i&&o)o.value=i;else{const[a,l]=function(c){let u;if(jp.test(c)){let p;for(u={};p=c.match(jp);)c=c.slice(0,c.length-p[0].length),u[p[0].toLowerCase()]=!0}return[c[2]===":"?c.slice(3):In(c.slice(2)),u]}(t);if(i){const c=s[t]=function(u,h){const p=f=>{if(f._vts){if(f._vts<=p.attached)return}else f._vts=Date.now();Zt(function(m,_){if(ae(_)){const y=m.stopImmediatePropagation;return m.stopImmediatePropagation=()=>{y.call(m),m._stopped=!0},_.map(x=>w=>!w._stopped&&x&&x(w))}return _}(f,p.value),h,5,[f])};return p.value=u,p.attached=x_(),p}(i,r);Bp(e,a,c,l)}else o&&(function(c,u,h,p){c.removeEventListener(u,h,p)}(e,a,o,l),s[t]=void 0)}}const jp=/(?:Once|Passive|Capture)$/;let Jl=0;const b_=Promise.resolve(),x_=()=>Jl||(b_.then(()=>Jl=0),Jl=Date.now()),Np=e=>e.charCodeAt(0)===111&&e.charCodeAt(1)===110&&e.charCodeAt(2)>96&&e.charCodeAt(2)<123,Gp=e=>{const t=e.props["onUpdate:modelValue"]||!1;return ae(t)?n=>ko(t,n):t},ec=Symbol("_assign"),Vp={deep:!0,created(e,t,n){e[ec]=Gp(n),Bp(e,"change",()=>{const i=e._modelValue,r=function(a){return"_value"in a?a._value:a.value}(e),s=e.checked,o=e[ec];if(ae(i)){const a=Yh(i,r),l=a!==-1;if(s&&!l)o(i.concat(r));else if(!s&&l){const c=[...i];c.splice(a,1),o(c)}}else if(So(i)){const a=new Set(i);s?a.add(r):a.delete(r),o(a)}else o(qp(e,s))})},mounted:$p,beforeUpdate(e,t,n){e[ec]=Gp(n),$p(e,t,n)}};function $p(e,{value:t,oldValue:n},i){let r;e._modelValue=t,r=ae(t)?Yh(t,i.props.value)>-1:So(t)?t.has(i.props.value):Io(t,qp(e,!0)),e.checked!==r&&(e.checked=r)}function qp(e,t){const n=t?"_trueValue":"_falseValue";return n in e?e[n]:t}const w_=["ctrl","shift","alt","meta"],E_={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)=>w_.some(n=>e[`${n}Key`]&&!t.includes(n))},St=(e,t)=>{const n=e._withMods||(e._withMods={}),i=t.join(".");return n[i]||(n[i]=(r,...s)=>{for(let o=0;o<t.length;o++){const a=E_[t[o]];if(a&&a(r,t))return}return e(r,...s)})},C_={esc:"escape",space:" ",up:"arrow-up",left:"arrow-left",right:"arrow-right",down:"arrow-down",delete:"backspace"},zi=(e,t)=>{const n=e._withKeys||(e._withKeys={}),i=t.join(".");return n[i]||(n[i]=r=>{if(!("key"in r))return;const s=In(r.key);return t.some(o=>o===s||C_[o]===s)?e(r):void 0})},A_=et({patchProp:(e,t,n,i,r,s)=>{const o=r==="svg";t==="class"?function(a,l,c){const u=a[Or];u&&(l=(l?[l,...u]:[...u]).join(" ")),l==null?a.removeAttribute("class"):c?a.setAttribute("class",l):a.className=l}(e,i,o):t==="style"?function(a,l,c){const u=a.style,h=Ne(c);let p=!1;if(c&&!h){if(l)if(Ne(l))for(const f of l.split(";")){const m=f.slice(0,f.indexOf(":")).trim();c[m]==null&&rs(u,m,"")}else for(const f in l)c[f]==null&&rs(u,f,"");for(const f in c)f==="display"&&(p=!0),rs(u,f,c[f])}else if(h){if(l!==c){const f=u[Mp];f&&(c+=";"+f),u.cssText=c,p=__.test(c)}}else l&&a.removeAttribute("style");ns in a&&(a[ns]=p?u.display:"",a[Ip]&&(u.display="none"))}(e,n,i):Ao(t)?nl(t)||y_(e,t,0,i,s):(t[0]==="."?(t=t.slice(1),1):t[0]==="^"?(t=t.slice(1),0):function(a,l,c,u){if(u)return l==="innerHTML"||l==="textContent"||!!(l in a&&Np(l)&&pe(c));if(l==="spellcheck"||l==="draggable"||l==="translate"||l==="form"||l==="list"&&a.tagName==="INPUT"||l==="type"&&a.tagName==="TEXTAREA")return!1;if(l==="width"||l==="height"){const h=a.tagName;if(h==="IMG"||h==="VIDEO"||h==="CANVAS"||h==="SOURCE")return!1}return Np(l)&&Ne(c)?!1:!!(l in a||a._isVueCE&&(/[A-Z]/.test(l)||!Ne(c)))}(e,t,i,o))?(function(a,l,c){if(l==="innerHTML"||l==="textContent")return void(c!=null&&(a[l]=l==="innerHTML"?Ep(c):c));const u=a.tagName;if(l==="value"&&u!=="PROGRESS"&&!u.includes("-")){const p=u==="OPTION"?a.getAttribute("value")||"":a.value,f=c==null?a.type==="checkbox"?"on":"":String(c);return p===f&&"_value"in a||(a.value=f),c==null&&a.removeAttribute(l),void(a._value=c)}let h=!1;if(c===""||c==null){const p=typeof a[l];p==="boolean"?c=Wh(c):c==null&&p==="string"?(c="",h=!0):p==="number"&&(c=0,h=!0)}try{a[l]=c}catch{}h&&a.removeAttribute(l)}(e,t,i),e.tagName.includes("-")||t!=="value"&&t!=="checked"&&t!=="selected"||Up(e,t,i,o,0,t!=="value")):(t==="true-value"?e._trueValue=i:t==="false-value"&&(e._falseValue=i),Up(e,t,i,o))}},p_);let Xp;for(var tc={},S_={byteLength:function(e){var t=Yp(e),n=t[0],i=t[1];return 3*(n+i)/4-i},toByteArray:function(e){var t,n,i=Yp(e),r=i[0],s=i[1],o=new T_(function(c,u,h){return 3*(u+h)/4-h}(0,r,s)),a=0,l=s>0?r-4:r;for(n=0;n<l;n+=4)t=Gt[e.charCodeAt(n)]<<18|Gt[e.charCodeAt(n+1)]<<12|Gt[e.charCodeAt(n+2)]<<6|Gt[e.charCodeAt(n+3)],o[a++]=t>>16&255,o[a++]=t>>8&255,o[a++]=255&t;return s===2&&(t=Gt[e.charCodeAt(n)]<<2|Gt[e.charCodeAt(n+1)]>>4,o[a++]=255&t),s===1&&(t=Gt[e.charCodeAt(n)]<<10|Gt[e.charCodeAt(n+1)]<<4|Gt[e.charCodeAt(n+2)]>>2,o[a++]=t>>8&255,o[a++]=255&t),o},fromByteArray:function(e){for(var t,n=e.length,i=n%3,r=[],s=16383,o=0,a=n-i;o<a;o+=s)r.push(R_(e,o,o+s>a?a:o+s));return i===1?(t=e[n-1],r.push(an[t>>2]+an[t<<4&63]+"==")):i===2&&(t=(e[n-2]<<8)+e[n-1],r.push(an[t>>10]+an[t>>4&63]+an[t<<2&63]+"=")),r.join("")}},an=[],Gt=[],T_=typeof Uint8Array<"u"?Uint8Array:Array,Wp="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",ji=0;ji<64;++ji)an[ji]=Wp[ji],Gt[Wp.charCodeAt(ji)]=ji;function Yp(e){var t=e.length;if(t%4>0)throw new Error("Invalid string. Length must be a multiple of 4");var n=e.indexOf("=");return n===-1&&(n=t),[n,n===t?0:4-n%4]}function R_(e,t,n){for(var i,r,s=[],o=t;o<n;o+=3)i=(e[o]<<16&16711680)+(e[o+1]<<8&65280)+(255&e[o+2]),s.push(an[(r=i)>>18&63]+an[r>>12&63]+an[r>>6&63]+an[63&r]);return s.join("")}Gt[45]=62,Gt[95]=63;var k_={read:function(e,t,n,i,r){var s,o,a=8*r-i-1,l=(1<<a)-1,c=l>>1,u=-7,h=n?r-1:0,p=n?-1:1,f=e[t+h];for(h+=p,s=f&(1<<-u)-1,f>>=-u,u+=a;u>0;s=256*s+e[t+h],h+=p,u-=8);for(o=s&(1<<-u)-1,s>>=-u,u+=i;u>0;o=256*o+e[t+h],h+=p,u-=8);if(s===0)s=1-c;else{if(s===l)return o?NaN:1/0*(f?-1:1);o+=Math.pow(2,i),s-=c}return(f?-1:1)*o*Math.pow(2,s-i)},write:function(e,t,n,i,r,s){var o,a,l,c=8*s-r-1,u=(1<<c)-1,h=u>>1,p=r===23?Math.pow(2,-24)-Math.pow(2,-77):0,f=i?0:s-1,m=i?1:-1,_=t<0||t===0&&1/t<0?1:0;for(t=Math.abs(t),isNaN(t)||t===1/0?(a=isNaN(t)?1:0,o=u):(o=Math.floor(Math.log(t)/Math.LN2),t*(l=Math.pow(2,-o))<1&&(o--,l*=2),(t+=o+h>=1?p/l:p*Math.pow(2,1-h))*l>=2&&(o++,l/=2),o+h>=u?(a=0,o=u):o+h>=1?(a=(t*l-1)*Math.pow(2,r),o+=h):(a=t*Math.pow(2,h-1)*Math.pow(2,r),o=0));r>=8;e[n+f]=255&a,f+=m,a/=256,r-=8);for(o=o<<r|a,c+=r;c>0;e[n+f]=255&o,f+=m,o/=256,c-=8);e[n+f-m]|=128*_}};/*!
   * The buffer module from node.js, for the browser.
   *
   * @author   Feross Aboukhadijeh <https://feross.org>
   * @license  MIT
   */(function(e){const t=S_,n=k_,i=typeof Symbol=="function"&&typeof Symbol.for=="function"?Symbol.for("nodejs.util.inspect.custom"):null;e.Buffer=o,e.SlowBuffer=function(d){return+d!=d&&(d=0),o.alloc(+d)},e.INSPECT_MAX_BYTES=50;const r=2147483647;function s(d){if(d>r)throw new RangeError('The value "'+d+'" is invalid for option "size"');const g=new Uint8Array(d);return Object.setPrototypeOf(g,o.prototype),g}function o(d,g,v){if(typeof d=="number"){if(typeof g=="string")throw new TypeError('The "string" argument must be of type string. Received type number');return c(d)}return a(d,g,v)}function a(d,g,v){if(typeof d=="string")return function(C,L){if(typeof L=="string"&&L!==""||(L="utf8"),!o.isEncoding(L))throw new TypeError("Unknown encoding: "+L);const z=0|f(C,L);let $=s(z);const H=$.write(C,L);return H!==z&&($=$.slice(0,H)),$}(d,g);if(ArrayBuffer.isView(d))return function(C){if(ut(C,Uint8Array)){const L=new Uint8Array(C);return h(L.buffer,L.byteOffset,L.byteLength)}return u(C)}(d);if(d==null)throw new TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof d);if(ut(d,ArrayBuffer)||d&&ut(d.buffer,ArrayBuffer)||typeof SharedArrayBuffer<"u"&&(ut(d,SharedArrayBuffer)||d&&ut(d.buffer,SharedArrayBuffer)))return h(d,g,v);if(typeof d=="number")throw new TypeError('The "value" argument must not be of type number. Received type number');const E=d.valueOf&&d.valueOf();if(E!=null&&E!==d)return o.from(E,g,v);const A=function(C){if(o.isBuffer(C)){const L=0|p(C.length),z=s(L);return z.length===0||C.copy(z,0,0,L),z}if(C.length!==void 0)return typeof C.length!="number"||P(C.length)?s(0):u(C);if(C.type==="Buffer"&&Array.isArray(C.data))return u(C.data)}(d);if(A)return A;if(typeof Symbol<"u"&&Symbol.toPrimitive!=null&&typeof d[Symbol.toPrimitive]=="function")return o.from(d[Symbol.toPrimitive]("string"),g,v);throw new TypeError("The first argument must be one of type string, Buffer, ArrayBuffer, Array, or Array-like Object. Received type "+typeof d)}function l(d){if(typeof d!="number")throw new TypeError('"size" argument must be of type number');if(d<0)throw new RangeError('The value "'+d+'" is invalid for option "size"')}function c(d){return l(d),s(d<0?0:0|p(d))}function u(d){const g=d.length<0?0:0|p(d.length),v=s(g);for(let E=0;E<g;E+=1)v[E]=255&d[E];return v}function h(d,g,v){if(g<0||d.byteLength<g)throw new RangeError('"offset" is outside of buffer bounds');if(d.byteLength<g+(v||0))throw new RangeError('"length" is outside of buffer bounds');let E;return E=g===void 0&&v===void 0?new Uint8Array(d):v===void 0?new Uint8Array(d,g):new Uint8Array(d,g,v),Object.setPrototypeOf(E,o.prototype),E}function p(d){if(d>=r)throw new RangeError("Attempt to allocate Buffer larger than maximum size: 0x"+r.toString(16)+" bytes");return 0|d}function f(d,g){if(o.isBuffer(d))return d.length;if(ArrayBuffer.isView(d)||ut(d,ArrayBuffer))return d.byteLength;if(typeof d!="string")throw new TypeError('The "string" argument must be one of type string, Buffer, or ArrayBuffer. Received type '+typeof d);const v=d.length,E=arguments.length>2&&arguments[2]===!0;if(!E&&v===0)return 0;let A=!1;for(;;)switch(g){case"ascii":case"latin1":case"binary":return v;case"utf8":case"utf-8":return Ut(d).length;case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return 2*v;case"hex":return v>>>1;case"base64":return _e(d).length;default:if(A)return E?-1:Ut(d).length;g=(""+g).toLowerCase(),A=!0}}function m(d,g,v){let E=!1;if((g===void 0||g<0)&&(g=0),g>this.length||((v===void 0||v>this.length)&&(v=this.length),v<=0)||(v>>>=0)<=(g>>>=0))return"";for(d||(d="utf8");;)switch(d){case"hex":return ee(this,g,v);case"utf8":case"utf-8":return j(this,g,v);case"ascii":return N(this,g,v);case"latin1":case"binary":return Y(this,g,v);case"base64":return F(this,g,v);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return ne(this,g,v);default:if(E)throw new TypeError("Unknown encoding: "+d);d=(d+"").toLowerCase(),E=!0}}function _(d,g,v){const E=d[g];d[g]=d[v],d[v]=E}function y(d,g,v,E,A){if(d.length===0)return-1;if(typeof v=="string"?(E=v,v=0):v>2147483647?v=2147483647:v<-2147483648&&(v=-2147483648),P(v=+v)&&(v=A?0:d.length-1),v<0&&(v=d.length+v),v>=d.length){if(A)return-1;v=d.length-1}else if(v<0){if(!A)return-1;v=0}if(typeof g=="string"&&(g=o.from(g,E)),o.isBuffer(g))return g.length===0?-1:x(d,g,v,E,A);if(typeof g=="number")return g&=255,typeof Uint8Array.prototype.indexOf=="function"?A?Uint8Array.prototype.indexOf.call(d,g,v):Uint8Array.prototype.lastIndexOf.call(d,g,v):x(d,[g],v,E,A);throw new TypeError("val must be string, number or Buffer")}function x(d,g,v,E,A){let C,L=1,z=d.length,$=g.length;if(E!==void 0&&((E=String(E).toLowerCase())==="ucs2"||E==="ucs-2"||E==="utf16le"||E==="utf-16le")){if(d.length<2||g.length<2)return-1;L=2,z/=2,$/=2,v/=2}function H(J,K){return L===1?J[K]:J.readUInt16BE(K*L)}if(A){let J=-1;for(C=v;C<z;C++)if(H(d,C)===H(g,J===-1?0:C-J)){if(J===-1&&(J=C),C-J+1===$)return J*L}else J!==-1&&(C-=C-J),J=-1}else for(v+$>z&&(v=z-$),C=v;C>=0;C--){let J=!0;for(let K=0;K<$;K++)if(H(d,C+K)!==H(g,K)){J=!1;break}if(J)return C}return-1}function w(d,g,v,E){v=Number(v)||0;const A=d.length-v;E?(E=Number(E))>A&&(E=A):E=A;const C=g.length;let L;for(E>C/2&&(E=C/2),L=0;L<E;++L){const z=parseInt(g.substr(2*L,2),16);if(P(z))return L;d[v+L]=z}return L}function T(d,g,v,E){return mt(Ut(g,d.length-v),d,v,E)}function R(d,g,v,E){return mt(function(A){const C=[];for(let L=0;L<A.length;++L)C.push(255&A.charCodeAt(L));return C}(g),d,v,E)}function b(d,g,v,E){return mt(_e(g),d,v,E)}function k(d,g,v,E){return mt(function(A,C){let L,z,$;const H=[];for(let J=0;J<A.length&&!((C-=2)<0);++J)L=A.charCodeAt(J),z=L>>8,$=L%256,H.push($),H.push(z);return H}(g,d.length-v),d,v,E)}function F(d,g,v){return g===0&&v===d.length?t.fromByteArray(d):t.fromByteArray(d.slice(g,v))}function j(d,g,v){v=Math.min(d.length,v);const E=[];let A=g;for(;A<v;){const C=d[A];let L=null,z=C>239?4:C>223?3:C>191?2:1;if(A+z<=v){let $,H,J,K;switch(z){case 1:C<128&&(L=C);break;case 2:$=d[A+1],(192&$)==128&&(K=(31&C)<<6|63&$,K>127&&(L=K));break;case 3:$=d[A+1],H=d[A+2],(192&$)==128&&(192&H)==128&&(K=(15&C)<<12|(63&$)<<6|63&H,K>2047&&(K<55296||K>57343)&&(L=K));break;case 4:$=d[A+1],H=d[A+2],J=d[A+3],(192&$)==128&&(192&H)==128&&(192&J)==128&&(K=(15&C)<<18|(63&$)<<12|(63&H)<<6|63&J,K>65535&&K<1114112&&(L=K))}}L===null?(L=65533,z=1):L>65535&&(L-=65536,E.push(L>>>10&1023|55296),L=56320|1023&L),E.push(L),A+=z}return function(C){const L=C.length;if(L<=B)return String.fromCharCode.apply(String,C);let z="",$=0;for(;$<L;)z+=String.fromCharCode.apply(String,C.slice($,$+=B));return z}(E)}e.kMaxLength=r,o.TYPED_ARRAY_SUPPORT=function(){try{const d=new Uint8Array(1),g={foo:function(){return 42}};return Object.setPrototypeOf(g,Uint8Array.prototype),Object.setPrototypeOf(d,g),d.foo()===42}catch{return!1}}(),o.TYPED_ARRAY_SUPPORT||typeof console>"u"||typeof console.error!="function"||console.error("This browser lacks typed array (Uint8Array) support which is required by `buffer` v5.x. Use `buffer` v4.x if you require old browser support."),Object.defineProperty(o.prototype,"parent",{enumerable:!0,get:function(){if(o.isBuffer(this))return this.buffer}}),Object.defineProperty(o.prototype,"offset",{enumerable:!0,get:function(){if(o.isBuffer(this))return this.byteOffset}}),o.poolSize=8192,o.from=function(d,g,v){return a(d,g,v)},Object.setPrototypeOf(o.prototype,Uint8Array.prototype),Object.setPrototypeOf(o,Uint8Array),o.alloc=function(d,g,v){return function(E,A,C){return l(E),E<=0?s(E):A!==void 0?typeof C=="string"?s(E).fill(A,C):s(E).fill(A):s(E)}(d,g,v)},o.allocUnsafe=function(d){return c(d)},o.allocUnsafeSlow=function(d){return c(d)},o.isBuffer=function(d){return d!=null&&d._isBuffer===!0&&d!==o.prototype},o.compare=function(d,g){if(ut(d,Uint8Array)&&(d=o.from(d,d.offset,d.byteLength)),ut(g,Uint8Array)&&(g=o.from(g,g.offset,g.byteLength)),!o.isBuffer(d)||!o.isBuffer(g))throw new TypeError('The "buf1", "buf2" arguments must be one of type Buffer or Uint8Array');if(d===g)return 0;let v=d.length,E=g.length;for(let A=0,C=Math.min(v,E);A<C;++A)if(d[A]!==g[A]){v=d[A],E=g[A];break}return v<E?-1:E<v?1:0},o.isEncoding=function(d){switch(String(d).toLowerCase()){case"hex":case"utf8":case"utf-8":case"ascii":case"latin1":case"binary":case"base64":case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return!0;default:return!1}},o.concat=function(d,g){if(!Array.isArray(d))throw new TypeError('"list" argument must be an Array of Buffers');if(d.length===0)return o.alloc(0);let v;if(g===void 0)for(g=0,v=0;v<d.length;++v)g+=d[v].length;const E=o.allocUnsafe(g);let A=0;for(v=0;v<d.length;++v){let C=d[v];if(ut(C,Uint8Array))A+C.length>E.length?(o.isBuffer(C)||(C=o.from(C)),C.copy(E,A)):Uint8Array.prototype.set.call(E,C,A);else{if(!o.isBuffer(C))throw new TypeError('"list" argument must be an Array of Buffers');C.copy(E,A)}A+=C.length}return E},o.byteLength=f,o.prototype._isBuffer=!0,o.prototype.swap16=function(){const d=this.length;if(d%2!=0)throw new RangeError("Buffer size must be a multiple of 16-bits");for(let g=0;g<d;g+=2)_(this,g,g+1);return this},o.prototype.swap32=function(){const d=this.length;if(d%4!=0)throw new RangeError("Buffer size must be a multiple of 32-bits");for(let g=0;g<d;g+=4)_(this,g,g+3),_(this,g+1,g+2);return this},o.prototype.swap64=function(){const d=this.length;if(d%8!=0)throw new RangeError("Buffer size must be a multiple of 64-bits");for(let g=0;g<d;g+=8)_(this,g,g+7),_(this,g+1,g+6),_(this,g+2,g+5),_(this,g+3,g+4);return this},o.prototype.toString=function(){const d=this.length;return d===0?"":arguments.length===0?j(this,0,d):m.apply(this,arguments)},o.prototype.toLocaleString=o.prototype.toString,o.prototype.equals=function(d){if(!o.isBuffer(d))throw new TypeError("Argument must be a Buffer");return this===d||o.compare(this,d)===0},o.prototype.inspect=function(){let d="";const g=e.INSPECT_MAX_BYTES;return d=this.toString("hex",0,g).replace(/(.{2})/g,"$1 ").trim(),this.length>g&&(d+=" ... "),"<Buffer "+d+">"},i&&(o.prototype[i]=o.prototype.inspect),o.prototype.compare=function(d,g,v,E,A){if(ut(d,Uint8Array)&&(d=o.from(d,d.offset,d.byteLength)),!o.isBuffer(d))throw new TypeError('The "target" argument must be one of type Buffer or Uint8Array. Received type '+typeof d);if(g===void 0&&(g=0),v===void 0&&(v=d?d.length:0),E===void 0&&(E=0),A===void 0&&(A=this.length),g<0||v>d.length||E<0||A>this.length)throw new RangeError("out of range index");if(E>=A&&g>=v)return 0;if(E>=A)return-1;if(g>=v)return 1;if(this===d)return 0;let C=(A>>>=0)-(E>>>=0),L=(v>>>=0)-(g>>>=0);const z=Math.min(C,L),$=this.slice(E,A),H=d.slice(g,v);for(let J=0;J<z;++J)if($[J]!==H[J]){C=$[J],L=H[J];break}return C<L?-1:L<C?1:0},o.prototype.includes=function(d,g,v){return this.indexOf(d,g,v)!==-1},o.prototype.indexOf=function(d,g,v){return y(this,d,g,v,!0)},o.prototype.lastIndexOf=function(d,g,v){return y(this,d,g,v,!1)},o.prototype.write=function(d,g,v,E){if(g===void 0)E="utf8",v=this.length,g=0;else if(v===void 0&&typeof g=="string")E=g,v=this.length,g=0;else{if(!isFinite(g))throw new Error("Buffer.write(string, encoding, offset[, length]) is no longer supported");g>>>=0,isFinite(v)?(v>>>=0,E===void 0&&(E="utf8")):(E=v,v=void 0)}const A=this.length-g;if((v===void 0||v>A)&&(v=A),d.length>0&&(v<0||g<0)||g>this.length)throw new RangeError("Attempt to write outside buffer bounds");E||(E="utf8");let C=!1;for(;;)switch(E){case"hex":return w(this,d,g,v);case"utf8":case"utf-8":return T(this,d,g,v);case"ascii":case"latin1":case"binary":return R(this,d,g,v);case"base64":return b(this,d,g,v);case"ucs2":case"ucs-2":case"utf16le":case"utf-16le":return k(this,d,g,v);default:if(C)throw new TypeError("Unknown encoding: "+E);E=(""+E).toLowerCase(),C=!0}},o.prototype.toJSON=function(){return{type:"Buffer",data:Array.prototype.slice.call(this._arr||this,0)}};const B=4096;function N(d,g,v){let E="";v=Math.min(d.length,v);for(let A=g;A<v;++A)E+=String.fromCharCode(127&d[A]);return E}function Y(d,g,v){let E="";v=Math.min(d.length,v);for(let A=g;A<v;++A)E+=String.fromCharCode(d[A]);return E}function ee(d,g,v){const E=d.length;(!g||g<0)&&(g=0),(!v||v<0||v>E)&&(v=E);let A="";for(let C=g;C<v;++C)A+=M[d[C]];return A}function ne(d,g,v){const E=d.slice(g,v);let A="";for(let C=0;C<E.length-1;C+=2)A+=String.fromCharCode(E[C]+256*E[C+1]);return A}function G(d,g,v){if(d%1!=0||d<0)throw new RangeError("offset is not uint");if(d+g>v)throw new RangeError("Trying to access beyond buffer length")}function V(d,g,v,E,A,C){if(!o.isBuffer(d))throw new TypeError('"buffer" argument must be a Buffer instance');if(g>A||g<C)throw new RangeError('"value" argument is out of bounds');if(v+E>d.length)throw new RangeError("Index out of range")}function q(d,g,v,E,A){mn(g,E,A,d,v,7);let C=Number(g&BigInt(4294967295));d[v++]=C,C>>=8,d[v++]=C,C>>=8,d[v++]=C,C>>=8,d[v++]=C;let L=Number(g>>BigInt(32)&BigInt(4294967295));return d[v++]=L,L>>=8,d[v++]=L,L>>=8,d[v++]=L,L>>=8,d[v++]=L,v}function W(d,g,v,E,A){mn(g,E,A,d,v,7);let C=Number(g&BigInt(4294967295));d[v+7]=C,C>>=8,d[v+6]=C,C>>=8,d[v+5]=C,C>>=8,d[v+4]=C;let L=Number(g>>BigInt(32)&BigInt(4294967295));return d[v+3]=L,L>>=8,d[v+2]=L,L>>=8,d[v+1]=L,L>>=8,d[v]=L,v+8}function se(d,g,v,E,A,C){if(v+E>d.length)throw new RangeError("Index out of range");if(v<0)throw new RangeError("Index out of range")}function he(d,g,v,E,A){return g=+g,v>>>=0,A||se(d,0,v,4),n.write(d,g,v,E,23,4),v+4}function Ie(d,g,v,E,A){return g=+g,v>>>=0,A||se(d,0,v,8),n.write(d,g,v,E,52,8),v+8}o.prototype.slice=function(d,g){const v=this.length;(d=~~d)<0?(d+=v)<0&&(d=0):d>v&&(d=v),(g=g===void 0?v:~~g)<0?(g+=v)<0&&(g=0):g>v&&(g=v),g<d&&(g=d);const E=this.subarray(d,g);return Object.setPrototypeOf(E,o.prototype),E},o.prototype.readUintLE=o.prototype.readUIntLE=function(d,g,v){d>>>=0,g>>>=0,v||G(d,g,this.length);let E=this[d],A=1,C=0;for(;++C<g&&(A*=256);)E+=this[d+C]*A;return E},o.prototype.readUintBE=o.prototype.readUIntBE=function(d,g,v){d>>>=0,g>>>=0,v||G(d,g,this.length);let E=this[d+--g],A=1;for(;g>0&&(A*=256);)E+=this[d+--g]*A;return E},o.prototype.readUint8=o.prototype.readUInt8=function(d,g){return d>>>=0,g||G(d,1,this.length),this[d]},o.prototype.readUint16LE=o.prototype.readUInt16LE=function(d,g){return d>>>=0,g||G(d,2,this.length),this[d]|this[d+1]<<8},o.prototype.readUint16BE=o.prototype.readUInt16BE=function(d,g){return d>>>=0,g||G(d,2,this.length),this[d]<<8|this[d+1]},o.prototype.readUint32LE=o.prototype.readUInt32LE=function(d,g){return d>>>=0,g||G(d,4,this.length),(this[d]|this[d+1]<<8|this[d+2]<<16)+16777216*this[d+3]},o.prototype.readUint32BE=o.prototype.readUInt32BE=function(d,g){return d>>>=0,g||G(d,4,this.length),16777216*this[d]+(this[d+1]<<16|this[d+2]<<8|this[d+3])},o.prototype.readBigUInt64LE=U(function(d){ot(d>>>=0,"offset");const g=this[d],v=this[d+7];g!==void 0&&v!==void 0||fe(d,this.length-8);const E=g+256*this[++d]+65536*this[++d]+this[++d]*2**24,A=this[++d]+256*this[++d]+65536*this[++d]+v*2**24;return BigInt(E)+(BigInt(A)<<BigInt(32))}),o.prototype.readBigUInt64BE=U(function(d){ot(d>>>=0,"offset");const g=this[d],v=this[d+7];g!==void 0&&v!==void 0||fe(d,this.length-8);const E=g*2**24+65536*this[++d]+256*this[++d]+this[++d],A=this[++d]*2**24+65536*this[++d]+256*this[++d]+v;return(BigInt(E)<<BigInt(32))+BigInt(A)}),o.prototype.readIntLE=function(d,g,v){d>>>=0,g>>>=0,v||G(d,g,this.length);let E=this[d],A=1,C=0;for(;++C<g&&(A*=256);)E+=this[d+C]*A;return A*=128,E>=A&&(E-=Math.pow(2,8*g)),E},o.prototype.readIntBE=function(d,g,v){d>>>=0,g>>>=0,v||G(d,g,this.length);let E=g,A=1,C=this[d+--E];for(;E>0&&(A*=256);)C+=this[d+--E]*A;return A*=128,C>=A&&(C-=Math.pow(2,8*g)),C},o.prototype.readInt8=function(d,g){return d>>>=0,g||G(d,1,this.length),128&this[d]?-1*(255-this[d]+1):this[d]},o.prototype.readInt16LE=function(d,g){d>>>=0,g||G(d,2,this.length);const v=this[d]|this[d+1]<<8;return 32768&v?4294901760|v:v},o.prototype.readInt16BE=function(d,g){d>>>=0,g||G(d,2,this.length);const v=this[d+1]|this[d]<<8;return 32768&v?4294901760|v:v},o.prototype.readInt32LE=function(d,g){return d>>>=0,g||G(d,4,this.length),this[d]|this[d+1]<<8|this[d+2]<<16|this[d+3]<<24},o.prototype.readInt32BE=function(d,g){return d>>>=0,g||G(d,4,this.length),this[d]<<24|this[d+1]<<16|this[d+2]<<8|this[d+3]},o.prototype.readBigInt64LE=U(function(d){ot(d>>>=0,"offset");const g=this[d],v=this[d+7];g!==void 0&&v!==void 0||fe(d,this.length-8);const E=this[d+4]+256*this[d+5]+65536*this[d+6]+(v<<24);return(BigInt(E)<<BigInt(32))+BigInt(g+256*this[++d]+65536*this[++d]+this[++d]*2**24)}),o.prototype.readBigInt64BE=U(function(d){ot(d>>>=0,"offset");const g=this[d],v=this[d+7];g!==void 0&&v!==void 0||fe(d,this.length-8);const E=(g<<24)+65536*this[++d]+256*this[++d]+this[++d];return(BigInt(E)<<BigInt(32))+BigInt(this[++d]*2**24+65536*this[++d]+256*this[++d]+v)}),o.prototype.readFloatLE=function(d,g){return d>>>=0,g||G(d,4,this.length),n.read(this,d,!0,23,4)},o.prototype.readFloatBE=function(d,g){return d>>>=0,g||G(d,4,this.length),n.read(this,d,!1,23,4)},o.prototype.readDoubleLE=function(d,g){return d>>>=0,g||G(d,8,this.length),n.read(this,d,!0,52,8)},o.prototype.readDoubleBE=function(d,g){return d>>>=0,g||G(d,8,this.length),n.read(this,d,!1,52,8)},o.prototype.writeUintLE=o.prototype.writeUIntLE=function(d,g,v,E){d=+d,g>>>=0,v>>>=0,!E&&V(this,d,g,v,Math.pow(2,8*v)-1,0);let A=1,C=0;for(this[g]=255&d;++C<v&&(A*=256);)this[g+C]=d/A&255;return g+v},o.prototype.writeUintBE=o.prototype.writeUIntBE=function(d,g,v,E){d=+d,g>>>=0,v>>>=0,!E&&V(this,d,g,v,Math.pow(2,8*v)-1,0);let A=v-1,C=1;for(this[g+A]=255&d;--A>=0&&(C*=256);)this[g+A]=d/C&255;return g+v},o.prototype.writeUint8=o.prototype.writeUInt8=function(d,g,v){return d=+d,g>>>=0,v||V(this,d,g,1,255,0),this[g]=255&d,g+1},o.prototype.writeUint16LE=o.prototype.writeUInt16LE=function(d,g,v){return d=+d,g>>>=0,v||V(this,d,g,2,65535,0),this[g]=255&d,this[g+1]=d>>>8,g+2},o.prototype.writeUint16BE=o.prototype.writeUInt16BE=function(d,g,v){return d=+d,g>>>=0,v||V(this,d,g,2,65535,0),this[g]=d>>>8,this[g+1]=255&d,g+2},o.prototype.writeUint32LE=o.prototype.writeUInt32LE=function(d,g,v){return d=+d,g>>>=0,v||V(this,d,g,4,4294967295,0),this[g+3]=d>>>24,this[g+2]=d>>>16,this[g+1]=d>>>8,this[g]=255&d,g+4},o.prototype.writeUint32BE=o.prototype.writeUInt32BE=function(d,g,v){return d=+d,g>>>=0,v||V(this,d,g,4,4294967295,0),this[g]=d>>>24,this[g+1]=d>>>16,this[g+2]=d>>>8,this[g+3]=255&d,g+4},o.prototype.writeBigUInt64LE=U(function(d,g=0){return q(this,d,g,BigInt(0),BigInt("0xffffffffffffffff"))}),o.prototype.writeBigUInt64BE=U(function(d,g=0){return W(this,d,g,BigInt(0),BigInt("0xffffffffffffffff"))}),o.prototype.writeIntLE=function(d,g,v,E){if(d=+d,g>>>=0,!E){const z=Math.pow(2,8*v-1);V(this,d,g,v,z-1,-z)}let A=0,C=1,L=0;for(this[g]=255&d;++A<v&&(C*=256);)d<0&&L===0&&this[g+A-1]!==0&&(L=1),this[g+A]=(d/C|0)-L&255;return g+v},o.prototype.writeIntBE=function(d,g,v,E){if(d=+d,g>>>=0,!E){const z=Math.pow(2,8*v-1);V(this,d,g,v,z-1,-z)}let A=v-1,C=1,L=0;for(this[g+A]=255&d;--A>=0&&(C*=256);)d<0&&L===0&&this[g+A+1]!==0&&(L=1),this[g+A]=(d/C|0)-L&255;return g+v},o.prototype.writeInt8=function(d,g,v){return d=+d,g>>>=0,v||V(this,d,g,1,127,-128),d<0&&(d=255+d+1),this[g]=255&d,g+1},o.prototype.writeInt16LE=function(d,g,v){return d=+d,g>>>=0,v||V(this,d,g,2,32767,-32768),this[g]=255&d,this[g+1]=d>>>8,g+2},o.prototype.writeInt16BE=function(d,g,v){return d=+d,g>>>=0,v||V(this,d,g,2,32767,-32768),this[g]=d>>>8,this[g+1]=255&d,g+2},o.prototype.writeInt32LE=function(d,g,v){return d=+d,g>>>=0,v||V(this,d,g,4,2147483647,-2147483648),this[g]=255&d,this[g+1]=d>>>8,this[g+2]=d>>>16,this[g+3]=d>>>24,g+4},o.prototype.writeInt32BE=function(d,g,v){return d=+d,g>>>=0,v||V(this,d,g,4,2147483647,-2147483648),d<0&&(d=4294967295+d+1),this[g]=d>>>24,this[g+1]=d>>>16,this[g+2]=d>>>8,this[g+3]=255&d,g+4},o.prototype.writeBigInt64LE=U(function(d,g=0){return q(this,d,g,-BigInt("0x8000000000000000"),BigInt("0x7fffffffffffffff"))}),o.prototype.writeBigInt64BE=U(function(d,g=0){return W(this,d,g,-BigInt("0x8000000000000000"),BigInt("0x7fffffffffffffff"))}),o.prototype.writeFloatLE=function(d,g,v){return he(this,d,g,!0,v)},o.prototype.writeFloatBE=function(d,g,v){return he(this,d,g,!1,v)},o.prototype.writeDoubleLE=function(d,g,v){return Ie(this,d,g,!0,v)},o.prototype.writeDoubleBE=function(d,g,v){return Ie(this,d,g,!1,v)},o.prototype.copy=function(d,g,v,E){if(!o.isBuffer(d))throw new TypeError("argument should be a Buffer");if(v||(v=0),E||E===0||(E=this.length),g>=d.length&&(g=d.length),g||(g=0),E>0&&E<v&&(E=v),E===v||d.length===0||this.length===0)return 0;if(g<0)throw new RangeError("targetStart out of bounds");if(v<0||v>=this.length)throw new RangeError("Index out of range");if(E<0)throw new RangeError("sourceEnd out of bounds");E>this.length&&(E=this.length),d.length-g<E-v&&(E=d.length-g+v);const A=E-v;return this===d&&typeof Uint8Array.prototype.copyWithin=="function"?this.copyWithin(g,v,E):Uint8Array.prototype.set.call(d,this.subarray(v,E),g),A},o.prototype.fill=function(d,g,v,E){if(typeof d=="string"){if(typeof g=="string"?(E=g,g=0,v=this.length):typeof v=="string"&&(E=v,v=this.length),E!==void 0&&typeof E!="string")throw new TypeError("encoding must be a string");if(typeof E=="string"&&!o.isEncoding(E))throw new TypeError("Unknown encoding: "+E);if(d.length===1){const C=d.charCodeAt(0);(E==="utf8"&&C<128||E==="latin1")&&(d=C)}}else typeof d=="number"?d&=255:typeof d=="boolean"&&(d=Number(d));if(g<0||this.length<g||this.length<v)throw new RangeError("Out of range index");if(v<=g)return this;let A;if(g>>>=0,v=v===void 0?this.length:v>>>0,d||(d=0),typeof d=="number")for(A=g;A<v;++A)this[A]=d;else{const C=o.isBuffer(d)?d:o.from(d,E),L=C.length;if(L===0)throw new TypeError('The value "'+d+'" is invalid for argument "value"');for(A=0;A<v-g;++A)this[A+g]=C[A%L]}return this};const Fe={};function $t(d,g,v){Fe[d]=class extends v{constructor(){super(),Object.defineProperty(this,"message",{value:g.apply(this,arguments),writable:!0,configurable:!0}),this.name=`${this.name} [${d}]`,this.stack,delete this.name}get code(){return d}set code(E){Object.defineProperty(this,"code",{configurable:!0,enumerable:!0,value:E,writable:!0})}toString(){return`${this.name} [${d}]: ${this.message}`}}}function fn(d){let g="",v=d.length;const E=d[0]==="-"?1:0;for(;v>=E+4;v-=3)g=`_${d.slice(v-3,v)}${g}`;return`${d.slice(0,v)}${g}`}function mn(d,g,v,E,A,C){if(d>v||d<g){const L=typeof g=="bigint"?"n":"";let z;throw z=g===0||g===BigInt(0)?`>= 0${L} and < 2${L} ** ${8*(C+1)}${L}`:`>= -(2${L} ** ${8*(C+1)-1}${L}) and < 2 ** ${8*(C+1)-1}${L}`,new Fe.ERR_OUT_OF_RANGE("value",z,d)}(function(L,z,$){ot(z,"offset"),L[z]!==void 0&&L[z+$]!==void 0||fe(z,L.length-($+1))})(E,A,C)}function ot(d,g){if(typeof d!="number")throw new Fe.ERR_INVALID_ARG_TYPE(g,"number",d)}function fe(d,g,v){throw Math.floor(d)!==d?(ot(d,v),new Fe.ERR_OUT_OF_RANGE("offset","an integer",d)):g<0?new Fe.ERR_BUFFER_OUT_OF_BOUNDS:new Fe.ERR_OUT_OF_RANGE("offset",`>= 0 and <= ${g}`,d)}$t("ERR_BUFFER_OUT_OF_BOUNDS",function(d){return d?`${d} is outside of buffer bounds`:"Attempt to access memory outside buffer bounds"},RangeError),$t("ERR_INVALID_ARG_TYPE",function(d,g){return`The "${d}" argument must be of type number. Received type ${typeof g}`},TypeError),$t("ERR_OUT_OF_RANGE",function(d,g,v){let E=`The value of "${d}" is out of range.`,A=v;return Number.isInteger(v)&&Math.abs(v)>2**32?A=fn(String(v)):typeof v=="bigint"&&(A=String(v),(v>BigInt(2)**BigInt(32)||v<-(BigInt(2)**BigInt(32)))&&(A=fn(A)),A+="n"),E+=` It must be ${g}. Received ${A}`,E},RangeError);const Ve=/[^+/0-9A-Za-z-_]/g;function Ut(d,g){let v;g=g||1/0;const E=d.length;let A=null;const C=[];for(let L=0;L<E;++L){if(v=d.charCodeAt(L),v>55295&&v<57344){if(!A){if(v>56319){(g-=3)>-1&&C.push(239,191,189);continue}if(L+1===E){(g-=3)>-1&&C.push(239,191,189);continue}A=v;continue}if(v<56320){(g-=3)>-1&&C.push(239,191,189),A=v;continue}v=65536+(A-55296<<10|v-56320)}else A&&(g-=3)>-1&&C.push(239,191,189);if(A=null,v<128){if((g-=1)<0)break;C.push(v)}else if(v<2048){if((g-=2)<0)break;C.push(v>>6|192,63&v|128)}else if(v<65536){if((g-=3)<0)break;C.push(v>>12|224,v>>6&63|128,63&v|128)}else{if(!(v<1114112))throw new Error("Invalid code point");if((g-=4)<0)break;C.push(v>>18|240,v>>12&63|128,v>>6&63|128,63&v|128)}}return C}function _e(d){return t.toByteArray(function(g){if((g=(g=g.split("=")[0]).trim().replace(Ve,"")).length<2)return"";for(;g.length%4!=0;)g+="=";return g}(d))}function mt(d,g,v,E){let A;for(A=0;A<E&&!(A+v>=g.length||A>=d.length);++A)g[A+v]=d[A];return A}function ut(d,g){return d instanceof g||d!=null&&d.constructor!=null&&d.constructor.name!=null&&d.constructor.name===g.name}function P(d){return d!=d}const M=function(){const d="0123456789abcdef",g=new Array(256);for(let v=0;v<16;++v){const E=16*v;for(let A=0;A<16;++A)g[E+A]=d[v]+d[A]}return g}();function U(d){return typeof BigInt>"u"?X:d}function X(){throw new Error("BigInt not supported")}})(tc);const Zp=new class{decode(e){if(e&&e.length!==0)return tc.Buffer.from(e,"base64").toString()}encode(e){if(e&&e.length!==0)return tc.Buffer.from(e).toString("base64")}};class P_{constructor(t){Um(this,"collection");this.collection=t}has(t){if(this.collection===void 0||!this.collection.has(t))return!1;const n=this.collection.get(t);return n!=null&&n!==""}translate(t){if(this.collection===void 0)return t;const n=this.collection.get(t);return n===void 0?t:n}translateFormat(t,...n){let i=this.translate(t);for(const[r,s]of(n||[]).entries())i=i.replace("{"+r+"}",s);return i}}const os={translations:le(new Map),set:e=>{for(const[t,n]of Object.entries(e))os.translations.value.set(t,n)}},I_={debugKey:"showtranslationkeys",prefixKey:"cb-translation-prefix"},M_={store:os,install:(e,t)=>{const n={...I_,...t},i=new P_(os.translations.value),r=function(){return new URLSearchParams(window.location.search.toLowerCase()).get(n.debugKey)!==null},s=o=>{const a=Ye(n.prefixKey,void 0);return a&&!o.startsWith(a)?`${a}.${o}`:o};e.config.globalProperties.$st=o=>{os.set(o)},e.config.globalProperties.$ht=o=>(o=s(o),i.has(o)),e.config.globalProperties.$t=o=>(o=s(o),r()?o:i.translate(o)),e.config.globalProperties.$tf=(o,...a)=>(o=s(o),r()?o:i.translateFormat(o,...a))}},L_=(e,t)=>{const n=e.__vccOpts||e;for(const[i,r]of t)n[i]=r;return n},F_=["innerHTML"],O_=L_({},[["render",function(e,t){return I(),O("div",{class:"cb-powered",innerHTML:e.$t("Citybreak.PoweredBy")},null,8,F_)}]]);function $n(e,t){t===void 0&&(t={});var n=t.insertAt;if(e&&typeof document<"u"){var i=document.head||document.getElementsByTagName("head")[0],r=document.createElement("style");r.type="text/css",n==="top"&&i.firstChild?i.insertBefore(r,i.firstChild):i.appendChild(r),r.styleSheet?r.styleSheet.cssText=e:r.appendChild(document.createTextNode(e))}}let Cn=class{constructor(e){this.propagationStopped,this.defaultPrevented,this.type=e,this.target=null}preventDefault(){this.defaultPrevented=!0}stopPropagation(){this.propagationStopped=!0}};const Ni="propertychange";let ss=class{constructor(){this.disposed=!1}dispose(){this.disposed||(this.disposed=!0,this.disposeInternal())}disposeInternal(){}};function as(e,t){return e>t?1:e<t?-1:0}function D_(e,t){return e<t?1:e>t?-1:0}function nc(e,t,n){if(e[0]<=t)return 0;const i=e.length;if(t<=e[i-1])return i-1;if(typeof n=="function"){for(let r=1;r<i;++r){const s=e[r];if(s===t)return r;if(s<t)return n(t,e[r-1],s)>0?r-1:r}return i-1}if(n>0){for(let r=1;r<i;++r)if(e[r]<t)return r-1;return i-1}if(n<0){for(let r=1;r<i;++r)if(e[r]<=t)return r;return i-1}for(let r=1;r<i;++r){if(e[r]==t)return r;if(e[r]<t)return e[r-1]-t<t-e[r]?r-1:r}return i-1}function ln(e,t){const n=Array.isArray(t)?t:[t],i=n.length;for(let r=0;r<i;r++)e[e.length]=n[r]}function ls(e,t){const n=e.length;if(n!==t.length)return!1;for(let i=0;i<n;i++)if(e[i]!==t[i])return!1;return!0}function Ur(){return!0}function cs(){return!1}function Gi(){}function Hp(e){let t,n,i;return function(){const r=Array.prototype.slice.call(arguments);return(!n||this!==i||!ls(r,n))&&(i=this,n=r,t=e.apply(this,arguments)),t}}function Br(e){for(const t in e)delete e[t]}function Vi(e){let t;for(t in e)return!1;return!t}let zr=class extends ss{constructor(e){super(),this.eventTarget_=e,this.pendingRemovals_=null,this.dispatching_=null,this.listeners_=null}addEventListener(e,t){if(!e||!t)return;const n=this.listeners_||(this.listeners_={}),i=n[e]||(n[e]=[]);i.includes(t)||i.push(t)}dispatchEvent(e){const t=typeof e=="string",n=t?e:e.type,i=this.listeners_&&this.listeners_[n];if(!i)return;const r=t?new Cn(e):e;r.target||(r.target=this.eventTarget_||this);const s=this.dispatching_||(this.dispatching_={}),o=this.pendingRemovals_||(this.pendingRemovals_={});let a;n in s||(s[n]=0,o[n]=0),++s[n];for(let l=0,c=i.length;l<c;++l)if(a="handleEvent"in i[l]?i[l].handleEvent(r):i[l].call(this,r),a===!1||r.propagationStopped){a=!1;break}if(--s[n]==0){let l=o[n];for(delete o[n];l--;)this.removeEventListener(n,Gi);delete s[n]}return a}disposeInternal(){this.listeners_&&Br(this.listeners_)}getListeners(e){return this.listeners_&&this.listeners_[e]||void 0}hasListener(e){return!!this.listeners_&&(e?e in this.listeners_:Object.keys(this.listeners_).length>0)}removeEventListener(e,t){if(!this.listeners_)return;const n=this.listeners_[e];if(!n)return;const i=n.indexOf(t);i!==-1&&(this.pendingRemovals_&&e in this.pendingRemovals_?(n[i]=Gi,++this.pendingRemovals_[e]):(n.splice(i,1),n.length===0&&delete this.listeners_[e]))}};const Be="change",U_="error",Kp="contextmenu",jr="click",B_="dblclick",us="keydown",Qp="keypress",z_="load",Jp="touchmove",Nr="wheel";function we(e,t,n,i,r){if(r){const o=n;n=function(){e.removeEventListener(t,n),o.apply(i??this,arguments)}}else i&&i!==e&&(n=n.bind(i));const s={target:e,type:t,listener:n};return e.addEventListener(t,n),s}function hs(e,t,n,i){return we(e,t,n,i,!0)}function Le(e){e&&e.target&&(e.target.removeEventListener(e.type,e.listener),Br(e))}let Gr=class extends zr{constructor(){super(),this.on=this.onInternal,this.once=this.onceInternal,this.un=this.unInternal,this.revision_=0}changed(){++this.revision_,this.dispatchEvent(Be)}getRevision(){return this.revision_}onInternal(e,t){if(Array.isArray(e)){const n=e.length,i=new Array(n);for(let r=0;r<n;++r)i[r]=we(this,e[r],t);return i}return we(this,e,t)}onceInternal(e,t){let n;if(Array.isArray(e)){const i=e.length;n=new Array(i);for(let r=0;r<i;++r)n[r]=hs(this,e[r],t)}else n=hs(this,e,t);return t.ol_key=n,n}unInternal(e,t){const n=t.ol_key;if(n)(function(i){if(Array.isArray(i))for(let r=0,s=i.length;r<s;++r)Le(i[r]);else Le(i)})(n);else if(Array.isArray(e))for(let i=0,r=e.length;i<r;++i)this.removeEventListener(e[i],t);else this.removeEventListener(e,t)}};function ue(){throw new Error("Unimplemented abstract method.")}Gr.prototype.on,Gr.prototype.once,Gr.prototype.un;let j_=0;function Ae(e){return e.ol_uid||(e.ol_uid=String(++j_))}let eg=class extends Cn{constructor(e,t,n){super(e),this.key=t,this.oldValue=n}},Kt=class extends Gr{constructor(e){super(),this.on,this.once,this.un,Ae(this),this.values_=null,e!==void 0&&this.setProperties(e)}get(e){let t;return this.values_&&this.values_.hasOwnProperty(e)&&(t=this.values_[e]),t}getKeys(){return this.values_&&Object.keys(this.values_)||[]}getProperties(){return this.values_&&Object.assign({},this.values_)||{}}getPropertiesInternal(){return this.values_}hasProperties(){return!!this.values_}notify(e,t){let n;n=`change:${e}`,this.hasListener(n)&&this.dispatchEvent(new eg(n,e,t)),n=Ni,this.hasListener(n)&&this.dispatchEvent(new eg(n,e,t))}addChangeListener(e,t){this.addEventListener(`change:${e}`,t)}removeChangeListener(e,t){this.removeEventListener(`change:${e}`,t)}set(e,t,n){const i=this.values_||(this.values_={});if(n)i[e]=t;else{const r=i[e];i[e]=t,r!==t&&this.notify(e,r)}}setProperties(e,t){for(const n in e)this.set(n,e[n],t)}applyProperties(e){e.values_&&Object.assign(this.values_||(this.values_={}),e.values_)}unset(e,t){if(this.values_&&e in this.values_){const n=this.values_[e];delete this.values_[e],Vi(this.values_)&&(this.values_=null),t||this.notify(e,n)}}};const ds="opacity",ic="visible",tg="extent",rc="zIndex",oc="maxResolution",sc="minResolution",ac="maxZoom",lc="minZoom",ps="source",cc="map";function Ce(e,t){if(!e)throw new Error(t)}function Ze(e,t,n){return Math.min(Math.max(e,t),n)}function N_(e,t,n,i,r,s){const o=r-n,a=s-i;if(o!==0||a!==0){const l=((e-n)*o+(t-i)*a)/(o*o+a*a);l>1?(n=r,i=s):l>0&&(n+=o*l,i+=a*l)}return di(e,t,n,i)}function di(e,t,n,i){const r=n-e,s=i-t;return r*r+s*s}function gs(e){return e*Math.PI/180}function $i(e,t){const n=e%t;return n*t<0?n+t:n}function uc(e,t,n){return e+n*(t-e)}function ng(e,t){const n=Math.pow(10,t);return Math.round(e*n)/n}function fs(e,t){return Math.floor(ng(e,t))}function ms(e,t){return Math.ceil(ng(e,t))}let ig=class extends Kt{constructor(e){super(),this.on,this.once,this.un,this.background_=e.background;const t=Object.assign({},e);typeof e.properties=="object"&&(delete t.properties,Object.assign(t,e.properties)),t[ds]=e.opacity!==void 0?e.opacity:1,Ce(typeof t[ds]=="number","Layer opacity must be a number"),t[ic]=e.visible===void 0||e.visible,t[rc]=e.zIndex,t[oc]=e.maxResolution!==void 0?e.maxResolution:1/0,t[sc]=e.minResolution!==void 0?e.minResolution:0,t[lc]=e.minZoom!==void 0?e.minZoom:-1/0,t[ac]=e.maxZoom!==void 0?e.maxZoom:1/0,this.className_=t.className!==void 0?t.className:"ol-layer",delete t.className,this.setProperties(t),this.state_=null}getBackground(){return this.background_}getClassName(){return this.className_}getLayerState(e){const t=this.state_||{layer:this,managed:e===void 0||e},n=this.getZIndex();return t.opacity=Ze(Math.round(100*this.getOpacity())/100,0,1),t.visible=this.getVisible(),t.extent=this.getExtent(),t.zIndex=n!==void 0||t.managed?n:1/0,t.maxResolution=this.getMaxResolution(),t.minResolution=Math.max(this.getMinResolution(),0),t.minZoom=this.getMinZoom(),t.maxZoom=this.getMaxZoom(),this.state_=t,t}getLayersArray(e){return ue()}getLayerStatesArray(e){return ue()}getExtent(){return this.get(tg)}getMaxResolution(){return this.get(oc)}getMinResolution(){return this.get(sc)}getMinZoom(){return this.get(lc)}getMaxZoom(){return this.get(ac)}getOpacity(){return this.get(ds)}getSourceState(){return ue()}getVisible(){return this.get(ic)}getZIndex(){return this.get(rc)}setBackground(e){this.background_=e,this.changed()}setExtent(e){this.set(tg,e)}setMaxResolution(e){this.set(oc,e)}setMinResolution(e){this.set(sc,e)}setMaxZoom(e){this.set(ac,e)}setMinZoom(e){this.set(lc,e)}setOpacity(e){Ce(typeof e=="number","Layer opacity must be a number"),this.set(ds,e)}setVisible(e){this.set(ic,e)}setZIndex(e){this.set(rc,e)}disposeInternal(){this.state_&&(this.state_.layer=null,this.state_=null),super.disposeInternal()}};const G_="prerender",V_="postrender",vs="precompose",hc="postcompose",dc="rendercomplete",qn=0,qi=1,Qt={CENTER:"center",RESOLUTION:"resolution",ROTATION:"rotation"},pc=256,gc={radians:6370997/(2*Math.PI),degrees:2*Math.PI*6370997/360,ft:.3048,m:1,"us-ft":.3048006096012192};let rg=class{constructor(e){this.code_=e.code,this.units_=e.units,this.extent_=e.extent!==void 0?e.extent:null,this.worldExtent_=e.worldExtent!==void 0?e.worldExtent:null,this.axisOrientation_=e.axisOrientation!==void 0?e.axisOrientation:"enu",this.global_=e.global!==void 0&&e.global,this.canWrapX_=!(!this.global_||!this.extent_),this.getPointResolutionFunc_=e.getPointResolution,this.defaultTileGrid_=null,this.metersPerUnit_=e.metersPerUnit}canWrapX(){return this.canWrapX_}getCode(){return this.code_}getExtent(){return this.extent_}getUnits(){return this.units_}getMetersPerUnit(){return this.metersPerUnit_||gc[this.units_]}getWorldExtent(){return this.worldExtent_}getAxisOrientation(){return this.axisOrientation_}isGlobal(){return this.global_}setGlobal(e){this.global_=e,this.canWrapX_=!(!e||!this.extent_)}getDefaultTileGrid(){return this.defaultTileGrid_}setDefaultTileGrid(e){this.defaultTileGrid_=e}setExtent(e){this.extent_=e,this.canWrapX_=!(!this.global_||!e)}setWorldExtent(e){this.worldExtent_=e}setGetPointResolution(e){this.getPointResolutionFunc_=e}getPointResolutionFunc(){return this.getPointResolutionFunc_}};const Vr=6378137,Xi=Math.PI*Vr,$_=[-Xi,-Xi,Xi,Xi],q_=[-180,-85,180,85],_s=Vr*Math.log(Math.tan(Math.PI/2));let Wi=class extends rg{constructor(e){super({code:e,units:"m",extent:$_,global:!0,worldExtent:q_,getPointResolution:function(t,n){return t/Math.cosh(n[1]/Vr)}})}};const og=[new Wi("EPSG:3857"),new Wi("EPSG:102100"),new Wi("EPSG:102113"),new Wi("EPSG:900913"),new Wi("http://www.opengis.net/def/crs/EPSG/0/3857"),new Wi("http://www.opengis.net/gml/srs/epsg.xml#3857")];function X_(e,t,n){const i=e.length;n=n>1?n:2,t===void 0&&(t=n>2?e.slice():new Array(i));for(let r=0;r<i;r+=n){t[r]=Xi*e[r]/180;let s=Vr*Math.log(Math.tan(Math.PI*(+e[r+1]+90)/360));s>_s?s=_s:s<-_s&&(s=-_s),t[r+1]=s}return t}function W_(e,t,n){const i=e.length;n=n>1?n:2,t===void 0&&(t=n>2?e.slice():new Array(i));for(let r=0;r<i;r+=n)t[r]=180*e[r]/Xi,t[r+1]=360*Math.atan(Math.exp(e[r+1]/Vr))/Math.PI-90;return t}const sg=[-180,-90,180,90],Y_=6378137*Math.PI/180;let pi=class extends rg{constructor(e,t){super({code:e,units:"degrees",extent:sg,axisOrientation:t,global:!0,metersPerUnit:Y_,worldExtent:sg})}};const ag=[new pi("CRS:84"),new pi("EPSG:4326","neu"),new pi("urn:ogc:def:crs:OGC:1.3:CRS84"),new pi("urn:ogc:def:crs:OGC:2:84"),new pi("http://www.opengis.net/def/crs/OGC/1.3/CRS84"),new pi("http://www.opengis.net/gml/srs/epsg.xml#4326","neu"),new pi("http://www.opengis.net/def/crs/EPSG/0/4326","neu")];let fc={},Yi={};function ys(e,t,n){const i=e.getCode(),r=t.getCode();i in Yi||(Yi[i]={}),Yi[i][r]=n}const lg=0,mc=1,vc=2,_c=4,yc=8,bc=16;function xc(e){const t=[1/0,1/0,-1/0,-1/0];for(let n=0,i=e.length;n<i;++n)ws(t,e[n]);return t}function gi(e,t,n){let i,r;return i=t<e[0]?e[0]-t:e[2]<t?t-e[2]:0,r=n<e[1]?e[1]-n:e[3]<n?n-e[3]:0,i*i+r*r}function bs(e,t){return wc(e,t[0],t[1])}function xs(e,t){return e[0]<=t[0]&&t[2]<=e[2]&&e[1]<=t[1]&&t[3]<=e[3]}function wc(e,t,n){return e[0]<=t&&t<=e[2]&&e[1]<=n&&n<=e[3]}function cg(e,t){const n=e[0],i=e[1],r=e[2],s=e[3],o=t[0],a=t[1];let l=lg;return o<n?l|=bc:o>r&&(l|=_c),a<i?l|=yc:a>s&&(l|=vc),l===lg&&(l=mc),l}function fi(e,t,n,i,r){return r?(r[0]=e,r[1]=t,r[2]=n,r[3]=i,r):[e,t,n,i]}function Zi(e){return fi(1/0,1/0,-1/0,-1/0,e)}function ug(e,t){const n=e[0],i=e[1];return fi(n,i,n,i,t)}function Ec(e,t,n,i,r){return dg(Zi(r),e,t,n,i)}function $r(e,t){return e[0]==t[0]&&e[2]==t[2]&&e[1]==t[1]&&e[3]==t[3]}function hg(e,t){return t[0]<e[0]&&(e[0]=t[0]),t[2]>e[2]&&(e[2]=t[2]),t[1]<e[1]&&(e[1]=t[1]),t[3]>e[3]&&(e[3]=t[3]),e}function ws(e,t){t[0]<e[0]&&(e[0]=t[0]),t[0]>e[2]&&(e[2]=t[0]),t[1]<e[1]&&(e[1]=t[1]),t[1]>e[3]&&(e[3]=t[1])}function dg(e,t,n,i,r){for(;n<i;n+=r)Z_(e,t[n],t[n+1]);return e}function Z_(e,t,n){e[0]=Math.min(e[0],t),e[1]=Math.min(e[1],n),e[2]=Math.max(e[2],t),e[3]=Math.max(e[3],n)}function pg(e,t){let n;return n=t(Cc(e)),!!(n||(n=t(Ac(e)),n)||(n=t(Tc(e)),n)||(n=t(Xr(e)),n))&&n}function qr(e){let t=0;return mi(e)||(t=ze(e)*Tt(e)),t}function Cc(e){return[e[0],e[1]]}function Ac(e){return[e[2],e[1]]}function Xn(e){return[(e[0]+e[2])/2,(e[1]+e[3])/2]}function H_(e,t){let n;if(t==="bottom-left")n=Cc(e);else if(t==="bottom-right")n=Ac(e);else if(t==="top-left")n=Xr(e);else{if(t!=="top-right")throw new Error("Invalid corner");n=Tc(e)}return n}function Sc(e,t,n,i,r){const[s,o,a,l,c,u,h,p]=function(f,m,_,y){const x=m*y[0]/2,w=m*y[1]/2,T=Math.cos(_),R=Math.sin(_),b=x*T,k=x*R,F=w*T,j=w*R,B=f[0],N=f[1];return[B-b+j,N-k-F,B-b-j,N-k+F,B+b-j,N+k+F,B+b+j,N+k-F,B-b+j,N-k-F]}(e,t,n,i);return fi(Math.min(s,a,c,h),Math.min(o,l,u,p),Math.max(s,a,c,h),Math.max(o,l,u,p),r)}function Tt(e){return e[3]-e[1]}function Vt(e,t,n){const i=n||[1/0,1/0,-1/0,-1/0];return Es(e,t)?(e[0]>t[0]?i[0]=e[0]:i[0]=t[0],e[1]>t[1]?i[1]=e[1]:i[1]=t[1],e[2]<t[2]?i[2]=e[2]:i[2]=t[2],e[3]<t[3]?i[3]=e[3]:i[3]=t[3]):Zi(i),i}function Xr(e){return[e[0],e[3]]}function Tc(e){return[e[2],e[3]]}function ze(e){return e[2]-e[0]}function Es(e,t){return e[0]<=t[2]&&e[2]>=t[0]&&e[1]<=t[3]&&e[3]>=t[1]}function mi(e){return e[2]<e[0]||e[3]<e[1]}function K_(e,t,n,i){if(mi(e))return Zi(n);let r=[];r=[e[0],e[1],e[2],e[1],e[2],e[3],e[0],e[3]],t(r,r,2);const s=[],o=[];for(let a=0,l=r.length;a<l;a+=2)s.push(r[a]),o.push(r[a+1]);return function(a,l,c){return fi(Math.min.apply(null,a),Math.min.apply(null,l),Math.max.apply(null,a),Math.max.apply(null,l),c)}(s,o,n)}function Rc(e,t,n){if(t.canWrapX()){const i=t.getExtent();if(!isFinite(e[0])||!isFinite(e[2]))return[[i[0],e[1],i[2],e[3]]];(function(s,o){const a=o.getExtent(),l=Xn(s);if(o.canWrapX()&&(l[0]<a[0]||l[0]>=a[2])){const c=ze(a),u=Math.floor((l[0]-a[0])/c)*c;s[0]-=u,s[2]-=u}})(e,t);const r=ze(i);if(ze(e)>r&&!n)return[[i[0],e[1],i[2],e[3]]];if(e[0]<i[0])return[[e[0]+r,e[1],i[2],e[3]],[i[0],e[1],e[2],e[3]]];if(e[2]>i[2])return[[e[0],e[1],i[2],e[3]],[i[0],e[1],e[2]-r,e[3]]]}return[e]}function Cs(e,t){let n=!0;for(let i=e.length-1;i>=0;--i)if(e[i]!=t[i]){n=!1;break}return n}function kc(e,t){const n=Math.cos(t),i=Math.sin(t),r=e[0]*n-e[1]*i,s=e[1]*n+e[0]*i;return e[0]=r,e[1]=s,e}function Q_(e,t){if(t.canWrapX()){const n=ze(t.getExtent()),i=function(r,s,o){const a=s.getExtent();let l=0;return s.canWrapX()&&(r[0]<a[0]||r[0]>a[2])&&(o=o||ze(a),l=Math.floor((r[0]-a[0])/o)),l}(e,t,n);i&&(e[0]-=i*n)}return e}function gg(e,t,n){n=n||63710088e-1;const i=gs(e[1]),r=gs(t[1]),s=(r-i)/2,o=gs(t[0]-e[0])/2,a=Math.sin(s)*Math.sin(s)+Math.sin(o)*Math.sin(o)*Math.cos(i)*Math.cos(r);return 2*n*Math.atan2(Math.sqrt(a),Math.sqrt(1-a))}function fg(...e){console.warn(...e)}let Pc=!0;function mg(e){Pc=!1}function Ic(e,t){if(t!==void 0)for(let n=0,i=e.length;n<i;++n)t[n]=e[n];else t=e.slice();return t}function vg(e,t){if(t!==void 0&&e!==t){for(let n=0,i=e.length;n<i;++n)t[n]=e[n];e=t}return e}function J_(e){(function(t,n){fc[t]=n})(e.getCode(),e),ys(e,e,Ic)}function He(e){return typeof e=="string"?function(t){return fc[t]||fc[t.replace(/urn:(x-)?ogc:def:crs:EPSG:(.*:)?(\w+)$/,"EPSG:$3")]||null}(e):e||null}function _g(e,t,n,i){let r;const s=(e=He(e)).getPointResolutionFunc();if(s)r=s(t,n);else{const o=e.getUnits();if(o=="degrees"&&!i||i=="degrees")r=t;else{const a=Lc(e,He("EPSG:4326"));if(a===vg&&o!=="degrees")r=t*e.getMetersPerUnit();else{let c=[n[0]-t/2,n[1],n[0]+t/2,n[1],n[0],n[1]-t/2,n[0],n[1]+t/2];c=a(c,c,2),r=(gg(c.slice(0,2),c.slice(2,4))+gg(c.slice(4,6),c.slice(6,8)))/2}const l=e.getMetersPerUnit();l!==void 0&&(r/=l)}}return r}function yg(e){(function(t){t.forEach(J_)})(e),e.forEach(function(t){e.forEach(function(n){t!==n&&ys(t,n,Ic)})})}function Mc(e,t){return e?typeof e=="string"?He(e):e:He(t)}function Hi(e,t){if(e===t)return!0;const n=e.getUnits()===t.getUnits();return(e.getCode()===t.getCode()||Lc(e,t)===Ic)&&n}function Lc(e,t){let n=function(i,r){let s;return i in Yi&&r in Yi[i]&&(s=Yi[i][r]),s}(e.getCode(),t.getCode());return n||(n=vg),n}function Ki(e,t){return Lc(He(e),He(t))}function bg(e,t,n){return Ki(t,n)(e,void 0,e.length)}function xg(e,t,n,i){return K_(e,Ki(t,n),void 0)}function Fc(e,t){return e}function An(e,t){return Pc&&!Cs(e,[0,0])&&e[0]>=-180&&e[0]<=180&&e[1]>=-90&&e[1]<=90&&(Pc=!1,fg("Call useGeographic() from ol/proj once to work with [longitude, latitude] coordinates.")),e}function wg(e,t){return e}function vi(e,t){return e}function Eg(e,t,n){return function(i,r,s,o,a){if(!i)return;if(!r&&!t)return i;const l=t?0:s[0]*r,c=t?0:s[1]*r,u=a?a[0]:0,h=a?a[1]:0;let p=e[0]+l/2+u,f=e[2]-l/2+u,m=e[1]+c/2+h,_=e[3]-c/2+h;p>f&&(p=(f+p)/2,f=p),m>_&&(m=(_+m)/2,_=m);let y=Ze(i[0],p,f),x=Ze(i[1],m,_);if(o&&n&&r){const w=30*r;y+=-w*Math.log(1+Math.max(0,p-i[0])/w)+w*Math.log(1+Math.max(0,i[0]-f)/w),x+=-w*Math.log(1+Math.max(0,m-i[1])/w)+w*Math.log(1+Math.max(0,i[1]-_)/w)}return[y,x]}}function ey(e){return e}function Oc(e,t,n,i){const r=ze(t)/n[0],s=Tt(t)/n[1];return i?Math.min(e,Math.max(r,s)):Math.min(e,Math.min(r,s))}function Dc(e,t,n){let i=Math.min(e,t);return i*=Math.log(1+50*Math.max(0,e/t-1))/50+1,n&&(i=Math.max(i,n),i/=Math.log(1+50*Math.max(0,n/e-1))/50+1),Ze(i,n/2,2*t)}function Cg(e,t,n,i,r){return n=n===void 0||n,function(s,o,a,l){if(s!==void 0){const c=i?Oc(e,i,a,r):e;return n&&l?Dc(s,c,t):Ze(s,t,c)}}}function Uc(e){if(e!==void 0)return 0}function Ag(e){if(e!==void 0)return e}function Sg(e){return Math.pow(e,3)}function _i(e){return 1-Sg(1-e)}function ty(e){return 3*e*e-2*e*e*e}function ny(e){return e}yg(og),yg(ag),function(e,t,n,i){e.forEach(function(r){t.forEach(function(s){ys(r,s,n),ys(s,r,i)})})}(ag,og,X_,W_);const Bc=new Array(6);function As(e,t){const n=e[0],i=e[1],r=e[2],s=e[3],o=e[4],a=e[5],l=t[0],c=t[1],u=t[2],h=t[3],p=t[4],f=t[5];return e[0]=n*l+r*c,e[1]=i*l+s*c,e[2]=n*u+r*h,e[3]=i*u+s*h,e[4]=n*p+r*f+o,e[5]=i*p+s*f+a,e}function Ss(e,t,n,i,r,s,o){return e[0]=t,e[1]=n,e[2]=i,e[3]=r,e[4]=s,e[5]=o,e}function Wr(e,t){const n=t[0],i=t[1];return t[0]=e[0]*n+e[2]*i+e[4],t[1]=e[1]*n+e[3]*i+e[5],t}function Tg(e,t,n){return As(e,Ss(Bc,t,0,0,n,0,0))}function Rg(e,t,n){return As(e,Ss(Bc,1,0,0,1,t,n))}function Yr(e,t,n,i,r,s,o,a){const l=Math.sin(s),c=Math.cos(s);return e[0]=i*c,e[1]=r*l,e[2]=-i*l,e[3]=r*c,e[4]=o*i*c-a*i*l+t,e[5]=o*r*l+a*r*c+n,e}function kg(e,t){const n=function(c){return c[0]*c[3]-c[1]*c[2]}(t);Ce(n!==0,"Transformation matrix cannot be inverted");const i=t[0],r=t[1],s=t[2],o=t[3],a=t[4],l=t[5];return e[0]=o/n,e[1]=-r/n,e[2]=-s/n,e[3]=i/n,e[4]=(s*l-o*a)/n,e[5]=-(i*l-r*a)/n,e}function Pg(e,t,n,i,r,s){s=s||[];let o=0;for(let a=t;a<n;a+=i){const l=e[a],c=e[a+1];s[o++]=r[0]*l+r[2]*c+r[4],s[o++]=r[1]*l+r[3]*c+r[5]}return s&&s.length!=o&&(s.length=o),s}const Ig=[1,0,0,1,0,0];let Mg=class extends Kt{constructor(){super(),this.extent_=[1/0,1/0,-1/0,-1/0],this.extentRevision_=-1,this.simplifiedGeometryMaxMinSquaredTolerance=0,this.simplifiedGeometryRevision=0,this.simplifyTransformedInternal=Hp((e,t,n)=>{if(!n)return this.getSimplifiedGeometry(t);const i=this.clone();return i.applyTransform(n),i.getSimplifiedGeometry(t)})}simplifyTransformed(e,t){return this.simplifyTransformedInternal(this.getRevision(),e,t)}clone(){return ue()}closestPointXY(e,t,n,i){return ue()}containsXY(e,t){const n=this.getClosestPoint([e,t]);return n[0]===e&&n[1]===t}getClosestPoint(e,t){return t=t||[NaN,NaN],this.closestPointXY(e[0],e[1],t,1/0),t}intersectsCoordinate(e){return this.containsXY(e[0],e[1])}computeExtent(e){return ue()}getExtent(e){if(this.extentRevision_!=this.getRevision()){const t=this.computeExtent(this.extent_);(isNaN(t[0])||isNaN(t[1]))&&Zi(t),this.extentRevision_=this.getRevision()}return function(t,n){return n?(n[0]=t[0],n[1]=t[1],n[2]=t[2],n[3]=t[3],n):t}(this.extent_,e)}rotate(e,t){ue()}scale(e,t,n){ue()}simplify(e){return this.getSimplifiedGeometry(e*e)}getSimplifiedGeometry(e){return ue()}getType(){return ue()}applyTransform(e){ue()}intersectsExtent(e){return ue()}translate(e,t){ue()}transform(e,t){const n=He(e),i=n.getUnits()=="tile-pixels"?function(r,s,o){const a=n.getExtent(),l=n.getWorldExtent(),c=Tt(l)/Tt(a);return Yr(Ig,l[0],l[3],c,-c,0,0,0),Pg(r,0,r.length,o,Ig,s),Ki(n,t)(r,s,o)}:Ki(n,t);return this.applyTransform(i),this}},yi=class extends Mg{constructor(){super(),this.layout="XY",this.stride=2,this.flatCoordinates}computeExtent(e){return Ec(this.flatCoordinates,0,this.flatCoordinates.length,this.stride,e)}getCoordinates(){return ue()}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(e){if(this.simplifiedGeometryRevision!==this.getRevision()&&(this.simplifiedGeometryMaxMinSquaredTolerance=0,this.simplifiedGeometryRevision=this.getRevision()),e<0||this.simplifiedGeometryMaxMinSquaredTolerance!==0&&e<=this.simplifiedGeometryMaxMinSquaredTolerance)return this;const t=this.getSimplifiedGeometryInternal(e);return t.getFlatCoordinates().length<this.flatCoordinates.length?t:(this.simplifiedGeometryMaxMinSquaredTolerance=e,this)}getSimplifiedGeometryInternal(e){return this}getStride(){return this.stride}setFlatCoordinates(e,t){this.stride=Lg(e),this.layout=e,this.flatCoordinates=t}setCoordinates(e,t){ue()}setLayout(e,t,n){let i;if(e)i=Lg(e);else{for(let r=0;r<n;++r){if(t.length===0)return this.layout="XY",void(this.stride=2);t=t[0]}i=t.length,e=bi(i)}this.layout=e,this.stride=i}applyTransform(e){this.flatCoordinates&&(e(this.flatCoordinates,this.flatCoordinates,this.stride),this.changed())}rotate(e,t){const n=this.getFlatCoordinates();if(n){const i=this.getStride();(function(r,s,o,a,l,c,u){u=u||[];const h=Math.cos(l),p=Math.sin(l),f=c[0],m=c[1];let _=0;for(let y=s;y<o;y+=a){const x=r[y]-f,w=r[y+1]-m;u[_++]=f+x*h-w*p,u[_++]=m+x*p+w*h;for(let T=y+2;T<y+a;++T)u[_++]=r[T]}u&&u.length!=_&&(u.length=_)})(n,0,n.length,i,e,t,n),this.changed()}}scale(e,t,n){t===void 0&&(t=e),n||(n=Xn(this.getExtent()));const i=this.getFlatCoordinates();if(i){const r=this.getStride();(function(s,o,a,l,c,u,h,p){p=p||[];const f=h[0],m=h[1];let _=0;for(let y=o;y<a;y+=l){const x=s[y]-f,w=s[y+1]-m;p[_++]=f+c*x,p[_++]=m+u*w;for(let T=y+2;T<y+l;++T)p[_++]=s[T]}p&&p.length!=_&&(p.length=_)})(i,0,i.length,r,e,t,n,i),this.changed()}}translate(e,t){const n=this.getFlatCoordinates();if(n){const i=this.getStride();(function(r,s,o,a,l,c,u){u=u||[];let h=0;for(let p=s;p<o;p+=a){u[h++]=r[p]+l,u[h++]=r[p+1]+c;for(let f=p+2;f<p+a;++f)u[h++]=r[f]}u&&u.length!=h&&(u.length=h)})(n,0,n.length,i,e,t,n),this.changed()}}};function bi(e){let t;return e==2?t="XY":e==3?t="XYZ":e==4&&(t="XYZM"),t}function Lg(e){let t;return e=="XY"?t=2:e=="XYZ"||e=="XYM"?t=3:e=="XYZM"&&(t=4),t}function Fg(e,t,n,i,r,s,o){const a=e[t],l=e[t+1],c=e[n]-a,u=e[n+1]-l;let h;if(c===0&&u===0)h=t;else{const p=((r-a)*c+(s-l)*u)/(c*c+u*u);if(p>1)h=n;else{if(p>0){for(let f=0;f<i;++f)o[f]=uc(e[t+f],e[n+f],p);return void(o.length=i)}h=t}}for(let p=0;p<i;++p)o[p]=e[h+p];o.length=i}function zc(e,t,n,i,r){let s=e[t],o=e[t+1];for(t+=i;t<n;t+=i){const a=e[t],l=e[t+1],c=di(s,o,a,l);c>r&&(r=c),s=a,o=l}return r}function jc(e,t,n,i,r){for(let s=0,o=n.length;s<o;++s){const a=n[s];r=zc(e,t,a,i,r),t=a}return r}function Nc(e,t,n,i,r,s,o,a,l,c,u){if(t==n)return c;let h,p;if(r===0){if(p=di(o,a,e[t],e[t+1]),p<c){for(h=0;h<i;++h)l[h]=e[t+h];return l.length=i,p}return c}u=u||[NaN,NaN];let f=t+i;for(;f<n;)if(Fg(e,f-i,f,i,o,a,u),p=di(o,a,u[0],u[1]),p<c){for(c=p,h=0;h<i;++h)l[h]=u[h];l.length=i,f+=i}else f+=i*Math.max((Math.sqrt(p)-Math.sqrt(c))/r|0,1);if(s&&(Fg(e,n-i,t,i,o,a,u),p=di(o,a,u[0],u[1]),p<c)){for(c=p,h=0;h<i;++h)l[h]=u[h];l.length=i}return c}function Gc(e,t,n,i,r,s,o,a,l,c,u){u=u||[NaN,NaN];for(let h=0,p=n.length;h<p;++h){const f=n[h];c=Nc(e,t,f,i,r,s,o,a,l,c,u),t=f}return c}function Ts(e,t,n,i){for(let r=0,s=n.length;r<s;++r){const o=n[r];for(let a=0;a<i;++a)e[t++]=o[a]}return t}function Zr(e,t,n,i,r){r=r||[];let s=0;for(let o=0,a=n.length;o<a;++o){const l=Ts(e,t,n[o],i);r[s++]=l,t=l}return r.length=s,r}function Og(e,t,n,i,r){r=r||[];let s=0;for(let o=0,a=n.length;o<a;++o){const l=Zr(e,t,n[o],i,r[s]);l.length===0&&(l[0]=t),r[s++]=l,t=l[l.length-1]}return r.length=s,r}function Rs(e,t,n,i,r,s,o){const a=(n-t)/i;if(a<3){for(;t<n;t+=i)s[o++]=e[t],s[o++]=e[t+1];return o}const l=new Array(a);l[0]=1,l[a-1]=1;const c=[t,n-i];let u=0;for(;c.length>0;){const h=c.pop(),p=c.pop();let f=0;const m=e[p],_=e[p+1],y=e[h],x=e[h+1];for(let w=p+i;w<h;w+=i){const T=N_(e[w],e[w+1],m,_,y,x);T>f&&(u=w,f=T)}f>r&&(l[(u-t)/i]=1,p+i<u&&c.push(p,u),u+i<h&&c.push(u,h))}for(let h=0;h<a;++h)l[h]&&(s[o++]=e[t+h*i],s[o++]=e[t+h*i+1]);return o}function Dg(e,t,n,i,r,s,o,a){for(let l=0,c=n.length;l<c;++l){const u=n[l];o=Rs(e,t,u,i,r,s,o),a.push(o),t=u}return o}function Qi(e,t){return t*Math.round(e/t)}function iy(e,t,n,i,r,s,o){if(t==n)return o;let a,l,c=Qi(e[t],r),u=Qi(e[t+1],r);t+=i,s[o++]=c,s[o++]=u;do if(a=Qi(e[t],r),l=Qi(e[t+1],r),(t+=i)==n)return s[o++]=a,s[o++]=l,o;while(a==c&&l==u);for(;t<n;){const h=Qi(e[t],r),p=Qi(e[t+1],r);if(t+=i,h==a&&p==l)continue;const f=a-c,m=l-u,_=h-c,y=p-u;f*y==m*_&&(f<0&&_<f||f==_||f>0&&_>f)&&(m<0&&y<m||m==y||m>0&&y>m)?(a=h,l=p):(s[o++]=a,s[o++]=l,c=a,u=l,a=h,l=p)}return s[o++]=a,s[o++]=l,o}function Vc(e,t,n,i,r,s,o,a){for(let l=0,c=n.length;l<c;++l){const u=n[l];o=iy(e,t,u,i,r,s,o),a.push(o),t=u}return o}function ks(e,t,n,i,r){r=r!==void 0?r:[];let s=0;for(let o=t;o<n;o+=i)r[s++]=e.slice(o,o+i);return r.length=s,r}function $c(e,t,n,i,r){r=r!==void 0?r:[];let s=0;for(let o=0,a=n.length;o<a;++o){const l=n[o];r[s++]=ks(e,t,l,i,r[s]),t=l}return r.length=s,r}function Ug(e,t,n,i){let r=0;const s=e[n-i],o=e[n-i+1];let a=0,l=0;for(;t<n;t+=i){const c=e[t]-s,u=e[t+1]-o;r+=l*c-a*u,a=c,l=u}return r/2}function Bg(e,t,n,i){let r=0;for(let s=0,o=n.length;s<o;++s){const a=n[s];r+=Ug(e,t,a,i),t=a}return r}let zg=class Lh extends yi{constructor(t,n){super(),this.maxDelta_=-1,this.maxDeltaRevision_=-1,n===void 0||Array.isArray(t[0])?this.setCoordinates(t,n):this.setFlatCoordinates(n,t)}clone(){return new Lh(this.flatCoordinates.slice(),this.layout)}closestPointXY(t,n,i,r){return r<gi(this.getExtent(),t,n)?r:(this.maxDeltaRevision_!=this.getRevision()&&(this.maxDelta_=Math.sqrt(zc(this.flatCoordinates,0,this.flatCoordinates.length,this.stride,0)),this.maxDeltaRevision_=this.getRevision()),Nc(this.flatCoordinates,0,this.flatCoordinates.length,this.stride,this.maxDelta_,!0,t,n,i,r))}getArea(){return Ug(this.flatCoordinates,0,this.flatCoordinates.length,this.stride)}getCoordinates(){return ks(this.flatCoordinates,0,this.flatCoordinates.length,this.stride)}getSimplifiedGeometryInternal(t){const n=[];return n.length=Rs(this.flatCoordinates,0,this.flatCoordinates.length,this.stride,t,n,0),new Lh(n,"XY")}getType(){return"LinearRing"}intersectsExtent(t){return!1}setCoordinates(t,n){this.setLayout(n,t,1),this.flatCoordinates||(this.flatCoordinates=[]),this.flatCoordinates.length=Ts(this.flatCoordinates,0,t,this.stride),this.changed()}},Ps=class Bm extends yi{constructor(t,n){super(),this.setCoordinates(t,n)}clone(){const t=new Bm(this.flatCoordinates.slice(),this.layout);return t.applyProperties(this),t}closestPointXY(t,n,i,r){const s=this.flatCoordinates,o=di(t,n,s[0],s[1]);if(o<r){const a=this.stride;for(let l=0;l<a;++l)i[l]=s[l];return i.length=a,o}return r}getCoordinates(){return this.flatCoordinates.slice()}computeExtent(t){return ug(this.flatCoordinates,t)}getType(){return"Point"}intersectsExtent(t){return wc(t,this.flatCoordinates[0],this.flatCoordinates[1])}setCoordinates(t,n){this.setLayout(n,t,0),this.flatCoordinates||(this.flatCoordinates=[]),this.flatCoordinates.length=function(i,r,s){for(let o=0,a=s.length;o<a;++o)i[r++]=s[o];return r}(this.flatCoordinates,0,t,this.stride),this.changed()}};function ry(e,t,n,i,r){return!pg(r,function(s){return!xi(e,t,n,i,s[0],s[1])})}function xi(e,t,n,i,r,s){let o=0,a=e[n-i],l=e[n-i+1];for(;t<n;t+=i){const c=e[t],u=e[t+1];l<=s?u>s&&(c-a)*(s-l)-(r-a)*(u-l)>0&&o++:u<=s&&(c-a)*(s-l)-(r-a)*(u-l)<0&&o--,a=c,l=u}return o!==0}function qc(e,t,n,i,r,s){if(n.length===0||!xi(e,t,n[0],i,r,s))return!1;for(let o=1,a=n.length;o<a;++o)if(xi(e,n[o-1],n[o],i,r,s))return!1;return!0}function Xc(e,t,n,i,r,s,o){let a,l,c,u,h,p,f;const m=r[s+1],_=[];for(let w=0,T=n.length;w<T;++w){const R=n[w];for(u=e[R-i],p=e[R-i+1],a=t;a<R;a+=i)h=e[a],f=e[a+1],(m<=p&&f<=m||p<=m&&m<=f)&&(c=(m-p)/(f-p)*(h-u)+u,_.push(c)),u=h,p=f}let y=NaN,x=-1/0;for(_.sort(as),u=_[0],a=1,l=_.length;a<l;++a){h=_[a];const w=Math.abs(h-u);w>x&&(c=(u+h)/2,qc(e,t,n,i,c,m)&&(y=c,x=w)),u=h}return isNaN(y)&&(y=r[s]),o?(o.push(y,m,x),o):[y,m,x]}function jg(e,t,n,i,r){let s=[];for(let o=0,a=n.length;o<a;++o){const l=n[o];s=Xc(e,t,l,i,r,2*o,s),t=l[l.length-1]}return s}function Ng(e,t,n,i,r){let s;for(t+=i;t<n;t+=i)if(s=r(e.slice(t-i,t),e.slice(t,t+i)),s)return s;return!1}function Is(e,t,n,i,r){const s=dg([1/0,1/0,-1/0,-1/0],e,t,n,i);return!!Es(r,s)&&(!!(xs(r,s)||s[0]>=r[0]&&s[2]<=r[2]||s[1]>=r[1]&&s[3]<=r[3])||Ng(e,t,n,i,function(o,a){return function(l,c,u){let h=!1;const p=cg(l,c),f=cg(l,u);if(p===mc||f===mc)h=!0;else{const m=l[0],_=l[1],y=l[2],x=l[3],w=c[0],T=c[1],R=u[0],b=u[1],k=(b-T)/(R-w);let F,j;f&vc&&!(p&vc)&&(F=R-(b-x)/k,h=F>=m&&F<=y),!h&&f&_c&&!(p&_c)&&(j=b-(R-y)*k,h=j>=_&&j<=x),!h&&f&yc&&!(p&yc)&&(F=R-(b-_)/k,h=F>=m&&F<=y),!h&&f&bc&&!(p&bc)&&(j=b-(R-m)*k,h=j>=_&&j<=x)}return h}(r,o,a)}))}function Gg(e,t,n,i,r){return!!(Is(e,t,n,i,r)||xi(e,t,n,i,r[0],r[1])||xi(e,t,n,i,r[0],r[3])||xi(e,t,n,i,r[2],r[1])||xi(e,t,n,i,r[2],r[3]))}function Vg(e,t,n,i,r){if(!Gg(e,t,n[0],i,r))return!1;if(n.length===1)return!0;for(let s=1,o=n.length;s<o;++s)if(ry(e,n[s-1],n[s],i,r)&&!Is(e,n[s-1],n[s],i,r))return!1;return!0}function oy(e,t,n,i){for(;t<n-i;){for(let r=0;r<i;++r){const s=e[t+r];e[t+r]=e[n-i+r],e[n-i+r]=s}t+=i,n-=i}}function Wc(e,t,n,i){let r=0,s=e[n-i],o=e[n-i+1];for(;t<n;t+=i){const a=e[t],l=e[t+1];r+=(a-s)*(l+o),s=a,o=l}return r===0?void 0:r>0}function Yc(e,t,n,i,r){r=r!==void 0&&r;for(let s=0,o=n.length;s<o;++s){const a=n[s],l=Wc(e,t,a,i);if(s===0){if(r&&l||!r&&!l)return!1}else if(r&&!l||!r&&l)return!1;t=a}return!0}function $g(e,t,n,i,r){for(let s=0,o=n.length;s<o;++s){const a=n[s];if(!Yc(e,t,a,i,r))return!1;a.length&&(t=a[a.length-1])}return!0}function Ms(e,t,n,i,r){r=r!==void 0&&r;for(let s=0,o=n.length;s<o;++s){const a=n[s],l=Wc(e,t,a,i);(s===0?r&&l||!r&&!l:r&&!l||!r&&l)&&oy(e,t,a,i),t=a}return t}function Zc(e,t,n,i,r){for(let s=0,o=n.length;s<o;++s)t=Ms(e,t,n[s],i,r);return t}let Hr=class Fh extends yi{constructor(t,n,i){super(),this.ends_=[],this.flatInteriorPointRevision_=-1,this.flatInteriorPoint_=null,this.maxDelta_=-1,this.maxDeltaRevision_=-1,this.orientedRevision_=-1,this.orientedFlatCoordinates_=null,n!==void 0&&i?(this.setFlatCoordinates(n,t),this.ends_=i):this.setCoordinates(t,n)}appendLinearRing(t){this.flatCoordinates?ln(this.flatCoordinates,t.getFlatCoordinates()):this.flatCoordinates=t.getFlatCoordinates().slice(),this.ends_.push(this.flatCoordinates.length),this.changed()}clone(){const t=new Fh(this.flatCoordinates.slice(),this.layout,this.ends_.slice());return t.applyProperties(this),t}closestPointXY(t,n,i,r){return r<gi(this.getExtent(),t,n)?r:(this.maxDeltaRevision_!=this.getRevision()&&(this.maxDelta_=Math.sqrt(jc(this.flatCoordinates,0,this.ends_,this.stride,0)),this.maxDeltaRevision_=this.getRevision()),Gc(this.flatCoordinates,0,this.ends_,this.stride,this.maxDelta_,!0,t,n,i,r))}containsXY(t,n){return qc(this.getOrientedFlatCoordinates(),0,this.ends_,this.stride,t,n)}getArea(){return Bg(this.getOrientedFlatCoordinates(),0,this.ends_,this.stride)}getCoordinates(t){let n;return t!==void 0?(n=this.getOrientedFlatCoordinates().slice(),Ms(n,0,this.ends_,this.stride,t)):n=this.flatCoordinates,$c(n,0,this.ends_,this.stride)}getEnds(){return this.ends_}getFlatInteriorPoint(){if(this.flatInteriorPointRevision_!=this.getRevision()){const t=Xn(this.getExtent());this.flatInteriorPoint_=Xc(this.getOrientedFlatCoordinates(),0,this.ends_,this.stride,t,0),this.flatInteriorPointRevision_=this.getRevision()}return this.flatInteriorPoint_}getInteriorPoint(){return new Ps(this.getFlatInteriorPoint(),"XYM")}getLinearRingCount(){return this.ends_.length}getLinearRing(t){return t<0||this.ends_.length<=t?null:new zg(this.flatCoordinates.slice(t===0?0:this.ends_[t-1],this.ends_[t]),this.layout)}getLinearRings(){const t=this.layout,n=this.flatCoordinates,i=this.ends_,r=[];let s=0;for(let o=0,a=i.length;o<a;++o){const l=i[o],c=new zg(n.slice(s,l),t);r.push(c),s=l}return r}getOrientedFlatCoordinates(){if(this.orientedRevision_!=this.getRevision()){const t=this.flatCoordinates;Yc(t,0,this.ends_,this.stride)?this.orientedFlatCoordinates_=t:(this.orientedFlatCoordinates_=t.slice(),this.orientedFlatCoordinates_.length=Ms(this.orientedFlatCoordinates_,0,this.ends_,this.stride)),this.orientedRevision_=this.getRevision()}return this.orientedFlatCoordinates_}getSimplifiedGeometryInternal(t){const n=[],i=[];return n.length=Vc(this.flatCoordinates,0,this.ends_,this.stride,Math.sqrt(t),n,0,i),new Fh(n,"XY",i)}getType(){return"Polygon"}intersectsExtent(t){return Vg(this.getOrientedFlatCoordinates(),0,this.ends_,this.stride,t)}setCoordinates(t,n){this.setLayout(n,t,2),this.flatCoordinates||(this.flatCoordinates=[]);const i=Zr(this.flatCoordinates,0,t,this.stride,this.ends_);this.flatCoordinates.length=i.length===0?0:i[i.length-1],this.changed()}};function qg(e){if(mi(e))throw new Error("Cannot create polygon from empty extent");const t=e[0],n=e[1],i=e[2],r=e[3],s=[t,n,t,r,i,r,i,n,t,n];return new Hr(s,"XY",[s.length])}class cn extends Kt{constructor(t){super(),this.on,this.once,this.un,t=Object.assign({},t),this.hints_=[0,0],this.animations_=[],this.updateAnimationKey_,this.projection_=Mc(t.projection,"EPSG:3857"),this.viewportSize_=[100,100],this.targetCenter_=null,this.targetResolution_,this.targetRotation_,this.nextCenter_=null,this.nextResolution_,this.nextRotation_,this.cancelAnchor_=void 0,t.projection&&mg(),t.center&&(t.center=An(t.center,this.projection_)),t.extent&&(t.extent=vi(t.extent,this.projection_)),this.applyOptions_(t)}applyOptions_(t){const n=Object.assign({},t);for(const a in Qt)delete n[a];this.setProperties(n,!0);const i=function(a){let l,c,u,h=a.minZoom!==void 0?a.minZoom:0,p=a.maxZoom!==void 0?a.maxZoom:28;const f=a.zoomFactor!==void 0?a.zoomFactor:2,m=a.multiWorld!==void 0&&a.multiWorld,_=a.smoothResolutionConstraint===void 0||a.smoothResolutionConstraint,y=a.showFullExtent!==void 0&&a.showFullExtent,x=Mc(a.projection,"EPSG:3857"),w=x.getExtent();let T=a.constrainOnlyCenter,R=a.extent;if(!m&&!R&&x.isGlobal()&&(T=!1,R=w),a.resolutions!==void 0){const b=a.resolutions;c=b[h],u=b[p]!==void 0?b[p]:b[b.length-1],l=a.constrainResolution?function(k,F,j,B){return F=F===void 0||F,function(N,Y,ee,ne){if(N!==void 0){const G=k[0],V=k[k.length-1],q=j?Oc(G,j,ee,B):G;if(ne)return F?Dc(N,q,V):Ze(N,V,q);const W=Math.min(q,N),se=Math.floor(nc(k,W,Y));return k[se]>q&&se<k.length-1?k[se+1]:k[se]}}}(b,_,!T&&R,y):Cg(c,u,_,!T&&R,y)}else{const b=(w?Math.max(ze(w),Tt(w)):360*gc.degrees/x.getMetersPerUnit())/pc/Math.pow(2,0),k=b/Math.pow(2,28);c=a.maxResolution,c!==void 0?h=0:c=b/Math.pow(f,h),u=a.minResolution,u===void 0&&(u=a.maxZoom!==void 0?a.maxResolution!==void 0?c/Math.pow(f,p):b/Math.pow(f,p):k),p=h+Math.floor(Math.log(c/u)/Math.log(f)),u=c/Math.pow(f,p-h),l=a.constrainResolution?function(F,j,B,N,Y,ee){return N=N===void 0||N,B=B!==void 0?B:0,function(ne,G,V,q){if(ne!==void 0){const W=Y?Oc(j,Y,V,ee):j;if(q)return N?Dc(ne,W,B):Ze(ne,B,W);const se=1e-9,he=Math.ceil(Math.log(j/W)/Math.log(F)-se),Ie=-G*(.5-se)+.5,Fe=Math.min(W,ne),$t=Math.floor(Math.log(j/Fe)/Math.log(F)+Ie),fn=Math.max(he,$t);return Ze(j/Math.pow(F,fn),B,W)}}}(f,c,u,_,!T&&R,y):Cg(c,u,_,!T&&R,y)}return{constraint:l,maxResolution:c,minResolution:u,minZoom:h,zoomFactor:f}}(t);this.maxResolution_=i.maxResolution,this.minResolution_=i.minResolution,this.zoomFactor_=i.zoomFactor,this.resolutions_=t.resolutions,this.padding_=t.padding,this.minZoom_=i.minZoom;const r=function(a){if(a.extent!==void 0){const c=a.smoothExtentConstraint===void 0||a.smoothExtentConstraint;return Eg(a.extent,a.constrainOnlyCenter,c)}const l=Mc(a.projection,"EPSG:3857");if(a.multiWorld!==!0&&l.isGlobal()){const c=l.getExtent().slice();return c[0]=-1/0,c[2]=1/0,Eg(c,!1,!1)}return ey}(t),s=i.constraint,o=function(a){if(a.enableRotation===void 0||a.enableRotation){const l=a.constrainRotation;return l===void 0||l===!0?function(){const c=gs(5);return function(u,h){return h||u===void 0?u:Math.abs(u)<=c?0:u}}():l===!1?Ag:typeof l=="number"?function(c){const u=2*Math.PI/c;return function(h,p){return p?h:h!==void 0?h=Math.floor(h/u+.5)*u:void 0}}(l):Ag}return Uc}(t);this.constraints_={center:r,resolution:s,rotation:o},this.setRotation(t.rotation!==void 0?t.rotation:0),this.setCenterInternal(t.center!==void 0?t.center:null),t.resolution!==void 0?this.setResolution(t.resolution):t.zoom!==void 0&&this.setZoom(t.zoom)}get padding(){return this.padding_}set padding(t){let n=this.padding_;this.padding_=t;const i=this.getCenterInternal();if(i){const r=t||[0,0,0,0];n=n||[0,0,0,0];const s=this.getResolution(),o=s/2*(r[3]-n[3]+n[1]-r[1]),a=s/2*(r[0]-n[0]+n[2]-r[2]);this.setCenterInternal([i[0]+o,i[1]-a])}}getUpdatedOptions_(t){const n=this.getProperties();return n.resolution!==void 0?n.resolution=this.getResolution():n.zoom=this.getZoom(),n.center=this.getCenterInternal(),n.rotation=this.getRotation(),Object.assign({},n,t)}animate(t){this.isDef()&&!this.getAnimating()&&this.resolveConstraints(0);const n=new Array(arguments.length);for(let i=0;i<n.length;++i){let r=arguments[i];r.center&&(r=Object.assign({},r),r.center=An(r.center,this.getProjection())),r.anchor&&(r=Object.assign({},r),r.anchor=An(r.anchor,this.getProjection())),n[i]=r}this.animateInternal.apply(this,n)}animateInternal(t){let n,i=arguments.length;i>1&&typeof arguments[i-1]=="function"&&(n=arguments[i-1],--i);let r=0;for(;r<i&&!this.isDef();++r){const u=arguments[r];u.center&&this.setCenterInternal(u.center),u.zoom!==void 0?this.setZoom(u.zoom):u.resolution&&this.setResolution(u.resolution),u.rotation!==void 0&&this.setRotation(u.rotation)}if(r===i)return void(n&&Ls(n,!0));let s=Date.now(),o=this.targetCenter_.slice(),a=this.targetResolution_,l=this.targetRotation_;const c=[];for(;r<i;++r){const u=arguments[r],h={start:s,complete:!1,anchor:u.anchor,duration:u.duration!==void 0?u.duration:1e3,easing:u.easing||ty,callback:n};if(u.center&&(h.sourceCenter=o,h.targetCenter=u.center.slice(),o=h.targetCenter),u.zoom!==void 0?(h.sourceResolution=a,h.targetResolution=this.getResolutionForZoom(u.zoom),a=h.targetResolution):u.resolution&&(h.sourceResolution=a,h.targetResolution=u.resolution,a=h.targetResolution),u.rotation!==void 0){h.sourceRotation=l;const p=$i(u.rotation-l+Math.PI,2*Math.PI)-Math.PI;h.targetRotation=l+p,l=h.targetRotation}sy(h)?h.complete=!0:s+=h.duration,c.push(h)}this.animations_.push(c),this.setHint(qn,1),this.updateAnimations_()}getAnimating(){return this.hints_[qn]>0}getInteracting(){return this.hints_[qi]>0}cancelAnimations(){let t;this.setHint(qn,-this.hints_[qn]);for(let n=0,i=this.animations_.length;n<i;++n){const r=this.animations_[n];if(r[0].callback&&Ls(r[0].callback,!1),!t)for(let s=0,o=r.length;s<o;++s){const a=r[s];if(!a.complete){t=a.anchor;break}}}this.animations_.length=0,this.cancelAnchor_=t,this.nextCenter_=null,this.nextResolution_=NaN,this.nextRotation_=NaN}updateAnimations_(){if(this.updateAnimationKey_!==void 0&&(cancelAnimationFrame(this.updateAnimationKey_),this.updateAnimationKey_=void 0),!this.getAnimating())return;const t=Date.now();let n=!1;for(let i=this.animations_.length-1;i>=0;--i){const r=this.animations_[i];let s=!0;for(let o=0,a=r.length;o<a;++o){const l=r[o];if(l.complete)continue;const c=t-l.start;let u=l.duration>0?c/l.duration:1;u>=1?(l.complete=!0,u=1):s=!1;const h=l.easing(u);if(l.sourceCenter){const p=l.sourceCenter[0],f=l.sourceCenter[1],m=l.targetCenter[0],_=l.targetCenter[1];this.nextCenter_=l.targetCenter;const y=p+h*(m-p),x=f+h*(_-f);this.targetCenter_=[y,x]}if(l.sourceResolution&&l.targetResolution){const p=h===1?l.targetResolution:l.sourceResolution+h*(l.targetResolution-l.sourceResolution);if(l.anchor){const f=this.getViewportSize_(this.getRotation()),m=this.constraints_.resolution(p,0,f,!0);this.targetCenter_=this.calculateCenterZoom(m,l.anchor)}this.nextResolution_=l.targetResolution,this.targetResolution_=p,this.applyTargetState_(!0)}if(l.sourceRotation!==void 0&&l.targetRotation!==void 0){const p=h===1?$i(l.targetRotation+Math.PI,2*Math.PI)-Math.PI:l.sourceRotation+h*(l.targetRotation-l.sourceRotation);if(l.anchor){const f=this.constraints_.rotation(p,!0);this.targetCenter_=this.calculateCenterRotate(f,l.anchor)}this.nextRotation_=l.targetRotation,this.targetRotation_=p}if(this.applyTargetState_(!0),n=!0,!l.complete)break}if(s){this.animations_[i]=null,this.setHint(qn,-1),this.nextCenter_=null,this.nextResolution_=NaN,this.nextRotation_=NaN;const o=r[0].callback;o&&Ls(o,!0)}}this.animations_=this.animations_.filter(Boolean),n&&this.updateAnimationKey_===void 0&&(this.updateAnimationKey_=requestAnimationFrame(this.updateAnimations_.bind(this)))}calculateCenterRotate(t,n){let i;const r=this.getCenterInternal();return r!==void 0&&(i=[r[0]-n[0],r[1]-n[1]],kc(i,t-this.getRotation()),function(s,o){s[0]+=+o[0],s[1]+=+o[1]}(i,n)),i}calculateCenterZoom(t,n){let i;const r=this.getCenterInternal(),s=this.getResolution();return r!==void 0&&s!==void 0&&(i=[n[0]-t*(n[0]-r[0])/s,n[1]-t*(n[1]-r[1])/s]),i}getViewportSize_(t){const n=this.viewportSize_;if(t){const i=n[0],r=n[1];return[Math.abs(i*Math.cos(t))+Math.abs(r*Math.sin(t)),Math.abs(i*Math.sin(t))+Math.abs(r*Math.cos(t))]}return n}setViewportSize(t){this.viewportSize_=Array.isArray(t)?t.slice():[100,100],this.getAnimating()||this.resolveConstraints(0)}getCenter(){const t=this.getCenterInternal();return t&&Fc(t,this.getProjection())}getCenterInternal(){return this.get(Qt.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){return wg(this.calculateExtentInternal(t),this.getProjection())}calculateExtentInternal(t){t=t||this.getViewportSizeMinusPadding_();const n=this.getCenterInternal();Ce(n,"The view center is not defined");const i=this.getResolution();Ce(i!==void 0,"The view resolution is not defined");const r=this.getRotation();return Ce(r!==void 0,"The view rotation is not defined"),Sc(n,i,r,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(Qt.RESOLUTION)}getResolutions(){return this.resolutions_}getResolutionForExtent(t,n){return this.getResolutionForExtentInternal(vi(t,this.getProjection()),n)}getResolutionForExtentInternal(t,n){n=n||this.getViewportSizeMinusPadding_();const i=ze(t)/n[0],r=Tt(t)/n[1];return Math.max(i,r)}getResolutionForValueFunction(t){t=t||2;const n=this.getConstrainedResolution(this.maxResolution_),i=this.minResolution_,r=Math.log(n/i)/Math.log(t);return function(s){return n/Math.pow(t,s*r)}}getRotation(){return this.get(Qt.ROTATION)}getValueForResolutionFunction(t){const n=Math.log(t||2),i=this.getConstrainedResolution(this.maxResolution_),r=this.minResolution_,s=Math.log(i/r)/n;return function(o){return Math.log(i/o)/n/s}}getViewportSizeMinusPadding_(t){let n=this.getViewportSize_(t);const i=this.padding_;return i&&(n=[n[0]-i[1]-i[3],n[1]-i[0]-i[2]]),n}getState(){const t=this.getProjection(),n=this.getResolution(),i=this.getRotation();let r=this.getCenterInternal();const s=this.padding_;if(s){const o=this.getViewportSizeMinusPadding_();r=Hc(r,this.getViewportSize_(),[o[0]/2+s[3],o[1]/2+s[0]],n,i)}return{center:r.slice(0),projection:t!==void 0?t:null,resolution:n,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 n=this.getResolution();return n!==void 0&&(t=this.getZoomForResolution(n)),t}getZoomForResolution(t){let n,i,r=this.minZoom_||0;if(this.resolutions_){const s=nc(this.resolutions_,t,1);r=s,n=this.resolutions_[s],i=s==this.resolutions_.length-1?2:n/this.resolutions_[s+1]}else n=this.maxResolution_,i=this.zoomFactor_;return r+Math.log(n/t)/Math.log(i)}getResolutionForZoom(t){if(this.resolutions_){if(this.resolutions_.length<=1)return 0;const n=Ze(Math.floor(t),0,this.resolutions_.length-2),i=this.resolutions_[n]/this.resolutions_[n+1];return this.resolutions_[n]/Math.pow(i,Ze(t-n,0,1))}return this.maxResolution_/Math.pow(this.zoomFactor_,t-this.minZoom_)}fit(t,n){let i;if(Ce(Array.isArray(t)||typeof t.getSimplifiedGeometry=="function","Invalid extent or geometry provided as `geometry`"),Array.isArray(t))Ce(!mi(t),"Cannot fit empty extent provided as `geometry`"),i=qg(vi(t,this.getProjection()));else if(t.getType()==="Circle"){const r=vi(t.getExtent(),this.getProjection());i=qg(r),i.rotate(this.getRotation(),Xn(r))}else i=t;this.fitInternal(i,n)}rotatedExtentForGeometry(t){const n=this.getRotation(),i=Math.cos(n),r=Math.sin(-n),s=t.getFlatCoordinates(),o=t.getStride();let a=1/0,l=1/0,c=-1/0,u=-1/0;for(let h=0,p=s.length;h<p;h+=o){const f=s[h]*i-s[h+1]*r,m=s[h]*r+s[h+1]*i;a=Math.min(a,f),l=Math.min(l,m),c=Math.max(c,f),u=Math.max(u,m)}return[a,l,c,u]}fitInternal(t,n){let i=(n=n||{}).size;i||(i=this.getViewportSizeMinusPadding_());const r=n.padding!==void 0?n.padding:[0,0,0,0],s=n.nearest!==void 0&&n.nearest;let o;o=n.minResolution!==void 0?n.minResolution:n.maxZoom!==void 0?this.getResolutionForZoom(n.maxZoom):0;const a=this.rotatedExtentForGeometry(t);let l=this.getResolutionForExtentInternal(a,[i[0]-r[1]-r[3],i[1]-r[0]-r[2]]);l=isNaN(l)?o:Math.max(l,o),l=this.getConstrainedResolution(l,s?0:1);const c=this.getRotation(),u=Math.sin(c),h=Math.cos(c),p=Xn(a);p[0]+=(r[1]-r[3])/2*l,p[1]+=(r[0]-r[2])/2*l;const f=p[0]*h-p[1]*u,m=p[1]*h+p[0]*u,_=this.getConstrainedCenter([f,m],l),y=n.callback?n.callback:Gi;n.duration!==void 0?this.animateInternal({resolution:l,center:_,duration:n.duration,easing:n.easing},y):(this.targetResolution_=l,this.targetCenter_=_,this.applyTargetState_(!1,!0),Ls(y,!0))}centerOn(t,n,i){this.centerOnInternal(An(t,this.getProjection()),n,i)}centerOnInternal(t,n,i){this.setCenterInternal(Hc(t,n,i,this.getResolution(),this.getRotation()))}calculateCenterShift(t,n,i,r){let s;const o=this.padding_;if(o&&t){const a=this.getViewportSizeMinusPadding_(-i),l=Hc(t,r,[a[0]/2+o[3],a[1]/2+o[0]],n,i);s=[t[0]-l[0],t[1]-l[1]]}return s}isDef(){return!!this.getCenterInternal()&&this.getResolution()!==void 0}adjustCenter(t){const n=Fc(this.targetCenter_,this.getProjection());this.setCenter([n[0]+t[0],n[1]+t[1]])}adjustCenterInternal(t){const n=this.targetCenter_;this.setCenterInternal([n[0]+t[0],n[1]+t[1]])}adjustResolution(t,n){n=n&&An(n,this.getProjection()),this.adjustResolutionInternal(t,n)}adjustResolutionInternal(t,n){const i=this.getAnimating()||this.getInteracting(),r=this.getViewportSize_(this.getRotation()),s=this.constraints_.resolution(this.targetResolution_*t,0,r,i);n&&(this.targetCenter_=this.calculateCenterZoom(s,n)),this.targetResolution_*=t,this.applyTargetState_()}adjustZoom(t,n){this.adjustResolution(Math.pow(this.zoomFactor_,-t),n)}adjustRotation(t,n){n&&(n=An(n,this.getProjection())),this.adjustRotationInternal(t,n)}adjustRotationInternal(t,n){const i=this.getAnimating()||this.getInteracting(),r=this.constraints_.rotation(this.targetRotation_+t,i);n&&(this.targetCenter_=this.calculateCenterRotate(r,n)),this.targetRotation_+=t,this.applyTargetState_()}setCenter(t){this.setCenterInternal(t&&An(t,this.getProjection()))}setCenterInternal(t){this.targetCenter_=t,this.applyTargetState_()}setHint(t,n){return this.hints_[t]+=n,this.changed(),this.hints_[t]}setResolution(t){this.targetResolution_=t,this.applyTargetState_()}setRotation(t){this.targetRotation_=t,this.applyTargetState_()}setZoom(t){this.setResolution(this.getResolutionForZoom(t))}applyTargetState_(t,n){const i=this.getAnimating()||this.getInteracting()||n,r=this.constraints_.rotation(this.targetRotation_,i),s=this.getViewportSize_(r),o=this.constraints_.resolution(this.targetResolution_,0,s,i),a=this.constraints_.center(this.targetCenter_,o,s,i,this.calculateCenterShift(this.targetCenter_,o,r,s));this.get(Qt.ROTATION)!==r&&this.set(Qt.ROTATION,r),this.get(Qt.RESOLUTION)!==o&&(this.set(Qt.RESOLUTION,o),this.set("zoom",this.getZoom(),!0)),(!a||!this.get(Qt.CENTER)||!Cs(this.get(Qt.CENTER),a))&&this.set(Qt.CENTER,a),this.getAnimating()&&!t&&this.cancelAnimations(),this.cancelAnchor_=void 0}resolveConstraints(t,n,i){t=t!==void 0?t:200;const r=n||0,s=this.constraints_.rotation(this.targetRotation_),o=this.getViewportSize_(s),a=this.constraints_.resolution(this.targetResolution_,r,o),l=this.constraints_.center(this.targetCenter_,a,o,!1,this.calculateCenterShift(this.targetCenter_,a,s,o));if(t===0&&!this.cancelAnchor_)return this.targetResolution_=a,this.targetRotation_=s,this.targetCenter_=l,void this.applyTargetState_();i=i||(t===0?this.cancelAnchor_:void 0),this.cancelAnchor_=void 0,(this.getResolution()!==a||this.getRotation()!==s||!this.getCenterInternal()||!Cs(this.getCenterInternal(),l))&&(this.getAnimating()&&this.cancelAnimations(),this.animateInternal({rotation:s,center:l,resolution:a,duration:t,easing:_i,anchor:i}))}beginInteraction(){this.resolveConstraints(0),this.setHint(qi,1)}endInteraction(t,n,i){i=i&&An(i,this.getProjection()),this.endInteractionInternal(t,n,i)}endInteractionInternal(t,n,i){this.getInteracting()&&(this.setHint(qi,-1),this.resolveConstraints(t,n,i))}getConstrainedCenter(t,n){const i=this.getViewportSize_(this.getRotation());return this.constraints_.center(t,n||this.getResolution(),i)}getConstrainedZoom(t,n){const i=this.getResolutionForZoom(t);return this.getZoomForResolution(this.getConstrainedResolution(i,n))}getConstrainedResolution(t,n){n=n||0;const i=this.getViewportSize_(this.getRotation());return this.constraints_.resolution(t,n,i)}}function Ls(e,t){setTimeout(function(){e(t)},0)}function sy(e){return!(e.sourceCenter&&e.targetCenter&&!Cs(e.sourceCenter,e.targetCenter)||e.sourceResolution!==e.targetResolution||e.sourceRotation!==e.targetRotation)}function Hc(e,t,n,i,r){const s=Math.cos(-r);let o=Math.sin(-r),a=e[0]*s-e[1]*o,l=e[1]*s+e[0]*o;return a+=(t[0]/2-n[0])*i,l+=(n[1]-t[1]/2)*i,o=-o,[a*s-l*o,l*s+a*o]}function Kc(e,t){if(!e.visible)return!1;const n=t.resolution;if(n<e.minResolution||n>=e.maxResolution)return!1;const i=t.zoom;return i>e.minZoom&&i<=e.maxZoom}const Kr=class extends ig{constructor(e){const t=Object.assign({},e);delete t.source,super(t),this.on,this.once,this.un,this.mapPrecomposeKey_=null,this.mapRenderKey_=null,this.sourceChangeKey_=null,this.renderer_=null,this.sourceReady_=!1,this.rendered=!1,e.render&&(this.render=e.render),e.map&&this.setMap(e.map),this.addChangeListener(ps,this.handleSourcePropertyChange_);const n=e.source?e.source:null;this.setSource(n)}getLayersArray(e){return(e=e||[]).push(this),e}getLayerStatesArray(e){return(e=e||[]).push(this.getLayerState()),e}getSource(){return this.get(ps)||null}getRenderSource(){return this.getSource()}getSourceState(){const e=this.getSource();return e?e.getState():"undefined"}handleSourceChange_(){this.changed(),!this.sourceReady_&&this.getSource().getState()==="ready"&&(this.sourceReady_=!0,this.dispatchEvent("sourceready"))}handleSourcePropertyChange_(){this.sourceChangeKey_&&(Le(this.sourceChangeKey_),this.sourceChangeKey_=null),this.sourceReady_=!1;const e=this.getSource();e&&(this.sourceChangeKey_=we(e,Be,this.handleSourceChange_,this),e.getState()==="ready"&&(this.sourceReady_=!0,setTimeout(()=>{this.dispatchEvent("sourceready")},0))),this.changed()}getFeatures(e){return this.renderer_?this.renderer_.getFeatures(e):Promise.resolve([])}getData(e){return this.renderer_&&this.rendered?this.renderer_.getData(e):null}isVisible(e){let t;const n=this.getMapInternal();let i;!e&&n&&(e=n.getView()),t=e instanceof cn?{viewState:e.getState(),extent:e.calculateExtent()}:e,!t.layerStatesArray&&n&&(t.layerStatesArray=n.getLayerGroup().getLayerStatesArray()),i=t.layerStatesArray?t.layerStatesArray.find(s=>s.layer===this):this.getLayerState();const r=this.getExtent();return Kc(i,t.viewState)&&(!r||Es(r,t.extent))}getAttributions(e){var t;if(!this.isVisible(e))return[];const n=(t=this.getSource())==null?void 0:t.getAttributions();if(!n)return[];let i=n(e instanceof cn?e.getViewStateAndExtent():e);return Array.isArray(i)||(i=[i]),i}render(e,t){const n=this.getRenderer();return n.prepareFrame(e)?(this.rendered=!0,n.renderFrame(e,t)):null}unrender(){this.rendered=!1}getDeclutter(){}renderDeclutter(e,t){}renderDeferred(e){const t=this.getRenderer();t&&t.renderDeferred(e)}setMapInternal(e){e||this.unrender(),this.set(cc,e)}getMapInternal(){return this.get(cc)}setMap(e){this.mapPrecomposeKey_&&(Le(this.mapPrecomposeKey_),this.mapPrecomposeKey_=null),e||this.changed(),this.mapRenderKey_&&(Le(this.mapRenderKey_),this.mapRenderKey_=null),e&&(this.mapPrecomposeKey_=we(e,vs,t=>{const n=t.frameState.layerStatesArray,i=this.getLayerState(!1);Ce(!n.some(function(r){return r.layer===i.layer}),"A layer can only be added to the map once. Use either `layer.setMap()` or `map.addLayer()`, not both."),n.push(i)}),this.mapRenderKey_=we(this,Be,e.render,e),this.changed())}setSource(e){this.set(ps,e)}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()}},Xg="preload",Wg="useInterimTilesOnError";let ay=class extends Kr{constructor(e){e=e||{};const t=Object.assign({},e),n=e.cacheSize;delete e.cacheSize,delete t.preload,delete t.useInterimTilesOnError,super(t),this.on,this.once,this.un,this.cacheSize_=n,this.setPreload(e.preload!==void 0?e.preload:0),this.setUseInterimTilesOnError(e.useInterimTilesOnError===void 0||e.useInterimTilesOnError)}getCacheSize(){return this.cacheSize_}getPreload(){return this.get(Xg)}setPreload(e){this.set(Xg,e)}getUseInterimTilesOnError(){return this.get(Wg)}setUseInterimTilesOnError(e){this.set(Wg,e)}getData(e){return super.getData(e)}};const Rt=0,wi=1,Ot=2,kt=3,nt=4;let Qc=class extends zr{constructor(e,t,n){super(),n=n||{},this.tileCoord=e,this.state=t,this.key="",this.transition_=n.transition===void 0?250:n.transition,this.transitionStarts_={},this.interpolate=!!n.interpolate}changed(){this.dispatchEvent(Be)}release(){this.state===kt&&this.setState(nt)}getKey(){return this.key+"/"+this.tileCoord}getTileCoord(){return this.tileCoord}getState(){return this.state}setState(e){if(this.state!==kt&&this.state>e)throw new Error("Tile load sequence violation");this.state=e,this.changed()}load(){ue()}getAlpha(e,t){if(!this.transition_)return 1;let n=this.transitionStarts_[e];if(n){if(n===-1)return 1}else n=t,this.transitionStarts_[e]=n;const i=t-n+1e3/60;return i>=this.transition_?1:Sg(i/this.transition_)}inTransition(e){return!!this.transition_&&this.transitionStarts_[e]!==-1}endTransition(e){this.transition_&&(this.transitionStarts_[e]=-1)}};const Wn=typeof navigator<"u"&&typeof navigator.userAgent<"u"?navigator.userAgent.toLowerCase():"",ly=Wn.includes("firefox"),cy=Wn.includes("safari")&&!Wn.includes("chrom")&&(Wn.includes("version/15.4")||/cpu (os|iphone os) 15_4 like mac os x/.test(Wn)),uy=Wn.includes("webkit")&&!Wn.includes("edge"),Yg=Wn.includes("macintosh"),Zg=typeof devicePixelRatio<"u"?devicePixelRatio:1,hy=typeof WorkerGlobalScope<"u"&&typeof OffscreenCanvas<"u"&&self instanceof WorkerGlobalScope,Hg=typeof Image<"u"&&Image.prototype.decode,Kg=function(){let e=!1;try{const t=Object.defineProperty({},"passive",{get:function(){e=!0}});window.addEventListener("_",null,t),window.removeEventListener("_",null,t)}catch{}return e}();function Pt(e,t,n,i){let r;return r=n&&n.length?n.shift():hy?new OffscreenCanvas(e||300,t||300):document.createElement("canvas"),e&&(r.width=e),t&&(r.height=t),r.getContext("2d",i)}let Jc;function Qg(){return Jc||(Jc=Pt(1,1)),Jc}function Qr(e){const t=e.canvas;t.width=1,t.height=1,e.clearRect(0,0,1,1)}function dy(e){let t=e.offsetWidth;const n=getComputedStyle(e);return t+=parseInt(n.marginLeft,10)+parseInt(n.marginRight,10),t}function py(e){let t=e.offsetHeight;const n=getComputedStyle(e);return t+=parseInt(n.marginTop,10)+parseInt(n.marginBottom,10),t}function Jg(e,t){const n=t.parentNode;n&&n.replaceChild(e,t)}function ef(e){for(;e.lastChild;)e.lastChild.remove()}function Fs(e){return e instanceof Image||e instanceof HTMLCanvasElement||e instanceof HTMLVideoElement||e instanceof ImageBitmap?e:null}function eu(e){return e instanceof Uint8Array||e instanceof Uint8ClampedArray||e instanceof Float32Array||e instanceof DataView?e:null}const gy=new Error("disposed");let Ji=null;const fy=[256,256];let tf=class extends Qc{constructor(e){const t=Rt;super(e.tileCoord,t,{transition:e.transition,interpolate:e.interpolate}),this.loader_=e.loader,this.data_=null,this.error_=null,this.size_=e.size||null,this.controller_=e.controller||null}getSize(){if(this.size_)return this.size_;const e=Fs(this.data_);return e?[e.width,e.height]:fy}getData(){return this.data_}getError(){return this.error_}load(){if(this.state!==Rt&&this.state!==kt)return;this.state=wi,this.changed();const e=this;this.loader_().then(function(t){e.data_=t,e.state=Ot,e.changed()}).catch(function(t){e.error_=t,e.state=kt,e.changed()})}disposeInternal(){this.controller_&&(this.controller_.abort(gy),this.controller_=null),super.disposeInternal()}},tu,nf=class{constructor(e,t,n,i,r,s){this.sourceProj_=e,this.targetProj_=t;let o={};const a=Ki(this.targetProj_,this.sourceProj_);this.transformInv_=function(x){const w=x[0]+"/"+x[1];return o[w]||(o[w]=a(x)),o[w]},this.maxSourceExtent_=i,this.errorThresholdSquared_=r*r,this.triangles_=[],this.wrapsXInSource_=!1,this.canWrapXInSource_=this.sourceProj_.canWrapX()&&!!i&&!!this.sourceProj_.getExtent()&&ze(i)>=ze(this.sourceProj_.getExtent()),this.sourceWorldWidth_=this.sourceProj_.getExtent()?ze(this.sourceProj_.getExtent()):null,this.targetWorldWidth_=this.targetProj_.getExtent()?ze(this.targetProj_.getExtent()):null;const l=Xr(n),c=Tc(n),u=Ac(n),h=Cc(n),p=this.transformInv_(l),f=this.transformInv_(c),m=this.transformInv_(u),_=this.transformInv_(h),y=10+(s?Math.max(0,Math.ceil(Math.log2(qr(n)/(s*s*256*256)))):0);if(this.addQuad_(l,c,u,h,p,f,m,_,y),this.wrapsXInSource_){let x=1/0;this.triangles_.forEach(function(w,T,R){x=Math.min(x,w.source[0][0],w.source[1][0],w.source[2][0])}),this.triangles_.forEach(w=>{if(Math.max(w.source[0][0],w.source[1][0],w.source[2][0])-x>this.sourceWorldWidth_/2){const T=[[w.source[0][0],w.source[0][1]],[w.source[1][0],w.source[1][1]],[w.source[2][0],w.source[2][1]]];T[0][0]-x>this.sourceWorldWidth_/2&&(T[0][0]-=this.sourceWorldWidth_),T[1][0]-x>this.sourceWorldWidth_/2&&(T[1][0]-=this.sourceWorldWidth_),T[2][0]-x>this.sourceWorldWidth_/2&&(T[2][0]-=this.sourceWorldWidth_);const R=Math.min(T[0][0],T[1][0],T[2][0]);Math.max(T[0][0],T[1][0],T[2][0])-R<this.sourceWorldWidth_/2&&(w.source=T)}})}o={}}addTriangle_(e,t,n,i,r,s){this.triangles_.push({source:[i,r,s],target:[e,t,n]})}addQuad_(e,t,n,i,r,s,o,a,l){const c=xc([r,s,o,a]),u=this.sourceWorldWidth_?ze(c)/this.sourceWorldWidth_:null,h=this.sourceWorldWidth_,p=this.sourceProj_.canWrapX()&&u>.5&&u<1;let f=!1;if(l>0&&(this.targetProj_.isGlobal()&&this.targetWorldWidth_&&(f=ze(xc([e,t,n,i]))/this.targetWorldWidth_>.25||f),!p&&this.sourceProj_.isGlobal()&&u&&(f=u>.25||f)),!f&&this.maxSourceExtent_&&isFinite(c[0])&&isFinite(c[1])&&isFinite(c[2])&&isFinite(c[3])&&!Es(c,this.maxSourceExtent_))return;let m=0;if(!(f||isFinite(r[0])&&isFinite(r[1])&&isFinite(s[0])&&isFinite(s[1])&&isFinite(o[0])&&isFinite(o[1])&&isFinite(a[0])&&isFinite(a[1]))){if(l>0)f=!0;else if(m=(isFinite(r[0])&&isFinite(r[1])?0:8)+(isFinite(s[0])&&isFinite(s[1])?0:4)+(isFinite(o[0])&&isFinite(o[1])?0:2)+(isFinite(a[0])&&isFinite(a[1])?0:1),m!=1&&m!=2&&m!=4&&m!=8)return}if(l>0){if(!f){const _=[(e[0]+n[0])/2,(e[1]+n[1])/2],y=this.transformInv_(_);let x;x=p?($i(r[0],h)+$i(o[0],h))/2-$i(y[0],h):(r[0]+o[0])/2-y[0];const w=(r[1]+o[1])/2-y[1];f=x*x+w*w>this.errorThresholdSquared_}if(f){if(Math.abs(e[0]-n[0])<=Math.abs(e[1]-n[1])){const _=[(t[0]+n[0])/2,(t[1]+n[1])/2],y=this.transformInv_(_),x=[(i[0]+e[0])/2,(i[1]+e[1])/2],w=this.transformInv_(x);this.addQuad_(e,t,_,x,r,s,y,w,l-1),this.addQuad_(x,_,n,i,w,y,o,a,l-1)}else{const _=[(e[0]+t[0])/2,(e[1]+t[1])/2],y=this.transformInv_(_),x=[(n[0]+i[0])/2,(n[1]+i[1])/2],w=this.transformInv_(x);this.addQuad_(e,_,x,i,r,y,w,a,l-1),this.addQuad_(_,t,n,x,y,s,o,w,l-1)}return}}if(p){if(!this.canWrapXInSource_)return;this.wrapsXInSource_=!0}11&m||this.addTriangle_(e,n,i,r,o,a),14&m||this.addTriangle_(e,n,t,r,o,s),m&&(13&m||this.addTriangle_(t,i,e,s,a,r),7&m||this.addTriangle_(t,i,n,s,a,o))}calculateSourceExtent(){const e=[1/0,1/0,-1/0,-1/0];return this.triangles_.forEach(function(t,n,i){const r=t.source;ws(e,r[0]),ws(e,r[1]),ws(e,r[2])}),e}getTriangles(){return this.triangles_}};const Sn=[];function rf(e,t,n,i,r){e.beginPath(),e.moveTo(0,0),e.lineTo(t,n),e.lineTo(i,r),e.closePath(),e.save(),e.clip(),e.fillRect(0,0,Math.max(t,i)+1,Math.max(n,r)),e.restore()}function nu(e,t){return Math.abs(e[4*t]-210)>2||Math.abs(e[4*t+3]-191.25)>2}function of(e,t,n,i){const r=bg(n,t,e);let s=_g(t,i,n);const o=t.getMetersPerUnit();o!==void 0&&(s*=o);const a=e.getMetersPerUnit();a!==void 0&&(s/=a);const l=e.getExtent();if(!l||bs(l,r)){const c=_g(e,s,r)/s;isFinite(c)&&c>0&&(s/=c)}return s}function sf(e,t,n,i){const r=Xn(n);let s=of(e,t,r,i);return(!isFinite(s)||s<=0)&&pg(n,function(o){return s=of(e,t,o,i),isFinite(s)&&s>0}),s}function af(e,t,n,i,r,s,o,a,l,c,u,h,p,f){const m=Pt(Math.round(n*e),Math.round(n*t),Sn);if(h||(m.imageSmoothingEnabled=!1),l.length===0)return m.canvas;function _(b){return Math.round(b*n)/n}m.scale(n,n),m.globalCompositeOperation="lighter";const y=[1/0,1/0,-1/0,-1/0];let x;l.forEach(function(b,k,F){hg(y,b.extent)});const w=n/i,T=(h?1:1+Math.pow(2,-24))/w;if(!p||l.length!==1||c!==0){if(x=Pt(Math.round(ze(y)*w),Math.round(Tt(y)*w),Sn),h||(x.imageSmoothingEnabled=!1),r&&f){const b=(r[0]-y[0])*w,k=-(r[3]-y[3])*w,F=ze(r)*w,j=Tt(r)*w;x.rect(b,k,F,j),x.clip()}l.forEach(function(b,k,F){if(b.image.width>0&&b.image.height>0){if(b.clipExtent){x.save();const ee=(b.clipExtent[0]-y[0])*w,ne=-(b.clipExtent[3]-y[3])*w,G=ze(b.clipExtent)*w,V=Tt(b.clipExtent)*w;x.rect(h?ee:Math.round(ee),h?ne:Math.round(ne),h?G:Math.round(ee+G)-Math.round(ee),h?V:Math.round(ne+V)-Math.round(ne)),x.clip()}const j=(b.extent[0]-y[0])*w,B=-(b.extent[3]-y[3])*w,N=ze(b.extent)*w,Y=Tt(b.extent)*w;x.drawImage(b.image,c,c,b.image.width-2*c,b.image.height-2*c,h?j:Math.round(j),h?B:Math.round(B),h?N:Math.round(j+N)-Math.round(j),h?Y:Math.round(B+Y)-Math.round(B)),b.clipExtent&&x.restore()}})}const R=Xr(o);return a.getTriangles().forEach(function(b,k,F){const j=b.source,B=b.target;let N=j[0][0],Y=j[0][1],ee=j[1][0],ne=j[1][1],G=j[2][0],V=j[2][1];const q=_((B[0][0]-R[0])/s),W=_(-(B[0][1]-R[1])/s),se=_((B[1][0]-R[0])/s),he=_(-(B[1][1]-R[1])/s),Ie=_((B[2][0]-R[0])/s),Fe=_(-(B[2][1]-R[1])/s),$t=N,fn=Y;N=0,Y=0,ee-=$t,ne-=fn,G-=$t,V-=fn;const mn=function(fe){const Ve=fe.length;for(let _e=0;_e<Ve;_e++){let mt=_e,ut=Math.abs(fe[_e][_e]);for(let M=_e+1;M<Ve;M++){const U=Math.abs(fe[M][_e]);U>ut&&(ut=U,mt=M)}if(ut===0)return null;const P=fe[mt];fe[mt]=fe[_e],fe[_e]=P;for(let M=_e+1;M<Ve;M++){const U=-fe[M][_e]/fe[_e][_e];for(let X=_e;X<Ve+1;X++)_e==X?fe[M][X]=0:fe[M][X]+=U*fe[_e][X]}}const Ut=new Array(Ve);for(let _e=Ve-1;_e>=0;_e--){Ut[_e]=fe[_e][Ve]/fe[_e][_e];for(let mt=_e-1;mt>=0;mt--)fe[mt][Ve]-=fe[mt][_e]*Ut[_e]}return Ut}([[ee,ne,0,0,se-q],[G,V,0,0,Ie-q],[0,0,ee,ne,he-W],[0,0,G,V,Fe-W]]);if(!mn)return;if(m.save(),m.beginPath(),function(){if(tu===void 0){const fe=Pt(6,6,Sn);fe.globalCompositeOperation="lighter",fe.fillStyle="rgba(210, 0, 0, 0.75)",rf(fe,4,5,4,0),rf(fe,4,5,0,5);const Ve=fe.getImageData(0,0,3,3).data;tu=nu(Ve,0)||nu(Ve,4)||nu(Ve,8),Qr(fe),Sn.push(fe.canvas)}return tu}()||!h){m.moveTo(se,he);const fe=4,Ve=q-se,Ut=W-he;for(let _e=0;_e<fe;_e++)m.lineTo(se+_((_e+1)*Ve/fe),he+_(_e*Ut/(fe-1))),_e!=fe-1&&m.lineTo(se+_((_e+1)*Ve/fe),he+_((_e+1)*Ut/(fe-1)));m.lineTo(Ie,Fe)}else m.moveTo(se,he),m.lineTo(q,W),m.lineTo(Ie,Fe);let ot;if(m.clip(),m.transform(mn[0],mn[2],mn[1],mn[3],q,W),m.translate(y[0]-$t,y[3]-fn),x)ot=x.canvas,m.scale(T,-T);else{const fe=l[0],Ve=fe.extent;ot=fe.image,m.scale(ze(Ve)/ot.width,-Tt(Ve)/ot.height)}m.drawImage(ot,0,0),m.restore()}),x&&(Qr(x),Sn.push(x.canvas)),u&&(m.save(),m.globalCompositeOperation="source-over",m.strokeStyle="black",m.lineWidth=1,a.getTriangles().forEach(function(b,k,F){const j=b.target,B=(j[0][0]-R[0])/s,N=-(j[0][1]-R[1])/s,Y=(j[1][0]-R[0])/s,ee=-(j[1][1]-R[1])/s,ne=(j[2][0]-R[0])/s,G=-(j[2][1]-R[1])/s;m.beginPath(),m.moveTo(Y,ee),m.lineTo(B,N),m.lineTo(ne,G),m.closePath(),m.stroke()}),m.restore()),m.canvas}class lf extends tf{constructor(t){super({tileCoord:t.tileCoord,loader:()=>Promise.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 n=t.sourceProj,i=n.getExtent(),r=t.sourceTileGrid.getExtent();this.clipExtent_=n.canWrapX()?r?Vt(i,r):i:r;const s=this.targetTileGrid_.getTileCoordExtent(this.wrappedTileCoord_),o=this.targetTileGrid_.getExtent();let a=this.sourceTileGrid_.getExtent();const l=o?Vt(s,o):s;if(qr(l)===0)return void(this.state=nt);i&&(a=a?Vt(a,i):i);const c=this.targetTileGrid_.getResolution(this.wrappedTileCoord_[0]),u=t.targetProj,h=sf(n,u,l,c);if(!isFinite(h)||h<=0)return void(this.state=nt);const p=t.errorThreshold!==void 0?t.errorThreshold:.5;if(this.triangulation_=new nf(n,u,l,a,h*p,c),this.triangulation_.getTriangles().length===0)return void(this.state=nt);this.sourceZ_=this.sourceTileGrid_.getZForResolution(h);let f=this.triangulation_.calculateSourceExtent();if(a&&(n.canWrapX()?(f[1]=Ze(f[1],a[1],a[3]),f[3]=Ze(f[3],a[1],a[3])):f=Vt(f,a)),qr(f)){let m=0,_=0;n.canWrapX()&&(m=ze(i),_=Math.floor((f[0]-i[0])/m)),Rc(f.slice(),n,!0).forEach(y=>{const x=this.sourceTileGrid_.getTileRangeForExtentAndZ(y,this.sourceZ_),w=t.getTileFunction;for(let T=x.minX;T<=x.maxX;T++)for(let R=x.minY;R<=x.maxY;R++){const b=w(this.sourceZ_,T,R,this.pixelRatio_);if(b){const k=_*m;this.sourceTiles_.push({tile:b,offset:k})}}++_}),this.sourceTiles_.length===0&&(this.state=nt)}else this.state=nt}getSize(){return this.reprojSize_}getData(){return this.reprojData_}getError(){return this.reprojError_}reproject_(){const t=[];let n=!1;if(this.sourceTiles_.forEach(f=>{var m;const _=f.tile;if(!_||_.getState()!==Ot)return;const y=_.getSize(),x=this.gutter_;let w;const T=eu(_.getData());T?w=T:(n=!0,w=function(W){Ji||(Ji=Pt(W.width,W.height,void 0,{willReadFrequently:!0}));const se=Ji.canvas,he=W.width;se.width!==he&&(se.width=he);const Ie=W.height;return se.height!==Ie&&(se.height=Ie),Ji.clearRect(0,0,he,Ie),Ji.drawImage(W,0,0),Ji.getImageData(0,0,he,Ie).data}(Fs(_.getData())));const R=[y[0]+2*x,y[1]+2*x],b=w instanceof Float32Array,k=R[0]*R[1],F=b?Float32Array:Uint8ClampedArray,j=new F(w.buffer),B=F.BYTES_PER_ELEMENT,N=B*j.length/k,Y=j.byteLength/R[1],ee=Math.floor(Y/B/R[0]),ne=k*ee;let G=j;if(j.length!==ne){G=new F(ne);let W=0,se=0;const he=R[0]*ee;for(let Ie=0;Ie<R[1];++Ie){for(let Fe=0;Fe<he;++Fe)G[W++]=j[se+Fe];se+=Y/B}}const V=this.sourceTileGrid_.getTileCoordExtent(_.tileCoord);V[0]+=f.offset,V[2]+=f.offset;const q=(m=this.clipExtent_)==null?void 0:m.slice();q&&(q[0]+=f.offset,q[2]+=f.offset),t.push({extent:V,clipExtent:q,data:new Uint8ClampedArray(G.buffer),dataType:F,bytesPerPixel:N,pixelSize:R})}),this.sourceTiles_.length=0,t.length===0)return this.state=kt,void this.changed();const i=this.wrappedTileCoord_[0],r=this.targetTileGrid_.getTileSize(i),s=typeof r=="number"?r:r[0],o=typeof r=="number"?r:r[1],a=this.targetTileGrid_.getResolution(i),l=this.sourceTileGrid_.getResolution(this.sourceZ_),c=this.targetTileGrid_.getTileCoordExtent(this.wrappedTileCoord_);let u,h;const p=t[0].bytesPerPixel;for(let f=Math.ceil(p/3)-1;f>=0;--f){const m=[];for(let R=0,b=t.length;R<b;++R){const k=t[R],F=k.data,j=k.pixelSize,B=j[0],N=j[1],Y=Pt(B,N,Sn),ee=Y.createImageData(B,N),ne=ee.data;let G=3*f;for(let V=0,q=ne.length;V<q;V+=4)ne[V]=F[G],ne[V+1]=F[G+1],ne[V+2]=F[G+2],ne[V+3]=255,G+=p;Y.putImageData(ee,0,0),m.push({extent:k.extent,clipExtent:k.clipExtent,image:Y.canvas})}const _=af(s,o,this.pixelRatio_,l,this.sourceTileGrid_.getExtent(),a,c,this.triangulation_,m,this.gutter_,!1,!1,!1);for(let R=0,b=m.length;R<b;++R){const k=m[R].image.getContext("2d");Qr(k),Sn.push(k.canvas)}const y=_.getContext("2d"),x=y.getImageData(0,0,_.width,_.height);Qr(y),Sn.push(_),u||(h=new Uint8ClampedArray(p*x.width*x.height),u=new t[0].dataType(h.buffer));const w=x.data;let T=3*f;for(let R=0,b=w.length;R<b;R+=4)w[R+3]===255?(h[T]=w[R],h[T+1]=w[R+1],h[T+2]=w[R+2]):(h[T]=0,h[T+1]=0,h[T+2]=0),T+=p}if(n){const f=Pt(s,o),m=new ImageData(u,s);f.putImageData(m,0,0),this.reprojData_=f.canvas}else this.reprojData_=u;this.reprojSize_=[Math.round(s*this.pixelRatio_),Math.round(o*this.pixelRatio_)],this.state=Ot,this.changed()}load(){if(this.state!==Rt&&this.state!==kt)return;this.state=wi,this.changed();let t=0;this.sourcesListenerKeys_=[],this.sourceTiles_.forEach(({tile:n})=>{const i=n.getState();if(i!==Rt&&i!==wi)return;t++;const r=we(n,Be,()=>{const s=n.getState();(s==Ot||s==kt||s==nt)&&(Le(r),t--,t===0&&(this.unlistenSources_(),this.reproject_()))});this.sourcesListenerKeys_.push(r)}),t===0?setTimeout(this.reproject_.bind(this),0):this.sourceTiles_.forEach(function({tile:n}){n.getState()==Rt&&n.load()})}unlistenSources_(){this.sourcesListenerKeys_.forEach(Le),this.sourcesListenerKeys_=null}}class Os extends Qc{constructor(t,n,i,r,s,o,a,l,c,u,h,p){super(s,Rt,p),this.renderEdges_=h!==void 0&&h,this.pixelRatio_=a,this.gutter_=l,this.canvas_=null,this.sourceTileGrid_=n,this.targetTileGrid_=r,this.wrappedTileCoord_=o||s,this.sourceTiles_=[],this.sourcesListenerKeys_=null,this.sourceZ_=0,this.clipExtent_=t.canWrapX()?t.getExtent():void 0;const f=r.getTileCoordExtent(this.wrappedTileCoord_),m=this.targetTileGrid_.getExtent();let _=this.sourceTileGrid_.getExtent();const y=m?Vt(f,m):f;if(qr(y)===0)return void(this.state=nt);const x=t.getExtent();x&&(_=_?Vt(_,x):x);const w=r.getResolution(this.wrappedTileCoord_[0]),T=sf(t,i,y,w);if(!isFinite(T)||T<=0)return void(this.state=nt);const R=u!==void 0?u:.5;if(this.triangulation_=new nf(t,i,y,_,T*R,w),this.triangulation_.getTriangles().length===0)return void(this.state=nt);this.sourceZ_=n.getZForResolution(T);let b=this.triangulation_.calculateSourceExtent();if(_&&(t.canWrapX()?(b[1]=Ze(b[1],_[1],_[3]),b[3]=Ze(b[3],_[1],_[3])):b=Vt(b,_)),qr(b)){let k=0,F=0;t.canWrapX()&&(k=ze(x),F=Math.floor((b[0]-x[0])/k)),Rc(b.slice(),t,!0).forEach(j=>{const B=n.getTileRangeForExtentAndZ(j,this.sourceZ_);for(let N=B.minX;N<=B.maxX;N++)for(let Y=B.minY;Y<=B.maxY;Y++){const ee=c(this.sourceZ_,N,Y,a);if(ee){const ne=F*k;this.sourceTiles_.push({tile:ee,offset:ne})}}++F}),this.sourceTiles_.length===0&&(this.state=nt)}else this.state=nt}getImage(){return this.canvas_}reproject_(){const t=[];if(this.sourceTiles_.forEach(n=>{var i;const r=n.tile;if(r&&r.getState()==Ot){const s=this.sourceTileGrid_.getTileCoordExtent(r.tileCoord);s[0]+=n.offset,s[2]+=n.offset;const o=(i=this.clipExtent_)==null?void 0:i.slice();o&&(o[0]+=n.offset,o[2]+=n.offset),t.push({extent:s,clipExtent:o,image:r.getImage()})}}),this.sourceTiles_.length=0,t.length===0)this.state=kt;else{const n=this.wrappedTileCoord_[0],i=this.targetTileGrid_.getTileSize(n),r=typeof i=="number"?i:i[0],s=typeof i=="number"?i:i[1],o=this.targetTileGrid_.getResolution(n),a=this.sourceTileGrid_.getResolution(this.sourceZ_),l=this.targetTileGrid_.getTileCoordExtent(this.wrappedTileCoord_);this.canvas_=af(r,s,this.pixelRatio_,a,this.sourceTileGrid_.getExtent(),o,l,this.triangulation_,t,this.gutter_,this.renderEdges_,this.interpolate),this.state=Ot}this.changed()}load(){if(this.state==Rt){this.state=wi,this.changed();let t=0;this.sourcesListenerKeys_=[],this.sourceTiles_.forEach(({tile:n})=>{const i=n.getState();if(i==Rt||i==wi){t++;const r=we(n,Be,s=>{const o=n.getState();(o==Ot||o==kt||o==nt)&&(Le(r),t--,t===0&&(this.unlistenSources_(),this.reproject_()))});this.sourcesListenerKeys_.push(r)}}),t===0?setTimeout(this.reproject_.bind(this),0):this.sourceTiles_.forEach(function({tile:n},i,r){n.getState()==Rt&&n.load()})}}unlistenSources_(){this.sourcesListenerKeys_.forEach(Le),this.sourcesListenerKeys_=null}release(){this.canvas_&&(Qr(this.canvas_.getContext("2d")),Sn.push(this.canvas_),this.canvas_=null),super.release()}}function my(e,t){return t&&(e.src=t),e.src&&Hg?new Promise((n,i)=>e.decode().then(()=>n(e)).catch(r=>e.complete&&e.width?n(e):i(r))):function(n){return new Promise((i,r)=>{function s(){a(),i(n)}function o(){a(),r(new Error("Image load error"))}function a(){n.removeEventListener("load",s),n.removeEventListener("error",o)}n.addEventListener("load",s),n.addEventListener("error",o)})}(e)}let iu=class extends Qc{constructor(e,t,n,i,r,s){super(e,t,s),this.crossOrigin_=i,this.src_=n,this.key=n,this.image_=new Image,i!==null&&(this.image_.crossOrigin=i),this.unlisten_=null,this.tileLoadFunction_=r}getImage(){return this.image_}setImage(e){this.image_=e,this.state=Ot,this.unlistenImage_(),this.changed()}handleImageError_(){this.state=kt,this.unlistenImage_(),this.image_=function(){const e=Pt(1,1);return e.fillStyle="rgba(0,0,0,0)",e.fillRect(0,0,1,1),e.canvas}(),this.changed()}handleImageLoad_(){const e=this.image_;e.naturalWidth&&e.naturalHeight?this.state=Ot:this.state=nt,this.unlistenImage_(),this.changed()}load(){this.state==kt&&(this.state=Rt,this.image_=new Image,this.crossOrigin_!==null&&(this.image_.crossOrigin=this.crossOrigin_)),this.state==Rt&&(this.state=wi,this.changed(),this.tileLoadFunction_(this,this.src_),this.unlisten_=function(e,t,n){const i=e;let r=!0,s=!1,o=!1;const a=[hs(i,z_,function(){o=!0,s||t()})];return i.src&&Hg?(s=!0,i.decode().then(function(){r&&t()}).catch(function(l){r&&(o?t():n())})):a.push(hs(i,U_,n)),function(){r=!1,a.forEach(Le)}}(this.image_,this.handleImageLoad_.bind(this),this.handleImageError_.bind(this)))}unlistenImage_(){this.unlisten_&&(this.unlisten_(),this.unlisten_=null)}},vy=class extends zr{constructor(e){super(),this.tile,this.handleTileChange_=this.handleTileChange_.bind(this),this.gutter=e.gutter||0,this.helper=e.helper,this.loaded=!1,this.ready=!1}setTile(e){if(e!==this.tile)if(this.tile&&this.tile.removeEventListener(Be,this.handleTileChange_),this.tile=e,this.loaded=e.getState()===Ot,this.loaded)this.uploadTile();else{if(e instanceof iu){const t=e.getImage();t instanceof Image&&!t.crossOrigin&&(t.crossOrigin="anonymous")}e.addEventListener(Be,this.handleTileChange_)}}uploadTile(){ue()}setReady(){this.ready=!0,this.dispatchEvent(Be)}handleTileChange_(){this.tile.getState()===Ot&&(this.loaded=!0,this.uploadTile())}disposeInternal(){this.tile.removeEventListener(Be,this.handleTileChange_)}};const Ds=34962,Us=34963,ru=35044,cf=35048,uf=["experimental-webgl","webgl","webkit-3d","moz-webgl"];function _y(e,t){t=Object.assign({preserveDrawingBuffer:!0,antialias:!cy},t);const n=uf.length;for(let i=0;i<n;++i)try{const r=e.getContext(uf[i],t);if(r)return r}catch{}return null}const yy=ru;let Bs=class{constructor(e,t){this.array_=null,this.type_=e,Ce(e===Ds||e===Us,"A `WebGLArrayBuffer` must either be of type `ELEMENT_ARRAY_BUFFER` or `ARRAY_BUFFER`"),this.usage_=t!==void 0?t:yy}ofSize(e){return this.array_=new(ou(this.type_))(e),this}fromArray(e){return this.array_=ou(this.type_).from(e),this}fromArrayBuffer(e){return this.array_=new(ou(this.type_))(e),this}getType(){return this.type_}getArray(){return this.array_}getUsage(){return this.usage_}getSize(){return this.array_?this.array_.length:0}};function ou(e){switch(e){case Ds:return Float32Array;case Us:return Uint32Array;default:return Float32Array}}function hf(e){return e[0]>0&&e[1]>0}function lt(e,t){return Array.isArray(e)?e:(t===void 0?t=[e,e]:(t[0]=e,t[1]=e),t)}function df(e,t,n){const i=n?e.LINEAR:e.NEAREST;e.bindTexture(e.TEXTURE_2D,t),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.texParameteri(e.TEXTURE_2D,e.TEXTURE_MIN_FILTER,i),e.texParameteri(e.TEXTURE_2D,e.TEXTURE_MAG_FILTER,i)}function pf(e,t,n,i,r,s){const o=e.getGL();let a,l;n instanceof Float32Array?(a=o.FLOAT,e.getExtension("OES_texture_float"),l=e.getExtension("OES_texture_float_linear")!==null):(a=o.UNSIGNED_BYTE,l=!0),df(o,t,s&&l);const c=n.byteLength/i[1];let u,h=1;switch(c%8==0?h=8:c%4==0?h=4:c%2==0&&(h=2),r){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: ${r}`)}const p=o.getParameter(o.UNPACK_ALIGNMENT);o.pixelStorei(o.UNPACK_ALIGNMENT,h),o.texImage2D(o.TEXTURE_2D,0,u,i[0],i[1],0,u,a,n),o.pixelStorei(o.UNPACK_ALIGNMENT,p)}let er=null,by=class extends vy{constructor(e){super(e),this.textures=[],this.renderSize_=lt(e.grid.getTileSize(e.tile.tileCoord[0])),this.bandCount=NaN;const t=new Bs(Ds,ru);t.fromArray([0,1,1,1,1,0,0,0]),this.helper.flushBufferData(t),this.coords=t,this.setTile(e.tile)}uploadTile(){const e=this.helper,t=e.getGL(),n=this.tile;let i;this.textures.length=0,i=n instanceof iu||n instanceof Os?n.getImage():n.getData();const r=Fs(i);if(r){const x=t.createTexture();return this.textures.push(x),this.bandCount=4,function(w,T,R,b){df(w,T,b),w.texImage2D(w.TEXTURE_2D,0,w.RGBA,w.RGBA,w.UNSIGNED_BYTE,R)}(t,x,r,n.interpolate),void this.setReady()}i=eu(i);const s=n.getSize(),o=[s[0]+2*this.gutter,s[1]+2*this.gutter],a=i instanceof Float32Array,l=o[0]*o[1],c=a?Float32Array:Uint8Array,u=c.BYTES_PER_ELEMENT,h=i.byteLength/o[1];this.bandCount=Math.floor(h/u/o[0]);const p=Math.ceil(this.bandCount/4);if(p===1){const x=t.createTexture();return this.textures.push(x),pf(e,x,i,o,this.bandCount,n.interpolate),void this.setReady()}const f=new Array(p);for(let x=0;x<p;++x){const w=t.createTexture();this.textures.push(w);const T=x<p-1?4:(this.bandCount-1)%4+1;f[x]=new c(l*T)}let m=0,_=0;const y=o[0]*this.bandCount;for(let x=0;x<o[1];++x){for(let w=0;w<y;++w){const T=i[_+w],R=Math.floor(m/this.bandCount),b=w%this.bandCount,k=f[Math.floor(b/4)];k[R*(k.length/l)+b%4]=T,++m}_+=h/u}for(let x=0;x<p;++x){const w=this.textures[x],T=f[x];pf(e,w,T,o,T.length/l,n.interpolate)}this.setReady()}disposeInternal(){const e=this.helper.getGL();this.helper.deleteBuffer(this.coords);for(let t=0;t<this.textures.length;++t)e.deleteTexture(this.textures[t]);this.tile.removeEventListener(Be,this.handleTileChange_)}getImagePixelData_(e,t,n){const i=this.gutter,r=this.renderSize_[0],s=this.renderSize_[1];er||(er=Pt(1,1,void 0,{willReadFrequently:!0})),er.clearRect(0,0,1,1);const o=e.width-2*i,a=e.height-2*i,l=i+Math.floor(o*(t/r)),c=i+Math.floor(a*(n/s));let u;try{er.drawImage(e,l,c,1,1,0,0,1,1),u=er.getImageData(0,0,1,1).data}catch{return er=null,null}return u}getArrayPixelData_(e,t,n,i){const r=this.gutter,s=this.renderSize_[0],o=this.renderSize_[1],a=t[0],l=t[1],c=a+2*r,u=l+2*r,h=r+Math.floor(a*(n/s)),p=r+Math.floor(l*(i/o));if(e instanceof DataView){const m=e.byteLength/(c*u),_=m*(p*c+h),y=e.buffer.slice(_,_+m);return new DataView(y)}const f=this.bandCount*(p*c+h);return e.slice(f,f+this.bandCount)}getPixelData(e,t){if(!this.loaded)return null;if(this.tile instanceof tf){const n=this.tile.getData(),i=eu(n);if(i){const r=this.tile.getSize();return this.getArrayPixelData_(i,r,e,t)}return this.getImagePixelData_(Fs(n),e,t)}return this.getImagePixelData_(this.tile.getImage(),e,t)}},gf=class{constructor(e){this.highWaterMark=e!==void 0?e:2048,this.count_=0,this.entries_={},this.oldest_=null,this.newest_=null}canExpireCache(){return this.highWaterMark>0&&this.getCount()>this.highWaterMark}expireCache(e){for(;this.canExpireCache();)this.pop()}clear(){this.count_=0,this.entries_={},this.oldest_=null,this.newest_=null}containsKey(e){return this.entries_.hasOwnProperty(e)}forEach(e){let t=this.oldest_;for(;t;)e(t.value_,t.key_,this),t=t.newer}get(e,t){const n=this.entries_[e];return Ce(n!==void 0,"Tried to get a value for a key that does not exist in the cache"),n===this.newest_||(n===this.oldest_?(this.oldest_=this.oldest_.newer,this.oldest_.older=null):(n.newer.older=n.older,n.older.newer=n.newer),n.newer=null,n.older=this.newest_,this.newest_.newer=n,this.newest_=n),n.value_}remove(e){const t=this.entries_[e];return Ce(t!==void 0,"Tried to get a value for a key that does not exist in the cache"),t===this.newest_?(this.newest_=t.older,this.newest_&&(this.newest_.newer=null)):t===this.oldest_?(this.oldest_=t.newer,this.oldest_&&(this.oldest_.older=null)):(t.newer.older=t.older,t.older.newer=t.newer),delete this.entries_[e],--this.count_,t.value_}getCount(){return this.count_}getKeys(){const e=new Array(this.count_);let t,n=0;for(t=this.newest_;t;t=t.older)e[n++]=t.key_;return e}getValues(){const e=new Array(this.count_);let t,n=0;for(t=this.newest_;t;t=t.older)e[n++]=t.value_;return e}peekLast(){return this.oldest_.value_}peekLastKey(){return this.oldest_.key_}peekFirstKey(){return this.newest_.key_}peek(e){var t;return(t=this.entries_[e])==null?void 0:t.value_}pop(){const e=this.oldest_;return delete this.entries_[e.key_],e.newer&&(e.newer.older=null),this.oldest_=e.newer,this.oldest_||(this.newest_=null),--this.count_,e.value_}replace(e,t){this.get(e),this.entries_[e].value_=t}set(e,t){Ce(!(e in this.entries_),"Tried to set a value for a key that is used already");const n={key_:e,newer:null,older:this.newest_,value_:t};this.newest_?this.newest_.newer=n:this.oldest_=n,this.newest_=n,this.entries_[e]=n,++this.count_}setSize(e){this.highWaterMark=e}},su=class{constructor(e,t,n,i){this.minX=e,this.maxX=t,this.minY=n,this.maxY=i}contains(e){return this.containsXY(e[1],e[2])}containsTileRange(e){return this.minX<=e.minX&&e.maxX<=this.maxX&&this.minY<=e.minY&&e.maxY<=this.maxY}containsXY(e,t){return this.minX<=e&&e<=this.maxX&&this.minY<=t&&t<=this.maxY}equals(e){return this.minX==e.minX&&this.minY==e.minY&&this.maxX==e.maxX&&this.maxY==e.maxY}extend(e){e.minX<this.minX&&(this.minX=e.minX),e.maxX>this.maxX&&(this.maxX=e.maxX),e.minY<this.minY&&(this.minY=e.minY),e.maxY>this.maxY&&(this.maxY=e.maxY)}getHeight(){return this.maxY-this.minY+1}getSize(){return[this.getWidth(),this.getHeight()]}getWidth(){return this.maxX-this.minX+1}intersects(e){return this.minX<=e.maxX&&this.maxX>=e.minX&&this.minY<=e.maxY&&this.maxY>=e.minY}};function tr(e,t,n,i,r){return r!==void 0?(r.minX=e,r.maxX=t,r.minY=n,r.maxY=i,r):new su(e,t,n,i)}const Ei=0,nr=1,gt=2,Jr=3;let xy=class extends Gr{constructor(e){super(),this.ready=!0,this.boundHandleImageChange_=this.handleImageChange_.bind(this),this.layer_=e,this.staleKeys_=new Array,this.maxStaleKeys=5}getStaleKeys(){return this.staleKeys_}prependStaleKey(e){this.staleKeys_.unshift(e),this.staleKeys_.length>this.maxStaleKeys&&(this.staleKeys_.length=this.maxStaleKeys)}getFeatures(e){return ue()}getData(e){return null}prepareFrame(e){return ue()}renderFrame(e,t){return ue()}forEachFeatureAtCoordinate(e,t,n,i,r){}getLayer(){return this.layer_}handleFontsChanged(){}handleImageChange_(e){const t=e.target;(t.getState()===gt||t.getState()===Jr)&&this.renderIfReadyAndVisible()}loadImage(e){let t=e.getState();return t!=gt&&t!=Jr&&e.addEventListener(Be,this.boundHandleImageChange_),t==Ei&&(e.load(),t=e.getState()),t==gt}renderIfReadyAndVisible(){const e=this.getLayer();e&&e.getVisible()&&e.getSourceState()==="ready"&&e.changed()}renderDeferred(e){}disposeInternal(){delete this.layer_,super.disposeInternal()}},zs=class extends Cn{constructor(e,t,n,i){super(e),this.inversePixelTransform=t,this.frameState=n,this.context=i}};const ff="webglcontextlost",mf="webglcontextrestored";let vf=class{constructor(e){this.gl_=e.webGlContext;const t=this.gl_;this.scaleRatio_=e.scaleRatio||1,this.renderTargetTexture_=t.createTexture(),this.renderTargetTextureSize_=null,this.frameBuffer_=t.createFramebuffer(),this.depthBuffer_=t.createRenderbuffer();const n=t.createShader(t.VERTEX_SHADER);t.shaderSource(n,e.vertexShader||`
  precision mediump float;

  attribute vec2 a_position;
  varying vec2 v_texCoord;
  varying vec2 v_screenCoord;

  uniform vec2 u_screenSize;

  void main() {
    v_texCoord = a_position * 0.5 + 0.5;
    v_screenCoord = v_texCoord * u_screenSize;
    gl_Position = vec4(a_position, 0.0, 1.0);
  }
`),t.compileShader(n);const i=t.createShader(t.FRAGMENT_SHADER);t.shaderSource(i,e.fragmentShader||`
  precision mediump float;

  uniform sampler2D u_image;
  uniform float u_opacity;

  varying vec2 v_texCoord;

  void main() {
    gl_FragColor = texture2D(u_image, v_texCoord) * u_opacity;
  }
`),t.compileShader(i),this.renderTargetProgram_=t.createProgram(),t.attachShader(this.renderTargetProgram_,n),t.attachShader(this.renderTargetProgram_,i),t.linkProgram(this.renderTargetProgram_),this.renderTargetVerticesBuffer_=t.createBuffer(),t.bindBuffer(t.ARRAY_BUFFER,this.renderTargetVerticesBuffer_),t.bufferData(t.ARRAY_BUFFER,new Float32Array([-1,-1,1,-1,-1,1,1,-1,1,1,-1,1]),t.STATIC_DRAW),this.renderTargetAttribLocation_=t.getAttribLocation(this.renderTargetProgram_,"a_position"),this.renderTargetUniformLocation_=t.getUniformLocation(this.renderTargetProgram_,"u_screenSize"),this.renderTargetOpacityLocation_=t.getUniformLocation(this.renderTargetProgram_,"u_opacity"),this.renderTargetTextureLocation_=t.getUniformLocation(this.renderTargetProgram_,"u_image"),this.uniforms_=[],e.uniforms&&Object.keys(e.uniforms).forEach(r=>{this.uniforms_.push({value:e.uniforms[r],location:t.getUniformLocation(this.renderTargetProgram_,r)})})}getGL(){return this.gl_}init(e){const t=this.getGL(),n=[t.drawingBufferWidth*this.scaleRatio_,t.drawingBufferHeight*this.scaleRatio_];if(t.bindFramebuffer(t.FRAMEBUFFER,this.getFrameBuffer()),t.bindRenderbuffer(t.RENDERBUFFER,this.getDepthBuffer()),t.viewport(0,0,n[0],n[1]),!this.renderTargetTextureSize_||this.renderTargetTextureSize_[0]!==n[0]||this.renderTargetTextureSize_[1]!==n[1]){this.renderTargetTextureSize_=n;const i=0,r=t.RGBA,s=0,o=t.RGBA,a=t.UNSIGNED_BYTE;t.bindTexture(t.TEXTURE_2D,this.renderTargetTexture_),t.texImage2D(t.TEXTURE_2D,i,r,n[0],n[1],s,o,a,null),t.texParameteri(t.TEXTURE_2D,t.TEXTURE_MIN_FILTER,t.LINEAR),t.texParameteri(t.TEXTURE_2D,t.TEXTURE_WRAP_S,t.CLAMP_TO_EDGE),t.texParameteri(t.TEXTURE_2D,t.TEXTURE_WRAP_T,t.CLAMP_TO_EDGE),t.framebufferTexture2D(t.FRAMEBUFFER,t.COLOR_ATTACHMENT0,t.TEXTURE_2D,this.renderTargetTexture_,0),t.renderbufferStorage(t.RENDERBUFFER,t.DEPTH_COMPONENT16,n[0],n[1]),t.framebufferRenderbuffer(t.FRAMEBUFFER,t.DEPTH_ATTACHMENT,t.RENDERBUFFER,this.depthBuffer_)}}apply(e,t,n,i){const r=this.getGL(),s=e.size;if(r.bindFramebuffer(r.FRAMEBUFFER,t?t.getFrameBuffer():null),r.activeTexture(r.TEXTURE0),r.bindTexture(r.TEXTURE_2D,this.renderTargetTexture_),!t){const a=Ae(r.canvas);if(!e.renderTargets[a]){const l=r.getContextAttributes();l&&l.preserveDrawingBuffer&&(r.clearColor(0,0,0,0),r.clearDepth(1),r.clear(r.COLOR_BUFFER_BIT|r.DEPTH_BUFFER_BIT)),e.renderTargets[a]=!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_,s[0],s[1]),r.uniform1i(this.renderTargetTextureLocation_,0);const o=e.layerStatesArray[e.layerIndex].opacity;r.uniform1f(this.renderTargetOpacityLocation_,o),this.applyUniforms(e),n&&n(r,e),r.drawArrays(r.TRIANGLES,0,6),i&&i(r,e)}getFrameBuffer(){return this.frameBuffer_}getDepthBuffer(){return this.depthBuffer_}applyUniforms(e){const t=this.getGL();let n,i=1;this.uniforms_.forEach(function(r){if(n=typeof r.value=="function"?r.value(e):r.value,n instanceof HTMLCanvasElement||n instanceof ImageData)r.texture||(r.texture=t.createTexture()),t.activeTexture(t[`TEXTURE${i}`]),t.bindTexture(t.TEXTURE_2D,r.texture),t.texParameteri(t.TEXTURE_2D,t.TEXTURE_MIN_FILTER,t.LINEAR),t.texParameteri(t.TEXTURE_2D,t.TEXTURE_WRAP_S,t.CLAMP_TO_EDGE),t.texParameteri(t.TEXTURE_2D,t.TEXTURE_WRAP_T,t.CLAMP_TO_EDGE),n instanceof ImageData?t.texImage2D(t.TEXTURE_2D,0,t.RGBA,t.RGBA,n.width,n.height,0,t.UNSIGNED_BYTE,new Uint8Array(n.data)):t.texImage2D(t.TEXTURE_2D,0,t.RGBA,t.RGBA,t.UNSIGNED_BYTE,n),t.uniform1i(r.location,i++);else if(Array.isArray(n))switch(n.length){case 2:return void t.uniform2f(r.location,n[0],n[1]);case 3:return void t.uniform3f(r.location,n[0],n[1],n[2]);case 4:return void t.uniform4f(r.location,n[0],n[1],n[2],n[3]);default:return}else typeof n=="number"&&t.uniform1f(r.location,n)})}};function _f(e,t){return e[0]=t[0],e[1]=t[1],e[4]=t[2],e[5]=t[3],e[12]=t[4],e[13]=t[5],e}const wy="u_projectionMatrix",Ey="u_time",Cy="u_zoom",Ay="u_resolution",Sy="u_rotation",Ty="u_viewportSizePx",yf="u_pixelRatio",Ry="u_hitDetection",ky=5121,Py=5123,Iy=5125,ir=5126,js={};function bf(e){return"shared/"+e}let xf=0,My=class extends ss{constructor(e){super(),e=e||{},this.boundHandleWebGLContextLost_=this.handleWebGLContextLost.bind(this),this.boundHandleWebGLContextRestored_=this.handleWebGLContextRestored.bind(this),this.canvasCacheKey_=e.canvasCacheKey?bf(e.canvasCacheKey):function(){const n="unique/"+xf;return xf+=1,n}(),this.gl_=function(n){let i=js[n];if(!i){const r=document.createElement("canvas");r.width=1,r.height=1,r.style.position="absolute",r.style.left="0",i={users:0,context:_y(r)},js[n]=i}return i.users+=1,i.context}(this.canvasCacheKey_),this.bufferCache_={},this.extensionCache_={},this.currentProgram_=null,this.needsToBeRecreated_=!1;const t=this.gl_.canvas;t.addEventListener(ff,this.boundHandleWebGLContextLost_),t.addEventListener(mf,this.boundHandleWebGLContextRestored_),this.offsetRotateMatrix_=[1,0,0,1,0,0],this.offsetScaleMatrix_=[1,0,0,1,0,0],this.tmpMat4_=[1,0,0,0,0,1,0,0,0,0,1,0,0,0,0,1],this.uniformLocationsByProgram_={},this.attribLocationsByProgram_={},this.uniforms_=[],e.uniforms&&this.setUniforms(e.uniforms),this.postProcessPasses_=e.postProcesses?e.postProcesses.map(n=>new vf({webGlContext:this.gl_,scaleRatio:n.scaleRatio,vertexShader:n.vertexShader,fragmentShader:n.fragmentShader,uniforms:n.uniforms})):[new vf({webGlContext:this.gl_})],this.shaderCompileErrors_=null,this.startTime_=Date.now()}setUniforms(e){this.uniforms_=[],this.addUniforms(e)}addUniforms(e){for(const t in e)this.uniforms_.push({name:t,value:e[t]})}canvasCacheKeyMatches(e){return this.canvasCacheKey_===bf(e)}getExtension(e){if(e in this.extensionCache_)return this.extensionCache_[e];const t=this.gl_.getExtension(e);return this.extensionCache_[e]=t,t}bindBuffer(e){const t=this.gl_,n=Ae(e);let i=this.bufferCache_[n];i||(i={buffer:e,webGlBuffer:t.createBuffer()},this.bufferCache_[n]=i),t.bindBuffer(e.getType(),i.webGlBuffer)}flushBufferData(e){const t=this.gl_;this.bindBuffer(e),t.bufferData(e.getType(),e.getArray(),e.getUsage())}deleteBuffer(e){const t=this.gl_,n=Ae(e),i=this.bufferCache_[n];i&&!t.isContextLost()&&t.deleteBuffer(i.webGlBuffer),delete this.bufferCache_[n]}disposeInternal(){const e=this.gl_.canvas;e.removeEventListener(ff,this.boundHandleWebGLContextLost_),e.removeEventListener(mf,this.boundHandleWebGLContextRestored_),function(t){const n=js[t];if(!n||(n.users-=1,n.users>0))return;const i=n.context,r=i.getExtension("WEBGL_lose_context");r&&r.loseContext();const s=i.canvas;s.width=1,s.height=1,delete js[t]}(this.canvasCacheKey_),delete this.gl_}prepareDraw(e,t,n){const i=this.gl_,r=this.getCanvas(),s=e.size,o=e.pixelRatio;(r.width!==s[0]*o||r.height!==s[1]*o)&&(r.width=s[0]*o,r.height=s[1]*o,r.style.width=s[0]+"px",r.style.height=s[1]+"px");for(let a=this.postProcessPasses_.length-1;a>=0;a--)this.postProcessPasses_[a].init(e);i.bindTexture(i.TEXTURE_2D,null),i.clearColor(0,0,0,0),i.depthRange(0,1),i.clearDepth(1),i.clear(i.COLOR_BUFFER_BIT|i.DEPTH_BUFFER_BIT),i.enable(i.BLEND),i.blendFunc(i.ONE,t?i.ZERO:i.ONE_MINUS_SRC_ALPHA),n?(i.enable(i.DEPTH_TEST),i.depthFunc(i.LEQUAL)):i.disable(i.DEPTH_TEST)}bindTexture(e,t,n){const i=this.gl_;i.activeTexture(i.TEXTURE0+t),i.bindTexture(i.TEXTURE_2D,e),i.uniform1i(this.getUniformLocation(n),t)}prepareDrawToRenderTarget(e,t,n,i){const r=this.gl_,s=t.getSize();r.bindFramebuffer(r.FRAMEBUFFER,t.getFramebuffer()),r.bindRenderbuffer(r.RENDERBUFFER,t.getDepthbuffer()),r.viewport(0,0,s[0],s[1]),r.bindTexture(r.TEXTURE_2D,t.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,n?r.ZERO:r.ONE_MINUS_SRC_ALPHA),i?(r.enable(r.DEPTH_TEST),r.depthFunc(r.LEQUAL)):r.disable(r.DEPTH_TEST)}drawElements(e,t){const n=this.gl_;this.getExtension("OES_element_index_uint");const i=n.UNSIGNED_INT,r=t-e,s=4*e;n.drawElements(n.TRIANGLES,r,i,s)}finalizeDraw(e,t,n){for(let i=0,r=this.postProcessPasses_.length;i<r;i++)i===r-1?this.postProcessPasses_[i].apply(e,null,t,n):this.postProcessPasses_[i].apply(e,this.postProcessPasses_[i+1])}getCanvas(){return this.gl_.canvas}getGL(){return this.gl_}applyFrameState(e){const t=e.size,n=e.viewState.rotation,i=e.pixelRatio;this.setUniformFloatValue(Ey,.001*(Date.now()-this.startTime_)),this.setUniformFloatValue(Cy,e.viewState.zoom),this.setUniformFloatValue(Ay,e.viewState.resolution),this.setUniformFloatValue(yf,i),this.setUniformFloatVec2(Ty,[t[0],t[1]]),this.setUniformFloatValue(Sy,n)}applyHitDetectionUniform(e){const t=this.getUniformLocation(Ry);this.getGL().uniform1i(t,e?1:0),e&&this.setUniformFloatValue(yf,.5)}applyUniforms(e){const t=this.gl_;let n,i=0;this.uniforms_.forEach(r=>{if(n=typeof r.value=="function"?r.value(e):r.value,n instanceof HTMLCanvasElement||n instanceof HTMLImageElement||n instanceof ImageData||n instanceof WebGLTexture){n instanceof WebGLTexture&&!r.texture?(r.prevValue=void 0,r.texture=n):r.texture||(r.prevValue=void 0,r.texture=t.createTexture()),this.bindTexture(r.texture,i,r.name),t.texParameteri(t.TEXTURE_2D,t.TEXTURE_MIN_FILTER,t.LINEAR),t.texParameteri(t.TEXTURE_2D,t.TEXTURE_WRAP_S,t.CLAMP_TO_EDGE),t.texParameteri(t.TEXTURE_2D,t.TEXTURE_WRAP_T,t.CLAMP_TO_EDGE);const s=!(n instanceof HTMLImageElement)||n.complete;!(n instanceof WebGLTexture)&&s&&r.prevValue!==n&&(r.prevValue=n,t.texImage2D(t.TEXTURE_2D,0,t.RGBA,t.RGBA,t.UNSIGNED_BYTE,n)),i++}else if(Array.isArray(n)&&n.length===6)this.setUniformMatrixValue(r.name,_f(this.tmpMat4_,n));else if(Array.isArray(n)&&n.length<=4)switch(n.length){case 2:return void t.uniform2f(this.getUniformLocation(r.name),n[0],n[1]);case 3:return void t.uniform3f(this.getUniformLocation(r.name),n[0],n[1],n[2]);case 4:return void t.uniform4f(this.getUniformLocation(r.name),n[0],n[1],n[2],n[3]);default:return}else typeof n=="number"&&t.uniform1f(this.getUniformLocation(r.name),n)})}useProgram(e,t){this.gl_.useProgram(e),this.currentProgram_=e,this.applyFrameState(t),this.applyUniforms(t)}compileShader(e,t){const n=this.gl_,i=n.createShader(t);return n.shaderSource(i,e),n.compileShader(i),i}getProgram(e,t){const n=this.gl_,i=this.compileShader(e,n.FRAGMENT_SHADER),r=this.compileShader(t,n.VERTEX_SHADER),s=n.createProgram();if(n.attachShader(s,i),n.attachShader(s,r),n.linkProgram(s),!n.getShaderParameter(i,n.COMPILE_STATUS)){const o=`Fragment shader compilation failed: ${n.getShaderInfoLog(i)}`;throw new Error(o)}if(n.deleteShader(i),!n.getShaderParameter(r,n.COMPILE_STATUS)){const o=`Vertex shader compilation failed: ${n.getShaderInfoLog(r)}`;throw new Error(o)}if(n.deleteShader(r),!n.getProgramParameter(s,n.LINK_STATUS)){const o=`GL program linking failed: ${n.getProgramInfoLog(s)}`;throw new Error(o)}return s}getUniformLocation(e){const t=Ae(this.currentProgram_);return this.uniformLocationsByProgram_[t]===void 0&&(this.uniformLocationsByProgram_[t]={}),this.uniformLocationsByProgram_[t][e]===void 0&&(this.uniformLocationsByProgram_[t][e]=this.gl_.getUniformLocation(this.currentProgram_,e)),this.uniformLocationsByProgram_[t][e]}getAttributeLocation(e){const t=Ae(this.currentProgram_);return this.attribLocationsByProgram_[t]===void 0&&(this.attribLocationsByProgram_[t]={}),this.attribLocationsByProgram_[t][e]===void 0&&(this.attribLocationsByProgram_[t][e]=this.gl_.getAttribLocation(this.currentProgram_,e)),this.attribLocationsByProgram_[t][e]}makeProjectionTransform(e,t){const n=e.size,i=e.viewState.rotation,r=e.viewState.resolution,s=e.viewState.center;return Yr(t,0,0,2/(r*n[0]),2/(r*n[1]),-i,-s[0],-s[1]),t}setUniformFloatValue(e,t){this.gl_.uniform1f(this.getUniformLocation(e),t)}setUniformFloatVec2(e,t){this.gl_.uniform2fv(this.getUniformLocation(e),t)}setUniformFloatVec4(e,t){this.gl_.uniform4fv(this.getUniformLocation(e),t)}setUniformMatrixValue(e,t){this.gl_.uniformMatrix4fv(this.getUniformLocation(e),!1,t)}enableAttributeArray_(e,t,n,i,r){const s=this.getAttributeLocation(e);s<0||(this.gl_.enableVertexAttribArray(s),this.gl_.vertexAttribPointer(s,t,n,!1,i,r))}enableAttributes(e){const t=function(i){let r=0;for(let s=0;s<i.length;s++){const o=i[s];r+=o.size*wf(o.type)}return r}(e);let n=0;for(let i=0;i<e.length;i++){const r=e[i];this.enableAttributeArray_(r.name,r.size,r.type||5126,t,n),n+=r.size*wf(r.type)}}handleWebGLContextLost(e){Br(this.bufferCache_),this.currentProgram_=null,e.preventDefault()}handleWebGLContextRestored(){this.needsToBeRecreated_=!0}needsToBeRecreated(){return this.needsToBeRecreated_}createTexture(e,t,n){const i=this.gl_;n=n||i.createTexture();const r=i.RGBA,s=i.RGBA,o=i.UNSIGNED_BYTE;return i.bindTexture(i.TEXTURE_2D,n),t?i.texImage2D(i.TEXTURE_2D,0,r,s,o,t):i.texImage2D(i.TEXTURE_2D,0,r,e[0],e[1],0,s,o,null),i.texParameteri(i.TEXTURE_2D,i.TEXTURE_MIN_FILTER,i.LINEAR),i.texParameteri(i.TEXTURE_2D,i.TEXTURE_WRAP_S,i.CLAMP_TO_EDGE),i.texParameteri(i.TEXTURE_2D,i.TEXTURE_WRAP_T,i.CLAMP_TO_EDGE),n}};function wf(e){switch(e){case ky:return Uint8Array.BYTES_PER_ELEMENT;case Py:return Uint16Array.BYTES_PER_ELEMENT;case Iy:return Uint32Array.BYTES_PER_ELEMENT;default:return Float32Array.BYTES_PER_ELEMENT}}let Ef=class zm extends xy{constructor(t,n){super(t),n=n||{},this.inversePixelTransform_=[1,0,0,1,0,0],this.postProcesses_=n.postProcesses,this.uniforms_=n.uniforms,this.helper,t.addChangeListener(cc,this.removeHelper.bind(this)),this.dispatchPreComposeEvent=this.dispatchPreComposeEvent.bind(this),this.dispatchPostComposeEvent=this.dispatchPostComposeEvent.bind(this)}dispatchPreComposeEvent(t,n){const i=this.getLayer();if(i.hasListener(vs)){const r=new zs(vs,void 0,n,t);i.dispatchEvent(r)}}dispatchPostComposeEvent(t,n){const i=this.getLayer();if(i.hasListener(hc)){const r=new zs(hc,void 0,n,t);i.dispatchEvent(r)}}reset(t){this.uniforms_=t.uniforms,this.helper&&this.helper.setUniforms(this.uniforms_)}removeHelper(){this.helper&&(this.helper.dispose(),delete this.helper)}prepareFrame(t){if(this.getLayer().getRenderSource()){let n,i=!0,r=-1;for(let o=0,a=t.layerStatesArray.length;o<a;o++){const l=t.layerStatesArray[o].layer,c=l.getRenderer();if(!(c instanceof zm)){i=!0;continue}const u=l.getClassName();if((i||u!==n)&&(r+=1,i=!1),n=u,c===this)break}const s="map/"+t.mapId+"/group/"+r;(!this.helper||!this.helper.canvasCacheKeyMatches(s)||this.helper.needsToBeRecreated())&&(this.removeHelper(),this.helper=new My({postProcesses:this.postProcesses_,uniforms:this.uniforms_,canvasCacheKey:s}),n&&(this.helper.getCanvas().className=n),this.afterHelperCreated())}return this.prepareFrameInternal(t)}afterHelperCreated(){}prepareFrameInternal(t){return!0}disposeInternal(){this.removeHelper(),super.disposeInternal()}dispatchRenderEvent_(t,n,i){const r=this.getLayer();if(r.hasListener(t)){Yr(this.inversePixelTransform_,0,0,i.pixelRatio,-i.pixelRatio,0,0,-i.size[1]);const s=new zs(t,this.inversePixelTransform_,i,n);r.dispatchEvent(s)}}preRender(t,n){this.dispatchRenderEvent_(G_,t,n)}postRender(t,n){this.dispatchRenderEvent_(V_,t,n)}};function Ns(e,t,n,i){return i!==void 0?(i[0]=e,i[1]=t,i[2]=n,i):[e,t,n]}function au(e,t,n){return e+"/"+t+"/"+n}function Yn(e){return au(e[0],e[1],e[2])}const Ly={};function Cf(e){return 1/(e+2)}function Af(e,t){return e.tileIds.has(Ae(t))}function Sf(e,t,n){const i=e.representationsByZ;n in i||(i[n]=new Set),i[n].add(t),e.tileIds.add(Ae(t.tile))}function lu(e,t){const n=e.layerStatesArray[e.layerIndex];n.extent&&(t=Vt(t,vi(n.extent,e.viewState.projection)));const i=n.layer.getRenderSource();if(!i.getWrapX()){const r=i.getTileGridForProjection(e.viewState.projection).getExtent();r&&(t=Vt(t,r))}return t}function cu(e,t){return`${e.getKey()},${Yn(t)}`}let Fy=class extends Ef{constructor(e,t){super(e,{uniforms:t.uniforms,postProcesses:t.postProcesses}),this.renderComplete=!1,this.tileTransform_=[1,0,0,1,0,0],this.tempMat4=[1,0,0,0,0,1,0,0,0,0,1,0,0,0,0,1],this.tempTileRange_=new su(0,0,0,0),this.tempTileCoord_=Ns(0,0,0),this.tempSize_=[0,0];const n=t.cacheSize!==void 0?t.cacheSize:512;this.tileRepresentationCache=new gf(n),this.frameState=null,this.projection_=void 0}reset(e){super.reset({uniforms:e.uniforms})}prepareFrameInternal(e){this.projection_?e.viewState.projection!==this.projection_&&(this.clearCache(),this.projection_=e.viewState.projection):this.projection_=e.viewState.projection;const t=this.getLayer().getRenderSource();return!(!t||mi(lu(e,e.extent)))&&t.getState()==="ready"}createTileRepresentation(e){return ue()}enqueueTiles(e,t,n,i,r){const s=e.viewState,o=this.getLayer(),a=o.getRenderSource(),l=a.getTileGridForProjection(s.projection),c=a.getGutterForProjection(s.projection),u=Ae(a);u in e.wantedTiles||(e.wantedTiles[u]={});const h=e.wantedTiles[u],p=this.tileRepresentationCache,f=o.getMapInternal(),m=Math.max(n-r,l.getMinZoom(),l.getZForResolution(Math.min(o.getMaxResolution(),f?f.getView().getResolutionForZoom(Math.max(o.getMinZoom(),0)):l.getResolution(0)),a.zDirection));for(let _=n;_>=m;--_){const y=l.getTileRangeForExtentAndZ(t,_,this.tempTileRange_),x=l.getResolution(_);for(let w=y.minX;w<=y.maxX;++w)for(let T=y.minY;T<=y.maxY;++T){const R=Ns(_,w,T,this.tempTileCoord_),b=cu(a,R);let k,F;if(p.containsKey(b)&&(k=p.get(b),F=k.tile),(!k||k.tile.key!==a.getKey())&&(F=a.getTile(_,w,T,e.pixelRatio,s.projection),!F)||Af(i,F))continue;k?k.setTile(F):(k=this.createTileRepresentation({tile:F,grid:l,helper:this.helper,gutter:c}),p.set(b,k)),Sf(i,k,_);const j=F.getKey();h[j]=!0,F.getState()===Rt&&(e.tileQueue.isKeyQueued(j)||e.tileQueue.enqueue([F,u,l.getTileCoordCenter(R),x]))}}}beforeTilesRender(e,t){this.helper.prepareDraw(this.frameState,!t,!0)}beforeTilesMaskRender(e){return!1}renderTile(e,t,n,i,r,s,o,a,l,c,u){}renderTileMask(e,t,n,i){}drawTile_(e,t,n,i,r,s,o){if(!t.ready)return;const a=t.tile.tileCoord,l=Yn(a),c=l in s?s[l]:1,u=o.getResolution(n),h=lt(o.getTileSize(n),this.tempSize_),p=o.getOrigin(n),f=o.getTileCoordExtent(a),m=c<1?-1:Cf(n);c<1&&(e.animate=!0);const _=e.viewState,y=_.center[0],x=_.center[1],w=h[0]+2*i,T=h[1]+2*i,R=w/T,b=(y-p[0])/(h[0]*u),k=(p[1]-x)/(h[1]*u),F=_.resolution/u,j=a[1],B=a[2];(function(N){Ss(N,1,0,0,1,0,0)})(this.tileTransform_),Tg(this.tileTransform_,2/(e.size[0]*F/w),-2/(e.size[1]*F/w)),function(N,Y){const ee=Math.cos(Y),ne=Math.sin(Y);As(N,Ss(Bc,ee,ne,-ne,ee,0,0))}(this.tileTransform_,_.rotation),Tg(this.tileTransform_,1,1/R),Rg(this.tileTransform_,(h[0]*(j-b)-i)/w,(h[1]*(B-k)-i)/T),this.renderTile(t,this.tileTransform_,e,r,u,h,p,f,m,i,c)}renderFrame(e){this.frameState=e,this.renderComplete=!0;const t=this.helper.getGL();this.preRender(t,e);const n=e.viewState,i=this.getLayer(),r=i.getRenderSource(),s=r.getTileGridForProjection(n.projection),o=r.getGutterForProjection(n.projection),a=lu(e,e.extent),l=s.getZForResolution(n.resolution,r.zDirection),c={tileIds:new Set,representationsByZ:{}},u=i.getPreload();if(e.nextExtent){const T=s.getZForResolution(n.nextResolution,r.zDirection),R=lu(e,e.nextExtent);this.enqueueTiles(e,R,T,c,u)}this.enqueueTiles(e,a,l,c,0),u>0&&setTimeout(()=>{this.enqueueTiles(e,a,l-1,c,u-1)},0);const h={},p=Ae(this),f=e.time;let m=!1;const _=c.representationsByZ;if(l in _)for(const T of _[l]){const R=T.tile;if((R instanceof Os||R instanceof lf)&&R.getState()===nt)continue;const b=R.tileCoord;if(T.ready){const F=R.getAlpha(p,f);if(F===1){R.endTransition(p);continue}m=!0,h[Yn(b)]=F}if(this.renderComplete=!1,this.findAltTiles_(s,b,l+1,c))continue;const k=s.getMinZoom();for(let F=l-1;F>=k&&!this.findAltTiles_(s,b,F,c);--F);}const y=Object.keys(_).map(Number).sort(D_);if(this.beforeTilesMaskRender(e))for(let T=0,R=y.length;T<R;++T){const b=y[T];for(const k of _[b]){const F=k.tile.tileCoord;if(Yn(F)in h)continue;const j=s.getTileCoordExtent(F);this.renderTileMask(k,b,j,Cf(b))}}this.beforeTilesRender(e,m);for(let T=0,R=y.length;T<R;++T){const b=y[T];for(const k of _[b])Yn(k.tile.tileCoord)in h||this.drawTile_(e,k,b,o,a,h,s)}if(l in _)for(const T of _[l])Yn(T.tile.tileCoord)in h&&this.drawTile_(e,T,l,o,a,h,s);this.helper.finalizeDraw(e,this.dispatchPreComposeEvent,this.dispatchPostComposeEvent);const x=this.helper.getCanvas(),w=this.tileRepresentationCache;for(;w.canExpireCache();)w.pop().dispose();return e.postRenderFunctions.push(function(T,R){r.expireCache(R.viewState.projection,Ly)}),this.postRender(t,e),x}findAltTiles_(e,t,n,i){const r=e.getTileRangeForTileCoordAndZ(t,n,this.tempTileRange_);if(!r)return!1;let s=!0;const o=this.tileRepresentationCache,a=this.getLayer().getRenderSource();for(let l=r.minX;l<=r.maxX;++l)for(let c=r.minY;c<=r.maxY;++c){const u=cu(a,[n,l,c]);let h=!1;if(o.containsKey(u)){const p=o.get(u);p.ready&&!Af(i,p.tile)&&(Sf(i,p,n),h=!0)}h||(s=!1)}return s}clearCache(){const e=this.tileRepresentationCache;e.forEach(t=>t.dispose()),e.clear()}removeHelper(){this.helper&&this.clearCache(),super.removeHelper()}disposeInternal(){super.disposeInternal(),delete this.frameState}};const me={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",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"},Gs="a_textureCoord",Oy=[{name:Gs,size:2,type:ir}];let Dy=class extends Fy{constructor(e,t){super(e,t),this.program_,this.vertexShader_=t.vertexShader,this.fragmentShader_=t.fragmentShader,this.indices_=new Bs(Us,ru),this.indices_.fromArray([0,1,3,1,2,3]),this.paletteTextures_=t.paletteTextures||[]}reset(e){if(super.reset(e),this.helper){const t=this.helper.getGL();for(const n of this.paletteTextures_)n.delete(t)}this.vertexShader_=e.vertexShader,this.fragmentShader_=e.fragmentShader,this.paletteTextures_=e.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 e=this.helper.getGL();for(const t of this.paletteTextures_)t.delete(e)}super.removeHelper()}createTileRepresentation(e){return new by(e)}beforeTilesRender(e,t){super.beforeTilesRender(e,t),this.helper.useProgram(this.program_,e)}renderTile(e,t,n,i,r,s,o,a,l,c,u){const h=this.helper.getGL();this.helper.bindBuffer(e.coords),this.helper.bindBuffer(this.indices_),this.helper.enableAttributes(Oy);let p=0;for(;p<e.textures.length;){const R=`${me.TILE_TEXTURE_ARRAY}[${p}]`;this.helper.bindTexture(e.textures[p],p,R),++p}for(let R=0;R<this.paletteTextures_.length;++R){const b=this.paletteTextures_[R],k=b.getTexture(h);this.helper.bindTexture(k,p,b.name),++p}const f=n.viewState,m=s[0]+2*c,_=s[1]+2*c,y=e.tile.tileCoord,x=y[1],w=y[2];this.helper.setUniformMatrixValue(me.TILE_TRANSFORM,_f(this.tempMat4,t)),this.helper.setUniformFloatValue(me.TRANSITION_ALPHA,u),this.helper.setUniformFloatValue(me.DEPTH,l);let T=i;c>0&&(T=a,Vt(T,i,T)),this.helper.setUniformFloatVec4(me.RENDER_EXTENT,T),this.helper.setUniformFloatValue(me.RESOLUTION,f.resolution),this.helper.setUniformFloatValue(me.ZOOM,f.zoom),this.helper.setUniformFloatValue(me.TEXTURE_PIXEL_WIDTH,m),this.helper.setUniformFloatValue(me.TEXTURE_PIXEL_HEIGHT,_),this.helper.setUniformFloatValue(me.TEXTURE_RESOLUTION,r),this.helper.setUniformFloatValue(me.TEXTURE_ORIGIN_X,o[0]+x*s[0]*r-c*r),this.helper.setUniformFloatValue(me.TEXTURE_ORIGIN_Y,o[1]-w*s[1]*r+c*r),this.helper.drawElements(0,this.indices_.getSize())}getData(e){if(!this.helper.getGL())return null;const t=this.frameState;if(!t)return null;const n=this.getLayer(),i=Wr(t.pixelToCoordinateTransform,e.slice()),r=t.viewState,s=n.getExtent();if(s&&!bs(vi(s,r.projection),i))return null;const o=n.getSources(xc([i]),r.resolution);let a,l,c;for(a=o.length-1;a>=0;--a)if(l=o[a],l.getState()==="ready"){if(c=l.getTileGridForProjection(r.projection),l.getWrapX())break;const h=c.getExtent();if(!h||bs(h,i))break}if(a<0)return null;const u=this.tileRepresentationCache;for(let h=c.getZForResolution(r.resolution);h>=c.getMinZoom();--h){const p=c.getTileCoordForCoordAndZ(i,h),f=cu(l,p);if(!u.containsKey(f))continue;const m=u.get(f),_=m.tile;if((_ instanceof Os||_ instanceof lf)&&_.getState()===nt)return null;if(!m.loaded)continue;const y=c.getOrigin(h),x=lt(c.getTileSize(h)),w=c.getResolution(h),T=(i[0]-y[0])/w-p[1]*x[0],R=(y[1]-i[1])/w-p[2]*x[1];return m.getPixelData(T,R)}return null}disposeInternal(){const e=this.helper;if(e){const t=e.getGL();for(const n of this.paletteTextures_)n.delete(t);this.paletteTextures_.length=0,t.deleteProgram(this.program_),delete this.program_,e.deleteBuffer(this.indices_)}super.disposeInternal(),delete this.indices_}};const eo={name:"rgb",min:[0,0,0],max:[255,255,255],channel:["red","green","blue"],alias:["RGB"]};var ft={name:"xyz",min:[0,0,0],channel:["X","Y","Z"],alias:["XYZ","ciexyz","cie1931"],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]}}};ft.max=ft.whitepoint[2].D65,ft.rgb=function(e,t){t=t||ft.whitepoint[2].E;var n,i,r,s=e[0]/t[0],o=e[1]/t[1],a=e[2]/t[2];return i=-.96924363628087*s+1.87596750150772*o+.041555057407175*a,r=.055630079696993*s+-.20397695888897*o+1.056971514242878*a,n=(n=3.240969941904521*s+-1.537383177570093*o+-.498610760293*a)>.0031308?1.055*Math.pow(n,1/2.4)-.055:n*=12.92,i=i>.0031308?1.055*Math.pow(i,1/2.4)-.055:i*=12.92,r=r>.0031308?1.055*Math.pow(r,1/2.4)-.055:r*=12.92,[255*(n=Math.min(Math.max(0,n),1)),255*(i=Math.min(Math.max(0,i),1)),255*(r=Math.min(Math.max(0,r),1))]},eo.xyz=function(e,t){var n=e[0]/255,i=e[1]/255,r=e[2]/255,s=.21263900587151*(n=n>.04045?Math.pow((n+.055)/1.055,2.4):n/12.92)+.71516867876775*(i=i>.04045?Math.pow((i+.055)/1.055,2.4):i/12.92)+.072192315360733*(r=r>.04045?Math.pow((r+.055)/1.055,2.4):r/12.92),o=.019330818715591*n+.11919477979462*i+.95053215224966*r;return[(.41239079926595*n+.35758433938387*i+.18048078840183*r)*(t=t||ft.whitepoint[2].E)[0],s*t[1],o*t[2]]};const uu={name:"luv",min:[0,-134,-140],max:[100,224,122],channel:["lightness","u","v"],alias:["LUV","cieluv","cie1976"],xyz:function(e,t,n){var i,r,s,o,a,l,c,u,h;return s=e[0],o=e[1],a=e[2],s===0?[0,0,0]:(t=t||"D65",n=n||2,i=o/(13*s)+4*(c=ft.whitepoint[n][t][0])/(c+15*(u=ft.whitepoint[n][t][1])+3*(h=ft.whitepoint[n][t][2]))||0,r=a/(13*s)+9*u/(c+15*u+3*h)||0,[9*(l=s>8?u*Math.pow((s+16)/116,3):u*s*.0011070564598794539)*i/(4*r)||0,l,l*(12-3*i-20*r)/(4*r)||0])}};ft.luv=function(e,t,n){var i,r,s,o,a,l,c,u,h,p,f;t=t||"D65",n=n||2,p=4*(c=ft.whitepoint[n][t][0])/(c+15*(u=ft.whitepoint[n][t][1])+3*(h=ft.whitepoint[n][t][2])),f=9*u/(c+15*u+3*h),i=4*(o=e[0])/(o+15*(a=e[1])+3*(l=e[2]))||0,r=9*a/(o+15*a+3*l)||0;var m=a/u;return[s=m<=.008856451679035631?903.2962962962961*m:116*Math.pow(m,1/3)-16,13*s*(i-p),13*s*(r-f)]};var Tf={name:"lchuv",channel:["lightness","chroma","hue"],alias:["LCHuv","cielchuv"],min:[0,0,0],max:[100,100,360],luv:function(e){var t,n=e[0],i=e[1];return t=e[2]/360*2*Math.PI,[n,i*Math.cos(t),i*Math.sin(t)]},xyz:function(e){return uu.xyz(Tf.luv(e))}};uu.lchuv=function(e){var t=e[0],n=e[1],i=e[2],r=Math.sqrt(n*n+i*i),s=360*Math.atan2(i,n)/2/Math.PI;return s<0&&(s+=360),[t,r,s]},ft.lchuv=function(e){return uu.lchuv(ft.luv(e))};const Rf={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 kf={red:0,orange:60,yellow:120,green:180,blue:240,purple:300};const hu={name:"hsl",min:[0,0,0],max:[360,100,100],channel:["hue","saturation","lightness"],alias:["HSL"],rgb:function(e){var t,n,i,r,s,o=e[0]/360,a=e[1]/100,l=e[2]/100,c=0;if(a===0)return[s=255*l,s,s];for(t=2*l-(n=l<.5?l*(1+a):l+a-l*a),r=[0,0,0];c<3;)(i=o+1/3*-(c-1))<0?i++:i>1&&i--,s=6*i<1?t+6*(n-t)*i:2*i<1?n:3*i<2?t+(n-t)*(2/3-i)*6:t,r[c++]=255*s;return r}};function Uy(e){Array.isArray(e)&&e.raw&&(e=String.raw(...arguments)),e instanceof Number&&(e=+e);var t,n=function(s){var o,a,l,c,u=[],h=1;if(typeof s=="number")return{space:"rgb",values:[s>>>16,(65280&s)>>>8,255&s],alpha:1};if(typeof s=="number")return{space:"rgb",values:[s>>>16,(65280&s)>>>8,255&s],alpha:1};if(s=String(s).toLowerCase(),Rf[s])u=Rf[s].slice(),c="rgb";else if(s==="transparent")h=0,c="rgb",u=[0,0,0];else if(s[0]==="#"){var p=s.slice(1),f=p.length;h=1,f<=4?(u=[parseInt(p[0]+p[0],16),parseInt(p[1]+p[1],16),parseInt(p[2]+p[2],16)],f===4&&(h=parseInt(p[3]+p[3],16)/255)):(u=[parseInt(p[0]+p[1],16),parseInt(p[2]+p[3],16),parseInt(p[4]+p[5],16)],f===8&&(h=parseInt(p[6]+p[7],16)/255)),u[0]||(u[0]=0),u[1]||(u[1]=0),u[2]||(u[2]=0),c="rgb"}else if(l=/^((?:rgba?|hs[lvb]a?|hwba?|cmyk?|xy[zy]|gray|lab|lchu?v?|[ly]uv|lms|oklch|oklab|color))\s*\(([^\)]*)\)/.exec(s)){var m=l[1],_=(c=m.replace(/a$/,""))==="cmyk"?4:c==="gray"?1:3;u=l[2].trim().split(/\s*[,\/]\s*|\s+/),c==="color"&&(c=u.shift()),u=u.map(function(y,x){if(y[y.length-1]==="%")return y=parseFloat(y)/100,x===3?y:c==="rgb"?255*y:c[0]==="h"||c[0]==="l"&&!x?100*y:c==="lab"?125*y:c==="lch"?x<2?150*y:360*y:c[0]!=="o"||x?c==="oklab"?.4*y:c==="oklch"?x<2?.4*y:360*y:y:y;if(c[x]==="h"||x===2&&c[c.length-1]==="h"){if(kf[y]!==void 0)return kf[y];if(y.endsWith("deg"))return parseFloat(y);if(y.endsWith("turn"))return 360*parseFloat(y);if(y.endsWith("grad"))return 360*parseFloat(y)/400;if(y.endsWith("rad"))return 180*parseFloat(y)/Math.PI}return y==="none"?0:parseFloat(y)}),h=u.length>_?u.pop():1}else/[0-9](?:\s|\/|,)/.test(s)&&(u=s.match(/([0-9]+)/g).map(function(y){return parseFloat(y)}),c=((a=(o=s.match(/([a-z])/gi))==null?void 0:o.join(""))==null?void 0:a.toLowerCase())||"rgb");return{space:c,values:u,alpha:h}}(e);if(!n.space)return[];const i=n.space[0]==="h"?hu.min:eo.min,r=n.space[0]==="h"?hu.max:eo.max;return(t=Array(3))[0]=Math.min(Math.max(n.values[0],i[0]),r[0]),t[1]=Math.min(Math.max(n.values[1],i[1]),r[1]),t[2]=Math.min(Math.max(n.values[2],i[2]),r[2]),n.space[0]==="h"&&(t=hu.rgb(t)),t.push(Math.min(Math.max(n.alpha,0),1)),t}eo.hsl=function(e){var t,n,i=e[0]/255,r=e[1]/255,s=e[2]/255,o=Math.min(i,r,s),a=Math.max(i,r,s),l=a-o;return a===o?t=0:i===a?t=(r-s)/l:r===a?t=2+(s-i)/l:s===a&&(t=4+(i-r)/l),(t=Math.min(60*t,360))<0&&(t+=360),n=(o+a)/2,[t,100*(a===o?0:n<=.5?l/(a+o):l/(2-a-o)),100*n]};const to={};let du=0;function By(e){if(e.length===4)return e;const t=e.slice();return t[3]=1,t}function Pf(e){const t=ft.lchuv(eo.xyz(e));return t[3]=e[3],t}function pu(e){if(to.hasOwnProperty(e))return to[e];if(du>=1024){let n=0;for(const i in to)3&n++||(delete to[i],--du)}const t=Uy(e);if(t.length!==4)throw new Error('failed to parse "'+e+'" as color');for(const n of t)if(isNaN(n))throw new Error('failed to parse "'+e+'" as color');return If(t),to[e]=t,++du,t}function Zn(e){return Array.isArray(e)?e:pu(e)}function If(e){return e[0]=Ze(e[0]+.5|0,0,255),e[1]=Ze(e[1]+.5|0,0,255),e[2]=Ze(e[2]+.5|0,0,255),e[3]=Ze(e[3],0,1),e}function gu(e){let t=e[0];t!=(0|t)&&(t=t+.5|0);let n=e[1];n!=(0|n)&&(n=n+.5|0);let i=e[2];return i!=(0|i)&&(i=i+.5|0),"rgba("+t+","+n+","+i+","+(e[3]===void 0?1:Math.round(1e3*e[3])/1e3)+")"}let rr=0;const ct=1<<rr++,re=1<<rr++,it=1<<rr++,Ge=1<<rr++,xt=1<<rr++,Jt=1<<rr++,Vs=Math.pow(2,6)-1,fu={[ct]:"boolean",[re]:"number",[it]:"string",[Ge]:"color",[xt]:"number[]",[Jt]:"size"},zy=Object.keys(fu).map(Number).sort(as);function or(e){const t=[];for(const n of zy)no(e,n)&&t.push(fu[n]);return t.length===0?"untyped":t.length<3?t.join(" or "):t.slice(0,-1).join(", ")+", or "+t[t.length-1]}function no(e,t){return(e&t)===t}function Hn(e,t){return e===t}let Je=class{constructor(e,t){if(!function(n){return n in fu}(e))throw new Error(`literal expressions must have a specific type, got ${or(e)}`);this.type=e,this.value=t}},Mf=class{constructor(e,t,...n){this.type=e,this.operator=t,this.args=n}};function mu(){return{variables:new Set,properties:new Set,featureId:!1,geometryType:!1}}function rt(e,t,n){switch(typeof e){case"boolean":if(Hn(t,it))return new Je(it,e?"true":"false");if(!no(t,ct))throw new Error(`got a boolean, but expected ${or(t)}`);return new Je(ct,e);case"number":if(Hn(t,Jt))return new Je(Jt,lt(e));if(Hn(t,ct))return new Je(ct,!!e);if(Hn(t,it))return new Je(it,e.toString());if(!no(t,re))throw new Error(`got a number, but expected ${or(t)}`);return new Je(re,e);case"string":if(Hn(t,Ge))return new Je(Ge,pu(e));if(Hn(t,ct))return new Je(ct,!!e);if(!no(t,it))throw new Error(`got a string, but expected ${or(t)}`);return new Je(it,e)}if(!Array.isArray(e))throw new Error("expression must be an array or a primitive value");if(e.length===0)throw new Error("empty expression");if(typeof e[0]=="string")return function(i,r,s){const o=i[0],a=jy[o];if(!a)throw new Error(`unknown operator: ${o}`);return a(i,r,s)}(e,t,n);for(const i of e)if(typeof i!="number")throw new Error("expected an array of numbers");if(Hn(t,Jt)){if(e.length!==2)throw new Error(`expected an array of two values for a size, got ${e.length}`);return new Je(Jt,e)}if(Hn(t,Ge)){if(e.length===3)return new Je(Ge,[...e,1]);if(e.length===4)return new Je(Ge,e);throw new Error(`expected an array of 3 or 4 values for a color, got ${e.length}`)}if(!no(t,xt))throw new Error(`got an array of numbers, but expected ${or(t)}`);return new Je(xt,e)}const $s="get",qs="var",Lf="concat",vu="geometry-type",Xs="any",Ws="all",Ys="!",_u="resolution",Ff="zoom",Of="time",Zs="==",Hs="!=",Ks=">",Qs=">=",Js="<",ea="<=",ta="*",na="/",ia="+",ra="-",oa="clamp",sa="%",aa="^",la="abs",ca="floor",ua="ceil",ha="round",da="sin",pa="cos",ga="atan",fa="sqrt",yu="match",ma="between",bu="interpolate",xu="coalesce",wu="case",va="in",Eu="number",Cu="string",Df="array",Uf="color",Bf="id",zf="band",jf="palette",Au="to-string",jy={[$s]:ge(xe(1,1/0),function(e,t,n){const i=e.length-1,r=new Array(i);for(let s=0;s<i;++s){const o=e[s+1];switch(typeof o){case"number":r[s]=new Je(re,o);break;case"string":r[s]=new Je(it,o);break;default:throw new Error(`expected a string key or numeric array index for a get operation, got ${o}`)}s===0&&n.properties.add(String(o))}return r}),[qs]:ge(xe(1,1),function(e,t,n){const i=e[1];if(typeof i!="string")throw new Error("expected a string argument for var operation");return n.variables.add(i),[new Je(it,i)]}),[Bf]:ge(function(e,t,n){n.featureId=!0},io),[Lf]:ge(xe(2,1/0),ke(it)),[vu]:ge(function(e,t,n){n.geometryType=!0},io),[_u]:ge(io),[Ff]:ge(io),[Of]:ge(io),[Xs]:ge(xe(2,1/0),ke(ct)),[Ws]:ge(xe(2,1/0),ke(ct)),[Ys]:ge(xe(1,1),ke(ct)),[Zs]:ge(xe(2,2),ke(Vs)),[Hs]:ge(xe(2,2),ke(Vs)),[Ks]:ge(xe(2,2),ke(re)),[Qs]:ge(xe(2,2),ke(re)),[Js]:ge(xe(2,2),ke(re)),[ea]:ge(xe(2,2),ke(re)),[ta]:ge(xe(2,1/0),Nf),[xu]:ge(xe(2,1/0),Nf),[na]:ge(xe(2,2),ke(re)),[ia]:ge(xe(2,1/0),ke(re)),[ra]:ge(xe(2,2),ke(re)),[oa]:ge(xe(3,3),ke(re)),[sa]:ge(xe(2,2),ke(re)),[aa]:ge(xe(2,2),ke(re)),[la]:ge(xe(1,1),ke(re)),[ca]:ge(xe(1,1),ke(re)),[ua]:ge(xe(1,1),ke(re)),[ha]:ge(xe(1,1),ke(re)),[da]:ge(xe(1,1),ke(re)),[pa]:ge(xe(1,1),ke(re)),[ga]:ge(xe(1,2),ke(re)),[fa]:ge(xe(1,1),ke(re)),[yu]:ge(xe(4,1/0),Gf,function(e,t,n){const i=e.length-1,r=it|re|ct,s=rt(e[1],r,n),o=rt(e[e.length-1],t,n),a=new Array(i-2);for(let l=0;l<i-2;l+=2){try{const c=rt(e[l+2],s.type,n);a[l]=c}catch(c){throw new Error(`failed to parse argument ${l+1} of match expression: ${c.message}`)}try{const c=rt(e[l+3],o.type,n);a[l+1]=c}catch(c){throw new Error(`failed to parse argument ${l+2} of match expression: ${c.message}`)}}return[s,...a,o]}),[ma]:ge(xe(3,3),ke(re)),[bu]:ge(xe(6,1/0),Gf,function(e,t,n){const i=e[1];let r;switch(i[0]){case"linear":r=1;break;case"exponential":const l=i[1];if(typeof l!="number"||l<=0)throw new Error(`expected a number base for exponential interpolation, got ${JSON.stringify(l)} instead`);r=l;break;default:throw new Error(`invalid interpolation type: ${JSON.stringify(i)}`)}const s=new Je(re,r);let o;try{o=rt(e[2],re,n)}catch(l){throw new Error(`failed to parse argument 1 in interpolate expression: ${l.message}`)}const a=new Array(e.length-3);for(let l=0;l<a.length;l+=2){try{const c=rt(e[l+3],re,n);a[l]=c}catch(c){throw new Error(`failed to parse argument ${l+2} for interpolate expression: ${c.message}`)}try{const c=rt(e[l+4],t,n);a[l+1]=c}catch(c){throw new Error(`failed to parse argument ${l+3} for interpolate expression: ${c.message}`)}}return[s,o,...a]}),[wu]:ge(xe(3,1/0),function(e,t,n){const i=e[0],r=e.length-1;if(r%2==0)throw new Error(`expected an odd number of arguments for ${i}, got ${r} instead`)},function(e,t,n){const i=rt(e[e.length-1],t,n),r=new Array(e.length-1);for(let s=0;s<r.length-1;s+=2){try{const o=rt(e[s+1],ct,n);r[s]=o}catch(o){throw new Error(`failed to parse argument ${s} of case expression: ${o.message}`)}try{const o=rt(e[s+2],i.type,n);r[s+1]=o}catch(o){throw new Error(`failed to parse argument ${s+1} of case expression: ${o.message}`)}}return r[r.length-1]=i,r}),[va]:ge(xe(2,2),function(e,t,n){let i,r=e[2];if(!Array.isArray(r))throw new Error('the second argument for the "in" operator must be an array');if(typeof r[0]=="string"){if(r[0]!=="literal")throw new Error('for the "in" operator, a string array should be wrapped in a "literal" operator to disambiguate from expressions');if(!Array.isArray(r[1]))throw new Error('failed to parse "in" expression: the literal operator must be followed by an array');r=r[1],i=it}else i=re;const s=new Array(r.length);for(let o=0;o<s.length;o++)try{const a=rt(r[o],i,n);s[o]=a}catch(a){throw new Error(`failed to parse haystack item ${o} for "in" expression: ${a.message}`)}return[rt(e[1],i,n),...s]}),[Eu]:ge(xe(1,1/0),ke(Vs)),[Cu]:ge(xe(1,1/0),ke(Vs)),[Df]:ge(xe(1,1/0),ke(re)),[Uf]:ge(xe(1,4),ke(re)),[zf]:ge(xe(1,3),ke(re)),[jf]:ge(xe(2,2),function(e,t,n){let i;try{i=rt(e[1],re,n)}catch(o){throw new Error(`failed to parse first argument in palette expression: ${o.message}`)}const r=e[2];if(!Array.isArray(r))throw new Error("the second argument of palette must be an array");const s=new Array(r.length);for(let o=0;o<s.length;o++){let a;try{a=rt(r[o],Ge,n)}catch(l){throw new Error(`failed to parse color at index ${o} in palette expression: ${l.message}`)}if(!(a instanceof Je))throw new Error(`the palette color at index ${o} must be a literal value`);s[o]=a}return[i,...s]}),[Au]:ge(xe(1,1),ke(ct|re|it|Ge))};function io(e,t,n){const i=e[0];if(e.length!==1)throw new Error(`expected no arguments for ${i} operation`);return[]}function xe(e,t){return function(n,i,r){const s=n[0],o=n.length-1;if(e===t){if(o!==e)throw new Error(`expected ${e} argument${e===1?"":"s"} for ${s}, got ${o}`)}else if(o<e||o>t)throw new Error(`expected ${t===1/0?`${e} or more`:`${e} to ${t}`} arguments for ${s}, got ${o}`)}}function Nf(e,t,n){const i=e.length-1,r=new Array(i);for(let s=0;s<i;++s){const o=rt(e[s+1],t,n);r[s]=o}return r}function ke(e){return function(t,n,i){const r=t.length-1,s=new Array(r);for(let o=0;o<r;++o){const a=rt(t[o+1],e,i);s[o]=a}return s}}function Gf(e,t,n){const i=e[0],r=e.length-1;if(r%2==1)throw new Error(`expected an even number of arguments for operation ${i}, got ${r} instead`)}function ge(...e){return function(t,n,i){const r=t[0];let s;for(let o=0;o<e.length;o++){const a=e[o](t,n,i);if(o==e.length-1){if(!a)throw new Error("expected last argument validator to return the parsed args");s=a}}return new Mf(n,r,...s)}}function Su(e){if(!e)return"";const t=e.getType();switch(t){case"Point":case"LineString":case"Polygon":return t;case"MultiPoint":case"MultiLineString":case"MultiPolygon":return t.substring(5);case"Circle":return"Polygon";case"GeometryCollection":return Su(e.getGeometries()[0]);default:return""}}let Ny=class{constructor(e,t){this.name=e,this.data=t,this.texture_=null}getTexture(e){if(!this.texture_){const t=e.createTexture();e.bindTexture(e.TEXTURE_2D,t),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.texParameteri(e.TEXTURE_2D,e.TEXTURE_MIN_FILTER,e.NEAREST),e.texParameteri(e.TEXTURE_2D,e.TEXTURE_MAG_FILTER,e.NEAREST),e.texImage2D(e.TEXTURE_2D,0,e.RGBA,this.data.length/4,1,0,e.RGBA,e.UNSIGNED_BYTE,this.data),this.texture_=t}return this.texture_}delete(e){this.texture_&&e.deleteTexture(this.texture_),this.texture_=null}};function Ci(e){const t=e.toString();return t.includes(".")?t:t+".0"}function _a(e){if(e.length<2||e.length>4)throw new Error("`formatArray` can only output `vec2`, `vec3` or `vec4` arrays.");return`vec${e.length}(${e.map(Ci).join(", ")})`}function ya(e){const t=Zn(e),n=t.length>3?t[3]:1;return _a([t[0]/255*n,t[1]/255*n,t[2]/255*n,n])}const Tu={};let Gy=0;function ba(e){return e in Tu||(Tu[e]=Gy++),Tu[e]}function Tn(e){return Ci(ba(e))}function Ru(e){return"u_var_"+e}const ku="getBandValue",Vf="u_paletteTextures";function Se(e){return(t,n,i)=>{const r=n.args.length,s=new Array(r);for(let o=0;o<r;++o)s[o]=Pu(n.args[o],i,t);return e(s,t)}}const Vy={[$s]:(e,t)=>{const n=t.args[0].value;return n in e.properties||(e.properties[n]={name:n,type:t.type}),(e.inFragmentShader?"v_prop_":"a_prop_")+n},[vu]:(e,t,n)=>{const i="geometryType";return i in e.properties||(e.properties[i]={name:i,type:it,evaluator:r=>Su(r.getGeometry())}),(e.inFragmentShader?"v_prop_":"a_prop_")+i},[qs]:(e,t)=>{const n=t.args[0].value;return n in e.variables||(e.variables[n]={name:n,type:t.type}),Ru(n)},[_u]:()=>"u_resolution",[Ff]:()=>"u_zoom",[Of]:()=>"u_time",[Xs]:Se(e=>`(${e.join(" || ")})`),[Ws]:Se(e=>`(${e.join(" && ")})`),[Ys]:Se(([e])=>`(!${e})`),[Zs]:Se(([e,t])=>`(${e} == ${t})`),[Hs]:Se(([e,t])=>`(${e} != ${t})`),[Ks]:Se(([e,t])=>`(${e} > ${t})`),[Qs]:Se(([e,t])=>`(${e} >= ${t})`),[Js]:Se(([e,t])=>`(${e} < ${t})`),[ea]:Se(([e,t])=>`(${e} <= ${t})`),[ta]:Se(e=>`(${e.join(" * ")})`),[na]:Se(([e,t])=>`(${e} / ${t})`),[ia]:Se(e=>`(${e.join(" + ")})`),[ra]:Se(([e,t])=>`(${e} - ${t})`),[oa]:Se(([e,t,n])=>`clamp(${e}, ${t}, ${n})`),[sa]:Se(([e,t])=>`mod(${e}, ${t})`),[aa]:Se(([e,t])=>`pow(${e}, ${t})`),[la]:Se(([e])=>`abs(${e})`),[ca]:Se(([e])=>`floor(${e})`),[ua]:Se(([e])=>`ceil(${e})`),[ha]:Se(([e])=>`floor(${e} + 0.5)`),[da]:Se(([e])=>`sin(${e})`),[pa]:Se(([e])=>`cos(${e})`),[ga]:Se(([e,t])=>t!==void 0?`atan(${e}, ${t})`:`atan(${e})`),[fa]:Se(([e])=>`sqrt(${e})`),[yu]:Se(e=>{const t=e[0],n=e[e.length-1];let i=null;for(let r=e.length-3;r>=1;r-=2)i=`(${t} == ${e[r]} ? ${e[r+1]} : ${i||n})`;return i}),[ma]:Se(([e,t,n])=>`(${e} >= ${t} && ${e} <= ${n})`),[bu]:Se(([e,t,...n])=>{let i="";for(let r=0;r<n.length-2;r+=2){const s=n[r],o=i||n[r+1],a=n[r+2],l=n[r+3];let c;c=e===Ci(1)?`(${t} - ${s}) / (${a} - ${s})`:`(pow(${e}, (${t} - ${s})) - 1.0) / (pow(${e}, (${a} - ${s})) - 1.0)`,i=`mix(${o}, ${l}, clamp(${c}, 0.0, 1.0))`}return i}),[wu]:Se(e=>{const t=e[e.length-1];let n=null;for(let i=e.length-3;i>=0;i-=2)n=`(${e[i]} ? ${e[i+1]} : ${n||t})`;return n}),[va]:Se(([e,...t],n)=>{const i=function(s,o){return`operator_${s}_${Object.keys(o.functions).length}`}("in",n),r=[];for(let s=0;s<t.length;s+=1)r.push(`  if (inputValue == ${t[s]}) { return true; }`);return n.functions[i]=`bool ${i}(float inputValue) {
${r.join(`
`)}
  return false;
}`,`${i}(${e})`}),[Df]:Se(e=>`vec${e.length}(${e.join(", ")})`),[Uf]:Se(e=>{if(e.length===1)return`vec4(vec3(${e[0]} / 255.0), 1.0)`;if(e.length===2)return`(${e[1]} * vec4(vec3(${e[0]} / 255.0), 1.0))`;const t=e.slice(0,3).map(n=>`${n} / 255.0`);return e.length===3?`vec4(${t.join(", ")}, 1.0)`:`(${e[3]} * vec4(${t.join(", ")}, 1.0))`}),[zf]:Se(([e,t,n],i)=>{if(!(ku in i.functions)){let r="";const s=i.bandCount||1;for(let o=0;o<s;o++){const a=Math.floor(o/4);let l=o%4;o===s-1&&l===1&&(l=3),r+=`  if (band == ${o+1}.0) {
    return texture2D(${`${me.TILE_TEXTURE_ARRAY}[${a}]`}, v_textureCoord + vec2(dx, dy))[${l}];
  }
`}i.functions[ku]=`float getBandValue(float band, float xOffset, float yOffset) {
  float dx = xOffset / ${me.TEXTURE_PIXEL_WIDTH};
  float dy = yOffset / ${me.TEXTURE_PIXEL_HEIGHT};
${r}
}`}return`${ku}(${e}, ${t??"0.0"}, ${n??"0.0"})`}),[jf]:(e,t)=>{const[n,...i]=t.args,r=i.length,s=new Uint8Array(4*r);for(let l=0;l<i.length;l++){const c=Zn(i[l].value),u=4*l;s[u]=c[0],s[u+1]=c[1],s[u+2]=c[2],s[u+3]=255*c[3]}e.paletteTextures||(e.paletteTextures=[]);const o=`${Vf}[${e.paletteTextures.length}]`,a=new Ny(o,s);return e.paletteTextures.push(a),`texture2D(${o}, vec2((${Pu(n,re,e)} + 0.5) / ${r}.0, 0.5))`}};function Pu(e,t,n){if(e instanceof Mf){const i=Vy[e.operator];if(i===void 0)throw new Error(`No compiler defined for this operator: ${JSON.stringify(e.operator)}`);return i(n,e,t)}if((e.type&re)>0)return Ci(e.value);if((e.type&ct)>0)return e.value.toString();if((e.type&it)>0)return Tn(e.value.toString());if((e.type&Ge)>0)return ya(e.value);if((e.type&xt)>0)return _a(e.value);if((e.type&Jt)>0)return function(i){return _a(lt(i))}(e.value);throw new Error(`Unexpected expression ${e.value} (expected type ${or(t)})`)}function $y(e,t){return(t=t||[])[0]=Math.floor(e/256/256/256)/255,t[1]=Math.floor(e/256/256)%256/255,t[2]=Math.floor(e/256)%256/255,t[3]=e%256/255,t}const sr=`#ifdef GL_FRAGMENT_PRECISION_HIGH
precision highp float;
#else
precision mediump float;
#endif
uniform mat4 u_projectionMatrix;
uniform mat4 u_screenToWorldMatrix;
uniform vec2 u_viewportSizePx;
uniform float u_pixelRatio;
uniform float u_globalAlpha;
uniform float u_time;
uniform float u_zoom;
uniform float u_resolution;
uniform float u_rotation;
uniform vec4 u_renderExtent;
uniform vec2 u_patternOrigin;
uniform float u_depth;
uniform mediump int u_hitDetection;

const float PI = 3.141592653589793238;
const float TWO_PI = 2.0 * PI;

// this used to produce an alpha-premultiplied color from a texture
vec4 samplePremultiplied(sampler2D sampler, vec2 texCoord) {
  vec4 color = texture2D(sampler, texCoord);
  return vec4(color.rgb * color.a, color.a);
}
`,ar={"fill-color":"rgba(255,255,255,0.4)","stroke-color":"#3399CC","stroke-width":1.25,"circle-radius":5,"circle-fill-color":"rgba(255,255,255,0.4)","circle-stroke-width":1.25,"circle-stroke-color":"#3399CC"};let qy=class{constructor(){this.uniforms_=[],this.attributes_=[],this.varyings_=[],this.hasSymbol_=!1,this.symbolSizeExpression_=`vec2(${Ci(ar["circle-radius"])} + ${Ci(.5*ar["circle-stroke-width"])})`,this.symbolRotationExpression_="0.0",this.symbolOffsetExpression_="vec2(0.0)",this.symbolColorExpression_=ya(ar["circle-fill-color"]),this.texCoordExpression_="vec4(0.0, 0.0, 1.0, 1.0)",this.discardExpression_="false",this.symbolRotateWithView_=!1,this.hasStroke_=!1,this.strokeWidthExpression_=Ci(ar["stroke-width"]),this.strokeColorExpression_=ya(ar["stroke-color"]),this.strokeOffsetExpression_="0.",this.strokeCapExpression_=Tn("round"),this.strokeJoinExpression_=Tn("round"),this.strokeMiterLimitExpression_="10.",this.strokeDistanceFieldExpression_="-1000.",this.hasFill_=!1,this.fillColorExpression_=ya(ar["fill-color"]),this.vertexShaderFunctions_=[],this.fragmentShaderFunctions_=[]}addUniform(e){return this.uniforms_.push(e),this}addAttribute(e){return this.attributes_.push(e),this}addVarying(e,t,n){return this.varyings_.push({name:e,type:t,expression:n}),this}setSymbolSizeExpression(e){return this.hasSymbol_=!0,this.symbolSizeExpression_=e,this}getSymbolSizeExpression(){return this.symbolSizeExpression_}setSymbolRotationExpression(e){return this.symbolRotationExpression_=e,this}setSymbolOffsetExpression(e){return this.symbolOffsetExpression_=e,this}getSymbolOffsetExpression(){return this.symbolOffsetExpression_}setSymbolColorExpression(e){return this.hasSymbol_=!0,this.symbolColorExpression_=e,this}getSymbolColorExpression(){return this.symbolColorExpression_}setTextureCoordinateExpression(e){return this.texCoordExpression_=e,this}setFragmentDiscardExpression(e){return this.discardExpression_=e,this}getFragmentDiscardExpression(){return this.discardExpression_}setSymbolRotateWithView(e){return this.symbolRotateWithView_=e,this}setStrokeWidthExpression(e){return this.hasStroke_=!0,this.strokeWidthExpression_=e,this}setStrokeColorExpression(e){return this.hasStroke_=!0,this.strokeColorExpression_=e,this}getStrokeColorExpression(){return this.strokeColorExpression_}setStrokeOffsetExpression(e){return this.strokeOffsetExpression_=e,this}setStrokeCapExpression(e){return this.strokeCapExpression_=e,this}setStrokeJoinExpression(e){return this.strokeJoinExpression_=e,this}setStrokeMiterLimitExpression(e){return this.strokeMiterLimitExpression_=e,this}setStrokeDistanceFieldExpression(e){return this.strokeDistanceFieldExpression_=e,this}setFillColorExpression(e){return this.hasFill_=!0,this.fillColorExpression_=e,this}getFillColorExpression(){return this.fillColorExpression_}addVertexShaderFunction(e){this.vertexShaderFunctions_.includes(e)||this.vertexShaderFunctions_.push(e)}addFragmentShaderFunction(e){this.fragmentShaderFunctions_.includes(e)||this.fragmentShaderFunctions_.push(e)}getSymbolVertexShader(){return this.hasSymbol_?`${sr}
${this.uniforms_.map(function(e){return"uniform "+e+";"}).join(`
`)}
attribute vec2 a_position;
attribute float a_index;
attribute vec4 a_prop_hitColor;
${this.attributes_.map(function(e){return"attribute "+e+";"}).join(`
`)}
varying vec2 v_texCoord;
varying vec2 v_quadCoord;
varying vec4 v_prop_hitColor;
varying vec2 v_centerPx;
varying float v_angle;
varying vec2 v_quadSizePx;
${this.varyings_.map(function(e){return"varying "+e.type+" "+e.name+";"}).join(`
`)}
${this.vertexShaderFunctions_.join(`
`)}
vec2 pxToScreen(vec2 coordPx) {
  vec2 scaled = coordPx / u_viewportSizePx / 0.5;
  return scaled;
}

vec2 screenToPx(vec2 coordScreen) {
  return (coordScreen * 0.5 + 0.5) * u_viewportSizePx;
}

void main(void) {
  v_quadSizePx = ${this.symbolSizeExpression_};
  vec2 halfSizePx = v_quadSizePx * 0.5;
  vec2 centerOffsetPx = ${this.symbolOffsetExpression_};
  vec2 offsetPx = centerOffsetPx;
  if (a_index == 0.0) {
    offsetPx -= halfSizePx;
  } else if (a_index == 1.0) {
    offsetPx += halfSizePx * vec2(1., -1.);
  } else if (a_index == 2.0) {
    offsetPx += halfSizePx;
  } else {
    offsetPx += halfSizePx * vec2(-1., 1.);
  }
  float angle = ${this.symbolRotationExpression_};
  ${this.symbolRotateWithView_?"angle += u_rotation;":""}
  float c = cos(-angle);
  float s = sin(-angle);
  offsetPx = vec2(c * offsetPx.x - s * offsetPx.y, s * offsetPx.x + c * offsetPx.y);
  vec4 center = u_projectionMatrix * vec4(a_position, 0.0, 1.0);
  gl_Position = center + vec4(pxToScreen(offsetPx), u_depth, 0.);
  vec4 texCoord = ${this.texCoordExpression_};
  float u = a_index == 0.0 || a_index == 3.0 ? texCoord.s : texCoord.p;
  float v = a_index == 2.0 || a_index == 3.0 ? texCoord.t : texCoord.q;
  v_texCoord = vec2(u, v);
  v_prop_hitColor = a_prop_hitColor;
  v_angle = angle;
  c = cos(-v_angle);
  s = sin(-v_angle);
  centerOffsetPx = vec2(c * centerOffsetPx.x - s * centerOffsetPx.y, s * centerOffsetPx.x + c * centerOffsetPx.y); 
  v_centerPx = screenToPx(center.xy) + centerOffsetPx;
${this.varyings_.map(function(e){return"  "+e.name+" = "+e.expression+";"}).join(`
`)}
}`:null}getSymbolFragmentShader(){return this.hasSymbol_?`${sr}
${this.uniforms_.map(function(e){return"uniform "+e+";"}).join(`
`)}
varying vec2 v_texCoord;
varying vec4 v_prop_hitColor;
varying vec2 v_centerPx;
varying float v_angle;
varying vec2 v_quadSizePx;
${this.varyings_.map(function(e){return"varying "+e.type+" "+e.name+";"}).join(`
`)}
${this.fragmentShaderFunctions_.join(`
`)}

void main(void) {
  if (${this.discardExpression_}) { discard; }
  vec2 coordsPx = gl_FragCoord.xy / u_pixelRatio - v_centerPx; // relative to center
  float c = cos(v_angle);
  float s = sin(v_angle);
  coordsPx = vec2(c * coordsPx.x - s * coordsPx.y, s * coordsPx.x + c * coordsPx.y);
  gl_FragColor = ${this.symbolColorExpression_};
  if (u_hitDetection > 0) {
    if (gl_FragColor.a < 0.05) { discard; };
    gl_FragColor = v_prop_hitColor;
  }
}`:null}getStrokeVertexShader(){return this.hasStroke_?`${sr}
${this.uniforms_.map(function(e){return"uniform "+e+";"}).join(`
`)}
attribute vec2 a_position;
attribute float a_index;
attribute vec2 a_segmentStart;
attribute vec2 a_segmentEnd;
attribute float a_parameters;
attribute float a_distance;
attribute vec2 a_joinAngles;
attribute vec4 a_prop_hitColor;
${this.attributes_.map(function(e){return"attribute "+e+";"}).join(`
`)}
varying vec2 v_segmentStart;
varying vec2 v_segmentEnd;
varying float v_angleStart;
varying float v_angleEnd;
varying float v_width;
varying vec4 v_prop_hitColor;
varying float v_distanceOffsetPx;
${this.varyings_.map(function(e){return"varying "+e.type+" "+e.name+";"}).join(`
`)}
${this.vertexShaderFunctions_.join(`
`)}
vec2 worldToPx(vec2 worldPos) {
  vec4 screenPos = u_projectionMatrix * vec4(worldPos, 0.0, 1.0);
  return (0.5 * screenPos.xy + 0.5) * u_viewportSizePx;
}

vec4 pxToScreen(vec2 pxPos) {
  vec2 screenPos = 2.0 * pxPos / u_viewportSizePx - 1.0;
  return vec4(screenPos, u_depth, 1.0);
}

bool isCap(float joinAngle) {
  return joinAngle < -0.1;
}

vec2 getJoinOffsetDirection(vec2 normalPx, float joinAngle) {
  float halfAngle = joinAngle / 2.0;
  float c = cos(halfAngle);
  float s = sin(halfAngle);
  vec2 angleBisectorNormal = vec2(s * normalPx.x + c * normalPx.y, -c * normalPx.x + s * normalPx.y);
  float length = 1.0 / s;
  return angleBisectorNormal * length;
}

vec2 getOffsetPoint(vec2 point, vec2 normal, float joinAngle, float offsetPx) {
  // if on a cap or the join angle is too high, offset the line along the segment normal
  if (cos(joinAngle) > 0.998 || isCap(joinAngle)) {
    return point - normal * offsetPx;
  }
  // offset is applied along the inverted normal (positive offset goes "right" relative to line direction)
  return point - getJoinOffsetDirection(normal, joinAngle) * offsetPx;
}

void main(void) {
  v_angleStart = a_joinAngles.x;
  v_angleEnd = a_joinAngles.y;
  float vertexNumber = floor(abs(a_parameters) / 10000. + 0.5);
  // we're reading the fractional part while keeping the sign (so -4.12 gives -0.12, 3.45 gives 0.45)
  float angleTangentSum = fract(abs(a_parameters) / 10000.) * 10000. * sign(a_parameters);

  float lineWidth = ${this.strokeWidthExpression_};
  float lineOffsetPx = ${this.strokeOffsetExpression_};

  // compute segment start/end in px with offset
  vec2 segmentStartPx = worldToPx(a_segmentStart);
  vec2 segmentEndPx = worldToPx(a_segmentEnd);
  vec2 tangentPx = normalize(segmentEndPx - segmentStartPx);
  vec2 normalPx = vec2(-tangentPx.y, tangentPx.x);
  segmentStartPx = getOffsetPoint(segmentStartPx, normalPx, v_angleStart, lineOffsetPx),
  segmentEndPx = getOffsetPoint(segmentEndPx, normalPx, v_angleEnd, lineOffsetPx);
  
  // compute current vertex position
  float normalDir = vertexNumber < 0.5 || (vertexNumber > 1.5 && vertexNumber < 2.5) ? 1.0 : -1.0;
  float tangentDir = vertexNumber < 1.5 ? 1.0 : -1.0;
  float angle = vertexNumber < 1.5 ? v_angleStart : v_angleEnd;
  vec2 joinDirection;
  vec2 positionPx = vertexNumber < 1.5 ? segmentStartPx : segmentEndPx;
  // if angle is too high, do not make a proper join
  if (cos(angle) > 0.985 || isCap(angle)) {
    joinDirection = normalPx * normalDir - tangentPx * tangentDir;
  } else {
    joinDirection = getJoinOffsetDirection(normalPx * normalDir, angle);
  }
  positionPx = positionPx + joinDirection * (lineWidth * 0.5 + 1.); // adding 1 pixel for antialiasing
  gl_Position = pxToScreen(positionPx);

  v_segmentStart = segmentStartPx;
  v_segmentEnd = segmentEndPx;
  v_width = lineWidth;
  v_prop_hitColor = a_prop_hitColor;
  v_distanceOffsetPx = a_distance / u_resolution - (lineOffsetPx * angleTangentSum);
${this.varyings_.map(function(e){return"  "+e.name+" = "+e.expression+";"}).join(`
`)}
}`:null}getStrokeFragmentShader(){return this.hasStroke_?`${sr}
${this.uniforms_.map(function(e){return"uniform "+e+";"}).join(`
`)}
varying vec2 v_segmentStart;
varying vec2 v_segmentEnd;
varying float v_angleStart;
varying float v_angleEnd;
varying float v_width;
varying vec4 v_prop_hitColor;
varying float v_distanceOffsetPx;
${this.varyings_.map(function(e){return"varying "+e.type+" "+e.name+";"}).join(`
`)}
${this.fragmentShaderFunctions_.join(`
`)}

vec2 pxToWorld(vec2 pxPos) {
  vec2 screenPos = 2.0 * pxPos / u_viewportSizePx - 1.0;
  return (u_screenToWorldMatrix * vec4(screenPos, 0.0, 1.0)).xy;
}

bool isCap(float joinAngle) {
  return joinAngle < -0.1;
}

float segmentDistanceField(vec2 point, vec2 start, vec2 end, float width) {
  vec2 tangent = normalize(end - start);
  vec2 normal = vec2(-tangent.y, tangent.x);
  vec2 startToPoint = point - start;
  return abs(dot(startToPoint, normal)) - width * 0.5;
}

float buttCapDistanceField(vec2 point, vec2 start, vec2 end) {
  vec2 startToPoint = point - start;
  vec2 tangent = normalize(end - start);
  return dot(startToPoint, -tangent);
}

float squareCapDistanceField(vec2 point, vec2 start, vec2 end, float width) {
  return buttCapDistanceField(point, start, end) - width * 0.5;
}

float roundCapDistanceField(vec2 point, vec2 start, vec2 end, float width) {
  float onSegment = max(0., 1000. * dot(point - start, end - start)); // this is very high when inside the segment
  return length(point - start) - width * 0.5 - onSegment;
}

float roundJoinDistanceField(vec2 point, vec2 start, vec2 end, float width) {
  return roundCapDistanceField(point, start, end, width);
}

float bevelJoinField(vec2 point, vec2 start, vec2 end, float width, float joinAngle) {
  vec2 startToPoint = point - start;
  vec2 tangent = normalize(end - start);
  float c = cos(joinAngle * 0.5);
  float s = sin(joinAngle * 0.5);
  float direction = -sign(sin(joinAngle));
  vec2 bisector = vec2(c * tangent.x - s * tangent.y, s * tangent.x + c * tangent.y);
  float radius = width * 0.5 * s;
  return dot(startToPoint, bisector * direction) - radius;
}

float miterJoinDistanceField(vec2 point, vec2 start, vec2 end, float width, float joinAngle) {
  if (cos(joinAngle) > 0.985) { // avoid risking a division by zero
    return bevelJoinField(point, start, end, width, joinAngle);
  }
  float miterLength = 1. / sin(joinAngle * 0.5);
  float miterLimit = ${this.strokeMiterLimitExpression_};
  if (miterLength > miterLimit) {
    return bevelJoinField(point, start, end, width, joinAngle);
  }
  return -1000.;
}

float capDistanceField(vec2 point, vec2 start, vec2 end, float width, float capType) {
   if (capType == ${Tn("butt")}) {
    return buttCapDistanceField(point, start, end);
  } else if (capType == ${Tn("square")}) {
    return squareCapDistanceField(point, start, end, width);
  }
  return roundCapDistanceField(point, start, end, width);
}

float joinDistanceField(vec2 point, vec2 start, vec2 end, float width, float joinAngle, float joinType) {
  if (joinType == ${Tn("bevel")}) {
    return bevelJoinField(point, start, end, width, joinAngle);
  } else if (joinType == ${Tn("miter")}) {
    return miterJoinDistanceField(point, start, end, width, joinAngle);
  }
  return roundJoinDistanceField(point, start, end, width);
}

float computeSegmentPointDistance(vec2 point, vec2 start, vec2 end, float width, float joinAngle, float capType, float joinType) {
  if (isCap(joinAngle)) {
    return capDistanceField(point, start, end, width, capType);
  }
  return joinDistanceField(point, start, end, width, joinAngle, joinType);
}

void main(void) {
  vec2 currentPoint = gl_FragCoord.xy / u_pixelRatio;
  #ifdef GL_FRAGMENT_PRECISION_HIGH
  vec2 worldPos = pxToWorld(currentPoint);
  if (
    abs(u_renderExtent[0] - u_renderExtent[2]) > 0.0 && (
      worldPos[0] < u_renderExtent[0] ||
      worldPos[1] < u_renderExtent[1] ||
      worldPos[0] > u_renderExtent[2] ||
      worldPos[1] > u_renderExtent[3]
    )
  ) {
    discard;
  }
  #endif
  if (${this.discardExpression_}) { discard; }

  float segmentLength = length(v_segmentEnd - v_segmentStart);
  vec2 segmentTangent = (v_segmentEnd - v_segmentStart) / segmentLength;
  vec2 segmentNormal = vec2(-segmentTangent.y, segmentTangent.x);
  vec2 startToPoint = currentPoint - v_segmentStart;
  float currentLengthPx = max(0., min(dot(segmentTangent, startToPoint), segmentLength)) + v_distanceOffsetPx; 
  float currentRadiusPx = abs(dot(segmentNormal, startToPoint));
  float currentRadiusRatio = dot(segmentNormal, startToPoint) * 2. / v_width;
  vec4 color = ${this.strokeColorExpression_} * u_globalAlpha;
  float capType = ${this.strokeCapExpression_};
  float joinType = ${this.strokeJoinExpression_};
  float segmentStartDistance = computeSegmentPointDistance(currentPoint, v_segmentStart, v_segmentEnd, v_width, v_angleStart, capType, joinType);
  float segmentEndDistance = computeSegmentPointDistance(currentPoint, v_segmentEnd, v_segmentStart, v_width, v_angleEnd, capType, joinType);
  float distance = max(
    segmentDistanceField(currentPoint, v_segmentStart, v_segmentEnd, v_width),
    max(segmentStartDistance, segmentEndDistance)
  );
  distance = max(distance, ${this.strokeDistanceFieldExpression_});
  gl_FragColor = color * smoothstep(0.5, -0.5, distance);
  if (u_hitDetection > 0) {
    if (gl_FragColor.a < 0.1) { discard; };
    gl_FragColor = v_prop_hitColor;
  }
}`:null}getFillVertexShader(){return this.hasFill_?`${sr}
${this.uniforms_.map(function(e){return"uniform "+e+";"}).join(`
`)}
attribute vec2 a_position;
attribute vec4 a_prop_hitColor;
${this.attributes_.map(function(e){return"attribute "+e+";"}).join(`
`)}
varying vec4 v_prop_hitColor;
${this.varyings_.map(function(e){return"varying "+e.type+" "+e.name+";"}).join(`
`)}
${this.vertexShaderFunctions_.join(`
`)}
void main(void) {
  gl_Position = u_projectionMatrix * vec4(a_position, u_depth, 1.0);
  v_prop_hitColor = a_prop_hitColor;
${this.varyings_.map(function(e){return"  "+e.name+" = "+e.expression+";"}).join(`
`)}
}`:null}getFillFragmentShader(){return this.hasFill_?`${sr}
${this.uniforms_.map(function(e){return"uniform "+e+";"}).join(`
`)}
varying vec4 v_prop_hitColor;
${this.varyings_.map(function(e){return"varying "+e.type+" "+e.name+";"}).join(`
`)}
${this.fragmentShaderFunctions_.join(`
`)}
vec2 pxToWorld(vec2 pxPos) {
  vec2 screenPos = 2.0 * pxPos / u_viewportSizePx - 1.0;
  return (u_screenToWorldMatrix * vec4(screenPos, 0.0, 1.0)).xy;
}

vec2 worldToPx(vec2 worldPos) {
  vec4 screenPos = u_projectionMatrix * vec4(worldPos, 0.0, 1.0);
  return (0.5 * screenPos.xy + 0.5) * u_viewportSizePx;
}

void main(void) {
  vec2 pxPos = gl_FragCoord.xy / u_pixelRatio;
  vec2 pxOrigin = worldToPx(u_patternOrigin);
  #ifdef GL_FRAGMENT_PRECISION_HIGH
  vec2 worldPos = pxToWorld(pxPos);
  if (
    abs(u_renderExtent[0] - u_renderExtent[2]) > 0.0 && (
      worldPos[0] < u_renderExtent[0] ||
      worldPos[1] < u_renderExtent[1] ||
      worldPos[0] > u_renderExtent[2] ||
      worldPos[1] > u_renderExtent[3]
    )
  ) {
    discard;
  }
  #endif
  if (${this.discardExpression_}) { discard; }
  gl_FragColor = ${this.fillColorExpression_} * u_globalAlpha;
  if (u_hitDetection > 0) {
    if (gl_FragColor.a < 0.1) { discard; };
    gl_FragColor = v_prop_hitColor;
  }
}`:null}};function de(e,t,n){return function(i,r,s,o){return Pu(rt(i,r,s),r,o)}(t,n,mu(),e)}function $f(e){const t=Zn(e);return[256*t[0]+t[1],256*t[2]+Math.round(255*t[3])]}function qf(e){return e===Ge||e===Jt?2:e===xt?4:1}function Iu(e){const t=qf(e);return t>1?`vec${t}`:"float"}function xa(e){return(JSON.stringify(e).split("").reduce((t,n)=>(t<<5)-t+n.charCodeAt(0),0)>>>0).toString()}function Mu(e,t,n,i){if(`${i}radius`in e&&i!=="icon-"){let r=de(n,e[`${i}radius`],re);`${i}radius2`in e&&(r=`max(${r}, ${de(n,e[`${i}radius2`],re)})`),`${i}stroke-width`in e&&(r=`(${r} + ${de(n,e[`${i}stroke-width`],re)} * 0.5)`),t.setSymbolSizeExpression(`vec2(${r} * 2. + 0.5)`)}if(`${i}scale`in e){const r=de(n,e[`${i}scale`],Jt);t.setSymbolSizeExpression(`${t.getSymbolSizeExpression()} * ${r}`)}`${i}displacement`in e&&t.setSymbolOffsetExpression(de(n,e[`${i}displacement`],xt)),`${i}rotation`in e&&t.setSymbolRotationExpression(de(n,e[`${i}rotation`],re)),`${i}rotate-with-view`in e&&t.setSymbolRotateWithView(!!e[`${i}rotate-with-view`])}function Xf(e,t,n,i,r){let s="vec4(0.)";t!==null&&(s=t),n!==null&&i!==null&&(s=`mix(${n}, ${s}, ${`smoothstep(-${i} + 0.63, -${i} - 0.58, ${e})`})`);let o=`${s} * ${`(1.0 - smoothstep(-0.63, 0.58, ${e}))`}`;return r!==null&&(o=`${o} * ${r}`),o}function Lu(e,t,n,i,r){const s=new Image;let o;return s.crossOrigin=e[`${i}cross-origin`]===void 0?"anonymous":e[`${i}cross-origin`],s.src=e[`${i}src`],s.complete&&s.width&&s.height?o=_a([s.width,s.height]):(n[`u_texture${r}_size`]=()=>s.complete?[s.width,s.height]:[0,0],t.addUniform(`vec2 u_texture${r}_size`),o=`u_texture${r}_size`),n[`u_texture${r}`]=s,t.addUniform(`sampler2D u_texture${r}`),o}function Fu(e,t,n,i,r){let s=de(n,e[`${t}offset`],xt);if(`${t}offset-origin`in e)switch(e[`${t}offset-origin`]){case"top-right":s=`vec2(${i}.x, 0.) + ${r} * vec2(-1., 0.) + ${s} * vec2(-1., 1.)`;break;case"bottom-left":s=`vec2(0., ${i}.y) + ${r} * vec2(0., -1.) + ${s} * vec2(1., -1.)`;break;case"bottom-right":s=`${i} - ${r} - ${s}`}return s}function Xy(e){const t={inFragmentShader:!1,properties:{},variables:{},functions:{},style:e},n={inFragmentShader:!0,variables:t.variables,properties:{},functions:{},style:e},i=new qy,r={};if("icon-src"in e?function(o,a,l,c,u){let h="vec4(1.0)";"icon-color"in o&&(h=de(u,o["icon-color"],Ge)),"icon-opacity"in o&&(h=`${h} * ${de(u,o["icon-opacity"],re)}`);const p=xa(o["icon-src"]),f=Lu(o,a,l,"icon-",p);if(a.setSymbolColorExpression(`${h} * samplePremultiplied(u_texture${p}, v_texCoord)`).setSymbolSizeExpression(f),"icon-width"in o&&"icon-height"in o&&a.setSymbolSizeExpression(`vec2(${de(c,o["icon-width"],re)}, ${de(c,o["icon-height"],re)})`),"icon-offset"in o&&"icon-size"in o){const m=de(c,o["icon-size"],xt),_=a.getSymbolSizeExpression();a.setSymbolSizeExpression(m);const y=Fu(o,"icon-",c,"v_quadSizePx",m);a.setTextureCoordinateExpression(`(vec4((${y}).xyxy) + vec4(0., 0., ${m})) / (${_}).xyxy`)}if(Mu(o,a,c,"icon-"),"icon-anchor"in o){const m=de(c,o["icon-anchor"],xt);let _,y="1.0";"icon-scale"in o&&(y=de(c,o["icon-scale"],Jt)),_=o["icon-anchor-x-units"]==="pixels"&&o["icon-anchor-y-units"]==="pixels"?`${m} * ${y}`:o["icon-anchor-x-units"]==="pixels"?`${m} * vec2(vec2(${y}).x, v_quadSizePx.y)`:o["icon-anchor-y-units"]==="pixels"?`${m} * vec2(v_quadSizePx.x, vec2(${y}).x)`:`${m} * v_quadSizePx`;let x=`v_quadSizePx * vec2(0.5, -0.5) + ${_} * vec2(-1., 1.)`;if("icon-anchor-origin"in o)switch(o["icon-anchor-origin"]){case"top-right":x=`v_quadSizePx * -0.5 + ${_}`;break;case"bottom-left":x=`v_quadSizePx * 0.5 - ${_}`;break;case"bottom-right":x=`v_quadSizePx * vec2(-0.5, 0.5) + ${_} * vec2(1., -1.)`}a.setSymbolOffsetExpression(`${a.getSymbolOffsetExpression()} + ${x}`)}}(e,i,r,t,n):"shape-points"in e?function(o,a,l,c,u){u.functions.round=`float round(float v) {
  return sign(v) * floor(abs(v) + 0.5);
}`,u.functions.starDistanceField=`float starDistanceField(vec2 point, float numPoints, float radius, float radius2, float angle) {
  float startAngle = -PI * 0.5 + angle; // tip starts upwards and rotates clockwise with angle
  float c = cos(startAngle);
  float s = sin(startAngle);
  vec2 pointRotated = vec2(c * point.x - s * point.y, s * point.x + c * point.y);
  float alpha = TWO_PI / numPoints; // the angle of one sector
  float beta = atan(pointRotated.y, pointRotated.x);
  float gamma = round(beta / alpha) * alpha; // angle in sector
  c = cos(-gamma);
  s = sin(-gamma);
  vec2 inSector = vec2(c * pointRotated.x - s * pointRotated.y, abs(s * pointRotated.x + c * pointRotated.y));
  vec2 tipToPoint = inSector + vec2(-radius, 0.);
  vec2 edgeNormal = vec2(radius2 * sin(alpha * 0.5), -radius2 * cos(alpha * 0.5) + radius);
  return dot(normalize(edgeNormal), tipToPoint);
}`,u.functions.regularDistanceField=`float regularDistanceField(vec2 point, float numPoints, float radius, float angle) {
  float startAngle = -PI * 0.5 + angle; // tip starts upwards and rotates clockwise with angle
  float c = cos(startAngle);
  float s = sin(startAngle);
  vec2 pointRotated = vec2(c * point.x - s * point.y, s * point.x + c * point.y);
  float alpha = TWO_PI / numPoints; // the angle of one sector
  float radiusIn = radius * cos(PI / numPoints);
  float beta = atan(pointRotated.y, pointRotated.x);
  float gamma = round((beta - alpha * 0.5) / alpha) * alpha + alpha * 0.5; // angle in sector from mid
  c = cos(-gamma);
  s = sin(-gamma);
  vec2 inSector = vec2(c * pointRotated.x - s * pointRotated.y, abs(s * pointRotated.x + c * pointRotated.y));
  return inSector.x - radiusIn;
}`,Mu(o,a,c,"shape-");let h=null;"shape-opacity"in o&&(h=de(u,o["shape-opacity"],re));let p="coordsPx";"shape-scale"in o&&(p=`coordsPx / ${de(u,o["shape-scale"],Jt)}`);let f=null;"shape-fill-color"in o&&(f=de(u,o["shape-fill-color"],Ge));let m=null;"shape-stroke-color"in o&&(m=de(u,o["shape-stroke-color"],Ge));let _=null;"shape-stroke-width"in o&&(_=de(u,o["shape-stroke-width"],re));const y=de(u,o["shape-points"],re);let x="0.";"shape-angle"in o&&(x=de(u,o["shape-angle"],re));let w,T=de(u,o["shape-radius"],re);if(_!==null&&(T=`${T} + ${_} * 0.5`),"shape-radius2"in o){let b=de(u,o["shape-radius2"],re);_!==null&&(b=`${b} + ${_} * 0.5`),w=`starDistanceField(${p}, ${y}, ${T}, ${b}, ${x})`}else w=`regularDistanceField(${p}, ${y}, ${T}, ${x})`;const R=Xf(w,f,m,_,h);a.setSymbolColorExpression(R)}(e,i,0,t,n):"circle-radius"in e&&function(o,a,l,c,u){u.functions.circleDistanceField=`float circleDistanceField(vec2 point, float radius) {
  return length(point) - radius;
}`,Mu(o,a,c,"circle-");let h=null;"circle-opacity"in o&&(h=de(u,o["circle-opacity"],re));let p="coordsPx";"circle-scale"in o&&(p=`coordsPx / ${de(u,o["circle-scale"],Jt)}`);let f=null;"circle-fill-color"in o&&(f=de(u,o["circle-fill-color"],Ge));let m=null;"circle-stroke-color"in o&&(m=de(u,o["circle-stroke-color"],Ge));let _=de(u,o["circle-radius"],re),y=null;"circle-stroke-width"in o&&(y=de(u,o["circle-stroke-width"],re),_=`(${_} + ${y} * 0.5)`);const x=Xf(`circleDistanceField(${p}, ${_})`,f,m,y,h);a.setSymbolColorExpression(x)}(e,i,0,t,n),function(o,a,l,c,u){if("stroke-color"in o&&a.setStrokeColorExpression(de(u,o["stroke-color"],Ge)),"stroke-pattern-src"in o){const h=xa(o["stroke-pattern-src"]),p=Lu(o,a,l,"stroke-pattern-",h);let f=p,m="vec2(0.)";"stroke-pattern-offset"in o&&"stroke-pattern-size"in o&&(f=de(u,o["stroke-pattern-size"],xt),m=Fu(o,"stroke-pattern-",u,p,f));let _="0.";"stroke-pattern-spacing"in o&&(_=de(u,o["stroke-pattern-spacing"],re)),u.functions.sampleStrokePattern=`vec4 sampleStrokePattern(sampler2D texture, vec2 textureSize, vec2 textureOffset, vec2 sampleSize, float spacingPx, float currentLengthPx, float currentRadiusRatio, float lineWidth) {
  float currentLengthScaled = currentLengthPx * sampleSize.y / lineWidth;
  float spacingScaled = spacingPx * sampleSize.y / lineWidth;
  float uCoordPx = mod(currentLengthScaled, (sampleSize.x + spacingScaled));
  // make sure that we're not sampling too close to the borders to avoid interpolation with outside pixels
  uCoordPx = clamp(uCoordPx, 0.5, sampleSize.x - 0.5);
  float vCoordPx = (-currentRadiusRatio * 0.5 + 0.5) * sampleSize.y;
  vec2 texCoord = (vec2(uCoordPx, vCoordPx) + textureOffset) / textureSize;
  return samplePremultiplied(texture, texCoord);
}`;const y=`u_texture${h}`;let x="1.";"stroke-color"in o&&(x=a.getStrokeColorExpression()),a.setStrokeColorExpression(`${x} * sampleStrokePattern(${y}, ${p}, ${m}, ${f}, ${_}, currentLengthPx, currentRadiusRatio, v_width)`)}if("stroke-width"in o&&a.setStrokeWidthExpression(de(c,o["stroke-width"],re)),"stroke-offset"in o&&a.setStrokeOffsetExpression(de(c,o["stroke-offset"],re)),"stroke-line-cap"in o&&a.setStrokeCapExpression(de(c,o["stroke-line-cap"],it)),"stroke-line-join"in o&&a.setStrokeJoinExpression(de(c,o["stroke-line-join"],it)),"stroke-miter-limit"in o&&a.setStrokeMiterLimitExpression(de(c,o["stroke-miter-limit"],re)),"stroke-line-dash"in o){u.functions.getSingleDashDistance=`float getSingleDashDistance(float distance, float radius, float dashOffset, float dashLength, float dashLengthTotal, float capType) {
  float localDistance = mod(distance, dashLengthTotal);
  float distanceSegment = abs(localDistance - dashOffset - dashLength * 0.5) - dashLength * 0.5;
  distanceSegment = min(distanceSegment, dashLengthTotal - localDistance);
  if (capType == ${Tn("square")}) {
    distanceSegment -= v_width * 0.5;
  } else if (capType == ${Tn("round")}) {
    distanceSegment = min(distanceSegment, sqrt(distanceSegment * distanceSegment + radius * radius) - v_width * 0.5);
  }
  return distanceSegment;
}`;let h=o["stroke-line-dash"].map(w=>de(u,w,re));h.length%2==1&&(h=[...h,...h]);let p="0.";"stroke-line-dash-offset"in o&&(p=de(c,o["stroke-line-dash-offset"],re));const f=`dashDistanceField_${xa(o["stroke-line-dash"])}`,m=h.map((w,T)=>`float dashLength${T} = ${w};`),_=h.map((w,T)=>`dashLength${T}`).join(" + ");let y="0.",x=`getSingleDashDistance(distance, radius, ${y}, dashLength0, totalDashLength, capType)`;for(let w=2;w<h.length;w+=2)y=`${y} + dashLength${w-2} + dashLength${w-1}`,x=`min(${x}, getSingleDashDistance(distance, radius, ${y}, dashLength${w}, totalDashLength, capType))`;u.functions[f]=`float ${f}(float distance, float radius, float capType) {
  ${m.join(`
  `)}
  float totalDashLength = ${_};
  return ${x};
}`,a.setStrokeDistanceFieldExpression(`${f}(currentLengthPx + ${p}, currentRadiusPx, capType)`)}}(e,i,r,t,n),function(o,a,l,c,u){if("fill-color"in o&&a.setFillColorExpression(de(u,o["fill-color"],Ge)),"fill-pattern-src"in o){const h=xa(o["fill-pattern-src"]),p=Lu(o,a,l,"fill-pattern-",h);let f=p,m="vec2(0.)";"fill-pattern-offset"in o&&"fill-pattern-size"in o&&(f=de(u,o["fill-pattern-size"],xt),m=Fu(o,"fill-pattern-",u,p,f)),u.functions.sampleFillPattern=`vec4 sampleFillPattern(sampler2D texture, vec2 textureSize, vec2 textureOffset, vec2 sampleSize, vec2 pxOrigin, vec2 pxPosition) {
  float scaleRatio = pow(2., mod(u_zoom + 0.5, 1.) - 0.5);
  vec2 pxRelativePos = pxPosition - pxOrigin;
  // rotate the relative position from origin by the current view rotation
  pxRelativePos = vec2(pxRelativePos.x * cos(u_rotation) - pxRelativePos.y * sin(u_rotation), pxRelativePos.x * sin(u_rotation) + pxRelativePos.y * cos(u_rotation));
  // sample position is computed according to the sample offset & size
  vec2 samplePos = mod(pxRelativePos / scaleRatio, sampleSize);
  // also make sure that we're not sampling too close to the borders to avoid interpolation with outside pixels
  samplePos = clamp(samplePos, vec2(0.5), sampleSize - vec2(0.5));
  samplePos.y = sampleSize.y - samplePos.y; // invert y axis so that images appear upright
  return samplePremultiplied(texture, (samplePos + textureOffset) / textureSize);
}`;const _=`u_texture${h}`;let y="1.";"fill-color"in o&&(y=a.getFillColorExpression()),a.setFillColorExpression(`${y} * sampleFillPattern(${_}, ${p}, ${m}, ${f}, pxOrigin, pxPos)`)}}(e,i,r,0,n),e.filter){const o=de(n,e.filter,ct);i.setFragmentDiscardExpression(`!${o}`)}for(const o in n.variables){const a=n.variables[o],l=Ru(a.name);i.addUniform(`${Iu(a.type)} ${l}`),r[l]=()=>{const c=e.variables[a.name];return typeof c=="number"?c:typeof c=="boolean"?c?1:0:a.type===Ge?$f([...Zn(c||"#eee")]):typeof c=="string"?ba(c):c}}for(const o in n.properties){const a=n.properties[o];t.properties[o]||(t.properties[o]=a);let l=Iu(a.type),c=`a_prop_${a.name}`;a.type===Ge&&(l="vec4",c=`unpackColor(${c})`,i.addVertexShaderFunction(`vec4 unpackColor(vec2 packedColor) {
  return fract(packedColor[1] / 256.0) * vec4(
    fract(floor(packedColor[0] / 256.0) / 256.0),
    fract(packedColor[0] / 256.0),
    fract(floor(packedColor[1] / 256.0) / 256.0),
    1.0
  );
}`)),i.addVarying(`v_prop_${a.name}`,l,c)}for(const o in t.properties){const a=t.properties[o];i.addAttribute(`${Iu(a.type)} a_prop_${a.name}`)}for(const o in t.functions)i.addVertexShaderFunction(t.functions[o]);for(const o in n.functions)i.addFragmentShaderFunction(n.functions[o]);const s={};for(const o in t.properties){const a=t.properties[o];let l;l=a.evaluator?a.evaluator:c=>{const u=c.get(a.name);return a.type===Ge?$f([...Zn(u||"#eee")]):typeof u=="string"?ba(u):typeof u=="boolean"?u?1:0:u},s[a.name]={size:qf(a.type),callback:l}}return{builder:i,attributes:s,uniforms:r}}function Wf(e,t){const n=`
    attribute vec2 ${Gs};
    uniform mat4 ${me.TILE_TRANSFORM};
    uniform float ${me.TEXTURE_PIXEL_WIDTH};
    uniform float ${me.TEXTURE_PIXEL_HEIGHT};
    uniform float ${me.TEXTURE_RESOLUTION};
    uniform float ${me.TEXTURE_ORIGIN_X};
    uniform float ${me.TEXTURE_ORIGIN_Y};
    uniform float ${me.DEPTH};

    varying vec2 v_textureCoord;
    varying vec2 v_mapCoord;

    void main() {
      v_textureCoord = ${Gs};
      v_mapCoord = vec2(
        ${me.TEXTURE_ORIGIN_X} + ${me.TEXTURE_RESOLUTION} * ${me.TEXTURE_PIXEL_WIDTH} * v_textureCoord[0],
        ${me.TEXTURE_ORIGIN_Y} - ${me.TEXTURE_RESOLUTION} * ${me.TEXTURE_PIXEL_HEIGHT} * v_textureCoord[1]
      );
      gl_Position = ${me.TILE_TRANSFORM} * vec4(${Gs}, ${me.DEPTH}, 1.0);
    }
  `,i={inFragmentShader:!1,variables:{},properties:{},functions:{},bandCount:0,style:{},inFragmentShader:!0,bandCount:t,style:e},r=[];if(e.color!==void 0){const u=de(i,e.color,Ge);r.push(`color = ${u};`)}if(e.contrast!==void 0){const u=de(i,e.contrast,re);r.push(`color.rgb = clamp((${u} + 1.0) * color.rgb - (${u} / 2.0), vec3(0.0, 0.0, 0.0), vec3(1.0, 1.0, 1.0));`)}if(e.exposure!==void 0){const u=de(i,e.exposure,re);r.push(`color.rgb = clamp((${u} + 1.0) * color.rgb, vec3(0.0, 0.0, 0.0), vec3(1.0, 1.0, 1.0));`)}if(e.saturation!==void 0){const u=de(i,e.saturation,re);r.push(`
      float saturation = ${u} + 1.0;
      float sr = (1.0 - saturation) * 0.2126;
      float sg = (1.0 - saturation) * 0.7152;
      float sb = (1.0 - saturation) * 0.0722;
      mat3 saturationMatrix = mat3(
        sr + saturation, sr, sr,
        sg, sg + saturation, sg,
        sb, sb, sb + saturation
      );
      color.rgb = clamp(saturationMatrix * color.rgb, vec3(0.0, 0.0, 0.0), vec3(1.0, 1.0, 1.0));
    `)}if(e.gamma!==void 0){const u=de(i,e.gamma,re);r.push(`color.rgb = pow(color.rgb, vec3(1.0 / ${u}));`)}if(e.brightness!==void 0){const u=de(i,e.brightness,re);r.push(`color.rgb = clamp(color.rgb + ${u}, vec3(0.0, 0.0, 0.0), vec3(1.0, 1.0, 1.0));`)}const s={},o=Object.keys(i.variables).length;if(o>1&&!e.variables)throw new Error(`Missing variables in style (expected ${i.variables})`);for(let u=0;u<o;++u){const h=i.variables[Object.keys(i.variables)[u]];if(!(h.name in e.variables))throw new Error(`Missing '${h.name}' in style variables`);s[Ru(h.name)]=function(){let p=e.variables[h.name];return typeof p=="string"&&(p=ba(p)),p!==void 0?p:-9999999}}const a=Object.keys(s).map(function(u){return`uniform float ${u};`}),l=Math.ceil(t/4);a.push(`uniform sampler2D ${me.TILE_TEXTURE_ARRAY}[${l}];`),i.paletteTextures&&a.push(`uniform sampler2D ${Vf}[${i.paletteTextures.length}];`);const c=Object.keys(i.functions).map(function(u){return i.functions[u]});return{vertexShader:n,fragmentShader:`
    #ifdef GL_FRAGMENT_PRECISION_HIGH
    precision highp float;
    #else
    precision mediump float;
    #endif

    varying vec2 v_textureCoord;
    varying vec2 v_mapCoord;
    uniform vec4 ${me.RENDER_EXTENT};
    uniform float ${me.TRANSITION_ALPHA};
    uniform float ${me.TEXTURE_PIXEL_WIDTH};
    uniform float ${me.TEXTURE_PIXEL_HEIGHT};
    uniform float ${me.RESOLUTION};
    uniform float ${me.ZOOM};

    ${a.join(`
`)}

    ${c.join(`
`)}

    void main() {
      if (
        v_mapCoord[0] < ${me.RENDER_EXTENT}[0] ||
        v_mapCoord[1] < ${me.RENDER_EXTENT}[1] ||
        v_mapCoord[0] > ${me.RENDER_EXTENT}[2] ||
        v_mapCoord[1] > ${me.RENDER_EXTENT}[3]
      ) {
        discard;
      }

      vec4 color = texture2D(${me.TILE_TEXTURE_ARRAY}[0],  v_textureCoord);

      ${r.join(`
`)}

      gl_FragColor = color;
      gl_FragColor.rgb *= gl_FragColor.a;
      gl_FragColor *= ${me.TRANSITION_ALPHA};
    }`,uniforms:s,paletteTextures:i.paletteTextures}}let Yf=class extends ay{constructor(e){const t=(e=e?Object.assign({},e):{}).style||{};delete e.style,super(e),this.sources_=e.sources,this.renderedSource_=null,this.renderedResolution_=NaN,this.style_=t,this.styleVariables_=this.style_.variables||{},this.addChangeListener(ps,this.handleSourceUpdate_)}getSources(e,t){const n=this.getSource();return this.sources_?typeof this.sources_=="function"?this.sources_(e,t):this.sources_:n?[n]:[]}getRenderSource(){return this.renderedSource_||this.getSource()}getSourceState(){const e=this.getRenderSource();return e?e.getState():"undefined"}handleSourceUpdate_(){this.hasRenderer()&&this.getRenderer().clearCache(),this.getSource()&&this.setStyle(this.style_)}getSourceBandCount_(){const e=Number.MAX_SAFE_INTEGER,t=this.getSources([-e,-e,e,e],e);return t&&t.length&&"bandCount"in t[0]?t[0].bandCount:4}createRenderer(){const e=Wf(this.style_,this.getSourceBandCount_());return new Dy(this,{vertexShader:e.vertexShader,fragmentShader:e.fragmentShader,uniforms:e.uniforms,cacheSize:this.getCacheSize(),paletteTextures:e.paletteTextures})}renderSources(e,t){const n=this.getRenderer();let i;for(let r=0,s=t.length;r<s;++r)this.renderedSource_=t[r],n.prepareFrame(e)&&(i=n.renderFrame(e));return i}render(e,t){this.rendered=!0;const n=e.viewState,i=this.getSources(e.extent,n.resolution);let r=!0;for(let o=0,a=i.length;o<a;++o){const l=i[o],c=l.getState();if(c=="loading"){const u=()=>{l.getState()=="ready"&&(l.removeEventListener("change",u),this.changed())};l.addEventListener("change",u)}r=r&&c=="ready"}const s=this.renderSources(e,i);if(this.getRenderer().renderComplete&&r)return this.renderedResolution_=n.resolution,s;if(this.renderedResolution_>.5*n.resolution){const o=this.getSources(e.extent,this.renderedResolution_).filter(a=>!i.includes(a));if(o.length>0)return this.renderSources(e,o)}return s}setStyle(e){if(this.styleVariables_=e.variables||{},this.style_=e,this.hasRenderer()){const t=Wf(this.style_,this.getSourceBandCount_());this.getRenderer().reset({vertexShader:t.vertexShader,fragmentShader:t.fragmentShader,uniforms:t.uniforms,paletteTextures:t.paletteTextures}),this.changed()}}updateStyleVariables(e){Object.assign(this.styleVariables_,e),this.changed()}};function Ou(){const e={};return{on:(t,n)=>{(e[t]??(e[t]=[])).push(n)},off:(t,n)=>{e[t]=(e[t]??(e[t]=[])).filter(i=>i!==n)},emit:async(t,...n)=>{for(const i of e[t]??[])await i(...n)}}}Yf.prototype.dispose;const Wy={key:0,class:"vgo-pricing"},Yy={key:0,class:"vgo-pricing__strike"},Zy={class:"vgo-pricing__main"},Hy={key:0,class:"vgo-pricing__definition"},Ky={__name:"cb-price-strike-through",props:{price:{type:Object,required:!0},translations:{type:Object,required:!0}},setup:e=>(t,n)=>e.price.priceAndCurrency?(I(),O("div",Wy,[e.price.originalPriceAndCurrency?(I(),O("div",Yy,Z(e.translations.priceOriginal)+" "+Z(e.price.originalPriceAndCurrency),1)):ie("",!0),S("div",Zy,[S("b",{class:ve(["vgo-pricing__price",{"vgo-pricing__price--discount":e.price.originalPriceAndCurrency}])},[S("span",null,Z(e.translations.priceFrom),1),n[0]||(n[0]=je()),S("span",null,Z(e.price.priceAndCurrency),1)],2),e.price.priceDescription?(I(),O("span",Hy,Z(e.price.priceDescription),1)):ie("",!0)])])):ie("",!0)},Qy={key:0,class:"vgo-pricing"},Jy={class:"vgo-pricing__main"},eb={class:"vgo-pricing__price"},tb={key:0,class:"vgo-pricing__definition"},nb={key:0,class:"vgo-pricing__yousave"},ib={__name:"cb-price-you-save",props:{price:{type:Object,required:!0},translations:{type:Object,required:!0}},setup:e=>(t,n)=>e.price.priceAndCurrency?(I(),O("div",Qy,[S("div",Jy,[S("b",eb,[S("span",null,Z(e.translations.priceFrom),1),n[0]||(n[0]=je()),S("span",null,Z(e.price.priceAndCurrency),1)]),e.price.priceDescription?(I(),O("span",tb,Z(e.price.priceDescription),1)):ie("",!0)]),e.price.youSavePriceAndCurrency?(I(),O("div",nb,Z(e.translations.discount)+" "+Z(e.price.youSavePriceAndCurrency),1)):ie("",!0)])):ie("",!0)},Zf=["strike-through","you-save"],rb=e=>{switch(e){case"strike-through":return Ky;case"you-save":return ib;default:return null}},ob={class:"cb-loader-custom",role:"status"},sb={__name:"cb-loader",props:{loading:{type:Boolean}},setup:e=>(t,n)=>yt((I(),O("i",ob,n[0]||(n[0]=[S("i",null,[S("i"),S("i"),S("i"),S("i"),S("i")],-1)]),512)),[[Ft,e.loading]])},Hf=sb,un=(e,t)=>{const n=e.__vccOpts||e;for(const[i,r]of t)n[i]=r;return n},ab={key:0,class:"cb--loader"},lb={__name:"cb-product-map-loader",props:{loading:{type:Boolean,required:!0}},setup:e=>(t,n)=>e.loading?(I(),O("div",ab,[Q(D(Hf),{loading:!0})])):ie("",!0)},cb=un(lb,[["__scopeId","data-v-1157898c"]]);$n(`
.cb--loader[data-v-1157898c] {
        display: block;
        position: absolute;
        z-index: 1;
        top: 50%;
        left: 50%;
        transform: translate(-50%, -50%);
        width: 30px;
        height: 30px;
        border-radius: 50%;
        /*background-color: var(--vg-body-background-color);
	color: var(--vg-body-color);*/
}
`);const Du="postrender",ub="movestart",hb="moveend",Kf="loadstart",Qf="loadend",wa="ol-hidden",Ea="ol-unselectable",Uu="ol-control",Jf="ol-collapsed",Bu="element",zu="map",ju="offset",Ca="position",Nu="positioning";let Gu=class extends Kt{constructor(e){super(),this.on,this.once,this.un,this.options=e,this.id=e.id,this.insertFirst=e.insertFirst===void 0||e.insertFirst,this.stopEvent=e.stopEvent===void 0||e.stopEvent,this.element=document.createElement("div"),this.element.className=e.className!==void 0?e.className:"ol-overlay-container ol-selectable",this.element.style.position="absolute",this.element.style.pointerEvents="auto",this.autoPan=e.autoPan===!0?{}:e.autoPan||void 0,this.rendered={transform_:"",visible:!0},this.mapPostrenderListenerKey=null,this.addChangeListener(Bu,this.handleElementChanged),this.addChangeListener(zu,this.handleMapChanged),this.addChangeListener(ju,this.handleOffsetChanged),this.addChangeListener(Ca,this.handlePositionChanged),this.addChangeListener(Nu,this.handlePositioningChanged),e.element!==void 0&&this.setElement(e.element),this.setOffset(e.offset!==void 0?e.offset:[0,0]),this.setPositioning(e.positioning||"top-left"),e.position!==void 0&&this.setPosition(e.position)}getElement(){return this.get(Bu)}getId(){return this.id}getMap(){return this.get(zu)||null}getOffset(){return this.get(ju)}getPosition(){return this.get(Ca)}getPositioning(){return this.get(Nu)}handleElementChanged(){ef(this.element);const e=this.getElement();e&&this.element.appendChild(e)}handleMapChanged(){var e;this.mapPostrenderListenerKey&&((e=this.element)==null||e.remove(),Le(this.mapPostrenderListenerKey),this.mapPostrenderListenerKey=null);const t=this.getMap();if(t){this.mapPostrenderListenerKey=we(t,Du,this.render,this),this.updatePixelPosition();const n=this.stopEvent?t.getOverlayContainerStopEvent():t.getOverlayContainer();this.insertFirst?n.insertBefore(this.element,n.childNodes[0]||null):n.appendChild(this.element),this.performAutoPan()}}render(){this.updatePixelPosition()}handleOffsetChanged(){this.updatePixelPosition()}handlePositionChanged(){this.updatePixelPosition(),this.performAutoPan()}handlePositioningChanged(){this.updatePixelPosition()}setElement(e){this.set(Bu,e)}setMap(e){this.set(zu,e)}setOffset(e){this.set(ju,e)}setPosition(e){this.set(Ca,e)}performAutoPan(){this.autoPan&&this.panIntoView(this.autoPan)}panIntoView(e){const t=this.getMap();if(!t||!t.getTargetElement()||!this.get(Ca))return;const n=this.getRect(t.getTargetElement(),t.getSize()),i=this.getElement(),r=this.getRect(i,[dy(i),py(i)]),s=(e=e||{}).margin===void 0?20:e.margin;if(!xs(n,r)){const o=r[0]-n[0],a=n[2]-r[2],l=r[1]-n[1],c=n[3]-r[3],u=[0,0];if(o<0?u[0]=o-s:a<0&&(u[0]=Math.abs(a)+s),l<0?u[1]=l-s:c<0&&(u[1]=Math.abs(c)+s),u[0]!==0||u[1]!==0){const h=t.getView().getCenterInternal(),p=t.getPixelFromCoordinateInternal(h);if(!p)return;const f=[p[0]+u[0],p[1]+u[1]],m=e.animation||{};t.getView().animateInternal({center:t.getCoordinateFromPixelInternal(f),duration:m.duration,easing:m.easing})}}}getRect(e,t){const n=e.getBoundingClientRect(),i=n.left+window.pageXOffset,r=n.top+window.pageYOffset;return[i,r,i+t[0],r+t[1]]}setPositioning(e){this.set(Nu,e)}setVisible(e){this.rendered.visible!==e&&(this.element.style.display=e?"":"none",this.rendered.visible=e)}updatePixelPosition(){const e=this.getMap(),t=this.getPosition();if(!e||!e.isRendered()||!t)return void this.setVisible(!1);const n=e.getPixelFromCoordinate(t),i=e.getSize();this.updateRenderedPosition(n,i)}updateRenderedPosition(e,t){const n=this.element.style,i=this.getOffset(),r=this.getPositioning();this.setVisible(!0);let s="0%",o="0%";r=="bottom-right"||r=="center-right"||r=="top-right"?s="-100%":(r=="bottom-center"||r=="center-center"||r=="top-center")&&(s="-50%"),r=="bottom-left"||r=="bottom-center"||r=="bottom-right"?o="-100%":(r=="center-left"||r=="center-center"||r=="center-right")&&(o="-50%");const a=`translate(${s}, ${o}) translate(${Math.round(e[0]+i[0])+"px"}, ${Math.round(e[1]+i[1])+"px"})`;this.rendered.transform_!=a&&(this.rendered.transform_=a,n.transform=a)}getOptions(){return this.options}};const db={__name:"cb-ripple",props:{map:{type:Object,required:!0}},setup(e){const t=e,n=le(null),i=new Gu({stopEvent:!1,positioning:"center-center"});t.map.addOverlay(i);const r=s=>{if(t.map.getFeaturesAtPixel(s.pixel)[0])return;const o=i.getElement();o&&o.remove();var a=n.value.cloneNode(!0);a.classList.add("animate"),i.setElement(a),i.setPosition(s.coordinate)};return We(()=>{t.map.on("click",r)}),(s,o)=>(I(),O("div",{ref_key:"element",ref:n},null,512))}},pb=un(db,[["__scopeId","data-v-8fca4a96"]]);function e0(e,t,n=0,i=e.length-1,r=gb){for(;i>n;){if(i-n>600){const l=i-n+1,c=t-n+1,u=Math.log(l),h=.5*Math.exp(2*u/3),p=.5*Math.sqrt(u*h*(l-h)/l)*(c-l/2<0?-1:1);e0(e,t,Math.max(n,Math.floor(t-c*h/l+p)),Math.min(i,Math.floor(t+(l-c)*h/l+p)),r)}const s=e[t];let o=n,a=i;for(ro(e,n,t),r(e[i],s)>0&&ro(e,n,i);o<a;){for(ro(e,o,a),o++,a--;r(e[o],s)<0;)o++;for(;r(e[a],s)>0;)a--}r(e[n],s)===0?ro(e,n,a):(a++,ro(e,a,i)),a<=t&&(n=a+1),t<=a&&(i=a-1)}}function ro(e,t,n){const i=e[t];e[t]=e[n],e[n]=i}function gb(e,t){return e<t?-1:e>t?1:0}$n(`
div[data-v-8fca4a96] {
        width: 3px;
        height: 3px;
        opacity: 0;
        transform: scale(0);
        background: rgba(0, 0, 0, 0.5);
        border-radius: 50%;
        position: fixed;
        -webkit-user-select: none;
        user-select: none;
}
.animate[data-v-8fca4a96] {
        animation: ripple-8fca4a96 0.75s cubic-bezier(0, 0, 0.2, 1);
}
@keyframes ripple-8fca4a96 {
0% {
            transform: scale(0);
            opacity: 1;
}
100% {
            transform: scale(10);
            opacity: 0;
}
}
`);let t0=class{constructor(e=9){this._maxEntries=Math.max(4,e),this._minEntries=Math.max(2,Math.ceil(.4*this._maxEntries)),this.clear()}all(){return this._all(this.data,[])}search(e){let t=this.data;const n=[];if(!Sa(e,t))return n;const i=this.toBBox,r=[];for(;t;){for(let s=0;s<t.children.length;s++){const o=t.children[s],a=t.leaf?i(o):o;Sa(e,a)&&(t.leaf?n.push(o):$u(e,a)?this._all(o,n):r.push(o))}t=r.pop()}return n}collides(e){let t=this.data;if(!Sa(e,t))return!1;const n=[];for(;t;){for(let i=0;i<t.children.length;i++){const r=t.children[i],s=t.leaf?this.toBBox(r):r;if(Sa(e,s)){if(t.leaf||$u(e,s))return!0;n.push(r)}}t=n.pop()}return!1}load(e){if(!e||!e.length)return this;if(e.length<this._minEntries){for(let n=0;n<e.length;n++)this.insert(e[n]);return this}let t=this._build(e.slice(),0,e.length-1,0);if(this.data.children.length)if(this.data.height===t.height)this._splitRoot(this.data,t);else{if(this.data.height<t.height){const n=this.data;this.data=t,t=n}this._insert(t,this.data.height-t.height-1,!0)}else this.data=t;return this}insert(e){return e&&this._insert(e,this.data.height-1),this}clear(){return this.data=cr([]),this}remove(e,t){if(!e)return this;let n=this.data;const i=this.toBBox(e),r=[],s=[];let o,a,l;for(;n||r.length;){if(n||(n=r.pop(),a=r[r.length-1],o=s.pop(),l=!0),n.leaf){const c=fb(e,n.children,t);if(c!==-1)return n.children.splice(c,1),r.push(n),this._condense(r),this}l||n.leaf||!$u(n,i)?a?(o++,n=a.children[o],l=!1):n=null:(r.push(n),s.push(o),o=0,a=n,n=n.children[0])}return this}toBBox(e){return e}compareMinX(e,t){return e.minX-t.minX}compareMinY(e,t){return e.minY-t.minY}toJSON(){return this.data}fromJSON(e){return this.data=e,this}_all(e,t){const n=[];for(;e;)e.leaf?t.push(...e.children):n.push(...e.children),e=n.pop();return t}_build(e,t,n,i){const r=n-t+1;let s,o=this._maxEntries;if(r<=o)return s=cr(e.slice(t,n+1)),lr(s,this.toBBox),s;i||(i=Math.ceil(Math.log(r)/Math.log(o)),o=Math.ceil(r/Math.pow(o,i-1))),s=cr([]),s.leaf=!1,s.height=i;const a=Math.ceil(r/o),l=a*Math.ceil(Math.sqrt(o));n0(e,t,n,l,this.compareMinX);for(let c=t;c<=n;c+=l){const u=Math.min(c+l-1,n);n0(e,c,u,a,this.compareMinY);for(let h=c;h<=u;h+=a){const p=Math.min(h+a-1,u);s.children.push(this._build(e,h,p,i-1))}}return lr(s,this.toBBox),s}_chooseSubtree(e,t,n,i){for(;i.push(t),!t.leaf&&i.length-1!==n;){let r,s=1/0,o=1/0;for(let a=0;a<t.children.length;a++){const l=t.children[a],c=Vu(l),u=_b(e,l)-c;u<o?(o=u,s=c<s?c:s,r=l):u===o&&c<s&&(s=c,r=l)}t=r||t.children[0]}return t}_insert(e,t,n){const i=n?e:this.toBBox(e),r=[],s=this._chooseSubtree(i,this.data,t,r);for(s.children.push(e),so(s,i);t>=0&&r[t].children.length>this._maxEntries;)this._split(r,t),t--;this._adjustParentBBoxes(i,r,t)}_split(e,t){const n=e[t],i=n.children.length,r=this._minEntries;this._chooseSplitAxis(n,r,i);const s=this._chooseSplitIndex(n,r,i),o=cr(n.children.splice(s,n.children.length-s));o.height=n.height,o.leaf=n.leaf,lr(n,this.toBBox),lr(o,this.toBBox),t?e[t-1].children.push(o):this._splitRoot(n,o)}_splitRoot(e,t){this.data=cr([e,t]),this.data.height=e.height+1,this.data.leaf=!1,lr(this.data,this.toBBox)}_chooseSplitIndex(e,t,n){let i,r=1/0,s=1/0;for(let o=t;o<=n-t;o++){const a=oo(e,0,o,this.toBBox),l=oo(e,o,n,this.toBBox),c=yb(a,l),u=Vu(a)+Vu(l);c<r?(r=c,i=o,s=u<s?u:s):c===r&&u<s&&(s=u,i=o)}return i||n-t}_chooseSplitAxis(e,t,n){const i=e.leaf?this.compareMinX:mb,r=e.leaf?this.compareMinY:vb;this._allDistMargin(e,t,n,i)<this._allDistMargin(e,t,n,r)&&e.children.sort(i)}_allDistMargin(e,t,n,i){e.children.sort(i);const r=this.toBBox,s=oo(e,0,t,r),o=oo(e,n-t,n,r);let a=Aa(s)+Aa(o);for(let l=t;l<n-t;l++){const c=e.children[l];so(s,e.leaf?r(c):c),a+=Aa(s)}for(let l=n-t-1;l>=t;l--){const c=e.children[l];so(o,e.leaf?r(c):c),a+=Aa(o)}return a}_adjustParentBBoxes(e,t,n){for(let i=n;i>=0;i--)so(t[i],e)}_condense(e){for(let t,n=e.length-1;n>=0;n--)e[n].children.length===0?n>0?(t=e[n-1].children,t.splice(t.indexOf(e[n]),1)):this.clear():lr(e[n],this.toBBox)}};function fb(e,t,n){if(!n)return t.indexOf(e);for(let i=0;i<t.length;i++)if(n(e,t[i]))return i;return-1}function lr(e,t){oo(e,0,e.children.length,t,e)}function oo(e,t,n,i,r){r||(r=cr(null)),r.minX=1/0,r.minY=1/0,r.maxX=-1/0,r.maxY=-1/0;for(let s=t;s<n;s++){const o=e.children[s];so(r,e.leaf?i(o):o)}return r}function so(e,t){return e.minX=Math.min(e.minX,t.minX),e.minY=Math.min(e.minY,t.minY),e.maxX=Math.max(e.maxX,t.maxX),e.maxY=Math.max(e.maxY,t.maxY),e}function mb(e,t){return e.minX-t.minX}function vb(e,t){return e.minY-t.minY}function Vu(e){return(e.maxX-e.minX)*(e.maxY-e.minY)}function Aa(e){return e.maxX-e.minX+(e.maxY-e.minY)}function _b(e,t){return(Math.max(t.maxX,e.maxX)-Math.min(t.minX,e.minX))*(Math.max(t.maxY,e.maxY)-Math.min(t.minY,e.minY))}function yb(e,t){const n=Math.max(e.minX,t.minX),i=Math.max(e.minY,t.minY),r=Math.min(e.maxX,t.maxX),s=Math.min(e.maxY,t.maxY);return Math.max(0,r-n)*Math.max(0,s-i)}function $u(e,t){return e.minX<=t.minX&&e.minY<=t.minY&&t.maxX<=e.maxX&&t.maxY<=e.maxY}function Sa(e,t){return t.minX<=e.maxX&&t.minY<=e.maxY&&t.maxX>=e.minX&&t.maxY>=e.minY}function cr(e){return{children:e,height:1,leaf:!0,minX:1/0,minY:1/0,maxX:-1/0,maxY:-1/0}}function n0(e,t,n,i,r){const s=[t,n];for(;s.length;){if((n=s.pop())-(t=s.pop())<=i)continue;const o=t+Math.ceil((n-t)/i/2)*i;e0(e,o,t,n,r),s.push(t,o,o,n)}}let i0=class jm{constructor(t){this.opacity_=t.opacity,this.rotateWithView_=t.rotateWithView,this.rotation_=t.rotation,this.scale_=t.scale,this.scaleArray_=lt(t.scale),this.displacement_=t.displacement,this.declutterMode_=t.declutterMode}clone(){const t=this.getScale();return new jm({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 ue()}getImage(t){return ue()}getHitDetectionImage(){return ue()}getPixelRatio(t){return 1}getImageState(){return ue()}getImageSize(){return ue()}getOrigin(){return ue()}getSize(){return ue()}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_=lt(t)}listenImageChange(t){ue()}load(){ue()}unlistenImageChange(t){ue()}ready(){return Promise.resolve()}};function qu(e,t,n){return t+":"+e+":"+(n?Zn(n):"null")}const hn=new class{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 e=0;for(const t in this.cache_){const n=this.cache_[t];!(3&e++)&&!n.hasListener()&&(delete this.cache_[t],delete this.patternCache_[t],--this.cacheSize_)}}}get(e,t,n){const i=qu(e,t,n);return i in this.cache_?this.cache_[i]:null}getPattern(e,t,n){const i=qu(e,t,n);return i in this.patternCache_?this.patternCache_[i]:null}set(e,t,n,i,r){const s=qu(e,t,n),o=s in this.cache_;this.cache_[s]=i,r&&(i.getImageState()===Ei&&i.load(),i.getImageState()===nr?i.ready().then(()=>{this.patternCache_[s]=Qg().createPattern(i.getImage(1),"repeat")}):this.patternCache_[s]=Qg().createPattern(i.getImage(1),"repeat")),o||++this.cacheSize_}setSize(e){this.maxCacheSize_=e,this.expire()}};let ao=null,bb=class extends zr{constructor(e,t,n,i,r){super(),this.hitDetectionImage_=null,this.image_=e,this.crossOrigin_=n,this.canvas_={},this.color_=r,this.imageState_=i===void 0?Ei:i,this.size_=e&&e.width&&e.height?[e.width,e.height]:null,this.src_=t,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_===gt){ao||(ao=Pt(1,1,void 0,{willReadFrequently:!0})),ao.drawImage(this.image_,0,0);try{ao.getImageData(0,0,1,1),this.tainted_=!1}catch{ao=null,this.tainted_=!0}}return this.tainted_===!0}dispatchChangeEvent_(){this.dispatchEvent(Be)}handleImageError_(){this.imageState_=Jr,this.dispatchChangeEvent_()}handleImageLoad_(){this.imageState_=gt,this.size_=[this.image_.width,this.image_.height],this.dispatchChangeEvent_()}getImage(e){return this.image_||this.initializeImage_(),this.replaceColor_(e),this.canvas_[e]?this.canvas_[e]:this.image_}getPixelRatio(e){return this.replaceColor_(e),this.canvas_[e]?e:1}getImageState(){return this.imageState_}getHitDetectionImage(){if(this.image_||this.initializeImage_(),!this.hitDetectionImage_)if(this.isTainted_()){const e=this.size_[0],t=this.size_[1],n=Pt(e,t);n.fillRect(0,0,e,t),this.hitDetectionImage_=n.canvas}else this.hitDetectionImage_=this.image_;return this.hitDetectionImage_}getSize(){return this.size_}getSrc(){return this.src_}load(){if(this.imageState_===Ei){this.image_||this.initializeImage_(),this.imageState_=nr;try{this.src_!==void 0&&(this.image_.src=this.src_)}catch{this.handleImageError_()}this.image_ instanceof HTMLImageElement&&my(this.image_,this.src_).then(e=>{this.image_=e,this.handleImageLoad_()}).catch(this.handleImageError_.bind(this))}}replaceColor_(e){if(!this.color_||this.canvas_[e]||this.imageState_!==gt)return;const t=this.image_,n=document.createElement("canvas");n.width=Math.ceil(t.width*e),n.height=Math.ceil(t.height*e);const i=n.getContext("2d");i.scale(e,e),i.drawImage(t,0,0),i.globalCompositeOperation="multiply",i.fillStyle=function(r){return typeof r=="string"?r:gu(r)}(this.color_),i.fillRect(0,0,n.width/e,n.height/e),i.globalCompositeOperation="destination-in",i.drawImage(t,0,0),this.canvas_[e]=n}ready(){return this.ready_||(this.ready_=new Promise(e=>{if(this.imageState_===gt||this.imageState_===Jr)e();else{const t=()=>{(this.imageState_===gt||this.imageState_===Jr)&&(this.removeEventListener(Be,t),e())};this.addEventListener(Be,t)}})),this.ready_}};function Xu(e,t,n,i,r,s){let o=t===void 0?void 0:hn.get(t,n,r);return o||(o=new bb(e,e&&"src"in e?e.src||void 0:t,n,i,r),hn.set(t,n,r,o,s)),s&&o&&!hn.getPattern(t,n,r)&&hn.set(t,n,r,o,s),o}function r0(e){return e?Array.isArray(e)?gu(e):typeof e=="object"&&"src"in e?function(t){if(!t.offset||!t.size)return hn.getPattern(t.src,"anonymous",t.color);const n=t.src+":"+t.offset,i=hn.getPattern(n,void 0,t.color);if(i)return i;const r=hn.get(t.src,"anonymous",null);if(r.getImageState()!==gt)return null;const s=Pt(t.size[0],t.size[1]);return s.drawImage(r.getImage(1),t.offset[0],t.offset[1],t.size[0],t.size[1],0,0,t.size[0],t.size[1]),Xu(s.canvas,n,void 0,gt,t.color,!0),hn.getPattern(n,void 0,t.color)}(e):e:null}const o0="#000",s0="round",a0="round",xb=new Kt;let l0=class Nm extends i0{constructor(t){super({opacity:1,rotateWithView:t.rotateWithView!==void 0&&t.rotateWithView,rotation:t.rotation!==void 0?t.rotation:0,scale:t.scale!==void 0?t.scale:1,displacement:t.displacement!==void 0?t.displacement:[0,0],declutterMode:t.declutterMode}),this.canvases_,this.hitDetectionCanvas_=null,this.fill_=t.fill!==void 0?t.fill:null,this.origin_=[0,0],this.points_=t.points,this.radius=t.radius,this.radius2_=t.radius2,this.angle_=t.angle!==void 0?t.angle:0,this.stroke_=t.stroke!==void 0?t.stroke:null,this.size_,this.renderOptions_,this.imageState_=this.fill_&&this.fill_.loading()?nr:gt,this.imageState_===nr&&this.ready().then(()=>this.imageState_=gt),this.render()}clone(){const t=this.getScale(),n=new Nm({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 n.setOpacity(this.getOpacity()),n}getAnchor(){const t=this.size_,n=this.getDisplacement(),i=this.getScaleArray();return[t[0]/2-n[0]/i[0],t[1]/2+n[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 n=this.canvases_[t];if(!n){const i=this.renderOptions_,r=Pt(i.size*t,i.size*t);this.draw_(i,r,t),n=r.canvas,this.canvases_[t]=n}return n}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,n,i){if(n===0||this.points_===1/0||t!=="bevel"&&t!=="miter")return n;let r=this.radius,s=this.radius2_===void 0?r:this.radius2_;if(r<s){const w=r;r=s,s=w}const o=this.radius2_===void 0?this.points_:2*this.points_,a=2*Math.PI/o,l=s*Math.sin(a),c=r-Math.sqrt(s*s-l*l),u=Math.sqrt(l*l+c*c),h=u/l;if(t==="miter"&&h<=i)return h*n;const p=n/2/h,f=n/2*(c/u),m=Math.sqrt((r+p)*(r+p)+f*f)-r;if(this.radius2_===void 0||t==="bevel")return 2*m;const _=r*Math.sin(a),y=s-Math.sqrt(r*r-_*_),x=Math.sqrt(_*_+y*y)/_;if(x<=i){const w=x*n/2-s-r;return 2*Math.max(m,w)}return 2*m}createRenderOptions(){let t,n=s0,i=a0,r=0,s=null,o=0,a=0;this.stroke_&&(t=r0(this.stroke_.getColor()??"#000"),a=this.stroke_.getWidth()??1,s=this.stroke_.getLineDash(),o=this.stroke_.getLineDashOffset()??0,i=this.stroke_.getLineJoin()??a0,n=this.stroke_.getLineCap()??s0,r=this.stroke_.getMiterLimit()??10);const l=this.calculateLineJoinSize_(i,a,r),c=Math.max(this.radius,this.radius2_||0);return{strokeStyle:t,strokeWidth:a,size:Math.ceil(2*c+l),lineCap:n,lineDash:s,lineDashOffset:o,lineJoin:i,miterLimit:r}}render(){this.renderOptions_=this.createRenderOptions();const t=this.renderOptions_.size;this.canvases_={},this.hitDetectionCanvas_=null,this.size_=[t,t]}draw_(t,n,i){if(n.scale(i,i),n.translate(t.size/2,t.size/2),this.createPath_(n),this.fill_){let r=this.fill_.getColor();r===null&&(r=o0),n.fillStyle=r0(r),n.fill()}t.strokeStyle&&(n.strokeStyle=t.strokeStyle,n.lineWidth=t.strokeWidth,t.lineDash&&(n.setLineDash(t.lineDash),n.lineDashOffset=t.lineDashOffset),n.lineCap=t.lineCap,n.lineJoin=t.lineJoin,n.miterLimit=t.miterLimit,n.stroke())}createHitDetectionCanvas_(t){let n;if(this.fill_){let i=this.fill_.getColor(),r=0;typeof i=="string"&&(i=Zn(i)),i===null?r=1:Array.isArray(i)&&(r=i.length===4?i[3]:1),r===0&&(n=Pt(t.size,t.size),this.drawHitDetectionCanvas_(t,n))}return n?n.canvas:this.getImage(1)}createPath_(t){let n=this.points_;const i=this.radius;if(n===1/0)t.arc(0,0,i,0,2*Math.PI);else{const r=this.radius2_===void 0?i:this.radius2_;this.radius2_!==void 0&&(n*=2);const s=this.angle_-Math.PI/2,o=2*Math.PI/n;for(let a=0;a<n;a++){const l=s+a*o,c=a%2==0?i:r;t.lineTo(c*Math.cos(l),c*Math.sin(l))}t.closePath()}}drawHitDetectionCanvas_(t,n){n.translate(t.size/2,t.size/2),this.createPath_(n),n.fillStyle=o0,n.fill(),t.strokeStyle&&(n.strokeStyle=t.strokeStyle,n.lineWidth=t.strokeWidth,t.lineDash&&(n.setLineDash(t.lineDash),n.lineDashOffset=t.lineDashOffset),n.lineJoin=t.lineJoin,n.miterLimit=t.miterLimit,n.stroke())}ready(){return this.fill_?this.fill_.ready():Promise.resolve()}},c0=class Gm extends l0{constructor(t){super({points:1/0,fill:(t=t||{radius:5}).fill,radius:t.radius,stroke:t.stroke,scale:t.scale!==void 0?t.scale:1,rotation:t.rotation!==void 0?t.rotation:0,rotateWithView:t.rotateWithView!==void 0&&t.rotateWithView,displacement:t.displacement!==void 0?t.displacement:[0,0],declutterMode:t.declutterMode})}clone(){const t=this.getScale(),n=new Gm({fill:this.getFill()?this.getFill().clone():void 0,stroke:this.getStroke()?this.getStroke().clone():void 0,radius:this.getRadius(),scale:Array.isArray(t)?t.slice():t,rotation:this.getRotation(),rotateWithView:this.getRotateWithView(),displacement:this.getDisplacement().slice(),declutterMode:this.getDeclutterMode()});return n.setOpacity(this.getOpacity()),n}setRadius(t){this.radius=t,this.render()}},Wu=class Vm{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 Vm({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 n=Xu(null,t.src,"anonymous",void 0,t.offset?null:t.color?t.color:null,!(t.offset&&t.size));n.ready().then(()=>{this.patternImage_=null}),n.getImageState()===Ei&&n.load(),n.getImageState()===nr&&(this.patternImage_=n)}this.color_=t}loading(){return!!this.patternImage_}ready(){return this.patternImage_?this.patternImage_.ready():Promise.resolve()}},u0=class $m{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 $m({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}},h0=class qm{constructor(t){t=t||{},this.geometry_=null,this.geometryFunction_=p0,t.geometry!==void 0&&this.setGeometry(t.geometry),this.fill_=t.fill!==void 0?t.fill:null,this.image_=t.image!==void 0?t.image:null,this.renderer_=t.renderer!==void 0?t.renderer:null,this.hitDetectionRenderer_=t.hitDetectionRenderer!==void 0?t.hitDetectionRenderer:null,this.stroke_=t.stroke!==void 0?t.stroke:null,this.text_=t.text!==void 0?t.text:null,this.zIndex_=t.zIndex}clone(){let t=this.getGeometry();return t&&typeof t=="object"&&(t=t.clone()),new qm({geometry:t??void 0,fill:this.getFill()?this.getFill().clone():void 0,image:this.getImage()?this.getImage().clone():void 0,renderer:this.getRenderer()??void 0,stroke:this.getStroke()?this.getStroke().clone():void 0,text:this.getText()?this.getText().clone():void 0,zIndex:this.getZIndex()})}getRenderer(){return this.renderer_}setRenderer(t){this.renderer_=t}setHitDetectionRenderer(t){this.hitDetectionRenderer_=t}getHitDetectionRenderer(){return this.hitDetectionRenderer_}getGeometry(){return this.geometry_}getGeometryFunction(){return this.geometryFunction_}getFill(){return this.fill_}setFill(t){this.fill_=t}getImage(){return this.image_}setImage(t){this.image_=t}getStroke(){return this.stroke_}setStroke(t){this.stroke_=t}getText(){return this.text_}setText(t){this.text_=t}getZIndex(){return this.zIndex_}setGeometry(t){typeof t=="function"?this.geometryFunction_=t:typeof t=="string"?this.geometryFunction_=function(n){return n.get(t)}:t?t!==void 0&&(this.geometryFunction_=function(){return t}):this.geometryFunction_=p0,this.geometry_=t}setZIndex(t){this.zIndex_=t}},Yu=null;function d0(e,t){if(!Yu){const n=new Wu({color:"rgba(255,255,255,0.4)"}),i=new u0({color:"#3399CC",width:1.25});Yu=[new h0({image:new c0({fill:n,stroke:i,radius:5}),fill:n,stroke:i})]}return Yu}function p0(e){return e.getGeometry()}const Ta=h0;function g0(e,t,n,i){return n!==void 0&&i!==void 0?[n/e,i/t]:n!==void 0?n/e:i!==void 0?i/t:1}let wb=class Xm extends i0{constructor(t){const n=(t=t||{}).opacity!==void 0?t.opacity:1,i=t.rotation!==void 0?t.rotation:0,r=t.scale!==void 0?t.scale:1,s=t.rotateWithView!==void 0&&t.rotateWithView;super({opacity:n,rotation:i,scale:r,displacement:t.displacement!==void 0?t.displacement:[0,0],rotateWithView:s,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,l=t.src;if(Ce(!(l!==void 0&&o),"`image` and `src` cannot be provided at the same time"),(l===void 0||l.length===0)&&o&&(l=o.src||Ae(o)),Ce(l!==void 0&&l.length>0,"A defined and non-empty `src` or `image` must be provided"),Ce(!((t.width!==void 0||t.height!==void 0)&&t.scale!==void 0),"`width` or `height` cannot be provided together with `scale`"),t.src!==void 0?a=Ei:o!==void 0&&(a="complete"in o?o.complete?o.src?gt:Ei:nr:gt),this.color_=t.color!==void 0?Zn(t.color):null,this.iconImage_=Xu(o,l,this.crossOrigin_,a,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 c,u;if(t.size)[c,u]=t.size;else{const h=this.getImage(1);if(h.width&&h.height)c=h.width,u=h.height;else if(h instanceof HTMLImageElement){this.initialOptions_=t;const p=()=>{if(this.unlistenImageChange(p),!this.initialOptions_)return;const f=this.iconImage_.getSize();this.setScale(g0(f[0],f[1],t.width,t.height))};return void this.listenImageChange(p)}}c!==void 0&&this.setScale(g0(c,u,t.width,t.height))}}clone(){let t,n,i;return this.initialOptions_?(n=this.initialOptions_.width,i=this.initialOptions_.height):(t=this.getScale(),t=Array.isArray(t)?t.slice():t),new Xm({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:n,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 r=this.getSize();if(this.anchorXUnits_=="fraction"||this.anchorYUnits_=="fraction"){if(!r)return null;t=this.anchor_.slice(),this.anchorXUnits_=="fraction"&&(t[0]*=r[0]),this.anchorYUnits_=="fraction"&&(t[1]*=r[1])}if(this.anchorOrigin_!="top-left"){if(!r)return null;t===this.anchor_&&(t=this.anchor_.slice()),(this.anchorOrigin_=="top-right"||this.anchorOrigin_=="bottom-right")&&(t[0]=-t[0]+r[0]),(this.anchorOrigin_=="bottom-left"||this.anchorOrigin_=="bottom-right")&&(t[1]=-t[1]+r[1])}this.normalizedAnchor_=t}const n=this.getDisplacement(),i=this.getScaleArray();return[t[0]-n[0]/i[0],t[1]+n[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 n=this.getSize(),i=this.iconImage_.getSize();if(!n||!i)return null;t=t.slice(),(this.offsetOrigin_=="top-right"||this.offsetOrigin_=="bottom-right")&&(t[0]=i[0]-n[0]-t[0]),(this.offsetOrigin_=="bottom-left"||this.offsetOrigin_=="bottom-right")&&(t[1]=i[1]-n[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();return this.size_?this.size_[0]*t[0]:this.iconImage_.getImageState()==gt?this.iconImage_.getSize()[0]*t[0]:void 0}getHeight(){const t=this.getScaleArray();return this.size_?this.size_[1]*t[1]:this.iconImage_.getImageState()==gt?this.iconImage_.getSize()[1]*t[1]:void 0}setScale(t){delete this.initialOptions_,super.setScale(t)}listenImageChange(t){this.iconImage_.addEventListener(Be,t)}load(){this.iconImage_.load()}unlistenImageChange(t){this.iconImage_.removeEventListener(Be,t)}ready(){return this.iconImage_.ready()}},Eb=class Wm{constructor(t){t=t||{},this.font_=t.font,this.rotation_=t.rotation,this.rotateWithView_=t.rotateWithView,this.scale_=t.scale,this.scaleArray_=lt(t.scale!==void 0?t.scale:1),this.text_=t.text,this.textAlign_=t.textAlign,this.justify_=t.justify,this.repeat_=t.repeat,this.textBaseline_=t.textBaseline,this.fill_=t.fill!==void 0?t.fill:new Wu({color:"#333"}),this.maxAngle_=t.maxAngle!==void 0?t.maxAngle:Math.PI/4,this.placement_=t.placement!==void 0?t.placement:"point",this.overflow_=!!t.overflow,this.stroke_=t.stroke!==void 0?t.stroke:null,this.offsetX_=t.offsetX!==void 0?t.offsetX:0,this.offsetY_=t.offsetY!==void 0?t.offsetY:0,this.backgroundFill_=t.backgroundFill?t.backgroundFill:null,this.backgroundStroke_=t.backgroundStroke?t.backgroundStroke:null,this.padding_=t.padding===void 0?null:t.padding,this.declutterMode_=t.declutterMode}clone(){const t=this.getScale();return new Wm({font:this.getFont(),placement:this.getPlacement(),repeat:this.getRepeat(),maxAngle:this.getMaxAngle(),overflow:this.getOverflow(),rotation:this.getRotation(),rotateWithView:this.getRotateWithView(),scale:Array.isArray(t)?t.slice():t,text:this.getText(),textAlign:this.getTextAlign(),justify:this.getJustify(),textBaseline:this.getTextBaseline(),fill:this.getFill()?this.getFill().clone():void 0,stroke:this.getStroke()?this.getStroke().clone():void 0,offsetX:this.getOffsetX(),offsetY:this.getOffsetY(),backgroundFill:this.getBackgroundFill()?this.getBackgroundFill().clone():void 0,backgroundStroke:this.getBackgroundStroke()?this.getBackgroundStroke().clone():void 0,padding:this.getPadding()||void 0,declutterMode:this.getDeclutterMode()})}getOverflow(){return this.overflow_}getFont(){return this.font_}getMaxAngle(){return this.maxAngle_}getPlacement(){return this.placement_}getRepeat(){return this.repeat_}getOffsetX(){return this.offsetX_}getOffsetY(){return this.offsetY_}getFill(){return this.fill_}getRotateWithView(){return this.rotateWithView_}getRotation(){return this.rotation_}getScale(){return this.scale_}getScaleArray(){return this.scaleArray_}getStroke(){return this.stroke_}getText(){return this.text_}getTextAlign(){return this.textAlign_}getJustify(){return this.justify_}getTextBaseline(){return this.textBaseline_}getBackgroundFill(){return this.backgroundFill_}getBackgroundStroke(){return this.backgroundStroke_}getPadding(){return this.padding_}getDeclutterMode(){return this.declutterMode_}setOverflow(t){this.overflow_=t}setFont(t){this.font_=t}setMaxAngle(t){this.maxAngle_=t}setOffsetX(t){this.offsetX_=t}setOffsetY(t){this.offsetY_=t}setPlacement(t){this.placement_=t}setRepeat(t){this.repeat_=t}setRotateWithView(t){this.rotateWithView_=t}setFill(t){this.fill_=t}setRotation(t){this.rotation_=t}setScale(t){this.scale_=t,this.scaleArray_=lt(t!==void 0?t:1)}setStroke(t){this.stroke_=t}setText(t){this.text_=t}setTextAlign(t){this.textAlign_=t}setJustify(t){this.justify_=t}setTextBaseline(t){this.textBaseline_=t}setBackgroundFill(t){this.backgroundFill_=t}setBackgroundStroke(t){this.backgroundStroke_=t}setPadding(t){this.padding_=t}};function Rn(e,t,n){return en(rt(e,t,n))}function en(e,t){if(e instanceof Je){if(e.type===Ge&&typeof e.value=="string"){const i=pu(e.value);return function(){return i}}return function(){return e.value}}const n=e.operator;switch(n){case Eu:case Cu:case xu:return function(i){const r=i.operator,s=i.args.length,o=new Array(s);for(let a=0;a<s;++a)o[a]=en(i.args[a]);switch(r){case xu:return a=>{for(let l=0;l<s;++l){const c=o[l](a);if(typeof c<"u"&&c!==null)return c}throw new Error("Expected one of the values to be non-null")};case Eu:case Cu:return a=>{for(let l=0;l<s;++l){const c=o[l](a);if(typeof c===r)return c}throw new Error(`Expected one of the values to be a ${r}`)};default:throw new Error(`Unsupported assertion operator ${r}`)}}(e);case $s:case qs:return function(i){const r=i.args[0].value;switch(i.operator){case $s:return s=>{const o=i.args;let a=s.properties[r];for(let l=1,c=o.length;l<c;++l)a=a[o[l].value];return a};case qs:return s=>s.variables[r];default:throw new Error(`Unsupported accessor operator ${i.operator}`)}}(e);case Bf:return i=>i.featureId;case vu:return i=>i.geometryType;case Lf:{const i=e.args.map(r=>en(r));return r=>"".concat(...i.map(s=>s(r).toString()))}case _u:return i=>i.resolution;case Xs:case Ws:case ma:case va:case Ys:return function(i){const r=i.operator,s=i.args.length,o=new Array(s);for(let a=0;a<s;++a)o[a]=en(i.args[a]);switch(r){case Xs:return a=>{for(let l=0;l<s;++l)if(o[l](a))return!0;return!1};case Ws:return a=>{for(let l=0;l<s;++l)if(!o[l](a))return!1;return!0};case ma:return a=>{const l=o[0](a),c=o[1](a),u=o[2](a);return l>=c&&l<=u};case va:return a=>{const l=o[0](a);for(let c=1;c<s;++c)if(l===o[c](a))return!0;return!1};case Ys:return a=>!o[0](a);default:throw new Error(`Unsupported logical operator ${r}`)}}(e);case Zs:case Hs:case Js:case ea:case Ks:case Qs:return function(i){const r=i.operator,s=en(i.args[0]),o=en(i.args[1]);switch(r){case Zs:return a=>s(a)===o(a);case Hs:return a=>s(a)!==o(a);case Js:return a=>s(a)<o(a);case ea:return a=>s(a)<=o(a);case Ks:return a=>s(a)>o(a);case Qs:return a=>s(a)>=o(a);default:throw new Error(`Unsupported comparison operator ${r}`)}}(e);case ta:case na:case ia:case ra:case oa:case sa:case aa:case la:case ca:case ua:case ha:case da:case pa:case ga:case fa:return function(i){const r=i.operator,s=i.args.length,o=new Array(s);for(let a=0;a<s;++a)o[a]=en(i.args[a]);switch(r){case ta:return a=>{let l=1;for(let c=0;c<s;++c)l*=o[c](a);return l};case na:return a=>o[0](a)/o[1](a);case ia:return a=>{let l=0;for(let c=0;c<s;++c)l+=o[c](a);return l};case ra:return a=>o[0](a)-o[1](a);case oa:return a=>{const l=o[0](a),c=o[1](a);if(l<c)return c;const u=o[2](a);return l>u?u:l};case sa:return a=>o[0](a)%o[1](a);case aa:return a=>Math.pow(o[0](a),o[1](a));case la:return a=>Math.abs(o[0](a));case ca:return a=>Math.floor(o[0](a));case ua:return a=>Math.ceil(o[0](a));case ha:return a=>Math.round(o[0](a));case da:return a=>Math.sin(o[0](a));case pa:return a=>Math.cos(o[0](a));case ga:return s===2?a=>Math.atan2(o[0](a),o[1](a)):a=>Math.atan(o[0](a));case fa:return a=>Math.sqrt(o[0](a));default:throw new Error(`Unsupported numeric operator ${r}`)}}(e);case wu:return function(i){const r=i.args.length,s=new Array(r);for(let o=0;o<r;++o)s[o]=en(i.args[o]);return o=>{for(let a=0;a<r-1;a+=2)if(s[a](o))return s[a+1](o);return s[r-1](o)}}(e);case yu:return function(i){const r=i.args.length,s=new Array(r);for(let o=0;o<r;++o)s[o]=en(i.args[o]);return o=>{const a=s[0](o);for(let l=1;l<r;l+=2)if(a===s[l](o))return s[l+1](o);return s[r-1](o)}}(e);case bu:return function(i){const r=i.args.length,s=new Array(r);for(let o=0;o<r;++o)s[o]=en(i.args[o]);return o=>{const a=s[0](o),l=s[1](o);let c,u;for(let h=2;h<r;h+=2){const p=s[h](o);let f=s[h+1](o);const m=Array.isArray(f);if(m&&(f=By(f)),p>=l)return h===2?f:m?Cb(a,l,c,u,p,f):lo(a,l,c,u,p,f);c=p,u=f}return u}}(e);case Au:return function(i){const r=i.operator,s=i.args.length,o=new Array(s);for(let a=0;a<s;++a)o[a]=en(i.args[a]);if(r===Au)return a=>{const l=o[0](a);return i.args[0].type===Ge?gu(l):l.toString()};throw new Error(`Unsupported convert operator ${r}`)}(e);default:throw new Error(`Unsupported operator ${n}`)}}function lo(e,t,n,i,r,s){const o=r-n;if(o===0)return i;const a=t-n;return i+(e===1?a/o:(Math.pow(e,a)-1)/(Math.pow(e,o)-1))*(s-i)}function Cb(e,t,n,i,r,s){if(r-n==0)return i;const o=Pf(i),a=Pf(s);let l=a[2]-o[2];return l>180?l-=360:l<-180&&(l+=360),If(function(c){const u=ft.rgb(Tf.xyz(c));return u[3]=c[3],u}([lo(e,t,n,o[0],r,a[0]),lo(e,t,n,o[1],r,a[1]),o[2]+lo(e,t,n,0,r,l),lo(e,t,n,i[3],r,s[3])]))}function Ab(e){return!0}function Sb(e){const t=mu(),n=function(r,s){const o=r.length,a=new Array(o);for(let l=0;l<o;++l){const c=r[l],u="filter"in c?Rn(c.filter,ct,s):Ab;let h;if(Array.isArray(c.style)){const p=c.style.length;h=new Array(p);for(let f=0;f<p;++f)h[f]=Zu(c.style[f],s)}else h=[Zu(c.style,s)];a[l]={filter:u,styles:h}}return function(l){const c=[];let u=!1;for(let h=0;h<o;++h)if((0,a[h].filter)(l)&&(!r[h].else||!u)){u=!0;for(const p of a[h].styles){const f=p(l);f&&c.push(f)}}return c}}(e,t),i={variables:{},properties:{},resolution:NaN,featureId:null,geometryType:""};return function(r,s){if(i.properties=r.getPropertiesInternal(),i.resolution=s,t.featureId){const o=r.getId();i.featureId=o!==void 0?o:null}return t.geometryType&&(i.geometryType=Su(r.getGeometry())),n(i)}}function f0(e){const t=mu(),n=e.length,i=new Array(n);for(let o=0;o<n;++o)i[o]=Zu(e[o],t);const r={variables:{},properties:{},resolution:NaN,featureId:null,geometryType:""},s=new Array(n);return function(o,a){if(r.properties=o.getPropertiesInternal(),r.resolution=a,t.featureId){const c=o.getId();r.featureId=c!==void 0?c:null}let l=0;for(let c=0;c<n;++c){const u=i[c](r);u&&(s[l]=u,l+=1)}return s.length=l,s}}function Zu(e,t){const n=co(e,"",t),i=uo(e,"",t),r=function(l,c){const u="text-",h=kn(l,u+"value",c);if(!h)return null;const p=co(l,u,c),f=co(l,u+"background-",c),m=uo(l,u,c),_=uo(l,u+"background-",c),y=kn(l,u+"font",c),x=It(l,u+"max-angle",c),w=It(l,u+"offset-x",c),T=It(l,u+"offset-y",c),R=ho(l,u+"overflow",c),b=kn(l,u+"placement",c),k=It(l,u+"repeat",c),F=ka(l,u+"scale",c),j=ho(l,u+"rotate-with-view",c),B=It(l,u+"rotation",c),N=kn(l,u+"align",c),Y=kn(l,u+"justify",c),ee=kn(l,u+"baseline",c),ne=m0(l,u+"padding",c),G=Ia(l,u+"declutter-mode"),V=new Eb({declutterMode:G});return function(q){if(V.setText(h(q)),p&&V.setFill(p(q)),f&&V.setBackgroundFill(f(q)),m&&V.setStroke(m(q)),_&&V.setBackgroundStroke(_(q)),y&&V.setFont(y(q)),x&&V.setMaxAngle(x(q)),w&&V.setOffsetX(w(q)),T&&V.setOffsetY(T(q)),R&&V.setOverflow(R(q)),b){const W=b(q);if(W!=="point"&&W!=="line")throw new Error("Expected point or line for text-placement");V.setPlacement(W)}if(k&&V.setRepeat(k(q)),F&&V.setScale(F(q)),j&&V.setRotateWithView(j(q)),B&&V.setRotation(B(q)),N){const W=N(q);if(W!=="left"&&W!=="center"&&W!=="right"&&W!=="end"&&W!=="start")throw new Error("Expected left, right, center, start, or end for text-align");V.setTextAlign(W)}if(Y){const W=Y(q);if(W!=="left"&&W!=="right"&&W!=="center")throw new Error("Expected left, right, or center for text-justify");V.setJustify(W)}if(ee){const W=ee(q);if(W!=="bottom"&&W!=="top"&&W!=="middle"&&W!=="alphabetic"&&W!=="hanging")throw new Error("Expected bottom, top, middle, alphabetic, or hanging for text-baseline");V.setTextBaseline(W)}return ne&&V.setPadding(ne(q)),V}}(e,t),s=function(l,c){return"icon-src"in l?function(u,h){const p="icon-",f=p+"src",m=b0(u[f],f),_=Ra(u,p+"anchor",h),y=ka(u,p+"scale",h),x=It(u,p+"opacity",h),w=Ra(u,p+"displacement",h),T=It(u,p+"rotation",h),R=ho(u,p+"rotate-with-view",h),b=_0(u,p+"anchor-origin"),k=y0(u,p+"anchor-x-units"),F=y0(u,p+"anchor-y-units"),j=function(W,se){const he=W[se];if(he!==void 0)return x0(he,se)}(u,p+"color"),B=function(W,se){const he=W[se];if(he!==void 0){if(typeof he!="string")throw new Error(`Expected a string for ${se}`);return he}}(u,p+"cross-origin"),N=function(W,se){const he=W[se];if(he!==void 0)return po(he,se)}(u,p+"offset"),Y=_0(u,p+"offset-origin"),ee=Pa(u,p+"width"),ne=Pa(u,p+"height"),G=function(W,se){const he=W[se];if(he!==void 0){if(typeof he=="number")return lt(he);if(!Array.isArray(he))throw new Error(`Expected a number or size array for ${se}`);if(he.length!==2||typeof he[0]!="number"||typeof he[1]!="number")throw new Error(`Expected a number or size array for ${se}`);return he}}(u,p+"size"),V=Ia(u,p+"declutter-mode"),q=new wb({src:m,anchorOrigin:b,anchorXUnits:k,anchorYUnits:F,color:j,crossOrigin:B,offset:N,offsetOrigin:Y,height:ne,width:ee,size:G,declutterMode:V});return function(W){return x&&q.setOpacity(x(W)),w&&q.setDisplacement(w(W)),T&&q.setRotation(T(W)),R&&q.setRotateWithView(R(W)),y&&q.setScale(y(W)),_&&q.setAnchor(_(W)),q}}(l,c):"shape-points"in l?function(u,h){const p="shape-",f=p+"points",m=p+"radius",_=Ku(u[f],f),y=Ku(u[m],m),x=co(u,p,h),w=uo(u,p,h),T=ka(u,p+"scale",h),R=Ra(u,p+"displacement",h),b=It(u,p+"rotation",h),k=ho(u,p+"rotate-with-view",h),F=Pa(u,p+"radius2"),j=Pa(u,p+"angle"),B=Ia(u,p+"declutter-mode"),N=new l0({points:_,radius:y,radius2:F,angle:j,declutterMode:B});return function(Y){return x&&N.setFill(x(Y)),w&&N.setStroke(w(Y)),R&&N.setDisplacement(R(Y)),b&&N.setRotation(b(Y)),k&&N.setRotateWithView(k(Y)),T&&N.setScale(T(Y)),N}}(l,c):"circle-radius"in l?function(u,h){const p="circle-",f=co(u,p,h),m=uo(u,p,h),_=It(u,p+"radius",h),y=ka(u,p+"scale",h),x=Ra(u,p+"displacement",h),w=It(u,p+"rotation",h),T=ho(u,p+"rotate-with-view",h),R=Ia(u,p+"declutter-mode"),b=new c0({radius:5,declutterMode:R});return function(k){return _&&b.setRadius(_(k)),f&&b.setFill(f(k)),m&&b.setStroke(m(k)),x&&b.setDisplacement(x(k)),w&&b.setRotation(w(k)),T&&b.setRotateWithView(T(k)),y&&b.setScale(y(k)),b}}(l,c):null}(e,t),o=It(e,"z-index",t);if(!(n||i||r||s||Vi(e)))throw new Error("No fill, stroke, point, or text symbolizer properties in style: "+JSON.stringify(e));const a=new Ta;return function(l){let c=!0;if(n){const u=n(l);u&&(c=!1),a.setFill(u)}if(i){const u=i(l);u&&(c=!1),a.setStroke(u)}if(r){const u=r(l);u&&(c=!1),a.setText(u)}if(s){const u=s(l);u&&(c=!1),a.setImage(u)}return o&&a.setZIndex(o(l)),c?null:a}}function co(e,t,n){let i;if(t+"fill-pattern-src"in e)i=function(s,o,a){const l=kn(s,o+"pattern-src",a),c=v0(s,o+"pattern-offset",a),u=v0(s,o+"pattern-size",a),h=Hu(s,o+"color",a);return function(p){return{src:l(p),offset:c&&c(p),size:u&&u(p),color:h&&h(p)}}}(e,t+"fill-",n);else{if(e[t+"fill-color"]==="none")return s=>null;i=Hu(e,t+"fill-color",n)}if(!i)return null;const r=new Wu;return function(s){const o=i(s);return o==="none"?null:(r.setColor(o),r)}}function uo(e,t,n){const i=It(e,t+"stroke-width",n),r=Hu(e,t+"stroke-color",n);if(!i&&!r)return null;const s=kn(e,t+"stroke-line-cap",n),o=kn(e,t+"stroke-line-join",n),a=m0(e,t+"stroke-line-dash",n),l=It(e,t+"stroke-line-dash-offset",n),c=It(e,t+"stroke-miter-limit",n),u=new u0;return function(h){if(r){const p=r(h);if(p==="none")return null;u.setColor(p)}if(i&&u.setWidth(i(h)),s){const p=s(h);if(p!=="butt"&&p!=="round"&&p!=="square")throw new Error("Expected butt, round, or square line cap");u.setLineCap(p)}if(o){const p=o(h);if(p!=="bevel"&&p!=="round"&&p!=="miter")throw new Error("Expected bevel, round, or miter line join");u.setLineJoin(p)}return a&&u.setLineDash(a(h)),l&&u.setLineDashOffset(l(h)),c&&u.setMiterLimit(c(h)),u}}function It(e,t,n){if(!(t in e))return;const i=Rn(e[t],re,n);return function(r){return Ku(i(r),t)}}function kn(e,t,n){if(!(t in e))return null;const i=Rn(e[t],it,n);return function(r){return b0(i(r),t)}}function ho(e,t,n){if(!(t in e))return null;const i=Rn(e[t],ct,n);return function(r){const s=i(r);if(typeof s!="boolean")throw new Error(`Expected a boolean for ${t}`);return s}}function Hu(e,t,n){if(!(t in e))return null;const i=Rn(e[t],Ge,n);return function(r){return x0(i(r),t)}}function m0(e,t,n){if(!(t in e))return null;const i=Rn(e[t],xt,n);return function(r){return po(i(r),t)}}function Ra(e,t,n){if(!(t in e))return null;const i=Rn(e[t],xt,n);return function(r){const s=po(i(r),t);if(s.length!==2)throw new Error(`Expected two numbers for ${t}`);return s}}function v0(e,t,n){if(!(t in e))return null;const i=Rn(e[t],xt,n);return function(r){return w0(i(r),t)}}function ka(e,t,n){if(!(t in e))return null;const i=Rn(e[t],xt|re,n);return function(r){return function(s,o){return typeof s=="number"?s:w0(s,o)}(i(r),t)}}function Pa(e,t){const n=e[t];if(n!==void 0){if(typeof n!="number")throw new Error(`Expected a number for ${t}`);return n}}function _0(e,t){const n=e[t];if(n!==void 0){if(n!=="bottom-left"&&n!=="bottom-right"&&n!=="top-left"&&n!=="top-right")throw new Error(`Expected bottom-left, bottom-right, top-left, or top-right for ${t}`);return n}}function y0(e,t){const n=e[t];if(n!==void 0){if(n!=="pixels"&&n!=="fraction")throw new Error(`Expected pixels or fraction for ${t}`);return n}}function Ia(e,t){const n=e[t];if(n!==void 0){if(typeof n!="string")throw new Error(`Expected a string for ${t}`);if(n!=="declutter"&&n!=="obstacle"&&n!=="none")throw new Error(`Expected declutter, obstacle, or none for ${t}`);return n}}function po(e,t){if(!Array.isArray(e))throw new Error(`Expected an array for ${t}`);const n=e.length;for(let i=0;i<n;++i)if(typeof e[i]!="number")throw new Error(`Expected an array of numbers for ${t}`);return e}function b0(e,t){if(typeof e!="string")throw new Error(`Expected a string for ${t}`);return e}function Ku(e,t){if(typeof e!="number")throw new Error(`Expected a number for ${t}`);return e}function x0(e,t){if(typeof e=="string")return e;const n=po(e,t),i=n.length;if(i<3||i>4)throw new Error(`Expected a color with 3 or 4 values for ${t}`);return n}function w0(e,t){const n=po(e,t);if(n.length!==2)throw new Error(`Expected an array of two numbers for ${t}`);return n}const E0="renderOrder";let C0=class extends Kr{constructor(e){e=e||{};const t=Object.assign({},e);delete t.style,delete t.renderBuffer,delete t.updateWhileAnimating,delete t.updateWhileInteracting,super(t),this.declutter_=e.declutter?String(e.declutter):void 0,this.renderBuffer_=e.renderBuffer!==void 0?e.renderBuffer:100,this.style_=null,this.styleFunction_=void 0,this.setStyle(e.style),this.updateWhileAnimating_=e.updateWhileAnimating!==void 0&&e.updateWhileAnimating,this.updateWhileInteracting_=e.updateWhileInteracting!==void 0&&e.updateWhileInteracting}getDeclutter(){return this.declutter_}getFeatures(e){return super.getFeatures(e)}getRenderBuffer(){return this.renderBuffer_}getRenderOrder(){return this.get(E0)}getStyle(){return this.style_}getStyleFunction(){return this.styleFunction_}getUpdateWhileAnimating(){return this.updateWhileAnimating_}getUpdateWhileInteracting(){return this.updateWhileInteracting_}renderDeclutter(e,t){const n=this.getDeclutter();n in e.declutter||(e.declutter[n]=new t0(9)),this.getRenderer().renderDeclutter(e,t)}setRenderOrder(e){this.set(E0,e)}setStyle(e){this.style_=e===void 0?d0:e;const t=function(n){if(n===void 0)return d0;if(!n)return null;if(typeof n=="function"||n instanceof Ta)return n;if(!Array.isArray(n))return f0([n]);if(n.length===0)return[];const i=n.length,r=n[0];if(r instanceof Ta){const s=new Array(i);for(let o=0;o<i;++o){const a=n[o];if(!(a instanceof Ta))throw new Error("Expected a list of style instances");s[o]=a}return s}if("style"in r){const s=new Array(i);for(let o=0;o<i;++o){const a=n[o];if(!("style"in a))throw new Error("Expected a list of rules with a style property");s[o]=a}return Sb(s)}return f0(n)}(e);this.styleFunction_=e===null?void 0:function(n){let i;if(typeof n=="function")i=n;else{let r;Array.isArray(n)?r=n:(Ce(typeof n.getZIndex=="function","Expected an `Style` or an array of `Style`"),r=[n]),i=function(){return r}}return i}(t),this.changed()}};const go="addfeature",A0="changefeature",S0="clear",Ma="removefeature",Tb="featuresloadstart",Rb="featuresloadend",kb="featuresloaderror",dn=new Uint8Array(4);let Pb=class{constructor(e,t){this.helper_=e;const n=e.getGL();this.texture_=n.createTexture(),this.framebuffer_=n.createFramebuffer(),this.depthbuffer_=n.createRenderbuffer(),this.size_=t||[1,1],this.data_=new Uint8Array(0),this.dataCacheDirty_=!0,this.updateSize_()}setSize(e){ls(e,this.size_)||(this.size_[0]=e[0],this.size_[1]=e[1],this.updateSize_())}getSize(){return this.size_}clearCachedData(){this.dataCacheDirty_=!0}readAll(){if(this.dataCacheDirty_){const e=this.size_,t=this.helper_.getGL();t.bindFramebuffer(t.FRAMEBUFFER,this.framebuffer_),t.readPixels(0,0,e[0],e[1],t.RGBA,t.UNSIGNED_BYTE,this.data_),this.dataCacheDirty_=!1}return this.data_}readPixel(e,t){if(e<0||t<0||e>this.size_[0]||t>=this.size_[1])return dn[0]=0,dn[1]=0,dn[2]=0,dn[3]=0,dn;this.readAll();const n=Math.floor(e)+(this.size_[1]-Math.floor(t)-1)*this.size_[0];return dn[0]=this.data_[4*n],dn[1]=this.data_[4*n+1],dn[2]=this.data_[4*n+2],dn[3]=this.data_[4*n+3],dn}getTexture(){return this.texture_}getFramebuffer(){return this.framebuffer_}getDepthbuffer(){return this.depthbuffer_}updateSize_(){const e=this.size_,t=this.helper_.getGL();this.texture_=this.helper_.createTexture(e,null,this.texture_),t.bindFramebuffer(t.FRAMEBUFFER,this.framebuffer_),t.viewport(0,0,e[0],e[1]),t.framebufferTexture2D(t.FRAMEBUFFER,t.COLOR_ATTACHMENT0,t.TEXTURE_2D,this.texture_,0),t.bindRenderbuffer(t.RENDERBUFFER,this.depthbuffer_),t.renderbufferStorage(t.RENDERBUFFER,t.DEPTH_COMPONENT16,e[0],e[1]),t.framebufferRenderbuffer(t.FRAMEBUFFER,t.DEPTH_ATTACHMENT,t.RENDERBUFFER,this.depthbuffer_),this.data_=new Uint8Array(e[0]*e[1]*4)}};const T0="GENERATE_POINT_BUFFERS";class Ib extends Ef{constructor(t,n){const i=n.uniforms||{},r=[1,0,0,1,0,0];i[wy]=r,super(t,{uniforms:i,postProcesses:n.postProcesses}),this.sourceRevision_=-1,this.verticesBuffer_=new Bs(Ds,cf),this.indicesBuffer_=new Bs(Us,cf),this.vertexShader_=n.vertexShader,this.fragmentShader_=n.fragmentShader,this.program_,this.hitDetectionEnabled_=n.hitDetectionEnabled??!0;const s=n.attributes?n.attributes.map(function(a){return{name:"a_prop_"+a.name,size:1,type:ir}}):[];this.attributes=[{name:"a_position",size:2,type:ir},{name:"a_index",size:1,type:ir}],this.hitDetectionEnabled_&&(this.attributes.push({name:"a_prop_hitColor",size:4,type:ir}),this.attributes.push({name:"a_featureUid",size:1,type:ir})),this.attributes.push(...s),this.customAttributes=n.attributes?n.attributes:[],this.previousExtent_=[1/0,1/0,-1/0,-1/0],this.currentTransform_=r,this.renderTransform_=[1,0,0,1,0,0],this.invertRenderTransform_=[1,0,0,1,0,0],this.renderInstructions_=new Float32Array(0),this.hitRenderTarget_,this.lastSentId=0,this.worker_=function(){const a='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;n<o;n++){const i=u(t,e[n]*r,n<o-1?e[n+1]*r:t.length,r,!1);i===i.next&&(i.steiner=!0),x.push(g(i))}x.sort(y);for(let t=0;t<x.length;t++)n=h(x[t],n);return n}(t,e,o,n)),t.length>80*n){s=1/0,l=1/0;let e=-1/0,r=-1/0;for(let o=n;o<x;o+=n){const n=t[o],x=t[o+1];n<s&&(s=n),x<l&&(l=x),n>e&&(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;o<n;o+=r)x+=(t[u]-t[o])*(t[o+1]+t[u+1]),u=o;return x}(t,e,n,r)>0)for(let x=e;x<n;x+=r)o=z(x/r|0,t[x],t[x+1],o);else for(let x=n-r;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;t<n&&(i++,u=u.nextZ,u);t++);let f=n;for(;i>0||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=x<o?x<u?x:u:o<u?o:u,c=i<f?i<s?i:s:f<s?f:s,a=x>o?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=i<f?i<s?i:s:f<s?f:s,h=l<c?l<a?l:a:c<a?c:a,p=i>f?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.next.x?n:n.next,t===r))return o}n=n.next}while(n!==e);if(!o)return null;const i=o,f=o.x,s=o.y;let l=1/0;n=o;do{if(r>=n.x&&n.x>=f&&r!==n.x&&b(x<s?r:u,x,f,s,x<s?u:r,x,n.x,n.y)){const e=Math.abs(x-n.y)/(r-n.x);E(n,t)&&(e<l||e===l&&(n.x>o.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<n.x||e.x===n.x&&e.y<n.y)&&(n=e),e=e.next}while(e!==t);return n}function b(t,e,n,r,x,o,u,i){return(x-u)*(e-i)>=(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;n<s.length;n++)s[n]=t[e+2+n];let l=o?o.vertexPosition:0,c=o?o.indexPosition:0;const a=l/u;return R(n,l,i,f,0),s.length&&n.set(s,l+3),l+=u,R(n,l,i,f,1),s.length&&n.set(s,l+3),l+=u,R(n,l,i,f,2),s.length&&n.set(s,l+3),l+=u,R(n,l,i,f,3),s.length&&n.set(s,l+3),l+=u,r[c++]=a,r[c++]=a+1,r[c++]=a+3,r[c++]=a+1,r[c++]=a+2,r[c++]=a+3,N.vertexPosition=l,N.indexPosition=c,N}function T(t,e,n,x,o,u,i,f,s,l,c){const a=8+f.length,y=u.length/a,h=[t[e+0],t[e+1]],p=[t[n],t[n+1]],v=r(s,[...h]),g=r(s,[...p]);function b(t,e,n){const r=Math.sqrt((e[0]-t[0])*(e[0]-t[0])+(e[1]-t[1])*(e[1]-t[1])),x=[(e[0]-t[0])/r,(e[1]-t[1])/r],o=[-x[1],x[0]],u=Math.sqrt((n[0]-t[0])*(n[0]-t[0])+(n[1]-t[1])*(n[1]-t[1])),i=[(n[0]-t[0])/u,(n[1]-t[1])/u],f=0===r||0===u?0:Math.acos((s=i[0]*x[0]+i[1]*x[1],l=-1,c=1,Math.min(Math.max(s,l),c)));var s,l,c;return i[0]*o[0]+i[1]*o[1]>0?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<s;e++)l+=t[i++],e<s-1&&(c[e]=l);const a=t.slice(i,i+2*l),y=o(a,c,2);for(let t=0;t<y.length;t++)r.push(y[t]+n.length/u);for(let t=0;t<a.length;t+=2)n.push(a[t],a[t+1],...f);return i+2*l}const O=self;O.onmessage=r=>{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;t<x.length;t+=r)l=S(x,t,s,f,n,l);const c=Object.assign({vertexBuffer:s.buffer,indexBuffer:f.buffer,renderInstructions:x.buffer},o);O.postMessage(c,[s.buffer,f.buffer,x.buffer]);break}case n:{const t=[],e=[],n=o.customAttributesSize,r=2,u=new Float32Array(o.renderInstructions);let i=0;const f=[1,0,0,1,0,0];let s,l;for(x(f,o.renderInstructionsTransform);i<u.length;){l=Array.from(u.slice(i,i+n)),i+=n,s=u[i++];const x=i,o=i+(s-1)*r,c=u[x]===u[o]&&u[x+1]===u[o+1];let a=0,y=0;for(let n=0;n<s-1;n++){let h=null;n>0?h=i+(n-1)*r:c&&(h=o-r);let p=null;n<s-2?p=i+(n+2)*r:c&&(p=x+r);const v=T(u,i+n*r,i+(n+1)*r,h,p,t,e,l,f,a,y);a=v.length,y=v.angle}i+=s*r}const c=Uint32Array.from(e),a=Float32Array.from(t),y=Object.assign({vertexBuffer:a.buffer,indexBuffer:c.buffer,renderInstructions:u.buffer},o);O.postMessage(y,[a.buffer,c.buffer,u.buffer]);break}case t:{const t=[],e=[],n=o.customAttributesSize,r=new Float32Array(o.renderInstructions);let x=0;for(;x<r.length;)x=_(r,x,t,e,n);const u=Uint32Array.from(e),i=Float32Array.from(t),f=Object.assign({vertexBuffer:i.buffer,indexBuffer:u.buffer,renderInstructions:r.buffer},o);O.postMessage(f,[i.buffer,u.buffer,r.buffer]);break}}};';return new Worker(typeof Blob>"u"?"data:application/javascript;base64,"+Buffer.from(a,"binary").toString("base64"):URL.createObjectURL(new Blob([a],{type:"application/javascript"})))}(),this.worker_.addEventListener("message",a=>{const l=a.data;if(l.type===T0){const c=l.projectionTransform;this.verticesBuffer_.fromArrayBuffer(l.vertexBuffer),this.helper.flushBufferData(this.verticesBuffer_),this.indicesBuffer_.fromArrayBuffer(l.indexBuffer),this.helper.flushBufferData(this.indicesBuffer_),this.renderTransform_=c,kg(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,go,this.handleSourceFeatureAdded_,this),we(o,A0,this.handleSourceFeatureChanged_,this),we(o,Ma,this.handleSourceFeatureDelete_,this),we(o,S0,this.handleSourceFeatureClear_,this)],o.forEachFeature(a=>{this.featureCache_[Ae(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 Pb(this.helper))}handleSourceFeatureAdded_(t){const n=t.feature;this.featureCache_[Ae(n)]={feature:n,properties:n.getProperties(),geometry:n.getGeometry()},this.featureCount_++}handleSourceFeatureChanged_(t){const n=t.feature;this.featureCache_[Ae(n)]={feature:n,properties:n.getProperties(),geometry:n.getGeometry()}}handleSourceFeatureDelete_(t){const n=t.feature;delete this.featureCache_[Ae(n)],this.featureCount_--}handleSourceFeatureClear_(){this.featureCache_={},this.featureCount_=0}renderFrame(t){const n=this.helper.getGL();this.preRender(n,t);const[i,r,s]=function(o,a){const l=o.viewState.projection,c=a.getSource().getWrapX()&&l.canWrapX(),u=l.getExtent(),h=o.extent,p=c?ze(u):null,f=c?Math.ceil((h[2]-u[2])/p)+1:1;return[c?Math.floor((h[0]-u[0])/p):0,f,p]}(t,this.getLayer());return this.renderWorlds(t,!1,i,r,s),this.helper.finalizeDraw(t,this.dispatchPreComposeEvent,this.dispatchPostComposeEvent),this.hitDetectionEnabled_&&(this.renderWorlds(t,!0,i,r,s),this.hitRenderTarget_.clearCachedData()),this.postRender(n,t),this.helper.getCanvas()}prepareFrameInternal(t){const n=this.getLayer(),i=n.getSource(),r=t.viewState,s=!t.viewHints[qn]&&!t.viewHints[qi],o=!$r(this.previousExtent_,t.extent),a=this.sourceRevision_<i.getRevision();if(a&&(this.sourceRevision_=i.getRevision()),s&&(o||a)){const l=r.projection,c=r.resolution,u=n instanceof C0?n.getRenderBuffer():0,h=function(p,f){return[p[0]-f,p[1]-f,p[2]+f,p[3]+f]}(t.extent,u*c);i.loadFeatures(h,c,l),this.rebuildBuffers_(t),this.previousExtent_=t.extent.slice()}return this.helper.useProgram(this.program_,t),this.helper.prepareDraw(t),this.helper.bindBuffer(this.verticesBuffer_),this.helper.bindBuffer(this.indicesBuffer_),this.helper.enableAttributes(this.attributes),!0}rebuildBuffers_(t){const n=[1,0,0,1,0,0];this.helper.makeProjectionTransform(t,n);const i=(this.hitDetectionEnabled_?7:2)+this.customAttributes.length,r=i*this.featureCount_;let s,o;(!this.renderInstructions_||this.renderInstructions_.length!==r)&&(this.renderInstructions_=new Float32Array(r));const a=[],l=[];let c=-1;for(const h in this.featureCache_)if(s=this.featureCache_[h],o=s.geometry,o&&o.getType()==="Point"){if(a[0]=o.getFlatCoordinates()[0],a[1]=o.getFlatCoordinates()[1],Wr(n,a),this.renderInstructions_[++c]=a[0],this.renderInstructions_[++c]=a[1],this.hitDetectionEnabled_){const p=$y(c+5,l);this.renderInstructions_[++c]=p[0],this.renderInstructions_[++c]=p[1],this.renderInstructions_[++c]=p[2],this.renderInstructions_[++c]=p[3],this.renderInstructions_[++c]=Number(h)}for(let p=0;p<this.customAttributes.length;p++){const f=this.customAttributes[p].callback(s.feature,s.properties);this.renderInstructions_[++c]=f}}const u={id:++this.lastSentId,type:T0,renderInstructions:this.renderInstructions_.buffer,customAttributesSize:i-2};u.projectionTransform=n,this.ready=!1,this.worker_.postMessage(u,[this.renderInstructions_.buffer]),this.renderInstructions_=null}forEachFeatureAtCoordinate(t,n,i,r,s){if(Ce(this.hitDetectionEnabled_,"`forEachFeatureAtCoordinate` cannot be used on a WebGL layer if the hit detection logic has been disabled using the `disableHitDetection: true` option."),!this.renderInstructions_||!this.hitDetectionEnabled_)return;const o=Wr(n.coordinateToPixelTransform,t.slice()),a=this.hitRenderTarget_.readPixel(o[0]/2,o[1]/2),l=function(p){let f=0;const m=256,_=255;return f+=Math.round(p[0]*m*m*m*_),f+=Math.round(p[1]*m*m*_),f+=Math.round(p[2]*m*_),f+=Math.round(p[3]*_),f}([a[0]/255,a[1]/255,a[2]/255,a[3]/255]),c=this.renderInstructions_[l],u=Math.floor(c).toString(),h=this.getLayer().getSource().getFeatureByUid(u);return h?r(h,this.getLayer(),null):void 0}renderWorlds(t,n,i,r,s){let o=i;this.helper.useProgram(this.program_,t),n&&(this.hitRenderTarget_.setSize([Math.floor(t.size[0]/2),Math.floor(t.size[1]/2)]),this.helper.prepareDrawToRenderTarget(t,this.hitRenderTarget_,!0)),this.helper.bindBuffer(this.verticesBuffer_),this.helper.bindBuffer(this.indicesBuffer_),this.helper.enableAttributes(this.attributes);do{this.helper.makeProjectionTransform(t,this.currentTransform_),Rg(this.currentTransform_,o*s,0),As(this.currentTransform_,this.invertRenderTransform_),this.helper.applyUniforms(t),this.helper.applyHitDetectionUniform(n);const a=this.indicesBuffer_.getSize();this.helper.drawElements(0,a)}while(++o<r)}disposeInternal(){this.worker_.terminate(),this.sourceListenKeys_.forEach(function(t){Le(t)}),this.sourceListenKeys_=null,super.disposeInternal()}renderDeclutter(){}}let R0=class extends Kr{constructor(e){super(Object.assign({},e)),this.parseResult_=Xy(e.style),this.styleVariables_=e.style.variables||{},this.hitDetectionDisabled_=!!e.disableHitDetection}createRenderer(){const e=Object.keys(this.parseResult_.attributes).map(t=>({name:t,...this.parseResult_.attributes[t]}));return new Ib(this,{vertexShader:this.parseResult_.builder.getSymbolVertexShader(),fragmentShader:this.parseResult_.builder.getSymbolFragmentShader(),hitDetectionEnabled:!this.hitDetectionDisabled_,uniforms:this.parseResult_.uniforms,attributes:e})}updateStyleVariables(e){Object.assign(this.styleVariables_,e),this.changed()}};function Qu(e){const t=arguments;return function(n){let i=!0;for(let r=0,s=t.length;r<s&&(i=i&&t[r](n),i);++r);return i}}const Mb=function(e){const t=e.originalEvent;return t.altKey&&!(t.metaKey||t.ctrlKey)&&t.shiftKey},k0=function(e){return!e.map.getTargetElement().hasAttribute("tabindex")||function(t){const n=t.map.getTargetElement(),i=t.map.getOwnerDocument().activeElement;return n.contains(i)}(e)},Lb=Ur,P0=function(e){const t=e.originalEvent;return t.button==0&&!(uy&&Yg&&t.ctrlKey)},I0=function(e){const t=e.originalEvent;return!t.altKey&&!(t.metaKey||t.ctrlKey)&&!t.shiftKey},Fb=function(e){const t=e.originalEvent;return!t.altKey&&!(t.metaKey||t.ctrlKey)&&t.shiftKey},M0=function(e){const t=e.originalEvent,n=t.target.tagName;return n!=="INPUT"&&n!=="SELECT"&&n!=="TEXTAREA"&&!t.target.isContentEditable},La=function(e){const t=e.originalEvent;return Ce(t!==void 0,"mapBrowserEvent must originate from a pointer event"),t.pointerType=="mouse"},Ob=function(e){const t=e.originalEvent;return Ce(t!==void 0,"mapBrowserEvent must originate from a pointer event"),t.isPrimary&&t.button===0},L0="default",F0="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACQAAAAkCAYAAADhAJiYAAAACXBIWXMAABYlAAAWJQFJUiTwAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAMISURBVHgBzVhtalNBFD1JamJD1WAkJYr4RCj+VNxAXYm6ArfQJegSXEmzA/0nFaERwWAgGE1taUh83tO5N5mm+biPfNADh5fJu/PmzJ07H3dyyI6S8I6wLNwRbgkL+m4oPBf2hT3hby27kctgW1XeQjacCtvCjsfYI4gCEmFRywOEnv8RniF4Y6jvCmpn3qsgeBBq92ORsHmC+KG6sKZlut56OoQfVf1OScttFTbMIoiVnwi3ETzS0g8tA3bsof6mt75gSnwVMF3MnvCmVjhCGJ5l8RfBuxVtg08O/XCeIA7TU4Q4YDB+RejNqsDGuwhxyQ4zzn4J01mCHghvI3hm1WJiUfQ4PcSQyCMagVhQVQUxZo7WJCYWRU/dQ/DWibWXj4zu67OF9Yox2DJAJPanCaJ3GDc2tTeFtrZZVA0jQbbWtLB5mANGgjgFubJyXF3LO5GmaUV4IDxMx/gofIVssIWWsXSxG9A7L4SPvF+QRhPhcTobfJfAj0Q11PIYb5Yn/vo4RBSIMxqg5yrwoafPMgXZpnnqqSmNvMZ8MbGot/DhTJ87FkOEd6p7GyH2nXa2p21RUHy48uAZ/Nh32o2OL3lcM1BQfLjyoAE/PjntRqNEQQMtFJ2VG/DjndPO4vicgmy6l52V3wubDrtmLpf7AB+29dmnIJvursO7NMJd+uUCUU218cLa7lFQVwtcxFxxJKLY+8fy8w0ux0lDeCB8Thv4YQto187Ue6ryOza72xPcVBOEkfps09421V1sHnYOu3BELMjOJTVsDrsYn8M6sSDimz6puIT1g23U9ffoHBYHcV/LjKWpKcqKxTBubwh/Kq8IIpg7MeuwFKW3BlGWhFred4w5aRBfxCnKqj01mYQyex3EBtPWHUtRLMPktPyH4L1lwADm2sVhmpmEzrtsoNg6xkuB6/ZiAsyE72I8mwjGC4M402VDjMnbC/Mg48uuYwaRADbM4bbJYaPAIWpiwVE564UV1yjvJmyg8A5WeGE1CXqAPbe0hbRLKXqKHqQXGCf0ZKYs+D+1WO7zCW7fRgAAAABJRU5ErkJggg==",O0={[L0]:F0,anchor:"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACQAAAAkCAYAAADhAJiYAAAACXBIWXMAABYlAAAWJQFJUiTwAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAOvSURBVHgBrVh/ThQxFP6WxUUIyMZNIPgjjiExaiCScADWE3gE4CTuDeQG6BE4AXoC+c9ojK6JkUhCWEUhEtbxfdtXppTO0Lp8yUun087063uvr32tIR1jItMiEyKTIqMidW3ri/wRORE5FPmh9WjUEvq2VKaQhiORPZH9mM4xhEggE2lo/RRm5j9FjmG00de2uvaz2mvCaBDa79tlxKoI8UdzIjNap+rtTPuIR0v/M6b1PSXWTyHEj+dFxmE0sqs/Ggac2F19prY+IOBfdYTJPBC5rh+8hzHPsPgNo92mjsGSpu9XEaKZHsL4AZ3xI8xsrgocvAfjl5ww/exAJC8jdFvkBoxmrpqMS4oap4boEiNwLOD6EJ0vg/GZd7Fk8jxvS/FEq1u1Wq2LONAKj2GUQn869DssiiyjWFUxZDr5RXQQjxkdc9FvaGnDAiIhA6/l5WgjHgs6NjkM7GeZEruIxzMtuyL3VXr6bhXxsOHkjBCXICMrnS0qvCuaWvboN+o7O/ouQzxsoOXKa3CZT2vDAdLwWqQtsiQm2tR3bS13EA8bCqihwSQZkc9sGAsh0RT5HPAfvsuQBuvDGU1mN80jpCGD8R8fXaTjWMtJ60NEahB8gcJELtralgK7p436h6sUbMHYPEPh4F0tXyEN7vFlYLvlqt4ac5ZK2tqO/6xU9LksFAx4jPjsAj/rSMFV9DYx4Nnv16TYFnlZEcXPWclGyvEQGW8FHfiaqtJQHo7mnQChCeXwiJUMgWXvDXSOVAKhMvjmt8t+nk59hOLw7kZqBrcNmKDV0XcdFNtDDNZF7nnfQ6K6Hzht4jDY8RvKjqwv+JGngdVL2lcC7WtV7Yol5dCgU9scimRC0ZqzsVqhTzURidxE7Oda5X73JtCtpWPTUid2t7emmvV7y09IZkOrGSJWW262FfbZRrHRdkq639LyQhJhV9tMySDb+f9jE2HMwjuHjTiNXxzGY/6XoqmnFbMsw2BByLfrgTaOMafPZ+cwPy+7A8O6NG9Sv+AZOhi5HXRhzti9EjJMtbigvot8LSNU144MVHSyT0i8LIiAm4Ty30wo+i4BF8yP3BQlmMwNScZNQmmFU7dDaP+yJzibYXJZ/oXJPIcBXYHn7muoSEKrLhtIdg5FKIi6vfDAneCm/sMeBOkzdOKkywYX/u2F1SCDqb2OOXUIcGCam9sBtWytQBN1RX5VDZZ6YcUYNYE0kPg+rvDCygc1wJlP6TPFXkpRU9QgtUA/oSaTjsb/AGKbNM0XZBjDAAAAAElFTkSuQmCC",binoculars:"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACQAAAAkCAYAAADhAJiYAAAACXBIWXMAABYlAAAWJQFJUiTwAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAANtSURBVHgBvVj/ShtBEJ4kNtagNTRFsT/wilBaECr0AZI+QfsG6Zv4CH2E4pvYN9C/iqXQCKWhgiRWqyQkPefLziTrubt3l0Q/GO72dnb329mZ3ZstUH4ssqyyVFiWWRZYSlI3ZOmx9FnOWc6knBmFHLo1kRXKh0uWE5bTLMpZCIFAxFKW8oDMzP+yXJGxxlDqSqKn1quSsSCJ3u80YiFC6GiDZU3KML3OdEjZUZN+FqV8IsSGeQih8RbLEhmLtKWjWYCJvZB3WOs7OfyrRG4yr1geSoMjMsszK/6RsW5VxsATSz8MEcIyvSbjB3DGH2RmMy9g8C4Zv8SE4WcdlthH6BnLIzKWmTcZmxQsDgvBJYpkrYBNqCaE4DNHd0TGJgVLPSFjrQsdr2gpPZVnmwJk4jiusjQgAZ0d0YnID90GgFt6sM47lu1ABxgoim+i6dD5ZNV3MAEKY1vGBoexhXSvaac0jlLKwKb1DjJvKQzdTkaEEFUIQeysWNe07f2ApWGVjx06eyz7VvmQwsCYcBf4UhmEVqWiE2ol/vCBzKwVX/k7nk2LDPTqlg58aa9QKLQ8XauD17Rv7MjjNQwQ+hLfxq44r6Iu35L4TGGoD0fwIT00L1MaRTQ9opT6K3kug5Aeemn7TkTTYyelXs+0BRCyf66ckNCNaHpEKeE//n0pUjZ8pNmRZqURQMj+ufKhGahDhOyLdAN6u4G68SqB0EAKZZcmmxrWaXg6Ig7nA5b3IqE9J3TcqB/3QOhCChWPcsg6eeHra0mefRDScPf9vDdofmh4vuvY5yCk644ocPlR2uGYB5Hnu47RBSHNoUAmuFvfEWoyNlaqr2Gvh+o63T/0P2x06tuEsFsi0tYSDVrkh6vuOIf+uozZEw430iA4FrIN7EvfRElP+U1H52cIecd3tKmTG4fcRn0Wof6GzHK1XISA58LamzfNCZpqwTp/WH5pRTKqkDsh69AUBc6eJ0vNSmaLJnnfTwqkQaiwUxRnMjcjGTsJxSoMbAXXvqN/cJphIiz/k7HeLIArvGR5QIEkNHTZALIbNNkKMt1eJIBf5Mc0iSYAPoNkItdlg43k7YVaEP6l1zEDiwAGxnIjau3dH0vUosnZSdMSsolhj6pQPoD4Kc3xwioJWAAzX5F3iF5KwVKwIKwAP4Elc6Xk1wkZQmYK/e0tAAAAAElFTkSuQmCC",buildings:"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACQAAAAkCAYAAADhAJiYAAAACXBIWXMAABYlAAAWJQFJUiTwAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAN4SURBVHgBvVhtTlNBFD2ltQgRaWwCwY+kxMSokQTjAsQVuARxB+4A3AE7kCW4A3QFxl9GY6QmRiIJAS1CIK31HufednjOm86jL5zk9s1XZ87ce+fORwXFMSkyKzItckWkJlLVup7IicipSEfkp+aTUSnQtqkyg2I4EtkV2UtpnEKIBFoidc134Wb+S+QYThs9ratqO9NeA06D0HbfRxGLEWJHCyJzmqfqbaY9pKOp/UxqfleJ9YoQ4p9vi0zBaWRHOxoHnNgtTVNbnxDwryrCZO6IXNY/fIQzz7j4Dafdho7BL03fixGime7C+QGd8TPcbMoCBz+A80tOmH62L9LPI3RD5CqcZsom45OixqkhusQEPAv4PkTna8H5zIdUMv1+nx0/0wFieF+pVF57eVrhPpxS6E+d7B+WRB5huKpSyLREtvvpeJHpYk7HXLKCCf02lbEt7VQ8hdNqKtYy+V0ds64cBoRMKzsoBt9Mi2ISusBmpCxkVlPAgBCXICMrnS0pvIcg47Y12Y6VBWCBliuvzmU+qxX7ef8Q26/I53GgasVr80oHXo2VBWChgBpq1DDcLA8RJrOO/20fwjKcPzVGlIXQUUK0FO7BefoUwoT2U5aP134tpSyDaeXwwHyIyIs7NrtNddBFlA/b02rZw1UMbf7QUUMTlbItTS7HynIwOL7UkI5VJdLKqW+rsL4RKYuipuyqKjEtscMV5HQsmnvOr5JezyvLwcBK9KGuZuqIY0MGeCLyMFTJbUSTrVhZDsyPT6ihQwyD4zHOj+2Ab23nL6wzsBV+Sg0daWbU4Z0+tCXyDuXDxu5QQ4ySPFrSN2J+1EKxjbQIzC8PqCG7Q5FMExePpo5NS53abm+b6jwuHtf1+2/X9wnZuSR7QDtAecj2NY/hOWzPJ0R81S8ZT3rlL1EeNrw0x1jQ9OAclr2X3YRjfebeJCuLJ8NR4X8U3kgMe+uR4VWL2vkh8i2PUFUbMibRyb6g4GNBAvxLKPvmhaLnE/DBKOZfUYKXuTHJ+JdQWqHrNwjdXO0EZzdMLss/cDfPcUBX4NHlEiKX0NhjA8kuYBgKkl4vMmDgvYbhaiLoM3TiQo8NPrKvF6ZBBlN7jul6BDgwzc3twKI/QRO1kXNULkLIJ8YYNY1iIPE9lPhglQU1wJnPaJpiBz1qihqkFugn1GSh94G/iZph1Go7mo4AAAAASUVORK5CYII=",plane:"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACQAAAAkCAYAAADhAJiYAAAACXBIWXMAABYlAAAWJQFJUiTwAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAN7SURBVHgBrVh/alNBEP7SaKqltcFAS/2BTwqiQrHgAawnsDdQb6AnaG+gnsB6gtoTVE9g/xNFNIJYDJSq1RYlMc7XnUnWdfPyNnkfDC+Tt2/325nZ2Z2tIB2TIrMiUyLTIidEqvquI/JL5LfIgcg31QujktC2oTKDNByKtET2ijQuQogEMpGa6m24mX8XOYKzRkffVbWdWa8OZ0Fou8/DiOURYkcLInOq0/Q20w6Ko6H9TKreUmKdFEL8eFHkNJxFdrWjccCJXdTftNZbROKrijiZKyKn9IM3cO4ZFz/hrFvXMfik6zt5hOimq3BxwGB8BzebssDBv8LFJSfMONsX6Q4idF7kDJxlyibjk6LFaSGGxAQ8D/gxxODL4GLmdR6Zbrd7Tx6XVG1WKpVnSAe9cB3OKIyng7DBkshN9FcVcghtd//FCkbDnI65ZH9M6LOhjG1pD8PzQH+K0dDSMWvKoUfIrLJbrB+8DPRMrPQAo8EM0LA/uARptmUkQAjsB26jXkc6qjo2OdRooVl9sR8MyFmvqWSRjjYCnWTWkA5LBdbHcUYmu0aEkOFDOHvRV7txZEhHQzlktJBtmod+C1nKTXk0Vc1ENoNOXiCOUQL8SJ/TJGSbXizv+KtpxTcDAhcPaufhVU7g2552goT8w1WILZQHBu4jEou86x1fJoZ0soPysSykBq5oEvIPV/99jPKxI/EZTrTnJRJqq1KLfHwX5aEpsi5yO/LO4vg4ljJElj2hy92wHbyrDwjeTaTDlv0iLWTLfSYYcFnJQmd3P+hkBXE8RDps7AMeyJglebRk4qMvOx6Jdf29pXnJx51IxxuRdkVgSdcy9vGRtdDRwxC407J5hnSYu65RsWVvpcl8kR4Cdxoej2idc/pshYTsXFLESrcCnafGJ0jHPPrnsD2fEPERfcaTQzpaDfR1pINjLOjv3jksrMsuwLEeWDcR3OnlcUPVUc7UVmrROl9EPg0iVNWGLIWZDt4j8bKgIBkrQtk3C4qOT8AHd3G/RIkWc2OS8YtQeqHtN4jtX3aCswqTy/IPXOU5DhgKl0VOIqcIzbtsINkF9FNBoduLAEy8Z9FfTQRjhkGcdNngI7y9MAuysLPrmLZHgAPT3dwOLPsTdFFT5EfeYKkXVsxRU0gDie+hxAurELQAZz6jvyl2KUVL0YK0AuOElky6H/gLKkCOaXDL55gAAAAASUVORK5CYII=",ship:"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACQAAAAkCAYAAADhAJiYAAAACXBIWXMAABYlAAAWJQFJUiTwAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAPUSURBVHgBrVhbTlNRFF2lWKQBaSTBoJjUmBBjJNY4ADsD/fULHIE4AuoI1BEAf/7pDCgjkA8TojEK0UgkIagoBNJa9+rZmx5u7uNc2pXs3Md5rbPP2udVQH6MiE2IlcXGxIbFiprWFjsWOxE7EPul38Eo5Mg7qTaOfDgU2xXbC8kcQogEqmIl/W7B9fy32BGcN9qaVtR85r0KnAeh+b5nEUsjxIqmxab0m663nrYRjkmtZ0S/d5VYOw8hFr4pNgrnkR2tqB+wY9f1nd76iBh9FRFPZlbsohb4ADc8/eIvnHcr2gafHPp2GiEO0y04HVCMn+B6Myiw8Z9wumSHqbN9sU4SoWtil+A8M2gyPil6nB6iJIbgjYCvIYqvCqeZzSwynU6HeecTklcLhcIW0sFRuA3nFOrpIJphTuw+elGFDEJrnWS8QRimtM05+zGkz0llbKHdLyqB+Xa1zZJyOCVkXtlJKskh8r0iv+pIRt3zFstUMkjBJ8QQ5MxKsaXNog8zSCSSQ7LWgN5Ey8grMcwnNGEf6fB72UAYGjFlo7CpgB6qDKO3WP5BICSCnofkk6FqIAwHSqhMQrZoHuIcUH1wSNjL9YBwj8ORPsdIyBa94EnQI/EIEV1JWlMeKySHcNiaNhzdXKXB10Ga3urIL/7T7ctQVk7p8SJDV14XcX40NPznszJy6ajBeWkDES/p0GRFXy6IxuK2PEXl0aaHWvqzFFOYQl3F4LCS8N90fExCFu7luJxCagGDIfVS6nqSkDaqzxMSsnBP3LwrqQbOj4bU8Swl3drurvgcKq64pqVEiKaWYlb2fbEXYsv6HsUSslFTDiUT2Kyy/IqE1V4qrkkvN+S5ALeuUfBNsVeaxaaFp9oA9cdhWreyiIftwzhSm/7PM/sSjwhX7nfa2y8MXVu9Na3heWOZjWtaheQjZWsxhGwf1l3t/RC8A6f2rpc6bke4puwHiS2xexrBV8Rm4Gbq90z0J8ZtfV5F71RQ1X8s/FYri0NTLQ5W1lAVu6ttTOu/031YdJKaUdbdc5N46THc9mRVe8SheACnkYoSbEratqZZY6ahDWrIS6vzVf69htMtA+qH2LckQkXNyDmJIvuMnJcFAfAPoaybQm77BHxwa+ofUWIPc32S8Q+hPG20/Axx847t4OyESfX/gzt59gNK4YbYBaQcQtMuG0h2WisCAm8vIuD25rLWYWslNUMR57ps8BG9vTAPcpq365iWR4ANc7g50dLLNgocoi1kbJXzXljxuFRGPpD4HgZ4YRUFPcCej+s7zS6l6Cl6kF6gTujJXPcD/wGeSq3AuYqaLwAAAABJRU5ErkJggg==",signs:"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACQAAAAkCAYAAADhAJiYAAAACXBIWXMAABYlAAAWJQFJUiTwAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAANaSURBVHgBxVgNahNBFP7SxNYGa4uFlvgDEUEUChY8gN5APIF6hJ5APEHrCWxPUrxBQVAsIhHFYCEk9ZeUxPi+znub6TK7mc1G/eCx2czszDfvb95MBcWxILIsUhe5IFITqWrbUKQvciLyTeRY36NRKdB3VWUJxfBT5EikE9M5hhAJNEXm9X0At/KvIr/gtDHUtqr2M+2twGkQ2u/zJGJ5hDhQQ2RN36l6W+kQ8VjVcRb0/UiJDYsQ4sc3RBbhNNLWgcqAC7umv6mtQwT8q4owmZsi5/WDt3DmKYsfcNpd0Tn4pOmHeYRopltwfkBnfAe3mlmBk/fg/JILpp91RUZZhK6IXITTzKzJ+KSocWqILjEHzwJzXkc6H+1MnzksQmY0Gj0WeYR4mA8Ndc4kldS8Tpf12UaAjEy4CbeqNO6I7GgfBkkr0KdVqVRaAVKMNjp6U+SV30jt3BXZCAzGiV6MyqGrCwphQ+cmh8RklmvaGR81UQ7U7H4GKUsnCSGGIDMr7RmV3kuQehD43xIt/WiehJa1oZszWA/lsSt+9Czwv6UCYqWGsYd/RzaeI+zQsTgQMls57awMaLI6o+I2nMlew22W/wN15dE3HyKmSoLiqPe9aLqH6WB7Wi1dXGVNSnNtIxxtvil3pG+Wv22J2Q4y2pLypYYJUDL7IpuYjLw+T0UeYgLmcLa4CmEbcWQmIS8oEiuR0EBf5jM6v8Tfh/nxqVNbuNdDPcXuu/J4gvJo5bQt6vOEYW+VXCfvI037y5gOxzkOTTTh8tBHOnVPCdHGtGW41s0YUIg25WGlx15gV4+B+VcSoSxZueOuoSBmkIes0mBiTHZ721TX8e9hddjpru8TYrZkpBXWUgms65x95XCmhP2gTzJeQDymrQQ4R0N/J3VY+lx2FY515rkpBNbUfIhD7yEOdtSidr6IfMoiVNWOzEk8Br1HwcuCSDJ2COXYb+BFdnq74PnIP6IED3MlyfiHUFph4HcI7V9WwdkJk2H5G+7kWQZ0hesi55BzCM27bCDZBsapIOr2IgUm3ksYRxNBn6ETF7ps8JG+vTANsuy065iBR4AT09wsjS37EzRRC/mlcuELK+aoOoqBxDuY4YVVGtQAV76kvylW6FFT1CC1QD+hJguVxn8As7g2RiIyRIwAAAAASUVORK5CYII="},Ju=Object.entries(O0),D0="#999",U0=36+36*~~(Ju.length/4),Db=(e,t,n,i)=>{e.beginPath(),e.arc(n+18,i+18,18,0,2*Math.PI,!1),e.fillStyle=t,e.fill()},Ub=async(e,t,n,i,r,s)=>{const o=new Image;o.src=t,await o.decode(),e.drawImage(o,0,0,n,i,r,s,n,i)},Bb=e=>["clamp",["-",["var","elapsed"],["get","timestamp"]],0,e],zb=async e=>{const t=document.createElement("canvas");t.width=144,t.height=U0;const n=t.getContext("2d");n.imageSmoothingEnabled=!1;const i=["match",["get","asset"]];for(let o=0;o<Ju.length;o++){const[a,l]=Ju[o],c=e[a]??D0,u=o%4*36,h=36*~~(o/4);Db(n,c,u,h),await Ub(n,l,36,36,u,h),i.push(a),i.push([u,h])}i.push([0,0]);const r=t.toDataURL("image/png"),s=((o,a,l)=>["interpolate",["linear"],Bb(l),0,o,l,a])(0,1,150);return{variables:{elapsed:0},"icon-src":r,"icon-scale":[.5,.5],"icon-color":"#fff","icon-width":144,"icon-height":U0,"icon-size":[36,36],"icon-offset":i,"icon-opacity":s}},jb={__name:"cb-poi-marker",props:{asset:{type:String,default:void 0},text:{type:String,default:""},active:{type:Boolean,default:!1},visible:{type:Boolean,default:!1},colors:{type:Object,default:()=>({})}},setup(e,{expose:t}){Lp(a=>({"7558dbcc":o.value}));const n=e,i=le(null),r=te(()=>n.asset??L0),s=te(()=>O0[r.value]??F0),o=te(()=>n.colors[r.value]??D0);return t({marker:i}),(a,l)=>yt((I(),O("div",{ref_key:"marker",ref:i,class:ve(["cb-poi-marker",{"cb-active":e.active}])},[S("span",null,Z(e.text),1),S("i",{style:Ln({"background-image":`url(${s.value})`})},null,4)],2)),[[Ft,e.visible]])}},Nb=un(jb,[["__scopeId","data-v-169f04fc"]]);$n(`
.cb-poi-marker[data-v-169f04fc] {
        position: relative;
        padding-left: 20px;
        height: 20px;
        font-family: Inter, sans-serif;
        font-size: 12px;
        font-weight: 600;
        transform: translate(-10px, -50%);
        user-select: none;
        cursor: pointer;
        transition: all .15s;
}
.cb-poi-marker span[data-v-169f04fc] {
        display: block;
        line-height: 20px;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
        max-width: 200px;
        padding-left: 5px;
        opacity: 1;
        color: #000;
        text-shadow: 1px 0 #fff, -1px 0 #fff, 0 1px #fff, 0 -1px #fff;
        animation: expand-169f04fc .3s forwards;
}
@keyframes expand-169f04fc {
0% {
            max-width: 0px;
            opacity: 0;
}
100% {
            max-width: 200px;
            opacity: 1;
}
}
@keyframes scale-169f04fc {
0% {
            transform: scale(.9);
}
100% {
            transform: scale(1.1);
}
}
.cb-poi-marker i[data-v-169f04fc] {
        position: absolute;
        top: 0;
        left: 0;
        width: 20px;
        height: 20px;
        background-size: 20px 20px;
        border-radius: 10px;
        background-color: var(--7558dbcc);
        animation: scale-169f04fc .2s forwards;
}

    /*.cb-poi-marker.cb-active {
  color: #fff;
  background-color: v-bind(color);
}*/
.cb-poi-marker.cb-active span[data-v-169f04fc] {
        animation: none;
}
`);const B0="default",z0="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAADgAAAA4CAYAAACohjseAAAACXBIWXMAABYlAAAWJQFJUiTwAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAADDSURBVHgB7dbRDYJAEIThwQoogRLsQDrQjixBO6AFO8EOsJN1CSRqfBDPvcQj/5fs+02GhJEAAAAAAACwOmbW+p38Bnvo/Tq/RqXyx9d+Z/tsDF+rJHO43pbriwq5sLm3JlUCf2hj6VoF2yjeUen2CpYj4FbpDgpWKdj4nekHlVOgHA3+lRwBb0p3VbAcAS9KFx4wnE3TLFWjEtg0v75Vxo9+ZGufaqM55JImyxvbz2yabp29NjrMwXYCAAAAAADA6twBRVLyKutDICsAAAAASUVORK5CYII=",j0={[B0]:z0,bed:"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAADgAAAA4CAYAAACohjseAAAACXBIWXMAABYlAAAWJQFJUiTwAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAEfSURBVHgB7dfvbcIwFATwS9UBukHTCdoN2g0KE8AIMAFZgQmADdgANmAEsgEwgTmEP0SBoMh5iSG6n/T0iC0Ipzj/ABERERERERGR/nDODVh7VoY+YrCN8/DE3tBzvQ/4DkNcrR9sE9a3H1onSbIqzC/Y0po/dyx/v1P3zkF+3LlbEz83cGEyxFAOyDau+IOHy5F9MF/HHwJZnoO/FeOXZZuimRECWQY8Bs7VkSKQZcA57gdZ8kKRIxKzgD7EkJUXhtesKSIyvU0w5JbtixeFT/YTt5suzcZMAjLQrGK8uPmDCKyOYIYnpWfRV2e1RJdoxxixuA7eBwuPahsEarJE81JvQ17q3fEP0P/u+orU1j5S1qjNfYiIiIiIiIi8pDOH6SxD93KzhgAAAABJRU5ErkJggg==",binoculars:"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAADgAAAA4CAYAAACohjseAAAACXBIWXMAABYlAAAWJQFJUiTwAAAAAXNSR0IArs4c6QAAAARnQU1BAACxjwv8YQUAAAEoSURBVHgB7dePjYIwFAbwj8sNcDcBHeFG4Da4DTw3cAPcwBmYxDiJjOAG9ZE0RgmWSj8i0e+XGAJ9rTzoPwARERERERF5RwVm4L3/t0MZTpuiKNo7cc4Oq3DaWlyDpeuS87eOkdhjL3YFsg/wlb1zF4l1D8RO8gm+g/22ibHbgbryNDaG9n5AKKuvLtXh2pAdiGhj0G6sskOFfBtrqwQJc5L5As8PSJgJ0p46iLMpM0EHHgcSZoIVeJbVRcOWi3ZTpgptZmMt9HVCzPUGIGVB79pc49m6J+1HROqOccjE6KIpb2+q7M03I0Hm2Ov7Q6bs78FYF7z8iZlY92RVv5Fh6QnerZtqju/BRVGCCdqM8lhZSvkoxkL/i/h03sxUV0RERERERERe1hk6ZuIvJ+k3KQAAAABJRU5ErkJggg=="},eh=Object.entries(j0),N0="#666",fo=68,G0=fo+~~(eh.length/4)*fo,Gb=(e,t,n,i)=>{e.beginPath(),e.arc(n+28,i+28,22,0,2*Math.PI,!1),e.fillStyle=t,e.fill()},V0=async(e,t,n,i,r,s)=>{const o=new Image;o.src=t,await o.decode(),e.drawImage(o,0,0,n,i,r,s,n,i)},Vb=e=>["clamp",["-",["var","elapsed"],["get","timestamp"]],0,e],th=(e,t,n)=>["interpolate",["linear"],Vb(n),0,e,n,t],$b={__name:"cb-product-marker",props:{asset:{type:String,default:void 0},text:{type:String,default:""},active:{type:Boolean,default:!1},visible:{type:Boolean,default:!1},colors:{type:Object,default:()=>({})}},setup(e,{expose:t}){Lp(a=>({b2fbc14c:o.value}));const n=e,i=le(null),r=te(()=>n.asset??B0),s=te(()=>j0[r.value]??z0),o=te(()=>n.colors[r.value]??N0);return t({marker:i}),(a,l)=>yt((I(),O("div",{ref_key:"marker",ref:i,class:ve(["cb-product-marker",{"cb-active":e.active}])},[S("span",null,Z(e.text),1),S("i",{style:Ln({"background-image":`url(${s.value})`})},null,4)],2)),[[Ft,e.visible]])}},qb=un($b,[["__scopeId","data-v-3b260374"]]);$n(`
.cb-product-marker[data-v-3b260374] {
        position: relative;
        padding-left: 24px;
        /*height: 28px;*/
        border: 1px solid rgba(0, 0, 0, .4);
        background-color: #fff;
        border-radius: 14px;
        font-family: Inter, sans-serif;
        font-size: 13px;
        font-weight: 600;
        box-shadow: 0 1px 2px rgba(0, 0, 0, .1);
        transform: translate(-50%, -50%);
        user-select: none;
        cursor: pointer;
        transition: all .15s;
        margin-top: -20px;
}
.cb-product-marker[data-v-3b260374]::after {
        content: '';
        position: absolute;
        left: 50%;
        bottom: -5px;
        background-color: #fff;
        width: 9px;
        height: 9px;
        box-shadow: inset -1px 0 rgba(0,0,0,.4), inset 0 -1px rgba(0,0,0,.2), 1px 0 rgba(0,0,0,.2), 0 1px rgba(0,0,0,.2);
        transform: rotate(45deg);
        margin-left: -4.5px;
        transition: all .15s;
}
.cb-product-marker span[data-v-3b260374] {
        display: block;
        line-height: 26px;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
        max-width: 200px;
        padding: 0 9px 0 4px;
        opacity: 1;
        animation: expand-3b260374 .3s forwards;
}
@keyframes expand-3b260374 {
0% {
            max-width: 0px;
            padding: 0;
            opacity: 0;
}
100% {
            max-width: 200px;
            padding: 0 9px 0 4px;
            opacity: 1;
}
}
.cb-product-marker i[data-v-3b260374] {
        position: absolute;
        top: 2px;
        left: 2px;
        width: 22px;
        height: 22px;
        background-size: 28px auto;
        background-position: -3px -3px;
        border-radius: 12px;
        background-color: var(--b2fbc14c);
}
.cb-product-marker.cb-active[data-v-3b260374] {
        color: #fff;
        background-color: var(--b2fbc14c);
}
.cb-product-marker.cb-active[data-v-3b260374]::after {
        background-color: var(--b2fbc14c);
}
.cb-product-marker.cb-active span[data-v-3b260374] {
        animation: none;
}
.cb-product-marker.cb-active i[data-v-3b260374] {
        background-color: rgba(0,0,0,.4);
        /*background: #fff;
  -webkit-mask-image: url(https://resources.citybreak.com/peter_test/map/invert.png);
  mask-image: url(https://resources.citybreak.com/peter_test/map/invert.png);
  -webkit-mask-size: 26px 26px;
  mask-size: 26px 26px;
  -webkit-mask-position: -3px -3px;
  mask-position: -3px -3px;*/
}

`);const Xb={__name:"cb-marker-overlay",props:{map:{type:Object,required:!0},coordinates:{type:Object,default:void 0},asset:{type:String,default:void 0},text:{type:String,default:""},active:{type:Boolean,default:!1},visible:{type:Boolean,default:!1},type:{type:String,required:!0,validator:e=>["poi","product"].indexOf(e)!==-1}},setup(e){const t=e,n={poi:Nb,product:qb},i=le(null),r=new Gu({position:t.coordinates,stopEvent:!1});return t.map.addOverlay(r),We(()=>{r.setElement(i.value.marker)}),Re(()=>t.coordinates,()=>{r.setPosition(t.coordinates)},{deep:!0}),(s,o)=>(I(),ce(ai(n[e.type]),{ref_key:"element",ref:i,asset:e.asset,text:e.text,active:e.active,visible:e.visible},null,8,["asset","text","active","visible"]))}},Wb={__name:"cb-marker-interaction",props:{map:{type:Object,required:!0},layer:{type:Object,required:!0},colors:{type:Object,default:()=>({})},type:{type:String,required:!0,validator:e=>["poi","product"].indexOf(e)!==-1}},setup(e){const t=e,n=t.layer.getSource(),i={id:void 0,map:t.map,coordinates:void 0,text:"",active:!1,colors:t.colors,visible:!1,type:t.type},r=Xe([{...i},{...i}]),s=(u,h,p)=>{u.id=h.getId(),u.coordinates=h.get("geometry").flatCoordinates,u.asset=h.get("asset"),u.text=h.get("text"),u.active=p,u.visible=!0},o=u=>{for(const h of u)Object.assign(h,i)},a=(u,h)=>u.active-h.active,l=u=>{if(u.dragging||!La(u))return;const h=t.map.getFeaturesAtPixel(u.pixel)[0];if(!h||!n.hasFeature(h)){const m=r.filter(_=>!_.active);return void o(m)}const p=h.getId();if(r.filter(m=>m.id===p)[0])return;const f=r.sort(a)[0];s(f,h,!1)},c=u=>{const h=t.map.getFeaturesAtPixel(u.pixel)[0];if(!h||!n.hasFeature(h)){const _=r.filter(y=>y.active);return void o(_)}const p=h.getId(),f=r.filter(_=>_.active&&_.id!==p);o(f);const m=r.sort((_=>(y,x)=>y.id===_?-1:x.id===_?1:0)(p))[0];s(m,h,!0)};return We(()=>{t.map.on("pointermove",l),t.map.on("click",c)}),(u,h)=>(I(!0),O(be,null,Qe(r,(p,f)=>(I(),ce(D(Xb),Bi({key:f,ref_for:!0},p),null,16))),128))}},Yb={class:"vg--popout"},Zb={class:"cb--content"},Hb={class:"cb-extra cb-text-small"},Kb={key:0,class:"cb-text-muted"},Qb={__name:"cb-poi-content",props:{isLoading:{type:Boolean,default:!1},id:{type:String,required:!0},name:{type:String,required:!0},description:{type:String,default:""}},setup(e){const t=e,{set:n}=Ye("cb-query-parameters"),i=()=>{const r=Object.entries({st:"poi",so:"a",state:t.id}).map(([s,o])=>`${s}=${o}`).join(";");n("sorting",r)};return(r,s)=>(I(),O("div",Yb,[S("div",Zb,[S("b",null,Z(e.name),1),S("div",Hb,[e.description?(I(),O("span",Kb,Z(e.description),1)):ie("",!0),S("a",{href:"javascript:void(0);",class:"cb-text-icon cb-text-small",onClick:i},[s[0]||(s[0]=S("span",{class:"cb-icon-aws cb-icon-aws--stronger cb--location-dot"},null,-1)),S("b",null,Z(r.$t("Map.Poi.SortByDistance")),1)])])])]))}},Jb={class:"vg--popout"},ex=un({},[["render",function(e,t){return I(),O("div",Jb,t[0]||(t[0]=[S("div",{class:"cb--content"},[S("b",null,[S("span",{class:"cb-text-ph",style:{width:"120px"}}," ")]),S("div",{class:"cb-extra cb-text-small"},[S("div",null,[S("span",{class:"cb-text-ph",style:{width:"70px"}}," ")])])],-1)]))}]]),tx={__name:"cb-poi",props:{isLoading:{type:Boolean,default:!1},id:{type:String,required:!0},name:{type:String,required:!0},description:{type:String,default:""}},setup(e){const t=e;return(n,i)=>e.isLoading?(I(),ce(ex,{key:1})):(I(),ce(Qb,Po(Bi({key:0},t)),null,16))}},nx=un(tx,[["__scopeId","data-v-61e8e286"]]);function nh(e,t){t===void 0&&(t={});var n=t.insertAt;if(e&&!(typeof document>"u")){var i=document.head||document.getElementsByTagName("head")[0],r=document.createElement("style");r.type="text/css",n==="top"&&i.firstChild?i.insertBefore(r,i.firstChild):i.appendChild(r),r.styleSheet?r.styleSheet.cssText=e:r.appendChild(document.createTextNode(e))}}$n(`.vg--popout[data-v-61e8e286] {
    border: var(--vg-popout-border-width) solid var(--vg-popout-border-color);
    border-radius: var(--vg-popout-border-radius);
    background-color: var(--vg-popout-background-color);
    box-shadow: var(--vg-popout-box-shadow);
    color: var(--vg-popout-color);
    width: 250px;
    overflow: hidden;
}
[data-v-61e8e286] .cb--content {
    display: block;
    padding: 15px;
    color: currentColor;
    text-decoration: none !important;
}
[data-v-61e8e286] .cb--content .cb-extra {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    column-gap: 7px;
    font-size: var(--vg-body-small-font-size);
    line-height: var(--vg-body-small-line-height);
    margin-top: 2px;
}`);const ix=["innerHTML"],rx={__name:"cb-badge",props:{type:{type:String,validator:e=>["default","discount","fewleft","cancelled","preliminary","custom"].indexOf(e)!==-1,default:"default"},value:{type:String,required:!0}},setup(e){const t=e,n=te(()=>({"cb-badge":t.type!=="custom","cb-badge--discount":t.type==="discount","cb-badge--fewleft":t.type==="fewleft","cb-badge--cancelled":t.type==="cancelled","cb-badge--preliminary":t.type==="preliminary"}));return(i,r)=>(I(),O("span",{class:ve([n.value]),innerHTML:e.value},null,10,ix))}},ih=(e,t)=>{const n=e.__vccOpts||e;for(const[i,r]of t)n[i]=r;return n},ox={key:0,class:"cb-badges"},sx={__name:"cb-badges",props:{badges:{type:Array,default:()=>[]}},setup:e=>(t,n)=>e.badges?(I(),O("div",ox,[(I(!0),O(be,null,Qe(e.badges,i=>(I(),ce(rx,{key:i.value,type:i.type,value:i.value},null,8,["type","value"]))),128))])):ie("",!0)},ax=ih(sx,[["__scopeId","data-v-0b07fb2a"]]);nh(`.cb-badges[data-v-0b07fb2a] {
    position: absolute;
    top: 15px;
    left: 0;
    display: flex;
    flex-direction: column;
    row-gap: 5px;
    font-size: var(--vg-body-small-font-size);
    pointer-events: none;
    z-index: 1;
}
.cb-badges[data-v-0b07fb2a] .cb-badge-recommended > span {
        height: 70px;
        max-width: 105px;
}
@container (max-width: 500px) {
.cb-badges[data-v-0b07fb2a] .cb-badge-recommended > span {
            height: 63px;
            max-width: 94px;
}
}
@container (max-width: 500px) {
.cb-badges[data-v-0b07fb2a] .cb-badge {
            font-size: 90%;
            border-top-left-radius: 0;
            border-bottom-left-radius: 0;
}
}`);const lx={__name:"cb-button",props:{secondary:{type:Boolean},loading:{type:Boolean},active:{type:Boolean},disabled:{type:Boolean},iconOnly:{type:Boolean},size:{type:String,default:null,validator:e=>!e||["small","large"].indexOf(e)!==-1}},emits:["click"],setup(e,{emit:t}){const n=e,i=t,r=te(()=>({"cb-btn":!0,"cb-btn-primary":!n.secondary,"cb-btn-secondary":n.secondary,"cb-btn-sm":n.size==="small","cb-btn-lg":n.size==="large","cb-btn-icon-only":n.iconOnly,"cb-loading-custom":n.loading,"cb-active":n.active,"cb-disabled":n.disabled})),s=o=>{n.disabled||i("click",o)};return(o,a)=>(I(),O("a",{class:ve([r.value]),href:"javascript:void(0)",onClick:s},[S("span",null,[Me(o.$slots,"default")]),Q(D(Hf),{loading:e.loading},null,8,["loading"])],2))}},rh=lx,cx={__name:"cb-button-link",props:{href:{type:String,required:!0},secondary:{type:Boolean},active:{type:Boolean},iconOnly:{type:Boolean},size:{type:String,default:null,validator:e=>!e||["small","large"].indexOf(e)!==-1}},setup(e){const t=le(!1),n=le(!1),i=()=>{t.value=!0,n.value=!0};return window.addEventListener("pagehide",()=>{t.value=!1,n.value=!1}),(r,s)=>(I(),ce(D(rh),{href:e.href,loading:t.value,disabled:n.value,secondary:e.secondary,active:e.active,"icon-only":e.iconOnly,size:e.size,onClick:i},{default:ye(()=>[Me(r.$slots,"default")]),_:3},8,["href","loading","disabled","secondary","active","icon-only","size"]))}},ux=cx,hx={__name:"cb-price",props:{price:{type:Object,default:()=>({})},type:{type:String,default:"strike-through",validator:e=>Zf.indexOf(e)!==-1},translations:{type:Object,required:!0}},setup:e=>(t,n)=>(I(),ce(ai(D(rb)(e.type)),{price:e.price,translations:e.translations},null,8,["price","translations"]))},dx=ih(hx,[["__scopeId","data-v-8914bfd6"]]);nh(`[data-v-8914bfd6] .vgo-pricing__main {
    display: flex;
    flex-wrap: wrap;
    column-gap: .35em;
    align-items: baseline;
}
[data-v-8914bfd6] .vgo-pricing__strike {
    text-decoration: line-through;
    opacity: var(--vg-text-muted-opacity);
    font-size: var(--vg-body-small-font-size);
    line-height: var(--vg-body-small-line-height);
}
[data-v-8914bfd6] .vgo-pricing__price--discount {
    color: var(--vg-text-discount);
}
[data-v-8914bfd6] .vgo-pricing__definition {
    opacity: var(--vg-text-muted-opacity);
}
[data-v-8914bfd6] .vgo-pricing__yousave {
    color: var(--vg-text-discount);
    font-size: var(--vg-body-small-font-size);
    line-height: var(--vg-body-small-line-height);
}`);const px={__name:"cb-score-rating",props:{rating:{type:Number,required:!0}},setup(e){const t=e,n=te(()=>{const i=10*Math.round(t.rating/10);return`cb-score-rating cb--${Math.max(0,Math.min(100,i))}`});return(i,r)=>(I(),O("span",{class:ve(n.value),innerHTML:"<span><i></i></span> "},null,2))}},gx=ih(px,[["__scopeId","data-v-80486437"]]);nh(`
@keyframes cb-score-rating-80486437 {
0%, 50% {
            width: 0;
            opacity: 0;
}
}
.cb-score-rating[data-v-80486437] {
        position: relative;
        display: inline-block;
        width: 64px;
}
.cb-score-rating[data-v-80486437]  span,
            .cb-score-rating[data-v-80486437]  i,
            .cb-score-rating[data-v-80486437]  span::before,
            .cb-score-rating[data-v-80486437]  span:after {
                position: absolute;
                width: 100%;
                mask-repeat: repeat-x;
                -webkit-mask-repeat: repeat-x;
                mask-position: left;
                -webkit-mask-position: left;
                mask-size: contain;
                -webkit-mask-size: contain;
}
.cb-score-rating[data-v-80486437]  span {
                display: block;
                padding-top: 18.75%;
                top: 50%;
                transform: translateY(-50%);
}
.cb-score-rating[data-v-80486437]  span i,
                .cb-score-rating[data-v-80486437]  span::before,
                .cb-score-rating[data-v-80486437]  span::after {
                    content: '';
                    position: absolute;
                    top: 0;
                    bottom: 0;
                    left: 0;
}
.cb-score-rating[data-v-80486437]  span i {
                    -webkit-mask-image: var(--vg-score-rating-fill-backdrop);
                    mask-image: var(--vg-score-rating-fill-backdrop);
                    background-color: currentColor;
                    opacity: .1;
}
.cb-score-rating[data-v-80486437]  span::before {
                    -webkit-mask-image: var(--vg-score-rating-fill);
                    mask-image: var(--vg-score-rating-fill);
                    background-color: var(--vg-score-rating-fill-color);
                    animation: cb-score-rating-80486437 .4s ease-out forwards;
                    opacity: 1;
}
.cb-score-rating[data-v-80486437]  span::after {
                    -webkit-mask-image: var(--vg-score-rating-fill-overlay);
                    mask-image: var(--vg-score-rating-fill-overlay);
                    background-color: var(--vg-score-rating-fill-overlay-color);
                    animation: cb-score-rating-80486437 .4s ease-out forwards;
                    opacity: 1;
}
.cb-score-rating.cb--10[data-v-80486437]  span::before {
                    width: 11%;
}
.cb-score-rating.cb--10[data-v-80486437]  span::after {
                    width: 11%;
}
.cb-score-rating.cb--20[data-v-80486437]  span::before {
                    width: 20%;
}
.cb-score-rating.cb--20[data-v-80486437]  span::after {
                    width: 20%;
}
.cb-score-rating.cb--30[data-v-80486437]  span::before {
                    width: 31%;
}
.cb-score-rating.cb--30[data-v-80486437]  span::after {
                    width: 31%;
}
.cb-score-rating.cb--40[data-v-80486437]  span::before {
                    width: 40%;
}
.cb-score-rating.cb--40[data-v-80486437]  span::after {
                    width: 40%;
}
.cb-score-rating.cb--50[data-v-80486437]  span::before {
                    width: 51%;
}
.cb-score-rating.cb--50[data-v-80486437]  span::after {
                    width: 51%;
}
.cb-score-rating.cb--60[data-v-80486437]  span::before {
                    width: 60%;
}
.cb-score-rating.cb--60[data-v-80486437]  span::after {
                    width: 60%;
}
.cb-score-rating.cb--70[data-v-80486437]  span::before {
                    width: 71%;
}
.cb-score-rating.cb--70[data-v-80486437]  span::after {
                    width: 71%;
}
.cb-score-rating.cb--80[data-v-80486437]  span::before {
                    width: 80%;
}
.cb-score-rating.cb--80[data-v-80486437]  span::after {
                    width: 80%;
}
.cb-score-rating.cb--90[data-v-80486437]  span::before {
                    width: 91%;
}
.cb-score-rating.cb--90[data-v-80486437]  span::after {
                    width: 91%;
}
.cb-score-rating.cb--100[data-v-80486437]  span::before {
                    width: 100%;
}
.cb-score-rating.cb--100[data-v-80486437]  span::after {
                    width: 100%;
}
`);const fx={class:"vg--popout"},mx={key:0},vx=["href"],_x=["src"],yx={key:1,class:"vg--photo"},bx=["href"],xx=["innerHTML"],wx={class:"cb-extra"},Ex={key:0,class:"cb-score"},Cx={__name:"cb-product-content",props:{isLoading:{type:Boolean,default:!1},url:{type:String,required:!0},imageUrl:{type:String,default:void 0},name:{type:String,required:!0},rating:{type:Number,default:void 0},badges:{type:Array,default:()=>[]},prepend:{type:String,default:void 0},pricing:{type:Object,default:()=>({})}},setup(e){const t=e,n=Ye("priceType","strike-through"),i=Nt(),r=te(()=>t.prepend),s=te(()=>({priceFrom:i.proxy.$t("Map.Popup.Price.From"),discount:i.proxy.$t("Map.Popup.Price.YouSave"),priceOriginal:i.proxy.$t("Map.Popup.Price.Original")}));return(o,a)=>(I(),O("div",fx,[e.isLoading?ie("",!0):(I(),O("div",mx,[e.imageUrl?(I(),O("a",{key:0,href:e.url,class:"vg--photo"},[Q(D(ax),{badges:e.badges},null,8,["badges"]),S("img",{src:e.imageUrl},null,8,_x)],8,vx)):(I(),O("div",yx,a[0]||(a[0]=[S("div",{class:"vg--noimage"},null,-1)]))),S("a",{href:e.url,class:"cb--content"},[S("div",null,[r.value?(I(),O("div",{key:0,class:"cb-prepend",innerHTML:r.value},null,8,xx)):ie("",!0),S("b",null,Z(e.name),1),S("div",wx,[e.rating?(I(),O("span",Ex,[Q(D(gx),{rating:e.rating},null,8,["rating"])])):ie("",!0),Q(D(dx),{price:e.pricing,type:D(n),translations:s.value},null,8,["price","type","translations"]),Q(D(ux),{href:e.url,style:{"margin-top":"10px"}},{default:ye(()=>[je(Z(o.$t("Map.Popup.Choose")),1)]),_:1},8,["href"])])])],8,bx)]))]))}},Ax={class:"vg--popout"},Sx=un({},[["render",function(e,t){return I(),O("div",Ax,t[0]||(t[0]=[Qo('<div class="vg--photo"><div class="vg--noimage"></div></div><div class="cb--content"><b><span class="cb-text-ph" style="width:120px;"> </span></b><div class="cb-extra cb-text-small"><div><span class="cb-text-ph" style="width:70px;"> </span></div></div></div>',2)]))}]]),Tx={__name:"cb-product",props:{isLoading:{type:Boolean,default:!1},url:{type:String,required:!0},imageUrl:{type:String,default:void 0},name:{type:String,required:!0},rating:{type:Number,default:void 0},badges:{type:Array,default:()=>[]},prepend:{type:String,default:void 0},pricing:{type:Object,default:()=>({})}},setup(e){const t=e;return(n,i)=>e.isLoading?(I(),ce(Sx,{key:1})):(I(),ce(Cx,Po(Bi({key:0},t)),null,16))}},Rx=un(Tx,[["__scopeId","data-v-30016535"]]);$n(`.vg--popout[data-v-30016535] {
    border: var(--vg-popout-border-width) solid var(--vg-popout-border-color);
    border-radius: var(--vg-popout-border-radius);
    background-color: var(--vg-popout-background-color);
    box-shadow: var(--vg-popout-box-shadow);
    color: var(--vg-popout-color);
    width: 250px;
    overflow: hidden;
}
[data-v-30016535] .vg--photo {
    position: relative;
    display: block;
    height: 150px;
    overflow: hidden;
    background-color: var(--vg-popout-option-hover-background);
    color: currentColor;
}
[data-v-30016535] .vg--photo img {
    object-fit: cover;
    object-position: center;
    width: 100%;
    height: 100%;
}
[data-v-30016535] .vg--photo .vg--noimage {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%,-50%);
    -webkit-mask-image: var(--vg-noimage-background);
    mask-image: var(--vg-noimage-background);
    mask-repeat: no-repeat;
    -webkit-mask-repeat: no-repeat;
    mask-position: center;
    -webkit-mask-position: center;
    mask-size: contain;
    -webkit-mask-size: contain;
    width: 70%;
    height: 70%;
    max-width: 150px;
    max-height: 100px;
    background-color: currentColor;
    opacity: .15;
}
[data-v-30016535] .cb--content {
    display: block;
    padding: 15px;
    color: currentColor;
    text-decoration: none !important;
}
[data-v-30016535] .cb--content .cb-extra {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    column-gap: 7px;
    font-size: var(--vg-body-small-font-size);
    line-height: var(--vg-body-small-line-height);
    margin-top: 2px;
}
[data-v-30016535] .cb-badges {
    position: absolute;
    z-index: 1;
    top: 8px;
    bottom: 8px;
    left: 0;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
}
[data-v-30016535] .cb-badges > * {
    margin: 2px 0;
}
[data-v-30016535] .cb-badge {
    border-top-left-radius: 0;
    border-bottom-left-radius: 0;
    font-size: 12px;
}
[data-v-30016535] .cb-badge-recommended {
    flex-grow: 1;
}`);const kx={key:0,class:"vg--popout-pager"},Px={__name:"cb-popup-pager",props:{ids:{type:Array,default:()=>[]},modelValue:{type:String,default:void 0}},emits:["update:modelValue"],setup(e,{emit:t}){const n=e,i=t,r=te({get:()=>n.modelValue,set(u){i("update:modelValue",u)}}),s=te(()=>n.ids.length>1),o=te(()=>n.ids.indexOf(r.value)>0),a=te(()=>n.ids.indexOf(r.value)<n.ids.length-1),l=()=>{const u=Math.max(n.ids.indexOf(r.value)-1,0);r.value=n.ids[u]},c=()=>{const u=Math.min(n.ids.indexOf(r.value)+1,n.ids.length-1);r.value=n.ids[u]};return Re(()=>n.ids,()=>{n.ids&&n.ids.length!==0?r.value=n.ids[0]:r.value=void 0},{deep:!0}),(u,h)=>s.value?(I(),O("div",kx,[Q(D(rh),{size:"small",disabled:!o.value,onClick:l},{default:ye(()=>[h[0]||(h[0]=S("span",{class:"cb-icon-css cb-icon-css--prev cb-icon-css--sm"},[S("span"),je(" ")],-1)),je(" "+Z(u.$t("Map.Popup.Previous")),1)]),_:1},8,["disabled"]),Q(D(rh),{size:"small",disabled:!a.value,onClick:c},{default:ye(()=>[h[1]||(h[1]=S("span",{class:"cb-icon-css cb-icon-css--next cb-icon-css--sm"},[S("span"),je(" ")],-1)),je(" "+Z(u.$t("Map.Popup.Next")),1)]),_:1},8,["disabled"])])):ie("",!0)}},Ix=un(Px,[["__scopeId","data-v-4fcd7125"]]);$n(`
.vg--popout-pager[data-v-4fcd7125] {
        display: flex;
        justify-content: space-between;
        width: 250px;
        margin-bottom: 5px;
}
.vg--popout-pager .cb-btn[data-v-4fcd7125] {
        border-color: transparent;
        background: rgba(0,0,0,.6);
        color: #fff;
        box-shadow: none;
}
.vg--popout-pager .cb-btn.cb-disabled[data-v-4fcd7125] {opacity: .4;}
.vg--popout-pager .cb-btn[data-v-4fcd7125]:focus {box-shadow: 0 0 0 @input-focus-outline rgba(0,0,0,.2);}
`);const Mx={credentials:"include",headers:{"Content-Type":"application/json"}},Lx={url:"",baseURI:document.baseURI,defaults:{isLoading:!0}};function Fx(e){const t={...Lx,...e},n=Xe({pendingRequest:null,requests:new Map});return{get:i=>{const r=(a=>{const l=new URL(t.url,t.baseURI);return l.searchParams.set("id",a),l.href})(i);if(n.requests.has(r))return n.requests.get(r);n.pendingRequest&&n.pendingRequest.abort(),n.pendingRequest=new AbortController;const s=Xe({...t.defaults}),o={...Mx,signal:n.pendingRequest.signal,method:"GET"};return fetch(r,o).then(a=>a.json()).then(a=>{n.pendingRequest=null,s.isLoading=!1,Object.assign(s,a)}).catch(a=>{if(n.requests.delete(r),!(a instanceof Error&&a.name==="AbortError"))throw a}),n.requests.set(r,s),s}}}const Ox={isLoading:!0,id:"0",name:"",description:""},Dx={isLoading:!0,url:"",imageUrl:"",name:"",rating:0,badges:[]},Ux={__name:"cb-popup",props:{url:{type:String,required:!0},ids:{type:Array,default:()=>[]},type:{type:String,required:!0,validator:e=>["poi","product"].indexOf(e)!==-1}},setup(e,{expose:t}){const n=e,i={poi:nx,product:Rx},r={poi:Ox,product:Dx}[n.type],s=le(null),o=le(void 0),{get:a}=Fx({url:n.url,defaults:r}),l=le({...r});return Re(()=>o.value,()=>{o.value?l.value=a(o.value):l.value={...r}}),t({popup:s}),(c,u)=>(I(),O("div",{ref_key:"popup",ref:s},[Q(D(Ix),{modelValue:o.value,"onUpdate:modelValue":u[0]||(u[0]=h=>o.value=h),ids:e.ids},null,8,["modelValue","ids"]),(I(),ce(ai(i[e.type]),Po($l(l.value)),null,16))],512))}},Bx={__name:"cb-popup-overlay",props:{map:{type:Object,required:!0},coordinates:{type:Object,default:void 0},url:{type:String,required:!0},ids:{type:Array,default:()=>[]},type:{type:String,required:!0,validator:e=>["poi","product"].indexOf(e)!==-1}},setup(e){const t=e,n=le(null),i=new Gu({position:t.coordinates,positioning:"top-center",offset:{poi:[0,16],product:[0,4]}[t.type],stopEvent:!0,autoPan:{animation:{easing:_i,duration:200},margin:60}});return t.map.addOverlay(i),We(()=>{i.setElement(n.value.popup)}),Re(()=>t.coordinates,()=>{i.setPosition(t.coordinates)},{deep:!0}),(r,s)=>(I(),ce(D(Ux),{ref_key:"element",ref:n,url:e.url,ids:e.ids,type:e.type},null,8,["url","ids","type"]))}},zx={__name:"cb-popup-interaction",props:{map:{type:Object,required:!0},layer:{type:Object,required:!0},url:{type:String,required:!0},type:{type:String,required:!0,validator:e=>["poi","product"].indexOf(e)!==-1}},setup(e){const t=e,n=t.layer.getSource(),i=Xe({map:t.map,coordinates:void 0,url:t.url,ids:[],type:t.type}),r=s=>{const o=t.map.getFeaturesAtPixel(s.pixel)[0];if(!o||!n.hasFeature(o))return i.coordinates=void 0,void(i.ids=[]);const a=o.get("geometry").flatCoordinates,l=n.getFeaturesAtCoordinate(a);i.coordinates=a,i.ids=l.map(c=>c.getId())};return We(()=>{t.map.on("click",r)}),(s,o)=>(I(),ce(D(Bx),Po($l(i)),null,16))}},$0={__name:"cb-layer-interaction",props:{map:{type:Object,required:!0},layer:{type:Object,required:!0},url:{type:String,required:!0},colors:{type:Object,default:()=>({})},type:{type:String,required:!0,validator:e=>["poi","product"].indexOf(e)!==-1}},setup:e=>(t,n)=>(I(),O(be,null,[Q(Wb,{map:e.map,layer:e.layer,colors:e.colors,type:e.type},null,8,["map","layer","colors","type"]),Q(zx,{map:e.map,layer:e.layer,url:e.url,type:e.type},null,8,["map","layer","url","type"])],64))},jx={credentials:"include",headers:{"Content-Type":"application/json"}},Nx={url:"",baseURI:document.baseURI},Gx={pendingRequest:null,requests:new Map};function q0(e,t){const n={...Nx,...e},i=Xe(structuredClone(Gx)),r=le(void 0),s=async()=>{const a=(()=>{const u=new URL(n.url,n.baseURI);return t==null||t.sync(u),u.href})();if(i.requests.has(a))return await i.requests.get(a);i.pendingRequest&&i.pendingRequest.abort(),i.pendingRequest=new AbortController;const l={...jx,signal:i.pendingRequest.signal,method:"GET"},c=fetch(a,l).then(u=>u.json()).then(u=>(i.pendingRequest=null,u)).catch(u=>{if(i.requests.delete(a),!(u instanceof Error&&u.name==="AbortError"))throw u});return i.requests.set(a,c),await c},o=async()=>{var a;const l=await s();if(!l||l.length===0)return void(r.value=[]);const c=xg(l,"EPSG:4326","EPSG:3857");((a=r.value)==null?void 0:a.toString())!==c.toString()&&(r.value=c)};return t==null||t.on("watch",o),{state:Bt(i),extent:r,refresh:o}}function X0(e,t){const n=Date.now(),i=()=>{const r=Date.now()-n;e.updateStyleVariables({elapsed:r}),requestAnimationFrame(i)};t.on("addedFeatures",async r=>{const s=Date.now()-n;for(const o of r)o.setProperties({timestamp:s})}),requestAnimationFrame(i)}function Vx(e,t){return[[-1/0,-1/0,1/0,1/0]]}function $x(e){return function(t,n,i){const r=e.getZForResolution(function(l){return l}(n)),s=e.getTileRangeForExtentAndZ(vi(t),r),o=[],a=[r,0,0];for(a[1]=s.minX;a[1]<=s.maxX;++a[1])for(a[2]=s.minY;a[2]<=s.maxY;++a[2])o.push(wg(e.getTileCoordExtent(a)));return o}}const ur=[0,0,0];let W0=class{constructor(e){let t;if(this.minZoom=e.minZoom!==void 0?e.minZoom:0,this.resolutions_=e.resolutions,Ce(function(i,r){const s=r||as;return i.every(function(o,a){if(a===0)return!0;const l=s(i[a-1],o);return!(l>0||l===0)})}(this.resolutions_,(i,r)=>r-i),"`resolutions` must be sorted in descending order"),!e.origins)for(let i=0,r=this.resolutions_.length-1;i<r;++i)if(t){if(this.resolutions_[i]/this.resolutions_[i+1]!==t){t=void 0;break}}else t=this.resolutions_[i]/this.resolutions_[i+1];this.zoomFactor_=t,this.maxZoom=this.resolutions_.length-1,this.origin_=e.origin!==void 0?e.origin:null,this.origins_=null,e.origins!==void 0&&(this.origins_=e.origins,Ce(this.origins_.length==this.resolutions_.length,"Number of `origins` and `resolutions` must be equal"));const n=e.extent;n!==void 0&&!this.origin_&&!this.origins_&&(this.origin_=Xr(n)),Ce(!this.origin_&&this.origins_||this.origin_&&!this.origins_,"Either `origin` or `origins` must be configured, never both"),this.tileSizes_=null,e.tileSizes!==void 0&&(this.tileSizes_=e.tileSizes,Ce(this.tileSizes_.length==this.resolutions_.length,"Number of `tileSizes` and `resolutions` must be equal")),this.tileSize_=e.tileSize!==void 0?e.tileSize:this.tileSizes_?null:pc,Ce(!this.tileSize_&&this.tileSizes_||this.tileSize_&&!this.tileSizes_,"Either `tileSize` or `tileSizes` must be configured, never both"),this.extent_=n!==void 0?n:null,this.fullTileRanges_=null,this.tmpSize_=[0,0],this.tmpExtent_=[0,0,0,0],e.sizes!==void 0?this.fullTileRanges_=e.sizes.map((i,r)=>{const s=new su(Math.min(0,i[0]),Math.max(i[0]-1,-1),Math.min(0,i[1]),Math.max(i[1]-1,-1));if(n){const o=this.getTileRangeForExtentAndZ(n,r);s.minX=Math.max(o.minX,s.minX),s.maxX=Math.min(o.maxX,s.maxX),s.minY=Math.max(o.minY,s.minY),s.maxY=Math.min(o.maxY,s.maxY)}return s}):n&&this.calculateTileRanges_(n)}forEachTileCoord(e,t,n){const i=this.getTileRangeForExtentAndZ(e,t);for(let r=i.minX,s=i.maxX;r<=s;++r)for(let o=i.minY,a=i.maxY;o<=a;++o)n([t,r,o])}forEachTileCoordParentTileRange(e,t,n,i){let r,s,o,a=null,l=e[0]-1;for(this.zoomFactor_===2?(s=e[1],o=e[2]):a=this.getTileCoordExtent(e,i);l>=this.minZoom;){if(s!==void 0&&o!==void 0?(s=Math.floor(s/2),o=Math.floor(o/2),r=tr(s,s,o,o,n)):r=this.getTileRangeForExtentAndZ(a,l,n),t(l,r))return!0;--l}return!1}getExtent(){return this.extent_}getMaxZoom(){return this.maxZoom}getMinZoom(){return this.minZoom}getOrigin(e){return this.origin_?this.origin_:this.origins_[e]}getResolution(e){return this.resolutions_[e]}getResolutions(){return this.resolutions_}getTileCoordChildTileRange(e,t,n){if(e[0]<this.maxZoom){if(this.zoomFactor_===2){const r=2*e[1],s=2*e[2];return tr(r,r+1,s,s+1,t)}const i=this.getTileCoordExtent(e,n||this.tmpExtent_);return this.getTileRangeForExtentAndZ(i,e[0]+1,t)}return null}getTileRangeForTileCoordAndZ(e,t,n){if(t>this.maxZoom||t<this.minZoom)return null;const i=e[0],r=e[1],s=e[2];if(t===i)return tr(r,s,r,s,n);if(this.zoomFactor_){const a=Math.pow(this.zoomFactor_,t-i),l=Math.floor(r*a),c=Math.floor(s*a);return t<i?tr(l,l,c,c,n):tr(l,Math.floor(a*(r+1))-1,c,Math.floor(a*(s+1))-1,n)}const o=this.getTileCoordExtent(e,this.tmpExtent_);return this.getTileRangeForExtentAndZ(o,t,n)}getTileRangeForExtentAndZ(e,t,n){this.getTileCoordForXYAndZ_(e[0],e[3],t,!1,ur);const i=ur[1],r=ur[2];return this.getTileCoordForXYAndZ_(e[2],e[1],t,!0,ur),tr(i,ur[1],r,ur[2],n)}getTileCoordCenter(e){const t=this.getOrigin(e[0]),n=this.getResolution(e[0]),i=lt(this.getTileSize(e[0]),this.tmpSize_);return[t[0]+(e[1]+.5)*i[0]*n,t[1]-(e[2]+.5)*i[1]*n]}getTileCoordExtent(e,t){const n=this.getOrigin(e[0]),i=this.getResolution(e[0]),r=lt(this.getTileSize(e[0]),this.tmpSize_),s=n[0]+e[1]*r[0]*i,o=n[1]-(e[2]+1)*r[1]*i;return fi(s,o,s+r[0]*i,o+r[1]*i,t)}getTileCoordForCoordAndResolution(e,t,n){return this.getTileCoordForXYAndResolution_(e[0],e[1],t,!1,n)}getTileCoordForXYAndResolution_(e,t,n,i,r){const s=this.getZForResolution(n),o=n/this.getResolution(s),a=this.getOrigin(s),l=lt(this.getTileSize(s),this.tmpSize_);let c=o*(e-a[0])/n/l[0],u=o*(a[1]-t)/n/l[1];return i?(c=ms(c,5)-1,u=ms(u,5)-1):(c=fs(c,5),u=fs(u,5)),Ns(s,c,u,r)}getTileCoordForXYAndZ_(e,t,n,i,r){const s=this.getOrigin(n),o=this.getResolution(n),a=lt(this.getTileSize(n),this.tmpSize_);let l=(e-s[0])/o/a[0],c=(s[1]-t)/o/a[1];return i?(l=ms(l,5)-1,c=ms(c,5)-1):(l=fs(l,5),c=fs(c,5)),Ns(n,l,c,r)}getTileCoordForCoordAndZ(e,t,n){return this.getTileCoordForXYAndZ_(e[0],e[1],t,!1,n)}getTileCoordResolution(e){return this.resolutions_[e[0]]}getTileSize(e){return this.tileSize_?this.tileSize_:this.tileSizes_[e]}getFullTileRange(e){return this.fullTileRanges_?this.fullTileRanges_[e]:this.extent_?this.getTileRangeForExtentAndZ(this.extent_,e):null}getZForResolution(e,t){return Ze(nc(this.resolutions_,e,t||0),this.minZoom,this.maxZoom)}tileCoordIntersectsViewport(e,t){return Gg(t,0,t.length,2,this.getTileCoordExtent(e))}calculateTileRanges_(e){const t=this.resolutions_.length,n=new Array(t);for(let i=this.minZoom;i<t;++i)n[i]=this.getTileRangeForExtentAndZ(e,i);this.fullTileRanges_=n}};function Y0(e){let t=e.getDefaultTileGrid();return t||(t=function(n,i,r,s){const o=oh(n);return function(a,l,c,u){u=u!==void 0?u:"top-left";const h=H0(a,l,c);return new W0({extent:a,origin:H_(a,u),resolutions:h,tileSize:c})}(o,i,r,s)}(e),e.setDefaultTileGrid(t)),t}function Z0(e){const t=e||{},n=t.extent||He("EPSG:3857").getExtent(),i={extent:n,minZoom:t.minZoom,tileSize:t.tileSize,resolutions:H0(n,t.maxZoom,t.tileSize,t.maxResolution)};return new W0(i)}function H0(e,t,n,i){t=t!==void 0?t:42,n=lt(n!==void 0?n:pc);const r=Tt(e),s=ze(e);i=i>0?i:Math.max(s/n[0],r/n[1]);const o=t+1,a=new Array(o);for(let l=0;l<o;++l)a[l]=i/Math.pow(2,l);return a}function oh(e){let t=(e=He(e)).getExtent();if(!t){const n=180*gc.degrees/e.getMetersPerUnit();t=fi(-n,-n,n,n)}return t}const qx={url:"",baseURI:document.baseURI},Xx={isLoading:!1,pendingRequests:[],requests:new Map},Wx={credentials:"include",headers:{"Content-Type":"application/json"}};let K0=class Ym extends Kt{constructor(t){if(super(),this.on,this.once,this.un,this.id_=void 0,this.geometryName_="geometry",this.style_=null,this.styleFunction_=void 0,this.geometryChangeKey_=null,this.addChangeListener(this.geometryName_,this.handleGeometryChanged_),t)if(typeof t.getSimplifiedGeometry=="function"){const n=t;this.setGeometry(n)}else{const n=t;this.setProperties(n)}}clone(){const t=new Ym(this.hasProperties()?this.getProperties():null);t.setGeometryName(this.getGeometryName());const n=this.getGeometry();n&&t.setGeometry(n.clone());const i=this.getStyle();return i&&t.setStyle(i),t}getGeometry(){return this.get(this.geometryName_)}getId(){return this.id_}getGeometryName(){return this.geometryName_}getStyle(){return this.style_}getStyleFunction(){return this.styleFunction_}handleGeometryChange_(){this.changed()}handleGeometryChanged_(){this.geometryChangeKey_&&(Le(this.geometryChangeKey_),this.geometryChangeKey_=null);const t=this.getGeometry();t&&(this.geometryChangeKey_=we(t,Be,this.handleGeometryChange_,this)),this.changed()}setGeometry(t){this.set(this.geometryName_,t)}setStyle(t){this.style_=t,this.styleFunction_=t?function(n){if(typeof n=="function")return n;let i;return Array.isArray(n)?i=n:(Ce(typeof n.getZIndex=="function","Expected an `ol/style/Style` or an array of `ol/style/Style.js`"),i=[n]),function(){return i}}(t):void 0,this.changed()}setId(t){this.id_=t,this.changed()}setGeometryName(t){this.removeChangeListener(this.geometryName_,this.handleGeometryChanged_),this.geometryName_=t,this.addChangeListener(this.geometryName_,this.handleGeometryChanged_),this.handleGeometryChanged_()}};function Fa(e,t,n,i,r,s,o){let a,l;const c=(n-t)/i;if(c===1)a=t;else if(c===2)a=t,l=r;else if(c!==0){let u=e[t],h=e[t+1],p=0;const f=[0];for(let y=t+i;y<n;y+=i){const x=e[y],w=e[y+1];p+=Math.sqrt((x-u)*(x-u)+(w-h)*(w-h)),f.push(p),u=x,h=w}const m=r*p,_=function(y,x,w){let T,R;w=w||as;let b=0,k=y.length,F=!1;for(;b<k;)T=b+(k-b>>1),R=+w(y[T],x),R<0?b=T+1:(k=T,F=!R);return F?b:~b}(f,m);_<0?(l=(m-f[-_-2])/(f[-_-1]-f[-_-2]),a=t+(-_-2)*i):a=t+_*i}o=o>1?o:2,s=s||new Array(o);for(let u=0;u<o;++u)s[u]=a===void 0?NaN:l===void 0?e[a+u]:uc(e[a+u],e[a+i+u],l);return s}function sh(e,t,n,i,r,s){if(n==t)return null;let o;if(r<e[t+i-1])return s?(o=e.slice(t,t+i),o[i-1]=r,o):null;if(e[n-1]<r)return s?(o=e.slice(n-i,n),o[i-1]=r,o):null;if(r==e[t+i-1])return e.slice(t,t+i);let a=t/i,l=n/i;for(;a<l;){const h=a+l>>1;r<e[(h+1)*i-1]?l=h:a=h+1}const c=e[a*i-1];if(r==c)return e.slice((a-1)*i,(a-1)*i+i);const u=(r-c)/(e[(a+1)*i-1]-c);o=[];for(let h=0;h<i-1;++h)o.push(uc(e[(a-1)*i+h],e[a*i+h],u));return o.push(r),o}function Q0(e,t,n,i){const r=[];let s=[1/0,1/0,-1/0,-1/0];for(let o=0,a=n.length;o<a;++o){const l=n[o];s=Ec(e,t,l[0],i),r.push((s[0]+s[2])/2,(s[1]+s[3])/2),t=l[l.length-1]}return r}const J0=[1,0,0,1,0,0];let pn=class Oh{constructor(t,n,i,r,s,o){this.styleFunction,this.extent_,this.id_=o,this.type_=t,this.flatCoordinates_=n,this.flatInteriorPoints_=null,this.flatMidpoints_=null,this.ends_=i||null,this.properties_=s,this.squaredTolerance_,this.stride_=r,this.simplifiedGeometry_}get(t){return this.properties_[t]}getExtent(){return this.extent_||(this.extent_=this.type_==="Point"?ug(this.flatCoordinates_):Ec(this.flatCoordinates_,0,this.flatCoordinates_.length,2)),this.extent_}getFlatInteriorPoint(){if(!this.flatInteriorPoints_){const t=Xn(this.getExtent());this.flatInteriorPoints_=Xc(this.flatCoordinates_,0,this.ends_,2,t,0)}return this.flatInteriorPoints_}getFlatInteriorPoints(){if(!this.flatInteriorPoints_){const t=function(i,r){const s=[];let o,a=0,l=0;for(let c=0,u=r.length;c<u;++c){const h=r[c],p=Wc(i,a,h,2);if(o===void 0&&(o=p),p===o)s.push(r.slice(l,c+1));else{if(s.length===0)continue;s[s.length-1].push(r[l])}l=c+1,a=h}return s}(this.flatCoordinates_,this.ends_),n=Q0(this.flatCoordinates_,0,t,2);this.flatInteriorPoints_=jg(this.flatCoordinates_,0,t,2,n)}return this.flatInteriorPoints_}getFlatMidpoint(){return this.flatMidpoints_||(this.flatMidpoints_=Fa(this.flatCoordinates_,0,this.flatCoordinates_.length,2,.5)),this.flatMidpoints_}getFlatMidpoints(){if(!this.flatMidpoints_){this.flatMidpoints_=[];const t=this.flatCoordinates_;let n=0;const i=this.ends_;for(let r=0,s=i.length;r<s;++r){const o=i[r],a=Fa(t,n,o,2,.5);ln(this.flatMidpoints_,a),n=o}}return this.flatMidpoints_}getId(){return this.id_}getOrientedFlatCoordinates(){return this.flatCoordinates_}getGeometry(){return this}getSimplifiedGeometry(t){return this}simplifyTransformed(t,n){return this}getProperties(){return this.properties_}getPropertiesInternal(){return this.properties_}getStride(){return this.stride_}getStyleFunction(){return this.styleFunction}getType(){return this.type_}transform(t){const n=(t=He(t)).getExtent(),i=t.getWorldExtent();if(n&&i){const r=Tt(i)/Tt(n);Yr(J0,i[0],i[3],r,-r,0,0,0),Pg(this.flatCoordinates_,0,this.flatCoordinates_.length,2,J0,this.flatCoordinates_)}}applyTransform(t){t(this.flatCoordinates_,this.flatCoordinates_,this.stride_)}clone(){var t;return new Oh(this.type_,this.flatCoordinates_.slice(),(t=this.ends_)==null?void 0:t.slice(),this.stride_,Object.assign({},this.properties_),this.id_)}getEnds(){return this.ends_}enableSimplifyTransformed(){return this.simplifyTransformed=Hp((t,n)=>{if(t===this.squaredTolerance_)return this.simplifiedGeometry_;this.simplifiedGeometry_=this.clone(),n&&this.simplifiedGeometry_.applyTransform(n);const i=this.simplifiedGeometry_.getFlatCoordinates();let r;switch(this.type_){case"LineString":i.length=Rs(i,0,this.simplifiedGeometry_.flatCoordinates_.length,this.simplifiedGeometry_.stride_,t,i,0),r=[i.length];break;case"MultiLineString":r=[],i.length=Dg(i,0,this.simplifiedGeometry_.ends_,this.simplifiedGeometry_.stride_,t,i,0,r);break;case"Polygon":r=[],i.length=Vc(i,0,this.simplifiedGeometry_.ends_,this.simplifiedGeometry_.stride_,Math.sqrt(t),i,0,r)}return r&&(this.simplifiedGeometry_=new Oh(this.type_,i,r,2,this.properties_,this.id_)),this.squaredTolerance_=t,this.simplifiedGeometry_}),this}};pn.prototype.getFlatCoordinates=pn.prototype.getOrientedFlatCoordinates;let Yx=class Dh extends Mg{constructor(t){super(),this.geometries_=t,this.changeEventsKeys_=[],this.listenGeometriesChange_()}unlistenGeometriesChange_(){this.changeEventsKeys_.forEach(Le),this.changeEventsKeys_.length=0}listenGeometriesChange_(){const t=this.geometries_;for(let n=0,i=t.length;n<i;++n)this.changeEventsKeys_.push(we(t[n],Be,this.changed,this))}clone(){const t=new Dh(ah(this.geometries_));return t.applyProperties(this),t}closestPointXY(t,n,i,r){if(r<gi(this.getExtent(),t,n))return r;const s=this.geometries_;for(let o=0,a=s.length;o<a;++o)r=s[o].closestPointXY(t,n,i,r);return r}containsXY(t,n){const i=this.geometries_;for(let r=0,s=i.length;r<s;++r)if(i[r].containsXY(t,n))return!0;return!1}computeExtent(t){Zi(t);const n=this.geometries_;for(let i=0,r=n.length;i<r;++i)hg(t,n[i].getExtent());return t}getGeometries(){return ah(this.geometries_)}getGeometriesArray(){return this.geometries_}getGeometriesArrayRecursive(){let t=[];const n=this.geometries_;for(let i=0,r=n.length;i<r;++i)n[i].getType()===this.getType()?t=t.concat(n[i].getGeometriesArrayRecursive()):t.push(n[i]);return t}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 n=[],i=this.geometries_;let r=!1;for(let s=0,o=i.length;s<o;++s){const a=i[s],l=a.getSimplifiedGeometry(t);n.push(l),l!==a&&(r=!0)}return r?new Dh(n):(this.simplifiedGeometryMaxMinSquaredTolerance=t,this)}getType(){return"GeometryCollection"}intersectsExtent(t){const n=this.geometries_;for(let i=0,r=n.length;i<r;++i)if(n[i].intersectsExtent(t))return!0;return!1}isEmpty(){return this.geometries_.length===0}rotate(t,n){const i=this.geometries_;for(let r=0,s=i.length;r<s;++r)i[r].rotate(t,n);this.changed()}scale(t,n,i){i||(i=Xn(this.getExtent()));const r=this.geometries_;for(let s=0,o=r.length;s<o;++s)r[s].scale(t,n,i);this.changed()}setGeometries(t){this.setGeometriesArray(ah(t))}setGeometriesArray(t){this.unlistenGeometriesChange_(),this.geometries_=t,this.listenGeometriesChange_(),this.changed()}applyTransform(t){const n=this.geometries_;for(let i=0,r=n.length;i<r;++i)n[i].applyTransform(t);this.changed()}translate(t,n){const i=this.geometries_;for(let r=0,s=i.length;r<s;++r)i[r].translate(t,n);this.changed()}disposeInternal(){this.unlistenGeometriesChange_(),super.disposeInternal()}};function ah(e){return e.map(t=>t.clone())}let lh=class Uh extends yi{constructor(t,n){super(),this.flatMidpoint_=null,this.flatMidpointRevision_=-1,this.maxDelta_=-1,this.maxDeltaRevision_=-1,n===void 0||Array.isArray(t[0])?this.setCoordinates(t,n):this.setFlatCoordinates(n,t)}appendCoordinate(t){ln(this.flatCoordinates,t),this.changed()}clone(){const t=new Uh(this.flatCoordinates.slice(),this.layout);return t.applyProperties(this),t}closestPointXY(t,n,i,r){return r<gi(this.getExtent(),t,n)?r:(this.maxDeltaRevision_!=this.getRevision()&&(this.maxDelta_=Math.sqrt(zc(this.flatCoordinates,0,this.flatCoordinates.length,this.stride,0)),this.maxDeltaRevision_=this.getRevision()),Nc(this.flatCoordinates,0,this.flatCoordinates.length,this.stride,this.maxDelta_,!1,t,n,i,r))}forEachSegment(t){return Ng(this.flatCoordinates,0,this.flatCoordinates.length,this.stride,t)}getCoordinateAtM(t,n){return this.layout!="XYM"&&this.layout!="XYZM"?null:(n=n!==void 0&&n,sh(this.flatCoordinates,0,this.flatCoordinates.length,this.stride,t,n))}getCoordinates(){return ks(this.flatCoordinates,0,this.flatCoordinates.length,this.stride)}getCoordinateAt(t,n){return Fa(this.flatCoordinates,0,this.flatCoordinates.length,this.stride,t,n,this.stride)}getLength(){return function(t,n,i,r){let s=t[n],o=t[n+1],a=0;for(let l=n+r;l<i;l+=r){const c=t[l],u=t[l+1];a+=Math.sqrt((c-s)*(c-s)+(u-o)*(u-o)),s=c,o=u}return a}(this.flatCoordinates,0,this.flatCoordinates.length,this.stride)}getFlatMidpoint(){return this.flatMidpointRevision_!=this.getRevision()&&(this.flatMidpoint_=this.getCoordinateAt(.5,this.flatMidpoint_??void 0),this.flatMidpointRevision_=this.getRevision()),this.flatMidpoint_}getSimplifiedGeometryInternal(t){const n=[];return n.length=Rs(this.flatCoordinates,0,this.flatCoordinates.length,this.stride,t,n,0),new Uh(n,"XY")}getType(){return"LineString"}intersectsExtent(t){return Is(this.flatCoordinates,0,this.flatCoordinates.length,this.stride,t)}setCoordinates(t,n){this.setLayout(n,t,1),this.flatCoordinates||(this.flatCoordinates=[]),this.flatCoordinates.length=Ts(this.flatCoordinates,0,t,this.stride),this.changed()}},em=class Zm extends yi{constructor(t,n){super(),n&&!Array.isArray(t[0])?this.setFlatCoordinates(n,t):this.setCoordinates(t,n)}appendPoint(t){ln(this.flatCoordinates,t.getFlatCoordinates()),this.changed()}clone(){const t=new Zm(this.flatCoordinates.slice(),this.layout);return t.applyProperties(this),t}closestPointXY(t,n,i,r){if(r<gi(this.getExtent(),t,n))return r;const s=this.flatCoordinates,o=this.stride;for(let a=0,l=s.length;a<l;a+=o){const c=di(t,n,s[a],s[a+1]);if(c<r){r=c;for(let u=0;u<o;++u)i[u]=s[a+u];i.length=o}}return r}getCoordinates(){return ks(this.flatCoordinates,0,this.flatCoordinates.length,this.stride)}getPoint(t){const n=this.flatCoordinates.length/this.stride;return t<0||n<=t?null:new Ps(this.flatCoordinates.slice(t*this.stride,(t+1)*this.stride),this.layout)}getPoints(){const t=this.flatCoordinates,n=this.layout,i=this.stride,r=[];for(let s=0,o=t.length;s<o;s+=i){const a=new Ps(t.slice(s,s+i),n);r.push(a)}return r}getType(){return"MultiPoint"}intersectsExtent(t){const n=this.flatCoordinates,i=this.stride;for(let r=0,s=n.length;r<s;r+=i)if(wc(t,n[r],n[r+1]))return!0;return!1}setCoordinates(t,n){this.setLayout(n,t,1),this.flatCoordinates||(this.flatCoordinates=[]),this.flatCoordinates.length=Ts(this.flatCoordinates,0,t,this.stride),this.changed()}},Zx=class{constructor(){this.dataProjection=void 0,this.defaultFeatureProjection=void 0,this.featureClass=K0,this.supportedMediaTypes=null}getReadOptions(e,t){if(t){let n=t.dataProjection?He(t.dataProjection):this.readProjection(e);t.extent&&n&&n.getUnits()==="tile-pixels"&&(n=He(n),n.setWorldExtent(t.extent)),t={dataProjection:n,featureProjection:t.featureProjection}}return this.adaptOptions(t)}adaptOptions(e){return Object.assign({dataProjection:this.dataProjection,featureProjection:this.defaultFeatureProjection,featureClass:this.featureClass},e)}getType(){return ue()}readFeature(e,t){return ue()}readFeatures(e,t){return ue()}readGeometry(e,t){return ue()}readProjection(e){return ue()}writeFeature(e,t){return ue()}writeFeatures(e,t){return ue()}writeGeometry(e,t){return ue()}};function ch(e,t,n){const i=n?He(n.featureProjection):null,r=n?He(n.dataProjection):null;let s=e;if(i&&r&&!Hi(i,r)){t&&(s=e.clone());const o=t?i:r,a=t?r:i;o.getUnits()==="tile-pixels"?s.transform(o,a):s.applyTransform(Ki(o,a))}if(t&&n&&n.decimals!==void 0){const o=Math.pow(10,n.decimals),a=function(l){for(let c=0,u=l.length;c<u;++c)l[c]=Math.round(l[c]*o)/o;return l};s===e&&(s=e.clone()),s.applyTransform(a)}return s}const Hx={Point:Ps,LineString:lh,Polygon:Hr,MultiPoint:em,MultiLineString:class Bh extends yi{constructor(t,n,i){if(super(),this.ends_=[],this.maxDelta_=-1,this.maxDeltaRevision_=-1,Array.isArray(t[0]))this.setCoordinates(t,n);else if(n!==void 0&&i)this.setFlatCoordinates(n,t),this.ends_=i;else{const r=t,s=[],o=[];for(let l=0,c=r.length;l<c;++l)ln(s,r[l].getFlatCoordinates()),o.push(s.length);const a=r.length===0?this.getLayout():r[0].getLayout();this.setFlatCoordinates(a,s),this.ends_=o}}appendLineString(t){ln(this.flatCoordinates,t.getFlatCoordinates().slice()),this.ends_.push(this.flatCoordinates.length),this.changed()}clone(){const t=new Bh(this.flatCoordinates.slice(),this.layout,this.ends_.slice());return t.applyProperties(this),t}closestPointXY(t,n,i,r){return r<gi(this.getExtent(),t,n)?r:(this.maxDeltaRevision_!=this.getRevision()&&(this.maxDelta_=Math.sqrt(jc(this.flatCoordinates,0,this.ends_,this.stride,0)),this.maxDeltaRevision_=this.getRevision()),Gc(this.flatCoordinates,0,this.ends_,this.stride,this.maxDelta_,!1,t,n,i,r))}getCoordinateAtM(t,n,i){return this.layout!="XYM"&&this.layout!="XYZM"||this.flatCoordinates.length===0?null:(n=n!==void 0&&n,i=i!==void 0&&i,function(r,s,o,a,l,c,u){if(u)return sh(r,s,o[o.length-1],a,l,c);let h;if(l<r[a-1])return c?(h=r.slice(0,a),h[a-1]=l,h):null;if(r[r.length-1]<l)return c?(h=r.slice(r.length-a),h[a-1]=l,h):null;for(let p=0,f=o.length;p<f;++p){const m=o[p];if(s!=m){if(l<r[s+a-1])return null;if(l<=r[m-1])return sh(r,s,m,a,l,!1);s=m}}return null}(this.flatCoordinates,0,this.ends_,this.stride,t,n,i))}getCoordinates(){return $c(this.flatCoordinates,0,this.ends_,this.stride)}getEnds(){return this.ends_}getLineString(t){return t<0||this.ends_.length<=t?null:new lh(this.flatCoordinates.slice(t===0?0:this.ends_[t-1],this.ends_[t]),this.layout)}getLineStrings(){const t=this.flatCoordinates,n=this.ends_,i=this.layout,r=[];let s=0;for(let o=0,a=n.length;o<a;++o){const l=n[o],c=new lh(t.slice(s,l),i);r.push(c),s=l}return r}getFlatMidpoints(){const t=[],n=this.flatCoordinates;let i=0;const r=this.ends_,s=this.stride;for(let o=0,a=r.length;o<a;++o){const l=r[o];ln(t,Fa(n,i,l,s,.5)),i=l}return t}getSimplifiedGeometryInternal(t){const n=[],i=[];return n.length=Dg(this.flatCoordinates,0,this.ends_,this.stride,t,n,0,i),new Bh(n,"XY",i)}getType(){return"MultiLineString"}intersectsExtent(t){return function(n,i,r,s,o){for(let a=0,l=r.length;a<l;++a){if(Is(n,i,r[a],s,o))return!0;i=r[a]}return!1}(this.flatCoordinates,0,this.ends_,this.stride,t)}setCoordinates(t,n){this.setLayout(n,t,2),this.flatCoordinates||(this.flatCoordinates=[]);const i=Zr(this.flatCoordinates,0,t,this.stride,this.ends_);this.flatCoordinates.length=i.length===0?0:i[i.length-1],this.changed()}},MultiPolygon:class zh extends yi{constructor(t,n,i){if(super(),this.endss_=[],this.flatInteriorPointsRevision_=-1,this.flatInteriorPoints_=null,this.maxDelta_=-1,this.maxDeltaRevision_=-1,this.orientedRevision_=-1,this.orientedFlatCoordinates_=null,!i&&!Array.isArray(t[0])){const r=t,s=[],o=[];for(let a=0,l=r.length;a<l;++a){const c=r[a],u=s.length,h=c.getEnds();for(let p=0,f=h.length;p<f;++p)h[p]+=u;ln(s,c.getFlatCoordinates()),o.push(h)}n=r.length===0?this.getLayout():r[0].getLayout(),t=s,i=o}n!==void 0&&i?(this.setFlatCoordinates(n,t),this.endss_=i):this.setCoordinates(t,n)}appendPolygon(t){let n;if(this.flatCoordinates){const i=this.flatCoordinates.length;ln(this.flatCoordinates,t.getFlatCoordinates()),n=t.getEnds().slice();for(let r=0,s=n.length;r<s;++r)n[r]+=i}else this.flatCoordinates=t.getFlatCoordinates().slice(),n=t.getEnds().slice(),this.endss_.push();this.endss_.push(n),this.changed()}clone(){const t=this.endss_.length,n=new Array(t);for(let r=0;r<t;++r)n[r]=this.endss_[r].slice();const i=new zh(this.flatCoordinates.slice(),this.layout,n);return i.applyProperties(this),i}closestPointXY(t,n,i,r){return r<gi(this.getExtent(),t,n)?r:(this.maxDeltaRevision_!=this.getRevision()&&(this.maxDelta_=Math.sqrt(function(s,o,a,l,c){for(let u=0,h=a.length;u<h;++u){const p=a[u];c=jc(s,o,p,l,c),o=p[p.length-1]}return c}(this.flatCoordinates,0,this.endss_,this.stride,0)),this.maxDeltaRevision_=this.getRevision()),function(s,o,a,l,c,u,h,p,f,m,_){_=_||[NaN,NaN];for(let y=0,x=a.length;y<x;++y){const w=a[y];m=Gc(s,o,w,l,c,u,h,p,f,m,_),o=w[w.length-1]}return m}(this.getOrientedFlatCoordinates(),0,this.endss_,this.stride,this.maxDelta_,!0,t,n,i,r))}containsXY(t,n){return function(i,r,s,o,a,l){if(s.length===0)return!1;for(let c=0,u=s.length;c<u;++c){const h=s[c];if(qc(i,r,h,o,a,l))return!0;r=h[h.length-1]}return!1}(this.getOrientedFlatCoordinates(),0,this.endss_,this.stride,t,n)}getArea(){return function(t,n,i,r){let s=0;for(let o=0,a=i.length;o<a;++o){const l=i[o];s+=Bg(t,n,l,r),n=l[l.length-1]}return s}(this.getOrientedFlatCoordinates(),0,this.endss_,this.stride)}getCoordinates(t){let n;return t!==void 0?(n=this.getOrientedFlatCoordinates().slice(),Zc(n,0,this.endss_,this.stride,t)):n=this.flatCoordinates,function(i,r,s,o,a){a=a!==void 0?a:[];let l=0;for(let c=0,u=s.length;c<u;++c){const h=s[c];a[l++]=h.length===1&&h[0]===r?[]:$c(i,r,h,o,a[l]),r=h[h.length-1]}return a.length=l,a}(n,0,this.endss_,this.stride)}getEndss(){return this.endss_}getFlatInteriorPoints(){if(this.flatInteriorPointsRevision_!=this.getRevision()){const t=Q0(this.flatCoordinates,0,this.endss_,this.stride);this.flatInteriorPoints_=jg(this.getOrientedFlatCoordinates(),0,this.endss_,this.stride,t),this.flatInteriorPointsRevision_=this.getRevision()}return this.flatInteriorPoints_}getInteriorPoints(){return new em(this.getFlatInteriorPoints().slice(),"XYM")}getOrientedFlatCoordinates(){if(this.orientedRevision_!=this.getRevision()){const t=this.flatCoordinates;$g(t,0,this.endss_,this.stride)?this.orientedFlatCoordinates_=t:(this.orientedFlatCoordinates_=t.slice(),this.orientedFlatCoordinates_.length=Zc(this.orientedFlatCoordinates_,0,this.endss_,this.stride)),this.orientedRevision_=this.getRevision()}return this.orientedFlatCoordinates_}getSimplifiedGeometryInternal(t){const n=[],i=[];return n.length=function(r,s,o,a,l,c,u,h){for(let p=0,f=o.length;p<f;++p){const m=o[p],_=[];u=Vc(r,s,m,a,l,c,u,_),h.push(_),s=m[m.length-1]}return u}(this.flatCoordinates,0,this.endss_,this.stride,Math.sqrt(t),n,0,i),new zh(n,"XY",i)}getPolygon(t){if(t<0||this.endss_.length<=t)return null;let n;if(t===0)n=0;else{const s=this.endss_[t-1];n=s[s.length-1]}const i=this.endss_[t].slice(),r=i[i.length-1];if(n!==0)for(let s=0,o=i.length;s<o;++s)i[s]-=n;return new Hr(this.flatCoordinates.slice(n,r),this.layout,i)}getPolygons(){const t=this.layout,n=this.flatCoordinates,i=this.endss_,r=[];let s=0;for(let o=0,a=i.length;o<a;++o){const l=i[o].slice(),c=l[l.length-1];if(s!==0)for(let h=0,p=l.length;h<p;++h)l[h]-=s;const u=new Hr(n.slice(s,c),t,l);r.push(u),s=c}return r}getType(){return"MultiPolygon"}intersectsExtent(t){return function(n,i,r,s,o){for(let a=0,l=r.length;a<l;++a){const c=r[a];if(Vg(n,i,c,s,o))return!0;i=c[c.length-1]}return!1}(this.getOrientedFlatCoordinates(),0,this.endss_,this.stride,t)}setCoordinates(t,n){this.setLayout(n,t,3),this.flatCoordinates||(this.flatCoordinates=[]);const i=Og(this.flatCoordinates,0,t,this.stride,this.endss_);if(i.length===0)this.flatCoordinates.length=0;else{const r=i[i.length-1];this.flatCoordinates.length=r.length===0?0:r[r.length-1]}this.changed()}}};function tm(e,t){var n;const i=e.geometry;if(!i)return[];if(Array.isArray(i))return i.map(o=>tm({...e,geometry:o})).flat();const r=i.type==="MultiPolygon"?"Polygon":i.type;if(r==="GeometryCollection"||r==="Circle")throw new Error("Unsupported geometry type: "+r);const s=i.layout.length;return ch(new pn(r,r==="Polygon"?function(o,a,l){return Array.isArray(a[0])?($g(o,0,a,l)||Zc(o=o.slice(),0,a,l),o):(Yc(o,0,a,l)||Ms(o=o.slice(),0,a,l),o)}(i.flatCoordinates,i.ends,s):i.flatCoordinates,(n=i.ends)==null?void 0:n.flat(),s,e.properties||{},e.id).enableSimplifyTransformed(),!1,t)}function uh(e,t){if(!e)return null;if(Array.isArray(e)){const n=e.map(i=>uh(i,t));return new Yx(n)}return ch(new Hx[e.type](e.flatCoordinates,e.layout,e.ends),!1,t)}let Kx=class extends Zx{constructor(){super()}getType(){return"json"}readFeature(e,t){return this.readFeatureFromObject(Oa(e),this.getReadOptions(e,t))}readFeatures(e,t){return this.readFeaturesFromObject(Oa(e),this.getReadOptions(e,t))}readFeatureFromObject(e,t){return ue()}readFeaturesFromObject(e,t){return ue()}readGeometry(e,t){return this.readGeometryFromObject(Oa(e),this.getReadOptions(e,t))}readGeometryFromObject(e,t){return ue()}readProjection(e){return this.readProjectionFromObject(Oa(e))}readProjectionFromObject(e){return ue()}writeFeature(e,t){return JSON.stringify(this.writeFeatureObject(e,t))}writeFeatureObject(e,t){return ue()}writeFeatures(e,t){return JSON.stringify(this.writeFeaturesObject(e,t))}writeFeaturesObject(e,t){return ue()}writeGeometry(e,t){return JSON.stringify(this.writeGeometryObject(e,t))}writeGeometryObject(e,t){return ue()}};function Oa(e){return typeof e=="string"?JSON.parse(e)||null:e!==null?e:null}let Qx=class extends Kx{constructor(e){e=e||{},super(),this.dataProjection=He(e.dataProjection?e.dataProjection:"EPSG:4326"),e.featureProjection&&(this.defaultFeatureProjection=He(e.featureProjection)),e.featureClass&&(this.featureClass=e.featureClass),this.geometryName_=e.geometryName,this.extractGeometryName_=e.extractGeometryName,this.supportedMediaTypes=["application/geo+json","application/vnd.geo+json"]}readFeatureFromObject(e,t){let n=null;n=e.type==="Feature"?e:{type:"Feature",geometry:e,properties:null};const i=hh(n.geometry);if(this.featureClass===pn)return tm({geometry:i,id:n.id,properties:n.properties},t);const r=new K0;return this.geometryName_?r.setGeometryName(this.geometryName_):this.extractGeometryName_&&n.geometry_name&&r.setGeometryName(n.geometry_name),r.setGeometry(uh(i,t)),"id"in n&&r.setId(n.id),n.properties&&r.setProperties(n.properties,!0),r}readFeaturesFromObject(e,t){let n=null;if(e.type==="FeatureCollection"){n=[];const i=e.features;for(let r=0,s=i.length;r<s;++r){const o=this.readFeatureFromObject(i[r],t);o&&n.push(o)}}else n=[this.readFeatureFromObject(e,t)];return n.flat()}readGeometryFromObject(e,t){return function(n,i){const r=hh(n);return uh(r,i)}(e,t)}readProjectionFromObject(e){const t=e.crs;let n;if(t)if(t.type=="name")n=He(t.properties.name);else{if(t.type!=="EPSG")throw new Error("Unknown SRS type");n=He("EPSG:"+t.properties.code)}else n=this.dataProjection;return n}writeFeatureObject(e,t){t=this.adaptOptions(t);const n={type:"Feature",geometry:null,properties:null},i=e.getId();if(i!==void 0&&(n.id=i),!e.hasProperties())return n;const r=e.getProperties(),s=e.getGeometry();return s&&(n.geometry=dh(s,t),delete r[e.getGeometryName()]),Vi(r)||(n.properties=r),n}writeFeaturesObject(e,t){t=this.adaptOptions(t);const n=[];for(let i=0,r=e.length;i<r;++i)n.push(this.writeFeatureObject(e[i],t));return{type:"FeatureCollection",features:n}}writeGeometryObject(e,t){return dh(e,this.adaptOptions(t))}};function hh(e,t){if(!e)return null;let n;switch(e.type){case"Point":n=function(i){const r=i.coordinates;return{type:"Point",flatCoordinates:r,layout:bi(r.length)}}(e);break;case"LineString":n=function(i){var r;const s=i.coordinates,o=s.flat();return{type:"LineString",flatCoordinates:o,ends:[o.length],layout:bi(((r=s[0])==null?void 0:r.length)||2)}}(e);break;case"Polygon":n=function(i){var r,s;const o=i.coordinates,a=[],l=(s=(r=o[0])==null?void 0:r[0])==null?void 0:s.length,c=Zr(a,0,o,l);return{type:"Polygon",flatCoordinates:a,ends:c,layout:bi(l)}}(e);break;case"MultiPoint":n=function(i){var r;const s=i.coordinates;return{type:"MultiPoint",flatCoordinates:s.flat(),layout:bi(((r=s[0])==null?void 0:r.length)||2)}}(e);break;case"MultiLineString":n=function(i){var r,s;const o=i.coordinates,a=((s=(r=o[0])==null?void 0:r[0])==null?void 0:s.length)||2,l=[],c=Zr(l,0,o,a);return{type:"MultiLineString",flatCoordinates:l,ends:c,layout:bi(a)}}(e);break;case"MultiPolygon":n=function(i){var r,s;const o=i.coordinates,a=[],l=((s=(r=o[0])==null?void 0:r[0])==null?void 0:s[0].length)||2,c=Og(a,0,o,l);return{type:"MultiPolygon",flatCoordinates:a,ends:c,layout:bi(l)}}(e);break;case"GeometryCollection":n=function(i){return i.geometries.map(function(r){return hh(r)})}(e);break;default:throw new Error("Unsupported GeoJSON type: "+e.type)}return n}function dh(e,t){const n=(e=ch(e,!0,t)).getType();let i;switch(n){case"Point":i=function(r){return{type:"Point",coordinates:r.getCoordinates()}}(e);break;case"LineString":i=function(r){return{type:"LineString",coordinates:r.getCoordinates()}}(e);break;case"Polygon":i=function(r,s){let o;return s&&(o=s.rightHanded),{type:"Polygon",coordinates:r.getCoordinates(o)}}(e,t);break;case"MultiPoint":i=function(r){return{type:"MultiPoint",coordinates:r.getCoordinates()}}(e);break;case"MultiLineString":i=function(r){return{type:"MultiLineString",coordinates:r.getCoordinates()}}(e);break;case"MultiPolygon":i=function(r,s){let o;return s&&(o=s.rightHanded),{type:"MultiPolygon",coordinates:r.getCoordinates(o)}}(e,t);break;case"GeometryCollection":i=function(r,s){return s=Object.assign({},s),delete s.featureProjection,{type:"GeometryCollection",geometries:r.getGeometriesArray().map(function(o){return dh(o,s)})}}(e,t);break;case"Circle":i={type:"GeometryCollection",geometries:[]};break;default:throw new Error("Unsupported geometry type: "+n)}return i}const Ai="add",Si="remove",nm="length";let Da=class extends Cn{constructor(e,t,n){super(e),this.element=t,this.index=n}},gn=class extends Kt{constructor(e,t){if(super(),this.on,this.once,this.un,t=t||{},this.unique_=!!t.unique,this.array_=e||[],this.unique_)for(let n=0,i=this.array_.length;n<i;++n)this.assertUnique_(this.array_[n],n);this.updateLength_()}clear(){for(;this.getLength()>0;)this.pop()}extend(e){for(let t=0,n=e.length;t<n;++t)this.push(e[t]);return this}forEach(e){const t=this.array_;for(let n=0,i=t.length;n<i;++n)e(t[n],n,t)}getArray(){return this.array_}item(e){return this.array_[e]}getLength(){return this.get(nm)}insertAt(e,t){if(e<0||e>this.getLength())throw new Error("Index out of bounds: "+e);this.unique_&&this.assertUnique_(t),this.array_.splice(e,0,t),this.updateLength_(),this.dispatchEvent(new Da(Ai,t,e))}pop(){return this.removeAt(this.getLength()-1)}push(e){this.unique_&&this.assertUnique_(e);const t=this.getLength();return this.insertAt(t,e),this.getLength()}remove(e){const t=this.array_;for(let n=0,i=t.length;n<i;++n)if(t[n]===e)return this.removeAt(n)}removeAt(e){if(e<0||e>=this.getLength())return;const t=this.array_[e];return this.array_.splice(e,1),this.updateLength_(),this.dispatchEvent(new Da(Si,t,e)),t}setAt(e,t){if(e>=this.getLength())return void this.insertAt(e,t);if(e<0)throw new Error("Index out of bounds: "+e);this.unique_&&this.assertUnique_(t,e);const n=this.array_[e];this.array_[e]=t,this.dispatchEvent(new Da(Si,n,e)),this.dispatchEvent(new Da(Ai,t,e))}updateLength_(){this.set(nm,this.array_.length)}assertUnique_(e,t){for(let n=0,i=this.array_.length;n<i;++n)if(this.array_[n]===e&&n!==t)throw new Error("Duplicate item added to a unique collection")}},im=class{constructor(e){this.rbush_=new t0(e),this.items_={}}insert(e,t){const n={minX:e[0],minY:e[1],maxX:e[2],maxY:e[3],value:t};this.rbush_.insert(n),this.items_[Ae(t)]=n}load(e,t){const n=new Array(t.length);for(let i=0,r=t.length;i<r;i++){const s=e[i],o=t[i],a={minX:s[0],minY:s[1],maxX:s[2],maxY:s[3],value:o};n[i]=a,this.items_[Ae(o)]=a}this.rbush_.load(n)}remove(e){const t=Ae(e),n=this.items_[t];return delete this.items_[t],this.rbush_.remove(n)!==null}update(e,t){const n=this.items_[Ae(t)];$r([n.minX,n.minY,n.maxX,n.maxY],e)||(this.remove(t),this.insert(e,t))}getAll(){return this.rbush_.all().map(function(e){return e.value})}getInExtent(e){const t={minX:e[0],minY:e[1],maxX:e[2],maxY:e[3]};return this.rbush_.search(t).map(function(n){return n.value})}forEach(e){return this.forEach_(this.getAll(),e)}forEachInExtent(e,t){return this.forEach_(this.getInExtent(e),t)}forEach_(e,t){let n;for(let i=0,r=e.length;i<r;i++)if(n=t(e[i]),n)return n;return n}isEmpty(){return Vi(this.items_)}clear(){this.rbush_.clear(),this.items_={}}getExtent(e){const t=this.rbush_.toJSON();return fi(t.minX,t.minY,t.maxX,t.maxY,e)}concat(e){this.rbush_.load(e.rbush_.all());for(const t in e.items_)this.items_[t]=e.items_[t]}},rm=class extends Kt{constructor(e){super(),this.projection=He(e.projection),this.attributions_=om(e.attributions),this.attributionsCollapsible_=e.attributionsCollapsible??!0,this.loading=!1,this.state_=e.state!==void 0?e.state:"ready",this.wrapX_=e.wrapX!==void 0&&e.wrapX,this.interpolate_=!!e.interpolate,this.viewResolver=null,this.viewRejector=null;const t=this;this.viewPromise_=new Promise(function(n,i){t.viewResolver=n,t.viewRejector=i})}getAttributions(){return this.attributions_}getAttributionsCollapsible(){return this.attributionsCollapsible_}getProjection(){return this.projection}getResolutions(e){return null}getView(){return this.viewPromise_}getState(){return this.state_}getWrapX(){return this.wrapX_}getInterpolate(){return this.interpolate_}refresh(){this.changed()}setAttributions(e){this.attributions_=om(e),this.changed()}setState(e){this.state_=e,this.changed()}};function om(e){return e?typeof e=="function"?e:(Array.isArray(e)||(e=[e]),t=>e):null}function sm(e,t){return function(n,i,r,s,o){const a=this;(function(l,c,u,h,p,f,m){const _=new XMLHttpRequest;_.open("GET",typeof l=="function"?l(u,h,p):l,!0),c.getType()=="arraybuffer"&&(_.responseType="arraybuffer"),_.withCredentials=!1,_.onload=function(y){if(!_.status||_.status>=200&&_.status<300){const x=c.getType();try{let w;x=="text"||x=="json"?w=_.responseText:x=="xml"?w=_.responseXML||_.responseText:x=="arraybuffer"&&(w=_.response),w?f(c.readFeatures(w,{extent:u,featureProjection:p}),c.readProjection(w)):m()}catch{m()}}else m()},_.onerror=m,_.send()})(e,t,n,i,r,function(l,c){a.addFeatures(l),s!==void 0&&s(l)},o||Gi)}}let Kn=class extends Cn{constructor(e,t,n){super(e),this.feature=t,this.features=n}},Jx=class extends rm{constructor(e){super({attributions:(e=e||{}).attributions,interpolate:!0,projection:void 0,state:"ready",wrapX:e.wrapX===void 0||e.wrapX}),this.on,this.once,this.un,this.loader_=Gi,this.format_=e.format||null,this.overlaps_=e.overlaps===void 0||e.overlaps,this.url_=e.url,e.loader!==void 0?this.loader_=e.loader:this.url_!==void 0&&(Ce(this.format_,"`format` must be set when `url` is set"),this.loader_=sm(this.url_,this.format_)),this.strategy_=e.strategy!==void 0?e.strategy:Vx;const t=e.useSpatialIndex===void 0||e.useSpatialIndex;let n,i;this.featuresRtree_=t?new im:null,this.loadedExtentsRtree_=new im,this.loadingExtentsCount_=0,this.nullGeometryFeatures_={},this.idIndex_={},this.uidIndex_={},this.featureChangeKeys_={},this.featuresCollection_=null,Array.isArray(e.features)?i=e.features:e.features&&(n=e.features,i=n.getArray()),!t&&n===void 0&&(n=new gn(i)),i!==void 0&&this.addFeaturesInternal(i),n!==void 0&&this.bindFeaturesCollection_(n)}addFeature(e){this.addFeatureInternal(e),this.changed()}addFeatureInternal(e){const t=Ae(e);if(!this.addToIndex_(t,e))return void(this.featuresCollection_&&this.featuresCollection_.remove(e));this.setupChangeEvents_(t,e);const n=e.getGeometry();if(n){const i=n.getExtent();this.featuresRtree_&&this.featuresRtree_.insert(i,e)}else this.nullGeometryFeatures_[t]=e;this.dispatchEvent(new Kn(go,e))}setupChangeEvents_(e,t){t instanceof pn||(this.featureChangeKeys_[e]=[we(t,Be,this.handleFeatureChange_,this),we(t,Ni,this.handleFeatureChange_,this)])}addToIndex_(e,t){let n=!0;if(t.getId()!==void 0){const i=String(t.getId());if(i in this.idIndex_)if(t instanceof pn){const r=this.idIndex_[i];r instanceof pn?Array.isArray(r)?r.push(t):this.idIndex_[i]=[r,t]:n=!1}else n=!1;else this.idIndex_[i]=t}return n&&(Ce(!(e in this.uidIndex_),"The passed `feature` was already added to the source"),this.uidIndex_[e]=t),n}addFeatures(e){this.addFeaturesInternal(e),this.changed()}addFeaturesInternal(e){const t=[],n=[],i=[];for(let r=0,s=e.length;r<s;r++){const o=e[r],a=Ae(o);this.addToIndex_(a,o)&&n.push(o)}for(let r=0,s=n.length;r<s;r++){const o=n[r],a=Ae(o);this.setupChangeEvents_(a,o);const l=o.getGeometry();if(l){const c=l.getExtent();t.push(c),i.push(o)}else this.nullGeometryFeatures_[a]=o}if(this.featuresRtree_&&this.featuresRtree_.load(t,i),this.hasListener(go))for(let r=0,s=n.length;r<s;r++)this.dispatchEvent(new Kn(go,n[r]))}bindFeaturesCollection_(e){let t=!1;this.addEventListener(go,function(n){t||(t=!0,e.push(n.feature),t=!1)}),this.addEventListener(Ma,function(n){t||(t=!0,e.remove(n.feature),t=!1)}),e.addEventListener(Ai,n=>{t||(t=!0,this.addFeature(n.element),t=!1)}),e.addEventListener(Si,n=>{t||(t=!0,this.removeFeature(n.element),t=!1)}),this.featuresCollection_=e}clear(e){if(e){for(const n in this.featureChangeKeys_)this.featureChangeKeys_[n].forEach(Le);this.featuresCollection_||(this.featureChangeKeys_={},this.idIndex_={},this.uidIndex_={})}else if(this.featuresRtree_){const n=i=>{this.removeFeatureInternal(i)};this.featuresRtree_.forEach(n);for(const i in this.nullGeometryFeatures_)this.removeFeatureInternal(this.nullGeometryFeatures_[i])}this.featuresCollection_&&this.featuresCollection_.clear(),this.featuresRtree_&&this.featuresRtree_.clear(),this.nullGeometryFeatures_={};const t=new Kn(S0);this.dispatchEvent(t),this.changed()}forEachFeature(e){if(this.featuresRtree_)return this.featuresRtree_.forEach(e);this.featuresCollection_&&this.featuresCollection_.forEach(e)}forEachFeatureAtCoordinateDirect(e,t){const n=[e[0],e[1],e[0],e[1]];return this.forEachFeatureInExtent(n,function(i){const r=i.getGeometry();if(r instanceof pn||r.intersectsCoordinate(e))return t(i)})}forEachFeatureInExtent(e,t){if(this.featuresRtree_)return this.featuresRtree_.forEachInExtent(e,t);this.featuresCollection_&&this.featuresCollection_.forEach(t)}forEachFeatureIntersectingExtent(e,t){return this.forEachFeatureInExtent(e,function(n){const i=n.getGeometry();if(i instanceof pn||i.intersectsExtent(e)){const r=t(n);if(r)return r}})}getFeaturesCollection(){return this.featuresCollection_}getFeatures(){let e;return this.featuresCollection_?e=this.featuresCollection_.getArray().slice(0):this.featuresRtree_&&(e=this.featuresRtree_.getAll(),Vi(this.nullGeometryFeatures_)||ln(e,Object.values(this.nullGeometryFeatures_))),e}getFeaturesAtCoordinate(e){const t=[];return this.forEachFeatureAtCoordinateDirect(e,function(n){t.push(n)}),t}getFeaturesInExtent(e,t){if(this.featuresRtree_){if(!(t&&t.canWrapX()&&this.getWrapX()))return this.featuresRtree_.getInExtent(e);const n=Rc(e,t);return[].concat(...n.map(i=>this.featuresRtree_.getInExtent(i)))}return this.featuresCollection_?this.featuresCollection_.getArray().slice(0):[]}getClosestFeatureToCoordinate(e,t){const n=e[0],i=e[1];let r=null;const s=[NaN,NaN];let o=1/0;const a=[-1/0,-1/0,1/0,1/0];return t=t||Ur,this.featuresRtree_.forEachInExtent(a,function(l){if(t(l)){const c=l.getGeometry(),u=o;if(o=c instanceof pn?0:c.closestPointXY(n,i,s,o),o<u){r=l;const h=Math.sqrt(o);a[0]=n-h,a[1]=i-h,a[2]=n+h,a[3]=i+h}}}),r}getExtent(e){return this.featuresRtree_.getExtent(e)}getFeatureById(e){const t=this.idIndex_[e.toString()];return t!==void 0?t:null}getFeatureByUid(e){const t=this.uidIndex_[e];return t!==void 0?t:null}getFormat(){return this.format_}getOverlaps(){return this.overlaps_}getUrl(){return this.url_}handleFeatureChange_(e){const t=e.target,n=Ae(t),i=t.getGeometry();if(i){const s=i.getExtent();n in this.nullGeometryFeatures_?(delete this.nullGeometryFeatures_[n],this.featuresRtree_&&this.featuresRtree_.insert(s,t)):this.featuresRtree_&&this.featuresRtree_.update(s,t)}else n in this.nullGeometryFeatures_||(this.featuresRtree_&&this.featuresRtree_.remove(t),this.nullGeometryFeatures_[n]=t);const r=t.getId();if(r!==void 0){const s=r.toString();this.idIndex_[s]!==t&&(this.removeFromIdIndex_(t),this.idIndex_[s]=t)}else this.removeFromIdIndex_(t),this.uidIndex_[n]=t;this.changed(),this.dispatchEvent(new Kn(A0,t))}hasFeature(e){const t=e.getId();return t!==void 0?t in this.idIndex_:Ae(e)in this.uidIndex_}isEmpty(){return this.featuresRtree_?this.featuresRtree_.isEmpty()&&Vi(this.nullGeometryFeatures_):!this.featuresCollection_||this.featuresCollection_.getLength()===0}loadFeatures(e,t,n){const i=this.loadedExtentsRtree_,r=this.strategy_(e,t,n);for(let s=0,o=r.length;s<o;++s){const a=r[s];i.forEachInExtent(a,function(l){return xs(l.extent,a)})||(++this.loadingExtentsCount_,this.dispatchEvent(new Kn(Tb)),this.loader_.call(this,a,t,n,l=>{--this.loadingExtentsCount_,this.dispatchEvent(new Kn(Rb,void 0,l))},()=>{--this.loadingExtentsCount_,this.dispatchEvent(new Kn(kb))}),i.insert(a,{extent:a.slice()}))}this.loading=!(this.loader_.length<4)&&this.loadingExtentsCount_>0}refresh(){this.clear(!0),this.loadedExtentsRtree_.clear(),super.refresh()}removeLoadedExtent(e){const t=this.loadedExtentsRtree_;let n;t.forEachInExtent(e,function(i){if($r(i.extent,e))return n=i,!0}),n&&t.remove(n)}removeFeatures(e){let t=!1;for(let n=0,i=e.length;n<i;++n)t=this.removeFeatureInternal(e[n])||t;t&&this.changed()}removeFeature(e){e&&this.removeFeatureInternal(e)&&this.changed()}removeFeatureInternal(e){const t=Ae(e);if(!(t in this.uidIndex_))return!1;t in this.nullGeometryFeatures_?delete this.nullGeometryFeatures_[t]:this.featuresRtree_&&this.featuresRtree_.remove(e);const n=this.featureChangeKeys_[t];n==null||n.forEach(Le),delete this.featureChangeKeys_[t];const i=e.getId();if(i!==void 0){const r=i.toString(),s=this.idIndex_[r];s===e?delete this.idIndex_[r]:Array.isArray(s)&&(s.splice(s.indexOf(e),1),s.length===1&&(this.idIndex_[r]=s[0]))}return delete this.uidIndex_[t],this.hasListener(Ma)&&this.dispatchEvent(new Kn(Ma,e)),!0}removeFromIdIndex_(e){for(const t in this.idIndex_)if(this.idIndex_[t]===e){delete this.idIndex_[t];break}}setLoader(e){this.loader_=e}setUrl(e){Ce(this.format_,"`format` must be set when `url` is set"),this.url_=e,this.setLoader(sm(e,this.format_))}};function am(e,t,n,i){const r=new Qx,s="EPSG:3857",o={...qx,...e},a=Xe(structuredClone(Xx)),l=new Jx({format:r,loader:async(f,m,_,y,x)=>{try{if(!c(f))return;const w=h(f),T=await p(w),R=r.readFeatures(T,{featureProjection:s});await t.emit("addedFeatures",R),l.addFeatures(R),y==null||y(R)}catch{l.removeLoadedExtent(f),x==null||x()}},strategy:$x(Z0({tileSize:512}))}),c=f=>!(!u(f)||xs(f,n.value)&&!l.isEmpty()),u=f=>n.value?!mi(Vt(n.value,f)):!1,h=f=>{const[m,_,y,x]=xg(f,s,"EPSG:4326"),w=new URL(o.url,o.baseURI);return w.searchParams.set("minLon",m.toString()),w.searchParams.set("minLat",_.toString()),w.searchParams.set("maxLon",y.toString()),w.searchParams.set("maxLat",x.toString()),i==null||i.sync(w),w.href},p=async f=>{if(a.requests.has(f))return await a.requests.get(f);a.isLoading=!0;const m=new AbortController;a.pendingRequests.push(m);const _={...Wx,signal:m.signal,method:"GET"},y=fetch(f,_).then(x=>x.json()).catch(x=>{throw a.requests.delete(f),x}).finally(()=>{a.pendingRequests.splice(a.pendingRequests.indexOf(m),1),a.isLoading=a.pendingRequests.length>0});return a.requests.set(f,y),await y};return Re(()=>n.value,()=>{for(const f of a.pendingRequests)f.abort();l.refresh()},{deep:!0,immediate:!0}),{state:Bt(a),source:l}}const e1={__name:"cb-poi-layer",props:{map:{type:Object,required:!0},extentUrl:{type:String,required:!0},markersUrl:{type:String,required:!0},detailsUrl:{type:String,required:!0},colors:{type:Object,default:()=>({})}},emits:["loading"],async setup(e,{emit:t}){let n,i;const r=e,s=t,o=Ou(),{extent:a,refresh:l}=q0({url:r.extentUrl}),{state:c,source:u}=am({url:r.markersUrl},o,a),h=([n,i]=Vd(()=>zb(r.colors)),n=await n,i(),n),p=new R0({source:u,style:h,zIndex:90});return X0(p,o),r.map.addLayer(p),We(async()=>await l()),Re(()=>c.isLoading,()=>s("loading",c.isLoading)),(f,m)=>(I(),ce(D($0),{map:e.map,layer:D(p),url:e.detailsUrl,colors:e.colors,type:"poi"},null,8,["map","layer","url","colors"]))}},t1={__name:"cb-product-layer",props:{map:{type:Object,required:!0},extentUrl:{type:String,required:!0},markersUrl:{type:String,required:!0},detailsUrl:{type:String,required:!0},colors:{type:Object,default:()=>({})}},emits:["loading"],async setup(e,{expose:t,emit:n}){let i,r;const s=e,o=[100,100,100,100],a=n,l=s.map.getView(),c=Ye("cb-query-parameters"),u=Ou(),{state:h,extent:p,refresh:f}=q0({url:s.extentUrl},c),{state:m,source:_}=am({url:s.markersUrl},u,p,c),y=T=>{p.value&&p.value.length!==0?l.fit(p.value,{padding:o,maxZoom:14,...T}):(()=>{if(l.getCenter())return;const R=l.getMinZoom();l.setCenter([0,0]),l.setZoom(R)})()};We(async()=>await f()),Re(()=>m.isLoading,()=>a("loading",m.isLoading)),Re(()=>p.value,()=>{const T=h.requests.length===1?void 0:250;y({duration:T})},{deep:!0}),t({fit:y});const x=([i,r]=Vd(()=>(async T=>{const R=document.createElement("canvas");R.width=224,R.height=G0;const b=R.getContext("2d");b.imageSmoothingEnabled=!1;const k=["match",["get","asset"]];for(let Y=0;Y<eh.length;Y++){const[ee,ne]=eh[Y],G=T[ee]??N0,V=Y%4*56,q=fo*~~(Y/4);Gb(b,G,V,q),await V0(b,"data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAADgAAABECAYAAADUZvakAAAACXBIWXMAABYlAAAWJQFJUiTwAAAFu2lUWHRYTUw6Y29tLmFkb2JlLnhtcAAAAAAAPD94cGFja2V0IGJlZ2luPSLvu78iIGlkPSJXNU0wTXBDZWhpSHpyZVN6TlRjemtjOWQiPz4gPHg6eG1wbWV0YSB4bWxuczp4PSJhZG9iZTpuczptZXRhLyIgeDp4bXB0az0iQWRvYmUgWE1QIENvcmUgNy4yLWMwMDAgNzkuMWI2NWE3OSwgMjAyMi8wNi8xMy0xNzo0NjoxNCAgICAgICAgIj4gPHJkZjpSREYgeG1sbnM6cmRmPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5LzAyLzIyLXJkZi1zeW50YXgtbnMjIj4gPHJkZjpEZXNjcmlwdGlvbiByZGY6YWJvdXQ9IiIgeG1sbnM6eG1wPSJodHRwOi8vbnMuYWRvYmUuY29tL3hhcC8xLjAvIiB4bWxuczpkYz0iaHR0cDovL3B1cmwub3JnL2RjL2VsZW1lbnRzLzEuMS8iIHhtbG5zOnBob3Rvc2hvcD0iaHR0cDovL25zLmFkb2JlLmNvbS9waG90b3Nob3AvMS4wLyIgeG1sbnM6eG1wTU09Imh0dHA6Ly9ucy5hZG9iZS5jb20veGFwLzEuMC9tbS8iIHhtbG5zOnN0RXZ0PSJodHRwOi8vbnMuYWRvYmUuY29tL3hhcC8xLjAvc1R5cGUvUmVzb3VyY2VFdmVudCMiIHhtcDpDcmVhdG9yVG9vbD0iQWRvYmUgUGhvdG9zaG9wIDIzLjUgKFdpbmRvd3MpIiB4bXA6Q3JlYXRlRGF0ZT0iMjAyMy0wOS0xOFQxMzowOTowNyswMjowMCIgeG1wOk1vZGlmeURhdGU9IjIwMjMtMDktMjVUMDg6MjQ6MTgrMDI6MDAiIHhtcDpNZXRhZGF0YURhdGU9IjIwMjMtMDktMjVUMDg6MjQ6MTgrMDI6MDAiIGRjOmZvcm1hdD0iaW1hZ2UvcG5nIiBwaG90b3Nob3A6Q29sb3JNb2RlPSIzIiB4bXBNTTpJbnN0YW5jZUlEPSJ4bXAuaWlkOjRiMzM3Y2Y0LTRiMTgtY2I0ZC04MTQyLTZkOGZmOWE3ODQyZCIgeG1wTU06RG9jdW1lbnRJRD0ieG1wLmRpZDphZWQ3MGU4My0wOTE5LTVlNGQtOTBjZi1iYTI0YTc1NzE0YzEiIHhtcE1NOk9yaWdpbmFsRG9jdW1lbnRJRD0ieG1wLmRpZDphZWQ3MGU4My0wOTE5LTVlNGQtOTBjZi1iYTI0YTc1NzE0YzEiPiA8eG1wTU06SGlzdG9yeT4gPHJkZjpTZXE+IDxyZGY6bGkgc3RFdnQ6YWN0aW9uPSJjcmVhdGVkIiBzdEV2dDppbnN0YW5jZUlEPSJ4bXAuaWlkOmFlZDcwZTgzLTA5MTktNWU0ZC05MGNmLWJhMjRhNzU3MTRjMSIgc3RFdnQ6d2hlbj0iMjAyMy0wOS0xOFQxMzowOTowNyswMjowMCIgc3RFdnQ6c29mdHdhcmVBZ2VudD0iQWRvYmUgUGhvdG9zaG9wIDIzLjUgKFdpbmRvd3MpIi8+IDxyZGY6bGkgc3RFdnQ6YWN0aW9uPSJzYXZlZCIgc3RFdnQ6aW5zdGFuY2VJRD0ieG1wLmlpZDo0YjMzN2NmNC00YjE4LWNiNGQtODE0Mi02ZDhmZjlhNzg0MmQiIHN0RXZ0OndoZW49IjIwMjMtMDktMjVUMDg6MjQ6MTgrMDI6MDAiIHN0RXZ0OnNvZnR3YXJlQWdlbnQ9IkFkb2JlIFBob3Rvc2hvcCAyMy41IChXaW5kb3dzKSIgc3RFdnQ6Y2hhbmdlZD0iLyIvPiA8L3JkZjpTZXE+IDwveG1wTU06SGlzdG9yeT4gPC9yZGY6RGVzY3JpcHRpb24+IDwvcmRmOlJERj4gPC94OnhtcG1ldGE+IDw/eHBhY2tldCBlbmQ9InIiPz6mkGVOAAAHhElEQVRogd2bX2hb1x3HP+fKSCmLQERaiDUG2lgELTEV9sMIFKYw6Isd0pCHvUZ9iCc85oxBoRnDNi0NFEZdaKqYwW73OAgkxUpggVEVRmBgBxeFFvywKQ+1syAbkWuoJTs6e7j3akdXV7J0fa/s7fvkc+49R78P53fPv9/PAp+l63psd3c3I4R4HchompaRUsaAlOPVihCiIqWsSSlLUsqv8vl8yW97hB+d6LoeazQaWSHErJQyA8Q8dlUDSsC96enpP/th26EALbDrwCwKVDweZ3R0lEQiQTweJxwOE41G29oahoFhGGxvb/PixQs2NzfZ2tpSX6lYI7uQz+crXm30BOgGlkwmSaVSnD17lkgk4skYwzDY3NykXC47YReazeZnXkAHBlxaWnoL+Ajrm0omk0xMTDA6OjpoVz21tbVFuVxmfX3drqoA84O6bt+Auq7H9vb25qWUsxAcmFOGYVAsFjEMw65aDIfDC7lcrtZP+74AC4VCKhQK3ZVSZiKRCOPj44yNjfVq8hwoAg+Bb4F14DvAtjIKJICTwGvAm8AUcLpbh+VymdXVVRqNBkCl2Wxe6MdlDwQsFAopTdO+AFLRaJSpqamOCUPRXWAO052Mbi/10BtADnjb7aFjNPuC7AmowsXjcaamprpNIH8C3sUcOT90GngH+K3zQb1ep1gs2pPQgZBdAVW4dDpNNpt1e+0b4BdAeSDz+9ePMV39VeeDUqlkT0A9ITW3Sl3XY+rIdYG7AfyU4OAA/mn9xg3ng2w2SzweB0iFQqG7uq7H3DpwBdzb25tH+eZclAdu4u07G1SG9Vt55wN7PpBSZhqNxpxb4w7AQqFwVUo5G4lEun1zeeC2D4YPqts4IG0bw+EwwHVrjW5TG6D13c0BjI+Pu82WRwVnqwMyGo0yMTFhFz9yumoboKZpV7Fc02Wdu8HRwtm6jeObHBsbszccqUajMas+awEWCoUU5hrm9t19A3ziv62e9QmmTS0po3hdHcUWYCgUmgNIp9NurjnJcCaUfmVgLk8tJZNJexRj6ii2AKWUWcDNNT8E/hWQoYdRGXOD0ZLbKGpgzpxAyj6/OfSHIK08pN5VC+oo1uv1n4EFqGnaJYBz5845O/gj/m2/gtBz4HO1IpVKAaBp2nX4r4tmAbejz2eBmeaffq8W0uk0AFLKjK7rMa1QKGSBWCKRcE4uz4FHw7LyEKqgeFkkErE/s9ju7m5Gs26/OHPmjLPh586KYyoDc0Peku2JQojXNSFEFnBbGv4WvG2+6aFaSCQS9p8ZTQgRc1Ta+jpws/zTt2rh1KlTAAghMpqUMgVw8uRJZ6OdYVjmk9bVgnJAiGlYt2MuLloN2iof9Z1aUFhSrudBS8dpa3aQutraC/D/Qr0Au16dHUN1tVXDXCjVi1VbrwRnj+/6vlpQWCqaEKIG2Beqqn4SuFn+6XtqwQaUUla0ZrO5BjiDHQA/HIZlPuk1taCw1DRgDaBa7VgVfh60VT7qTbWguGhJk1J+BfDs2TNno0v870w0bXcsm5ubAGiatqadOHFiDahVq1Xq9br63mk6w87HUW+gBG0Mw7BdtHbt2rUvtVwuVxNCrAFqLM7We8Oy8hDKqYWNjQ0ApJQlsNZBIcQiwNOnT52NL9EjpHUMdBpHJOrJkycACCHugQU4MjLyJVDb2Nho+a+im0FbeQi9oxaq1Wor6mRHgjUAK1q6CLC6uurs5G2gZ7TziPQjHOE1e/Rs9wRlqxYOhz+m+yj+heM1o0aB+2qFYRitOURKuWDXtwAPGMVXgV8FYalH/RpHzPDhw9ahfl6NFbZttq1RrGxsbFAud4T9PsAlhHUEygPvqxVK2kml2Wy2ZWG0AVqj+BswR9FlA/4pRwuZt2xoyTAM1ePmnZHejuPS9PT0PWCx0WiwvLzsXPzh6CA74Or1OsvLy/ZBYdEth8b1PBgOhxeEEGs7OzsUi0W3Vz7FvDYfxsQTBX6HAw5geXmZnZ0dgEo4HF5wPocugLlcrvby5cvLQGVra4tSqeT22gfAPzCn66A0Zv3G+84HpVKJ7e1tsJIQuiUG+ZVG8iFmkMbPNJKbuOTL2G6pwnlKI7E1ACSY4Swd+PvBDB2KYm7u38PcInZoUDgYIJVLhbxy5cpBTdRUrq8x71irtKdyvQKkgR/QRyoXwJ07dwaCgwGS8fpMDApM/Sb+ODVQOuVRQXqFAw/5osOGPAwceLj4zefzlf39/ctAbX19vdsS4osUuNr+/v5lLxm/nm62Z2Zm1vb39y8QIOSjR49UuAszMzNrXvrxfHXvhHQ5gXjWysqKfbY7FBz48G8Ft27dyoyMjHwBxCYmJtRUDk9aWVnh8ePH4AMc+PR/E35B+g0HEDpsBwAPHjx4Njk5+W8hxFv2bUAymRyoDwUO4Jf5fP6vftjmCyDA/fv31yYnJ596gXTAXfXrv17AR0DwBhkkHPgMCINBBg0HAQBCf5DDgIOAAMGEvHjxIkDWCemAm5+env44KDt8WSZ6aWlpaQ6YBzh//jz1et0J53rV4JcCB4R2SEWBw8GQAKEDcihwQ9fS0tKcBTo0/QfrwI18ibf85QAAAABJRU5ErkJggg==",56,fo,V,q),await V0(b,ne,56,56,V,q),k.push(ee),k.push([V,q])}k.push([0,0]);const F=R.toDataURL("image/png"),j=th(0,1,150),B=th(0,.5,150),N=["array",0,th(0,17,150)];return{variables:{elapsed:0},"icon-src":F,"icon-scale":B,"icon-color":"#fff","icon-width":224,"icon-height":G0,"icon-size":[56,fo],"icon-offset":k,"icon-opacity":j,"icon-displacement":N}})(s.colors)),i=await i,r(),i),w=new R0({source:_,style:x,zIndex:100});return X0(w,u),s.map.addLayer(w),(T,R)=>(I(),ce(D($0),{map:e.map,layer:D(w),url:e.detailsUrl,colors:e.colors,type:"product"},null,8,["map","layer","url","colors"]))}},lm="active";let mo=class extends Kt{constructor(e){super(),this.on,this.once,this.un,e&&e.handleEvent&&(this.handleEvent=e.handleEvent),this.map_=null,this.setActive(!0)}getActive(){return this.get(lm)}getMap(){return this.map_}handleEvent(e){return!0}setActive(e){this.set(lm,e)}setMap(e){this.map_=e}};function ph(e,t,n,i){const r=e.getZoom();if(r===void 0)return;const s=e.getConstrainedZoom(r+t),o=e.getResolutionForZoom(s);e.getAnimating()&&e.cancelAnimations(),e.animate({resolution:o,anchor:n,duration:i!==void 0?i:250,easing:_i})}let cm=class extends mo{constructor(e){super(e=e||{}),this.totalDelta_=0,this.lastDelta_=0,this.maxDelta_=e.maxDelta!==void 0?e.maxDelta:1,this.duration_=e.duration!==void 0?e.duration:250,this.timeout_=e.timeout!==void 0?e.timeout:80,this.useAnchor_=e.useAnchor===void 0||e.useAnchor,this.constrainResolution_=e.constrainResolution!==void 0&&e.constrainResolution;const t=e.condition?e.condition:Lb;this.condition_=e.onFocusOnly?Qu(k0,t):t,this.lastAnchor_=null,this.startTime_=void 0,this.timeoutId_,this.mode_=void 0,this.trackpadEventGap_=400,this.trackpadTimeoutId_,this.deltaPerZoom_=300}endInteraction_(){this.trackpadTimeoutId_=void 0;const e=this.getMap();e&&e.getView().endInteraction(void 0,this.lastDelta_?this.lastDelta_>0?1:-1:0,this.lastAnchor_)}handleEvent(e){if(!this.condition_(e)||e.type!==Nr)return!0;const t=e.map,n=e.originalEvent;let i;if(n.preventDefault(),this.useAnchor_&&(this.lastAnchor_=e.coordinate),e.type==Nr&&(i=n.deltaY,ly&&n.deltaMode===WheelEvent.DOM_DELTA_PIXEL&&(i/=Zg),n.deltaMode===WheelEvent.DOM_DELTA_LINE&&(i*=40)),i===0)return!1;this.lastDelta_=i;const r=Date.now();this.startTime_===void 0&&(this.startTime_=r),(!this.mode_||r-this.startTime_>this.trackpadEventGap_)&&(this.mode_=Math.abs(i)<4?"trackpad":"wheel");const s=t.getView();if(this.mode_==="trackpad"&&!s.getConstrainResolution()&&!this.constrainResolution_)return this.trackpadTimeoutId_?clearTimeout(this.trackpadTimeoutId_):(s.getAnimating()&&s.cancelAnimations(),s.beginInteraction()),this.trackpadTimeoutId_=setTimeout(this.endInteraction_.bind(this),this.timeout_),s.adjustZoom(-i/this.deltaPerZoom_,this.lastAnchor_),this.startTime_=r,!1;this.totalDelta_+=i;const o=Math.max(this.timeout_-(r-this.startTime_),0);return clearTimeout(this.timeoutId_),this.timeoutId_=setTimeout(this.handleWheelZoom_.bind(this,t),o),!1}handleWheelZoom_(e){const t=e.getView();t.getAnimating()&&t.cancelAnimations();let n=-Ze(this.totalDelta_,-this.maxDelta_*this.deltaPerZoom_,this.maxDelta_*this.deltaPerZoom_)/this.deltaPerZoom_;(t.getConstrainResolution()||this.constrainResolution_)&&(n=n?n>0?1:-1:0),ph(t,n,this.lastAnchor_,this.duration_),this.mode_=void 0,this.totalDelta_=0,this.lastAnchor_=null,this.startTime_=void 0,this.timeoutId_=void 0}setMouseAnchor(e){this.useAnchor_=e,e||(this.lastAnchor_=null)}},n1=class extends ss{constructor(e){super(),this.map_=e}dispatchRenderEvent(e,t){ue()}calculateMatrices2D(e){const t=e.viewState,n=e.coordinateToPixelTransform,i=e.pixelToCoordinateTransform;Yr(n,e.size[0]/2,e.size[1]/2,1/t.resolution,-1/t.resolution,-t.rotation,-t.center[0],-t.center[1]),kg(i,n)}forEachFeatureAtCoordinate(e,t,n,i,r,s,o,a){let l;const c=t.viewState;function u(T,R,b,k){return r.call(s,R,T?b:null,k)}const h=c.projection,p=Q_(e.slice(),h),f=[[0,0]];if(h.canWrapX()&&i){const T=ze(h.getExtent());f.push([-T,0],[T,0])}const m=t.layerStatesArray,_=m.length,y=[],x=[];for(let T=0;T<f.length;T++)for(let R=_-1;R>=0;--R){const b=m[R],k=b.layer;if(k.hasRenderer()&&Kc(b,c)&&o.call(a,k)){const F=k.getRenderer(),j=k.getSource();if(F&&j){const B=j.getWrapX()?p:e,N=u.bind(null,b.managed);x[0]=B[0]+f[T][0],x[1]=B[1]+f[T][1],l=F.forEachFeatureAtCoordinate(x,t,n,N,y)}if(l)return l}}if(y.length===0)return;const w=1/y.length;return y.forEach((T,R)=>T.distanceSq+=R*w),y.sort((T,R)=>T.distanceSq-R.distanceSq),y.some(T=>l=T.callback(T.feature,T.layer,T.geometry)),l}hasFeatureAtCoordinate(e,t,n,i,r,s){return this.forEachFeatureAtCoordinate(e,t,n,i,Ur,this,r,s)!==void 0}getMap(){return this.map_}renderFrame(e){ue()}scheduleExpireIconCache(e){hn.canExpireCache()&&e.postRenderFunctions.push(i1)}};function i1(e,t){hn.expire()}let r1=class extends n1{constructor(e){super(e),this.fontChangeListenerKey_=we(xb,Ni,e.redrawText.bind(e)),this.element_=document.createElement("div");const t=this.element_.style;t.position="absolute",t.width="100%",t.height="100%",t.zIndex="0",this.element_.className=Ea+" ol-layers";const n=e.getViewport();n.insertBefore(this.element_,n.firstChild||null),this.children_=[],this.renderedVisible_=!0}dispatchRenderEvent(e,t){const n=this.getMap();if(n.hasListener(e)){const i=new zs(e,void 0,t);n.dispatchEvent(i)}}disposeInternal(){Le(this.fontChangeListenerKey_),this.element_.remove(),super.disposeInternal()}renderFrame(e){if(!e)return void(this.renderedVisible_&&(this.element_.style.display="none",this.renderedVisible_=!1));this.calculateMatrices2D(e),this.dispatchRenderEvent(vs,e);const t=e.layerStatesArray.sort((s,o)=>s.zIndex-o.zIndex);t.some(s=>s.layer instanceof C0&&s.layer.getDeclutter())&&(e.declutter={});const n=e.viewState;this.children_.length=0;const i=[];let r=null;for(let s=0,o=t.length;s<o;++s){const a=t[s];e.layerIndex=s;const l=a.layer,c=l.getSourceState();if(!Kc(a,n)||c!="ready"&&c!="undefined"){l.unrender();continue}const u=l.render(e,r);u&&(u!==r&&(this.children_.push(u),r=u),i.push(a))}this.declutter(e,i),function(s,o){const a=s.childNodes;for(let l=0;;++l){const c=a[l],u=o[l];if(!c&&!u)break;if(c!==u){if(!c){s.appendChild(u);continue}if(!u){s.removeChild(c),--l;continue}s.insertBefore(u,c)}}}(this.element_,this.children_),this.dispatchRenderEvent(hc,e),this.renderedVisible_||(this.element_.style.display="",this.renderedVisible_=!0),this.scheduleExpireIconCache(e)}declutter(e,t){if(e.declutter){for(let n=t.length-1;n>=0;--n){const i=t[n],r=i.layer;r.getDeclutter()&&r.renderDeclutter(e,i)}t.forEach(n=>n.layer.renderDeferred(e))}}},Qn=class extends Cn{constructor(e,t){super(e),this.layer=t}};const gh="layers";let Ua=class Hm extends ig{constructor(t){t=t||{};const n=Object.assign({},t);delete n.layers;let i=t.layers;super(n),this.on,this.once,this.un,this.layersListenerKeys_=[],this.listenerKeys_={},this.addChangeListener(gh,this.handleLayersChanged_),i?Array.isArray(i)?i=new gn(i.slice(),{unique:!0}):Ce(typeof i.getArray=="function","Expected `layers` to be an array or a `Collection`"):i=new gn(void 0,{unique:!0}),this.setLayers(i)}handleLayerChange_(){this.changed()}handleLayersChanged_(){this.layersListenerKeys_.forEach(Le),this.layersListenerKeys_.length=0;const t=this.getLayers();this.layersListenerKeys_.push(we(t,Ai,this.handleLayersAdd_,this),we(t,Si,this.handleLayersRemove_,this));for(const i in this.listenerKeys_)this.listenerKeys_[i].forEach(Le);Br(this.listenerKeys_);const n=t.getArray();for(let i=0,r=n.length;i<r;i++){const s=n[i];this.registerLayerListeners_(s),this.dispatchEvent(new Qn("addlayer",s))}this.changed()}registerLayerListeners_(t){const n=[we(t,Ni,this.handleLayerChange_,this),we(t,Be,this.handleLayerChange_,this)];t instanceof Hm&&n.push(we(t,"addlayer",this.handleLayerGroupAdd_,this),we(t,"removelayer",this.handleLayerGroupRemove_,this)),this.listenerKeys_[Ae(t)]=n}handleLayerGroupAdd_(t){this.dispatchEvent(new Qn("addlayer",t.layer))}handleLayerGroupRemove_(t){this.dispatchEvent(new Qn("removelayer",t.layer))}handleLayersAdd_(t){const n=t.element;this.registerLayerListeners_(n),this.dispatchEvent(new Qn("addlayer",n)),this.changed()}handleLayersRemove_(t){const n=t.element,i=Ae(n);this.listenerKeys_[i].forEach(Le),delete this.listenerKeys_[i],this.dispatchEvent(new Qn("removelayer",n)),this.changed()}getLayers(){return this.get(gh)}setLayers(t){const n=this.getLayers();if(n){const i=n.getArray();for(let r=0,s=i.length;r<s;++r)this.dispatchEvent(new Qn("removelayer",i[r]))}this.set(gh,t)}getLayersArray(t){return t=t!==void 0?t:[],this.getLayers().forEach(function(n){n.getLayersArray(t)}),t}getLayerStatesArray(t){const n=t!==void 0?t:[],i=n.length;this.getLayers().forEach(function(o){o.getLayerStatesArray(n)});const r=this.getLayerState();let s=r.zIndex;!t&&r.zIndex===void 0&&(s=0);for(let o=i,a=n.length;o<a;o++){const l=n[o];l.opacity*=r.opacity,l.visible=l.visible&&r.visible,l.maxResolution=Math.min(l.maxResolution,r.maxResolution),l.minResolution=Math.max(l.minResolution,r.minResolution),l.minZoom=Math.max(l.minZoom,r.minZoom),l.maxZoom=Math.min(l.maxZoom,r.maxZoom),r.extent!==void 0&&(l.extent!==void 0?l.extent=Vt(l.extent,r.extent):l.extent=r.extent),l.zIndex===void 0&&(l.zIndex=s)}return n}getSourceState(){return"ready"}},hr=class extends Cn{constructor(e,t,n){super(e),this.map=t,this.frameState=n!==void 0?n:null}},Jn=class extends hr{constructor(e,t,n,i,r,s){super(e,t,r),this.originalEvent=n,this.pixel_=null,this.coordinate_=null,this.dragging=i!==void 0&&i,this.activePointers=s}get pixel(){return this.pixel_||(this.pixel_=this.map.getEventPixel(this.originalEvent)),this.pixel_}set pixel(e){this.pixel_=e}get coordinate(){return this.coordinate_||(this.coordinate_=this.map.getCoordinateFromPixel(this.pixel)),this.coordinate_}set coordinate(e){this.coordinate_=e}preventDefault(){super.preventDefault(),"preventDefault"in this.originalEvent&&this.originalEvent.preventDefault()}stopPropagation(){super.stopPropagation(),"stopPropagation"in this.originalEvent&&this.originalEvent.stopPropagation()}};const $e={SINGLECLICK:"singleclick",CLICK:jr,DBLCLICK:B_,POINTERDRAG:"pointerdrag",POINTERMOVE:"pointermove",POINTERDOWN:"pointerdown",POINTERUP:"pointerup",POINTEROVER:"pointerover",POINTEROUT:"pointerout",POINTERENTER:"pointerenter",POINTERLEAVE:"pointerleave",POINTERCANCEL:"pointercancel"},o1="pointermove",um="pointerdown";let s1=class extends zr{constructor(e,t){super(e),this.map_=e,this.clickTimeoutId_,this.emulateClicks_=!1,this.dragging_=!1,this.dragListenerKeys_=[],this.moveTolerance_=t===void 0?1:t,this.down_=null;const n=this.map_.getViewport();this.activePointers_=[],this.trackedTouches_={},this.element_=n,this.pointerdownListenerKey_=we(n,um,this.handlePointerDown_,this),this.originalPointerMoveEvent_,this.relayedListenerKey_=we(n,o1,this.relayMoveEvent_,this),this.boundHandleTouchMove_=this.handleTouchMove_.bind(this),this.element_.addEventListener(Jp,this.boundHandleTouchMove_,!!Kg&&{passive:!1})}emulateClick_(e){let t=new Jn($e.CLICK,this.map_,e);this.dispatchEvent(t),this.clickTimeoutId_!==void 0?(clearTimeout(this.clickTimeoutId_),this.clickTimeoutId_=void 0,t=new Jn($e.DBLCLICK,this.map_,e),this.dispatchEvent(t)):this.clickTimeoutId_=setTimeout(()=>{this.clickTimeoutId_=void 0;const n=new Jn($e.SINGLECLICK,this.map_,e);this.dispatchEvent(n)},250)}updateActivePointers_(e){const t=e,n=t.pointerId;if(t.type==$e.POINTERUP||t.type==$e.POINTERCANCEL){delete this.trackedTouches_[n];for(const i in this.trackedTouches_)if(this.trackedTouches_[i].target!==t.target){delete this.trackedTouches_[i];break}}else(t.type==$e.POINTERDOWN||t.type==$e.POINTERMOVE)&&(this.trackedTouches_[n]=t);this.activePointers_=Object.values(this.trackedTouches_)}handlePointerUp_(e){this.updateActivePointers_(e);const t=new Jn($e.POINTERUP,this.map_,e,void 0,void 0,this.activePointers_);this.dispatchEvent(t),this.emulateClicks_&&!t.defaultPrevented&&!this.dragging_&&this.isMouseActionButton_(e)&&this.emulateClick_(this.down_),this.activePointers_.length===0&&(this.dragListenerKeys_.forEach(Le),this.dragListenerKeys_.length=0,this.dragging_=!1,this.down_=null)}isMouseActionButton_(e){return e.button===0}handlePointerDown_(e){this.emulateClicks_=this.activePointers_.length===0,this.updateActivePointers_(e);const t=new Jn($e.POINTERDOWN,this.map_,e,void 0,void 0,this.activePointers_);if(this.dispatchEvent(t),this.down_=new PointerEvent(e.type,e),Object.defineProperty(this.down_,"target",{writable:!1,value:e.target}),this.dragListenerKeys_.length===0){const n=this.map_.getOwnerDocument();this.dragListenerKeys_.push(we(n,$e.POINTERMOVE,this.handlePointerMove_,this),we(n,$e.POINTERUP,this.handlePointerUp_,this),we(this.element_,$e.POINTERCANCEL,this.handlePointerUp_,this)),this.element_.getRootNode&&this.element_.getRootNode()!==n&&this.dragListenerKeys_.push(we(this.element_.getRootNode(),$e.POINTERUP,this.handlePointerUp_,this))}}handlePointerMove_(e){if(this.isMoving_(e)){this.updateActivePointers_(e),this.dragging_=!0;const t=new Jn($e.POINTERDRAG,this.map_,e,this.dragging_,void 0,this.activePointers_);this.dispatchEvent(t)}}relayMoveEvent_(e){this.originalPointerMoveEvent_=e;const t=!(!this.down_||!this.isMoving_(e));this.dispatchEvent(new Jn($e.POINTERMOVE,this.map_,e,t))}handleTouchMove_(e){const t=this.originalPointerMoveEvent_;(!t||t.defaultPrevented)&&(typeof e.cancelable!="boolean"||e.cancelable===!0)&&e.preventDefault()}isMoving_(e){return this.dragging_||Math.abs(e.clientX-this.down_.clientX)>this.moveTolerance_||Math.abs(e.clientY-this.down_.clientY)>this.moveTolerance_}disposeInternal(){this.relayedListenerKey_&&(Le(this.relayedListenerKey_),this.relayedListenerKey_=null),this.element_.removeEventListener(Jp,this.boundHandleTouchMove_),this.pointerdownListenerKey_&&(Le(this.pointerdownListenerKey_),this.pointerdownListenerKey_=null),this.dragListenerKeys_.forEach(Le),this.dragListenerKeys_.length=0,this.element_=null,super.disposeInternal()}};const Ba="layergroup",fh="size",za="target",vo="view",ja=1/0;let a1=class{constructor(e,t){this.priorityFunction_=e,this.keyFunction_=t,this.elements_=[],this.priorities_=[],this.queuedElements_={}}clear(){this.elements_.length=0,this.priorities_.length=0,Br(this.queuedElements_)}dequeue(){const e=this.elements_,t=this.priorities_,n=e[0];e.length==1?(e.length=0,t.length=0):(e[0]=e.pop(),t[0]=t.pop(),this.siftUp_(0));const i=this.keyFunction_(n);return delete this.queuedElements_[i],n}enqueue(e){Ce(!(this.keyFunction_(e)in this.queuedElements_),"Tried to enqueue an `element` that was already added to the queue");const t=this.priorityFunction_(e);return t!=ja&&(this.elements_.push(e),this.priorities_.push(t),this.queuedElements_[this.keyFunction_(e)]=!0,this.siftDown_(0,this.elements_.length-1),!0)}getCount(){return this.elements_.length}getLeftChildIndex_(e){return 2*e+1}getRightChildIndex_(e){return 2*e+2}getParentIndex_(e){return e-1>>1}heapify_(){let e;for(e=(this.elements_.length>>1)-1;e>=0;e--)this.siftUp_(e)}isEmpty(){return this.elements_.length===0}isKeyQueued(e){return e in this.queuedElements_}isQueued(e){return this.isKeyQueued(this.keyFunction_(e))}siftUp_(e){const t=this.elements_,n=this.priorities_,i=t.length,r=t[e],s=n[e],o=e;for(;e<i>>1;){const a=this.getLeftChildIndex_(e),l=this.getRightChildIndex_(e),c=l<i&&n[l]<n[a]?l:a;t[e]=t[c],n[e]=n[c],e=c}t[e]=r,n[e]=s,this.siftDown_(o,e)}siftDown_(e,t){const n=this.elements_,i=this.priorities_,r=n[t],s=i[t];for(;t>e;){const o=this.getParentIndex_(t);if(!(i[o]>s))break;n[t]=n[o],i[t]=i[o],t=o}n[t]=r,i[t]=s}reprioritize(){const e=this.priorityFunction_,t=this.elements_,n=this.priorities_;let i=0;const r=t.length;let s,o,a;for(o=0;o<r;++o)s=t[o],a=e(s),a==ja?delete this.queuedElements_[this.keyFunction_(s)]:(n[i]=a,t[i++]=s);t.length=i,n.length=i,this.heapify_()}},l1=class extends a1{constructor(e,t){super(function(n){return e.apply(null,n)},function(n){return n[0].getKey()}),this.boundHandleTileChange_=this.handleTileChange.bind(this),this.tileChangeCallback_=t,this.tilesLoading_=0,this.tilesLoadingKeys_={}}enqueue(e){const t=super.enqueue(e);return t&&e[0].addEventListener(Be,this.boundHandleTileChange_),t}getTilesLoading(){return this.tilesLoading_}handleTileChange(e){const t=e.target,n=t.getState();if(n===Ot||n===kt||n===nt){n!==kt&&t.removeEventListener(Be,this.boundHandleTileChange_);const i=t.getKey();i in this.tilesLoadingKeys_&&(delete this.tilesLoadingKeys_[i],--this.tilesLoading_),this.tileChangeCallback_()}}loadMoreTiles(e,t){let n=0;for(;this.tilesLoading_<e&&n<t&&this.getCount()>0;){const i=this.dequeue()[0],r=i.getKey();i.getState()===Rt&&!(r in this.tilesLoadingKeys_)&&(this.tilesLoadingKeys_[r]=!0,++this.tilesLoading_,++n,i.load())}}},mh=class extends Kt{constructor(e){super();const t=e.element;t&&!e.target&&!t.style.pointerEvents&&(t.style.pointerEvents="auto"),this.element=t||null,this.target_=null,this.map_=null,this.listenerKeys=[],e.render&&(this.render=e.render),e.target&&this.setTarget(e.target)}disposeInternal(){var e;(e=this.element)==null||e.remove(),super.disposeInternal()}getMap(){return this.map_}setMap(e){var t;this.map_&&((t=this.element)==null||t.remove());for(let n=0,i=this.listenerKeys.length;n<i;++n)Le(this.listenerKeys[n]);this.listenerKeys.length=0,this.map_=e,e&&((this.target_??e.getOverlayContainerStopEvent()).appendChild(this.element),this.render!==Gi&&this.listenerKeys.push(we(e,Du,this.render,this)),e.render())}render(e){}setTarget(e){this.target_=typeof e=="string"?document.getElementById(e):e}},c1=class extends mh{constructor(e){e=e||{},super({element:document.createElement("div"),render:e.render,target:e.target}),this.ulElement_=document.createElement("ul"),this.collapsed_=e.collapsed===void 0||e.collapsed,this.userCollapsed_=this.collapsed_,this.overrideCollapsible_=e.collapsible!==void 0,this.collapsible_=e.collapsible===void 0||e.collapsible,this.collapsible_||(this.collapsed_=!1);const t=e.className!==void 0?e.className:"ol-attribution",n=e.tipLabel!==void 0?e.tipLabel:"Attributions",i=e.expandClassName!==void 0?e.expandClassName:t+"-expand",r=e.collapseLabel!==void 0?e.collapseLabel:"›",s=e.collapseClassName!==void 0?e.collapseClassName:t+"-collapse";typeof r=="string"?(this.collapseLabel_=document.createElement("span"),this.collapseLabel_.textContent=r,this.collapseLabel_.className=s):this.collapseLabel_=r;const o=e.label!==void 0?e.label:"i";typeof o=="string"?(this.label_=document.createElement("span"),this.label_.textContent=o,this.label_.className=i):this.label_=o;const a=this.collapsible_&&!this.collapsed_?this.collapseLabel_:this.label_;this.toggleButton_=document.createElement("button"),this.toggleButton_.setAttribute("type","button"),this.toggleButton_.setAttribute("aria-expanded",String(!this.collapsed_)),this.toggleButton_.title=n,this.toggleButton_.appendChild(a),this.toggleButton_.addEventListener(jr,this.handleClick_.bind(this),!1);const l=t+" "+Ea+" "+Uu+(this.collapsed_&&this.collapsible_?" "+Jf:"")+(this.collapsible_?"":" ol-uncollapsible"),c=this.element;c.className=l,c.appendChild(this.toggleButton_),c.appendChild(this.ulElement_),this.renderedAttributions_=[],this.renderedVisible_=!0}collectSourceAttributions_(e){const t=this.getMap().getAllLayers(),n=Array.from(new Set(t.flatMap(i=>i.getAttributions(e))));if(!this.overrideCollapsible_){const i=!t.some(r=>{var s;return((s=r.getSource())==null?void 0:s.getAttributionsCollapsible())===!1});this.setCollapsible(i)}return n}async updateElement_(e){if(!e)return void(this.renderedVisible_&&(this.element.style.display="none",this.renderedVisible_=!1));const t=await Promise.all(this.collectSourceAttributions_(e).map(i=>function(r){return function(){let s;try{s=r()}catch(o){return Promise.reject(o)}return s instanceof Promise?s:Promise.resolve(s)}()}(()=>i))),n=t.length>0;if(this.renderedVisible_!=n&&(this.element.style.display=n?"":"none",this.renderedVisible_=n),!ls(t,this.renderedAttributions_)){ef(this.ulElement_);for(let i=0,r=t.length;i<r;++i){const s=document.createElement("li");s.innerHTML=t[i],this.ulElement_.appendChild(s)}this.renderedAttributions_=t}}handleClick_(e){e.preventDefault(),this.handleToggle_(),this.userCollapsed_=this.collapsed_}handleToggle_(){this.element.classList.toggle(Jf),this.collapsed_?Jg(this.collapseLabel_,this.label_):Jg(this.label_,this.collapseLabel_),this.collapsed_=!this.collapsed_,this.toggleButton_.setAttribute("aria-expanded",String(!this.collapsed_))}getCollapsible(){return this.collapsible_}setCollapsible(e){this.collapsible_!==e&&(this.collapsible_=e,this.element.classList.toggle("ol-uncollapsible"),this.userCollapsed_&&this.handleToggle_())}setCollapsed(e){this.userCollapsed_=e,this.collapsible_&&this.collapsed_!==e&&this.handleToggle_()}getCollapsed(){return this.collapsed_}render(e){this.updateElement_(e.frameState)}},u1=class extends mh{constructor(e){e=e||{},super({element:document.createElement("div"),render:e.render,target:e.target});const t=e.className!==void 0?e.className:"ol-rotate",n=e.label!==void 0?e.label:"⇧",i=e.compassClassName!==void 0?e.compassClassName:"ol-compass";this.label_=null,typeof n=="string"?(this.label_=document.createElement("span"),this.label_.className=i,this.label_.textContent=n):(this.label_=n,this.label_.classList.add(i));const r=e.tipLabel?e.tipLabel:"Reset rotation",s=document.createElement("button");s.className=t+"-reset",s.setAttribute("type","button"),s.title=r,s.appendChild(this.label_),s.addEventListener(jr,this.handleClick_.bind(this),!1);const o=t+" "+Ea+" "+Uu,a=this.element;a.className=o,a.appendChild(s),this.callResetNorth_=e.resetNorth?e.resetNorth:void 0,this.duration_=e.duration!==void 0?e.duration:250,this.autoHide_=e.autoHide===void 0||e.autoHide,this.rotation_=void 0,this.autoHide_&&this.element.classList.add(wa)}handleClick_(e){e.preventDefault(),this.callResetNorth_!==void 0?this.callResetNorth_():this.resetNorth_()}resetNorth_(){const e=this.getMap().getView();if(!e)return;const t=e.getRotation();t!==void 0&&(this.duration_>0&&t%(2*Math.PI)!=0?e.animate({rotation:0,duration:this.duration_,easing:_i}):e.setRotation(0))}render(e){const t=e.frameState;if(!t)return;const n=t.viewState.rotation;if(n!=this.rotation_){const i="rotate("+n+"rad)";if(this.autoHide_){const r=this.element.classList.contains(wa);r||n!==0?r&&n!==0&&this.element.classList.remove(wa):this.element.classList.add(wa)}this.label_.style.transform=i}this.rotation_=n}},h1=class extends mh{constructor(e){e=e||{},super({element:document.createElement("div"),target:e.target});const t=e.className!==void 0?e.className:"ol-zoom",n=e.delta!==void 0?e.delta:1,i=e.zoomInClassName!==void 0?e.zoomInClassName:t+"-in",r=e.zoomOutClassName!==void 0?e.zoomOutClassName:t+"-out",s=e.zoomInLabel!==void 0?e.zoomInLabel:"+",o=e.zoomOutLabel!==void 0?e.zoomOutLabel:"–",a=e.zoomInTipLabel!==void 0?e.zoomInTipLabel:"Zoom in",l=e.zoomOutTipLabel!==void 0?e.zoomOutTipLabel:"Zoom out",c=document.createElement("button");c.className=i,c.setAttribute("type","button"),c.title=a,c.appendChild(typeof s=="string"?document.createTextNode(s):s),c.addEventListener(jr,this.handleClick_.bind(this,n),!1);const u=document.createElement("button");u.className=r,u.setAttribute("type","button"),u.title=l,u.appendChild(typeof o=="string"?document.createTextNode(o):o),u.addEventListener(jr,this.handleClick_.bind(this,-n),!1);const h=t+" "+Ea+" "+Uu,p=this.element;p.className=h,p.appendChild(c),p.appendChild(u),this.duration_=e.duration!==void 0?e.duration:250}handleClick_(e,t){t.preventDefault(),this.zoomByDelta_(e)}zoomByDelta_(e){const t=this.getMap().getView();if(!t)return;const n=t.getZoom();if(n!==void 0){const i=t.getConstrainedZoom(n+e);this.duration_>0?(t.getAnimating()&&t.cancelAnimations(),t.animate({zoom:i,duration:this.duration_,easing:_i})):t.setZoom(i)}}},d1=class extends mo{constructor(e){super(),e=e||{},this.delta_=e.delta?e.delta:1,this.duration_=e.duration!==void 0?e.duration:250}handleEvent(e){let t=!1;if(e.type==$e.DBLCLICK){const n=e.originalEvent,i=e.map,r=e.coordinate,s=n.shiftKey?-this.delta_:this.delta_;ph(i.getView(),s,r,this.duration_),n.preventDefault(),t=!0}return!t}},_o=class extends mo{constructor(e){super(e=e||{}),e.handleDownEvent&&(this.handleDownEvent=e.handleDownEvent),e.handleDragEvent&&(this.handleDragEvent=e.handleDragEvent),e.handleMoveEvent&&(this.handleMoveEvent=e.handleMoveEvent),e.handleUpEvent&&(this.handleUpEvent=e.handleUpEvent),e.stopDown&&(this.stopDown=e.stopDown),this.handlingDownUpSequence=!1,this.targetPointers=[]}getPointerCount(){return this.targetPointers.length}handleDownEvent(e){return!1}handleDragEvent(e){}handleEvent(e){if(!e.originalEvent)return!0;let t=!1;if(this.updateTrackedPointers_(e),this.handlingDownUpSequence){if(e.type==$e.POINTERDRAG)this.handleDragEvent(e),e.originalEvent.preventDefault();else if(e.type==$e.POINTERUP){const n=this.handleUpEvent(e);this.handlingDownUpSequence=n&&this.targetPointers.length>0}}else if(e.type==$e.POINTERDOWN){const n=this.handleDownEvent(e);this.handlingDownUpSequence=n,t=this.stopDown(n)}else e.type==$e.POINTERMOVE&&this.handleMoveEvent(e);return!t}handleMoveEvent(e){}handleUpEvent(e){return!1}stopDown(e){return e}updateTrackedPointers_(e){e.activePointers&&(this.targetPointers=e.activePointers)}};function vh(e){const t=e.length;let n=0,i=0;for(let r=0;r<t;r++)n+=e[r].clientX,i+=e[r].clientY;return{clientX:n/t,clientY:i/t}}let p1=class extends _o{constructor(e){super({stopDown:cs}),e=e||{},this.kinetic_=e.kinetic,this.lastCentroid=null,this.lastPointersCount_,this.panning_=!1;const t=e.condition?e.condition:Qu(I0,Ob);this.condition_=e.onFocusOnly?Qu(k0,t):t,this.noKinetic_=!1}handleDragEvent(e){const t=e.map;this.panning_||(this.panning_=!0,t.getView().beginInteraction());const n=this.targetPointers,i=t.getEventPixel(vh(n));if(n.length==this.lastPointersCount_){if(this.kinetic_&&this.kinetic_.update(i[0],i[1]),this.lastCentroid){const r=[this.lastCentroid[0]-i[0],i[1]-this.lastCentroid[1]],s=e.map.getView();(function(o,a){o[0]*=a,o[1]*=a})(r,s.getResolution()),kc(r,s.getRotation()),s.adjustCenterInternal(r)}}else this.kinetic_&&this.kinetic_.begin();this.lastCentroid=i,this.lastPointersCount_=n.length,e.originalEvent.preventDefault()}handleUpEvent(e){const t=e.map,n=t.getView();if(this.targetPointers.length===0){if(!this.noKinetic_&&this.kinetic_&&this.kinetic_.end()){const i=this.kinetic_.getDistance(),r=this.kinetic_.getAngle(),s=n.getCenterInternal(),o=t.getPixelFromCoordinateInternal(s),a=t.getCoordinateFromPixelInternal([o[0]-i*Math.cos(r),o[1]-i*Math.sin(r)]);n.animateInternal({center:n.getConstrainedCenter(a),duration:500,easing:_i})}return this.panning_&&(this.panning_=!1,n.endInteraction()),!1}return this.kinetic_&&this.kinetic_.begin(),this.lastCentroid=null,!0}handleDownEvent(e){if(this.targetPointers.length>0&&this.condition_(e)){const t=e.map.getView();return this.lastCentroid=null,t.getAnimating()&&t.cancelAnimations(),this.kinetic_&&this.kinetic_.begin(),this.noKinetic_=this.targetPointers.length>1,!0}return!1}},g1=class extends _o{constructor(e){e=e||{},super({stopDown:cs}),this.condition_=e.condition?e.condition:Mb,this.lastAngle_=void 0,this.duration_=e.duration!==void 0?e.duration:250}handleDragEvent(e){if(!La(e))return;const t=e.map,n=t.getView();if(n.getConstraints().rotation===Uc)return;const i=t.getSize(),r=e.pixel,s=Math.atan2(i[1]/2-r[1],r[0]-i[0]/2);if(this.lastAngle_!==void 0){const o=s-this.lastAngle_;n.adjustRotationInternal(-o)}this.lastAngle_=s}handleUpEvent(e){return!La(e)||(e.map.getView().endInteraction(this.duration_),!1)}handleDownEvent(e){return!!(La(e)&&P0(e)&&this.condition_(e))&&(e.map.getView().beginInteraction(),this.lastAngle_=void 0,!0)}},f1=class extends ss{constructor(e){super(),this.geometry_=null,this.element_=document.createElement("div"),this.element_.style.position="absolute",this.element_.style.pointerEvents="auto",this.element_.className="ol-box "+e,this.map_=null,this.startPixel_=null,this.endPixel_=null}disposeInternal(){this.setMap(null)}render_(){const e=this.startPixel_,t=this.endPixel_,n="px",i=this.element_.style;i.left=Math.min(e[0],t[0])+n,i.top=Math.min(e[1],t[1])+n,i.width=Math.abs(t[0]-e[0])+n,i.height=Math.abs(t[1]-e[1])+n}setMap(e){if(this.map_){this.map_.getOverlayContainer().removeChild(this.element_);const t=this.element_.style;t.left="inherit",t.top="inherit",t.width="inherit",t.height="inherit"}this.map_=e,this.map_&&this.map_.getOverlayContainer().appendChild(this.element_)}setPixels(e,t){this.startPixel_=e,this.endPixel_=t,this.createOrUpdateGeometry(),this.render_()}createOrUpdateGeometry(){if(!this.map_)return;const e=this.startPixel_,t=this.endPixel_,n=[e,[e[0],t[1]],t,[t[0],e[1]]].map(this.map_.getCoordinateFromPixelInternal,this.map_);n[4]=n[0].slice(),this.geometry_?this.geometry_.setCoordinates([n]):this.geometry_=new Hr([n])}getGeometry(){return this.geometry_}};const m1="boxstart",v1="boxdrag",_1="boxend",hm="boxcancel";let Na=class extends Cn{constructor(e,t,n){super(e),this.coordinate=t,this.mapBrowserEvent=n}},y1=class extends _o{constructor(e){super(),this.on,this.once,this.un,e=e||{},this.box_=new f1(e.className||"ol-dragbox"),this.minArea_=e.minArea!==void 0?e.minArea:64,e.onBoxEnd&&(this.onBoxEnd=e.onBoxEnd),this.startPixel_=null,this.condition_=e.condition?e.condition:P0,this.boxEndCondition_=e.boxEndCondition?e.boxEndCondition:this.defaultBoxEndCondition}defaultBoxEndCondition(e,t,n){const i=n[0]-t[0],r=n[1]-t[1];return i*i+r*r>=this.minArea_}getGeometry(){return this.box_.getGeometry()}handleDragEvent(e){this.startPixel_&&(this.box_.setPixels(this.startPixel_,e.pixel),this.dispatchEvent(new Na(v1,e.coordinate,e)))}handleUpEvent(e){if(!this.startPixel_)return!1;this.box_.setMap(null);const t=this.boxEndCondition_(e,this.startPixel_,e.pixel);return t&&this.onBoxEnd(e),this.dispatchEvent(new Na(t?_1:hm,e.coordinate,e)),!1}handleDownEvent(e){return!!this.condition_(e)&&(this.startPixel_=e.pixel,this.box_.setMap(e.map),this.box_.setPixels(this.startPixel_,this.startPixel_),this.dispatchEvent(new Na(m1,e.coordinate,e)),!0)}onBoxEnd(e){}setActive(e){e||(this.box_.setMap(null),this.startPixel_&&(this.dispatchEvent(new Na(hm,this.startPixel_,null)),this.startPixel_=null)),super.setActive(e)}},b1=class extends y1{constructor(e){super({condition:(e=e||{}).condition?e.condition:Fb,className:e.className||"ol-dragzoom",minArea:e.minArea}),this.duration_=e.duration!==void 0?e.duration:200,this.out_=e.out!==void 0&&e.out}onBoxEnd(e){const t=this.getMap().getView();let n=this.getGeometry();if(this.out_){const i=t.rotatedExtentForGeometry(n),r=t.getResolutionForExtentInternal(i),s=t.getResolution()/r;n=n.clone(),n.scale(s*s)}t.fitInternal(n,{duration:this.duration_,easing:_i})}};const dm="ArrowLeft",x1="ArrowUp",pm="ArrowRight",gm="ArrowDown";let w1=class extends mo{constructor(e){super(),e=e||{},this.defaultCondition_=function(t){return I0(t)&&M0(t)},this.condition_=e.condition!==void 0?e.condition:this.defaultCondition_,this.duration_=e.duration!==void 0?e.duration:100,this.pixelDelta_=e.pixelDelta!==void 0?e.pixelDelta:128}handleEvent(e){let t=!1;if(e.type==us){const n=e.originalEvent,i=n.key;if(this.condition_(e)&&(i==gm||i==dm||i==pm||i==x1)){const r=e.map.getView(),s=r.getResolution()*this.pixelDelta_;let o=0,a=0;i==gm?a=-s:i==dm?o=-s:i==pm?o=s:a=s;const l=[o,a];kc(l,r.getRotation()),function(c,u,h){const p=c.getCenterInternal();if(p){const f=[p[0]+u[0],p[1]+u[1]];c.animateInternal({duration:h!==void 0?h:250,easing:ny,center:c.getConstrainedCenter(f)})}}(r,l,this.duration_),n.preventDefault(),t=!0}}return!t}},E1=class extends mo{constructor(e){super(),e=e||{},this.condition_=e.condition?e.condition:function(t){return!function(n){const i=n.originalEvent;return Yg?i.metaKey:i.ctrlKey}(t)&&M0(t)},this.delta_=e.delta?e.delta:1,this.duration_=e.duration!==void 0?e.duration:100}handleEvent(e){let t=!1;if(e.type==us||e.type==Qp){const n=e.originalEvent,i=n.key;if(this.condition_(e)&&(i==="+"||i==="-")){const r=e.map,s=i==="+"?this.delta_:-this.delta_;ph(r.getView(),s,void 0,this.duration_),n.preventDefault(),t=!0}}return!t}},C1=class{constructor(e,t,n){this.decay_=e,this.minVelocity_=t,this.delay_=n,this.points_=[],this.angle_=0,this.initialVelocity_=0}begin(){this.points_.length=0,this.angle_=0,this.initialVelocity_=0}update(e,t){this.points_.push(e,t,Date.now())}end(){if(this.points_.length<6)return!1;const e=Date.now()-this.delay_,t=this.points_.length-3;if(this.points_[t+2]<e)return!1;let n=t-3;for(;n>0&&this.points_[n+2]>e;)n-=3;const i=this.points_[t+2]-this.points_[n+2];if(i<1e3/60)return!1;const r=this.points_[t]-this.points_[n],s=this.points_[t+1]-this.points_[n+1];return this.angle_=Math.atan2(s,r),this.initialVelocity_=Math.sqrt(r*r+s*s)/i,this.initialVelocity_>this.minVelocity_}getDistance(){return(this.minVelocity_-this.initialVelocity_)/this.decay_}getAngle(){return this.angle_}},A1=class extends _o{constructor(e){const t=e=e||{};t.stopDown||(t.stopDown=cs),super(t),this.anchor_=null,this.lastAngle_=void 0,this.rotating_=!1,this.rotationDelta_=0,this.threshold_=e.threshold!==void 0?e.threshold:.3,this.duration_=e.duration!==void 0?e.duration:250}handleDragEvent(e){let t=0;const n=this.targetPointers[0],i=this.targetPointers[1],r=Math.atan2(i.clientY-n.clientY,i.clientX-n.clientX);if(this.lastAngle_!==void 0){const a=r-this.lastAngle_;this.rotationDelta_+=a,!this.rotating_&&Math.abs(this.rotationDelta_)>this.threshold_&&(this.rotating_=!0),t=a}this.lastAngle_=r;const s=e.map,o=s.getView();o.getConstraints().rotation!==Uc&&(this.anchor_=s.getCoordinateFromPixelInternal(s.getEventPixel(vh(this.targetPointers))),this.rotating_&&(s.render(),o.adjustRotationInternal(t,this.anchor_)))}handleUpEvent(e){return!(this.targetPointers.length<2)||(e.map.getView().endInteraction(this.duration_),!1)}handleDownEvent(e){if(this.targetPointers.length>=2){const t=e.map;return this.anchor_=null,this.lastAngle_=void 0,this.rotating_=!1,this.rotationDelta_=0,this.handlingDownUpSequence||t.getView().beginInteraction(),!0}return!1}},S1=class extends _o{constructor(e){const t=e=e||{};t.stopDown||(t.stopDown=cs),super(t),this.anchor_=null,this.duration_=e.duration!==void 0?e.duration:400,this.lastDistance_=void 0,this.lastScaleDelta_=1}handleDragEvent(e){let t=1;const n=this.targetPointers[0],i=this.targetPointers[1],r=n.clientX-i.clientX,s=n.clientY-i.clientY,o=Math.sqrt(r*r+s*s);this.lastDistance_!==void 0&&(t=this.lastDistance_/o),this.lastDistance_=o;const a=e.map,l=a.getView();t!=1&&(this.lastScaleDelta_=t),this.anchor_=a.getCoordinateFromPixelInternal(a.getEventPixel(vh(this.targetPointers))),a.render(),l.adjustResolutionInternal(t,this.anchor_)}handleUpEvent(e){if(this.targetPointers.length<2){const t=e.map.getView(),n=this.lastScaleDelta_>1?1:-1;return t.endInteraction(this.duration_,n),!1}return!0}handleDownEvent(e){if(this.targetPointers.length>=2){const t=e.map;return this.anchor_=null,this.lastDistance_=void 0,this.lastScaleDelta_=1,this.handlingDownUpSequence||t.getView().beginInteraction(),!0}return!1}};function fm(e){e=e||{};const t=new gn,n=new C1(-.005,.05,100);return(e.altShiftDragRotate===void 0||e.altShiftDragRotate)&&t.push(new g1),(e.doubleClickZoom===void 0||e.doubleClickZoom)&&t.push(new d1({delta:e.zoomDelta,duration:e.zoomDuration})),(e.dragPan===void 0||e.dragPan)&&t.push(new p1({onFocusOnly:e.onFocusOnly,kinetic:n})),(e.pinchRotate===void 0||e.pinchRotate)&&t.push(new A1),(e.pinchZoom===void 0||e.pinchZoom)&&t.push(new S1({duration:e.zoomDuration})),(e.keyboard===void 0||e.keyboard)&&(t.push(new w1),t.push(new E1({delta:e.zoomDelta,duration:e.zoomDuration}))),(e.mouseWheelZoom===void 0||e.mouseWheelZoom)&&t.push(new cm({onFocusOnly:e.onFocusOnly,duration:e.zoomDuration})),(e.shiftDragZoom===void 0||e.shiftDragZoom)&&t.push(new b1({duration:e.zoomDuration})),t}function mm(e){e instanceof Kr?e.setMapInternal(null):e instanceof Ua&&e.getLayers().forEach(mm)}function vm(e,t){if(e instanceof Kr)e.setMapInternal(t);else if(e instanceof Ua){const n=e.getLayers().getArray();for(let i=0,r=n.length;i<r;++i)vm(n[i],t)}}class T1 extends Kt{constructor(t){super(),t=t||{},this.on,this.once,this.un;const n=function(r){let s=null;r.keyboardEventTarget!==void 0&&(s=typeof r.keyboardEventTarget=="string"?document.getElementById(r.keyboardEventTarget):r.keyboardEventTarget);const o={},a=r.layers&&typeof r.layers.getLayers=="function"?r.layers:new Ua({layers:r.layers});let l,c,u;return o[Ba]=a,o[za]=r.target,o[vo]=r.view instanceof cn?r.view:new cn,r.controls!==void 0&&(Array.isArray(r.controls)?l=new gn(r.controls.slice()):(Ce(typeof r.controls.getArray=="function","Expected `controls` to be an array or an `ol/Collection.js`"),l=r.controls)),r.interactions!==void 0&&(Array.isArray(r.interactions)?c=new gn(r.interactions.slice()):(Ce(typeof r.interactions.getArray=="function","Expected `interactions` to be an array or an `ol/Collection.js`"),c=r.interactions)),r.overlays!==void 0?Array.isArray(r.overlays)?u=new gn(r.overlays.slice()):(Ce(typeof r.overlays.getArray=="function","Expected `overlays` to be an array or an `ol/Collection.js`"),u=r.overlays):u=new gn,{controls:l,interactions:c,keyboardEventTarget:s,overlays:u,values:o}}(t);this.renderComplete_=!1,this.loaded_=!0,this.boundHandleBrowserEvent_=this.handleBrowserEvent.bind(this),this.maxTilesLoading_=t.maxTilesLoading!==void 0?t.maxTilesLoading:16,this.pixelRatio_=t.pixelRatio!==void 0?t.pixelRatio:Zg,this.postRenderTimeoutHandle_,this.animationDelayKey_,this.animationDelay_=this.animationDelay_.bind(this),this.coordinateToPixelTransform_=[1,0,0,1,0,0],this.pixelToCoordinateTransform_=[1,0,0,1,0,0],this.frameIndex_=0,this.frameState_=null,this.previousExtent_=null,this.viewPropertyListenerKey_=null,this.viewChangeListenerKey_=null,this.layerGroupPropertyListenerKeys_=null,this.viewport_=document.createElement("div"),this.viewport_.className="ol-viewport"+("ontouchstart"in window?" ol-touch":""),this.viewport_.style.position="relative",this.viewport_.style.overflow="hidden",this.viewport_.style.width="100%",this.viewport_.style.height="100%",this.overlayContainer_=document.createElement("div"),this.overlayContainer_.style.position="absolute",this.overlayContainer_.style.zIndex="0",this.overlayContainer_.style.width="100%",this.overlayContainer_.style.height="100%",this.overlayContainer_.style.pointerEvents="none",this.overlayContainer_.className="ol-overlaycontainer",this.viewport_.appendChild(this.overlayContainer_),this.overlayContainerStopEvent_=document.createElement("div"),this.overlayContainerStopEvent_.style.position="absolute",this.overlayContainerStopEvent_.style.zIndex="0",this.overlayContainerStopEvent_.style.width="100%",this.overlayContainerStopEvent_.style.height="100%",this.overlayContainerStopEvent_.style.pointerEvents="none",this.overlayContainerStopEvent_.className="ol-overlaycontainer-stopevent",this.viewport_.appendChild(this.overlayContainerStopEvent_),this.mapBrowserEventHandler_=null,this.moveTolerance_=t.moveTolerance,this.keyboardEventTarget_=n.keyboardEventTarget,this.targetChangeHandlerKeys_=null,this.targetElement_=null,this.resizeObserver_=new ResizeObserver(()=>this.updateSize()),this.controls=n.controls||function(r){r=r||{};const s=new gn;return(r.zoom===void 0||r.zoom)&&s.push(new h1(r.zoomOptions)),(r.rotate===void 0||r.rotate)&&s.push(new u1(r.rotateOptions)),(r.attribution===void 0||r.attribution)&&s.push(new c1(r.attributionOptions)),s}(),this.interactions=n.interactions||fm({onFocusOnly:!0}),this.overlays_=n.overlays,this.overlayIdIndex_={},this.renderer_=null,this.postRenderFunctions_=[],this.tileQueue_=new l1(this.getTilePriority.bind(this),this.handleTileChange_.bind(this)),this.addChangeListener(Ba,this.handleLayerGroupChanged_),this.addChangeListener(vo,this.handleViewChanged_),this.addChangeListener(fh,this.handleSizeChanged_),this.addChangeListener(za,this.handleTargetChanged_),this.setProperties(n.values);const i=this;t.view&&!(t.view instanceof cn)&&t.view.then(function(r){i.setView(new cn(r))}),this.controls.addEventListener(Ai,r=>{r.element.setMap(this)}),this.controls.addEventListener(Si,r=>{r.element.setMap(null)}),this.interactions.addEventListener(Ai,r=>{r.element.setMap(this)}),this.interactions.addEventListener(Si,r=>{r.element.setMap(null)}),this.overlays_.addEventListener(Ai,r=>{this.addOverlayInternal_(r.element)}),this.overlays_.addEventListener(Si,r=>{const s=r.element.getId();s!==void 0&&delete this.overlayIdIndex_[s.toString()],r.element.setMap(null)}),this.controls.forEach(r=>{r.setMap(this)}),this.interactions.forEach(r=>{r.setMap(this)}),this.overlays_.forEach(this.addOverlayInternal_.bind(this))}addControl(t){this.getControls().push(t)}addInteraction(t){this.getInteractions().push(t)}addLayer(t){this.getLayerGroup().getLayers().push(t)}handleLayerAdd_(t){vm(t.layer,this)}addOverlay(t){this.getOverlays().push(t)}addOverlayInternal_(t){const n=t.getId();n!==void 0&&(this.overlayIdIndex_[n.toString()]=t),t.setMap(this)}disposeInternal(){this.controls.clear(),this.interactions.clear(),this.overlays_.clear(),this.resizeObserver_.disconnect(),this.setTarget(null),super.disposeInternal()}forEachFeatureAtPixel(t,n,i){if(!this.frameState_||!this.renderer_)return;const r=this.getCoordinateFromPixelInternal(t),s=(i=i!==void 0?i:{}).hitTolerance!==void 0?i.hitTolerance:0,o=i.layerFilter!==void 0?i.layerFilter:Ur,a=i.checkWrapped!==!1;return this.renderer_.forEachFeatureAtCoordinate(r,this.frameState_,s,a,n,null,o,null)}getFeaturesAtPixel(t,n){const i=[];return this.forEachFeatureAtPixel(t,function(r){i.push(r)},n),i}getAllLayers(){const t=[];return function n(i){i.forEach(function(r){r instanceof Ua?n(r.getLayers()):t.push(r)})}(this.getLayers()),t}hasFeatureAtPixel(t,n){if(!this.frameState_||!this.renderer_)return!1;const i=this.getCoordinateFromPixelInternal(t),r=(n=n!==void 0?n:{}).layerFilter!==void 0?n.layerFilter:Ur,s=n.hitTolerance!==void 0?n.hitTolerance:0,o=n.checkWrapped!==!1;return this.renderer_.hasFeatureAtCoordinate(i,this.frameState_,s,o,r,null)}getEventCoordinate(t){return this.getCoordinateFromPixel(this.getEventPixel(t))}getEventCoordinateInternal(t){return this.getCoordinateFromPixelInternal(this.getEventPixel(t))}getEventPixel(t){const n=this.viewport_.getBoundingClientRect(),i=this.getSize(),r=n.width/i[0],s=n.height/i[1],o="changedTouches"in t?t.changedTouches[0]:t;return[(o.clientX-n.left)/r,(o.clientY-n.top)/s]}getTarget(){return this.get(za)}getTargetElement(){return this.targetElement_}getCoordinateFromPixel(t){return Fc(this.getCoordinateFromPixelInternal(t),this.getView().getProjection())}getCoordinateFromPixelInternal(t){const n=this.frameState_;return n?Wr(n.pixelToCoordinateTransform,t.slice()):null}getControls(){return this.controls}getOverlays(){return this.overlays_}getOverlayById(t){const n=this.overlayIdIndex_[t.toString()];return n!==void 0?n:null}getInteractions(){return this.interactions}getLayerGroup(){return this.get(Ba)}setLayers(t){const n=this.getLayerGroup();if(t instanceof gn)return void n.setLayers(t);const i=n.getLayers();i.clear(),i.extend(t)}getLayers(){return this.getLayerGroup().getLayers()}getLoadingOrNotReady(){const t=this.getLayerGroup().getLayerStatesArray();for(let n=0,i=t.length;n<i;++n){const r=t[n];if(!r.visible)continue;const s=r.layer.getRenderer();if(s&&!s.ready)return!0;const o=r.layer.getSource();if(o&&o.loading)return!0}return!1}getPixelFromCoordinate(t){const n=An(t,this.getView().getProjection());return this.getPixelFromCoordinateInternal(n)}getPixelFromCoordinateInternal(t){const n=this.frameState_;return n?Wr(n.coordinateToPixelTransform,t.slice(0,2)):null}getRenderer(){return this.renderer_}getSize(){return this.get(fh)}getView(){return this.get(vo)}getViewport(){return this.viewport_}getOverlayContainer(){return this.overlayContainer_}getOverlayContainerStopEvent(){return this.overlayContainerStopEvent_}getOwnerDocument(){const t=this.getTargetElement();return t?t.ownerDocument:document}getTilePriority(t,n,i,r){return function(s,o,a,l,c){if(!s||!(a in s.wantedTiles)||!s.wantedTiles[a][o.getKey()])return ja;const u=s.viewState.center,h=l[0]-u[0],p=l[1]-u[1];return 65536*Math.log(c)+Math.sqrt(h*h+p*p)/c}(this.frameState_,t,n,i,r)}handleBrowserEvent(t,n){n=n||t.type;const i=new Jn(n,this,t);this.handleMapBrowserEvent(i)}handleMapBrowserEvent(t){if(!this.frameState_)return;const n=t.originalEvent,i=n.type;if(i===um||i===Nr||i===us){const r=this.getOwnerDocument(),s=this.viewport_.getRootNode?this.viewport_.getRootNode():r,o=n.target;if(this.overlayContainerStopEvent_.contains(o)||!(s===r?r.documentElement:s).contains(o))return}if(t.frameState=this.frameState_,this.dispatchEvent(t)!==!1){const r=this.getInteractions().getArray().slice();for(let s=r.length-1;s>=0;s--){const o=r[s];if(o.getMap()===this&&o.getActive()&&this.getTargetElement()&&(!o.handleEvent(t)||t.propagationStopped))break}}}handlePostRender(){const t=this.frameState_,n=this.tileQueue_;if(!n.isEmpty()){let r=this.maxTilesLoading_,s=r;if(t){const o=t.viewHints;if(o[qn]||o[qi]){const a=Date.now()-t.time>8;r=a?0:8,s=a?0:2}}n.getTilesLoading()<r&&(n.reprioritize(),n.loadMoreTiles(r,s))}t&&this.renderer_&&!t.animate&&(this.renderComplete_?(this.hasListener(dc)&&this.renderer_.dispatchRenderEvent(dc,t),this.loaded_===!1&&(this.loaded_=!0,this.dispatchEvent(new hr(Qf,this,t)))):this.loaded_===!0&&(this.loaded_=!1,this.dispatchEvent(new hr(Kf,this,t))));const i=this.postRenderFunctions_;for(let r=0,s=i.length;r<s;++r)i[r](this,t);i.length=0}handleSizeChanged_(){this.getView()&&!this.getView().getAnimating()&&this.getView().resolveConstraints(0),this.render()}handleTargetChanged_(){if(this.mapBrowserEventHandler_){for(let i=0,r=this.targetChangeHandlerKeys_.length;i<r;++i)Le(this.targetChangeHandlerKeys_[i]);this.targetChangeHandlerKeys_=null,this.viewport_.removeEventListener(Kp,this.boundHandleBrowserEvent_),this.viewport_.removeEventListener(Nr,this.boundHandleBrowserEvent_),this.mapBrowserEventHandler_.dispose(),this.mapBrowserEventHandler_=null,this.viewport_.remove()}if(this.targetElement_){this.resizeObserver_.unobserve(this.targetElement_);const i=this.targetElement_.getRootNode();i instanceof ShadowRoot&&this.resizeObserver_.unobserve(i.host),this.setSize(void 0)}const t=this.getTarget(),n=typeof t=="string"?document.getElementById(t):t;if(this.targetElement_=n,n){n.appendChild(this.viewport_),this.renderer_||(this.renderer_=new r1(this)),this.mapBrowserEventHandler_=new s1(this,this.moveTolerance_);for(const s in $e)this.mapBrowserEventHandler_.addEventListener($e[s],this.handleMapBrowserEvent.bind(this));this.viewport_.addEventListener(Kp,this.boundHandleBrowserEvent_,!1),this.viewport_.addEventListener(Nr,this.boundHandleBrowserEvent_,!!Kg&&{passive:!1});const i=this.keyboardEventTarget_?this.keyboardEventTarget_:n;this.targetChangeHandlerKeys_=[we(i,us,this.handleBrowserEvent,this),we(i,Qp,this.handleBrowserEvent,this)];const r=n.getRootNode();r instanceof ShadowRoot&&this.resizeObserver_.observe(r.host),this.resizeObserver_.observe(n)}else this.renderer_&&(clearTimeout(this.postRenderTimeoutHandle_),this.postRenderTimeoutHandle_=void 0,this.postRenderFunctions_.length=0,this.renderer_.dispose(),this.renderer_=null),this.animationDelayKey_&&(cancelAnimationFrame(this.animationDelayKey_),this.animationDelayKey_=void 0);this.updateSize()}handleTileChange_(){this.render()}handleViewPropertyChanged_(){this.render()}handleViewChanged_(){this.viewPropertyListenerKey_&&(Le(this.viewPropertyListenerKey_),this.viewPropertyListenerKey_=null),this.viewChangeListenerKey_&&(Le(this.viewChangeListenerKey_),this.viewChangeListenerKey_=null);const t=this.getView();t&&(this.updateViewportSize_(this.getSize()),this.viewPropertyListenerKey_=we(t,Ni,this.handleViewPropertyChanged_,this),this.viewChangeListenerKey_=we(t,Be,this.handleViewPropertyChanged_,this),t.resolveConstraints(0)),this.render()}handleLayerGroupChanged_(){this.layerGroupPropertyListenerKeys_&&(this.layerGroupPropertyListenerKeys_.forEach(Le),this.layerGroupPropertyListenerKeys_=null);const t=this.getLayerGroup();t&&(this.handleLayerAdd_(new Qn("addlayer",t)),this.layerGroupPropertyListenerKeys_=[we(t,Ni,this.render,this),we(t,Be,this.render,this),we(t,"addlayer",this.handleLayerAdd_,this),we(t,"removelayer",this.handleLayerRemove_,this)]),this.render()}isRendered(){return!!this.frameState_}animationDelay_(){this.animationDelayKey_=void 0,this.renderFrame_(Date.now())}renderSync(){this.animationDelayKey_&&cancelAnimationFrame(this.animationDelayKey_),this.animationDelay_()}redrawText(){const t=this.getLayerGroup().getLayerStatesArray();for(let n=0,i=t.length;n<i;++n){const r=t[n].layer;r.hasRenderer()&&r.getRenderer().handleFontsChanged()}}render(){this.renderer_&&this.animationDelayKey_===void 0&&(this.animationDelayKey_=requestAnimationFrame(this.animationDelay_))}removeControl(t){return this.getControls().remove(t)}removeInteraction(t){return this.getInteractions().remove(t)}removeLayer(t){return this.getLayerGroup().getLayers().remove(t)}handleLayerRemove_(t){mm(t.layer)}removeOverlay(t){return this.getOverlays().remove(t)}renderFrame_(t){const n=this.getSize(),i=this.getView(),r=this.frameState_;let s=null;if(n!==void 0&&hf(n)&&i&&i.isDef()){const o=i.getHints(this.frameState_?this.frameState_.viewHints:void 0),a=i.getState();if(s={animate:!1,coordinateToPixelTransform:this.coordinateToPixelTransform_,declutter:null,extent:Sc(a.center,a.resolution,a.rotation,n),index:this.frameIndex_++,layerIndex:0,layerStatesArray:this.getLayerGroup().getLayerStatesArray(),pixelRatio:this.pixelRatio_,pixelToCoordinateTransform:this.pixelToCoordinateTransform_,postRenderFunctions:[],size:n,tileQueue:this.tileQueue_,time:t,usedTiles:{},viewState:a,viewHints:o,wantedTiles:{},mapId:Ae(this),renderTargets:{}},a.nextCenter&&a.nextResolution){const l=isNaN(a.nextRotation)?a.rotation:a.nextRotation;s.nextExtent=Sc(a.nextCenter,a.nextResolution,l,n)}}this.frameState_=s,this.renderer_.renderFrame(s),s&&(s.animate&&this.render(),Array.prototype.push.apply(this.postRenderFunctions_,s.postRenderFunctions),r&&(!this.previousExtent_||!mi(this.previousExtent_)&&!$r(s.extent,this.previousExtent_))&&(this.dispatchEvent(new hr(ub,this,r)),this.previousExtent_=Zi(this.previousExtent_)),this.previousExtent_&&!s.viewHints[qn]&&!s.viewHints[qi]&&!$r(s.extent,this.previousExtent_)&&(this.dispatchEvent(new hr(hb,this,s)),function(o,a){a?(a[0]=o[0],a[1]=o[1],a[2]=o[2],a[3]=o[3]):o.slice()}(s.extent,this.previousExtent_))),this.dispatchEvent(new hr(Du,this,s)),this.renderComplete_=(this.hasListener(Kf)||this.hasListener(Qf)||this.hasListener(dc))&&!this.tileQueue_.getTilesLoading()&&!this.tileQueue_.getCount()&&!this.getLoadingOrNotReady(),this.postRenderTimeoutHandle_||(this.postRenderTimeoutHandle_=setTimeout(()=>{this.postRenderTimeoutHandle_=void 0,this.handlePostRender()},0))}setLayerGroup(t){const n=this.getLayerGroup();n&&this.handleLayerRemove_(new Qn("removelayer",n)),this.set(Ba,t)}setSize(t){this.set(fh,t)}setTarget(t){this.set(za,t)}setView(t){if(!t||t instanceof cn)return void this.set(vo,t);this.set(vo,new cn);const n=this;t.then(function(i){n.setView(new cn(i))})}updateSize(){const t=this.getTargetElement();let n;if(t){const r=getComputedStyle(t),s=t.offsetWidth-parseFloat(r.borderLeftWidth)-parseFloat(r.paddingLeft)-parseFloat(r.paddingRight)-parseFloat(r.borderRightWidth),o=t.offsetHeight-parseFloat(r.borderTopWidth)-parseFloat(r.paddingTop)-parseFloat(r.paddingBottom)-parseFloat(r.borderBottomWidth);!isNaN(s)&&!isNaN(o)&&(n=[Math.max(0,s),Math.max(0,o)],!hf(n)&&(t.offsetWidth||t.offsetHeight||t.getClientRects().length)&&fg("No map visible because the map container's width or height are 0."))}const i=this.getSize();n&&(!i||!ls(n,i))&&(this.setSize(n),this.updateViewportSize_(n))}updateViewportSize_(t){const n=this.getView();n&&n.setViewportSize(t)}}let _m=class extends gf{clear(){for(;this.getCount()>0;)this.pop().release();super.clear()}expireCache(e){for(;this.canExpireCache()&&!(this.peekLast().getKey()in e);)this.pop().release()}pruneExceptNewestZ(){if(this.getCount()===0)return;const e=function(t){return t.split("/").map(Number)}(this.peekFirstKey())[0];this.forEach(t=>{t.tileCoord[0]!==e&&(this.remove(Yn(t.tileCoord)),t.release())})}};const R1="tileloadstart",k1="tileloadend",P1="tileloaderror";let I1=class extends rm{constructor(e){super({attributions:e.attributions,attributionsCollapsible:e.attributionsCollapsible,projection:e.projection,state:e.state,wrapX:e.wrapX,interpolate:e.interpolate}),this.on,this.once,this.un,this.tilePixelRatio_=e.tilePixelRatio!==void 0?e.tilePixelRatio:1,this.tileGrid=e.tileGrid!==void 0?e.tileGrid:null,this.tileGrid&&lt(this.tileGrid.getTileSize(this.tileGrid.getMinZoom()),[256,256]),this.tileCache=new _m(e.cacheSize||0),this.tmpSize=[0,0],this.key_=e.key||"",this.tileOptions={transition:e.transition,interpolate:e.interpolate},this.zDirection=e.zDirection?e.zDirection:0}canExpireCache(){return this.tileCache.canExpireCache()}expireCache(e,t){const n=this.getTileCacheForProjection(e);n&&n.expireCache(t)}getGutterForProjection(e){return 0}getKey(){return this.key_}setKey(e){this.key_!==e&&(this.key_=e,this.changed())}getResolutions(e){const t=e?this.getTileGridForProjection(e):this.tileGrid;return t?t.getResolutions():null}getTile(e,t,n,i,r){return ue()}getTileGrid(){return this.tileGrid}getTileGridForProjection(e){return this.tileGrid?this.tileGrid:Y0(e)}getTileCacheForProjection(e){const t=this.getProjection();return Ce(t===null||Hi(t,e),"A VectorTile source can only be rendered if it has a projection compatible with the view projection."),this.tileCache}getTilePixelRatio(e){return this.tilePixelRatio_}getTilePixelSize(e,t,n){const i=this.getTileGridForProjection(n),r=this.getTilePixelRatio(t),s=lt(i.getTileSize(e),this.tmpSize);return r==1?s:function(o,a,l){return l===void 0&&(l=[0,0]),l[0]=o[0]*a+.5|0,l[1]=o[1]*a+.5|0,l}(s,r,this.tmpSize)}getTileCoordForTileUrlFunction(e,t){t=t!==void 0?t:this.getProjection();const n=this.getTileGridForProjection(t);return this.getWrapX()&&t.isGlobal()&&(e=function(i,r,s){const o=r[0],a=i.getTileCoordCenter(r),l=oh(s);if(!bs(l,a)){const c=ze(l),u=Math.ceil((l[0]-a[0])/c);return a[0]+=c*u,i.getTileCoordForCoordAndZ(a,o)}return r}(n,e,t)),function(i,r){const s=i[0],o=i[1],a=i[2];if(r.getMinZoom()>s||s>r.getMaxZoom())return!1;const l=r.getFullTileRange(s);return!l||l.containsXY(o,a)}(e,n)?e:null}clear(){this.tileCache.clear()}refresh(){this.clear(),super.refresh()}useTile(e,t,n,i){}},M1=class extends Cn{constructor(e,t){super(e),this.tile=t}};const L1=/\{z\}/g,F1=/\{x\}/g,O1=/\{y\}/g,D1=/\{-y\}/g;function U1(e,t){return function(n,i,r){if(!n)return;let s;const o=n[0];if(t){const a=t.getFullTileRange(o);a&&(s=a.getHeight()-1)}return function(a,l,c,u,h){return a.replace(L1,l.toString()).replace(F1,c.toString()).replace(O1,u.toString()).replace(D1,function(){if(h===void 0)throw new Error("If the URL template has a {-y} placeholder, the grid extent must be known");return(h-u).toString()})}(e,o,n[1],n[2],s)}}function B1(e,t){const n=e.length,i=new Array(n);for(let r=0;r<n;++r)i[r]=U1(e[r],t);return function(r){return r.length===1?r[0]:function(s,o,a){if(!s)return;const l=function(u){return function(h,p,f){return(p<<h)+f}(u[0],u[1],u[2])}(s),c=$i(l,r.length);return r[c](s,o,a)}}(i)}let z1=class Km extends I1{constructor(t){super({attributions:t.attributions,cacheSize:t.cacheSize,projection:t.projection,state:t.state,tileGrid:t.tileGrid,tilePixelRatio:t.tilePixelRatio,wrapX:t.wrapX,transition:t.transition,interpolate:t.interpolate,key:t.key,attributionsCollapsible:t.attributionsCollapsible,zDirection:t.zDirection}),this.generateTileUrlFunction_=this.tileUrlFunction===Km.prototype.tileUrlFunction,this.tileLoadFunction=t.tileLoadFunction,t.tileUrlFunction&&(this.tileUrlFunction=t.tileUrlFunction),this.urls=null,t.urls?this.setUrls(t.urls):t.url&&this.setUrl(t.url),this.tileLoadingKeys_={}}getTileLoadFunction(){return this.tileLoadFunction}getTileUrlFunction(){return Object.getPrototypeOf(this).tileUrlFunction===this.tileUrlFunction?this.tileUrlFunction.bind(this):this.tileUrlFunction}getUrls(){return this.urls}handleTileChange(t){const n=t.target,i=Ae(n),r=n.getState();let s;r==wi?(this.tileLoadingKeys_[i]=!0,s=R1):i in this.tileLoadingKeys_&&(delete this.tileLoadingKeys_[i],s=r==kt?P1:r==Ot?k1:void 0),s!=null&&this.dispatchEvent(new M1(s,n))}setTileLoadFunction(t){this.tileCache.clear(),this.tileLoadFunction=t,this.changed()}setTileUrlFunction(t,n){this.tileUrlFunction=t,this.tileCache.pruneExceptNewestZ(),typeof n<"u"?this.setKey(n):this.changed()}setUrl(t){const n=function(i){const r=[];let s=/\{([a-z])-([a-z])\}/.exec(i);if(s){const o=s[1].charCodeAt(0),a=s[2].charCodeAt(0);let l;for(l=o;l<=a;++l)r.push(i.replace(s[0],String.fromCharCode(l)));return r}if(s=/\{(\d+)-(\d+)\}/.exec(i),s){const o=parseInt(s[2],10);for(let a=parseInt(s[1],10);a<=o;a++)r.push(i.replace(s[0],a.toString()));return r}return r.push(i),r}(t);this.urls=n,this.setUrls(n)}setUrls(t){this.urls=t;const n=t.join(`
`);this.generateTileUrlFunction_?this.setTileUrlFunction(B1(t,this.tileGrid),n):this.setKey(n)}tileUrlFunction(t,n,i){}useTile(t,n,i){const r=au(t,n,i);this.tileCache.containsKey(r)&&this.tileCache.get(r)}},j1=class extends z1{constructor(e){super({attributions:e.attributions,cacheSize:e.cacheSize,projection:e.projection,state:e.state,tileGrid:e.tileGrid,tileLoadFunction:e.tileLoadFunction?e.tileLoadFunction:N1,tilePixelRatio:e.tilePixelRatio,tileUrlFunction:e.tileUrlFunction,url:e.url,urls:e.urls,wrapX:e.wrapX,transition:e.transition,interpolate:e.interpolate===void 0||e.interpolate,key:e.key,attributionsCollapsible:e.attributionsCollapsible,zDirection:e.zDirection}),this.crossOrigin=e.crossOrigin!==void 0?e.crossOrigin:null,this.tileClass=e.tileClass!==void 0?e.tileClass:iu,this.tileCacheForProjection={},this.tileGridForProjection={},this.reprojectionErrorThreshold_=e.reprojectionErrorThreshold,this.renderReprojectionEdges_=!1}canExpireCache(){if(this.tileCache.canExpireCache())return!0;for(const e in this.tileCacheForProjection)if(this.tileCacheForProjection[e].canExpireCache())return!0;return!1}expireCache(e,t){const n=this.getTileCacheForProjection(e);this.tileCache.expireCache(this.tileCache==n?t:{});for(const i in this.tileCacheForProjection){const r=this.tileCacheForProjection[i];r.expireCache(r==n?t:{})}}getGutterForProjection(e){return this.getProjection()&&e&&!Hi(this.getProjection(),e)?0:this.getGutter()}getGutter(){return 0}getKey(){let e=super.getKey();return this.getInterpolate()||(e+=":disable-interpolation"),e}getTileGridForProjection(e){const t=this.getProjection();if(this.tileGrid&&(!t||Hi(t,e)))return this.tileGrid;const n=Ae(e);return n in this.tileGridForProjection||(this.tileGridForProjection[n]=Y0(e)),this.tileGridForProjection[n]}getTileCacheForProjection(e){const t=this.getProjection();if(!t||Hi(t,e))return this.tileCache;const n=Ae(e);return n in this.tileCacheForProjection||(this.tileCacheForProjection[n]=new _m(this.tileCache.highWaterMark)),this.tileCacheForProjection[n]}createTile_(e,t,n,i,r,s){const o=[e,t,n],a=this.getTileCoordForTileUrlFunction(o,r),l=a?this.tileUrlFunction(a,i,r):void 0,c=new this.tileClass(o,l!==void 0?Rt:nt,l!==void 0?l:"",this.crossOrigin,this.tileLoadFunction,this.tileOptions);return c.key=s,c.addEventListener(Be,this.handleTileChange.bind(this)),c}getTile(e,t,n,i,r){const s=this.getProjection();if(!s||!r||Hi(s,r))return this.getTileInternal(e,t,n,i,s||r);const o=this.getTileCacheForProjection(r),a=[e,t,n];let l;const c=Yn(a);o.containsKey(c)&&(l=o.get(c));const u=this.getKey();if(l&&l.key==u)return l;const h=this.getTileGridForProjection(s),p=this.getTileGridForProjection(r),f=this.getTileCoordForTileUrlFunction(a,r),m=new Os(s,h,r,p,a,f,this.getTilePixelRatio(i),this.getGutter(),(_,y,x,w)=>this.getTileInternal(_,y,x,w,s),this.reprojectionErrorThreshold_,this.renderReprojectionEdges_,this.tileOptions);return m.key=u,l?o.replace(c,m):o.set(c,m),m}getTileInternal(e,t,n,i,r){const s=au(e,t,n),o=this.getKey();if(!this.tileCache.containsKey(s)){const l=this.createTile_(e,t,n,i,r,o);return this.tileCache.set(s,l),l}let a=this.tileCache.get(s);return a.key!=o&&(a=this.createTile_(e,t,n,i,r,o),this.tileCache.replace(s,a)),a}setRenderReprojectionEdges(e){if(this.renderReprojectionEdges_!=e){this.renderReprojectionEdges_=e;for(const t in this.tileCacheForProjection)this.tileCacheForProjection[t].clear();this.changed()}}setTileGridForProjection(e,t){const n=He(e);if(n){const i=Ae(n);i in this.tileGridForProjection||(this.tileGridForProjection[i]=t)}}clear(){super.clear();for(const e in this.tileCacheForProjection)this.tileCacheForProjection[e].clear()}};function N1(e,t){e.getImage().src=t}let G1=class extends j1{constructor(e){const t=(e=e||{}).projection!==void 0?e.projection:"EPSG:3857",n=e.tileGrid!==void 0?e.tileGrid:Z0({extent:oh(t),maxResolution:e.maxResolution,maxZoom:e.maxZoom,minZoom:e.minZoom,tileSize:e.tileSize});super({attributions:e.attributions,cacheSize:e.cacheSize,crossOrigin:e.crossOrigin,interpolate:e.interpolate,projection:t,reprojectionErrorThreshold:e.reprojectionErrorThreshold,tileGrid:n,tileLoadFunction:e.tileLoadFunction,tilePixelRatio:e.tilePixelRatio,tileUrlFunction:e.tileUrlFunction,url:e.url,urls:e.urls,wrapX:e.wrapX===void 0||e.wrapX,transition:e.transition,attributionsCollapsible:e.attributionsCollapsible,zDirection:e.zDirection}),this.gutter_=e.gutter!==void 0?e.gutter:0}getGutter(){return this.gutter_}};const V1={class:"vg-map"},$1=["innerHTML"],q1={__name:"cb-product-map",props:{rasterUrl:{type:String,required:!0},productsExtentUrl:{type:String,required:!0},productsUrl:{type:String,required:!0},productUrl:{type:String,required:!0},poisExtentUrl:{type:String,required:!0},poisUrl:{type:String,required:!0},poiUrl:{type:String,required:!0},colors:{type:Object,default:()=>({})},minZoom:{type:Number,default:3},maxZoom:{type:Number,default:18},queryParameters:{type:Object,default:()=>({})},priceType:{type:String,default:"strike-through",validator:e=>Zf.indexOf(e)!==-1},attributions:{type:String,default:null}},emits:["update:queryParameters"],setup(e,{expose:t,emit:n}){const i=e,r=new cn({minZoom:i.minZoom,maxZoom:i.maxZoom}),s=new cm({onFocusOnly:!0}),o=new T1({view:r,interactions:fm({pinchRotate:!1,mouseWheelZoom:!1}).extend([s])}),a=new Yf({preload:1/0,source:new G1({url:i.rasterUrl,crossOrigin:"anonymous"})});o.addLayer(a);const l=n,c=le(null),u=le(null),h=le(!1),p=le(!1),f=te({get:()=>i.queryParameters,set(y){l("update:queryParameters",y)}}),m=te(()=>h.value||p.value),_=function(y){const x=Ou();return Re(y,async()=>{await x.emit("watch")},{deep:!0}),{all:Bt(y.value),get:w=>y.value[w]??"",set:(w,T)=>{y.value[w]=T},clear:()=>{for(const w of Object.keys(y.value))y.value[w]=""},sync:w=>{for(const[T,R]of Object.entries(y.value))R?w.searchParams.set(T,R):w.searchParams.delete(T)},on:(w,T)=>{x.on(w,T)}}}(f);return zn("priceType",i.priceType),zn("cb-query-parameters",_),We(()=>o.setTarget(c.value)),t({focus:()=>{c.value.focus()},fit:()=>{u.value.fit()},go:(y,x,w,T)=>{const R=function(b){return mg(),bg(b,"EPSG:4326","EPSG:3857")}([y,x]);T?r.animate({center:R,zoom:w,duration:T}):(r.setCenter(R),r.setZoom(w))}}),(y,x)=>(I(),O("div",V1,[Q(D(cb),{loading:m.value},null,8,["loading"]),S("div",{ref_key:"canvas",ref:c,tabindex:"0",class:"vg-canvas"},null,512),Q(D(pb),{map:D(o)},null,8,["map"]),(I(),ce(hp,null,{default:ye(()=>[Q(D(e1),{map:D(o),"extent-url":e.poisExtentUrl,"markers-url":e.poisUrl,"details-url":e.poiUrl,colors:e.colors,onLoading:x[0]||(x[0]=w=>h.value=w)},null,8,["map","extent-url","markers-url","details-url","colors"])]),_:1})),(I(),ce(hp,null,{default:ye(()=>[Q(D(t1),{ref_key:"productLayer",ref:u,map:D(o),"extent-url":e.productsExtentUrl,"markers-url":e.productsUrl,"details-url":e.productUrl,colors:e.colors,onLoading:x[1]||(x[1]=w=>p.value=w)},null,8,["map","extent-url","markers-url","details-url","colors"])]),_:1})),e.attributions?(I(),O("div",{key:0,class:"vg-attributions",innerHTML:e.attributions},null,8,$1)):ie("",!0)]))}},X1=un(q1,[["__scopeId","data-v-fad2822e"]]);function Ga(e,t){t===void 0&&(t={});var n=t.insertAt;if(e&&!(typeof document>"u")){var i=document.head||document.getElementsByTagName("head")[0],r=document.createElement("style");r.type="text/css",n==="top"&&i.firstChild?i.insertBefore(r,i.firstChild):i.appendChild(r),r.styleSheet?r.styleSheet.cssText=e:r.appendChild(document.createTextNode(e))}}$n(`
.vg-map[data-v-fad2822e] {
        width: 100%;
        height: 100%;
        position: relative;
}
.vg-canvas[data-v-fad2822e] {
        width: 100%;
        height: 100%;
}
.vg-attributions[data-v-fad2822e] {
        position: absolute;
        bottom: 0;
        right: 0;
        color: #333;
        background: rgba(255, 255, 255, 0.8);
        font-size: 12px;
        user-select: none;
        padding: 1px .5em;
}
`);const Va=(e,t)=>{const n=e.__vccOpts||e;for(const[i,r]of t)n[i]=r;return n},W1={__name:"cb-product-attributes",props:{attributes:{type:Array,default:()=>[]},layout:{type:String,default:"standard",validator:e=>["standard","introbox"].includes(e)}},setup(e){const t=e,n=te(()=>({"cb-attributes":t.layout==="standard","cb--attributes":t.layout==="introbox"}));return(i,r)=>{var s;return((s=e.attributes)==null?void 0:s.length)>0?(I(),O("div",{key:0,class:ve(n.value)},[S("div",null,[(I(!0),O(be,null,Qe(e.attributes,o=>(I(),O("div",{key:o.name,class:"cb-label-attr"},[S("span",{class:ve(["cb-icon-aws",o.iconClassName])},null,2),S("span",null,Z(o.name),1)]))),128))])],2)):ie("",!0)}}},_h=W1,Y1={key:0,class:"vgo-pricing"},Z1={key:0,class:"vgo-pricing__strike"},H1={class:"vgo-pricing__main"},K1={key:0,class:"vgo-pricing__definition"},Q1={__name:"cb-price-strike-through",props:{price:{type:Object,required:!0},translations:{type:Object,required:!0}},setup:e=>(t,n)=>e.price.priceAndCurrency?(I(),O("div",Y1,[e.price.originalPriceAndCurrency?(I(),O("div",Z1,Z(e.translations.priceOriginal)+" "+Z(e.price.originalPriceAndCurrency),1)):ie("",!0),S("div",H1,[S("b",{class:ve(["vgo-pricing__price",{"vgo-pricing__price--discount":e.price.originalPriceAndCurrency}])},[S("span",null,Z(e.translations.priceFrom),1),n[0]||(n[0]=je()),S("span",null,Z(e.price.priceAndCurrency),1)],2),e.price.priceDescription?(I(),O("span",K1,Z(e.price.priceDescription),1)):ie("",!0)])])):ie("",!0)},J1={key:0,class:"vgo-pricing"},ew={class:"vgo-pricing__main"},tw={class:"vgo-pricing__price"},nw={key:0,class:"vgo-pricing__definition"},iw={key:0,class:"vgo-pricing__yousave"},rw={__name:"cb-price-you-save",props:{price:{type:Object,required:!0},translations:{type:Object,required:!0}},setup:e=>(t,n)=>e.price.priceAndCurrency?(I(),O("div",J1,[S("div",ew,[S("b",tw,[S("span",null,Z(e.translations.priceFrom),1),n[0]||(n[0]=je()),S("span",null,Z(e.price.priceAndCurrency),1)]),e.price.priceDescription?(I(),O("span",nw,Z(e.price.priceDescription),1)):ie("",!0)]),e.price.youSavePriceAndCurrency?(I(),O("div",iw,Z(e.translations.discount)+" "+Z(e.price.youSavePriceAndCurrency),1)):ie("",!0)])):ie("",!0)},$a=["strike-through","you-save"],ow=e=>{switch(e){case"strike-through":return Q1;case"you-save":return rw;default:return null}},sw=["innerHTML"],aw={__name:"cb-badge",props:{type:{type:String,validator:e=>["default","discount","fewleft","cancelled","preliminary","custom"].indexOf(e)!==-1,default:"default"},value:{type:String,required:!0}},setup(e){const t=e,n=te(()=>({"cb-badge":t.type!=="custom","cb-badge--discount":t.type==="discount","cb-badge--fewleft":t.type==="fewleft","cb-badge--cancelled":t.type==="cancelled","cb-badge--preliminary":t.type==="preliminary"}));return(i,r)=>(I(),O("span",{class:ve([n.value]),innerHTML:e.value},null,10,sw))}},lw={key:0,class:"cb-badges"},cw={__name:"cb-badges",props:{badges:{type:Array,default:()=>[]}},setup:e=>(t,n)=>e.badges?(I(),O("div",lw,[(I(!0),O(be,null,Qe(e.badges,i=>(I(),ce(aw,{key:i.value,type:i.type,value:i.value},null,8,["type","value"]))),128))])):ie("",!0)},yh=Va(cw,[["__scopeId","data-v-0b07fb2a"]]);Ga(`.cb-badges[data-v-0b07fb2a] {
    position: absolute;
    top: 15px;
    left: 0;
    display: flex;
    flex-direction: column;
    row-gap: 5px;
    font-size: var(--vg-body-small-font-size);
    pointer-events: none;
    z-index: 1;
}
.cb-badges[data-v-0b07fb2a] .cb-badge-recommended > span {
        height: 70px;
        max-width: 105px;
}
@container (max-width: 500px) {
.cb-badges[data-v-0b07fb2a] .cb-badge-recommended > span {
            height: 63px;
            max-width: 94px;
}
}
@container (max-width: 500px) {
.cb-badges[data-v-0b07fb2a] .cb-badge {
            font-size: 90%;
            border-top-left-radius: 0;
            border-bottom-left-radius: 0;
}
}`);const uw={class:"cb-loader-custom",role:"status"},hw={__name:"cb-loader",props:{loading:{type:Boolean}},setup:e=>(t,n)=>yt((I(),O("i",uw,n[0]||(n[0]=[S("i",null,[S("i"),S("i"),S("i"),S("i"),S("i")],-1)]),512)),[[Ft,e.loading]])},dw=hw,pw={__name:"cb-button",props:{secondary:{type:Boolean},loading:{type:Boolean},active:{type:Boolean},disabled:{type:Boolean},iconOnly:{type:Boolean},size:{type:String,default:null,validator:e=>!e||["small","large"].indexOf(e)!==-1}},emits:["click"],setup(e,{emit:t}){const n=e,i=t,r=te(()=>({"cb-btn":!0,"cb-btn-primary":!n.secondary,"cb-btn-secondary":n.secondary,"cb-btn-sm":n.size==="small","cb-btn-lg":n.size==="large","cb-btn-icon-only":n.iconOnly,"cb-loading-custom":n.loading,"cb-active":n.active,"cb-disabled":n.disabled})),s=o=>{n.disabled||i("click",o)};return(o,a)=>(I(),O("a",{class:ve([r.value]),href:"javascript:void(0)",onClick:s},[S("span",null,[Me(o.$slots,"default")]),Q(D(dw),{loading:e.loading},null,8,["loading"])],2))}},gw=pw;function fw(e){const t=le(0),n=new Map;return{velocity:t,track:i=>{const r=Date.now();n.set(r,i),(()=>{const s=Date.now();for(const[o]of[...n])o>=s-e||n.delete(o)})(),(()=>{const s=Date.now(),o=[...n.keys()],a=[...n.values()],l=Math.min(...a),c=Math.max(...a),u=Math.abs(c-l),h=s-Math.min(...o);t.value=u/(h||1)})()},untrack:()=>{t.value=0,n.clear()}}}function mw(e,t){const o=Xe({index:0,startX:0,target:void 0,swiping:void 0,animation:void 0}),a="ontouchstart"in window,{velocity:l,track:c,untrack:u}=fw(200),h=(b,k,F)=>Math.max(k,Math.min(b,F)),p=b=>b instanceof TouchEvent?b.changedTouches[0].clientX:b.x,f=()=>m(o.index),m=b=>{o.index=b,o.target=-100*o.index,_(),R()},_=()=>{if(o.animation&&(cancelAnimationFrame(o.animation),o.animation=void 0),typeof o.target!="number")return;let b=o.target;b=+b.toFixed(2),b=(k=>h(k,-(100*t.value.length-100+20),20))(b),o.animation=requestAnimationFrame(()=>{e.value.style.transform=`translate3d(${b}%, 0, 0)`,_()})},y=(b,k)=>{b.style.left=100*k+"%",a?(b.ontouchstart=x,b.ontouchmove=w,b.ontouchend=T,b.ontouchcancel=f):(b.onpointerdown=x,b.onpointermove=w,b.onpointerup=T,b.onpointercancel=f)},x=b=>{const k=b.currentTarget,F=p(b);c(F),o.startX=F,o.target=-100*o.index,o.swiping=k,_()},w=b=>{if(!o.swiping)return;b.stopPropagation();const k=p(b);c(k);const F=(k-o.startX)/o.swiping.clientWidth*100;o.target=-1*(100*o.index-F)},T=b=>{if(!o.swiping)return;b.stopPropagation();const k=p(b);c(k);const F=k-o.startX,j=Math.abs(F),B=o.swiping.clientWidth*.5,N=F!==0?F<0?1:-1:0,Y=Math.round(j/o.swiping.clientWidth)||1,ee=(q=>h(q,0,t.value.length-1))(o.index+Y*N),ne=o.index!==ee,G=j>=B,V=l.value>=.2;m(ne&&(G||V)?ee:o.index)},R=()=>{o.startX=0,o.target=void 0,o.swiping=void 0,o.animation=void 0,u()};return Re(()=>t.value,()=>{if(!(t.value.length<=1))for(const[b,k]of t.value.entries())y(k,b)},{deep:!0}),We(()=>{a||(document.addEventListener("pointerup",T),document.addEventListener("pointermove",w))}),{state:Bt(o),set:m}}const vw={class:"vgo-gallery__wrapper"},_w=["loading","src","alt","onLoad"],yw={key:1,class:"vgo-gallery__cell-noimage"},bw=["tabindex"],xw=["tabindex"],ww={class:"vgo-gallery__pager"},Ew=["onClick"],Cw={__name:"cb-gallery",props:{images:{type:Array,default:()=>[]}},setup(e){const t=e,n=le(null),i=le([]),r=Xe({}),{state:s,set:o}=mw(n,i),a=p=>Math.max(0,Math.min(p,t.images.length-1)),l=()=>o(a(s.index+1)),c=()=>o(a(s.index-1)),u={ArrowRight:l,ArrowLeft:c,Home:()=>o(0),End:()=>o(t.images.length-1)},h=p=>{const f=u[p.key];f&&(p.preventDefault(),f())};return(p,f)=>(I(),O("div",{class:ve(["vgo-gallery",{"vgo-gallery__grabable":e.images.length>1,"vgo-gallery__grabbing":D(s).swiping}]),tabindex:"0",onKeydown:St(h,["stop","self"])},[S("div",vw,[e.images.length>0?(I(),O("div",{key:0,ref_key:"viewport",ref:n,class:"vgo-gallery__viewport"},[(I(!0),O(be,null,Qe(e.images,(m,_)=>(I(),O("div",{key:m.url,ref_for:!0,ref_key:"cells",ref:i,class:"vgo-gallery__cell"},[S("div",{class:"vgo-gallery__cell-blur",style:Ln({"background-image":r[m.url]?`url(${r[m.url]})`:"none"}),role:"img"},null,4),S("img",{loading:_===0?"eager":"lazy",src:m.url,alt:m.description,onLoad:y=>r[m.url]=m.url,onDragstart:f[0]||(f[0]=St(()=>{},["prevent"]))},null,40,_w)]))),128))],512)):(I(),O("div",yw)),e.images.length>1?(I(),O(be,{key:2},[S("a",{class:ve(["vgo-gallery__previous",{hidden:D(s).index===0}]),tabindex:D(s).index===0?-1:0,href:"javascript:void(0)",onClick:c},f[1]||(f[1]=[S("span",{class:"cb-icon-aws cb-icon-aws--strong cb--chevron-left"},null,-1)]),10,bw),S("a",{class:ve(["vgo-gallery__next",{hidden:D(s).index===e.images.length-1}]),tabindex:D(s).index===e.images.length-1?-1:0,href:"javascript:void(0)",onClick:l},f[2]||(f[2]=[S("span",{class:"cb-icon-aws cb-icon-aws--strong cb--chevron-right"},null,-1)]),10,xw),S("ol",ww,[(I(!0),O(be,null,Qe(e.images,(m,_)=>(I(),O("li",{key:m.url,class:ve({selected:D(s).index===_}),onClick:y=>D(o)(_)},null,10,Ew))),128))])],64)):ie("",!0),Me(p.$slots,"default",{index:D(s).index},void 0,!0)])],34))}},bh=Va(Cw,[["__scopeId","data-v-239321eb"]]);Ga(`.vgo-gallery[data-v-239321eb] {
    overflow: hidden;
    touch-action: pan-y;
    -webkit-tap-highlight-color: transparent;
    -webkit-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
    user-select: none;
    container-type: inline-size;
    font-family: var(--vg-body-font-family);
    font-size: var(--vg-body-font-size);
    font-weight: var(--vg-body-font-weight);
    line-height: var(--vg-body-line-height);
    letter-spacing: var(--vg-body-letter-spacing);
}
.vgo-gallery[data-v-239321eb] *, .vgo-gallery[data-v-239321eb] *:before, .vgo-gallery[data-v-239321eb] *:after {box-sizing: border-box;}
.vgo-gallery[data-v-239321eb]:focus {
        outline: none;
}
.vgo-gallery__wrapper[data-v-239321eb] {
    position: relative;
    height: 100%;
}
.vgo-gallery__wrapper[data-v-239321eb]:before {
        content: '';
        position: absolute;
        inset: 0;
        background-color: currentColor;
        opacity: .1;
}
.vgo-gallery__viewport[data-v-239321eb] {
    position: relative;
    left: 0;
    height: 100%;
    transform: translate3d(0, 0, 0);
    transition: transform 0.3s ease-out;
    will-change: transform;
}
.vgo-gallery__cell[data-v-239321eb] {
    position: absolute;
    width: 100%;
    height: 100%;
    overflow: hidden;
}
.vgo-gallery__cell img[data-v-239321eb] {
        position: absolute;
        inset: 0;
        width: 100%;
        height: 100%;
        object-fit: cover;
        transition: transform 0.3s ease-in-out;
        -webkit-touch-callout: none;
        will-change: filter;
}
.vgo-gallery__cell .vgo-gallery__cell-blur[data-v-239321eb] {
        position: absolute;
        inset: -25px;
        filter: blur(20px);
        opacity: .9;
        background-repeat: no-repeat;
        background-position: center;
        background-size: cover;
        will-change: filter;
}
.vgo-gallery__grabable[data-v-239321eb] {
    cursor: -webkit-grab;
    cursor: grab;
}
.vgo-gallery__grabbing[data-v-239321eb] {
    cursor: -webkit-grabbing;
    cursor: grabbing;
}
.vgo-gallery__grabbing .vgo-gallery__viewport[data-v-239321eb] {
    transition: none !important;
}
.vgo-gallery__grabbing .vgo-gallery__cell img[data-v-239321eb] {
    transform: scale3d(0.95, 0.95, 1);
}
.vgo-gallery__cell .cb-image[data-v-239321eb] {
    background-repeat: no-repeat;
    background-position: center;
}
.vgo-gallery__cell-noimage[data-v-239321eb] {
    position: absolute;
    left: 50%;
    top: 50%;
    width: 100%;
    height: 100%;
    max-width: 30%;
    max-height: 30%;
    transform: translate(-50%, -50%);
    -webkit-mask-image: var(--vg-noimage-background);
    mask-image: var(--vg-noimage-background);
    mask-repeat: no-repeat;
    -webkit-mask-repeat: no-repeat;
    mask-position: center;
    -webkit-mask-position: center;
    mask-size: contain;
    -webkit-mask-size: contain;
    background-color: currentColor;
    opacity: .2;
}
.vgo-gallery__previous[data-v-239321eb],
.vgo-gallery__next[data-v-239321eb] {
    position: absolute;
    top: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 30px;
    height: 30px;
    margin-top: -15px;
    user-select: none;
    color: #222;
    background-color: #fff;
    transition: opacity 0.2s ease-out;
    text-decoration: none;
    opacity: 0;
    border-radius: 50%;
    font-size: 16px;
    text-decoration: none !important;
}
.vgo-gallery__grabbing .vgo-gallery__previous[data-v-239321eb],
.vgo-gallery__grabbing .vgo-gallery__next[data-v-239321eb],
.vgo-gallery__grabbing .vgo-gallery__pager li[data-v-239321eb] {
    pointer: none;
}
.vgo-gallery__previous[data-v-239321eb] {
    left: 15px;
}
.vgo-gallery__next[data-v-239321eb] {
    right: 15px;
}
.vgo-gallery:hover .vgo-gallery__previous[data-v-239321eb],
.vgo-gallery:hover .vgo-gallery__next[data-v-239321eb] {
    opacity: .7;
}
.vgo-gallery .vgo-gallery__previous[data-v-239321eb]:hover,
.vgo-gallery .vgo-gallery__next[data-v-239321eb]:hover {
    opacity: 1;
    box-shadow: 0 0 0 1px #fff, 0 0 5px rgba(0,0,0,.2);
    transition: opacity 0.1s ease-out;
}
.vgo-gallery .vgo-gallery__previous.hidden[data-v-239321eb],
.vgo-gallery .vgo-gallery__next.hidden[data-v-239321eb] {
    opacity: 0;
    pointer-events: none;
}
.vgo-gallery__pager[data-v-239321eb] {
    position: absolute;
    bottom: 10px;
    width: 100%;
    padding: 0;
    list-style: none;
    text-align: center;
    pointer-events: none;
    display: flex;
    justify-content: center;
    margin: 0;
}
.vgo-gallery__pager li[data-v-239321eb] {
    padding: 5px 3px;
    pointer-events: initial;
    cursor: pointer;
}
.vgo-gallery__pager li[data-v-239321eb]:before {
    content: '';
    display: block;
    width: 10px;
    height: 10px;
    opacity: 1;
    background: transparent;
    border: 2px solid white;
    border-radius: 50%;
    transition: border-width .1s;
}
.vgo-gallery__pager li[data-v-239321eb]:hover:before,
.vgo-gallery__pager li.selected[data-v-239321eb]:before {
    border-width: 5px;
}`);const Aw={__name:"cb-price",props:{price:{type:Object,default:()=>({})},type:{type:String,default:"strike-through",validator:e=>$a.indexOf(e)!==-1},translations:{type:Object,required:!0}},setup:e=>(t,n)=>(I(),ce(ai(D(ow)(e.type)),{price:e.price,translations:e.translations},null,8,["price","translations"]))},Sw=Va(Aw,[["__scopeId","data-v-8914bfd6"]]);Ga(`[data-v-8914bfd6] .vgo-pricing__main {
    display: flex;
    flex-wrap: wrap;
    column-gap: .35em;
    align-items: baseline;
}
[data-v-8914bfd6] .vgo-pricing__strike {
    text-decoration: line-through;
    opacity: var(--vg-text-muted-opacity);
    font-size: var(--vg-body-small-font-size);
    line-height: var(--vg-body-small-line-height);
}
[data-v-8914bfd6] .vgo-pricing__price--discount {
    color: var(--vg-text-discount);
}
[data-v-8914bfd6] .vgo-pricing__definition {
    opacity: var(--vg-text-muted-opacity);
}
[data-v-8914bfd6] .vgo-pricing__yousave {
    color: var(--vg-text-discount);
    font-size: var(--vg-body-small-font-size);
    line-height: var(--vg-body-small-line-height);
}`);const ei=(e,t)=>{const n=e.__vccOpts||e;for(const[i,r]of t)n[i]=r;return n};function yo(e,t){t===void 0&&(t={});var n=t.insertAt;if(e&&typeof document<"u"){var i=document.head||document.getElementsByTagName("head")[0],r=document.createElement("style");r.type="text/css",n==="top"&&i.firstChild?i.insertBefore(r,i.firstChild):i.appendChild(r),r.styleSheet?r.styleSheet.cssText=e:r.appendChild(document.createTextNode(e))}}const Tw={__name:"cb-score-rating",props:{rating:{type:Number,required:!0}},setup(e){const t=e,n=te(()=>{const i=10*Math.round(t.rating/10);return`cb-score-rating cb--${Math.max(0,Math.min(100,i))}`});return(i,r)=>(I(),O("span",{class:ve(n.value),innerHTML:"<span><i></i></span> "},null,2))}},xh=Va(Tw,[["__scopeId","data-v-80486437"]]);Ga(`
@keyframes cb-score-rating-80486437 {
0%, 50% {
            width: 0;
            opacity: 0;
}
}
.cb-score-rating[data-v-80486437] {
        position: relative;
        display: inline-block;
        width: 64px;
}
.cb-score-rating[data-v-80486437]  span,
            .cb-score-rating[data-v-80486437]  i,
            .cb-score-rating[data-v-80486437]  span::before,
            .cb-score-rating[data-v-80486437]  span:after {
                position: absolute;
                width: 100%;
                mask-repeat: repeat-x;
                -webkit-mask-repeat: repeat-x;
                mask-position: left;
                -webkit-mask-position: left;
                mask-size: contain;
                -webkit-mask-size: contain;
}
.cb-score-rating[data-v-80486437]  span {
                display: block;
                padding-top: 18.75%;
                top: 50%;
                transform: translateY(-50%);
}
.cb-score-rating[data-v-80486437]  span i,
                .cb-score-rating[data-v-80486437]  span::before,
                .cb-score-rating[data-v-80486437]  span::after {
                    content: '';
                    position: absolute;
                    top: 0;
                    bottom: 0;
                    left: 0;
}
.cb-score-rating[data-v-80486437]  span i {
                    -webkit-mask-image: var(--vg-score-rating-fill-backdrop);
                    mask-image: var(--vg-score-rating-fill-backdrop);
                    background-color: currentColor;
                    opacity: .1;
}
.cb-score-rating[data-v-80486437]  span::before {
                    -webkit-mask-image: var(--vg-score-rating-fill);
                    mask-image: var(--vg-score-rating-fill);
                    background-color: var(--vg-score-rating-fill-color);
                    animation: cb-score-rating-80486437 .4s ease-out forwards;
                    opacity: 1;
}
.cb-score-rating[data-v-80486437]  span::after {
                    -webkit-mask-image: var(--vg-score-rating-fill-overlay);
                    mask-image: var(--vg-score-rating-fill-overlay);
                    background-color: var(--vg-score-rating-fill-overlay-color);
                    animation: cb-score-rating-80486437 .4s ease-out forwards;
                    opacity: 1;
}
.cb-score-rating.cb--10[data-v-80486437]  span::before {
                    width: 11%;
}
.cb-score-rating.cb--10[data-v-80486437]  span::after {
                    width: 11%;
}
.cb-score-rating.cb--20[data-v-80486437]  span::before {
                    width: 20%;
}
.cb-score-rating.cb--20[data-v-80486437]  span::after {
                    width: 20%;
}
.cb-score-rating.cb--30[data-v-80486437]  span::before {
                    width: 31%;
}
.cb-score-rating.cb--30[data-v-80486437]  span::after {
                    width: 31%;
}
.cb-score-rating.cb--40[data-v-80486437]  span::before {
                    width: 40%;
}
.cb-score-rating.cb--40[data-v-80486437]  span::after {
                    width: 40%;
}
.cb-score-rating.cb--50[data-v-80486437]  span::before {
                    width: 51%;
}
.cb-score-rating.cb--50[data-v-80486437]  span::after {
                    width: 51%;
}
.cb-score-rating.cb--60[data-v-80486437]  span::before {
                    width: 60%;
}
.cb-score-rating.cb--60[data-v-80486437]  span::after {
                    width: 60%;
}
.cb-score-rating.cb--70[data-v-80486437]  span::before {
                    width: 71%;
}
.cb-score-rating.cb--70[data-v-80486437]  span::after {
                    width: 71%;
}
.cb-score-rating.cb--80[data-v-80486437]  span::before {
                    width: 80%;
}
.cb-score-rating.cb--80[data-v-80486437]  span::after {
                    width: 80%;
}
.cb-score-rating.cb--90[data-v-80486437]  span::before {
                    width: 91%;
}
.cb-score-rating.cb--90[data-v-80486437]  span::after {
                    width: 91%;
}
.cb-score-rating.cb--100[data-v-80486437]  span::before {
                    width: 100%;
}
.cb-score-rating.cb--100[data-v-80486437]  span::after {
                    width: 100%;
}
`);const Rw={url:"",baseURI:document.baseURI,pageSize:10,maxConsecutiveRequests:2,unknownItems:3},ym={page:0,totalResults:0,isLoading:!1,hasLoaded:!1,error:!1,items:[],pendingRequests:[]},kw={credentials:"include",headers:{"Content-Type":"application/json"}};function Pw(e,t){const n={...Rw,...e},i=Xe(structuredClone(ym)),r=function(u){const h={active:0,queue:[]},p=async()=>{if(h.queue.length===0||h.active>=u)return;const f=h.queue.shift();f&&(h.active++,f.call(...f.args).then(m=>f.resolve(m)).catch(m=>f.error(m)).finally(()=>{h.active--,p()}))};return{enqueue:async(f,...m)=>new Promise((_,y)=>{h.queue.push({call:f,resolve:_,error:y,args:m}),p()}),purge:async()=>{for(const f of h.queue)f.error("The queue was purged.");h.active=0,h.queue=[]}}}(n.maxConsecutiveRequests),s=u=>!i.hasLoaded||u<=Math.ceil(i.totalResults/n.pageSize),o=async(u,h)=>{if(s(u)){const p=(m=>{const _=new URL(n.url,n.baseURI);return _.searchParams.set("page",m.toString()),_.searchParams.set("pageSize",n.pageSize.toString()),t==null||t.sync(_),_.href})(u),f={...kw,signal:h.signal,method:"GET"};await fetch(p,f).then(m=>m.json()).then(m=>a(m)).catch(m=>{m instanceof Error&&m.name==="AbortError"||(i.error=!0)})}h.signal.aborted||(i.hasLoaded=!0,i.pendingRequests.splice(i.pendingRequests.indexOf(h),1),i.isLoading=i.pendingRequests.length>0,((p,f)=>{const m=i.items.filter((_,y)=>_.isLoading&&y>=f).slice(0,p);for(const _ of m)i.items.splice(i.items.indexOf(_),1)})(i.items.length-i.totalResults,i.totalResults))},a=u=>{i.totalResults=u.totalResults;const h=u.page*n.pageSize-n.pageSize;for(const[p]of u.items.entries()){const f=h+p;i.items[f]=u.items[p]}},l=async()=>{if(!s(i.page+1))return;const u=++i.page;i.isLoading=!0,(()=>{const p=i.hasLoaded?Math.min(n.pageSize,i.totalResults-i.items.length):n.unknownItems;i.items.push(...[...Array(p)].map(()=>({isLoading:!0})))})();const h=new AbortController;i.pendingRequests.push(h),await r.enqueue(o,u,h)},c=async()=>{r.purge();for(const u of i.pendingRequests)u.abort();Object.assign(i,structuredClone(ym)),await l()};return t==null||t.on("watch",c),{state:Bt(i),fetchNextPage:l,reset:c}}function wh(e,t){t===void 0&&(t={});var n=t.insertAt;if(e&&!(typeof document>"u")){var i=document.head||document.getElementsByTagName("head")[0],r=document.createElement("style");r.type="text/css",n==="top"&&i.firstChild?i.insertBefore(r,i.firstChild):i.appendChild(r),r.styleSheet?r.styleSheet.cssText=e:r.appendChild(document.createTextNode(e))}}const Iw={url:""},Mw={isLoading:!1,hasLoaded:!1,filters:[],pendingRequest:null},Lw={credentials:"include",headers:{"Content-Type":"application/json"}},Fw={url:"",baseURI:document.baseURI},Ow={isLoading:!1,pendingRequest:null,requests:new Map},Dw={credentials:"include",headers:{"Content-Type":"application/json"}};function Uw(e,t){const n={...Fw,...e},i=Xe(structuredClone(Ow));return{state:Bt(i),get:async r=>{const s=(l=>{const c=new URL(n.url,n.baseURI);return t.sync(c),l?c.searchParams.set("filter",l):c.searchParams.delete("filter"),c.href})(r);if(i.requests.has(s))return await i.requests.get(s);i.pendingRequest&&i.pendingRequest.abort(),i.isLoading=!0,i.pendingRequest=new AbortController;const o={...Dw,signal:i.pendingRequest.signal,method:"GET"},a=fetch(s,o).then(l=>l.json()).then(l=>(i.pendingRequest=null,i.isLoading=!1,l)).catch(l=>{if(i.requests.delete(s),!(l instanceof Error&&l.name==="AbortError"))throw l});return i.requests.set(s,a),await a}}}const Bw=["disabled"],zw={__name:"cb-checkbox",props:{modelValue:{type:[String,Boolean],required:!0,validator:e=>["true","false","indeterminate",!0,!1].includes(e)},outline:{type:Boolean},disabled:{type:Boolean}},emits:["update:modelValue"],setup(e,{emit:t}){const n=e,i=t,r=Nd(),s=`cb-checkbox-${Nt().uid}`,o=te(()=>!!r.default),a=te(()=>n.modelValue==="indeterminate"),l=te({get:()=>!!n.modelValue,set(c){i("update:modelValue",c)}});return(c,u)=>(I(),O("label",{class:ve(["cb-custom-control","cb-custom-check",{"cb-custom-control-outline":e.outline}]),for:s,onClick:u[1]||(u[1]=St(()=>{},["stop"]))},[yt(S("input",{id:s,"onUpdate:modelValue":u[0]||(u[0]=h=>l.value=h),type:"checkbox",disabled:e.disabled},null,8,Bw),[[Vp,l.value]]),S("span",null,[S("span",{class:ve(["cb-indicator",{"cb-indeterminate":a.value}])},null,2),S("span",{class:ve({"cb-text":o.value})},[Me(c.$slots,"default")],2)]),Me(c.$slots,"extra")],2))}},bm=zw,jw={style:{display:"grid","grid-template-columns":"repeat(auto-fill,minmax(250px,1fr))","grid-row-gap":"10px","column-gap":"20px"}},Nw={key:0,class:"cb-text-extra cb-text-small cb-text-muted"},Gw={__name:"cb-filter-checkbox",props:{modelValue:{type:String,required:!0},context:{type:Object,required:!0},expand:{type:Number,default:4}},emits:["update:modelValue"],setup(e,{emit:t}){const n=e,i=t,r=Nt(),s=le(!1),o=te(()=>{const h=n.modelValue.split(Dt.values),p=n.context.options.map(f=>[f.value,h.includes(f.value)]);return Object.fromEntries(p)}),a=te(()=>Object.values(o.value).filter(Boolean).length>0),l=te(()=>{const h=s.value?"List.Filters.Collapse":"List.Filters.Expand";return r.proxy.$t(h)}),c=te(()=>s.value?"cb-icon-css--up":"cb-icon-css--down"),u=()=>{const h=Object.keys(o.value).filter(p=>o.value[p]).join(Dt.values);i("update:modelValue",h)};return Re(a,h=>s.value=h||s.value,{immediate:!0}),(h,p)=>(I(),O(be,null,[S("div",jw,[(I(!0),O(be,null,Qe(e.context.options,(f,m)=>yt((I(),ce(D(bm),{key:f.value,modelValue:o.value[f.value],"onUpdate:modelValue":[_=>o.value[f.value]=_,u],class:"cb-fade-in-down","aria-label":f.name},{default:ye(()=>[S("b",null,Z(f.name),1)]),extra:ye(()=>[f.description?(I(),O("span",Nw,Z(f.description),1)):ie("",!0)]),_:2},1032,["modelValue","onUpdate:modelValue","aria-label"])),[[Ft,s.value||m<e.expand||a.value]])),128))]),e.context.options.length>e.expand&&!a.value?(I(),O("a",{key:0,href:"javascript:void(0);",class:"cb-more cb-text-icon",onClick:p[0]||(p[0]=f=>s.value=!s.value)},[S("b",null,Z(l.value),1),S("span",{class:ve(["cb-icon-css cb-icon-css--sm",c.value])},p[1]||(p[1]=[S("span",null,null,-1),je(" ")]),2)])):ie("",!0)],64))}},Vw=["aria-label"],$w={key:0,class:"cb-text-extra cb-text-small cb-text-muted"},qw={key:0},xm={__name:"cb-filter-checkbox-tree-node",props:{state:{type:Object,required:!0},option:{type:Object,required:!0},parent:{type:Object,default:null}},emits:["changed"],setup(e,{emit:t}){const n=e,i=t,r=le(!1),s=te({get:()=>n.state.get(n.option.value).selected,set(a){i("changed",n.option.value,a)}}),o=(a,l)=>{i("changed",a,l)};return(a,l)=>{var c,u;return I(),O(be,null,[S("div",{class:ve(["cb-tree cb-fade-in-down",{"cb--open":r.value}])},[((c=e.option.options)==null?void 0:c.length)>0?(I(),O("a",{key:0,href:"javascript:void(0);","aria-label":a.$t("List.FiltersDropdown"),onClick:l[0]||(l[0]=h=>r.value=!r.value)},l[2]||(l[2]=[S("span",{class:"cb-icon-css cb-icon-css--down"},[S("span"),je(" ")],-1)]),8,Vw)):ie("",!0),Q(D(bm),{modelValue:s.value,"onUpdate:modelValue":l[1]||(l[1]=h=>s.value=h),"aria-label":e.option.name},{default:ye(()=>[S("b",null,Z(e.option.name),1)]),extra:ye(()=>[e.option.description?(I(),O("span",$w,Z(e.option.description),1)):ie("",!0)]),_:1},8,["modelValue","aria-label"])],2),((u=e.option.options)==null?void 0:u.length)>0?yt((I(),O("ul",qw,[(I(!0),O(be,null,Qe(e.option.options,h=>(I(),O("li",{key:h.value},[Q(xm,{state:e.state,option:h,parent:e.option,onChanged:o},null,8,["state","option","parent"])]))),128))],512)),[[Ft,r.value]]):ie("",!0)],64)}}},Xw={class:"cb-filter-tree"},Ww={__name:"cb-filter-checkbox-tree",props:{modelValue:{type:String,required:!0},context:{type:Object,required:!0},expand:{type:Number,default:4}},emits:["update:modelValue"],setup(e,{emit:t}){const n=e,i=t,r=Nt(),s=le(!1),o=Xe(new Map),a=te(()=>Array.from(o.values()).filter(f=>f.selected).length>0),l=te(()=>{const f=s.value?"List.Filters.Collapse":"List.Filters.Expand";return r.proxy.$t(f)}),c=te(()=>s.value?"cb-icon-css--up":"cb-icon-css--down"),u=(f,m,_,y)=>!!(f.includes(m)||_.some(x=>f.includes(x))||y.length>0&&y.every(x=>f.includes(x)))||!!y.some(x=>f.includes(x))&&"indeterminate",h=(f,m,_)=>{const y=m.options||[],x=(_==null?void 0:_.map(b=>b.value))||[],w=b=>b==null?void 0:b.flatMap(({options:k,...F})=>[F,...w(k||[])]),T=y.flatMap(({options:b,...k})=>[k,...w(b||[])]).map(b=>b.value),R=u(f,m.value,x,T);o.set(m.value,{selected:R,parents:x,children:T});for(const b of y)h(f,b,[..._,m])},p=(f,m)=>{const _=o.get(f);_.selected=m;for(const R of _.children)o.get(R).selected=m;for(const R of Array.from(_.parents).reverse()){const b=o.get(R),k=b.children.map(B=>o.get(B)),F=k.every(B=>B.selected===!0),j=k.every(B=>B.selected===!1);b.selected=!(!m||!F)||!(!m&&j)&&"indeterminate"}const y=[...o].filter(([,R])=>R.selected===!0),x=y.map(([R])=>R),w=y.flatMap(([,R])=>R.children),T=x.filter(R=>!w.includes(R)).join(Dt.values);i("update:modelValue",T)};return Re(()=>n.modelValue,()=>{const f=n.modelValue.split(Dt.values);for(const[m,_]of o)_.selected=u(f,m,_.parents,_.children)}),Re(()=>n.context,()=>{o.clear();const f=n.modelValue.split(Dt.values);for(const m of n.context.options)h(f,m,[])},{deep:!0,immediate:!0}),Re(a,f=>s.value=f||s.value,{immediate:!0}),(f,m)=>(I(),O(be,null,[S("div",Xw,[S("ul",null,[(I(!0),O(be,null,Qe(e.context.options,(_,y)=>yt((I(),O("li",{key:_.value},[Q(xm,{state:o,option:_,onChanged:p},null,8,["state","option"])])),[[Ft,s.value||y<e.expand||a.value]])),128))])]),e.context.options.length>e.expand&&!a.value?(I(),O("a",{key:0,href:"javascript:void(0);",class:"cb-more cb-text-icon",onClick:m[0]||(m[0]=_=>s.value=!s.value)},[S("b",null,Z(l.value),1),S("span",{class:ve(["cb-icon-css cb-icon-css--sm",c.value])},m[1]||(m[1]=[S("span",null,null,-1),je(" ")]),2)])):ie("",!0)],64))}},Dt={key:";",value:"=",values:","},wm=e=>{switch(e){case"checkbox":return Gw;case"checkbox-tree":return Ww;default:return null}},Em=e=>{const t=e.split(Dt.key).reduce((i,r)=>{const[s,o]=r.split(Dt.value);return s&&o&&(i[s]=o),i},{}),n=Object.entries(t);return new Map(n)},Eh=e=>Array.from(e).filter(([t,n])=>t&&n).map(([t,n])=>`${t}${Dt.value}${n}`).sort().join(Dt.key),Yw={class:"cb-loader-custom",role:"status"},Zw={__name:"cb-loader",props:{loading:{type:Boolean}},setup:e=>(t,n)=>yt((I(),O("i",Yw,n[0]||(n[0]=[S("i",null,[S("i"),S("i"),S("i"),S("i"),S("i")],-1)]),512)),[[Ft,e.loading]])},Hw=Zw,Kw={__name:"cb-button",props:{secondary:{type:Boolean},loading:{type:Boolean},active:{type:Boolean},disabled:{type:Boolean},iconOnly:{type:Boolean},size:{type:String,default:null,validator:e=>!e||["small","large"].indexOf(e)!==-1}},emits:["click"],setup(e,{emit:t}){const n=e,i=t,r=te(()=>({"cb-btn":!0,"cb-btn-primary":!n.secondary,"cb-btn-secondary":n.secondary,"cb-btn-sm":n.size==="small","cb-btn-lg":n.size==="large","cb-btn-icon-only":n.iconOnly,"cb-loading-custom":n.loading,"cb-active":n.active,"cb-disabled":n.disabled})),s=o=>{n.disabled||i("click",o)};return(o,a)=>(I(),O("a",{class:ve([r.value]),href:"javascript:void(0)",onClick:s},[S("span",null,[Me(o.$slots,"default")]),Q(D(Hw),{loading:e.loading},null,8,["loading"])],2))}},dr=Kw;function bo(e,t){t===void 0&&(t={});var n=t.insertAt;if(e&&!(typeof document>"u")){var i=document.head||document.getElementsByTagName("head")[0],r=document.createElement("style");r.type="text/css",n==="top"&&i.firstChild?i.insertBefore(r,i.firstChild):i.appendChild(r),r.styleSheet?r.styleSheet.cssText=e:r.appendChild(document.createTextNode(e))}}const xo=(e,t)=>{const n=e.__vccOpts||e;for(const[i,r]of t)n[i]=r;return n},Qw={__name:"cb-dialog",props:{modelValue:{type:Boolean,default:!1},locked:{type:Boolean,default:!1},delay:{type:Number,default:0}},emits:["update:modelValue","blocked","closed"],setup(e,{emit:t}){const n=e,i=t;let r;const s=le(null),o=te({get:()=>n.modelValue,set:h=>i("update:modelValue",h)}),a=h=>{h.target===s.value&&l()},l=()=>{if(n.locked)return o.value=!0,void i("blocked");o.value=!1,s.value.classList.add("cb-dialog--leave"),s.value.classList.remove("cb-dialog--enter"),u(()=>{var h,p;(h=s.value)==null||h.classList.remove("cb-dialog--leave"),(p=s.value)==null||p.close(),i("closed")})},c=h=>{h.preventDefault(),l()},u=h=>{clearTimeout(r),r=setTimeout(h,n.delay)};return Re(()=>n.modelValue,h=>h?(o.value=!0,s.value.showModal(),s.value.classList.add("cb-dialog--enter"),s.value.classList.remove("cb-dialog--leave"),void u(()=>{s.value.classList.remove("cb-dialog--enter")})):l()),We(()=>{(()=>{if(document.querySelector("style[cb-dialog]"))return;const h=document.getElementsByTagName("head")[0],p=document.createElement("style");p.setAttribute("cb-dialog","");const f=window.innerWidth-document.documentElement.clientWidth;p.innerHTML=`
            :root {
                --vg-scrollbar-width: ${f}px;
            }
        `,h.appendChild(p)})(),o.value&&s.value.showModal()}),(h,p)=>(I(),O("dialog",{ref_key:"dialog",ref:s,class:"cb-framework cb-dialog",onClick:St(a,["self","stop"]),onCancel:c},[Me(h.$slots,"default")],544))}},Jw=Qw;function e2(e){const t=le(0),n=new Map;return{velocity:t,track:i=>{const r=Date.now();n.set(r,i),(()=>{const s=Date.now();for(const[o]of[...n])o>=s-e||n.delete(o)})(),(()=>{const s=Date.now(),o=[...n.keys()],a=[...n.values()],l=Math.min(...a),c=Math.max(...a),u=Math.abs(c-l),h=s-Math.min(...o);t.value=u/(h||1)})()},untrack:()=>{t.value=0,n.clear()}}}function t2(e,t){const o=Xe({index:0,startX:0,target:void 0,swiping:void 0,animation:void 0}),a="ontouchstart"in window,{velocity:l,track:c,untrack:u}=e2(200),h=(b,k,F)=>Math.max(k,Math.min(b,F)),p=b=>b instanceof TouchEvent?b.changedTouches[0].clientX:b.x,f=()=>m(o.index),m=b=>{o.index=b,o.target=-100*o.index,_(),R()},_=()=>{if(o.animation&&(cancelAnimationFrame(o.animation),o.animation=void 0),typeof o.target!="number")return;let b=o.target;b=+b.toFixed(2),b=(k=>h(k,-(100*t.value.length-100+20),20))(b),o.animation=requestAnimationFrame(()=>{e.value.style.transform=`translate3d(${b}%, 0, 0)`,_()})},y=(b,k)=>{b.style.left=100*k+"%",a?(b.ontouchstart=x,b.ontouchmove=w,b.ontouchend=T,b.ontouchcancel=f):(b.onpointerdown=x,b.onpointermove=w,b.onpointerup=T,b.onpointercancel=f)},x=b=>{const k=b.currentTarget,F=p(b);c(F),o.startX=F,o.target=-100*o.index,o.swiping=k,_()},w=b=>{if(!o.swiping)return;b.stopPropagation();const k=p(b);c(k);const F=(k-o.startX)/o.swiping.clientWidth*100;o.target=-1*(100*o.index-F)},T=b=>{if(!o.swiping)return;b.stopPropagation();const k=p(b);c(k);const F=k-o.startX,j=Math.abs(F),B=o.swiping.clientWidth*.5,N=F!==0?F<0?1:-1:0,Y=Math.round(j/o.swiping.clientWidth)||1,ee=(q=>h(q,0,t.value.length-1))(o.index+Y*N),ne=o.index!==ee,G=j>=B,V=l.value>=.2;m(ne&&(G||V)?ee:o.index)},R=()=>{o.startX=0,o.target=void 0,o.swiping=void 0,o.animation=void 0,u()};return Re(()=>t.value,()=>{if(!(t.value.length<=1))for(const[b,k]of t.value.entries())y(k,b)},{deep:!0}),We(()=>{a||(document.addEventListener("pointerup",T),document.addEventListener("pointermove",w))}),{state:Bt(o),set:m}}const n2={class:"vgo-gallery__wrapper"},i2=["loading","src","alt","onLoad"],r2={key:1,class:"vgo-gallery__cell-noimage"},o2=["tabindex"],s2=["tabindex"],a2={class:"vgo-gallery__pager"},l2=["onClick"],c2={__name:"cb-gallery",props:{images:{type:Array,default:()=>[]}},setup(e){const t=e,n=le(null),i=le([]),r=Xe({}),{state:s,set:o}=t2(n,i),a=p=>Math.max(0,Math.min(p,t.images.length-1)),l=()=>o(a(s.index+1)),c=()=>o(a(s.index-1)),u={ArrowRight:l,ArrowLeft:c,Home:()=>o(0),End:()=>o(t.images.length-1)},h=p=>{const f=u[p.key];f&&(p.preventDefault(),f())};return(p,f)=>(I(),O("div",{class:ve(["vgo-gallery",{"vgo-gallery__grabable":e.images.length>1,"vgo-gallery__grabbing":D(s).swiping}]),tabindex:"0",onKeydown:St(h,["stop","self"])},[S("div",n2,[e.images.length>0?(I(),O("div",{key:0,ref_key:"viewport",ref:n,class:"vgo-gallery__viewport"},[(I(!0),O(be,null,Qe(e.images,(m,_)=>(I(),O("div",{key:m.url,ref_for:!0,ref_key:"cells",ref:i,class:"vgo-gallery__cell"},[S("div",{class:"vgo-gallery__cell-blur",style:Ln({"background-image":r[m.url]?`url(${r[m.url]})`:"none"}),role:"img"},null,4),S("img",{loading:_===0?"eager":"lazy",src:m.url,alt:m.description,onLoad:y=>r[m.url]=m.url,onDragstart:f[0]||(f[0]=St(()=>{},["prevent"]))},null,40,i2)]))),128))],512)):(I(),O("div",r2)),e.images.length>1?(I(),O(be,{key:2},[S("a",{class:ve(["vgo-gallery__previous",{hidden:D(s).index===0}]),tabindex:D(s).index===0?-1:0,href:"javascript:void(0)",onClick:c},f[1]||(f[1]=[S("span",{class:"cb-icon-aws cb-icon-aws--strong cb--chevron-left"},null,-1)]),10,o2),S("a",{class:ve(["vgo-gallery__next",{hidden:D(s).index===e.images.length-1}]),tabindex:D(s).index===e.images.length-1?-1:0,href:"javascript:void(0)",onClick:l},f[2]||(f[2]=[S("span",{class:"cb-icon-aws cb-icon-aws--strong cb--chevron-right"},null,-1)]),10,s2),S("ol",a2,[(I(!0),O(be,null,Qe(e.images,(m,_)=>(I(),O("li",{key:m.url,class:ve({selected:D(s).index===_}),onClick:y=>D(o)(_)},null,10,l2))),128))])],64)):ie("",!0),Me(p.$slots,"default",{index:D(s).index},void 0,!0)])],34))}},u2=xo(c2,[["__scopeId","data-v-239321eb"]]);bo(`.vgo-gallery[data-v-239321eb] {
    overflow: hidden;
    touch-action: pan-y;
    -webkit-tap-highlight-color: transparent;
    -webkit-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
    user-select: none;
    container-type: inline-size;
    font-family: var(--vg-body-font-family);
    font-size: var(--vg-body-font-size);
    font-weight: var(--vg-body-font-weight);
    line-height: var(--vg-body-line-height);
    letter-spacing: var(--vg-body-letter-spacing);
}
.vgo-gallery[data-v-239321eb] *, .vgo-gallery[data-v-239321eb] *:before, .vgo-gallery[data-v-239321eb] *:after {box-sizing: border-box;}
.vgo-gallery[data-v-239321eb]:focus {
        outline: none;
}
.vgo-gallery__wrapper[data-v-239321eb] {
    position: relative;
    height: 100%;
}
.vgo-gallery__wrapper[data-v-239321eb]:before {
        content: '';
        position: absolute;
        inset: 0;
        background-color: currentColor;
        opacity: .1;
}
.vgo-gallery__viewport[data-v-239321eb] {
    position: relative;
    left: 0;
    height: 100%;
    transform: translate3d(0, 0, 0);
    transition: transform 0.3s ease-out;
    will-change: transform;
}
.vgo-gallery__cell[data-v-239321eb] {
    position: absolute;
    width: 100%;
    height: 100%;
    overflow: hidden;
}
.vgo-gallery__cell img[data-v-239321eb] {
        position: absolute;
        inset: 0;
        width: 100%;
        height: 100%;
        object-fit: cover;
        transition: transform 0.3s ease-in-out;
        -webkit-touch-callout: none;
        will-change: filter;
}
.vgo-gallery__cell .vgo-gallery__cell-blur[data-v-239321eb] {
        position: absolute;
        inset: -25px;
        filter: blur(20px);
        opacity: .9;
        background-repeat: no-repeat;
        background-position: center;
        background-size: cover;
        will-change: filter;
}
.vgo-gallery__grabable[data-v-239321eb] {
    cursor: -webkit-grab;
    cursor: grab;
}
.vgo-gallery__grabbing[data-v-239321eb] {
    cursor: -webkit-grabbing;
    cursor: grabbing;
}
.vgo-gallery__grabbing .vgo-gallery__viewport[data-v-239321eb] {
    transition: none !important;
}
.vgo-gallery__grabbing .vgo-gallery__cell img[data-v-239321eb] {
    transform: scale3d(0.95, 0.95, 1);
}
.vgo-gallery__cell .cb-image[data-v-239321eb] {
    background-repeat: no-repeat;
    background-position: center;
}
.vgo-gallery__cell-noimage[data-v-239321eb] {
    position: absolute;
    left: 50%;
    top: 50%;
    width: 100%;
    height: 100%;
    max-width: 30%;
    max-height: 30%;
    transform: translate(-50%, -50%);
    -webkit-mask-image: var(--vg-noimage-background);
    mask-image: var(--vg-noimage-background);
    mask-repeat: no-repeat;
    -webkit-mask-repeat: no-repeat;
    mask-position: center;
    -webkit-mask-position: center;
    mask-size: contain;
    -webkit-mask-size: contain;
    background-color: currentColor;
    opacity: .2;
}
.vgo-gallery__previous[data-v-239321eb],
.vgo-gallery__next[data-v-239321eb] {
    position: absolute;
    top: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 30px;
    height: 30px;
    margin-top: -15px;
    user-select: none;
    color: #222;
    background-color: #fff;
    transition: opacity 0.2s ease-out;
    text-decoration: none;
    opacity: 0;
    border-radius: 50%;
    font-size: 16px;
    text-decoration: none !important;
}
.vgo-gallery__grabbing .vgo-gallery__previous[data-v-239321eb],
.vgo-gallery__grabbing .vgo-gallery__next[data-v-239321eb],
.vgo-gallery__grabbing .vgo-gallery__pager li[data-v-239321eb] {
    pointer: none;
}
.vgo-gallery__previous[data-v-239321eb] {
    left: 15px;
}
.vgo-gallery__next[data-v-239321eb] {
    right: 15px;
}
.vgo-gallery:hover .vgo-gallery__previous[data-v-239321eb],
.vgo-gallery:hover .vgo-gallery__next[data-v-239321eb] {
    opacity: .7;
}
.vgo-gallery .vgo-gallery__previous[data-v-239321eb]:hover,
.vgo-gallery .vgo-gallery__next[data-v-239321eb]:hover {
    opacity: 1;
    box-shadow: 0 0 0 1px #fff, 0 0 5px rgba(0,0,0,.2);
    transition: opacity 0.1s ease-out;
}
.vgo-gallery .vgo-gallery__previous.hidden[data-v-239321eb],
.vgo-gallery .vgo-gallery__next.hidden[data-v-239321eb] {
    opacity: 0;
    pointer-events: none;
}
.vgo-gallery__pager[data-v-239321eb] {
    position: absolute;
    bottom: 10px;
    width: 100%;
    padding: 0;
    list-style: none;
    text-align: center;
    pointer-events: none;
    display: flex;
    justify-content: center;
    margin: 0;
}
.vgo-gallery__pager li[data-v-239321eb] {
    padding: 5px 3px;
    pointer-events: initial;
    cursor: pointer;
}
.vgo-gallery__pager li[data-v-239321eb]:before {
    content: '';
    display: block;
    width: 10px;
    height: 10px;
    opacity: 1;
    background: transparent;
    border: 2px solid white;
    border-radius: 50%;
    transition: border-width .1s;
}
.vgo-gallery__pager li[data-v-239321eb]:hover:before,
.vgo-gallery__pager li.selected[data-v-239321eb]:before {
    border-width: 5px;
}`);const h2=["innerHTML"],d2={__name:"cb-badge",props:{type:{type:String,validator:e=>["default","discount","fewleft","cancelled","preliminary","custom"].indexOf(e)!==-1,default:"default"},value:{type:String,required:!0}},setup(e){const t=e,n=te(()=>({"cb-badge":t.type!=="custom","cb-badge--discount":t.type==="discount","cb-badge--fewleft":t.type==="fewleft","cb-badge--cancelled":t.type==="cancelled","cb-badge--preliminary":t.type==="preliminary"}));return(i,r)=>(I(),O("span",{class:ve([n.value]),innerHTML:e.value},null,10,h2))}},p2={key:0,class:"cb-badges"},g2={__name:"cb-badges",props:{badges:{type:Array,default:()=>[]}},setup:e=>(t,n)=>e.badges?(I(),O("div",p2,[(I(!0),O(be,null,Qe(e.badges,i=>(I(),ce(d2,{key:i.value,type:i.type,value:i.value},null,8,["type","value"]))),128))])):ie("",!0)},f2=xo(g2,[["__scopeId","data-v-0b07fb2a"]]);bo(`.cb-badges[data-v-0b07fb2a] {
    position: absolute;
    top: 15px;
    left: 0;
    display: flex;
    flex-direction: column;
    row-gap: 5px;
    font-size: var(--vg-body-small-font-size);
    pointer-events: none;
    z-index: 1;
}
.cb-badges[data-v-0b07fb2a] .cb-badge-recommended > span {
        height: 70px;
        max-width: 105px;
}
@container (max-width: 500px) {
.cb-badges[data-v-0b07fb2a] .cb-badge-recommended > span {
            height: 63px;
            max-width: 94px;
}
}
@container (max-width: 500px) {
.cb-badges[data-v-0b07fb2a] .cb-badge {
            font-size: 90%;
            border-top-left-radius: 0;
            border-bottom-left-radius: 0;
}
}`);const m2={class:"cb-dialog__wrapper"},v2={class:"cb-dialog__close"},_2=["aria-labelledby"],y2=["id"],b2={key:0,class:"cb-dialog__gallery"},x2={class:"cb-dialog__padding"},w2={key:1,class:"cb-dialog__footer"},E2=Object.assign({inheritAttrs:!1},{__name:"cb-dialog-description",props:{modelValue:{type:Boolean,default:!1},locked:{type:Boolean,default:!1},closeButtonText:{type:String,required:!0},images:{type:Array,default:()=>[]},badges:{type:Array,default:()=>[]}},emits:["update:modelValue","closed"],setup(e,{emit:t}){const n=e,i=t,r=Nt().uid,s=te({get:()=>n.modelValue,set:l=>i("update:modelValue",l)}),o=le(!1),a=()=>{o.value=!0,setTimeout(()=>{o.value=!1},300)};return(l,c)=>(I(),ce(Ov,{to:"body"},[Q(D(Jw),Bi({modelValue:s.value,"onUpdate:modelValue":c[1]||(c[1]=u=>s.value=u)},l.$attrs,{locked:e.locked,delay:400,onClosed:c[2]||(c[2]=u=>i("closed")),onBlocked:a}),{default:ye(()=>[S("div",{class:ve(["cb-dialog__description",{"cb-dialog--shake":o.value}])},[S("div",m2,[S("div",v2,[S("button",{"aria-labelledby":`cb-dialog__close-${D(r)}`,onClick:c[0]||(c[0]=St(u=>s.value=!1,["prevent","stop"]))},[c[3]||(c[3]=S("span",{class:"cb--icon"},[S("span",{class:"cb-icon-aws cb-icon-aws--stronger cb--xmark-large"})],-1)),S("span",{id:`cb-dialog__close-${D(r)}`,class:"cb--text"},Z(e.closeButtonText),9,y2)],8,_2)]),e.images.length>0?(I(),O("div",b2,[Q(D(u2),{images:e.images},{default:ye(()=>[Q(D(f2),{badges:e.badges},null,8,["badges"])]),_:1},8,["images"])])):ie("",!0),S("div",x2,[Me(l.$slots,"default",{},void 0,!0)]),l.$slots.footer?(I(),O("div",w2,[Me(l.$slots,"footer",{},void 0,!0)])):ie("",!0)])],2)]),_:3},16,["modelValue","locked"])]))}}),Cm=xo(E2,[["__scopeId","data-v-09f227ee"]]);bo(`body:has(.cb-dialog[open]) {
    overflow: hidden;
    margin-right: var(--vg-scrollbar-width);
}
body:has(.cb-dialog--leave) {
    overflow: hidden;
    margin-right: var(--vg-scrollbar-width);
}
body:has(.cb-dialog--enter) {
    overflow: hidden;
    margin-right: var(--vg-scrollbar-width);
}
.cb-dialog[data-v-09f227ee] {
    width: 100%;
    height: 100%;
    border: 0;
    padding: 0;
    background-color: transparent;
    max-width: 100%;
    max-height: 100%;
}
.cb-dialog[data-v-09f227ee]::backdrop {
    background-color: rgba(25,25,25,.85);
}
.cb-dialog .cb-dialog--shake[data-v-09f227ee] {
    animation: cb-dialog-shake-09f227ee 0.82s cubic-bezier(.36,.07,.19,.97) both;
    transform: translate3d(0, 0, 0);
}
@keyframes cb-dialog-shake-09f227ee {
10%, 90% {
        transform: translate3d(-1px, 0, 0);
}
20%, 80% {
        transform: translate3d(2px, 0, 0);
}
30%, 50%, 70% {
        transform: translate3d(-4px, 0, 0);
}
40%, 60% {
        transform: translate3d(4px, 0, 0);
}
}
.cb-dialog[open][data-v-09f227ee] {
    animation: cb-dialog-enter-09f227ee .3s cubic-bezier(.075,.82,.165,1);
    animation-fill-mode: forwards;
}
.cb-dialog[open][data-v-09f227ee]::backdrop {
    animation: cb-dialog-fade-in-09f227ee .3s ease-in;
}
.cb-dialog.cb-dialog--leave[data-v-09f227ee] {
    animation: cb-dialog-leave-09f227ee .3s cubic-bezier(.55,.055,.675,.19);
    animation-fill-mode: forwards;
}
.cb-dialog.cb-dialog--leave[data-v-09f227ee]::backdrop {
    animation: cb-dialog-fade-out-09f227ee .3s ease-out;
    animation-fill-mode: forwards;
}
[data-v-09f227ee]  .cb-dialog__close {
        position: sticky;
        z-index: 13;
        top: 0;
        width: 100%;
        opacity: 0;
        animation: cb-dialog-fade-in-09f227ee forwards .2s;
        animation-delay: .4s;
}
[data-v-09f227ee]  .cb-dialog__close button {
        position: absolute;
        top: 10px;
        right: 10px;
        display: flex;
        align-items: center;
        justify-content: flex-end;
        background: none;
        border: 0;
        cursor: pointer;
        font-size: 18px;
        border-radius: 20px;
        font-weight: var(--vg-body-bold-font-weight);
        font-size: var(--vg-body-small-font-size);
        font-family: inherit;
        overflow: hidden;
        outline: none;
}
[data-v-09f227ee]  .cb-dialog__close button:focus .cb--icon:before,[data-v-09f227ee]  .cb-dialog__close button:focus .cb--text:before {
        content: '';
        position: absolute;
        inset: 0;
        background-color: currentColor;
        border-radius: inherit;
        opacity: .15;
}
[data-v-09f227ee]  .cb-dialog__close .cb--icon {
        position: relative;
        display: flex;
        align-items: center;
        justify-content: center;
        min-width: 34px;
        height: 34px;
        background-color: rgba(0,0,0,.6);
        color: #fff;
        border-radius: 20px 0 0 20px;
        font-size: 14px;
}
[data-v-09f227ee]  .cb-dialog__close .cb--text {
        position: relative;
        display: flex;
        align-items: center;
        height: 34px;
        overflow: hidden;
        white-space: nowrap;
        background-color: rgba(0,0,0,.6);
        color: #fff;
        animation: cb-dialog__close-text-out-09f227ee forwards ease-out .4s;
}
[data-v-09f227ee]  .cb-dialog__close:hover .cb--text {
        animation: cb-dialog__close-text-in-09f227ee forwards ease-out .4s;
}
@keyframes cb-dialog__close-text-in-09f227ee {
0% {width: 0; padding-right: 0; color: transparent;}
100% {width: 100%; padding-right: 15px; color: #fff;}
}
@keyframes cb-dialog__close-text-out-09f227ee {
0% {width: 100%; padding-right: 15px; color: #fff;}
100% {width: 0; padding-right: 0; color: transparent;}
}
@keyframes cb-dialog-enter-09f227ee {
0% {transform: translate3d(0,200px,0); opacity: 0;}
100% {transform: translate3d(0,0,0); opacity: 1;}
}
@keyframes cb-dialog-leave-09f227ee {
0% {transform: translate3d(0,0,0); opacity: 1;}
100% {transform: translate3d(0,200px,0); opacity: 0;}
}
@keyframes cb-dialog-fade-out-left-09f227ee {
0% {transform: translate3d(0,0,0); opacity: 1;}
100% {transform: translate3d(-50px,0,0); opacity: 0;}
}
@keyframes cb-dialog-fade-out-right-09f227ee {
0% {transform: translate3d(0,0,0); opacity: 1;}
100% {transform: translate3d(50px,0,0); opacity: 0;}
}
@keyframes cb-dialog-fade-in-right-09f227ee {
0% {transform: translate3d(50px,0,0); opacity: 0;}
100% {transform: translate3d(0,0,0); opacity: 1;}
}
@keyframes cb-dialog-fade-in-left-09f227ee {
0% {transform: translate3d(-50px,0,0); opacity: 0;}
100% {transform: translate3d(0,0,0); opacity: 1;}
}
@keyframes cb-dialog-fade-out-09f227ee {
0% {opacity: 1;}
100% {opacity: 0;}
}
@keyframes cb-dialog-fade-in-09f227ee {
0% {opacity: 0;}
100% {opacity: 1;}
}
@keyframes cb-dialog-summary-height-09f227ee {
0% {height: 0; opacity: 0;}
100% {height: calc(100vh - 140px); opacity: 1;}
}
.cb-dialog[data-v-09f227ee] {
    scrollbar-gutter: stable;
}
[data-v-09f227ee]  .cb-dialog__description {
        display: flex;
        min-height: 100%;
        pointer-events: none;
}
@media (min-width: 441px) {
[data-v-09f227ee]  .cb-dialog__description {
            padding: 20px;
}
}
[data-v-09f227ee]  .cb-dialog__wrapper {
        display: flex;
        flex-direction: column;
        width: 100%;
        max-width: 800px;
        min-height: 100%;
        margin: 0 auto;
        background-color: var(--vg-body-background-color);
        pointer-events: initial;
        border-radius: var(--vg-card-all-border-radius);
}
[data-v-09f227ee]  .cb-dialog__gallery {
        background-color: #999;
}
[data-v-09f227ee]  .cb-dialog__gallery .vgo-gallery {
            height: 100%;
}
@media (max-width: 440px) {
[data-v-09f227ee]  .cb-dialog__gallery {
            height: 300px;
}
}
@media (min-width: 441px) {
[data-v-09f227ee]  .cb-dialog__gallery {
            height: 350px;
            border-radius: var(--vg-card-tl-border-radius) var(--vg-card-tr-border-radius) 0 0;
}
}
[data-v-09f227ee]  .cb-dialog__padding {
        flex-grow: 1;
}
@media (max-width: 440px) {
[data-v-09f227ee]  .cb-dialog__padding {
            padding: 40px 20px;
}
}
@media (min-width: 441px) {
[data-v-09f227ee]  .cb-dialog__padding {
            padding: 50px 30px;
}
}
[data-v-09f227ee]  .cb-dialog__footer {
        position: sticky;
        bottom: 0;
        display: flex;
        align-items: center;
        justify-content: space-between;
        background-color: var(--vg-total-background);
        color: var(--vg-total-color);
        box-shadow: var(--vg-total-box-shadow);
        min-height: 80px;
}
[data-v-09f227ee]  .cb-dialog__footer .cb-btn {
            height: 50px;
}
[data-v-09f227ee]  .cb-dialog__footer .vgo-pricing__definition {
            font-size: var(--vg-body-small-font-size);
            line-height: var(--vg-body-small-line-height);
}
@media (max-width: 440px) {
[data-v-09f227ee]  .cb-dialog__footer {
            padding: 10px 20px;
}
}
@media (min-width: 441px) {
[data-v-09f227ee]  .cb-dialog__footer {
            padding: 10px 30px;
            border-radius: 0 0 var(--vg-card-br-border-radius) var(--vg-card-bl-border-radius);
            gap: 20px;

            /* Generic price */
}
[data-v-09f227ee]  .cb-dialog__footer .cb-dialog__footer-pricing {
                flex-grow: 1;
                text-align: right;
}
[data-v-09f227ee]  .cb-dialog__footer .cb-dialog__footer-pricing b {font-size: var(--vg-body-large-font-size);}

            /* Pricing component */
[data-v-09f227ee]  .cb-dialog__footer .vgo-pricing {
                flex-grow: 1;
                text-align: right;
}
[data-v-09f227ee]  .cb-dialog__footer .vgo-pricing__main {
                justify-content: flex-end;
}
[data-v-09f227ee]  .cb-dialog__footer .vgo-pricing__price {
                font-size: var(--vg-body-large-font-size);
}
}`);const C2={class:"cb-content"},A2={class:"cb-modal-filter",style:{padding:"0 !important"}},S2=["aria-labelledby"],T2=["id"],R2={__name:"cb-filter-modal",props:{modelValue:{type:String,required:!0},isOpen:{type:Boolean,required:!0},filters:{type:Array,default:()=>[]}},emits:["update:modelValue","update:isOpen"],setup(e,{emit:t}){const n=e,i=t,{state:r,get:s}=Ye("cb-query-count"),o=Nt().uid,a=le(0),l=Xe({}),c=te({get:()=>n.isOpen,set(_){f(),i("update:isOpen",_)}}),u=te(()=>Em(n.modelValue)),h=te(()=>(_=>{const y=Object.entries(_),x=new Map(y);return Eh(x)})(l)),p=()=>{for(const _ in l)l[_]=""},f=()=>{for(const _ in l)l[_]="";for(const[_,y]of u.value)l[_]=y},m=()=>{i("update:modelValue",h.value),i("update:isOpen",!1)};return Re(()=>n.modelValue,f),Re(()=>n.filters,()=>{for(const _ of n.filters)l[_.key]||(l[_.key]=u.value.get(_.key)??"")},{deep:!0,immediate:!0}),Re(()=>h.value,async()=>{const _=await s(h.value);typeof _=="number"&&(a.value=_)},{immediate:!0}),(_,y)=>(I(),ce(D(Cm),{modelValue:c.value,"onUpdate:modelValue":y[0]||(y[0]=x=>c.value=x),"close-button-text":_.$t("List.Filters.Close"),"aria-label":_.$t("List.Filters.AriaLabel")},{footer:ye(()=>[S("div",null,[yt(S("a",{href:"javascript:void(0);",onClick:p},[S("b",null,Z(_.$t("List.Filters.Clear")),1)],512),[[Ft,h.value]])]),Q(D(dr),{size:"large",loading:D(r).isLoading,disabled:D(r).isLoading||a.value===0,onClick:m},{default:ye(()=>[je(Z(_.$t("List.Filters.ViewAlternatives"))+" ("+Z(a.value)+") ",1)]),_:1},8,["loading","disabled"])]),default:ye(()=>[S("div",C2,[S("div",null,[S("div",A2,[(I(!0),O(be,null,Qe(e.filters,x=>(I(),O("div",{key:x.key,class:"cb-group",role:"group","aria-labelledby":`cb-filter-modal-filter-group-${D(o)}-${x.key}-heading`},[S("h2",{id:`cb-filter-modal-filter-group-${D(o)}-${x.key}-heading`},Z(x.name),9,T2),(I(),ce(ai(D(wm)(x.type)),{modelValue:l[x.key],"onUpdate:modelValue":w=>l[x.key]=w,context:x.context},null,8,["modelValue","onUpdate:modelValue","context"]))],8,S2))),128))])])])]),_:1},8,["modelValue","close-button-text","aria-label"]))}},k2={top:"x",right:"y",bottom:"x",left:"y"},P2={x:"width",y:"height"},qa={top:(e,t,n,i)=>({x:e,y:n.y-i.height}),right:(e,t,n)=>({x:n.x+n.width,y:t}),bottom:(e,t,n)=>({x:e,y:n.y+n.height}),left:(e,t,n,i)=>({x:n.x-i.width,y:t})},Xa={start:(e,t,n)=>e[t]-n,center:(e,t)=>e[t],end:(e,t,n)=>e[t]+n},I2=(e,t,n,i)=>{const r=k2[n],s=P2[r],o=e.x+e.width/2-t.width/2,a=e.y+e.height/2-t.height/2,l=e[s]/2-t[s]/2,c=Xa[i],u=(0,qa[n])(o,a,e,t);return u[r]=c(u,r,l),u};var M2=Object.defineProperty,Am=(e,t,n)=>((i,r,s)=>r in i?M2(i,r,{enumerable:!0,configurable:!0,writable:!0,value:s}):i[r]=s)(e,typeof t!="symbol"?t+"":t,n),Wa=class extends Event{constructor(e,{oldState:t="",newState:n="",...i}={}){super(e,i),Am(this,"oldState"),Am(this,"newState"),this.oldState=String(t||""),this.newState=String(n||"")}},Sm=new WeakMap;function Tm(e,t,n){Sm.set(e,setTimeout(()=>{Sm.has(e)&&e.dispatchEvent(new Wa("toggle",{cancelable:!1,oldState:t,newState:n}))},0))}var Ch=globalThis.ShadowRoot||function(){},L2=globalThis.HTMLDialogElement||function(){},Ya=new WeakMap,Pn=new WeakMap,wo=new WeakMap;function Za(e){return wo.get(e)||"hidden"}var Ha=new WeakMap;function Ti(e,t){return!(e.popover!=="auto"&&e.popover!=="manual"||!e.isConnected||t&&Za(e)!=="showing"||!t&&Za(e)!=="hidden"||e instanceof L2&&e.hasAttribute("open")||document.fullscreenElement===e)}function Rm(e){return e?Array.from(Pn.get(e.ownerDocument)||[]).indexOf(e)+1:0}function F2(e){const t=km(e),n=function(i){for(;i;){const r=i.popoverTargetElement;if(r instanceof HTMLElement)return r;if((i=i.parentElement||pr(i))instanceof Ch&&(i=i.host),i instanceof Document)return}}(e);return Rm(t)>Rm(n)?t:n}function Ka(e){const t=Pn.get(e);for(const n of t||[]){if(n.isConnected)return n;t.delete(n)}return null}function pr(e){return typeof e.getRootNode=="function"?e.getRootNode():e.parentNode?pr(e.parentNode):e}function km(e){for(;e;){if(e instanceof HTMLElement&&e.popover==="auto"&&wo.get(e)==="showing")return e;if((e=e instanceof Element&&e.assignedSlot||e.parentElement||pr(e))instanceof Ch&&(e=e.host),e instanceof Document)return}}function O2(e){return!(e.hidden||e instanceof Ch||(e instanceof HTMLButtonElement||e instanceof HTMLInputElement||e instanceof HTMLSelectElement||e instanceof HTMLTextAreaElement||e instanceof HTMLOptGroupElement||e instanceof HTMLOptionElement||e instanceof HTMLFieldSetElement)&&e.disabled||e instanceof HTMLInputElement&&e.type==="hidden"||e instanceof HTMLAnchorElement&&e.href==="")&&typeof e.tabIndex=="number"&&e.tabIndex!==-1}function D2(e){var t;(t=function(n){if(n.shadowRoot&&n.shadowRoot.delegatesFocus!==!0)return null;let i=n;i.shadowRoot&&(i=i.shadowRoot);let r=i.querySelector("[autofocus]");if(r)return r;{const a=i.querySelectorAll("slot");for(const l of a){const c=l.assignedElements({flatten:!0});for(const u of c){if(u.hasAttribute("autofocus"))return u;if(r=u.querySelector("[autofocus]"),r)return r}}}const s=n.ownerDocument.createTreeWalker(i,NodeFilter.SHOW_ELEMENT);let o=s.currentNode;for(;o;){if(O2(o))return o;o=s.nextNode()}}(e))==null||t.focus()}var Qa=new WeakMap;function Ah(e){if(!Ti(e,!1))return;const t=e.ownerDocument;if(!e.dispatchEvent(new Wa("beforetoggle",{cancelable:!0,oldState:"closed",newState:"open"}))||!Ti(e,!1))return;let n=!1;if(e.popover==="auto"){const r=e.getAttribute("popover"),s=function(o){const a=new Map;let l=0;for(const u of Pn.get(o.ownerDocument)||[])a.set(u,l),l+=1;a.set(o,l),l+=1;let c=null;return function(u){const h=km(u);if(h===null)return null;const p=a.get(h);(c===null||a.get(c)<p)&&(c=h)}(o.parentElement||pr(o)),c}(e)||t;if(Ja(s,!1,!0),r!==e.getAttribute("popover")||!Ti(e,!1))return}Ka(t)||(n=!0),Qa.delete(e);const i=t.activeElement;e.classList.add(":popover-open"),wo.set(e,"showing"),Ya.has(t)||Ya.set(t,new Set),Ya.get(t).add(e),D2(e),e.popover==="auto"&&(Pn.has(t)||Pn.set(t,new Set),Pn.get(t).add(e),Mm(Ha.get(e),!0)),n&&i&&e.popover==="auto"&&Qa.set(e,i),Tm(e,"closed","open")}function Eo(e,t=!1,n=!1){var i,r;if(!Ti(e,!0))return;const s=e.ownerDocument;if(e.popover==="auto"&&(Ja(e,t,n),!Ti(e,!0))||(Mm(Ha.get(e),!1),Ha.delete(e),n&&(e.dispatchEvent(new Wa("beforetoggle",{oldState:"open",newState:"closed"})),!Ti(e,!0))))return;(i=Ya.get(s))==null||i.delete(e),(r=Pn.get(s))==null||r.delete(e),e.classList.remove(":popover-open"),wo.set(e,"hidden"),n&&Tm(e,"open","closed");const o=Qa.get(e);o&&(Qa.delete(e),t&&o.focus())}function Pm(e,t=!1,n=!1){let i=Ka(e);for(;i;)Eo(i,t,n),i=Ka(e)}function Ja(e,t,n){var i;const r=e.ownerDocument||e;if(e instanceof Document)return Pm(r,t,n);let s=null,o=!1;for(const a of Pn.get(r)||[])if(a===e)o=!0;else if(o){s=a;break}if(!o)return Pm(r,t,n);for(;s&&Za(s)==="showing"&&(i=Pn.get(r))!=null&&i.size;)Eo(s,t,n)}var Sh=new WeakMap;function Im(e){if(!e.isTrusted)return;const t=e.composedPath()[0];if(!t)return;const n=t.ownerDocument;if(!Ka(n))return;const i=F2(t);if(i&&e.type==="pointerdown")Sh.set(n,i);else if(e.type==="pointerup"){const r=Sh.get(n)===i;Sh.delete(n),r&&Ja(i||n,!1,!0)}}var Th=new WeakMap;function Mm(e,t=!1){if(!e)return;Th.has(e)||Th.set(e,e.getAttribute("aria-expanded"));const n=e.popoverTargetElement;if(n instanceof HTMLElement&&n.popover==="auto")e.setAttribute("aria-expanded",String(t));else{const i=Th.get(e);i?e.setAttribute("aria-expanded",i):e.removeAttribute("aria-expanded")}}var Lm=globalThis.ShadowRoot||function(){};function Ri(e,t,n){const i=e[t];Object.defineProperty(e,t,{value(r){return i.call(this,n(r))}})}var U2=/(^|[^\\]):popover-open\b/g;function B2(){const e=typeof globalThis.CSSLayerBlockRule=="function";return`
${e?"@layer popover-polyfill {":""}
  :where([popover]) {
    position: fixed;
    z-index: 2147483647;
    inset: 0;
    padding: 0.25em;
    width: fit-content;
    height: fit-content;
    border-width: initial;
    border-color: initial;
    border-image: initial;
    border-style: solid;
    background-color: canvas;
    color: canvastext;
    overflow: auto;
    margin: auto;
  }

  :where([popover]:not(.\\:popover-open)) {
    display: none;
  }

  :where(dialog[popover].\\:popover-open) {
    display: block;
  }

  :where(dialog[popover][open]) {
    display: revert;
  }

  :where([anchor].\\:popover-open) {
    inset: auto;
  }

  :where([anchor]:popover-open) {
    inset: auto;
  }

  @supports not (background-color: canvas) {
    :where([popover]) {
      background-color: white;
      color: black;
    }
  }

  @supports (width: -moz-fit-content) {
    :where([popover]) {
      width: -moz-fit-content;
      height: -moz-fit-content;
    }
  }

  @supports not (inset: 0) {
    :where([popover]) {
      top: 0;
      left: 0;
      right: 0;
      bottom: 0;
    }
  }
${e?"}":""}
`}var Co=null;function Rh(e){const t=B2();if(Co===null)try{(Co=new CSSStyleSheet).replaceSync(t)}catch{Co=!1}if(Co===!1){const n=document.createElement("style");n.textContent=t,e instanceof Document?e.head.prepend(n):e.prepend(n)}else e.adoptedStyleSheets=[Co,...e.adoptedStyleSheets]}function z2(){if(typeof window>"u")return;function e(a){return a!=null&&a.includes(":popover-open")&&(a=a.replace(U2,"$1.\\:popover-open")),a}window.ToggleEvent=window.ToggleEvent||Wa,Ri(Document.prototype,"querySelector",e),Ri(Document.prototype,"querySelectorAll",e),Ri(Element.prototype,"querySelector",e),Ri(Element.prototype,"querySelectorAll",e),Ri(Element.prototype,"matches",e),Ri(Element.prototype,"closest",e),Ri(DocumentFragment.prototype,"querySelectorAll",e),Object.defineProperties(HTMLElement.prototype,{popover:{enumerable:!0,configurable:!0,get(){if(!this.hasAttribute("popover"))return null;const a=(this.getAttribute("popover")||"").toLowerCase();return a===""||a=="auto"?"auto":"manual"},set(a){this.setAttribute("popover",a)}},showPopover:{enumerable:!0,configurable:!0,value(){Ah(this)}},hidePopover:{enumerable:!0,configurable:!0,value(){Eo(this,!0,!0)}},togglePopover:{enumerable:!0,configurable:!0,value(a){wo.get(this)==="showing"&&a===void 0||a===!1?Eo(this,!0,!0):(a===void 0||a===!0)&&Ah(this)}}});const t=Element.prototype.attachShadow;t&&Object.defineProperties(Element.prototype,{attachShadow:{enumerable:!0,configurable:!0,writable:!0,value(a){const l=t.call(this,a);return Rh(l),l}}});const n=HTMLElement.prototype.attachInternals;n&&Object.defineProperties(HTMLElement.prototype,{attachInternals:{enumerable:!0,configurable:!0,writable:!0,value(){const a=n.call(this);return a.shadowRoot&&Rh(a.shadowRoot),a}}});const i=new WeakMap;function r(a){Object.defineProperties(a.prototype,{popoverTargetElement:{enumerable:!0,configurable:!0,set(l){if(l===null)this.removeAttribute("popovertarget"),i.delete(this);else{if(!(l instanceof Element))throw new TypeError("popoverTargetElement must be an element or null");this.setAttribute("popovertarget",""),i.set(this,l)}},get(){if(this.localName!=="button"&&this.localName!=="input"||this.localName==="input"&&this.type!=="reset"&&this.type!=="image"&&this.type!=="button"||this.disabled||this.form&&this.type==="submit")return null;const l=i.get(this);if(l&&l.isConnected)return l;if(l&&!l.isConnected)return i.delete(this),null;const c=pr(this),u=this.getAttribute("popovertarget");return(c instanceof Document||c instanceof Lm)&&u&&c.getElementById(u)||null}},popoverTargetAction:{enumerable:!0,configurable:!0,get(){const l=(this.getAttribute("popovertargetaction")||"").toLowerCase();return l==="show"||l==="hide"?l:"toggle"},set(l){this.setAttribute("popovertargetaction",l)}}})}r(HTMLButtonElement),r(HTMLInputElement);const s=a=>{const l=a.composedPath(),c=l[0];if(!(c instanceof Element)||c!=null&&c.shadowRoot)return;const u=pr(c);if(!(u instanceof Lm||u instanceof Document))return;const h=l.find(p=>{var f;return(f=p.matches)==null?void 0:f.call(p,"[popovertargetaction],[popovertarget]")});return h?(function(p){const f=p.popoverTargetElement;if(!(f instanceof HTMLElement))return;const m=Za(f);p.popoverTargetAction==="show"&&m==="showing"||p.popoverTargetAction==="hide"&&m==="hidden"||(m==="showing"?Eo(f,!0,!0):Ti(f,!1)&&(Ha.set(f,p),Ah(f)))}(h),void a.preventDefault()):void 0},o=a=>{const l=a.key,c=a.target;!a.defaultPrevented&&c&&(l==="Escape"||l==="Esc")&&Ja(c.ownerDocument,!0,!0)};(a=>{a.addEventListener("click",s),a.addEventListener("keydown",o),a.addEventListener("pointerdown",Im),a.addEventListener("pointerup",Im)})(document),Rh(document)}const j2={__name:"cb-popover",props:{modelValue:{type:Boolean,required:!0},anchor:{type:[HTMLElement,null],required:!0},placement:{type:String,default:"bottom",validator:e=>Object.keys(qa).includes(e)},alignment:{type:String,default:"center",validator:e=>Object.keys(Xa).includes(e)}},emits:["update:modelValue"],setup(e,{expose:t,emit:n}){const i=e,r=n,s=le(null),o=le(i.alignment),a=le(i.placement);let l=Object.keys(Xa),c=Object.keys(qa);const u=(x,w)=>x.x>=window.visualViewport.pageLeft&&x.x+w.width<=window.visualViewport.pageLeft+window.visualViewport.width&&x.y>=window.visualViewport.pageTop&&x.y+w.height<=window.visualViewport.pageTop+window.visualViewport.height,h=()=>{const x=Object.keys(qa),w=x.indexOf(i.placement);c=x.slice(w).concat(x.slice(0,w)),l=[i.alignment,...Object.keys(Xa).filter(T=>T!==i.alignment)]},p=x=>{const w=x.getBoundingClientRect();return new DOMRect(w.left+window.scrollX,w.top+window.scrollY,w.width,w.height)},f=()=>{var x,w;i.modelValue?(x=s.value)==null||x.showPopover():(w=s.value)==null||w.hidePopover()},m=()=>{if(!i.modelValue||!i.anchor||!s.value)return;const x=((w,T)=>{for(const R of c)for(const b of l){const k=I2(w,T,R,b);if(u(k,T))return o.value=b,a.value=R,k}return o.value=void 0,a.value=void 0,{x:window.visualViewport.pageLeft+window.visualViewport.width/2-T.width/2,y:window.visualViewport.pageTop+window.visualViewport.height/2-T.height/2}})(p(i.anchor),p(s.value));s.value.style.top=`${x.y}px`,s.value.style.left=`${x.x}px`},_=x=>{const w=x.newState==="open";r("update:modelValue",w)},y=new ResizeObserver(m);return Re(()=>i.anchor,(x,w)=>{x&&y.observe(x),w&&y.unobserve(w)}),Re(()=>s.value,(x,w)=>{x&&y.observe(x),w&&y.unobserve(w)}),Re(()=>i.placement,()=>{h(),m()},{immediate:!0}),Re(()=>i.alignment,()=>{h(),m()},{immediate:!0}),Re(()=>i.modelValue,f),We(()=>{typeof HTMLElement<"u"&&typeof HTMLElement.prototype=="object"&&"popover"in HTMLElement.prototype||z2(),y.observe(document.body),window.addEventListener("resize",m),f()}),Wo(()=>{y.unobserve(document.body),window.removeEventListener("resize",m)}),t({element:s}),(x,w)=>(I(),O("div",{ref_key:"target",ref:s,class:ve(["cb-popover",o.value,a.value]),popover:"",onToggle:_},[Me(x.$slots,"default",{},void 0,!0)],34))}},N2=xo(j2,[["__scopeId","data-v-837614e0"]]);bo(`.cb-popover[data-v-837614e0] {
    position: absolute;
    inset: unset;
    padding: 20px;
    transition: .3s opacity;
    border: var(--vg-popout-border-width) solid var(--vg-popout-border-color);
    border-radius: var(--vg-popout-border-radius);
    background-color: var(--vg-popout-background-color);
    box-shadow: var(--vg-popout-box-shadow);
    color: var(--vg-popout-color);
    font-family: var(--vg-body-font-family);
    font-size: var(--vg-body-font-size);
    font-weight: var(--vg-body-font-weight);
    line-height: var(--vg-body-line-height);
    letter-spacing: var(--vg-body-letter-spacing);

    /* restrict height */
    /*max-height: calc(100vh - 200px);*/ /* for large inner content */
    max-width: calc(100vw - 40px); /* for mobile */
    overflow: auto;
}
.cb-popover[data-v-837614e0]  {
        box-sizing: border-box;
}
.cb-popover[data-v-837614e0]  * {
            box-sizing: border-box;
}
.cb-popover.top[data-v-837614e0] {
        margin-top: -10px;
}
.cb-popover.right[data-v-837614e0] {
        margin-left: 10px;
}
.cb-popover.bottom[data-v-837614e0] {
        margin-top: 10px;
}
.cb-popover.left[data-v-837614e0] {
        margin-left: -10px;
}
.cb-popover[data-v-837614e0]:popover-open {
        opacity: 1;
}
@starting-style {
.cb-popover[data-v-837614e0]:popover-open {
            opacity: 0;
}
}
`);const G2={class:"cb-badge","aria-hidden":"true"},V2=["aria-label"],$2={style:{display:"flex","justify-content":"space-between","padding-top":"15px"}},q2={__name:"cb-filter-shortcut",props:{name:{type:String,required:!0},modelValue:{type:String,required:!0},filterKey:{type:String,required:!0},filterType:{type:String,required:!0},context:{type:Object,required:!0}},emits:["update:modelValue"],setup(e,{emit:t}){const n=e,i=t,{state:r,get:s}=Ye("cb-query-count"),o=le(null),a=le(""),l=le(!1),c=le(0),u=te(()=>Em(n.modelValue)),h=te(()=>u.value.has(n.filterKey)),p=te(()=>{const x=u.value.get(n.filterKey);return(x==null?void 0:x.split(Dt.values).length)??0}),f=async()=>{const x=new Map(u.value);x.set(n.filterKey,a.value);const w=Eh(x),T=await s(w);typeof T=="number"&&(c.value=T)},m=async()=>{a.value=u.value.get(n.filterKey)??"",await f()},_=async()=>{a.value="",await f()},y=()=>{u.value.set(n.filterKey,a.value);const x=Eh(u.value);i("update:modelValue",x),l.value=!1};return Re(()=>l.value,x=>{x||m()}),Re(()=>n.modelValue,m,{immediate:!0}),(x,w)=>(I(),O("span",{ref_key:"anchor",ref:o,class:"cb-hide-sm"},[Q(D(dr),{secondary:"",class:ve({"cb-selected cb--show-badge":h.value}),onClick:w[0]||(w[0]=T=>l.value=!l.value)},{default:ye(()=>[je(Z(e.name)+" ",1),S("span",G2,Z(p.value),1)]),_:1},8,["class"]),Q(D(N2),{modelValue:l.value,"onUpdate:modelValue":w[2]||(w[2]=T=>l.value=T),anchor:o.value,placement:"bottom",alignment:"start",class:"cb-framework"},{default:ye(()=>[S("div",{style:{"max-width":"300px"},role:"group","aria-label":e.name},[(I(),ce(ai(D(wm)(e.filterType)),{modelValue:a.value,"onUpdate:modelValue":[w[1]||(w[1]=T=>a.value=T),f],context:e.context,expand:1/0},null,8,["modelValue","context"])),S("div",$2,[S("div",null,[yt(S("a",{href:"javascript:void(0);",class:"cb-btn cb-btn-link",style:{margin:"0"},onClick:_},Z(x.$t("List.Filters.Clear")),513),[[Ft,a.value]])]),S("div",null,[Q(D(dr),{size:"small",loading:D(r).isLoading,disabled:D(r).isLoading||c.value===0,onClick:y},{default:ye(()=>[je(Z(x.$t("List.Filters.Apply"))+" ("+Z(c.value)+") ",1)]),_:1},8,["loading","disabled"])])])],8,V2)]),_:1},8,["modelValue","anchor"])],512))}},X2={__name:"cb-transition",setup(e){const t=r=>{const{width:s}=getComputedStyle(r);r.style.width=s,r.style.position="absolute",r.style.visibility="hidden",r.style.height="auto";const{height:o}=getComputedStyle(r);r.style.width=null,r.style.position=null,r.style.visibility=null,r.style.height=0,getComputedStyle(r).height,requestAnimationFrame(()=>{r.style.height=o})},n=r=>{r.style.height="auto"},i=r=>{const{height:s}=getComputedStyle(r);r.style.height=s,getComputedStyle(r).height,requestAnimationFrame(()=>{r.style.height=0})};return(r,s)=>(I(),ce(m_,{name:"expand",onEnter:t,onAfterEnter:n,onLeave:i},{default:ye(()=>[Me(r.$slots,"default",{},void 0,!0)]),_:3}))}},W2=xo(X2,[["__scopeId","data-v-5aed59cf"]]);bo(`
.expand-enter-active[data-v-5aed59cf],
    .expand-leave-active[data-v-5aed59cf] {
        will-change: height;
        transform: translateZ(0);
        backface-visibility: hidden;
        perspective: 1000px;
        transition: height .2s ease-in-out !important;
        overflow: hidden;
}
.expand-enter[data-v-5aed59cf],
    .expand-leave-to[data-v-5aed59cf] {
        will-change: height;
        transform: translateZ(0);
        backface-visibility: hidden;
        perspective: 1000px;
        height: 0;
}
`);const gr=(e,t)=>{const n=e.__vccOpts||e;for(const[i,r]of t)n[i]=r;return n},Y2=gr({},[["render",function(e,t){return I(),O("div",null,t[0]||(t[0]=[S("div",{class:"cb-flex"},[S("div",{class:"cb-item"},[S("select",{class:"cb-select",style:{opacity:"0"}})])],-1),S("div",{class:"cb-divider"},null,-1)]))}]]),Z2={key:0},H2={class:"cb-flex"},K2={class:"cb-item cb-item--grow cb-item--filter"},Q2={class:"cb-btn-group-parted"},J2={class:"cb-badge","aria-hidden":"true"},eE={__name:"cb-filter",props:{skeleton:{type:Boolean,default:!1},url:{type:String,required:!0},queryCountUrl:{type:String,required:!0},modelValue:{type:String,required:!0},minShortcuts:{type:Number,default:2}},emits:["update:modelValue"],setup(e,{emit:t}){const n=e,i=t,r=Ye("cb-query-parameters"),{state:s,get:o}=function(p){const f={...Iw,...p},m=Xe(structuredClone(Mw));return{state:Bt(m),get:async()=>{m.pendingRequest&&m.pendingRequest.abort(),m.isLoading=!0,m.pendingRequest=new AbortController;const _={...Lw,signal:m.pendingRequest.signal,method:"GET"};await fetch(f.url,_).then(y=>y.json()).then(y=>{m.filters=y.filters,m.pendingRequest=null,m.isLoading=!1}).catch(y=>{if(!(y instanceof Error&&y.name==="AbortError"))throw y}).finally(()=>{m.hasLoaded=!0})}}}({url:n.url}),a=Uw({url:n.queryCountUrl},r),l=le(!1),c=te({get:()=>n.modelValue,set(p){i("update:modelValue",p)}}),u=te(()=>s.filters.filter(p=>p.shortcut)),h=te(()=>n.modelValue.split(Dt.key).map(p=>{const[,f]=p.split(Dt.value);return(f==null?void 0:f.split(Dt.values).length)??0}).reduce((p,f)=>p+f,0));return We(async()=>await o()),zn("cb-query-count",a),(p,f)=>!e.skeleton||D(s).hasLoaded&&D(s).filters.length===0?(I(),ce(D(W2),{key:1},{default:ye(()=>[!D(s).hasLoaded||D(s).filters.length>0?(I(),O("div",Z2,[S("div",H2,[S("div",K2,[S("div",Q2,[u.value.length>=e.minShortcuts||u.value.length<D(s).filters.length?(I(!0),O(be,{key:0},Qe(u.value,m=>(I(),ce(D(q2),{key:m.name,modelValue:c.value,"onUpdate:modelValue":f[0]||(f[0]=_=>c.value=_),name:m.name,context:m.context,"filter-key":m.key,"filter-type":m.type},null,8,["modelValue","name","context","filter-key","filter-type"]))),128)):ie("",!0),Q(D(dr),{secondary:"",loading:D(s).isLoading,disabled:D(s).filters.length===0,class:ve({"cb-selected cb--show-badge":c.value&&!D(s).isLoading}),onClick:f[1]||(f[1]=m=>l.value=!0)},{default:ye(()=>[f[5]||(f[5]=S("span",{class:"cb-icon-aws cb-icon-aws--strong cb--sliders-simple"},null,-1)),je("  "+Z(p.$t("List.Filters"))+" ",1),S("span",J2,Z(h.value),1)]),_:1},8,["loading","disabled","class"]),c.value?(I(),ce(D(dr),{key:1,secondary:"",class:"cb-btn-link",onClick:f[2]||(f[2]=m=>c.value="")},{default:ye(()=>[f[6]||(f[6]=S("span",{class:"cb-icon-aws cb-icon-aws--strong cb--xmark-large"},[S("span")],-1)),f[7]||(f[7]=je("  ")),S("span",null,Z(p.$t("List.Filters.Clear")),1)]),_:1})):ie("",!0),Q(D(R2),{modelValue:c.value,"onUpdate:modelValue":f[3]||(f[3]=m=>c.value=m),"is-open":l.value,"onUpdate:isOpen":f[4]||(f[4]=m=>l.value=m),filters:D(s).filters},null,8,["modelValue","is-open","filters"])])])]),f[8]||(f[8]=S("div",{class:"cb-divider"},null,-1))])):ie("",!0)]),_:1})):(I(),ce(Y2,{key:0}))}},tE=gr(eE,[["__scopeId","data-v-36888184"]]);wh(`
.cb-item.cb-item--grow.cb-item--filter[data-v-36888184] {
        transition: all .3s ease-in;
}
`);const nE={url:""},iE={isLoading:!1,hasLoaded:!1,options:[],pendingRequest:null},rE={credentials:"include",headers:{"Content-Type":"application/json"}},oE={class:"cb-page-subtitle"},sE={class:"cb--small"},aE={class:"cb-spacer-top"},lE={class:"cb-flex cb-flex--wrap cb-flex--gutter-sm cb-flex--gutter-vert-sm cb-flex--2-cols-sm cb-flex--3-cols-lg"},cE=["onClick"],uE={class:"cb-icon-poi"},hE={__name:"cb-sorting-group",props:{isOpen:{type:Boolean,required:!0},groups:{type:Array,default:()=>[]}},emits:["update:isOpen","selected"],setup(e,{emit:t}){const n=e,i=t,r=te({get:()=>n.isOpen,set(s){i("update:isOpen",s)}});return(s,o)=>(I(),ce(D(Cm),{modelValue:r.value,"onUpdate:modelValue":o[0]||(o[0]=a=>r.value=a),"close-button-text":s.$t("List.Filters.Close"),"aria-label":s.$t("List.Filters.AriaLabel")},{default:ye(()=>[(I(!0),O(be,null,Qe(e.groups,a=>(I(),O("div",{key:a.name},[S("div",oE,[S("h2",sE,Z(a.name),1)]),S("div",null,[S("div",aE,[S("div",lE,[(I(!0),O(be,null,Qe(a.options,l=>(I(),O("a",{key:l.value,href:"javascript:void(0);",class:"cb-text-icon cb-mfp-close",onClick:c=>(u=>{i("selected",u),r.value=!1})(l.value)},[S("span",uE,[S("span",{class:ve(["cb-icon-aws",l.iconClassName])},null,2)]),S("span",null,Z(l.name),1)],8,cE))),128))])])])]))),128))]),_:1},8,["modelValue","close-button-text","aria-label"]))}},dE=["value","disabled"],pE=["value"],gE={__name:"cb-select",props:{options:{type:Array,default:()=>[]},modelValue:{type:[String,Number,null],required:!0},success:{type:Boolean},error:{type:Boolean},loading:{type:Boolean},disabled:{type:Boolean},locked:{type:Boolean},size:{type:String,default:null,validator:e=>!e||["small"].indexOf(e)!==-1}},emits:["update:modelValue"],setup(e,{emit:t}){const n=e,i=t,r=te({get:()=>n.modelValue,set(o){i("update:modelValue",o)}}),s=te(()=>({"cb-disabled":n.disabled,"cb-select-sm":n.size==="small","cb-invalid":n.error,"cb-valid":n.success,"cb-loading":n.loading,"cb-locked":n.locked}));return(o,a)=>(I(),O("select",Bi(o.$attrs,{class:["cb-select",s.value],value:r.value,disabled:e.disabled||e.locked,onChange:a[0]||(a[0]=l=>r.value=l.target.value)}),[Me(o.$slots,"default",{},()=>[(I(!0),O(be,null,Qe(e.options,l=>yt((I(),O("option",{key:l.value,value:l.value},Z(l.label),9,pE)),[[Ft,!l.hidden]])),128))])],16,dE))}},fE=gE,mE={class:"cb-item"},vE=gr({},[["render",function(e,t){return I(),O("div",mE,t[0]||(t[0]=[S("select",{class:"cb-select cb-select-sm cb-sort",style:{opacity:"0"},disabled:""},null,-1)]))}]]),_E={key:1,class:"cb-item cb-item--sort"},yE={class:"cb-text-small cb-text-muted"},bE={__name:"cb-sorting",props:{skeleton:{type:Boolean,default:!1},results:{type:Number,required:!0},url:{type:String,required:!0},modelValue:{type:String,required:!0}},emits:["update:modelValue"],setup(e,{emit:t}){const n=e,i=t,r=le(0),s=le(!1),o=le([]),{state:a,get:l}=function(m){const _={...nE,...m},y=Xe(structuredClone(iE));return{state:Bt(y),get:async()=>{y.pendingRequest&&y.pendingRequest.abort(),y.isLoading=!0,y.pendingRequest=new AbortController;const x={...rE,signal:y.pendingRequest.signal,method:"GET"};await fetch(_.url,x).then(w=>w.json()).then(w=>{y.options=w.options,y.pendingRequest=null,y.isLoading=!1}).catch(w=>{if(!(w instanceof Error&&w.name==="AbortError"))throw w}).finally(()=>{y.hasLoaded=!0})}}}({url:n.url}),c=te(()=>{const m=a.options.findIndex(_=>_.value===n.modelValue);return m===-1?n.modelValue:m}),u=te({get:()=>c.value,set(m){const _=a.options[+m];typeof _.value=="string"?i("update:modelValue",_.value):Array.isArray(_.value)&&(s.value=!0,o.value=_.value,r.value++)}}),h=te(()=>a.options.some(m=>Array.isArray(m.value))),p=te(()=>a.options.filter(m=>Array.isArray(m.value)).flatMap(m=>m.value).flatMap(m=>m.options).find(m=>m.value===n.modelValue)),f=te(()=>{const m=p.value;return[...a.options.map((_,y)=>({label:_.name,value:y})),...m?[{label:m.name,value:m.value,hidden:!0}]:[]]});return We(async()=>await l()),(m,_)=>e.skeleton||!e.results||D(a).hasLoaded&&D(a).options.length===0?(I(),ce(vE,{key:0})):(I(),O("div",_E,[S("div",yE,Z(m.$t("List.Sorting"))+": ",1),(I(),ce(D(fE),{key:r.value,modelValue:u.value,"onUpdate:modelValue":_[0]||(_[0]=y=>u.value=y),size:"small",options:f.value,loading:D(a).isLoading,disabled:D(a).isLoading,"aria-label":m.$t("List.Sorting.AriaLabel")},null,8,["modelValue","options","loading","disabled","aria-label"])),h.value?(I(),ce(D(hE),{key:0,"is-open":s.value,"onUpdate:isOpen":_[1]||(_[1]=y=>s.value=y),groups:o.value,onSelected:_[2]||(_[2]=y=>i("update:modelValue",y))},null,8,["is-open","groups"])):ie("",!0)]))}},xE={class:"cb-item cb-item--grow cb-item--count"},wE=gr({},[["render",function(e,t){return I(),O("div",xE,t[0]||(t[0]=[S("div",null,[S("span",{class:"cb-text-ph",style:{width:"90px"}}," ")],-1)]))}]]),EE={key:1,class:"cb-item cb-item--grow cb-item--count"},CE={key:0},AE={class:"cb-hide-lg"},SE={class:"cb-hide-sm"},TE={__name:"cb-list-counter",props:{skeleton:{type:Boolean,default:!1},results:{type:Number,required:!0}},setup:e=>(t,n)=>e.skeleton?(I(),ce(wE,{key:0})):(I(),O("div",EE,[e.results?(I(),O("div",CE,[S("b",AE,Z(t.$tf("List.Count.Short{0}",e.results)),1),S("b",SE,Z(t.$tf("List.Count.Long{0}",e.results)),1)])):ie("",!0)]))},RE={class:"cb-page-setup cb-spacer-top"},kE={class:"cb-flex"},PE={__name:"cb-list-header",props:{filterUrl:{type:String,required:!0},sortingUrl:{type:String,required:!0},queryCountUrl:{type:String,required:!0}},setup(e){const{state:t}=Ye("cb-pagination"),{get:n,set:i}=Ye("cb-query-parameters"),r=te({get:()=>n("filter"),set(o){i("filter",o)}}),s=te({get:()=>n("sorting"),set(o){i("sorting",o)}});return(o,a)=>(I(),O("div",RE,[Q(D(tE),{modelValue:r.value,"onUpdate:modelValue":a[0]||(a[0]=l=>r.value=l),skeleton:!D(t).hasLoaded,url:e.filterUrl,"query-count-url":e.queryCountUrl},null,8,["modelValue","skeleton","url","query-count-url"]),S("div",kE,[Q(D(TE),{skeleton:!D(t).hasLoaded,results:D(t).totalResults},null,8,["skeleton","results"]),Q(D(bE),{modelValue:s.value,"onUpdate:modelValue":a[1]||(a[1]=l=>s.value=l),skeleton:!D(t).hasLoaded,results:D(t).totalResults,url:e.sortingUrl},null,8,["modelValue","skeleton","results","url"]),Me(o.$slots,"controls")])]))}},IE={__name:"cb-alert",props:{danger:{type:Boolean,default:!1},info:{type:Boolean,default:!1},success:{type:Boolean,default:!1}},setup(e){const t=e,n=te(()=>({"cb--plate-invalid":t.danger,"cb--plate-valid":t.success,"cb--plate-info":t.info}));return(i,r)=>(I(),O("div",{class:ve(["cb-page-message",n.value]),role:"alert"},[S("div",null,[Me(i.$slots,"default")])],2))}},ME=IE,LE={__name:"cb-list-error",setup(e){const{state:t}=Ye("cb-pagination");return(n,i)=>D(t).error?(I(),ce(D(ME),{key:0,invalid:!0},{default:ye(()=>[i[0]||(i[0]=S("span",{class:"cb-icon-aws cb--triangle-exclamation"},null,-1)),je(" "+Z(n.$t("List.Error.Message")),1)]),_:1})):ie("",!0)}},FE={key:0,class:"cb-placeholder cb--icon-top cb-spacer-top-xl"},OE={href:"javascript:void(0);"},DE={__name:"cb-list-no-results",setup(e){const{state:t}=Ye("cb-pagination"),{clear:n}=Ye("cb-query-parameters");return(i,r)=>D(t).hasLoaded&&D(t).items.length===0?(I(),O("div",FE,[r[1]||(r[1]=S("div",{class:"cb-text-muted"},[S("span",{class:"cb-icon-aws cb--face-sad-tear"}," ")],-1)),r[2]||(r[2]=S("p",null," ",-1)),S("h2",null,Z(i.$t("List.NoResults.Header")),1),r[3]||(r[3]=S("p",null," ",-1)),S("p",null,Z(i.$t("List.NoResults.Info")),1),S("p",null,[S("span",{onClick:r[0]||(r[0]=(...s)=>D(n)&&D(n)(...s))},[S("a",OE,[S("b",null,Z(i.$t("List.Search.Clear")),1)])])])])):ie("",!0)}},UE=gr(DE,[["__scopeId","data-v-b9f3cd71"]]);wh(`
h2[data-v-b9f3cd71] {
        text-align: center;
}
`);const BE={key:0,class:"cb-placeholder cb--icon-top cb-spacer-top-md"},zE={class:"cb-text-muted cb-text-small"},jE={__name:"cb-list-no-more-results",setup(e){const{state:t}=Ye("cb-pagination");return(n,i)=>D(t).hasLoaded&&D(t).items.length>0&&D(t).items.length>=D(t).totalResults?(I(),O("div",BE,[i[0]||(i[0]=S("div",{class:"cb-text-muted"},[S("span",{class:"cb-icon-aws cb--mountains"})],-1)),S("p",zE,Z(n.$t("List.End.Reach")),1)])):ie("",!0)}},NE={baseURI:document.baseURI},GE={class:"cb-list-loader"},VE={__name:"cb-list-loader",setup(e){const{state:t,fetchNextPage:n}=Ye("cb-pagination"),i=le(null),r=te(()=>!t.hasLoaded&&!t.isLoading||t.items.length<t.totalResults);return We(async()=>{new IntersectionObserver(async s=>{r.value&&s[0].isIntersecting&&await n()}).observe(i.value)}),(s,o)=>(I(),O("div",GE,[D(t).items.length>0&&r.value?(I(),ce(D(dr),{key:0,loading:D(t).isLoading,disabled:D(t).isLoading,onClick:D(n)},{default:ye(()=>[je(Z(s.$t("List.LoadMore")),1)]),_:1},8,["loading","disabled","onClick"])):ie("",!0),yt(S("span",{ref_key:"loader",ref:i,class:"cb-list-loader-virtual"}," ",512),[[Ft,r.value]])]))}},$E=gr(VE,[["__scopeId","data-v-f72fe5dd"]]);wh(`
.cb-list-loader[data-v-f72fe5dd] {
        position: relative;
        text-align: center;
        padding: 10px;
}
.cb-list-loader-virtual[data-v-f72fe5dd] {
        position: absolute;
        height: 600px;
        top: -600px;
        left: 0;
        width: 100%;
        pointer-events: none;
}
`);const qE={__name:"cb-list",props:{pageUrl:{type:String,required:!0},filterUrl:{type:String,required:!0},sortingUrl:{type:String,required:!0},queryCountUrl:{type:String,required:!0},pageSize:{type:Number,default:10},queryParameters:{type:Object,default:()=>({})}},emits:["update:queryParameters"],setup(e,{emit:t}){const n=e,i=t,r=te({get:()=>n.queryParameters,set(a){i("update:queryParameters",a)}}),s=function(a){const l=function(){const c={};return{on:(u,h)=>{(c[u]??(c[u]=[])).push(h)},off:(u,h)=>{c[u]=(c[u]??(c[u]=[])).filter(p=>p!==h)},emit:async(u,...h)=>{for(const p of c[u]??[])await p(...h)}}}();return Re(a,async()=>{await l.emit("watch")},{deep:!0}),{all:Bt(a.value),get:c=>a.value[c]??"",set:(c,u)=>{a.value[c]=u},clear:()=>{for(const c of Object.keys(a.value))a.value[c]=""},sync:c=>{for(const[u,h]of Object.entries(a.value))h?c.searchParams.set(u,h):c.searchParams.delete(u)},on:(c,u)=>{l.on(c,u)}}}(r);(function(a,l){const c={...NE,...a},u={assigning:!1};window.addEventListener("popstate",h=>{u.assigning=!0;for(const[p]of Object.entries(l.all))l.set(p,h.state?h.state[p]??"":"");setTimeout(()=>u.assigning=!1,0)}),l.on("watch",async()=>{if(u.assigning)return;const h=new URL(c.baseURI);l.sync(h),history.pushState({...l.all},"",h)}),We(()=>{history.replaceState({...l.all},"",null)})})({baseURI:document.baseURI},s);const o=Pw({url:n.pageUrl,pageSize:n.pageSize},s);return zn("cb-pagination",o),zn("cb-query-parameters",s),(a,l)=>(I(),O(be,null,[Q(D(PE),{"filter-url":e.filterUrl,"sorting-url":e.sortingUrl,"query-count-url":e.queryCountUrl},{controls:ye(()=>[Me(a.$slots,"controls")]),_:3},8,["filter-url","sorting-url","query-count-url"]),Q(D(LE)),S("div",null,[S("div",null,[(I(!0),O(be,null,Qe(D(o).state.items,c=>Me(a.$slots,"item",{key:c.id,item:c})),128)),Q(D($E)),Q(D(UE)),Q(D(jE))])])],64))}},XE=qE,WE={class:"vgo-list-item"},YE={class:"vgo-list-item__inner"},ZE={class:"vgo-list-item__description"},HE={class:"vgo-list-item__title"},KE=["innerHTML"],QE=["href"],JE={key:1,class:"vgo-list-item__extra"},eC=["aria-label"],tC={class:"vgo-text"},nC={key:1,class:"vgo-list-item__extra--location"},iC={class:"vgo-text vgo-text-short"},rC={class:"vgo-text vgo-text-long"},oC=["href"],sC={class:"vgo-item__introduction--read-more"},aC={key:0,class:"vgo-list-item__action"},lC={__name:"cb-product-list-item-large-content",props:{product:{type:Object,required:!0}},emits:["showOnMap","showReviews","showProduct"],setup(e,{emit:t}){const n=e,i=t,r=te(()=>n.product.rating||n.product.location||n.product.coordinates);return(s,o)=>(I(),O("div",WE,[S("div",YE,[Q(D(bh),{images:e.product.images},{default:ye(()=>[Q(D(yh),{badges:e.product.badges},null,8,["badges"])]),_:1},8,["images"]),S("div",ZE,[S("div",HE,[e.product.prepend?(I(),O("div",{key:0,class:"vgo-list-item__title--prepend",innerHTML:e.product.prepend},null,8,KE)):ie("",!0),S("h2",null,[S("a",{href:e.product.url,onClick:o[0]||(o[0]=a=>i("showProduct",a))},Z(e.product.name),9,QE)]),r.value?(I(),O("div",JE,[S("div",null,[e.product.rating?(I(),O("span",{key:0,class:"vgo-list-item__extra--rating",role:"button",tabindex:"0","aria-label":s.$t("List.Show.Reviews"),onClick:o[1]||(o[1]=a=>i("showReviews",e.product)),onKeydown:[o[2]||(o[2]=zi(St(a=>i("showReviews",e.product),["prevent","stop"]),["enter"])),o[3]||(o[3]=zi(St(a=>i("showReviews",e.product),["prevent","stop"]),["space"]))]},[Q(D(xh),{rating:e.product.rating},null,8,["rating"]),S("span",tC,Z(s.$tf("List.Count.Reviews{0}",e.product.reviewCount)),1)],40,eC)):ie("",!0),e.product.location?(I(),O("span",nC,Z(e.product.location),1)):ie("",!0),e.product.coordinates?(I(),O("a",{key:2,class:"vgo-list-item__extra--map",href:"javascript:void(0);",onClick:o[4]||(o[4]=a=>i("showOnMap",e.product.coordinates))},[o[6]||(o[6]=S("span",{class:"cb-icon-aws cb-icon-aws--stronger cb--location-dot"},null,-1)),S("span",iC,Z(s.$t("List.ShowOnMap.Short")),1),S("span",rC,Z(s.$t("List.ShowOnMap.Long")),1)])):ie("",!0)])])):ie("",!0)]),S("a",{href:e.product.url,class:"vgo-list-item__introduction",onClick:o[5]||(o[5]=a=>i("showProduct",a))},[S("p",null,Z(e.product.introduction),1),S("div",sC,[S("span",null,Z(s.$t("List.ReadMore")),1),o[7]||(o[7]=S("span",{class:"cb-icon-aws cb-icon-aws--stronger cb--chevron-right"},[S("span"),je(" ")],-1))])],8,oC),Q(D(_h),{attributes:e.product.attributes},null,8,["attributes"])]),s.$slots.action?(I(),O("div",aC,[Me(s.$slots,"action")])):ie("",!0)])]))}},cC={class:"vgo-list-item"},uC=ei({},[["render",function(e,t){return I(),O("div",cC,t[0]||(t[0]=[Qo('<div class="vgo-list-item__inner"><div class="vgo-gallery"><div class="cb-photo cb-photo--ph"></div></div><div class="vgo-list-item__description"><div class="vgo-list-item__title"><h2><span class="cb-text-ph" style="width:120px;"> </span></h2><div class="vgo-list-item__extra"><span class="cb-text-ph" style="width:150px;"> </span></div></div><div class="vgo-list-item__introduction"><p><span class="cb-text-ph ph-lg" style="width:70%;"> </span><span class="cb-text-ph ph-lg" style="width:60%;"> </span></p><div class="vgo-item__introduction--read-more"><span class="cb-text-ph ph-lg" style="width:100px;"> </span></div></div></div></div>',1)]))}]]),hC={__name:"cb-product-list-item-large",props:{product:{type:Object,required:!0}},emits:["showOnMap","showReviews","showProduct"],setup(e,{emit:t}){const n=t;return(i,r)=>e.product.isLoading?(I(),ce(uC,{key:0})):(I(),ce(lC,{key:1,product:e.product,onShowOnMap:r[0]||(r[0]=s=>n("showOnMap",s)),onShowReviews:r[1]||(r[1]=s=>n("showReviews",s)),onShowProduct:r[2]||(r[2]=s=>n("showProduct",s))},{action:ye(()=>[Me(i.$slots,"action",{},void 0,!0)]),_:3},8,["product"]))}},dC=ei(hC,[["__scopeId","data-v-c8aa1a87"]]);yo(`/* Shared */
[data-v-c8aa1a87]  {
    font-family: var(--vg-body-font-family);
    font-size: var(--vg-body-font-size);
    font-weight: var(--vg-body-font-weight);
    line-height: var(--vg-body-line-height);
    letter-spacing: var(--vg-body-letter-spacing);
    border-radius: var(--vg-card-all-border-radius);
    border: var(--vg-card-border-width) solid var(--vg-card-border-color);
    box-shadow: var(--vg-card-box-shadow);
    color: var(--vg-card-color);
    background-color: var(--vg-card-background);
    position: relative;
    container-type: inline-size;
}
[data-v-c8aa1a87]  * {margin: 0;}
[data-v-c8aa1a87]  h2 {
        font-family: var(--vg-h2-font-family);
        font-weight: var(--vg-h2-font-weight);
        line-height: var(--vg-h2-line-height);
        text-transform: var(--vg-h2-text-transform);
        letter-spacing: var(--vg-h2-letter-spacing);
        font-size: var(--vg-h2-small-dev-font-size);
}

/* Gallery */
[data-v-c8aa1a87]  .vgo-gallery {
        position: absolute;
        top: calc(-1 * var(--vg-card-border-width));
        left: calc(-1 * var(--vg-card-border-width));
        mix-blend-mode: multiply;
}
[data-v-c8aa1a87]  .vgo-gallery .cb-photo {
            position: absolute;
            inset: 0;
}

/* Title */
[data-v-c8aa1a87]  .vgo-list-item__title h2 a {
        color: currentColor;
        text-decoration: none;
}
[data-v-c8aa1a87]  .vgo-list-item__title--prepend {
        display: flex;
        align-items: center;
        column-gap: 7px;
        max-width: 100%;
        font-size: var(--vg-body-small-font-size);
        line-height: var(--vg-body-small-line-height);
        margin-bottom: 7px;
}
[data-v-c8aa1a87]  .vgo-list-item__title--prepend > * {font-size: 90%;}
[data-v-c8aa1a87]  .vgo-list-item__title--prepend > *:nth-child(2) {
            opacity: var(--vg-text-muted-opacity);
            display: -webkit-box;
            -webkit-box-orient: vertical;
            -webkit-line-clamp: 1;
            overflow: hidden;
}

/* Extra */
[data-v-c8aa1a87]  .vgo-list-item__extra {
        margin-top: 3px;
        font-size: var(--vg-body-small-font-size);
        line-height: var(--vg-body-small-line-height);
}
[data-v-c8aa1a87]  .vgo-list-item__extra > div {
            display: flex;
            flex-wrap: wrap;
            column-gap: 12px;
}
[data-v-c8aa1a87]  .vgo-list-item__extra > div > * {
                position: relative;
}
[data-v-c8aa1a87]  .vgo-list-item__extra > div > *:before:not(a) {
                    position: absolute;
                    left: -12px;
                    width: 12px;
                    text-align: center;
                    content: '·';
}
[data-v-c8aa1a87]  .vgo-list-item__extra--location {
        opacity: var(--vg-text-muted-opacity);
}
[data-v-c8aa1a87]  .vgo-list-item__extra--map {
        display: flex;
        align-items: center;
        gap: 5px;
        text-decoration: none;
        color: var(--vg-link-color);
}
[data-v-c8aa1a87]  .vgo-list-item__extra--map .vgo-text {
            text-decoration: var(--vg-link-text-decoration);
}
[data-v-c8aa1a87]  .vgo-list-item__extra--map .vgo-text:hover {
                text-decoration: var(--vg-link-text-decoration-hover);
}
[data-v-c8aa1a87]  .vgo-list-item__extra--rating {
        display: flex;
        flex-wrap: wrap;
        column-gap: 7px;
        cursor: pointer;
}
[data-v-c8aa1a87]  .vgo-list-item__extra--rating:hover .vgo-text {text-decoration: underline;}

/* Text */
[data-v-c8aa1a87]  .vgo-list-item__introduction {
        display: block;
        padding-top: 10px;
        font-family: var(--vg-description-font-family);
        font-size: var(--vg-description-small-font-size);
        line-height: var(--vg-description-line-height);
        text-decoration: none !important;
        color: currentColor;
}
[data-v-c8aa1a87]  .vgo-list-item__introduction p {
            display: -webkit-box;
            -webkit-box-orient: vertical;
            -webkit-line-clamp: 2;
            overflow: hidden;
}

/* Read more */
[data-v-c8aa1a87]  .vgo-list-item__introduction {
        position: relative;
}
[data-v-c8aa1a87]  .vgo-item__introduction--read-more {
        display: block;
        position: absolute;
        right: 0;
        bottom: 0;
        color: var(--vg-link-color);
        text-decoration: var(--vg-link-text-decoration);
        font-family: var(--vg-body-font-family);
        background-color: var(--vg-card-background);
        padding-left: 7px;
}
[data-v-c8aa1a87]  .vgo-item__introduction--read-more > * {
            font-size: var(--vg-body-small-font-size);
}
[data-v-c8aa1a87]  .vgo-item__introduction--read-more .cb-icon-aws {
            margin-left: 3px;
}
[data-v-c8aa1a87]  .vgo-list-item__introduction:hover .vgo-item__introduction--read-more {
        text-decoration: var(--vg-link-text-decoration-hover);
}

/* Action */
[data-v-c8aa1a87]  .vgo-list-item__action > div {
            padding-top: 15px;
            border-top: 1px solid var(--vg-card-inner-divider);
}

/* Attributes */
[data-v-c8aa1a87]  .cb-attributes {
        padding-top: 10px;
        font-size: var(--vg-body-small-font-size);
        line-height: var(--vg-body-small-line-height);
}
[data-v-c8aa1a87]  .cb-attributes > div {
            display: flex;
            flex-wrap: wrap;
            overflow: hidden;
            column-gap: 12px;
}
[data-v-c8aa1a87]  .cb-attributes > div > * {
                position: relative;
}
[data-v-c8aa1a87]  .cb-attributes > div > *:before {
                    position: absolute;
                    left: -12px;
                    width: 12px;
                    text-align: center;
                    content: '·';
}
[data-v-c8aa1a87]  .cb-attributes .cb-icon-aws {
            display: none;
}

/* Small */
@media (max-width: 699px) {
[data-v-c8aa1a87]  .vgo-list-item__inner {
            padding: calc(190px - var(--vg-card-border-width)) 20px 20px 20px;
}

        /* Gallery */
[data-v-c8aa1a87]  .vgo-gallery {
            right: calc(-1 * var(--vg-card-border-width));
            left: calc(-1 * var(--vg-card-border-width));
            border-radius: var(--vg-card-tl-border-radius) var(--vg-card-tr-border-radius) 0 0;
            height: 170px;
}

        /* Text */
[data-v-c8aa1a87]  .vgo-list-item__extra .vgo-text-long {
            display: none;
}

        /* Action */
[data-v-c8aa1a87]  .vgo-list-item__action {
            padding-top: 20px;
}
}

/* Large */
@media (min-width: 700px) {
[data-v-c8aa1a87]  .vgo-list-item__inner {
            padding: 20px 25px 20px calc(250px - var(--vg-card-border-width));
}

        /* Gallery */
[data-v-c8aa1a87]  .vgo-gallery {
            bottom: calc(-1 * var(--vg-card-border-width));
            border-radius: var(--vg-card-tl-border-radius) 0 0 var(--vg-card-bl-border-radius);
            width: 225px;
}

        /* Text */
[data-v-c8aa1a87]  .vgo-list-item__description {
            flex-grow: 1;
}
[data-v-c8aa1a87]  .vgo-list-item__extra .vgo-text-short {
            display: none;
}

        /* Action */
[data-v-c8aa1a87]  .vgo-list-item__action {
            padding-top: 25px;
}
[data-v-c8aa1a87]  .vgo-list-item__action .vgo-pricing__price {
                font-family: var(--vg-h2-font-family);
                font-weight: var(--vg-h2-font-weight);
                line-height: var(--vg-h2-line-height);
                text-transform: var(--vg-h2-text-transform);
                letter-spacing: var(--vg-h2-letter-spacing);
                font-size: var(--vg-h2-small-dev-font-size);
}

        /* Container */
@container (min-width: 750px) {
[data-v-c8aa1a87]  .vgo-list-item__inner {
                padding: 25px 30px 25px calc(330px - var(--vg-card-border-width));
}
[data-v-c8aa1a87]  .vgo-gallery {
                width: 300px;
}

            /* Text */
[data-v-c8aa1a87]  .vgo-list-item__introduction p {
                -webkit-line-clamp: 3;
}
}
@container (min-width: 1000px) {
[data-v-c8aa1a87]  .vgo-list-item__inner {
                padding: 30px 30px 30px calc(440px - var(--vg-card-border-width));
}
[data-v-c8aa1a87]  .vgo-gallery {
                width: 410px;
}

            /* Attributes */
[data-v-c8aa1a87]  .cb-attributes {
                padding-top: 15px;
}
[data-v-c8aa1a87]  .cb-attributes > div {
                    column-gap: 20px;
}
[data-v-c8aa1a87]  .cb-attributes > div > *::before {
                        display: none;
}
[data-v-c8aa1a87]  .cb-attributes .cb-label-attr {
                    display: flex;
                    flex-direction: column;
                    row-gap: 6px;
}
[data-v-c8aa1a87]  .cb-attributes .cb-icon-aws {
                    display: block;
                    margin: 0;
}
}
}

/* Small */
@media (max-width: 699px) {
div:has(> .vgo-list-item) {
        display: flex;
        flex-direction: column;
        gap: 15px;
        padding-top: 15px;
        margin: 0; /* todo delete - reset for old product wrapper */
}
}

/* Large */
@media (min-width: 699px) {
div:has(> .vgo-list-item) {
        display: flex;
        flex-direction: column;
        gap: 20px;
        padding-top: 20px;
        margin: 0; /* todo delete - reset for old product wrapper */
}
}`);const pC={class:"vgo-list-item"},gC={class:"vgo-list-item__inner"},fC={class:"vgo-list-item__title"},mC={class:"vgo-list-item__name"},vC=["href"],_C=["innerHTML"],yC={key:1,class:"vgo-list-item__extra"},bC={key:0,class:"vgo-list-item__extra--location"},xC={class:"vgo-text vgo-text-short"},wC={class:"vgo-text vgo-text-long"},EC=["aria-label"],CC={class:"vgo-text"},AC={class:"vgo-list-item__description"},SC={class:"vgo-list-item__introduction"},TC=["href"],RC={class:"vgo-item__introduction--read-more"},kC={key:0,class:"vgo-list-item__action"},PC={__name:"cb-product-list-item-medium-2-content",props:{product:{type:Object,required:!0},priceType:{type:String,default:"strike-through",validator:e=>$a.indexOf(e)!==-1}},emits:["showOnMap","showReviews","showProduct"],setup(e,{emit:t}){const n=e,i=t,r=te(()=>n.product.location||n.product.coordinates);return(s,o)=>(I(),O("div",pC,[S("div",gC,[S("div",fC,[S("div",mC,[S("h2",null,[S("a",{href:e.product.url,onClick:o[0]||(o[0]=a=>i("showProduct",a))},Z(e.product.name),9,vC)]),e.product.prepend?(I(),O("span",{key:0,class:"vgo-list-item__title--prepend",innerHTML:e.product.prepend},null,8,_C)):ie("",!0),r.value?(I(),O("div",yC,[e.product.location?(I(),O("span",bC,Z(e.product.location),1)):ie("",!0),e.product.coordinates?(I(),O("a",{key:1,class:"vgo-list-item__extra--map",href:"javascript:void(0);",onClick:o[1]||(o[1]=a=>i("showOnMap",e.product.coordinates))},[o[6]||(o[6]=S("span",{class:"cb-icon-aws cb-icon-aws--stronger cb--location-dot"},null,-1)),S("span",xC,Z(s.$t("List.ShowOnMap.Short")),1),S("span",wC,Z(s.$t("List.ShowOnMap.Long")),1)])):ie("",!0)])):ie("",!0)]),e.product.rating?(I(),O("div",{key:0,class:"vgo-list-item__rating",role:"button",tabindex:"0","aria-label":s.$t("List.Show.Reviews"),onClick:o[2]||(o[2]=a=>i("showReviews",e.product)),onKeydown:[o[3]||(o[3]=zi(St(a=>i("showReviews",e.product),["prevent","stop"]),["enter"])),o[4]||(o[4]=zi(St(a=>i("showReviews",e.product),["prevent","stop"]),["space"]))]},[Q(D(xh),{rating:e.product.rating},null,8,["rating"]),S("span",CC,Z(s.$tf("List.Count.Reviews{0}",e.product.reviewCount)),1)],40,EC)):ie("",!0)]),S("div",AC,[Q(D(bh),{images:e.product.images},{default:ye(()=>[Q(D(yh),{badges:e.product.badges},null,8,["badges"])]),_:1},8,["images"]),S("div",SC,[S("a",{href:e.product.url,onClick:o[5]||(o[5]=a=>i("showProduct",a))},[S("p",null,Z(e.product.introduction),1),S("div",RC,[S("span",null,Z(s.$t("List.ReadMore")),1),o[7]||(o[7]=S("span",{class:"cb-icon-aws cb-icon-aws--stronger cb--chevron-right"},[S("span"),je(" ")],-1))])],8,TC),Q(D(_h),{attributes:e.product.attributes},null,8,["attributes"])]),s.$slots.action?(I(),O("div",kC,[Me(s.$slots,"action")])):ie("",!0)])])]))}},IC={class:"vgo-list-item"},MC=ei({},[["render",function(e,t){return I(),O("div",IC,t[0]||(t[0]=[Qo('<div class="vgo-list-item__inner"><div class="vgo-list-item__title"><div class="vgo-list-item__name"><h2><span class="cb-text-ph" style="width:120px;"> </span></h2><div class="vgo-list-item__extra"><span class="cb-text-ph" style="width:150px;"> </span></div></div></div><div class="vgo-list-item__description"><div class="vgo-gallery"><div class="cb-photo cb-photo--ph"></div></div><div class="vgo-list-item__introduction"><span><p><span class="cb-text-ph ph-lg" style="width:90%;"> </span><span class="cb-text-ph ph-lg" style="width:100%;"> </span><span class="cb-text-ph ph-lg" style="width:80%;"> </span></p><div class="vgo-item__introduction--read-more"><span class="cb-text-ph ph-lg" style="width:100px;"> </span></div></span></div></div></div>',1)]))}]]),LC={__name:"cb-product-list-item-medium-2",props:{product:{type:Object,required:!0}},emits:["showOnMap","showReviews","showProduct"],setup(e,{emit:t}){const n=t;return(i,r)=>e.product.isLoading?(I(),ce(MC,{key:0})):(I(),ce(PC,{key:1,product:e.product,onShowOnMap:r[0]||(r[0]=s=>n("showOnMap",s)),onShowReviews:r[1]||(r[1]=s=>n("showReviews",s)),onShowProduct:r[2]||(r[2]=s=>n("showProduct",s))},{action:ye(()=>[Me(i.$slots,"action",{},void 0,!0)]),_:3},8,["product"]))}},FC=ei(LC,[["__scopeId","data-v-6f4945e2"]]);yo(`/* Shared */
[data-v-6f4945e2]  {
    font-family: var(--vg-body-font-family);
    font-size: var(--vg-body-font-size);
    font-weight: var(--vg-body-font-weight);
    line-height: var(--vg-body-line-height);
    letter-spacing: var(--vg-body-letter-spacing);
    border-radius: var(--vg-card-all-border-radius);
    border: var(--vg-card-border-width) solid var(--vg-card-border-color);
    box-shadow: var(--vg-card-box-shadow);
    color: var(--vg-card-color);
    background-color: var(--vg-card-background);
    position: relative;
    container-type: inline-size;
}
[data-v-6f4945e2]  * {margin: 0;}
[data-v-6f4945e2]  h2 {
        font-family: var(--vg-h2-font-family);
        font-weight: var(--vg-h2-font-weight);
        line-height: var(--vg-h2-line-height);
        text-transform: var(--vg-h2-text-transform);
        letter-spacing: var(--vg-h2-letter-spacing);
        font-size: var(--vg-h2-small-dev-font-size);
}

/* Container */
[data-v-6f4945e2]  .vgo-list-item__inner {
        display: flex;
        flex-direction: column;
        gap: 20px;
}
@container (max-width: 699px) {
[data-v-6f4945e2]  .vgo-list-item__inner {
            padding: 20px;
}
}
@container (min-width: 700px) {
[data-v-6f4945e2]  .vgo-list-item__inner {
            padding: 25px;
}
}

/* Title row */
[data-v-6f4945e2]  .vgo-list-item__title .vgo-list-item__name {
            flex-grow: 1;
}
[data-v-6f4945e2]  .vgo-list-item__title .vgo-list-item__name h2 {
                display: inline-block;
                margin: 0 7px 3px 0;
}
[data-v-6f4945e2]  .vgo-list-item__title .vgo-list-item__name h2 a {
                    color: currentColor;
                    text-decoration: none;
}
[data-v-6f4945e2]  .vgo-list-item__title .vgo-list-item__title--prepend {
            display: inline;
            align-items: center;
            font-size: var(--vg-body-small-font-size);
            line-height: var(--vg-body-small-line-height);
}
[data-v-6f4945e2]  .vgo-list-item__title .vgo-list-item__title--prepend > *:nth-child(2) {
                opacity: var(--vg-text-muted-opacity);
                display: -webkit-box;
                -webkit-box-orient: vertical;
                -webkit-line-clamp: 1;
                overflow: hidden;
}
[data-v-6f4945e2]  .vgo-list-item__title .vgo-list-item__extra {
            font-size: var(--vg-body-small-font-size);
            line-height: var(--vg-body-small-line-height);
            display: flex;
            column-gap: 10px;
}
[data-v-6f4945e2]  .vgo-list-item__title .vgo-list-item__extra > * {
                position: relative;
}
[data-v-6f4945e2]  .vgo-list-item__title .vgo-list-item__extra > *:before:not(a) {
                    position: absolute;
                    left: -12px;
                    width: 12px;
                    text-align: center;
                    content: '·';
}
[data-v-6f4945e2]  .vgo-list-item__title .vgo-list-item__extra--location {
            opacity: var(--vg-text-muted-opacity);
}
[data-v-6f4945e2]  .vgo-list-item__title .vgo-list-item__extra--map {
            display: flex;
            align-items: center;
            gap: 5px;
            text-decoration: none;
            color: var(--vg-link-color);
}
[data-v-6f4945e2]  .vgo-list-item__title .vgo-list-item__extra--map .vgo-text {
                text-decoration: var(--vg-link-text-decoration);
}
[data-v-6f4945e2]  .vgo-list-item__title .vgo-list-item__extra--map .vgo-text:hover {
                    text-decoration: var(--vg-link-text-decoration-hover);
}
[data-v-6f4945e2]  .vgo-list-item__title .vgo-list-item__rating {
            font-size: var(--vg-body-small-font-size);
            line-height: var(--vg-body-small-line-height);
            cursor: pointer;
}
[data-v-6f4945e2]  .vgo-list-item__title .vgo-list-item__rating:hover .vgo-text {text-decoration: underline;}
@container (max-width: 699px) {
[data-v-6f4945e2]  .vgo-list-item__title .vgo-list-item__extra .vgo-text-long {
                    display: none;
}
[data-v-6f4945e2]  .vgo-list-item__title .vgo-list-item__rating {
                display: flex;
                flex-wrap: wrap;
                column-gap: 7px;
}
}
@container (min-width: 700px) {
[data-v-6f4945e2]  .vgo-list-item__title {
            display: flex;
            gap: 20px;
}
[data-v-6f4945e2]  .vgo-list-item__title .vgo-list-item__extra .vgo-text-short {
                    display: none;
}
[data-v-6f4945e2]  .vgo-list-item__title .vgo-list-item__rating .cb-score-rating {
                    width: 128px;
                    height: calc(var(--vg-h2-small-dev-font-size) * var(--vg-h2-line-height));
                    margin-bottom: 3px;
}
[data-v-6f4945e2]  .vgo-list-item__title .vgo-list-item__rating .vgo-text {
                    display: block;
                    text-align: right;
}
}

/* Description row */
[data-v-6f4945e2]  .vgo-list-item__description {
        display: flex;
}
[data-v-6f4945e2]  .vgo-list-item__description .vgo-gallery {
            position: relative;
            border-radius: var(--vg-card-inner-border-radius);
}
[data-v-6f4945e2]  .vgo-list-item__description .vgo-gallery .cb-photo {
                position: absolute;
                inset: 0;
                border-radius: var(--vg-card-inner-border-radius);
}
[data-v-6f4945e2]  .vgo-list-item__description .vgo-list-item__introduction {
            display: flex;
            flex-direction: column;
            flex-grow: 1;
            gap: 15px;
}
[data-v-6f4945e2]  .vgo-list-item__description .vgo-list-item__introduction a {
                flex-grow: 1;
                text-decoration: none !important;
                color: currentColor;
}
[data-v-6f4945e2]  .vgo-list-item__description .vgo-list-item__introduction a:hover .vgo-item__introduction--read-more {
                        text-decoration: var(--vg-link-text-decoration-hover);
}
[data-v-6f4945e2]  .vgo-list-item__description .vgo-list-item__introduction p {
                display: -webkit-box;
                -webkit-box-orient: vertical;
                -webkit-line-clamp: 6;
                overflow: hidden;
                font-family: var(--vg-description-font-family);
                font-size: var(--vg-description-small-font-size);
                line-height: var(--vg-description-line-height);
}
[data-v-6f4945e2]  .vgo-list-item__description .vgo-list-item__introduction .vgo-item__introduction--read-more {
                display: inline-block;
                font-family: var(--vg-body-font-family);
                font-size: var(--vg-body-small-font-size);
                color: var(--vg-link-color);
                text-decoration: var(--vg-link-text-decoration);
}
[data-v-6f4945e2]  .vgo-list-item__description .vgo-list-item__introduction .vgo-item__introduction--read-more .cb-icon-aws {
                    margin-left: 3px;
}
[data-v-6f4945e2]  .vgo-list-item__description .vgo-list-item__introduction .cb-attributes {
                font-size: var(--vg-body-small-font-size);
                line-height: var(--vg-body-small-line-height);
}
[data-v-6f4945e2]  .vgo-list-item__description .vgo-list-item__introduction .cb-attributes > div {
                    display: grid;
                    grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
                    grid-column-gap: 10px;
                    grid-row-gap: 2px;
}
[data-v-6f4945e2]  .vgo-list-item__description .vgo-list-item__introduction .cb-attributes .cb-icon-aws {
                    font-size: 16px;
                    min-width: 18px;
                    margin-right: 8px;
}
[data-v-6f4945e2]  .vgo-list-item__description .vgo-list-item__action:empty {
                display: none;
}
@container (max-width: 699px) {
[data-v-6f4945e2]  .vgo-list-item__description {
            flex-direction: column;
            gap: 20px;
}
[data-v-6f4945e2]  .vgo-list-item__description .vgo-gallery {
                height: 220px;
}
[data-v-6f4945e2]  .vgo-list-item__description .vgo-list-item__action > div {
                    display: flex;
                    border-top: 1px solid var(--vg-card-inner-divider);
                    padding-top: 20px;
}
}
@container (min-width: 700px) {
[data-v-6f4945e2]  .vgo-list-item__description {
            gap: 25px;
}
[data-v-6f4945e2]  .vgo-list-item__description .vgo-gallery {
                min-width: 200px;
                max-width: 200px;
                min-height: 170px;
}
[data-v-6f4945e2]  .vgo-list-item__description .vgo-list-item__action {
                display: flex;
                flex-direction: column;
                justify-content: flex-end;
}
}
@container (min-width: 800px) {
[data-v-6f4945e2]  .vgo-list-item__description .vgo-gallery {
                min-width: 250px;
                max-width: 250px;
}
}
@container (min-width: 850px) {
[data-v-6f4945e2]  .vgo-list-item__description .vgo-gallery {
                min-width: 270px;
                max-width: 270px;
}
}

/* Accordion */
:is(:deep() :deep()) + .vgo-accordion-panel > div[data-v-6f4945e2] {
                border-radius: var(--vg-card-all-border-radius);
                border: var(--vg-card-border-width) solid var(--vg-card-border-color);
                box-shadow: var(--vg-card-box-shadow);
                color: var(--vg-card-color);
                background-color: var(--vg-card-background);
                container-type: inline-size;
}
@media (max-width: 699px) {
:is(:deep() :deep()) + .vgo-accordion-panel[data-v-6f4945e2] {
                padding-top: 15px;
}
:is(:deep() :deep()) + .vgo-accordion-panel > div[data-v-6f4945e2] {
                    margin-top: -15px;
                    padding: 20px;
}
}
@media (min-width: 700px) {
:is(:deep() :deep()) + .vgo-accordion-panel[data-v-6f4945e2] {
                padding-top: 20px;
}
:is(:deep() :deep()) + .vgo-accordion-panel > div[data-v-6f4945e2] {
                    margin-top: -20px;
                    padding: 30px;
}
}

/* List flex and gap */
@media (max-width: 699px) {
[data-v-6f4945e2]  :global(div:has(> .vgo-list-item)) {
            display: flex;
            flex-direction: column;
            gap: 15px;
            padding-top: 15px;
            margin: 0; /* todo delete - reset for old product wrapper */
}
}
@media (min-width: 700px) {
[data-v-6f4945e2]  :global(div:has(> .vgo-list-item)) {
            display: flex;
            flex-direction: column;
            gap: 20px;
            padding-top: 20px;
            margin: 0; /* todo delete - reset for old product wrapper */
}
}`);const OC={class:"vgo-list-item"},DC={class:"vgo-list-item__inner"},UC={class:"vgo-list-item__description"},BC={class:"vgo-list-item__title"},zC=["innerHTML"],jC=["href"],NC={key:1,class:"vgo-list-item__extra"},GC=["aria-label"],VC={class:"vgo-text"},$C={key:1,class:"vgo-list-item__extra--location"},qC={class:"vgo-text vgo-text-short"},XC={class:"vgo-text vgo-text-long"},WC=["href"],YC={class:"vgo-item__introduction--read-more"},ZC={key:0,class:"vgo-list-item__action"},HC={__name:"cb-product-list-item-medium-content",props:{product:{type:Object,required:!0}},emits:["showOnMap","showReviews","showProduct"],setup(e,{emit:t}){const n=e,i=t,r=te(()=>n.product.rating||n.product.location||n.product.coordinates);return(s,o)=>(I(),O("div",OC,[S("div",DC,[Q(D(bh),{images:e.product.images},{default:ye(()=>[Q(D(yh),{badges:e.product.badges},null,8,["badges"])]),_:1},8,["images"]),S("div",UC,[S("div",BC,[e.product.prepend?(I(),O("div",{key:0,class:"vgo-list-item__title--prepend",innerHTML:e.product.prepend},null,8,zC)):ie("",!0),S("h2",null,[S("a",{href:e.product.url,onClick:o[0]||(o[0]=a=>i("showProduct",a))},Z(e.product.name),9,jC)]),r.value?(I(),O("div",NC,[S("div",null,[e.product.rating?(I(),O("span",{key:0,class:"vgo-list-item__extra--rating",role:"button",tabindex:"0","aria-label":s.$t("List.Show.Reviews"),onClick:o[1]||(o[1]=a=>i("showReviews",e.product)),onKeydown:[o[2]||(o[2]=zi(St(a=>i("showReviews",e.product),["prevent","stop"]),["enter"])),o[3]||(o[3]=zi(St(a=>i("showReviews",e.product),["prevent","stop"]),["space"]))]},[Q(D(xh),{rating:e.product.rating},null,8,["rating"]),S("span",VC,Z(s.$tf("List.Count.Reviews{0}",e.product.reviewCount)),1)],40,GC)):ie("",!0),e.product.location?(I(),O("span",$C,Z(e.product.location),1)):ie("",!0),e.product.coordinates?(I(),O("a",{key:2,class:"vgo-list-item__extra--map",href:"javascript:void(0);",onClick:o[4]||(o[4]=a=>i("showOnMap",e.product.coordinates))},[o[6]||(o[6]=S("span",{class:"cb-icon-aws cb-icon-aws--stronger cb--location-dot"},null,-1)),S("span",qC,Z(s.$t("List.ShowOnMap.Short")),1),S("span",XC,Z(s.$t("List.ShowOnMap.Long")),1)])):ie("",!0)])])):ie("",!0)]),S("a",{href:e.product.url,class:"vgo-list-item__introduction",onClick:o[5]||(o[5]=a=>i("showProduct",a))},[S("p",null,Z(e.product.introduction),1),S("div",YC,[S("span",null,Z(s.$t("List.ReadMore")),1),o[7]||(o[7]=S("span",{class:"cb-icon-aws cb-icon-aws--stronger cb--chevron-right"},[S("span"),je(" ")],-1))])],8,WC),Q(D(_h),{attributes:e.product.attributes},null,8,["attributes"])]),s.$slots.action?(I(),O("div",ZC,[Me(s.$slots,"action")])):ie("",!0)])]))}},KC={class:"vgo-list-item"},QC=ei({},[["render",function(e,t){return I(),O("div",KC,t[0]||(t[0]=[Qo('<div class="vgo-list-item__inner"><div class="vgo-gallery"><div class="cb-photo cb-photo--ph"></div></div><div class="vgo-list-item__description"><div class="vgo-list-item__title"><h2><span class="cb-text-ph" style="width:120px;"> </span></h2><div class="vgo-list-item__extra"><span class="cb-text-ph" style="width:150px;"> </span></div></div><div class="vgo-list-item__introduction"><p><span class="cb-text-ph ph-lg" style="width:70%;"> </span><span class="cb-text-ph ph-lg" style="width:60%;"> </span></p><div class="vgo-item__introduction--read-more"><span class="cb-text-ph ph-lg" style="width:100px;"> </span></div></div></div></div>',1)]))}]]),JC={__name:"cb-product-list-item-medium",props:{product:{type:Object,required:!0}},emits:["showOnMap","showReviews","showProduct"],setup(e,{emit:t}){const n=t;return(i,r)=>e.product.isLoading?(I(),ce(QC,{key:0})):(I(),ce(HC,{key:1,product:e.product,onShowOnMap:r[0]||(r[0]=s=>n("showOnMap",s)),onShowReviews:r[1]||(r[1]=s=>n("showReviews",s)),onShowProduct:r[2]||(r[2]=s=>n("showProduct",s))},{action:ye(()=>[Me(i.$slots,"action",{},void 0,!0)]),_:3},8,["product"]))}},eA=ei(JC,[["__scopeId","data-v-c26cf456"]]);yo(`/* Shared */
[data-v-c26cf456]  {
    font-family: var(--vg-body-font-family);
    font-size: var(--vg-body-font-size);
    font-weight: var(--vg-body-font-weight);
    line-height: var(--vg-body-line-height);
    letter-spacing: var(--vg-body-letter-spacing);
    border-radius: var(--vg-card-all-border-radius);
    border: var(--vg-card-border-width) solid var(--vg-card-border-color);
    box-shadow: var(--vg-card-box-shadow);
    color: var(--vg-card-color);
    background-color: var(--vg-card-background);
    position: relative;
    container-type: inline-size;
}
[data-v-c26cf456]  * {margin: 0;}
[data-v-c26cf456]  h2 {
        font-family: var(--vg-h2-font-family);
        font-weight: var(--vg-h2-font-weight);
        line-height: var(--vg-h2-line-height);
        text-transform: var(--vg-h2-text-transform);
        letter-spacing: var(--vg-h2-letter-spacing);
        font-size: var(--vg-h2-small-dev-font-size);
}

/* Gallery */
[data-v-c26cf456]  .vgo-gallery {
        position: absolute;
        top: calc(-1 * var(--vg-card-border-width));
        left: calc(-1 * var(--vg-card-border-width));
        mix-blend-mode: multiply;
}
[data-v-c26cf456]  .vgo-gallery .cb-photo {
            position: absolute;
            inset: 0;
}

/* Title */
[data-v-c26cf456]  .vgo-list-item__title h2 a {
        color: currentColor;
        text-decoration: none;
}
[data-v-c26cf456]  .vgo-list-item__title--prepend {
        display: flex;
        align-items: center;
        column-gap: 7px;
        max-width: 100%;
        font-size: var(--vg-body-small-font-size);
        line-height: var(--vg-body-small-line-height);
        margin-bottom: 7px;
}
[data-v-c26cf456]  .vgo-list-item__title--prepend > * {font-size: 90%;}
[data-v-c26cf456]  .vgo-list-item__title--prepend > *:nth-child(2) {
            opacity: var(--vg-text-muted-opacity);
            display: -webkit-box;
            -webkit-box-orient: vertical;
            -webkit-line-clamp: 1;
            overflow: hidden;
}

/* Extra */
[data-v-c26cf456]  .vgo-list-item__extra {
        margin-top: 3px;
        font-size: var(--vg-body-small-font-size);
        line-height: var(--vg-body-small-line-height);
}
[data-v-c26cf456]  .vgo-list-item__extra > div {
            display: flex;
            flex-wrap: wrap;
            column-gap: 12px;
}
[data-v-c26cf456]  .vgo-list-item__extra > div > * {
                position: relative;
}
[data-v-c26cf456]  .vgo-list-item__extra > div > *:before:not(a) {
                    position: absolute;
                    left: -12px;
                    width: 12px;
                    text-align: center;
                    content: '·';
}
[data-v-c26cf456]  .vgo-list-item__extra .vgo-text-long {
            display: none;
}
[data-v-c26cf456]  .vgo-list-item__extra--location {
        opacity: var(--vg-text-muted-opacity);
}
[data-v-c26cf456]  .vgo-list-item__extra--map {
        display: flex;
        align-items: center;
        gap: 5px;
        text-decoration: none;
        color: var(--vg-link-color);
}
[data-v-c26cf456]  .vgo-list-item__extra--map .vgo-text {
            text-decoration: var(--vg-link-text-decoration);
}
[data-v-c26cf456]  .vgo-list-item__extra--map .vgo-text:hover {
                text-decoration: var(--vg-link-text-decoration-hover);
}
[data-v-c26cf456]  .vgo-list-item__extra--rating {
        display: flex;
        flex-wrap: wrap;
        column-gap: 7px;
        cursor: pointer;
}
[data-v-c26cf456]  .vgo-list-item__extra--rating:hover .vgo-text {text-decoration: underline;}

/* Text */
[data-v-c26cf456]  .vgo-list-item__introduction {
        display: block;
        padding-top: 10px;
        font-family: var(--vg-description-font-family);
        font-size: var(--vg-description-small-font-size);
        line-height: var(--vg-description-line-height);
        text-decoration: none !important;
        color: currentColor;
}
[data-v-c26cf456]  .vgo-list-item__introduction p {
            display: -webkit-box;
            -webkit-box-orient: vertical;
            -webkit-line-clamp: 2;
            overflow: hidden;
}

/* Read more */
[data-v-c26cf456]  .vgo-item__introduction--read-more {
        display: inline-block;
        font-family: var(--vg-body-font-family);
        font-size: var(--vg-body-small-font-size);
        color: var(--vg-link-color);
        text-decoration: var(--vg-link-text-decoration);
}
[data-v-c26cf456]  .vgo-item__introduction--read-more .cb-icon-aws {
            margin-left: 3px;
}
[data-v-c26cf456]  .vgo-list-item__introduction:hover .vgo-item__introduction--read-more {
        text-decoration: var(--vg-link-text-decoration-hover);
}

/* Action */
[data-v-c26cf456]  .vgo-list-item__action:empty {
            display: none;
}

/* Attributes */
[data-v-c26cf456]  .cb-attributes {
        padding-top: 10px;
        font-size: var(--vg-body-small-font-size);
        line-height: var(--vg-body-small-line-height);
}
[data-v-c26cf456]  .cb-attributes > div {
            display: flex;
            flex-wrap: wrap;
            overflow: hidden;
            column-gap: 12px;
}
[data-v-c26cf456]  .cb-attributes > div > * {
                position: relative;
}
[data-v-c26cf456]  .cb-attributes > div > *:before {
                    position: absolute;
                    left: -12px;
                    width: 12px;
                    text-align: center;
                    content: '·';
}
[data-v-c26cf456]  .cb-attributes .cb-icon-aws {
            display: none;
}

/* Small */
@media (max-width: 699px) {
[data-v-c26cf456]  .vgo-list-item__inner {
            padding: calc(190px - var(--vg-card-border-width)) 20px 20px 20px;
}

        /* Gallery */
[data-v-c26cf456]  .vgo-gallery {
            right: calc(-1 * var(--vg-card-border-width));
            left: calc(-1 * var(--vg-card-border-width));
            border-radius: var(--vg-card-tl-border-radius) var(--vg-card-tr-border-radius) 0 0;
            height: 170px;
}

        /* Action */
[data-v-c26cf456]  .vgo-list-item__action {
            padding-top: 20px;
}
[data-v-c26cf456]  .vgo-list-item__action > div {
                border-top: 1px solid var(--vg-card-inner-divider);
                padding-top: 20px;
}
}

/* Large */
@media (min-width: 700px) {
[data-v-c26cf456]  .vgo-list-item__inner {
            padding: 20px 25px 20px calc(175px - var(--vg-card-border-width));
            display: flex;
            gap: 20px;
}

        /* Gallery */
[data-v-c26cf456]  .vgo-gallery {
            bottom: calc(-1 * var(--vg-card-border-width));
            border-radius: var(--vg-card-tl-border-radius) 0 0 var(--vg-card-bl-border-radius);
            width: 150px;
}

        /* Text */
[data-v-c26cf456]  .vgo-list-item__description {
            flex-grow: 1;
            display: flex;
            flex-direction: column;
}

        /* Attributes */
[data-v-c26cf456]  .cb-attributes {
            flex-grow: 1;
            display: flex;
            flex-direction: column;
            justify-content: flex-end;
}

        /* Action */
[data-v-c26cf456]  .vgo-list-item__action {
            display: flex;
            flex-direction: column;
            justify-content: flex-end;
}

        /* Container */
@container (min-width: 700px) {
[data-v-c26cf456]  .vgo-list-item__inner {
                padding: 25px 25px 25px calc(245px - var(--vg-card-border-width));
}
[data-v-c26cf456]  .vgo-gallery {
                width: 220px;
}
}
@container (min-width: 1000px) {
[data-v-c26cf456]  .vgo-list-item__inner {
                padding: 25px 30px 25px calc(250px - var(--vg-card-border-width));
}
[data-v-c26cf456]  .vgo-list-item__extra .vgo-text-short {
                display: none;
}
[data-v-c26cf456]  .vgo-list-item__extra .vgo-text-long {
                display: inline;
}
}
}

/* Accordion */
[data-v-c26cf456]  + .vgo-accordion-panel > div {
            border-radius: var(--vg-card-all-border-radius);
            border: var(--vg-card-border-width) solid var(--vg-card-border-color);
            box-shadow: var(--vg-card-box-shadow);
            color: var(--vg-card-color);
            background-color: var(--vg-card-background);
            container-type: inline-size;
}
@media (max-width: 699px) {
[data-v-c26cf456]  + .vgo-accordion-panel {
            padding-top: 15px;
}
[data-v-c26cf456]  + .vgo-accordion-panel > div {
                margin-top: -15px;
                padding: 20px;
}
}
@media (min-width: 700px) {
[data-v-c26cf456]  + .vgo-accordion-panel {
            padding-top: 20px;
}
[data-v-c26cf456]  + .vgo-accordion-panel > div {
                margin-top: -20px;
                padding: 30px;
}
}

/* List flex and gap */
@media (max-width: 699px) {
div:has(> .vgo-list-item) {
        display: flex;
        flex-direction: column;
        gap: 15px;
        padding-top: 15px;
        margin: 0; /* todo delete - reset for old product wrapper */
}
}
@media (min-width: 700px) {
div:has(> .vgo-list-item) {
        display: flex;
        flex-direction: column;
        gap: 20px;
        padding-top: 20px;
        margin: 0; /* todo delete - reset for old product wrapper */
}
}


`);const tA=["medium","medium2","large"],nA=e=>{switch(e){case"medium":return eA;case"medium2":return FC;case"large":return dC;default:return null}},iA={__name:"cb-button-link",props:{href:{type:String,required:!0},secondary:{type:Boolean},active:{type:Boolean},iconOnly:{type:Boolean},size:{type:String,default:null,validator:e=>!e||["small","large"].indexOf(e)!==-1}},setup(e){const t=le(!1),n=le(!1),i=()=>{t.value=!0,n.value=!0};return window.addEventListener("pagehide",()=>{t.value=!1,n.value=!1}),(r,s)=>(I(),ce(D(gw),{href:e.href,loading:t.value,disabled:n.value,secondary:e.secondary,active:e.active,"icon-only":e.iconOnly,size:e.size,onClick:i},{default:ye(()=>[Me(r.$slots,"default")]),_:3},8,["href","loading","disabled","secondary","active","icon-only","size"]))}},rA=iA,oA={key:0,class:"vgo-item-action__icons"},sA={__name:"cb-product-list-item-action-icons",props:{icons:{type:Array,default:()=>[]}},setup:e=>(t,n)=>e.icons.length>0?(I(),O("div",oA,[(I(!0),O(be,null,Qe(e.icons,(i,r)=>(I(),O("span",{key:r,class:ve(i)},n[0]||(n[0]=[S("span",null,null,-1)]),2))),128))])):ie("",!0)},aA=ei(sA,[["__scopeId","data-v-e1c6e38a"]]);yo(`
.vgo-item-action__icons[data-v-e1c6e38a] {
        display: flex;
}
.vgo-item-action__icons .cb-icon-aws[data-v-e1c6e38a] {
            font-size: 16px;
            display: flex;
}
.vgo-item-action__icons .cb-icon-aws:not(:last-child) > span[data-v-e1c6e38a] {
                display: inline-block;
                padding: 0 3px;
                text-align: center;
}
.vgo-item-action__icons .cb-icon-aws:not(:last-child) > span[data-v-e1c6e38a]::before {
                    content: '+';}
`);const lA={class:"vgo-item-action"},cA={class:"vgo-item-action__wrapper"},uA={class:"vgo-text-short"},hA={class:"vgo-text-long"},dA={__name:"cb-product-list-item-action-link",props:{product:{type:Object,required:!0},priceType:{type:String,default:"strike-through",validator:e=>$a.indexOf(e)!==-1},icons:{type:Array,default:()=>[]}},emits:["click"],setup(e,{emit:t}){const n=e,i=t,r=Nt(),s=te(()=>n.product.isBookable?r.proxy.$t("List.Book.Short"):r.proxy.$t("List.Show.Short")),o=te(()=>n.product.isBookable?r.proxy.$t("List.Book.Long"):r.proxy.$t("List.Show.Long")),a={priceFrom:r.proxy.$t("List.Price.From"),discount:r.proxy.$t("List.Price.Discount"),priceOriginal:r.proxy.$t("List.Price.Original")};return(l,c)=>(I(),O("div",lA,[S("div",cA,[Q(D(aA),{icons:e.icons},null,8,["icons"]),Q(D(Sw),{price:e.product.pricing,type:e.priceType,translations:a},null,8,["price","type"]),Q(D(rA),{class:"cb-test-list-choose-button",href:e.product.url,onClick:c[0]||(c[0]=u=>i("click",u))},{default:ye(()=>[S("span",uA,Z(s.value),1),S("span",hA,Z(o.value),1)]),_:1},8,["href"])])]))}},Fm=ei(dA,[["__scopeId","data-v-62e5436d"]]);yo(`.vgo-item-action[data-v-62e5436d] {
    container-type: inline-size;
    flex-grow: 1;
    display: flex;
    min-width: 200px;
}
@container (max-width: 240px) {
[data-v-62e5436d]  .vgo-item-action__wrapper {
            flex-grow: 1;
            display: flex;
            flex-direction: column;
            text-align: right;
            padding-left: 20px; /* 180px width */
}
[data-v-62e5436d]  .vgo-pricing {
            flex-grow: 1;
            margin-bottom: 15px;
}
[data-v-62e5436d]  .vgo-pricing__main {
            justify-content: flex-end;
}
[data-v-62e5436d]  .vgo-pricing__price span {
            display: inline-block;
}
[data-v-62e5436d]  .vgo-pricing__price span:last-child {
                font-family: var(--vg-h2-font-family);
                font-weight: var(--vg-h2-font-weight);
                line-height: var(--vg-h2-line-height);
                text-transform: var(--vg-h2-text-transform);
                letter-spacing: var(--vg-h2-letter-spacing);
                font-size: var(--vg-h2-small-dev-font-size);
}
[data-v-62e5436d]  .vgo-pricing__definition {
            font-size: var(--vg-body-small-font-size);
            line-height: var(--vg-body-small-line-height);
}
[data-v-62e5436d]  .cb-btn .vgo-text-short {display: none;}
[data-v-62e5436d]  .cb-btn .vgo-text-long {display: inline;}

        /* Boxed with icons */
[data-v-62e5436d]  .vgo-item-action__wrapper:has(> .vgo-item-action__icons) {
            border: 1px solid var(--vg-card-inner-divider);
            border-radius: var(--vg-card-inner-border-radius);
            padding: 20px;
            text-align: center;
            width: 200px;
}
[data-v-62e5436d]  .vgo-item-action__wrapper:has(> .vgo-item-action__icons) .vgo-item-action__icons {
                justify-content: center;
                margin-bottom: 5px;
}
[data-v-62e5436d]  .vgo-item-action__wrapper:has(> .vgo-item-action__icons) .vgo-pricing__main {
                justify-content: center;
}
[data-v-62e5436d]  .vgo-item-action__wrapper:has(> .vgo-item-action__icons) .cb-btn .vgo-text-short {display: inline;}
[data-v-62e5436d]  .vgo-item-action__wrapper:has(> .vgo-item-action__icons) .cb-btn .vgo-text-long {display: none;}
}
@container (min-width: 240px) {
[data-v-62e5436d]  .vgo-item-action__wrapper {
            width: 100%;
            flex-grow: 1;
            display: flex;
            align-items: center;
            gap: 15px;
}
[data-v-62e5436d]  .vgo-item-action__icons {
            display: none;
}
[data-v-62e5436d]  .vgo-pricing {
            flex-grow: 1;
}
[data-v-62e5436d]  .vgo-pricing__definition {
            display: inline-block;
            font-size: var(--vg-body-small-font-size);
            line-height: var(--vg-body-small-line-height);
}
[data-v-62e5436d]  .cb-btn .vgo-text-short {display: inline;}
[data-v-62e5436d]  .cb-btn .vgo-text-long {display: none;}
}`);const pA={__name:"cb-product-list",props:{pageUrl:{type:String,required:!0},filterUrl:{type:String,required:!0},sortingUrl:{type:String,required:!0},queryCountUrl:{type:String,required:!0},pageSize:{type:Number,default:10},queryParameters:{type:Object,default:()=>({})},layout:{type:String,default:"medium",validator:e=>tA.indexOf(e)!==-1},priceType:{type:String,default:"strike-through",validator:e=>$a.indexOf(e)!==-1}},emits:["update:queryParameters","showOnMap","showReviews","showProduct","click"],setup(e,{emit:t}){const n=t;return(i,r)=>(I(),ce(D(XE),{"page-url":e.pageUrl,"filter-url":e.filterUrl,"sorting-url":e.sortingUrl,"query-count-url":e.queryCountUrl,"page-size":e.pageSize,"query-parameters":e.queryParameters,"onUpdate:queryParameters":r[4]||(r[4]=s=>n("update:queryParameters",s))},{item:ye(({item:s})=>[(I(),ce(ai(D(nA)(e.layout)),{product:s,onShowOnMap:r[1]||(r[1]=o=>n("showOnMap",o)),onShowReviews:r[2]||(r[2]=o=>n("showReviews",o)),onShowProduct:r[3]||(r[3]=o=>n("showProduct",o))},{action:ye(()=>[Me(i.$slots,"action",{item:s},()=>[Q(Fm,{product:s,"price-type":e.priceType,onClick:r[0]||(r[0]=o=>n("click",o))},null,8,["product","price-type"])])]),_:2},1064,["product"]))]),controls:ye(()=>[Me(i.$slots,"controls")]),_:3},8,["page-url","filter-url","sorting-url","query-count-url","page-size","query-parameters"]))}},gA=pA,Om={fit:!0},kh="none",Ph="half",Ih="full";function fA(e,t,n,i=kh){const r=le(i),s=le(!1),o=le(!0),a=async()=>{e.value.classList.remove("cb--map"),e.value.classList.remove("cb--cnt-compact"),e.value.classList.remove("cb--map-fullscreen"),document.body.classList.remove("cb-body-fullwidth"),r.value=kh},l=async p=>{const f={...Om,...p},m=u();e.value.classList.add("cb--map"),e.value.classList.add("cb--cnt-compact"),e.value.classList.remove("cb--map-fullscreen"),document.body.classList.add("cb-body-fullwidth"),await new Promise(requestAnimationFrame),await new Promise(requestAnimationFrame),f.fit&&!m&&n.value.fit(),r.value=Ph},c=async p=>{const f={...Om,...p},m=u();e.value.classList.add("cb--map"),e.value.classList.add("cb--cnt-compact"),e.value.classList.add("cb--map-fullscreen"),document.body.classList.add("cb-body-fullwidth"),await new Promise(requestAnimationFrame),await new Promise(requestAnimationFrame),f.fit&&!m&&n.value.fit(),n.value.focus(),r.value=Ih},u=()=>{var p,f,m;return!!((p=t.value)!=null&&p.offsetWidth||(f=t.value)!=null&&f.offsetHeight||(m=t.value)!=null&&m.getClientRects().length)},h={[kh]:a,[Ph]:l,[Ih]:c};return Re(r,()=>{s.value=r.value===Ih,o.value=r.value===Ph},{immediate:!0}),We(async()=>await(async()=>{await h[r.value]({fit:!1}),document.addEventListener("keydown",p=>{p.key==="Escape"&&s.value&&l()})})()),{none:a,half:l,full:c,isFull:s,isHalf:o,go:async p=>{u()?n.value.go(p[0],p[1],12,200):(n.value.go(p[0],p[1],12),await c({fit:!1}))}}}const mA={class:"cb-canvas-tools"},vA=["title"],_A=["title"],yA={__name:"cb-canvas-tools",setup(e){const{full:t,half:n}=Ye("cb-map");return(i,r)=>(I(),O("div",mA,[S("div",null,[S("a",{href:"javascript:void(0);",class:"cb-btn cb-btn-sm cb-btn-icon-only cb--expand",title:i.$t("List.Map.Expand"),tabindex:"0",onClick:r[0]||(r[0]=(...s)=>D(t)&&D(t)(...s))},r[2]||(r[2]=[S("span",{class:"cb-icon-aws cb-icon-aws--strong cb--arrows-maximize"},null,-1)]),8,vA),S("a",{href:"javascript:void(0);",class:"cb-btn cb-btn-sm cb--shrink",title:i.$t("List.Map.Shrink"),tabindex:"0",onClick:r[1]||(r[1]=(...s)=>D(n)&&D(n)(...s))},[r[3]||(r[3]=S("span",{class:"cb-icon-aws cb-icon-aws--strong cb--arrows-minimize"},null,-1)),je(" "+Z(i.$t("List.Map.Shrink")),1)],8,_A)])]))}},bA=yA,xA={class:"cb-loader-custom",role:"status"},wA={__name:"cb-loader",props:{loading:{type:Boolean}},setup:e=>(t,n)=>yt((I(),O("i",xA,n[0]||(n[0]=[S("i",null,[S("i"),S("i"),S("i"),S("i"),S("i")],-1)]),512)),[[Ft,e.loading]])},EA=wA,CA={__name:"cb-button",props:{secondary:{type:Boolean},loading:{type:Boolean},active:{type:Boolean},disabled:{type:Boolean},iconOnly:{type:Boolean},size:{type:String,default:null,validator:e=>!e||["small","large"].indexOf(e)!==-1}},emits:["click"],setup(e,{emit:t}){const n=e,i=t,r=te(()=>({"cb-btn":!0,"cb-btn-primary":!n.secondary,"cb-btn-secondary":n.secondary,"cb-btn-sm":n.size==="small","cb-btn-lg":n.size==="large","cb-btn-icon-only":n.iconOnly,"cb-loading-custom":n.loading,"cb-active":n.active,"cb-disabled":n.disabled})),s=o=>{n.disabled||i("click",o)};return(o,a)=>(I(),O("a",{class:ve([r.value]),href:"javascript:void(0)",onClick:s},[S("span",null,[Me(o.$slots,"default")]),Q(D(EA),{loading:e.loading},null,8,["loading"])],2))}},AA=CA,SA=["disabled"],TA={__name:"cb-toggle",props:{modelValue:{type:Boolean,required:!0},size:{type:String,default:null,validator:e=>!e||["large"].includes(e)},disabled:{type:Boolean}},emits:["update:modelValue"],setup(e,{emit:t}){const n=e,i=t,r=Nd(),s=te(()=>!!r.default),o=te({get:()=>n.modelValue,set(l){i("update:modelValue",l)}}),a=te(()=>({"cb-custom-control-lg":n.size==="large"}));return(l,c)=>(I(),O("label",{class:ve(["cb-custom-control","cb-custom-toggle",a.value]),onClick:c[1]||(c[1]=St(()=>{},["stop"]))},[yt(S("input",{"onUpdate:modelValue":c[0]||(c[0]=u=>o.value=u),type:"checkbox",role:"switch",disabled:e.disabled},null,8,SA),[[Vp,o.value]]),S("span",null,[c[2]||(c[2]=S("span",{class:"cb-indicator"},[S("span")],-1)),S("span",{class:ve({"cb-text":s.value})},[Me(l.$slots,"default")],2)])],2))}},RA=TA,kA={class:"cb-item cb-item--maptoggle cb-hide-sm"},PA={class:"cb-text-small cb-text-muted"},IA={class:"cb-item cb-hide-lg"},MA={__name:"cb-list-controls",setup(e){const{full:t,half:n,none:i,isFull:r,isHalf:s}=Ye("cb-map"),o=te({get:()=>r.value||s.value,set:a=>a?n():i()});return(a,l)=>(I(),O("div",null,[S("div",kA,[S("div",PA,Z(a.$t("List.Map.Show")),1),Q(D(RA),{modelValue:o.value,"onUpdate:modelValue":l[0]||(l[0]=c=>o.value=c),size:"large"},null,8,["modelValue"])]),S("div",IA,[Q(D(AA),{onClick:D(t)},{default:ye(()=>[l[1]||(l[1]=S("span",{class:"cb-icon-aws cb-icon-aws--stronger cb--location-dot"},null,-1)),je("  "+Z(a.$t("List.Map.Show")),1)]),_:1},8,["onClick"])])]))}},LA=MA,FA={key:0},OA={class:"cb-page-maintitle"},DA={class:"cb-description"},UA={class:"cb-title"},BA={key:0,class:"cb-intro"},zA={key:0},jA=["innerHTML"],NA={key:1},GA={__name:"cb-page-title",props:{description:{type:String,default:null},subtitle:{type:String,default:null},title:{type:String,default:null}},setup:e=>(t,n)=>e.title||e.description||e.subtitle?(I(),O("div",FA,[S("div",OA,[S("div",null,[S("div",DA,[S("div",UA,[S("div",null,[S("h1",null,Z(e.title),1)])]),e.description||e.subtitle?(I(),O("div",BA,[e.description?(I(),O("p",zA,[S("span",{innerHTML:e.description},null,8,jA)])):ie("",!0),e.subtitle?(I(),O("p",NA,[S("b",null,Z(e.subtitle)+".",1)])):ie("",!0)])):ie("",!0)])])]),n[0]||(n[0]=S("div",{class:"cb-spacer-top-xl-partial"},null,-1))])):ie("",!0)},VA=GA,$A={key:0,class:"cb-map"},qA={class:"cb-page-inner"},XA={class:"cb-page-section"},WA={__name:"App",props:{filter:{type:String,required:!0},sorting:{type:String,required:!1,default:""},pageUrl:{type:String,required:!0},filterUrl:{type:String,required:!0},sortingUrl:{type:String,required:!0},queryCountUrl:{type:String,required:!0},rasterUrl:{type:String,required:!0},mapAttributions:{type:String,default:null},productsExtentUrl:{type:String,required:!0},productsUrl:{type:String,required:!0},productUrl:{type:String,required:!0},poisExtentUrl:{type:String,required:!0},poisUrl:{type:String,required:!0},poiUrl:{type:String,required:!0},colors:{type:String,required:!0},description:{type:String,default:null},useMap:{type:Boolean,default:!1},translations:{type:String,required:!0}},setup(e){const t=e,n=Nt(),i=JSON.parse(Zp.decode(t.translations));n.proxy.$st(i);const r=JSON.parse(Zp.decode(t.colors)),s=le(null),o=le(null),a=le(null),l=t.useMap?"half":"none",c=fA(s,a,o,l),u=le({filter:t.filter,sorting:t.sorting}),h=function(){const f=Xe({});return{invoked:f,load:(m,_)=>{if(f[_])return;let y=document.getElementById(_);if(y||(y=document.createElement("div"),y.id=_,document.body.appendChild(y)),y.hasAttribute("invoked"))return;const x=document.createElement("script");x.type="text/javascript",x.async=!0,x.setAttribute("src",m),y.appendChild(x),y.setAttribute("invoked",""),f[_]=!0}}}(),p=f=>{h.invoked[f.guestReviewsWidgetContainerId]?document.getElementById(f.guestReviewsWidgetContainerId).toggle():h.load(f.guestReviewsWidgetUrl,f.guestReviewsWidgetContainerId)};return zn("cb-translation-prefix","Package"),zn("cb-map",c),(f,m)=>(I(),O("div",{ref_key:"page",ref:s,class:"cb-page-new"},[e.useMap?(I(),O("div",$A,[Q(D(bA)),S("div",{ref_key:"canvas",ref:a,class:"cb-canvas"},[Q(D(X1),{ref_key:"map",ref:o,"query-parameters":u.value,"onUpdate:queryParameters":m[0]||(m[0]=_=>u.value=_),"raster-url":e.rasterUrl,attributions:e.mapAttributions,"products-extent-url":e.productsExtentUrl,"products-url":e.productsUrl,"product-url":e.productUrl,"pois-extent-url":e.poisExtentUrl,"pois-url":e.poisUrl,"poi-url":e.poiUrl,colors:D(r)},null,8,["query-parameters","raster-url","attributions","products-extent-url","products-url","product-url","pois-extent-url","pois-url","poi-url","colors"])],512)])):ie("",!0),S("div",qA,[S("div",XA,[S("div",null,[Q(D(VA),{description:e.description,title:f.$t("Package.List.Header")},null,8,["description","title"]),Q(D(gA),{"query-parameters":u.value,"onUpdate:queryParameters":m[1]||(m[1]=_=>u.value=_),"page-url":e.pageUrl,"filter-url":e.filterUrl,"sorting-url":e.sortingUrl,"query-count-url":e.queryCountUrl,layout:"large",onShowOnMap:D(c).go,onShowReviews:p},{action:ye(({item:_})=>[Q(D(Fm),{product:_,"price-type":f.priceType,icons:_.icons},null,8,["product","price-type","icons"])]),controls:ye(()=>[e.useMap?(I(),ce(D(LA),{key:0})):ie("",!0)]),_:1},8,["query-parameters","page-url","filter-url","sorting-url","query-count-url","onShowOnMap"]),Q(D(O_),{class:"cb-text-center"})])])])],512))}},Dm=document.querySelector("#cb-package-list");((...e)=>{const t=(Xp||(Xp=e_(A_))).createApp(...e),{mount:n}=t;return t.mount=i=>{const r=function(a){return Ne(a)?document.querySelector(a):a}(i);if(!r)return;const s=t._component;pe(s)||s.render||s.template||(s.template=r.innerHTML),r.nodeType===1&&(r.textContent="");const o=n(r,!1,function(a){if(a instanceof SVGElement)return"svg";if(typeof MathMLElement=="function"&&a instanceof MathMLElement)return"mathml"}(r));return r instanceof Element&&(r.removeAttribute("v-cloak"),r.setAttribute("data-v-app","")),o},t})(WA,{...Dm.dataset}).use(M_).mount(`#${Dm.id}`)})();
