PageSourceSearch

https://brik.id/_nuxt/entry.8caca9db.js

js brik.id collected 2026-10-08 12:06:25 UTC 2,143,512 bytes, 1,439 lines download raw bytes

vendor: 16,465 bytes, line 1
1var s6=Object.defineProperty;var l6=(e,t,n)=>t in e?s6(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n;var Oy=(e,t,n)=>(l6(e,typeof t!="symbol"?t+"":t,n),n),iT=(e,t,n)=>{if(!t.has(e))throw TypeError("Cannot "+n)};var pi=(e,t,n)=>(iT(e,t,"read from private field"),n?n.call(e):t.get(e)),Oa=(e,t,n)=>{if(t.has(e))throw TypeError("Cannot add the same private member more than once");t instanceof WeakSet?t.add(e):t.set(e,n)},sl=(e,t,n,r)=>(iT(e,t,"write to private field"),r?r.call(e,n):t.set(e,n),n);var vc=(e,t,n)=>(iT(e,t,"access private method"),n);function HC(e,t){const n=Object.create(null),r=e.split(",");for(let i=0;i<r.length;i++)n[r[i]]=!0;return t?i=>!!n[i.toLowerCase()]:i=>!!n[i]}const ro={},Dm=[],Ac=()=>{},c6=()=>!1,u6=/^on[^a-z]/,yv=e=>u6.test(e),YC=e=>e.startsWith("onUpdate:"),Go=Object.assign,ZC=(e,t)=>{const n=e.indexOf(t);n>-1&&e.splice(n,1)},h6=Object.prototype.hasOwnProperty,Yr=(e,t)=>h6.call(e,t),Gn=Array.isArray,Lm=e=>bg(e)==="[object Map]",$x=e=>bg(e)==="[object Set]",YM=e=>bg(e)==="[object Date]",d6=e=>bg(e)==="[object RegExp]",yr=e=>typeof e=="function",fo=e=>typeof e=="string",P_=e=>typeof e=="symbol",Fi=e=>e!==null&&typeof e=="object",XC=e=>Fi(e)&&yr(e.then)&&yr(e.catch),SF=Object.prototype.toString,bg=e=>SF.call(e),f6=e=>bg(e).slice(8,-1),CF=e=>bg(e)==="[object Object]",KC=e=>fo(e)&&e!=="NaN"&&e[0]!=="-"&&""+parseInt(e,10)===e,c_=HC(",key,ref,ref_for,ref_key,onVnodeBeforeMount,onVnodeMounted,onVnodeBeforeUpdate,onVnodeUpdated,onVnodeBeforeUnmount,onVnodeUnmounted"),jx=e=>{const t=Object.create(null);return n=>t[n]||(t[n]=e(n))},p6=/-(\w)/g,Pc=jx(e=>e.replace(p6,(t,n)=>n?n.toUpperCase():"")),m6=/\B([A-Z])/g,bp=jx(e=>e.replace(m6,"-$1").toLowerCase()),_v=jx(e=>e.charAt(0).toUpperCase()+e.slice(1)),vb=jx(e=>e?`on${_v(e)}`:""),M_=(e,t)=>!Object.is(e,t),Rm=(e,t)=>{for(let n=0;n<e.length;n++)e[n](t)},Vb=(e,t,n)=>{Object.defineProperty(e,t,{configurable:!0,enumerable:!1,value:n})},kF=e=>{const t=parseFloat(e);return isNaN(t)?e:t},AF=e=>{const t=fo(e)?Number(e):NaN;return isNaN(t)?e:t};let ZM;const DE=()=>ZM||(ZM=typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:typeof global<"u"?global:{});function Sa(e){if(Gn(e)){const t={};for(let n=0;n<e.length;n++){const r=e[n],i=fo(r)?v6(r):Sa(r);if(i)for(const s in i)t[s]=i[s]}return t}else{if(fo(e))return e;if(Fi(e))return e}}const g6=/;(?![^(]*\))/g,y6=/:([^]+)/,_6=/\/\*[^]*?\*\//g;function v6(e){const t={};return e.replace(_6,"").split(g6).forEach(n=>{if(n){const r=n.split(y6);r.length>1&&(t[r[0].trim()]=r[1].trim())}}),t}function qr(e){let t="";if(fo(e))t=e;else if(Gn(e))for(let n=0;n<e.length;n++){const r=qr(e[n]);r&&(t+=r+" ")}else if(Fi(e))for(const n in e)e[n]&&(t+=n+" ");return t.trim()}function ys(e){if(!e)return null;let{class:t,style:n}=e;return t&&!fo(t)&&(e.class=qr(t)),n&&(e.style=Sa(n)),e}const b6="itemscope,allowfullscreen,formnovalidate,ismap,nomodule,novalidate,readonly",x6=HC(b6);function PF(e){return!!e||e===""}function w6(e,t){if(e.length!==t.length)return!1;let n=!0;for(let r=0;n&&r<e.length;r++)n=Ux(e[r],t[r]);return n}function Ux(e,t){if(e===t)return!0;let n=YM(e),r=YM(t);if(n||r)return n&&r?e.getTime()===t.getTime():!1;if(n=P_(e),r=P_(t),n||r)return e===t;if(n=Gn(e),r=Gn(t),n||r)return n&&r?w6(e,t):!1;if(n=Fi(e),r=Fi(t),n||r){if(!n||!r)return!1;const i=Object.keys(e).length,s=Object.keys(t).length;if(i!==s)return!1;for(const c in e){const a=e.hasOwnProperty(c),m=t.hasOwnProperty(c);if(a&&!m||!a&&m||!Ux(e[c],t[c]))return!1}}return String(e)===String(t)}function T6(e,t){return e.findIndex(n=>Ux(n,t))}const Ba=e=>fo(e)?e:e==null?"":Gn(e)||Fi(e)&&(e.toString===SF||!yr(e.toString))?JSON.stringify(e,MF,2):String(e),MF=(e,t)=>t&&t.__v_isRef?MF(e,t.value):Lm(t)?{[`Map(${t.size})`]:[...t.entries()].reduce((n,[r,i])=>(n[`${r} =>`]=i,n),{})}:$x(t)?{[`Set(${t.size})`]:[...t.values()]}:Fi(t)&&!Gn(t)&&!CF(t)?String(t):t;let cl;class IF{constructor(t=!1){this.detached=t,this._active=!0,this.effects=[],this.cleanups=[],this.parent=cl,!t&&cl&&(this.index=(cl.scopes||(cl.scopes=[])).push(this)-1)}get active(){return this._active}run(t){if(this._active){const n=cl;try{return cl=this,t()}finally{cl=n}}}on(){cl=this}off(){cl=this.parent}stop(t){if(this._active){let n,r;for(n=0,r=this.effects.length;n<r;n++)this.effects[n].stop();for(n=0,r=this.cleanups.length;n<r;n++)this.cleanups[n]();if(this.scopes)for(n=0,r=this.scopes.length;n<r;n++)this.scopes[n].stop(!0);if(!this.detached&&this.parent&&!t){const i=this.parent.scopes.pop();i&&i!==this&&(this.parent.scopes[this.index]=i,i.index=this.index)}this.parent=void 0,this._active=!1}}}function xg(e){return new IF(e)}function E6(e,t=cl){t&&t.active&&t.effects.push(e)}function QC(){return cl}function $s(e){cl&&cl.cleanups.push(e)}const JC=e=>{const t=new Set(e);return t.w=0,t.n=0,t},OF=e=>(e.w&wd)>0,DF=e=>(e.n&wd)>0,S6=({deps:e})=>{if(e.length)for(let t=0;t<e.length;t++)e[t].w|=wd},C6=e=>{const{deps:t}=e;if(t.length){let n=0;for(let r=0;r<t.length;r++){const i=t[r];OF(i)&&!DF(i)?i.delete(e):t[n++]=i,i.w&=~wd,i.n&=~wd}t.length=n}},Gb=new WeakMap;let t_=0,wd=1;const LE=30;let Tc;const tp=Symbol(""),RE=Symbol("");class ek{constructor(t,n=null,r){this.fn=t,this.scheduler=n,this.active=!0,this.deps=[],this.parent=void 0,E6(this,r)}run(){if(!this.active)return this.fn();let t=Tc,n=hd;for(;t;){if(t===this)return;t=t.parent}try{return this.parent=Tc,Tc=this,hd=!0,wd=1<<++t_,t_<=LE?S6(this):XM(this),this.fn()}finally{t_<=LE&&C6(this),wd=1<<--t_,Tc=this.parent,hd=n,this.parent=void 0,this.deferStop&&this.stop()}}stop(){Tc===this?this.deferStop=!0:this.active&&(XM(this),this.onStop&&this.onStop(),this.active=!1)}}function XM(e){const{deps:t}=e;if(t.length){for(let n=0;n<t.length;n++)t[n].delete(e);t.length=0}}let hd=!0;const LF=[];function wg(){LF.push(hd),hd=!1}function Tg(){const e=LF.pop();hd=e===void 0?!0:e}function js(e,t,n){if(hd&&Tc){let r=Gb.get(e);r||Gb.set(e,r=new Map);let i=r.get(n);i||r.set(n,i=JC()),RF(i)}}function RF(e,t){let n=!1;t_<=LE?DF(e)||(e.n|=wd,n=!OF(e)):n=!e.has(Tc),n&&(e.add(Tc),Tc.deps.push(e))}function th(e,t,n,r,i,s){const c=Gb.get(e);if(!c)return;let a=[];if(t==="clear")a=[...c.values()];else if(n==="length"&&Gn(e)){const m=Number(r);c.forEach((g,x)=>{(x==="length"||x>=m)&&a.push(g)})}else switch(n!==void 0&&a.push(c.get(n)),t){case"add":Gn(e)?KC(n)&&a.push(c.get("length")):(a.push(c.get(tp)),Lm(e)&&a.push(c.get(RE)));break;case"delete":Gn(e)||(a.push(c.get(tp)),Lm(e)&&a.push(c.get(RE)));break;case"set":Lm(e)&&a.push(c.get(tp));break}if(a.length===1)a[0]&&FE(a[0]);else{const m=[];for(const g of a)g&&m.push(...g);FE(JC(m))}}function FE(e,t){const n=Gn(e)?e:[...e];for(const r of n)r.computed&&KM(r);for(const r of n)r.computed||KM(r)}function KM(e,t){(e!==Tc||e.allowRecurse)&&(e.scheduler?e.scheduler():e.run())}function k6(e,t){var n;return(n=Gb.get(e))==null?void 0:n.get(t)}const A6=HC("__proto__,__v_isRef,__isVue"),FF=new Set(Object.getOwnPropertyNames(Symbol).filter(e=>e!=="arguments"&&e!=="caller").map(e=>Symbol[e]).filter(P_)),P6=tk(),M6=tk(!1,!0),I6=tk(!0),QM=O6();function O6(){const e={};return["includes","indexOf","lastIndexOf"].forEach(t=>{e[t]=function(...n){const r=Ar(this);for(let s=0,c=this.length;s<c;s++)js(r,"get",s+"");const i=r[t](...n);return i===-1||i===!1?r[t](...n.map(Ar)):i}}),["push","pop","shift","unshift","splice"].forEach(t=>{e[t]=function(...n){wg();const r=Ar(this)[t].apply(this,n);return Tg(),r}}),e}function D6(e){const t=Ar(this);return js(t,"has",e),t.hasOwnProperty(e)}function tk(e=!1,t=!1){return function(r,i,s){if(i==="__v_isReactive")return!e;if(i==="__v_isReadonly")return e;if(i==="__v_isShallow")return t;if(i==="__v_raw"&&s===(e?t?Z6:jF:t?$F:NF).get(r))return r;const c=Gn(r);if(!e){if(c&&Yr(QM,i))return Reflect.get(QM,i,s);if(i==="hasOwnProperty")return D6}const a=Reflect.get(r,i,s);return(P_(i)?FF.has(i):A6(i))||(e||js(r,"get",i),t)?a:Ai(a)?c&&KC(i)?a:a.value:Fi(a)?e?bv(a):so(a):a}}const L6=BF(),R6=BF(!0);function BF(e=!1){return function(n,r,i,s){let c=n[r];if(pp(c)&&Ai(c)&&!Ai(i))return!1;if(!e&&(!qb(i)&&!pp(i)&&(c=Ar(c),i=Ar(i)),!Gn(n)&&Ai(c)&&!Ai(i)))return c.value=i,!0;const a=Gn(n)&&KC(r)?Number(r)<n.length:Yr(n,r),m=Reflect.set(n,r,i,s);return n===Ar(s)&&(a?M_(i,c)&&th(n,"set",r,i):th(n,"add",r,i)),m}}function F6(e,t){const n=Yr(e,t);e[t];const r=Reflect.deleteProperty(e,t);return r&&n&&th(e,"delete",t,void 0),r}function B6(e,t){const n=Reflect.has(e,t);return(!P_(t)||!FF.has(t))&&js(e,"has",t),n}function z6(e){return js(e,"iterate",Gn(e)?"length":tp),Reflect.ownKeys(e)}const zF={get:P6,set:L6,deleteProperty:F6,has:B6,ownKeys:z6},N6={get:I6,set(e,t){return!0},deleteProperty(e,t){return!0}},$6=Go({},zF,{get:M6,set:R6}),nk=e=>e,Vx=e=>Reflect.getPrototypeOf(e);function j0(e,t,n=!1,r=!1){e=e.__v_raw;const i=Ar(e),s=Ar(t);n||(t!==s&&js(i,"get",t),js(i,"get",s));const{has:c}=Vx(i),a=r?nk:n?ok:I_;if(c.call(i,t))return a(e.get(t));if(c.call(i,s))return a(e.get(s));e!==i&&e.get(t)}function U0(e,t=!1){const n=this.__v_raw,r=Ar(n),i=Ar(e);return t||(e!==i&&js(r,"has",e),js(r,"has",i)),e===i?n.has(e):n.has(e)||n.has(i)}function V0(e,t=!1){return e=e.__v_raw,!t&&js(Ar(e),"iterate",tp),Reflect.get(e,"size",e)}function JM(e){e=Ar(e);const t=Ar(this);return Vx(t).has.call(t,e)||(t.add(e),th(t,"add",e,e)),this}function eI(e,t){t=Ar(t);const n=Ar(this),{has:r,get:i}=Vx(n);let s=r.call(n,e);s||(e=Ar(e),s=r.call(n,e));const c=i.call(n,e);return n.set(e,t),s?M_(t,c)&&th(n,"set",e,t):th(n,"add",e,t),this}function tI(e){const t=Ar(this),{has:n,get:r}=Vx(t);let i=n.call(t,e);i||(e=Ar(e),i=n.call(t,e)),r&&r.call(t,e);const s=t.delete(e);return i&&th(t,"delete",e,void 0),s}function nI(){const e=Ar(this),t=e.size!==0,n=e.clear();return t&&th(e,"clear",void 0,void 0),n}function G0(e,t){return function(r,i){const s=this,c=s.__v_raw,a=Ar(c),m=t?nk:e?ok:I_;return!e&&js(a,"iterate",tp),c.forEach((g,x)=>r.call(i,m(g),m(x),s))}}function q0(e,t,n){return function(...r){const i=this.__v_raw,s=Ar(i),c=Lm(s),a=e==="entries"||e===Symbol.iterator&&c,m=e==="keys"&&c,g=i[e](...r),x=n?nk:t?ok:I_;return!t&&js(s,"iterate",m?RE:tp),{next(){const{value:T,done:C}=g.next();return C?{value:T,done:C}:{value:a?[x(T[0]),x(T[1])]:x(T),done:C}},[Symbol.iterator](){return this}}}}function $h(e){return function(...t){return e==="delete"?!1:this}}function j6(){const e={get(s){return j0(this,s)},get size(){return V0(this)},has:U0,add:JM,set:eI,delete:tI,clear:nI,forEach:G0(!1,!1)},t={get(s){return j0(this,s,!1,!0)},get size(){return V0(this)},has:U0,add:JM,set:eI,delete:tI,clear:nI,forEach:G0(!1,!0)},n={get(s){return j0(this,s,!0)},get size(){return V0(this,!0)},has(s){return U0.call(this,s,!0)},add:$h("add"),set:$h("set"),delete:$h("delete"),clear:$h("clear"),forEach:G0(!0,!1)},r={get(s){return j0(this,s,!0,!0)},get size(){return V0(this,!0)},has(s){return U0.call(this,s,!0)},add:$h("add"),set:$h("set"),delete:$h("delete"),clear:$h("clear"),forEach:G0(!0,!0)};return["keys","values","entries",Symbol.iterator].forEach(s=>{e[s]=q0(s,!1,!1),n[s]=q0(s,!0,!1),t[s]=q0(s,!1,!0),r[s]=q0(s,!0,!0)}),[e,n,t,r]}const[U6,V6,G6,q6]=j6();function rk(e,t){const n=t?e?q6:G6:e?V6:U6;return(r,i,s)=>i==="__v_isReactive"?!e:i==="__v_isReadonly"?e:i==="__v_raw"?r:Reflect.get(Yr(n,i)&&i in r?n:r,i,s)}const W6={get:rk(!1,!1)},H6={get:rk(!1,!0)},Y6={get:rk(!0,!1)},NF=new WeakMap,$F=new WeakMap,jF=new WeakMap,Z6=new WeakMap;function X6(e){switch(e){case"Object":case"Array":return 1;case"Map":case"Set":case"WeakMap":case"WeakSet":return 2;default:return 0}}function K6(e){return e.__v_skip||!Object.isExtensible(e)?0:X6(f6(e))}function so(e){return pp(e)?e:ik(e,!1,zF,W6,NF)}function vv(e){return ik(e,!1,$6,H6,$F)}function bv(e){return ik(e,!0,N6,Y6,jF)}function ik(e,t,n,r,i){if(!Fi(e)||e.__v_raw&&!(t&&e.__v_isReactive))return e;const s=i.get(e);if(s)return s;const c=K6(e);if(c===0)return e;const a=new Proxy(e,c===2?r:n);return i.set(e,a),a}function dd(e){return pp(e)?dd(e.__v_raw):!!(e&&e.__v_isReactive)}function pp(e){return!!(e&&e.__v_isReadonly)}function qb(e){return!!(e&&e.__v_isShallow)}function UF(e){return dd(e)||pp(e)}function Ar(e){const t=e&&e.__v_raw;return t?Ar(t):e}function xv(e){return Vb(e,"__v_skip",!0),e}const I_=e=>Fi(e)?so(e):e,ok=e=>Fi(e)?bv(e):e;function VF(e){hd&&Tc&&(e=Ar(e),RF(e.dep||(e.dep=JC())))}function GF(e,t){e=Ar(e);const n=e.dep;n&&FE(n)}function Ai(e){return!!(e&&e.__v_isRef===!0)}function jt(e){return qF(e,!1)}function ua(e){return qF(e,!0)}function qF(e,t){return Ai(e)?e:new Q6(e,t)}class Q6{constructor(t,n){this.__v_isShallow=n,this.dep=void 0,this.__v_isRef=!0,this._rawValue=n?t:Ar(t),this._value=n?t:I_(t)}get value(){return VF(this),this._value}set value(t){const n=this.__v_isShallow||qb(t)||pp(t);t=n?t:Ar(t),M_(t,this._rawValue)&&(this._rawValue=t,this._value=n?t:I_(t),GF(this))}}function bt(e){return Ai(e)?e.value:e}const J6={get:(e,t,n)=>bt(Reflect.get(e,t,n)),set:(e,t,n,r)=>{const i=e[t];return Ai(i)&&!Ai(n)?(i.value=n,!0):Reflect.set(e,t,n,r)}};function WF(e){return dd(e)?e:new Proxy(e,J6)}function wv(e){const t=Gn(e)?new Array(e.length):{};for(const n in e)t[n]=HF(e,n);return t}class e8{constructor(t,n,r){this._object=t,this._key=n,this._defaultValue=r,this.__v_isRef=!0}get value(){const t=this._object[this._key];return t===void 0?this._defaultValue:t}set value(t){this._object[this._key]=t}get dep(){return k6(Ar(this._object),this._key)}}class t8{constructor(t){this._getter=t,this.__v_isRef=!0,this.__v_isReadonly=!0}get value(){return this._getter()}}function Us(e,t,n){return Ai(e)?e:yr(e)?new t8(e):Fi(e)&&arguments.length>1?HF(e,t,n):jt(e)}function HF(e,t,n){const r=e[t];return Ai(r)?r:new e8(e,t,n)}class n8{constructor(t,n,r,i){this._setter=n,this.dep=void 0,this.__v_isRef=!0,this.__v_isReadonly=!1,this._dirty=!0,this.effect=new ek(t,()=>{this._dirty||(this._dirty=!0,GF(this))}),this.effect.computed=this,this.effect.active=this._cacheable=!i,this.__v_isReadonly=r}get value(){const t=Ar(this);return VF(t),(t._dirty||!t._cacheable)&&(t._dirty=!1,t._value=t.effect.run()),t._value}set value(t){this._setter(t)}}function r8(e,t,n=!1){let r,i;const s=yr(e);return s?(r=e,i=Ac):(r=e.get,i=e.set),new n8(r,i,s||!i,n)}function fd(e,t,n,r){let i;try{i=r?e(...r):e()}catch(s){Tv(s,t,n)}return i}function Wl(e,t,n,r){if(yr(e)){const s=fd(e,t,n,r);return s&&XC(s)&&s.catch(c=>{Tv(c,t,n)}),s}const i=[];for(let s=0;s<e.length;s++)i.push(Wl(e[s],t,n,r));return i}function Tv(e,t,n,r=!0){const i=t?t.vnode:null;if(t){let s=t.parent;const c=t.proxy,a=n;for(;s;){const g=s.ec;if(g){for(let x=0;x<g.length;x++)if(g[x](e,c,a)===!1)return}s=s.parent}const m=t.appContext.config.errorHandler;if(m){fd(m,null,10,[e,c,a]);return}}i8(e,n,i,r)}function i8(e,t,n,r=!0){console.error(e)}let O_=!1,BE=!1;const Qa=[];let iu=0;const Fm=[];let Hu=null,qf=0;const YF=Promise.resolve();let ak=null;function Qi(e){const t=ak||YF;return e?t.then(this?e.bind(this):e):t}function o8(e){let t=iu+1,n=Qa.length;for(;t<n;){const r=t+n>>>1;D_(Qa[r])<e?t=r+1:n=r}return t}function sk(e){(!Qa.length||!Qa.includes(e,O_&&e.allowRecurse?iu+1:iu))&&(e.id==null?Qa.push(e):Qa.splice(o8(e.id),0,e),ZF())}function ZF(){!O_&&!BE&&(BE=!0,ak=YF.then(KF))}function a8(e){const t=Qa.indexOf(e);t>iu&&Qa.splice(t,1)}function XF(e){Gn(e)?Fm.push(...e):(!Hu||!Hu.includes(e,e.allowRecurse?qf+1:qf))&&Fm.push(e),ZF()}function rI(e,t=O_?iu+1:0){for(;t<Qa.length;t++){const n=Qa[t];n&&n.pre&&(Qa.splice(t,1),t--,n())}}function Wb(e){if(Fm.length){const t=[...new Set(Fm)];if(Fm.length=0,Hu){Hu.push(...t);return}for(Hu=t,Hu.sort((n,r)=>D_(n)-D_(r)),qf=0;qf<Hu.length;qf++)Hu[qf]();Hu=null,qf=0}}const D_=e=>e.id==null?1/0:e.id,s8=(e,t)=>{const n=D_(e)-D_(t);if(n===0){if(e.pre&&!t.pre)return-1;if(t.pre&&!e.pre)return 1}return n};function KF(e){BE=!1,O_=!0,Qa.sort(s8);const t=Ac;try{for(iu=0;iu<Qa.length;iu++){const n=Qa[iu];n&&n.active!==!1&&fd(n,null,14)}}finally{iu=0,Qa.length=0,Wb(),O_=!1,ak=null,(Qa.length||Fm.length)&&KF()}}function l8(e,t,...n){if(e.isUnmounted)return;const r=e.vnode.props||ro;let i=n;const s=t.startsWith("update:"),c=s&&t.slice(7);if(c&&c in r){const x=`${c==="modelValue"?"model":c}Modifiers`,{number:T,trim:C}=r[x]||ro;C&&(i=n.map(A=>fo(A)?A.trim():A)),T&&(i=n.map(kF))}let a,m=r[a=vb(t)]||r[a=vb(Pc(t))];!m&&s&&(m=r[a=vb(bp(t))]),m&&Wl(m,e,6,i);const g=r[a+"Once"];if(g){if(!e.emitted)e.emitted={};else if(e.emitted[a])return;e.emitted[a]=!0,Wl(g,e,6,i)}}function QF(e,t,n=!1){const r=t.emitsCache,i=r.get(e);if(i!==void 0)return i;const s=e.emits;let c={},a=!1;
vendor: 2,182 bytes, line 1
1if(!yr(e)){const m=g=>{const x=QF(g,t,!0);x&&(a=!0,Go(c,x))};!n&&t.mixins.length&&t.mixins.forEach(m),e.extends&&m(e.extends),e.mixins&&e.mixins.forEach(m)}return!s&&!a?(Fi(e)&&r.set(e,null),null):(Gn(s)?s.forEach(m=>c[m]=null):Go(c,s),Fi(e)&&r.set(e,c),c)}function Gx(e,t){return!e||!yv(t)?!1:(t=t.slice(2).replace(/Once$/,""),Yr(e,t[0].toLowerCase()+t.slice(1))||Yr(e,bp(t))||Yr(e,t))}let Ca=null,qx=null;function Hb(e){const t=Ca;return Ca=e,qx=e&&e.type.__scopeId||null,t}function c8(e){qx=e}function u8(){qx=null}function wr(e,t=Ca,n){if(!t||e._n)return e;const r=(...i)=>{r._d&&yI(-1);const s=Hb(t);let c;try{c=e(...i)}finally{Hb(s),r._d&&yI(1)}return c};return r._n=!0,r._c=!0,r._d=!0,r}function oT(e){const{type:t,vnode:n,proxy:r,withProxy:i,props:s,propsOptions:[c],slots:a,attrs:m,emit:g,render:x,renderCache:T,data:C,setupState:A,ctx:P,inheritAttrs:D}=e;let B,R;const N=Hb(e);try{if(n.shapeFlag&4){const U=i||r;B=Nl(x.call(U,U,T,s,A,C,P)),R=m}else{const U=t;B=Nl(U.length>1?U(s,{attrs:m,slots:a,emit:g}):U(s,null)),R=t.props?m:d8(m)}}catch(U){f_.length=0,Tv(U,e,1),B=sn(_s)}let j=B;if(R&&D!==!1){const U=Object.keys(R),{shapeFlag:W}=j;U.length&&W&7&&(c&&U.some(YC)&&(R=f8(R,c)),j=nh(j,R))}return n.dirs&&(j=nh(j),j.dirs=j.dirs?j.dirs.concat(n.dirs):n.dirs),n.transition&&(j.transition=n.transition),B=j,Hb(N),B}function h8(e){let t;for(let n=0;n<e.length;n++){const r=e[n];if(Km(r)){if(r.type!==_s||r.children==="v-if"){if(t)return;t=r}}else return}return t}const d8=e=>{let t;for(const n in e)(n==="class"||n==="style"||yv(n))&&((t||(t={}))[n]=e[n]);return t},f8=(e,t)=>{const n={};for(const r in e)(!YC(r)||!(r.slice(9)in t))&&(n[r]=e[r]);return n};function p8(e,t,n){const{props:r,children:i,component:s}=e,{props:c,children:a,patchFlag:m}=t,g=s.emitsOptions;if(t.dirs||t.transition)return!0;if(n&&m>=0){if(m&1024)return!0;if(m&16)return r?iI(r,c,g):!!c;if(m&8){const x=t.dynamicProps;for(let T=0;T<x.length;T++){const C=x[T];if(c[C]!==r[C]&&!Gx(g,C))return!0}}}else return(i||a)&&(!a||!a.$stable)?!0:r===c?!1:r?c?iI(r,c,g):!0:!!c;return!1}function iI(e,t,n){const r=Object.keys(t);if(r.length!==Object.keys(e).length)return!0;for(let i=0;i<r.length;i++){const s=r[i];
1if(t[s]!==e[s]&&!Gx(n,s))return!0}return!1}function lk({vnode:e,parent:t},n){for(;t&&t.subTree===e;)(e=t.vnode).el=n,t=t.parent}const JF=e=>e.__isSuspense,m8={name:"Suspense",__isSuspense:!0,process(e,t,n,r,i,s,c,a,m,g){e==null?g8(t,n,r,i,s,c,a,m,g):y8(e,t,n,r,i,c,a,m,g)},hydrate:_8,create:uk,normalize:v8},ck=m8;function L_(e,t){const n=e.props&&e.props[t];yr(n)&&n()}function g8(e,t,n,r,i,s,c,a,m){const{p:g,o:{createElement:x}}=m,T=x("div"),C=e.suspense=uk(e,i,r,t,T,n,s,c,a,m);g(null,C.pendingBranch=e.ssContent,T,null,r,C,s,c),C.deps>0?(L_(e,"onPending"),L_(e,"onFallback"),g(null,e.ssFallback,t,n,r,null,s,c),Bm(C,e.ssFallback)):C.resolve(!1,!0)}function y8(e,t,n,r,i,s,c,a,{p:m,um:g,o:{createElement:x}}){const T=t.suspense=e.suspense;T.vnode=t,t.el=e.el;const C=t.ssContent,A=t.ssFallback,{activeBranch:P,pendingBranch:D,isInFallback:B,isHydrating:R}=T;if(D)T.pendingBranch=C,Ec(C,D)?(m(D,C,T.hiddenContainer,null,i,T,s,c,a),T.deps<=0?T.resolve():B&&(m(P,A,n,r,i,null,s,c,a),Bm(T,A))):(T.pendingId++,R?(T.isHydrating=!1,T.activeBranch=D):g(D,i,T),T.deps=0,T.effects.length=0,T.hiddenContainer=x("div"),B?(m(null,C,T.hiddenContainer,null,i,T,s,c,a),T.deps<=0?T.resolve():(m(P,A,n,r,i,null,s,c,a),Bm(T,A))):P&&Ec(C,P)?(m(P,C,n,r,i,T,s,c,a),T.resolve(!0)):(m(null,C,T.hiddenContainer,null,i,T,s,c,a),T.deps<=0&&T.resolve()));else if(P&&Ec(C,P))m(P,C,n,r,i,T,s,c,a),Bm(T,C);else if(L_(t,"onPending"),T.pendingBranch=C,T.pendingId++,m(null,C,T.hiddenContainer,null,i,T,s,c,a),T.deps<=0)T.resolve();else{const{timeout:N,pendingId:j}=T;N>0?setTimeout(()=>{T.pendingId===j&&T.fallback(A)},N):N===0&&T.fallback(A)}}function uk(e,t,n,r,i,s,c,a,m,g,x=!1){const{p:T,m:C,um:A,n:P,o:{parentNode:D,remove:B}}=g;let R;const N=b8(e);N&&t!=null&&t.pendingBranch&&(R=t.pendingId,t.deps++);const j=e.props?AF(e.props.timeout):void 0,U={vnode:e,parent:t,parentComponent:n,isSVG:c,container:r,hiddenContainer:i,anchor:s,deps:0,pendingId:0,timeout:typeof j=="number"?j:-1,activeBranch:null,pendingBranch:null,isInFallback:!0,isHydrating:x,isUnmounted:!1,effects:[],resolve(W=!1,Q=!1){const{vnode:Z,activeBranch:K,pendingBranch:Y,pendingId:me,effects:ge,parentComponent:ce,container:fe}=U;if(U.isHydrating)U.isHydrating=!1;else if(!W){const Te=K&&Y.transition&&Y.transition.mode==="out-in";Te&&(K.transition.afterLeave=()=>{me===U.pendingId&&C(Y,fe,oe,0)});let{anchor:oe}=U;K&&(oe=P(K),A(K,ce,U,!0)),Te||C(Y,fe,oe,0)}Bm(U,Y),U.pendingBranch=null,U.isInFallback=!1;let ie=U.parent,xe=!1;for(;ie;){if(ie.pendingBranch){ie.effects.push(...ge),xe=!0;break}ie=ie.parent}xe||XF(ge),U.effects=[],N&&t&&t.pendingBranch&&R===t.pendingId&&(t.deps--,t.deps===0&&!Q&&t.resolve()),L_(Z,"onResolve")},fallback(W){if(!U.pendingBranch)return;const{vnode:Q,activeBranch:Z,parentComponent:K,container:Y,isSVG:me}=U;L_(Q,"onFallback");const ge=P(Z),ce=()=>{U.isInFallback&&(T(null,W,Y,ge,K,null,me,a,m),Bm(U,W))},fe=W.transition&&W.transition.mode==="out-in";fe&&(Z.transition.afterLeave=ce),U.isInFallback=!0,A(Z,K,null,!0),fe||ce()},move(W,Q,Z){U.activeBranch&&C(U.activeBranch,W,Q,Z),U.container=W},next(){return U.activeBranch&&P(U.activeBranch)},registerDep(W,Q){const Z=!!U.pendingBranch;Z&&U.deps++;const K=W.vnode.el;W.asyncDep.catch(Y=>{Tv(Y,W,0)}).then(Y=>{if(W.isUnmounted||U.isUnmounted||U.pendingId!==W.suspenseId)return;W.asyncResolved=!0;const{vnode:me}=W;VE(W,Y,!1),K&&(me.el=K);const ge=!K&&W.subTree.el;Q(W,me,D(K||W.subTree.el),K?null:P(W.subTree),U,c,m),ge&&B(ge),lk(W,me.el),Z&&--U.deps===0&&U.resolve()})},unmount(W,Q){U.isUnmounted=!0,U.activeBranch&&A(U.activeBranch,n,W,Q),U.pendingBranch&&A(U.pendingBranch,n,W,Q)}};return U}function _8(e,t,n,r,i,s,c,a,m){const g=t.suspense=uk(t,r,n,e.parentNode,document.createElement("div"),null,i,s,c,a,!0),x=m(e,g.pendingBranch=t.ssContent,n,g,s,c);return g.deps===0&&g.resolve(!1,!0),x}function v8(e){const{shapeFlag:t,children:n}=e,r=t&32;e.ssContent=oI(r?n.default:n),e.ssFallback=r?oI(n.fallback):sn(_s)}function oI(e){let t;if(yr(e)){const n=Xm&&e._c;n&&(e._d=!1,At()),e=e(),n&&(e._d=!0,t=Ul,T3())}return Gn(e)&&(e=h8(e)),e=Nl(e),t&&!e.dynamicChildren&&(e.dynamicChildren=t.filter(n=>n!==e)),e}function e3(e,t){t&&t.pendingBranch?Gn(e)?t.effects.push(...e):t.effects.push(e):XF(e)}function Bm(e,t){e.activeBranch=t;const{vnode:n,parentComponent:r}=e,i=n.el=t.el;r&&r.subTree===n&&(r.vnode.el=i,lk(r,i))}function b8(e){var t;return((t=e.props)==null?void 0:t.suspensible)!=null&&e.props.suspensible!==!1}function sh(e,t){return hk(e,null,t)}const W0={};function Nn(e,t,n){return hk(e,t,n)}function hk(e,t,{immediate:n,deep:r,flush:i,onTrack:s,onTrigger:c}=ro){var a;const m=QC()===((a=la)==null?void 0:a.scope)?la:null;let g,x=!1,T=!1;if(Ai(e)?(g=()=>e.value,x=qb(e)):dd(e)?(g=()=>e,r=!0):Gn(e)?(T=!0,x=e.some(U=>dd(U)||qb(U)),g=()=>e.map(U=>{if(Ai(U))return U.value;if(dd(U))return Yf(U);if(yr(U))return fd(U,m,2)})):yr(e)?t?g=()=>fd(e,m,2):g=()=>{if(!(m&&m.isUnmounted))return C&&C(),Wl(e,m,3,[A])}:g=Ac,t&&r){const U=g;g=()=>Yf(U())}let C,A=U=>{C=N.onStop=()=>{fd(U,m,4)}},P;if(B_)if(A=Ac,t?n&&Wl(t,m,3,[g(),T?[]:void 0,A]):g(),i==="sync"){const U=cG();P=U.__watcherHandles||(U.__watcherHandles=[])}else return Ac;let D=T?new Array(e.length).fill(W0):W0;const B=()=>
vendor: 4,691 bytes, line 1
1{if(N.active)if(t){const U=N.run();(r||x||(T?U.some((W,Q)=>M_(W,D[Q])):M_(U,D)))&&(C&&C(),Wl(t,m,3,[U,D===W0?void 0:T&&D[0]===W0?[]:D,A]),D=U)}else N.run()};B.allowRecurse=!!t;let R;i==="sync"?R=B:i==="post"?R=()=>Fa(B,m&&m.suspense):(B.pre=!0,m&&(B.id=m.uid),R=()=>sk(B));const N=new ek(g,R);t?n?B():D=N.run():i==="post"?Fa(N.run.bind(N),m&&m.suspense):N.run();const j=()=>{N.stop(),m&&m.scope&&ZC(m.scope.effects,N)};return P&&P.push(j),j}function x8(e,t,n){const r=this.proxy,i=fo(e)?e.includes(".")?t3(r,e):()=>r[e]:e.bind(r,r);let s;yr(t)?s=t:(s=t.handler,n=t);const c=la;Ed(this);const a=hk(i,s.bind(r),n);return c?Ed(c):md(),a}function t3(e,t){const n=t.split(".");return()=>{let r=e;for(let i=0;i<n.length&&r;i++)r=r[n[i]];return r}}function Yf(e,t){if(!Fi(e)||e.__v_skip||(t=t||new Set,t.has(e)))return e;if(t.add(e),Ai(e))Yf(e.value,t);else if(Gn(e))for(let n=0;n<e.length;n++)Yf(e[n],t);else if($x(e)||Lm(e))e.forEach(n=>{Yf(n,t)});else if(CF(e))for(const n in e)Yf(e[n],t);return e}function pd(e,t){const n=Ca;if(n===null)return e;const r=Kx(n)||n.proxy,i=e.dirs||(e.dirs=[]);for(let s=0;s<t.length;s++){let[c,a,m,g=ro]=t[s];c&&(yr(c)&&(c={mounted:c,updated:c}),c.deep&&Yf(a),i.push({dir:c,instance:r,value:a,oldValue:void 0,arg:m,modifiers:g}))}return e}function nu(e,t,n,r){const i=e.dirs,s=t&&t.dirs;for(let c=0;c<i.length;c++){const a=i[c];s&&(a.oldValue=s[c].value);let m=a.dir[r];m&&(wg(),Wl(m,n,8,[e.el,a,e,t]),Tg())}}function n3(){const e={isMounted:!1,isLeaving:!1,isUnmounting:!1,leavingVNodes:new Map};return Dr(()=>{e.isMounted=!0}),xp(()=>{e.isUnmounting=!0}),e}const Bl=[Function,Array],r3={mode:String,appear:Boolean,persisted:Boolean,onBeforeEnter:Bl,onEnter:Bl,onAfterEnter:Bl,onEnterCancelled:Bl,onBeforeLeave:Bl,onLeave:Bl,onAfterLeave:Bl,onLeaveCancelled:Bl,onBeforeAppear:Bl,onAppear:Bl,onAfterAppear:Bl,onAppearCancelled:Bl},w8={name:"BaseTransition",props:r3,setup(e,{slots:t}){const n=ko(),r=n3();let i;return()=>{const s=t.default&&dk(t.default(),!0);if(!s||!s.length)return;let c=s[0];if(s.length>1){for(const D of s)if(D.type!==_s){c=D;break}}const a=Ar(e),{mode:m}=a;if(r.isLeaving)return aT(c);const g=aI(c);if(!g)return aT(c);const x=R_(g,a,r,n);Zm(g,x);const T=n.subTree,C=T&&aI(T);let A=!1;const{getTransitionKey:P}=g.type;if(P){const D=P();i===void 0?i=D:D!==i&&(i=D,A=!0)}if(C&&C.type!==_s&&(!Ec(g,C)||A)){const D=R_(C,a,r,n);if(Zm(C,D),m==="out-in")return r.isLeaving=!0,D.afterLeave=()=>{r.isLeaving=!1,n.update.active!==!1&&n.update()},aT(c);m==="in-out"&&g.type!==_s&&(D.delayLeave=(B,R,N)=>{const j=i3(r,C);j[String(C.key)]=C,B._leaveCb=()=>{R(),B._leaveCb=void 0,delete x.delayedLeave},x.delayedLeave=N})}return c}}},T8=w8;function i3(e,t){const{leavingVNodes:n}=e;let r=n.get(t.type);return r||(r=Object.create(null),n.set(t.type,r)),r}function R_(e,t,n,r){const{appear:i,mode:s,persisted:c=!1,onBeforeEnter:a,onEnter:m,onAfterEnter:g,onEnterCancelled:x,onBeforeLeave:T,onLeave:C,onAfterLeave:A,onLeaveCancelled:P,onBeforeAppear:D,onAppear:B,onAfterAppear:R,onAppearCancelled:N}=t,j=String(e.key),U=i3(n,e),W=(K,Y)=>{K&&Wl(K,r,9,Y)},Q=(K,Y)=>{const me=Y[1];W(K,Y),Gn(K)?K.every(ge=>ge.length<=1)&&me():K.length<=1&&me()},Z={mode:s,persisted:c,beforeEnter(K){let Y=a;if(!n.isMounted)if(i)Y=D||a;else return;K._leaveCb&&K._leaveCb(!0);const me=U[j];me&&Ec(e,me)&&me.el._leaveCb&&me.el._leaveCb(),W(Y,[K])},enter(K){let Y=m,me=g,ge=x;if(!n.isMounted)if(i)Y=B||m,me=R||g,ge=N||x;else return;let ce=!1;const fe=K._enterCb=ie=>{ce||(ce=!0,ie?W(ge,[K]):W(me,[K]),Z.delayedLeave&&Z.delayedLeave(),K._enterCb=void 0)};Y?Q(Y,[K,fe]):fe()},leave(K,Y){const me=String(e.key);if(K._enterCb&&K._enterCb(!0),n.isUnmounting)return Y();W(T,[K]);let ge=!1;const ce=K._leaveCb=fe=>{ge||(ge=!0,Y(),fe?W(P,[K]):W(A,[K]),K._leaveCb=void 0,U[me]===e&&delete U[me])};U[me]=e,C?Q(C,[K,ce]):ce()},clone(K){return R_(K,t,n,r)}};return Z}function aT(e){if(Wx(e))return e=nh(e),e.children=null,e}function aI(e){return Wx(e)?e.children?e.children[0]:void 0:e}function Zm(e,t){e.shapeFlag&6&&e.component?Zm(e.component.subTree,t):e.shapeFlag&128?(e.ssContent.transition=t.clone(e.ssContent),e.ssFallback.transition=t.clone(e.ssFallback)):e.transition=t}function dk(e,t=!1,n){let r=[],i=0;for(let s=0;s<e.length;s++){let c=e[s];const a=n==null?c.key:String(n)+String(c.key!=null?c.key:s);c.type===Hn?(c.patchFlag&128&&i++,r=r.concat(dk(c.children,t,a))):(t||c.type!==_s)&&r.push(a!=null?nh(c,{key:a}):c)}if(i>1)for(let s=0;s<r.length;s++)r[s].patchFlag=-2;return r}function sr(e,t){return yr(e)?(()=>Go({name:e.name},t,{setup:e}))():e}const np=e=>!!e.type.__asyncLoader,Wx=e=>e.type.__isKeepAlive,E8={name:"KeepAlive",__isKeepAlive:!0,props:{include:[String,RegExp,Array
vendor: 4,244 bytes, line 1
1],exclude:[String,RegExp,Array],max:[String,Number]},setup(e,{slots:t}){const n=ko(),r=n.ctx;if(!r.renderer)return()=>{const N=t.default&&t.default();return N&&N.length===1?N[0]:N};const i=new Map,s=new Set;let c=null;const a=n.suspense,{renderer:{p:m,m:g,um:x,o:{createElement:T}}}=r,C=T("div");r.activate=(N,j,U,W,Q)=>{const Z=N.component;g(N,j,U,0,a),m(Z.vnode,N,j,U,Z,a,W,N.slotScopeIds,Q),Fa(()=>{Z.isDeactivated=!1,Z.a&&Rm(Z.a);const K=N.props&&N.props.onVnodeMounted;K&&Ls(K,Z.parent,N)},a)},r.deactivate=N=>{const j=N.component;g(N,C,null,1,a),Fa(()=>{j.da&&Rm(j.da);const U=N.props&&N.props.onVnodeUnmounted;U&&Ls(U,j.parent,N),j.isDeactivated=!0},a)};function A(N){sT(N),x(N,n,a,!0)}function P(N){i.forEach((j,U)=>{const W=GE(j.type);W&&(!N||!N(W))&&D(U)})}function D(N){const j=i.get(N);!c||!Ec(j,c)?A(j):c&&sT(c),i.delete(N),s.delete(N)}Nn(()=>[e.include,e.exclude],([N,j])=>{N&&P(U=>n_(N,U)),j&&P(U=>!n_(j,U))},{flush:"post",deep:!0});let B=null;const R=()=>{B!=null&&i.set(B,lT(n.subTree))};return Dr(R),Yx(R),xp(()=>{i.forEach(N=>{const{subTree:j,suspense:U}=n,W=lT(j);if(N.type===W.type&&N.key===W.key){sT(W);const Q=W.component.da;Q&&Fa(Q,U);return}A(N)})}),()=>{if(B=null,!t.default)return null;const N=t.default(),j=N[0];if(N.length>1)return c=null,N;if(!Km(j)||!(j.shapeFlag&4)&&!(j.shapeFlag&128))return c=null,j;let U=lT(j);const W=U.type,Q=GE(np(U)?U.type.__asyncResolved||{}:W),{include:Z,exclude:K,max:Y}=e;if(Z&&(!Q||!n_(Z,Q))||K&&Q&&n_(K,Q))return c=U,j;const me=U.key==null?W:U.key,ge=i.get(me);return U.el&&(U=nh(U),j.shapeFlag&128&&(j.ssContent=U)),B=me,ge?(U.el=ge.el,U.component=ge.component,U.transition&&Zm(U,U.transition),U.shapeFlag|=512,s.delete(me),s.add(me)):(s.add(me),Y&&s.size>parseInt(Y,10)&&D(s.values().next().value)),U.shapeFlag|=256,c=U,JF(j.type)?j:U}}},S8=E8;function n_(e,t){return Gn(e)?e.some(n=>n_(n,t)):fo(e)?e.split(",").includes(t):d6(e)?e.test(t):!1}function o3(e,t){s3(e,"a",t)}function a3(e,t){s3(e,"da",t)}function s3(e,t,n=la){const r=e.__wdc||(e.__wdc=()=>{let i=n;for(;i;){if(i.isDeactivated)return;i=i.parent}return e()});if(Hx(t,r,n),n){let i=n.parent;for(;i&&i.parent;)Wx(i.parent.vnode)&&C8(r,t,n,i),i=i.parent}}function C8(e,t,n,r){const i=Hx(t,e,r,!0);Bi(()=>{ZC(r[t],i)},n)}function sT(e){e.shapeFlag&=-257,e.shapeFlag&=-513}function lT(e){return e.shapeFlag&128?e.ssContent:e}function Hx(e,t,n=la,r=!1){if(n){const i=n[e]||(n[e]=[]),s=t.__weh||(t.__weh=(...c)=>{if(n.isUnmounted)return;wg(),Ed(n);const a=Wl(t,n,e,c);return md(),Tg(),a});return r?i.unshift(s):i.push(s),s}}const lh=e=>(t,n=la)=>(!B_||e==="sp")&&Hx(e,(...r)=>t(...r),n),l3=lh("bm"),Dr=lh("m"),c3=lh("bu"),Yx=lh("u"),xp=lh("bum"),Bi=lh("um"),k8=lh("sp"),A8=lh("rtg"),P8=lh("rtc");function u3(e,t=la){Hx("ec",e,t)}const fk="components",M8="directives";function Zx(e,t){return pk(fk,e,!0,t)||e}const h3=Symbol.for("v-ndc");function Ev(e){return fo(e)?pk(fk,e,!1)||e:e||h3}function I8(e){return pk(M8,e)}function pk(e,t,n=!0,r=!1){const i=Ca||la;if(i){const s=i.type;if(e===fk){const a=GE(s,!1);if(a&&(a===t||a===Pc(t)||a===_v(Pc(t))))return s}const c=sI(i[e]||s[e],t)||sI(i.appContext[e],t);return!c&&r?s:c}}function sI(e,t){return e&&(e[t]||e[Pc(t)]||e[_v(Pc(t))])}function $o(e,t,n,r){let i;const s=n&&n[r];if(Gn(e)||fo(e)){i=new Array(e.length);for(let c=0,a=e.length;c<a;c++)i[c]=t(e[c],c,void 0,s&&s[c])}else if(typeof e=="number"){i=new Array(e);for(let c=0;c<e;c++)i[c]=t(c+1,c,void 0,s&&s[c])}else if(Fi(e))if(e[Symbol.iterator])i=Array.from(e,(c,a)=>t(c,a,void 0,s&&s[a]));else{const c=Object.keys(e);i=new Array(c.length);for(let a=0,m=c.length;a<m;a++){const g=c[a];i[a]=t(e[g],g,a,s&&s[a])}}else i=[];return n&&(n[r]=i),i}function pl(e,t){for(let n=0;n<t.length;n++){const r=t[n];if(Gn(r))for(let i=0;i<r.length;i++)e[r[i].name]=r[i].fn;else r&&(e[r.name]=r.key?(...i)=>{const s=r.fn(...i);return s&&(s.key=r.key),s}:r.fn)}return e}function En(e,t,n={},r,i){if(Ca.isCE||Ca.parent&&np(Ca.parent)&&Ca.parent.isCE)return t!=="default"&&(n.name=t),sn("slot",n,r&&r());let s=e[t];s&&s._c&&(s._d=!1),At();const c=s&&d3(s(n)),a=Tr(Hn,{key:n.key||c&&c.key||`_${t}`},c||(r?r():[]),c&&e._===1?64:-2);return!i&&a.scopeId&&(a.slotScopeIds=[a.scopeId+"-s"]),s&&s._c&&(s._d=!0),a}function d3(e){return e.some(t=>
vendor: 4,163 bytes, line 1
1Km(t)?!(t.type===_s||t.type===Hn&&!d3(t.children)):!0)?e:null}function O8(e,t){const n={};for(const r in e)n[t&&/[A-Z]/.test(r)?`on:${r}`:vb(r)]=e[r];return n}const zE=e=>e?k3(e)?Kx(e)||e.proxy:zE(e.parent):null,u_=Go(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=>zE(e.parent),$root:e=>zE(e.root),$emit:e=>e.emit,$options:e=>mk(e),$forceUpdate:e=>e.f||(e.f=()=>sk(e.update)),$nextTick:e=>e.n||(e.n=Qi.bind(e.proxy)),$watch:e=>x8.bind(e)}),cT=(e,t)=>e!==ro&&!e.__isScriptSetup&&Yr(e,t),D8={get({_:e},t){const{ctx:n,setupState:r,data:i,props:s,accessCache:c,type:a,appContext:m}=e;let g;if(t[0]!=="$"){const A=c[t];if(A!==void 0)switch(A){case 1:return r[t];case 2:return i[t];case 4:return n[t];case 3:return s[t]}else{if(cT(r,t))return c[t]=1,r[t];if(i!==ro&&Yr(i,t))return c[t]=2,i[t];if((g=e.propsOptions[0])&&Yr(g,t))return c[t]=3,s[t];if(n!==ro&&Yr(n,t))return c[t]=4,n[t];NE&&(c[t]=0)}}const x=u_[t];let T,C;if(x)return t==="$attrs"&&js(e,"get",t),x(e);if((T=a.__cssModules)&&(T=T[t]))return T;if(n!==ro&&Yr(n,t))return c[t]=4,n[t];if(C=m.config.globalProperties,Yr(C,t))return C[t]},set({_:e},t,n){const{data:r,setupState:i,ctx:s}=e;return cT(i,t)?(i[t]=n,!0):r!==ro&&Yr(r,t)?(r[t]=n,!0):Yr(e.props,t)||t[0]==="$"&&t.slice(1)in e?!1:(s[t]=n,!0)},has({_:{data:e,setupState:t,accessCache:n,ctx:r,appContext:i,propsOptions:s}},c){let a;return!!n[c]||e!==ro&&Yr(e,c)||cT(t,c)||(a=s[0])&&Yr(a,c)||Yr(r,c)||Yr(u_,c)||Yr(i.config.globalProperties,c)},defineProperty(e,t,n){return n.get!=null?e._.accessCache[t]=0:Yr(n,"value")&&this.set(e,t,n.value,null),Reflect.defineProperty(e,t,n)}};function Sv(){return L8().slots}function L8(){const e=ko();return e.setupContext||(e.setupContext=P3(e))}function lI(e){return Gn(e)?e.reduce((t,n)=>(t[n]=null,t),{}):e}function v_e(e){const t=ko();let n=e();return md(),XC(n)&&(n=n.catch(r=>{throw Ed(t),r})),[n,()=>Ed(t)]}let NE=!0;function R8(e){const t=mk(e),n=e.proxy,r=e.ctx;NE=!1,t.beforeCreate&&cI(t.beforeCreate,e,"bc");const{data:i,computed:s,methods:c,watch:a,provide:m,inject:g,created:x,beforeMount:T,mounted:C,beforeUpdate:A,updated:P,activated:D,deactivated:B,beforeDestroy:R,beforeUnmount:N,destroyed:j,unmounted:U,render:W,renderTracked:Q,renderTriggered:Z,errorCaptured:K,serverPrefetch:Y,expose:me,inheritAttrs:ge,components:ce,directives:fe,filters:ie}=t;if(g&&F8(g,r,null),c)for(const oe in c){const ne=c[oe];yr(ne)&&(r[oe]=ne.bind(n))}if(i){const oe=i.call(n,n);Fi(oe)&&(e.data=so(oe))}if(NE=!0,s)for(const oe in s){const ne=s[oe],le=yr(ne)?ne.bind(n,n):yr(ne.get)?ne.get.bind(n,n):Ac,se=!yr(ne)&&yr(ne.set)?ne.set.bind(n):Ac,Ne=yt({get:le,set:se});Object.defineProperty(r,oe,{enumerable:!0,configurable:!0,get:()=>Ne.value,set:Se=>Ne.value=Se})}if(a)for(const oe in a)f3(a[oe],r,n,oe);if(m){const oe=yr(m)?m.call(n):m;Reflect.ownKeys(oe).forEach(ne=>{ea(ne,oe[ne])})}x&&cI(x,e,"c");function Te(oe,ne){Gn(ne)?ne.forEach(le=>oe(le.bind(n))):ne&&oe(ne.bind(n))}if(Te(l3,T),Te(Dr,C),Te(c3,A),Te(Yx,P),Te(o3,D),Te(a3,B),Te(u3,K),Te(P8,Q),Te(A8,Z),Te(xp,N),Te(Bi,U),Te(k8,Y),Gn(me))if(me.length){const oe=e.exposed||(e.exposed={});me.forEach(ne=>{Object.defineProperty(oe,ne,{get:()=>n[ne],set:le=>n[ne]=le})})}else e.exposed||(e.exposed={});W&&e.render===Ac&&(e.render=W),ge!=null&&(e.inheritAttrs=ge),ce&&(e.components=ce),fe&&(e.directives=fe)}function F8(e,t,n=Ac){Gn(e)&&(e=$E(e));for(const r in e){const i=e[r];let s;Fi(i)?"default"in i?s=dr(i.from||r,i.default,!0):s=dr(i.from||r):s=dr(i),Ai(s)?Object.defineProperty(t,r,{enumerable:!0,configurable:!0,get:()=>s.value,set:c=>s.value=c}):t[r]=s}}function cI(e,t,n){Wl(Gn(e)?e.map(r=>r.bind(t.proxy)):e.bind(t.proxy),t,n)}function f3(e,t,n,r){const i=r.includes(".")?t3(n,r):()=>n[r];if(fo(e)){const s=t[e];yr(s)&&Nn(i,s)}else if(yr(e))Nn(i,e.bind(n));else if(Fi(e))if(Gn(e))e.forEach(s=>f3(s,t,n,r));else{const s=yr(e.handler)?e.handler.bind(n):t[e.handler];yr(s)&&Nn(i,s,e)}}function mk(e){const t=e.type,{mixins:n,extends:r}=t,{mixins:i,optionsCache:s,config:{optionMergeStrategies:c}}=e.appContext,a=s.get(t);let m;return a?m=a:!i.length&&!n&&!r?m=t:(m={}
vendor: 5,521 bytes, line 1
1,i.length&&i.forEach(g=>Yb(m,g,c,!0)),Yb(m,t,c)),Fi(t)&&s.set(t,m),m}function Yb(e,t,n,r=!1){const{mixins:i,extends:s}=t;s&&Yb(e,s,n,!0),i&&i.forEach(c=>Yb(e,c,n,!0));for(const c in t)if(!(r&&c==="expose")){const a=B8[c]||n&&n[c];e[c]=a?a(e[c],t[c]):t[c]}return e}const B8={data:uI,props:hI,emits:hI,methods:r_,computed:r_,beforeCreate:ds,created:ds,beforeMount:ds,mounted:ds,beforeUpdate:ds,updated:ds,beforeDestroy:ds,beforeUnmount:ds,destroyed:ds,unmounted:ds,activated:ds,deactivated:ds,errorCaptured:ds,serverPrefetch:ds,components:r_,directives:r_,watch:N8,provide:uI,inject:z8};function uI(e,t){return t?e?function(){return Go(yr(e)?e.call(this,this):e,yr(t)?t.call(this,this):t)}:t:e}function z8(e,t){return r_($E(e),$E(t))}function $E(e){if(Gn(e)){const t={};for(let n=0;n<e.length;n++)t[e[n]]=e[n];return t}return e}function ds(e,t){return e?[...new Set([].concat(e,t))]:t}function r_(e,t){return e?Go(Object.create(null),e,t):t}function hI(e,t){return e?Gn(e)&&Gn(t)?[...new Set([...e,...t])]:Go(Object.create(null),lI(e),lI(t??{})):t}function N8(e,t){if(!e)return t;if(!t)return e;const n=Go(Object.create(null),e);for(const r in t)n[r]=ds(e[r],t[r]);return n}function p3(){return{app:null,config:{isNativeTag:c6,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 $8=0;function j8(e,t){return function(r,i=null){yr(r)||(r=Go({},r)),i!=null&&!Fi(i)&&(i=null);const s=p3(),c=new Set;let a=!1;const m=s.app={_uid:$8++,_component:r,_props:i,_container:null,_context:s,_instance:null,version:M3,get config(){return s.config},set config(g){},use(g,...x){return c.has(g)||(g&&yr(g.install)?(c.add(g),g.install(m,...x)):yr(g)&&(c.add(g),g(m,...x))),m},mixin(g){return s.mixins.includes(g)||s.mixins.push(g),m},component(g,x){return x?(s.components[g]=x,m):s.components[g]},directive(g,x){return x?(s.directives[g]=x,m):s.directives[g]},mount(g,x,T){if(!a){const C=sn(r,i);return C.appContext=s,x&&t?t(C,g):e(C,g,T),a=!0,m._container=g,g.__vue_app__=m,Kx(C.component)||C.component.proxy}},unmount(){a&&(e(null,m._container),delete m._container.__vue_app__)},provide(g,x){return s.provides[g]=x,m},runWithContext(g){F_=m;try{return g()}finally{F_=null}}};return m}}let F_=null;function ea(e,t){if(la){let n=la.provides;const r=la.parent&&la.parent.provides;r===n&&(n=la.provides=Object.create(r)),n[e]=t}}function dr(e,t,n=!1){const r=la||Ca;if(r||F_){const i=r?r.parent==null?r.vnode.appContext&&r.vnode.appContext.provides:r.parent.provides:F_._context.provides;if(i&&e in i)return i[e];if(arguments.length>1)return n&&yr(t)?t.call(r&&r.proxy):t}}function gk(){return!!(la||Ca||F_)}function U8(e,t,n,r=!1){const i={},s={};Vb(s,Xx,1),e.propsDefaults=Object.create(null),m3(e,t,i,s);for(const c in e.propsOptions[0])c in i||(i[c]=void 0);n?e.props=r?i:vv(i):e.type.props?e.props=i:e.props=s,e.attrs=s}function V8(e,t,n,r){const{props:i,attrs:s,vnode:{patchFlag:c}}=e,a=Ar(i),[m]=e.propsOptions;let g=!1;if((r||c>0)&&!(c&16)){if(c&8){const x=e.vnode.dynamicProps;for(let T=0;T<x.length;T++){let C=x[T];if(Gx(e.emitsOptions,C))continue;const A=t[C];if(m)if(Yr(s,C))A!==s[C]&&(s[C]=A,g=!0);else{const P=Pc(C);i[P]=jE(m,a,P,A,e,!1)}else A!==s[C]&&(s[C]=A,g=!0)}}}else{m3(e,t,i,s)&&(g=!0);let x;for(const T in a)(!t||!Yr(t,T)&&((x=bp(T))===T||!Yr(t,x)))&&(m?n&&(n[T]!==void 0||n[x]!==void 0)&&(i[T]=jE(m,a,T,void 0,e,!0)):delete i[T]);if(s!==a)for(const T in s)(!t||!Yr(t,T))&&(delete s[T],g=!0)}g&&th(e,"set","$attrs")}function m3(e,t,n,r){const[i,s]=e.propsOptions;let c=!1,a;if(t)for(let m in t){if(c_(m))continue;const g=t[m];let x;i&&Yr(i,x=Pc(m))?!s||!s.includes(x)?n[x]=g:(a||(a={}))[x]=g:Gx(e.emitsOptions,m)||(!(m in r)||g!==r[m])&&(r[m]=g,c=!0)}if(s){const m=Ar(n),g=a||ro;for(let x=0;x<s.length;x++){const T=s[x];n[T]=jE(i,m,T,g[T],e,!Yr(g,T))}}return c}function jE(e,t,n,r,i,s){const c=e[n];if(c!=null){const a=Yr(c,"default");if(a&&r===void 0){const m=c.default;if(c.type!==Function&&!c.skipFactory&&yr(m)){const{propsDefaults:g}=i;n in g?r=g[n]:(Ed(i),r=g[n]=m.call(null,t),md())}else r=m}c[0]&&(s&&!a?r=!1:c[1]&&(r===""||r===bp(n))&&(r=!0))}return r}function g3(e,t,n=!1){const r=t.propsCache,i=r.get(e);if(i)return i;const s=e.props,c={},a=[];let m=!1;if(!yr(e)){const x=T=>{m=!0;const[C,A]=g3(T,t,!0);Go(c,C),A&&a.push(...A)};!n&&t.mixins.length&&t.mixins.forEach(x),e.extends&&x(e.extends),e.mixins&&e.mixins.forEach(x)}if(!s&&!m)return Fi(e)&&r.set(e,Dm),Dm;if(Gn(s))for(let x=0;x<s.length;x++){const T=Pc(s[x]);dI(T)&&(c[T]=ro)}else if(s)for(const x in s){const T=Pc(x);if(dI(T)){const C=s[x],A=c[T]=Gn(C)||yr(C)?{type:C}:Go({},C);if(A){const P=mI(Boolean,A.type),D=mI(String,A.type);A[0]=P>-1,A[1]=D<0||P<D,(P>-1||Yr(A,"default"))&&a.push(T)}}}const g=[c,a];return Fi(e)&&r.set(e,g),g}function dI(e){return e[0]!=="$"}function fI(e){const t=e&&e.toString().match(/^\s*(function|class) (\w+)/);return t?t[2]:e===null?"null":""}function pI(e,t){return fI(e)===fI(t)}function mI(e,t){return Gn(t)?t.findIndex(n=>pI(n,e)):yr(t)&&pI(t,e)?0:-1}const y3=e=>e[0]==="_"||e==="$stable",yk=e=>Gn(e)?e.map(Nl):[Nl(e)],G8=(e,t,n)=>{if(t._n)return t;const r=wr((...i)=>yk(t(...i)),n);return r._c=!1,r},_3=(e,t,n)=>{const r=e._ctx;for(const i in e){if(y3(i))continue;const s=e[i];if(yr(s))t[i]=G8(i,s,r);else if(s!=null){const c=yk(s);t[i]=()=>c}}},v3=(e,t)=>{const n=yk(t);e.slots.default=()=>n},q8=(e,t)=>
1{if(e.vnode.shapeFlag&32){const n=t._;n?(e.slots=Ar(t),Vb(t,"_",n)):_3(t,e.slots={})}else e.slots={},t&&v3(e,t);Vb(e.slots,Xx,1)},W8=(e,t,n)=>{const{vnode:r,slots:i}=e;let s=!0,c=ro;if(r.shapeFlag&32){const a=t._;a?n&&a===1?s=!1:(Go(i,t),!n&&a===1&&delete i._):(s=!t.$stable,_3(t,i)),c=t}else t&&(v3(e,t),c={default:1});if(s)for(const a in i)!y3(a)&&!(a in c)&&delete i[a]};function Zb(e,t,n,r,i=!1){if(Gn(e)){e.forEach((C,A)=>Zb(C,t&&(Gn(t)?t[A]:t),n,r,i));return}if(np(r)&&!i)return;const s=r.shapeFlag&4?Kx(r.component)||r.component.proxy:r.el,c=i?null:s,{i:a,r:m}=e,g=t&&t.r,x=a.refs===ro?a.refs={}:a.refs,T=a.setupState;if(g!=null&&g!==m&&(fo(g)?(x[g]=null,Yr(T,g)&&(T[g]=null)):Ai(g)&&(g.value=null)),yr(m))fd(m,a,12,[c,x]);else{const C=fo(m),A=Ai(m);if(C||A){const P=()=>{if(e.f){const D=C?Yr(T,m)?T[m]:x[m]:m.value;i?Gn(D)&&ZC(D,s):Gn(D)?D.includes(s)||D.push(s):C?(x[m]=[s],Yr(T,m)&&(T[m]=x[m])):(m.value=[s],e.k&&(x[e.k]=m.value))}else C?(x[m]=c,Yr(T,m)&&(T[m]=c)):A&&(m.value=c,e.k&&(x[e.k]=c))};c?(P.id=-1,Fa(P,n)):P()}}}let jh=!1;const H0=e=>/svg/.test(e.namespaceURI)&&e.tagName!=="foreignObject",Y0=e=>e.nodeType===8;function H8(e){const{mt:t,p:n,o:{patchProp:r,createText:i,nextSibling:s,parentNode:c,remove:a,insert:m,createComment:g}}=e,x=(R,N)=>{if(!N.hasChildNodes()){n(null,R,N),Wb(),N._vnode=R;return}jh=!1,T(N.firstChild,R,null,null,null),Wb(),N._vnode=R,jh&&console.error("Hydration completed but contains mismatches.")},T=(R,N,j,U,W,Q=!1)=>{const Z=Y0(R)&&R.data==="[",K=()=>D(R,N,j,U,W,Z),{type:Y,ref:me,shapeFlag:ge,patchFlag:ce}=N;let fe=R.nodeType;N.el=R,ce===-2&&(Q=!1,N.dynamicChildren=null);let ie=null;switch(Y){case Td:fe!==3?N.children===""?(m(N.el=i(""),c(R),R),ie=R):ie=K():(R.data!==N.children&&(jh=!0,R.data=N.children),ie=s(R));break;case _s:fe!==8||Z?ie=K():ie=s(R);break;case d_:if(Z&&(R=s(R),fe=R.nodeType),fe===1||fe===3){ie=R;const xe=!N.children.length;for(let Te=0;Te<N.staticCount;Te++)xe&&(N.children+=ie.nodeType===1?ie.outerHTML:ie.data),Te===N.staticCount-1&&(N.anch
1or=ie),ie=s(ie);return Z?s(ie):ie}else K();break;case Hn:Z?ie=P(R,N,j,U,W,Q):ie=K();break;default:if(ge&1)fe!==1||N.type.toLowerCase()!==R.tagName.toLowerCase()?ie=K():ie=C(R,N,j,U,W,Q);else if(ge&6){N.slotScopeIds=W;const xe=c(R);if(t(N,xe,null,j,U,H0(xe),Q),ie=Z?B(R):s(R),ie&&Y0(ie)&&ie.data==="teleport end"&&(ie=s(ie)),np(N)){let Te;Z?(Te=sn(Hn),Te.anchor=ie?ie.previousSibling:xe.lastChild):Te=R.nodeType===3?mu(""):sn("div"),Te.el=R,N.component.subTree=Te}}else ge&64?fe!==8?ie=K():ie=N.type.hydrate(R,N,j,U,W,Q,e,A):ge&128&&(ie=N.type.hydrate(R,N,j,U,H0(c(R)),W,Q,e,T))}return me!=null&&Zb(me,null,U,N),ie},C=(R,N,j,U,W,Q)=>{Q=Q||!!N.dynamicChildren;const{type:Z,props:K,patchFlag:Y,shapeFlag:me,dirs:ge}=N,ce=Z==="input"&&ge||Z==="option";if(ce||Y!==-1){if(ge&&nu(N,null,j,"created"),K)if(ce||!Q||Y&48)for(const ie in K)(ce&&ie.endsWith("value")||yv(ie)&&!c_(ie))&&r(R,ie,null,K[ie],!1,void 0,j);else K.onClick&&r(R,"onClick",null,K.onClick,!1,void 0,j);let fe;if((fe=K&&K.onVnodeBeforeMount)&&Ls(fe,j,N),ge&&nu(N,null,j,"beforeMount"),((fe=K&&K.onVnodeMounted)||ge)&&e3(()=>
1{fe&&Ls(fe,j,N),ge&&nu(N,null,j,"mounted")},U),me&16&&!(K&&(K.innerHTML||K.textContent))){let ie=A(R.firstChild,N,R,j,U,W,Q);for(;ie;){jh=!0;const xe=ie;ie=ie.nextSibling,a(xe)}}else me&8&&R.textContent!==N.children&&(jh=!0,R.textContent=N.children)}return R.nextSibling},A=(R,N,j,U,W,Q,Z)=>{Z=Z||!!N.dynamicChildren;const K=N.children,Y=K.length;for(let me=0;me<Y;me++){const ge=Z?K[me]:K[me]=Nl(K[me]);if(R)R=T(R,ge,U,W,Q,Z);else{if(ge.type===Td&&!ge.children)continue;jh=!0,n(null,ge,j,null,U,W,H0(j),Q)}}return R},P=(R,N,j,U,W,Q)=>{const{slotScopeIds:Z}=N;Z&&(W=W?W.concat(Z):Z);const K=c(R),Y=A(s(R),N,K,j,U,W,Q);return Y&&Y0(Y)&&Y.data==="]"?s(N.anchor=Y):(jh=!0,m(N.anchor=g("]"),K,Y),Y)},D=(R,N,j,U,W,Q)=>{if(jh=!0,N.el=null,Q){const Y=B(R);for(;;){const me=s(R);if(me&&me!==Y)a(me);else break}}const Z=s(R),K=c(R);return a(R),n(null,N,K,Z,j,U,H0(K),W),Z},B=R=>{let N=0;for(;R;)if(R=s(R),R&&Y0(R)&&(R.data==="["&&N++,R.data==="]")){if(N===0)return s(R);N--}return R};return[x,T]}const Fa=e3;function Y8(e){return b3(e)}function Z8(e){return b3(e,H8)}function b3(e,t){const n=DE();n.__VUE__=!0;const{insert:r,remove:i,patchProp:s,createElement:c,createText:a,createComment:m,setText:g,setElementText:x,parentNode:T,nextSibling:C,setScopeId:A=Ac,insertStaticContent:P}=e,D=(Ae,we,Je,ct=null,mt=null,Vt=null,Ie=!1,Pe=null,rt=!!we.dynamicChildren)=>{if(Ae===we)return;Ae&&!Ec(Ae,we)&&(ct=je(Ae),Se(Ae,mt,Vt,!0),Ae=null),we.patchFlag===-2&&(rt=!1,we.dynamicChildren=null);const{type:Tt,ref:pn,shapeFlag:qt}=we;switch(Tt){case Td:B(Ae,we,Je,ct);break;case _s:R(Ae,we,Je,ct);break;case d_:Ae==null&&N(we,Je,ct,Ie);break;case Hn:ce(Ae,we,Je,ct,mt,Vt,Ie,Pe,rt);break;default:qt&1?W(Ae,we,Je,ct,mt,Vt,Ie,Pe,rt):qt&6?fe(Ae,we,Je,ct,mt,Vt,Ie,Pe,rt):(qt&64||qt&128)&&Tt.process(Ae,we,Je,ct,mt,Vt,Ie,Pe,rt,tt)}pn!=null&&mt&&Zb(pn,Ae&&Ae.ref,Vt,we||Ae,!we)},B=(Ae,we,Je,ct)=>{if(Ae==null)r(we.el=a(we.children),Je,ct);else{const mt=we.el=Ae.el;we.children!==Ae.children&&g(mt,we.children)}},R=(Ae,we,Je,ct)=>{Ae==null?r(we.el=m(we.children||""),Je,ct):we.el=Ae.el},N=(Ae,we,Je,ct)=>{[Ae.el,Ae.anchor]=P(Ae.children,we,Je,ct,Ae.el,Ae.anchor)},j=({el:Ae,anchor:we},Je,ct)=>{let mt;for(;Ae&&Ae!==we;)mt=C(Ae),r(Ae,Je,ct),Ae=mt;r(we,Je,ct)},U=({el:Ae,anchor:we})=>{let Je;for(;Ae&&Ae!==we;)Je=C(Ae),i(Ae),Ae=Je;i(we)},W=(Ae,we,Je,ct,mt,Vt,Ie,Pe,rt)=>{Ie=Ie||we.type==="svg",Ae==null?Q(we,Je,ct,mt,Vt,Ie,Pe,rt):Y(Ae,we,mt,Vt,Ie,Pe,rt)},Q=(Ae,we,Je,ct,mt,Vt,Ie,Pe)=>{let rt,Tt;const{type:pn,props:qt,shapeFlag:nt,transition:It,dirs:$t}=Ae;if(rt=Ae.el=c(Ae.type,Vt,qt&&qt.is,qt),nt&8?x(rt,Ae.children):nt&16&&K(Ae.children,rt,null,ct,mt,Vt&&pn!=="foreignObject",Ie,Pe),$t&&nu(Ae,null,ct,"created"),Z(rt,Ae,Ae.scopeId,Ie,ct),qt){for(const pt in qt)pt!=="value"&&!c_(pt)&&s(rt,pt,null,qt[pt],Vt,Ae.children,ct,mt,Ue);"value"in qt&&s(rt,"value",null,qt.value),(Tt=qt.onVnodeBeforeMount)&&Ls(Tt,ct,Ae)}$t&&nu(Ae,null,ct,"beforeMount");const $e=(!mt||mt&&!mt.pendingBranch)&&It&&!It.persisted;$e&&It.beforeEnter(rt),r(rt,we,Je),((Tt=qt&&qt.onVnodeMounted)||$e||$t)&&Fa(()=>{Tt&&Ls(Tt,ct,Ae),$e&&It.enter(rt),$t&&nu(Ae,null,ct,"mounted")},mt)},Z=(Ae,we,Je,ct,mt)=>{if(Je&&A(Ae,Je),ct)for(let Vt=0;Vt<ct.length;Vt++)A(Ae,ct[Vt]);if(mt){let Vt=mt.subTree;if(we===Vt){const Ie=mt.vnode;Z(Ae,Ie,Ie.scopeId,Ie.slotScopeIds,mt.parent)}}},K=(Ae,we,Je,ct,mt,Vt,Ie,Pe,rt=0)=>{for(let Tt=rt;Tt<Ae.length;Tt++){const pn=Ae[Tt]=Pe?Xh(Ae[Tt]):Nl(Ae[Tt]);D(null,pn,we,Je,ct,mt,Vt,Ie,Pe)}},Y=(Ae,we,Je,ct,mt,Vt,Ie)=>{const Pe=we.el=Ae.el;let{patchFlag:rt,dynamicChildren:Tt,dirs:pn}=we;rt|=Ae.patchFlag&16;const qt=Ae.props||ro,nt=we.props||ro;let It;Je&&Pf(Je,!1),(It=nt.onVnodeBeforeUpdate)&&Ls(It,Je,we,Ae),pn&&nu(we,Ae,Je,"beforeUpdate"),Je&&Pf(Je,!0);const $t=mt&&we.type!=="foreignObject";if(Tt?me(Ae.dynamicChildren,Tt,Pe,Je,ct,$t,Vt):Ie||ne(Ae,we,Pe,null,Je,ct,$t,Vt,!1),rt>0){if(rt&16)ge(Pe,we,qt,nt,Je,ct,mt);else if(rt&2&&qt.class!==nt.class&&s(Pe,"class",null,nt.class,mt),rt&4&&s(Pe,"style",qt.style,nt.style,mt),rt&8){const $e=we.dynamicProps;for(let pt=0;pt<$e.length;pt++){const gn=$e[pt],Pn=qt[gn],gr=nt[gn];
vendor: 5,694 bytes, line 1
1(gr!==Pn||gn==="value")&&s(Pe,gn,Pn,gr,mt,Ae.children,Je,ct,Ue)}}rt&1&&Ae.children!==we.children&&x(Pe,we.children)}else!Ie&&Tt==null&&ge(Pe,we,qt,nt,Je,ct,mt);((It=nt.onVnodeUpdated)||pn)&&Fa(()=>{It&&Ls(It,Je,we,Ae),pn&&nu(we,Ae,Je,"updated")},ct)},me=(Ae,we,Je,ct,mt,Vt,Ie)=>{for(let Pe=0;Pe<we.length;Pe++){const rt=Ae[Pe],Tt=we[Pe],pn=rt.el&&(rt.type===Hn||!Ec(rt,Tt)||rt.shapeFlag&70)?T(rt.el):Je;D(rt,Tt,pn,null,ct,mt,Vt,Ie,!0)}},ge=(Ae,we,Je,ct,mt,Vt,Ie)=>{if(Je!==ct){if(Je!==ro)for(const Pe in Je)!c_(Pe)&&!(Pe in ct)&&s(Ae,Pe,Je[Pe],null,Ie,we.children,mt,Vt,Ue);for(const Pe in ct){if(c_(Pe))continue;const rt=ct[Pe],Tt=Je[Pe];rt!==Tt&&Pe!=="value"&&s(Ae,Pe,Tt,rt,Ie,we.children,mt,Vt,Ue)}"value"in ct&&s(Ae,"value",Je.value,ct.value)}},ce=(Ae,we,Je,ct,mt,Vt,Ie,Pe,rt)=>{const Tt=we.el=Ae?Ae.el:a(""),pn=we.anchor=Ae?Ae.anchor:a("");let{patchFlag:qt,dynamicChildren:nt,slotScopeIds:It}=we;It&&(Pe=Pe?Pe.concat(It):It),Ae==null?(r(Tt,Je,ct),r(pn,Je,ct),K(we.children,Je,pn,mt,Vt,Ie,Pe,rt)):qt>0&&qt&64&&nt&&Ae.dynamicChildren?(me(Ae.dynamicChildren,nt,Je,mt,Vt,Ie,Pe),(we.key!=null||mt&&we===mt.subTree)&&_k(Ae,we,!0)):ne(Ae,we,Je,pn,mt,Vt,Ie,Pe,rt)},fe=(Ae,we,Je,ct,mt,Vt,Ie,Pe,rt)=>{we.slotScopeIds=Pe,Ae==null?we.shapeFlag&512?mt.ctx.activate(we,Je,ct,Ie,rt):ie(we,Je,ct,mt,Vt,Ie,rt):xe(Ae,we,rt)},ie=(Ae,we,Je,ct,mt,Vt,Ie)=>{const Pe=Ae.component=rG(Ae,ct,mt);if(Wx(Ae)&&(Pe.ctx.renderer=tt),iG(Pe),Pe.asyncDep){if(mt&&mt.registerDep(Pe,Te),!Ae.el){const rt=Pe.subTree=sn(_s);R(null,rt,we,Je)}return}Te(Pe,Ae,we,Je,mt,Vt,Ie)},xe=(Ae,we,Je)=>{const ct=we.component=Ae.component;if(p8(Ae,we,Je))if(ct.asyncDep&&!ct.asyncResolved){oe(ct,we,Je);return}else ct.next=we,a8(ct.update),ct.update();else we.el=Ae.el,ct.vnode=we},Te=(Ae,we,Je,ct,mt,Vt,Ie)=>{const Pe=()=>{if(Ae.isMounted){let{next:pn,bu:qt,u:nt,parent:It,vnode:$t}=Ae,$e=pn,pt;Pf(Ae,!1),pn?(pn.el=$t.el,oe(Ae,pn,Ie)):pn=$t,qt&&Rm(qt),(pt=pn.props&&pn.props.onVnodeBeforeUpdate)&&Ls(pt,It,pn,$t),Pf(Ae,!0);const gn=oT(Ae),Pn=Ae.subTree;Ae.subTree=gn,D(Pn,gn,T(Pn.el),je(Pn),Ae,mt,Vt),pn.el=gn.el,$e===null&&lk(Ae,gn.el),nt&&Fa(nt,mt),(pt=pn.props&&pn.props.onVnodeUpdated)&&Fa(()=>Ls(pt,It,pn,$t),mt)}else{let pn;const{el:qt,props:nt}=we,{bm:It,m:$t,parent:$e}=Ae,pt=np(we);if(Pf(Ae,!1),It&&Rm(It),!pt&&(pn=nt&&nt.onVnodeBeforeMount)&&Ls(pn,$e,we),Pf(Ae,!0),qt&&lt){const gn=()=>{Ae.subTree=oT(Ae),lt(qt,Ae.subTree,Ae,mt,null)};pt?we.type.__asyncLoader().then(()=>!Ae.isUnmounted&&gn()):gn()}else{const gn=Ae.subTree=oT(Ae);D(null,gn,Je,ct,Ae,mt,Vt),we.el=gn.el}if($t&&Fa($t,mt),!pt&&(pn=nt&&nt.onVnodeMounted)){const gn=we;Fa(()=>Ls(pn,$e,gn),mt)}(we.shapeFlag&256||$e&&np($e.vnode)&&$e.vnode.shapeFlag&256)&&Ae.a&&Fa(Ae.a,mt),Ae.isMounted=!0,we=Je=ct=null}},rt=Ae.effect=new ek(Pe,()=>sk(Tt),Ae.scope),Tt=Ae.update=()=>rt.run();Tt.id=Ae.uid,Pf(Ae,!0),Tt()},oe=(Ae,we,Je)=>{we.component=Ae;const ct=Ae.vnode.props;Ae.vnode=we,Ae.next=null,V8(Ae,we.props,ct,Je),W8(Ae,we.children,Je),wg(),rI(),Tg()},ne=(Ae,we,Je,ct,mt,Vt,Ie,Pe,rt=!1)=>{const Tt=Ae&&Ae.children,pn=Ae?Ae.shapeFlag:0,qt=we.children,{patchFlag:nt,shapeFlag:It}=we;if(nt>0){if(nt&128){se(Tt,qt,Je,ct,mt,Vt,Ie,Pe,rt);return}else if(nt&256){le(Tt,qt,Je,ct,mt,Vt,Ie,Pe,rt);return}}It&8?(pn&16&&Ue(Tt,mt,Vt),qt!==Tt&&x(Je,qt)):pn&16?It&16?se(Tt,qt,Je,ct,mt,Vt,Ie,Pe,rt):Ue(Tt,mt,Vt,!0):(pn&8&&x(Je,""),It&16&&K(qt,Je,ct,mt,Vt,Ie,Pe,rt))},le=(Ae,we,Je,ct,mt,Vt,Ie,Pe,rt)=>{Ae=Ae||Dm,we=we||Dm;const Tt=Ae.length,pn=we.length,qt=Math.min(Tt,pn);let nt;for(nt=0;nt<qt;nt++){const It=we[nt]=rt?Xh(we[nt]):Nl(we[nt]);D(Ae[nt],It,Je,null,mt,Vt,Ie,Pe,rt)}Tt>pn?Ue(Ae,mt,Vt,!0,!1,qt):K(we,Je,ct,mt,Vt,Ie,Pe,rt,qt)},se=(Ae,we,Je,ct,mt,Vt,Ie,Pe,rt)=>{let Tt=0;const pn=we.length;let qt=Ae.length-1,nt=pn-1;for(;Tt<=qt&&Tt<=nt;){const It=Ae[Tt],$t=we[Tt]=rt?Xh(we[Tt]):Nl(we[Tt]);if(Ec(It,$t))D(It,$t,Je,null,mt,Vt,Ie,Pe,rt);else break;Tt++}for(;Tt<=qt&&Tt<=nt;){const It=Ae[qt],$t=we[nt]=rt?Xh(we[nt]):Nl(we[nt]);if(Ec(It,$t))D(It,$t,Je,null,mt,Vt,Ie,Pe,rt);else break;qt--,nt--}if(Tt>qt){if(Tt<=nt){const It=nt+1,$t=It<pn?we[It].el:ct;for(;Tt<=nt;)D(null,we[Tt]=rt?Xh(we[Tt]):Nl(we[Tt]),Je,$t,mt,Vt,Ie,Pe,rt),Tt++}}else if(Tt>nt)for(;Tt<=qt;)Se(Ae[Tt],mt,Vt,!0),Tt++;else{const It=Tt,$t=Tt,$e=new Map;for(Tt=$t;Tt<=nt;Tt++){const _i=we[Tt]=rt?Xh(we[Tt]):Nl(we[Tt]);_i.key!=null&&$e.set(_i.key,Tt)}let pt,gn=0;const Pn=nt-$t+1;let gr=!1,Ji=0;const Ni=new Array(Pn);for(Tt=0;Tt<Pn;Tt++)Ni[Tt]=0;for(Tt=It;Tt<=qt;Tt++){const _i=Ae[Tt];if(gn>=Pn){Se(_i,mt,Vt,!0);continue}let Wr;if(_i.key!=null)Wr=$e.get(_i.key);else for(pt=$t;pt<=nt;pt++)if(Ni[pt-$t]===0&&Ec(_i,we[pt])){Wr=pt;break}Wr===void 0?Se(_i,mt,Vt,!0):(Ni[Wr-$t]=Tt+1,Wr>=Ji?Ji=Wr:gr=!0,D(_i,we[Wr],Je,null,mt,Vt,Ie,Pe,rt),gn++)}const Bo=gr?X8(Ni):Dm;for(pt=Bo.length-1,Tt=Pn-1;Tt>=0;Tt--){const _i=$t+Tt,Wr=we[_i],Ao=_i+1<pn?we[_i+1].el:ct;Ni[Tt]===0?D(null,Wr,Je,Ao,mt,Vt,Ie,Pe,rt):gr&&(pt<0||Tt!==Bo[pt]?Ne(Wr,Je,Ao,2):pt--)}}},Ne=(Ae,we,Je,ct,mt=null)=>{const{el:Vt,type:Ie,transition:Pe,children:rt,shapeFlag:Tt}=Ae;if(Tt&6){Ne(Ae.component.subTree,we,Je,ct);return}if(Tt&128){Ae.suspense.move(we,Je,ct);return}if(Tt&64){Ie.move(Ae,we,Je,tt);return}if(Ie===Hn){r(Vt,we,Je);for(let qt=0;qt<rt.length;qt++)Ne(rt[qt],we,Je,ct);r(Ae.anchor,we,Je);return}if(Ie===d_){j(Ae,we,Je);return}if(ct!==2&&Tt&1&&Pe)if(ct===0)Pe.beforeEnter(Vt),r(Vt,we,Je),Fa(()=>Pe.enter(Vt),mt);else{const{leave:qt,delayLeave:nt,afterLeave:It}=Pe,$t=()=>r(Vt,we,Je),$e=()=>{qt(Vt,()=>{$t(),It&&It()})};nt?nt(Vt,$t,$e):$e()}else r(Vt,we,Je)},Se=(Ae,we,Je,ct=!1,mt=!1)=>{const{type:Vt,props:Ie,ref:Pe,children:rt,dynamicChildren:Tt,shapeFlag:pn,patchFlag:qt,dirs:nt}=Ae;if(Pe!=null&&Zb(Pe,null,Je,Ae,!0),pn&256){we.ctx.deactivate(Ae);return}
vendor: 4,536 bytes, line 1
1const It=pn&1&&nt,$t=!np(Ae);let $e;if($t&&($e=Ie&&Ie.onVnodeBeforeUnmount)&&Ls($e,we,Ae),pn&6)wt(Ae.component,Je,ct);else{if(pn&128){Ae.suspense.unmount(Je,ct);return}It&&nu(Ae,null,we,"beforeUnmount"),pn&64?Ae.type.remove(Ae,we,Je,mt,tt,ct):Tt&&(Vt!==Hn||qt>0&&qt&64)?Ue(Tt,we,Je,!1,!0):(Vt===Hn&&qt&384||!mt&&pn&16)&&Ue(rt,we,Je),ct&&xt(Ae)}($t&&($e=Ie&&Ie.onVnodeUnmounted)||It)&&Fa(()=>{$e&&Ls($e,we,Ae),It&&nu(Ae,null,we,"unmounted")},Je)},xt=Ae=>{const{type:we,el:Je,anchor:ct,transition:mt}=Ae;if(we===Hn){kt(Je,ct);return}if(we===d_){U(Ae);return}const Vt=()=>{i(Je),mt&&!mt.persisted&&mt.afterLeave&&mt.afterLeave()};if(Ae.shapeFlag&1&&mt&&!mt.persisted){const{leave:Ie,delayLeave:Pe}=mt,rt=()=>Ie(Je,Vt);Pe?Pe(Ae.el,Vt,rt):rt()}else Vt()},kt=(Ae,we)=>{let Je;for(;Ae!==we;)Je=C(Ae),i(Ae),Ae=Je;i(we)},wt=(Ae,we,Je)=>{const{bum:ct,scope:mt,update:Vt,subTree:Ie,um:Pe}=Ae;ct&&Rm(ct),mt.stop(),Vt&&(Vt.active=!1,Se(Ie,Ae,we,Je)),Pe&&Fa(Pe,we),Fa(()=>{Ae.isUnmounted=!0},we),we&&we.pendingBranch&&!we.isUnmounted&&Ae.asyncDep&&!Ae.asyncResolved&&Ae.suspenseId===we.pendingId&&(we.deps--,we.deps===0&&we.resolve())},Ue=(Ae,we,Je,ct=!1,mt=!1,Vt=0)=>{for(let Ie=Vt;Ie<Ae.length;Ie++)Se(Ae[Ie],we,Je,ct,mt)},je=Ae=>Ae.shapeFlag&6?je(Ae.component.subTree):Ae.shapeFlag&128?Ae.suspense.next():C(Ae.anchor||Ae.el),st=(Ae,we,Je)=>{Ae==null?we._vnode&&Se(we._vnode,null,null,!0):D(we._vnode||null,Ae,we,null,null,null,Je),rI(),Wb(),we._vnode=Ae},tt={p:D,um:Se,m:Ne,r:xt,mt:ie,mc:K,pc:ne,pbc:me,n:je,o:e};let Me,lt;return t&&([Me,lt]=t(tt)),{render:st,hydrate:Me,createApp:j8(st,Me)}}function Pf({effect:e,update:t},n){e.allowRecurse=t.allowRecurse=n}function _k(e,t,n=!1){const r=e.children,i=t.children;if(Gn(r)&&Gn(i))for(let s=0;s<r.length;s++){const c=r[s];let a=i[s];a.shapeFlag&1&&!a.dynamicChildren&&((a.patchFlag<=0||a.patchFlag===32)&&(a=i[s]=Xh(i[s]),a.el=c.el),n||_k(c,a)),a.type===Td&&(a.el=c.el)}}function X8(e){const t=e.slice(),n=[0];let r,i,s,c,a;const m=e.length;for(r=0;r<m;r++){const g=e[r];if(g!==0){if(i=n[n.length-1],e[i]<g){t[r]=i,n.push(r);continue}for(s=0,c=n.length-1;s<c;)a=s+c>>1,e[n[a]]<g?s=a+1:c=a;g<e[n[s]]&&(s>0&&(t[r]=n[s-1]),n[s]=r)}}for(s=n.length,c=n[s-1];s-- >0;)n[s]=c,c=t[c];return n}const K8=e=>e.__isTeleport,h_=e=>e&&(e.disabled||e.disabled===""),gI=e=>typeof SVGElement<"u"&&e instanceof SVGElement,UE=(e,t)=>{const n=e&&e.to;return fo(n)?t?t(n):null:n},Q8={__isTeleport:!0,process(e,t,n,r,i,s,c,a,m,g){const{mc:x,pc:T,pbc:C,o:{insert:A,querySelector:P,createText:D,createComment:B}}=g,R=h_(t.props);let{shapeFlag:N,children:j,dynamicChildren:U}=t;if(e==null){const W=t.el=D(""),Q=t.anchor=D("");A(W,n,r),A(Q,n,r);const Z=t.target=UE(t.props,P),K=t.targetAnchor=D("");Z&&(A(K,Z),c=c||gI(Z));const Y=(me,ge)=>{N&16&&x(j,me,ge,i,s,c,a,m)};R?Y(n,Q):Z&&Y(Z,K)}else{t.el=e.el;const W=t.anchor=e.anchor,Q=t.target=e.target,Z=t.targetAnchor=e.targetAnchor,K=h_(e.props),Y=K?n:Q,me=K?W:Z;if(c=c||gI(Q),U?(C(e.dynamicChildren,U,Y,i,s,c,a),_k(e,t,!0)):m||T(e,t,Y,me,i,s,c,a,!1),R)K||Z0(t,n,W,g,1);else if((t.props&&t.props.to)!==(e.props&&e.props.to)){const ge=t.target=UE(t.props,P);ge&&Z0(t,ge,null,g,0)}else K&&Z0(t,Q,Z,g,1)}w3(t)},remove(e,t,n,r,{um:i,o:{remove:s}},c){const{shapeFlag:a,children:m,anchor:g,targetAnchor:x,target:T,props:C}=e;if(T&&s(x),(c||!h_(C))&&(s(g),a&16))for(let A=0;A<m.length;A++){const P=m[A];i(P,t,n,!0,!!P.dynamicChildren)}},move:Z0,hydrate:J8};function Z0(e,t,n,{o:{insert:r},m:i},s=2){s===0&&r(e.targetAnchor,t,n);const{el:c,anchor:a,shapeFlag:m,children:g,props:x}=e,T=s===2;if(T&&r(c,t,n),(!T||h_(x))&&m&16)for(let C=0;C<g.length;C++)i(g[C],t,n,2);T&&r(a,t,n)}function J8(e,t,n,r,i,s,{o:{nextSibling:c,parentNode:a,querySelector:m}},g){const x=t.target=UE(t.props,m);if(x){const T=x._lpa||x.firstChild;if(t.shapeFlag&16)if(h_(t.props))t.anchor=g(c(e),t,a(e),n,r,i,s),t.targetAnchor=T;else{t.anchor=c(e);let C=T;for(;C;)if(C=c(C),C&&C.nodeType===8&&C.data==="teleport anchor"){t.targetAnchor=C,x._lpa=t.targetAnchor&&c(t.targetAnchor);break}g(T,t,x,n,r,i,s)}w3(t)}return t.anchor&&c(t.anchor)}const x3=Q8;function w3(e){const t=e.ctx;if(t&&t.ut){let n=e.children[0].el;for(;n!==e.targetAnchor;)n.nodeType===1&&n.setAttribute("data-v-owner",t.uid),n=n.nextSibling;t.ut()}}const Hn=Symbol.for("v-fgt"),Td=Symbol.for("v-txt"),_s=Symbol.for("v-cmt"),d_=Symbol.for("v-stc"),f_=[];let Ul=null;function At(e=!1){f_.push(Ul=e?null:[])}function T3(){f_.pop(),Ul=f_[f_.length-1]||null}let Xm=1;function yI(e){Xm+=e}function E3(e){return e.dynamicChildren=Xm>0?Ul||Dm:null,T3(),Xm>
vendor: 10,947 bytes, line 1
10&&Ul&&Ul.push(e),e}function Wt(e,t,n,r,i,s){return E3(Un(e,t,n,r,i,s,!0))}function Tr(e,t,n,r,i){return E3(sn(e,t,n,r,i,!0))}function Km(e){return e?e.__v_isVNode===!0:!1}function Ec(e,t){return e.type===t.type&&e.key===t.key}const Xx="__vInternal",S3=({key:e})=>e??null,bb=({ref:e,ref_key:t,ref_for:n})=>(typeof e=="number"&&(e=""+e),e!=null?fo(e)||Ai(e)||yr(e)?{i:Ca,r:e,k:t,f:!!n}:e:null);function Un(e,t=null,n=null,r=0,i=null,s=e===Hn?0:1,c=!1,a=!1){const m={__v_isVNode:!0,__v_skip:!0,type:e,props:t,key:t&&S3(t),ref:t&&bb(t),scopeId:qx,slotScopeIds:null,children:n,component:null,suspense:null,ssContent:null,ssFallback:null,dirs:null,transition:null,el:null,anchor:null,target:null,targetAnchor:null,staticCount:0,shapeFlag:s,patchFlag:r,dynamicProps:i,dynamicChildren:null,appContext:null,ctx:Ca};return a?(vk(m,n),s&128&&e.normalize(m)):n&&(m.shapeFlag|=fo(n)?8:16),Xm>0&&!c&&Ul&&(m.patchFlag>0||s&6)&&m.patchFlag!==32&&Ul.push(m),m}const sn=eG;function eG(e,t=null,n=null,r=0,i=null,s=!1){if((!e||e===h3)&&(e=_s),Km(e)){const a=nh(e,t,!0);return n&&vk(a,n),Xm>0&&!s&&Ul&&(a.shapeFlag&6?Ul[Ul.indexOf(e)]=a:Ul.push(a)),a.patchFlag|=-2,a}if(sG(e)&&(e=e.__vccOpts),t){t=dl(t);let{class:a,style:m}=t;a&&!fo(a)&&(t.class=qr(a)),Fi(m)&&(UF(m)&&!Gn(m)&&(m=Go({},m)),t.style=Sa(m))}const c=fo(e)?1:JF(e)?128:K8(e)?64:Fi(e)?4:yr(e)?2:0;return Un(e,t,n,r,i,c,s,!0)}function dl(e){return e?UF(e)||Xx in e?Go({},e):e:null}function nh(e,t,n=!1){const{props:r,ref:i,patchFlag:s,children:c}=e,a=t?Li(r||{},t):r;return{__v_isVNode:!0,__v_skip:!0,type:e.type,props:a,key:a&&S3(a),ref:t&&t.ref?n&&i?Gn(i)?i.concat(bb(t)):[i,bb(t)]:bb(t):i,scopeId:e.scopeId,slotScopeIds:e.slotScopeIds,children:c,target:e.target,targetAnchor:e.targetAnchor,staticCount:e.staticCount,shapeFlag:e.shapeFlag,patchFlag:t&&e.type!==Hn?s===-1?16:s|16:s,dynamicProps:e.dynamicProps,dynamicChildren:e.dynamicChildren,appContext:e.appContext,dirs:e.dirs,transition:e.transition,component:e.component,suspense:e.suspense,ssContent:e.ssContent&&nh(e.ssContent),ssFallback:e.ssFallback&&nh(e.ssFallback),el:e.el,anchor:e.anchor,ctx:e.ctx,ce:e.ce}}function mu(e=" ",t=0){return sn(Td,null,e,t)}function C3(e,t){const n=sn(d_,null,e);return n.staticCount=t,n}function hn(e="",t=!1){return t?(At(),Tr(_s,null,e)):sn(_s,null,e)}function Nl(e){return e==null||typeof e=="boolean"?sn(_s):Gn(e)?sn(Hn,null,e.slice()):typeof e=="object"?Xh(e):sn(Td,null,String(e))}function Xh(e){return e.el===null&&e.patchFlag!==-1||e.memo?e:nh(e)}function vk(e,t){let n=0;const{shapeFlag:r}=e;if(t==null)t=null;else if(Gn(t))n=16;else if(typeof t=="object")if(r&65){const i=t.default;i&&(i._c&&(i._d=!1),vk(e,i()),i._c&&(i._d=!0));return}else{n=32;const i=t._;!i&&!(Xx in t)?t._ctx=Ca:i===3&&Ca&&(Ca.slots._===1?t._=1:(t._=2,e.patchFlag|=1024))}else yr(t)?(t={default:t,_ctx:Ca},n=32):(t=String(t),r&64?(n=16,t=[mu(t)]):n=8);e.children=t,e.shapeFlag|=n}function Li(...e){const t={};for(let n=0;n<e.length;n++){const r=e[n];for(const i in r)if(i==="class")t.class!==r.class&&(t.class=qr([t.class,r.class]));else if(i==="style")t.style=Sa([t.style,r.style]);else if(yv(i)){const s=t[i],c=r[i];c&&s!==c&&!(Gn(s)&&s.includes(c))&&(t[i]=s?[].concat(s,c):c)}else i!==""&&(t[i]=r[i])}return t}function Ls(e,t,n,r=null){Wl(e,t,7,[n,r])}const tG=p3();let nG=0;function rG(e,t,n){const r=e.type,i=(t?t.appContext:e.appContext)||tG,s={uid:nG++,vnode:e,type:r,parent:t,appContext:i,root:null,next:null,subTree:null,effect:null,update:null,scope:new IF(!0),render:null,proxy:null,exposed:null,exposeProxy:null,withProxy:null,provides:t?t.provides:Object.create(i.provides),accessCache:null,renderCache:[],components:null,directives:null,propsOptions:g3(r,i),emitsOptions:QF(r,i),emit:null,emitted:null,propsDefaults:ro,inheritAttrs:r.inheritAttrs,ctx:ro,data:ro,props:ro,attrs:ro,slots:ro,refs:ro,setupState:ro,setupContext:null,attrsProxy:null,slotsProxy:null,suspense:n,suspenseId:n?n.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 s.ctx={_:s},s.root=t?t.root:s,s.emit=l8.bind(null,s),e.ce&&e.ce(s),s}let la=null;const ko=()=>la||Ca;let bk,dm,_I="__VUE_INSTANCE_SETTERS__";(dm=DE()[_I])||(dm=DE()[_I]=[]),dm.push(e=>la=e),bk=e=>{dm.length>1?dm.forEach(t=>t(e)):dm[0](e)};const Ed=e=>{bk(e),e.scope.on()},md=()=>{la&&la.scope.off(),bk(null)};function k3(e){return e.vnode.shapeFlag&4}let B_=!1;function iG(e,t=!1){B_=t;const{props:n,children:r}=e.vnode,i=k3(e);U8(e,n,i,t),q8(e,r);const s=i?oG(e,t):void 0;return B_=!1,s}function oG(e,t){const n=e.type;e.accessCache=Object.create(null),e.proxy=xv(new Proxy(e.ctx,D8));const{setup:r}=n;if(r){const i=e.setupContext=r.length>1?P3(e):null;Ed(e),wg();const s=fd(r,e,0,[e.props,i]);if(Tg(),md(),XC(s)){if(s.then(md,md),t)return s.then(c=>{VE(e,c,t)}).catch(c=>{Tv(c,e,0)});e.asyncDep=s}else VE(e,s,t)}else A3(e,t)}function VE(e,t,n){yr(t)?e.type.__ssrInlineRender?e.ssrRender=t:e.render=t:Fi(t)&&(e.setupState=WF(t)),A3(e,n)}let vI;function A3(e,t,n){const r=e.type;if(!e.render){if(!t&&vI&&!r.render){const i=r.template||mk(e).template;if(i){const{isCustomElement:s,compilerOptions:c}=e.appContext.config,{delimiters:a,compilerOptions:m}=r,g=Go(Go({isCustomElement:s,delimiters:a},c),m);r.render=vI(i,g)}}e.render=r.render||Ac}Ed(e),wg(),R8(e),Tg(),md()}function aG(e){return e.attrsProxy||(e.attrsProxy=new Proxy(e.attrs,{get(t,n){return js(e,"get","$attrs"),t[n]}}))}function P3(e){const t=n=>{e.exposed=n||{}};return{get attrs(){return aG(e)},slots:e.slots,emit:e.emit,expose:t}}function Kx(e){if(e.exposed)return e.exposeProxy||(e.exposeProxy=new Proxy(WF(xv(e.exposed)),{get(t,n){if(n in t)return t[n];if(n in u_)return u_[n](e)},has(t,n){return n in t||n in u_}}))}function GE(e,t=!0){return yr(e)?e.displayName||e.name:e.name||t&&e.__name}function sG(e){return yr(e)&&"__vccOpts"in e}const yt=(e,t)=>r8(e,t,B_);function ao(e,t,n){const r=arguments.length;return r===2?Fi(t)&&!Gn(t)?Km(t)?sn(e,null,[t]):sn(e,t):sn(e,null,t):(r>3?n=Array.prototype.slice.call(arguments,2):r===3&&Km(n)&&(n=[n]),sn(e,t,n))}const lG=Symbol.for("v-scx"),cG=()=>dr(lG),M3="3.3.4",uG="http://www.w3.org/2000/svg",Wf=typeof document<"u"?document:null,bI=Wf&&Wf.createElement("template"),hG={insert:(e,t,n)=>{t.insertBefore(e,n||null)},remove:e=>{const t=e.parentNode;t&&t.removeChild(e)},createElement:(e,t,n,r)=>{const i=t?Wf.createElementNS(uG,e):Wf.createElement(e,n?{is:n}:void 0);return e==="select"&&r&&r.multiple!=null&&i.setAttribute("multiple",r.multiple),i},createText:e=>Wf.createTextNode(e),createComment:e=>Wf.createComment(e),setText:(e,t)=>{e.nodeValue=t},setElementText:(e,t)=>{e.textContent=t},parentNode:e=>e.parentNode,nextSibling:e=>e.nextSibling,querySelector:e=>Wf.querySelector(e),setScopeId(e,t){e.setAttribute(t,"")},insertStaticContent(e,t,n,r,i,s){const c=n?n.previousSibling:t.lastChild;if(i&&(i===s||i.nextSibling))for(;t.insertBefore(i.cloneNode(!0),n),!(i===s||!(i=i.nextSibling)););else{bI.innerHTML=r?`<svg>${e}</svg>`:e;const a=bI.content;if(r){const m=a.firstChild;for(;m.firstChild;)a.appendChild(m.firstChild);a.removeChild(m)}t.insertBefore(a,n)}return[c?c.nextSibling:t.firstChild,n?n.previousSibling:t.lastChild]}};function dG(e,t,n){const r=e._vtc;r&&(t=(t?[t,...r]:[...r]).join(" ")),t==null?e.removeAttribute("class"):n?e.setAttribute("class",t):e.className=t}function fG(e,t,n){const r=e.style,i=fo(n);if(n&&!i){if(t&&!fo(t))for(const s in t)n[s]==null&&qE(r,s,"");for(const s in n)qE(r,s,n[s])}else{const s=r.display;i?t!==n&&(r.cssText=n):t&&e.removeAttribute("style"),"_vod"in e&&(r.display=s)}}const xI=/\s*!important$/;function qE(e,t,n){if(Gn(n))n.forEach(r=>qE(e,t,r));else if(n==null&&(n=""),t.startsWith("--"))e.setProperty(t,n);else{const r=pG(e,t);xI.test(n)?e.setProperty(bp(r),n.replace(xI,""),"important"):e[r]=n}}const wI=["Webkit","Moz","ms"],uT={};function pG(e,t){const n=uT[t];if(n)return n;let r=Pc(t);if(r!=="filter"&&r in e)return uT[t]=r;r=_v(r);for(let i=0;i<wI.length;i++){const s=wI[i]+r;if(s in e)return uT[t]=s}return t}const TI="http://www.w3.org/1999/xlink";function mG(e,t,n,r,i){if(r&&t.startsWith("xlink:"))n==null?e.removeAttributeNS(TI,t.slice(6,t.length)):e.setAttributeNS(TI,t,n);else{const s=x6(t);n==null||s&&!PF(n)?e.removeAttribute(t):e.setAttribute(t,s?"":n)}}function gG(e,t,n,r,i,s,c){if(t==="innerHTML"||t==="textContent"){r&&c(r,i,s),e[t]=n??"";return}const a=e.tagName;if(t==="value"&&a!=="PROGRESS"&&!a.includes("-")){e._value=n;const g=a==="OPTION"?e.getAttribute("value"):e.value,x=n??"";g!==x&&(e.value=x),n==null&&e.removeAttribute(t);return}let m=!1;if(n===""||n==null){const g=typeof e[t];g==="boolean"?n=PF(n):n==null&&g==="string"?(n="",m=!0):g==="number"&&(n=0,m=!0)}try{e[t]=n}catch{}m&&e.removeAttribute(t)}function I3(e,t,n,r){e.addEventListener(t,n,r)}function yG(e,t,n,r){e.removeEventListener(t,n,r)}function _G(e,t,n,r,i=null){const s=e._vei||(e._vei={}),c=s[t];if(r&&c)c.value=r;else{const[a,m]=vG(t);if(r){const g=s[t]=wG(r,i);I3(e,a,g,m)}else c&&(yG(e,a,c,m),s[t]=void 0)}}const EI=/(?:Once|Passive|Capture)$/;function vG(e){let t;if(EI.test(e)){t={};let r;for(;r=e.match(EI);)e=e.slice(0,e.length-r[0].length),t[r[0].toLowerCase()]=!0}return[e[2]===":"?e.slice(3):bp(e.slice(2)),t]}let hT=0;const bG=Promise.resolve(),xG=()=>hT||(bG.then(()=>hT=0),hT=Date.now());function wG(e,t){const n=r=>{if(!r._vts)r._vts=Date.now();else if(r._vts<=n.attached)return;Wl(TG(r,n.value),t,5,[r])};return n.value=e,n.attached=xG(),n}function TG(e,t){if(Gn(t)){const n=e.stopImmediatePropagation;return e.stopImmediatePropagation=()=>{n.call(e),e._stopped=!0},t.map(r=>i=>!i._stopped&&r&&r(i))}else return t}const SI=/^on[a-z]/,EG=(e,t,n,r,i=!1,s,c,a,m)=>{t==="class"?dG(e,r,i):t==="style"?fG(e,n,r):yv(t)?YC(t)||_G(e,t,n,r,c):(t[0]==="."?(t=t.slice(1),!0):t[0]==="^"?(t=t.slice(1),!1):SG(e,t,r,i))?gG(e,t,r,s,c,a,m):(t==="true-value"?e._trueValue=r:t==="false-value"&&(e._falseValue=r),mG(e,t,r,i))};function SG(e,t,n,r){return r?!!(t==="innerHTML"||t==="textContent"||t in e&&SI.test(t)&&yr(n)):t==="spellcheck"||t==="draggable"||t==="translate"||t==="form"||t==="list"&&e.tagName==="INPUT"||t==="type"&&e.tagName==="TEXTAREA"||SI.test(t)&&fo(n)?!1:t in e}const Uh="transition",Dy="animation",bs=(e,{slots:t})=>ao(T8,D3(e),t);bs.displayName="Transition";const O3={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},CG=bs.props=Go({},r3,O3),Mf=(e,t=[])=>{Gn(e)?e.forEach(n=>n(...t)):e&&e(...t)},CI=e=>e?Gn(e)?e.some(t=>t.length>1):e.length>1:!1;function D3(e){const t={};for(const ce in e)ce in O3||(t[ce]=e[ce]);if(e.css===!1)return t;const{name:n="v",type:r,duration:i,enterFromClass:s=`${n}
1-enter-from`,enterActiveClass:c=`${n}-enter-active`,enterToClass:a=`${n}-enter-to`,appearFromClass:m=s,appearActiveClass:g=c,appearToClass:x=a,leaveFromClass:T=`${n}-leave-from`,leaveActiveClass:C=`${n}-leave-active`,leaveToClass:A=`${n}-leave-to`}=e,P=kG(i),D=P&&P[0],B=P&&P[1],{onBeforeEnter:R,onEnter:N,onEnterCancelled:j,onLeave:U,onLeaveCancelled:W,onBeforeAppear:Q=R,onAppear:Z=N,onAppearCancelled:K=j}=t,Y=(ce,fe,ie)=>{Hh(ce,fe?x:a),Hh(ce,fe?g:c),ie&&ie()},me=(ce,fe)=>{ce._isLeaving=!1,Hh(ce,T),Hh(ce,A),Hh(ce,C),fe&&fe()},ge=ce=>(fe,ie)=>{const xe=ce?Z:N,Te=()=>Y(fe,ce,ie);Mf(xe,[fe,Te]),kI(()=>{Hh(fe,ce?m:s),Wu(fe,ce?x:a),CI(xe)||AI(fe,r,D,Te)})};return Go(t,{onBeforeEnter(ce){Mf(R,[ce]),Wu(ce,s),Wu(ce,c)},onBeforeAppear(ce){Mf(Q,[ce]),Wu(ce,m),Wu(ce,g)},onEnter:ge(!1),onAppear:ge(!0),onLeave(ce,fe){ce._isLeaving=!0;const ie=()=>me(ce,fe);Wu(ce,T),R3(),Wu(ce,C),kI(()=>{ce._isLeaving&&(Hh(ce,T),Wu(ce,A),CI(U)||AI(ce,r,B,ie))}),Mf(U,[ce,ie])},onEnterCancelled(ce){Y(ce,!1),Mf(j,[ce])},onAppearCancelled(ce){Y(ce,!0),Mf(K,[ce])},onLeaveCancelled(ce){me(ce),Mf(W,[ce])}})}function kG(e){if(e==null)return null;if(Fi(e))return[dT(e.enter),dT(e.leave)];{const t=dT(e);return[t,t]}}function dT(e){return AF(e)}function Wu(e,t){t.split(/\s+/).forEach(n=>n&&e.classList.add(n)),(e._vtc||(e._vtc=new Set)).add(t)}function Hh(e,t){t.split(/\s+/).forEach(r=>r&&e.classList.remove(r));const{_vtc:n}=e;n&&(n.delete(t),n.size||(e._vtc=void 0))}function kI(e){requestAnimationFrame(()=>{requestAnimationFrame(e)})}let AG=0;function AI(e,t,n,r){const i=e._endId=++AG,s=()=>{i===e._endId&&r()};if(n)return setTimeout(s,n);const{type:c,timeout:a,propCount:m}=L3(e,t);if(!c)return r();const g=c+"end";let x=0;const T=()=>{e.removeEventListener(g,C),s()},C=A=>{A.target===e&&++x>=m&&T()};setTimeout(()=>{x<m&&T()},a+1),e.addEventListener(g,C)}function L3(e,t){const n=window.getComputedStyle(e),r=P=>(n[P]||"").split(", "),i=r(`${Uh}Delay`),s=r(`${Uh}Duration`),c=PI(i,s),a=r(`${Dy}Delay`),m=r(`${Dy}Duration`),g=PI(a,m);let x=null,T=0,C=0;t===Uh?c>0&&(x=Uh,T=c,C=s.length):t===Dy?g>0&&(x=Dy,T=g,C=m.length):(T=Math.max(c,g),x=T>0?c>g?Uh:Dy:null,C=x?x===Uh?s.length:m.length:0);const A=x===Uh&&/\b(transform|all)(,|$)/.test(r(`${Uh}Property`).toString());return{type:x,timeout:T,propCount:C,hasTransform:A}}function PI(e,t){for(;e.length<t.length;)e=e.concat(e);return Math.max(...t.map((n,r)=>MI(n)+MI(e[r])))}function MI(e){return Number(e.slice(0,-1).replace(",","."))*1e3}function R3(){return document.body.offsetHeight}const F3=new WeakMap,B3=new WeakMap,z3={name:"TransitionGroup",props:Go({},CG,{tag:String,moveClass:String}),setup(e,{slots:t}){const n=ko(),r=n3();let i,s;return Yx(()=>{if(!i.length)return;const c=e.moveClass||`${e.name||"v"}-move`;if(!LG(i[0].el,n.vnode.el,c))return;i.forEach(IG),i.forEach(OG);const a=i.filter(DG);R3(),a.forEach(m=>{const g=m.el,x=g.style;Wu(g,c),x.transform=x.webkitTransform=x.transitionDuration="";const T=g._moveCb=C=>{C&&C.target!==g||(!C||/transform$/.test(C.propertyName))&&(g.removeEventListener("transitionend",T),g._moveCb=null,Hh(g,c))};g.addEventListener("transitionend",T)})}),()=>{const c=Ar(e),a=D3(c);let m=c.tag||Hn;i=s,s=t.default?dk(t.default()):[];for(let g=0;g<s.length;g++){const x=s[g];x.key!=null&&Zm(x,R_(x,a,r,n))}if(i)for(let g=0;g<i.length;g++){const x=i[g];Zm(x,R_(x,a,r,n)),F3.set(x,x.el.getBoundingClientRect())}return sn(m,null,s)}}},PG=e=>delete e.mode;z3.props;const MG=z3;function IG(e){const t=e.el;t._moveCb&&t._moveCb(),t._enterCb&&t._enterCb()}function OG(e){B3.set(e,e.el.getBoundingClientRect())}function DG(e){const t=F3.get(e),n=B3.get(e),r=t.left-n.left,i=t.top-n.top;if(r||i){const s=e.el.style;return s.transform=s.webkitTransform=`translate(${r}px,${i}px)`,s.transitionDuration="0s",e}}function LG(e,t,n){const r=e.cloneNode();e._vtc&&e._vtc.forEach(c=>{c.split(/\s+/).forEach(a=>a&&r.classList.remove(a))}),n.split(/\s+/).forEach(c=>c&&r.classList.add(c)),r.style.display="none";const i=t.nodeType===1?t:t.parentNode;i.appendChild(r);const{hasTransform:s}=L3(r);return i.removeChild(r),s}const II=e=>{const t=e.props["onUpdate:modelValue"]||!1;return Gn(t)?n=>Rm(t,n):t},b_e={deep:!0,created(e,{value:t,modifiers:{number:n}},r){const i=$x(t);I3(e,"change",()=>{const s=Array.prototype.filter.call(e.options,c=>c.selected).map(c=>n?kF(Xb(c)):Xb(c));e._assign(e.multiple?i?new Set(s):s:s[0])}),e._assign=II(r)},mounted(e,{value:t}){OI(e,t)},beforeUpdate(e,t,n){e._assign=II(n)},updated(e,{value:t}){OI(e,t)}};function OI(e,t){const n=e.multiple;if(!(n&&!Gn(t)&&!$x(t))){for(let r=0,i=e.options.length;r<i;r++){const s=e.options[r],c=Xb(s);if(n)Gn(t)?s.selected=T6(t,c)>-1:s.selected=t.has(c);else if(Ux(Xb(s),t)){e.selectedIndex!==r&&(e.selectedIndex=r);return}}!n&&e.selectedIndex!==-1&&(e.selectedIndex=-1)}}function Xb(e){return"_value"in e?e._value:e.value}const RG=["ctrl","shift","alt","meta"],FG={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)=>
1RG.some(n=>e[`${n}Key`]&&!t.includes(n))},Di=(e,t)=>(n,...r)=>{for(let i=0;i<t.length;i++){const s=FG[t[i]];if(s&&s(n,t))return}return e(n,...r)},BG={esc:"escape",space:" ",up:"arrow-up",left:"arrow-left",right:"arrow-right",down:"arrow-down",delete:"backspace"},br=(e,t)=>n=>{if(!("key"in n))return;const r=bp(n.key);if(t.some(i=>i===r||BG[i]===r))return e(n)},gd={beforeMount(e,{value:t},{transition:n}){e._vod=e.style.display==="none"?"":e.style.display,n&&t?n.beforeEnter(e):Ly(e,t)},mounted(e,{value:t},{transition:n}){n&&t&&n.enter(e)},updated(e,{value:t,oldValue:n},{transition:r}){!t!=!n&&(r?t?(r.beforeEnter(e),Ly(e,!0),r.enter(e)):r.leave(e,()=>{Ly(e,!1)}):Ly(e,t))},beforeUnmount(e,{value:t}){Ly(e,t)}};function Ly(e,t){e.style.display=t?e._vod:"none"}const N3=Go({patchProp:EG},hG);let p_,DI=!1;function $3(){return p_||(p_=Y8(N3))}function zG(){return p_=DI?p_:Z8(N3),DI=!0,p_}const LI=(...e)=>{$3().render(...e)},WE=(...e)=>{const t=$3().createApp(...e),{mount:n}=t;return t.mount=r=>{const i=j3(r);if(!i)return;const s=t._component;!yr(s)&&!s.render&&!s.template&&(s.template=i.innerHTML),i.innerHTML="";const c=n(i,!1,i instanceof SVGElement);return i instanceof Element&&(i.removeAttribute("v-cloak"),i.setAttribute("data-v-app","")),c},t},NG=(...e)=>{const t=zG().createApp(...e),{mount:n}=t;return t.mount=r=>{const i=j3(r);if(i)return n(i,!0,i instanceof SVGElement)},t};function j3(e){return fo(e)?document.querySelector(e):e}const $G=/"(?:_|\\u0{2}5[Ff]){2}(?:p|\\u0{2}70)(?:r|\\u0{2}72)(?:o|\\u0{2}6[Ff])(?:t|\\u0{2}74)(?:o|\\u0{2}6[Ff])(?:_|\\u0{2}5[Ff]){2}"\s*:/,jG=/"(?:c|\\u0063)(?:o|\\u006[Ff])(?:n|\\u006[Ee])(?:s|\\u0073)(?:t|\\u0074)(?:r|\\u0072)(?:u|\\u0075)(?:c|\\u0063)(?:t|\\u0074)(?:o|\\u006[Ff])(?:r|\\u0072)"\s*:/,UG=/^\s*["[{]|^\s*-?\d[\d.]{0,14}\s*$/;function VG(e,t){if(e==="__proto__"||e==="constructor"&&t&&typeof t=="object"&&"prototype"in t){GG(e);return}return t}function GG(e){console.warn(`[destr] Dropping "${e}" key to prevent prototype pollution.`)}function U3(e,t={}){if(typeof e!="string")return e;const n=e.trim();if(e[0]==='"'&&e[e.length-1]==='"')return n.slice(1,-1);if(n.length<=9){const r=n.toLowerCase();if(r==="true")return!0;if(r==="false")return!1;if(r==="undefined")return;if(r==="null")return null;if(r==="nan")return Number.NaN;if(r==="infinity")return Number.POSITIVE_INFINITY;if(r==="-infinity")return Number.NEGATIVE_INFINITY}if(!UG.test(e)){if(t.strict)throw new SyntaxError("[destr] Invalid JSON");return e}try{if($G.test(e)||jG.test(e)){if(t.strict)throw new Error("[destr] Possible prototype pollution");return JSON.parse(e,VG)}return JSON.parse(e)}catch(r){if(t.strict)throw r;return e}}const qG=/#/g,WG=/&/g,HG=/=/g,xk=/\+/g,YG=/%5e/gi,ZG=/%60/gi,XG=/%7c/gi,KG=/%20/gi;function QG(e){return encodeURI(""+e).replace(XG,"|")}function HE(e){return QG(typeof e=="string"?e:JSON.stringify(e)).replace(xk,"%2B").replace(KG,"+").replace(qG,"%23").replace(WG,"%26").replace(ZG,"`").replace(YG,"^")}function fT(e){return HE(e).replace(HG,"%3D")}function Kb(e=""){try{return decodeURIComponent(""+e)}catch{return""+e}}function JG(e){return Kb(e.replace(xk," "))}function eq(e){return Kb(e.replace(xk," "))}function tq(e=""){const t={};e[0]==="?"&&(e=e.slice(1));for(const n of e.split("&")){const r=n.match(/([^=]+)=?(.*)/)||[];if(r.length<2)continue;const i=JG(r[1]);if(i==="__proto__"||i==="constructor")continue;const s=eq(r[2]||"");t[i]===void 0?t[i]=s:Array.isArray(t[i])?t[i].push(s):t[i]=[t[i],s]}return t}function nq(e,t){return(typeof t=="number"||typeof t=="boolean")&&(t=String(t)),t?Array.isArray(t)?t.map(n=>`${fT(e)}=${HE(n)}`).join("&"):`${fT(e)}=${HE(t)}`:fT(e)}function rq(e){return Object.keys(e).filter(t=>e[t]!==void 0).map(t=>nq(t,e[t])).filter(Boolean).join("&")}const iq=/^\w{2,}:([/\\]{1,2})/,oq=/^\w{2,}:([/\\]{2})?/,aq=/^([/\\]\s*){2,}[^/\\]/;function Qx(e,t={}){return typeof t=="boolean"&&(t={acceptRelative:t}),t.strict?iq.test(e):oq.test(e)||(t.acceptRelative?aq.test(e):!1)}const sq=/\/$|\/\?/;
1function YE(e="",t=!1){return t?sq.test(e):e.endsWith("/")}function V3(e="",t=!1){if(!t)return(YE(e)?e.slice(0,-1):e)||"/";if(!YE(e,!0))return e||"/";const[n,...r]=e.split("?");return(n.slice(0,-1)||"/")+(r.length>0?`?${r.join("?")}`:"")}function ZE(e="",t=!1){if(!t)return e.endsWith("/")?e:e+"/";if(YE(e,!0))return e||"/";const[n,...r]=e.split("?");return n+"/"+(r.length>0?`?${r.join("?")}`:"")}function lq(e=""){return e.startsWith("/")}function RI(e=""){return lq(e)?e:"/"+e}function cq(e,t){if(q3(t)||Qx(e))return e;const n=V3(t);return e.startsWith(n)?e:Jx(n,e)}function FI(e,t){if(q3(t))return e;const n=V3(t);if(!e.startsWith(n))return e;const r=e.slice(n.length);return r[0]==="/"?r:"/"+r}function G3(e,t){const n=wk(e),r={...tq(n.search),...t};return n.search=rq(r),fq(n)}function q3(e){return!e||e==="/"}function uq(e){return e&&e!=="/"}const hq=/^\.?\//;function Jx(e,...t){let n=e||"";for(const r of t.filter(i=>uq(i)))if(n){const i=r.replace(hq,"");n=ZE(n)+i}else n=r;return n}function dq(e,t,n={}){return n.trailingSlash||(e=ZE(e),t=ZE(t)),n.leadingSlash||(e=RI(e),t=RI(t)),n.encoding||(e=Kb(e),t=Kb(t)),e===t}function wk(e="",t){if(!Qx(e,{acceptRelative:!0}))return t?wk(t+e):BI(e);const[n="",r,i=""]=(e.replace(/\\/g,"/").match(/([^/:]+:)?\/\/([^/@]+@)?(.*)/)||[]).splice(1),[s="",c=""]=(i.match(/([^#/?]*)(.*)?/)||[]).splice(1),{pathname:a,search:m,hash:g}=BI(c.replace(/\/(?=[A-Za-z]:)/,""));return{protocol:n,auth:r?r.slice(0,Math.max(0,r.length-1)):"",host:s,pathname:a,search:m,hash:g}}function BI(e=""){const[t="",n="",r=""]=(e.match(/([^#?]*)(\?[^#]*)?(#.*)?/)||[]).splice(1);return{pathname:t,search:n,hash:r}}function fq(e){const t=e.pathname+(e.search?(e.search.startsWith("?")?"":"?")+e.search:"")+e.hash;return e.protocol?e.protocol+"//"+(e.auth?e.auth+"@":"")+e.host+t:t}class pq extends Error{constructor(){super(...arguments),this.name="FetchError"}}function mq(e,t,n){let r="";t&&(r=t.message),e&&n?r=`${r} (${n.status} ${n.statusText} (${e.toString()}))`:e&&(r=`${r} (${e.toString()})`);const i=new pq(r);return Object.defineProperty(i,"request",{get(){return e}}),Object.defineProperty(i,"response",{get(){return n}}),Object.defineProperty(i,"data",{get(){return n&&n._data}}),Object.defineProperty(i,"status",{get(){return n&&n.status}}),Object.defineProperty(i,"statusText",{get(){return n&&n.statusText}}),Object.defineProperty(i,"statusCode",{get(){return n&&n.status}}),Object.defineProperty(i,"statusMessage",{get(){return n&&n.statusText}}),i}const gq=new Set(Object.freeze(["PATCH","POST","PUT","DELETE"]));function zI(e="GET"){return gq.has(e.toUpperCase())}function yq(e){if(e===void 0)return!1;const t=typeof e;return t==="string"||t==="number"||t==="boolean"||t===null?!0:t!=="object"?!1:Array.isArray(e)?!0:e.constructor&&e.constructor.name==="Object"||typeof e.toJSON=="function"}const _q=new Set(["image/svg","application/xml","application/xhtml","application/html"]),vq=/^application\/(?:[\w!#$%&*.^`~-]*\+)?json(;.+)?$/i;function bq(e=""){if(!e)return"json";const t=e.split(";").shift()||"";return vq.test(t)?"json":_q.has(t)||t.startsWith("text/")?"text":"blob"}function xq(e,t,n=globalThis.Headers){const r={...t,...e};if(t!=null&&t.params&&(e!=null&&e.params)&&(r.params={...t==null?void 0:t.params,...e==null?void 0:e.params}),t!=null&&t.query&&(e!=null&&e.query)&&(r.query={...t==null?void 0:t.query,...e==null?void 0:e.query}),t!=null&&t.headers&&(e!=null&&e.headers)){r.headers=new n((t==null?void 0:t.headers)||{});for(const[i,s]of new n((e==null?void 0:e.headers)||{}))r.headers.set(i,s)}return r}const wq=new Set([408,409,425,429,500,502,503,504]);function W3(e){const{fetch:t,Headers:n}=e;function r(c){const a=c.error&&c.error.name==="AbortError"||!1;if(c.options.retry!==!1&&!a){let g;typeof c.options.retry=="number"?g=c.options.retry:g=zI(c.options.method)?0:1;const x=c.response&&c.response.status||500;if(g>0&&wq.has(x))return i(c.request,{...c.options,retry:g-1})}const m=mq(c.request,c.error,c.response);throw Error.captureStackTrace&&Error.captureStackTrace(m,i),m}const i=async function(a,m={}){const g={request:a,options:xq(m,e.defaults,n),response:void 0,error:void 0};g.options.onRequest&&await g.options.onRequest(g),typeof g.request=="string"&&(g.options.baseURL&&(g.request=cq(g.request,g.options.baseURL)),(g.options.query||g.options.params)&&(g.request=G3(g.request,{...g.options.params,...g.options.query})),g.options.body&&zI(g.options.method)&&yq(g.options.body)&&(g.options.body=typeof g.options.body=="str
1ing"?g.options.body:JSON.stringify(g.options.body),g.options.headers=new n(g.options.headers||{}),g.options.headers.has("content-type")||g.options.headers.set("content-type","application/json"),g.options.headers.has("accept")||g.options.headers.set("accept","application/json")));try{g.response=await t(g.request,g.options)}catch(T){return g.error=T,g.options.onRequestError&&await g.options.onRequestError(g),await r(g)}const x=(g.options.parseResponse?"json":g.options.responseType)||bq(g.response.headers.get("content-type")||"");if(x==="json"){const T=await g.response.text(),C=g.options.parseResponse||U3;g.response._data=C(T)}else x==="stream"?g.response._data=g.response.body:g.response._data=await g.response[x]();return g.options.onResponse&&await g.options.onResponse(g),!g.options.ignoreResponseError&&g.response.status>=400&&g.response.status<600?(g.options.onResponseError&&await g.options.onResponseError(g),await r(g)):g.response},s=async function(a,m){return(await i(a,m))._data};return s.raw=i,s.native=t,s.create=(c={})=>W3({...e,defaults:{...e.defaults,...c}}),s}const H3=function(){if(typeof globalThis<"u")return globalThis;if(typeof self<"u")return self;if(typeof window<"u")return window;if(typeof global<"u")return global;throw new Error("unable to locate global object")}(),Tq=H3.fetch||(()=>Promise.reject(new Error("[ofetch] global.fetch is not supported!"))),Eq=H3.Headers,Sq=W3({fetch:Tq,Headers:Eq}),Cq=Sq,kq=()=>{var e;return((e=window==null?void 0:window.__NUXT__)==null?void 0:e.config)||{}},Qb=kq().app,Aq=()=>Qb.baseURL,Pq=()=>Qb.buildAssetsDir,Mq=(...e)=>Jx(Y3(),Pq(),...e),Y3=(...e)=>{const t=Qb.cdnURL||Qb.baseURL;return e.length?Jx(t,...e):t};globalThis.__buildAssetsURL=Mq,globalThis.__publicAssetsURL=Y3;function XE(e,t={},n){for(const r in e){const i=e[r],s=n?`${n}:${r}`:r;typeof i=="object"&&i!==null?XE(i,t,s):typeof i=="function"&&(t[s]=i)}return t}const Iq={run:e=>e()},Oq=()=>Iq,Z3=typeof console.createTask<"u"?console.createTask:Oq;function Dq(e,t){const n=t.shift(),r=Z3(n);return e.reduce((i,s)=>i.then(()=>r.run(()=>s(...t))),Promise.resolve())}function Lq(e,t){const n=t.shift(),r=Z3(n);return Promise.all(e.map(i=>r.run(()=>i(...t))))}function pT(e,t){for(const n of[...e])n(t)}class Rq{constructor(){this._hooks={},this._before=void 0,this._after=void 0,this._deprecatedMessages=void 0,this._deprecatedHooks={},this.hook=this.hook.bind(this),this.callHook=this.callHook.bind(this),this.callHookWith=this.callHookWith.bind(this)}hook(t,n,r={}){if(!t||typeof n!="function")return()=>{};const i=t;let s;for(;this._deprecatedHooks[t];)s=this._deprecatedHooks[t],t=s.to;if(s&&!r.allowDeprecated){let c=s.message;c||(c=`${i} hook has been deprecated`+(s.to?`, please use ${s.to}`:"")),this._deprecatedMessages||(this._deprecatedMessages=new Set),this._deprecatedMessages.has(c)||(console.warn(c),this._deprecatedMessages.add(c))}if(!n.name)try{Object.defineProperty(n,"name",{get:()=>"_"+t.replace(/\W+/g,"_")+"_hook_cb",configurable:!0})}catch{}return this._hooks[t]=this._hooks[t]||[],this._hooks[t].push(n),()=>{n&&(this.removeHook(t,n),n=void 0)}}hookOnce(t,n){let r,i=(...s)=>(typeof r=="function"&&r(),r=void 0,i=void 0,n(...s));return r=this.hook(t,i),r}removeHook(t,n){if(this._hooks[t]){const r=this._hooks[t].indexOf(n);r!==-1&&this._hooks[t].splice(r,1),this._hooks[t].length===0&&delete this._hooks[t]}}deprecateHook(t,n){this._deprecatedHooks[t]=typeof n=="string"?{to:n}:n;const r=this._hooks[t]||[];delete this._hooks[t];for(const i of r)this.hook(t,i)}deprecateHooks(t){Object.assign(this._deprecatedHooks,t);for(const n in t)this.deprecateHook(n,t[n])}addHooks(t){const n=XE(t),r=Object.keys(n).map(i=>this.hook(i,n[i]));return()=>{for(const i of r.splice(0,r.length))i()}}removeHooks(t){const n=XE(t);for(const r in n)this.removeHook(r,n[r])}removeAllHooks(){for(const t in this._hooks)delete this._hooks[t]}callHook(t,...n){return n.unshift(t),this.callHookWith(Dq,t,...n)}callHookParallel(t,...n){return n.unshift(t),this.callHookWith(Lq,t,...n)}callHookWith(t,n,...r){const i=this._before||this._after?{name:n,args:r,context:{}}:void 0;this._before&&pT(this._before,i);const s=t(n in this._hooks?[...this._hooks[n]]:[],r);return s instanceof Promise?s.finally(()=>{this._after&&i&&pT(this._after,i)}):(this._after&&i&&pT(this._after,i),s)}beforeEach(t){return this._before=this._before||[],this._before.push(t),()=>{if(this._before!==void 0){const n=this._before.indexOf(t);n!==-1&&this._before.splice(n,1)}}}afterEach(t){return this._after=this._after||[],this._after.push(t),()=>{if(this._after!==void 0){const n=this._after.indexOf(t);n!==-1&&this._after.splice(n,1)}}}}function X3(){return new Rq}function Fq(e={}){let t,n=!1;const r=c=>{if(t&&t!==c)throw new Error("Context conflict")};let i;if(e.asyncContext){const c=e.AsyncLocalStorage||globalThis.AsyncLocalStorage;c?i=new c:console.warn("[unctx] `AsyncLocalStorage` is not provided.")}const s=()=>
1{if(i&&t===void 0){const c=i.getStore();if(c!==void 0)return c}return t};return{use:()=>{const c=s();if(c===void 0)throw new Error("Context is not available");return c},tryUse:()=>s(),set:(c,a)=>{a||r(c),t=c,n=!0},unset:()=>{t=void 0,n=!1},call:(c,a)=>{r(c),t=c;try{return i?i.run(c,a):a()}finally{n||(t=void 0)}},async callAsync(c,a){t=c;const m=()=>{t=c},g=()=>t===c?m:void 0;KE.add(g);try{const x=i?i.run(c,a):a();return n||(t=void 0),await x}finally{KE.delete(g)}}}}function Bq(e={}){const t={};return{get(n,r={}){return t[n]||(t[n]=Fq({...e,...r})),t[n],t[n]}}}const Jb=typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof global<"u"?global:typeof window<"u"?window:{},NI="__unctx__",zq=Jb[NI]||(Jb[NI]=Bq()),Nq=(e,t={})=>zq.get(e,t),$I="__unctx_async_handlers__",KE=Jb[$I]||(Jb[$I]=new Set);function ex(e){const t=[];for(const i of KE){const s=i();s&&t.push(s)}const n=()=>{for(const i of t)i()};let r=e();return r&&typeof r=="object"&&"catch"in r&&(r=r.catch(i=>{throw n(),i})),[r,n]}const K3=Nq("nuxt-app"),$q="__nuxt_plugin";function jq(e){let t=0;const n={provide:void 0,globalName:"nuxt",versions:{get nuxt(){return"3.6.5"},get vue(){return n.vueApp.version}},payload:so({data:{},state:{},_errors:{},...window.__NUXT__??{}}),static:{data:{}},runWithContext:i=>Gq(n,i),isHydrating:!0,deferHydration(){if(!n.isHydrating)return()=>{};t++;let i=!1;return()=>{if(!i&&(i=!0,t--,t===0))return n.isHydrating=!1,n.callHook("app:suspense:resolve")}},_asyncDataPromises:{},_asyncData:{},_payloadRevivers:{},...e};n.hooks=X3(),n.hook=n.hooks.hook,n.callHook=n.hooks.callHook,n.provide=(i,s)=>{const c="$"+i;X0(n,c,s),X0(n.vueApp.config.globalProperties,c,s)},X0(n.vueApp,"$nuxt",n),X0(n.vueApp.config.globalProperties,"$nuxt",n);{window.addEventListener("nuxt.preloadError",s=>{n.callHook("app:chunkError",{error:s.payload})}),window.useNuxtApp=window.useNuxtApp||qo;const i=n.hook("app:error",(...s)=>{console.error("[nuxt] error caught during app initialization",...s)});n.hook("app:mounted",i)}const r=so(n.payload.config);return n.provide("config",r),n}async function Uq(e,t){if(t.hooks&&e.hooks.addHooks(t.hooks),typeof t=="function"){const{provide:n}=await e.runWithContext(()=>t(e))||{};if(n&&typeof n=="object")for(const r in n)e.provide(r,n[r])}}async function Vq(e,t){const n=[],r=[];for(const i of t){const s=Uq(e,i);i.parallel?n.push(s.catch(c=>r.push(c))):await s}if(await Promise.all(n),r.length)throw r[0]}/*! @__NO_SIDE_EFFECTS__ */function Gi(e){return typeof e=="function"?e:(delete e.name,Object.assign(e.setup||(()=>{}),e,{[$q]:!0}))}function Gq(e,t,n){const r=()=>n?t(...n):t();return K3.set(e),e.vueApp.runWithContext(r)}/*! @__NO_SIDE_EFFECTS__ */function qo(){var t;let e;if(gk()&&(e=(t=ko())==null?void 0:t.appContext.app.$nuxt),e=e||K3.tryUse(),!e)throw new Error("[nuxt] instance unavailable");return e}/*! @__NO_SIDE_EFFECTS__ */function Eg(){return qo().$config}function X0(e,t,n){Object.defineProperty(e,t,{get:()=>n})}const qq="modulepreload",Wq=function(e,t){return e.startsWith(".")?new URL(e,t).href:e},jI={},Hq=function(t,n,r){if(!n||n.length===0)return t();const i=document.getElementsByTagName("link");return Promise.all(n.map(s=>{if(s=Wq(s,r),s in jI)return;jI[s]=!0;const c=s.endsWith(".css"),a=c?'[rel="stylesheet"]':"";if(!!r)for(let x=i.length-1;x>=0;x--){const T=i[x];if(T.href===s&&(!c||T.rel==="stylesheet"))return}else if(document.querySelector(`link[href="${s}"]${a}`))return;const g=document.createElement("link");if(g.rel=c?"stylesheet":qq,c||(g.as="script",g.crossOrigin=""),g.href=s,document.head.appendChild(g),c)return new Promise((x,T)=>{g.addEventListener("load",x),g.addEventListener("error",()=>T(new Error(`Unable to preload CSS for ${s}`)))})})).then(()=>t())},Sn=(...e)=>Hq(...e).catch(t=>{const n=new Event("nuxt.preloadError");throw n.payload=t,window.dispatchEvent(n),t}),Yq=-1,Zq=-2,Xq=-3,Kq=-4,Qq=-5,Jq=-6;function eW(e,t){return tW(JSON.parse(e),t)}function tW(e,t){if(typeof e=="number")return i(e,!0);if(!Array.isArray(e)||e.length===0)throw new Error("Invalid input");const n=e,r=Array(n.length);function i(s,c=!1){if(s===Yq)return;if(s===Xq)return NaN;if(s===Kq)return 1/0;if(s===Qq)return-1/0;if(s===Jq)return-0;if(c)throw new Error("Invalid input");if(s in r)return r[s];const a=n[s];if(!a||typeof a!="object")r[s]=a;else if(Array.isArray(a))if(typeof a[0]=="string"){const m=a[0],g=t==null?void 0:t[m];if(g)return r[s]=g(i(a[1]));switch(m){case"Date":r[s]=new Date(a[1]);break;case"Set":const x=new Set;r[s]=x;for(let A=1;A<a.length;A+=1)x.add(i(a[A]));break;case"Map":const T=new Map;r[s]=T;for(let A=1;A<a.length;A+=2)T.set(i(a[A]),i(a[A+1]));break;case"RegExp":r[s]=new RegExp(a[1],a[2]);break;case"Object":r[s]=Object(a[1]);break;case"BigInt":r[s]=BigInt(a[1]);break;case"null":const C=Object.create(null);r[s]=C;for(let A=1;A<a.length;A+=2)C[a[A]]=i(a[A+1]);break;default:throw new Error(`Unknown type ${m}`)}}else{const m=new Array(a.length);r[s]=m;for(let g=0;g<a.length;g+=1){const x=a[g];x!==Zq&&(m[g]=i(x))}}else{const m={};r[s]=m;for(const g in a){const x=a[g];m[g]=i(x)}}return r[s]}return i(0)}function nW(e){return Array.isArray(e)?e:[e]}const Q3=["title","script","style","noscript"],J3=["base","meta","link","style","script","noscript"],rW=["title","titleTemplate","templateParams","base","htmlAttrs","bodyAttrs","meta","link","style","script","noscript"],iW=["base","title","titleTemplate","bodyAttrs","htmlAttrs","templateParams"],UI=["tagPosition","tagPriority","tagDuplicateStrategy","innerHTML","textContent"];function eB(e){let t=9;for(let n=0;n<e.length;)t=Math.imul(t^e.charCodeAt(n++),9**9);return((t^t>>>9)+65536).toString(16).substring(1,8).toLowerCase()}function QE(e){return eB(`${e.tag}:${e.textContent||e.innerHTML||""}:${Object.entries(e.props).map(([t,n])=>`${t}:${String(n)}`).join(",")}`)}function oW(e){let t=9;for(const n of e)for(let r=0;r<n.length;
1)t=Math.imul(t^n.charCodeAt(r++),9**9);return((t^t>>>9)+65536).toString(16).substring(1,8).toLowerCase()}function tB(e,t){const{props:n,tag:r}=e;if(iW.includes(r))return r;if(r==="link"&&n.rel==="canonical")return"canonical";if(n.charset)return"charset";const i=["id"];r==="meta"&&i.push("name","property","http-equiv");for(const s of i)if(typeof n[s]<"u"){const c=String(n[s]);return t&&!t(c)?!1:`${r}:${s}:${c}`}return!1}function VI(e,t){return e==null?t||null:typeof e=="function"?e(t):e}function K0(e,t=!1,n){const{tag:r,$el:i}=e;i&&(Object.entries(r.props).forEach(([s,c])=>{c=String(c);const a=`attr:${s}`;if(s==="class"){if(!c)return;for(const m of c.split(" ")){const g=`${a}:${m}`;n&&n(e,g,()=>i.classList.remove(m)),i.classList.contains(m)||i.classList.add(m)}return}n&&!s.startsWith("data-h-")&&n(e,a,()=>i.removeAttribute(s)),(t||i.getAttribute(s)!==c)&&i.setAttribute(s,c)}),Q3.includes(r.tag)&&(r.textContent&&r.textContent!==i.textContent?i.textContent=r.textContent:r.innerHTML&&r.innerHTML!==i.innerHTML&&(i.innerHTML=r.innerHTML)))}let Ry=!1;async function aW(e,t={}){var C,A;const n={shouldRender:!0};if(await e.hooks.callHook("dom:beforeRender",n),!n.shouldRender)return;const r=t.document||e.resolvedOptions.document||window.document,i=(await e.resolveTags()).map(a);
1if(e.resolvedOptions.experimentalHashHydration&&(Ry=Ry||e._hash||!1,Ry)){const P=oW(i.map(D=>D.tag._h));if(Ry===P)return;Ry=P}const s=e._popSideEffectQueue();e.headEntries().map(P=>P._sde).forEach(P=>{Object.entries(P).forEach(([D,B])=>{s[D]=B})});const c=(P,D,B)=>{D=`${P.renderId}:${D}`,P.entry&&(P.entry._sde[D]=B),delete s[D]};function a(P){const D=e.headEntries().find(R=>R._i===P._e),B={renderId:P._d||QE(P),$el:null,shouldRender:!0,tag:P,entry:D,markSideEffect:(R,N)=>c(B,R,N)};return B}const m=[],g={body:[],head:[]},x=P=>{e._elMap[P.renderId]=P.$el,m.push(P),c(P,"el",()=>{var D;(D=P.$el)==null||D.remove(),delete e._elMap[P.renderId]})};for(const P of i){if(await e.hooks.callHook("dom:beforeRenderTag",P),!P.shouldRender)continue;const{tag:D}=P;if(D.tag==="title"){r.title=D.textContent||"",m.push(P);continue}if(D.tag==="htmlAttrs"||D.tag==="bodyAttrs"){P.$el=r[D.tag==="htmlAttrs"?"documentElement":"body"],K0(P,!1,c),m.push(P);continue}if(P.$el=e._elMap[P.renderId],!P.$el&&D.key&&(P.$el=r.querySelector(`${(C=D.tagPosition)!=null&&C.startsWith("body")?"body":"head"} > ${D.tag}[data-h-${D._h}]`)),P.$el){P.tag._d&&K0(P),x(P);continue}g[(A=D.tagPosition)!=null&&A.startsWith("body")?"body":"head"].push(P)}const T={bodyClose:void 0,bodyOpen:void 0,head:void 0};Object.entries(g).forEach(([P,D])=>{var R;if(!D.length)return;const B=(R=r==null?void 0:r[P])==null?void 0:R.children;if(B){for(const N of[...B].reverse()){const j=N.tagName.toLowerCase();if(!J3.includes(j))continue;const U=N.getAttributeNames().reduce((K,Y)=>({...K,[Y]:N.getAttribute(Y)}),{}),W={tag:j,props:U};N.innerHTML&&(W.innerHTML=N.innerHTML);const Q=QE(W);let Z=D.findIndex(K=>(K==null?void 0:K.renderId)===Q);if(Z===-1){const K=tB(W);Z=D.findIndex(Y=>(Y==null?void 0:Y.tag._d)&&Y.tag._d===K)}if(Z!==-1){const K=D[Z];K.$el=N,K0(K),x(K),delete D[Z]}}D.forEach(N=>{const j=N.tag.tagPosition||"head";T[j]=T[j]||r.createDocumentFragment(),N.$el||(N.$el=r.createElement(N.tag.tag),K0(N,!0)),T[j].appendChild(N.$el),x(N)})}}),T.head&&r.head.appendChild(T.head),T.bodyOpen&&r.body.insertBefore(T.bodyOpen,r.body.firstChild),T.bodyClose&&r.body.appendChild(T.bodyClose);for(const P of m)await e.hooks.callHook("dom:renderTag",P);Object.values(s).forEach(P=>P())}let mT=null;async function sW(e,t={}){function n(){return mT=null,aW(e,t)}const r=t.delayFn||(i=>setTimeout(i,10));return mT=mT||new Promise(i=>r(()=>i(n())))}function lW(e){return{hooks:{"entries:updated":function(t){if(typeof(e==null?void 0:e.document)>"u"&&typeof window>"u")return;let n=e==null?void 0:e.delayFn;!n&&typeof requestAnimationFrame<"u"&&(n=requestAnimationFrame),sW(t,{document:(e==null?void 0:e.document)||window.document,delayFn:n})}}}}function cW(e){var t;return((t=e==null?void 0:e.head.querySelector('meta[name="unhead:ssr"]'))==null?void 0:t.getAttribute("content"))||!1}const GI={base:-1,title:1},qI={critical:-8,high:-1,low:2};function tx(e){let t=10;const n=e.tagPriority;return typeof n=="number"?n:(e.tag==="meta"?(e.props.charset&&(t=-2),e.props["http-equiv"]==="content-security-policy"&&(t=0)):e.tag=="link"&&e.props.rel==="preconnect"?t=2:e.tag in GI&&(t=GI[e.tag]),typeof n=="string"&&n in qI?t+qI[n]:t)}const uW=[{prefix:"before:",offset:-1},{prefix:"after:",offset:1}];function hW(){return{hooks:{"tags:resolve":e=>{const t=n=>{var r;return(r=e.tags.find(i=>i._d===n))==null?void 0:r._p};for(const{prefix:n,offset:r}of uW)for(const i of e.tags.filter(s=>typeof s.tagPriority=="string"&&s.tagPriority.startsWith(n))){const s=t(i.tagPriority.replace(n,""));typeof s<"u"&&(i._p=s+r)}e.tags.sort((n,r)=>n._p-r._p).sort((n,r)=>tx(n)-tx(r))}}}}function dW(){return{hooks:{"tags:resolve":e=>{const{tags:t}=e;let n=t.findIndex(i=>i.tag==="titleTemplate");const r=t.findIndex(i=>i.tag==="title");if(r!==-1&&n!==-1){const i=VI(t[n].textContent,t[r].textContent);i!==null?t[r].textContent=i||t[r].textContent:delete t[r]}else if(n!==-1){const i=VI(t[n].textContent);i!==null&&(t[n].textContent=i,t[n].tag="title",n=-1)}n!==-1&&delete t[n],e.tags=t.filter(Boolean)}}}}function fW(){return{hooks:{"tag:normalise":function({tag:e}){typeof e.props.body<"u"&&(e.tagPosition="bodyClose",delete e.props.body)}}}}const pW=["link","style","script","noscript"];function mW(){return{hooks:{"tag:normalise":({tag:e,resolvedOptions:t})=>{t.experimentalHashHydration===!0&&(e._h=QE(e)),e.key&&pW.includes(e.tag)&&(e._h=eB(e.key),e.props[`data-h-${e._h}`]="")}}}}const WI=["script","link","bodyAttrs"];function gW(){const e=(t,n)=>{const r={},i={};
1Object.entries(n.props).forEach(([c,a])=>{c.startsWith("on")&&typeof a=="function"?i[c]=a:r[c]=a});let s;return t==="dom"&&n.tag==="script"&&typeof r.src=="string"&&typeof i.onload<"u"&&(s=r.src,delete r.src),{props:r,eventHandlers:i,delayedSrc:s}};return{hooks:{"ssr:render":function(t){t.tags=t.tags.map(n=>(!WI.includes(n.tag)||!Object.entries(n.props).find(([r,i])=>r.startsWith("on")&&typeof i=="function")||(n.props=e("ssr",n).props),n))},"dom:beforeRenderTag":function(t){if(!WI.includes(t.tag.tag)||!Object.entries(t.tag.props).find(([s,c])=>s.startsWith("on")&&typeof c=="function"))return;const{props:n,eventHandlers:r,delayedSrc:i}=e("dom",t.tag);Object.keys(r).length&&(t.tag.props=n,t.tag._eventHandlers=r,t.tag._delayedSrc=i)},"dom:renderTag":function(t){const n=t.$el;if(!t.tag._eventHandlers||!n)return;const r=t.tag.tag==="bodyAttrs"&&typeof window<"u"?window:n;Object.entries(t.tag._eventHandlers).forEach(([i,s])=>{const c=`${t.tag._d||t.tag._p}:${i}`,a=i.slice(2).toLowerCase(),m=`data-h-${a}`;if(t.markSideEffect(c,()=>{}),n.hasAttribute(m))return;const g=s;n.setAttribute(m,""),r.addEventListener(a,g),t.entry&&(t.entry._sde[c]=()=>{r.removeEventListener(a,g),n.removeAttribute(m)})}),t.tag._delayedSrc&&n.setAttribute("src",t.tag._delayedSrc)}}}}const yW=["templateParams","htmlAttrs","bodyAttrs"];function _W(){return{hooks:{"tag:normalise":function({tag:e}){["hid","vmid","key"].forEach(r=>{e.props[r]&&(e.key=e.props[r],delete e.props[r])});const n=tB(e)||(e.key?`${e.tag}:${e.key}`:!1);n&&(e._d=n)},"tags:resolve":function(e){const t={};e.tags.forEach(r=>{const i=(r.key?`${r.tag}:${r.key}`:r._d)||r._p,s=t[i];if(s){let a=r==null?void 0:r.tagDuplicateStrategy;if(!a&&yW.includes(r.tag)&&(a="merge"),a==="merge"){const m=s.props;["class","style"].forEach(g=>{r.props[g]&&m[g]&&(g==="style"&&!m[g].endsWith(";")&&(m[g]+=";"),r.props[g]=`${m[g]} ${r.props[g]}`)}),t[i].props={...m,...r.props};return}else if(r._e===s._e){s._duped=s._duped||[],r._d=`${s._d}:${s._duped.length+1}`,s._duped.push(r);return}else if(tx(r)>tx(s))return}const c=Object.keys(r.props).length+(r.innerHTML?1:0)+(r.textContent?1:0);if(J3.includes(r.tag)&&c===0){delete t[i];return}t[i]=r});const n=[];Object.values(t).forEach(r=>{const i=r._duped;delete r._duped,n.push(r),i&&n.push(...i)}),e.tags=n}}}}function Fy(e,t){if(typeof e!="string")return e;function n(c){if(["s","pageTitle"].includes(c))return t.pageTitle;let a;return c.includes(".")?a=c.split(".").reduce((m,g)=>m&&m[g]||void 0,t):a=t[c],typeof a<"u"?a||"":!1}let r=e;try{r=decodeURI(e)}catch{}(r.match(/%(\w+\.+\w+)|%(\w+)/g)||[]).sort().reverse().forEach(c=>{const a=n(c.slice(1));typeof a=="string"&&(e=e.replace(new RegExp(`\\${c}(\\W|$)`,"g"),(m,g)=>`${a}${g}`).trim())});const s=t.separator;return e.includes(s)&&(e.endsWith(s)&&(e=e.slice(0,-s.length).trim()),e.startsWith(s)&&(e=e.slice(s.length).trim()),e=e.replace(new RegExp(`\\${s}\\s*\\${s}`,"g"),s)),e}function vW(){return{hooks:{"tags:resolve":e=>{var s;const{tags:t}=e,n=(s=t.find(c=>c.tag==="title"))==null?void 0:s.textContent,r=t.findIndex(c=>c.tag==="templateParams"),i=r!==-1?t[r].props:{};i.separator=i.separator||"|",i.pageTitle=Fy(i.pageTitle||n||"",i);for(const c of t)if(["titleTemplate","title"].includes(c.tag)&&typeof c.textContent=="string")c.textContent=Fy(c.textContent,i);else if(c.tag==="meta"&&typeof c.props.content=="string")c.props.content=Fy(c.props.content,i);else if(c.tag==="link"&&typeof c.props.href=="string")c.props.href=Fy(c.props.href,i);else if(c.tag==="script"&&["application/json","application/ld+json"].includes(c.props.type)&&typeof c.innerHTML=="string")try{c.innerHTML=JSON.stringify(JSON.parse(c.innerHTML),(a,m)=>typeof m=="string"?Fy(m,i):m)}catch{}e.tags=t.filter(c=>c.tag!=="templateParams")}}}}const bW=typeof window<"u";let nB;function xW(e){return nB=e}function wW(){return nB}async function TW(e,t,n){const r={tag:e,props:{}};return t instanceof Promise&&(t=await t),e==="templateParams"?(r.props=t,r):["title","titleTemplate"].includes(e)?(t&&typeof t=="object"?(r.textContent=t.textContent,t.tagPriority&&(r.tagPriority=t.tagPriority)):r.textContent=t,r):typeof t=="string"?["script","noscript","style"].includes(e)?(e==="script"&&(/^(https?:)?\/\//.test(t)||t.startsWith("/"))?r.props.src=t:r.innerHTML=t,r):!1:(r.props=await SW(e,{...t}),r.props.children&&(r.props.innerHTML=r.props.children),delete r.props.children,Object.keys(r.props).filter(i=>
1UI.includes(i)).forEach(i=>{(!["innerHTML","textContent"].includes(i)||Q3.includes(r.tag))&&(r[i]=r.props[i]),delete r.props[i]}),UI.forEach(i=>{!r[i]&&n[i]&&(r[i]=n[i])}),["innerHTML","textContent"].forEach(i=>{if(r.tag==="script"&&typeof r[i]=="string"&&["application/ld+json","application/json"].includes(r.props.type))try{r[i]=JSON.parse(r[i])}catch{r[i]=""}typeof r[i]=="object"&&(r[i]=JSON.stringify(r[i]))}),r.props.class&&(r.props.class=EW(r.props.class)),r.props.content&&Array.isArray(r.props.content)?r.props.content.map(i=>({...r,props:{...r.props,content:i}})):r)}function EW(e){return typeof e=="object"&&!Array.isArray(e)&&(e=Object.keys(e).filter(t=>e[t])),(Array.isArray(e)?e.join(" "):e).split(" ").filter(t=>t.trim()).filter(Boolean).join(" ")}async function SW(e,t){for(const n of Object.keys(t)){const r=n.startsWith("data-");t[n]instanceof Promise&&(t[n]=await t[n]),String(t[n])==="true"?t[n]=r?"true":"":String(t[n])==="false"&&(r?t[n]="false":delete t[n])}return t}const CW=10;async function kW(e){const t=[];return Object.entries(e.resolvedInput).filter(([n,r])=>typeof r<"u"&&rW.includes(n)).forEach(([n,r])=>{const i=nW(r);t.push(...i.map(s=>TW(n,s,e)).flat())}),(await Promise.all(t)).flat().filter(Boolean).map((n,r)=>(n._e=e._i,n._p=(e._i<<CW)+r,n))}function AW(){return[_W(),hW(),vW(),dW(),mW(),gW(),fW()]}function PW(e={}){return[lW({document:e==null?void 0:e.document,delayFn:e==null?void 0:e.domDelayFn})]}function MW(e={}){const t=IW({...e,plugins:[...PW(e),...(e==null?void 0:e.plugins)||[]]});return e.experimentalHashHydration&&t.resolvedOptions.document&&(t._hash=cW(t.resolvedOptions.document)),xW(t),t}function IW(e={}){let t=[],n={},r=0;const i=X3();e!=null&&e.hooks&&i.addHooks(e.hooks),e.plugins=[...AW(),...(e==null?void 0:e.plugins)||[]],e.plugins.forEach(a=>a.hooks&&i.addHooks(a.hooks)),e.document=e.document||(bW?document:void 0);const s=()=>i.callHook("entries:updated",c),c={resolvedOptions:e,headEntries(){return t},get hooks(){return i},use(a){a.hooks&&i.addHooks(a.hooks)},push(a,m){const g={_i:r++,input:a,_sde:{},...m},x=(g==null?void 0:g.mode)||e.mode;return x&&(g.mode=x),t.push(g),s(),{dispose(){t=t.filter(T=>T._i!==g._i?!0:(n={...n,...T._sde||{}},T._sde={},s(),!1))},patch(T){t=t.map(C=>(C._i===g._i&&(g.input=C.input=T,s()),C))}}},async resolveTags(){const a={tags:[],entries:[...t]};await i.callHook("entries:resolve",a);for(const m of a.entries){const g=m.resolvedInput||m.input;if(m.resolvedInput=await(m.transform?m.transform(g):g),m.resolvedInput)for(const x of await kW(m)){const T={tag:x,entry:m,resolvedOptions:c.resolvedOptions};await i.callHook("tag:normalise",T),a.tags.push(T.tag)}}return await i.callHook("tags:beforeResolve",a),await i.callHook("tags:resolve",a),a.tags},_popSideEffectQueue(){const a={...n};return n={},a},_elMap:{}};return c.hooks.callHook("init",c),c}function OW(e){return typeof e=="function"?e():bt(e)}function nx(e,t=""){if(e instanceof Promise)return e;const n=OW(e);return!e||!n?n:Array.isArray(n)?n.map(r=>nx(r,t)):typeof n=="object"?Object.fromEntries(Object.entries(n).map(([r,i])=>r==="titleTemplate"||r.startsWith("on")?[r,bt(i)]:[r,nx(i,r)])):n}const DW=M3.startsWith("3"),LW=typeof window<"u",rB="usehead";function Tk(){return ko()&&dr(rB)||wW()}function RW(e){return{install(n){DW&&(n.config.globalProperties.$unhead=e,n.config.globalProperties.$head=e,n.provide(rB,e))}}.install}function FW(e={}){const t=MW({...e,domDelayFn:n=>setTimeout(()=>Qi(()=>n()),10),plugins:[BW(),...(e==null?void 0:e.plugins)||[]]});return t.install=RW(t),t}function BW(){return{hooks:{"entries:resolve":function(e){for(const t of e.entries)t.resolvedInput=nx(t.input)}}}}function zW(e,t={}){const n=Tk(),r=jt(!1),i=jt({});sh(()=>{i.value=r.value?{}:nx(e)});const s=n.push(i.value,t);return Nn(i,a=>{s.patch(a)}),ko()&&(xp(()=>{s.dispose()}),a3(()=>{r.value=!0}),o3(()=>{r.value=!1})),s}function NW(e,t={}){return Tk().push(e,t)}function $W(e,t={}){var r;const n=Tk();if(n){const i=LW||!!((r=n.resolvedOptions)!=null&&r.document);return t.mode==="server"&&i||t.mode==="client"&&!i?void 0:i?zW(e,t):NW(e,t)}}const jW={meta:[{name:"viewport",content:"width=device-width, initial-scale=1"},{charset:"utf-8"},{hid:"description",name:"description",content:"BRIK menyediakan semua bahan bangunan, mulai dari beton readymix hingga cat tembok, dengan harga terjangkau. Kunjungi BRIK hari ini untuk mewujudkan rumah impian Anda!"},{hid:"og:locale",property:"og:locale",content:"id_ID"},{hid:"og:site_name",property:"og:site_name",content:"BRIK"},{hid:"og:type",property:"og:type",content:"website"},{hid:"og:url",property:"og:url",content:"https://brik.id"},{hid:"og:image:secure_url",property:"og:image:secure_url",content:"https://brik.id/
1display.png"},{hid:"og:title",property:"og:title",content:"BRIK"},{hid:"og:description",property:"og:description",content:"BRIK menyediakan semua bahan bangunan, mulai dari beton readymix hingga cat tembok, dengan harga terjangkau. Kunjungi BRIK hari ini untuk mewujudkan rumah impian Anda!"},{hid:"og:image",property:"og:image",content:"https://brik.id/display.png"},{name:"twitter:card",content:"summary_large_image"},{hid:"twitter:url",name:"twitter:url",content:"https://brik.id"},{hid:"twitter:title",name:"twitter:title",content:"BRIK"},{hid:"twitter:description",name:"twitter:description",content:"BRIK menyediakan semua bahan bangunan, mulai dari beton readymix hingga cat tembok, dengan harga terjangkau. Kunjungi BRIK hari ini untuk mewujudkan rumah impian Anda!"},{hid:"twitter:image",name:"twitter:image",content:"https://brik.id/display.png"},{hid:"twitter:label1",name:"twitter:label1",content:"Written by"},{name:"mobile-web-app-capable",content:"yes",key:"mobile-web-app-capable"},{name:"apple-mobile-web-app-title",content:"BRIK",key:"apple-mobile-web-app-title"},{name:"author",content:"BRIK",key:"author"},{name:"description",content:"BRIK menyediakan semua bahan bangunan, mulai dari beton readymix hingga cat tembok, dengan harga terjangkau. Kunjungi BRIK hari ini untuk mewujudkan rumah impian Anda!",key:"description"},{name:"theme-color",content:"#ffcd03",key:"theme-color"},{property:"og:type",content:"website",key:"og:type"},{property:"og:title",content:"BRIK",key:"og:title"},{property:"og:site_name",content:"BRIK - [Re]Constructing Construction",key:"og:site_name"},{property:"og:description",content:"BRIK menyediakan semua bahan bangunan, mulai dari beton readymix hingga cat tembok, dengan harga terjangkau. Kunjungi BRIK hari ini untuk mewujudkan rumah impian Anda!",key:"og:description"},{name:"twitter:card",content:"summary",key:"twitter:card"}],link:[{rel:"stylesheet",href:"https://rsms.me/inter/inter.css"},{rel:"preconnect",href:"https://rsms.me/"},{rel:"icon",type:"image/x-icon",href:"/favicon.ico"},{rel:"canonical",href:"https://brik.id"},{rel:"icon",href:"/_nuxt/icons/64x64.5a938ee5.png",key:"favicon"},{rel:"apple-touch-icon",href:"/_nuxt/icons/512x512.maskable.5a938ee5.png",sizes:"512x512",key:"favicon-apple"},{rel:"manifest",href:"/manifest.json"}],style:[],script:[{src:"/js/vue-scrollto.js"}],noscript:[],title:"BRIK",titleTemplate:"%s | BRIK - [Re]Constructing Construction",htmlAttrs:{lang:"en"}},UW=!1,JE=!1,VW=!1,GW="__nuxt",qW=!0;async function WW(e){try{return qW?iB(await fetch(e).then(t=>t.text())):await Sn(()=>import(e),[],import.meta.url).then(t=>t.default||t)}catch(t){console.warn("[nuxt] Cannot load payload ",e,t)}return null}let Q0=null;async function HW(){if(Q0)return Q0;const e=document.getElementById("__NUXT_DATA__");if(!e)return{};const t=iB(e.textContent||""),n=e.dataset.src?await WW(e.dataset.src):void 0;return Q0={...t,...n,...window.__NUXT__},Q0}function iB(e){return eW(e,qo()._payloadRevivers)}function YW(e,t){qo()._payloadRevivers[e]=t}const J0=/^[\u0009\u0020-\u007E\u0080-\u00FF]+$/;function ZW(e,t){if(typeof e!="string")throw new TypeError("argument str must be a string");const n={},i=(t||{}).decode||QW;let s=0;for(;s<e.length;){const c=e.indexOf("=",s);if(c===-1)break;let a=e.indexOf(";",s);if(a===-1)a=e.length;else if(a<c){s=e.lastIndexOf(";",c-1)+1;continue}const m=e.slice(s,c).trim();if(n[m]===void 0){let g=e.slice(c+1,a).trim();g.codePointAt(0)===34&&(g=g.slice(1,-1)),n[m]=KW(g,i)}s=a+1}return n}function HI(e,t,n){const r=n||{},i=r.encode||JW;if(typeof i!="function")throw new TypeError("option encode is invalid");if(!J0.test(e))throw new TypeError("argument name is invalid");const s=i(t);if(s&&!J0.test(s))throw new TypeError("argument val is invalid");let c=e+"="+s;if(r.maxAge!==void 0&&r.maxAge!==null){const a=r.maxAge-0;if(Number.isNaN(a)||!Number.isFinite(a))throw new TypeError("option maxAge is invalid");c+="; Max-Age="+Math.floor(a)}if(r.domain){if(!J0.test(r.domain))throw new TypeError("option domain is invalid");c+="; Domain="+r.domain}if(r.path){if(!J0.test(r.path))throw new TypeError("option path is invali
1d");c+="; Path="+r.path}if(r.expires){if(!XW(r.expires)||Number.isNaN(r.expires.valueOf()))throw new TypeError("option expires is invalid");c+="; Expires="+r.expires.toUTCString()}if(r.httpOnly&&(c+="; HttpOnly"),r.secure&&(c+="; Secure"),r.priority)switch(typeof r.priority=="string"?r.priority.toLowerCase():r.priority){case"low":c+="; Priority=Low";break;case"medium":c+="; Priority=Medium";break;case"high":c+="; Priority=High";break;default:throw new TypeError("option priority is invalid")}if(r.sameSite)switch(typeof r.sameSite=="string"?r.sameSite.toLowerCase():r.sameSite){case!0:c+="; SameSite=Strict";break;case"lax":c+="; SameSite=Lax";break;case"strict":c+="; SameSite=Strict";break;case"none":c+="; SameSite=None";break;default:throw new TypeError("option sameSite is invalid")}return c}function XW(e){return Object.prototype.toString.call(e)==="[object Date]"||e instanceof Date}function KW(e,t){try{return t(e)}catch{return e}}function QW(e){return e.includes("%")?decodeURIComponent(e):e}function JW(e){return encodeURIComponent(e)}function gT(e){return e!==null&&typeof e=="object"}function eS(e,t,n=".",r){if(!gT(t))return eS(e,{},n,r);const i=Object.assign({},t);for(const s in e){if(s==="__proto__"||s==="constructor")continue;const c=e[s];c!=null&&(r&&r(i,s,c,n)||(Array.isArray(c)&&Array.isArray(i[s])?i[s]=[...c,...i[s]]:gT(c)&&gT(i[s])?i[s]=eS(c,i[s],(n?`${n}.`:"")+s.toString(),r):i[s]=c))}return i}function eH(e){return(...t)=>t.reduce((n,r)=>eS(n,r,"",e),{})}const tH=eH();class tS extends Error{constructor(){super(...arguments),this.statusCode=500,this.fatal=!1,this.unhandled=!1}toJSON(){const t={message:this.message,statusCode:rS(this.statusCode,500)};return this.statusMessage&&(t.statusMessage=oB(this.statusMessage)),this.data!==void 0&&(t.data=this.data),t}}tS.__h3_error__=!0;function nS(e){if(typeof e=="string")return new tS(e);if(nH(e))return e;const t=new tS(e.message??e.statusMessage??"",e.cause?{cause:e.cause}:void 0);if("stack"in e)try{Object.defineProperty(t,"stack",{get(){return e.stack}})}catch{try{t.stack=e.stack}catch{}}if(e.data&&(t.data=e.data),e.statusCode?t.statusCode=rS(e.statusCode,t.statusCode):e.status&&(t.statusCode=rS(e.status,t.statusCode)),e.statusMessage?t.statusMessage=e.statusMessage:e.statusText&&(t.statusMessage=e.statusText),t.statusMessage){const n=t.statusMessage;oB(t.statusMessage)!==n&&console.warn("[h3] Please prefer using `message` for longer error messages instead of `statusMessage`. In the future, `statusMessage` will be sanitized by default.")}return e.fatal!==void 0&&(t.fatal=e.fatal),e.unhandled!==void 0&&(t.unhandled=e.unhandled),t}function nH(e){var t;return((t=e==null?void 0:e.constructor)==null?void 0:t.__h3_error__)===!0}const rH=/[^\u0009\u0020-\u007E]/g;function oB(e=""){return e.replace(rH,"")}function rS(e,t=200){return!e||(typeof e=="string"&&(e=Number.parseInt(e,10)),e<100||e>999)?t:e}const iH="$s";function oH(...e){const t=typeof e[e.length-1]=="string"?e.pop():void 0;typeof e[0]!="string"&&e.unshift(t);const[n,r]=e;if(!n||typeof n!="string")throw new TypeError("[nuxt] [useState] key must be a string: "+n);if(r!==void 0&&typeof r!="function")throw new Error("[nuxt] [useState] init must be a function: "+r);const i=iH+n,s=qo(),c=Us(s.payload.state,i);if(c.value===void 0&&r){const a=r();if(Ai(a))return s.payload.state[i]=a,a;c.value=a}return c}const aB=Symbol("layout-meta"),Cv=Symbol("route"),Sg=()=>{var e;return(e=qo())==null?void 0:e.$router},sB=()=>gk()?dr(Cv,qo()._route):qo()._route;/*! @__NO_SIDE_EFFECTS__ */const aH=()=>{try{if(qo()._processingMiddleware)return!0}catch{return!0}return!1},x_e=(e,t)=>{e||(e="/");const n=typeof e=="string"?e:G3(e.path||"/",e.query||{})+(e.hash||"");if(t!=null&&t.open){{const{target:a="_blank",windowFeatures:m={}}=t.open,g=Object.entries(m).filter(([x,T])=>T!==void 0).map(([x,T])=>`${x.toLowerCase()}=${T}`).join(", ");open(n,a,g)}return Promise.resolve()}const r=(t==null?void 0:t.external)||Qx(n,{acceptRelative:!0});if(r&&!(t!=null&&t.external))throw new Error("Navigating to external URL is not allowed by default. Use `navigateTo (url, { external: true })`.");if(r&&wk(n).protocol==="script:")throw new Error("Cannot navigate to an URL with script protocol.");const i=aH();if(!r&&i)return e;const s=Sg(),c=qo();return r?(t!=null&&t.replace?location.replace(n):location.href=n,i?c.isHydrating?new Promise(()=>{}
vendor: 4,198 bytes, lines 1-5
1):!1:Promise.resolve()):t!=null&&t.replace?s.replace(e):s.push(e)},e1=()=>Us(qo().payload,"error"),km=e=>{const t=t1(e);try{const n=qo(),r=e1();n.hooks.callHook("app:error",t),r.value=r.value||t}catch{throw t}return t},lB=async(e={})=>{const t=qo(),n=e1();t.callHook("app:error:cleared",e),e.redirect&&await Sg().replace(e.redirect),n.value=null},sH=e=>!!(e&&typeof e=="object"&&"__nuxt_error"in e),t1=e=>{const t=nS(e);return t.__nuxt_error=!0,t},YI={NuxtError:e=>t1(e),EmptyShallowRef:e=>ua(e==="_"?void 0:e==="0n"?BigInt(0):JSON.parse(e)),EmptyRef:e=>jt(e==="_"?void 0:e==="0n"?BigInt(0):JSON.parse(e)),ShallowRef:e=>ua(e),ShallowReactive:e=>vv(e),Ref:e=>jt(e),Reactive:e=>so(e)},lH=Gi({name:"nuxt:revive-payload:client",order:-30,async setup(e){let t,n;for(const r in YI)YW(r,YI[r]);Object.assign(e.payload,([t,n]=ex(()=>e.runWithContext(HW)),t=await t,n(),t)),window.__NUXT__=e.payload}});/*!
2  * vue-router v4.2.5
3  * (c) 2023 Eduardo San Martin Morote
4  * @license MIT
5  */const wm=typeof window<"u";function cH(e){return e.__esModule||e[Symbol.toStringTag]==="Module"}const Si=Object.assign;function yT(e,t){const n={};for(const r in t){const i=t[r];n[r]=Mc(i)?i.map(e):e(i)}return n}const m_=()=>{},Mc=Array.isArray,uH=/\/$/,hH=e=>e.replace(uH,"");function _T(e,t,n="/"){let r,i={},s="",c="";const a=t.indexOf("#");let m=t.indexOf("?");return a<m&&a>=0&&(m=-1),m>-1&&(r=t.slice(0,m),s=t.slice(m+1,a>-1?a:t.length),i=e(s)),a>-1&&(r=r||t.slice(0,a),c=t.slice(a,t.length)),r=mH(r??t,n),{fullPath:r+(s&&"?")+s+c,path:r,query:i,hash:c}}function dH(e,t){const n=t.query?e(t.query):"";return t.path+(n&&"?")+n+(t.hash||"")}function ZI(e,t){return!t||!e.toLowerCase().startsWith(t.toLowerCase())?e:e.slice(t.length)||"/"}function fH(e,t,n){const r=t.matched.length-1,i=n.matched.length-1;return r>-1&&r===i&&Qm(t.matched[r],n.matched[i])&&cB(t.params,n.params)&&e(t.query)===e(n.query)&&t.hash===n.hash}function Qm(e,t){return(e.aliasOf||e)===(t.aliasOf||t)}function cB(e,t){if(Object.keys(e).length!==Object.keys(t).length)return!1;for(const n in e)if(!pH(e[n],t[n]))return!1;return!0}function pH(e,t){return Mc(e)?XI(e,t):Mc(t)?XI(t,e):e===t}function XI(e,t){return Mc(t)?e.length===t.length&&e.every((n,r)=>n===t[r]):e.length===1&&e[0]===t}function mH(e,t){if(e.startsWith("/"))return e;if(!e)return t;const n=t.split("/"),r=e.split("/"),i=r[r.length-1];(i===".."||i===".")&&r.push("");let s=n.length-1,c,a;for(c=0;c<r.length;c++)if(a=r[c],a!==".")if(a==="..")s>1&&s--;else break;return n.slice(0,s).join("/")+"/"+r.slice(c-(c===r.length?1:0)).join("/")}var z_;(function(e){e.pop="pop",e.push="push"})(z_||(z_={}));var g_;(function(e){e.back="back",e.forward="forward",e.unknown=""})(g_||(g_={}));function gH(e){if(!e)if(wm){const t=document.querySelector("base");e=t&&t.getAttribute("href")||"/",e=e.replace(/^\w+:\/\/[^\/]+/,"")}else e="/";return e[0]!=="/"&&e[0]!=="#"&&(e="/"+e),hH(e)}const yH=/^[^#]+#/;function _H(e,t){return e.replace(yH,"#")+t}function vH(e,t){const n=document.documentElement.getBoundingClientRect(),r=e.getBoundingClientRect();return{behavior:t.behavior,left:r.left-n.left-(t.left||0),top:r.top-n.top-(t.top||0)}}const n1=()=>({left:window.pageXOffset,top:window.pageYOffset});function bH(e){let t;if("el"in e){const n=e.el,r=typeof n=="string"&&n.startsWith("#"),i=typeof n=="string"?r?document.getElementById(n.slice(1)):document.querySelector(n):n;if(!i)return;t=vH(i,e)}else t=e;"scrollBehavior"in document.documentElement.style?window.scrollTo(t):window.scrollTo(t.left!=null?t.left:window.pageXOffset,t.top!=null?t.top:window.pageYOffset)}function KI(e,t){return(history.state?history.state.position-t:-1)+e}const iS=new Map;function xH(e,t){iS.set(e,t)}function wH(e){const t=iS.get(e);return iS.delete(e),t}let TH=()=>location.protocol+"//"+location.host;function uB(e,t){const{pathname:n,search:r,hash:i}=t,s=e.indexOf("#");if(s>-1){let a=i.includes(e.slice(s))?e.slice(s).length:1,m=i.slice(a);return m[0]!=="/"&&(m="/"+m),ZI(m,"")}return ZI(n,e)+r+i}function EH(e,t,n,r){let i=[],s=[],c=null;const a=({state:C})=>{const A=uB(e,location),P=n.value,D=t.value;let B=0;if(C){if(n.value=A,t.value=C,c&&c===P){c=null;return}B=D?C.position-D.position:0}else r(A);
vendor: 4,170 bytes, line 5
5i.forEach(R=>{R(n.value,P,{delta:B,type:z_.pop,direction:B?B>0?g_.forward:g_.back:g_.unknown})})};function m(){c=n.value}function g(C){i.push(C);const A=()=>{const P=i.indexOf(C);P>-1&&i.splice(P,1)};return s.push(A),A}function x(){const{history:C}=window;C.state&&C.replaceState(Si({},C.state,{scroll:n1()}),"")}function T(){for(const C of s)C();s=[],window.removeEventListener("popstate",a),window.removeEventListener("beforeunload",x)}return window.addEventListener("popstate",a),window.addEventListener("beforeunload",x,{passive:!0}),{pauseListeners:m,listen:g,destroy:T}}function QI(e,t,n,r=!1,i=!1){return{back:e,current:t,forward:n,replaced:r,position:window.history.length,scroll:i?n1():null}}function SH(e){const{history:t,location:n}=window,r={value:uB(e,n)},i={value:t.state};i.value||s(r.value,{back:null,current:r.value,forward:null,position:t.length-1,replaced:!0,scroll:null},!0);function s(m,g,x){const T=e.indexOf("#"),C=T>-1?(n.host&&document.querySelector("base")?e:e.slice(T))+m:TH()+e+m;try{t[x?"replaceState":"pushState"](g,"",C),i.value=g}catch(A){console.error(A),n[x?"replace":"assign"](C)}}function c(m,g){const x=Si({},t.state,QI(i.value.back,m,i.value.forward,!0),g,{position:i.value.position});s(m,x,!0),r.value=m}function a(m,g){const x=Si({},i.value,t.state,{forward:m,scroll:n1()});s(x.current,x,!0);const T=Si({},QI(r.value,m,null),{position:x.position+1},g);s(m,T,!1),r.value=m}return{location:r,state:i,push:a,replace:c}}function hB(e){e=gH(e);const t=SH(e),n=EH(e,t.state,t.location,t.replace);function r(s,c=!0){c||n.pauseListeners(),history.go(s)}const i=Si({location:"",base:e,go:r,createHref:_H.bind(null,e)},t,n);return Object.defineProperty(i,"location",{enumerable:!0,get:()=>t.location.value}),Object.defineProperty(i,"state",{enumerable:!0,get:()=>t.state.value}),i}function CH(e){return e=location.host?e||location.pathname+location.search:"",e.includes("#")||(e+="#"),hB(e)}function kH(e){return typeof e=="string"||e&&typeof e=="object"}function dB(e){return typeof e=="string"||typeof e=="symbol"}const tu={path:"/",name:void 0,params:{},query:{},hash:"",fullPath:"/",matched:[],meta:{},redirectedFrom:void 0},fB=Symbol("");var JI;(function(e){e[e.aborted=4]="aborted",e[e.cancelled=8]="cancelled",e[e.duplicated=16]="duplicated"})(JI||(JI={}));function Jm(e,t){return Si(new Error,{type:e,[fB]:!0},t)}function Gu(e,t){return e instanceof Error&&fB in e&&(t==null||!!(e.type&t))}const eO="[^/]+?",AH={sensitive:!1,strict:!1,start:!0,end:!0},PH=/[.+*?^${}()[\]/\\]/g;function MH(e,t){const n=Si({},AH,t),r=[];let i=n.start?"^":"";const s=[];for(const g of e){const x=g.length?[]:[90];n.strict&&!g.length&&(i+="/");for(let T=0;T<g.length;T++){const C=g[T];let A=40+(n.sensitive?.25:0);if(C.type===0)T||(i+="/"),i+=C.value.replace(PH,"\\$&"),A+=40;else if(C.type===1){const{value:P,repeatable:D,optional:B,regexp:R}=C;s.push({name:P,repeatable:D,optional:B});const N=R||eO;if(N!==eO){A+=10;try{new RegExp(`(${N})`)}catch(U){throw new Error(`Invalid custom RegExp for param "${P}" (${N}): `+U.message)}}let j=D?`((?:${N})(?:/(?:${N}))*)`:`(${N})`;T||(j=B&&g.length<2?`(?:/${j})`:"/"+j),B&&(j+="?"),i+=j,A+=20,B&&(A+=-8),D&&(A+=-20),N===".*"&&(A+=-50)}x.push(A)}r.push(x)}if(n.strict&&n.end){const g=r.length-1;r[g][r[g].length-1]+=.7000000000000001}n.strict||(i+="/?"),n.end?i+="$":n.strict&&(i+="(?:/|$)");const c=new RegExp(i,n.sensitive?"":"i");function a(g){const x=g.match(c),T={};if(!x)return null;for(let C=1;C<x.length;C++){const A=x[C]||"",P=s[C-1];T[P.name]=A&&P.repeatable?A.split("/"):A}return T}function m(g){let x="",T=!1;for(const C of e){(!T||!x.endsWith("/"))&&(x+="/"),T=!1;for(const A of C)if(A.type===0)x+=A.value;else if(A.type===1){const{value:P,repeatable:D,optional:B}=A,R=P in g?g[P]:"";if(Mc(R)&&!D)throw new Error(`Provided param "${P}" is an array but it is not repeatable (* or + modifiers)`);const N=Mc(R)?R.join("/"):R;if(!N)if(B)C.length<2&&(x.endsWith("/")?x=x.slice(0,-1):T=!0);else throw new Error(`Missing required param "${P}"`);x+=N}}return x||"/"}return{re:c,score:r,keys:s,parse:a,stringify:m}}function IH(e,t){let n=0;for(;n<e.length&&n<t.length;){const r=t[n]-e[n];if(r)return r;n++}
vendor: 11,851 bytes, line 5
5return e.length<t.length?e.length===1&&e[0]===40+40?-1:1:e.length>t.length?t.length===1&&t[0]===40+40?1:-1:0}function OH(e,t){let n=0;const r=e.score,i=t.score;for(;n<r.length&&n<i.length;){const s=IH(r[n],i[n]);if(s)return s;n++}if(Math.abs(i.length-r.length)===1){if(tO(r))return 1;if(tO(i))return-1}return i.length-r.length}function tO(e){const t=e[e.length-1];return e.length>0&&t[t.length-1]<0}const DH={type:0,value:""},LH=/[a-zA-Z0-9_]/;function RH(e){if(!e)return[[]];if(e==="/")return[[DH]];if(!e.startsWith("/"))throw new Error(`Invalid path "${e}"`);function t(A){throw new Error(`ERR (${n})/"${g}": ${A}`)}let n=0,r=n;const i=[];let s;function c(){s&&i.push(s),s=[]}let a=0,m,g="",x="";function T(){g&&(n===0?s.push({type:0,value:g}):n===1||n===2||n===3?(s.length>1&&(m==="*"||m==="+")&&t(`A repeatable param (${g}) must be alone in its segment. eg: '/:ids+.`),s.push({type:1,value:g,regexp:x,repeatable:m==="*"||m==="+",optional:m==="*"||m==="?"})):t("Invalid state to consume buffer"),g="")}function C(){g+=m}for(;a<e.length;){if(m=e[a++],m==="\\"&&n!==2){r=n,n=4;continue}switch(n){case 0:m==="/"?(g&&T(),c()):m===":"?(T(),n=1):C();break;case 4:C(),n=r;break;case 1:m==="("?n=2:LH.test(m)?C():(T(),n=0,m!=="*"&&m!=="?"&&m!=="+"&&a--);break;case 2:m===")"?x[x.length-1]=="\\"?x=x.slice(0,-1)+m:n=3:x+=m;break;case 3:T(),n=0,m!=="*"&&m!=="?"&&m!=="+"&&a--,x="";break;default:t("Unknown state");break}}return n===2&&t(`Unfinished custom RegExp for param "${g}"`),T(),c(),i}function FH(e,t,n){const r=MH(RH(e.path),n),i=Si(r,{record:e,parent:t,children:[],alias:[]});return t&&!i.record.aliasOf==!t.record.aliasOf&&t.children.push(i),i}function BH(e,t){const n=[],r=new Map;t=iO({strict:!1,end:!0,sensitive:!1},t);function i(x){return r.get(x)}function s(x,T,C){const A=!C,P=zH(x);P.aliasOf=C&&C.record;const D=iO(t,x),B=[P];if("alias"in x){const j=typeof x.alias=="string"?[x.alias]:x.alias;for(const U of j)B.push(Si({},P,{components:C?C.record.components:P.components,path:U,aliasOf:C?C.record:P}))}let R,N;for(const j of B){const{path:U}=j;if(T&&U[0]!=="/"){const W=T.record.path,Q=W[W.length-1]==="/"?"":"/";j.path=T.record.path+(U&&Q+U)}if(R=FH(j,T,D),C?C.alias.push(R):(N=N||R,N!==R&&N.alias.push(R),A&&x.name&&!rO(R)&&c(x.name)),P.children){const W=P.children;for(let Q=0;Q<W.length;Q++)s(W[Q],R,C&&C.children[Q])}C=C||R,(R.record.components&&Object.keys(R.record.components).length||R.record.name||R.record.redirect)&&m(R)}return N?()=>{c(N)}:m_}function c(x){if(dB(x)){const T=r.get(x);T&&(r.delete(x),n.splice(n.indexOf(T),1),T.children.forEach(c),T.alias.forEach(c))}else{const T=n.indexOf(x);T>-1&&(n.splice(T,1),x.record.name&&r.delete(x.record.name),x.children.forEach(c),x.alias.forEach(c))}}function a(){return n}function m(x){let T=0;for(;T<n.length&&OH(x,n[T])>=0&&(x.record.path!==n[T].record.path||!pB(x,n[T]));)T++;n.splice(T,0,x),x.record.name&&!rO(x)&&r.set(x.record.name,x)}function g(x,T){let C,A={},P,D;if("name"in x&&x.name){if(C=r.get(x.name),!C)throw Jm(1,{location:x});D=C.record.name,A=Si(nO(T.params,C.keys.filter(N=>!N.optional).map(N=>N.name)),x.params&&nO(x.params,C.keys.map(N=>N.name))),P=C.stringify(A)}else if("path"in x)P=x.path,C=n.find(N=>N.re.test(P)),C&&(A=C.parse(P),D=C.record.name);else{if(C=T.name?r.get(T.name):n.find(N=>N.re.test(T.path)),!C)throw Jm(1,{location:x,currentLocation:T});D=C.record.name,A=Si({},T.params,x.params),P=C.stringify(A)}const B=[];let R=C;for(;R;)B.unshift(R.record),R=R.parent;return{name:D,path:P,params:A,matched:B,meta:$H(B)}}return e.forEach(x=>s(x)),{addRoute:s,resolve:g,removeRoute:c,getRoutes:a,getRecordMatcher:i}}function nO(e,t){const n={};for(const r of t)r in e&&(n[r]=e[r]);return n}function zH(e){return{path:e.path,redirect:e.redirect,name:e.name,meta:e.meta||{},aliasOf:void 0,beforeEnter:e.beforeEnter,props:NH(e),children:e.children||[],instances:{},leaveGuards:new Set,updateGuards:new Set,enterCallbacks:{},components:"components"in e?e.components||null:e.component&&{default:e.component}}}function NH(e){const t={},n=e.props||!1;if("component"in e)t.default=n;else for(const r in e.components)t[r]=typeof n=="object"?n[r]:n;return t}function rO(e){for(;e;){if(e.record.aliasOf)return!0;e=e.parent}return!1}function $H(e){return e.reduce((t,n)=>Si(t,n.meta),{})}function iO(e,t){const n={};for(const r in e)n[r]=r in t?t[r]:e[r];return n}function pB(e,t){return t.children.some(n=>n===e||pB(e,n))}const mB=/#/g,jH=/&/g,UH=/\//g,VH=/=/g,GH=/\?/g,gB=/\+/g,qH=/%5B/g,WH=/%5D/g,yB=/%5E/g,HH=/%60/g,_B=/%7B/g,YH=/%7C/g,vB=/%7D/g,ZH=/%20/g;function Ek(e){return encodeURI(""+e).replace(YH,"|").replace(qH,"[").replace(WH,"]")}function XH(e){return Ek(e).replace(_B,"{").replace(vB,"}").replace(yB,"^")}function oS(e){return Ek(e).replace(gB,"%2B").replace(ZH,"+").replace(mB,"%23").replace(jH,"%26").replace(HH,"`").replace(_B,"{").replace(vB,"}").replace(yB,"^")}function KH(e){return oS(e).replace(VH,"%3D")}function QH(e){return Ek(e).replace(mB,"%23").replace(GH,"%3F")}function JH(e){return e==null?"":QH(e).replace(UH,"%2F")}function rx(e){try{return decodeURIComponent(""+e)}catch{}return""+e}function e7(e){const t={};if(e===""||e==="?")return t;const r=(e[0]==="?"?e.slice(1):e).split("&");for(let i=0;i<r.length;++i){const s=r[i].replace(gB," "),c=s.indexOf("="),a=rx(c<0?s:s.slice(0,c)),m=c<0?null:rx(s.slice(c+1));if(a in t){let g=t[a];Mc(g)||(g=t[a]=[g]),g.push(m)}else t[a]=m}return t}function oO(e){let t="";for(let n in e){const r=e[n];if(n=KH(n),r==null){r!==void 0&&(t+=(t.length?"&":"")+n);continue}(Mc(r)?r.map(s=>s&&oS(s)):[r&&oS(r)]).forEach(s=>{s!==void 0&&(t+=(t.length?"&":"")+n,s!=null&&(t+="="+s))})}return t}function t7(e){const t={};for(const n in e){const r=e[n];r!==void 0&&(t[n]=Mc(r)?r.map(i=>i==null?null:""+i):r==null?r:""+r)}return t}const n7=Symbol(""),aO=Symbol(""),Sk=Symbol(""),Ck=Symbol(""),aS=Symbol("");function By(){let e=[];function t(r){return e.push(r),()=>{const i=e.indexOf(r);i>-1&&e.splice(i,1)}}function n(){e=[]}return{add:t,list:()=>e.slice(),reset:n}}function Kh(e,t,n,r,i){const s=r&&(r.enterCallbacks[i]=r.enterCallbacks[i]||[]);return()=>new Promise((c,a)=>{const m=T=>{T===!1?a(Jm(4,{from:n,to:t})):T instanceof Error?a(T):kH(T)?a(Jm(2,{from:t,to:T})):(s&&r.enterCallbacks[i]===s&&typeof T=="function"&&s.push(T),c())},g=e.call(r&&r.instances[i],t,n,m);let x=Promise.resolve(g);e.length<3&&(x=x.then(m)),x.catch(T=>a(T))})}function vT(e,t,n,r){const i=[];for(const s of e)for(const c in s.components){let a=s.components[c];if(!(t!=="beforeRouteEnter"&&!s.instances[c]))if(r7(a)){const g=(a.__vccOpts||a)[t];g&&i.push(Kh(g,n,r,s,c))}else{let m=a();i.push(()=>m.then(g=>{if(!g)return Promise.reject(new Error(`Couldn't resolve component "${c}" at "${s.path}"`));const x=cH(g)?g.default:g;s.components[c]=x;const C=(x.__vccOpts||x)[t];return C&&Kh(C,n,r,s,c)()}))}}return i}function r7(e){return typeof e=="object"||"displayName"in e||"props"in e||"__vccOpts"in e}function sO(e){const t=dr(Sk),n=dr(Ck),r=yt(()=>t.resolve(bt(e.to))),i=yt(()=>{const{matched:m}=r.value,{length:g}=m,x=m[g-1],T=n.matched;if(!x||!T.length)return-1;const C=T.findIndex(Qm.bind(null,x));if(C>-1)return C;const A=lO(m[g-2]);return g>1&&lO(x)===A&&T[T.length-1].path!==A?T.findIndex(Qm.bind(null,m[g-2])):C}),s=yt(()=>i.value>-1&&s7(n.params,r.value.params)),c=yt(()=>i.value>-1&&i.value===n.matched.length-1&&cB(n.params,r.value.params));function a(m={}){return a7(m)?t[bt(e.replace)?"replace":"push"](bt(e.to)).catch(m_):Promise.resolve()}return{route:r,href:yt(()=>r.value.href),isActive:s,isExactActive:c,navigate:a}}const i7=sr({name:"RouterLink",compatConfig:{MODE:3},props:{to:{type:[String,Object],required:!0},replace:Boolean,activeClass:String,exactActiveClass:String,custom:Boolean,ariaCurrentValue:{type:String,default:"page"}},useLink:sO,setup(e,{slots:t}){const n=so(sO(e)),{options:r}=dr(Sk),i=yt(()=>({[cO(e.activeClass,r.linkActiveClass,"router-link-active")]:n.isActive,[cO(e.exactActiveClass,r.linkExactActiveClass,"router-link-exact-active")]:n.isExactActive}));return()=>{const s=t.default&&t.default(n);return e.custom?s:ao("a",{"aria-current":n.isExactActive?e.ariaCurrentValue:null,href:n.href,onClick:n.navigate,class:i.value},s)}}}),o7=i7;function a7(e){if(!(e.metaKey||e.altKey||e.ctrlKey||e.shiftKey)&&!e.defaultPrevented&&!(e.button!==void 0&&e.button!==0)){if(e.currentTarget&&e.currentTarget.getAttribute){const t=e.currentTarget.getAttribute("target");if(/\b_blank\b/i.test(t))return}return e.preventDefault&&e.preventDefault(),!0}}function s7(e,t){for(const n in t){const r=t[n],i=e[n];if(typeof r=="string"){if(r!==i)return!1}else if(!Mc(i)||i.length!==r.length||r.some((s,c)=>s!==i[c]))return!1}return!0}function lO(e){return e?e.aliasOf?e.aliasOf.path:e.path:""}const cO=(e,t,n)=>e??t??n,l7=sr({name:"RouterView",inheritAttrs:!1,props:{name:{type:String,default:"default"},route:Object},compatConfig:{MODE:3},setup(e,{attrs:t,slots:n}){const r=dr(aS),i=yt(()=>e.route||r.value),s=dr(aO,0),c=yt(()=>{let g=bt(s);const{matched:x}=i.value;let T;for(;(T=x[g])&&!T.components;)g++;return g}),a=yt(()=>i.value.matched[c.value]);ea(aO,yt(()=>c.value+1)),ea(n7,a),ea(aS,i);const m=jt();return Nn(()=>[m.value,a.value,e.name],([g,x,T],[C,A,P])=>{x&&(x.instances[T]=g,A&&A!==x&&g&&g===C&&(x.leaveGuards.size||(x.leaveGuards=A.leaveGuards),x.updateGuards.size||(x.updateGuards=A.updateGuards))),g&&x&&(!A||!Qm(x,A)||!C)&&(x.enterCallbacks[T]||[]).forEach(D=>D(g))},{flush:"post"}),()=>{const g=i.value,x=e.name,T=a.value,C=T&&T.components[x];if(!C)return uO(n.default,{Component:C,route:g});const A=T.props[x],P=A?A===!0?g.params:typeof A=="function"?A(g):A:null,B=ao(C,Si({},P,t,{onVnodeUnmounted:R=>{R.component.isUnmounted&&(T.instances[x]=null)},ref:m}));return uO(n.default,{Component:B,route:g})||B}}});function uO(e,t){if(!e)return null;const n=e(t);return n.length===1?n[0]:n}const bB=l7;function c7(e){const t=BH(e.routes,e),n=e.parseQuery||e7,r=e.stringifyQuery||oO,i=e.history,s=By(),c=By(),a=By(),m=ua(tu);let g=tu;wm&&e.scrollBehavior&&"scrollRestoration"in history&&(history.scrollRestoration="manual");const x=yT.bind(null,je=>""+je),T=yT.bind(null,JH),C=yT.bind(null,rx);function A(je,st){let tt,Me;return dB(je)?(tt=t.getRecordMatcher(je),Me=st):Me=je,t.addRoute(Me,tt)}function P(je){const st=t.getRecordMatcher(je);st&&t.removeRoute(st)}function D(){return t.getRoutes().map(je=>je.record)}function B(je){return!!t.getRecordMatcher(je)}function R(je,st){if(st=Si({},st||m.value),typeof je=="string"){const Je=_T(n,je,st.path),ct=t.resolve({path:Je.path},st),mt=i.createHref(Je.fullPath);return Si(Je,ct,{params:C(ct.params),hash:rx(Je.hash),redirectedFrom:void 0,href:mt})}let tt;if("path"in je)tt=Si({},je,{path:_T(n,je.path,st.path).path});else{const Je=Si({},je.params);for(const ct in Je)Je[ct]==null&&delete Je[ct];tt=Si({},je,{params:T(Je)}),st.params=T(st.params)}const Me=t.resolve(tt,st),lt=je.hash||"";Me.params=x(C(Me.params));const Ae=dH(r,Si({},je,{hash:XH(lt),path:Me.path})),we=i.createHref(Ae);return Si({fullPath:Ae,hash:lt,query:r===oO?t7(je.query):je.query||{}},Me,{redirectedFrom:void 0,href:we})}function N(je){return typeof je=="string"?_T(n,je,m.value.path):Si({},je)}function j(je,st){if(g!==je)return Jm(8,{from:st,to:je})}function U(je){return Z(je)}function W(je){return U(Si(N(je),{replace:!0}))}function Q(je){const st=je.matched[je.matched.length-1];if(st&&st.redirect){const{redirect:tt}=st;let Me=typeof tt=="function"?tt(je):tt;return typeof Me=="string"&&(Me=Me.includes("?")||Me.includes("#")?Me=N(Me):{path:Me},Me.params={}),Si({query:je.query,hash:je.hash,params:"path"in Me?{}:je.params},Me)}}function Z(je,st){const tt=g=R(je),Me=m.value,lt=je.state,Ae=je.force,we=je.replace===!0,Je=Q(tt);if(Je)return Z(Si(N(Je),{state:typeof Je=="object"?Si({},lt,Je.state):lt,force:Ae,replace:we}),st||tt);const ct=tt;ct.redirectedFrom=st;let mt;
vendor: 5,032 bytes, line 5
5return!Ae&&fH(r,Me,tt)&&(mt=Jm(16,{to:ct,from:Me}),Ne(Me,Me,!0,!1)),(mt?Promise.resolve(mt):me(ct,Me)).catch(Vt=>Gu(Vt)?Gu(Vt,2)?Vt:se(Vt):ne(Vt,ct,Me)).then(Vt=>{if(Vt){if(Gu(Vt,2))return Z(Si({replace:we},N(Vt.to),{state:typeof Vt.to=="object"?Si({},lt,Vt.to.state):lt,force:Ae}),st||ct)}else Vt=ce(ct,Me,!0,we,lt);return ge(ct,Me,Vt),Vt})}function K(je,st){const tt=j(je,st);return tt?Promise.reject(tt):Promise.resolve()}function Y(je){const st=kt.values().next().value;return st&&typeof st.runWithContext=="function"?st.runWithContext(je):je()}function me(je,st){let tt;const[Me,lt,Ae]=u7(je,st);tt=vT(Me.reverse(),"beforeRouteLeave",je,st);for(const Je of Me)Je.leaveGuards.forEach(ct=>{tt.push(Kh(ct,je,st))});const we=K.bind(null,je,st);return tt.push(we),Ue(tt).then(()=>{tt=[];for(const Je of s.list())tt.push(Kh(Je,je,st));return tt.push(we),Ue(tt)}).then(()=>{tt=vT(lt,"beforeRouteUpdate",je,st);for(const Je of lt)Je.updateGuards.forEach(ct=>{tt.push(Kh(ct,je,st))});return tt.push(we),Ue(tt)}).then(()=>{tt=[];for(const Je of Ae)if(Je.beforeEnter)if(Mc(Je.beforeEnter))for(const ct of Je.beforeEnter)tt.push(Kh(ct,je,st));else tt.push(Kh(Je.beforeEnter,je,st));return tt.push(we),Ue(tt)}).then(()=>(je.matched.forEach(Je=>Je.enterCallbacks={}),tt=vT(Ae,"beforeRouteEnter",je,st),tt.push(we),Ue(tt))).then(()=>{tt=[];for(const Je of c.list())tt.push(Kh(Je,je,st));return tt.push(we),Ue(tt)}).catch(Je=>Gu(Je,8)?Je:Promise.reject(Je))}function ge(je,st,tt){a.list().forEach(Me=>Y(()=>Me(je,st,tt)))}function ce(je,st,tt,Me,lt){const Ae=j(je,st);if(Ae)return Ae;const we=st===tu,Je=wm?history.state:{};tt&&(Me||we?i.replace(je.fullPath,Si({scroll:we&&Je&&Je.scroll},lt)):i.push(je.fullPath,lt)),m.value=je,Ne(je,st,tt,we),se()}let fe;function ie(){fe||(fe=i.listen((je,st,tt)=>{if(!wt.listening)return;const Me=R(je),lt=Q(Me);if(lt){Z(Si(lt,{replace:!0}),Me).catch(m_);return}g=Me;const Ae=m.value;wm&&xH(KI(Ae.fullPath,tt.delta),n1()),me(Me,Ae).catch(we=>Gu(we,12)?we:Gu(we,2)?(Z(we.to,Me).then(Je=>{Gu(Je,20)&&!tt.delta&&tt.type===z_.pop&&i.go(-1,!1)}).catch(m_),Promise.reject()):(tt.delta&&i.go(-tt.delta,!1),ne(we,Me,Ae))).then(we=>{we=we||ce(Me,Ae,!1),we&&(tt.delta&&!Gu(we,8)?i.go(-tt.delta,!1):tt.type===z_.pop&&Gu(we,20)&&i.go(-1,!1)),ge(Me,Ae,we)}).catch(m_)}))}let xe=By(),Te=By(),oe;function ne(je,st,tt){se(je);const Me=Te.list();return Me.length?Me.forEach(lt=>lt(je,st,tt)):console.error(je),Promise.reject(je)}function le(){return oe&&m.value!==tu?Promise.resolve():new Promise((je,st)=>{xe.add([je,st])})}function se(je){return oe||(oe=!je,ie(),xe.list().forEach(([st,tt])=>je?tt(je):st()),xe.reset()),je}function Ne(je,st,tt,Me){const{scrollBehavior:lt}=e;if(!wm||!lt)return Promise.resolve();const Ae=!tt&&wH(KI(je.fullPath,0))||(Me||!tt)&&history.state&&history.state.scroll||null;return Qi().then(()=>lt(je,st,Ae)).then(we=>we&&bH(we)).catch(we=>ne(we,je,st))}const Se=je=>i.go(je);let xt;const kt=new Set,wt={currentRoute:m,listening:!0,addRoute:A,removeRoute:P,hasRoute:B,getRoutes:D,resolve:R,options:e,push:U,replace:W,go:Se,back:()=>Se(-1),forward:()=>Se(1),beforeEach:s.add,beforeResolve:c.add,afterEach:a.add,onError:Te.add,isReady:le,install(je){const st=this;je.component("RouterLink",o7),je.component("RouterView",bB),je.config.globalProperties.$router=st,Object.defineProperty(je.config.globalProperties,"$route",{enumerable:!0,get:()=>bt(m)}),wm&&!xt&&m.value===tu&&(xt=!0,U(i.location).catch(lt=>{}));const tt={};for(const lt in tu)Object.defineProperty(tt,lt,{get:()=>m.value[lt],enumerable:!0});je.provide(Sk,st),je.provide(Ck,vv(tt)),je.provide(aS,m);const Me=je.unmount;kt.add(je),je.unmount=function(){kt.delete(je),kt.size<1&&(g=tu,fe&&fe(),fe=null,m.value=tu,xt=!1,oe=!1),Me()}}};function Ue(je){return je.reduce((st,tt)=>st.then(()=>Y(tt)),Promise.resolve())}return wt}function u7(e,t){const n=[],r=[],i=[],s=Math.max(t.matched.length,e.matched.length);for(let c=0;c<s;c++){const a=t.matched[c];a&&(e.matched.find(g=>Qm(g,a))?r.push(a):n.push(a));const m=e.matched[c];m&&(t.matched.find(g=>Qm(g,m))||i.push(m))}return[n,r,i]}function h7(){return dr(Ck)}const hO=[{path:"/:customerId()",children:[{name:"customerId",path:"",meta:{},alias:[],redirect:void 0,component:()=>Sn(()=>import("./index.c8fbe05f.js"),["./index.c8fbe05f.js","./BText.98e0af33.js","./BText.4187dff4.css","./index.9ad46bd7.js","./group.2cdc14d0.js","./group.9bfde38d.css","./index.bdf729ea.css","./BDivider.79eea1a5.js","./BDivider.2a23fb06.css","./VBtn.b870324c.js","./VDefaultsProvider.9c2bb8ee.js","./VBtn.3c529c85.css","./brik-mix.924f0a7e.js","./VDialog.6be3fb98.js","./forwardRefs.e2994a01.js","./dialog-transition.33e3c46d.js","./VDialog.f0a29abf.css","./VCard.0bff31d4.js","./createSimpleFunctional.24e8d9e4.js","./VAvatar.5e7c6354.js","./VImg.a63e6fbd.js","./index.c048e374.js","./VImg.9014554e.css","./VAvatar.b72a6b57.css","./VCard.911f41ce.css","./index.f7e8e619.css"],import.meta.url).then(e=>e.default||e)},{name:"customerId-pin",path:"pin",meta:{},alias:[],redirect:void 0,component:()=>Sn(()=>
5import("./index.e09feb62.js"),["./index.e09feb62.js","./group.2cdc14d0.js","./group.9bfde38d.css","./brik-mix.924f0a7e.js","./VBtn.b870324c.js","./VDefaultsProvider.9c2bb8ee.js","./VBtn.3c529c85.css","./index.59e5f567.css"],import.meta.url).then(e=>e.default||e)},{path:"projects/:projectId()",children:[{name:"customerId-projects-projectId-documents",path:"documents",meta:{},alias:[],redirect:void 0,component:()=>Sn(()=>import("./index.b07dea5e.js"),["./index.b07dea5e.js","./BUpload.f6de8766.js","./BUpload.83d678af.css","./VCheckbox.8c812257.js","./VCheckboxBtn.d80509f1.js","./VSelectionControl.7102513c.js","./VDefaultsProvider.9c2bb8ee.js","./group.2cdc14d0.js","./group.9bfde38d.css","./VSelectionControl.74f78248.css","./VInput.3a16f114.js","./form.02b88035.js","./VInput.f7db6f99.css","./VCheckbox.1ea139e1.css","./VBtn.b870324c.js","./VBtn.3c529c85.css","./index.410d817d.css"],import.meta.url).then(e=>e.default||e)},{name:"customerId-projects-projectId",path:"",meta:{},alias:[],redirect:void 0,component:()=>Sn(()=>import("./index.87d4985b.js"),["./index.87d4985b.js","./ProjectDisplay.52f009f1.js","./BText.98e0af33.js","./BText.4187dff4.css","./ProjectDisplay.fea4fa79.css","./index.9d5e269a.js","./VBtn.b870324c.js","./group.2cdc14d0.js","./group.9bfde38d.css","./VDefaultsProvider.9c2bb8ee.js","./VBtn.3c529c85.css","./index.85b1b03b.css","./Navigation.11a4ff71.js","./layout.8ec5c668.js","./ssrBoot.74019366.js","./VTabs.e0427fe1.js","./VTabs.3926bdaa.css","./Navigation.56fcc89d.css","./BStatus.350f3e5a.js","./VChip.ffd4e37e.js","./VAvatar.5e7c6354.js","./VImg.a63e6fbd.js","./index.c048e374.js","./VImg.9014554e.css","./VAvatar.b72a6b57.css","./VChip.cc3fec85.css","./index.9ad46bd7.js","./index.bdf729ea.css","./BDivider.79eea1a5.js","./BDivider.2a23fb06.css","./index.0b78284b.css"],import.meta.url).then(e=>e.default||e)},{name:"customerId-projects-projectId-invoices-invoiceId",path:"invoices/:invoiceId()",meta:{},alias:[],redirect:void 0,component:()=>Sn(()=>import("./index.d5d96bd7.js"),["./index.d5d96bd7.js","./ProjectDisplay.52f009f1.js","./BText.98e0af33.js","./BText.4187dff4.css","./ProjectDisplay.fea4fa79.css","./index.9d5e269a.js","./VBtn.b870324c.js","./group.2cdc14d0.js","./group.9bfde38d.css","./VDefaultsProvider.9c2bb8ee.js","./VBtn.3c529c85.css","./index.85b1b03b.css","./BStatus.350f3e5a.js","./VChip.ffd4e37e.js","./VAvatar.5e7c6354.js","./VImg.a63e6fbd.js","./index.c048e374.js","./VImg.9014554e.css","./VAvatar.b72a6b57.css","./VChip.cc3fec85.css","./index.0773f023.css"],import.meta.url).then(e=>e.default||e)},{name:"customerId-projects-projectId-invoices",path:"invoices",meta:{},alias:[],redirect:void 0,component:()=>Sn(()=>import("./index.4cb44ef4.js"),["./index.4cb44ef4.js","./BStatus.350f3e5a.js","./VChip.ffd4e37e.js","./group.2cdc14d0.js","./group.9bfde38d.css","./VDefaultsProvider.9c2bb8ee.js","./VAvatar.5e7c6354.js","./VImg.a63e6fbd.js","./index.c048e374.js","./VImg.9014554e.css","./VAvatar.b72a6b57.css","./VChip.cc3fec85.css","./BText.98e0af33.js","./BText.4187dff4.css","./index.9ad46bd7.js","./index.bdf729ea.css","./ProjectDisplay.52f009f1.js","./ProjectDisplay.fea4fa79.css","./index.9d5e269a.js","./VBtn.b870324c.js","./VBtn.3c529c85.css","./index.85b1b03b.css","./Navigation.11a4ff71.js","./layout.8ec5c668.js","./ssrBoot.74019366.js","./VTabs.e0427fe1.js","./VTabs.3926bdaa.css","./Navigation.56fcc89d.css","./index.f81cb4a1.css"],import.meta.url).then(e=>e.default||e)},{name:"customerId-projects-projectId-invoices-invoices",path:"invoices/invoices",meta:{},alias:[],redirect:void 0,component:()=>Sn(()=>import("./invoices.8153cae4.js"),["./invoices.8153cae4.js","./BPreloader.807da747.js","./BPreloader.ccba4d69.css"],import.meta.url).then(e=>e.default||e)},{path:"orders/:orderId()",children:[{name:"customerId-projects-projectId-orders-orderId",path:"",meta:{},alias:[],redirect:void 0,component:()=>Sn(()=>import("./index.869e6fac.js"),["./index.869e6fac.js","./BText.98e0af33.js","./BText.4187dff4.css","./BUpload.f6de8766.js","./BUpload.83d678af.css","./BDivider.79eea1a5.js","./BDivider.2a23fb06.css","./index.482ed8f8.js","./VForm.3a5805e1.js","./form.02b88035.js","./forwardRefs.e2994a01.js","./VBtn.b870324c.js","./group.2cdc14d0.js","./group.9bfde38d.css","./VDefaultsProvider.9c2bb8ee.js","./VBtn.3c529c85.css","./VDialog.6be3fb98.js","./dialog-transition.33e3c46d.js","./VDialog.f0a29abf.css","./VImg.a63e6fbd.js","./index.c048e374.js","./VImg.9014554e.css","./constants.a7ac9ca4.js","./VDivider.7864b1a5.js","./VDivider.fc38186d.css","./index.0f990383.js","./index.d32f5485.
5css","./index.48db917e.js","./BStatus.350f3e5a.js","./VChip.ffd4e37e.js","./VAvatar.5e7c6354.js","./VAvatar.b72a6b57.css","./VChip.cc3fec85.css","./index.9ad46bd7.js","./index.bdf729ea.css","./VCheckbox.8c812257.js","./VCheckboxBtn.d80509f1.js","./VSelectionControl.7102513c.js","./VSelectionControl.74f78248.css","./VInput.3a16f114.js","./VInput.f7db6f99.css","./VCheckbox.1ea139e1.css","./VTabs.e0427fe1.js","./VTabs.3926bdaa.css","./ssrBoot.74019366.js","./index.0bee0482.css","./ProjectDisplay.52f009f1.js","./ProjectDisplay.fea4fa79.css","./index.9d5e269a.js","./index.85b1b03b.css","./BNego.d864b983.js","./BNego.26b2432a.css","./BPreloader.807da747.js","./BPreloader.ccba4d69.css","./VTextField.ce1053f7.js","./VTextField.d6b7c0ed.css","./index.8ffb591a.css"],import.meta.url).then(e=>e.default||e)}],name:void 0,meta:{},alias:[],redirect:void 0,component:()=>Sn(()=>import("./_orderId_.860f9101.js"),["./_orderId_.860f9101.js","./components.ce428f69.js","./BPreloader.807da747.js","./BPreloader.ccba4d69.css"],import.meta.url).then(e=>e.default||e)},{name:"customerId-projects-projectId-orders",path:"orders",meta:{},alias:[],redirect:void 0,component:()=>Sn(()=>import("./index.382ffe6a.js"),[],import.meta.url).then(e=>e.default||e)},{path:"orders/new",children:[{name:"customerId-projects-projectId-orders-new",path:"",meta:{},alias:[],redirect:void 0,component:()=>Sn(()=>import("./index.73d22e59.js"),["./index.73d22e59.js","./components.ce428f69.js","./index.482ed8f8.js","./VForm.3a5805e1.js","./form.02b88035.js","./forwardRefs.e2994a01.js","./VBtn.b870324c.js","./group.2cdc14d0.js","./group.9bfde38d.css","./VDefaultsProvider.9c2bb8ee.js","./VBtn.3c529c85.css","./VDialog.6be3fb98.js","./dialog-transition.33e3c46d.js","./VDialog.f0a29abf.css","./VImg.a63e6fbd.js","./index.c048e374.js","./VImg.9014554e.css","./constants.a7ac9ca4.js","./VDivider.7864b1a5.js","./VDivider.fc38186d.css","./index.0f990383.js","./index.d32f5485.css","./BNego.d864b983.js","./index.9ad46bd7.js","./index.bdf729ea.css","./BNego.26b2432a.css","./ProjectDisplay.52f009f1.js","./BText.98e0af33.js","./BText.4187dff4.css","./ProjectDisplay.fea4fa79.css","./index.9d5e269a.js","./index.85b1b03b.css","./BPreloader.807da747.js","./BPreloader.ccba4d69.css","./VSwitch.2b52fa93.js","./VInput.3a16f114.js","./VInput.f7db6f99.css","./VSelectionControl.7102513c.js","./VSelectionControl.74f78248.css","./VSwitch.c4b0ddac.css","./index.74c0886d.css"],import.meta.url).then(e=>e.default||e)},{path:"products",children:[{name:"customerId-projects-projectId-orders-new-products-productInternalId",path:":productInternalId()",meta:{},alias:[],redirect:void 0,component:()=>Sn(()=>import("./index.0618e4e7.js"),["./index.0618e4e7.js","./BText.98e0af33.js","./BText.4187dff4.css","./ProjectDisplay.52f009f1.js","./ProjectDisplay.fea4fa79.css","./index.9d5e269a.js","./VBtn.b870324c.js","./group.2cdc14d0.js","./group.9bfde38d.css","./VDefaultsProvider.9c2bb8ee.js","./VBtn.3c529c85.css","./index.85b1b03b.css","./VSelect.6df4bf46.js","./VTextField.ce1053f7.js","./VInput.3a16f114.js","./form.02b88035.js","./VInput.f7db6f99.css","./forwardRefs.e2994a01.js","./index.c048e374.js","./VTextField.d6b7c0ed.css","./VMenu.2a1bf36a.js","./VListItem.0f228b79.js","./createSimpleFunctional.24e8d9e4.js","./VAvatar.5e7c6354.js","./VImg.a63e6fbd.js","./VImg.9014554e.css","./VAvatar.b72a6b57.css","./VListItem.360a1571.css","./ssrBoot.74019366.js","./VDivider.7864b1a5.js","./VDivider.fc38186d.css","./dialog-transition.33e3c46d.js","./VMenu.c85f5330.css","./VCheckboxBtn.d80509f1.js","./VSelectionControl.7102513c.js","./VSelectionControl.74f78248.css","./VChip.ffd4e37e.js","./VChip.cc3fec85.css","./VSelect.91a61802.css","./index.5ed690e0.css"],import.meta.url).then(e=>e.default||e)},{name:"customerId-projects-projectId-orders-new-products",path:"",meta:{},alias:[],redirect:void 0,component:()=>Sn(()=>import("./index.61438f64.js"),["./index.61438f64.js","./index.482ed8f8.js","./VForm.3a5805e1.js","./form.02b88035.js","./forwardRefs.e2994a01.js","./VBtn.b870324c.js","./group.2cdc14d0.js","./group.9bfde38d.css","./VDefaultsProvider.9c2bb8ee.js","./VBtn.3c529c85.css","./VDialog.6be3fb98.js","./dialog-transition.33e3c46d.js","./VDialog.f0a29abf.css","./VImg.a63e6fbd.js","./index.c048e374.js","./VImg.9014554e.css","./constants.a7ac9ca4.js","./VDivider.7864b1a5.js","./VDivider.fc38186d.css","./index.0f990383.js","./index.d32f5485.
5css","./ProjectDisplay.52f009f1.js","./BText.98e0af33.js","./BText.4187dff4.css","./ProjectDisplay.fea4fa79.css","./index.9d5e269a.js","./index.85b1b03b.css","./index.c2caf649.css"],import.meta.url).then(e=>e.default||e)}],name:void 0,meta:{},alias:[],redirect:void 0,component:()=>Sn(()=>import("./products.2022dcc2.js"),["./products.2022dcc2.js","./components.ce428f69.js","./BPreloader.807da747.js","./BPreloader.ccba4d69.css"],import.meta.url).then(e=>e.default||e)}],name:void 0,meta:{},alias:[],redirect:void 0,component:()=>Sn(()=>import("./new.b64abe64.js"),[],import.meta.url).then(e=>e.default||e)},{name:"customerId-projects-projectId-payments-paymentId",path:"payments/:paymentId()",meta:{},alias:[],redirect:void 0,component:()=>Sn(()=>import("./index.0fa2dc4e.js"),["./index.0fa2dc4e.js","./ProjectDisplay.52f009f1.js","./BText.98e0af33.js","./BText.4187dff4.css","./ProjectDisplay.fea4fa79.css","./index.9d5e269a.js","./VBtn.b870324c.js","./group.2cdc14d0.js","./group.9bfde38d.css","./VDefaultsProvider.9c2bb8ee.js","./VBtn.3c529c85.css","./index.85b1b03b.css","./BStatus.350f3e5a.js","./VChip.ffd4e37e.js","./VAvatar.5e7c6354.js","./VImg.a63e6fbd.js","./index.c048e374.js","./VImg.9014554e.css","./VAvatar.b72a6b57.css","./VChip.cc3fec85.css","./index.0a077ced.css"],import.meta.url).then(e=>e.default||e)},{name:"customerId-projects-projectId-payments",path:"payments",meta:{},alias:[],redirect:void 0,component:()=>Sn(()=>import("./index.53f9d948.js"),["./index.53f9d948.js","./ProjectDisplay.52f009f1.js","./BText.98e0af33.js","./BText.4187dff4.css","./ProjectDisplay.fea4fa79.css","./index.9d5e269a.js","./VBtn.b870324c.js","./group.2cdc14d0.js","./group.9bfde38d.css","./VDefaultsProvider.9c2bb8ee.js","./VBtn.3c529c85.css","./index.85b1b03b.css","./Navigation.11a4ff71.js","./layout.8ec5c668.js","./ssrBoot.74019366.js","./VTabs.e0427fe1.js","./VTabs.3926bdaa.css","./Navigation.56fcc89d.css","./index.358e35e5.css"],import.meta.url).then(e=>e.default||e)},{name:"customerId-projects-projectId-payments-payments",path:"payments/payments",meta:{},alias:[],redirect:void 0,component:()=>Sn(()=>import("./payments.860c18b2.js"),["./payments.860c18b2.js","./BPreloader.807da747.js","./BPreloader.ccba4d69.css"],import.meta.url).then(e=>e.default||e)},{path:"schedules",children:[{path:":scheduleId()",children:[{path:"do/:doId()",children:[{name:"customerId-projects-projectId-schedules-scheduleId-do-doId",path:"",meta:{},alias:[],redirect:void 0,component:()=>Sn(()=>import("./index.7048288c.js"),["./index.7048288c.js","./VSpacer.3ca9b258.js","./group.2cdc14d0.js","./group.9bfde38d.css","./VImg.a63e6fbd.js","./index.c048e374.js","./VImg.9014554e.css","./VDefaultsProvider.9c2bb8ee.js","./createSimpleFunctional.24e8d9e4.js","./VSpacer.28018df2.css","./VBtn.b870324c.js","./VBtn.3c529c85.css","./index.84e5a497.css"],import.meta.url).then(e=>e.default||e)}],name:void 0,meta:{},alias:[],redirect:void 0,component:()=>Sn(()=>import("./_doId_.7ec5c6a4.js"),["./_doId_.7ec5c6a4.js","./components.ce428f69.js","./BPreloader.807da747.js","./BPreloader.ccba4d69.css"],import.meta.url).then(e=>e.default||e)},{name:"customerId-projects-projectId-schedules-scheduleId",path:"",meta:{},alias:[],redirect:void 0,component:()=>Sn(()=>import("./index.3fa1606f.js"),["./index.3fa1606f.js","./BText.98e0af33.js","./BText.4187dff4.css","./index.9ad46bd7.js","./group.2cdc14d0.js","./group.9bfde38d.css","./index.bdf729ea.css","./BDivider.79eea1a5.js","./BDivider.2a23fb06.css","./BStatus.350f3e5a.js","./VChip.ffd4e37e.js","./VDefaultsProvider.9c2bb8ee.js","./VAvatar.5e7c6354.js","./VImg.a63e6fbd.js","./index.c048e374.js","./VImg.9014554e.css","./VAvatar.b72a6b57.css","./VChip.cc3fec85.css","./VCard.0bff31d4.js","./createSimpleFunctional.24e8d9e4.js","./VBtn.b870324c.js","./VBtn.3c529c85.css","./VCard.911f41ce.css","./VSpacer.3ca9b258.js","./VSpacer.28018df2.css","./VDialog.6be3fb98.js","./forwardRefs.e2994a01.js","./dialog-transition.33e3c46d.js","./VDialog.f0a29abf.css","./ProjectDisplay.52f009f1.js","./ProjectDisplay.fea4fa79.css","./index.9d5e269a.js","./index.85b1b03b.css","./index.7b8aa918.css"],import.meta.url).then(e=>e.default||e)},{name:"customerId-projects-projectId-schedules-scheduleId-pay",path:"pay",meta:{},alias:[],redirect:void 0,component:()=>Sn(()=>import("./pay.735e7552.js"),["./pay.735e7552.js","./VSpacer.3ca9b258.js","./group.2cdc14d0.js","./group.9bfde38d.css","./VImg.a63e6fbd.js","./index.c048e374.js","./VImg.9014554e.css","./VDefaultsProvider.9c2bb8ee.js","./createSimpleFunctional.24e8d9e4.js","./VSpacer.28018df2.css","./VBtn.b870324c.js","./VBtn.3c529c85.css","./pay.38b21d07.css"],import.meta.url).then(e=>e.default||e)}],name:void 0,meta:{},alias:[],redirect:void 0,component:()=>Sn(()=>import("./_scheduleId_.80e1f34c.js"),["./_scheduleId_.80e1f34c.js","./components.ce428f69.js","./BPreloader.807da747.js","./BPreloader.ccba4d69.css"],import.meta.url).then(e=>e.default||e)},{name:"customerId-projects-projectId-schedules",path:"",meta:{},alias:[],redirect:void 0,component:()=>Sn(()=>import("./index.8078b3fc.js"),["./index.8078b3fc.js","./BText.98e0af33.js","./BText.4187dff4.css","./BDivider.79eea1a5.js","./BDivider.2a23fb06.css","./index.48db917e.js","./BStatus.350f3e5a.js","./VChip.ffd4e37e.js","./group.2cdc14d0.js","./group.9bfde38d.css","./VDefaultsProvider.9c2bb8ee.js","./VAvatar.5e7c6354.js","./VImg.a63e6fbd.js","./index.c048e374.js","./VImg.9014554e.css","./VAvatar.b72a6b57.css","./VChip.cc3fec85.css","./index.9ad46bd7.js","./index.bdf729ea.css","./VCheckbox.8c812257.js","./VCheckboxBtn.d80509f1.js","./VSelectionControl.7102513c.js","./VSelectionControl.74f78248.css","./VInput.3a16f114.js","./form.02b88035.js","./VInput.f7db6f99.css","./VCheckbox.1ea139e1.css","./VTabs.e0427fe1.js","./VBtn.b870324c.js","./VBtn.3c529c85.css","./VTabs.3926bdaa.css","./ssrBoot.74019366.js","./index.0bee0482.css","./ProjectDisplay.52f009f1.js","./ProjectDisplay.fea4fa79.css","./index.9d5e269a.js","./index.85b1b03b.css","./Navigation.11a4ff71.js","./layout.8ec5c668.js","./Navigation.56fcc89d.css","./VTooltip.d90ace6b.js","./forwardRefs.e2994a01.js","./VTooltip.8b532790.css","./index.83740a0e.css"],import.meta.url).then(e=>e.default||e)},{path:"new",children:[{name:"customerId-projects-projectId-schedules-new",path:"",meta:{},alias:[],redirect:void 0,component:()=>Sn(()=>import("./index.1b302a04.js"),["./index.1b302a04.js","./components.ce428f69.js","./ProjectDisplay.52f009f1.js","./BText.98e0af33.js","./BText.4187dff4.css","./ProjectDisplay.fea4fa79.css","./index.9d5e269a.js","./VBtn.b870324c.js","./group.2cdc14d0.js","./group.9bfde38d.css","./VDefaultsProvider.9c2bb8ee.js","./VBtn.3c529c85.css","./index.85b1b03b.css","./BDivider.79eea1a5.js","./BDivider.2a23fb06.css","./BPreloader.807da747.js","./BPreloader.ccba4d69.css","./VSelect.6df4bf46.js","./VTextField.ce1053f7.js","./VInput.3a16f114.js","./form.02b88035.js","./VInput.f7db6f99.css","./forwardRefs.e2994a01.js","./index.c048e374.js","./VTextField.d6b7c0ed.css","./VMenu.2a1bf36a.js","./VListItem.0f228b79.js","./createSimpleFunctional.24e8d9e4.js","./VAvatar.5e7c6354.js","./VImg.a63e6fbd.js","./VImg.9014554e.css","./VAvatar.b72a6b57.css","./VListItem.360a1571.css","./ssrBoot.74019366.js","./VDivider.7864b1a5.js","./VDivider.fc38186d.css","./dialog-transition.33e3c46d.js","./VMenu.c85f5330.css","./VCheckboxBtn.d80509f1.js","./VSelectionControl.7102513c.js","./VSelectionControl.74f78248.css","./VChip.ffd4e37e.js","./VChip.cc3fec85.css","./VSelect.91a61802.css","./VSwitch.2b52fa93.js","./VSwitch.c4b0ddac.css","./index.5c35238d.css"],import.meta.url).then(e=>e.default||e)},{path:"products",children:[{name:"customerId-projects-projectId-schedules-new-products-productName",path:":productName()",meta:{},alias:[],redirect:void 0,component:()=>Sn(()=>import("./index.2438c357.js"),["./index.2438c357.js","./BText.98e0af33.js","./BText.4187dff4.css","./ProjectDisplay.52f009f1.js","./ProjectDisplay.fea4fa79.css","./index.9d5e269a.js","./VBtn.b870324c.js","./group.2cdc14d0.js","./group.9bfde38d.css","./VDefaultsProvider.9c2bb8ee.js","./VBtn.3c529c85.css","./index.85b1b03b.css","./VSelect.6df4bf46.js","./VTextField.ce1053f7.js","./VInput.3a16f114.js","./form.02b88035.js","./VInput.f7db6f99.css","./forwardRefs.e2994a01.js","./index.c048e374.js","./VTextField.d6b7c0ed.css","./VMenu.2a1bf36a.js","./VListItem.0f228b79.js","./createSimpleFunctional.24e8d9e4.js","./VAvatar.5e7c6354.js","./VImg.a63e6fbd.js","./VImg.9014554e.css","./VAvatar.b72a6b57.css","./VListItem.360a1571.css","./ssrBoot.74019366.js","./VDivider.7864b1a5.js","./VDivider.fc38186d.css","./dialog-transition.33e3c46d.js","./VMenu.c85f5330.css","./VCheckboxBtn.d80509f1.js","./VSelectionControl.7102513c.js","./VSelectionControl.74f78248.css","./VChip.ffd4e37e.js","./VChip.cc3fec85.css","./VSelect.91a61802.css","./index.cc264b6f.css"],import.meta.url).then(e=>e.default||e)},{name:"customerId-projects-projectId-schedules-new-products",path:"",meta:{},alias:[],redirect:void 0,component:()=>Sn(()=>import("./index.2d3e8186.js"),["./index.2d3e8186.js","./index.482ed8f8.js","./VForm.3a5805e1.js","./form.02b88035.js","./forwardRefs.e2994a01.js","./VBtn.b870324c.js","./group.2cdc14d0.js","./group.9bfde38d.css","./VDefaultsProvider.9c2bb8ee.js","./VBtn.3c529c85.css","./VDialog.6be3fb98.js","./dialog-transition.33e3c46d.js","./VDialog.f0a29abf.css","./VImg.a63e6fbd.js","./index.c048e374.js","./VImg.9014554e.css","./constants.a7ac9ca4.js","./VDivider.7864b1a5.js","./VDivider.fc38186d.css","./index.0f990383.js","./index.d32f5485.
5css","./ProjectDisplay.52f009f1.js","./BText.98e0af33.js","./BText.4187dff4.css","./ProjectDisplay.fea4fa79.css","./index.9d5e269a.js","./index.85b1b03b.css","./VTextField.ce1053f7.js","./VInput.3a16f114.js","./VInput.f7db6f99.css","./VTextField.d6b7c0ed.css","./index.6cb9b117.css"],import.meta.url).then(e=>e.default||e)}],name:void 0,meta:{},alias:[],redirect:void 0,component:()=>Sn(()=>import("./products.ee273106.js"),["./products.ee273106.js","./components.ce428f69.js","./BPreloader.807da747.js","./BPreloader.ccba4d69.css"],import.meta.url).then(e=>e.default||e)}],name:void 0,meta:{},alias:[],redirect:void 0,component:()=>Sn(()=>import("./new.23a4f3c5.js"),["./new.23a4f3c5.js","./BPreloader.807da747.js","./BPreloader.ccba4d69.css"],import.meta.url).then(e=>e.default||e)}],name:void 0,meta:{},alias:[],redirect:void 0,component:()=>Sn(()=>import("./schedules.52de1685.js"),["./schedules.52de1685.js","./BPreloader.807da747.js","./BPreloader.ccba4d69.css"],import.meta.url).then(e=>e.default||e)},{name:"customerId-projects-projectId-transactions",path:"transactions",meta:{},alias:[],redirect:void 0,component:()=>Sn(()=>import("./index.59e2f00b.js"),["./index.59e2f00b.js","./ProjectDisplay.52f009f1.js","./BText.98e0af33.js","./BText.4187dff4.css","./ProjectDisplay.fea4fa79.css","./index.9d5e269a.js","./VBtn.b870324c.js","./group.2cdc14d0.js","./group.9bfde38d.css","./VDefaultsProvider.9c2bb8ee.js","./VBtn.3c529c85.css","./index.85b1b03b.css","./Navigation.11a4ff71.js","./layout.8ec5c668.js","./ssrBoot.74019366.js","./VTabs.e0427fe1.js","./VTabs.3926bdaa.css","./Navigation.56fcc89d.css","./nuxt-link.6243d81b.js","./BStatus.350f3e5a.js","./VChip.ffd4e37e.js","./VAvatar.5e7c6354.js","./VImg.a63e6fbd.js","./index.c048e374.js","./VImg.9014554e.css","./VAvatar.b72a6b57.css","./VChip.cc3fec85.css","./VDataTable.6e4cf55c.js","./VSelect.6df4bf46.js","./VTextField.ce1053f7.js","./VInput.3a16f114.js","./form.02b88035.js","./VInput.f7db6f99.css","./forwardRefs.e2994a01.js","./VTextField.d6b7c0ed.css","./VMenu.2a1bf36a.js","./VListItem.0f228b79.js","./createSimpleFunctional.24e8d9e4.js","./VListItem.360a1571.css","./VDivider.7864b1a5.js","./VDivider.fc38186d.css","./dialog-transition.33e3c46d.js","./VMenu.c85f5330.css","./VCheckboxBtn.d80509f1.js","./VSelectionControl.7102513c.js","./VSelectionControl.74f78248.css","./VSelect.91a61802.css","./filter.7941c130.js","./VDataTable.6aa94b58.css","./index.9350035c.css"],import.meta.url).then(e=>e.default||e)},{name:"customerId-projects-projectId-transactions-transactions",path:"transactions/transactions",meta:{},alias:[],redirect:void 0,component:()=>Sn(()=>import("./transactions.00e4d1f5.js"),["./transactions.00e4d1f5.js","./BPreloader.807da747.js","./BPreloader.ccba4d69.css"],import.meta.url).then(e=>e.default||e)}],name:void 0,meta:{},alias:[],redirect:void 0,component:()=>Sn(()=>import("./_projectId_.482830e3.js"),["./_projectId_.482830e3.js","./components.ce428f69.js","./BPreloader.807da747.js","./BPreloader.ccba4d69.css"],import.meta.url).then(e=>e.default||e)},{name:"customerId-projects-create",path:"projects/create",meta:{},alias:[],redirect:void 0,component:()=>Sn(()=>import("./index.77423613.js"),["./index.77423613.js","./index.9d5e269a.js","./VBtn.b870324c.js","./group.2cdc14d0.js","./group.9bfde38d.css","./VDefaultsProvider.9c2bb8ee.js","./VBtn.3c529c85.css","./index.85b1b03b.css","./client-only.f3ab23a1.js","./VDialog.6be3fb98.js","./forwardRefs.e2994a01.js","./dialog-transition.33e3c46d.js","./VDialog.f0a29abf.css","./VTextField.ce1053f7.js","./VInput.3a16f114.js","./form.02b88035.js","./VInput.f7db6f99.css","./index.c048e374.js","./VTextField.d6b7c0ed.css","./VSelect.6df4bf46.js","./VMenu.2a1bf36a.js","./VListItem.0f228b79.js","./createSimpleFunctional.24e8d9e4.js","./VAvatar.5e7c6354.js","./VImg.a63e6fbd.js","./VImg.9014554e.css","./VAvatar.b72a6b57.css","./VListItem.360a1571.css","./ssrBoot.74019366.js","./VDivider.7864b1a5.js","./VDivider.fc38186d.css","./VMenu.c85f5330.css","./VCheckboxBtn.d80509f1.js","./VSelectionControl.7102513c.js","./VSelectionControl.74f78248.css","./VChip.ffd4e37e.js","./VChip.cc3fec85.css","./VSelect.91a61802.css","./VCard.0bff31d4.js","./VCard.911f41ce.css","./VAutocomplete.1c08501a.js","./filter.7941c130.js","./VAutocomplete.53c69b1a.css","./VForm.3a5805e1.js","./VCheckbox.8c812257.js","./VCheckbox.1ea139e1.css","./index.6e46c5ec.css"],import.meta.url).then(e=>e.default||e)}],name:void 0,meta:{},alias:[],redirect:void 0,component:()=>Sn(()=>import("./_customerId_.a297cce1.js"),["./_customerId_.a297cce1.js","./components.ce428f69.js","./BPreloader.807da747.js","./BPreloader.ccba4d69.css","./BAutoLayout.f0d7a903.js"],import.meta.url).then(e=>e.default||e)},{name:"about-us",path:"/about-us",meta:{},alias:[],redirect:void 0,component:()=>Sn(()=>import("./index.f7a04e7c.js"),["./index.f7a04e7c.js","./index.eaf19382.js","./VImg.a63e6fbd.js","./index.c048e374.js","./VImg.9014554e.css","./constants.a7ac9ca4.js","./VBtn.b870324c.js","./group.2cdc14d0.js","./group.9bfde38d.css","./VDefaultsProvider.9c2bb8ee.js","./VBtn.3c529c85.css","./index.a86e5041.css","./client-only.f3ab23a1.js","./logo.129927ce.js","./index.e174789c.js","./nuxt-link.6243d81b.js","./index.5b7bc755.css","./index.fb72e8da.css"],import.meta.url).then(e=>e.default||e)},{path:"/articles",children:[{path:":slug()",children:[{name:"articles-slug-index.old",path:"index.old",meta:{},alias:[],redirect:void 0,component:()=>Sn(()=>import("./index.old.b59e6b9a.js"),["./index.old.b59e6b9a.js","./index.3d08f0f9.js","./VChip.ffd4e37e.js","./group.2cdc14d0.js","./group.9bfde38d.css","./VDefaultsProvider.9c2bb8ee.js","./VAvatar.5e7c6354.js","./VImg.a63e6fbd.js","./index.c048e374.js","./VImg.9014554e.css","./VAvatar.b72a6b57.css","./VChip.cc3fec85.css","./VContainer.1379175b.js","./VGrid.b7f52dfd.css","./index.e079a943.css","./index.old.46333bbf.css"],import.meta.url).then(e=>e.default||e)},{name:"articles-slug",path:"",meta:{},alias:[],redirect:void 0,component:()=>Sn(()=>import("./index.2e79b309.js"),["./index.2e79b309.js","./index.3d08f0f9.js","./VChip.ffd4e37e.js","./group.2cdc14d0.js","./group.9bfde38d.css","./VDefaultsProvider.9c2bb8ee.js","./VAvatar.5e7c6354.js","./VImg.a63e6fbd.js","./index.c048e374.js","./VImg.9014554e.css","./VAvatar.b72a6b57.css","./VChip.cc3fec85.css","./VContainer.1379175b.js","./VGrid.b7f52dfd.css","./index.e079a943.css","./index.0f990383.js","./index.12c60aca.css"],import.meta.url).then(e=>e.default||e)}],name:void 0,meta:{},alias:[],redirect:void 0,component:()=>Sn(()=>import("./_slug_.687df4aa.js"),["./_slug_.687df4aa.js","./index.ec638f34.js"],import.meta.url).then(e=>e.default||e)},{name:"articles-categories-categorySlug",path:"categories/:categorySlug()",meta:{},alias:[],redirect:void 0,component:()=>Sn(()=>import("./_categorySlug_.ca4525d5.js"),["./_categorySlug_.ca4525d5.js","./index.558fe6e2.js","./index.f4f25ca4.js","./VContainer.1379175b.js","./VGrid.b7f52dfd.css","./VChip.ffd4e37e.js","./group.2cdc14d0.js","./group.9bfde38d.css","./VDefaultsProvider.9c2bb8ee.js","./VAvatar.5e7c6354.js","./VImg.a63e6fbd.js","./index.c048e374.js","./VImg.9014554e.css","./VAvatar.b72a6b57.css","./VChip.cc3fec85.css","./index.0819af46.css","./index.ec638f34.js","./index.ae01c
554c.css"],import.meta.url).then(e=>e.default||e)},{name:"articles-index copy",path:"index%20copy",meta:{},alias:[],redirect:void 0,component:()=>Sn(()=>import("./index copy.c6ea1ef1.js"),["./index copy.c6ea1ef1.js","./index.f4f25ca4.js","./VContainer.1379175b.js","./VGrid.b7f52dfd.css","./VChip.ffd4e37e.js","./group.2cdc14d0.js","./group.9bfde38d.css","./VDefaultsProvider.9c2bb8ee.js","./VAvatar.5e7c6354.js","./VImg.a63e6fbd.js","./index.c048e374.js","./VImg.9014554e.css","./VAvatar.b72a6b57.css","./VChip.cc3fec85.css","./index.0819af46.css","./index copy.1656e330.css"],import.meta.url).then(e=>e.default||e)},{name:"articles",path:"",meta:{},alias:[],redirect:void 0,component:()=>Sn(()=>import("./index.558fe6e2.js"),["./index.558fe6e2.js","./index.f4f25ca4.js","./VContainer.1379175b.js","./VGrid.b7f52dfd.css","./VChip.ffd4e37e.js","./group.2cdc14d0.js","./group.9bfde38d.css","./VDefaultsProvider.9c2bb8ee.js","./VAvatar.5e7c6354.js","./VImg.a63e6fbd.js","./index.c048e374.js","./VImg.9014554e.css","./VAvatar.b72a6b57.css","./VChip.cc3fec85.css","./index.0819af46.css","./index.ec638f34.js","./index.ae01c
554c.css"],import.meta.url).then(e=>e.default||e)}],name:void 0,meta:{},alias:[],redirect:void 0,component:()=>Sn(()=>import("./articles.5c00849c.js"),["./articles.5c00849c.js","./articles.1dbb1542.css"],import.meta.url).then(e=>e.default||e)},{name:"calculator",path:"/calculator",meta:{},alias:[],redirect:void 0,component:()=>Sn(()=>import("./index.43313080.js"),["./index.43313080.js","./index.042b40e8.js","./VBtn.b870324c.js","./group.2cdc14d0.js","./group.9bfde38d.css","./VDefaultsProvider.9c2bb8ee.js","./VBtn.3c529c85.css","./index.faad844c.css","./VContainer.1379175b.js","./VGrid.b7f52dfd.css","./VMenu.2a1bf36a.js","./VListItem.0f228b79.js","./createSimpleFunctional.24e8d9e4.js","./VAvatar.5e7c6354.js","./VImg.a63e6fbd.js","./index.c048e374.js","./VImg.9014554e.css","./VAvatar.b72a6b57.css","./VListItem.360a1571.css","./ssrBoot.74019366.js","./VDivider.7864b1a5.js","./VDivider.fc38186d.css","./forwardRefs.e2994a01.js","./dialog-transition.33e3c46d.js","./VMenu.c85f5330.css","./VTextField.ce1053f7.js","./VInput.3a16f114.js","./form.02b88035.js","./VInput.f7db6f99.css","./VTextField.d6b7c0ed.css","./client-only.f3ab23a1.js","./index.e174789c.js","./nuxt-link.6243d81b.js","./index.5b7bc755.css","./index.f3947993.css"],import.meta.url).then(e=>e.default||e)},{name:"forgot-password",path:"/forgot-password",meta:{},alias:[],redirect:void 0,component:()=>Sn(()=>import("./index.f6d10c3c.js"),["./index.f6d10c3c.js","./brik-mix.924f0a7e.js","./VContainer.1379175b.js","./VGrid.b7f52dfd.css","./VTextField.ce1053f7.js","./VInput.3a16f114.js","./VDefaultsProvider.9c2bb8ee.js","./form.02b88035.js","./VInput.f7db6f99.css","./forwardRefs.e2994a01.js","./index.c048e374.js","./VTextField.d6b7c0ed.css","./VBtn.b870324c.js","./group.2cdc14d0.js","./group.9bfde38d.css","./VBtn.3c529c85.css","./index.742db90d.css"],import.meta.url).then(e=>e.default||e)},{name:"index",path:"/",meta:{},alias:[],redirect:void 0,component:()=>Sn(()=>import("./index.eb4540f0.js"),["./index.eb4540f0.js","./index.5d1fbfa7.js","./client-only.f3ab23a1.js","./VBtn.b870324c.js","./group.2cdc14d0.js","./group.9bfde38d.css","./VDefaultsProvider.9c2bb8ee.js","./VBtn.3c529c85.css","./index.6ea3d895.css","./index.eaf19382.js","./VImg.a63e6fbd.js","./index.c048e374.js","./VImg.9014554e.css","./constants.a7ac9ca4.js","./index.a86e5041.css","./index.1c4c70a7.js","./index.042b40e8.js","./index.faad844c.css","./VDataTable.6e4cf55c.js","./VSelect.6df4bf46.js","./VTextField.ce1053f7.js","./VInput.3a16f114.js","./form.02b88035.js","./VInput.f7db6f99.css","./forwardRefs.e2994a01.js","./VTextField.d6b7c0ed.css","./VMenu.2a1bf36a.js","./VListItem.0f228b79.js","./createSimpleFunctional.24e8d9e4.js","./VAvatar.5e7c6354.js","./VAvatar.b72a6b57.css","./VListItem.360a1571.css","./ssrBoot.74019366.js","./VDivider.7864b1a5.js","./VDivider.fc38186d.css","./dialog-transition.33e3c46d.js","./VMenu.c85f5330.css","./VCheckboxBtn.d80509f1.js","./VSelectionControl.7102513c.js","./VSelectionControl.74f78248.css","./VChip.ffd4e37e.js","./VChip.cc3fec85.css","./VSelect.91a61802.css","./filter.7941c130.js","./VDataTable.6aa94b58.css","./VAutocomplete.1c08501a.js","./VAutocomplete.53c69b1a.css","./index.0f990383.js","./index.0a1d6cba.css","./index.e174789c.js","./nuxt-link.6243d81b.js","./index.5b7bc755.css","./index.ec638f34.js","./index.2caba5f3.css"],import.meta.url).then(e=>e.default||e)},{name:"low-carbon-concrete",path:"/low-carbon-concrete",meta:{},alias:[],redirect:void 0,component:()=>Sn(()=>import("./index.e47826a1.js"),["./index.e47826a1.js","./index.1a81bcb4.js","./nuxt-link.6243d81b.js","./constants.a7ac9ca4.js","./index.0f990383.js","./logo.129927ce.js","./VBtn.b870324c.js","./group.2cdc14d0.js","./group.9bfde38d.css","./VDefaultsProvider.9c2bb8ee.js","./VBtn.3c529c85.css","./VImg.a63e6fbd.js","./index.c048e374.js","./VImg.9014554e.css","./layout.8ec5c668.js","./ssrBoot.74019366.js","./VRow.b0cbbd6b.js","./VGrid.b7f52dfd.css","./VListItem.0f228b79.js","./createSimpleFunctional.24e8d9e4.js","./VAvatar.5e7c6354.js","./VAvatar.b72a6b57.css","./VListItem.360a1571.css","./VCard.0bff31d4.js","./VCard.911f41ce.css","./index.07d2f18c.css","./client-only.f3ab23a1.js","./index.5d1fbfa7.js","./index.6ea3d895.css","./VDialog.6be3fb98.js","./forwardRefs.e2994a01.js","./dialog-transition.33e3c46d.js","./VDialog.f0a29abf.css","./index.e174789c.js","./index.5b7bc755.css","./index.a313aa99.css"],import.meta.url).then(e=>e.default||e)},{name:"not-found",path:"/not-found",meta:{},alias:[],redirect:void 0,component:()=>Sn(()=>import("./not-found.474ee90f.js"),[],import.meta.url).then(e=>e.default||e)},{path:"/product/:mainCategorySlug()",children:[{path:":categorySlug()",children:[{path:":subcategorySlug()",children:[{name:"product-mainCategorySlug-categorySlug-subcategorySlug-productSlug",path:":productSlug()",meta:{},alias:[],redirect:void 0,component:()=>Sn(()=>import("./index.48756212.js"),[],import.meta.url).then(e=>e.default||e)},{name:"product-mainCategorySlug-categorySlug-subcategorySlug",path:"",meta:{},alias:[],redirect:void 0,component:()=>Sn(()=>import("./index.4a104e96.js"),["./index.4a104e96.js","./index.3ff71a4e.js","./index.c2982d3e.
5js","./BText.98e0af33.js","./BText.4187dff4.css","./VImg.a63e6fbd.js","./index.c048e374.js","./VImg.9014554e.css","./Item.c676eea1.js","./VDefaultsProvider.9c2bb8ee.js","./Item.724cfb6c.css","./VContainer.1379175b.js","./VGrid.b7f52dfd.css","./VRow.b0cbbd6b.js","./index.ced8200f.css"],import.meta.url).then(e=>e.default||e)}],name:void 0,meta:{},alias:[],redirect:void 0,component:()=>Sn(()=>import("./_subcategorySlug_.e0fd277e.js"),["./_subcategorySlug_.e0fd277e.js","./BStrapiPreloader.f0d573fa.js","./BStrapiPreloader.768b2df7.css"],import.meta.url).then(e=>e.default||e)},{name:"product-mainCategorySlug-categorySlug",path:"",meta:{},alias:[],redirect:void 0,component:()=>Sn(()=>import("./index.3ff71a4e.js"),["./index.3ff71a4e.js","./index.c2982d3e.js","./BText.98e0af33.js","./BText.4187dff4.css","./VImg.a63e6fbd.js","./index.c048e374.js","./VImg.9014554e.css","./Item.c676eea1.js","./VDefaultsProvider.9c2bb8ee.js","./Item.724cfb6c.css","./VContainer.1379175b.js","./VGrid.b7f52dfd.css","./VRow.b0cbbd6b.js","./index.ced8200f.css"],import.meta.url).then(e=>e.default||e)}],name:void 0,meta:{},alias:[],redirect:void 0,component:()=>Sn(()=>import("./_categorySlug_.56a57e68.js"),["./_categorySlug_.56a57e68.js","./BStrapiPreloader.f0d573fa.js","./BStrapiPreloader.768b2df7.css"],import.meta.url).then(e=>e.default||e)},{name:"product-mainCategorySlug",path:"",meta:{},alias:[],redirect:void 0,component:()=>Sn(()=>import("./index.c2982d3e.js"),["./index.c2982d3e.js","./BText.98e0af33.js","./BText.4187dff4.css","./VImg.a63e6fbd.js","./index.c048e374.js","./VImg.9014554e.css","./Item.c676eea1.js","./VDefaultsProvider.9c2bb8ee.js","./Item.724cfb6c.css","./VContainer.1379175b.js","./VGrid.b7f52dfd.css","./VRow.b0cbbd6b.js","./index.ced8200f.css"],import.meta.url).then(e=>e.default||e)}],name:void 0,meta:{},alias:[],redirect:void 0,component:()=>Sn(()=>import("./_mainCategorySlug_.48b69f23.js"),["./_mainCategorySlug_.48b69f23.js","./BStrapiPreloader.f0d573fa.js","./BStrapiPreloader.768b2df7.css"],import.meta.url).then(e=>e.default||e)},{name:"product",path:"/product",meta:{},alias:[],redirect:void 0,component:()=>Sn(()=>import("./index.7db4eb5a.js"),["./index.7db4eb5a.js","./index.482ed8f8.js","./VForm.3a5805e1.js","./form.02b88035.js","./forwardRefs.e2994a01.js","./VBtn.b870324c.js","./group.2cdc14d0.js","./group.9bfde38d.css","./VDefaultsProvider.9c2bb8ee.js","./VBtn.3c529c85.css","./VDialog.6be3fb98.js","./dialog-transition.33e3c46d.js","./VDialog.f0a29abf.css","./VImg.a63e6fbd.js","./index.c048e374.js","./VImg.9014554e.css","./constants.a7ac9ca4.js","./VDivider.7864b1a5.js","./VDivider.fc38186d.css","./index.0f990383.js","./index.d32f5485.css","./client-only.f3ab23a1.js","./index.1c4c70a7.js","./index.042b40e8.js","./index.faad844c.css","./VDataTable.6e4cf55c.js","./VSelect.6df4bf46.js","./VTextField.ce1053f7.js","./VInput.3a16f114.js","./VInput.f7db6f99.css","./VTextField.d6b7c0ed.css","./VMenu.2a1bf36a.js","./VListItem.0f228b79.js","./createSimpleFunctional.24e8d9e4.js","./VAvatar.5e7c6354.js","./VAvatar.b72a6b57.css","./VListItem.360a1571.css","./ssrBoot.74019366.js","./VMenu.c85f5330.css","./VCheckboxBtn.d80509f1.js","./VSelectionControl.7102513c.js","./VSelectionControl.74f78248.css","./VChip.ffd4e37e.js","./VChip.cc3fec85.css","./VSelect.91a61802.css","./filter.7941c130.js","./VDataTable.6aa94b58.css","./VAutocomplete.1c08501a.js","./VAutocomplete.53c69b1a.css","./index.0a1d6cba.css","./index.e174789c.js","./nuxt-link.6243d81b.js","./index.5b7bc755.css"],import.meta.url).then(e=>e.default||e)},{name:"product-search-search",path:"/product/search/:search()",meta:{},alias:[],redirect:void 0,component:()=>Sn(()=>import("./_search_.41519e66.js"),["./_search_.41519e66.js","./BText.98e0af33.js","./BText.4187dff4.css","./Item.c676eea1.js","./VDefaultsProvider.9c2bb8ee.js","./VImg.a63e6fbd.js","./index.c048e374.js","./VImg.9014554e.css","./Item.724cfb6c.css","./VContainer.1379175b.js","./VGrid.b7f52dfd.css","./VRow.b0cbbd6b.js","./_search_.0694f44e.css"],import.meta.url).then(e=>e.default||e)},{name:"products",path:"/products",meta:{},alias:[],redirect:void 0,component:()=>Sn(()=>import("./products.89f111d3.js"),[],import.meta.url).then(e=>e.default||e)},{path:"/signin",children:[{name:"signin",path:"",meta:{},alias:[],redirect:void 0,component:()=>Sn(()=>import("./index.a3cfdb79.js"),["./index.a3cfdb79.js","./brik-mix.924f0a7e.js","./VContainer.1379175b.js","./VGrid.b7f52dfd.css","./VTextField.ce1053f7.js","./VInput.3a16f114.js","./VDefaultsProvider.9c2bb8ee.js","./form.02b88035.js","./VInput.f7db6f99.css","./forwardRefs.e2994a01.js","./index.c048e374.js","./VTextField.d6b7c0ed.css","./VBtn.b870324c.js","./group.2cdc14d0.js","./group.9bfde38d.css","./VBtn.3c529c85.css","./index.36db8116.css"],import.meta.url).then(e=>e.default||e)}],name:void 0,meta:{},alias:[],redirect:void 0,component:()=>Sn(()=>import("./signin.adf5d36e.js"),["./signin.adf5d36e.js","./BAutoLayout.f0d7a903.js"],import.meta.url).then(e=>e.default||e)},{path:"/signup",children:[{name:"signup",path:"",meta:{},alias:[],redirect:void 0,component:()=>Sn(()=>import("./index.cac38bfd.js"),["./index.cac38bfd.js","./BUpload.f6de8766.js","./BUpload.83d678af.css","./constants.a7ac9ca4.js","./VCard.0bff31d4.js","./createSimpleFunctional.24e8d9e4.js","./VDefaultsProvider.9c2bb8ee.js","./VAvatar.5e7c6354.js","./group.2cdc14d0.js","./group.9bfde38d.css","./VImg.a63e6fbd.js","./index.c048e374.js","./VImg.9014554e.css","./VAvatar.b72a6b57.css","./VBtn.b870324c.js","./VBtn.3c529c85.css","./VCard.911f41ce.css","./VDialog.6be3fb98.js","./forwardRefs.e2994a01.js","./dialog-transition.33e3c46d.js","./VDialog.f0a29abf.css","./brik-mix.924f0a7e.js","./VContainer.1379175b.js","./VGrid.b7f52dfd.css","./VTextField.ce1053f7.js","./VInput.3a16f114.js","./form.02b88035.js","./VInput.f7db6f99.css","./VTextField.d6b7c0ed.css","./VTooltip.d90ace6b.js","./VTooltip.8b532790.css","./VCheckbox.8c812257.js","./VCheckboxBtn.d80509f1.js","./VSelectionControl.7102513c.js","./VSelectionControl.74f78248.css","./VCheckbox.1ea139e1.css","./index.5d40f63d.css"],import.meta.url).then(e=>e.default||e)}],name:void 0,meta:{},alias:[],redirect:void 0,component:()=>Sn(()=>import("./signup.23a6e5b0.js"),["./signup.23a6e5b0.js","./BAutoLayout.f0d7a903.js"],import.meta.url).then(e=>e.default||e)},{name:"test",path:"/test",meta:{},alias:[],redirect:void 0,component:()=>Sn(()=>import("./index.f1b6645c.js"),[],import.meta.url).then(e=>e.default||e)}],d7={scrollBehavior(e,t,n){const r=qo();let i=n||void 0;if(!i&&t&&e&&e.meta.scrollToTop!==!1&&f7(t,e)&&(i={left:0,top:0}),e.path===t.path){if(t.hash&&!e.hash)return{left:0,top:0};if(e.hash)return{el:e.hash,top:dO(e.hash)}}const s=a=>!!(a.meta.pageTransition??JE),c=s(t)&&s(e)?"page:transition:finish":"page:finish";return new Promise(a=>{r.hooks.hookOnce(c,async()=>{await Qi(),e.hash&&(i={el:e.hash,top:dO(e.hash)}),a(i)})})}};function dO(e){try{const t=document.querySelector(e);
5if(t)return parseFloat(getComputedStyle(t).scrollMarginTop)}catch{}return 0}function f7(e,t){const n=t.matched.every((r,i)=>{var s,c,a;return((s=r.components)==null?void 0:s.default)===((a=(c=e.matched[i])==null?void 0:c.components)==null?void 0:a.default)});return!!(!n||n&&JSON.stringify(e.params)!==JSON.stringify(t.params))}const p7={},Is={...p7,...d7},m7=async e=>{var m;let t,n;if(!((m=e.meta)!=null&&m.validate))return;const r=qo(),i=Sg();if(([t,n]=ex(()=>Promise.resolve(e.meta.validate(e))),t=await t,n(),t)===!0)return;const c=t1({statusCode:404,statusMessage:`Page Not Found: ${e.fullPath}`}),a=i.beforeResolve(g=>{if(a(),g===e){const x=i.afterEach(async()=>{x(),await r.runWithContext(()=>km(c)),window.history.pushState({},"",e.fullPath)});return!1}})},g7=[m7],y_={};function y7(e,t,n){const{pathname:r,search:i,hash:s}=t,c=e.indexOf("#");if(c>-1){const g=s.includes(e.slice(c))?e.slice(c).length:1;let x=s.slice(g);return x[0]!=="/"&&(x="/"+x),FI(x,"")}const a=FI(r,e),m=!n||dq(a,n,{trailingSlash:!0})?a:n;return m+(m.includes("?")?"":i)+s}const _7=Gi({name:"nuxt:router",enforce:"pre",async setup(e){var D,B;let t,n,r=Eg().app.baseURL;Is.hashMode&&!r.includes("#")&&(r+="#");const i=((D=Is.history)==null?void 0:D.call(Is,r))??(Is.hashMode?CH(r):hB(r)),s=((B=Is.routes)==null?void 0:B.call(Is,hO))??hO;let c;const a=y7(r,window.location,e.payload.path),m=c7({...Is,scrollBehavior:(R,N,j)=>{var U;if(N===tu){c=j;return}return m.options.scrollBehavior=Is.scrollBehavior,(U=Is.scrollBehavior)==null?void 0:U.call(Is,R,tu,c||j)},history:i,routes:s});e.vueApp.use(m);const g=ua(m.currentRoute.value);m.afterEach((R,N)=>{g.value=N}),Object.defineProperty(e.vueApp.config.globalProperties,"previousRoute",{get:()=>g.value});const x=ua(m.resolve(a)),T=()=>{x.value=m.currentRoute.value};e.hook("page:finish",T),m.afterEach((R,N)=>{var j,U,W,Q;((U=(j=R.matched[0])==null?void 0:j.components)==null?void 0:U.default)===((Q=(W=N.matched[0])==null?void 0:W.components)==null?void 0:Q.default)&&T()});const C={};for(const R in x.value)Object.defineProperty(C,R,{get:()=>x.value[R]});e._route=vv(C),e._middleware=e._middleware||{global:[],named:{}};const A=e1();try{[t,n]=ex(()=>m.isReady()),await t,n()}catch(R){[t,n]=ex(()=>e.runWithContext(()=>km(R))),await t,n()}const P=oH("_layout");return m.beforeEach(async(R,N)=>{var j;R.meta=so(R.meta),e.isHydrating&&P.value&&!pp(R.meta.layout)&&(R.meta.layout=P.value),e._processingMiddleware=!0;{const U=new Set([...g7,...e._middleware.global]);for(const W of R.matched){const Q=W.meta.middleware;if(Q)if(Array.isArray(Q))for(const Z of Q)U.add(Z);else U.add(Q)}for(const W of U){const Q=typeof W=="string"?e._middleware.named[W]||await((j=y_[W])==null?void 0:j.call(y_).then(K=>K.default||K)):W;if(!Q)throw new Error(`Unknown route middleware: '${W}'.`);const Z=await e.runWithContext(()=>Q(R,N));if(!e.payload.serverRendered&&e.isHydrating&&(Z===!1||Z instanceof Error)){const K=Z||nS({statusCode:404,statusMessage:`Page Not Found: ${a}`});return await e.runWithContext(()=>km(K)),!1}if(Z||Z===!1)return Z}}}),m.onError(()=>{delete e._processingMiddleware}),m.afterEach(async(R,N,j)=>{delete e._processingMiddleware,!e.isHydrating&&A.value&&await e.runWithContext(lB),R.matched.length===0&&await e.runWithContext(()=>km(nS({statusCode:404,fatal:!1,statusMessage:`Page not found: ${R.fullPath}`})))}),e.hooks.hookOnce("app:created",async()=>{try{await m.replace({...m.resolve(a),name:void 0,force:!0}),m.options.scrollBehavior=Is.scrollBehavior}catch(R){await e.runWithContext(()=>km(R))}}),{provide:{router:m}}}}),v7=!1;/*!
6 * pinia v2.1.6
7 * (c) 2023 Eduardo San Martin Morote
8 * @license MIT
9 */let xB;const kv=e=>xB=e,wB=Symbol();function sS(e){return e&&typeof e=="object"&&Object.prototype.toString.call(e)==="[object Object]"&&typeof e.toJSON!="function"}var __;(function(e){e.direct="direct",e.patchObject="patch object",e.patchFunction="patch function"})(__||(__={}));function b7(){const e=xg(!0),t=e.run(()=>jt({}));let n=[],r=[];const i=xv({install(s){kv(i),i._a=s,s.provide(wB,i),s.config.globalProperties.$pinia=i,r.forEach(c=>n.push(c)),r=[]},use(s){return!this._a&&!v7?r.push(s):n.push(s),this},_p:n,_a:null,_e:e,_s:new Map,state:t});return i}const TB=()=>{};function fO(e,t,n,r=TB){e.push(t);const i=()=>{const s=e.indexOf(t);s>-1&&(e.splice(s,1),r())};return!n&&QC()&&$s(i),i}
9function fm(e,...t){e.slice().forEach(n=>{n(...t)})}const x7=e=>e();function lS(e,t){e instanceof Map&&t instanceof Map&&t.forEach((n,r)=>e.set(r,n)),e instanceof Set&&t instanceof Set&&t.forEach(e.add,e);for(const n in t){if(!t.hasOwnProperty(n))continue;const r=t[n],i=e[n];sS(i)&&sS(r)&&e.hasOwnProperty(n)&&!Ai(r)&&!dd(r)?e[n]=lS(i,r):e[n]=r}return e}const w7=Symbol();function T7(e){return!sS(e)||!e.hasOwnProperty(w7)}const{assign:Yh}=Object;function E7(e){return!!(Ai(e)&&e.effect)}function S7(e,t,n,r){const{state:i,actions:s,getters:c}=t,a=n.state.value[e];let m;function g(){a||(n.state.value[e]=i?i():{});const x=wv(n.state.value[e]);return Yh(x,s,Object.keys(c||{}).reduce((T,C)=>(T[C]=xv(yt(()=>{kv(n);const A=n._s.get(e);return c[C].call(A,A)})),T),{}))}return m=EB(e,g,t,n,r,!0),m}function EB(e,t,n={},r,i,s){let c;const a=Yh({actions:{}},n),m={deep:!0};let g,x,T=[],C=[],A;const P=r.state.value[e];!s&&!P&&(r.state.value[e]={}),jt({});let D;function B(K){let Y;g=x=!1,typeof K=="function"?(K(r.state.value[e]),Y={type:__.patchFunction,storeId:e,events:A}):(lS(r.state.value[e],K),Y={type:__.patchObject,payload:K,storeId:e,events:A});const me=D=Symbol();Qi().then(()=>{D===me&&(g=!0)}),x=!0,fm(T,Y,r.state.value[e])}const R=s?function(){const{state:Y}=n,me=Y?Y():{};this.$patch(ge=>{Yh(ge,me)})}:TB;function N(){c.stop(),T=[],C=[],r._s.delete(e)}function j(K,Y){return function(){kv(r);const me=Array.from(arguments),ge=[],ce=[];function fe(Te){ge.push(Te)}function ie(Te){ce.push(Te)}fm(C,{args:me,name:K,store:W,after:fe,onError:ie});let xe;try{xe=Y.apply(this&&this.$id===e?this:W,me)}catch(Te){throw fm(ce,Te),Te}return xe instanceof Promise?xe.then(Te=>(fm(ge,Te),Te)).catch(Te=>(fm(ce,Te),Promise.reject(Te))):(fm(ge,xe),xe)}}const U={_p:r,$id:e,$onAction:fO.bind(null,C),$patch:B,$reset:R,$subscribe(K,Y={}){const me=fO(T,K,Y.detached,()=>ge()),ge=c.run(()=>Nn(()=>r.state.value[e],ce=>{(Y.flush==="sync"?x:g)&&K({storeId:e,type:__.direct,events:A},ce)},Yh({},m,Y)));return me},$dispose:N},W=so(U);r._s.set(e,W);const Q=r._a&&r._a.runWithContext||x7,Z=r._e.run(()=>(c=xg(),Q(()=>c.run(t))));for(const K in Z){const Y=Z[K];if(Ai(Y)&&!E7(Y)||dd(Y))s||(P&&T7(Y)&&(Ai(Y)?Y.value=P[K]:lS(Y,P[K])),r.state.value[e][K]=Y);else if(typeof Y=="function"){const me=j(K,Y);Z[K]=me,a.actions[K]=Y}}return Yh(W,Z),Yh(Ar(W),Z),Object.defineProperty(W,"$state",{get:()=>r.state.value[e],set:K=>{B(Y=>{Yh(Y,K)})}}),r._p.forEach(K=>{Yh(W,c.run(()=>K({store:W,app:r._a,pinia:r,options:a})))}),P&&s&&n.hydrate&&n.hydrate(W.$state,P),g=!0,x=!0,W}function Ic(e,t,n){let r,i;const s=typeof t=="function";typeof e=="string"?(r=e,i=s?n:t):(i=e,r=e.id);function c(a,m){const g=gk();return a=a||(g?dr(wB,null):null),a&&kv(a),a=xB,a._s.has(r)||(s?EB(r,t,i,a):S7(r,i,a)),a._s.get(r)}return c.$id=r,c}const C7=()=>null;function k7(...e){const t=typeof e[e.length-1]=="string"?e.pop():void 0;typeof e[0]!="string"&&e.unshift(t);let[n,r,i={}]=e;if(typeof n!="string")throw new TypeError("[nuxt] [asyncData] key must be a string.");if(typeof r!="function")throw new TypeError("[nuxt] [asyncData] handler must be a function.");i.server=i.server??!0,i.default=i.default??C7,i.lazy=i.lazy??!1,i.immediate=i.immediate??!0;const s=qo(),c=()=>s.isHydrating?s.payload.data[n]:s.static.data[n],a=()=>c()!==void 0;s._asyncData[n]||(s._asyncData[n]={data:jt(c()??i.default()),pending:jt(!a()),error:Us(s.payload._errors,n),status:jt("idle")});const m={...s._asyncData[n]};m.refresh=m.execute=(C={})=>{if(s._asyncDataPromises[n]){if(C.dedupe===!1)return s._asyncDataPromises[n];s._asyncDataPromises[n].cancelled=!0}if((C._initial||s.isHydrating&&C._initial!==!1)&&a())return c();m.pending.value=!0,m.status.value="pending";const A=new Promise((P,D)=>{try{P(r(s))}catch(B){D(B)}}).then(P=>{if(A.cancelled)return s._asyncDataPromises[n];let D=P;i.transform&&(D=i.transform(P)),i.pick&&(D=A7(D,i.pick)),m.data.value=D,m.error.value=null,m.status.value="success"}).catch(P=>{if(A.cancelled)return s._asyncDataPromises[n];m.error.value=P,m.data.value=bt(i.default()),m.status.value="error"}).finally(()=>{A.cancelled||(m.pending.value=!1,s.payload.data[n]=m.data.value,m.error.value&&(s.payload._errors[n]=t1(m.error.value)),delete s._asyncDataPromises[n])});return s._asyncDataPromises[n]=A,s._asyncDataPromises[n]};const g=()=>m.refresh({_initial:!0}),x=i.server!==!1&&s.payload.serverRendered;{const C=ko();if(C&&!C._nuxtOnBeforeMountCbs){C._nuxtOnBeforeMountCbs=[];const P=C._nuxtOnBeforeMountCbs;C&&(l3(()=>{P.forEach(D=>{D()}),P.splice(0,P.length)}),Bi(()=>P.splice(0,P.length)))}x&&s.isHydrating&&a()?(m.pending.value=!1,m.status.value=m.error.value?"error":"success"):C&&(s.payload.serverRendered&&s.isHydrating||i.lazy)&&i.immediate?C._nuxtOnBeforeMountCbs.push(g):i.immediate&&g(),i.watch&&Nn(i.watch,()=>m.refresh());const A=s.hook("app:data:refresh",P=>{if(!P||P.includes(n))return m.refresh()});C&&Bi(A)}const T=Promise.resolve(s._asyncDataPromises[n]).then(()=>m);return Object.assign(T,m),T}function A7(e,t){const n={};for(const r of t)n[r]=e[r];return n}const pO=Object.freeze({ignoreUnknown:!1,respectType:!1,respectFunctionNames:!1,respectFunctionProperties:!1,unorderedObjects:!0,unorderedArrays:!1,unorderedSets:!1,excludeKeys:void 0,excludeValues:void 0,replacer:void 0});function cS(e,t){t?t={...pO,...t}:t=pO;const n=SB(t);return n.dispatch(e),n.toString()}const P7=Object.freeze(["prototype","__proto__","constructor"]);function SB(e){let t="",n=new Map;const r=i=>{t+=i};return{toString(){return t},getContext(){return n},dispatch(i){return e.replacer&&(i=e.replacer(i)),this[i===null?"null":typeof i](i)},object(i){if(i&&typeof i.toJSON=="function")return this.object(i.toJSON());const s=Object.prototype.toString.call(i);let c="";const a=s.length;a<10?c="unknown:["+s+"]":c=s.slice(8,a-1),c=c.toLowerCase();let m=null;if((m=n.get(i))===void 0)n.set(i,n.size);else return this.dispatch("[CIRCULAR:"+m+"]");if(typeof Buffer<"u"&&Buffer.isBuffer&&Buffer.isBuffer(i))return r("buffer:"),r(i.toString("utf8"));if(c!=="object"&&c!=="function"&&c!=="asyncfunction")this[c]?this[c](i):e.ignoreUnknown||this.unkown(i,c);else{let g=Object.keys(i);e.unorderedObjects&&(g=g.sort());let x=[];e.respectType!==!1&&!mO(i)&&(x=P7),e.excludeKeys&&(g=g.filter(C=>!e.excludeKeys(C)),x=x.filter(C=>!e.excludeKeys(C))),r("object:"+(g.length+x.length)+":");const T=C=>{this.dispatch(C),r(":"),e.excludeValues||this.dispatch(i[C]),r(",")};for(const C of g)T(C);for(const C of x)T(C)}},array(i,s){if(s=s===void 0?e.unorderedArrays!==!1:s,r("array:"+i.length+":"),!s||i.length<=1){for(const m of i)this.dispatch(m);return}const c=new Map,a=i.map(m=>{const g=SB(e);g.dispatch(m);for(const[x,T]of g.getContext())c.set(x,T);return g.toString()});return n=c,a.sort(),this.array(a,!1)},date(i){return r("date:"+i.toJSON())},symbol(i){return r("symbol:"+i.toString())},unkown(i,s){if(r(s),!!i&&(r(":"),i&&typeof i.entries=="function"))return this.array(Array.from(i.entries()),!0)},error(i){return r("error:"+i.toString())},boolean(i){return r("bool:"+i)},string(i){r("string:"+i.length+":"),r(i)},function(i){r("fn:"),mO(i)?this.dispatch("[native]"):this.dispatch(i.toString()),e.respectFunctionNames!==!1&&this.dispatch("function-name:"+String(i.name)),e.respectFunctionProperties&&this.object(i)},number(i){return r("number:"+i)},xml(i){return r("xml:"+i.toString())},null(){return r("Null")},undefined(){return r("Undefined")},regexp(i){return r("regex:"+i.toString())},uint8array(i){return r("uint8array:"),this.dispatch(Array.prototype.slice.call(i))},uint8clampedarray(i){return r("uint8clampedarray:"),this.dispatch(Array.prototype.slice.call(i))},int8array(i){return r("int8array:"),this.dispatch(Array.prototype.slice.call(i))},uint16array(i){return r("uint16array:"),this.dispatch(Array.prototype.slice.call(i))},int16array(i){return r("int16array:"),this.dispatch(Array.prototype.slice.call(i))},uint32array(i){return r("uint32array:"),this.dispatch(Array.prototype.slice.call(i))},int32array(i){return r("int32array:"),this.dispatch(Array.prototype.slice.call(i))},float32array(i){return r("float32array:"),this.dispatch(Array.prototype.slice.call(i))},float64array(i){return r("float64array:"),this.dispatch(Array.prototype.slice.call(i))},arraybuffer(i){return r("arraybuffer:"),this.dispatch(new Uint8Array(i))},url(i){return r("url:"+i.toString())},map(i){r("map:");const s=[...i];return this.array(s,e.unorderedSets!==!1)},set(i){r("set:");const s=[...i];return this.array(s,e.unorderedSets!==!1)},file(i){return r("file:"),this.dispatch([i.name,i.size,i.type,i.lastModfied])},blob(){if(e.ignoreUnknown)return r("[blob]");throw new Error(`Hashing Blob objects is currently not supported
10Use "options.replacer" or "options.ignoreUnknown"
11`)},domwindow(){return r("domwindow")},bigint(i){return r("bigint:"+i.toString())},process(){return r("process")},timer(){return r("timer")},pipe(){return r("pipe")},tcp(){return r("tcp")},udp(){return r("udp")},tty(){return r("tty")},statwatcher(){return r("statwatcher")},securecontext(){return r("securecontext")},connection(){return r("connection")},zlib(){return r("zlib")}
11,context(){return r("context")},nodescript(){return r("nodescript")},httpparser(){return r("httpparser")},dataview(){return r("dataview")},signal(){return r("signal")},fsevent(){return r("fsevent")},tlswrap(){return r("tlswrap")}}}const CB="[native code] }",M7=CB.length;function mO(e){return typeof e!="function"?!1:Function.prototype.toString.call(e).slice(-M7)===CB}class yd{constructor(t,n){t=this.words=t||[],this.sigBytes=n===void 0?t.length*4:n}toString(t){return(t||I7).stringify(this)}concat(t){if(this.clamp(),this.sigBytes%4)for(let n=0;n<t.sigBytes;n++){const r=t.words[n>>>2]>>>24-n%4*8&255;this.words[this.sigBytes+n>>>2]|=r<<24-(this.sigBytes+n)%4*8}else for(let n=0;n<t.sigBytes;n+=4)this.words[this.sigBytes+n>>>2]=t.words[n>>>2];return this.sigBytes+=t.sigBytes,this}clamp(){this.words[this.sigBytes>>>2]&=4294967295<<32-this.sigBytes%4*8,this.words.length=Math.ceil(this.sigBytes/4)}clone(){return new yd([...this.words])}}const I7={stringify(e){const t=[];for(let n=0;n<e.sigBytes;n++){const r=e.words[n>>>2]>>>24-n%4*8&255;t.push((r>>>4).toString(16),(r&15).toString(16))}return t.join("")}},O7={stringify(e){const t="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789",n=[];for(let r=0;r<e.sigBytes;r+=3){const i=e.words[r>>>2]>>>24-r%4*8&255,s=e.words[r+1>>>2]>>>24-(r+1)%4*8&255,c=e.words[r+2>>>2]>>>24-(r+2)%4*8&255,a=i<<16|s<<8|c;for(let m=0;m<4&&r*8+m*6<e.sigBytes*8;m++)n.push(t.charAt(a>>>6*(3-m)&63))}return n.join("")}},D7={parse(e){const t=e.length,n=[];for(let r=0;r<t;r++)n[r>>>2]|=(e.charCodeAt(r)&255)<<24-r%4*8;return new yd(n,t)}},L7={parse(e){return D7.parse(unescape(encodeURIComponent(e)))}};class R7{constructor(){this._data=new yd,this._nDataBytes=0,this._minBufferSize=0,this.blockSize=512/32}reset(){this._data=new yd,this._nDataBytes=0}_append(t){typeof t=="string"&&(t=L7.parse(t)),this._data.concat(t),this._nDataBytes+=t.sigBytes}_doProcessBlock(t,n){}_process(t){let n,r=this._data.sigBytes/(this.blockSize*4);t?r=Math.ceil(r):r=Math.max((r|0)-this._minBufferSize,0);const i=r*this.blockSize,s=Math.min(i*4,this._data.sigBytes);if(i){for(let c=0;c<i;c+=this.blockSize)this._doProcessBlock(this._data.words,c);n=this._data.words.splice(0,i),this._data.sigBytes-=s}return new yd(n,s)}}class F7 extends R7{update(t){return this._append(t),this._process(),this}finalize(t){t&&this._append(t)}}const gO=[1779033703,-1150833019,1013904242,-1521486534,1359893119,-1694144372,528734635,1541459225],B7=[1116352408,1899447441,-1245643825,-373957723,961987163,1508970993,-1841331548,-1424204075,-670586216,310598401,607225278,1426881987,1925078388,-2132889090,-1680079193,-1046744716,-459576895,-272742522,264347078,604807628,770255983,1249150122,1555081692,1996064986,-1740746414,-1473132947,-1341970488,-1084653625,-958395405,-710438585,113926993,338241895,666307205,773529912,1294757372,1396182291,1695183700,1986661051,-2117940946,-1838011259,-1564481375,-1474664885,-1035236496,-949202525,-778901479,-694614492,-200395387,275423344,430227734,506948616,659060556,883997877,958139571,1322822218,1537002063,1747873779,1955562222,2024104815,-2067236844,-1933114872,-1866530822,-1538233109,-1090935817,-965641998],If=[];class z7 extends F7{constructor(){super(...arguments),this._hash=new yd([...gO])}reset(){super.reset(),this._hash=new yd([...gO])}_doProcessBlock(t,n){const r=this._hash.words;let i=r[0],s=r[1],c=r[2],a=r[3],m=r[4],g=r[5],x=r[6],T=r[7];for(let C=0;C<64;C++){if(C<16)If[C]=t[n+C]|0;else{const j=If[C-15],U=(j<<25|j>>>7)^(j<<14|j>>>18)^j>>>3,W=If[C-2],Q=(W<<15|W>>>17)^(W<<13|W>>>19)^W>>>10;If[C]=U+If[C-7]+Q+If[C-16]}const A=m&g^~m&x,P=i&s^i&c^s&c,D=(i<<30|i>>>2)^(i<<19|i>>>13)^(i<<10|i>>>22),B=(m<<26|m>>>6)^(m<<21|m>>>11)^(m<<7|m>>>25),R=T+B+A+B7[C]+If[C],N=D+P;T=x,x=g,g=m,m=a+R|0,a=c,c=s,s=i,i=R+N|0}r[0]=r[0]+i|0,r[1]=r[1]+s|0,r[2]=r[2]+c|0,r[3]=r[3]+a|0,r[4]=r[4]+m|0,r[5]=r[5]+g|0,r[6]=r[6]+x|0,r[7]=r[7]+T|0}finalize(t){super.finalize(t);const n=this._nDataBytes*8,r=this._data.sigBytes*8;return this._data.words[r>>>5]|=128<<24-r%32,this._data.words[(r+64>>>9<<4)+14]=Math.floor(n/4294967296),this._data.words[(r+64>>>9<<4)+15]=n,this._data.sigBytes=this._data.words.length*4,this._process(),this._hash}}function N7(e){return new z7().finalize(e).toString(O7)}function $7(e,t={}){const n=typeof e=="string"?e:cS(e,t);return N7(n).slice(0,10)}function j7(e,t,n={}){return e===t||cS(e,n)===cS(t,n)}function U7(e){return{}}const V7={path:"/",watch:!0,decode:e=>U3(decodeURIComponent(e)),encode:e=>encodeURIComponent(typeof e=="string"?e:JSON.stringify(e))};function uS(e,t){var s;const n={...V7,...t},r=G7(n)||{},i=jt(r[e]??((s=n.default)==null?void 0:s.call(n)));{const c=typeof BroadcastChannel>"u"?null:new BroadcastChannel(`nuxt:cookies:${e}`);ko()&&Bi(()=>{c==null||c.close()});const a=()=>{W7(e,i.value,n),c==null||c.postMessage(Ar(i.value))};let m=!1;c&&(c.onmessage=g=>{m=!0,i.value=g.data,Qi(()=>{m=!1})}),n.watch?Nn(i,(g,x)=>{m||j7(g,x)||a()},{deep:n.watch!=="shallow"}):a()}return i}function G7(e={}){return ZW(document.cookie,e)}function q7(e,t,n={}){return t==null?HI(e,t,{...n,maxAge:-1}):HI(e,t,n)}function W7(e,t,n={}){document.cookie=q7(e,t,n)}function H7(e={}){const t=e.path||window.location.pathname;let n={};try{n=JSON.parse(sessionStorage.getItem("nuxt:reload")||"{}")}catch{}if(e.force||(n==null?void 0:n.path)!==t||(n==null?void 0:n.expires)<Date.now()){try{sessionStorage.setItem("nuxt:reload",JSON.stringify({path:t,expires:Date.now()+(e.ttl??1e4)}))}catch{}if(e.persistState)try{sessionStorage.setItem("nuxt:reload:state",JSON.stringify({state:qo().payload.state}))}catch{}window.location.pathname!==t?window.location.href=t:window.location.reload()}}const Y7=Gi(e=>{const t=b7();return e.vueApp.use(t),kv(t),e.payload&&e.payload.pinia&&(t.state.value=e.payload.pinia),{provide:{pinia:t}}}),Z7=Gi({name:"nuxt:global-components"}),X7=Gi({name:"nuxt:head",setup(e){const n=FW();n.push(jW),e.vueApp.use(n);{let r=!0;const i=()=>{r=!1,n.hooks.callHook("entries:updated",n)};n.hooks.hook("dom:beforeRender",s=>{s.shouldRender=!r}),e.hooks.hook("page:start",()=>{r=!0}),e.hooks.hook("page:finish",i),e.hooks.hook("app:suspense:resolve",i)}}}),Zf={"blog-home":()=>Sn(()=>import("./blog-home.7969c795.js"),["./blog-home.7969c795.js","./index.1a81bcb4.js","./nuxt-link.6243d81b.js","./constants.a7ac9ca4.js","./index.0f990383.js","./logo.129927ce.js","./VBtn.b870324c.js","./group.2cdc14d0.js","./group.9bfde38d.css","./VDefaultsProvider.9c2bb8ee.js","./VBtn.3c529c85.css","./VImg.a63e6fbd.js","./index.c048e374.js","./VImg.9014554e.css","./layout.8ec5c668.js","./ssrBoot.74019366.js","./VRow.b0cbbd6b.js","./VGrid.b7f52dfd.css","./VListItem.0f228b79.js","./createSimpleFunctional.24e8d9e4.js","./VAvatar.5e7c6354.js","./VAvatar.b72a6b57.css","./VListItem.360a1571.css","./VCard.0bff31d4.js","./VCard.911f41ce.css","./index.07d2f18c.css"],import.meta.url).then(e=>e.default||e),blog:()=>Sn(()=>import("./blog.c2b57120.js"),[],import.meta.url).then(e=>e.default||e),default:()=>Sn(()=>import("./default.9cdbf33a.js"),["./default.9cdbf33a.js","./BAlert.4c530142.js","./layout.8ec5c668.js","./createSimpleFunctional.24e8d9e4.js","./VDefaultsProvider.9c2bb8ee.js","./group.2cdc14d0.js","./group.9bfde38d.css","./VBtn.b870324c.js","./VBtn.3c529c85.css","./BAlert.34a60e6a.css","./index.0f990383.js","./VMain.ba10a01d.js","./ssrBoot.74019366.js","./VMain.e6b12815.css","./default.02d24ab5.css"],import.meta.url).then(e=>e.default||e),desktop:()=>Sn(()=>import("./desktop.adfeacb5.js"),["./desktop.adfeacb5.js","./BText.98e0af33.js","./BText.4187dff4.css","./Navigation.11a4ff71.js","./VBtn.b870324c.js","./group.2cdc14d0.js","./group.9bfde38d.css","./VDefaultsProvider.9c2bb8ee.js","./VBtn.3c529c85.css","./layout.8ec5c668.js","./ssrBoot.74019366.js","./VTabs.e0427fe1.js","./VTabs.3926bdaa.css","./Navigation.56fcc89d.css","./BAlert.4c530142.js","./createSimpleFunctional.24e8d9e4.js","./BAlert.34a60e6a.css","./brik-mix.924f0a7e.js","./VCard.0bff31d4.js","./VAvatar.5e7c6354.js","./VImg.a63e6fbd.js","./index.c048e374.js","./VImg.9014554e.css","./VAvatar.b72a6b57.css","./VCard.911f41ce.css","./VDialog.6be3fb98.js","./forwardRefs.e2994a01.js","./dialog-transition.33e3c46d.js","./VDialog.f0a29abf.css","./VMain.ba10a01d.js","./VMain.e6b12815.css","./desktop.7e2c2076.css"],import.meta.url).then(e=>e.default||e),home:()=>Sn(()=>
11import("./home.0e28390e.js"),["./home.0e28390e.js","./index.1a81bcb4.js","./nuxt-link.6243d81b.js","./constants.a7ac9ca4.js","./index.0f990383.js","./logo.129927ce.js","./VBtn.b870324c.js","./group.2cdc14d0.js","./group.9bfde38d.css","./VDefaultsProvider.9c2bb8ee.js","./VBtn.3c529c85.css","./VImg.a63e6fbd.js","./index.c048e374.js","./VImg.9014554e.css","./layout.8ec5c668.js","./ssrBoot.74019366.js","./VRow.b0cbbd6b.js","./VGrid.b7f52dfd.css","./VListItem.0f228b79.js","./createSimpleFunctional.24e8d9e4.js","./VAvatar.5e7c6354.js","./VAvatar.b72a6b57.css","./VListItem.360a1571.css","./VCard.0bff31d4.js","./VCard.911f41ce.css","./index.07d2f18c.css","./client-only.f3ab23a1.js","./home.ec3d3a07.css"],import.meta.url).then(e=>e.default||e),mobile:()=>Sn(()=>import("./mobile.8929f9e0.js"),["./mobile.8929f9e0.js","./VMain.ba10a01d.js","./layout.8ec5c668.js","./ssrBoot.74019366.js","./VMain.e6b12815.css","./mobile.81c9043b.css"],import.meta.url).then(e=>e.default||e),pages:()=>Sn(()=>import("./pages.512e97d7.js"),["./pages.512e97d7.js","./index.1a81bcb4.js","./nuxt-link.6243d81b.js","./constants.a7ac9ca4.js","./index.0f990383.js","./logo.129927ce.js","./VBtn.b870324c.js","./group.2cdc14d0.js","./group.9bfde38d.css","./VDefaultsProvider.9c2bb8ee.js","./VBtn.3c529c85.css","./VImg.a63e6fbd.js","./index.c048e374.js","./VImg.9014554e.css","./layout.8ec5c668.js","./ssrBoot.74019366.js","./VRow.b0cbbd6b.js","./VGrid.b7f52dfd.css","./VListItem.0f228b79.js","./createSimpleFunctional.24e8d9e4.js","./VAvatar.5e7c6354.js","./VAvatar.b72a6b57.css","./VListItem.360a1571.css","./VCard.0bff31d4.js","./VCard.911f41ce.css","./index.07d2f18c.css"],import.meta.url).then(e=>e.default||e),"with-menu":()=>Sn(()=>import("./withMenu.17847e9a.js"),["./withMenu.17847e9a.js","./BAlert.4c530142.js","./layout.8ec5c668.js","./createSimpleFunctional.24e8d9e4.js","./VDefaultsProvider.9c2bb8ee.js","./group.2cdc14d0.js","./group.9bfde38d.css","./VBtn.b870324c.js","./VBtn.3c529c85.css","./BAlert.34a60e6a.css","./VMain.ba10a01d.js","./ssrBoot.74019366.js","./VMain.e6b12815.css","./withMenu.f2cccef2.css"],import.meta.url).then(e=>e.default||e)},K7=Gi({name:"nuxt:prefetch",setup(e){const t=Sg();e.hooks.hook("app:mounted",()=>{t.beforeEach(async n=>{var i;const r=(i=n==null?void 0:n.meta)==null?void 0:i.layout;r&&typeof Zf[r]=="function"&&await Zf[r]()})}),e.hooks.hook("link:prefetch",n=>{var c,a,m,g;if(Qx(n))return;const r=t.resolve(n);if(!r)return;const i=(c=r==null?void 0:r.meta)==null?void 0:c.layout;let s=Array.isArray((a=r==null?void 0:r.meta)==null?void 0:a.middleware)?(m=r==null?void 0:r.meta)==null?void 0:m.middleware:[(g=r==null?void 0:r.meta)==null?void 0:g.middleware];s=s.filter(x=>typeof x=="string");for(const x of s)typeof y_[x]=="function"&&y_[x]();i&&typeof Zf[i]=="function"&&Zf[i]()})}});var yO=/^GTM-[0-9A-Z]+$/;function bT(e){if(typeof e!="string"||!yO.test(e)){let t=String(e).toUpperCase().replace(/.*-|[^0-9A-Z]/g,""),n=t.length===0?"":` Did you mean 'GTM-${t}'?`;throw new Error(`'${e}' is not a valid GTM-ID (${yO}).${n}`)}}function zm(e,t){var m;let n=document,r=n.createElement("script"),i=g=>{var x;(x=t.onReady)==null||x.call(t,{id:e,script:r}),r.removeEventListener("load",i)};if(r.addEventListener("load",i),window.dataLayer=window.dataLayer??[],(m=window.dataLayer)==null||m.push({event:"gtm.js","gtm.start":new Date().getTime()}),!e)return r;r.async=!t.defer,r.defer=!!(t.defer||t.compatibility),t.nonce&&(r.nonce=t.nonce),t.scriptType&&(r.type=t.scriptType);let s=new URLSearchParams({id:e,...t.queryParams??{}}),c=t.source??"https://www.googletagmanager.com/gtm.js";r.src=`${c}?${s}`;let a=t.parentElement??n.body;if(typeof(a==null?void 0:a.appendChild)!="function")throw new Error("parentElement must be a DOM element");return a.appendChild(r),r}function Q7(e="https://www.googletagmanager.com/gtm.js"){return Array.from(document.getElementsByTagName("script")).some(t=>t.src.includes(e))}var J7=class{constructor(t){Oy(this,"id");Oy(this,"options");Oy(this,"scriptElements",[]);Oy(this,"isInBrowserContext",()=>typeof window<"u");if(Array.isArray(t.id))for(let n of t.id)bT(typeof n=="string"?n:n.id);else bT(t.id);this.id=t.id,this.options={enabled:!0,debug:!1,loadScript:!0,defer:!1,compatibility:!1,...t},delete this.options.id}enabled(){return this.options.enabled??!0}
11enable(t=!0,n){if(this.options.enabled=t,this.isInBrowserContext()&&t&&!Q7(n)&&this.options.loadScript)if(Array.isArray(this.id))this.id.forEach(r=>{let i;typeof r=="string"?i=zm(r,{...this.options}):i=zm(r.id,{...this.options,queryParams:r.queryParams}),this.scriptElements.push(i)});else{let r=zm(this.id,{...this.options});this.scriptElements.push(r)}}debugEnabled(){return this.options.debug??!1}debug(t){this.options.debug=t}dataLayer(){return this.isInBrowserContext()&&this.options.enabled?window.dataLayer=window.dataLayer??[]:!1}trackView(t,n,r={}){let i=this.isInBrowserContext()&&(this.options.enabled??!1);this.options.debug&&console.log(`[GTM-Support${i?"":"(disabled)"}]: Dispatching TrackView`,{screenName:t,path:n}),i&&(window.dataLayer=window.dataLayer??[]).push({...r,event:this.options.trackViewEventProperty??"content-view","content-name":n,"content-view-name":t})}trackEvent({event:t,category:n=null,action:r=null,label:i=null,value:s=null,noninteraction:c=!1,...a}={}){let m=this.isInBrowserContext()&&(this.options.enabled??!1);this.options.debug&&console.log(`[GTM-Support${m?"":"(disabled)"}]: Dispatching event`,{event:t,category:n,action:r,label:i,value:s,...a}),m&&(window.dataLayer=window.dataLayer??[]).push({event:t??"interaction",target:n,action:r,"target-properties":i,value:s,"interaction-type":c,...a})}push(t){let n=this.isInBrowserContext()&&(this.options.enabled??!1);this.options.debug&&console.log(`[GTM-Support${n?"":"(disabled)"}]: Dispatching event`,t),n&&(window.dataLayer=window.dataLayer??[]).push(t)}},Ra;function e9(e,t={id:""}){t={trackOnNextTick:!1,...t},Ra=new J7(t),e.config.globalProperties.$gtm=Ra,Ra.isInBrowserContext()&&(t.vueRouter&&t9(e,t.vueRouter,t.ignoredViews,t.trackOnNextTick,t.vueRouterAdditionalEventData),Ra.options.enabled&&Ra.options.loadScript&&(Array.isArray(t.id)?t.id.forEach(n=>{if(typeof n=="string")zm(n,t);else{let r={...t};n.queryParams!=null&&(r.queryParams={...r.queryParams,...n.queryParams}),zm(n.id,r)}}):zm(t.id,t))),e.provide("gtm",t)}function t9(e,t,n=[],r,i=()=>({})){function s(c,a){return c instanceof Error?!!(c.type&a):!1}t.afterEach(async(c,a,m)=>{var C,A,P;if(typeof c.name!="string"||Array.isArray(n)&&n.includes(c.name)||typeof n=="function"&&n(c,a))return;let g=c.meta&&typeof c.meta.gtm=="string"&&c.meta.gtm?c.meta.gtm:c.name;s(m,4)?Ra!=null&&Ra.debugEnabled()&&console.log(`[VueGtm]: '${g}' not tracked due to navigation aborted`):s(m,8)&&(Ra!=null&&Ra.debugEnabled())&&console.log(`[VueGtm]: '${g}' not tracked due to navigation cancelled`);let x={...await i(c,a),...(C=c.meta)==null?void 0:C.gtmAdditionalEventData},T=((P=(A=t.options)==null?void 0:A.history)==null?void 0:P.base)??"";T.endsWith("/")||(T+="/"),T+=c.fullPath.startsWith("/")?c.fullPath.substring(1):c.fullPath,r?Qi(()=>{Ra==null||Ra.trackView(g,T,x)}):Ra==null||Ra.trackView(g,T,x)})}function n9(e){return{install:t=>e9(t,e)}}const r9=Gi(e=>{{const t=e.$config.public.gtm,n=Sg(),r={...t,vueRouter:t.enableRouterSync&&n?n:void 0};e.vueApp.use(n9(r))}});function _O(e,...t){var n;(n=window.dataLayer)==null||n.push(arguments)}function i9({id:e,config:t}){window.dataLayer=window.dataLayer||[],_O("js",new Date),_O("config",e,t)}const o9=Gi(()=>{const{gtag:{id:e,config:t,initialConsent:n,loadingStrategy:r}}=Eg().public;if(!e||(i9({id:e,config:t}),!n))return;const i=r==="async"?"async":"defer";$W({script:[{src:`https://www.googletagmanager.com/gtag/js?id=${e}`,[i]:!0}]})}),a9=/"(?:_|\\u0{2}5[Ff]){2}(?:p|\\u0{2}70)(?:r|\\u0{2}72)(?:o|\\u0{2}6[Ff])(?:t|\\u0{2}74)(?:o|\\u0{2}6[Ff])(?:_|\\u0{2}5[Ff]){2}"\s*:/,s9=/"(?:c|\\u0063)(?:o|\\u006[Ff])(?:n|\\u006[Ee])(?:s|\\u0073)(?:t|\\u0074)(?:r|\\u0072)(?:u|\\u0075)(?:c|\\u0063)(?:t|\\u0074)(?:o|\\u006[Ff])(?:r|\\u0072)"\s*:/,l9=/^\s*["[{]|^\s*-?\d[\d.]{0,14}\s*$/;function c9(e,t){if(e!=="__proto__"&&!(e==="constructor"&&t&&typeof t=="object"&&"prototype"in t))return t}function u9(e,t={}){if(typeof e!="string")return e;const n=e.toLowerCase().trim();if(n==="true")return!0;if(n==="false")return!1;if(n==="null")return null;if(n==="nan")return Number.NaN;if(n==="infinity")return Number.POSITIVE_INFINITY;if(n!=="undefined"){if(!l9.test(e)){if(t.strict)throw new SyntaxError("Invalid JSON");return e}try{return a9.test(e)||s9.test(e)?JSON.parse(e,c9):JSON.parse(e)}catch(r){if(t.strict)throw r;return e}}}
11var hS=function(e,t){return hS=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(n,r){n.__proto__=r}||function(n,r){for(var i in r)Object.prototype.hasOwnProperty.call(r,i)&&(n[i]=r[i])},hS(e,t)};function Kl(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");hS(e,t);function n(){this.constructor=e}e.prototype=t===null?Object.create(t):(n.prototype=t.prototype,new n)}var Lt=function(){return Lt=Object.assign||function(t){for(var n,r=1,i=arguments.length;r<i;r++){n=arguments[r];for(var s in n)Object.prototype.hasOwnProperty.call(n,s)&&(t[s]=n[s])}return t},Lt.apply(this,arguments)};function rh(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(e!=null&&typeof Object.getOwnPropertySymbols=="function")for(var i=0,r=Object.getOwnPropertySymbols(e);i<r.length;i++)t.indexOf(r[i])<0&&Object.prototype.propertyIsEnumerable.call(e,r[i])&&(n[r[i]]=e[r[i]]);return n}function Qh(e,t,n,r){function i(s){return s instanceof n?s:new n(function(c){c(s)})}return new(n||(n=Promise))(function(s,c){function a(x){try{g(r.next(x))}catch(T){c(T)}}function m(x){try{g(r.throw(x))}catch(T){c(T)}}function g(x){x.done?s(x.value):i(x.value).then(a,m)}g((r=r.apply(e,t||[])).next())})}function Jh(e,t){var n={label:0,sent:function(){if(s[0]&1)throw s[1];return s[1]},trys:[],ops:[]},r,i,s,c;return c={next:a(0),throw:a(1),return:a(2)},typeof Symbol=="function"&&(c[Symbol.iterator]=function(){return this}),c;function a(g){return function(x){return m([g,x])}}function m(g){if(r)throw new TypeError("Generator is already executing.");for(;c&&(c=0,g[0]&&(n=0)),n;)try{if(r=1,i&&(s=g[0]&2?i.return:g[0]?i.throw||((s=i.return)&&s.call(i),0):i.next)&&!(s=s.call(i,g[1])).done)return s;switch(i=0,s&&(g=[g[0]&2,s.value]),g[0]){case 0:case 1:s=g;break;case 4:return n.label++,{value:g[1],done:!1};case 5:n.label++,i=g[1],g=[0];continue;case 7:g=n.ops.pop(),n.trys.pop();continue;default:if(s=n.trys,!(s=s.length>0&&s[s.length-1])&&(g[0]===6||g[0]===2)){n=0;continue}if(g[0]===3&&(!s||g[1]>s[0]&&g[1]<s[3])){n.label=g[1];break}if(g[0]===6&&n.label<s[1]){n.label=s[1],s=g;break}if(s&&n.label<s[2]){n.label=s[2],n.ops.push(g);break}s[2]&&n.ops.pop(),n.trys.pop();continue}g=t.call(e,n)}catch(x){g=[6,x],i=0}finally{r=s=0}if(g[0]&5)throw g[1];return{value:g[0]?g[1]:void 0,done:!0}}}function rp(e,t,n){if(n||arguments.length===2)for(var r=0,i=t.length,s;r<i;r++)(s||!(r in t))&&(s||(s=Array.prototype.slice.call(t,0,r)),s[r]=t[r]);return e.concat(s||Array.prototype.slice.call(t))}var xT="Invariant Violation",vO=Object.setPrototypeOf,h9=vO===void 0?function(e,t){return e.__proto__=t,e}:vO,kB=function(e){Kl(t,e);function t(n){n===void 0&&(n=xT);var r=e.call(this,typeof n=="number"?xT+": "+n+" (see https://github.com/apollographql/invariant-packages)":n)||this;return r.framesToPop=1,r.name=xT,h9(r,t.prototype),r}return t}(Error);function Hf(e,t){if(!e)throw new kB(t)}var AB=["debug","log","warn","error","silent"],d9=AB.indexOf("log");function eb(e){return function(){if(AB.indexOf(e)>=d9){var t=console[e]||console.log;return t.apply(console,arguments)}}}(function(e){e.debug=eb("debug"),e.log=eb("log"),e.warn=eb("warn"),e.error=eb("error")})(Hf||(Hf={}));var kk="3.8.6";function wc(e){try{return e()}catch{}}const bO=wc(function(){return globalThis})||wc(function(){return window})||wc(function(){return self})||wc(function(){return global})||wc(function(){return wc.constructor("return this")()});var xO=new Map;function dS(e){var t=xO.get(e)||1;return xO.set(e,t+1),"".concat(e,":").concat(t,":").concat(Math.random().toString(36).slice(2))}function PB(e,t){t===void 0&&(t=0);var n=dS("stringifyForDisplay");return JSON.stringify(e,function(r,i){return i===void 0?n:i},t).split(JSON.stringify(n)).join("<undefined>")}function tb(e){return function(t){for(var n=[],r=1;r<arguments.length;r++)n[r-1]=arguments[r];if(typeof t=="number"){var i=t;t=Ak(i),t||(t=Pk(i,n),n=[])}e.apply(void 0,[t].concat(n))}}var hr=Object.assign(function(t,n){for(var r=[],i=2;i<arguments.length;i++)r[i-2]=arguments[i];t||Hf(t,Ak(n,r)||Pk(n,r))},{debug:tb(Hf.debug),log:tb(Hf.log),warn:tb(Hf.warn),error:tb(Hf.error)});function vs(e){for(var t=[],n=1;n<arguments.length;n++)t[n-1]=arguments[n];return new kB(Ak(e,t)||Pk(e,t))}var wO=Symbol.for("ApolloErrorMessageHandler_"+kk);function MB(e){return typeof e=="string"?e:PB(e,2).slice(0,1e3)}function Ak(e,t){if(t===void 0&&(t=[]),!!e)return bO[wO]&&bO[wO](e,t.map(MB))}function Pk(e,t){if(t===void 0&&(t=[]),!!e)return"An error occurred! For more details, see the full error text at https://go.apollo.dev/c/err#".concat(encodeURIComponent(JSON.stringify({version:kk,message:e,args:t.map(MB)}
vendor: 10,048 bytes, lines 11-18
11)))}function f9(e,t){if(!!!e)throw new Error(t)}class T_e{constructor(t,n,r){this.start=t.start,this.end=n.end,this.startToken=t,this.endToken=n,this.source=r}get[Symbol.toStringTag](){return"Location"}toJSON(){return{start:this.start,end:this.end}}}class E_e{constructor(t,n,r,i,s,c){this.kind=t,this.start=n,this.end=r,this.line=i,this.column=s,this.value=c,this.prev=null,this.next=null}get[Symbol.toStringTag](){return"Token"}toJSON(){return{kind:this.kind,value:this.value,line:this.line,column:this.column}}}const IB={Name:[],Document:["definitions"],OperationDefinition:["name","variableDefinitions","directives","selectionSet"],VariableDefinition:["variable","type","defaultValue","directives"],Variable:["name"],SelectionSet:["selections"],Field:["alias","name","arguments","directives","selectionSet"],Argument:["name","value"],FragmentSpread:["name","directives"],InlineFragment:["typeCondition","directives","selectionSet"],FragmentDefinition:["name","variableDefinitions","typeCondition","directives","selectionSet"],IntValue:[],FloatValue:[],StringValue:[],BooleanValue:[],NullValue:[],EnumValue:[],ListValue:["values"],ObjectValue:["fields"],ObjectField:["name","value"],Directive:["name","arguments"],NamedType:["name"],ListType:["type"],NonNullType:["type"],SchemaDefinition:["description","directives","operationTypes"],OperationTypeDefinition:["type"],ScalarTypeDefinition:["description","name","directives"],ObjectTypeDefinition:["description","name","interfaces","directives","fields"],FieldDefinition:["description","name","arguments","type","directives"],InputValueDefinition:["description","name","type","defaultValue","directives"],InterfaceTypeDefinition:["description","name","interfaces","directives","fields"],UnionTypeDefinition:["description","name","directives","types"],EnumTypeDefinition:["description","name","directives","values"],EnumValueDefinition:["description","name","directives"],InputObjectTypeDefinition:["description","name","directives","fields"],DirectiveDefinition:["description","name","arguments","locations"],SchemaExtension:["directives","operationTypes"],ScalarTypeExtension:["name","directives"],ObjectTypeExtension:["name","interfaces","directives","fields"],InterfaceTypeExtension:["name","interfaces","directives","fields"],UnionTypeExtension:["name","directives","types"],EnumTypeExtension:["name","directives","values"],InputObjectTypeExtension:["name","directives","fields"]},p9=new Set(Object.keys(IB));function TO(e){const t=e==null?void 0:e.kind;return typeof t=="string"&&p9.has(t)}var EO;(function(e){e.QUERY="query",e.MUTATION="mutation",e.SUBSCRIPTION="subscription"})(EO||(EO={}));var Ta;(function(e){e.NAME="Name",e.DOCUMENT="Document",e.OPERATION_DEFINITION="OperationDefinition",e.VARIABLE_DEFINITION="VariableDefinition",e.SELECTION_SET="SelectionSet",e.FIELD="Field",e.ARGUMENT="Argument",e.FRAGMENT_SPREAD="FragmentSpread",e.INLINE_FRAGMENT="InlineFragment",e.FRAGMENT_DEFINITION="FragmentDefinition",e.VARIABLE="Variable",e.INT="IntValue",e.FLOAT="FloatValue",e.STRING="StringValue",e.BOOLEAN="BooleanValue",e.NULL="NullValue",e.ENUM="EnumValue",e.LIST="ListValue",e.OBJECT="ObjectValue",e.OBJECT_FIELD="ObjectField",e.DIRECTIVE="Directive",e.NAMED_TYPE="NamedType",e.LIST_TYPE="ListType",e.NON_NULL_TYPE="NonNullType",e.SCHEMA_DEFINITION="SchemaDefinition",e.OPERATION_TYPE_DEFINITION="OperationTypeDefinition",e.SCALAR_TYPE_DEFINITION="ScalarTypeDefinition",e.OBJECT_TYPE_DEFINITION="ObjectTypeDefinition",e.FIELD_DEFINITION="FieldDefinition",e.INPUT_VALUE_DEFINITION="InputValueDefinition",e.INTERFACE_TYPE_DEFINITION="InterfaceTypeDefinition",e.UNION_TYPE_DEFINITION="UnionTypeDefinition",e.ENUM_TYPE_DEFINITION="EnumTypeDefinition",e.ENUM_VALUE_DEFINITION="EnumValueDefinition",e.INPUT_OBJECT_TYPE_DEFINITION="InputObjectTypeDefinition",e.DIRECTIVE_DEFINITION="DirectiveDefinition",e.SCHEMA_EXTENSION="SchemaExtension",e.SCALAR_TYPE_EXTENSION="ScalarTypeExtension",e.OBJECT_TYPE_EXTENSION="ObjectTypeExtension",e.INTERFACE_TYPE_EXTENSION="InterfaceTypeExtension",e.UNION_TYPE_EXTENSION="UnionTypeExtension",e.ENUM_TYPE_EXTENSION="EnumTypeExtension",e.INPUT_OBJECT_TYPE_EXTENSION="InputObjectTypeExtension"})(Ta||(Ta={}));function fS(e){return e===9||e===32}function m9(e){return e>=48&&e<=57}function OB(e){return e>=97&&e<=122||e>=65&&e<=90}function S_e(e){return OB(e)||e===95}function C_e(e){return OB(e)||m9(e)||e===95}function k_e(e){var t;let n=Number.MAX_SAFE_INTEGER,r=null,i=-1;for(let c=0;c<e.length;++c){var s;const a=e[c],m=g9(a);m!==a.length&&(r=(s=r)!==null&&s!==void 0?s:c,i=c,c!==0&&m<n&&(n=m))}return e.map((c,a)=>a===0?c:c.slice(n)).slice((t=r)!==null&&t!==void 0?t:0,i+1)}function g9(e){let t=0;for(;t<e.length&&fS(e.charCodeAt(t));)++t;return t}function y9(e,t){const n=e.replace(/"""/g,'\\"""'),r=n.split(/\r\n|[\n\r]/g),i=r.length===1,s=r.length>1&&r.slice(1).every(A=>A.length===0||fS(A.charCodeAt(0))),c=n.endsWith('\\"""'),a=e.endsWith('"')&&!c,m=e.endsWith("\\"),g=a||m,x=!(t!=null&&t.minimize)&&(!i||e.length>70||g||s||c);let T="";const C=i&&fS(e.charCodeAt(0));return(x&&!C||s)&&(T+=`
12`),T+=n,(x||g)&&(T+=`
13`),'"""'+T+'"""'}const _9=10,DB=2;function v9(e){return r1(e,[])}function r1(e,t){switch(typeof e){case"string":return JSON.stringify(e);case"function":return e.name?`[function ${e.name}]`:"[function]";case"object":return b9(e,t);default:return String(e)}}function b9(e,t){if(e===null)return"null";if(t.includes(e))return"[Circular]";const n=[...t,e];if(x9(e)){const r=e.toJSON();if(r!==e)return typeof r=="string"?r:r1(r,n)}else if(Array.isArray(e))return T9(e,n);return w9(e,n)}function x9(e){return typeof e.toJSON=="function"}function w9(e,t){const n=Object.entries(e);return n.length===0?"{}":t.length>DB?"["+E9(e)+"]":"{ "+n.map(([i,s])=>i+": "+r1(s,t)).join(", ")+" }"}function T9(e,t){if(e.length===0)return"[]";if(t.length>DB)return"[Array]";const n=Math.min(_9,e.length),r=e.length-n,i=[];for(let s=0;s<n;++s)i.push(r1(e[s],t));return r===1?i.push("... 1 more item"):r>1&&i.push(`... ${r} more items`),"["+i.join(", ")+"]"}function E9(e){const t=Object.prototype.toString.call(e).replace(/^\[object /,"").replace(/]$/,"");if(t==="Object"&&typeof e.constructor=="function"){const n=e.constructor.name;if(typeof n=="string"&&n!=="")return n}return t}function S9(e){return`"${e.replace(C9,k9)}"`}const C9=/[\x00-\x1f\x22\x5c\x7f-\x9f]/g;function k9(e){return A9[e.charCodeAt(0)]}const A9=["\\u0000","\\u0001","\\u0002","\\u0003","\\u0004","\\u0005","\\u0006","\\u0007","\\b","\\t","\\n","\\u000B","\\f","\\r","\\u000E","\\u000F","\\u0010","\\u0011","\\u0012","\\u0013","\\u0014","\\u0015","\\u0016","\\u0017","\\u0018","\\u0019","\\u001A","\\u001B","\\u001C","\\u001D","\\u001E","\\u001F","","",'\\"',"","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","\\\\","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","","\\u007F","\\u0080","\\u0081","\\u0082","\\u0083","\\u0084","\\u0085","\\u0086","\\u0087","\\u0088","\\u0089","\\u008A","\\u008B","\\u008C","\\u008D","\\u008E","\\u008F","\\u0090","\\u0091","\\u0092","\\u0093","\\u0094","\\u0095","\\u0096","\\u0097","\\u0098","\\u0099","\\u009A","\\u009B","\\u009C","\\u009D","\\u009E","\\u009F"],Mk=Object.freeze({});function ih(e,t,n=IB){const r=new Map;for(const R of Object.values(Ta))r.set(R,P9(t,R));let i,s=Array.isArray(e),c=[e],a=-1,m=[],g=e,x,T;const C=[],A=[];do{a++;const R=a===c.length,N=R&&m.length!==0;if(R){if(x=A.length===0?void 0:C[C.length-1],g=T,T=A.pop(),N)if(s){g=g.slice();let U=0;for(const[W,Q]of m){const Z=W-U;Q===null?(g.splice(Z,1),U++):g[Z]=Q}}else{g=Object.defineProperties({},Object.getOwnPropertyDescriptors(g));for(const[U,W]of m)g[U]=W}a=i.index,c=i.keys,m=i.edits,s=i.inArray,i=i.prev}else if(T){if(x=s?a:c[a],g=T[x],g==null)continue;C.push(x)}let j;if(!Array.isArray(g)){var P,D;TO(g)||f9(!1,`Invalid AST Node: ${v9(g)}.`);const U=R?(P=r.get(g.kind))===null||P===void 0?void 0:P.leave:(D=r.get(g.kind))===null||D===void 0?void 0:D.enter;if(j=U==null?void 0:U.call(t,g,x,T,C,A),j===Mk)break;if(j===!1){if(!R){C.pop();continue}}else if(j!==void 0&&(m.push([x,j]),!R))if(TO(j))g=j;else{C.pop();continue}}if(j===void 0&&N&&m.push([x,g]),R)C.pop();else{var B;i={inArray:s,index:a,keys:c,edits:m,prev:i},s=Array.isArray(g),c=s?g:(B=n[g.kind])!==null&&B!==void 0?B:[],a=-1,m=[],T&&A.push(T),T=g}}while(i!==void 0);return m.length!==0?m[m.length-1][1]:e}function P9(e,t){const n=e[t];return typeof n=="object"?n:typeof n=="function"?{enter:n,leave:void 0}:{enter:e.enter,leave:e.leave}}function LB(e){return ih(e,I9)}const M9=80,I9={Name:{leave:e=>e.value},Variable:{leave:e=>"$"+e.name},Document:{leave:e=>zn(e.definitions,`
14
15`)},OperationDefinition:{leave(e){const t=Rr("(",zn(e.variableDefinitions,", "),")"),n=zn([e.operation,zn([e.name,t]),zn(e.directives," ")]," ");return(n==="query"?"":n+" ")+e.selectionSet}},VariableDefinition:{leave:({variable:e,type:t,defaultValue:n,directives:r})=>e+": "+t+Rr(" = ",n)+Rr(" ",zn(r," "))},SelectionSet:{leave:({selections:e})=>bc(e)},Field:{leave({alias:e,name:t,arguments:n,directives:r,selectionSet:i}){const s=Rr("",e,": ")+t;let c=s+Rr("(",zn(n,", "),")");return c.length>M9&&(c=s+Rr(`(
16`,xb(zn(n,`
17`)),`
18)`)),zn([c,zn(r," "),i]," ")}},Argument:{leave:({name:e,value:t})=>e+": "+t},FragmentSpread:{leave:({name:e,directives:t})=>"..."+e+Rr(" ",zn(t," "))},InlineFragment:{leave:({typeCondition:e,directives:t,selectionSet:n})=>zn(["...",Rr("on ",e),zn(t," "),n]," ")},FragmentDefinition:{leave:({name:e,typeCondition:t,variableDefinitions:n,directives:r,selectionSet:i})=>`fragment ${e}${Rr("(",zn(n,", "),")")} on ${t} ${Rr("",zn(r," ")," ")}`+i},IntValue:{leave:({value:e})=>e},FloatValue:{leave:({value:e})=>e},StringValue:{leave:({value:e,block:t})=>t?y9(e):S9(e)},BooleanValue:{leave:({value:e})=>e?"true":"false"},NullValue:{leave:()=>"null"},EnumValue:{leave:({value:e})=>e},ListValue:{leave:({values:e})=>"["+zn(e,", ")+"]"}
18,ObjectValue:{leave:({fields:e})=>"{"+zn(e,", ")+"}"},ObjectField:{leave:({name:e,value:t})=>e+": "+t},Directive:{leave:({name:e,arguments:t})=>"@"+e+Rr("(",zn(t,", "),")")},NamedType:{leave:({name:e})=>e},ListType:{leave:({type:e})=>"["+e+"]"},NonNullType:{leave:({type:e})=>e+"!"},SchemaDefinition:{leave:({description:e,directives:t,operationTypes:n})=>Rr("",e,`
19`)+zn(["schema",zn(t," "),bc(n)]," ")},OperationTypeDefinition:{leave:({operation:e,type:t})=>e+": "+t},ScalarTypeDefinition:{leave:({description:e,name:t,directives:n})=>Rr("",e,`
20`)+zn(["scalar",t,zn(n," ")]," ")},ObjectTypeDefinition:{leave:({description:e,name:t,interfaces:n,directives:r,fields:i})=>Rr("",e,`
21`)+zn(["type",t,Rr("implements ",zn(n," & ")),zn(r," "),bc(i)]," ")},FieldDefinition:{leave:({description:e,name:t,arguments:n,type:r,directives:i})=>Rr("",e,`
22`)+t+(SO(n)?Rr(`(
23`,xb(zn(n,`
24`)),`
25)`):Rr("(",zn(n,", "),")"))+": "+r+Rr(" ",zn(i," "))},InputValueDefinition:{leave:({description:e,name:t,type:n,defaultValue:r,directives:i})=>Rr("",e,`
26`)+zn([t+": "+n,Rr("= ",r),zn(i," ")]," ")},InterfaceTypeDefinition:{leave:({description:e,name:t,interfaces:n,directives:r,fields:i})=>Rr("",e,`
27`)+zn(["interface",t,Rr("implements ",zn(n," & ")),zn(r," "),bc(i)]," ")},UnionTypeDefinition:{leave:({description:e,name:t,directives:n,types:r})=>Rr("",e,`
28`)+zn(["union",t,zn(n," "),Rr("= ",zn(r," | "))]," ")},EnumTypeDefinition:{leave:({description:e,name:t,directives:n,values:r})=>Rr("",e,`
29`)+zn(["enum",t,zn(n," "),bc(r)]," ")},EnumValueDefinition:{leave:({description:e,name:t,directives:n})=>Rr("",e,`
30`)+zn([t,zn(n," ")]," ")},InputObjectTypeDefinition:{leave:({description:e,name:t,directives:n,fields:r})=>Rr("",e,`
31`)+zn(["input",t,zn(n," "),bc(r)]," ")},DirectiveDefinition:{leave:({description:e,name:t,arguments:n,repeatable:r,locations:i})=>Rr("",e,`
32`)+"directive @"+t+(SO(n)?Rr(`(
33`,xb(zn(n,`
34`)),`
35)`):Rr("(",zn(n,", "),")"))+(r?" repeatable":"")+" on "+zn(i," | ")},SchemaExtension:{leave:({directives:e,operationTypes:t})=>zn(["extend schema",zn(e," "),bc(t)]," ")},ScalarTypeExtension:{leave:({name:e,directives:t})=>zn(["extend scalar",e,zn(t," ")]," ")},ObjectTypeExtension:{leave:({name:e,interfaces:t,directives:n,fields:r})=>zn(["extend type",e,Rr("implements ",zn(t," & ")),zn(n," "),bc(r)]," ")},InterfaceTypeExtension:{leave:({name:e,interfaces:t,directives:n,fields:r})=>zn(["extend interface",e,Rr("implements ",zn(t," & ")),zn(n," "),bc(r)]," ")},UnionTypeExtension:{leave:({name:e,directives:t,types:n})=>zn(["extend union",e,zn(t," "),Rr("= ",zn(n," | "))]," ")},EnumTypeExtension:{leave:({name:e,directives:t,values:n})=>zn(["extend enum",e,zn(t," "),bc(n)]," ")},InputObjectTypeExtension:{leave:({name:e,directives:t,fields:n})=>zn(["extend input",e,zn(t," "),bc(n)]," ")}};function zn(e,t=""){var n;return(n=e==null?void 0:e.filter(r=>r).join(t))!==null&&n!==void 0?n:""}function bc(e){return Rr(`{
36`,xb(zn(e,`
37`)),`
38}`)}function Rr(e,t,n=""){return t!=null&&t!==""?e+t+n:""}function xb(e){return Rr("  ",e.replace(/\n/g,`
39  `))}function SO(e){var t;return(t=e==null?void 0:e.some(n=>n.includes(`
40`)))!==null&&t!==void 0?t:!1}function CO(e){return e.kind===Ta.FIELD||e.kind===Ta.FRAGMENT_SPREAD||e.kind===Ta.INLINE_FRAGMENT}function Av(e,t){var n=e.directives;return!n||!n.length?!0:L9(n).every(function(r){var i=r.directive,s=r.ifArgument,c=!1;return s.value.kind==="Variable"?(c=t&&t[s.value.name.value],hr(c!==void 0,66,i.name.value)):c=s.value.value,i.name.value==="skip"?!c:c})}function N_(e,t,n){var r=new Set(e),i=r.size;return ih(t,{Directive:function(s){if(r.delete(s.name.value)&&(!n||!r.size))return Mk}}),n?!r.size:r.size<i}function O9(e){return e&&N_(["client","export"],e,!0)}function D9(e){var t=e.name.value;return t==="skip"||t==="include"}function L9(e){var t=[];return e&&e.length&&e.forEach(function(n){if(D9(n)){var r=n.arguments,i=n.name.value;hr(r&&r.length===1,67,i);var s=r[0];hr(s.name&&s.name.value==="if",68,i);var c=s.value;hr(c&&(c.kind==="Variable"||c.kind==="BooleanValue"),69,i),t.push({directive:n,ifArgument:s})}}),t}const R9=()=>Object.create(null),{forEach:F9,slice:B9}=Array.prototype,{hasOwnProperty:z9}=Object.prototype;class Ld{constructor(t=!0,n=R9){this.weakness=t,this.makeData=n}lookup(...t){return this.lookupArray(t)}lookupArray(t){let n=this;return F9.call(t,r=>n=n.getChildTrie(r)),z9.call(n,"data")?n.data:n.data=this.makeData(B9.call(t))}peek(...t){return this.peekArray(t)}peekArray(t){let n=this;for(let r=0,i=t.length;n&&r<i;++r){const s=this.weakness&&kO(t[r])?n.weak:n.strong;n=s&&s.get(t[r])}return n&&n.data}getChildTrie(t){const n=this.weakness&&kO(t)?this.weak||(this.weak=new WeakMap):this.strong||(this.strong=new Map);let r=n.get(t);return r||n.set(t,r=new Ld(this.weakness,this.makeData)),r}}function kO(e){switch(typeof e){case"object":if(e===null)break;case"function":return!0}return!1}var ch=typeof WeakMap=="function"&&wc(function(){return navigator.product})!=="ReactNative",RB=typeof WeakSet=="function",FB=typeof Symbol=="function"&&typeof Symbol.for=="function",i1=FB&&Symbol.asyncIterator;wc(function(){return window.document.createElement});wc(function(){return navigator.userAgent.indexOf("jsdom")>=0});function Xi(e){return e!==null&&typeof e=="object"}function N9(e,t){var n=t,r=[];e.definitions.forEach(function(s){if(s.kind==="OperationDefinition")throw vs(70,s.operation,s.name?" named '".concat(s.name.value,"'"):"");s.kind==="FragmentDefinition"&&r.push(s)}),typeof n>"u"&&(hr(r.length===1,71,r.length),n=r[0].name.value);var i=Lt(Lt({},e),{definitions:rp([{kind:"OperationDefinition",operation:"query",selectionSet:{kind:"SelectionSet",selections:[{kind:"FragmentSpread",name:{kind:"Name",value:n}}]}}],e.definitions,!0)});return i}function o1(e){e===void 0&&(e=[]);var t={};return e.forEach(function(n){t[n.name.value]=n}),t}function a1(e,t){switch(e.kind){case"InlineFragment":return e;case"FragmentSpread":{var n=e.name.value;if(typeof t=="function")return t(n);var r=t&&t[n];return hr(r,72,n),r||null}default:return null}}function Nm(e){return{__ref:String(e)}}function xi(e){return!!(e&&typeof e=="object"&&typeof e.__ref=="string")}function $9(e){return Xi(e)&&e.kind==="Document"&&Array.isArray(e.definitions)}function j9(e){return e.kind==="StringValue"}function U9(e){return e.kind==="BooleanValue"}function V9(e){return e.kind==="IntValue"}function G9(e){return e.kind==="FloatValue"}function q9(e){return e.kind==="Variable"}function W9(e){return e.kind==="ObjectValue"}function H9(e){return e.kind==="ListValue"}function Y9(e){return e.kind==="EnumValue"}
40function Z9(e){return e.kind==="NullValue"}function eg(e,t,n,r){if(V9(n)||G9(n))e[t.value]=Number(n.value);else if(U9(n)||j9(n))e[t.value]=n.value;else if(W9(n)){var i={};n.fields.map(function(c){return eg(i,c.name,c.value,r)}),e[t.value]=i}else if(q9(n)){var s=(r||{})[n.name.value];e[t.value]=s}else if(H9(n))e[t.value]=n.values.map(function(c){var a={};return eg(a,t,c,r),a[t.value]});else if(Y9(n))e[t.value]=n.value;else if(Z9(n))e[t.value]=null;else throw vs(81,t.value,n.kind)}function X9(e,t){var n=null;e.directives&&(n={},e.directives.forEach(function(i){n[i.name.value]={},i.arguments&&i.arguments.forEach(function(s){var c=s.name,a=s.value;return eg(n[i.name.value],c,a,t)})}));var r=null;return e.arguments&&e.arguments.length&&(r={},e.arguments.forEach(function(i){var s=i.name,c=i.value;return eg(r,s,c,t)})),Ik(e.name.value,r,n)}var K9=["connection","include","skip","client","rest","export","nonreactive"],Ik=Object.assign(function(e,t,n){if(t&&n&&n.connection&&n.connection.key)if(n.connection.filter&&n.connection.filter.length>0){var r=n.connection.filter?n.connection.filter:[];r.sort();var i={};return r.forEach(function(a){i[a]=t[a]}),"".concat(n.connection.key,"(").concat(zy(i),")")}else return n.connection.key;var s=e;if(t){var c=zy(t);s+="(".concat(c,")")}return n&&Object.keys(n).forEach(function(a){K9.indexOf(a)===-1&&(n[a]&&Object.keys(n[a]).length?s+="@".concat(a,"(").concat(zy(n[a]),")"):s+="@".concat(a))}),s},{setStringify:function(e){var t=zy;return zy=e,t}}),zy=function(t){return JSON.stringify(t,Q9)};function Q9(e,t){return Xi(t)&&!Array.isArray(t)&&(t=Object.keys(t).sort().reduce(function(n,r){return n[r]=t[r],n},{})),t}function s1(e,t){if(e.arguments&&e.arguments.length){var n={};return e.arguments.forEach(function(r){var i=r.name,s=r.value;return eg(n,i,s,t)}),n}return null}function Sd(e){return e.alias?e.alias.value:e.name.value}function pS(e,t,n){for(var r,i=0,s=t.selections;i<s.length;i++){var c=s[i];if(Cd(c)){if(c.name.value==="__typename")return e[Sd(c)]}else r?r.push(c):r=[c]}if(typeof e.__typename=="string")return e.__typename;if(r)for(var a=0,m=r;a<m.length;a++){var c=m[a],g=pS(e,a1(c,n).selectionSet,n);if(typeof g=="string")return g}}function Cd(e){return e.kind==="Field"}function J9(e){return e.kind==="InlineFragment"}function Pv(e){hr(e&&e.kind==="Document",73);var t=e.definitions.filter(function(n){return n.kind!=="FragmentDefinition"}).map(function(n){if(n.kind!=="OperationDefinition")throw vs(74,n.kind);return n});return hr(t.length<=1,75,t.length),e}function Mv(e){return Pv(e),e.definitions.filter(function(t){return t.kind==="OperationDefinition"})[0]}function mS(e){return e.definitions.filter(function(t){return t.kind==="OperationDefinition"&&!!t.name}).map(function(t){return t.name.value})[0]||null}function l1(e){return e.definitions.filter(function(t){return t.kind==="FragmentDefinition"})}function BB(e){var t=Mv(e);return hr(t&&t.operation==="query",76),t}function eY(e){hr(e.kind==="Document",77),hr(e.definitions.length<=1,78);var t=e.definitions[0];return hr(t.kind==="FragmentDefinition",79),t}function Cg(e){Pv(e);for(var t,n=0,r=e.definitions;n<r.length;n++){var i=r[n];if(i.kind==="OperationDefinition"){var s=i.operation;if(s==="query"||s==="mutation"||s==="subscription")return i}i.kind==="FragmentDefinition"&&!t&&(t=i)}if(t)return t;throw vs(80)}function Ok(e){var t=Object.create(null),n=e&&e.variableDefinitions;return n&&n.length&&n.forEach(function(r){r.defaultValue&&eg(t,r.variable.name,r.defaultValue)}),t}function tY(e){return e}var zB=function(){function e(t,n){n===void 0&&(n=Object.create(null)),this.resultCache=RB?new WeakSet:new Set,this.transform=t,n.getCacheKey&&(this.getCacheKey=n.getCacheKey),n.cache!==!1&&(this.stableCacheKeys=new Ld(ch,function(r){return{key:r}}))}return e.prototype.getCacheKey=function(t){return[t]},e.identity=function(){return new e(tY,{cache:!1})},e.split=function(t,n,r){return r===void 0&&(r=e.identity()),new e(function(i){var s=t(i)?n:r;return s.transformDocument(i)},{cache:!1})},e.prototype.transformDocument=function(t){if(this.resultCache.has(t))return t;var n=this.getStableCacheEntry(t);if(n&&n.value)return n.value;Pv(t);var r=this.transform(t);return this.resultCache.add(r),n&&(n.value=r),r},e.prototype.concat=function(t){var n=this;return new e(function(r){return t.transformDocument(n.transformDocument(r))},{cache:!1})},e.prototype.getStableCacheEntry=function(t){if(this.stableCacheKeys){var n=this.getCacheKey(t);if(n)return hr(Array.isArray(n),65),this.stableCacheKeys.lookupArray(n)}},e}(),pm=ch?new WeakMap:void 0,Dk=function(e){var t;return t=pm==null?void 0:pm.get(e),t||(t=LB(e),pm==null||pm.set(e,t)),t},Do=Array.isArray;function gu(e){return Array.isArray(e)&&e.length>0}var AO={kind:Ta.FIELD,name:{kind:Ta.NAME,value:"__typename"}};function NB(e,t){return!e||e.selectionSet.selections.every(function(n){return n.kind===Ta.FRAGMENT_SPREAD&&NB(t[n.name.value],t)})}function nY(e){return NB(Mv(e)||eY(e),o1(l1(e)))?null:e}function rY(e){var t=new Map,n=new Map;return e.forEach(function(r){r&&(r.name?t.set(r.name,r):r.test&&n.set(r.test,r))}),function(r){var i=t.get(r.name.value);
40return!i&&n.size&&n.forEach(function(s,c){c(r)&&(i=s)}),i}}function PO(e){var t=new Map;return function(r){r===void 0&&(r=e);var i=t.get(r);return i||t.set(r,i={variables:new Set,fragmentSpreads:new Set}),i}}function $B(e,t){Pv(t);for(var n=PO(""),r=PO(""),i=function(R){for(var N=0,j=void 0;N<R.length&&(j=R[N]);++N)if(!Do(j)){if(j.kind===Ta.OPERATION_DEFINITION)return n(j.name&&j.name.value);if(j.kind===Ta.FRAGMENT_DEFINITION)return r(j.name.value)}return globalThis.__DEV__!==!1&&hr.error(82),null},s=0,c=t.definitions.length-1;c>=0;--c)t.definitions[c].kind===Ta.OPERATION_DEFINITION&&++s;var a=rY(e),m=function(R){return gu(R)&&R.map(a).some(function(N){return N&&N.remove})},g=new Map,x=!1,T={enter:function(R){if(m(R.directives))return x=!0,null}},C=ih(t,{Field:T,InlineFragment:T,VariableDefinition:{enter:function(){return!1}},Variable:{enter:function(R,N,j,U,W){var Q=i(W);Q&&Q.variables.add(R.name.value)}},FragmentSpread:{enter:function(R,N,j,U,W){if(m(R.directives))return x=!0,null;var Q=i(W);Q&&Q.fragmentSpreads.add(R.name.value)}},FragmentDefinition:{enter:function(R,N,j,U){g.set(JSON.stringify(U),R)},leave:function(R,N,j,U){var W=g.get(JSON.stringify(U));if(R===W)return R;if(s>0&&R.selectionSet.selections.every(function(Q){return Q.kind===Ta.FIELD&&Q.name.value==="__typename"}))return r(R.name.value).removed=!0,x=!0,null}},Directive:{leave:function(R){if(a(R))return x=!0,null}}});if(!x)return t;var A=function(R){return R.transitiveVars||(R.transitiveVars=new Set(R.variables),R.removed||R.fragmentSpreads.forEach(function(N){A(r(N)).transitiveVars.forEach(function(j){R.transitiveVars.add(j)})})),R},P=new Set;C.definitions.forEach(function(R){R.kind===Ta.OPERATION_DEFINITION?A(n(R.name&&R.name.value)).fragmentSpreads.forEach(function(N){P.add(N)}):R.kind===Ta.FRAGMENT_DEFINITION&&s===0&&!r(R.name.value).removed&&P.add(R.name.value)}),P.forEach(function(R){A(r(R)).fragmentSpreads.forEach(function(N){P.add(N)})});var D=function(R){return!!(!P.has(R)||r(R).removed)},B={enter:function(R){if(D(R.name.value))return null}};return nY(ih(C,{FragmentSpread:B,FragmentDefinition:B,OperationDefinition:{leave:function(R){if(R.variableDefinitions){var N=A(n(R.name&&R.name.value)).transitiveVars;if(N.size<R.variableDefinitions.length)return Lt(Lt({},R),{variableDefinitions:R.variableDefinitions.filter(function(j){return N.has(j.variable.name.value)})})}}}}))}var Lk=Object.assign(function(e){return ih(e,{SelectionSet:{enter:function(t,n,r){if(!(r&&r.kind===Ta.OPERATION_DEFINITION)){var i=t.selections;if(i){var s=i.some(function(a){return Cd(a)&&(a.name.value==="__typename"||a.name.value.lastIndexOf("__",0)===0)});if(!s){var c=r;if(!(Cd(c)&&c.directives&&c.directives.some(function(a){return a.name.value==="export"})))return Lt(Lt({},t),{selections:rp(rp([],i,!0),[AO],!1)})}}}}}})},{added:function(e){return e===AO}});function iY(e){var t=Cg(e),n=t.operation;if(n==="query")return e;var r=ih(e,{OperationDefinition:{enter:function(i){return Lt(Lt({},i),{operation:"query"})}}});return r}function jB(e){Pv(e);var t=$B([{test:function(n){return n.name.value==="client"},remove:!0}],e);return t}var oY=Object.prototype.hasOwnProperty;function MO(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];return Rk(e)}function Rk(e){var t=e[0]||{},n=e.length;if(n>1)for(var r=new kd,i=1;i<n;++i)t=r.merge(t,e[i]);return t}var aY=function(e,t,n){return this.merge(e[n],t[n])},kd=function(){function e(t){t===void 0&&(t=aY),this.reconciler=t,this.isObject=Xi,this.pastCopies=new Set}return e.prototype.merge=function(t,n){for(var r=this,i=[],s=2;s<arguments.length;s++)i[s-2]=arguments[s];return Xi(n)&&Xi(t)?(Object.keys(n).forEach(function(c){if(oY.call(t,c)){var a=t[c];if(n[c]!==a){var m=r.reconciler.apply(r,rp([t,n,c],i,!1));m!==a&&(t=r.shallowCopyForMerge(t),t[c]=m)}}else t=r.shallowCopyForMerge(t),t[c]=n[c]}),t):n},e.prototype.shallowCopyForMerge=function(t){return Xi(t)&&(this.pastCopies.has(t)||(Array.isArray(t)?t=t.slice(0):t=Lt({__proto__:Object.getPrototypeOf(t)},t),this.pastCopies.add(t))),t},e}();function sY(e,t){var n=typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(n)return(n=n.call(e)).next.bind(n);if(Array.isArray(e)||(n=lY(e))||t&&e&&typeof e.length=="number"){n&&(e=n);var r=0;return function(){return r>=e.length?{done:!0}:{done:!1,value:e[r++]}}}throw new TypeError(`Invalid attempt to iterate non-iterable instance.
41In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function lY(e,t){if(e){if(typeof e=="string")return IO(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set")return Array.from(e);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return IO(e,t)}}function IO(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function OO(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}function Fk(e,t,n){return t&&OO(e.prototype,t),n&&OO(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}var Bk=function(){return typeof Symbol=="function"},zk=function(e){return Bk()&&!!Symbol[e]},Nk=function(e){return zk(e)?Symbol[e]:"@@"+e};
41Bk()&&!zk("observable")&&(Symbol.observable=Symbol("observable"));var cY=Nk("iterator"),gS=Nk("observable"),UB=Nk("species");function ix(e,t){var n=e[t];if(n!=null){if(typeof n!="function")throw new TypeError(n+" is not a function");return n}}function Ny(e){var t=e.constructor;return t!==void 0&&(t=t[UB],t===null&&(t=void 0)),t!==void 0?t:Oi}function uY(e){return e instanceof Oi}function tg(e){tg.log?tg.log(e):setTimeout(function(){throw e})}function wb(e){Promise.resolve().then(function(){try{e()}catch(t){tg(t)}})}function VB(e){var t=e._cleanup;if(t!==void 0&&(e._cleanup=void 0,!!t))try{if(typeof t=="function")t();else{var n=ix(t,"unsubscribe");n&&n.call(t)}}catch(r){tg(r)}}function yS(e){e._observer=void 0,e._queue=void 0,e._state="closed"}function hY(e){var t=e._queue;if(t){e._queue=void 0,e._state="ready";for(var n=0;n<t.length&&(GB(e,t[n].type,t[n].value),e._state!=="closed");++n);}}function GB(e,t,n){e._state="running";var r=e._observer;try{var i=ix(r,t);switch(t){case"next":i&&i.call(r,n);break;case"error":if(yS(e),i)i.call(r,n);else throw n;break;case"complete":yS(e),i&&i.call(r);break}}catch(s){tg(s)}e._state==="closed"?VB(e):e._state==="running"&&(e._state="ready")}function wT(e,t,n){if(e._state!=="closed"){if(e._state==="buffering"){e._queue.push({type:t,value:n});return}if(e._state!=="ready"){e._state="buffering",e._queue=[{type:t,value:n}],wb(function(){return hY(e)});return}GB(e,t,n)}}var dY=function(){function e(n,r){this._cleanup=void 0,this._observer=n,this._queue=void 0,this._state="initializing";var i=new fY(this);try{this._cleanup=r.call(void 0,i)}catch(s){i.error(s)}this._state==="initializing"&&(this._state="ready")}var t=e.prototype;return t.unsubscribe=function(){this._state!=="closed"&&(yS(this),VB(this))},Fk(e,[{key:"closed",get:function(){return this._state==="closed"}}]),e}(),fY=function(){function e(n){this._subscription=n}var t=e.prototype;return t.next=function(r){wT(this._subscription,"next",r)},t.error=function(r){wT(this._subscription,"error",r)},t.complete=function(){wT(this._subscription,"complete")},Fk(e,[{key:"closed",get:function(){return this._subscription._state==="closed"}}]),e}(),Oi=function(){function e(n){if(!(this instanceof e))throw new TypeError("Observable cannot be called as a function");if(typeof n!="function")throw new TypeError("Observable initializer must be a function");this._subscriber=n}var t=e.prototype;return t.subscribe=function(r){return(typeof r!="object"||r===null)&&(r={next:r,error:arguments[1],complete:arguments[2]}),new dY(r,this._subscriber)},t.forEach=function(r){var i=this;return new Promise(function(s,c){if(typeof r!="function"){c(new TypeError(r+" is not a function"));return}function a(){m.unsubscribe(),s()}var m=i.subscribe({next:function(g){try{r(g,a)}catch(x){c(x),m.unsubscribe()}},error:c,complete:s})})},t.map=function(r){var i=this;if(typeof r!="function")throw new TypeError(r+" is not a function");var s=Ny(this);return new s(function(c){return i.subscribe({next:function(a){try{a=r(a)}catch(m){return c.error(m)}c.next(a)},error:function(a){c.error(a)},complete:function(){c.complete()}})})},t.filter=function(r){var i=this;if(typeof r!="function")throw new TypeError(r+" is not a function");var s=Ny(this);return new s(function(c){return i.subscribe({next:function(a){try{if(!r(a))return}catch(m){return c.error(m)}c.next(a)},error:function(a){c.error(a)},complete:function(){c.complete()}})})},t.reduce=function(r){var i=this;if(typeof r!="function")throw new TypeError(r+" is not a function");var s=Ny(this),c=arguments.length>1,a=!1,m=arguments[1],g=m;return new s(function(x){return i.subscribe({next:function(T){var C=!a;if(a=!0,!C||c)try{g=r(g,T)}catch(A){return x.error(A)}else g=T},error:function(T){x.error(T)},complete:function(){if(!a&&!c)return x.error(new TypeError("Cannot reduce an empty sequence"));x.next(g),x.complete()}})})},t.concat=function(){for(var r=this,i=arguments.length,s=new Array(i),c=0;c<i;c++)s[c]=arguments[c];var a=Ny(this);return new a(function(m){var g,x=0;function T(C){g=C.subscribe({next:function(A){m.next(A)},error:function(A){m.error(A)},complete:function(){x===s.length?(g=void 0,m.complete()):T(a.from(s[x++]))}})}return T(r),function(){g&&(g.unsubscribe(),g=void 0)}})},t.flatMap=function(r){var i=this;if(typeof r!="function")throw new TypeError(r+" is not a function");var s=Ny(this);return new s(function(c){var a=[],m=i.subscribe({next:function(x){if(r)try{x=r(x)}catch(C){return c.error(C)}var T=s.from(x).subscribe({next:function(C){c.next(C)},error:function(C){c.error(C)},complete:function(){var C=a.indexOf(T);C>=0&&a.splice(C,1),g()}});a.push(T)},error:function(x){c.error(x)},complete:function(){g()}});
41function g(){m.closed&&a.length===0&&c.complete()}return function(){a.forEach(function(x){return x.unsubscribe()}),m.unsubscribe()}})},t[gS]=function(){return this},e.from=function(r){var i=typeof this=="function"?this:e;if(r==null)throw new TypeError(r+" is not an object");var s=ix(r,gS);if(s){var c=s.call(r);if(Object(c)!==c)throw new TypeError(c+" is not an object");return uY(c)&&c.constructor===i?c:new i(function(a){return c.subscribe(a)})}if(zk("iterator")&&(s=ix(r,cY),s))return new i(function(a){wb(function(){if(!a.closed){for(var m=sY(s.call(r)),g;!(g=m()).done;){var x=g.value;if(a.next(x),a.closed)return}a.complete()}})});if(Array.isArray(r))return new i(function(a){wb(function(){if(!a.closed){for(var m=0;m<r.length;++m)if(a.next(r[m]),a.closed)return;a.complete()}})});throw new TypeError(r+" is not observable")},e.of=function(){for(var r=arguments.length,i=new Array(r),s=0;s<r;s++)i[s]=arguments[s];var c=typeof this=="function"?this:e;return new c(function(a){wb(function(){if(!a.closed){for(var m=0;m<i.length;++m)if(a.next(i[m]),a.closed)return;a.complete()}})})},Fk(e,null,[{key:UB,get:function(){return this}}]),e}();Bk()&&Object.defineProperty(Oi,Symbol("extensions"),{value:{symbol:gS,hostReportError:tg},configurable:!0});function pY(e){var t,n=e.Symbol;if(typeof n=="function")if(n.observable)t=n.observable;else{typeof n.for=="function"?t=n.for("https://github.com/benlesh/symbol-observable"):t=n("https://github.com/benlesh/symbol-observable");try{n.observable=t}catch{}}else t="@@observable";return t}var Tm;typeof self<"u"?Tm=self:typeof window<"u"?Tm=window:typeof global<"u"?Tm=global:typeof module<"u"?Tm=module:Tm=Function("return this")();pY(Tm);var DO=Oi.prototype,LO="@@observable";DO[LO]||(DO[LO]=function(){return this});var mY=Object.prototype.toString;function qB(e){return _S(e)}function _S(e,t){switch(mY.call(e)){case"[object Array]":{if(t=t||new Map,t.has(e))return t.get(e);var n=e.slice(0);return t.set(e,n),n.forEach(function(i,s){n[s]=_S(i,t)}),n}case"[object Object]":{if(t=t||new Map,t.has(e))return t.get(e);var r=Object.create(Object.getPrototypeOf(e));return t.set(e,r),Object.keys(e).forEach(function(i){r[i]=_S(e[i],t)}),r}default:return e}}function gY(e){var t=new Set([e]);return t.forEach(function(n){Xi(n)&&yY(n)===n&&Object.getOwnPropertyNames(n).forEach(function(r){Xi(n[r])&&t.add(n[r])})}),e}function yY(e){if(globalThis.__DEV__!==!1&&!Object.isFrozen(e))try{Object.freeze(e)}catch(t){if(t instanceof TypeError)return null;throw t}return e}function vS(e){return globalThis.__DEV__!==!1&&gY(e),e}function v_(e,t,n){var r=[];e.forEach(function(i){return i[t]&&r.push(i)}),r.forEach(function(i){return i[t](n)})}function TT(e,t,n){return new Oi(function(r){var i={then:function(m){return new Promise(function(g){return g(m())})}};function s(m,g){return function(x){if(m){var T=function(){return r.closed?0:m(x)};i=i.then(T,T).then(function(C){return r.next(C)},function(C){return r.error(C)})}else r[g](x)}}var c={next:s(t,"next"),error:s(n,"error"),complete:function(){i.then(function(){return r.complete()})}},a=e.subscribe(c);return function(){return a.unsubscribe()}})}function WB(e){function t(n){Object.defineProperty(e,n,{value:Oi})}return FB&&Symbol.species&&t(Symbol.species),t("@@species"),e}function RO(e){return e&&typeof e.then=="function"}var Em=function(e){Kl(t,e);function t(n){var r=e.call(this,function(i){return r.addObserver(i),function(){return r.removeObserver(i)}})||this;return r.observers=new Set,r.promise=new Promise(function(i,s){r.resolve=i,r.reject=s}),r.handlers={next:function(i){r.sub!==null&&(r.latest=["next",i],r.notify("next",i),v_(r.observers,"next",i))},error:function(i){var s=r.sub;s!==null&&(s&&setTimeout(function(){return s.unsubscribe()}),r.sub=null,r.latest=["error",i],r.reject(i),r.notify("error",i),v_(r.observers,"error",i))},complete:function(){var i=r,s=i.sub,c=i.sources,a=c===void 0?[]:c;if(s!==null){var m=a.shift();m?RO(m)?m.then(function(g){return r.sub=g.subscribe(r.handlers)}):r.sub=m.subscribe(r.handlers):(s&&setTimeout(function(){return s.unsubscribe()}),r.sub=null,r.latest&&r.latest[0]==="next"?r.resolve(r.latest[1]):r.resolve(),r.notify("complete"),v_(r.observers,"complete"))}}},r.nextResultListeners=new Set,r.cancel=function(i){r.reject(i),r.sources=[],r.handlers.complete()},r.promise.catch(function(i){}),typeof n=="function"&&(n=[new Oi(n)]),RO(n)?n.then(function(i){return r.start(i)},r.handlers.error):r.start(n),r}return t.prototype.start=function(n){this.sub===void 0&&(this.sources=Array.from(n),this.handlers.complete())},t.prototype.deliverLastMessage=function(n){if(this.latest){var r=this.latest[0],i=n[r];i&&i.call(n,this.latest[1]),this.sub===null&&r==="next"&&n.complete&&n.complete()}},t.prototype.addObserver=function(n){this.observers.has(n)||(this.deliverLastMessage(n),this.observers.add(n))},t.prototype.removeObserver=function(n){this.observers.delete(n)&&this.observers.size<1&&this.handlers.complete()},t.prototype.notify=function(n,r){var i=this.nextResultListeners;
41i.size&&(this.nextResultListeners=new Set,i.forEach(function(s){return s(n,r)}))},t.prototype.beforeNext=function(n){var r=!1;this.nextResultListeners.add(function(i,s){r||(r=!0,n(i,s))})},t}(Oi);WB(Em);function $m(e){return"incremental"in e}function _Y(e){return"hasNext"in e&&"data"in e}function vY(e){return $m(e)||_Y(e)}function bY(e){return Xi(e)&&"payload"in e}function HB(e,t){var n=e,r=new kd;return $m(t)&&gu(t.incremental)&&t.incremental.forEach(function(i){for(var s=i.data,c=i.path,a=c.length-1;a>=0;--a){var m=c[a],g=!isNaN(+m),x=g?[]:{};x[m]=s,s=x}n=r.merge(n,s)}),n}function Tb(e){var t=bS(e);return gu(t)}function bS(e){var t=gu(e.errors)?e.errors.slice(0):[];return $m(e)&&gu(e.incremental)&&e.incremental.forEach(function(n){n.errors&&t.push.apply(t,n.errors)}),t}function ng(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];var n=Object.create(null);return e.forEach(function(r){r&&Object.keys(r).forEach(function(i){var s=r[i];s!==void 0&&(n[i]=s)})}),n}function ET(e,t){return ng(e,t,t.variables&&{variables:ng(Lt(Lt({},e&&e.variables),t.variables))})}function ST(e){return new Oi(function(t){t.error(e)})}var xS=function(e,t,n){var r=new Error(n);throw r.name="ServerError",r.response=e,r.statusCode=e.status,r.result=t,r};function xY(e){for(var t=["query","operationName","variables","extensions","context"],n=0,r=Object.keys(e);n<r.length;n++){var i=r[n];if(t.indexOf(i)<0)throw vs(43,i)}return e}function wY(e,t){var n=Lt({},e),r=function(s){typeof s=="function"?n=Lt(Lt({},n),s(n)):n=Lt(Lt({},n),s)},i=function(){return Lt({},n)};return Object.defineProperty(t,"setContext",{enumerable:!1,value:r}),Object.defineProperty(t,"getContext",{enumerable:!1,value:i}),t}function TY(e){var t={variables:e.variables||{},extensions:e.extensions||{},operationName:e.operationName,query:e.query};return t.operationName||(t.operationName=typeof t.query!="string"?mS(t.query)||void 0:""),t}function EY(e,t){var n=Lt({},e),r=new Set(Object.keys(e));return ih(t,{Variable:function(i,s,c){c&&c.kind!=="VariableDefinition"&&r.delete(i.name.value)}}),r.forEach(function(i){delete n[i]}),n}function FO(e,t){return t?t(e):Oi.of()}function $y(e){return typeof e=="function"?new Oc(e):e}function nb(e){return e.request.length<=1}var Oc=function(){function e(t){t&&(this.request=t)}return e.empty=function(){return new e(function(){return Oi.of()})},e.from=function(t){return t.length===0?e.empty():t.map($y).reduce(function(n,r){return n.concat(r)})},e.split=function(t,n,r){var i=$y(n),s=$y(r||new e(FO));return nb(i)&&nb(s)?new e(function(c){return t(c)?i.request(c)||Oi.of():s.request(c)||Oi.of()}):new e(function(c,a){return t(c)?i.request(c,a)||Oi.of():s.request(c,a)||Oi.of()})},e.execute=function(t,n){return t.request(wY(n.context,TY(xY(n))))||Oi.of()},e.concat=function(t,n){var r=$y(t);if(nb(r))return globalThis.__DEV__!==!1&&hr.warn(35,r),r;var i=$y(n);return nb(i)?new e(function(s){return r.request(s,function(c){return i.request(c)||Oi.of()})||Oi.of()}):new e(function(s,c){return r.request(s,function(a){return i.request(a,c)||Oi.of()})||Oi.of()})},e.prototype.split=function(t,n,r){return this.concat(e.split(t,n,r||new e(FO)))},e.prototype.concat=function(t){return e.concat(this,t)},e.prototype.request=function(t,n){throw vs(36)},e.prototype.onError=function(t,n){if(n&&n.error)return n.error(t),!1;throw t},e.prototype.setOnError=function(t){return this.onError=t,this},e}(),SY=Oc.split,wS=Oc.execute;function YB(e){return new Oc(function(t,n){return new Oi(function(r){var i,s,c;try{i=n(t).subscribe({next:function(a){if(a.errors&&(c=e({graphQLErrors:a.errors,response:a,operation:t,forward:n}),c)){s=c.subscribe({next:r.next.bind(r),error:r.error.bind(r),complete:r.complete.bind(r)});return}r.next(a)},error:function(a){if(c=e({operation:t,networkError:a,graphQLErrors:a&&a.result&&a.result.errors,forward:n}),c){s=c.subscribe({next:r.next.bind(r),error:r.error.bind(r),complete:r.complete.bind(r)});return}r.error(a)},complete:function(){c||r.complete.bind(r)()}})}catch(a){e({networkError:a,operation:t,forward:n}),r.error(a)}return function(){i&&i.unsubscribe(),s&&i.unsubscribe()}})})}(function(e){Kl(t,e);function t(n){var r=e.call(this)||this;return r.link=YB(n),r}return t.prototype.request=function(n,r){return this.link.request(n,r)},t})(Oc);function CY(e){var t,n=e[Symbol.asyncIterator]();return t={next:function(){return n.next()}},t[Symbol.asyncIterator]=function(){return this},t}function kY(e){var t=null,n=null,r=!1,i=[],s=[];
41function c(T){if(!n){if(s.length){var C=s.shift();if(Array.isArray(C)&&C[0])return C[0]({value:T,done:!1})}i.push(T)}}function a(T){n=T;var C=s.slice();C.forEach(function(A){A[1](T)}),!t||t()}function m(){r=!0;var T=s.slice();T.forEach(function(C){C[0]({value:void 0,done:!0})}),!t||t()}t=function(){t=null,e.removeListener("data",c),e.removeListener("error",a),e.removeListener("end",m),e.removeListener("finish",m),e.removeListener("close",m)},e.on("data",c),e.on("error",a),e.on("end",m),e.on("finish",m),e.on("close",m);function g(){return new Promise(function(T,C){if(n)return C(n);if(i.length)return T({value:i.shift(),done:!1});if(r)return T({value:void 0,done:!0});s.push([T,C])})}var x={next:function(){return g()}};return i1&&(x[Symbol.asyncIterator]=function(){return this}),x}function AY(e){var t=!1,n={next:function(){return t?Promise.resolve({value:void 0,done:!0}):(t=!0,new Promise(function(r,i){e.then(function(s){r({value:s,done:!1})}).catch(i)}))}};return i1&&(n[Symbol.asyncIterator]=function(){return this}),n}function BO(e){var t={next:function(){return e.read()}};return i1&&(t[Symbol.asyncIterator]=function(){return this}),t}function PY(e){return!!e.body}function MY(e){return!!e.getReader}function IY(e){return!!(i1&&e[Symbol.asyncIterator])}function OY(e){return!!e.stream}function DY(e){return!!e.arrayBuffer}function LY(e){return!!e.pipe}function RY(e){var t=e;if(PY(e)&&(t=e.body),IY(t))return CY(t);if(MY(t))return BO(t.getReader());if(OY(t))return BO(t.stream().getReader());if(DY(t))return AY(t.arrayBuffer());if(LY(t))return kY(t);throw new Error("Unknown body type for responseIterator. Please pass a streamable response.")}var $k=Symbol();function FY(e){return e.extensions?Array.isArray(e.extensions[$k]):!1}function BY(e){return e.hasOwnProperty("graphQLErrors")}var zY=function(e){var t=rp(rp(rp([],e.graphQLErrors,!0),e.clientErrors,!0),e.protocolErrors,!0);return e.networkError&&t.push(e.networkError),t.map(function(n){return Xi(n)&&n.message||"Error message not found."}).join(`
42`)},Nf=function(e){Kl(t,e);function t(n){var r=n.graphQLErrors,i=n.protocolErrors,s=n.clientErrors,c=n.networkError,a=n.errorMessage,m=n.extraInfo,g=e.call(this,a)||this;return g.name="ApolloError",g.graphQLErrors=r||[],g.protocolErrors=i||[],g.clientErrors=s||[],g.networkError=c||null,g.message=a||zY(g),g.extraInfo=m,g.__proto__=t.prototype,g}return t}(Error),zO=Object.prototype.hasOwnProperty;function NY(e,t){var n;return Qh(this,void 0,void 0,function(){var r,i,s,c,a,m,g,x,T,C,A,P,D,B,R,N,j,U,W,Q,Z,K,Y;return Jh(this,function(me){switch(me.label){case 0:if(TextDecoder===void 0)throw new Error("TextDecoder must be defined in the environment: please import a polyfill.");r=new TextDecoder("utf-8"),i=(n=e.headers)===null||n===void 0?void 0:n.get("content-type"),s="boundary=",c=i!=null&&i.includes(s)?i==null?void 0:i.substring((i==null?void 0:i.indexOf(s))+s.length).replace(/['"]/g,"").replace(/\;(.*)/gm,"").trim():"-",a=`\r
43--`.concat(c),m="",g=RY(e),x=!0,me.label=1;case 1:return x?[4,g.next()]:[3,3];case 2:for(T=me.sent(),C=T.value,A=T.done,P=typeof C=="string"?C:r.decode(C),D=m.length-a.length+1,x=!A,m+=P,B=m.indexOf(a,D);B>-1;){if(R=void 0,K=[m.slice(0,B),m.slice(B+a.length)],R=K[0],m=K[1],N=R.indexOf(`\r
44\r
45`),j=$Y(R.slice(0,N)),U=j["content-type"],U&&U.toLowerCase().indexOf("application/json")===-1)throw new Error("Unsupported patch content type: application/json is required.");if(W=R.slice(N),W){if(Q=ZB(e,W),Object.keys(Q).length>1||"data"in Q||"incremental"in Q||"errors"in Q||"payload"in Q)bY(Q)?(Z={},"payload"in Q&&(Z=Lt({},Q.payload)),"errors"in Q&&(Z=Lt(Lt({},Z),{extensions:Lt(Lt({},"extensions"in Z?Z.extensions:null),(Y={},Y[$k]=Q.errors,Y))})),t(Z)):t(Q);else if(Object.keys(Q).length===1&&"hasNext"in Q&&!Q.hasNext)return[2]}B=m.indexOf(a)}return[3,1];case 3:return[2]}})})}function $Y(e){var t={};return e.split(`
46`).forEach(function(n){var r=n.indexOf(":");if(r>-1){var i=n.slice(0,r).trim().toLowerCase(),s=n.slice(r+1).trim();t[i]=s}}),t}function ZB(e,t){if(e.status>=300){var n=function(){try{return JSON.parse(t)}catch{return t}};xS(e,n(),"Response not successful: Received status code ".concat(e.status))}try{return JSON.parse(t)}catch(i){var r=i;throw r.name="ServerParseError",r.response=e,r.statusCode=e.status,r.bodyText=t,r}}function jY(e,t){e.result&&e.result.errors&&e.result.data&&t.next(e.result),t.error(e)}function UY(e){return function(t){return t.text().then(function(n){return ZB(t,n)}).then(function(n){return t.status>=300&&xS(t,n,"Response not successful: Received status code ".concat(t.status)),!Array.isArray(n)&&!zO.call(n,"data")&&!zO.call(n,"errors")&&xS(t,n,"Server response was missing for query '".concat(Array.isArray(e)?e.map(function(r){return r.operationName}):e.operationName,"'.")),n})}}var TS=function(e,t){var n;try{n=JSON.stringify(e)}catch(i){var r=vs(39,t,i.message);throw r.parseError=i,r}return n},VY={includeQuery:!0,includeExtensions:!1,preserveHeaderCase:!1},GY={accept:"*/*","content-type":"application/json"},qY={method:"POST"}
46,WY={http:VY,headers:GY,options:qY},HY=function(e,t){return t(e)};function YY(e,t){for(var n=[],r=2;r<arguments.length;r++)n[r-2]=arguments[r];var i={},s={};n.forEach(function(T){i=Lt(Lt(Lt({},i),T.options),{headers:Lt(Lt({},i.headers),T.headers)}),T.credentials&&(i.credentials=T.credentials),s=Lt(Lt({},s),T.http)}),i.headers&&(i.headers=ZY(i.headers,s.preserveHeaderCase));var c=e.operationName,a=e.extensions,m=e.variables,g=e.query,x={operationName:c,variables:m};return s.includeExtensions&&(x.extensions=a),s.includeQuery&&(x.query=t(g,Dk)),{options:i,body:x}}function ZY(e,t){if(!t){var n=Object.create(null);return Object.keys(Object(e)).forEach(function(s){n[s.toLowerCase()]=e[s]}),n}var r=Object.create(null);Object.keys(Object(e)).forEach(function(s){r[s.toLowerCase()]={originalName:s,value:e[s]}});var i=Object.create(null);return Object.keys(r).forEach(function(s){i[r[s].originalName]=r[s].value}),i}var XY=function(e){if(!e&&typeof fetch>"u")throw vs(37)},KY=function(e,t){var n=e.getContext(),r=n.uri;return r||(typeof t=="function"?t(e):t||"/graphql")};function QY(e,t){var n=[],r=function(T,C){n.push("".concat(T,"=").concat(encodeURIComponent(C)))};if("query"in t&&r("query",t.query),t.operationName&&r("operationName",t.operationName),t.variables){var i=void 0;try{i=TS(t.variables,"Variables map")}catch(T){return{parseError:T}}r("variables",i)}if(t.extensions){var s=void 0;try{s=TS(t.extensions,"Extensions map")}catch(T){return{parseError:T}}r("extensions",s)}var c="",a=e,m=e.indexOf("#");m!==-1&&(c=e.substr(m),a=e.substr(0,m));var g=a.indexOf("?")===-1?"?":"&",x=a+g+n.join("&")+c;return{newURI:x}}var NO=wc(function(){return fetch}),XB=function(e){e===void 0&&(e={});var t=e.uri,n=t===void 0?"/graphql":t,r=e.fetch,i=e.print,s=i===void 0?HY:i,c=e.includeExtensions,a=e.preserveHeaderCase,m=e.useGETForQueries,g=e.includeUnusedVariables,x=g===void 0?!1:g,T=rh(e,["uri","fetch","print","includeExtensions","preserveHeaderCase","useGETForQueries","includeUnusedVariables"]);globalThis.__DEV__!==!1&&XY(r||NO);var C={http:{includeExtensions:c,preserveHeaderCase:a},options:T.fetchOptions,credentials:T.credentials,headers:T.headers};return new Oc(function(A){var P=KY(A,n),D=A.getContext(),B={};if(D.clientAwareness){var R=D.clientAwareness,N=R.name,j=R.version;N&&(B["apollographql-client-name"]=N),j&&(B["apollographql-client-version"]=j)}var U=Lt(Lt({},B),D.headers),W={http:D.http,options:D.fetchOptions,credentials:D.credentials,headers:U};if(N_(["client"],A.query)){var Q=jB(A.query);if(!Q)return ST(new Error("HttpLink: Trying to send a client-only query to the server. To send to the server, ensure a non-client field is added to the query or set the `transformOptions.removeClientFields` option to `true`."));A.query=Q}var Z=YY(A,s,WY,C,W),K=Z.options,Y=Z.body;Y.variables&&!x&&(Y.variables=EY(Y.variables,A.query));var me;!K.signal&&typeof AbortController<"u"&&(me=new AbortController,K.signal=me.signal);var ge=function(le){return le.kind==="OperationDefinition"&&le.operation==="mutation"},ce=function(le){return le.kind==="OperationDefinition"&&le.operation==="subscription"},fe=ce(Cg(A.query)),ie=N_(["defer"],A.query);if(m&&!A.query.definitions.some(ge)&&(K.method="GET"),ie||fe){K.headers=K.headers||{};var xe="multipart/mixed;";fe&&ie&&globalThis.__DEV__!==!1&&hr.warn(38),fe?xe+="boundary=graphql;subscriptionSpec=1.0,application/json":ie&&(xe+="deferSpec=20220824,application/json"),K.headers.accept=xe}if(K.method==="GET"){var Te=QY(P,Y),oe=Te.newURI,ne=Te.parseError;if(ne)return ST(ne);P=oe}else try{K.body=TS(Y,"Payload")}catch(le){return ST(le)}return new Oi(function(le){var se=r||wc(function(){return fetch})||NO,Ne=le.next.bind(le);return se(P,K).then(function(Se){var xt;A.setContext({response:Se});var kt=(xt=Se.headers)===null||xt===void 0?void 0:xt.get("content-type");return kt!==null&&/^multipart\/mixed/i.test(kt)?NY(Se,Ne):UY(A)(Se).then(Ne)}).then(function(){me=void 0,le.complete()}).catch(function(Se){me=void 0,jY(Se,le)}),function(){me&&me.abort()}})})},JY=function(e){Kl(t,e);function t(n){n===void 0&&(n={});var r=e.call(this,XB(n).request)||this;return r.options=n,r}return t}(Oc);const{toString:$O,hasOwnProperty:eZ}=Object.prototype,jO=Function.prototype.toString,ES=new Map;function To(e,t){try{return SS(e,t)}finally{ES.clear()}}function SS(e,t){if(e===t)return!0;const n=$O.call(e),r=$O.call(t);if(n!==r)return!1;switch(n){case"[object Array]":if(e.length!==t.length)return!1;case"[object Object]":{if(VO(e,t))return!0;const i=UO(e),s=UO(t),c=i.length;if(c!==s.length)return!1;for(let a=0;a<c;++a)if(!eZ.call(t,i[a]))return!1;for(let a=0;a<c;++a){const m=i[a];if(!SS(e[m],t[m]))return!1}return!0}case"[object Error]":return e.name===t.name&&e.message===t.message;case"[object Number]":if(e!==e)return t!==t;case"[object Boolean]":case"[object Date]":return+e==+t;case"[object RegExp]":case"[object String]":return e==`${t}`;case"[object Map]":case"[object Set]":{if(e.size!==t.size)return!1;if(VO(e,t))return!0;const i=e.entries(),s=n==="[object Map]";for(;;){const c=i.next();if(c.done)break;const[a,m]=c.value;if(!t.has(a)||s&&!SS(m,t.get(a)))return!1}return!0}case"[object Uint16Array]":case"[object Uint8Array]":case"[object Uint32Array]":case"[object Int32Array]":case"[object Int8Array]":case"[object Int16Array]":case"[object ArrayBuffer]":e=new Uint8Array(e),t=new Uint8Array(t);case"[object DataView]":{let i=e.byteLength;if(i===t.byteLength)for(;i--&&e[i]===t[i];);return i===-1}case"[object AsyncFunction]":case"[object GeneratorFunction]":case"[object AsyncGeneratorFunction]":case"[object Function]":{const i=jO.call(e);return i!==jO.call(t)?!1:!rZ(i,nZ)}}return!1}function UO(e){return Object.keys(e).filter(tZ,e)}function tZ(e){return this[e]!==void 0}const nZ="{ [native code] }";function rZ(e,t){const n=e.length-t.length;return n>=0&&e.indexOf(t,n)===n}function VO(e,t){let n=ES.get(e);if(n){if(n.has(t))return!0}else ES.set(e,n=new Set);return n.add(t),!1}function iZ(){}class oZ{constructor(t=1/0,n=iZ){this.max=t,this.dispose=n,this.map=new Map,this.newest=null,this.oldest=null}has(t){return this.map.has(t)}get(t){const n=this.getNode(t);return n&&n.value}getNode(t){const n=this.map.get(t);if(n&&n!==this.newest){const{older:r,newer:i}=n;i&&(i.older=r),r&&(r.newer=i),n.older=this.newest,n.older.newer=n,n.newer=null,this.newest=n,n===this.oldest&&(this.oldest=i)}return n}set(t,n){let r=this.getNode(t);return r?r.value=n:(r={key:t,value:n,newer:null,older:this.newest},this.newest&&(this.newest.newer=r),this.newest=r,this.oldest=this.oldest||r,this.map.set(t,r),r.value)}clean(){for(;this.oldest&&this.map.size>this.max;)this.delete(this.oldest.key)}delete(t){const n=this.map.get(t);return n?(n===this.newest&&(this.newest=n.older),n===this.oldest&&(this.oldest=n.newer),n.newer&&(n.newer.older=n.older),n.older&&(n.older.newer=n.newer),this.map.delete(t),this.dispose(n.value,t),!0):!1}}let Da=null;const GO={};let aZ=1;const sZ=()=>class{constructor(){this.id=["slot",aZ++,Date.now(),Math.random().toString(36).slice(2)].join(":")}hasValue(){for(let t=Da;t;t=t.parent)if(this.id in t.slots){const n=t.slots[this.id];if(n===GO)break;return t!==Da&&(Da.slots[this.id]=n),!0}return Da&&(Da.slots[this.id]=GO),!1}getValue(){if(this.hasValue())return Da.slots[this.id]}withValue(t,n,r,i){const s={__proto__:null,[this.id]:t},c=Da;Da={parent:c,slots:s};try{return n.apply(i,r)}finally{Da=c}}static bind(t){const n=Da;return function(){const r=Da;try{return Da=n,t.apply(this,arguments)}finally{Da=r}}}static noContext(t,n,r){if(Da){const i=Da;try{return Da=null,t.apply(r,n)}finally{Da=i}}else return t.apply(r,n)}};function qO(e){try{return e()}catch{}}const CT="@wry/context:Slot",lZ=qO(()=>globalThis)||qO(()=>global)||Object.create(null),WO=lZ,KB=WO[CT]||Array[CT]||function(e){try{Object.defineProperty(WO,CT,{value:e,enumerable:!1,writable:!1,
46configurable:!0})}finally{return e}}(sZ()),c1=new KB,{hasOwnProperty:cZ}=Object.prototype,jk=Array.from||function(e){const t=[];return e.forEach(n=>t.push(n)),t};function ox(e){const{unsubscribe:t}=e;typeof t=="function"&&(e.unsubscribe=void 0,t())}const $_=[],uZ=100;function rg(e,t){if(!e)throw new Error(t||"assertion failure")}function hZ(e,t){const n=e.length;return n>0&&n===t.length&&e[n-1]===t[n-1]}function QB(e){switch(e.length){case 0:throw new Error("unknown value");case 1:return e[0];case 2:throw e[1]}}function dZ(e){return e.slice(0)}class u1{constructor(t){this.fn=t,this.parents=new Set,this.childValues=new Map,this.dirtyChildren=null,this.dirty=!0,this.recomputing=!1,this.value=[],this.deps=null,++u1.count}peek(){if(this.value.length===1&&!Ad(this))return HO(this),this.value[0]}recompute(t){return rg(!this.recomputing,"already recomputing"),HO(this),Ad(this)?fZ(this,t):QB(this.value)}setDirty(){this.dirty||(this.dirty=!0,this.value.length=0,JB(this),ox(this))}dispose(){this.setDirty(),iz(this),Uk(this,(t,n)=>{t.setDirty(),oz(t,this)})}forget(){this.dispose()}dependOn(t){t.add(this),this.deps||(this.deps=$_.pop()||new Set),this.deps.add(t)}forgetDeps(){this.deps&&(jk(this.deps).forEach(t=>t.delete(this)),this.deps.clear(),$_.push(this.deps),this.deps=null)}}u1.count=0;function HO(e){const t=c1.getValue();if(t)return e.parents.add(t),t.childValues.has(e)||t.childValues.set(e,[]),Ad(e)?tz(t,e):nz(t,e),t}function fZ(e,t){return iz(e),c1.withValue(e,pZ,[e,t]),gZ(e,t)&&mZ(e),QB(e.value)}function pZ(e,t){e.recomputing=!0,e.value.length=0;try{e.value[0]=e.fn.apply(null,t)}catch(n){e.value[1]=n}e.recomputing=!1}function Ad(e){return e.dirty||!!(e.dirtyChildren&&e.dirtyChildren.size)}function mZ(e){e.dirty=!1,!Ad(e)&&ez(e)}function JB(e){Uk(e,tz)}function ez(e){Uk(e,nz)}function Uk(e,t){const n=e.parents.size;if(n){const r=jk(e.parents);for(let i=0;i<n;++i)t(r[i],e)}}function tz(e,t){rg(e.childValues.has(t)),rg(Ad(t));const n=!Ad(e);if(!e.dirtyChildren)e.dirtyChildren=$_.pop()||new Set;else if(e.dirtyChildren.has(t))return;e.dirtyChildren.add(t),n&&JB(e)}function nz(e,t){rg(e.childValues.has(t)),rg(!Ad(t));const n=e.childValues.get(t);n.length===0?e.childValues.set(t,dZ(t.value)):hZ(n,t.value)||e.setDirty(),rz(e,t),!Ad(e)&&ez(e)}function rz(e,t){const n=e.dirtyChildren;n&&(n.delete(t),n.size===0&&($_.length<uZ&&$_.push(n),e.dirtyChildren=null))}function iz(e){e.childValues.size>0&&e.childValues.forEach((t,n)=>{oz(e,n)}),e.forgetDeps(),rg(e.dirtyChildren===null)}function oz(e,t){t.parents.delete(e),e.childValues.delete(t),rz(e,t)}function gZ(e,t){if(typeof e.subscribe=="function")try{ox(e),e.unsubscribe=e.subscribe.apply(null,t)}catch{return e.setDirty(),!1}return!0}const yZ={setDirty:!0,dispose:!0,forget:!0};function az(e){const t=new Map,n=e&&e.subscribe;function r(i){const s=c1.getValue();if(s){let c=t.get(i);c||t.set(i,c=new Set),s.dependOn(c),typeof n=="function"&&(ox(c),c.unsubscribe=n(i))}}return r.dirty=function(s,c){const a=t.get(s);if(a){const m=c&&cZ.call(yZ,c)?c:"setDirty";jk(a).forEach(g=>g[m]()),t.delete(s),ox(a)}},r}let YO;function _Z(...e){return(YO||(YO=new Ld(typeof WeakMap=="function"))).lookupArray(e)}const kT=new Set;function ax(e,{max:t=Math.pow(2,16),makeCacheKey:n=_Z,keyArgs:r,subscribe:i}=Object.create(null)){const s=new oZ(t,x=>x.dispose()),c=function(){const x=n.apply(null,r?r.apply(null,arguments):arguments);if(x===void 0)return e.apply(null,arguments);let T=s.get(x);T||(s.set(x,T=new u1(e)),T.subscribe=i,T.forget=()=>s.delete(x));const C=T.recompute(Array.prototype.slice.call(arguments));return s.set(x,T),kT.add(s),c1.hasValue()||(kT.forEach(A=>A.clean()),kT.clear()),C};Object.defineProperty(c,"size",{get(){return s.map.size},configurable:!1,enumerable:!1}),Object.freeze(c.options={max:t,makeCacheKey:n,keyArgs:r,subscribe:i});function a(x){const T=s.get(x);T&&T.setDirty()}c.dirtyKey=a,c.dirty=function(){a(n.apply(null,arguments))};function m(x){const T=s.get(x);if(T)return T.peek()}c.peekKey=m,c.peek=function(){return m(n.apply(null,arguments))};function g(x){return s.delete(x)}return c.forgetKey=g,c.forget=function(){return g(n.apply(null,arguments))},c.makeCacheKey=n,c.getKey=r?function(){return n.apply(null,r.apply(null,arguments))}:n,Object.freeze(c)}var vZ=function(){function e(){this.assumeImmutableResults=!1,this.getFragmentDoc=ax(N9)}return e.prototype.batch=function(t){var n=this,r=typeof t.optimistic=="string"?t.optimistic:t.optimistic===!1?null:void 0,i;return this.performTransaction(function(){return i=t.update(n)},r),i},e.prototype.recordOptimisticTransaction=function(t,n){this.performTransaction(t,n)},e.prototype.transformDocument=function(t){return t},e.prototype.transformForLink=function(t){return t},e.prototype.identify=function(t){},e.prototype.gc=function(){return[]},e.prototype.modify=function(t){return!1},e.prototype.readQuery=function(t,n){return n===void 0&&(n=!!t.optimistic),this.read(Lt(Lt({},t),{rootId:t.id||"ROOT_QUERY",optimistic:n}))},e.prototype.readFragment=function(t,n){return n===void 0&&(n=!!t.optimistic),this.read(Lt(Lt({},t),{query:this.getFragmentDoc(t.fragment,t.fragmentName),rootId:t.id,optimistic:n}))},e.prototype.writeQuery=function(t){var n=t.id,r=t.data,i=rh(t,["id","data"]);return this.write(Object.assign(i,{dataId:n||"ROOT_QUERY",result:r}))},e.prototype.writeFragment=function(t){var n=t.id,r=t.data,i=t.fragment,s=t.fragmentName,c=rh(t,["id","data","fragment","fragmentName"]);return this.write(Object.assign(c,{query:this.getFragmentDoc(i,s),dataId:n,result:r}))},e.prototype.updateQuery=function(t,n){return this.batch({update:function(r){var i=r.readQuery(t),s=n(i);return s==null?i:(r.writeQuery(Lt(Lt({},t),{data:s})),s)}})},e.prototype.updateFragment=function(t,n){return this.batch({update:function(r){var i=r.readFragment(t),s=n(i);return s==null?i:(r.writeFragment(Lt(Lt({},t),{data:s})),s)}})},e}(),sz=function(e){Kl(t,e);function t(n,r,i,s){var c,a=e.call(this,n)||this;if(a.message=n,a.path=r,a.query=i,a.variables=s,Array.isArray(a.path)){a.missing=a.message;for(var m=a.path.length-1;m>=0;--m)a.missing=(c={},c[a.path[m]]=a.missing,c)}else a.missing=a.path;return a.__proto__=t.prototype,a}return t}(Error),xa=Object.prototype.hasOwnProperty;function jy(e){return e==null}function lz(e,t){var n=e.__typename,r=e.id,i=e._id;if(typeof n=="string"&&(t&&(t.keyObject=jy(r)?jy(i)?void 0:{_id:i}:{id:r}),jy(r)&&!jy(i)&&(r=i),!jy(r)))return"".concat(n,":").concat(typeof r=="number"||typeof r=="string"?r:JSON.stringify(r))}var cz={dataIdFromObject:lz,addTypename:!0,resultCaching:!0,canonizeResults:!1};function bZ(e){return ng(cz,e)}function uz(e){var t=e.canonizeResults;return t===void 0?cz.canonizeResults:t}function xZ(e,t){return xi(t)?e.get(t.__ref,"__typename"):t&&t.__typename}var hz=/^[_a-z][_0-9a-z]*/i;function Pd(e){var t=e.match(hz);return t?t[0]:e}function CS(e,t,n){return Xi(t)?Do(t)?t.every(function(r){return CS(e,r,n)}):e.selections.every(function(r){if(Cd(r)&&Av(r,n)){var i=Sd(r);return xa.call(t,i)&&(!r.selectionSet||CS(r.selectionSet,t[i],n))}return!0}):!1}function Am(e){return Xi(e)&&!xi(e)&&!Do(e)}function wZ(){return new kd}function dz(e,t){var n=o1(l1(e));return{fragmentMap:n,lookupFragment:function(r){var i=n[r];return!i&&t&&(i=t.lookup(r)),i||null}}}var Eb=Object.create(null),AT=function(){return Eb},ZO=Object.create(null),j_=function(){function e(t,n){var r=this;this.policies=t,this.group=n,this.data=Object.create(null),this.rootIds=Object.create(null),this.refs=Object.create(null),this.getFieldValue=function(i,s){return vS(xi(i)?r.get(i.__ref,s):i&&i[s])},this.canRead=function(i){return xi(i)?r.has(i.__ref):typeof i=="object"},this.toReference=function(i,s){if(typeof i=="string")return Nm(i);if(xi(i))return i;var c=r.policies.identify(i)[0];if(c){var a=Nm(c);return s&&r.merge(c,i),a}}}return e.prototype.toObject=function(){return Lt({},this.data)},e.prototype.has=function(t){return this.lookup(t,!0)!==void 0},e.prototype.get=function(t,n){if(this.group.depend(t,n),xa.call(this.data,t)){var r=this.data[t];if(r&&xa.call(r,n))return r[n]}if(n==="__typename"&&xa.call(this.policies.rootTypenamesById,t))return this.policies.rootTypenamesById[t];if(this instanceof Zh)return this.parent.get(t,n)},e.prototype.lookup=function(t,n){if(n&&this.group.depend(t,"__exists"),xa.call(this.data,t))return this.data[t];if(this instanceof Zh)return this.parent.lookup(t,n);if(this.policies.rootTypenamesById[t])return Object.create(null)},e.prototype.merge=function(t,n){var r=this,i;xi(t)&&(t=t.__ref),xi(n)&&(n=n.__ref);var s=typeof t=="string"?this.lookup(i=t):t,c=typeof n=="string"?this.lookup(i=n):n;
46if(c){hr(typeof i=="string",1);var a=new kd(EZ).merge(s,c);if(this.data[i]=a,a!==s&&(delete this.refs[i],this.group.caching)){var m=Object.create(null);s||(m.__exists=1),Object.keys(c).forEach(function(g){if(!s||s[g]!==a[g]){m[g]=1;var x=Pd(g);x!==g&&!r.policies.hasKeyArgs(a.__typename,x)&&(m[x]=1),a[g]===void 0&&!(r instanceof Zh)&&delete a[g]}}),m.__typename&&!(s&&s.__typename)&&this.policies.rootTypenamesById[i]===a.__typename&&delete m.__typename,Object.keys(m).forEach(function(g){return r.group.dirty(i,g)})}}},e.prototype.modify=function(t,n){var r=this,i=this.lookup(t);if(i){var s=Object.create(null),c=!1,a=!0,m={DELETE:Eb,INVALIDATE:ZO,isReference:xi,toReference:this.toReference,canRead:this.canRead,readField:function(g,x){return r.policies.readField(typeof g=="string"?{fieldName:g,from:x||Nm(t)}:g,{store:r})}};if(Object.keys(i).forEach(function(g){var x=Pd(g),T=i[g];if(T!==void 0){var C=typeof n=="function"?n:n[g]||n[x];if(C){var A=C===AT?Eb:C(vS(T),Lt(Lt({},m),{fieldName:x,storeFieldName:g,storage:r.getStorage(t,g)}));if(A===ZO)r.group.dirty(t,g);else if(A===Eb&&(A=void 0),A!==T&&(s[g]=A,c=!0,T=A,globalThis.__DEV__!==!1)){var P=function(W){if(r.lookup(W.__ref)===void 0)return globalThis.__DEV__!==!1&&hr.warn(2,W),!0};if(xi(A))P(A);else if(Array.isArray(A))for(var D=!1,B=void 0,R=0,N=A;R<N.length;R++){var j=N[R];if(xi(j)){if(D=!0,P(j))break}else if(typeof j=="object"&&j){var U=r.policies.identify(j)[0];U&&(B=j)}if(D&&B!==void 0){globalThis.__DEV__!==!1&&hr.warn(3,B);break}}}}T!==void 0&&(a=!1)}}),c)return this.merge(t,s),a&&(this instanceof Zh?this.data[t]=void 0:delete this.data[t],this.group.dirty(t,"__exists")),!0}return!1},e.prototype.delete=function(t,n,r){var i,s=this.lookup(t);if(s){var c=this.getFieldValue(s,"__typename"),a=n&&r?this.policies.getStoreFieldName({typename:c,fieldName:n,args:r}):n;return this.modify(t,a?(i={},i[a]=AT,i):AT)}return!1},e.prototype.evict=function(t,n){var r=!1;return t.id&&(xa.call(this.data,t.id)&&(r=this.delete(t.id,t.fieldName,t.args)),this instanceof Zh&&this!==n&&(r=this.parent.evict(t,n)||r),(t.fieldName||r)&&this.group.dirty(t.id,t.fieldName||"__exists")),r},e.prototype.clear=function(){this.replace(null)},e.prototype.extract=function(){var t=this,n=this.toObject(),r=[];return this.getRootIdSet().forEach(function(i){xa.call(t.policies.rootTypenamesById,i)||r.push(i)}),r.length&&(n.__META={extraRootIds:r.sort()}),n},e.prototype.replace=function(t){var n=this;if(Object.keys(this.data).forEach(function(s){t&&xa.call(t,s)||n.delete(s)}),t){var r=t.__META,i=rh(t,["__META"]);
46Object.keys(i).forEach(function(s){n.merge(s,i[s])}),r&&r.extraRootIds.forEach(this.retain,this)}},e.prototype.retain=function(t){return this.rootIds[t]=(this.rootIds[t]||0)+1},e.prototype.release=function(t){if(this.rootIds[t]>0){var n=--this.rootIds[t];return n||delete this.rootIds[t],n}return 0},e.prototype.getRootIdSet=function(t){return t===void 0&&(t=new Set),Object.keys(this.rootIds).forEach(t.add,t),this instanceof Zh?this.parent.getRootIdSet(t):Object.keys(this.policies.rootTypenamesById).forEach(t.add,t),t},e.prototype.gc=function(){var t=this,n=this.getRootIdSet(),r=this.toObject();n.forEach(function(c){xa.call(r,c)&&(Object.keys(t.findChildRefIds(c)).forEach(n.add,n),delete r[c])});var i=Object.keys(r);if(i.length){for(var s=this;s instanceof Zh;)s=s.parent;i.forEach(function(c){return s.delete(c)})}return i},e.prototype.findChildRefIds=function(t){if(!xa.call(this.refs,t)){var n=this.refs[t]=Object.create(null),r=this.data[t];if(!r)return n;var i=new Set([r]);i.forEach(function(s){xi(s)&&(n[s.__ref]=!0),Xi(s)&&Object.keys(s).forEach(function(c){var a=s[c];Xi(a)&&i.add(a)})})}return this.refs[t]},e.prototype.makeCacheKey=function(){return this.group.keyMaker.lookupArray(arguments)},e}(),fz=function(){function e(t,n){n===void 0&&(n=null),this.caching=t,this.parent=n,this.d=null,this.resetCaching()}return e.prototype.resetCaching=function(){this.d=this.caching?az():null,this.keyMaker=new Ld(ch)}
46,e.prototype.depend=function(t,n){if(this.d){this.d(PT(t,n));var r=Pd(n);r!==n&&this.d(PT(t,r)),this.parent&&this.parent.depend(t,n)}},e.prototype.dirty=function(t,n){this.d&&this.d.dirty(PT(t,n),n==="__exists"?"forget":"setDirty")},e}();function PT(e,t){return t+"#"+e}function XO(e,t){b_(e)&&e.group.depend(t,"__exists")}(function(e){var t=function(n){Kl(r,n);function r(i){var s=i.policies,c=i.resultCaching,a=c===void 0?!0:c,m=i.seed,g=n.call(this,s,new fz(a))||this;return g.stump=new TZ(g),g.storageTrie=new Ld(ch),m&&g.replace(m),g}return r.prototype.addLayer=function(i,s){return this.stump.addLayer(i,s)},r.prototype.removeLayer=function(){return this},r.prototype.getStorage=function(){return this.storageTrie.lookupArray(arguments)},r}(e);e.Root=t})(j_||(j_={}));var Zh=function(e){Kl(t,e);function t(n,r,i,s){var c=e.call(this,r.policies,s)||this;return c.id=n,c.parent=r,c.replay=i,c.group=s,i(c),c}return t.prototype.addLayer=function(n,r){return new t(n,this,r,this.group)},t.prototype.removeLayer=function(n){var r=this,i=this.parent.removeLayer(n);return n===this.id?(this.group.caching&&Object.keys(this.data).forEach(function(s){var c=r.data[s],a=i.lookup(s);a?c?c!==a&&Object.keys(c).forEach(function(m){To(c[m],a[m])||r.group.dirty(s,m)}):(r.group.dirty(s,"__exists"),Object.keys(a).forEach(function(m){r.group.dirty(s,m)})):r.delete(s)}),i):i===this.parent?this:i.addLayer(this.id,this.replay)},t.prototype.toObject=function(){return Lt(Lt({},this.parent.toObject()),this.data)},t.prototype.findChildRefIds=function(n){var r=this.parent.findChildRefIds(n);return xa.call(this.data,n)?Lt(Lt({},r),e.prototype.findChildRefIds.call(this,n)):r},t.prototype.getStorage=function(){for(var n=this.parent;n.parent;)n=n.parent;return n.getStorage.apply(n,arguments)},t}(j_),TZ=function(e){Kl(t,e);function t(n){return e.call(this,"EntityStore.Stump",n,function(){},new fz(n.group.caching,n.group))||this}return t.prototype.removeLayer=function(){return this},t.prototype.merge=function(){return this.parent.merge.apply(this.parent,arguments)},t}(Zh);function EZ(e,t,n){var r=e[n],i=t[n];return To(r,i)?r:i}function b_(e){return!!(e instanceof j_&&e.group.caching)}function SZ(e){return Xi(e)?Do(e)?e.slice(0):Lt({__proto__:Object.getPrototypeOf(e)},e):e}var kS=function(){function e(){this.known=new(RB?WeakSet:Set),this.pool=new Ld(ch),this.passes=new WeakMap,this.keysByJSON=new Map,this.empty=this.admit({})}return e.prototype.isKnown=function(t){return Xi(t)&&this.known.has(t)},e.prototype.pass=function(t){if(Xi(t)){var n=SZ(t);return this.passes.set(n,t),n}return t},e.prototype.admit=function(t){var n=this;if(Xi(t)){var r=this.passes.get(t);if(r)return r;var i=Object.getPrototypeOf(t);switch(i){case Array.prototype:{if(this.known.has(t))return t;var s=t.map(this.admit,this),c=this.pool.lookupArray(s);return c.array||(this.known.add(c.array=s),globalThis.__DEV__!==!1&&Object.freeze(s)),c.array}case null:case Object.prototype:{if(this.known.has(t))return t;var a=Object.getPrototypeOf(t),m=[a],g=this.sortedKeys(t);m.push(g.json);var x=m.length;g.sorted.forEach(function(A){m.push(n.admit(t[A]))});var c=this.pool.lookupArray(m);if(!c.object){var T=c.object=Object.create(a);this.known.add(T),g.sorted.forEach(function(A,P){T[A]=m[x+P]}),globalThis.__DEV__!==!1&&Object.freeze(T)}return c.object}}}return t},e.prototype.sortedKeys=function(t){var n=Object.keys(t),r=this.pool.lookupArray(n);if(!r.keys){n.sort();var i=JSON.stringify(n);(r.keys=this.keysByJSON.get(i))||this.keysByJSON.set(i,r.keys={sorted:n,json:i})}return r.keys},e}(),ip=Object.assign(function(e){if(Xi(e)){AS===void 0&&KO();var t=AS.admit(e),n=PS.get(t);return n===void 0&&PS.set(t,n=JSON.stringify(t)),n}return JSON.stringify(e)},{reset:KO}),AS,PS;function KO(){AS=new kS,PS=new(ch?WeakMap:Map)}function QO(e){return[e.selectionSet,e.objectOrReference,e.context,e.context.canonizeResults]}var CZ=function(){function e(t){var n=this;this.knownResults=new(ch?WeakMap:Map),this.config=ng(t,{addTypename:t.addTypename!==!1,canonizeResults:uz(t)}),this.canon=t.canon||new kS,this.executeSelectionSet=ax(function(r){var i,s=r.context.canonizeResults,c=QO(r);c[3]=!s;var a=(i=n.executeSelectionSet).peek.apply(i,c);return a?s?Lt(Lt({},a),{result:n.canon.admit(a.result)}):a:(XO(r.context.store,r.enclosingRef.__ref),n.execSelectionSetImpl(r))},{max:this.config.resultCacheMaxSize,keyArgs:QO,makeCacheKey:function(r,i,s,c){if(b_(s.store))return s.store.makeCacheKey(r,xi(i)?i.__ref:i,s.varString,c)}}),this.executeSubSelectedArray=ax(function(r){return XO(r.context.store,r.enclosingRef.__ref),n.execSubSelectedArrayImpl(r)},{max:this.config.resultCacheMaxSize,makeCacheKey:function(r){var i=r.field,s=r.array,c=r.context;if(b_(c.store))return c.store.makeCacheKey(i,s,c.varString)}})}return e.prototype.resetCanon=function(){this.canon=new kS},e.prototype.diffQueryAgainstStore=function(t){var n=t.store,r=t.query,i=t.rootId,s=i===void 0?"ROOT_QUERY":i,c=t.variables,a=t.returnPartialData,m=a===void 0?!0:a,g=t.canonizeResults,x=g===void 0?this.config.canonizeResults:g,T=this.config.cache.policies;c=Lt(Lt({},Ok(BB(r))),c);var C=Nm(s),A=this.executeSelectionSet({selectionSet:Cg(r).selectionSet,objectOrReference:C,enclosingRef:C,context:Lt({store:n,query:r,policies:T,variables:c,varString:ip(c),canonizeResults:x},dz(r,this.config.fragments))}),P;if(A.missing&&(P=[new sz(kZ(A.missing),A.missing,r,c)],!m))throw P[0];return{result:A.result,complete:!P,missing:P}},e.prototype.isFresh=function(t,n,r,i){if(b_(i.store)&&this.knownResults.get(t)===r){var s=this.executeSelectionSet.peek(r,n,i,this.canon.isKnown(t));if(s&&t===s.result)return!0}return!1},e.prototype.execSelectionSetImpl=function(t){var n=this,r=t.selectionSet,i=t.objectOrReference,s=t.enclosingRef,c=t.context;if(xi(i)&&!c.policies.rootTypenamesById[i.__ref]&&!c.store.has(i.__ref))return{result:this.canon.empty,missing:"Dangling reference to missing ".concat(i.__ref," object")};var a=c.variables,m=c.policies,g=c.store,x=g.getFieldValue(i,"__typename"),T=[],C,A=new kd;
46this.config.addTypename&&typeof x=="string"&&!m.rootIdsByTypename[x]&&T.push({__typename:x});function P(j,U){var W;return j.missing&&(C=A.merge(C,(W={},W[U]=j.missing,W))),j.result}var D=new Set(r.selections);D.forEach(function(j){var U,W;if(Av(j,a))if(Cd(j)){var Q=m.readField({fieldName:j.name.value,field:j,variables:c.variables,from:i},c),Z=Sd(j);Q===void 0?Lk.added(j)||(C=A.merge(C,(U={},U[Z]="Can't find field '".concat(j.name.value,"' on ").concat(xi(i)?i.__ref+" object":"object "+JSON.stringify(i,null,2)),U))):Do(Q)?Q=P(n.executeSubSelectedArray({field:j,array:Q,enclosingRef:s,context:c}),Z):j.selectionSet?Q!=null&&(Q=P(n.executeSelectionSet({selectionSet:j.selectionSet,objectOrReference:Q,enclosingRef:xi(Q)?Q:s,context:c}),Z)):c.canonizeResults&&(Q=n.canon.pass(Q)),Q!==void 0&&T.push((W={},W[Z]=Q,W))}else{var K=a1(j,c.lookupFragment);if(!K&&j.kind===Ta.FRAGMENT_SPREAD)throw vs(9,j.name.value);K&&m.fragmentMatches(K,x)&&K.selectionSet.selections.forEach(D.add,D)}});var B=Rk(T),R={result:B,missing:C},N=c.canonizeResults?this.canon.admit(R):vS(R);return N.result&&this.knownResults.set(N.result,r),N},e.prototype.execSubSelectedArrayImpl=function(t){var n=this,r=t.field,i=t.array,s=t.enclosingRef,c=t.context,a,m=new kd;function g(x,T){var C;return x.missing&&(a=m.merge(a,(C={},C[T]=x.missing,C))),x.result}return r.selectionSet&&(i=i.filter(c.store.canRead)),i=i.map(function(x,T){return x===null?null:Do(x)?g(n.executeSubSelectedArray({field:r,array:x,enclosingRef:s,context:c}),T):r.selectionSet?g(n.executeSelectionSet({selectionSet:r.selectionSet,objectOrReference:x,enclosingRef:xi(x)?x:s,context:c}),T):(globalThis.__DEV__!==!1&&AZ(c.store,r,x),x)}),{result:c.canonizeResults?this.canon.admit(i):i,missing:a}},e}();function kZ(e){try{JSON.stringify(e,function(t,n){if(typeof n=="string")throw n;return n})}catch(t){return t}}function AZ(e,t,n){if(!t.selectionSet){var r=new Set([n]);r.forEach(function(i){Xi(i)&&(hr(!xi(i),10,xZ(e,i),t.name.value),Object.values(i).forEach(r.add,r))})}}var Vk=new KB,JO=new WeakMap;function x_(e){var t=JO.get(e);return t||JO.set(e,t={vars:new Set,dep:az()}),t}function eD(e){x_(e).vars.forEach(function(t){return t.forgetCache(e)})}function PZ(e){x_(e).vars.forEach(function(t){return t.attachCache(e)})}function MZ(e){var t=new Set,n=new Set,r=function(s){if(arguments.length>0){if(e!==s){e=s,t.forEach(function(m){x_(m).dep.dirty(r),IZ(m)});var c=Array.from(n);n.clear(),c.forEach(function(m){return m(e)})}}else{var a=Vk.getValue();a&&(i(a),x_(a).dep(r))}return e};r.onNextChange=function(s){return n.add(s),function(){n.delete(s)}};var i=r.attachCache=function(s){return t.add(s),x_(s).vars.add(r),r};return r.forgetCache=function(s){return t.delete(s)},r}function IZ(e){e.broadcastWatches&&e.broadcastWatches()}var tD=Object.create(null);function Gk(e){var t=JSON.stringify(e);return tD[t]||(tD[t]=Object.create(null))}function nD(e){var t=Gk(e);return t.keyFieldsFn||(t.keyFieldsFn=function(n,r){var i=function(c,a){return r.readField(a,c)},s=r.keyObject=qk(e,function(c){var a=jm(r.storeObject,c,i);return a===void 0&&n!==r.storeObject&&xa.call(n,c[0])&&(a=jm(n,c,mz)),hr(a!==void 0,4,c.join("."),n),a});return"".concat(r.typename,":").concat(JSON.stringify(s))})}function rD(e){var t=Gk(e);return t.keyArgsFn||(t.keyArgsFn=function(n,r){var i=r.field,s=r.variables,c=r.fieldName,a=qk(e,function(g){var x=g[0],T=x.charAt(0);if(T==="@"){if(i&&gu(i.directives)){var C=x.slice(1),A=i.directives.find(function(R){return R.name.value===C}),P=A&&s1(A,s);return P&&jm(P,g.slice(1))}return}if(T==="$"){var D=x.slice(1);if(s&&xa.call(s,D)){var B=g.slice(0);return B[0]=D,jm(s,B)}return}if(n)return jm(n,g)}),m=JSON.stringify(a);return(n||m!=="{}")&&(c+=":"+m),c})}function qk(e,t){var n=new kd;return pz(e).reduce(function(r,i){var s,c=t(i);if(c!==void 0){for(var a=i.length-1;a>=0;--a)c=(s={},s[i[a]]=c,s);r=n.merge(r,c)}return r},Object.create(null))}function pz(e){var t=Gk(e);if(!t.paths){var n=t.paths=[],r=[];e.forEach(function(i,s){Do(i)?(pz(i).forEach(function(c){return n.push(r.concat(c))}),r.length=0):(r.push(i),Do(e[s+1])||(n.push(r.slice(0)),r.length=0))})}return t.paths}function mz(e,t){return e[t]}function jm(e,t,n){return n=n||mz,gz(t.reduce(function r(i,s){return Do(i)?i.map(function(c){return r(c,s)}):i&&n(i,s)},e))}function gz(e){return Xi(e)?Do(e)?e.map(gz):qk(Object.keys(e).sort(),function(t){return jm(e,t)}):e}Ik.setStringify(ip);
46function MS(e){return e.args!==void 0?e.args:e.field?s1(e.field,e.variables):null}var OZ=function(){},iD=function(e,t){return t.fieldName},oD=function(e,t,n){var r=n.mergeObjects;return r(e,t)},aD=function(e,t){return t},DZ=function(){function e(t){this.config=t,this.typePolicies=Object.create(null),this.toBeAdded=Object.create(null),this.supertypeMap=new Map,this.fuzzySubtypes=new Map,this.rootIdsByTypename=Object.create(null),this.rootTypenamesById=Object.create(null),this.usingPossibleTypes=!1,this.config=Lt({dataIdFromObject:lz},t),this.cache=this.config.cache,this.setRootTypename("Query"),this.setRootTypename("Mutation"),this.setRootTypename("Subscription"),t.possibleTypes&&this.addPossibleTypes(t.possibleTypes),t.typePolicies&&this.addTypePolicies(t.typePolicies)}return e.prototype.identify=function(t,n){var r,i=this,s=n&&(n.typename||((r=n.storeObject)===null||r===void 0?void 0:r.__typename))||t.__typename;if(s===this.rootTypenamesById.ROOT_QUERY)return["ROOT_QUERY"];for(var c=n&&n.storeObject||t,a=Lt(Lt({},n),{typename:s,storeObject:c,readField:n&&n.readField||function(){var C=Wk(arguments,c);return i.readField(C,{store:i.cache.data,variables:C.variables})}}),m,g=s&&this.getTypePolicy(s),x=g&&g.keyFn||this.config.dataIdFromObject;x;){var T=x(Lt(Lt({},t),c),a);if(Do(T))x=nD(T);else{m=T;break}}return m=m?String(m):void 0,a.keyObject?[m,a.keyObject]:[m]},e.prototype.addTypePolicies=function(t){var n=this;Object.keys(t).forEach(function(r){var i=t[r],s=i.queryType,c=i.mutationType,a=i.subscriptionType,m=rh(i,["queryType","mutationType","subscriptionType"]);s&&n.setRootTypename("Query",r),c&&n.setRootTypename("Mutation",r),a&&n.setRootTypename("Subscription",r),xa.call(n.toBeAdded,r)?n.toBeAdded[r].push(m):n.toBeAdded[r]=[m]})},e.prototype.updateTypePolicy=function(t,n){var r=this,i=this.getTypePolicy(t),s=n.keyFields,c=n.fields;function a(m,g){m.merge=typeof g=="function"?g:g===!0?oD:g===!1?aD:m.merge}a(i,n.merge),i.keyFn=s===!1?OZ:Do(s)?nD(s):typeof s=="function"?s:i.keyFn,c&&Object.keys(c).forEach(function(m){var g=r.getFieldPolicy(t,m,!0),x=c[m];if(typeof x=="function")g.read=x;else{var T=x.keyArgs,C=x.read,A=x.merge;g.keyFn=T===!1?iD:Do(T)?rD(T):typeof T=="function"?T:g.keyFn,typeof C=="function"&&(g.read=C),a(g,A)}g.read&&g.merge&&(g.keyFn=g.keyFn||iD)})},e.prototype.setRootTypename=function(t,n){n===void 0&&(n=t);var r="ROOT_"+t.toUpperCase(),i=this.rootTypenamesById[r];n!==i&&(hr(!i||i===t,5,t),i&&delete this.rootIdsByTypename[i],this.rootIdsByTypename[n]=r,this.rootTypenamesById[r]=n)},e.prototype.addPossibleTypes=function(t){var n=this;this.usingPossibleTypes=!0,Object.keys(t).forEach(function(r){n.getSupertypeSet(r,!0),t[r].forEach(function(i){n.getSupertypeSet(i,!0).add(r);var s=i.match(hz);(!s||s[0]!==i)&&n.fuzzySubtypes.set(i,new RegExp(i))})})},e.prototype.getTypePolicy=function(t){var n=this;if(!xa.call(this.typePolicies,t)){var r=this.typePolicies[t]=Object.create(null);r.fields=Object.create(null);var i=this.supertypeMap.get(t);!i&&this.fuzzySubtypes.size&&(i=this.getSupertypeSet(t,!0),this.fuzzySubtypes.forEach(function(c,a){if(c.test(t)){var m=n.supertypeMap.get(a);m&&m.forEach(function(g){return i.add(g)})}})),i&&i.size&&i.forEach(function(c){var a=n.getTypePolicy(c),m=a.fields,g=rh(a,["fields"]);Object.assign(r,g),Object.assign(r.fields,m)})}var s=this.toBeAdded[t];return s&&s.length&&s.splice(0).forEach(function(c){n.updateTypePolicy(t,c)}),this.typePolicies[t]},e.prototype.getFieldPolicy=function(t,n,r){if(t){var i=this.getTypePolicy(t).fields;return i[n]||r&&(i[n]=Object.create(null))}},e.prototype.getSupertypeSet=function(t,n){var r=this.supertypeMap.get(t);return!r&&n&&this.supertypeMap.set(t,r=new Set),r},e.prototype.fragmentMatches=function(t,n,r,i){var s=this;if(!t.typeCondition)return!0;if(!n)return!1;var c=t.typeCondition.name.value;if(n===c)return!0;if(this.usingPossibleTypes&&this.supertypeMap.has(c))for(var a=this.getSupertypeSet(n,!0),m=[a],g=function(P){var D=s.getSupertypeSet(P,!1);D&&D.size&&m.indexOf(D)<0&&m.push(D)},x=!!(r&&this.fuzzySubtypes.size),T=!1,C=0;C<m.length;++C){var A=m[C];if(A.has(c))return a.has(c)||(T&&globalThis.__DEV__!==!1&&hr.warn(6,n,c),a.add(c)),!0;A.forEach(g),x&&C===m.length-1&&CS(t.selectionSet,r,i)&&(x=!1,T=!0,this.fuzzySubtypes.forEac
46h(function(P,D){var B=n.match(P);B&&B[0]===n&&g(D)}))}return!1},e.prototype.hasKeyArgs=function(t,n){var r=this.getFieldPolicy(t,n,!1);return!!(r&&r.keyFn)},e.prototype.getStoreFieldName=function(t){var n=t.typename,r=t.fieldName,i=this.getFieldPolicy(n,r,!1),s,c=i&&i.keyFn;if(c&&n)for(var a={typename:n,fieldName:r,field:t.field||null,variables:t.variables},m=MS(t);c;){var g=c(m,a);if(Do(g))c=rD(g);else{s=g||r;break}}return s===void 0&&(s=t.field?X9(t.field,t.variables):Ik(r,MS(t))),s===!1?r:r===Pd(s)?s:r+":"+s},e.prototype.readField=function(t,n){var r=t.from;if(r){var i=t.field||t.fieldName;if(i){if(t.typename===void 0){var s=n.store.getFieldValue(r,"__typename");s&&(t.typename=s)}var c=this.getStoreFieldName(t),a=Pd(c),m=n.store.getFieldValue(r,c),g=this.getFieldPolicy(t.typename,a,!1),x=g&&g.read;if(x){var T=sD(this,r,t,n,n.store.getStorage(xi(r)?r.__ref:r,c));return Vk.withValue(this.cache,x,[m,T])}return m}}},e.prototype.getReadFunction=function(t,n){var r=this.getFieldPolicy(t,n,!1);return r&&r.read},e.prototype.getMergeFunction=function(t,n,r){var i=this.getFieldPolicy(t,n,!1),s=i&&i.merge;return!s&&r&&(i=this.getTypePolicy(r),s=i&&i.merge),s},e.prototype.runMergeFunction=function(t,n,r,i,s){var c=r.field,a=r.typename,m=r.merge;return m===oD?yz(i.store)(t,n):m===aD?n:(i.overwrite&&(t=void 0),m(t,n,sD(this,void 0,{typename:a,fieldName:c.name.value,field:c,variables:i.variables},i,s||Object.create(null))))},e}();function sD(e,t,n,r,i){var s=e.getStoreFieldName(n),c=Pd(s),a=n.variables||r.variables,m=r.store,g=m.toReference,x=m.canRead;return{args:MS(n),field:n.field||null,fieldName:c,storeFieldName:s,variables:a,isReference:xi,toReference:g,storage:i,cache:e.cache,canRead:x,readField:function(){return e.readField(Wk(arguments,t,a),r)},mergeObjects:yz(r.store)}}function Wk(e,t,n){var r=e[0],i=e[1],s=e.length,c;return typeof r=="string"?c={fieldName:r,from:s>1?i:t}:(c=Lt({},r),xa.call(c,"from")||(c.from=t)),globalThis.__DEV__!==!1&&c.from===void 0&&globalThis.__DEV__!==!1&&hr.warn(7,PB(Array.from(e))),c.variables===void 0&&(c.variables=n),c}function yz(e){return function(n,r){if(Do(n)||Do(r))throw vs(8);if(Xi(n)&&Xi(r)){var i=e.getFieldValue(n,"__typename"),s=e.getFieldValue(r,"__typename"),c=i&&s&&i!==s;if(c)return r;if(xi(n)&&Am(r))return e.merge(n.__ref,r),n;if(Am(n)&&xi(r))return e.merge(n,r.__ref),r;if(Am(n)&&Am(r))return Lt(Lt({},n),r)}return r}}function MT(e,t,n){var r="".concat(t).concat(n),i=e.flavors.get(r);return i||e.flavors.set(r,i=e.clientOnly===t&&e.deferred===n?e:Lt(Lt({},e),{clientOnly:t,deferred:n})),i}var LZ=function(){function e(t,n,r){this.cache=t,this.reader=n,this.fragments=r}return e.prototype.writeToStore=function(t,n){var r=this,i=n.query,s=n.result,c=n.dataId,a=n.variables,m=n.overwrite,g=Mv(i),x=wZ();a=Lt(Lt({},Ok(g)),a);var T=Lt(Lt({store:t,written:Object.create(null),merge:function(A,P){return x.merge
46(A,P)},variables:a,varString:ip(a)},dz(i,this.fragments)),{overwrite:!!m,incomingById:new Map,clientOnly:!1,deferred:!1,flavors:new Map}),C=this.processSelectionSet({result:s||Object.create(null),dataId:c,selectionSet:g.selectionSet,mergeTree:{map:new Map},context:T});if(!xi(C))throw vs(11,s);return T.incomingById.forEach(function(A,P){var D=A.storeObject,B=A.mergeTree,R=A.fieldNodeSet,N=Nm(P);if(B&&B.map.size){var j=r.applyMerges(B,N,D,T);if(xi(j))return;D=j}if(globalThis.__DEV__!==!1&&!T.overwrite){var U=Object.create(null);R.forEach(function(Z){Z.selectionSet&&(U[Z.name.value]=!0)});var W=function(Z){return U[Pd(Z)]===!0},Q=function(Z){var K=B&&B.map.get(Z);return!!(K&&K.info&&K.info.merge)};Object.keys(D).forEach(function(Z){W(Z)&&!Q(Z)&&RZ(N,D,Z,T.store)})}t.merge(P,D)}),t.retain(C.__ref),C},e.prototype.processSelectionSet=function(t){var n=this,r=t.dataId,i=t.result,s=t.selectionSet,c=t.context,a=t.mergeTree,m=this.cache.policies,g=Object.create(null),x=r&&m.rootTypenamesById[r]||pS(i,s,c.fragmentMap)||r&&c.store.get(r,"__typename");typeof x=="string"&&(g.__typename=x);var T=function(){var j=Wk(arguments,g,c.variables);if(xi(j.from)){var U=c.incomingById.get(j.from.__ref);if(U){var W=m.readField(Lt(Lt({},j),{from:U.storeObject}),c);if(W!==void 0)return W}}return m.readField(j,c)},C=new Set;this.flattenFields(s,i,c,x).forEach(function(j,U){var W,Q=Sd(U),Z=i[Q];if(C.add(U),Z!==void 0){var K=m.getStoreFieldName({typename:x,fieldName:U.name.value,field:U,variables:j.variables}),Y=lD(a,K),me=n.processFieldValue(Z,U,U.selectionSet?MT(j,!1,!1):j,Y),ge=void 0;U.selectionSet&&(xi(me)||Am(me))&&(ge=T("__typename",me));var ce=m.getMergeFunction(x,U.name.value,ge);ce?Y.info={field:U,typename:x,merge:ce}:cD(a,K),g=j.merge(g,(W={},W[K]=me,W))}else globalThis.__DEV__!==!1&&!j.clientOnly&&!j.deferred&&!Lk.added(U)&&!m.getReadFunction(x,U.name.value)&&globalThis.__DEV__!==!1&&hr.error(12,Sd(U),i)});try{var A=m.identify(i,{typename:x,selectionSet:s,fragmentMap:c.fragmentMap,storeObject:g,readField:T}),P=A[0],D=A[1];r=r||P,D&&(g=c.merge(g,D))}catch(j){if(!r)throw j}if(typeof r=="string"){var B=Nm(r),R=c.written[r]||(c.written[r]=[]);if(R.indexOf(s)>=0||(R.push(s),this.reader&&this.reader.isFresh(i,B,s,c)))return B;var N=c.incomingById.get(r);return N?(N.storeObject=c.merge(N.storeObject,g),N.mergeTree=IS(N.mergeTree,a),C.forEach(function(j){return N.fieldNodeSet.add(j)})):c.incomingById.set(r,{storeObject:g,mergeTree:sx(a)?void 0:a,fieldNodeSet:C}),B}return g},e.prototype.processFieldValue=function(t,n,r,i){var s=this;return!n.selectionSet||t===null?globalThis.__DEV__!==!1?qB(t):t:Do(t)?t.map(function(c,a){var m=s.processFieldValue(c,n,r,lD(i,a));return cD(i,a),m}):this.processSelectionSet({result:t,selectionSet:n.selectionSet,context:r,mergeTree:i})},e.prototype.flattenFields=function(t,n,r,i){i===void 0&&(i=pS(n,t,r.fragmentMap));var s=new Map,c=this.cache.policies,a=new Ld(!1);return function m(g,x){var T=a.lookup(g,x.clientOnly,x.deferred);T.visited||(T.visited=!0,g.selections.forEach(function(C){if(Av(C,r.variables)){var A=x.clientOnly,P=x.deferred;if(!(A&&P)&&gu(C.directives)&&C.directives.forEach(function(R){var N=R.name.value;if(N==="client"&&(A=!0),N==="defer"){var j=s1(R,r.variables);(!j||j.if!==!1)&&(P=!0)}}),Cd(C)){var D=s.get(C);D&&(A=A&&D.clientOnly,P=P&&D.deferred),s.set(C,MT(r,A,P))}else{var B=a1(C,r.lookupFragment);if(!B&&C.kind===Ta.FRAGMENT_SPREAD)throw vs(13,C.name.value);B&&c.fragmentMatches(B,i,n,r.variables)&&m(B.selectionSet,MT(r,A,P))}}}))}(t,r),s},e.prototype.applyMerges=function(t,n,r,i,s){var c,a=this;if(t.map.size&&!xi(r)){var m=!Do(r)&&(xi(n)||Am(n))?n:void 0,g=r;m&&!s&&(s=[xi(m)?m.__ref:m]);var x,T=function(C,A){return Do(C)?typeof A=="number"?C[A]:void 0:i.store.getFieldValue(C,String(A))};t.map.forEach(function(C,A){var P=T(m,A),D=T(g,A);if(D!==void 0){s&&s.push(A);var B=a.applyMerges(C,P,D,i,s);B!==D&&(x=x||new Map,x.set(A,B)),s&&hr(s.pop()===A)}}),x&&(r=Do(g)?g.slice(0):Lt({},g),x.forEach(function(C,A){r[A]=C}))}return t.info?this.cache.policies.runMergeFunction(n,r,t.info,i,s&&(c=i.store).getStorage.apply(c,s)):r},e}(),_z=[];function lD(e,t){var n=e.map;return n.has(t)||n.set(t,_z.pop()||{map:new Map}),n.get(t)}function IS(e,t){if(e===t||!t||sx(t))return e;if(!e||sx(e))return t;var n=e.info&&t.info?Lt(Lt({},e.info),t.info):e.info||t.info,r=e.map.size&&t.map.size,i=r?new Map:e.map.size?e.map:t.map,s={info:n,map:i};if(r){var c=new Set(t.map.keys());
46e.map.forEach(function(a,m){s.map.set(m,IS(a,t.map.get(m))),c.delete(m)}),c.forEach(function(a){s.map.set(a,IS(t.map.get(a),e.map.get(a)))})}return s}function sx(e){return!e||!(e.info||e.map.size)}function cD(e,t){var n=e.map,r=n.get(t);r&&sx(r)&&(_z.push(r),n.delete(t))}var uD=new Set;function RZ(e,t,n,r){var i=function(T){var C=r.getFieldValue(T,n);return typeof C=="object"&&C},s=i(e);if(s){var c=i(t);if(c&&!xi(s)&&!To(s,c)&&!Object.keys(s).every(function(T){return r.getFieldValue(c,T)!==void 0})){var a=r.getFieldValue(e,"__typename")||r.getFieldValue(t,"__typename"),m=Pd(n),g="".concat(a,".").concat(m);if(!uD.has(g)){uD.add(g);var x=[];!Do(s)&&!Do(c)&&[s,c].forEach(function(T){var C=r.getFieldValue(T,"__typename");typeof C=="string"&&!x.includes(C)&&x.push(C)}),globalThis.__DEV__!==!1&&hr.warn(14,m,a,x.length?"either ensure all objects of type "+x.join(" and ")+" have an ID or a custom merge function, or ":"",g,s,c)}}}}var FZ=function(e){Kl(t,e);function t(n){n===void 0&&(n={});var r=e.call(this)||this;return r.watches=new Set,r.addTypenameTransform=new zB(Lk),r.assumeImmutableResults=!0,r.makeVar=MZ,r.txCount=0,r.config=bZ(n),r.addTypename=!!r.config.addTypename,r.policies=new DZ({cache:r,dataIdFromObject:r.config.dataIdFromObject,possibleTypes:r.config.possibleTypes,typePolicies:r.config.typePolicies}),r.init(),r}return t.prototype.init=function(){var n=this.data=new j_.Root({policies:this.policies,resultCaching:this.config.resultCaching});this.optimisticData=n.stump,this.resetResultCache()},t.prototype.resetResultCache=function(n){var r=this,i=this.storeReader,s=this.config.fragments;this.storeWriter=new LZ(this,this.storeReader=new CZ({cache:this,addTypename:this.addTypename,resultCacheMaxSize:this.config.resultCacheMaxSize,canonizeResults:uz(this.config),canon:n?void 0:i&&i.canon,fragments:s}),s),this.maybeBroadcastWatch=ax(function(c,a){return r.broadcastWatch(c,a)},{max:this.config.resultCacheMaxSize,makeCacheKey:function(c){var a=c.optimistic?r.optimisticData:r.data;if(b_(a)){var m=c.optimistic,g=c.id,x=c.variables;return a.makeCacheKey(c.query,c.callback,ip({optimistic:m,id:g,variables:x}))}}}),new Set([this.data.group,this.optimisticData.group]).forEach(function(c){return c.resetCaching()})},t.prototype.restore=function(n){return this.init(),n&&this.data.replace(n),this},t.prototype.extract=function(n){return n===void 0&&(n=!1),(n?this.optimisticData:this.data).extract()},t.prototype.read=function(n){var r=n.returnPartialData,i=r===void 0?!1:r;try{return this.storeReader.diffQueryAgainstStore(Lt(Lt({},n),{store:n.optimistic?this.optimisticData:this.data,config:this.config,returnPartialData:i})).result||null}catch(s){if(s instanceof sz)return null;throw s}},t.prototype.write=function(n){try{return++this.txCount,this.storeWriter.writeToStore(this.data,n)}finally{!--this.txCount&&n.broadcast!==!1&&this.broadcastWatches()}},t.prototype.modify=function(n){if(xa.call(n,"id")&&!n.id)return!1;var r=n.optimistic?this.optimisticData:this.data;try{return++this.txCount,r.modify(n.id||"ROOT_QUERY",n.fields)}finally{!--this.txCount&&n.broadcast!==!1&&this.broadcastWatches()}},t.prototype.diff=function(n){return this.storeReader.diffQueryAgainstStore(Lt(Lt({},n),{store:n.optimistic?this.optimisticData:this.data,rootId:n.id||"ROOT_QUERY",config:this.config}))},t.prototype.watch=function(n){var r=this;return this.watches.size||PZ(this),this.watches.add(n),n.immediate&&this.maybeBroadcastWatch(n),function(){r.watches.delete(n)&&!r.watches.size&&eD(r),r.maybeBroadcastWatch.forget(n)}},t.prototype.gc=function(n){ip.reset();var r=this.optimisticData.gc();return n&&!this.txCount&&(n.resetResultCache?this.resetResultCache(n.resetResultIdentities):n.resetResultIdentities&&this.storeReader.resetCanon()),r},t.prototype.retain=function(n,r){return(r?this.optimisticData:this.data).retain(n)},t.prototype.release=function(n,r){return(r?this.optimisticData:this.data).release(n)},t.prototype.identify=function(n){if(xi(n))return n.__ref;try{return this.policies.identify(n)[0]}catch(r){globalThis.__DEV__!==!1&&hr.warn(r)}}
46,t.prototype.evict=function(n){if(!n.id){if(xa.call(n,"id"))return!1;n=Lt(Lt({},n),{id:"ROOT_QUERY"})}try{return++this.txCount,this.optimisticData.evict(n,this.data)}finally{!--this.txCount&&n.broadcast!==!1&&this.broadcastWatches()}},t.prototype.reset=function(n){var r=this;return this.init(),ip.reset(),n&&n.discardWatches?(this.watches.forEach(function(i){return r.maybeBroadcastWatch.forget(i)}),this.watches.clear(),eD(this)):this.broadcastWatches(),Promise.resolve()},t.prototype.removeOptimistic=function(n){var r=this.optimisticData.removeLayer(n);r!==this.optimisticData&&(this.optimisticData=r,this.broadcastWatches())},t.prototype.batch=function(n){var r=this,i=n.update,s=n.optimistic,c=s===void 0?!0:s,a=n.removeOptimistic,m=n.onWatchUpdated,g,x=function(C){var A=r,P=A.data,D=A.optimisticData;++r.txCount,C&&(r.data=r.optimisticData=C);try{return g=i(r)}finally{--r.txCount,r.data=P,r.optimisticData=D}},T=new Set;return m&&!this.txCount&&this.broadcastWatches(Lt(Lt({},n),{onWatchUpdated:function(C){return T.add(C),!1}})),typeof c=="string"?this.optimisticData=this.optimisticData.addLayer(c,x):c===!1?x(this.data):x(),typeof a=="string"&&(this.optimisticData=this.optimisticData.removeLayer(a)),m&&T.size?(this.broadcastWatches(Lt(Lt({},n),{onWatchUpdated:function(C,A){var P=m.call(this,C,A);return P!==!1&&T.delete(C),P}})),T.size&&T.forEach(function(C){return r.maybeBroadcastWatch.dirty(C)})):this.broadcastWatches(n),g},t.prototype.performTransaction=function(n,r){return this.batch({update:n,optimistic:r||r!==null})},t.prototype.transformDocument=function(n){return this.addTypenameToDocument(this.addFragmentsToDocument(n))},t.prototype.broadcastWatches=function(n){var r=this;this.txCount||this.watches.forEach(function(i){return r.maybeBroadcastWatch(i,n)})},t.prototype.addFragmentsToDocument=function(n){var r=this.config.fragments;return r?r.transform(n):n},t.prototype.addTypenameToDocument=function(n){return this.addTypename?this.addTypenameTransform.transformDocument(n):n},t.prototype.broadcastWatch=function(n,r){var i=n.lastDiff,s=this.diff(n);r&&(n.optimistic&&typeof r.optimistic=="string"&&(s.fromOptimisticTransaction=!0),r.onWatchUpdated&&r.onWatchUpdated.call(this,n,s,i)===!1)||(!i||!To(i.result,s.result))&&n.callback(n.lastDiff=s,i)},t}(vZ),Ii;(function(e){e[e.loading=1]="loading",e[e.setVariables=2]="setVariables",e[e.fetchMore=3]="fetchMore",e[e.refetch=4]="refetch",e[e.poll=6]="poll",e[e.ready=7]="ready",e[e.error=8]="error"})(Ii||(Ii={}));function U_(e){return e?e<7:!1}function BZ(e,t,n,r){var i=t.data,s=rh(t,["data"]),c=n.data,a=rh(n,["data"]);return To(s,a)&&Sb(Cg(e).selectionSet,i,c,{fragmentMap:o1(l1(e)),variables:r})}function Sb(e,t,n,r){if(t===n)return!0;var i=new Set;return e.selections.every(function(s){if(i.has(s)||(i.add(s),!Av(s,r.variables))||hD(s))return!0;if(Cd(s)){var c=Sd(s),a=t&&t[c],m=n&&n[c],g=s.selectionSet;if(!g)return To(a,m);var x=Array.isArray(a),T=Array.isArray(m);if(x!==T)return!1;if(x&&T){var C=a.length;if(m.length!==C)return!1;for(var A=0;A<C;++A)if(!Sb(g,a[A],m[A],r))return!1;return!0}return Sb(g,a,m,r)}else{var P=a1(s,r.fragmentMap);if(P)return hD(P)?!0:Sb(P.selectionSet,t,n,r)}})}function hD(e){return!!e.directives&&e.directives.some(zZ)}function zZ(e){return e.name.value==="nonreactive"}var dD=Object.assign,NZ=Object.hasOwnProperty,OS=function(e){Kl(t,e);function t(n){var r=n.queryManager,i=n.queryInfo,s=n.options,c=e.call(this,function(B){try{var R=B._subscription._observer;R&&!R.error&&(R.error=$Z)}catch{}var N=!c.observers.size;c.observers.add(B);var j=c.last;return j&&j.error?B.error&&B.error(j.error):j&&j.result&&B.next&&B.next(j.result),N&&c.reobserve().catch(function(){}),function(){c.observers.delete(B)&&!c.observers.size&&c.tearDownQuery()}})||this;c.observers=new Set,c.subscriptions=new Set,c.queryInfo=i,c.queryManager=r,c.waitForOwnResult=IT(s.fetchPolicy),c.isTornDown=!1;var a=r.defaultOptions.watchQuery,m=a===void 0?{}:a,g=m.fetchPolicy,x=g===void 0?"cache-first":g,T=s.fetchPolicy,C=T===void 0?x:T,A=s.initialFetchPolicy,P=A===void 0?C==="standby"?x:C:A;c.options=Lt(Lt({},s),{initialFetchPolicy:P,fetchPolicy:C}),c.queryId=i.queryId||r.generateQueryId();var D=Mv(c.query);return c.queryName=D&&D.name&&D.name.value,c}return Object.defineProperty(t.prototype,"query",{get:function(){return this.lastQuery||this.options.query}
46,enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"variables",{get:function(){return this.options.variables},enumerable:!1,configurable:!0}),t.prototype.result=function(){var n=this;return new Promise(function(r,i){var s={next:function(a){r(a),n.observers.delete(s),n.observers.size||n.queryManager.removeQuery(n.queryId),setTimeout(function(){c.unsubscribe()},0)},error:i},c=n.subscribe(s)})},t.prototype.getCurrentResult=function(n){n===void 0&&(n=!0);var r=this.getLastResult(!0),i=this.queryInfo.networkStatus||r&&r.networkStatus||Ii.ready,s=Lt(Lt({},r),{loading:U_(i),networkStatus:i}),c=this.options.fetchPolicy,a=c===void 0?"cache-first":c;if(!(IT(a)||this.queryManager.getDocumentInfo(this.query).hasForcedResolvers))if(this.waitForOwnResult)this.queryInfo.updateWatch();else{var m=this.queryInfo.getDiff();(m.complete||this.options.returnPartialData)&&(s.data=m.result),To(s.data,{})&&(s.data=void 0),m.complete?(delete s.partial,m.complete&&s.networkStatus===Ii.loading&&(a==="cache-first"||a==="cache-only")&&(s.networkStatus=Ii.ready,s.loading=!1)):s.partial=!0,globalThis.__DEV__!==!1&&!m.complete&&!this.options.partialRefetch&&!s.loading&&!s.data&&!s.error&&bz(m.missing)}return n&&this.updateLastResult(s),s},t.prototype.isDifferentFromLastResult=function(n,r){if(!this.last)return!0;var i=this.queryManager.getDocumentInfo(this.query).hasNonreactiveDirective?!BZ(this.query,this.last.result,n,this.variables):!To(this.last.result,n);return i||r&&!To(this.last.variables,r)},t.prototype.getLast=function(n,r){var i=this.last;if(i&&i[n]&&(!r||To(i.variables,this.variables)))return i[n]},t.prototype.getLastResult=function(n){return this.getLast("result",n)},t.prototype.getLastError=function(n){return this.getLast("error",n)},t.prototype.resetLastResults=function(){delete this.last,this.isTornDown=!1},t.prototype.resetQueryStoreErrors=function(){this.queryManager.resetErrors(this.queryId)},t.prototype.refetch=function(n){var r,i={pollInterval:0},s=this.options.fetchPolicy;if(s==="cache-and-network"?i.fetchPolicy=s:s==="no-cache"?i.fetchPolicy="no-cache":i.fetchPolicy="network-only",globalThis.__DEV__!==!1&&n&&NZ.call(n,"variables")){var c=BB(this.query),a=c.variableDefinitions;(!a||!a.some(function(m){return m.variable.name.value==="variables"}))&&globalThis.__DEV__!==!1&&hr.warn(20,n,((r=c.name)===null||r===void 0?void 0:r.value)||c)}return n&&!To(this.options.variables,n)&&(i.variables=this.options.variables=Lt(Lt({},this.options.variables),n)),this.queryInfo.resetLastWrite(),this.reobserve(i,Ii.refetch)},t.prototype.fetchMore=function(n){var r=this,i=Lt(Lt({},n.query?n:Lt(Lt(Lt(Lt({},this.options),{query:this.options.query}),n),{variables:Lt(Lt({},this.options.variables),n.variables)})),{fetchPolicy:"no-cache"});i.query=this.transformDocument(i.query);var s=this.queryManager.generateQueryId();this.lastQuery=n.query?this.transformDocument(this.options.query):i.query;var c=this.queryInfo,a=c.networkStatus;c.networkStatus=Ii.fetchMore,i.notifyOnNetworkStatusChange&&this.observe();var m=new Set;return this.queryManager.fetchQuery(s,i,Ii.fetchMore).then(function(g){return r.queryManager.removeQuery(s),c.networkStatus===Ii.fetchMore&&(c.networkStatus=a),r.queryManager.cache.batch({update:function(x){var T=n.updateQuery;T?x.updateQuery({query:r.query,variables:r.variables,returnPartialData:!0,optimistic:!1},function(C){return T(C,{fetchMoreResult:g.data,variables:i.variables})}):x.writeQuery({query:i.query,variables:i.variables,data:g.data})},onWatchUpdated:function(x){m.add(x.query)}}),g}).finally(function(){m.has(r.query)||vz(r)})},t.prototype.subscribeToMore=function(n){var r=this,i=this.queryManager.startGraphQLSubscription({query:n.document,variables:n.variables,context:n.context}).subscribe({next:function(s){var c=n.updateQuery;c&&r.updateQuery(function(a,m){var g=m.variables;return c(a,{subscriptionData:s,variables:g})})},error:function(s){if(n.onError){n.onError(s);return}globalThis.__DEV__!==!1&&hr.error(21,s)}});return this.subscriptions.add(i),function(){r.subscriptions.delete(i)&&i.unsubscribe()}},t.prototype.setOptions=function(n){return this.reobserve(n)},t.prototype.silentSetOptions=function(n){var r=ng(this.options,n||{});dD(this.options,r)},t.prototype.setVariables=function(n){return To(this.variables,n)?this.observers.size?this.result():Promise.resolve():(this.options.variables=n,this.observers.size?this.reobserve({fetchPolicy:this.options.initialFetchPolicy,variables:n},Ii.setVariables):Promise.resolve())},t.prototype.updateQuery=function(n){var r=this.queryManager,i=r.cache.diff({query:this.options.query,variables:this.variables,returnPartialData:!0,optimistic:!1}).result,s=n(i,{variables:this.variables});s&&(r.cache.writeQuery({query:this.options.query,data:s,variables:this.variables}),r.broadcastQueries())},t.prototype.startPolling=function(n){this.options.pollInterval=n,this.updatePolling()},t.prototype.stopPolling=function(){this.options.pollInterval=0,this.updatePolling()},t.prototype.applyNextFetchPolicy=function(n,r){if(r.nextFetchPolicy){var i=r.fetchPolicy,s=i===void 0?"cache-first":i,c=r.initialFetchPolicy,a=c===void 0?s:c;s==="standby"||(typeof r.nextFetchPolicy=="function"?r.fetchPolicy=r.nextFetchPolicy(s,{reason:n,options:r,observable:this,initialFetchPolicy:a}):n==="variables-changed"?r.fetchPolicy=a:r.fetchPolicy=r.nextFetchPolicy)}return r.fetchPolicy},t.prototype.fetch=function(n,r,i){return this.queryManager.setObservableQuery(this),this.queryManager.fetchConcastWithInfo(this.queryId,n,r,i)},t.prototype.updatePolling=function(){var n=this;if(!this.queryManager.ssrMode){var r=this,i=r.pollingInfo,s=r.options.pollInterval;
46if(!s){i&&(clearTimeout(i.timeout),delete this.pollingInfo);return}if(!(i&&i.interval===s)){hr(s,22);var c=i||(this.pollingInfo={});c.interval=s;var a=function(){n.pollingInfo&&(U_(n.queryInfo.networkStatus)?m():n.reobserve({fetchPolicy:n.options.initialFetchPolicy==="no-cache"?"no-cache":"network-only"},Ii.poll).then(m,m))},m=function(){var g=n.pollingInfo;g&&(clearTimeout(g.timeout),g.timeout=setTimeout(a,g.interval))};m()}}},t.prototype.updateLastResult=function(n,r){r===void 0&&(r=this.variables);var i=this.getLastError();return i&&this.last&&!To(r,this.last.variables)&&(i=void 0),this.last=Lt({result:this.queryManager.assumeImmutableResults?n:qB(n),variables:r},i?{error:i}:null)},t.prototype.reobserveAsConcast=function(n,r){var i=this;this.isTornDown=!1;var s=r===Ii.refetch||r===Ii.fetchMore||r===Ii.poll,c=this.options.variables,a=this.options.fetchPolicy,m=ng(this.options,n||{}),g=s?m:dD(this.options,m),x=this.transformDocument(g.query);this.lastQuery=x,s||(this.updatePolling(),n&&n.variables&&!To(n.variables,c)&&g.fetchPolicy!=="standby"&&g.fetchPolicy===a&&(this.applyNextFetchPolicy("variables-changed",g),r===void 0&&(r=Ii.setVariables))),this.waitForOwnResult&&(this.waitForOwnResult=IT(g.fetchPolicy));var T=function(){i.concast===P&&(i.waitForOwnResult=!1)},C=g.variables&&Lt({},g.variables),A=this.fetch(g,r,x),P=A.concast,D=A.fromLink,B={next:function(R){T(),i.reportResult(R,C)},error:function(R){T(),i.reportError(R,C)}};return!s&&(D||!this.concast)&&(this.concast&&this.observer&&this.concast.removeObserver(this.observer),this.concast=P,this.observer=B),P.addObserver(B),P},t.prototype.reobserve=function(n,r){return this.reobserveAsConcast(n,r).promise},t.prototype.resubscribeAfterError=function(){for(var n=[],r=0;r<arguments.length;r++)n[r]=arguments[r];var i=this.last;this.resetLastResults();var s=this.subscribe.apply(this,n);return this.last=i,s},t.prototype.observe=function(){this.reportResult(this.getCurrentResult(!1),this.variables)},t.prototype.reportResult=function(n,r){var i=this.getLastError(),s=this.isDifferentFromLastResult(n,r);(i||!n.partial||this.options.returnPartialData)&&this.updateLastResult(n,r),(i||s)&&v_(this.observers,"next",n)},t.prototype.reportError=function(n,r){var i=Lt(Lt({},this.getLastResult()),{error:n,errors:n.graphQLErrors,networkStatus:Ii.error,loading:!1});this.updateLastResult(i,r),v_(this.observers,"error",this.last.error=n)},t.prototype.hasObservers=function(){return this.observers.size>0},t.prototype.tearDownQuery=function(){this.isTornDown||(this.concast&&this.observer&&(this.concast.removeObserver(this.observer),delete this.concast,delete this.observer),this.stopPolling(),this.subscriptions.forEach(function(n){return n.unsubscribe()}),this.subscriptions.clear(),this.queryManager.stopQuery(this.queryId),this.observers.clear(),this.isTornDown=!0)},t.prototype.transformDocument=function(n){return this.queryManager.transform(n)},t}(Oi);WB(OS);function vz(e){var t=e.options,n=t.fetchPolicy,r=t.nextFetchPolicy;return n==="cache-and-network"||n==="network-only"?e.reobserve({fetchPolicy:"cache-first",nextFetchPolicy:function(){return this.nextFetchPolicy=r,typeof r=="function"?r.apply(this,arguments):n}}):e.reobserve()}function $Z(e){globalThis.__DEV__!==!1&&hr.error(23,e.message,e.stack)}function bz(e){globalThis.__DEV__!==!1&&e&&globalThis.__DEV__!==!1&&hr.debug(24,e)}function IT(e){return e==="network-only"||e==="no-cache"||e==="standby"}var xz=function(){function e(t){var n=t.cache,r=t.client,i=t.resolvers,s=t.fragmentMatcher;this.selectionsToResolveCache=new WeakMap,this.cache=n,r&&(this.client=r),i&&this.addResolvers(i),s&&this.setFragmentMatcher(s)}return e.prototype.addResolvers=function(t){var n=this;this.resolvers=this.resolvers||{},Array.isArray(t)?t.forEach(function(r){n.resolvers=MO(n.resolvers,r)}):this.resolvers=MO(this.resolvers,t)},e.prototype.setResolvers=function(t){this.resolvers={},this.addResolvers(t)},e.prototype.getResolvers=function(){return this.resolvers||{}},e.prototype.runResolvers=function(t){var n=t.document,r=t.remoteResult,i=t.context,s=t.variables,c=t.onlyRunForcedResolvers,a=c===void 0?!1:c;return Qh(this,void 0,void 0,function(){return Jh(this,function(m){return n?[2,this.resolveDocument(n,r.data,i,s,this.fragmentMatcher,a).then(function(g){return Lt(Lt({},r),{data:g.result})})]:[2,r]})})},e.prototype.setFragmentMatcher=function(t){this.fragmentMatcher=t},e.prototype.getFragmentMatcher=function(){return this.fragmentMatcher},e.prototype.clientQuery=function(t){return N_(["client"],t)&&this.resolvers?t:null},e.prototype.serverQuery=function(t){return jB(t)},e.prototype.prepareContext=function(t){var n=this.cache;return Lt(Lt({},t),{cache:n,getCacheKey:function(r){return n.identify(r)}})},e.prototype.addExportedVariables=function(t,n,r){return n===void 0&&(n={}),r===void 0&&(r={}),Qh(this,void 0,void 0,function(){return Jh(this,function(i){return t?[2,this.resolveDocument(t,this.buildRootValueFromCache(t,n)||{},this.prepareContext(r),n).then(function(s){return Lt(Lt({},n),s.exportedVariables)})]:[2,Lt({},n)]})})},e.prototype.shouldForceResolvers=function(t){var n=!1;return ih(t,{Directive:{enter:function(r){if(r.name.value==="client"&&r.arguments&&(n=r.arguments.some(function(i){return i.name.value==="always"&&i.value.kind==="BooleanValue"&&i.value.value===!0}),n))return Mk}}}),n},e.prototype.buildRootValueFromCache=function(t,n){return this.cache.diff({query:iY(t),variables:n,returnPartialData:!0,optimistic:!1}).result},e.prototype.resolveDocument=function(t,n,r,i,s,c){return r===void 0&&(r={}),i===void 0&&(i={}),s===void 0&&(s=function(){return!0}),c===void 0&&(c=!1),Qh(this,void 0,void 0,function(){var a,m,g,x,T,C,A,P,D,B,R;return Jh(this,function(N){return a=Cg(t),m=l1(t),g=o1(m),x=this.collectSelectionsToResolve(a,g),T=a.operation,C=T?T.charAt(0).toUpperCase()+T.slice(1):"Query",A=this,P=A.cache,D=A.client,B={fragmentMap:g,context:Lt(Lt({},r),{cache:P,client:D}),variables:i,fragmentMatcher:s,defaultOperationType:C,exportedVariables:{},selectionsToResolve:x,onlyRunForcedResolvers:c},R=!1,[2,this.resolveSelectionSet(a.selectionSet,R,n,B).then(function(j){return{result:j,exportedVariables:B.exportedVariables}})]})})},e.prototype.resolveSelectionSet=function(t,n,r,i){return Qh(this,void 0,void 0,function(){var s,c,a,m,g,x=this;return Jh(this,function(T){return s=i.fragmentMap,c=i.context,a=i.variables,m=[r],g=function(C){return Qh(x,void 0,void 0,function(){var A,P;return Jh(this,function(D){return!n&&!i.selectionsToResolve.has(C)?[2]:Av(C,a)?Cd(C)?[2,this.resolveField(C,n,r,i).then(function(B){var R;typeof B<"u"&&m.push((R={},R[Sd(C)]=B,R))})]:(J9(C)?A=C:(A=s[C.name.value],hr(A,18,C.name.value)),A&&A.typeCondition&&(P=A.typeCondition.name.value,i.fragmentMatcher(r,P,c))?[2,this.resolveSelectionSet(A.selectionSet,n,r,i).then(function(B){m.push(B)})]:[2]):[2]})})},[2,Promise.all(t.selections.map(g)).then(function(){return Rk(m)})]})})},e.prototype.resolveField=function(t,n,r,i){return Qh(this,void 0,void 0,function(){var s,c,a,m,g,x,T,C,A,P=this;return Jh(this,function(D){return r?(s=i.variables,c=t.name.value,a=Sd(t),m=c!==a,g=r[a
46]||r[c],x=Promise.resolve(g),(!i.onlyRunForcedResolvers||this.shouldForceResolvers(t))&&(T=r.__typename||i.defaultOperationType,C=this.resolvers&&this.resolvers[T],C&&(A=C[m?c:a],A&&(x=Promise.resolve(Vk.withValue(this.cache,A,[r,s1(t,s),i.context,{field:t,fragmentMap:i.fragmentMap}]))))),[2,x.then(function(B){var R,N;if(B===void 0&&(B=g),t.directives&&t.directives.forEach(function(U){U.name.value==="export"&&U.arguments&&U.arguments.forEach(function(W){W.name.value==="as"&&W.value.kind==="StringValue"&&(i.exportedVariables[W.value.value]=B)})}),!t.selectionSet||B==null)return B;var j=(N=(R=t.directives)===null||R===void 0?void 0:R.some(function(U){return U.name.value==="client"}))!==null&&N!==void 0?N:!1;if(Array.isArray(B))return P.resolveSubSelectedArray(t,n||j,B,i);if(t.selectionSet)return P.resolveSelectionSet(t.selectionSet,n||j,B,i)})]):[2,null]})})},e.prototype.resolveSubSelectedArray=function(t,n,r,i){var s=this;return Promise.all(r.map(function(c){if(c===null)return null;if(Array.isArray(c))return s.resolveSubSelectedArray(t,n,c,i);if(t.selectionSet)return s.resolveSelectionSet(t.selectionSet,n,c,i)}))},e.prototype.collectSelectionsToResolve=function(t,n){var r=function(c){return!Array.isArray(c)},i=this.selectionsToResolveCache;function s(c){if(!i.has(c)){var a=new Set;i.set(c,a),ih(c,{Directive:function(m,g,x,T,C){m.name.value==="client"&&C.forEach(function(A){r(A)&&CO(A)&&a.add(A)})},FragmentSpread:function(m,g,x,T,C){var A=n[m.name.value];hr(A,19,m.name.value);var P=s(A);P.size>0&&(C.forEach(function(D){r(D)&&CO(D)&&a.add(D)}),a.add(m),P.forEach(function(D){a.add(D)}))}})}return i.get(c)}return s(t)},e}(),Pm=new(ch?WeakMap:Map);function OT(e,t){var n=e[t];typeof n=="function"&&(e[t]=function(){return Pm.set(e,(Pm.get(e)+1)%1e15),n.apply(this,arguments)})}function fD(e){e.notifyTimeout&&(clearTimeout(e.notifyTimeout),e.notifyTimeout=void 0)}var DT=function(){function e(t,n){n===void 0&&(n=t.generateQueryId()),this.queryId=n,this.listeners=new Set,this.document=null,this.lastRequestId=1,this.stopped=!1,this.dirty=!1,this.observableQuery=null;var r=this.cache=t.cache;Pm.has(r)||(Pm.set(r,0),OT(r,"evict"),OT(r,"modify"),OT(r,"reset"))}return e.prototype.init=function(t){var n=t.networkStatus||Ii.loading;return this.variables&&this.networkStatus!==Ii.loading&&!To(this.variables,t.variables)&&(n=Ii.setVariables),To(t.variables,this.variables)||(this.lastDiff=void 0),Object.assign(this,{document:t.document,variables:t.variables,networkError:null,graphQLErrors:this.graphQLErrors||[],networkStatus:n}),t.observableQuery&&this.setObservableQuery(t.observableQuery),t.lastRequestId&&(this.lastRequestId=t.lastRequestId),this},e.prototype.reset=function(){fD(this),this.dirty=!1},e.prototype.getDiff=function(){var t=this.getDiffOptions();if(this.lastDiff&&To(t,this.lastDiff.options))return this.lastDiff.diff;this.updateWatch(this.variables);var n=this.observableQuery;if(n&&n.options.fetchPolicy==="no-cache")return{complete:!1};var r=this.cache.diff(t);return this.updateLastDiff(r,t),r},e.prototype.updateLastDiff=function(t,n){this.lastDiff=t?{diff:t,options:n||this.getDiffOptions()}:void 0},e.prototype.getDiffOptions=function(t){var n;return t===void 0&&(t=this.variables),{query:this.document,variables:t,returnPartialData:!0,optimistic:!0,canonizeResults:(n=this.observableQuery)===null||n===void 0?void 0:n.options.canonizeResults}},e.prototype.setDiff=function(t){var n=this,r=this.lastDiff&&this.lastDiff.diff;this.updateLastDiff(t),!this.dirty&&!To(r&&r.result,t&&t.result)&&(this.dirty=!0,this.notifyTimeout||(this.notifyTimeout=setTimeout(function(){return n.notify()},0)))},e.prototype.setObservableQuery=function(t){var n=this;t!==this.observableQuery&&(this.oqListener&&this.listeners.delete(this.oqListener),this.observableQuery=t,t?(t.queryInfo=this,this.listeners.add(this.oqListener=function(){var r=n.getDiff();r.fromOptimisticTransaction?t.observe():vz(t)})):delete this.oqListener)},e.prototype.notify=function(){var t=this;fD(this),this.shouldNotify()&&this.listeners.forEach(function(n){return n(t)}),this.dirty=!1},e.prototype.shouldNotify=function(){if(!this.dirty||!this.listeners.size)return!1;if(U_(this.networkStatus)&&this.observableQuery){var t=this.observableQuery.options.fetchPolicy;if(t!=="cache-only"&&t!=="cache-and-network")return!1}return!0},e.prototype.stop=function(){if(!this.stopped){this.stopped=!0,this.reset(),this.cancel(),this.cancel=e.prototype.cancel;var t=this.observableQuery;t&&t.stopPolling()}},e.prototype.cancel=function(){},e.prototype.updateWatch=function(t){var n=this;t===void 0&&(t=this.variables);var r=this.observableQuery;if(!(r&&r.options.fetchPolicy==="no-cache")){var i=Lt(Lt({},this.getDiffOptions(t)),{watcher:this,callback:function(s){return n.setDiff(s)}});(!this.lastWatch||!To(i,this.lastWatch))&&(this.cancel(),this.cancel=this.cache.watch(this.lastWatch=i))}},e.prototype.resetLastWrite=function(){this.lastWrite=void 0},e.prototype.shouldWrite=function(t,n){var r=this.lastWrite;return!(r&&r.dmCount===Pm.get(this.cache)&&To(n,r.variables)&&To(t.data,r.result.data))},e.prototype.markResult=function(t,n,r,i){var s=this,c=new kd,a=gu(t.errors)?t.errors.slice(0):[];if(this.reset(),"incremental"in t&&gu(t.incremental)){var m=HB(this.getDiff().result,t);t.data=m}else if("hasNext"in t&&t.hasNext){var g=this.getDiff();t.data=c.merge(g.result,t.data)}this.graphQLErrors=a,r.fetchPolicy==="no-cache"?this.updateLastDiff({result:t.data,complete:!0},this.getDiffOptions(r.variables)):i!==0&&(DS(t,r.errorPolicy)?this.cache.performTransaction(function(x){if(s.shouldWrite(t,r.variables))x.writeQuery({query:n,data:t.data,variables:r.variables,overwrite:i===1}),s.lastWrite={result:t,variables:r.variables,dmCount:Pm.get(s.cache)};else if(s.lastDiff&&s.lastDiff.diff.complete){t.data=s.lastDiff.diff.result;return}var T=s.getDiffOptions(r.variables),C=x.diff(T);!s.stopped&&To(s.variables,r.variables)&&s.updateWatch(r.variables),s.updateLastDiff(C,T),C.complete&&(t.data=C.result)}):this.lastWrite=void 0)},e.prototype.markReady=function(){return this.networkError=null,this.networkStatus=Ii.ready},e.prototype.markError=function(t){return this.networkStatus=Ii.error,this.lastWrite=void 0,this.reset(),t.graphQLErrors&&(this.graphQLErrors=t.graphQLErrors),t.networkError&&(this.networkError=t.networkError),t},e}();function DS(e,t){t===void 0&&(t="none");var n=t==="ignore"||t==="all",r=!Tb(e);return!r&&n&&e.data&&(r=!0),r}var jZ=Object.prototype.hasOwnProperty,UZ=function(){function e(t){var n=this,r=t.cache,i=t.link,s=t.defaultOptions,c=t.documentTransform,a=t.queryDeduplication,m=a===void 0?!1:a,g=t.onBroadcast,x=t.ssrMode,T=x===void 0?!1:x,C=t.clientAwareness,A=C===void 0?{}:C,P=t.localState,D=t.assumeImmutableResults,B=D===void 0?!!r.assumeImmutableResults:D;this.clientAwareness={},this.queries=new Map,this.fetchCancelFns=new Map,this.transformCache=new(ch?WeakMap:Map),this.queryIdCounter=1,this.requestIdCounter=1,this.mutationIdCounter=1,this.inFlightLinkObservables=new Map;var R=new zB(function(N){return n.cache.transformDocument(N)},{cache:!1});this.cache=r,this.link=i,this.defaultOptions=s||Object.create(null),this.queryDeduplication=m,this.clientAwareness=A,this.localState=P||new xz({cache:r}),this.ssrMode=T,this.assumeImmutableResults=B,this.documentTransform=c?R.concat(c).concat(R):R,(this.onBroadcast=g)&&(this.mutationStore=Object.create(null))}return e.prototype.stop=function(){var t=this;
46this.queries.forEach(function(n,r){t.stopQueryNoBroadcast(r)}),this.cancelPendingFetches(vs(25))},e.prototype.cancelPendingFetches=function(t){this.fetchCancelFns.forEach(function(n){return n(t)}),this.fetchCancelFns.clear()},e.prototype.mutate=function(t){var n,r,i=t.mutation,s=t.variables,c=t.optimisticResponse,a=t.updateQueries,m=t.refetchQueries,g=m===void 0?[]:m,x=t.awaitRefetchQueries,T=x===void 0?!1:x,C=t.update,A=t.onQueryUpdated,P=t.fetchPolicy,D=P===void 0?((n=this.defaultOptions.mutate)===null||n===void 0?void 0:n.fetchPolicy)||"network-only":P,B=t.errorPolicy,R=B===void 0?((r=this.defaultOptions.mutate)===null||r===void 0?void 0:r.errorPolicy)||"none":B,N=t.keepRootFields,j=t.context;return Qh(this,void 0,void 0,function(){var U,W,Q,Z;return Jh(this,function(K){switch(K.label){case 0:return hr(i,26),hr(D==="network-only"||D==="no-cache",27),U=this.generateMutationId(),i=this.cache.transformForLink(this.transform(i)),W=this.getDocumentInfo(i).hasClientExports,s=this.getVariables(i,s),W?[4,this.localState.addExportedVariables(i,s,j)]:[3,2];case 1:s=K.sent(),K.label=2;case 2:return Q=this.mutationStore&&(this.mutationStore[U]={mutation:i,variables:s,loading:!0,error:null}),c&&this.markMutationOptimistic(c,{mutationId:U,document:i,variables:s,fetchPolicy:D,errorPolicy:R,context:j,updateQueries:a,update:C,keepRootFields:N}),this.broadcastQueries(),Z=this,[2,new Promise(function(Y,me){return TT(Z.getObservableFromLink(i,Lt(Lt({},j),{optimisticResponse:c}),s,!1),function(ge){if(Tb(ge)&&R==="none")throw new Nf({graphQLErrors:bS(ge)});Q&&(Q.loading=!1,Q.error=null);var ce=Lt({},ge);return typeof g=="function"&&(g=g(ce)),R==="ignore"&&Tb(ce)&&delete ce.errors,Z.markMutationResult({mutationId:U,result:ce,document:i,variables:s,fetchPolicy:D,errorPolicy:R,context:j,update:C,updateQueries:a,awaitRefetchQueries:T,refetchQueries:g,removeOptimistic:c?U:void 0,onQueryUpdated:A,keepRootFields:N})}).subscribe({next:function(ge){Z.broadcastQueries(),(!("hasNext"in ge)||ge.hasNext===!1)&&Y(ge)},error:function(ge){Q&&(Q.loading=!1,Q.error=ge),c&&Z.cache.removeOptimistic(U),Z.broadcastQueries(),me(ge instanceof Nf?ge:new Nf({networkError:ge}))}})})]}})})},e.prototype.markMutationResult=function(t,n){var r=this;n===void 0&&(n=this.cache);var i=t.result,s=[],c=t.fetchPolicy==="no-cache";if(!c&&DS(i,t.errorPolicy)){if($m(i)||s.push({result:i.data,dataId:"ROOT_MUTATION",query:t.document,variables:t.variables}),$m(i)&&gu(i.incremental)){var a=n.diff({id:"ROOT_MUTATION",query:this.getDocumentInfo(t.document).asQuery,variables:t.variables,optimistic:!1,returnPartialData:!0}),m=void 0;a.result&&(m=HB(a.result,i)),typeof m<"u"&&(i.data=m,s.push({result:m,dataId:"ROOT_MUTATION",query:t.document,variables:t.variables}))}var g=t.updateQueries;g&&this.queries.forEach(function(T,C){var A=T.observableQuery,P=A&&A.queryName;if(!(!P||!jZ.call(g,P))){var D=g[P],B=r.queries.get(C),R=B.document,N=B.variables,j=n.diff({query:R,variables:N,returnPartialData:!0,optimistic:!1}),U=j.result,W=j.complete;if(W&&U){var Q=D(U,{mutationResult:i,queryName:R&&mS(R)||void 0,queryVariables:N});Q&&s.push({result:Q,dataId:"ROOT_QUERY",query:R,variables:N})}}})}if(s.length>0||t.refetchQueries||t.update||t.onQueryUpdated||t.removeOptimistic){var x=[];if(this.refetchQueries({updateCache:function(T){c||s.forEach(function(D){return T.write(D)});var C=t.update,A=!vY(i)||$m(i)&&!i.hasNext;if(C){if(!c){var P=T.diff({id:"ROOT_MUTATION",query:r.getDocumentInfo(t.document).asQuery,variables:t.variables,optimistic:!1,returnPartialData:!0});P.complete&&(i=Lt(Lt({},i),{data:P.result}),"incremental"in i&&delete i.incremental,"hasNext"in i&&delete i.hasNext)}A&&C(T,i,{context:t.context,variables:t.variables})}!c&&!t.keepRootFields&&A&&T.modify({id:"ROOT_MUTATION",fields:function(D,B){var R=B.fieldName,N=B.DELETE;return R==="__typename"?D:N}})},include:t.refetchQueries,optimistic:!1,removeOptimistic:t.removeOptimistic,onQueryUpdated:t.onQueryUpdated||null}).forEach(function(T){return x.push(T)}),t.awaitRefetchQueries||t.onQueryUpdated)return Promise.all(x).then(function(){return i})}return Promise.resolve(i)},e.prototype.markMutationOptimistic=function(t,n){var r=this,i=typeof t=="function"?t(n.variables):t;return this.cache.recordOptimisticTransaction(function(s){try{r.markMutationResult(Lt(Lt({},n),{result:{data:i}}),s)}catch(c){globalThis.__DEV__!==!1&&hr.error(c)}},n.mutationId)},e.prototype.fetchQuery=function(t,n,r){return this.fetchConcastWithInfo(t,n,r).concast.promise},e.prototype.getQueryStore=function(){var t=Object.create(null);
46return this.queries.forEach(function(n,r){t[r]={variables:n.variables,networkStatus:n.networkStatus,networkError:n.networkError,graphQLErrors:n.graphQLErrors}}),t},e.prototype.resetErrors=function(t){var n=this.queries.get(t);n&&(n.networkError=void 0,n.graphQLErrors=[])},e.prototype.transform=function(t){return this.documentTransform.transformDocument(t)},e.prototype.getDocumentInfo=function(t){var n=this.transformCache;if(!n.has(t)){var r={hasClientExports:O9(t),hasForcedResolvers:this.localState.shouldForceResolvers(t),hasNonreactiveDirective:N_(["nonreactive"],t),clientQuery:this.localState.clientQuery(t),serverQuery:$B([{name:"client",remove:!0},{name:"connection"},{name:"nonreactive"}],t),defaultVars:Ok(Mv(t)),asQuery:Lt(Lt({},t),{definitions:t.definitions.map(function(i){return i.kind==="OperationDefinition"&&i.operation!=="query"?Lt(Lt({},i),{operation:"query"}):i})})};n.set(t,r)}return n.get(t)},e.prototype.getVariables=function(t,n){return Lt(Lt({},this.getDocumentInfo(t).defaultVars),n)},e.prototype.watchQuery=function(t){var n=this.transform(t.query);t=Lt(Lt({},t),{variables:this.getVariables(n,t.variables)}),typeof t.notifyOnNetworkStatusChange>"u"&&(t.notifyOnNetworkStatusChange=!1);var r=new DT(this),i=new OS({queryManager:this,queryInfo:r,options:t});return i.lastQuery=n,this.queries.set(i.queryId,r),r.init({document:n,observableQuery:i,variables:i.variables}),i},e.prototype.query=function(t,n){var r=this;return n===void 0&&(n=this.generateQueryId()),hr(t.query,28),hr(t.query.kind==="Document",29),hr(!t.returnPartialData,30),hr(!t.pollInterval,31),this.fetchQuery(n,Lt(Lt({},t),{query:this.transform(t.query)})).finally(function(){return r.stopQuery(n)})},e.prototype.generateQueryId=function(){return String(this.queryIdCounter++)},e.prototype.generateRequestId=function(){return this.requestIdCounter++},e.prototype.generateMutationId=function(){return String(this.mutationIdCounter++)},e.prototype.stopQueryInStore=function(t){this.stopQueryInStoreNoBroadcast(t),this.broadcastQueries()},e.prototype.stopQueryInStoreNoBroadcast=function(t){var n=this.queries.get(t);n&&n.stop()},e.prototype.clearStore=function(t){return t===void 0&&(t={discardWatches:!0}),this.cancelPendingFetches(vs(32)),this.queries.forEach(function(n){n.observableQuery?n.networkStatus=Ii.loading:n.stop()}),this.mutationStore&&(this.mutationStore=Object.create(null)),this.cache.reset(t)},e.prototype.getObservableQueries=function(t){var n=this;t===void 0&&(t="active");var r=new Map,i=new Map,s=new Set;return Array.isArray(t)&&t.forEach(function(c){typeof c=="string"?i.set(c,!1):$9(c)?i.set(n.transform(c),!1):Xi(c)&&c.query&&s.add(c)}),this.queries.forEach(function(c,a){var m=c.observableQuery,g=c.document;if(m){if(t==="all"){r.set(a,m);return}var x=m.queryName,T=m.options.fetchPolicy;if(T==="standby"||t==="active"&&!m.hasObservers())return;(t==="active"||x&&i.has(x)||g&&i.has(g))&&(r.set(a,m),x&&i.set(x,!0),g&&i.set(g,!0))}}),s.size&&s.forEach(function(c){var a=dS("legacyOneTimeQuery"),m=n.getQuery(a).init({document:c.query,variables:c.variables}),g=new OS({queryManager:n,queryInfo:m,options:Lt(Lt({},c),{fetchPolicy:"network-only"})});hr(g.queryId===a),m.setObservableQuery(g),r.set(a,g)}),globalThis.__DEV__!==!1&&i.size&&i.forEach(function(c,a){c||globalThis.__DEV__!==!1&&hr.warn(typeof a=="string"?33:34,a)}),r},e.prototype.reFetchObservableQueries=function(t){var n=this;t===void 0&&(t=!1);var r=[];return this.getObservableQueries(t?"all":"active").forEach(function(i,s){var c=i.options.fetchPolicy;i.resetLastResults(),(t||c!=="standby"&&c!=="cache-only")&&r.push(i.refetch()),n.getQuery(s).setDiff(null)}),this.broadcastQueries(),Promise.all(r)},e.prototype.setObservableQuery=function(t){this.getQuery(t.queryId).setObservableQuery(t)},e.prototype.startGraphQLSubscription=function(t){var n=this,r=t.query,i=t.fetchPolicy,s=t.errorPolicy,c=s===void 0?"none":s,a=t.variables,m=t.context,g=m===void 0?{}:m;r=this.transform(r),a=this.getVariables(r,a);var x=function(C){return n.getObservableFromLink(r,g,C).map(function(A){i!=="no-cache"&&(DS(A,c)&&n.cache.write({query:r,result:A.data,dataId:"ROOT_SUBSCRIPTION",variables:C}),n.broadcastQueries());var P=Tb(A),D=FY(A);
46if(P||D){var B={};if(P&&(B.graphQLErrors=A.errors),D&&(B.protocolErrors=A.extensions[$k]),c==="none"||D)throw new Nf(B)}return c==="ignore"&&delete A.errors,A})};if(this.getDocumentInfo(r).hasClientExports){var T=this.localState.addExportedVariables(r,a,g).then(x);return new Oi(function(C){var A=null;return T.then(function(P){return A=P.subscribe(C)},C.error),function(){return A&&A.unsubscribe()}})}return x(a)},e.prototype.stopQuery=function(t){this.stopQueryNoBroadcast(t),this.broadcastQueries()},e.prototype.stopQueryNoBroadcast=function(t){this.stopQueryInStoreNoBroadcast(t),this.removeQuery(t)},e.prototype.removeQuery=function(t){this.fetchCancelFns.delete(t),this.queries.has(t)&&(this.getQuery(t).stop(),this.queries.delete(t))},e.prototype.broadcastQueries=function(){this.onBroadcast&&this.onBroadcast(),this.queries.forEach(function(t){return t.notify()})},e.prototype.getLocalState=function(){return this.localState},e.prototype.getObservableFromLink=function(t,n,r,i){var s=this,c;i===void 0&&(i=(c=n==null?void 0:n.queryDeduplication)!==null&&c!==void 0?c:this.queryDeduplication);var a,m=this.getDocumentInfo(t),g=m.serverQuery,x=m.clientQuery;if(g){var T=this,C=T.inFlightLinkObservables,A=T.link,P={query:g,variables:r,operationName:mS(g)||void 0,context:this.prepareContext(Lt(Lt({},n),{forceFetch:!i}))};if(n=P.context,i){var D=Dk(g),B=C.get(D)||new Map;C.set(D,B);var R=ip(r);if(a=B.get(R),!a){var N=new Em([wS(A,P)]);B.set(R,a=N),N.beforeNext(function(){B.delete(R)&&B.size<1&&C.delete(D)})}}else a=new Em([wS(A,P)])}else a=new Em([Oi.of({data:{}})]),n=this.prepareContext(n);return x&&(a=TT(a,function(j){return s.localState.runResolvers({document:x,remoteResult:j,context:n,variables:r})})),a},e.prototype.getResultsFromLink=function(t,n,r){var i=t.lastRequestId=this.generateRequestId(),s=this.cache.transformForLink(r.query);return TT(this.getObservableFromLink(s,r.context,r.variables),function(c){var a=bS(c),m=a.length>0;if(i>=t.lastRequestId){if(m&&r.errorPolicy==="none")throw t.markError(new Nf({graphQLErrors:a}));t.markResult(c,s,r,n),t.markReady()}var g={data:c.data,loading:!1,networkStatus:Ii.ready};return m&&r.errorPolicy!=="ignore"&&(g.errors=a,g.networkStatus=Ii.error),g}
46,function(c){var a=BY(c)?c:new Nf({networkError:c});throw i>=t.lastRequestId&&t.markError(a),a})},e.prototype.fetchConcastWithInfo=function(t,n,r,i){var s=this;r===void 0&&(r=Ii.loading),i===void 0&&(i=n.query);var c=this.getVariables(i,n.variables),a=this.getQuery(t),m=this.defaultOptions.watchQuery,g=n.fetchPolicy,x=g===void 0?m&&m.fetchPolicy||"cache-first":g,T=n.errorPolicy,C=T===void 0?m&&m.errorPolicy||"none":T,A=n.returnPartialData,P=A===void 0?!1:A,D=n.notifyOnNetworkStatusChange,B=D===void 0?!1:D,R=n.context,N=R===void 0?{}:R,j=Object.assign({},n,{query:i,variables:c,fetchPolicy:x,errorPolicy:C,returnPartialData:P,notifyOnNetworkStatusChange:B,context:N}),U=function(Y){j.variables=Y;var me=s.fetchQueryByPolicy(a,j,r);return j.fetchPolicy!=="standby"&&me.sources.length>0&&a.observableQuery&&a.observableQuery.applyNextFetchPolicy("after-fetch",n),me},W=function(){return s.fetchCancelFns.delete(t)};this.fetchCancelFns.set(t,function(Y){W(),setTimeout(function(){return Q.cancel(Y)})});var Q,Z;if(this.getDocumentInfo(j.query).hasClientExports)Q=new Em(this.localState.addExportedVariables(j.query,j.variables,j.context).then(U).then(function(Y){return Y.sources})),Z=!0;else{var K=U(j.variables);Z=K.fromLink,Q=new Em(K.sources)}return Q.promise.then(W,W),{concast:Q,fromLink:Z}},e.prototype.refetchQueries=function(t){var n=this,r=t.updateCache,i=t.include,s=t.optimistic,c=s===void 0?!1:s,a=t.removeOptimistic,m=a===void 0?c?dS("refetchQueries"):void 0:a,g=t.onQueryUpdated,x=new Map;i&&this.getObservableQueries(i).forEach(function(C,A){x.set(A,{oq:C,lastDiff:n.getQuery(A).getDiff()})});var T=new Map;return r&&this.cache.batch({update:r,optimistic:c&&m||!1,removeOptimistic:m,onWatchUpdated:function(C,A,P){var D=C.watcher instanceof DT&&C.watcher.observableQuery;if(D){if(g){x.delete(D.queryId);var B=g(D,A,P);return B===!0&&(B=D.refetch()),B!==!1&&T.set(D,B),B}g!==null&&x.set(D.queryId,{oq:D,lastDiff:P,diff:A})}}}),x.size&&x.forEach(function(C,A){var P=C.oq,D=C.lastDiff,B=C.diff,R;
46if(g){if(!B){var N=P.queryInfo;N.reset(),B=N.getDiff()}R=g(P,B,D)}(!g||R===!0)&&(R=P.refetch()),R!==!1&&T.set(P,R),A.indexOf("legacyOneTimeQuery")>=0&&n.stopQueryNoBroadcast(A)}),m&&this.cache.removeOptimistic(m),T},e.prototype.fetchQueryByPolicy=function(t,n,r){var i=this,s=n.query,c=n.variables,a=n.fetchPolicy,m=n.refetchWritePolicy,g=n.errorPolicy,x=n.returnPartialData,T=n.context,C=n.notifyOnNetworkStatusChange,A=t.networkStatus;t.init({document:s,variables:c,networkStatus:r});var P=function(){return t.getDiff()},D=function(U,W){W===void 0&&(W=t.networkStatus||Ii.loading);var Q=U.result;globalThis.__DEV__!==!1&&!x&&!To(Q,{})&&bz(U.missing);var Z=function(K){return Oi.of(Lt({data:K,loading:U_(W),networkStatus:W},U.complete?null:{partial:!0}))};return Q&&i.getDocumentInfo(s).hasForcedResolvers?i.localState.runResolvers({document:s,remoteResult:{data:Q},context:T,variables:c,onlyRunForcedResolvers:!0}).then(function(K){return Z(K.data||void 0)}):g==="none"&&W===Ii.refetch&&Array.isArray(U.missing)?Z(void 0):Z(Q)},B=a==="no-cache"?0:r===Ii.refetch&&m!=="merge"?1:2,R=function(){return i.getResultsFromLink(t,B,{query:s,variables:c,context:T,fetchPolicy:a,errorPolicy:g})},N=C&&typeof A=="number"&&A!==r&&U_(r);switch(a){default:case"cache-first":{var j=P();return j.complete?{fromLink:!1,sources:[D(j,t.markReady())]}:x||N?{fromLink:!0,sources:[D(j),R()]}:{fromLink:!0,sources:[R()]}}case"cache-and-network":{var j=P();return j.complete||x||N?{fromLink:!0,sources:[D(j),R()]}:{fromLink:!0,sources:[R()]}}case"cache-only":return{fromLink:!1,sources:[D(P(),t.markReady())]};case"network-only":return N?{fromLink:!0,sources:[D(P()),R()]}:{fromLink:!0,sources:[R()]};case"no-cache":return N?{fromLink:!0,sources:[D(t.getDiff()),R()]}:{fromLink:!0,sources:[R()]};case"standby":return{fromLink:!1,sources:[]}}},e.prototype.getQuery=function(t){return t&&!this.queries.has(t)&&this.queries.set(t,new DT(this,t)),this.queries.get(t)},e.prototype.prepareContext=function(t){t===void 0&&(t={});var n=this.localState.prepareContext(t);return Lt(Lt({},n),{clientAwareness:this.clientAwareness})},e}(),pD=!1,VZ=function(){function e(t){var n=this;if(this.resetStoreCallbacks=[],this.clearStoreCallbacks=[],!t.cache)throw vs(15);var r=t.uri,i=t.credentials,s=t.headers,c=t.cache,a=t.documentTransform,m=t.ssrMode,g=m===void 0?!1:m,x=t.ssrForceFetchDelay,T=x===void 0?0:x,C=t.connectToDevTools,A=C===void 0?typeof window=="object"&&!window.__APOLLO_CLIENT__&&globalThis.__DEV__!==!1:C,P=t.queryDeduplication,D=P===void 0?!0:P,B=t.defaultOptions,R=t.assumeImmutableResults,N=R===void 0?c.assumeImmutableResults:R,j=t.resolvers,U=t.typeDefs,W=t.fragmentMatcher,Q=t.name,Z=t.version,K=t.link;K||(K=r?new JY({uri:r,credentials:i,headers:s}):Oc.empty()),this.link=K,this.cache=c,this.disableNetworkFetches=g||T>0,this.queryDeduplication=D,this.defaultOptions=B||Object.create(null),this.typeDefs=U,T&&setTimeout(function(){return n.disableNetworkFetches=!1},T),this.watchQuery=this.watchQuery.bind(this),this.query=this.query.bind(this),this.mutate=this.mutate.bind(this),this.resetStore=this.resetStore.bind(this),this.reFetchObservableQueries=this.reFetchObservableQueries.bind(this),this.version=kk,this.localState=new xz({cache:c,client:this,resolvers:j,fragmentMatcher:W}),this.queryManager=new UZ({cache:this.cache,link:this.link,defaultOptions:this.defaultOptions,documentTransform:a,queryDeduplication:D,ssrMode:g,clientAwareness:{name:Q,version:Z},localState:this.localState,assumeImmutableResults:N,onBroadcast:A?function(){n.devToolsHookCb&&n.devToolsHookCb({action:{},state:{queries:n.queryManager.getQueryStore(),mutations:n.queryManager.mutationStore||{}},dataWithOptimisticResults:n.cache.extract(!0)})}:void 0}),A&&this.connectToDevTools()}return e.prototype.connectToDevTools=function(){if(typeof window=="object"){var t=window,n=Symbol.for("apollo.devtools");(t[n]=t[n]||[]).push(this),t.__APOLLO_CLIENT__=this}!pD&&globalThis.__DEV__!==!1&&(pD=!0,setTimeout(function(){if(typeof window<"u"&&window.document&&window.top===window.self&&!window.__APOLLO_DEVTOOLS_GLOBAL_HOOK__){var r=window.navigator,i=r&&r.userAgent,s=void 0;typeof i=="string"&&(i.indexOf("Chrome/")>-1?s="https://chrome.google.com/webstore/detail/apollo-client-developer-t/jdkknkkbebbapilgoeccciglkfbmbnfm":i.indexOf("Firefox/")>-1&&(s="https://addons.mozilla.org/en-US/firefox/addon/apollo-developer-tools/")),s&&globalThis.__DEV__!==!1&&hr.log("Download the Apollo DevTools for a better development experience: %s",s)}},1e4))},Object.defineProperty(e.prototype,"documentTransform",{get:function(){return this.queryManager.documentTransform}
46,enumerable:!1,configurable:!0}),e.prototype.stop=function(){this.queryManager.stop()},e.prototype.watchQuery=function(t){return this.defaultOptions.watchQuery&&(t=ET(this.defaultOptions.watchQuery,t)),this.disableNetworkFetches&&(t.fetchPolicy==="network-only"||t.fetchPolicy==="cache-and-network")&&(t=Lt(Lt({},t),{fetchPolicy:"cache-first"})),this.queryManager.watchQuery(t)},e.prototype.query=function(t){return this.defaultOptions.query&&(t=ET(this.defaultOptions.query,t)),hr(t.fetchPolicy!=="cache-and-network",16),this.disableNetworkFetches&&t.fetchPolicy==="network-only"&&(t=Lt(Lt({},t),{fetchPolicy:"cache-first"})),this.queryManager.query(t)},e.prototype.mutate=function(t){return this.defaultOptions.mutate&&(t=ET(this.defaultOptions.mutate,t)),this.queryManager.mutate(t)},e.prototype.subscribe=function(t){return this.queryManager.startGraphQLSubscription(t)},e.prototype.readQuery=function(t,n){return n===void 0&&(n=!1),this.cache.readQuery(t,n)},e.prototype.readFragment=function(t,n){return n===void 0&&(n=!1),this.cache.readFragment(t,n)},e.prototype.writeQuery=function(t){var n=this.cache.writeQuery(t);return t.broadcast!==!1&&this.queryManager.broadcastQueries(),n},e.prototype.writeFragment=function(t){var n=this.cache.writeFragment(t);return t.broadcast!==!1&&this.queryManager.broadcastQueries(),n},e.prototype.__actionHookForDevTools=function(t){this.devToolsHookCb=t},e.prototype.__requestRaw=function(t){return wS(this.link,t)},e.prototype.resetStore=function(){var t=this;return Promise.resolve().then(function(){return t.queryManager.clearStore({discardWatches:!1})}).then(function(){return Promise.all(t.resetStoreCallbacks.map(function(n){return n()}))}).then(function(){return t.reFetchObservableQueries()})},e.prototype.clearStore=function(){var t=this;return Promise.resolve().then(function(){return t.queryManager.clearStore({discardWatches:!0})}).then(function(){return Promise.all(t.clearStoreCallbacks.map(function(n){return n()}))})},e.prototype.onResetStore=function(t){var n=this;return this.resetStoreCallbacks.push(t),function(){n.resetStoreCallbacks=n.resetStoreCallbacks.filter(function(r){return r!==t})}},e.prototype.onClearStore=function(t){var n=this;return this.clearStoreCallbacks.push(t),function(){n.clearStoreCallbacks=n.clearStoreCallbacks.filter(function(r){return r!==t})}},e.prototype.reFetchObservableQueries=function(t){return this.queryManager.reFetchObservableQueries(t)},e.prototype.refetchQueries=function(t){var n=this.queryManager.refetchQueries(t),r=[],i=[];n.forEach(function(c,a){r.push(a),i.push(c)});var s=Promise.all(i);return s.queries=r,s.results=i,s.catch(function(c){globalThis.__DEV__!==!1&&hr.debug(17,c)}),s},e.prototype.getObservableQueries=function(t){return t===void 0&&(t="active"),this.queryManager.getObservableQueries(t)},e.prototype.extract=function(t){return this.cache.extract(t)},e.prototype.restore=function(t){return this.cache.restore(t)},e.prototype.addResolvers=function(t){this.localState.addResolvers(t)},e.prototype.setResolvers=function(t){this.localState.setResolvers(t)},e.prototype.getResolvers=function(){return this.localState.getResolvers()},e.prototype.setLocalStateFragmentMatcher=function(t){this.localState.setFragmentMatcher(t)},e.prototype.setLink=function(t){this.link=this.queryManager.link=t},e}(),GZ=Symbol("apollo-clients");function qZ(e){return Xi(e)&&"code"in e&&"reason"in e}function WZ(e){var t;return Xi(e)&&((t=e.target)===null||t===void 0?void 0:t.readyState)===WebSocket.CLOSED}var HZ=function(e){Kl(t,e);function t(n){var r=e.call(this)||this;return r.client=n,r}return t.prototype.request=function(n){var r=this;return new Oi(function(i){return r.client.subscribe(Lt(Lt({},n),{query:Dk(n.query)}),{next:i.next.bind(i),complete:i.complete.bind(i),error:function(s){if(s instanceof Error)return i.error(s);var c=qZ(s);return c||WZ(s)?i.error(new Error("Socket closed".concat(c?" with event ".concat(s.code):"").concat(c?" ".concat(s.reason):""))):i.error(new Nf({graphQLErrors:Array.isArray(s)?s:[s]}))}})})},t}(Oc);function YZ(e){return new Oc(function(t,n){var r=rh(t,[]);return new Oi(function(i){var s,c=!1;return Promise.resolve(r).then(function(a){return e(a,t.getContext())}).then(t.setContext).then(function(){c||(s=n(t).subscribe({next:i.next.bind(i),error:i.error.bind(i),complete:i.complete.bind(i)}))}).catch(i.error.bind(i)),function(){c=!0,s&&s.unsubscribe()}})})}function Os(e){return e===null?"null":Array.isArray(e)?"array":typeof e}function $f(e){return Os(e)==="object"}function ZZ(e){return Array.isArray(e)&&e.length>0&&e.every(t=>"message"in t)}function mD(e,t){return e.length<124?e:t}const XZ="graphql-transport-ws";var ll;(function(e){e[e.InternalServerError=4500]="InternalServerError",e[e.InternalClientError=4005]="InternalClientError",e[e.BadRequest=4400]="BadRequest",e[e.BadResponse=4004]="BadResponse",e[e.Unauthorized=4401]="Unauthorized",e[e.Forbidden=4403]="Forbidden",e[e.SubprotocolNotAcceptable=4406]="SubprotocolNotAcceptable",e[e.ConnectionInitialisationTimeout=4408]="ConnectionInitialisationTimeout",e[e.ConnectionAcknowledgementTimeout=4504]="ConnectionAcknowledgementTimeout",e[e.SubscriberAlreadyExists=4409]="SubscriberAlreadyExists",e[e.TooManyInitialisationRequests=4429]="TooManyInitialisationRequests"})(ll||(ll={}));var zo;(function(e){e.ConnectionInit="connection_init",e.ConnectionAck="connection_ack",e.Ping="ping",e.Pong="pong",e.Subscribe="subscribe",e.Next="next",e.Error="error",e.Complete="complete"})(zo||(zo={}));function wz(e){if(!$f(e))throw new Error(`Message is expected to be an object, but got ${Os(e)}`);
46if(!e.type)throw new Error("Message is missing the 'type' property");if(typeof e.type!="string")throw new Error(`Message is expects the 'type' property to be a string, but got ${Os(e.type)}`);switch(e.type){case zo.ConnectionInit:case zo.ConnectionAck:case zo.Ping:case zo.Pong:{if(e.payload!=null&&!$f(e.payload))throw new Error(`"${e.type}" message expects the 'payload' property to be an object or nullish or missing, but got "${e.payload}"`);break}case zo.Subscribe:{if(typeof e.id!="string")throw new Error(`"${e.type}" message expects the 'id' property to be a string, but got ${Os(e.id)}`);if(!e.id)throw new Error(`"${e.type}" message requires a non-empty 'id' property`);if(!$f(e.payload))throw new Error(`"${e.type}" message expects the 'payload' property to be an object, but got ${Os(e.payload)}`);if(typeof e.payload.query!="string")throw new Error(`"${e.type}" message payload expects the 'query' property to be a string, but got ${Os(e.payload.query)}`);if(e.payload.variables!=null&&!$f(e.payload.variables))throw new Error(`"${e.type}" message payload expects the 'variables' property to be a an object or nullish or missing, but got ${Os(e.payload.variables)}`);if(e.payload.operationName!=null&&Os(e.payload.operationName)!=="string")throw new Error(`"${e.type}" message payload expects the 'operationName' property to be a string or nullish or missing, but got ${Os(e.payload.operationName)}`);if(e.payload.extensions!=null&&!$f(e.payload.extensions))throw new Error(`"${e.type}" message payload expects the 'extensions' property to be a an object or nullish or missing, but got ${Os(e.payload.extensions)}`);break}case zo.Next:{if(typeof e.id!="string")throw new Error(`"${e.type}" message expects the 'id' property to be a string, but got ${Os(e.id)}`);if(!e.id)throw new Error(`"${e.type}" message requires a non-empty 'id' property`);if(!$f(e.payload))throw new Error(`"${e.type}" message expects the 'payload' property to be an object, but got ${Os(e.payload)}`);break}case zo.Error:{if(typeof e.id!="string")throw new Error(`"${e.type}" message expects the 'id' property to be a string, but got ${Os(e.id)}`);if(!e.id)throw new Error(`"${e.type}" message requires a non-empty 'id' property`);if(!ZZ(e.payload))throw new Error(`"${e.type}" message expects the 'payload' property to be an array of GraphQL errors, but got ${JSON.stringify(e.payload)}`);break}case zo.Complete:{if(typeof e.id!="string")throw new Error(`"${e.type}" message expects the 'id' property to be a string, but got ${Os(e.id)}`);if(!e.id)throw new Error(`"${e.type}" message requires a non-empty 'id' property`);break}default:throw new Error(`Invalid message 'type' property "${e.type}"`)}return e}function KZ(e,t){return wz(typeof e=="string"?JSON.parse(e,t):e)}function Uy(e,t){return wz(e),JSON.stringify(e,t)}var Um=globalThis&&globalThis.__await||function(e){return this instanceof Um?(this.v=e,this):new Um(e)},QZ=globalThis&&globalThis.__asyncGenerator||function(e,t,n){if(!Symbol.asyncIterator)throw new TypeError("Symbol.asyncIterator is not defined.");var r=n.apply(e,t||[]),i,s=[];return i={},c("next"),c("throw"),c("return"),i[Symbol.asyncIterator]=function(){return this},i;function c(C){r[C]&&(i[C]=function(A){return new Promise(function(P,D){s.push([C,A,P,D])>1||a(C,A)})})}function a(C,A){try{m(r[C](A))}catch(P){T(s[0][3],P)}}function m(C){C.value instanceof Um?Promise.resolve(C.value.v).then(g,x):T(s[0][2],C)}function g(C){a("next",C)}function x(C){a("throw",C)}function T(C,A){C(A),s.shift(),s.length&&a(s[0][0],s[0][1])}};function JZ(e){const{url:t,connectionParams:n,lazy:r=!0,onNonLazyError:i=console.error,lazyCloseTimeout:s=0,keepAlive:c=0,disablePong:a,connectionAckWaitTimeout:m=0,retryAttempts:g=5,retryWait:x=async function(xe){let Te=1e3;for(let oe=0;oe<xe;oe++)Te*=2;await new Promise(oe=>setTimeout(oe,Te+Math.floor(Math.random()*(3e3-300)+300)))},shouldRetry:T=rb,isFatalConnectionProblem:C,on:A,webSocketImpl:P,generateID:D=function(){return"xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g,xe=>{const Te=Math.random()*16|0;return(xe=="x"?Te:Te&3|8).toString(16)})},jsonMessageReplacer:B,jsonMessageReviver:R}=e;let N;if(P){if(!tX(P))throw new Error("Invalid WebSocket implementation provided");N=P}else typeof WebSocket<"u"?N=WebSocket:typeof global<"u"?N=global.WebSocket||global.MozWebSocket:typeof window<"u"&&(N=window.WebSocket||window.MozWebSocket);if(!N)throw new Error("WebSocket implementation missing; on Node you can `import WebSocket from 'ws';` and pass `webSocketImpl: WebSocket` to `createClient`");const j=N,U=(()=>{const ie=(()=>{const Te={};return{on(oe,ne){return Te[oe]=ne,()=>{delete Te[oe]}},emit(oe){var ne;"id"in oe&&((ne=Te[oe.id])===null||ne===void 0||ne.call(Te,oe))}}})(),xe={connecting:A!=null&&A.connecting?[A.connecting]:[],opened:A!=null&&A.opened?[A.opened]:[],connected:A!=null&&A.connected?[A.connected]:[],ping:A!=null&&A.ping?[A.ping]:[],pong:A!=null&&A.pong?[A.pong]:[],message:A!=null&&A.message?[ie.emit,A.message]:[ie.emit],closed:A!=null&&A.closed?[A.closed]:[],error:A!=null&&A.error?[A.error]:[]};return{onMessage:ie.on,on(Te,oe){const ne=xe[Te];return ne.push(oe),()=>{ne.splice(ne.indexOf(oe),1)}},emit(Te,...oe){for(const ne of[...xe[Te]])ne(...oe)}}})();function W(ie){const xe=[U.on("error",Te=>{xe.forEach(oe=>oe()),ie(Te)}),U.on("closed",Te=>{xe.forEach(oe=>oe()),ie(Te)})]}let Q,Z=0,K,Y=!1,me=0,ge=!1;async function ce(){clearTimeout(K);const[ie,xe]=await(Q??(Q=new Promise((ne,le)=>(async()=>
46{if(Y){if(await x(me),!Z)return Q=void 0,le({code:1e3,reason:"All Subscriptions Gone"});me++}U.emit("connecting");const se=new j(typeof t=="function"?await t():t,XZ);let Ne,Se;function xt(){isFinite(c)&&c>0&&(clearTimeout(Se),Se=setTimeout(()=>{se.readyState===j.OPEN&&(se.send(Uy({type:zo.Ping})),U.emit("ping",!1,void 0))},c))}W(wt=>{Q=void 0,clearTimeout(Ne),clearTimeout(Se),le(wt),rb(wt)&&wt.code===4499&&(se.close(4499,"Terminated"),se.onerror=null,se.onclose=null)}),se.onerror=wt=>U.emit("error",wt),se.onclose=wt=>U.emit("closed",wt),se.onopen=async()=>{try{U.emit("opened",se);const wt=typeof n=="function"?await n():n;if(se.readyState!==j.OPEN)return;se.send(Uy(wt?{type:zo.ConnectionInit,payload:wt}:{type:zo.ConnectionInit},B)),isFinite(m)&&m>0&&(Ne=setTimeout(()=>{se.close(ll.ConnectionAcknowledgementTimeout,"Connection acknowledgement timeout")},m)),xt()}catch(wt){U.emit("error",wt),se.close(ll.InternalClientError,mD(wt instanceof Error?wt.message:new Error(wt).message,"Internal client error"))}};let kt=!1;se.onmessage=({data:wt})=>{try{const Ue=KZ(wt,R);if(U.emit("message",Ue),Ue.type==="ping"||Ue.type==="pong"){U.emit(Ue.type,!0,Ue.payload),Ue.type==="pong"?xt():a||(se.send(Uy(Ue.payload?{type:zo.Pong,payload:Ue.payload}:{type:zo.Pong})),U.emit("pong",!1,Ue.payload));return}if(kt)return;if(Ue.type!==zo.ConnectionAck)throw new Error(`First message cannot be of type ${Ue.type}`);clearTimeout(Ne),kt=!0,U.emit("connected",se,Ue.payload),Y=!1,me=0,ne([se,new Promise((je,st)=>W(st))])}catch(Ue){se.onmessage=null,U.emit("error",Ue),se.close(ll.BadResponse,mD(Ue instanceof Error?Ue.message:new Error(Ue).message,"Bad response"))}}})())));ie.readyState===j.CLOSING&&await xe;let Te=()=>{};const oe=new Promise(ne=>Te=ne);return[ie,Te,Promise.race([oe.then(()=>{if(!Z){const ne=()=>ie.close(1e3,"Normal Closure");isFinite(s)&&s>0?K=setTimeout(()=>{ie.readyState===j.OPEN&&ne()},s):ne()}}),xe])]}function fe(ie){if(rb(ie)&&(eX(ie.code)||[ll.InternalServerError,ll.InternalClientError,ll.BadRequest,ll.BadResponse,ll.Unauthorized,ll.SubprotocolNotAcceptable,ll.SubscriberAlreadyExists,ll.TooManyInitialisationRequests].includes(ie.code)))throw ie;if(ge)return!1;if(rb(ie)&&ie.code===1e3)return Z>0;if(!g||me>=g||!T(ie)||C!=null&&C(ie))throw ie;return Y=!0}return r||(async()=>{for(Z++;;)try{const[,,ie]=await ce();await ie}catch(ie){try{if(!fe(ie))return}catch(xe){return i==null?void 0:i(xe)}}})(),{on:U.on,subscribe(ie,xe){const Te=D(ie);let oe=!1,ne=!1,le=()=>{Z--,oe=!0};return(async()=>{for(Z++;;)try{const[se,Ne,Se]=await ce();if(oe)return Ne();const xt=U.onMessage(Te,kt=>{switch(kt.type){case zo.Next:{xe.next(kt.payload);return}case zo.Error:{ne=!0,oe=!0,xe.error(kt.payload),le();return}case zo.Complete:{oe=!0,le();return}}});se.send(Uy({id:Te,type:zo.Subscribe,payload:ie},B)),le=()=>{!oe&&se.readyState===j.OPEN&&se.send(Uy({id:Te,type:zo.Complete},B)),Z--,oe=!0,Ne()},await Se.finally(xt);return}catch(se){if(!fe(se))return}})().then(()=>{ne||xe.complete()}).catch(se=>{xe.error(se)}),()=>{oe||le()}},iterate(ie){const xe=[],Te={done:!1,error:null,resolve:()=>{}},oe=this.subscribe(ie,{next(le){xe.push(le),Te.resolve()},error(le){Te.done=!0,Te.error=le,Te.resolve()},complete(){Te.done=!0,Te.resolve()}}),ne=function(){return QZ(this,arguments,function*(){for(;;){for(xe.length||(yield Um(new Promise(Ne=>Te.resolve=Ne)));xe.length;)yield yield Um(xe.shift());if(Te.error)throw Te.error;if(Te.done)return yield Um(void 0)}})}();return ne.throw=async le=>(Te.done||(Te.done=!0,Te.error=le,Te.resolve()),{done:!0,value:void 0}),ne.return=async()=>(oe(),{done:!0,value:void 0}),ne},async dispose(){if(ge=!0,Q){const[ie]=await Q;ie.close(1e3,"Normal Closure")}},terminate(){Q&&U.emit("closed",{code:4499,reason:"Terminated",wasClean:!1})}}}function rb(e){return $f(e)&&"code"in e&&"reason"in e}function eX(e){return[1e3,1001,1006,1005,1012,1013,1014].includes(e)?!1:e>=1e3&&e<=1999}function tX(e){return typeof e=="function"&&"constructor"in e&&"CLOSED"in e&&"CLOSING"in e&&"CONNECTING"in e&&"OPEN"in e}function nX(e){let t=!1,n=()=>{t=!0};return{...JZ({...e,on:{...e.on,opened:i=>{var s,c;(c=(s=e.on)==null?void 0:s.opened)==null||c.call(s,i),n=()=>{i.readyState===WebSocket.OPEN?i.close(4205,"Client Restart"):t=!0},t&&(t=!1,n())}}}),restart:()=>n()}}const ps={proxyCookies:!0,clientAwareness:!1,cookieAttributes:{maxAge:604800,secure:!0},clients:{wp:{httpEndpoint:"https://wp.brik.id/graphql",authType:"Bearer",authHeader:"Authorization",tokenName:"apollo:wp.token",tokenStorage:"cookie"}}};function P_e(...e){const{key:t,fn:n}=rX(...e);return k7(t,n,"$WvHsgSk08j")}const rX=(...e)=>{var g,x,T,C,A,P;const{clients:t}=Tz(),n=((g=e==null?void 0:e[0])==null?void 0:g.query)||(e==null?void 0:e[0]),r=((x=e==null?void 0:e[0])==null?void 0:x.cache)??!0,i=((T=e==null?void 0:e[0])==null?void 0:T.variables)||typeof(e==null?void 0:e[1])!="string"&&(e==null?void 0:e[1])||void 0,s=(C=e==null?void 0:e[0])==null?void 0:C.context;let c=((A=e==null?void 0:e[0])==null?void 0:A.clientId)||typeof(e==null?void 0:e[1])=="string"&&(e==null?void 0:e[1])||void 0;return(!c||!(t!=null&&t[c]))&&(c=t!=null&&t.default?"default":Object.keys(t)[0]),{key:((P=e==null?void 0:e[0])==null?void 0:P.key)||$7({query:LB(n),variables:i,clientId:c}),query:n,clientId:c,variables:i,fn:()=>{var D;return(D=t[c])==null?void 0:D.query({query:n,variables:i,fetchPolicy:r?"cache-first":"no-cache",context:s}).then(B=>B.data)}}},Tz=()=>{const e=qo(),t=async r=>{var a;r=r||"default";const i=(a=ps==null?void 0:ps.clients)==null?void 0:a[r],s=jt(null);
46if(await e.callHook("apollo:auth",{token:s,client:r}),s.value)return s.value;const c=i.tokenName;return(i==null?void 0:i.tokenStorage)==="cookie"?uS(c).value:localStorage.getItem(c)||null},n=async({token:r,client:i,mode:s,skipResetStore:c})=>{var g,x,T;i=i||"default";const a=(g=ps==null?void 0:ps.clients)==null?void 0:g[i],m=i&&a.tokenName;if((a==null?void 0:a.tokenStorage)==="cookie"){const C=i&&(a==null?void 0:a.cookieAttributes)||(ps==null?void 0:ps.cookieAttributes),A=uS(m,C);if(!A.value&&s==="logout")return;A.value=s==="login"&&r||null}else(a==null?void 0:a.tokenStorage)==="localStorage"&&(s==="login"&&r?localStorage.setItem(m,r):s==="logout"&&localStorage.removeItem(m));(x=e==null?void 0:e._apolloWsClients)!=null&&x[i]&&e._apolloWsClients[i].restart(),!c&&await((T=e==null?void 0:e._apolloClients)==null?void 0:T[i].resetStore().catch(C=>console.log("%cError on cache reset","color: orange;",C.message)))};return{getToken:t,clients:e==null?void 0:e._apolloClients,onLogin:(r,i,s)=>n({token:r,client:i,skipResetStore:s,mode:"login"}),onLogout:(r,i)=>n({client:r,skipResetStore:i,mode:"logout"})}},iX=Gi(e=>{var i,s;const n={};for(const[c,a]of Object.entries(ps.clients)){const m=async()=>{var N,j;const B=jt();return await e.callHook("apollo:auth",{token:B,client:c}),!B.value&&(a.tokenStorage==="cookie"?B.value=uS(a.tokenName).value:a.tokenStorage==="localStorage"&&(B.value=localStorage.getItem(a.tokenName)),!B.value)?void 0:!!((j=(N=B.value)==null?void 0:N.match(/^[a-zA-Z]+\s/))!=null&&j[0])||(a==null?void 0:a.authType)===null?B.value:`${a==null?void 0:a.authType} ${B.value}`},x=YZ(async(B,{headers:R})=>{const N=await m();if(N)return{headers:{...R,[a.authHeader]:N}}}).concat(XB({...(a==null?void 0:a.httpLinkOptions)&&a.httpLinkOptions,uri:a.browserHttpEndpoint||a.httpEndpoint,headers:{...((i=a==null?void 0:a.httpLinkOptions)==null?void 0:i.headers)||{}}}));let T=null;if(a.wsEndpoint){const B=nX({...a.wsLinkOptions,url:a.wsEndpoint,connectionParams:async()=>{const R=await m();if(R)return{[a.authHeader]:R}}});T=new HZ(B),e._apolloWsClients=e._apolloWsClients||{},e._apolloWsClients[c]=B}const C=YB(B=>{e.callHook("apollo:error",B)}),A=Oc.from([C,...T?[...a!=null&&a.websocketsOnly?[T]:[SY(({query:B})=>{const R=Cg(B);return R.kind==="OperationDefinition"&&R.operation==="subscription"},T,x)]]:[x]]),P=new FZ(a.inMemoryCacheOptions);n[c]=new VZ({link:A,cache:P,...ps.clientAwareness,ssrForceFetchDelay:100,connectToDevTools:a.connectToDevTools||!1,defaultOptions:a==null?void 0:a.defaultOptions}),!(n!=null&&n.default)&&!((s=ps==null?void 0:ps.clients)!=null&&s.default)&&c===Object.keys(ps.clients)[0]&&(n.default=n[c]);const D=`_apollo:${c}`;e.hook("app:rendered",()=>{e.payload.data[D]=P.extract()}),e.payload.data[D]&&P.restore(u9(JSON.stringify(e.payload.data[D])))}e.vueApp.provide(GZ,n),e._apolloClients=n;const r=n==null?void 0:n.default;return{provide:{apolloHelpers:Tz(),apollo:{clients:n,defaultClient:r}}}}),oX=/(android|bb\d+|meego).+mobile|avantgo|bada\/|blackberry|blazer|compal|elaine|FBAN|FBAV|fennec|hiptop|iemobile|ip(hone|od)|Instagram|iris|kindle|lge |maemo|midp|mmp|mobile.+firefox|netfront|opera m(ob|in)i|palm( os)?|phone|p(ixi|re)\/|plucker|pocket|psp|series(4|6)0|symbian|treo|up\.(browser|link)|vodafone|wap|windows ce|xda|xiino/i,aX=/1207|6310|6590|3gso|4thp|50[1-6]i|770s|802s|a wa|abac|ac(er|oo|s\-)|ai(ko|rn)|al(av|ca|co)|amoi|an(ex|ny|yw)|aptu|ar(ch|go)|as(te|us)|attw|au(di|\-m|r |s )|avan|be(ck|ll|nq)|bi(lb|rd)|bl(ac|az)|br(e|v)w|bumb|bw\-(n|u)|c55\/|capi|ccwa|cdm\-|cell|chtm|cldc|cmd\-|co(mp|nd)|craw|da(it|ll|ng)|dbte|dc\-s|devi|dica|dmob|do(c|p)o|ds(12|\-d)|el(49|ai)|em(l2|ul)|er(ic|k0)|esl8|ez([4-7]0|os|wa|ze)|fetc|fly(\-|_)|g1 u|g560|gene|gf\-5|g\-mo|go(\.w|od)|gr(ad|un)|haie|hcit|hd\-(m|p|t)|hei\-|hi(pt|ta)|hp( i|ip)|hs\-c|ht(c(\-| |_|a|g|p|s|t)|tp)|hu(aw|tc)|i\-(20|go|ma)|i230|iac( |\-|\/)|ibro|idea|ig01|ikom|im1k|inno|ipaq|iris|ja(t|v)a|jbro|jemu|jigs|kddi|keji|kgt( |\/)|klon|kpt |kwc\-|kyo(c|k)|le(no|xi)|lg( g|\/(k|l|u)|50|54|\-[a-w])|libw|lynx|m1\-w|m3ga|m50\/|ma(te|ui|xo)|mc(01|21|ca)|m\-cr|me(rc|ri)|mi(o8|oa|ts)|mmef|mo(01|02|bi|de|do|t(\-| |o|v)|zz)|mt(50|p1|v )|mwbp|mywa|n10[0-2]|n20[2-3]|n30(0|2)|n50(0|2|5)|n7(0(0|1)|10)|ne((c|m)\-|on|tf|wf|wg|wt)|nok(6|i)|nzph|o2im|op(ti|wv)|oran|owg1|p800|pan(a|d|t)|pdxg|pg(13|\-([1-8]|c))|phil|pire|pl(ay|uc)|pn\-2|po(ck|rt|se)|prox|psio|pt\-g|qa\-a|qc(07|12|21|32|60|\-[2-7]|i\-)|qtek|r380|r600|raks|rim9|ro(ve|zo)|s55\/|sa(ge|ma|mm|ms|ny|va)|sc(01|h\-|oo|p\-)|sdk\/|se(c(\-|0|1)|47|mc|nd|ri)|sgh\-|shar|sie(\-|m)|sk\-0|sl(45|id)|sm(al|ar|b3|it|t5)|so(ft|ny)|sp(01|h\-|v\-|v )|
46sy(01|mb)|t2(18|50)|t6(00|10|18)|ta(gt|lk)|tcl\-|tdg\-|tel(i|m)|tim\-|t\-mo|to(pl|sh)|ts(70|m\-|m3|m5)|tx\-9|up(\.b|g1|si)|utst|v400|v750|veri|vi(rg|te)|vk(40|5[0-3]|\-v)|vm40|voda|vulc|vx(52|53|60|61|70|80|81|83|85|98)|w3c(\-| )|webc|whit|wi(g |nc|nw)|wmlb|wonu|x700|yas\-|your|zeto|zte\-/i;function sX(e){return oX.test(e)||aX.test(e.slice(0,4))}const lX=/(android|bb\d+|meego).+mobile|avantgo|bada\/|blackberry|blazer|compal|elaine|FBAN|FBAV|fennec|hiptop|iemobile|ip(hone|od)|Instagram|iris|kindle|lge |maemo|midp|mmp|mobile.+firefox|netfront|opera m(ob|in)i|palm( os)?|phone|p(ixi|re)\/|plucker|pocket|psp|series(4|6)0|symbian|treo|up\.(browser|link)|vodafone|wap|windows ce|xda|xiino|android|ipad|playbook|silk/i,cX=/1207|6310|6590|3gso|4thp|50[1-6]i|770s|802s|a wa|abac|ac(er|oo|s\-)|ai(ko|rn)|al(av|ca|co)|amoi|an(ex|ny|yw)|aptu|ar(ch|go)|as(te|us)|attw|au(di|\-m|r |s )|avan|be(ck|ll|nq)|bi(lb|rd)|bl(ac|az)|br(e|v)w|bumb|bw\-(n|u)|c55\/|capi|ccwa|cdm\-|cell|chtm|cldc|cmd\-|co(mp|nd)|craw|da(it|ll|ng)|dbte|dc\-s|devi|dica|dmob|do(c|p)o|ds(12|\-d)|el(49|ai)|em(l2|ul)|er(ic|k0)|esl8|ez([4-7]0|os|wa|ze)|fetc|fly(\-|_)|g1 u|g560|gene|gf\-5|g\-mo|go(\.w|od)|gr(ad|un)|haie|hcit|hd\-(m|p|t)|hei\-|hi(pt|ta)|hp( i|ip)|hs\-c|ht(c(\-| |_|a|g|p|s|t)|tp)|hu(aw|tc)|i\-(20|go|ma)|i230|iac( |\-|\/)|ibro|idea|ig01|ikom|im1k|inno|ipaq|iris|ja(t|v)a|jbro|jemu|jigs|kddi|keji|kgt( |\/)|klon|kpt |kwc\-|kyo(c|k)|le(no|xi)|lg( g|\/(k|l|u)|50|54|\-[a-w])|libw|lynx|m1\-w|m3ga|m50\/|ma(te|ui|xo)|mc(01|21|ca)|m\-cr|me(rc|ri)|mi(o8|oa|ts)|mmef|mo(01|02|bi|de|do|t(\-| |o|v)|zz)|mt(50|p1|v )|mwbp|mywa|n10[0-2]|n20[2-3]|n30(0|2)|n50(0|2|5)|n7(0(0|1)|10)|ne((c|m)\-|on|tf|wf|wg|wt)|nok(6|i)|nzph|o2im|op(ti|wv)|oran|owg1|p800|pan(a|d|t)|pdxg|pg(13|\-([1-8]|c))|phil|pire|pl(ay|uc)|pn\-2|po(ck|rt|se)|prox|psio|pt\-g|qa\-a|qc(07|12|21|32|60|\-[2-7]|i\-)|qtek|r380|r600|raks|rim9|ro(ve|zo)|s55\/|sa(ge|ma|mm|ms|ny|va)|sc(01|h\-|oo|p\-)|sdk\/|se(c(\-|0|1)|47|mc|nd|ri)|sgh\-|shar|sie(\-|m)|sk\-0|sl(45|id)|sm(al|ar|b3|it|t5)|so(ft|ny)|sp(01|h\-|v\-|v )|sy(01|mb)|t2(18|50)|t6(00|10|18)|ta(gt|lk)|tcl\-|tdg\-|tel(i|m)|tim\-|t\-mo|to(pl|sh)|ts(70|m\-|m3|m5)|tx\-9|up(\.b|g1|si)|utst|v400|v750|veri|vi(rg|te)|vk(40|5[0-3]|\-v)|vm40|voda|vulc|vx(52|53|60|61|70|80|81|83|85|98)|w3c(\-| )|webc|whit|wi(g |nc|nw)|wmlb|wonu|x700|yas\-|your|zeto|zte\-/i,uX=/Googlebot\/|Googlebot-Mobile|Googlebot-Image|Googlebot-News|Googlebot-Video|AdsBot-Google([^-]|$)|AdsBot-Google-Mobile|Feedfetcher-Google|Mediapartners-Google|Mediapartners \(Googlebot\)|APIs-Google|bingbot|Slurp|[wW]get|LinkedInBot|Python-urllib|python-requests|aiohttp|httpx|libwww-perl|httpunit|nutch|Go-http-client|phpcrawl|msnbot|jyxobot|FAST-WebCrawler|FAST Enterprise Crawler|BIGLOTRON|Teoma|convera|seekbot|Gigabot|Gigablast|exabot|ia_archiver|GingerCrawler|webmon |HTTrack|grub.org|UsineNouvelleCrawler|antibot|netresearchserver|speedy|fluffy|findlink|msrbot|panscient|yacybot|AISearchBot|ips-agent|tagoobot|MJ12bot|woriobot|yanga|buzzbot|mlbot|YandexBot|YandexImages|YandexAccessibilityBot|YandexMobileBot|YandexMetrika|YandexTurbo|YandexImageResizer|YandexVideo|YandexAdNet|YandexBlogs|YandexCalendar|YandexDirect|YandexFavicons|YaDirectFetcher|YandexForDomain|YandexMarket|YandexMedia|YandexMobileScreenShotBot|YandexNews|YandexOntoDB|YandexPagechecker|YandexPartner|YandexRCA|YandexSearchShop|YandexSitelinks|YandexSpravBot|YandexTracker|YandexVertis|YandexVerticals|YandexWebmaster|YandexScreenshotBot|purebot|Linguee Bot|CyberPatrol|voilabot|Baiduspider|citeseerxbot|spbot|twengabot|postrank|TurnitinBot|scribdbot|page2rss|sitebot|linkdex|Adidxbot|ezooms|dotbot|Mail.RU_Bot|discobot|heritrix|findthatfile|europarchive.org|NerdByNature.Bot|sistrix crawler|Ahrefs(Bot|SiteAudit)|fuelbot|CrunchBot|IndeedBot|mappydata|woobot|ZoominfoBot|PrivacyAwareBot|Multiviewbot|SWIMGBot|Grobbot|eright|Apercite|semanticbot|Aboundex|domaincrawler|wbsearchbot|summify|CCBot|edisterbot|seznambot|ec2linkfinder|gslfbot|aiHitBot|intelium_bot|facebookexternalhit|Yeti|RetrevoPageAnalyzer|lb-spider|Sogou|lssbot|careerbot|wotbox|wocbot|ichiro|DuckDuckBot|lssrocketcrawler|drupact|webcompanycrawler|acoonbot|openindexspider|gnam gnam spider|web-archive-net.com.bot|backlinkcrawler|coccoc|integromedb|content crawler spider|toplistbot|it2media-domain-crawler|ip-web-crawler.com|siteexplorer.info|elisabot|proximic|changedetection|arabot|WeSEE:Search|niki-bot|CrystalSemanticsBot|rogerbot|360Spider|psbot|InterfaxScanBot|CC Metadata Scaper|g00g1e.net|GrapeshotCrawler|urlappendbot|brainobot|fr-crawler|binlar|SimpleCrawler|Twitterbot|cXensebot|smtbot|bnf.fr_bot|A6-Indexer|ADmantX|Facebot|OrangeBot\/|memorybot|AdvBot|MegaIndex|SemanticScholarBot|ltx71|nerdybot|xovibot|BUbiNG|Qwantify|archive.org_bot|Applebot|TweetmemeBot|crawler4j|findxbot|S[eE][mM]rushBot|yoozBot|lipperhey|Y!J|Domain Re-Animator Bot|AddThis|Screaming Frog SEO Spider|MetaURI|Scrapy|Livelap[bB]ot|OpenHoseBot|CapsuleChecker|[email protected]|IstellaBot|DeuSu\/|betaBot|Cliqzbot\/|MojeekBot\/|netEstate NE Crawler|SafeSearch microdata crawler|Gluten Free Crawler\/|Sonic|Sysomos|Trove|deadlinkchecker|Slack-ImgProxy|Embedly|RankActiveLinkBot|iskanie|SafeDNSBot|SkypeUriPreview|Veoozbot|Slackbot|redditbot|datagnionbot|Google-Adwords-Instant|adbeat_bot|WhatsApp|contxbot|pinterest.com.bot|electricmonk|GarlikCrawler|BingPreview\/|vebidoobot|FemtosearchBot|Yahoo Link Preview|MetaJobBot|DomainStatsBot|mindUpBot|Daum\/|Jugendschutzprogramm-Crawler|Xenu Link Sleuth|Pcore-HTTP|moatbot|KosmioBot|pingdom|AppInsights|PhantomJS|Gowikibot|PiplBot|Discordbot|TelegramBot|Jetslide|newsharecounts|James BOT|Bark[rR]owler|TinEye|SocialRankIOBot|trendictionbot|Ocarinabot|epicbot|Primalbot|DuckDuckGo-Favicons-Bot|GnowitNewsbot|Leikibot|LinkArchiver|YaK\/|PaperLiBot|Digg Deeper|dcrawl|Snacktory|AndersPinkBot|Fyrebot|EveryoneSocialBot|Mediatoolkitbot|Luminator-robots|ExtLinksBot|SurveyBot|NING\/|okhttp|Nuzzel|omgili|PocketParser|YisouSpider|um-LN|ToutiaoSpider|MuckRack|Jamie's Spider|AHC\/|NetcraftSurveyAgent|Laserlikebot|^Apache-HttpClient|AppEngine-Google|Jetty|Upflow|Thinklab|Traackr.com|Twurly|Mastodon|http_get|DnyzBot|botify|007ac9 Crawler|BehloolBot|BrandVerity|check_http|BDCbot|ZumBot|EZID|ICC-Crawler|ArchiveBot|^LCC |filterdb.iss.net\/crawler|BLP_bbot|BomboraBot|Buck\/|Companybook-Crawler|Genieo|magpie-crawler|Meltw
46aterNews|Moreover|newspaper\/|ScoutJet|(^| )sentry\/|StorygizeBot|UptimeRobot|OutclicksBot|seoscanners|Hatena|Google Web Preview|MauiBot|AlphaBot|SBL-BOT|IAS crawler|adscanner|Netvibes|acapbot|Baidu-YunGuanCe|bitlybot|blogmuraBot|Bot.AraTurka.com|bot-pge.chlooe.com|BoxcarBot|BTWebClient|ContextAd Bot|Digincore bot|Disqus|Feedly|Fetch\/|Fever|Flamingo_SearchEngine|FlipboardProxy|g2reader-bot|G2 Web Services|imrbot|K7MLWCBot|Kemvibot|Landau-Media-Spider|linkapediabot|vkShare|Siteimprove.com|BLEXBot\/|DareBoost|ZuperlistBot\/|Miniflux\/|Feedspot|Diffbot\/|SEOkicks|tracemyfile|Nimbostratus-Bot|zgrab|PR-CY.RU|AdsTxtCrawler|Datafeedwatch|Zabbix|TangibleeBot|google-xrawler|axios|Amazon CloudFront|Pulsepoint|CloudFlare-AlwaysOnline|Google-Structured-Data-Testing-Tool|WordupInfoSearch|WebDataStats|HttpUrlConnection|Seekport Crawler|ZoomBot|VelenPublicWebCrawler|MoodleBot|jpg-newsbot|outbrain|W3C_Validator|Validator\.nu|W3C-checklink|W3C-mobileOK|W3C_I18n-Checker|FeedValidator|W3C_CSS_Validator|W3C_Unicorn|Google-PhysicalWeb|Blackboard|ICBot\/|BazQux|Twingly|Rivva|Experibot|awesomecrawler|Dataprovider.com|GroupHigh\/|theoldreader.com|AnyEvent|Uptimebot\.org|Nmap Scripting Engine|2ip.ru|Clickagy|Caliperbot|MBCrawler|online-webceo-bot|B2B Bot|AddSearchBot|Google Favicon|HubSpot|Chrome-Lighthouse|HeadlessChrome|CheckMarkNetwork\/|www\.uptime\.com|Streamline3Bot\/|serpstatbot\/|MixnodeCache\/|^curl|SimpleScraper|RSSingBot|Jooblebot|fedoraplanet|Friendica|NextCloud|Tiny Tiny RSS|RegionStuttgartBot|Bytespider|Datanyze|Google-Site-Verification|TrendsmapResolver|tweetedtimes|NTENTbot|Gwene|SimplePie|SearchAtlas|Superfeedr|feedbot|UT-Dorkbot|Amazonbot|SerendeputyBot|Eyeotabot|officestorebot|Neticle Crawler|SurdotlyBot|LinkisBot|AwarioSmartBot|AwarioRssBot|RyteBot|FreeWebMonitoring SiteChecker|AspiegelBot|NAVER Blog Rssbot|zenback bot|SentiBot|Domains Project\/|Pandalytics|VKRobot|bidswitchbot|tigerbot|NIXStatsbot|Atom Feed Robot|Curebot|PagePeeker\/|Vigil\/|rssbot\/|startmebot\/|JobboerseBot|seewithkids|NINJA bot|Cutbot|BublupBot|BrandONbot|RidderBot|Taboolabot|Dubbotbot|FindITAnswersbot|infoobot|Refindbot|BlogTraffic\/\d\.\d+ Feed-Fetcher|SeobilityBot|Cincraw|Dragonbot|VoluumDSP-content-bot|FreshRSS|BitBot|^PHP-Curl-Class|Google-Certificates-Bridge/;function hX(e){return lX.test(e)||cX.test(e.slice(0,4))}function dX(e){return/iPad|iPhone|iPod/.test(e)}function fX(e){return/android/i.test(e)}function pX(e){return/Windows/.test(e)}function mX(e){return/Mac OS X/.test(e)}const gX=[{name:"Samsung",test:/SamsungBrowser/i},{name:"Edge",test:/edg([ea]|ios|)\//i},{name:"Firefox",test:/firefox|iceweasel|fxios/i},{name:"Chrome",test:/chrome|crios|crmo/i},{name:"Safari",test:/safari|applewebkit/i}];function yX(e){for(const t of gX)if(t.test.test(e))return t.name;return""}function LT(e,t){let n=!1,r=!1,i=!1,s=!1;if(t==="Amazon CloudFront")e["cloudfront-is-mobile-viewer"]==="true"&&(n=!0,r=!0),e["cloudfront-is-tablet-viewer"]==="true"&&(n=!1,r=!0),e["cloudfront-is-desktop-viewer"]==="true"&&(n=!1,r=!1),e["cloudfront-is-ios-viewer"]==="true"&&(i=!0),e["cloudfront-is-android-viewer"]==="true"&&(s=!0);else if(e&&e["cf-device-type"])switch(e["cf-device-type"]){case"mobile":n=!0,r=!0;break;case"tablet":n=!1,r=!0;break;case"desktop":n=!1,r=!1;break}else n=sX(t),r=hX(t),i=dX(t),s=fX(t);const c=pX(t),a=mX(t),m=yX(t),g=m==="Safari",x=m==="Firefox",T=m==="Edge",C=m==="Chrome",A=m==="Samsung",P=uX.test(t);return{userAgent:t,isMobile:n,isMobileOrTablet:r,isTablet:!n&&r,isDesktop:!r,isIos:i,isAndroid:s,isWindows:c,isMacOS:a,isApple:a||i,isDesktopOrTablet:!n,isSafari:g,isFirefox:x,isEdge:T,isChrome:C,isSamsung:A,isCrawler:P}}const _X=Gi(e=>{const t=Eg(),n=t.public.device.defaultUserAgent,r=t.public.device.refreshOnResize;if(e.ssrContext){const c=U7(),a=c["user-agent"]||n;return{provide:{device:so(LT(c,a))}}}const i=navigator.userAgent||n,s=so(LT({},i));return r&&window.addEventListener("resize",()=>{setTimeout(()=>{const c=LT({},navigator.userAgent||n);Object.entries(c).forEach(a=>{const[m,g]=a;s[m]=g})},50)}),{provide:{device:s}}}),vX=Gi({name:"nuxt:chunk-reload",setup(e){const t=Sg(),n=Eg(),r=new Set;t.beforeEach(()=>{r.clear()}),e.hook("app:chunkError",({error:i})=>{r.add(i)}),t.onError((i,s)=>{if(r.has(i)){const a="href"in s&&s.href.startsWith("#")?n.app.baseURL+s.href:Jx(n.app.baseURL,s.fullPath);H7({path:a,persistState:!0})}})}});function Ez(e,t){return function(){return e.apply(t,arguments)}}const{toString:bX}=Object.prototype,{getPrototypeOf:Hk}=Object,h1=(e=>t=>{const n=bX.call(t);return e[n]||(e[n]=n.slice(8,-1).toLowerCase())})(Object.create(null)),vu=e=>(e=e.toLowerCase(),t=>h1(t)===e),d1=e=>t=>typeof t===e,{isArray:kg}=Array,V_=d1("undefined");function xX(e){return e!==null&&!V_(e)&&e.constructor!==null&&!V_(e.constructor)&&Hl(e.constructor.isBuffer)&&e.constructor.isBuffer(e)}const Sz=vu("ArrayBuffer");function wX(e){let t;return typeof ArrayBuffer<"u"&&ArrayBuffer.isView?t=ArrayBuffer.isView(e):t=e&&e.buffer&&Sz(e.buffer),t}const TX=d1("string"),Hl=d1("function"),Cz=d1("number"),f1=e=>e!==null&&typeof e=="object",EX=e=>e===!0||e===!1,Cb=e=>{if(h1(e)!=="object")return!1;const t=Hk(e);
vendor: 26,271 bytes, lines 46-48
46return(t===null||t===Object.prototype||Object.getPrototypeOf(t)===null)&&!(Symbol.toStringTag in e)&&!(Symbol.iterator in e)},SX=vu("Date"),CX=vu("File"),kX=vu("Blob"),AX=vu("FileList"),PX=e=>f1(e)&&Hl(e.pipe),MX=e=>{let t;return e&&(typeof FormData=="function"&&e instanceof FormData||Hl(e.append)&&((t=h1(e))==="formdata"||t==="object"&&Hl(e.toString)&&e.toString()==="[object FormData]"))},IX=vu("URLSearchParams"),OX=e=>e.trim?e.trim():e.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,"");function Iv(e,t,{allOwnKeys:n=!1}={}){if(e===null||typeof e>"u")return;let r,i;if(typeof e!="object"&&(e=[e]),kg(e))for(r=0,i=e.length;r<i;r++)t.call(null,e[r],r,e);else{const s=n?Object.getOwnPropertyNames(e):Object.keys(e),c=s.length;let a;for(r=0;r<c;r++)a=s[r],t.call(null,e[a],a,e)}}function kz(e,t){t=t.toLowerCase();const n=Object.keys(e);let r=n.length,i;for(;r-- >0;)if(i=n[r],t===i.toLowerCase())return i;return null}const Az=(()=>typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:global)(),Pz=e=>!V_(e)&&e!==Az;function LS(){const{caseless:e}=Pz(this)&&this||{},t={},n=(r,i)=>{const s=e&&kz(t,i)||i;Cb(t[s])&&Cb(r)?t[s]=LS(t[s],r):Cb(r)?t[s]=LS({},r):kg(r)?t[s]=r.slice():t[s]=r};for(let r=0,i=arguments.length;r<i;r++)arguments[r]&&Iv(arguments[r],n);return t}const DX=(e,t,n,{allOwnKeys:r}={})=>(Iv(t,(i,s)=>{n&&Hl(i)?e[s]=Ez(i,n):e[s]=i},{allOwnKeys:r}),e),LX=e=>(e.charCodeAt(0)===65279&&(e=e.slice(1)),e),RX=(e,t,n,r)=>{e.prototype=Object.create(t.prototype,r),e.prototype.constructor=e,Object.defineProperty(e,"super",{value:t.prototype}),n&&Object.assign(e.prototype,n)},FX=(e,t,n,r)=>{let i,s,c;const a={};if(t=t||{},e==null)return t;do{for(i=Object.getOwnPropertyNames(e),s=i.length;s-- >0;)c=i[s],(!r||r(c,e,t))&&!a[c]&&(t[c]=e[c],a[c]=!0);e=n!==!1&&Hk(e)}while(e&&(!n||n(e,t))&&e!==Object.prototype);return t},BX=(e,t,n)=>{e=String(e),(n===void 0||n>e.length)&&(n=e.length),n-=t.length;const r=e.indexOf(t,n);return r!==-1&&r===n},zX=e=>{if(!e)return null;if(kg(e))return e;let t=e.length;if(!Cz(t))return null;const n=new Array(t);for(;t-- >0;)n[t]=e[t];return n},NX=(e=>t=>e&&t instanceof e)(typeof Uint8Array<"u"&&Hk(Uint8Array)),$X=(e,t)=>{const r=(e&&e[Symbol.iterator]).call(e);let i;for(;(i=r.next())&&!i.done;){const s=i.value;t.call(e,s[0],s[1])}},jX=(e,t)=>{let n;const r=[];for(;(n=e.exec(t))!==null;)r.push(n);return r},UX=vu("HTMLFormElement"),VX=e=>e.toLowerCase().replace(/[-_\s]([a-z\d])(\w*)/g,function(n,r,i){return r.toUpperCase()+i}),gD=(({hasOwnProperty:e})=>(t,n)=>e.call(t,n))(Object.prototype),GX=vu("RegExp"),Mz=(e,t)=>{const n=Object.getOwnPropertyDescriptors(e),r={};Iv(n,(i,s)=>{t(i,s,e)!==!1&&(r[s]=i)}),Object.defineProperties(e,r)},qX=e=>{Mz(e,(t,n)=>{if(Hl(e)&&["arguments","caller","callee"].indexOf(n)!==-1)return!1;const r=e[n];if(Hl(r)){if(t.enumerable=!1,"writable"in t){t.writable=!1;return}t.set||(t.set=()=>{throw Error("Can not rewrite read-only method '"+n+"'")})}})},WX=(e,t)=>{const n={},r=i=>{i.forEach(s=>{n[s]=!0})};return kg(e)?r(e):r(String(e).split(t)),n},HX=()=>{},YX=(e,t)=>(e=+e,Number.isFinite(e)?e:t),RT="abcdefghijklmnopqrstuvwxyz",yD="0123456789",Iz={DIGIT:yD,ALPHA:RT,ALPHA_DIGIT:RT+RT.toUpperCase()+yD},ZX=(e=16,t=Iz.ALPHA_DIGIT)=>{let n="";const{length:r}=t;for(;e--;)n+=t[Math.random()*r|0];return n};function XX(e){return!!(e&&Hl(e.append)&&e[Symbol.toStringTag]==="FormData"&&e[Symbol.iterator])}const KX=e=>{const t=new Array(10),n=(r,i)=>{if(f1(r)){if(t.indexOf(r)>=0)return;if(!("toJSON"in r)){t[i]=r;const s=kg(r)?[]:{};return Iv(r,(c,a)=>{const m=n(c,i+1);!V_(m)&&(s[a]=m)}),t[i]=void 0,s}}return r};return n(e,0)},QX=vu("AsyncFunction"),JX=e=>e&&(f1(e)||Hl(e))&&Hl(e.then)&&Hl(e.catch),Ht={isArray:kg,isArrayBuffer:Sz,isBuffer:xX,isFormData:MX,isArrayBufferView:wX,isString:TX,isNumber:Cz,isBoolean:EX,isObject:f1,isPlainObject:Cb,isUndefined:V_,isDate:SX,isFile:CX,isBlob:kX,isRegExp:GX,isFunction:Hl,isStream:PX,isURLSearchParams:IX,isTypedArray:NX,isFileList:AX,forEach:Iv,merge:LS,extend:DX,trim:OX,stripBOM:LX,inherits:RX,toFlatObject:FX,kindOf:h1,kindOfTest:vu,endsWith:BX,toArray:zX,forEachEntry:$X,matchAll:jX,isHTMLForm:UX,hasOwnProperty:gD,hasOwnProp:gD,reduceDescriptors:Mz,freezeMethods:qX,toObjectSet:WX,toCamelCase:VX,noop:HX,toFiniteNumber:YX,findKey:kz,global:Az,isContextDefined:Pz,ALPHABET:Iz,generateString:ZX,isSpecCompliantForm:XX,toJSONObject:KX,isAsyncFn:QX,isThenable:JX};function Zr(e,t,n,r,i){Error.call(this),Error.captureStackTrace?Error.captureStackTrace(this,this.constructor):this.stack=new Error().stack,this.message=e,this.name="AxiosError",t&&(this.code=t),n&&(this.config=n),r&&(this.request=r),i&&(this.response=i)}Ht.inherits(Zr,Error,{toJSON:function(){return{message:this.message,name:this.name,description:this.description,number:this.number,fileName:this.fileName,lineNumber:this.lineNumber,columnNumber:this.columnNumber,stack:this.stack,config:Ht.toJSONObject(this.config),code:this.code,status:this.response&&this.response.status?this.response.status:null}}});const Oz=Zr.prototype,Dz={};["ERR_BAD_OPTION_VALUE","ERR_BAD_OPTION","ECONNABORTED","ETIMEDOUT","ERR_NETWORK","ERR_FR_TOO_MANY_REDIRECTS","ERR_DEPRECATED","ERR_BAD_RESPONSE","ERR_BAD_REQUEST","ERR_CANCELED","ERR_NOT_SUPPORT","ERR_INVALID_URL"].forEach(e=>{Dz[e]={value:e}});Object.defineProperties(Zr,Dz);Object.defineProperty(Oz,"isAxiosError",{value:!0});Zr.from=(e,t,n,r,i,s)=>{const c=Object.create(Oz);return Ht.toFlatObject(e,c,function(m){return m!==Error.prototype},a=>a!=="isAxiosError"),Zr.call(c,e.message,t,n,r,i),c.cause=e,c.name=e.name,s&&Object.assign(c,s),c};const eK=null;function RS(e){return Ht.isPlainObject(e)||Ht.isArray(e)}function Lz(e){return Ht.endsWith(e,"[]")?e.slice(0,-2):e}function _D(e,t,n){return e?e.concat(t).map(function(i,s){return i=Lz(i),!n&&s?"["+i+"]":i}).join(n?".":""):t}function tK(e){return Ht.isArray(e)&&!e.some(RS)}const nK=Ht.toFlatObject(Ht,{},null,function(t){return/^is[A-Z]/.test(t)});function p1(e,t,n){if(!Ht.isObject(e))throw new TypeError("target must be an object");t=t||new FormData,n=Ht.toFlatObject(n,{metaTokens:!0,dots:!1,indexes:!1},!1,function(D,B){return!Ht.isUndefined(B[D])});const r=n.metaTokens,i=n.visitor||x,s=n.dots,c=n.indexes,m=(n.Blob||typeof Blob<"u"&&Blob)&&Ht.isSpecCompliantForm(t);if(!Ht.isFunction(i))throw new TypeError("visitor must be a function");function g(P){if(P===null)return"";if(Ht.isDate(P))return P.toISOString();if(!m&&Ht.isBlob(P))throw new Zr("Blob is not supported. Use a Buffer instead.");return Ht.isArrayBuffer(P)||Ht.isTypedArray(P)?m&&typeof Blob=="function"?new Blob([P]):Buffer.from(P):P}function x(P,D,B){let R=P;if(P&&!B&&typeof P=="object"){if(Ht.endsWith(D,"{}"))D=r?D:D.slice(0,-2),P=JSON.stringify(P);else if(Ht.isArray(P)&&tK(P)||(Ht.isFileList(P)||Ht.endsWith(D,"[]"))&&(R=Ht.toArray(P)))return D=Lz(D),R.forEach(function(j,U){!(Ht.isUndefined(j)||j===null)&&t.append(c===!0?_D([D],U,s):c===null?D:D+"[]",g(j))}),!1}return RS(P)?!0:(t.append(_D(B,D,s),g(P)),!1)}const T=[],C=Object.assign(nK,{defaultVisitor:x,convertValue:g,isVisitable:RS});function A(P,D){if(!Ht.isUndefined(P)){if(T.indexOf(P)!==-1)throw Error("Circular reference detected in "+D.join("."));T.push(P),Ht.forEach(P,function(R,N){(!(Ht.isUndefined(R)||R===null)&&i.call(t,R,Ht.isString(N)?N.trim():N,D,C))===!0&&A(R,D?D.concat(N):[N])}),T.pop()}}if(!Ht.isObject(e))throw new TypeError("data must be an object");return A(e),t}function vD(e){const t={"!":"%21","'":"%27","(":"%28",")":"%29","~":"%7E","%20":"+","%00":"\0"};return encodeURIComponent(e).replace(/[!'()~]|%20|%00/g,function(r){return t[r]})}function Yk(e,t){this._pairs=[],e&&p1(e,this,t)}const Rz=Yk.prototype;Rz.append=function(t,n){this._pairs.push([t,n])};Rz.toString=function(t){const n=t?function(r){return t.call(this,r,vD)}:vD;return this._pairs.map(function(i){return n(i[0])+"="+n(i[1])},"").join("&")};function rK(e){return encodeURIComponent(e).replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%20/g,"+").replace(/%5B/gi,"[").replace(/%5D/gi,"]")}function Fz(e,t,n){if(!t)return e;const r=n&&n.encode||rK,i=n&&n.serialize;let s;if(i?s=i(t,n):s=Ht.isURLSearchParams(t)?t.toString():new Yk(t,n).toString(r),s){const c=e.indexOf("#");c!==-1&&(e=e.slice(0,c)),e+=(e.indexOf("?")===-1?"?":"&")+s}return e}class iK{constructor(){this.handlers=[]}use(t,n,r){return this.handlers.push({fulfilled:t,rejected:n,synchronous:r?r.synchronous:!1,runWhen:r?r.runWhen:null}),this.handlers.length-1}eject(t){this.handlers[t]&&(this.handlers[t]=null)}clear(){this.handlers&&(this.handlers=[])}forEach(t){Ht.forEach(this.handlers,function(r){r!==null&&t(r)})}}const bD=iK,Bz={silentJSONParsing:!0,forcedJSONParsing:!0,clarifyTimeoutError:!1},oK=typeof URLSearchParams<"u"?URLSearchParams:Yk,aK=typeof FormData<"u"?FormData:null,sK=typeof Blob<"u"?Blob:null,lK=(()=>{let e;return typeof navigator<"u"&&((e=navigator.product)==="ReactNative"||e==="NativeScript"||e==="NS")?!1:typeof window<"u"&&typeof document<"u"})(),cK=(()=>typeof WorkerGlobalScope<"u"&&self instanceof WorkerGlobalScope&&typeof self.importScripts=="function")(),lu={isBrowser:!0,classes:{URLSearchParams:oK,FormData:aK,Blob:sK},isStandardBrowserEnv:lK,isStandardBrowserWebWorkerEnv:cK,protocols:["http","https","file","blob","url","data"]};function uK(e,t){return p1(e,new lu.classes.URLSearchParams,Object.assign({visitor:function(n,r,i,s){return lu.isNode&&Ht.isBuffer(n)?(this.append(r,n.toString("base64")),!1):s.defaultVisitor.apply(this,arguments)}},t))}function hK(e){return Ht.matchAll(/\w+|\[(\w*)]/g,e).map(t=>t[0]==="[]"?"":t[1]||t[0])}function dK(e){const t={},n=Object.keys(e);let r;const i=n.length;let s;for(r=0;r<i;r++)s=n[r],t[s]=e[s];return t}function zz(e){function t(n,r,i,s){let c=n[s++];const a=Number.isFinite(+c),m=s>=n.length;return c=!c&&Ht.isArray(i)?i.length:c,m?(Ht.hasOwnProp(i,c)?i[c]=[i[c],r]:i[c]=r,!a):((!i[c]||!Ht.isObject(i[c]))&&(i[c]=[]),t(n,r,i[c],s)&&Ht.isArray(i[c])&&(i[c]=dK(i[c])),!a)}if(Ht.isFormData(e)&&Ht.isFunction(e.entries)){const n={};return Ht.forEachEntry(e,(r,i)=>{t(hK(r),i,n,0)}),n}return null}const fK={"Content-Type":void 0};function pK(e,t,n){if(Ht.isString(e))try{return(t||JSON.parse)(e),Ht.trim(e)}catch(r){if(r.name!=="SyntaxError")throw r}return(n||JSON.stringify)(e)}const m1={transitional:Bz,adapter:["xhr","http"],transformRequest:[function(t,n){const r=n.getContentType()||"",i=r.indexOf("application/json")>-1,s=Ht.isObject(t);if(s&&Ht.isHTMLForm(t)&&(t=new FormData(t)),Ht.isFormData(t))return i&&i?JSON.stringify(zz(t)):t;if(Ht.isArrayBuffer(t)||Ht.isBuffer(t)||Ht.isStream(t)||Ht.isFile(t)||Ht.isBlob(t))return t;if(Ht.isArrayBufferView(t))return t.buffer;if(Ht.isURLSearchParams(t))return n.setContentType("application/x-www-form-urlencoded;charset=utf-8",!1),t.toString();let a;if(s){if(r.indexOf("application/x-www-form-urlencoded")>-1)return uK(t,this.formSerializer).toString();if((a=Ht.isFileList(t))||r.indexOf("multipart/form-data")>-1){const m=this.env&&this.env.FormData;return p1(a?{"files[]":t}:t,m&&new m,this.formSerializer)}}return s||i?(n.setContentType("application/json",!1),pK(t)):t}],transformResponse:[function(t){const n=this.transitional||m1.transitional,r=n&&n.forcedJSONParsing,i=this.responseType==="json";if(t&&Ht.isString(t)&&(r&&!this.responseType||i)){const c=!(n&&n.silentJSONParsing)&&i;try{return JSON.parse(t)}catch(a){if(c)throw a.name==="SyntaxError"?Zr.from(a,Zr.ERR_BAD_RESPONSE,this,null,this.response):a}}return t}],timeout:0,xsrfCookieName:"XSRF-TOKEN",xsrfHeaderName:"X-XSRF-TOKEN",maxContentLength:-1,maxBodyLength:-1,env:{FormData:lu.classes.FormData,Blob:lu.classes.Blob},validateStatus:function(t){return t>=200&&t<300},headers:{common:{Accept:"application/json, text/plain, */*"}}};Ht.forEach(["delete","get","head"],function(t){m1.headers[t]={}});Ht.forEach(["post","put","patch"],function(t){m1.headers[t]=Ht.merge(fK)});const Zk=m1,mK=Ht.toObjectSet(["age","authorization","content-length","content-type","etag","expires","from","host","if-modified-since","if-unmodified-since","last-modified","location","max-forwards","proxy-authorization","referer","retry-after","user-agent"]),gK=e=>{const t={};let n,r,i;return e&&e.split(`
47`).forEach(function(c){i=c.indexOf(":"),n=c.substring(0,i).trim().toLowerCase(),r=c.substring(i+1).trim(),!(!n||t[n]&&mK[n])&&(n==="set-cookie"?t[n]?t[n].push(r):t[n]=[r]:t[n]=t[n]?t[n]+", "+r:r)}),t},xD=Symbol("internals");function Vy(e){return e&&String(e).trim().toLowerCase()}function kb(e){return e===!1||e==null?e:Ht.isArray(e)?e.map(kb):String(e)}function yK(e){const t=Object.create(null),n=/([^\s,;=]+)\s*(?:=\s*([^,;]+))?/g;let r;for(;r=n.exec(e);)t[r[1]]=r[2];return t}const _K=e=>/^[-_a-zA-Z0-9^`|~,!#$%&'*+.]+$/.test(e.trim());function FT(e,t,n,r,i){if(Ht.isFunction(r))return r.call(this,t,n);if(i&&(t=n),!!Ht.isString(t)){if(Ht.isString(r))return t.indexOf(r)!==-1;if(Ht.isRegExp(r))return r.test(t)}}function vK(e){return e.trim().toLowerCase().replace(/([a-z\d])(\w*)/g,(t,n,r)=>n.toUpperCase()+r)}function bK(e,t){const n=Ht.toCamelCase(" "+t);["get","set","has"].forEach(r=>{Object.defineProperty(e,r+n,{value:function(i,s,c){return this[r].call(this,t,i,s,c)},configurable:!0})})}class g1{constructor(t){t&&this.set(t)}set(t,n,r){const i=this;function s(a,m,g){const x=Vy(m);if(!x)throw new Error("header name must be a non-empty string");const T=Ht.findKey(i,x);(!T||i[T]===void 0||g===!0||g===void 0&&i[T]!==!1)&&(i[T||m]=kb(a))}const c=(a,m)=>Ht.forEach(a,(g,x)=>s(g,x,m));return Ht.isPlainObject(t)||t instanceof this.constructor?c(t,n):Ht.isString(t)&&(t=t.trim())&&!_K(t)?c(gK(t),n):t!=null&&s(n,t,r),this}get(t,n){if(t=Vy(t),t){const r=Ht.findKey(this,t);if(r){const i=this[r];if(!n)return i;if(n===!0)return yK(i);if(Ht.isFunction(n))return n.call(this,i,r);if(Ht.isRegExp(n))return n.exec(i);throw new TypeError("parser must be boolean|regexp|function")}}}has(t,n){if(t=Vy(t),t){const r=Ht.findKey(this,t);return!!(r&&this[r]!==void 0&&(!n||FT(this,this[r],r,n)))}return!1}delete(t,n){const r=this;let i=!1;function s(c){if(c=Vy(c),c){const a=Ht.findKey(r,c);a&&(!n||FT(r,r[a],a,n))&&(delete r[a],i=!0)}}return Ht.isArray(t)?t.forEach(s):s(t),i}clear(t){const n=Object.keys(this);let r=n.length,i=!1;for(;r--;){const s=n[r];(!t||FT(this,this[s],s,t,!0))&&(delete this[s],i=!0)}return i}normalize(t){const n=this,r={};return Ht.forEach(this,(i,s)=>{const c=Ht.findKey(r,s);if(c){n[c]=kb(i),delete n[s];return}const a=t?vK(s):String(s).trim();a!==s&&delete n[s],n[a]=kb(i),r[a]=!0}),this}concat(...t){return this.constructor.concat(this,...t)}toJSON(t){const n=Object.create(null);return Ht.forEach(this,(r,i)=>{r!=null&&r!==!1&&(n[i]=t&&Ht.isArray(r)?r.join(", "):r)}),n}[Symbol.iterator](){return Object.entries(this.toJSON())[Symbol.iterator]()}toString(){return Object.entries(this.toJSON()).map(([t,n])=>t+": "+n).join(`
48`)}get[Symbol.toStringTag](){return"AxiosHeaders"}static from(t){return t instanceof this?t:new this(t)}static concat(t,...n){const r=new this(t);return n.forEach(i=>r.set(i)),r}static accessor(t){const r=(this[xD]=this[xD]={accessors:{}}).accessors,i=this.prototype;function s(c){const a=Vy(c);r[a]||(bK(i,c),r[a]=!0)}return Ht.isArray(t)?t.forEach(s):s(t),this}}g1.accessor(["Content-Type","Content-Length","Accept","Accept-Encoding","User-Agent","Authorization"]);Ht.freezeMethods(g1.prototype);Ht.freezeMethods(g1);const eh=g1;function BT(e,t){const n=this||Zk,r=t||n,i=eh.from(r.headers);let s=r.data;return Ht.forEach(e,function(a){s=a.call(n,s,i.normalize(),t?t.status:void 0)}),i.normalize(),s}function Nz(e){return!!(e&&e.__CANCEL__)}function Ov(e,t,n){Zr.call(this,e??"canceled",Zr.ERR_CANCELED,t,n),this.name="CanceledError"}Ht.inherits(Ov,Zr,{__CANCEL__:!0});function xK(e,t,n){const r=n.config.validateStatus;!n.status||!r||r(n.status)?e(n):t(new Zr("Request failed with status code "+n.status,[Zr.ERR_BAD_REQUEST,Zr.ERR_BAD_RESPONSE][Math.floor(n.status/100)-4],n.config,n.request,n))}const wK=lu.isStandardBrowserEnv?function(){return{write:function(n,r,i,s,c,a){const m=[];m.push(n+"="+encodeURIComponent(r)),Ht.isNumber(i)&&m.push("expires="+new Date(i).toGMTString()),Ht.isString(s)&&m.push("path="+s),Ht.isString(c)&&m.push("domain="+c),a===!0&&m.push("secure"),document.cookie=m.join("; ")},read:function(n){const r=document.cookie.match(new RegExp("(^|;\\s*)("+n+")=([^;]*)"));return r?decodeURIComponent(r[3]):null},remove:function(n){this.write(n,"",Date.now()-864e5)}}}():function(){return{write:function(){},read:function(){return null},remove:function(){}}}();function TK(e){return/^([a-z][a-z\d+\-.]*:)?\/\//i.test(e)}function EK(e,t){return t?e.replace(/\/+$/,"")+"/"+t.replace(/^\/+/,""):e}function $z(e,t){return e&&!TK(t)?EK(e,t):t}const SK=lu.isStandardBrowserEnv?function(){const t=/(msie|trident)/i.test(navigator.userAgent),n=document.createElement("a");let r;function i(s){let c=s;return t&&(n.setAttribute("href",c),c=n.href),n.setAttribute("href",c),{href:n.href,protocol:n.protocol?n.protocol.replace(/:$/,""):"",host:n.host,search:n.search?n.search.replace(/^\?/,""):"",hash:n.hash?n.hash.replace(/^#/,""):"",hostname:n.hostname,port:n.port,pathname:n.pathname.charAt(0)==="/"?n.pathname:"/"+n.pathname}}return r=i(window.location.href),function(c){const a=Ht.isString(c)?i(c):c;return a.protocol===r.protocol&&a.host===r.host}}():function(){return function(){return!0}}();function CK(e){const t=/^([-+\w]{1,25})(:?\/\/|:)/.exec(e);return t&&t[1]||""}function kK(e,t){e=e||10;const n=new Array(e),r=new Array(e);let i=0,s=0,c;return t=t!==void 0?t:1e3,function(m){const g=Date.now(),x=r[s];c||(c=g),n[i]=m,r[i]=g;let T=s,C=0;for(;T!==i;)C+=n[T++],T=T%e;if(i=(i+1)%e,i===s&&(s=(s+1)%e),g-c<t)return;const A=x&&g-x;return A?Math.round(C*1e3/A):void 0}}function wD(e,t){let n=0;const r=kK(50,250);return i=>{const s=i.loaded,c=i.lengthComputable?i.total:void 0,a=s-n,m=r(a),g=s<=c;n=s;const x={loaded:s,total:c,progress:c?s/c:void 0,bytes:a,rate:m||void 0,estimated:m&&c&&g?(c-s)/m:void 0,event:i};x[t?"download":"upload"]=!0,e(x)}}const AK=typeof XMLHttpRequest<"u",PK=AK&&function(e){return new Promise(function(n,r){let i=e.data;const s=eh.from(e.headers).normalize(),c=e.responseType;let a;function m(){e.cancelToken&&e.cancelToken.unsubscribe(a),e.signal&&e.signal.removeEventListener("abort",a)}Ht.isFormData(i)&&(lu.isStandardBrowserEnv||lu.isStandardBrowserWebWorkerEnv?s.setContentType(!1):s.setContentType("multipart/form-data;",!1));let g=new XMLHttpRequest;if(e.auth){const A=e.auth.username||"",P=e.auth.password?unescape(encodeURIComponent(e.auth.password)):"";s.set("Authorization","Basic "+btoa(A+":"+P))}const x=$z(e.baseURL,e.url);g.open(e.method.toUpperCase(),Fz(x,e.params,e.paramsSerializer),!0),g.timeout=e.timeout;function T(){if(!g)return;const A=eh.from("getAllResponseHeaders"in g&&g.getAllResponseHeaders()),D={data:!c||c==="text"||c==="json"?g.responseText:g.response,status:g.status,statusText:g.statusText,headers:A,config:e,request:g};xK(function(R){n(R),m()},function(R){r(R),m()},D),g=null}if("onloadend"in g?g.onloadend=T:g.onreadystatechange=function(){!g||g.readyState!==4||g.status===0&&!(g.responseURL&&g.responseURL.indexOf("file:")===0)||setTimeout(T)},g.onabort=function(){g&&(r(new Zr("Request aborted",Zr.ECONNABORTED,e,g)),g=null)},g.onerror=function(){r(new Zr("Network Error",Zr.ERR_NETWORK,e,g)),g=null},g.ontimeout=function(){let P=e.timeout?"timeout of "+e.timeout+"ms exceeded":"timeout exceeded";const D=e.transitional||Bz;e.timeoutErrorMessage&&(P=e.timeoutErrorMessage),r(new Zr(P,D.clarifyTimeoutError?Zr.ETIMEDOUT:Zr.ECONNABORTED,e,g)),g=null},lu.isStandardBrowserEnv){const A=(e.withCredentials||SK(x))&&e.xsrfCookieName&&wK.read(e.xsrfCookieName);A&&s.set(e.xsrfHeaderName,A)}i===void 0&&s.setContentType(null),"setRequestHeader"in g&&Ht.forEach(s.toJSON(),function(P,D){g.setRequestHeader(D,P)}),Ht.isUndefined(e.withCredentials)||(g.withCredentials=!!e.withCredentials),c&&c!=="json"&&(g.responseType=e.responseType),typeof e.onDownloadProgress=="function"&&g.addEventListener("progress",wD(e.onDownloadProgress,!0)),typeof e.onUploadProgress=="function"&&g.upload&&g.upload.addEventListener("progress",wD(e.onUploadProgress)),(e.cancelToken||e.signal)&&(a=A=>{g&&(r(!A||A.type?new Ov(null,e,g):A),g.abort(),g=null)},e.cancelToken&&e.cancelToken.subscribe(a),e.signal&&(e.signal.aborted?a():e.signal.addEventListener("abort",a)));const C=CK(x);if(C&&lu.protocols.indexOf(C)===-1){r(new Zr("Unsupported protocol "+C+":",Zr.ERR_BAD_REQUEST,e));return}g.send(i||null)})},Ab={http:eK,xhr:PK};Ht.forEach(Ab,(e,t)=>{if(e){try{Object.defineProperty(e,"name",{value:t})}catch{}Object.defineProperty(e,"adapterName",{value:t})}});const MK={getAdapter:e=>{e=Ht.isArray(e)?e:[e];const{length:t}=e;let n,r;for(let i=0;i<t&&(n=e[i],!(r=Ht.isString(n)?Ab[n.toLowerCase()]:n));i++);if(!r)throw r===!1?new Zr(`Adapter ${n} is not supported by the environment`,"ERR_NOT_SUPPORT"):new Error(Ht.hasOwnProp(Ab,n)?`Adapter '${n}' is not available in the build`:`Unknown adapter '${n}'`);if(!Ht.isFunction(r))throw new TypeError("adapter is not a function");return r},adapters:Ab};function zT(e){if(e.cancelToken&&e.cancelToken.throwIfRequested(),e.signal&&e.signal.aborted)throw new Ov(null,e)}function TD(e){return zT(e),e.headers=eh.from(e.headers),e.data=BT.call(e,e.transformRequest),["post","put","patch"].indexOf(e.method)!==-1&&e.headers.setContentType("application/x-www-form-urlencoded",!1),MK.getAdapter(e.adapter||Zk.adapter)(e).then(function(r){return zT(e),r.data=BT.call(e,e.transformResponse,r),r.headers=eh.from(r.headers),r},function(r){return Nz(r)||(zT(e),r&&r.response&&(r.response.data=BT.call(e,e.transformResponse,r.response),r.response.headers=eh.from(r.response.headers))),Promise.reject(r)})}const ED=e=>e instanceof eh?e.toJSON():e;function ig(e,t){t=t||{};const n={};function r(g,x,T){return Ht.isPlainObject(g)&&Ht.isPlainObject(x)?Ht.merge.call({caseless:T},g,x):Ht.isPlainObject(x)?Ht.merge({},x):Ht.isArray(x)?x.slice():x}function i(g,x,T){if(Ht.isUndefined(x)){if(!Ht.isUndefined(g))return r(void 0,g,T)}else return r(g,x,T)}function s(g,x){if(!Ht.isUndefined(x))return r(void 0,x)}function c(g,x){if(Ht.isUndefined(x)){if(!Ht.isUndefined(g))return r(void 0,g)}else return r(void 0,x)}function a(g,x,T){if(T in t)return r(g,x);if(T in e)return r(void 0,g)}const m={url:s,method:s,data:s,baseURL:c,transformRequest:c,transformResponse:c,paramsSerializer:c,timeout:c,timeoutMessage:c,withCredentials:c,adapter:c,responseType:c,xsrfCookieName:c,xsrfHeaderName:c,onUploadProgress:c,onDownloadProgress:c,decompress:c,maxContentLength:c,maxBodyLength:c,beforeRedirect:c,transport:c,httpAgent:c,httpsAgent:c,cancelToken:c,socketPath:c,responseEncoding:c,validateStatus:a,headers:(g,x)=>i(ED(g),ED(x),!0)};return Ht.forEach(Object.keys(Object.assign({},e,t)),function(x){const T=m[x]||i,C=T(e[x],t[x],x);Ht.isUndefined(C)&&T!==a||(n[x]=C)}),n}const jz="1.4.0",Xk={};["object","boolean","number","function","string","symbol"].forEach((e,t)=>{Xk[e]=function(r){return typeof r===e||"a"+(t<1?"n ":" ")+e}});const SD={};Xk.transitional=function(t,n,r){function i(s,c){return"[Axios v"+jz+"] Transitional option '"+s+"'"+c+(r?". "+r:"")}return(s,c,a)=>{if(t===!1)throw new Zr(i(c," has been removed"+(n?" in "+n:"")),Zr.ERR_DEPRECATED);return n&&!SD[c]&&(SD[c]=!0,console.warn(i(c," has been deprecated since v"+n+" and will be removed in the near future"))),t?t(s,c,a):!0}};function IK(e,t,n){if(typeof e!="object")throw new Zr("options must be an object",Zr.ERR_BAD_OPTION_VALUE);const r=Object.keys(e);let i=r.length;for(;i-- >0;){const s=r[i],c=t[s];if(c){const a=e[s],m=a===void 0||c(a,s,e);if(m!==!0)throw new Zr("option "+s+" must be "+m,Zr.ERR_BAD_OPTION_VALUE);continue}if(n!==!0)throw new Zr("Unknown option "+s,Zr.ERR_BAD_OPTION)}}const FS={assertOptions:IK,validators:Xk},Vh=FS.validators;class lx{constructor(t){this.defaults=t,this.interceptors={request:new bD,response:new bD}}request(t,n){typeof t=="string"?(n=n||{},n.url=t):n=t||{},n=ig(this.defaults,n);const{transitional:r,paramsSerializer:i,headers:s}=n;r!==void 0&&FS.assertOptions(r,{silentJSONParsing:Vh.transitional(Vh.boolean),forcedJSONParsing:Vh.transitional(Vh.boolean),clarifyTimeoutError:Vh.transitional(Vh.boolean)},!1),i!=null&&(Ht.isFunction(i)?n.paramsSerializer={serialize:i}:FS.assertOptions(i,{encode:Vh.function,serialize:Vh.function},!0)),n.method=(n.method||this.defaults.method||"get").toLowerCase();let c;c=s&&Ht.merge(s.common,s[n.method]),c&&Ht.forEach(["delete","get","head","post","put","patch","common"],P=>{delete s[P]}),n.headers=eh.concat(c,s);const a=[];let m=!0;this.interceptors.request.forEach(function(D){typeof D.runWhen=="function"&&D.runWhen(n)===!1||(m=m&&D.synchronous,a.unshift(D.fulfilled,D.rejected))});const g=[];this.interceptors.response.forEach(function(D){g.push(D.fulfilled,D.rejected)});let x,T=0,C;if(!m){const P=[TD.bind(this),void 0];for(P.unshift.apply(P,a),P.push.apply(P,g),C=P.length,x=Promise.resolve(n);T<C;)x=x.then(P[T++],P[T++]);return x}C=a.length;let A=n;for(T=0;T<C;){const P=a[T++],D=a[T++];try{A=P(A)}catch(B){D.call(this,B);break}}try{x=TD.call(this,A)}catch(P){return Promise.reject(P)}for(T=0,C=g.length;T<C;)x=x.then(g[T++],g[T++]);return x}getUri(t){t=ig(this.defaults,t);const n=$z(t.baseURL,t.url);return Fz(n,t.params,t.paramsSerializer)}}Ht.forEach(["delete","get","head","options"],function(t){lx.prototype[t]=function(n,r){return this.request(ig(r||{},{method:t,url:n,data:(r||{}).data}))}});Ht.forEach(["post","put","patch"],function(t){function n(r){return function(s,c,a){return this.request(ig(a||{},{method:t,headers:r?{"Content-Type":"multipart/form-data"}:{},url:s,data:c}))}}lx.prototype[t]=n(),lx.prototype[t+"Form"]=n(!0)});const Pb=lx;class Kk{constructor(t){if(typeof t!="function")throw new TypeError("executor must be a function.");let n;this.promise=new Promise(function(s){n=s});const r=this;this.promise.then(i=>{if(!r._listeners)return;let s=r._listeners.length;for(;s-- >0;)r._listeners[s](i);r._listeners=null}),this.promise.then=i=>{let s;const c=new Promise(a=>{r.subscribe(a),s=a}).then(i);return c.cancel=function(){r.unsubscribe(s)},c},t(function(s,c,a){r.reason||(r.reason=new Ov(s,c,a),n(r.reason))})}throwIfRequested(){if(this.reason)throw this.reason}
48subscribe(t){if(this.reason){t(this.reason);return}this._listeners?this._listeners.push(t):this._listeners=[t]}unsubscribe(t){if(!this._listeners)return;const n=this._listeners.indexOf(t);n!==-1&&this._listeners.splice(n,1)}static source(){let t;return{token:new Kk(function(i){t=i}),cancel:t}}}const OK=Kk;function DK(e){return function(n){return e.apply(null,n)}}function LK(e){return Ht.isObject(e)&&e.isAxiosError===!0}const BS={Continue:100,SwitchingProtocols:101,Processing:102,EarlyHints:103,Ok:200,Created:201,Accepted:202,NonAuthoritativeInformation:203,NoContent:204,ResetContent:205,PartialContent:206,MultiStatus:207,AlreadyReported:208,ImUsed:226,MultipleChoices:300,MovedPermanently:301,Found:302,SeeOther:303,NotModified:304,UseProxy:305,Unused:306,TemporaryRedirect:307,PermanentRedirect:308,BadRequest:400,Unauthorized:401,PaymentRequired:402,Forbidden:403,NotFound:404,MethodNotAllowed:405,NotAcceptable:406,ProxyAuthenticationRequired:407,RequestTimeout:408,Conflict:409,Gone:410,LengthRequired:411,PreconditionFailed:412,PayloadTooLarge:413,UriTooLong:414,UnsupportedMediaType:415,RangeNotSatisfiable:416,ExpectationFailed:417,ImATeapot:418,MisdirectedRequest:421,UnprocessableEntity:422,Locked:423,FailedDependency:424,TooEarly:425,UpgradeRequired:426,PreconditionRequired:428,TooManyRequests:429,RequestHeaderFieldsTooLarge:431,UnavailableForLegalReasons:451,InternalServerError:500,NotImplemented:501,BadGateway:502,ServiceUnavailable:503,GatewayTimeout:504,HttpVersionNotSupported:505,VariantAlsoNegotiates:506,InsufficientStorage:507,LoopDetected:508,NotExtended:510,NetworkAuthenticationRequired:511};Object.entries(BS).forEach(([e,t])=>{BS[t]=e});const RK=BS;function Uz(e){const t=new Pb(e),n=Ez(Pb.prototype.request,t);return Ht.extend(n,Pb.prototype,t,{allOwnKeys:!0}),Ht.extend(n,t,null,{allOwnKeys:!0}),n.create=function(i){return Uz(ig(e,i))},n}const da=Uz(Zk);da.Axios=Pb;da.CanceledError=Ov;da.CancelToken=OK;da.isCancel=Nz;da.VERSION=jz;da.toFormData=p1;da.AxiosError=Zr;da.Cancel=da.CanceledError;da.all=function(t){return Promise.all(t)};da.spread=DK;da.isAxiosError=LK;da.mergeConfig=ig;da.AxiosHeaders=eh;da.formToJSON=e=>zz(Ht.isHTMLForm(e)?new FormData(e):e);da.HttpStatusCode=RK;da.default=da;const y1=da,FK={}.API_BASE_URL,BK={}.API_STRAPI_URL,vr=y1.create({baseURL:FK,headers:{common:{}}}),CD=y1.create({baseURL:BK,headers:{common:{}}}),zK=Gi(e=>{var t,n,r,i;return vr.interceptors.response.use(s=>(s.config.method!=="get"&&(s.data.message&&e.$stores.alert.updateAlert(s.data),console.log(s,"ini responser dari interceptor yg bukan get")),Promise.resolve(s)),s=>(e.$stores.alert.updateAlert(s.response.data),console.log(s.response.data.message,"ini response interceptor error"),Promise.reject(s))),vr.defaults.baseURL=(n=(t=e.$config)==null?void 0:t.public)==null?void 0:n.API_BASE_URL,CD.defaults.baseURL=(i=(r=e.$config)==null?void 0:r.public)==null?void 0:i.API_STRAPI_URL,{provide:{api:vr,strapiApi:CD,axios:y1}}});var Vz=typeof window<"u",NK=()=>Vz?window.innerWidth:0,$K=()=>Vz?window.innerHeight:0,jK=e=>e??NK(),UK=e=>e??$K(),VK=e=>({width:jK(e==null?void 0:e.width),height:UK(e==null?void 0:e.height)}),GK=e=>{let t=0,n=e(),r=so(VK()),i=({width:a,height:m})=>{r.width=a,r.height=m};n.addObserver("composition-api",i);let s=()=>{++t},c=()=>{t=Math.max(t-1,0)};return()=>(t===0&&n.subscribe().dispatch(),s(),Bi(()=>{c(),t===0&&n.unsubscribe()}),{width:yt(()=>r.width),height:yt(()=>r.height)})},td,Jf,hv,nd,rd,dv,zS,fv,NS,zx,Gz,TF,qK=(TF=class{constructor(t){Oa(this,dv);Oa(this,fv);Oa(this,zx);Oa(this,td,new Map);Oa(this,Jf,void 0);Oa(this,hv,void 0);Oa(this,nd,!1);Oa(this,rd,void 0);let{delay:n=33}=t??{};sl(this,Jf,n),sl(this,rd,vc(this,zx,Gz).bind(this))}addObserver(t,n){return pi(this,td).set(t,n),n(vc(this,dv,zS).call(this)),this}deleteObserver(t){return pi(this,td).delete(t),this}deleteObservers(){return pi(this,td).clear(),this}
48notifyObservers(t){return pi(this,td).forEach(n=>{n(t)}),this}subscribe(){return typeof window>"u"?this:pi(this,nd)?this:(window.addEventListener("resize",pi(this,rd)),window.addEventListener("orientationchange",pi(this,rd)),sl(this,nd,!0),this)}unsubscribe(){return pi(this,nd)?(window.removeEventListener("resize",pi(this,rd)),window.removeEventListener("orientationchange",pi(this,rd)),sl(this,nd,!1),this):this}setDelay(t){return sl(this,Jf,t),this}info(){return{delay:pi(this,Jf),subscribed:pi(this,nd),observersCount:pi(this,td).size}}dispatch(){return vc(this,fv,NS).call(this),this}},td=new WeakMap,Jf=new WeakMap,hv=new WeakMap,nd=new WeakMap,rd=new WeakMap,dv=new WeakSet,zS=function(){return typeof window>"u"?{width:0,height:0}:{width:window.innerWidth,height:window.innerHeight}},fv=new WeakSet,NS=function(){let t=vc(this,dv,zS).call(this);this.notifyObservers(t)},zx=new WeakSet,Gz=function(){clearTimeout(pi(this,hv)),window.setTimeout(()=>{},1),sl(this,hv,window.setTimeout(()=>{vc(this,fv,NS).call(this)},pi(this,Jf)))},TF),NT,WK=()=>(NT||(NT=new qK),NT),qz=GK(WK);const{width:HK}=qz(),YK={width:HK,desktopWidth:640,yoastToHead(e){var i,s,c,a,m,g,x,T;const t=e==null?void 0:e.seo,n=((t==null?void 0:t.opengraphUrl)||(t==null?void 0:t.twitterUrl)||"").replace("https://wp.brik.id/","https://brik.id/"),r=(t==null?void 0:t.metaDesc)||(t==null?void 0:t.opengraphDescription)||(t==null?void 0:t.twitterDescription);return{title:t==null?void 0:t.title,titleTemplate:"%s",meta:[{hid:"description",name:"description",content:r},{hid:"og:site_name",property:"og:site_name",content:t==null?void 0:t.opengraphSiteName},{hid:"og:type",property:"og:type",content:t==null?void 0:t.opengraphType},{hid:"og:url",property:"og:url",content:n},{hid:"og:title",property:"og:title",content:(t==null?void 0:t.opengraphTitle)||(t==null?void 0:t.twitterTitle)},{hid:"og:description",property:"og:description",content:r},{hid:"og:image",name:"og:image",content:((i=t==null?void 0:t.opengraphImage)==null?void 0:i.sourceUrl)||((s=t==null?void 0:t.twitterImage)==null?void 0:s.sourceUrl)},{hid:"og:image:secure_url",name:"og:image:secure_url",content:((c=t==null?void 0:t.opengraphImage)==null?void 0:c.sourceUrl)||((a=t==null?void 0:t.twitterImage)==null?void 0:a.sourceUrl)},{hid:"og:publisher",property:"og:publisher",content:t==null?void 0:t.opengraphPublisher},{hid:"og:published_time",property:"og:published_time",content:t==null?void 0:t.opengraphPublishedTime},{hid:"og:modified_time",property:"og:modified_time",content:t==null?void 0:t.opengraphModifiedTime},{hid:"article:publisher",property:"article:publisher",content:t==null?void 0:t.opengraphPublisher},{hid:"article:modified_time",property:"article:modified_time",content:t==null?void 0:t.opengraphModifiedTime},{hid:"article:published_time",property:"article:published_time",content:t==null?void 0:t.opengraphPublishedTime},{hid:"author",name:"author",content:(g=(m=e==null?void 0:e.author)==null?void 0:m.node)==null?void 0:g.name},{hid:"twitter:url",name:"twitter:url",content:t==null?void 0:t.opengraphUrl},{hid:"twitter:title",name:"twitter:title",content:(t==null?void 0:t.twitterTitle)||(t==null?void 0:t.opengraphTitle)},{hid:"twitter:description",name:"twitter:description",content:r},{hid:"twitter:image",name:"twitter:image",content:n},{hid:"twitter:label1",name:"twitter:label1",content:"Written by"},{hid:"twitter:data1",name:"twitter:data1",content:(T=(x=e==null?void 0:e.author)==null?void 0:x.node)==null?void 0:T.name}]}}},ZK=Gi(e=>({provide:{b:YK}}));var cx=function(){return cx=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var i in t=arguments[n])Object.prototype.hasOwnProperty.call(t,i)&&(e[i]=t[i]);return e},cx.apply(this,arguments)},XK=function(){function e(t,n,r){var i=this;this.endVal=n,this.options=r,this.version="2.8.0",this.defaults={startVal:0,decimalPlaces:0,duration:2,useEasing:!0,useGrouping:!0,useIndianSeparators:!1,smartEasingThreshold:999,smartEasingAmount:333,separator:",",decimal:".",prefix:"",suffix:"",enableScrollSpy:!1,scrollSpyDelay:200,scrollSpyOnce:!1},this.finalEndVal=null,this.useEasing=!0,this.countDown=!1,this.error="",this.startVal=0,this.paused=!0,this.once=!1,this.count=function(s){i.startTime||(i.startTime=s);var c=s-i.startTime;i.remaining=i.duration-c,i.useEasing?i.countDown?i.frameVal=i.startVal-i.easingFn(c,0,i.startVal-i.endVal,i.duration):i.frameVal=i.easingFn(c,i.startVal,i.endVal-i.startVal,i.duration):i.frameVal=i.startVal+(i.endVal-i.startVal)*(c/i.duration);var a=i.countDown?i.frameVal<i.endVal:i.frameVal>i.endVal;i.frameVal=a?i.endVal:i.frameVal,i.frameVal=Number(i.frameVal.toFixed(i.options.decimalPlaces)),i.printValue(i.frameVal),c<i.duration?i.rAF=requestAnimationFrame(i.count):i.finalEndVal!==null?i.update(i.finalEndVal):i.options.onCompleteCallback&&i.options.onCompleteCallback()},this.formatNumber=function(s){var c,a,m,g,x=s<0?"-":"";c=Math.abs(s).toFixed(i.options.decimalPlaces);var T=(c+="").split(".");if(a=T[0],m=T.length>1?i.options.decimal+T[1]:"",i.options.useGrouping){g="";for(var C=3,A=0,P=0,D=a.length;P<D;++P)i.options.useIndianSeparators&&P===4&&(C=2,A=1),P!==0&&A%C==0&&(g=i.options.separator+g),A
48++,g=a[D-P-1]+g;a=g}return i.options.numerals&&i.options.numerals.length&&(a=a.replace(/[0-9]/g,function(B){return i.options.numerals[+B]}),m=m.replace(/[0-9]/g,function(B){return i.options.numerals[+B]})),x+i.options.prefix+a+m+i.options.suffix},this.easeOutExpo=function(s,c,a,m){return a*(1-Math.pow(2,-10*s/m))*1024/1023+c},this.options=cx(cx({},this.defaults),r),this.formattingFn=this.options.formattingFn?this.options.formattingFn:this.formatNumber,this.easingFn=this.options.easingFn?this.options.easingFn:this.easeOutExpo,this.startVal=this.validateValue(this.options.startVal),this.frameVal=this.startVal,this.endVal=this.validateValue(n),this.options.decimalPlaces=Math.max(this.options.decimalPlaces),this.resetDuration(),this.options.separator=String(this.options.separator),this.useEasing=this.options.useEasing,this.options.separator===""&&(this.options.useGrouping=!1),this.el=typeof t=="string"?document.getElementById(t):t,this.el?this.printValue(this.startVal):this.error="[CountUp] target is null or undefined",typeof window<"u"&&this.options.enableScrollSpy&&(this.error?console.error(this.error,t):(window.onScrollFns=window.onScrollFns||[],window.onScrollFns.push(function(){return i.handleScroll(i)}),window.onscroll=function(){window.onScrollFns.forEach(function(s){return s()})},this.handleScroll(this)))}return e.prototype.handleScroll=function(t){if(t&&window&&!t.once){var n=window.innerHeight+window.scrollY,r=t.el.getBoundingClientRect(),i=r.top+window.pageYOffset,s=r.top+r.height+window.pageYOffset;s<n&&s>window.scrollY&&t.paused?(t.paused=!1,setTimeout(function(){return t.start()},t.options.scrollSpyDelay),t.options.scrollSpyOnce&&(t.once=!0)):(window.scrollY>s||i>n)&&!t.paused&&t.reset()}},e.prototype.determineDirectionAndSmartEasing=function(){var t=this.finalEndVal?this.finalEndVal:this.endVal;this.countDown=this.startVal>t;var n=t-this.startVal;if(Math.abs(n)>this.options.smartEasingThreshold&&this.options.useEasing){this.finalEndVal=t;var r=this.countDown?1:-1;this.endVal=t+r*this.options.smartEasingAmount,this.duration=this.duration/2}else this.endVal=t,this.finalEndVal=null;this.finalEndVal!==null?this.useEasing=!1:this.useEasing=this.options.useEasing},e.prototype.start=function(t){this.error||(this.options.onStartCallback&&this.options.onStartCallback(),t&&(this.options.onCompleteCallback=t),this.duration>0?(this.determineDirectionAndSmartEasing(),this.paused=!1,this.rAF=requestAnimationFrame(this.count)):this.printValue(this.endVal))},e.prototype.pauseResume=function(){this.paused?(this.startTime=null,this.duration=this.remaining,this.startVal=this.frameVal,this.determineDirectionAndSmartEasing(),this.rAF=requestAnimationFrame(this.count)):cancelAnimationFrame(this.rAF),this.paused=!this.paused},e.prototype.reset=function(){cancelAnimationFrame(this.rAF),this.paused=!0,this.resetDuration(),this.startVal=this.validateValue(this.options.startVal),this.frameVal=this.startVal,this.printValue(this.startVal)},e.prototype.update=function(t){cancelAnimationFrame(this.rAF),this.startTime=null,this.endVal=this.validateValue(t),this.endVal!==this.frameVal&&(this.startVal=this.frameVal,this.finalEndVal==null&&this.resetDuration(),this.finalEndVal=null,this.determineDirectionAndSmartEasing(),this.rAF=requestAnimationFrame(this.count))},e.prototype.printValue=function(t){var n;if(this.el){var r=this.formattingFn(t);(n=this.options.plugin)!==null&&n!==void 0&&n.render?this.options.plugin.render(this.el,r):this.el.tagName==="INPUT"?this.el.value=r:this.el.tagName==="text"||this.el.tagName==="tspan"?this.el.textContent=r:this.el.innerHTML=r}},e.prototype.ensureNumber=function(t){return typeof t=="number"&&!isNaN(t)},e.prototype.validateValue=function(t){var n=Number(t);return this.ensureNumber(n)?n:(this.error="[CountUp] invalid start or end value: ".concat(t),null)},e.prototype.resetDuration=function(){this.startTime=null,this.duration=1e3*Number(this.options.duration),this.remaining=this.duration},e}();const KK={class:"countup-wrap"},QK=sr({name:"CountUp",props:{endVal:{},startVal:{default:0},duration:{default:2.5},decimalPlaces:{default:0},autoplay:{type:Boolean,default:!0},loop:{type:[Boolean,Number],default:!1},delay:{default:0},options:{default:void 0}},emits:["init","finished"],setup(e,{expose:t,emit:n}){const r=e,i=n;
48let s=jt(),c=jt(),a=0;const m=jt(!1);let g;function x(){if(!s.value)return void console.warn("[vue-countup-v3]","elRef can't found");a=0,m.value=!1;const A=Number(r.startVal),P=Number(r.endVal),D=Number(r.duration);c.value=new XK(s.value,P,{startVal:A,duration:D,decimalPlaces:r.decimalPlaces,...r.options}),c.value.error?console.error("[vue-countup-v3]",c.value.error):i("init",c.value)}function T(){var A;c.value||x(),(A=c.value)==null||A.start(function(){typeof r.loop=="boolean"&&r.loop||r.loop>a?g=function(P,D=1){const B=jt(-1);let R;return B.value=requestAnimationFrame(function N(j){R||(R=j),j-R<1e3*D?B.value=requestAnimationFrame(N):P()}),{cancel:function(){window.cancelAnimationFrame(B.value)}}}(()=>{var P;(P=c.value)==null||P.reset(),T()},r.delay):m.value=!0}),a++}function C(){g==null||g.cancel(),x(),T()}return Nn([()=>r.startVal,()=>r.endVal],()=>{r.autoplay&&C()}),Nn(m,A=>{var P;A&&((P=r.options)!=null&&P.onCompleteCallback&&r.options.onCompleteCallback(),i("finished"))}),Dr(()=>{x(),r.autoplay&&T()}),Bi(()=>{var A;g==null||g.cancel(),(A=c.value)==null||A.reset()}),t({init:x,restart:C}),(A,P)=>(At(),Wt("div",KK,[En(A.$slots,"prefix"),Un("span",{ref_key:"elRef",ref:s},null,512),En(A.$slots,"suffix")]))}}),JK=Gi(e=>{e.vueApp.component("CountUp",QK)});var oo=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function Rd(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}function eQ(e){if(e.__esModule)return e;var t=e.default;if(typeof t=="function"){var n=function r(){if(this instanceof r){var i=[null];i.push.apply(i,arguments);var s=Function.bind.apply(t,i);return new s}return t.apply(this,arguments)};n.prototype=t.prototype}else n={};return Object.defineProperty(n,"__esModule",{value:!0}),Object.keys(e).forEach(function(r){var i=Object.getOwnPropertyDescriptor(e,r);Object.defineProperty(n,r,i.get?i:{enumerable:!0,get:function(){return e[r]}})}),n}var Wz={exports:{}};(function(e,t){(function(n,r){e.exports=r()})(oo,function(){var n=1e3,r=6e4,i=36e5,s="millisecond",c="second",a="minute",m="hour",g="day",x="week",T="month",C="quarter",A="year",P="date",D="Invalid Date",B=/^(\d{4})[-/]?(\d{1,2})?[-/]?(\d{0,2})[Tt\s]*(\d{1,2})?:?(\d{1,2})?:?(\d{1,2})?[.:]?(\d+)?$/,R=/\[([^\]]+)]|Y{1,4}|M{1,4}|D{1,2}|d{1,4}|H{1,2}|h{1,2}|a|A|m{1,2}|s{1,2}|Z{1,2}|SSS/g,N={name:"en",weekdays:"Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),months:"January_February_March_April_May_June_July_August_September_October_November_December".split("_"),ordinal:function(fe){var ie=["th","st","nd","rd"],xe=fe%100;return"["+fe+(ie[(xe-20)%10]||ie[xe]||ie[0])+"]"}},j=function(fe,ie,xe){var Te=String(fe);return!Te||Te.length>=ie?fe:""+Array(ie+1-Te.length).join(xe)+fe},U={s:j,z:function(fe){var ie=-fe.utcOffset(),xe=Math.abs(ie),Te=Math.floor(xe/60),oe=xe%60;return(ie<=0?"+":"-")+j(Te,2,"0")+":"+j(oe,2,"0")},m:function fe(ie,xe){if(ie.date()<xe.date())return-fe(xe,ie);var Te=12*(xe.year()-ie.year())+(xe.month()-ie.month()),oe=ie.clone().add(Te,T),ne=xe-oe<0,le=ie.clone().add(Te+(ne?-1:1),T);return+(-(Te+(xe-oe)/(ne?oe-le:le-oe))||0)},a:function(fe){return fe<0?Math.ceil(fe)||0:Math.floor(fe)},p:function(fe){return{M:T,y:A,w:x,d:g,D:P,h:m,m:a,s:c,ms:s,Q:C}[fe]||String(fe||"").toLowerCase().replace(/s$/,"")},u:function(fe){return fe===void 0}},W="en",Q={};Q[W]=N;var Z=function(fe){return fe instanceof ge},K=function fe(ie,xe,Te){var oe;if(!ie)return W;if(typeof ie=="string"){var ne=ie.toLowerCase();Q[ne]&&(oe=ne),xe&&(Q[ne]=xe,oe=ne);var le=ie.split("-");if(!oe&&le.length>1)return fe(le[0])}else{var se=ie.name;Q[se]=ie,oe=se}return!Te&&oe&&(W=oe),oe||!Te&&W},Y=function(fe,ie){if(Z(fe))return fe.clone();var xe=typeof ie=="object"?ie:{};return xe.date=fe,xe.args=arguments,new ge(xe)},me=U;me.l=K,me.i=Z,me.w=function(fe,ie){return Y(fe,{locale:ie.$L,utc:ie.$u,x:ie.$x,$offset:ie.$offset})};var ge=function(){function fe(xe){this.$L=K(xe.locale,null,!0),this.parse(xe)}var ie=fe.prototype;return ie.parse=function(xe){this.$d=function(Te){var oe=Te.date,ne=Te.utc;if(oe===null)return new Date(NaN);if(me.u(oe))return new Date;if(oe instanceof Date)return new Date(oe);
vendor: 5,073 bytes, line 48
48if(typeof oe=="string"&&!/Z$/i.test(oe)){var le=oe.match(B);if(le){var se=le[2]-1||0,Ne=(le[7]||"0").substring(0,3);return ne?new Date(Date.UTC(le[1],se,le[3]||1,le[4]||0,le[5]||0,le[6]||0,Ne)):new Date(le[1],se,le[3]||1,le[4]||0,le[5]||0,le[6]||0,Ne)}}return new Date(oe)}(xe),this.$x=xe.x||{},this.init()},ie.init=function(){var xe=this.$d;this.$y=xe.getFullYear(),this.$M=xe.getMonth(),this.$D=xe.getDate(),this.$W=xe.getDay(),this.$H=xe.getHours(),this.$m=xe.getMinutes(),this.$s=xe.getSeconds(),this.$ms=xe.getMilliseconds()},ie.$utils=function(){return me},ie.isValid=function(){return this.$d.toString()!==D},ie.isSame=function(xe,Te){var oe=Y(xe);return this.startOf(Te)<=oe&&oe<=this.endOf(Te)},ie.isAfter=function(xe,Te){return Y(xe)<this.startOf(Te)},ie.isBefore=function(xe,Te){return this.endOf(Te)<Y(xe)},ie.$g=function(xe,Te,oe){return me.u(xe)?this[Te]:this.set(oe,xe)},ie.unix=function(){return Math.floor(this.valueOf()/1e3)},ie.valueOf=function(){return this.$d.getTime()},ie.startOf=function(xe,Te){var oe=this,ne=!!me.u(Te)||Te,le=me.p(xe),se=function(st,tt){var Me=me.w(oe.$u?Date.UTC(oe.$y,tt,st):new Date(oe.$y,tt,st),oe);return ne?Me:Me.endOf(g)},Ne=function(st,tt){return me.w(oe.toDate()[st].apply(oe.toDate("s"),(ne?[0,0,0,0]:[23,59,59,999]).slice(tt)),oe)},Se=this.$W,xt=this.$M,kt=this.$D,wt="set"+(this.$u?"UTC":"");switch(le){case A:return ne?se(1,0):se(31,11);case T:return ne?se(1,xt):se(0,xt+1);case x:var Ue=this.$locale().weekStart||0,je=(Se<Ue?Se+7:Se)-Ue;return se(ne?kt-je:kt+(6-je),xt);case g:case P:return Ne(wt+"Hours",0);case m:return Ne(wt+"Minutes",1);case a:return Ne(wt+"Seconds",2);case c:return Ne(wt+"Milliseconds",3);default:return this.clone()}},ie.endOf=function(xe){return this.startOf(xe,!1)},ie.$set=function(xe,Te){var oe,ne=me.p(xe),le="set"+(this.$u?"UTC":""),se=(oe={},oe[g]=le+"Date",oe[P]=le+"Date",oe[T]=le+"Month",oe[A]=le+"FullYear",oe[m]=le+"Hours",oe[a]=le+"Minutes",oe[c]=le+"Seconds",oe[s]=le+"Milliseconds",oe)[ne],Ne=ne===g?this.$D+(Te-this.$W):Te;if(ne===T||ne===A){var Se=this.clone().set(P,1);Se.$d[se](Ne),Se.init(),this.$d=Se.set(P,Math.min(this.$D,Se.daysInMonth())).$d}else se&&this.$d[se](Ne);return this.init(),this},ie.set=function(xe,Te){return this.clone().$set(xe,Te)},ie.get=function(xe){return this[me.p(xe)]()},ie.add=function(xe,Te){var oe,ne=this;xe=Number(xe);var le=me.p(Te),se=function(xt){var kt=Y(ne);return me.w(kt.date(kt.date()+Math.round(xt*xe)),ne)};if(le===T)return this.set(T,this.$M+xe);if(le===A)return this.set(A,this.$y+xe);if(le===g)return se(1);if(le===x)return se(7);var Ne=(oe={},oe[a]=r,oe[m]=i,oe[c]=n,oe)[le]||1,Se=this.$d.getTime()+xe*Ne;return me.w(Se,this)},ie.subtract=function(xe,Te){return this.add(-1*xe,Te)},ie.format=function(xe){var Te=this,oe=this.$locale();if(!this.isValid())return oe.invalidDate||D;var ne=xe||"YYYY-MM-DDTHH:mm:ssZ",le=me.z(this),se=this.$H,Ne=this.$m,Se=this.$M,xt=oe.weekdays,kt=oe.months,wt=oe.meridiem,Ue=function(tt,Me,lt,Ae){return tt&&(tt[Me]||tt(Te,ne))||lt[Me].slice(0,Ae)},je=function(tt){return me.s(se%12||12,tt,"0")},st=wt||function(tt,Me,lt){var Ae=tt<12?"AM":"PM";return lt?Ae.toLowerCase():Ae};return ne.replace(R,function(tt,Me){return Me||function(lt){switch(lt){case"YY":return String(Te.$y).slice(-2);case"YYYY":return me.s(Te.$y,4,"0");case"M":return Se+1;case"MM":return me.s(Se+1,2,"0");case"MMM":return Ue(oe.monthsShort,Se,kt,3);case"MMMM":return Ue(kt,Se);case"D":return Te.$D;case"DD":return me.s(Te.$D,2,"0");case"d":return String(Te.$W);case"dd":return Ue(oe.weekdaysMin,Te.$W,xt,2);case"ddd":return Ue(oe.weekdaysShort,Te.$W,xt,3);case"dddd":return xt[Te.$W];case"H":return String(se);case"HH":return me.s(se,2,"0");case"h":return je(1);case"hh":return je(2);case"a":return st(se,Ne,!0);case"A":return st(se,Ne,!1);case"m":return String(Ne);case"mm":return me.s(Ne,2,"0");case"s":return String(Te.$s);case"ss":return me.s(Te.$s,2,"0");case"SSS":return me.s(Te.$ms,3,"0");case"Z":return le}return null}(tt)||le.replace(":","")})},ie.utcOffset=function(){return 15*-Math.round(this.$d.getTimezoneOffset()/15)},ie.diff=function(xe,Te,oe){var ne,le=this,se=me.p(Te),Ne=Y(xe),Se=(Ne.utcOffset()-this.utcOffset())*r,xt=this-Ne,kt=function(){return me.m(le,Ne)};switch(se){case A:ne=kt()/12;break;case T:ne=kt();break;case C:ne=kt()/3;break;case x:ne=(xt-Se)/6048e5;break;case g:ne=(xt-Se)/864e5;break;case m:ne=xt/i;break;case a:ne=xt/r;break;case c:ne=xt/n;break;default:ne=xt}return oe?ne:me.a(ne)},ie.daysInMonth=function(){return this.endOf(T).$D},ie.$locale=function(){return Q[this.$L]},ie.locale=function(xe,Te){if(!xe)return this.$L;var oe=this.clone(),ne=K(xe,Te,!0);return ne&&(oe.$L=ne),oe},ie.clone=function(){return me.w(this.$d,this)},ie.toDate=function(){return new Date(this.valueOf())},ie.toJSON=function(){return this.isValid()?this.toISOString():null},ie.toISOString=function(){return this.$d.toISOString()},ie.toString=function(){return this.$d.toUTCString()},fe}(),ce=ge.prototype;return Y.prototype=ce,[["$ms",s],["$s",c],["$m",a],["$H",m],["$W",g],["$M",T],["$y",A],["$D",P]].forEac
48h(function(fe){ce[fe[1]]=function(ie){return this.$g(ie,fe[0],fe[1])}}),Y.extend=function(fe,ie){return fe.$i||(fe(ie,ge,Y),fe.$i=!0),Y},Y.locale=K,Y.isDayjs=Z,Y.unix=function(fe){return Y(1e3*fe)},Y.en=Q[W],Y.Ls=Q,Y.p={},Y})})(Wz);var tQ=Wz.exports;const ux=Rd(tQ),nQ={format(e,{withTime:t,format:n}={withTime:!1}){return n||(n="DD/MM/YYYY",t&&(n=n+" - HH:mm")),ux(e).format(n)},dayjs:ux},rQ=Gi(e=>({provide:{date:nQ}})),iQ={date(e,{withTime:t,format:n}={withTime:!1}){return n||(n="DD/MM/YYYY",t&&(n=n+" - HH:mm")),ux(e).format(n)},dayjs:ux,price(e,{prefix:t}={}){let n=String(Number(e)).replace(/\B(?=(\d{3})+(?!\d))/g,".");return`${typeof t!="string"?"Rp ":t}${n}`}},oQ=Gi(e=>({provide:{format:iQ}}));/*!
49  * shared v11.0.1
50  * (c) 2024 kazuya kawaguchi
51  * Released under the MIT License.
52  */const hx=typeof window<"u",Fd=(e,t=!1)=>t?Symbol.for(e):Symbol(e),aQ=(e,t,n)=>sQ({l:e,k:t,s:n}),sQ=e=>JSON.stringify(e).replace(/\u2028/g,"\\u2028").replace(/\u2029/g,"\\u2029").replace(/\u0027/g,"\\u0027"),Qo=e=>typeof e=="number"&&isFinite(e),lQ=e=>Qk(e)==="[object Date]",og=e=>Qk(e)==="[object RegExp]",_1=e=>Or(e)&&Object.keys(e).length===0,ha=Object.assign,cQ=Object.create,Ri=(e=null)=>cQ(e);let kD;const Xf=()=>kD||(kD=typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:typeof global<"u"?global:Ri());function AD(e){return e.replace(/</g,"&lt;").replace(/>/g,"&gt;").replace(/"/g,"&quot;").replace(/'/g,"&apos;")}const uQ=Object.prototype.hasOwnProperty;function Cc(e,t){return uQ.call(e,t)}const Jo=Array.isArray,io=e=>typeof e=="function",On=e=>typeof e=="string",li=e=>typeof e=="boolean",gi=e=>e!==null&&typeof e=="object",hQ=e=>gi(e)&&io(e.then)&&io(e.catch),Hz=Object.prototype.toString,Qk=e=>Hz.call(e),Or=e=>Qk(e)==="[object Object]",dQ=e=>e==null?"":Jo(e)||Or(e)&&e.toString===Hz?JSON.stringify(e,null,2):String(e);function Jk(e,t=""){return e.reduce((n,r,i)=>i===0?n+r:n+t+r,"")}function fQ(e,t){typeof console<"u"&&(console.warn("[intlify] "+e),t&&console.warn(t.stack))}const ib=e=>!gi(e)||Jo(e);function Mb(e,t){if(ib(e)||ib(t))throw new Error("Invalid value");const n=[{src:e,des:t}];for(;n.length;){const{src:r,des:i}=n.pop();Object.keys(r).forEach(s=>{s!=="__proto__"&&(gi(r[s])&&!gi(i[s])&&(i[s]=Array.isArray(r[s])?[]:Ri()),ib(i[s])||ib(r[s])?i[s]=r[s]:n.push({src:r[s],des:i[s]}))})}}/*!
53  * message-compiler v11.0.1
54  * (c) 2024 kazuya kawaguchi
55  * Released under the MIT License.
56  */function pQ(e,t,n){return{line:e,column:t,offset:n}}function $S(e,t,n){const r={start:e,end:t};return n!=null&&(r.source=n),r}const Ci={EXPECTED_TOKEN:1,INVALID_TOKEN_IN_PLACEHOLDER:2,UNTERMINATED_SINGLE_QUOTE_IN_PLACEHOLDER:3,UNKNOWN_ESCAPE_SEQUENCE:4,INVALID_UNICODE_ESCAPE_SEQUENCE:5,UNBALANCED_CLOSING_BRACE:6,UNTERMINATED_CLOSING_BRACE:7,EMPTY_PLACEHOLDER:8,NOT_ALLOW_NEST_PLACEHOLDER:9,INVALID_LINKED_FORMAT:10,MUST_HAVE_MESSAGES_IN_PLURAL:11,UNEXPECTED_EMPTY_LINKED_MODIFIER:12,UNEXPECTED_EMPTY_LINKED_KEY:13,UNEXPECTED_LEXICAL_ANALYSIS:14,UNHANDLED_CODEGEN_NODE_TYPE:15,UNHANDLED_MINIFIER_NODE_TYPE:16},mQ=17;function v1(e,t,n={}){const{domain:r,messages:i,args:s}=n,c=e,a=new SyntaxError(String(c));return a.code=e,t&&(a.location=t),a.domain=r,a}function gQ(e){throw e}const qu=" ",yQ="\r",fs=`
57`,_Q=String.fromCharCode(8232),vQ=String.fromCharCode(8233);function bQ(e){const t=e;let n=0,r=1,i=1,s=0;const c=Z=>t[Z]===yQ&&t[Z+1]===fs,a=Z=>t[Z]===fs,m=Z=>t[Z]===vQ,g=Z=>t[Z]===_Q,x=Z=>c(Z)||a(Z)||m(Z)||g(Z),T=()=>n,C=()=>r,A=()=>i,P=()=>s,D=Z=>c(Z)||m(Z)||g(Z)?fs:t[Z],B=()=>D(n),R=()=>D(n+s);function N(){return s=0,x(n)&&(r++,i=0),c(n)&&n++,n++,i++,t[n]}function j(){return c(n+s)&&s++,s++,t[n+s]}function U(){n=0,r=1,i=1,s=0}function W(Z=0){s=Z}function Q(){const Z=n+s;for(;Z!==n;)N();s=0}return{index:T,line:C,column:A,peekOffset:P,charAt:D,currentChar:B,currentPeek:R,next:N,peek:j,reset:U,resetPeek:W,skipToPeek:Q}}const Gh=void 0,xQ=".",PD="'",wQ="tokenizer";function TQ(e,t={}){const n=t.location!==!1,r=bQ(e),i=()=>r.index(),s=()=>pQ(r.line(),r.column(),r.index()),c=s(),a=i(),m={currentType:13,offset:a,startLoc:c,endLoc:c,lastType:13,lastOffset:a,lastStartLoc:c,lastEndLoc:c,braceNest:0,inLinked:!1,text:""},g=()=>m,{onError:x}=t;function T(Ie,Pe,rt,...Tt){const pn=g();if(Pe.column+=rt,Pe.offset+=rt,x){const qt=n?$S(pn.startLoc,Pe):null,nt=v1(Ie,qt,{domain:wQ,args:Tt});x(nt)}}function C(Ie,Pe,rt){Ie.endLoc=s(),Ie.currentType=Pe;const Tt={type:Pe};return n&&(Tt.loc=$S(Ie.startLoc,Ie.endLoc)),rt!=null&&(Tt.value=rt),Tt}const A=Ie=>C(Ie,13);function P(Ie,Pe){return Ie.currentChar()===Pe?(Ie.next(),Pe):(T(Ci.EXPECTED_TOKEN,s(),0,Pe),"")}function D(Ie){let Pe="";for(;Ie.currentPeek()===qu||Ie.currentPeek()===fs;)Pe+=Ie.currentPeek(),Ie.peek();return Pe}function B(Ie){const Pe=D(Ie);return Ie.skipToPeek(),Pe}function R(Ie){if(Ie===Gh)return!1;const Pe=Ie.charCodeAt(0);return Pe>=97&&Pe<=122||Pe>=65&&Pe<=90||Pe===95}function N(Ie){if(Ie===Gh)return!1;const Pe=Ie.charCodeAt(0);return Pe>=48&&Pe<=57}function j(Ie,Pe){const{currentType:rt}=Pe;if(rt!==2)return!1;D(Ie);const Tt=R(Ie.currentPeek());return Ie.resetPeek(),Tt}function U(Ie,Pe){const{currentType:rt}=Pe;if(rt!==2)return!1;D(Ie);const Tt=Ie.currentPeek()==="-"?Ie.peek():Ie.currentPeek(),pn=N(Tt);return Ie.resetPeek(),pn}function W(Ie,Pe){const{currentType:rt}=Pe;if(rt!==2)return!1;D(Ie);const Tt=Ie.currentPeek()===PD;return Ie.resetPeek(),Tt}function Q(Ie,Pe){const{currentType:rt}=Pe;if(rt!==7)return!1;D(Ie);const Tt=Ie.currentPeek()===".";return Ie.resetPeek(),Tt}function Z(Ie,Pe){const{currentType:rt}=Pe;if(rt!==8)return!1;D(Ie);const Tt=R(Ie.currentPeek());return Ie.resetPeek(),Tt}function K(Ie,Pe){const{currentType:rt}=Pe;if(!(rt===7||rt===11))return!1;D(Ie);const Tt=Ie.currentPeek()===":";return Ie.resetPeek(),Tt}function Y(Ie,Pe){const{currentType:rt}=Pe;if(rt!==9)return!1;const Tt=()=>{const qt=Ie.currentPeek();return qt==="{"?R(Ie.peek()):qt==="@"||qt==="|"||qt===":"||qt==="."||qt===qu||!qt?!1:qt===fs?(Ie.peek(),Tt()):ge(Ie,!1)},pn=Tt();return Ie.resetPeek(),pn}function me(Ie){D(Ie);const Pe=Ie.currentPeek()==="|";return Ie.resetPeek(),Pe}function ge(Ie,Pe=!0){const rt=(pn=!1,qt="")=>{const nt=Ie.currentPeek();return nt==="{"||nt==="@"||!nt?pn:nt==="|"?!(qt===qu||qt===fs):nt===qu?(Ie.peek(),rt(!0,qu)):nt===fs?(Ie.peek(),rt(!0,fs)):!0},Tt=rt();return Pe&&Ie.resetPeek(),Tt}function ce(Ie,Pe){const rt=Ie.currentChar();return rt===Gh?Gh:Pe(rt)?(Ie.next(),rt):null}function fe(Ie){const Pe=Ie.charCodeAt(0);return Pe>=97&&Pe<=122||Pe>=65&&Pe<=90||Pe>=48&&Pe<=57||Pe===95||Pe===36}function ie(Ie){return ce(Ie,fe)}function xe(Ie){const Pe=Ie.charCodeAt(0);return Pe>=97&&Pe<=122||Pe>=65&&Pe<=90||Pe>=48&&Pe<=57||Pe===95||Pe===36||Pe===45}function Te(Ie){return ce(Ie,xe)}function oe(Ie){const Pe=Ie.charCodeAt(0);return Pe>=48&&Pe<=57}function ne(Ie){return ce(Ie,oe)}function le(Ie){const Pe=Ie.charCodeAt(0);return Pe>=48&&Pe<=57||Pe>=65&&Pe<=70||Pe>=97&&Pe<=102}function se(Ie){return ce(Ie,le)}function Ne(Ie){let Pe="",rt="";for(;Pe=ne(Ie);)rt+=Pe;return rt}function Se(Ie){let Pe="";for(;;){const rt=Ie.currentChar();if(rt==="{"||rt==="}"||rt==="@"||rt==="|"||!rt)break;if(rt===qu||rt===fs)if(ge(Ie))Pe+=rt,Ie.next();else{if(me(Ie))break;Pe+=rt,Ie.next()}else Pe+=rt,Ie.next()}return Pe}function xt(Ie){B(Ie);let Pe="",rt="";for(;Pe=Te(Ie);)rt+=Pe;return Ie.currentChar()===Gh&&T(Ci.UNTERMINATED_CLOSING_BRACE,s(),0),rt}function kt(Ie){B(Ie);let Pe="";return Ie.currentChar()==="-"?(Ie.next(),Pe+=`-${Ne(Ie)}`):Pe+=Ne(Ie),Ie.currentChar()===Gh&&T(Ci.UNTERMINATED_CLOSING_BRACE,s(),0),Pe}function wt(Ie){return Ie!==PD&&Ie!==fs}function Ue(Ie){B(Ie),P(Ie,"'");let Pe="",rt="";for(;Pe=ce(Ie,wt);)Pe==="\\"?rt+=je(Ie):rt+=Pe;const Tt=Ie.currentChar();return Tt===fs||Tt===Gh?(T(Ci.UNTERMINATED_SINGLE_QUOTE_IN_PLACEHOLDER,s(),0),Tt===fs&&(Ie.next(),P(Ie,"'")),rt):(P(Ie,"'"),rt)}function je(Ie){const Pe=Ie.currentChar();switch(Pe){case"\\":case"'":return Ie.next(),`\\${Pe}`;case"u":return st(Ie,Pe,4);case"U":return st(Ie,Pe,6);default:return T(Ci.UNKNOWN_ESCAPE_SEQUENCE,s(),0,Pe),""}}function st(Ie,Pe,rt){P(Ie,Pe);let Tt="";for(let pn=0;pn<rt;pn++){const qt=se(Ie);
57if(!qt){T(Ci.INVALID_UNICODE_ESCAPE_SEQUENCE,s(),0,`\\${Pe}${Tt}${Ie.currentChar()}`);break}Tt+=qt}return`\\${Pe}${Tt}`}function tt(Ie){return Ie!=="{"&&Ie!=="}"&&Ie!==qu&&Ie!==fs}function Me(Ie){B(Ie);let Pe="",rt="";for(;Pe=ce(Ie,tt);)rt+=Pe;return rt}function lt(Ie){let Pe="",rt="";for(;Pe=ie(Ie);)rt+=Pe;return rt}function Ae(Ie){const Pe=rt=>{const Tt=Ie.currentChar();return Tt==="{"||Tt==="@"||Tt==="|"||Tt==="("||Tt===")"||!Tt||Tt===qu?rt:(rt+=Tt,Ie.next(),Pe(rt))};return Pe("")}function we(Ie){B(Ie);const Pe=P(Ie,"|");return B(Ie),Pe}function Je(Ie,Pe){let rt=null;switch(Ie.currentChar()){case"{":return Pe.braceNest>=1&&T(Ci.NOT_ALLOW_NEST_PLACEHOLDER,s(),0),Ie.next(),rt=C(Pe,2,"{"),B(Ie),Pe.braceNest++,rt;case"}":return Pe.braceNest>0&&Pe.currentType===2&&T(Ci.EMPTY_PLACEHOLDER,s(),0),Ie.next(),rt=C(Pe,3,"}"),Pe.braceNest--,Pe.braceNest>0&&B(Ie),Pe.inLinked&&Pe.braceNest===0&&(Pe.inLinked=!1),rt;case"@":return Pe.braceNest>0&&T(Ci.UNTERMINATED_CLOSING_BRACE,s(),0),rt=ct(Ie,Pe)||A(Pe),Pe.braceNest=0,rt;default:{let pn=!0,qt=!0,nt=!0;if(me(Ie))return Pe.braceNest>0&&T(Ci.UNTERMINATED_CLOSING_BRACE,s(),0),rt=C(Pe,1,we(Ie)),Pe.braceNest=0,Pe.inLinked=!1,rt;if(Pe.braceNest>0&&(Pe.currentType===4||Pe.currentType===5||Pe.currentType===6))return T(Ci.UNTERMINATED_CLOSING_BRACE,s(),0),Pe.braceNest=0,mt(Ie,Pe);if(pn=j(Ie,Pe))return rt=C(Pe,4,xt(Ie)),B(Ie),rt;if(qt=U(Ie,Pe))return rt=C(Pe,5,kt(Ie)),B(Ie),rt;if(nt=W(Ie,Pe))return rt=C(Pe,6,Ue(Ie)),B(Ie),rt;if(!pn&&!qt&&!nt)return rt=C(Pe,12,Me(Ie)),T(Ci.INVALID_TOKEN_IN_PLACEHOLDER,s(),0,rt.value),B(Ie),rt;break}}return rt}function ct(Ie,Pe){const{currentType:rt}=Pe;let Tt=null;const pn=Ie.currentChar();switch((rt===7||rt===8||rt===11||rt===9)&&(pn===fs||pn===qu)&&T(Ci.INVALID_LINKED_FORMAT,s(),0),pn){case"@":return Ie.next(),Tt=C(Pe,7,"@"),Pe.inLinked=!0,Tt;case".":return B(Ie),Ie.next(),C(Pe,8,".");case":":return B(Ie),Ie.next(),C(Pe,9,":");default:return me(Ie)?(Tt=C(Pe,1,we(Ie)),Pe.braceNest=0,Pe.inLinked=!1,Tt):Q(Ie,Pe)||K(Ie,Pe)?(B(Ie),ct(Ie,Pe)):Z(Ie,Pe)?(B(Ie),C(Pe,11,lt(Ie))):Y(Ie,Pe)?(B(Ie),pn==="{"?Je(Ie,Pe)||Tt:C(Pe,10,Ae(Ie))):(rt===7&&T(Ci.INVALID_LINKED_FORMAT,s(),0),Pe.braceNest=0,Pe.inLinked=!1,mt(Ie,Pe))}}function mt(Ie,Pe){let rt={type:13};if(Pe.braceNest>0)return Je(Ie,Pe)||A(Pe);if(Pe.inLinked)return ct(Ie,Pe)||A(Pe);switch(Ie.currentChar()){case"{":return Je(Ie,Pe)||A(Pe);case"}":return T(Ci.UNBALANCED_CLOSING_BRACE,s(),0),Ie.next(),C(Pe,3,"}");case"@":return ct(Ie,Pe)||A(Pe);default:{if(me(Ie))return rt=C(Pe,1,we(Ie)),Pe.braceNest=0,Pe.inLinked=!1,rt;if(ge(Ie))return C(Pe,0,Se(Ie));break}}return rt}function Vt(){const{currentType:Ie,offset:Pe,startLoc:rt,endLoc:Tt}=m;return m.lastType=Ie,m.lastOffset=Pe,m.lastStartLoc=rt,m.lastEndLoc=Tt,m.offset=i(),m.startLoc=s(),r.currentChar()===Gh?C(m,13):mt(r,m)}return{nextToken:Vt,currentOffset:i,currentPosition:s,context:g}}const EQ="parser",SQ=/(?:\\\\|\\'|\\u([0-9a-fA-F]{4})|\\U([0-9a-fA-F]{6}))/g;
57function CQ(e,t,n){switch(e){case"\\\\":return"\\";case"\\'":return"'";default:{const r=parseInt(t||n,16);return r<=55295||r>=57344?String.fromCodePoint(r):"�"}}}function kQ(e={}){const t=e.location!==!1,{onError:n}=e;function r(R,N,j,U,...W){const Q=R.currentPosition();if(Q.offset+=U,Q.column+=U,n){const Z=t?$S(j,Q):null,K=v1(N,Z,{domain:EQ,args:W});n(K)}}function i(R,N,j){const U={type:R};return t&&(U.start=N,U.end=N,U.loc={start:j,end:j}),U}function s(R,N,j,U){t&&(R.end=N,R.loc&&(R.loc.end=j))}function c(R,N){const j=R.context(),U=i(3,j.offset,j.startLoc);return U.value=N,s(U,R.currentOffset(),R.currentPosition()),U}function a(R,N){const j=R.context(),{lastOffset:U,lastStartLoc:W}=j,Q=i(5,U,W);return Q.index=parseInt(N,10),R.nextToken(),s(Q,R.currentOffset(),R.currentPosition()),Q}function m(R,N){const j=R.context(),{lastOffset:U,lastStartLoc:W}=j,Q=i(4,U,W);return Q.key=N,R.nextToken(),s(Q,R.currentOffset(),R.currentPosition()),Q}function g(R,N){const j=R.context(),{lastOffset:U,lastStartLoc:W}=j,Q=i(9,U,W);return Q.value=N.replace(SQ,CQ),R.nextToken(),s(Q,R.currentOffset(),R.currentPosition()),Q}function x(R){const N=R.nextToken(),j=R.context(),{lastOffset:U,lastStartLoc:W}=j,Q=i(8,U,W);return N.type!==11?(r(R,Ci.UNEXPECTED_EMPTY_LINKED_MODIFIER,j.lastStartLoc,0),Q.value="",s(Q,U,W),{nextConsumeToken:N,node:Q}):(N.value==null&&r(R,Ci.UNEXPECTED_LEXICAL_ANALYSIS,j.lastStartLoc,0,eu(N)),Q.value=N.value||"",s(Q,R.currentOffset(),R.currentPosition()),{node:Q})}function T(R,N){const j=R.context(),U=i(7,j.offset,j.startLoc);return U.value=N,s(U,R.currentOffset(),R.currentPosition()),U}function C(R){const N=R.context(),j=i(6,N.offset,N.startLoc);let U=R.nextToken();if(U.type===8){const W=x(R);j.modifier=W.node,U=W.nextConsumeToken||R.nextToken()}switch(U.type!==9&&r(R,Ci.UNEXPECTED_LEXICAL_ANALYSIS,N.lastStartLoc,0,eu(U)),U=R.nextToken(),U.type===2&&(U=R.nextToken()),U.type){case 10:U.value==null&&r(R,Ci.UNEXPECTED_LEXICAL_ANALYSIS,N.lastStartLoc,0,eu(U)),j.key=T(R,U.value||"");break;case 4:U.value==null&&r(R,Ci.UNEXPECTED_LEXICAL_ANALYSIS,N.lastStartLoc,0,eu(U)),j.key=m(R,U.value||"");break;case 5:U.value==null&&r(R,Ci.UNEXPECTED_LEXICAL_ANALYSIS,N.lastStartLoc,0,eu(U)),j.key=a(R,U.value||"");break;case 6:U.value==null&&r(R,Ci.UNEXPECTED_LEXICAL_ANALYSIS,N.lastStartLoc,0,eu(U)),j.key=g(R,U.value||"");break;default:{r(R,Ci.UNEXPECTED_EMPTY_LINKED_KEY,N.lastStartLoc,0);const W=R.context(),Q=i(7,W.offset,W.startLoc);return Q.value="",s(Q,W.offset,W.startLoc),j.key=Q,s(j,W.offset,W.startLoc),{nextConsumeToken:U,node:j}}}return s(j,R.currentOffset(),R.currentPosition()),{node:j}}function A(R){const N=R.context(),j=N.currentType===1?R.currentOffset():N.offset,U=N.currentType===1?N.endLoc:N.startLoc,W=i(2,j,U);W.items=[];let Q=null;do{const Y=Q||R.nextToken();switch(Q=null,Y.type){case 0:Y.value==null&&r(R,Ci.UNEXPECTED_LEXICAL_ANALYSIS,N.lastStartLoc,0,eu(Y)),W.items.push(c(R,Y.value||""));break;case 5:Y.value==null&&r(R,Ci.UNEXPECTED_LEXICAL_ANALYSIS,N.lastStartLoc,0,eu(Y)),W.items.push(a(R,Y.value||""));break;case 4:Y.value==null&&r(R,Ci.UNEXPECTED_LEXICAL_ANALYSIS,N.lastStartLoc,0,eu(Y)),W.items.push(m(R,Y.value||""));break;case 6:Y.value==null&&r(R,Ci.UNEXPECTED_LEXICAL_ANALYSIS,N.lastStartLoc,0,eu(Y)),W.items.push(g(R,Y.value||""));break;case 7:{const me=C(R);W.items.push(me.node),Q=me.nextConsumeToken||null;break}}}while(N.currentType!==13&&N.currentType!==1);const Z=N.currentType===1?N.lastOffset:R.currentOffset(),K=N.currentType===1?N.lastEndLoc:R.currentPosition();return s(W,Z,K),W}function P(R,N,j,U){const W=R.context();let Q=U.items.length===0;const Z=i(1,N,j);Z.cases=[],Z.cases.push(U);do{const K=A(R);Q||(Q=K.items.length===0),Z.cases.push(K)}while(W.currentType!==13);return Q&&r(R,Ci.MUST_HAVE_MESSAGES_IN_PLURAL,j,0),s(Z,R.currentOffset(),R.currentPosition()),Z}function D(R){const N=R.context(),{offset:j,startLoc:U}=N,W=A(R);return N.currentType===13?W:P(R,j,U,W)}function B(R){const N=TQ(R,ha({},e)),j=N.context(),U=i(0,j.offset,j.startLoc);return t&&U.loc&&(U.loc.source=R),U.body=D(N),e.onCacheKey&&(U.cacheKey=e.onCacheKey(R)),j.currentType!==13&&r(N,Ci.UNEXPECTED_LEXICAL_ANALYSIS,j.lastStartLoc,0,R[j.offset]||""),s(U,N.currentOffset(),N.currentPosition()),U}return{parse:B}}function eu(e){if(e.type===13)return"EOF";const t=(e.value||"").replace(/\r?\n/gu,"\\n");return t.length>10?t.slice(0,9)+"…":t}function AQ(e,t={}){const n={ast:e,helpers:new Set};return{context:()=>n,helper:s=>(n.helpers.add(s),s)}}function MD(e,t){for(let n=0;n<e.length;n++)e2(e[n],t)}function e2(e,t){switch(e.type){case 1:MD(e.cases,t),t.helper("plural");break;case 2:MD(e.items,t);break;case 6:{e2(e.key,t),t.helper("linked"),t.helper("type");break}case 5:t.helper("interpolate"),t.helper("list");break;case 4:t.helper("interpolate"),t.helper("named");break}}function PQ(e,t={}){const n=AQ(e);n.helper("normalize"),e.body&&e2(e.body,n);const r=n.context();e.helpers=Array.from(r.helpers)}function MQ(e){const t=e.body;
57return t.type===2?ID(t):t.cases.forEach(n=>ID(n)),e}function ID(e){if(e.items.length===1){const t=e.items[0];(t.type===3||t.type===9)&&(e.static=t.value,delete t.value)}else{const t=[];for(let n=0;n<e.items.length;n++){const r=e.items[n];if(!(r.type===3||r.type===9)||r.value==null)break;t.push(r.value)}if(t.length===e.items.length){e.static=Jk(t);for(let n=0;n<e.items.length;n++){const r=e.items[n];(r.type===3||r.type===9)&&delete r.value}}}}function Sm(e){switch(e.t=e.type,e.type){case 0:{const t=e;Sm(t.body),t.b=t.body,delete t.body;break}case 1:{const t=e,n=t.cases;for(let r=0;r<n.length;r++)Sm(n[r]);t.c=n,delete t.cases;break}case 2:{const t=e,n=t.items;for(let r=0;r<n.length;r++)Sm(n[r]);t.i=n,delete t.items,t.static&&(t.s=t.static,delete t.static);break}case 3:case 9:case 8:case 7:{const t=e;t.value&&(t.v=t.value,delete t.value);break}case 6:{const t=e;Sm(t.key),t.k=t.key,delete t.key,t.modifier&&(Sm(t.modifier),t.m=t.modifier,delete t.modifier);break}case 5:{const t=e;t.i=t.index,delete t.index;break}case 4:{const t=e;t.k=t.key,delete t.key;break}}delete e.type}function IQ(e,t){const{sourceMap:n,filename:r,breakLineCode:i,needIndent:s}
57=t,c=t.location!==!1,a={filename:r,code:"",column:1,line:1,offset:0,map:void 0,breakLineCode:i,needIndent:s,indentLevel:0};c&&e.loc&&(a.source=e.loc.source);const m=()=>a;function g(B,R){a.code+=B}function x(B,R=!0){const N=R?i:"";g(s?N+"  ".repeat(B):N)}function T(B=!0){const R=++a.indentLevel;B&&x(R)}function C(B=!0){const R=--a.indentLevel;B&&x(R)}function A(){x(a.indentLevel)}return{context:m,push:g,indent:T,deindent:C,newline:A,helper:B=>`_${B}`,needIndent:()=>a.needIndent}}function OQ(e,t){const{helper:n}=e;e.push(`${n("linked")}(`),ag(e,t.key),t.modifier?(e.push(", "),ag(e,t.modifier),e.push(", _type")):e.push(", undefined, _type"),e.push(")")}function DQ(e,t){const{helper:n,needIndent:r}=e;e.push(`${n("normalize")}([`),e.indent(r());const i=t.items.length;for(let s=0;s<i&&(ag(e,t.items[s]),s!==i-1);s++)e.push(", ");e.deindent(r()),e.push("])")}function LQ(e,t){const{helper:n,needIndent:r}=e;if(t.cases.length>1){e.push(`${n("plural")}([`),e.indent(r());const i=t.cases.length;for(let s=0;s<i&&(ag(e,t.cases[s]),s!==i-1);s++)e.push(", ");e.deindent(r()),e.push("])")}}function RQ(e,t){t.body?ag(e,t.body):e.push("null")}function ag(e,t){const{helper:n}=e;switch(t.type){case 0:RQ(e,t);break;case 1:LQ(e,t);break;case 2:DQ(e,t);break;case 6:OQ(e,t);break;case 8:e.push(JSON.stringify(t.value),t);break;case 7:e.push(JSON.stringify(t.value),t);break;case 5:e.push(`${n("interpolate")}(${n("list")}(${t.index}))`,t);break;case 4:e.push(`${n("interpolate")}(${n("named")}(${JSON.stringify(t.key)}))`,t);break;case 9:e.push(JSON.stringify(t.value),t);break;case 3:e.push(JSON.stringify(t.value),t);break}}const FQ=(e,t={})=>{const n=On(t.mode)?t.mode:"normal",r=On(t.filename)?t.filename:"message.intl",i=!!t.sourceMap,s=t.breakLineCode!=null?t.breakLineCode:n==="arrow"?";":`
58`,c=t.needIndent?t.needIndent:n!=="arrow",a=e.helpers||[],m=IQ(e,{mode:n,filename:r,sourceMap:i,breakLineCode:s,needIndent:c});m.push(n==="normal"?"function __msg__ (ctx) {":"(ctx) => {"),m.indent(c),a.length>0&&(m.push(`const { ${Jk(a.map(T=>`${T}: _${T}`),", ")} } = ctx`),m.newline()),m.push("return "),ag(m,e),m.deindent(c),m.push("}"),delete e.helpers;const{code:g,map:x}=m.context();return{ast:e,code:g,map:x?x.toJSON():void 0}};function BQ(e,t={}){const n=ha({},t),r=!!n.jit,i=!!n.minify,s=n.optimize==null?!0:n.optimize,a=kQ(n).parse(e);return r?(s&&MQ(a),i&&Sm(a),{ast:a,code:""}):(PQ(a,n),FQ(a,n))}/*!
59  * core-base v11.0.1
60  * (c) 2024 kazuya kawaguchi
61  * Released under the MIT License.
62  */function zQ(){typeof __INTLIFY_PROD_DEVTOOLS__!="boolean"&&(Xf().__INTLIFY_PROD_DEVTOOLS__=!1),typeof __INTLIFY_DROP_MESSAGE_COMPILER__!="boolean"&&(Xf().__INTLIFY_DROP_MESSAGE_COMPILER__=!1)}function $T(e){return n=>NQ(n,e)}function NQ(e,t){const n=jQ(t);if(n==null)throw G_(0);if(t2(n)===1){const s=VQ(n);return e.plural(s.reduce((c,a)=>[...c,OD(e,a)],[]))}else return OD(e,n)}const $Q=["b","body"];function jQ(e){return Bd(e,$Q)}const UQ=["c","cases"];function VQ(e){return Bd(e,UQ,[])}function OD(e,t){const n=qQ(t);if(n!=null)return e.type==="text"?n:e.normalize([n]);{const r=HQ(t).reduce((i,s)=>[...i,jS(e,s)],[]);return e.normalize(r)}}const GQ=["s","static"];function qQ(e){return Bd(e,GQ)}const WQ=["i","items"];function HQ(e){return Bd(e,WQ,[])}function jS(e,t){const n=t2(t);switch(n){case 3:return ob(t,n);case 9:return ob(t,n);case 4:{const r=t;if(Cc(r,"k")&&r.k)return e.interpolate(e.named(r.k));if(Cc(r,"key")&&r.key)return e.interpolate(e.named(r.key));throw G_(n)}case 5:{const r=t;if(Cc(r,"i")&&Qo(r.i))return e.interpolate(e.list(r.i));if(Cc(r,"index")&&Qo(r.index))return e.interpolate(e.list(r.index));throw G_(n)}case 6:{const r=t,i=KQ(r),s=JQ(r);return e.linked(jS(e,s),i?jS(e,i):void 0,e.type)}case 7:return ob(t,n);case 8:return ob(t,n);default:throw new Error(`unhandled node on format message part: ${n}`)}}const YQ=["t","type"];function t2(e){return Bd(e,YQ)}const ZQ=["v","value"];function ob(e,t){const n=Bd(e,ZQ);if(n)return n;throw G_(t)}const XQ=["m","modifier"];function KQ(e){return Bd(e,XQ)}const QQ=["k","key"];function JQ(e){const t=Bd(e,QQ);if(t)return t;throw G_(6)}
62function Bd(e,t,n){for(let r=0;r<t.length;r++){const i=t[r];if(Cc(e,i)&&e[i]!=null)return e[i]}return n}function G_(e){return new Error(`unhandled node type: ${e}`)}const eJ=e=>e;let ab=Ri();function sg(e){return gi(e)&&t2(e)===0&&(Cc(e,"b")||Cc(e,"body"))}function tJ(e,t={}){let n=!1;const r=t.onError||gQ;return t.onError=i=>{n=!0,r(i)},{...BQ(e,t),detectError:n}}function nJ(e,t){if(!__INTLIFY_DROP_MESSAGE_COMPILER__&&On(e)){li(t.warnHtmlMessage)&&t.warnHtmlMessage;const r=(t.onCacheKey||eJ)(e),i=ab[r];if(i)return i;const{ast:s,detectError:c}=tJ(e,{...t,location:!1,jit:!0}),a=$T(s);return c?a:ab[r]=a}else{const n=e.cacheKey;if(n){const r=ab[n];return r||(ab[n]=$T(e))}else return $T(e)}}let q_=null;function rJ(e){q_=e}function iJ(e,t,n){q_&&q_.emit("i18n:init",{timestamp:Date.now(),i18n:e,version:t,meta:n})}const oJ=aJ("function:translate");function aJ(e){return t=>q_&&q_.emit(e,t)}const Ku={INVALID_ARGUMENT:mQ,INVALID_DATE_ARGUMENT:18,INVALID_ISO_DATE_ARGUMENT:19,NOT_SUPPORT_NON_STRING_MESSAGE:20,NOT_SUPPORT_LOCALE_PROMISE_VALUE:21,NOT_SUPPORT_LOCALE_ASYNC_FUNCTION:22,NOT_SUPPORT_LOCALE_TYPE:23},sJ=24;function Qu(e){return v1(e,null,void 0)}function n2(e,t){return t.locale!=null?DD(t.locale):DD(e.locale)}let jT;function DD(e){if(On(e))return e;if(io(e)){if(e.resolvedOnce&&jT!=null)return jT;if(e.constructor.name==="Function"){const t=e();if(hQ(t))throw Qu(Ku.NOT_SUPPORT_LOCALE_PROMISE_VALUE);return jT=t}else throw Qu(Ku.NOT_SUPPORT_LOCALE_ASYNC_FUNCTION)}else throw Qu(Ku.NOT_SUPPORT_LOCALE_TYPE)}function lJ(e,t,n){return[...new Set([n,...Jo(t)?t:gi(t)?Object.keys(t):On(t)?[t]:[n]])]}function Yz(e,t,n){const r=On(n)?n:W_,i=e;i.__localeChainCache||(i.__localeChainCache=new Map);let s=i.__localeChainCache.get(r);if(!s){s=[];let c=[n];for(;Jo(c);)c=LD(s,c,t);const a=Jo(t)||!Or(t)?t:t.default?t.default:null;c=On(a)?[a]:a,Jo(c)&&LD(s,c,!1),i.__localeChainCache.set(r,s)}return s}function LD(e,t,n){let r=!0;for(let i=0;i<t.length&&li(r);i++){const s=t[i];On(s)&&(r=cJ(e,t[i],n))}return r}function cJ(e,t,n){let r;const i=t.split("-");do{const s=i.join("-");r=uJ(e,s,n),i.splice(-1,1)}while(i.length&&r===!0);return r}function uJ(e,t,n){let r=!1;if(!e.includes(t)&&(r=!0,t)){r=t[t.length-1]!=="!";const i=t.replace(/!/g,"");e.push(i),(Jo(n)||Or(n))&&n[i]&&(r=n[i])}return r}const zd=[];zd[0]={w:[0],i:[3,0],["["]:[4],o:[7]};zd[1]={w:[1],["."]:[2],["["]:[4],o:[7]};zd[2]={w:[2],i:[3,0],[0]:[3,0]};zd[3]={i:[3,0],[0]:[3,0],w:[1,1],["."]:[2,1],["["]:[4,1],o:[7,1]};zd[4]={["'"]:[5,0],['"']:[6,0],["["]:[4,2],["]"]:[1,3],o:8,l:[4,0]};zd[5]={["'"]:[4,0],o:8,l:[5,0]};zd[6]={['"']:[4,0],o:8,l:[6,0]};const hJ=/^\s?(?:true|false|-?[\d.]+|'[^']*'|"[^"]*")\s?$/;function dJ(e){return hJ.test(e)}function fJ(e){const t=e.charCodeAt(0),n=e.charCodeAt(e.length-1);return t===n&&(t===34||t===39)?e.slice(1,-1):e}function pJ(e){if(e==null)return"o";switch(e.charCodeAt(0)){case 91:case 93:case 46:case 34:case 39:return e;case 95:case 36:case 45:return"i";case 9:case 10:case 13:case 160:case 65279:case 8232:case 8233:return"w"}return"i"}function mJ(e){const t=e.trim();return e.charAt(0)==="0"&&isNaN(parseInt(e))?!1:dJ(t)?fJ(t):"*"+t}function gJ(e){const t=[];let n=-1,r=0,i=0,s,c,a,m,g,x,T;const C=[];C[0]=()=>{c===void 0?c=a:c+=a},C[1]=()=>{c!==void 0&&(t.push(c),c=void 0)},C[2]=()=>{C[0](),i++},C[3]=()=>{if(i>0)i--,r=4,C[0]();else{if(i=0,c===void 0||(c=mJ(c),c===!1))return!1;C[1]()}};function A(){const P=e[n+1];if(r===5&&P==="'"||r===6&&P==='"')return n++,a="\\"+P,C[0](),!0}for(;r!==null;)if(n++,s=e[n],!(s==="\\"&&A())){if(m=pJ(s),T=zd[r],g=T[m]||T.l||8,g===8||(r=g[0],g[1]!==void 0&&(x=C[g[1]],x&&(a=s,x()===!1))))return;if(r===7)return t}}const RD=new Map;function yJ(e,t){return gi(e)?e[t]:null}function _J(e,t){if(!gi(e))return null;let n=RD.get(t);if(n||(n=gJ(t),n&&RD.set(t,n)),!n)return null;const r=n.length;let i=e,s=0;for(;s<r;){const c=i[n[s]];if(c===void 0||io(i))return null;i=c,s++}return i}const vJ="11.0.1",b1=-1,W_="en-US",FD="",BD=e=>`${e.charAt(0).toLocaleUpperCase()}${e.substr(1)}`;function bJ(){return{upper:(e,t)=>t==="text"&&On(e)?e.toUpperCase():t==="vnode"&&gi(e)&&"__v_isVNode"in e?e.children.toUpperCase():e,lower:(e,t)=>t==="text"&&On(e)?e.toLowerCase():t==="vnode"&&gi(e)&&"__v_isVNode"in e?e.children.toLowerCase():e,capitalize:(e,t)=>
62t==="text"&&On(e)?BD(e):t==="vnode"&&gi(e)&&"__v_isVNode"in e?BD(e.children):e}}let Zz;function xJ(e){Zz=e}let Xz;function wJ(e){Xz=e}let Kz;function TJ(e){Kz=e}let Qz=null;const EJ=e=>{Qz=e},SJ=()=>Qz;let Jz=null;const zD=e=>{Jz=e},CJ=()=>Jz;let ND=0;function kJ(e={}){const t=io(e.onWarn)?e.onWarn:fQ,n=On(e.version)?e.version:vJ,r=On(e.locale)||io(e.locale)?e.locale:W_,i=io(r)?W_:r,s=Jo(e.fallbackLocale)||Or(e.fallbackLocale)||On(e.fallbackLocale)||e.fallbackLocale===!1?e.fallbackLocale:i,c=Or(e.messages)?e.messages:UT(i),a=Or(e.datetimeFormats)?e.datetimeFormats:UT(i),m=Or(e.numberFormats)?e.numberFormats:UT(i),g=ha(Ri(),e.modifiers,bJ()),x=e.pluralRules||Ri(),T=io(e.missing)?e.missing:null,C=li(e.missingWarn)||og(e.missingWarn)?e.missingWarn:!0,A=li(e.fallbackWarn)||og(e.fallbackWarn)?e.fallbackWarn:!0,P=!!e.fallbackFormat,D=!!e.unresolving,B=io(e.postTranslation)?e.postTranslation:null,R=Or(e.processor)?e.processor:null,N=li(e.warnHtmlMessage)?e.warnHtmlMessage:!0,j=!!e.escapeParameter,U=io(e.messageCompiler)?e.messageCompiler:Zz,W=io(e.messageResolver)?e.messageResolver:Xz||yJ,Q=io(e.localeFallbacker)?e.localeFallbacker:Kz||lJ,Z=gi(e.fallbackContext)?e.fallbackContext:void 0,K=e,Y=gi(K.__datetimeFormatters)?K.__datetimeFormatters:new Map,me=gi(K.__numberFormatters)?K.__numberFormatters:new Map,ge=gi(K.__meta)?K.__meta:{};ND++;const ce={version:n,cid:ND,locale:r,fallbackLocale:s,messages:c,modifiers:g,pluralRules:x,missing:T,missingWarn:C,fallbackWarn:A,fallbackFormat:P,unresolving:D,postTranslation:B,processor:R,warnHtmlMessage:N,escapeParameter:j,messageCompiler:U,messageResolver:W,localeFallbacker:Q,fallbackContext:Z,onWarn:t,__meta:ge};return ce.datetimeFormats=a,ce.numberFormats=m,ce.__datetimeFormatters=Y,ce.__numberFormatters=me,__INTLIFY_PROD_DEVTOOLS__&&iJ(ce,n,ge),ce}const UT=e=>({[e]:Ri()});function r2(e,t,n,r,i){const{missing:s,onWarn:c}=e;if(s!==null){const a=s(e,n,t,i);return On(a)?a:t}else return t}function Gy(e,t,n){const r=e;r.__localeChainCache=new Map,e.localeFallbacker(e,n,t)}function AJ(e,t){return e===t?!1:e.split("-")[0]===t.split("-")[0]}function PJ(e,t){const n=t.indexOf(e);if(n===-1)return!1;for(let r=n+1;r<t.length;r++)if(AJ(e,t[r]))return!0;return!1}function $D(e,...t){const{datetimeFormats:n,unresolving:r,fallbackLocale:i,onWarn:s,localeFallbacker:c}=e,{__datetimeFormatters:a}=e,[m,g,x,T]=US(...t),C=li(x.missingWarn)?x.missingWarn:e.missingWarn;li(x.fallbackWarn)?x.fallbackWarn:e.fallbackWarn;const A=!!x.part,P=n2(e,x),D=c(e,i,P);if(!On(m)||m==="")return new Intl.DateTimeFormat(P,T).format(g);let B={},R,N=null;const j="datetime format";for(let Q=0;Q<D.length&&(R=D[Q],B=n[R]||{},N=B[m],!Or(N));Q++)r2(e,m,R,C,j);if(!Or(N)||!On(R))return r?b1:m;let U=`${R}__${m}`;_1(T)||(U=`${U}__${JSON.stringify(T)}`);let W=a.get(U);return W||(W=new Intl.DateTimeFormat(R,ha({},N,T)),a.set(U,W)),A?W.formatToParts(g):W.format(g)}const eN=["localeMatcher","weekday","era","year","month","day","hour","minute","second","timeZoneName","formatMatcher","hour12","timeZone","dateStyle","timeStyle","calendar","dayPeriod","numberingSystem","hourCycle","fractionalSecondDigits"];function US(...e){const[t,n,r,i]=e,s=Ri();let c=Ri(),a;if(On(t)){const m=t.match(/(\d{4}-\d{2}-\d{2})(T|\s)?(.*)/);if(!m)throw Qu(Ku.INVALID_ISO_DATE_ARGUMENT);const g=m[3]?m[3].trim().startsWith("T")?`${m[1].trim()}${m[3].trim()}`:`${m[1].trim()}T${m[3].trim()}`:m[1].trim();a=new Date(g);try{a.toISOString()}catch{throw Qu(Ku.INVALID_ISO_DATE_ARGUMENT)}}else if(lQ(t)){if(isNaN(t.getTime()))throw Qu(Ku.INVALID_DATE_ARGUMENT);a=t}else if(Qo(t))a=t;else throw Qu(Ku.INVALID_ARGUMENT);return On(n)?s.key=n:Or(n)&&Object.keys(n).forEach(m=>{eN.includes(m)?c[m]=n[m]:s[m]=n[m]}),On(r)?s.locale=r:Or(r)&&(c=r),Or(i)&&(c=i),[s.key||"",a,s,c]}function jD(e,t,n){const r=e;for(const i in n){const s=`${t}__${i}`;r.__datetimeFormatters.has(s)&&r.__datetimeFormatters.delete(s)}}function UD(e,...t){const{numberFormats:n,unresolving:r,fallbackLocale:i,onWarn:s,localeFallbacker:c}=e,{__numberFormatters:a}=e,[m,g,x,T]=VS(...t),C=li(x.missingWarn)?x.missingWarn:e.missingWarn;li(x.fallbackWarn)?x.fallbackWarn:e.fallbackWarn;const A=!!x.part,P=n2(e,x),D=c(e,i,P);
62if(!On(m)||m==="")return new Intl.NumberFormat(P,T).format(g);let B={},R,N=null;const j="number format";for(let Q=0;Q<D.length&&(R=D[Q],B=n[R]||{},N=B[m],!Or(N));Q++)r2(e,m,R,C,j);if(!Or(N)||!On(R))return r?b1:m;let U=`${R}__${m}`;_1(T)||(U=`${U}__${JSON.stringify(T)}`);let W=a.get(U);return W||(W=new Intl.NumberFormat(R,ha({},N,T)),a.set(U,W)),A?W.formatToParts(g):W.format(g)}const tN=["localeMatcher","style","currency","currencyDisplay","currencySign","useGrouping","minimumIntegerDigits","minimumFractionDigits","maximumFractionDigits","minimumSignificantDigits","maximumSignificantDigits","compactDisplay","notation","signDisplay","unit","unitDisplay","roundingMode","roundingPriority","roundingIncrement","trailingZeroDisplay"];function VS(...e){const[t,n,r,i]=e,s=Ri();let c=Ri();if(!Qo(t))throw Qu(Ku.INVALID_ARGUMENT);const a=t;return On(n)?s.key=n:Or(n)&&Object.keys(n).forEach(m=>{tN.includes(m)?c[m]=n[m]:s[m]=n[m]}),On(r)?s.locale=r:Or(r)&&(c=r),Or(i)&&(c=i),[s.key||"",a,s,c]}function VD(e,t,n){const r=e;for(const i in n){const s=`${t}__${i}`;r.__numberFormatters.has(s)&&r.__numberFormatters.delete(s)}}const MJ=e=>e,IJ=e=>"",OJ="text",DJ=e=>e.length===0?"":Jk(e),LJ=dQ;function GD(e,t){return e=Math.abs(e),t===2?e?e>1?1:0:1:e?Math.min(e,2):0}function RJ(e){const t=Qo(e.pluralIndex)?e.pluralIndex:-1;return e.named&&(Qo(e.named.count)||Qo(e.named.n))?Qo(e.named.count)?e.named.count:Qo(e.named.n)?e.named.n:t:t}function FJ(e,t){t.count||(t.count=e),t.n||(t.n=e)}function BJ(e={}){const t=e.locale,n=RJ(e),r=gi(e.pluralRules)&&On(t)&&io(e.pluralRules[t])?e.pluralRules[t]:GD,i=gi(e.pluralRules)&&On(t)&&io(e.pluralRules[t])?GD:void 0,s=R=>R[r(n,R.length,i)],c=e.list||[],a=R=>c[R],m=e.named||Ri();Qo(e.pluralIndex)&&FJ(n,m);const g=R=>m[R];function x(R,N){const j=io(e.messages)?e.messages(R,!!N):gi(e.messages)?e.messages[R]:!1;return j||(e.parent?e.parent.message(R):IJ)}const T=R=>e.modifiers?e.modifiers[R]:MJ,C=Or(e.processor)&&io(e.processor.normalize)?e.processor.normalize:DJ,A=Or(e.processor)&&io(e.processor.interpolate)?e.processor.interpolate:LJ,P=Or(e.processor)&&On(e.processor.type)?e.processor.type:OJ,B={list:a,named:g,plural:s,linked:(R,...N)=>{const[j,U]=N;let W="text",Q="";N.length===1?gi(j)?(Q=j.modifier||Q,W=j.type||W):On(j)&&(Q=j||Q):N.length===2&&(On(j)&&(Q=j||Q),On(U)&&(W=U||W));const Z=x(R,!0)(B),K=W==="vnode"&&Jo(Z)&&Q?Z[0]:Z;return Q?T(Q)(K,W):K},message:x,type:P,interpolate:A,normalize:C,values:ha(Ri(),c,m)};return B}const qD=()=>"",$l=e=>io(e);function WD(e,...t){const{fallbackFormat:n,postTranslation:r,unresolving:i,messageCompiler:s,fallbackLocale:c,messages:a}=e,[m,g]=GS(...t),x=li(g.missingWarn)?g.missingWarn:e.missingWarn,T=li(g.fallbackWarn)?g.fallbackWarn:e.fallbackWarn,C=li(g.escapeParameter)?g.escapeParameter:e.escapeParameter,A=!!g.resolvedMessage,P=On(g.default)||li(g.default)?li(g.default)?s?m:()=>m:g.default:n?s?m:()=>m:null,D=n||P!=null&&(On(P)||io(P)),B=n2(e,g);C&&zJ(g);let[R,N,j]=A?[m,B,a[B]||Ri()]:nN(e,m,B,c,T,x),U=R,W=m;if(!A&&!(On(U)||sg(U)||$l(U))&&D&&(U=P,W=U),!A&&(!(On(U)||sg(U)||$l(U))||!On(N)))return i?b1:m;let Q=!1;const Z=()=>{Q=!0},K=$l(U)?U:rN(e,m,N,U,W,Z);if(Q)return U;const Y=jJ(e,N,j,g),me=BJ(Y),ge=NJ(e,K,me),ce=r?r(ge,m):ge;if(__INTLIFY_PROD_DEVTOOLS__){const fe={timestamp:Date.now(),key:On(m)?m:$l(U)?U.key:"",locale:N||($l(U)?U.locale:""),format:On(U)?U:$l(U)?U.source:"",message:ce};fe.meta=ha({},e.__meta,SJ()||{}),oJ(fe)}return ce}function zJ(e){Jo(e.list)?e.list=e.list.map(t=>On(t)?AD(t):t):gi(e.named)&&Object.keys(e.named).forEach(t=>{On(e.named[t])&&(e.named[t]=AD(e.named[t]))})}function nN(e,t,n,r,i,s){const{messages:c,onWarn:a,messageResolver:m,localeFallbacker:g}=e,x=g(e,r,n);let T=Ri(),C,A=null;const P="translate";for(let D=0;D<x.length&&(C=x[D],T=c[C]||Ri(),(A=m(T,t))===null&&(A=T[t]),!(On(A)||sg(A)||$l(A)));D++)if(!PJ(C,x)){const B=r2(e,t,C,s,P);B!==t&&(A=B)}return[A,C,T]}function rN(e,t,n,r,i,s){const{messageCompiler:c,warnHtmlMessage:a}=e;if($l(r)){const g=r;return g.locale=g.locale||n,g.key=g.key||t,g}if(c==null){const g=()=>r;return g.locale=n,g.key=t,g}const m=c(r,$J(e,n,i,r,a,s));return m.locale=n,m.key=t,m.source=r,m}function NJ(e,t,n){return t(n)}function GS(...e){const[t,n,r]=e,i=Ri();
vendor: 4,938 bytes, lines 62-66
62if(!On(t)&&!Qo(t)&&!$l(t)&&!sg(t))throw Qu(Ku.INVALID_ARGUMENT);const s=Qo(t)?String(t):($l(t),t);return Qo(n)?i.plural=n:On(n)?i.default=n:Or(n)&&!_1(n)?i.named=n:Jo(n)&&(i.list=n),Qo(r)?i.plural=r:On(r)?i.default=r:Or(r)&&ha(i,r),[s,i]}function $J(e,t,n,r,i,s){return{locale:t,key:n,warnHtmlMessage:i,onError:c=>{throw s&&s(c),c},onCacheKey:c=>aQ(t,n,c)}}function jJ(e,t,n,r){const{modifiers:i,pluralRules:s,messageResolver:c,fallbackLocale:a,fallbackWarn:m,missingWarn:g,fallbackContext:x}=e,C={locale:t,modifiers:i,pluralRules:s,messages:(A,P)=>{let D=c(n,A);if(D==null&&(x||P)){const[,,B]=nN(x||e,A,t,a,m,g);D=c(B,A)}if(On(D)||sg(D)){let B=!1;const N=rN(e,A,t,D,A,()=>{B=!0});return B?qD:N}else return $l(D)?D:qD}};return e.processor&&(C.processor=e.processor),r.list&&(C.list=r.list),r.named&&(C.named=r.named),Qo(r.plural)&&(C.pluralIndex=r.plural),C}zQ();/*!
63  * vue-i18n v11.0.1
64  * (c) 2024 kazuya kawaguchi
65  * Released under the MIT License.
66  */const UJ="11.0.1";function VJ(){typeof __VUE_I18N_FULL_INSTALL__!="boolean"&&(Xf().__VUE_I18N_FULL_INSTALL__=!0),typeof __VUE_I18N_LEGACY_API__!="boolean"&&(Xf().__VUE_I18N_LEGACY_API__=!0),typeof __INTLIFY_DROP_MESSAGE_COMPILER__!="boolean"&&(Xf().__INTLIFY_DROP_MESSAGE_COMPILER__=!1),typeof __INTLIFY_PROD_DEVTOOLS__!="boolean"&&(Xf().__INTLIFY_PROD_DEVTOOLS__=!1)}const Vs={UNEXPECTED_RETURN_TYPE:sJ,INVALID_ARGUMENT:25,MUST_BE_CALL_SETUP_TOP:26,NOT_INSTALLED:27,REQUIRED_VALUE:28,INVALID_VALUE:29,CANNOT_SETUP_VUE_DEVTOOLS_PLUGIN:30,NOT_INSTALLED_WITH_PROVIDE:31,UNEXPECTED_ERROR:32,NOT_COMPATIBLE_LEGACY_VUE_I18N:33,NOT_AVAILABLE_COMPOSITION_IN_LEGACY:34};function gl(e,...t){return v1(e,null,void 0)}const qS=Fd("__translateVNode"),WS=Fd("__datetimeParts"),HS=Fd("__numberParts"),iN=Fd("__setPluralRules"),oN=Fd("__injectWithOption"),YS=Fd("__dispose");function H_(e){if(!gi(e))return e;for(const t in e)if(Cc(e,t))if(!t.includes("."))gi(e[t])&&H_(e[t]);else{const n=t.split("."),r=n.length-1;let i=e,s=!1;for(let c=0;c<r;c++){if(n[c]in i||(i[n[c]]=Ri()),!gi(i[n[c]])){s=!0;break}i=i[n[c]]}s||(i[n[r]]=e[t],delete e[t]),gi(i[n[r]])&&H_(i[n[r]])}return e}function i2(e,t){const{messages:n,__i18n:r,messageResolver:i,flatJson:s}=t,c=Or(n)?n:Jo(r)?Ri():{[e]:Ri()};if(Jo(r)&&r.forEach(a=>{if("locale"in a&&"resource"in a){const{locale:m,resource:g}=a;m?(c[m]=c[m]||Ri(),Mb(g,c[m])):Mb(g,c)}else On(a)&&Mb(JSON.parse(a),c)}),i==null&&s)for(const a in c)Cc(c,a)&&H_(c[a]);return c}function aN(e){return e.type}function sN(e,t,n){let r=gi(t.messages)?t.messages:Ri();"__i18nGlobal"in n&&(r=i2(e.locale.value,{messages:r,__i18n:n.__i18nGlobal}));const i=Object.keys(r);i.length&&i.forEach(s=>{e.mergeLocaleMessage(s,r[s])});{if(gi(t.datetimeFormats)){const s=Object.keys(t.datetimeFormats);s.length&&s.forEach(c=>{e.mergeDateTimeFormat(c,t.datetimeFormats[c])})}if(gi(t.numberFormats)){const s=Object.keys(t.numberFormats);s.length&&s.forEach(c=>{e.mergeNumberFormat(c,t.numberFormats[c])})}}}function HD(e){return sn(Td,null,e,0)}const YD="__INTLIFY_META__",ZD=()=>[],GJ=()=>!1;let XD=0;function KD(e){return(t,n,r,i)=>e(n,r,ko()||void 0,i)}const qJ=()=>{const e=ko();let t=null;return e&&(t=aN(e)[YD])?{[YD]:t}:null};function o2(e={}){const{__root:t,__injectWithOption:n}=e,r=t===void 0,i=e.flatJson,s=hx?jt:ua;let c=li(e.inheritLocale)?e.inheritLocale:!0;const a=s(t&&c?t.locale.value:On(e.locale)?e.locale:W_),m=s(t&&c?t.fallbackLocale.value:On(e.fallbackLocale)||Jo(e.fallbackLocale)||Or(e.fallbackLocale)||e.fallbackLocale===!1?e.fallbackLocale:a.value),g=s(i2(a.value,e)),x=s(Or(e.datetimeFormats)?e.datetimeFormats:{[a.value]:{}}),T=s(Or(e.numberFormats)?e.numberFormats:{[a.value]:{}});let C=t?t.missingWarn:li(e.missingWarn)||og(e.missingWarn)?e.missingWarn:!0,A=t?t.fallbackWarn:li(e.fallbackWarn)||og(e.fallbackWarn)?e.fallbackWarn:!0,P=t?t.fallbackRoot:li(e.fallbackRoot)?e.fallbackRoot:!0,D=!!e.fallbackFormat,B=io(e.missing)?e.missing:null,R=io(e.missing)?KD(e.missing):null,N=io(e.postTranslation)?e.postTranslation:null,j=t?t.warnHtmlMessage:li(e.warnHtmlMessage)?e.warnHtmlMessage:!0,U=!!e.escapeParameter;const W=t?t.modifiers:Or(e.modifiers)?e.modifiers:{};let Q=e.pluralRules||t&&t.pluralRules,Z;Z=(()=>{r&&zD(null);const nt={version:UJ,locale:a.value,fallbackLocale:m.value,messages:g.value,modifiers:W,pluralRules:Q,missing:R===null?void 0:R,missingWarn:C,fallbackWarn:A,fallbackFormat:D,unresolving:!0,postTranslation:N===null?void 0:N,warnHtmlMessage:j,escapeParameter:U,messageResolver:e.messageResolver,messageCompiler:e.messageCompiler,__meta:{framework:"vue"}};nt.datetimeFormats=x.value,nt.numberFormats=T.value,nt.__datetimeFormatters=Or(Z)?Z.__datetimeFormatters:void 0,nt.__numberFormatters=Or(Z)?Z.__numberFormatters:void 0;const It=kJ(nt);return r&&zD(It),It})(),Gy(Z,a.value,m.value);function Y(){return[a.value,m.value,g.value,x.value,T.value]}const me=yt({get:()=>a.value,set:nt=>{a.value=nt,Z.locale=a.value}}),ge=yt({get:()=>m.value,set:nt=>
66{m.value=nt,Z.fallbackLocale=m.value,Gy(Z,a.value,nt)}}),ce=yt(()=>g.value),fe=yt(()=>x.value),ie=yt(()=>T.value);function xe(){return io(N)?N:null}function Te(nt){N=nt,Z.postTranslation=nt}function oe(){return B}function ne(nt){nt!==null&&(R=KD(nt)),B=nt,Z.missing=R}const le=(nt,It,$t,$e,pt,gn)=>{Y();let Pn;try{__INTLIFY_PROD_DEVTOOLS__&&EJ(qJ()),r||(Z.fallbackContext=t?CJ():void 0),Pn=nt(Z)}finally{__INTLIFY_PROD_DEVTOOLS__,r||(Z.fallbackContext=void 0)}if($t!=="translate exists"&&Qo(Pn)&&Pn===b1||$t==="translate exists"&&!Pn){const[gr,Ji]=It();return t&&P?$e(t):pt(gr)}else{if(gn(Pn))return Pn;throw gl(Vs.UNEXPECTED_RETURN_TYPE)}};function se(...nt){return le(It=>Reflect.apply(WD,null,[It,...nt]),()=>GS(...nt),"translate",It=>Reflect.apply(It.t,It,[...nt]),It=>It,It=>On(It))}function Ne(...nt){const[It,$t,$e]=nt;if($e&&!gi($e))throw gl(Vs.INVALID_ARGUMENT);return se(It,$t,ha({resolvedMessage:!0},$e||{}))}function Se(...nt){return le(It=>Reflect.apply($D,null,[It,...nt]),()=>US(...nt),"datetime format",It=>Reflect.apply(It.d,It,[...nt]),()=>FD,It=>On(It))}function xt(...nt){return le(It=>Reflect.apply(UD,null,[It,...nt]),()=>VS(...nt),"number format",It=>Reflect.apply(It.n,It,[...nt]),()=>FD,It=>On(It))}function kt(nt){return nt.map(It=>On(It)||Qo(It)||li(It)?HD(String(It)):It)}const Ue={normalize:kt,interpolate:nt=>nt,type:"vnode"};function je(...nt){return le(It=>{let $t;const $e=It;try{$e.processor=Ue,$t=Reflect.apply(WD,null,[$e,...nt])}finally{$e.processor=null}return $t},()=>GS(...nt),"translate",It=>It[qS](...nt),It=>[HD(It)],It=>Jo(It))}function st(...nt){return le(It=>Reflect.apply(UD,null,[It,...nt]),()=>VS(...nt),"number format",It=>It[HS](...nt),ZD,It=>On(It)||Jo(It))}function tt(...nt){return le(It=>Reflect.apply($D,null,[It,...nt]),()=>US(...nt),"datetime format",It=>It[WS](...nt),ZD,It=>On(It)||Jo(It))}function Me(nt){Q=nt,Z.pluralRules=Q}function lt(nt,It){return le(()=>{if(!nt)return!1;const $t=On(It)?It:a.value,$e=Je($t),pt=Z.messageResolver($e,nt);return sg(pt)||$l(pt)||On(pt)},()=>[nt],"translate exists",$t=>Reflect.apply($t.te,$t,[nt,It]),GJ,$t=>li($t))}function Ae(nt){let It=null;const $t=Yz(Z,m.value,a.value);for(let $e=0;$e<$t.length;$e++){const pt=g.value[$t[$e]]||{},gn=Z.messageResolver(pt,nt);if(gn!=null){It=gn;break}}return It}function we(nt){const It=Ae(nt);return It??(t?t.tm(nt)||{}:{})}function Je(nt){return g.value[nt]||{}}function ct(nt,It){if(i){const $t={[nt]:It};for(const $e in $t)Cc($t,$e)&&H_($t[$e]);It=$t[nt]}g.value[nt]=It,Z.messages=g.value}function mt(nt,It){g.value[nt]=g.value[nt]||{};const $t={[nt]:It};if(i)for(const $e in $t)Cc($t,$e)&&H_($t[$e]);It=$t[nt],Mb(It,g.value[nt]),Z.messages=g.value}function Vt(nt){return x.value[nt]||{}}function Ie(nt,It){x.value[nt]=It,Z.datetimeFormats=x.value,jD(Z,nt,It)}function Pe(nt,It){x.value[nt]=ha(x.value[nt]||{},It),Z.datetimeFormats=x.value,jD(Z,nt,It)}function rt(nt){return T.value[nt]||{}}function Tt(nt,It){T.value[nt]=It,Z.numberFormats=T.value,VD(Z,nt,It)}function pn(nt,It){T.value[nt]=ha(T.value[nt]||{},It),Z.numberFormats=T.value,VD(Z,nt,It)}XD++,t&&hx&&(Nn(t.locale,nt=>{c&&(a.value=nt,Z.locale=nt,Gy(Z,a.value,m.value))}),Nn(t.fallbackLocale,nt=>{c&&(m.value=nt,Z.fallbackLocale=nt,Gy(Z,a.value,m.value))}));const qt={id:XD,locale:me,fallbackLocale:ge,get inheritLocale(){return c},set inheritLocale(nt){c=nt,nt&&t&&(a.value=t.locale.value,m.value=t.fallbackLocale.value,Gy(Z,a.value,m.value))},get availableLocales(){return Object.keys(g.value).sort()},messages:ce,get modifiers(){return W},get pluralRules(){return Q||{}},get isGlobal(){return r},get missingWarn(){return C},set missingWarn(nt){C=nt,Z.missingWarn=C},get fallbackWarn(){return A},set fallbackWarn(nt){A=nt,Z.fallbackWarn=A},get fallbackRoot(){return P},set fallbackRoot(nt){P=nt},get fallbackFormat(){return D},set fallbackFormat(nt){D=nt,Z.fallbackFormat=D},get warnHtmlMessage(){return j},set warnHtmlMessage(nt){j=nt,Z.warnHtmlMessage=nt},get escapeParameter(){return U},set escapeParameter(nt){U=nt,Z.escapeParameter=nt},t:se,getLocaleMessage:Je,setLocaleMessage:ct,mergeLocaleMessage:mt,getPostTranslationHandler:xe,setPostTranslationHandler:Te,getMissingHandler:oe,setMissingHandler:ne,[iN]:Me};return qt.datetimeFormats=fe,qt.numberFormats=ie,qt.rt=Ne,qt.te=lt,qt.tm=we,qt.d=Se,qt.n=xt,qt.getDateTimeFormat=Vt,qt.setDateTimeFormat=Ie,qt.mergeDateTimeFormat=Pe,qt.getNumberFormat=rt,qt.setNumberFormat=Tt,qt.mergeNumberFormat=pn,qt[oN]=n,qt[qS]=je,qt[WS]=tt,qt[HS]=st,qt}function WJ(e){const t=On(e.locale)?e.locale:W_,n=On(e.fallbackLocale)||Jo(e.fallbackLocale)||Or(e.fallbackLocale)||e.fallbackLocale===!1?e.fallbackLocale:t,r=io(e.missing)?e.missing:void 0,i=li(e.silentTranslationWarn)||og(e.silentTranslationWarn)?!e.silentTranslationWarn:!0,s=li(e.silentFallbackWarn)||og(e.silentFallbackWarn)?!e.silentFallbackWarn:!0,c=li(e.fallbackRoot)?e.fallbackRoot:!0,a=!!e.formatFallbackMessages,m=Or(e.modifiers)?e.modifiers:{},g=e.pluralizationRules,x=io(e.postTranslation)?e.postTranslation:void 0,T=On(e.warnHtmlInMessage)?e.warnHtmlInMessage!=="off":!0,C=!!e.escapeParameterHtml,A=li(e.sync)?e.sync:!0;let P=e.messages;if(Or(e.sharedMessages)){const W=e.sharedMessages;P=Object.keys(W).reduce((Z,K)=>{const Y=Z[K]||(Z[K]={});return ha(Y,W[K]),Z},P||{})}const{__i18n:D,__root:B,__injectWithOption:R}=e,N=e.datetimeFormats,j=e.numberFormats,U=e.flatJson;return{locale:t,fallbackLocale:n,messages:P,flatJson:U,datetimeFormats:N,numberFormats:j,missing:r,missingWarn:i,fallbackWarn:s,fallbackRoot:c,fallbackFormat:a,modifiers:m,pluralRules:g,postTranslation:x,warnHtmlMessage:T,escapeParameter:C,messageResolver:e.messageResolver,inheritLocale:A,__i18n:D,__root:B,__injectWithOption:R}}function ZS(e={}){const t=o2(WJ(e)),{__extender:n}=e,r={id:t.id,get locale(){return t.locale.value},set locale(i){t.locale.value=i},get fallbackLocale(){return t.fallbackLocale.value},set fallbackLocale(i){t.fallbackLocale.value=i},get messages(){return t.messages.value},get datetimeFormats(){return t.datetimeFormats.value},get numberFormats(){return t.numberFormats.value},get availableLocales(){return t.availableLocales},get missing(){return t.getMissingHandler()},set missing(i){t.setMissingHandler(i)},get silentTranslationWarn(){return li(t.missingWarn)?!t.missingWarn:t.missingWarn},set silentTranslationWarn(i){t.missingWarn=li(i)?!i:i},get silentFallbackWarn(){return li(t.fallbackWarn)?!t.fallbackWarn:t.fallbackWarn},set silentFallbackWarn(i){t.fallbackWarn=li(i)?!i:i},get modifiers(){return t.modifiers},get formatFallbackMessages(){return t.fallbackFormat},set formatFallbackMessages(i){t.fallbackFormat=i},get postTranslation(){return t.getPostTranslationHandler()},set postTranslation(i){t.setPostTranslationHandler(i)},get sync(){return t.inheritLocale},set sync(i){t.inheritLocale=i},get warnHtmlInMessage(){return t.warnHtmlMessage?"warn":"off"},set warnHtmlInMessage(i){t.warnHtmlMessage=i!=="off"},get escapeParameterHtml(){return t.escapeParameter},set escapeParameterHtml(i){t.escapeParameter=i},get pluralizationRules(){return t.pluralRules||{}}
66,__composer:t,t(...i){return Reflect.apply(t.t,t,[...i])},rt(...i){return Reflect.apply(t.rt,t,[...i])},te(i,s){return t.te(i,s)},tm(i){return t.tm(i)},getLocaleMessage(i){return t.getLocaleMessage(i)},setLocaleMessage(i,s){t.setLocaleMessage(i,s)},mergeLocaleMessage(i,s){t.mergeLocaleMessage(i,s)},d(...i){return Reflect.apply(t.d,t,[...i])},getDateTimeFormat(i){return t.getDateTimeFormat(i)},setDateTimeFormat(i,s){t.setDateTimeFormat(i,s)},mergeDateTimeFormat(i,s){t.mergeDateTimeFormat(i,s)},n(...i){return Reflect.apply(t.n,t,[...i])},getNumberFormat(i){return t.getNumberFormat(i)},setNumberFormat(i,s){t.setNumberFormat(i,s)},mergeNumberFormat(i,s){t.mergeNumberFormat(i,s)}};return r.__extender=n,r}function HJ(e,t,n){return{beforeCreate(){const r=ko();if(!r)throw gl(Vs.UNEXPECTED_ERROR);const i=this.$options;if(i.i18n){const s=i.i18n;if(i.__i18n&&(s.__i18n=i.__i18n),s.__root=t,this===this.$root)this.$i18n=QD(e,s);else{s.__injectWithOption=!0,s.__extender=n.__vueI18nExtend,this.$i18n=ZS(s);const c=this.$i18n;c.__extender&&(c.__disposer=c.__extender(this.$i18n))}}else if(i.__i18n)if(this===this.$root)this.$i18n=QD(e,i);else{this.$i18n=ZS({__i18n:i.__i18n,__injectWithOption:!0,__extender:n.__vueI18nExtend,__root:t});const s=this.$i18n;s.__extender&&(s.__disposer=s.__extender(this.$i18n))}else this.$i18n=e;i.__i18nGlobal&&sN(t,i,i),this.$t=(...s)=>this.$i18n.t(...s),this.$rt=(...s)=>this.$i18n.rt(...s),this.$te=(s,c)=>this.$i18n.te(s,c),this.$d=(...s)=>this.$i18n.d(...s),this.$n=(...s)=>this.$i18n.n(...s),this.$tm=s=>this.$i18n.tm(s),n.__setInstance(r,this.$i18n)},mounted(){},unmounted(){const r=ko();if(!r)throw gl(Vs.UNEXPECTED_ERROR);const i=this.$i18n;delete this.$t,delete this.$rt,delete this.$te,delete this.$d,delete this.$n,delete this.$tm,i.__disposer&&(i.__disposer(),delete i.__disposer,delete i.__extender),n.__deleteInstance(r),delete this.$i18n}}}function QD(e,t){e.locale=t.locale||e.locale,e.fallbackLocale=t.fallbackLocale||e.fallbackLocale,e.missing=t.missing||e.missing,e.silentTranslationWarn=t.silentTranslationWarn||e.silentFallbackWarn,e.silentFallbackWarn=t.silentFallbackWarn||e.silentFallbackWarn,e.formatFallbackMessages=t.formatFallbackMessages||e.formatFallbackMessages,e.postTranslation=t.postTranslation||e.postTranslation,e.warnHtmlInMessage=t.warnHtmlInMessage||e.warnHtmlInMessage,e.escapeParameterHtml=t.escapeParameterHtml||e.escapeParameterHtml,e.sync=t.sync||e.sync,e.__composer[iN](t.pluralizationRules||e.pluralizationRules);const n=i2(e.locale,{messages:t.messages,__i18n:t.__i18n});return Object.keys(n).forEach(r=>e.mergeLocaleMessage(r,n[r])),t.datetimeFormats&&Object.keys(t.datetimeFormats).forEach(r=>e.mergeDateTimeFormat(r,t.datetimeFormats[r])),t.numberFormats&&Object.keys(t.numberFormats).forEach(r=>e.mergeNumberFormat(r,t.numberFormats[r])),e}const a2={tag:{type:[String,Object]},locale:{type:String},scope:{type:String,validator:e=>e==="parent"||e==="global",default:"parent"},i18n:{type:Object}};function YJ({slots:e},t){return t.length===1&&t[0]==="default"?(e.default?e.default():[]).reduce((r,i)=>[...r,...i.type===Hn?i.children:[i]],[]):t.reduce((n,r)=>{const i=e[r];return i&&(n[r]=i()),n},Ri())}function lN(){return Hn}const ZJ=sr({name:"i18n-t",props:ha({keypath:{type:String,required:!0},plural:{type:[Number,String],validator:e=>Qo(e)||!isNaN(e)}},a2),setup(e,t){const{slots:n,attrs:r}=t,i=e.i18n||s2({useScope:e.scope,__useComponent:!0});return()=>{const s=Object.keys(n).filter(T=>T!=="_"),c=Ri();e.locale&&(c.locale=e.locale),e.plural!==void 0&&(c.plural=On(e.plural)?+e.plural:e.plural);const a=YJ(t,s),m=i[qS](e.keypath,a,c),g=ha(Ri(),r),x=On(e.tag)||gi(e.tag)?e.tag:lN();return ao(x,g,m)}}}),JD=ZJ;function XJ(e){return Jo(e)&&!On(e[0])}function cN(e,t,n,r){const{slots:i,attrs:s}=t;return()=>{const c={part:!0};let a=Ri();e.locale&&(c.locale=e.locale),On(e.format)?c.key=e.format:gi(e.format)&&(On(e.format.key)&&(c.key=e.format.key),a=Object.keys(e.format).reduce((C,A)=>n.includes(A)?ha(Ri(),C,{[A]:e.format[A]}):C,Ri()));const m=r(e.value,c,a);let g=[c.key];Jo(m)?g=m.map((C,A)=>{const P=i[C.type],D=P?P({[C.type]:C.value,index:A,parts:m}):[C.value];return XJ(D)&&(D[0].key=`${C.type}-${A}`),D}):On(m)&&(g=[m]);const x=ha(Ri(),s),T=On(e.tag)||gi(e.tag)?e.tag:lN();return ao(T,x,g)}}const KJ=sr({name:"i18n-n",props:ha({value:{type:Number,required:!0},format:{type:[String,Object]}},a2),setup(e,t){const n=e.i18n||s2({useScope:e.scope,__useComponent:!0});return cN(e,t,tN,(...r)=>n[HS](...r))}}),eL=KJ;function QJ(e,t){const n=e;if(e.mode==="composition")return n.__getInstance(t)||e.global;{const r=n.__getInstance(t);return r!=null?r.__composer:e.global.__composer}}function JJ(e){const t=c=>{const{instance:a,value:m}=c;if(!a||!a.$)throw gl(Vs.UNEXPECTED_ERROR);const g=QJ(e,a.$),x=tL(m);return[Reflect.apply(g.t,g,[...nL(x)]),g]};return{created:(c,a)=>{const[m,g]=t(a);hx&&e.global===g&&(c.__i18nWatcher=Nn(g.locale,()=>{a.instance&&a.instance.$forceUpdate()})),c.__composer=g,c.textContent=m},unmounted:c=>{hx&&c.__i18nWatcher&&(c.__i18nWatcher(),c.__i18nWatcher=void 0,delete c.__i18nWatcher),c.__composer&&(c.__composer=void 0,delete c.__composer)},beforeUpdate:(c,{value:a})=>{if(c.__composer){const m=c.__composer,g=tL(a);c.textContent=Reflect.apply(m.t,m,[...nL(g)])}},getSSRProps:c=>{const[a]=t(c);return{textContent:a}}}}function tL(e){if(On(e))return{path:e};if(Or(e)){if(!("path"in e))throw gl(Vs.REQUIRED_VALUE,"path");return e}else throw gl(Vs.INVALID_VALUE)}function nL(e){const{path:t,locale:n,args:r,choice:i,plural:s}=e,c={},a=r||{};return On(n)&&(c.locale=n),Qo(i)&&(c.plural=i),Qo(s)&&(c.plural=s),[t,a,c]}function eee(e,t,...n){const r=Or(n[0])?n[0]:{};(li(r.globalInstall)?r.globalInstall:!0)&&([JD.name,"I18nT"].forEach(s=>e.component(s,JD)),[eL.name,"I18nN"].forEach(s=>e.component(s,eL)),[iL.name,"I18nD"].forEach(s=>e.component(s,iL))),e.directive("t",JJ(t))}const tee=Fd("global-vue-i18n");function nee(e={}){const t=__VUE_I18N_LEGACY_API__&&li(e.legacy)?e.legacy:__VUE_I18N_LEGACY_API__,n=li(e.globalInjection)?e.globalInjection:!0,r=new Map,[i,s]=ree(e,t),c=Fd("");function a(T){return r.get(T)||null}function m(T,C){r.set(T,C)}function g(T){r.delete(T)}const x={get mode(){return __VUE_I18N_LEGACY_API__&&t?"legacy":"composition"}
66,async install(T,...C){if(T.__VUE_I18N_SYMBOL__=c,T.provide(T.__VUE_I18N_SYMBOL__,x),Or(C[0])){const D=C[0];x.__composerExtend=D.__composerExtend,x.__vueI18nExtend=D.__vueI18nExtend}let A=null;!t&&n&&(A=hee(T,x.global)),__VUE_I18N_FULL_INSTALL__&&eee(T,x,...C),__VUE_I18N_LEGACY_API__&&t&&T.mixin(HJ(s,s.__composer,x));const P=T.unmount;T.unmount=()=>{A&&A(),x.dispose(),P()}},get global(){return s},dispose(){i.stop()},__instances:r,__getInstance:a,__setInstance:m,__deleteInstance:g};return x}function s2(e={}){const t=ko();if(t==null)throw gl(Vs.MUST_BE_CALL_SETUP_TOP);if(!t.isCE&&t.appContext.app!=null&&!t.appContext.app.__VUE_I18N_SYMBOL__)throw gl(Vs.NOT_INSTALLED);const n=iee(t),r=aee(n),i=aN(t),s=oee(e,i);if(s==="global")return sN(r,e,i),r;if(s==="parent"){let m=see(n,t,e.__useComponent);return m==null&&(m=r),m}const c=n;let a=c.__getInstance(t);if(a==null){const m=ha({},e);"__i18n"in i&&(m.__i18n=i.__i18n),r&&(m.__root=r),a=o2(m),c.__composerExtend&&(a[YS]=c.__composerExtend(a)),cee(c,t,a),c.__setInstance(t,a)}return a}function ree(e,t){const n=xg(),r=__VUE_I18N_LEGACY_API__&&t?n.run(()=>ZS(e)):n.run(()=>o2(e));if(r==null)throw gl(Vs.UNEXPECTED_ERROR);return[n,r]}function iee(e){const t=dr(e.isCE?tee:e.appContext.app.__VUE_I18N_SYMBOL__);if(!t)throw gl(e.isCE?Vs.NOT_INSTALLED_WITH_PROVIDE:Vs.UNEXPECTED_ERROR);return t}function oee(e,t){return _1(e)?"__i18n"in t?"local":"global":e.useScope?e.useScope:"local"}function aee(e){return e.mode==="composition"?e.global:e.global.__composer}function see(e,t,n=!1){let r=null;const i=t.root;let s=lee(t,n);for(;s!=null;){const c=e;if(e.mode==="composition")r=c.__getInstance(s);else if(__VUE_I18N_LEGACY_API__){const a=c.__getInstance(s);a!=null&&(r=a.__composer,n&&r&&!r[oN]&&(r=null))}if(r!=null||i===s)break;s=s.parent}return r}function lee(e,t=!1){return e==null?null:t&&e.vnode.ctx||e.parent}function cee(e,t,n){Dr(()=>{},t),Bi(()=>{const r=n;e.__deleteInstance(t);const i=r[YS];i&&(i(),delete r[YS])},t)}const uee=["locale","fallbackLocale","availableLocales"],rL=["t","rt","d","n","tm","te"];function hee(e,t){const n=Object.create(null);return uee.forEach(i=>{const s=Object.getOwnPropertyDescriptor(t,i);if(!s)throw gl(Vs.UNEXPECTED_ERROR);const c=Ai(s.value)?{get(){return s.value.value},set(a){s.value.value=a}}:{get(){return s.get&&s.get()}};Object.defineProperty(n,i,c)}),e.config.globalProperties.$i18n=n,rL.forEach(i=>{const s=Object.getOwnPropertyDescriptor(t,i);if(!s||!s.value)throw gl(Vs.UNEXPECTED_ERROR);Object.defineProperty(e.config.globalProperties,`$${i}`,s)}),()=>{delete e.config.globalProperties.$i18n,rL.forEach(i=>{delete e.config.globalProperties[`$${i}`]})}}const dee=sr({name:"i18n-d",props:ha({value:{type:[Number,Date],required:!0},format:{type:[String,Object]}},a2),setup(e,t){const n=e.i18n||s2({useScope:e.scope,__useComponent:!0});return cN(e,t,eN,(...r)=>n[WS](...r))}}),iL=dee;VJ();xJ(nJ);wJ(_J);TJ(Yz);if(__INTLIFY_PROD_DEVTOOLS__){const e=Xf();e.__INTLIFY__=!0,rJ(e.__INTLIFY_DEVTOOLS_GLOBAL_HOOK__)}const fee="Quantity",pee="Production Location",mee="Need Paints?",gee="North",yee="South",_ee="East",vee="West",bee="Registered & Recognized By",xee={Beranda:"Home","Tentang Kami":"About Us","Katalog Produk":"Product Catalog","Kalkulator Volume":"Volume Calculator","Kontak Kami":"Contact Us",Member:"Register As Member"},wee="Need help? Contact us now for the best solution!",Tee="Find Us",Eee={LearnMore:"Learn More",ContactUs:"Contact Us",OrderNow:"Order Now",SeeAll:"See All",CustomerPortal:"Customer Portal",LihatPeta:"View Map"},See={Menampilkan:"Showing",Hingga:"to",Dari:"of",Entri:"entries"},Cee={Mutu:"Concrete Quality"},kee={MainBanner:{Heading:"Quality Concrete","Sub-1":"for Building","Sub-2":"a Green Future",SubHeading:{Main:"Ready-mix concrete with high quality, material innovation with",Italic:"secular economic",Sub:"to build a more environmentally friendly Indonesia."},OrderButton:"Order Concrete",LearnMoreButton:"Learn More"},OpcReplaced:{Heading:"Total OPC Successfully Substituted (KG)",LastData:"Real-Time Calculation:",Description:{"desc-1":"OPC cement is the largest CO₂ producer in the","desc-2":"building","desc-3":"materials industry.","desc-4":"1 KG of OPC generates 0.8 - 0.9 KG of CO₂."},LearnMoreButton:"Learn More"},Mission:{WhyChoose:"Why Choose",Heading:"The Advantages of ",Text:"Powered by innovative technology and low-carbon materials, BRIK Mix is shaping the future of the construction industry with concrete solutions that optimize performance, cost, and environmental sustainability.",LearnButton:"Learn More"},System:{Heading:{"heading-1":"Easy","heading-2":"Fast","heading-3":"and","heading-4":"Well-Organized Administration"},Sub:"Integrated Technology for Ordering, Coordination, and Administration",OnlineOrder:{Heading:"Easy Online Ordering 24/7",Text:"Create an account on the BOD platform to enjoy new efficie
66ncy and affordability in concrete, with exclusive promotions and 24/7 online ordering."},Scheduling:{Heading:"Self-Scheduling",Text:"Schedule your concrete delivery anytime, day or night, through the BOD platform."},DeliveryTracking:{Heading:"Real-Time Delivery Tracking",Text:"Enjoy full visibility of your delivery with real-time location tracking, ensuring you're always informed about the status and progress of your delivery."},Mix:{Heading:"Complete Transparent Mix Design",Text:"With the BOD platform, gain instant access to mix designs and production results for every concrete delivery, offering unmatched transparency and control at your fingertips."},Monitoring:{Heading:"Remote Monitoring",Text:"Monitor concrete deliveries in real-time, anytime, anywhere. Access or download videos and photos through BOD for smooth project execution. Visuals are automatically captured from our vehicles and taken by our field officers, ensuring full coverage."},Administration:{Heading:"Simplified Administration",Text:"With the BOD platform, gain instant access to mix designs and production results for every concrete delivery, offering unparalleled transparency and control at your fingertips."}},Concrete:{Header:"Product",SeeAllButton:"More"},PriceList:{Heading:"Order",Sub:" Now",Text:"Check Prices in Real-Time!",Help:{Heading:"Get help understanding your needs",Sub:"Have specific concrete needs or feeling unsure? Our expert team is ready to provide solutions to understand your unique requirements.",ContactUsButton:"Contact Us"}},Project:{Heading:"Current",Sub:"Projects"},Partner:{Heading:"Trusted",Sub:"By"},Recyle:{Heading:"Recycle Your Concrete!",Sub:"If you're demolishing an old building, we'll buy your old concrete. Contact us now!",ContactUsButton:"Contact Us"},Experience:{Deliveries:"Orders",YearsExperience:"Years of Experience",ProjectsCompleted:"Projects Completed"},Video:{MobileHeading:'<h1 class="text-2xl text-center font-bold tagline"><span>Follow </span><span>the Journey of </span><span class="text-red-600">BRIK </span><br /><span>to Your </span><span>Project! </span></h1><p class="text-1xl text-center font-semibold sub-tagline">The best solution, straight to your project.</p>',Heading:'<div class="tagline-container text-center"><h1 class="text-5xl font-bold tagline"><span>Follow </span><span>the Journey of </span><span class="text-red-600">BRIK </span><span>to Your </span><span>Project! </span></h1><p class="text-3xl font-semibold sub-tagline">The best solution, straight to your project.</p></div>',Scene2:"The process of loading readymix concrete into the Transit Mixer, ensuring the <strong>quality</strong> of the mix is preserved throughout delivery to your project site.",Scene3:"The process of delivering readymix concrete en route, with <strong>guaranteed on-time delivery</strong> and the quality of the concrete maintained optimally until it arrives at your project site.",Scene4:"The process when the Truck Mixer arrives at the project site and the readymix concrete is poured. <strong>We guarantee the exact quality and quantity of concrete</strong> as requested, with no cuts or irregularities."},PlantMap:{Heading:{h1:"<span>Our </span>Batching Plants",h2:"Check Our Batching Plant List"},Sub:"BRIK Mix Batching Plants"},RawMaterial:{Heading:"High-Quality Raw Materials",Text:"Using high-quality Bangka sand and Tayan sand, combined with premium split from Tarabatu Quarry owned by Semen Indonesia Group (SIG), as well as OPC Type 1 cement from Semen Tiga Roda for strong and high-quality results."}},Aee={HeroBanner:"About Us",Vision:{Heading:{Text:"The company started with the idea of a group of young people, enthusiasts and practitioners of construction, with a business philosophy.","heading-1":"HONEST","heading-2":"ORGANIZED","heading-3":"and","heading-4":"GREEN"}},TabButton:{Mission:"Our Mission",Vision:"Our Vision"},Tab:{MissionDescription:"Modernizing the construction industry in Indonesia and using technology to enhance the service levels of building material suppliers in Indonesia.",VisionDescription:"Creating a technology-driven company in the ready-mix concrete industry, adhering to 21st-century standards."}
66,OrderButton:"Order Concrete",Contact:{Heading:"Want to discuss a project?"},CompanyValues:{Heading:"Company Values & Mission"}},Pee={MainFeature:"Main Features",BenefitKonstruksi:"Construction Benefits",BenefitPelanggan:"Customer Benefits",AreaAplikasi:"Application Areas",Product:"Products"},Mee={Tinggi:"Height",Panjang:"Length",Lebar:"Width",Diameter:"Diameter",DiameterLuar:"Outer Diameter",DiamaterDalam:"Inner Diameter",Estimation:"Your Estimated Requirements Result",CalculateRmc:"Calculate Ready-Mix Concrete (RMC) Requirements",Heading:"Calculate Your Concrete Needs","Pilih Bentuk Konstruksi":"Select Construction Shape"},Iee={Heading:"Our Mindset & Values",MindsetValues:"Precision, Efficiency, Excelence,Done.",CoreValue1:"Customer Needs First",CoreValue2:"Honest and Open Communication",CoreValue3:"Obsession with Operational Excellence",CoreValue4:"Pursuits of Continuous Improvements"},Oee={Kuantitas:fee,LokasiProduksi:pee,NeedPaint:mee,North:gee,South:yee,East:_ee,West:vee,RegisteredAndRecognizedBy:bee,MenuBar:xee,WhatsappHelp:wee,FindUs:Tee,Buttons:Eee,Pagination:See,Table:Cee,HomePage:kee,AboutUsPage:Aee,ProductPage:Pee,CalculatorPage:Mee,Values:Iee},Dee="Kuantitas",Lee="Lokasi Produksi",Ree="Butuh Cat?",Fee="Utara",Bee="Selatan",zee="Timur",Nee="Barat",$ee="Terdaftar & Diakui Oleh",jee={Beranda:"Beranda","Tentang Kami":"Tentang Kami","Katalog Produk":"Katalog Produk","Kalkulator Volume":"Kalkulator Volume","Kontak Kami":"Kontak Kami",Member:"Daftar Sebagai Member"},Uee="Butuh bantuan? Hubungi kami sekarang untuk solusi terbaik!",Vee="Temukan Kami",Gee={LearnMore:"Pelajari Lebih Lanjut",ContactUs:"Hubungi Kami",OrderNow:"Pesan Sekarang",SeeAll:"Lihat Semua",CustomerPortal:"Portal Pelanggan",LihatPeta:"Lihat Peta"},qee={Menampilkan:"Menampilkan",Hingga:"hingga",Dari:"dari",Entri:"entri"},Wee={Mutu:"Mutu"},Hee={MainBanner:{Heading:"Beton Berkualitas","Sub-1":"untuk Membangun","Sub-2":"Masa Depan Hijau",SubHeading:{Main:"Beton siap pakai dengan kualitas tinggi inovasi material dengan tesis",Italic:"secular economic",Sub:"untuk membangun Indonesia jadi ramah lingkungan."},OrderButton:"Pesan Beton",LearnMoreButton:"Pelajari Lebih Lanjut"},OpcReplaced:{Heading:"Total OPC yang Berhasil Disubstitusi (KG)",LastData:"Data terakhir di perbarui:",Description:{"desc-1":"Semen OPC adalah penghasil CO₂ terbesar di industri","desc-2":"building","desc-3":"material","desc-4":". 1KG OPC menghasilkan 0,8 - 0,9 KG CO₂."},LearnMoreButton:"Pelajari Lebih Lanjut"},Mission:{WhyChoose:"Kenapa Pilih",Heading:"Keunggulan",Text:"Didukung oleh teknologi inovatif dan material rendah karbon, BRIK Mix menciptakan masa depan industri konstruksi dengan solusi beton yang mengoptimalkan performa, biaya, dan keberlanjutan lingkungan.",LearnButton:"Pelajari Lebih Lanjut"},System:{Heading:{"heading-1":"Mudah","heading-2":"Cepat","heading-3":"dan","heading-4":"Administrasi Rapih"},Sub:"Teknologi yang Terintegrasi Mulai dari Pemesanan, Koordinasi, dan Administrasi",OnlineOrder:{Heading:"Pemesanan Online Mudah 24/7",Text:"Buat akun di platform BOD untuk menikmati efisiensi dan keterjangkauan baru dalam beton, dengan promo eksklusif dan pemesanan online 24/7."},Scheduling:{Heading:"Penjadwalan Mandiri",Text:"Jadwalkan pengiriman beton Anda kapan saja, baik siang maupun malam, melalui platform BOD."},DeliveryTracking:{Heading:"Pelacakan Pengiriman Waktu Nyata",Text:"Nikmati visibilitas lengkap pada pengiriman Anda dengan pelacakan lokasi waktu nyata, yang memastikan Anda selalu mendapat informasi tentang status dan kemajuan pengiriman."},Mix:{Heading:"Desain Campuran Lengkap Transparan",Text:"Dengan platform BOD, dapatkan akses instan ke desain campuran dan hasil produksi setiap pengiriman beton, yang menawarkan transparansi dan kontrol yang tak tertandingi di ujung jari Anda."},Monitoring:{Heading:"Pemantauan Jarak Jauh",Text:"Pantau pengiriman beton secara real-time, kapan saja, di mana saja. Akses atau unduh video dan foto melalui BOD untuk pelaksanaan proyek yang lancar. Visual diambil secara otomatis dari kendaraan kami dan diambil oleh petugas lapangan kami, memastikan cakupan penuh."},Administration:{Heading:"Administrasi yang Sederhana",Text:"Dengan platform BOD, dapatkan akses instan ke desain campuran dan hasil produksi setiap pengiriman beton, yang menawarkan transparansi dan kontrol yang tak tertandingi di ujung jari Anda."}},Concrete:{Header:"Produk",SeeAllButton:"Lihat Semua"},PriceList:{Heading:"Pesan",Sub:" Sekarang",Text:"Cek Harga Secara Real-Time!",Help:{Heading:"Dapatkan bantuan untuk memahami kebutuhan Anda",Sub:"Punya kebutuhan beton khusus atau bingung? Tim ahli kami siap memberikan solusi untuk memahami kebutuhan spesifik Anda.",ContactUsButton:"Hubungi Kami"}},Project:{Heading:"Proyek",Sub:"Terkini Kami"},Partner:{Heading:"Dipercaya",Sub:"Oleh"},Recyle:{Heading:"Daur Ulang  <br /> Beton Anda!",Sub:"Jika Anda merobohkan bangunan lama, kami akan membeli <br /> beton lama Anda. Hubungi kami sekarang!",ContactUsButton:"Hubungi Kami"},Experience:{Deliveries:"Pesanan",YearsExperience:"Tahun Pengalaman",ProjectsCompleted:"Proyek Selesai"},Video:{MobileHeading:'<h1 class="text-2xl text-center font-bold tagline"><span>
66Ikuti </span><span>Perjalanan </span><span class="text-red-600">BRIK </span><br /><span>Menuju </span><span>Proyek </span><span>Anda! </span></h1><p class="text-1xl text-center font-semibold sub-tagline">Solusi terbaik, langsung menuju proyek Anda.</p>',Heading:'<div class="tagline-container text-center"><h1 class="text-5xl font-bold tagline"><span>Ikuti </span><span>Perjalanan </span><span class="text-red-600">BRIK </span><span>Menuju </span><span>Proyek </span><span>Anda! </span></h1><p class="text-3xl font-semibold sub-tagline">Solusi terbaik, langsung menuju proyek Anda.</p></div>',Scene2:"Proses pengisian beton readymix ke dalam Transit Mixer, memastikan <strong>kualitas</strong> beton terjaga dengan baik selama pengiriman ke proyek Anda.",Scene3:"Proses pengiriman beton readymix dalam perjalanan, dengan pengiriman yang <strong>dijamin tepat waktu</strong> dan kualitas beton tetap terjaga optimal hingga tiba di lokasi proyek Anda.",Scene4:"Proses saat Truck Mixer tiba di lokasi proyek dan beton readymix dituangkan. <strong>Kami menjamin kualitas dan kuantitas beton yang tepat</strong> sesuai dengan permintaan, tanpa ada potongan atau kecurangan."},PlantMap:{Heading:{h1:"<span>Batching Plant </span>Kami",h2:"Cek Daftar Batching Plant Kami"},Sub:"Batching Plant BRIK Mix"},RawMaterial:{Heading:"Bahan Baku Berkualitas",Text:"Menggunakan pasir Bangka dan pasir Tayan yang berkualitas, dipadukan dengan split premium dari Tarabatu Quarry milik Semen Indonesia Group (SIG), serta semen OPC Tipe 1 dari Semen Tiga Roda untuk hasil yang kokoh dan bermutu tinggi."}},Yee={HeroBanner:"Tentang Kami",Vision:{Heading:{Text:"Perusahaan bermula dari gagasan sekelompok anak muda, penggemar dan penggiat konstruksi, dengan filosofi bisnis","heading-1":"JUJUR","heading-2":"RAPI","heading-3":"dan","heading-4":"HIJAU"}},TabButton:{Mission:"Misi Kami",Vision:"Visi Kami"},Tab:{MissionDescription:"Mendekabornisasi industri konstruksi di Indonesia dan menggunakan teknologi untuk meningkatkan tingkat pelayanan Supplier Building Material di Indonesia.",VisionDescription:"Membuat perusahaan yang didorong oleh teknologi dalam industri beton dan beton siap pakai sesuai standar abad ke-21."},OrderButton:"Pesan Beton",Contact:{Heading:"Ingin mendiskusikan proyek?"},CompanyValues:{Heading:"Nilai & Misi Perusahaan"}},Zee={MainFeature:"Fitur Utama",BenefitKonstruksi:"Benefit Konstruksi",BenefitPelanggan:"Benefit Pelanggan",AreaAplikasi:"Area Aplikasi",Product:"Produk"},Xee={Tinggi:"Tinggi",Panjang:"Panjang",Lebar:"Lebar",Diameter:"Diameter",DiameterLuar:"Diameter Luar",DiamaterDalam:"Diameter Dalam",Estimation:"Hasil Estimasi Kebutuhan Anda",CalculateRmc:"Hitung Kebutuhan Beton Readymix (RMC)",Heading:"Hitung Kebutuhan Beton Anda!","Pilih Bentuk Konstruksi":"Pilih Bentuk Konstruksi"},Kee={Heading:"Mindset & Values",MindsetValues:"Presisi. Efisiensi. Kualitas. Selesai",CoreValue1:"Kepuasan Pelanggan Nomor Satu",CoreValue2:"Komunikasi yang Transparan dan Jujur",CoreValue3:"Obsesi Mendalam terhadap Efisiensi dan Kualitas",CoreValue4:"Komitmen Abadi untuk Kemajuan"},Qee={Kuantitas:Dee,LokasiProduksi:Lee,NeedPaint:Ree,North:Fee,South:Bee,East:zee,West:Nee,RegisteredAndRecognizedBy:$ee,MenuBar:jee,WhatsappHelp:Uee,FindUs:Vee,Buttons:Gee,Pagination:qee,Table:Wee,HomePage:Hee,AboutUsPage:Yee,ProductPage:Zee,CalculatorPage:Xee,Values:Kee},Jee=Gi(({vueApp:e})=>{const t=nee({legacy:!1,globalInjection:!0,locale:"id",messages:{id:Qee,en:Oee}});e.use(t)}),ete=Ic("user",{state:()=>({token:null}),actions:{increment(){},async fetchToken(){try{const{data:e}=await y1.get("https://jsonplaceholder.typicode.com/users");this.token=e.data}catch(e){console.log(e)}}}}),Of={scheduler:"U0NIRURVTEVS",admin:"QURNSU4="},tte={routes:{"customerId-projects-projectId":[Of.admin],"customerId-projects-projectId-orders-orderId":[Of.admin],"customerId-projects-projectId-orders-new":[Of.admin],"customerId-projects-projectId-orders-new-products":[Of.admin],"customerId-projects-projectId-orders-new-products-productInternalId":[Of.admin]},roles:Of,items:{projectNavBar:[Of.admin]}};function nte(e){var t=typeof e;return e!=null&&(t=="object"||t=="function")}var uN=nte,rte=typeof oo=="object"&&oo&&oo.Object===Object&&oo,ite=rte,ote=ite,ate=typeof self=="object"&&self&&self.Object===Object&&self,ste=ote||ate||Function("return this")(),hN=ste,lte=hN,cte=function(){return lte.Date.now()},ute=cte,hte=/\s/;function dte(e){for(var t=e.length;t--&&hte.test(e.charAt(t)););return t}var fte=dte,pte=fte,mte=/^\s+/;function gte(e){return e&&e.slice(0,pte(e)+1).replace(mte,"")}var yte=gte,_te=hN,vte=_te.Symbol,dN=vte,oL=dN,fN=Object.prototype,bte=fN.hasOwnProperty,xte=fN.toString,qy=oL?oL.toStringTag:void 0;function wte(e){var t=bte.call(e,qy),n=e[qy];try{e[qy]=void 0;var r=!0}catch{}var i=xte.call(e);return r&&(t?e[qy]=n:delete e[qy]),i}var Tte=wte,Ete=Object.prototype,Ste=Ete.toString;function Cte(e){return Ste.call(e)}var kte=Cte,aL=dN,Ate=Tte,Pte=kte,Mte="[object Null]",Ite="[object Undef
66ined]",sL=aL?aL.toStringTag:void 0;function Ote(e){return e==null?e===void 0?Ite:Mte:sL&&sL in Object(e)?Ate(e):Pte(e)}var Dte=Ote;function Lte(e){return e!=null&&typeof e=="object"}var Rte=Lte,Fte=Dte,Bte=Rte,zte="[object Symbol]";function Nte(e){return typeof e=="symbol"||Bte(e)&&Fte(e)==zte}var $te=Nte,jte=yte,lL=uN,Ute=$te,cL=0/0,Vte=/^[-+]0x[0-9a-f]+$/i,Gte=/^0b[01]+$/i,qte=/^0o[0-7]+$/i,Wte=parseInt;function Hte(e){if(typeof e=="number")return e;if(Ute(e))return cL;if(lL(e)){var t=typeof e.valueOf=="function"?e.valueOf():e;e=lL(t)?t+"":t}if(typeof e!="string")return e===0?e:+e;e=jte(e);var n=Gte.test(e);return n||qte.test(e)?Wte(e.slice(2),n?2:8):Vte.test(e)?cL:+e}var Yte=Hte,Zte=uN,VT=ute,uL=Yte,Xte="Expected a function",Kte=Math.max,Qte=Math.min;function Jte(e,t,n){var r,i,s,c,a,m,g=0,x=!1,T=!1,C=!0;if(typeof e!="function")throw new TypeError(Xte);t=uL(t)||0,Zte(n)&&(x=!!n.leading,T="maxWait"in n,s=T?Kte(uL(n.maxWait)||0,t):s,C="trailing"in n?!!n.trailing:C);function A(Q){var Z=r,K=i;return r=i=void 0,g=Q,c=e.apply(K,Z),c}function P(Q){return g=Q,a=setTimeout(R,t),x?A(Q):c}function D(Q){var Z=Q-m,K=Q-g,Y=t-Z;return T?Qte(Y,s-K):Y}function B(Q){var Z=Q-m,K=Q-g;return m===void 0||Z>=t||Z<0||T&&K>=s}function R(){var Q=VT();if(B(Q))return N(Q);a=setTimeout(R,D(Q))}function N(Q){return a=void 0,C&&r?A(Q):(r=i=void 0,c)}function j(){a!==void 0&&clearTimeout(a),g=0,r=m=i=a=void 0}function U(){return a===void 0?c:N(VT())}function W(){var Q=VT(),Z=B(Q);if(r=arguments,i=this,m=Q,Z){if(a===void 0)return P(m);if(T)return clearTimeout(a),a=setTimeout(R,t),A(m)}return a===void 0&&(a=setTimeout(R,t)),c}return W.cancel=j,W.flush=U,W}var ene=Jte;const wa=Rd(ene);function XS(e){this.message=e}XS.prototype=new Error,XS.prototype.name="InvalidCharacterError";var hL=typeof window<"u"&&window.atob&&window.atob.bind(window)||function(e){var t=String(e).replace(/=+$/,"");if(t.length%4==1)throw new XS("'atob' failed: The string to be decoded is not correctly encoded.");for(var n,r,i=0,s=0,c="";r=t.charAt(s++);~r&&(n=i%4?64*n+r:r,i++%4)?c+=String.fromCharCode(255&n>>(-2*i&6)):0)r="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=".indexOf(r);return c};function tne(e){var t=e.replace(/-/g,"+").replace(/_/g,"/");switch(t.length%4){case 0:break;case 2:t+="==";break;case 3:t+="=";break;default:throw"Illegal base64url string!"}try{return function(n){return decodeURIComponent(hL(n).replace(/(.)/g,function(r,i){var s=i.charCodeAt(0).toString(16).toUpperCase();return s.length<2&&(s="0"+s),"%"+s}))}(t)}catch{return hL(t)}}function dx(e){this.message=e}function nne(e,t){if(typeof e!="string")throw new dx("Invalid token specified");var n=(t=t||{}).header===!0?0:1;try{return JSON.parse(tne(e.split(".")[n]))}catch(r){throw new dx("Invalid token specified: "+r.message)}}dx.prototype=new Error,dx.prototype.name="InvalidTokenError";const dL=e=>{let t={raw:e};try{t.decoded=nne(e)}catch(n){console.log(n)}return t},rne=(e,t,{stores:n}={})=>Ic("main",{state:()=>({token:null,role:null,customer:null,customerBalance:null,project:null,loginCheck:!1,schedules:null,schedulesProjectId:null,schedule:null,order:null,bp:[],bpDistances:null,bpDistance:null,deb:{},sois:null,soisByProject:null,soisProjectId:null,purchaseOrderId:null,scheduleDates:[]}),getters:{getProductStore(){return n}},actions:{increment(){},logout(){this.token=null,this.deb={}},async checkLoggedIn({id:r,pin:i}={}){var s,c,a,m,g,x,T,C,A,P,D;try{console.log("checkLoggedIn");let B=localStorage.getItem("token");if(B)try{B=JSON.parse(B),this.token=B,(((s=this.token.decoded)==null?void 0:s.iat)||0)<1695525311&&!((c=this.token.decoded)!=null&&c.role)?(console.log("OLD TOKEN!"),this.role=tte.roles.admin):this.role=(a=this.token.decoded)==null?void 0:a.role}catch(j){console.log(j)}r===((g=(m=this.token)==null?void 0:m.decoded)==null?void 0:g.id)?vr.defaults.headers.common={Authorization:`Bearer ${(x=this.token)==null?void 0:x.raw}`}:vr.defaults.headers.common={Authorization:void 0};const R=await vr(`/customer/b/customer/${r}`,{method:"POST",data:{pin:i}}),N=R==null?void 0:R.data;return N!=null&&N.data&&(this.token=dL(N==null?void 0:N.data),this.role=(T=this.token.decoded)==null?void 0:T.role,localStorage.setItem("token",JSON.stringify(this.token)),vr.defaults.headers.common={Authorization:`Bearer ${(C=this.token)==null?void 0:C.raw}`}),N}
66catch(B){if(console.log(B),(A=B==null?void 0:B.response)!=null&&A.data)return{status:(P=B==null?void 0:B.response)==null?void 0:P.status,...(D=B==null?void 0:B.response)==null?void 0:D.data}}},async loginByPhone(r){var i,s;try{const a=(await vr("/customer/b/customer/login",{method:"POST",data:r})).data;return a!=null&&a.data&&(this.token=dL(a==null?void 0:a.data),this.role=(i=this.token.decoded)==null?void 0:i.role,localStorage.setItem("token",JSON.stringify(this.token)),vr.defaults.headers.common={Authorization:`Bearer ${(s=this.token)==null?void 0:s.raw}`}),a}catch(c){console.log(c)}},async register(r){return(await vr("/customer/b/customer/register",{method:"POST",data:r})).data},async sendOtp(r){try{return(await vr("/customer/b/customer/send-otp",{method:"POST",data:r})).data}catch(i){console.log(i)}},async login({id:r,pin:i}={}){return await this.checkLoggedIn({id:r,pin:i})},async getCustomer({id:r}={}){var i;try{((i=this.customer)==null?void 0:i.id)!==r&&(this.customer=null),console.log("getCustomer",Date.now());const s=await vr("/customer/b/customer/detail",{method:"GET",params:{id:r}}),c=s==null?void 0:s.data;return this.customer=c.data,this.customer}catch(s){console.log(s)}},async debGetCustomer({id:r}={}){return console.log("debGetCustomer",Date.now()),this.deb.getCustomer||(this.deb.getCustomer=wa(this.getCustomer,500,{leading:!0,trailing:!1})),await this.deb.getCustomer({id:r})},async getCustomerBalance(){try{const r=await vr("/customer/b/customer/balance",{method:"GET"}),i=r==null?void 0:r.data.data;return this.customerBalance=i,this.customerBalance}catch(r){console.log(r)}},async debGetCustomerBalance({id:r}={}){return console.log("debGetCustomerBalance",Date.now()),this.deb.getCustomerBalance||(this.deb.getCustomerBalance=wa(this.getCustomerBalance,500,{leading:!0,trailing:!1})),await this.deb.getCustomerBalance({id:r})},async getProject({customerId:r,id:i}={}){var s,c;try{console.log("getProject",Date.now(),i),((s=this.project)==null?void 0:s.id)!==i&&(this.project=null);const a=await vr(`/customer/b/project/${i}`,{method:"GET"}),m=a==null?void 0:a.data;this.project=m==null?void 0:m.data,console.log({project:this.project});try{console.log("getBatchingPlants"),await((c=n.product)==null?void 0:c.getBatchingPlants(i))}catch(g){console.log(g)}return console.log("Get Project Done",Date.now()),this.project}catch(a){console.log(a)}},async debGetProject({customerId:r,id:i}={}){return console.log("debGetProject",Date.now()),this.deb.getProject||(this.deb.getProject=wa(this.getProject,500,{leading:!0,trailing:!1})),await this.deb.getProject({customerId:r,id:i})},async getSchedules({projectId:r}={}){var i;try{this.schedulesProjectId!==r&&(this.schedulesProjectId=null);const s=await vr(`/customer/b/schedule/project/${r}`,{method:"GET"}),c=await vr(`/customer/b/schedule/customer/${(i=this.customer)==null?void 0:i.id}`,{method:"GET"}),a=s==null?void 0:s.data,m=c==null?void 0:c.data;return this.schedulesProjectId=r,this.schedules=a==null?void 0:a.data,this.scheduleDates=m==null?void 0:m.data.map(g=>{const x=new Date(g.date),T=x.getFullYear(),C=x.getMonth()+1,A=x.getDate(),P=C<10?`0${C}`:C,D=A<10?`0${A}`:A;return new Date(g.date)}),this.schedules}catch(s){console.log(s)}},async debGetSchedules({projectId:r}={}){return this.deb.getSchedules||(this.deb.getSchedules=wa(this.getSchedules,500,{leading:!0,trailing:!1})),await this.deb.getSchedules({projectId:r})},async getSchedule({id:r}={}){var i;try{((i=this.schedule)==null?void 0:i.id)!==r&&(this.schedule=null);const s=await vr(`/customer/b/schedule/${r}`,{method:"GET"}),c=s==null?void 0:s.data;return this.schedule=c==null?void 0:c.data,this.schedule}catch(s){console.log(s)}},async debGetSchedule({id:r}={}){return this.deb.getSchedule||(this.deb.getSchedule=wa(this.getSchedule,500,{leading:!0,trailing:!1})),await this.deb.getSchedule({id:r})},async getOrder({id:r}={}){var i;try{((i=this.order)==null?void 0:i.id)!==r&&(this.order=null);const s=await vr(`/customer/b/purchase-order/${r}`,{method:"GET"}),c=s==null?void 0:s.data;return this.order=c==null?void 0:c.data,this.order}catch(s){console.log(s)}},async debGetOrder({id:r}={}){return this.deb.getOrder||(this.deb.getOrder=wa(this.getOrder,500,{leading:!0,trailing:!1})),await this.deb.getOrder({id:r})},async getSOIs({purchaseOrderId:r}={}){try{this.purchaseOrderId!==r&&(this.sois=null);const i=await vr(`/customer/b/purchase-order/sale-order/${r}`,{method:"GET"}),s=i==null?void 0:i.data;return this.sois=s==null?void 0:s.data,this.purchaseOrderId=r,this.sois}catch(i){console.log(i)}},async debSOIs({purchaseOrderId:r}={}){return this.deb.getSOIs||(this.deb.getSOIs=wa(this.getSOIs,500,{leading:!0,trailing:!1})),await this.deb.getSOIs({purchaseOrderId:r})},async getSOIsByProject({projectId:r}={}){var i,s,c,a,m,g,x,T,C,A,P,D,B,R,N;try{r=r||((i=this.project)==null?void 0:i.id);const j=(c=(s=this.project)==null?void 0:s.PurchaseOrders)==null?void 0:c.filter(Z=>!!Z.number&&!Z.isExpired);this.soisProjectId!==r&&(this.soisByProject=null);const U=j==null?void 0:j.map(async Z=>{var Y;const K=await vr(`/customer/b/purchase-order/sale-order/${Z.id}`,{method:"GET"});return(Y=K==null?void 0:K.data)==null?void 0:Y.data}),W=await Promise.all(U),Q={};for(let Z in W)if(W[Z]&&W[Z].length){Q[j[Z].id]=W[Z];for(let K in W[Z]){Q[j[Z].id][K].PurchaseOrder=j[Z];const Y=(m=(a=Q[j[Z].id][K])==null?void 0:a.PurchaseOrderProduct)==null?void 0:m.ReqProduct,me=Y!=null&&Y.specifications?((g=Y==null?void 0:Y.specifications)==null?void 0:g["slump-a"])+" ± "+((x=Y==null?void 0:Y.specifications)==null?void 0:x["slump-b"]):"-",ge=Y!=null&&Y.SKU?((A=(C=(T=Y==null?void 0:Y.SKU)==null?void 0:T.slump)==null?void 0:C.split("-"))==null?void 0:A.pop())+((B=(D=(P=Y==null?void 0:Y.SKU)==null?void 0:P.slumpTolerance)==null?void 0:D.split("-"))==null?void 0:B.pop()):"-";Q[j[Z].id][K].displayName=`${Y==null?void 0:Y.displayName}
67								${(N=(R=Y==null?void 0:Y.Product)==null?void 0:R.Category)==null?void 0:N.name}
68								| 
69                ${Y?ge:me}
70								
71							`}}return this.soisByProject={pos:j.sort((Z,K)=>Z.number<K.number?1:-1),items:Q},console.log({soisByProject:this.soisByProject}),this.soisProjectId=r,this.soisByProject}catch(j){console.log(j)}},async debSOIsByProject({projectId:r}={}){return this.deb.getSOIsByProject||(this.deb.getSOIsByProject=wa(this.getSOIsByProject,500,{leading:!0,trailing:!1})),await this.deb.getSOIsByProject({projectId:r})},async uploadPODocs({poFile:r,ktpFile:i,npwpFile:s,purchaseOrderId:c,purchaseOrderNumber:a}={}){try{const m={},g={};r&&(m.po={photos:r,type:"Purchase_Order",purchaseOrderId:c,purchaseOrderNumber:a}
71),i&&(m.ktp={photos:i,type:"KTP"}),s&&(m.npwp={photos:s,type:"NPWP"});for(let x in m){const T=m[x];if(T){let C=new FormData;for(let A in T)C.append(A,T[A]);g[x]=await vr("/customer/b/customer/upload-docs",{method:"POST",data:C})}}return g}catch(m){console.log(m)}},async uploadCustDocs({poFile:r,ktpFile:i,npwpFile:s,purchaseOrderId:c,purchaseOrderNumber:a,customerId:m}={}){try{const g={},x={};r&&(g.po={photos:r,type:"Purchase_Order",purchaseOrderId:c,purchaseOrderNumber:a}),i&&(g.ktp={photos:i,type:"KTP"}),s&&(g.npwp={photos:s,type:"NPWP"});for(let T in g){const C=g[T];if(C){let A=new FormData;for(let P in C)A.append(P,C[P]);m&&A.append("customerId",m),x[T]=await vr("/customer/b/customer/signup-upload",{method:"POST",data:A})}}return x}catch(g){console.log(g)}},async submitSchedule({date:r,withTechnician:i,consecutive:s,withPump:c,quantity:a,saleOrderId:m,interval:g}={}){var x,T;try{const C={date:r,withTechnician:i,consecutive:s,withPump:c,quantity:Number(a),saleOrderId:m,batchingPlant:(T=(x=n==null?void 0:n.product)==null?void 0:x.bpDistance)==null?void 0:T.name,interval:g};return console.log({payload:C}),await vr("/customer/b/schedule",{method:"POST",data:C})}catch(C){console.log(C)}},async generatePayment({scheduleIds:r,projectId:i}={}){return await vr("/customer/b/webhook/payment-generate",{method:"POST",data:{scheduleIds:r,projectId:i}})},async createProject(r){return await vr("/customer/b/project",{method:"POST",data:r})},async generateSPH(r){return await vr(`/customer/b/quotation/${r}`,{method:"POST"})},async sendOtpReset(r){try{return(await vr("/customer/b/customer/otp-reset-password",{method:"POST",data:r})).data}catch(i){console.log(i)}},async verifyOTP(r){try{return await vr("/customer/b/customer/verify-otp",{method:"POST",data:r})}catch(i){console.log(i)}},async resetPassword(r){try{return await vr("/customer/b/customer/reset-password",{method:"POST",data:r})}catch(i){console.log(i)}},async getBp(){var i;const r=await vr("/common/batching-plant",{method:"GET"});return this.bp=(i=r==null?void 0:r.data)==null?void 0:i.data,r}}})(e,t),ine=(e,t,{stores:n}={})=>Ic("cart",{state:()=>({items:null,hasLoaded:!1}),getters:{getItems:r=>{var a,m,g,x,T;const i=r.items||[],s=(a=n==null?void 0:n.product)==null?void 0:a.bpDistance;let c=[];for(let C=0;C<i.length;C++)if((s==null?void 0:s.id)===((g=(m=i[C])==null?void 0:m.Product)==null?void 0:g.batchingPlantId)){const A=(((x=i[C])==null?void 0:x.price)||0)+(s==null?void 0:s.additionalPrice);c.push({...i[C],price:A,totalPrice:A*((T=i[C])==null?void 0:T.quantity)})}return c},getOrderItems:r=>{var a,m,g,x,T;const i=r.items||[],s=(a=n==null?void 0:n.product)==null?void 0:a.bpDistance;let c=[];for(let C=0;C<i.length;C++)if((s==null?void 0:s.id)===((g=(m=i[C])==null?void 0:m.Product)==null?void 0:g.batchingPlantId)){const A=(((x=i[C])==null?void 0:x.price)||0)+(s==null?void 0:s.additionalPrice);c.push({...i[C],price:A,totalPrice:A*((T=i[C])==null?void 0:T.quantity)})}return c},getTotalPrice(){var i;let r;if((i=this.getItems)!=null&&i.length)for(let s=0;s<(this.getItems||[]).length;s++)r||(r=0),r+=(this.getItems[s].price||0)*this.getItems[s].quantity;return r}},actions:{async loadCartProducts(){try{let r=localStorage.getItem("cartItems"),i=null;try{i=JSON.parse(r||"")}catch{}return this.items=i,this.hasLoaded=!0,i}catch(r){console.log(r)}},async addEditProduct(r,{quantity:i,variant:s,pouringMethod:c,slump:a}={}){var m,g;console.log("addEditProduct",{quantity:i,variant:s,pouringMethod:c,slump:a});try{this.items||(this.items=[]);let x;c=c||"Manual",s=s||"FA",a=a||12;const T=[r.id,a].join("-"),C=(m=this.items)==null?void 0:m.findIndex(A=>(A==null?void 0:A.cartProductId)==T);return console.log({foundIdx:C,items:this.items},C>=0),C>=0?(i==null?this.items[C].quantity+=1:this.items[C].quantity=i,x=this.items[C]):(this.items.push({Product:r,productId:r==null?void 0:r.id,quantity:i||7,slump:a||12,variant:s,pouringMethod:c,name:r==null?void 0:r.displayName,price:(g=r==null?void 0:r.Price)==null?void 0:g.price,cartProductId:T}),x=this.items[this.items.length-1]),localStorage.setItem("cartItems",JSON.stringify(this.items||[])),x}catch(x){console.log(x)}},async removeProduct(r){var i;try{this.items=(i=this.items)==null?void 0:i.filter(s=>(s==null?void 0:s.cartProductId)!=(r==null?void 0:r.cartProductId)),localStorage.setItem("cartItems",JSON.stringify(this.items||[]))}catch(s){console.log(s)}},async createOrder({viaTol:r,picArr:i}){var s,c,a,m,g;try{const x=await vr("/customer/b/quotation",{method:"POST",data:{requestedProducts:this.getOrderItems,viaTol:r,picArr:i,projectId:(c=(s=n==null?void 0:n.main)==null?void 0:s.project)==null?void 0:c.id,batchingPlant:(m=(a=n==null?void 0:n.product)==null?void 0:a.bpDistance)==null?void 0:m.name}});return console.log(x),this.items=[],localStorage.setItem("cartItems",JSON.stringify([])),(g=x==null?void 0:x.data)==null?void 0:g.data}catch(x){console.log(x)}}}})(e,t),one=(e,t,{stores:n}={})=>Ic("product",{state:()=>({items:null,bpDistances:null,bpDistance:null,bpDistanceLatLon:null,search:null,deb:{},productsProjectId:null}),getters:{getItems:r=>
71r.items||[],mergedItemsObj:r=>{var s,c,a;const i={};if(r.items)for(let m=0;m<((s=r.items)==null?void 0:s.length);m++){r.items[m].displayName=="K-BO"&&(r.items[m].displayName="B0");const g=encodeURIComponent((r.items[m].displayName||"").toLowerCase());i[g]||(i[g]={}),i[g][(a=(c=r.items[m])==null?void 0:c.Category)==null?void 0:a.name]={...r.items[m],internalId:g}}return i},mergedItems(){return Object.values(this.mergedItemsObj).sort((r,i)=>(r.NFA||r.FA||{}).displayName>(i.NFA||i.FA||{}).displayName?1:-1)}},actions:{updateSearch(r){this.search=r},async getProducts({lat:r,lon:i}={}){var s,c,a;console.log("getProducts",Date.now());try{if(!this.bpDistance)throw new Error("No BP Distance");const m=await vr("/customer/b/product",{method:"GET",params:{batchingPlant:(s=this.bpDistance)==null?void 0:s.name,projectId:(c=n.route.getRouteParams)==null?void 0:c.projectId,latLng:r&&i?`${r},${i}`:void 0,size:1e4}}),g=m==null?void 0:m.data;return this.items=g.data,console.log({items:this.items}),this.productsProjectId=(a=n.route.getRouteParams)==null?void 0:a.projectId,this.items}catch(m){console.log(m)}},async debGetProducts({lat:r,lon:i}={}){return console.log("debGetProducts",Date.now()),this.deb.getProducts||(this.deb.getProducts=wa(this.getProducts,500,{leading:!0,trailing:!1})),await this.deb.getProducts({lat:r,lon:i})},async getBatchingPlants(r){var i;try{console.log("getBatchingPlants",Date.now());const s=await vr("/customer/b/batching-plant",{method:"GET",params:{projectId:r}}),c=s==null?void 0:s.data;this.bpDistances=c==null?void 0:c.data,this.bpDistance=(i=this.bpDistances)==null?void 0:i[0],console.log({bpDistances:this.bpDistances,bpDistance:this.bpDistance}),this.debGetProducts(),console.log("getBatchingPlants done",Date.now())}catch(s){console.log(s)}},async getBatchingPlantsLatLng({lat:r,lon:i}){var s;try{console.log("getBatchingPlantsLatLng",Date.now());const c=await vr("/customer/b/batching-plant",{method:"GET",params:{lat:r,long:i}}),a=c==null?void 0:c.data;this.bpDistances=a==null?void 0:a.data,this.bpDistance=(s=this.bpDistances)==null?void 0:s[0],this.bpDistanceLatLon={lat:r,lon:i},console.log({bpDistances:this.bpDistances,bpDistance:this.bpDistance}),this.debGetProducts({lat:r,lon:i}),console.log("getBatchingPlantsLatLng done",Date.now())}catch(c){console.log(c)}}}})(e),ane=(e,t,{router:n}={})=>Ic("route",{state:()=>({customerId:null}),getters:{getRouteParams(){var r,i;return(i=(r=n==null?void 0:n.currentRoute)==null?void 0:r.value)==null?void 0:i.params},getCustomerPath(){var r;return`/${(r=this.getRouteParams)==null?void 0:r.customerId}`},getProjectPath(){var r;return`${this.getCustomerPath}/projects/${(r=this.getRouteParams)==null?void 0:r.projectId}`},getSchedulePath(){var r;return`${this.getProjectPath}/schedules/${(r=this.getRouteParams)==null?void 0:r.scheduleId}`},getProductPath(){var r;return`${this.getProjectPath}/orders/new/products/${(r=this.getRouteParams)==null?void 0:r.productId}`}},actions:{}})(e,t),sne=(e,t,{router:n}={})=>Ic("map",{state:()=>({config:Eg(),addressList:[]}),actions:{async getPlaces(r){var i;try{const s=this.config.public.API_BASE_URL,c=await vr(`${s}/common/map/places?search=${r}`,{method:"GET"});return this.addressList=(i=c.data)==null?void 0:i.result,this.addressList}catch(s){console.log(s)}},async getPlaceDetail(r){try{const i=this.config.public.API_BASE_URL;return(await vr(`${i}/common/map/places/${r}`,{method:"GET"})).data.result}catch(i){console.log(i)}},async getPlacesCustomer(r){try{return(await vr(`/customer/b/map/suggestions?search=${r}`,{method:"GET"})).data}catch(i){console.log(i)}},async getPlaceDetailCustomer(r,i,s){try{let c;return r&&(c=`/customer/b/map/geocode?placeId=${r}`),(i||s)&&(c=`/customer/b/map/geocode?lat=${i}&long=${s}`),(await vr(c,{method:"GET"})).data}catch(c){console.log(c)}}}})(e,t),lne=(e,t,{stores:n}={})=>Ic("alert",{state:()=>({alertMessage:null,alertType:null,config:Eg()}),actions:{async updateAlert(r){this.alertMessage=r.message,this.alertType=r.success?"success":"error"}}})(e,t),cne=(e,t)=>Ic("layout",{state:()=>({isDesktop:!1}),actions:{updateIsDesktop(n){this.isDesktop=n}}})(e,t),une=(e,t,{stores:n,strapiApi:r,api:i}={})=>Ic("strapi",{state:()=>
71({mainCategories:null,sMainCategorySlug:null,categories:null,sCategorySlug:null,subcategories:null,sSubcategorySlug:null,deb:{},search:""}),getters:{getSMainCategory(){var s;return this.mainCategories&&((s=this.mainCategories)==null?void 0:s.find(c=>{var a;return((a=c==null?void 0:c.attributes)==null?void 0:a.slug)===this.sMainCategorySlug}))||null},getSCategory(){var s;return this.categories&&((s=this.categories)==null?void 0:s.find(c=>{var a;return((a=c==null?void 0:c.attributes)==null?void 0:a.slug)===this.sCategorySlug}))||null},getSSubcategory(){var s;return console.log(this.subcategories,"this.subcats"),this.subcategories&&((s=this.subcategories)==null?void 0:s.find(c=>{var a;return((a=c==null?void 0:c.attributes)==null?void 0:a.slug)===this.sSubcategorySlug}))||null},getSProduct(){return this.mainCategories&&this.mainCategories.find(s=>{var c;return((c=s==null?void 0:s.attributes)==null?void 0:c.slug)===this.sMainCategorySlug})||null}},actions:{updateSearch(s){this.search=s},async getMainCategories({id:s}={}){console.log("getMainCategories",Date.now());try{const c=await r("/main-categories"+(typeof s<"u"?`/${s}`:""),{method:"GET"}),a=c==null?void 0:c.data;return this.mainCategories=a.data,this.mainCategories}catch(c){console.log(c)}},async debGetMainCategories({id:s}={}){return console.log("debGetMainCategories",Date.now()),this.deb.getMainCategories||(this.deb.getMainCategories=wa(this.getMainCategories,500,{leading:!0,trailing:!1})),await this.deb.getMainCategories({id:s})},async getCategories({id:s,mainCategoryId:c}={}){console.log("getCategories",Date.now());try{const a={};c&&(a["filters[main_category]"]=c);const m=await r("/categories"+(typeof s<"u"?`/${s}`:""),{method:"GET",params:a}),g=m==null?void 0:m.data;return this.categories=g.data,this.categories}catch(a){console.log(a)}},async debGetCategories({id:s,mainCategoryId:c}={}){return console.log("debGetCategories",Date.now()),this.deb.getCategories||(this.deb.getCategories=wa(this.getCategories,500,{leading:!0,trailing:!1})),await this.deb.getCategories({id:s,mainCategoryId:c})},async getSubcategories({id:s,categoryId:c}={}){console.log("getSubCategories",Date.now());try{const a={};c&&(a["filters[category]"]=c);const m=await r("/subcategories"+(typeof s<"u"?`/${s}`:""),{method:"GET",params:a}),g=m==null?void 0:m.data;return this.subcategories=g.data,this.subcategories}catch(a){console.log(a)}},async debGetSubcategories({id:s,categoryId:c}={}){return console.log("debGetSubCategories",Date.now()),this.deb.getSubcategories||(this.deb.getSubcategories=wa(this.getSubcategories,500,{leading:!0,trailing:!1})),await this.deb.getSubcategories({id:s,categoryId:c})},async getMainCategory({slug:s,withCategories:c}={}){var a,m,g,x,T;console.log("getMainCategory",Date.now());try{const C={"filters[slug]":s};c&&(C["populate[0]"]="categories");const A=await r("/main-categories",{method:"GET",params:C}),P=A==null?void 0:A.data;return console.log((a=P==null?void 0:P.data)==null?void 0:a[0],"getMainCategory"),this.categories=(T=(x=(g=(m=P==null?void 0:P.data)==null?void 0:m[0])==null?void 0:g.attributes)==null?void 0:x.categories)==null?void 0:T.data,this.categories}catch(C){console.log(C)}},async debGetMainCategory({slug:s,withCategories:c}={}){return console.log("debGetMainCategory",Date.now()),this.deb.getMainCategory||(this.deb.getMainCategory=wa(this.getMainCategory,500,{leading:!0,trailing:!1})),await this.deb.getMainCategory({slug:s,withCategories:c})},async changeMainCategorySlug(s){return this.sMainCategorySlug=s,await this.debGetMainCategory({slug:s,withCategories:!0})},async getCategory({slug:s,withSubcategories:c}={}){var a,m,g,x,T;console.log("getCategory",Date.now());try{const C={"filters[slug]":s};c&&(C["populate[0]"]="subcategories");const A=await r("/categories",{method:"GET",params:C}),P=A==null?void 0:A.data;return console.log((a=P==null?void 0:P.data)==null?void 0:a[0],"getCategory"),this.subcategories=(T=(x=(g=(m=P==null?void 0:P.data)==null?void 0:m[0])==null?void 0:g.attributes)==null?void 0:x.subcategories)==null?void 0:T.data,this.categories}catch(C){console.log(C)}},async debGetCategory({slug:s,withSubcategories:c}={}){return console.log("debGetCategory",Date.now()),this.deb.getCategory||(this.deb.getCategory=wa(this.getCategory,500,{leading:!0,trailing:!1})),await this.deb.getCategory({slug:s,withSubcategories:c})},async changeCategorySlug(s){return this.sCategorySlug=s,await this.debGetCategory({slug:s,withSubcategories:!0})},async getSubcategory({slug:s,withProducts:c}={}){var a,m,g,x,T;console.log("getSubcategory",Date.now());try{const C={"filters[slug]":s};c&&(C["populate[0]"]="products");const A=await r("/subcategories",{method:"GET",params:C}),P=A==null?void 0:A.data;return console.log((a=P==null?void 0:P.data)==null?void 0:a[0],"getSubcategory"),this.products=(T=(x=(g=(m=P==null?void 0:P.data)==null?void 0:m[0])==null?void 0:g.attributes)==null?void 0:x.products)==null?void 0:T.data,this.products}catch(C){console.log(C)}},async debGetSubcategory({slug:s,withProducts:c}={}){return console.log("debGetSubcategory",Date.now()),this.deb.getSubcategory||(this.deb.getSubcategory=wa(this.getSubcategory,500,{leading:!0,trailing:!1})),await this.deb.getSubcategory({slug:s,withProducts:c})},async changeSubcategorySlug(s){return this.sSubcategorySlug=s,await this.debGetSubcategory({slug:s,withProducts:!0})}}})(e,t),hne=(e,t,{stores:n,strapiApi:r,api:i}={})=>Ic("toko",{state:()=>({selectedCategory:null,selectedCategorySlug:null,selectedCategoryType:null,products:null,productsMeta:null,deb:{},search:""}),getters:{getChildCategories(){var s,c,a,m,g,x;return this.selectedCategoryType=="category"?((a=(c=(s=this.selectedCategory)==null?void 0:s.attributes)==null?void 0:c.subcategories)==null?void 0:a.data)||[]:this.selectedCategoryType=="mainCategory"?((x=(g=(m=this.selectedCategory)==null?void 0:m.attributes)==null?void 0:g.categories)==null?void 0:x.data)||[]:[]},getBreadcrumbs(){var m,g,x,T,C,A;const s=[];let c=((m=this.selectedCategory)==null?void 0:m.attributes)||{};for(s.push({name:c==null?void 0:c.name,slug:c==null?void 0:c.slug});c!=null&&c.category||c!=null&&c.main_category;)c=((x=(g=c==null?void 0:c.category)==null?void 0:g.data)==null?void 0:x.attributes)||((C=(T=c==null?void 0:c.main_category)==null?void 0:T.data)==null?void 0:C.attributes)||{},s.push({name:c==null?void 0:c.name,slug:c==null?void 0:c.slug});s.reverse();let a="";s.unshift({name:"Semua Produk",slug:"products"});for(let P in s)a+=`/${(A=s[P])==null?void 0:A.slug}`,s[P]={...s[P],to:a,title:s[P].name,disabled:!1};return s[s.length-1].disabled=!0,s}},actions:{updateSearch(s){this.search=s},async getCategory({categoryType:s,slug:c,withParents:a,withProducts:m,withChildren:g}={}){var x,T,C,A,P,D;try{if(!s)throw new Error("categoryType Required!");m&&(this.products=null),this.selectedCategory=null,this.selectedCategorySlug=null,this.selectedCategoryType=null;const B={"filters[slug]":c};a&&(s=="subcategory"?B["populate[category][populate][0]"]="main_category":s=="category"&&(B["populate[0]"]="main_category")),g&&(s=="mainCategory"?B["populate[1]"]="categories":s=="category"&&(B["populate[1]"]="subcategories")),console.log(B);let R="main-categories";s=="category"?R="categories":s=="subcategory"&&(R="subcategories");const N=await r(R,{method:"GET",params:B}),j=N==null?void 0:N.data;return this.selectedCategory=(x=j==null?void 0:j.data)==null?void 0:x[0],this.selectedCategorySlug=c,this.selectedCategoryType=s,this.products=((A=(C=(T=this.selectedCategory)==null?void 0:T.attributes)==null?void 0:C.products)==null?void 0:A.data)||this.products,(D=(P=this.selectedCategory)==null?void 0:P.attributes)==null||delete D.products,m&&this.getProducts(),this.selectedCategory}catch(B){console.log(B)}},async getProducts(){var s,c,a;try{this.products=null,this.productsMeta=null;const m={};this.selectedCategoryType=="subcategory"?m["filters[subcategory]"]=(s=this.selectedCategory)==null?void 0:s.id:this.selectedCategoryType=="category"?m["filters[category]"]=(c=this.selectedCategory)==null?void 0:c.id:this.selectedCategoryType=="mainCategory"&&(m["filters[main_category]"]=(a=this.selectedCategory)==null?void 0:a.id);const g=await r("/products",{method:"GET",params:m}),x=g==null?void 0:g.data;return this.products=x==null?void 0:x.data,this.productsMeta=x==null?void 0:x.meta,console.log(this.products,"this.products"),this.products}catch(m){console.log(m)}},async getMoreProducts(){var s,c,a,m,g;try{console.log(this.productsMeta,"this.productsMeta");const x={"pagination[page]":(((c=(s=this.productsMeta)==null?void 0:s.pagination)==null?void 0:c.page)||0)+1};this.selectedCategoryType=="subcategory"?x["filters[subcategory]"]=(a=this.selectedCategory)==null?void 0:a.id:this.selectedCategoryType=="category"?x["filters[category]"]=(m=this.selectedCategory)==null?void 0:m.id:this.selectedCategoryType=="mainCategory"&&(x["filters[main_category]"]=(g=this.selectedCategory)==null?void 0:g.id);const T=await r("/products",{method:"GET",params:x}),C=T==null?void 0:T.data;return this.products=[...this.products||[],...(C==null?void 0:C.data)||[]],this.productsMeta=C==null?void 0:C.meta,C==null?void 0:C.meta}catch(x){console.log(x)}},async debGetMoreProducts(){return this.deb.getMoreProducts||(this.deb.getMoreProducts=wa(this.getMoreProducts,500,{leading:!0,trailing:!1})),await this.deb.getMoreProducts()},async searchProducts({search:s,pageSize:c}={search:""}){try{this.products=null,this.productsMeta=null,this.search=s;const a={populate:"*","pagination[page]":1,"pagination[pageSize]":c||25,"filters[$or][0][keywords][$containsi]":this.search,"sort[0]":"keywords","filters[$or][1][name][$containsi]":this.search,"filters[$or][3][short_name][$containsi]":this.search,"filters[$or][6][subcategory][name][$containsi]":this.search},m=await r("/products",{method:"GET",params:a}),g=m==null?void 0:m.data;return this.products=g==null?void 0:g.data,this.productsMeta=g==null?void 0:g.meta,this.products}catch(a){console.log(a)}},async getMoreSearchProducts(){var s,c,a,m;try{console.log(this.productsMeta,"this.productsMeta");const g={"pagination[page]":(((c=(s=this.productsMeta)==null?void 0:s.pagination)==null?void 0:c.page)||0)+1,"pagination[pageSize]":((m=(a=this.productsMeta)==null?void 0:a.pagination)==null?void 0:m.pageSize)||25,populate:"*","filters[$or][0][keywords][$containsi]":this.search,"sort[0]":"keywords","filters[$or][1][name][$containsi]":this.search,"filters[$or][3][short_name][$containsi]":this.search,"filters[$or][6][subcategory][name][$containsi]":this.search},x=await r("/products",{method:"GET",params:g}),T=x==null?void 0:x.data;return this.products=[...this.products||[],...(T==null?void 0:T.data)||[]],this.productsMeta=T==null?void 0:T.meta,T==null?void 0:T.meta}catch(g){console.log(g)}},async debGetMoreSearchProducts(){return this.deb.getMoreSearchProducts||(this.deb.getMoreSearchProducts=wa(this.getMoreSearchProducts,500,{leading:!0,trailing:!1})),await this.deb.getMoreSearchProducts()},async debGetCategory({categoryType:s,slug:c,withParents:a,withProducts:m,withChildren:g}={}){return this.deb.getCategory||(this.deb.getCategory=wa(this.getCategory,500,{leading:!0,trailing:!1})),await this.deb.getCategory({categoryType:s,slug:c,withParents:a,withProducts:m,withChildren:g})}}})(e,t),dne=Ic("invoice",{state(){return{invoices:[],inoviceMeta:{currentPage:0,totalItems:1,totalPages:1},transactions:[],transactionMeta:{currentPage:0,totalItems:1,totalPages:1},payments:[],paymentMeta:{currentPage:0,totalItems:1,totalPages:1}}},actions:{merge(e,t,n){return e.filter(r=>!t.find(i=>r[n]===i[n])).concat(t)},async getInvoiceByProjectId(e,t){var n,r;try{const{data:i}=await vr({method:"GET",url:`customer/b/invoice/project/${e}`,params:{page:(t==null?void 0:t.page)||1,size:(t==null?void 0:t.size)||10,status:t==null?void 0:t.status}});return console.log(i,"datainvoiceeeee"),this.invoices=this.invoices.concat((n=i.data)==null?void 0:n.data),this.inoviceMeta=(r=i.data)==null?void 0:r.meta,i.data}catch(i){console.log(i,"error getInvoiceByProjectId")}},async getTransactionByCustomerId(e,t){var n,r;try{const{data:i}=await vr({method:"GET",url:`customer/b/transaction/customer/${e}`,params:{page:(t==null?void 0:t.page)||1,size:(t==null?void 0:t.size)||10,status:t==null?void 0:t.status,startDate:t==null?void 0:t.startDate,endD
71ate:t==null?void 0:t.endDate}});return this.transactions=(n=i.data)==null?void 0:n.data,this.transactionMeta=(r=i.data)==null?void 0:r.meta,i.data}catch(i){console.log(i,"error getTransactionByCustomerId")}},async getInvoiceById(e){try{const{data:t}=await vr({method:"GET",url:`customer/b/invoice/${e}`});return console.log(t,"datainvoiceeeee"),t.data}catch(t){console.log(t,"error getInvoiceByProjectId")}},async getPaymentsByCustomerId(e,t){var n,r;try{const{data:i}=await vr({method:"GET",url:`customer/b/payment/customer/${e}`,params:{page:(t==null?void 0:t.page)||1,size:(t==null?void 0:t.size)||10,status:t==null?void 0:t.status}});return this.payments=this.payments.concat((n=i.data)==null?void 0:n.data),this.paymentMeta=(r=i.data)==null?void 0:r.meta,i.data}catch(i){console.log(i,"error getInvoiceByProjectId")}},async getPaymentById(e){try{const{data:t}=await vr({method:"GET",url:`customer/b/payment/${e}`});return console.log(t,"data payment detail"),t.data}catch(t){console.log(t,"error getInvoiceByProjectId")}}}}),fL={main:rne,user:ete,cart:ine,product:one,route:ane,map:sne,alert:lne,layout:cne,strapi:une,toko:hne,invoice:dne},fne=Gi(e=>{e.$pinia.router=xv(e.$router);const t={},n=fL;for(let r in fL)t[r]=n[r](e.$pinia,!1,{router:e.$router,stores:t,config:e.$config,api:e.$api,strapiApi:e.$strapiApi});return{provide:{stores:t}}});/**
72 *  Copyright 2021 Thorsten Luenborg 
73 *  @license MIT
74 */const pN=Symbol("wormhole");function mN(){const e=dr(pN);if(!e)throw new Error(`
75    [portal-vue]: Necessary Injection not found. Make sur you installed the plugin properly.`);return e}const gN=typeof window<"u";var pne=sr({compatConfig:{MODE:3},name:"portal",props:{disabled:{type:Boolean},name:{type:[String,Symbol],default:()=>Symbol()},order:{type:Number},slotProps:{type:Object,default:()=>({})},to:{type:String,default:()=>String(Math.round(1e7*Math.random()))}},setup:(e,{slots:t})=>(function(n,r){const i=mN();function s(){if(!gN)return;const{to:a,name:m,order:g}=n;r.default?i.open({to:a,from:m,order:g,content:r.default}):c()}function c(a){i.close({to:a??n.to,from:n.name})}Dr(()=>{n.disabled||s()}),Yx(()=>{n.disabled?c():s()}),xp(()=>{c()}),Nn(()=>n.to,(a,m)=>{n.disabled||(m&&m!==a&&c(m),s())})}(e,t),()=>e.disabled&&t.default?t.default(e.slotProps):null)});const mne=(e,{slots:t})=>{var n;return(n=t.default)===null||n===void 0?void 0:n.call(t)};var gne=sr({compatConfig:{MODE:3},name:"portalTarget",props:{multiple:{type:Boolean,default:!1},name:{type:String,required:!0},slotProps:{type:Object,default:()=>({})}},emits:["change"],setup(e,{emit:t,slots:n}){const r=mN(),i=yt(()=>{const s=r.getContentForTarget(e.name,e.multiple),c=n.wrapper,a=s.map(g=>g.content(e.slotProps)),m=c?a.flatMap(g=>g.length?c(g):[]):a.flat(1);return{vnodes:m,vnodesFn:()=>m}});return Nn(i,({vnodes:s})=>{const c=s.length>0,a=r.transports.get(e.name),m=a?[...a.keys()]:[];t("change",{hasContent:c,sources:m})},{flush:"post"}),()=>{var s;return i.value.vnodes.length?[ao("div",{style:"display: none",key:"__portal-vue-hacky-scoped-slot-repair__"}),ao(mne,i.value.vnodesFn)]:(s=n.default)===null||s===void 0?void 0:s.call(n)}}});function yne(e=!0){const t=so(new Map),n={open:function(r){if(!gN)return;const{to:i,from:s,content:c,order:a=1/0}=r;if(!i||!s||!c)return;t.has(i)||t.set(i,new Map);const m={to:i,from:s,content:c,order:a};t.get(i).set(s,m)},close:function(r){const{to:i,from:s}=r;if(!i||!s)return;const c=t.get(i);c&&(c.delete(s),c.size||t.delete(i))},transports:t,getContentForTarget:function(r,i){const s=t.get(r);if(!s)return[];const c=Array.from((s==null?void 0:s.values())||[]);return i?(a=(m,g)=>m.order-g.order,c.map((m,g)=>[g,m]).sort(function(m,g){return a(m[1],g[1])||m[0]-g[0]}).map(m=>m[1])):[c.pop()];var a}};return e?bv(n):n}const _ne=yne();function vne(e,t={}){var n;t.portalName!==!1&&e.component(t.portalName||"Portal",pne),t.portalTargetName!==!1&&e.component(t.portalTargetName||"PortalTarget",gne);const r=(n=t.wormhole)!==null&&n!==void 0?n:_ne;e.provide(pN,r)}const bne=Gi(e=>{e.vueApp.use(vne)});var yN={exports:{}};/*!
76 * ScrollMagic v2.0.8 (2020-08-14)
77 * The javascript library for magical scroll interactions.
78 * (c) 2020 Jan Paepke (@janpaepke)
79 * Project Website: http://scrollmagic.io
80 * 
81 * @version 2.0.8
82 * @license Dual licensed under MIT license and GPL.
83 * @author Jan Paepke - [email protected]
84 *
85 * @file ScrollMagic main library.
86 */(function(e,t){(function(n,r){e.exports=r()})(oo,function(){var n=function(){c.log(2,"(COMPATIBILITY NOTICE) -> As of ScrollMagic 2.0.0 you need to use 'new ScrollMagic.Controller()' to create a new controller instance. Use 'new ScrollMagic.Scene()' to instance a scene.")};n.version="2.0.8",typeof window<"u"&&window.addEventListener("mousewheel",void 0);var r="data-scrollmagic-pin-spacer";n.Controller=function(a){var m="ScrollMagic.Controller",g="FORWARD",x="REVERSE",T="PAUSED",C=i.defaults,A=this,P=c.extend({},C,a),D=[],B=!1,R=0,N=T,j=!0,U=0,W=!0,Q,Z,K=function(){for(var le in P)C.hasOwnProperty(le)||(oe(2,'WARNING: Unknown option "'+le+'"'),delete P[le]);if(P.container=c.get.elements(P.container)[0],!P.container)throw oe(1,"ERROR creating object "+m+": No valid scroll container supplied"),m+" init failed.";j=P.container===window||P.container===document.body||!document.body.contains(P.container),j&&(P.container=window),U=ge(),P.container.addEventListener("resize",xe),P.container.addEventListener("scroll",xe);var se=parseInt(P.refreshInterval,10);P.refreshInterval=c.type.Number(se)?se:C.refreshInterval,Y(),oe(3,"added new "+m+" controller (v"+n.version+")")},Y=function(){P.refreshInterval>0&&(Z=window.setTimeout(Te,P.refreshInterval))},me=function(){return P.vertical?c.get.scrollTop(P.container):c.get.scrollLeft(P.container)},ge=function(){return P.vertical?c.get.height(P.container):c.get.width(P.container)},ce=this._setScrollPos=function(le){P.vertical?j?window.scrollTo(c.get.scrollLeft(),le):P.container.scrollTop=le:j?window.scrollTo(le,c.get.scrollTop()):P.container.scrollLeft=le},fe=function(){if(W&&B){var le=c.type.Array(B)?B:D.slice(0);B=!1;var se=R;R=A.scrollPos();var Ne=R-se;Ne!==0&&(N=Ne>0?g:x),N===x&&le.reverse(),le.forEach(function(Se,xt){oe(3,"updating Scene "+(xt+1)+"/"+le.length+" ("+D.length+" total)"),Se.update(!0)}),le.length===0&&P.loglevel>=3&&oe(3,"updating 0 Scenes (nothing added to controller)")}},ie=function(){Q=c.rAF(fe)},xe=function(le){oe(3,"event fired causing an update:",le.type),le.type=="resize"&&(U=ge(),N=T),B!==!0&&(B=!0,ie())},Te=function(){if(!j&&U!=ge()){var le;try{le=new Event("resize",{bubbles:!1,cancelable:!1})}catch{le=document.createEvent("Event"),le.initEvent("resize",!1,!1)}
86P.container.dispatchEvent(le)}D.forEach(function(se,Ne){se.refresh()}),Y()},oe=this._log=function(le,se){P.loglevel>=le&&(Array.prototype.splice.call(arguments,1,0,"("+m+") ->"),c.log.apply(window,arguments))};this._options=P;var ne=function(le){if(le.length<=1)return le;var se=le.slice(0);return se.sort(function(Ne,Se){return Ne.scrollOffset()>Se.scrollOffset()?1:-1}),se};return this.addScene=function(le){if(c.type.Array(le))le.forEach(function(Ne,Se){A.addScene(Ne)});else if(le instanceof n.Scene){if(le.controller()!==A)le.addTo(A);else if(D.indexOf(le)<0){D.push(le),D=ne(D),le.on("shift.controller_sort",function(){D=ne(D)});for(var se in P.globalSceneOptions)le[se]&&le[se].call(le,P.globalSceneOptions[se]);oe(3,"adding Scene (now "+D.length+" total)")}}else oe(1,"ERROR: invalid argument supplied for '.addScene()'");return A},this.removeScene=function(le){if(c.type.Array(le))le.forEach(function(Ne,Se){A.removeScene(Ne)});else{var se=D.indexOf(le);se>-1&&(le.off("shift.controller_sort"),D.splice(se,1),oe(3,"removing Scene (now "+D.length+" left)"),le.remove())}return A},this.updateScene=function(le,se){return c.type.Array(le)?le.forEach(function(Ne,Se){A.updateScene(Ne,se)}):se?le.update(!0):B!==!0&&le instanceof n.Scene&&(B=B||[],B.indexOf(le)==-1&&B.push(le),B=ne(B),ie()),A},this.update=function(le){return xe({type:"resize"}),le&&fe(),A},this.scrollTo=function(le,se){if(c.type.Number(le))ce.call(P.container,le,se);else if(le instanceof n.Scene)le.controller()===A?A.scrollTo(le.scrollOffset(),se):oe(2,"scrollTo(): The supplied scene does not belong to this controller. Scroll cancelled.",le);else if(c.type.Function(le))ce=le;else{var Ne=c.get.elements(le)[0];if(Ne){for(;Ne.parentNode.hasAttribute(r);)Ne=Ne.parentNode;var Se=P.vertical?"top":"left",xt=c.get.offset(P.container),kt=c.get.offset(Ne);j||(xt[Se]-=A.scrollPos()),A.scrollTo(kt[Se]-xt[Se],se)}else oe(2,"scrollTo(): The supplied argument is invalid. Scroll cancelled.",le)}return A},this.scrollPos=function(le){if(arguments.length)c.type.Function(le)?me=le:oe(2,"Provided value for method 'scrollPos' is not a function. To change the current scroll position use 'scrollTo()'.");else return me.call(A);return A},this.info=function(le){var se={size:U,vertical:P.vertical,scrollPos:R,scrollDirection:N,container:P.container,isDocument:j};if(arguments.length){if(se[le]!==void 0)return se[le];oe(1,'ERROR: option "'+le+'" is not available');return}else return se},this.loglevel=function(le){if(arguments.length)P.loglevel!=le&&(P.loglevel=le);else return P.loglevel;return A},this.enabled=function(le){if(arguments.length)W!=le&&(W=!!le,A.updateScene(D,!0));else return W;return A},this.destroy=function(le){window.clearTimeout(Z);for(var se=D.length;se--;)D[se].destroy(le);return P.container.removeEventListener("resize",xe),P.container.removeEventListener("scroll",xe),c.cAF(Q),oe(3,"destroyed "+m+" (reset: "+(le?"true":"false")+")"),null},K(),A};var i={defaults:{container:window,vertical:!0,globalSceneOptions:{},loglevel:2,refreshInterval:100}};n.Controller.addOption=function(a,m){i.defaults[a]=m},n.Controller.extend=function(a){var m=this;n.Controller=function(){return m.apply(this,arguments),this.$super=c.extend({},this),a.apply(this,arguments)||this},c.extend(n.Controller,m),n.Controller.prototype=m.prototype,n.Controller.prototype.constructor=n.Controller},n.Scene=function(a){var m="ScrollMagic.Scene",g="BEFORE",x="DURING",T="AFTER",C=s.defaults,A=this,P=c.extend({},C,a),D=g,B=0,R={start:0,end:0},N=0,j=!0,U,W,Q=function(){for(var Ue in P)C.hasOwnProperty(Ue)||(K(2,'WARNING: Unknown option "'+Ue+'"'),delete P[Ue]);for(var je in C)Te(je);ie()},Z={};this.on=function(Ue,je){return c.type.Function(je)?(Ue=Ue.trim().split(" "),Ue.forEach(function(st){var tt=st.split("."),Me=tt[0],lt=tt[1];Me!="*"&&(Z[Me]||(Z[Me]=[]),Z[Me].push({namespace:lt||"",callback:je}))})):K(1,"ERROR when calling '.on()': Supplied callback for '"+Ue+"' is not a valid function!"),A},this.off=function(Ue,je){return Ue?(Ue=Ue.trim().split(" "),Ue.forEach(function(st,tt){var Me=st.split("."),lt=Me[0],Ae=Me[1]||"",we=lt==="*"?Object.keys(Z):[lt];we.forEach(function(Je){for(var ct=Z[Je]||[],mt=ct.length;mt--;){var Vt=ct[mt];Vt&&(Ae===Vt.namespace||Ae==="*")&&(!je||je==Vt.callback)&&ct.splice(mt,1)}ct.length||delete Z[Je]})}),A):(K(1,"ERROR: Invalid event name supplied."),A)},this.trigger=function(Ue,je){if(Ue){var st=Ue.trim().split("."),tt=st[0],Me=st[1],lt=Z[tt];K(3,"event fired:",tt,je?"->":"",je||""),lt&&lt.forEach(function(Ae,we){(!Me||Me===Ae.namespace)&&Ae.callback.call(A,new n.Event(tt,Ae.namespace,A,je))})}
86else K(1,"ERROR: Invalid event name supplied.");return A},A.on("change.internal",function(Ue){Ue.what!=="loglevel"&&Ue.what!=="tweenChanges"&&(Ue.what==="triggerElement"?ge():Ue.what==="reverse"&&A.update())}).on("shift.internal",function(Ue){Y(),A.update()});var K=this._log=function(Ue,je){P.loglevel>=Ue&&(Array.prototype.splice.call(arguments,1,0,"("+m+") ->"),c.log.apply(window,arguments))};this.addTo=function(Ue){return Ue instanceof n.Controller?W!=Ue&&(W&&W.removeScene(A),W=Ue,ie(),me(!0),ge(!0),Y(),W.info("container").addEventListener("resize",ce),Ue.addScene(A),A.trigger("add",{controller:W}),K(3,"added "+m+" to controller"),A.update()):K(1,"ERROR: supplied argument of 'addTo()' is not a valid ScrollMagic Controller"),A},this.enabled=function(Ue){if(arguments.length)j!=Ue&&(j=!!Ue,A.update(!0));else return j;return A},this.remove=function(){if(W){W.info("container").removeEventListener("resize",ce);var Ue=W;W=void 0,Ue.removeScene(A),A.trigger("remove"),K(3,"removed "+m+" from controller")}return A},this.destroy=function(Ue){return A.trigger("destroy",{reset:Ue}),A.remove(),A.off("*.*"),K(3,"destroyed "+m+" (reset: "+(Ue?"true":"false")+")"),null},this.update=function(Ue){if(W)if(Ue)if(W.enabled()&&j){var je=W.info("scrollPos"),st;P.duration>0?st=(je-R.start)/(R.end-R.start):st=je>=R.start?1:0,A.trigger("update",{startPos:R.start,endPos:R.end,scrollPos:je}),A.progress(st)}else oe&&D===x&&le(!0);else W.updateScene(A,!1);return A},this.refresh=function(){return me(),ge(),A},this.progress=function(Ue){if(arguments.length){var je=!1,st=D,tt=W?W.info("scrollDirection"):"PAUSED",Me=P.reverse||Ue>=B;if(P.duration===0?(je=B!=Ue,B=Ue<1&&Me?0:1,D=B===0?g:x):Ue<0&&D!==g&&Me?(B=0,D=g,je=!0):Ue>=0&&Ue<1&&Me?(B=Ue,D=x,je=!0):Ue>=1&&D!==T?(B=1,D=T,je=!0):D===x&&!Me&&le(),je){var lt={progress:B,state:D,scrollDirection:tt},Ae=D!=st,we=function(Je){A.trigger(Je,lt)};Ae&&st!==x&&(we("enter"),we(st===g?"start":"end")),we("progress"),Ae&&D!==x&&(we(D===g?"start":"end"),we("leave"))}return A}else return B};var Y=function(){R={start:N+P.offset},W&&P.triggerElement&&(R.start-=W.info("size")*P.triggerHook),R.end=R.start+P.duration},me=function(Ue){if(U){var je="duration";xe(je,U.call(A))&&!Ue&&(A.trigger("change",{what:je,newval:P[je]}),A.trigger("shift",{reason:je}))}},ge=function(Ue){var je=0,st=P.triggerElement;if(W&&(st||N>0)){if(st)if(st.parentNode){for(var tt=W.info(),Me=c.get.offset(tt.container),lt=tt.vertical?"top":"left";st.parentNode.hasAttribute(r);)st=st.parentNode;var Ae=c.get.offset(st);tt.isDocument||(Me[lt]-=W.scrollPos()),je=Ae[lt]-Me[lt]}else K(2,"WARNING: triggerElement was removed from DOM and will be reset to",void 0),A.triggerElement(void 0);var we=je!=N;N=je,we&&!Ue&&A.trigger("shift",{reason:"triggerElementPosition"})}},ce=function(Ue){P.triggerHook>0&&A.trigger("shift",{reason:"containerResize"})},fe=c.extend(s.validate,{duration:function(Ue){if(c.type.String(Ue)&&Ue.match(/^(\.|\d)*\d+%$/)){var je=parseFloat(Ue)/100;Ue=function(){return W?W.info("size")*je:0}}if(c.type.Function(Ue)){U=Ue;try{Ue=parseFloat(U.call(A))}catch{Ue=-1}}if(Ue=parseFloat(Ue),!c.type.Number(Ue)||Ue<0)throw U?(U=void 0,['Invalid return value of supplied function for option "duration":',Ue]):['Invalid value for option "duration":',Ue];return Ue}}),ie=function(Ue){Ue=arguments.length?[Ue]:Object.keys(fe),Ue.forEach(function(je,st){var tt;if(fe[je])try{tt=fe[je](P[je])}catch(lt){tt=C[je];var Me=c.type.String(lt)?[lt]:lt;c.type.Array(Me)?(Me[0]="ERROR: "+Me[0],Me.unshift(1),K.apply(this,Me)):K(1,"ERROR: Problem executing validation callback for option '"+je+"':",lt.message)}finally{P[je]=tt}})},xe=function(Ue,je){var st=!1,tt=P[Ue];return P[Ue]!=je&&(P[Ue]=je,ie(Ue),st=tt!=P[Ue]),st},Te=function(Ue){A[Ue]||(A[Ue]=function(je){if(arguments.length)Ue==="duration"&&(U=void 0),xe(Ue,je)&&(A.trigger("change",{what:Ue,newval:P[Ue]}),s.shifts.indexOf(Ue)>-1&&A.trigger("shift",{reason:Ue}));else return P[Ue];return A})};this.controller=function(){return W},this.state=function(){return D},this.scrollOffset=function(){return R.start},this.triggerPosition=function(){var Ue=P.offset;return W&&(P.triggerElement?Ue+=N:Ue+=W.info("size")*A.triggerHook()),Ue};var oe,ne;A.on("shift.internal",function(Ue){var je=Ue.reason==="duration";(D===T&&je||D===x&&P.duration===0)&&le(),je&&se()}
86).on("progress.internal",function(Ue){le()}).on("add.internal",function(Ue){se()}).on("destroy.internal",function(Ue){A.removePin(Ue.reset)});var le=function(Ue){if(oe&&W){var je=W.info(),st=ne.spacer.firstChild;if(!Ue&&D===x){c.css(st,"position")!="fixed"&&(c.css(st,{position:"fixed"}),se());var tt=c.get.offset(ne.spacer,!0),Me=P.reverse||P.duration===0?je.scrollPos-R.start:Math.round(B*P.duration*10)/10;tt[je.vertical?"top":"left"]+=Me,c.css(ne.spacer.firstChild,{top:tt.top,left:tt.left})}else{var lt={position:ne.inFlow?"relative":"absolute",top:0,left:0},Ae=c.css(st,"position")!=lt.position;ne.pushFollowers?P.duration>0&&(D===T&&parseFloat(c.css(ne.spacer,"padding-top"))===0||D===g&&parseFloat(c.css(ne.spacer,"padding-bottom"))===0)&&(Ae=!0):lt[je.vertical?"top":"left"]=P.duration*B,c.css(st,lt),Ae&&se()}}},se=function(){if(oe&&W&&ne.inFlow){var Ue=D===x,je=W.info("vertical"),st=ne.spacer.firstChild,tt=c.isMarginCollapseType(c.css(ne.spacer,"display")),Me={};ne.relSize.width||ne.relSize.autoFullWidth?Ue?c.css(oe,{width:c.get.width(ne.spacer)}):c.css(oe,{width:"100%"}):(Me["min-width"]=c.get.width(je?oe:st,!0,!0),Me.width=Ue?Me["min-width"]:"auto"),ne.relSize.height?Ue?c.css(oe,{height:c.get.height(ne.spacer)-(ne.pushFollowers?P.duration:0)}):c.css(oe,{height:"100%"}):(Me["min-height"]=c.get.height(je?st:oe,!0,!tt),Me.height=Ue?Me["min-height"]:"auto"),ne.pushFollowers&&(Me["padding"+(je?"Top":"Left")]=P.duration*B,Me["padding"+(je?"Bottom":"Right")]=P.duration*(1-B)),c.css(ne.spacer,Me)}},Ne=function(){W&&oe&&D===x&&!W.info("isDocument")&&le()},Se=function(){W&&oe&&D===x&&((ne.relSize.width||ne.relSize.autoFullWidth)&&c.get.width(window)!=c.get.width(ne.spacer.parentNode)||ne.relSize.height&&c.get.height(window)!=c.get.height(ne.spacer.parentNode))&&se()},xt=function(Ue){W&&oe&&D===x&&!W.info("isDocument")&&(Ue.preventDefault(),W._setScrollPos(W.info("scrollPos")-((Ue.wheelDelta||Ue[W.info("vertical")?"wheelDeltaY":"wheelDeltaX"])/3||-Ue.detail*30)))};this.setPin=function(Ue,je){var st={pushFollowers:!0,spacerClass:"scrollmagic-pin-spacer"},tt=je&&je.hasOwnProperty("pushFollowers");if(je=c.extend({},st,je),Ue=c.get.elements(Ue)[0],Ue){if(c.css(Ue,"position")==="fixed")return K(1,"ERROR calling method 'setPin()': Pin does not work with elements that are positioned 'fixed'."),A}else return K(1,"ERROR calling method 'setPin()': Invalid pin element supplied."),A;if(oe){if(oe===Ue)return A;A.removePin()}oe=Ue;var Me=oe.parentNode.style.display,lt=["top","left","bottom","right","margin","marginLeft","marginRight","marginTop","marginBottom"];oe.parentNode.style.display="none";var Ae=c.css(oe,"position")!="absolute",we=c.css(oe,lt.concat(["display"])),Je=c.css(oe,["width","height"]);oe.parentNode.style.display=Me,!Ae&&je.pushFollowers&&(K(2,"WARNING: If the pinned element is positioned absolutely pushFollowers will be disabled."),je.pushFollowers=!1),window.setTimeout(function(){oe&&P.duration===0&&tt&&je.pushFollowers&&K(2,"WARNING: pushFollowers =",!0,"has no effect, when scene duration is 0.")},0);var ct=oe.parentNode.insertBefore(document.createElement("div"),oe),mt=c.extend(we,{position:Ae?"relative":"absolute",boxSizing:"content-box",mozBoxSizing:"content-box",webkitBoxSizing:"content-box"});if(Ae||c.extend(mt,c.css(oe,["width","height"])),c.css(ct,mt),ct.setAttribute(r,""),c.addClass(ct,je.spacerClass),ne={spacer:ct,relSize:{width:Je.width.slice(-1)==="%",height:Je.height.slice(-1)==="%",autoFullWidth:Je.width==="auto"&&Ae&&c.isMarginCollapseType(we.display)},pushFollowers:je.pushFollowers,inFlow:Ae},!oe.___origStyle){oe.___origStyle={};var Vt=oe.style,Ie=lt.concat(["width","height","position","boxSizing","mozBoxSizing","webkitBoxSizing"]);Ie.forEach(function(Pe){oe.___origStyle[Pe]=Vt[Pe]||""})}return ne.relSize.width&&c.css(ct,{width:Je.width}),ne.relSize.height&&c.css(ct,{height:Je.height}),ct.appendChild(oe),c.css(oe,{position:Ae?"relative":"absolute",margin:"auto",top:"auto",left:"auto",bottom:"auto",right:"auto"}),(ne.relSize.width||ne.relSize.autoFullWidth)&&c.css(oe,{boxSizing:"border-box",mozBoxSizing:"border-box",webkitBoxSizing:"border-box"}),window.addEventListener("scroll",Ne),window.addEventListener("resize",Ne),window.addEventListener("resize",Se),oe.addEventListener("mousewheel",xt),oe.addEventListener("DOMMouseScroll",xt),K(3,"added pin"),le(),A},this.removePin=function(Ue){if(oe){if(D===x&&le(!0),Ue||!W){var je=ne.spacer.firstChild;if(je.hasAttribute(r)){var st=ne.spacer.style,tt=["margin","marginLeft","marginRight","marginTop","marginBottom"],Me={};tt.forEach(function(lt){Me[lt]=st[lt]||""}),c.css(je,Me)}ne.spacer.parentNode.insertBefore(je,ne.spacer),ne.spacer.parentNode.removeChild(ne.spacer),oe.parentNode.hasAttribute(r)||(c.css(oe,oe.___origStyle),delete oe.___origStyle)}window.removeEventListener("scroll",Ne),window.removeEventListener("resize",Ne),window.removeEventListener("resize",Se),oe.removeEventListener("mousewheel",xt),oe.removeEventListener("DOMMouseScroll",xt),oe=void 0,K(3,"removed pin (reset: "+(Ue?"true":"false")+")")}return A};var kt,wt=[];return A.on("destroy.internal",function(Ue){A.removeClassToggle(Ue.reset)}),this.setClassToggle=function(Ue,je){var st=c.get.elements(Ue);return st.length===0||!c.type.String(je)?(K(1,"ERROR calling method 'setClassToggle(
86)': Invalid "+(st.length===0?"element":"classes")+" supplied."),A):(wt.length>0&&A.removeClassToggle(),kt=je,wt=st,A.on("enter.internal_class leave.internal_class",function(tt){var Me=tt.type==="enter"?c.addClass:c.removeClass;wt.forEach(function(lt,Ae){Me(lt,kt)})}),A)},this.removeClassToggle=function(Ue){return Ue&&wt.forEach(function(je,st){c.removeClass(je,kt)}),A.off("start.internal_class end.internal_class"),kt=void 0,wt=[],A},Q(),A};var s={defaults:{duration:0,offset:0,triggerElement:void 0,triggerHook:.5,reverse:!0,loglevel:2},validate:{offset:function(a){if(a=parseFloat(a),!c.type.Number(a))throw['Invalid value for option "offset":',a];return a},triggerElement:function(a){if(a=a||void 0,a){var m=c.get.elements(a)[0];if(m&&m.parentNode)a=m;else throw['Element defined in option "triggerElement" was not found:',a]}return a},triggerHook:function(a){var m={onCenter:.5,onEnter:1,onLeave:0};if(c.type.Number(a))a=Math.max(0,Math.min(parseFloat(a),1));else if(a in m)a=m[a];else throw['Invalid value for option "triggerHook": ',a];return a},reverse:function(a){return!!a},loglevel:function(a){if(a=parseInt(a),!c.type.Number(a)||a<0||a>3)throw['Invalid value for option "loglevel":',a];return a}},shifts:["duration","offset","triggerHook"]};n.Scene.addOption=function(a,m,g,x){a in s.defaults?n._util.log(1,"[static] ScrollMagic.Scene -> Cannot add Scene option '"+a+"', because it already exists."):(s.defaults[a]=m,s.validate[a]=g,x&&s.shifts.push(a))},n.Scene.extend=function(a){var m=this;n.Scene=function(){return m.apply(this,arguments),this.$super=c.extend({},this),a.apply(this,arguments)||this},c.extend(n.Scene,m),n.Scene.prototype=m.prototype,n.Scene.prototype.constructor=n.Scene},n.Event=function(a,m,g,x){x=x||{};for(var T in x)this[T]=x[T];return this.type=a,this.target=this.currentTarget=g,this.namespace=m||"",this.timeStamp=this.timestamp=Date.now(),this};var c=n._util=function(a){var m={},g,x=function(Z){return parseFloat(Z)||0},T=function(Z){return Z.currentStyle?Z.currentStyle:a.getComputedStyle(Z)},C=function(Z,K,Y,me){if(K=K===document?a:K,K===a)me=!1;else if(!W.DomElement(K))return 0;Z=Z.charAt(0).toUpperCase()+Z.substr(1).toLowerCase();var ge=(Y?K["offset"+Z]||K["outer"+Z]:K["client"+Z]||K["inner"+Z])||0;if(Y&&me){var ce=T(K);ge+=Z==="Height"?x(ce.marginTop)+x(ce.marginBottom):x(ce.marginLeft)+x(ce.marginRight)}return ge},A=function(Z){return Z.replace(/^[^a-z]+([a-z])/g,"$1").replace(/-([a-z])/g,function(K){return K[1].toUpperCase()})};m.extend=function(Z){for(Z=Z||{},g=1;g<arguments.length;g++)if(arguments[g])for(var K in arguments[g])arguments[g].hasOwnProperty(K)&&(Z[K]=arguments[g][K]);return Z},m.isMarginCollapseType=function(Z){return["block","flex","list-item","table","-webkit-box"].indexOf(Z)>-1};var P=0,D=["ms","moz","webkit","o"],B=a.requestAnimationFrame,R=a.cancelAnimationFrame;for(g=0;!B&&g<D.length;++g)B=a[D[g]+"RequestAnimationFrame"],R=a[D[g]+"CancelAnimationFrame"]||a[D[g]+"CancelRequestAnimationFrame"];B||(B=function(Z){var K=new Date().getTime(),Y=Math.max(0,16-(K-P)),me=a.setTimeout(function(){Z(K+Y)},Y);return P=K+Y,me}),R||(R=function(Z){a.clearTimeout(Z)}),m.rAF=B.bind(a),m.cAF=R.bind(a);var N=["error","warn","log"],j=a.console||{};for(j.log=j.log||function(){},g=0;g<N.length;g++){var U=N[g];j[U]||(j[U]=j.log)}m.log=function(Z){(Z>N.length||Z<=0)&&(Z=N.length);var K=new Date,Y=("0"+K.getHours()).slice(-2)+":"+("0"+K.getMinutes()).slice(-2)+":"+("0"+K.getSeconds()).slice(-2)+":"+("00"+K.getMilliseconds()).slice(-3),me=N[Z-1],ge=Array.prototype.splice.call(arguments,1),ce=Function.prototype.bind.call(j[me],j);ge.unshift(Y),ce.apply(j,ge)};var W=m.type=function(Z){return Object.prototype.toString.call(Z).replace(/^\[object (.+)\]$/,"$1").toLowerCase()};
86W.String=function(Z){return W(Z)==="string"},W.Function=function(Z){return W(Z)==="function"},W.Array=function(Z){return Array.isArray(Z)},W.Number=function(Z){return!W.Array(Z)&&Z-parseFloat(Z)+1>=0},W.DomElement=function(Z){return typeof HTMLElement=="object"||typeof HTMLElement=="function"?Z instanceof HTMLElement||Z instanceof SVGElement:Z&&typeof Z=="object"&&Z!==null&&Z.nodeType===1&&typeof Z.nodeName=="string"};var Q=m.get={};return Q.elements=function(Z){var K=[];if(W.String(Z))try{Z=document.querySelectorAll(Z)}catch{return K}if(W(Z)==="nodelist"||W.Array(Z)||Z instanceof NodeList)for(var Y=0,me=K.length=Z.length;Y<me;Y++){var ge=Z[Y];K[Y]=W.DomElement(ge)?ge:Q.elements(ge)}else(W.DomElement(Z)||Z===document||Z===a)&&(K=[Z]);return K},Q.scrollTop=function(Z){return Z&&typeof Z.scrollTop=="number"?Z.scrollTop:a.pageYOffset||0},Q.scrollLeft=function(Z){return Z&&typeof Z.scrollLeft=="number"?Z.scrollLeft:a.pageXOffset||0},Q.width=function(Z,K,Y){return C("width",Z,K,Y)},Q.height=function(Z,K,Y){return C("height",Z,K,Y)},Q.offset=function(Z,K){var Y={top:0,left:0};if(Z&&Z.getBoundingClientRect){var me=Z.getBoundingClientRect();Y.top=me.top,Y.left=me.left,K||(Y.top+=Q.scrollTop(),Y.left+=Q.scrollLeft())}return Y},m.addClass=function(Z,K){K&&(Z.classList?Z.classList.add(K):Z.className+=" "+K)},m.removeClass=function(Z,K){K&&(Z.classList?Z.classList.remove(K):Z.className=Z.className.replace(new RegExp("(^|\\b)"+K.split(" ").join("|")+"(\\b|$)","gi")," "))},m.css=function(Z,K){if(W.String(K))return T(Z)[A(K)];if(W.Array(K)){var Y={},me=T(Z);return K.forEach(function(fe,ie){Y[fe]=me[A(fe)]}),Y}else for(var ge in K){var ce=K[ge];ce==parseFloat(ce)&&(ce+="px"),Z.style[A(ge)]=ce}},m}(window||{});return n.Scene.prototype.addIndicators=function(){return n._util.log(1,"(ScrollMagic.Scene) -> ERROR calling addIndicators() due to missing Plugin 'debug.addIndicators'. Please make sure to include plugins/debug.addIndicators.js"),this},n.Scene.prototype.removeIndicators=function(){return n._util.log(1,"(ScrollMagic.Scene) -> ERROR calling removeIndicators() due to missing Plugin 'debug.addIndicators'. Please make sure to include plugins/debug.addIndicators.js"),this},n.Scene.prototype.setTween=function(){return n._util.log(1,"(ScrollMagic.Scene) -> ERROR calling setTween() due to missing Plugin 'animation.gsap'. Please make sure to include plugins/animation.gsap.js"),this},n.Scene.prototype.removeTween=function(){return n._util.log(1,"(ScrollMagic.Scene) -> ERROR calling removeTween() due to missing Plugin 'animation.gsap'. Please make sure to include plugins/animation.gsap.js"),this},n.Scene.prototype.setVelocity=function(){return n._util.log(1,"(ScrollMagic.Scene) -> ERROR calling setVelocity() due to missing Plugin 'animation.velocity'. Please make sure to include plugins/animation.velocity.js"),this},n.Scene.prototype.removeVelocity=function(){return n._util.log(1,"(ScrollMagic.Scene) -> ERROR calling removeVelocity() due to missing Plugin 'animation.velocity'. Please make sure to include plugins/animation.velocity.js"),this},n})})(yN);var _N=yN.exports;const xne=Rd(_N);function Yu(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function vN(e,t){e.prototype=Object.create(t.prototype),e.prototype.constructor=e,e.__proto__=t}/*!
87 * GSAP 3.12.5
88 * https://gsap.com
89 *
90 * @license Copyright 2008-2024, GreenSock. All rights reserved.
91 * Subject to the terms at https://gsap.com/standard-license or for
92 * Club GSAP members, the agreement issued with that membership.
93 * @author: Jack Doyle, [email protected]
94*/var ml={autoSleep:120,force3D:"auto",nullTargetWarn:1,units:{lineHeight:""}},lg={duration:.5,overwrite:!1,delay:0},l2,ts,uo,Vl=1e8,Zi=1/Vl,KS=Math.PI*2,wne=KS/4,Tne=0,bN=Math.sqrt,Ene=Math.cos,Sne=Math.sin,ka=function(t){return typeof t=="string"},Lo=function(t){return typeof t=="function"},oh=function(t){return typeof t=="number"},c2=function(t){return typeof t>"u"},yu=function(t){return typeof t=="object"},Fs=function(t){return t!==!1},u2=function(){return typeof window<"u"},sb=function(t){return Lo(t)||ka(t)},xN=typeof ArrayBuffer=="function"&&ArrayBuffer.isView||function(){},ns=Array.isArray,QS=/(?:-?\.?\d|\.)+/gi,wN=/[-+=.]*\d+[.e\-+]*\d*[e\-+]*\d*/g,Mm=/[-+=.]*\d+[.e-]*\d*[a-z%]*/g,GT=/[-+=.]*\d+\.?\d*(?:e-|e\+)?\d*/gi,TN=/[+-]=-?[.\d]+/,EN=/[^,'"\[\]\s]+/gi,Cne=/^[+\-=e\s\d]*\d+[.\d]*([a-z]*|%)\s*$/i,Eo,ru,JS,h2,yl={},fx={},SN,CN=function(t){return(fx=mp(t,yl))&&Gs},d2=function(t,n){return console.warn("Invalid property",t,"set to",n,"Missing plugin? gsap.registerPlugin()")},Y_=function(t,n){return!n&&console.warn(t)},kN=function(t,n){return t&&(yl[t]=n)&&fx&&(fx[t]=n)||yl},Z_=function(){return 0},kne={suppressEvents:!0,isStart:!0,kill:!1},Ib={suppressEvents:!0,kill:!1},Ane={suppressEvents:!0},f2={},_d=[],eC={},AN,ul={},qT={},pL=30,Ob=[],p2="",m2=function(t){var n=t[0],r,i;if(yu(n)||Lo(n)||(t=[t]),!(r=(n._gsap||{}).harness)){for(i=Ob.length;i--&&!Ob[i].targetTest(n););r=Ob[i]}for(i=t.length;i--;)t[i]&&(t[i]._gsap||(t[i]._gsap=new QN(t[i],r)))||t.splice(i,1);return t},op=function(t){return t._gsap||m2(Gl(t))[0]._gsap}
vendor: 52,214 bytes, lines 94-102
94,PN=function(t,n,r){return(r=t[n])&&Lo(r)?t[n]():c2(r)&&t.getAttribute&&t.getAttribute(n)||r},Bs=function(t,n){return(t=t.split(",")).forEach(n)||t},No=function(t){return Math.round(t*1e5)/1e5||0},Ea=function(t){return Math.round(t*1e7)/1e7||0},Vm=function(t,n){var r=n.charAt(0),i=parseFloat(n.substr(2));return t=parseFloat(t),r==="+"?t+i:r==="-"?t-i:r==="*"?t*i:t/i},Pne=function(t,n){for(var r=n.length,i=0;t.indexOf(n[i])<0&&++i<r;);return i<r},px=function(){var t=_d.length,n=_d.slice(0),r,i;for(eC={},_d.length=0,r=0;r<t;r++)i=n[r],i&&i._lazy&&(i.render(i._lazy[0],i._lazy[1],!0)._lazy=0)},MN=function(t,n,r,i){_d.length&&!ts&&px(),t.render(n,r,i||ts&&n<0&&(t._initted||t._startAt)),_d.length&&!ts&&px()},IN=function(t){var n=parseFloat(t);return(n||n===0)&&(t+"").match(EN).length<2?n:ka(t)?t.trim():t},ON=function(t){return t},Yl=function(t,n){for(var r in n)r in t||(t[r]=n[r]);return t},Mne=function(t){return function(n,r){for(var i in r)i in n||i==="duration"&&t||i==="ease"||(n[i]=r[i])}},mp=function(t,n){for(var r in n)t[r]=n[r];return t},mL=function e(t,n){for(var r in n)r!=="__proto__"&&r!=="constructor"&&r!=="prototype"&&(t[r]=yu(n[r])?e(t[r]||(t[r]={}),n[r]):n[r]);return t},mx=function(t,n){var r={},i;for(i in t)i in n||(r[i]=t[i]);return r},w_=function(t){var n=t.parent||Eo,r=t.keyframes?Mne(ns(t.keyframes)):Yl;if(Fs(t.inherit))for(;n;)r(t,n.vars.defaults),n=n.parent||n._dp;return t},Ine=function(t,n){for(var r=t.length,i=r===n.length;i&&r--&&t[r]===n[r];);return r<0},DN=function(t,n,r,i,s){r===void 0&&(r="_first"),i===void 0&&(i="_last");var c=t[i],a;if(s)for(a=n[s];c&&c[s]>a;)c=c._prev;return c?(n._next=c._next,c._next=n):(n._next=t[r],t[r]=n),n._next?n._next._prev=n:t[i]=n,n._prev=c,n.parent=n._dp=t,n},x1=function(t,n,r,i){r===void 0&&(r="_first"),i===void 0&&(i="_last");var s=n._prev,c=n._next;s?s._next=c:t[r]===n&&(t[r]=c),c?c._prev=s:t[i]===n&&(t[i]=s),n._next=n._prev=n.parent=null},Md=function(t,n){t.parent&&(!n||t.parent.autoRemoveChildren)&&t.parent.remove&&t.parent.remove(t),t._act=0},ap=function(t,n){if(t&&(!n||n._end>t._dur||n._start<0))for(var r=t;r;)r._dirty=1,r=r.parent;return t},One=function(t){for(var n=t.parent;n&&n.parent;)n._dirty=1,n.totalDuration(),n=n.parent;return t},tC=function(t,n,r,i){return t._startAt&&(ts?t._startAt.revert(Ib):t.vars.immediateRender&&!t.vars.autoRevert||t._startAt.render(n,!0,i))},Dne=function e(t){return!t||t._ts&&e(t.parent)},gL=function(t){return t._repeat?cg(t._tTime,t=t.duration()+t._rDelay)*t:0},cg=function(t,n){var r=Math.floor(t/=n);return t&&r===t?r-1:r},gx=function(t,n){return(t-n._start)*n._ts+(n._ts>=0?0:n._dirty?n.totalDuration():n._tDur)},w1=function(t){return t._end=Ea(t._start+(t._tDur/Math.abs(t._ts||t._rts||Zi)||0))},T1=function(t,n){var r=t._dp;return r&&r.smoothChildTiming&&t._ts&&(t._start=Ea(r._time-(t._ts>0?n/t._ts:((t._dirty?t.totalDuration():t._tDur)-n)/-t._ts)),w1(t),r._dirty||ap(r,t)),t},LN=function(t,n){var r;if((n._time||!n._dur&&n._initted||n._start<t._time&&(n._dur||!n.add))&&(r=gx(t.rawTime(),n),(!n._dur||Dv(0,n.totalDuration(),r)-n._tTime>Zi)&&n.render(r,!0)),ap(t,n)._dp&&t._initted&&t._time>=t._dur&&t._ts){if(t._dur<t.duration())for(r=t;r._dp;)r.rawTime()>=0&&r.totalTime(r._tTime),r=r._dp;t._zTime=-Zi}},ou=function(t,n,r,i){return n.parent&&Md(n),n._start=Ea((oh(r)?r:r||t!==Eo?zl(t,r,n):t._time)+n._delay),n._end=Ea(n._start+(n.totalDuration()/Math.abs(n.timeScale())||0)),DN(t,n,"_first","_last",t._sort?"_start":0),nC(n)||(t._recent=n),i||LN(t,n),t._ts<0&&T1(t,t._tTime),t},RN=function(t,n){return(yl.ScrollTrigger||d2("scrollTrigger",n))&&yl.ScrollTrigger.create(n,t)},FN=function(t,n,r,i,s){if(y2(t,n,s),!t._initted)return 1;if(!r&&t._pt&&!ts&&(t._dur&&t.vars.lazy!==!1||!t._dur&&t.vars.lazy)&&AN!==hl.frame)return _d.push(t),t._lazy=[s,i],1},Lne=function e(t){var n=t.parent;return n&&n._ts&&n._initted&&!n._lock&&(n.rawTime()<0||e(n))},nC=function(t){var n=t.data;return n==="isFromStart"||n==="isStart"},Rne=function(t,n,r,i){var s=t.ratio,c=n<0||!n&&(!t._start&&Lne(t)&&!(!t._initted&&nC(t))||(t._ts<0||t._dp._ts<0)&&!nC(t))?0:1,a=t._rDelay,m=0,g,x,T;if(a&&t._repeat&&(m=Dv(0,t._tDur,n),x=cg(m,a),t._yoyo&&x&1&&(c=1-c),x!==cg(t._tTime,a)&&(s=1-c,t.vars.repeatRefresh&&t._initted&&t.invalidate())),c!==s||ts||i||t._zTime===Zi||!n&&t._zTime){if(!t._initted&&FN(t,n,i,r,m))return;for(T=t._zTime,t._zTime=n||(r?Zi:0),r||(r=n&&!T),t.ratio=c,t._from&&(c=1-c),t._time=0,t._tTime=m,g=t._pt;g;)g.r(c,g.d),g=g._next;n<0&&tC(t,n,r,!0),t._onUpdate&&!r&&fl(t,"onUpdate"),m&&t._repeat&&!r&&t.parent&&fl(t,"onRepeat"),(n>=t._tDur||n<0)&&t.ratio===c&&(c&&Md(t,1),!r&&!ts&&(fl(t,c?"onComplete":"onReverseComplete",!0),t._prom&&t._prom()))}else t._zTime||(t._zTime=n)},Fne=function(t,n,r){var i;if(r>n)for(i=t._first;i&&i._start<=r;){if(i.data==="isPause"&&i._start>n)return i;i=i._next}else for(i=t._last;i&&i._start>=r;){if(i.data==="isPause"&&i._start<n)return i;i=i._prev}},ug=function(t,n,r,i){var s=t._repeat,c=Ea(n)||0,a=t._tTime/t._tDur;return a&&!i&&(t._time*=c/t._dur),t._dur=c,t._tDur=s?s<0?1e10:Ea(c*(s+1)+t._rDelay*s):c,a>0&&!i&&T1(t,t._tTime=t._tDur*a),t.parent&&w1(t),r||ap(t.parent,t),t},yL=function(t){return t instanceof ms?ap(t):ug(t,t._dur)},Bne={_start:0,endTime:Z_,totalDuration:Z_},zl=function e(t,n,r){var i=t.labels,s=t._recent||Bne,c=t.duration()>=Vl?s.endTime(!1):t._dur,a,m,g;return ka(n)&&(isNaN(n)||n in i)?(m=n.charAt(0),g=n.substr(-1)==="%",a=n.indexOf("="),m==="<"||m===">"?(a>=0&&(n=n.replace(/=/,"")),(m==="<"?s._start:s.endTime(s._repeat>=0))+(parseFloat(n.substr(1))||0)*(g?(a<0?s:r).totalDuration()/100:1)):a<0?(n in i||(i[n]=c),i[n]):(m=parseFloat(n.charAt(a-1)+n.substr(a+1)),g&&r&&(m=m/100*(ns(r)?r[0]:r).totalDuration()),a>1?e(t,n.substr(0,a-1),r)+m:c+m)):n==null?c:+n},T_=function(t,n,r){var i=oh(n[1]),s=(i?2:1)+(t<2?0:1),c=n[s],a,m;if(i&&(c.duration=n[1]),c.parent=r,t){for(a=c,m=r;m&&!("immediateRender"in a);)a=m.vars.defaults||{},m=Fs(m.vars.inherit)&&m.parent;c.immediateRender=Fs(a.immediateRender),t<2?c.runBackwards=1:c.startAt=n[s-1]}return new Ko(n[0],c,n[s+1])},Nd=function(t,n){return t||t===0?n(t):n},Dv=function(t,n,r){return r<t?t:r>n?n:r},Ja=function(t,n){return!ka(t)||!(n=Cne.exec(t))?"":n[1]},zne=function(t,n,r){return Nd(r,function(i){return Dv(t,n,i)})},rC=[].slice,BN=function(t,n){return t&&yu(t)&&"length"in t&&(!n&&!t.length||t.length-1 in t&&yu(t[0]))&&!t.nodeType&&t!==ru},Nne=function(t,n,r){return r===void 0&&(r=[]),t.forEach(function(i){var s;return ka(i)&&!n||BN(i,1)?(s=r).push.apply(s,Gl(i)):r.push(i)})||r},Gl=function(t,n,r){return uo&&!n&&uo.selector?uo.selector(t):ka(t)&&!r&&(JS||!hg())?rC.call((n||h2).querySelectorAll(t),0):ns(t)?Nne(t,r):BN(t)?rC.call(t,0):t?[t]:[]},iC=function(t){return t=Gl(t)[0]||Y_("Invalid scope")||{},function(n){var r=t.current||t.nativeElement||t;return Gl(n,r.querySelectorAll?r:r===t?Y_("Invalid scope")||h2.createElement("div"):t)}},zN=function(t){return t.sort(function(){return .5-Math.random()})},NN=function(t){if(Lo(t))return t;var n=yu(t)?t:{each:t},r=sp(n.ease),i=n.from||0,s=parseFloat(n.base)||0,c={},a=i>0&&i<1,m=isNaN(i)||a,g=n.axis,x=i,T=i;return ka(i)?x=T={center:.5,edges:.5,end:1}[i]||0:!a&&m&&(x=i[0],T=i[1]),function(C,A,P){var D=(P||n).length,B=c[D],R,N,j,U,W,Q,Z,K,Y;if(!B){if(Y=n.grid==="auto"?0:(n.grid||[1,Vl])[1],!Y){for(Z=-Vl;Z<(Z=P[Y++].getBoundingClientRect().left)&&Y<D;);Y<D&&Y--}for(B=c[D]=[],R=m?Math.min(Y,D)*x-.5:i%Y,N=Y===Vl?0:m?D*T/Y-.5:i/Y|0,Z=0,K=Vl,Q=0;Q<D;Q++)j=Q%Y-R,U=N-(Q/Y|0),B[Q]=W=g?Math.abs(g==="y"?U:j):bN(j*j+U*U),W>Z&&(Z=W),W<K&&(K=W);i==="random"&&zN(B),B.max=Z-K,B.min=K,B.v=D=(parseFloat(n.amount)||parseFloat(n.each)*(Y>D?D-1:g?g==="y"?D/Y:Y:Math.max(Y,D/Y))||0)*(i==="edges"?-1:1),B.b=D<0?s-D:s,B.u=Ja(n.amount||n.each)||0,r=r&&D<0?ZN(r):r}return D=(B[C]-B.min)/B.max||0,Ea(B.b+(r?r(D):D)*B.v)+B.u}},oC=function(t){var n=Math.pow(10,((t+"").split(".")[1]||"").length);return function(r){var i=Ea(Math.round(parseFloat(r)/t)*t*n);return(i-i%1)/n+(oh(r)?0:Ja(r))}},$N=function(t,n){var r=ns(t),i,s;return!r&&yu(t)&&(i=r=t.radius||Vl,t.values?(t=Gl(t.values),(s=!oh(t[0]))&&(i*=i)):t=oC(t.increment)),Nd(n,r?Lo(t)?function(c){return s=t(c),Math.abs(s-c)<=i?s:c}:function(c){for(var a=parseFloat(s?c.x:c),m=parseFloat(s?c.y:0),g=Vl,x=0,T=t.length,C,A;T--;)s?(C=t[T].x-a,A=t[T].y-m,C=C*C+A*A):C=Math.abs(t[T]-a),C<g&&(g=C,x=T);return x=!i||g<=i?t[x]:c,s||x===c||oh(c)?x:x+Ja(c)}:oC(t))},jN=function(t,n,r,i){return Nd(ns(t)?!n:r===!0?!!(r=0):!i,function(){return ns(t)?t[~~(Math.random()*t.length)]:(r=r||1e-5)&&(i=r<1?Math.pow(10,(r+"").length-2):1)&&Math.floor(Math.round((t-r/2+Math.random()*(n-t+r*.99))/r)*r*i)/i})},$ne=function(){for(var t=arguments.length,n=new Array(t),r=0;r<t;r++)n[r]=arguments[r];return function(i){return n.reduce(function(s,c){return c(s)},i)}},jne=function(t,n){return function(r){return t(parseFloat(r))+(n||Ja(r))}},Une=function(t,n,r){return VN(t,n,0,1,r)},UN=function(t,n,r){return Nd(r,function(i){return t[~~n(i)]})},Vne=function e(t,n,r){var i=n-t;return ns(t)?UN(t,e(0,t.length),n):Nd(r,function(s){return(i+(s-t)%i)%i+t})},Gne=function e(t,n,r){var i=n-t,s=i*2;return ns(t)?UN(t,e(0,t.length-1),n):Nd(r,function(c){return c=(s+(c-t)%s)%s||0,t+(c>i?s-c:c)})},X_=function(t){for(var n=0,r="",i,s,c,a;~(i=t.indexOf("random(",n));)c=t.indexOf(")",i),a=t.charAt(i+7)==="[",s=t.substr(i+7,c-i-7).match(a?EN:QS),r+=t.substr(n,i-n)+jN(a?s:+s[0],a?0:+s[1],+s[2]||1e-5),n=c+1;return r+t.substr(n,t.length-n)},VN=function(t,n,r,i,s){var c=n-t,a=i-r;return Nd(s,function(m){return r+((m-t)/c*a||0)})},qne=function e(t,n,r,i){var s=isNaN(t+n)?0:function(A){return(1-A)*t+A*n};if(!s){var c=ka(t),a={},m,g,x,T,C;if(r===!0&&(i=1)&&(r=null),c)t={p:t},n={p:n};else if(ns(t)&&!ns(n)){for(x=[],T=t.length,C=T-2,g=1;g<T;g++)x.push(e(t[g-1],t[g]));T--,s=function(P){P*=T;var D=Math.min(C,~~P);return x[D](P-D)},r=n}else i||(t=mp(ns(t)?[]:{},t));if(!x){for(m in n)g2.call(a,t,m,"get",n[m]);s=function(P){return b2(P,a)||(c?t.p:t)}}}return Nd(r,s)},_L=function(t,n,r){var i=t.labels,s=Vl,c,a,m;for(c in i)a=i[c]-n,a<0==!!r&&a&&s>(a=Math.abs(a))&&(m=c,s=a);return m},fl=function(t,n,r){var i=t.vars,s=i[n],c=uo,a=t._ctx,m,g,x;if(s)return m=i[n+"Params"],g=i.callbackScope||t,r&&_d.length&&px(),a&&(uo=a),x=m?s.apply(g,m):s.call(g),uo=c,x},i_=function(t){return Md(t),t.scrollTrigger&&t.scrollTrigger.kill(!!ts),t.progress()<1&&fl(t,"onInterrupt"),t},Im,GN=[],qN=function(t){if(t)if(t=!t.name&&t.default||t,u2()||t.headless){var n=t.name,r=Lo(t),i=n&&!r&&t.init?function(){this._props=[]}:t,s={init:Z_,render:b2,add:g2,kill:sre,modifier:are,rawVars:0},c={targetTest:0,get:0,getSetter:v2,aliases:{},register:0};if(hg(),t!==i){if(ul[n])return;Yl(i,Yl(mx(t,s),c)),mp(i.prototype,mp(s,mx(t,c))),ul[i.prop=n]=i,t.targetTest&&(Ob.push(i),f2[n]=1),n=(n==="css"?"CSS":n.charAt(0).toUpperCase()+n.substr(1))+"Plugin"}kN(n,i),t.register&&t.register(Gs,i,zs)}else GN.push(t)},Vi=255,o_={aqua:[0,Vi,Vi],lime:[0,Vi,0],silver:[192,192,192],black:[0,0,0],maroon:[128,0,0],teal:[0,128,128],blue:[0,0,Vi],navy:[0,0,128],white:[Vi,Vi,Vi],olive:[128,128,0],yellow:[Vi,Vi,0],orange:[Vi,165,0],gray:[128,128,128],purple:[128,0,128],green:[0,128,0],red:[Vi,0,0],pink:[Vi,192,203],cyan:[0,Vi,Vi],transparent:[Vi,Vi,Vi,0]},WT=function(t,n,r){return t+=t<0?1:t>1?-1:0,(t*6<1?n+(r-n)*t*6:t<.5?r:t*3<2?n+(r-n)*(2/3-t)*6:n)*Vi+.5|0},WN=function(t,n,r){var i=t?oh(t)?[t>>16,t>>8&Vi,t&Vi]:0:o_.black,s,c,a,m,g,x,T,C,A,P;if(!i){if(t.substr(-1)===","&&(t=t.substr(0,t.length-1)),o_[t])i=o_[t];else if(t.charAt(0)==="#"){if(t.length<6&&(s=t.charAt(1),c=t.charAt(2),a=t.charAt(3),t="#"+s+s+c+c+a+a+(t.length===5?t.charAt(4)+t.charAt(4):"")),t.length===9)return i=parseInt(t.substr(1,6),16),[i>>16,i>>8&Vi,i&Vi,parseInt(t.substr(7),16)/255];t=parseInt(t.substr(1),16),i=[t>>16,t>>8&Vi,t&Vi]}else if(t.substr(0,3)==="hsl"){if(i=P=t.match(QS),!n)m=+i[0]%360/360,g=+i[1]/100,x=+i[2]/100,c=x<=.5?x*(g+1):x+g-x*g,s=x*2-c,i.length>3&&(i[3]*=1),i[0]=WT(m+1/3,s,c),i[1]=WT(m,s,c),i[2]=WT(m-1/3,s,c);else if(~t.indexOf("="))return i=t.match(wN),r&&i.length<4&&(i[3]=1),i}else i=t.match(QS)||o_.transparent;i=i.map(Number)}return n&&!P&&(s=i[0]/Vi,c=i[1]/Vi,a=i[2]/Vi,T=Math.max(s,c,a),C=Math.min(s,c,a),x=(T+C)/2,T===C?m=g=0:(A=T-C,g=x>.5?A/(2-T-C):A/(T+C),m=T===s?(c-a)/A+(c<a?6:0):T===c?(a-s)/A+2:(s-c)/A+4,m*=60),i[0]=~~(m+.5),i[1]=~~(g*100+.5),i[2]=~~(x*100+.5)),r&&i.length<4&&(i[3]=1),i},HN=function(t){var n=[],r=[],i=-1;return t.split(vd).forEach(function(s){var c=s.match(Mm)||[];n.push.apply(n,c),r.push(i+=c.length+1)}),n.c=r,n},vL=function(t,n,r){var i="",s=(t+i).match(vd),c=n?"hsla(":"rgba(",a=0,m,g,x,T;if(!s)return t;if(s=s.map(function(C){return(C=WN(C,n,1))&&c+(n?C[0]+","+C[1]+"%,"+C[2]+"%,"+C[3]:C.join(","))+")"}),r&&(x=HN(t),m=r.c,m.join(i)!==x.c.join(i)))for(g=t.replace(vd,"1").split(Mm),T=g.length-1;a<T;a++)i+=g[a]+(~m.indexOf(a)?s.shift()||c+"0,0,0,0)":(x.length?x:s.length?s:r).shift());if(!g)for(g=t.split(vd),T=g.length-1;a<T;a++)i+=g[a]+s[a];return i+g[T]},vd=function(){var e="(?:\\b(?:(?:rgb|rgba|hsl|hsla)\\(.+?\\))|\\B#(?:[0-9a-f]{3,4}){1,2}\\b",t;for(t in o_)e+="|"+t+"\\b";return new RegExp(e+")","gi")}(),Wne=/hsl[a]?\(/,YN=function(t){var n=t.join(" "),r;if(vd.lastIndex=0,vd.test(n))return r=Wne.test(n),t[1]=vL(t[1],r),t[0]=vL(t[0],r,HN(t[1])),!0},K_,hl=function(){var e=Date.now,t=500,n=33,r=e(),i=r,s=1e3/240,c=s,a=[],m,g,x,T,C,A,P=function D(B){var R=e()-i,N=B===!0,j,U,W,Q;if((R>t||R<0)&&(r+=R-n),i+=R,W=i-r,j=W-c,(j>0||N)&&(Q=++T.frame,C=W-T.time*1e3,T.time=W=W/1e3,c+=j+(j>=s?4:s-j),U=1),N||(m=g(D)),U)for(A=0;A<a.length;A++)a[A](W,C,Q,B)};return T={time:0,frame:0,tick:function(){P(!0)},deltaRatio:function(B){return C/(1e3/(B||60))},wake:function(){SN&&(!JS&&u2()&&(ru=JS=window,h2=ru.document||{},yl.gsap=Gs,(ru.gsapVersions||(ru.gsapVersions=[])).push(Gs.version),CN(fx||ru.GreenSockGlobals||!ru.gsap&&ru||{}),GN.forEach(qN)),x=typeof requestAnimationFrame<"u"&&requestAnimationFrame,m&&T.sleep(),g=x||function(B){return setTimeout(B,c-T.time*1e3+1|0)},K_=1,P(2))},sleep:function(){(x?cancelAnimationFrame:clearTimeout)(m),K_=0,g=Z_},lagSmoothing:function(B,R){t=B||1/0,n=Math.min(R||33,t)},fps:function(B){s=1e3/(B||240),c=T.time*1e3+s},add:function(B,R,N){var j=R?function(U,W,Q,Z){B(U,W,Q,Z),T.remove(j)}:B;return T.remove(B),a[N?"unshift":"push"](j),hg(),j},remove:function(B,R){~(R=a.indexOf(B))&&a.splice(R,1)&&A>=R&&A--},_listeners:a},T}(),hg=function(){return!K_&&hl.wake()},jr={},Hne=/^[\d.\-M][\d.\-,\s]/,Yne=/["']/g,Zne=function(t){for(var n={},r=t.substr(1,t.length-3).split(":"),i=r[0],s=1,c=r.length,a,m,g;s<c;s++)m=r[s],a=s!==c-1?m.lastIndexOf(","):m.length,g=m.substr(0,a),n[i]=isNaN(g)?g.replace(Yne,"").trim():+g,i=m.substr(a+1).trim();return n},Xne=function(t){var n=t.indexOf("(")+1,r=t.indexOf(")"),i=t.indexOf("(",n);return t.substring(n,~i&&i<r?t.indexOf(")",r+1):r)},Kne=function(t){var n=(t+"").split("("),r=jr[n[0]];return r&&n.length>1&&r.config?r.config.apply(null,~t.indexOf("{")?[Zne(n[1])]:Xne(t).split(",").map(IN)):jr._CE&&Hne.test(t)?jr._CE("",t):r},ZN=function(t){return function(n){return 1-t(1-n)}},XN=function e(t,n){for(var r=t._first,i;r;)r instanceof ms?e(r,n):r.vars.yoyoEase&&(!r._yoyo||!r._repeat)&&r._yoyo!==n&&(r.timeline?e(r.timeline,n):(i=r._ease,r._ease=r._yEase,r._yEase=i,r._yoyo=n)),r=r._next},sp=function(t,n){return t&&(Lo(t)?t:jr[t]||Kne(t))||n},wp=function(t,n,r,i){r===void 0&&(r=function(m){return 1-n(1-m)}),i===void 0&&(i=function(m){return m<.5?n(m*2)/2:1-n((1-m)*2)/2});var s={easeIn:n,easeOut:r,easeInOut:i},c;return Bs(t,function(a){jr[a]=yl[a]=s,jr[c=a.toLowerCase()]=r;for(var m in s)jr[c+(m==="easeIn"?".in":m==="easeOut"?".out":".inOut")]=jr[a+"."+m]=s[m]}),s},KN=function(t){return function(n){return n<.5?(1-t(1-n*2))/2:.5+t((n-.5)*2)/2}},HT=function e(t,n,r){var i=n>=1?n:1,s=(r||(t?.3:.45))/(n<1?n:1),c=s/KS*(Math.asin(1/i)||0),a=function(x){return x===1?1:i*Math.pow(2,-10*x)*Sne((x-c)*s)+1},m=t==="out"?a:t==="in"?function(g){return 1-a(1-g)}:KN(a);return s=KS/s,m.config=function(g,x){return e(t,g,x)},m},YT=function e(t,n){n===void 0&&(n=1.70158);var r=function(c){return c?--c*c*((n+1)*c+n)+1:0},i=t==="out"?r:t==="in"?function(s){return 1-r(1-s)}:KN(r);return i.config=function(s){return e(t,s)},i};Bs("Linear,Quad,Cubic,Quart,Quint,Strong",function(e,t){var n=t<5?t+1:t;wp(e+",Power"+(n-1),t?function(r){return Math.pow(r,n)}:function(r){return r},function(r){return 1-Math.pow(1-r,n)},function(r){return r<.5?Math.pow(r*2,n)/2:1-Math.pow((1-r)*2,n)/2})});jr.Linear.easeNone=jr.none=jr.Linear.easeIn;wp("Elastic",HT("in"),HT("out"),HT());(function(e,t){var n=1/t,r=2*n,i=2.5*n,s=function(a){return a<n?e*a*a:a<r?e*Math.pow(a-1.5/t,2)+.75:a<i?e*(a-=2.25/t)*a+.9375:e*Math.pow(a-2.625/t,2)+.984375};wp("Bounce",function(c){return 1-s(1-c)},s)})(7.5625,2.75);wp("Expo",function(e){return e?Math.pow(2,10*(e-1)):0});wp("Circ",function(e){return-(bN(1-e*e)-1)});wp("Sine",function(e){return e===1?1:-Ene(e*wne)+1});wp("Back",YT("in"),YT("out"),YT());jr.SteppedEase=jr.steps=yl.SteppedEase={config:function(t,n){t===void 0&&(t=1);var r=1/t,i=t+(n?0:1),s=n?1:0,c=1-Zi;return function(a){return((i*Dv(0,c,a)|0)+s)*r}}};lg.ease=jr["quad.out"];Bs("onComplete,onUpdate,onStart,onRepeat,onReverseComplete,onInterrupt",function(e){return p2+=e+","+e+"Params,"});var QN=function(t,n){this.id=Tne++,t._gsap=this,this.target=t,this.harness=n,this.get=n?n.get:PN,this.set=n?n.getSetter:v2},Q_=function(){function e(n){this.vars=n,this._delay=+n.delay||0,(this._repeat=n.repeat===1/0?-2:n.repeat||0)&&(this._rDelay=n.repeatDelay||0,this._yoyo=!!n.yoyo||!!n.yoyoEase),this._ts=1,ug(this,+n.duration,1,1),this.data=n.data,uo&&(this._ctx=uo,uo.data.push(this)),K_||hl.wake()}var t=e.prototype;return t.delay=function(r){return r||r===0?(this.parent&&this.parent.smoothChildTiming&&this.startTime(this._start+r-this._delay),this._delay=r,this):this._delay},t.duration=function(r){return arguments.length?this.totalDuration(this._repeat>0?r+(r+this._rDelay)*this._repeat:r):this.totalDuration()&&this._dur},t.totalDuration=function(r){return arguments.length?(this._dirty=0,ug(this,this._repeat<0?r:(r-this._repeat*this._rDelay)/(this._repeat+1))):this._tDur},t.totalTime=function(r,i){if(hg(),!arguments.length)return this._tTime;var s=this._dp;if(s&&s.smoothChildTiming&&this._ts){for(T1(this,r),!s._dp||s.parent||LN(s,this);s&&s.parent;)s.parent._time!==s._start+(s._ts>=0?s._tTime/s._ts:(s.totalDuration()-s._tTime)/-s._ts)&&s.totalTime(s._tTime,!0),s=s.parent;!this.parent&&this._dp.autoRemoveChildren&&(this._ts>0&&r<this._tDur||this._ts<0&&r>0||!this._tDur&&!r)&&ou(this._dp,this,this._start-this._delay)}return(this._tTime!==r||!this._dur&&!i||this._initted&&Math.abs(this._zTime)===Zi||!r&&!this._initted&&(this.add||this._ptLookup))&&(this._ts||(this._pTime=r),MN(this,r,i)),this},t.time=function(r,i){return arguments.length?this.totalTime(Math.min(this.totalDuration(),r+gL(this))%(this._dur+this._rDelay)||(r?this._dur:0),i):this._time},t.totalProgress=function(r,i){return arguments.length?this.totalTime(this.totalDuration()*r,i):this.totalDuration()?Math.min(1,this._tTime/this._tDur):this.rawTime()>0?1:0},t.progress=function(r,i){return arguments.length?this.totalTime(this.duration()*(this._yoyo&&!(this.iteration()&1)?1-r:r)+gL(this),i):this.duration()?Math.min(1,this._time/this._dur):this.rawTime()>0?1:0},t.iteration=function(r,i){var s=this.duration()+this._rDelay;return arguments.length?this.totalTime(this._time+(r-1)*s,i):this._repeat?cg(this._tTime,s)+1:1},t.timeScale=function(r,i){if(!arguments.length)return this._rts===-Zi?0:this._rts;if(this._rts===r)return this;var s=this.parent&&this._ts?gx(this.parent._time,this):this._tTime;return this._rts=+r||0,this._ts=this._ps||r===-Zi?0:this._rts,this.totalTime(Dv(-Math.abs(this._delay),this._tDur,s),i!==!1),w1(this),One(this)},t.paused=function(r){return arguments.length?(this._ps!==r&&(this._ps=r,r?(this._pTime=this._tTime||Math.max(-this._delay,this.rawTime()),this._ts=this._act=0):(hg(),this._ts=this._rts,this.totalTime(this.parent&&!this.parent.smoothChildTiming?this.rawTime():this._tTime||this._pTime,this.progress()===1&&Math.abs(this._zTime)!==Zi&&(this._tTime-=Zi)))),this):this._ps},t.startTime=function(r){if(arguments.length){this._start=r;var i=this.parent||this._dp;return i&&(i._sort||!this.parent)&&ou(i,this,r-this._delay),this}return this._start},t.endTime=function(r){return this._start+(Fs(r)?this.totalDuration():this.duration())/Math.abs(this._ts||1)},t.rawTime=function(r){var i=this.parent||this._dp;return i?r&&(!this._ts||this._repeat&&this._time&&this.totalProgress()<1)?this._tTime%(this._dur+this._rDelay):this._ts?gx(i.rawTime(r),this):this._tTime:this._tTime},t.revert=function(r){r===void 0&&(r=Ane);var i=ts;return ts=r,(this._initted||this._startAt)&&(this.timeline&&this.timeline.revert(r),this.totalTime(-.01,r.suppressEvents)),this.data!=="nested"&&r.kill!==!1&&this.kill(),ts=i,this},t.globalTime=function(r){for(var i=this,s=arguments.length?r:i.rawTime();i;)s=i._start+s/(Math.abs(i._ts)||1),i=i._dp;return!this.parent&&this._sat?this._sat.globalTime(r):s},t.repeat=function(r){return arguments.length?(this._repeat=r===1/0?-2:r,yL(this)):this._repeat===-2?1/0:this._repeat},t.repeatDelay=function(r){if(arguments.length){var i=this._time;return this._rDelay=r,yL(this),i?this.time(i):this}return this._rDelay},t.yoyo=function(r){return arguments.length?(this._yoyo=r,this):this._yoyo},t.seek=function(r,i){return this.totalTime(zl(this,r),Fs(i))},t.restart=function(r,i){return this.play().totalTime(r?-this._delay:0,Fs(i))},t.play=function(r,i){return r!=null&&this.seek(r,i),this.reversed(!1).paused(!1)},t.reverse=function(r,i){return r!=null&&this.seek(r||this.totalDuration(),i),this.reversed(!0).paused(!1)},t.pause=function(r,i){return r!=null&&this.seek(r,i),this.paused(!0)},t.resume=function(){return this.paused(!1)},t.reversed=function(r){return arguments.length?(!!r!==this.reversed()&&this.timeScale(-this._rts||(r?-Zi:0)),this):this._rts<0},t.invalidate=function(){return this._initted=this._act=0,this._zTime=-Zi,this},t.isActive=function(){var r=this.parent||this._dp,i=this._start,s;return!!(!r||this._ts&&this._initted&&r.isActive()&&(s=r.rawTime(!0))>=i&&s<this.endTime(!0)-Zi)},t.eventCallback=function(r,i,s){var c=this.vars;return arguments.length>1?(i?(c[r]=i,s&&(c[r+"Params"]=s),r==="onUpdate"&&(this._onUpdate=i)):delete c[r],this):c[r]},t.then=function(r){var i=this;return new Promise(function(s){var c=Lo(r)?r:ON,a=function(){var g=i.then;i.then=null,Lo(c)&&(c=c(i))&&(c.then||c===i)&&(i.then=g),s(c),i.then=g};i._initted&&i.totalProgress()===1&&i._ts>=0||!i._tTime&&i._ts<0?a():i._prom=a})},t.kill=function(){i_(this)},e}();Yl(Q_.prototype,{_time:0,_start:0,_end:0,_tTime:0,_tDur:0,_dirty:0,_repeat:0,_yoyo:!1,parent:null,_initted:!1,_rDelay:0,_ts:1,_dp:0,ratio:0,_zTime:-Zi,_prom:0,_ps:!1,_rts:1});var ms=function(e){vN(t,e);function t(r,i){var s;return r===void 0&&(r={}),s=e.call(this,r)||this,s.labels={},s.smoothChildTiming=!!r.smoothChildTiming,s.autoRemoveChildren=!!r.autoRemoveChildren,s._sort=Fs(r.sortChildren),Eo&&ou(r.parent||Eo,Yu(s),i),r.reversed&&s.reverse(),r.paused&&s.paused(!0),r.scrollTrigger&&RN(Yu(s),r.scrollTrigger),s}var n=t.prototype;return n.to=function(i,s,c){return T_(0,arguments,this),this},n.from=function(i,s,c){return T_(1,arguments,this),this},n.fromTo=function(i,s,c,a){return T_(2,arguments,this),this},n.set=function(i,s,c){return s.duration=0,s.parent=this,w_(s).repeatDelay||(s.repeat=0),s.immediateRender=!!s.immediateRender,new Ko(i,s,zl(this,c),1),this},n.call=function(i,s,c){return ou(this,Ko.delayedCall(0,i,s),c)},n.staggerTo=function(i,s,c,a,m,g,x){return c.duration=s,c.stagger=c.stagger||a,c.onComplete=g,c.onCompleteParams=x,c.parent=this,new Ko(i,c,zl(this,m)),this},n.staggerFrom=function(i,s,c,a,m,g,x){return c.runBackwards=1,w_(c).immediateRender=Fs(c.immediateRender),this.staggerTo(i,s,c,a,m,g,x)},n.staggerFromTo=function(i,s,c,a,m,g,x,T){return a.startAt=c,w_(a).immediateRender=Fs(a.immediateRender),this.staggerTo(i,s,a,m,g,x,T)},n.render=function(i,s,c){var a=this._time,m=this._dirty?this.totalDuration():this._tDur,g=this._dur,x=i<=0?0:Ea(i),T=this._zTime<0!=i<0&&(this._initted||!g),C,A,P,D,B,R,N,j,U,W,Q,Z;if(this!==Eo&&x>m&&i>=0&&(x=m),x!==this._tTime||c||T){if(a!==this._time&&g&&(x+=this._time-a,i+=this._time-a),C=x,U=this._start,j=this._ts,R=!j,T&&(g||(a=this._zTime),(i||!s)&&(this._zTime=i)),this._repeat){if(Q=this._yoyo,B=g+this._rDelay,this._repeat<-1&&i<0)return this.totalTime(B*100+i,s,c);if(C=Ea(x%B),x===m?(D=this._repeat,C=g):(D=~~(x/B),D&&D===x/B&&(C=g,D--),C>g&&(C=g)),W=cg(this._tTime,B),!a&&this._tTime&&W!==D&&this._tTime-W*B-this._dur<=0&&(W=D),Q&&D&1&&(C=g-C,Z=1),D!==W&&!this._lock){var K=Q&&W&1,Y=K===(Q&&D&1);if(D<W&&(K=!K),a=K?0:x%g?g:x,this._lock=1,this.render(a||(Z?0:Ea(D*B)),s,!g)._lock=0,this._tTime=x,!s&&this.parent&&fl(this,"onRepeat"),this.vars.repeatRefresh&&!Z&&(this.invalidate()._lock=1),a&&a!==this._time||R!==!this._ts||this.vars.onRepeat&&!this.parent&&!this._act)return this;if(g=this._dur,m=this._tDur,Y&&(this._lock=2,a=K?g:-1e-4,this.render(a,!0),this.vars.repeatRefresh&&!Z&&this.invalidate()),this._lock=0,!this._ts&&!R)return this;XN(this,Z)}}if(this._hasPause&&!this._forcing&&this._lock<2&&(N=Fne(this,Ea(a),Ea(C)),N&&(x-=C-(C=N._start))),this._tTime=x,this._time=C,this._act=!j,this._initted||(this._onUpdate=this.vars.onUpdate,this._initted=1,this._zTime=i,a=0),!a&&C&&!s&&!D&&(fl(this,"onStart"),this._tTime!==x))return this;if(C>=a&&i>=0)for(A=this._first;A;){if(P=A._next,(A._act||C>=A._start)&&A._ts&&N!==A){if(A.parent!==this)return this.render(i,s,c);if(A.render(A._ts>0?(C-A._start)*A._ts:(A._dirty?A.totalDuration():A._tDur)+(C-A._start)*A._ts,s,c),C!==this._time||!this._ts&&!R){N=0,P&&(x+=this._zTime=-Zi);break}}A=P}else{A=this._last;for(var me=i<0?i:C;A;){if(P=A._prev,(A._act||me<=A._end)&&A._ts&&N!==A){if(A.parent!==this)return this.render(i,s,c);if(A.render(A._ts>0?(me-A._start)*A._ts:(A._dirty?A.totalDuration():A._tDur)+(me-A._start)*A._ts,s,c||ts&&(A._initted||A._startAt)),C!==this._time||!this._ts&&!R){N=0,P&&(x+=this._zTime=me?-Zi:Zi);break}}A=P}}if(N&&!s&&(this.pause(),N.render(C>=a?0:-Zi)._zTime=C>=a?1:-1,this._ts))return this._start=U,w1(this),this.render(i,s,c);this._onUpdate&&!s&&fl(this,"onUpdate",!0),(x===m&&this._tTime>=this.totalDuration()||!x&&a)&&(U===this._start||Math.abs(j)!==Math.abs(this._ts))&&(this._lock||((i||!g)&&(x===m&&this._ts>0||!x&&this._ts<0)&&Md(this,1),!s&&!(i<0&&!a)&&(x||a||!m)&&(fl(this,x===m&&i>=0?"onComplete":"onReverseComplete",!0),this._prom&&!(x<m&&this.timeScale()>0)&&this._prom())))}return this},n.add=function(i,s){var c=this;if(oh(s)||(s=zl(this,s,i)),!(i instanceof Q_)){if(ns(i))return i.forEach(function(a){return c.add(a,s)}),this;if(ka(i))return this.addLabel(i,s);if(Lo(i))i=Ko.delayedCall(0,i);else return this}return this!==i?ou(this,i,s):this},n.getChildren=function(i,s,c,a){i===void 0&&(i=!0),s===void 0&&(s=!0),c===void 0&&(c=!0),a===void 0&&(a=-Vl);for(var m=[],g=this._first;g;)g._start>=a&&(g instanceof Ko?s&&m.push(g):(c&&m.push(g),i&&m.push.apply(m,g.getChildren(!0,s,c)))),g=g._next;return m},n.getById=function(i){for(var s=this.getChildren(1,1,1),c=s.length;c--;)if(s[c].vars.id===i)return s[c]},n.remove=function(i){return ka(i)?this.removeLabel(i):Lo(i)?this.killTweensOf(i):(x1(this,i),i===this._recent&&(this._recent=this._last),ap(this))},n.totalTime=function(i,s){return arguments.length?(this._forcing=1,!this._dp&&this._ts&&(this._start=Ea(hl.time-(this._ts>0?i/this._ts:(this.totalDuration()-i)/-this._ts))),e.prototype.totalTime.call(this,i,s),this._forcing=0,this):this._tTime},n.addLabel=function(i,s){return this.labels[i]=zl(this,s),this},n.removeLabel=function(i){return delete this.labels[i],this},n.addPause=function(i,s,c){var a=Ko.delayedCall(0,s||Z_,c);return a.data="isPause",this._hasPause=1,ou(this,a,zl(this,i))},n.removePause=function(i){var s=this._first;for(i=zl(this,i);s;)s._start===i&&s.data==="isPause"&&Md(s),s=s._next},n.killTweensOf=function(i,s,c){for(var a=this.getTweensOf(i,c),m=a.length;m--;)sd!==a[m]&&a[m].kill(i,s);return this},n.getTweensOf=function(i,s){for(var c=[],a=Gl(i),m=this._first,g=oh(s),x;m;)m instanceof Ko?Pne(m._targets,a)&&(g?(!sd||m._initted&&m._ts)&&m.globalTime(0)<=s&&m.globalTime(m.totalDuration())>s:!s||m.isActive())&&c.push(m):(x=m.getTweensOf(a,s)).length&&c.push.apply(c,x),m=m._next;return c},n.tweenTo=function(i,s){s=s||{};var c=this,a=zl(c,i),m=s,g=m.startAt,x=m.onStart,T=m.onStartParams,C=m.immediateRender,A,P=Ko.to(c,Yl({ease:s.ease||"none",lazy:!1,immediateRender:!1,time:a,overwrite:"auto",duration:s.duration||Math.abs((a-(g&&"time"in g?g.time:c._time))/c.timeScale())||Zi,onStart:function(){if(c.pause(),!A){var B=s.duration||Math.abs((a-(g&&"time"in g?g.time:c._time))/c.timeScale());P._dur!==B&&ug(P,B,0,1).render(P._time,!0,!0),A=1}x&&x.apply(P,T||[])}},s));return C?P.render(0):P},n.tweenFromTo=function(i,s,c){return this.tweenTo(s,Yl({startAt:{time:zl(this,i)}},c))},n.recent=function(){return this._recent},n.nextLabel=function(i){return i===void 0&&(i=this._time),_L(this,zl(this,i))},n.previousLabel=function(i){return i===void 0&&(i=this._time),_L(this,zl(this,i),1)},n.currentLabel=function(i){return arguments.length?this.seek(i,!0):this.previousLabel(this._time+Zi)},n.shiftChildren=function(i,s,c){c===void 0&&(c=0);for(var a=this._first,m=this.labels,g;a;)a._start>=c&&(a._start+=i,a._end+=i),a=a._next;if(s)for(g in m)m[g]>=c&&(m[g]+=i);return ap(this)},n.invalidate=function(i){var s=this._first;for(this._lock=0;s;)s.invalidate(i),s=s._next;return e.prototype.invalidate.call(this,i)},n.clear=function(i){i===void 0&&(i=!0);for(var s=this._first,c;s;)c=s._next,this.remove(s),s=c;return this._dp&&(this._time=this._tTime=this._pTime=0),i&&(this.labels={}),ap(this)},n.totalDuration=function(i){var s=0,c=this,a=c._last,m=Vl,g,x,T;if(arguments.length)return c.timeScale((c._repeat<0?c.duration():c.totalDuration())/(c.reversed()?-i:i));if(c._dirty){for(T=c.parent;a;)g=a._prev,a._dirty&&a.totalDuration(),x=a._start,x>m&&c._sort&&a._ts&&!c._lock?(c._lock=1,ou(c,a,x-a._delay,1)._lock=0):m=x,x<0&&a._ts&&(s-=x,(!T&&!c._dp||T&&T.smoothChildTiming)&&(c._start+=x/c._ts,c._time-=x,c._tTime-=x),c.shiftChildren(-x,!1,-1/0),m=0),a._end>s&&a._ts&&(s=a._end),a=g;ug(c,c===Eo&&c._time>s?c._time:s,1,1),c._dirty=0}return c._tDur},t.updateRoot=function(i){if(Eo._ts&&(MN(Eo,gx(i,Eo)),AN=hl.frame),hl.frame>=pL){pL+=ml.autoSleep||120;var s=Eo._first;if((!s||!s._ts)&&ml.autoSleep&&hl._listeners.length<2){for(;s&&!s._ts;)s=s._next;s||hl.sleep()}}},t}(Q_);Yl(ms.prototype,{_lock:0,_hasPause:0,_forcing:0});var Qne=function(t,n,r,i,s,c,a){var m=new zs(this._pt,t,n,0,1,i5,null,s),g=0,x=0,T,C,A,P,D,B,R,N;for(m.b=r,m.e=i,r+="",i+="",(R=~i.indexOf("random("))&&(i=X_(i)),c&&(N=[r,i],c(N,t,n),r=N[0],i=N[1]),C=r.match(GT)||[];T=GT.exec(i);)P=T[0],D=i.substring(g,T.index),A?A=(A+1)%5:D.substr(-5)==="rgba("&&(A=1),P!==C[x++]&&(B=parseFloat(C[x-1])||0,m._pt={_next:m._pt,p:D||x===1?D:",",s:B,c:P.charAt(1)==="="?Vm(B,P)-B:parseFloat(P)-B,m:A&&A<4?Math.round:0},g=GT.lastIndex);return m.c=g<i.length?i.substring(g,i.length):"",m.fp=a,(TN.test(i)||R)&&(m.e=0),this._pt=m,m},g2=function(t,n,r,i,s,c,a,m,g,x){Lo(i)&&(i=i(s||0,t,c));var T=t[n],C=r!=="get"?r:Lo(T)?g?t[n.indexOf("set")||!Lo(t["get"+n.substr(3)])?n:"get"+n.substr(3)](g):t[n]():T,A=Lo(T)?g?rre:n5:_2,P;if(ka(i)&&(~i.indexOf("random(")&&(i=X_(i)),i.charAt(1)==="="&&(P=Vm(C,i)+(Ja(C)||0),(P||P===0)&&(i=P))),!x||C!==i||aC)return!isNaN(C*i)&&i!==""?(P=new zs(this._pt,t,n,+C||0,i-(C||0),typeof T=="boolean"?ore:r5,0,A),g&&(P.fp=g),a&&P.modifier(a,this,t),this._pt=P):(!T&&!(n in t)&&d2(n,i),Qne.call(this,t,n,C,i,A,m||ml.stringFilter,g))},Jne=function(t,n,r,i,s){if(Lo(t)&&(t=E_(t,s,n,r,i)),!yu(t)||t.style&&t.nodeType||ns(t)||xN(t))return ka(t)?E_(t,s,n,r,i):t;var c={},a;for(a in t)c[a]=E_(t[a],s,n,r,i);return c},JN=function(t,n,r,i,s,c){var a,m,g,x;if(ul[t]&&(a=new ul[t]).init(s,a.rawVars?n[t]:Jne(n[t],i,s,c,r),r,i,c)!==!1&&(r._pt=m=new zs(r._pt,s,t,0,1,a.render,a,0,a.priority),r!==Im))for(g=r._ptLookup[r._targets.indexOf(s)],x=a._props.length;x--;)g[a._props[x]]=m;return a},sd,aC,y2=function e(t,n,r){var i=t.vars,s=i.ease,c=i.startAt,a=i.immediateRender,m=i.lazy,g=i.onUpdate,x=i.runBackwards,T=i.yoyoEase,C=i.keyframes,A=i.autoRevert,P=t._dur,D=t._startAt,B=t._targets,R=t.parent,N=R&&R.data==="nested"?R.vars.targets:B,j=t._overwrite==="auto"&&!l2,U=t.timeline,W,Q,Z,K,Y,me,ge,ce,fe,ie,xe,Te,oe;if(U&&(!C||!s)&&(s="none"),t._ease=sp(s,lg.ease),t._yEase=T?ZN(sp(T===!0?s:T,lg.ease)):0,T&&t._yoyo&&!t._repeat&&(T=t._yEase,t._yEase=t._ease,t._ease=T),t._from=!U&&!!i.runBackwards,!U||C&&!i.stagger){if(ce=B[0]?op(B[0]).harness:0,Te=ce&&i[ce.prop],W=mx(i,f2),D&&(D._zTime<0&&D.progress(1),n<0&&x&&a&&!A?D.render(-1,!0):D.revert(x&&P?Ib:kne),D._lazy=0),c){if(Md(t._startAt=Ko.set(B,Yl({data:"isStart",overwrite:!1,parent:R,immediateRender:!0,lazy:!D&&Fs(m),startAt:null,delay:0,onUpdate:g&&function(){return fl(t,"onUpdate")},stagger:0},c))),t._startAt._dp=0,t._startAt._sat=t,n<0&&(ts||!a&&!A)&&t._startAt.revert(Ib),a&&P&&n<=0&&r<=0){n&&(t._zTime=n);return}}else if(x&&P&&!D){if(n&&(a=!1),Z=Yl({overwrite:!1,data:"isFromStart",lazy:a&&!D&&Fs(m),immediateRender:a,stagger:0,parent:R},W),Te&&(Z[ce.prop]=Te),Md(t._startAt=Ko.set(B,Z)),t._startAt._dp=0,t._startAt._sat=t,n<0&&(ts?t._startAt.revert(Ib):t._startAt.render(-1,!0)),t._zTime=n,!a)e(t._startAt,Zi,Zi);else if(!n)return}for(t._pt=t._ptCache=0,m=P&&Fs(m)||m&&!P,Q=0;Q<B.length;Q++){if(Y=B[Q],ge=Y._gsap||m2(B)[Q]._gsap,t._ptLookup[Q]=ie={},eC[ge.id]&&_d.length&&px(),xe=N===B?Q:N.indexOf(Y),ce&&(fe=new ce).init(Y,Te||W,t,xe,N)!==!1&&(t._pt=K=new zs(t._pt,Y,fe.name,0,1,fe.render,fe,0,fe.priority),fe._props.forEach(function(ne){ie[ne]=K}),fe.priority&&(me=1)),!ce||Te)for(Z in W)ul[Z]&&(fe=JN(Z,W,t,xe,Y,N))?fe.priority&&(me=1):ie[Z]=K=g2.call(t,Y,Z,"get",W[Z],xe,N,0,i.stringFilter);t._op&&t._op[Q]&&t.kill(Y,t._op[Q]),j&&t._pt&&(sd=t,Eo.killTweensOf(Y,ie,t.globalTime(n)),oe=!t.parent,sd=0),t._pt&&m&&(eC[ge.id]=1)}me&&o5(t),t._onInit&&t._onInit(t)}t._onUpdate=g,t._initted=(!t._op||t._pt)&&!oe,C&&n<=0&&U.render(Vl,!0,!0)},ere=function(t,n,r,i,s,c,a,m){var g=(t._pt&&t._ptCache||(t._ptCache={}))[n],x,T,C,A;if(!g)for(g=t._ptCache[n]=[],C=t._ptLookup,A=t._targets.length;A--;){if(x=C[A][n],x&&x.d&&x.d._pt)for(x=x.d._pt;x&&x.p!==n&&x.fp!==n;)x=x._next;if(!x)return aC=1,t.vars[n]="+=0",y2(t,a),aC=0,m?Y_(n+" not eligible for reset"):1;g.push(x)}for(A=g.length;A--;)T=g[A],x=T._pt||T,x.s=(i||i===0)&&!s?i:x.s+(i||0)+c*x.c,x.c=r-x.s,T.e&&(T.e=No(r)+Ja(T.e)),T.b&&(T.b=x.s+Ja(T.b))},tre=function(t,n){var r=t[0]?op(t[0]).harness:0,i=r&&r.aliases,s,c,a,m;if(!i)return n;s=mp({},n);for(c in i)if(c in s)for(m=i[c].split(","),a=m.length;a--;)s[m[a]]=s[c];return s},nre=function(t,n,r,i){var s=n.ease||i||"power1.inOut",c,a;if(ns(n))a=r[t]||(r[t]=[]),n.forEach(function(m,g){return a.push({t:g/(n.length-1)*100,v:m,e:s})});else for(c in n)a=r[c]||(r[c]=[]),c==="ease"||a.push({t:parseFloat(t),v:n[c],e:s})},E_=function(t,n,r,i,s){return Lo(t)?t.call(n,r,i,s):ka(t)&&~t.indexOf("random(")?X_(t):t},e5=p2+"repeat,repeatDelay,yoyo,repeatRefresh,yoyoEase,autoRevert",t5={};Bs(e5+",id,stagger,delay,duration,paused,scrollTrigger",function(e){return t5[e]=1});var Ko=function(e){vN(t,e);function t(r,i,s,c){var a;typeof i=="number"&&(s.duration=i,i=s,s=null),a=e.call(this,c?i:w_(i))||this;var m=a.vars,g=m.duration,x=m.delay,T=m.immediateRender,C=m.stagger,A=m.overwrite,P=m.keyframes,D=m.defaults,B=m.scrollTrigger,R=m.yoyoEase,N=i.parent||Eo,j=(ns(r)||xN(r)?oh(r[0]):"length"in i)?[r]:Gl(r),U,W,Q,Z,K,Y,me,ge;if(a._targets=j.length?m2(j):Y_("GSAP target "+r+" not found. https://gsap.com",!ml.nullTargetWarn)||[],a._ptLookup=[],a._overwrite=A,P||C||sb(g)||sb(x)){if(i=a.vars,U=a.timeline=new ms({data:"nested",defaults:D||{},targets:N&&N.data==="nested"?N.vars.targets:j}),U.kill(),U.parent=U._dp=Yu(a),U._start=0,C||sb(g)||sb(x)){if(Z=j.length,me=C&&NN(C),yu(C))for(K in C)~e5.indexOf(K)&&(ge||(ge={}),ge[K]=C[K]);for(W=0;W<Z;W++)Q=mx(i,t5),Q.stagger=0,R&&(Q.yoyoEase=R),ge&&mp(Q,ge),Y=j[W],Q.duration=+E_(g,Yu(a),W,Y,j),Q.delay=(+E_(x,Yu(a),W,Y,j)||0)-a._delay,!C&&Z===1&&Q.delay&&(a._delay=x=Q.delay,a._start+=x,Q.delay=0),U.to(Y,Q,me?me(W,Y,j):0),U._ease=jr.none;U.duration()?g=x=0:a.timeline=0}else if(P){w_(Yl(U.vars.defaults,{ease:"none"})),U._ease=sp(P.ease||i.ease||"none");var ce=0,fe,ie,xe;if(ns(P))P.forEach(function(Te){return U.to(j,Te,">")}),U.duration();else{Q={};for(K in P)K==="ease"||K==="easeEach"||nre(K,P[K],Q,P.easeEach);for(K in Q)for(fe=Q[K].sort(function(Te,oe){return Te.t-oe.t}),ce=0,W=0;W<fe.length;W++)ie=fe[W],xe={ease:ie.e,duration:(ie.t-(W?fe[W-1].t:0))/100*g},xe[K]=ie.v,U.to(j,xe,ce),ce+=xe.duration;U.duration()<g&&U.to({},{duration:g-U.duration()})}}g||a.duration(g=U.duration())}else a.timeline=0;return A===!0&&!l2&&(sd=Yu(a),Eo.killTweensOf(j),sd=0),ou(N,Yu(a),s),i.reversed&&a.reverse(),i.paused&&a.paused(!0),(T||!g&&!P&&a._start===Ea(N._time)&&Fs(T)&&Dne(Yu(a))&&N.data!=="nested")&&(a._tTime=-Zi,a.render(Math.max(0,-x)||0)),B&&RN(Yu(a),B),a}var n=t.prototype;return n.render=function(i,s,c){var a=this._time,m=this._tDur,g=this._dur,x=i<0,T=i>m-Zi&&!x?m:i<Zi?0:i,C,A,P,D,B,R,N,j,U;if(!g)Rne(this,i,s,c);else if(T!==this._tTime||!i||c||!this._initted&&this._tTime||this._startAt&&this._zTime<0!==x){if(C=T,j=this.timeline,this._repeat){if(D=g+this._rDelay,this._repeat<-1&&x)return this.totalTime(D*100+i,s,c);if(C=Ea(T%D),T===m?(P=this._repeat,C=g):(P=~~(T/D),P&&P===Ea(T/D)&&(C=g,P--),C>g&&(C=g)),R=this._yoyo&&P&1,R&&(U=this._yEase,C=g-C),B=cg(this._tTime,D),C===a&&!c&&this._initted&&P===B)return this._tTime=T,this;P!==B&&(j&&this._yEase&&XN(j,R),this.vars.repeatRefresh&&!R&&!this._lock&&this._time!==D&&this._initted&&(this._lock=c=1,this.render(Ea(D*P),!0).invalidate()._lock=0))}if(!this._initted){if(FN(this,x?i:C,c,s,T))return this._tTime=0,this;if(a!==this._time&&!(c&&this.vars.repeatRefresh&&P!==B))return this;if(g!==this._dur)return this.render(i,s,c)}if(this._tTime=T,this._time=C,!this._act&&this._ts&&(this._act=1,this._lazy=0),this.ratio=N=(U||this._ease)(C/g),this._from&&(this.ratio=N=1-N),C&&!a&&!s&&!P&&(fl(this,"onStart"),this._tTime!==T))return this;for(A=this._pt;A;)A.r(N,A.d),A=A._next;j&&j.render(i<0?i:j._dur*j._ease(C/this._dur),s,c)||this._startAt&&(this._zTime=i),this._onUpdate&&!s&&(x&&tC(this,i,s,c),fl(this,"onUpdate")),this._repeat&&P!==B&&this.vars.onRepeat&&!s&&this.parent&&fl(this,"onRepeat"),(T===this._tDur||!T)&&this._tTime===T&&(x&&!this._onUpdate&&tC(this,i,!0,!0),(i||!g)&&(T===this._tDur&&this._ts>0||!T&&this._ts<0)&&Md(this,1),!s&&!(x&&!a)&&(T||a||R)&&(fl(this,T===m?"onComplete":"onReverseComplete",!0),this._prom&&!(T<m&&this.timeScale()>0)&&this._prom()))}return this},n.targets=function(){return this._targets},n.invalidate=function(i){return(!i||!this.vars.runBackwards)&&(this._startAt=0),this._pt=this._op=this._onUpdate=this._lazy=this.ratio=0,this._ptLookup=[],this.timeline&&this.timeline.invalidate(i),e.prototype.invalidate.call(this,i)},n.resetTo=function(i,s,c,a,m){K_||hl.wake(),this._ts||this.play();var g=Math.min(this._dur,(this._dp._time-this._start)*this._ts),x;return this._initted||y2(this,g),x=this._ease(g/this._dur),ere(this,i,s,c,a,x,g,m)?this.resetTo(i,s,c,a,1):(T1(this,0),this.parent||DN(this._dp,this,"_first","_last",this._dp._sort?"_start":0),this.render(0))},n.kill=function(i,s){if(s===void 0&&(s="all"),!i&&(!s||s==="all"))return this._lazy=this._pt=0,this.parent?i_(this):this;if(this.timeline){var c=this.timeline.totalDuration();return this.timeline.killTweensOf(i,s,sd&&sd.vars.overwrite!==!0)._first||i_(this),this.parent&&c!==this.timeline.totalDuration()&&ug(this,this._dur*this.timeline._tDur/c,0,1),this}var a=this._targets,m=i?Gl(i):a,g=this._ptLookup,x=this._pt,T,C,A,P,D,B,R;if((!s||s==="all")&&Ine(a,m))return s==="all"&&(this._pt=0),i_(this);for(T=this._op=this._op||[],s!=="all"&&(ka(s)&&(D={},Bs(s,function(N){return D[N]=1}),s=D),s=tre(a,s)),R=a.length;R--;)if(~m.indexOf(a[R])){C=g[R],s==="all"?(T[R]=s,P=C,A={}):(A=T[R]=T[R]||{},P=s);for(D in P)B=C&&C[D],B&&((!("kill"in B.d)||B.d.kill(D)===!0)&&x1(this,B,"_pt"),delete C[D]),A!=="all"&&(A[D]=1)}return this._initted&&!this._pt&&x&&i_(this),this},t.to=function(i,s){return new t(i,s,arguments[2])},t.from=function(i,s){return T_(1,arguments)},t.delayedCall=function(i,s,c,a){return new t(s,0,{immediateRender:!1,lazy:!1,overwrite:!1,delay:i,onComplete:s,onReverseComplete:s,onCompleteParams:c,onReverseCompleteParams:c,callbackScope:a})},t.fromTo=function(i,s,c){return T_(2,arguments)},t.set=function(i,s){return s.duration=0,s.repeatDelay||(s.repeat=0),new t(i,s)},t.killTweensOf=function(i,s,c){return Eo.killTweensOf(i,s,c)},t}(Q_);Yl(Ko.prototype,{_targets:[],_lazy:0,_startAt:0,_op:0,_onInit:0});Bs("staggerTo,staggerFrom,staggerFromTo",function(e){Ko[e]=function(){var t=new ms,n=rC.call(arguments,0);return n.splice(e==="staggerFromTo"?5:4,0,0),t[e].apply(t,n)}});var _2=function(t,n,r){return t[n]=r},n5=function(t,n,r){return t[n](r)},rre=function(t,n,r,i){return t[n](i.fp,r)},ire=function(t,n,r){return t.setAttribute(n,r)},v2=function(t,n){return Lo(t[n])?n5:c2(t[n])&&t.setAttribute?ire:_2},r5=function(t,n){return n.set(n.t,n.p,Math.round((n.s+n.c*t)*1e6)/1e6,n)},ore=function(t,n){return n.set(n.t,n.p,!!(n.s+n.c*t),n)},i5=function(t,n){var r=n._pt,i="";if(!t&&n.b)i=n.b;else if(t===1&&n.e)i=n.e;else{for(;r;)i=r.p+(r.m?r.m(r.s+r.c*t):Math.round((r.s+r.c*t)*1e4)/1e4)+i,r=r._next;i+=n.c}n.set(n.t,n.p,i,n)},b2=function(t,n){for(var r=n._pt;r;)r.r(t,r.d),r=r._next},are=function(t,n,r,i){for(var s=this._pt,c;s;)c=s._next,s.p===i&&s.modifier(t,n,r),s=c},sre=function(t){for(var n=this._pt,r,i;n;)i=n._next,n.p===t&&!n.op||n.op===t?x1(this,n,"_pt"):n.dep||(r=1),n=i;return!r},lre=function(t,n,r,i){i.mSet(t,n,i.m.call(i.tween,r,i.mt),i)},o5=function(t){for(var n=t._pt,r,i,s,c;n;){for(r=n._next,i=s;i&&i.pr>n.pr;)i=i._next;(n._prev=i?i._prev:c)?n._prev._next=n:s=n,(n._next=i)?i._prev=n:c=n,n=r}t._pt=s},zs=function(){function e(n,r,i,s,c,a,m,g,x){this.t=r,this.s=s,this.c=c,this.p=i,this.r=a||r5,this.d=m||this,this.set=g||_2,this.pr=x||0,this._next=n,n&&(n._prev=this)}var t=e.prototype;return t.modifier=function(r,i,s){this.mSet=this.mSet||this.set,this.set=lre,this.m=r,this.mt=s,this.tween=i},e}();Bs(p2+"parent,duration,ease,delay,overwrite,runBackwards,startAt,yoyo,immediateRender,repeat,repeatDelay,data,paused,reversed,lazy,callbackScope,stringFilter,id,yoyoEase,stagger,inherit,repeatRefresh,keyframes,autoRevert,scrollTrigger",function(e){return f2[e]=1});yl.TweenMax=yl.TweenLite=Ko;yl.TimelineLite=yl.TimelineMax=ms;Eo=new ms({sortChildren:!1,defaults:lg,autoRemoveChildren:!0,id:"root",smoothChildTiming:!0});ml.stringFilter=YN;var lp=[],Db={},cre=[],bL=0,ure=0,ZT=function(t){return(Db[t]||cre).map(function(n){return n()})},sC=function(){var t=Date.now(),n=[];t-bL>2&&(ZT("matchMediaInit"),lp.forEach(function(r){var i=r.queries,s=r.conditions,c,a,m,g;for(a in i)c=ru.matchMedia(i[a]).matches,c&&(m=1),c!==s[a]&&(s[a]=c,g=1);g&&(r.revert(),m&&n.push(r))}),ZT("matchMediaRevert"),n.forEach(function(r){return r.onMatch(r,function(i){return r.add(null,i)})}),bL=t,ZT("matchMedia"))},a5=function(){function e(n,r){this.selector=r&&iC(r),this.data=[],this._r=[],this.isReverted=!1,this.id=ure++,n&&this.add(n)}var t=e.prototype;return t.add=function(r,i,s){Lo(r)&&(s=i,i=r,r=Lo);var c=this,a=function(){var g=uo,x=c.selector,T;return g&&g!==c&&g.data.push(c),s&&(c.selector=iC(s)),uo=c,T=i.apply(c,arguments),Lo(T)&&c._r.push(T),uo=g,c.selector=x,c.isReverted=!1,T};return c.last=a,r===Lo?a(c,function(m){return c.add(null,m)}):r?c[r]=a:a},t.ignore=function(r){var i=uo;uo=null,r(this),uo=i},t.getTweens=function(){var r=[];return this.data.forEach(function(i){return i instanceof e?r.push.apply(r,i.getTweens()):i instanceof Ko&&!(i.parent&&i.parent.data==="nested")&&r.push(i)}),r},t.clear=function(){this._r.length=this.data.length=0},t.kill=function(r,i){var s=this;if(r?function(){for(var a=s.getTweens(),m=s.data.length,g;m--;)g=s.data[m],g.data==="isFlip"&&(g.revert(),g.getChildren(!0,!0,!1).forEach(function(x){return a.splice(a.indexOf(x),1)}));for(a.map(function(x){return{g:x._dur||x._delay||x._sat&&!x._sat.vars.immediateRender?x.globalTime(0):-1/0,t:x}}).sort(function(x,T){return T.g-x.g||-1/0}).forEach(function(x){return x.t.revert(r)}),m=s.data.length;m--;)g=s.data[m],g instanceof ms?g.data!=="nested"&&(g.scrollTrigger&&g.scrollTrigger.revert(),g.kill()):!(g instanceof Ko)&&g.revert&&g.revert(r);s._r.forEach(function(x){return x(r,s)}),s.isReverted=!0}():this.data.forEach(function(a){return a.kill&&a.kill()}),this.clear(),i)for(var c=lp.length;c--;)lp[c].id===this.id&&lp.splice(c,1)},t.revert=function(r){this.kill(r||{})},e}(),hre=function(){function e(n){this.contexts=[],this.scope=n,uo&&uo.data.push(this)}var t=e.prototype;return t.add=function(r,i,s){yu(r)||(r={matches:r});var c=new a5(0,s||this.scope),a=c.conditions={},m,g,x;uo&&!c.selector&&(c.selector=uo.selector),this.contexts.push(c),i=c.add("onMatch",i),c.queries=r;for(g in r)g==="all"?x=1:(m=ru.matchMedia(r[g]),m&&(lp.indexOf(c)<0&&lp.push(c),(a[g]=m.matches)&&(x=1),m.addListener?m.addListener(sC):m.addEventListener("change",sC)));return x&&i(c,function(T){return c.add(null,T)}),this},t.revert=function(r){this.kill(r||{})},t.kill=function(r){this.contexts.forEach(function(i){return i.kill(r,!0)})},e}(),yx={registerPlugin:function(){for(var t=arguments.length,n=new Array(t),r=0;r<t;r++)n[r]=arguments[r];n.forEach(function(i){return qN(i)})},timeline:function(t){return new ms(t)},getTweensOf:function(t,n){return Eo.getTweensOf(t,n)},getProperty:function(t,n,r,i){ka(t)&&(t=Gl(t)[0]);var s=op(t||{}).get,c=r?ON:IN;return r==="native"&&(r=""),t&&(n?c((ul[n]&&ul[n].get||s)(t,n,r,i)):function(a,m,g){return c((ul[a]&&ul[a].get||s)(t,a,m,g))})},quickSetter:function(t,n,r){if(t=Gl(t),t.length>1){var i=t.map(function(x){return Gs.quickSetter(x,n,r)}),s=i.length;return function(x){for(var T=s;T--;)i[T](x)}}t=t[0]||{};var c=ul[n],a=op(t),m=a.harness&&(a.harness.aliases||{})[n]||n,g=c?function(x){var T=new c;Im._pt=0,T.init(t,r?x+r:x,Im,0,[t]),T.render(1,T),Im._pt&&b2(1,Im)}:a.set(t,m);return c?g:function(x){return g(t,m,r?x+r:x,a,1)}},quickTo:function(t,n,r){var i,s=Gs.to(t,mp((i={},i[n]="+=0.1",i.paused=!0,i),r||{})),c=function(m,g,x){return s.resetTo(n,m,g,x)};return c.tween=s,c},isTweening:function(t){return Eo.getTweensOf(t,!0).length>0},defaults:function(t){return t&&t.ease&&(t.ease=sp(t.ease,lg.ease)),mL(lg,t||{})},config:function(t){return mL(ml,t||{})},registerEffect:function(t){var n=t.name,r=t.effect,i=t.plugins,s=t.defaults,c=t.extendTimeline;(i||"").split(",").forEach(function(a){return a&&!ul[a]&&!yl[a]&&Y_(n+" effect requires "+a+" plugin.")}),qT[n]=function(a,m,g){return r(Gl(a),Yl(m||{},s),g)},c&&(ms.prototype[n]=function(a,m,g){return this.add(qT[n](a,yu(m)?m:(g=m)&&{},this),g)})},registerEase:function(t,n){jr[t]=sp(n)},parseEase:function(t,n){return arguments.length?sp(t,n):jr},getById:function(t){return Eo.getById(t)},exportRoot:function(t,n){t===void 0&&(t={});var r=new ms(t),i,s;for(r.smoothChildTiming=Fs(t.smoothChildTiming),Eo.remove(r),r._dp=0,r._time=r._tTime=Eo._time,i=Eo._first;i;)s=i._next,(n||!(!i._dur&&i instanceof Ko&&i.vars.onComplete===i._targets[0]))&&ou(r,i,i._start-i._delay),i=s;return ou(Eo,r,0),r},context:function(t,n){return t?new a5(t,n):uo},matchMedia:function(t){return new hre(t)},matchMediaRefresh:function(){return lp.forEach(function(t){var n=t.conditions,r,i;for(i in n)n[i]&&(n[i]=!1,r=1);r&&t.revert()})||sC()},addEventListener:function(t,n){var r=Db[t]||(Db[t]=[]);~r.indexOf(n)||r.push(n)},removeEventListener:function(t,n){var r=Db[t],i=r&&r.indexOf(n);i>=0&&r.splice(i,1)},utils:{wrap:Vne,wrapYoyo:Gne,distribute:NN,random:jN,snap:$N,normalize:Une,getUnit:Ja,clamp:zne,splitColor:WN,toArray:Gl,selector:iC,mapRange:VN,pipe:$ne,unitize:jne,interpolate:qne,shuffle:zN},install:CN,effects:qT,ticker:hl,updateRoot:ms.updateRoot,plugins:ul,globalTimeline:Eo,core:{PropTween:zs,globals:kN,Tween:Ko,Timeline:ms,Animation:Q_,getCache:op,_removeLinkedListItem:x1,reverting:function(){return ts},context:function(t){return t&&uo&&(uo.data.push(t),t._ctx=uo),uo},suppressOverwrites:function(t){return l2=t}}};Bs("to,from,fromTo,delayedCall,set,killTweensOf",function(e){return yx[e]=Ko[e]});hl.add(ms.updateRoot);Im=yx.to({},{duration:0});var dre=function(t,n){for(var r=t._pt;r&&r.p!==n&&r.op!==n&&r.fp!==n;)r=r._next;return r},fre=function(t,n){var r=t._targets,i,s,c;for(i in n)for(s=r.length;s--;)c=t._ptLookup[s][i],c&&(c=c.d)&&(c._pt&&(c=dre(c,i)),c&&c.modifier&&c.modifier(n[i],t,r[s],i))},XT=function(t,n){return{name:t,rawVars:1,init:function(i,s,c){c._onInit=function(a){var m,g;if(ka(s)&&(m={},Bs(s,function(x){return m[x]=1}),s=m),n){m={};for(g in s)m[g]=n(s[g]);s=m}fre(a,s)}}}},Gs=yx.registerPlugin({name:"attr",init:function(t,n,r,i,s){var c,a,m;this.tween=r;for(c in n)m=t.getAttribute(c)||"",a=this.add(t,"setAttribute",(m||0)+"",n[c],i,s,0,0,c),a.op=c,a.b=m,this._props.push(c)},render:function(t,n){for(var r=n._pt;r;)ts?r.set(r.t,r.p,r.b,r):r.r(t,r.d),r=r._next}},{name:"endArray",init:function(t,n){for(var r=n.length;r--;)this.add(t,r,t[r]||0,n[r],0,0,0,0,0,1)}},XT("roundProps",oC),XT("modifiers"),XT("snap",$N))||yx;Ko.version=ms.version=Gs.version="3.12.5";SN=1;u2()&&hg();jr.Power0;jr.Power1;jr.Power2;jr.Power3;jr.Power4;jr.Linear;jr.Quad;jr.Cubic;jr.Quart;jr.Quint;jr.Strong;jr.Elastic;jr.Back;jr.SteppedEase;jr.Bounce;jr.Sine;jr.Expo;jr.Circ;/*!
95 * CSSPlugin 3.12.5
96 * https://gsap.com
97 *
98 * Copyright 2008-2024, GreenSock. All rights reserved.
99 * Subject to the terms at https://gsap.com/standard-license or for
100 * Club GSAP members, the agreement issued with that membership.
101 * @author: Jack Doyle, [email protected]
102*/var xL,ld,Gm,x2,Kf,wL,w2,pre=function(){return typeof window<"u"},ah={},jf=180/Math.PI,qm=Math.PI/180,mm=Math.atan2,TL=1e8,T2=/([A-Z])/g,mre=/(left|right|width|margin|padding|x)/i,gre=/[\s,\(]\S/,cu={autoAlpha:"opacity,visibility",scale:"scaleX,scaleY",alpha:"opacity"},lC=function(t,n){return n.set(n.t,n.p,Math.round((n.s+n.c*t)*1e4)/1e4+n.u,n)},yre=function(t,n){return n.set(n.t,n.p,t===1?n.e:Math.round((n.s+n.c*t)*1e4)/1e4+n.u,n)},_re=function(t,n){return n.set(n.t,n.p,t?Math.round((n.s+n.c*t)*1e4)/1e4+n.u:n.b,n)},vre=function(t,n){var r=n.s+n.c*t;n.set(n.t,n.p,~~(r+(r<0?-.5:.5))+n.u,n)},s5=function(t,n){return n.set(n.t,n.p,t?n.e:n.b,n)},l5=function(t,n){return n.set(n.t,n.p,t!==1?n.b:n.e,n)},bre=function(t,n,r){return t.style[n]=r},xre=function(t,n,r){return t.style.setProperty(n,r)},wre=function(t,n,r){return t._gsap[n]=r},Tre=function(t,n,r){return t._gsap.scaleX=t._gsap.scaleY=r},Ere=function(t,n,r,i,s){var c=t._gsap;c.scaleX=c.scaleY=r,c.renderTransform(s,c)},Sre=function(t,n,r,i,s){var c=t._gsap;c[n]=r,c.renderTransform(s,c)},So="transform",Ns=So+"Origin",Cre=function e(t,n){var r=this,i=this.target,s=i.style,c=i._gsap;if(t in ah&&s){if(this.tfm=this.tfm||{},t!=="transform")t=cu[t]||t,~t.indexOf(",")?t.split(",").forEach(function(a){return r.tfm[a]=Zu(i,a)}):this.tfm[t]=c.x?c[t]:Zu(i,t),t===Ns&&(this.tfm.zOrigin=c.zOrigin);else return cu.transform.split(",").forEach(function(a){return e.call(r,a,n)});if(this.props.indexOf(So)>=0)return;c.svg&&(this.svgo=i.getAttribute("data-svg-origin"),this.props.push(Ns,n,"")),t=So}(s||n)&&this.props.push(t,n,s[t])},c5=function(t){t.translate&&(t.removeProperty("translate"),t.removeProperty("scale"),t.removeProperty("rotate"))},kre=function(){var t=this.props,n=this.target,r=n.style,i=n._gsap,s,c;for(s=0;s<t.length;s+=3)t[s+1]?n[t[s]]=t[s+2]:t[s+2]?r[t[s]]=t[s+2]:r.removeProperty(t[s].substr(0,2)==="--"?t[s]:t[s].replace(T2,"-$1").toLowerCase());if(this.tfm){for(c in this.tfm)i[c]=this.tfm[c];i.svg&&(i.renderTransform(),n.setAttribute("data-svg-origin",this.svgo||"")),s=w2(),(!s||!s.isStart)&&!r[So]&&(c5(r),i.zOrigin&&r[Ns]&&(r[Ns]+=" "+i.zOrigin+"px",i.zOrigin=0,i.renderTransform()),i.uncache=1)}},u5=function(t,n){var r={target:t,props:[],revert:kre,save:Cre};return t._gsap||Gs.core.getCache(t),n&&n.split(",").forEach(function(i){return r.s
vendor: 6,605 bytes, line 102
102ave(i)}),r},h5,cC=function(t,n){var r=ld.createElementNS?ld.createElementNS((n||"http://www.w3.org/1999/xhtml").replace(/^https/,"http"),t):ld.createElement(t);return r&&r.style?r:ld.createElement(t)},hu=function e(t,n,r){var i=getComputedStyle(t);return i[n]||i.getPropertyValue(n.replace(T2,"-$1").toLowerCase())||i.getPropertyValue(n)||!r&&e(t,dg(n)||n,1)||""},EL="O,Moz,ms,Ms,Webkit".split(","),dg=function(t,n,r){var i=n||Kf,s=i.style,c=5;if(t in s&&!r)return t;for(t=t.charAt(0).toUpperCase()+t.substr(1);c--&&!(EL[c]+t in s););return c<0?null:(c===3?"ms":c>=0?EL[c]:"")+t},uC=function(){pre()&&window.document&&(xL=window,ld=xL.document,Gm=ld.documentElement,Kf=cC("div")||{style:{}},cC("div"),So=dg(So),Ns=So+"Origin",Kf.style.cssText="border-width:0;line-height:0;position:absolute;padding:0",h5=!!dg("perspective"),w2=Gs.core.reverting,x2=1)},KT=function e(t){var n=cC("svg",this.ownerSVGElement&&this.ownerSVGElement.getAttribute("xmlns")||"http://www.w3.org/2000/svg"),r=this.parentNode,i=this.nextSibling,s=this.style.cssText,c;if(Gm.appendChild(n),n.appendChild(this),this.style.display="block",t)try{c=this.getBBox(),this._gsapBBox=this.getBBox,this.getBBox=e}catch{}else this._gsapBBox&&(c=this._gsapBBox());return r&&(i?r.insertBefore(this,i):r.appendChild(this)),Gm.removeChild(n),this.style.cssText=s,c},SL=function(t,n){for(var r=n.length;r--;)if(t.hasAttribute(n[r]))return t.getAttribute(n[r])},d5=function(t){var n;try{n=t.getBBox()}catch{n=KT.call(t,!0)}return n&&(n.width||n.height)||t.getBBox===KT||(n=KT.call(t,!0)),n&&!n.width&&!n.x&&!n.y?{x:+SL(t,["x","cx","x1"])||0,y:+SL(t,["y","cy","y1"])||0,width:0,height:0}:n},f5=function(t){return!!(t.getCTM&&(!t.parentNode||t.ownerSVGElement)&&d5(t))},gp=function(t,n){if(n){var r=t.style,i;n in ah&&n!==Ns&&(n=So),r.removeProperty?(i=n.substr(0,2),(i==="ms"||n.substr(0,6)==="webkit")&&(n="-"+n),r.removeProperty(i==="--"?n:n.replace(T2,"-$1").toLowerCase())):r.removeAttribute(n)}},cd=function(t,n,r,i,s,c){var a=new zs(t._pt,n,r,0,1,c?l5:s5);return t._pt=a,a.b=i,a.e=s,t._props.push(r),a},CL={deg:1,rad:1,turn:1},Are={grid:1,flex:1},Id=function e(t,n,r,i){var s=parseFloat(r)||0,c=(r+"").trim().substr((s+"").length)||"px",a=Kf.style,m=mre.test(n),g=t.tagName.toLowerCase()==="svg",x=(g?"client":"offset")+(m?"Width":"Height"),T=100,C=i==="px",A=i==="%",P,D,B,R;if(i===c||!s||CL[i]||CL[c])return s;if(c!=="px"&&!C&&(s=e(t,n,r,"px")),R=t.getCTM&&f5(t),(A||c==="%")&&(ah[n]||~n.indexOf("adius")))return P=R?t.getBBox()[m?"width":"height"]:t[x],No(A?s/P*T:s/100*P);if(a[m?"width":"height"]=T+(C?c:i),D=~n.indexOf("adius")||i==="em"&&t.appendChild&&!g?t:t.parentNode,R&&(D=(t.ownerSVGElement||{}).parentNode),(!D||D===ld||!D.appendChild)&&(D=ld.body),B=D._gsap,B&&A&&B.width&&m&&B.time===hl.time&&!B.uncache)return No(s/B.width*T);if(A&&(n==="height"||n==="width")){var N=t.style[n];t.style[n]=T+i,P=t[x],N?t.style[n]=N:gp(t,n)}else(A||c==="%")&&!Are[hu(D,"display")]&&(a.position=hu(t,"position")),D===t&&(a.position="static"),D.appendChild(Kf),P=Kf[x],D.removeChild(Kf),a.position="absolute";return m&&A&&(B=op(D),B.time=hl.time,B.width=D[x]),No(C?P*s/T:P&&s?T/P*s:0)},Zu=function(t,n,r,i){var s;return x2||uC(),n in cu&&n!=="transform"&&(n=cu[n],~n.indexOf(",")&&(n=n.split(",")[0])),ah[n]&&n!=="transform"?(s=ev(t,i),s=n!=="transformOrigin"?s[n]:s.svg?s.origin:vx(hu(t,Ns))+" "+s.zOrigin+"px"):(s=t.style[n],(!s||s==="auto"||i||~(s+"").indexOf("calc("))&&(s=_x[n]&&_x[n](t,n,r)||hu(t,n)||PN(t,n)||(n==="opacity"?1:0))),r&&!~(s+"").trim().indexOf(" ")?Id(t,n,s,r)+r:s},Pre=function(t,n,r,i){if(!r||r==="none"){var s=dg(n,t,1),c=s&&hu(t,s,1);c&&c!==r?(n=s,r=c):n==="borderColor"&&(r=hu(t,"borderTopColor"))}var a=new zs(this._pt,t.style,n,0,1,i5),m=0,g=0,x,T,C,A,P,D,B,R,N,j,U,W;if(a.b=r,a.e=i,r+="",i+="",i==="auto"&&(D=t.style[n],t.style[n]=i,i=hu(t,n)||i,D?t.style[n]=D:gp(t,n)),x=[r,i],YN(x),r=x[0],i=x[1],C=r.match(Mm)||[],W=i.match(Mm)||[],W.length){for(;T=Mm.exec(i);)B=T[0],N=i.substring(m,T.index),P?P=(P+1)%5:(N.substr(-5)==="rgba("||N.substr(-5)==="hsla(")&&(P=1),B!==(D=C[g++]||"")&&(A=parseFloat(D)||0,U=D.substr((A+"").length),B.charAt(1)==="="&&(B=Vm(A,B)+U),R=parseFloat(B),j=B.substr((R+"").length),m=Mm.lastIndex-j.length,j||(j=j||ml.units[n]||U,m===i.length&&(i+=j,a.e+=j)),U!==j&&(A=Id(t,n,D,j)||0),a._pt={_next:a._pt,p:N||g===1?N:",",s:A,c:R-A,m:P&&P<4||n==="zIndex"?Math.round:0});a.c=m<i.length?i.substring(m,i.length):""}else a.r=n==="display"&&i==="none"?l5:s5;return TN.test(i)&&(a.e=0),this._pt=a,a},kL={top:"0%",bottom:"100%",left:"0%",right:"100%",center:"50%"},Mre=function(t){var n=t.split(" "),r=n[0],i=n[1]||"50%";return(r==="top"||r==="bottom"||i==="left"||i==="right")&&(t=r,r=i,i=t),n[0]=kL[r]||r,n[1]=kL[i]||i,n.join(" ")},Ire=function(t,n){if(n.tween&&n.tween._time===n.tween._dur){var r=n.t,i=r.style,s=n.u,c=r._gsap,a,m,g;if(s==="all"||s===!0)i.cssText="",m=1;else for(s=s.split(","),g=s.length;--g>-1;)a=s[g],ah[a]&&(m=1,a=a==="transformOrigin"?Ns:So),gp(r,a);m&&(gp(r,So),c&&(c.svg&&r.removeAttribute("transform"),ev(r,1),c.uncache=1,c5(i)))}},_x={clearProps:function(t,n,r,i,s){if(s.data!=="isFromStart"){var c=t._pt=new zs(t._pt,n,r,0,0,Ire);return c.u=i,c.pr=-10,c.tween=s,t._props.push(r),1}}},J_=[1,0,0,1,0,0],p5={},m5=function(t){return t==="matrix(1, 0, 0, 1, 0, 0)"||t==="none"||!t},AL=function(t){var n=hu(t,So);return m5(n)?J_:n.substr(7).match(wN).map(No)},E2=function(t,n){var r=t._gsap||op(t),i=t.style,s=AL(t),c,a,m,g;return r.svg&&t.getAttribute("transform")?(m=t.transform.baseVal.consolidate().matrix,s=[m.a,m.b,m.c,m.d,m.e,m.f],s.join(",")==="1,0,0,1,0,0"?J_:s):(s===J_&&!t.offsetParent&&t!==Gm&&!r.svg&&(m=i.display,i.display="block",c=t.parentNode,(!c||!t.offsetParent)&&(g=1,a=t.nextElementSibling,Gm.appendChild(t)),s=AL(t),m?i.display=m:gp(t,"display"),g&&(a?c.insertBefore(t,a):c?c.appendChild(t):Gm.removeChild(t))),n&&s.length>6?[s[0],s[1],s[4],s[5],s[12],s[13]]:s)},hC=function(t,n,r,i,s,c){var a=t._gsap,m=s||E2(t,!0),g=a.xOrigin||0,x=a.yOrigin||0,T=a.xOffset||0,C=a.yOffset||0,A=m[0],P=m[1],D=m[2],B=m[3],R=m[4],N=m[5],j=n.split(" "),U=parseFloat(j[0])||0,W=parseFloat(j[1])||0,Q,Z,K,Y;r?m!==J_&&(Z=A*B-P*D)&&(K=U*(B/Z)+W*(-D/Z)+(D*N-B*R)/Z,Y=U*(-P/Z)+W*(A/Z)-(A*N-P*R)/Z,U=K,W=Y):(Q=d5(t),U=Q.x+(~j[0].indexOf("%")?U/100*Q.width:U),W=Q.y+(~(j[1]||j[0]).indexOf("%")?W/100*Q.height:W)),i||i!==!1&&a.smooth?(R=U-g,N=W-x,a.xOffset=T+(R*A+N*D)-R,a.yOffset=C+(R*P+N*B)-N):a.xOffset=a.yOffset=0,a.xOrigin=U,a.yOrigin=W,a.smooth=!!i,a.origin=n,a.originIsAbsolute=!!r,t.style[Ns]="0px 0px",c&&(cd(c,a,"xOrigin",g,U),cd(c,a,"yOrigin",x,W),cd(c,a,"xOffset",T,a.xOffset),c
vendor: 11,168 bytes, lines 102-113
102d(c,a,"yOffset",C,a.yOffset)),t.setAttribute("data-svg-origin",U+" "+W)},ev=function(t,n){var r=t._gsap||new QN(t);if("x"in r&&!n&&!r.uncache)return r;var i=t.style,s=r.scaleX<0,c="px",a="deg",m=getComputedStyle(t),g=hu(t,Ns)||"0",x,T,C,A,P,D,B,R,N,j,U,W,Q,Z,K,Y,me,ge,ce,fe,ie,xe,Te,oe,ne,le,se,Ne,Se,xt,kt,wt;return x=T=C=D=B=R=N=j=U=0,A=P=1,r.svg=!!(t.getCTM&&f5(t)),m.translate&&((m.translate!=="none"||m.scale!=="none"||m.rotate!=="none")&&(i[So]=(m.translate!=="none"?"translate3d("+(m.translate+" 0 0").split(" ").slice(0,3).join(", ")+") ":"")+(m.rotate!=="none"?"rotate("+m.rotate+") ":"")+(m.scale!=="none"?"scale("+m.scale.split(" ").join(",")+") ":"")+(m[So]!=="none"?m[So]:"")),i.scale=i.rotate=i.translate="none"),Z=E2(t,r.svg),r.svg&&(r.uncache?(ne=t.getBBox(),g=r.xOrigin-ne.x+"px "+(r.yOrigin-ne.y)+"px",oe=""):oe=!n&&t.getAttribute("data-svg-origin"),hC(t,oe||g,!!oe||r.originIsAbsolute,r.smooth!==!1,Z)),W=r.xOrigin||0,Q=r.yOrigin||0,Z!==J_&&(ge=Z[0],ce=Z[1],fe=Z[2],ie=Z[3],x=xe=Z[4],T=Te=Z[5],Z.length===6?(A=Math.sqrt(ge*ge+ce*ce),P=Math.sqrt(ie*ie+fe*fe),D=ge||ce?mm(ce,ge)*jf:0,N=fe||ie?mm(fe,ie)*jf+D:0,N&&(P*=Math.abs(Math.cos(N*qm))),r.svg&&(x-=W-(W*ge+Q*fe),T-=Q-(W*ce+Q*ie))):(wt=Z[6],xt=Z[7],se=Z[8],Ne=Z[9],Se=Z[10],kt=Z[11],x=Z[12],T=Z[13],C=Z[14],K=mm(wt,Se),B=K*jf,K&&(Y=Math.cos(-K),me=Math.sin(-K),oe=xe*Y+se*me,ne=Te*Y+Ne*me,le=wt*Y+Se*me,se=xe*-me+se*Y,Ne=Te*-me+Ne*Y,Se=wt*-me+Se*Y,kt=xt*-me+kt*Y,xe=oe,Te=ne,wt=le),K=mm(-fe,Se),R=K*jf,K&&(Y=Math.cos(-K),me=Math.sin(-K),oe=ge*Y-se*me,ne=ce*Y-Ne*me,le=fe*Y-Se*me,kt=ie*me+kt*Y,ge=oe,ce=ne,fe=le),K=mm(ce,ge),D=K*jf,K&&(Y=Math.cos(K),me=Math.sin(K),oe=ge*Y+ce*me,ne=xe*Y+Te*me,ce=ce*Y-ge*me,Te=Te*Y-xe*me,ge=oe,xe=ne),B&&Math.abs(B)+Math.abs(D)>359.9&&(B=D=0,R=180-R),A=No(Math.sqrt(ge*ge+ce*ce+fe*fe)),P=No(Math.sqrt(Te*Te+wt*wt)),K=mm(xe,Te),N=Math.abs(K)>2e-4?K*jf:0,U=kt?1/(kt<0?-kt:kt):0),r.svg&&(oe=t.getAttribute("transform"),r.forceCSS=t.setAttribute("transform","")||!m5(hu(t,So)),oe&&t.setAttribute("transform",oe))),Math.abs(N)>90&&Math.abs(N)<270&&(s?(A*=-1,N+=D<=0?180:-180,D+=D<=0?180:-180):(P*=-1,N+=N<=0?180:-180)),n=n||r.uncache,r.x=x-((r.xPercent=x&&(!n&&r.xPercent||(Math.round(t.offsetWidth/2)===Math.round(-x)?-50:0)))?t.offsetWidth*r.xPercent/100:0)+c,r.y=T-((r.yPercent=T&&(!n&&r.yPercent||(Math.round(t.offsetHeight/2)===Math.round(-T)?-50:0)))?t.offsetHeight*r.yPercent/100:0)+c,r.z=C+c,r.scaleX=No(A),r.scaleY=No(P),r.rotation=No(D)+a,r.rotationX=No(B)+a,r.rotationY=No(R)+a,r.skewX=N+a,r.skewY=j+a,r.transformPerspective=U+c,(r.zOrigin=parseFloat(g.split(" ")[2])||!n&&r.zOrigin||0)&&(i[Ns]=vx(g)),r.xOffset=r.yOffset=0,r.force3D=ml.force3D,r.renderTransform=r.svg?Dre:h5?g5:Ore,r.uncache=0,r},vx=function(t){return(t=t.split(" "))[0]+" "+t[1]},QT=function(t,n,r){var i=Ja(n);return No(parseFloat(n)+parseFloat(Id(t,"x",r+"px",i)))+i},Ore=function(t,n){n.z="0px",n.rotationY=n.rotationX="0deg",n.force3D=0,g5(t,n)},Df="0deg",Wy="0px",Lf=") ",g5=function(t,n){var r=n||this,i=r.xPercent,s=r.yPercent,c=r.x,a=r.y,m=r.z,g=r.rotation,x=r.rotationY,T=r.rotationX,C=r.skewX,A=r.skewY,P=r.scaleX,D=r.scaleY,B=r.transformPerspective,R=r.force3D,N=r.target,j=r.zOrigin,U="",W=R==="auto"&&t&&t!==1||R===!0;if(j&&(T!==Df||x!==Df)){var Q=parseFloat(x)*qm,Z=Math.sin(Q),K=Math.cos(Q),Y;Q=parseFloat(T)*qm,Y=Math.cos(Q),c=QT(N,c,Z*Y*-j),a=QT(N,a,-Math.sin(Q)*-j),m=QT(N,m,K*Y*-j+j)}B!==Wy&&(U+="perspective("+B+Lf),(i||s)&&(U+="translate("+i+"%, "+s+"%) "),(W||c!==Wy||a!==Wy||m!==Wy)&&(U+=m!==Wy||W?"translate3d("+c+", "+a+", "+m+") ":"translate("+c+", "+a+Lf),g!==Df&&(U+="rotate("+g+Lf),x!==Df&&(U+="rotateY("+x+Lf),T!==Df&&(U+="rotateX("+T+Lf),(C!==Df||A!==Df)&&(U+="skew("+C+", "+A+Lf),(P!==1||D!==1)&&(U+="scale("+P+", "+D+Lf),N.style[So]=U||"translate(0, 0)"},Dre=function(t,n){var r=n||this,i=r.xPercent,s=r.yPercent,c=r.x,a=r.y,m=r.rotation,g=r.skewX,x=r.skewY,T=r.scaleX,C=r.scaleY,A=r.target,P=r.xOrigin,D=r.yOrigin,B=r.xOffset,R=r.yOffset,N=r.forceCSS,j=parseFloat(c),U=parseFloat(a),W,Q,Z,K,Y;m=parseFloat(m),g=parseFloat(g),x=parseFloat(x),x&&(x=parseFloat(x),g+=x,m+=x),m||g?(m*=qm,g*=qm,W=Math.cos(m)*T,Q=Math.sin(m)*T,Z=Math.sin(m-g)*-C,K=Math.cos(m-g)*C,g&&(x*=qm,Y=Math.tan(g-x),Y=Math.sqrt(1+Y*Y),Z*=Y,K*=Y,x&&(Y=Math.tan(x),Y=Math.sqrt(1+Y*Y),W*=Y,Q*=Y)),W=No(W),Q=No(Q),Z=No(Z),K=No(K)):(W=T,K=C,Q=Z=0),(j&&!~(c+"").indexOf("px")||U&&!~(a+"").indexOf("px"))&&(j=Id(A,"x",c,"px"),U=Id(A,"y",a,"px")),(P||D||B||R)&&(j=No(j+P-(P*W+D*Z)+B),U=No(U+D-(P*Q+D*K)+R)),(i||s)&&(Y=A.getBBox(),j=No(j+i/100*Y.width),U=No(U+s/100*Y.height)),Y="matrix("+W+","+Q+","+Z+","+K+","+j+","+U+")",A.setAttribute("transform",Y),N&&(A.style[So]=Y)},Lre=function(t,n,r,i,s){var c=360,a=ka(s),m=parseFloat(s)*(a&&~s.indexOf("rad")?jf:1),g=m-i,x=i+g+"deg",T,C;return a&&(T=s.split("_")[1],T==="short"&&(g%=c,g!==g%(c/2)&&(g+=g<0?c:-c)),T==="cw"&&g<0?g=(g+c*TL)%c-~~(g/c)*c:T==="ccw"&&g>0&&(g=(g-c*TL)%c-~~(g/c)*c)),t._pt=C=new zs(t._pt,n,r,i,g,yre),C.e=x,C.u="deg",t._props.push(r),C},PL=function(t,n){for(var r in n)t[r]=n[r];return t},Rre=function(t,n,r){var i=PL({},r._gsap),s="perspective,force3D,transformOrigin,svgOrigin",c=r.style,a,m,g,x,T,C,A,P;i.svg?(g=r.getAttribute("transform"),r.setAttribute("transform",""),c[So]=n,a=ev(r,1),gp(r,So),r.setAttribute("transform",g)):(g=getComputedStyle(r)[So],c[So]=n,a=ev(r,1),c[So]=g);for(m in ah)g=i[m],x=a[m],g!==x&&s.indexOf(m)<0&&(A=Ja(g),P=Ja(x),T=A!==P?Id(r,m,g,P):parseFloat(g),C=parseFloat(x),t._pt=new zs(t._pt,a,m,T,C-T,lC),t._pt.u=P||0,t._props.push(m));PL(a,i)};Bs("padding,margin,Width,Radius",function(e,t){var n="Top",r="Right",i="Bottom",s="Left",c=(t<3?[n,r,i,s]:[n+s,n+r,i+r,i+s]).map(function(a){return t<2?e+a:"border"+a+e});_x[t>1?"border"+e:e]=function(a,m,g,x,T){var C,A;if(arguments.length<4)return C=c.map(function(P){return Zu(a,P,g)}),A=C.join(" "),A.split(C[0]).length===5?C[0]:A;C=(x+"").split(" "),A={},c.forEach(function(P,D){return A[P]=C[D]=C[D]||C[(D-1)/2|0]}),a.init(m,A,T)}});var y5={name:"css",register:uC,targetTest:function(t){return t.style&&t.nodeType},init:function(t,n,r,i,s){var c=this._props,a=t.style,m=r.vars.startAt,g,x,T,C,A,P,D,B,R,N,j,U,W,Q,Z,K;x2||uC(),this.styles=this.styles||u5(t),K=this.styles.props,this.tween=r;for(D in n)if(D!=="autoRound"&&(x=n[D],!(ul[D]&&JN(D,n,r,i,t,s)))){if(A=typeof x,P=_x[D],A==="function"&&(x=x.call(r,i,t,s),A=typeof x),A==="string"&&~x.indexOf("random(")&&(x=X_(x)),P)P(this,t,D,x,r)&&(Z=1);else if(D.substr(0,2)==="--")g=(getComputedStyle(t).getPropertyValue(D)+"").trim(),x+="",vd.lastIndex=0,vd.test(g)||(B=Ja(g),R=Ja(x)),R?B!==R&&(g=Id(t,D,g,R)+R):B&&(x+=B),this.add(a,"setProperty",g,x,i,s,0,0,D),c.push(D),K.push(D,0,a[D]);else if(A!=="undefined"){if(m&&D in m?(g=typeof m[D]=="function"?m[D].call(r,i,t,s):m[D],ka(g)&&~g.indexOf("random(")&&(g=X_(g)),Ja(g+"")||g==="auto"||(g+=ml.units[D]||Ja(Zu(t,D))||""),(g+"").charAt(1)==="="&&(g=Zu(t,D))):g=Zu(t,D),C=parseFloat(g),N=A==="string"&&x.charAt(1)==="="&&x.substr(0,2),N&&(x=x.substr(2)),T=parseFloat(x),D in cu&&(D==="autoAlpha"&&(C===1&&Zu(t,"visibility")==="hidden"&&T&&(C=0),K.push("visibility",0,a.visibility),cd(this,a,"visibility",C?"inherit":"hidden",T?"inherit":"hidden",!T)),D!=="scale"&&D!=="transform"&&(D=cu[D],~D.indexOf(",")&&(D=D.split(",")[0]))),j=D in ah,j){if(this.styles.save(D),U||(W=t._gsap,W.renderTransform&&!n.parseTransform||ev(t,n.parseTransform),Q=n.smoothOrigin!==!1&&W.smooth,U=this._pt=new zs(this._pt,a,So,0,1,W.renderTransform,W,0,-1),U.dep=1),D==="scale")this._pt=new zs(this._pt,W,"scaleY",W.scaleY,(N?Vm(W.scaleY,N+T):T)-W.scaleY||0,lC),this._pt.u=0,c.push("scaleY",D),D+="X";else if(D==="transformOrigin"){K.push(Ns,0,a[Ns]),x=Mre(x),W.svg?hC(t,x,0,Q,0,this):(R=parseFloat(x.split(" ")[2])||0,R!==W.zOrigin&&cd(this,W,"zOrigin",W.zOrigin,R),cd(this,a,D,vx(g),vx(x)));continue}else if(D==="svgOrigin"){hC(t,x,1,Q,0,this);continue}else if(D in p5){Lre(this,W,D,C,N?Vm(C,N+x):x);continue}else if(D==="smoothOrigin"){cd(this,W,"smooth",W.smooth,x);continue}else if(D==="force3D"){W[D]=x;continue}else if(D==="transform"){Rre(this,x,t);continue}}else D in a||(D=dg(D)||D);if(j||(T||T===0)&&(C||C===0)&&!gre.test(x)&&D in a)B=(g+"").substr((C+"").length),T||(T=0),R=Ja(x)||(D in ml.units?ml.units[D]:B),B!==R&&(C=Id(t,D,g,R)),this._pt=new zs(this._pt,j?W:a,D,C,(N?Vm(C,N+T):T)-C,!j&&(R==="px"||D==="zIndex")&&n.autoRound!==!1?vre:lC),this._pt.u=R||0,B!==R&&R!=="%"&&(this._pt.b=g,this._pt.r=_re);else if(D in a)Pre.call(this,t,D,g,N?N+x:x);else if(D in t)this.add(t,D,g||t[D],N?N+x:x,i,s);else if(D!=="parseTransform"){d2(D,x);continue}j||(D in a?K.push(D,0,a[D]):K.push(D,1,g||t[D])),c.push(D)}}Z&&o5(this)},render:function(t,n){if(n.tween._time||!w2())for(var r=n._pt;r;)r.r(t,r.d),r=r._next;else n.styles.revert()},get:Zu,aliases:cu,getSetter:function(t,n,r){var i=cu[n];return i&&i.indexOf(",")<0&&(n=i),n in ah&&n!==Ns&&(t._gsap.x||Zu(t,"x"))?r&&wL===r?n==="scale"?Tre:wre:(wL=r||{})&&(n==="scale"?Ere:Sre):t.style&&!c2(t.style[n])?bre:~n.indexOf("-")?xre:v2(t,n)},core:{_removeProperty:gp,_getMatrix:E2}};Gs.utils.checkPrefix=dg;Gs.core.getStyleSaver=u5;(function(e,t,n,r){var i=Bs(e+","+t+","+n,function(s){ah[s]=1});Bs(t,function(s){ml.units[s]="deg",p5[s]=1}),cu[i[13]]=e+","+t,Bs(r,function(s){var c=s.split(":");cu[c[1]]=i[c[0]]})})("x,y,z,scale,scaleX,scaleY,xPercent,yPercent","rotation,rotationX,rotationY,skewX,skewY","transform,transformOrigin,svgOrigin,force3D,smoothOrigin,transformPerspective","0:translateX,1:translateY,2:translateZ,8:rotate,8:rotationZ,8:rotateZ,9:rotateX,10:rotateY");Bs("x,y,z,top,right,bottom,left,width,height,fontSize,padding,margin,perspective",function(e){ml.units[e]="px"});Gs.registerPlugin(y5);var _5=Gs.registerPlugin(y5)||Gs;_5.core.Tween;/*!
103 * ScrollMagic v2.0.8 (2020-08-14)
104 * The javascript library for magical scroll interactions.
105 * (c) 2020 Jan Paepke (@janpaepke)
106 * Project Website: http://scrollmagic.io
107 * 
108 * @version 2.0.8
109 * @license Dual licensed under MIT license and GPL.
110 * @author Jan Paepke - [email protected]
111 *
112 * @file Debug Extension for ScrollMagic.
113 */(function(e){(function(t,n){n(_N)})(oo,function(t){var n="debug.addIndicators",r=window.console||{},i=Function.prototype.bind.call(r.error||r.log||function(){},r);t||i("("+n+") -> ERROR: The ScrollMagic main module could not be found. Please make sure it's loaded before this plugin or use an asynchronous loader like requirejs.");var s="0.85em",c="9999",a=15,m=t._util,g=0;t.Scene.extend(function(){var C=this,A;C.addIndicators=function(P){if(!A){var D={name:"",indent:0,parent:void 0,colorStart:"green",colorEnd:"red",colorTrigger:"blue"};P=m.extend({},D,P),g++,A=new x(C,P),C.on("add.plugin_addIndicators",A.add),C.on("remove.plugin_addIndicators",A.remove),C.on("destroy.plugin_addIndicators",C.removeIndicators),C.controller()&&A.add()}return C},C.removeIndicators=function(){return A&&(A.remove(),this.off("*.plugin_addIndicators"),A=void 0),C}}),t.Controller.addOption("addIndicators",!1),t.Controller.extend(function(){var C=this,A=C.info(),P=A.container,D=A.isDocument,B=A.vertical,R={groups:[]},N=function(){C._log&&(Array.prototype.splice.call(arguments,1,0,"("+n+")","->"),C._log.apply(this,arguments))};
113C._indicators&&N(2,"WARNING: Scene already has a property '_indicators', which will be overwritten by plugin."),this._indicators=R;var j=function(){R.updateBoundsPositions()},U=function(){R.updateTriggerGroupPositions()};return P.addEventListener("resize",U),D||(window.addEventListener("resize",U),window.addEventListener("scroll",U)),P.addEventListener("resize",j),P.addEventListener("scroll",j),this._indicators.updateBoundsPositions=function(W){for(var Q=W?[m.extend({},W.triggerGroup,{members:[W]})]:R.groups,Z=Q.length,K={},Y=B?"left":"top",me=B?"width":"height",ge=B?m.get.scrollLeft(P)+m.get.width(P)-a:m.get.scrollTop(P)+m.get.height(P)-a,ce,fe,ie;Z--;)for(ie=Q[Z],ce=ie.members.length,fe=m.get[me](ie.element.firstChild);ce--;)K[Y]=ge-fe,m.css(ie.members[ce].bounds,K)},this._indicators.updateTriggerGroupPositions=function(W){for(var Q=W?[W]:R.groups,Z=Q.length,K=D?document.body:P,Y=D?{top:0,left:0}:m.get.offset(K,!0),me=B?m.get.width(P)-a:m.get.height(P)-a,ge=B?"width":"height",ce=B?"Y":"X",fe,ie,xe,Te,oe;Z--;)fe=Q[Z],ie=fe.element,xe=fe.triggerHook*C.info("size"),Te=m.get[ge](ie.firstChild.firstChild),oe=xe>Te?"translate"+ce+"(-100%)":"",m.css(ie,{top:Y.top+(B?xe:me-fe.members[0].options.indent),left:Y.left+(B?me-fe.members[0].options.indent:xe)}),m.css(ie.firstChild.firstChild,{"-ms-transform":oe,"-webkit-transform":oe,transform:oe})},this._indicators.updateTriggerGroupLabel=function(W){var Q="trigger"+(W.members.length>1?"":" "+W.members[0].options.name),Z=W.element.firstChild.firstChild,K=Z.textContent!==Q;K&&(Z.textContent=Q,B&&R.updateBoundsPositions())},this.addScene=function(W){this._options.addIndicators&&W instanceof t.Scene&&W.controller()===C&&W.addIndicators(),this.$super.addScene.apply(this,arguments)},this.destroy=function(){P.removeEventListener("resize",U),D||(window.removeEventListener("resize",U),window.removeEventListener("scroll",U)),P.removeEventListener("resize",j),P.removeEventListener("scroll",j),this.$super.destroy.apply(this,arguments)},C});var x=function(C,A){var P=this,D=T.bounds(),B=T.start(A.colorStart),R=T.end(A.colorEnd),N=A.parent&&m.get.elements(A.parent)[0],j,U,W=function(){C._log&&(Array.prototype.splice.call(arguments,1,0,"("+n+")","->"),C._log.apply(this,arguments))};A.name=A.name||g,B.firstChild.textContent+=" "+A.name,R.textContent+=" "+A.name,D.appendChild(B),D.appendChild(R),P.options=A,P.bounds=D,P.triggerGroup=void 0,this.add=function(){U=C.controller(),j=U.info("vertical");var ie=U.info("isDocument");N||(N=ie?document.body:U.info("container")),!ie&&m.css(N,"position")==="static"&&m.css(N,{position:"relative"}),C.on("change.plugin_addIndicators",Z),C.on("shift.plugin_addIndicators",Q),fe(),me(),setTimeout(function(){U._indicators.updateBoundsPositions(P)},0),W(3,"added indicators")},this.remove=function(){if(P.triggerGroup){if(C.off("change.plugin_addIndicators",Z),C.off("shift.plugin_addIndicators",Q),P.triggerGroup.members.length>1){var ie=P.triggerGroup;ie.members.splice(ie.members.indexOf(P),1),U._indicators.updateTriggerGroupLabel(ie),U._indicators.updateTriggerGroupPositions(ie),P.triggerGroup=void 0}else ce();Y(),W(3,"removed indicators")}};var Q=function(){me()},Z=function(ie){ie.what==="triggerHook"&&fe()},K=function(){var ie=U.info("vertical");m.css(B.firstChild,{"border-bottom-width":ie?1:0,"border-right-width":ie?0:1,bottom:ie?-1:A.indent,right:ie?A.indent:-1,padding:ie?"0 8px":"2px 4px"}),m.css(R,{"border-top-width":ie?1:0,"border-left-width":ie?0:1,top:ie?"100%":"",right:ie?A.indent:"",bottom:ie?"":A.indent,left:ie?"":"100%",padding:ie?"0 8px":"2px 4px"}),N.appendChild(D)},Y=function(){D.parentNode.removeChild(D)},me=function(){D.parentNode!==N&&K();var ie={};ie[j?"top":"left"]=C.triggerPosition(),ie[j?"height":"width"]=C.duration(),m.css(D,ie),m.css(R,{display:C.duration()>0?"":"none"})},ge=function(){var ie=T.trigger(A.colorTrigger),xe={};xe[j?"right":"bottom"]=0,xe[j?"border-top-width":"border-left-width"]=1,m.css(ie.firstChild,xe),m.css(ie.firstChild.firstChild,{padding:j?"0 8px 3px 8px":"3px 4px"}),document.body.appendChild(ie);var Te={triggerHook:C.triggerHook(),element:ie,members:[P]};U._indicators.groups.push(Te),P.triggerGroup=Te,U._indicators.updateTriggerGroupLabel(Te),U._indicators.updateTriggerGroupPositions(Te)},ce=function(){U._indicators.groups.splice(U._indicators.groups.indexOf(P.triggerGroup),1),P.triggerGroup.element.parentNode.removeChild(P.triggerGroup.element),P.triggerGroup=void 0},fe=function(){var ie=C.triggerHook(),xe=1e-4;if(!(P.triggerGroup&&Math.abs(P.triggerGroup.triggerHook-ie)<xe)){for(var Te=U._indicators.groups,oe,ne=Te.length;ne--;)if(oe=Te[ne],Math.abs(oe.triggerHook-ie)<xe){P.triggerGroup&&(P.triggerGroup.members.length===1?ce():(P.triggerGroup.members.splice(P.triggerGroup.members.indexOf(P),1),U._indicators.updateTriggerGroupLabel(P.triggerGroup),U._indicators.updateTriggerGroupPositions(P.triggerGroup))),oe.members.push(P),P.triggerGroup=oe,U._indicators.updateTriggerGroupLabel(oe);return}if(P.triggerGroup)if(P.triggerGroup.members.length===1){P.triggerGroup.triggerHook=ie,U._indicators.updateTriggerGroupPositions(P.triggerGroup);return}else P.triggerGroup.members.splice(P.triggerGroup.members.indexOf(P),1),U._indicators.updateTriggerGroupLabel(P.triggerGroup),U._indicators.updateTriggerGroupPositions(P.triggerGroup),P.triggerGroup=void 0;ge()}}},T={start:function(C){var A=document.createElement("div");A.textContent="start",m.css(A,{position:"absolute",overflow:"visible","border-width":0,"border-style":"solid",color:C,"border-color":C});var P=document.createElement("div");return m.css(P,{position:"absolute",overflow:"visible",width:0,height:0}),P.appendChild(A),P},end:function(C){var A=document.createElement("div");return A.textContent="end",m.css(A,{position:"absolute",overflow:"visible","border-width":0,"border-style":"solid",color:C,"border-color":C}),A},bounds:function(){var C=document.createElement("div");return m.css(C,{position:"absolute",overflow:"visible","white-space":"nowrap","pointer-events":"none","font-size":s}),C.style.zIndex=c,C},trigger:function(C){var A=document.createElement("div");A.textContent="trigger",m.css(A,{position:"relative"});var P=document.createElement("div");m.css(P,{position:"absolute",overflow:"visible","border-width":0,"border-style":"solid",color:C,"border-color":C}),P.appendChild(A);var D=document.createElement("div");return m.css(D,{position:"fixed",overflow:"visible","white-space":"nowrap","pointer-events":"none","font-size":s}),D.style.zIndex=c,D.appendChild(P),D}}})})();const Fre=Gi(()=>({provide:{ScrollMagic:xne,gsap:_5}}));function Bre(e,t){const n=e.getBoundingClientRect();if(!t)return n.top>=0&&n.bottom<=window.innerHeight;const r=t.getBoundingClientRect();return n.top>=r.top&&n.bottom<=r.bottom}async function zre(e){return await Qi(),e.value instanceof HTMLElement?e.value:e.value?document.querySelector(e.value):null}function ML(e){let t=`0px 0px ${e.distance}px 0px`;
113e.top&&(t=`${e.distance}px 0px 0px 0px`);const n=new IntersectionObserver(r=>{r[0].isIntersecting&&(e.firstload&&e.emit(),e.firstload=!0)},{root:e.parentEl,rootMargin:t});return n.observe(e.infiniteLoading.value),n}const v5=(e,t)=>{const n=e.__vccOpts||e;for(const[r,i]of t)n[r]=i;return n},Nre={},$re=e=>(c8("data-v-d3e37633"),e=e(),u8(),e),jre={class:"container"},Ure=$re(()=>Un("div",{class:"spinner"},null,-1)),Vre=[Ure];function Gre(e,t){return At(),Wt("div",jre,Vre)}const qre=v5(Nre,[["render",Gre],["__scopeId","data-v-d3e37633"]]),Wre={class:"state-error"},Hre=sr({__name:"InfiniteLoading",props:{top:{type:Boolean,default:!1},target:{},distance:{default:0},identifier:{},firstload:{type:Boolean,default:!0},slots:{}},emits:["infinite"],setup(e,{emit:t}){const n=e;let r=null,i=0;const s=jt(null),c=jt(""),{top:a,firstload:m,distance:g}=n,{identifier:x,target:T}=wv(n),C={infiniteLoading:s,top:a,firstload:m,distance:g,parentEl:null,emit(){i=(C.parentEl||document.documentElement).scrollHeight,A.loading(),t("infinite",A)}},A={loading(){c.value="loading"},async loaded(){c.value="loaded";const P=C.parentEl||document.documentElement;await Qi(),a&&(P.scrollTop=P.scrollHeight-i),Bre(s.value,C.parentEl)&&C.emit()},complete(){c.value="complete",r==null||r.disconnect()},error(){c.value="error"}};return Nn(x,()=>{r==null||r.disconnect(),r=ML(C)}),Dr(async()=>{C.parentEl=await zre(T),r=ML(C)}),Bi(()=>{r==null||r.disconnect()}),(P,D)=>(At(),Wt("div",{ref_key:"infiniteLoading",ref:s,style:{"min-height":"1px"}},[pd(Un("div",null,[En(P.$slots,"spinner",{},()=>[sn(qre)],!0)],512),[[gd,c.value=="loading"]]),c.value=="complete"?En(P.$slots,"complete",{key:0},()=>{var B;return[Un("span",null,Ba(((B=P.slots)==null?void 0:B.complete)||"No more results!"),1)]},!0):hn("",!0),c.value=="error"?En(P.$slots,"error",{key:1,retry:C.emit},()=>{var B;return[Un("span",Wre,[Un("span",null,Ba(((B=P.slots)==null?void 0:B.error)||"Oops something went wrong!"),1),Un("button",{class:"retry",onClick:D[0]||(D[0]=(...R)=>C.emit&&C.emit(...R))},"retry")])]},!0):hn("",!0)],512))}}),Yre=v5(Hre,[["__scopeId","data-v-a7077831"]]);const Zre=Gi(e=>{e.vueApp.component("infinite-loading",Yre)}),IL=e=>{let t=!1,n;return()=>(t||(t=!0,n=e()),n)};class dC{static isServer(){return typeof document>"u"}}function Xre(e){const t=document.createElement("SCRIPT");if(typeof e!="object")throw new Error("options should  be an object");Array.prototype.isPrototypeOf(e.libraries)&&(e.libraries=e.libraries.join(",")),e.v||(e.v=3.47),e.callback="vueGoogleMapsInit";let r="https://maps.googleapis.com/maps/api/js?"+Object.keys(e).map(i=>encodeURIComponent(i)+"="+encodeURIComponent(e[i])).join("&");return t.setAttribute("src",r),t.setAttribute("async",""),t.setAttribute("defer",""),t}let OL=!1;function Kre(e){if(!dC.isServer()){if(OL)throw new Error("You already started the loading of google maps");{OL=!0;const t=Xre(e);document.head.appendChild(t)}}}const b5=(e,t,n)=>{for(let r of n){const i=`on${r.charAt(0).toUpperCase()}${r.slice(1)}`.replace(/[-_]+(.)?/g,(s,c)=>c?c.toUpperCase():"");e.$props[i]||e.$attrs[i]?t.addListener(r,s=>{e.$emit(r,s)}):(e.$gmapOptions.autobindAllEvents||e.$attrs[r])&&t.addListener(r,s=>{e.$emit(r,s)})}};function x5(e,t,n,r=!1){let i=!1;function s(){i||(i=!0,e.$nextTick(()=>{i=!1,n()}))}for(let c of t)e.$watch(c,s,{immediate:r})}class DL{static capitalizeFirstLetter(t){return t.charAt(0).toUpperCase()+t.slice(1)}}function bx(e,t){return Object.keys(t).reduce((n,r)=>(e[r]!==void 0&&(n[r]=e[r]),n),{})}function S2(e,t,n){for(let r in n){let{twoWay:i,type:s,trackProperties:c,noBind:a}=n[r];if(a)continue;const m="set"+DL.capitalizeFirstLetter(r),g="get"+DL.capitalizeFirstLetter(r),x=r.toLowerCase()+"_changed",T=e[r];if(typeof t[m]>"u")throw new Error(`${m} is not a method of (the Maps object corresponding to) ${e.$options._componentTag}`);s!==Object||!c?e.$watch(r,()=>{const C=e[r];t[m](C)},{immediate:typeof T<"u",deep:s===Object}):x5(e,c.map(C=>`${r}.${C}`),()=>{t[m](e[r])},e[r]!==void 0),i&&(e.$gmapOptions.autobindAllEvents||e.$attrs[x])&&t.addListener(x,()=>{e.$emit(x,t[g]())})}}const Qre={inject:{$mapPromise:{default:"abcdef"}},provide(){return this.$mapPromise.then(e=>{this.$map=e}),{}}};function Tp(e){const{mappedProps:t,name:n,ctr:r,ctrArgs:i,events:s,beforeCreate:c,afterCreate:a,props:m,...g}=e,x=`$${n}Promise`,T=`$${n}Object`;return Jre(!(g.props instanceof Array),"`props` should be an object, not Array"),{...typeof GENERATE_DOC<"u"?{$vgmOptions:e}:{},mixins:[Qre],props:{...m,...C2(t)},render(){return""},provide(){const C=this.$mapPromise.then(A=>{this.$map=A;const P={...this.options,map:A,...bx(this,t)};if(delete P.options,c){const D=c.bind(this)(P);if(D instanceof Promise)return D.then(()=>({options:P}))}return{options:P}}).then(({options:A})=>{const P=r();return this[T]=i?new(Function.prototype.bind.call(P,null,...i(A,bx(this,m||{})))):new P(A),S2(this,this[T],t),b5(this,this[T],s),a&&a.bind(this)(this[T]),this[T]});return this[x]=C,{[x]:C}},unmounted(){this[T]&&this[T].setMap&&this[T].setMap(null)},...g}}function Jre(e,t){if(!e)throw new Error(t)}function C2(e){return Object.entries(e).map(([t,n])=>{const r={};return"type"in n&&(r.type=n.type),"default"in n&&(r.default=n.default),"required"in n&&(r.required=n.required),[t,r]}).reduce((t,[n,r])=>(t[n]=r,t),{})}const eie={draggable:{type:Boolean},editable:{type:Boolean},options:{twoWay:!1,type:Object},path:{type:Array,twoWay:!0}},tie=["click","dblclick","drag","dragend","dragstart","mousedown","mousemove","mouseout","mouseover","mouseup","rightclick"],nie=Tp({mappedProps:eie,props:{deepWatch:{type:Boolean,default:!1}},events:tie,name:"polyline",ctr:()=>google.maps.Polyline,afterCreate(){let e=()=>{};this.$watch("path",t=>{if(t){e(),this.$polylineObject.setPath(t);const n=this.$polylineObject.getPath(),r=[],i=()=>{this.$emit("path_changed",this.$polylineObject.getPath())};r.push([n,n.addListener("insert_at",i)]),r.push([n,n.addListener("remove_at",i)]),r.push([n,n.addListener("set_at",i)]),e=()=>{r.map(([s,c])=>google.maps.event.removeListener(c))}}},{deep:this.deepWatch,immediate:!0})}}),rie={draggable:{type:Boolean},editable:{type:Boolean},options:{type:Object},path:{type:Array,twoWay:!0,noBind:!0},paths:{type:Array,twoWay:!0,noBind:!0}},iie=["click","dblclick","drag","dragend","dragstart","mousedown","mousemove","mouseout","mouseover","mouseup","rightclick"],oie=Tp({props:{deepWatch:{type:Boolean,default:!1}},events:iie,mappedProps:rie,name:"polygon",ctr:()=>google.maps.Polygon,beforeCreate(e){e.path||delete e.path,e.paths||delete e.paths},afterCreate(e){let t=()=>{};this.$watch("paths",n=>{if(n){t(),e.setPaths(n);const r=()=>{this.$emit("paths_changed",e.getPaths())},i=[],s=e.getPaths();for(let c=0;c<s.getLength();c++){let a=s.getAt(c);i.push([a,a.addListener("insert_at",r)]),i.push([a,a.addListener("remove_at",r)]),i.push([a,a.addListener("set_at",r)])}i.push([s,s.addListener("insert_at",r)]),i.push([s,s.addListener("remove_at",r)]),i.push([s,s.addListener("set_at",r)]),t=()=>{i.map(([c,a])=>google.maps.event.removeListener(a))}}},{deep:this.deepWatch,immediate:!0}),this.$watch("path",n=>{if(n){t(),e.setPaths(n);const r=e.getPath(),i=[],s=()=>{this.$emit("path_changed",e.getPath())};i.push([r,r.addListener("insert_at",s)]),i.push([r,r.addListener("remove_at",s)]),i.push([r,r.addListener("set_at",s)]),t=()=>{i.map(([c,a])=>google.maps.event.removeListener(a))}}},{deep:this.deepWatch,immediate:!0})}}),aie={center:{type:Object,twoWay:!0,required:!0},radius:{type:Number,twoWay:!0},draggable:{type:Boolean,default:!1},editable:{type:Boolean,default:!1},options:{type:Object,twoWay:!1}},sie=["click","dblclick","drag","dragend","dragstart","mousedown","mousemove","mouseout","mouseover","mouseup","rightclick"],lie=Tp({mappedProps:aie,name:"circle",ctr:()=>google.maps.Circle,events:sie}),cie={bounds:{type:Object,twoWay:!0},draggable:{type:Boolean,default:!1},editable:{type:Boolean,default:!1},options:{type:Object,twoWay:!1}},uie=["click","dblclick","drag","dragend","dragstart","mousedown","mousemove","mouseout","mouseover","mouseup","rightclick"],hie=Tp({mappedProps:cie,name:"rectangle",ctr:()=>google.maps.Rectangle,events:uie}),Lv=(e,t)=>{const n=e.__vccOpts||e;for(const[r,i]of t)n[r]=i;return n},die={animation:{twoWay:!0,type:Number},attribution:{type:Object},clickable:{type:Boolean,twoWay:!0,default:!0},cursor:{type:String,twoWay:!0},draggable:{type:Boolean,twoWay:!0,default:!1},icon:{twoWay:!0},label:{},opacity:{type:Number,default:1},options:{type:Object},place:{type:Object},position:{type:Object,twoWay:!0},shape:{type:Object,twoWay:!0},title:{type:String,twoWay:!0},zIndex:{type:Number,twoWay:!0},visible:{twoWay:!0,default:!0}},JT=["click","rightclick","dblclick","drag","dragstart","dragend","mouseup","mousedown","mouseover","mouseout"],fie=Tp({mappedProps:die,events:JT,name:"marker",ctr:()=>google.maps.Marker,inject:{$clusterPromise:{default:null}},emits:JT,unmounted(){this.$markerObject&&(this.$clusterObject?this.$clusterObject.removeMarker(this.$markerObject,!0):this.$markerObject.setMap(null))},beforeCreate(e){return this.$clusterPromise&&(e.map=null),this.$clusterPromise},afterCreate(e){JT.forEach(t=>{e.addListener(t,n=>{this.$emit(t,n)})}),this.$clusterPromise&&this.$clusterPromise.then(t=>{this.$clusterObject=t,t.addMarker(e)})}});function pie(e,t,n,r,i,s){return At(),Wt("div",{onClick:t[0]||(t[0]=()=>{console.log("sdfsd")})},[En(e.$slots,"default")])}const mie=Lv(fie,[["render",pie]]),gie={options:{type:Object,required:!1,default(){return{}}},position:{type:Object,twoWay:!0},zIndex:{type:Number,twoWay:!0}},yie=["domready","click","closeclick","content_changed"],_ie=Tp({mappedProps:gie,events:yie,name:"infoWindow",ctr:()=>google.maps.InfoWindow,props:{opened:{type:Boolean,default:!0}},inject:{$markerPromise:{default:null}},mounted(){const e=this.$refs.infoWindow;e.parentNode.removeChild(e)},beforeCreate(e){if(e.content=this.$refs.infoWindow,this.$markerPromise)return delete e.position,this.$markerPromise.then(t=>(this.$markerObject=t,t))},emits:["closeclick"],methods:{_openInfoWindow(){this.$infoWindowObject.close(),this.opened?this.$infoWindowObject.open(this.$map,this.$markerObject):this.$emit("closeclick")}},afterCreate(){this._openInfoWindow(),this.$watch("opened",()=>{this._openInfoWindow()})}}),vie={ref:"infoWindow"};function bie(e,t,n,r,i,s){return At(),Wt("div",vie,[En(e.$slots,"default")],512)}const xie=Lv(_ie,[["render",bie]]),wie={props:["resizeBus"],data(){return{_actualResizeBus:null}},created(){typeof this.resizeBus>"u"?this.$data._actualResizeBus=this.$gmapDefaultResizeBus:this.$data._actualResizeBus=this.resizeBus},methods:{_resizeCallback(){this.resize()},isFunction(e){return e&&{}.toString.call(e)==="[object Function]"},_delayedResizeCallback(){this.$nextTick(()=>this._resizeCallback())}},watch:{resizeBus(e){this.$data._actualResizeBus=e},"$data._actualResizeBus"(e,t){t&&t.$off("resize",this._delayedResizeCallback)}},unmounted(){this.$data._actualResizeBus&&this.isFunction(this.$data._actualResizeBus.$off)&&this.$data._actualResizeBus.$off("resize",this._delayedResizeCallback)}};function Tie(e){let t=0;
113e(()=>{t+=1},()=>{t=Math.max(0,t-1)},()=>t===0)}const eE={center:{required:!0,twoWay:!0,type:Object,noBind:!0},zoom:{required:!1,twoWay:!0,type:Number,noBind:!0},heading:{type:Number,twoWay:!0},mapTypeId:{twoWay:!0,type:String},tilt:{twoWay:!0,type:Number},options:{type:Object,default(){return{}}}},LL=["bounds_changed","click","dblclick","drag","dragend","dragstart","idle","mousemove","mouseout","mouseover","resize","rightclick","tilesloaded"],Eie=["panBy","panTo","panToBounds","fitBounds"].reduce((e,t)=>(e[t]=function(){this.$mapObject&&this.$mapObject[t].apply(this.$mapObject,arguments)},e),{}),Sie={resize(){this.$mapObject&&google.maps.event.trigger(this.$mapObject,"resize")},resizePreserveCenter(){if(!this.$mapObject)return;const e=this.$mapObject.getCenter();google.maps.event.trigger(this.$mapObject,"resize"),this.$mapObject.setCenter(e)},_resizeCallback(){this.resizePreserveCenter()}},Cie={mixins:[wie],props:C2({...eE,...LL.reduce((e,t)=>({...e,[`on${t.charAt(0).toUpperCase()}${t.slice(1)}`.replace(/[-_]+(.)?/g,(n,r)=>r?r.toUpperCase():"")]:Function}),{})}),inheritAttrs:!1,provide(){return this.$mapPromise=new Promise((e,t)=>{this.$mapPromiseDeferred={resolve:e,reject:t}}),{$mapPromise:this.$mapPromise}},emits:["center_changed","zoom_changed","bounds_changed"],computed:{finalLat(){return this.center&&typeof this.center.lat=="function"?this.center.lat():this.center.lat},finalLng(){return this.center&&typeof this.center.lng=="function"?this.center.lng():this.center.lng},finalLatLng(){return{lat:this.finalLat,lng:this.finalLng}}},watch:{zoom(e){this.$mapObject&&this.$mapObject.setZoom(e)}},mounted(){return this.$gmapApiPromiseLazy().then(()=>{const e=this.$refs["vue-map"],t={...this.options,...bx(this,eE)};return delete t.options,this.$mapObject=new google.maps.Map(e,t),S2(this,this.$mapObject,eE),b5(this,this.$mapObject,LL),Tie((n,r,i)=>{this.$mapObject.addListener("center_changed",()=>{i()&&this.$emit("center_changed",this.$mapObject.getCenter()),r()}),x5(this,["finalLat","finalLng"],()=>{n(),this.$mapObject.setCenter(this.finalLatLng)})}),this.$mapObject.addListener("zoom_changed",()=>{this.$emit("zoom_changed",this.$mapObject.getZoom())}),this.$mapObject.addListener("bounds_changed",()=>{this.$emit("bounds_changed",this.$mapObject.getBounds())}),this.$mapPromiseDeferred.resolve(this.$mapObject),this.$mapObject}).catch(e=>{throw e})},methods:{...Sie,...Eie}},kie={class:"vue-map-hidden"};function Aie(e,t,n,r,i,s){return At(),Wt("div",{class:qr(["vue-map-container",e.$attrs.class])},[Un("div",{ref:"vue-map",class:"vue-map",style:Sa(e.$attrs.style?e.$attrs.style:"")},null,4),Un("div",kie,[En(e.$slots,"default")]),En(e.$slots,"visible")],2)}const Pie=Lv(Cie,[["render",Aie]]),Mie={options:{type:Object,twoWay:!1,default:()=>{}},data:{type:Array,twoWay:!0}},Iie=[],Oie=Tp({mappedProps:Mie,name:"heatmap",ctr:()=>google.maps.visualization.HeatmapLayer,events:Iie}),Die=e=>{const t=e.addEventListener?e.addEventListener:e.attachEvent;function n(r,i){if(r==="keydown"){const s=i;i=function(c){const a=document.getElementsByClassName("pac-item-selected").length>0;if(c.which===13&&!a){const m=document.createEvent("Event");m.keyCode=40,m.which=40,s.apply(e,[m])}s.apply(e,[c])}}t.apply(e,[r,i])}e.addEventListener=n,e.attachEvent=n},tE={bounds:{type:Object},componentRestrictions:{type:Object,noBind:!0},types:{type:Array,default:function(){return[]}}},Lie={selectFirstOnEnter:{required:!1,type:Boolean,default:!1},options:{type:Object}},Rie={mounted(){this.$gmapApiPromiseLazy().then(()=>{if(this.selectFirstOnEnter&&Die(this.$refs.input),typeof google.maps.places.Autocomplete!="function")throw new Error("google.maps.places.Autocomplete is undefined. Did you add 'places' to libraries when loading Google Maps?");const e={...bx(this,tE),...this.options};this.$autocomplete=new google.maps.places.Autocomplete(this.$refs.input,e),S2(this,this.$autocomplete,tE),this.$watch("componentRestrictions",t=>{t!==void 0&&this.$autocomplete.setComponentRestrictions(t)}),this.$autocomplete.addListener("place_changed",()=>{this.$emit("place_changed",this.$autocomplete.getPlace())})})},props:{...C2(tE),...Lie}};function Fie(e,t,n,r,i,s){return At(),Wt("input",Li({id:"autocomplete-2023",ref:"input"},e.$attrs,O8(e.$attrs,!0)),null,16)}const Bie=Lv(Rie,[["render",Fie]]);let w5=null;function zie(e,t){t={installComponents:!0,autobindAllEvents:!1,...t},w5=WE({data:function(){return{gmapApi:null}}});const n=WE();let r=Nie(t);e.mixin({created(){this.$gmapDefaultResizeBus=n,this.$gmapOptions=t,this.$gmapApiProm
113iseLazy=r}}),e.$gmapDefaultResizeBus=n,e.$gmapApiPromiseLazy=r,t.installComponents&&(e.component("GMapMap",Pie),e.component("GMapMarker",mie),e.component("GMapInfoWindow",xie),e.component("GMapPolyline",nie),e.component("GMapPolygon",oie),e.component("GMapCircle",lie),e.component("GMapRectangle",hie),e.component("GMapAutocomplete",Bie),e.component("GMapHeatmap",Oie))}function Nie(e){function t(){return w5.gmapApi={},window.google}if(e.load)return IL(()=>dC.isServer()?new Promise(()=>{}).then(t):new Promise((n,r)=>{try{window.vueGoogleMapsInit=n,Kre(e.load)}catch(i){r(i)}}).then(t));{const n=new Promise(r=>{dC.isServer()||(window.vueGoogleMapsInit=r)}).then(t);return IL(()=>n)}}const $ie=Gi(e=>{e.vueApp.use(zie,{load:{key:e.$config.public.GMAPS_KEY,libraries:"places"}})});var k2={},A2={};Object.defineProperty(A2,"__esModule",{value:!0});class jie{constructor(t=null){this.state="pending",this.fate="unresolved",this._val=t||null,this.promise=new Promise((n,r)=>{this._resolve=n,this._reject=r}),this.promise.then(n=>{this.state="fulfilled",this._val=n},()=>{this.state="rejected",this._val=null})}resolve(t){if(this.fate==="resolved")throw"Deferred cannot be resolved twice";this.fate="resolved",this._resolve(t)}reject(t){if(this.fate==="resolved")throw"Deferred cannot be resolved twice";this.fate="resolved",this._reject(t)}isResolved(){return this.fate==="resolved"}isPending(){return this.state==="pending"}isFulfilled(){return this.state==="fulfilled"}isRejected(){return this.state==="rejected"}get val(){return this._val}}A2.default=jie;var Uie=oo&&oo.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(k2,"__esModule",{value:!0});const Vie=Uie(A2);var Ep=k2.default=Vie.default,T5={exports:{}};(function(e,t){(function(n,r){e.exports=r()})(oo,function(){var n,r,i;function s(a,m){if(!n)n=m;else if(!r)r=m;else{var g="self.onerror = function() { console.error('An error occurred while parsing the WebWorker bundle. This is most likely due to improper transpilation by Babel; please see https://docs.mapbox.com/mapbox-gl-js/guides/install/#transpiling'); }; var sharedChunk = {}; ("+n+")(sharedChunk); ("+r+")(sharedChunk); self.onerror = null;",x={};n(x),i=m(x),typeof window<"u"&&window&&window.URL&&window.URL.createObjectURL&&(i.workerUrl=window.URL.createObjectURL(new Blob([g],{type:"text/javascript"})))}}s(["exports"],function(a){var m=typeof self<"u"?self:{},g="2.15.0";let x;const T={API_URL:"https://api.mapbox.com",get API_URL_REGEX(){if(x==null){const l=/^((https?:)?\/\/)?([^\/]+\.)?mapbox\.c(n|om)(\/|\?|$)/i;try{x={}.API_URL_REGEX!=null?new RegExp({}.API_URL_REGEX):l}catch{x=l}}return x},get API_TILEJSON_REGEX(){return/^((https?:)?\/\/)?([^\/]+\.)?mapbox\.c(n|om)(\/v[0-9]*\/.*\.json.*$)/i},get API_SPRITE_REGEX(){return/^((https?:)?\/\/)?([^\/]+\.)?mapbox\.c(n|om)(\/styles\/v[0-9]*\/)(.*\/sprite.*\..*$)/i},get API_FONTS_REGEX(){return/^((https?:)?\/\/)?([^\/]+\.)?mapbox\.c(n|om)(\/fonts\/v[0-9]*\/)(.*\.pbf.*$)/i},get API_STYLE_REGEX(){return/^((https?:)?\/\/)?([^\/]+\.)?mapbox\.c(n|om)(\/styles\/v[0-9]*\/)(.*$)/i},get API_CDN_URL_REGEX(){return/^((https?:)?\/\/)?api\.mapbox\.c(n|om)(\/mapbox-gl-js\/)(.*$)/i},get EVENTS_URL(){if(!T.API_URL)return null;try{const l=new URL(T.API_URL);return l.hostname==="api.mapbox.cn"?"https://events.mapbox.cn/events/v2":l.hostname==="api.mapbox.com"?"https://events.mapbox.com/events/v2":null}catch{return null}},SESSION_PATH:"/map-sessions/v1",FEEDBACK_URL:"https://apps.mapbox.com/feedback",TILE_URL_VERSION:"v4",RASTER_URL_PREFIX:"raster/v1",REQUIRE_ACCESS_TOKEN:!0,ACCESS_TOKEN:null,MAX_PARALLEL_IMAGE_REQUESTS:16},C={supported:!1,testSupport:function(l){!D&&P&&(B?R(l):A=l)}};let A,P,D=!1,B=!1;function R(l){const o=l.createTexture();l.bindTexture(l.TEXTURE_2D,o);try{if(l.texImage2D(l.TEXTURE_2D,0,l.RGBA,l.RGBA,l.UNSIGNED_BYTE,P),l.isContextLost())return;C.supported=!0}
113catch{}l.deleteTexture(o),D=!0}m.document&&(P=m.document.createElement("img"),P.onload=function(){A&&R(A),A=null,B=!0},P.onerror=function(){D=!0,A=null},P.src="data:image/webp;base64,UklGRh4AAABXRUJQVlA4TBEAAAAvAQAAAAfQ//73v/+BiOh/AAA=");const N="01";function j(l){return l&&l.__esModule&&Object.prototype.hasOwnProperty.call(l,"default")?l.default:l}var U=W;function W(l,o,u,d){this.cx=3*l,this.bx=3*(u-l)-this.cx,this.ax=1-this.cx-this.bx,this.cy=3*o,this.by=3*(d-o)-this.cy,this.ay=1-this.cy-this.by,this.p1x=l,this.p1y=o,this.p2x=u,this.p2y=d}W.prototype={sampleCurveX:function(l){return((this.ax*l+this.bx)*l+this.cx)*l},sampleCurveY:function(l){return((this.ay*l+this.by)*l+this.cy)*l},sampleCurveDerivativeX:function(l){return(3*this.ax*l+2*this.bx)*l+this.cx},solveCurveX:function(l,o){if(o===void 0&&(o=1e-6),l<0)return 0;if(l>1)return 1;for(var u=l,d=0;d<8;d++){var p=this.sampleCurveX(u)-l;if(Math.abs(p)<o)return u;var _=this.sampleCurveDerivativeX(u);if(Math.abs(_)<1e-6)break;u-=p/_}var b=0,E=1;for(u=l,d=0;d<20&&(p=this.sampleCurveX(u),!(Math.abs(p-l)<o));d++)l>p?b=u:E=u,u=.5*(E-b)+b;return u},solve:function(l,o){return this.sampleCurveY(this.solveCurveX(l,o))}};var Q=j(U),Z=K;function K(l,o){this.x=l,this.y=o}K.prototype={clone:function(){return new K(this.x,this.y)},add:function(l){return this.clone()._add(l)},sub:function(l){return this.clone()._sub(l)},multByPoint:function(l){return this.clone()._multByPoint(l)},divByPoint:function(l){return this.clone()._divByPoint(l)},mult:function(l){return this.clone()._mult(l)},div:function(l){return this.clone()._div(l)},rotate:function(l){return this.clone()._rotate(l)},rotateAround:function(l,o){return this.clone()._rotateAround(l,o)},matMult:function(l){return this.clone()._matMult(l)},unit:function(){return this.clone()._unit()},perp:function(){return this.clone()._perp()},round:function(){return this.clone()._round()},mag:function(){return Math.sqrt(this.x*this.x+this.y*this.y)},equals:function(l){return this.x===l.x&&this.y===l.y},dist:function(l){return Math.sqrt(this.distSqr(l))},distSqr:function(l){var o=l.x-this.x,u=l.y-this.y;return o*o+u*u},angle:function(){return Math.atan2(this.y,this.x)},angleTo:function(l){return Math.atan2(this.y-l.y,this.x-l.x)},angleWith:function(l){return this.angleWithSep(l.x,l.y)},angleWithSep:function(l,o){return Math.atan2(this.x*o-this.y*l,this.x*l+this.y*o)},_matMult:function(l){var o=l[2]*this.x+l[3]*this.y;return this.x=l[0]*this.x+l[1]*this.y,this.y=o,this},_add:function(l){return this.x+=l.x,this.y+=l.y,this},_sub:function(l){return this.x-=l.x,this.y-=l.y,this},_mult:function(l){return this.x*=l,this.y*=l,this},_div:function(l){return this.x/=l,this.y/=l,this},_multByPoint:function(l){return this.x*=l.x,this.y*=l.y,this},_divByPoint:function(l){return this.x/=l.x,this.y/=l.y,this},_unit:function(){return this._div(this.mag()),this},_perp:function(){var l=this.y;return this.y=this.x,this.x=-l,this},_rotate:function(l){var o=Math.cos(l),u=Math.sin(l),d=u*this.x+o*this.y;return this.x=o*this.x-u*this.y,this.y=d,this},_rotateAround:function(l,o){var u=Math.cos(l),d=Math.sin(l),p=o.y+d*(this.x-o.x)+u*(this.y-o.y);return this.x=o.x+u*(this.x-o.x)-d*(this.y-o.y),this.y=p,this},_round:function(){return this.x=Math.round(this.x),this.y=Math.round(this.y),this}},K.convert=function(l){return l instanceof K?l:Array.isArray(l)?new K(l[0],l[1]):l};var Y=j(Z);const me=Math.PI/180,ge=180/Math.PI;function ce(l){return l*me}function fe(l){return l*ge}const ie=[[0,0],[1,0],[1,1],[0,1]];function xe(l){if(l<=0)return 0;if(l>=1)return 1;const o=l*l,u=o*l;return 4*(l<.5?u:3*(l-o)+u-.75)}function Te(l,o,u,d){const p=new Q(l,o,u,d);return function(_){return p.solve(_)}}const oe=Te(.25,.1,.25,1);function ne(l,o,u){return Math.min(u,Math.max(o,l))}function le(l,o,u){return(u=ne((u-l)/(o-l),0,1))*u*(3-2*u)}function se(l,o,u){const d=u-o,p=((l-o)%d+d)%d+o;return p===o?u:p}function Ne(l,o,u){if(!l.length)return u(null,[]);let d=l.length;const p=new Array(l.length);let _=null;l.forEach((b,E)=>{o(b,(k,M)=>{k&&(_=k),p[E]=M,--d==0&&u(_,p)})})}function Se(l){const o=[];for(const u in l)o.push(l[u]);return o}function xt(l,...o){for(const u of o)for(const d in u)l[d]=u[d];return l}let kt=1;function wt(){return kt++}function Ue(){return function l(o){return o?(o^Math.random()*(16>>o/4)).toString(16):([1e7]+-[1e3]+-4e3+-8e3+-1e11).replace(/[018]/g,l)}()}function je(l){return l<=1?1:Math.pow(2,Math.ceil(Math.log(l)/Math.LN2))}function st(l){return!!l&&/^[0-9a-f]{8}-[0-9a-f]{4}-[4][0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}$/i.test(l)}function tt(l,o){l.forEach(u=>{o[u]&&(o[u]=o[u].bind(o))})}function Me(l,o){return l.indexOf(o,l.length-o.length)!==-1}function lt(l,o,u){const d={};for(const p in l)d[p]=o.call(u||this,l[p],p,l);return d}function Ae(l,o,u){const d={};for(const p in l)o.call(u||this,l[p],p,l)&&(d[p]=l[p]);return d}function we(l){return Array.isArray(l)?l.map(we):typeof l=="object"&&l?lt(l,we):l}const Je={};function ct(l){Je[l]||(typeof console<"u"&&console.warn(l),Je[l]=!0)}function mt(l,o,u){return(u.y-l.y)*(o.x-l.x)>(o.y-l.y)*(u.x-l.x)}function Vt(l){let o=0;for(let u,d,p=0,_=l.length,b=_-1;p<_;b=p++)u=l[p],d=l[b],o+=(d.x-u.x)*(u.y+d.y);return o}function Ie(){return typeof WorkerGlobalScope<"u"&&typeof self<"u"&&self instanceof WorkerGlobalScope}function Pe(l){const o={};if(l.replace(/(?:^|(?:\s*\,\s*))([^\x00-\x20\(\)<>@\,;\:\\"\/\[\]\?\=\{\}\x7F]+)(?:\=(?:([^\x00-\x20\(\)<>@\,;\:\\"\/\[\]\?\=\{\}\x7F]+)|(?:\"((?:[^"\\]|\\.)*)\")))?/g,(u,d,p,_)=>{const b=p||_;return o[d]=!b||b.toLowerCase(),""}),o["max-age"]){const u=parseInt(o["max-age"],10);isNaN(u)?delete o["max-age"]:o["max-age"]=u}return o}let rt=null;function Tt(l){if(rt==null){const o=l.navigator?l.navigator.userAgent:null;rt=!!l.safari||!(!o||!(/\b(iPad|iPhone|iPod)\b/.test(o)||o.match("Safari")&&!o.match("Chrome")))}return rt}function pn(l){try{const o=m[l];return o.setItem("_mapbox_test_",1),o.removeItem("_mapbox_test_"),!0}catch{return!1}}function qt(l,o){return[l[4*o],l[4*o+1],l[4*o+2],l[4*o+3]]}const nt="mapbox-tiles";let It=500,$t=50,$e,pt;function gn(){try{return m.caches}catch{}}function Pn(){gn()&&!$e&&($e=m.caches.open(nt))}function gr(l){const o=l.indexOf("?");if(o<0)return l;const u=function(p){const _=p.indexOf("?");return _>0?p.slice(_+1).split("&"):[]}(l),d=u.filter(p=>{const _=p.split("=");return _[0]==="language"||_[0]==="worldview"});return d.length?`${l.slice(0,o)}?${d.join("&")}`:l.slice(0,o)}let Ji=1/0;const Ni={Unknown:"Unknown",Style:"Style",Source:"Source",Tile:"Tile",Glyphs:"Glyphs",SpriteImage:"SpriteImage",SpriteJSON:"SpriteJSON",Image:"Image"};typeof Object.freeze=="function"&&Object.freeze(Ni);
113class Bo extends Error{constructor(o,u,d){u===401&&ht(d)&&(o+=": you may have provided an invalid Mapbox access token. See https://docs.mapbox.com/api/overview/#access-tokens-and-token-scopes"),super(o),this.status=u,this.url=d}toString(){return`${this.name}: ${this.message} (${this.status}): ${this.url}`}}const _i=Ie()?()=>self.worker&&self.worker.referrer:()=>(m.location.protocol==="blob:"?m.parent:m).location.href,Wr=function(l,o){if(!(/^file:/.test(u=l.url)||/^file:/.test(_i())&&!/^\w+:/.test(u))){if(m.fetch&&m.Request&&m.AbortController&&m.Request.prototype.hasOwnProperty("signal"))return function(d,p){const _=new m.AbortController,b=new m.Request(d.url,{method:d.method||"GET",body:d.body,credentials:d.credentials,headers:d.headers,referrer:_i(),referrerPolicy:d.referrerPolicy,signal:_.signal});let E=!1,k=!1;const M=(F=b.url).indexOf("sku=")>0&&ht(F);var F;d.type==="json"&&b.headers.set("Accept","application/json");const $=(X,J,re)=>{if(k)return;if(X&&X.message!=="SecurityError"&&ct(X.toString()),J&&re)return V(J);const pe=Date.now();m.fetch(b).then(Ce=>{if(Ce.ok){const ze=M?Ce.clone():null;return V(Ce,ze,pe)}return p(new Bo(Ce.statusText,Ce.status,d.url))}).catch(Ce=>{Ce.name!=="AbortError"&&p(new Error(`${Ce.message} ${d.url}`))})},V=(X,J,re)=>{(d.type==="arrayBuffer"?X.arrayBuffer():d.type==="json"?X.json():X.text()).then(pe=>{k||(J&&re&&function(Ce,ze,ke){if(Pn(),!$e)return;const Be={status:ze.status,statusText:ze.statusText,headers:new m.Headers};ze.headers.forEach((vt,ft)=>Be.headers.set(ft,vt));const We=Pe(ze.headers.get("Cache-Control")||"");if(We["no-store"])return;We["max-age"]&&Be.headers.set("Expires",new Date(ke+1e3*We["max-age"]).toUTCString());const Ge=Be.headers.get("Expires");Ge&&(new Date(Ge).getTime()-ke<42e4||function(vt,ft){if(pt===void 0)try{new Response(new ReadableStream),pt=!0}catch{pt=!1}pt?ft(vt.body):vt.blob().then(ft)}(ze,vt=>{const ft=new m.Response(vt,Be);Pn(),$e&&$e.then(Dt=>Dt.put(gr(Ce.url),ft)).catch(Dt=>ct(Dt.message))}))}(b,J,re),E=!0,p(null,pe,X.headers.get("Cache-Control"),X.headers.get("Expires")))}).catch(pe=>{k||p(new Error(pe.message))})};return M?function(X,J){if(Pn(),!$e)return J(null);const re=gr(X.url);$e.then(pe=>{pe.match(re).then(Ce=>{const ze=function(ke){if(!ke)return!1;const Be=new Date(ke.headers.get("Expires")||0),We=Pe(ke.headers.get("Cache-Control")||"");return Be>Date.now()&&!We["no-cache"]}(Ce);pe.delete(re),ze&&pe.put(re,Ce.clone()),J(null,Ce,ze)}).catch(J)}).catch(J)}(b,$):$(null,null),{cancel:()=>{k=!0,E||_.abort()}}}(l,o);if(Ie()&&self.worker&&self.worker.actor)return self.worker.actor.send("getResource",l,o,void 0,!0)}var u;return function(d,p){const _=new m.XMLHttpRequest;_.open(d.method||"GET",d.url,!0),d.type==="arrayBuffer"&&(_.responseType="arraybuffer");for(const b in d.headers)_.setRequestHeader(b,d.headers[b]);return d.type==="json"&&(_.responseType="text",_.setRequestHeader("Accept","application/json")),_.withCredentials=d.credentials==="include",_.onerror=()=>{p(new Error(_.statusText))},_.onload=()=>{if((_.status>=200&&_.status<300||_.status===0)&&_.response!==null){let b=_.response;if(d.type==="json")try{b=JSON.parse(_.response)}catch(E){return p(E)}p(null,b,_.getResponseHeader("Cache-Control"),_.getResponseHeader("Expires"))}else p(new Bo(_.statusText,_.status,d.url))},_.send(d.body),{cancel:()=>_.abort()}}(l,o)},Ao=function(l,o){return Wr(xt(l,{type:"arrayBuffer"}),o)};function xs(l){const o=m.document.createElement("a");return o.href=l,o.protocol===m.document.location.protocol&&o.host===m.document.location.host}const Fe="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAAC0lEQVQYV2NgAAIAAAUAAarVyFEAAAAASUVORK5CYII=";let ae,ue;ae=[],ue=0;const De=function(l,o){if(C.supported&&(l.headers||(l.headers={}),l.headers.accept="image/webp,*/*"),ue>=T.MAX_PARALLEL_IMAGE_REQUESTS){const _={requestParameters:l,callback:o,cancelled:!1,cancel(){this.cancelled=!0}};return ae.push(_),_}ue++;let u=!1;const d=()=>{if(!u)for(u=!0,ue--;ae.length&&ue<T.MAX_PARALLEL_IMAGE_REQUESTS;){const _=ae.shift(),{requestParameters:b,callback:E,cancelled:k}=_;k||(_.cancel=De(b,E).cancel)}},p=Ao(l,(_,b,E,k)=>{d(),_?o(_):b&&(m.createImageBitmap?function(M,F){const $=new m.Blob([new Uint8Array(M)],{type:"image/png"});m.createImageBitmap($).then(V=>{F(null,V)}).catch(V=>{F(new Error(`Could not load image because of ${V.message}. Please make sure to use a supported image type such as PNG or JPEG. Note that SVGs are not supported.`))})}(b,(M,F)=>o(M,F,E,k)):function(M,F){const $=new m.Image,V=m.URL;$.onload=()=>{F(null,$),V.revokeObjectURL($.src),$.onload=null,m.requestAnimationFrame(()=>{$.src=Fe})},$.onerror=()=>F(new Error("Could not load image. Please make sure to use a supported image type such as PNG or JPEG. Note that SVGs are not supported."));const X=new m.Blob([new Uint8Array(M)],{type:"image/png"});$.src=M.byteLength?V.createObjectURL(X):Fe}(b,(M,F)=>o(M,F,E,k)))});return{cancel:()=>{p.cancel(),d()}}},qe="NO_ACCESS_TOKEN";function Xe(l){return l.indexOf("mapbox:")===0}function ht(l){return T.API_URL_REGEX.test(l)}function ut(l){return T.API_CDN_URL_REGEX.test(l)}function Ke(l){return T.API_STYLE_REGEX.test(l)&&!Et(l)}function Et(l){return T.API_SPRITE_REGEX.test(l)}const en=/^(\w+):\/\/([^/?]*)(\/[^?]+)?\??(.+)?/;function ln(l){const o=l.match(en);if(!o)throw new Error("Unable to parse URL object");return{protocol:o[1],authority:o[2],path:o[3]||"/",params:o[4]?o[4].split("&"):[]}}function Kt(l){const o=l.params.length?`?${l.params.join("&")}`:"";return`${l.protocol}://${l.authority}${l.path}${o}`}const Xn="mapbox.eventData";function jn(l){if(!l)return null;const o=l.split(".");if(!o||o.length!==3)return null;try{return JSON.parse(decodeURIComponent(m.atob(o[1]).split("").map(u=>"%"+("00"+u.charCodeAt(0).toString(16)).slice(-2)).join("")))}catch{return null}}class Yn{constructor(o){this.type=o,this.anonId=null,this.eventData={},this.queue=[],this.pendingRequest=null}getStorageKey(o){const u=jn(T.ACCESS_TOKEN);let d="";return d=u&&u.u?m.btoa(encodeURIComponent(u.u).replace(/%([0-9A-F]{2})/g,(p,_)=>
113String.fromCharCode(+("0x"+_)))):T.ACCESS_TOKEN||"",o?`${Xn}.${o}:${d}`:`${Xn}:${d}`}fetchEventData(){const o=pn("localStorage"),u=this.getStorageKey(),d=this.getStorageKey("uuid");if(o)try{const p=m.localStorage.getItem(u);p&&(this.eventData=JSON.parse(p));const _=m.localStorage.getItem(d);_&&(this.anonId=_)}catch{ct("Unable to read from LocalStorage")}}saveEventData(){const o=pn("localStorage"),u=this.getStorageKey(),d=this.getStorageKey("uuid");if(o)try{m.localStorage.setItem(d,this.anonId),Object.keys(this.eventData).length>=1&&m.localStorage.setItem(u,JSON.stringify(this.eventData))}catch{ct("Unable to write to LocalStorage")}}processRequests(o){}postEvent(o,u,d,p){if(!T.EVENTS_URL)return;const _=ln(T.EVENTS_URL);_.params.push(`access_token=${p||T.ACCESS_TOKEN||""}`);const b={event:this.type,created:new Date(o).toISOString()},E=u?xt(b,u):b,k={url:Kt(_),headers:{"Content-Type":"text/plain"},body:JSON.stringify([E])};this.pendingRequest=function(M,F){return Wr(xt(M,{method:"POST"}),F)}(k,M=>{this.pendingRequest=null,d(M),this.saveEventData(),this.processRequests(p)})}queueRequest(o,u){this.queue.push(o),this.processRequests(u)}}const or=new class extends Yn{constructor(l){super("appUserTurnstile"),this._customAccessToken=l}postTurnstileEvent(l,o){T.EVENTS_URL&&T.ACCESS_TOKEN&&Array.isArray(l)&&l.some(u=>Xe(u)||ht(u))&&this.queueRequest(Date.now(),o)}processRequests(l){if(this.pendingRequest||this.queue.length===0)return;this.anonId&&this.eventData.lastSuccess&&this.eventData.tokenU||this.fetchEventData();const o=jn(T.ACCESS_TOKEN),u=o?o.u:T.ACCESS_TOKEN;let d=u!==this.eventData.tokenU;st(this.anonId)||(this.anonId=Ue(),d=!0);const p=this.queue.shift();if(this.eventData.lastSuccess){const _=new Date(this.eventData.lastSuccess),b=new Date(p),E=(p-this.eventData.lastSuccess)/864e5;d=d||E>=1||E<-1||_.getDate()!==b.getDate()}else d=!0;d?this.postEvent(p,{sdkIdentifier:"mapbox-gl-js",sdkVersion:g,skuId:N,"enabled.telemetry":!1,userId:this.anonId},_=>{_||(this.eventData.lastSuccess=p,this.eventData.tokenU=u)},l):this.processRequests()}},lr=or.postTurnstileEvent.bind(or),Gr=new class extends Yn{constructor(){super("map.load"),this.success={},this.skuToken=""}postMapLoadEvent(l,o,u,d){this.skuToken=o,this.errorCb=d,T.EVENTS_URL&&(u||T.ACCESS_TOKEN?this.queueRequest({id:l,timestamp:Date.now()},u):this.errorCb(new Error(qe)))}processRequests(l){if(this.pendingRequest||this.queue.length===0)return;const{id:o,timestamp:u}=this.queue.shift();o&&this.success[o]||(this.anonId||this.fetchEventData(),st(this.anonId)||(this.anonId=Ue()),this.postEvent(u,{sdkIdentifier:"mapbox-gl-js",sdkVersion:g,skuId:N,skuToken:this.skuToken,userId:this.anonId},d=>{d?this.errorCb(d):o&&(this.success[o]=!0)},l))}},Wi=Gr.postMapLoadEvent.bind(Gr),po=new class extends Yn{constructor(){super("gljs.performance")}postPerformanceEvent(l,o){T.EVENTS_URL&&(l||T.ACCESS_TOKEN)&&this.queueRequest({timestamp:Date.now(),performanceData:o},l)}processRequests(l){if(this.pendingRequest||this.queue.length===0)return;const{timestamp:o,performanceData:u}=this.queue.shift(),d=function(p){const _=m.performance.getEntriesByType("resource"),b=m.performance.getEntriesByType("mark"),E=function(V){const X={};if(V){for(const J in V)if(J!=="other")for(const re of V[J]){const pe=`${J}ResolveRangeMin`,Ce=`${J}ResolveRangeMax`,ze=`${J}RequestCount`,ke=`${J}RequestCachedCount`;X[pe]=Math.min(X[pe]||1/0,re.startTime),X[Ce]=Math.max(X[Ce]||-1/0,re.responseEnd);const Be=We=>{X[We]===void 0&&(X[We]=0),++X[We]};re.transferSize!==void 0&&re.transferSize===0&&Be(ke),Be(ze)}}return X}(function(V,X){const J={};if(V)for(const re of V){const pe=X(re);J[pe]===void 0&&(J[pe]=[]),J[pe].push(re)}return J}(_,Cp)),k=m.devicePixelRatio,M=m.navigator.connection||m.navigator.mozConnection||m.navigator.webkitConnection,F={counters:[],metadata:[],attributes:[]},$=(V,X,J)=>{J!=null&&V.push({name:X,value:J.toString()})};for(const V in E)$(F.counters,V,E[V]);if(p.interactionRange[0]!==1/0&&p.interactionRange[1]!==-1/0&&($(F.counters,"interactionRangeMin",p.interactionRange[0]),$(F.counters,"interactionRangeMax",p.interactionRange[1])),b)for(const V of Object.keys(Lc)){const X=Lc[V],J=b.find(re=>re.name===X);J&&$(F.counters,X,J.startTime)}return $(F.counters,"visibilityHidden",p.visibilityHidden),$(F.attributes,"style",function(V){if(V)for(const X of V){const J=X.name.split("?")[0];if(Ke(J)){const re=J.split("/").slice(-2);if(re.length===2)return`mapbox://styles/${re[0]}/${re[1]}`}}}(_)),$(F.attributes,"terrainEnabled",p.terrainEnabled?"true":"false"),$(F.attributes,"fogEnabled",p.fogEnabled?"true":"false"),$(F.attributes,"projection",p.projection),$(F.attributes,"zoom",p.zoom),$(F.metadata,"devicePixelRatio",k),$(F.metadata,"connectionEffectiveType",M?M.effectiveType:void 0),$(F.metadata,"navigatorUserAgent",m.navigator.userAgent),$(F.metadata,"screenWidth",m.screen.width),$(F.metadata,"screenHeight",m.screen.height),$(F.metadata,"windowWidth",m.innerWidth),$(F.metadata,"windowHeight",m.innerHe
113ight),$(F.metadata,"mapWidth",p.width/k),$(F.metadata,"mapHeight",p.height/k),$(F.metadata,"webglRenderer",p.renderer),$(F.metadata,"webglVendor",p.vendor),$(F.metadata,"sdkVersion",g),$(F.metadata,"sdkIdentifier","mapbox-gl-js"),F}(u);for(const p of d.metadata);for(const p of d.counters);for(const p of d.attributes);this.postEvent(o,d,()=>{},l)}},$i=po.postPerformanceEvent.bind(po),ws=new class extends Yn{constructor(){super("map.auth"),this.success={},this.skuToken=""}getSession(l,o,u,d){if(!T.API_URL||!T.SESSION_PATH)return;const p=ln(T.API_URL+T.SESSION_PATH);p.params.push(`sku=${o||""}`),p.params.push(`access_token=${d||T.ACCESS_TOKEN||""}`);const _={url:Kt(p),headers:{"Content-Type":"text/plain"}};this.pendingRequest=function(b,E){return Wr(xt(b,{method:"GET"}),E)}(_,b=>{this.pendingRequest=null,u(b),this.saveEventData(),this.processRequests(d)})}getSessionAPI(l,o,u,d){this.skuToken=o,this.errorCb=d,T.SESSION_PATH&&T.API_URL&&(u||T.ACCESS_TOKEN?this.queueRequest({id:l,timestamp:Date.now()},u):this.errorCb(new Error(qe)))}processRequests(l){if(this.pendingRequest||this.queue.length===0)return;const{id:o,timestamp:u}=this.queue.shift();o&&this.success[o]||this.getSession(u,this.skuToken,d=>{d?this.errorCb(d):o&&(this.success[o]=!0)},l)}},Po=ws.getSessionAPI.bind(ws),Hr=new Set,Lc={create:"create",load:"load",fullLoad:"fullLoad"},Ig={mark(l){m.performance.mark(l)},measure(l,o,u){m.performance.measure(l,o,u)}};function Cp(l){const o=l.name.split("?")[0];return ut(o)&&o.includes("mapbox-gl.js")?"javascript":ut(o)&&o.includes("mapbox-gl.css")?"css":function(u){return T.API_FONTS_REGEX.test(u)}(o)?"fontRange":Et(o)?"sprite":Ke(o)?"style":function(u){return T.API_TILEJSON_REGEX.test(u)}(o)?"tilejson":"other"}const Er=m.performance;function Ud(l){const o=l?l.url.toString():void 0;return Er.getEntriesByName(o)}let Jl,Vd,ec,$a;const is={now:()=>ec!==void 0?ec:m.performance.now(),setNow(l){ec=l},restoreNow(){ec=void 0},frame(l){const o=m.requestAnimationFrame(l);return{cancel:()=>m.cancelAnimationFrame(o)}},getImageData(l,o=0){const{width:u,height:d}=l;$a||($a=m.document.createElement("canvas"));const p=$a.getContext("2d",{willReadFrequently:!0});if(!p)throw new Error("failed to create canvas 2d context");return(u>$a.width||d>$a.height)&&($a.width=u,$a.height=d),p.clearRect(-o,-o,u+2*o,d+2*o),p.drawImage(l,0,0,u,d),p.getImageData(-o,-o,u+2*o,d+2*o)},resolveURL:l=>(Jl||(Jl=m.document.createElement("a")),Jl.href=l,Jl.href),get devicePixelRatio(){return m.devicePixelRatio},get prefersReducedMotion(){return!!m.matchMedia&&(Vd==null&&(Vd=m.matchMedia("(prefers-reduced-motion: reduce)")),Vd.matches)}};function eo(l,o,u){u[l]&&u[l].indexOf(o)!==-1||(u[l]=u[l]||[],u[l].push(o))}function hh(l,o,u){if(u&&u[l]){const d=u[l].indexOf(o);d!==-1&&u[l].splice(d,1)}}class vl{constructor(o,u={}){xt(this,u),this.type=o}}class Wo extends vl{constructor(o,u={}){super("error",xt({error:o},u))}}class fa{on(o,u){return this._listeners=this._listeners||{},eo(o,u,this._listeners),this}off(o,u){return hh(o,u,this._listeners),hh(o,u,this._oneTimeListeners),this}once(o,u){return u?(this._oneTimeListeners=this._oneTimeListeners||{},eo(o,u,this._oneTimeListeners),this):new Promise(d=>this.once(o,d))}fire(o,u){typeof o=="string"&&(o=new vl(o,u||{}));const d=o.type;if(this.listens(d)){o.target=this;const p=this._listeners&&this._listeners[d]?this._listeners[d].slice():[];for(const E of p)E.call(this,o);const _=this._oneTimeListeners&&this._oneTimeListeners[d]?this._oneTimeListeners[d].slice():[];for(const E of _)hh(d,E,this._oneTimeListeners),E.call(this,o);const b=this._eventedParent;b&&(xt(o,typeof this._eventedParentData=="function"?this._eventedParentData():this._eventedParentData),b.fire(o))}else o instanceof Wo&&console.error(o.error);return this}listens(o){return!!(this._listeners&&this._listeners[o]&&this._listeners[o].length>0||this._oneTimeListeners&&this._oneTimeListeners[o]&&this._oneTimeListeners[o].length>0||this._eventedParent&&this._eventedParent.listens(o))}setEventedParent(o,u){return this._eventedParent=o,this._eventedParentData=u,this}}var Pt=JSON.parse('{"$version":8,"$root":{"version":{"required":true,"type":"enum","values":[8]},"name":{"type":"string"},"metadata":{"type":"*"},"center":{"type":"array","value":"number"},"zoom":{"type":"number"},"bearing":{"type":"number","default":0,"period":360,"units":"degrees"},"pitch":{"type":"number","default":0,"units":"degrees"},"light":{"type":"light"},"terrain":{"type":"terrain"},"fog":{"type":"fog"},"sources":{"required":true,"type":"sources"},"sprite":{"type":"string"},"glyphs":{"type":"string"},"transition":{"type":"transition"},"projection":{"type":"projection"},"layers":{"required":true,"type":"array","value":"layer"}},"sources":{"*":{"type":"source"}},"source":["source_vector","source_raster","source_raster_dem","source_geojson","source_video","source_image"],"source_vector":{"type":{"required":true,"type":"enum","values":{"vector":{}}},"url":{"type":"string"},"tiles":{"type":"array","value":"string"},"bounds":{"type":"array","value":"number","length":4,"default":[-180,-85.051129,180,85.051129]},"scheme":{"type":"enum","values":{"xyz":{},"tms":{}},"default":"xyz"},"minzoom":{"type":"number","default":0},"maxzoom":{"type":"number","default":22},"attribution":{"type":"string"},"promoteId":{"type":"promoteId"},"volatile":{"type":"boolean","default":false},"*":{"type":"*"}},"source_raster":{"type":{"required":true,"type":"enum","values":{"raster":{}}},"url":{"type":"string"},"tiles":{"type":"array","value":"string"},"bounds":{"type":"array","value":"number","length":4,"default":[-180,-85.051129,180,85.051129]},"minzoom":{"type":"number","default":0},"maxzoom":{"type":"number","default":22},"tileSize":{"type":"number","default":512,"units":"pixels"},"scheme":{"type":"enum","values":{"xyz":{},"tms":{}},"default":"xyz"},"attribution":{"type":"string"},"volatile":{"type":"boolean","default":false},"*":{"type":"*"}},"source_raster_dem":{"type":{"required":true,"type":"enum","values":{"raster-dem":{}}},"url":{"type":"string"},"tiles":{"type":"array","value":"string"},"bounds":{"type":"array","value":"number","length":4,"default":[-180,-85.051129,180,85.051129]},"minzoom":{"type":"number","default":0},"maxzoom":{"type":"number","default":22},"tileSize":{"type":"number","default":512,"units":"pixels"},"attribution":{"type":"string"},"encoding":{"type":"enum","values":{"terrarium":{},"mapbox":{}},"default":"mapbox"},"volatile":{"type":"boolean","default":false},"*":{"type":"*"}},"source_geojson":{"type":{"required":true,"type":"enum","values":{"geojson":{}}},"data":{"type":"*"},"maxzoom":{"type":"number","default":18},"attribution":{"type":"string"},"buffer":{"type":"number","default":128,"maximum":512,"minimum":0},"filter":{"type":"*"},"tolerance":{"type":"number","default":0.375},"cluster":{"type":"boolean","default":false},"clusterRadius":{"type":"number","default":50,"minimum":0}
113,"clusterMaxZoom":{"type":"number"},"clusterMinPoints":{"type":"number"},"clusterProperties":{"type":"*"},"lineMetrics":{"type":"boolean","default":false},"generateId":{"type":"boolean","default":false},"promoteId":{"type":"promoteId"}},"source_video":{"type":{"required":true,"type":"enum","values":{"video":{}}},"urls":{"required":true,"type":"array","value":"string"},"coordinates":{"required":true,"type":"array","length":4,"value":{"type":"array","length":2,"value":"number"}}},"source_image":{"type":{"required":true,"type":"enum","values":{"image":{}}},"url":{"required":true,"type":"string"},"coordinates":{"required":true,"type":"array","length":4,"value":{"type":"array","length":2,"value":"number"}}},"layer":{"id":{"type":"string","required":true},"type":{"type":"enum","values":{"fill":{},"line":{},"symbol":{},"circle":{},"heatmap":{},"fill-extrusion":{},"raster":{},"hillshade":{},"background":{},"sky":{}},"required":true},"metadata":{"type":"*"},"source":{"type":"string"},"source-layer":{"type":"string"},"minzoom":{"type":"number","minimum":0,"maximum":24},"maxzoom":{"type":"number","minimum":0,"maximum":24},"filter":{"type":"filter"},"layout":{"type":"layout"},"paint":{"type":"paint"}},"layout":["layout_fill","layout_line","layout_circle","layout_heatmap","layout_fill-extrusion","layout_symbol","layout_raster","layout_hillshade","layout_background","layout_sky"],"layout_background":{"visibility":{"type":"enum","values":{"visible":{},"none":{}},"default":"visible","property-type":"constant"}},"layout_sky":{"visibility":{"type":"enum","values":{"visible":{},"none":{}},"default":"visible","property-type":"constant"}},"layout_fill":{"fill-sort-key":{"type":"number","expression":{"interpolated":false,"parameters":["zoom","feature"]},"property-type":"data-driven"},"visibility":{"type":"enum","values":{"visible":{},"none":{}},"default":"visible","property-type":"constant"}},"layout_circle":{"circle-sort-key":{"type":"number","expression":{"interpolated":false,"parameters":["zoom","feature"]},"property-type":"data-driven"},"visibility":{"type":"enum","values":{"visible":{},"none":{}},"default":"visible","property-type":"constant"}},"layout_heatmap":{"visibility":{"type":"enum","values":{"visible":{},"none":{}},"default":"visible","property-type":"constant"}},"layout_fill-extrusion":{"visibility":{"type":"enum","values":{"visible":{},"none":{}},"default":"visible","property-type":"constant"},"fill-extrusion-edge-radius":{"type":"number","private":true,"default":0,"minimum":0,"maximum":1
vendor: 16,128 bytes, line 113
113,"property-type":"constant"}},"layout_line":{"line-cap":{"type":"enum","values":{"butt":{},"round":{},"square":{}},"default":"butt","expression":{"interpolated":false,"parameters":["zoom","feature"]},"property-type":"data-driven"},"line-join":{"type":"enum","values":{"bevel":{},"round":{},"miter":{}},"default":"miter","expression":{"interpolated":false,"parameters":["zoom","feature"]},"property-type":"data-driven"},"line-miter-limit":{"type":"number","default":2,"requires":[{"line-join":"miter"}],"expression":{"interpolated":true,"parameters":["zoom"]},"property-type":"data-constant"},"line-round-limit":{"type":"number","default":1.05,"requires":[{"line-join":"round"}],"expression":{"interpolated":true,"parameters":["zoom"]},"property-type":"data-constant"},"line-sort-key":{"type":"number","expression":{"interpolated":false,"parameters":["zoom","feature"]},"property-type":"data-driven"},"visibility":{"type":"enum","values":{"visible":{},"none":{}},"default":"visible","property-type":"constant"}},"layout_symbol":{"symbol-placement":{"type":"enum","values":{"point":{},"line":{},"line-center":{}},"default":"point","expression":{"interpolated":false,"parameters":["zoom"]},"property-type":"data-constant"},"symbol-spacing":{"type":"number","default":250,"minimum":1,"units":"pixels","requires":[{"symbol-placement":"line"}],"expression":{"interpolated":true,"parameters":["zoom"]},"property-type":"data-constant"},"symbol-avoid-edges":{"type":"boolean","default":false,"expression":{"interpolated":false,"parameters":["zoom"]},"property-type":"data-constant"},"symbol-sort-key":{"type":"number","expression":{"interpolated":false,"parameters":["zoom","feature"]},"property-type":"data-driven"},"symbol-z-order":{"type":"enum","values":{"auto":{},"viewport-y":{},"source":{}},"default":"auto","expression":{"interpolated":false,"parameters":["zoom"]},"property-type":"data-constant"},"icon-allow-overlap":{"type":"boolean","default":false,"requires":["icon-image"],"expression":{"interpolated":false,"parameters":["zoom"]},"property-type":"data-constant"},"icon-ignore-placement":{"type":"boolean","default":false,"requires":["icon-image"],"expression":{"interpolated":false,"parameters":["zoom"]},"property-type":"data-constant"},"icon-optional":{"type":"boolean","default":false,"requires":["icon-image","text-field"],"expression":{"interpolated":false,"parameters":["zoom"]},"property-type":"data-constant"},"icon-rotation-alignment":{"type":"enum","values":{"map":{},"viewport":{},"auto":{}},"default":"auto","requires":["icon-image"],"expression":{"interpolated":false,"parameters":["zoom"]},"property-type":"data-constant"},"icon-size":{"type":"number","default":1,"minimum":0,"units":"factor of the original icon size","requires":["icon-image"],"expression":{"interpolated":true,"parameters":["zoom","feature"]},"property-type":"data-driven"},"icon-text-fit":{"type":"enum","values":{"none":{},"width":{},"height":{},"both":{}},"default":"none","requires":["icon-image","text-field"],"expression":{"interpolated":false,"parameters":["zoom"]},"property-type":"data-constant"},"icon-text-fit-padding":{"type":"array","value":"number","length":4,"default":[0,0,0,0],"units":"pixels","requires":["icon-image","text-field",{"icon-text-fit":["both","width","height"]}],"expression":{"interpolated":true,"parameters":["zoom"]},"property-type":"data-constant"},"icon-image":{"type":"resolvedImage","tokens":true,"expression":{"interpolated":false,"parameters":["zoom","feature"]},"property-type":"data-driven"},"icon-rotate":{"type":"number","default":0,"period":360,"units":"degrees","requires":["icon-image"],"expression":{"interpolated":true,"parameters":["zoom","feature"]},"property-type":"data-driven"},"icon-padding":{"type":"number","default":2,"minimum":0,"units":"pixels","requires":["icon-image"],"expression":{"interpolated":true,"parameters":["zoom"]},"property-type":"data-constant"},"icon-keep-upright":{"type":"boolean","default":false,"requires":["icon-image",{"icon-rotation-alignment":"map"},{"symbol-placement":["line","line-center"]}],"expression":{"interpolated":false,"parameters":["zoom"]},"property-type":"data-constant"},"icon-offset":{"type":"array","value":"number","length":2,"default":[0,0],"requires":["icon-image"],"expression":{"interpolated":true,"parameters":["zoom","feature"]},"property-type":"data-driven"},"icon-anchor":{"type":"enum","values":{"center":{},"left":{},"right":{},"top":{},"bottom":{},"top-left":{},"top-right":{},"bottom-left":{},"bottom-right":{}},"default":"center","requires":["icon-image"],"expression":{"interpolated":false,"parameters":["zoom","feature"]},"property-type":"data-driven"},"icon-pitch-alignment":{"type":"enum","values":{"map":{},"viewport":{},"auto":{}},"default":"auto","requires":["icon-image"],"expression":{"interpolated":false,"parameters":["zoom"]},"property-type":"data-constant"},"text-pitch-alignment":{"type":"enum","values":{"map":{},"viewport":{},"auto":{}},"default":"auto","requires":["text-field"],"expression":{"interpolated":false,"parameters":["zoom"]},"property-type":"data-constant"},"text-rotation-alignment":{"type":"enum","values":{"map":{},"viewport":{},"auto":{}},"default":"auto","requires":["text-field"],"expression":{"interpolated":false,"parameters":["zoom"]},"property-type":"data-constant"},"text-field":{"type":"formatted","default":"","tokens":true,"expression":{"interpolated":false,"parameters":["zoom","feature"]},"property-type":"data-driven"},"text-font":{"type":"array","value":"string","default":["Open Sans Regular","Arial Unicode MS Regular"],"requires":["text-field"],"expression":{"interpolated":false,"parameters":["zoom","feature"]},"property-type":"data-driven"},"text-size":{"type":"number","default":16,"minimum":0,"units":"pixels","requires":["text-field"],"expression":{"interpolated":true,"parameters":["zoom","feature"]},"property-type":"data-driven"},"text-max-width":{"type":"number","default":10,"minimum":0,"units":"ems","requires":["text-field",{"symbol-placement":["point"]}],"expression":{"interpolated":true,"parameters":["zoom","feature"]},"property-type":"data-driven"},"text-line-height":{"type":"number","default":1.2,"units":"ems","requires":["text-field"],"expression":{"interpolated":true,"parameters":["zoom","feature"]},"property-type":"data-driven"},"text-letter-spacing":{"type":"number","default":0,"units":"ems","requires":["text-field"],"expression":{"interpolated":true,"parameters":["zoom","feature"]},"property-type":"data-driven"},"text-justify":{"type":"enum","values":{"auto":{},"left":{},"center":{},"right":{}},"default":"center","requires":["text-field"],"expression":{"interpolated":false,"parameters":["zoom","feature"]},"property-type":"data-driven"},"text-radial-offset":{"type":"number","units":"ems","default":0,"requires":["text-field"],"property-type":"data-driven","expression":{"interpolated":true,"parameters":["zoom","feature"]}},"text-variable-anchor":{"type":"array","value":"enum","values":{"center":{},"left":{},"right":{},"top":{},"bottom":{},"top-left":{},"top-right":{},"bottom-left":{},"bottom-right":{}},"requires":["text-field",{"symbol-placement":["point"]}],"expression":{"interpolated":false,"parameters":["zoom"]},"property-type":"data-constant"},"text-anchor":{"type":"enum","values":{"center":{},"left":{},"right":{},"top":{},"bottom":{},"top-left":{},"top-right":{},"bottom-left":{},"bottom-right":{}},"default":"center","requires":["text-field",{"!":"text-variable-anchor"}],"expression":{"interpolated":false,"parameters":["zoom","feature"]},"property-type":"data-driven"},"text-max-angle":{"type":"number","default":45,"units":"degrees","requires":["text-field",{"symbol-placement":["line","line-center"]}],"expression":{"interpolated":true,"parameters":["zoom"]},"property-type":"data-constant"},"text-writing-mode":{"type":"array","value":"enum","values":{"horizontal":{},"vertical":{}},"requires":["text-field"],"expression":{"interpolated":false,"parameters":["zoom"]},"property-type":"data-constant"},"text-rotate":{"type":"number","default":0,"period":360,"units":"degrees","requires":["text-field"],"expression":{"interpolated":true,"parameters":["zoom","feature"]},"property-type":"data-driven"},"text-padding":{"type":"number","default":2,"minimum":0,"units":"pixels","requires":["text-field"],"expression":{"interpolated":true,"parameters":["zoom"]},"property-type":"data-constant"},"text-keep-upright":{"type":"boolean","default":true,"requires":["text-field",{"text-rotation-alignment":"map"},{"symbol-placement":["line","line-center"]}],"expression":{"interpolated":false,"parameters":["zoom"]},"property-type":"data-constant"},"text-transform":{"type":"enum","values":{"none":{},"uppercase":{},"lowercase":{}},"default":"none","requires":["text-field"],"expression":{"interpolated":false,"parameters":["zoom","feature"]},"property-type":"data-driven"},"text-offset":{"type":"array","value":"number","units":"ems","length":2,"default":[0,0],"requires":["text-field",{"!":"text-radial-offset"}],"expression":{"interpolated":true,"parameters":["zoom","feature"]},"property-type":"data-driven"},"text-allow-overlap":{"type":"boolean","default":false,"requires":["text-field"],"expression":{"interpolated":false,"parameters":["zoom"]},"property-type":"data-constant"},"text-ignore-placement":{"type":"boolean","default":false,"requires":["text-field"],"expression":{"interpolated":false,"parameters":["zoom"]},"property-type":"data-constant"},"text-optional":{"type":"boolean","default":false,"requires":["text-field","icon-image"],"expression":{"interpolated":false,"parameters":["zoom"]},"property-type":"data-constant"},"visibility":{"type":"enum","values":{"visible":{},"none":{}},"default":"visible","property-type":"constant"}},"layout_raster":{"visibility":{"type":"enum","values":{"visible":{},"none":{}},"default":"visible","property-type":"constant"}},"layout_hillshade":{"visibility":{"type":"enum","values":{"visible":{},"none":{}},"default":"visible","property-type":"constant"}},"filter":{"type":"array","value":"*"},"filter_symbol":{"type":"boolean","default":false,"transition":false,"property-type":"data-driven","expression":{"interpolated":false,"parameters":["zoom","feature","pitch","distance-from-center"]}},"filter_fill":{"type":"boolean","default":false,"transition":false,"property-type":"data-driven","expression":{"interpolated":false,"parameters":["zoom","feature"]}},"filter_line":{"type":"boolean","default":false,"transition":false,"property-type":"data-driven","expression":{"interpolated":false,"parameters":["zoom","feature"]}},"filter_circle":{"type":"boolean","default":false,"transition":false,"property-type":"data-driven","expression":{"interpolated":false,"parameters":["zoom","feature"]}},"filter_fill-extrusion":{"type":"boolean","default":false,"transition":false,"property-type":"data-driven","expression":{"interpolated":false,"parameters":["zoom","feature"]}},"filter_heatmap":{"type":"boolean","default":false,"transition":false,"property-type":"data-driven","expression":{"interpolated":false,"parameters":["zoom","feature"]}},"filter_operator":{"type":"enum","values":{"==":{},"!=":{},">":{},">=":{},"<":{},"<=":{},"in":{},"!in":{},"all":{},"any":{},"none":{},"has":{},"!has":{},"within":{}}},"geometry_type":{"type":"enum","values":{"Point":{},"LineString":{},"Polygon":{}}},"function":{"expression":{"type":"expression"},"stops":{"type":"array","value":"function_stop"},"base":{"type":"number","default":1,"minimum":0},"property":{"type":"string","default":"$zoom"},"type":{"type":"enum","values":{"identity":{},"exponential":{},"interval":{},"categorical":{}},"default":"exponential"},"colorSpace":{"type":"enum","values":{"rgb":{},"lab":{},"hcl":{}},"default":"rgb"},"default":{"type":"*","required":false}},"function_stop":{"type":"array","minimum":0,"maximum":24,"value":["number","color"],"length":2},"expression":{"type":"array","value":"*","minimum":1},"fog":{"range":{"type":"array","default":[0.5,10],"minimum":-20,"maximum":20,"length":2,"value":"number","property-type":"data-constant","transition":true,"expression":{"interpolated":true,"parameters":["zoom"]}},"color":{"type":"color","property-type":"data-constant","default":"#ffffff","expression":{"interpolated":true,"parameters":["zoom"]},"transition":true},"high-color":{"type":"color","property-type":"data-constant","default":"#245cdf","expression":{"interpolated":true,"parameters":["zoom"]},"transition":true},"space-color":{"type":"color","property-type":"data-constant","default":["interpolate",["linear"],["zoom"],4,"#010b19",7,"#367ab9"],"expression":{"interpolated":true,"parameters":["zoom"]},"transition":true},"horizon-blend":{"type":"number","property-type":"data-constant","default":["interpolate",["linear"],["zoom"],4,0.2,7,0.1],"minimum":0,"maximum":1,"expression":{"interpolated":true,"parameters":["zoom"]},"transition":true},"star-intensity":{"type":"number","property-type":"data-constant","default":["interpolate",["linear"],["zoom"],5,0.35,6,0],"minimum":0,"maximum":1,"expression":{"interpolated":true,"parameters":["zoom"]},"transition":true}},"light":{"anchor":{"type":"enum","default":"viewport","values":{"map":{},"viewport":{}},"property-type":"data-constant","transition":false,"expression":{"interpolated":false,"parameters":["zoom"]}},"position":{"type":"array","default":[1.15,210,30],"length":3,"value":"number","property-type":"data-constant","transition":true,"expression":{"interpolated":true,"parameters":["zoom"]}},"color":{"type":"color","property-type":"data-constant","default":"#ffffff","expression":{"interpolated":true,"parameters":["zoom"]},"transition":true},"intensity":{"type":"number","property-type":"data-constant","default":0.5,"minimum":0,"maximum":1,"expression":{"interpolated":true,"parameters":["zoom"]},"transition":true}},"projection":{"name":{"type":"enum","values":{"albers":{},"equalEarth":{},"equirectangular":{},"lambertConformalConic":{},"mercator":{},"naturalEarth":{},"winkelTripel":{},"globe":{}},"default":"mercator","required":true},"center":{"type":"array","length":2,"value":"number","property-type":"data-constant","minimum":[-180,-90],"maximum":[180,90],"transition":false,"requires":[{"name":["albers","lambertConformalConic"]}]},"parallels":{"type":"array","length":2,"value":"number","property-type":"data-constant","minimum":[-90,-90],"maximum":[90,90],"transition":false,"requires":[{"name":["albers","lambertConformalConic"]}]}},"terrain":{"source":{"type":"string","required":true},"exaggeration":{"type":"number","property-type":"data-constant","default":1,"minimum":0,"maximum":1000,"expression":{"interpolated":true,"parameters":["zoom"]},"transition":true,"requires":["source"]}},"paint":["paint_fill","paint_line","paint_circle","paint_heatmap","paint_fill-extrusion","paint_symbol","paint_raster","paint_hillshade","paint_background","paint_sky"],"paint_fill":{"fill-antialias":{"type":"boolean","default":true,"expression":{"interpolated":false,"parameters":["zoom"]},"property-type":"data-constant"},"fill-opacity":{"type":"number","default":1,"minimum":0,"maximum":1,"transition":true,"expression":{"interpolated":true,"parameters":["zoom","feature","feature-state"]},"property-type":"data-driven"},"fill-color":{"type":"color","default":"#000000","transition":true,"requires":[{"!":"fill-pattern"}],"expression":{"interpolated":true,"parameters":["zoom","feature","feature-state"]},"property-type":"data-driven"},"fill-outline-color":{"type":"color","transition":true,"requires":[{"!":"fill-pattern"},{"fill-antialias":true}],"expression":{"interpolated":true,"parameters":["zoom","feature","feature-state"]},"property-type":"data-driven"},"fill-translate":{"type":"array","value":"number","length":2,"default":[0,0],"transition":true,"units":"pixels","expression":{"interpolated":true,"parameters":["zoom"]},"property-type":"data-constant"},"fill-translate-anchor":{"type":"enum","values":{"map":{},"viewport":{}},"default":"map","requires":["fill-translate"],"expression":{"interpolated":false,"parameters":["zoom"]},"property-type":"data-constant"},"fill-pattern":{"type":"resolvedImage","transition":
vendor: 3,928 bytes, line 113
113false,"expression":{"interpolated":false,"parameters":["zoom","feature"]},"property-type":"data-driven"}},"paint_fill-extrusion":{"fill-extrusion-opacity":{"type":"number","default":1,"minimum":0,"maximum":1,"transition":true,"expression":{"interpolated":true,"parameters":["zoom"]},"property-type":"data-constant"},"fill-extrusion-color":{"type":"color","default":"#000000","transition":true,"requires":[{"!":"fill-extrusion-pattern"}],"expression":{"interpolated":true,"parameters":["zoom","feature","feature-state"]},"property-type":"data-driven"},"fill-extrusion-translate":{"type":"array","value":"number","length":2,"default":[0,0],"transition":true,"units":"pixels","expression":{"interpolated":true,"parameters":["zoom"]},"property-type":"data-constant"},"fill-extrusion-translate-anchor":{"type":"enum","values":{"map":{},"viewport":{}},"default":"map","requires":["fill-extrusion-translate"],"expression":{"interpolated":false,"parameters":["zoom"]},"property-type":"data-constant"},"fill-extrusion-pattern":{"type":"resolvedImage","transition":false,"expression":{"interpolated":false,"parameters":["zoom","feature"]},"property-type":"data-driven"},"fill-extrusion-height":{"type":"number","default":0,"minimum":0,"units":"meters","transition":true,"expression":{"interpolated":true,"parameters":["zoom","feature","feature-state"]},"property-type":"data-driven"},"fill-extrusion-base":{"type":"number","default":0,"minimum":0,"units":"meters","transition":true,"requires":["fill-extrusion-height"],"expression":{"interpolated":true,"parameters":["zoom","feature","feature-state"]},"property-type":"data-driven"},"fill-extrusion-vertical-gradient":{"type":"boolean","default":true,"transition":false,"expression":{"interpolated":false,"parameters":["zoom"]},"property-type":"data-constant"},"fill-extrusion-ambient-occlusion-intensity":{"property-type":"data-constant","type":"number","private":true,"default":0,"minimum":0,"maximum":1,"expression":{"interpolated":true,"parameters":["zoom"]},"transition":true},"fill-extrusion-ambient-occlusion-radius":{"property-type":"data-constant","type":"number","private":true,"default":3,"minimum":0,"expression":{"interpolated":true,"parameters":["zoom"]},"transition":true,"requires":["fill-extrusion-edge-radius"]},"fill-extrusion-rounded-roof":{"type":"boolean","default":true,"requires":["fill-extrusion-edge-radius"],"transition":false,"expression":{"interpolated":false,"parameters":["zoom"]},"property-type":"data-constant"}},"paint_line":{"line-opacity":{"type":"number","default":1,"minimum":0,"maximum":1,"transition":true,"expression":{"interpolated":true,"parameters":["zoom","feature","feature-state"]},"property-type":"data-driven"},"line-color":{"type":"color","default":"#000000","transition":true,"requires":[{"!":"line-pattern"}],"expression":{"interpolated":true,"parameters":["zoom","feature","feature-state"]},"property-type":"data-driven"},"line-translate":{"type":"array","value":"number","length":2,"default":[0,0],"transition":true,"units":"pixels","expression":{"interpolated":true,"parameters":["zoom"]},"property-type":"data-constant"},"line-translate-anchor":{"type":"enum","values":{"map":{},"viewport":{}},"default":"map","requires":["line-translate"],"expression":{"interpolated":false,"parameters":["zoom"]},"property-type":"data-constant"},"line-width":{"type":"number","default":1,"minimum":0,"transition":true,"units":"pixels","expression":{"interpolated":true,"parameters":["zoom","feature","feature-state"]},"property-type":"data-driven"},"line-gap-width":{"type":"number","default":0,"minimum":0,"transition":true,"units":"pixels","expression":{"interpolated":true,"parameters":["zoom","feature","feature-state"]},"property-type":"data-driven"},"line-offset":{"type":"number","default":0,"transition":true,"units":"pixels","expression":{"interpolated":true,"parameters":["zoom","feature","feature-state"]},"property-type":"data-driven"}
113,"line-blur":{"type":"number","default":0,"minimum":0,"transition":true,"units":"pixels","expression":{"interpolated":true,"parameters":["zoom","feature","feature-state"]},"property-type":"data-driven"},"line-dasharray":{"type":"array","value":"number","minimum":0,"transition":false,"units":"line widths","requires":[{"!":"line-pattern"}],"expression":{"interpolated":false,"parameters":["zoom","feature"]},"property-type":"data-driven"},"line-pattern":{"type":"resolvedImage","transition":false,"expression":{"interpolated":false,"parameters":["zoom","feature"]},"property-type":"data-driven"},"line-gradient":{"type":"color","transition":false,"requires":[{"!":"line-pattern"},{"source":"geojson","has":{"lineMetrics":true}}],"expression":{"interpolated":true,"parameters":["line-progress"]},"property-type":"color-ramp"},"line-trim-offset":{"type":"array","value":"number","length":2,"default":[0,0],"minimum":[0,0],"maximum":[1,1],"transition":false,"requires":[{"source":"geojson","has":{"lineMetrics":true}}],"property-type":"constant"}},"paint_circle":{"circle-radius":{"type":"number","default":5,"minimum":0,"transition":true,"units":"pixels","expression":{"interpolated":true,"parameters":["zoom","feature","feature-state"]},"property-type":"data-driven"},"circle-color":{"type":"color","default":"#000000","transition":true,"expression":{"interpolated":true,"parameters":["zoom","feature","feature-state"]},"property-type":"data-driven"},"circle-blur":{"type":"number","default":0,"transition":true,"expression":{"interpolated":true,"parameters":["zoom","feature","feature-state"]},"property-type":"data-driven"},"circle-opacity":{"type":"number","default":1,"minimum":0,"maximum":1,"transition":true,"expression":{"interpolated":true,"parameters":["zoom","feature","feature-state"]},"property-type":"data-driven"},"circle-translate":{"type":"array","value":"number","length":2,"default":[0,0],"transition":true,"units":"pixels","expression":{"interpolated":true,"parameters":["zoom"]},"property-type":"data-constant"},"circle-translate-anchor":{"type":"enum","values":{"map":{},"viewport":{}},"default":"map","requires":["circle-translate"],"expression":{"interpolated":false,"parameters":["zoom"]},"property-type":"data-constant"},"circle-pitch-scale":{"type":"enum","values":{"map":{},"viewport":{}},"default":"map","expression":{"interpolated":false,"parameters":["zoom"]},"property-type":"data-constant"},"circle-pitch-alignment":{"type":"enum","values":{"map":{},"viewport":{}},"default":"viewport","expression":{"interpolated":false,"parameters":["zoom"]},"property-type":"data-constant"},"circle-stroke-width":{"type":"number","default":0,"minimum":0,"transition":true,"units":"pixels","expression":{"interpolated":true,"parameters":["zoom","feature","feature-state"]},"property-type":"data-driven"},"circle-stroke-color":{"type":"color","default":"#000000","transition":true,"expression":{"interpolated":true,"parameters":["zoom","feature","feature-state"]},"property-type":"data-driven"},"circle-stroke-opacity":{"type":"number","default":1,"minimum":0,"maximum":1,"transition":true,"expression":{"interpolated":true,"parameters":["zoom","feature","feature-state"]},"property-type":"data-driven"}},"paint_heatmap":{"heatmap-radius":{"type":"number","default":30,"minimum":1,"transition":true,"units":"pixels","expression":{"interpolated":true,"parameters":["zoom","feature","feature-state"]},"property-type":"data-driven"},"heatmap-weight":{"type":"number","default":1,"minimum":0,"transition":false,"expression":{"interpolated":true,"parameters":["zoom","feature","feature-state"]},"property-type":"data-driven"},"heatmap-intensity":{"type":"number","default":1,"minimum":0,"transition":true,"expression":{"interpolated":true,"parameters":["zoom"]},"property-type":"data-constant"},"heatmap-color":{"type":"color","default":["interpolate",["linear"],["heatmap-density"],0,"rgba(0, 0, 255, 0)",0.1,"royalblue",0.3,"cyan",0.5,"lime",0.7,"yellow",1,"red"],"transition":false,"expression":{"interpolated":true,"parameters":["heatmap-density"]},"property-type":"color-ramp"},"heatmap-opacity":{"type":"number","default":1,"minimum":0,"maximum":1,"transition":true,"expression":{"interpolated":true,"parameters":["zoom"]},"property-type":"data-constant"}},"paint_symbol":{"icon-opacity":{"type":"number","default":1,"minimum":0,"maximum":1,"transition":true,"requires":["icon-image"],"expression":{"interpolated":true,"parameters":["zoom","feature","feature-state"]},"property-type":"data-driven"},"icon-color":{"type":"color","default":"#000000","transition":true,"requires":["icon-image"],"expression":{"interpolated":true,"parameters":["zoom","feature","feature-state"]},"property-type":"data-driven"},"icon-halo-color":{"type":"color","default":"rgba(0, 0, 0, 0)","transition":true,"requires":["icon-image"],"expression":{"interpolated":true,"parameters":["zoom","feature","feature-state"]},"property-type":"data-driven"},"icon-halo-width":{"type":"number","default":0,"minimum":0,"transition":true,"units":"pixels","requires":["icon-image"],"expression":{"interpolated":true,"parameters":["zoom","feature","feature-state"]},"property-type":"data-driven"},"icon-halo-blur":{"type":"number","default":0,"minimum":0,"transition":true,"units":"pixels","requires":["icon-image"],"expression":{"interpolated":true,"parameters":["zoom","feature","feature-state"]},"property-type":"data-driven"},"icon-translate":{"type":"array","value":"number","length":2,"default":[0,0],"transition":true,"units":"pixels","requires":["icon-image"],"expression":{"interpolated":true,"parameters":["zoom"]},"property-type":"data-constant"},"icon-translate-anchor":{"type":"enum","values":{"map":{},"viewport":{}},"default":"map","requires":["icon-image","icon-translate"],"expression":{"interpolated":false,"parameters":["zoom"]},"property-type":"data-constant"},"text-opacity":{"type":"number","default":1,"minimum":0,"maximum":1,"transition":true,"requires":["text-field"],"expression":{"interpolated":true,"parameters":["zoom","feature","feature-state"]},"property-type":"data-driven"},"text-color":{"type":"color","default":"#000000","transition":true,"overridable":true,"requires":["text-field"],"expression":{"interpolated":true,"parameters":["zoom","feature","feature-state"]},"property-type":"data-driven"},"text-halo-color":{"type":"color","default":"rgba(0, 0, 0, 0)","transition":true,"requires":["text-field"],"expression":{"interpolated":true,"parameters":["zoom","feature","feature-state"]},"property-type":"data-driven"},"text-halo-width":{"type":"number","default":0,"minimum":0,"transition":true,"units":"pixels","requires":["text-field"],"expression":{"interpolated":true,"parameters":["zoom","feature","feature-state"]},"property-type":"data-driven"},"text-halo-blur":{"type":"number","default":0,"minimum":0,"transition":true,"units":"pixels","requires":["text-field"],"expression":{"interpolated":true,"parameters":["zoom","feature","feature-state"]},"property-type":"data-driven"},"text-translate":{"type":"array","value":"number","length":2,"default":[0,0],"transition":true,"units":"pixels","requires":["text-field"],"expression":{"interpolated":true,"parameters":["zoom"]},"property-type":"data-constant"},"text-translate-anchor":{"type":"enum","values":{"map":{},"viewport":{}},"default":"map","requires":["text-field","text-translate"],"expression":{"interpolated":false,"parameters":["zoom"]},"property-type":"data-constant"}},"paint_raster":{"raster-opacity":{"type":"number","default":1,"minimum":0,"maximum":1,"transition":true,"expression":{"interpolated":true,"parameters":["zoom"]},"property-type":"data-constant"},"raster-hue-rotate":{"type":"number","default":0,"period":360,"transition":true,"units":"degrees","expression":{"interpolated":true,"parameters":["zoom"]},"property-type":"data-constant"},"raster-brightness-min":{"type":"number","default":0,"minimum":0,"maximum":1,"transition":true,"expression":{"interpolated":true,"parameters":["zoom"]},"property-type":"data-constant"},"raster-brightness-max":{"type":"number","default":1,"minimum":0,"maximum":1,"transition":true,"expression":{"interpolated":true,"parameters":["zoom"]},"property-type":"data-constant"},"raster-saturation":{"type":"number","default":0,"minimum":-1,"maximum":1,"transition":true,"expression":{"interpolated":true,"parameters":["zoom"]},"property-type":"data-constant"},"raster-contrast":{"type":"number","default":0,"minimum":-1,"maximum":1,"transition":true,"expression":{"interpolated":true,"parameters":["zoom"]},"property-type":"data-constant"},"raster-resampling":{"type":"enum","values":{"linear":{},"nearest":{}},"default":"linear","expression":{"interpolated":false,"parameters":["zoom"]},"property-type":"data-constant"},"raster-fade-duration":{"type":"number","default":300,"minimum":0,"transition":false,"units":"milliseconds","expression":{"interpolated":true,"parameters":["zoom"]},"property-type":"data-constant"}},"paint_hillshade":{"hillshade-illumination-direction":{"type":"number","default":335,"minimum":0,"maximum":359,"transition":false,"expression":{"interpolated":true,"parameters":["zoom"]},"property-type":"data-constant"},"hillshade-illumination-anchor":{"type":"enum","values":{"map":{},"viewport":{}},"default":"viewport","expression":{"interpolated":false,"parameters":["zoom"]},"property-type":"data-constant"},"hillshade-exaggeration":{"type":"number","default":0.5,"minimum":0,"maximum":1,"transition":true,"expression":{"interpolated":true,"parameters":["zoom"]},"property-type":"data-constant"},"hillshade-shadow-color":{"type":"color","default":"#000000","transition":true,"expression":{"interpolated":true,"parameters":["zoom"]},"property-type":"data-constant"},"hillshade-highlight-color":{"type":"color","default":"#FFFFFF","transition":true,"expression":{"interpolated":true,"parameters":["zoom"]},"property-type":"data-constant"},"hillshade-accent-color":{"type":"color","default":"#000000","transition":true,"expression":{"interpolated":true,"parameters":["zoom"]},"property-type":"data-constant"}},"paint_background":{"background-color":{"type":"color","default":"#000000","transition":true,"requires":[{"!":"background-pattern"}],"expression":{"interpolated":true,"parameters":["zoom"]},"property-type":"data-constant"},"background-pattern":{"type":"resolvedImage","transition":false,"expression":{"interpolated":false,"parameters":["zoom"]},"property-type":"data-constant"},"background-opacity":{"type":"number","default":1,"minimum":0,"maximum":1,"transition":true,"expression":{"interpolated":true,"parameters":["zoom"]},"property-type":"data-constant"}},"paint_sky":{"sky-type":{"type":"enum","values":{"gradient":{},"atmosphere":{}},"default":"atmosphere","expression":{"interpolated":false,"parameters":["zoom"]},"property-type":"data-constant"},"sky-atmosphere-sun":{"type":"array","value":"number","length":2,"units":"degrees","minimum":[0,0],"maximum":[360,180],"transition":false,"requires":[{"sky-type":"atmosphere"}],"expression":{"interpolated":false,"parameters":["zoom"]},"property-type":"data-constant"},"sky-atmosphere-sun-intensity":{"type":"number","requires":[{"sky-type":"atmosphere"}],"default":10,"minimum":0,"maximum":100,"transition":false,"property-type":"data-constant"},"sky-gradient-center":{"type":"array","requires":[{"sky-type":"gradient"}],"value":"number","default":[0,0],"length":2,"units":"degrees","minimum":[0,0],"maximum":[360,180],"transition":false,"expression":{"interpolated":false,"parameters":["zoom"]},"property-type":"data-constant"},"sky-gradient-radius":{"type":"number","requires":[{"sky-type":"gradient"}],"default":90,"minimum":0,"maximum":180,"transition":false,"expression":{"interpolated":false,"parameters":["zoom"]},"property-type":"data-constant"},"sky-gradient":{"type":"color","default":["interpolate",["linear"],["sky-radial-progress"],0.8,"#87ceeb",1,"white"],"transition":false,"requires":[{"sky-type":"gradient"}],"expression":{"interpolated":true,"parameters":["sky-radial-progress"]},"property-type":"color-ramp"},"sky-atmosphere-halo-color":{"type":"color","default":"white","transition":false,"requires":[{"sky-type":"atmosphere"}],"property-type":"data-constant"},"sky-atmosphere-color":{"type":"color","default":"white","transition":false,"requires":[{"sky-type":"atmosphere"}],"property-type":"data-constant"},"sky-opacity":{"type":"number","default":1,"minimum":0,"maximum":1,"transition":true,"expression":{"interpolated":true,"parameters":["zoom"]},"property-type":"data-constant"}},"transition":{"duration":{"type":"number","default":300,"minimum":0,"units":"milliseconds"},"delay":{"type":"number","default":0,"minimum":0,"units":"milliseconds"}},"property-type":{"data-driven":{"type":"property-type"},"color-ramp":{"type":"property-type"},"data-constant":{"type":"property-type"},"constant":{"type":"property-type"}},"promoteId":{"*":{"type":"string"}}}');function ta(l,...o){for(const u of o)for(const d in u)l[d]=u[d];return l}function ci(l){return l instanceof Number||l instanceof String||l instanceof Boolean?l.valueOf():l}function mo(l){if(Array.isArray(l))return l.map(mo);if(l instanceof Object&&!(l instanceof Number||l instanceof String||l instanceof Boolean)){const o={};for(const u in l)o[u]=mo(l[u]);return o}return ci(l)}
113class kp extends Error{constructor(o,u){super(u),this.message=u,this.key=o}}var Ts=kp;class Gd{constructor(o,u=[]){this.parent=o,this.bindings={};for(const[d,p]of u)this.bindings[d]=p}concat(o){return new Gd(this,o)}get(o){if(this.bindings[o])return this.bindings[o];if(this.parent)return this.parent.get(o);throw new Error(`${o} not found in scope.`)}has(o){return!!this.bindings[o]||!!this.parent&&this.parent.has(o)}}var qd=Gd;const bl={kind:"null"},dn={kind:"number"},fr={kind:"string"},cr={kind:"boolean"},Aa={kind:"color"},os={kind:"object"},tr={kind:"value"},O={kind:"collator"},G={kind:"formatted"},he={kind:"resolvedImage"};function Re(l,o){return{kind:"array",itemType:l,N:o}}function Ve(l){if(l.kind==="array"){const o=Ve(l.itemType);return typeof l.N=="number"?`array<${o}, ${l.N}>`:l.itemType.kind==="value"?"array":`array<${o}>`}return l.kind}const Qe=[bl,dn,fr,cr,Aa,G,os,Re(tr),he];function it(l,o){if(o.kind==="error")return null;if(l.kind==="array"){if(o.kind==="array"&&(o.N===0&&o.itemType.kind==="value"||!it(l.itemType,o.itemType))&&(typeof l.N!="number"||l.N===o.N))return null}else{if(l.kind===o.kind)return null;if(l.kind==="value"){for(const u of Qe)if(!it(u,o))return null}}return`Expected ${Ve(l)} but found ${Ve(o)} instead.`}function Qt(l,o){return o.some(u=>u.kind===l.kind)}function on(l,o){return o.some(u=>u==="null"?l===null:u==="array"?Array.isArray(l):u==="object"?l&&!Array.isArray(l)&&typeof l=="object":u===typeof l)}var _n,bn={transparent:[0,0,0,0],aliceblue:[240,248,255,1],antiquewhite:[250,235,215,1],aqua:[0,255,255,1],aquamarine:[127,255,212,1],azure:[240,255,255,1],beige:[245,245,220,1],bisque:[255,228,196,1],black:[0,0,0,1],blanchedalmond:[255,235,205,1],blue:[0,0,255,1],blueviolet:[138,43,226,1],brown:[165,42,42,1],burlywood:[222,184,135,1],cadetblue:[95,158,160,1],chartreuse:[127,255,0,1],chocolate:[210,105,30,1],coral:[255,127,80,1],cornflowerblue:[100,149,237,1],cornsilk:[255,248,220,1],crimson:[220,20,60,1],cyan:[0,255,255,1],darkblue:[0,0,139,1],darkcyan:[0,139,139,1],darkgoldenrod:[184,134,11,1],darkgray:[169,169,169,1],darkgreen:[0,100,0,1],darkgrey:[169,169,169,1],darkkhaki:[189,183,107,1],darkmagenta:[139,0,139,1],darkolivegreen:[85,107,47,1],darkorange:[255,140,0,1],darkorchid:[153,50,204,1],darkred:[139,0,0,1],darksalmon:[233,150,122,1],darkseagreen:[143,188,143,1],darkslateblue:[72,61,139,1],darkslategray:[47,79,79,1],darkslategrey:[47,79,79,1],darkturquoise:[0,206,209,1],darkviolet:[148,0,211,1],deeppink:[255,20,147,1],deepskyblue:[0,191,255,1],dimgray:[105,105,105,1],dimgrey:[105,105,105,1],dodgerblue:[30,144,255,1],firebrick:[178,34,34,1],floralwhite:[255,250,240,1],forestgreen:[34,139,34,1],fuchsia:[255,0,255,1],gainsboro:[220,220,220,1],ghostwhite:[248,248,255,1],gold:[255,215,0,1],goldenrod:[218,165,32,1],gray:[128,128,128,1],green:[0,128,0,1],greenyellow:[173,255,47,1],grey:[128,128,128,1],honeydew:[240,255,240,1],hotpink:[255,105,180,1],indianred:[205,92,92,1],indigo:[75,0,130,1],ivory:[255,255,240,1],khaki:[240,230,140,1],lavender:[230,230,250,1],lavenderblush:[255,240,245,1],lawngreen:[124,252,0,1],lemonchiffon:[255,250,205,1],lightblue:[173,216,230,1],lightcoral:[240,128,128,1],lightcyan:[224,255,255,1],lightgoldenrodyellow:[250,250,210,1],lightgray:[211,211,211,1],lightgreen:[144,238,144,1],lightgrey:[211,211,211,1],lightpink:[255,182,193,1],lightsalmon:[255,160,122,1],lightseagreen:[32,178,170,1],lightskyblue:[135,206,250,1],lightslategray:[119,136,153,1],lightslategrey:[119,136,153,1],lightsteelblue:[176,196,222,1],lightyellow:[255,255,224,1],lime:[0,255,0,1],limegreen:[50,205,50,1],linen:[250,240,230,1],magenta:[255,0,255,1],maroon:[128,0,0,1],mediumaquamarine:[102,205,170,1],mediumblue:[0,0,205,1],mediumorchid:[186,85,211,1],mediumpurple:[147,112,219,1],mediumseagreen:[60,179,113,1],mediumslateblue:[123,104,238,1],mediumspringgreen:[0,250,154,1],mediumturquoise:[72,209,204,1],mediumvioletred:[199,21,133,1],midnightblue:[25,25,112,1],mintcream:[245,255,250,1],mistyrose:[255,228,225,1],moccasin:[255,228,181,1],navajowhite:[255,222,173,1],navy:[0,0,128,1],oldlace:[253,245,230,1],olive:[128,128,0,1],olivedrab:[107,142,35,1],orange:[255,165,0,1],orangered:[255,69,0,1],orchid:[218,112,214,1],palegoldenrod:[238,232,170,1],palegreen:[152,251,152,1],paleturquoise:[175,238,238,1],palevioletred:[219,112,147,1],papayawhip:[255,239,213,1],peachpuff:[255,218,185,1],peru:[205,133,63,1],pink:[255,192,203,1],plum:[221,160,221,1],powderblue:[176,224,230,1],purple:[128,0,128,1],rebeccapurple:[102,51,153,1],red:[255,0,0,1],rosybrown:[188,143,143,1],royalblue:[65,105,225,1],saddlebrown:[139,69,19,1],salmon:[250,128,114,1],sandybrown:[244,164,96,1],seagreen:[46,139,87,1],seashell:[255,245,238,1],sienna:[160,82,45,1],silver:[192,192,192,1],skyblue:[135,206,235,1],slateblue:[106,90,205,1],slategray:[112,128,144,1],slategrey:[112,128,144,1],snow:[255,250,250,1],springgreen:[0,255,127,1],steelblue:[70,130,180,1],tan:[210,180,140,1],teal:[0,128,128,1],thistle:[216,191,216,1],tomato:[255,99,71,1],turquoise:[64,224,208,1],violet:[238,130,238,1],wheat:[245,222,179,1],white:[255,255,255,1],whitesmoke:[245,245,245,1],yellow:[255,255,0,1],yellowgreen:[154,205,50,1]};function cn(l){return(l=Math.round(l))<0?0:l>255?255:l}function qn(l){return cn(l[l.length-1]==="%"?parseFloat(l)/100*255:parseInt(l))}function vi(l){return(o=l[l.length-1]==="%"?parseFloat(l)/100:parseFloat(l))<0?0:o>1?1:o;var o}function Zn(l,o,u){return u<0?u+=1:u>1&&(u-=1),6*u<1?l+(o-l)*u*6:2*u<1?o:3*u<2?l+(o-l)*(2/3-u)*6:l}try{_n={}.parseCSSColor=function(l){var o,u=l.replace(/ /g,"").toLowerCase();if(u in bn)return bn[u].slice();if(u[0]==="#")return u.length===4?(o=parseInt(u.substr(1),16))>=0&&o<=4095?[(3840&o)>>4|(3840&o)>>8,240&o|(240&o)>>4,15&o|(15&o)<<4,1]:null:u.length===7&&(o=parseInt(u.substr(1),16))>=0&&o<=16777215?[(16711680&o)>>16,(65280&o)>>8,255&o,1]:null;var d=u.indexOf("("),p=u.indexOf(")");if(d!==-1&&p+1===u.length){var _=u.substr(0,d),b=u.substr(d+1,p-(d+1)).split(","),E=1;switch(_){case"rgba":if(b.length!==4)return null;E=vi(b.pop());case"rgb":return b.length!==3?null:[qn(b[0]),qn(b[1]),qn(b[2]),E];case"hsla":if(b.length!==4)return null;E=vi(b.pop());case"hsl":if(b.length!==3)return null;var k=(parseFloat(b[0])%360+360)%360/360,M=vi(b[1]),F=vi(b[2]),$=F<=.5?F*(M+1):F+M-F*M,V=2*F-$;return[cn(255*Zn(V,$,k+1/3)),cn(255*Zn(V,$,k)),cn(255*Zn(V,$,k-1/3)),E];default:return null}}return null}}catch{}class Pr{constructor(o,u,d,p=1){this.r=o,this.g=u,this.b=d,this.a=p}static parse(o){if(!o)return;if(o instanceof Pr)return o;if(typeof o!="string")return;const u=_n(o);return u?new Pr(u[0]/255*u[3],u[1]/255*u[3],u[2]/255*u[3],u[3]):void 0}toString(){const[o,u,d,p]=this.toArray();return`rgba(${Math.round(o)},${Math.round(u)},${Math.round(d)},${p})`}toArray(){const{r:o,g:u,b:d,a:p}=this;return p===0?[0,0,0,0]:[255*o/p,255*u/p,255*d/p,p]}toArray01(){const{r:o,g:u,b:d,a:p}=this;return p===0?[0,0,0,0]:[o/p,u/p,d/p,p]}toArray01PremultipliedAlpha(){const{r:o,g:u,b:d,a:p}=this;return[o,u,d,p]}}Pr.black=new Pr(0,0,0,1),Pr.white=new Pr(1,1,1,1),Pr.transparent=new Pr(0,0,0,0),Pr.red=new Pr(1,0,0,1),Pr.blue=new Pr(0,0,1,1);var Rt=Pr;class An{constructor(o,u,d){this.sensitivity=o?u?"variant":"case":u?"accent":"base",this.locale=d,this.collator=new Intl.Collator(this.locale?this.locale:[],{sensitivity:this.sensitivity,usage:"search"})}compare(o,u){return this.collator.compare(o,u)}resolvedLocale(){return new Intl.Collator(this.locale?this.locale:[]).resolvedOptions().locale}}class Fr{constructor(o,u,d,p,_){this.text=o.normalize?o.normalize():o,this.image=u,this.scale=d,this.fontStack=p,this.textColor=_}}class Br{constructor(o){this.sections=o}static fromString(o){return new Br([new Fr(o,null,null,null,null)])}isEmpty(){return this.sections.length===0||!this.sections.some(o=>o.text.length!==0||o.image&&o.image.name.length!==0)}static factory(o){return o instanceof Br?o:Br.fromString(o)}toString(){return this.sections.length===0?"":this.sections.map(o=>o.text).join("")}serialize(){const o=["format"];for(const u of this.sections){if(u.image){o.push(["image",u.image.name]);continue}o.push(u.text);const d={};
113u.fontStack&&(d["text-font"]=["literal",u.fontStack.split(",")]),u.scale&&(d["font-scale"]=u.scale),u.textColor&&(d["text-color"]=["rgba"].concat(u.textColor.toArray())),o.push(d)}return o}}class zr{constructor(o){this.name=o.name,this.available=o.available}toString(){return this.name}static fromString(o){return o?new zr({name:o,available:!1}):null}serialize(){return["image",this.name]}}function dh(l,o,u,d){return typeof l=="number"&&l>=0&&l<=255&&typeof o=="number"&&o>=0&&o<=255&&typeof u=="number"&&u>=0&&u<=255?d===void 0||typeof d=="number"&&d>=0&&d<=1?null:`Invalid rgba value [${[l,o,u,d].join(", ")}]: 'a' must be between 0 and 1.`:`Invalid rgba value [${(typeof d=="number"?[l,o,u,d]:[l,o,u]).join(", ")}]: 'r', 'g', and 'b' must be between 0 and 255.`}function xu(l){if(l===null||typeof l=="string"||typeof l=="boolean"||typeof l=="number"||l instanceof Rt||l instanceof An||l instanceof Br||l instanceof zr)return!0;if(Array.isArray(l)){for(const o of l)if(!xu(o))return!1;return!0}if(typeof l=="object"){for(const o in l)if(!xu(l[o]))return!1;return!0}return!1}function Kn(l){if(l===null)return bl;if(typeof l=="string")return fr;if(typeof l=="boolean")return cr;if(typeof l=="number")return dn;if(l instanceof Rt)return Aa;if(l instanceof An)return O;if(l instanceof Br)return G;if(l instanceof zr)return he;if(Array.isArray(l)){const o=l.length;let u;for(const d of l){const p=Kn(d);if(u){if(u===p)continue;u=tr;break}u=p}return Re(u||tr,o)}return os}function Rc(l){const o=typeof l;return l===null?"":o==="string"||o==="number"||o==="boolean"?String(l):l instanceof Rt||l instanceof Br||l instanceof zr?l.toString():JSON.stringify(l)}class Wd{constructor(o,u){this.type=o,this.value=u}static parse(o,u){if(o.length!==2)return u.error(`'literal' expression requires exactly one argument, but found ${o.length-1} instead.`);if(!xu(o[1]))return u.error("invalid value");const d=o[1];let p=Kn(d);const _=u.expectedType;return p.kind!=="array"||p.N!==0||!_||_.kind!=="array"||typeof _.N=="number"&&_.N!==0||(p=_),new Wd(p,d)}evaluate(){return this.value}eachChild(){}outputDefined(){return!0}serialize(){return this.type.kind==="array"||this.type.kind==="object"?["literal",this.value]:this.value instanceof Rt?["rgba"].concat(this.value.toArray()):this.value instanceof Br?this.value.serialize():this.value}}var na=Wd,Mo=class{constructor(l){this.name="ExpressionEvaluationError",this.message=l}toJSON(){return this.message}};const fh={string:fr,number:dn,boolean:cr,object:os};class ph{constructor(o,u){this.type=o,this.args=u}static parse(o,u){if(o.length<2)return u.error("Expected at least one argument.");let d,p=1;const _=o[0];if(_==="array"){let E,k;if(o.length>2){const M=o[1];if(typeof M!="string"||!(M in fh)||M==="object")return u.error('The item type argument of "array" must be one of string, number, boolean',1);E=fh[M],p++}else E=tr;if(o.length>3){if(o[2]!==null&&(typeof o[2]!="number"||o[2]<0||o[2]!==Math.floor(o[2])))return u.error('The length argument to "array" must be a positive integer literal',2);k=o[2],p++}d=Re(E,k)}else d=fh[_];const b=[];for(;p<o.length;p++){const E=u.parse(o[p],p,tr);if(!E)return null;b.push(E)}return new ph(d,b)}evaluate(o){for(let u=0;u<this.args.length;u++){const d=this.args[u].evaluate(o);if(!it(this.type,Kn(d)))return d;if(u===this.args.length-1)throw new Mo(`Expected value to be of type ${Ve(this.type)}, but found ${Ve(Kn(d))} instead.`)}return null}eachChild(o){this.args.forEach(o)}outputDefined(){return this.args.every(o=>o.outputDefined())}serialize(){const o=this.type,u=[o.kind];if(o.kind==="array"){const d=o.itemType;if(d.kind==="string"||d.kind==="number"||d.kind==="boolean"){u.push(d.kind);const p=o.N;(typeof p=="number"||this.args.length>1)&&u.push(p)}}return u.concat(this.args.map(d=>d.serialize()))}}var as=ph;class Ws{constructor(o){this.type=G,this.sections=o}static parse(o,u){if(o.length<2)return u.error("Expected at least one argument.");const d=o[1];if(!Array.isArray(d)&&typeof d=="object")return u.error("First argument must be an image or text section.");const p=[];let _=!1;for(let b=1;b<=o.length-1;++b){const E=o[b];if(_&&typeof E=="object"&&!Array.isArray(E)){_=!1;let k=null;if(E["font-scale"]&&(k=u.parse(E["font-scale"],1,dn),!k))return null;let M=null;if(E["text-font"]&&(M=u.parse(E["text-font"],1,Re(fr)),!M))return null;let F=null;if(E["text-color"]&&(F=u.parse(E["text-color"],1,Aa),!F))return null;const $=p[p.length-1];$.scale=k,$.font=M,$.textColor=F}
113else{const k=u.parse(o[b],1,tr);if(!k)return null;const M=k.type.kind;if(M!=="string"&&M!=="value"&&M!=="null"&&M!=="resolvedImage")return u.error("Formatted text type must be 'string', 'value', 'image' or 'null'.");_=!0,p.push({content:k,scale:null,font:null,textColor:null})}}return new Ws(p)}evaluate(o){return new Br(this.sections.map(u=>{const d=u.content.evaluate(o);return Kn(d)===he?new Fr("",d,null,null,null):new Fr(Rc(d),null,u.scale?u.scale.evaluate(o):null,u.font?u.font.evaluate(o).join(","):null,u.textColor?u.textColor.evaluate(o):null)}))}eachChild(o){for(const u of this.sections)o(u.content),u.scale&&o(u.scale),u.font&&o(u.font),u.textColor&&o(u.textColor)}outputDefined(){return!1}serialize(){const o=["format"];for(const u of this.sections){o.push(u.content.serialize());const d={};u.scale&&(d["font-scale"]=u.scale.serialize()),u.font&&(d["text-font"]=u.font.serialize()),u.textColor&&(d["text-color"]=u.textColor.serialize()),o.push(d)}return o}}class wu{constructor(o){this.type=he,this.input=o}static parse(o,u){if(o.length!==2)return u.error("Expected two arguments.");const d=u.parse(o[1],1,fr);return d?new wu(d):u.error("No image name provided.")}evaluate(o){const u=this.input.evaluate(o),d=zr.fromString(u);return d&&o.availableImages&&(d.available=o.availableImages.indexOf(u)>-1),d}eachChild(o){o(this.input)}outputDefined(){return!1}serialize(){return["image",this.input.serialize()]}}const Og={"to-boolean":cr,"to-color":Aa,"to-number":dn,"to-string":fr};class Hd{constructor(o,u){this.type=o,this.args=u}static parse(o,u){if(o.length<2)return u.error("Expected at least one argument.");const d=o[0];if((d==="to-boolean"||d==="to-string")&&o.length!==2)return u.error("Expected one argument.");const p=Og[d],_=[];for(let b=1;b<o.length;b++){const E=u.parse(o[b],b,tr);if(!E)return null;_.push(E)}return new Hd(p,_)}evaluate(o){if(this.type.kind==="boolean")return!!this.args[0].evaluate(o);if(this.type.kind==="color"){let u,d;for(const p of this.args){if(u=p.evaluate(o),d=null,u instanceof Rt)return u;if(typeof u=="string"){const _=o.parseColor(u);if(_)return _}else if(Array.isArray(u)&&(d=u.length<3||u.length>4?`Invalid rbga value ${JSON.stringify(u)}: expected an array containing either three or four numeric values.`:dh(u[0],u[1],u[2],u[3]),!d))return new Rt(u[0]/255,u[1]/255,u[2]/255,u[3])}throw new Mo(d||`Could not parse color from value '${typeof u=="string"?u:String(JSON.stringify(u))}'`)}if(this.type.kind==="number"){let u=null;for(const d of this.args){if(u=d.evaluate(o),u===null)return 0;const p=Number(u);if(!isNaN(p))return p}throw new Mo(`Could not convert ${JSON.stringify(u)} to number.`)}return this.type.kind==="formatted"?Br.fromString(Rc(this.args[0].evaluate(o))):this.type.kind==="resolvedImage"?zr.fromString(Rc(this.args[0].evaluate(o))):Rc(this.args[0].evaluate(o))}eachChild(o){this.args.forEach(o)}outputDefined(){return this.args.every(o=>o.outputDefined())}serialize(){if(this.type.kind==="formatted")return new Ws([{content:this.args[0],scale:null,font:null,textColor:null}]).serialize();if(this.type.kind==="resolvedImage")return new wu(this.args[0]).serialize();const o=[`to-${this.type.kind}`];return this.eachChild(u=>{o.push(u.serialize())}),o}}var Fc=Hd;const ss=["Unknown","Point","LineString","Polygon"];var mh=class{constructor(){this.globals=null,this.feature=null,this.featureState=null,this.formattedSection=null,this._parseColorCache={},this.availableImages=null,this.canonical=null,this.featureTileCoord=null,this.featureDistanceData=null}id(){return this.feature&&this.feature.id!==void 0?this.feature.id:null}geometryType(){return this.feature?typeof this.feature.type=="number"?ss[this.feature.type]:this.feature.type:null}geometry(){return this.feature&&"geometry"in this.feature?this.feature.geometry:null}canonicalID(){return this.canonical}properties(){return this.feature&&this.feature.properties||{}}distanceFromCenter(){if(this.featureTileCoord&&this.featureDistanceData){const l=this.featureDistanceData.center,o=this.featureDistanceData.scale,{x:u,y:d}=this.featureTileCoord;return this.featureDistanceData.bearing[0]*(u*o-l[0])+this.featureDistanceData.bearing[1]*(d*o-l[1])}return 0}parseColor(l){let o=this._parseColorCache[l];return o||(o=this._parseColorCache[l]=Rt.parse(l)),o}};class xl{constructor(o,u,d,p){this.name=o,this.type=u,this._evaluate=d,this.args=p}evaluate(o){return this._evaluate(o,this.args)}
113eachChild(o){this.args.forEach(o)}outputDefined(){return!1}serialize(){return[this.name].concat(this.args.map(o=>o.serialize()))}static parse(o,u){const d=o[0],p=xl.definitions[d];if(!p)return u.error(`Unknown expression "${d}". If you wanted a literal array, use ["literal", [...]].`,0);const _=Array.isArray(p)?p[0]:p.type,b=Array.isArray(p)?[[p[1],p[2]]]:p.overloads,E=b.filter(([M])=>!Array.isArray(M)||M.length===o.length-1);let k=null;for(const[M,F]of E){k=new Qd(u.registry,u.path,null,u.scope);const $=[];let V=!1;for(let X=1;X<o.length;X++){const J=o[X],re=Array.isArray(M)?M[X-1]:M.type,pe=k.parse(J,1+$.length,re);if(!pe){V=!0;break}$.push(pe)}if(!V)if(Array.isArray(M)&&M.length!==$.length)k.error(`Expected ${M.length} arguments, but found ${$.length} instead.`);else{for(let X=0;X<$.length;X++){const J=Array.isArray(M)?M[X]:M.type,re=$[X];k.concat(X+1).checkSubtype(J,re.type)}if(k.errors.length===0)return new xl(d,_,F,$)}}if(E.length===1)u.errors.push(...k.errors);else{const M=(E.length?E:b).map(([$])=>{return V=$,Array.isArray(V)?`(${V.map(Ve).join(", ")})`:`(${Ve(V.type)}...)`;var V}).join(" | "),F=[];for(let $=1;$<o.length;$++){const V=u.parse(o[$],1+F.length);if(!V)return null;F.push(Ve(V.type))}u.error(`Expected arguments of type ${M}, but found (${F.join(", ")}) instead.`)}return null}static register(o,u){xl.definitions=u;for(const d in u)o[d]=xl}}var Hs=xl;class Tu{constructor(o,u,d){this.type=O,this.locale=d,this.caseSensitive=o,this.diacriticSensitive=u}static parse(o,u){if(o.length!==2)return u.error("Expected one argument.");const d=o[1];if(typeof d!="object"||Array.isArray(d))return u.error("Collator options argument must be an object.");const p=u.parse(d["case-sensitive"]!==void 0&&d["case-sensitive"],1,cr);if(!p)return null;const _=u.parse(d["diacritic-sensitive"]!==void 0&&d["diacritic-sensitive"],1,cr);if(!_)return null;let b=null;return d.locale&&(b=u.parse(d.locale,1,fr),!b)?null:new Tu(p,_,b)}evaluate(o){return new An(this.caseSensitive.evaluate(o),this.diacriticSensitive.evaluate(o),this.locale?this.locale.evaluate(o):null)}eachChild(o){o(this.caseSensitive),o(this.diacriticSensitive),this.locale&&o(this.locale)}outputDefined(){return!1}serialize(){const o={};return o["case-sensitive"]=this.caseSensitive.serialize(),o["diacritic-sensitive"]=this.diacriticSensitive.serialize(),this.locale&&(o.locale=this.locale.serialize()),["collator",o]}}const ja=8192;function Bc(l,o){l[0]=Math.min(l[0],o[0]),l[1]=Math.min(l[1],o[1]),l[2]=Math.max(l[2],o[0]),l[3]=Math.max(l[3],o[1])}function tc(l,o){return!(l[0]<=o[0]||l[2]>=o[2]||l[1]<=o[1]||l[3]>=o[3])}function pa(l,o){const u=(180+l[0])/360,d=(180-180/Math.PI*Math.log(Math.tan(Math.PI/4+l[1]*Math.PI/360)))/360,p=Math.pow(2,o.z);return[Math.round(u*p*ja),Math.round(d*p*ja)]}function Yd(l,o,u){const d=l[0]-o[0],p=l[1]-o[1],_=l[0]-u[0],b=l[1]-u[1];return d*b-_*p==0&&d*_<=0&&p*b<=0}function Eu(l,o){let u=!1;for(let b=0,E=o.length;b<E;b++){const k=o[b];for(let M=0,F=k.length;M<F-1;M++){if(Yd(l,k[M],k[M+1]))return!1;(p=k[M])[1]>(d=l)[1]!=(_=k[M+1])[1]>d[1]&&d[0]<(_[0]-p[0])*(d[1]-p[1])/(_[1]-p[1])+p[0]&&(u=!u)}}var d,p,_;return u}function Zd(l,o){for(let u=0;u<o.length;u++)if(Eu(l,o[u]))return!0;return!1}function gh(l,o,u,d){const p=d[0]-u[0],_=d[1]-u[1],b=(l[0]-u[0])*_-p*(l[1]-u[1]),E=(o[0]-u[0])*_-p*(o[1]-u[1]);return b>0&&E<0||b<0&&E>0}function Ys(l,o,u){for(const M of u)for(let F=0;F<M.length-1;++F)if((E=[(b=M[F+1])[0]-(_=M[F])[0],b[1]-_[1]])[0]*(k=[(p=o)[0]-(d=l)[0],p[1]-d[1]])[1]-E[1]*k[0]!=0&&gh(d,p,_,b)&&gh(_,b,d,p))return!0;var d,p,_,b,E,k;return!1}function Sr(l,o){for(let u=0;u<l.length;++u)if(!Eu(l[u],o))return!1;for(let u=0;u<l.length-1;++u)if(Ys(l[u],l[u+1],o))return!1;return!0}function Ap(l,o){for(let u=0;u<o.length;u++)if(Sr(l,o[u]))return!0;return!1}function Xd(l,o,u){const d=[];for(let p=0;p<l.length;p++){const _=[];for(let b=0;b<l[p].length;b++){const E=pa(l[p][b],u);Bc(o,E),_.push(E)}d.push(_)}return d}function wl(l,o,u){const d=[];for(let p=0;p<l.length;p++){const _=Xd(l[p],o,u);d.push(_)}return d}function yh(l,o,u,d){if(l[0]<u[0]||l[0]>u[2]){const p=.5*d;let _=l[0]-u[0]>p?-d:u[0]-l[0]>p?d:0;_===0&&(_=l[0]-u[2]>p?-d:u[2]-l[0]>p?d:0),l[0]+=_}Bc(o,l)}function Pp(l,o,u,d){const p=Math.pow(2,d.z)*ja,_=[d.x*ja,d.y*ja],b=[];if(!l)return b;for(const E of l)for(const k of E){const M=[k.x+_[0],k.y+_[1]];yh(M,o,u,p),b.push(M)}return b}function Kd(l,o,u,d){const p=Math.pow(2,d.z)*ja,_=[d.x*ja,d.y*ja],b=[];if(!l)return b;for(const k of l){const M=[];for(const F of k){const $=[F.x+_[0],F.y+_[1]];Bc(o,$),M.push($)}b.push(M)}if(o[2]-o[0]<=p/2){(E=o)[0]=E[1]=1/0,E[2]=E[3]=-1/0;for(const k of b)for(const M of k)yh(M,o,u,p)}var E;return b}class Tl{constructor(o,u){this.type=cr,this.geojson=o,this.geometries=u}static parse(o,u){if(o.length!==2)return u.error(`'within' expression requires exactly one argument, but found ${o.length-1} instead.`);if(xu(o[1])){const d=o[1];if(d.type==="FeatureCollection")for(let p=0;p<d.features.length;++p){const _=d.features[p].geometry.type;if(_==="Polygon"||_==="MultiPolygon")return new Tl(d,d.features[p].geometry)}else if(d.type==="Feature"){const p=d.geometry.type;if(p==="Polygon"||p==="MultiPolygon")return new Tl(d,d.geometry)}else if(d.type==="Polygon"||d.type==="MultiPolygon")return new Tl(d,d)}return u.error("'within' expression requires valid geojson object that contains polygon geometry type.")}evaluate(o){if(o.geometry()!=null&&o.canonicalID()!=null){if(o.geometryType()==="Point")return function(u,d){const p=[1/0,1/0,-1/0,-1/0],_=[1/0,1/0,-1/0,-1/0],b=u.canonicalID();if(!b)return!1;if(d.type==="Polygon"){const E=Xd(d.coordinates,_,b),k=Pp(u.geometry(),p,_,b);if(!tc(p,_))return!1;
113for(const M of k)if(!Eu(M,E))return!1}if(d.type==="MultiPolygon"){const E=wl(d.coordinates,_,b),k=Pp(u.geometry(),p,_,b);if(!tc(p,_))return!1;for(const M of k)if(!Zd(M,E))return!1}return!0}(o,this.geometries);if(o.geometryType()==="LineString")return function(u,d){const p=[1/0,1/0,-1/0,-1/0],_=[1/0,1/0,-1/0,-1/0],b=u.canonicalID();if(!b)return!1;if(d.type==="Polygon"){const E=Xd(d.coordinates,_,b),k=Kd(u.geometry(),p,_,b);if(!tc(p,_))return!1;for(const M of k)if(!Sr(M,E))return!1}if(d.type==="MultiPolygon"){const E=wl(d.coordinates,_,b),k=Kd(u.geometry(),p,_,b);if(!tc(p,_))return!1;for(const M of k)if(!Ap(M,E))return!1}return!0}(o,this.geometries)}return!1}eachChild(){}outputDefined(){return!0}serialize(){return["within",this.geojson]}}var El=Tl;function Sl(l){if(l instanceof Hs&&(l.name==="get"&&l.args.length===1||l.name==="feature-state"||l.name==="has"&&l.args.length===1||l.name==="properties"||l.name==="geometry-type"||l.name==="id"||/^filter-/.test(l.name))||l instanceof El)return!1;let o=!0;return l.eachChild(u=>{o&&!Sl(u)&&(o=!1)}),o}function ls(l){if(l instanceof Hs&&l.name==="feature-state")return!1;let o=!0;return l.eachChild(u=>{o&&!ls(u)&&(o=!1)}),o}function Zs(l,o){if(l instanceof Hs&&o.indexOf(l.name)>=0)return!1;let u=!0;return l.eachChild(d=>{u&&!Zs(d,o)&&(u=!1)}),u}class Cl{constructor(o,u){this.type=u.type,this.name=o,this.boundExpression=u}
113static parse(o,u){if(o.length!==2||typeof o[1]!="string")return u.error("'var' expression requires exactly one string literal argument.");const d=o[1];return u.scope.has(d)?new Cl(d,u.scope.get(d)):u.error(`Unknown variable "${d}". Make sure "${d}" has been bound in an enclosing "let" expression before using it.`,1)}evaluate(o){return this.boundExpression.evaluate(o)}eachChild(){}outputDefined(){return!1}serialize(){return["var",this.name]}}var Mp=Cl;class Su{constructor(o,u=[],d,p=new qd,_=[]){this.registry=o,this.path=u,this.key=u.map(b=>`[${b}]`).join(""),this.scope=p,this.errors=_,this.expectedType=d}parse(o,u,d,p,_={}){return u?this.concat(u,d,p)._parse(o,_):this._parse(o,_)}_parse(o,u){function d(p,_,b){return b==="assert"?new as(_,[p]):b==="coerce"?new Fc(_,[p]):p}if(o!==null&&typeof o!="string"&&typeof o!="boolean"&&typeof o!="number"||(o=["literal",o]),Array.isArray(o)){if(o.length===0)return this.error('Expected an array with at least one element. If you wanted a literal array, use ["literal", []].');const p=o[0];if(typeof p!="string")return this.error(`Expression name must be a string, but found ${typeof p} instead. If you wanted a literal array, use ["literal", [...]].`,0),null;const _=this.registry[p];if(_){let b=_.parse(o,this);if(!b)return null;if(this.expectedType){const E=this.expectedType,k=b.type;if(E.kind!=="string"&&E.kind!=="number"&&E.kind!=="boolean"&&E.kind!=="object"&&E.kind!=="array"||k.kind!=="value")if(E.kind!=="color"&&E.kind!=="formatted"&&E.kind!=="resolvedImage"||k.kind!=="value"&&k.kind!=="string"){if(this.checkSubtype(E,k))return null}else b=d(b,E,u.typeAnnotation||"coerce");else b=d(b,E,u.typeAnnotation||"assert")}if(!(b instanceof na)&&b.type.kind!=="resolvedImage"&&Jd(b)){const E=new mh;try{b=new na(b.type,b.evaluate(E))}catch(k){return this.error(k.message),null}}return b}return this.error(`Unknown expression "${p}". If you wanted a literal array, use ["literal", [...]].`,0)}return this.error(o===void 0?"'undefined' value invalid. Use null instead.":typeof o=="object"?'Bare objects invalid. Use ["literal", {...}] instead.':`Expected an array, but found ${typeof o} instead.`)}concat(o,u,d){const p=typeof o=="number"?this.path.concat(o):this.path,_=d?this.scope.concat(d):this.scope;return new Su(this.registry,p,u||null,_,this.errors)}error(o,...u){const d=`${this.key}${u.map(p=>`[${p}]`).join("")}`;this.errors.push(new Ts(d,o))}checkSubtype(o,u){const d=it(o,u);return d&&this.error(d),d}}var Qd=Su;function Jd(l){if(l instanceof Mp)return Jd(l.boundExpression);if(l instanceof Hs&&l.name==="error"||l instanceof Tu||l instanceof El)return!1;const o=l instanceof Fc||l instanceof as;let u=!0;return l.eachChild(d=>{u=o?u&&Jd(d):u&&d instanceof na}),!!u&&Sl(l)&&Zs(l,["zoom","heatmap-density","line-progress","sky-radial-progress","accumulated","is-supported-script","pitch","distance-from-center"])}function _h(l,o){const u=l.length-1;let d,p,_=0,b=u,E=0;for(;_<=b;)if(E=Math.floor((_+b)/2),d=l[E],p=l[E+1],d<=o){if(E===u||o<p)return E;_=E+1}else{if(!(d>o))throw new Mo("Input is not a number.");b=E-1}return 0}class Cu{constructor(o,u,d){this.type=o,this.input=u,this.labels=[],this.outputs=[];for(const[p,_]of d)this.labels.push(p),this.outputs.push(_)}static parse(o,u){if(o.length-1<4)return u.error(`Expected at least 4 arguments, but found only ${o.length-1}.`);if((o.length-1)%2!=0)return u.error("Expected an even number of arguments.");const d=u.parse(o[1],1,dn);if(!d)return null;const p=[];let _=null;u.expectedType&&u.expectedType.kind!=="value"&&(_=u.expectedType);for(let b=1;b<o.length;b+=2){const E=b===1?-1/0:o[b],k=o[b+1],M=b,F=b+1;if(typeof E!="number")return u.error('Input/output pairs for "step" expressions must be defined using literal numeric values (not computed expressions) for the input values.',M);if(p.length&&p[p.length-1][0]>=E)return u.error('Input/output pairs for "step" expressions must be arranged with input values in strictly ascending order.',M);const $=u.parse(k,F,_);if(!$)return null;_=_||$.type,p.push([E,$])}return new Cu(_,d,p)}evaluate(o){const u=this.labels,d=this.outputs;if(u.length===1)return d[0].evaluate(o);const p=this.input.evaluate(o);if(p<=u[0])return d[0].evaluate(o);const _=u.length;return p>=u[_-1]?d[_-1].evaluate(o):d[_h(u,p)].evaluate(o)}eachChild(o){o(this.input);for(const u of this.outputs)o(u)}outputDefined(){return this.outputs.every(o=>o.outputDefined())}serialize(){const o=["step",this.input.serialize()];for(let u=0;u<this.labels.length;u++)u>0&&o.push(this.labels[u]),o.push(this.outputs[u].serialize());return o}}var ku=Cu;function ur(l,o,u){return l*(1-u)+o*u}var Pa=Object.freeze({__proto__:null,array:function(l,o,u){return l.map((d,p)=>ur(d,o[p],u))},color:function(l,o,u){return new Rt(ur(l.r,o.r,u),ur(l.g,o.g,u),ur(l.b,o.b,u),ur(l.a,o.a,u))},number:ur});const kl=.95047,zc=1.08883,Xs=4/29,nc=6/29,Nc=3*nc*nc,Au=nc*nc*nc,Ip=Math.PI/180,Op=180/Math.PI;function ef(l){return l>Au?Math.pow(l,1/3):l/Nc+Xs}function tf(l){return l>nc?l*l*l:Nc*(l-Xs)}
vendor: 5,116 bytes, line 113
113function vh(l){return 255*(l<=.0031308?12.92*l:1.055*Math.pow(l,1/2.4)-.055)}function Pu(l){return(l/=255)<=.04045?l/12.92:Math.pow((l+.055)/1.055,2.4)}function Mu(l){const o=Pu(l.r),u=Pu(l.g),d=Pu(l.b),p=ef((.4124564*o+.3575761*u+.1804375*d)/kl),_=ef((.2126729*o+.7151522*u+.072175*d)/1);return{l:116*_-16,a:500*(p-_),b:200*(_-ef((.0193339*o+.119192*u+.9503041*d)/zc)),alpha:l.a}}function rc(l){let o=(l.l+16)/116,u=isNaN(l.a)?o:o+l.a/500,d=isNaN(l.b)?o:o-l.b/200;return o=1*tf(o),u=kl*tf(u),d=zc*tf(d),new Rt(vh(3.2404542*u-1.5371385*o-.4985314*d),vh(-.969266*u+1.8760108*o+.041556*d),vh(.0556434*u-.2040259*o+1.0572252*d),l.alpha)}function Dg(l,o,u){const d=o-l;return l+u*(d>180||d<-180?d-360*Math.round(d/360):d)}const Ua={forward:Mu,reverse:rc,interpolate:function(l,o,u){return{l:ur(l.l,o.l,u),a:ur(l.a,o.a,u),b:ur(l.b,o.b,u),alpha:ur(l.alpha,o.alpha,u)}}},$c={forward:function(l){const{l:o,a:u,b:d}=Mu(l),p=Math.atan2(d,u)*Op;return{h:p<0?p+360:p,c:Math.sqrt(u*u+d*d),l:o,alpha:l.a}},reverse:function(l){const o=l.h*Ip,u=l.c;return rc({l:l.l,a:Math.cos(o)*u,b:Math.sin(o)*u,alpha:l.alpha})},interpolate:function(l,o,u){return{h:Dg(l.h,o.h,u),c:ur(l.c,o.c,u),l:ur(l.l,o.l,u),alpha:ur(l.alpha,o.alpha,u)}}};var Ks=Object.freeze({__proto__:null,hcl:$c,lab:Ua});class jc{constructor(o,u,d,p,_){this.type=o,this.operator=u,this.interpolation=d,this.input=p,this.labels=[],this.outputs=[];for(const[b,E]of _)this.labels.push(b),this.outputs.push(E)}static interpolationFactor(o,u,d,p){let _=0;if(o.name==="exponential")_=nf(u,o.base,d,p);else if(o.name==="linear")_=nf(u,1,d,p);else if(o.name==="cubic-bezier"){const b=o.controlPoints;_=new Q(b[0],b[1],b[2],b[3]).solve(nf(u,1,d,p))}return _}static parse(o,u){let[d,p,_,...b]=o;if(!Array.isArray(p)||p.length===0)return u.error("Expected an interpolation type expression.",1);if(p[0]==="linear")p={name:"linear"};else if(p[0]==="exponential"){const M=p[1];if(typeof M!="number")return u.error("Exponential interpolation requires a numeric base.",1,1);p={name:"exponential",base:M}}else{if(p[0]!=="cubic-bezier")return u.error(`Unknown interpolation type ${String(p[0])}`,1,0);{const M=p.slice(1);if(M.length!==4||M.some(F=>typeof F!="number"||F<0||F>1))return u.error("Cubic bezier interpolation requires four numeric arguments with values between 0 and 1.",1);p={name:"cubic-bezier",controlPoints:M}}}if(o.length-1<4)return u.error(`Expected at least 4 arguments, but found only ${o.length-1}.`);if((o.length-1)%2!=0)return u.error("Expected an even number of arguments.");if(_=u.parse(_,2,dn),!_)return null;const E=[];let k=null;d==="interpolate-hcl"||d==="interpolate-lab"?k=Aa:u.expectedType&&u.expectedType.kind!=="value"&&(k=u.expectedType);for(let M=0;M<b.length;M+=2){const F=b[M],$=b[M+1],V=M+3,X=M+4;if(typeof F!="number")return u.error('Input/output pairs for "interpolate" expressions must be defined using literal numeric values (not computed expressions) for the input values.',V);if(E.length&&E[E.length-1][0]>=F)return u.error('Input/output pairs for "interpolate" expressions must be arranged with input values in strictly ascending order.',V);const J=u.parse($,X,k);if(!J)return null;k=k||J.type,E.push([F,J])}return k.kind==="number"||k.kind==="color"||k.kind==="array"&&k.itemType.kind==="number"&&typeof k.N=="number"?new jc(k,d,p,_,E):u.error(`Type ${Ve(k)} is not interpolatable.`)}evaluate(o){const u=this.labels,d=this.outputs;if(u.length===1)return d[0].evaluate(o);const p=this.input.evaluate(o);if(p<=u[0])return d[0].evaluate(o);const _=u.length;if(p>=u[_-1])return d[_-1].evaluate(o);const b=_h(u,p),E=jc.interpolationFactor(this.interpolation,p,u[b],u[b+1]),k=d[b].evaluate(o),M=d[b+1].evaluate(o);return this.operator==="interpolate"?Pa[this.type.kind.toLowerCase()](k,M,E):this.operator==="interpolate-hcl"?$c.reverse($c.interpolate($c.forward(k),$c.forward(M),E)):Ua.reverse(Ua.interpolate(Ua.forward(k),Ua.forward(M),E))}eachChild(o){o(this.input);for(const u of this.outputs)o(u)}outputDefined(){return this.outputs.every(o=>o.outputDefined())}serialize(){let o;o=this.interpolation.name==="linear"?["linear"]:this.interpolation.name==="exponential"?this.interpolation.base===1?["linear"]:["exponential",this.interpolation.base]:["cubic-bezier"].concat(this.interpolation.controlPoints);const u=[this.operator,o,this.input.serialize()];for(let d=0;d<this.labels.length;d++)u.push(this.labels[d],this.outputs[d].serialize());return u}}function nf(l,o,u,d){const p=d-u,_=l-u;return p===0?0:o===1?_/p:(Math.pow(o,_)-1)/(Math.pow(o,p)-1)}var Ma=jc;class Uc{constructor(o,u){this.type=o,this.args=u}static parse(o,u){if(o.length<2)return u.error("Expectected at least one argument.");let d=null;const p=u.expectedType;p&&p.kind!=="value"&&(d=p);const _=[];for(const E of o.slice(1)){const k=u.parse(E,1+_.length,d,void 0,{typeAnnotation:"omit"});if(!k)return null;d=d||k.type,_.push(k)}const b=p&&_.some(E=>it(p,E.type));return new Uc(b?tr:d,_)}evaluate(o){let u,d=null,p=0;for(const _ of this.args){if(p++,d=_.evaluate(o),d&&d instanceof zr&&!d.available&&(u||(u=d),d=null,p===this.args.length))return u;if(d!==null)break}return d}
113eachChild(o){this.args.forEach(o)}outputDefined(){return this.args.every(o=>o.outputDefined())}serialize(){const o=["coalesce"];return this.eachChild(u=>{o.push(u.serialize())}),o}}var bh=Uc;class Iu{constructor(o,u){this.type=u.type,this.bindings=[].concat(o),this.result=u}evaluate(o){return this.result.evaluate(o)}eachChild(o){for(const u of this.bindings)o(u[1]);o(this.result)}static parse(o,u){if(o.length<4)return u.error(`Expected at least 3 arguments, but found ${o.length-1} instead.`);const d=[];for(let _=1;_<o.length-1;_+=2){const b=o[_];if(typeof b!="string")return u.error(`Expected string, but found ${typeof b} instead.`,_);if(/[^a-zA-Z0-9_]/.test(b))return u.error("Variable names must contain only alphanumeric characters or '_'.",_);const E=u.parse(o[_+1],_+1);if(!E)return null;d.push([b,E])}const p=u.parse(o[o.length-1],o.length-1,u.expectedType,d);return p?new Iu(d,p):null}outputDefined(){return this.result.outputDefined()}serialize(){const o=["let"];for(const[u,d]of this.bindings)o.push(u,d.serialize());return o.push(this.result.serialize()),o}}var rf=Iu;class ic{constructor(o,u,d){this.type=o,this.index=u,this.input=d}static parse(o,u){if(o.length!==3)return u.error(`Expected 2 arguments, but found ${o.length-1} instead.`);const d=u.parse(o[1],1,dn),p=u.parse(o[2],2,Re(u.expectedType||tr));return d&&p?new ic(p.type.itemType,d,p):null}evaluate(o){const u=this.index.evaluate(o),d=this.input.evaluate(o);if(u<0)throw new Mo(`Array index out of bounds: ${u} < 0.`);if(u>=d.length)throw new Mo(`Array index out of bounds: ${u} > ${d.length-1}.`);if(u!==Math.floor(u))throw new Mo(`Array index must be an integer, but found ${u} instead.`);return d[u]}eachChild(o){o(this.index),o(this.input)}outputDefined(){return!1}serialize(){return["at",this.index.serialize(),this.input.serialize()]}}var Dp=ic;class of{constructor(o,u){this.type=cr,this.needle=o,this.haystack=u}static parse(o,u){if(o.length!==3)return u.error(`Expected 2 arguments, but found ${o.length-1} instead.`);const d=u.parse(o[1],1,tr),p=u.parse(o[2],2,tr);return d&&p?Qt(d.type,[cr,fr,dn,bl,tr])?new of(d,p):u.error(`Expected first argument to be of type boolean, string, number or null, but found ${Ve(d.type)} instead`):null}evaluate(o){const u=this.needle.evaluate(o),d=this.haystack.evaluate(o);if(d==null)return!1;if(!on(u,["boolean","string","number","null"]))throw new Mo(`Expected first argument to be of type boolean, string, number or null, but found ${Ve(Kn(u))} instead.`);if(!on(d,["string","array"]))throw new Mo(`Expected second argument to be of type array or string, but found ${Ve(Kn(d))} instead.`);return d.indexOf(u)>=0}eachChild(o){o(this.needle),o(this.haystack)}outputDefined(){return!0}serialize(){return["in",this.needle.serialize(),this.haystack.serialize()]}}var at=of;class Ot{constructor(o,u,d){this.type=dn,this.needle=o,this.haystack=u,this.fromIndex=d}static parse(o,u){if(o.length<=2||o.length>=5)return u.error(`Expected 3 or 4 arguments, but found ${o.length-1} instead.`);const d=u.parse(o[1],1,tr),p=u.parse(o[2],2,tr);if(!d||!p)return null;if(!Qt(d.type,[cr,fr,dn,bl,tr]))return u.error(`Expected first argument to be of type boolean, string, number or null, but found ${Ve(d.type)} instead`);if(o.length===4){const _=u.parse(o[3],3,dn);return _?new Ot(d,p,_):null}return new Ot(d,p)}evaluate(o){const u=this.needle.evaluate(o),d=this.haystack.evaluate(o);if(!on(u,["boolean","string","number","null"]))throw new Mo(`Expected first argument to be of type boolean, string, number or null, but found ${Ve(Kn(u))} instead.`);if(!on(d,["string","array"]))throw new Mo(`Expected second argument to be of type array or string, but found ${Ve(Kn(d))} instead.`);if(this.fromIndex){const p=this.fromIndex.evaluate(o);return d.indexOf(u,p)}return d.indexOf(u)}eachChild(o){o(this.needle),o(this.haystack),this.fromIndex&&o(this.fromIndex)}outputDefined(){return!1}serialize(){if(this.fromIndex!=null&&this.fromIndex!==void 0){const o=this.fromIndex.serialize();return["index-of",this.needle.serialize(),this.haystack.serialize(),o]}return["index-of",this.needle.serialize(),this.haystack.serialize()]}}var yn=Ot;class Fn{constructor(o,u,d,p,_,b){this.inputType=o,this.type=u,this.input=d,this.cases=p,this.outputs=_,this.otherwise=b}static parse(o,u){if(o.length<5)return u.error(`Expected at least 4 arguments, but found only ${o.length-1}.`);if(o.length%2!=1)return u.error("Expected an even number of arguments.");let d,p;u.expectedType&&u.expectedType.kind!=="value"&&(p=u.expectedType);const _={},b=[];for(let M=2;M<o.length-1;M+=2){let F=o[M];const $=o[M+1];Array.isArray(F)||(F=[F]);const V=u.concat(M);if(F.length===0)return V.error("Expected at least one branch label.");for(const J of F){if(typeof J!="number"&&typeof J!="string")return V.error("Branch labels must be numbers or strings.");if(typeof J=="number"&&Math.abs(J)>Number.MAX_SAFE_INTEGER)return V.error(`Branch labels must be integers no larger than ${Number.MAX_SAFE_INTEGER}.`);if(typeof J=="number"&&Math.floor(J)!==J)return V.error("Numeric branch labels must be integer values.");if(d){if(V.checkSubtype(d,Kn(J)))return null}else d=Kn(J);if(_[String(J)]!==void 0)return V.error("Branch labels must be unique.");_[String(J)]=b.length}const X=u.parse($,M,p);if(!X)return null;p=p||X.type,b.push(X)}const E=u.parse(o[1],1,tr);if(!E)return null;
vendor: 16,183 bytes, line 113
113const k=u.parse(o[o.length-1],o.length-1,p);return k?E.type.kind!=="value"&&u.concat(1).checkSubtype(d,E.type)?null:new Fn(d,p,E,_,b,k):null}evaluate(o){const u=this.input.evaluate(o);return(Kn(u)===this.inputType&&this.outputs[this.cases[u]]||this.otherwise).evaluate(o)}eachChild(o){o(this.input),this.outputs.forEach(o),o(this.otherwise)}outputDefined(){return this.outputs.every(o=>o.outputDefined())&&this.otherwise.outputDefined()}serialize(){const o=["match",this.input.serialize()],u=Object.keys(this.cases).sort(),d=[],p={};for(const b of u){const E=p[this.cases[b]];E===void 0?(p[this.cases[b]]=d.length,d.push([this.cases[b],[b]])):d[E][1].push(b)}const _=b=>this.inputType.kind==="number"?Number(b):b;for(const[b,E]of d)o.push(E.length===1?_(E[0]):E.map(_)),o.push(this.outputs[b].serialize());return o.push(this.otherwise.serialize()),o}}var wi=Fn;class xr{constructor(o,u,d){this.type=o,this.branches=u,this.otherwise=d}static parse(o,u){if(o.length<4)return u.error(`Expected at least 3 arguments, but found only ${o.length-1}.`);if(o.length%2!=0)return u.error("Expected an odd number of arguments.");let d;u.expectedType&&u.expectedType.kind!=="value"&&(d=u.expectedType);const p=[];for(let b=1;b<o.length-1;b+=2){const E=u.parse(o[b],b,cr);if(!E)return null;const k=u.parse(o[b+1],b+1,d);if(!k)return null;p.push([E,k]),d=d||k.type}const _=u.parse(o[o.length-1],o.length-1,d);return _?new xr(d,p,_):null}evaluate(o){for(const[u,d]of this.branches)if(u.evaluate(o))return d.evaluate(o);return this.otherwise.evaluate(o)}eachChild(o){for(const[u,d]of this.branches)o(u),o(d);o(this.otherwise)}outputDefined(){return this.branches.every(([o,u])=>u.outputDefined())&&this.otherwise.outputDefined()}serialize(){const o=["case"];return this.eachChild(u=>{o.push(u.serialize())}),o}}var ji=xr;class Pi{constructor(o,u,d,p){this.type=o,this.input=u,this.beginIndex=d,this.endIndex=p}static parse(o,u){if(o.length<=2||o.length>=5)return u.error(`Expected 3 or 4 arguments, but found ${o.length-1} instead.`);const d=u.parse(o[1],1,tr),p=u.parse(o[2],2,dn);if(!d||!p)return null;if(!Qt(d.type,[Re(tr),fr,tr]))return u.error(`Expected first argument to be of type array or string, but found ${Ve(d.type)} instead`);if(o.length===4){const _=u.parse(o[3],3,dn);return _?new Pi(d.type,d,p,_):null}return new Pi(d.type,d,p)}evaluate(o){const u=this.input.evaluate(o),d=this.beginIndex.evaluate(o);if(!on(u,["string","array"]))throw new Mo(`Expected first argument to be of type array or string, but found ${Ve(Kn(u))} instead.`);if(this.endIndex){const p=this.endIndex.evaluate(o);return u.slice(d,p)}return u.slice(d)}eachChild(o){o(this.input),o(this.beginIndex),this.endIndex&&o(this.endIndex)}outputDefined(){return!1}serialize(){if(this.endIndex!=null&&this.endIndex!==void 0){const o=this.endIndex.serialize();return["slice",this.input.serialize(),this.beginIndex.serialize(),o]}return["slice",this.input.serialize(),this.beginIndex.serialize()]}}var Va=Pi;function Hi(l,o){return l==="=="||l==="!="?o.kind==="boolean"||o.kind==="string"||o.kind==="number"||o.kind==="null"||o.kind==="value":o.kind==="string"||o.kind==="number"||o.kind==="value"}function lo(l,o,u,d){return d.compare(o,u)===0}function ra(l,o,u){const d=l!=="=="&&l!=="!=";return class E5{constructor(_,b,E){this.type=cr,this.lhs=_,this.rhs=b,this.collator=E,this.hasUntypedArgument=_.type.kind==="value"||b.type.kind==="value"}static parse(_,b){if(_.length!==3&&_.length!==4)return b.error("Expected two or three arguments.");const E=_[0];let k=b.parse(_[1],1,tr);if(!k)return null;if(!Hi(E,k.type))return b.concat(1).error(`"${E}" comparisons are not supported for type '${Ve(k.type)}'.`);let M=b.parse(_[2],2,tr);if(!M)return null;if(!Hi(E,M.type))return b.concat(2).error(`"${E}" comparisons are not supported for type '${Ve(M.type)}'.`);if(k.type.kind!==M.type.kind&&k.type.kind!=="value"&&M.type.kind!=="value")return b.error(`Cannot compare types '${Ve(k.type)}' and '${Ve(M.type)}'.`);d&&(k.type.kind==="value"&&M.type.kind!=="value"?k=new as(M.type,[k]):k.type.kind!=="value"&&M.type.kind==="value"&&(M=new as(k.type,[M])));let F=null;if(_.length===4){if(k.type.kind!=="string"&&M.type.kind!=="string"&&k.type.kind!=="value"&&M.type.kind!=="value")return b.error("Cannot use collator to compare non-string types.");if(F=b.parse(_[3],3,O),!F)return null}return new E5(k,M,F)}evaluate(_){const b=this.lhs.evaluate(_),E=this.rhs.evaluate(_);if(d&&this.hasUntypedArgument){const k=Kn(b),M=Kn(E);if(k.kind!==M.kind||k.kind!=="string"&&k.kind!=="number")throw new Mo(`Expected arguments for "${l}" to be (string, string) or (number, number), but found (${k.kind}, ${M.kind}) instead.`)}if(this.collator&&!d&&this.hasUntypedArgument){const k=Kn(b),M=Kn(E);if(k.kind!=="string"||M.kind!=="string")return o(_,b,E)}return this.collator?u(_,b,E,this.collator.evaluate(_)):o(_,b,E)}eachChild(_){_(this.lhs),_(this.rhs),this.collator&&_(this.collator)}outputDefined(){return!0}serialize(){const _=[l];return this.eachChild(b=>{_.push(b.serialize())}),_}}}const Qs=ra("==",function(l,o,u){return o===u},lo),ia=ra("!=",function(l,o,u){return o!==u},function(l,o,u,d){return!lo(0,o,u,d)}),Js=ra("<",function(l,o,u){return o<u},function(l,o,u,d){return d.compare(o,u)<0}),Vc=ra(">",function(l,o,u){return o>u},function(l,o,u,d){return d.compare(o,u)>0}),xh=ra("<=",function(l,o,u){return o<=u},function(l,o,u,d){return d.compare(o,u)<=0}),oc=ra(">=",function(l,o,u){return o>=u},function(l,o,u,d){return d.compare(o,u)>=0});class Al{constructor(o,u,d,p,_,b){this.type=fr,this.number=o,this.locale=u,this.currency=d,this.unit=p,this.minFractionDigits=_,this.maxFractionDigits=b}static parse(o,u){if(o.length!==3)return u.error("Expected two arguments.");const d=u.parse(o[1],1,dn);if(!d)return null;const p=o[2];if(typeof p!="object"||Array.isArray(p))return u.error("NumberFormat options argument must be an object.");let _=null;if(p.locale&&(_=u.parse(p.locale,1,fr),!_))return null;let b=null;if(p.currency&&(b=u.parse(p.currency,1,fr),!b))return null;let E=null;if(p.unit&&(E=u.parse(p.unit,1,fr),!E))return null;let k=null;if(p["min-fraction-digits"]&&(k=u.parse(p["min-fraction-digits"],1,dn),!k))return null;let M=null;return p["max-fraction-digits"]&&(M=u.parse(p["max-fraction-digits"],1,dn),!M)?null:new Al(d,_,b,E,k,M)}evaluate(o){return new Intl.NumberFormat(this.locale?this.locale.evaluate(o):[],{style:(this.currency?"currency":this.unit&&"unit")||"decimal",currency:this.currency?this.currency.evaluate(o):void 0,unit:this.unit?this.unit.evaluate(o):void 0,minimumFractionDigits:this.minFractionDigits?this.minFractionDigits.evaluate(o):void 0,maximumFractionDigits:this.maxFractionDigits?this.maxFractionDigits.evaluate(o):void 0}).format(this.number.evaluate(o))}eachChild(o){o(this.number),this.locale&&o(this.locale),this.currency&&o(this.currency),this.unit&&o(this.unit),this.minFractionDigits&&o(this.minFractionDigits),this.maxFractionDigits&&o(this.maxFractionDigits)}outputDefined(){return!1}serialize(){const o={};return this.locale&&(o.locale=this.locale.serialize()),this.currency&&(o.currency=this.currency.serialize()),this.unit&&(o.unit=this.unit.serialize()),this.minFractionDigits&&(o["min-fraction-digits"]=this.minFractionDigits.serialize()),this.maxFractionDigits&&(o["max-fraction-digits"]=this.maxFractionDigits.serialize()),["number-format",this.number.serialize(),o]}}class ac{constructor(o){this.type=dn,this.input=o}static parse(o,u){if(o.length!==2)return u.error(`Expected 1 argument, but found ${o.length-1} instead.`);const d=u.parse(o[1],1);return d?d.type.kind!=="array"&&d.type.kind!=="string"&&d.type.kind!=="value"?u.error(`Expected argument of type string or array, but found ${Ve(d.type)} instead.`):new ac(d):null}evaluate(o){const u=this.input.evaluate(o);if(typeof u=="string"||Array.isArray(u))return u.length;throw new Mo(`Expected value to be of type string or array, but found ${Ve(Kn(u))} instead.`)}eachChild(o){o(this.input)}outputDefined(){return!1}serialize(){const o=["length"];return this.eachChild(u=>{o.push(u.serialize())}),o}}const Lp={"==":Qs,"!=":ia,">":Vc,"<":Js,">=":oc,"<=":xh,array:as,at:Dp,boolean:as,case:ji,coalesce:bh,collator:Tu,format:Ws,image:wu,in:at,"index-of":yn,interpolate:Ma,"interpolate-hcl":Ma,"interpolate-lab":Ma,length:ac,let:rf,literal:na,match:wi,number:as,"number-format":Al,object:as,slice:Va,step:ku,string:as,"to-boolean":Fc,"to-color":Fc,"to-number":Fc,"to-string":Fc,var:Mp,within:El};function Rp(l,[o,u,d,p]){o=o.evaluate(l),u=u.evaluate(l),d=d.evaluate(l);const _=p?p.evaluate(l):1,b=dh(o,u,d,_);if(b)throw new Mo(b);return new Rt(o/255*_,u/255*_,d/255*_,_)}function Cr(l,o){return l in o}function Lr(l,o){const u=o[l];return u===void 0?null:u}function oa(l){return{type:l}}Hs.register(Lp,{error:[{kind:"error"},[fr],(l,[o])=>{throw new Mo(o.evaluate(l))}],typeof:[fr,[tr],(l,[o])=>Ve(Kn(o.evaluate(l)))],"to-rgba":[Re(dn,4),[Aa],(l,[o])=>o.evaluate(l).toArray()],rgb:[Aa,[dn,dn,dn],Rp],rgba:[Aa,[dn,dn,dn,dn],Rp],has:{type:cr,overloads:[[[fr],(l,[o])=>Cr(o.evaluate(l),l.properties())],[[fr,os],(l,[o,u])=>Cr(o.evaluate(l),u.evaluate(l))]]},get:{type:tr,overloads:[[[fr],(l,[o])=>Lr(o.evaluate(l),l.properties())],[[fr,os],(l,[o,u])=>Lr(o.evaluate(l),u.evaluate(l))]]},"feature-state":[tr,[fr],(l,[o])=>Lr(o.evaluate(l),l.featureState||{})],properties:[os,[],l=>l.properties()],"geometry-type":[fr,[],l=>l.geometryType()],id:[tr,[],l=>l.id()],zoom:[dn,[],l=>l.globals.zoom],pitch:[dn,[],l=>l.globals.pitch||0],"distance-from-center":[dn,[],l=>l.distanceFromCenter()],"heatmap-density":[dn,[],l=>l.globals.heatmapDensity||0],"line-progress":[dn,[],l=>l.globals.lineProgress||0],"sky-radial-progress":[dn,[],l=>l.globals.skyRadialProgress||0],accumulated:[tr,[],l=>l.globals.accumulated===void 0?null:l.globals.accumulated],"+":[dn,oa(dn),(l,o)=>{let u=0;for(const d of o)u+=d.evaluate(l);return u}],"*":[dn,oa(dn),(l,o)=>{let u=1;for(const d of o)u*=d.evaluate(l);return u}],"-":{type:dn,overloads:[[[dn,dn],(l,[o,u])=>o.evaluate(l)-u.evaluate(l)],[[dn],(l,[o])=>-o.evaluate(l)]]},"/":[dn,[dn,dn],(l,[o,u])=>o.evaluate(l)/u.evaluate(l)],"%":[dn,[dn,dn],(l,[o,u])=>o.evaluate(l)%u.evaluate(l)],ln2:[dn,[],()=>Math.LN2],pi:[dn,[],()=>Math.PI],e:[dn,[],()=>Math.E],"^":[dn,[dn,dn],(l,[o,u])=>Math.pow(o.evaluate(l),u.evaluate(l))],sqrt:[dn,[dn],(l,[o])=>Math.sqrt(o.evaluate(l))],log10:[dn,[dn],(l,[o])=>Math.log(o.evaluate(l))/Math.LN10],ln:[dn,[dn],(l,[o])=>Math.log(o.evaluate(l))],log2:[dn,[dn],(l,[o])=>Math.log(o.evaluate(l))/Math.LN2],sin:[dn,[dn],(l,[o])=>Math.sin(o.evaluate(l))],cos:[dn,[dn],(l,[o])=>Math.cos(o.evaluate(l))],tan:[dn,[dn],(l,[o])=>Math.tan(o.evaluate(l))],asin:[dn,[dn],(l,[o])=>Math.asin(o.evaluate(l))],acos:[dn,[dn],(l,[o])=>Math.acos(o.evaluate(l))],atan:[dn,[dn],(l,[o])=>Math.atan(o.evaluate(l))],min:[dn,oa(dn),(l,o)=>Math.min(...o.map(u=>u.evaluate(l)))],max:[dn,oa(dn),(l,o)=>Math.max(...o.map(u=>u.evaluate(l)))],abs:[dn,[dn],(l,[o])=>Math.abs(o.evaluate(l))],round:[dn,[dn],(l,[o])=>{const u=o.evaluate(l);return u<0?-Math.round(-u):Math.round(u)}],floor:[dn,[dn],(l,[o])=>Math.floor(o.evaluate(l))],ceil:[dn,[dn],(l,[o])=>Math.ceil(o.evaluate(l))],"filter-==":[cr,[fr,tr],(l,[o,u])=>l.properties()[o.value]===u.value],"filter-id-==":[cr,[tr],(l,[o])=>l.id()===o.value],"filter-type-==":[cr,[fr],(l,[o])=>l.geometryType()===o.value],"filter-<":[cr,[fr,tr],(l,[o,u])=>{const d=l.properties()[o.value],p=u.value;return typeof d==typeof p&&d<p}],"filter-id-<":[cr,[tr],(l,[o])=>{const u=l.id(),d=o.value;return typeof u==typeof d&&u<d}],"filter->":[cr,[fr,tr],(l,[o,u])=>{const d=l.properties()[o.value],p=u.value;return typeof d==typeof p&&d>p}],"filter-id->":[cr,[tr],(l,[o])=>{const u=l.id(),d=o.value;return typeof u==typeof d&&u>d}],"filter-<=":[cr,[fr,tr],(l,[o,u])=>{const d=l.properties()[o.value],p=u.value;return typeof d==typeof p&&d<=p}],"filter-id-<=":[cr,[tr],(l,[o])=>{const u=l.id(),d=o.value;return typeof u==typeof d&&u<=d}],"filter->=":[cr,[fr,tr],(l,[o,u])=>{const d=l.properties()[o.value],p=u.value;return typeof d==typeof p&&d>=p}],"filter-id->=":[cr,[tr],(l,[o])=>{const u=l.id(),d=o.value;return typeof u==typeof d&&u>=d}],"filter-has":[cr,[tr],(l,[o])=>o.value in l.properties()],"filter-has-id":[cr,[],l=>l.id()!==null&&l.id()!==void 0],"filter-type-in":[cr,[Re(fr)],(l,[o])=>o.value.indexOf(l.geometryType())>=0],"filter-id-in":[cr,[Re(tr)],(l,[o])=>o.value.indexOf(l.id())>=0],"filter-in-small":[cr,[fr,Re(tr)],(l,[o,u])=>u.value.indexOf(l.properties()[o.value])>=0],"filter-in-large":[cr,[fr,Re(tr)],(l,[o,u])=>function(d,p,_,b){for(;_<=b;){const E=_+b>>1;if(p[E]===d)return!0;p[E]>d?b=E-1:_=E+1}return!1}(l.properties()[o.value],u.value,0,u.value.length-1)],all:{type:cr,overloads:[[[cr,cr],(l,[o,u])=>o.evaluate(l)&&u.evaluate(l)],[oa(cr),(l,o)=>{for(const u of o)if(!u.evaluate(l))return!1;return!0}]]},any:{type:cr,overloads:[[[cr,cr],(l,[o,u])=>o.evaluate(l)||u.evaluate(l)],[oa(cr),(l,o)=>{for(const u of o)if(u.evaluate(l))return!0;return!1}]]},"!":[cr,[cr],(l,[o])=>!o.evaluate(l)],"is-supported-script":[cr,[fr],(l,[o])=>{const u=l.globals&&l.globals.isSupportedScript;return!u||u(o.evaluate(l))}],upcase:[fr,[fr],(l,[o])=>o.evaluate(l).toUpperCase()],downcase:[fr,[fr],(l,[o])=>o.evaluate(l).toLowerCase()],concat:[fr,oa(tr),(l,o)=>o.map(u=>Rc(u.evaluate(l))).join("")],"resolved-locale":[fr,[O],(l,[o])=>o.evaluate(l).resolvedLocale()]});var Ga=Lp;function wh(l){return{result:"success",value:l}}function Io(l){return{result:"error",value:l}}function ma(l){return l["property-type"]==="data-driven"}function cs(l){return!!l.expression&&l.expression.parameters.indexOf("zoom")>-1}function Pl(l){return!!l.expression&&l.expression.interpolated}function _r(l){return l instanceof Number?"number":l instanceof String?"string":l instanceof Boolean?"boolean":Array.isArray(l)?"array":l===null?"null":typeof l}function Es(l){return typeof l=="object"&&l!==null&&!Array.isArray(l)}function Ml(l){return l}function Ou(l,o){const u=o.type==="color",d=l.stops&&typeof l.stops[0][0]=="object",p=d||!(d||l.property!==void 0),_=l.type||(Pl(o)?"exponential":"interval");if(u&&((l=ta({},l)).stops&&(l.stops=l.stops.map(M=>[M[0],Rt.parse(M[1])])),l.default=Rt.parse(l.default?l.default:o.default)),l.colorSpace&&l.colorSpace!=="rgb"&&!Ks[l.colorSpace])throw new Error(`Unknown color space: ${l.colorSpace}`);let b,E,k;if(_==="exponential")b=qa;else if(_==="interval")b=sc;else if(_==="categorical"){b=Th,E=Object.create(null);for(const M of l.stops)E[M[0]]=M[1];k=typeof l.stops[0][0]}else{if(_!=="identity")throw new Error(`Unknown function type "${_}"`);b=af}if(d){const M={},F=[];for(let X=0;X<l.stops.length;X++){const J=l.stops[X],re=J[0].zoom;M[re]===void 0&&(M[re]={zoom:re,type:l.type,property:l.property,default:l.default,stops:[]},F.push(re)),M[re].stops.push([J[0].value,J[1]])}const $=[];for(const X of F)$.push([M[X].zoom,Ou(M[X],o)]);const V={name:"linear"};return{kind:"composite",interpolationType:V,interpolationFactor:Ma.interpolationFactor.bind(void 0,V),zoomStops:$.map(X=>X[0]),evaluate:({zoom:X},J)=>qa({stops:$,base:l.base},o,X).evaluate(X,J)}}if(p){const M=_==="exponential"?{name:"exponential",base:l.base!==void 0?l.base:1}:null;return{kind:"camera",interpolationType:M,interpolationFactor:Ma.interpolationFactor.bind(void 0,M),zoomStops:l.stops.map(F=>F[0]),evaluate:({zoom:F})=>b(l,o,F,E,k)}}return{kind:"source",evaluate(M,F){const $=F&&F.properties?F.properties[l.property]:void 0;return $===void 0?el(l.default,o.default):b(l,o,$,E,k)}}}function el(l,o,u){return l!==void 0?l:o!==void 0?o:u!==void 0?u:void 0}function Th(l,o,u,d,p){return el(typeof u===p?d[u]:void 0,l.default,o.default)}function sc(l,o,u){if(_r(u)!=="number")return el(l.default,o.default);const d=l.stops.length;if(d===1||u<=l.stops[0][0])return l.stops[0][1];if(u>=l.stops[d-1][0])return l.stops[d-1][1];const p=_h(l.stops.map(_=>_[0]),u);return l.stops[p][1]}function qa(l,o,u){const d=l.base!==void 0?l.base:1;if(_r(u)!=="number")return el(l.default,o.default);const p=l.stops.length;if(p===1||u<=l.stops[0][0])return l.stops[0][1];if(u>=l.stops[p-1][0])return l.stops[p-1][1];const _=_h(l.stops.map(F=>F[0]),u),b=function(F,$,V,X){const J=X-V,re=F-V;
113return J===0?0:$===1?re/J:(Math.pow($,re)-1)/(Math.pow($,J)-1)}(u,d,l.stops[_][0],l.stops[_+1][0]),E=l.stops[_][1],k=l.stops[_+1][1];let M=Pa[o.type]||Ml;if(l.colorSpace&&l.colorSpace!=="rgb"){const F=Ks[l.colorSpace];M=($,V)=>F.reverse(F.interpolate(F.forward($),F.forward(V),b))}return typeof E.evaluate=="function"?{evaluate(...F){const $=E.evaluate.apply(void 0,F),V=k.evaluate.apply(void 0,F);if($!==void 0&&V!==void 0)return M($,V,b)}}:M(E,k,b)}function af(l,o,u){return o.type==="color"?u=Rt.parse(u):o.type==="formatted"?u=Br.fromString(u.toString()):o.type==="resolvedImage"?u=zr.fromString(u.toString()):_r(u)===o.type||o.type==="enum"&&o.values[u]||(u=void 0),el(u,l.default,o.default)}class lc{constructor(o,u){this.expression=o,this._warningHistory={},this._evaluator=new mh,this._defaultValue=u?function(d){return d.type==="color"&&(Es(d.default)||Array.isArray(d.default))?new Rt(0,0,0,0):d.type==="color"?Rt.parse(d.default)||null:d.default===void 0?null:d.default}(u):null,this._enumValues=u&&u.type==="enum"?u.values:null}evaluateWithoutErrorHandling(o,u,d,p,_,b,E,k){return this._evaluator.globals=o,this._evaluator.feature=u,this._evaluator.featureState=d,this._evaluator.canonical=p||null,this._evaluator.availableImages=_||null,this._evaluator.formattedSection=b,this._evaluator.featureTileCoord=E||null,this._evaluator.featureDistanceData=k||null,this.expression.evaluate(this._evaluator)}evaluate(o,u,d,p,_,b,E,k){this._evaluator.globals=o,this._evaluator.feature=u||null,this._evaluator.featureState=d||null,this._evaluator.canonical=p||null,this._evaluator.availableImages=_||null,this._evaluator.formattedSection=b||null,this._evaluator.featureTileCoord=E||null,this._evaluator.featureDistanceData=k||null;try{const M=this.expression.evaluate(this._evaluator);if(M==null||typeof M=="number"&&M!=M)return this._defaultValue;if(this._enumValues&&!(M in this._enumValues))throw new Mo(`Expected value to be one of ${Object.keys(this._enumValues).map(F=>JSON.stringify(F)).join(", ")}, but found ${JSON.stringify(M)} instead.`);return M}catch(M){return this._warningHistory[M.message]||(this._warningHistory[M.message]=!0,typeof console<"u"&&console.warn(M.message)),this._defaultValue}}}function tl(l){return Array.isArray(l)&&l.length>0&&typeof l[0]=="string"&&l[0]in Ga}function Eh(l,o){const u=new Qd(Ga,[],o?function(p){const _={color:Aa,string:fr,number:dn,enum:fr,boolean:cr,formatted:G,resolvedImage:he};return p.type==="array"?Re(_[p.value]||tr,p.length):_[p.type]}(o):void 0),d=u.parse(l,void 0,void 0,void 0,o&&o.type==="string"?{typeAnnotation:"coerce"}:void 0);return d?wh(new lc(d,o)):Io(u.errors)}class Lg{constructor(o,u){this.kind=o,this._styleExpression=u,this.isStateDependent=o!=="constant"&&!ls(u.expression)}evaluateWithoutErrorHandling(o,u,d,p,_,b){return this._styleExpression.evaluateWithoutErrorHandling(o,u,d,p,_,b)}evaluate(o,u,d,p,_,b){return this._styleExpression.evaluate(o,u,d,p,_,b)}}class sf{constructor(o,u,d,p){this.kind=o,this.zoomStops=d,this._styleExpression=u,this.isStateDependent=o!=="camera"&&!ls(u.expression),this.interpolationType=p}evaluateWithoutErrorHandling(o,u,d,p,_,b){return this._styleExpression.evaluateWithoutErrorHandling(o,u,d,p,_,b)}evaluate(o,u,d,p,_,b){return this._styleExpression.evaluate(o,u,d,p,_,b)}interpolationFactor(o,u,d){return this.interpolationType?Ma.interpolationFactor(this.interpolationType,o,u,d):0}}function lf(l,o){if((l=Eh(l,o)).result==="error")return l;const u=l.value.expression,d=Sl(u);if(!d&&!ma(o))return Io([new Ts("","data expressions not supported")]);const p=Zs(u,["zoom","pitch","distance-from-center"]);if(!p&&!cs(o))return Io([new Ts("","zoom expressions not supported")]);const _=Bp(u);return _||p?_ instanceof Ts?Io([_]):_ instanceof Ma&&!Pl(o)?Io([new Ts("",'"interpolate" expressions cannot be used with this property')]):wh(_?new sf(d?"camera":"composite",l.value,_.labels,_ instanceof Ma?_.interpolation:void 0):new Lg(d?"constant":"source",l.value)):Io([new Ts("",'"zoom" expression may only be used as input to a top-level "step" or "interpolate" expression.')])}class Fp{constructor(o,u){this._parameters=o,this._specification=u,ta(this,Ou(this._parameters,this._specification))}static deserialize(o){return new Fp(o._parameters,o._specification)}static serialize(o){return{_parameters:o._parameters,_specification:o._specification}}}function Bp(l){let o=null;if(l instanceof rf)o=Bp(l.result);else if(l instanceof bh){for(const u of l.args)if(o=Bp(u),o)break}else(l instanceof ku||l instanceof Ma)&&l.input instanceof Hs&&l.input.name==="zoom"&&(o=l);return o instanceof Ts||l.eachChild(u=>{const d=Bp(u);d instanceof Ts?o=d:!o&&d?o=new Ts("",'"zoom" expression may only be used as input to a top-level "step" or "interpolate" expression.'):o&&d&&o!==d&&(o=new Ts("",'Only one zoom-based "step" or "interpolate" subexpression may be used in an expression.'))}),o}class vn{constructor(o,u,d,p){this.message=(o?`${o}: `:"")+d,p&&(this.identifier=p),u!=null&&u.__line__&&(this.line=u.__line__)}}function nl(l){const o=l.key,u=l.value,d=l.valueSpec||{},p=l.objectElementValidators||{},_=l.style,b=l.styleSpec;let E=[];const k=_r(u);if(k!=="object")return[new vn(o,u,`object expected, ${k} found`)];for(const M in u){const F=M.split(".")[0];let $;
113p[F]?$=p[F]:d[F]?$=ga:p["*"]?$=p["*"]:d["*"]&&($=ga),$?E=E.concat($({key:(o&&`${o}.`)+M,value:u[M],valueSpec:d[F]||d["*"],style:_,styleSpec:b,object:u,objectKey:M},u)):E.push(new vn(o,u[M],`unknown property "${M}"`))}for(const M in d)p[M]||d[M].required&&d[M].default===void 0&&u[M]===void 0&&E.push(new vn(o,u,`missing required property "${M}"`));return E}function Uv(l){const o=l.value,u=l.valueSpec,d=l.style,p=l.styleSpec,_=l.key,b=l.arrayElementValidator||ga;if(_r(o)!=="array")return[new vn(_,o,`array expected, ${_r(o)} found`)];if(u.length&&o.length!==u.length)return[new vn(_,o,`array length ${u.length} expected, length ${o.length} found`)];if(u["min-length"]&&o.length<u["min-length"])return[new vn(_,o,`array length at least ${u["min-length"]} expected, length ${o.length} found`)];let E={type:u.value,values:u.values,minimum:u.minimum,maximum:u.maximum,function:void 0};p.$version<7&&(E.function=u.function),_r(u.value)==="object"&&(E=u.value);let k=[];for(let M=0;M<o.length;M++)k=k.concat(b({array:o,arrayIndex:M,value:o[M],valueSpec:E,style:d,styleSpec:p,key:`${_}[${M}]`}));return k}function cf(l){const o=l.key,u=l.value,d=l.valueSpec;let p=_r(u);if(p==="number"&&u!=u&&(p="NaN"),p!=="number")return[new vn(o,u,`number expected, ${p} found`)];if("minimum"in d){let _=d.minimum;if(_r(d.minimum)==="array"&&(_=d.minimum[l.arrayIndex]),u<_)return[new vn(o,u,`${u} is less than the minimum value ${_}`)]}if("maximum"in d){let _=d.maximum;if(_r(d.maximum)==="array"&&(_=d.maximum[l.arrayIndex]),u>_)return[new vn(o,u,`${u} is greater than the maximum value ${_}`)]}return[]}function uf(l){const o=l.valueSpec,u=ci(l.value.type);let d,p,_,b={};const E=u!=="categorical"&&l.value.property===void 0,k=!E,M=_r(l.value.stops)==="array"&&_r(l.value.stops[0])==="array"&&_r(l.value.stops[0][0])==="object",F=nl({key:l.key,value:l.value,valueSpec:l.styleSpec.function,style:l.style,styleSpec:l.styleSpec,objectElementValidators:{stops:function(X){if(u==="identity")return[new vn(X.key,X.value,'identity function may not have a "stops" property')];let J=[];const re=X.value;return J=J.concat(Uv({key:X.key,value:re,valueSpec:X.valueSpec,style:X.style,styleSpec:X.styleSpec,arrayElementValidator:$})),_r(re)==="array"&&re.length===0&&J.push(new vn(X.key,re,"array must have at least one stop")),J},default:function(X){return ga({key:X.key,value:X.value,valueSpec:o,style:X.style,styleSpec:X.styleSpec})}}});return u==="identity"&&E&&F.push(new vn(l.key,l.value,'missing required property "property"')),u==="identity"||l.value.stops||F.push(new vn(l.key,l.value,'missing required property "stops"')),u==="exponential"&&l.valueSpec.expression&&!Pl(l.valueSpec)&&F.push(new vn(l.key,l.value,"exponential functions not supported")),l.styleSpec.$version>=8&&(k&&!ma(l.valueSpec)?F.push(new vn(l.key,l.value,"property functions not supported")):E&&!cs(l.valueSpec)&&F.push(new vn(l.key,l.value,"zoom functions not supported"))),u!=="categorical"&&!M||l.value.property!==void 0||F.push(new vn(l.key,l.value,'"property" property is required')),F;function $(X){let J=[];const re=X.value,pe=X.key;if(_r(re)!=="array")return[new vn(pe,re,`array expected, ${_r(re)} found`)];if(re.length!==2)return[new vn(pe,re,`array length 2 expected, length ${re.length} found`)];if(M){if(_r(re[0])!=="object")return[new vn(pe,re,`object expected, ${_r(re[0])} found`)];if(re[0].zoom===void 0)return[new vn(pe,re,"object stop key must have zoom")];if(re[0].value===void 0)return[new vn(pe,re,"object stop key must have value")];const Ce=ci(re[0].zoom);if(typeof Ce!="number")return[new vn(pe,re[0].zoom,"stop zoom values must be numbers")];if(_&&_>Ce)return[new vn(pe,re[0].zoom,"stop zoom values must appear in ascending order")];Ce!==_&&(_=Ce,p=void 0,b={}),J=J.concat(nl({key:`${pe}[0]`,value:re[0],valueSpec:{zoom:{}},style:X.style,styleSpec:X.styleSpec,objectElementValidators:{zoom:cf,value:V}}))}else J=J.concat(V({key:`${pe}[0]`,value:re[0],valueSpec:{},style:X.style,styleSpec:X.styleSpec},re));return tl(mo(re[1]))?J.concat([new vn(`${pe}[1]`,re[1],"expressions are not allowed in function stops.")]):J.concat(ga({key:`${pe}[1]`,value:re[1],valueSpec:o,style:X.style,styleSpec:X.styleSpec}))}function V(X,J){const re=_r(X.value),pe=ci(X.value),Ce=X.value!==null?X.value:J;if(d){if(re!==d)return[new vn(X.key,Ce,`${re} stop domain type must match previous stop domain type ${d}`)]}else d=re;if(re!=="number"&&re!=="string"&&re!=="boolean"&&typeof pe!="number"&&typeof pe!="string"&&typeof pe!="boolean")return[new vn(X.key,Ce,"stop domain value must be a number, string, or boolean")];if(re!=="number"&&u!=="categorical"){let ze=`number expected, ${re} found`;return ma(o)&&u===void 0&&(ze+='\nIf you intended to use a categorical function, specify `"type": "categorical"`.'),[new vn(X.key,Ce,ze)]}
113return u!=="categorical"||re!=="number"||typeof pe=="number"&&isFinite(pe)&&Math.floor(pe)===pe?u!=="categorical"&&re==="number"&&typeof pe=="number"&&typeof p=="number"&&p!==void 0&&pe<p?[new vn(X.key,Ce,"stop domain values must appear in ascending order")]:(p=pe,u==="categorical"&&pe in b?[new vn(X.key,Ce,"stop domain values must be unique")]:(b[pe]=!0,[])):[new vn(X.key,Ce,`integer expected, found ${String(pe)}`)]}}function Ho(l){const o=(l.expressionContext==="property"?lf:Eh)(mo(l.value),l.valueSpec);if(o.result==="error")return o.value.map(d=>new vn(`${l.key}${d.key}`,l.value,d.message));const u=o.value.expression||o.value._styleExpression.expression;if(l.expressionContext==="property"&&l.propertyKey==="text-font"&&!u.outputDefined())return[new vn(l.key,l.value,`Invalid data expression for "${l.propertyKey}". Output values must be contained as literals within the expression.`)];if(l.expressionContext==="property"&&l.propertyType==="layout"&&!ls(u))return[new vn(l.key,l.value,'"feature-state" data expressions are not supported with layout properties.')];if(l.expressionContext==="filter")return hf(u,l);if(l.expressionContext&&l.expressionContext.indexOf("cluster")===0){if(!Zs(u,["zoom","feature-state"]))return[new vn(l.key,l.value,'"zoom" and "feature-state" expressions are not supported with cluster properties.')];if(l.expressionContext==="cluster-initial"&&!Sl(u))return[new vn(l.key,l.value,"Feature data expressions are not supported with initial expression part of cluster properties.")]}return[]}function hf(l,o){const u=new Set(["zoom","feature-state","pitch","distance-from-center"]);if(o.valueSpec&&o.valueSpec.expression)for(const p of o.valueSpec.expression.parameters)u.delete(p);if(u.size===0)return[];const d=[];return l instanceof Hs&&u.has(l.name)?[new vn(o.key,o.value,`["${l.name}"] expression is not supported in a filter for a ${o.object.type} layer with id: ${o.object.id}`)]:(l.eachChild(p=>{d.push(...hf(p,o))}),d)}function zp(l){const o=l.key,u=l.value,d=l.valueSpec,p=[];return Array.isArray(d.values)?d.values.indexOf(ci(u))===-1&&p.push(new vn(o,u,`expected one of [${d.values.join(", ")}], ${JSON.stringify(u)} found`)):Object.keys(d.values).indexOf(ci(u))===-1&&p.push(new vn(o,u,`expected one of [${Object.keys(d.values).join(", ")}], ${JSON.stringify(u)} found`)),p}function Rg(l){if(l===!0||l===!1)return!0;if(!Array.isArray(l)||l.length===0)return!1;switch(l[0]){case"has":return l.length>=2&&l[1]!=="$id"&&l[1]!=="$type";case"in":return l.length>=3&&(typeof l[1]!="string"||Array.isArray(l[2]));case"!in":case"!has":case"none":return!1;case"==":case"!=":case">":case">=":case"<":case"<=":return l.length!==3||Array.isArray(l[1])||Array.isArray(l[2]);case"any":case"all":for(const o of l.slice(1))if(!Rg(o)&&typeof o!="boolean")return!1;return!0;default:return!0}}function Np(l,o="fill"){if(l==null)return{filter:()=>!0,needGeometry:!1,needFeature:!1};Rg(l)||(l=Ch(l));const u=l;let d=!0;try{d=function(M){if(!Sh(M))return M;let F=mo(M);return $p(F),F=Vv(F),F}(u)}catch{console.warn(`Failed to extract static filter. Filter will continue working, but at higher memory usage and slower framerate.
114This is most likely a bug, please report this via https://github.com/mapbox/mapbox-gl-js/issues/new?assignees=&labels=&template=Bug_report.md
115and paste the contents of this message in the report.
116Thank you!
117Filter Expression:
118${JSON.stringify(u,null,2)}
119        `)}const p=Pt[`filter_${o}`],_=Eh(d,p);let b=null;if(_.result==="error")throw new Error(_.value.map(M=>`${M.key}: ${M.message}`).join(", "));b=(M,F,$)=>_.value.evaluate(M,F,{},$);let E=null,k=null;if(d!==u){const M=Eh(u,p);if(M.result==="error")throw new Error(M.value.map(F=>`${F.key}: ${F.message}`).join(", "));E=(F,$,V,X,J)=>M.value.evaluate(F,$,{},V,void 0,void 0,X,J),k=!Sl(M.value.expression)}return{filter:b,dynamicFilter:E||void 0,needGeometry:Gv(d),needFeature:!!k}}function Vv(l){if(!Array.isArray(l))return l;const o=function(u){if(Fg.has(u[0])){for(let d=1;d<u.length;d++)if(Sh(u[d]))return!0}return u}(l);return o===!0?o:o.map(u=>Vv(u))}function $p(l){let o=!1;const u=[];
119if(l[0]==="case"){for(let d=1;d<l.length-1;d+=2)o=o||Sh(l[d]),u.push(l[d+1]);u.push(l[l.length-1])}else if(l[0]==="match"){o=o||Sh(l[1]);for(let d=2;d<l.length-1;d+=2)u.push(l[d+1]);u.push(l[l.length-1])}else if(l[0]==="step"){o=o||Sh(l[1]);for(let d=1;d<l.length-1;d+=2)u.push(l[d+1])}o&&(l.length=0,l.push("any",...u));for(let d=1;d<l.length;d++)$p(l[d])}function Sh(l){if(!Array.isArray(l))return!1;if((o=l[0])==="pitch"||o==="distance-from-center")return!0;var o;for(let u=1;u<l.length;u++)if(Sh(l[u]))return!0;return!1}const Fg=new Set(["in","==","!=",">",">=","<","<=","to-boolean"]);function N1(l,o){return l<o?-1:l>o?1:0}function Gv(l){if(!Array.isArray(l))return!1;if(l[0]==="within")return!0;for(let o=1;o<l.length;o++)if(Gv(l[o]))return!0;return!1}function Ch(l){if(!l)return!0;const o=l[0];return l.length<=1?o!=="any":o==="=="?Bg(l[1],l[2],"=="):o==="!="?jp(Bg(l[1],l[2],"==")):o==="<"||o===">"||o==="<="||o===">="?Bg(l[1],l[2],o):o==="any"?(u=l.slice(1),["any"].concat(u.map(Ch))):o==="all"?["all"].concat(l.slice(1).map(Ch)):o==="none"?["all"].concat(l.slice(1).map(Ch).map(jp)):o==="in"?zg(l[1],l.slice(2)):o==="!in"?jp(zg(l[1],l.slice(2))):o==="has"?Ng(l[1]):o==="!has"?jp(Ng(l[1])):o!=="within"||l;var u}function Bg(l,o,u){switch(l){case"$type":return[`filter-type-${u}`,o];case"$id":return[`filter-id-${u}`,o];default:return[`filter-${u}`,l,o]}}function zg(l,o){if(o.length===0)return!1;switch(l){case"$type":return["filter-type-in",["literal",o]];case"$id":return["filter-id-in",["literal",o]];default:return o.length>200&&!o.some(u=>typeof u!=typeof o[0])?["filter-in-large",l,["literal",o.sort(N1)]]:["filter-in-small",l,["literal",o]]}}function Ng(l){switch(l){case"$type":return!0;case"$id":return["filter-has-id"];default:return["filter-has",l]}}function jp(l){return["!",l]}function df(l){return Rg(mo(l.value))?Ho(ta({},l,{expressionContext:"filter",valueSpec:l.styleSpec[`filter_${l.layerType||"fill"}`]})):ff(l)}function ff(l){const o=l.value,u=l.key;if(_r(o)!=="array")return[new vn(u,o,`array expected, ${_r(o)} found`)];const d=l.styleSpec;let p,_=[];if(o.length<1)return[new vn(u,o,"filter array must have at least 1 element")];switch(_=_.concat(zp({key:`${u}[0]`,value:o[0],valueSpec:d.filter_operator,style:l.style,styleSpec:l.styleSpec})),ci(o[0])){case"<":case"<=":case">":case">=":o.length>=2&&ci(o[1])==="$type"&&_.push(new vn(u,o,`"$type" cannot be use with operator "${o[0]}"`));case"==":case"!=":o.length!==3&&_.push(new vn(u,o,`filter array for operator "${o[0]}" must have 3 elements`));case"in":case"!in":o.length>=2&&(p=_r(o[1]),p!=="string"&&_.push(new vn(`${u}[1]`,o[1],`string expected, ${p} found`)));for(let b=2;b<o.length;b++)p=_r(o[b]),ci(o[1])==="$type"?_=_.concat(zp({key:`${u}[${b}]`,value:o[b],valueSpec:d.geometry_type,style:l.style,styleSpec:l.styleSpec})):p!=="string"&&p!=="number"&&p!=="boolean"&&_.push(new vn(`${u}[${b}]`,o[b],`string, number, or boolean expected, ${p} found`));break;case"any":case"all":case"none":for(let b=1;b<o.length;b++)_=_.concat(ff({key:`${u}[${b}]`,value:o[b],style:l.style,styleSpec:l.styleSpec}));break;case"has":case"!has":p=_r(o[1]),o.length!==2?_.push(new vn(u,o,`filter array for "${o[0]}" operator must have 2 elements`)):p!=="string"&&_.push(new vn(`${u}[1]`,o[1],`string expected, ${p} found`));break;case"within":p=_r(o[1]),o.length!==2?_.push(new vn(u,o,`filter array for "${o[0]}" operator must have 2 elements`)):p!=="object"&&_.push(new vn(`${u}[1]`,o[1],`object expected, ${p} found`))}return _}function $g(l,o){const u=l.key,d=l.style,p=l.styleSpec,_=l.value,b=l.objectKey,E=p[`${o}_${l.layerType}`];if(!E)return[];const k=b.match(/^(.*)-transition$/);if(o==="paint"&&k&&E[k[1]]&&E[k[1]].transition)return ga({key:u,value:_,valueSpec:p.transition,style:d,styleSpec:p});const M=l.valueSpec||E[b];if(!M)return[new vn(u,_,`unknown property "${b}"`)];let F;if(_r(_)==="string"&&ma(M)&&!M.tokens&&(F=/^{([^}]+)}$/.exec(_))){const V=`\`{ "type": "identity", "property": ${F?JSON.stringify(F[1]):'"_"'} }\``;return[new vn(u,_,`"${b}" does not support interpolation syntax
120Use an identity property function instead: ${V}.`)]}const $=[];return l.layerType==="symbol"&&(b==="text-field"&&d&&!d.glyphs&&$.push(new vn(u,_,'use of "text-field" requires a style "glyphs" property')),b==="text-font"&&Es(mo(_))&&ci(_.type)==="identity"&&$.push(new vn(u,_,'"text-font" does not support identity functions'))),$.concat(ga({key:l.key,value:_,valueSpec:M,style:d,styleSpec:p,expressionContext:"property",propertyType:o,propertyKey:b}))}function qv(l){return $g(l,"paint")}function jg(l){return $g(l,"layout")}function Wv(l){let o=[];const u=l.value,d=l.key,p=l.style,_=l.styleSpec;u.type||u.ref||o.push(new vn(d,u,'either "type" or "ref" is required'));let b=ci(u.type);const E=ci(u.ref);if(u.id){const k=ci(u.id);for(let M=0;M<l.arrayIndex;M++){const F=p.layers[M];ci(F.id)===k&&o.push(new vn(d,u.id,`duplicate layer id "${u.id}", previously used at line ${F.id.__line__}`))}}if("ref"in u){let k;["type","source","source-layer","filter","layout"].forEach(M=>{M in u&&o.push(new vn(d,u[M],`"${M}" is prohibited for ref layers`))}
120),p.layers.forEach(M=>{ci(M.id)===E&&(k=M)}),k?k.ref?o.push(new vn(d,u.ref,"ref cannot reference another ref layer")):b=ci(k.type):typeof E=="string"&&o.push(new vn(d,u.ref,`ref layer "${E}" not found`))}else if(b!=="background"&&b!=="sky")if(u.source){const k=p.sources&&p.sources[u.source],M=k&&ci(k.type);k?M==="vector"&&b==="raster"?o.push(new vn(d,u.source,`layer "${u.id}" requires a raster source`)):M==="raster"&&b!=="raster"?o.push(new vn(d,u.source,`layer "${u.id}" requires a vector source`)):M!=="vector"||u["source-layer"]?M==="raster-dem"&&b!=="hillshade"?o.push(new vn(d,u.source,"raster-dem source can only be used with layer type 'hillshade'.")):b!=="line"||!u.paint||!u.paint["line-gradient"]&&!u.paint["line-trim-offset"]||M==="geojson"&&k.lineMetrics||o.push(new vn(d,u,`layer "${u.id}" specifies a line-gradient, which requires a GeoJSON source with \`lineMetrics\` enabled.`)):o.push(new vn(d,u,`layer "${u.id}" must specify a "source-layer"`)):o.push(new vn(d,u.source,`source "${u.source}" not found`))}else o.push(new vn(d,u,'missing required property "source"'));return o=o.concat(nl({key:d,value:u,valueSpec:_.layer,style:l.style,styleSpec:l.styleSpec,objectElementValidators:{"*":()=>[],type:()=>ga({key:`${d}.type`,value:u.type,valueSpec:_.layer.type,style:l.style,styleSpec:l.styleSpec,object:u,objectKey:"type"}),filter:k=>df(ta({layerType:b},k)),layout:k=>nl({layer:u,key:k.key,value:k.value,valueSpec:{},style:k.style,styleSpec:k.styleSpec,objectElementValidators:{"*":M=>jg(ta({layerType:b},M))}}),paint:k=>nl({layer:u,key:k.key,value:k.value,valueSpec:{},style:k.style,styleSpec:k.styleSpec,objectElementValidators:{"*":M=>qv(ta({layerType:b},M))}})}})),o}function Gc(l){const o=l.value,u=l.key,d=_r(o);return d!=="string"?[new vn(u,o,`string expected, ${d} found`)]:[]}const Hv={promoteId:function({key:l,value:o}){if(_r(o)==="string")return Gc({key:l,value:o});{const u=[];for(const d in o)u.push(...Gc({key:`${l}.${d}`,value:o[d]}));return u}}};function Yv(l){const o=l.value,u=l.key,d=l.styleSpec,p=l.style;if(!o.type)return[new vn(u,o,'"type" is required')];const _=ci(o.type);let b;switch(_){case"vector":case"raster":case"raster-dem":return b=nl({key:u,value:o,valueSpec:d[`source_${_.replace("-","_")}`],style:l.style,styleSpec:d,objectElementValidators:Hv}),b;case"geojson":if(b=nl({key:u,value:o,valueSpec:d.source_geojson,style:p,styleSpec:d,objectElementValidators:Hv}),o.cluster)for(const E in o.clusterProperties){const[k,M]=o.clusterProperties[E],F=typeof k=="string"?[k,["accumulated"],["get",E]]:k;b.push(...Ho({key:`${u}.${E}.map`,value:M,expressionContext:"cluster-map"})),b.push(...Ho({key:`${u}.${E}.reduce`,value:F,expressionContext:"cluster-reduce"}))}return b;case"video":return nl({key:u,value:o,valueSpec:d.source_video,style:p,styleSpec:d});case"image":return nl({key:u,value:o,valueSpec:d.source_image,style:p,styleSpec:d});case"canvas":return[new vn(u,null,"Please use runtime APIs to add canvas sources, rather than including them in stylesheets.","source.canvas")];default:return zp({key:`${u}.type`,value:o.type,valueSpec:{values:$1(d)},style:p,styleSpec:d})}}function $1(l){return l.source.reduce((o,u)=>{const d=l[u];return d.type.type==="enum"&&(o=o.concat(Object.keys(d.type.values))),o},[])}function Zv(l){const o=l.value,u=l.styleSpec,d=u.light,p=l.style;let _=[];const b=_r(o);if(o===void 0)return _;if(b!=="object")return _=_.concat([new vn("light",o,`object expected, ${b} found`)]),_;for(const E in o){const k=E.match(/^(.*)-transition$/);_=_.concat(k&&d[k[1]]&&d[k[1]].transition?ga({key:E,value:o[E],valueSpec:u.transition,style:p,styleSpec:u}):d[E]?ga({key:E,value:o[E],valueSpec:d[E],style:p,styleSpec:u}):[new vn(E,o[E],`unknown property "${E}"`)])}return _}function Ug(l){const o=l.value,u=l.key,d=l.style,p=l.styleSpec,_=p.terrain;let b=[];const E=_r(o);if(o===void 0)return b;if(E!=="object")return b=b.concat([new vn("terrain",o,`object expected, ${E} found`)]),b;for(const k in o){const M=k.match(/^(.*)-transition$/);b=b.concat(M&&_[M[1]]&&_[M[1]].transition?ga({key:k,value:o[k],valueSpec:p.transition,style:d,styleSpec:p}):_[k]?ga({key:k,value:o[k],valueSpec:_[k],style:d,styleSpec:p}):[new vn(k,o[k],`unknown property "${k}"`)])}if(o.source){const k=d.sources&&d.sources[o.source],M=k&&ci(k.type);k?M!=="raster-dem"&&b.push(new vn(u,o.source,`terrain cannot be used with a source of type ${String(M)}, it only be used with a "raster-dem" source type`)):b.push(new vn(u,o.source,`source "${o.source}" not found`))}else b.push(new vn(u,o,'terrain is missing required property "source"'));return b}function Xv(l){const o=l.value,u=l.style,d=l.styleSpec,p=d.fog;let _=[];const b=_r(o);if(o===void 0)return _;if(b!=="object")return _=_.concat([new vn("fog",o,`object expected, ${b} found`)]),_;
120for(const E in o){const k=E.match(/^(.*)-transition$/);_=_.concat(k&&p[k[1]]&&p[k[1]].transition?ga({key:E,value:o[E],valueSpec:d.transition,style:u,styleSpec:d}):p[E]?ga({key:E,value:o[E],valueSpec:p[E],style:u,styleSpec:d}):[new vn(E,o[E],`unknown property "${E}"`)])}return _}const Kv={"*":()=>[],array:Uv,boolean:function(l){const o=l.value,u=l.key,d=_r(o);return d!=="boolean"?[new vn(u,o,`boolean expected, ${d} found`)]:[]},number:cf,color:function(l){const o=l.key,u=l.value,d=_r(u);return d!=="string"?[new vn(o,u,`color expected, ${d} found`)]:_n(u)===null?[new vn(o,u,`color expected, "${u}" found`)]:[]},enum:zp,filter:df,function:uf,layer:Wv,object:nl,source:Yv,light:Zv,terrain:Ug,fog:Xv,string:Gc,formatted:function(l){return Gc(l).length===0?[]:Ho(l)},resolvedImage:function(l){return Gc(l).length===0?[]:Ho(l)},projection:function(l){const o=l.value,u=l.styleSpec,d=u.projection,p=l.style;let _=[];const b=_r(o);if(b==="object")for(const E in o)_=_.concat(ga({key:E,value:o[E],valueSpec:d[E],style:p,styleSpec:u}));else b!=="string"&&(_=_.concat([new vn("projection",o,`object or string expected, ${b} found`)]));return _}};function ga(l){const o=l.value,u=l.valueSpec,d=l.styleSpec;return u.expression&&Es(ci(o))?uf(l):u.expression&&tl(mo(o))?Ho(l):u.type&&Kv[u.type]?Kv[u.type](l):nl(ta({},l,{valueSpec:u.type?d[u.type]:u}))}function j1(l){const o=l.value,u=l.key,d=Gc(l);return d.length||(o.indexOf("{fontstack}")===-1&&d.push(new vn(u,o,'"glyphs" url must include a "{fontstack}" token')),o.indexOf("{range}")===-1&&d.push(new vn(u,o,'"glyphs" url must include a "{range}" token'))),d}function Qv(l,o=Pt){return Ss(ga({key:"",value:l,valueSpec:o.$root,styleSpec:o,style:l,objectElementValidators:{glyphs:j1,"*":()=>[]}}))}const U1=l=>Ss(qv(l)),V1=l=>Ss(jg(l));function Ss(l){return l.slice().sort((o,u)=>o.line&&u.line?o.line-u.line:0)}function Jv(l,o){let u=!1;if(o&&o.length)for(const d of o)l.fire(new Wo(new Error(d.message))),u=!0;return u}var G1=Il,rl=3;function Il(l,o,u){var d=this.cells=[];if(l instanceof ArrayBuffer){this.arrayBuffer=l;var p=new Int32Array(this.arrayBuffer);l=p[0],this.d=(o=p[1])+2*(u=p[2]);for(var _=0;_<this.d*this.d;_++){var b=p[rl+_],E=p[rl+_+1];d.push(b===E?null:p.subarray(b,E))}var k=p[rl+d.length+1];this.keys=p.subarray(p[rl+d.length],k),this.bboxes=p.subarray(k),this.insert=this._insertReadonly}else{this.d=o+2*u;for(var M=0;M<this.d*this.d;M++)d.push([]);this.keys=[],this.bboxes=[]}this.n=o,this.extent=l,this.padding=u,this.scale=o/l,this.uid=0;var F=u/o*l;this.min=-F,this.max=l+F}Il.prototype.insert=function(l,o,u,d,p){this._forEachCell(o,u,d,p,this._insertCell,this.uid++),this.keys.push(l),this.bboxes.push(o),this.bboxes.push(u),this.bboxes.push(d),this.bboxes.push(p)},Il.prototype._insertReadonly=function(){throw"Cannot insert into a GridIndex created from an ArrayBuffer."},Il.prototype._insertCell=function(l,o,u,d,p,_){this.cells[p].push(_)},Il.prototype.query=function(l,o,u,d,p){var _=this.min,b=this.max;if(l<=_&&o<=_&&b<=u&&b<=d&&!p)return Array.prototype.slice.call(this.keys);var E=[];return this._forEachCell(l,o,u,d,this._queryCell,E,{},p),E},Il.prototype._queryCell=function(l,o,u,d,p,_,b,E){var k=this.cells[p];if(k!==null)for(var M=this.keys,F=this.bboxes,$=0;$<k.length;$++){var V=k[$];if(b[V]===void 0){var X=4*V;(E?E(F[X+0],F[X+1],F[X+2],F[X+3]):l<=F[X+2]&&o<=F[X+3]&&u>=F[X+0]&&d>=F[X+1])?(b[V]=!0,_.push(M[V])):b[V]=!1}}},Il.prototype._forEachCell=function(l,o,u,d,p,_,b,E){for(var k=this._convertToCellCoord(l),M=this._convertToCellCoord(o),F=this._convertToCellCoord(u),$=this._convertToCellCoord(d),V=k;V<=F;V++)for(var X=M;X<=$;X++){var J=this.d*X+V;if((!E||E(this._convertFromCellCoord(V),this._convertFromCellCoord(X),this._convertFromCellCoord(V+1),this._convertFromCellCoord(X+1)))&&p.call(this,l,o,u,d,J,_,b,E))return}},Il.prototype._convertFromCellCoord=function(l){return(l-this.padding)/this.scale},Il.prototype._convertToCellCoord=function(l){return Math.max(0,Math.min(this.d-1,Math.floor(l*this.scale)+this.padding))},Il.prototype.toArrayBuffer=function(){if(this.arrayBuffer)return this.arrayBuffer;for(var l=this.cells,o=rl+this.cells.length+1+1,u=0,d=0;d<this.cells.length;d++)u+=this.cells[d].length;var p=new Int32Array(o+u+this.keys.length+this.bboxes.length);p[0]=this.extent,p[1]=this.n,p[2]=this.padding;
120for(var _=o,b=0;b<l.length;b++){var E=l[b];p[rl+b]=_,p.set(E,_),_+=E.length}return p[rl+l.length]=_,p.set(this.keys,_),p[rl+l.length+1]=_+=this.keys.length,p.set(this.bboxes,_),_+=this.bboxes.length,p.buffer};var Du=j(G1);const Up={};function xn(l,o,u={}){Object.defineProperty(l,"_classRegistryKey",{value:o,writeable:!1}),Up[o]={klass:l,omit:u.omit||[]}}xn(Object,"Object"),Du.serialize=function(l,o){const u=l.toArrayBuffer();return o&&o.push(u),{buffer:u}},Du.deserialize=function(l){return new Du(l.buffer)},Object.defineProperty(Du,"name",{value:"Grid"}),xn(Du,"Grid"),xn(Rt,"Color"),xn(Error,"Error"),xn(Bo,"AJAXError"),xn(zr,"ResolvedImage"),xn(Fp,"StylePropertyFunction"),xn(lc,"StyleExpression",{omit:["_evaluator"]}),xn(sf,"ZoomDependentExpression"),xn(Lg,"ZoomConstantExpression"),xn(Hs,"CompoundExpression",{omit:["_evaluate"]});for(const l in Ga)Up[Ga[l]._classRegistryKey]||xn(Ga[l],`Expression${l}`);function Vg(l){return l&&typeof ArrayBuffer<"u"&&(l instanceof ArrayBuffer||l.constructor&&l.constructor.name==="ArrayBuffer")}function Gg(l){return m.ImageBitmap&&l instanceof m.ImageBitmap}function kh(l,o){if(l==null||typeof l=="boolean"||typeof l=="number"||typeof l=="string"||l instanceof Boolean||l instanceof Number||l instanceof String||l instanceof Date||l instanceof RegExp)return l;if(Vg(l)||Gg(l))return o&&o.push(l),l;if(ArrayBuffer.isView(l)){const u=l;return o&&o.push(u.buffer),u}if(l instanceof m.ImageData)return o&&o.push(l.data.buffer),l;if(Array.isArray(l)){const u=[];for(const d of l)u.push(kh(d,o));return u}if(typeof l=="object"){const u=l.constructor,d=u._classRegistryKey;if(!d)throw new Error(`can't serialize object of unregistered class ${d}`);const p=u.serialize?u.serialize(l,o):{};if(!u.serialize){for(const _ in l)l.hasOwnProperty(_)&&(Up[d].omit.indexOf(_)>=0||(p[_]=kh(l[_],o)));l instanceof Error&&(p.message=l.message)}if(p.$name)throw new Error("$name property is reserved for worker serialization logic.");return d!=="Object"&&(p.$name=d),p}throw new Error("can't serialize object of type "+typeof l)}function Lu(l){if(l==null||typeof l=="boolean"||typeof l=="number"||typeof l=="string"||l instanceof Boolean||l instanceof Number||l instanceof String||l instanceof Date||l instanceof RegExp||Vg(l)||Gg(l)||ArrayBuffer.isView(l)||l instanceof m.ImageData)return l;if(Array.isArray(l))return l.map(Lu);if(typeof l=="object"){const o=l.$name||"Object",{klass:u}=Up[o];if(!u)throw new Error(`can't deserialize unregistered class ${o}`);if(u.deserialize)return u.deserialize(l);const d=Object.create(u.prototype);for(const p of Object.keys(l))p!=="$name"&&(d[p]=Lu(l[p]));return d}throw new Error("can't deserialize object of type "+typeof l)}const mn={"Latin-1 Supplement":l=>l>=128&&l<=255,Arabic:l=>l>=1536&&l<=1791,"Arabic Supplement":l=>l>=1872&&l<=1919,"Arabic Extended-A":l=>l>=2208&&l<=2303,"Hangul Jamo":l=>l>=4352&&l<=4607,"Unified Canadian Aboriginal Syllabics":l=>l>=5120&&l<=5759,Khmer:l=>l>=6016&&l<=6143,"Unified Canadian Aboriginal Syllabics Extended":l=>l>=6320&&l<=6399,"General Punctuation":l=>l>=8192&&l<=8303,"Letterlike Symbols":l=>l>=8448&&l<=8527,"Number Forms":l=>l>=8528&&l<=8591,"Miscellaneous Technical":l=>l>=8960&&l<=9215,"Control Pictures":l=>l>=9216&&l<=9279,"Optical Character Recognition":l=>l>=9280&&l<=9311,"Enclosed Alphanumerics":l=>l>=9312&&l<=9471,"Geometric Shapes":l=>l>=9632&&l<=9727,"Miscellaneous Symbols":l=>l>=9728&&l<=9983,"Miscellaneous Symbols and Arrows":l=>l>=11008&&l<=11263,"CJK Radicals Supplement":l=>l>=11904&&l<=12031,"Kangxi Radicals":l=>l>=12032&&l<=12255,"Ideographic Description Characters":l=>l>=12272&&l<=12287,"CJK Symbols and Punctuation":l=>l>=12288&&l<=12351,Hiragana:l=>l>=12352&&l<=12447,Katakana:l=>l>=12448&&l<=12543,Bopomofo:l=>l>=12544&&l<=12591,"Hangul Compatibility Jamo":l=>l>=12592&&l<=12687,Kanbun:l=>l>=12688&&l<=12703,"Bopomofo Extended":l=>l>=12704&&l<=12735,"CJK Strokes":l=>l>=12736&&l<=12783,"Katakana Phonetic Extensions":l=>l>=12784&&l<=12799,"Enclosed CJK Letters and Months":l=>l>=12800&&l<=13055,"CJK Compatibility":l=>l>=13056&&l<=13311,"CJK Unified Ideographs Extension A":l=>l>=13312&&l<=19903,"Yijing Hexagram Symbols":l=>l>=19904&&l<=19967,"CJK Unified Ideographs":l=>l>=19968&&l<=40959,"Yi Syllables":l=>l>=40960&&l<=42127,"Yi Radicals":l=>l>=42128&&l<=42191,"Hangul Jamo Extended-A":l=>l>=43360&&l<=43391,"Hangul Syllables":l=>l>=44032&&l<=55215,"Hangul Jamo Extended-B":l=>l>=55216&&l<=55295,"Private Use Area":l=>l>=57344&&l<=63743,"CJK Compatibility Ideographs":l=>l>=63744&&l<=64255,"Arabic Presentation Forms-A":l=>l>=64336&&l<=65023,"Vertical Forms":l=>l>=65040&&l<=65055,"CJK Compatibility Forms":l=>l>=65072&&l<=65103,"Small Form Variants":l=>l>=65104&&l<=65135,"Arabic Presentation Forms-B":l=>l>=65136&&l<=65279,"Halfwidth and Fullwidth Forms":l=>l>=65280&&l<=65519};
120function qg(l){for(const o of l)if(Wg(o.charCodeAt(0)))return!0;return!1}function q1(l){for(const o of l)if(!e0(o.charCodeAt(0)))return!1;return!0}function e0(l){return!(mn.Arabic(l)||mn["Arabic Supplement"](l)||mn["Arabic Extended-A"](l)||mn["Arabic Presentation Forms-A"](l)||mn["Arabic Presentation Forms-B"](l))}function Wg(l){return!(l!==746&&l!==747&&(l<4352||!(mn["Bopomofo Extended"](l)||mn.Bopomofo(l)||mn["CJK Compatibility Forms"](l)&&!(l>=65097&&l<=65103)||mn["CJK Compatibility Ideographs"](l)||mn["CJK Compatibility"](l)||mn["CJK Radicals Supplement"](l)||mn["CJK Strokes"](l)||!(!mn["CJK Symbols and Punctuation"](l)||l>=12296&&l<=12305||l>=12308&&l<=12319||l===12336)||mn["CJK Unified Ideographs Extension A"](l)||mn["CJK Unified Ideographs"](l)||mn["Enclosed CJK Letters and Months"](l)||mn["Hangul Compatibility Jamo"](l)||mn["Hangul Jamo Extended-A"](l)||mn["Hangul Jamo Extended-B"](l)||mn["Hangul Jamo"](l)||mn["Hangul Syllables"](l)||mn.Hiragana(l)||mn["Ideographic Description Characters"](l)||mn.Kanbun(l)||mn["Kangxi Radicals"](l)||mn["Katakana Phonetic Extensions"](l)||mn.Katakana(l)&&l!==12540||!(!mn["Halfwidth and Fullwidth Forms"](l)||l===65288||l===65289||l===65293||l>=65306&&l<=65310||l===65339||l===65341||l===65343||l>=65371&&l<=65503||l===65507||l>=65512&&l<=65519)||!(!mn["Small Form Variants"](l)||l>=65112&&l<=65118||l>=65123&&l<=65126)||mn["Unified Canadian Aboriginal Syllabics"](l)||mn["Unified Canadian Aboriginal Syllabics Extended"](l)||mn["Vertical Forms"](l)||mn["Yijing Hexagram Symbols"](l)||mn["Yi Syllables"](l)||mn["Yi Radicals"](l))))}function t0(l){return!(Wg(l)||function(o){return!!(mn["Latin-1 Supplement"](o)&&(o===167||o===169||o===174||o===177||o===188||o===189||o===190||o===215||o===247)||mn["General Punctuation"](o)&&(o===8214||o===8224||o===8225||o===8240||o===8241||o===8251||o===8252||o===8258||o===8263||o===8264||o===8265||o===8273)||mn["Letterlike Symbols"](o)||mn["Number Forms"](o)||mn["Miscellaneous Technical"](o)&&(o>=8960&&o<=8967||o>=8972&&o<=8991||o>=8996&&o<=9e3||o===9003||o>=9085&&o<=9114||o>=9150&&o<=9165||o===9167||o>=9169&&o<=9179||o>=9186&&o<=9215)||mn["Control Pictures"](o)&&o!==9251||mn["Optical Character Recognition"](o)||mn["Enclosed Alphanumerics"](o)||mn["Geometric Shapes"](o)||mn["Miscellaneous Symbols"](o)&&!(o>=9754&&o<=9759)||mn["Miscellaneous Symbols and Arrows"](o)&&(o>=11026&&o<=11055||o>=11088&&o<=11097||o>=11192&&o<=11243)||mn["CJK Symbols and Punctuation"](o)||mn.Katakana(o)||mn["Private Use Area"](o)||mn["CJK Compatibility Forms"](o)||mn["Small Form Variants"](o)||mn["Halfwidth and Fullwidth Forms"](o)||o===8734||o===8756||o===8757||o>=9984&&o<=10087||o>=10102&&o<=10131||o===65532||o===65533)}(l))}function n0(l){return l>=1424&&l<=2303||mn["Arabic Presentation Forms-A"](l)||mn["Arabic Presentation Forms-B"](l)}function W1(l,o){return!(!o&&n0(l)||l>=2304&&l<=3583||l>=3840&&l<=4255||mn.Khmer(l))}function H1(l){for(const o of l)if(n0(o.charCodeAt(0)))return!0;return!1}const Hg="deferred",Yg="loading",Zg="loaded";let Ah=null,y="unavailable",h=null;const f=function(l){l&&typeof l=="string"&&l.indexOf("NetworkError")>-1&&(y="error"),Ah&&Ah(l)};function v(){w.fire(new vl("pluginStateChange",{pluginStatus:y,pluginURL:h}))}const w=new fa,S=function(){return y},I=function(){if(y!==Hg||!h)throw new Error("rtl-text-plugin cannot be downloaded unless a pluginURL is specified");y=Yg,v(),h&&Ao({url:h},l=>{l?f(l):(y=Zg,v())})},L={applyArabicShaping:null,processBidirectionalText:null,processStyledBidirectionalText:null,isLoaded:()=>y===Zg||L.applyArabicShaping!=null,isLoading:()=>y===Yg,setState(l){y=l.pluginStatus,h=l.pluginURL},isParsed:()=>L.applyArabicShaping!=null&&L.processBidirectionalText!=null&&L.processStyledBidirectionalText!=null,getPluginURL:()=>h};class z{constructor(o,u){this.zoom=o,u?(this.now=u.now,this.fadeDuration=u.fadeDuration,this.transition=u.transition,this.pitch=u.pitch):(this.now=0,this.fadeDuration=0,this.transition={},this.pitch=0)}isSupportedScript(o){return function(u,d){for(const p of u)if(!W1(p.charCodeAt(0),d))return!1;return!0}(o,L.isLoaded())}}class H{constructor(o,u){this.property=o,this.value=u,this.expression=function(d,p){
120if(Es(d))return new Fp(d,p);if(tl(d)){const _=lf(d,p);if(_.result==="error")throw new Error(_.value.map(b=>`${b.key}: ${b.message}`).join(", "));return _.value}{let _=d;return typeof d=="string"&&p.type==="color"&&(_=Rt.parse(d)),{kind:"constant",evaluate:()=>_}}}(u===void 0?o.specification.default:u,o.specification)}isDataDriven(){return this.expression.kind==="source"||this.expression.kind==="composite"}possiblyEvaluate(o,u,d){return this.property.possiblyEvaluate(this,o,u,d)}}class q{constructor(o){this.property=o,this.value=new H(o,void 0)}transitioned(o,u){return new de(this.property,this.value,u,xt({},o.transition,this.transition),o.now)}untransitioned(){return new de(this.property,this.value,null,{},0)}}class ee{constructor(o){this._properties=o,this._values=Object.create(o.defaultTransitionablePropertyValues)}getValue(o){return we(this._values[o].value.value)}setValue(o,u){this._values.hasOwnProperty(o)||(this._values[o]=new q(this._values[o].property)),this._values[o].value=new H(this._values[o].property,u===null?void 0:we(u))}getTransition(o){return we(this._values[o].transition)}setTransition(o,u){this._values.hasOwnProperty(o)||(this._values[o]=new q(this._values[o].property)),this._values[o].transition=we(u)||void 0}serialize(){const o={};for(const u of Object.keys(this._values)){const d=this.getValue(u);d!==void 0&&(o[u]=d);const p=this.getTransition(u);p!==void 0&&(o[`${u}-transition`]=p)}return o}transitioned(o,u){const d=new _e(this._properties);for(const p of Object.keys(this._values))d._values[p]=this._values[p].transitioned(o,u._values[p]);return d}untransitioned(){const o=new _e(this._properties);for(const u of Object.keys(this._values))o._values[u]=this._values[u].untransitioned();return o}}class de{constructor(o,u,d,p,_){const b=p.delay||0,E=p.duration||0;_=_||0,this.property=o,this.value=u,this.begin=_+b,this.end=this.begin+E,o.specification.transition&&(p.delay||p.duration)&&(this.prior=d)}possiblyEvaluate(o,u,d){const p=o.now||0,_=this.value.possiblyEvaluate(o,u,d),b=this.prior;if(b){if(p>this.end)return this.prior=null,_;if(this.value.isDataDriven())return this.prior=null,_;if(p<this.begin)return b.possiblyEvaluate(o,u,d);{const E=(p-this.begin)/(this.end-this.begin);return this.property.interpolate(b.possiblyEvaluate(o,u,d),_,xe(E))}}return _}}class _e{constructor(o){this._properties=o,this._values=Object.create(o.defaultTransitioningPropertyValues)}possiblyEvaluate(o,u,d){const p=new Ee(this._properties);for(const _ of Object.keys(this._values))p._values[_]=this._values[_].possiblyEvaluate(o,u,d);return p}hasTransition(){for(const o of Object.keys(this._values))if(this._values[o].prior)return!0;return!1}}class be{constructor(o){this._properties=o,this._values=Object.create(o.defaultPropertyValues)}getValue(o){return we(this._values[o].value)}setValue(o,u){this._values[o]=new H(this._values[o].property,u===null?void 0:we(u))}serialize(){const o={};for(const u of Object.keys(this._values)){const d=this.getValue(u);d!==void 0&&(o[u]=d)}return o}possiblyEvaluate(o,u,d){const p=new Ee(this._properties);for(const _ of Object.keys(this._values))p._values[_]=this._values[_].possiblyEvaluate(o,u,d);return p}}class ve{constructor(o,u,d){this.property=o,this.value=u,this.parameters=d}isConstant(){return this.value.kind==="constant"}constantOr(o){return this.value.kind==="constant"?this.value.value:o}evaluate(o,u,d,p){return this.property.evaluate(this.value,this.parameters,o,u,d,p)}}class Ee{constructor(o){this._properties=o,this._values=Object.create(o.defaultPossiblyEvaluatedValues)}get(o){return this._values[o]}}class te{constructor(o){this.specification=o}possiblyEvaluate(o,u){return o.expression.evaluate(u)}interpolate(o,u,d){const p=Pa[this.specification.type];return p?p(o,u,d):o}}class ye{constructor(o,u){this.specification=o,this.overrides=u}possiblyEvaluate(o,u,d,p){return new ve(this,o.expression.kind==="constant"||o.expression.kind==="camera"?{kind:"constant",value:o.expression.evaluate(u,null,{},d,p)}:o.expression,u)}interpolate(o,u,d){if(o.value.kind!=="constant"||u.value.kind!=="constant")return o;if(o.value.value===void 0||u.value.value===void 0)return new ve(this,{kind:"constant",value:void 0},o.parameters);const p=Pa[this.specification.type];return p?new ve(this,{kind:"constant",value:p(o.value.value,u.value.value,d)},o.parameters):o}evaluate(o,u,d,p,_,b){return o.kind==="constant"?o.value:o.evaluate(u,d,p,_,b)}}class Oe{constructor(o){this.specification=o}possiblyEvaluate(o,u,d,p){return!!o.expression.evaluate(u,null,{},d,p)}interpolate(){return!1}}class Le{constructor(o){this.properties=o,this.defaultPropertyValues={},this.defaultTransitionablePropertyValues={},this.defaultTransitioningPropertyValues={},this.defaultPossiblyEvaluatedValues={},this.overridableProperties=[];const u=new z(0,{});for(const d in o){const p=o[d];p.specification.overridable&&this.overridableProperties.push(d);const _=this.defaultPropertyValues[d]=new H(p,void 0),b=this.defaultTransitionablePropertyValues[d]=new q(p);this.defaultTransitioningPropertyValues[d]=b.untransitioned(),this.defaultPossiblyEvaluatedValues[d]=_.possiblyEvaluate(u)}}}function He(l,o){return 256*(l=ne(Math.floor(l),0,255))+ne(Math.floor(o),0,255)}xn(ye,"DataDrivenProperty"),xn(te,"DataConstantProperty"),xn(Oe,"ColorRampProperty");const Ze={Int8:Int8Array,Uint8:Uint8Array,Int16:Int16Array,Uint16:Uint16Array,Int32:Int32Array,Uint32:Uint32Array,Float32:Float32Array};class Ye{constructor(o,u){this._structArray=o,this._pos1=u*this.size,this._pos2=this._pos1/2,this._pos4=this._pos1/4,this._pos8=this._pos1/8}}
vendor: 20,266 bytes, line 120
120class ot{constructor(){this.isTransferred=!1,this.capacity=-1,this.resize(0)}static serialize(o,u){return o._trim(),u&&(o.isTransferred=!0,u.push(o.arrayBuffer)),{length:o.length,arrayBuffer:o.arrayBuffer}}static deserialize(o){const u=Object.create(this.prototype);return u.arrayBuffer=o.arrayBuffer,u.length=o.length,u.capacity=o.arrayBuffer.byteLength/u.bytesPerElement,u._refreshViews(),u}_trim(){this.length!==this.capacity&&(this.capacity=this.length,this.arrayBuffer=this.arrayBuffer.slice(0,this.length*this.bytesPerElement),this._refreshViews())}clear(){this.length=0}resize(o){this.reserve(o),this.length=o}reserve(o){if(o>this.capacity){this.capacity=Math.max(o,Math.floor(5*this.capacity),128),this.arrayBuffer=new ArrayBuffer(this.capacity*this.bytesPerElement);const u=this.uint8;this._refreshViews(),u&&this.uint8.set(u)}}_refreshViews(){throw new Error("_refreshViews() must be implemented by each concrete StructArray layout")}destroy(){this.int8=this.uint8=this.int16=this.uint16=this.int32=this.uint32=this.float32=null,this.arrayBuffer=null}}function et(l,o=1){let u=0,d=0;return{members:l.map(p=>{const _=Ze[p.type].BYTES_PER_ELEMENT,b=u=_t(u,Math.max(o,_)),E=p.components||1;return d=Math.max(d,_),u+=_*E,{name:p.name,type:p.type,components:E,offset:b}}),size:_t(u,Math.max(d,o)),alignment:o}}function _t(l,o){return Math.ceil(l/o)*o}class Zt extends ot{_refreshViews(){this.uint8=new Uint8Array(this.arrayBuffer),this.int16=new Int16Array(this.arrayBuffer)}emplaceBack(o,u){const d=this.length;return this.resize(d+1),this.emplace(d,o,u)}emplace(o,u,d){const p=2*o;return this.int16[p+0]=u,this.int16[p+1]=d,o}}Zt.prototype.bytesPerElement=4,xn(Zt,"StructArrayLayout2i4");class dt extends ot{_refreshViews(){this.uint8=new Uint8Array(this.arrayBuffer),this.int16=new Int16Array(this.arrayBuffer)}emplaceBack(o,u,d){const p=this.length;return this.resize(p+1),this.emplace(p,o,u,d)}emplace(o,u,d,p){const _=3*o;return this.int16[_+0]=u,this.int16[_+1]=d,this.int16[_+2]=p,o}}dt.prototype.bytesPerElement=6,xn(dt,"StructArrayLayout3i6");class Bt extends ot{_refreshViews(){this.uint8=new Uint8Array(this.arrayBuffer),this.int16=new Int16Array(this.arrayBuffer)}emplaceBack(o,u,d,p){const _=this.length;return this.resize(_+1),this.emplace(_,o,u,d,p)}emplace(o,u,d,p,_){const b=4*o;return this.int16[b+0]=u,this.int16[b+1]=d,this.int16[b+2]=p,this.int16[b+3]=_,o}}Bt.prototype.bytesPerElement=8,xn(Bt,"StructArrayLayout4i8");class St extends ot{_refreshViews(){this.uint8=new Uint8Array(this.arrayBuffer),this.int16=new Int16Array(this.arrayBuffer),this.float32=new Float32Array(this.arrayBuffer)}emplaceBack(o,u,d,p,_,b,E){const k=this.length;return this.resize(k+1),this.emplace(k,o,u,d,p,_,b,E)}emplace(o,u,d,p,_,b,E,k){const M=6*o,F=12*o,$=3*o;return this.int16[M+0]=u,this.int16[M+1]=d,this.uint8[F+4]=p,this.uint8[F+5]=_,this.uint8[F+6]=b,this.uint8[F+7]=E,this.float32[$+2]=k,o}}St.prototype.bytesPerElement=12,xn(St,"StructArrayLayout2i4ub1f12");class Yt extends ot{_refreshViews(){this.uint8=new Uint8Array(this.arrayBuffer),this.float32=new Float32Array(this.arrayBuffer)}emplaceBack(o,u,d,p){const _=this.length;return this.resize(_+1),this.emplace(_,o,u,d,p)}emplace(o,u,d,p,_){const b=4*o;return this.float32[b+0]=u,this.float32[b+1]=d,this.float32[b+2]=p,this.float32[b+3]=_,o}}Yt.prototype.bytesPerElement=16,xn(Yt,"StructArrayLayout4f16");class gt extends ot{_refreshViews(){this.uint8=new Uint8Array(this.arrayBuffer),this.uint16=new Uint16Array(this.arrayBuffer),this.float32=new Float32Array(this.arrayBuffer)}emplaceBack(o,u,d,p,_){const b=this.length;return this.resize(b+1),this.emplace(b,o,u,d,p,_)}emplace(o,u,d,p,_,b){const E=6*o,k=3*o;return this.uint16[E+0]=u,this.uint16[E+1]=d,this.uint16[E+2]=p,this.uint16[E+3]=_,this.float32[k+2]=b,o}}gt.prototype.bytesPerElement=12,xn(gt,"StructArrayLayout4ui1f12");class Ft extends ot{_refreshViews(){this.uint8=new Uint8Array(this.arrayBuffer),this.uint16=new Uint16Array(this.arrayBuffer)}emplaceBack(o,u,d,p){const _=this.length;return this.resize(_+1),this.emplace(_,o,u,d,p)}emplace(o,u,d,p,_){const b=4*o;return this.uint16[b+0]=u,this.uint16[b+1]=d,this.uint16[b+2]=p,this.uint16[b+3]=_,o}}Ft.prototype.bytesPerElement=8,xn(Ft,"StructArrayLayout4ui8");class Jt extends ot{_refreshViews(){this.uint8=new Uint8Array(this.arrayBuffer),this.int16=new Int16Array(this.arrayBuffer)}emplaceBack(o,u,d,p,_,b){const E=this.length;return this.resize(E+1),this.emplace(E,o,u,d,p,_,b)}emplace(o,u,d,p,_,b,E){const k=6*o;return this.int16[k+0]=u,this.int16[k+1]=d,this.int16[k+2]=p,this.int16[k+3]=_,this.int16[k+4]=b,this.int16[k+5]=E,o}}Jt.prototype.bytesPerElement=12,xn(Jt,"StructArrayLayout6i12");class Ut extends ot{_refreshViews(){this.uint8=new Uint8Array(this.arrayBuffer),this.int16=new Int16Array(this.arrayBuffer),this.uint16=new Uint16Array(this.arrayBuffer)}emplaceBack(o,u,d,p,_,b,E,k,M,F,$,V){const X=this.length;return this.resize(X+1),this.emplace(X,o,u,d,p,_,b,E,k,M,F,$,V)}emplace(o,u,d,p,_,b,E,k,M,F,$,V,X){const J=12*o;return this.int16[J+0]=u,this.int16[J+1]=d,this.int16[J+2]=p,this.int16[J+3]=_,this.uint16[J+4]=b,this.uint16[J+5]=E,this.uint16[J+6]=k,this.uint16[J+7]=M,this.int16[J+8]=F,this.int16[J+9]=$,this.int16[J+10]=V,this.int16[J+11]=X,o}}Ut.prototype.bytesPerElement=24,xn(Ut,"StructArrayLayout4i4ui4i24");class tn extends ot{_refreshViews(){this.uint8=new Uint8Array(this.arrayBuffer),this.int16=new Int16Array(this.arrayBuffer),this.float32=new Float32Array(this.arrayBuffer)}emplaceBack(o,u,d,p,_,b){const E=this.length;return this.resize(E+1),this.emplace(E,o,u,d,p,_,b)}emplace(o,u,d,p,_,b,E){const k=10*o,M=5*o;return this.int16[k+0]=u,this.int16[k+1]=d,this.int16[k+2]=p,this.float32[M+2]=_,this.float32[M+3]=b,this.float32[M+4]=E,o}}tn.prototype.bytesPerElement=20,xn(tn,"StructArrayLayout3i3f20");class Mn extends ot{_refreshViews(){this.uint8=new Uint8Array(this.arrayBuffer),this.uint32=new Uint32Array(this.arrayBuffer)}emplaceBack(o){const u=this.length;return this.resize(u+1),this.emplace(u,o)}emplace(o,u){return this.uint32[1*o+0]=u,o}}Mn.prototype.bytesPerElement=4,xn(Mn,"StructArrayLayout1ul4");class Wn extends ot{_refreshViews(){this.uint8=new Uint8Array(this.arrayBuffer),this.int16=new Int16Array(this.arrayBuffer),this.float32=new Float32Array(this.arrayBuffer),this.uint32=new Uint32Array(this.arrayBuffer),this.uint16=new Uint16Array(this.arrayBuffer)}emplaceBack(o,u,d,p,_,b,E,k,M,F,$,V,X){const J=this.length;return this.resize(J+1),this.emplace(J,o,u,d,p,_,b,E,k,M,F,$,V,X)}emplace(o,u,d,p,_,b,E,k,M,F,$,V,X,J){const re=20*o,pe=10*o;return this.int16[re+0]=u,this.int16[re+1]=d,this.int16[re+2]=p,this.int16[re+3]=_,this.int16[re+4]=b,this.float32[pe+3]=E,this.float32[pe+4]=k,this.float32[pe+5]=M,this.float32[pe+6]=F,this.int16[re+14]=$,this.uint32[pe+8]=V,this.uint16[re+18]=X,this.uint16[re+19]=J,o}}Wn.prototype.bytesPerElement=40,xn(Wn,"StructArrayLayout5i4f1i1ul2ui40");class wn extends ot{_refreshViews(){this.uint8=new Uint8Array(this.arrayBuffer),this.int16=new Int16Array(this.arrayBuffer)}emplaceBack(o,u,d,p,_,b,E){const k=this.length;return this.resize(k+1),this.emplace(k,o,u,d,p,_,b,E)}emplace(o,u,d,p,_,b,E,k){const M=8*o;return this.int16[M+0]=u,this.int16[M+1]=d,this.int16[M+2]=p,this.int16[M+4]=_,this.int16[M+5]=b,this.int16[M+6]=E,this.int16[M+7]=k,o}}wn.prototype.bytesPerElement=16,xn(wn,"StructArrayLayout3i2i2i16");class Bn extends ot{_refreshViews(){this.uint8=new Uint8Array(this.arrayBuffer),this.float32=new Float32Array(this.arrayBuffer),this.int16=new Int16Array(this.arrayBuffer)}emplaceBack(o,u,d,p,_){const b=this.length;return this.resize(b+1),this.emplace(b,o,u,d,p,_)}emplace(o,u,d,p,_,b){const E=4*o,k=8*o;return this.float32[E+0]=u,this.float32[E+1]=d,this.float32[E+2]=p,this.int16[k+6]=_,this.int16[k+7]=b,o}}Bn.prototype.bytesPerElement=16,xn(Bn,"StructArrayLayout2f1f2i16");class mr extends ot{_refreshViews(){this.uint8=new Uint8Array(this.arrayBuffer),this.float32=new Float32Array(this.arrayBuffer)}emplaceBack(o,u,d,p){const _=this.length;return this.resize(_+1),this.emplace(_,o,u,d,p)}emplace(o,u,d,p,_){const b=12*o,E=3*o;return this.uint8[b+0]=u,this.uint8[b+1]=d,this.float32[E+1]=p,this.float32[E+2]=_,o}}mr.prototype.bytesPerElement=12,xn(mr,"StructArrayLayout2ub2f12");class pr extends ot{_refreshViews(){this.uint8=new Uint8Array(this.arrayBuffer),this.float32=new Float32Array(this.arrayBuffer)}emplaceBack(o,u,d){const p=this.length;return this.resize(p+1),this.emplace(p,o,u,d)}emplace(o,u,d,p){const _=3*o;return this.float32[_+0]=u,this.float32[_+1]=d,this.float32[_+2]=p,o}}pr.prototype.bytesPerElement=12,xn(pr,"StructArrayLayout3f12");class Cn extends ot{_refreshViews(){this.uint8=new Uint8Array(this.arrayBuffer),this.uint16=new Uint16Array(this.arrayBuffer)}emplaceBack(o,u,d){const p=this.length;return this.resize(p+1),this.emplace(p,o,u,d)}emplace(o,u,d,p){const _=3*o;return this.uint16[_+0]=u,this.uint16[_+1]=d,this.uint16[_+2]=p,o}}Cn.prototype.bytesPerElement=6,xn(Cn,"StructArrayLayout3ui6");class Nr extends ot{_refreshViews(){this.uint8=new Uint8Array(this.arrayBuffer),this.int16=new Int16Array(this.arrayBuffer),this.float32=new Float32Array(this.arrayBuffer),this.uint16=new Uint16Array(this.arrayBuffer),this.uint32=new Uint32Array(this.arrayBuffer)}emplaceBack(o,u,d,p,_,b,E,k,M,F,$,V,X,J,re,pe,Ce,ze,ke,Be,We){const Ge=this.length;return this.resize(Ge+1),this.emplace(Ge,o,u,d,p,_,b,E,k,M,F,$,V,X,J,re,pe,Ce,ze,ke,Be,We)}emplace(o,u,d,p,_,b,E,k,M,F,$,V,X,J,re,pe,Ce,ze,ke,Be,We,Ge){const vt=30*o,ft=15*o,Dt=60*o;return this.int16[vt+0]=u,this.int16[vt+1]=d,this.int16[vt+2]=p,this.float32[ft+2]=_,this.float32[ft+3]=b,this.uint16[vt+8]=E,this.uint16[vt+9]=k,this.uint32[ft+5]=M,this.uint32[ft+6]=F,this.uint32[ft+7]=$,this.uint16[vt+16]=V,this.uint16[vt+17]=X,this.uint16[vt+18]=J,this.float32[ft+10]=re,this.float32[ft+11]=pe,this.uint8[Dt+48]=Ce,this.uint8[Dt+49]=ze,this.uint8[Dt+50]=ke,this.uint32[ft+13]=Be,this.int16[vt+28]=We,this.uint8[Dt+58]=Ge,o}}Nr.prototype.bytesPerElement=60,xn(Nr,"StructArrayLayout3i2f2ui3ul3ui2f3ub1ul1i1ub60");class Qr extends ot{_refreshViews(){this.uint8=new Uint8Array(this.arrayBuffer),this.int16=new Int16Array(this.arrayBuffer),this.float32=new Float32Array(this.arrayBuffer),this.uint16=new Uint16Array(this.arrayBuffer),this.uint32=new Uint32Array(this.arrayBuffer)}emplaceBack(o,u,d,p,_,b,E,k,M,F,$,V,X,J,re,pe,Ce,ze,ke,Be,We,Ge,vt,ft,Dt,Xt,Ct,zt,Nt,Gt){const nn=this.length;return this.resize(nn+1),this.emplace(nn,o,u,d,p,_,b,E,k,M,F,$,V,X,J,re,pe,Ce,ze,ke,Be,We,Ge,vt,ft,Dt,Xt,Ct,zt,Nt,Gt)}emplace(o,u,d,p,_,b,E,k,M,F,$,V,X,J,re,pe,Ce,ze,ke,Be,We,Ge,vt,ft,Dt,Xt,Ct,zt,Nt,Gt,nn){const Mt=38*o,un=19*o;return this.int16[Mt+0]=u,this.int16[Mt+1]=d,this.int16[Mt+2]=p,this.float32[un+2]=_,this.float32[un+3]=b,this.int16[Mt+8]=E,this.int16[Mt+9]=k,this.int16[Mt+10]=M,this.int16[Mt+11]=F,this.int16[Mt+12]=$,this.int16[Mt+13]=V,this.uint16[Mt+14]=X,this.uint16[Mt+15]=J,this.uint16[Mt+16]=re,this.uint16[Mt+17]=pe,this.uint16[Mt+18]=Ce,this.uint16[Mt+19]=ze,this.uint16[Mt+20]=ke,this.uint16[Mt+21]=Be,this.uint16[Mt+22]=We,this.uint16[Mt+23]=Ge,this.uint16[Mt+24]=vt,this.uint16[Mt+25]=ft,this.uint16[Mt+26]=Dt,this.uint16[Mt+27]=Xt,this.uint16[Mt+28]=Ct,this.uint32[un+15]=zt,this.float32[un+16]=Nt,this.float32[un+17]=Gt,this.float32[un+18]=nn,o}}Qr.prototype.bytesPerElement=76,xn(Qr,"StructArrayLayout3i2f6i15ui1ul3f76");class Jr extends ot{_refreshViews(){this.uint8=new Uint8Array(this.arrayBuffer),this.float32=new Float32Array(this.arrayBuffer)}emplaceBack(o){const u=this.length;return this.resize(u+1),this.emplace(u,o)}emplace(o,u){return this.float32[1*o+0]=u,o}}Jr.prototype.bytesPerElement=4,xn(Jr,"StructArrayLayout1f4");class ei extends ot{_refreshViews(){this.uint8=new Uint8Array(this.arrayBuffer),this.float32=new Float32Array(this.arrayBuffer)}emplaceBack(o,u,d,p,_){const b=this.length;return this.resize(b+1),this.emplace(b,o,u,d,p,_)}emplace(o,u,d,p,_,b){const E=5*o;return this.float32[E+0]=u,this.float32[E+1]=d,this.float32[E+2]=p,this.float32[E+3]=_,this.float32[E+4]=b,o}}ei.prototype.bytesPerElement=20,xn(ei,"StructArrayLayout5f20");class ya extends ot{_refreshViews(){this.uint8=new Uint8Array(this.arrayBuffer),this.uint32=new Uint32Array(this.arrayBuffer),this.uint16=new Uint16Array(this.arrayBuffer)}emplaceBack(o,u,d,p){const _=this.length;return this.resize(_+1),this.emplace(_,o,u,d,p)}emplace(o,u,d,p,_){const b=6*o;return this.uint32[3*o+0]=u,this.uint16[b+2]=d,this.uint16[b+3]=p,this.uint16[b+4]=_,o}}ya.prototype.bytesPerElement=12,xn(ya,"StructArrayLayout1ul3ui12");class Yo extends ot{_refreshViews(){this.uint8=new Uint8Array(this.arrayBuffer),this.uint16=new Uint16Array(this.arrayBuffer)}emplaceBack(o,u){const d=this.length;return this.resize(d+1),this.emplace(d,o,u)}emplace(o,u,d){const p=2*o;return this.uint16[p+0]=u,this.uint16[p+1]=d,o}}Yo.prototype.bytesPerElement=4,xn(Yo,"StructArrayLayout2ui4");class Cs extends ot{_refreshViews(){this.uint8=new Uint8Array(this.arrayBuffer),this.uint16=new Uint16Array(this.arrayBuffer)}emplaceBack(o){const u=this.length;return this.resize(u+1),this.emplace(u,o)}emplace(o,u){return this.uint16[1*o+0]=u,o}}Cs.prototype.bytesPerElement=2,xn(Cs,"StructArrayLayout1ui2");class Ol extends ot{_refreshViews(){this.uint8=new Uint8Array(this.arrayBuffer),this.float32=new Float32Array(this.arrayBuffer)}emplaceBack(o,u){const d=this.length;return this.resize(d+1),this.emplace(d,o,u)}emplace(o,u,d){const p=2*o;return this.float32[p+0]=u,this.float32[p+1]=d,o}}Ol.prototype.bytesPerElement=8,xn(Ol,"StructArrayLayout2f8");class Mi extends Ye{get projectedAnchorX(){return this._structArray.int16[this._pos2+0]}get projectedAnchorY(){return this._structArray.int16[this._pos2+1]}get projectedAnchorZ(){return this._structArray.int16[this._pos2+2]}get tileAnchorX(){return this._structArray.int16[this._pos2+3]}get tileAnchorY(){return this._structArray.int16[this._pos2+4]}get x1(){return this._structArray.float32[this._pos4+3]}get y1(){return this._structArray.float32[this._pos4+4]}get x2(){return this._structArray.float32[this._pos4+5]}get y2(){return this._structArray.float32[this._pos4+6]}get padding(){return this._structArray.int16[this._pos2+14]}get featureIndex(){return this._structArray.uint32[this._pos4+8]}get sourceLayerIndex(){return this._structArray.uint16[this._pos2+18]}get bucketIndex(){return this._structArray.uint16[this._pos2+19]}}Mi.prototype.size=40;class ti extends Wn{get(o){return new Mi(this,o)}}xn(ti,"CollisionBoxArray");class Mr extends Ye{get projectedAnchorX(){return this._structArray.int16[this._pos2+0]}get projectedAnchorY(){return this._structArray.int16[this._pos2+1]}get projectedAnchorZ(){return this._structArray.int16[this._pos2+2]}get tileAnchorX(){return this._structArray.float32[this._pos4+2]}get tileAnchorY(){return this._structArray.float32[this._pos4+3]}get glyphStartIndex(){return this._structArray.uint16[this._pos2+8]}get numGlyphs(){return this._structArray.uint16[this._pos2+9]}get vertexStartIndex(){return this._structArray.uint32[this._pos4+5]}get lineStartIndex(){return this._structArray.uint32[this._pos4+6]}get lineLength(){return this._structArray.uint32[this._pos4+7]}get segment(){return this._structArray.uint16[this._pos2+16]}get lowerSize(){return this._structArray.uint16[this._pos2+17]}get upperSize(){return this._structArray.uint16[this._pos2+18]}get lineOffsetX(){return this._structArray.float32[this._pos4+10]}get lineOffsetY(){return this._structArray.float32[this._pos4+11]}get writingMode(){return this._structArray.uint8[this._pos1+48]}get placedOrientation(){return this._structArray.uint8[this._pos1+49]}set placedOrientation(o){this._structArray.uint8[this._pos1+49]=o}get hidden(){return this._structArray.uint8[this._pos1+50]}set hidden(o){this._structArray.uint8[this._pos1+50]=o}get crossTileID(){return this._structArray.uint32[this._pos4+13]}set crossTileID(o){this._structArray.uint32[this._pos4+13]=o}get associatedIconIndex(){return this._structArray.int16[this._pos2+28]}get flipState(){return this._structArray.uint8[this._pos1+58]}set flipState(o){this._structArray.uint8[this._pos1+58]=o}}Mr.prototype.size=60;class go extends Nr{get(o){return new Mr(this,o)}}xn(go,"PlacedSymbolArray");class Ia extends Ye{get projectedAnchorX(){return this._structArray.int16[this._pos2+0]}get projectedAnchorY(){return this._structArray.int16[this._pos2+1]}get projectedAnchorZ(){return this._structArray.int16[this._pos2+2]}get tileAnchorX(){return this._structArray.float32[this._pos4+2]}get tileAnchorY(){return this._structArray.float32[this._pos4+3]}get rightJustifiedTextSymbolIndex(){return this._structArray.int16[this._pos2+8]}get centerJustifiedTextSymbolIndex(){return this._structArray.int16[this._pos2+9]}get leftJustifiedTextSymbolIndex(){return this._structArray.int16[this._pos2+10]}get verticalPlacedTextSymbolIndex(){return this._structArray.int16[this._pos2+11]}get placedIconSymbolIndex(){return this._structArray.int16[this._pos2+12]}get verticalPlacedIconSymbolIndex(){return this._structArray.int16[this._pos2+13]}get key(){return this._structArray.uint16[this._pos2+14]}get textBoxStartIndex(){return this._structArray.uint16[this._pos2+15]}get textBoxEndIndex(){return this._structArray.uint16[this._pos2+16]}get verticalTextBoxStartIndex(){return this._structArray.uint16[this._pos2+17]}get verticalTextBoxEndIndex(){return this._structArray.uint16[this._pos2+18]}get iconBoxStartIndex(){return this._structArray.uint16[this._pos2+19]}get iconBoxEndIndex(){return this._structArray.uint16[this._pos2+20]}get verticalIconBoxStartIndex(){return this._structArray.uint16[this._pos2+21]}get verticalIconBoxEndIndex(){return this._structArray.uint16[this._pos2+22]}get featureIndex(){return this._structArray.uint16[this._pos2+23]}get numHorizontalGlyphVertices(){return this._structArray.uint16[this._pos2+24]}get numVerticalGlyphVertices(){return this._structArray.uint16[this._pos2+25]}get numIconVertices(){return this._structArray.uint16[this._pos2+26]}get numVerticalIconVertices(){return this._structArray.uint16[this._pos2+27]}get useRuntimeCollisionCircles(){return this._structArray.uint16[this._pos2+28]}get crossTileID(){return this._structArray.uint32[this._pos4+15]}set crossTileID(o){this._structArray.uint32[this._pos4+15]=o}get textOffset0(){return this._structArray.float32[this._pos4+16]}get textOffset1(){return this._structArray.float32[this._pos4+17]}get collisionCircleDiameter(){return this._structArray.float32[this._pos4+18]}}Ia.prototype.size=76;class Ti extends Qr{get(o){return new Ia(this,o)}}xn(Ti,"SymbolInstanceArray");class Wa extends Jr{getoffsetX(o){return this.float32[1*o+0]}}xn(Wa,"GlyphOffsetArray");class Vp extends Zt{getx(o){return this.int16[2*o+0]}gety(o){return this.int16[2*o+1]}}xn(Vp,"SymbolLineVertexArray");class Ru extends Ye{get featureIndex(){return this._structArray.uint32[this._pos4+0]}get sourceLayerIndex(){return this._structArray.uint16[this._pos2+2]}get bucketIndex(){return this._structArray.uint16[this._pos2+3]}get layoutVertexArrayOffset(){return this._structArray.uint16[this._pos2+4]}}Ru.prototype.size=12;class pf extends ya{get(o){return new Ru(this,o)}}xn(pf,"FeatureIndexArray");class cc extends Yo{geta_centroid_pos0(o){return this.uint16[2*o+0]}geta_centroid_pos1(o){return this.uint16[2*o+1]}}xn(cc,"FillExtrusionCentroidArray");const qc=et([{name:"a_pattern",components:4,type:"Uint16"},{name:"a_pixel_ratio",components:1,type:"Float32"}]),Fu=et([{name:"a_dash",components:4,type:"Uint16"}]);var Gp={exports:{}},mf={exports:{}};mf.exports=function(l,o){var u,d,p,_,b,E,k,M;for(d=l.length-(u=3&l.length),p=o,b=3432918353,E=461845907,M=0;M<d;)k=255&l.charCodeAt(M)|(255&l.charCodeAt(++M))<<8|(255&l.charCodeAt(++M))<<16|(255&l.charCodeAt(++M))<<24,++M,p=27492+(65535&(_=5*(65535&(p=(p^=k=(65535&(k=(k=(65535&k)*b+(((k>>>16)*b&65535)<<16)&4294967295)<<15|k>>>17))*E+(((k>>>16)*E&65535)<<16)&4294967295)<<13|p>>>19))+((5*(p>>>16)&65535)<<16)&4294967295))+((58964+(_>>>16)&65535)<<16);switch(k=0,u){case 3:k^=(255&l.charCodeAt(M+2))<<16;case 2:k^=(255&l.charCodeAt(M+1))<<8;case 1:p^=k=(65535&(k=(k=(65535&(k^=255&l.charCodeAt(M)))*b+(((k>>>16)*b&65535)<<16)&4294967295)<<15|k>>>17))*E+(((k>>>16)*E&65535)<<16)&4294967295}
120return p^=l.length,p=2246822507*(65535&(p^=p>>>16))+((2246822507*(p>>>16)&65535)<<16)&4294967295,p=3266489909*(65535&(p^=p>>>13))+((3266489909*(p>>>16)&65535)<<16)&4294967295,(p^=p>>>16)>>>0};var Xg=mf.exports,_A={exports:{}};_A.exports=function(l,o){for(var u,d=l.length,p=o^d,_=0;d>=4;)u=1540483477*(65535&(u=255&l.charCodeAt(_)|(255&l.charCodeAt(++_))<<8|(255&l.charCodeAt(++_))<<16|(255&l.charCodeAt(++_))<<24))+((1540483477*(u>>>16)&65535)<<16),p=1540483477*(65535&p)+((1540483477*(p>>>16)&65535)<<16)^(u=1540483477*(65535&(u^=u>>>24))+((1540483477*(u>>>16)&65535)<<16)),d-=4,++_;switch(d){case 3:p^=(255&l.charCodeAt(_+2))<<16;case 2:p^=(255&l.charCodeAt(_+1))<<8;case 1:p=1540483477*(65535&(p^=255&l.charCodeAt(_)))+((1540483477*(p>>>16)&65535)<<16)}return p=1540483477*(65535&(p^=p>>>13))+((1540483477*(p>>>16)&65535)<<16),(p^=p>>>15)>>>0};var vA=Xg,Dj=_A.exports;Gp.exports=vA,Gp.exports.murmur3=vA,Gp.exports.murmur2=Dj;var Y1=j(Gp.exports);class r0{constructor(){this.ids=[],this.positions=[],this.indexed=!1}add(o,u,d,p){this.ids.push(bA(o)),this.positions.push(u,d,p)}getPositions(o){const u=bA(o);let d=0,p=this.ids.length-1;for(;d<p;){const b=d+p>>1;this.ids[b]>=u?p=b:d=b+1}const _=[];for(;this.ids[d]===u;)_.push({index:this.positions[3*d],start:this.positions[3*d+1],end:this.positions[3*d+2]}),d++;return _}static serialize(o,u){const d=new Float64Array(o.ids),p=new Uint32Array(o.positions);return Z1(d,p,0,d.length-1),u&&u.push(d.buffer,p.buffer),{ids:d,positions:p}}static deserialize(o){const u=new r0;return u.ids=o.ids,u.positions=o.positions,u.indexed=!0,u}}function bA(l){const o=+l;return!isNaN(o)&&Number.MIN_SAFE_INTEGER<=o&&o<=Number.MAX_SAFE_INTEGER?o:Y1(String(l))}function Z1(l,o,u,d){for(;u<d;){const p=l[u+d>>1];let _=u-1,b=d+1;for(;;){do _++;while(l[_]<p);do b--;while(l[b]>p);if(_>=b)break;i0(l,_,b),i0(o,3*_,3*b),i0(o,3*_+1,3*b+1),i0(o,3*_+2,3*b+2)}b-u<d-b?(Z1(l,o,u,b),u=b+1):(Z1(l,o,b+1,d),d=b)}}function i0(l,o,u){const d=l[o];l[o]=l[u],l[u]=d}xn(r0,"FeaturePositionMap");class Bu{constructor(o){this.gl=o.gl,this.initialized=!1}fetchUniformLocation(o,u){return this.location||this.initialized||(this.location=this.gl.getUniformLocation(o,u),this.initialized=!0),!!this.location}}class o0 extends Bu{constructor(o){super(o),this.current=0}set(o,u,d){this.fetchUniformLocation(o,u)&&this.current!==d&&(this.current=d,this.gl.uniform1f(this.location,d))}}class xA extends Bu{constructor(o){super(o),this.current=[0,0,0,0]}set(o,u,d){this.fetchUniformLocation(o,u)&&(d[0]===this.current[0]&&d[1]===this.current[1]&&d[2]===this.current[2]&&d[3]===this.current[3]||(this.current=d,this.gl.uniform4f(this.location,d[0],d[1],d[2],d[3])))}}class wA extends Bu{constructor(o){super(o),this.current=Rt.transparent}set(o,u,d){this.fetchUniformLocation(o,u)&&(d.r===this.current.r&&d.g===this.current.g&&d.b===this.current.b&&d.a===this.current.a||(this.current=d,this.gl.uniform4f(this.location,d.r,d.g,d.b,d.a)))}}const Lj=new Float32Array(16),Rj=new Float32Array(9),Fj=new Float32Array(4);function X1(l){return[He(255*l.r,255*l.g),He(255*l.b,255*l.a)]}class Kg{constructor(o,u,d){this.value=o,this.uniformNames=u.map(p=>`u_${p}`),this.type=d}setUniform(o,u,d,p,_){u.set(o,_,p.constantOr(this.value))}getBinding(o,u){return this.type==="color"?new wA(o):new o0(o)}}class qp{constructor(o,u){this.uniformNames=u.map(d=>`u_${d}`),this.pattern=null,this.pixelRatio=1}setConstantPatternPositions(o){this.pixelRatio=o.pixelRatio||1,this.pattern=o.tl.concat(o.br)}setUniform(o,u,d,p,_){const b=_==="u_pattern"||_==="u_dash"?this.pattern:_==="u_pixel_ratio"?this.pixelRatio:null;b&&u.set(o,_,b)}getBinding(o,u){return u==="u_pattern"||u==="u_dash"?new xA(o):new o0(o)}}class zu{constructor(o,u,d,p){this.expression=o,this.type=d,this.maxValue=0,this.paintVertexAttributes=u.map(_=>({name:`a_${_}`,type:"Float32",components:d==="color"?2:1,offset:0})),this.paintVertexArray=new p}populatePaintArray(o,u,d,p,_,b){const E=this.paintVertexArray.length,k=this.expression.evaluate(new z(0),u,{},_,p,b);this.paintVertexArray.resize(o),this._setPaintValue(E,o,k)}updatePaintArray(o,u,d,p,_){const b=this.expression.evaluate({zoom:0},d,p,void 0,_);this._setPaintValue(o,u,b)}
120_setPaintValue(o,u,d){if(this.type==="color"){const p=X1(d);for(let _=o;_<u;_++)this.paintVertexArray.emplace(_,p[0],p[1])}else{for(let p=o;p<u;p++)this.paintVertexArray.emplace(p,d);this.maxValue=Math.max(this.maxValue,Math.abs(d))}}upload(o){this.paintVertexArray&&this.paintVertexArray.arrayBuffer&&(this.paintVertexBuffer&&this.paintVertexBuffer.buffer?this.paintVertexBuffer.updateData(this.paintVertexArray):this.paintVertexBuffer=o.createVertexBuffer(this.paintVertexArray,this.paintVertexAttributes,this.expression.isStateDependent))}destroy(){this.paintVertexBuffer&&this.paintVertexBuffer.destroy()}}class uc{constructor(o,u,d,p,_,b){this.expression=o,this.uniformNames=u.map(E=>`u_${E}_t`),this.type=d,this.useIntegerZoom=p,this.zoom=_,this.maxValue=0,this.paintVertexAttributes=u.map(E=>({name:`a_${E}`,type:"Float32",components:d==="color"?4:2,offset:0})),this.paintVertexArray=new b}populatePaintArray(o,u,d,p,_,b){const E=this.expression.evaluate(new z(this.zoom),u,{},_,p,b),k=this.expression.evaluate(new z(this.zoom+1),u,{},_,p,b),M=this.paintVertexArray.length;this.paintVertexArray.resize(o),this._setPaintValue(M,o,E,k)}updatePaintArray(o,u,d,p,_){const b=this.expression.evaluate({zoom:this.zoom},d,p,void 0,_),E=this.expression.evaluate({zoom:this.zoom+1},d,p,void 0,_);this._setPaintValue(o,u,b,E)}_setPaintValue(o,u,d,p){if(this.type==="color"){const _=X1(d),b=X1(p);for(let E=o;E<u;E++)this.paintVertexArray.emplace(E,_[0],_[1],b[0],b[1])}else{for(let _=o;_<u;_++)this.paintVertexArray.emplace(_,d,p);this.maxValue=Math.max(this.maxValue,Math.abs(d),Math.abs(p))}}upload(o){this.paintVertexArray&&this.paintVertexArray.arrayBuffer&&(this.paintVertexBuffer&&this.paintVertexBuffer.buffer?this.paintVertexBuffer.updateData(this.paintVertexArray):this.paintVertexBuffer=o.createVertexBuffer(this.paintVertexArray,this.paintVertexAttributes,this.expression.isStateDependent))}destroy(){this.paintVertexBuffer&&this.paintVertexBuffer.destroy()}setUniform(o,u,d,p,_){const b=this.useIntegerZoom?Math.floor(d.zoom):d.zoom,E=ne(this.expression.interpolationFactor(b,this.zoom,this.zoom+1),0,1);u.set(o,_,E)}getBinding(o,u){return new o0(o)}}class Ph{constructor(o,u,d,p,_){this.expression=o,this.layerId=_,this.paintVertexAttributes=(d==="array"?Fu:qc).members;for(let b=0;b<u.length;++b);this.paintVertexArray=new p}populatePaintArray(o,u,d){const p=this.paintVertexArray.length;this.paintVertexArray.resize(o),this._setPaintValues(p,o,u.patterns&&u.patterns[this.layerId],d)}updatePaintArray(o,u,d,p,_,b){this._setPaintValues(o,u,d.patterns&&d.patterns[this.layerId],b)}_setPaintValues(o,u,d,p){if(!p||!d)return;const _=p[d];if(!_)return;const{tl:b,br:E,pixelRatio:k}=_;for(let M=o;M<u;M++)this.paintVertexArray.emplace(M,b[0],b[1],E[0],E[1],k)}upload(o){this.paintVertexArray&&this.paintVertexArray.arrayBuffer&&(this.paintVertexBuffer=o.createVertexBuffer(this.paintVertexArray,this.paintVertexAttributes,this.expression.isStateDependent))}destroy(){this.paintVertexBuffer&&this.paintVertexBuffer.destroy()}}class Mh{constructor(o,u,d=()=>!0){this.binders={},this._buffers=[];const p=[];for(const _ in o.paint._values){if(!d(_))continue;const b=o.paint.get(_);if(!(b instanceof ve&&ma(b.property.specification)))continue;const E=zj(_,o.type),k=b.value,M=b.property.specification.type,F=!!b.property.useIntegerZoom,$=_==="line-dasharray"||_.endsWith("pattern"),V=_==="line-dasharray"&&o.layout.get("line-cap").value.kind!=="constant";if(k.kind!=="constant"||V)if(k.kind==="source"||V||$){const X=TA(_,M,"source");this.binders[_]=$?new Ph(k,E,M,X,o.id):new zu(k,E,M,X),p.push(`/a_${_}`)}else{const X=TA(_,M,"composite");this.binders[_]=new uc(k,E,M,F,u,X),p.push(`/z_${_}`)}else this.binders[_]=$?new qp(k.value,E):new Kg(k.value,E,M),p.push(`/u_${_}`)}this.cacheKey=p.sort().join("")}getMaxValue(o){const u=this.binders[o];return u instanceof zu||u instanceof uc?u.maxValue:0}populatePaintArrays(o,u,d,p,_,b){for(const E in this.binders){const k=this.binders[E];(k instanceof zu||k instanceof uc||k instanceof Ph)&&k.populatePaintArray(o,u,d,p,_,b)}}setConstantPatternPositions(o){for(const u in this.binders){const d=this.binders[u];d instanceof qp&&d.setConstantPatternPositions(o)}}updatePaintArrays(o,u,d,p,_,b){let E=!1;for(const k in o){const M=u.getPositions(k);for(const F of M){const $=d.feature(F.index);for(const V in this.binders){const X=this.binders[V];if((X instanceof zu||X instanceof uc||X instanceof Ph)&&X.expression.isStateDependent===!0){const J=p.paint.get(V);X.expression=J.value,X.updatePaintArray(F.start,F.end,$,o[k],_,b),E=!0}}}}return E}defines(){const o=[];for(const u in this.binders){const d=this.binders[u];(d instanceof Kg||d instanceof qp)&&o.push(...d.uniformNames.map(p=>`#define HAS_UNIFORM_${p}`))}return o}getBinderAttributes(){const o=[];for(const u in this.binders){const d=this.binders[u];if(d instanceof zu||d instanceof uc||d instanceof Ph)for(let p=0;p<d.paintVertexAttributes.length;p++)o.push(d.paintVertexAttributes[p].name)}return o}getBinderUniforms(){const o=[];for(const u in this.binders){const d=this.binders[u];if(d instanceof Kg||d instanceof qp||d instanceof uc)for(const p of d.uniformNames)o.push(p)}return o}getPaintVertexBuffers(){return this._buffers}getUniforms(o){const u=[];for(const d in this.binders){const p=this.binders[d];if(p instanceof Kg||p instanceof qp||p instanceof uc)for(const _ of p.uniformNames)u.push({name:_,property:d,binding:p.getBinding(o,_)})}return u}setUniforms(o,u,d,p,_){for(const{name:b,property:E,binding:k}of d)this.binders[E].setUniform(o,k,_,p.get(E),b)}updatePaintBuffers(){this._buffers=[];for(const o in this.binders){const u=this.binders[o];(u instanceof zu||u instanceof uc||u instanceof Ph)&&u.paintVertexBuffer&&this._buffers.push(u.paintVertexBuffer)}}upload(o){for(const u in this.binders){const d=this.binders[u];(d instanceof zu||d instanceof uc||d instanceof Ph)&&d.upload(o)}this.updatePaintBuffers()}destroy(){for(const o in this.binders){const u=this.binders[o];(u instanceof zu||u instanceof uc||u instanceof Ph)&&u.destroy()}}}class gf{constructor(o,u,d=()=>!0){this.programConfigurations={};for(const p of o)this.programConfigurations[p.id]=new Mh(p,u,d);this.needsUpload=!1,this._featureMap=new r0,this._bufferOffset=0}populatePaintArrays(o,u,d,p,_,b,E){for(const k in this.programConfigurations)this.programConfigurations[k].populatePaintArrays(o,u,p,_,b,E);u.id!==void 0&&this._featureMap.add(u.id,d,this._bufferOffset,o),this._bufferOffset=o,this.needsUpload=!0}updatePaintArrays(o,u,d,p,_){for(const b of d)this.needsUpload=this.programConfigurations[b.id].updatePaintArrays(o,this._featureMap,u,b,p,_)||this.needsUpload}get(o){return this.programConfigurations[o]}upload(o){if(this.needsUpload){for(const u in this.programConfigurations)this.programConfigurations[u].upload(o);this.needsUpload=!1}}destroy(){for(const o in this.programConfigurations)this.programConfigurations[o].destroy()}}const Bj={"text-opacity":["opacity"],"icon-opacity":["opacity"],"text-color":["fill_color"],"icon-color":["fill_color"],"text-halo-color":["halo_color"],"icon-halo-color":["halo_color"],"text-halo-blur":["halo_blur"],"icon-halo-blur":["halo_blur"],"text-halo-width":["halo_width"],"icon-halo-width":["halo_width"],"line-gap-width":["ga
120pwidth"],"line-pattern":["pattern","pixel_ratio"],"fill-pattern":["pattern","pixel_ratio"],"fill-extrusion-pattern":["pattern","pixel_ratio"],"line-dasharray":["dash"]};function zj(l,o){return Bj[l]||[l.replace(`${o}-`,"").replace(/-/g,"_")]}const Nj={"line-pattern":{source:gt,composite:gt},"fill-pattern":{source:gt,composite:gt},"fill-extrusion-pattern":{source:gt,composite:gt},"line-dasharray":{source:Ft,composite:Ft}},$j={color:{source:Ol,composite:Yt},number:{source:Jr,composite:Ol}};function TA(l,o,u){const d=Nj[l];return d&&d[u]||$j[o][u]}xn(Kg,"ConstantBinder"),xn(qp,"PatternConstantBinder"),xn(zu,"SourceExpressionBinder"),xn(Ph,"PatternCompositeBinder"),xn(uc,"CompositeExpressionBinder"),xn(Mh,"ProgramConfiguration",{omit:["_buffers"]}),xn(gf,"ProgramConfigurationSet");const EA="-transition";class hc extends fa{constructor(o,u){if(super(),this.id=o.id,this.type=o.type,this._featureFilter={filter:()=>!0,needGeometry:!1,needFeature:!1},this._filterCompiled=!1,o.type!=="custom"&&(this.metadata=o.metadata,this.minzoom=o.minzoom,this.maxzoom=o.maxzoom,o.type!=="background"&&o.type!=="sky"&&(this.source=o.source,this.sourceLayer=o["source-layer"],this.filter=o.filter),u.layout&&(this._unevaluatedLayout=new be(u.layout)),u.paint)){this._transitionablePaint=new ee(u.paint);for(const d in o.paint)this.setPaintProperty(d,o.paint[d],{validate:!1});for(const d in o.layout)this.setLayoutProperty(d,o.layout[d],{validate:!1});this._transitioningPaint=this._transitionablePaint.untransitioned(),this.paint=new Ee(u.paint)}}getLayoutProperty(o){return o==="visibility"?this.visibility:this._unevaluatedLayout.getValue(o)}setLayoutProperty(o,u,d={}){u!=null&&this._validate(V1,`layers.${this.id}.layout.${o}`,o,u,d)||(o!=="visibility"?this._unevaluatedLayout.setValue(o,u):this.visibility=u)}getPaintProperty(o){return Me(o,EA)?this._transitionablePaint.getTransition(o.slice(0,-11)):this._transitionablePaint.getValue(o)}setPaintProperty(o,u,d={}){if(u!=null&&this._validate(U1,`layers.${this.id}.paint.${o}`,o,u,d))return!1;if(Me(o,EA))return this._transitionablePaint.setTransition(o.slice(0,-11),u||void 0),!1;{const p=this._transitionablePaint._values[o],_=p.value.isDataDriven(),b=p.value;this._transitionablePaint.setValue(o,u),this._handleSpecialPaintPropertyUpdate(o);const E=this._transitionablePaint._values[o].value,k=E.isDataDriven(),M=Me(o,"pattern")||o==="line-dasharray";return k||_||M||this._handleOverridablePaintPropertyUpdate(o,b,E)}}_handleSpecialPaintPropertyUpdate(o){}getProgramIds(){return null}getProgramConfiguration(o){return null}_handleOverridablePaintPropertyUpdate(o,u,d){return!1}isHidden(o){return!!(this.minzoom&&o<this.minzoom)||!!(this.maxzoom&&o>=this.maxzoom)||this.visibility==="none"}updateTransitions(o){this._transitioningPaint=this._transitionablePaint.transitioned(o,this._transitioningPaint)}hasTransition(){return this._transitioningPaint.hasTransition()}recalculate(o,u){this._unevaluatedLayout&&(this.layout=this._unevaluatedLayout.possiblyEvaluate(o,void 0,u)),this.paint=this._transitioningPaint.possiblyEvaluate(o,void 0,u)}
120serialize(){const o={id:this.id,type:this.type,source:this.source,"source-layer":this.sourceLayer,metadata:this.metadata,minzoom:this.minzoom,maxzoom:this.maxzoom,filter:this.filter,layout:this._unevaluatedLayout&&this._unevaluatedLayout.serialize(),paint:this._transitionablePaint&&this._transitionablePaint.serialize()};return this.visibility&&(o.layout=o.layout||{},o.layout.visibility=this.visibility),Ae(o,(u,d)=>!(u===void 0||d==="layout"&&!Object.keys(u).length||d==="paint"&&!Object.keys(u).length))}_validate(o,u,d,p,_={}){return(!_||_.validate!==!1)&&Jv(this,o.call(Qv,{key:u,layerType:this.type,objectKey:d,value:p,styleSpec:Pt,style:{glyphs:!0,sprite:!0}}))}is3D(){return!1}isSky(){return!1}isTileClipped(){return!1}hasOffscreenPass(){return!1}resize(){}isStateDependent(){for(const o in this.paint._values){const u=this.paint.get(o);if(u instanceof ve&&ma(u.property.specification)&&(u.value.kind==="source"||u.value.kind==="composite")&&u.value.isStateDependent)return!0}return!1}compileFilter(){this._filterCompiled||(this._featureFilter=Np(this.filter),this._filterCompiled=!0)}invalidateCompiledFilter(){this._filterCompiled=!1}dynamicFilter(){return this._featureFilter.dynamicFilter}dynamicFilterNeedsFeature(){return this._featureFilter.needFeature}}const jj=et([{name:"a_pos",components:2,type:"Int16"}],4),Uj=et([{name:"a_pos_3",components:3,type:"Int16"},{name:"a_pos_normal_3",components:3,type:"Int16"}]);class yo{constructor(o=[]){this.segments=o}prepareSegment(o,u,d,p){let _=this.segments[this.segments.length-1];return o>yo.MAX_VERTEX_ARRAY_LENGTH&&ct(`Max vertices per segment is ${yo.MAX_VERTEX_ARRAY_LENGTH}: bucket requested ${o}`),(!_||_.vertexLength+o>yo.MAX_VERTEX_ARRAY_LENGTH||_.sortKey!==p)&&(_={vertexOffset:u.length,primitiveOffset:d.length,vertexLength:0,primitiveLength:0}
vendor: 5,553 bytes, line 120
120,p!==void 0&&(_.sortKey=p),this.segments.push(_)),_}get(){return this.segments}destroy(){for(const o of this.segments)for(const u in o.vaos)o.vaos[u].destroy()}static simpleSegment(o,u,d,p){return new yo([{vertexOffset:o,primitiveOffset:u,vertexLength:d,primitiveLength:p,vaos:{},sortKey:0}])}}yo.MAX_VERTEX_ARRAY_LENGTH=Math.pow(2,16)-1,xn(yo,"SegmentVector");var Rn=8192;class Ih{constructor(o,u){o&&(u?this.setSouthWest(o).setNorthEast(u):o.length===4?this.setSouthWest([o[0],o[1]]).setNorthEast([o[2],o[3]]):this.setSouthWest(o[0]).setNorthEast(o[1]))}setNorthEast(o){return this._ne=o instanceof ni?new ni(o.lng,o.lat):ni.convert(o),this}setSouthWest(o){return this._sw=o instanceof ni?new ni(o.lng,o.lat):ni.convert(o),this}extend(o){const u=this._sw,d=this._ne;let p,_;if(o instanceof ni)p=o,_=o;else{if(!(o instanceof Ih))return Array.isArray(o)?o.length===4||o.every(Array.isArray)?this.extend(Ih.convert(o)):this.extend(ni.convert(o)):typeof o=="object"&&o!==null&&o.hasOwnProperty("lat")&&(o.hasOwnProperty("lon")||o.hasOwnProperty("lng"))?this.extend(ni.convert(o)):this;if(p=o._sw,_=o._ne,!p||!_)return this}return u||d?(u.lng=Math.min(p.lng,u.lng),u.lat=Math.min(p.lat,u.lat),d.lng=Math.max(_.lng,d.lng),d.lat=Math.max(_.lat,d.lat)):(this._sw=new ni(p.lng,p.lat),this._ne=new ni(_.lng,_.lat)),this}getCenter(){return new ni((this._sw.lng+this._ne.lng)/2,(this._sw.lat+this._ne.lat)/2)}getSouthWest(){return this._sw}getNorthEast(){return this._ne}getNorthWest(){return new ni(this.getWest(),this.getNorth())}getSouthEast(){return new ni(this.getEast(),this.getSouth())}getWest(){return this._sw.lng}getSouth(){return this._sw.lat}getEast(){return this._ne.lng}getNorth(){return this._ne.lat}toArray(){return[this._sw.toArray(),this._ne.toArray()]}toString(){return`LngLatBounds(${this._sw.toString()}, ${this._ne.toString()})`}isEmpty(){return!(this._sw&&this._ne)}contains(o){const{lng:u,lat:d}=ni.convert(o);let p=this._sw.lng<=u&&u<=this._ne.lng;return this._sw.lng>this._ne.lng&&(p=this._sw.lng>=u&&u>=this._ne.lng),this._sw.lat<=d&&d<=this._ne.lat&&p}static convert(o){return!o||o instanceof Ih?o:new Ih(o)}}var a0=1e-6,ks=typeof Float32Array<"u"?Float32Array:Array;function SA(){var l=new ks(9);return ks!=Float32Array&&(l[1]=0,l[2]=0,l[3]=0,l[5]=0,l[6]=0,l[7]=0),l[0]=1,l[4]=1,l[8]=1,l}function CA(l,o,u){var d=o[0],p=o[1],_=o[2],b=o[3],E=o[4],k=o[5],M=o[6],F=o[7],$=o[8],V=u[0],X=u[1],J=u[2],re=u[3],pe=u[4],Ce=u[5],ze=u[6],ke=u[7],Be=u[8];return l[0]=V*d+X*b+J*M,l[1]=V*p+X*E+J*F,l[2]=V*_+X*k+J*$,l[3]=re*d+pe*b+Ce*M,l[4]=re*p+pe*E+Ce*F,l[5]=re*_+pe*k+Ce*$,l[6]=ze*d+ke*b+Be*M,l[7]=ze*p+ke*E+Be*F,l[8]=ze*_+ke*k+Be*$,l}function dc(l){return l[0]=1,l[1]=0,l[2]=0,l[3]=0,l[4]=0,l[5]=1,l[6]=0,l[7]=0,l[8]=0,l[9]=0,l[10]=1,l[11]=0,l[12]=0,l[13]=0,l[14]=0,l[15]=1,l}function K1(l,o){var u=o[0],d=o[1],p=o[2],_=o[3],b=o[4],E=o[5],k=o[6],M=o[7],F=o[8],$=o[9],V=o[10],X=o[11],J=o[12],re=o[13],pe=o[14],Ce=o[15],ze=u*E-d*b,ke=u*k-p*b,Be=u*M-_*b,We=d*k-p*E,Ge=d*M-_*E,vt=p*M-_*k,ft=F*re-$*J,Dt=F*pe-V*J,Xt=F*Ce-X*J,Ct=$*pe-V*re,zt=$*Ce-X*re,Nt=V*Ce-X*pe,Gt=ze*Nt-ke*zt+Be*Ct+We*Xt-Ge*Dt+vt*ft;return Gt?(l[0]=(E*Nt-k*zt+M*Ct)*(Gt=1/Gt),l[1]=(p*zt-d*Nt-_*Ct)*Gt,l[2]=(re*vt-pe*Ge+Ce*We)*Gt,l[3]=(V*Ge-$*vt-X*We)*Gt,l[4]=(k*Xt-b*Nt-M*Dt)*Gt,l[5]=(u*Nt-p*Xt+_*Dt)*Gt,l[6]=(pe*Be-J*vt-Ce*ke)*Gt,l[7]=(F*vt-V*Be+X*ke)*Gt,l[8]=(b*zt-E*Xt+M*ft)*Gt,l[9]=(d*Xt-u*zt-_*ft)*Gt,l[10]=(J*Ge-re*Be+Ce*ze)*Gt,l[11]=($*Be-F*Ge-X*ze)*Gt,l[12]=(E*Dt-b*Ct-k*ft)*Gt,l[13]=(u*Ct-d*Dt+p*ft)*Gt,l[14]=(re*ke-J*We-pe*ze)*Gt,l[15]=(F*We-$*ke+V*ze)*Gt,l):null}function yf(l,o,u){var d=o[0],p=o[1],_=o[2],b=o[3],E=o[4],k=o[5],M=o[6],F=o[7],$=o[8],V=o[9],X=o[10],J=o[11],re=o[12],pe=o[13],Ce=o[14],ze=o[15],ke=u[0],Be=u[1],We=u[2],Ge=u[3];return l[0]=ke*d+Be*E+We*$+Ge*re,l[1]=ke*p+Be*k+We*V+Ge*pe,l[2]=ke*_+Be*M+We*X+Ge*Ce,l[3]=ke*b+Be*F+We*J+Ge*ze,l[4]=(ke=u[4])*d+(Be=u[5])*E+(We=u[6])*$+(Ge=u[7])*re,l[5]=ke*p+Be*k+We*V+Ge*pe,l[6]=ke*_+Be*M+We*X+Ge*Ce,l[7]=ke*b+Be*F+We*J+Ge*ze,l[8]=(ke=u[8])*d+(Be=u[9])*E+(We=u[10])*$+(Ge=u[11])*re,l[9]=ke*p+Be*k+We*V+Ge*pe,l[10]=ke*_+Be*M+We*X+Ge*Ce,l[11]=ke*b+Be*F+We*J+Ge*ze,l[12]=(ke=u[12])*d+(Be=u[13])*E+(We=u[14])*$+(Ge=u[15])*re,l[13]=ke*p+Be*k+We*V+Ge*pe,l[14]=ke*_+Be*M+We*X+Ge*Ce,l[15]=ke*b+Be*F+We*J+Ge*ze,l}function Qg(l,o,u){var d,p,_,b,E,k,M,F,$,V,X,J,re=u[0],pe=u[1],Ce=u[2];return o===l?(l[12]=o[0]*re+o[4]*pe+o[8]*Ce+o[12],l[13]=o[1]*re+o[5]*pe+o[9]*Ce+o[13],l[14]=o[2]*re+o[6]*pe+o[10]*Ce+o[14],l[15]=o[3]*re+o[7]*pe+o[11]*Ce+o[15]):(p=o[1],_=o[2],b=o[3],E=o[4],k=o[5],M=o[6],F=o[7],$=o[8],V=o[9],X=o[10],J=o[11],l[0]=d=o[0],l[1]=p,l[2]=_,l[3]=b,l[4]=E,l[5]=k,l[6]=M,l[7]=F,l[8]=$,l[9]=V,l[10]=X,l[11]=J,l[12]=d*re+E*pe+$*Ce+o[12],l[13]=p*re+k*pe+V*Ce+o[13],l[14]=_*re+M*pe+X*Ce+o[14],l[15]=b*re+F*pe+J*Ce+o[15]),l}function _f(l,o,u){var d=u[0],p=u[1],_=u[2];return l[0]=o[0]*d,l[1]=o[1]*d,l[2]=o[2]*d,l[3]=o[3]*d,l[4]=o[4]*p,l[5]=o[5]*p,l[6]=o[6]*p,l[7]=o[7]*p,l[8]=o[8]*_,l[9]=o[9]*_,l[10]=o[10]*_,l[11]=o[11]*_,l[12]=o[12],l[13]=o[13],l[14]=o[14],l[15]=o[15],l}function Q1(l,o,u){var d=Math.sin(u),p=Math.cos(u),_=o[4],b=o[5],E=o[6],k=o[7],M=o[8],F=o[9],$=o[10],V=o[11];return o!==l&&(l[0]=o[0],l[1]=o[1],l[2]=o[2],l[3]=o[3],l[12]=o[12],l[13]=o[13],l[14]=o[14],l[15]=o[15]),l[4]=_*p+M*d,l[5]=b*p+F*d,l[6]=E*p+$*d,l[7]=k*p+V*d,l[8]=M*p-_*d,l[9]=F*p-b*d,l[10]=$*p-E*d,l[11]=V*p-k*d,l}function s0(l,o,u){var d=Math.sin(u),p=Math.cos(u),_=o[0],b=o[1],E=o[2],k=o[3],M=o[8],F=o[9],$=o[10],V=o[11];return o!==l&&(l[4]=o[4],l[5]=o[5],l[6]=o[6],l[7]=o[7],l[12]=o[12],l[13]=o[13],l[14]=o[14],l[15]=o[15]),l[0]=_*p-M*
vendor: 7,224 bytes, line 120
120d,l[1]=b*p-F*d,l[2]=E*p-$*d,l[3]=k*p-V*d,l[8]=_*d+M*p,l[9]=b*d+F*p,l[10]=E*d+$*p,l[11]=k*d+V*p,l}function kA(l,o){return l[0]=o[0],l[1]=0,l[2]=0,l[3]=0,l[4]=0,l[5]=o[1],l[6]=0,l[7]=0,l[8]=0,l[9]=0,l[10]=o[2],l[11]=0,l[12]=0,l[13]=0,l[14]=0,l[15]=1,l}function AA(l,o,u){var d,p,_,b=u[0],E=u[1],k=u[2],M=Math.hypot(b,E,k);return M<a0?null:(b*=M=1/M,E*=M,k*=M,d=Math.sin(o),p=Math.cos(o),l[0]=b*b*(_=1-p)+p,l[1]=E*b*_+k*d,l[2]=k*b*_-E*d,l[3]=0,l[4]=b*E*_-k*d,l[5]=E*E*_+p,l[6]=k*E*_+b*d,l[7]=0,l[8]=b*k*_+E*d,l[9]=E*k*_-b*d,l[10]=k*k*_+p,l[11]=0,l[12]=0,l[13]=0,l[14]=0,l[15]=1,l)}Math.hypot||(Math.hypot=function(){for(var l=0,o=arguments.length;o--;)l+=arguments[o]*arguments[o];return Math.sqrt(l)});var Vj=yf;function J1(){var l=new ks(3);return ks!=Float32Array&&(l[0]=0,l[1]=0,l[2]=0),l}function PA(l){var o=new ks(3);return o[0]=l[0],o[1]=l[1],o[2]=l[2],o}function Jg(l){return Math.hypot(l[0],l[1],l[2])}function Wp(l,o,u){var d=new ks(3);return d[0]=l,d[1]=o,d[2]=u,d}function Nu(l,o,u){return l[0]=o[0]+u[0],l[1]=o[1]+u[1],l[2]=o[2]+u[2],l}function ew(l,o,u){return l[0]=o[0]-u[0],l[1]=o[1]-u[1],l[2]=o[2]-u[2],l}function MA(l,o,u){return l[0]=o[0]*u[0],l[1]=o[1]*u[1],l[2]=o[2]*u[2],l}function ey(l,o,u){return l[0]=Math.min(o[0],u[0]),l[1]=Math.min(o[1],u[1]),l[2]=Math.min(o[2],u[2]),l}function ty(l,o,u){return l[0]=Math.max(o[0],u[0]),l[1]=Math.max(o[1],u[1]),l[2]=Math.max(o[2],u[2]),l}function il(l,o,u){return l[0]=o[0]*u,l[1]=o[1]*u,l[2]=o[2]*u,l}function ny(l,o,u,d){return l[0]=o[0]+u[0]*d,l[1]=o[1]+u[1]*d,l[2]=o[2]+u[2]*d,l}function Ha(l,o){var u=o[0],d=o[1],p=o[2],_=u*u+d*d+p*p;return _>0&&(_=1/Math.sqrt(_)),l[0]=o[0]*_,l[1]=o[1]*_,l[2]=o[2]*_,l}function Dl(l,o){return l[0]*o[0]+l[1]*o[1]+l[2]*o[2]}function tw(l,o,u){var d=o[0],p=o[1],_=o[2],b=u[0],E=u[1],k=u[2];return l[0]=p*k-_*E,l[1]=_*b-d*k,l[2]=d*E-p*b,l}function co(l,o,u){var d=o[0],p=o[1],_=o[2],b=u[3]*d+u[7]*p+u[11]*_+u[15];return l[0]=(u[0]*d+u[4]*p+u[8]*_+u[12])/(b=b||1),l[1]=(u[1]*d+u[5]*p+u[9]*_+u[13])/b,l[2]=(u[2]*d+u[6]*p+u[10]*_+u[14])/b,l}function IA(l,o,u){var d=u[0],p=u[1],_=u[2],b=o[0],E=o[1],k=o[2],M=p*k-_*E,F=_*b-d*k,$=d*E-p*b,V=p*$-_*F,X=_*M-d*$,J=d*F-p*M,re=2*u[3];return F*=re,$*=re,X*=2,J*=2,l[0]=b+(M*=re)+(V*=2),l[1]=E+F+X,l[2]=k+$+J,l}var ry,fc=ew,Gj=MA,qj=Jg;function OA(l,o,u){return l[0]=o[0]*u,l[1]=o[1]*u,l[2]=o[2]*u,l[3]=o[3]*u,l}function DA(l,o){var u=o[0],d=o[1],p=o[2],_=o[3],b=u*u+d*d+p*p+_*_;return b>0&&(b=1/Math.sqrt(b)),l[0]=u*b,l[1]=d*b,l[2]=p*b,l[3]=_*b,l}function vf(l,o,u){var d=o[0],p=o[1],_=o[2],b=o[3];return l[0]=u[0]*d+u[4]*p+u[8]*_+u[12]*b,l[1]=u[1]*d+u[5]*p+u[9]*_+u[13]*b,l[2]=u[2]*d+u[6]*p+u[10]*_+u[14]*b,l[3]=u[3]*d+u[7]*p+u[11]*_+u[15]*b,l}function LA(){var l=new ks(4);return ks!=Float32Array&&(l[0]=0,l[1]=0,l[2]=0),l[3]=1,l}function RA(l){return l[0]=0,l[1]=0,l[2]=0,l[3]=1,l}function FA(l,o,u){u*=.5;var d=o[0],p=o[1],_=o[2],b=o[3],E=Math.sin(u),k=Math.cos(u);return l[0]=d*k+b*E,l[1]=p*k+_*E,l[2]=_*k-p*E,l[3]=b*k-d*E,l}function BA(l,o,u){u*=.5;var d=o[0],p=o[1],_=o[2],b=o[3],E=Math.sin(u),k=Math.cos(u);return l[0]=d*k-_*E,l[1]=p*k+b*E,l[2]=_*k+d*E,l[3]=b*k-p*E,l}J1(),ry=new ks(4),ks!=Float32Array&&(ry[0]=0,ry[1]=0,ry[2]=0,ry[3]=0);var Wj=DA;J1(),Wp(1,0,0),Wp(0,1,0),LA(),LA(),SA();const Hj=et([{type:"Float32",name:"a_globe_pos",components:3},{type:"Float32",name:"a_uv",components:2}]),{members:zA}=Hj,NA=et([{name:"a_pos_3",components:3,type:"Int16"}]);var iy=et([{name:"a_pos",type:"Int16",components:2}]);class nw{constructor(o,u){this.pos=o,this.dir=u}intersectsPlane(o,u,d){const p=Dl(u,this.dir);if(Math.abs(p)<1e-6)return!1;const _=((o[0]-this.pos[0])*u[0]+(o[1]-this.pos[1])*u[1]+(o[2]-this.pos[2])*u[2])/p;return d[0]=this.pos[0]+this.dir[0]*_,d[1]=this.pos[1]+this.dir[1]*_,d[2]=this.pos[2]+this.dir[2]*_,!0}closestPointOnSphere(o,u,d){if(function(X,J){var re=X[0],pe=X[1],Ce=X[2],ze=J[0],ke=J[1],Be=J[2];return Math.abs(re-ze)<=a0*Math.max(1,Math.abs(re),Math.abs(ze))&&Math.abs(pe-ke)<=a0*Math.max(1,Math.abs(pe),Math.abs(ke))&&Math.abs(Ce-Be)<=a0*Math.max(1,Math.abs(Ce),Math.abs(Be))}(this.pos,o)||u===0)return d[0]=d[1]=d[2]=0,!1;const[p,_,b]=this.dir,E=this.pos[0]-o[0],k=this.pos[1]-o[1],M=this.pos[2]-o[2],F=p*p+_*_+b*b,$=2*(E*p+k*_+M*b),V=$*$-4*F*(E*E+k*k+M*M-u*u);if(V<0){const X=Math.max(-$/2,0),J=E+p*X,re=k+_*X,pe=M+b*X,Ce=Math.hypot(J,re,pe);return d[0]=J*u/Ce,d[1]=re*u/Ce,d[2]=pe*u/Ce,!1}{const X=(-$-Math.sqrt(V))/(2*F);if(X<0){const J=Math.hypot(E,k,M);return d[0]=E*u/J,d[1]=k*u/J,d[2]=M*u/J,!1}return d[0]=E+p*X,d[1]=k+_*X,d[2]=M+b*X,!0}}}class rw{constructor(o,u,d,p,_){this.TL=o,this.TR=u,this.BR=d,this.BL=p,this.horizon=_}static fromInvProjectionMatrix(o,u,d){const p=[-1,1,1],_=[1,1,1],b=[1,-1,1],E=[-1,-1,1],k=co(p,p,o),M=co(_,_,o),F=co(b,b,o),$=co(E,E,o);return new rw(k,M,F,$,u/d)}}class iw{constructor(o,u){this.points=o,this.planes=u}static fromInvProjectionMatrix(o,u,d,p){const _=Math.pow(2,d),b=[[-1,1,-1,1],[1,1,-1,1],[1,-1,-1,1],[-1,-1,-1,1],[-1,1,1,1],[1,1,1,1],[1,-1,1,1],[-1,-1,1,1]].map(k=>{const M=vf([],k,o),F=1/M[3]/u*_;return function($,V,X){return $[0]=V[0]*X[0],$[1]=V[1]*X[1],$[2]=V[2]*X[2],$[3]=V[3]*X[3],$}(M,M,[F,F,p?1/M[3]:F,F])}),E=[[0,1,2],[6,5,4],[0,3,7],[2,1,5],[3,2,6],[0,4,5]].map(k=>{const M=Ha([],tw([],fc([],b[k[0]],b[k[1]]),fc([],b[k[2]],b[k[1]]))),F=-Dl(M,b[k[1]]);return M.concat(F)});return new iw(b,E)}}class Ya{static fromPoints(o){const u=[1/0,1/0,1/0],d=[-1/0,-1/0,-1/0];for(const p of o)ey(u,u,p),ty(d,d,p);return new Ya(u,d)}static applyTransform(o,u){const d=o.getCorners();for(let p=0;p<d.length;++p)co(d[p],d[p],u);return Ya.fromPoints(d)}constructor(o,u){this.min=o,this.max=u,this.center=il([],Nu([],this.min,this.max),.5)}quadrant(o){const u=[o%2==0,o<2],d=PA(this.min),p=PA(this.max);for(let _=0;_<u.length;_++)d[_]=u[_]?this.min[_]:this.center[_],p[_]=u[_]?this.center[_]:this.max[_];return p[2]=this.max[2],new Ya(d,p)}distanceX(o){return Math.max(Math.min(this.max[0],o[0]),this.min[0])-o[0]}distanceY(o){return Math.max(Math.min(this.max[1],o[1]),this.min[1])-o[1]}distanceZ(o){return Math.max(Math.min(this.max[2],o[2]),this.min[2])-o[2]}getCorners(){const o=this.min,u=this.max;return[[o[0],o[1],o[2]],[u[0],o[1],o[2]],[u[0],u[1],o[2]],[o[0],u[1],o[2]],[o[0],o[1],u[2]],[u[0],o[1],u[2]],[u[0],u[1],u[2]],[o[0],u[1],u[2]]]}intersects(o){const u=this.getCorners();let d=!0;for(let p=0;p<o.planes.length;p++){const _=o.planes[p];let b=0;for(let E=0;E<u.length;E++)b+=Dl(_,u[E])+_[3]>=0;if(b===0)return 0;b!==u.length&&(d=!1)}if(d)return 2;for(let p=0;p<3;p++){let _=Number.MAX_VALUE,b=-Number.MAX_VALUE;for(let E=0;E<o.points.length;E++){const k=o.points[E][p]-this.min[p];_=Math.min(_,k),b=Math.max(b,k)}if(b<0||_>this.max[p]-this.min[p])return 0}return 1}}const ow=5,$A=6,Wc=Rn/Math.PI/2,Yj=16383,bf=64,oy=[bf,32,16],Ll=-Wc,Rl=Wc,Zj=[new Ya([Ll,Ll,Ll],[Rl,Rl,Rl]),new Ya([Ll,Ll,Ll],[0,0,Rl]),new Ya([0,Ll,Ll],[Rl,0,Rl]),new Ya([Ll,0,Ll],[0,Rl,Rl]),new Ya([0,0,Ll],[Rl,Rl,Rl])];function l0(l){return l*Wc/ly}function jA(l,o,u,d=!0){const p=il([],l._camera.position,l.worldSize),_=[o,u,1,1];vf(_,_,l.pixelMatrixInverse),OA(_,_,1/_[3]);const b=Ha([],fc([],_,p)),E=l.globeMatrix,k=[E[12],E[13],E[14]],M=fc([],k,p),F=Jg(M),$=Ha([],M),V=l.worldSize/(2*Math.PI),X=Dl($,b),J=Math.asin(V/F);
120if(J<Math.acos(X)){if(!d)return null;const Xt=[],Ct=[];il(Xt,b,F/X),Ha(Ct,fc(Ct,Xt,M)),Ha(b,Nu(b,M,il(b,Ct,Math.tan(J)*F)))}const re=[];new nw(p,b).closestPointOnSphere(k,V,re);const pe=Ha([],qt(E,0)),Ce=Ha([],qt(E,1)),ze=Ha([],qt(E,2)),ke=Dl(pe,re),Be=Dl(Ce,re),We=Dl(ze,re),Ge=fe(Math.asin(-Be/V));let vt=fe(Math.atan2(ke,We));vt=l.center.lng+function(Xt,Ct){const zt=(Ct-Xt+180)%360-180;return zt<-180?zt+360:zt}(l.center.lng,vt);const ft=Yc(vt),Dt=ne(Zc(Ge),0,1);return new Xp(ft,Dt)}class Xj{constructor(o,u,d){this.a=fc([],o,d),this.b=fc([],u,d),this.center=d;const p=Ha([],this.a),_=Ha([],this.b);this.angle=Math.acos(Dl(p,_))}}function aw(l,o){if(l.angle===0)return null;let u;return u=l.a[o]===0?1/l.angle*.5*Math.PI:1/l.angle*Math.atan(l.b[o]/l.a[o]/Math.sin(l.angle)-1/Math.tan(l.angle)),u<0||u>1?null:function(d,p,_,b){const E=Math.sin(_);return d*(Math.sin((1-b)*_)/E)+p*(Math.sin(b*_)/E)}(l.a[o],l.b[o],l.angle,ne(u,0,1))+l.center[o]}function Hc(l){if(l.z<=1)return Zj[l.z+2*l.y+l.x];const o=sw(c0(l));return Ya.fromPoints(o)}function xf(l,o,u){return il(l,l,1-u),ny(l,l,o,u)}function UA(l,o){const u=Zp(o.zoom);if(u===0)return Hc(l);const d=c0(l),p=sw(d),_=Yc(d.getWest())*o.worldSize,b=Yc(d.getEast())*o.worldSize,E=Zc(d.getNorth())*o.worldSize,k=Zc(d.getSouth())*o.worldSize,M=[_,E,0],F=[b,E,0],$=[_,k,0],V=[b,k,0],X=K1([],o.globeMatrix);return co(M,M,X),co(F,F,X),co($,$,X),co(V,V,X),p[0]=xf(p[0],$,u),p[1]=xf(p[1],V,u),p[2]=xf(p[2],F,u),p[3]=xf(p[3],M,u),Ya.fromPoints(p)}function VA(l,o,u){for(const d of l)co(d,d,o),il(d,d,u)}function Kj(l,o,u){const d=o/l.worldSize,p=l.globeMatrix;if(u.z<=1){const ft=Hc(u).getCorners();return VA(ft,p,d),Ya.fromPoints(ft)}const _=c0(u),b=sw(_);VA(b,p,d);const E=Number.MAX_VALUE,k=[-E,-E,-E],M=[E,E,E];if(_.contains(l.center)){for(const Xt of b)ey(M,M,Xt),ty(k,k,Xt);k[2]=0;const ft=l.point,Dt=[ft.x*d,ft.y*d,0];return ey(M,M,Dt),ty(k,k,Dt),new Ya(M,k)}const F=[p[12]*d,p[13]*d,p[14]*d],$=_.getCenter(),V=ne(l.center.lat,-va,va),X=ne($.lat,-va,va),J=Yc(l.center.lng),re=Zc(V);let pe=J-Yc($.lng);const Ce=re-Zc(X);pe>.5?pe-=1:pe<-.5&&(pe+=1);let ze=0;Math.abs(pe)>Math.abs(Ce)?ze=pe>=0?1:3:(ze=Ce>=0?0:2,ny(F,F,[p[4]*d,p[5]*d,p[6]*d],-Math.sin(ce(Ce>=0?_.getSouth():_.getNorth()))*Wc));const ke=b[ze],Be=b[(ze+1)%4],We=new Xj(ke,Be,F),Ge=[aw(We,0)||ke[0],aw(We,1)||ke[1],aw(We,2)||ke[2]],vt=Zp(l.zoom);if(vt>0){const ft=function({x:Xt,y:Ct,z:zt},Nt,Gt,nn,Mt){const un=1/(1<<zt);let Tn=Xt*un,fn=Tn+un,Qn=Ct*un,rn=Qn+un,In=0;const Jn=(Tn+fn)/2-nn;return Jn>.5?In=-1:Jn<-.5&&(In=1),Tn=((Tn+In)*Nt-(nn*=Nt))*Gt+nn,fn=((fn+In)*Nt-nn)*Gt+nn,Qn=(Qn*Nt-(Mt*=Nt))*Gt+Mt,rn=(rn*Nt-Mt)*Gt+Mt,[[Tn,rn,0],[fn,rn,0],[fn,Qn,0],[Tn,Qn,0]]}(u,o,l._pixelsPerMercatorPixel,J,re);for(let Xt=0;Xt<b.length;Xt++)xf(b[Xt],ft[Xt],vt);const Dt=Nu([],ft[ze],ft[(ze+1)%4]);il(Dt,Dt,.5),xf(Ge,Dt,vt)}for(const ft of b)ey(M,M,ft),ty(k,k,ft);return M[2]=Math.min(ke[2],Be[2]),ey(M,M,Ge),ty(k,k,Ge),new Ya(M,k)}function c0({x:l,y:o,z:u}){const d=1/(1<<u),p=new ni(ol(l*d),_a((o+1)*d)),_=new ni(ol((l+1)*d),_a(o*d));return new Ih(p,_)}function sw(l){const o=ce(l.getNorth()),u=ce(l.getSouth()),d=Math.cos(o),p=Math.cos(u),_=Math.sin(o),b=Math.sin(u),E=l.getWest(),k=l.getEast();return[Hp(p,b,E),Hp(p,b,k),Hp(d,_,k),Hp(d,_,E)]}function Hp(l,o,u,d=Wc){return u=ce(u),[l*Math.sin(u)*d,-o*d,l*Math.cos(u)*d]}function Yp(l,o,u){return Hp(Math.cos(ce(l)),Math.sin(ce(l)),o,u)}function ay(l,o,u,d){const p=1<<u.z,_=(l/Rn+u.x)/p;return Yp(_a((o/Rn+u.y)/p),ol(_),d)}function u0({min:l,max:o}){return Yj/Math.max(o[0]-l[0],o[1]-l[1],o[2]-l[2])}const GA=new Float64Array(16);function sy(l){const o=u0(l),u=kA(GA,[o,o,o]);return Qg(u,u,((d=[])[0]=-(p=l.min)[0],d[1]=-p[1],d[2]=-p[2],d));var d,p}function lw(l){const o=(d=l.min,(u=GA)[0]=1,u[1]=0,u[2]=0,u[3]=0,u[4]=0,u[5]=1,u[6]=0,u[7]=0,u[8]=0,u[9]=0,u[10]=1,u[11]=0,u[12]=d[0],u[13]=d[1],u[14]=d[2],u[15]=1,u);var u,d;const p=1/u0(l);return _f(o,o,[p,p,p])}function qA(l,o,u,d,p){const _=function(k){const M=Rn/(2*Math.PI);return k/(2*Math.PI)/M}(u),b=[l,o,-u/(2*Math.PI)],E=dc(new Float64Array(16));return Qg(E,E,b),_f(E,E,[_,_,_]),Q1(E,E,ce(-p)),s0(E,E,ce(-d)),E}function Zp(l){return le(ow,$A,l)}function WA(l,o){const u=Yp(o.lat,o.lng),d=function(J){const re=Yp(J._center.lat,J._center.lng);let pe=tw([],Wp(0,1,0),re);const Ce=AA([],-J.angle,re);pe=co(pe,pe,Ce),AA(Ce,-J._pitch,pe);const ze=Ha([],re);return il(ze,ze,l0(J.cameraToCenterDistance/J.pixelsPerMeter)),co(ze,ze,Ce),Nu([],re,ze)}(l);return b=(p=ew([],d,u))[0],E=p[1],k=p[2],M=(_=u)[0],F=_[1],$=_[2],X=(V=Math.sqrt(b*b+E*E+k*k)*Math.sqrt(M*M+F*F+$*$))&&Dl(p,_)/V,Math.acos(Math.min(Math.max(X,-1),1));var p,_,b,E,k,M,F,$,V,X}function cw(l,o){return WA(l,o)>Math.PI/2*1.01}const HA=ce(85),Qj=Math.cos(HA),Jj=Math.sin(HA),ly=63710088e-1,YA=2*Math.PI*ly;class Oh{constructor(o,u){if(isNaN(o)||isNaN(u))throw new Error(`Invalid LngLat object: (${o}, ${u})`);if(this.lng=+o,this.lat=+u,this.lat>90||this.lat<-90)throw new Error("Invalid LngLat latitude value: must be between -90 and 90")}wrap(){return new Oh(se(this.lng,-180,180),this.lat)}toArray(){return[this.lng,this.lat]}toString(){return`LngLat(${this.lng}, ${this.lat})`}distanceTo(o){const u=Math.PI/180,d=this.lat*u,p=o.lat*u,_=Math.sin(d)*Math.sin(p)+Math.cos(d)*Math.cos(p)*Math.cos((o.lng-this.lng)*u);return ly*Math.acos(Math.min(_,1))}toBounds(o=0){const u=360*o/40075017,d=u/Math.cos(Math.PI/180*this.lat);return new Ih(new Oh(this.lng-d,this.lat-u),new Oh(this.lng+d,this.lat+u))}toEcef(o){const u=l0(o);return Yp(this.lat,this.lng,Wc+u)}static convert(o){if(o instanceof Oh)return o;if(Array.isArray(o)&&(o.length===2||o.length===3))return new Oh(Number(o[0]),Number(o[1]));if(!Array.isArray(o)&&typeof o=="object"&&o!==null)return new Oh(Number("lng"in o?o.lng:o.lon),Number(o.lat));throw new Error("`LngLatLike` argument must be specified as a LngLat instance, an object {lng: <lng>, lat: <lat>}, an object {lon: <lng>, lat: <lat>}, or an array of [<lng>, <lat>]")}}var ni=Oh;function uw(l){return YA*Math.cos(l*Math.PI/180)}function Yc(l){return(180+l)/360}function Zc(l){return(180-180/Math.PI*Math.log(Math.tan(Math.PI/4+l*Math.PI/360)))/360}function pc(l,o){return l/uw(o)}function ol(l){return 360*l-180}function _a(l){return 360/Math.PI*Math.atan(Math.exp((180-360*l)*Math.PI/180)
vendor: 6,838 bytes, line 120
120)-90}function ZA(l,o){return l*uw(_a(o))}const va=85.051129;function XA(l){return 1/Math.cos(l*Math.PI/180)}class Xp{constructor(o,u,d=0){this.x=+o,this.y=+u,this.z=+d}static fromLngLat(o,u=0){const d=ni.convert(o);return new Xp(Yc(d.lng),Zc(d.lat),pc(u,d.lat))}toLngLat(){return new ni(ol(this.x),_a(this.y))}toAltitude(){return ZA(this.z,this.y)}meterInMercatorCoordinateUnits(){return 1/YA*XA(_a(this.y))}}function hw(l,o,u,d,p,_,b,E,k){const M=(o+d)/2,F=(u+p)/2,$=new Y(M,F);E($),function(V,X,J,re,pe,Ce){const ze=J-pe,ke=re-Ce;return Math.abs((re-X)*ze-(J-V)*ke)/Math.hypot(ze,ke)}($.x,$.y,_.x,_.y,b.x,b.y)>=k?(hw(l,o,u,M,F,_,$,E,k),hw(l,M,F,d,p,$,b,E,k)):l.push(b)}function KA(l,o,u){let d=l[0],p=d.x,_=d.y;o(d);const b=[d];for(let E=1;E<l.length;E++){const k=l[E],{x:M,y:F}=k;o(k),hw(b,p,_,M,F,d,k,o,u),p=M,_=F,d=k}return b}function dw(l,o,u,d){if(d(o,u)){const p=o.add(u)._mult(.5);dw(l,o,p,d),dw(l,p,u,d)}else l.push(u)}function eU(l,o){let u=l[0];const d=[u];for(let p=1;p<l.length;p++){const _=l[p];dw(d,u,_,o),u=_}return d}const fw=Math.pow(2,14)-1,QA=-fw-1;function tU(l,o){const u=Math.round(l.x*o),d=Math.round(l.y*o);return l.x=ne(u,QA,fw),l.y=ne(d,QA,fw),(u<l.x||u>l.x+1||d<l.y||d>l.y+1)&&ct("Geometry exceeds allowed extent, reduce your vector tile buffer size"),l}function $u(l,o,u){const d=l.loadGeometry(),p=l.extent,_=Rn/p;if(o&&u&&u.projection.isReprojectedInTileSpace){const b=1<<o.z,{scale:E,x:k,y:M,projection:F}=u,$=V=>{const X=ol((o.x+V.x/p)/b),J=_a((o.y+V.y/p)/b),re=F.project(X,J);V.x=(re.x*E-k)*p,V.y=(re.y*E-M)*p};for(let V=0;V<d.length;V++)if(l.type!==1)d[V]=KA(d[V],$,1);else{const X=[];for(const J of d[V])J.x<0||J.x>=p||J.y<0||J.y>=p||($(J),X.push(J));d[V]=X}}for(const b of d)for(const E of b)tU(E,_);return d}function wf(l,o){return{type:l.type,id:l.id,properties:l.properties,geometry:o?$u(l):[]}}function h0(l,o,u,d,p){l.emplaceBack(2*o+(d+1)/2,2*u+(p+1)/2)}function d0(l,o,u){l.emplaceBack(o.x,o.y,o.z,u[0]*16384,u[1]*16384,u[2]*16384)}class pw{constructor(o){this.zoom=o.zoom,this.overscaling=o.overscaling,this.layers=o.layers,this.layerIds=this.layers.map(u=>u.id),this.index=o.index,this.hasPattern=!1,this.projection=o.projection,this.layoutVertexArray=new Zt,this.indexArray=new Cn,this.segments=new yo,this.programConfigurations=new gf(o.layers,o.zoom),this.stateDependentLayerIds=this.layers.filter(u=>u.isStateDependent()).map(u=>u.id)}populate(o,u,d,p){const _=this.layers[0],b=[];let E=null;_.type==="circle"&&(E=_.layout.get("circle-sort-key"));for(const{feature:M,id:F,index:$,sourceLayerIndex:V}of o){const X=this.layers[0]._featureFilter.needGeometry,J=wf(M,X);if(!this.layers[0]._featureFilter.filter(new z(this.zoom),J,d))continue;const re=E?E.evaluate(J,{},d):void 0,pe={id:F,properties:M.properties,type:M.type,sourceLayerIndex:V,index:$,geometry:X?J.geometry:$u(M,d,p),patterns:{},sortKey:re};b.push(pe)}E&&b.sort((M,F)=>M.sortKey-F.sortKey);let k=null;p.projection.name==="globe"&&(this.globeExtVertexArray=new Jt,k=p.projection);for(const M of b){const{geometry:F,index:$,sourceLayerIndex:V}=M,X=o[$].feature;this.addFeature(M,F,$,u.availableImages,d,k),u.featureIndex.insert(X,F,$,V,this.index)}}update(o,u,d,p){this.stateDependentLayers.length&&this.programConfigurations.updatePaintArrays(o,u,this.stateDependentLayers,d,p)}isEmpty(){return this.layoutVertexArray.length===0}uploadPending(){return!this.uploaded||this.programConfigurations.needsUpload}upload(o){this.uploaded||(this.layoutVertexBuffer=o.createVertexBuffer(this.layoutVertexArray,jj.members),this.indexBuffer=o.createIndexBuffer(this.indexArray),this.globeExtVertexArray&&(this.globeExtVertexBuffer=o.createVertexBuffer(this.globeExtVertexArray,Uj.members))),this.programConfigurations.upload(o),this.uploaded=!0}destroy(){this.layoutVertexBuffer&&(this.layoutVertexBuffer.destroy(),this.indexBuffer.destroy(),this.programConfigurations.destroy(),this.segments.destroy(),this.globeExtVertexBuffer&&this.globeExtVertexBuffer.destroy())}addFeature(o,u,d,p,_,b){for(const E of u)for(const k of E){const M=k.x,F=k.y;if(M<0||M>=Rn||F<0||F>=Rn)continue;if(b){const X=b.projectTilePoint(M,F,_),J=b.upVector(_,M,F),re=this.globeExtVertexArray;d0(re,X,J),d0(re,X,J),d0(re,X,J),d0(re,X,J)}const $=this.segments.prepareSegment(4,this.layoutVertexArray,this.indexArray,o.sortKey),V=$.vertexLength;h0(this.layoutVertexArray,M,F,-1,-1),h0(this.layoutVertexArray,M,F,1,-1),h0(this.layoutVertexArray,M,F,1,1),h0(this.layoutVertexArray,M,F,-1,1),this.indexArray.emplaceBack(V,V+1,V+2),this.indexArray.emplaceBack(V,V+2,V+3),$.vertexLength+=4,$.primitiveLength+=2}this.programConfigurations.populatePaintArrays(this.layoutVertexArray.length,o,d,{},p,_)}}function JA(l,o){for(let u=0;u<l.length;u++)if(Tf(o,l[u]))return!0;for(let u=0;u<o.length;u++)if(Tf(l,o[u]))return!0;return!!mw(l,o)}function nU(l,o,u){return!!Tf(l,o)||!!gw(o,l,u)}function eP(l,o){if(l.length===1)return nP(o,l[0]);for(let u=0;u<o.length;u++){const d=o[u];for(let p=0;p<d.length;p++)if(Tf(l,d[p]))return!0}for(let u=0;u<l.length;u++)if(nP(o,l[u]))return!0;for(let u=0;u<o.length;u++)if(mw(l,o[u]))return!0;return!1}function rU(l,o,u){if(l.length>1){if(mw(l,o))return!0;for(let d=0;d<o.length;d++)if(gw(o[d],l,u))return!0}for(let d=0;d<l.length;d++)if(gw(l[d],o,u))return!0;return!1}function mw(l,o){if(l.length===0||o.length===0)return!1;for(let u=0;u<l.length-1;u++){const d=l[u],p=l[u+1];for(let _=0;_<o.length-1;_++)if(iU(d,p,o[_],o[_+1]))return!0}return!1}function iU(l,o,u,d){return mt(l,u,d)!==mt(o,u,d)&&mt(l,o,u)!==mt(l,o,d)}function gw(l,o,u){const d=u*u;if(o.length===1)return l.distSqr(o[0])<d;for(let p=1;p<o.length;p++)if(tP(l,o[p-1],o[p])<d)return!0;return!1}function tP(l,o,u){const d=o.distSqr(u);if(d===0)return l.distSqr(o);const p=((l.x-o.x)*(u.x-o.x)+(l.y-o.y)*(u.y-o.y))/d;return l.distSqr(p<0?o:p>1?u:u.sub(o)._mult(p)._add(o))}function nP(l,o){let u,d,p,_=!1;for(let b=0;b<l.length;b++){u=l[b];for(let E=0,k=u.length-1;E<u.length;k=E++)d=u[E],p=u[k],d.y>o.y!=p.y>o.y&&o.x<(p.x-d.x)*(o.y-d.y)/(p.y-d.y)+d.x&&(_=!_)}return _}function Tf(l,o){let u=!1;for(let d=0,p=l.length-1;d<l.length;p=d++){const _=l[d],b=l[p];_.y>o.y!=b.y>o.y&&o.x<(b.x-_.x)*(o.y-_.y)/(b.y-_.y)+_.x&&(u=!u)}return u}function rP(l,o,u,d,p){for(const b of l)if(o<=b.x&&u<=b.y&&d>=b.x&&p>=b.y)return!0;const _=[new Y(o,u),new Y(o,p),new Y(d,p),new Y(d,u)];if(l.length>2){for(const b of _)if(Tf(l,b))return!0}for(let b=0;b<l.length-1;b++)if(oU(l[b],l[b+1],_))return!0;return!1}function oU(l,o,u){const d=u[0],p=u[2];if(l.x<d.x&&o.x<d.x||l.x>p.x&&o.x>p.x||l.y<d.y&&o.y<d.y||l.y>p.y&&o.y>p.y)return!1;const _=mt(l,o,u[0]);return _!==mt(l,o,u[1])||_!==mt(l,o,u[2])||_!==mt(l,o,u[3])}function Kp(l,o,u){const d=o.paint.get(l).value;return d.kind==="constant"?d.value:u.programConfigurations.get(o.id).getMaxValue(l)}function f0(l){return Math.sqrt(l[0]*l[0]+l[1]*l[1])}
120function iP(l,o,u,d,p){if(!o[0]&&!o[1])return l;const _=Y.convert(o)._mult(p);u==="viewport"&&_._rotate(-d);const b=[];for(let E=0;E<l.length;E++)b.push(l[E].sub(_));return b}function oP(l,o,u,d){const p=Y.convert(l)._mult(d);return o==="viewport"&&p._rotate(-u),p}xn(pw,"CircleBucket",{omit:["layers"]});const aU=new Le({"circle-sort-key":new ye(Pt.layout_circle["circle-sort-key"])});var sU={paint:new Le({"circle-radius":new ye(Pt.paint_circle["circle-radius"]),"circle-color":new ye(Pt.paint_circle["circle-color"]),"circle-blur":new ye(Pt.paint_circle["circle-blur"]),"circle-opacity":new ye(Pt.paint_circle["circle-opacity"]),"circle-translate":new te(Pt.paint_circle["circle-translate"]),"circle-translate-anchor":new te(Pt.paint_circle["circle-translate-anchor"]),"circle-pitch-scale":new te(Pt.paint_circle["circle-pitch-scale"]),"circle-pitch-alignment":new te(Pt.paint_circle["circle-pitch-alignment"]),"circle-stroke-width":new ye(Pt.paint_circle["circle-stroke-width"]),"circle-stroke-color":new ye(Pt.paint_circle["circle-stroke-color"]),"circle-stroke-opacity":new ye(Pt.paint_circle["circle-stroke-opacity"])}),layout:aU};function aP(l,o,u,d,p,_,b,E,k){if(_&&l.queryGeometry.isAboveHorizon)return!1;_&&(k*=l.pixelToTileUnitsFactor);const M=l.tileID.canonical,F=u.projection.upVectorScale(M,u.center.lat,u.worldSize).metersToTile;for(const $ of o)for(const V of $){const X=V.add(E),J=p&&u.elevation?u.elevation.exaggeration()*p.getElevationAt(X.x,X.y,!0):0,re=u.projection.projectTilePoint(X.x,X.y,M);if(J>0){const ke=u.projection.upVector(M,X.x,X.y);re.x+=ke[0]*F*J,re.y+=ke[1]*F*J,re.z+=ke[2]*F*J}const pe=_?X:lU(re.x,re.y,re.z,d),Ce=_?l.tilespaceRays.map(ke=>uU(ke,J)):l.queryGeometry.screenGeometry,ze=vf([],[re.x,re.y,re.z,1],d);if(!b&&_?k*=ze[3]/u.cameraToCenterDistance:b&&!_&&(k*=u.cameraToCenterDistance/ze[3]),_){const ke=_a((V.y/Rn+M.y)/(1<<M.z));k/=u.projection.pixelsPerMeter(ke,1)/pc(1,ke)}if(nU(Ce,pe,k))return!0}return!1}function lU(l,o,u,d){const p=vf([],[l,o,u,1],d);return new Y(p[0]/p[3],p[1]/p[3])}const sP=Wp(0,0,0),cU=Wp(0,0,1);function uU(l,o){const u=J1();return sP[2]=o,l.intersectsPlane(sP,cU,u),new Y(u[0],u[1])}class lP extends pw{}function cP(l,{width:o,height:u},d,p){if(p){if(p instanceof Uint8ClampedArray)p=new Uint8Array(p.buffer);else if(p.length!==o*u*d)throw new RangeError("mismatched image size")}else p=new Uint8Array(o*u*d);return l.width=o,l.height=u,l.data=p,l}function uP(l,o,u){const{width:d,height:p}=o;d===l.width&&p===l.height||(yw(l,o,{x:0,y:0},{x:0,y:0},{width:Math.min(l.width,d),height:Math.min(l.height,p)},u),l.width=d,l.height=p,l.data=o.data)}function yw(l,o,u,d,p,_){if(p.width===0||p.height===0)return o;if(p.width>l.width||p.height>l.height||u.x>l.width-p.width||u.y>l.height-p.height)throw new RangeError("out of range source coordinates for image copy");if(p.width>o.width||p.height>o.height||d.x>o.width-p.width||d.y>o.height-p.height)throw new RangeError("out of range destination coordinates for image copy");const b=l.data,E=o.data;for(let k=0;k<p.height;
120k++){const M=((u.y+k)*l.width+u.x)*_,F=((d.y+k)*o.width+d.x)*_;for(let $=0;$<p.width*_;$++)E[F+$]=b[M+$]}return o}xn(lP,"HeatmapBucket",{omit:["layers"]});class ju{constructor(o,u){cP(this,o,1,u)}resize(o){uP(this,new ju(o),1)}clone(){return new ju({width:this.width,height:this.height},new Uint8Array(this.data))}static copy(o,u,d,p,_){yw(o,u,d,p,_,1)}}class As{constructor(o,u){cP(this,o,4,u)}resize(o){uP(this,new As(o),4)}replace(o,u){u?this.data.set(o):this.data=o instanceof Uint8ClampedArray?new Uint8Array(o.buffer):o}clone(){return new As({width:this.width,height:this.height},new Uint8Array(this.data))}static copy(o,u,d,p,_){yw(o,u,d,p,_,4)}}xn(ju,"AlphaImage"),xn(As,"RGBAImage");var hU={paint:new Le({"heatmap-radius":new ye(Pt.paint_heatmap["heatmap-radius"]),"heatmap-weight":new ye(Pt.paint_heatmap["heatmap-weight"]),"heatmap-intensity":new te(Pt.paint_heatmap["heatmap-intensity"]),"heatmap-color":new Oe(Pt.paint_heatmap["heatmap-color"]),"heatmap-opacity":new te(Pt.paint_heatmap["heatmap-opacity"])})};function _w(l){const o={},u=l.resolution||256,d=l.clips?l.clips.length:1,p=l.image||new As({width:u,height:d}),_=(b,E,k)=>{o[l.evaluationKey]=k;const M=l.expression.evaluate(o);p.data[b+E+0]=Math.floor(255*M.r/M.a),p.data[b+E+1]=Math.floor(255*M.g/M.a),p.data[b+E+2]=Math.floor(255*M.b/M.a),p.data[b+E+3]=Math.floor(255*M.a)};if(l.clips)for(let b=0,E=0;b<d;++b,E+=4*u)for(let k=0,M=0;k<u;k++,M+=4){const F=k/(u-1),{start:$,end:V}=l.clips[b];_(E,M,$*(1-F)+V*F)}else for(let b=0,E=0;b<u;b++,E+=4)_(0,E,b/(u-1));return p}var dU={paint:new Le({"hillshade-illumination-direction":new te(Pt.paint_hillshade["hillshade-illumination-direction"]),"hillshade-illumination-anchor":new te(Pt.paint_hillshade["hillshade-illumination-anchor"]),"hillshade-exaggeration":new te(Pt.paint_hillshade["hillshade-exaggeration"]),"hillshade-shadow-color":new te(Pt.paint_hillshade["hillshade-shadow-color"]),"hillshade-highlight-color":new te(Pt.paint_hillshade["hillshade-highlight-color"]),"hillshade-accent-color":new te(Pt.paint_hillshade["hillshade-accent-color"])})};const fU=et([{name:"a_pos",components:2,type:"Int16"}],4),{members:pU}=fU;var vw={exports:{}};function p0(l,o,u){u=u||2;var d,p,_,b,E,k,M,F=o&&o.length,$=F?o[0]*u:l.length,V=hP(l,0,$,u,!0),X=[];if(!V||V.next===V.prev)return X;if(F&&(V=function(re,pe,Ce,ze){var ke,Be,We,Ge=[];for(ke=0,Be=pe.length;ke<Be;ke++)(We=hP(re,pe[ke]*ze,ke<Be-1?pe[ke+1]*ze:re.length,ze,!1))===We.next&&(We.steiner=!0),Ge.push(wU(We));for(Ge.sort(vU),ke=0;ke<Ge.length;ke++)Ce=bU(Ge[ke],Ce);return Ce}(l,o,V,u)),l.length>80*u){d=_=l[0],p=b=l[1];for(var J=u;J<$;J+=u)(E=l[J])<d&&(d=E),(k=l[J+1])<p&&(p=k),E>_&&(_=E),k>b&&(b=k);M=(M=Math.max(_-d,b-p))!==0?32767/M:0}return cy(V,X,u,d,p,M,0),X}function hP(l,o,u,d,p){var _,b;if(p===ww(l,o,u,d)>0)for(_=o;_<u;_+=d)b=pP(_,l[_],l[_+1],b);else for(_=u-d;_>=o;_-=d)b=pP(_,l[_],l[_+1],b);return b&&m0(b,b.next)&&(hy(b),b=b.next),b}function Ef(l,o){if(!l)return l;o||(o=l);var u,d=l;do if(u=!1,d.steiner||!m0(d,d.next)&&_o(d.prev,d,d.next)!==0)d=d.next;else{if(hy(d),(d=o=d.prev)===d.next)break;u=!0}while(u||d!==o);return o}function cy(l,o,u,d,p,_,b){if(l){!b&&_&&function(F,$,V,X){var J=F;do J.z===0&&(J.z=bw(J.x,J.y,$,V,X)),J.prevZ=J.prev,J.nextZ=J.next,J=J.next;while(J!==F);J.prevZ.nextZ=null,J.prevZ=null,function(re){var pe,Ce,ze,ke,Be,We,Ge,vt,ft=1;do{for(Ce=re,re=null,Be=null,We=0;Ce;){for(We++,ze=Ce,Ge=0,pe=0;pe<ft&&(Ge++,ze=ze.nextZ);pe++);for(vt=ft;Ge>0||vt>0&&ze;)Ge!==0&&(vt===0||!ze||Ce.z<=ze.z)?(ke=Ce,Ce=Ce.nextZ,Ge--):(ke=ze,ze=ze.nextZ,vt--),Be?Be.nextZ=ke:re=ke,ke.prevZ=Be,Be=ke;Ce=ze}Be.nextZ=null,ft*=2}while(We>1)}(J)}(l,d,p,_);for(var E,k,M=l;l.prev!==l.next;)if(E=l.prev,k=l.next,_?gU(l,d,p,_):mU(l))o.push(E.i/u|0),o.push(l.i/u|0),o.push(k.i/u|0),hy(l),l=k.next,M=k.next;else if((l=k)===M){b?b===1?cy(l=yU(Ef(l),o,u),o,u,d,p,_,2):b===2&&_U(l,o,u,d,p,_):cy(Ef(l),o,u,d,p,_,1);break}}}function mU(l){var o=l.prev,u=l,d=l.next;if(_o(o,u,d)>=0)return!1;for(var p=o.x,_=u.x,b=d.x,E=o.y,k=u.y,M=d.y,F=p<_?p<b?p:b:_<b?_:b,$=E<k?E<M?E:M:k<M?k:M,V=p>_?p>b?p:b:_>b?_:b,X=E>k?E>M?E:M:k>M?k:M,J=d.next;J!==o;){if(J.x>=F&&J.x<=V&&J.y>=$&&J.y<=X&&Qp(p,E,_,k,b,M,J.x,J.y)&&_o(J.prev,J,J.next)>=0)return!1;J=J.next}return!0}function gU(l,o,u,d){var p=l.prev,_=l,b=l.next;if(_o(p,_,b)>=0)return!1;for(var E=p.x,k=_.x,M=b.x,F=p.y,$=_.y,V=b.y,X=E<k?E<M?E:M:k<M?k:M,J=F<$?F<V?F:V:$<V?$:V,re=E>k?E>M?E:M:k>M?k:M,pe=F>$?F>V?F:V:$>V?$:V,Ce=bw(X,J,o,u,d),ze=bw(re,pe,o,u,d),ke=l.prevZ,Be=l.nextZ;ke&&ke.z>=Ce&&Be&&Be.z<=ze;){if(ke.x>=X&&ke.x<=re&&ke.y>=J&&ke.y<=pe&&ke!==p&&ke!==b&&Qp(E,F,k,$,M,V,ke.x,ke.y)&&_o(ke.prev,ke,ke.next)>=0||(ke=ke.prevZ,Be.x>=X&&Be.x<=re&&Be.y>=J&&Be.y<=pe&&Be!==p&&Be!==b&&Qp(E,F,k,$,M,V,Be.x,Be.y)&&_o(Be.prev,Be,Be.next)>=0))return!1;Be=Be.nextZ}for(;ke&&ke.z>=Ce;){if(ke.x>=X&&ke.x<=re&&ke.y>=J&&ke.y<=pe&&ke!==p&&ke!==b&&Qp(E,F,k,$,M,V,ke.x,ke.y)&&_o(ke.prev,ke,ke.next)>=0)return!1;ke=ke.prevZ}for(;Be&&Be.z<=ze;){if(Be.x>=X&&Be.x<=re&&Be.y>=J&&Be.y<=pe&&Be!==p&&Be!==b&&Qp(E,F,k,$,M,V,Be.x,Be.y)&&_o(Be.prev,Be,Be.next)>=0)return!1;Be=Be.nextZ}return!0}function yU(l,o,u){var d=l;do{var p=d.prev,_=d.next.next;!m0(p,_)&&dP(p,d,d.next,_)&&uy(p,_)&&uy(_,p)&&(o.push(p.i/u|0),o.push(d.i/u|0),o.push(_.i/u|0),hy(d),hy(d.next),d=l=_),d=d.next}while(d!==l);return Ef(d)}function _U(l,o,u,d,p,_){var b=l;do{for(var E=b.next.next;E!==b.prev;){if(b.i!==E.i&&TU(b,E)){var k=fP(b,E);return b=Ef(b,b.next),k=Ef(k,k.next),cy(b,o,u,d,p,_,0),void cy(k,o,u,d,p,_,0)}E=E.next}b=b.next}
120while(b!==l)}function vU(l,o){return l.x-o.x}function bU(l,o){var u=function(p,_){var b,E=_,k=p.x,M=p.y,F=-1/0;do{if(M<=E.y&&M>=E.next.y&&E.next.y!==E.y){var $=E.x+(M-E.y)*(E.next.x-E.x)/(E.next.y-E.y);if($<=k&&$>F&&(F=$,b=E.x<E.next.x?E:E.next,$===k))return b}E=E.next}while(E!==_);if(!b)return null;var V,X=b,J=b.x,re=b.y,pe=1/0;E=b;do k>=E.x&&E.x>=J&&k!==E.x&&Qp(M<re?k:F,M,J,re,M<re?F:k,M,E.x,E.y)&&(V=Math.abs(M-E.y)/(k-E.x),uy(E,p)&&(V<pe||V===pe&&(E.x>b.x||E.x===b.x&&xU(b,E)))&&(b=E,pe=V)),E=E.next;while(E!==X);return b}(l,o);if(!u)return o;var d=fP(u,l);return Ef(d,d.next),Ef(u,u.next)}function xU(l,o){return _o(l.prev,l,o.prev)<0&&_o(o.next,l,l.next)<0}function bw(l,o,u,d,p){return(l=1431655765&((l=858993459&((l=252645135&((l=16711935&((l=(l-u)*p|0)|l<<8))|l<<4))|l<<2))|l<<1))|(o=1431655765&((o=858993459&((o=252645135&((o=16711935&((o=(o-d)*p|0)|o<<8))|o<<4))|o<<2))|o<<1))<<1}function wU(l){var o=l,u=l;do(o.x<u.x||o.x===u.x&&o.y<u.y)&&(u=o),o=o.next;while(o!==l);return u}function Qp(l,o,u,d,p,_,b,E){return(p-b)*(o-E)>=(l-b)*(_-E)&&(l-b)*(d-E)>=(u-b)*(o-E)&&(u-b)*(_-E)>=(p-b)*(d-E)}function TU(l,o){return l.next.i!==o.i&&l.prev.i!==o.i&&!function(u,d){var p=u;do{if(p.i!==u.i&&p.next.i!==u.i&&p.i!==d.i&&p.next.i!==d.i&&dP(p,p.next,u,d))return!0;p=p.next}while(p!==u);return!1}(l,o)&&(uy(l,o)&&uy(o,l)&&function(u,d){var p=u,_=!1,b=(u.x+d.x)/2,E=(u.y+d.y)/2;do p.y>E!=p.next.y>E&&p.next.y!==p.y&&b<(p.next.x-p.x)*(E-p.y)/(p.next.y-p.y)+p.x&&(_=!_),p=p.next;while(p!==u);return _}(l,o)&&(_o(l.prev,l,o.prev)||_o(l,o.prev,o))||m0(l,o)&&_o(l.prev,l,l.next)>0&&_o(o.prev,o,o.next)>0)}function _o(l,o,u){return(o.y-l.y)*(u.x-o.x)-(o.x-l.x)*(u.y-o.y)}function m0(l,o){return l.x===o.x&&l.y===o.y}function dP(l,o,u,d){var p=y0(_o(l,o,u)),_=y0(_o(l,o,d)),b=y0(_o(u,d,l)),E=y0(_o(u,d,o));return p!==_&&b!==E||!(p!==0||!g0(l,u,o))||!(_!==0||!g0(l,d,o))||!(b!==0||!g0(u,l,d))||!(E!==0||!g0(u,o,d))}function g0(l,o,u){return o.x<=Math.max(l.x,u.x)&&o.x>=Math.min(l.x,u.x)&&o.y<=Math.max(l.y,u.y)&&o.y>=Math.min(l.y,u.y)}function y0(l){return l>0?1:l<0?-1:0}function uy(l,o){return _o(l.prev,l,l.next)<0?_o(l,o,l.next)>=0&&_o(l,l.prev,o)>=0:_o(l,o,l.prev)<0||_o(l,l.next,o)<0}function fP(l,o){var u=new xw(l.i,l.x,l.y),d=new xw(o.i,o.x,o.y),p=l.next,_=o.prev;return l.next=o,o.prev=l,u.next=p,p.prev=u,d.next=u,u.prev=d,_.next=d,d.prev=_,d}function pP(l,o,u,d){var p=new xw(l,o,u);return d?(p.next=d.next,p.prev=d,d.next.prev=p,d.next=p):(p.prev=p,p.next=p),p}function hy(l){l.next.prev=l.prev,l.prev.next=l.next,l.prevZ&&(l.prevZ.nextZ=l.nextZ),l.nextZ&&(l.nextZ.prevZ=l.prevZ)}function xw(l,o,u){this.i=l,this.x=o,this.y=u,this.prev=null,this.next=null,this.z=0,this.prevZ=null,this.nextZ=null,this.steiner=!1}function ww(l,o,u,d){for(var p=0,_=o,b=u-d;_<u;_+=d)p+=(l[b]-l[_])*(l[_+1]+l[b+1]),b=_;return p}vw.exports=p0,vw.exports.default=p0,p0.deviation=function(l,o,u,d){var p=o&&o.length,_=Math.abs(ww(l,0,p?o[0]*u:l.length,u));if(p)for(var b=0,E=o.length;b<E;b++)_-=Math.abs(ww(l,o[b]*u,b<E-1?o[b+1]*u:l.length,u));var k=0;for(b=0;b<d.length;b+=3){var M=d[b]*u,F=d[b+1]*u,$=d[b+2]*u;k+=Math.abs((l[M]-l[$])*(l[F+1]-l[M+1])-(l[M]-l[F])*(l[$+1]-l[M+1]))}return _===0&&k===0?0:Math.abs((k-_)/_)},p0.flatten=function(l){for(var o=l[0][0].length,u={vertices:[],holes:[],dimensions:o},d=0,p=0;p<l.length;p++){for(var _=0;_<l[p].length;_++)for(var b=0;b<o;b++)u.vertices.push(l[p][_][b]);p>0&&u.holes.push(d+=l[p-1].length)}return u};var Tw=j(vw.exports);function EU(l,o,u,d,p){mP(l,o,u||0,d||l.length-1,p||SU)}function mP(l,o,u,d,p){for(;d>u;){if(d-u>600){var _=d-u+1,b=o-u+1,E=Math.log(_),k=.5*Math.exp(2*E/3),M=.5*Math.sqrt(E*k*(_-k)/_)*(b-_/2<0?-1:1);mP(l,o,Math.max(u,Math.floor(o-b*k/_+M)),Math.min(d,Math.floor(o+(_-b)*k/_+M)),p)}var F=l[o],$=u,V=d;for(dy(l,u,o),p(l[d],F)>0&&dy(l,u,d);$<V;){for(dy(l,$,V),$++,V--;p(l[$],F)<0;)$++;for(;p(l[V],F)>0;)V--}p(l[u],F)===0?dy(l,u,V):dy(l,++V,d),V<=o&&(u=V+1),o<=V&&(d=V-1)}}function dy(l,o,u){var d=l[o];l[o]=l[u],l[u]=d}function SU(l,o){return l<o?-1:l>o?1:0}function Ew(l,o){const u=l.length;if(u<=1)return[l];const d=[];let p,_;for(let b=0;b<u;b++){const E=Vt(l[b]);E!==0&&(l[b].area=Math.abs(E),_===void 0&&(_=E<0),_===E<0?(p&&d.push(p),p=[l[b]]):p.push(l[b]))}if(p&&d.push(p),o>1)for(let b=0;b<d.length;b++)d[b].length<=o||(EU(d[b],o,1,d[b].length-1,CU),d[b]=d[b].slice(0,o));return d}function CU(l,o){return o.area-l.area}function Sw(l,o,u){const d=u.patternDependencies;let p=!1;for(const _ of o){const b=_.paint.get(`${l}-pattern`);b.isConstant()||(p=!0);const E=b.constantOr(null);E&&(p=!0,d[E]=!0)}return p}function Cw(l,o,u,d,p){const _=p.patternDependencies;for(const b of o){const E=b.paint.get(`${l}-pattern`).value;if(E.kind!=="constant"){let k=E.evaluate({zoom:d},u,{},p.availableImages);k=k&&k.name?k.name:k,_[k]=!0,u.patterns[b.id]=k}}return u}class _0{constructor(o){this.zoom=o.zoom,this.overscaling=o.overscaling,this.layers=o.layers,this.layerIds=this.layers.map(u=>u.id),this.index=o.index,this.hasPattern=!1,this.patternFeatures=[],this.layoutVertexArray=new Zt,this.indexArray=new Cn,this.indexArray2=new Yo,this.programConfigurations=new gf(o.layers,o.zoom),this.segments=new yo,this.segments2=new yo,this.stateDependentLayerIds=this.layers.filter(u=>u.isStateDependent()).map(u=>u.id),this.projection=o.projection}populate(o,u,d,p){this.hasPattern=Sw("fill",this.layers,u);const _=this.layers[0].layout.get("fill-sort-key"),b=[];for(const{feature:E,id:k,index:M,sourceLayerIndex:F}of o){const $=this.layers[0]._featureFilter.needGeometry,V=wf(E,$);if(!this.layers[0]._featureFilter.filter(new z(this.zoom),V,d))continue;const X=_?_.evaluate(V,{}
120,d,u.availableImages):void 0,J={id:k,properties:E.properties,type:E.type,sourceLayerIndex:F,index:M,geometry:$?V.geometry:$u(E,d,p),patterns:{},sortKey:X};b.push(J)}_&&b.sort((E,k)=>E.sortKey-k.sortKey);for(const E of b){const{geometry:k,index:M,sourceLayerIndex:F}=E;if(this.hasPattern){const $=Cw("fill",this.layers,E,this.zoom,u);this.patternFeatures.push($)}else this.addFeature(E,k,M,d,{},u.availableImages);u.featureIndex.insert(o[M].feature,k,M,F,this.index)}}update(o,u,d,p){this.stateDependentLayers.length&&this.programConfigurations.updatePaintArrays(o,u,this.stateDependentLayers,d,p)}addFeatures(o,u,d,p,_){for(const b of this.patternFeatures)this.addFeature(b,b.geometry,b.index,u,d,p)}isEmpty(){return this.layoutVertexArray.length===0}uploadPending(){return!this.uploaded||this.programConfigurations.needsUpload}upload(o){this.uploaded||(this.layoutVertexBuffer=o.createVertexBuffer(this.layoutVertexArray,pU),this.indexBuffer=o.createIndexBuffer(this.indexArray),this.indexBuffer2=o.createIndexBuffer(this.indexArray2)),this.programConfigurations.upload(o),this.uploaded=!0}destroy(){this.layoutVertexBuffer&&(this.layoutVertexBuffer.destroy(),this.indexBuffer.destroy(),this.indexBuffer2.destroy(),this.programConfigurations.destroy(),this.segments.destroy(),this.segments2.destroy())}addFeature(o,u,d,p,_,b=[]){for(const E of Ew(u,500)){let k=0;for(const J of E)k+=J.length;const M=this.segments.prepareSegment(k,this.layoutVertexArray,this.indexArray),F=M.vertexLength,$=[],V=[];for(const J of E){if(J.length===0)continue;J!==E[0]&&V.push($.length/2);const re=this.segments2.prepareSegment(J.length,this.layoutVertexArray,this.indexArray2),pe=re.vertexLength;this.layoutVertexArray.emplaceBack(J[0].x,J[0].y),this.indexArray2.emplaceBack(pe+J.length-1,pe),$.push(J[0].x),$.push(J[0].y);for(let Ce=1;Ce<J.length;Ce++)this.layoutVertexArray.emplaceBack(J[Ce].x,J[Ce].y),this.indexArray2.emplaceBack(pe+Ce-1,pe+Ce),$.push(J[Ce].x),$.push(J[Ce].y);re.vertexLength+=J.length,re.primitiveLength+=J.length}const X=Tw($,V);for(let J=0;J<X.length;J+=3)this.indexArray.emplaceBack(F+X[J],F+X[J+1],F+X[J+2]);M.vertexLength+=k,M.primitiveLength+=X.length/3}this.programConfigurations.populatePaintArrays(this.layoutVertexArray.length,o,d,_,b,p)}}xn(_0,"FillBucket",{omit:["layers","patternFeatures"]});const kU=new Le({"fill-sort-key":new ye(Pt.layout_fill["fill-sort-key"])});var AU={paint:new Le({"fill-antialias":new te(Pt.paint_fill["fill-antialias"]),"fill-opacity":new ye(Pt.paint_fill["fill-opacity"]),"fill-color":new ye(Pt.paint_fill["fill-color"]),"fill-outline-color":new ye(Pt.paint_fill["fill-outline-color"]),"fill-translate":new te(Pt.paint_fill["fill-translate"]),"fill-translate-anchor":new te(Pt.paint_fill["fill-translate-anchor"]),"fill-pattern":new ye(Pt.paint_fill["fill-pattern"])}),layout:kU};const PU=et([{name:"a_pos_normal_ed",components:4,type:"Int16"}]),MU=et([{name:"a_centroid_pos",components:2,type:"Uint16"}]),IU=et([{name:"a_pos_3",components:3,type:"Int16"},{name:"a_pos_normal_3",components:3,type:"Int16"}]),{members:OU}=PU;var v0={},DU=Z,gP=Jp;function Jp(l,o,u,d,p){this.properties={},this.extent=u,this.type=0,this._pbf=l,this._geometry=-1,this._keys=d,this._values=p,l.readFields(LU,this,o)}function LU(l,o,u){l==1?o.id=u.readVarint():l==2?function(d,p){for(var _=d.readVarint()+d.pos;d.pos<_;){var b=p._keys[d.readVarint()],E=p._values[d.readVarint()];p.properties[b]=E}}(u,o):l==3?o.type=u.readVarint():l==4&&(o._geometry=u.pos)}function RU(l){for(var o,u,d=0,p=0,_=l.length,b=_-1;p<_;b=p++)d+=((u=l[b]).x-(o=l[p]).x)*(o.y+u.y);return d}Jp.types=["Unknown","Point","LineString","Polygon"],Jp.prototype.loadGeometry=function(){var l=this._pbf;l.pos=this._geometry;for(var o,u=l.readVarint()+l.pos,d=1,p=0,_=0,b=0,E=[];l.pos<u;){if(p<=0){var k=l.readVarint();d=7&k,p=k>>3}if(p--,d===1||d===2)_+=l.readSVarint(),b+=l.readSVarint(),d===1&&(o&&E.push(o),o=[]),o.push(new DU(_,b));else{if(d!==7)throw new Error("unknown command "+d);o&&o.push(o[0].clone())}}return o&&E.push(o),E},Jp.prototype.bbox=function(){var l=this._pbf;l.pos=this._geometry;for(var o=l.readVarint()+l.pos,u=1,d=0,p=0,_=0,b=1/0,E=-1/0,k=1/0,M=-1/0;l.pos<o;){if(d<=0){var F=l.readVarint();u=7&F,d=F>>3}if(d--,u===1||u===2)(p+=l.readSVarint())<b&&(b=p),p>E&&(E=p),(_+=l.readSVarint())<k&&(k=_),_>M&&(M=_);else if(u!==7)throw new Error("unknown command "+u)}return[b,k,E,M]},Jp.prototype.toGeoJSON=function(l,o,u){var d,p,_=this.extent*Math.pow(2,u),b=this.extent*l,E=this.extent*o,k=this.loadGeometry(),M=Jp.types[this.type];function F(X){for(var J=0;J<X.length;J++){var re=X[J];X[J]=[360*(re.x+b)/_-180,360/Math.PI*Math.atan(Math.exp((180-360*(re.y+E)/_)*Math.PI/180)
120)-90]}}switch(this.type){case 1:var $=[];for(d=0;d<k.length;d++)$[d]=k[d][0];F(k=$);break;case 2:for(d=0;d<k.length;d++)F(k[d]);break;case 3:for(k=function(X){var J=X.length;if(J<=1)return[X];for(var re,pe,Ce=[],ze=0;ze<J;ze++){var ke=RU(X[ze]);ke!==0&&(pe===void 0&&(pe=ke<0),pe===ke<0?(re&&Ce.push(re),re=[X[ze]]):re.push(X[ze]))}return re&&Ce.push(re),Ce}(k),d=0;d<k.length;d++)for(p=0;p<k[d].length;p++)F(k[d][p])}k.length===1?k=k[0]:M="Multi"+M;var V={type:"Feature",geometry:{type:M,coordinates:k},properties:this.properties};return"id"in this&&(V.id=this.id),V};var FU=gP,yP=_P;function _P(l,o){this.version=1,this.name=null,this.extent=4096,this.length=0,this._pbf=l,this._keys=[],this._values=[],this._features=[],l.readFields(BU,this,o),this.length=this._features.length}function BU(l,o,u){l===15?o.version=u.readVarint():l===1?o.name=u.readString():l===5?o.extent=u.readVarint():l===2?o._features.push(u.pos):l===3?o._keys.push(u.readString()):l===4&&o._values.push(function(d){for(var p=null,_=d.readVarint()+d.pos;d.pos<_;){var b=d.readVarint()>>3;p=b===1?d.readString():b===2?d.readFloat():b===3?d.readDouble():b===4?d.readVarint64():b===5?d.readVarint():b===6?d.readSVarint():b===7?d.readBoolean():null}return p}(u))}_P.prototype.feature=function(l){if(l<0||l>=this._features.length)throw new Error("feature index out of bounds");this._pbf.pos=this._features[l];var o=this._pbf.readVarint()+this._pbf.pos;return new FU(this._pbf,o,this.extent,this._keys,this._values)};var zU=yP;function NU(l,o,u){if(l===3){var d=new zU(u,u.readVarint()+u.pos);d.length&&(o[d.name]=d)}}var kw=v0.VectorTile=function(l,o){this.layers=l.readFields(NU,{},o)},b0=v0.VectorTileFeature=gP;function x0(l,o,u,d){const p=[],_=d===0?(b,E,k,M,F,$)=>{b.push(new Y($,k+($-E)/(M-E)*(F-k)))}:(b,E,k,M,F,$)=>{b.push(new Y(E+($-k)/(F-k)*(M-E),$))};for(const b of l){const E=[];for(const k of b){if(k.length<=2)continue;const M=[];for(let V=0;V<k.length-1;V++){const X=k[V].x,J=k[V].y,re=k[V+1].x,pe=k[V+1].y,Ce=d===0?X:J,ze=d===0?re:pe;Ce<o?ze>o&&_(M,X,J,re,pe,o):Ce>u?ze<u&&_(M,X,J,re,pe,u):M.push(k[V]),ze<o&&Ce>=o&&_(M,X,J,re,pe,o),ze>u&&Ce<=u&&_(M,X,J,re,pe,u)}let F=k[k.length-1];const $=d===0?F.x:F.y;$>=o&&$<=u&&M.push(F),M.length&&(F=M[M.length-1],M[0].x===F.x&&M[0].y===F.y||M.push(M[0]),E.push(M))}E.length&&p.push(E)}return p}v0.VectorTileLayer=yP;const $U=b0.types,jU=Math.pow(2,13);function fy(l,o,u,d,p,_,b,E){l.emplaceBack((o<<1)+b,(u<<1)+_,(Math.floor(d*jU)<<1)+p,Math.round(E))}function py(l,o,u){l.emplaceBack(o.x,o.y,o.z,u[0]*16384,u[1]*16384,u[2]*16384)}class vP{constructor(){this.acc=new Y(0,0),this.polyCount=[]}startRing(o){this.currentPolyCount={edges:0,top:0},this.polyCount.push(this.currentPolyCount),this.min||(this.min=new Y(o.x,o.y),this.max=new Y(o.x,o.y))}append(o,u){this.currentPolyCount.edges++,this.acc._add(o);const d=this.min,p=this.max;o.x<d.x?d.x=o.x:o.x>p.x&&(p.x=o.x),o.y<d.y?d.y=o.y:o.y>p.y&&(p.y=o.y),((o.x===0||o.x===Rn)&&o.x===u.x)!=((o.y===0||o.y===Rn)&&o.y===u.y)&&this.processBorderOverlap(o,u),u.x<0!=o.x<0&&this.addBorderIntersection(0,ur(u.y,o.y,(0-u.x)/(o.x-u.x))),u.x>Rn!=o.x>Rn&&this.addBorderIntersection(1,ur(u.y,o.y,(Rn-u.x)/(o.x-u.x))),u.y<0!=o.y<0&&this.addBorderIntersection(2,ur(u.x,o.x,(0-u.y)/(o.y-u.y))),u.y>Rn!=o.y>Rn&&this.addBorderIntersection(3,ur(u.x,o.x,(Rn-u.y)/(o.y-u.y)))}addBorderIntersection(o,u){this.borders||(this.borders=[[Number.MAX_VALUE,-Number.MAX_VALUE],[Number.MAX_VALUE,-Number.MAX_VALUE],[Number.MAX_VALUE,-Number.MAX_VALUE],[Number.MAX_VALUE,-Number.MAX_VALUE]]);const d=this.borders[o];u<d[0]&&(d[0]=u),u>d[1]&&(d[1]=u)}processBorderOverlap(o,u){if(o.x===u.x){if(o.y===u.y)return;const d=o.x===0?0:1;this.addBorderIntersection(d,u.y),this.addBorderIntersection(d,o.y)}else{const d=o.y===0?2:3;this.addBorderIntersection(d,u.x),this.addBorderIntersection(d,o.x)}}centroid(){const o=this.polyCount.reduce((u,d)=>u+d.edges,0);return o!==0?this.acc.div(o)._round():new Y(0,0)}span(){return new Y(this.max.x-this.min.x,this.max.y-this.min.y)}intersectsCount(){return this.borders.reduce((o,u)=>o+ +(u[0]!==Number.MAX_VALUE),0)}}class my{constructor(o){this.zoom=o.zoom,this.canonical=o.canonical,this.overscaling=o.overscaling,this.layers=o.layers,this.layerIds=this.layers.map(u=>u.id),this.index=o.index,this.hasPattern=!1,this.edgeRadius=0,this.projection=o.projection,this.layoutVertexArray=new Bt,this.centroidVertexArray=new cc,this.indexArray=new Cn,this.programConfigurations=new gf(o.layers,o.zoom),this.segments=new yo,this.stateDependentLayerIds=this.layers.filter(u=>u.isStateDependent()).map(u=>u.id),this.enableTerrain=o.enableTerrain}populate(o,u,d,p){this.features=[],this.hasPattern=Sw("fill-extrusion",this.layers,u),this.featuresOnBorder=[],this.borders=[[],[],[],[]],this.borderDoneWithNeighborZ=[-1,-1,-1,-1],this.tileToMeter=function(_){const b=Math.exp(Math.PI*(1-_.y/(1<<_.z)*2));return 80150034*b/(b*b+1)/Rn/(1<<_.z)}(d),this.edgeRadius=this.layers[0].layout.get("fill-extrusion-edge-radius")/this.tileToMeter;for(const{feature:_,id:b,index:E,sourceLayerIndex:k}of o){const M=this.layers[0]._featureFilter.needGeometry,F=wf(_,M);if(!this.layers[0]._featureFilter.filter(new z(this.zoom),F,d))continue;const $={id:b,sourceLayerIndex:k,index:E,geometry:M?F.geometry:$u(_,d,p),properties:_.properties,type:_.type,patterns:{}},V=this.layoutVertexArray.length;this.hasPattern?this.features.push(Cw("fill-extrusion",this.layers,$,this.zoom,u)):this.addFeature($,$.geometry,E,d,{},u.availableImages,p),u.featureIndex.insert(_,$.geometry,E,k,this.index,V)}this.sortBorders()}addFeatures(o,u,d,p,_){for(const b of this.features){const{geometry:E}=b;this.addFeature(b,E,b.index,u,d,p,_)}this.sortBorders()}update(o,u,d,p){this.stateDependentLayers.length&&this.programConfigurations.updatePaintArrays(o,u,this.stateDependentLayers,d,p)}isEmpty(){return this.layoutVertexArray.length===0}uploadPending(){return!this.uploaded||this.programConfigurations.needsUpload}upload(o){this.uploaded||(this.layoutVertexBuffer=o.createVertexBuffer(this.layoutVertexArray,OU),this.indexBuffer=o.createIndexBuffer(this.indexArray),this.layoutVertexExtArray&&(this.layoutVertexExtBuffer=o.createVertexBuffer(this.layoutVertexExtArray,IU.members,!0))),this.programConfigurations.upload(o),this.uploaded=!0}uploadCentroid(o){this.centroidVertexArray.length!==0&&(this.centroidVertexBuffer?this.needsCentroidUpdate&&this.centroidVertexBuffer.updateData(this.centroidVertexArray):this.centroidVertexBuffer=o.createVertexBuffer(this.centroidVertexArray,MU.members,!0),this.needsCentroidUpdate=!1)}destroy(){this.layoutVertexBuffer&&(this.layoutVertexBuffer.destroy(),this.centroidVertexBuffer&&this.centroidVertexBuffer.destroy(),this.layoutVertexExtBuffer&&this.layoutVertexExtBuffer.destroy(),this.indexBuffer.destroy(),this.programConfigurations.destroy(),this.segments.destroy())}addFeature(o,u,d,p,_,b,E){const k=[new Y(0,0),new Y(Rn,Rn)],M=E.projection,F=M.name==="globe",$=this.enableTerrain&&!F?new vP:null,V=$U[o.type]==="Polygon";F&&!this.layoutVertexExtArray&&(this.layoutVertexExtArray=new Jt);const X=Ew(u,500);for(let Ce=X.length-1;Ce>=0;Ce--){const ze=X[Ce];(ze.length===0||(J=ze[0]).every(ke=>ke.x<=0)||J.every(ke=>ke.x>=Rn)||J.every(ke=>ke.y<=0)||J.every(ke=>ke.y>=Rn))&&X.splice(Ce,1)}var J;let re;if(F)re=CP(X,k,p);else{re=[];for(const Ce of X)re.push({polygon:Ce,bounds:k})}const pe=V?this.edgeRadius:0;for(const{polygon:Ce,bounds:ze}of re){let ke=0,Be=0;for(const Ge of Ce)V&&!Ge[0].equals(Ge[Ge.length-1])&&Ge.push(Ge[0]),Be+=V?Ge.length-1:Ge.length;const We=this.segments.prepareSegment((V?5:4)*Be,this.layoutVertexArray,this.indexArray);if(V){const Ge=[],vt=[];ke=We.vertexLength;for(const Dt of Ce){let Xt,Ct;Dt.length&&Dt!==Ce[0]&&vt.push(Ge.length/2),Xt=Dt[1].sub(Dt[0])._perp()._unit();for(let zt=1;zt<Dt.length;
120zt++){const Nt=Dt[zt],Gt=Dt[zt===Dt.length-1?1:zt+1];let{x:nn,y:Mt}=Nt;if(pe){Ct=Gt.sub(Nt)._perp()._unit();const un=Xt.add(Ct)._unit(),Tn=pe*Math.min(4,1/(Xt.x*un.x+Xt.y*un.y));nn+=Tn*un.x,Mt+=Tn*un.y,Xt=Ct}fy(this.layoutVertexArray,nn,Mt,0,0,1,1,0),We.vertexLength++,Ge.push(Nt.x,Nt.y),F&&py(this.layoutVertexExtArray,M.projectTilePoint(nn,Mt,p),M.upVector(p,nn,Mt))}}const ft=Tw(Ge,vt);for(let Dt=0;Dt<ft.length;Dt+=3)this.indexArray.emplaceBack(ke+ft[Dt],ke+ft[Dt+2],ke+ft[Dt+1]),We.primitiveLength++}for(const Ge of Ce){$&&Ge.length&&$.startRing(Ge[0]);let vt,ft,Dt,Xt=Ge.length>4&&TP(Ge[Ge.length-2],Ge[0],Ge[1]),Ct=pe?UU(Ge[Ge.length-2],Ge[0],Ge[1],pe):0;ft=Ge[1].sub(Ge[0])._perp()._unit();let zt=!0;for(let Nt=1,Gt=0;Nt<Ge.length;Nt++){let nn=Ge[Nt-1],Mt=Ge[Nt];const un=Ge[Nt===Ge.length-1?1:Nt+1];if($&&V&&$.currentPolyCount.top++,wP(Mt,nn,ze)){pe&&(ft=un.sub(Mt)._perp()._unit(),zt=!zt);continue}$&&$.append(Mt,nn);const Tn=Mt.sub(nn)._perp(),fn=Tn.x/(Math.abs(Tn.x)+Math.abs(Tn.y)),Qn=Tn.y>0?1:0,rn=nn.dist(Mt);if(Gt+rn>32768&&(Gt=0),pe){Dt=un.sub(Mt)._perp()._unit();let er=xP(nn,Mt,un,bP(ft,Dt),pe);isNaN(er)&&(er=0);const $n=Mt.sub(nn)._unit();nn=nn.add($n.mult(Ct))._round(),Mt=Mt.add($n.mult(-er))._round(),Ct=er,ft=Dt}const In=We.vertexLength,Jn=Ge.length>4&&TP(nn,Mt,un);let kr=EP(Gt,Xt,zt);if(fy(this.layoutVertexArray,nn.x,nn.y,fn,Qn,0,0,kr),fy(this.layoutVertexArray,nn.x,nn.y,fn,Qn,0,1,kr),Gt+=rn,kr=EP(Gt,Jn,!zt),Xt=Jn,fy(this.layoutVertexArray,Mt.x,Mt.y,fn,Qn,0,0,kr),fy(this.layoutVertexArray,Mt.x,Mt.y,fn,Qn,0,1,kr),We.vertexLength+=4,this.indexArray.emplaceBack(In+0,In+1,In+2),this.indexArray.emplaceBack(In+1,In+3,In+2),We.primitiveLength+=2,pe){const er=ke+(Nt===1?Ge.length-2:Nt-2),$n=Nt===1?ke:er+1;if(this.indexArray.emplaceBack(In+1,er,In+3),this.indexArray.emplaceBack(er,$n,In+3),We.primitiveLength+=2,vt===void 0&&(vt=In),!wP(un,Ge[Nt],ze)){const bi=Nt===Ge.length-1?vt:We.vertexLength;this.indexArray.emplaceBack(In+2,In+3,bi),this.indexArray.emplaceBack(In+3,bi+1,bi),this.indexArray.emplaceBack(In+3,$n,bi+1),We.primitiveLength+=3}zt=!zt}if(F){const er=this.layoutVertexExtArray,$n=M.projectTilePoint(nn.x,nn.y,p),bi=M.projectTilePoint(Mt.x,Mt.y,p),nr=M.upVector(p,nn.x,nn.y),rr=M.upVector(p,Mt.x,Mt.y);py(er,$n,nr),py(er,$n,nr),py(er,bi,rr),py(er,bi,rr)}}V&&(ke+=Ge.length-1)}}if($&&$.polyCount.length>0){if($.borders){$.vertexArrayOffset=this.centroidVertexArray.length;const Ce=$.borders,ze=this.featuresOnBorder.push($)-1;for(let ke=0;ke<4;ke++)Ce[ke][0]!==Number.MAX_VALUE&&this.borders[ke].push(ze)}this.encodeCentroid($.borders?void 0:$.centroid(),$)}this.programConfigurations.populatePaintArrays(this.layoutVertexArray.length,o,d,_,b,p)}sortBorders(){for(let o=0;o<4;o++)this.borders[o].sort((u,d)=>this.featuresOnBorder[u].borders[o][0]-this.featuresOnBorder[d].borders[o][0])}encodeCentroid(o,u,d=!0){let p,_;if(o)if(o.y!==0){const E=u.span()._mult(this.tileToMeter);p=(Math.max(o.x,1)<<3)+Math.min(7,Math.round(E.x/10)),_=(Math.max(o.y,1)<<3)+Math.min(7,Math.round(E.y/10))}else p=Math.ceil(7*(o.x+450)),_=0;else p=0,_=+d;let b=d?this.centroidVertexArray.length:u.vertexArrayOffset;for(const E of u.polyCount){d&&this.centroidVertexArray.resize(this.centroidVertexArray.length+4*E.edges+E.top);for(let k=0;k<E.top;k++)this.centroidVertexArray.emplace(b++,p,_);for(let k=0;k<2*E.edges;k++)this.centroidVertexArray.emplace(b++,0,_),this.centroidVertexArray.emplace(b++,p,_)}}}function bP(l,o){const u=l.add(o)._unit();return l.x*u.x+l.y*u.y}function UU(l,o,u,d){const p=o.sub(l)._perp()._unit(),_=u.sub(o)._perp()._unit();return xP(l,o,u,bP(p,_),d)}function xP(l,o,u,d,p){const _=Math.sqrt(1-d*d);return Math.min(l.dist(o)/3,o.dist(u)/3,p*_/d)}function wP(l,o,u){return l.x<u[0].x&&o.x<u[0].x||l.x>u[1].x&&o.x>u[1].x||l.y<u[0].y&&o.y<u[0].y||l.y>u[1].y&&o.y>u[1].y}function TP(l,o,u){if(l.x<0||l.x>=Rn||o.x<0||o.x>=Rn||u.x<0||u.x>=Rn)return!1;const d=u.sub(o),p=d.perp(),_=l.sub(o);return(d.x*_.x+d.y*_.y)/Math.sqrt((d.x*d.x+d.y*d.y)*(_.x*_.x+_.y*_.y))>-.866&&p.x*_.x+p.y*_.y<0}function EP(l,o,u){const d=o?2|l:-3&l;return u?1|d:-2&d}function SP(){const l=Math.PI/32,o=Math.tan(l),u=ly;return u*Math.sqrt(1+2*o*o)-u}function CP(l,o,u){const d=1<<u.z,p=ol(u.x/d),_=ol((u.x+1)/d),b=_a(u.y
vendor: 4,778 bytes, line 120
120/d),E=_a((u.y+1)/d);return function(k,M,F,$,V=0,X){const J=[];if(!k.length||!F||!$)return J;const re=(Ge,vt)=>{for(const ft of Ge)J.push({polygon:ft,bounds:vt})},pe=Math.ceil(Math.log2(F)),Ce=Math.ceil(Math.log2($)),ze=pe-Ce,ke=[];for(let Ge=0;Ge<Math.abs(ze);Ge++)ke.push(ze>0?0:1);for(let Ge=0;Ge<Math.min(pe,Ce);Ge++)ke.push(0),ke.push(1);let Be=k;if(Be=x0(Be,M[0].y-V,M[1].y+V,1),Be=x0(Be,M[0].x-V,M[1].x+V,0),!Be.length)return J;const We=[];for(ke.length?We.push({polygons:Be,bounds:M,depth:0}):re(Be,M);We.length;){const Ge=We.pop(),vt=Ge.depth,ft=ke[vt],Dt=Ge.bounds[0],Xt=Ge.bounds[1],Ct=ft===0?Dt.x:Dt.y,zt=ft===0?Xt.x:Xt.y,Nt=X?X(ft,Ct,zt):.5*(Ct+zt),Gt=x0(Ge.polygons,Ct-V,Nt+V,ft),nn=x0(Ge.polygons,Nt-V,zt+V,ft);if(Gt.length){const Mt=[Dt,new Y(ft===0?Nt:Xt.x,ft===1?Nt:Xt.y)];ke.length>vt+1?We.push({polygons:Gt,bounds:Mt,depth:vt+1}):re(Gt,Mt)}if(nn.length){const Mt=[new Y(ft===0?Nt:Dt.x,ft===1?Nt:Dt.y),Xt];ke.length>vt+1?We.push({polygons:nn,bounds:Mt,depth:vt+1}):re(nn,Mt)}}return J}(l,o,Math.ceil((_-p)/11.25),Math.ceil((b-E)/11.25),1,(k,M,F)=>{if(k===0)return .5*(M+F);{const $=_a((u.y+M/Rn)/d);return(Zc(.5*(_a((u.y+F/Rn)/d)+$))*d-u.y)*Rn}})}xn(my,"FillExtrusionBucket",{omit:["layers","features"]}),xn(vP,"PartMetadata");const VU=new Le({"fill-extrusion-edge-radius":new te(Pt["layout_fill-extrusion"]["fill-extrusion-edge-radius"])});var GU={paint:new Le({"fill-extrusion-opacity":new te(Pt["paint_fill-extrusion"]["fill-extrusion-opacity"]),"fill-extrusion-color":new ye(Pt["paint_fill-extrusion"]["fill-extrusion-color"]),"fill-extrusion-translate":new te(Pt["paint_fill-extrusion"]["fill-extrusion-translate"]),"fill-extrusion-translate-anchor":new te(Pt["paint_fill-extrusion"]["fill-extrusion-translate-anchor"]),"fill-extrusion-pattern":new ye(Pt["paint_fill-extrusion"]["fill-extrusion-pattern"]),"fill-extrusion-height":new ye(Pt["paint_fill-extrusion"]["fill-extrusion-height"]),"fill-extrusion-base":new ye(Pt["paint_fill-extrusion"]["fill-extrusion-base"]),"fill-extrusion-vertical-gradient":new te(Pt["paint_fill-extrusion"]["fill-extrusion-vertical-gradient"]),"fill-extrusion-ambient-occlusion-intensity":new te(Pt["paint_fill-extrusion"]["fill-extrusion-ambient-occlusion-intensity"]),"fill-extrusion-ambient-occlusion-radius":new te(Pt["paint_fill-extrusion"]["fill-extrusion-ambient-occlusion-radius"]),"fill-extrusion-rounded-roof":new te(Pt["paint_fill-extrusion"]["fill-extrusion-rounded-roof"])}),layout:VU};function kP(l,o,u){var d=2*Math.PI*6378137/256/Math.pow(2,u);return[l*d-2*Math.PI*6378137/2,o*d-2*Math.PI*6378137/2]}class w0{constructor(o,u,d){this.z=o,this.x=u,this.y=d,this.key=gy(0,o,o,u,d)}equals(o){return this.z===o.z&&this.x===o.x&&this.y===o.y}url(o,u){const d=function(_,b,E){var k=kP(256*_,256*(b=Math.pow(2,E)-b-1),E),M=kP(256*(_+1),256*(b+1),E);return k[0]+","+k[1]+","+M[0]+","+M[1]}(this.x,this.y,this.z),p=function(_,b,E){let k,M="";for(let F=_;F>0;F--)k=1<<F-1,M+=(b&k?1:0)+(E&k?2:0);return M}(this.z,this.x,this.y);return o[(this.x+this.y)%o.length].replace("{prefix}",(this.x%16).toString(16)+(this.y%16).toString(16)).replace(/{z}/g,String(this.z)).replace(/{x}/g,String(this.x)).replace(/{y}/g,String(u==="tms"?Math.pow(2,this.z)-this.y-1:this.y)).replace("{quadkey}",p).replace("{bbox-epsg-3857}",d)}toString(){return`${this.z}/${this.x}/${this.y}`}}class AP{constructor(o,u){this.wrap=o,this.canonical=u,this.key=gy(o,u.z,u.z,u.x,u.y)}}class Za{constructor(o,u,d,p,_){this.overscaledZ=o,this.wrap=u,this.canonical=new w0(d,+p,+_),this.key=u===0&&o===d?this.canonical.key:gy(u,o,d,p,_)}equals(o){return this.overscaledZ===o.overscaledZ&&this.wrap===o.wrap&&this.canonical.equals(o.canonical)}scaledTo(o){const u=this.canonical.z-o;return o>this.canonical.z?new Za(o,this.wrap,this.canonical.z,this.canonical.x,this.canonical.y):new Za(o,this.wrap,o,this.canonical.x>>u,this.canonical.y>>u)}calculateScaledKey(o,u=!0){if(this.overscaledZ===o&&u)return this.key;if(o>this.canonical.z)return gy(this.wrap*+u,o,this.canonical.z,this.canonical.x,this.canonical.y);{const d=this.canonical.z-o;return gy(this.wrap*+u,o,o,this.canonical.x>>d,this.canonical.y>>d)}}isChildOf(o){if(o.wrap!==this.wrap)return!1;const u=this.canonical.z-o.canonical.z;return o.overscaledZ===0||o.overscaledZ<this.overscaledZ&&o.canonical.x===this.canonical.x>>u&&o.canonical.y===this.canonical.y>>u}children(o){if(this.overscaledZ>=o)return[new Za(this.overscaledZ+1,this.wrap,this.canonical.z,this.canonical.x,this.canonical.y)];const u=this.canonical.z+1,d=2*this.canonical.x,p=2*this.canonical.y;return[new Za(u,this.wrap,u,d,p),new Za(u,this.wrap,u,d+1,p),new Za(u,this.wrap,u,d,p+1),new Za(u,this.wrap,u,d+1,p+1)]}isLessThan(o){return this.wrap<o.wrap||!(this.wrap>o.wrap)&&(this.overscaledZ<o.overscaledZ||!(this.overscaledZ>
vendor: 5,281 bytes, line 120
120o.overscaledZ)&&(this.canonical.x<o.canonical.x||!(this.canonical.x>o.canonical.x)&&this.canonical.y<o.canonical.y))}wrapped(){return new Za(this.overscaledZ,0,this.canonical.z,this.canonical.x,this.canonical.y)}unwrapTo(o){return new Za(this.overscaledZ,o,this.canonical.z,this.canonical.x,this.canonical.y)}overscaleFactor(){return Math.pow(2,this.overscaledZ-this.canonical.z)}toUnwrapped(){return new AP(this.wrap,this.canonical)}toString(){return`${this.overscaledZ}/${this.canonical.x}/${this.canonical.y}`}}function gy(l,o,u,d,p){const _=1<<Math.min(u,22);let b=_*(p%_)+d%_;return l&&u<22&&(b+=_*_*((l<0?-2*l-1:2*l)%(1<<2*(22-u)))),16*(32*b+u)+(o-u)}xn(w0,"CanonicalTileID"),xn(Za,"OverscaledTileID",{omit:["projMatrix"]});class em extends Y{constructor(o,u,d){super(o,u),this.z=d}}function yy(l,o){return l.x*o.x+l.y*o.y}function PP(l,o){if(l.length===1){let u=0;const d=o[u++];let p;for(;!p||d.equals(p);)if(p=o[u++],!p)return 1/0;for(;u<o.length;u++){const _=o[u],b=l[0],E=p.sub(d),k=_.sub(d),M=b.sub(d),F=yy(E,E),$=yy(E,k),V=yy(k,k),X=yy(M,E),J=yy(M,k),re=F*V-$*$,pe=(V*X-$*J)/re,Ce=(F*J-$*X)/re,ze=d.z*(1-pe-Ce)+p.z*pe+_.z*Ce;if(isFinite(ze))return ze}return 1/0}{let u=1/0;for(const d of o)u=Math.min(u,d.z);return u}}function MP(l,o,u,d,p,_,b,E){const k=b*p.getElevationAt(l,o,!0,!0),M=_[0]!==0,F=M?_[1]===0?b*(_[0]/7-450):b*function($,V,X){const J=Math.floor(V[0]/8),re=Math.floor(V[1]/8),pe=10*(V[0]-8*J),Ce=10*(V[1]-8*re),ze=$.getElevationAt(J,re,!0,!0),ke=$.getMeterToDEM(X),Be=Math.floor(.5*(pe*ke-1)),We=Math.floor(.5*(Ce*ke-1)),Ge=$.tileCoordToPixel(J,re),vt=2*Be+1,ft=2*We+1,Dt=function(nn,Mt,un,Tn,fn){return[nn.getElevationAtPixel(Mt,un,!0),nn.getElevationAtPixel(Mt+fn,un,!0),nn.getElevationAtPixel(Mt,un+fn,!0),nn.getElevationAtPixel(Mt+Tn,un+fn,!0)]}($,Ge.x-Be,Ge.y-We,vt,ft),Xt=Math.abs(Dt[0]-Dt[1]),Ct=Math.abs(Dt[2]-Dt[3]),zt=Math.abs(Dt[0]-Dt[2])+Math.abs(Dt[1]-Dt[3]),Nt=Math.min(.25,.5*ke*(Xt+Ct)/vt),Gt=Math.min(.25,.5*ke*zt/ft);return ze+Math.max(Nt*pe,Gt*Ce)}(p,_,E):k;return{base:k+(u===0)?-1:u,top:M?Math.max(F+d,k+u+2):k+d}}const qU=et([{name:"a_pos_normal",components:2,type:"Int16"},{name:"a_data",components:4,type:"Uint8"},{name:"a_linesofar",components:1,type:"Float32"}],4),{members:WU}=qU,HU=et([{name:"a_packed",components:4,type:"Float32"}]),{members:YU}=HU,ZU=b0.types,XU=Math.cos(Math.PI/180*37.5);class T0{constructor(o){this.zoom=o.zoom,this.overscaling=o.overscaling,this.layers=o.layers,this.layerIds=this.layers.map(u=>u.id),this.index=o.index,this.projection=o.projection,this.hasPattern=!1,this.patternFeatures=[],this.lineClipsArray=[],this.gradients={},this.layers.forEach(u=>{this.gradients[u.id]={}}),this.layoutVertexArray=new St,this.layoutVertexArray2=new Yt,this.indexArray=new Cn,this.programConfigurations=new gf(o.layers,o.zoom),this.segments=new yo,this.maxLineLength=0,this.stateDependentLayerIds=this.layers.filter(u=>u.isStateDependent()).map(u=>u.id)}populate(o,u,d,p){this.hasPattern=Sw("line",this.layers,u);const _=this.layers[0].layout.get("line-sort-key"),b=[];for(const{feature:F,id:$,index:V,sourceLayerIndex:X}of o){const J=this.layers[0]._featureFilter.needGeometry,re=wf(F,J);if(!this.layers[0]._featureFilter.filter(new z(this.zoom),re,d))continue;const pe=_?_.evaluate(re,{},d):void 0,Ce={id:$,properties:F.properties,type:F.type,sourceLayerIndex:X,index:V,geometry:J?re.geometry:$u(F,d,p),patterns:{},sortKey:pe};b.push(Ce)}_&&b.sort((F,$)=>F.sortKey-$.sortKey);const{lineAtlas:E,featureIndex:k}=u,M=this.addConstantDashes(E);for(const F of b){const{geometry:$,index:V,sourceLayerIndex:X}=F;if(M&&this.addFeatureDashes(F,E),this.hasPattern){const J=Cw("line",this.layers,F,this.zoom,u);this.patternFeatures.push(J)}else this.addFeature(F,$,V,d,E.positions,u.availableImages);k.insert(o[V].feature,$,V,X,this.index)}}addConstantDashes(o){let u=!1;for(const d of this.layers){const p=d.paint.get("line-dasharray").value,_=d.layout.get("line-cap").value;if(p.kind!=="constant"||_.kind!=="constant")u=!0;else{const b=_.value,E=p.value;if(!E)continue;o.addDash(E,b)}}return u}addFeatureDashes(o,u){const d=this.zoom;for(const p of this.layers){const _=p.paint.get("line-dasharray").value,b=p.layout.get("line-cap").value;if(_.kind==="constant"&&b.kind==="constant")continue;let E,k;if(_.kind==="constant"){if(E=_.value,!E)continue}else E=_.evaluate({zoom:d},o);k=b.kind==="constant"?b.value:b.evaluate({zoom:d},o),u.addDash(E,k),o.patterns[p.id]=u.getKey(E,k)}}update(o,u,d,p){this.stateDependentLayers.length&&this.programConfigurations.updatePaintArrays(o,u,this.stateDependentLayers,d,p)}addFeatures(o,u,d,p,_){for(const b of this.patternFeatures)this.addFeature(b,b.geometry,b.index,u,d,p)}isEmpty(){return this.layoutVertexArray.length===0}uploadPending(){return!this.uploaded||this.programConfigurations.needsUpload}upload(o){this.uploaded||(this.layoutVertexArray2.length!==0&&(this.layoutVertexBuffer2=o.createVertexBuffer(this.layoutVertexArray2,YU)),this.layoutVertexBuffer=o.createVertexBuffer(this.layoutVertexArray,WU),this.indexBuffer=o.createIndexBuffer(this.indexArray)),this.programConfigurations.upload(o),this.uploaded=!0}destroy(){this.layoutVertexBuffer&&(this.layoutVertexBuffer.destroy(),this.indexBuffer.destroy(),this.programConfigurations.destroy(),this.segments.destroy())}
vendor: 4,037 bytes, line 120
120lineFeatureClips(o){if(o.properties&&o.properties.hasOwnProperty("mapbox_clip_start")&&o.properties.hasOwnProperty("mapbox_clip_end"))return{start:+o.properties.mapbox_clip_start,end:+o.properties.mapbox_clip_end}}addFeature(o,u,d,p,_,b){const E=this.layers[0].layout,k=E.get("line-join").evaluate(o,{}),M=E.get("line-cap").evaluate(o,{}),F=E.get("line-miter-limit"),$=E.get("line-round-limit");this.lineClips=this.lineFeatureClips(o);for(const V of u)this.addLine(V,o,k,M,F,$);this.programConfigurations.populatePaintArrays(this.layoutVertexArray.length,o,d,_,b,p)}addLine(o,u,d,p,_,b){if(this.distance=0,this.scaledDistance=0,this.totalDistance=0,this.lineSoFar=0,this.lineClips){this.lineClipsArray.push(this.lineClips);for(let Ce=0;Ce<o.length-1;Ce++)this.totalDistance+=o[Ce].dist(o[Ce+1]);this.updateScaledDistance(),this.maxLineLength=Math.max(this.maxLineLength,this.totalDistance)}const E=ZU[u.type]==="Polygon";let k=o.length;for(;k>=2&&o[k-1].equals(o[k-2]);)k--;let M=0;for(;M<k-1&&o[M].equals(o[M+1]);)M++;if(k<(E?3:2))return;d==="bevel"&&(_=1.05);const F=this.overscaling<=16?15*Rn/(512*this.overscaling):0,$=this.segments.prepareSegment(10*k,this.layoutVertexArray,this.indexArray);let V,X,J,re,pe;this.e1=this.e2=-1,E&&(V=o[k-2],pe=o[M].sub(V)._unit()._perp());for(let Ce=M;Ce<k;Ce++){if(J=Ce===k-1?E?o[M+1]:void 0:o[Ce+1],J&&o[Ce].equals(J))continue;pe&&(re=pe),V&&(X=V),V=o[Ce],pe=J?J.sub(V)._unit()._perp():re,re=re||pe;let ze=re.add(pe);ze.x===0&&ze.y===0||ze._unit();const ke=re.x*pe.x+re.y*pe.y,Be=ze.x*pe.x+ze.y*pe.y,We=Be!==0?1/Be:1/0,Ge=2*Math.sqrt(2-2*Be),vt=Be<XU&&X&&J,ft=re.x*pe.y-re.y*pe.x>0;if(vt&&Ce>M){const Ct=V.dist(X);if(Ct>2*F){const zt=V.sub(V.sub(X)._mult(F/Ct)._round());this.updateDistance(X,zt),this.addCurrentVertex(zt,re,0,0,$),X=zt}}const Dt=X&&J;let Xt=Dt?d:E?"butt":p;if(Dt&&Xt==="round"&&(We<b?Xt="miter":We<=2&&(Xt="fakeround")),Xt==="miter"&&We>_&&(Xt="bevel"),Xt==="bevel"&&(We>2&&(Xt="flipbevel"),We<_&&(Xt="miter")),X&&this.updateDistance(X,V),Xt==="miter")ze._mult(We),this.addCurrentVertex(V,ze,0,0,$);else if(Xt==="flipbevel"){if(We>100)ze=pe.mult(-1);else{const Ct=We*re.add(pe).mag()/re.sub(pe).mag();ze._perp()._mult(Ct*(ft?-1:1))}this.addCurrentVertex(V,ze,0,0,$),this.addCurrentVertex(V,ze.mult(-1),0,0,$)}else if(Xt==="bevel"||Xt==="fakeround"){const Ct=-Math.sqrt(We*We-1),zt=ft?Ct:0,Nt=ft?0:Ct;if(X&&this.addCurrentVertex(V,re,zt,Nt,$),Xt==="fakeround"){const Gt=Math.round(180*Ge/Math.PI/20);for(let nn=1;nn<Gt;nn++){let Mt=nn/Gt;if(Mt!==.5){const Tn=Mt-.5;Mt+=Mt*Tn*(Mt-1)*((1.0904+ke*(ke*(3.55645-1.43519*ke)-3.2452))*Tn*Tn+(.848013+ke*(.215638*ke-1.06021)))}const un=pe.sub(re)._mult(Mt)._add(re)._unit()._mult(ft?-1:1);this.addHalfVertex(V,un.x,un.y,!1,ft,0,$)}}J&&this.addCurrentVertex(V,pe,-zt,-Nt,$)}else if(Xt==="butt")this.addCurrentVertex(V,ze,0,0,$);else if(Xt==="square"){const Ct=X?1:-1;X||this.addCurrentVertex(V,ze,Ct,Ct,$),this.addCurrentVertex(V,ze,0,0,$),X&&this.addCurrentVertex(V,ze,Ct,Ct,$)}else Xt==="round"&&(X&&(this.addCurrentVertex(V,re,0,0,$),this.addCurrentVertex(V,re,1,1,$,!0)),J&&(this.addCurrentVertex(V,pe,-1,-1,$,!0),this.addCurrentVertex(V,pe,0,0,$)));if(vt&&Ce<k-1){const Ct=V.dist(J);if(Ct>2*F){const zt=V.add(J.sub(V)._mult(F/Ct)._round());this.updateDistance(V,zt),this.addCurrentVertex(zt,pe,0,0,$),V=zt}}}}addCurrentVertex(o,u,d,p,_,b=!1){const E=u.y*p-u.x,k=-u.y-u.x*p;this.addHalfVertex(o,u.x+u.y*d,u.y-u.x*d,b,!1,d,_),this.addHalfVertex(o,E,k,b,!0,-p,_)}addHalfVertex({x:o,y:u},d,p,_,b,E,k){this.layoutVertexArray.emplaceBack((o<<1)+(_?1:0),(u<<1)+(b?1:0),Math.round(63*d)+128,Math.round(63*p)+128,1+(E===0?0:E<0?-1:1),0,this.lineSoFar),this.lineClips&&this.layoutVertexArray2.emplaceBack(this.scaledDistance,this.lineClipsArray.length,this.lineClips.start,this.lineClips.end);const M=k.vertexLength++;this.e1>=0&&this.e2>=0&&(this.indexArray.emplaceBack(this.e1,this.e2,M),k.primitiveLength++),b?this.e2=M:this.e1=M}updateScaledDistance(){if(this.lineClips){const o=this.totalDistance/(this.lineClips.end-this.lineClips.start);
120this.scaledDistance=this.distance/this.totalDistance,this.lineSoFar=o*this.lineClips.start+this.distance}else this.lineSoFar=this.distance}updateDistance(o,u){this.distance+=o.dist(u),this.updateScaledDistance()}}xn(T0,"LineBucket",{omit:["layers","patternFeatures"]});const KU=new Le({"line-cap":new ye(Pt.layout_line["line-cap"]),"line-join":new ye(Pt.layout_line["line-join"]),"line-miter-limit":new te(Pt.layout_line["line-miter-limit"]),"line-round-limit":new te(Pt.layout_line["line-round-limit"]),"line-sort-key":new ye(Pt.layout_line["line-sort-key"])});var IP={paint:new Le({"line-opacity":new ye(Pt.paint_line["line-opacity"]),"line-color":new ye(Pt.paint_line["line-color"]),"line-translate":new te(Pt.paint_line["line-translate"]),"line-translate-anchor":new te(Pt.paint_line["line-translate-anchor"]),"line-width":new ye(Pt.paint_line["line-width"]),"line-gap-width":new ye(Pt.paint_line["line-gap-width"]),"line-offset":new ye(Pt.paint_line["line-offset"]),"line-blur":new ye(Pt.paint_line["line-blur"]),"line-dasharray":new ye(Pt.paint_line["line-dasharray"]),"line-pattern":new ye(Pt.paint_line["line-pattern"]),"line-gradient":new Oe(Pt.paint_line["line-gradient"]),"line-trim-offset":new te(Pt.paint_line["line-trim-offset"])}),layout:KU};const OP=new class extends ye{possiblyEvaluate(l,o){return o=new z(Math.floor(o.zoom),{now:o.now,fadeDuration:o.fadeDuration,transition:o.transition}),super.possiblyEvaluate(l,o)}evaluate(l,o,u,d){return o=xt({},o,{zoom:Math.floor(o.zoom)}),super.evaluate(l,o,u,d)}}(IP.paint.properties["line-width"].specification);function DP(l,o){return o>0?o+2*l:l}OP.useIntegerZoom=!0;const QU=et([{name:"a_pos_offset",components:4,type:"Int16"},{name:"a_tex_size",components:4,type:"Uint16"},{name:"a_pixeloffset",components:4,type:"Int16"}],4),JU=et([{name:"a_globe_anchor",components:3,type:"Int16"},{name:"a_globe_normal",components:3,type:"Float32"}],4),eV=et([{name:"a_projected_pos",components:4,type:"Float32"}],4);et([{name:"a_fade_opacity",components:1,type:"Uint32"}],4);const tV=et([{name:"a_placed",components:2,type:"Uint8"},{name:"a_shift",components:2,type:"Float32"}]),nV=et([{name:"a_size_scale",components:1,type:"Float32"},{name:"a_padding",components:2,type:"Float32"}]);et([{type:"Int16",name:"projectedAnchorX"},{type:"Int16",name:"projectedAnchorY"},{type:"Int16",name:"projectedAnchorZ"},{type:"Int16",name:"tileAnchorX"},{type:"Int16",name:"tileAnchorY"},{type:"Float32",name:"x1"},{type:"Float32",name:"y1"},{type:"Float32",name:"x2"},{type:"Float32",name:"y2"},{type:"Int16",name:"padding"},{type:"Uint32",name:"featureIndex"},{type:"Uint16",name:"sourceLayerIndex"},{type:"Uint16",name:"bucketIndex"}]);const LP=et([{name:"a_pos",components:3,type:"Int16"},{name:"a_anchor_pos",components:2,type:"Int16"},{name:"a_extrude",components:2,type:"Int16"}],4),rV=et([{name:"a_pos_2f",components:2,type:"Float32"},{name:"a_radius",components:1,type:"Float32"},{name:"a_flags",components:2,type:"Int16"}],4);et([{name:"triangle",components:3,type:"Uint16"}]),et([{type:"Int16",name:"projectedAnchorX"},{type:"Int16",name:"projectedAnchorY"},{type:"Int16",name:"projectedAnchorZ"},{type:"Float32",name:"tileAnchorX"},{type:"Float32",name:"tileAnchorY"},{type:"Uint16",name:"glyphStartIndex"},{type:"Uint16",name:"numGlyphs"},{type:"Uint32",name:"vertexStartIndex"},{type:"Uint32",name:"lineStartIndex"},{type:"Uint32",name:"lineLength"},{type:"Uint16",name:"segment"},{type:"Uint16",name:"lowerSize"},{type:"Uint16",name:"upperSize"},{type:"Float32",name:"lineOffsetX"},{type:"Float32",name:"lineOffsetY"},{type:"Uint8",name:"writingMode"},{type:"Uint8",name:"placedOrientation"},{type:"Uint8",name:"hidden"},{type:"Uint32",name:"crossTileID"},{type:"Int16",name:"associatedIconIndex"},{type:"Uint8",name:"flipState"}]),et([{type:"Int16",name:"projectedAnchorX"},{type:"Int16",name:"projectedAnchorY"},{type:"Int16",name:"projectedAnchorZ"},{type:"Float32",name:"tileAnchorX"},{type:"Float32",name:"tileAnchorY"},{type:"Int16",name:"rightJustifiedTextSymbolIndex"},{type:"Int16",name:"centerJustifiedTextSymbolIndex"},{type:"Int16",name:"leftJustifiedTextSymbolIndex"},{type:"Int16",name:"verticalPlacedTextSymbolIndex"},{type:"Int16",name:"placedIconSymbolIndex"},{type:"Int16",name:"verticalPlacedIconSymbolIndex"},{type:"Uint16",name:"key"},{type:"Uint16",name:"textBoxStartIndex"},{type:"Uint16",name:"textBoxEndIndex"},{type:"Uint16",name:"verticalTextBoxStartIndex"},{type:"Uint16",name:"verticalTextBoxEndIndex"},{type:"Uint16",name:"iconBoxStartIndex"},{type:"Uint16",name:"iconBoxEndIndex"},{type:"Uint16",name:"verticalIconBoxStartIndex"},{type:"Uint16",name:"verticalIconBoxEndIndex"},{type:"Uint16",name:"featureIndex"},{type:"Uint16",name:"numHorizontalGlyphVertices"},{type:"Uint16",name:"numVerticalGlyphVertices"},{type:"Uint16",name:"numIconVertices"},{type:"Uint16",name:"numVerticalIconVertices"},{type:"Uint16",name:"useRuntimeCollisionCircles"},{type:"Uint32",name:"crossTileID"},{type:"Float32",components:2,name:"textOffset"},{type:"Float32",name:"collisionCircleDiameter"}]),et([{type:"Float32",name:"offsetX"}]),et([{type:"Int16",name:"x"},{type:"Int16",name:"y"}]);var aa=24;const mc=128;function Aw(l,o){const{expression:u}=o;if(u.kind==="constant")return{kind:"constant",layoutSize:u.evaluate(new z(l+1))};if(u.kind==="source")return{kind:"source"};{const{zoomStops:d,interpolationType:p}=u;let _=0;for(;_<d.length&&d[_]<=l;)_++;_=Math.max(0,_-1);let b=_;for(;b<d.length&&d[b]<l+1;)b++;b=Math.min(d.length-1,b);const E=d[_],k=d[b];return u.kind==="composite"?{kind:"composite",minZoom:E,maxZoom:k,interpolationType:p}:{kind:"camera",minZoom:E,maxZoom:k,minSize:u.evaluate(new z(E)),maxSize:u.evaluate(new z(k)),interpolationType:p}}}function E0(l,{uSize:o,uSizeT:u},{lowerSize:d,upperSize:p}){return l.kind==="source"?d/mc:l.kind==="composite"?ur(d/mc,p/mc,u):o}function tm(l,o){let u=0,d=0;if(l.kind==="constant")d=l.layoutSize;else if(l.kind!=="source"){const{interpolationType:p,minZoom:_,maxZoom:b}=l,E=p?ne(Ma.interpolationFactor(p,o,_,b),0,1):0;l.kind==="camera"?d=ur(l.minSize,l.maxSize,E):u=E}return{uSizeT:u,uSize:d}}var iV=Object.freeze({__proto__:null,SIZE_PACK_FACTOR:mc,evaluateSizeForFeature:E0,evaluateSizeForZoom:tm,getSizeData:Aw});function oV(l,o,u){return l.sections.forEach(d=>{d.text=function(p,_,b){const E=_.layout.get("text-transform").evaluate(b,{});return E==="uppercase"?p=p.toLocaleUpperCase():E==="lowercase"&&(p=p.toLocaleLowerCase()),L.applyArabicShaping&&(p=L.applyArabicShaping(p)),p}(d.text,o,u)}),l}const _y={"!":"︕","#":"#",$:"$","%":"%","&":"&","(":"︵",")":"︶","*":"*","+":"+",",":"︐","-":"︲",".":"・","/":"/",":":"︓",";":"︔","<":"︿","=":"=",">":"﹀","?":"︖","@":"@","[":"﹇","\\":"\","]":"﹈","^":"^",_:"︳","`":"`","{":"︷","|":"―","}":"︸","~":"~","¢":"¢","£":"£","¥":"¥","¦":"¦","¬":"¬","¯":" ̄","–":"︲","—":"︱","‘":"﹃","’":"﹄","“":"﹁","”":"﹂","…":"︙","‧":"・","₩":"₩","、":"︑","。":"︒","〈":"︿","〉":"﹀","《":"︽","》":"︾","「":"﹁","」":"﹂","『":"﹃","』":"﹄","【":"︻","】":"︼","〔":"︹","〕":"︺","〖":"︗","〗":"︘","!":"︕","(":"︵",")":"︶",",":"︐","-":"︲",".":"・",":":"︓",";":"︔","<":"︿",">":"﹀","?":"︖","[":"﹇","]":"﹈","_":"︳","{":"︷","|":"―","}":"︸","⦅":"︵","⦆":"︶","。":"︒","「":"﹁","」":"﹂","←":"↑","→":"↓"};function aV(l){return l==="︶"||l==="﹈"||l==="︸"||l==="﹄"||l==="﹂"||l==="︾"||l==="︼"||l==="︺"||l==="︘"||l==="﹀"||l==="︐"||l==="︓"||l==="︔"||l==="`"||l===" ̄"||l==="︑"||l==="︒"}function sV(l){return l==="︵"||l==="﹇"||l==="︷"||l==="﹃"||l==="﹁"||l==="︽"||l==="︻"||l==="︹"||l==="︗"||l==="︿"}var RP=ui,FP=function(l,o,u,d,p){var _,b,E=8*p-d-1,k=(1<<E)-1,M=k>>1,F=-7,$=u?p-1:0,V=u?-1:1,X=l[o+$];for($+=V,_=X&(1<<-F)-1,X>>=-F,F+=E;F>0;_=256*_+l[o+$],$+=V,F-=8);for(b=_&(1<<-F)-1,_>>=-F,F+=d;F>0;b=256*b+l[o+$],$+=V,F-=8);if(_===0)_=1-M;else{if(_===k)return b?NaN:1/0*(X?-1:1);b+=Math.pow(2,d),_-=M}return(X?-1:1)*b*Math.pow(2,_-d)},BP=function(l,o,u,d,p,_){var b,E,k,M=8*_-p-1,F=(1<<M)-1,$=F>>1,V=p===23?Math.pow(2,-24)-Math.pow(2,-77):0,X=d?0:_-1,J=d?1:-1,re=o<0||o===0&&1/o<0?1:0;for(o=Math.abs(o),isNaN(o)||o===1/0?(E=isNaN(o)?1:0,b=F):(b=Math.floor(Math.log(o)/M
120ath.LN2),o*(k=Math.pow(2,-b))<1&&(b--,k*=2),(o+=b+$>=1?V/k:V*Math.pow(2,1-$))*k>=2&&(b++,k/=2),b+$>=F?(E=0,b=F):b+$>=1?(E=(o*k-1)*Math.pow(2,p),b+=$):(E=o*Math.pow(2,$-1)*Math.pow(2,p),b=0));p>=8;l[u+X]=255&E,X+=J,E/=256,p-=8);for(b=b<<p|E,M+=p;M>0;l[u+X]=255&b,X+=J,b/=256,M-=8);l[u+X-J]|=128*re};/*! ieee754. BSD-3-Clause License. Feross Aboukhadijeh <https://feross.org/opensource> */function ui(l){this.buf=ArrayBuffer.isView&&ArrayBuffer.isView(l)?l:new Uint8Array(l||0),this.pos=0,this.type=0,this.length=this.buf.length}ui.Varint=0,ui.Fixed64=1,ui.Bytes=2,ui.Fixed32=5;var Pw=4294967296,zP=1/Pw,NP=typeof TextDecoder>"u"?null:new TextDecoder("utf8");function Uu(l){return l.type===ui.Bytes?l.readVarint()+l.pos:l.pos+1}function nm(l,o,u){return u?4294967296*o+(l>>>0):4294967296*(o>>>0)+(l>>>0)}function $P(l,o,u){var d=o<=16383?1:o<=2097151?2:o<=268435455?3:Math.floor(Math.log(o)/(7*Math.LN2));u.realloc(d);for(var p=u.pos-1;p>=l;p--)u.buf[p+d]=u.buf[p]}function lV(l,o){for(var u=0;u<l.length;u++)o.writeVarint(l[u])}function cV(l,o){for(var u=0;u<l.length;u++)o.writeSVarint(l[u])}function uV(l,o){for(var u=0;u<l.length;u++)o.writeFloat(l[u])}function hV(l,o){for(var u=0;u<l.length;u++)o.writeDouble(l[u])}function dV(l,o){for(var u=0;u<l.length;u++)o.writeBoolean(l[u])}function fV(l,o){for(var u=0;u<l.length;u++)o.writeFixed32(l[u])}function pV(l,o){for(var u=0;u<l.length;u++)o.writeSFixed32(l[u])}function mV(l,o){for(var u=0;u<l.length;u++)o.writeFixed64(l[u])}function gV(l,o){for(var u=0;u<l.length;u++)o.writeSFixed64(l[u])}function S0(l,o){return(l[o]|l[o+1]<<8|l[o+2]<<16)+16777216*l[o+3]}function rm(l,o,u){l[u]=o,l[u+1]=o>>>8,l[u+2]=o>>>16,l[u+3]=o>>>24}function jP(l,o){return(l[o]|l[o+1]<<8|l[o+2]<<16)+(l[o+3]<<24)}ui.prototype={destroy:function(){this.buf=null},readFields:function(l,o,u){for(u=u||this.length;this.pos<u;){var d=this.readVarint(),p=d>>3,_=this.pos;this.type=7&d,l(p,o,this),this.pos===_&&this.skip(d)}return o},readMessage:function(l,o){return this.readFields(l,o,this.readVarint()+this.pos)},readFixed32:function(){var l=S0(this.buf,this.pos);return this.pos+=4,l},readSFixed32:function(){var l=jP(this.buf,this.pos);return this.pos+=4,l},readFixed64:function(){var l=S0(this.buf,this.pos)+S0(this.buf,this.pos+4)*Pw;return this.pos+=8,l},readSFixed64:function(){var l=S0(this.buf,this.pos)+jP(this.buf,this.pos+4)*Pw;return this.pos+=8,l},readFloat:function(){var l=FP(this.buf,this.pos,!0,23,4);return this.pos+=4,l},readDouble:function(){var l=FP(this.buf,this.pos,!0,52,8);return this.pos+=8,l},readVarint:function(l){var o,u,d=this.buf;return o=127&(u=d[this.pos++]),u<128?o:(o|=(127&(u=d[this.pos++]))<<7,u<128?o:(o|=(127&(u=d[this.pos++]))<<14,u<128?o:(o|=(127&(u=d[this.pos++]))<<21,u<128?o:function(p,_,b){var E,k,M=b.buf;if(E=(112&(k=M[b.pos++]))>>4,k<128||(E|=(127&(k=M[b.pos++]))<<3,k<128)||(E|=(127&(k=M[b.pos++]))<<10,k<128)||(E|=(127&(k=M[b.pos++]))<<17,k<128)||(E|=(127&(k=M[b.pos++]))<<24,k<128)||(E|=(1&(k=M[b.pos++]))<<31,k<128))return nm(p,E,_);throw new Error("Expected varint not more than 10 bytes")}(o|=(15&(u=d[this.pos]))<<28,l,this))))},readVarint64:function(){return this.readVarint(!0)},readSVarint:function(){var l=this.readVarint();return l%2==1?(l+1)/-2:l/2},readBoolean:function(){return!!this.readVarint()},readString:function(){var l=this.readVarint()+this.pos,o=this.pos;return this.pos=l,l-o>=12&&NP?function(u,d,p){return NP.decode(u.subarray(d,p))}(this.buf,o,l):function(u,d,p){for(var _="",b=d;b<p;){var E,k,M,F=u[b],$=null,V=F>239?4:F>223?3:F>191?2:1;if(b+V>p)break;V===1?F<128&&($=F):V===2?(192&(E=u[b+1]))==128&&($=(31&F)<<6|63&E)<=127&&($=null):V===3?(k=u[b+2],(192&(E=u[b+1]))==128&&(192&k)==128&&(($=(15&F)<<12|(63&E)<<6|63&k)<=2047||$>=55296&&$<=57343)&&($=null)):V===4&&(k=u[b+2],M=u[b+3],(192&(E=u[b+1]))==128&&(192&k)==128&&(192&M)==128&&(($=(15&F)<<18|(63&E)<<12|(63&k)<<6|63&M)<=65535||$>=1114112)&&($=null)),$===null?($=65533,V=1):$>65535&&($-=65536,_+=String.fromCharCode($>>>10&1023|55296),$=56320|1023&$),_+=String.fromCharCode($),b+=V}return _}(this.buf,o,l)},readBytes:function(){var l=this.readVarint()+this.pos,o=this.buf.subarray(this.pos,l);return this.pos=l,o}
vendor: 5,627 bytes, line 120
120,readPackedVarint:function(l,o){if(this.type!==ui.Bytes)return l.push(this.readVarint(o));var u=Uu(this);for(l=l||[];this.pos<u;)l.push(this.readVarint(o));return l},readPackedSVarint:function(l){if(this.type!==ui.Bytes)return l.push(this.readSVarint());var o=Uu(this);for(l=l||[];this.pos<o;)l.push(this.readSVarint());return l},readPackedBoolean:function(l){if(this.type!==ui.Bytes)return l.push(this.readBoolean());var o=Uu(this);for(l=l||[];this.pos<o;)l.push(this.readBoolean());return l},readPackedFloat:function(l){if(this.type!==ui.Bytes)return l.push(this.readFloat());var o=Uu(this);for(l=l||[];this.pos<o;)l.push(this.readFloat());return l},readPackedDouble:function(l){if(this.type!==ui.Bytes)return l.push(this.readDouble());var o=Uu(this);for(l=l||[];this.pos<o;)l.push(this.readDouble());return l},readPackedFixed32:function(l){if(this.type!==ui.Bytes)return l.push(this.readFixed32());var o=Uu(this);for(l=l||[];this.pos<o;)l.push(this.readFixed32());return l},readPackedSFixed32:function(l){if(this.type!==ui.Bytes)return l.push(this.readSFixed32());var o=Uu(this);for(l=l||[];this.pos<o;)l.push(this.readSFixed32());return l},readPackedFixed64:function(l){if(this.type!==ui.Bytes)return l.push(this.readFixed64());var o=Uu(this);for(l=l||[];this.pos<o;)l.push(this.readFixed64());return l},readPackedSFixed64:function(l){if(this.type!==ui.Bytes)return l.push(this.readSFixed64());var o=Uu(this);for(l=l||[];this.pos<o;)l.push(this.readSFixed64());return l},skip:function(l){var o=7&l;if(o===ui.Varint)for(;this.buf[this.pos++]>127;);else if(o===ui.Bytes)this.pos=this.readVarint()+this.pos;else if(o===ui.Fixed32)this.pos+=4;else{if(o!==ui.Fixed64)throw new Error("Unimplemented type: "+o);this.pos+=8}},writeTag:function(l,o){this.writeVarint(l<<3|o)},realloc:function(l){for(var o=this.length||16;o<this.pos+l;)o*=2;if(o!==this.length){var u=new Uint8Array(o);u.set(this.buf),this.buf=u,this.length=o}},finish:function(){return this.length=this.pos,this.pos=0,this.buf.subarray(0,this.length)},writeFixed32:function(l){this.realloc(4),rm(this.buf,l,this.pos),this.pos+=4},writeSFixed32:function(l){this.realloc(4),rm(this.buf,l,this.pos),this.pos+=4},writeFixed64:function(l){this.realloc(8),rm(this.buf,-1&l,this.pos),rm(this.buf,Math.floor(l*zP),this.pos+4),this.pos+=8},writeSFixed64:function(l){this.realloc(8),rm(this.buf,-1&l,this.pos),rm(this.buf,Math.floor(l*zP),this.pos+4),this.pos+=8},writeVarint:function(l){(l=+l||0)>268435455||l<0?function(o,u){var d,p;if(o>=0?(d=o%4294967296|0,p=o/4294967296|0):(p=~(-o/4294967296),4294967295^(d=~(-o%4294967296))?d=d+1|0:(d=0,p=p+1|0)),o>=18446744073709552e3||o<-18446744073709552e3)throw new Error("Given varint doesn't fit into 10 bytes");u.realloc(10),function(_,b,E){E.buf[E.pos++]=127&_|128,_>>>=7,E.buf[E.pos++]=127&_|128,_>>>=7,E.buf[E.pos++]=127&_|128,_>>>=7,E.buf[E.pos++]=127&_|128,E.buf[E.pos]=127&(_>>>=7)}(d,0,u),function(_,b){var E=(7&_)<<4;b.buf[b.pos++]|=E|((_>>>=3)?128:0),_&&(b.buf[b.pos++]=127&_|((_>>>=7)?128:0),_&&(b.buf[b.pos++]=127&_|((_>>>=7)?128:0),_&&(b.buf[b.pos++]=127&_|((_>>>=7)?128:0),_&&(b.buf[b.pos++]=127&_|((_>>>=7)?128:0),_&&(b.buf[b.pos++]=127&_)))))}(p,u)}(l,this):(this.realloc(4),this.buf[this.pos++]=127&l|(l>127?128:0),l<=127||(this.buf[this.pos++]=127&(l>>>=7)|(l>127?128:0),l<=127||(this.buf[this.pos++]=127&(l>>>=7)|(l>127?128:0),l<=127||(this.buf[this.pos++]=l>>>7&127))))},writeSVarint:function(l){this.writeVarint(l<0?2*-l-1:2*l)},writeBoolean:function(l){this.writeVarint(!!l)},writeString:function(l){l=String(l),this.realloc(4*l.length),this.pos++;var o=this.pos;this.pos=function(d,p,_){for(var b,E,k=0;k<p.length;k++){if((b=p.charCodeAt(k))>55295&&b<57344){if(!E){b>56319||k+1===p.length?(d[_++]=239,d[_++]=191,d[_++]=189):E=b;continue}if(b<56320){d[_++]=239,d[_++]=191,d[_++]=189,E=b;continue}b=E-55296<<10|b-56320|65536,E=null}else E&&(d[_++]=239,d[_++]=191,d[_++]=189,E=null);b<128?d[_++]=b:(b<2048?d[_++]=b>>6|192:(b<65536?d[_++]=b>>12|224:(d[_++]=b>>18|240,d[_++]=b>>12&63|128),d[_++]=b>>6&63|128),d[_++]=63&b|128)}return _}(this.buf,l,this.pos);var u=this.pos-o;u>=128&&$P(o,u,this),this.pos=o-1,this.writeVarint(u),this.pos+=u},writeFloat:function(l){this.realloc(4),BP(this.buf,l,this.pos,!0,23,4),this.pos+=4},writeDouble:function(l){this.realloc(8),BP(this.buf,l,this.pos,!0,52,8),this.pos+=8},writeBytes:function(l){var o=l.length;this.writeVarint(o),this.realloc(o);for(var u=0;u<o;u++)this.buf[this.pos++]=l[u]},writeRawMessage:function(l,o){this.pos++;var u=this.pos;l(o,this);var d=this.pos-u;d>=128&&$P(u,d,this),this.pos=u-1,this.writeVarint(d),this.pos+=d},writeMessage:function(l,o,u){this.writeTag(l,ui.Bytes),this.writeRawMessage(o,u)},writePackedVarint:function(l,o){o.length&&this.writeMessage(l,lV,o)},writePackedSVarint:function(l,o){o.length&&this.writeMessage(l,cV,o)},writePackedBoolean:function(l,o){o.length&&this.writeMessage(l,dV,o)},writePackedFloat:function(l,o){o.length&&this.writeMessage(l,uV,o)},writePackedDouble:function(l,o){o.length&&this.writeMessage(l,hV,o)},writePackedFixed32:function(l,o){o.length&&this.writeMessage(l,fV,o)},writePackedSFixed32:function(l,o){o.length&&this.writeMessage(l,pV,o)},writePackedFixed64:function(l,o){o.length&&this.writeMessage(l,mV,o)},writePackedSFixed64:function(l,o){o.length&&this.writeMessage(l,gV,o)},writeBytesField:function(l,o){this.writeTag(l,ui.Bytes),this.writeBytes(o)},writeFixed32Field:function(l,o){this.writeTag(l,ui.Fixed32),this.writeFixed32(o)},writeSFixed32Field:function(l,o){this.writeTag(l,ui.Fixed32),this.writeSFixed32(o)},writeFixed64Field:function(l,o){this.writeTag(l,ui.Fixed64),this.writeFixed64
120(o)},writeSFixed64Field:function(l,o){this.writeTag(l,ui.Fixed64),this.writeSFixed64(o)},writeVarintField:function(l,o){this.writeTag(l,ui.Varint),this.writeVarint(o)},writeSVarintField:function(l,o){this.writeTag(l,ui.Varint),this.writeSVarint(o)},writeStringField:function(l,o){this.writeTag(l,ui.Bytes),this.writeString(o)},writeFloatField:function(l,o){this.writeTag(l,ui.Fixed32),this.writeFloat(o)},writeDoubleField:function(l,o){this.writeTag(l,ui.Fixed64),this.writeDouble(o)},writeBooleanField:function(l,o){this.writeVarintField(l,!!o)}};var C0=j(RP);const Mw=3;function yV(l,o,u){o.glyphs=[],l===1&&u.readMessage(_V,o)}function _V(l,o,u){if(l===3){const{id:d,bitmap:p,width:_,height:b,left:E,top:k,advance:M}=u.readMessage(vV,{});o.glyphs.push({id:d,bitmap:new ju({width:_+2*Mw,height:b+2*Mw},p),metrics:{width:_,height:b,left:E,top:k,advance:M}})}else l===4?o.ascender=u.readSVarint():l===5&&(o.descender=u.readSVarint())}function vV(l,o,u){l===1?o.id=u.readVarint():l===2?o.bitmap=u.readBytes():l===3?o.width=u.readVarint():l===4?o.height=u.readVarint():l===5?o.left=u.readSVarint():l===6?o.top=u.readSVarint():l===7&&(o.advance=u.readVarint())}const UP=Mw;function Iw(l){let o=0,u=0;for(const b of l)o+=b.w*b.h,u=Math.max(u,b.w);l.sort((b,E)=>E.h-b.h);const d=[{x:0,y:0,w:Math.max(Math.ceil(Math.sqrt(o/.95)),u),h:1/0}];let p=0,_=0;for(const b of l)for(let E=d.length-1;E>=0;E--){const k=d[E];if(!(b.w>k.w||b.h>k.h)){if(b.x=k.x,b.y=k.y,_=Math.max(_,b.y+b.h),p=Math.max(p,b.x+b.w),b.w===k.w&&b.h===k.h){const M=d.pop();E<d.length&&(d[E]=M)}else b.h===k.h?(k.x+=b.w,k.w-=b.w):b.w===k.w?(k.y+=b.h,k.h-=b.h):(d.push({x:k.x+b.w,y:k.y,w:k.w-b.w,h:b.h}),k.y+=b.h,k.h-=b.h);break}}return{w:p,h:_,fill:o/(p*_)||0}}const us=1;class Ow{constructor(o,{pixelRatio:u,version:d,stretchX:p,stretchY:_,content:b}){this.paddedRect=o,this.pixelRatio=u,this.stretchX=p,this.stretchY=_,this.content=b,this.version=d}get tl(){return[this.paddedRect.x+us,this.paddedRect.y+us]}get br(){return[this.paddedRect.x+this.paddedRect.w-us,this.paddedRect.y+this.paddedRect.h-us]}get displaySize(){return[(this.paddedRect.w-2*us)/this.pixelRatio,(this.paddedRect.h-2*us)/this.pixelRatio]}}class VP{constructor(o,u){const d={},p={};this.haveRenderCallbacks=[];const _=[];this.addImages(o,d,_),this.addImages(u,p,_);const{w:b,h:E}=Iw(_),k=new As({width:b||1,height:E||1});for(const M in o){const F=o[M],$=d[M].paddedRect;As.copy(F.data,k,{x:0,y:0},{x:$.x+us,y:$.y+us},F.data)}for(const M in u){const F=u[M],$=p[M].paddedRect,V=$.x+us,X=$.y+us,J=F.data.width,re=F.data.height;As.copy(F.data,k,{x:0,y:0},{x:V,y:X},F.data),As.copy(F.data,k,{x:0,y:re-1},{x:V,y:X-1},{width:J,height:1}),As.copy(F.data,k,{x:0,y:0},{x:V,y:X+re},{width:J,height:1}),As.copy(F.data,k,{x:J-1,y:0},{x:V-1,y:X},{width:1,height:re}),As.copy(F.data,k,{x:0,y:0},{x:V+J,y:X},{width:1,height:re})}this.image=k,this.iconPositions=d,this.patternPositions=p}addImages(o,u,d){for(const p in o){const _=o[p],b={x:0,y:0,w:_.data.width+2*us,h:_.data.height+2*us};d.push(b),u[p]=new Ow(b,_),_.hasRenderCallback&&this.haveRenderCallbacks.push(p)}}patchUpdatedImages(o,u){this.haveRenderCallbacks=this.haveRenderCallbacks.filter(d=>o.hasImage(d)),o.dispatchRenderCallbacks(this.haveRenderCallbacks);for(const d in o.updatedImages)this.patchUpdatedImage(this.iconPositions[d],o.getImage(d),u),this.patchUpdatedImage(this.patternPositions[d],o.getImage(d),u)}patchUpdatedImage(o,u,d){if(!o||!u||o.version===u.version)return;o.version=u.version;const[p,_]=o.tl;d.update(u.data,void 0,{x:p,y:_})}}xn(Ow,"ImagePosition"),xn(VP,"ImageAtlas");const al={horizontal:1,vertical:2,horizontalOnly:3},GP=-17;class vy{constructor(){this.scale=1,this.fontStack="",this.imageName=null}static forText(o,u){const d=new vy;return d.scale=o||1,d.fontStack=u,d}static forImage(o){const u=new vy;return u.imageName=o,u}}class im{constructor(){this.text="",this.sectionIndex=[],this.sections=[],this.imageSectionID=null}static fromFeature(o,u){const d=new im;for(let p=0;p<o.sections.length;p++){const _=o.sections[p];_.image?d.addImageSection(_):d.addTextSection(_,u)}return d}length(){return this.text.length}getSection(o){return this.sections[this.sectionIndex[o]]}getSections(){return this.sections}getSectionIndex(o){return this.sectionIndex[o]}getCharCode(o){return this.text.charCodeAt(o)}verticalizePunctuation(o){this.text=function(u,d){let p="";for(let _=0;_<u.length;_++){const b=u.charCodeAt(_+1)||null,E=u.charCodeAt(_-1)||null;p+=!d&&(b&&t0(b)&&!_y[u[_+1]]||E&&t0(E)&&!_y[u[_-1]])||!_y[u[_]]?u[_]:_y[u[_]]}return p}(this.text,o)}trim(){let o=0;for(let d=0;d<this.text.length&&k0[this.text.charCodeAt(d)];d++)o++;let u=this.text.length;for(let d=this.text.length-1;d>=0&&d>=o&&k0[this.text.charCodeAt(d)];d--)u--;this.text=this.text.substring(o,u),this.sectionIndex=this.sectionIndex.slice(o,u)}
120substring(o,u){const d=new im;return d.text=this.text.substring(o,u),d.sectionIndex=this.sectionIndex.slice(o,u),d.sections=this.sections,d}toString(){return this.text}getMaxScale(){return this.sectionIndex.reduce((o,u)=>Math.max(o,this.sections[u].scale),0)}addTextSection(o,u){this.text+=o.text,this.sections.push(vy.forText(o.scale,o.fontStack||u));const d=this.sections.length-1;for(let p=0;p<o.text.length;++p)this.sectionIndex.push(d)}addImageSection(o){const u=o.image?o.image.name:"";if(u.length===0)return void ct("Can't add FormattedSection with an empty image.");const d=this.getNextImageSectionCharCode();d?(this.text+=String.fromCharCode(d),this.sections.push(vy.forImage(u)),this.sectionIndex.push(this.sections.length-1)):ct("Reached maximum number of images 6401")}getNextImageSectionCharCode(){return this.imageSectionID?this.imageSectionID>=63743?null:++this.imageSectionID:(this.imageSectionID=57344,this.imageSectionID)}}function Dw(l,o,u,d,p,_,b,E,k,M,F,$,V,X,J){const re=im.fromFeature(l,p);$===al.vertical&&re.verticalizePunctuation(V);let pe=[];const Ce=function(Ge,vt,ft,Dt,Xt,Ct){if(!Ge)return[];const zt=[],Nt=function(un,Tn,fn,Qn,rn,In){let Jn=0;for(let kr=0;kr<un.length();kr++){const er=un.getSection(kr);Jn+=qP(un.getCharCode(kr),er,Qn,rn,Tn,In)}return Jn/Math.max(1,Math.ceil(Jn/fn))}(Ge,vt,ft,Dt,Xt,Ct),Gt=Ge.text.indexOf("​")>=0;let nn=0;for(let un=0;un<Ge.length();un++){const Tn=Ge.getSection(un),fn=Ge.getCharCode(un);if(k0[fn]||(nn+=qP(fn,Tn,Dt,Xt,vt,Ct)),un<Ge.length()-1){const Qn=!((Mt=fn)<11904||!(mn["Bopomofo Extended"](Mt)||mn.Bopomofo(Mt)||mn["CJK Compatibility Forms"](Mt)||mn["CJK Compatibility Ideographs"](Mt)||mn["CJK Compatibility"](Mt)||mn["CJK Radicals Supplement"](Mt)||mn["CJK Strokes"](Mt)||mn["CJK Symbols and Punctuation"](Mt)||mn["CJK Unified Ideographs Extension A"](Mt)||mn["CJK Unified Ideographs"](Mt)||mn["Enclosed CJK Letters and Months"](Mt)||mn["Halfwidth and Fullwidth Forms"](Mt)||mn.Hiragana(Mt)||mn["Ideographic Description Characters"](Mt)||mn["Kangxi Radicals"](Mt)||mn["Katakana Phonetic Extensions"](Mt)||mn.Katakana(Mt)||mn["Vertical Forms"](Mt)||mn["Yi Radicals"](Mt)||mn["Yi Syllables"](Mt)));(bV[fn]||Qn||Tn.imageName)&&zt.push(HP(un+1,nn,Nt,zt,xV(fn,Ge.getCharCode(un+1),Qn&&Gt),!1))}}var Mt;return YP(HP(Ge.length(),nn,Nt,zt,0,!0))}(re,M,_,o,d,X),{processBidirectionalText:ze,processStyledBidirectionalText:ke}=L;if(ze&&re.sections.length===1){const Ge=ze(re.toString(),Ce);for(const vt of Ge){const ft=new im;ft.text=vt,ft.sections=re.sections;for(let Dt=0;Dt<vt.length;Dt++)ft.sectionIndex.push(0);pe.push(ft)}}else if(ke){const Ge=ke(re.text,re.sectionIndex,Ce);for(const vt of Ge){const ft=new im;ft.text=vt[0],ft.sectionIndex=vt[1],ft.sections=re.sections,pe.push(ft)}}else pe=function(Ge,vt){const ft=[],Dt=Ge.text;let Xt=0;for(const Ct of vt)ft.push(Ge.substring(Xt,Ct)),Xt=Ct;return Xt<Dt.length&&ft.push(Ge.substring(Xt,Dt.length)),ft}(re,Ce);const Be=[],We={positionedLines:Be,text:re.toString(),top:F[1],bottom:F[1],left:F[0],right:F[0],writingMode:$,iconsInText:!1,verticalizable:!1,hasBaseline:!1};return function(Ge,vt,ft,Dt,Xt,Ct,zt,Nt,Gt,nn,Mt,un){let Tn=0,fn=0,Qn=0;const rn=Nt==="right"?1:Nt==="left"?0:.5;let In=!1;for(const nr of Xt){const rr=nr.getSections();for(const ri of rr){if(ri.imageName)continue;const hi=vt[ri.fontStack];if(hi&&(In=hi.ascender!==void 0&&hi.descender!==void 0,!In))break}if(!In)break}let Jn=0;for(const nr of Xt){nr.trim();const rr=nr.getMaxScale(),ri=(rr-1)*aa,hi={positionedGlyphs:[],lineOffset:0};Ge.positionedLines[Jn]=hi;const di=hi.positionedGlyphs;let ii=0;if(!nr.length()){fn+=Ct,++Jn;continue}let Ui=0,to=0;for(let oi=0;oi<nr.length();oi++){const Oo=nr.getSection(oi),bo=nr.getSectionIndex(oi),Yi=nr.getCharCode(oi);let Ir=Oo.scale,xo=null,fi=null,Xa=null,wo=aa,sa=0;const Zo=!(Gt===al.horizontal||!Mt&&!Wg(Yi)||Mt&&(k0[Yi]||(kr=Yi,mn.Arabic(kr)||mn["Arabic Supplement"](kr)||mn["Arabic Extended-A"](kr)||mn["Arabic Presentation Forms-A"](kr)||mn["Arabic Presentation Forms-B"](kr))));if(Oo.imageName){const Ka=Dt[Oo.imageName];if(!Ka)continue;Xa=Oo.imageName,Ge.iconsInText=Ge.iconsInText||!0,fi=Ka.paddedRect;const Xo=Ka.displaySize;Ir=Ir*aa/un,xo={width:Xo[0],height:Xo[1],left:us,top:-UP,advance:Zo?Xo[1]:Xo[0],localGlyph:!1}
120,sa=In?-xo.height*Ir:GP+rr*aa-Xo[1]*Ir,wo=xo.advance;const _c=(Zo?Xo[0]:Xo[1])*Ir-aa*rr;_c>0&&_c>ii&&(ii=_c)}else{const Ka=ft[Oo.fontStack];if(!Ka)continue;Ka[Yi]&&(fi=Ka[Yi]);const Xo=vt[Oo.fontStack];if(!Xo)continue;const _c=Xo.glyphs[Yi];if(!_c)continue;if(xo=_c.metrics,wo=Yi!==8203?aa:0,In){const hm=Xo.ascender!==void 0?Math.abs(Xo.ascender):0,Py=Xo.descender!==void 0?Math.abs(Xo.descender):0,My=(hm+Py)*Ir;Ui<My&&(Ui=My,to=(hm-Py)/2*Ir),sa=-hm*Ir}else sa=GP+(rr-Ir)*aa}Zo?(Ge.verticalizable=!0,di.push({glyph:Yi,imageName:Xa,x:Tn,y:fn+sa,vertical:Zo,scale:Ir,localGlyph:xo.localGlyph,fontStack:Oo.fontStack,sectionIndex:bo,metrics:xo,rect:fi}),Tn+=wo*Ir+nn):(di.push({glyph:Yi,imageName:Xa,x:Tn,y:fn+sa,vertical:Zo,scale:Ir,localGlyph:xo.localGlyph,fontStack:Oo.fontStack,sectionIndex:bo,metrics:xo,rect:fi}),Tn+=xo.advance*Ir+nn)}di.length!==0&&(Qn=Math.max(Tn-nn,Qn),In?ZP(di,rn,ii,to,Ct*rr/2):ZP(di,rn,ii,0,Ct/2)),Tn=0;const vo=Ct*rr+ii;hi.lineOffset=Math.max(ii,ri),fn+=vo,++Jn}var kr;const er=fn,{horizontalAlign:$n,verticalAlign:bi}=Lw(zt);(function(nr,rr,ri,hi,di,ii){const Ui=(rr-ri)*di,to=-ii*hi;for(const vo of nr)for(const oi of vo.positionedGlyphs)oi.x+=Ui,oi.y+=to})(Ge.positionedLines,rn,$n,bi,Qn,er),Ge.top+=-bi*er,Ge.bottom=Ge.to
120p+er,Ge.left+=-$n*Qn,Ge.right=Ge.left+Qn,Ge.hasBaseline=In}(We,o,u,d,pe,b,E,k,$,M,V,J),!function(Ge){for(const vt of Ge)if(vt.positionedGlyphs.length!==0)return!1;return!0}(Be)&&We}const k0={9:!0,10:!0,11:!0,12:!0,13:!0,32:!0},bV={10:!0,32:!0,38:!0,40:!0,41:!0,43:!0,45:!0,47:!0,173:!0,183:!0,8203:!0,8208:!0,8211:!0,8231:!0};function qP(l,o,u,d,p,_){if(o.imageName){const b=d[o.imageName];return b?b.displaySize[0]*o.scale*aa/_+p:0}{const b=u[o.fontStack],E=b&&b.glyphs[l];return E?E.metrics.advance*o.scale+p:0}}function WP(l,o,u,d){const p=Math.pow(l-o,2);return d?l<o?p/2:2*p:p+Math.abs(u)*u}function xV(l,o,u){let d=0;return l===10&&(d-=1e4),u&&(d+=150),l!==40&&l!==65288||(d+=50),o!==41&&o!==65289||(d+=50),d}function HP(l,o,u,d,p,_){let b=null,E=WP(o,u,p,_);for(const k of d){const M=WP(o-k.x,u,p,_)+k.badness;M<=E&&(b=k,E=M)}return{index:l,x:o,priorBreak:b,badness:E}}function YP(l){return l?YP(l.priorBreak).concat(l.index):[]}function Lw(l){let o=.5,u=.5;switch(l){case"right":case"top-right":case"bottom-right":o=1;break;case"left":case"top-left":case"bottom-left":o=0}switch(l){case"bottom":case"bottom-right":case"bottom-left":u=1;break;case"top":case"top-right":case"top-left":u=0}return{horizontalAlign:o,verticalAlign:u}}function ZP(l,o,u,d,p){if(!(o||u||d||p))return;const _=l.length-1,b=l[_],E=(b.x+b.metrics.advance*b.scale)*o;for(let k=0;k<=_;k++)l[k].x-=E,l[k].y+=u+d+p}function wV(l,o,u){const{horizontalAlign:d,verticalAlign:p}=Lw(u),_=o[0]-l.displaySize[0]*d,b=o[1]-l.displaySize[1]*p;
vendor: 5,074 bytes, line 120
120return{image:l,top:b,bottom:b+l.displaySize[1],left:_,right:_+l.displaySize[0]}}function XP(l,o,u,d,p,_){const b=l.image;let E;if(b.content){const pe=b.content,Ce=b.pixelRatio||1;E=[pe[0]/Ce,pe[1]/Ce,b.displaySize[0]-pe[2]/Ce,b.displaySize[1]-pe[3]/Ce]}const k=o.left*_,M=o.right*_;let F,$,V,X;u==="width"||u==="both"?(X=p[0]+k-d[3],$=p[0]+M+d[1]):(X=p[0]+(k+M-b.displaySize[0])/2,$=X+b.displaySize[0]);const J=o.top*_,re=o.bottom*_;return u==="height"||u==="both"?(F=p[1]+J-d[0],V=p[1]+re+d[2]):(F=p[1]+(J+re-b.displaySize[1])/2,V=F+b.displaySize[1]),{image:b,top:F,right:$,bottom:V,left:X,collisionPadding:E}}class Vu extends Y{constructor(o,u,d,p,_){super(o,u),this.angle=p,this.z=d,_!==void 0&&(this.segment=_)}clone(){return new Vu(this.x,this.y,this.z,this.angle,this.segment)}}function KP(l,o,u,d,p){if(o.segment===void 0)return!0;let _=o,b=o.segment+1,E=0;for(;E>-u/2;){if(b--,b<0)return!1;E-=l[b].dist(_),_=l[b]}E+=l[b].dist(l[b+1]),b++;const k=[];let M=0;for(;E<u/2;){const F=l[b],$=l[b+1];if(!$)return!1;let V=l[b-1].angleTo(F)-F.angleTo($);for(V=Math.abs((V+3*Math.PI)%(2*Math.PI)-Math.PI),k.push({distance:E,angleDelta:V}),M+=V;E-k[0].distance>d;)M-=k.shift().angleDelta;if(M>p)return!1;b++,E+=F.dist($)}return!0}function QP(l){let o=0;for(let u=0;u<l.length-1;u++)o+=l[u].dist(l[u+1]);return o}function JP(l,o,u){return l?.6*o*u:0}function eM(l,o){return Math.max(l?l.right-l.left:0,o?o.right-o.left:0)}function TV(l,o,u,d,p,_){const b=JP(u,p,_),E=eM(u,d)*_;let k=0;const M=QP(l)/2;for(let F=0;F<l.length-1;F++){const $=l[F],V=l[F+1],X=$.dist(V);if(k+X>M){const J=(M-k)/X,re=ur($.x,V.x,J),pe=ur($.y,V.y,J),Ce=new Vu(re,pe,0,V.angleTo($),F);return!b||KP(l,Ce,E,b,o)?Ce:void 0}k+=X}}function EV(l,o,u,d,p,_,b,E,k){const M=JP(d,_,b),F=eM(d,p),$=F*b,V=l[0].x===0||l[0].x===k||l[0].y===0||l[0].y===k;return o-$<o/4&&(o=$+o/4),tM(l,V?o/2*E%o:(F/2+2*_)*b*E%o,o,M,u,$,V,!1,k)}function tM(l,o,u,d,p,_,b,E,k){const M=_/2,F=QP(l);let $=0,V=o-u,X=[];for(let J=0;J<l.length-1;J++){const re=l[J],pe=l[J+1],Ce=re.dist(pe),ze=pe.angleTo(re);for(;V+u<$+Ce;){V+=u;const ke=(V-$)/Ce,Be=ur(re.x,pe.x,ke),We=ur(re.y,pe.y,ke);if(Be>=0&&Be<k&&We>=0&&We<k&&V-M>=0&&V+M<=F){const Ge=new Vu(Be,We,0,ze,J);Ge._round(),d&&!KP(l,Ge,_,d,p)||X.push(Ge)}}$+=Ce}return E||X.length||b||(X=tM(l,$/2,u,d,p,_,b,!0,k)),X}function nM(l,o,u,d,p){const _=[];for(let b=0;b<l.length;b++){const E=l[b];let k;for(let M=0;M<E.length-1;M++){let F=E[M],$=E[M+1];F.x<o&&$.x<o||(F.x<o?F=new Y(o,F.y+(o-F.x)/($.x-F.x)*($.y-F.y))._round():$.x<o&&($=new Y(o,F.y+(o-F.x)/($.x-F.x)*($.y-F.y))._round()),F.y<u&&$.y<u||(F.y<u?F=new Y(F.x+(u-F.y)/($.y-F.y)*($.x-F.x),u)._round():$.y<u&&($=new Y(F.x+(u-F.y)/($.y-F.y)*($.x-F.x),u)._round()),F.x>=d&&$.x>=d||(F.x>=d?F=new Y(d,F.y+(d-F.x)/($.x-F.x)*($.y-F.y))._round():$.x>=d&&($=new Y(d,F.y+(d-F.x)/($.x-F.x)*($.y-F.y))._round()),F.y>=p&&$.y>=p||(F.y>=p?F=new Y(F.x+(p-F.y)/($.y-F.y)*($.x-F.x),p)._round():$.y>=p&&($=new Y(F.x+(p-F.y)/($.y-F.y)*($.x-F.x),p)._round()),k&&F.equals(k[k.length-1])||(k=[F],_.push(k)),k.push($)))))}}return _}xn(Vu,"Anchor");const by=1e20;function rM(l,o,u,d,p,_,b,E,k){for(let M=o;M<o+d;M++)iM(l,u*_+M,_,p,b,E,k);for(let M=u;M<u+p;M++)iM(l,M*_+o,1,d,b,E,k)}function iM(l,o,u,d,p,_,b){_[0]=0,b[0]=-by,b[1]=by,p[0]=l[o];for(let E=1,k=0,M=0;E<d;E++){p[E]=l[o+E*u];const F=E*E;do{const $=_[k];M=(p[E]-p[$]+F-$*$)/(E-$)/2}while(M<=b[k]&&--k>-1);k++,_[k]=E,b[k]=M,b[k+1]=by}for(let E=0,k=0;E<d;E++){for(;b[k+1]<E;)k++;const M=_[k],F=E-M;l[o+E*u]=p[M]+F*F}}const gc=2,Rw={none:0,ideographs:1,all:2};class om{constructor(o,u,d){this.requestManager=o,this.localGlyphMode=u,this.localFontFamily=d,this.entries={},this.localGlyphs={200:{},400:{},500:{},900:{}}}setURL(o){this.url=o}getGlyphs(o,u){const d=[];for(const p in o)for(const _ of o[p])d.push({stack:p,id:_});Ne(d,({stack:p,id:_},b)=>{let E=this.entries[p];E||(E=this.entries[p]={glyphs:{},requests:{},ranges:{},ascender:void 0,descender:void 0});let k=E.glyphs[_];if(k!==void 0)return void b(null,{stack:p,id:_,glyph:k});if(k=this._tinySDF(E,p,_),k)return E.glyphs[_]=k,void b(null,{stack:p,id:_,glyph:k});const M=Math.floor(_/256);if(256*M>65535)return void b(new Error("glyphs > 65535 not supported"));if(E.ranges[M])return void b(null,{stack:p,id:_,glyph:k});let F=E.requests[M];F||(F=E.requests[M]=[],om.loadGlyphRange(p,M,this.url,this.requestManager,($,V)=>{if(V){E.ascender=V.ascender,E.descender=V.descender;for(const X in V.glyphs)this._doesCharSupportLocalGlyph(+X)||(E.glyphs[+X]=V.glyphs[+X]);E.ranges[M]=!0}for(const X of F)X($,V);delete E.requests[M]})),F.push(($,V)=>{$?b($):V&&b(null,{stack:p,id:_,glyph:V.glyphs[_]||null})})},(p,_)=>{if(p)u(p);else if(_){const b={};for(const{stack:E,id:k,glyph:M}of _)b[E]===void 0&&(b[E]={}),b[E].glyphs===void 0&&(b[E].glyphs={}),b[E].glyphs[k]=M&&{id:M.id,bitmap:M.bitmap.clone(),metrics:M.metrics},b[E].ascender=this.entries[E].ascender,b[E].descender=this.entries[E].descender;u(null,b)}})}_doesCharSupportLocalGlyph(o){return this.localGlyphMode!==Rw.none&&(this.localGlyphMode===Rw.all?!!this.localFontFamily:!!this.localFontFamily&&
120(mn["CJK Unified Ideographs"](o)||mn["Hangul Syllables"](o)||mn.Hiragana(o)||mn.Katakana(o)||mn["CJK Symbols and Punctuation"](o)))}_tinySDF(o,u,d){const p=this.localFontFamily;if(!p||!this._doesCharSupportLocalGlyph(d))return;let _=o.tinySDF;if(!_){let re="400";/bold/i.test(u)?re="900":/medium/i.test(u)?re="500":/light/i.test(u)&&(re="200"),_=o.tinySDF=new om.TinySDF({fontFamily:p,fontWeight:re,fontSize:24*gc,buffer:3*gc,radius:8*gc}),_.fontWeight=re}if(this.localGlyphs[_.fontWeight][d])return this.localGlyphs[_.fontWeight][d];const b=String.fromCharCode(d),{data:E,width:k,height:M,glyphWidth:F,glyphHeight:$,glyphLeft:V,glyphTop:X,glyphAdvance:J}=_.draw(b);return this.localGlyphs[_.fontWeight][d]={id:d,bitmap:new ju({width:k,height:M},E),metrics:{width:F/gc,height:$/gc,left:V/gc,top:X/gc-27,advance:J/gc,localGlyph:!0}}}}om.loadGlyphRange=function(l,o,u,d,p){const _=256*o,b=_+255,E=d.transformRequest(d.normalizeGlyphsURL(u).replace("{fontstack}",l).replace("{range}",`${_}-${b}`),Ni.Glyphs);Ao(E,(k,M)=>{if(k)p(k);else if(M){const F={},$=function(V){return new C0(V).readFields(yV,{})}(M);for(const V of $.glyphs)F[V.id]=V;p(null,{glyphs:F,ascender:$.ascender,descender:$.descender})}})},om.TinySDF=class{constructor({fontSize:l=24,buffer:o=3,radius:u=8,cutoff:d=.25,fontFamily:p="sans-serif",fontWeight:_="normal",fontStyle:b="normal"}={}){this.buffer=o,this.cutoff=d,this.radius=u;const E=this.size=l+4*o,k=this._createCanvas(E),M=this.ctx=k.getContext("2d",{willReadFrequently:!0});M.font=`${b} ${_} ${l}px ${p}`,M.textBaseline="alphabetic",M.textAlign="left",M.fillStyle="black",this.gridOuter=new Float64Array(E*E),this.gridInner=new Float64Array(E*E),this.f=new Float64Array(E),this.z=new Float64Array(E+1),this.v=new Uint16Array(E)}_createCanvas(l){const o=document.createElement("canvas");return o.width=o.height=l,o}draw(l){const{width:o,actualBoundingBoxAscent:u,actualBoundingBoxDescent:d,actualBoundingBoxLeft:p,actualBoundingBoxRight:_}=this.ctx.measureText(l),b=Math.ceil(u),E=Math.max(0,Math.min(this.size-this.buffer,Math.ceil(_-p))),k=Math.min(this.size-this.buffer,b+Math.ceil(d)),M=E+2*this.buffer,F=k+2*this.buffer,$=Math.max(M*F,0),V=new Uint8ClampedArray($),X={data:V,width:M,height:F,glyphWidth:E,glyphHeight:k,glyphTop:b,glyphLeft:0,glyphAdvance:o};if(E===0||k===0)return X;const{ctx:J,buffer:re,gridInner:pe,gridOuter:Ce}=this;J.clearRect(re,re,E,k),J.fillText(l,re,re+b);const ze=J.getImageData(re,re,E,k);Ce.fill(by,0,$),pe.fill(0,0,$);for(let ke=0;ke<k;ke++)for(let Be=0;Be<E;Be++){const We=ze.data[4*(ke*E+Be)+3]/255;if(We===0)continue;const Ge=(ke+re)*M+Be+re;if(We===1)Ce[Ge]=0,pe[Ge]=by;else{const vt=.5-We;Ce[Ge]=vt>0?vt*vt:0,pe[Ge]=vt<0?vt*vt:0}}rM(Ce,0,0,M,F,M,this.f,this.v,this.z),rM(pe,re,re,E,k,M,this.f,this.v,this.z);for(let ke=0;ke<$;ke++){const Be=Math.sqrt(Ce[ke])-Math.sqrt(pe[ke]);V[ke]=Math.round(255-255*(Be/this.radius+this.cutoff))}return X}};const am=us;function oM(l,o,u,d){const p=[],_=l.image,b=_.pixelRatio,E=_.paddedRect.w-2*am,k=_.paddedRect.h-2*am,M=l.right-l.left,F=l.bottom-l.top,$=_.stretchX||[[0,E]],V=_.stretchY||[[0,k]],X=(Ct,zt)=>Ct+zt[1]-zt[0],J=$.reduce(X,0),re=V.reduce(X,0),pe=E-J,Ce=k-re;let ze=0,ke=J,Be=0,We=re,Ge=0,vt=pe,ft=0,Dt=Ce;if(_.content&&d){const Ct=_.content;ze=A0($,0,Ct[0]),Be=A0(V,0,Ct[1]),ke=A0($,Ct[0],Ct[2]),We=A0(V,Ct[1],Ct[3]),Ge=Ct[0]-ze,ft=Ct[1]-Be,vt=Ct[2]-Ct[0]-ke,Dt=Ct[3]-Ct[1]-We}const Xt=(Ct,zt,Nt,Gt)=>{const nn=P0(Ct.stretch-ze,ke,M,l.left),Mt=M0(Ct.fixed-Ge,vt,Ct.stretch,J),un=P0(zt.stretch-Be,We,F,l.top),Tn=M0(zt.fixed-ft,Dt,zt.stretch,re),fn=P0(Nt.stretch-ze,ke,M,l.left),Qn=M0(Nt.fixed-Ge,vt,Nt.stretch,J),rn=P0(Gt.stretch-Be,We,F,l.top),In=M0(Gt.fixed-ft,Dt,Gt.stretch,re),Jn=new Y(nn,un),kr=new Y(fn,un),er=new Y(fn,rn),$n=new Y(nn,rn),bi=new Y(Mt/b,Tn/b),nr=new Y(Qn/b,In/b),rr=o*Math.PI/180;if(rr){const di=Math.sin(rr),ii=Math.cos(rr),Ui=[ii,-di,di,ii];Jn._matMult(Ui),kr._matMult(Ui),$n._matMult(Ui),er._matMult(Ui)}const ri=Ct.stretch+Ct.fixed,hi=zt.stretch+zt.fixed;return{tl:Jn,tr:kr,bl:$n,br:er,tex:{x:_.paddedRect.x+am+ri,y:_.paddedRect.y+am+hi,w:Nt.stretch+Nt.fixed-ri,h:Gt.stretch+Gt.fixed-hi},writingMode:void 0,glyphOffset:[0,0],sectionIndex:0,pixelOffsetTL:bi,pixelOffsetBR:nr,minFontScaleX:vt/b/M,minFontScaleY:
120Dt/b/F,isSDF:u}};if(d&&(_.stretchX||_.stretchY)){const Ct=aM($,pe,J),zt=aM(V,Ce,re);for(let Nt=0;Nt<Ct.length-1;Nt++){const Gt=Ct[Nt],nn=Ct[Nt+1];for(let Mt=0;Mt<zt.length-1;Mt++)p.push(Xt(Gt,zt[Mt],nn,zt[Mt+1]))}}else p.push(Xt({fixed:0,stretch:-1},{fixed:0,stretch:-1},{fixed:0,stretch:E+1},{fixed:0,stretch:k+1}));return p}function A0(l,o,u){let d=0;for(const p of l)d+=Math.max(o,Math.min(u,p[1]))-Math.max(o,Math.min(u,p[0]));return d}function aM(l,o,u){const d=[{fixed:-am,stretch:0}];for(const[p,_]of l){const b=d[d.length-1];d.push({fixed:p-b.stretch,stretch:b.stretch}),d.push({fixed:p-b.stretch,stretch:b.stretch+(_-p)})}return d.push({fixed:o+am,stretch:u}),d}function P0(l,o,u,d){return l/o*u+d}function M0(l,o,u,d){return l-o*u/d}function SV(l,o,u,d){const p=o+l.positionedLines[d].lineOffset;return d===0?u+p/2:u+(p+(o+l.positionedLines[d-1].lineOffset))/2}class CV{constructor(o=[],u=kV){if(this.data=o,this.length=this.data.length,this.compare=u,this.length>0)for(let d=(this.length>>1)-1;d>=0;d--)this._down(d)}push(o){this.data.push(o),this.length++,this._up(this.length-1)}pop(){if(this.length===0)return;const o=this.data[0],u=this.data.pop();return this.length--,this.length>0&&(this.data[0]=u,this._down(0)),o}peek(){return this.data[0]}_up(o){const{data:u,compare:d}=this,p=u[o];for(;o>0;){const _=o-1>>1,b=u[_];if(d(p,b)>=0)break;u[o]=b,o=_}u[o]=p}_down(o){const{data:u,compare:d}=this,p=this.length>>1,_=u[o];for(;o<p;){let b=1+(o<<1),E=u[b];const k=b+1;if(k<this.length&&d(u[k],E)<0&&(b=k,E=u[k]),d(E,_)>=0)break;u[o]=E,o=b}u[o]=_}}function kV(l,o){return l<o?-1:l>o?1:0}function AV(l,o=1,u=!1){let d=1/0,p=1/0,_=-1/0,b=-1/0;const E=l[0];for(let X=0;X<E.length;X++){const J=E[X];(!X||J.x<d)&&(d=J.x),(!X||J.y<p)&&(p=J.y),(!X||J.x>_)&&(_=J.x),(!X||J.y>b)&&(b=J.y)}const k=Math.min(_-d,b-p);let M=k/2;const F=new CV([],PV);if(k===0)return new Y(d,p);for(let X=d;X<_;X+=k)for(let J=p;J<b;J+=k)F.push(new sm(X+M,J+M,M,l));let $=function(X){let J=0,re=0,pe=0;const Ce=X[0];for(let ze=0,ke=Ce.length,Be=ke-1;ze<ke;Be=ze++){const We=Ce[ze],Ge=Ce[Be],vt=We.x*Ge.y-Ge.x*We.y;re+=(We.x+Ge.x)*vt,pe+=(We.y+Ge.y)*vt,J+=3*vt}return new sm(re/J,pe/J,0,X)}(l),V=F.length;for(;F.length;){const X=F.pop();(X.d>$.d||!$.d)&&($=X,u&&console.log("found best %d after %d probes",Math.round(1e4*X.d)/1e4,V)),X.max-$.d<=o||(M=X.h/2,F.push(new sm(X.p.x-M,X.p.y-M,M,l)),F.push(new sm(X.p.x+M,X.p.y-M,M,l)),F.push(new sm(X.p.x-M,X.p.y+M,M,l)),F.push(new sm(X.p.x+M,X.p.y+M,M,l)),V+=4)}return u&&(console.log(`num probes: ${V}`),console.log(`best distance: ${$.d}`)),$.p}function PV(l,o){return o.max-l.max}class sm{constructor(o,u,d,p){this.p=new Y(o,u),this.h=d,this.d=function(_,b){let E=!1,k=1/0;for(let M=0;M<b.length;M++){const F=b[M];for(let $=0,V=F.length,X=V-1;$<V;X=$++){const J=F[$],re=F[X];J.y>_.y!=re.y>_.y&&_.x<(re.x-J.x)*(_.y-J.y)/(re.y-J.y)+J.x&&(E=!E),k=Math.min(k,tP(_,J,re))}}return(E?1:-1)*Math.sqrt(k)}(this.p,p),this.max=this.d+this.h*Math.SQRT2}}const lm=7,Fw=Number.POSITIVE_INFINITY,MV=Math.sqrt(2);function sM(l,[o,u]){let d=0,p=0;if(u===Fw){o<0&&(o=0);const _=o/MV;switch(l){case"top-right":case"top-left":p=_-lm;break;case"bottom-right":case"bottom-left":p=-_+lm;break;case"bottom":p=-o+lm;break;case"top":p=o-lm}switch(l){case"top-right":case"bottom-right":d=-_;break;case"top-left":case"bottom-left":d=_;break;case"left":d=o;break;case"right":d=-o}}else{switch(o=Math.abs(o),u=Math.abs(u),l){case"top-right":case"top-left":case"top":p=u-lm;break;case"bottom-right":case"bottom-left":case"bottom":p=-u+lm}switch(l){case"top-right":case"bottom-right":case"right":d=-o;break;case"top-left":case"bottom-left":case"left":d=o}}return[d,p]}function IV(l,o,u,d,p,_,b,E,k,M){l.createArrays(),l.tilePixelRatio=Rn/(512*l.overscaling),l.compareText={},l.iconsNeedLinear=!1;const F=l.layers[0].layout,$=l.layers[0]._unevaluatedLayout._values,V={};if(l.textSizeData.kind==="composite"){const{minZoom:re,maxZoom:pe}=l.textSizeData;V.compositeTextSizes=[$["text-size"].possiblyEvaluate(new z(re),E),$["text-size"].possiblyEvaluate(new z(pe),E)]}if(l.iconSizeData.kind==="composite"){const{minZoom:re,maxZoom:pe}=l.iconSizeData;V.compositeIconSizes=[$["icon-size"].possiblyEvaluate(new z(re),E),$["icon-size"].possiblyEvaluate(new z(pe),E)]}V.layoutTextSize=$["text-size"].possiblyEvaluate(new z(k+1),E),V.layoutIconSize=$["icon-size"].possiblyEvaluate(new z(k+1),E),V.textMaxSize=$["text-size"].possiblyEvaluate(new z(18),E);const X=F.get("text-rotation-alignment")==="map"&&F.get("symbol-placement")!=="point",J=F.get("text-size");for(const re of l.features){const pe=F.get("text-font").evaluate(re,{},E).join(","),Ce=J.evaluate(re,{},E),ze=V.layoutTextSize.evaluate(re,{},E),ke=(V.layoutIconSize.evaluate(re,{},E),{horizontal:{},vertical:void 0}),Be=re.text;let We,Ge=[0,0];if(Be){const Dt=Be.toString(),Xt=F.get("text-letter-spacing").evaluate(re,{},E)*aa,Ct=F.get("text-line-height").evaluate(re,{},E)*aa,zt=q1(Dt)?Xt:0,Nt=F.get("text-anchor").evaluate(re,{},E),Gt=F.get("text-variable-anchor");if(!Gt){const fn=F.get("text-radial-offset").evaluate(re,{},E);Ge=fn?sM(Nt,[fn*aa,Fw]):F.get("text-offset").evaluate(re,{},E).map(Qn=>Qn*aa)}
120let nn=X?"center":F.get("text-justify").evaluate(re,{},E);const Mt=F.get("symbol-placement")==="point",un=Mt?F.get("text-max-width").evaluate(re,{},E)*aa:1/0,Tn=fn=>{l.allowVerticalPlacement&&qg(Dt)&&(ke.vertical=Dw(Be,o,u,p,pe,un,Ct,Nt,fn,zt,Ge,al.vertical,!0,ze,Ce))};if(!X&&Gt){const fn=nn==="auto"?Gt.map(rn=>Bw(rn)):[nn];let Qn=!1;for(let rn=0;rn<fn.length;rn++){const In=fn[rn];if(!ke.horizontal[In])if(Qn)ke.horizontal[In]=ke.horizontal[0];else{const Jn=Dw(Be,o,u,p,pe,un,Ct,"center",In,zt,Ge,al.horizontal,!1,ze,Ce);Jn&&(ke.horizontal[In]=Jn,Qn=Jn.positionedLines.length===1)}}Tn("left")}else{if(nn==="auto"&&(nn=Bw(Nt)),Mt||F.get("text-writing-mode").indexOf("horizontal")>=0||!qg(Dt)){const fn=Dw(Be,o,u,p,pe,un,Ct,Nt,nn,zt,Ge,al.horizontal,!1,ze,Ce);fn&&(ke.horizontal[nn]=fn)}Tn(Mt?"left":nn)}}let vt=!1;if(re.icon&&re.icon.name){const Dt=d[re.icon.name];Dt&&(We=wV(p[re.icon.name],F.get("icon-offset").evaluate(re,{},E),F.get("icon-anchor").evaluate(re,{},E)),vt=Dt.sdf,l.sdfIcons===void 0?l.sdfIcons=Dt.sdf:l.sdfIcons!==Dt.sdf&&ct("Style sheet warning: Cannot mix SDF and non-SDF icons in one buffer"),(Dt.pixelRatio!==l.pixelRatio||F.get("icon-rotate").constantOr(1)!==0)&&(l.iconsNeedLinear=!0))}const ft=cM(ke.horizontal)||ke.vertical;l.iconsInText||(l.iconsInText=!!ft&&ft.iconsInText),(ft||We)&&OV(l,re,ke,We,d,V,ze,0,Ge,vt,b,E,M)}_&&l.generateCollisionDebugBuffers(k,l.collisionBoxArray)}function Bw(l){switch(l){case"right":case"top-right":case"bottom-right":return"right";case"left":case"top-left":case"bottom-left":return"left"}return"center"}function OV(l,o,u,d,p,_,b,E,k,M,F,$,V){let X=_.textMaxSize.evaluate(o,{},$);X===void 0&&(X=b);const J=l.layers[0].layout,re=J.get("icon-offset").evaluate(o,{},$),pe=cM(u.horizontal)||u.vertical,Ce=V.name==="globe",ze=aa,ke=b/ze,Be=l.tilePixelRatio*X/ze,We=(Nt=l.overscaling,l.zoom>18&&Nt>2&&(Nt>>=1),Math.max(Rn/(512*Nt),1)*J.get("symbol-spacing")),Ge=J.get("text-padding")*l.tilePixelRatio,vt=J.get("icon-padding")*l.tilePixelRatio,ft=ce(J.get("text-max-angle")),Dt=J.get("text-rotation-alignment")==="map"&&J.get("symbol-placement")!=="point",Xt=J.get("icon-rotation-alignment")==="map"&&J.get("symbol-placement")!=="point",Ct=J.get("symbol-placement"),zt=We/2;var Nt;const Gt=J.get("icon-text-fit");let nn;d&&Gt!=="none"&&(l.allowVerticalPlacement&&u.vertical&&(nn=XP(d,u.vertical,Gt,J.get("icon-text-fit-padding"),re,ke)),pe&&(d=XP(d,pe,Gt,J.get("icon-text-fit-padding"),re,ke)));const Mt=(un,Tn,fn)=>{if(Tn.x<0||Tn.x>=Rn||Tn.y<0||Tn.y>=Rn)return;let Qn=null;if(Ce){const{x:rn,y:In,z:Jn}=V.projectTilePoint(Tn.x,Tn.y,fn);Qn={anchor:new Vu(rn,In,Jn,0,void 0),up:V.upVector(fn,Tn.x,Tn.y)}}(function(rn,In,Jn,kr,er,$n,bi,nr,rr,ri,hi,di,ii,Ui,to,vo,oi,Oo,bo,Yi,Ir,xo,fi,Xa,wo){const sa=rn.addToLineVertexArray(In,kr);let Zo,Ka,Xo,_c,hm,Py,My,UM=0,VM=0,GM=0,qM=0,Qw=-1,Jw=-1;const Jc={};let WM=Y1("");const kf=Jn?Jn.anchor:In;let eT=0,tT=0;if(rr._unevaluatedLayout.getValue("text-radial-offset")===void 0?[eT,tT]=rr.layout.get("text-offset").evaluate(Ir,{},wo).map(Ps=>Ps*aa):(eT=rr.layout.get("text-radial-offset").evaluate(Ir,{},wo)*aa,tT=Fw),rn.allowVerticalPlacement&&er.vertical){const Ps=er.vertical;if(to)Py=zw(Ps),nr&&(My=zw(nr));else{const Ms=rr.layout.get("text-rotate").evaluate(Ir,{},wo)+90;Xo=I0(ri,kf,In,hi,di,ii,Ps,Ui,Ms,vo),nr&&(_c=I0(ri,kf,In,hi,di,ii,nr,Oo,Ms))}}if($n){const Ps=rr.layout.get("icon-rotate").evaluate(Ir,{},wo),Ms=rr.layout.get("icon-text-fit")!=="none",Iy=oM($n,Ps,fi,Ms),rT=nr?oM(nr,Ps,fi,Ms):void 0;Ka=I0(ri,kf,In,hi,di,ii,$n,Oo,Ps),UM=4*Iy.length;const HM=rn.iconSizeData;let Af=null;HM.kind==="source"?(Af=[mc*rr.layout.get("icon-size").evaluate(Ir,{},wo)],Af[0]>Dh&&ct(`${rn.layerIds[0]}: Value for "icon-size" is >= ${xy}. Reduce your "icon-size".`)):HM.kind==="composite"&&(Af=[mc*xo.compositeIconSizes[0].evaluate(Ir,{},wo),mc*xo.compositeIconSizes[1].evaluate(Ir,{},wo)],(Af[0]>Dh||Af[1]>Dh)&&ct(`${rn.layerIds[0]}: Value for "icon-size" is >= ${xy}. Reduce your "icon-size".`)),rn.addSymbols(rn.icon,Iy,Af,Yi,bo,Ir,!1,Jn,In,sa.lineStartIndex,sa.lineLength,-1,Xa,wo),Qw=rn.icon.placedSymbolArray.length-1,rT&&(VM=4*rT.length,rn.addSymbols(rn.icon,rT,Af,Yi,bo,Ir,al.vertical,Jn,In,sa.lineStartIndex,sa.lineLength,-1,Xa,wo),Jw=rn.icon.placedSymbolArray.length-1)}for(const Ps in er.horizontal){const Ms=er.horizontal[Ps];Zo||(WM=Y1(Ms.text),to?hm=zw(Ms):Zo=I0(ri,kf,In,hi,di,ii,Ms,Ui,rr.layout.get("text-rotate").evaluate(Ir,{},wo),vo));const Iy=Ms.positionedLines.length===1;if(GM+=lM(rn,Jn,In,Ms,bi,rr,to,Ir,vo,sa,er.vertical?al.horizontal:al.horizontalOnly,Iy?Object.keys(er.horizontal):[Ps],Jc,Qw,xo,Xa,wo),Iy)break}er.vertical&&(qM+=lM(rn,Jn,In,er.vertical,bi,rr,to,Ir,vo,sa,al.vertical,["vertical"],Jc,Jw,xo,Xa,wo));let Nh=-1;const nT=(Ps,Ms)=>Ps?Math.max(Ps,Ms):Ms;Nh=nT(hm,Nh),Nh=nT(Py,Nh),Nh=nT(My,Nh);const a6=Nh>-1?1:0;rn.glyphOffsetArray.length>=Rh.MAX_GLYPHS&&ct("Too many glyphs being rendered in a tile. See https://github.com/mapbox/mapbox-gl-js/issues/2907"),Ir.sortKey!==void 0&&rn.addToSortKey
120Ranges(rn.symbolInstances.length,Ir.sortKey),rn.symbolInstances.emplaceBack(kf.x,kf.y,kf.z,In.x,In.y,Jc.right>=0?Jc.right:-1,Jc.center>=0?Jc.center:-1,Jc.left>=0?Jc.left:-1,Jc.vertical>=0?Jc.vertical:-1,Qw,Jw,WM,Zo!==void 0?Zo:rn.collisionBoxArray.length,Zo!==void 0?Zo+1:rn.collisionBoxArray.length,Xo!==void 0?Xo:rn.collisionBoxArray.length,Xo!==void 0?Xo+1:rn.collisionBoxArray.length,Ka!==void 0?Ka:rn.collisionBoxArray.length,Ka!==void 0?Ka+1:rn.collisionBoxArray.length,_c||rn.collisionBoxArray.length,_c?_c+1:rn.collisionBoxArray.length,hi,GM,qM,UM,VM,a6,0,eT,tT,Nh)})(l,Tn,Qn,un,u,d,p,nn,l.layers[0],l.collisionBoxArray,o.index,o.sourceLayerIndex,l.index,Ge,Dt,k,0,vt,Xt,re,o,_,M,F,$)};if(Ct==="line")for(const un of nM(o.geometry,0,0,Rn,Rn)){const Tn=EV(un,We,ft,u.vertical||pe,d,ze,Be,l.overscaling,Rn);for(const fn of Tn)pe&&DV(l,pe.text,zt,fn)||Mt(un,fn,$)}else if(Ct==="line-center"){for(const un of o.geometry)if(un.length>1){const Tn=TV(un,ft,u.vertical||pe,d,ze,Be);Tn&&Mt(un,Tn,$)}}else if(o.type==="Polygon")for(const un of Ew(o.geometry,0)){const Tn=AV(un,16);Mt(un[0],new Vu(Tn.x,Tn.y,0,0,void 0),$)}else if(o.type==="LineString")for(const un of o.geometry)Mt(un,new Vu(un[0].x,un[0].y,0,0,void 0),$);else if(o.type==="Point")for(const un of o.geometry)for(const Tn of un)Mt([Tn],new Vu(Tn.x,Tn.y,0,0,void 0),$)}const xy=255,Dh=xy*mc;function lM(l,o,u,d,p,_,b,E,k,M,F,$,V,X,J,re,pe){const Ce=function(Be,We,Ge,vt,ft,Dt,Xt,Ct){const zt=[];if(We.positionedLines.length===0)return zt;const Nt=vt.layout.get("text-rotate").evaluate(Dt,{})*Math.PI/180,Gt=function(fn){const Qn=fn[0],rn=fn[1],In=Qn*rn;return In>0?[Qn,-rn]:In<0?[-Qn,rn]:Qn===0?[rn,Qn]:[rn,-Qn]}(Ge);let nn=Math.abs(We.top-We.bottom);for(const fn of We.positionedLines)nn-=fn.lineOffset;const Mt=We.positionedLines.length,un=nn/Mt;let Tn=We.top-Ge[1];for(let fn=0;fn<Mt;++fn){const Qn=We.positionedLines[fn];Tn=SV(We,un,Tn,fn);for(const rn of Qn.positionedGlyphs){if(!rn.rect)continue;const In=rn.rect||{};let Jn=UP+1,kr=!0,er=1,$n=0;if(rn.imageName){const fi=Xt[rn.imageName];if(!fi)continue;if(fi.sdf){ct("SDF images are not supported in formatted text and will be ignored.");continue}kr=!1,er=fi.pixelRatio,Jn=us/er}const bi=(ft||Ct)&&rn.vertical,nr=rn.metrics.advance*rn.scale/2,rr=rn.metrics,ri=rn.rect;if(ri===null)continue;Ct&&We.verticalizable&&($n=rn.imageName?nr-rn.metrics.width*rn.scale/2:0);const hi=ft?[rn.x+nr,rn.y]:[0,0];let di=[0,0],ii=[0,0],Ui=!1;ft||(bi?(ii=[rn.x+nr+Gt[0],rn.y+Gt[1]-$n],Ui=!0):di=[rn.x+nr+Ge[0],rn.y+Ge[1]-$n]);const to=ri.w*rn.scale/(er*(rn.localGlyph?gc:1)),vo=ri.h*rn.scale/(er*(rn.localGlyph?gc:1));let oi,Oo,bo,Yi;if(bi){const fi=rn.y-Tn,Xa=new Y(-nr,nr-fi),wo=-Math.PI/2,sa=new Y(...ii);oi=new Y(-nr+di[0],di[1]),oi._rotateAround(wo,Xa)._add(sa),oi.x+=-fi+nr,oi.y-=(rr.left-Jn)*rn.scale;const Zo=rn.imageName?rr.advance*rn.scale:aa*rn.scale,Ka=String.fromCharCode(rn.glyph);aV(Ka)?oi.x+=(1-Jn)*rn.scale:sV(Ka)?oi.x+=Zo-rr.height*rn.scale+(-Jn-1)*rn.scale:oi.x+=rn.imageName||rr.width+2*Jn===ri.w&&rr.height+2*Jn===ri.h?(Zo-vo)/2:(Zo-(rr.height+2*Jn)*rn.scale)/2,Oo=new Y(oi.x,oi.y-to),bo=new Y(oi.x+vo,oi.y),Yi=new Y(oi.x+vo,oi.y-to)}else{const fi=(rr.left-Jn)*rn.scale-nr+di[0],Xa=(-rr.top-Jn)*rn.scale+di[1],wo=fi+to,sa=Xa+vo;oi=new Y(fi,Xa),Oo=new Y(wo,Xa),bo=new Y(fi,sa),Yi=new Y(wo,sa)}if(Nt){let fi;fi=ft?new Y(0,0):Ui?new Y(Gt[0],Gt[1]):new Y(Ge[0],Ge[1]),oi._rotateAround(Nt,fi),Oo._rotateAround(Nt,fi),bo._rotateAround(Nt,fi),Yi._rotateAround(Nt,fi)}const Ir=new Y(0,0),xo=new Y(0,0);zt.push({tl:oi,tr:Oo,bl:bo,br:Yi,tex:In,writingMode:We.writingMode,glyphOffset:hi,sectionIndex:rn.sectionIndex,isSDF:kr,pixelOffsetTL:Ir,pixelOffsetBR:xo,minFontScaleX:0,minFontScaleY:0})}}return zt}(0,d,k,_,b,E,p,l.allowVerticalPlacement),ze=l.textSizeData;let ke=null;ze.kind==="source"?(ke=[mc*_.layout.get("text-size").evaluate(E,{},pe)],ke[0]>Dh&&ct(`${l.layerIds[0]}: Value for "text-size" is >= ${xy}. Reduce your "text-size".`)):ze.kind==="composite"&&(ke=[mc*J.compositeTextSizes[0].evaluate(E,{},pe),mc*J.compositeTextSizes[1].evaluate(E,{},pe)],(ke[0]>Dh||ke[1]>Dh)&&ct(`${l.layerIds[0]}: Value for "text-size" is >= ${xy}. Reduce your "text-size".`)),l.addSymbols(l.text,Ce,ke,k,b,E,F,o,u,M.lineStartIndex,M.lineLength,X,re,pe);for(const Be of $)V[Be]=l.text.placedSymbolArray.length-1;return 4*Ce.length}function cM(l){for(const o in l)return l[o];return null}function I0(l,o,u,d,p,_,b,E,k,M){let F=b.top,$=b.bottom,V=b.left,X=b.right;const J=b.collisionPadding;if(J&&(V-=J[0],F-=J[1],X+=J[2],$+=J[3]),k){const re=new Y(V,F),pe=new Y(X,F),Ce=new Y(V,$),ze=new Y(X,$),ke=ce(k);let Be=new Y(0,0);
vendor: 4,597 bytes, line 120
120M&&(Be=new Y(M[0],M[1])),re._rotateAround(ke,Be),pe._rotateAround(ke,Be),Ce._rotateAround(ke,Be),ze._rotateAround(ke,Be),V=Math.min(re.x,pe.x,Ce.x,ze.x),X=Math.max(re.x,pe.x,Ce.x,ze.x),F=Math.min(re.y,pe.y,Ce.y,ze.y),$=Math.max(re.y,pe.y,Ce.y,ze.y)}return l.emplaceBack(o.x,o.y,o.z,u.x,u.y,V,F,X,$,E,d,p,_),l.length-1}function zw(l){l.collisionPadding&&(l.top-=l.collisionPadding[1],l.bottom+=l.collisionPadding[3]);const o=l.bottom-l.top;return o>0?Math.max(10,o):null}function DV(l,o,u,d){const p=l.compareText;if(o in p){const _=p[o];for(let b=_.length-1;b>=0;b--)if(d.dist(_[b])<u)return!0}else p[o]=[];return p[o].push(d),!1}function uM(l,o){const u=l.fovAboveCenter,d=l.elevation?l.elevation.getMinElevationBelowMSL()*o:0,p=(l._camera.position[2]*l.worldSize-d)/Math.cos(l._pitch),_=Math.sin(u)*p/Math.sin(Math.max(Math.PI/2-l._pitch-u,.01)),b=Math.sin(l._pitch)*_+p;return Math.min(1.01*b,p*(1/l._horizonShift))}function Sf(l,o){if(!o.isReprojectedInTileSpace)return{scale:1<<l.z,x:l.x,y:l.y,x2:l.x+1,y2:l.y+1,projection:o};const u=Math.pow(2,-l.z),d=l.x*u,p=(l.x+1)*u,_=l.y*u,b=(l.y+1)*u,E=ol(d),k=ol(p),M=_a(_),F=_a(b),$=o.project(E,M),V=o.project(k,M),X=o.project(k,F),J=o.project(E,F);let re=Math.min($.x,V.x,X.x,J.x),pe=Math.min($.y,V.y,X.y,J.y),Ce=Math.max($.x,V.x,X.x,J.x),ze=Math.max($.y,V.y,X.y,J.y);const ke=u/16;function Be(Ge,vt,ft,Dt,Xt,Ct){const zt=(ft+Xt)/2,Nt=(Dt+Ct)/2,Gt=o.project(ol(zt),_a(Nt)),nn=Math.max(0,re-Gt.x,pe-Gt.y,Gt.x-Ce,Gt.y-ze);re=Math.min(re,Gt.x),Ce=Math.max(Ce,Gt.x),pe=Math.min(pe,Gt.y),ze=Math.max(ze,Gt.y),nn>ke&&(Be(Ge,Gt,ft,Dt,zt,Nt),Be(Gt,vt,zt,Nt,Xt,Ct))}Be($,V,d,_,p,_),Be(V,X,p,_,p,b),Be(X,J,p,b,d,b),Be(J,$,d,b,d,_),re-=ke,pe-=ke,Ce+=ke,ze+=ke;const We=1/Math.max(Ce-re,ze-pe);return{scale:We,x:re*We,y:pe*We,x2:Ce*We,y2:ze*We,projection:o}}const LV=dc(new Float32Array(16));class Lh{constructor(o){this.spec=o,this.name=o.name,this.wrap=!1,this.requiresDraping=!1,this.supportsWorldCopies=!1,this.supportsTerrain=!1,this.supportsFog=!1,this.supportsFreeCamera=!1,this.zAxisUnit="meters",this.isReprojectedInTileSpace=!0,this.unsupportedLayers=["custom"],this.center=[0,0],this.range=[3.5,7]}project(o,u){return{x:0,y:0,z:0}}unproject(o,u){return new ni(0,0)}projectTilePoint(o,u,d){return{x:o,y:u,z:0}}locationPoint(o,u,d=!0){return o._coordinatePoint(o.locationCoordinate(u),d)}pixelsPerMeter(o,u){return pc(1,o)*u}pixelSpaceConversion(o,u,d){return 1}farthestPixelDistance(o){return uM(o,o.pixelsPerMeter)}pointCoordinate(o,u,d,p){const _=o.horizonLineFromTop(!1),b=new Y(u,Math.max(_,d));return o.rayIntersectionCoordinate(o.pointRayIntersection(b,p))}pointCoordinate3D(o,u,d){const p=new Y(u,d);if(o.elevation)return o.elevation.pointCoordinate(p);{const _=this.pointCoordinate(o,p.x,p.y,0);return[_.x,_.y,_.z]}}isPointAboveHorizon(o,u){if(o.elevation)return!this.pointCoordinate3D(o,u.x,u.y);const d=o.horizonLineFromTop();return u.y<d}createInversionMatrix(o,u){return LV}createTileMatrix(o,u,d){let p,_,b;const E=d.canonical,k=dc(new Float64Array(16));if(this.isReprojectedInTileSpace){const M=Sf(E,this);p=1,_=M.x+d.wrap*M.scale,b=M.y,_f(k,k,[p/M.scale,p/M.scale,o.pixelsPerMeter/u])}else p=u/o.zoomScale(E.z),_=(E.x+Math.pow(2,E.z)*d.wrap)*p,b=E.y*p;return Qg(k,k,[_,b,0]),_f(k,k,[p/Rn,p/Rn,1]),k}upVector(o,u,d){return[0,0,1]}upVectorScale(o,u,d){return{metersToTile:1}}}class RV extends Lh{constructor(o){super(o),this.range=[4,7],this.center=o.center||[-96,37.5];const[u,d]=this.parallels=o.parallels||[29.5,45.5],p=Math.sin(ce(u));this.n=(p+Math.sin(ce(d)))/2,this.c=1+p*(2*this.n-p),this.r0=Math.sqrt(this.c)/this.n}project(o,u){const{n:d,c:p,r0:_}=this,b=ce(o-this.center[0]),E=ce(u),k=Math.sqrt(p-2*d*Math.sin(E))/d;return{x:k*Math.sin(b*d),y:k*Math.cos(b*d)-_,z:0}}unproject(o,u){const{n:d,c:p,r0:_}=this,b=_+u;let E=Math.atan2(o,Math.abs(b))*Math.sign(b);b*d<0&&(E-=Math.PI*Math.sign(o)*Math.sign(b));const k=ce(this.center[0])*d;E=se(E,-Math.PI-k,Math.PI-k);const M=ne(fe(E/d)+this.center[0],-180,180),F=Math.asin(ne((p-(o*o+b*b)*d*d)/(2*d),-1,1)),$=ne(fe(F),-va,va);return new ni(M,$)}}const wy=1.340264,Ty=-.081106,Ey=893e-6,Sy=.003796,O0=Math.sqrt(3)/2;class FV extends Lh{project(o,u){u=u/180*Math.PI,o=o/180*Math.PI;const d=Math.asin(O0*Math.sin(u)),p=d*d,_=p*p*p;return{x:.5*(o*Math.cos(d)/(O0*(wy+3*Ty*p+_*(7*Ey+9*Sy*p)))/Math.PI+.5),y:1-.5*(d*(wy+Ty*p+_*(Ey+Sy*p))/Math.PI+1),z:0}}unproject(o,u){o=(2*o-.5)*Math.PI;let d=u=(2*(1-u)-1)*Math.PI,p=d*d,_=p*p*p;for(let F,$,V,X=0;X<12&&($=d*(wy+Ty*p+_*(Ey+Sy*p))-u,V=wy+3*Ty*p+_*(7*Ey+9*Sy*p),F=$/V,d=ne(d-F,-Math.PI/3,Math.PI/3),p=d*d,_=p*p*p,!(Math.abs(F)<1e-12));++X);
vendor: 5,042 bytes, line 120
120const b=O0*o*(wy+3*Ty*p+_*(7*Ey+9*Sy*p))/Math.cos(d),E=Math.asin(Math.sin(d)/O0),k=ne(180*b/Math.PI,-180,180),M=ne(180*E/Math.PI,-va,va);return new ni(k,M)}}class BV extends Lh{constructor(o){super(o),this.wrap=!0,this.supportsWorldCopies=!0}project(o,u){return{x:.5+o/360,y:.5-u/360,z:0}}unproject(o,u){const d=360*(o-.5),p=ne(360*(.5-u),-va,va);return new ni(d,p)}}const cm=Math.PI/2;function D0(l){return Math.tan((cm+l)/2)}class zV extends Lh{constructor(o){super(o),this.center=o.center||[0,30];const[u,d]=this.parallels=o.parallels||[30,30];let p=ce(u),_=ce(d);this.southernCenter=p+_<0,this.southernCenter&&(p=-p,_=-_);const b=Math.cos(p),E=D0(p);this.n=p===_?Math.sin(p):Math.log(b/Math.cos(_))/Math.log(D0(_)/E),this.f=b*Math.pow(D0(p),this.n)/this.n}project(o,u){u=ce(u),this.southernCenter&&(u=-u),o=ce(o-this.center[0]);const d=1e-6,{n:p,f:_}=this;_>0?u<-cm+d&&(u=-cm+d):u>cm-d&&(u=cm-d);const b=_/Math.pow(D0(u),p);let E=b*Math.sin(p*o),k=_-b*Math.cos(p*o);return E=.5*(E/Math.PI+.5),k=.5*(k/Math.PI+.5),{x:E,y:this.southernCenter?k:1-k,z:0}}unproject(o,u){o=(2*o-.5)*Math.PI,this.southernCenter&&(u=1-u),u=(2*(1-u)-.5)*Math.PI;const{n:d,f:p}=this,_=p-u,b=Math.sign(_),E=Math.sign(d)*Math.sqrt(o*o+_*_);let k=Math.atan2(o,Math.abs(_))*b;_*d<0&&(k-=Math.PI*Math.sign(o)*b);const M=ne(fe(k/d)+this.center[0],-180,180),F=ne(fe(2*Math.atan(Math.pow(p/E,1/d))-cm),-va,va);return new ni(M,this.southernCenter?-F:F)}}class hM extends Lh{constructor(o){super(o),this.wrap=!0,this.supportsWorldCopies=!0,this.supportsTerrain=!0,this.supportsFog=!0,this.supportsFreeCamera=!0,this.isReprojectedInTileSpace=!1,this.unsupportedLayers=[],this.range=null}project(o,u){return{x:Yc(o),y:Zc(u),z:0}}unproject(o,u){const d=ol(o),p=_a(u);return new ni(d,p)}}const dM=ce(va);class NV extends Lh{project(o,u){const d=(u=ce(u))*u,p=d*d;return{x:.5*((o=ce(o))*(.8707-.131979*d+p*(p*(.003971*d-.001529*p)-.013791))/Math.PI+.5),y:1-.5*(u*(1.007226+d*(.015085+p*(.028874*d-.044475-.005916*p)))/Math.PI+1),z:0}}unproject(o,u){o=(2*o-.5)*Math.PI;let d=u=(2*(1-u)-1)*Math.PI,p=25,_=0,b=d*d;do{b=d*d;const M=b*b;_=(d*(1.007226+b*(.015085+M*(.028874*b-.044475-.005916*M)))-u)/(1.007226+b*(.045255+M*(.259866*b-.311325-.005916*11*M))),d=ne(d-_,-dM,dM)}while(Math.abs(_)>1e-6&&--p>0);b=d*d;const E=ne(fe(o/(.8707+b*(b*(b*b*b*(.003971-.001529*b)-.013791)-.131979))),-180,180),k=fe(d);return new ni(E,k)}}const fM=ce(va);class $V extends Lh{project(o,u){u=ce(u),o=ce(o);const d=Math.cos(u),p=2/Math.PI,_=Math.acos(d*Math.cos(o/2)),b=Math.sin(_)/_,E=.5*(o*p+2*d*Math.sin(o/2)/b)||0,k=.5*(u+Math.sin(u)/b)||0;return{x:.5*(E/Math.PI+.5),y:1-.5*(k/Math.PI+1),z:0}}unproject(o,u){let d=o=(2*o-.5)*Math.PI,p=u=(2*(1-u)-1)*Math.PI,_=25;const b=1e-6;let E=0,k=0;do{const M=Math.cos(p),F=Math.sin(p),$=2*F*M,V=F*F,X=M*M,J=Math.cos(d/2),re=Math.sin(d/2),pe=2*J*re,Ce=re*re,ze=1-X*J*J,ke=ze?1/ze:0,Be=ze?Math.acos(M*J)*Math.sqrt(1/ze):0,We=.5*(2*Be*M*re+2*d/Math.PI)-o,Ge=.5*(Be*F+p)-u,vt=.5*ke*(X*Ce+Be*M*J*V)+1/Math.PI,ft=ke*(pe*$/4-Be*F*re),Dt=.125*ke*($*re-Be*F*X*pe),Xt=.5*ke*(V*J+Be*Ce*M)+.5,Ct=ft*Dt-Xt*vt;E=(Ge*ft-We*Xt)/Ct,k=(We*Dt-Ge*vt)/Ct,d=ne(d-E,-Math.PI,Math.PI),p=ne(p-k,-fM,fM)}while((Math.abs(E)>b||Math.abs(k)>b)&&--_>0);return new ni(fe(d),fe(p))}}class pM extends Lh{constructor(o){super(o),this.center=o.center||[0,0],this.parallels=o.parallels||[0,0],this.cosPhi=Math.max(.01,Math.cos(ce(this.parallels[0]))),this.scale=1/(2*Math.max(Math.PI*this.cosPhi,1/this.cosPhi)),this.wrap=!0,this.supportsWorldCopies=!0}project(o,u){const{scale:d,cosPhi:p}=this;return{x:ce(o)*p*d+.5,y:-Math.sin(ce(u))/p*d+.5,z:0}}unproject(o,u){const{scale:d,cosPhi:p}=this,_=-(u-.5)/d,b=ne(fe((o-.5)/d)/p,-180,180),E=Math.asin(ne(_*p,-1,1)),k=ne(fe(E),-va,va);return new ni(b,k)}}class jV extends hM{constructor(o){super(o),this.requiresDraping=!0,this.supportsWorldCopies=!1,this.supportsFog=!0,this.zAxisUnit="pixels",this.unsupportedLayers=["debug"],this.range=[3,5]}projectTilePoint(o,u,d){const p=ay(o,u,d);return co(p,p,sy(Hc(d))),{x:p[0],y:p[1],z:p[2]}}locationPoint(o,u){const d=Yp(u.lat,u.lng),p=Ha([],d),_=o.elevation?o.elevation.getAtPointOrZero(o.locationCoordinate(u),o._centerAltitude):o._centerAltitude;ny(d,d,p,pc(1,0)*Rn*_);const b=dc(new Float64Array(16));return yf(b,o.pixelMatrix,o.globeMatrix),co(d,d,b),new Y(d[0],d[1])}pixelsPerMeter(o,u){return pc(1,0)*u}pixelSpaceConversion(o,u,d){const p=pc(1,o)*u,_=ur(pc(1,45)*u,p,d);return this.pixelsPerMeter(o,u)/_}createTileMatrix(o,u,d){const p=lw(Hc(d.canonical));return yf(new Float64Array(16),o.globeMatrix,p)}createInversionMatrix(o,u){const{center:d}=o,p=sy(Hc(u));return s0(p,p,ce(d.lng)),Q1(p,p,ce(d.lat)),_f(p,p,[o._pixelsPerMercatorPixel,o._pixelsPerMercatorPixel,1]),Float32Array.from(p)}pointCoordinate(o,u,d,p){return jA(o,u,d,!0)||new Xp(0,0)}pointCoordinate3D(o,u,d){const p=this.pointCoordinate(o,u,d,0);return[p.x,p.y,p.z]}isPointAboveHorizon(o,u){return!jA(o,u.x,u.y,!1)}farthestPixelDistance(o){const u=function(p,_){const b=p.cameraToCenterDistance,E=p._centerAltitude*_,k=p._camera,M=p._c
vendor: 3,837 bytes, line 120
120amera.forward(),F=Nu([],il([],M,-b),[0,0,E]),$=p.worldSize/(2*Math.PI),V=[0,0,-$],X=p.width/p.height,J=Math.tan(p.fovAboveCenter),re=il([],k.up(),J),pe=il([],k.right(),J*X),Ce=Ha([],Nu([],Nu([],M,re),pe)),ze=[];let ke;if(new nw(F,Ce).closestPointOnSphere(V,$,ze)){const Be=Nu([],ze,V),We=fc([],Be,F);ke=Math.cos(p.fovAboveCenter)*Jg(We)}else{const Be=fc([],F,V),We=fc([],V,F);Ha(We,We);const Ge=Jg(Be)-$;ke=Math.sqrt(Ge*(Ge+2*$));const vt=Math.acos(ke/($+Ge))-Math.acos(Dl(M,We));ke*=Math.cos(vt)}return 1.01*ke}(o,this.pixelsPerMeter(o.center.lat,o.worldSize)),d=Zp(o.zoom);if(d>0){const p=uM(o,pc(1,o.center.lat)*o.worldSize),_=o.worldSize/(2*Math.PI),b=Math.max(o.width,o.height)/o.worldSize*Math.PI;return ur(u,p+_*(1-Math.cos(b)),Math.pow(d,10))}return u}upVector(o,u,d){return ay(u,d,o,1)}upVectorScale(o){return{metersToTile:l0(u0(Hc(o)))}}}function mM(l){const o=l.parallels,u=!!o&&Math.abs(o[0]+o[1])<.01;switch(l.name){case"mercator":return new hM(l);case"equirectangular":return new BV(l);case"naturalEarth":return new NV(l);case"equalEarth":return new FV(l);case"winkelTripel":return new $V(l);case"albers":return u?new pM(l):new RV(l);case"lambertConformalConic":return u?new pM(l):new zV(l);case"globe":return new jV(l)}throw new Error(`Invalid projection name: ${l.name}`)}const UV=b0.types,VV=[{name:"a_fade_opacity",components:1,type:"Uint8",offset:0}];function L0(l,o,u,d,p,_,b,E,k,M,F,$,V){const X=E?Math.min(Dh,Math.round(E[0])):0,J=E?Math.min(Dh,Math.round(E[1])):0;l.emplaceBack(o,u,Math.round(32*d),Math.round(32*p),_,b,(X<<1)+(k?1:0),J,16*M,16*F,256*$,256*V)}function R0(l,o,u,d,p,_,b){l.emplaceBack(o,u,d,p,_,b)}function F0(l,o,u,d,p){l.emplaceBack(o,u,d,p),l.emplaceBack(o,u,d,p),l.emplaceBack(o,u,d,p),l.emplaceBack(o,u,d,p)}function GV(l){for(const o of l.sections)if(H1(o.text))return!0;return!1}class Nw{constructor(o){this.layoutVertexArray=new Ut,this.indexArray=new Cn,this.programConfigurations=o,this.segments=new yo,this.dynamicLayoutVertexArray=new Yt,this.opacityVertexArray=new Mn,this.placedSymbolArray=new go,this.globeExtVertexArray=new tn}isEmpty(){return this.layoutVertexArray.length===0&&this.indexArray.length===0&&this.dynamicLayoutVertexArray.length===0&&this.opacityVertexArray.length===0}upload(o,u,d,p){this.isEmpty()||(d&&(this.layoutVertexBuffer=o.createVertexBuffer(this.layoutVertexArray,QU.members),this.indexBuffer=o.createIndexBuffer(this.indexArray,u),this.dynamicLayoutVertexBuffer=o.createVertexBuffer(this.dynamicLayoutVertexArray,eV.members,!0),this.opacityVertexBuffer=o.createVertexBuffer(this.opacityVertexArray,VV,!0),this.globeExtVertexArray.length>0&&(this.globeExtVertexBuffer=o.createVertexBuffer(this.globeExtVertexArray,JU.members,!0)),this.opacityVertexBuffer.itemSize=1),(d||p)&&this.programConfigurations.upload(o))}destroy(){this.layoutVertexBuffer&&(this.layoutVertexBuffer.destroy(),this.indexBuffer.destroy(),this.programConfigurations.destroy(),this.segments.destroy(),this.dynamicLayoutVertexBuffer.destroy(),this.opacityVertexBuffer.destroy(),this.globeExtVertexBuffer&&this.globeExtVertexBuffer.destroy())}}xn(Nw,"SymbolBuffers");class $w{constructor(o,u,d){this.layoutVertexArray=new o,this.layoutAttributes=u,this.indexArray=new d,this.segments=new yo,this.collisionVertexArray=new mr,this.collisionVertexArrayExt=new pr}upload(o){this.layoutVertexBuffer=o.createVertexBuffer(this.layoutVertexArray,this.layoutAttributes),this.indexBuffer=o.createIndexBuffer(this.indexArray),this.collisionVertexBuffer=o.createVertexBuffer(this.collisionVertexArray,tV.members,!0),this.collisionVertexBufferExt=o.createVertexBuffer(this.collisionVertexArrayExt,nV.members,!0)}destroy(){this.layoutVertexBuffer&&(this.layoutVertexBuffer.destroy(),this.indexBuffer.destroy(),this.segments.destroy(),this.collisionVertexBuffer.destroy(),this.collisionVertexBufferExt.de
120stroy())}}xn($w,"CollisionBuffers");class Rh{constructor(o){this.collisionBoxArray=o.collisionBoxArray,this.zoom=o.zoom,this.overscaling=o.overscaling,this.layers=o.layers,this.layerIds=this.layers.map(b=>b.id),this.index=o.index,this.pixelRatio=o.pixelRatio,this.sourceLayerIndex=o.sourceLayerIndex,this.hasPattern=!1,this.hasRTLText=!1,this.fullyClipped=!1,this.sortKeyRanges=[],this.collisionCircleArray=[],this.placementInvProjMatrix=dc([]),this.placementViewportMatrix=dc([]);const u=this.layers[0]._unevaluatedLayout._values;this.textSizeData=Aw(this.zoom,u["text-size"]),this.iconSizeData=Aw(this.zoom,u["icon-size"]);const d=this.layers[0].layout,p=d.get("symbol-sort-key"),_=d.get("symbol-z-order");this.canOverlap=d.get("text-allow-overlap")||d.get("icon-allow-overlap")||d.get("text-ignore-placement")||d.get("icon-ignore-placement"),this.sortFeaturesByKey=_!=="viewport-y"&&p.constantOr(1)!==void 0,this.sortFeaturesByY=(_==="viewport-y"||_==="auto"&&!this.sortFeaturesByKey)&&this.canOverlap,this.writingModes=d.get("text-writing-mode").map(b=>al[b]),this.stateDependentLayerIds=this.layers.filter(b=>b.isStateDependent()).map(b=>b.id),this.sourceID=o.sourceID,this.projection=o.projection}createArrays(){this.text=new Nw(new gf(this.layers,this.zoom,o=>/^text/.test(o))),this.icon=new Nw(new gf(this.layers,this.zoom,o=>/^icon/.test(o))),this.glyphOffsetArray=new Wa,this.lineVertexArray=new Vp,this.symbolInstances=new Ti}calculateGlyphDependencies(o,u,d,p,_){for(let b=0;b<o.length;b++)if(u[o.charCodeAt(b)]=!0,p&&_){const E=_y[o.charAt(b)];
120E&&(u[E.charCodeAt(0)]=!0)}}populate(o,u,d,p){const _=this.layers[0],b=_.layout,E=this.projection.name==="globe",k=b.get("text-font"),M=b.get("text-field"),F=b.get("icon-image"),$=(M.value.kind!=="constant"||M.value.value instanceof Br&&!M.value.value.isEmpty()||M.value.value.toString().length>0)&&(k.value.kind!=="constant"||k.value.value.length>0),V=F.value.kind!=="constant"||!!F.value.value||Object.keys(F.parameters).length>0,X=b.get("symbol-sort-key");if(this.features=[],!$&&!V)return;const J=u.iconDependencies,re=u.glyphDependencies,pe=u.availableImages,Ce=new z(this.zoom);for(const{feature:ze,id:ke,index:Be,sourceLayerIndex:We}of o){const Ge=_._featureFilter.needGeometry,vt=wf(ze,Ge);if(!_._featureFilter.filter(Ce,vt,d))continue;if(Ge||(vt.geometry=$u(ze,d,p)),E&&ze.type!==1&&d.z<=5){const Ct=vt.geometry,zt=.98078528056,Nt=(Gt,nn)=>Dl(ay(Gt.x,Gt.y,d,1),ay(nn.x,nn.y,d,1))<zt;for(let Gt=0;Gt<Ct.length;Gt++)Ct[Gt]=eU(Ct[Gt],Nt)}let ft,Dt;if($){const Ct=_.getValueAndResolveTokens("text-field",vt,d,pe),zt=Br.factory(Ct);GV(zt)&&(this.hasRTLText=!0),(!this.hasRTLText||S()==="unavailable"||this.hasRTLText&&L.isParsed())&&(ft=oV(zt,_,vt))}if(V){const Ct=_.getValueAndResolveTokens("icon-image",vt,d,pe);Dt=Ct instanceof zr?Ct:zr.fromString(Ct)}if(!ft&&!Dt)continue;const Xt=this.sortFeaturesByKey?X.evaluate(vt,{},d):void 0;if(this.features.push({id:ke,text:ft,icon:Dt,index:Be,sourceLayerIndex:We,geometry:vt.geometry,properties:ze.properties,type:UV[ze.type],sortKey:Xt}),Dt&&(J[Dt.name]=!0),ft){const Ct=k.evaluate(vt,{},d).join(","),zt=b.get("text-rotation-alignment")==="map"&&b.get("symbol-placement")!=="point";this.allowVerticalPlacement=this.writingModes&&this.writingModes.indexOf(al.vertical)>=0;for(const Nt of ft.sections)if(Nt.image)J[Nt.image.name]=!0;else{const Gt=qg(ft.toString()),nn=Nt.fontStack||Ct,Mt=re[nn]=re[nn]||{};this.calculateGlyphDependencies(Nt.text,Mt,zt,this.allowVerticalPlacement,Gt)}}}b.get("symbol-placement")==="line"&&(this.features=function(ze){const ke={},Be={},We=[];let Ge=0;function vt(Ct){We.push(ze[Ct]),Ge++}function ft(Ct,zt,Nt){const Gt=Be[Ct];return delete Be[Ct],Be[zt]=Gt,We[Gt].geometry[0].pop(),We[Gt].geometry[0]=We[Gt].geometry[0].concat(Nt[0]),Gt}function Dt(Ct,zt,Nt){const Gt=ke[zt];return delete ke[zt],ke[Ct]=Gt,We[Gt].geometry[0].shift(),We[Gt].geometry[0]=Nt[0].concat(We[Gt].geometry[0]),Gt}function Xt(Ct,zt,Nt){const Gt=Nt?zt[0][zt[0].length-1]:zt[0][0];return`${Ct}:${Gt.x}:${Gt.y}`}for(let Ct=0;Ct<ze.length;
vendor: 10,012 bytes, line 120
120Ct++){const zt=ze[Ct],Nt=zt.geometry,Gt=zt.text?zt.text.toString():null;if(!Gt){vt(Ct);continue}const nn=Xt(Gt,Nt),Mt=Xt(Gt,Nt,!0);if(nn in Be&&Mt in ke&&Be[nn]!==ke[Mt]){const un=Dt(nn,Mt,Nt),Tn=ft(nn,Mt,We[un].geometry);delete ke[nn],delete Be[Mt],Be[Xt(Gt,We[Tn].geometry,!0)]=Tn,We[un].geometry=null}else nn in Be?ft(nn,Mt,Nt):Mt in ke?Dt(nn,Mt,Nt):(vt(Ct),ke[nn]=Ge-1,Be[Mt]=Ge-1)}return We.filter(Ct=>Ct.geometry)}(this.features)),this.sortFeaturesByKey&&this.features.sort((ze,ke)=>ze.sortKey-ke.sortKey)}update(o,u,d,p){this.stateDependentLayers.length&&(this.text.programConfigurations.updatePaintArrays(o,u,this.layers,d,p),this.icon.programConfigurations.updatePaintArrays(o,u,this.layers,d,p))}isEmpty(){return this.symbolInstances.length===0&&!this.hasRTLText}uploadPending(){return!this.uploaded||this.text.programConfigurations.needsUpload||this.icon.programConfigurations.needsUpload}upload(o){!this.uploaded&&this.hasDebugData()&&(this.textCollisionBox.upload(o),this.iconCollisionBox.upload(o)),this.text.upload(o,this.sortFeaturesByY,!this.uploaded,this.text.programConfigurations.needsUpload),this.icon.upload(o,this.sortFeaturesByY,!this.uploaded,this.icon.programConfigurations.needsUpload),this.uploaded=!0}destroyDebugData(){this.textCollisionBox.destroy(),this.iconCollisionBox.destroy()}getProjection(){return this.projectionInstance||(this.projectionInstance=mM(this.projection)),this.projectionInstance}destroy(){this.text.destroy(),this.icon.destroy(),this.hasDebugData()&&this.destroyDebugData()}addToLineVertexArray(o,u){const d=this.lineVertexArray.length;if(o.segment!==void 0)for(const{x:p,y:_}of u)this.lineVertexArray.emplaceBack(p,_);return{lineStartIndex:d,lineLength:this.lineVertexArray.length-d}}addSymbols(o,u,d,p,_,b,E,k,M,F,$,V,X,J){const re=o.indexArray,pe=o.layoutVertexArray,Ce=o.globeExtVertexArray,ze=o.segments.prepareSegment(4*u.length,pe,re,this.canOverlap?b.sortKey:void 0),ke=this.glyphOffsetArray.length,Be=ze.vertexLength,We=this.allowVerticalPlacement&&E===al.vertical?Math.PI/2:0,Ge=b.text&&b.text.sections;for(let ft=0;ft<u.length;ft++){const{tl:Dt,tr:Xt,bl:Ct,br:zt,tex:Nt,pixelOffsetTL:Gt,pixelOffsetBR:nn,minFontScaleX:Mt,minFontScaleY:un,glyphOffset:Tn,isSDF:fn,sectionIndex:Qn}=u[ft],rn=ze.vertexLength,In=Tn[1];if(L0(pe,M.x,M.y,Dt.x,In+Dt.y,Nt.x,Nt.y,d,fn,Gt.x,Gt.y,Mt,un),L0(pe,M.x,M.y,Xt.x,In+Xt.y,Nt.x+Nt.w,Nt.y,d,fn,nn.x,Gt.y,Mt,un),L0(pe,M.x,M.y,Ct.x,In+Ct.y,Nt.x,Nt.y+Nt.h,d,fn,Gt.x,nn.y,Mt,un),L0(pe,M.x,M.y,zt.x,In+zt.y,Nt.x+Nt.w,Nt.y+Nt.h,d,fn,nn.x,nn.y,Mt,un),k){const{x:Jn,y:kr,z:er}=k.anchor,[$n,bi,nr]=k.up;R0(Ce,Jn,kr,er,$n,bi,nr),R0(Ce,Jn,kr,er,$n,bi,nr),R0(Ce,Jn,kr,er,$n,bi,nr),R0(Ce,Jn,kr,er,$n,bi,nr),F0(o.dynamicLayoutVertexArray,Jn,kr,er,We)}else F0(o.dynamicLayoutVertexArray,M.x,M.y,M.z,We);re.emplaceBack(rn,rn+1,rn+2),re.emplaceBack(rn+1,rn+2,rn+3),ze.vertexLength+=4,ze.primitiveLength+=2,this.glyphOffsetArray.emplaceBack(Tn[0]),ft!==u.length-1&&Qn===u[ft+1].sectionIndex||o.programConfigurations.populatePaintArrays(pe.length,b,b.index,{},X,J,Ge&&Ge[Qn])}const vt=k?k.anchor:M;o.placedSymbolArray.emplaceBack(vt.x,vt.y,vt.z,M.x,M.y,ke,this.glyphOffsetArray.length-ke,Be,F,$,M.segment,d?d[0]:0,d?d[1]:0,p[0],p[1],E,0,!1,0,V,0)}_commitLayoutVertex(o,u,d,p,_,b,E){o.emplaceBack(u,d,p,_,b,Math.round(E.x),Math.round(E.y))}_addCollisionDebugVertices(o,u,d,p,_,b,E){const k=d.segments.prepareSegment(4,d.layoutVertexArray,d.indexArray),M=k.vertexLength,F=E.tileAnchorX,$=E.tileAnchorY;for(let X=0;X<4;X++)d.collisionVertexArray.emplaceBack(0,0,0,0);d.collisionVertexArrayExt.emplaceBack(u,-o.padding,-o.padding),d.collisionVertexArrayExt.emplaceBack(u,o.padding,-o.padding),d.collisionVertexArrayExt.emplaceBack(u,o.padding,o.padding),d.collisionVertexArrayExt.emplaceBack(u,-o.padding,o.padding),this._commitLayoutVertex(d.layoutVertexArray,p,_,b,F,$,new Y(o.x1,o.y1)),this._commitLayoutVertex(d.layoutVertexArray,p,_,b,F,$,new Y(o.x2,o.y1)),this._commitLayoutVertex(d.layoutVertexArray,p,_,b,F,$,new Y(o.x2,o.y2)),this._commitLayoutVertex(d.layoutVertexArray,p,_,b,F,$,new Y(o.x1,o.y2)),k.vertexLength+=4;const V=d.indexArray;V.emplaceBack(M,M+1),V.emplaceBack(M+1,M+2),V.emplaceBack(M+2,M+3),V.emplaceBack(M+3,M),k.primitiveLength+=4}_addTextDebugCollisionBoxes(o,u,d,p,_,b){for(let E=p;E<_;E++){const k=d.get(E),M=this.getSymbolInstanceTextSize(o,b,u,E);this._addCollisionDebugVertices(k,M,this.textCollisionBox,k.projectedAnchorX,k.projectedAnchorY,k.projectedAnchorZ,b)}}_addIconDebugCollisionBoxes(o,u,d,p,_,b){for(let E=p;E<_;E++){const k=d.get(E),M=this.getSymbolInstanceIconSize(o,u,b.placedIconSymbolIndex);this._addCollisionDebugVertices(k,M,this.iconCollisionBox,k.projectedAnchorX,k.projectedAnchorY,k.projectedAnchorZ,b)}}generateCollisionDebugBuffers(o,u){this.hasDebugData()&&this.destroyDebugData(),this.textCollisionBox=new $w(wn,LP.members,Yo),this.iconCollisionBox=new $w(wn,LP.members,Yo);const d=tm(this.iconSizeData,o),p=tm(this.textSizeData,o);for(let _=0;_<this.symbolInstances.length;_++){const b=this.symbolInstances.get(_);this._addTextDebugCollisionBoxes(p,o,u,b.textBoxStartIndex,b.textBoxEndIndex,b),this._addTextDebugCollisionBoxes(p,o,u,b.verticalTextBoxStartIndex,b.verticalTextBoxEndIndex,b),this._addIconDebugCollisionBoxes(d,o,u,b.iconBoxStartIndex,b.iconBoxEndIndex,b),this._addIconDebugCollisionBoxes(d,o,u,b.verticalIconBoxStartIndex,b.verticalIconBoxEndIndex,b)}}getSymbolInstanceTextSize(o,u,d,p){const _=this.text.placedSymbolArray.get(u.rightJustifiedTextSymbolIndex>=0?u.rightJustifiedTextSymbolIndex:u.centerJustifiedTextSymbolIndex>=0?u.centerJustifiedTextSymbolIndex:u.leftJustifiedTextSymbolIndex>=0?u.leftJustifiedTextSymbolIndex:u.verticalPlacedTextSymbolIndex>=0?u.verticalPlacedTextSymbolIndex:p),b=E0(this.textSizeData,o,_)/aa;return this.tilePixelRatio*b}getSymbolInstanceIconSize(o,u,d){const p=this.icon.placedSymbolArray.get(d),_=E0(this.iconSizeData,o,p);return this.tilePixelRatio*_}_commitDebugCollisionVertexUpdate(o,u,d){o.emplaceBack(u,-d,-d),o.emplaceBack(u,d,-d),o.emplaceBack(u,d,d),o.emplaceBack(u,-d,d)}_updateTextDebugCollisionBoxes(o,u,d,p,_,b){for(let E=p;E<_;E++){const k=d.get(E),M=this.getSymbolInstanceTextSize(o,b,u,E);this._commitDebugCollisionVertexUpdate(this.textCollisionBox.collisionVertexArrayExt,M,k.padding)}}_updateIconDebugCollisionBoxes(o,u,d,p,_,b){for(let E=p;E<_;E++){const k=d.get(E),M=this.getSymbolInstanceIconSize(o,u,b);this._commitDebugCollisionVertexUpdate(this.iconCollisionBox.collisionVertexArrayExt,M,k.padding)}}updateCollisionDebugBuffers(o,u){if(!this.hasDebugData())return;this.hasTextCollisionBoxData()&&this.textCollisionBox.collisionVertexArrayExt.clear(),this.hasIconCollisionBoxData()&&this.iconCollisionBox.collisionVertexArrayExt.clear();const d=tm(this.iconSizeData,o),p=tm(this.textSizeData,o);for(let _=0;_<this.symbolInstances.length;_++){const b=this.symbolInstances.get(_);this._updateTextDebugCollisionBoxes(p,o,u,b.textBoxStartIndex,b.textBoxEndIndex,b),this._updateTextDebugCollisionBoxes(p,o,u,b.verticalTextBoxStartIndex,b.verticalTextBoxEndIndex,b),this._updateIconDebugCollisionBoxes(d,o,u,b.iconBoxStartIndex,b.iconBoxEndIndex,b.placedIconSymbolIndex),this._updateIconDebugCollisionBoxes(d,o,u,b.verticalIconBoxStartIndex,b.verticalIconBoxEndIndex,b.placedIconSymbolIndex)}this.hasTextCollisionBoxData()&&this.textCollisionBox.collisionVertexBufferExt&&this.textCollisionBox.collisionVertexBufferExt.updateData(this.textCollisionBox.collisionVertexArrayExt),this.hasIconCollisionBoxData()&&this.iconCollisionBox.collisionVertexBufferExt&&this.iconCollisionBox.collisionVertexBufferExt.updateData(this.iconCollisionBox.collisionVertexArrayExt)}_deserializeCollisionBoxesForSymbol(o,u,d,p,_,b,E,k,M){const F={};if(u<d){const{x1:$,y1:V,x2:X,y2:J,padding:re,projectedAnchorX:pe,projectedAnchorY:Ce,projectedAnchorZ:ze,tileAnchorX:ke,tileAnchorY:Be,featureIndex:We}=o.get(u);F.textBox={x1:$,y1:V,x2:X,y2:J,padding:re,projectedAnchorX:pe,projectedAnchorY:Ce,projectedAnchorZ:ze,tileAnchorX:ke,tileAnchorY:Be},F.textFeatureIndex=We}if(p<_){const{x1:$,y1:V,x2:X,y2:J,padding:re,projectedAnchorX:pe,projectedAnchorY:Ce,projectedAnchorZ:ze,tileAnchorX:ke,tileAnchorY:Be,featureIndex:We}=o.get(p);F.verticalTextBox={x1:$,y1:V,x2:X,y2:J,padding:re,projectedAnchorX:pe,projectedAnchorY:Ce,projectedAnchorZ:ze,tileAnchorX:ke,tileAnchorY:Be},F.verticalTextFeatureIndex=We}if(b<E){const{x1:$,y1:V,x2:X,y2:J,padding:re,projectedAnchorX:pe,projectedAnchorY:Ce,projectedAnchorZ:ze,tileAnchorX:ke,tileAnchorY:Be,featureIndex:We}=o.get(b);F.iconBox={x1:$,y1:V,x2:X,y2:J,padding:re,projectedAnchorX:pe,projectedAnchorY:Ce,projectedAnchorZ:ze,tileAnchorX:ke,tileAnchorY:Be},F.iconFeatureIndex=We}if(k<M){const{x1:$,y1:V,x2:X,y2:J,padding:re,projectedAnchorX:pe,projectedAnchorY:Ce,projectedAnchorZ:ze,tileAnchorX:ke,tileAnchorY:Be,featureIndex:We}=o.get(k);F.verticalIconBox={x1:$,y1:V,x2:X,y2:J,padding:re,projectedAnchorX:pe,projectedAnchorY:Ce,projectedAnchorZ:ze,tileAnchorX:ke,tileAnchorY:Be},F.verticalIconFeatureIndex=We}return F}deserializeCollisionBoxes(o){this.collisionArrays=[];for(let u=0;u<this.symbolInstances.length;u++){const d=this.symbolInstances.get(u);this.collisionArrays.push(this._deserializeCollisionBoxesForSymbol(o,d.textBoxStartIndex,d.textBoxEndIndex,d.verticalTextBoxStartIndex,d.verticalTextBoxEndIndex,d.iconBoxStartIndex,d.iconBoxEndIndex,d.verticalIconBoxStartIndex,d.verticalIconBoxEndIndex))}}hasTextData(){return this.text.segments.get().length>0}hasIconData(){return this.icon.segments.get().length>0}hasDebugData(){return this.textCollisionBox&&this.iconCollisionBox}hasTextCollisionBoxData(){return this.hasDebugData()&&this.textCollisionBox.segments.get().length>0}hasIconCollisionBoxData(){return this.hasDebugData()&&this.iconCollisionBox.segments.get().length>0}addIndicesForPlacedSymbol(o,u){const d=o.placedSymbolArray.get(u),p=d.vertexStartIndex+4*d.numGlyphs;for(let _=d.vertexStartIndex;_<p;_+=4)o.indexArray.emplaceBack(_,_+1,_+2),o.indexArray.emplaceBack(_+1,_+2,_+3)}
120getSortedSymbolIndexes(o){if(this.sortedAngle===o&&this.symbolInstanceIndexes!==void 0)return this.symbolInstanceIndexes;const u=Math.sin(o),d=Math.cos(o),p=[],_=[],b=[];for(let E=0;E<this.symbolInstances.length;++E){b.push(E);const k=this.symbolInstances.get(E);p.push(0|Math.round(u*k.tileAnchorX+d*k.tileAnchorY)),_.push(k.featureIndex)}return b.sort((E,k)=>p[E]-p[k]||_[k]-_[E]),b}addToSortKeyRanges(o,u){const d=this.sortKeyRanges[this.sortKeyRanges.length-1];d&&d.sortKey===u?d.symbolInstanceEnd=o+1:this.sortKeyRanges.push({sortKey:u,symbolInstanceStart:o,symbolInstanceEnd:o+1})}sortFeatures(o){if(this.sortFeaturesByY&&this.sortedAngle!==o&&!(this.text.segments.get().length>1||this.icon.segments.get().length>1)){this.symbolInstanceIndexes=this.getSortedSymbolIndexes(o),this.sortedAngle=o,this.text.indexArray.clear(),this.icon.indexArray.clear(),this.featureSortOrder=[];for(const u of this.symbolInstanceIndexes){const d=this.symbolInstances.get(u);this.featureSortOrder.push(d.featureIndex);const{rightJustifiedTextSymbolIndex:p,centerJustifiedTextSymbolIndex:_,leftJustifiedTextSymbolIndex:b,verticalPlacedTextSymbolIndex:E,placedIconSymbolIndex:k,verticalPlacedIconSymbolIndex:M}=d;p>=0&&this.addIndicesForPlacedSymbol(this.text,p),_>=0&&_!==p&&this.addIndicesForPlacedSymbol(this.text,_),b>=0&&b!==_&&b!==p&&this.addIndicesForPlacedSymbol(this.text,b),E>=0&&this.addIndicesForPlacedSymbol(this.text,E),k>=0&&this.addIndicesForPlacedSymbol(this.icon,k),M>=0&&this.addIndicesForPlacedSymbol(this.icon,M)}this.text.indexBuffer&&this.text.indexBuffer.updateData(this.text.indexArray),this.icon.indexBuffer&&this.icon.indexBuffer.updateData(this.icon.indexArray)}}}xn(Rh,"SymbolBucket",{omit:["layers","collisionBoxArray","features","compareText"]}),Rh.MAX_GLYPHS=65535,Rh.addDynamicAttributes=F0;const qV=new Le({"symbol-placement":new te(Pt.layout_symbol["symbol-placement"]),"symbol-spacing":new te(Pt.layout_symbol["symbol-spacing"]),"symbol-avoid-edges":new te(Pt.layout_symbol["symbol-avoid-edges"]),"symbol-sort-key":new ye(Pt.layout_symbol["symbol-sort-key"]),"symbol-z-order":new te(Pt.layout_symbol["symbol-z-order"]),"icon-allow-overlap":new te(Pt.layout_symbol["icon-allow-overlap"]),"icon-ignore-placement":new te(Pt.layout_symbol["icon-ignore-placement"]),"icon-optional":new te(Pt.layout_symbol["icon-optional"]),"icon-rotation-alignment":new te(Pt.layout_symbol["icon-rotation-alignment"]),"icon-size":new ye(Pt.layout_symbol["icon-size"]),"icon-text-fit":new te(Pt.layout_symbol["icon-text-fit"]),"icon-text-fit-padding":new te(Pt.layout_symbol["icon-text-fit-padding"]),"icon-image":new ye(Pt.layout_symbol["icon-image"]),"icon-rotate":new ye(Pt.layout_symbol["icon-rotate"]),"icon-padding":new te(Pt.layout_symbol["icon-padding"]),"icon-keep-upright":new te(Pt.layout_symbol["icon-keep-upright"]),"icon-offset":new ye(Pt.layout_symbol["icon-offset"]),"icon-anchor":new ye(Pt.layout_symbol["icon-anchor"]),"icon-pitch-alignment":new te(Pt.layout_symbol["icon-pitch-alignment"]),"text-pitch-alignment":new te(Pt.layout_symbol["text-pitch-alignment"]),"text-rotation-alignment":new te(Pt.layout_symbol["text-rotation-alignment"]),"text-field":new ye(Pt.layout_symbol["text-field"]),"text-font":new ye(Pt.layout_symbol["text-font"]),"text-size":new ye(Pt.layout_symbol["text-size"]),"text-max-width":new ye(Pt.layout_symbol["text-max-width"]),"text-line-height":new ye(Pt.layout_symbol["text-line-height"]),"text-letter-spacing":new ye(Pt.layout_symbol["text-letter-spacing"]),"text-justify":new ye(Pt.layout_symbol["text-justify"]),"text-radial-offset":new ye(Pt.layout_symbol["text-radial-offset"]),"text-variable-anchor":new te(Pt.layout_symbol["text-variable-anchor"]),"text-anchor":new ye(Pt.layout_symbol["text-anchor"]),"text-max-angle":new te(Pt.layout_symbol["text-max-angle"]),"text-writing-mode":new te(Pt.layout_symbol["text-writing-mode"]),"text-rotate":new ye(Pt.layout_symbol["text-rotate"]),"text-padding":new te(Pt.layout_symbol["text-padding"]),"text-keep-upright":new te(Pt.layout_symbol["text-keep-upright"]),"text-transform":new ye(Pt.layout_symbol["text-transform"]),"text-offset":new ye(Pt.layout_symbol["text-offset"]),"text-allow-overlap":new te(Pt.layout_symbol["text-allow-overlap"]),"text-ignore-placement":new te(Pt.layout_symbol["text-ignore-placement"]),"text-optional":new te(Pt.layout_symbol["text-optional"])});var jw={paint:new Le({"icon-opacity":new ye(Pt.paint_symbol["icon-opacity"]),"icon-color":new ye(Pt.paint_symbol["icon-color"]),"icon-halo-color":new ye(Pt.paint_symbol["icon-halo-color"]),"icon-halo-width":new ye(Pt.paint_symbol["icon-halo-width"]),"icon-halo-blur":new ye(Pt.paint_symbol["icon-halo-blur"]),"icon-translate":new te(Pt.paint_symbol["icon-translate"]),"icon-translate-anchor":new te(Pt.paint_symbol["icon-translate-anchor"]),"text-opacity":new ye(Pt.paint_symbol["text-opacity"]),"text-color":new ye(Pt.paint_symbol["text-color"],{runtimeType:Aa,getOverride:l=>l.textColor,hasOverride:l=>!!l.textColor}),"text-halo-color":new ye(Pt.paint_symbol["text-halo-color"]),"text-halo-width":new ye(Pt.paint_symbol["text-halo-width"]),"text-halo-blur":new ye(Pt.paint_symbol["text-halo-blur"]),"text-translate":new te(Pt.paint_symbol["text-translate"]),"text-translate-anchor":new te(Pt.paint_symbol["text-translate-anchor"])}),layout:qV};class gM{constructor(o){this.type=o.property.overrides?o.property.overrides.runtimeType:bl,this.defaultValue=o}evaluate(o){if(o.formattedSection){const u=this.defaultValue.property.overrides;if(u&&u.hasOverride(o.formattedSection))return u.getOverride(o.formattedSection)}return o.feature&&o.featureState?this.defaultValue.evaluate(o.feature,o.featureState):this.defaultValue.property.specification.default}eachChild(o){this.defaultValue.isConstant()||o(this.defaultValue.value._styleExpression.expression)}outputDefined(){return!1}serialize(){return null}}xn(gM,"FormatSectionOverride",{omit:["defaultValue"]});class B0 extends hc{constructor(o){super(o,jw)}recalculate(o,u){super.recalculate(o,u),this.layout.get("icon-rotation-alignment")==="auto"&&(this.layout._values["icon-rotation-alignment"]=this.layout.get("symbol-placement")!=="point"?"map":"viewport"),this.layout.get("text-rotation-alignment")==="auto"&&(this.layout._values["text-rotation-alignment"]=this.layout.get("symbol-placement")!=="point"?"map":"viewport"),this.layout.get("text-pitch-alignment")==="auto"&&(this.layout._values["text-pitch-alignment"]=this.layout.get("text-rotation-alignment")),this.layout.get("icon-pitch-alignment")==="auto"&&(this.layout._values["icon-pitch-alignment"]=this.layout.get("icon-rotation-alignment"));const d=this.layout.get("text-writing-mode");if(d){const p=[];for(const _ of d)p.indexOf(_)<0&&p.push(_);this.layout._values["text-writing-mode"]=p}else this.layout._values["text-writing-mode"]=this.layout.get("symbol-placement")==="point"?["horizontal"]:["horizontal","vertical"];this._setPaintOverrides()}getValueAndResolveTokens(o,u,d,p){const _=this.layout.get(o).evaluate(u,{},d,p),b=this._unevaluatedLayout._values[o];return b.isDataDriven()||tl(b.value)||!_?_:function(E,k){return k.replace(/{([^{}]+)}/g,(M,F)=>F in E?String(E[F]):"")}(u.properties,_)}createBucket(o){return new Rh(o)}queryRadius(){return 0}queryIntersectsFeature(){return!1}_setPaintOverrides(){for(const o of jw.paint.overridableProperties){if(!B0.hasPaintOverride(this.layout,o))continue;
120const u=this.paint.get(o),d=new gM(u),p=new lc(d,u.property.specification);let _=null;_=u.value.kind==="constant"||u.value.kind==="source"?new Lg("source",p):new sf("composite",p,u.value.zoomStops,u.value._interpolationType),this.paint._values[o]=new ve(u.property,_,u.parameters)}}_handleOverridablePaintPropertyUpdate(o,u,d){return!(!this.layout||u.isDataDriven()||d.isDataDriven())&&B0.hasPaintOverride(this.layout,o)}static hasPaintOverride(o,u){const d=o.get("text-field"),p=jw.paint.properties[u];let _=!1;const b=E=>{for(const k of E)if(p.overrides&&p.overrides.hasOverride(k))return void(_=!0)};if(d.value.kind==="constant"&&d.value.value instanceof Br)b(d.value.value.sections);else if(d.value.kind==="source"){const E=M=>{_||(M instanceof na&&Kn(M.value)===G?b(M.value.sections):M instanceof Ws?b(M.sections):M.eachChild(E))},k=d.value;k._styleExpression&&E(k._styleExpression.expression)}return _}getProgramConfiguration(o){return new Mh(this,o)}}var WV={paint:new Le({"background-color":new te(Pt.paint_background["background-color"]),"background-pattern":new te(Pt.paint_background["background-pattern"]),"background-opacity":new te(Pt.paint_background["background-opacity"])})},HV={paint:new Le({"raster-opacity":new te(Pt.paint_raster["raster-opacity"]),"raster-hue-rotate":new te(Pt.paint_raster["raster-hue-rotate"]),"raster-brightness-min":new te(Pt.paint_raster["raster-brightness-min"]),"raster-brightness-max":new te(Pt.paint_raster["raster-brightness-max"]),"raster-saturation":new te(Pt.paint_raster["raster-saturation"]),"raster-contrast":new te(Pt.paint_raster["raster-contrast"]),"raster-resampling":new te(Pt.paint_raster["raster-resampling"]),"raster-fade-duration":new te(Pt.paint_raster["raster-fade-duration"])})};class YV extends hc{constructor(o){super(o,{}),this.implementation=o}is3D(){return this.implementation.renderingMode==="3d"}hasOffscreenPass(){return this.implementation.prerender!==void 0}isLayerDraped(){return this.implementation.renderToTile!==void 0}shouldRedrape(){return!!this.implementation.shouldRerenderTiles&&this.implementation.shouldRerenderTiles()}recalculate(){}updateTransitions(){}hasTransition(){return!1}serialize(){}onAdd(o){this.implementation.onAdd&&this.implementation.onAdd(o,o.painter.context.gl)}onRemove(o){this.implementation.onRemove&&this.implementation.onRemove(o,o.painter.context.gl)}}var ZV={paint:new Le({"sky-type":new te(Pt.paint_sky["sky-type"]),"sky-atmosphere-sun":new te(Pt.paint_sky["sky-atmosphere-sun"]),"sky-atmosphere-sun-intensity":new te(Pt.paint_sky["sky-atmosphere-sun-intensity"]),"sky-gradient-center":new te(Pt.paint_sky["sky-gradient-center"]),"sky-gradient-radius":new te(Pt.paint_sky["sky-gradient-radius"]),"sky-gradient":new Oe(Pt.paint_sky["sky-gradient"]),"sky-atmosphere-halo-color":new te(Pt.paint_sky["sky-atmosphere-halo-color"]),"sky-atmosphere-color":new te(Pt.paint_sky["sky-atmosphere-color"]),"sky-opacity":new te(Pt.paint_sky["sky-opacity"])})};function Uw(l,o,u){const d=[0,0,1],p=RA([]);return BA(p,p,u?-ce(l)+Math.PI:ce(l)),FA(p,p,-ce(o)),IA(d,d,p),Ha(d,d)}const XV={circle:class extends hc{constructor(l){super(l,sU)}createBucket(l){return new pw(l)}queryRadius(l){const o=l;return Kp("circle-radius",this,o)+Kp("circle-stroke-width",this,o)+f0(this.paint.get("circle-translate"))}queryIntersectsFeature(l,o,u,d,p,_,b,E){const k=oP(this.paint.get("circle-translate"),this.paint.get("circle-translate-anchor"),_.angle,l.pixelToTileUnitsFactor),M=this.paint.get("circle-radius").evaluate(o,u)+this.paint.get("circle-stroke-width").evaluate(o,u);return aP(l,d,_,b,E,this.paint.get("circle-pitch-alignment")==="map",this.paint.get("circle-pitch-scale")==="map",k,M)}getProgramIds(){return["circle"]}getProgramConfiguration(l){return new Mh(this,l)}},heatmap:class extends hc{createBucket(l){return new lP(l)}constructor(l){super(l,hU),this._updateColorRamp()}_handleSpecialPaintPropertyUpdate(l){l==="heatmap-color"&&this._updateColorRamp()}_updateColorRamp(){this.colorRamp=_w({expression:this._transitionablePaint._values["heatmap-color"].value.expression,evaluationKey:"heatmapDensity",image:this.colorRamp}),this.colorRampTexture=null}resize(){this.heatmapFbo&&(this.heatmapFbo.destroy(),this.heatmapFbo=null)}queryRadius(l){return Kp("heatmap-radius",this,l)}queryIntersectsFeature(l,o,u,d,p,_,b,E){const k=this.paint.get("heatmap-radius").evaluate(o,u);return aP(l,d,_,b,E,!0,!0,new Y(0,0),k)}hasOffscreenPass(){return this.paint.get("heatmap-opacity")!==0&&this.visibility!=="none"}getProgramIds(){return["heatmap","heatmapTexture"]}getProgramConfiguration(l){return new Mh(this,l)}},hillshade:class extends hc{constructor(l){super(l,dU)}hasOffscreenPass(){return this.paint.get("hillshade-exaggeration")!==0&&this.visibility!=="none"}getProgramIds(){return["hillshade","hillshadePrepare"]}},fill:class extends hc{constructor(l){super(l,AU)}getProgramIds(){const l=this.paint.get("fill-pattern"),o=l&&l.constantOr(1),u=[o?"fillPattern":"fill"];return this.paint.get("fill-antialias")&&u.push(o&&!this.getPaintProperty("fill-outline-color")?"fillOutlinePattern":"fillOutline"),u}getProgramConfiguration(l){return new Mh(this,l)}recalculate(l,o){super.recalculate(l,o);const u=this.paint._values["fill-outline-color"];u.value.kind==="constant"&&u.value.value===void 0&&(this.paint._values["fill-outline-color"]=this.paint._values["fill-color"])}createBucket(l){return new _0(l)}queryRadius(){return f0(this.paint.get("fill-translate"))}queryIntersectsFeature(l,o,u,d,p,_){return!l.queryGeometry.isAboveHorizon&&eP(iP(l.tilespaceGeometry,this.paint.get("fill-translate"),this.paint.get("fill-translate-anchor"),_.angle,l.pixelToTileUnitsFactor),d)}isTileClipped(){return!0}},"fill-extrusion":class extends hc{constructor(l){super(l,GU)}createBucket(l){return new my(l)}queryRadius(){return f0(this.paint.get("fill-extrusion-translate"))}is3D(){return!0}getProgramIds(){return[this.paint.get("fill-extrusion-pattern").constantOr(1)?"fillExtrusionPattern":"fillExtrusion"]}getProgramConfiguration(l){return new Mh(this,l)}queryIntersectsFeature(l,o,u,d,p,_,b,E,k){const M=oP(this.paint.get("fill-extrusion-translate"),this.paint.get("fill-extrusion-translate-anchor"),_.angle,l.pixelToTileUnitsFactor),F=this.paint.get("fill-extrusion-height").evaluate(o,u),$=this.paint.get("fill-extrusion-base").evaluate(o,u),V=[0,0],X=E&&_.elevation,J=_.elevation?_.elevation.exaggeration():1,re=l.tile.getBucket(this);if(X&&re instanceof my){const Be=re.centroidVertexArray,We=k+1;We<Be.length&&(V[0]=Be.geta_centroid_pos0(We),V[1]=Be.geta_centroid_pos1(We))}if(V[0]===0&&V[1]===1)return!1;_.projection.name==="globe"&&(d=CP([d],[new Y(0,0),new Y(Rn,Rn)],l.tileID.canonical).map(Be=>Be.polygon).flat());const pe=X?E:null,[Ce,ze]=function(Be,We,Ge,vt,ft,Dt,Xt,Ct,zt,Nt,Gt){return Be.projection.name==="globe"?function(nn,Mt,un,Tn,fn,Qn,rn,In,Jn,kr,er){const $n=[],bi=[],nr=nn.projection.upVectorScale(er,nn.center.lat,nn.worldSize).metersToTile,rr=[0,0,0,1],ri=[0,0,0,1],hi=(ii,Ui,to,vo)=>{ii[0]=Ui,ii[1]=to,ii[2]=vo,ii[3]=1},di=SP();un>0&&(un+=di),Tn+=di;for(const ii of Mt){const Ui=[],to=[];for(const vo of ii){const oi=vo.x+fn.x,Oo=vo.y+fn.y,bo=nn.projection.projectTilePoint(oi,Oo,er),Yi=nn.projection.upVector(er,vo.x,vo.y);let Ir=un,xo=Tn;if(rn){const fi=MP(oi,Oo,un,Tn,rn,In,Jn,kr);Ir+=fi.base,xo+=fi.top}un!==0?hi(rr,bo.x+Yi[0]*nr*Ir,bo.y+Yi[1]*nr*Ir,bo.z+Yi[2]*nr*Ir):hi(rr,bo.x,bo.y,bo.z),hi(ri,bo.x+Yi[0]*nr*xo,bo.y+Yi[1]*nr*xo,bo.z+Yi[2]*nr*xo),co(rr,rr,Qn),co(ri,ri,Qn),Ui.push(new em(rr[0],rr[1],rr[2])),to.push(new em(ri[0],ri[1],ri[2]))}$n.push(Ui),bi.push(to)}return[$n,bi]}(Be,We,Ge,vt,ft,Dt,Xt,Ct,zt,Nt,Gt):Xt?function(nn,Mt,un,Tn,fn,Qn,rn,In,Jn){const kr=[],er=[],$n=[0,0,0,1];for(const bi of nn){const nr=[],rr=[];for(const ri of bi){const hi=ri.x+Tn.x,di=ri.y+Tn.y,ii=MP(hi,di,Mt,un,Qn,rn,In,Jn);$n[0]=hi,$n[1]=di,$n[2]=ii.base,$n[3]=1,vf($n,$n,fn),$n[3]=Math.max($n[3],1e-5);const Ui=new em($n[0]/$n[3],$n[1]/$n[3],$n[2]/$n[3]);$n[0]=hi,$n[1]=di,$n[2]=ii.top,$n[3]=1,vf($n,$n,fn),$n[3]=Math.max($n[3],1e-5);const to=new em($n[0]/$n[3],$n[1]/$n[3],$n[2]/$n[3]);nr.push(Ui),rr.push(to)}kr.push(nr),er.push(rr)}return[kr,er]}(We,Ge,vt,ft,Dt,Xt,Ct,zt,Nt):function(nn,Mt,un,Tn,fn){const Qn=[],rn=[],In=fn[8]*Mt,Jn=fn[9]*Mt,kr=fn[10]*Mt,er=fn[11]*Mt,$n=fn[8]*un,bi=fn[9]*un,nr=fn[10]*un,rr=fn[11]*un;for(const ri of nn){const hi=[],di=[];for(const ii of ri){const Ui=ii.x+Tn.x,to=ii.y+Tn.y,vo=fn[0]*Ui+fn[4]*to+fn[12],oi=fn[1]*Ui+fn[5]*to+fn[13],Oo=fn[2]*Ui+fn[6]*to+fn[14],bo=fn[3]*Ui+fn[7]*to+fn[15],Yi=vo+In,Ir=oi+Jn,xo=Oo+kr,fi=Math.max(bo+er,1e-5),Xa=vo+$n,wo=oi+bi,sa=Oo+nr,Zo=Math.max(bo+rr,1e-5);hi.push(new em(Yi/fi,Ir/fi,xo/fi)),di.push(new em(Xa/Zo,wo/Zo,sa/Zo))}Qn.push(hi),rn.push(di)}return[Qn,rn]}(We,Ge,vt,ft,Dt)}(_,d,$,F,M,b,pe,V,J,_.center.lat,l.tileID.canonical),ke=l.queryGeometry;return function(Be,We,Ge){let vt=1/0;eP(Ge,We)&&(vt=PP(Ge,We[0]));for(let ft=0;ft<We.length;ft++){const Dt=We[ft],Xt=Be[ft];for(let Ct=0;Ct<Dt.length-1;
120Ct++){const zt=Dt[Ct],Nt=[zt,Dt[Ct+1],Xt[Ct+1],Xt[Ct],zt];JA(Ge,Nt)&&(vt=Math.min(vt,PP(Ge,Nt)))}}return vt!==1/0&&vt}(Ce,ze,ke.isPointQuery()?ke.screenBounds:ke.screenGeometry)}},line:class extends hc{constructor(l){super(l,IP),this.gradientVersion=0}_handleSpecialPaintPropertyUpdate(l){if(l==="line-gradient"){const o=this._transitionablePaint._values["line-gradient"].value.expression;this.stepInterpolant=o._styleExpression&&o._styleExpression.expression instanceof ku,this.gradientVersion=(this.gradientVersion+1)%Number.MAX_SAFE_INTEGER}}gradientExpression(){return this._transitionablePaint._values["line-gradient"].value.expression}widthExpression(){return this._transitionablePaint._values["line-width"].value.expression}recalculate(l,o){super.recalculate(l,o),this.paint._values["line-floorwidth"]=OP.possiblyEvaluate(this._transitioningPaint._values["line-width"].value,l)}createBucket(l){return new T0(l)}getProgramIds(){return[this.paint.get("line-pattern").constantOr(1)?"linePattern":"line"]}getProgramConfiguration(l){return new Mh(this,l)}queryRadius(l){const o=l,u=DP(Kp("line-width",this,o),Kp("line-gap-width",this,o)),d=Kp("line-offset",this,o);return u/2+Math.abs(d)+f0(this.paint.get("line-translate"))}queryIntersectsFeature(l,o,u,d,p,_){if(l.queryGeometry.isAboveHorizon)return!1;const b=iP(l.tilespaceGeometry,this.paint.get("line-translate"),this.paint.get("line-translate-anchor"),_.angle,l.pixelToTileUnitsFactor),E=l.pixelToTileUnitsFactor/2*DP(this.paint.get("line-width").evaluate(o,u),this.paint.get("line-gap-width").evaluate(o,u)),k=this.paint.get("line-offset").evaluate(o,u);return k&&(d=function(M,F){const $=[],V=new Y(0,0);for(let X=0;X<M.length;X++){const J=M[X],re=[];for(let pe=0;pe<J.length;pe++){const Ce=J[pe],ze=J[pe+1],ke=pe===0?V:Ce.sub(J[pe-1])._unit()._perp(),Be=pe===J.length-1?V:ze.sub(Ce)._unit()._perp(),We=ke._add(Be)._unit();We._mult(1/(We.x*Be.x+We.y*Be.y)),re.push(We._mult(F)._add(Ce))}$.push(re)}return $}(d,k*l.pixelToTileUnitsFactor)),function(M,F,$){for(let V=0;V<F.length;V++){const X=F[V];if(M.length>=3){for(let J=0;J<X.length;J++)if(Tf(M,X[J]))return!0}if(rU(M,X,$))return!0}return!1}(b,d,E)}isTileClipped(){return!0}},symbol:B0,background:class extends hc{constructor(l){super(l,WV)}getProgramIds(){return[this.paint.get("background-pattern")?"backgroundPattern":"background"]}},raster:class extends hc{constructor(l){super(l,HV)}getProgramIds(){return["raster"]}},sky:class extends hc{constructor(l){super(l,ZV),this._updateColorRamp()}_handleSpecialPaintPropertyUpdate(l){l==="sky-gradient"?this._updateColorRamp():l!=="sky-atmosphere-sun"&&l!=="sky-atmosphere-halo-color"&&l!=="sky-atmosphere-color"&&l!=="sky-atmosphere-sun-intensity"||(this._skyboxInvalidated=!0)}_updateColorRamp(){this.colorRamp=_w({expression:this._transitionablePaint._values["sky-gradient"].value.expression,evaluationKey:"skyRadialProgress"}),this.colorRampTexture&&(this.colorRampTexture.destroy(),this.colorRampTexture=null)}needsSkyboxCapture(l){if(this._skyboxInvalidated||!this.skyboxTexture||!this.skyboxGeometry)return!0;if(!this.paint.get("sky-atmosphere-sun")){const o=l.style.light.properties.get("position");return this._lightPosition.azimuthal!==o.azimuthal||this._lightPosition.polar!==o.polar}return!1}getCenter(l,o){if(this.paint.get("sky-type")==="atmosphere"){const d=this.paint.get("sky-atmosphere-sun"),p=!d,_=l.style.light,b=_.properties.get("position");return p&&_.properties.get("anchor")==="viewport"&&ct("The sun direction is attached to a light with viewport anchor, lighting may behave unexpectedly."),p?Uw(b.azimuthal,90-b.polar,o):Uw(d[0],90-d[1],o)}const u=this.paint.get("sky-gradient-center");return Uw(u[0],90-u[1],o)}is3D(){return!1}isSky(){return!0}markSkyboxValid(l){this._skyboxInvalidated=!1,this._lightPosition=l.style.light.properties.get("position")}hasOffscreenPass(){return!0}getProgramIds(){const l=this.paint.get("sky-type");return l==="atmosphere"?["skyboxCapture","skybox"]:l==="gradient"?["skyboxGradient"]:null}}};class Cy{constructor(o,u,d,p){this.context=o,this.format=d,this.texture=o.gl.createTexture(),this.update(u,p)}update(o,u,d){const{width:p,height:_}=o,{context:b}=this,{gl:E}=b,{HTMLImageElement:k,HTMLCanvasElement:M,HTMLVideoElement:F,ImageData:$,ImageBitmap:V}=m;if(E.bindTexture(E.TEXTURE_2D,this.texture),b.pixelStoreUnpackFlipY.set(!1),b.pixelStoreUnpack.set(1),b.pixelStoreUnpackPremultiplyAlpha.set(this.format===E.RGBA&&(!u||u.premultiply!==!1)),d||this.size&&this.size[0]===p&&this.size[1]===_){const{x:X,y:J}=d||{x:0,y:0};o instanceof k||o instanceof M||o instanceof F||o instanceof $||V&&o instanceof V?E.texSubImage2D(E.TEXTURE_2D,0,X,J,E.RGBA,E.UNSIGNED_BYTE,o):E.texSubImage2D(E.TEXTURE_2D,0,X,J,p,_,E.RGBA,E.UNSIGNED_BYTE,o.data)}else this.size=[p,_],o instanceof k||o instanceof M||o instanceof F||o instanceof $||V&&o instanceof V?E.texImage2D(E.TEXTURE_2D,0,this.format,this.format,E.UNSIGNED_BYTE,o):E.texImage2D(E.TEXTURE_2D,0,this.format,p,_,0,this.format,E.UNSIGNED_BYTE,o.data);this.useMipmap=!!(u&&u.useMipmap&&this.isSizePowerOfTwo()),this.useMipmap&&E.generateMipmap(E.TEXTURE_2D)}bind(o,u){const{context:d}=this,{gl:p}=d;p.bindTexture(p.TEXTURE_2D,this.texture),o!==this.filter&&(p.texParameteri(p.TEXTURE_2D,p.TEXTURE_MAG_FILTER,o),p.texParameteri(p.TEXTURE_2D,p.TEXTURE_MIN_FILTER,this.useMipmap?o===
120p.NEAREST?p.NEAREST_MIPMAP_NEAREST:p.LINEAR_MIPMAP_NEAREST:o),this.filter=o),u!==this.wrap&&(p.texParameteri(p.TEXTURE_2D,p.TEXTURE_WRAP_S,u),p.texParameteri(p.TEXTURE_2D,p.TEXTURE_WRAP_T,u),this.wrap=u)}isSizePowerOfTwo(){return this.size[0]===this.size[1]&&Math.log(this.size[0])/Math.LN2%1==0}destroy(){const{gl:o}=this.context;o.deleteTexture(this.texture),this.texture=null}}class KV{constructor(o){this._callback=o,this._triggered=!1,typeof MessageChannel<"u"&&(this._channel=new MessageChannel,this._channel.port2.onmessage=()=>{this._triggered=!1,this._callback()})}trigger(){this._triggered||(this._triggered=!0,this._channel?this._channel.port1.postMessage(!0):setTimeout(()=>{this._triggered=!1,this._callback()},0))}remove(){this._channel=void 0,this._callback=()=>{}}}class QV{constructor(){this.tasks={},this.taskQueue=[],tt(["process"],this),this.invoker=new KV(this.process),this.nextId=0}add(o,u){const d=this.nextId++,p=function({type:_,isSymbolTile:b,zoom:E}){return E=E||0,_==="message"?0:_!=="maybePrepare"||b?_!=="parseTile"||b?_==="parseTile"&&b?300-E:_==="maybePrepare"&&b?400-E:500:200-E:100-E}(u);if(p===0){Ie();try{o()}finally{}return{cancel:()=>{}}}return this.tasks[d]={fn:o,metadata:u,priority:p,id:d},this.taskQueue.push(d),this.invoker.trigger(),{cancel:()=>{delete this.tasks[d]}}}process(){Ie();try{if(this.taskQueue=this.taskQueue.filter(d=>!!this.tasks[d]),!this.taskQueue.length)return;const o=this.pick();if(o===null)return;const u=this.tasks[o];if(delete this.tasks[o],this.taskQueue.length&&this.invoker.trigger(),!u)return;u.fn()}finally{}}pick(){let o=null,u=1/0;for(let p=0;p<this.taskQueue.length;p++){const _=this.tasks[this.taskQueue[p]];_.priority<u&&(u=_.priority,o=p)}if(o===null)return null;const d=this.taskQueue[o];return this.taskQueue.splice(o,1),d}remove(){this.invoker.remove()}}class yM{constructor(o){this._stringToNumber={},this._numberToString=[];for(let u=0;u<o.length;u++){const d=o[u];this._stringToNumber[d]=u,this._numberToString[u]=d}}encode(o){return this._stringToNumber[o]}decode(o){return this._numberToString[o]}}const JV=["tile","layer","source","sourceLayer","state"];class _M{constructor(o,u,d,p,_){this.type="Feature",this._vectorTileFeature=o,this._z=u,this._x=d,this._y=p,this.properties=o.properties,this.id=_}get geometry(){return this._geometry===void 0&&(this._geometry=this._vectorTileFeature.toGeoJSON(this._x,this._y,this._z).geometry),this._geometry}set geometry(o){this._geometry=o}toJSON(){const o={type:"Feature",state:void 0,geometry:this.geometry,properties:this.properties};this.id!==void 0&&(o.id=this.id);for(const u of JV)this[u]!==void 0&&(o[u]=this[u]);return o}}const Fl=32,Xc=33,Fh=new Uint16Array(8184);for(let l=0;l<2046;l++){let o=l+2,u=0,d=0,p=0,_=0,b=0,E=0;for(1&o?p=_=b=Fl:u=d=E=Fl;(o>>=1)>1;){const M=u+p>>1,F=d+_>>1;1&o?(p=u,_=d,u=b,d=E):(u=p,d=_,p=b,_=E),b=M,E=F}const k=4*l;Fh[k+0]=u,Fh[k+1]=d,Fh[k+2]=p,Fh[k+3]=_}const Kc=new Uint16Array(2178),Bh=new Uint8Array(1089),z0=new Uint16Array(1089);function vM(l){return l===0?-.03125:l===32?.03125:0}var bM=et([{name:"a_pos",type:"Int16",components:2},{name:"a_texture_pos",type:"Int16",components:2}]);const xM={type:2,extent:Rn,loadGeometry:()=>[[new Y(0,0),new Y(Rn+1,0),new Y(Rn+1,Rn+1),new Y(0,Rn+1),new Y(0,0)]]};class Vw{constructor(o,u,d,p,_){this.tileID=o,this.uid=wt(),this.uses=0,this.tileSize=u,this.tileZoom=d,this.buckets={},this.expirationTime=null,this.queryPadding=0,this.hasSymbolBuckets=!1,this.hasRTLText=!1,this.dependencies={},this.isRaster=_,this.expiredRequestCount=0,this.state="loading",p&&p.transform&&(this.projection=p.transform.projection)}registerFadeDuration(o){const u=o+this.timeAdded;u<is.now()||this.fadeEndTime&&u<this.fadeEndTime||(this.fadeEndTime=u)}wasRequested(){return this.state==="errored"||this.state==="loaded"||this.state==="reloading"}get tileTransform(){return this._tileTransform||(this._tileTransform=Sf(this.tileID.canonical,this.projection)),this._tileTransform}loadVectorData(o,u,d){if(this.unloadVectorData(),this.state="loaded",o){o.featureIndex&&(this.latestFeatureIndex=o.featureIndex,o.rawTileData?(this.latestRawTileData=o.rawTileData,this.latestFeatureIndex.rawTileData=o.rawTileData):this.latestRawTileData&&(this.latestFeatureIndex.rawTileData=this.latestRawTileData)),this.collisionBoxArray=o.collisionBoxArray,this.buckets=function(p,_){const b={};if(!_)return b;for(const E of p){const k=E.layerIds.map(M=>
vendor: 4,389 bytes, line 120
120_.getLayer(M)).filter(Boolean);if(k.length!==0){E.layers=k,E.stateDependentLayerIds&&(E.stateDependentLayers=E.stateDependentLayerIds.map(M=>k.filter(F=>F.id===M)[0]));for(const M of k)b[M.id]=E}}return b}(o.buckets,u.style),this.hasSymbolBuckets=!1;for(const p in this.buckets){const _=this.buckets[p];if(_ instanceof Rh){if(this.hasSymbolBuckets=!0,!d)break;_.justReloaded=!0}}if(this.hasRTLText=!1,this.hasSymbolBuckets)for(const p in this.buckets){const _=this.buckets[p];if(_ instanceof Rh&&_.hasRTLText){this.hasRTLText=!0,L.isLoading()||L.isLoaded()||S()!=="deferred"||I();break}}this.queryPadding=0;for(const p in this.buckets){const _=this.buckets[p];this.queryPadding=Math.max(this.queryPadding,u.style.getLayer(p).queryRadius(_))}o.imageAtlas&&(this.imageAtlas=o.imageAtlas),o.glyphAtlasImage&&(this.glyphAtlasImage=o.glyphAtlasImage),o.lineAtlas&&(this.lineAtlas=o.lineAtlas)}else this.collisionBoxArray=new ti}unloadVectorData(){if(this.hasData()){for(const o in this.buckets)this.buckets[o].destroy();this.buckets={},this.imageAtlas&&(this.imageAtlas=null),this.lineAtlas&&(this.lineAtlas=null),this.imageAtlasTexture&&this.imageAtlasTexture.destroy(),this.glyphAtlasTexture&&this.glyphAtlasTexture.destroy(),this.lineAtlasTexture&&this.lineAtlasTexture.destroy(),this._tileBoundsBuffer&&(this._tileBoundsBuffer.destroy(),this._tileBoundsIndexBuffer.destroy(),this._tileBoundsSegments.destroy(),this._tileBoundsBuffer=null),this._tileDebugBuffer&&(this._tileDebugBuffer.destroy(),this._tileDebugSegments.destroy(),this._tileDebugBuffer=null),this._tileDebugIndexBuffer&&(this._tileDebugIndexBuffer.destroy(),this._tileDebugIndexBuffer=null),this._globeTileDebugBorderBuffer&&(this._globeTileDebugBorderBuffer.destroy(),this._globeTileDebugBorderBuffer=null),this._tileDebugTextBuffer&&(this._tileDebugTextBuffer.destroy(),this._tileDebugTextSegments.destroy(),this._tileDebugTextIndexBuffer.destroy(),this._tileDebugTextBuffer=null),this._globeTileDebugTextBuffer&&(this._globeTileDebugTextBuffer.destroy(),this._globeTileDebugTextBuffer=null),this.latestFeatureIndex=null,this.state="unloaded"}}getBucket(o){return this.buckets[o.id]}upload(o){for(const d in this.buckets){const p=this.buckets[d];p.uploadPending()&&p.upload(o)}const u=o.gl;this.imageAtlas&&!this.imageAtlas.uploaded&&(this.imageAtlasTexture=new Cy(o,this.imageAtlas.image,u.RGBA),this.imageAtlas.uploaded=!0),this.glyphAtlasImage&&(this.glyphAtlasTexture=new Cy(o,this.glyphAtlasImage,u.ALPHA),this.glyphAtlasImage=null),this.lineAtlas&&!this.lineAtlas.uploaded&&(this.lineAtlasTexture=new Cy(o,this.lineAtlas.image,u.ALPHA),this.lineAtlas.uploaded=!0)}prepare(o){this.imageAtlas&&this.imageAtlas.patchUpdatedImages(o,this.imageAtlasTexture)}queryRenderedFeatures(o,u,d,p,_,b,E,k){return this.latestFeatureIndex&&this.latestFeatureIndex.rawTileData?this.latestFeatureIndex.query({tileResult:p,pixelPosMatrix:E,transform:b,params:_,tileTransform:this.tileTransform},o,u,d):{}}querySourceFeatures(o,u){const d=this.latestFeatureIndex;if(!d||!d.rawTileData)return;const p=d.loadVTLayers(),_=u?u.sourceLayer:"",b=p._geojsonTileLayer||p[_];if(!b)return;const E=Np(u&&u.filter),{z:k,x:M,y:F}=this.tileID.canonical,$={z:k,x:M,y:F};for(let V=0;V<b.length;V++){const X=b.feature(V);if(E.needGeometry){const pe=wf(X,!0);if(!E.filter(new z(this.tileID.overscaledZ),pe,this.tileID.canonical))continue}else if(!E.filter(new z(this.tileID.overscaledZ),X))continue;const J=d.getId(X,_),re=new _M(X,k,M,F,J);re.tile=$,o.push(re)}}hasData(){return this.state==="loaded"||this.state==="reloading"||this.state==="expired"}patternsLoaded(){return!!this.imageAtlas&&!!Object.keys(this.imageAtlas.patternPositions).length}setExpiryData(o){const u=this.expirationTime;if(o.cacheControl){const d=Pe(o.cacheControl);d["max-age"]&&(this.expirationTime=Date.now()+1e3*d["max-age"])}else o.expires&&(this.expirationTime=new Date(o.expires).getTime());if(this.expirationTime){const d=Date.now();let p=!1;if(this.expirationTime>d)p=!1;else if(u)if(this.expirationTime<u)p=!0;else{const _=this.expirationTime-u;_?this.expirationTime=d+Math.max(_,3e4):p=!0}else p=!0;p?(this.expiredRequestCount++,this.state="expired"):this.expiredRequestCount=0}}getExpiryTimeout(){if(this.expirationTime)return this.expiredRequestCount?1e3*(1<<Math.min(this.expiredRequestCount-1,31)):Math.min(this.expirationTime-new Date().getTime(),Math.pow(2,31)-1)}
120setFeatureState(o,u){if(!this.latestFeatureIndex||!this.latestFeatureIndex.rawTileData||Object.keys(o).length===0||!u)return;const d=this.latestFeatureIndex.loadVTLayers(),p=u.style.listImages();for(const _ in this.buckets){if(!u.style.hasLayer(_))continue;const b=this.buckets[_],E=b.layers[0].sourceLayer||"_geojsonTileLayer",k=d[E],M=o[E];if(!k||!M||Object.keys(M).length===0)continue;if(b.update(M,k,p,this.imageAtlas&&this.imageAtlas.patternPositions||{}),b instanceof T0||b instanceof _0){const $=u.style._getSourceCache(b.layers[0].source);u._terrain&&u._terrain.enabled&&$&&b.programConfigurations.needsUpload&&u._terrain._clearRenderCacheForTile($.id,this.tileID)}const F=u&&u.style&&u.style.getLayer(_);F&&(this.queryPadding=Math.max(this.queryPadding,F.queryRadius(b)))}}holdingForFade(){return this.symbolFadeHoldUntil!==void 0}symbolFadeFinished(){return!this.symbolFadeHoldUntil||this.symbolFadeHoldUntil<is.now()}clearFadeHold(){this.symbolFadeHoldUntil=void 0}setHoldDuration(o){this.symbolFadeHoldUntil=is.now()+o}setTexture(o,u){const d=u.context,p=d.gl;this.texture=this.texture||u.getTileTexture(o.width),this.texture?this.texture.update(o,{useMipmap:!0}):(this.texture=new Cy(d,o,p.RGBA,{useMipmap:!0}),this.texture.bind(p.LINEAR,p.CLAMP_TO_EDGE))}setDependencies(o,u){const d={};for(const p of u)d[p]=!0;this.dependencies[o]=d}hasDependency(o,u){for(const d of o){const p=this.dependencies[d];if(p){for(const _ of u)if(p[_])return!0}}return!1}clearQueryDebugViz(){}_makeDebugTileBoundsBuffers(o,u){if(!u||u.name==="mercator"||this._tileDebugBuffer)return;const d=$u(xM,this.tileID.canonical,this.tileTransform)[0],p=new Zt,_=new Cs;for(let b=0;b<d.length;b++){const{x:E,y:k}=d[b];p.emplaceBack(E,k),_.emplaceBack(b)}_.emplaceBack(0),this._tileDebugIndexBuffer=o.createIndexBuffer(_),this._tileDebugBuffer=o.createVertexBuffer(p,iy.members),this._tileDebugSegments=yo.simpleSegment(0,0,p.length,_.length)}_makeTileBoundsBuffers(o,u){if(this._tileBoundsBuffer||!u||u.name==="mercator")return;const d=$u(xM,this.tileID.canonical,this.tileTransform)[0];let p,_;if(this.isRaster){const b=function(E,k){const M=Sf(E,k),F=Math.pow(2,E.z);for(let pe=0;pe<Xc;pe++)for(let Ce=0;Ce<Xc;Ce++){const ze=ol((E.x+(Ce+vM(Ce))/Fl)/F),ke=_a((E.y+(pe+vM(pe))/Fl)/F),Be=k.project(ze,ke),We=pe*Xc+Ce;Kc[2*We+0]=Math.round((Be.x*M.scale-M.x)*Rn),Kc[2*We+1]=Math.round((Be.y*M.scale-M.y)*Rn)}Bh.fill(0),z0.fill(0);for(let pe=2045;pe>=0;pe--){const Ce=4*pe,ze=Fh[Ce+0],ke=Fh[Ce+1],Be=Fh[Ce+2],We=Fh[Ce+3],Ge=ze+Be>>1,vt=ke+We>>1,ft=Ge+vt-ke,Dt=vt+ze-Ge,Xt=ke*Xc+ze,Ct=We*Xc+Be,zt=vt*Xc+Ge,Nt=Math.hypot((Kc[2*Xt+0]+Kc[2*Ct+0])/2-Kc[2*zt+0],(Kc[2*Xt+1]+Kc[2*Ct+1])/2-Kc[2*zt+1])>=16;Bh[zt]=Bh[zt]||(Nt?1:0),pe<1022&&(Bh[zt]=Bh[zt]||Bh[(ke+Dt>>1)*Xc+(ze+ft>>1)]||Bh[(We+Dt>>1)*Xc+(Be+ft>>1)])}const $=new Bt,V=new Cn;let X=0;function J(pe,Ce){const ze=Ce*Xc+pe;return z0[ze]===0&&($.emplaceBack(Kc[2*ze+0],Kc[2*ze+1],pe*Rn/Fl,Ce*Rn/Fl),z0[ze]=++X),z0[ze]-1}function re(pe,Ce,ze,ke,Be,We){const Ge=pe+ze>>1,vt=Ce+ke>>1;if(Math.abs(pe-Be)+Math.abs(Ce-We)>1&&Bh[vt*Xc+Ge])re(Be,We,pe,Ce,Ge,vt),re(ze,ke,Be,We,Ge,vt);else{const ft=J(pe,Ce),Dt=J(ze,ke),Xt=J(Be,We);V.emplaceBack(ft,Dt,Xt)}}return re(0,0,Fl,Fl,Fl,0),re(Fl,Fl,0,0,0,Fl),{vertices:$,indices:V}}(this.tileID.canonical,u);p=b.vertices,_=b.indices}else{p=new Bt,_=new Cn;for(const{x:E,y:k}of d)p.emplaceBack(E,k,0,0);const b=Tw(p.int16,void 0,4);for(let E=0;E<b.length;E+=3)_.emplaceBack(b[E],b[E+1],b[E+2])}this._tileBoundsBuffer=o.createVertexBuffer(p,bM.members),this._tileBoundsIndexBuffer=o.createIndexBuffer(_),this._tileBoundsSegments=yo.simpleSegment(0,0,p.length,_.length)}_makeGlobeTileDebugBuffers(o,u){const d=u.projection;if(!d||d.name!=="globe"||u.freezeTileCoverage)return;const p=this.tileID.canonical,_=sy(UA(p,u)),b=Zp(u.zoom);let E;b>0&&(E=K1(new Float64Array(16),u.globeMatrix)),this._makeGlobeTileDebugBorderBuffer(o,p,u,_,E,b),this._makeGlobeTileDebugTextBuffer(o,p,u,_,E,b)}_globePoint(o,u,d,p,_,b,E){let k=ay(o,u,d);if(b){const M=1<<d.z,F=Yc(p.center.lng),$=Zc(p.center.lat),V=(d.x+.5)/M-F;let X=0;V>.5?X=-1:V<-.5&&(X=1);let J=(o/Rn+d.x)/M+X,re=(u/Rn+d.y)/M;J=(J-F)*p._pixelsPerMercatorPixel+F,re=(re-$)*p._pixelsPerMercatorPixel+$;const pe=[J*p.worldSize,re*p.worldSize,0];co(pe,pe,b),k=xf(k,pe,E)}return co(k,k,_)}_makeGlobeTileDebugBorderBuffer(o,u,d,p,_,b){const E=new Zt,k=new Cs,M=new dt,F=(V,X,J,re,pe)=>{const Ce=(J-V)/(pe-1),ze=(re-X)/(pe-1),ke=E.length;for(let Be=0;Be<pe;Be++){const We=V+Be*Ce,Ge=X+Be*ze;E.emplaceBack(We,Ge);const vt=this._globePoint(We,Ge,u,d,p,_,b);M.emplaceBack(vt[0],vt[1],vt[2]),k.emplaceBack(ke+Be)}},$=Rn;F(0,0,$,0,16),F($,0,$,$,16),F($,$,0,$,16),F(0,$,0,0,16),this._tileDebugIndexBuffer=o.createIndexBuffer(k),this._tileDebugBuffer=o.createVertexBuffer(E,iy.members),this._globeTileDebugBorderBuffer=o.createVertexBuffer(M,NA.members),this._tileDebugSegments=yo.simpleSegment(0,0,E.length,k.length)}_makeGlobeTileDebugTextBuffer(o,u,d,p,_,b){const E=Rn/4,k=new Zt,M=new Cn,F=new dt,$=25;M.reserve(32),k.reserve($),F.reserve($);const V=(X,J)=>$*X+J;for(let X=0;X<$;X++){const J=X*E;for(let re=0;re<$;re++){const pe=re*E;k.emplaceBack(pe,J);const Ce=this._globePoint(pe,J,u,d,p,_,b);F.emplaceBack(Ce[0],Ce[1],Ce[2])}}for(let X=0;X<4;X++)for(let J=0;J<4;J++){const re=V(X,J),pe=V(X,J+1),Ce=V(X+1,J),ze=V(X+1,J+1);M.emplaceBack(re,pe,Ce),M.emplaceBack(Ce,pe,ze)}this._tileDebugTextIndexBuffer=o.createIndexBuffer(M),this._tileDebugTextBuffer=o.createVertexBuffer(k,iy.members),this._globeTileDebugTextBuffer=o.createVertexBuffer(F,NA.members),this._tileDebugTextSegments=yo.simpleSegment(0,0,$,32)}}class e6{constructor(){this.state={},this.stateChanges={},this.deletedStates={}}updateState(o,u,d){const p=String(u);if(this.stateChanges[o]=this.stateChanges[o]||{},this.stateChanges[o][p]=this.stateChanges[o][p]||{},xt(this.stateChanges[o][p],d),this.deletedStates[o]===null){this.deletedStates[o]={};
120for(const _ in this.state[o])_!==p&&(this.deletedStates[o][_]=null)}else if(this.deletedStates[o]&&this.deletedStates[o][p]===null){this.deletedStates[o][p]={};for(const _ in this.state[o][p])d[_]||(this.deletedStates[o][p][_]=null)}else for(const _ in d)this.deletedStates[o]&&this.deletedStates[o][p]&&this.deletedStates[o][p][_]===null&&delete this.deletedStates[o][p][_]}removeFeatureState(o,u,d){if(this.deletedStates[o]===null)return;const p=String(u);if(this.deletedStates[o]=this.deletedStates[o]||{},d&&u!==void 0)this.deletedStates[o][p]!==null&&(this.deletedStates[o][p]=this.deletedStates[o][p]||{},this.deletedStates[o][p][d]=null);else if(u!==void 0)if(this.stateChanges[o]&&this.stateChanges[o][p])for(d in this.deletedStates[o][p]={},this.stateChanges[o][p])this.deletedStates[o][p][d]=null;else this.deletedStates[o][p]=null;else this.deletedStates[o]=null}getState(o,u){const d=String(u),p=xt({},(this.state[o]||{})[d],(this.stateChanges[o]||{})[d]);if(this.deletedStates[o]===null)return{};if(this.deletedStates[o]){const _=this.deletedStates[o][u];if(_===null)return{};for(const b in _)delete p[b]}return p}initializeTileState(o,u){o.setFeatureState(this.state,u)}coalesceChanges(o,u){const d={};for(const p in this.stateChanges){this.state[p]=this.state[p]||{};const _={};for(const b in this.stateChanges[p])this.state[p][b]||(this.state[p][b]={}),xt(this.state[p][b],this.stateChanges[p][b]),_[b]=this.state[p][b];d[p]=_}for(const p in this.deletedStates){this.state[p]=this.state[p]||{};const _={};if(this.deletedStates[p]===null)for(const b in this.state[p])_[b]={},this.state[p][b]={};else for(const b in this.deletedStates[p]){if(this.deletedStates[p][b]===null)this.state[p][b]={};else if(this.state[p][b])for(const E of Object.keys(this.deletedStates[p][b]))delete this.state[p][b][E];_[b]=this.state[p][b]}d[p]=d[p]||{},xt(d[p],_)}if(this.stateChanges={},this.deletedStates={},Object.keys(d).length!==0)for(const p in o)o[p].setFeatureState(d,u)}}class wM{constructor(o){this.size=o,this.minimums=[],this.maximums=[],this.leaves=[]}getElevation(o,u){const d=this.toIdx(o,u);return{min:this.minimums[d],max:this.maximums[d]}}isLeaf(o,u){return this.leaves[this.toIdx(o,u)]}toIdx(o,u){return u*this.size+o}}function TM(l,o,u,d){let p=0,_=Number.MAX_VALUE;for(let b=0;b<3;b++)if(Math.abs(d[b])<1e-15){if(u[b]<l[b]||u[b]>o[b])return null}else{const E=1/d[b];let k=(l[b]-u[b])*E,M=(o[b]-u[b])*E;if(k>M){const F=k;k=M,M=F}if(k>p&&(p=k),M<_&&(_=M),p>_)return null}return p}function EM(l,o,u,d,p,_,b,E,k,M,F){const $=d-l,V=p-o,X=_-u,J=b-l,re=E-o,pe=k-u,Ce=F[1]*pe-F[2]*re,ze=F[2]*J-F[0]*pe,ke=F[0]*re-F[1]*J,Be=$*Ce+V*ze+X*ke;if(Math.abs(Be)<1e-15)return null;const We=1/Be,Ge=M[0]-l,vt=M[1]-o,ft=M[2]-u,Dt=(Ge*Ce+vt*ze+ft*ke)*We;if(Dt<0||Dt>1)return null;const Xt=vt*X-ft*V,Ct=ft*$-Ge*X,zt=Ge*V-vt*$,Nt=(F[0]*Xt+F[1]*Ct+F[2]*zt)*We;return Nt<0||Dt+Nt>1?null:(J*Xt+re*Ct+pe*zt)*We}function SM(l,o,u){return(l-o)/(u-o)}function CM(l,o,u,d,p,_,b,E,k){const M=1<<u,F=_-d,$=b-p,V=(l+1)/M*F+d,X=(o+0)/M*$+p,J=(o+1)/M*$+p;E[0]=(l+0)/M*F+d,E[1]=X,k[0]=V,k[1]=J}class kM{constructor(o){if(this.maximums=[],this.minimums=[],this.leaves=[],this.childOffsets=[],this.nodeCount=0,this.dem=o,this._siblingOffset=[[0,0],[1,0],[0,1],[1,1]],!this.dem)return;const u=function(_){const b=Math.ceil(Math.log2(_.dim/8)),E=[];let k=Math.ceil(Math.pow(2,b));const M=1/k,F=(X,J,re,pe,Ce)=>{const ze=pe?1:0,ke=(X+1)*re-ze,Be=J*re,We=(J+1)*re-ze;Ce[0]=X*re,Ce[1]=Be,Ce[2]=ke,Ce[3]=We};let $=new wM(k);const V=[];for(let X=0;X<k*k;X++){F(X%k,Math.floor(X/k),M,!1,V);const J=zh(V[0],V[1],_),re=zh(V[2],V[1],_),pe=zh(V[2],V[3],_),Ce=zh(V[0],V[3],_);$.minimums.push(Math.min(J,re,pe,Ce)),$.maximums.push(Math.max(J,re,pe,Ce)),$.leaves.push(1)}for(E.push($),k/=2;k>=1;k/=2){const X=E[E.length-1];$=new wM(k);for(let J=0;J<k*k;J++){F(J%k,Math.floor(J/k),2,!0,V);const re=X.getElevation(V[0],V[1]),pe=X.getElevation(V[2],V[1]),Ce=X.getElevation(V[2],V[3]),ze=X.getElevation(V[0],V[3]),ke=X.isLeaf(V[0],V[1]),Be=X.isLeaf(V[2],V[1]),We=X.isLeaf(V[2],V[3]),Ge=X.isLeaf(V[0],V[3]),vt=Math.min(re.min,pe.min,Ce.min,ze.min),ft=Math.max(re.max,pe.max,Ce.max,ze.max),Dt=ke&&Be&&We&&Ge;$.maximums.push(ft),$.minimums.push(vt),$.leaves.push(ft-vt<=5&&Dt?1:0)}E.push($)}return E}(this.dem),d=u.length-1,p=u[d];this._addNode(p.minimums[0],p.maximums[0],p.leaves[0]),this._construct(u,0,0,d,0)}raycastRoot(o,u,d,p,_,b,E=1){return TM([o,u,-100],[d,p,this.maximums[0]*E],_,b)}raycast(o,u,d,p,_,b,E=1){if(!this.nodeCount)return null;
vendor: 4,237 bytes, line 120
120const k=this.raycastRoot(o,u,d,p,_,b,E);if(k==null)return null;const M=[],F=[],$=[],V=[],X=[{idx:0,t:k,nodex:0,nodey:0,depth:0}];for(;X.length>0;){const{idx:J,t:re,nodex:pe,nodey:Ce,depth:ze}=X.pop();if(this.leaves[J]){CM(pe,Ce,ze,o,u,d,p,$,V);const Be=1<<ze,We=(pe+0)/Be,Ge=(pe+1)/Be,vt=(Ce+0)/Be,ft=(Ce+1)/Be,Dt=zh(We,vt,this.dem)*E,Xt=zh(Ge,vt,this.dem)*E,Ct=zh(Ge,ft,this.dem)*E,zt=zh(We,ft,this.dem)*E,Nt=EM($[0],$[1],Dt,V[0],$[1],Xt,V[0],V[1],Ct,_,b),Gt=EM(V[0],V[1],Ct,$[0],V[1],zt,$[0],$[1],Dt,_,b),nn=Math.min(Nt!==null?Nt:Number.MAX_VALUE,Gt!==null?Gt:Number.MAX_VALUE);if(nn!==Number.MAX_VALUE)return nn;{const Mt=ny([],_,b,re);if(AM(Dt,Xt,zt,Ct,SM(Mt[0],$[0],V[0]),SM(Mt[1],$[1],V[1]))>=Mt[2])return re}continue}let ke=0;for(let Be=0;Be<this._siblingOffset.length;Be++){CM((pe<<1)+this._siblingOffset[Be][0],(Ce<<1)+this._siblingOffset[Be][1],ze+1,o,u,d,p,$,V),$[2]=-100,V[2]=this.maximums[this.childOffsets[J]+Be]*E;const We=TM($,V,_,b);if(We!=null){const Ge=We;M[Be]=Ge;let vt=!1;for(let ft=0;ft<ke&&!vt;ft++)Ge>=M[F[ft]]&&(F.splice(ft,0,Be),vt=!0);vt||(F[ke]=Be),ke++}}for(let Be=0;Be<ke;Be++){const We=F[Be];X.push({idx:this.childOffsets[J]+We,t:M[We],nodex:(pe<<1)+this._siblingOffset[We][0],nodey:(Ce<<1)+this._siblingOffset[We][1],depth:ze+1})}}return null}_addNode(o,u,d){return this.minimums.push(o),this.maximums.push(u),this.leaves.push(d),this.childOffsets.push(0),this.nodeCount++}_construct(o,u,d,p,_){if(o[p].isLeaf(u,d)===1)return;this.childOffsets[_]||(this.childOffsets[_]=this.nodeCount);const b=p-1,E=o[b];let k=0,M=0;for(let F=0;F<this._siblingOffset.length;F++){const $=2*u+this._siblingOffset[F][0],V=2*d+this._siblingOffset[F][1],X=E.getElevation($,V),J=E.isLeaf($,V),re=this._addNode(X.min,X.max,J);J&&(k|=1<<F),M||(M=re)}for(let F=0;F<this._siblingOffset.length;F++)k&1<<F||this._construct(o,2*u+this._siblingOffset[F][0],2*d+this._siblingOffset[F][1],b,M+F)}}function AM(l,o,u,d,p,_){return ur(ur(l,u,_),ur(o,d,_),p)}function zh(l,o,u){const d=u.dim,p=ne(l*d-.5,0,d-1),_=ne(o*d-.5,0,d-1),b=Math.floor(p),E=Math.floor(_),k=Math.min(b+1,d-1),M=Math.min(E+1,d-1);return AM(u.get(b,E),u.get(k,E),u.get(b,M),u.get(k,M),p-b,_-E)}const PM={mapbox:[6553.6,25.6,.1,1e4],terrarium:[256,1,1/256,32768]};function t6(l,o,u){return(256*l*256+256*o+u)/10-1e4}function n6(l,o,u){return 256*l+o+u/256-32768}class N0{get tree(){return this._tree||this._buildQuadTree(),this._tree}constructor(o,u,d,p=!1,_=!1){if(this.uid=o,u.height!==u.width)throw new RangeError("DEM tiles must be square");if(d&&d!=="mapbox"&&d!=="terrarium")return ct(`"${d}" is not a valid encoding type. Valid types include "mapbox" and "terrarium".`);this.stride=u.height;const b=this.dim=u.height-2,E=new Uint32Array(u.data.buffer);if(this.pixels=new Uint8Array(u.data.buffer),this.encoding=d||"mapbox",this.borderReady=p,!p){for(let k=0;k<b;k++)E[this._idx(-1,k)]=E[this._idx(0,k)],E[this._idx(b,k)]=E[this._idx(b-1,k)],E[this._idx(k,-1)]=E[this._idx(k,0)],E[this._idx(k,b)]=E[this._idx(k,b-1)];E[this._idx(-1,-1)]=E[this._idx(0,0)],E[this._idx(b,-1)]=E[this._idx(b-1,0)],E[this._idx(-1,b)]=E[this._idx(0,b-1)],E[this._idx(b,b)]=E[this._idx(b-1,b-1)],_&&this._buildQuadTree()}}_buildQuadTree(){this._tree=new kM(this)}get(o,u,d=!1){d&&(o=ne(o,-1,this.dim),u=ne(u,-1,this.dim));const p=4*this._idx(o,u);return(this.encoding==="terrarium"?n6:t6)(this.pixels[p],this.pixels[p+1],this.pixels[p+2])}static getUnpackVector(o){return PM[o]}get unpackVector(){return PM[this.encoding]}_idx(o,u){if(o<-1||o>=this.dim+1||u<-1||u>=this.dim+1)throw new RangeError("out of range source coordinates for DEM data");return(u+1)*this.stride+(o+1)}static pack(o,u){const d=[0,0,0,0],p=N0.getUnpackVector(u);let _=Math.floor((o+p[3])/p[2]);return d[2]=_%256,_=Math.floor(_/256),d[1]=_%256,_=Math.floor(_/256),d[0]=_,d}getPixels(){return new As({width:this.stride,height:this.stride},this.pixels)}backfillBorder(o,u,d){if(this.dim!==o.dim)throw new Error("dem dimension mismatch");let p=u*this.dim,_=u*this.dim+this.dim,b=d*this.dim,E=d*this.dim+this.dim;switch(u){case-1:p=_-1;break;case 1:_=p+1}switch(d){case-1:b=E-1;break;case 1:E=b+1}const k=-u*this.dim,M=-d*this.dim;for(let F=b;F<E;F++)for(let $=p;$<_;$++){const V=4*this._idx($,F),X=4*this._idx($+k,F+M);
120this.pixels[V+0]=o.pixels[X+0],this.pixels[V+1]=o.pixels[X+1],this.pixels[V+2]=o.pixels[X+2],this.pixels[V+3]=o.pixels[X+3]}}onDeserialize(){this._tree&&(this._tree.dem=this)}}xn(N0,"DEMData"),xn(kM,"DemMinMaxQuadTree",{omit:["dem"]});class r6{constructor(o,u){this.max=o,this.onRemove=u,this.reset()}reset(){for(const o in this.data)for(const u of this.data[o])u.timeout&&clearTimeout(u.timeout),this.onRemove(u.value);return this.data={},this.order=[],this}add(o,u,d){const p=o.wrapped().key;this.data[p]===void 0&&(this.data[p]=[]);const _={value:u,timeout:void 0};if(d!==void 0&&(_.timeout=setTimeout(()=>{this.remove(o,_)},d)),this.data[p].push(_),this.order.push(p),this.order.length>this.max){const b=this._getAndRemoveByKey(this.order[0]);b&&this.onRemove(b)}return this}has(o){return o.wrapped().key in this.data}getAndRemove(o){return this.has(o)?this._getAndRemoveByKey(o.wrapped().key):null}_getAndRemoveByKey(o){const u=this.data[o].shift();return u.timeout&&clearTimeout(u.timeout),this.data[o].length===0&&delete this.data[o],this.order.splice(this.order.indexOf(o),1),u.value}getByKey(o){const u=this.data[o];return u?u[0].value:null}get(o){return this.has(o)?this.data[o.wrapped().key][0].value:null}remove(o,u){if(!this.has(o))return this;const d=o.wrapped().key,p=u===void 0?0:this.data[d].indexOf(u),_=this.data[d][p];return this.data[d].splice(p,1),_.timeout&&clearTimeout(_.timeout),this.data[d].length===0&&delete this.data[d],this.onRemove(_.value),this.order.splice(this.order.indexOf(d),1),this}setMaxSize(o){for(this.max=o;this.order.length>this.max;){const u=this._getAndRemoveByKey(this.order[0]);u&&this.onRemove(u)}return this}filter(o){const u=[];for(const d in this.data)for(const p of this.data[d])o(p.value)||u.push(p);for(const d of u)this.remove(d.value.tileID,d)}}class um{constructor(o,u,d){this.func=o,this.mask=u,this.range=d}}um.ReadOnly=!1,um.ReadWrite=!0,um.disabled=new um(519,um.ReadOnly,[0,1]);const Gw=7680;class qw{constructor(o,u,d,p,_,b){this.test=o,this.ref=u,this.mask=d,this.fail=p,this.depthFail=_,this.pass=b}}qw.disabled=new qw({func:519,mask:0},0,0,Gw,Gw,Gw);class Qc{constructor(o,u,d){this.blendFunction=o,this.blendColor=u,this.mask=d}}Qc.Replace=[1,0],Qc.disabled=new Qc(Qc.Replace,Rt.transparent,[!1,!1,!1,!1]),Qc.unblended=new Qc(Qc.Replace,Rt.transparent,[!0,!0,!0,!0]),Qc.alphaBlended=new Qc([1,771],Rt.transparent,[!0,!0,!0,!0]);const Ww=1029,Hw=2305;class yc{constructor(o,u,d){this.enable=o,this.mode=u,this.frontFace=d}}yc.disabled=new yc(!1,Ww,Hw),yc.backCCW=new yc(!0,Ww,Hw),yc.backCW=new yc(!0,Ww,2304),yc.frontCW=new yc(!0,1028,2304),yc.frontCCW=new yc(!0,1028,Hw);class Cf extends fa{constructor(o,u,d){super(),this.id=o,this._onlySymbols=d,u.on("data",p=>{p.dataType==="source"&&p.sourceDataType==="metadata"&&(this._sourceLoaded=!0),this._sourceLoaded&&!this._paused&&p.dataType==="source"&&p.sourceDataType==="content"&&(this.reload(),this.transform&&this.update(this.transform))}),u.on("error",()=>{this._sourceErrored=!0}),this._source=u,this._tiles={},this._cache=new r6(0,this._unloadTile.bind(this)),this._timers={},this._cacheTimers={},this._minTileCacheSize=u.minTileCacheSize,this._maxTileCacheSize=u.maxTileCacheSize,this._loadedParentTiles={},this._coveredTiles={},this._state=new e6,this._isRaster=this._source.type==="raster"||this._source.type==="raster-dem"||this._source.type==="custom"&&this._source._dataType==="raster"}onAdd(o){this.map=o,this._minTileCacheSize=this._minTileCacheSize===void 0&&o?o._minTileCacheSize:this._minTileCacheSize,this._maxTileCacheSize=this._maxTileCacheSize===void 0&&o?o._maxTileCacheSize:this._maxTileCacheSize}loaded(){if(this._sourceErrored)return!0;if(!this._sourceLoaded||!this._source.loaded())return!1;for(const o in this._tiles){const u=this._tiles[o];if(u.state!=="loaded"&&u.state!=="errored")return!1}return!0}getSource(){return this._source}pause(){this._paused=!0}resume(){if(!this._paused)return;const o=this._shouldReloadOnResume;this._paused=!1,this._shouldReloadOnResume=!1,o&&this.reload(),this.transform&&this.update(this.transform)}_loadTile(o,u){return o.isSymbolTile=this._onlySymbols,this._source.loadTile(o,u)}_unloadTile(o){if(this._source.unloadTile)return this._source.unloadTile(o,()=>{})}_abortTile(o){if(this._source.abortTile)return this._source.abortTile(o,()=>{})}serialize(){return this._source.serialize()}prepare(o){this._source.prepare&&this._source.prepare(),this._state.coalesceChanges(this._tiles,this.map?this.map.painter:null);for(const u in this._tiles){const d=this._tiles[u];d.upload(o),d.prepare(this.map.style.imageManager)}}getIds(){return Se(this._tiles).map(o=>o.tileID).sort(MM).map(o=>o.key)}getRenderableIds(o){const u=[];for(const d in this._tiles)this._isIdRenderable(+d,o)&&u.push(this._tiles[d]);return o?u.sort((d,p)=>{const _=d.tileID,b=p.tileID,E=new Y(_.canonical.x,_.canonical.y)._rotate(this.transform.angle),k=new Y(b.canonical.x,b.canonical.y)._rotate(this.transform.angle);return _.overscaledZ-b.overscaledZ||k.y-E.y||k.x-E.x}).map(d=>d.tileID.key):u.map(d=>d.tileID).sort(MM).map(d=>d.key)}hasRenderableParent(o){const u=this.findLoadedParent(o,0);return!!u&&this._isIdRenderable(u.tileID.key)}_isIdRenderable(o,u){return this._tiles[o]&&this._tiles[o].hasData()&&!this._coveredTiles[o]&&(u||!this._tiles[o].holdingForFade())}reload(){if(this._paused)this._shouldReloadOnResume=!0;else{this._cache.reset();for(const o in this._tiles)this._tiles[o].state!=="errored"&&this._reloadTile(+o,"reloading")}}_reloadTile(o,u){const d=this._tiles[o];d&&(d.state!=="loading"&&(d.state=u),this._loadTile(d,this._tileLoaded.bind(this,d,o,u)))}_tileLoaded(o,u,d,p){if(p)if(o.state="errored",p.status!==404)this._source.fire(new Wo(p,{tile:o}));else if(this._source.type==="raster-dem"&&this.usedForTerrain&&this.map.painter.terrain){const _=this.map.painter.terrain;this.update(this.transform,_.getScaledDemTileSize(),!0),_.resetTileLookupCache(this.id
120)}else this.update(this.transform);else o.timeAdded=is.now(),d==="expired"&&(o.refreshedUponExpiration=!0),this._setTileReloadTimer(u,o),this._source.type==="raster-dem"&&o.dem&&this._backfillDEM(o),this._state.initializeTileState(o,this.map?this.map.painter:null),this._source.fire(new vl("data",{dataType:"source",tile:o,coord:o.tileID,sourceCacheId:this.id}))}_backfillDEM(o){const u=this.getRenderableIds();for(let p=0;p<u.length;p++){const _=u[p];if(o.neighboringTiles&&o.neighboringTiles[_]){const b=this.getTileByID(_);d(o,b),d(b,o)}}function d(p,_){if(!p.dem||p.dem.borderReady)return;p.needsHillshadePrepare=!0,p.needsDEMTextureUpload=!0;let b=_.tileID.canonical.x-p.tileID.canonical.x;const E=_.tileID.canonical.y-p.tileID.canonical.y,k=Math.pow(2,p.tileID.canonical.z),M=_.tileID.key;b===0&&E===0||Math.abs(E)>1||(Math.abs(b)>1&&(Math.abs(b+k)===1?b+=k:Math.abs(b-k)===1&&(b-=k)),_.dem&&p.dem&&(p.dem.backfillBorder(_.dem,b,E),p.neighboringTiles&&p.neighboringTiles[M]&&(p.neighboringTiles[M].backfilled=!0)))}}getTile(o){return this.getTileByID(o.key)}getTileByID(o){return this._tiles[o]}_retainLoadedChildren(o,u,d,p){for(const _ in this._tiles){let b=this._tiles[_];if(p[_]||!b.hasData()||b.tileID.overscaledZ<=u||b.tileID.overscaledZ>d)continue;let E=b.tileID;for(;b&&b.tileID.overscaledZ>u+1;){const M=b.tileID.scaledTo(b.tileID.overscaledZ-1);b=this._tiles[M.key],b&&b.hasData()&&(E=M)}let k=E;for(;k.overscaledZ>u;)if(k=k.scaledTo(k.overscaledZ-1),o[k.key]){p[E.key]=E;break}}}findLoadedParent(o,u){if(o.key in this._loadedParentTiles){const d=this._loadedParentTiles[o.key];return d&&d.tileID.overscaledZ>=u?d:null}for(let d=o.overscaledZ-1;d>=u;d--){const p=o.scaledTo(d),_=this._getLoadedTile(p);if(_)return _}}_getLoadedTile(o){const u=this._tiles[o.key];return u&&u.hasData()?u:this._cache.getByKey(this._source.reparseOverscaled?o.wrapped().key:o.canonical.key)}updateCacheSize(o,u){u=u||this._source.tileSize;const d=Math.ceil(o.width/u)+1,p=Math.ceil(o.height/u)+1,_=Math.floor(d*p*5),b=typeof this._minTileCacheSize=="number"?Math.max(this._minTileCacheSize,_):_,E=typeof this._maxTileCacheSize=="number"?Math.min(this._maxTileCacheSize,b):b;this._cache.setMaxSize(E)}handleWrapJump(o){const u=Math.round((o-(this._prevLng===void 0?o:this._prevLng))/360);if(this._prevLng=o,u){const d={};for(const p in this._tiles){const _=this._tiles[p];_.tileID=_.tileID.unwrapTo(_.tileID.wrap+u),d[_.tileID.key]=_}this._tiles=d;for(const p in this._timers)clearTimeout(this._timers[p]),delete this._timers[p];for(const p in this._tiles)this._setTileReloadTimer(+p,this._tiles[p])}}update(o,u,d){if(this.transform=o,!this._sourceLoaded||this._paused||this.transform.freezeTileCoverage||this.usedForTerrain&&!d)return;let p;this.updateCacheSize(o,u),this.transform.projection.name!=="globe"&&this.handleWrapJump(this.transform.center.lng),this._coveredTiles={},this.used||this.usedForTerrain?this._source.tileID?p=o.getVisibleUnwrappedCoordinates(this._source.tileID).map(E=>new Za(E.canonical.z,E.wrap,E.canonical.z,E.canonical.x,E.canonical.y)):(p=o.coveringTiles({tileSize:u||this._source.tileSize,minzoom:this._source.minzoom,maxzoom:this._source.maxzoom,roundZoom:this._source.roundZoom&&!d,reparseOverscaled:this._source.reparseOverscaled,isTerrainDEM:this.usedForTerrain}),this._source.hasTile&&(p=p.filter(E=>this._source.hasTile(E)))):p=[];const _=this._updateRetainedTiles(p);if(IM(this._source.type)&&p.length!==0){const E={},k={},M=Object.keys(_);for(const $ of M){const V=_[$],X=this._tiles[$];if(!X||X.fadeEndTime&&X.fadeEndTime<=is.now())continue;const J=this.findLoadedParent(V,Math.max(V.overscaledZ-Cf.maxOverzooming,this._source.minzoom));J&&(this._addTile(J.tileID),E[J.tileID.key]=J.tileID),k[$]=V}const F=p[p.length-1].overscaledZ;for(const $ in this._tiles){const V=this._tiles[$];if(_[$]||!V.hasData())continue;let X=V.tileID;for(;X.overscaledZ>F;){X=X.scaledTo(X.overscaledZ-1);const J=this._tiles[X.key];if(J&&J.hasData()&&k[X.key]){_[$]=V.tileID;break}}}for(const $ in E)_[$]||(this._coveredTiles[$]=!0,_[$]=E[$])}for(const E in _)this._tiles[E].clearFadeHold();const b=function(E,k){const M=[];for(const F in E)F in k||M.push(F);return M}(this._tiles,_);for(const E of b){const k=this._tiles[E];k.hasSymbolBuckets&&!k.holdingForFade()?k.setHoldDuration(this.map._fadeDuration):k.hasSymbolBuckets&&!k.symbolFadeFinished()||this._removeTile(+E)}this._updateLoadedParentTileCache(),this._onlySymbols&&this._source.afterUpdate&&this._source.afterUpdate()}releaseSymbolFadeTiles(){for(const o in this._tiles)this._tiles[o].holdingForFade()&&this._removeTile(+o)}_updateRetainedTiles(o){const u={};if(o.length===0)return u;const d={},p=o.reduce((M,F)=>
120Math.min(M,F.overscaledZ),1/0),_=o[0].overscaledZ,b=Math.max(_-Cf.maxOverzooming,this._source.minzoom),E=Math.max(_+Cf.maxUnderzooming,this._source.minzoom),k={};for(const M of o){const F=this._addTile(M);u[M.key]=M,F.hasData()||p<this._source.maxzoom&&(k[M.key]=M)}this._retainLoadedChildren(k,p,E,u);for(const M of o){let F=this._tiles[M.key];if(F.hasData())continue;if(M.canonical.z>=this._source.maxzoom){const V=M.children(this._source.maxzoom)[0],X=this.getTile(V);if(X&&X.hasData()){u[V.key]=V;continue}}else{const V=M.children(this._source.maxzoom);if(u[V[0].key]&&u[V[1].key]&&u[V[2].key]&&u[V[3].key])continue}let $=F.wasRequested();for(let V=M.overscaledZ-1;V>=b;--V){const X=M.scaledTo(V);if(d[X.key]||(d[X.key]=!0,F=this.getTile(X),!F&&$&&(F=this._addTile(X)),F&&(u[X.key]=X,$=F.wasRequested(),F.hasData())))break}}return u}_updateLoadedParentTileCache(){this._loadedParentTiles={};for(const o in this._tiles){const u=[];let d,p=this._tiles[o].tileID;for(;p.overscaledZ>0;){if(p.key in this._loadedParentTiles){d=this._loadedParentTiles[p.key];break}u.push(p.key);const _=p.scaledTo(p.overscaledZ-1);if(d=this._getLoadedTile(_),d)break;p=_}for(const _ of u)this._loadedParentTiles[_]=d}}_addTile(o){let u=this._tiles[o.key];if(u)return u;u=this._cache.getAndRemove(o),u&&(this._setTileReloadTimer(o.key,u),u.tileID=o,this._state.initializeTileState(u,this.map?this.map.painter:null),this._cacheTimers[o.key]&&(clearTimeout(this._cacheTimers[o.key]),delete this._cacheTimers[o.key],this._setTileReloadTimer(o.key,u)));const d=!!u;if(!d){const p=this.map?this.map.painter:null;u=new Vw(o,this._source.tileSize*o.overscaleFactor(),this.transform.tileZoom,p,this._isRaster),this._loadTile(u,this._tileLoaded.bind(this,u,o.key,u.state))}return u?(u.uses++,this._tiles[o.key]=u,d||this._source.fire(new vl("dataloading",{tile:u,coord:u.tileID,dataType:"source"})),u):null}_setTileReloadTimer(o,u){o in this._timers&&(clearTimeout(this._timers[o]),delete this._timers[o]);const d=u.getExpiryTimeout();d&&(this._timers[o]=setTimeout(()=>{this._reloadTile(o,"expired"),delete this._timers[o]},d))}_removeTile(o){const u=this._tiles[o];u&&(u.uses--,delete this._tiles[o],this._timers[o]&&(clearTimeout(this._timers[o]),delete this._timers[o]),u.uses>0||(u.hasData()&&u.state!=="reloading"?this._cache.add(u.tileID,u,u.getExpiryTimeout()):(u.aborted=!0,this._abortTile(u),this._unloadTile(u))))}clearTiles(){this._shouldReloadOnResume=!1,this._paused=!1;for(const o in this._tiles)this._removeTile(+o);this._source._clear&&this._source._clear(),this._cache.reset(),this.map&&this.usedForTerrain&&this.map.painter.terrain&&this.map.painter.terrain.resetTileLookupCache(this.id)}tilesIn(o,u,d){const p=[],_=this.transform;if(!_)return p;const b=_.projection.name==="globe",E=Yc(_.center.lng);for(const k in this._tiles){const M=this._tiles[k];if(d&&M.clearQueryDebugViz(),M.holdingForFade())continue;let F;if(b){const $=M.tileID.canonical;if($.z===0){const V=[Math.abs(ne(E,...ky($,-1))-E),Math.abs(ne(E,...ky($,1))-E)];F=[0,2*V.indexOf(Math.min(...V))-1]}else{const V=[Math.abs(ne(E,...ky($,-1))-E),Math.abs(ne(E,...ky($,0))-E),Math.abs(ne(E,...ky($,1))-E)];F=[V.indexOf(Math.min(...V))-1]}}else F=[0];for(const $ of F){const V=o.containsTile(M,_,u,$);V&&p.push(V)}}return p}getVisibleCoordinates(o){const u=this.getRenderableIds(o).map(d=>this._tiles[d].tileID);for(const d of u)d.projMatrix=this.transform.calculateProjMatrix(d.toUnwrapped());return u}hasTransition(){if(this._source.hasTransition())return!0;if(IM(this._source.type))for(const o in this._tiles){const u=this._tiles[o];if(u.fadeEndTime!==void 0&&u.fadeEndTime>=is.now())return!0}return!1}setFeatureState(o,u,d){this._state.updateState(o=o||"_geojsonTileLayer",u,d)}removeFeatureState(o,u,d){this._state.removeFeatureState(o=o||"_geojsonTileLayer",u,d)}getFeatureState(o,u){return this._state.getState(o=o||"_geojsonTileLayer",u)}setDependencies(o,u,d){const p=this._tiles[o];p&&p.setDependencies(u,d)}reloadTilesForDependencies(o,u){for(const d in this._tiles)this._tiles[d].hasDependency(o,u)&&this._reloadTile(+d,"reloading");this._cache.filter(d=>!d.hasDependency(o,u))}_preloadTiles(o,u){if(!this._sourceLoaded){const E=()=>{this._sourceLoaded&&(this._source.off("data",E),this._preloadTiles(o,u))};return void this._source.on("data",E)}const d=new Map,p=Array.isArray(o)?o:[o],_=this.map.painter.terrain,b=this.usedForTerrain&&_?_.getScaledDemTileSize():this._source.tileSize;
vendor: 4,210 bytes, line 120
120for(const E of p){const k=E.coveringTiles({tileSize:b,minzoom:this._source.minzoom,maxzoom:this._source.maxzoom,roundZoom:this._source.roundZoom&&!this.usedForTerrain,reparseOverscaled:this._source.reparseOverscaled,isTerrainDEM:this.usedForTerrain});for(const M of k)d.set(M.key,M);this.usedForTerrain&&E.updateElevation(!1)}Ne(Array.from(d.values()),(E,k)=>{const M=new Vw(E,this._source.tileSize*E.overscaleFactor(),this.transform.tileZoom,this.map.painter,this._isRaster);this._loadTile(M,F=>{this._source.type==="raster-dem"&&M.dem&&this._backfillDEM(M),k(F,M)})},u)}}function MM(l,o){const u=Math.abs(2*l.wrap)-+(l.wrap<0),d=Math.abs(2*o.wrap)-+(o.wrap<0);return l.overscaledZ-o.overscaledZ||d-u||o.canonical.y-l.canonical.y||o.canonical.x-l.canonical.x}function IM(l){return l==="raster"||l==="image"||l==="video"||l==="custom"}function ky(l,o){const u=1<<l.z;return[l.x/u+o,(l.x+1)/u+o]}Cf.maxOverzooming=10,Cf.maxUnderzooming=3;class $0{constructor(o,u,d){this._demTile=o,this._dem=this._demTile.dem,this._scale=u,this._offset=d}static create(o,u,d){const p=d||o.findDEMTileFor(u);if(!p||!p.dem)return;const _=p.dem,b=p.tileID,E=1<<u.canonical.z-b.canonical.z;return new $0(p,p.tileSize/Rn/E,[(u.canonical.x/E-b.canonical.x)*_.dim,(u.canonical.y/E-b.canonical.y)*_.dim])}tileCoordToPixel(o,u){const d=u*this._scale+this._offset[1],p=Math.floor(o*this._scale+this._offset[0]),_=Math.floor(d);return new Y(p,_)}getElevationAt(o,u,d,p){const _=o*this._scale+this._offset[0],b=u*this._scale+this._offset[1],E=Math.floor(_),k=Math.floor(b),M=this._dem;return p=!!p,d?ur(ur(M.get(E,k,p),M.get(E,k+1,p),b-k),ur(M.get(E+1,k,p),M.get(E+1,k+1,p),b-k),_-E):M.get(E,k,p)}getElevationAtPixel(o,u,d){return this._dem.get(o,u,!!d)}getMeterToDEM(o){return(1<<this._demTile.tileID.canonical.z)*pc(1,o)*this._dem.stride}}class OM{constructor(o,u){this.tileID=o,this.x=o.canonical.x,this.y=o.canonical.y,this.z=o.canonical.z,this.grid=new Du(Rn,16,0),this.featureIndexArray=new pf,this.promoteId=u}insert(o,u,d,p,_,b=0){const E=this.featureIndexArray.length;this.featureIndexArray.emplaceBack(d,p,_,b);const k=this.grid;for(let M=0;M<u.length;M++){const F=u[M],$=[1/0,1/0,-1/0,-1/0];for(let V=0;V<F.length;V++){const X=F[V];$[0]=Math.min($[0],X.x),$[1]=Math.min($[1],X.y),$[2]=Math.max($[2],X.x),$[3]=Math.max($[3],X.y)}$[0]<Rn&&$[1]<Rn&&$[2]>=0&&$[3]>=0&&k.insert(E,$[0],$[1],$[2],$[3])}}loadVTLayers(){if(!this.vtLayers){this.vtLayers=new kw(new C0(this.rawTileData)).layers,this.sourceLayerCoder=new yM(this.vtLayers?Object.keys(this.vtLayers).sort():["_geojsonTileLayer"]),this.vtFeatures={};for(const o in this.vtLayers)this.vtFeatures[o]=[]}return this.vtLayers}query(o,u,d,p){this.loadVTLayers();const _=o.params||{},b=Np(_.filter),E=o.tileResult,k=o.transform,M=E.bufferedTilespaceBounds,F=this.grid.query(M.min.x,M.min.y,M.max.x,M.max.y,(J,re,pe,Ce)=>rP(E.bufferedTilespaceGeometry,J,re,pe,Ce));F.sort(i6);let $=null;k.elevation&&F.length>0&&($=$0.create(k.elevation,this.tileID));const V={};let X;for(let J=0;J<F.length;J++){const re=F[J];if(re===X)continue;X=re;const pe=this.featureIndexArray.get(re);let Ce=null;this.loadMatchingFeature(V,pe,b,_.layers,_.availableImages,u,d,p,(ze,ke,Be,We=0)=>(Ce||(Ce=$u(ze,this.tileID.canonical,o.tileTransform)),ke.queryIntersectsFeature(E,ze,Be,Ce,this.z,o.transform,o.pixelPosMatrix,$,We)))}return V}loadMatchingFeature(o,u,d,p,_,b,E,k,M){const{featureIndex:F,bucketIndex:$,sourceLayerIndex:V,layoutVertexArrayOffset:X}=u,J=this.bucketLayerIDs[$];if(p&&!function(ze,ke){for(let Be=0;Be<ze.length;Be++)if(ke.indexOf(ze[Be])>=0)return!0;return!1}(p,J))return;const re=this.sourceLayerCoder.decode(V),pe=this.vtLayers[re].feature(F);if(d.needGeometry){const ze=wf(pe,!0);if(!d.filter(new z(this.tileID.overscaledZ),ze,this.tileID.canonical))return}else if(!d.filter(new z(this.tileID.overscaledZ),pe))return;const Ce=this.getId(pe,re);for(let ze=0;ze<J.length;ze++){const ke=J[ze];if(p&&p.indexOf(ke)<0)continue;const Be=b[ke];if(!Be)continue;let We={};Ce!==void 0&&k&&(We=k.getState(Be.sourceLayer||"_geojsonTileLayer",Ce));const Ge=xt({},E[ke]);Ge.paint=DM(Ge.paint,Be.paint,pe,We,_),Ge.layout=DM(Ge.layout,Be.layout,pe,We,_);const vt=!M||M(pe,Be,We,X);if(!vt)continue;
120const ft=new _M(pe,this.z,this.x,this.y,Ce);ft.layer=Ge;let Dt=o[ke];Dt===void 0&&(Dt=o[ke]=[]),Dt.push({featureIndex:F,feature:ft,intersectionZ:vt})}}lookupSymbolFeatures(o,u,d,p,_,b,E,k){const M={};this.loadVTLayers();const F=Np(_);for(const $ of o)this.loadMatchingFeature(M,{bucketIndex:d,sourceLayerIndex:p,featureIndex:$,layoutVertexArrayOffset:0},F,b,E,k,u);return M}loadFeature(o){const{featureIndex:u,sourceLayerIndex:d}=o;this.loadVTLayers();const p=this.sourceLayerCoder.decode(d),_=this.vtFeatures[p];if(_[u])return _[u];const b=this.vtLayers[p].feature(u);return _[u]=b,b}hasLayer(o){for(const u of this.bucketLayerIDs)for(const d of u)if(o===d)return!0;return!1}getId(o,u){let d=o.id;if(this.promoteId){const p=typeof this.promoteId=="string"?this.promoteId:this.promoteId[u];p!=null&&(d=o.properties[p]),typeof d=="boolean"&&(d=Number(d))}return d}}function DM(l,o,u,d,p){return lt(l,(_,b)=>{const E=o instanceof Ee?o.get(b):null;return E&&E.evaluate?E.evaluate(u,d,p):E})}function i6(l,o){return o-l}xn(OM,"FeatureIndex",{omit:["rawTileData","sourceLayerCoder"]});class LM{constructor(o,u){this.width=o,this.height=u,this.nextRow=0,this.image=new ju({width:o,height:u}),this.positions={},this.uploaded=!1}getDash(o,u){const d=this.getKey(o,u);return this.positions[d]}trim(){const o=this.width,u=this.height=je(this.nextRow);this.image.resize({width:o,height:u})}getKey(o,u){return o.join(",")+u}getDashRanges(o,u,d){const p=[];let _=o.length%2==1?-o[o.length-1]*d:0,b=o[0]*d,E=!0;p.push({left:_,right:b,isDash:E,zeroLength:o[0]===0});let k=o[0];for(let M=1;M<o.length;M++){E=!E;const F=o[M];_=k*d,k+=F,b=k*d,p.push({left:_,right:b,isDash:E,zeroLength:F===0})}return p}addRoundDash(o,u,d){const p=u/2;for(let _=-d;_<=d;_++){const b=this.width*(this.nextRow+d+_);let E=0,k=o[E];for(let M=0;M<this.width;M++){M/k.right>1&&(k=o[++E]);const F=Math.abs(M-k.left),$=Math.abs(M-k.right),V=Math.min(F,$);let X;const J=_/d*(p+1);if(k.isDash){const re=p-Math.abs(J);X=Math.sqrt(V*V+re*re)}else X=p-Math.sqrt(V*V+J*J);this.image.data[b+M]=Math.max(0,Math.min(255,X+128))}}}addRegularDash(o,u){for(let k=o.length-1;k>=0;--k){const M=o[k],F=o[k+1];M.zeroLength?o.splice(k,1):F&&F.isDash===M.isDash&&(F.left=M.left,o.splice(k,1))}const d=o[0],p=o[o.length-1];d.isDash===p.isDash&&(d.left=p.left-this.width,p.right=d.right+this.width);const _=this.width*this.nextRow;let b=0,E=o[b];for(let k=0;k<this.width;k++){k/E.right>1&&(E=o[++b]);const M=Math.abs(k-E.left),F=Math.abs(k-E.right),$=Math.min(M,F);this.image.data[_+k]=Math.max(0,Math.min(255,(E.isDash?$:-$)+u+128))}}
120addDash(o,u){const d=this.getKey(o,u);if(this.positions[d])return this.positions[d];const p=u==="round",_=p?7:0,b=2*_+1;if(this.nextRow+b>this.height)return ct("LineAtlas out of space"),null;o.length===0&&o.push(1);let E=0;for(let F=0;F<o.length;F++)o[F]<0&&(ct("Negative value is found in line dasharray, replacing values with 0"),o[F]=0),E+=o[F];if(E!==0){const F=this.width/E,$=this.getDashRanges(o,this.width,F);p?this.addRoundDash($,F,_):this.addRegularDash($,u==="square"?.5*F:0)}const k=this.nextRow+_;this.nextRow+=b;const M={tl:[k,_],br:[E,0]};return this.positions[d]=M,M}}xn(LM,"LineAtlas");const RM=1*gc;class FM{constructor(o){const u={},d=[];for(const E in o){const k=o[E],M=u[E]={};for(const F in k.glyphs){const $=k.glyphs[+F];if(!$||$.bitmap.width===0||$.bitmap.height===0)continue;const V=$.metrics.localGlyph?RM:1,X={x:0,y:0,w:$.bitmap.width+2*V,h:$.bitmap.height+2*V};d.push(X),M[F]=X}}const{w:p,h:_}=Iw(d),b=new ju({width:p||1,height:_||1});for(const E in o){const k=o[E];for(const M in k.glyphs){const F=k.glyphs[+M];if(!F||F.bitmap.width===0||F.bitmap.height===0)continue;const $=u[E][M],V=F.metrics.localGlyph?RM:1;ju.copy(F.bitmap,b,{x:0,y:0},{x:$.x+V,y:$.y+V},F.bitmap)}}this.image=b,this.positions=u}}xn(FM,"GlyphAtlas");class o6{constructor(o){this.tileID=new Za(o.tileID.overscaledZ,o.tileID.wrap,o.tileID.canonical.z,o.tileID.canonical.x,o.tileID.canonical.y),this.tileZoom=o.tileZoom,this.uid=o.uid,this.zoom=o.zoom,this.canonical=o.tileID.canonical,this.pixelRatio=o.pixelRatio,this.tileSize=o.tileSize,this.source=o.source,this.overscaling=this.tileID.overscaleFactor(),this.showCollisionBoxes=o.showCollisionBoxes,this.collectResourceTiming=!!o.collectResourceTiming,this.returnDependencies=!!o.returnDependencies,this.promoteId=o.promoteId,this.enableTerrain=!!o.enableTerrain,this.isSymbolTile=o.isSymbolTile,this.tileTransform=Sf(o.tileID.canonical,o.projection),this.projection=o.projection}parse(o,u,d,p,_){this.status="parsing",this.data=o,this.collisionBoxArray=new ti;const b=new yM(Object.keys(o.layers).sort()),E=new OM(this.tileID,this.promoteId);E.bucketLayerIDs=[];const k={},M=new LM(256,256),F={featureIndex:E,iconDependencies:{},patternDependencies:{},glyphDependencies:{},lineAtlas:M,availableImages:d},$=u.familiesBySource[this.source];for(const We in $){const Ge=o.layers[We];if(!Ge)continue;let vt=!1,ft=!1;for(const Ct of $[We])Ct[0].type==="symbol"?vt=!0:ft=!0;if(this.isSymbolTile===!0&&!vt||this.isSymbolTile===!1&&!ft)continue;Ge.version===1&&ct(`Vector tile source "${this.source}" layer "${We}" does not use vector tile spec v2 and therefore may have some rendering errors.`);const Dt=b.encode(We),Xt=[];for(let Ct=0;Ct<Ge.length;
120Ct++){const zt=Ge.feature(Ct),Nt=E.getId(zt,We);Xt.push({feature:zt,id:Nt,index:Ct,sourceLayerIndex:Dt})}for(const Ct of $[We]){const zt=Ct[0];this.isSymbolTile!==void 0&&zt.type==="symbol"!==this.isSymbolTile||zt.minzoom&&this.zoom<Math.floor(zt.minzoom)||zt.maxzoom&&this.zoom>=zt.maxzoom||zt.visibility!=="none"&&(Yw(Ct,this.zoom,d),(k[zt.id]=zt.createBucket({index:E.bucketLayerIDs.length,layers:Ct,zoom:this.zoom,canonical:this.canonical,pixelRatio:this.pixelRatio,overscaling:this.overscaling,collisionBoxArray:this.collisionBoxArray,sourceLayerIndex:Dt,sourceID:this.source,enableTerrain:this.enableTerrain,projection:this.projection.spec,availableImages:d})).populate(Xt,F,this.tileID.canonical,this.tileTransform),E.bucketLayerIDs.push(Ct.map(Nt=>Nt.id)))}}let V,X,J,re;M.trim();const pe={type:"maybePrepare",isSymbolTile:this.isSymbolTile,zoom:this.zoom},Ce=()=>{if(V)return _(V);if(X&&J&&re){const We=new FM(X),Ge=new VP(J,re);for(const vt in k){const ft=k[vt];ft instanceof Rh?(Yw(ft.layers,this.zoom,d),IV(ft,X,We.positions,J,Ge.iconPositions,this.showCollisionBoxes,d,this.tileID.canonical,this.tileZoom,this.projection)):ft.hasPattern&&(ft instanceof T0||ft instanceof _0||ft instanceof my)&&(Yw(ft.layers,this.zoom,d),ft.addFeatures(F,this.tileID.canonical,Ge.patternPositions,d,this.tileTransform))}this.status="done",_(null,{buckets:Se(k).filter(vt=>!vt.isEmpty()),featureIndex:E,collisionBoxArray:this.collisionBoxArray,glyphAtlasImage:We.image,lineAtlas:M,imageAtlas:Ge,glyphMap:this.returnDependencies?X:null,iconMap:this.returnDependencies?J:null,glyphPositions:this.returnDependencies?We.positions:null})}},ze=lt(F.glyphDependencies,We=>Object.keys(We).map(Number));Object.keys(ze).length?p.send("getGlyphs",{uid:this.uid,stacks:ze},(We,Ge)=>{V||(V=We,X=Ge,Ce())},void 0,!1,pe):X={};const ke=Object.keys(F.iconDependencies);ke.length?p.send("getImages",{icons:ke,source:this.source,tileID:this.tileID,type:"icons"},(We,Ge)=>{V||(V=We,J=Ge,Ce())},void 0,!1,pe):J={};const Be=Object.keys(F.patternDependencies);Be.length?p.send("getImages",{icons:Be,source:this.source,tileID:this.tileID,type:"patterns"},(We,Ge)=>{V||(V=We,re=Ge,Ce())},void 0,!1,pe):re={},Ce()}}function Yw(l,o,u){const d=new z(o);for(const p of l)p.recalculate(d,u)}class BM{constructor(o){this.entries={},this.scheduler=o}request(o,u,d,p){const _=this.entries[o]=this.entries[o]||{callbacks:[]};if(_.result){const[b,E]=_.result;return this.scheduler?this.scheduler.add(()=>{p(b,E)},u):p(b,E),()=>{}}return _.callbacks.push(p),_.cancel||(_.cancel=d((b,E)=>{_.result=[b,E];for(const k of _.callbacks)this.scheduler?this.scheduler.add(()=>{k(b,E)},u):k(b,E);setTimeout(()=>delete this.entries[o],3e3)})),()=>{_.result||(_.callbacks=_.callbacks.filter(b=>b!==p),_.callbacks.length||(_.cancel(),delete this.entries[o]))}}}function zM(l,o,u){const d=JSON.stringify(l.request);return l.data&&(this.deduped.entries[d]={result:[null,l.data]}),this.deduped.request(d,{type:"parseTile",isSymbolTile:l.isSymbolTile,zoom:l.tileZoom},p=>{const _=Ao(l.request,(b,E,k,M)=>{b?p(b):E&&p(null,{vectorTile:u?void 0:new kw(new C0(E)),rawData:E,cacheControl:k,expires:M})});return()=>{_.cancel(),p()}},o)}const NM=[Int8Array,Uint8Array,Uint8ClampedArray,Int16Array,Uint16Array,Int32Array,Uint32Array,Float32Array,Float64Array];class Zw{static from(o){if(!(o instanceof ArrayBuffer))throw new Error("Data must be an instance of ArrayBuffer.");const[u,d]=new Uint8Array(o,0,2);if(u!==219)throw new Error("Data does not appear to be in a KDBush format.");const p=d>>4;if(p!==1)throw new Error(`Got v${p} data when expected v1.`);const _=NM[15&d];if(!_)throw new Error("Unrecognized array type.");const[b]=new Uint16Array(o,2,1),[E]=new Uint32Array(o,4,1);return new Zw(E,b,_,o)}constructor(o,u=64,d=Float64Array,p){if(isNaN(o)||o<0)throw new Error(`Unpexpected numItems value: ${o}.`);this.numItems=+o,this.nodeSize=Math.min(Math.max(+u,2),65535),this.ArrayType=d,this.IndexArrayType=o<65536?Uint16Array:Uint32Array;const _=NM.indexOf(this.ArrayType),b=2*o*this.ArrayType.BYTES_PER_ELEMENT,E=o*this.IndexArrayType.BYTES_PER_ELEMENT,k=(8-E%8)%8;if(_<0)throw new Error(`Unexpected typed array class: ${d}.`);p&&p instanceof ArrayBuffer?(this.data=p,this.ids=new this.IndexArrayType(this.data,8,o),this.coords=new this.ArrayType(this.data,8+E+k,2*o),this._pos=2*o,this._finished=!0):(this.data=new ArrayBuffer(8+b+E+k),this.ids=new this.IndexArrayType(this.data,8,o),this.coords=new this.ArrayType(this.data,8+E+k,2*o),this._pos=0,this._finished=!1,new Uint8Array(this.data,0,2).set([219,16+_]),new Uint16Array(this.data,2,1)[0]=u,new Uint32Array(this.data,4,1)[0]=o)}add(o,u){const d=this._pos>>1;return this.ids[d]=d,this.coords[this._pos++]=o,this.coords[this._pos++]=u,d}finish(){const o=this._pos>>1;if(o!==this.numItems)throw new Error(`Added ${o} items when expected ${this.numItems}.`);return Xw(this.ids,this.coords,this.nodeSize,0,this.numItems-1,0),this._finished=!0,this}range(o,u,d,p){if(!this._finished)throw new Error("Data not yet indexed - call index.finish().");
120const{ids:_,coords:b,nodeSize:E}=this,k=[0,_.length-1,0],M=[];for(;k.length;){const F=k.pop()||0,$=k.pop()||0,V=k.pop()||0;if($-V<=E){for(let pe=V;pe<=$;pe++){const Ce=b[2*pe],ze=b[2*pe+1];Ce>=o&&Ce<=d&&ze>=u&&ze<=p&&M.push(_[pe])}continue}const X=V+$>>1,J=b[2*X],re=b[2*X+1];J>=o&&J<=d&&re>=u&&re<=p&&M.push(_[X]),(F===0?o<=J:u<=re)&&(k.push(V),k.push(X-1),k.push(1-F)),(F===0?d>=J:p>=re)&&(k.push(X+1),k.push($),k.push(1-F))}return M}within(o,u,d){if(!this._finished)throw new Error("Data not yet indexed - call index.finish().");const{ids:p,coords:_,nodeSize:b}=this,E=[0,p.length-1,0],k=[],M=d*d;for(;E.length;){const F=E.pop()||0,$=E.pop()||0,V=E.pop()||0;if($-V<=b){for(let pe=V;pe<=$;pe++)jM(_[2*pe],_[2*pe+1],o,u)<=M&&k.push(p[pe]);continue}const X=V+$>>1,J=_[2*X],re=_[2*X+1];jM(J,re,o,u)<=M&&k.push(p[X]),(F===0?o-d<=J:u-d<=re)&&(E.push(V),E.push(X-1),E.push(1-F)),(F===0?o+d>=J:u+d>=re)&&(E.push(X+1),E.push($),E.push(1-F))}return k}}function Xw(l,o,u,d,p,_){if(p-d<=u)return;const b=d+p>>1;$M(l,o,b,d,p,_),Xw(l,o,u,d,b-1,1-_),Xw(l,o,u,b+1,p,1-_)}function $M(l,o,u,d,p,_){for(;p>d;){if(p-d>600){const M=p-d+1,F=u-d+1,$=Math.log(M),V=.5*Math.exp(2*$/3),X=.5*Math.sqrt($*V*(M-V)/M)*(F-M/2<0?-1:1);$M(l,o,u,Math.max(d,Math.floor(u-F*V/M+X)),Math.min(p,Math.floor(u+(M-F)*V/M+X)),_)}const b=o[2*u+_];let E=d,k=p;for(Ay(l,o,d,u),o[2*p+_]>b&&Ay(l,o,d,p);E<k;){for(Ay(l,o,E,k),E++,k--;o[2*E+_]<b;)E++;for(;o[2*k+_]>b;)k--}o[2*d+_]===b?Ay(l,o,d,k):(k++,Ay(l,o,k,p)),k<=u&&(d=k+1),u<=k&&(p=k-1)}}function Ay(l,o,u,d){Kw(l,u,d),Kw(o,2*u,2*d),Kw(o,2*u+1,2*d+1)}function Kw(l,o,u){const d=l[o];l[o]=l[u],l[u]=d}function jM(l,o,u,d){const p=l-u,_=o-d;return p*p+_*_}a.ARRAY_TYPE=ks,a.AUTH_ERR_MSG=qe,a.Aabb=Ya,a.Actor=class{constructor(l,o,u){this.target=l,this.parent=o,this.mapId=u,this.callbacks={},this.cancelCallbacks={},tt(["receive"],this),this.target.addEventListener("message",this.receive,!1),this.globalScope=Ie()?l:m,this.scheduler=new QV}send(l,o,u,d,p=!1,_){const b=Math.round(1e18*Math.random()).toString(36).substring(0,10);u&&(u.metadata=_,this.callbacks[b]=u);const E=Tt(this.globalScope)?void 0:[];return this.target.postMessage({id:b,type:l,hasCallback:!!u,targetMapId:d,mustQueue:p,sourceMapId:this.mapId,data:kh(o,E)},E),{cancel:()=>{u&&delete this.callbacks[b],this.target.postMessage({id:b,type:"<cancel>",targetMapId:d,sourceMapId:this.mapId})}}}receive(l){const o=l.data,u=o.id;if(u&&(!o.targetMapId||this.mapId===o.targetMapId))if(o.type==="<cancel>"){const d=this.cancelCallbacks[u];delete this.cancelCallbacks[u],d&&d.cancel()}else if(o.mustQueue||Ie()){const d=this.callbacks[u];this.cancelCallbacks[u]=this.scheduler.add(()=>this.processTask(u,o),d&&d.metadata||{type:"message"})}else this.processTask(u,o)}processTask(l,o){if(o.type==="<response>"){const u=this.callbacks[l];delete this.callbacks[l],u&&(o.error?u(Lu(o.error)):u(null,Lu(o.data)))}else{const u=Tt(this.globalScope)?void 0:[],d=o.hasCallback?(_,b)=>{delete this.cancelCallbacks[l],this.target.postMessage({id:l,type:"<response>",sourceMapId:this.mapId,error:_?kh(_):null,data:kh(b,u)},u)}:_=>{},p=Lu(o.data);if(this.parent[o.type])this.parent[o.type](o.sourceMapId,p,d);else if(this.parent.getWorkerSource){const _=o.type.split(".");this.parent.getWorkerSource(o.sourceMapId,_[0],p.source)[_[1]](p,d)}else d(new Error(`Could not find function ${o.type}`))}}remove(){this.scheduler.remove(),this.target.removeEventListener("message",this.receive,!1)}},a.CanonicalTileID=w0,a.Color=Rt,a.ColorMode=Qc,a.CullFaceMode=yc,a.DEMData=N0,a.DataConstantProperty=te,a.DedupedRequest=BM,a.DepthMode=um,a.EXTENT=Rn,a.Elevation=class{isDataAvailableAtPoint(l){const o=this._source();if(this.isUsingMockSource()||!o||l.y<0||l.y>1)return!1;const u=o.getSource().maxzoom,d=1<<u,p=Math.floor(l.x),_=Math.floor((l.x-p)*d),b=Math.floor(l.y*d),E=this.findDEMTileFor(new Za(u,p,u,_,b));return!(!E||!E.dem)}getAtPointOrZero(l,o=0){return this.getAtPoint(l,o)||0}getAtPoint(l,o,u=!0){if(this.isUsingMockSource())return null;o==null&&(o=null);const d=this._source();if(!d||l.y<0||l.y>1)return o;const p=d.getSource().maxzoom,_=1<<p,b=Math.floor(l.x),E=l.x-b,k=new Za(p,b,p,Math.floor(E*_),Math.floor(l.y*_)),M=this.findDEMTileFor(k);if(!M||!M.dem)return o;const F=M.dem,$=1<<M.tileID.canonical.z,V=(E*$-M.tileID.canonical.x)*F.dim,X=(l.y*$-M.tileID.canonical.y)*F.dim,J=Math.floor(V),re=Math.floor(X);return(u?this.exaggeration():1)*ur(ur(F.get(J,re),F.get(J,re+1),X-re),ur(F.get(J+1,re),F.get(J+1,re+1),X-re),V-J)}getAtTileOffset(l,o,u){const d=1<<l.canonical.z;return this.getAtPointOrZero(new Xp(l.wrap+(l.canonical.x+o/Rn)/d,(l.canonical.y+u/Rn)/d))}getAtTileOffsetFunc(l,o,u,d){return p=>{const _=this.getAtTileOffset(l,p.x,p.y),b=d.upVector(l.canonical,p.x,p.y);return il(b,b,_*d.upVectorScale(l.canonical,o,u).metersToTile),b}}
120getForTilePoints(l,o,u,d){if(this.isUsingMockSource())return!1;const p=$0.create(this,l,d);return!!p&&(o.forEach(_=>{_[2]=this.exaggeration()*p.getElevationAt(_[0],_[1],u)}),!0)}getMinMaxForTile(l){if(this.isUsingMockSource())return null;const o=this.findDEMTileFor(l);if(!o||!o.dem)return null;const u=o.dem.tree,d=o.tileID,p=1<<l.canonical.z-d.canonical.z;let _=l.canonical.x/p-d.canonical.x,b=l.canonical.y/p-d.canonical.y,E=0;for(let k=0;k<l.canonical.z-d.canonical.z&&!u.leaves[E];k++){_*=2,b*=2;const M=2*Math.floor(b)+Math.floor(_);E=u.childOffsets[E]+M,_%=1,b%=1}return{min:this.exaggeration()*u.minimums[E],max:this.exaggeration()*u.maximums[E]}}getMinElevationBelowMSL(){throw new Error("Pure virtual method called.")}raycast(l,o,u){throw new Error("Pure virtual method called.")}pointCoordinate(l){throw new Error("Pure virtual method called.")}_source(){throw new Error("Pure virtual method called.")}isUsingMockSource(){throw new Error("Pure virtual method called.")}exaggeration(){throw new Error("Pure virtual method called.")}findDEMTileFor(l){throw new Error("Pure virtual method called.")}get visibleDemTiles(){throw new Error("Getter must be implemented in subclass.")}},a.ErrorEvent=Wo,a.EvaluationParameters=z,a.Event=vl,a.Evented=fa,a.FillExtrusionBucket=my,a.Frustum=iw,a.FrustumCorners=rw,a.GLOBE_RADIUS=Wc,a.GLOBE_SCALE_MATCH_LATITUDE=45,a.GLOBE_ZOOM_THRESHOLD_MAX=$A,a.GLOBE_ZOOM_THRESHOLD_MIN=ow,a.GlobeSharedBuffers=class{constructor(l){this._createGrid(l),this._createPoles(l)}destroy(){this._poleIndexBuffer.destroy(),this._gridBuffer.destroy(),this._gridIndexBuffer.destroy(),this._poleNorthVertexBuffer.destroy(),this._poleSouthVertexBuffer.destroy();for(const l of this._poleSegments)l.destroy();for(const l of this._gridSegments)l.withSkirts.destroy(),l.withoutSkirts.destroy();if(this._wireframeIndexBuffer){this._wireframeIndexBuffer.destroy();for(const l of this._wireframeSegments)l.destroy()}}_fillGridMeshWithLods(l,o){const u=new Zt,d=new Cn,p=[],_=l+1+2,b=o[0]+1,E=o[0]+1+(1+o.length),k=(M,F,$)=>{let V=M===_-1?M-2:M===0?M:M-1;return V+=$?24575:0,[V,F]};for(let M=0;M<_;++M)u.emplaceBack(...k(M,0,!0));for(let M=0;M<b;++M)for(let F=0;F<_;++F)u.emplaceBack(...k(F,M,(F===0||F===_-1)&&!0));for(let M=0;M<o.length;++M){const F=o[M];for(let $=0;$<_;++$)u.emplaceBack(...k($,F,!0))}for(let M=0;M<o.length;++M){const F=d.length,$=o[M]+1+2,V=new Cn;for(let re=0;re<$-1;re++){const pe=re===$-2,Ce=pe?_*(E-o.length+M-re):_;for(let ze=0;ze<_-1;ze++){const ke=re*_+ze;re===0||pe||ze===0||ze===_-2?(V.emplaceBack(ke+1,ke,ke+Ce),V.emplaceBack(ke+Ce,ke+Ce+1,ke+1)):(d.emplaceBack(ke+1,ke,ke+Ce),d.emplaceBack(ke+Ce,ke+Ce+1,ke+1))}}const X=yo.simpleSegment(0,F,u.length,d.length-F);for(let re=0;re<V.uint16.length;re+=3)d.emplaceBack(V.uint16[re],V.uint16[re+1],V.uint16[re+2]);const J=yo.simpleSegment(0,F,u.length,d.length-F);p.push({withoutSkirts:X,withSkirts:J})}return{vertices:u,indices:d,segments:p}}_createGrid(l){const o=this._fillGridMeshWithLods(bf,oy);this._gridSegments=o.segments,this._gridBuffer=l.createVertexBuffer(o.vertices,iy.members),this._gridIndexBuffer=l.createIndexBuffer(o.indices,!0)}_createPoles(l){const o=new Cn;for(let p=0;p<=bf;p++)o.emplaceBack(0,p+1,p+2);this._poleIndexBuffer=l.createIndexBuffer(o,!0);const u=new ei,d=new ei;this._poleSegments=[];for(let p=0,_=0;p<ow;p++){const b=360/(1<<p);u.emplaceBack(0,-Wc,0,.5,0),d.emplaceBack(0,-Wc,0,.5,1);for(let E=0;E<=bf;E++){const k=E/bf,M=ur(0,b,k),[F,$,V]=Hp(Qj,Jj,M,Wc);u.emplaceBack(F,$,V,k,0),d.emplaceBack(F,$,V,k,1)}this._poleSegments.push(yo.simpleSegment(_,0,66,64)),_+=66}this._poleNorthVertexBuffer=l.createVertexBuffer(u,zA,!1),this._poleSouthVertexBuffer=l.createVertexBuffer(d,zA,!1)}getGridBuffers(l,o){return[this._gridBuffer,this._gridIndexBuffer,o?this._gridSegments[l].withSkirts:this._gridSegments[l].withoutSkirts]}getPoleBuffers(l){return[this._poleNorthVertexBuffer,this._poleSouthVertexBuffer,this._poleIndexBuffer,this._poleSegments[l]]}getWirefameBuffers(l,o){if(!this._wireframeSegments){const u=new Yo,d=bf,p=d+1+2,_=1;this._wireframeSegments=[];for(let b=0,E=0;b<oy.length;b++){const k=oy[b];for(let F=_;F<k+_;F++)for(let $=_;$<d+_;$++){const V=F*p+$;u.emplaceBack(V,V+1),u.emplaceBack(V,V+p),u.emplaceBack(V,V+p+1)}const M=k*d*3;this._wireframeSegments.push(yo.simpleSegment(0,E,(k+1)*p,M)),E+=M}this._wireframeIndexBuffer=l.createIndexBuffer(u)}return[this._gridBuffer,this._wireframeIndexBuffer,this._wireframeSegments[o]]}},a.GlyphManager=om,a.ImagePosition=Ow,a.KDBush=Zw,a.LivePerformanceUtils=Ig,a.LngLat=ni,a.LngLatBounds=Ih,a.LocalGlyphMode=Rw,a.MAX_MERCATOR_LATITUDE=va,a.MercatorCoordinate=Xp,a.ONE_EM=aa,a.OverscaledTileID=Za,a.PerformanceMarkers=Lc,a.Point=Y,a.Properties=Le,a.RGBAImage=As,a.Ray=nw,a.RequestManager=class{constructor(l,o,u){this._transformRequestFn=l,this._customAccessToken=o,this._silenceAuthErrors=!!u,this._createSkuToken()}_createSkuToken(){const l=function(){let o="";for(let u=0;u<10;u++)o+="0123456789abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ"[Math.floor(62*Math.random())];return{token:["1",N,o].join(""),tokenExpiresAt:Date.now()+432e5}}();this._skuToken=l.token,this._skuTokenExpiresAt=l.tokenExpiresAt}_isSkuTokenExpired(){return Date.now()>this._skuTokenExpiresAt}transformRequest(l,o){return this._transformRequestFn&&this._transformRequestFn(l,o)||{url:l}}normalizeStyleURL(l,o){if(!Xe(l))return l;const u=ln(l);return u.path=`/styles/v1${u.path}`,this._makeAPIURL(u,this._customAccessToken||o)}normalizeGlyphsURL(l,o){if(!Xe(l))return l;const u=ln(l);return u.path=`/fonts/v1${u.path}`,this._makeAPIURL(u,this._customAccessToken||o)}
120normalizeSourceURL(l,o,u,d){if(!Xe(l))return l;const p=ln(l);return p.path=`/v4/${p.authority}.json`,p.params.push("secure"),u&&p.params.push(`language=${u}`),d&&p.params.push(`worldview=${d}`),this._makeAPIURL(p,this._customAccessToken||o)}normalizeSpriteURL(l,o,u,d){const p=ln(l);return Xe(l)?(p.path=`/styles/v1${p.path}/sprite${o}${u}`,this._makeAPIURL(p,this._customAccessToken||d)):(p.path+=`${o}${u}`,Kt(p))}normalizeTileURL(l,o,u){if(this._isSkuTokenExpired()&&this._createSkuToken(),l&&!Xe(l))return l;const d=ln(l);d.path=d.path.replace(/(\.(png|jpg)\d*)(?=$)/,`${o||u&&d.authority!=="raster"&&u===512?"@2x":""}${C.supported?".webp":"$1"}`),d.authority==="raster"?d.path=`/${T.RASTER_URL_PREFIX}${d.path}`:(d.path=d.path.replace(/^.+\/v4\//,"/"),d.path=`/${T.TILE_URL_VERSION}${d.path}`);const p=this._customAccessToken||function(_){for(const b of _){const E=b.match(/^access_token=(.*)$/);if(E)return E[1]}return null}(d.params)||T.ACCESS_TOKEN;return T.REQUIRE_ACCESS_TOKEN&&p&&this._skuToken&&d.params.push(`sku=${this._skuToken}`),this._makeAPIURL(d,p)}canonicalizeTileURL(l,o){const u=ln(l);if(!u.path.match(/^(\/v4\/|\/raster\/v1\/)/)||!u.path.match(/\.[\w]+$/))return l;let d="mapbox://";u.path.match(/^\/raster\/v1\//)?d+=`raster/${u.path.replace(`/${T.RASTER_URL_PREFIX}/`,"")}`:d+=`tiles/${u.path.replace(`/${T.TILE_URL_VERSION}/`,"")}`;let p=u.params;return o&&(p=p.filter(_=>!_.match(/^access_token=/))),p.length&&(d+=`?${p.join("&")}`),d}canonicalizeTileset(l,o){const u=!!o&&Xe(o),d=[];for(const p of l.tiles||[])ht(p)?d.push(this.canonicalizeTileURL(p,u)):d.push(p);return d}_makeAPIURL(l,o){const u="See https://docs.mapbox.com/api/overview/#access-tokens-and-token-scopes",d=ln(T.API_URL);if(l.protocol=d.protocol,l.authority=d.authority,l.protocol==="http"){const p=l.params.indexOf("secure");p>=0&&l.params.splice(p,1)}if(d.path!=="/"&&(l.path=`${d.path}${l.path}`),!T.REQUIRE_ACCESS_TOKEN)return Kt(l);
120if(o=o||T.ACCESS_TOKEN,!this._silenceAuthErrors){if(!o)throw new Error(`An API access token is required to use Mapbox GL. ${u}`);if(o[0]==="s")throw new Error(`Use a public access token (pk.*) with Mapbox GL, not a secret access token (sk.*). ${u}`)}return l.params=l.params.filter(p=>p.indexOf("access_token")===-1),l.params.push(`access_token=${o||""}`),Kt(l)}},a.ResourceType=Ni,a.SegmentVector=yo,a.SourceCache=Cf,a.StencilMode=qw,a.StructArrayLayout1ui2=Cs,a.StructArrayLayout2f1f2i16=Bn,a.StructArrayLayout2i4=Zt,a.StructArrayLayout2ui4=Yo,a.StructArrayLayout3f12=pr,a.StructArrayLayout3ui6=Cn,a.StructArrayLayout4i8=Bt,a.StructArrayLayout5f20=ei,a.Texture=Cy,a.Tile=Vw,a.Transitionable=ee,a.Uniform1f=o0,a.Uniform1i=class extends Bu{constructor(l){super(l),this.current=0}set(l,o,u){this.fetchUniformLocation(l,o)&&this.current!==u&&(this.current=u,this.gl.uniform1i(this.location,u))}},a.Uniform2f=class extends Bu{constructor(l){super(l),this.current=[0,0]}set(l,o,u){this.fetchUniformLocation(l,o)&&(u[0]===this.current[0]&&u[1]===this.current[1]||(this.current=u,this.gl.uniform2f(this.location,u[0],u[1])))}},a.Uniform3f=class extends Bu{constructor(l){super(l),this.current=[0,0,0]}set(l,o,u){this.fetchUniformLocation(l,o)&&(u[0]===this.current[0]&&u[1]===this.current[1]&&u[2]===this.current[2]||(this.current=u,this.gl.uniform3f(this.location,u[0],u[1],u[2])))}},a.Uniform4f=xA,a.UniformColor=wA,a.UniformMatrix2f=class extends Bu{constructor(l){super(l),this.current=Fj}set(l,o,u){if(this.fetchUniformLocation(l,o)){for(let d=0;d<4;d++)if(u[d]!==this.current[d]){this.current=u,this.gl.uniformMatrix2fv(this.location,!1,u);break}}}},a.UniformMatrix3f=class extends Bu{constructor(l){super(l),this.current=Rj}set(l,o,u){if(this.fetchUniformLocation(l,o)){for(let d=0;d<9;d++)if(u[d]!==this.current[d]){this.current=u,this.gl.uniformMatrix3fv(this.location,!1,u);break}}}},a.UniformMatrix4f=class extends Bu{constructor(l){super(l),this.current=Lj}set(l,o,u){if(this.fetchUniformLocation(l,o)){if(u[12]!==this.current[12]||u[0]!==this.current[0])return this.current=u,void this.gl.uniformMatrix4fv(this.location,!1,u);for(let d=1;d<16;d++)if(u[d]!==this.current[d]){this.current=u,this.gl.uniformMatrix4fv(this.location,!1,u);break}}}},a.UnwrappedTileID=AP,a.ValidationError=vn,a.VectorTileFeature=b0,a.VectorTileWorkerSource=class extends fa{constructor(l,o,u,d,p){super(),this.actor=l,this.layerIndex=o,this.availableImages=u,this.loadVectorData=p||zM,this.loading={},this.loaded={},this.deduped=new BM(l.scheduler),this.isSpriteLoaded=d,this.scheduler=l.scheduler}loadTile(l,o){const u=l.uid,d=l&&l.request,p=d&&d.collectResourceTiming,_=this.loading[u]=new o6(l);_.abort=this.loadVectorData(l,(b,E)=>{const k=!this.loading[u];if(delete this.loading[u],k||b||!E)return _.status="done",k||(this.loaded[u]=_),o(b);const M=E.rawData,F={};E.expires&&(F.expires=E.expires),E.cacheControl&&(F.cacheControl=E.cacheControl),_.vectorTile=E.vectorTile||new kw(new C0(M));const $=()=>{_.parse(_.vectorTile,this.layerIndex,this.availableImages,this.actor,(V,X)=>{if(V||!X)return o(V);const J={};if(p){const re=Ud(d);re.length>0&&(J.resourceTiming=JSON.parse(JSON.stringify(re)))}o(null,xt({rawTileData:M.slice(0)},X,F,J))})};this.isSpriteLoaded?$():this.once("isSpriteLoaded",()=>{this.scheduler?this.scheduler.add($,{type:"parseTile",isSymbolTile:l.isSymbolTile,zoom:l.tileZoom}):$()}),this.loaded=this.loaded||{},this.loaded[u]=_})}reloadTile(l,o){const u=this.loaded,d=l.uid,p=this;if(u&&u[d]){const _=u[d];_.showCollisionBoxes=l.showCollisionBoxes,_.enableTerrain=!!l.enableTerrain,_.projection=l.projection,_.tileTransform=Sf(l.tileID.canonical,l.projection);const b=(E,k)=>{const M=_.reloadCallback;M&&(delete _.reloadCallback,_.parse(_.vectorTile,p.layerIndex,this.availableImages,p.actor,M)),o(E,k)};_.status==="parsing"?_.reloadCallback=b:_.status==="done"&&(_.vectorTile?_.parse(_.vectorTile,this.layerIndex,this.availableImages,this.actor,b):b())}}abortTile(l,o){const u=l.uid,d=this.loading[u];d&&(d.abort&&d.abort(),delete this.loading[u]),o()}removeTile(l,o){const u=this.loaded,d=l.uid;u&&u[d]&&delete u[d],o()}},a.WritingMode=al,a.ZoomDependentExpression=sf,a.add=Nu,a.addDynamicAttributes=F0,a.adjoint=function(l,o){var u=o[0],d=o[1],p=o[2],_=o[3],b=o[4],E=o[5],k=o[6],M=o[7],F=o[8];
120return l[0]=b*F-E*M,l[1]=p*M-d*F,l[2]=d*E-p*b,l[3]=E*k-_*F,l[4]=u*F-p*k,l[5]=p*_-u*E,l[6]=_*M-b*k,l[7]=d*k-u*M,l[8]=u*b-d*_,l},a.asyncAll=Ne,a.bezier=Te,a.bindAll=tt,a.boundsAttributes=bM,a.bufferConvexPolygon=function(l,o){const u=[];for(let d=0;d<l.length;d++){const p=se(d-1,-1,l.length-1),_=se(d+1,-1,l.length-1),b=l[d],E=l[_],k=l[p].sub(b).unit(),M=E.sub(b).unit(),F=M.angleWithSep(k.x,k.y),$=k.add(M).unit().mult(-1*o/Math.sin(F/2));u.push(b.add($))}return u},a.cacheEntryPossiblyAdded=function(l){Ji++,Ji>$t&&(l.getActor().send("enforceCacheSizeLimit",It),Ji=0)},a.calculateGlobeLabelMatrix=function(l,o){const{x:u,y:d}=l.point,p=qA(u,d,l.worldSize/l._pixelsPerMercatorPixel,0,0);return yf(p,p,lw(Hc(o)))},a.calculateGlobeMatrix=function(l){const{x:o,y:u}=l.point,{lng:d,lat:p}=l._center;return qA(o,u,l.worldSize,d,p)},a.calculateGlobeMercatorMatrix=function(l){const o=l.pixelsPerMeter,u=o/pc(1,l.center.lat),d=dc(new Float64Array(16));return Qg(d,d,[l.point.x,l.point.y,0]),_f(d,d,[u,u,o]),Float32Array.from(d)},a.circumferenceAtLatitude=uw,a.clamp=ne,a.clearTileCache=function(l){if(!gn())return;const o=m.caches.delete(nt);l&&o.catch(l).then(()=>l())},a.clipLine=nM,a.clone=function(l){var o=new ks(16);return o[0]=l[0],o[1]=l[1],o[2]=l[2],o[3]=l[3],o[4]=l[4],o[5]=l[5],o[6]=l[6],o[7]=l[7],o[8]=l[8],o[9]=l[9],o[10]=l[10],o[11]=l[11],o[12]=l[12],o[13]=l[13],o[14]=l[14],o[15]=l[15],o},a.clone$1=we,a.collisionCircleLayout=rV,a.config=T,a.conjugate=function(l,o){return l[0]=-o[0],l[1]=-o[1],l[2]=-o[2],l[3]=o[3],l},a.create=function(){var l=new ks(16);return ks!=Float32Array&&(l[1]=0,l[2]=0,l[3]=0,l[4]=0,l[6]=0,l[7]=0,l[8]=0,l[9]=0,l[11]=0,l[12]=0,l[13]=0,l[14]=0),l[0]=1,l[5]=1,l[10]=1,l[15]=1,l},a.create$1=SA,a.createExpression=Eh,a.createLayout=et,a.createStyleLayer=function(l){return l.type==="custom"?new YV(l):new XV[l.type](l)},a.cross=tw,a.degToRad=ce,a.distance=function(l,o){return Math.hypot(o[0]-l[0],o[1]-l[1],o[2]-l[2])},a.div=function(l,o,u){return l[0]=o[0]/u[0],l[1]=o[1]/u[1],l[2]=o[2]/u[2],l},a.dot=Dl,a.earthRadius=ly,a.ease=oe,a.easeCubicInOut=xe,a.ecefToLatLng=function([l,o,u]){const d=Math.hypot(l,o,u),p=Math.atan2(l,u),_=.5*Math.PI-Math.acos(-o/d);return new ni(fe(p),fe(_))},a.emitValidationErrors=Jv,a.endsWith=Me,a.enforceCacheSizeLimit=function(l){Pn(),$e&&$e.then(o=>{o.keys().then(u=>{for(let d=0;d<u.length-l;d++)o.delete(u[d])})})},a.evaluateSizeForFeature=E0,a.evaluateSizeForZoom=tm,a.evaluateVariableOffset=sM,a.evented=w,a.exactEquals=function(l,o){return l[0]===o[0]&&l[1]===o[1]&&l[2]===o[2]&&l[3]===o[3]},a.exactEquals$1=function(l,o){return l[0]===o[0]&&l[1]===o[1]&&l[2]===o[2]},a.exported=is,a.exported$1=C,a.extend=xt,a.extend$1=ta,a.fillExtrusionHeightLift=SP,a.filterObject=Ae,a.fromMat4=function(l,o){return l[0]=o[0],l[1]=o[1],l[2]=o[2],l[3]=o[4],l[4]=o[5],l[5]=o[6],l[6]=o[8],l[7]=o[9],l[8]=o[10],l},a.fromQuat=function(l,o){var u=o[0],d=o[1],p=o[2],_=o[3],b=u+u,E=d+d,k=p+p,M=u*b,F=d*b,$=d*E,V=p*b,X=p*E,J=p*k,re=_*b,pe=_*E,Ce=_*k;return l[0]=1-$-J,l[1]=F+Ce,l[2]=V-pe,l[3]=0,l[4]=F-Ce,l[5]=1-M-J,l[6]=X+re,l[7]=0,l[8]=V+pe,l[9]=X-re,l[10]=1-M-$,l[11]=0,l[12]=0,l[13]=0,l[14]=0,l[15]=1,l},a.fromRotation=function(l,o){var u=Math.sin(o),d=Math.cos(o);return l[0]=d,l[1]=u,l[2]=0,l[3]=-u,l[4]=d,l[5]=0,l[6]=0,l[7]=0,l[8]=1,l},a.fromScaling=kA,a.furthestTileCorner=function(l){const o=Math.round((l+45+360)%360/90)%4;return ie[o]},a.getAABBPointSquareDist=function(l,o,u){let d=0;for(let p=0;p<2;++p){const _=u?u[p]:0;l[p]>_&&(d+=(l[p]-_)*(l[p]-_)),o[p]<_&&(d+=(_-o[p])*(_-o[p]))}return d},a.getAnchorAlignment=Lw,a.getAnchorJustification=Bw,a.getBounds=function(l){let o=1/0,u=1/0,d=-1/0,p=-1/0;for(const _ of l)o=Math.min(o,_.x),u=Math.min(u,_.y),d=Math.max(d,_.x),p=Math.max(p,_.y);return{min:new Y(o,u),max:new Y(d,p)}},a.getColumn=qt,a.getDefaultExportFromCjs=j,a.getGridMatrix=function(l,o,u,d){const p=o.getNorth(),_=o.getSouth(),b=o.getWest(),E=o.getEast(),k=1<<l.z,M=E-b,F=p-_,$=M/bf,V=-F/oy[u],X=[0,$,0,V,0,0,p,b,0];if(l.z>0){const J=180/d;CA(X,X,[J/M+1,0,0,0,J/F+1,0,-.5*J/$,.5*J/V,1])}return X[2]=k,X[5]=l.x,X[8]=l.y,X},a.getImage=De,a.getJSON=function(l,o){return Wr(xt(l,{type:"json"}),o)},a.getLatitudinalLod=function(l){const o=va-5;l=ne(l,-o,o)/o*90;const u=Math.pow(Math.abs(Math.sin(ce(l))),3);return Math.round(u*(oy.length-1))},a.getMapSessionAPI=Po,a.getPerformanceMeasurement=Ud,a.getProjection=mM,a.getRTLTextPluginStatus=S,a.getReferrer=_i,a.getTilePoint=function(l,{x:o,y:u},d=0){return new Y(((o-d)*l.scale-l.x)*Rn,(u*l.scale-l.y)*Rn)},a.getTileVec3=function(l,o,u=0){return Wp(((o.x-u)*l.scale-l.x)*Rn,(o.y*l.scale-l.y)*Rn,ZA(o.z,o.y))},a.getVideo=function(l,o){const u=m.document.createElement("video");u.muted=!0,u.onloadstart=function(){o(null,u)};for(let d=0;d<l.length;d++){const p=m.document.createElement("source");xs(l[d])||(u.crossOrigin="Anonymous"),p.src=l[d],u.appendChild(p)}return{cancel:()=>{}}},a.globeCenterToScreenPoint=function(l){const o=[0,0,0],u=dc(new Float64Array(16));return yf(u,l.pixelMatrix,l.globeMatrix),co(o,o,u),new Y(o[0],o[1])},a.globeDenormalizeECEF=lw,a.globeECEFOrigin=function(l,o){const u=[0,0,0];return co(u,u,sy(Hc(o.canonical))),co(u,u,l),u},a.globeMetersToEcef=l0,a.globeNormalizeECEF=sy,a.globePixelsToTileUnits=function(l,o){return Rn/(512*Math.pow(2,l))*u0(Hc(o))},a.globePoleMatrixForTile=function(l,o,u){const d=dc(new Float64Array(16)),p=(o/(1<<l)-.5)*Math.PI*2;return s0(d,u.globeMatrix,p),Float32Array.from(d)},a.globeTileBounds=Hc,a.globeTiltAtLngLat=WA,a.globeToMercatorTransition=Zp,a.globeUseCustomAntiAliasing=function(l,o,u){const d=Zp(u.zoom),p=l.style.map._antialias,_=!!o.extStandardDerivatives,b=o.extStandardDerivativesForceOff||l.terrain&&l.terrain.exaggeration()>0;return d===0&&!p&&!b&&_},a.identity=dc,a.identity$1=RA,a.invert=K1,a.isFullscreen=function(){return!!m.document.fullscreenElement||!!m.document.webkitFullscreenElement},a.isLngLatBehindGlobe=cw,a.isMapAuthenticated=function(l){return Hr.has(l)},a.isMapboxURL=Xe,a.isSafariWithAntialiasingBug=function(l){const o=l.navigator?l.navigator.userAgent:null;return!!Tt(l)&&o&&(o.match("Version/15.4")||o.match("Version/15.5")||o.match(/CPU (OS|iPhone OS) (15_4|15_5) like Mac OS X/))},a.latFromMercatorY=_a,a.latLngToECEF=Yp,a.len=qj,a.length=Jg,a.length$1=function(l){return Math.hypot(l[0],l[1],l[2],l[3])},a.lngFromMercatorX=ol,a.loadVectorTile=zM,a.makeRequest=Wr,a.mapValue=function(l,o,u,d,p){return ne((l-
120o)/(u-o)*(p-d)+d,d,p)},a.mercatorScale=XA,a.mercatorXfromLng=Yc,a.mercatorYfromLat=Zc,a.mercatorZfromAltitude=pc,a.mul=Vj,a.mul$1=Gj,a.multiply=yf,a.multiply$1=CA,a.multiply$2=MA,a.nextPowerOfTwo=je,a.normalize=Ha,a.normalize$1=Wj,a.normalize$2=DA,a.number=ur,a.ortho=function(l,o,u,d,p,_,b){var E=1/(o-u),k=1/(d-p),M=1/(_-b);return l[0]=-2*E,l[1]=0,l[2]=0,l[3]=0,l[4]=0,l[5]=-2*k,l[6]=0,l[7]=0,l[8]=0,l[9]=0,l[10]=2*M,l[11]=0,l[12]=(o+u)*E,l[13]=(p+d)*k,l[14]=(b+_)*M,l[15]=1,l},a.pbf=RP,a.perspective=function(l,o,u,d,p){var _,b=1/Math.tan(o/2);return l[0]=b/u,l[1]=0,l[2]=0,l[3]=0,l[4]=0,l[5]=b,l[6]=0,l[7]=0,l[8]=0,l[9]=0,l[11]=-1,l[12]=0,l[13]=0,l[15]=0,p!=null&&p!==1/0?(l[10]=(p+d)*(_=1/(d-p)),l[14]=2*p*d*_):(l[10]=-1,l[14]=-2*d),l},a.pick=function(l,o){const u={};for(let d=0;d<o.length;d++){const p=o[d];p in l&&(u[p]=l[p])}return u},a.plugin=L,a.pointGeometry=Z,a.polesInViewport=function(l){const o=dc(new Float64Array(16));yf(o,l.pixelMatrix,l.globeMatrix);const u=[0,Ll,0],d=[0,Rl,0];return co(u,u,o),co(d,d,o),[u[0]>0&&u[0]<=l.width&&u[1]>0&&u[1]<=l.height&&!cw(l,new ni(l.center.lat,90)),d[0]>0&&d[0]<=l.width&&d[1]>0&&d[1]<=l.height&&!cw(l,new ni(l.center.lat,-90))]},a.polygonContainsPoint=Tf,a.polygonIntersectsBox=rP,a.polygonIntersectsPolygon=JA,a.polygonizeBounds=function(l,o,u=0,d=!0){const p=new Y(u,u),_=l.sub(p),b=o.add(p),E=[_,new Y(b.x,_.y),b,new Y(_.x,b.y)];return d&&E.push(_.clone()),E},a.posAttributes=iy,a.postMapLoadEvent=Wi,a.postPerformanceEvent=$i,a.postTurnstileEvent=lr,a.potpack=Iw,a.prevPowerOfTwo=function(l){return l<=1?1:Math.pow(2,Math.floor(Math.log(l)/Math.LN2))},a.radToDeg=fe,a.refProperties=["type","source","source-layer","minzoom","maxzoom","filter","layout"],a.registerForPluginStateChange=function(l){return l({pluginStatus:y,pluginURL:h}),w.on("pluginStateChange",l),l},a.removeAuthState=function(l){Hr.delete(l)},a.renderColorRamp=_w,a.resample=KA,a.rotateX=Q1,a.rotateX$1=FA,a.rotateY=s0,a.rotateY$1=BA,a.rotateZ=function(l,o,u){var d=Math.sin(u),p=Math.cos(u),_=o[0],b=o[1],E=o[2],k=o[3],M=o[4],F=o[5],$=o[6],V=o[7];return o!==l&&(l[8]=o[8],l[9]=o[9],l[10]=o[10],l[11]=o[11],l[12]=o[12],l[13]=o[13],l[14]=o[14],l[15]=o[15]),l[0]=_*p+M*d,l[1]=b*p+F*d,l[2]=E*p+$*d,l[3]=k*p+V*d,l[4]=M*p-_*d,l[5]=F*p-b*d,l[6]=$*p-E*d,l[7]=V*p-k*d,l},a.rotateZ$1=function(l,o,u){u*=.5;var d=o[0],p=o[1],_=o[2],b=o[3],E=Math.sin(u),k=Math.cos(u);return l[0]=d*k+p*E,l[1]=p*k-d*E,l[2]=_*k+b*E,l[3]=b*k-_*E,l},a.scale=_f,a.scale$1=OA,a.scale$2=il,a.scaleAndAdd=ny,a.set=function(l,o,u,d){return l[0]=o,l[1]=u,l[2]=d,l},a.setCacheLimits=function(l,o){It=l,$t=o},a.setColumn=function(l,o,u){l[4*o+0]=u[0],l[4*o+1]=u[1],l[4*o+2]=u[2],l[4*o+3]=u[3]},a.setRTLTextPlugin=function(l,o,u=!1){if(y===Hg||y===Yg||y===Zg)throw new Error("setRTLTextPlugin cannot be called multiple times.");h=is.resolveURL(l),y=Hg,Ah=o,v(),u||I()},a.smoothstep=le,a.spec=Pt,a.squaredLength=function(l){var o=l[0],u=l[1],d=l[2];return o*o+u*u+d*d},a.storeAuthState=function(l,o){o?Hr.add(l):Hr.delete(l)},a.sub=fc,a.subtract=ew,a.symbolSize=iV,a.tileAABB=function(l,o,u,d,p,_,b,E,k){if(k.name==="globe")return Kj(l,o,new w0(u,d,p));const M=Sf({z:u,x:d,y:p},k);return new Ya([(_+M.x/M.scale)*o,o*(M.y/M.scale),b],[(_+M.x2/M.scale)*o,o*(M.y2/M.scale),E])},a.tileCornersToBounds=c0,a.tileTransform=Sf,a.transformMat3=function(l,o,u){var d=o[0],p=o[1],_=o[2];return l[0]=d*u[0]+p*u[3]+_*u[6],l[1]=d*u[1]+p*u[4]+_*u[7],l[2]=d*u[2]+p*u[5]+_*u[8],l},a.transformMat4=co,a.transformMat4$1=vf,a.transformQuat=IA,a.transitionTileAABBinECEF=UA,a.translate=Qg,a.transpose=function(l,o){if(l===o){var u=o[1],d=o[2],p=o[5];l[1]=o[3],l[2]=o[6],l[3]=u,l[5]=o[7],l[6]=d,l[7]=p}else l[0]=o[0],l[1]=o[3],l[2]=o[6],l[3]=o[1],l[4]=o[4],l[5]=o[7],l[6]=o[2],l[7]=o[5],l[8]=o[8];return l},a.triggerPluginCompletionEvent=f,a.uniqueId=wt,a.updateGlobeVertexNormal=function(l,o,u,d,p){const _=5*o+2;l.float32[_+0]=u,l.float32[_+1]=d,l.float32[_+2]=p},a.validateCustomStyleLayer=function(l){const o=[],u=l.id;return u===void 0&&o.push({message:`layers.${u}: missing required property "id"`}),l.render===void 0&&o.push({message:`layers.${u}: missing required method "render"`}),l.renderingMode&&l.renderingMode!=="2d"&&l.renderingMode!=="3d"&&o.push({message:`layers.${u}: property "renderingMode" must be either "2d" or "3d"`}),o},a.validateFilter=l=>Ss(df(l)),a.validateFog=l=>Ss(Xv(l)),a.validateLayer=l=>Ss(Wv(l)),a.validateLight=l=>Ss(Zv(l)),a.validateSource=l=>Ss(Yv(l)),a.validateStyle=Qv,a.validateTerrain=l=>Ss(Ug(l)),a.values=Se,a.vectorTile=v0,a.version=g,a.warnOnce=ct,a.window=m,a.wrap=se}),s(["./shared"],function(a){function m(Fe){if(typeof Fe=="number"||typeof Fe=="boolean"||typeof Fe=="string"||Fe==null)return JSON.stringify(Fe);if(Array.isArray(Fe)){let ue="[";for(const De of Fe)ue+=`${m(De)},`;return`${ue}]`}let ae="{";for(const ue of Object.keys(Fe).sort())ae+=`${ue}:${m(Fe[ue])},`;return`${ae}}`}function g(Fe){let ae="";for(const ue of a.refProperties)ae+=`/${m(Fe[ue])}`;return ae}class x{constructor(ae){this.keyCache={},ae&&this.replace(ae)}replace(ae){this._layerConfigs={},this._layers={},this.update(ae,[])}update(ae,ue){for(const qe of ae)this._layerConfigs[qe.id]=qe,(this._layers[qe.id]=a.createStyleLayer(qe)).c
120ompileFilter(),this.keyCache[qe.id]&&delete this.keyCache[qe.id];for(const qe of ue)delete this.keyCache[qe],delete this._layerConfigs[qe],delete this._layers[qe];this.familiesBySource={};const De=function(qe,Xe){const ht={};for(let Ke=0;Ke<qe.length;Ke++){const Et=Xe&&Xe[qe[Ke].id]||g(qe[Ke]);Xe&&(Xe[qe[Ke].id]=Et);let en=ht[Et];en||(en=ht[Et]=[]),en.push(qe[Ke])}const ut=[];for(const Ke in ht)ut.push(ht[Ke]);return ut}(a.values(this._layerConfigs),this.keyCache);for(const qe of De){const Xe=qe.map(ln=>this._layers[ln.id]),ht=Xe[0];if(ht.visibility==="none")continue;const ut=ht.source||"";let Ke=this.familiesBySource[ut];Ke||(Ke=this.familiesBySource[ut]={});const Et=ht.sourceLayer||"_geojsonTileLayer";let en=Ke[Et];en||(en=Ke[Et]=[]),en.push(Xe)}}}class T{loadTile(ae,ue){const{uid:De,encoding:qe,rawImageData:Xe,padding:ht,buildQuadTree:ut}=ae,Ke=a.window.ImageBitmap&&Xe instanceof a.window.ImageBitmap?this.getImageData(Xe,ht):Xe;ue(null,new a.DEMData(De,Ke,qe,ht<1,ut))}getImageData(ae,ue){this.offscreenCanvas&&this.offscreenCanvasContext||(this.offscreenCanvas=new OffscreenCanvas(ae.width,ae.height),this.offscreenCanvasContext=this.offscreenCanvas.getContext("2d",{willReadFrequently:!0})),this.offscreenCanvas.width=ae.width,this.offscreenCanvas.height=ae.height,this.offscreenCanvasContext.drawImage(ae,0,0,ae.width,ae.height);const De=this.offscreenCanvasContext.getImageData(-ue,-ue,ae.width+2*ue,ae.height+2*ue);return this.offscreenCanvasContext.clearRect(0,0,this.offscreenCanvas.width,this.offscreenCanvas.height),De}}function C(Fe,ae){if(Fe.length!==0){A(Fe[0],ae);for(var ue=1;ue<Fe.length;ue++)A(Fe[ue],!ae)}}function A(Fe,ae){for(var ue=0,De=0,qe=0,Xe=Fe.length,ht=Xe-1;qe<Xe;ht=qe++){var ut=(Fe[qe][0]-Fe[ht][0])*(Fe[ht][1]+Fe[qe][1]),Ke=ue+ut;De+=Math.abs(ue)>=Math.abs(ut)?ue-Ke+ut:ut-Ke+ue,ue=Ke}ue+De>=0!=!!ae&&Fe.reverse()}var P=a.getDefaultExportFromCjs(function Fe(ae,ue){var De,qe=ae&&ae.type;if(qe==="FeatureCollection")for(De=0;De<ae.features.length;De++)Fe(ae.features[De],ue);else if(qe==="GeometryCollection")for(De=0;De<ae.geometries.length;De++)Fe(ae.geometries[De],ue);else if(qe==="Feature")Fe(ae.geometry,ue);else if(qe==="Polygon")C(ae.coordinates,ue);else if(qe==="MultiPolygon")for(De=0;De<ae.coordinates.length;De++)C(ae.coordinates[De],ue);return ae});const D=a.VectorTileFeature.prototype.toGeoJSON;var B={exports:{}},R=a.pointGeometry,N=a.vectorTile.VectorTileFeature,j=U;function U(Fe,ae){this.options=ae||{},this.features=Fe,this.length=Fe.length}function W(Fe,ae){this.id=typeof Fe.id=="number"?Fe.id:void 0,this.type=Fe.type,this.rawGeometry=Fe.type===1?[Fe.geometry]:Fe.geometry,this.properties=Fe.tags,this.extent=ae||4096}U.prototype.feature=function(Fe){return new W(this.features[Fe],this.options.extent)},W.prototype.loadGeometry=function(){var Fe=this.rawGeometry;this.geometry=[];for(var ae=0;ae<Fe.length;ae++){for(var ue=Fe[ae],De=[],qe=0;qe<ue.length;qe++)De.push(new R(ue[qe][0],ue[qe][1]));this.geometry.push(De)}return this.geometry},W.prototype.bbox=function(){this.geometry||this.loadGeometry();for(var Fe=this.geometry,ae=1/0,ue=-1/0,De=1/0,qe=-1/0,Xe=0;Xe<Fe.length;Xe++)for(var ht=Fe[Xe],ut=0;ut<ht.length;ut++){var Ke=ht[ut];ae=Math.min(ae,Ke.x),ue=Math.max(ue,Ke.x),De=Math.min(De,Ke.y),qe=Math.max(qe,Ke.y)}return[ae,De,ue,qe]},W.prototype.toGeoJSON=N.prototype.toGeoJSON;var Q=a.pbf,Z=j;function K(Fe){var ae=new Q;return function(ue,De){for(var qe in ue.layers)De.writeMessage(3,Y,ue.layers[qe])}(Fe,ae),ae.finish()}function Y(Fe,ae){var ue;ae.writeVarintField(15,Fe.version||1),ae.writeStringField(1,Fe.name||""),ae.writeVarintField(5,Fe.extent||4096);var De={keys:[],values:[],keycache:{},valuecache:{}};for(ue=0;ue<Fe.length;ue++)De.feature=Fe.feature(ue),ae.writeMessage(2,me,De);var qe=De.keys;for(ue=0;ue<qe.length;ue++)ae.writeStringField(3,qe[ue]);var Xe=De.values;for(ue=0;ue<Xe.length;ue++)ae.writeMessage(4,xe,Xe[ue])}function me(Fe,ae){var ue=Fe.feature;ue.id!==void 0&&ae.writeVarintField(1,ue.id),ae.writeMessage(2,ge,Fe),ae.writeVarintField(3,ue.type),ae.writeMessage(4,ie,ue)}function ge(Fe,ae){var ue=Fe.feature,De=Fe.keys,qe=Fe.values,Xe=Fe.keycache,ht=Fe.valuecache;for(var ut in ue.properties){var Ke=ue.properties[ut],Et=Xe[ut];if(Ke!==null){Et===void 0&&(De.push(ut),Xe[ut]=Et=De.length-1),ae.writeVarint(Et);var en=typeof Ke;en!=="string"&&en!=="boolean"&&en!=="number"&&(Ke=JSON.stringify(Ke));var ln=en+":"+Ke,Kt=ht[ln];Kt===void 0&&(qe.push(Ke),ht[ln]=Kt=qe.length-1),ae.writeVarint(Kt)}}}function ce(Fe,ae){return(ae<<3)+(7&Fe)}function fe(Fe){return Fe<<1^Fe>>31}function ie(Fe,ae){for(var ue=Fe.loadGeometry(),De=Fe.type,qe=0,Xe=0,ht=ue.length,ut=0;ut<ht;ut++){var Ke=ue[ut],Et=1;De===1&&(Et=Ke.length),ae.writeVarint(ce(1,Et));for(var en=De===3?Ke.length-1:Ke.length,ln=0;ln<en;ln++){ln===1&&De!==1&&ae.writeVarint(ce(2,en-1));var Kt=Ke[ln].x-qe,Xn=Ke[ln].y-Xe;ae.writeVarint(fe(Kt)),ae.writeVarint(fe(Xn)),qe+=Kt,Xe+=Xn}De===3&&ae.writeVarint(ce(7,1))}}function xe(Fe,ae){var ue=typeof Fe;ue==="string"?ae.writeStringField(1,Fe):ue==="boolean"?ae.writeBooleanField(7,Fe):ue==="number"&&(Fe%1!=0?ae.writeDoubleField(3,Fe):Fe<0?ae.writeSVarintField(6,Fe):ae.writeVarintField(5,Fe))}B.exports=K,B.exports.fromVectorTileJs=K,B.exports.fromGeojsonVt=function(Fe,ae){ae=ae||{};var ue={};for(var De in Fe)ue[De]=new Z(Fe[De].features,ae),ue[De].name=De,ue[De].version=ae.version,ue[De].extent=ae.extent;return K({layers:ue})},B.exports.GeoJSONWrapper=Z;
vendor: 5,263 bytes, line 120
120var Te=a.getDefaultExportFromCjs(B.exports);const oe={minZoom:0,maxZoom:16,minPoints:2,radius:40,extent:512,nodeSize:64,log:!1,generateId:!1,reduce:null,map:Fe=>Fe},ne=Math.fround||(le=new Float32Array(1),Fe=>(le[0]=+Fe,le[0]));var le;const se=3,Ne=5,Se=6;class xt{constructor(ae){this.options=Object.assign(Object.create(oe),ae),this.trees=new Array(this.options.maxZoom+1),this.stride=this.options.reduce?7:6,this.clusterProps=[]}load(ae){const{log:ue,minZoom:De,maxZoom:qe}=this.options;ue&&console.time("total time");const Xe=`prepare ${ae.length} points`;ue&&console.time(Xe),this.points=ae;const ht=[];for(let Ke=0;Ke<ae.length;Ke++){const Et=ae[Ke];if(!Et.geometry)continue;const[en,ln]=Et.geometry.coordinates,Kt=ne(Ue(en)),Xn=ne(je(ln));ht.push(Kt,Xn,1/0,Ke,-1,1),this.options.reduce&&ht.push(0)}let ut=this.trees[qe+1]=this._createTree(ht);ue&&console.timeEnd(Xe);for(let Ke=qe;Ke>=De;Ke--){const Et=+Date.now();ut=this.trees[Ke]=this._createTree(this._cluster(ut,Ke)),ue&&console.log("z%d: %d clusters in %dms",Ke,ut.numItems,+Date.now()-Et)}return ue&&console.timeEnd("total time"),this}getClusters(ae,ue){let De=((ae[0]+180)%360+360)%360-180;const qe=Math.max(-90,Math.min(90,ae[1]));let Xe=ae[2]===180?180:((ae[2]+180)%360+360)%360-180;const ht=Math.max(-90,Math.min(90,ae[3]));if(ae[2]-ae[0]>=360)De=-180,Xe=180;else if(De>Xe){const ln=this.getClusters([De,qe,180,ht],ue),Kt=this.getClusters([-180,qe,Xe,ht],ue);return ln.concat(Kt)}const ut=this.trees[this._limitZoom(ue)],Ke=ut.range(Ue(De),je(ht),Ue(Xe),je(qe)),Et=ut.data,en=[];for(const ln of Ke){const Kt=this.stride*ln;en.push(Et[Kt+Ne]>1?kt(Et,Kt,this.clusterProps):this.points[Et[Kt+se]])}return en}getChildren(ae){const ue=this._getOriginId(ae),De=this._getOriginZoom(ae),qe="No cluster with the specified id.",Xe=this.trees[De];if(!Xe)throw new Error(qe);const ht=Xe.data;if(ue*this.stride>=ht.length)throw new Error(qe);const ut=this.options.radius/(this.options.extent*Math.pow(2,De-1)),Ke=Xe.within(ht[ue*this.stride],ht[ue*this.stride+1],ut),Et=[];for(const en of Ke){const ln=en*this.stride;ht[ln+4]===ae&&Et.push(ht[ln+Ne]>1?kt(ht,ln,this.clusterProps):this.points[ht[ln+se]])}if(Et.length===0)throw new Error(qe);return Et}getLeaves(ae,ue,De){const qe=[];return this._appendLeaves(qe,ae,ue=ue||10,De=De||0,0),qe}getTile(ae,ue,De){const qe=this.trees[this._limitZoom(ae)],Xe=Math.pow(2,ae),{extent:ht,radius:ut}=this.options,Ke=ut/ht,Et=(De-Ke)/Xe,en=(De+1+Ke)/Xe,ln={features:[]};return this._addTileFeatures(qe.range((ue-Ke)/Xe,Et,(ue+1+Ke)/Xe,en),qe.data,ue,De,Xe,ln),ue===0&&this._addTileFeatures(qe.range(1-Ke/Xe,Et,1,en),qe.data,Xe,De,Xe,ln),ue===Xe-1&&this._addTileFeatures(qe.range(0,Et,Ke/Xe,en),qe.data,-1,De,Xe,ln),ln.features.length?ln:null}getClusterExpansionZoom(ae){let ue=this._getOriginZoom(ae)-1;for(;ue<=this.options.maxZoom;){const De=this.getChildren(ae);if(ue++,De.length!==1)break;ae=De[0].properties.cluster_id}return ue}_appendLeaves(ae,ue,De,qe,Xe){const ht=this.getChildren(ue);for(const ut of ht){const Ke=ut.properties;if(Ke&&Ke.cluster?Xe+Ke.point_count<=qe?Xe+=Ke.point_count:Xe=this._appendLeaves(ae,Ke.cluster_id,De,qe,Xe):Xe<qe?Xe++:ae.push(ut),ae.length===De)break}return Xe}_createTree(ae){const ue=new a.KDBush(ae.length/this.stride|0,this.options.nodeSize,Float32Array);for(let De=0;De<ae.length;De+=this.stride)ue.add(ae[De],ae[De+1]);return ue.finish(),ue.data=ae,ue}_addTileFeatures(ae,ue,De,qe,Xe,ht){for(const ut of ae){const Ke=ut*this.stride,Et=ue[Ke+Ne]>1;let en,ln,Kt;if(Et)en=wt(ue,Ke,this.clusterProps),ln=ue[Ke],Kt=ue[Ke+1];else{const Yn=this.points[ue[Ke+se]];en=Yn.properties;const[or,lr]=Yn.geometry.coordinates;ln=Ue(or),Kt=je(lr)}const Xn={type:1,geometry:[[Math.round(this.options.extent*(ln*Xe-De)),Math.round(this.options.extent*(Kt*Xe-qe))]],tags:en};let jn;jn=Et||this.options.generateId?ue[Ke+se]:this.points[ue[Ke+se]].id,jn!==void 0&&(Xn.id=jn),ht.features.push(Xn)}}_limitZoom(ae){return Math.max(this.options.minZoom,Math.min(Math.floor(+ae),this.options.maxZoom+1))}_cluster(ae,ue){const{radius:De,extent:qe,reduce:Xe,minPoints:ht}=this.options,ut=De/(qe*Math.pow(2,ue)),Ke=ae.data,Et=[],en=this.stride;for(let ln=0;ln<Ke.length;ln+=en){if(Ke[ln+2]<=ue)continue;Ke[ln+2]=ue;const Kt=Ke[ln],Xn=Ke[ln+1],jn=ae.within(Ke[ln],Ke[ln+1],ut),Yn=Ke[ln+Ne];let or=Yn;for(const lr of jn){const Gr=lr*en;Ke[Gr+2]>ue&&(or+=Ke[Gr+Ne])}if(or>Yn&&or>=ht){let lr,Gr=Kt*Yn,Wi=Xn*Yn,po=-1;const $i=((ln/en|0)<<5)+(ue+1)+this.points.length;for(const ws of jn){const Po=ws*en;if(Ke[Po+2]<=ue)continue;Ke[Po+2]=ue;const Hr=Ke[Po+Ne];Gr+=Ke[Po]*Hr,Wi+=Ke[Po+1]*Hr,Ke[Po+4]=$i,Xe&&(lr||(lr=this._map(Ke,ln,!0),po=this.clusterProps.length,this.clusterProps.push(lr)),Xe(lr,this._map(Ke,Po)))}Ke[ln+4]=$i,Et.push(Gr/or,Wi/or,1/0,$i,-1,or),Xe&&Et.push(po)}else{for(let lr=0;lr<en;lr++)Et.push(Ke[ln+lr]);if(or>1)for(const lr of jn){const Gr=lr*en;if(!(Ke[Gr+2]<=ue)){Ke[Gr+2]=ue;for(let Wi=0;Wi<en;Wi++)Et.push(Ke[Gr+Wi])}}}}return Et}_getOriginId(ae){return ae-this.points.length>>5}_getOriginZoom(ae){return(ae-this.points.length)%32}_map(ae,ue,De){if(ae[ue+Ne]>1){const ht=this.clusterProps[ae[ue+Se]];return De?Object.assign({},ht):ht}const qe=this.points[ae[ue+se]].properties,Xe=this.options.map(qe);return De&&Xe===qe?Object.assign({}
120,Xe):Xe}}function kt(Fe,ae,ue){return{type:"Feature",id:Fe[ae+se],properties:wt(Fe,ae,ue),geometry:{type:"Point",coordinates:[(De=Fe[ae],360*(De-.5)),st(Fe[ae+1])]}};var De}function wt(Fe,ae,ue){const De=Fe[ae+Ne],qe=De>=1e4?`${Math.round(De/1e3)}k`:De>=1e3?Math.round(De/100)/10+"k":De,Xe=Fe[ae+Se],ht=Xe===-1?{}:Object.assign({},ue[Xe]);return Object.assign(ht,{cluster:!0,cluster_id:Fe[ae+se],point_count:De,point_count_abbreviated:qe})}function Ue(Fe){return Fe/360+.5}function je(Fe){const ae=Math.sin(Fe*Math.PI/180),ue=.5-.25*Math.log((1+ae)/(1-ae))/Math.PI;return ue<0?0:ue>1?1:ue}function st(Fe){const ae=(180-360*Fe)*Math.PI/180;return 360*Math.atan(Math.exp(ae))/Math.PI-90}function tt(Fe,ae,ue,De){for(var qe,Xe=De,ht=ue-ae>>1,ut=ue-ae,Ke=Fe[ae],Et=Fe[ae+1],en=Fe[ue],ln=Fe[ue+1],Kt=ae+3;Kt<ue;Kt+=3){var Xn=Me(Fe[Kt],Fe[Kt+1],Ke,Et,en,ln);if(Xn>Xe)qe=Kt,Xe=Xn;else if(Xn===Xe){var jn=Math.abs(Kt-ht);jn<ut&&(qe=Kt,ut=jn)}}Xe>De&&(qe-ae>3&&tt(Fe,ae,qe,De),Fe[qe+2]=Xe,ue-qe>3&&tt(Fe,qe,ue,De))}function Me(Fe,ae,ue,De,qe,Xe){var ht=qe-ue,ut=Xe-De;if(ht!==0||ut!==0){var Ke=((Fe-ue)*ht+(ae-De)*ut)/(ht*ht+ut*ut);Ke>1?(ue=qe,De=Xe):Ke>0&&(ue+=ht*Ke,De+=ut*Ke)}return(ht=Fe-ue)*ht+(ut=ae-De)*ut}function lt(Fe,ae,ue,De){var qe={id:Fe===void 0?null:Fe,type:ae,geometry:ue,tags:De,minX:1/0,minY:1/0,maxX:-1/0,maxY:-1/0};return function(Xe){var ht=Xe.geometry,ut=Xe.type;if(ut==="Point"||ut==="MultiPoint"||ut==="LineString")Ae(Xe,ht);else if(ut==="Polygon"||ut==="MultiLineString")for(var Ke=0;Ke<ht.length;Ke++)Ae(Xe,ht[Ke]);else if(ut==="MultiPolygon")for(Ke=0;Ke<ht.length;Ke++)for(var Et=0;Et<ht[Ke].length;Et++)Ae(Xe,ht[Ke][Et])}(qe),qe}function Ae(Fe,ae){for(var ue=0;ue<ae.length;ue+=3)Fe.minX=Math.min(Fe.minX,ae[ue]),Fe.minY=Math.min(Fe.minY,ae[ue+1]),Fe.maxX=Math.max(Fe.maxX,ae[ue]),Fe.maxY=Math.max(Fe.maxY,ae[ue+1])}function we(Fe,ae,ue,De){if(ae.geometry){var qe=ae.geometry.coordinates,Xe=ae.geometry.type,ht=Math.pow(ue.tolerance/((1<<ue.maxZoom)*ue.extent),2),ut=[],Ke=ae.id;if(ue.promoteId?Ke=ae.properties[ue.promoteId]:ue.generateId&&(Ke=De||0),Xe==="Point")Je(qe,ut);else if(Xe==="MultiPoint")for(var Et=0;Et<qe.length;Et++)Je(qe[Et],ut);else if(Xe==="LineString")ct(qe,ut,ht,!1);else if(Xe==="MultiLineString"){if(ue.lineMetrics){for(Et=0;Et<qe.length;Et++)ct(qe[Et],ut=[],ht,!1),Fe.push(lt(Ke,"LineString",ut,ae.properties));return}mt(qe,ut,ht,!1)}else if(Xe==="Polygon")mt(qe,ut,ht,!0);else{if(Xe!=="MultiPolygon"){if(Xe==="GeometryCollection"){for(Et=0;Et<ae.geometry.geometries.length;Et++)we(Fe,{id:Ke,geometry:ae.geometry.geometries[Et],properties:ae.properties},ue,De);return}throw new Error("Input data is not a valid GeoJSON object.")}for(Et=0;Et<qe.length;Et++){var en=[];mt(qe[Et],en,ht,!0),ut.push(en)}}Fe.push(lt(Ke,Xe,ut,ae.properties))}}function Je(Fe,ae){ae.push(Vt(Fe[0])),ae.push(Ie(Fe[1])),ae.push(0)}function ct(Fe,ae,ue,De){for(var qe,Xe,ht=0,ut=0;ut<Fe.length;ut++){var Ke=Vt(Fe[ut][0]),Et=Ie(Fe[ut][1]);ae.push(Ke),ae.push(Et),ae.push(0),ut>0&&(ht+=De?(qe*Et-Ke*Xe)/2:Math.sqrt(Math.pow(Ke-qe,2)+Math.pow(Et-Xe,2))),qe=Ke,Xe=Et}var en=ae.length-3;ae[2]=1,tt(ae,0,en,ue),ae[en+2]=1,ae.size=Math.abs(ht),ae.start=0,ae.end=ae.size}function mt(Fe,ae,ue,De){for(var qe=0;qe<Fe.length;qe++){var Xe=[];ct(Fe[qe],Xe,ue,De),ae.push(Xe)}}function Vt(Fe){return Fe/360+.5}function Ie(Fe){var ae=Math.sin(Fe*Math.PI/180),ue=.5-.25*Math.log((1+ae)/(1-ae))/Math.PI;return ue<0?0:ue>1?1:ue}function Pe(Fe,ae,ue,De,qe,Xe,ht,ut){if(De/=ae,Xe>=(ue/=ae)&&ht<De)return Fe;if(ht<ue||Xe>=De)return null;for(var Ke=[],Et=0;Et<Fe.length;Et++){var en=Fe[Et],ln=en.geometry,Kt=en.type,Xn=qe===0?en.minX:en.minY,jn=qe===0?en.maxX:en.maxY;if(Xn>=ue&&jn<De)Ke.push(en);else if(!(jn<ue||Xn>=De)){var Yn=[];if(Kt==="Point"||Kt==="MultiPoint")rt(ln,Yn,ue,De,qe);else if(Kt==="LineString")Tt(ln,Yn,ue,De,qe,!1,ut.lineMetrics);else if(Kt==="MultiLineString")qt(ln,Yn,ue,De,qe,!1);else if(Kt==="Polygon")qt(ln,Yn,ue,De,qe,!0);else if(Kt==="MultiPolygon")for(var or=0;or<ln.length;or++){var lr=[];qt(ln[or],lr,ue,De,qe,!0),lr.length&&Yn.push(lr)}if(Yn.length){if(ut.lineMetrics&&Kt==="LineString"){for(or=0;or<Yn.length;
vendor: 5,120 bytes, line 120
120or++)Ke.push(lt(en.id,Kt,Yn[or],en.tags));continue}Kt!=="LineString"&&Kt!=="MultiLineString"||(Yn.length===1?(Kt="LineString",Yn=Yn[0]):Kt="MultiLineString"),Kt!=="Point"&&Kt!=="MultiPoint"||(Kt=Yn.length===3?"Point":"MultiPoint"),Ke.push(lt(en.id,Kt,Yn,en.tags))}}}return Ke.length?Ke:null}function rt(Fe,ae,ue,De,qe){for(var Xe=0;Xe<Fe.length;Xe+=3){var ht=Fe[Xe+qe];ht>=ue&&ht<=De&&(ae.push(Fe[Xe]),ae.push(Fe[Xe+1]),ae.push(Fe[Xe+2]))}}function Tt(Fe,ae,ue,De,qe,Xe,ht){for(var ut,Ke,Et=pn(Fe),en=qe===0?It:$t,ln=Fe.start,Kt=0;Kt<Fe.length-3;Kt+=3){var Xn=Fe[Kt],jn=Fe[Kt+1],Yn=Fe[Kt+2],or=Fe[Kt+3],lr=Fe[Kt+4],Gr=qe===0?Xn:jn,Wi=qe===0?or:lr,po=!1;ht&&(ut=Math.sqrt(Math.pow(Xn-or,2)+Math.pow(jn-lr,2))),Gr<ue?Wi>ue&&(Ke=en(Et,Xn,jn,or,lr,ue),ht&&(Et.start=ln+ut*Ke)):Gr>De?Wi<De&&(Ke=en(Et,Xn,jn,or,lr,De),ht&&(Et.start=ln+ut*Ke)):nt(Et,Xn,jn,Yn),Wi<ue&&Gr>=ue&&(Ke=en(Et,Xn,jn,or,lr,ue),po=!0),Wi>De&&Gr<=De&&(Ke=en(Et,Xn,jn,or,lr,De),po=!0),!Xe&&po&&(ht&&(Et.end=ln+ut*Ke),ae.push(Et),Et=pn(Fe)),ht&&(ln+=ut)}var $i=Fe.length-3;Xn=Fe[$i],jn=Fe[$i+1],Yn=Fe[$i+2],(Gr=qe===0?Xn:jn)>=ue&&Gr<=De&&nt(Et,Xn,jn,Yn),$i=Et.length-3,Xe&&$i>=3&&(Et[$i]!==Et[0]||Et[$i+1]!==Et[1])&&nt(Et,Et[0],Et[1],Et[2]),Et.length&&ae.push(Et)}function pn(Fe){var ae=[];return ae.size=Fe.size,ae.start=Fe.start,ae.end=Fe.end,ae}function qt(Fe,ae,ue,De,qe,Xe){for(var ht=0;ht<Fe.length;ht++)Tt(Fe[ht],ae,ue,De,qe,Xe,!1)}function nt(Fe,ae,ue,De){Fe.push(ae),Fe.push(ue),Fe.push(De)}function It(Fe,ae,ue,De,qe,Xe){var ht=(Xe-ae)/(De-ae);return Fe.push(Xe),Fe.push(ue+(qe-ue)*ht),Fe.push(1),ht}function $t(Fe,ae,ue,De,qe,Xe){var ht=(Xe-ue)/(qe-ue);return Fe.push(ae+(De-ae)*ht),Fe.push(Xe),Fe.push(1),ht}function $e(Fe,ae){for(var ue=[],De=0;De<Fe.length;De++){var qe,Xe=Fe[De],ht=Xe.type;if(ht==="Point"||ht==="MultiPoint"||ht==="LineString")qe=pt(Xe.geometry,ae);else if(ht==="MultiLineString"||ht==="Polygon"){qe=[];for(var ut=0;ut<Xe.geometry.length;ut++)qe.push(pt(Xe.geometry[ut],ae))}else if(ht==="MultiPolygon")for(qe=[],ut=0;ut<Xe.geometry.length;ut++){for(var Ke=[],Et=0;Et<Xe.geometry[ut].length;Et++)Ke.push(pt(Xe.geometry[ut][Et],ae));qe.push(Ke)}ue.push(lt(Xe.id,ht,qe,Xe.tags))}return ue}function pt(Fe,ae){var ue=[];ue.size=Fe.size,Fe.start!==void 0&&(ue.start=Fe.start,ue.end=Fe.end);for(var De=0;De<Fe.length;De+=3)ue.push(Fe[De]+ae,Fe[De+1],Fe[De+2]);return ue}function gn(Fe,ae){if(Fe.transformed)return Fe;var ue,De,qe,Xe=1<<Fe.z,ht=Fe.x,ut=Fe.y;for(ue=0;ue<Fe.features.length;ue++){var Ke=Fe.features[ue],Et=Ke.geometry,en=Ke.type;if(Ke.geometry=[],en===1)for(De=0;De<Et.length;De+=2)Ke.geometry.push(Pn(Et[De],Et[De+1],ae,Xe,ht,ut));else for(De=0;De<Et.length;De++){var ln=[];for(qe=0;qe<Et[De].length;qe+=2)ln.push(Pn(Et[De][qe],Et[De][qe+1],ae,Xe,ht,ut));Ke.geometry.push(ln)}}return Fe.transformed=!0,Fe}function Pn(Fe,ae,ue,De,qe,Xe){return[Math.round(ue*(Fe*De-qe)),Math.round(ue*(ae*De-Xe))]}function gr(Fe,ae,ue,De,qe){for(var Xe=ae===qe.maxZoom?0:qe.tolerance/((1<<ae)*qe.extent),ht={features:[],numPoints:0,numSimplified:0,numFeatures:0,source:null,x:ue,y:De,z:ae,transformed:!1,minX:2,minY:1,maxX:-1,maxY:0},ut=0;ut<Fe.length;ut++){ht.numFeatures++,Ji(ht,Fe[ut],Xe,qe);var Ke=Fe[ut].minX,Et=Fe[ut].minY,en=Fe[ut].maxX,ln=Fe[ut].maxY;Ke<ht.minX&&(ht.minX=Ke),Et<ht.minY&&(ht.minY=Et),en>ht.maxX&&(ht.maxX=en),ln>ht.maxY&&(ht.maxY=ln)}return ht}function Ji(Fe,ae,ue,De){var qe=ae.geometry,Xe=ae.type,ht=[];if(Xe==="Point"||Xe==="MultiPoint")for(var ut=0;ut<qe.length;ut+=3)ht.push(qe[ut]),ht.push(qe[ut+1]),Fe.numPoints++,Fe.numSimplified++;else if(Xe==="LineString")Ni(ht,qe,Fe,ue,!1,!1);else if(Xe==="MultiLineString"||Xe==="Polygon")for(ut=0;ut<qe.length;ut++)Ni(ht,qe[ut],Fe,ue,Xe==="Polygon",ut===0);else if(Xe==="MultiPolygon")for(var Ke=0;Ke<qe.length;Ke++){var Et=qe[Ke];for(ut=0;ut<Et.length;ut++)Ni(ht,Et[ut],Fe,ue,!0,ut===0)}if(ht.length){var en=ae.tags||null;if(Xe==="LineString"&&De.lineMetrics){for(var ln in en={},ae.tags)en[ln]=ae.tags[ln];en.mapbox_clip_start=qe.start/qe.size,en.mapbox_clip_end=qe.end/qe.size}var Kt={geometry:ht,type:Xe==="Polygon"||Xe==="MultiPolygon"?3:Xe==="LineString"||Xe==="MultiLineString"?2:1,tags:en};ae.id!==null&&(Kt.id=ae.id),Fe.features.push(Kt)}}function Ni(Fe,ae,ue,De,qe,Xe){var ht=De*De;if(De>0&&ae.size<(qe?ht:De))ue.numPoints+=ae.length/3;else{for(var ut=[],Ke=0;Ke<ae.length;Ke+=3)(De===0||ae[Ke+2]>ht)&&(ue.numSimplified++,ut.push(ae[Ke]),ut.push(ae[Ke+1])),ue.numPoints++;qe&&function(Et,en){for(var ln=0,Kt=0,Xn=Et.length,jn=Xn-2;Kt<Xn;jn=Kt,Kt+=2)ln+=(Et[Kt]-Et[jn])*(Et[Kt+1]+Et[jn+1]);if(ln>0===en)for(Kt=0,Xn=Et.length;Kt<Xn/2;Kt+=2){var Yn=Et[Kt],or=Et[Kt+1];Et[Kt]=Et[Xn-2-Kt],Et[Kt+1]=Et[Xn-1-Kt],Et[Xn-2-Kt]=Yn,Et[Xn-1-Kt]=or}}(ut,Xe),Fe.push(ut)}}function Bo(Fe,ae){var ue=(ae=this.options=function(qe,Xe){for(var ht in Xe)qe[ht]=Xe[ht];return qe}(Object.create(this.options),ae)).debug;if(ue&&console.time("preprocess data"),ae.maxZoom<0||ae.maxZoom>24)throw new Error("maxZoom should be in the 0-24 range");if(ae.promoteId&&ae.generateId)throw new Error("promoteId and generateId cannot be used together.");var De=function(qe,Xe){var ht=[];
120if(qe.type==="FeatureCollection")for(var ut=0;ut<qe.features.length;ut++)we(ht,qe.features[ut],Xe,ut);else we(ht,qe.type==="Feature"?qe:{geometry:qe},Xe);return ht}(Fe,ae);this.tiles={},this.tileCoords=[],ue&&(console.timeEnd("preprocess data"),console.log("index: maxZoom: %d, maxPoints: %d",ae.indexMaxZoom,ae.indexMaxPoints),console.time("generate tiles"),this.stats={},this.total=0),De=function(qe,Xe){var ht=Xe.buffer/Xe.extent,ut=qe,Ke=Pe(qe,1,-1-ht,ht,0,-1,2,Xe),Et=Pe(qe,1,1-ht,2+ht,0,-1,2,Xe);return(Ke||Et)&&(ut=Pe(qe,1,-ht,1+ht,0,-1,2,Xe)||[],Ke&&(ut=$e(Ke,1).concat(ut)),Et&&(ut=ut.concat($e(Et,-1)))),ut}(De,ae),De.length&&this.splitTile(De,0,0,0),ue&&(De.length&&console.log("features: %d, points: %d",this.tiles[0].numFeatures,this.tiles[0].numPoints),console.timeEnd("generate tiles"),console.log("tiles generated:",this.total,JSON.stringify(this.stats)))}function _i(Fe,ae,ue){return 32*((1<<Fe)*ue+ae)+Fe}function Wr(Fe,ae){const ue=Fe.tileID.canonical;if(!this._geoJSONIndex)return ae(null,null);const De=this._geoJSONIndex.getTile(ue.z,ue.x,ue.y);if(!De)return ae(null,null);const qe=new class{constructor(ht){this.layers={_geojsonTileLayer:this},this.name="_geojsonTileLayer",this.extent=a.EXTENT,this.length=ht.length,this._features=ht}feature(ht){return new class{constructor(ut){this._feature=ut,this.extent=a.EXTENT,this.type=ut.type,this.properties=ut.tags,"id"in ut&&!isNaN(ut.id)&&(this.id=parseInt(ut.id,10))}loadGeometry(){if(this._feature.type===1){const ut=[];for(const Ke of this._feature.geometry)ut.push([new a.Point(Ke[0],Ke[1])]);return ut}{const ut=[];for(const Ke of this._feature.geometry){const Et=[];for(const en of Ke)Et.push(new a.Point(en[0],en[1]));ut.push(Et)}return ut}}toGeoJSON(ut,Ke,Et){return D.call(this,ut,Ke,Et)}}(this._features[ht])}}(De.features);let Xe=Te(qe);Xe.byteOffset===0&&Xe.byteLength===Xe.buffer.byteLength||(Xe=new Uint8Array(Xe)),ae(null,{vectorTile:qe,rawData:Xe.buffer})}Bo.prototype.options={maxZoom:14,indexMaxZoom:5,indexMaxPoints:1e5,tolerance:3,extent:4096,buffer:64,lineMetrics:!1,promoteId:null,generateId:!1,debug:0},Bo.prototype.splitTile=function(Fe,ae,ue,De,qe,Xe,ht){for(var ut=[Fe,ae,ue,De],Ke=this.options,Et=Ke.debug;ut.length;){De=ut.pop(),ue=ut.pop(),ae=ut.pop(),Fe=ut.pop();var en=1<<ae,ln=_i(ae,ue,De),Kt=this.tiles[ln];if(!Kt&&(Et>1&&console.time("creation"),Kt=this.tiles[ln]=gr(Fe,ae,ue,De,Ke),this.tileCoords.push({z:ae,x:ue,y:De}),Et)){Et>1&&(console.log("tile z%d-%d-%d (features: %d, points: %d, simplified: %d)",ae,ue,De,Kt.numFeatures,Kt.numPoints,Kt.numSimplified),console.timeEnd("creation"));var Xn="z"+ae;this.stats[Xn]=(this.stats[Xn]||0)+1,this.total++}if(Kt.source=Fe,qe){if(ae===Ke.maxZoom||ae===qe)continue;var jn=1<<qe-ae;if(ue!==Math.floor(Xe/jn)||De!==Math.floor(ht/jn))continue}else if(ae===Ke.indexMaxZoom||Kt.numPoints<=Ke.indexMaxPoints)continue;if(Kt.source=null,Fe.length!==0){Et>1&&console.time("clipping");var Yn,or,lr,Gr,Wi,po,$i=.5*Ke.buffer/Ke.extent,ws=.5-$i,Po=.5+$i,Hr=1+$i;Yn=or=lr=Gr=null,Wi=Pe(Fe,en,ue-$i,ue+Po,0,Kt.minX,Kt.maxX,Ke),po=Pe(Fe,en,ue+ws,ue+Hr,0,Kt.minX,Kt.maxX,Ke),Fe=null,Wi&&(Yn=Pe(Wi,en,De-$i,De+Po,1,Kt.minY,Kt.maxY,Ke),or=Pe(Wi,en,De+ws,De+Hr,1,Kt.minY,Kt.maxY,Ke),Wi=null),po&&(lr=Pe(po,en,De-$i,De+Po,1,Kt.minY,Kt.maxY,Ke),Gr=Pe(po,en,De+ws,De+Hr,1,Kt.minY,Kt.maxY,Ke),po=null),Et>1&&console.timeEnd("clipping"),ut.push(Yn||[],ae+1,2*ue,2*De),ut.push(or||[],ae+1,2*ue,2*De+1),ut.push(lr||[],ae+1,2*ue+1,2*De),ut.push(Gr||[],ae+1,2*ue+1,2*De+1)}}},Bo.prototype.getTile=function(Fe,ae,ue){var De=this.options,qe=De.extent,Xe=De.debug;if(Fe<0||Fe>24)return null;var ht=1<<Fe,ut=_i(Fe,ae=(ae%ht+ht)%ht,ue);if(this.tiles[ut])return gn(this.tiles[ut],qe);Xe>1&&console.log("drilling down to z%d-%d-%d",Fe,ae,ue);for(var Ke,Et=Fe,en=ae,ln=ue;!Ke&&Et>0;)Et--,en=Math.floor(en/2),ln=Math.floor(ln/2),Ke=this.tiles[_i(Et,en,ln)];return Ke&&Ke.source?(Xe>1&&console.log("found parent tile z%d-%d-%d",Et,en,ln),Xe>1&&console.time("drilling down"),this.splitTile(Ke.source,Et,en,ln,Fe,ae,ue),Xe>1&&console.timeEnd("drilling down"),this.tiles[ut]?gn(this.tiles[ut],qe):null):null};class Ao extends a.VectorTileWorkerSource{constructor(ae,ue,De,qe,Xe){super(ae,ue,De,qe,Wr),Xe&&(this.loadGeoJSON=Xe)}loadData(ae,ue){const De=ae&&ae.request,qe=De&&De.collectResourceTiming;this.loadGeoJSON(ae,(Xe,ht)=>{if(Xe||!ht)return ue(Xe);if(typeof ht!="object")return ue(new Error(`Input data given to '${ae.source}' is not a valid GeoJSON object.`));{P(ht,!0);try{if(ae.filter){const Ke=a.createExpression(ae.filter,{type:"boolean","property-type":"data-driven",overridable:!1,transition:!1});if(Ke.result==="error")throw new Error(Ke.value.map(en=>`${en.key}: ${en.message}`).join(", "));ht={type:"FeatureCollection",features:ht.features.filter(en=>Ke.value.evaluate({zoom:0}
120,en))}}this._geoJSONIndex=ae.cluster?new xt(function({superclusterOptions:Ke,clusterProperties:Et}){if(!Et||!Ke)return Ke;const en={},ln={},Kt={accumulated:null,zoom:0},Xn={properties:null},jn=Object.keys(Et);for(const Yn of jn){const[or,lr]=Et[Yn],Gr=a.createExpression(lr),Wi=a.createExpression(typeof or=="string"?[or,["accumulated"],["get",Yn]]:or);en[Yn]=Gr.value,ln[Yn]=Wi.value}return Ke.map=Yn=>{Xn.properties=Yn;const or={};for(const lr of jn)or[lr]=en[lr].evaluate(Kt,Xn);return or},Ke.reduce=(Yn,or)=>{Xn.properties=or;for(const lr of jn)Kt.accumulated=Yn[lr],Yn[lr]=ln[lr].evaluate(Kt,Xn)},Ke}(ae)).load(ht.features):function(Ke,Et){return new Bo(Ke,Et)}(ht,ae.geojsonVtOptions)}catch(Ke){return ue(Ke)}this.loaded={};const ut={};if(qe){const Ke=a.getPerformanceMeasurement(De);Ke&&(ut.resourceTiming={},ut.resourceTiming[ae.source]=JSON.parse(JSON.stringify(Ke)))}ue(null,ut)}})}reloadTile(ae,ue){const De=this.loaded;return De&&De[ae.uid]?super.reloadTile(ae,ue):this.loadTile(ae,ue)}loadGeoJSON(ae,ue){if(ae.request)a.getJSON(ae.request,ue);else{if(typeof ae.data!="string")return ue(new Error(`Input data given to '${ae.source}' is not a valid GeoJSON object.`));try{return ue(null,JSON.parse(ae.data))}catch{return ue(new Error(`Input data given to '${ae.source}' is not a valid GeoJSON object.`))}}}getClusterExpansionZoom(ae,ue){try{ue(null,this._geoJSONIndex.getClusterExpansionZoom(ae.clusterId))}catch(De){ue(De)}}getClusterChildren(ae,ue){try{ue(null,this._geoJSONIndex.getChildren(ae.clusterId))}catch(De){ue(De)}}getClusterLeaves(ae,ue){try{ue(null,this._geoJSONIndex.getLeaves(ae.clusterId,ae.limit,ae.offset))}catch(De){ue(De)}}}class xs{constructor(ae){this.self=ae,this.actor=new a.Actor(ae,this),this.layerIndexes={},this.availableImages={},this.isSpriteLoaded={},this.projections={},this.defaultProjection=a.getProjection({name:"mercator"}),this.workerSourceTypes={vector:a.VectorTileWorkerSource,geojson:Ao},this.workerSources={},this.demWorkerSources={},this.self.registerWorkerSource=(ue,De)=>{if(this.workerSourceTypes[ue])throw new Error(`Worker source with name "${ue}" already registered.`);this.workerSourceTypes[ue]=De},this.self.registerRTLTextPlugin=ue=>{if(a.plugin.isParsed())throw new Error("RTL text plugin already registered.");a.plugin.applyArabicShaping=ue.applyArabicShaping,a.plugin.processBidirectionalText=ue.processBidirectionalText,a.plugin.processStyledBidirectionalText=ue.processStyledBidirectionalText}}clearCaches(ae,ue,De){delete this.layerIndexes[ae],delete this.availableImages[ae],delete this.workerSources[ae],delete this.demWorkerSources[ae],De()}checkIfReady(ae,ue,De){De()}setReferrer(ae,ue){this.referrer=ue}spriteLoaded(ae,ue){this.isSpriteLoaded[ae]=ue;for(const De in this.workerSources[ae]){const qe=this.workerSources[ae][De];for(const Xe in qe)qe[Xe]instanceof a.VectorTileWorkerSource&&(qe[Xe].isSpriteLoaded=ue,qe[Xe].fire(new a.Event("isSpriteLoaded")))}}setImages(ae,ue,De){this.availableImages[ae]=ue;for(const qe in this.workerSources[ae]){const Xe=this.workerSources[ae][qe];for(const ht in Xe)Xe[ht].availableImages=ue}De()}enableTerrain(ae,ue,De){this.terrain=ue,De()}setProjection(ae,ue){this.projections[ae]=a.getProjection(ue)}setLayers(ae,ue,De){this.getLayerIndex(ae).replace(ue),De()}updateLayers(ae,ue,De){this.getLayerIndex(ae).update(ue.layers,ue.removedIds),De()}loadTile(ae,ue,De){const qe=this.enableTerrain?a.extend({enableTerrain:this.terrain},ue):ue;qe.projection=this.projections[ae]||this.defaultProjection,this.getWorkerSource(ae,ue.type,ue.source).loadTile(qe,De)}loadDEMTile(ae,ue,De){const qe=this.enableTerrain?a.extend({buildQuadTree:this.terrain},ue):ue;this.getDEMWorkerSource(ae,ue.source).loadTile(qe,De)}reloadTile(ae,ue,De){const qe=this.enableTerrain?a.extend({enableTerrain:this.terrain},ue):ue;qe.projection=this.projections[ae]||this.defaultProjection,this.getWorkerSource(ae,ue.type,ue.source).reloadTile(qe,De)}abortTile(ae,ue,De){this.getWorkerSource(ae,ue.type,ue.source).abortTile(ue,De)}removeTile(ae,ue,De){this.getWorkerSource(ae,ue.type,ue.source).removeTile(ue,De)}removeSource(ae,ue,De){if(!this.workerSources[ae]||!this.workerSources[ae][ue.type]||!this.workerSources[ae][ue.type][ue.source])return;const qe=this.workerSources[ae][ue.type][ue.source];delete this.workerSources[ae][ue.type][ue.source],qe.removeSource!==void 0?qe.removeSource(ue,De):De()}loadWorkerSource(ae,ue,De){try{this.self.importScripts(ue.url),De()}catch(qe){De(qe.toString())}}syncRTLPluginState(ae,ue,De){try{a.plugin.setState(ue);const qe=a.plugin.getPluginURL();if(a.plugin.isLoaded()&&!a.plugin.isParsed()&&qe!=null){this.self.importScripts(qe);const Xe=a.plugin.isParsed();De(Xe?void 0:new Error(`RTL Text Plugin failed to import scripts from ${qe}`),Xe)}}catch(qe){De(qe.toString())}}getAvailableImages(ae){let ue=this.availableImages[ae];return ue||(ue=[]),ue}getLayerIndex(ae){let ue=this.layerIndexes[ae];return ue||(ue=this.layerIndexes[ae]=new x),ue}getWorkerSource(ae,ue,De){if(this.workerSources[ae]||(this.workerSources[ae]={}),this.workerSources[ae][ue]||(this.workerSources[ae][ue]={}),!this.workerSources[ae][ue][De]){const qe={send:(Xe,ht,ut,Ke,Et,en)=>{this.actor.send(Xe,ht,ut,ae,Et,en)},scheduler:this.actor.scheduler};this.workerSources[ae][ue][De]=new this.workerSourceTypes[ue](qe,this.getLayerIndex(ae),this.getAvailableImages(ae),this.isSpriteLoaded[ae])}return this.workerSources[ae][ue][De]}
120getDEMWorkerSource(ae,ue){return this.demWorkerSources[ae]||(this.demWorkerSources[ae]={}),this.demWorkerSources[ae][ue]||(this.demWorkerSources[ae][ue]=new T),this.demWorkerSources[ae][ue]}enforceCacheSizeLimit(ae,ue){a.enforceCacheSizeLimit(ue)}getWorkerPerformanceMetrics(ae,ue,De){De(void 0,void 0)}}return typeof WorkerGlobalScope<"u"&&typeof self<"u"&&self instanceof WorkerGlobalScope&&(self.worker=new xs(self)),xs}),s(["./shared"],function(a){function m(y,h){if(Array.isArray(y)){if(!Array.isArray(h)||y.length!==h.length)return!1;for(let f=0;f<y.length;f++)if(!m(y[f],h[f]))return!1;return!0}if(typeof y=="object"&&y!==null&&h!==null){if(typeof h!="object"||Object.keys(y).length!==Object.keys(h).length)return!1;for(const f in y)if(!m(y[f],h[f]))return!1;return!0}return y===h}var g=x;function x(y){return!function(h){return typeof window>"u"||typeof document>"u"?"not a browser":Array.prototype&&Array.prototype.every&&Array.prototype.filter&&Array.prototype.forEach&&Array.prototype.indexOf&&Array.prototype.lastIndexOf&&Array.prototype.map&&Array.prototype.some&&Array.prototype.reduce&&Array.prototype.reduceRight&&Array.isArray?Function.prototype&&Function.prototype.bind?Object.keys&&Object.create&&Object.getPrototypeOf&&Object.getOwnPropertyNames&&Object.isSealed&&Object.isFrozen&&Object.isExtensible&&Object.getOwnPropertyDescriptor&&Object.defineProperty&&Object.defineProperties&&Object.seal&&Object.freeze&&Object.preventExtensions?"JSON"in window&&"parse"in JSON&&"stringify"in JSON?function(){if(!("Worker"in window&&"Blob"in window&&"URL"in window))return!1;var v,w,S=new Blob([""],{type:"text/javascript"}),I=URL.createObjectURL(S);try{w=new Worker(I),v=!0}catch{v=!1}return w&&w.terminate(),URL.revokeObjectURL(I),v}()?"Uint8ClampedArray"in window?ArrayBuffer.isView?function(){var v=document.createElement("canvas");v.width=v.height=1;var w=v.getContext("2d");if(!w)return!1;var S=w.getImageData(0,0,1,1);return S&&S.width===v.width}()?(T[f=h&&h.failIfMajorPerformanceCaveat]===void 0&&(T[f]=function(v){var w,S=function(I){var L=document.createElement("canvas"),z=Object.create(x.webGLContextAttributes);return z.failIfMajorPerformanceCaveat=I,L.getContext("webgl",z)||L.getContext("experimental-webgl",z)}(v);if(!S)return!1;try{w=S.createShader(S.VERTEX_SHADER)}catch{return!1}return!(!w||S.isContextLost())&&(S.shaderSource(w,"void main() {}"),S.compileShader(w),S.getShaderParameter(w,S.COMPILE_STATUS)===!0)}(f)),T[f]?document.documentMode?"insufficient ECMAScript 6 support":void 0:"insufficient WebGL support"):"insufficient Canvas/getImageData support":"insufficient ArrayBuffer support":"insufficient Uint8ClampedArray support":"insufficient worker support":"insufficient JSON support":"insufficient Object support":"insufficient Function support":"insufficent Array support";var f}(y)}var T={};function C(y,h,f){const v=a.window.document.createElement(y);return h!==void 0&&(v.className=h),f&&f.appendChild(v),v}function A(y,h,f){const v=a.window.document.createElementNS("http://www.w3.org/2000/svg",y);for(const w of Object.keys(h))v.setAttributeNS(null,w,h[w]);return f&&f.appendChild(v),v}x.webGLContextAttributes={antialias:!1,alpha:!0,stencil:!0,depth:!0};const P=a.window.document&&a.window.document.documentElement.style,D=P&&P.userSelect!==void 0?"userSelect":"WebkitUserSelect";let B;function R(){P&&D&&(B=P[D],P[D]="none")}function N(){P&&D&&(P[D]=B)}function j(y){y.preventDefault(),y.stopPropagation(),a.window.removeEventListener("click",j,!0)}function U(){a.window.addEventListener("click",j,!0),a.window.setTimeout(()=>{a.window.removeEventListener("click",j,!0)},0)}function W(y,h){const f=y.getBoundingClientRect();return K(y,f,h)}function Q(y,h){const f=y.getBoundingClientRect(),v=[];for(let w=0;w<h.length;w++)v.push(K(y,f,h[w]));return v}function Z(y){return a.window.InstallTrigger!==void 0&&y.button===2&&y.ctrlKey&&a.window.navigator.platform.toUpperCase().indexOf("MAC")>=0?0:y.button}function K(y,h,f){const v=y.offsetWidth===h.width?1:y.offsetWidth/h.width;return new a.Point((f.clientX-h.left)*v,(f.clientY-h.top)*v)}function Y(y,h){var f=h[0],v=h[1],w=h[2],S=h[3],I=f*S-w*v;return I?(y[0]=S*(I=1/I),y[1]=-v*I,y[2]=-w*I,y[3]=f*I,y):null}function me(y){const{userImage:h}=y;return!!(h&&h.render&&h.render())&&(y.data.replace(new Uint8Array(h.data.buffer)),!0)}class ge extends a.Evented{constructor(){super(),this.images={},this.updatedImages={},this.callbackDispatchedThisFrame={},this.loaded=!1,this.requestors=[],this.patterns={},this.atlasImage=new a.RGBAImage({width:1,height:1}),this.dirty=!0}isLoaded(){return this.loaded}setLoaded(h){if(this.loaded!==h&&(this.loaded=h,h)){for(const{ids:f,callback:v}of this.requestors)this._notify(f,v);this.requestors=[]}}hasImage(h){return!!this.getImage(h)}getImage(h){return this.images[h]}
vendor: 4,238 bytes, line 120
120addImage(h,f){this._validate(h,f)&&(this.images[h]=f)}_validate(h,f){let v=!0;return this._validateStretch(f.stretchX,f.data&&f.data.width)||(this.fire(new a.ErrorEvent(new Error(`Image "${h}" has invalid "stretchX" value`))),v=!1),this._validateStretch(f.stretchY,f.data&&f.data.height)||(this.fire(new a.ErrorEvent(new Error(`Image "${h}" has invalid "stretchY" value`))),v=!1),this._validateContent(f.content,f)||(this.fire(new a.ErrorEvent(new Error(`Image "${h}" has invalid "content" value`))),v=!1),v}_validateStretch(h,f){if(!h)return!0;let v=0;for(const w of h){if(w[0]<v||w[1]<w[0]||f<w[1])return!1;v=w[1]}return!0}_validateContent(h,f){return!(h&&(h.length!==4||h[0]<0||f.data.width<h[0]||h[1]<0||f.data.height<h[1]||h[2]<0||f.data.width<h[2]||h[3]<0||f.data.height<h[3]||h[2]<h[0]||h[3]<h[1]))}updateImage(h,f){f.version=this.images[h].version+1,this.images[h]=f,this.updatedImages[h]=!0}removeImage(h){const f=this.images[h];delete this.images[h],delete this.patterns[h],f.userImage&&f.userImage.onRemove&&f.userImage.onRemove()}listImages(){return Object.keys(this.images)}getImages(h,f){let v=!0;if(!this.isLoaded())for(const w of h)this.images[w]||(v=!1);this.isLoaded()||v?this._notify(h,f):this.requestors.push({ids:h,callback:f})}_notify(h,f){const v={};for(const w of h){this.images[w]||this.fire(new a.Event("styleimagemissing",{id:w}));const S=this.images[w];S?v[w]={data:S.data.clone(),pixelRatio:S.pixelRatio,sdf:S.sdf,version:S.version,stretchX:S.stretchX,stretchY:S.stretchY,content:S.content,hasRenderCallback:!!(S.userImage&&S.userImage.render)}:a.warnOnce(`Image "${w}" could not be loaded. Please make sure you have added the image with map.addImage() or a "sprite" property in your style. You can provide missing images by listening for the "styleimagemissing" map event.`)}f(null,v)}getPixelSize(){const{width:h,height:f}=this.atlasImage;return{width:h,height:f}}getPattern(h){const f=this.patterns[h],v=this.getImage(h);if(!v)return null;if(f&&f.position.version===v.version)return f.position;if(f)f.position.version=v.version;else{const w={w:v.data.width+2,h:v.data.height+2,x:0,y:0},S=new a.ImagePosition(w,v);this.patterns[h]={bin:w,position:S}}return this._updatePatternAtlas(),this.patterns[h].position}bind(h){const f=h.gl;this.atlasTexture?this.dirty&&(this.atlasTexture.update(this.atlasImage),this.dirty=!1):this.atlasTexture=new a.Texture(h,this.atlasImage,f.RGBA),this.atlasTexture&&this.atlasTexture.bind(f.LINEAR,f.CLAMP_TO_EDGE)}_updatePatternAtlas(){const h=[];for(const S in this.patterns)h.push(this.patterns[S].bin);const{w:f,h:v}=a.potpack(h),w=this.atlasImage;w.resize({width:f||1,height:v||1});for(const S in this.patterns){const{bin:I}=this.patterns[S],L=I.x+1,z=I.y+1,H=this.images[S].data,q=H.width,ee=H.height;a.RGBAImage.copy(H,w,{x:0,y:0},{x:L,y:z},{width:q,height:ee}),a.RGBAImage.copy(H,w,{x:0,y:ee-1},{x:L,y:z-1},{width:q,height:1}),a.RGBAImage.copy(H,w,{x:0,y:0},{x:L,y:z+ee},{width:q,height:1}),a.RGBAImage.copy(H,w,{x:q-1,y:0},{x:L-1,y:z},{width:1,height:ee}),a.RGBAImage.copy(H,w,{x:0,y:0},{x:L+q,y:z},{width:1,height:ee})}this.dirty=!0}beginFrame(){this.callbackDispatchedThisFrame={}}dispatchRenderCallbacks(h){for(const f of h){if(this.callbackDispatchedThisFrame[f])continue;this.callbackDispatchedThisFrame[f]=!0;const v=this.images[f];me(v)&&this.updateImage(f,v)}}}const ce=new a.Properties({anchor:new a.DataConstantProperty(a.spec.light.anchor),position:new class{constructor(){this.specification=a.spec.light.position}possiblyEvaluate(y,h){return function([f,v,w]){const S=a.degToRad(v+90),I=a.degToRad(w);return{x:f*Math.cos(S)*Math.sin(I),y:f*Math.sin(S)*Math.sin(I),z:f*Math.cos(I),azimuthal:v,polar:w}}(y.expression.evaluate(h))}interpolate(y,h,f){return{x:a.number(y.x,h.x,f),y:a.number(y.y,h.y,f),z:a.number(y.z,h.z,f),azimuthal:a.number(y.azimuthal,h.azimuthal,f),polar:a.number(y.polar,h.polar,f)}}},color:new a.DataConstantProperty(a.spec.light.color),intensity:new a.DataConstantProperty(a.spec.light.intensity)});class fe extends a.Evented{constructor(h){super(),this._transitionable=new a.Transitionable(ce),this.setLight(h),this._transitioning=this._transitionable.untransitioned()}getLight(){return this._transitionable.serialize()}setLight(h,f={}
120){if(!this._validate(a.validateLight,h,f))for(const v in h){const w=h[v];a.endsWith(v,"-transition")?this._transitionable.setTransition(v.slice(0,-11),w):this._transitionable.setValue(v,w)}}updateTransitions(h){this._transitioning=this._transitionable.transitioned(h,this._transitioning)}hasTransition(){return this._transitioning.hasTransition()}recalculate(h){this.properties=this._transitioning.possiblyEvaluate(h)}_validate(h,f,v){return(!v||v.validate!==!1)&&a.emitValidationErrors(this,h.call(a.validateStyle,a.extend({value:f,style:{glyphs:!0,sprite:!0},styleSpec:a.spec})))}}const ie=new a.Properties({source:new a.DataConstantProperty(a.spec.terrain.source),exaggeration:new a.DataConstantProperty(a.spec.terrain.exaggeration)});let xe=class extends a.Evented{constructor(y,h){super(),this._transitionable=new a.Transitionable(ie),this.set(y),this._transitioning=this._transitionable.untransitioned(),this.drapeRenderMode=h}get(){return this._transitionable.serialize()}set(y){for(const h in y){const f=y[h];a.endsWith(h,"-transition")?this._transitionable.setTransition(h.slice(0,-11),f):this._transitionable.setValue(h,f)}}updateTransitions(y){this._transitioning=this._transitionable.transitioned(y,this._transitioning)}hasTransition(){return this._transitioning.hasTransition()}recalculate(y){this.properties=this._transitioning.possiblyEvaluate(y)}};function Te(y,h,f,v){const w=a.smoothstep(45,65,f),[S,I]=oe(y,v),L=a.length(h);let z=1-Math.min(1,Math.exp((L-S)/(I-S)*-6));return z*=z*z,z=Math.min(1,1.00747*z),z*w*y.alpha}function oe(y,h){const f=.5/Math.tan(.5*h);return[y.range[0]+f,y.range[1]+f]}const ne=new a.Properties({range:new a.DataConstantProperty(a.spec.fog.range),color:new a.DataConstantProperty(a.spec.fog.color),"high-color":new a.DataConstantProperty(a.spec.fog["high-color"]),"space-color":new a.DataConstantProperty(a.spec.fog["space-color"]),"horizon-blend":new a.DataConstantProperty(a.spec.fog["horizon-blend"]),"star-intensity":new a.DataConstantProperty(a.spec.fog["star-intensity"])});class le extends a.Evented{constructor(h,f){super(),this._transitionable=new a.Transitionable(ne),this.set(h),this._transitioning=this._transitionable.untransitioned(),this._transform=f}get state(){const h=this._transform,f=h.projection.name==="globe",v=a.globeToMercatorTransition(h.zoom),w=this.properties.get("range"),S=[.5,3];return{range:f?[a.number(S[0],w[0],v),a.number(S[1],w[1],v)]:w,horizonBlend:this.properties.get("horizon-blend"),alpha:this.properties.get("color").a}}get(){return this._transitionable.serialize()}set(h,f={}){if(!this._validate(a.validateFog,h,f)){for(const v of Object.keys(a.spec.fog))h&&h[v]===void 0&&(h[v]=a.spec.fog[v].default);for(const v in h){const w=h[v];a.endsWith(v,"-transition")?this._transitionable.setTransition(v.slice(0,-11),w):this._transitionable.setValue(v,w)}}}getOpacity(h){if(!this._transform.projection.supportsFog)return 0;const f=this.properties&&this.properties.get("color")||1;return(this._transform.projection.name==="globe"?1:a.smoothstep(45,65,h))*f.a}getOpacityAtLatLng(h,f){return this._transform.projection.supportsFog?function(v,w,S){const I=a.MercatorCoordinate.fromLngLat(w),L=S.elevation?S.elevation.getAtPointOrZero(I):0,z=[I.x,I.y,L];return a.transformMat4(z,z,S.mercatorFogMatrix),Te(v,z,S.pitch,S._fov)}(this.state,h,f):0}getFovAdjustedRange(h){return this._transform.projection.supportsFog?oe(this.state,h):[0,1]}updateTransitions(h){this._transitioning=this._transitionable.transitioned(h,this._transitioning)}hasTransition(){return this._transitioning.hasTransition()}recalculate(h){this.properties=this._transitioning.possiblyEvaluate(h)}_validate(h,f,v){return(!v||v.validate!==!1)&&a.emitValidationErrors(this,h.call(a.validateStyle,a.extend({value:f,style:{glyphs:!0,sprite:!0},styleSpec:a.spec})))}}class se{constructor(h,f){this.workerPool=h,this.actors=[],this.currentActor=0,this.id=a.uniqueId();const v=this.workerPool.acquire(this.id);for(let w=0;w<v.length;w++){const S=new se.Actor(v[w],f,this.id);S.name=`Worker ${w}`,this.actors.push(S)}this.ready=!1,this.broadcast("checkIfReady",null,()=>{this.ready=!0})}broadcast(h,f,v){a.asyncAll(this.actors,(w,S)=>{w.send(h,f,S)},v=v||function(){})}getActor(){return this.currentActor=(this.currentActor+1)%this.actors.length,this.actors[this.currentActor]}
120remove(){this.actors.forEach(h=>{h.remove()}),this.actors=[],this.workerPool.release(this.id)}}function Ne(y,h,f){return h*(a.EXTENT/(y.tileSize*Math.pow(2,f-y.tileID.overscaledZ)))}se.Actor=a.Actor;class Se{constructor(h,f,v,w){this.screenBounds=h,this.cameraPoint=f,this._screenRaycastCache={},this._cameraRaycastCache={},this.isAboveHorizon=v,this.screenGeometry=this.bufferedScreenGeometry(0),this.screenGeometryMercator=this._bufferedScreenMercator(0,w)}static createFromScreenPoints(h,f){let v,w;if(h instanceof a.Point||typeof h[0]=="number"){const S=a.Point.convert(h);v=[S],w=f.isPointAboveHorizon(S)}else{const S=a.Point.convert(h[0]),I=a.Point.convert(h[1]);v=[S,I],w=a.polygonizeBounds(S,I).every(L=>f.isPointAboveHorizon(L))}return new Se(v,f.getCameraPoint(),w,f)}isPointQuery(){return this.screenBounds.length===1}bufferedScreenGeometry(h){return a.polygonizeBounds(this.screenBounds[0],this.screenBounds.length===1?this.screenBounds[0]:this.screenBounds[1],h)}bufferedCameraGeometry(h){const f=this.screenBounds[0],v=this.screenBounds.length===1?this.screenBounds[0].add(new a.Point(1,1)):this.screenBounds[1],w=a.polygonizeBounds(f,v,0,!1);return this.cameraPoint.y>v.y&&(this.cameraPoint.x>f.x&&this.cameraPoint.x<v.x?w.splice(3,0,this.cameraPoint):this.cameraPoint.x>=v.x?w[2]=this.cameraPoint:this.cameraPoint.x<=f.x&&(w[3]=this.cameraPoint)),a.bufferConvexPolygon(w,h)}bufferedCameraGeometryGlobe(h){const f=this.screenBounds[0],v=this.screenBounds.length===1?this.screenBounds[0].add(new a.Point(1,1)):this.screenBounds[1],w=a.polygonizeBounds(f,v,h),S=this.cameraPoint.clone();switch(3*((S.y>f.y)+(S.y>v.y))+((S.x>f.x)+(S.x>v.x))){case 0:w[0]=S,w[4]=S.clone();break;case 1:w.splice(1,0,S);break;case 2:w[1]=S;break;case 3:w.splice(4,0,S);break;case 5:w.splice(2,0,S);break;case 6:w[3]=S;break;case 7:w.splice(3,0,S);break;case 8:w[2]=S}return w}containsTile(h,f,v,w=0){const S=h.queryPadding/f._pixelsPerMercatorPixel+1,I=v?this._bufferedCameraMercator(S,f):this._bufferedScreenMercator(S,f);let L=h.tileID.wrap+(I.unwrapped?w:0);const z=I.polygon.map(Ee=>a.getTilePoint(h.tileTransform,Ee,L));if(!a.polygonIntersectsBox(z,0,0,a.EXTENT,a.EXTENT))return;L=h.tileID.wrap+(this.screenGeometryMercator.unwrapped?w:0);const H=this.screenGeometryMercator.polygon.map(Ee=>a.getTileVec3(h.tileTransform,Ee,L)),q=H.map(Ee=>new a.Point(Ee[0],Ee[1])),ee=f.getFreeCameraOptions().position||new a.MercatorCoordinate(0,0,0),de=a.getTileVec3(h.tileTransform,ee,L),_e=H.map(Ee=>{const te=a.sub(Ee,Ee,de);return a.normalize(te,te),new a.Ray(de,te)}),be=Ne(h,1,f.zoom)*f._pixelsPerMercatorPixel;return{queryGeometry:this,tilespaceGeometry:q,tilespaceRays:_e,bufferedTilespaceGeometry:z,bufferedTilespaceBounds:(ve=a.getBounds(z),ve.min.x=a.clamp(ve.min.x,0,a.EXTENT),ve.min.y=a.clamp(ve.min.y,0,a.EXTENT),ve.max.x=a.clamp(ve.max.x,0,a.EXTENT),ve.max.y=a.clamp(ve.max.y,0,a.EXTENT),ve),tile:h,tileID:h.tileID,pixelToTileUnitsFactor:be};var ve}_bufferedScreenMercator(h,f){const v=wt(h);if(this._screenRaycastCache[v])return this._screenRaycastCache[v];{let w;return w=f.projection.name==="globe"?this._projectAndResample(this.bufferedScreenGeometry(h),f):{polygon:this.bufferedScreenGeometry(h).map(S=>f.pointCoordinate3D(S)),unwrapped:!0},this._screenRaycastCache[v]=w,w}}_bufferedCameraMercator(h,f){const v=wt(h);if(this._cameraRaycastCache[v])return this._cameraRaycastCache[v];{let w;return w=f.projection.name==="globe"?this._projectAndResample(this.bufferedCameraGeometryGlobe(h),f):{polygon:this.bufferedCameraGeometry(h).map(S=>f.pointCoordinate3D(S)),unwrapped:!0},this._cameraRaycastCache[v]=w,w}}_projectAndResample(h,f){const v=function(S,I){const L=a.multiply([],I.pixelMatrix,I.globeMatrix),z=[0,-a.GLOBE_RADIUS,0,1],H=[0,a.GLOBE_RADIUS,0,1],q=[0,0,0,1];a.transformMat4$1(z,z,L),a.transformMat4$1(H,H,L),a.transformMat4$1(q,q,L);const ee=new a.Point(z[0]/z[3],z[1]/z[3]),de=new a.Point(H[0]/H[3],H[1]/H[3]),_e=a.polygonContainsPoint(S,ee)&&z[3]<q[3],be=a.polygonContainsPoint(S,de)&&H[3]<q[3];if(!_e&&!be)return null;const ve=function(Ye,ot,et){for(let _t=1;_t<Ye.length;_t++){const Zt=kt(ot.pointCoordinate3D(Ye[_t-1]).x),dt=kt(ot.pointCoordinate3D(Ye[_t]).x);if(et<0){if(Zt<dt)return{idx:_t,t:-Zt/(dt-1-Zt)}}else if(dt<Zt)return{idx:_t,t:(1-Zt)/(dt+1-Zt)}}return null}(S,I,_e?-1:1);if(!ve)return null;const{idx:Ee,t:te}=ve;let ye=Ee>1?xt(S.slice(0,Ee),I):[],Oe=Ee<S.length?xt(S.slice(Ee),I):[];ye=ye.map(Ye=>new a.Point(kt(Ye.x),Ye.y)),Oe=Oe.map(Ye=>new a.Point(kt(Ye.x),Ye.y));const Le=[...ye];Le.length===0&&Le.push(Oe[Oe.length-1]);const He=a.number(Le[Le.length-1].y,(Oe.length===0?ye[0]:Oe[0]).y,te);let Ze;return Ze=_e?[new a.Point(0,He),new a.Point(0,0),new a.Point(1,0),new a.Point(1,He)]:[new a.Point(1,He),new a.Point(1,1),new a.Point(0,1),new a.Point(0,He)],Le.push(...Ze),Oe.length===0?Le.push(ye[0]):Le.push(...Oe),{polygon:Le.map(Ye=>new a.MercatorCoordinate(Ye.x,Ye.y)),unwrapped:!1}}(h,f);if(v)return v;const w=function(S,I){let L=!1,z=-1/0,H=0;for(let ee=0;ee<S.length-1;ee++)S[ee].x>z&&(z=S[ee].x,H=ee);for(let ee=0;ee<S.length-1;ee++){const de=(H+ee)%(S.length-1),_e=S[de],be=S[de+1];Math.abs(_e.x-be.x)>.5&&(_e.x<be.x?(_e.x+=1,de===0&&(S[S.length-1].x+=1)):(be.x+=1,de+1===S.length-1&&(S[0].x+=1)),L=!0)}const q=a.mercatorXfromLng(I.center.lng);
120return L&&q<Math.abs(q-1)&&S.forEach(ee=>{ee.x-=1}),{polygon:S,unwrapped:L}}(xt(h,f).map(S=>new a.Point(kt(S.x),S.y)),f);return{polygon:w.polygon.map(S=>new a.MercatorCoordinate(S.x,S.y)),unwrapped:w.unwrapped}}}function xt(y,h){return a.resample(y,f=>{const v=h.pointCoordinate3D(f);f.x=v.x,f.y=v.y},1/256)}function kt(y){return y<0?1+y%1:y%1}function wt(y){return 100*y|0}function Ue(y,h,f,v,w){const S=function(I,L){if(I)return w(I);if(L){y.url&&L.tiles&&y.tiles&&delete y.tiles;const z=a.pick(a.extend(L,y),["tiles","minzoom","maxzoom","attribution","mapbox_logo","bounds","scheme","tileSize","encoding"]);L.vector_layers&&(z.vectorLayers=L.vector_layers,z.vectorLayerIds=z.vectorLayers.map(H=>H.id)),z.tiles=h.canonicalizeTileset(z,y.url),w(null,z)}};return y.url?a.getJSON(h.transformRequest(h.normalizeSourceURL(y.url,null,f,v),a.ResourceType.Source),S):a.exported.frame(()=>S(null,y))}class je{constructor(h,f,v){this.bounds=a.LngLatBounds.convert(this.validateBounds(h)),this.minzoom=f||0,this.maxzoom=v||24}validateBounds(h){return Array.isArray(h)&&h.length===4?[Math.max(-180,h[0]),Math.max(-90,h[1]),Math.min(180,h[2]),Math.min(90,h[3])]:[-180,-90,180,90]}contains(h){const f=Math.pow(2,h.z),v=Math.floor(a.mercatorXfromLng(this.bounds.getWest())*f),w=Math.floor(a.mercatorYfromLat(this.bounds.getNorth())*f),S=Math.ceil(a.mercatorXfromLng(this.bounds.getEast())*f),I=Math.ceil(a.mercatorYfromLat(this.bounds.getSouth())*f);return h.x>=v&&h.x<S&&h.y>=w&&h.y<I}}class st{constructor(h,f,v){this.context=h;const w=h.gl;this.buffer=w.createBuffer(),this.dynamicDraw=!!v,this.context.unbindVAO(),h.bindElementBuffer.set(this.buffer),w.bufferData(w.ELEMENT_ARRAY_BUFFER,f.arrayBuffer,this.dynamicDraw?w.DYNAMIC_DRAW:w.STATIC_DRAW),this.dynamicDraw||f.destroy()}bind(){this.context.bindElementBuffer.set(this.buffer)}updateData(h){const f=this.context.gl;this.context.unbindVAO(),this.bind(),f.bufferSubData(f.ELEMENT_ARRAY_BUFFER,0,h.arrayBuffer)}destroy(){this.buffer&&(this.context.gl.deleteBuffer(this.buffer),delete this.buffer)}}const tt={Int8:"BYTE",Uint8:"UNSIGNED_BYTE",Int16:"SHORT",Uint16:"UNSIGNED_SHORT",Int32:"INT",Uint32:"UNSIGNED_INT",Float32:"FLOAT"};class Me{constructor(h,f,v,w){this.length=f.length,this.attributes=v,this.itemSize=f.bytesPerElement,this.dynamicDraw=w,this.context=h;const S=h.gl;this.buffer=S.createBuffer(),h.bindVertexBuffer.set(this.buffer),S.bufferData(S.ARRAY_BUFFER,f.arrayBuffer,this.dynamicDraw?S.DYNAMIC_DRAW:S.STATIC_DRAW),this.dynamicDraw||f.destroy()}bind(){this.context.bindVertexBuffer.set(this.buffer)}updateData(h){const f=this.context.gl;this.bind(),f.bufferSubData(f.ARRAY_BUFFER,0,h.arrayBuffer)}enableAttributes(h,f){for(let v=0;v<this.attributes.length;v++){const w=f.attributes[this.attributes[v].name];w!==void 0&&h.enableVertexAttribArray(w)}}setVertexAttribPointers(h,f,v){for(let w=0;w<this.attributes.length;w++){const S=this.attributes[w],I=f.attributes[S.name];I!==void 0&&h.vertexAttribPointer(I,S.components,h[tt[S.type]],!1,this.itemSize,S.offset+this.itemSize*(v||0))}}destroy(){this.buffer&&(this.context.gl.deleteBuffer(this.buffer),delete this.buffer)}}class lt{constructor(h){this.gl=h.gl,this.default=this.getDefault(),this.current=this.default,this.dirty=!1}get(){return this.current}set(h){}getDefault(){return this.default}setDefault(){this.set(this.default)}}class Ae extends lt{getDefault(){return a.Color.transparent}set(h){const f=this.current;(h.r!==f.r||h.g!==f.g||h.b!==f.b||h.a!==f.a||this.dirty)&&(this.gl.clearColor(h.r,h.g,h.b,h.a),this.current=h,this.dirty=!1)}}class we extends lt{getDefault(){return 1}set(h){(h!==this.current||this.dirty)&&(this.gl.clearDepth(h),this.current=h,this.dirty=!1)}}class Je extends lt{getDefault(){return 0}set(h){(h!==this.current||this.dirty)&&(this.gl.clearStencil(h),this.current=h,this.dirty=!1)}}class ct extends lt{getDefault(){return[!0,!0,!0,!0]}set(h){const f=this.current;(h[0]!==f[0]||h[1]!==f[1]||h[2]!==f[2]||h[3]!==f[3]||this.dirty)&&(this.gl.colorMask(h[0],h[1],h[2],h[3]),this.current=h,this.dirty=!1)}}class mt extends lt{getDefault(){return!0}set(h){(h!==this.current||this.dirty)&&(this.gl.depthMask(h),this.current=h,this.dirty=!1)}}class Vt extends lt{getDefault(){return 255}set(h){(h!==this.current||this.dirty)&&(this.gl.stencilMask(h),this.current=h,this.dirty=!1)}}class Ie extends lt{getDefault(){return{func:this.gl.ALWAYS,ref:0,mask:255}}set(h){const f=this.current;(h.func!==f.func||h.ref!==f.ref||h.mask!==f.mask||this.dirty)&&(this.gl.stencilFunc(h.func,h.ref,h.mask),this.current=h,this.dirty=!1)}}class Pe extends lt{getDefault(){const h=this.gl;return[h.KEEP,h.KEEP,h.KEEP]}set(h){const f=this.current;(h[0]!==f[0]||h[1]!==f[1]||h[2]!==f[2]||this.dirty)&&(this.gl.stencilOp(h[0],h[1],h[2]),this.current=h,this.dirty=!1)}}class rt extends lt{getDefault(){return!1}set(h){if(h===this.current&&!this.dirty)return;const f=this.gl;h?f.enable(f.STENCIL_TEST):f.disable(f.STENCIL_TEST),this.current=h,this.dirty=!1}}class Tt extends lt{getDefault(){return[0,1]}set(h){const f=this.current;(h[0]!==f[0]||h[1]!==f[1]||this.dirty)&&(this.gl.depthRange(h[0],h[1]),this.current=h,this.dirty=!1)}}class pn extends lt{getDefault(){return!1}set(h){if(h===this.current&&!this.dirty)return;const f=this.gl;h?f.enable(f.DEPTH_TEST):f.disable(f.DEPTH_TEST),this.current=h,this.dirty=!1}}class qt extends lt{getDefault(){return this.gl.LESS}set(h){(h!==this.current||this.dirty)&&(this.gl.depthFunc(h),this.current=h,this.dirty=!1)}}class nt extends lt{getDefault(){return!1}set(h){if(h===this.current&&!this.dirty)return;const f=this.gl;h?f.enable(f.BLEND):f.disable(f.BLEND),this.current=h,this.dirty=!1}}class It extends lt{getDefault(){const h=this.gl;return[h.ONE,h.ZERO]}set(h){const f=this.current;(h[0]!==f[0]||h[1]!==f[1]||this.dirty)&&(this.gl.blendFunc(h[0],h[1]),this.current=h,this.dirty=!1)}}class $t extends lt{getDefault(){return a.Color.transparent}set(h){const f=this.current;(h.r!==f.r||h.g!==f.g||h.b!==f.b||h.a!==f.a||this.dirty)&&(this.gl.blendColor
120(h.r,h.g,h.b,h.a),this.current=h,this.dirty=!1)}}class $e extends lt{getDefault(){return this.gl.FUNC_ADD}set(h){(h!==this.current||this.dirty)&&(this.gl.blendEquation(h),this.current=h,this.dirty=!1)}}class pt extends lt{getDefault(){return!1}set(h){if(h===this.current&&!this.dirty)return;const f=this.gl;h?f.enable(f.CULL_FACE):f.disable(f.CULL_FACE),this.current=h,this.dirty=!1}}class gn extends lt{getDefault(){return this.gl.BACK}set(h){(h!==this.current||this.dirty)&&(this.gl.cullFace(h),this.current=h,this.dirty=!1)}}class Pn extends lt{getDefault(){return this.gl.CCW}set(h){(h!==this.current||this.dirty)&&(this.gl.frontFace(h),this.current=h,this.dirty=!1)}}let gr,Ji=class extends lt{getDefault(){return null}set(y){(y!==this.current||this.dirty)&&(this.gl.useProgram(y),this.current=y,this.dirty=!1)}};class Ni extends lt{getDefault(){return this.gl.TEXTURE0}set(h){(h!==this.current||this.dirty)&&(this.gl.activeTexture(h),this.current=h,this.dirty=!1)}}class Bo extends lt{getDefault(){const h=this.gl;return[0,0,h.drawingBufferWidth,h.drawingBufferHeight]}set(h){const f=this.current;(h[0]!==f[0]||h[1]!==f[1]||h[2]!==f[2]||h[3]!==f[3]||this.dirty)&&(this.gl.viewport(h[0],h[1],h[2],h[3]),this.current=h,this.dirty=!1)}}class _i extends lt{getDefault(){return null}set(h){if(h===this.current&&!this.dirty)return;const f=this.gl;f.bindFramebuffer(f.FRAMEBUFFER,h),this.current=h,this.dirty=!1}}class Wr extends lt{getDefault(){return null}set(h){if(h===this.current&&!this.dirty)return;const f=this.gl;f.bindRenderbuffer(f.RENDERBUFFER,h),this.current=h,this.dirty=!1}}class Ao extends lt{getDefault(){return null}set(h){if(h===this.current&&!this.dirty)return;const f=this.gl;f.bindTexture(f.TEXTURE_2D,h),this.current=h,this.dirty=!1}}class xs extends lt{getDefault(){return null}set(h){if(h===this.current&&!this.dirty)return;const f=this.gl;f.bindBuffer(f.ARRAY_BUFFER,h),this.current=h,this.dirty=!1}}class Fe extends lt{getDefault(){return null}set(h){const f=this.gl;f.bindBuffer(f.ELEMENT_ARRAY_BUFFER,h),this.current=h,this.dirty=!1}}class ae extends lt{constructor(h){super(h),this.vao=h.extVertexArrayObject}getDefault(){return null}set(h){this.vao&&(h!==this.current||this.dirty)&&(this.vao.bindVertexArrayOES(h),this.current=h,this.dirty=!1)}}class ue extends lt{getDefault(){return 4}set(h){if(h===this.current&&!this.dirty)return;const f=this.gl;f.pixelStorei(f.UNPACK_ALIGNMENT,h),this.current=h,this.dirty=!1}}class De extends lt{getDefault(){return!1}set(h){if(h===this.current&&!this.dirty)return;const f=this.gl;f.pixelStorei(f.UNPACK_PREMULTIPLY_ALPHA_WEBGL,h),this.current=h,this.dirty=!1}}class qe extends lt{getDefault(){return!1}set(h){if(h===this.current&&!this.dirty)return;const f=this.gl;f.pixelStorei(f.UNPACK_FLIP_Y_WEBGL,h),this.current=h,this.dirty=!1}}class Xe extends lt{constructor(h,f){super(h),this.context=h,this.parent=f}getDefault(){return null}}class ht extends Xe{setDirty(){this.dirty=!0}set(h){if(h===this.current&&!this.dirty)return;this.context.bindFramebuffer.set(this.parent);const f=this.gl;f.framebufferTexture2D(f.FRAMEBUFFER,f.COLOR_ATTACHMENT0,f.TEXTURE_2D,h,0),this.current=h,this.dirty=!1}}class ut extends Xe{attachment(){return this.gl.DEPTH_ATTACHMENT}set(h){if(h===this.current&&!this.dirty)return;this.context.bindFramebuffer.set(this.parent);const f=this.gl;f.framebufferRenderbuffer(f.FRAMEBUFFER,this.attachment(),f.RENDERBUFFER,h),this.current=h,this.dirty=!1}}class Ke extends ut{attachment(){return this.gl.DEPTH_STENCIL_ATTACHMENT}}class Et{constructor(h,f,v,w){this.context=h,this.width=f,this.height=v;const S=this.framebuffer=h.gl.createFramebuffer();this.colorAttachment=new ht(h,S),w&&(this.depthAttachment=new ut(h,S))}destroy(){const h=this.context.gl,f=this.colorAttachment.get();if(f&&h.deleteTexture(f),this.depthAttachment){const v=this.depthAttachment.get();v&&h.deleteRenderbuffer(v)}h.deleteFramebuffer(this.framebuffer)}}class en{constructor(h,f=!1){if(this.gl=h,this.isWebGL2=f,this.extVertexArrayObject=this.gl.getExtension("OES_vertex_array_object"),f){const v=h;this.extVertexArrayObject={createVertexArrayOES:v.createVertexArray.bind(h),deleteVertexArrayOES:v.deleteVertexArray.bind(h),bindVertexArrayOES:v.bindVertexArray.bind(h)}}this.clearColor=new Ae(this),this.clearDepth=new we(this),this.clearStencil=new Je(this),this.colorMask=new ct(this),this.depthMask=new mt(this),this.stencilMask=new Vt(this),this.stencilFunc=new Ie(this),this.stencilOp=new Pe
120(this),this.stencilTest=new rt(this),this.depthRange=new Tt(this),this.depthTest=new pn(this),this.depthFunc=new qt(this),this.blend=new nt(this),this.blendFunc=new It(this),this.blendColor=new $t(this),this.blendEquation=new $e(this),this.cullFace=new pt(this),this.cullFaceSide=new gn(this),this.frontFace=new Pn(this),this.program=new Ji(this),this.activeTexture=new Ni(this),this.viewport=new Bo(this),this.bindFramebuffer=new _i(this),this.bindRenderbuffer=new Wr(this),this.bindTexture=new Ao(this),this.bindVertexBuffer=new xs(this),this.bindElementBuffer=new Fe(this),this.bindVertexArrayOES=this.extVertexArrayObject&&new ae(this),this.pixelStoreUnpack=new ue(this),this.pixelStoreUnpackPremultiplyAlpha=new De(this),this.pixelStoreUnpackFlipY=new qe(this),this.extTextureFilterAnisotropic=h.getExtension("EXT_texture_filter_anisotropic")||h.getExtension("MOZ_EXT_texture_filter_anisotropic")||h.getExtension("WEBKIT_EXT_texture_filter_anisotropic"),this.extTextureFilterAnisotropic&&(this.extTextureFilterAnisotropicMax=h.getParameter(this.extTextureFilterAnisotropic.MAX_TEXTURE_MAX_ANISOTROPY_EXT)),this.extTextureFilterAnisotropicForceOff=!1,this.extStandardDerivativesForceOff=!1,this.extDebugRendererInfo=h.getExtension("WEBGL_debug_renderer_info"),this.extDebugRendererInfo&&(this.renderer=h.getParameter(this.extDebugRendererInfo.UNMASKED_RENDERER_WEBGL),this.vendor=h.getParameter(this.extDebugRendererInfo.UNMASKED_VENDOR_WEBGL)),f||(this.extTextureHalfFloat=h.getExtension("OES_texture_half_float")),(f||this.extTextureHalfFloat&&h.getExtension("OES_texture_half_float_linear"))&&(this.extRenderToTextureHalfFloat=h.getExtension("EXT_color_buffer_half_float")),this.extStandardDerivatives=f||h.getExtension("OES_standard_derivatives"),this.extTimerQuery=h.getExtension("EXT_disjoint_timer_query"),this.maxTextureSize=h.getParameter(h.MAX_TEXTURE_SIZE)}setDefault(){this.unbindVAO(),this.clearColor.setDefault(),this.clearDepth.setDefault(),this.clearStencil.setDefault(),this.colorMask.setDefault(),this.depthMask.setDefault(),this.stencilMask.setDefault(),this.stencilFunc.setDefault(),this.stencilOp.setDefault(),this.stencilTest.setDefault(),this.depthRange.setDefault(),this.depthTest.setDefault(),this.depthFunc.setDefault(),this.blend.setDefault(),this.blendFunc.setDefault(),this.blendColor.setDefault(),this.blendEquation.setDefault(),this.cullFace.setDefault(),this.cullFaceSide.setDefault(),this.frontFace.setDefault(),this.program.setDefault(),this.activeTexture.setDefault(),this.bindFramebuffer.setDefault(),this.pixelStoreUnpack.setDefault(),this.pixelStoreUnpackPremultiplyAlpha.setDefault(),this.pixelStoreUnpackFlipY.setDefault()}setDirty(){this.clearColor.dirty=!0,this.clearDepth.dirty=!0,this.clearStencil.dirty=!0,this.colorMask.dirty=!0,this.depthMask.dirty=!0,this.stencilMask.dirty=!0,this.stencilFunc.dirty=!0,this.stencilOp.dirty=!0,this.stencilTest.dirty=!0,this.depthRange.dirty=!0,this.depthTest.dirty=!0,this.depthFunc.dirty=!0,this.blend.dirty=!0,this.blendFunc.dirty=!0,this.blendColor.dirty=!0,this.blendEquation.dirty=!0,this.cullFace.dirty=!0,this.cullFaceSide.dirty=!0,this.frontFace.dirty=!0,this.program.dirty=!0,this.activeTexture.dirty=!0,this.viewport.dirty=!0,this.bindFramebuffer.dirty=!0,this.bindRenderbuffer.dirty=!0,this.bindTexture.dirty=!0,this.bindVertexBuffer.dirty=!0,this.bindElementBuffer.dirty=!0,this.extVertexArrayObject&&(this.bindVertexArrayOES.dirty=!0),this.pixelStoreUnpack.dirty=!0,this.pixelStoreUnpackPremultiplyAlpha.dirty=!0,this.pixelStoreUnpackFlipY.dirty=!0}createIndexBuffer(h,f){return new st(this,h,f)}createVertexBuffer(h,f,v){return new Me(this,h,f,v)}createRenderbuffer(h,f,v){const w=this.gl,S=w.createRenderbuffer();return this.bindRenderbuffer.set(S),w.renderbufferStorage(w.RENDERBUFFER,h,f,v),this.bindRenderbuffer.set(null),S}createFramebuffer(h,f,v){return new Et(this,h,f,v)}clear({color:h,depth:f,stencil:v}){const w=this.gl;let S=0;h&&(S|=w.COLOR_BUFFER_BIT,this.clearColor.set(h),this.colorMask.set([!0,!0,!0,!0])),f!==void 0&&(S|=w.DEPTH_BUFFER_BIT,this.depthRange.set([0,1]),this.clearDepth.set(f),this.depthMask.set(!0)),v!==void 0&&(S|=w.STENCIL_BUFFER_BIT,this.clearStencil.set(v),this.stencilMask.set(255)),w.clear(S)}setCullFace(h){h.enable===!1?this.cullFace.set(!1):(this.cullFace.set(!0),this.cullFaceSide.set(h.mode),this.frontFace.set(h.frontFace))}setDepthMode(h){h.func!==this.gl.ALWAYS||h.mask?(this.depthTest.set(!0),this.depthFunc.set(h.func),this.depthMask.set(h.mask),this.depthRange.set(h.range)):this.depthTest.set(!1)}setStencilMode(h){h.test.func!==this.gl.ALWAYS||h.mask?(this.stencilTest.set(!0),this.stencilMask.set(h.mask),this.stencilOp.set([h.fail,h.depthFail,h.pass]),this.stencilFunc.set({func:h.test.func,ref:h.ref,mask:h.test.mask})):this.stencilTest.set(!1)}setColorMode(h){m(h.blendFunction,a.ColorMode.Replace)?this.blend.set(!1):(this.blend.set(!0),this.blendFunc.set(h.blendFunction),this.blendColor.set(h.blendColor)),this.colorMask.set(h.mask)}unbindVAO(){this.extVertexArrayObject&&this.bindVertexArrayOES.set(null)}}class ln extends a.Evented{constructor(h,f,v,w){if(super(),this.id=h,this.dispatcher=v,this.type="vector",this.minzoom=0,this.maxzoom=22,this.scheme="xyz",this.tileSize=512,this.reparseOverscaled=!0,this.isTileClipped=!0,this._loaded=!1,a.extend(this,a.pick(f,["url","scheme","tileSize","promoteId"])),this._options=a.extend({type:"vector"},f),this._collectResourceTiming=f.collectResourceTiming,this.tileSize!==512)throw new Error("vector tile sources must have a tileSize of 512");this.setEventedParent(w),this._tileWorkers={},this._deduped=new a.DedupedRequest}load(h){this._loaded=!1,this.fire(new a.Event("dataloading",{dataType:"source"}));const f=Array.isArray(this.map._language)?this.map._language.join():this.map._language,v=this.map._worldview;this._tileJSONRequest=Ue(this._options,this.map._requestManager,f,v,(w,S)=>{this._tileJSONRequest=null,this._loaded=!0,w?(f&&console.warn(`Ensure that your requested language string is a valid BCP-47 code or list of codes. Found: ${f}`),v&&v.length!==2&&console.warn(`Requested worldview strings must be a valid ISO alpha-2 code. Found: ${v}`),this.fire(new a.ErrorEvent(w))):S&&(a.extend(this,S),S.bounds&&(this.tileBounds=new je(S.bounds,this.minzoom,this.maxzoom)),a.postTurnstileEvent(S.tiles,this.map._requestManager._customAccessToken),this.fire(new a.Event("data",{dataType:"source",sourceDataType:"metadata"})),this.fire(new a.Event("data",{dataType:"source",sourceDataType:"content"}))),h&&h(w)})}loaded(){return this._loaded}hasTile(h){return!this.tileBounds||this.tileBounds.contains(h.canonical)}onAdd(h){this.map=h,this.load()}reload(){this.cancelTileJSONRequest(),this.load(()=>
120this.map.style._clearSource(this.id))}setTiles(h){return this._options.tiles=h,this.reload(),this}setUrl(h){return this.url=h,this._options.url=h,this.reload(),this}onRemove(){this.cancelTileJSONRequest()}serialize(){return a.extend({},this._options)}loadTile(h,f){const v=this.map._requestManager.normalizeTileURL(h.tileID.canonical.url(this.tiles,this.scheme)),w={request:this.map._requestManager.transformRequest(v,a.ResourceType.Tile),data:void 0,uid:h.uid,tileID:h.tileID,tileZoom:h.tileZoom,zoom:h.tileID.overscaledZ,tileSize:this.tileSize*h.tileID.overscaleFactor(),type:this.type,source:this.id,pixelRatio:a.exported.devicePixelRatio,showCollisionBoxes:this.map.showCollisionBoxes,promoteId:this.promoteId,isSymbolTile:h.isSymbolTile};if(w.request.collectResourceTiming=this._collectResourceTiming,h.actor&&h.state!=="expired")h.state==="loading"?h.reloadCallback=f:h.request=h.actor.send("reloadTile",w,S.bind(this));else if(h.actor=this._tileWorkers[v]=this._tileWorkers[v]||this.dispatcher.getActor(),this.dispatcher.ready)h.request=h.actor.send("loadTile",w,S.bind(this),void 0,!0);else{const I=a.loadVectorTile.call({deduped:this._deduped},w,(L,z)=>{L||!z?S.call(this,L):(w.data={cacheControl:z.cacheControl,expires:z.expires,rawData:z.rawData.slice(0)},h.actor&&h.actor.send("loadTile",w,S.bind(this),void 0,!0))},!0);h.request={cancel:I}}function S(I,L){return delete h.request,h.aborted?f(null):I&&I.status!==404?f(I):(L&&L.resourceTiming&&(h.resourceTiming=L.resourceTiming),this.map._refreshExpiredTiles&&L&&h.setExpiryData(L),h.loadVectorData(L,this.map.painter),a.cacheEntryPossiblyAdded(this.dispatcher),f(null),void(h.reloadCallback&&(this.loadTile(h,h.reloadCallback),h.reloadCallback=null)))}}abortTile(h){h.request&&(h.request.cancel(),delete h.request),h.actor&&h.actor.send("abortTile",{uid:h.uid,type:this.t
120ype,source:this.id})}unloadTile(h){h.unloadVectorData(),h.actor&&h.actor.send("removeTile",{uid:h.uid,type:this.type,source:this.id})}hasTransition(){return!1}afterUpdate(){this._tileWorkers={}}cancelTileJSONRequest(){this._tileJSONRequest&&(this._tileJSONRequest.cancel(),this._tileJSONRequest=null)}}class Kt extends a.Evented{constructor(h,f,v,w){super(),this.id=h,this.dispatcher=v,this.setEventedParent(w),this.type="raster",this.minzoom=0,this.maxzoom=22,this.roundZoom=!0,this.scheme="xyz",this.tileSize=512,this._loaded=!1,this._options=a.extend({type:"raster"},f),a.extend(this,a.pick(f,["url","scheme","tileSize"]))}load(h){this._loaded=!1,this.fire(new a.Event("dataloading",{dataType:"source"})),this._tileJSONRequest=Ue(this._options,this.map._requestManager,null,null,(f,v)=>{this._tileJSONRequest=null,this._loaded=!0,f?this.fire(new a.ErrorEvent(f)):v&&(a.extend(this,v),v.bounds&&(this.tileBounds=new je(v.bounds,this.minzoom,this.maxzoom)),a.postTurnstileEvent(v.tiles),this.fire(new a.Event("data",{dataType:"source",sourceDataType:"metadata"})),this.fire(new a.Event("data",{dataType:"source",sourceDataType:"content"}))),h&&h(f)})}loaded(){return this._loaded}onAdd(h){this.map=h,this.load()}reload(){this.cancelTileJSONRequest(),this.load(()=>this.map.style._clearSource(this.id))}setTiles(h){return this._options.tiles=h,this.reload(),this}setUrl(h){return this.url=h,this._options.url=h,this.reload(),this}onRemove(){this.cancelTileJSONRequest()}serialize(){return a.extend({},this._options)}hasTile(h){return!this.tileBounds||this.tileBounds.contains(h.canonical)}loadTile(h,f){const v=a.exported.devicePixelRatio>=2,w=this.map._requestManager.normalizeTileURL(h.tileID.canonical.url(this.tiles,this.scheme),v,this.tileSize);h.request=a.getImage(this.map._requestManager.transformRequest(w,a.ResourceType.Tile),(S,I,L,z)=>(delete h.request,h.aborted?(h.state="unloaded",f(null)):S?(h.state="errored",f(S)):I?(this.map._refreshExpiredTiles&&h.setExpiryData({cacheControl:L,expires:z}),h.setTexture(I,this.map.painter),h.state="loaded",a.cacheEntryPossiblyAdded(this.dispatcher),void f(null)):f(null)))}static loadTileData(h,f,v){h.setTexture(f,v)}static unloadTileData(h,f){h.texture&&f.saveTileTexture(h.texture)}abortTile(h,f){h.request&&(h.request.cancel(),delete h.request),f()}unloadTile(h,f){h.texture&&this.map.painter.saveTileTexture(h.texture),f()}hasTransition(){return!1}cancelTileJSONRequest(){this._tileJSONRequest&&(this._tileJSONRequest.cancel(),this._tileJSONRequest=null)}}function Xn(y,h,f,v,w,S,I,L){const z=[y,f,w,h,v,S,1,1,1],H=[I,L,1],q=a.adjoint([],z),[ee,de,_e]=a.transformMat3(H,H,a.transpose(q,q));return a.multiply$1(z,[ee,0,0,0,de,0,0,0,_e],z)}class jn extends a.Evented{constructor(h,f,v,w){super(),this.id=h,this.dispatcher=v,this.coordinates=f.coordinates,this.type="image",this.minzoom=0,this.maxzoom=22,this.tileSize=512,this.tiles={},this._loaded=!1,this.setEventedParent(w),this.options=f,this._dirty=!1}load(h,f){this._loaded=f||!1,this.fire(new a.Event("dataloading",{dataType:"source"})),this.url=this.options.url,this._imageRequest=a.getImage(this.map._requestManager.transformRequest(this.url,a.ResourceType.Image),(v,w)=>{if(this._imageRequest=null,this._loaded=!0,v)this.fire(new a.ErrorEvent(v));else if(w){const{HTMLImageElement:S}=a.window;this.image=w instanceof S?a.exported.getImageData(w):w,this._dirty=!0,this.width=this.image.width,this.height=this.image.height,h&&(this.coordinates=h),this._finishLoading()}})}loaded(){return this._loaded}updateImage(h){return this.image&&h.url?(this._imageRequest&&h.url!==this.options.url&&(this._imageRequest.cancel(),this._imageRequest=null),this.options.url=h.url,this.load(h.coordinates,this._loaded),this):this}_finishLoading(){this.map&&(this.setCoordinates(this.coordinates),this.fire(new a.Event("data",{dataType:"source",sourceDataType:"metadata"})))}onAdd(h){this.map=h,this.load()}onRemove(){this._imageRequest&&(this._imageRequest.cancel(),this._imageRequest=null),this.texture&&this.texture.destroy()}setCoordinates(h){this.coordinates=h,this._boundsArray=void 0;const f=h.map(a.MercatorCoordinate.fromLngLat);return this.tileID=function(v){let w=1/0,S=1/0,I=-1/0,L=-1/0;for(const ee of v)w=Math.min(w,ee.x),S=Math.min(S,ee.y),I=Math.max(I,ee.x),L=Math.max(L,ee.y);const z=Math.max(I-w,L-S),H=Math.max(0,Math.floor(-Math.log(z)/Math.LN2)),q=Math.pow(2,H);return new a.CanonicalTileID(H,Math.floor((w+I)/2*q),Math.floor((S+L)/2*q))}(f),this.minzoom=this.maxzoom=this.tileID.z,this.fire(new a.Event("data",{dataType:"source",sourceDataType:"content"})),this}_clear(){this._boundsArray=void 0}_prepareData(h){for(const z in this.tiles){const H=this.tiles[z];H.state!=="loaded"&&(H.state="loaded",H.texture=this.texture)}if(this._boundsArray)return;const f=a.tileTransform(this.tileID,this.map.transform.projection),[v,w,S,I]=this.coordinates.map(z=>{const H=f.projection.project(z[0],z[1]);return a.getTilePoint(f,H)._round()});this.perspectiveTransform=function(z,H,q,ee,de,_e,be,ve,Ee,te){const ye=Xn(0,0,z,0,0,H,z,H),Oe=Xn(q,ee,de,_e,be,ve,Ee,te);return a.multiply$1(Oe,a.adjoint(ye,ye),Oe),[Oe[6]/Oe[8]*z/a.EXTENT,Oe[7]/Oe[8]*H/a.EXTENT]}(this.width,this.height,v.x,v.y,w.x,w.y,I.x,I.y,S.x,S.y);const L=this._boundsArray=new a.StructArrayLayout4i8;L.emplaceBack(v.x,v.y,0,0),L.emplaceBack(w.x,w.y,a.EXTENT,0),L.emplaceBack(I.x,I.y,0,a.EXTENT),L.emplaceBack(S.x,S.y,a.EXTENT,a.EXTENT),this.boundsBuffer&&this.boundsBuffer.destroy(),this.boundsBuffer=h.createVertexBuffer(L,a.boundsAttributes.members),this.boundsSegments=a.SegmentVector.simpleSegment(0,0,4,2)}prepare(){if(Object.keys(this.tiles).length===0||!this.image)return;
120const h=this.map.painter.context,f=h.gl;this._dirty&&(this.texture?this.texture.update(this.image):(this.texture=new a.Texture(h,this.image,f.RGBA),this.texture.bind(f.LINEAR,f.CLAMP_TO_EDGE)),this._dirty=!1),this._prepareData(h)}loadTile(h,f){this.tileID&&this.tileID.equals(h.tileID.canonical)?(this.tiles[String(h.tileID.wrap)]=h,h.buckets={},f(null)):(h.state="errored",f(null))}serialize(){return{type:"image",url:this.options.url,coordinates:this.coordinates}}hasTransition(){return!1}}const Yn={vector:ln,raster:Kt,"raster-dem":class extends Kt{constructor(y,h,f,v){super(y,h,f,v),this.type="raster-dem",this.maxzoom=22,this._options=a.extend({type:"raster-dem"},h),this.encoding=h.encoding||"mapbox"}loadTile(y,h){const f=this.map._requestManager.normalizeTileURL(y.tileID.canonical.url(this.tiles,this.scheme),!1,this.tileSize);function v(w,S){w&&(y.state="errored",h(w)),S&&(y.dem=S,y.dem.onDeserialize(),y.needsHillshadePrepare=!0,y.needsDEMTextureUpload=!0,y.state="loaded",h(null))}y.request=a.getImage(this.map._requestManager.transformRequest(f,a.ResourceType.Tile),function(w,S,I,L){if
120(delete y.request,y.aborted)y.state="unloaded",h(null);else if(w)y.state="errored",h(w);else if(S){this.map._refreshExpiredTiles&&y.setExpiryData({cacheControl:I,expires:L});const z=a.window.ImageBitmap&&S instanceof a.window.ImageBitmap&&(gr==null&&(gr=a.window.OffscreenCanvas&&new a.window.OffscreenCanvas(1,1).getContext("2d")&&typeof a.window.createImageBitmap=="function"),gr),H=1-(S.width-a.prevPowerOfTwo(S.width))/2;H<1||y.neighboringTiles||(y.neighboringTiles=this._getNeighboringTiles(y.tileID));const q=z?S:a.exported.getImageData(S,H),ee={uid:y.uid,coord:y.tileID,source:this.id,rawImageData:q,encoding:this.encoding,padding:H};y.actor&&y.state!=="expired"||(y.actor=this.dispatcher.getActor(),y.actor.send("loadDEMTile",ee,v.bind(this),void 0,!0))}}.bind(this))}_getNeighboringTiles(y){const h=y.canonical,f=Math.pow(2,h.z),v=(h.x-1+f)%f,w=h.x===0?y.wrap-1:y.wrap,S=(h.x+1+f)%f,I=h.x+1===f?y.wrap+1:y.wrap,L={};return L[new a.OverscaledTileID(y.overscaledZ,w,h.z,v,h.y).key]={backfilled:!1},L[new a.OverscaledTileID(y.overscaledZ,I,h.z,S,h.y).key]={backfilled:!1},h.y>0&&(L[new a.OverscaledTileID(y.overscaledZ,w,h.z,v,h.y-1).key]={backfilled:!1},L[new a.OverscaledTileID(y.overscaledZ,y.wrap,h.z,h.x,h.y-1).key]={backfilled:!1},L[new a.OverscaledTileID(y.overscaledZ,I,h.z,S,h.y-1).key]={backfilled:!1}),h.y+1<f&&(L[new a.OverscaledTileID(y.overscaledZ,w,h.z,v,h.y+1).key]={backfilled:!1},L[new a.OverscaledTileID(y.overscaledZ,y.wrap,h.z,h.x,h.y+1).key]={backfilled:!1},L[new a.OverscaledTileID(y.overscaledZ,I,h.z,S,h.y+1).key]={backfilled:!1}),L}unloadTile(y){y.demTexture&&this.map.painter.saveTileTexture(y.demTexture),y.fbo&&(y.fbo.destroy(),delete y.fbo),y.dem&&delete y.dem,delete y.neighboringTiles,y.state="unloaded"}},geojson:class extends a.Evented{constructor(y,h,f,v){super(),this.id=y,this.type="geojson",this.minzoom=0,this.maxzoom=18,this.tileSize=512,this.isTileClipped=!0,this.reparseOverscaled=!0,this._loaded=!1,this.actor=f.getActor(),this.setEventedParent(v),this._data=h.data,this._options=a.extend({},h),this._collectResourceTiming=h.collectResourceTiming,h.maxzoom!==void 0&&(this.maxzoom=h.maxzoom),h.type&&(this.type=h.type),h.attribution&&(this.attribution=h.attribution),this.promoteId=h.promoteId;const w=a.EXTENT/this.tileSize;this.workerOptions=a.extend({source:this.id,cluster:h.cluster||!1,geojsonVtOptions:{buffer:(h.buffer!==void 0?h.buffer:128)*w,tolerance:(h.tolerance!==void 0?h.tolerance:.375)*w,extent:a.EXTENT,maxZoom:this.maxzoom,lineMetrics:h.lineMetrics||!1,generateId:h.generateId||!1},superclusterOptions:{maxZoom:h.clusterMaxZoom!==void 0?h.clusterMaxZoom:this.maxzoom-1,minPoints:Math.max(2,h.clusterMinPoints||2),extent:a.EXTENT,radius:(h.clusterRadius!==void 0?h.clusterRadius:50)*w,log:!1,generateId:h.generateId||!1},clusterProperties:h.clusterProperties,filter:h.filter},h.workerOptions)}onAdd(y){this.map=y,this.setData(this._data)}setData(y){return this._data=y,this._updateWorkerData(),this}getClusterExpansionZoom(y,h){return this.actor.send("geojson.getClusterExpansionZoom",{clusterId:y,source:this.id},h),this}getClusterChildren(y,h){return this.actor.send("geojson.getClusterChildren",{clusterId:y,source:this.id},h),this}getClusterLeaves(y,h,f,v){return this.actor.send("geojson.getClusterLeaves",{source:this.id,clusterId:y,limit:h,offset:f},v),this}_updateWorkerData(){if(this._pendingLoad)return void(this._coalesce=!0);this.fire(new a.Event("dataloading",{dataType:"source"})),this._loaded=!1;const y=a.extend({},this.workerOptions),h=this._data;typeof h=="string"?(y.request=this.map._requestManager.transformRequest(a.exported.resolveURL(h),a.ResourceType.Source),y.request.collectResourceTiming=this._collectResourceTiming):y.data=JSON.stringify(h),this._pendingLoad=this.actor.send(`${this.type}.loadData`,y,(f,v)=>{if(this._loaded=!0,this._pendingLoad=null,f)this.fire(new a.ErrorEvent(f));else{const w={dataType:"source",sourceDataType:this._metadataFired?"content":"metadata"};this._collectResourceTiming&&v&&v.resourceTiming&&v.resourceTiming[this.id]&&(w.resourceTiming=v.resourceTiming[this.id]),this.fire(new a.Event("data",w)),this._metadataFired=!0}this._coalesce&&(this._updateWorkerData(),this._coalesce=!1)})}loaded(){return this._loaded}loadTile(y,h){const f=y.actor?"reloadTile":"loadTile";
120y.actor=this.actor,y.request=this.actor.send(f,{type:this.type,uid:y.uid,tileID:y.tileID,tileZoom:y.tileZoom,zoom:y.tileID.overscaledZ,maxZoom:this.maxzoom,tileSize:this.tileSize,source:this.id,pixelRatio:a.exported.devicePixelRatio,showCollisionBoxes:this.map.showCollisionBoxes,promoteId:this.promoteId},(v,w)=>(delete y.request,y.unloadVectorData(),y.aborted?h(null):v?h(v):(y.loadVectorData(w,this.map.painter,f==="reloadTile"),h(null))),void 0,f==="loadTile")}abortTile(y){y.request&&(y.request.cancel(),delete y.request),y.aborted=!0}unloadTile(y){y.unloadVectorData(),this.actor.send("removeTile",{uid:y.uid,type:this.type,source:this.id})}onRemove(){this._pendingLoad&&this._pendingLoad.cancel()}serialize(){return a.extend({},this._options,{type:this.type,data:this._data})}hasTransition(){return!1}},video:class extends jn{constructor(y,h,f,v){super(y,h,f,v),this.roundZoom=!0,this.type="video",this.options=h}load(){this._loaded=!1;const y=this.options;this.urls=[];for(const h of y.urls)this.urls.push(this.map._requestManager.transformRequest(h,a.ResourceType.Source).url);a.getVideo(this.urls,(h,f)=>{this._loaded=!0,h?this.fire(new a.ErrorEvent(h)):f&&(this.video=f,this.video.loop=!0,this.video.setAttribute("playsinline",""),this.video.addEventListener("playing",()=>{this.map.triggerRepaint()}),this.map&&this.video.play(),this._finishLoading())})}pause(){this.video&&this.video.pause()}play(){this.video&&this.video.play()}seek(y){if(this.video){const h=this.video.seekable;y<h.start(0)||y>h.end(0)?this.fire(new a.ErrorEvent(new a.ValidationError(`sources.${this.id}`,null,`Playback for this video can be set only between the ${h.start(0)} and ${h.end(0)}-second mark.`))):this.video.currentTime=y}}getVideo(){return this.video}
120onAdd(y){this.map||(this.map=y,this.load(),this.video&&(this.video.play(),this.setCoordinates(this.coordinates)))}prepare(){if(Object.keys(this.tiles).length===0||this.video.readyState<2)return;const y=this.map.painter.context,h=y.gl;this.texture?this.video.paused||(this.texture.bind(h.LINEAR,h.CLAMP_TO_EDGE),h.texSubImage2D(h.TEXTURE_2D,0,0,0,h.RGBA,h.UNSIGNED_BYTE,this.video)):(this.texture=new a.Texture(y,this.video,h.RGBA),this.texture.bind(h.LINEAR,h.CLAMP_TO_EDGE),this.width=this.video.videoWidth,this.height=this.video.videoHeight),this._prepareData(y)}serialize(){return{type:"video",urls:this.urls,coordinates:this.coordinates}}hasTransition(){return this.video&&!this.video.paused}},image:jn,canvas:class extends jn{constructor(y,h,f,v){super(y,h,f,v),h.coordinates?Array.isArray(h.coordinates)&&h.coordinates.length===4&&!h.coordinates.some(w=>!Array.isArray(w)||w.length!==2||w.some(S=>typeof S!="number"))||this.fire(new a.ErrorEvent(new a.ValidationError(`sources.${y}`,null,'"coordinates" property must be an array of 4 longitude/latitude array pairs'))):this.fire(new a.ErrorEvent(new a.ValidationError(`sources.${y}`,null,'missing required property "coordinates"'))),h.animate&&typeof h.animate!="boolean"&&this.fire(new a.ErrorEvent(new a.ValidationError(`sources.${y}`,null,'optional "animate" property must be a boolean value'))),h.canvas?typeof h.canvas=="string"||h.canvas instanceof a.window.HTMLCanvasElement||this.fire(new a.ErrorEvent(new a.ValidationError(`sources.${y}`,null,'"canvas" must be either a string representing the ID of the canvas element from which to read, or an HTMLCanvasElement instance'))):this.fire(new a.ErrorEvent(new a.ValidationError(`sources.${y}`,null,'missing required property "canvas"'))),this.options=h,this.animate=h.animate===void 0||h.animate}load(){this._loaded=!0,this.canvas||(this.canvas=this.options.canvas instanceof a.window.HTMLCanvasElement?this.options.canvas:a.window.document.getElementById(this.options.canvas)),this.width=this.canvas.width,this.height=this.canvas.height,this._hasInvalidDimensions()?this.fire(new a.ErrorEvent(new Error("Canvas dimensions cannot be less than or equal to zero."))):(this.play=function(){this._playing=!0,this.map.triggerRepaint()},this.pause=function(){this._playing&&(this.prepare(),this._playing=!1)},this._finishLoading())}getCanvas(){return this.canvas}onAdd(y){this.map=y,this.load(),this.canvas&&this.animate&&this.play()}onRemove(){this.pause()}prepare(){let y=!1;if(this.canvas.width!==this.width&&(this.width=this.canvas.width,y=!0),this.canvas.height!==this.height&&(this.height=this.canvas.height,y=!0),this._hasInvalidDimensions()||Object.keys(this.tiles).length===0)return;const h=this.map.painter.context;this.texture?(y||this._playing)&&this.texture.update(this.canvas,{premultiply:!0}):this.texture=new a.Texture(h,this.canvas,h.gl.RGBA,{premultiply:!0}),this._prepareData(h)}serialize(){return{type:"canvas",coordinates:this.coordinates}}hasTransition(){return this._playing}_hasInvalidDimensions(){for(const y of[this.canvas.width,this.canvas.height])if(isNaN(y)||y<=0)return!0;return!1}},custom:class extends a.Evented{constructor(y,h,f,v){super(),this.id=y,this.type="custom",this._dataType="raster",this._dispatcher=f,this._implementation=h,this.setEventedParent(v),this.scheme="xyz",this.minzoom=0,this.maxzoom=22,this.tileSize=512,this._loaded=!1,this.roundZoom=!0,this._implementation||this.fire(new a.ErrorEvent(new Error(`Missing implementation for ${this.id} custom source`))),this._implementation.loadTile||this.fire(new a.ErrorEvent(new Error(`Missing loadTile implementation for ${this.id} custom source`))),this._implementation.bounds&&(this.tileBounds=new je(this._implementation.bounds,this.minzoom,this.maxzoom)),h.update=this._update.bind(this),h.clearTiles=this._clearTiles.bind(this),h.coveringTiles=this._coveringTiles.bind(this),a.extend(this,a.pick(h,["dataType","scheme","minzoom","maxzoom","tileSize","attribution","minTileCacheSize","maxTileCacheSize"]))}serialize(){return a.pick(this,["type","scheme","minzoom","maxzoom","tileSize","attribution"])}load(){this._loaded=!0,this.fire(new a.Event("data",{dataType:"source",sourceDataType:"metadata"})),this.fire(new a.Event("data",{dataType:"source",sourceDataType:"content"}))}loaded(){return this._loaded}onAdd(y){this._map=y,this._loaded=!1,this.fire(new a.Event("dataloading",{dataType:"source"})),this._implementation.onAdd&&this._implementation.onAdd(y),this.load()}onRemove(y){this._implementation.onRemove&&this._implementation.onRemove(y)}hasTile(y){if(this._implementation.hasTile){const{x:h,y:f,z:v}=y.canonical;return this._implementation.hasTile({x:h,y:f,z:v})}return!this.tileBounds||this.tileBounds.contains(y.canonical)}loadTile(y,h){const{x:f,y:v,z:w}=y.tileID.canonical,S=new a.window.AbortController;y.request=Promise.resolve(this._implementation.loadTile({x:f,y:v,z:w},{signal:S.signal})).then(function(I){return delete y.request,y.aborted?(y.state="unloaded",h(null)):I===void 0?(y.state="errored",h(null)):I===null?(this.loadTileData(y,{width:this.tileSize,height:this.tileSize,data:null}),y.state="loaded",h(null)):function(L){return L instanceof a.window.ImageData||L instanceof a.window.HTMLCanvasElement||L instanceof a.window.ImageBitmap||L instanceof a.window.HTMLImageElement}(I)?(this.loadTileData(y,I),y.state="loaded",void h(null)):(y.state="errored",h(new Error(`Can't infer data type for ${this.id}, only raster data supported at the moment`)))}.bind(this)).catch(I=>{I.code!==20&&(y.state="errored",h(I))}),y.request.cancel=()=>S.abort()}loadTileData(y,h){Kt.loadTileData(y,h,this._map.painter)}unloadTileData(y){Kt.unloadTileData(y,this._map.painter)}unloadTile(y,h){if(this.unloadTileData(y),this._implementation.unloadTile){const{x:f,y:v,z:w}=y.tileID.canonical;this._implementation.unloadTile({x:f,y:v,z:w})}h()}abortTile(y,h){y.request&&y.request.cancel&&(y.request.cancel(),delete y.request),h()}hasTransition(){return!1}_coveringTiles(){return this._map.transform.coveringTiles({tileSize:this.tileSize,minzoom:this.minzoom,maxzoom:this.maxzoom,roundZoom:this.roundZoom}).map(y=>({x:y.canonical.x,y:y.canonical.y,z:y.canonical.z}))}
120_clearTiles(){this._map.style._clearSource(this.id)}_update(){this.fire(new a.Event("data",{dataType:"source",sourceDataType:"content"}))}}},or=function(y,h,f,v){const w=new Yn[h.type](y,h,f,v);if(w.id!==y)throw new Error(`Expected Source id to be ${y} instead of ${w.id}`);return a.bindAll(["load","abort","unload","serialize","prepare"],w),w};function lr(y,h){const f=a.identity([]);return a.scale(f,f,[.5*y.width,.5*-y.height,1]),a.translate(f,f,[1,-1,0]),a.multiply(f,f,y.calculateProjMatrix(h.toUnwrapped())),Float32Array.from(f)}function Gr(y,h,f,v,w,S,I,L=!1){const z=y.tilesIn(v,I,L);z.sort(po);const H=[];for(const ee of z)H.push({wrappedTileID:ee.tile.tileID.wrapped().key,queryResults:ee.tile.queryRenderedFeatures(h,f,y._state,ee,w,S,lr(y.transform,ee.tile.tileID),L)});const q=function(ee){const de={},_e={};for(const be of ee){const ve=be.queryResults,Ee=be.wrappedTileID,te=_e[Ee]=_e[Ee]||{};for(const ye in ve){const Oe=ve[ye],Le=te[ye]=te[ye]||{},He=de[ye]=de[ye]||[];for(const Ze of Oe)Le[Ze.featureIndex]||(Le[Ze.featureIndex]=!0,He.push(Ze))}}return de}(H);for(const ee in q)q[ee].forEach(de=>{const _e=de.feature,be=_e.layer;be&&be.type!=="background"&&be.type!=="sky"&&(_e.source=be.source,be["source-layer"]&&(_e.sourceLayer=be["source-layer"]),_e.state=_e.id!==void 0?y.getFeatureState(be["source-layer"],_e.id):{})});return q}function Wi(y,h){const f=y.getRenderableIds().map(S=>y.getTileByID(S)),v=[],w={};for(let S=0;S<f.length;S++){const I=f[S],L=I.tileID.canonical.key;w[L]||(w[L]=!0,I.querySourceFeatures(v,h))}return v}function po(y,h){const f=y.tileID,v=h.tileID;return f.overscaledZ-v.overscaledZ||f.canonical.y-v.canonical.y||f.wrap-v.wrap||f.canonical.x-v.canonical.x}function $i(){return Ah.workerClass!=null?new Ah.workerClass:new a.window.Worker(Ah.workerUrl)}const ws="mapboxgl_preloaded_worker_pool";class Po{constructor(){this.active={}}acquire(h){if(!this.workers)for(this.workers=[];this.workers.length<Po.workerCount;)this.workers.push(new $i);return this.active[h]=!0,this.workers.slice()}release(h){delete this.active[h],this.numActive()===0&&(this.workers.forEach(f=>{f.terminate()}),this.workers=null)}isPreloaded(){return!!this.active[ws]}numActive(){return Object.keys(this.active).length}}let Hr;function Lc(){return Hr||(Hr=new Po),Hr}function Ig(y,h){const f={};for(const v in y)v!=="ref"&&(f[v]=y[v]);return a.refProperties.forEach(v=>{v in h&&(f[v]=h[v])}),f}function Cp(y){y=y.slice();const h=Object.create(null);for(let f=0;f<y.length;f++)h[y[f].id]=y[f];for(let f=0;f<y.length;f++)"ref"in y[f]&&(y[f]=Ig(y[f],h[y[f].ref]));return y}Po.workerCount=2;const Er={setStyle:"setStyle",addLayer:"addLayer",removeLayer:"removeLayer",setPaintProperty:"setPaintProperty",setLayoutProperty:"setLayoutProperty",setFilter:"setFilter",addSource:"addSource",removeSource:"removeSource",setGeoJSONSourceData:"setGeoJSONSourceData",setLayerZoomRange:"setLayerZoomRange",setLayerProperty:"setLayerProperty",setCenter:"setCenter",setZoom:"setZoom",setBearing:"setBearing",setPitch:"setPitch",setSprite:"setSprite",setGlyphs:"setGlyphs",setTransition:"setTransition",setLight:"setLight",setTerrain:"setTerrain",setFog:"setFog",setProjection:"setProjection"};function Ud(y,h,f){f.push({command:Er.addSource,args:[y,h[y]]})}function Jl(y,h,f){h.push({command:Er.removeSource,args:[y]}),f[y]=!0}function Vd(y,h,f,v){Jl(y,f,v),Ud(y,h,f)}function ec(y,h,f){let v;for(v in y[f])if(y[f].hasOwnProperty(v)&&v!=="data"&&!m(y[f][v],h[f][v]))return!1;for(v in h[f])if(h[f].hasOwnProperty(v)&&v!=="data"&&!m(y[f][v],h[f][v]))return!1;return!0}function $a(y,h,f,v,w,S){let I;for(I in h=h||{},y=y||{})y.hasOwnProperty(I)&&(m(y[I],h[I])||f.push({command:S,args:[v,I,h[I],w]}));for(I in h)h.hasOwnProperty(I)&&!y.hasOwnProperty(I)&&(m(y[I],h[I])||f.push({command:S,args:[v,I,h[I],w]}))}function is(y){return y.id}function eo(y,h){return y[h.id]=h,y}class hh{constructor(h,f){this.reset(h,f)}reset(h,f){this.points=h||[],this._distances=[0];for(let v=1;v<this.points.length;v++)this._distances[v]=this._distances[v-1]+this.points[v].dist(this.points[v-1]);this.length=this._distances[this._distances.length-1],this.padding=Math.min(f||0,.5*this.length),this.paddedLength=this.length-2*this.padding}lerp(h){if(this.points.length===1)return this.points[0];h=a.clamp(h,0,1);let f=1,v=this._distances[f];const w=h*this.paddedLength+this.padding;
vendor: 4,488 bytes, line 120
120for(;v<w&&f<this._distances.length;)v=this._distances[++f];const S=f-1,I=this._distances[S],L=v-I,z=L>0?(w-I)/L:0;return this.points[S].mult(1-z).add(this.points[f].mult(z))}}class vl{constructor(h,f,v){const w=this.boxCells=[],S=this.circleCells=[];this.xCellCount=Math.ceil(h/v),this.yCellCount=Math.ceil(f/v);for(let I=0;I<this.xCellCount*this.yCellCount;I++)w.push([]),S.push([]);this.circleKeys=[],this.boxKeys=[],this.bboxes=[],this.circles=[],this.width=h,this.height=f,this.xScale=this.xCellCount/h,this.yScale=this.yCellCount/f,this.boxUid=0,this.circleUid=0}keysLength(){return this.boxKeys.length+this.circleKeys.length}insert(h,f,v,w,S){this._forEachCell(f,v,w,S,this._insertBoxCell,this.boxUid++),this.boxKeys.push(h),this.bboxes.push(f),this.bboxes.push(v),this.bboxes.push(w),this.bboxes.push(S)}insertCircle(h,f,v,w){this._forEachCell(f-w,v-w,f+w,v+w,this._insertCircleCell,this.circleUid++),this.circleKeys.push(h),this.circles.push(f),this.circles.push(v),this.circles.push(w)}_insertBoxCell(h,f,v,w,S,I){this.boxCells[S].push(I)}_insertCircleCell(h,f,v,w,S,I){this.circleCells[S].push(I)}_query(h,f,v,w,S,I){if(v<0||h>this.width||w<0||f>this.height)return!S&&[];const L=[];if(h<=0&&f<=0&&this.width<=v&&this.height<=w){if(S)return!0;for(let z=0;z<this.boxKeys.length;z++)L.push({key:this.boxKeys[z],x1:this.bboxes[4*z],y1:this.bboxes[4*z+1],x2:this.bboxes[4*z+2],y2:this.bboxes[4*z+3]});for(let z=0;z<this.circleKeys.length;z++){const H=this.circles[3*z],q=this.circles[3*z+1],ee=this.circles[3*z+2];L.push({key:this.circleKeys[z],x1:H-ee,y1:q-ee,x2:H+ee,y2:q+ee})}return I?L.filter(I):L}return this._forEachCell(h,f,v,w,this._queryCell,L,{hitTest:S,seenUids:{box:{},circle:{}}},I),S?L.length>0:L}_queryCircle(h,f,v,w,S){const I=h-v,L=h+v,z=f-v,H=f+v;if(L<0||I>this.width||H<0||z>this.height)return!w&&[];const q=[];return this._forEachCell(I,z,L,H,this._queryCellCircle,q,{hitTest:w,circle:{x:h,y:f,radius:v},seenUids:{box:{},circle:{}}},S),w?q.length>0:q}query(h,f,v,w,S){return this._query(h,f,v,w,!1,S)}hitTest(h,f,v,w,S){return this._query(h,f,v,w,!0,S)}hitTestCircle(h,f,v,w){return this._queryCircle(h,f,v,!0,w)}_queryCell(h,f,v,w,S,I,L,z){const H=L.seenUids,q=this.boxCells[S];if(q!==null){const de=this.bboxes;for(const _e of q)if(!H.box[_e]){H.box[_e]=!0;const be=4*_e;if(h<=de[be+2]&&f<=de[be+3]&&v>=de[be+0]&&w>=de[be+1]&&(!z||z(this.boxKeys[_e]))){if(L.hitTest)return I.push(!0),!0;I.push({key:this.boxKeys[_e],x1:de[be],y1:de[be+1],x2:de[be+2],y2:de[be+3]})}}}const ee=this.circleCells[S];if(ee!==null){const de=this.circles;for(const _e of ee)if(!H.circle[_e]){H.circle[_e]=!0;const be=3*_e;if(this._circleAndRectCollide(de[be],de[be+1],de[be+2],h,f,v,w)&&(!z||z(this.circleKeys[_e]))){if(L.hitTest)return I.push(!0),!0;{const ve=de[be],Ee=de[be+1],te=de[be+2];I.push({key:this.circleKeys[_e],x1:ve-te,y1:Ee-te,x2:ve+te,y2:Ee+te})}}}}}_queryCellCircle(h,f,v,w,S,I,L,z){const H=L.circle,q=L.seenUids,ee=this.boxCells[S];if(ee!==null){const _e=this.bboxes;for(const be of ee)if(!q.box[be]){q.box[be]=!0;const ve=4*be;if(this._circleAndRectCollide(H.x,H.y,H.radius,_e[ve+0],_e[ve+1],_e[ve+2],_e[ve+3])&&(!z||z(this.boxKeys[be])))return I.push(!0),!0}}const de=this.circleCells[S];if(de!==null){const _e=this.circles;for(const be of de)if(!q.circle[be]){q.circle[be]=!0;const ve=3*be;if(this._circlesCollide(_e[ve],_e[ve+1],_e[ve+2],H.x,H.y,H.radius)&&(!z||z(this.circleKeys[be])))return I.push(!0),!0}}}_forEachCell(h,f,v,w,S,I,L,z){const H=this._convertToXCellCoord(h),q=this._convertToYCellCoord(f),ee=this._convertToXCellCoord(v),de=this._convertToYCellCoord(w);for(let _e=H;_e<=ee;_e++)for(let be=q;be<=de;be++)if(S.call(this,h,f,v,w,this.xCellCount*be+_e,I,L,z))return}_convertToXCellCoord(h){return Math.max(0,Math.min(this.xCellCount-1,Math.floor(h*this.xScale)))}_convertToYCellCoord(h){return Math.max(0,Math.min(this.yCellCount-1,Math.floor(h*this.yScale)))}_circlesCollide(h,f,v,w,S,I){const L=w-h,z=S-f,H=v+I;return H*H>L*L+z*z}_circleAndRectCollide(h,f,v,w,S,I,L){const z=(I-w)/2,H=Math.abs(h-(w+z));if(H>z+v)return!1;const q=(L-S)/2,ee=Math.abs(f-(S+q));if(ee>q+v)return!1;if(H<=z||ee<=q)return!0;const de=H-z,_e=ee-q;return de*de+_e*_e<=v*v}}const Wo={unknown:0,flipRequired:1,flipNotRequired:2},fa=Math.tan(85*Math.PI/180);function Pt(y,h,f,v,w,S,I){const L=a.create();if(f)if(S.name==="globe"){const z=a.calculateGlobeLabelMatrix(w,h);a.multiply(L,L,z)}else{const z=Y([],I);L[0]=z[0],L[1]=z[1],L[4]=z[2],L[5]=z[3],v||a.rotateZ(L,L,w.angle)}
120else a.multiply(L,w.labelPlaneMatrix,y);return L}function ta(y,h,f,v,w,S,I){const L=Pt(y,h,f,v,w,S,I);return S.name==="globe"&&f||(L[2]=L[6]=L[10]=L[14]=0),L}function ci(y,h,f,v,w,S,I){if(f){if(S.name==="globe"){const L=Pt(y,h,f,v,w,S,I);return a.invert(L,L),a.multiply(L,y,L),L}{const L=a.clone(y),z=a.identity([]);return z[0]=I[0],z[1]=I[1],z[4]=I[2],z[5]=I[3],a.multiply(L,L,z),v||a.rotateZ(L,L,-w.angle),L}}return w.glCoordMatrix}function mo(y,h,f,v){const w=[y,h,f,1];f?a.transformMat4$1(w,w,v):tr(w,w,v);const S=w[3];return w[0]/=S,w[1]/=S,w[2]/=S,w}function kp(y,h){return Math.min(.5+y/h*.5,1.5)}function Ts(y,h){const f=y[0]/y[3],v=y[1]/y[3];return f>=-h[0]&&f<=h[0]&&v>=-h[1]&&v<=h[1]}function Gd(y,h,f,v,w,S,I,L,z,H){const q=f.transform,ee=v?y.textSizeData:y.iconSizeData,de=a.evaluateSizeForZoom(ee,f.transform.zoom),_e=q.projection.name==="globe",be=[256/f.width*2+1,256/f.height*2+1],ve=v?y.text.dynamicLayoutVertexArray:y.icon.dynamicLayoutVertexArray;ve.clear();let Ee=null;_e&&(Ee=v?y.text.globeExtVertexArray:y.icon.globeExtVertexArray);const te=y.lineVertexArray,ye=v?y.text.placedSymbolArray:y.icon.placedSymbolArray,Oe=f.transform.width/f.transform.height;let Le,He=!1;for(let Ze=0;Ze<ye.length;Ze++){const Ye=ye.get(Ze),{numGlyphs:ot,writingMode:et}=Ye;if(et!==a.WritingMode.vertical||He||Le===a.WritingMode.horizontal||(He=!0),Le=et,(Ye.hidden||et===a.WritingMode.vertical)&&!He){os(ot,ve);continue}He=!1;const _t=new a.Point(Ye.tileAnchorX,Ye.tileAnchorY);let{x:Zt,y:dt,z:Bt}=q.projection.projectTilePoint(_t.x,_t.y,H.canonical);if(z){const[Wn,wn,Bn]=z(_t);Zt+=Wn,dt+=wn,Bt+=Bn}const St=[Zt,dt,Bt,1];if(a.transformMat4$1(St,St,h),!Ts(St,be)){os(ot,ve);continue}const Yt=kp(f.transform.cameraToCenterDistance,St[3]),gt=a.evaluateSizeForFeature(ee,de,Ye),Ft=I?gt/Yt:gt*Yt,Jt=mo(Zt,dt,Bt,w);if(Jt[3]<=0){os(ot,ve);continue}let Ut={};const tn=I?null:z,Mn=dn(Ye,Ft,!1,L,h,w,S,y.glyphOffsetArray,te,ve,Ee,Jt,_t,Ut,Oe,tn,q.projection,H,I);He=Mn.useVertical,tn&&Mn.needsFlipping&&(Ut={}),(Mn.notEnoughRoom||He||Mn.needsFlipping&&dn(Ye,Ft,!0,L,h,w,S,y.glyphOffsetArray,te,ve,Ee,Jt,_t,Ut,Oe,tn,q.projection,H,I).notEnoughRoom)&&os(ot,ve)}v?(y.text.dynamicLayoutVertexBuffer.updateData(ve),Ee&&y.text.globeExtVertexBuffer.updateData(Ee)):(y.icon.dynamicLayoutVertexBuffer.updateData(ve),Ee&&y.icon.globeExtVertexBuffer.updateData(Ee))}function qd(y,h,f,v,w,S,I,L,z,H,q,ee,de,_e,be,ve){const{lineStartIndex:Ee,glyphStartIndex:te,segment:ye}=L,Oe=te+L.numGlyphs,Le=Ee+L.lineLength,He=h.getoffsetX(te),Ze=h.getoffsetX(Oe-1),Ye=Aa(y*He,f,v,w,S,I,ye,Ee,Le,z,H,q,ee,de,!0,_e,be,ve);if(!Ye)return null;const ot=Aa(y*Ze,f,v,w,S,I,ye,Ee,Le,z,H,q,ee,de,!0,_e,be,ve);return ot?{first:Ye,last:ot}:null}function bl(y,h,f,v){return y===a.WritingMode.horizontal&&Math.abs(v)>Math.abs(f)?{useVertical:!0}:y===a.WritingMode.vertical?v>0?{needsFlipping:!0}:null:h!==Wo.unknown&&function(w,S){return w===0||Math.abs(S/w)>fa}(f,v)?h===Wo.flipRequired?{needsFlipping:!0}:null:f<0?{needsFlipping:!0}:null}function dn(y,h,f,v,w,S,I,L,z,H,q,ee,de,_e,be,ve,Ee,te,ye){const Oe=h/24,Le=y.lineOffsetX*Oe,He=y.lineOffsetY*Oe,{lineStartIndex:Ze,glyphStartIndex:Ye,numGlyphs:ot,segment:et,writingMode:_t,flipState:Zt}=y,dt=Ze+y.lineLength,Bt=St=>{if(q){const[Jt,Ut,tn]=St.up,Mn=H.length;a.updateGlobeVertexNormal(q,Mn+0,Jt,Ut,tn),a.updateGlobeVertexNormal(q,Mn+1,Jt,Ut,tn),a.updateGlobeVertexNormal(q,Mn+2,Jt,Ut,tn),a.updateGlobeVertexNormal(q,Mn+3,Jt,Ut,tn)}const[Yt,gt,Ft]=St.point;a.addDynamicAttributes(H,Yt,gt,Ft,St.angle)};if(ot>1){const St=qd(Oe,L,Le,He,f,ee,de,y,z,S,_e,ve,!1,Ee,te,ye);if(!St)return{notEnoughRoom:!0};if(v&&!f){let[Yt,gt,Ft]=St.first.point,[Jt,Ut,tn]=St.last.point;[Yt,gt]=mo(Yt,gt,Ft,I),[Jt,Ut]=mo(Jt,Ut,tn,I);const Mn=bl(_t,Zt,(Jt-Yt)*be,Ut-gt);if(y.flipState=Mn&&Mn.needsFlipping?Wo.flipRequired:Wo.flipNotRequired,Mn)return Mn}Bt(St.first);for(let Yt=Ye+1;Yt<Ye+ot-1;Yt++){const gt=Aa(Oe*L.getoffsetX(Yt),Le,He,f,ee,de,et,Ze,dt,z,S,_e,ve,!1,!1,Ee,te,ye);if(!gt)return H.length-=4*(Yt-Ye),{notEnoughRoom:!0};Bt(gt)}Bt(St.last)}else{if(v&&!f){const Yt=mo(de.x,de.y,0,w),gt=Ze+et+1,Ft=new a.Point(z.getx(gt),z.gety(gt)),Jt=mo(Ft.x,Ft.y,0,w),Ut=Jt[3]>0?Jt:cr(de,Ft,Yt,1,w,void 0,Ee,te.canonical),tn=bl(_t,Zt,(Ut[0]-Yt[0])*be,Ut[1]-Yt[1]);if(y.flipState=tn&&tn.needsFlipping?Wo.flipRequired:Wo.flipNotRequired,tn)return tn}const St=Aa(Oe*L.getoffsetX(Ye),Le,He,f,ee,de,et,Ze,dt,z,S,_e,ve,!1,!1,Ee,te,ye);if(!St)return{notEnoughRoom:!0};Bt(St)}return{}}function fr(y,h,f,v,w){const{x:S,y:I,z:L}=v.projectTilePoint(y.x,y.y,h);if(!w)return mo(S,I,L,f);const[z,H,q]=w(y);return mo(S+z,I+H,L+q,f)}function cr(y,h,f,v,w,S,I,L){const z=fr(y.sub(h)._unit()._add(y),L,w,I,S);return a.sub(z,f,z),a.normalize(z,z),a.scaleAndAdd(z,f,z,v)}function Aa(y,h,f,v,w,S,I,L,z,H,q,ee,de,_e,be,ve,Ee,te){const ye=v?y-h:y+h;let Oe=ye>0?1:-1,Le=0;v&&(Oe*=-1,Le=Math.PI),Oe<0&&(Le+=Math.PI);let He=L+I+(Oe>0?0:1)|0,Ze=w,Ye=w,ot=0,et=0;const _t=Math.abs(ye),Zt=[],dt=[];let Bt=S,St=Bt;const Yt=()=>cr(St,Bt,Ye,_t-ot+1,q,de,ve,Ee.canonical);for(;ot+et<=_t;){if(He+=Oe,He<L||He>=z)return null;if(Ye=Ze,St=Bt,Zt.push(Ye),_e&&dt.push(St),Bt=new a.Point(H.getx(He),H.gety(He)),Ze=ee[He],!Ze){const Bn=fr(Bt,Ee.canonical,q,ve,de);Ze=Bn[3]>0?ee[He]=Bn:Yt()}ot+=et,et=a.distance(Ye,Ze)}be&&de&&(ee[He]&&(Ze=Yt(),et=a.distance(Ye,Ze)),ee[He]=Ze);const gt=(_t-ot)/et,Ft=Bt.sub(St)._mult(gt)._add(St),Jt=a.sub([],Ze,Ye),Ut=a.scaleAndAdd([],Ye,Jt,gt);let tn=[0,0,1],Mn=Jt[0],Wn=Jt[1];if(te&&(tn=ve.upVector(Ee.canonical,Ft.x,Ft.y),tn[0]!==0||tn[1]!==0||tn[2]!==1)){const Bn=[tn[2],0,-tn[0]],mr=a.cross([],tn,Bn);a.normalize(Bn,Bn),a.normalize(mr,mr),Mn=a.dot(Jt,Bn),Wn=a.dot(Jt,mr)}if(f){const Bn=a.cross([],tn,Jt);a.normalize(Bn,Bn),a.scaleAndAdd(Ut,Ut,Bn,f*Oe)}const wn=Le+Math.atan2(Wn,Mn);return Zt.push(Ut),_e&&dt.push(Ft),{point:Ut,angle:wn,path:Zt,tilePath:dt,up:tn}}function os(y,h){const f=h.length,v=f+4*y;h.resize(v),h.float32.fill(-1/0,4*f,4*v)}function tr(y,h,f){const v=h[0],w=h[1];
120return y[0]=f[0]*v+f[4]*w+f[12],y[1]=f[1]*v+f[5]*w+f[13],y[3]=f[3]*v+f[7]*w+f[15],y}const O=100;class G{constructor(h,f,v=new vl(h.width+200,h.height+200,25),w=new vl(h.width+200,h.height+200,25)){this.transform=h,this.grid=v,this.ignoredGrid=w,this.pitchfactor=Math.cos(h._pitch)*h.cameraToCenterDistance,this.screenRightBoundary=h.width+O,this.screenBottomBoundary=h.height+O,this.gridRightBoundary=h.width+200,this.gridBottomBoundary=h.height+200,this.fogState=f}placeCollisionBox(h,f,v,w,S,I,L,z){let H=v.projectedAnchorX,q=v.projectedAnchorY,ee=v.projectedAnchorZ;const de=v.elevation,_e=v.tileID,be=h.getProjection();if(de&&_e){const[Ze,Ye,ot]=be.upVector(_e.canonical,v.tileAnchorX,v.tileAnchorY),et=be.upVectorScale(_e.canonical,this.transform.center.lat,this.transform.worldSize).metersToTile;H+=Ze*de*et,q+=Ye*de*et,ee+=ot*de*et}const ve=this.projectAndGetPerspectiveRatio(L,H,q,ee,v.tileID,be.name==="globe"||!!de||this.transform.pitch>0,be),Ee=I*ve.perspectiveRatio,te=(v.x1*f+w.x-v.padding)*Ee+ve.point.x,ye=(v.y1*f+w.y-v.padding)*Ee+ve.point.y,Oe=(v.x2*f+w.x+v.padding)*Ee+ve.point.x,Le=(v.y2*f+w.y+v.padding)*Ee+ve.point.y,He=ve.perspectiveRatio<=.55||ve.occluded;return!this.isInsideGrid(te,ye,Oe,Le)||!S&&this.grid.hitTest(te,ye,Oe,Le,z)||He?{box:[],offscreen:!1,occluded:ve.occluded}:{box:[te,ye,Oe,Le],offscreen:this.isOffscreen(te,ye,Oe,Le),occluded:!1}}placeCollisionCircles(h,f,v,w,S,I,L,z,H,q,ee,de,_e,be,ve){const Ee=[],te=this.transform.elevation,ye=h.getProjection(),Oe=te?te.getAtTileOffsetFunc(ve,this.transform.center.lat,this.transform.worldSize,ye):null,Le=new a.Point(v.tileAnchorX,v.tileAnchorY);let{x:He,y:Ze,z:Ye}=ye.projectTilePoint(Le.x,Le.y,ve.canonical);if(Oe){const[Ft,Jt,Ut]=Oe(Le);He+=Ft,Ze+=Jt,Ye+=Ut}const ot=ye.name==="globe",et=this.projectAndGetPerspectiveRatio(L,He,Ze,Ye,ve,ot||!!te||this.transform.pitch>0,ye),{perspectiveRatio:_t}=et,Zt=(ee?I/_t:I*_t)/a.ONE_EM,dt=mo(He,Ze,Ye,z),Bt=et.signedDistanceFromCamera>0?qd(Zt,S,v.lineOffsetX*Zt,v.lineOffsetY*Zt,!1,dt,Le,v,w,z,{},te&&!ee?Oe:null,ee&&!!te,ye,ve,ee):null;let St=!1,Yt=!1,gt=!0;if(Bt&&!et.occluded){const Ft=.5*_e*_t+be,Jt=new a.Point(-100,-100),Ut=new a.Point(this.screenRightBoundary,this.screenBottomBoundary),tn=new hh,{first:Mn,last:Wn}=Bt,wn=Mn.path.length;let Bn=[];for(let Cn=wn-1;Cn>=1;Cn--)Bn.push(Mn.path[Cn]);for(let Cn=1;Cn<Wn.path.length;Cn++)Bn.push(Wn.path[Cn]);const mr=2.5*Ft;H&&(Bn=Bn.map(([Cn,Nr,Qr],Jr)=>(Oe&&!ot&&(Qr=Oe(Jr<wn-1?Mn.tilePath[wn-1-Jr]:Wn.tilePath[Jr-wn+2])[2]),mo(Cn,Nr,Qr,H))),Bn.some(Cn=>Cn[3]<=0)&&(Bn=[]));let pr=[];if(Bn.length>0){let Cn=1/0,Nr=-1/0,Qr=1/0,Jr=-1/0;for(const ei of Bn)Cn=Math.min(Cn,ei[0]),Qr=Math.min(Qr,ei[1]),Nr=Math.max(Nr,ei[0]),Jr=Math.max(Jr,ei[1]);Nr>=Jt.x&&Cn<=Ut.x&&Jr>=Jt.y&&Qr<=Ut.y&&(pr=[Bn.map(ei=>new a.Point(ei[0],ei[1]))],(Cn<Jt.x||Nr>Ut.x||Qr<Jt.y||Jr>Ut.y)&&(pr=a.clipLine(pr,Jt.x,Jt.y,Ut.x,Ut.y)))}for(const Cn of pr){tn.reset(Cn,.25*Ft);let Nr=0;Nr=tn.length<=.5*Ft?1:Math.ceil(tn.paddedLength/mr)+1;for(let Qr=0;Qr<Nr;Qr++){const Jr=Qr/Math.max(Nr-1,1),ei=tn.lerp(Jr),ya=ei.x+O,Yo=ei.y+O;Ee.push(ya,Yo,Ft,0);const Cs=ya-Ft,Ol=Yo-Ft,Mi=ya+Ft,ti=Yo+Ft;if(gt=gt&&this.isOffscreen(Cs,Ol,Mi,ti),Yt=Yt||this.isInsideGrid(Cs,Ol,Mi,ti),!f&&this.grid.hitTestCircle(ya,Yo,Ft,de)&&(St=!0,!q))return{circles:[],offscreen:!1,collisionDetected:St,occluded:!1}}}}return{circles:!q&&St||!Yt?[]:Ee,offscreen:gt,collisionDetected:St,occluded:et.occluded}}queryRenderedSymbols(h){if(h.length===0||this.grid.keysLength()===0&&this.ignoredGrid.keysLength()===0)return{};const f=[];let v=1/0,w=1/0,S=-1/0,I=-1/0;for(const q of h){const ee=new a.Point(q.x+O,q.y+O);v=Math.min(v,ee.x),w=Math.min(w,ee.y),S=Math.max(S,ee.x),I=Math.max(I,ee.y),f.push(ee)}const L=this.grid.query(v,w,S,I).concat(this.ignoredGrid.query(v,w,S,I)),z={},H={};for(const q of L){const ee=q.key;if(z[ee.bucketInstanceId]===void 0&&(z[ee.bucketInstanceId]={}),z[ee.bucketInstanceId][ee.featureIndex])continue;const de=[new a.Point(q.x1,q.y1),new a.Point(q.x2,q.y1),new a.Point(q.x2,q.y2),new a.Point(q.x1,q.y2)];a.polygonIntersectsPolygon(f,de)&&(z[ee.bucketInstanceId][ee.featureIndex]=!0,H[ee.bucketInstanceId]===void 0&&(H[ee.bucketInstanceId]=[]),H[ee.bucketInstanceId].push(ee.featureIndex))}return H}insertCollisionBox(h,f,v,w,S){(f?this.ignoredGrid:this.grid).insert({bucketInstanceId:v,featureIndex:w,collisionGroupID:S},h[0],h[1],h[2],h[3])}insertCollisionCircles(h,f,v,w,S){const I=f?this.ignoredGrid:this.grid,L={bucketInstanceId:v,featureIndex:w,collisionGroupID:S};for(let z=0;z<h.length;
120z+=4)I.insertCircle(L,h[z],h[z+1],h[z+2])}projectAndGetPerspectiveRatio(h,f,v,w,S,I,L){const z=[f,v,w,1];let H=!1;w||this.transform.pitch>0?(a.transformMat4$1(z,z,h),this.fogState&&S&&L.name!=="globe"&&(H=function(de,_e,be,ve,Ee,te){const ye=te.calculateFogTileMatrix(Ee),Oe=[_e,be,ve];return a.transformMat4(Oe,Oe,ye),Te(de,Oe,te.pitch,te._fov)}(this.fogState,f,v,w,S.toUnwrapped(),this.transform)>.9)):tr(z,z,h);const q=z[3];return{point:new a.Point((z[0]/q+1)/2*this.transform.width+O,(-z[1]/q+1)/2*this.transform.height+O),perspectiveRatio:Math.min(.5+this.transform.getCameraToCenterDistance(L)/q*.5,1.5),signedDistanceFromCamera:q,occluded:I&&z[2]>q||H}}isOffscreen(h,f,v,w){return v<O||h>=this.screenRightBoundary||w<O||f>this.screenBottomBoundary}isInsideGrid(h,f,v,w){return v>=0&&h<this.gridRightBoundary&&w>=0&&f<this.gridBottomBoundary}getViewportMatrix(){const h=a.identity([]);return a.translate(h,h,[-100,-100,0]),h}}function he(y,h,f){const v=h.createTileMatrix(y,y.worldSize,f.toUnwrapped());return a.multiply(new Float32Array(16),y.projMatrix,v)}function Re(y,h,f){if(h.projection.name===f.projection.name)return y.projMatrix;const v=f.clone();return v.setProjection(h.projection),he(v,h.getProjection(),y)}function Ve(y,h,f){return h.name===f.projection.name?y.projMatrix:he(f,h,y)}class Qe{constructor(h,f,v,w){this.opacity=h?Math.max(0,Math.min(1,h.opacity+(h.placed?f:-f))):w&&v?1:0,this.placed=v}isHidden(){return this.opacity===0&&!this.placed}}class it{constructor(h,f,v,w,S,I=!1){this.text=new Qe(h?h.text:null,f,v,S),this.icon=new Qe(h?h.icon:null,f,w,S),this.clipped=I}isHidden(){return this.text.isHidden()&&this.icon.isHidden()}}class Qt{constructor(h,f,v,w=!1){this.text=h,this.icon=f,this.skipFade=v,this.clipped=w}}class on{constructor(){this.invProjMatrix=a.create(),this.viewportMatrix=a.create(),this.circles=[]}}class _n{constructor(h,f,v,w,S){this.bucketInstanceId=h,this.featureIndex=f,this.sourceLayerIndex=v,this.bucketIndex=w,this.tileID=S}}class bn{constructor(h){this.crossSourceCollisions=h,this.maxGroupID=0,this.collisionGroups={}}get(h){if(this.crossSourceCollisions)return{ID:0,predicate:null};if(!this.collisionGroups[h]){const f=++this.maxGroupID;this.collisionGroups[h]={ID:f,predicate:v=>v.collisionGroupID===f}}return this.collisionGroups[h]}}function cn(y,h,f,v,w){const{horizontalAlign:S,verticalAlign:I}=a.getAnchorAlignment(y),L=-(S-.5)*h,z=-(I-.5)*f,H=a.evaluateVariableOffset(y,v);return new a.Point(L+H[0]*w,z+H[1]*w)}function qn(y,h,f,v,w){const S=new a.Point(y,h);return f&&S._rotate(v?w:-w),S}class vi{constructor(h,f,v,w,S){this.transform=h.clone(),this.projection=h.projection.name,this.collisionIndex=new G(this.transform,S),this.placements={},this.opacities={},this.variableOffsets={},this.stale=!1,this.commitTime=0,this.fadeDuration=f,this.retainedQueryData={},this.collisionGroups=new bn(v),this.collisionCircleArrays={},this.prevPlacement=w,w&&(w.prevPlacement=void 0),this.placedOrientations={}}getBucketParts(h,f,v,w){const S=v.getBucket(f),I=v.latestFeatureIndex;if(!S||!I||f.id!==S.layerIds[0])return;const L=S.layers[0].layout,z=v.collisionBoxArray,H=Math.pow(2,this.transform.zoom-v.tileID.overscaledZ),q=v.tileSize/a.EXTENT,ee=v.tileID.toUnwrapped();this.transform.setProjection(S.projection);const de=(_e=v.tileID,be=S.getProjection(),ve=this.transform,be.name===this.projection?ve.calculateProjMatrix(_e.toUnwrapped()):he(ve,be,_e));var _e,be,ve;const Ee=L.get("text-pitch-alignment")==="map",te=L.get("text-rotation-alignment")==="map";f.compileFilter();const ye=f.dynamicFilter(),Oe=f.dynamicFilterNeedsFeature(),Le=this.transform.calculatePixelsToTileUnitsMatrix(v),He=ta(de,v.tileID.canonical,Ee,te,this.transform,S.getProjection(),Le);let Ze=null;if(Ee){const et=ci(de,v.tileID.canonical,Ee,te,this.transform,S.getProjection(),Le);Ze=a.multiply([],this.transform.labelPlaneMatrix,et)}let Ye=null;ye&&v.latestFeatureIndex&&(Ye={unwrappedTileID:ee,dynamicFilter:ye,dynamicFilterNeedsFeature:Oe,featureIndex:v.latestFeatureIndex}),this.retainedQueryData[S.bucketInstanceId]=new _n(S.bucketInstanceId,I,S.sourceLayerIndex,S.index,v.tileID);
120const ot={bucket:S,layout:L,posMatrix:de,textLabelPlaneMatrix:He,labelToScreenMatrix:Ze,clippingData:Ye,scale:H,textPixelRatio:q,holdingForFade:v.holdingForFade(),collisionBoxArray:z,partiallyEvaluatedTextSize:a.evaluateSizeForZoom(S.textSizeData,this.transform.zoom),partiallyEvaluatedIconSize:a.evaluateSizeForZoom(S.iconSizeData,this.transform.zoom),collisionGroup:this.collisionGroups.get(S.sourceID)};if(w)for(const et of S.sortKeyRanges){const{sortKey:_t,symbolInstanceStart:Zt,symbolInstanceEnd:dt}=et;h.push({sortKey:_t,symbolInstanceStart:Zt,symbolInstanceEnd:dt,parameters:ot})}else h.push({symbolInstanceStart:0,symbolInstanceEnd:S.symbolInstances.length,parameters:ot})}attemptAnchorPlacement(h,f,v,w,S,I,L,z,H,q,ee,de,_e,be,ve,Ee,te,ye){const{textOffset0:Oe,textOffset1:Le,crossTileID:He}=de,Ze=[Oe,Le],Ye=cn(h,v,w,Ze,S),ot=this.collisionIndex.placeCollisionBox(be,S,f,qn(Ye.x,Ye.y,I,L,this.transform.angle),ee,z,H,q.predicate);if(Ee){const et=be.getSymbolInstanceIconSize(ye,this.transform.zoom,de.placedIconSymbolIndex);if(this.collisionIndex.placeCollisionBox(be,et,Ee,qn(Ye.x,Ye.y,I,L,this.transform.angle),ee,z,H,q.predicate).box.length===0)return}if(ot.box.length>0){let et;return this.prevPlacement&&this.prevPlacement.variableOffsets[He]&&this.prevPlacement.placements[He]&&this.prevPlacement.placements[He].text&&(et=this.prevPlacement.variableOffsets[He].anchor),this.variableOffsets[He]={textOffset:Ze,width:v,height:w,anchor:h,textScale:S,prevAnchor:et},this.markUsedJustification(be,h,de,ve),be.allowVerticalPlacement&&(this.markUsedOrientation(be,ve,de),this.placedOrientations[He]=ve),{shift:Ye,placedGlyphBoxes:ot}}}placeLayerBucketPart(h,f,v,w){const{bucket:S,layout:I,posMatrix:L,textLabelPlaneMatrix:z,labelToScreenMatrix:H,clippingData:q,textPixelRatio:ee,holdingForFade:de,collisionBoxArray:_e,partiallyEvaluatedTextSize:be,partiallyEvaluatedIconSize:ve,collisionGroup:Ee}=h.parameters,te=I.get("text-optional"),ye=I.get("icon-optional"),Oe=I.get("text-allow-overlap"),Le=I.get("icon-allow-overlap"),He=I.get("text-rotation-alignment")==="map",Ze=I.get("text-pitch-alignment")==="map",Ye=I.get("icon-text-fit")!=="none",ot=I.get("symbol-z-order")==="viewport-y";this.transform.setProjection(S.projection);let et=Oe&&(Le||!S.hasIconData()||ye),_t=Le&&(Oe||!S.hasTextData()||te);!S.collisionArrays&&_e&&S.deserializeCollisionBoxes(_e),v&&w&&S.updateCollisionDebugBuffers(this.transform.zoom,_e);const Zt=(dt,Bt,St)=>{const{crossTileID:Yt,numVerticalGlyphVertices:gt}=dt;if(q){const Mi={zoom:this.transform.zoom,pitch:this.transform.pitch};let ti=null;if(q.dynamicFilterNeedsFeature){const Mr=this.retainedQueryData[S.bucketInstanceId];ti=q.featureIndex.loadFeature({featureIndex:dt.featureIndex,bucketIndex:Mr.bucketIndex,sourceLayerIndex:Mr.sourceLayerIndex,layoutVertexArrayOffset:0})}if(!(0,q.dynamicFilter)(Mi,ti,this.retainedQueryData[S.bucketInstanceId].tileID.canonical,new a.Point(dt.tileAnchorX,dt.tileAnchorY),this.transform.calculateDistanceTileData(q.unwrappedTileID)))return this.placements[Yt]=new Qt(!1,!1,!1,!0),void f.add(Yt)}if(f.has(Yt))return;if(de)return void(this.placements[Yt]=new Qt(!1,!1,!1));let Ft=!1,Jt=!1,Ut=!0,tn=!1,Mn=!1,Wn=null,wn={box:null,offscreen:null,occluded:null},Bn={box:null,offscreen:null,occluded:null},mr=null,pr=null,Cn=null,Nr=0,Qr=0,Jr=0;St.textFeatureIndex?Nr=St.textFeatureIndex:dt.useRuntimeCollisionCircles&&(Nr=dt.featureIndex),St.verticalTextFeatureIndex&&(Qr=St.verticalTextFeatureIndex);const ei=Mi=>{Mi.tileID=this.retainedQueryData[S.bucketInstanceId].tileID;const ti=this.transform.elevation;(ti||Mi.elevation)&&(Mi.elevation=ti?ti.getAtTileOffset(Mi.tileID,Mi.tileAnchorX,Mi.tileAnchorY):0)},ya=St.textBox;if(ya){ei(ya);const Mi=Mr=>{let go=a.WritingMode.horizontal;if(S.allowVerticalPlacement&&!Mr&&this.prevPlacement){const Ia=this.prevPlacement.placedOrientations[Yt];Ia&&(this.placedOrientations[Yt]=Ia,go=Ia,this.markUsedOrientation(S,go,dt))}return go},ti=(Mr,go)=>{if(S.allowVerticalPlacement&&gt>0&&St.verticalTextBox){for(const Ia of S.writingModes)if(Ia===a.WritingMode.vertical?(wn=go(),Bn=wn):wn=Mr(),wn&&wn.box&&wn.box.length)break}else wn=Mr()};if(I.get("text-variable-anchor")){let Mr=I.get("text-variable-anchor");if(this.prevPlacement&&this.prevPlacement.variableOffsets[Yt]){const Ti=this.prevPlacement.variableOffsets[Yt];Mr.indexOf(Ti.anchor)>0&&(Mr=Mr.filter(Wa=>Wa!==Ti.anchor),Mr.unshift(Ti.anchor))}const go=(Ti,Wa,Vp)=>{const Ru=S.getSymbolInstanceTextSize(be,dt,this.transform.zoom,Bt),pf=(Ti.x2-Ti.x1)*Ru+2*Ti.padding,cc=(Ti.y2-Ti.y1)*Ru+2*Ti.padding,qc=Ye&&!Le?Wa:null;qc&&ei(qc);let Fu={box:[],offscreen:!1,occluded:!1};const Gp=Oe?2*Mr.length:Mr.length;for(let mf=0;mf<Gp;++mf){const Xg=this.attemptAnchorPlacement(Mr[mf%Mr.length],Ti,pf,cc,Ru,He,Ze,ee,L,Ee,mf>=Mr.length,dt,Bt,S,Vp,qc,be,ve);if(Xg&&(Fu=Xg.placedGlyphBoxes,Fu&&Fu.box&&Fu.box.length)){Ft=!0,Wn=Xg.shift;break}}return Fu};ti(()=>go(ya,St.iconBox,a.WritingMode.horizontal),()=>{const Ti=St.verticalTextBox;return Ti&&ei(Ti),S.allowVerticalPlacement&&!(wn&&wn.box&&wn.box.length)&&gt>0&&Ti?go(Ti,St.verticalIconBox,a.WritingMode.vertical):{box:null,offscreen:null,occluded:null}}),wn&&(Ft=wn.box,Ut=wn.offscreen,tn=wn.occluded);const Ia=Mi(!(!wn||!wn.box));if(!Ft&&this.prevPlacement){const Ti=this.prevPlacement.variableOffsets[Yt];Ti&&(this.variableOffsets[Yt]=Ti,this.markUsedJustification(S,Ti.anchor,dt,Ia))}}else{const Mr=(go,Ia)=>{const Ti=S.getSymbolInstanceTextSize(be,dt,this.transform.zoom,Bt),Wa=this.collisionIndex.placeCollisionBox(S,Ti,go,new a.Point(0,0),Oe,ee,L,Ee.predicate);return Wa&&Wa.box&&Wa.box.length&&(this.markUsedOrientation(S,Ia,dt),this.placedOrientations[Yt]=Ia),Wa};ti(()=>Mr(ya,a.WritingMode.horizontal),()=>{const go=St.verticalTextBox;return S.allowVerticalPlacement&&gt>0&&go?(ei(go),Mr(go,a.WritingMode.vertical)):{box:null,offscreen:null,occluded:null}}),Mi(!!(wn&&wn.box&&wn.box.length))}}if(mr=wn,Ft=mr&&mr.box&&mr.box.length>0,Ut=mr&&mr.offscreen,tn=mr&&mr.occluded,dt.useRuntimeCollisionCircles){const Mi=S.text.placedSymbolArray.get(dt.centerJustifiedTextSymbolIndex>=0?dt.centerJustifiedTextSymbolIndex:dt.verticalPlacedTextSymbolIndex),ti=a.evaluateSizeForFeature
vendor: 4,593 bytes, line 120
120(S.textSizeData,be,Mi),Mr=I.get("text-padding");pr=this.collisionIndex.placeCollisionCircles(S,Oe,Mi,S.lineVertexArray,S.glyphOffsetArray,ti,L,z,H,v,Ze,Ee.predicate,dt.collisionCircleDiameter*ti/a.ONE_EM,Mr,this.retainedQueryData[S.bucketInstanceId].tileID),Ft=Oe||pr.circles.length>0&&!pr.collisionDetected,Ut=Ut&&pr.offscreen,tn=pr.occluded}if(St.iconFeatureIndex&&(Jr=St.iconFeatureIndex),St.iconBox){const Mi=ti=>{ei(ti);const Mr=Ye&&Wn?qn(Wn.x,Wn.y,He,Ze,this.transform.angle):new a.Point(0,0),go=S.getSymbolInstanceIconSize(ve,this.transform.zoom,dt.placedIconSymbolIndex);return this.collisionIndex.placeCollisionBox(S,go,ti,Mr,Le,ee,L,Ee.predicate)};Bn&&Bn.box&&Bn.box.length&&St.verticalIconBox?(Cn=Mi(St.verticalIconBox),Jt=Cn.box.length>0):(Cn=Mi(St.iconBox),Jt=Cn.box.length>0),Ut=Ut&&Cn.offscreen,Mn=Cn.occluded}const Yo=te||dt.numHorizontalGlyphVertices===0&&gt===0,Cs=ye||dt.numIconVertices===0;if(Yo||Cs?Cs?Yo||(Jt=Jt&&Ft):Ft=Jt&&Ft:Jt=Ft=Jt&&Ft,Ft&&mr&&mr.box&&this.collisionIndex.insertCollisionBox(mr.box,I.get("text-ignore-placement"),S.bucketInstanceId,Bn&&Bn.box&&Qr?Qr:Nr,Ee.ID),Jt&&Cn&&this.collisionIndex.insertCollisionBox(Cn.box,I.get("icon-ignore-placement"),S.bucketInstanceId,Jr,Ee.ID),pr&&(Ft&&this.collisionIndex.insertCollisionCircles(pr.circles,I.get("text-ignore-placement"),S.bucketInstanceId,Nr,Ee.ID),v)){const Mi=S.bucketInstanceId;let ti=this.collisionCircleArrays[Mi];ti===void 0&&(ti=this.collisionCircleArrays[Mi]=new on);for(let Mr=0;Mr<pr.circles.length;Mr+=4)ti.circles.push(pr.circles[Mr+0]),ti.circles.push(pr.circles[Mr+1]),ti.circles.push(pr.circles[Mr+2]),ti.circles.push(pr.collisionDetected?1:0)}const Ol=S.projection.name!=="globe";et=et&&(Ol||!tn),_t=_t&&(Ol||!Mn),this.placements[Yt]=new Qt(Ft||et,Jt||_t,Ut||S.justReloaded),f.add(Yt)};if(ot){const dt=S.getSortedSymbolIndexes(this.transform.angle);for(let Bt=dt.length-1;Bt>=0;--Bt){const St=dt[Bt];Zt(S.symbolInstances.get(St),St,S.collisionArrays[St])}}else for(let dt=h.symbolInstanceStart;dt<h.symbolInstanceEnd;dt++)Zt(S.symbolInstances.get(dt),dt,S.collisionArrays[dt]);if(v&&S.bucketInstanceId in this.collisionCircleArrays){const dt=this.collisionCircleArrays[S.bucketInstanceId];a.invert(dt.invProjMatrix,L),dt.viewportMatrix=this.collisionIndex.getViewportMatrix()}S.justReloaded=!1}markUsedJustification(h,f,v,w){const{leftJustifiedTextSymbolIndex:S,centerJustifiedTextSymbolIndex:I,rightJustifiedTextSymbolIndex:L,verticalPlacedTextSymbolIndex:z,crossTileID:H}=v,q=a.getAnchorJustification(f),ee=w===a.WritingMode.vertical?z:q==="left"?S:q==="center"?I:q==="right"?L:-1;S>=0&&(h.text.placedSymbolArray.get(S).crossTileID=ee>=0&&S!==ee?0:H),I>=0&&(h.text.placedSymbolArray.get(I).crossTileID=ee>=0&&I!==ee?0:H),L>=0&&(h.text.placedSymbolArray.get(L).crossTileID=ee>=0&&L!==ee?0:H),z>=0&&(h.text.placedSymbolArray.get(z).crossTileID=ee>=0&&z!==ee?0:H)}markUsedOrientation(h,f,v){const w=f===a.WritingMode.horizontal||f===a.WritingMode.horizontalOnly?f:0,S=f===a.WritingMode.vertical?f:0,{leftJustifiedTextSymbolIndex:I,centerJustifiedTextSymbolIndex:L,rightJustifiedTextSymbolIndex:z,verticalPlacedTextSymbolIndex:H}=v,q=h.text.placedSymbolArray;I>=0&&(q.get(I).placedOrientation=w),L>=0&&(q.get(L).placedOrientation=w),z>=0&&(q.get(z).placedOrientation=w),H>=0&&(q.get(H).placedOrientation=S)}commit(h){this.commitTime=h,this.zoomAtLastRecencyCheck=this.transform.zoom;const f=this.prevPlacement;let v=!1;this.prevZoomAdjustment=f?f.zoomAdjustment(this.transform.zoom):0;const w=f?f.symbolFadeChange(h):1,S=f?f.opacities:{},I=f?f.variableOffsets:{},L=f?f.placedOrientations:{};for(const z in this.placements){const H=this.placements[z],q=S[z];q?(this.opacities[z]=new it(q,w,H.text,H.icon,null,H.clipped),v=v||H.text!==q.text.placed||H.icon!==q.icon.placed):(this.opacities[z]=new it(null,w,H.text,H.icon,H.skipFade,H.clipped),v=v||H.text||H.icon)}for(const z in S){const H=S[z];if(!this.opacities[z]){const q=new it(H,w,!1,!1);q.isHidden()||(this.opacities[z]=q,v=v||H.text.placed||H.icon.placed)}}for(const z in I)this.variableOffsets[z]||!this.opacities[z]||this.opacities[z].isHidden()||(this.variableOffsets[z]=I[z]);for(const z in L)this.placedOrientations[z]||!this.opacities[z]||this.opacities[z].isHidden()||(this.placedOrientations[z]=L[z]);v?this.lastPlacementChangeTime=h:typeof this.lastPlacementChangeTime!="number"&&(this.lastPlacementChangeTime=f?f.lastPlacementChangeTime:h)}updateLayerOpacities(h,f){const v=new Set;for(const w of f){const S=w.getBucket(h);S&&w.latestFeatureIndex&&h.id===S.layerIds[0]&&this.updateBucketOpacities(S,v,w.collisionBoxArray)}}
120updateBucketOpacities(h,f,v){h.hasTextData()&&h.text.opacityVertexArray.clear(),h.hasIconData()&&h.icon.opacityVertexArray.clear(),h.hasIconCollisionBoxData()&&h.iconCollisionBox.collisionVertexArray.clear(),h.hasTextCollisionBoxData()&&h.textCollisionBox.collisionVertexArray.clear();const w=h.layers[0].layout,S=!!h.layers[0].dynamicFilter(),I=new it(null,0,!1,!1,!0),L=w.get("text-allow-overlap"),z=w.get("icon-allow-overlap"),H=w.get("text-variable-anchor"),q=w.get("text-rotation-alignment")==="map",ee=w.get("text-pitch-alignment")==="map",de=w.get("icon-text-fit")!=="none",_e=new it(null,0,L&&(z||!h.hasIconData()||w.get("icon-optional")),z&&(L||!h.hasTextData()||w.get("text-optional")),!0);!h.collisionArrays&&v&&(h.hasIconCollisionBoxData()||h.hasTextCollisionBoxData())&&h.deserializeCollisionBoxes(v);const be=(Ee,te,ye)=>{for(let Oe=0;Oe<te/4;Oe++)Ee.opacityVertexArray.emplaceBack(ye)};let ve=0;for(let Ee=0;Ee<h.symbolInstances.length;Ee++){const te=h.symbolInstances.get(Ee),{numHorizontalGlyphVertices:ye,numVerticalGlyphVertices:Oe,crossTileID:Le,numIconVertices:He}=te,Ze=f.has(Le);let Ye=this.opacities[Le];Ze?Ye=I:Ye||(Ye=_e,this.opacities[Le]=Ye),f.add(Le);const ot=ye>0||Oe>0,et=He>0,_t=this.placedOrientations[Le],Zt=_t===a.WritingMode.vertical,dt=_t===a.WritingMode.horizontal||_t===a.WritingMode.horizontalOnly;if(!ot&&!et||Ye.isHidden()||ve++,ot){const Bt=xu(Ye.text);be(h.text,ye,Zt?Kn:Bt),be(h.text,Oe,dt?Kn:Bt);const St=Ye.text.isHidden(),{leftJustifiedTextSymbolIndex:Yt,centerJustifiedTextSymbolIndex:gt,rightJustifiedTextSymbolIndex:Ft,verticalPlacedTextSymbolIndex:Jt}=te,Ut=h.text.placedSymbolArray,tn=St||Zt?1:0;Yt>=0&&(Ut.get(Yt).hidden=tn),gt>=0&&(Ut.get(gt).hidden=tn),Ft>=0&&(Ut.get(Ft).hidden=tn),Jt>=0&&(Ut.get(Jt).hidden=St||dt?1:0);const Mn=this.variableOffsets[Le];Mn&&this.markUsedJustification(h,Mn.anchor,te,_t);const Wn=this.placedOrientations[Le];Wn&&(this.markUsedJustification(h,"left",te,Wn),this.markUsedOrientation(h,Wn,te))}if(et){const Bt=xu(Ye.icon),{placedIconSymbolIndex:St,verticalPlacedIconSymbolIndex:Yt}=te,gt=h.icon.placedSymbolArray,Ft=Ye.icon.isHidden()?1:0;St>=0&&(be(h.icon,He,Zt?Kn:Bt),gt.get(St).hidden=Ft),Yt>=0&&(be(h.icon,te.numVerticalIconVertices,dt?Kn:Bt),gt.get(Yt).hidden=Ft)}if(h.hasIconCollisionBoxData()||h.hasTextCollisionBoxData()){const Bt=h.collisionArrays[Ee];if(Bt){let St=new a.Point(0,0),Yt=!0;if(Bt.textBox||Bt.verticalTextBox){if(H){const Ft=this.variableOffsets[Le];Ft?(St=cn(Ft.anchor,Ft.width,Ft.height,Ft.textOffset,Ft.textScale),q&&St._rotate(ee?this.transform.angle:-this.transform.angle)):Yt=!1}S&&(Yt=!Ye.clipped),Bt.textBox&&Zn(h.textCollisionBox.collisionVertexArray,Ye.text.placed,!Yt||Zt,St.x,St.y),Bt.verticalTextBox&&Zn(h.textCollisionBox.collisionVertexArray,Ye.text.placed,!Yt||dt,St.x,St.y)}const gt=Yt&&!!(!dt&&Bt.verticalIconBox);Bt.iconBox&&Zn(h.iconCollisionBox.collisionVertexArray,Ye.icon.placed,gt,de?St.x:0,de?St.y:0),Bt.verticalIconBox&&Zn(h.iconCollisionBox.collisionVertexArray,Ye.icon.placed,!gt,de?St.x:0,de?St.y:0)}}}if(h.fullyClipped=ve===0,h.sortFeatures(this.transform.angle),this.retainedQueryData[h.bucketInstanceId]&&(this.retainedQueryData[h.bucketInstanceId].featureSortOrder=h.featureSortOrder),h.hasTextData()&&h.text.opacityVertexBuffer&&h.text.o
120pacityVertexBuffer.updateData(h.text.opacityVertexArray),h.hasIconData()&&h.icon.opacityVertexBuffer&&h.icon.opacityVertexBuffer.updateData(h.icon.opacityVertexArray),h.hasIconCollisionBoxData()&&h.iconCollisionBox.collisionVertexBuffer&&h.iconCollisionBox.collisionVertexBuffer.updateData(h.iconCollisionBox.collisionVertexArray),h.hasTextCollisionBoxData()&&h.textCollisionBox.collisionVertexBuffer&&h.textCollisionBox.collisionVertexBuffer.updateData(h.textCollisionBox.collisionVertexArray),h.bucketInstanceId in this.collisionCircleArrays){const Ee=this.collisionCircleArrays[h.bucketInstanceId];h.placementInvProjMatrix=Ee.invProjMatrix,h.placementViewportMatrix=Ee.viewportMatrix,h.collisionCircleArray=Ee.circles,delete this.collisionCircleArrays[h.bucketInstanceId]}}symbolFadeChange(h){return this.fadeDuration===0?1:(h-this.commitTime)/this.fadeDuration+this.prevZoomAdjustment}zoomAdjustment(h){return Math.max(0,(this.transform.zoom-h)/1.5)}hasTransitions(h){return this.stale||h-this.lastPlacementChangeTime<this.fadeDuration}stillRecent(h,f){const v=this.zoomAtLastRecencyCheck===f?1-this.zoomAdjustment(f):1;return this.zoomAtLastRecencyCheck=f,this.commitTime+this.fadeDuration*v>h}setStale(){this.stale=!0}}function Zn(y,h,f,v,w){y.emplaceBack(h?1:0,f?1:0,v||0,w||0),y.emplaceBack(h?1:0,f?1:0,v||0,w||0),y.emplaceBack(h?1:0,f?1:0,v||0,w||0),y.emplaceBack(h?1:0,f?1:0,v||0,w||0)}const Pr=Math.pow(2,25),Rt=Math.pow(2,24),An=Math.pow(2,17),Fr=Math.pow(2,16),Br=Math.pow(2,9),zr=Math.pow(2,8),dh=Math.pow(2,1);function xu(y){if(y.opacity===0&&!y.placed)return 0;if(y.opacity===1&&y.placed)return 4294967295;const h=y.placed?1:0,f=Math.floor(127*y.opacity);return f*Pr+h*Rt+f*An+h*Fr+f*Br+h*zr+f*dh+h}const Kn=0;class Rc{constructor(h){this._sortAcrossTiles=h.layout.get("symbol-z-order")!=="viewport-y"&&h.layout.get("symbol-sort-key").constantOr(1)!==void 0,this._currentTileIndex=0,this._currentPartIndex=0,this._seenCrossTileIDs=new Set,this._bucketParts=[]}continuePlacement(h,f,v,w,S){const I=this._bucketParts;for(;this._currentTileIndex<h.length;)if(f.getBucketParts(I,w,h[this._currentTileIndex],this._sortAcrossTiles),this._currentTileIndex++,S())return!0;for(this._sortAcrossTiles&&(this._sortAcrossTiles=!1,I.sort((L,z)=>L.sortKey-z.sortKey));this._currentPartIndex<I.length;){const L=I[this._currentPartIndex];if(f.placeLayerBucketPart(L,this._seenCrossTileIDs,v,L.symbolInstanceStart===0),this._currentPartIndex++,S())return!0}return!1}}class Wd{constructor(h,f,v,w,S,I,L,z){this.placement=new vi(h,S,I,L,z),this._currentPlacementIndex=f.length-1,this._forceFullPlacement=v,this._showCollisionBoxes=w,this._done=!1}isDone(){return this._done}continuePlacement(h,f,v){const w=a.exported.now(),S=()=>{const I=a.exported.now()-w;return!this._forceFullPlacement&&I>2};for(;this._currentPlacementIndex>=0;){const I=f[h[this._currentPlacementIndex]],L=this.placement.collisionIndex.transform.zoom;if(I.type==="symbol"&&(!I.minzoom||I.minzoom<=L)&&(!I.maxzoom||I.maxzoom>L)){if(this._inProgressLayer||(this._inProgressLayer=new Rc(I)),this._inProgressLayer.continuePlacement(v[I.source],this.placement,this._showCollisionBoxes,I,S))return;delete this._inProgressLayer}this._currentPlacementIndex--}this._done=!0}commit(h){return this.placement.commit(h),this.placement}}const na=512/a.EXTENT/2;class Mo{constructor(h,f,v){this.tileID=h,this.bucketInstanceId=v,this.index=new a.KDBush(f.length,16,Int32Array),this.keys=[],this.crossTileIDs=[];const w=h.canonical.x*a.EXTENT,S=h.canonical.y*a.EXTENT;for(let I=0;I<f.length;I++){const{key:L,crossTileID:z,tileAnchorX:H,tileAnchorY:q}=f.get(I),ee=Math.floor((w+H)*na),de=Math.floor((S+q)*na);this.index.add(ee,de),this.keys.push(L),this.crossTileIDs.push(z)}this.index.finish()}findMatches(h,f,v){const w=this.tileID.canonical.z<f.canonical.z?1:Math.pow(2,this.tileID.canonical.z-f.canonical.z),S=na/Math.pow(2,f.canonical.z-this.tileID.canonical.z),I=f.canonical.x*a.EXTENT,L=f.canonical.y*a.EXTENT;for(let z=0;z<h.length;z++){const H=h.get(z);if(H.crossTileID)continue;const{key:q,tileAnchorX:ee,tileAnchorY:de}=H,_e=Math.floor((I+ee)*S),be=Math.floor((L+de)*S),ve=this.index.range(_e-w,be-w,_e+w,be+w);for(const Ee of ve){const te=this.crossTileIDs[Ee];
120if(this.keys[Ee]===q&&!v.has(te)){v.add(te),H.crossTileID=te;break}}}}}class fh{constructor(){this.maxCrossTileID=0}generate(){return++this.maxCrossTileID}}class ph{constructor(){this.indexes={},this.usedCrossTileIDs={},this.lng=0}handleWrapJump(h){const f=Math.round((h-this.lng)/360);if(f!==0)for(const v in this.indexes){const w=this.indexes[v],S={};for(const I in w){const L=w[I];L.tileID=L.tileID.unwrapTo(L.tileID.wrap+f),S[L.tileID.key]=L}this.indexes[v]=S}this.lng=h}addBucket(h,f,v){if(this.indexes[h.overscaledZ]&&this.indexes[h.overscaledZ][h.key]){if(this.indexes[h.overscaledZ][h.key].bucketInstanceId===f.bucketInstanceId)return!1;this.removeBucketCrossTileIDs(h.overscaledZ,this.indexes[h.overscaledZ][h.key])}for(let S=0;S<f.symbolInstances.length;S++)f.symbolInstances.get(S).crossTileID=0;this.usedCrossTileIDs[h.overscaledZ]||(this.usedCrossTileIDs[h.overscaledZ]=new Set);const w=this.usedCrossTileIDs[h.overscaledZ];for(const S in this.indexes){const I=this.indexes[S];if(Number(S)>h.overscaledZ)for(const L in I){const z=I[L];z.tileID.isChildOf(h)&&z.findMatches(f.symbolInstances,h,w)}else{const L=I[h.scaledTo(Number(S)).key];L&&L.findMatches(f.symbolInstances,h,w)}}for(let S=0;S<f.symbolInstances.length;S++){const I=f.symbolInstances.get(S);I.crossTileID||(I.crossTileID=v.generate(),w.add(I.crossTileID))}return this.indexes[h.overscaledZ]===void 0&&(this.indexes[h.overscaledZ]={}),this.indexes[h.overscaledZ][h.key]=new Mo(h,f.symbolInstances,f.bucketInstanceId),!0}removeBucketCrossTileIDs(h,f){for(const v of f.crossTileIDs)this.usedCrossTileIDs[h].delete(v)}removeStaleBuckets(h){let f=!1;for(const v in this.indexes){const w=this.indexes[v];for(const S in w)h[w[S].bucketInstanceId]||(this.removeBucketCrossTileIDs(v,w[S]),delete w[S],f=!0)}return f}}class as{constructor(){this.layerIndexes={},this.crossTileIDs=new fh,this.maxBucketInstanceId=0,this.bucketsInCurrentPlacement={}}addLayer(h,f,v,w){let S=this.layerIndexes[h.id];S===void 0&&(S=this.layerIndexes[h.id]=new ph);let I=!1;const L={};w.name!=="globe"&&S.handleWrapJump(v);for(const z of f){const H=z.getBucket(h);H&&h.id===H.layerIds[0]&&(H.bucketInstanceId||(H.bucketInstanceId=++this.maxBucketInstanceId),S.addBucket(z.tileID,H,this.crossTileIDs)&&(I=!0),L[H.bucketInstanceId]=!0)}return S.removeStaleBuckets(L)&&(I=!0),I}pruneUnusedLayers(h){const f={};h.forEach(v=>{f[v]=!0});for(const v in this.layerIndexes)f[v]||delete this.layerIndexes[v]}}const Ws=(y,h)=>a.emitValidationErrors(y,h&&h.filter(f=>f.identifier!=="source.canvas")),wu=a.pick(Er,["addLayer","removeLayer","setPaintProperty","setLayoutProperty","setFilter","addSource","removeSource","setLayerZoomRange","setLight","setTransition","setGeoJSONSourceData","setTerrain","setFog","setProjection"]),Og=a.pick(Er,["setCenter","setZoom","setBearing","setPitch"]),Hd={version:8,layers:[],sources:{}},Fc={fill:!0,line:!0,background:!0,hillshade:!0,raster:!0};class ss extends a.Evented{constructor(h,f={}){super(),this.map=h,this.dispatcher=new se(Lc(),this),this.imageManager=new ge,this.imageManager.setEventedParent(this),this.glyphManager=new a.GlyphManager(h._requestManager,f.localFontFamily?a.LocalGlyphMode.all:f.localIdeographFontFamily?a.LocalGlyphMode.ideographs:a.LocalGlyphMode.none,f.localFontFamily||f.localIdeographFontFamily),this.crossTileSymbolIndex=new as,this._layers={},this._num3DLayers=0,this._numSymbolLayers=0,this._numCircleLayers=0,this._serializedLayers={},this._sourceCaches={},this._otherSourceCaches={},this._symbolSourceCaches={},this._loaded=!1,this._availableImages=[],this._order=[],this._drapedFirstOrder=[],this._markersNeedUpdate=!1,this._resetUpdates(),this.dispatcher.broadcast("setReferrer",a.getReferrer());const v=this;this._rtlTextPluginCallback=ss.registerForPluginStateChange(w=>{v.dispatcher.broadcast("syncRTLPluginState",{pluginStatus:w.pluginStatus,pluginURL:w.pluginURL},(S,I)=>{if(a.triggerPluginCompletionEvent(S),I&&I.every(L=>L))for(const L in v._sourceCaches){const z=v._sourceCaches[L],H=z.getSource().type;H!=="vector"&&H!=="geojson"||z.reload()}})}),this.on("data",w=>{if(w.dataType!=="source"||w.sourceDataType!=="metadata")return;const S=this.getSource(w.sourceId);if(S&&S.vectorLayerIds)for(const I in this._layers){const L=this._layers[I];
120L.source===S.id&&this._validateLayer(L)}})}loadURL(h,f={}){this.fire(new a.Event("dataloading",{dataType:"style"}));const v=typeof f.validate=="boolean"?f.validate:!a.isMapboxURL(h);h=this.map._requestManager.normalizeStyleURL(h,f.accessToken);const w=this.map._requestManager.transformRequest(h,a.ResourceType.Style);this._request=a.getJSON(w,(S,I)=>{this._request=null,S?this.fire(new a.ErrorEvent(S)):I&&this._load(I,v)})}loadJSON(h,f={}){this.fire(new a.Event("dataloading",{dataType:"style"})),this._request=a.exported.frame(()=>{this._request=null,this._load(h,f.validate!==!1)})}loadEmpty(){this.fire(new a.Event("dataloading",{dataType:"style"})),this._load(Hd,!1)}_updateLayerCount(h,f){const v=f?1:-1;h.is3D()&&(this._num3DLayers+=v),h.type==="circle"&&(this._numCircleLayers+=v),h.type==="symbol"&&(this._numSymbolLayers+=v)}_load(h,f){if(f&&Ws(this,a.validateStyle(h)))return;this._loaded=!0,this.stylesheet=a.clone$1(h),this._updateMapProjection();for(const w in h.sources)this.addSource(w,h.sources[w],{validate:!1});this._changed=!1,h.sprite?this._loadSprite(h.sprite):(this.imageManager.setLoaded(!0),this.dispatcher.broadcast("spriteLoaded",!0)),this.glyphManager.setURL(h.glyphs);const v=Cp(this.stylesheet.layers);this._order=v.map(w=>w.id),this._layers={},this._serializedLayers={};for(const w of v){const S=a.createStyleLayer(w);S.setEventedParent(this,{layer:{id:S.id}}),this._layers[S.id]=S,this._serializedLayers[S.id]=S.serialize(),this._updateLayerCount(S,!0)}this.dispatcher.broadcast("setLayers",this._serializeLayers(this._order)),this.light=new fe(this.stylesheet.light),this.stylesheet.terrain&&!this.terrainSetForDrapingOnly()&&this._createTerrain(this.stylesheet.terrain,1),this.stylesheet.fog&&this._createFog(this.stylesheet.fog),this._updateDrapeFirstLayers(),this.fire(new a.Event("data",{dataType:"style"})),this.fire(new a.Event("style.load"))}terrainSetForDrapingOnly(){return!!this.terrain&&this.terrain.drapeRenderMode===0}setProjection(h){h?this.stylesheet.projection=h:delete this.stylesheet.projection,this._updateMapProjection()}applyProjectionUpdate(){this._loaded&&(this.dispatcher.broadcast("setProjection",this.map.transform.projectionOptions),this.map.transform.projection.requiresDraping?this.getTerrain()||this.stylesheet.terrain||this.setTerrainForDraping():this.terrainSetForDrapingOnly()&&this.setTerrain(null))}_updateMapProjection(){this.map._useExplicitProjection?this.applyProjectionUpdate():this.map._prioritizeAndUpdateProjection(null,this.stylesheet.projection)}_loadSprite(h){this._spriteRequest=function(f,v,w){let S,I,L;const z=a.exported.devicePixelRatio>1?"@2x":"";let H=a.getJSON(v.transformRequest(v.normalizeSpriteURL(f,z,".json"),a.ResourceType.SpriteJSON),(de,_e)=>{H=null,L||(L=de,S=_e,ee())}),q=a.getImage(v.transformRequest(v.normalizeSpriteURL(f,z,".png"),a.ResourceType.SpriteImage),(de,_e)=>{q=null,L||(L=de,I=_e,ee())});function ee(){if(L)w(L);else if(S&&I){const de=a.exported.getImageData(I),_e={};for(const be in S){const{width:ve,height:Ee,x:te,y:ye,sdf:Oe,pixelRatio:Le,stretchX:He,stretchY:Ze,content:Ye}=S[be],ot=new a.RGBAImage({width:ve,height:Ee});a.RGBAImage.copy(de,ot,{x:te,y:ye},{x:0,y:0},{width:ve,height:Ee}),_e[be]={data:ot,pixelRatio:Le,sdf:Oe,stretchX:He,stretchY:Ze,content:Ye}}w(null,_e)}}return{cancel(){H&&(H.cancel(),H=null),q&&(q.cancel(),q=null)}}}(h,this.map._requestManager,(f,v)=>{if(this._spriteRequest=null,f)this.fire(new a.ErrorEvent(f));else if(v)for(const w in v)this.imageManager.addImage(w,v[w]);this.imageManager.setLoaded(!0),this._availableImages=this.imageManager.listImages(),this.dispatcher.broadcast("setImages",this._availableImages),this.dispatcher.broadcast("spriteLoaded",!0),this.fire(new a.Event("data",{dataType:"style"}))})}_validateLayer(h){const f=this.getSource(h.source);if(!f)return;const v=h.sourceLayer;v&&(f.type==="geojson"||f.vectorLayerIds&&f.vectorLayerIds.indexOf(v)===-1)&&this.fire(new a.ErrorEvent(new Error(`Source layer "${v}" does not exist on source "${f.id}" as specified by style layer "${h.id}"`)))}loaded(){if(!this._loaded||Object.keys(this._updatedSources).length)return!1;for(const h in this._sourceCaches)if(!this._sourceCaches[h].loaded())return!1;return!!this.imageManager.isLoaded()}_serializeLayers(h){const f=[];for(const v of h){const w=this._layers[v];w.type!=="custom"&&f.push(w.serialize())}return f}hasTransitions(){if(this.light&&this.light.hasTransition()||this.fog&&this.fog.hasTransition())return!0;for(const h in this._sourceCaches)if(this._sourceCaches[h].hasTransition())return!0;for(const h in this._layers)if(this._layers[h].hasTransition())return!0;return!1}get order(){return this.map._optimizeForTerrain&&this.terrain?this._drapedFirstOrder:this._order}isLayerDraped(h){return!!this.terrain&&(typeof h.isLayerDraped=="function"?h.isLayerDraped():Fc[h.type])}_checkLoaded(){if(!this._loaded)throw new Error("Style is not done loading")}
120update(h){if(!this._loaded)return;const f=this._changed;if(this._changed){const w=Object.keys(this._updatedLayers),S=Object.keys(this._removedLayers);(w.length||S.length)&&this._updateWorkerLayers(w,S);for(const I in this._updatedSources){const L=this._updatedSources[I];L==="reload"?this._reloadSource(I):L==="clear"&&this._clearSource(I)}this._updateTilesForChangedImages();for(const I in this._updatedPaintProps)this._layers[I].updateTransitions(h);this.light.updateTransitions(h),this.fog&&this.fog.updateTransitions(h),this._resetUpdates()}const v={};for(const w in this._sourceCaches){const S=this._sourceCaches[w];v[w]=S.used,S.used=!1}for(const w of this._order){const S=this._layers[w];if(S.recalculate(h,this._availableImages),!S.isHidden(h.zoom)){const L=this._getLayerSourceCache(S);L&&(L.used=!0)}const I=this.map.painter;if(I){const L=S.getProgramIds();if(!L)continue;const z=S.getProgramConfiguration(h.zoom);for(const H of L)I.useProgram(H,z)}}for(const w in v){const S=this._sourceCaches[w];v[w]!==S.used&&S.getSource().fire(new a.Event("data",{sourceDataType:"visibility",dataType:"source",sourceId:S.getSource().id}))}this.light.recalculate(h),this.terrain&&this.terrain.recalculate(h),this.fog&&this.fog.recalculate(h),this.z=h.zoom,this._markersNeedUpdate&&(this._updateMarkersOpacity(),this._markersNeedUpdate=!1),f&&this.fire(new a.Event("data",{dataType:"style"}))}_updateTilesForChangedImages(){const h=Object.keys(this._changedImages);if(h.length){for(const f in this._sourceCaches)this._sourceCaches[f].reloadTilesForDependencies(["icons","patterns"],h);this._changedImages={}}}_updateWorkerLayers(h,f){this.dispatcher.broadcast("updateLayers",{layers:this._serializeLayers(h),removedIds:f})}_resetUpdates(){this._changed=!1,this._updatedLayers={},this._removedLayers={},this._updatedSources={},this._updatedPaintProps={},this._changedImages={}}setState(h){if(this._checkLoaded(),Ws(this,a.validateStyle(h)))return!1;(h=a.clone$1(h)).layers=Cp(h.layers);const f=function(w,S){if(!w)return[{command:Er.setStyle,args:[S]}];let I=[];try{if(!m(w.version,S.version))return[{command:Er.setStyle,args:[S]}];m(w.center,S.center)||I.push({command:Er.setCenter,args:[S.center]}),m(w.zoom,S.zoom)||I.push({command:Er.setZoom,args:[S.zoom]}),m(w.bearing,S.bearing)||I.push({command:Er.setBearing,args:[S.bearing]}),m(w.pitch,S.pitch)||I.push({command:Er.setPitch,args:[S.pitch]}),m(w.sprite,S.sprite)||I.push({command:Er.setSprite,args:[S.sprite]}),m(w.glyphs,S.glyphs)||I.push({command:Er.setGlyphs,args:[S.glyphs]}),m(w.transition,S.transition)||I.push({command:Er.setTransition,args:[S.transition]}),m(w.light,S.light)||I.push({command:Er.setLight,args:[S.light]}),m(w.fog,S.fog)||I.push({command:Er.setFog,args:[S.fog]}),m(w.projection,S.projection)||I.push({command:Er.setProjection,args:[S.projection]});const L={},z=[];(function(ee,de,_e,be){let ve;for(ve in de=de||{},ee=ee||{})ee.hasOwnProperty(ve)&&(de.hasOwnProperty(ve)||Jl(ve,_e,be));for(ve in de){if(!de.hasOwnProperty(ve))continue;const Ee=de[ve];ee.hasOwnProperty(ve)?m(ee[ve],Ee)||(ee[ve].type==="geojson"&&Ee.type==="geojson"&&ec(ee,de,ve)?_e.push({command:Er.setGeoJSONSourceData,args:[ve,Ee.data]}):Vd(ve,de,_e,be)):Ud(ve,de,_e)}})(w.sources,S.sources,z,L);const H=[];w.layers&&w.layers.forEach(ee=>{ee.source&&L[ee.source]?I.push({command:Er.removeLayer,args:[ee.id]}):H.push(ee)});let q=w.terrain;q&&L[q.source]&&(I.push({command:Er.setTerrain,args:[void 0]}),q=void 0),I=I.concat(z),m(q,S.terrain)||I.push({command:Er.setTerrain,args:[S.terrain]}),function(ee,de,_e){de=de||[];const be=(ee=ee||[]).map(is),ve=de.map(is),Ee=ee.reduce(eo,{}),te=de.reduce(eo,{}),ye=be.slice(),Oe=Object.create(null);let Le,He,Ze,Ye,ot,et,_t;for(Le=0,He=0;Le<be.length;Le++)Ze=be[Le],te.hasOwnProperty(Ze)?He++:(_e.push({command:Er.removeLayer,args:[Ze]}),ye.splice(ye.indexOf(Ze,He),1));for(Le=0,He=0;Le<ve.length;Le++)Ze=ve[ve.length-1-Le],ye[ye.length-1-Le]!==Ze&&(Ee.hasOwnProperty(Ze)?(_e.push({command:Er.removeLayer,args:[Ze]}),ye.splice(ye.lastIndexOf(Ze,ye.length-He),1)):He++,et=ye[ye.length-Le],_e.push({command:Er.addLayer,args:[te[Ze],et]}),ye.splice(ye.length-Le,0,Ze),Oe[Ze]=!0);for(Le=0;Le<ve.length;Le++)if(Ze=ve[Le],Ye=Ee[Ze],ot=te[Ze],!Oe[Ze]&&!m(Ye,ot))if(m(Ye.source,ot.source)&&m(Ye["source-layer"],ot["source-layer"])&&m(Ye.type,ot.type)){for(_t in $a(Ye.layout,ot.layout,_e,Ze,null,Er.setLayoutProperty),$a(Ye.paint,ot.paint,_e,Ze,null,Er.setPaintProperty),m(Ye.filter,ot.filter)||_e.push({command:Er.setFilter,args:[Ze,ot.filter]}),m(Ye.minzoom,ot.minzoom)&&m(Ye.maxzoom,ot.maxzoom)||_e.push({command:Er.setLayerZoomRange,args:[Ze,ot.minzoom,ot.maxzoom]}),Ye)Ye.hasOwnProperty(_t)&&_t!=="layout"&&_t!=="paint"&&_t!=="filter"&&_t!=="metadata"&&_t!=="minzoom"&&_t!=="maxzoom"&&(_t.indexOf("paint.")===0?$a(Ye[_t],ot[_t],_e,Ze,_t.slice(6),Er.setPaintProperty):m(Ye[_t],ot[_t])||_e.push({command:Er.setLayerProperty,args:[Ze,_t,ot[_t]]}));for(_t in ot)ot.hasOwnProperty(_t)&&!Ye.hasOwnProperty(_t)&&_t!=="layout"&&_t!=="paint"&&_t!=="filter"&&_t!=="metadata"&&_t!=="minzoom"&&_t!=="maxzoom"&&(_t.indexOf("paint.")===0?$a(Ye[_t],ot[_t],_e,Ze,_t.slice(6),Er.setPaintProperty):m(Ye[_t],ot[_t])||_e.push({command:Er.setLayerProperty,args:[Ze,_t,ot[_t]]}))}else _e.push({command:Er.removeLayer,args:[Ze]}),et=ye[ye.lastIndexOf(Ze)+1],_e.push({command:Er.addLayer,args:[ot,et]})}(H,S.layers,I)}catch(L){console.warn("Unable to compute style diff:",L),I=[{command:Er.setStyle,args:[S]}]}return I}(this.serialize(),h).filter(w=>!(w.command in Og));if(f.length===0)return!1;const v=f.filter(w=>!(w.command in wu));if(v.length>0)throw new Error(`Unimplemented: ${v.map(w=>w.command).join(", ")}.`);return f.forEach(w=>{w.command!=="setTransition"&&w.command!=="setProjection"&&this[w.command].apply(this,w.args)}),this.stylesheet=h,this._updateMapProjection(),!0}addImage(h,f){return this.getImage(h)?this.fire(new a.ErrorEvent(new Error("An image with this name already exists."))):(this.imageManager.addImage(h,f),this._afterImageUpdated(h),this)}updateImage(h,f){this.imageManager.updateImage(h,f)}getImage(h){return this.imageManager.getImage(h)}removeImage(h){return this.getImage(h)?(this.imageManager.removeImage(h),this._afterImageUpdated(h),this):this.fire(new a.ErrorEvent(new Error("No image with this name exists.")))}_afterImageUpdated(h){this._availableImages=this.imageManager.listImages(),this._changedImages[h]=!0,this._changed=!0,this.dispatcher.broadcast("setImages",this._availableImages),this.fire(new a.Event("data",{dataType:"style"}))}listImages(){return this._checkLoaded(),this._availableImages.slice()}addSource(h,f,v={}
120){if(this._checkLoaded(),this.getSource(h)!==void 0)throw new Error("There is already a source with this ID");if(!f.type)throw new Error(`The type property must be defined, but only the following properties were given: ${Object.keys(f).join(", ")}.`);if(["vector","raster","geojson","video","image"].indexOf(f.type)>=0&&this._validate(a.validateSource,`sources.${h}`,f,null,v))return;this.map&&this.map._collectResourceTiming&&(f.collectResourceTiming=!0);const w=or(h,f,this.dispatcher,this);w.setEventedParent(this,()=>({isSourceLoaded:this._isSourceCacheLoaded(h),source:w.serialize(),sourceId:h}));const S=I=>{const L=(I?"symbol:":"other:")+h,z=this._sourceCaches[L]=new a.SourceCache(L,w,I);(I?this._symbolSourceCaches:this._otherSourceCaches)[h]=z,z.style=this,z.onAdd(this.map)};S(!1),f.type!=="vector"&&f.type!=="geojson"||S(!0),w.onAdd&&w.onAdd(this.map),this._changed=!0}removeSource(h){this._checkLoaded();const f=this.getSource(h);if(!f)throw new Error("There is no source with this ID");for(const w in this._layers)if(this._layers[w].source===h)return this.fire(new a.ErrorEvent(new Error(`Source "${h}" cannot be removed while layer "${w}" is using it.`)));if(this.terrain&&this.terrain.get().source===h)return this.fire(new a.ErrorEvent(new Error(`Source "${h}" cannot be removed while terrain is using it.`)));const v=this._getSourceCaches(h);for(const w of v)delete this._sourceCaches[w.id],delete this._updatedSources[w.id],w.fire(new a.Event("data",{sourceDataType:"metadata",dataType:"source",sourceId:w.getSource().id})),w.setEventedParent(null),w.clearTiles();return delete this._otherSourceCaches[h],delete this._symbolSourceCaches[h],f.setEventedParent(null),f.onRemove&&f.onRemove(this.map),this._changed=!0,this}
120setGeoJSONSourceData(h,f){this._checkLoaded(),this.getSource(h).setData(f),this._changed=!0}getSource(h){const f=this._getSourceCache(h);return f&&f.getSource()}_getSources(){const h=[];for(const f in this._otherSourceCaches){const v=this._getSourceCache(f);v&&h.push(v.getSource())}return h}addLayer(h,f,v={}){this._checkLoaded();const w=h.id;if(this.getLayer(w))return void this.fire(new a.ErrorEvent(new Error(`Layer with id "${w}" already exists on this map`)));let S;if(h.type==="custom"){if(Ws(this,a.validateCustomStyleLayer(h)))return;S=a.createStyleLayer(h)}else{if(typeof h.source=="object"&&(this.addSource(w,h.source),h=a.clone$1(h),h=a.extend(h,{source:w})),this._validate(a.validateLayer,`layers.${w}`,h,{arrayIndex:-1},v))return;S=a.createStyleLayer(h),this._validateLayer(S),S.setEventedParent(this,{layer:{id:w}}),this._serializedLayers[S.id]=S.serialize(),this._updateLayerCount(S,!0)}const I=f?this._order.indexOf(f):this._order.length;if(f&&I===-1)return void this.fire(new a.ErrorEvent(new Error(`Layer with id "${f}" does not exist on this map.`)));this._order.splice(I,0,w),this._layerOrderChanged=!0,this._layers[w]=S;const L=this._getLayerSourceCache(S);if(this._removedLayers[w]&&S.source&&L&&S.type!=="custom"){const z=this._removedLayers[w];delete this._removedLayers[w],z.type!==S.type?this._updatedSources[S.source]="clear":(this._updatedSources[S.source]="reload",L.pause())}this._updateLayer(S),S.onAdd&&S.onAdd(this.map),this._updateDrapeFirstLayers()}moveLayer(h,f){if(this._checkLoaded(),this._changed=!0,!this._layers[h])return void this.fire(new a.ErrorEvent(new Error(`The layer '${h}' does not exist in the map's style and cannot be moved.`)));if(h===f)return;const v=this._order.indexOf(h);this._order.splice(v,1);const w=f?this._order.indexOf(f):this._order.length;
120f&&w===-1?this.fire(new a.ErrorEvent(new Error(`Layer with id "${f}" does not exist on this map.`))):(this._order.splice(w,0,h),this._layerOrderChanged=!0,this._updateDrapeFirstLayers())}removeLayer(h){this._checkLoaded();const f=this._layers[h];if(!f)return void this.fire(new a.ErrorEvent(new Error(`The layer '${h}' does not exist in the map's style and cannot be removed.`)));f.setEventedParent(null),this._updateLayerCount(f,!1);const v=this._order.indexOf(h);this._order.splice(v,1),this._layerOrderChanged=!0,this._changed=!0,this._removedLayers[h]=f,delete this._layers[h],delete this._serializedLayers[h],delete this._updatedLayers[h],delete this._updatedPaintProps[h],f.onRemove&&f.onRemove(this.map),this._updateDrapeFirstLayers()}getLayer(h){return this._layers[h]}hasLayer(h){return h in this._layers}hasLayerType(h){for(const f in this._layers)if(this._layers[f].type===h)return!0;return!1}setLayerZoomRange(h,f,v){this._checkLoaded();const w=this.getLayer(h);w?w.minzoom===f&&w.maxzoom===v||(f!=null&&(w.minzoom=f),v!=null&&(w.maxzoom=v),this._updateLayer(w)):this.fire(new a.ErrorEvent(new Error(`The layer '${h}' does not exist in the map's style and cannot have zoom extent.`)))}setFilter(h,f,v={}){this._checkLoaded();const w=this.getLayer(h);if(w){if(!m(w.filter,f))return f==null?(w.filter=void 0,void this._updateLayer(w)):void(this._validate(a.validateFilter,`layers.${w.id}.filter`,f,{layerType:w.type},v)||(w.filter=a.clone$1(f),this._updateLayer(w)))}else this.fire(new a.ErrorEvent(new Error(`The layer '${h}' does not exist in the map's style and cannot be filtered.`)))}getFilter(h){const f=this.getLayer(h);return f&&a.clone$1(f.filter)}setLayoutProperty(h,f,v,w={}){this._checkLoaded();const S=this.getLayer(h);S?m(S.getLayoutProperty(f),v)||(S.setLayoutProperty(f,v,w),this._updateLayer(S)):this.fire(new a.ErrorEvent(new Error(`The layer '${h}' does not exist in the map's style and cannot be styled.`)))}getLayoutProperty(h,f){const v=this.getLayer(h);if(v)return v.getLayoutProperty(f);this.fire(new a.ErrorEvent(new Error(`The layer '${h}' does not exist in the map's style.`)))}setPaintProperty(h,f,v,w={}){this._checkLoaded();const S=this.getLayer(h);S?m(S.getPaintProperty(f),v)||(S.setPaintProperty(f,v,w)&&this._updateLayer(S),this._changed=!0,this._updatedPaintProps[h]=!0):this.fire(new a.ErrorEvent(new Error(`The layer '${h}' does not exist in the map's style and cannot be styled.`)))}getPaintProperty(h,f){const v=this.getLayer(h);return v&&v.getPaintProperty(f)}setFeatureState(h,f){this._checkLoaded();const v=h.source,w=h.sourceLayer,S=this.getSource(v);if(!S)return void this.fire(new a.ErrorEvent(new Error(`The source '${v}' does not exist in the map's style.`)));const I=S.type;if(I==="geojson"&&w)return void this.fire(new a.ErrorEvent(new Error("GeoJSON sources cannot have a sourceLayer parameter.")));if(I==="vector"&&!w)return void this.fire(new a.ErrorEvent(new Error("The sourceLayer parameter must be provided for vector source types.")));h.id===void 0&&this.fire(new a.ErrorEvent(new Error("The feature id parameter must be provided.")));const L=this._getSourceCaches(v);for(const z of L)z.setFeatureState(w,h.id,f)}removeFeatureState(h,f){this._checkLoaded();const v=h.source,w=this.getSource(v);if(!w)return void this.fire(new a.ErrorEvent(new Error(`The source '${v}' does not exist in the map's style.`)));const S=w.type,I=S==="vector"?h.sourceLayer:void 0;if(S==="vector"&&!I)return void this.fire(new a.ErrorEvent(new Error("The sourceLayer parameter must be provided for vector source types.")));if(f&&typeof h.id!="string"&&typeof h.id!="number")return void this.fire(new a.ErrorEvent(new Error("A feature id is required to remove its specific state property.")));const L=this._getSourceCaches(v);for(const z of L)z.removeFeatureState(I,h.id,f)}getFeatureState(h){this._checkLoaded();const f=h.source,v=h.sourceLayer,w=this.getSource(f);if(w){if(w.type!=="vector"||v)return h.id===void 0&&this.fire(new a.ErrorEvent(new Error("The feature id parameter must be provided."))),this._getSourceCaches(f)[0].getFeatureState(v,h.id);this.fire(new a.ErrorEvent(new Error("The sourceLayer parameter must be provided for vector source types.")))}else this.fire(new a.ErrorEvent(new Error(`The source '${f}' does not exist in the map's style.`)))}getTransition(){return a.extend({duration:300,delay:0},this.stylesheet&&this.stylesheet.transition)}serialize(){const h={};for(const f in this._sourceCaches){const v=this._sourceCaches[f].getSource();h[v.id]||(h[v.id]=v.serialize())}return a.filterObject({version:this.stylesheet.version,name:this.stylesheet.name,metadata:this.stylesheet.metadata,light:this.stylesheet.light,terrain:this.getTerrain()||void 0,fog:this.stylesheet.fog,center:this.stylesheet.center,zoom:this.stylesheet.zoom,bearing:this.stylesheet.bearing,pitch:this.stylesheet.pitch,sprite:this.stylesheet.sprite,glyphs:this.stylesheet.glyphs,transition:this.stylesheet.transition,projection:this.stylesheet.projection,sources:h,layers:this._serializeLayers(this._order)},f=>f!==void 0)}_updateLayer(h){this._updatedLayers[h.id]=!0;const f=this._getLayerSourceCache(h);h.source&&!this._updatedSources[h.source]&&f&&f.getSource().type!=="raster"&&(this._updatedSources[h.source]="reload",f.pause()),this._changed=!0,h.invalidateCompiledFilter()}_flattenAndSortRenderedFeatures(h){const f=I=>this._layers[I].type==="fill-extrusion",v={},w=[];for(let I=this._order.length-1;I>=0;I--){const L=this._order[I];if(f(L)){v[L]=I;for(const z of h){const H=z[L];if(H)for(const q of H)w.push(q)}}}w.sort((I,L)=>L.intersectionZ-I.intersectionZ);const S=[];for(let I=this._order.length-1;I>=0;I--){const L=this._order[I];if(f(L))for(let z=w.length-1;z>=0;z--){const H=w[z].feature;if(v[H.layer.id]<I)break;S.push(H),w.pop()}else for(const z of h){const H=z[L];if(H)for(const q of H)S.push(q.feature)}}return S}
120queryRenderedFeatures(h,f,v){f&&f.filter&&this._validate(a.validateFilter,"queryRenderedFeatures.filter",f.filter,null,f);const w={};if(f&&f.layers){if(!Array.isArray(f.layers))return this.fire(new a.ErrorEvent(new Error("parameters.layers must be an Array."))),[];for(const z of f.layers){const H=this._layers[z];if(!H)return this.fire(new a.ErrorEvent(new Error(`The layer '${z}' does not exist in the map's style and cannot be queried for features.`))),[];w[H.source]=!0}}const S=[];f.availableImages=this._availableImages;const I=f&&f.layers?f.layers.some(z=>{const H=this.getLayer(z);return H&&H.is3D()}):this.has3DLayers(),L=Se.createFromScreenPoints(h,v);for(const z in this._sourceCaches){const H=this._sourceCaches[z].getSource().id;f.layers&&!w[H]||S.push(Gr(this._sourceCaches[z],this._layers,this._serializedLayers,L,f,v,I,!!this.map._showQueryGeometry))}return this.placement&&S.push(function(z,H,q,ee,de,_e,be){const ve={},Ee=_e.queryRenderedSymbols(ee),te=[];for(const ye of Object.keys(Ee).map(Number))te.push(be[ye]);te.sort(po);for(const ye of te){const Oe=ye.featureIndex.lookupSymbolFeatures(Ee[ye.bucketInstanceId],H,ye.bucketIndex,ye.sourceLayerIndex,de.filter,de.layers,de.availableImages,z);for(const Le in Oe){const He=ve[Le]=ve[Le]||[],Ze=Oe[Le];Ze.sort((Ye,ot)=>{const et=ye.featureSortOrder;if(et){const _t=et.indexOf(Ye.featureIndex);return et.indexOf(ot.featureIndex)-_t}return ot.featureIndex-Ye.featureIndex});for(const Ye of Ze)He.push(Ye)}}for(const ye in ve)ve[ye].forEach(Oe=>{const Le=Oe.feature,He=q(z[ye]);if(!He)return;const Ze=He.getFeatureState(Le.layer["source-layer"],Le.id);Le.source=Le.layer.source,Le.layer["source-layer"]&&(Le.sourceLayer=Le.layer["source-layer"]),Le.state=Ze});return ve}(this._layers,this._serializedLayers,this._getLayerSourceCache.bind(this),L.screenGeometry,f,this.placement.collisionIndex,this.placement.retainedQueryData)),this._flattenAndSortRenderedFeatures(S)}querySourceFeatures(h,f){f&&f.filter&&this._validate(a.validateFilter,"querySourceFeatures.filter",f.filter,null,f);const v=this._getSourceCaches(h);let w=[];for(const S of v)w=w.concat(Wi(S,f));return w}addSourceType(h,f,v){return ss.getSourceType(h)?v(new Error(`A source type called "${h}" already exists.`)):(ss.setSourceType(h,f),f.workerSourceURL?void this.dispatcher.broadcast("loadWorkerSource",{name:h,url:f.workerSourceURL},v):v(null,null))}getLight(){return this.light.getLight()}setLight(h,f={}){this._checkLoaded();const v=this.light.getLight();let w=!1;for(const I in h)if(!m(h[I],v[I])){w=!0;break}if(!w)return;const S=this._setTransitionParameters({duration:300,delay:0});this.light.setLight(h,f),this.light.updateTransitions(S)}getTerrain(){return this.terrain&&this.terrain.drapeRenderMode===1?this.terrain.get():null}setTerrainForDraping(){this.setTerrain({source:"",exaggeration:0},0)}setTerrain(h,f=1){if(this._checkLoaded(),!h)return delete this.terrain,delete this.stylesheet.terrain,this.dispatcher.broadcast("enableTerrain",!1),this._force3DLayerUpdate(),void(this._markersNeedUpdate=!0);let v=h;if(f===1){if(typeof v.source=="object"){const w="terrain-dem-src";this.addSource(w,v.source),v=a.clone$1(v),v=a.extend(v,{source:w})}if(this._validate(a.validateTerrain,"terrain",v))return}if(!this.terrain||this.terrain&&f!==this.terrain.drapeRenderMode){if(!v)return;this._createTerrain(v,f)}else{const w=this.terrain,S=w.get();for(const I of Object.keys(a.spec.terrain))!v.hasOwnProperty(I)&&a.spec.terrain[I].default&&(v[I]=a.spec.terrain[I].default);for(const I in v)if(!m(v[I],S[I])){w.set(v),this.stylesheet.terrain=v;const L=this._setTransitionParameters({duration:0});w.updateTransitions(L);break}}this._updateDrapeFirstLayers(),this._markersNeedUpdate=!0}_createFog(h){const f=this.fog=new le(h,this.map.transform);this.stylesheet.fog=h;const v=this._setTransitionParameters({duration:0});f.updateTransitions(v)}_updateMarkersOpacity(){this.map._markers.length!==0&&this.map._requestDomTask(()=>{for(const h of this.map._markers)h._evaluateOpacity()})}getFog(){return this.fog?this.fog.get():null}setFog(h){if(this._checkLoaded(),!h)return delete this.fog,delete this.stylesheet.fog,void(this._markersNeedU
120pdate=!0);if(this.fog){const f=this.fog,v=f.get();Object.keys(h).length===0&&f.set(h);for(const w in h)if(!m(h[w],v[w])){f.set(h),this.stylesheet.fog=h;const S=this._setTransitionParameters({duration:0});f.updateTransitions(S);break}}else this._createFog(h);this._markersNeedUpdate=!0}_setTransitionParameters(h){return{now:a.exported.now(),transition:a.extend(h,this.stylesheet.transition)}}_updateDrapeFirstLayers(){if(!this.map._optimizeForTerrain||!this.terrain)return;const h=this._order.filter(v=>this.isLayerDraped(this._layers[v])),f=this._order.filter(v=>!this.isLayerDraped(this._layers[v]));this._drapedFirstOrder=[],this._drapedFirstOrder.push(...h),this._drapedFirstOrder.push(...f)}_createTerrain(h,f){const v=this.terrain=new xe(h,f);this.stylesheet.terrain=h,this.dispatcher.broadcast("enableTerrain",!this.terrainSetForDrapingOnly()),this._force3DLayerUpdate();const w=this._setTransitionParameters({duration:0});v.updateTransitions(w)}_force3DLayerUpdate(){for(const h in this._layers){const f=this._layers[h];f.type==="fill-extrusion"&&this._updateLayer(f)}}_forceSymbolLayerUpdate(){for(const h in this._layers){const f=this._layers[h];f.type==="symbol"&&this._updateLayer(f)}}_validate(h,f,v,w,S={}){return(!S||S.validate!==!1)&&Ws(this,h.call(a.validateStyle,a.extend({key:f,style:this.serialize(),value:v,styleSpec:a.spec},w)))}_remove(){this._request&&(this._request.cancel(),this._request=null),this._spriteRequest&&(this._spriteRequest.cancel(),this._spriteRequest=null),a.evented.off("pluginStateChange",this._rtlTextPluginCallback);for(const h in this._layers)this._layers[h].setEventedParent(null);for(const h in this._sourceCaches)this._sourceCaches[h].clearTiles(),this._sourceCaches[h].setEventedParent(null);this.imageManager.setEventedParent(null),this.setEventedParent(null),this.dispatcher.remove()}_clearSource(h){const f=this._getSourceCaches(h);for(const v of f)v.clearTiles()}_reloadSource(h){const f=this._getSourceCaches(h);for(const v of f)v.resume(),v.reload()}_reloadSources(){for(const h of this._getSources())h.reload&&h.reload()}_updateSources(h){for(const f in this._sourceCaches)this._sourceCaches[f].update(h)}_generateCollisionBoxes(){for(const h in this._sourceCaches){const f=this._sourceCaches[h];f.resume(),f.reload()}}_updatePlacement(h,f,v,w,S=!1){let I=!1,L=!1;const z={};for(const H of this._order){const q=this._layers[H];if(q.type!=="symbol")continue;if(!z[q.source]){const de=this._getLayerSourceCache(q);if(!de)continue;z[q.source]=de.getRenderableIds(!0).map(_e=>de.getTileByID(_e)).sort((_e,be)=>be.tileID.overscaledZ-_e.tileID.overscaledZ||(_e.tileID.isLessThan(be.tileID)?-1:1))}const ee=this.crossTileSymbolIndex.addLayer(q,z[q.source],h.center.lng,h.projection);I=I||ee}if(this.crossTileSymbolIndex.pruneUnusedLayers(this._order),S=S||this._layerOrderChanged||v===0,this._layerOrderChanged&&this.fire(new a.Event("neworder")),(S||!this.pauseablePlacement||this.pauseablePlacement.isDone()&&!this.placement.stillRecent(a.exported.now(),h.zoom))&&(this.pauseablePlacement=new Wd(h,this._order,S,f,v,w,this.placement,this.fog&&h.projection.supportsFog?this.fog.state:null),this._layerOrderChanged=!1),this.pauseablePlacement.isDone()?this.placement.setStale():(this.pauseablePlacement.continuePlacement(this._order,this._layers,z),this.pauseablePlacement.isDone()&&(this.placement=this.pauseablePlacement.commit(a.exported.now()),L=!0),I&&this.pauseablePlacement.placement.setStale()),L||I)for(const H of this._order){const q=this._layers[H];q.type==="symbol"&&this.placement.updateLayerOpacities(q,z[q.source])}return!this.pauseablePlacement.isDone()||this.placement.hasTransitions(a.exported.now())}_releaseSymbolFadeTiles(){for(const h in this._sourceCaches)this._sourceCaches[h].releaseSymbolFadeTiles()}getImages(h,f,v){this.imageManager.getImages(f.icons,v),this._updateTilesForChangedImages();const w=S=>{S&&S.setDependencies(f.tileID.key,f.type,f.icons)};w(this._otherSourceCaches[f.source]),w(this._symbolSourceCaches[f.source])}getGlyphs(h,f,v){this.glyphManager.getGlyphs(f.stacks,v)}
120getResource(h,f,v){return a.makeRequest(f,v)}_getSourceCache(h){return this._otherSourceCaches[h]}_getLayerSourceCache(h){return h.type==="symbol"?this._symbolSourceCaches[h.source]:this._otherSourceCaches[h.source]}_getSourceCaches(h){const f=[];return this._otherSourceCaches[h]&&f.push(this._otherSourceCaches[h]),this._symbolSourceCaches[h]&&f.push(this._symbolSourceCaches[h]),f}_isSourceCacheLoaded(h){const f=this._getSourceCaches(h);return f.length===0?(this.fire(new a.ErrorEvent(new Error(`There is no source with ID '${h}'`))),!1):f.every(v=>v.loaded())}has3DLayers(){return this._num3DLayers>0}hasSymbolLayers(){return this._numSymbolLayers>0}hasCircleLayers(){return this._numCircleLayers>0}_clearWorkerCaches(){this.dispatcher.broadcast("clearCaches")}destroy(){this._clearWorkerCaches(),this.terrainSetForDrapingOnly()&&(delete this.terrain,delete this.stylesheet.terrain)}}ss.getSourceType=function(y){return Yn[y]},ss.setSourceType=function(y,h){Yn[y]=h},ss.registerForPluginStateChange=a.registerForPluginStateChange;var mh=`
121#define EPSILON 0.0000001
122#define PI 3.141592653589793
123#define EXTENT 8192.0
124#define HALF_PI PI/2.0
125#define QUARTER_PI PI/4.0
126#define RAD_TO_DEG 180.0/PI
127#define DEG_TO_RAD PI/180.0
128#define GLOBE_RADIUS EXTENT/PI/2.0`,xl="attribute highp vec3 a_pos_3f;uniform lowp mat4 u_matrix;varying highp vec3 v_uv;void main() {const mat3 half_neg_pi_around_x=mat3(1.0,0.0, 0.0,0.0,0.0,-1.0,0.0,1.0, 0.0);v_uv=half_neg_pi_around_x*a_pos_3f;vec4 pos=u_matrix*vec4(a_pos_3f,1.0);gl_Position=pos.xyww;}",Hs=`
129#define ELEVATION_SCALE 7.0
130#define ELEVATION_OFFSET 450.0
131#ifdef PROJECTION_GLOBE_VIEW
132uniform vec3 u_tile_tl_up;uniform vec3 u_tile_tr_up;uniform vec3 u_tile_br_up;uniform vec3 u_tile_bl_up;uniform float u_tile_up_scale;vec3 elevationVector(vec2 pos) {vec2 uv=pos/EXTENT;vec3 up=normalize(mix(
133mix(u_tile_tl_up,u_tile_tr_up,uv.xxx),mix(u_tile_bl_up,u_tile_br_up,uv.xxx),uv.yyy));return up*u_tile_up_scale;}
134#else
135vec3 elevationVector(vec2 pos) { return vec3(0,0,1); }
136#endif
137const float skirtOffset=24575.0;vec3 decomposeToPosAndSkirt(vec2 posWithComposedSkirt)
138{float skirt=float(posWithComposedSkirt.x >=skirtOffset);vec2 pos=posWithComposedSkirt-vec2(skirt*skirtOffset,0.0);return vec3(pos,skirt);}
139#ifdef TERRAIN
140#ifdef TERRAIN_DEM_FLOAT_FORMAT
141uniform highp sampler2D u_dem;uniform highp sampler2D u_dem_prev;
142#else
143uniform sampler2D u_dem;uniform sampler2D u_dem_prev;
144#endif
145uniform vec4 u_dem_unpack;uniform vec2 u_dem_tl;uniform vec2 u_dem_tl_prev;uniform float u_dem_scale;uniform float u_dem_scale_prev;uniform float u_dem_size;uniform float u_dem_lerp;uniform float u_exaggeration;uniform float u_meter_to_dem;uniform mat4 u_label_plane_matrix_inv;uniform sampler2D u_depth;uniform vec2 u_depth_size_inv;vec4 tileUvToDemSample(vec2 uv,float dem_size,float dem_scale,vec2 dem_tl) {vec2 pos=dem_size*(uv*dem_scale+dem_tl)+1.0;vec2 f=fract(pos);return vec4((pos-f+0.5)/(dem_size+2.0),f);}float decodeElevation(vec4 v) {return dot(vec4(v.xyz*255.0,-1.0),u_dem_unpack);}float currentElevation(vec2 apos) {
146#ifdef TERRAIN_DEM_FLOAT_FORMAT
147vec2 pos=(u_dem_size*(apos/8192.0*u_dem_scale+u_dem_tl)+1.5)/(u_dem_size+2.0);return u_exaggeration*texture2D(u_dem,pos).a;
148#else
149float dd=1.0/(u_dem_size+2.0);vec4 r=tileUvToDemSample(apos/8192.0,u_dem_size,u_dem_scale,u_dem_tl);vec2 pos=r.xy;vec2 f=r.zw;float tl=decodeElevation(texture2D(u_dem,pos));
150#ifdef TERRAIN_DEM_NEAREST_FILTER
151return u_exaggeration*tl;
152#endif
153float tr=decodeElevation(texture2D(u_dem,pos+vec2(dd,0.0)));float bl=decodeElevation(texture2D(u_dem,pos+vec2(0.0,dd)));float br=decodeElevation(texture2D(u_dem,pos+vec2(dd,dd)));return u_exaggeration*mix(mix(tl,tr,f.x),mix(bl,br,f.x),f.y);
154#endif
155}float prevElevation(vec2 apos) {
156#ifdef TERRAIN_DEM_FLOAT_FORMAT
157vec2 pos=(u_dem_size*(apos/8192.0*u_dem_scale_prev+u_dem_tl_prev)+1.5)/(u_dem_size+2.0);return u_exaggeration*texture2D(u_dem_prev,pos).a;
158#else
159float dd=1.0/(u_dem_size+2.0);vec4 r=tileUvToDemSample(apos/8192.0,u_dem_size,u_dem_scale_prev,u_dem_tl_prev);vec2 pos=r.xy;vec2 f=r.zw;float tl=decodeElevation(texture2D(u_dem_prev,pos));float tr=decodeElevation(texture2D(u_dem_prev,pos+vec2(dd,0.0)));float bl=decodeElevation(texture2D(u_dem_prev,pos+vec2(0.0,dd)));float br=decodeElevation(texture2D(u_dem_prev,pos+vec2(dd,dd)));return u_exaggeration*mix(mix(tl,tr,f.x),mix(bl,br,f.x),f.y);
160#endif
161}
162#ifdef TERRAIN_VERTEX_MORPHING
163float elevation(vec2 apos) {
164#ifdef ZERO_EXAGGERATION
165return 0.0;
166#endif
167float nextElevation=currentElevation(apos);float prevElevation=prevElevation(apos);return mix(prevElevation,nextElevation,u_dem_lerp);}
168#else
169float elevation(vec2 apos) {
170#ifdef ZERO_EXAGGERATION
171return 0.0;
172#endif
173return currentElevation(apos);}
174#endif
175highp float unpack_depth(highp vec4 rgba_depth)
176{const highp vec4 bit_shift=vec4(1.0/(255.0*255.0*255.0),1.0/(255.0*255.0),1.0/255.0,1.0);return dot(rgba_depth,bit_shift)*2.0-1.0;}bool isOccluded(vec4 frag) {vec3 coord=frag.xyz/frag.w;float depth=unpack_depth(texture2D(u_depth,(coord.xy+1.0)*0.5));return coord.z > depth+0.0005;}float occlusionFade(vec4 frag) {vec3 coord=frag.xyz/frag.w;
176vec3 df=vec3(5.0*u_depth_size_inv,0.0);vec2 uv=0.5*coord.xy+0.5;vec4 depth=vec4(
177unpack_depth(texture2D(u_depth,uv-df.xz)),unpack_depth(texture2D(u_depth,uv+df.xz)),unpack_depth(texture2D(u_depth,uv-df.zy)),unpack_depth(texture2D(u_depth,uv+df.zy))
178);return dot(vec4(0.25),vec4(1.0)-clamp(300.0*(vec4(coord.z-0.001)-depth),0.0,1.0));}vec4 fourSample(vec2 pos,vec2 off) {
179#ifdef TERRAIN_DEM_FLOAT_FORMAT
180float tl=texture2D(u_dem,pos).a;float tr=texture2D(u_dem,pos+vec2(off.x,0.0)).a;float bl=texture2D(u_dem,pos+vec2(0.0,off.y)).a;float br=texture2D(u_dem,pos+off).a;
181#else
182vec4 demtl=vec4(texture2D(u_dem,pos).xyz*255.0,-1.0);float tl=dot(demtl,u_dem_unpack);vec4 demtr=vec4(texture2D(u_dem,pos+vec2(off.x,0.0)).xyz*255.0,-1.0);float tr=dot(demtr,u_dem_unpack);vec4 dembl=vec4(texture2D(u_dem,pos+vec2(0.0,off.y)).xyz*255.0,-1.0);float bl=dot(dembl,u_dem_unpack);vec4 dembr=vec4(texture2D(u_dem,pos+off).xyz*255.0,-1.0);float br=dot(dembr,u_dem_unpack);
183#endif
184return vec4(tl,tr,bl,br);}float flatElevation(vec2 pack) {vec2 apos=floor(pack/8.0);vec2 span=10.0*(pack-apos*8.0);vec2 uvTex=(apos-vec2(1.0,1.0))/8190.0;float size=u_dem_size+2.0;float dd=1.0/size;vec2 pos=u_dem_size*(uvTex*u_dem_scale+u_dem_tl)+1.0;vec2 f=fract(pos);pos=(pos-f+0.5)*dd;vec4 h=fourSample(pos,vec2(dd));float z=mix(mix(h.x,h.y,f.x),mix(h.z,h.w,f.x),f.y);vec2 w=floor(0.5*(span*u_meter_to_dem-1.0));vec2 d=dd*w;h=fourSample(pos-d,2.0*d+vec2(dd));vec4 diff=abs(h.xzxy-h.ywzw);vec2 slope=min(vec2(0.25),u_meter_to_dem*0.5*(diff.xz+diff.yw)/(2.0*w+vec2(1.0)));vec2 fix=slope*span;float base=z+max(fix.x,fix.y);return u_exaggeration*base;}float elevationFromUint16(float word) {return u_exaggeration*(word/ELEVATION_SCALE-ELEVATION_OFFSET);}
185#else
186float elevation(vec2 pos) { return 0.0; }bool isOccluded(vec4 frag) { return false; }float occlusionFade(vec4 frag) { return 1.0; }
187#endif`,Tu=`#ifdef FOG
188uniform mediump vec4 u_fog_color;uniform mediump vec2 u_fog_range;uniform mediump float u_fog_horizon_blend;uniform mediump mat4 u_fog_matrix;varying vec3 v_fog_pos;float fog_range(float depth) {return (depth-u_fog_range[0])/(u_fog_range[1]-u_fog_range[0]);}float fog_horizon_blending(vec3 camera_dir) {float t=max(0.0,camera_dir.z/u_fog_horizon_blend);return u_fog_color.a*exp(-3.0*t*t);}float fog_opacity(float t) {const float decay=6.0;float falloff=1.0-min(1.0,exp(-decay*t));falloff*=falloff*falloff;return u_fog_color.a*min(1.0,1.00747*falloff);}vec3 fog_position(vec3 pos) {return (u_fog_matrix*vec4(pos,1.0)).xyz;}vec3 fog_position(vec2 pos) {return fog_position(vec3(pos,0.0));}float fog(vec3 pos) {float depth=length(pos);float opacity=fog_opacity(fog_range(depth));return opacity*fog_horizon_blending(pos/depth);}
189#endif`,ja=`#ifdef FOG
190uniform mediump vec4 u_fog_color;uniform mediump vec2 u_fog_range;uniform mediump float u_fog_horizon_blend;uniform mediump float u_fog_temporal_offset;varying vec3 v_fog_pos;uniform highp vec3 u_frustum_tl;uniform highp vec3 u_frustum_tr;uniform highp vec3 u_frustum_br;uniform highp vec3 u_frustum_bl;uniform highp vec3 u_globe_pos;uniform highp float u_globe_radius;uniform highp vec2 u_viewport;uniform float u_globe_transition;uniform int u_is_globe;float fog_range(float depth) {return (depth-u_fog_range[0])/(u_fog_range[1]-u_fog_range[0]);}float fog_horizon_blending(vec3 camera_dir) {float t=max(0.0,camera_dir.z/u_fog_horizon_blend);return u_fog_color.a*exp(-3.0*t*t);}float fog_opacity(float t) {const float decay=6.0;float falloff=1.0-min(1.0,exp(-decay*t));falloff*=falloff*falloff;return u_fog_color.a*min(1.0,1.00747*falloff);}float globe_glow_progress() {highp vec2 uv=gl_FragCoord.xy/u_viewport;highp vec3 ray_dir=mix(
191mix(u_frustum_tl,u_frustum_tr,uv.x),mix(u_frustum_bl,u_frustum_br,uv.x),1.0-uv.y);highp vec3 dir=normalize(ray_dir);highp vec3 closest_point=dot(u_globe_pos,dir)*dir;highp float sdf=length(closest_point-u_globe_pos)/u_globe_radius;return sdf+PI*0.5;}float fog_opacity(vec3 pos) {float depth=length(pos);return fog_opacity(fog_range(depth));}vec3 fog_apply(vec3 color,vec3 pos) {float depth=length(pos);float opacity;if (u_is_globe==1) {float glow_progress=globe_glow_progress();float t=mix(glow_progress,depth,u_globe_transition);opacity=fog_opacity(fog_range(t));} else {opacity=fog_opacity(fog_range(depth));opacity*=fog_horizon_blending(pos/depth);}return mix(color,u_fog_color.rgb,opacity);}vec4 fog_apply_from_vert(vec4 color,float fog_opac) {float alpha=EPSILON+color.a;color.rgb=mix(color.rgb/alpha,u_fog_color.rgb,fog_opac)*alpha;return color;}
191vec3 fog_apply_sky_gradient(vec3 camera_ray,vec3 sky_color) {float horizon_blend=fog_horizon_blending(normalize(camera_ray));return mix(sky_color,u_fog_color.rgb,horizon_blend);}vec4 fog_apply_premultiplied(vec4 color,vec3 pos) {float alpha=EPSILON+color.a;color.rgb=fog_apply(color.rgb/alpha,pos)*alpha;return color;}vec3 fog_dither(vec3 color) {vec2 dither_seed=gl_FragCoord.xy+u_fog_temporal_offset;return dither(color,dither_seed);}vec4 fog_dither(vec4 color) {return vec4(fog_dither(color.rgb),color.a);}
192#endif`;let Bc={},tc={};const pa=[];Ys(mh,pa),Ys(Hs,pa),Ys(Tu,pa),Ys(ja,pa),Bc=Sr("",Hs),tc=Sr(ja,Tu);const Yd=Sr(`
193#if __VERSION__ >=300
194#define varying in
195#define gl_FragColor glFragColor
196#define texture2D texture
197#define textureCube texture
198out vec4 glFragColor;
199#endif
200highp vec3 hash(highp vec2 p) {highp vec3 p3=fract(p.xyx*vec3(443.8975,397.2973,491.1871));p3+=dot(p3,p3.yxz+19.19);return fract((p3.xxy+p3.yzz)*p3.zyx);}vec3 dither(vec3 color,highp vec2 seed) {vec3 rnd=hash(seed)+hash(seed+0.59374)-0.5;return color+rnd/255.0;}highp float unpack_depth(highp vec4 rgba_depth)
201{const highp vec4 bit_shift=vec4(1.0/(255.0*255.0*255.0),1.0/(255.0*255.0),1.0/255.0,1.0);return dot(rgba_depth,bit_shift)*2.0-1.0;}highp vec4 pack_depth(highp float ndc_z) {highp float depth=ndc_z*0.5+0.5;const highp vec4 bit_shift=vec4(255.0*255.0*255.0,255.0*255.0,255.0,1.0);const highp vec4 bit_mask =vec4(0.0,1.0/255.0,1.0/255.0,1.0/255.0);highp vec4 res=fract(depth*bit_shift);res-=res.xxyz*bit_mask;return res;}`,`
202#if __VERSION__ >=300
203#define attribute in
204#define varying out
205#define texture2D texture
206#endif
207float wrap(float n,float min,float max) {float d=max-min;float w=mod(mod(n-min,d)+d,d)+min;return (w==min) ? max : w;}
208#ifdef PROJECTION_GLOBE_VIEW
209vec3 mercator_tile_position(mat4 matrix,vec2 tile_anchor,vec3 tile_id,vec2 mercator_center) {
210#ifndef PROJECTED_POS_ON_VIEWPORT
211float tiles=tile_id.z;vec2 mercator=(tile_anchor/EXTENT+tile_id.xy)/tiles;mercator-=mercator_center;mercator.x=wrap(mercator.x,-0.5,0.5);vec4 mercator_tile=vec4(mercator.xy*EXTENT,EXTENT/(2.0*PI),1.0);mercator_tile=matrix*mercator_tile;return mercator_tile.xyz;
212#else
213return vec3(0.0);
214#endif
215}vec3 mix_globe_mercator(vec3 globe,vec3 mercator,float t) {return mix(globe,mercator,t);}mat3 globe_mercator_surface_vectors(vec3 pos_normal,vec3 up_dir,float zoom_transition) {vec3 normal=zoom_transition==0.0 ? pos_normal : normalize(mix(pos_normal,up_dir,zoom_transition));vec3 xAxis=normalize(vec3(normal.z,0.0,-normal.x));vec3 yAxis=normalize(cross(normal,xAxis));return mat3(xAxis,yAxis,normal);}
216#endif
217vec2 unpack_float(const float packedValue) {int packedIntValue=int(packedValue);int v0=packedIntValue/256;return vec2(v0,packedIntValue-v0*256);}vec2 unpack_opacity(const float packedOpacity) {int intOpacity=int(packedOpacity)/2;return vec2(float(intOpacity)/127.0,mod(packedOpacity,2.0));}vec4 decode_color(const vec2 encodedColor) {return vec4(
218unpack_float(encodedColor[0])/255.0,unpack_float(encodedColor[1])/255.0
219);}float unpack_mix_vec2(const vec2 packedValue,const float t) {return mix(packedValue[0],packedValue[1],t);}vec4 unpack_mix_color(const vec4 packedColors,const float t) {vec4 minColor=decode_color(vec2(packedColors[0],packedColors[1]));vec4 maxColor=decode_color(vec2(packedColors[2],packedColors[3]));return mix(minColor,maxColor,t);}vec2 get_pattern_pos(const vec2 pixel_coord_upper,const vec2 pixel_coord_lower,const vec2 pattern_size,const float tile_units_to_pixels,const vec2 pos) {vec2 offset=mod(mod(mod(pixel_coord_upper,pattern_size)*256.0,pattern_size)*256.0+pixel_coord_lower,pattern_size);return (tile_units_to_pixels*pos+offset)/pattern_size;}const vec4 AWAY=vec4(-1000.0,-1000.0,-1000.0,1);//Normalized device coordinate that is not rendered.`),Eu=mh,Zd=`
220#ifdef GL_ES
221precision mediump float;
222#else
223
224#if !defined(lowp)
225#define lowp
226#endif
227
228#if !defined(mediump)
229#define mediump
230#endif
231
232#if !defined(highp)
233#define highp
234#endif
235
236#endif`;var gh={background:Sr(`uniform vec4 u_color;uniform float u_opacity;
237#ifdef LIGHTING_3D_MODE
238varying vec4 v_color;
239#endif
240void main() {vec4 out_color;
241#ifdef LIGHTING_3D_MODE
242out_color=v_color;
243#else
244out_color=u_color;
245#endif
246#ifdef FOG
247out_color=fog_dither(fog_apply_premultiplied(out_color,v_fog_pos));
248#endif
249gl_FragColor=out_color*u_opacity;
250#ifdef OVERDRAW_INSPECTOR
251gl_FragColor=vec4(1.0);
252#endif
253}`,`attribute vec2 a_pos;uniform mat4 u_matrix;
254#ifdef LIGHTING_3D_MODE
255uniform vec4 u_color;varying vec4 v_color;
256#endif
257void main() {gl_Position=u_matrix*vec4(a_pos,0,1);
258#ifdef LIGHTING_3D_MODE
259v_color=apply_lighting(u_color);
260#endif
261#ifdef FOG
262v_fog_pos=fog_position(a_pos);
263#endif
264}`),backgroundPattern:Sr(`uniform vec2 u_pattern_tl;uniform vec2 u_pattern_br;uniform vec2 u_texsize;uniform float u_opacity;uniform sampler2D u_image;varying vec2 v_pos;void main() {vec2 imagecoord=mod(v_pos,1.0);vec2 pos=mix(u_pattern_tl/u_texsize,u_pattern_br/u_texsize,imagecoord);vec4 out_color=texture2D(u_image,pos);
265#ifdef LIGHTING_3D_MODE
266out_color=apply_lighting(out_color);
267#endif
268#ifdef FOG
269out_color=fog_dither(fog_apply_premultiplied(out_color,v_fog_pos));
270#endif
271gl_FragColor=out_color*u_opacity;
272#ifdef OVERDRAW_INSPECTOR
273gl_FragColor=vec4(1.0);
274#endif
275}`,`uniform mat4 u_matrix;uniform vec2 u_pattern_size;uniform vec2 u_pixel_coord_upper;uniform vec2 u_pixel_coord_lower;uniform float u_tile_units_to_pixels;attribute vec2 a_pos;varying vec2 v_pos;void main() {gl_Position=u_matrix*vec4(a_pos,0,1);v_pos=get_pattern_pos(u_pixel_coord_upper,u_pixel_coord_lower,u_pattern_size,u_tile_units_to_pixels,a_pos);
276#ifdef FOG
277v_fog_pos=fog_position(a_pos);
278#endif
279}`),circle:Sr(`varying vec3 v_data;varying float v_visibility;
280#pragma mapbox: define highp vec4 color
281#pragma mapbox: define mediump float radius
282#pragma mapbox: define lowp float blur
283#pragma mapbox: define lowp float opacity
284#pragma mapbox: define highp vec4 stroke_color
285#pragma mapbox: define mediump float stroke_width
286#pragma mapbox: define lowp float stroke_opacity
287void main() {
288#pragma mapbox: initialize highp vec4 color
289#pragma mapbox: initialize mediump float radius
290#pragma mapbox: initialize lowp float blur
291#pragma mapbox: initialize lowp float opacity
292#pragma mapbox: initialize highp vec4 stroke_color
293#pragma mapbox: initialize mediump float stroke_width
294#pragma mapbox: initialize lowp float stroke_opacity
295vec2 extrude=v_data.xy;float extrude_length=length(extrude);lowp float antialiasblur=v_data.z;float antialiased_blur=-max(blur,antialiasblur);float opacity_t=smoothstep(0.0,antialiased_blur,extrude_length-1.0);float color_t=stroke_width < 0.01 ? 0.0 : smoothstep(
296antialiased_blur,0.0,extrude_length-radius/(radius+stroke_width)
297);vec4 out_color=mix(color*opacity,stroke_color*stroke_opacity,color_t);
298#ifdef LIGHTING_3D_MODE
299out_color=apply_lighting(out_color);
300#endif
301#ifdef FOG
302out_color=fog_apply_premultiplied(out_color,v_fog_pos);
303#endif
304gl_FragColor=out_color*(v_visibility*opacity_t);
305#ifdef OVERDRAW_INSPECTOR
306gl_FragColor=vec4(1.0);
307#endif
308}`,`#define NUM_VISIBILITY_RINGS 2
309#define INV_SQRT2 0.70710678
310#define ELEVATION_BIAS 0.0001
311#define NUM_SAMPLES_PER_RING 16
312uniform mat4 u_matrix;uniform mat2 u_extrude_scale;uniform lowp float u_device_pixel_ratio;uniform highp float u_camera_to_center_distance;attribute vec2 a_pos;
313#ifdef PROJECTION_GLOBE_VIEW
314attribute vec3 a_pos_3;attribute vec3 a_pos_normal_3;uniform mat4 u_inv_rot_matrix;uniform vec2 u_merc_center;uniform vec3 u_tile_id;uniform float u_zoom_transition;uniform vec3 u_up_dir;
315#endif
316varying vec3 v_data;varying float v_visibility;
317#pragma mapbox: define highp vec4 color
318#pragma mapbox: define mediump float radius
319#pragma mapbox: define lowp float blur
320#pragma mapbox: define lowp float opacity
321#pragma mapbox: define highp vec4 stroke_color
322#pragma mapbox: define mediump float stroke_width
323#pragma mapbox: define lowp float stroke_opacity
324vec2 calc_offset(vec2 extrusion,float radius,float stroke_width, float view_scale) {return extrusion*(radius+stroke_width)*u_extrude_scale*view_scale;}float cantilevered_elevation(vec2 pos,float radius,float stroke_width,float view_scale) {vec2 c1=pos+calc_offset(vec2(-1,-1),radius,stroke_width,view_scale);vec2 c2=pos+calc_offset(vec2(1,-1),radius,stroke_width,view_scale);vec2 c3=pos+calc_offset(vec2(1,1),radius,stroke_width,view_scale);vec2 c4=pos+calc_offset(vec2(-1,1),radius,stroke_width,view_scale);float h1=elevation(c1)+ELEVATION_BIAS;float h2=elevation(c2)+ELEVATION_BIAS;float h3=elevation(c3)+ELEVATION_BIAS;float h4=elevation(c4)+ELEVATION_BIAS;return max(h4,max(h3,max(h1,h2)));}float circle_elevation(vec2 pos) {
325#if defined(TERRAIN)
326return elevation(pos)+ELEVATION_BIAS;
327#else
328return 0.0;
329#endif
330}vec4 project_vertex(vec2 extrusion,vec4 world_center,vec4 projected_center,float radius,float stroke_width, float view_scale,mat3 surface_vectors) {vec2 sample_offset=calc_offset(extrusion,radius,stroke_width,view_scale);
331#ifdef PITCH_WITH_MAP
332#ifdef PROJECTION_GLOBE_VIEW
333return u_matrix*( world_center+vec4(sample_offset.x*surface_vectors[0]+sample_offset.y*surface_vectors[1],0) );
334#else
335return u_matrix*( world_center+vec4(sample_offset,0,0) );
336#endif
337#else
338return projected_center+vec4(sample_offset,0,0);
339#endif
340}float get_sample_step() {
341#ifdef PITCH_WITH_MAP
342return 2.0*PI/float(NUM_SAMPLES_PER_RING);
343#else
344return PI/float(NUM_SAMPLES_PER_RING);
345#endif
346}void main(void) {
347#pragma mapbox: initialize highp vec4 color
348#pragma mapbox: initialize mediump float radius
349#pragma mapbox: initialize lowp float blur
350#pragma mapbox: initialize lowp float opacity
351#pragma mapbox: initialize highp vec4 stroke_color
352#pragma mapbox: initialize mediump float stroke_width
353#pragma mapbox: initialize lowp float stroke_opacity
354vec2 extrude=vec2(mod(a_pos,2.0)*2.0-1.0);vec2 circle_center=floor(a_pos*0.5);vec4 world_center;mat3 surface_vectors;
355#ifdef PROJECTION_GLOBE_VIEW
356vec3 pos_normal_3=a_pos_normal_3/16384.0;surface_vectors=globe_mercator_surface_vectors(pos_normal_3,u_up_dir,u_zoom_transition);vec3 surface_extrusion=extrude.x*surface_vectors[0]+extrude.y*surface_vectors[1];vec3 globe_elevation=elevationVector(circle_center)*circle_elevation(circle_center);vec3 globe_pos=a_pos_3+surface_extrusion+globe_elevation;vec3 mercator_elevation=u_up_dir*u_tile_up_scale*circle_elevation(circle_center);vec3 merc_pos=mercator_tile_position(u_inv_rot_matrix,circle_center,u_tile_id,u_merc_center)+surface_extrusion+mercator_elevation;vec3 pos=mix_globe_mercator(globe_pos,merc_pos,u_zoom_transition);world_center=vec4(pos,1);
357#else 
358surface_vectors=mat3(1.0);float height=circle_elevation(circle_center);world_center=vec4(circle_center,height,1);
359#endif
360vec4 projected_center=u_matrix*world_center;float view_scale=0.0;
361#ifdef PITCH_WITH_MAP
362#ifdef SCALE_WITH_MAP
363view_scale=1.0;
364#else
365view_scale=projected_center.w/u_camera_to_center_distance;
366#endif
367#else
368#ifdef SCALE_WITH_MAP
369view_scale=u_camera_to_center_distance;
370#else
371view_scale=projected_center.w;
372#endif
373#endif
374gl_Position=project_vertex(extrude,world_center,projected_center,radiu
374s,stroke_width,view_scale,surface_vectors);float visibility=0.0;
375#ifdef TERRAIN
376float step=get_sample_step();vec4 occlusion_world_center;vec4 occlusion_projected_center;
377#ifdef PITCH_WITH_MAP
378float cantilevered_height=cantilevered_elevation(circle_center,radius,stroke_width,view_scale);occlusion_world_center=vec4(circle_center,cantilevered_height,1);occlusion_projected_center=u_matrix*occlusion_world_center;
379#else
380occlusion_world_center=world_center;occlusion_projected_center=projected_center;
381#endif
382for(int ring=0; ring < NUM_VISIBILITY_RINGS; ring++) {float scale=(float(ring)+1.0)/float(NUM_VISIBILITY_RINGS);for(int i=0; i < NUM_SAMPLES_PER_RING; i++) {vec2 extrusion=vec2(cos(step*float(i)),-sin(step*float(i)))*scale;vec4 frag_pos=project_vertex(extrusion,occlusion_world_center,occlusion_projected_center,radius,stroke_width,view_scale,surface_vectors);visibility+=float(!isOccluded(frag_pos));}}visibility/=float(NUM_VISIBILITY_RINGS)*float(NUM_SAMPLES_PER_RING);
383#else
384visibility=1.0;
385#endif
386#ifdef PROJECTION_GLOBE_VIEW
387visibility=1.0;
388#endif
389v_visibility=visibility;lowp float antialiasblur=1.0/u_device_pixel_ratio/(radius+stroke_width);v_data=vec3(extrude.x,extrude.y,antialiasblur);
390#ifdef FOG
391v_fog_pos=fog_position(world_center.xyz);
392#endif
393}`),clippingMask:Sr("void main() {gl_FragColor=vec4(1.0);}","attribute vec2 a_pos;uniform mat4 u_matrix;void main() {gl_Position=u_matrix*vec4(a_pos,0,1);}"),heatmap:Sr(`uniform highp float u_intensity;varying vec2 v_extrude;
394#pragma mapbox: define highp float weight
395#define GAUSS_COEF 0.3989422804014327
396void main() {
397#pragma mapbox: initialize highp float weight
398float d=-0.5*3.0*3.0*dot(v_extrude,v_extrude);float val=weight*u_intensity*GAUSS_COEF*exp(d);gl_FragColor=vec4(val,1.0,1.0,1.0);
399#ifdef FOG
400if (u_is_globe==0) {gl_FragColor.r*=pow(1.0-fog_opacity(v_fog_pos),2.0);}
401#endif
402#ifdef OVERDRAW_INSPECTOR
403gl_FragColor=vec4(1.0);
404#endif
405}`,`uniform mat4 u_matrix;uniform float u_extrude_scale;uniform float u_opacity;uniform float u_intensity;attribute vec2 a_pos;
406#ifdef PROJECTION_GLOBE_VIEW
407attribute vec3 a_pos_3;attribute vec3 a_pos_normal_3;uniform mat4 u_inv_rot_matrix;uniform vec2 u_merc_center;uniform vec3 u_tile_id;uniform float u_zoom_transition;uniform vec3 u_up_dir;
408#endif
409varying vec2 v_extrude;
410#pragma mapbox: define highp float weight
411#pragma mapbox: define mediump float radius
412const highp float ZERO=1.0/255.0/16.0;
413#define GAUSS_COEF 0.3989422804014327
414void main(void) {
415#pragma mapbox: initialize highp float weight
416#pragma mapbox: initialize mediump float radius
417vec2 unscaled_extrude=vec2(mod(a_pos,2.0)*2.0-1.0);float S=sqrt(-2.0*log(ZERO/weight/u_intensity/GAUSS_COEF))/3.0;v_extrude=S*unscaled_extrude;vec2 extrude=v_extrude*radius*u_extrude_scale;vec2 tilePos=floor(a_pos*0.5);vec3 pos;
418#ifdef PROJECTION_GLOBE_VIEW
419vec3 pos_normal_3=a_pos_normal_3/16384.0;mat3 surface_vectors=globe_mercator_surface_vectors(pos_normal_3,u_up_dir,u_zoom_transition);vec3 surface_extrusion=extrude.x*surface_vectors[0]+extrude.y*surface_vectors[1];vec3 globe_elevation=elevationVector(tilePos)*elevation(tilePos);vec3 globe_pos=a_pos_3+surface_extrusion+globe_elevation;vec3 mercator_elevation=u_up_dir*u_tile_up_scale*elevation(tilePos);vec3 merc_pos=mercator_tile_position(u_inv_rot_matrix,tilePos,u_tile_id,u_merc_center)+surface_extrusion+mercator_elevation;pos=mix_globe_mercator(globe_pos,merc_pos,u_zoom_transition);
420#else
421pos=vec3(tilePos+extrude,elevation(tilePos));
422#endif
423gl_Position=u_matrix*vec4(pos,1);
424#ifdef FOG
425v_fog_pos=fog_position(pos);
426#endif
427}`),heatmapTexture:Sr(`uniform sampler2D u_image;uniform sampler2D u_color_ramp;uniform float u_opacity;varying vec2 v_pos;void main() {float t=texture2D(u_image,v_pos).r;vec4 color=texture2D(u_color_ramp,vec2(t,0.5));gl_FragColor=color*u_opacity;
428#ifdef OVERDRAW_INSPECTOR
429gl_FragColor=vec4(0.0);
430#endif
431}`,"attribute vec2 a_pos;varying vec2 v_pos;void main() {gl_Position=vec4(a_pos,0,1);v_pos=a_pos*0.5+0.5;}"),collisionBox:Sr("varying float v_placed;varying float v_notUsed;void main() {vec4 red =vec4(1.0,0.0,0.0,1.0);vec4 blue=vec4(0.0,0.0,1.0,0.5);gl_FragColor =mix(red,blue,step(0.5,v_placed))*0.5;gl_FragColor*=mix(1.0,0.1,step(0.5,v_notUsed));}",`attribute vec3 a_pos;attribute vec2 a_anchor_pos;attribute vec2 a_extrude;attribute vec2 a_placed;attribute vec2 a_shift;attribute float a_size_scale;attribute vec2 a_padding;uniform mat4 u_matrix;uniform vec2 u_extrude_scale;uniform float u_camera_to_center_distance;varying float v_placed;varying float v_notUsed;void main() {vec4 projectedPoint=u_matrix*vec4(a_pos+elevationVector(a_anchor_pos)*elevation(a_anchor_pos),1);highp float camera_to_anchor_distance=projectedPoint.w;highp float collision_perspective_ratio=clamp(
4320.5+0.5*(u_camera_to_center_distance/camera_to_anchor_distance),0.0,1.5);gl_Position=projectedPoint;gl_Position.xy+=(a_extrude*a_size_scale+a_shift+a_padding)*u_extrude_scale*gl_Position.w*collision_perspective_ratio;v_placed=a_placed.x;v_notUsed=a_placed.y;}`),collisionCircle:Sr("varying float v_radius;varying vec2 v_extrude;varying float v_perspective_ratio;varying float v_collision;void main() {float alpha=0.5*min(v_perspective_ratio,1.0);float stroke_radius=0.9*max(v_perspective_ratio,1.0);float distance_to_center=length(v_extrude);float distance_to_edge=abs(distance_to_center-v_radius);float opacity_t=smoothstep(-stroke_radius,0.0,-distance_to_edge);vec4 color=mix(vec4(0.0,0.0,1.0,0.5),vec4(1.0,0.0,0.0,1.0),v_collision);gl_FragColor=color*alpha*opacity_t;}",`attribute vec2 a_pos_2f;attribute float a_radius;attribute vec2 a_flags;uniform mat4 u_matrix;uniform mat4 u_inv_matrix;uniform vec2 u_viewport_size;uniform float u_camera_to_center_distance;varying float v_radius;varying vec2 v_extrude;varying float v_perspective_ratio;varying float v_collision;vec3 toTilePosition(vec2 screenPos) {vec4 rayStart=u_inv_matrix*vec4(screenPos,-1.0,1.0);vec4 rayEnd  =u_inv_matrix*vec4(screenPos, 1.0,1.0);rayStart.xyz/=rayStart.w;rayEnd.xyz  /=rayEnd.w;highp float t=(0.0-rayStart.z)/(rayEnd.z-rayStart.z);return mix(rayStart.xyz,rayEnd.xyz,t);}void main() {vec2 quadCenterPos=a_pos_2f;float radius=a_radius;float collision=a_flags.x;float vertexIdx=a_flags.y;vec2 quadVertexOffset=vec2(
433mix(-1.0,1.0,float(vertexIdx >=2.0)),mix(-1.0,1.0,float(vertexIdx >=1.0 && vertexIdx <=2.0)));vec2 quadVertexExtent=quadVertexOffset*radius;vec3 tilePos=toTilePosition(quadCenterPos);vec4 clipPos=u_matrix*vec4(tilePos,1.0);highp float camera_to_anchor_distance=clipPos.w;highp float collision_perspective_ratio=clamp(
4340.5+0.5*(u_camera_to_center_distance/camera_to_anchor_distance),0.0,4.0);float padding_factor=1.2;v_radius=radius;v_extrude=quadVertexExtent*padding_factor;v_perspective_ratio=collision_perspective_ratio;v_collision=collision;gl_Position=vec4(clipPos.xyz/clipPos.w,1.0)+vec4(quadVertexExtent*padding_factor/u_viewport_size*2.0,0.0,0.0);}`),debug:Sr("uniform highp vec4 u_color;uniform sampler2D u_overlay;varying vec2 v_uv;void main() {vec4 overlay_color=texture2D(u_overlay,v_uv);gl_FragColor=mix(u_color,overlay_color,overlay_color.a);}",`attribute vec2 a_pos;
435#ifdef PROJECTION_GLOBE_VIEW
436attribute vec3 a_pos_3;
437#endif
438varying vec2 v_uv;uniform mat4 u_matrix;uniform float u_overlay_scale;void main() {float h=elevation(a_pos);v_uv=a_pos/8192.0;
439#ifdef PROJECTION_GLOBE_VIEW
440gl_Position=u_matrix*vec4(a_pos_3+elevationVector(a_pos)*h,1);
441#else
442gl_Position=u_matrix*vec4(a_pos*u_overlay_scale,h,1);
443#endif
444}`),fill:Sr(`#pragma mapbox: define highp vec4 color
445#pragma mapbox: define lowp float opacity
446void main() {
447#pragma mapbox: initialize highp vec4 color
448#pragma mapbox: initialize lowp float opacity
449vec4 out_color=color;
450#ifdef LIGHTING_3D_MODE
451out_color=apply_lighting(out_color);
452#endif
453#ifdef FOG
454out_color=fog_dither(fog_apply_premultiplied(out_color,v_fog_pos));
455#endif
456gl_FragColor=out_color*opacity;
457#ifdef OVERDRAW_INSPECTOR
458gl_FragColor=vec4(1.0);
459#endif
460}`,`attribute vec2 a_pos;uniform mat4 u_matrix;
461#pragma mapbox: define highp vec4 color
462#pragma mapbox: define lowp float opacity
463void main() {
464#pragma mapbox: initialize highp vec4 color
465#pragma mapbox: initialize lowp float opacity
466gl_Position=u_matrix*vec4(a_pos,0,1);
467#ifdef FOG
468v_fog_pos=fog_position(a_pos);
469#endif
470}`),fillOutline:Sr(`varying vec2 v_pos;
471#pragma mapbox: define highp vec4 outline_color
472#pragma mapbox: define lowp float opacity
473void main() {
474#pragma mapbox: initialize highp vec4 outline_color
475#pragma mapbox: initialize lowp float opacity
476float dist=length(v_pos-gl_FragCoord.xy);float alpha=1.0-smoothstep(0.0,1.0,dist);vec4 out_color=outline_color;
477#ifdef LIGHTING_3D_MODE
478out_color=apply_lighting(out_color);
479#endif
480#ifdef FOG
481out_color=fog_dither(fog_apply_premultiplied(out_color,v_fog_pos));
482#endif
483gl_FragColor=out_color*(alpha*opacity);
484#ifdef OVERDRAW_INSPECTOR
485gl_FragColor=vec4(1.0);
486#endif
487}`,`attribute vec2 a_pos;uniform mat4 u_matrix;uniform vec2 u_world;varying vec2 v_pos;
488#pragma mapbox: define highp vec4 outline_color
489#pragma mapbox: define lowp float opacity
490void main() {
491#pragma mapbox: initialize highp vec4 outline_color
492#pragma mapbox: initialize lowp float opacity
493gl_Position=u_matrix*vec4(a_pos,0,1);v_pos=(gl_Position.xy/gl_Position.w+1.0)/2.0*u_world;
494#ifdef FOG
495v_fog_pos=fog_position(a_pos);
496#endif
497}`),fillOutlinePattern:Sr(`uniform vec2 u_texsize;uniform sampler2D u_image;varying vec2 v_pos;varying vec2 v_pos_world;
498#pragma mapbox: define lowp float opacity
499#pragma mapbox: define lowp vec4 pattern
500void main() {
501#pragma mapbox: initialize lowp float opacity
502#pragma mapbox: initialize mediump vec4 pattern
503vec2 pattern_tl=pattern.xy;vec2 pattern_br=pattern.zw;vec2 imagecoord=mod(v_pos,1.0);vec2 pos=mix(pattern_tl/u_texsize,pattern_br/u_texsize,imagecoord);float dist=length(v_pos_world-gl_FragCoord.xy);float alpha=1.0-smoothstep(0.0,1.0,dist);vec4 out_color=texture2D(u_image,pos);
504#ifdef LIGHTING_3D_MODE
505out_color=apply_lighting(out_color);
506#endif
507#ifdef FOG
508out_color=fog_dither(fog_apply_premultiplied(out_color,v_fog_pos));
509#endif
510gl_FragColor=out_color*(alpha*opacity);
511#ifdef OVERDRAW_INSPECTOR
512gl_FragColor=vec4(1.0);
513#endif
514}`,`uniform mat4 u_matrix;uniform vec2 u_world;uniform vec2 u_pixel_coord_upper;uniform vec2 u_pixel_coord_lower;uniform float u_tile_units_to_pixels;attribute vec2 a_pos;varying vec2 v_pos;varying vec2 v_pos_world;
515#pragma mapbox: define lowp float opacity
516#pragma mapbox: define lowp vec4 pattern
517#pragma mapbox: define lowp float pixel_ratio
518void main() {
519#pragma mapbox: initialize lowp float opacity
520#pragma mapbox: initialize mediump vec4 pattern
521#pragma mapbox: initialize lowp float pixel_ratio
522vec2 pattern_tl=pattern.xy;vec2 pattern_br=pattern.zw;gl_Position=u_matrix*vec4(a_pos,0,1);vec2 display_size=(pattern_br-pattern_tl)/pixel_ratio;v_pos=get_pattern_pos(u_pixel_coord_upper,u_pixel_coord_lower,display_size,u_tile_units_to_pixels,a_pos);v_pos_world=(gl_Position.xy/gl_Position.w+1.0)/2.0*u_world;
523#ifdef FOG
524v_fog_pos=fog_position(a_pos);
525#endif
526}`),fillPattern:Sr(`uniform vec2 u_texsize;uniform sampler2D u_image;varying vec2 v_pos;
527#pragma mapbox: define lowp float opacity
528#pragma mapbox: define lowp vec4 pattern
529void main() {
530#pragma mapbox: initialize lowp float opacity
531#pragma mapbox: initialize mediump vec4 pattern
532vec2 pattern_tl=pattern.xy;vec2 pattern_br=pattern.zw;vec2 imagecoord=mod(v_pos,1.0);vec2 pos=mix(pattern_tl/u_texsize,pattern_br/u_texsize,imagecoord);vec4 out_color=texture2D(u_image,pos);
533#ifdef LIGHTING_3D_MODE
534out_color=apply_lighting(out_color);
535#endif
536#ifdef FOG
537out_color=fog_dither(fog_apply_premultiplied(out_color,v_fog_pos));
538#endif
539gl_FragColor=out_color*opacity;
540#ifdef OVERDRAW_INSPECTOR
541gl_FragColor=vec4(1.0);
542#endif
543}`,`uniform mat4 u_matrix;uniform vec2 u_pixel_coord_upper;uniform vec2 u_pixel_coord_lower;uniform float u_tile_units_to_pixels;attribute vec2 a_pos;varying vec2 v_pos;
544#pragma mapbox: define lowp float opacity
545#pragma mapbox: define lowp vec4 pattern
546#pragma mapbox: define lowp float pixel_ratio
547void main() {
548#pragma mapbox: initialize lowp float opacity
549#pragma mapbox: initialize mediump vec4 pattern
550#pragma mapbox: initialize lowp float pixel_ratio
551vec2 pattern_tl=pattern.xy;vec2 pattern_br=pattern.zw;vec2 display_size=(pattern_br-pattern_tl)/pixel_ratio;gl_Position=u_matrix*vec4(a_pos,0,1);v_pos=get_pattern_pos(u_pixel_coord_upper,u_pixel_coord_lower,display_size,u_tile_units_to_pixels,a_pos);
552#ifdef FOG
553v_fog_pos=fog_position(a_pos);
554#endif
555}`),fillExtrusion:Sr(`varying vec4 v_color;
556#ifdef RENDER_SHADOWS
557varying highp vec4 v_pos_light_view_0;varying highp vec4 v_pos_light_view_1;varying float v_depth;
558#endif
559#ifdef FAUX_AO
560uniform lowp vec2 u_ao;varying vec3 v_ao;
561#endif
562#ifdef ZERO_ROOF_RADIUS
563varying vec4 v_roof_color;
564#endif
565#if defined(ZERO_ROOF_RADIUS) || defined(RENDER_SHADOWS)
566varying highp vec3 v_normal;
567#endif
568void main() {
569#if defined(ZERO_ROOF_RADIUS) || defined(RENDER_SHADOWS)
570vec3 normal=v_normal;
571#endif
572float z;vec4 color;
573#ifdef ZERO_ROOF_RADIUS
574z=float(normal.z > 0.00001);color=mix(v_color,v_roof_color,z);
575#else
576color=v_color;
577#endif
578#ifdef FAUX_AO
579float intensity=u_ao[0];float h=max(0.0,v_ao.z);float h_floors=h/u_ao[1];float y_shade=1.0-0.9*intensity*min(v_ao.y,1.0);float shade=(1.0-0.08*intensity)*(y_shade+(1.0-y_shade)*(1.0-pow(1.0-min(h_floors/16.0,1.0
579),16.0)))+0.08*intensity*min(h_floors/160.0,1.0);float concave=v_ao.x*v_ao.x;
580#ifdef ZERO_ROOF_RADIUS
581concave*=(1.0-z);
582#endif
583float x_shade=mix(1.0,mix(0.6,0.75,min(h_floors/30.0,1.0)),intensity)+0.1*intensity*min(h,1.0);shade*=mix(1.0,x_shade*x_shade*x_shade,concave);color.rgb=color.rgb*shade;
584#endif
585#ifdef RENDER_SHADOWS
586#ifdef ZERO_ROOF_RADIUS
587normal=mix(normal,vec3(0.0,0.0,1.0),z);
588#endif
589color.xyz=shadowed_color_normal(color.xyz,normalize(normal),v_pos_light_view_0,v_pos_light_view_1,v_depth);
590#endif
591#ifdef FOG
592color=fog_dither(fog_apply_premultiplied(color,v_fog_pos));
593#endif
594gl_FragColor=color;
595#ifdef OVERDRAW_INSPECTOR
596gl_FragColor=vec4(1.0);
597#endif
598}`,`uniform mat4 u_matrix;uniform vec3 u_lightcolor;uniform lowp vec3 u_lightpos;uniform lowp float u_lightintensity;uniform float u_vertical_gradient;uniform lowp float u_opacity;uniform float u_edge_radius;attribute vec4 a_pos_normal_ed;attribute vec2 a_centroid_pos;
599#ifdef PROJECTION_GLOBE_VIEW
600attribute vec3 a_pos_3;attribute vec3 a_pos_normal_3;uniform mat4 u_inv_rot_matrix;uniform vec2 u_merc_center;uniform vec3 u_tile_id;uniform float u_zoom_transition;uniform vec3 u_up_dir;uniform float u_height_lift;
601#endif
602varying vec4 v_color;
603#ifdef RENDER_SHADOWS
604uniform mat4 u_light_matrix_0;uniform mat4 u_light_matrix_1;varying highp vec4 v_pos_light_view_0;varying highp vec4 v_pos_light_view_1;varying float v_depth;
605#endif
606#ifdef ZERO_ROOF_RADIUS
607varying vec4 v_roof_color;
608#endif
609#if defined(ZERO_ROOF_RADIUS) || defined(RENDER_SHADOWS)
610varying highp vec3 v_normal;
611#endif
612#ifdef FAUX_AO
613uniform lowp vec2 u_ao;varying vec3 v_ao;
614#endif
615#pragma mapbox: define highp float base
616#pragma mapbox: define highp float height
617#pragma mapbox: define highp vec4 color
618void main() {
619#pragma mapbox: initialize highp float base
620#pragma mapbox: initialize highp float height
621#pragma mapbox: initialize highp vec4 color
622vec4 pos_nx=floor(a_pos_normal_ed*0.5);vec4 top_up_ny_start=a_pos_normal_ed-2.0*pos_nx;vec3 top_up_ny=top_up_ny_start.xyz;float x_normal=pos_nx.z/8192.0;vec3 normal=top_up_ny.y==1.0 ? vec3(0.0,0.0,1.0) : normalize(vec3(x_normal,(2.0*top_up_ny.z-1.0)*(1.0-abs(x_normal)),0.0));
623#if defined(ZERO_ROOF_RADIUS) || defined(RENDER_SHADOWS)
624v_normal=normal;
625#endif
626base=max(0.0,base);height=max(0.0,top_up_ny.y==0.0 && top_up_ny.x==1.0 ? height-u_edge_radius : height);float t=top_up_ny.x;vec2 centroid_pos=vec2(0.0);
627#if defined(HAS_CENTROID) || defined(TERRAIN)
628centroid_pos=a_centroid_pos;
629#endif
630float ele=0.0;float h=0.0;float c_ele;vec3 pos;
631#ifdef TERRAIN
632bool flat_roof=centroid_pos.x !=0.0 && t > 0.0;ele=elevation(pos_nx.xy);c_ele=flat_roof ? centroid_pos.y==0.0 ? elevationFromUint16(centroid_pos.x) : flatElevation(centroid_pos) : ele;h=flat_roof ? max(c_ele+height,ele+base+2.0) : ele+(t > 0.0 ? height : base==0.0 ?-5.0 : base);pos=vec3(pos_nx.xy,h);
633#else
634h=t > 0.0 ? height : base;pos=vec3(pos_nx.xy,h);
635#endif
636#ifdef PROJECTION_GLOBE_VIEW
637float lift=float((t+base) > 0.0)*u_height_lift;h+=lift;vec3 globe_normal=normalize(mix(a_pos_normal_3/16384.0,u_up_dir,u_zoom_transition));vec3 globe_pos=a_pos_3+globe_normal*(u_tile_up_scale*h);vec3 merc_pos=mercator_tile_position(u_inv_rot_matrix,pos.xy,u_tile_id,u_merc_center)+u_up_dir*u_tile_up_scale*pos.z;pos=mix_globe_mercator(globe_pos,merc_pos,u_zoom_transition);
638#endif
639float hidden=float(centroid_pos.x==0.0 && centroid_pos.y==1.0);gl_Position=mix(u_matrix*vec4(pos,1),AWAY,hidden);
640#ifdef RENDER_SHADOWS
641v_pos_light_view_0=u_light_matrix_0*vec4(pos,1);v_pos_light_view_1=u_light_matrix_1*vec4(pos,1);v_depth=gl_Position.w;
642#endif
643float NdotL=0.0;float colorvalue=0.0;
644#ifdef LIGHTING_3D_MODE
645NdotL=calculate_NdotL(normal);
646#else
647colorvalue=color.r*0.2126+color.g*0.7152+color.b*0.0722;vec4 ambientlight=vec4(0.03,0.03,0.03,1.0);color+=ambientlight;NdotL=clamp(dot(normal,u_lightpos),0.0,1.0);NdotL=mix((1.0-u_lightintensity),max((1.0-colorvalue+u_lightintensity),1.0),NdotL);
648#endif
649if (normal.y !=0.0) {float r=0.84;
650#ifndef LIGHTING_3D_MODE
651r=mix(0.7,0.98,1.0-u_lightintensity);
652#endif
653NdotL*=(
654(1.0-u_vertical_gradient)+(u_vertical_gradient*clamp((t+base)*pow(height/150.0,0.5),r,1.0)));}v_color=vec4(0.0,0.0,0.0,1.0);
655#ifdef FAUX_AO
656float concave=pos_nx.w-floor(pos_nx.w*0.5)*2.0;float start=top_up_ny_start.w;float y_ground=1.0-clamp(t+base,0.0,1.0);float top_height=height;
657#ifdef TERRAIN
658top_height=mix(max(c_ele+height,ele+base+2.0),ele+height,float(centroid_pos.x==0.0))-ele;y_ground+=y_ground*5.0/max(3.0,top_height);
659#endif
660v_ao=vec3(mix(concave,-concave,start),y_ground,h-ele);NdotL*=(1.0+0.05*(1.0-top_up_ny.y)*u_ao[0]);
661#ifdef PROJECTION_GLOBE_VIEW
662top_height+=u_height_lift;
663#endif
664gl_Position.z-=(0.0000006*(min(top_height,500.)+2.0*min(base,500.0)+60.0*concave+3.0*start))*gl_Position.w;
665#endif
666#ifdef LIGHTING_3D_MODE
667v_color=apply_lighting(color,NdotL);
668#else
669v_color.rgb+=clamp(color.rgb*NdotL*u_lightcolor,mix(vec3(0.0),vec3(0.3),1.0-u_lightcolor),vec3(1.0));
670#endif
671v_color*=u_opacity;
672#ifdef ZERO_ROOF_RADIUS
673v_roof_color=vec4(0.0,0.0,0.0,1.0);
674#ifdef LIGHTING_3D_MODE
675v_roof_color=apply_lighting(color,calculate_NdotL(vec3(0.0,0.0,1.0)));
676#else
677float roofNdotL=clamp(u_lightpos.z,0.0,1.0);roofNdotL=mix((1.0-u_lightintensity),max((1.0-colorvalue+u_lightintensity),1.0),roofNdotL);v_roof_color.rgb+=clamp(color.rgb*roofNdotL*u_lightcolor,mix(vec3(0.0),vec3(0.3),1.0-u_lightcolor),vec3(1.0));
678#endif
679v_roof_color*=u_opacity;
680#endif
681#ifdef FOG
682v_fog_pos=fog_position(pos);
683#endif
684}`),fillExtrusionPattern:Sr(`uniform vec2 u_texsize;uniform sampler2D u_image;
685#ifdef FAUX_AO
686uniform lowp vec2 u_ao;varying vec3 v_ao;
687#endif
688#ifdef LIGHTING_3D_MODE
689varying float v_NdotL;
690#endif
691varying vec2 v_pos;varying vec4 v_lighting;uniform lowp float u_opacity;
692#pragma mapbox: define lowp float base
693#pragma mapbox: define lowp float height
694#pragma mapbox: define lowp vec4 pattern
695#pragma mapbox: define lowp float pixel_ratio
696void main() {
697#pragma mapbox: initialize lowp float base
698#pragma mapbox: initialize lowp float height
699#pragma mapbox: initialize mediump vec4 pattern
700#pragma mapbox: initialize lowp float pixel_ratio
701vec2 pattern_tl=pattern.xy;vec2 pattern_br=pattern.zw;vec2 imagecoord=mod(v_pos,1.0);vec2 pos=mix(pattern_tl/u_texsize,pattern_br/u_texsize,imagecoord);vec4 out_color=texture2D(u_image,pos);
702#ifdef LIGHTING_3D_MODE
703out_color=apply_lighting(out_color,v_NdotL)*u_opacity;
704#else
705out_color=out_color*v_lighting;
706#endif
707#ifdef FAUX_AO
708float intensity=u_ao[0];float h=max(0.0,v_ao.z);float h_floors=h/u_ao[1];float y_shade=1.0-0.9*intensity*min(v_ao.y,1.0);float shade=(1.0-0.08*intensity)*(y_shade+(1.0-y_shade)*(1.0-pow(1.0-min(h_floors/16.0,1.0),16.0)))+0.08*intensity*min(h_floors/160.0,1.0);float concave=v_ao.x*v_ao.x;float x_shade=mix(1.0,mix(0.6,0.75,min(h_floors/30.0,1.0)),intensity)+0.1*intensity*min(h,1.0);shade*=mix(1.0,x_shade*x_shade*x_shade,concave);out_color.rgb=out_color.rgb*shade;
709#endif
710#ifdef FOG
711out_color=fog_dither(fog_apply_premultiplied(out_color,v_fog_pos));
712#endif
713gl_FragColor=out_color;
714#ifdef OVERDRAW_INSPECTOR
715gl_FragColor=vec4(1.0);
716#endif
717}`,`uniform mat4 u_matrix;uniform vec2 u_pixel_coord_upper;uniform vec2 u_pixel_coord_lower;uniform float u_height_factor;uniform float u_tile_units_to_pixels;uniform float u_vertical_gradient;uniform lowp float u_opacity;uniform vec3 u_lightcolor;uniform lowp vec3 u_lightpos;uniform lowp float u_lightintensity;attribute vec4 a_pos_normal_ed;attribute vec2 a_centroid_pos;
718#ifdef PROJECTION_GLOBE_VIEW
719attribute vec3 a_pos_3;attribute vec3 a_pos_normal_3;uniform mat4 u_inv_rot_matrix;uniform vec2 u_merc_center;uniform vec3 u_tile_id;uniform float u_zoom_transition;uniform vec3 u_up_dir;uniform float u_height_lift;
720#endif
721varying vec2 v_pos;varying vec4 v_lighting;
722#ifdef FAUX_AO
723uniform lowp vec2 u_ao;varying vec3 v_ao;
724#endif
725#ifdef LIGHTING_3D_MODE
726varying float v_NdotL;
727#endif
728#pragma mapbox: define lowp float base
729#pragma mapbox: define lowp float height
730#pragma mapbox: define lowp vec4 pattern
731#pragma mapbox: define lowp float pixel_ratio
732void main() {
733#pragma mapbox: initialize lowp float base
734#pragma mapbox: initialize lowp float height
735#pragma mapbox: initialize mediump vec4 pattern
736#pragma mapbox: initialize lowp float pixel_ratio
737vec2 pattern_tl=pattern.xy;vec2 pattern_br=pattern.zw;vec4 pos_nx=floor(a_pos_normal_ed*0.5);mediump vec4 top_up_ny_start=a_pos_normal_ed-2.0*pos_nx;mediump vec3 top_up_ny=top_up_ny_start.xyz;float x_normal=pos_nx.z/8192.0;vec3 normal=top_up_ny.y==1.0 ? vec3(0.0,0.0,1.0) : normalize(vec3(x_normal,(2.0*top_up_ny.z-1.0)*(1.0-abs(x_normal)),0.0));float edgedistance=a_pos_normal_ed.w;vec2 display_size=(pattern_br-pattern_tl)/pixel_ratio;
737base=max(0.0,base);height=max(0.0,height);float t=top_up_ny.x;float z=t > 0.0 ? height : base;vec2 centroid_pos=vec2(0.0);
738#if defined(HAS_CENTROID) || defined(TERRAIN)
739centroid_pos=a_centroid_pos;
740#endif
741float ele=0.0;float h=z;vec3 p;float c_ele;
742#ifdef TERRAIN
743bool flat_roof=centroid_pos.x !=0.0 && t > 0.0;ele=elevation(pos_nx.xy);c_ele=flat_roof ? centroid_pos.y==0.0 ? elevationFromUint16(centroid_pos.x) : flatElevation(centroid_pos) : ele;h=flat_roof ? max(c_ele+height,ele+base+2.0) : ele+(t > 0.0 ? height : base==0.0 ?-5.0 : base);p=vec3(pos_nx.xy,h);
744#else
745p=vec3(pos_nx.xy,z);
746#endif
747#ifdef PROJECTION_GLOBE_VIEW
748float lift=float((t+base) > 0.0)*u_height_lift;h+=lift;vec3 globe_normal=normalize(mix(a_pos_normal_3/16384.0,u_up_dir,u_zoom_transition));vec3 globe_pos=a_pos_3+globe_normal*(u_tile_up_scale*(p.z+lift));vec3 merc_pos=mercator_tile_position(u_inv_rot_matrix,p.xy,u_tile_id,u_merc_center)+u_up_dir*u_tile_up_scale*p.z;p=mix_globe_mercator(globe_pos,merc_pos,u_zoom_transition);
749#endif
750float hidden=float(centroid_pos.x==0.0 && centroid_pos.y==1.0);gl_Position=mix(u_matrix*vec4(p,1),AWAY,hidden);vec2 pos=normal.z==1.0
751? pos_nx.xy
752: vec2(edgedistance,z*u_height_factor);v_pos=get_pattern_pos(u_pixel_coord_upper,u_pixel_coord_lower,display_size,u_tile_units_to_pixels,pos);v_lighting=vec4(0.0,0.0,0.0,1.0);float NdotL=0.0;
753#ifdef LIGHTING_3D_MODE
754NdotL=calculate_NdotL(normal);
755#else
756NdotL=clamp(dot(normal,u_lightpos),0.0,1.0);NdotL=mix((1.0-u_lightintensity),max((0.5+u_lightintensity),1.0),NdotL);
757#endif
758if (normal.y !=0.0) {float r=0.84;
759#ifndef LIGHTING_3D_MODE
760r=mix(0.7,0.98,1.0-u_lightintensity);
761#endif
762NdotL*=(
763(1.0-u_vertical_gradient)+(u_vertical_gradient*clamp((t+base)*pow(height/150.0,0.5),r,1.0)));}
764#ifdef FAUX_AO
765float concave=pos_nx.w-floor(pos_nx.w*0.5)*2.0;float start=top_up_ny_start.w;float y_ground=1.0-clamp(t+base,0.0,1.0);float top_height=height;
766#ifdef TERRAIN
767top_height=mix(max(c_ele+height,ele+base+2.0),ele+height,float(ce
767ntroid_pos.x==0.0))-ele;y_ground+=y_ground*5.0/max(3.0,top_height);
768#endif
769v_ao=vec3(mix(concave,-concave,start),y_ground,h-ele);NdotL*=(1.0+0.05*(1.0-top_up_ny.y)*u_ao[0]);
770#ifdef PROJECTION_GLOBE_VIEW
771top_height+=u_height_lift;
772#endif
773gl_Position.z-=(0.0000006*(min(top_height,500.)+2.0*min(base,500.0)+60.0*concave+3.0*start))*gl_Position.w;
774#endif
775#ifdef LIGHTING_3D_MODE
776v_NdotL=NdotL;
777#else
778v_lighting.rgb+=clamp(NdotL*u_lightcolor,mix(vec3(0.0),vec3(0.3),1.0-u_lightcolor),vec3(1.0));v_lighting*=u_opacity;
779#endif 
780#ifdef FOG
781v_fog_pos=fog_position(p);
782#endif
783}`),hillshadePrepare:Sr(`#ifdef GL_ES
784precision highp float;
785#endif
786uniform sampler2D u_image;varying vec2 v_pos;uniform vec2 u_dimension;uniform float u_zoom;uniform vec4 u_unpack;float getElevation(vec2 coord) {
787#ifdef TERRAIN_DEM_FLOAT_FORMAT
788return texture2D(u_image,coord).a/4.0;
789#else
790vec4 data=texture2D(u_image,coord)*255.0;data.a=-1.0;return dot(data,u_unpack)/4.0;
791#endif
792}void main() {vec2 epsilon=1.0/u_dimension;float a=getElevation(v_pos+vec2(-epsilon.x,-epsilon.y));float b=getElevation(v_pos+vec2(0,-epsilon.y));float c=getElevation(v_pos+vec2(epsilon.x,-epsilon.y));float d=getElevation(v_pos+vec2(-epsilon.x,0));float e=getElevation(v_pos+vec2(epsilon.x,0));float f=getElevation(v_pos+vec2(-epsilon.x,epsilon.y));float g=getElevation(v_pos+vec2(0,epsilon.y));float h=getElevation(v_pos+vec2(epsilon.x,epsilon.y));float exaggerationFactor=u_zoom < 2.0 ? 0.4 : u_zoom < 4.5 ? 0.35 : 0.3;float exaggeration=u_zoom < 15.0 ? (u_zoom-15.0)*exaggerationFactor : 0.0;vec2 deriv=vec2(
793(c+e+e+h)-(a+d+d+f),(f+g+g+h)-(a+b+b+c)
794)/pow(2.0,exaggeration+(19.2562-u_zoom));gl_FragColor=clamp(vec4(
795deriv.x/2.0+0.5,deriv.y/2.0+0.5,1.0,1.0),0.0,1.0);
796#ifdef OVERDRAW_INSPECTOR
797gl_FragColor=vec4(1.0);
798#endif
799}`,"uniform mat4 u_matrix;uniform vec2 u_dimension;attribute vec2 a_pos;attribute vec2 a_texture_pos;varying vec2 v_pos;void main() {gl_Position=u_matrix*vec4(a_pos,0,1);highp vec2 epsilon=1.0/u_dimension;float scale=(u_dimension.x-2.0)/u_dimension.x;v_pos=(a_texture_pos/8192.0)*scale+epsilon;}"),hillshade:Sr(`uniform sampler2D u_image;varying vec2 v_pos;uniform vec2 u_latrange;uniform vec2 u_light;uniform vec4 u_shadow;uniform vec4 u_highlight;uniform vec4 u_accent;void main() {vec4 pixel=texture2D(u_image,v_pos);vec2 deriv=((pixel.rg*2.0)-1.0);float scaleFactor=cos(radians((u_latrange[0]-u_latrange[1])*(1.0-v_pos.y)+u_latrange[1]));float slope=atan(1.25*length(deriv)/scaleFactor);float aspect=deriv.x !=0.0 ? atan(deriv.y,-deriv.x) : PI/2.0*(deriv.y > 0.0 ? 1.0 :-1.0);float intensity=u_light.x;float azimuth=u_light.y+PI;float base=1.875-intensity*1.75;float maxValue=0.5*PI;float scaledSlope=intensity !=0.5 ? ((pow(base,slope)-1.0)/(pow(base,maxValue)-1.0))*maxValue : slope;float accent=cos(scaledSlope);vec4 accent_color=(1.0-accent)*u_accent*clamp(intensity*2.0,0.0,1.0);float shade=abs(mod((aspect+azimuth)/PI+0.5,2.0)-1.0);vec4 shade_color=mix(u_shadow,u_highlight,shade)*sin(scaledSlope)*clamp(intensity*2.0,0.0,1.0);gl_FragColor=accent_color*(1.0-shade_color.a)+shade_color;
800#ifdef LIGHTING_3D_MODE
801gl_FragColor=apply_lighting(gl_FragColor);
802#endif
803#ifdef FOG
804gl_FragColor=fog_dither(fog_apply_premultiplied(gl_FragColor,v_fog_pos));
805#endif
806#ifdef OVERDRAW_INSPECTOR
807gl_FragColor=vec4(1.0);
808#endif
809}`,`uniform mat4 u_matrix;attribute vec2 a_pos;attribute vec2 a_texture_pos;varying vec2 v_pos;void main() {gl_Position=u_matrix*vec4(a_pos,0,1);v_pos=a_texture_pos/8192.0;
810#ifdef FOG
811v_fog_pos=fog_position(a_pos);
812#endif
813}`),line:Sr(`uniform lowp float u_device_pixel_ratio;uniform float u_alpha_discard_threshold;uniform highp vec2 u_trim_offset;varying vec2 v_width2;varying vec2 v_normal;varying float v_gamma_scale;varying highp vec4 v_uv;
814#ifdef RENDER_LINE_DASH
815uniform sampler2D u_dash_image;varying vec2 v_tex;
816#endif
817#ifdef RENDER_LINE_GRADIENT
818uniform sampler2D u_gradient_image;
819#endif
820uniform float u_border_width;uniform vec4 u_border_color;float luminance(vec3 c) {return (c.r+c.r+c.b+c.g+c.g+c.g)*0.1667;}
821#pragma mapbox: define highp vec4 color
822#pragma mapbox: define lowp float floorwidth
823#pragma mapbox: define lowp vec4 dash
824#pragma mapbox: define lowp float blur
825#pragma mapbox: define lowp float opacity
826float linearstep(float edge0,float edge1,float x) {return  clamp((x-edge0)/(edge1-edge0),0.0,1.0);}void main() {
827#pragma mapbox: initialize highp vec4 color
828#pragma mapbox: initialize lowp float floorwidth
829#pragma mapbox: initialize lowp vec4 dash
830#pragma mapbox: initialize lowp float blur
831#pragma mapbox: initialize lowp float opacity
832float dist=length(v_normal)*v_width2.s;float blur2=(blur+1.0/u_device_pixel_ratio)*v_gamma_scale;float alpha=clamp(min(dist-(v_width2.t-blur2),v_width2.s-dist)/blur2,0.0,1.0);
833#ifdef RENDER_LINE_DASH
834float sdfdist=texture2D(u_dash_image,v_tex).a;float sdfgamma=1.0/(2.0*u_device_pixel_ratio)/dash.z;alpha*=linearstep(0.5-sdfgamma/floorwidth,0.5+sdfgamma/floorwidth,sdfdist);
835#endif
836highp vec4 out_color;
837#ifdef RENDER_LINE_GRADIENT
838out_color=texture2D(u_gradient_image,v_uv.xy);
839#else
840out_color=color;
841#endif
842float trimmed=1.0;
843#ifdef RENDER_LINE_TRIM_OFFSET
844highp float start=v_uv[2];highp float end=v_uv[3];highp float trim_start=u_trim_offset[0];highp float trim_end=u_trim_offset[1];highp float line_progress=(start+(v_uv.x)*(end-start));if (trim_end > trim_start) {if (line_progress <=trim_end && line_progress >=trim_start) {out_color=vec4(0,0,0,0);trimmed=0.0;}}
845#endif
846#ifdef LIGHTING_3D_MODE
847out_color=apply_lighting(out_color);
848#endif
849#ifdef FOG
850out_color=fog_dither(fog_apply_premultiplied(out_color,v_fog_pos));
851#endif
852#ifdef RENDER_LINE_ALPHA_DISCARD
853if (alpha < u_alpha_discard_threshold) {discard;}
854#endif
855#ifdef RENDER_LINE_BORDER
856float edgeBlur=(u_border_width+1.0/u_device_pixel_ratio);float alpha2=clamp(min(dist-(v_width2.t-edgeBlur),v_width2.s-dist)/edgeBlur,0.0,1.0);if (alpha2 < 1.) {float smoothAlpha=smoothstep(0.6,1.0,alpha2);
857#ifdef RENDER_LINE_BORDER_AUTO
858float Y=(out_color.a > 0.01) ? luminance(out_color.rgb/out_color.a) : 1.;float adjustment=(Y > 0.) ? 0.5/Y : 0.45;if (out_color.a > 0.25 && Y < 0.25) {vec3 borderColor=(Y > 0.) ? out_color.rgb : vec3(1,1,1)*out_color.a;out_color.rgb=out_color.rgb+borderColor*(adjustment*(1.0-smoothAlpha));} else {out_color.rgb*=(0.6 +0.4*smoothAlpha);}
859#else
860out_color.rgb=mix(u_border_color.rgb*u_border_color.a*trimmed,out_color.rgb,smoothAlpha);
861#endif
862}
863#endif
864gl_FragColor=out_color*(alpha*opacity);
865#ifdef OVERDRAW_INSPECTOR
866gl_FragColor=vec4(1.0);
867#endif
868}`,`
869#define EXTRUDE_SCALE 0.015873016
870attribute vec2 a_pos_normal;attribute vec4 a_data;
871#if defined(RENDER_LINE_GRADIENT) || defined(RENDER_LINE_TRIM_OFFSET)
872attribute highp vec4 a_packed;
873#endif
874#ifdef RENDER_LINE_DASH
875attribute float a_linesofar;
876#endif
877uniform mat4 u_matrix;uniform mat2 u_pixels_to_tile_units;uniform vec2 u_units_to_pixels;uniform lowp float u_device_pixel_ratio;varying vec2 v_normal;varying vec2 v_width2;varying float v_gamma_scale;varying highp vec4 v_uv;
878#ifdef RENDER_LINE_DASH
879uniform vec2 u_texsize;uniform float u_tile_units_to_pixels;varying vec2 v_tex;
880#endif
881#ifdef RENDER_LINE_GRADIENT
882uniform float u_image_height;
883#endif
884#pragma mapbox: define highp vec4 color
885#pragma mapbox: define lowp float floorwidth
886#pragma mapbox: define lowp vec4 dash
887#pragma mapbox: define lowp float blur
888#pragma mapbox: define lowp float opacity
889#pragma mapbox: define mediump float gapwidth
890#pragma mapbox: define lowp float offset
891#pragma mapbox: define mediump float width
892void main() {
893#pragma mapbox: initialize highp vec4 color
894#pragma mapbox: initialize lowp float floorwidth
895#pragma mapbox: initialize lowp vec4 dash
896#pragma mapbox: initialize lowp float blur
897#pragma mapbox: initialize lowp float opacity
898#pragma mapbox: initialize mediump float gapwidth
899#pragma mapbox: initialize lowp float offset
900#pragma mapbox: initialize mediump float width
901float ANTIALIASING=1.0/u_device_pixel_ratio/2.0;vec2 a_extrude=a_data.xy-128.0;float a_direction=mod(a_data.z,4.0)-1.0;vec2 pos=floor(a_pos_normal*0.5);mediump vec2 normal=a_pos_normal-2.0*pos;normal.y=normal.y*2.0-1.0;v_normal=normal;gapwidth=gapwidth/2.0;float halfwidth=width/2.0;offset=-1.0*offset;float inset=gapwidth+(gapwidth > 0.0 ? ANTIALIASING : 0.0);float outset=gapwidth+halfwidth*(gapwidth > 0.0 ? 2.0 : 1.0)+(halfwidth==0.0 ? 0.0 : ANTIALIASING);mediump vec2 dist=outset*a_extrude*EXTRUDE_SCALE;mediump float u=0.5*a_direction;mediump float t=1.0-abs(u);mediump vec2 offset2=offset*a_extrude*EXTRUDE_SCALE*normal.y*mat2(t,-u,u,t);vec4 projected_extrude=u_matrix*vec4(dist*u_pixels_to_tile_units,0.0,0.0);gl_Position=u_matrix*vec4(pos+offset2*u_pixels_to_tile_units,0.0,1.0)+projected_extrude;
902#ifndef RENDER_TO_TEXTURE
903float extrude_length_without_perspective=length(dist);float extrude_length_with_perspective=length(projected_extrude.xy/gl_Position.w*u_units_to_pixels);v_gamma_scale=extrude_length_without_perspective/extrude_length_with_perspective;
904#else
905v_gamma_scale=1.0;
906#endif
907#if defined(RENDER_LINE_GRADIENT) || defined(RENDER_LINE_TRIM_OFFSET)
908float a_uv_x=a_packed[0];float a_split_index=a_packed[1];highp float a_clip_start=a_packed[2];highp float a_clip_end=a_packed[3];
909#ifdef RENDER_LINE_GRADIENT
910highp float texel_height=1.0/u_image_height;highp float half_texel_height=0.5*texel_height;v_uv=vec4(a_uv_x,a_split_index*texel_height-half_texel_height,a_clip_start,a_clip_end);
911#else
912v_uv=vec4(a_uv_x,0.0,a_clip_start,a_clip_end);
913#endif
914#endif
915#ifdef RENDER_LINE_DASH
916float scale=dash.z==0.0 ? 0.0 : u_tile_units_to_pixels/dash.z;float height=dash.y;v_tex=vec2(a_linesofar*scale/floorwidth,(-normal.y*height+dash.x+0.5)/u_texsize.y);
917#endif
918v_width2=vec2(outset,inset);
919#ifdef FOG
920v_fog_pos=fog_position(pos);
921#endif
922}`),linePattern:Sr(`uniform lowp float u_device_pixel_ratio;uniform vec2 u_texsize;uniform float u_tile_units_to_pixels;uniform sampler2D u_image;varying vec2 v_normal;varying vec2 v_width2;varying float v_linesofar;varying float v_gamma_scale;varying float v_width;
923#pragma mapbox: define lowp vec4 pattern
924#pragma mapbox: define lowp float pixel_ratio
925#pragma mapbox: define lowp float blur
926#pragma mapbox: define lowp float opacity
927void main() {
928#pragma mapbox: initialize mediump vec4 pattern
929#pragma mapbox: initialize lowp float pixel_ratio
930#pragma mapbox: initialize lowp float blur
931#pragma mapbox: initialize lowp float opacity
932vec2 pattern_tl=pattern.xy;vec2 pattern_br=pattern.zw;vec2 display_size=(pattern_br-pattern_tl)/pixel_ratio;vec2 pattern_size=vec2(display_size.x/u_tile_units_to_pixels,display_size.y);float aspect=display_size.y/v_width;float dist=length(v_normal)*v_width2.s;float blur2=(blur+1.0/u_device_pixel_ratio)*v_gamma_scale;float alpha=clamp(min(dist-(v_width2.t-blur2),v_width2.s-dist)/blur2,0.0,1.0);float x=mod(v_linesofar/pattern_size.x*aspect,1.0);float y=0.5*v_normal.y+0.5;vec2 texel_size=1.0/u_texsize;vec2 pos=mix(pattern_tl*texel_size-texel_size,pattern_br*texel_size+texel_size,vec2(x,y));vec4 color=texture2D(u_image,pos);
933#ifdef LIGHTING_3D_MODE
934color=apply_lighting(color);
935#endif
936#ifdef FOG
937color=fog_dither(fog_apply_premultiplied(color,v_fog_pos));
938#endif
939gl_FragColor=color*(alpha*opacity);
940#ifdef OVERDRAW_INSPECTOR
941gl_FragColor=vec4(1.0);
942#endif
943}`,`
944#define scale 0.015873016
945attribute vec2 a_pos_normal;attribute vec4 a_data;attribute float a_linesofar;uniform mat4 u_matrix;uniform vec2 u_units_to_pixels;uniform mat2 u_pixels_to_tile_units;uniform lowp float u_device_pixel_ratio;varying vec2 v_normal;varying vec2 v_width2;varying float v_linesofar;varying float v_gamma_scale;varying float v_width;
946#pragma mapbox: define lowp float blur
947#pragma mapbox: define lowp float opacity
948#pragma mapbox: define lowp float offset
949#pragma mapbox: define mediump float gapwidth
950#pragma mapbox: define mediump float width
951#pragma mapbox: define lowp float floorwidth
952#pragma mapbox: define lowp vec4 pattern
953#pragma mapbox: define lowp float pixel_ratio
954void main() {
955#pragma mapbox: initialize lowp float blur
956#pragma mapbox: initialize lowp float opacity
957#pragma mapbox: initialize lowp float offset
958#pragma mapbox: initialize mediump float gapwidth
959#pragma mapbox: initialize mediump float width
960#pragma mapbox: initialize lowp float floorwidth
961#pragma mapbox: initialize mediump vec4 pattern
962#pragma mapbox: initialize lowp float pixel_ratio
963float ANTIALIASING=1.0/u_device_pixel_ratio/2.0;vec2 a_extrude=a_data.xy-128.0;float a_direction=mod(a_data.z,4.0)-1.0;vec2 pos=floor(a_pos_normal*0.5);mediump vec2 normal=a_pos_normal-2.0*pos;normal.y=normal.y*2.0-1.0;v_normal=normal;gapwidth=gapwidth/2.0;float halfwidth=width/2.0;offset=-1.0*offset;float inset=gapwidth+(gapwidth > 0.0 ? ANTIALIASING : 0.0);float outset=gapwidth+halfwidth*(gapwidth > 0.0 ? 2.0 : 1.0)+(halfwidth==0.0 ? 0.0 : ANTIALIASING);mediump vec2 dist=outset*a_extrude*scale;mediump float u=0.5*a_direction;mediump float t=1.0-abs(u);mediump vec2 offset2=offset*a_extrude*scale*normal.y*mat2(t,-u,u,t);vec4 projected_extrude=u_matrix*vec4(dist*u_pixels_to_tile_units,0.0,0.0);gl_Position=u_matrix*vec4(pos+offset2*u_pixels_to_tile_units,0.0,1.0)+projected_extrude;
964#ifndef RENDER_TO_TEXTURE
965float extrude_length_without_perspective=length(dist);float extrude_length_with_perspective=length(projected_extrude.xy/gl_Position.w*u_units_to_pixels);v_gamma_scale=extrude_length_without_perspective/extrude_length_with_perspective;
966#else
967v_gamma_scale=1.0;
968#endif
969v_linesofar=a_linesofar;v_width2=vec2(outset,inset);v_width=floorwidth;
970#ifdef FOG
971v_fog_pos=fog_position(pos);
972#endif
973}`),raster:Sr(`uniform float u_fade_t;uniform float u_opacity;uniform sampler2D u_image0;uniform sampler2D u_image1;varying vec2 v_pos0;varying vec2 v_pos1;uniform float u_brightness_low;uniform float u_brightness_high;uniform float u_saturation_factor;uniform float u_contrast_factor;uniform vec3 u_spin_weights;void main() {vec4 color0=texture2D(u_image0,v_pos0);vec4 color1=texture2D(u_image1,v_pos1);if (color0.a > 0.0) {color0.rgb=color0.rgb/color0.a;}if (color1.a > 0.0) {color1.rgb=color1.rgb/color1.a;}vec4 color=mix(color0,color1,u_fade_t);color.a*=u_opacity;vec3 rgb=color.rgb;rgb=vec3(
974dot(rgb,u_spin_weights.xyz),dot(rgb,u_spin_weights.zxy),dot(rgb,u_spin_weights.yzx));float average=(color.r+color.g+color.b)/3.0;rgb+=(average-rgb)*u_saturation_factor;rgb=(rgb-0.5)*u_contrast_factor+0.5;vec3 u_high_vec=vec3(u_brightness_low,u_brightness_low,u_brightness_low);vec3 u_low_vec=vec3(u_brightness_high,u_brightness_high,u_brightness_high);vec3 out_color=mix(u_high_vec,u_low_vec,rgb);
975#ifdef LIGHTING_3D_MODE
976out_color=apply_lighting(out_color);
977#endif
978#ifdef FOG
979out_color=fog_dither(fog_apply(out_color,v_fog_pos));
980#endif
981gl_FragColor=vec4(out_color*color.a,color.a);
982#ifdef OVERDRAW_INSPECTOR
983gl_FragColor=vec4(1.0);
984#endif
985}`,`uniform mat4 u_matrix;uniform vec2 u_tl_parent;uniform float u_scale_parent;uniform vec2 u_perspective_transform;attribute vec2 a_pos;attribute vec2 a_texture_pos;varying vec2 v_pos0;varying vec2 v_pos1;void main() {float w=1.0+dot(a_texture_pos,u_perspective_transform);gl_Position=u_matrix*vec4(a_pos*w,0,w);v_pos0=a_texture_pos/8192.0;v_pos1=(v_pos0*u_scale_parent)+u_tl_parent;
986#ifdef FOG
987v_fog_pos=fog_position(a_pos);
988#endif
989}`),symbolIcon:Sr(`uniform sampler2D u_texture;varying vec2 v_tex;varying float v_fade_opacity;
990#pragma mapbox: define lowp float opacity
991void main() {
992#pragma mapbox: initialize lowp float opacity
993lowp float alpha=opacity*v_fade_opacity;gl_FragColor=texture2D(u_texture,v_tex)*alpha;
994#ifdef OVERDRAW_INSPECTOR
995gl_FragColor=vec4(1.0);
996#endif
997}`,`attribute vec4 a_pos_offset;attribute vec4 a_tex_size;attribute vec4 a_pixeloffset;attribute vec4 a_projected_pos;attribute float a_fade_opacity;
998#ifdef PROJECTION_GLOBE_VIEW
999attribute vec3 a_globe_anchor;attribute vec3 a_globe_normal;
1000#endif
1001uniform bool u_is_size_zoom_constant;uniform bool u_is_size_feature_constant;uniform highp float u_size_t;uniform highp float u_size;uniform highp float u_camera_to_center_distance;uniform bool u_rotate_symbol;uniform highp float u_aspect_ratio;uniform float u_fade_change;uniform mat4 u_matrix;uniform mat4 u_label_plane_matrix;uniform mat4 u_coord_matrix;uniform bool u_is_text;uniform bool u_pitch_with_map;uniform vec2 u_texsize;uniform vec3 u_up_vector;
1002#ifdef PROJECTION_GLOBE_VIEW
1003uniform vec3 u_tile_id;uniform mat4 u_inv_rot_matrix;uniform vec2 u_merc_center;uniform vec3 u_camera_forward;uniform float u_zoom_transition;uniform vec3 u_ecef_origin;uniform mat4 u_tile_matrix;
1004#endif
1005varying vec2 v_tex;varying float v_fade_opacity;
1006#pragma mapbox: define lowp float opacity
1007void main() {
1008#pragma mapbox: initialize lowp float opacity
1009vec2 a_pos=a_pos_offset.xy;vec2 a_offset=a_pos_offset.zw;vec2 a_tex=a_tex_size.xy;vec2 a_size=a_tex_size.zw;float a_size_min=floor(a_size[0]*0.5);vec2 a_pxoffset=a_pixeloffset.xy;vec2 a_min_font_scale=a_pixeloffset.zw/256.0;highp float segment_angle=-a_projected_pos[3];float size;if (!u_is_size_zoom_constant && !u_is_size_feature_constant) {size=mix(a_size_min,a_size[1],u_size_t)/128.0;} else if (u_is_size_zoom_constant && !u_is_size_feature_constant) {size=a_size_min/128.0;} else {size=u_size;}vec2 tile_anchor=a_pos;vec3 h=elevationVector(tile_anchor)*elevation(tile_anchor);float globe_occlusion_fade;vec3 world_pos;vec3 mercator_pos;
1010#ifdef PROJECTION_GLOBE_VIEW
1011mercator_pos=mercator_tile_position(u_inv_rot_matrix,tile_anchor,u_tile_id,u_merc_center);world_pos=mix_globe_mercator(a_globe_anchor+h,mercator_pos,u_zoom_transition);vec4 ecef_point=u_tile_matrix*vec4(world_pos,1.0);vec3 origin_to_point=ecef_point.xyz-u_ecef_origin;globe_occlusion_fade=dot(origin_to_point,u_camera_forward) >=0.0 ? 0.0 : 1.0;
1012#else
1013world_pos=vec3(tile_anchor,0)+h;globe_occlusion_fade=1.0;
1014#endif
1015vec4 projected_point=u_matrix*vec4(world_pos,1);highp float camera_to_anchor_distance=projected_point.w;highp float distance_ratio=u_pitch_with_map ?
1016camera_to_anchor_distance/u_camera_to_center_distance :
1017u_camera_to_center_distance/camera_to_anchor_distance;highp float perspective_ratio=clamp(
10180.5+0.5*distance_ratio,0.0,1.5);size*=perspective_ratio;float font_scale=u_is_text ? size/24.0 : size;highp float symbol_rotation=0.0;if (u_rotate_symbol) {vec4 offsetProjected_point;
1019#ifdef PROJECTION_GLOBE_VIEW
1020vec3 displacement=vec3(a_globe_normal.z,0,-a_globe_normal.x);offsetProjected_point=u_matrix*vec4(a_globe_anchor+displacement,1);
1021#else
1022offsetProjected_point=u_matrix*vec4(tile_anchor+vec2(1,0),0,1);
1023#endif
1024vec2 a=projected_point.xy/projected_point.w;vec2 b=offsetProjected_point.xy/offsetProjected_point.w;symbol_rotation=atan((b.y-a.y)/u_aspect_ratio,b.x-a.x);}vec4 projected_pos;
1025#ifdef PROJECTION_GLOBE_VIEW
1026vec3 proj_pos=mix_globe_mercator(a_projected_pos.xyz+h,mercator_pos,u_zoom_transition);projected_pos=u_label_plane_matrix*vec4(proj_pos,1.0);
1027#else
1028projected_pos=u_label_plane_matrix*vec4(a_projected_pos.xy,h.z,1.0);
1029#endif
1030highp float angle_sin=sin(segment_angle+symbol_rotation);highp float angle_cos=cos(segment_angle+symbol_rotation);mat2 rotation_matrix=mat2(angle_cos,-1.0*angle_sin,angle_sin,angle_cos);float z=0.0;vec2 offset=rotation_matrix*(a_offset/32.0*max(a_min_font_scale,font_scale)+a_pxoffset/16.0);
1031#ifdef TERRAIN
1032#ifdef PITCH_WITH_MAP_TERRAIN
1033vec4 tile_pos=u_label_plane_matrix_inv*vec4(a_projected_pos.xy+offset,0.0,1.0);z=elevation(tile_pos.xy);
1034#endif
1035#endif
1036float occlusion_fade=occlusionFade(projected_point)*globe_occlusion_fade;
1037#ifdef PROJECTION_GLOBE_VIEW
1038vec3 xAxis=u_pitch_with_map ? normalize(cross(a_globe_normal,u_up_vector)) : vec3(1,0,0);vec3 yAxis=u_pitch_with_map ? normalize(cross(a_globe_normal,xAxis)) : vec3(0,1,0);gl_Position=mix(u_coord_matrix*vec4(projected_pos.xyz/projected_pos.w+xAxis*offset.x+yAxis*offset.y,1.0),AWAY,float(projected_point.w <=0.0 || occlusion_fade==0.0));
1039#else
1040gl_Position=mix(u_coord_matrix*vec4(projected_pos.xy/projected_pos.w+offset,z,1.0),AWAY,float(projected_point.w <=0.0 || occlusion_fade==0.0));
1041#endif
1042float projection_transition_fade=1.0;
1043#if defined(PROJECTED_POS_ON_VIEWPORT) && defined(PROJECTION_GLOBE_VIEW)
1044projection_transition_fade=1.0-step(EPSILON,u_zoom_transition);
1045#endif
1046v_tex=a_tex/u_texsize;vec2 fade_opacity=unpack_opacity(a_fade_opacity);float fade_change=fade_opacity[1] > 0.5 ? u_fade_change :-u_fade_change;v_fade_opacity=max(0.0,min(occlusion_fade,fade_opacity[0]+fade_change))*projection_transition_fade;}`),symbolSDF:Sr(`#define SDF_PX 8.0
1047uniform bool u_is_halo;uniform sampler2D u_texture;uniform highp float u_gamma_scale;uniform lowp float u_device_pixel_ratio;uniform bool u_is_text;varying vec2 v_data0;varying vec3 v_data1;
1048#pragma mapbox: define highp vec4 fill_color
1049#pragma mapb
1049ox: define highp vec4 halo_color
1050#pragma mapbox: define lowp float opacity
1051#pragma mapbox: define lowp float halo_width
1052#pragma mapbox: define lowp float halo_blur
1053void main() {
1054#pragma mapbox: initialize highp vec4 fill_color
1055#pragma mapbox: initialize highp vec4 halo_color
1056#pragma mapbox: initialize lowp float opacity
1057#pragma mapbox: initialize lowp float halo_width
1058#pragma mapbox: initialize lowp float halo_blur
1059float EDGE_GAMMA=0.105/u_device_pixel_ratio;vec2 tex=v_data0.xy;float gamma_scale=v_data1.x;float size=v_data1.y;float fade_opacity=v_data1[2];float fontScale=u_is_text ? size/24.0 : size;lowp vec4 color=fill_color;highp float gamma=EDGE_GAMMA/(fontScale*u_gamma_scale);lowp float buff=(256.0-64.0)/256.0;if (u_is_halo) {color=halo_color;gamma=(halo_blur*1.19/SDF_PX+EDGE_GAMMA)/(fontScale*u_gamma_scale);buff=(6.0-halo_width/fontScale)/SDF_PX;}lowp float dist=texture2D(u_texture,tex).a;highp float gamma_scaled=gamma*gamma_scale;highp float alpha=smoothstep(buff-gamma_scaled,buff+gamma_scaled,dist);gl_FragColor=color*(alpha*opacity*fade_opacity);
1060#ifdef OVERDRAW_INSPECTOR
1061gl_FragColor=vec4(1.0);
1062#endif
1063}`,`attribute vec4 a_pos_offset;attribute vec4 a_tex_size;attribute vec4 a_pixeloffset;attribute vec4 a_projected_pos;attribute float a_fade_opacity;
1064#ifdef PROJECTION_GLOBE_VIEW
1065attribute vec3 a_globe_anchor;attribute vec3 a_globe_normal;
1066#endif
1067uniform bool u_is_size_zoom_constant;uniform bool u_is_size_feature_constant;uniform highp float u_size_t;uniform highp float u_size;uniform mat4 u_matrix;uniform mat4 u_label_plane_matrix;uniform mat4 u_coord_matrix;uniform bool u_is_text;uniform bool u_pitch_with_map;uniform bool u_rotate_symbol;uniform highp float u_aspect_ratio;uniform highp float u_camera_to_center_distance;uniform float u_fade_change;uniform vec2 u_texsize;uniform vec3 u_up_vector;
1068#ifdef PROJECTION_GLOBE_VIEW
1069uniform vec3 u_tile_id;uniform mat4 u_inv_rot_matrix;uniform vec2 u_merc_center;uniform vec3 u_camera_forward;uniform float u_zoom_transition;uniform vec3 u_ecef_origin;uniform mat4 u_tile_matrix;
1070#endif
1071varying vec2 v_data0;varying vec3 v_data1;
1072#pragma mapbox: define highp vec4 fill_color
1073#pragma mapbox: define highp vec4 halo_color
1074#pragma mapbox: define lowp float opacity
1075#pragma mapbox: define lowp float halo_width
1076#pragma mapbox: define lowp float halo_blur
1077void main() {
1078#pragma mapbox: initialize highp vec4 fill_color
1079#pragma mapbox: initialize highp vec4 halo_color
1080#pragma mapbox: initialize lowp float opacity
1081#pragma mapbox: initialize lowp float halo_width
1082#pragma mapbox: initialize lowp float halo_blur
1083vec2 a_pos=a_pos_offset.xy;vec2 a_offset=a_pos_offset.zw;vec2 a_tex=a_tex_size.xy;vec2 a_size=a_tex_size.zw;float a_size_min=floor(a_size[0]*0.5);vec2 a_pxoffset=a_pixeloffset.xy;highp float segment_angle=-a_projected_pos[3];float size;if (!u_is_size_zoom_constant && !u_is_size_feature_constant) {size=mix(a_size_min,a_size[1],u_size_t)/128.0;} else if (u_is_size_zoom_constant && !u_is_size_feature_constant) {size=a_size_min/128.0;} else {size=u_size;}vec2 tile_anchor=a_pos;vec3 h=elevationVector(tile_anchor)*elevation(tile_anchor);float globe_occlusion_fade;vec3 world_pos;vec3 mercator_pos;
1084#ifdef PROJECTION_GLOBE_VIEW
1085mercator_pos=mercator_tile_position(u_inv_rot_matrix,tile_anchor,u_tile_id,u_merc_center);world_pos=mix_globe_mercator(a_globe_anchor+h,mercator_pos,u_zoom_transition);vec4 ecef_point=u_tile_matrix*vec4(world_pos,1.0);vec3 origin_to_point=ecef_point.xyz-u_ecef_origin;globe_occlusion_fade=dot(origin_to_point,u_camera_forward) >=0.0 ? 0.0 : 1.0;
1086#else
1087world_pos=vec3(tile_anchor,0)+h;globe_occlusion_fade=1.0;
1088#endif
1089vec4 projected_point=u_matrix*vec4(world_pos,1);highp float camera_to_anchor_distance=projected_point.w;highp float distance_ratio=u_pitch_with_map ?
1090camera_to_anchor_distance/u_camera_to_center_distance :
1091u_camera_to_center_distance/camera_to_anchor_distance;highp float perspective_ratio=clamp(
10920.5+0.5*distance_ratio,0.0,1.5);size*=perspective_ratio;float fontScale=u_is_text ? size/24.0 : size;highp float symbol_rotation=0.0;if (u_rotate_symbol) {vec4 offsetprojected_point;
1093#ifdef PROJECTION_GLOBE_VIEW
1094vec3 displacement=vec3(a_globe_normal.z,0,-a_globe_normal.x);offsetprojected_point=u_matrix*vec4(a_globe_anchor+displacement,1);
1095#else
1096offsetprojected_point=u_matrix*vec4(tile_anchor+vec2(1,0),0,1);
1097#endif
1098vec2 a=projected_point.xy/projected_point.w;vec2 b=offsetprojected_point.xy/offsetprojected_point.w;symbol_rotation=atan((b.y-a.y)/u_aspect_ratio,b.x-a.x);}vec4 projected_pos;
1099#ifdef PROJECTION_GLOBE_VIEW
1100vec3 proj_pos=mix_globe_mercator(a_projected_pos.xyz+h,mercator_pos,u_zoom_transition);projected_pos=u_label_plane_matrix*vec4(proj_pos,1.0);
1101#else
1102projected_pos=u_label_plane_matrix*vec4(a_projected_pos.xy,h.z,1.0);
1103#endif
1104highp float angle_sin=sin(segment_angle+symbol_rotation);highp float angle_cos=cos(segment_angle+symbol_rotation);mat2 rotation_matrix=mat2(angle_cos,-1.0*angle_sin,angle_sin,angle_cos);float z=0.0;vec2 offset=rotation_matrix*(a_offset/32.0*fontScale+a_pxoffset);
1105#ifdef TERRAIN
1106#ifdef PITCH_WITH_MAP_TERRAIN
1107vec4 tile_pos=u_label_plane_matrix_inv*vec4(a_projected_pos.xy+offset,0.0,1.0);z=elevation(tile_pos.xy);
1108#endif
1109#endif
1110float occlusion_fade=occlusionFade(projected_point)*globe_occlusion_fade;
1111#ifdef PROJECTION_GLOBE_VIEW
1112vec3 xAxis=u_pitch_with_map ? normalize(cross(a_globe_normal,u_up_vector)) : vec3(1,0,0);vec3 yAxis=u_pitch_with_map ? normalize(cross(a_globe_normal,xAxis)) : vec3(0,1,0);gl_Position=mix(u_coord_matrix*vec4(projected_pos.xyz/projected_pos.w+xAxis*offset.x+yAxis*offset.y,1.0),AWAY,float(projected_point.w <=0.0 || occlusion_fade==0.0));
1113#else
1114gl_Position=mix(u_coord_matrix*vec4(projected_pos.xy/projected_pos.w+offset,z,1.0),AWAY,float(projected_point.w <=0.0 || occlusion_fade==0.0));
1115#endif
1116float gamma_scale=gl_Position.w;float projection_transition_fade=1.0;
1117#if defined(PROJECTED_POS_ON_VIEWPORT) && defined(PROJECTION_GLOBE_VIEW)
1118projection_transition_fade=1.0-step(EPSILON,u_zoom_transition);
1119#endif
1120vec2 fade_opacity=unpack_opacity(a_fade_opacity);float fade_change=fade_opacity[1] > 0.5 ? u_fade_change :-u_fade_change;float interpolated_fade_opacity=max(0.0,min(occlusion_fade,fade_opacity[0]+fade_change));v_data0=a_tex/u_texsize;v_data1=vec3(gamma_scale,size,interpolated_fade_opacity*projection_transition_fade);}`),symbolTextAndIcon:Sr(`#define SDF_PX 8.0
1121#define SDF 1.0
1122#define ICON 0.0
1123uniform bool u_is_halo;uniform sampler2D u_texture;uniform sampler2D u_texture_icon;uniform highp float u_gamma_scale;uniform lowp float u_device_pixel_ratio;varying vec4 v_data0;varying vec4 v_data1;
1124#pragma mapbox: define highp vec4 fill_color
1125#pragma mapbox: define highp vec4 halo_color
1126#pragma mapbox: define lowp float opacity
1127#pragma mapbox: define lowp float halo_width
1128#pragma mapbox: define lowp float halo_blur
1129void main() {
1130#pragma mapbox: initialize highp vec4 fill_color
1131#pragma mapbox: initialize highp vec4 halo_color
1132#pragma mapbox: initialize lowp float opacity
1133#pragma mapbox: initialize lowp float halo_width
1134#pragma mapbox: initialize lowp float halo_blur
1135float fade_opacity=v_data1[2];if (v_data1.w==ICON) {vec2 tex_icon=v_data0.zw;lowp float alpha=opacity*fade_opacity;
1135gl_FragColor=texture2D(u_texture_icon,tex_icon)*alpha;
1136#ifdef OVERDRAW_INSPECTOR
1137gl_FragColor=vec4(1.0);
1138#endif
1139return;}vec2 tex=v_data0.xy;float EDGE_GAMMA=0.105/u_device_pixel_ratio;float gamma_scale=v_data1.x;float size=v_data1.y;float fontScale=size/24.0;lowp vec4 color=fill_color;highp float gamma=EDGE_GAMMA/(fontScale*u_gamma_scale);lowp float buff=(256.0-64.0)/256.0;if (u_is_halo) {color=halo_color;gamma=(halo_blur*1.19/SDF_PX+EDGE_GAMMA)/(fontScale*u_gamma_scale);buff=(6.0-halo_width/fontScale)/SDF_PX;}lowp float dist=texture2D(u_texture,tex).a;highp float gamma_scaled=gamma*gamma_scale;highp float alpha=smoothstep(buff-gamma_scaled,buff+gamma_scaled,dist);gl_FragColor=color*(alpha*opacity*fade_opacity);
1140#ifdef OVERDRAW_INSPECTOR
1141gl_FragColor=vec4(1.0);
1142#endif
1143}`,`attribute vec4 a_pos_offset;attribute vec4 a_tex_size;attribute vec4 a_projected_pos;attribute float a_fade_opacity;
1144#ifdef PROJECTION_GLOBE_VIEW
1145attribute vec3 a_globe_anchor;attribute vec3 a_globe_normal;
1146#endif
1147uniform bool u_is_size_zoom_constant;uniform bool u_is_size_feature_constant;uniform highp float u_size_t;uniform highp float u_size;uniform mat4 u_matrix;uniform mat4 u_label_plane_matrix;uniform mat4 u_coord_matrix;uniform bool u_is_text;uniform bool u_pitch_with_map;uniform bool u_rotate_symbol;uniform highp float u_aspect_ratio;uniform highp float u_camera_to_center_distance;uniform float u_fade_change;uniform vec2 u_texsize;uniform vec3 u_up_vector;uniform vec2 u_texsize_icon;
1148#ifdef PROJECTION_GLOBE_VIEW
1149uniform vec3 u_tile_id;uniform mat4 u_inv_rot_matrix;uniform vec2 u_merc_center;uniform vec3 u_camera_forward;uniform float u_zoom_transition;uniform vec3 u_ecef_origin;uniform mat4 u_tile_matrix;
1150#endif
1151varying vec4 v_data0;varying vec4 v_data1;
1152#pragma mapbox: define highp vec4 fill_color
1153#pragma mapbox: define highp vec4 halo_color
1154#pragma mapbox: define lowp float opacity
1155#pragma mapbox: define lowp float halo_width
1156#pragma mapbox: define lowp float halo_blur
1157void main() {
1158#pragma mapbox: initialize highp vec4 fill_color
1159#pragma mapbox: initialize highp vec4 halo_color
1160#pragma mapbox: initialize lowp float opacity
1161#pragma mapbox: initialize lowp float halo_width
1162#pragma mapbox: initialize lowp float halo_blur
1163vec2 a_pos=a_pos_offset.xy;vec2 a_offset=a_pos_offset.zw;vec2 a_tex=a_tex_size.xy;vec2 a_size=a_tex_size.zw;float a_size_min=floor(a_size[0]*0.5);float is_sdf=a_size[0]-2.0*a_size_min;highp float segment_angle=-a_projected_pos[3];float size;if (!u_is_size_zoom_constant && !u_is_size_feature_constant) {size=mix(a_size_min,a_size[1],u_size_t)/128.0;} else if (u_is_size_zoom_constant && !u_is_size_feature_constant) {size=a_size_min/128.0;} else {size=u_size;}vec2 tile_anchor=a_pos;vec3 h=elevationVector(tile_anchor)*elevation(tile_anchor);float globe_occlusion_fade;vec3 world_pos;vec3 mercator_pos;
1164#ifdef PROJECTION_GLOBE_VIEW
1165mercator_pos=mercator_tile_position(u_inv_rot_matrix,tile_anchor,u_tile_id,u_merc_center);world_pos=mix_globe_mercator(a_globe_anchor+h,mercator_pos,u_zoom_transition);vec4 ecef_point=u_tile_matrix*vec4(world_pos,1.0);vec3 origin_to_point=ecef_point.xyz-u_ecef_origin;globe_occlusion_fade=dot(origin_to_point,u_camera_forward) >=0.0 ? 0.0 : 1.0;
1166#else
1167world_pos=vec3(tile_anchor,0)+h;globe_occlusion_fade=1.0;
1168#endif
1169vec4 projected_point=u_matrix*vec4(world_pos,1);highp float camera_to_anchor_distance=projected_point.w;highp float distance_ratio=u_pitch_with_map ?
1170camera_to_anchor_distance/u_camera_to_center_distance :
1171u_camera_to_center_distance/camera_to_anchor_distance;highp float perspective_ratio=clamp(
11720.5+0.5*distance_ratio,0.0,1.5);size*=perspective_ratio;float font_scale=size/24.0;highp float symbol_rotation=0.0;if (u_rotate_symbol) {vec4 offset_projected_point=u_matrix*vec4(a_pos+vec2(1,0),0,1);vec2 a=projected_point.xy/projected_point.w;vec2 b=offset_projected_point.xy/offset_projected_point.w;symbol_rotation=atan((b.y-a.y)/u_aspect_ratio,b.x-a.x);}vec4 projected_pos;
1173#ifdef PROJECTION_GLOBE_VIEW
1174vec3 proj_pos=mix_globe_mercator(a_projected_pos.xyz+h,mercator_pos,u_zoom_transition);projected_pos=u_label_plane_matrix*vec4(proj_pos,1.0);
1175#else
1176projected_pos=u_label_plane_matrix*vec4(a_projected_pos.xy,h.z,1.0);
1177#endif
1178highp float angle_sin=sin(segment_angle+symbol_rotation);highp float angle_cos=cos(segment_angle+symbol_rotation);mat2 rotation_matrix=mat2(angle_cos,-1.0*angle_sin,angle_sin,angle_cos);float z=0.0;vec2 offset=rotation_matrix*(a_offset/32.0*font_scale);
1179#ifdef TERRAIN
1180#ifdef PITCH_WITH_MAP_TERRAIN
1181vec4 tile_pos=u_label_plane_matrix_inv*vec4(a_projected_pos.xy+offset,0.0,1.0);z=elevation(tile_pos.xy);
1182#endif
1183#endif
1184float occlusion_fade=occlusionFade(projected_point)*globe_occlusion_fade;
1185#ifdef PROJECTION_GLOBE_VIEW
1186vec3 xAxis=u_pitch_with_map ? normalize(cross(a_globe_normal,u_up_vector)) : vec3(1,0,0);vec3 yAxis=u_pitch_with_map ? normalize(cross(a_globe_normal,xAxis)) : vec3(0,1,0);gl_Position=mix(u_coord_matrix*vec4(projected_pos.xyz/projected_pos.w+xAxis*offset.x+yAxis*offset.y,1.0),AWAY,float(projected_point.w <=0.0 || occlusion_fade==0.0));
1187#else
1188gl_Position=mix(u_coord_matrix*vec4(projected_pos.xy/projected_pos.w+offset,z,1.0),AWAY,float(projected_point.w <=0.0 || occlusion_fade==0.0));
1189#endif
1190float gamma_scale=gl_Position.w;vec2 fade_opacity=unpack_opacity(a_fade_opacity);float fade_change=fade_opacity[1] > 0.5 ? u_fade_change :-u_fade_change;float interpolated_fade_opacity=max(0.0,min(occlusion_fade,fade_opacity[0]+fade_change));float projection_transition_fade=1.0;
1191#if defined(PROJECTED_POS_ON_VIEWPORT) && defined(PROJECTION_GLOBE_VIEW)
1192projection_transition_fade=1.0-step(EPSILON,u_zoom_transition);
1193#endif
1194v_data0.xy=a_tex/u_texsize;v_data0.zw=a_tex/u_texsize_icon;v_data1=vec4(gamma_scale,size,interpolated_fade_opacity*projection_transition_fade,is_s
1194df);}`),terrainRaster:Sr(`uniform sampler2D u_image0;varying vec2 v_pos0;
1195#ifdef FOG
1196varying float v_fog_opacity;
1197#endif
1198#ifdef RENDER_SHADOWS
1199varying vec4 v_pos_light_view_0;varying vec4 v_pos_light_view_1;varying float v_depth;
1200#endif
1201void main() {vec4 color=texture2D(u_image0,v_pos0);
1202#ifdef RENDER_SHADOWS
1203color.xyz=shadowed_color(color.xyz,v_pos_light_view_0,v_pos_light_view_1,v_depth);
1204#endif
1205#ifdef FOG
1206#ifdef ZERO_EXAGGERATION
1207color=fog_dither(fog_apply_premultiplied(color,v_fog_pos));
1208#else
1209color=fog_dither(fog_apply_from_vert(color,v_fog_opacity));
1210#endif
1211#endif
1212gl_FragColor=color;
1213#ifdef TERRAIN_WIREFRAME
1214gl_FragColor=vec4(1.0,0.0,0.0,0.8);
1215#endif
1216#ifdef OVERDRAW_INSPECTOR
1217gl_FragColor=vec4(1.0);
1218#endif
1219}`,`uniform mat4 u_matrix;uniform float u_skirt_height;attribute vec2 a_pos;varying vec2 v_pos0;
1220#ifdef FOG
1221varying float v_fog_opacity;
1222#endif
1223#ifdef RENDER_SHADOWS
1224uniform mat4 u_light_matrix_0;uniform mat4 u_light_matrix_1;varying vec4 v_pos_light_view_0;varying vec4 v_pos_light_view_1;varying float v_depth;
1225#endif
1226const float wireframeOffset=0.00015;void main() {vec3 decomposedPosAndSkirt=decomposeToPosAndSkirt(a_pos);float skirt=decomposedPosAndSkirt.z;vec2 decodedPos=decomposedPosAndSkirt.xy;float elevation=elevation(decodedPos)-skirt*u_skirt_height;
1227#ifdef TERRAIN_WIREFRAME
1228elevation+=wireframeOffset;
1229#endif
1230v_pos0=decodedPos/8192.0;gl_Position=u_matrix*vec4(decodedPos,elevation,1.0);
1231#ifdef FOG
1232#ifdef ZERO_EXAGGERATION
1233v_fog_pos=fog_position(decodedPos);
1234#else
1235v_fog_opacity=fog(fog_position(vec3(decodedPos,elevation)));
1236#endif
1237#endif
1238#ifdef RENDER_SHADOWS
1239vec3 pos=vec3(decodedPos,elevation);v_pos_light_view_0=u_light_matrix_0*vec4(pos,1.);v_pos_light_view_1=u_light_matrix_1*vec4(pos,1.);v_depth=gl_Position.w;
1240#endif
1241}`),terrainDepth:Sr(`#ifdef GL_ES
1242precision highp float;
1243#endif
1244varying float v_depth;void main() {gl_FragColor=pack_depth(v_depth);}`,"uniform mat4 u_matrix;attribute vec2 a_pos;varying float v_depth;void main() {float elevation=elevation(a_pos);gl_Position=u_matrix*vec4(a_pos,elevation,1.0);v_depth=gl_Position.z/gl_Position.w;}"),skybox:Sr(`
1245varying lowp vec3 v_uv;uniform lowp samplerCube u_cubemap;uniform lowp float u_opacity;uniform highp float u_temporal_offset;uniform highp vec3 u_sun_direction;float sun_disk(highp vec3 ray_direction,highp vec3 sun_direction) {highp float cos_angle=dot(normalize(ray_direction),sun_direction);const highp float cos_sun_angular_diameter=0.99996192306;const highp float smoothstep_delta=1e-5;return smoothstep(
1246cos_sun_angular_diameter-smoothstep_delta,cos_sun_angular_diameter+smoothstep_delta,cos_angle);}float map(float value,float start,float end,float new_start,float new_end) {return ((value-start)*(new_end-new_start))/(e
1246nd-start)+new_start;}void main() {vec3 uv=v_uv;const float y_bias=0.015;uv.y+=y_bias;uv.y=pow(abs(uv.y),1.0/5.0);uv.y=map(uv.y,0.0,1.0,-1.0,1.0);vec3 sky_color=textureCube(u_cubemap,uv).rgb;
1247#ifdef FOG
1248sky_color=fog_apply_sky_gradient(v_uv.xzy,sky_color);
1249#endif
1250sky_color.rgb=dither(sky_color.rgb,gl_FragCoord.xy+u_temporal_offset);sky_color+=0.1*sun_disk(v_uv,u_sun_direction);gl_FragColor=vec4(sky_color*u_opacity,u_opacity);
1251#ifdef OVERDRAW_INSPECTOR
1252gl_FragColor=vec4(1.0);
1253#endif
1254}`,xl),skyboxGradient:Sr(`varying highp vec3 v_uv;uniform lowp sampler2D u_color_ramp;uniform highp vec3 u_center_direction;uniform lowp float u_radius;uniform lowp float u_opacity;uniform highp float u_temporal_offset;void main() {float progress=acos(dot(normalize(v_uv),u_center_direction))/u_radius;vec4 color=texture2D(u_color_ramp,vec2(progress,0.5));
1255#ifdef FOG
1256color.rgb=fog_apply_sky_gradient(v_uv.xzy,color.rgb/color.a)*color.a;
1257#endif
1258color*=u_opacity;color.rgb=dither(color.rgb,gl_FragCoord.xy+u_temporal_offset);gl_FragColor=color;
1259#ifdef OVERDRAW_INSPECTOR
1260gl_FragColor=vec4(1.0);
1261#endif
1262}`,xl),skyboxCapture:Sr(`
1263varying highp vec3 v_position;uniform highp float u_sun_intensity;uniform highp float u_luminance;uniform lowp vec3 u_sun_direction;uniform highp vec4 u_color_tint_r;uniform highp vec4 u_color_tint_m;
1264#ifdef GL_ES
1265precision highp float;
1266#endif
1267#define BETA_R                  vec3(5.5e-6,13.0e-6,22.4e-6)
1268#define BETA_M                  vec3(21e-6,21e-6,21e-6)
1269#define MIE_G                   0.76
1270#define DENSITY_HEIGHT_SCALE_R  8000.0
1271#define DENSITY_HEIGHT_SCALE_M  1200.0
1272#define PLANET_RADIUS           6360e3
1273#define ATMOSPHERE_RADIUS       6420e3
1274#define SAMPLE_STEPS            10
1275#define DENSITY_STEPS           4
1276float ray_sphere_exit(vec3 orig,vec3 dir,float radius) {float a=dot(dir,dir);float b=2.0*dot(dir,orig);float c=dot(orig,orig)-radius*radius;float d=sqrt(b*b-4.0*a*c);return (-b+d)/(2.0*a);}vec3 extinction(vec2 density) {return exp(-vec3(BETA_R*u_color_tint_r.a*density.x+BETA_M*u_color_tint_m.a*density.y));}vec2 local_density(vec3 point) {float height=max(length(point)-PLANET_RADIUS,0.0);float exp_r=exp(-height/DENSITY_HEIGHT_SCALE_R);float exp_m=exp(-height/DENSITY_HEIGHT_SCALE_M);return vec2(exp_r,exp_m);}float phase_ray(float cos_angle) {return (3.0/(16.0*PI))*(1.0+cos_angle*cos_angle);}
1276float phase_mie(float cos_angle) {return (3.0/(8.0*PI))*((1.0-MIE_G*MIE_G)*(1.0+cos_angle*cos_angle))/((2.0+MIE_G*MIE_G)*pow(1.0+MIE_G*MIE_G-2.0*MIE_G*cos_angle,1.5));}vec2 density_to_atmosphere(vec3 point,vec3 light_dir) {float ray_len=ray_sphere_exit(point,light_dir,ATMOSPHERE_RADIUS);float step_len=ray_len/float(DENSITY_STEPS);vec2 density_point_to_atmosphere=vec2(0.0);for (int i=0; i < DENSITY_STEPS;++i) {vec3 point_on_ray=point+light_dir*((float(i)+0.5)*step_len);density_point_to_atmosphere+=local_density(point_on_ray)*step_len;;}return density_point_to_atmosphere;}vec3 atmosphere(vec3 ray_dir,vec3 sun_direction,float sun_intensity) {vec2 density_orig_to_point=vec2(0.0);vec3 scatter_r=vec3(0.0);vec3 scatter_m=vec3(0.0);vec3 origin=vec3(0.0,PLANET_RADIUS,0.0);float ray_len=ray_sphere_exit(origin,ray_dir,ATMOSPHERE_RADIUS);float step_len=ray_len/float(SAMPLE_STEPS);for (int i=0; i < SAMPLE_STEPS;++i) {vec3 point_on_ray=origin+ray_dir*((float(i)+0.5)*step_len);vec2 density=local_density(point_on_ray)*step_len;density_orig_to_point+=density;vec2 density_point_to_atmosphere=density_to_atmosphere(point_on_ray,sun_direction);vec2 density_orig_to_atmosphere=density_orig_to_point+density_point_to_atmosphere;vec3 extinction=extinction(density_orig_to_atmosphere);scatter_r+=density.x*extinction;scatter_m+=density.y*extinction;}float cos_angle=dot(ray_dir,sun_direction);float phase_r=phase_ray(cos_angle);float phase_m=phase_mie(cos_angle);vec3 beta_r=BETA_R*u_color_tint_r.rgb*u_color_tint_r.a;vec3 beta_m=BETA_M*u_color_tint_m.rgb*u_color_tint_m.a;return (scatter_r*phase_r*beta_r+scatter_m*phase_m*beta_m)*sun_intensity;}const float A=0.15;const float B=0.50;const float C=0.10;const float D=0.20;const float E=0.02;const float F=0.30;vec3 uncharted2_tonemap(vec3 x) {return ((x*(A*x+C*B)+D*E)/(x*(A*x+B)+D*F))-E/F;}void main() {vec3 ray_direction=v_position;ray_direction.y=pow(ray_direction.y,5.0);const float y_bias=0.015;ray_direction.y+=y_bias;vec3 color=atmosphere(normalize(ray_direction),u_sun_direction,u_sun_intensity);float white_scale=1.0748724675633854;color=uncharted2_tonemap((log2(2.0/pow(u_luminance,4.0)))*color)*white_scale;gl_FragColor=vec4(color,1.0);}`,"attribute highp vec3 a_pos_3f;uniform mat3 u_matrix_3f;varying highp vec3 v_position;float map(float value,float start,float end,float new_start,float new_end) {return ((value-start)*(new_end-new_start))/(e
1276nd-start)+new_start;}void main() {vec4 pos=vec4(u_matrix_3f*a_pos_3f,1.0);v_position=pos.xyz;v_position.y*=-1.0;v_position.y=map(v_position.y,-1.0,1.0,0.0,1.0);gl_Position=vec4(a_pos_3f.xy,0.0,1.0);}"),globeRaster:Sr(`uniform sampler2D u_image0;varying vec2 v_pos0;
1277#ifndef FOG
1278uniform highp vec3 u_frustum_tl;uniform highp vec3 u_frustum_tr;uniform highp vec3 u_frustum_br;uniform highp vec3 u_frustum_bl;uniform highp vec3 u_globe_pos;uniform highp float u_globe_radius;uniform vec2 u_viewport;
1279#endif
1280void main() {vec4 color;
1281#ifdef CUSTOM_ANTIALIASING
1282vec2 uv=gl_FragCoord.xy/u_viewport;highp vec3 ray_dir=mix(
1283mix(u_frustum_tl,u_frustum_tr,uv.x),mix(u_frustum_bl,u_frustum_br,uv.x),1.0-uv.y);vec3 dir=normalize(ray_dir);vec3 closest_point=dot(u_globe_pos,dir)*dir;float norm_dist_from_center=1.0-length(closest_point-u_globe_pos)/u_globe_radius;const float antialias_pixel=2.0;float antialias_factor=antialias_pixel*fwidth(norm_dist_from_center);float antialias=smoothstep(0.0,antialias_factor,norm_dist_from_center);vec4 raster=texture2D(u_image0,v_pos0);color=vec4(raster.rgb*antialias,raster.a*antialias);
1284#else
1285color=texture2D(u_image0,v_pos0);
1286#endif
1287#ifdef FOG
1288color=fog_dither(fog_apply_premultiplied(color,v_fog_pos));
1289#endif
1290gl_FragColor=color;
1291#ifdef TERRAIN_WIREFRAME
1292gl_FragColor=vec4(1.0,0.0,0.0,0.8);
1293#endif
1294#ifdef OVERDRAW_INSPECTOR
1295gl_FragColor=vec4(1.0);
1296#endif
1297}`,`uniform mat4 u_proj_matrix;uniform mat4 u_normalize_matrix;uniform mat4 u_globe_matrix;uniform mat4 u_merc_matrix;uniform float u_zoom_transition;uniform vec2 u_merc_center;uniform mat3 u_grid_matrix;uniform float u_skirt_height;
1298#ifdef GLOBE_POLES
1299attribute vec3 a_globe_pos;attribute vec2 a_uv;
1300#else
1301attribute vec2 a_pos;
1302#endif
1303varying vec2 v_pos0;const float wireframeOffset=1e3;float mercatorXfromLng(float lng) {return (180.0+lng)/360.0;}float mercatorYfromLat(float lat) {return (180.0-(RAD_TO_DEG*log(tan(QUARTER_PI+lat/2.0*DEG_TO_RAD))))/360.0;}vec3 latLngToECEF(vec2 latLng) {latLng=DEG_TO_RAD*latLng;float cosLat=cos(latLng[0]);float sinLat=sin(latLng[0]);float cosLng=cos(latLng[1]);float sinLng=sin(latLng[1]);float sx=cosLat*sinLng*GLOBE_RADIUS;float sy=-sinLat*GLOBE_RADIUS;float sz=cosLat*cosLng*GLOBE_RADIUS;return vec3(sx,sy,sz);}void main() {
1304#ifdef GLOBE_POLES
1305vec3 globe_pos=a_globe_pos;vec2 uv=a_uv;
1306#else
1307float tiles=u_grid_matrix[0][2];float idx=u_grid_matrix[1][2];float idy=u_grid_matrix[2][2];vec3 decomposed_pos_and_skirt=decomposeToPosAndSkirt(a_pos);vec3 latLng=u_grid_matrix*vec3(decomposed_pos_and_skirt.xy,1.0);float mercatorY=mercatorYfromLat(latLng[0]);float uvY=mercatorY*tiles-idy;float mercatorX=mercatorXfromLng(latLng[1]);float uvX=mercatorX*tiles-idx;vec3 globe_pos=latLngToECEF(latLng.xy);vec2 merc_pos=vec2(mercatorX,mercatorY);vec2 uv=vec2(uvX,uvY);
1308#endif
1309v_pos0=uv;vec2 tile_pos=uv*EXTENT;vec3 globe_derived_up_vector=normalize(globe_pos)*u_tile_up_scale;
1310#ifdef GLOBE_POLES
1311vec3 up_vector=globe_derived_up_vector;
1312#else
1313vec3 up_vector=elevationVector(tile_pos);
1314#endif
1315float height=elevation(tile_pos);
1316#ifdef TERRAIN_WIREFRAME
1317height+=wireframeOffset;
1318#endif
1319globe_pos+=up_vector*height;
1320#ifndef GLOBE_POLES
1321globe_pos-=globe_derived_up_vector*u_skirt_height*decomposed_pos_and_skirt.z;
1322#endif
1323#ifdef GLOBE_POLES
1324vec4 interpolated_pos=u_globe_matrix*vec4(globe_pos,1.0);
1325#else
1326vec4 globe_world_pos=u_globe_matrix*vec4(globe_pos,1.0);vec4 merc_world_pos=vec4(0.0);if (u_zoom_transition > 0.0) {merc_world_pos=vec4(merc_pos,height-u_skirt_height*decomposed_pos_and_skirt.z,1.0);merc_world_pos.xy-=u_merc_center;merc_world_pos.x=wrap(merc_world_pos.x,-0.5,0.5);merc_world_pos=u_merc_matrix*merc_world_pos;}vec4 interpolated_pos=vec4(mix(globe_world_pos.xyz,merc_world_pos.xyz,u_zoom_transition),1.0);
1327#endif
1328gl_Position=u_proj_matrix*interpolated_pos;
1329#ifdef FOG
1330v_fog_pos=fog_position((u_normalize_matrix*vec4(globe_pos,1.0)).xyz);
1331#endif
1332}`),globeAtmosphere:Sr(`uniform float u_transition;uniform highp float u_fadeout_range;uniform highp float u_temporal_offset;uniform vec3 u_start_color;uniform vec4 u_color;uniform vec4 u_space_color;uniform vec4 u_high_color;uniform float u_star_intensity;uniform float u_star_size;uniform float u_star_density;uniform float u_horizon_angle;uniform mat4 u_rotation_matrix;varying highp vec3 v_ray_dir;varying highp vec3 v_horizon_dir;
1332highp float random(highp vec3 p) {p=fract(p*vec3(23.2342,97.1231,91.2342));p+=dot(p.zxy,p.yxz+123.1234);return fract(p.x*p.y);}float stars(vec3 p,float scale,vec2 offset) {vec2 uv_scale=(u_viewport/u_star_size)*scale;vec3 position=vec3(p.xy*uv_scale+offset*u_viewport,p.z);vec3 q=fract(position)-0.5;vec3 id=floor(position);float random_visibility=step(random(id),u_star_density);float circle=smoothstep(0.5+u_star_intensity,0.5,length(q));return circle*random_visibility;}void main() {highp vec3 dir=normalize(v_ray_dir);float globe_pos_dot_dir;
1333#ifdef PROJECTION_GLOBE_VIEW
1334globe_pos_dot_dir=dot(u_globe_pos,dir);highp vec3 closest_point_forward=abs(globe_pos_dot_dir)*dir;float norm_dist_from_center=length(closest_point_forward-u_globe_pos)/u_globe_radius;if (norm_dist_from_center < 0.98) {discard;return;}
1335#endif
1336highp vec3 horizon_dir=normalize(v_horizon_dir);float horizon_angle_mercator=dir.y < horizon_dir.y ?
13370.0 : max(acos(dot(dir,horizon_dir)),0.0);float horizon_angle;
1338#ifdef PROJECTION_GLOBE_VIEW
1339highp vec3 closest_point=globe_pos_dot_dir*dir;float closest_point_to_center=length(closest_point-u_globe_pos);float theta=asin(clamp(closest_point_to_center/length(u_globe_pos),-1.0,1.0));horizon_angle=globe_pos_dot_dir < 0.0 ?
1340PI-theta-u_horizon_angle : theta-u_horizon_angle;float angle_t=pow(u_transition,10.0);horizon_angle=mix(horizon_angle,horizon_angle_mercator,angle_t);
1341#else
1342horizon_angle=horizon_angle_mercator;
1343#endif
1344horizon_angle/=PI;float t=exp(-horizon_angle/u_fadeout_range);float alpha_0=u_color.a;float alpha_1=u_high_color.a;float alpha_2=u_space_color.a;vec3 color_stop_0=u_color.rgb;vec3 color_stop_1=u_high_color.rgb;vec3 color_stop_2=u_space_color.rgb;vec3 c0=mix(color_stop_2,color_stop_1,alpha_1);vec3 c1=mix(c0,color_stop_0,alpha_0);vec3 c2=mix(c0,c1,t);vec3 c =mix(color_stop_2,c2,t);float a0=mix(alpha_2,1.0,alpha_1);float a1=mix(a0,1.0,alpha_0);float a2=mix(a0,a1,t);float a =mix(alpha_2,a2,t);vec2 uv=gl_FragCoord.xy/u_viewport-0.5;float aspect_ratio=u_viewport.x/u_viewport.y;vec4 uv_dir=vec4(normalize(vec3(uv.x*aspect_ratio,uv.y,1.0)),1.0);uv_dir=u_rotation_matrix*uv_dir;vec3 n=abs(uv_dir.xyz);vec2 uv_remap=(n.x > n.y && n.x > n.z) ? uv_dir.yz/uv_dir.x:
1345(n.y > n.x && n.y > n.z) ? uv_dir.zx/uv_dir.y:
1346uv_dir.xy/uv_dir.z;uv_remap.x/=aspect_ratio;vec3 D=vec3(uv_remap,1.0);highp float star_field=0.0;if (u_star_intensity > 0.0) {star_field+=stars(D,1.2,vec2(0.0,0.0));star_field+=stars(D,1.0,vec2(1.0,0.0));star_field+=stars(D,0.8,vec2(0.0,1.0));star_field+=stars(D,0.6,vec2(1.0,1.0));star_field*=(1.0-pow(t,0.25+(1.0-u_high_color.a)*0.75));c+=star_field*alpha_2;}c=dither(c,gl_FragCoord.xy+u_temporal_offset);gl_FragColor=vec4(c,a);}`,`attribute vec3 a_pos;attribute vec2 a_uv;uniform vec3 u_frustum_tl;uniform vec3 u_frustum_tr;uniform vec3 u_frustum_br;uniform vec3 u_frustum_bl;uniform float u_horizon;varying highp vec3 v_ray_dir;varying highp vec3 v_horizon_dir;void main() {v_ray_dir=mix(
1347mix(u_frustum_tl,u_frustum_tr,a_uv.x),mix(u_frustum_bl,u_frustum_br,a_uv.x),a_uv.y);v_horizon_dir=mix(
1348mix(u_frustum_tl,u_frustum_bl,u_horizon),mix(u_frustum_tr,u_frustum_br,u_horizon),a_uv.x);gl_Position=vec4(a_pos,1.0);}`)};function Ys(y,h){const f=y.replace(/\s*\/\/[^\n]*\n/g,`
1349`).split(`
1350`);for(let v of f)if(v=v.trim(),v[0]==="#"&&v.includes("if")&&!v.includes("endif")){v=v.replace("#","").replace(/ifdef|ifndef|elif|if/g,"").replace(/!|defined|\(|\)|\|\||&&/g,"").replace(/\s+/g," ").trim();const w=v.split(" ");for(const S of w)h.includes(S)||h.push(S)}}function Sr(y,h){const f=/#pragma mapbox: ([\w]+) ([\w]+) ([\w]+) ([\w]+)/g,v=h.match(/attribute (highp |mediump |lowp )?([\w]+) ([\w]+)/g),w={},S=[...pa];return Ys(y,S),Ys(h,S),{fragmentSource:y=y.replace(f,(I,L,z,H,q)=>(w[q]=!0,L==="define"?`
1351#ifndef HAS_UNIFORM_u_${q}
1352varying ${z} ${H} ${q};
1353#else
1354uniform ${z} ${H} u_${q};
1355#endif
1356`:`
1357#ifdef HAS_UNIFORM_u_${q}
1358    ${z} ${H} ${q} = u_${q};
1359#endif
1360`)),vertexSource:h=h.replace(f,(I,L,z,H,q)=>{const ee=H==="float"?"vec2":"vec4",de=q.match(/color/)?"color":ee;return w[q]?L==="define"?`
1361#ifndef HAS_UNIFORM_u_${q}
1362uniform lowp float u_${q}_t;
1363attribute ${z} ${ee} a_${q};
1364varying ${z} ${H} ${q};
1365#else
1366uniform ${z} ${H} u_${q};
1367#endif
1368`:de==="vec4"?`
1369#ifndef HAS_UNIFORM_u_${q}
1370    ${q} = a_${q};
1371#else
1372    ${z} ${H} ${q} = u_${q};
1373#endif
1374`:`
1375#ifndef HAS_UNIFORM_u_${q}
1376    ${q} = unpack_mix_${de}(a_${q}, u_${q}_t);
1377#else
1378    ${z} ${H} ${q} = u_${q};
1379#endif
1380`:L==="define"?`
1381#ifndef HAS_UNIFORM_u_${q}
1382uniform lowp float u_${q}_t;
1383attribute ${z} ${ee} a_${q};
1384#else
1385uniform ${z} ${H} u_${q};
1386#endif
1387`:de==="vec4"?`
1388#ifndef HAS_UNIFORM_u_${q}
1389    ${z} ${H} ${q} = a_${q};
1390#else
1391    ${z} ${H} ${q} = u_${q};
1392#endif
1393`:`
1394#ifndef HAS_UNIFORM_u_${q}
1395    ${z} ${H} ${q} = unpack_mix_${de}(a_${q}, u_${q}_t);
1396#else
1397    ${z} ${H} ${q} = u_${q};
1398#endif
1399`}),staticAttributes:v,usedDefines:S}}class Ap{constructor(){this.boundProgram=null,this.boundLayoutVertexBuffer=null,this.boundPaintVertexBuffers=[],this.boundIndexBuffer=null,this.boundVertexOffset=null,this.boundDynamicVertexBuffers=[],this.vao=null}bind(h,f,v,w,S,I,L){this.context=h;let z=this.boundPaintVertexBuffers.length!==w.length;for(let q=0;!z&&q<w.length;q++)this.boundPaintVertexBuffers[q]!==w[q]&&(z=!0);let H=this.boundDynamicVertexBuffers.length!==L.length;for(let q=0;!H&&q<L.length;q++)this.boundDynamicVertexBuffers[q]!==L[q]&&(H=!0);if(!h.extVertexArrayObject||!this.vao||this.boundProgram!==f||this.boundLayoutVertexBuffer!==v||z||H||this.boundIndexBuffer!==S||this.boundVertexOffset!==I)this.freshBind(f,v,w,S,I,L);else{h.bindVertexArrayOES.set(this.vao);for(const q of L)q&&q.bind();S&&S.dynamicDraw&&S.bind()}}freshBind(h,f,v,w,S,I){let L;const z=h.numAttributes,H=this.context,q=H.gl;if(H.extVertexArrayObject)this.vao&&this.destroy(),this.vao=H.extVertexArrayObject.createVertexArrayOES(),H.bindVertexArrayOES.set(this.vao),L=0,this.boundProgram=h,this.boundLayoutVertexBuffer=f,this.boundPaintVertexBuffers=v,this.boundIndexBuffer=w,this.boundVertexOffset=S,this.boundDynamicVertexBuffers=I;else{L=H.currentNumAttributes||0;for(let ee=z;ee<L;ee++)q.disableVertexAttribArray(ee)}f.enableAttributes(q,h),f.bind(),f.setVertexAttribPointers(q,h,S);for(const ee of v)ee.enableAttributes(q,h),ee.bind(),ee.setVertexAttribPointers(q,h,S);for(const ee of I)ee&&(ee.enableAttributes(q,h),ee.bind(),ee.setVertexAttribPointers(q,h,S));w&&w.bind(),H.currentNumAttributes=z}destroy(){this.vao&&(this.context.extVertexArrayObject.deleteVertexArrayOES(this.vao),this.vao=null)}}function Xd(y,h){const f=Math.pow(2,h.canonical.z),v=h.canonical.y;return[new a.MercatorCoordinate(0,v/f).toLngLat().lat,new a.MercatorCoordinate(0,(v+1)/f).toLngLat().lat]}
1399function wl(y,h,f,v,w,S,I){const L=y.context,z=L.gl,H=f.fbo;if(!H)return;y.prepareDrawTile();const q=y.useProgram("hillshade");L.activeTexture.set(z.TEXTURE0),z.bindTexture(z.TEXTURE_2D,H.colorAttachment.get());const ee=((ve,Ee,te,ye)=>{const Oe=te.paint.get("hillshade-shadow-color"),Le=te.paint.get("hillshade-highlight-color"),He=te.paint.get("hillshade-accent-color");let Ze=te.paint.get("hillshade-illumination-direction")*(Math.PI/180);te.paint.get("hillshade-illumination-anchor")==="viewport"&&(Ze-=ve.transform.angle);const Ye=!ve.options.moving;return{u_matrix:ye||ve.transform.calculateProjMatrix(Ee.tileID.toUnwrapped(),Ye),u_image:0,u_latrange:Xd(0,Ee.tileID),u_light:[te.paint.get("hillshade-exaggeration"),Ze],u_shadow:Oe,u_highlight:Le,u_accent:He}})(y,f,v,y.terrain?h.projMatrix:null);y.prepareDrawProgram(L,q,h.toUnwrapped());const{tileBoundsBuffer:de,tileBoundsIndexBuffer:_e,tileBoundsSegments:be}=y.getTileBoundsBuffers(f);q.draw(L,z.TRIANGLES,w,S,I,a.CullFaceMode.disabled,ee,v.id,de,_e,be)}function yh(y,h,f){if(!h.needsDEMTextureUpload)return;const v=y.context,w=v.gl;v.pixelStoreUnpackPremultiplyAlpha.set(!1),h.demTexture=h.demTexture||y.getTileTexture(f.stride);const S=f.getPixels();h.demTexture?h.demTexture.update(S,{premultiply:!1}):h.demTexture=new a.Texture(v,S,w.RGBA,{premultiply:!1}),h.needsDEMTextureUpload=!1}function Pp(y,h,f,v,w,S){const I=y.context,L=I.gl;if(!h.dem)return;const z=h.dem;if(I.activeTexture.set(L.TEXTURE1),yh(y,h,z),!h.demTexture)return;h.demTexture.bind(L.NEAREST,L.CLAMP_TO_EDGE);const H=z.dim;I.activeTexture.set(L.TEXTURE0);let q=h.fbo;if(!q){const be=new a.Texture(I,{width:H,height:H,data:null},L.RGBA);be.bind(L.LINEAR,L.CLAMP_TO_EDGE),q=h.fbo=I.createFramebuffer(H,H,!0),q.colorAttachment.set(be.texture)}I.bindFramebuffer.set(q.framebuffer),I.viewport.set([0,0,H,H]);const{tileBoundsBuffer:ee,tileBoundsIndexBuffer:de,tileBoundsSegments:_e}=y.getMercatorTileBoundsBuffers();y.useProgram("hillshadePrepare").draw(I,L.TRIANGLES,v,w,S,a.CullFaceMode.disabled,((be,ve)=>{const Ee=ve.stride,te=a.create();return a.ortho(te,0,a.EXTENT,-a.EXTENT,0,0,1),a.translate(te,te,[0,-a.EXTENT,0]),{u_matrix:te,u_image:1,u_dimension:[Ee,Ee],u_zoom:be.overscaledZ,u_unpack:ve.unpackVector}})(h.tileID,z),f.id,ee,de,_e),h.needsHillshadePrepare=!1}const Kd=y=>({u_matrix:new a.UniformMatrix4f(y),u_image0:new a.Uniform1i(y),u_skirt_height:new a.Uniform1f(y)}),Tl=(y,h)=>({u_matrix:y,u_image0:0,u_skirt_height:h}),El=(y,h,f,v,w,S,I,L,z,H,q,ee,de,_e,be)=>({u_proj_matrix:Float32Array.from(y),u_globe_matrix:h,u_normalize_matrix:Float32Array.from(v),u_merc_matrix:f,u_zoom_transition:w,u_merc_center:S,u_image0:0,u_frustum_tl:I,u_frustum_tr:L,u_frustum_br:z,u_frustum_bl:H,u_globe_pos:q,u_globe_radius:ee,u_viewport:de,u_grid_matrix:be?Float32Array.from(be):new Float32Array(9),u_skirt_height:_e});function Sl(y,h){return y!=null&&h!=null&&!(!y.hasData()||!h.hasData())&&y.demTexture!=null&&h.demTexture!=null&&y.tileID.key!==h.tileID.key}const ls=new class{constructor(){this.operations={}}newMorphing(y,h,f,v,w){if(y in this.operations){const S=this.operations[y];S.to.tileID.key!==f.tileID.key&&(S.queued=f)}else this.operations[y]={startTime:v,phase:0,duration:w,from:h,to:f,queued:null}}getMorphValuesForProxy(y){if(!(y in this.operations))return null;const h=this.operations[y];return{from:h.from,to:h.to,phase:h.phase}}update(y){for(const h in this.operations){const f=this.operations[h];for(f.phase=(y-f.startTime)/f.duration;f.phase>=1||!this._validOp(f);)if(!this._nextOp(f,y)){delete this.operations[h];break}}}_nextOp(y,h){return!!y.queued&&(y.from=y.to,y.to=y.queued,y.queued=null,y.phase=0,y.startTime=h,!0)}_validOp(y){return y.from.hasData()&&y.to.hasData()}},Zs={0:null,1:"TERRAIN_VERTEX_MORPHING",2:"TERRAIN_WIREFRAME"};function Cl(y){return 6*Math.pow(1.5,22-y)}function Mp(y,h){const f=1<<y.z;return!h&&(y.x===0||y.x===f-1)||y.y===0||y.y===f-1}const Su=y=>({u_matrix:y});function Qd(y,h,f,v,w){if(w>0){const S=a.exported.now(),I=(S-y.timeAdded)/w,L=h?(S-h.timeAdded)/w:-1,z=f.getSource(),H=v.coveringZoomLevel({tileSize:z.tileSize,roundZoom:z.roundZoom}),q=!h||Math.abs(h.tileID.overscaledZ-H)>Math.abs(y.tileID.overscaledZ-H),ee=q&&y.refreshedUponExpiration?1:a.clamp(q?I:1-L,0,1);return y.refreshedUponExpiration&&I>=1&&(y.refreshedUponExpiration=!1),h?{opacity:1,mix:1-ee}:{opacity:ee,mix:0}}return{opacity:1,mix:0}}class Jd extends a.SourceCache{constructor(h){const f={type:"raster-dem",maxzoom:h.transform.maxZoom},v=new se(Lc(),null),w=or("mock-dem",f,v,h.style);super("mock-dem",w,!1),w.setEventedParent(this),this._sourceLoaded=!0}_loadTile(h,f){h.state="loaded",f(null)}}class _h extends a.SourceCache{constructor(h){const f=or("proxy",{type:"geojson",maxzoom:h.transform.maxZoom},new se(Lc(),null),h.style);super("proxy",f,!1),f.setEventedParent(this),this.map=this.getSource().map=h,this.used=this._sourceLoaded=!0,this.renderCache=[],this.renderCachePool=[],this.proxyCachedFBO={}}update(h,f,v){if(h.freezeTileCoverage)return;this.transform=h;const w=h.coveringTiles({tileSize:this._source.tileSize,minzoom:this._source.minzoom,maxzoom:this._source.maxzoom,roundZoom:this._source.roundZoom,reparseOverscaled:this._source.reparseOverscaled}).reduce((S,I)=>
1399{if(S[I.key]="",!this._tiles[I.key]){const L=new a.Tile(I,this._source.tileSize*I.overscaleFactor(),h.tileZoom);L.state="loaded",this._tiles[I.key]=L}return S},{});for(const S in this._tiles)S in w||(this.freeFBO(S),this._tiles[S].unloadVectorData(),delete this._tiles[S])}freeFBO(h){const f=this.proxyCachedFBO[h];if(f!==void 0){const v=Object.values(f);this.renderCachePool.push(...v),delete this.proxyCachedFBO[h]}}deallocRenderCache(){this.renderCache.forEach(h=>h.fb.destroy()),this.renderCache=[],this.renderCachePool=[],this.proxyCachedFBO={}}}class Cu extends a.OverscaledTileID{constructor(h,f,v){super(h.overscaledZ,h.wrap,h.canonical.z,h.canonical.x,h.canonical.y),this.proxyTileKey=f,this.projMatrix=v}}class ku extends a.Elevation{constructor(h,f){super(),this.painter=h,this.terrainTileForTile={},this.prevTerrainTileForTile={};const[v,w,S]=function(z){const H=new a.StructArrayLayout2i4,q=new a.StructArrayLayout3ui6,ee=131;H.reserve(17161),q.reserve(33800);const de=a.EXTENT/128,_e=a.EXTENT+de/2,be=_e+de;for(let Ee=-de;Ee<be;Ee+=de)for(let te=-de;te<be;te+=de){const ye=te<0||te>_e||Ee<0||Ee>_e?24575:0,Oe=a.clamp(Math.round(te),0,a.EXTENT),Le=a.clamp(Math.round(Ee),0,a.EXTENT);H.emplaceBack(Oe+ye,Le)}const ve=(Ee,te)=>{const ye=te*ee+Ee;q.emplaceBack(ye+1,ye,ye+ee),q.emplaceBack(ye+ee,ye+ee+1,ye+1)};for(let Ee=1;Ee<129;Ee++)for(let te=1;te<129;te++)ve(te,Ee);return[0,129].forEach(Ee=>{for(let te=0;te<130;te++)ve(te,Ee),ve(Ee,te)}),[H,q,32768]}(),I=h.context;this.gridBuffer=I.createVertexBuffer(v,a.posAttributes.members),this.gridIndexBuffer=I.createIndexBuffer(w),this.gridSegments=a.SegmentVector.simpleSegment(0,0,v.length,w.length),this.gridNoSkirtSegments=a.SegmentVector.simpleSegment(0,0,v.length,S),this.proxyCoords=[],this.proxiedCoords={},this._visibleDemTiles=[],this._drapedRenderBatches=[],this._sourceTilesOverlap={},this.proxySourceCache=new _h(f.map),this.orthoMatrix=a.create(),a.ortho(this.orthoMatrix,this.painter.transform.projection.name==="globe"?.015:0,a.EXTENT,0,a.EXTENT,0,1);const L=I.gl;this._overlapStencilMode=new a.StencilMode({func:L.GEQUAL,mask:255},0,255,L.KEEP,L.KEEP,L.REPLACE),this._previousZoom=h.transform.zoom,this.pool=[],this._findCoveringTileCache={},this._tilesDirty={},this.style=f,this._useVertexMorphing=!0,this._exaggeration=1,this._mockSourceCache=new Jd(f.map)}set style(h){h.on("data",this._onStyleDataEvent.bind(this)),h.on("neworder",this._checkRenderCacheEfficiency.bind(this)),this._style=h,this._checkRenderCacheEfficiency(),this._style.map.on("moveend",()=>{this._clearLineLayersFromRenderCache()})}update(h,f,v){if(h&&h.terrain){this._style!==h&&(this.style=h),this.enabled=!0;const w=h.terrain.properties;this.sourceCache=h.terrain.drapeRenderMode===0?this._mockSourceCache:h._getSourceCache(w.get("source")),this._exaggeration=w.get("exaggeration");const S=()=>{this.sourceCache.used&&a.warnOnce(`Raster DEM source '${this.sourceCache.id}' is used both for terrain and as layer source.
1400This leads to lower resolution of hillshade. For full hillshade resolution but higher memory consumption, define another raster DEM source.`);const I=this.getScaledDemTileSize();this.sourceCache.update(f,I,!0),this.resetTileLookupCache(this.sourceCache.id)};this.sourceCache.usedForTerrain||(this.resetTileLookupCache(this.sourceCache.id),this.sourceCache.usedForTerrain=!0,S(),this._initializing=!0),S(),f.updateElevation(!0,v),this.resetTileLookupCache(this.proxySourceCache.id),this.proxySourceCache.update(f),this._emptyDEMTextureDirty=!0}else this._disable()}resetTileLookupCache(h){this._findCoveringTileCache[h]={}}getScaledDemTileSize(){return this.sourceCache.getSource().tileSize/128*this.proxySourceCache.getSource().tileSize}_checkRenderCacheEfficiency(){const h=this.renderCacheEfficiency(this._style);this._style.map._optimizeForTerrain||h.efficiency!==100&&a.warnOnce(`Terrain render cache efficiency is not optimal (${h.efficiency}%) and performance
1401                may be affected negatively, consider placing all background, fill and line layers before layer
1402                with id '${h.firstUndrapedLayer}' or create a map using optimizeForTerrain: true option.`)}_onStyleDataEvent(h){h.coord&&h.dataType==="source"?this._clearRenderCacheForTile(h.sourceCacheId,h.coord):h.dataType==="style"&&(this._invalidateRenderCache=!0)}_disable(){if(this.enabled&&(this.enabled=!1,this._sharedDepthStencil=void 0,this.proxySourceCache.deallocRenderCache(),this._style))for(const h in this._style._sourceCaches)this._style._sourceCaches[h].usedForTerrain=!1}destroy(){this._disable(),this._emptyDEMTexture&&this._emptyDEMTexture.destroy(),this._emptyDepthBufferTexture&&this._emptyDepthBufferTexture.destroy(),this.pool.forEach(h=>h.fb.destroy()),this.pool=[],this._depthFBO&&(this._depthFBO.destroy(),this._depthFBO=void 0,this._depthTexture=void 0)}_source(){return this.enabled?this.sourceCache:null}isUsingMockSource(){return this.sourceCache===this._mockSourceCache}exaggeration(){return this._exaggeration}get visibleDemTiles(){return this._visibleDemTiles}get drapeBufferSize(){const h=2*this.proxySourceCache.getSource().tileSize;return[h,h]}set useVertexMorphing(h){this._useVertexMorphing=h}
1402updateTileBinding(h){if(!this.enabled)return;this.prevTerrainTileForTile=this.terrainTileForTile;const f=this.proxySourceCache,v=this.painter.transform;this._initializing&&(this._initializing=v._centerAltitude===0&&this.getAtPointOrZero(a.MercatorCoordinate.fromLngLat(v.center),-1)===-1,this._emptyDEMTextureDirty=!this._initializing);const w=this.proxyCoords=f.getIds().map(z=>{const H=f.getTileByID(z).tileID;return H.projMatrix=v.calculateProjMatrix(H.toUnwrapped()),H});(function(z,H){const q=H.transform.pointCoordinate(H.transform.getCameraPoint()),ee=new a.Point(q.x,q.y);z.sort((de,_e)=>{if(_e.overscaledZ-de.overscaledZ)return _e.overscaledZ-de.overscaledZ;const be=new a.Point(de.canonical.x+(1<<de.canonical.z)*de.wrap,de.canonical.y),ve=new a.Point(_e.canonical.x+(1<<_e.canonical.z)*_e.wrap,_e.canonical.y),Ee=ee.mult(1<<de.canonical.z);return Ee.x-=.5,Ee.y-=.5,Ee.distSqr(be)-Ee.distSqr(ve)})})(w,this.painter),this._previousZoom=v.zoom;const S=this.proxyToSource||{};this.proxyToSource={},w.forEach(z=>{this.proxyToSource[z.key]={}}),this.terrainTileForTile={};const I=this._style._sourceCaches;for(const z in I){const H=I[z];if(!H.used||(H!==this.sourceCache&&this.resetTileLookupCache(H.id),this._setupProxiedCoordsForOrtho(H,h[z],S),H.usedForTerrain))continue;const q=h[z];H.getSource().reparseOverscaled&&this._assignTerrainTiles(q)}this.proxiedCoords[f.id]=w.map(z=>new Cu(z,z.key,this.orthoMatrix)),this._assignTerrainTiles(w),this._prepareDEMTextures(),this._setupDrapedRenderBatches(),this._initFBOPool(),this._setupRenderCache(S),this.renderingToTexture=!1,this._updateTimestamp=a.exported.now();const L={};this._visibleDemTiles=[];for(const z of this.proxyCoords){const H=this.terrainTileForTile[z.key];if(!H)continue;const q=H.tileID.key;q in L||(this._visibleDemTiles.push(H),L[q]=q)}}_assignTerrainTiles(h){this._initializing||h.forEach(f=>{if(this.terrainTileForTile[f.key])return;const v=this._findTileCoveringTileID(f,this.sourceCache);v&&(this.terrainTileForTile[f.key]=v)})}_prepareDEMTextures(){const h=this.painter.context,f=h.gl;for(const v in this.terrainTileForTile){const w=this.terrainTileForTile[v],S=w.dem;!S||w.demTexture&&!w.needsDEMTextureUpload||(h.activeTexture.set(f.TEXTURE1),yh(this.painter,w,S))}}_prepareDemTileUniforms(h,f,v,w){if(!f||f.demTexture==null)return!1;const S=h.tileID.canonical,I=Math.pow(2,f.tileID.canonical.z-S.z),L=w||"";return v[`u_dem_tl${L}`]=[S.x*I%1,S.y*I%1],v[`u_dem_scale${L}`]=I,!0}get emptyDEMTexture(){return!this._emptyDEMTextureDirty&&this._emptyDEMTexture?this._emptyDEMTexture:this._updateEmptyDEMTexture()}get emptyDepthBufferTexture(){const h=this.painter.context,f=h.gl;if(!this._emptyDepthBufferTexture){const v=new a.RGBAImage({width:1,height:1},Uint8Array.of(255,255,255,255));this._emptyDepthBufferTexture=new a.Texture(h,v,f.RGBA,{premultiply:!1})}return this._emptyDepthBufferTexture}_getLoadedAreaMinimum(){let h=0;const f=this._visibleDemTiles.reduce((v,w)=>{if(!w.dem)return v;const S=w.dem.tree.minimums[0];return S>0&&h++,v+S},0);return h?f/h:0}_updateEmptyDEMTexture(){const h=this.painter.context,f=h.gl;h.activeTexture.set(f.TEXTURE2);const v=this._getLoadedAreaMinimum(),w=new a.RGBAImage({width:1,height:1},new Uint8Array(a.DEMData.pack(v,this.sourceCache.getSource().encoding)));this._emptyDEMTextureDirty=!1;let S=this._emptyDEMTexture;return S?S.update(w,{premultiply:!1}):S=this._emptyDEMTexture=new a.Texture(h,w,f.RGBA,{premultiply:!1}),S}setupElevationDraw(h,f,v){const w=this.painter.context,S=w.gl,I=(L=this.sourceCache.getSource().encoding,{u_dem:2,u_dem_prev:4,u_dem_unpack:a.DEMData.getUnpackVector(L),u_dem_tl:[0,0],u_dem_tl_prev:[0,0],u_dem_scale:0,u_dem_scale_prev:0,u_dem_size:0,u_dem_lerp:1,u_depth:3,u_depth_size_inv:[0,0],u_exaggeration:0});var L;I.u_dem_size=this.sourceCache.getSource().tileSize,I.u_exaggeration=this.exaggeration();let z=null,H=null,q=1;if(v&&v.morphing&&this._useVertexMorphing){const ee=v.morphing.srcDemTile,de=v.morphing.dstDemTile;q=v.morphing.phase,ee&&de&&(this._prepareDemTileUniforms(h,ee,I,"_prev")&&(H=ee),this._prepareDemTileUniforms(h,de,I)&&(z=de))}if(H&&z?(w.activeTexture.set(S.TEXTURE2),z.demTexture.bind(S.NEAREST,S.CLAMP_TO_EDGE,S.NEAREST),w.activeTexture.set(S.TEXTURE4),H.demTexture.bind(S.NEAREST,S.CLAMP_TO_EDGE,S.NEAREST),I.u_dem_lerp=q):(z=this.terrainTileForTile[h.tileID.key],w.activeTexture.set(S.TEXTURE2),(this._prepareDemTileUniforms(h,z,I)?z.demTexture:this.empty
1402DEMTexture).bind(S.NEAREST,S.CLAMP_TO_EDGE)),w.activeTexture.set(S.TEXTURE3),v&&v.useDepthForOcclusion?(this._depthTexture&&this._depthTexture.bind(S.NEAREST,S.CLAMP_TO_EDGE),this._depthFBO&&(I.u_depth_size_inv=[1/this._depthFBO.width,1/this._depthFBO.height])):(this.emptyDepthBufferTexture.bind(S.NEAREST,S.CLAMP_TO_EDGE),I.u_depth_size_inv=[1,1]),v&&v.useMeterToDem&&z){const ee=(1<<z.tileID.canonical.z)*a.mercatorZfromAltitude(1,this.painter.transform.center.lat)*this.sourceCache.getSource().tileSize;I.u_meter_to_dem=ee}if(v&&v.labelPlaneMatrixInv&&(I.u_label_plane_matrix_inv=v.labelPlaneMatrixInv),f.setTerrainUniformValues(w,I),this.painter.transform.projection.name==="globe"){const ee=this.globeUniformValues(this.painter.transform,h.tileID.canonical,v&&v.useDenormalizedUpVectorScale);f.setGlobeUniformValues(w,ee)}}globeUniformValues(h,f,v){const w=h.projection;return{u_tile_tl_up:w.upVector(f,0,0),u_tile_tr_up:w.upVector(f,a.EXTENT,0),u_tile_br_up:w.upVector(f,a.EXTENT,a.EXTENT),u_tile_bl_up:w.upVector(f,0,a.EXTENT),u_tile_up_scale:v?a.globeMetersToEcef(1):w.upVectorScale(f,h.center.lat,h.worldSize).metersToTile}}renderToBackBuffer(h){const f=this.painter,v=this.painter.context;h.length!==0&&(v.bindFramebuffer.set(null),v.viewport.set([0,0,f.width,f.height]),f.gpuTimingDeferredRenderStart(),this.renderingToTexture=!1,function(w,S,I,L,z){if(w.transform.projection.name==="globe")(function(H,q,ee,de,_e){const be=H.context,ve=be.gl;let Ee,te;const ye=H.options.showTerrainWireframe?2:0,Oe=H.transform,Le=a.globeUseCustomAntiAliasing(H,be,Oe),He=(Yt,gt)=>{if(te===Yt)return;const Ft=[Zs[Yt],"PROJECTION_GLOBE_VIEW"];Le&&Ft.push("CUSTOM_ANTIALIASING"),gt&&Ft.push(Zs[ye]),Ee=H.useProgram("globeRaster",null,Ft),te=Yt},Ze=H.colorModeForRenderPass(),Ye=new a.DepthMode(ve.LEQUAL,a.DepthMode.ReadWrite,H.depthRangeFor3D);ls.update(_e);const ot=a.calculateGlobeMercatorMatrix(Oe),et=[a.mercatorXfromLng(Oe.center.lng),a.mercatorYfromLat(Oe.center.lat)],_t=ye?[!1,!0]:[!1],Zt=H.globeSharedBuffers,dt=[Oe.width*a.exported.devicePixelRatio,Oe.height*a.exported.devicePixelRatio],Bt=Float32Array.from(Oe.globeMatrix),St={useDenormalizedUpVectorScale:!0};if(_t.forEach(Yt=>{const gt=H.transform,Ft=Cl(gt.zoom)*q.exaggeration();te=-1;const Jt=Yt?ve.LINES:ve.TRIANGLES;for(const Ut of de){const tn=ee.getTile(Ut),Mn=a.StencilMode.disabled,Wn=q.prevTerrainTileForTile[Ut.key],wn=q.terrainTileForTile[Ut.key];Sl(Wn,wn)&&ls.newMorphing(Ut.key,Wn,wn,_e,250),be.activeTexture.set(ve.TEXTURE0),tn.texture.bind(ve.LINEAR,ve.CLAMP_TO_EDGE);const Bn=ls.getMorphValuesForProxy(Ut.key),mr=Bn?1:0;Bn&&a.extend$1(St,{morphing:{srcDemTile:Bn.from,dstDemTile:Bn.to,phase:a.easeCubicInOut(Bn.phase)}});const pr=a.tileCornersToBounds(Ut.canonical),Cn=a.getLatitudinalLod(pr.getCenter().lat),Nr=a.getGridMatrix(Ut.canonical,pr,Cn,gt.worldSize/gt._pixelsPerMercatorPixel),Qr=a.globeNormalizeECEF(a.globeTileBounds(Ut.canonical)),Jr=El(gt.projMatrix,Bt,ot,Qr,a.globeToMercatorTransition(gt.zoom),et,gt.frustumCorners.TL,gt.frustumCorners.TR,gt.frustumCorners.BR,gt.frustumCorners.BL,gt.globeCenterInViewSpace,gt.globeRadius,dt,Ft,Nr);if(He(mr,Yt),q.setupElevationDraw(tn,Ee,St),H.prepareDrawProgram(be,Ee,Ut.toUnwrapped()),Zt){const[ei,ya,Yo]=Yt?Zt.getWirefameBuffers(H.context,Cn):Zt.getGridBuffers(Cn,Ft!==0);Ee.draw(be,Jt,Ye,Mn,Ze,a.CullFaceMode.backCCW,Jr,"globe_raster",ei,ya,Yo)}}}),Zt){const Yt=["GLOBE_POLES","PROJECTION_GLOBE_VIEW"];Le&&Yt.push("CUSTOM_ANTIALIASING"),Ee=H.useProgram("globeRaster",null,Yt);for(const gt of de){const{x:Ft,y:Jt,z:Ut}=gt.canonical,tn=Jt===0,Mn=Jt===(1<<Ut)-1,[Wn,wn,Bn,mr]=Zt.getPoleBuffers(Ut);if(mr&&(tn||Mn)){const pr=ee.getTile(gt);be.activeTexture.set(ve.TEXTURE0),pr.texture.bind(ve.LINEAR,ve.CLAMP_TO_EDGE);let Cn=a.globePoleMatrixForTile(Ut,Ft,Oe);const Nr=a.globeNormalizeECEF(a.globeTileBounds(gt.canonical)),Qr=(Jr,ei)=>Jr.draw(be,ve.TRIANGLES,Ye,a.StencilMode.disabled,Ze,a.CullFaceMode.disabled,El(Oe.projMatrix,Cn,Cn,Nr,0,et,Oe.frustumCorners.TL,Oe.frustumCorners.TR,Oe.frustumCorners.BR,Oe.frustumCorners.BL,Oe.globeCenterInViewSpace,Oe.globeRadius,dt,0),"globe_pole_raster",ei,Bn,mr);q.setupElevationDraw(pr,Ee,St),H.prepareDrawProgram(be,Ee,gt.toUnwrapped()),tn&&Qr(Ee,Wn),Mn&&(Cn=a.scale(a.create(),Cn,[1,-1,1]),Qr(Ee,wn))}}}})(w,S,I,L,z);else{const H=w.context,q=H.gl;let ee,de;const _e=w.options.showTerrainWireframe?2:0,be=(Oe,Le)=>{if(de===Oe)return;const He=[Zs[Oe]];Le&&He.push(Zs[_e]),ee=w.useProgram("terrainRaster",null,He),de=Oe},ve=w.colorModeForRenderPass(),Ee=new a.DepthMode(q.LEQUAL,a.DepthMode.ReadWrite,w.depthRangeFor3D);ls.update(z);const te=w.transform,ye=Cl(te.zoom)*S.exaggeration();
1402(_e?[!1,!0]:[!1]).forEach(Oe=>{de=-1;const Le=Oe?q.LINES:q.TRIANGLES,[He,Ze]=Oe?S.getWirefameBuffer():[S.gridIndexBuffer,S.gridSegments];for(const Ye of L){const ot=I.getTile(Ye),et=a.StencilMode.disabled,_t=S.prevTerrainTileForTile[Ye.key],Zt=S.terrainTileForTile[Ye.key];Sl(_t,Zt)&&ls.newMorphing(Ye.key,_t,Zt,z,250),H.activeTexture.set(q.TEXTURE0),ot.texture.bind(q.LINEAR,q.CLAMP_TO_EDGE,q.LINEAR_MIPMAP_NEAREST);const dt=ls.getMorphValuesForProxy(Ye.key),Bt=dt?1:0;let St;dt&&(St={morphing:{srcDemTile:dt.from,dstDemTile:dt.to,phase:a.easeCubicInOut(dt.phase)}});const Yt=Tl(Ye.projMatrix,Mp(Ye.canonical,te.renderWorldCopies)?ye/10:ye);be(Bt,Oe),S.setupElevationDraw(ot,ee,St),w.prepareDrawProgram(H,ee,Ye.toUnwrapped()),ee.draw(H,Le,Ee,et,ve,a.CullFaceMode.backCCW,Yt,"terrain_raster",S.gridBuffer,He,Ze)}})}}(f,this,this.proxySourceCache,h,this._updateTimestamp),this.renderingToTexture=!0,f.gpuTimingDeferredRenderEnd(),h.splice(0,h.length))}renderBatch(h){if(this._drapedRenderBatches.length===0)return h+1;this.renderingToTexture=!0;const f=this.painter,v=this.painter.context,w=this.proxySourceCache,S=this.proxiedCoords[w.id],I=this._drapedRenderBatches.shift(),L=[],z=f.style.order;let H=0;for(const q of S){const ee=w.getTileByID(q.proxyTileKey),de=w.proxyCachedFBO[q.key]?w.proxyCachedFBO[q.key][h]:void 0,_e=de!==void 0?w.renderCache[de]:this.pool[H++],be=de!==void 0;if(ee.texture=_e.tex,be&&!_e.dirty){L.push(ee.tileID);continue}let ve;v.bindFramebuffer.set(_e.fb.framebuffer),this.renderedToTile=!1,_e.dirty&&(v.clear({color:a.Color.transparent,stencil:0}),_e.dirty=!1);for(let Ee=I.start;Ee<=I.end;++Ee){const te=f.style._layers[z[Ee]];if(te.isHidden(f.transform.zoom))continue;const ye=f.style._getLayerSourceCache(te),Oe=ye?this.proxyToSource[q.key][ye.id]:[q];if(!Oe)continue;const Le=Oe;v.viewport.set([0,0,_e.fb.width,_e.fb.height]),ve!==(ye?ye.id:null)&&(this._setupStencil(_e,Oe,te,ye),ve=ye?ye.id:null),f.renderLayer(f,ye,te,Le)}this.renderedToTile?(_e.dirty=!0,L.push(ee.tileID)):be||--H,H===5&&(H=0,this.renderToBackBuffer(L))}return this.renderToBackBuffer(L),this.renderingToTexture=!1,v.bindFramebuffer.set(null),v.viewport.set([0,0,f.width,f.height]),I.end+1}postRender(){}renderCacheEfficiency(h){const f=h.order.length;if(f===0)return{efficiency:100};let v,w=0,S=0,I=!1;for(let L=0;L<f;++L){const z=h._layers[h.order[L]];this._style.isLayerDraped(z)?(I&&++w,++S):I||(I=!0,v=z.id)}return S===0?{efficiency:100}:{efficiency:100*(1-w/S),firstUndrapedLayer:v}}getMinElevationBelowMSL(){let h=0;return this._visibleDemTiles.filter(f=>f.dem).forEach(f=>{h=Math.min(h,f.dem.tree.minimums[0])}),h===0?h:(h-30)*this._exaggeration}raycast(h,f,v){if(!this._visibleDemTiles)return null;const w=this._visibleDemTiles.filter(S=>S.dem).map(S=>{const I=S.tileID,L=1<<I.overscaledZ,{x:z,y:H}=I.canonical,q=z/L,ee=(z+1)/L,de=H/L,_e=(H+1)/L;return{minx:q,miny:de,maxx:ee,maxy:_e,t:S.dem.tree.raycastRoot(q,de,ee,_e,h,f,v),tile:S}});w.sort((S,I)=>(S.t!==null?S.t:Number.MAX_VALUE)-(I.t!==null?I.t:Number.MAX_VALUE));for(const S of w){if(S.t==null)return null;const I=S.tile.dem.tree.raycast(S.minx,S.miny,S.maxx,S.maxy,h,f,v);if(I!=null)return I}return null}_createFBO(){const h=this.painter.context,f=h.gl,v=this.drapeBufferSize;h.activeTexture.set(f.TEXTURE0);const w=new a.Texture(h,{width:v[0],height:v[1],data:null},f.RGBA);w.bind(f.LINEAR,f.CLAMP_TO_EDGE);const S=h.createFramebuffer(v[0],v[1],!1);return S.colorAttachment.set(w.texture),S.depthAttachment=new Ke(h,S.framebuffer),this._sharedDepthStencil===void 0?(this._sharedDepthStencil=h.createRenderbuffer(h.gl.DEPTH_STENCIL,v[0],v[1]),this._stencilRef=0,S.depthAttachment.set(this._sharedDepthStencil),h.clear({stencil:0})):S.depthAttachment.set(this._sharedDepthStencil),h.extTextureFilterAnisotropic&&!h.extTextureFilterAnisotropicForceOff&&f.texParameterf(f.TEXTURE_2D,h.extTextureFilterAnisotropic.TEXTURE_MAX_ANISOTROPY_EXT,h.extTextureFilterAnisotropicMax),{fb:S,tex:w,dirty:!1}}_initFBOPool(){for(;this.pool.length<Math.min(5,this.proxyCoords.length);)this.pool.push(this._createFBO())}_shouldDisableRenderCache(){if(this._style.light&&this._style.light.hasTransition())return!0;for(const h in this._style._sourceCaches)if(this._style._sourceCaches[h].hasTransition())return!0;return this._style.order.some(h=>{const f=this._style._layers[h],v=f.isHidden(this.painter.transform.zoom);return f.type==="custom"?!v&&f.shouldRedrape():!v&&f.hasTransition()})}_clearLineLayersFromRenderCache(){let h=!1;for(const v of this._style._getSources())if(v instanceof ln){h=!0;break}if(!h)return;const f={};for(let v=0;v<this._style.order.length;++v){const w=this._style._layers[this._style.order[v]],S=this._style._getLayerSourceCache(w);if(S&&!f[S.id]&&!w.isHidden(this.painter.transform.zoom)&&w.type==="line"&&w.widthExpression()instanceof a.ZoomDependentExpression){f[S.id]=!0;for(const I of this.proxyCoords){const L=this.proxyToSource[I.key][S.id];if(L)for(const z of L)this._clearRenderCacheForTile(S.id,z)}}}}_clearRasterLayersFromRenderCache(){let h=!1;for(const v in this._style._sourceCaches)if(this._style._sourceCaches[v]._source instanceof Kt){h=!0;break}if(!h)return;const f={};for(let v=0;v<this._style.order.length;++v){const w=this._style._layers[this._style.order[v]],S=this._style._getLayerSourceCache(w);if(!S||f[S.id]||w.isHidden(this.painter.transform.zoom)||w.type!=="raster")continue;const I=w.paint.get("raster-fade-duration");for(const L of this.proxyCoords){const z=this.proxyToSource[L.key][S.id];if(z)for(const H of z){const q=Qd(S.getTile(H),S.findLoadedParent(H,0),S,this.painter.transform,I);(q.opacity!==1||q.mix!==0)&&this._clearRenderCacheForTile(S.id,H)}}}}_setupDrapedRenderBatches(){const h=this._style.order,f=h.length;if(f===0)return;const v=[];let w,S=0,I=this._style._layers[h[S]];for(;!this._style.isLayerDraped(I)&&I.isHidden(this.painter.transform.zoom)&&++S<f;)I=this._style._layers[h[S]];for(;S<f;++S){const L=this._style._layers[h[S]];L.isHidden(this.painter.transform.zoom)||(this._style.isLayerDraped(L)?w===void 0&&(w=S):w!==void 0&&(v.push({start:w,end:S-1}),w=void 0))}w!==void 0&&v.push({start:w,end:S-1}),this._drapedRenderBatches=v}_setupRenderCache(h){const f=this.proxySourceCache;if(this._shouldDisableRenderCache()||this._invalidateRenderCache){if(this._invalidateRenderCache=!1,f.renderCache.length>f.renderCachePool.length){const I=Object.values(f.proxyCachedFBO);f.proxyCachedFBO={};for(let L=0;L<I.length;++L){const z=Object.values(I[L]);f.renderCachePool.push(...z)}}return}this._clearRasterLayersFromRenderCache();const v=this.proxyCoords,w=this._tilesDirty;for(let I=v.length-1;I>=0;I--){const L=v[I];if(f.getTileByID(L.key),f.proxyCachedFBO[L.key]!==void 0){const z=h[L.key],H=this.proxyToSource[L.key];let q=0;for(const ee in H){const de=H[ee],_e=z[ee];if(!_e||_e.length!==de.length||de.some((be,ve)=>be!==_e[ve]||w[ee]&&w[ee].hasOwnProperty(be.key))){q=-1;break}++q}for(const ee in f.proxyCachedFBO[L.key])f.renderCache[f.proxyCachedFBO[L.key][ee]].dirty=q<0||q!==Object.values(z).length}}const S=[...this._drapedRenderBatches];S.sort((I,L)=>L.end-L.start-(I.end-I.start));for(const I of S)for(const L of v){if(f.proxyCachedFBO[L.key])continue;let z=f.renderCachePool.pop();z===void 0&&f.renderCache.length<50&&(z=f.renderCache.length,f.renderCache.push(this._createFBO())),z!==void 0&&(f.proxyCachedFBO[L.key]={},f.proxyCachedFBO[L.key][I.start]=z,f.renderCache[z].dirty=!0)}this._tilesDirty={}}_setupStencil(h,f,v,w){if(!w||!this._sourceTilesOverlap[w.id])return void(this._overlapStencilType&&(this._overlapStencilType=!1));const S=this.painter.context,I=S.gl;if(f.length<=1)return void(this._overlapStencilType=!1);let L;if(v.isTileClipped())L=f.length,this._overlapStencilMode.test={func:I.EQUAL,mask:255},this._overlapStencilType="Clip";else{if(!(f[0].overscaledZ>
vendor: 5,130 bytes, line 1402
1402f[f.length-1].overscaledZ))return void(this._overlapStencilType=!1);L=1,this._overlapStencilMode.test={func:I.GREATER,mask:255},this._overlapStencilType="Mask"}this._stencilRef+L>255&&(S.clear({stencil:0}),this._stencilRef=0),this._stencilRef+=L,this._overlapStencilMode.ref=this._stencilRef,v.isTileClipped()&&this._renderTileClippingMasks(f,this._overlapStencilMode.ref)}clipOrMaskOverlapStencilType(){return this._overlapStencilType==="Clip"||this._overlapStencilType==="Mask"}stencilModeForRTTOverlap(h){return this.renderingToTexture&&this._overlapStencilType?(this._overlapStencilType==="Clip"&&(this._overlapStencilMode.ref=this.painter._tileClippingMaskIDs[h.key]),this._overlapStencilMode):a.StencilMode.disabled}_renderTileClippingMasks(h,f){const v=this.painter,w=this.painter.context,S=w.gl;v._tileClippingMaskIDs={},w.setColorMode(a.ColorMode.disabled),w.setDepthMode(a.DepthMode.disabled);const I=v.useProgram("clippingMask");for(const L of h){const z=v._tileClippingMaskIDs[L.key]=--f;I.draw(w,S.TRIANGLES,a.DepthMode.disabled,new a.StencilMode({func:S.ALWAYS,mask:0},z,255,S.KEEP,S.KEEP,S.REPLACE),a.ColorMode.disabled,a.CullFaceMode.disabled,Su(L.projMatrix),"$clipping",v.tileExtentBuffer,v.quadTriangleIndexBuffer,v.tileExtentSegments)}}pointCoordinate(h){const f=this.painter.transform;if(h.x<0||h.x>f.width||h.y<0||h.y>f.height)return null;const v=[h.x,h.y,1,1];a.transformMat4$1(v,v,f.pixelMatrixInverse),a.scale$1(v,v,1/v[3]),v[0]/=f.worldSize,v[1]/=f.worldSize;const w=f._camera.position,S=a.mercatorZfromAltitude(1,f.center.lat),I=[w[0],w[1],w[2]/S,0],L=a.subtract([],v.slice(0,3),I);a.normalize(L,L);const z=this.raycast(I,L,this._exaggeration);return z!==null&&z?(a.scaleAndAdd(I,I,L,z),I[3]=I[2],I[2]*=S,I):null}drawDepth(){const h=this.painter,f=h.context,v=this.proxySourceCache,w=Math.ceil(h.width),S=Math.ceil(h.height);if(!this._depthFBO||this._depthFBO.width===w&&this._depthFBO.height===S||(this._depthFBO.destroy(),this._depthFBO=void 0,this._depthTexture=void 0),!this._depthFBO){const I=f.gl,L=f.createFramebuffer(w,S,!0);f.activeTexture.set(I.TEXTURE0);const z=new a.Texture(f,{width:w,height:S,data:null},I.RGBA);z.bind(I.NEAREST,I.CLAMP_TO_EDGE),L.colorAttachment.set(z.texture);const H=f.createRenderbuffer(f.gl.DEPTH_COMPONENT16,w,S);L.depthAttachment.set(H),this._depthFBO=L,this._depthTexture=z}f.bindFramebuffer.set(this._depthFBO.framebuffer),f.viewport.set([0,0,w,S]),function(I,L,z,H){if(I.transform.projection.name==="globe")return;const q=I.context,ee=q.gl;q.clear({depth:1});const de=I.useProgram("terrainDepth"),_e=new a.DepthMode(ee.LESS,a.DepthMode.ReadWrite,I.depthRangeFor3D);for(const be of H){const ve=z.getTile(be),Ee=Tl(be.projMatrix,0);L.setupElevationDraw(ve,de),de.draw(q,ee.TRIANGLES,_e,a.StencilMode.disabled,a.ColorMode.unblended,a.CullFaceMode.backCCW,Ee,"terrain_depth",L.gridBuffer,L.gridIndexBuffer,L.gridNoSkirtSegments)}}(h,this,v,this.proxyCoords)}_setupProxiedCoordsForOrtho(h,f,v){if(h.getSource()instanceof jn)return this._setupProxiedCoordsForImageSource(h,f,v);this._findCoveringTileCache[h.id]=this._findCoveringTileCache[h.id]||{};const w=this.proxiedCoords[h.id]=[],S=this.proxyCoords;for(let L=0;L<S.length;L++){const z=S[L],H=this._findTileCoveringTileID(z,h);if(H){const q=this._createProxiedId(z,H,v[z.key]&&v[z.key][h.id]);w.push(q),this.proxyToSource[z.key][h.id]=[q]}}let I=!1;for(let L=0;L<f.length;L++){const z=h.getTile(f[L]);if(!z||!z.hasData())continue;const H=this._findTileCoveringTileID(z.tileID,this.proxySourceCache);if(H&&H.tileID.canonical.z!==z.tileID.canonical.z){const q=this.proxyToSource[H.tileID.key][h.id],ee=this._createProxiedId(H.tileID,z,v[H.tileID.key]&&v[H.tileID.key][h.id]);q?q.splice(q.length-1,0,ee):this.proxyToSource[H.tileID.key][h.id]=[ee],w.push(ee),I=!0}}this._sourceTilesOverlap[h.id]=I}_setupProxiedCoordsForImageSource(h,f,v){if(!h.getSource().loaded())return;const w=this.proxiedCoords[h.id]=[],S=this.proxyCoords,I=h.getSource(),L=new a.Point(I.tileID.x,I.tileID.y)._div(1<<I.tileID.z),z=I.coordinates.map(a.MercatorCoordinate.fromLngLat).reduce((q,ee)=>(q.min.x=Math.min(q.min.x,ee.x-L.x),q.min.y=Math.min(q.min.y,ee.y-L.y),q.max.x=Math.max(q.max.x,ee.x-L.x),q.max.y=Math.max(q.max.y,ee.y-L.y),q),{min:new a.Point(Number.MAX_VALUE,Number.MAX_VALUE),max:new a.Point(-Number.MAX_VALUE,-Number.MAX_VALUE)}),H=(q,ee)=>{const de=q.wrap+q.canonical.x/(1<<q.canonical.z),_e=q.canonical.y/(1<<q.canonical.z),be=a.EXTENT/(1<<q.canonical.z),ve=ee.wrap+ee.canonical.x/(1<<ee.canonical.z),Ee=ee.canonical.y/(1<<ee.canonical.z);return de+be<ve+z.min.x||de>ve+z.max.x||_e+be<Ee+z.min.y||_e>Ee+z.max.y};for(let q=0;q<S.length;q++){const ee=S[q];for(let de=0;de<f.length;de++){const _e=h.getTile(f[de]);if(!_e||!_e.hasData()||H(ee,_e.tileID))continue;const be=this._createProxiedId(ee,_e,v[ee.key]&&v[ee.key][h.id]),ve=this.proxyToSource[ee.key][h.id];ve?ve.push(be):this.proxyToSource[ee.key][h.id]=[be],w.push(be)}}}_createProxiedId(h,f,v){let w=this.orthoMatrix;if(v){const S=v.find(I=>I.key===f.tileID.key);if(S)return S}if(f.tileID.key!==h.key){const S=h.canonical.z-f.tileID.canonical.z;let I,L,z;w=a.create();
1402const H=f.tileID.wrap-h.wrap<<h.overscaledZ;S>0?(I=a.EXTENT>>S,L=I*((f.tileID.canonical.x<<S)-h.canonical.x+H),z=I*((f.tileID.canonical.y<<S)-h.canonical.y)):(I=a.EXTENT<<-S,L=a.EXTENT*(f.tileID.canonical.x-(h.canonical.x+H<<-S)),z=a.EXTENT*(f.tileID.canonical.y-(h.canonical.y<<-S))),a.ortho(w,0,I,0,I,0,1),a.translate(w,w,[L,z,0])}return new Cu(f.tileID,h.key,w)}_findTileCoveringTileID(h,f){let v=f.getTile(h);if(v&&v.hasData())return v;const w=this._findCoveringTileCache[f.id],S=w[h.key];if(v=S?f.getTileByID(S):null,v&&v.hasData()||S===null)return v;let I=v?v.tileID:h,L=I.overscaledZ;const z=f.getSource().minzoom,H=[];if(!S){const ee=f.getSource().maxzoom;if(h.canonical.z>=ee){const de=h.canonical.z-ee;f.getSource().reparseOverscaled?(L=Math.max(h.canonical.z+2,f.transform.tileZoom),I=new a.OverscaledTileID(L,h.wrap,ee,h.canonical.x>>de,h.canonical.y>>de)):de!==0&&(L=ee,I=new a.OverscaledTileID(L,h.wrap,ee,h.canonical.x>>de,h.canonical.y>>de))}I.key!==h.key&&(H.push(I.key),v=f.getTile(I))}const q=ee=>{H.forEach(de=>{w[de]=ee}),H.length=0};for(L-=1;L>=z&&(!v||!v.hasData());L--){v&&q(v.tileID.key);const ee=I.calculateScaledKey(L);if(v=f.getTileByID(ee),v&&v.hasData())break;const de=w[ee];if(de===null)break;de===void 0?H.push(ee):v=f.getTileByID(de)}return q(v?v.tileID.key:null),v&&v.hasData()?v:null}findDEMTileFor(h){return this.enabled?this._findTileCoveringTileID(h,this.sourceCache):null}prepareDrawTile(){this.renderedToTile=!0}_clearRenderCacheForTile(h,f){let v=this._tilesDirty[h];v||(v=this._tilesDirty[h]={}),v[f.key]=!0}getWirefameBuffer(){if(!this.wireframeSegments){const h=function(f){let v=0;const w=new a.StructArrayLayout2ui4,S=131;for(let I=1;I<129;I++){for(let L=1;L<129;L++)v=I*S+L,w.emplaceBack(v,v+1),w.emplaceBack(v,v+S),w.emplaceBack(v+1,v+S),I===128&&w.emplaceBack(v+S,v+S+1);w.emplaceBack(v+1,v+1+S)}return w}();this.wireframeIndexBuffer=this.painter.context.createIndexBuffer(h),this.wireframeSegments=a.SegmentVector.simpleSegment(0,0,this.gridBuffer.length,h.length)}return[this.wireframeIndexBuffer,this.wireframeSegments]}}class ur{static cacheKey(h,f,v,w){let S=`${f}${w?w.cacheKey:""}`;for(const I of v)h.usedDefines.includes(I)&&(S+=`/${I}`);return S}constructor(h,f,v,w,S,I){const L=h.gl;this.program=L.createProgram();const z=function(te){const ye=[];for(let Oe=0;Oe<te.length;Oe++){if(te[Oe]===null)continue;const Le=te[Oe].split(" ");ye.push(Le.pop())}return ye}(v.staticAttributes),H=w?w.getBinderAttributes():[],q=z.concat(H);let ee=w?w.defines():[];ee=ee.concat(I.map(te=>`#define ${te}`));const de=h.isWebGL2?`#version 300 es
1403`:"",_e=de+ee.concat(h.extStandardDerivatives&&de.length===0?`#extension GL_OES_standard_derivatives : enable
1404`.concat(Zd):Zd,Zd,Eu,Yd.fragmentSource,tc.fragmentSource,v.fragmentSource).join(`
1405`),be=de+ee.concat(`
1406#ifdef GL_ES
1407precision highp float;
1408#else
1409
1410#if !defined(lowp)
1411#define lowp
1412#endif
1413
1414#if !defined(mediump)
1415#define mediump
1416#endif
1417
1418#if !defined(highp)
1419#define highp
1420#endif
1421
1422#endif`,Eu,Yd.vertexSource,tc.vertexSource,Bc.vertexSource,v.vertexSource).join(`
1423`),ve=L.createShader(L.FRAGMENT_SHADER);if(L.isContextLost())return void(this.failedToCreate=!0);L.shaderSource(ve,_e),L.compileShader(ve),L.attachShader(this.program,ve);const Ee=L.createShader(L.VERTEX_SHADER);if(L.isContextLost())this.failedToCreate=!0;else{L.shaderSource(Ee,be),L.compileShader(Ee),L.attachShader(this.program,Ee),this.attributes={},this.numAttributes=q.length;for(let te=0;te<this.numAttributes;te++)q[te]&&(L.bindAttribLocation(this.program,te,q[te]),this.attributes[q[te]]=te);L.linkProgram(this.program),L.deleteShader(Ee),L.deleteShader(ve),this.fixedUniforms=S(h),this.binderUniforms=w?w.getUniforms(h):[],I.includes("TERRAIN")&&(this.terrainUniforms=(te=>({u_dem:new a.Uniform1i(te),u_dem_prev:new a.Uniform1i(te),u_dem_unpack:new a.Uniform4f(te),u_dem_tl:new a.Uniform2f(te),u_dem_scale:new a.Uniform1f(te),u_dem_tl_prev:new a.Uniform2f(te),u_dem_scale_prev:new a.Uniform1f(te),u_dem_size:new a.Uniform1f(te),u_dem_lerp:new a.Uniform1f(te),u_exaggeration:new a.Uniform1f(te),u_depth:new a.Uniform1i(te),u_depth_size_inv:new a.Uniform2f(te),u_meter_to_dem:new a.Uniform1f(te),u_label_plane_matrix_inv:new a.UniformMatrix4f(te)}))(h)),I.includes("GLOBE")&&(this.globeUniforms=(te=>({u_tile_tl_up:new a.Uniform3f(te),u_tile_tr_up:new a.Uniform3f(te),u_tile_br_up:new a.Uniform3f(te),u_tile_bl_up:new a.Uniform3f(te),u_tile_up_scale:new a.Uniform1f(te)}))(h)),I.includes("FOG")&&(this.fogUniforms=(te=>({u_fog_matrix:new a.UniformMatrix4f(te),u_fog_range:new a.Uniform2f(te),u_fog_color:new a.Uniform4f(te),u_fog_horizon_blend:new a.Uniform1f(te),u_fog_temporal_offset:new a.Uniform1f(te),u_frustum_tl:new a.Uniform3f(te),u_frustum_tr:new a.Uniform3f(te),u_frustum_br:new a.Uniform3f(te),u_frustum_bl:new a.Uniform3f(te),u_globe_pos:new a.Uniform3f(te),u_globe_radius:new a.Uniform1f(te),u_globe_transition:new a.Uniform1f(te),u_is_globe:new a.Uniform1i(te),u_viewport:new a.Uniform2f(te)}))(h))}}setTerrainUniformValues(h,f){if(!this.terrainUniforms)return;const v=this.terrainUniforms;if(!this.failedToCreate){h.program.set(this.program);for(const w in f)v[w]&&v[w].set(this.program,w,f[w])}}setGlobeUniformValues(h,f){if(!this.globeUniforms)return;const v=this.globeUniforms;if(!this.failedToCreate){h.program.set(this.program);for(const w in f)v[w]&&v[w].set(this.program,w,f[w])}}setFogUniformValues(h,f){if(!this.fogUniforms)return;const v=this.fogUniforms;if(!this.failedToCreate){h.program.set(this.program);for(const w in f)v[w].set(this.program,w,f[w])}}draw(h,f,v,w,S,I,L,z,H,q,ee,de,_e,be,ve){const Ee=h.gl;if(this.failedToCreate)return;h.program.set(this.program),h.setDepthMode(v),h.setStencilMode(w),h.setColorMode(S),h.setCullFace(I);for(const ye of Object.keys(this.fixedUniforms))this.fixedUniforms[ye].set(this.program,ye,L[ye]);be&&be.setUniforms(this.program,h,this.binderUniforms,de,{zoom:_e});const te={[Ee.LINES]:2,[Ee.TRIANGLES]:3,[Ee.LINE_STRIP]:1}[f];for(const ye of ee.get()){const Oe=ye.vaos||(ye.vaos={});(Oe[z]||(Oe[z]=new Ap)).bind(h,this,H,be?be.getPaintVertexBuffers():[],q,ye.vertexOffset,ve||[]),Ee.drawElements(f,ye.primitiveLength*te,Ee.
1423UNSIGNED_SHORT,ye.primitiveOffset*te*2)}}}function Pa(y,h){const f=Math.pow(2,h.tileID.overscaledZ),v=h.tileSize*Math.pow(2,y.transform.tileZoom)/f,w=v*(h.tileID.canonical.x+h.tileID.wrap*f),S=v*h.tileID.canonical.y;return{u_image:0,u_texsize:h.imageAtlasTexture.size,u_tile_units_to_pixels:1/Ne(h,1,y.transform.tileZoom),u_pixel_coord_upper:[w>>16,S>>16],u_pixel_coord_lower:[65535&w,65535&S]}}const kl=a.create(),zc=(y,h,f,v,w,S,I,L,z,H,q)=>{const ee=h.style.light,de=ee.properties.get("position"),_e=[de.x,de.y,de.z],be=a.create$1();ee.properties.get("anchor")==="viewport"&&(a.fromRotation(be,-h.transform.angle),a.transformMat3(_e,_e,be));const ve=ee.properties.get("color"),Ee=h.transform,te={u_matrix:y,u_lightpos:_e,u_lightintensity:ee.properties.get("intensity"),u_lightcolor:[ve.r,ve.g,ve.b],u_vertical_gradient:+f,u_opacity:v,u_tile_id:[0,0,0],u_zoom_transition:0,u_inv_rot_matrix:kl,u_merc_center:[0,0],u_up_dir:[0,0,0],u_height_lift:0,u_ao:w,u_edge_radius:S};return Ee.projection.name==="globe"&&(te.u_tile_id=[I.canonical.x,I.canonical.y,1<<I.canonical.z],te.u_zoom_transition=z,te.u_inv_rot_matrix=q,te.u_merc_center=H,te.u_up_dir=Ee.projection.upVector(new a.CanonicalTileID(0,0,0),H[0]*a.EXTENT,H[1]*a.EXTENT),te.u_height_lift=L),te},Xs=(y,h,f,v,w,S,I,L,z,H,q,ee)=>{const de=zc(y,h,f,v,w,S,I,z,H,q,ee),_e={u_height_factor:-Math.pow(2,I.overscaledZ)/L.tileSize/8};return a.extend(de,Pa(h,L),_e)},nc=y=>({u_matrix:y}),Nc=(y,h,f)=>a.extend(nc(y),Pa(h,f)),Au=(y,h)=>({u_matrix:y,u_world:h}),Ip=(y,h,f,v)=>a.extend(Nc(y,h,f),{u_world:v}),Op=a.create(),ef=(y,h,f,v,w,S)=>{const I=y.transform,L=I.projection.name==="globe";let z;if(S.paint.get("circle-pitch-alignment")==="map")if(L){const q=a.globePixelsToTileUnits(I.zoom,h.canonical)*I._pixelsPerMercatorPixel;z=Float32Array.from([q,0,0,q])}else z=I.calculatePixelsToTileUnitsMatrix(f);else z=new Float32Array([I.pixelsToGLUnits[0],0,0,I.pixelsToGLUnits[1]]);const H={u_camera_to_center_distance:I.cameraToCenterDistance,u_matrix:y.translatePosMatrix(h.projMatrix,f,S.paint.get("circle-translate"),S.paint.get("circle-translate-anchor")),u_device_pixel_ratio:a.exported.devicePixelRatio,u_extrude_scale:z,u_inv_rot_matrix:Op,u_merc_center:[0,0],u_tile_id:[0,0,0],u_zoom_transition:0,u_up_dir:[0,0,0]};if(L){H.u_inv_rot_matrix=v,H.u_merc_center=w,H.u_tile_id=[h.canonical.x,h.canonical.y,1<<h.canonical.z],H.u_zoom_transition=a.globeToMercatorTransition(I.zoom);const q=w[0]*a.EXTENT,ee=w[1]*a.EXTENT;H.u_up_dir=I.projection.upVector(new a.CanonicalTileID(0,0,0),q,ee)}return H},tf=y=>{const h=[];return y.paint.get("circle-pitch-alignment")==="map"&&h.push("PITCH_WITH_MAP"),y.paint.get("circle-pitch-scale")==="map"&&h.push("SCALE_WITH_MAP"),h},vh=(y,h,f,v)=>{const w=a.EXTENT/f.tileSize;return{u_matrix:y,u_camera_to_center_distance:h.getCameraToCenterDistance(v),u_extrude_scale:[h.pixelsToGLUnits[0]/w,h.pixelsToGLUnits[1]/w]}},Pu=(y,h,f=1)=>({u_matrix:y,u_color:h,u_overlay:0,u_overlay_scale:f}),Mu=a.create(),rc=(y,h,f,v,w,S,I)=>{const L=y.transform,z=L.projection.name==="globe",H=z?a.globePixelsToTileUnits(L.zoom,h.canonical)*L._pixelsPerMercatorPixel:Ne(f,1,S),q={u_matrix:h.projMatrix,u_extrude_scale:H,u_intensity:I,u_inv_rot_matrix:Mu,u_merc_center:[0,0],u_tile_id:[0,0,0],u_zoom_transition:0,u_up_dir:[0,0,0]};if(z){q.u_inv_rot_matrix=v,q.u_merc_center=w,q.u_tile_id=[h.canonical.x,h.canonical.y,1<<h.canonical.z],q.u_zoom_transition=a.globeToMercatorTransition(L.zoom);const ee=w[0]*a.EXTENT,de=w[1]*a.EXTENT;q.u_up_dir=L.projection.upVector(new a.CanonicalTileID(0,0,0),ee,de)}return q},Dg=(y,h,f,v,w,S,I)=>{const L=y.transform,z=L.calculatePixelsToTileUnitsMatrix(h);return{u_matrix:Ks(y,h,f,v),u_pixels_to_tile_units:z,u_device_pixel_ratio:S,u_units_to_pixels:[1/L.pixelsToGLUnits[0],1/L.pixelsToGLUnits[1]],u_dash_image:0,u_gradient_image:1,u_image_height:w,u_texsize:jc(f)?h.lineAtlasTexture.size:[0,0],u_tile_units_to_pixels:$c(h,y.transform),u_alpha_discard_threshold:0,u_trim_offset:I}},Ua=(y,h,f,v,w)=>{const S=y.transform;return{u_matrix:Ks(y,h,f,v),u_texsize:h.imageAtlasTexture.size,u_pixels_to_tile_units:S.calculatePixelsToTileUnitsMatrix(h),u_device_pixel_ratio:w,u_image:0,u_tile_units_to_pixels:$c(h,S),u_units_to_pixels:[1/S.pixelsToGLUnits[0],1/S.pixelsToGLUnits[1]],u_alph
1423a_discard_threshold:0}};function $c(y,h){return 1/Ne(y,1,h.tileZoom)}function Ks(y,h,f,v){return y.translatePosMatrix(v||h.tileID.projMatrix,h,f.paint.get("line-translate"),f.paint.get("line-translate-anchor"))}function jc(y){const h=y.paint.get("line-dasharray").value;return h.value||h.kind!=="constant"}const nf=(y,h,f,v,w,S)=>{return{u_matrix:y,u_tl_parent:h,u_scale_parent:f,u_fade_t:v.mix,u_opacity:v.opacity*w.paint.get("raster-opacity"),u_image0:0,u_image1:1,u_brightness_low:w.paint.get("raster-brightness-min"),u_brightness_high:w.paint.get("raster-brightness-max"),u_saturation_factor:(L=w.paint.get("raster-saturation"),L>0?1-1/(1.001-L):-L),u_contrast_factor:(I=w.paint.get("raster-contrast"),I>0?1/(1-I):1+I),u_spin_weights:Ma(w.paint.get("raster-hue-rotate")),u_perspective_transform:S};var I,L};function Ma(y){y*=Math.PI/180;const h=Math.sin(y),f=Math.cos(y);return[(2*f+1)/3,(-Math.sqrt(3)*h-f+1)/3,(Math.sqrt(3)*h-f+1)/3]}const Uc=a.create(),bh=(y,h,f,v,w,S,I,L,z,H,q,ee,de,_e,be,ve)=>{const Ee=w.transform,te={u_is_size_zoom_constant:+(y==="constant"||y==="source"),u_is_size_feature_constant:+(y==="constant"||y==="camera"),u_size_t:h?h.uSizeT:0,u_size:h?h.uSize:0,u_camera_to_center_distance:Ee.cameraToCenterDistance,u_rotate_symbol:+f,u_aspect_ratio:Ee.width/Ee.height,u_fade_change:w.options.fadeDuration?w.symbolFadeChange:1,u_matrix:S,u_label_plane_matrix:I,u_coord_matrix:L,u_is_text:+z,u_pitch_with_map:+v,u_texsize:H,u_texture:0,u_tile_id:[0,0,0],u_zoom_transition:0,u_inv_rot_matrix:Uc,u_merc_center:[0,0],u_camera_forward:[0,0,0],u_ecef_origin:[0,0,0],u_tile_matrix:Uc,u_up_vector:[0,-1,0]};return ve.name==="globe"&&(te.u_tile_id=[q.canonical.x,q.canonical.y,1<<q.canonical.z],te.u_zoom_transition=ee,te.u_inv_rot_matrix=_e,te.u_merc_center=de,te.u_camera_forward=Ee._camera.forward(),te.u_ecef_origin=a.globeECEFOrigin(Ee.globeMatrix,q.toUnwrapped()),te.u_tile_matrix=Float32Array.from(Ee.globeMatrix),te.u_up_vector=be),te},Iu=(y,h,f,v,w,S,I,L,z,H,q,ee,de,_e,be,ve,Ee)=>a.extend(bh(y,h,f,v,w,S,I,L,z,H,ee,de,_e,be,ve,Ee),{u_gamma_scale:v?w.transform.cameraToCenterDistance*Math.cos(w.terrain?0:w.transform._pitch):1,u_device_pixel_ratio:a.exported.devicePixelRatio,u_is_halo:+q}),rf=(y,h,f,v,w,S,I,L,z,H,q,ee,de,_e,be,ve)=>a.extend(Iu(y,h,f,v,w,S,I,L,!0,z,!0,q,ee,de,_e,be,ve),{u_texsize_icon:H,u_texture_icon:1}),ic=(y,h,f)=>({u_matrix:y,u_opacity:h,u_color:f}),Dp=(y,h,f,v,w)=>a.extend(function(S,I,L){const z=I.imageManager.getPattern(S.toString()),{width:H,height:q}=I.imageManager.getPixelSize(),ee=Math.pow(2,L.tileID.overscaledZ),de=L.tileSize*Math.pow(2,I.transform.tileZoom)/ee,_e=de*(L.tileID.canonical.x+L.tileID.wrap*ee),be=de*L.tileID.canonical.y;return{u_image:0,u_pattern_tl:z.tl,u_pattern_br:z.br,u_texsize:[H,q],u_pattern_size:z.displaySize,u_tile_units_to_pixels:1/Ne(L,1,I.transform.tileZoom),u_pixel_coord_upper:[_e>>16,be>>16],u_pixel_coord_lower:[65535&_e,65535&be]}}(v,f,w),{u_matrix:y,u_opacity:h}),of={fillExtrusion:y=>({u_matrix:new a.UniformMatrix4f(y),u_lightpos:new a.Uniform3f(y),u_lightintensity:new a.Uniform1f(y),u_lightcolor:new a.Uniform3f(y),u_vertical_gradient:new a.Uniform1f(y),u_opacity:new a.Uniform1f(y),u_edge_radius:new a.Uniform1f(y),u_ao:new a.Uniform2f(y),u_tile_id:new a.Uniform3f(y),u_zoom_transition:new a.Uniform1f(y),u_inv_rot_matrix:new a.UniformMatrix4f(y),u_merc_center:new a.Uniform2f(y),u_up_dir:new a.Uniform3f(y),u_height_lift:new a.Uniform1f(y)}),fillExtrusionPattern:y=>({u_matrix:new a.UniformMatrix4f(y),u_lightpos:new a.Uniform3f(y),u_lightintensity:new a.Uniform1f(y),u_lightcolor:new a.Uniform3f(y),u_vertical_gradient:new a.Uniform1f(y),u_height_factor:new a.Uniform1f(y),u_edge_radius:new a.Uniform1f(y),u_ao:new a.Uniform2f(y),u_tile_id:new a.Uniform3f(y),u_zoom_transition:new a.Uniform1f(y),u_inv_rot_matrix:new a.UniformMatrix4f(y),u_merc_center:new a.Uniform2f(y),u_up_dir:new a.Uniform3f(y),u_height_lift:new a.Uniform1f(y),u_image:new a.Uniform1i(y),u_texsize:new a.Uniform2f(y),u_pixel_coord_upper:new a.Uniform2f(y),u_pixel_coord_lower:new a.Uniform2f(y),u_tile_units_to_pixels:new a.Uniform1f(y),u_opacity:new a.Uniform1f(y)}),fill:y=>({u_matrix:new a.UniformMatrix4f(y)}),fillPattern:y=>({u_matrix:new a.UniformMatrix4f(y),u_image:new a.Uniform1i(y),u_texsize:new a.Uniform2f(y),u_pixel_coord_upper:new a.Uniform2f(y),u_pixel_coord_lower:new a.Uniform2f(y),u_tile_units_to_pixels:new a.Uniform1f(y)}),fillOutline:y=>({u_matrix:new a.UniformMatrix4f(y),u_world:new a.Uniform2f(y)}),fillOutlinePattern:y=>({u_matrix:new a.UniformMatrix4f(y),u_world:new a.Uniform2f(y),u_image:new a.Uniform1i(y),u_texsize:new a.Uniform2f(y),u_pixel_coord_upper:new a.Uniform2f(y),u_pixel_coord_lower:new a.Uniform2f(y),u_tile_units_to_pixels:new a.Uniform1f(y)}),circle:y=>({u_camera_to_center_distance:new a.Uniform1f(y),u_extrude_scale:new a.UniformMatrix2f(y),u_device_pixel_ratio:new a.Uniform1f(y),u_matrix:new a.UniformMatrix4f(y),u_inv_rot_matrix:new a.UniformMatrix4f(y),u_merc_center:new a.Uniform2f(y),u_tile_id:new a.Uniform3f(y),u_zoom_transition:new a.Uniform1f(y),u_up_dir:new a.Uniform3f(y)}),collisionBox:y=>({u_matrix:new a.UniformMatrix4f(y),u_camera_to_center_distance:new a.Uniform1f(y),u_extrude_scale:new a.Uniform2f(y)}),collisionCircle:y=>({u_matrix:new a.UniformMatrix4f(y),u_inv_matrix:new a.UniformMatrix4f(y),u_camera_to_center_distance:new a.Uniform1f(y),u_viewport_size:new a.Uniform2f(y)}),debug:y=>({u_color:new a.UniformColor(y),u_matrix:new a.UniformMatrix4f(y),u_overlay:new a.Uniform1i(y),u_overlay_scale:new a.Uniform1f(y)}),clippingMask:y=>({u_matrix:new a.UniformMatrix4f(y)}),heatmap:y=>({u_extrude_scale:new a.Uniform1f(y),u_intensity:new a.Uniform1f(y),u_matrix:new a.UniformMatrix4f(y),u_inv_rot_matrix:new a.UniformMatrix4f(y),u_merc_center:new a.Uniform2f(y),u_tile_id:new a.Uniform3f(y),u_zoom_transition:new a.Uniform1f(y),u_up_dir:new a.Uniform3f(y)}),heatmapTexture:y=>({u_image:new a.Uniform1i(y),u_color_ramp:new a.Uniform1i(y),u_opacity:new a.Uniform1f(y)}),hillshade:y=>({u_matrix:new a.UniformMatrix4f(y),u_image:new a.Uniform1i(y),u_latrange:new a.Uniform2f(y),u_light:new a.Uniform2f(y),u_shadow:new a.UniformColor(y),u_highlight:new a.UniformColor(y),u_accent:new a.UniformColor(y)}),hillshadePrepare:y=>({u_matrix:new a.UniformMatrix4f(y),u_image:new a.Uniform1i(y),u_dimension:new a.Uniform2f(y),u_zoom:new a.Uniform1f(y),u_unpack:new a.Uniform4f(y)}),line:y=>({u_matrix:new a.UniformMatrix4f(y),u_pixels_to_tile_units:new a.UniformMatrix2f(y),u_device_pixel_ratio:new a.Uniform1f(y),u_units_to_pixels:new a.Uniform2f(y),u_dash_image:new a.Uniform1i(y),u_gradient_image:new a.Uniform1i(y),u_image_height:new a.Uniform1f(y),u_texsize:new a.Uniform2f(y),u_tile_units_to_pixels:new a.Uniform1f(y),u_alph
1423a_discard_threshold:new a.Uniform1f(y),u_trim_offset:new a.Uniform2f(y)}),linePattern:y=>({u_matrix:new a.UniformMatrix4f(y),u_texsize:new a.Uniform2f(y),u_pixels_to_tile_units:new a.UniformMatrix2f(y),u_device_pixel_ratio:new a.Uniform1f(y),u_image:new a.Uniform1i(y),u_units_to_pixels:new a.Uniform2f(y),u_tile_units_to_pixels:new a.Uniform1f(y),u_alpha_discard_threshold:new a.Uniform1f(y)}),raster:y=>({u_matrix:new a.UniformMatrix4f(y),u_tl_parent:new a.Uniform2f(y),u_scale_parent:new a.Uniform1f(y),u_fade_t:new a.Uniform1f(y),u_opacity:new a.Uniform1f(y),u_image0:new a.Uniform1i(y),u_image1:new a.Uniform1i(y),u_brightness_low:new a.Uniform1f(y),u_brightness_high:new a.Uniform1f(y),u_saturation_factor:new a.Uniform1f(y),u_contrast_factor:new a.Uniform1f(y),u_spin_weights:new a.Uniform3f(y),u_perspective_transform:new a.Uniform2f(y)}),symbolIcon:y=>({u_is_size_zoom_constant:new a.Uniform1i(y),u_is_size_feature_constant:new a.Uniform1i(y),u_size_t:new a.Uniform1f(y),u_size:new a.Uniform1f(y),u_camera_to_center_distance:new a.Uniform1f(y),u_rotate_symbol:new a.Uniform1i(y),u_aspect_ratio:new a.Uniform1f(y),u_fade_change:new a.Uniform1f(y),u_matrix:new a.UniformMatrix4f(y),u_label_plane_matrix:new a.UniformMatrix4f(y),u_coord_matrix:new a.UniformMatrix4f(y),u_is_text:new a.Uniform1i(y),u_pitch_with_map:new a.Uniform1i(y),u_texsize:new a.Uniform2f(y),u_tile_id:new a.Uniform3f(y),u_zoom_transition:new a.Uniform1f(y),u_inv_rot_matrix:new a.UniformMatrix4f(y),u_merc_center:new a.Uniform2f(y),u_camera_forward:new a.Uniform3f(y),u_tile_matrix:new a.UniformMatrix4f(y),u_up_vector:new a.Uniform3f(y),u_ecef_origin:new a.Uniform3f(y),u_texture:new a.Uniform1i(y)}),symbolSDF:y=>({u_is_size_zoom_constant:new a.Uniform1i(y),u_is_size_feature_constant:new a.Uniform1i(y),u_size_t:new a.Uniform1f(y),u_size:new a.Uniform1f(y),u_camera_to_center_distance:new a.Uniform1f(y),u_rotate_symbol:new a.Uniform1i(y),u_aspect_ratio:new a.Uniform1f(y),u_fade_change:new a.Uniform1f(y),u_matrix:new a.UniformMatrix4f(y),u_label_plane_matrix:new a.UniformMatrix4f(y),u_coord_matrix:new a.UniformMatrix4f(y),u_is_text:new a.Uniform1i(y),u_pitch_with_map:new a.Uniform1i(y),u_texsize:new a.Uniform2f(y),u_texture:new a.Uniform1i(y),u_gamma_scale:new a.Uniform1f(y),u_device_pixel_ratio:new a.Uniform1f(y),u_tile_id:new a.Uniform3f(y),u_zoom_transition:new a.Uniform1f(y),u_inv_rot_matrix:new a.UniformMatrix4f(y),u_merc_center:new a.Uniform2f(y),u_camera_forward:new a.Uniform3f(y),u_tile_matrix:new a.UniformMatrix4f(y),u_up_vector:new a.Uniform3f(y),u_ecef_origin:new a.Uniform3f(y),u_is_halo:new a.Uniform1i(y)}),symbolTextAndIcon:y=>({u_is_size_zoom_constant:new a.Uniform1i(y),u_is_size_feature_constant:new a.Uniform1i(y),u_size_t:new a.Uniform1f(y),u_size:new a.Uniform1f(y),u_camera_to_center_distance:new a.Uniform1f(y),u_rotate_symbol:new a.Uniform1i(y),u_aspect_ratio:new a.Uniform1f(y),u_fade_change:new a.Uniform1f(y),u_matrix:new a.UniformMatrix4f(y),u_label_plane_matrix:new a.UniformMatrix4f(y),u_coord_matrix:new a.UniformMatrix4f(y),u_is_text:new a.Uniform1i(y),u_pitch_with_map:new a.Uniform1i(y),u_texsize:new a.Uniform2f(y),u_texsize_icon:new a.Uniform2f(y),u_texture:new a.Uniform1i(y),u_texture_icon:new a.Uniform1i(y),u_gamma_scale:new a.Uniform1f(y),u_device_pixel_ratio:new a.Uniform1f(y),u_is_halo:new a.Uniform1i(y)}),background:y=>({u_matrix:new a.UniformMatrix4f(y),u_opacity:new a.Uniform1f(y),u_color:new a.UniformColor(y)}),backgroundPattern:y=>({u_matrix:new a.UniformMatrix4f(y),u_opacity:new a.Uniform1f(y),u_image:new a.Uniform1i(y),u_pattern_tl:new a.Uniform2f(y),u_pattern_br:new a.Uniform2f(y),u_texsize:new a.Uniform2f(y),u_pattern_size:new a.Uniform2f(y),u_pixel_coord_upper:new a.Uniform2f(y),u_pixel_coord_lower:new a.Uniform2f(y),u_tile_units_to_pixels:new a.Uniform1f(y)}),terrainRaster:Kd,terrainDepth:Kd,skybox:y=>({u_matrix:new a.UniformMatrix4f(y),u_sun_direction:new a.Uniform3f(y),u_cubemap:new a.Uniform1i(y),u_opacity:new a.Uniform1f(y),u_temporal_offset:new a.Uniform1f(y)}),skyboxGradient:y=>({u_matrix:new a.UniformMatrix4f(y),u_color_ramp:new a.Uniform1i(y),u_center_direction:new a.Uniform3f(y),u_radius:new a.Uniform1f(y),u_opacity:new a.Uniform1f(y),u_temporal_offset:new a.Uniform1f(y)}),skyboxCapture:y=>({u_matrix_3f:new a.UniformMatrix3f(y),u_sun_direction:new a.Uniform3f(y),u_sun_intensity:new a.Uniform1f(y),u_color_tint_r:new a.Uniform4f(y),u_color_tint_m:new a.Uniform4f(y),u_luminance:new a.Uniform1f(y)}),globeRaster:y=>({u_proj_matrix:new a.UniformMatrix4f(y),u_globe_matrix:new a.UniformMatrix4f(y),u_normalize_matrix:new a.UniformMatrix4f(y),u_merc_matrix:new a.UniformMatrix4f(y),u_zoom_transition:new a.Uniform1f(y),u_merc_center:new a.Uniform2f(y),u_image0:new a.Uniform1i(y),u_grid_matrix:new a.UniformMatrix3f(y),u_skirt_height:new a.Uniform1f(y),u_frustum_tl:new a.Uniform3f(y),u_frustum_tr:new a.Uniform3f(y),u_frustum_br:new a.Uniform3f(y),u_frustum_bl:new a.Uniform3f(y),u_globe_pos:new a.Uniform3f(y),u_globe_radius:new a.Uniform1f(y),u_viewport:new a.Uniform2f(y)}),globeAtmosphere:y=>({u_frustum_tl:new a.Uniform3f(y),u_frustum_tr:new a.Uniform3f(y),u_frustum_br:new a.Uniform3f(y),u_frustum_bl:new a.Uniform3f(y),u_horizon:new a.Uniform1f(y),u_transition:new a.Uniform1f(y),u_fadeout_range:new a.Uniform1f(y),u_color:new a.Uniform4f(y),u_high_color:new a.Uniform4f(y),u_space_color:new a.Uniform4f(y),u_star_intensity:new a.Uniform1f(y),u_star_density:new a.Uniform1f(y),u_star_size:new a.Uniform1f(y),u_temporal_offset:new a.Uniform1f(y),u_horizon_angle:new a.Uniform1f(y),u_rotation_matrix:new a.UniformMatrix4f(y)})};let at;
1423function Ot(y,h,f,v,w,S,I){const L=y.context,z=L.gl,H=y.transform,q=y.useProgram("collisionBox"),ee=[];let de=0,_e=0;for(let Le=0;Le<v.length;Le++){const He=v[Le],Ze=h.getTile(He),Ye=Ze.getBucket(f);if(!Ye)continue;const ot=Re(He,Ye,H);let et=ot;w[0]===0&&w[1]===0||(et=y.translatePosMatrix(ot,Ze,w,S));const _t=I?Ye.textCollisionBox:Ye.iconCollisionBox,Zt=Ye.collisionCircleArray;if(Zt.length>0){const dt=a.create(),Bt=et;a.mul(dt,Ye.placementInvProjMatrix,H.glCoordMatrix),a.mul(dt,dt,Ye.placementViewportMatrix),ee.push({circleArray:Zt,circleOffset:_e,transform:Bt,invTransform:dt,projection:Ye.getProjection()}),de+=Zt.length/4,_e=de}_t&&(y.terrain&&y.terrain.setupElevationDraw(Ze,q),q.draw(L,z.LINES,a.DepthMode.disabled,a.StencilMode.disabled,y.colorModeForRenderPass(),a.CullFaceMode.disabled,vh(et,H,Ze,Ye.getProjection()),f.id,_t.layoutVertexBuffer,_t.indexBuffer,_t.segments,null,H.zoom,null,[_t.collisionVertexBuffer,_t.collisionVertexBufferExt]))}if(!I||!ee.length)return;const be=y.useProgram("collisionCircle"),ve=new a.StructArrayLayout2f1f2i16;ve.resize(4*de),ve._trim();let Ee=0;for(const Le of ee)for(let He=0;He<Le.circleArray.length/4;He++){const Ze=4*He,Ye=Le.circleArray[Ze+0],ot=Le.circleArray[Ze+1],et=Le.circleArray[Ze+2],_t=Le.circleArray[Ze+3];ve.emplace(Ee++,Ye,ot,et,_t,0),ve.emplace(Ee++,Ye,ot,et,_t,1),ve.emplace(Ee++,Ye,ot,et,_t,2),ve.emplace(Ee++,Ye,ot,et,_t,3)}(!at||at.length<2*de)&&(at=function(Le){const He=2*Le,Ze=new a.StructArrayLayout3ui6;Ze.resize(He),Ze._trim();for(let Ye=0;Ye<He;Ye++){const ot=6*Ye;Ze.uint16[ot+0]=4*Ye+0,Ze.uint16[ot+1]=4*Ye+1,Ze.uint16[ot+2]=4*Ye+2,Ze.uint16[ot+3]=4*Ye+2,Ze.uint16[ot+4]=4*Ye+3,Ze.uint16[ot+5]=4*Ye+0}return Ze}(de));const te=L.createIndexBuffer(at,!0),ye=L.createVertexBuffer(ve,a.collisionCircleLayout.members,!0);for(const Le of ee){const He={u_matrix:Le.transform,u_inv_matrix:Le.invTransform,u_camera_to_center_distance:(Oe=H).getCameraToCenterDistance(Le.projection),u_viewport_size:[Oe.width,Oe.height]};be.draw(L,z.TRIANGLES,a.DepthMode.disabled,a.StencilMode.disabled,y.colorModeForRenderPass(),a.CullFaceMode.disabled,He,f.id,ye,te,a.SegmentVector.simpleSegment(0,2*Le.circleOffset,Le.circleArray.length,Le.circleArray.length/2),null,H.zoom)}var Oe;ye.destroy(),te.destroy()}const yn=a.create();function Fn({width:y,height:h,anchor:f,textOffset:v,textScale:w},S){const{horizontalAlign:I,verticalAlign:L}=a.getAnchorAlignment(f),z=-(I-.5)*y,H=-(L-.5)*h,q=a.evaluateVariableOffset(f,v);return new a.Point((z/w+q[0])*S,(H/w+q[1])*S)}function wi(y,h,f,v,w,S,I,L,z,H,q){const ee=y.text.placedSymbolArray,de=y.text.dynamicLayoutVertexArray,_e=y.icon.dynamicLayoutVertexArray,be={},ve=y.getProjection(),Ee=Ve(L,ve,S),te=S.elevation,ye=ve.upVectorScale(L.canonical,S.center.lat,S.worldSize).metersToTile;de.clear();for(let Oe=0;Oe<ee.length;Oe++){const Le=ee.get(Oe),{tileAnchorX:He,tileAnchorY:Ze,numGlyphs:Ye}=Le,ot=Le.hidden||!Le.crossTileID||y.allowVerticalPlacement&&!Le.placedOrientation?null:v[Le.crossTileID];if(ot){let et=0,_t=0,Zt=0;if(te){const tn=te?te.getAtTileOffset(L,He,Ze):0,[Mn,Wn,wn]=ve.upVector(L.canonical,He,Ze);et=tn*Mn*ye,_t=tn*Wn*ye,Zt=tn*wn*ye}let[dt,Bt,St,Yt]=mo(Le.projectedAnchorX+et,Le.projectedAnchorY+_t,Le.projectedAnchorZ+Zt,f?Ee:I);const gt=kp(S.getCameraToCenterDistance(ve),Yt);let Ft=w.evaluateSizeForFeature(y.textSizeData,H,Le)*gt/a.ONE_EM;f&&(Ft*=y.tilePixelRatio/z);const Jt=Fn(ot,Ft);f?({x:dt,y:Bt,z:St}=ve.projectTilePoint(He+Jt.x,Ze+Jt.y,L.canonical),[dt,Bt,St]=mo(dt+et,Bt+_t,St+Zt,I)):(h&&Jt._rotate(-S.angle),dt+=Jt.x,Bt+=Jt.y,St=0);const Ut=y.allowVerticalPlacement&&Le.placedOrientation===a.WritingMode.vertical?Math.PI/2:0;for(let tn=0;tn<Ye;tn++)a.addDynamicAttributes(de,dt,Bt,St,Ut);q&&Le.associatedIconIndex>=0&&(be[Le.associatedIconIndex]={x:dt,y:Bt,z:St,angle:Ut})}else os(Ye,de)}if(q){_e.clear();const Oe=y.icon.placedSymbolArray;for(let Le=0;Le<Oe.length;Le++){const He=Oe.get(Le),{numGlyphs:Ze}=He,Ye=be[Le];if(He.hidden||!Ye)os(Ze,_e);else{const{x:ot,y:et,z:_t,angle:Zt}=Ye;for(let dt=0;dt<Ze;dt++)a.addDynamicAttributes(_e,ot,et,_t,Zt)}}y.icon.dynamicLayoutVertexBuffer.updateData(_e)}y.text.dynamicLayoutVertexBuffer.updateData(de)}function xr(y,h,f){return f.iconsInText&&h?"symbolTextAndIcon":y?"symbolSDF":"symbolIcon"}function ji(y,h,f,v,w,S,I,L,z,H,q,ee){const de=y.context,_e=de.gl,be=y.transform,ve=L==="map",Ee=z==="map",te=ve&&f.layout.get("symbol-placement")!=="point",ye=ve&&!Ee&&!te,Oe=f.layout.get("symbol-sort-key").constantOr(1)!==void 0;let Le=!1;const He=y.depthModeForSublayer(0,a.DepthMode.ReadOnly),Ze=[a.mercatorXfromLng(be.center.lng),a.mercatorYfromLat(be.center.lat)],Ye=f.layout.get("text-variable-anchor"),ot=be.projection.name==="globe",et=[],_t=[0,-1,0];let Zt=_t;!ot&&!be.mercatorFromTransition||ve||(Zt=function(dt){const Bt=dt._camera.getWorldToCamera(dt.worldSize,1),St=a.multiply([],Bt,dt.globeMatrix);a.invert(St,St);const Yt=[0,0,0],gt=[0,1,0,0];return a.transformMat4$1(gt,gt,St),Yt[0]=gt[0],Yt[1]=gt[1],Yt[2]=gt[2],a.normalize(Yt,Yt),Yt}(be));for(const dt of v){const Bt=h.getTile(dt),St=Bt.getBucket(f);if(!St||St.projection.name==="mercator"&&ot)continue;
1423const Yt=w?St.text:St.icon;if(!Yt||St.fullyClipped||!Yt.segments.get().length)continue;const gt=Yt.programConfigurations.get(f.id),Ft=w||St.sdfIcons,Jt=w?St.textSizeData:St.iconSizeData,Ut=Ee||be.pitch!==0,tn=a.evaluateSizeForZoom(Jt,be.zoom);let Mn,Wn,wn,Bn,mr=[0,0],pr=null;if(w)Wn=Bt.glyphAtlasTexture,wn=_e.LINEAR,Mn=Bt.glyphAtlasTexture.size,St.iconsInText&&(mr=Bt.imageAtlasTexture.size,pr=Bt.imageAtlasTexture,Bn=Ut||y.options.rotating||y.options.zooming||Jt.kind==="composite"||Jt.kind==="camera"?_e.LINEAR:_e.NEAREST);else{const cc=f.layout.get("icon-size").constantOr(0)!==1||St.iconsNeedLinear;Wn=Bt.imageAtlasTexture,wn=Ft||y.options.rotating||y.options.zooming||cc||Ut?_e.LINEAR:_e.NEAREST,Mn=Bt.imageAtlasTexture.size}const Cn=St.projection.name==="globe",Nr=Cn?Zt:_t,Qr=Cn?a.globeToMercatorTransition(be.zoom):0,Jr=Ve(dt,St.getProjection(),be),ei=be.calculatePixelsToTileUnitsMatrix(Bt),ya=Pt(Jr,Bt.tileID.canonical,Ee,ve,be,St.getProjection(),ei),Yo=y.terrain&&Ee&&te?a.invert(a.create(),ya):yn,Cs=ci(Jr,Bt.tileID.canonical,Ee,ve,be,St.getProjection(),ei),Ol=Ye&&St.hasTextData(),Mi=f.layout.get("icon-text-fit")!=="none"&&Ol&&St.hasIconData();if(te){const cc=be.elevation,qc=cc?cc.getAtTileOffsetFunc(dt,be.center.lat,be.worldSize,St.getProjection()):null,Fu=ta(Jr,Bt.tileID.canonical,Ee,ve,be,St.getProjection(),ei);Gd(St,Jr,y,w,Fu,Cs,Ee,H,qc,dt)}const ti=te||w&&Ye||Mi,Mr=y.translatePosMatrix(Jr,Bt,S,I),go=ti?yn:ya,Ia=y.translatePosMatrix(Cs,Bt,S,I,!0),Ti=St.getProjection().createInversionMatrix(be,dt.canonical),Wa=[];y.terrainRenderModeElevated()&&Ee&&Wa.push("PITCH_WITH_MAP_TERRAIN"),Cn&&Wa.push("PROJECTION_GLOBE_VIEW"),ti&&Wa.push("PROJECTED_POS_ON_VIEWPORT");const Vp=Ft&&f.paint.get(w?"text-halo-width":"icon-halo-width").constantOr(1)!==0;let Ru;Ru=Ft?St.iconsInText?rf(Jt.kind,tn,ye,Ee,y,Mr,go,Ia,Mn,mr,dt,Qr,Ze,Ti,Nr,St.getProjection()):Iu(Jt.kind,tn,ye,Ee,y,Mr,go,Ia,w,Mn,!0,dt,Qr,Ze,Ti,Nr,St.getProjection()):bh(Jt.kind,tn,ye,Ee,y,Mr,go,Ia,w,Mn,dt,Qr,Ze,Ti,Nr,St.getProjection());const pf={program:y.useProgram(xr(Ft,w,St),gt,Wa),buffers:Yt,uniformValues:Ru,atlasTexture:Wn,atlasTextureIcon:pr,atlasInterpolation:wn,atlasInterpolationIcon:Bn,isSDF:Ft,hasHalo:Vp,tile:Bt,labelPlaneMatrixInv:Yo};if(Oe&&St.canOverlap){Le=!0;const cc=Yt.segments.get();for(const qc of cc)et.push({segments:new a.SegmentVector([qc]),sortKey:qc.sortKey,state:pf})}else et.push({segments:Yt.segments,sortKey:0,state:pf})}Le&&et.sort((dt,Bt)=>dt.sortKey-Bt.sortKey);for(const dt of et){const Bt=dt.state;if(y.terrain&&y.terrain.setupElevationDraw(Bt.tile,Bt.program,{useDepthForOcclusion:!ot,labelPlaneMatrixInv:Bt.labelPlaneMatrixInv}),de.activeTexture.set(_e.TEXTURE0),Bt.atlasTexture.bind(Bt.atlasInterpolation,_e.CLAMP_TO_EDGE),Bt.atlasTextureIcon&&(de.activeTexture.set(_e.TEXTURE1),Bt.atlasTextureIcon&&Bt.atlasTextureIcon.bind(Bt.atlasInterpolationIcon,_e.CLAMP_TO_EDGE)),Bt.isSDF){const St=Bt.uniformValues;Bt.hasHalo&&(St.u_is_halo=1,Pi(Bt.buffers,dt.segments,f,y,Bt.program,He,q,ee,St)),St.u_is_halo=0}Pi(Bt.buffers,dt.segments,f,y,Bt.program,He,q,ee,Bt.uniformValues)}}function Pi(y,h,f,v,w,S,I,L,z){const H=v.context,q=[y.dynamicLayoutVertexBuffer,y.opacityVertexBuffer,y.globeExtVertexBuffer];w.draw(H,H.gl.TRIANGLES,S,I,L,a.CullFaceMode.disabled,z,f.id,y.layoutVertexBuffer,y.indexBuffer,h,f.paint,v.transform.zoom,y.programConfigurations.get(f.id),q)}function Va(y,h,f,v,w,S,I){const L=y.context.gl,z=f.paint.get("fill-pattern"),H=z&&z.constantOr(1);let q,ee,de,_e,be;I?(ee=H&&!f.getPaintProperty("fill-outline-color")?"fillOutlinePattern":"fillOutline",q=L.LINES):(ee=H?"fillPattern":"fill",q=L.TRIANGLES);for(const ve of v){const Ee=h.getTile(ve);if(H&&!Ee.patternsLoaded())continue;const te=Ee.getBucket(f);if(!te)continue;y.prepareDrawTile();const ye=te.programConfigurations.get(f.id),Oe=y.useProgram(ee,ye);H&&(y.context.activeTexture.set(L.TEXTURE0),Ee.imageAtlasTexture.bind(L.LINEAR,L.CLAMP_TO_EDGE),ye.updatePaintBuffers());const Le=z.constantOr(null);if(Le&&Ee.imageAtlas){const Ze=Ee.imageAtlas.patternPositions[Le.toString()];Ze&&ye.setConstantPatternPositions(Ze)}const He=y.translatePosMatrix(ve.projMatrix,Ee,f.paint.get("fill-translate"),f.paint.get("fill-translate-anchor"));if(I){_e=te.indexBuffer2,be=te.segments2;const Ze=y.terrain&&y.terrain.renderingToTexture?y.terrain.drapeBufferSize:[L.drawingBufferWidth,L.drawingBufferHeight];
1423de=ee==="fillOutlinePattern"&&H?Ip(He,y,Ee,Ze):Au(He,Ze)}else _e=te.indexBuffer,be=te.segments,de=H?Nc(He,y,Ee):nc(He);y.prepareDrawProgram(y.context,Oe,ve.toUnwrapped()),Oe.draw(y.context,q,w,y.stencilModeForClipping(ve),S,a.CullFaceMode.disabled,de,f.id,te.layoutVertexBuffer,_e,be,f.paint,y.transform.zoom,ye)}}function Hi(y,h,f,v,w,S,I){const L=y.context,z=L.gl,H=y.transform,q=f.paint.get("fill-extrusion-pattern"),ee=q.constantOr(1),de=f.paint.get("fill-extrusion-opacity"),_e=[f.paint.get("fill-extrusion-ambient-occlusion-intensity"),f.paint.get("fill-extrusion-ambient-occlusion-radius")],be=f.layout.get("fill-extrusion-edge-radius"),ve=be>0&&!f.paint.get("fill-extrusion-rounded-roof"),Ee=ve?0:be,te=H.projection.name==="globe"?a.fillExtrusionHeightLift():0,ye=H.projection.name==="globe",Oe=ye?a.globeToMercatorTransition(H.zoom):0,Le=[a.mercatorXfromLng(H.center.lng),a.mercatorYfromLat(H.center.lat)],He=[];ye&&He.push("PROJECTION_GLOBE_VIEW"),_e[0]>0&&He.push("FAUX_AO"),ve&&He.push("ZERO_ROOF_RADIUS");for(const Ze of v){const Ye=h.getTile(Ze),ot=Ye.getBucket(f);if(!ot||ot.projection.name!==H.projection.name)continue;const et=ot.programConfigurations.get(f.id),_t=y.useProgram(ee?"fillExtrusionPattern":"fillExtrusion",et,He);if(y.terrain){const Ft=y.terrain;if(y.style.terrainSetForDrapingOnly())Ft.setupElevationDraw(Ye,_t,{useMeterToDem:!0});else{if(!ot.enableTerrain)continue;if(Ft.setupElevationDraw(Ye,_t,{useMeterToDem:!0}),lo(L,h,Ze,ot,f,Ft),!ot.centroidVertexBuffer){const Jt=_t.attributes.a_centroid_pos;Jt!==void 0&&z.vertexAttrib2f(Jt,0,0)}}}ee&&(y.context.activeTexture.set(z.TEXTURE0),Ye.imageAtlasTexture.bind(z.LINEAR,z.CLAMP_TO_EDGE),et.updatePaintBuffers());const Zt=q.constantOr(null);if(Zt&&Ye.imageAtlas){const Ft=Ye.imageAtlas.patternPositions[Zt.toString()];Ft&&et.setConstantPatternPositions(Ft)}const dt=y.translatePosMatrix(Ze.projMatrix,Ye,f.paint.get("fill-extrusion-translate"),f.paint.get("fill-extrusion-translate-anchor")),Bt=H.projection.createInversionMatrix(H,Ze.canonical),St=f.paint.get("fill-extrusion-vertical-gradient"),Yt=ee?Xs(dt,y,St,de,_e,Ee,Ze,Ye,te,Oe,Le,Bt):zc(dt,y,St,de,_e,Ee,Ze,te,Oe,Le,Bt);y.prepareDrawProgram(L,_t,Ze.toUnwrapped());const gt=[];y.terrain&&gt.push(ot.centroidVertexBuffer),ye&&gt.push(ot.layoutVertexExtBuffer),_t.draw(L,L.gl.TRIANGLES,w,S,I,a.CullFaceMode.backCCW,Yt,f.id,ot.layoutVertexBuffer,ot.indexBuffer,ot.segments,f.paint,y.transform.zoom,et,gt)}}function lo(y,h,f,v,w,S){const I=[te=>{let ye=te.canonical.x-1,Oe=te.wrap;return ye<0&&(ye=(1<<te.canonical.z)-1,Oe--),new a.OverscaledTileID(te.overscaledZ,Oe,te.canonical.z,ye,te.canonical.y)},te=>{let ye=te.canonical.x+1,Oe=te.wrap;return ye===1<<te.canonical.z&&(ye=0,Oe++),new a.OverscaledTileID(te.overscaledZ,Oe,te.canonical.z,ye,te.canonical.y)},te=>new a.OverscaledTileID(te.overscaledZ,te.wrap,te.canonical.z,te.canonical.x,(te.canonical.y===0?1<<te.canonical.z:te.canonical.y)-1),te=>new a.OverscaledTileID(te.overscaledZ,te.wrap,te.canonical.z,te.canonical.x,te.canonical.y===(1<<te.canonical.z)-1?0:te.canonical.y+1)],L=te=>{const ye=h.getSource().minzoom,Oe=He=>{const Ze=h.getTileByID(He);if(Ze&&Ze.hasData())return Ze.getBucket(w)},Le=[0,-1,1];for(const He of Le){if(te.overscaledZ+He<ye)continue;const Ze=Oe(te.calculateScaledKey(te.overscaledZ+He));if(Ze)return Ze}},z=[0,0,0],H=(te,ye)=>(z[0]=Math.min(te.min.y,ye.min.y),z[1]=Math.max(te.max.y,ye.max.y),z[2]=a.EXTENT-ye.min.x>te.max.x?ye.min.x-a.EXTENT:te.max.x,z),q=(te,ye)=>(z[0]=Math.min(te.min.x,ye.min.x),z[1]=Math.max(te.max.x,ye.max.x),z[2]=a.EXTENT-ye.min.y>te.max.y?ye.min.y-a.EXTENT:te.max.y,z),ee=[(te,ye)=>H(te,ye),(te,ye)=>H(ye,te),(te,ye)=>q(te,ye),(te,ye)=>q(ye,te)],de=new a.Point(0,0);let _e,be,ve;const Ee=(te,ye,Oe,Le,He)=>{const Ze=[[Le?Oe:te,Le?te:Oe,0],[Le?Oe:ye,Le?ye:Oe,0]],Ye=He<0?a.EXTENT+He:He,ot=[Le?Ye:(te+ye)/2,Le?(te+ye)/2:Ye,0];return Oe===0&&He<0||Oe!==0&&He>0?S.getForTilePoints(ve,[ot],!0,be):Ze.push(ot),S.getForTilePoints(f,Ze,!0,_e),Math.max(Ze[0][2],Ze[1][2],ot[2])/S.exaggeration()};for(let te=0;te<4;te++){const ye=(te<2?1:5)-te,Oe=v.borders[te];if(Oe.length===0)continue;const Le=ve=I[te](f),He=L(Le);if(!(He&&He instanceof a.FillExtrusionBucket&&He.enableTerrain)||v.borderDoneWithNeighborZ[te]===He.canonical.z&&He.borderDoneWithNeighborZ[ye]===v.canonical.z||(be=S.findDEMTileFor(Le),!be||!be.dem))continue;if(!_e){const et=S.findDEMTileFor(f);if(!et||!et.dem)return;_e=et}const Ze=He.borders[ye];let Ye=0;const ot=He.borderDoneWithNeighborZ[ye]!==v.canonical.z;if(v.canonical.z===He.canonical.z){for(let et=0;et<Oe.length;et++){const _t=v.featuresOnBorder[Oe[et]],Zt=_t.borders[te];let dt;
1423for(;Ye<Ze.length&&(dt=He.featuresOnBorder[Ze[Ye]],!(dt.borders[ye][1]>Zt[0]+3));)ot&&He.encodeCentroid(void 0,dt,!1),Ye++;if(dt&&Ye<Ze.length){const Bt=Ye;let St=0;for(;!(dt.borders[ye][0]>Zt[1]-3)&&(St++,++Ye!==Ze.length);)dt=He.featuresOnBorder[Ze[Ye]];if(dt=He.featuresOnBorder[Ze[Bt]],_t.intersectsCount()>1||dt.intersectsCount()>1||St!==1){St!==1&&(Ye=Bt),v.encodeCentroid(void 0,_t,!1),ot&&He.encodeCentroid(void 0,dt,!1);continue}const Yt=ee[te](_t,dt),gt=te%2?a.EXTENT-1:0;de.x=Ee(Yt[0],Math.min(a.EXTENT-1,Yt[1]),gt,te<2,Yt[2]),de.y=0,v.encodeCentroid(de,_t,!1),ot&&He.encodeCentroid(de,dt,!1)}else v.encodeCentroid(void 0,_t,!1)}v.borderDoneWithNeighborZ[te]=He.canonical.z,v.needsCentroidUpdate=!0,ot&&(He.borderDoneWithNeighborZ[ye]=v.canonical.z,He.needsCentroidUpdate=!0)}else{for(const et of Oe)v.encodeCentroid(void 0,v.featuresOnBorder[et],!1);if(ot){for(const et of Ze)He.encodeCentroid(void 0,He.featuresOnBorder[et],!1);He.borderDoneWithNeighborZ[ye]=v.canonical.z,He.needsCentroidUpdate=!0}v.borderDoneWithNeighborZ[te]=He.canonical.z,v.needsCentroidUpdate=!0}}(v.needsCentroidUpdate||!v.centroidVertexBuffer&&v.centroidVertexArray.length!==0)&&v.uploadCentroid(y)}const ra=new a.Color(1,0,0,1),Qs=new a.Color(0,1,0,1),ia=new a.Color(0,0,1,1),Js=new a.Color(1,0,1,1),Vc=new a.Color(0,1,1,1);function xh(y,h,f){const v=y.context,w=y.transform,S=v.gl,I=w.projection.name==="globe",L=I?["PROJECTION_GLOBE_VIEW"]:null;let z=f.projMatrix;if(I&&a.globeToMercatorTransition(w.zoom)>0){const _t=a.transitionTileAABBinECEF(f.canonical,w),Zt=a.globeDenormalizeECEF(_t);z=a.multiply(new Float32Array(16),w.globeMatrix,Zt),a.multiply(z,w.projMatrix,z)}const H=y.useProgram("debug",null,L),q=h.getTileByID(f.key);y.terrain&&y.terrain.setupElevationDraw(q,H);const ee=a.DepthMode.disabled,de=a.StencilMode.disabled,_e=y.colorModeForRenderPass(),be="$debug";v.activeTexture.set(S.TEXTURE0),y.emptyTexture.bind(S.LINEAR,S.CLAMP_TO_EDGE),I?q._makeGlobeTileDebugBuffers(y.context,w):q._makeDebugTileBoundsBuffers(y.context,w.projection);const ve=q._tileDebugBuffer||y.debugBuffer,Ee=q._tileDebugIndexBuffer||y.debugIndexBuffer,te=q._tileDebugSegments||y.debugSegments;H.draw(v,S.LINE_STRIP,ee,de,_e,a.CullFaceMode.disabled,Pu(z,a.Color.red),be,ve,Ee,te,null,null,null,[q._globeTileDebugBorderBuffer]);const ye=q.latestRawTileData,Oe=Math.floor((ye&&ye.byteLength||0)/1024),Le=h.getTile(f).tileSize,He=512/Math.min(Le,512)*(f.overscaledZ/w.zoom)*.5;let Ze=f.canonical.toString();f.overscaledZ!==f.canonical.z&&(Ze+=` => ${f.overscaledZ}`),Ze+=` ${Oe}kb`,function(_t,Zt){_t.initDebugOverlayCanvas();const dt=_t.debugOverlayCanvas,Bt=_t.context.gl,St=_t.debugOverlayCanvas.getContext("2d");St.clearRect(0,0,dt.width,dt.height),St.shadowColor="white",St.shadowBlur=2,St.lineWidth=1.5,St.strokeStyle="white",St.textBaseline="top",St.font="bold 36px Open Sans, sans-serif",St.fillText(Zt,5,5),St.strokeText(Zt,5,5),_t.debugOverlayTexture.update(dt),_t.debugOverlayTexture.bind(Bt.LINEAR,Bt.CLAMP_TO_EDGE)}(y,Ze);const Ye=q._tileDebugTextBuffer||y.debugBuffer,ot=q._tileDebugTextIndexBuffer||y.quadTriangleIndexBuffer,et=q._tileDebugTextSegments||y.debugSegments;H.draw(v,S.TRIANGLES,ee,de,a.ColorMode.alphaBlended,a.CullFaceMode.disabled,Pu(z,a.Color.transparent,He),be,Ye,ot,et,null,null,null,[q._globeTileDebugTextBuffer])}function oc(y,h,f,v){ac(y,0,h+f/2,y.transform.width,f,v)}function Al(y,h,f,v){ac(y,h-f/2,0,f,y.transform.height,v)}function ac(y,h,f,v,w,S){const I=y.context,L=I.gl;L.enable(L.SCISSOR_TEST),L.scissor(h*a.exported.devicePixelRatio,f*a.exported.devicePixelRatio,v*a.exported.devicePixelRatio,w*a.exported.devicePixelRatio),I.clear({color:S}),L.disable(L.SCISSOR_TEST)}const Lp=a.createLayout([{name:"a_pos_3f",components:3,type:"Float32"}]),{members:Rp}=Lp;function Cr(y,h,f,v){y.emplaceBack(h,f,v)}class Lr{constructor(h){this.vertexArray=new a.StructArrayLayout3f12,this.indices=new a.StructArrayLayout3ui6,Cr(this.vertexArray,-1,-1,1),Cr(this.vertexArray,1,-1,1),Cr(this.vertexArray,-1,1,1),Cr(this.vertexArray,1,1,1),Cr(this.vertexArray,-1,-1,-1),Cr(this.vertexArray,1,-1,-1),Cr(this.vertexArray,-1,1,-1),Cr(this.vertexArray,1,1,-1),this.indices.emplaceBack(5,1,3),this.indices.emplaceBack(3,7,5),this.indices.emplaceBack(6,2,0),this.indices.emplaceBack(0,4,6),this.indices.emplaceBack(2,6,7),this.indices.emplaceBack(7,3,2),this.indices.emplaceBack(5,4,0),this.indices.emplaceBack(0,1,5),this.indices.emplaceBack(0,2,3),this.indices.emplaceBack(3,1,0),this.indices.emplaceBack(7,6,4),this.indices.emplaceBack(4,5,7),this.vertexBuffer=h.createVertexBuffer(this.vertexArray,Rp),this.indexBuffer=h.createIndexBuffer(this.indices),this.segment=a.SegmentVector.simpleSegment(0,0,36,12)}}function oa(y,h,f,v,w,S){const I=y.gl,L=h.paint.get("sky-atmosphere-color"),z=h.paint.get("sky-atmosphere-halo-color"),H=h.paint.get("sky-atmosphere-sun-intensity"),q=((ee,de,_e,be,ve)=>({u_matrix_3f:ee,u_sun_direction:de,u_sun_intensity:_e,u_color_tint_r:[be.r,be.g,be.b,be.a],u_color_tint_m:[ve.r,ve.g,ve.b,ve.a],u_luminance:5e-5}))(a.fromMat4(a.create$1(),v),w,H,L,z);I.framebufferTexture2D(I.FRAMEBUFFER,I.COLOR_ATTACHMENT0,I.TEXTURE_CUBE_MAP_POSITIVE_X+S,h.skyboxTexture,0),f.draw(y,I.TRIANGLES,a.DepthMode.disabled,a.StencilMode.disabled,a.ColorMode.unblended,a.CullFaceMode.frontCW,q,"skyboxCapture",h.skyboxGeometry.vertexBuffer,h.skyboxGeometry.indexBuffer,h.skyboxGeometry.segment)}const Ga=a.createLayout([{type:"Float32",name:"a_pos",components:3},{type:"Float32",name:"a_uv",components:2}]);class wh{constructor(h){const f=new a.StructArrayLayout5f20;f.emplaceBack(-1,1,1,0,0),f.emplaceBack(1,1,1,1,0),f.emplaceBack(1,-1,1,1,1),f.emplaceBack(-1,-1,1,0,1);const v=new a.StructArrayLayout3ui6;v.emplaceBack(0,1,2),v.emplaceBack(2,3,0),this.vertexBuffer=h.createVertexBuffer(f,Ga.members),this.indexBuffer=h.createIndexBuffer(v),this.segments=a.SegmentVector.simpleSegment(0,0,4,2)}destroy(){this.vertexBuffer.destroy(),this.indexBuffer.destroy(),this.segments.destroy()}}
1423const Io={symbol:function(y,h,f,v,w){if(y.renderPass!=="translucent")return;const S=a.StencilMode.disabled,I=y.colorModeForRenderPass();f.layout.get("text-variable-anchor")&&function(L,z,H,q,ee,de,_e){const be=z.transform,ve=ee==="map",Ee=de==="map";for(const te of L){const ye=q.getTile(te),Oe=ye.getBucket(H);if(!Oe||!Oe.text||!Oe.text.segments.get().length)continue;const Le=a.evaluateSizeForZoom(Oe.textSizeData,be.zoom),He=Ve(te,Oe.getProjection(),be),Ze=be.calculatePixelsToTileUnitsMatrix(ye),Ye=Pt(He,ye.tileID.canonical,Ee,ve,be,Oe.getProjection(),Ze),ot=H.layout.get("icon-text-fit")!=="none"&&Oe.hasIconData();if(Le){const et=Math.pow(2,be.zoom-ye.tileID.overscaledZ);wi(Oe,ve,Ee,_e,a.symbolSize,be,Ye,te,et,Le,ot)}}}(v,y,f,h,f.layout.get("text-rotation-alignment"),f.layout.get("text-pitch-alignment"),w),f.paint.get("icon-opacity").constantOr(1)!==0&&ji(y,h,f,v,!1,f.paint.get("icon-translate"),f.paint.get("icon-translate-anchor"),f.layout.get("icon-rotation-alignment"),f.layout.get("icon-pitch-alignment"),f.layout.get("icon-keep-upright"),S,I),f.paint.get("text-opacity").constantOr(1)!==0&&ji(y,h,f,v,!0,f.paint.get("text-translate"),f.paint.get("text-translate-anchor"),f.layout.get("text-rotation-alignment"),f.layout.get("text-pitch-alignment"),f.layout.get("text-keep-upright"),S,I),h.map.showCollisionBoxes&&(Ot(y,h,f,v,f.paint.get("text-translate"),f.paint.get("text-translate-anchor"),!0),Ot(y,h,f,v,f.paint.get("icon-translate"),f.paint.get("icon-translate-anchor"),!1))},circle:function(y,h,f,v){if(y.renderPass!=="translucent")return;const w=f.paint.get("circle-opacity"),S=f.paint.get("circle-stroke-width"),I=f.paint.get("circle-stroke-opacity"),L=f.layout.get("circle-sort-key").constantOr(1)!==void 0;if(w.constantOr(1)===0&&(S.constantOr(1)===0||I.constantOr(1)===0))return;const z=y.context,H=z.gl,q=y.transform,ee=y.depthModeForSublayer(0,a.DepthMode.ReadOnly),de=a.StencilMode.disabled,_e=y.colorModeForRenderPass(),be=q.projection.name==="globe",ve=[a.mercatorXfromLng(q.center.lng),a.mercatorYfromLat(q.center.lat)],Ee=[];for(let ye=0;ye<v.length;ye++){const Oe=v[ye],Le=h.getTile(Oe),He=Le.getBucket(f);if(!He||He.projection.name!==q.projection.name)continue;const Ze=He.programConfigurations.get(f.id),Ye=tf(f);be&&Ye.push("PROJECTION_GLOBE_VIEW");const ot=y.useProgram("circle",Ze,Ye),et=He.layoutVertexBuffer,_t=He.globeExtVertexBuffer,Zt=He.indexBuffer,dt=q.projection.createInversionMatrix(q,Oe.canonical),Bt={programConfiguration:Ze,program:ot,layoutVertexBuffer:et,globeExtVertexBuffer:_t,indexBuffer:Zt,uniformValues:ef(y,Oe,Le,dt,ve,f),tile:Le};if(L){const St=He.segments.get();for(const Yt of St)Ee.push({segments:new a.SegmentVector([Yt]),sortKey:Yt.sortKey,state:Bt})}else Ee.push({segments:He.segments,sortKey:0,state:Bt})}L&&Ee.sort((ye,Oe)=>ye.sortKey-Oe.sortKey);const te={useDepthForOcclusion:!be};for(const ye of Ee){const{programConfiguration:Oe,program:Le,layoutVertexBuffer:He,globeExtVertexBuffer:Ze,indexBuffer:Ye,uniformValues:ot,tile:et}=ye.state,_t=ye.segments;y.terrain&&y.terrain.setupElevationDraw(et,Le,te),y.prepareDrawProgram(z,Le,et.tileID.toUnwrapped()),Le.draw(z,H.TRIANGLES,ee,de,_e,a.CullFaceMode.disabled,ot,f.id,He,Ye,_t,f.paint,q.zoom,Oe,[Ze])}},heatmap:function(y,h,f,v){if(f.paint.get("heatmap-opacity")!==0)if(y.renderPass==="offscreen"){const w=y.context,S=w.gl,I=a.StencilMode.disabled,L=new a.ColorMode([S.ONE,S.ONE],a.Color.transparent,[!0,!0,!0,!0]);(function(_e,be,ve,Ee){const te=_e.gl,ye=be.width*Ee,Oe=be.height*Ee;_e.activeTexture.set(te.TEXTURE1),_e.viewport.set([0,0,ye,Oe]);let Le=ve.heatmapFbo;if(!Le||Le&&(Le.width!==ye||Le.height!==Oe)){Le&&Le.destroy();const He=te.createTexture();te.bindTexture(te.TEXTURE_2D,He),te.texParameteri(te.TEXTURE_2D,te.TEXTURE_WRAP_S,te.CLAMP_TO_EDGE),te.texParameteri(te.TEXTURE_2D,te.TEXTURE_WRAP_T,te.CLAMP_TO_EDGE),te.texParameteri(te.TEXTURE_2D,te.TEXTURE_MIN_FILTER,te.LINEAR),te.texParameteri(te.TEXTURE_2D,te.TEXTURE_MAG_FILTER,te.LINEAR),Le=ve.heatmapFbo=_e.createFramebuffer(ye,Oe,!1),function(Ze,Ye,ot,et,_t,Zt){const dt=Ze.gl;dt.texImage2D(dt.TEXTURE_2D,0,Ze.isWebGL2&&Ze.extRenderToTextureHalfFloat?dt.RGBA16F:dt.RGBA,_t,Zt,0,dt.RGBA,Ze.extRenderToTextureHalfFloat?Ze.isWebGL2?dt.HALF_FLOAT:Ze.extTextureHalfFloat.HALF_FLOAT_OES:dt.UNSIGNED_BYTE,null),et.colorAttachment.set(ot)}(_e,0,He,Le,ye,Oe)}else te.bindTexture(te.TEXTURE_2D,Le.colorAttachment.get()),_e.bindFramebuffer.set(Le.framebuffer)})(w,y,f,y.transform.projection.name==="globe"?.5:.25),w.clear({color:a.Color.transparent});const z=y.transform,H=z.projection.name==="globe",q=H?["PROJECTION_GLOBE_VIEW"]:null,ee=H?a.CullFaceMode.frontCCW:a.CullFaceMode.disabled,de=[a.mercatorXfromLng(z.center.lng),a.mercatorYfromLat(z.center.lat)];for(let _e=0;_e<v.length;_e++){const be=v[_e];if(h.hasRenderableParent(be))continue;const ve=h.getTile(be),Ee=ve.getBucket(f);if(!Ee||Ee.projection.name!==z.projection.name)continue;const te=Ee.programConfigurations.get(f.id),ye=y.useProgram("heatmap",te,q),{zoom:Oe}=y.transform;y.terrain&&y.terrain.setupElevationDraw(ve,ye),y.prepareDrawProgram(w,ye,be.toUnwrapped());const Le=z.projection.createInversionMatrix(z,be.canonical);ye.draw(w,S.TRIANGLES,a.DepthMode.disabled,I,L,ee,rc(y,be,ve,Le,de,Oe,f.paint.get("heatmap-intensity")),f.id,Ee.layoutVertexBuffer,Ee.indexBuffer,Ee.segments,f.paint,y.transform.zoom,te,H?[Ee.globeExtVertexBuffer]:null)}w.viewport.set([0,0,y.width,y.height])}else y.renderPass==="translucent"&&(y.context.setColorMode(y.colorModeForRenderPass()),function(w,S){const I=w.context,L=I.gl,z=S.heatmapFbo;if(!z)return;I.activeTexture.set(L.TEXTURE0),L.bindTexture(L.TEXTURE_2D,z.colorAttachment.get()),I.activeTexture.set(L.TEXTURE1);let H=S.colorRampTexture;
1423H||(H=S.colorRampTexture=new a.Texture(I,S.colorRamp,L.RGBA)),H.bind(L.LINEAR,L.CLAMP_TO_EDGE),w.useProgram("heatmapTexture").draw(I,L.TRIANGLES,a.DepthMode.disabled,a.StencilMode.disabled,w.colorModeForRenderPass(),a.CullFaceMode.disabled,((q,ee,de,_e)=>({u_image:0,u_color_ramp:1,u_opacity:ee.paint.get("heatmap-opacity")}))(0,S),S.id,w.viewportBuffer,w.quadTriangleIndexBuffer,w.viewportSegments,S.paint,w.transform.zoom)}(y,f))},line:function(y,h,f,v){if(y.renderPass!=="translucent")return;const w=f.paint.get("line-opacity"),S=f.paint.get("line-width");if(w.constantOr(1)===0||S.constantOr(1)===0)return;const I=y.depthModeForSublayer(0,a.DepthMode.ReadOnly),L=y.colorModeForRenderPass(),z=y.terrain&&y.terrain.renderingToTexture?1:a.exported.devicePixelRatio,H=f.paint.get("line-dasharray"),q=H.constantOr(1),ee=f.layout.get("line-cap"),de=f.paint.get("line-pattern"),_e=de.constantOr(1),be=f.paint.get("line-gradient"),ve=_e?"linePattern":"line",Ee=y.context,te=Ee.gl,ye=(Le=>{const He=[];jc(Le)&&He.push("RENDER_LINE_DASH"),Le.paint.get("line-gradient")&&He.push("RENDER_LINE_GRADIENT");const Ze=Le.paint.get("line-trim-offset");Ze[0]===0&&Ze[1]===0||He.push("RENDER_LINE_TRIM_OFFSET");const Ye=Le.paint.get("line-pattern").constantOr(1),ot=Le.paint.get("line-opacity").constantOr(1)!==1;return!Ye&&ot&&He.push("RENDER_LINE_ALPHA_DISCARD"),He})(f);let Oe=ye.includes("RENDER_LINE_ALPHA_DISCARD");y.terrain&&y.terrain.clipOrMaskOverlapStencilType()&&(Oe=!1);for(const Le of v){const He=h.getTile(Le);if(_e&&!He.patternsLoaded())continue;const Ze=He.getBucket(f);if(!Ze)continue;y.prepareDrawTile();const Ye=Ze.programConfigurations.get(f.id),ot=y.useProgram(ve,Ye,ye),et=de.constantOr(null);if(et&&He.imageAtlas){const Ft=He.imageAtlas.patternPositions[et.toString()];Ft&&Ye.setConstantPatternPositions(Ft)}const _t=H.constantOr(null),Zt=ee.constantOr(null);if(!_e&&_t&&Zt&&He.lineAtlas){const Ft=He.lineAtlas.getDash(_t,Zt);Ft&&Ye.setConstantPatternPositions(Ft)}let[dt,Bt]=f.paint.get("line-trim-offset");(Zt==="round"||Zt==="square")&&dt!==Bt&&(dt===0&&(dt-=1),Bt===1&&(Bt+=1));const St=y.terrain?Le.projMatrix:null,Yt=_e?Ua(y,He,f,St,z):Dg(y,He,f,St,Ze.lineClipsArray.length,z,[dt,Bt]);if(be){const Ft=Ze.gradients[f.id];let Jt=Ft.texture;if(f.gradientVersion!==Ft.version){let Ut=256;if(f.stepInterpolant){const tn=h.getSource().maxzoom,Mn=Le.canonical.z===tn?Math.ceil(1<<y.transform.maxZoom-Le.canonical.z):1;Ut=a.clamp(a.nextPowerOfTwo(Ze.maxLineLength/a.EXTENT*1024*Mn),256,Ee.maxTextureSize)}Ft.gradient=a.renderColorRamp({expression:f.gradientExpression(),evaluationKey:"lineProgress",resolution:Ut,image:Ft.gradient||void 0,clips:Ze.lineClipsArray}),Ft.texture?Ft.texture.update(Ft.gradient):Ft.texture=new a.Texture(Ee,Ft.gradient,te.RGBA),Ft.version=f.gradientVersion,Jt=Ft.texture}Ee.activeTexture.set(te.TEXTURE1),Jt.bind(f.stepInterpolant?te.NEAREST:te.LINEAR,te.CLAMP_TO_EDGE)}q&&(Ee.activeTexture.set(te.TEXTURE0),He.lineAtlasTexture.bind(te.LINEAR,te.REPEAT),Ye.updatePaintBuffers()),_e&&(Ee.activeTexture.set(te.TEXTURE0),He.imageAtlasTexture.bind(te.LINEAR,te.CLAMP_TO_EDGE),Ye.updatePaintBuffers()),y.prepareDrawProgram(Ee,ot,Le.toUnwrapped());const gt=Ft=>{ot.draw(Ee,te.TRIANGLES,I,Ft,L,a.CullFaceMode.disabled,Yt,f.id,Ze.layoutVertexBuffer,Ze.indexBuffer,Ze.segments,f.paint,y.transform.zoom,Ye,[Ze.layoutVertexBuffer2])};if(Oe){const Ft=y.stencilModeForClipping(Le).ref;Ft===0&&y.terrain&&Ee.clear({stencil:0});const Jt={func:te.EQUAL,mask:255};Yt.u_alpha_discard_threshold=.8,gt(new a.StencilMode(Jt,Ft,255,te.KEEP,te.KEEP,te.INVERT)),Yt.u_alpha_discard_threshold=0,gt(new a.StencilMode(Jt,Ft,255,te.KEEP,te.KEEP,te.KEEP))}else gt(y.stencilModeForClipping(Le))}Oe&&(y.resetStencilClippingMasks(),y.terrain&&Ee.clear({stencil:0}))},fill:function(y,h,f,v){const w=f.paint.get("fill-color"),S=f.paint.get("fill-opacity");if(S.constantOr(1)===0)return;const I=y.colorModeForRenderPass(),L=f.paint.get("fill-pattern"),z=y.opaquePassEnabledForLayer()&&!L.constantOr(1)&&w.constantOr(a.Color.transparent).a===1&&S.constantOr(0)===1?"opaque":"translucent";if(y.renderPass===z){const H=y.depthModeForSublayer(1,y.renderPass==="opaque"?a.DepthMode.ReadWrite:a.DepthMode.ReadOnly);Va(y,h,f,v,H,I,!1)}if(y.renderPass==="translucent"&&f.paint.get("fill-antialias")){const H=y.depthModeForSublayer(f.getPaintProperty("fill-outline-color")?2:0,a.DepthMode.ReadOnly);Va(y,h,f,v,H,I,!0)}},"fill-extrusion":function(y,h,f,v){const w=f.paint.get("fill-extrusion-opacity");if(w!==0&&y.renderPass==="translucent"){const S=new a.DepthMode(y.context.gl.LEQUAL,a.DepthMode.ReadWrite,y.depthRangeFor3D);if(w!==1||f.paint.get("fill-extrusion-pattern").constantOr(1))Hi(y,h,f,v,S,a.StencilMode.disabled,a.ColorMode.disabled),Hi(y,h,f,v,S,y.stencilModeFor3D(),y.colorModeForRenderPass()),y.resetStencilClippingMasks();else{const I=y.colorModeForRenderPass();Hi(y,h,f,v,S,a.StencilMode.disabled,I)}}},hillshade:function(y,h,f,v){if(y.renderPass!=="offscreen"&&y.renderPass!=="translucent")return;const w=y.context,S=y.depthModeForSublayer(0,a.DepthMode.ReadOnly),I=y.colorModeForRenderPass(),L=y.terrain&&y.terrain.renderingToTexture,[z,H]=y.renderPass!=="translucent"||L?[{},v]:y.stencilConfigForOverlap(v);for(const q of H){const ee=h.getTile(q);if(ee.needsHillshadePrepare&&y.renderPass==="offscreen")Pp(y,ee,f,S,a.StencilMode.disabled,I);else if(y.renderPass==="translucent"){const de=L&&y.terrain?y.terrain.stencilModeForRTTOverlap(q):z[q.overscaledZ];wl(y,q,ee,f,S,de,I)}}w.viewport.set([0,0,y.width,y.height]),y.resetStencilClippingMasks()}
1423,raster:function(y,h,f,v,w,S){if(y.renderPass!=="translucent"||f.paint.get("raster-opacity")===0||!v.length)return;const I=y.context,L=I.gl,z=h.getSource(),H=y.useProgram("raster"),q=y.colorModeForRenderPass(),ee=y.terrain&&y.terrain.renderingToTexture,[de,_e]=z instanceof jn||ee?[{},v]:y.stencilConfigForOverlap(v),be=_e[_e.length-1].overscaledZ,ve=!y.options.moving;for(const Ee of _e){const te=ee?a.DepthMode.disabled:y.depthModeForSublayer(Ee.overscaledZ-be,f.paint.get("raster-opacity")===1?a.DepthMode.ReadWrite:a.DepthMode.ReadOnly,L.LESS),ye=Ee.toUnwrapped(),Oe=h.getTile(Ee);if(ee&&(!Oe||!Oe.hasData()))continue;const Le=ee?Ee.projMatrix:y.transform.calculateProjMatrix(ye,ve),He=y.terrain&&ee?y.terrain.stencilModeForRTTOverlap(Ee):de[Ee.overscaledZ],Ze=S?0:f.paint.get("raster-fade-duration");Oe.registerFadeDuration(Ze);const Ye=h.findLoadedParent(Ee,0),ot=Qd(Oe,Ye,h,y.transform,Ze);let et,_t;y.terrain&&y.terrain.prepareDrawTile();const Zt=f.paint.get("raster-resampling")==="nearest"?L.NEAREST:L.LINEAR;I.activeTexture.set(L.TEXTURE0),Oe.texture.bind(Zt,L.CLAMP_TO_EDGE),I.activeTexture.set(L.TEXTURE1),Ye?(Ye.texture.bind(Zt,L.CLAMP_TO_EDGE),et=Math.pow(2,Ye.tileID.overscaledZ-Oe.tileID.overscaledZ),_t=[Oe.tileID.canonical.x*et%1,Oe.tileID.canonical.y*et%1
1423]):Oe.texture.bind(Zt,L.CLAMP_TO_EDGE),Oe.texture.useMipmap&&I.extTextureFilterAnisotropic&&y.transform.pitch>20&&L.texParameterf(L.TEXTURE_2D,I.extTextureFilterAnisotropic.TEXTURE_MAX_ANISOTROPY_EXT,I.extTextureFilterAnisotropicMax);const dt=nf(Le,_t||[0,0],et||1,ot,f,z instanceof jn?z.perspectiveTransform:[0,0]);if(y.prepareDrawProgram(I,H,ye),z instanceof jn)z.boundsBuffer&&z.boundsSegments&&H.draw(I,L.TRIANGLES,te,a.StencilMode.disabled,q,a.CullFaceMode.disabled,dt,f.id,z.boundsBuffer,y.quadTriangleIndexBuffer,z.boundsSegments);else{const{tileBoundsBuffer:Bt,tileBoundsIndexBuffer:St,tileBoundsSegments:Yt}=y.getTileBoundsBuffers(Oe);H.draw(I,L.TRIANGLES,te,He,q,a.CullFaceMode.disabled,dt,f.id,Bt,St,Yt)}}y.resetStencilClippingMasks()},background:function(y,h,f,v){const w=f.paint.get("background-color"),S=f.paint.get("background-opacity");if(S===0)return;const I=y.context,L=I.gl,z=y.transform,H=z.tileSize,q=f.paint.get("background-pattern");if(y.isPatternMissing(q))return;const ee=!q&&w.a===1&&S===1&&y.opaquePassEnabledForLayer()?"opaque":"translucent";if(y.renderPass!==ee)return;const de=a.StencilMode.disabled,_e=y.depthModeForSublayer(0,ee==="opaque"?a.DepthMode.ReadWrite:a.DepthMode.ReadOnly),be=y.colorModeForRenderPass(),ve=y.useProgram(q?"backgroundPattern":"background");let Ee,te=v;te||(Ee=y.getBackgroundTiles(),te=Object.values(Ee).map(ye=>ye.tileID)),q&&(I.activeTexture.set(L.TEXTURE0),y.imageManager.bind(y.context));for(const ye of te){const Oe=ye.toUnwrapped(),Le=v?ye.projMatrix:y.transform.calculateProjMatrix(Oe);y.prepareDrawTile();const He=h?h.getTile(ye):Ee?Ee[ye.key]:new a.Tile(ye,H,z.zoom,y),Ze=q?Dp(Le,S,y,q,{tileID:ye,tileSize:H}):ic(Le,S,w);y.prepareDrawProgram(I,ve,Oe);const{tileBoundsBuffer:Ye,tileBoundsIndexBuffer:ot,tileBoundsSegments:et}=y.getTileBoundsBuffers(He);ve.draw(I,L.TRIANGLES,_e,de,be,a.CullFaceMode.disabled,Ze,f.id,Ye,ot,et)}},sky:function(y,h,f){const v=y.transform,w=v.projection.name==="mercator"||v.projection.name==="globe"?1:a.smoothstep(7,8,v.zoom),S=f.paint.get("sky-opacity")*w;if(S===0)return;const I=y.context,L=f.paint.get("sky-type"),z=new a.DepthMode(I.gl.LEQUAL,a.DepthMode.ReadOnly,[0,1]),H=y.frameCounter/1e3%1;L==="atmosphere"?y.renderPass==="offscreen"?f.needsSkyboxCapture(y)&&(function(q,ee,de,_e){const be=q.context,ve=be.gl;let Ee=ee.skyboxFbo;if(!Ee){Ee=ee.skyboxFbo=be.createFramebuffer(32,32,!1),ee.skyboxGeometry=new Lr(be),ee.skyboxTexture=be.gl.createTexture(),ve.bindTexture(ve.TEXTURE_CUBE_MAP,ee.skyboxTexture),ve.texParameteri(ve.TEXTURE_CUBE_MAP,ve.TEXTURE_WRAP_S,ve.CLAMP_TO_EDGE),ve.texParameteri(ve.TEXTURE_CUBE_MAP,ve.TEXTURE_WRAP_T,ve.CLAMP_TO_EDGE),ve.texParameteri(ve.TEXTURE_CUBE_MAP,ve.TEXTURE_MIN_FILTER,ve.LINEAR),ve.texParameteri(ve.TEXTURE_CUBE_MAP,ve.TEXTURE_MAG_FILTER,ve.LINEAR);for(let Le=0;Le<6;++Le)ve.texImage2D(ve.TEXTURE_CUBE_MAP_POSITIVE_X+Le,0,ve.RGBA,32,32,0,ve.RGBA,ve.UNSIGNED_BYTE,null)}be.bindFramebuffer.set(Ee.framebuffer),be.viewport.set([0,0,32,32]);const te=ee.getCenter(q,!0),ye=q.useProgram("skyboxCapture"),Oe=new Float64Array(16);a.identity(Oe),a.rotateY(Oe,Oe,.5*-Math.PI),oa(be,ee,ye,Oe,te,0),a.identity(Oe),a.rotateY(Oe,Oe,.5*Math.PI),oa(be,ee,ye,Oe,te,1),a.identity(Oe),a.rotateX(Oe,Oe,.5*-Math.PI),oa(be,ee,ye,Oe,te,2),a.identity(Oe),a.rotateX(Oe,Oe,.5*Math.PI),oa(be,ee,ye,Oe,te,3),a.identity(Oe),oa(be,ee,ye,Oe,te,4),a.identity(Oe),a.rotateY(Oe,Oe,Math.PI),oa(be,ee,ye,Oe,te,5),be.viewport.set([0,0,q.width,q.height])}(y,f),f.markSkyboxValid(y)):y.renderPass==="sky"&&function(q,ee,de,_e,be){const ve=q.context,Ee=ve.gl,te=q.transform,ye=q.useProgram("skybox");ve.activeTexture.set(Ee.TEXTURE0),Ee.bindTexture(Ee.TEXTURE_CUBE_MAP,ee.skyboxTexture);const Oe=((Le,He,Ze,Ye,ot)=>({u_matrix:Le,u_sun_direction:He,u_cubemap:0,u_opacity:Ye,u_temporal_offset:ot}))(te.skyboxMatrix,ee.getCenter(q,!1),0,_e,be);q.prepareDrawProgram(ve,ye),ye.draw(ve,Ee.TRIANGLES,de,a.StencilMode.disabled,q.colorModeForRenderPass(),a.CullFaceMode.backCW,Oe,"skybox",ee.skyboxGeometry.vertexBuffer,ee.skyboxGeometry.indexBuffer,ee.skyboxGeometry.segment)}(y,f,z,S,H):L==="gradient"&&y.renderPass==="sky"&&function(q,ee,de,_e,be){const ve=q.context,Ee=ve.gl,te=q.transform,ye=q.useProgram("skyboxGradient");ee.skyboxGeometry||(ee.skyboxGeometry=new Lr(ve)),ve.activeTexture.set(Ee.TEXTURE0);let Oe=ee.colorRampTexture;Oe||(Oe=ee.colorRampTexture=new a.Texture(ve,ee.colorRamp,Ee.RGBA)),Oe.bind(Ee.LINEAR,Ee.CLAMP_TO_EDGE);const Le=((He,Ze,Ye,ot,et)=>({u_matrix:He,u_color_ramp:0,u_center_direction:Ze,u_radius:a.degToRad(Ye),u_opacity:ot,u_temporal_offset:et}))(te.skyboxMatrix,ee.getCenter(q,!1),ee.paint.get("sky-gradient-radius"),_e,be);q.prepareDrawProgram(ve,ye),ye.draw(ve,Ee.TRIANGLES,de,a.StencilMode.disabled,q.colorModeForRenderPass(),a.CullFaceMode.backCW,Le,"skyboxGradient",ee.skyboxGeometry.vertexBuffer,ee.skyboxGeometry.indexBuffer,ee.skyboxGeometry.segment)}(y,f,z,S,H)},debug:function(y,h,f){for(let v=0;v<f.length;v++)xh(y,h,f[v])},custom:function(y,h,f,v){const w=y.context,S=f.implementation;if(!y.transform.projection.unsupportedLayers||!y.transform.projection.unsupportedLayers.includes("custom")||y.terrain&&(y.terrain.renderingToTexture||y.renderPass==="offscreen")&&f.isLayerDraped()){if(y.renderPass==="offscreen"){const I=S.prerender;if(I){if(y.setCustomLayerDefaults(),w.setColorMode(y.colorModeForRenderPass()),y.transform.projection.name==="globe"){const L=y.transform.pointMerc;I.call(S,w.gl,y.transform.customLayerMatrix(),y.transform.getProjection(),y.transform.globeToMercatorMatrix(),a.globeToMercatorTransition(y.transform.zoom),[L.x,L.y],y.transform.pixelsPerMeterRatio)}else I.call(S,w.gl,y.transform.customLayerMatrix());w.setDirty(),y.setBaseState()}}else if(y.renderPass==="translucent"){if(y.terrain&&y.terrain.renderingToTexture){const L=S.renderToTile;if(L){const z=v[0].canonical,H=new a.MercatorCoordinate(z.x+v[0].wrap*(1<<z.z),z.y,z.z);w.setDepthMode(a.DepthMode.disabled),w.setStencilMode(a.StencilMode.disabled),w.setColorMode(y.colorModeForRenderPass()),y.setCustomLayerDefaults(),L.call(S,w.gl,H),w.setDirty(),y.setBaseState()}return}y.setCustomLayerDefaults(),w.setColorMode(y.colorModeForRenderPass()),w.setStencilMode(a.StencilMode.disabled);const I=S.renderingMode==="3d"?new a.DepthMode(y.context.gl.LEQUAL,a.DepthMode.ReadWrite,y.depthRangeFor3D):y.depthModeForSublayer(0,a.DepthMode.ReadOnly);if(w.setDepthMode(I),y.transform.projection.name==="globe"){const L=y.transform.pointMerc;S.render(w.gl,y.transform.customLayerMatrix(),y.transform.getProjection(),y.transform.globeToMercatorMatrix(),a.globeToMercatorTransition(y.transform.zoom),[L.x,L.y],y.transform.pixelsPerMeterRatio)}else S.render(w.gl,y.transform.customLayerMatrix());w.setDirty(),y.setBaseState(),w.bindFramebuffer.set(null)}}else a.warnOnce("Custom layers are not yet supported with this projection. Use mercator or globe to enable usage of custom layers.")}};class ma{constructor(h,f,v=!1){this.context=new en(h,v),this.transform=f,this._tileTextures={},this.frameCopies=[],this.loadTimeStamps=[],this.setup(),this.numSublayers=a.SourceCache.maxUnderzooming+a.SourceCache.maxOverzooming+1,this.depthEpsilon=1/Math.pow(2,16),this.deferredRenderGpuTimeQueries=[],this.gpuTimers={},this.frameCounter=0,this._backgroundTiles={}}updateTerrain(h,f){const v=!!h&&!!h.terrain&&this.transform.projection.supportsTerrain;if(!(v||this._terrain&&this._terrain.enabled))return;this._terrain||(this._terrain=new ku(this,h));const w=this._terrain;this.transform.elevation=v?w:null,w.update(h,this.transform,f)}_updateFog(h){const f=h.fog;if(!f||this.transform.projection.name==="globe"||f.getOpacity(this.transform.pitch)<1||f.properties.get("horizon-blend")<.03)return void(this.transform.fogCullDistSq=null);const[v,w]=f.getFovAdjustedRange(this.transform._fov);if(v>w)return void(this.transform.fogCullDistSq=null);const S=v+.78*(w-v);this.transform.fogCullDistSq=S*S}get terrain(){return this.transform._terrainEnabled()&&this._terrain&&this._terrain.enabled?this._terrain:null}resize(h,f){if(this.width=h*a.exported.devicePixelRatio,this.height=f*a.exported.devicePixelRatio,this.context.viewport.set([0,0,this.width,this.height]),this.style)for(const v of this.style.order)this.style._layers[v].resize()}
vendor: 3,791 bytes, line 1423
1423setup(){const h=this.context,f=new a.StructArrayLayout2i4;f.emplaceBack(0,0),f.emplaceBack(a.EXTENT,0),f.emplaceBack(0,a.EXTENT),f.emplaceBack(a.EXTENT,a.EXTENT),this.tileExtentBuffer=h.createVertexBuffer(f,a.posAttributes.members),this.tileExtentSegments=a.SegmentVector.simpleSegment(0,0,4,2);const v=new a.StructArrayLayout2i4;v.emplaceBack(0,0),v.emplaceBack(a.EXTENT,0),v.emplaceBack(0,a.EXTENT),v.emplaceBack(a.EXTENT,a.EXTENT),this.debugBuffer=h.createVertexBuffer(v,a.posAttributes.members),this.debugSegments=a.SegmentVector.simpleSegment(0,0,4,5);const w=new a.StructArrayLayout2i4;w.emplaceBack(-1,-1),w.emplaceBack(1,-1),w.emplaceBack(-1,1),w.emplaceBack(1,1),this.viewportBuffer=h.createVertexBuffer(w,a.posAttributes.members),this.viewportSegments=a.SegmentVector.simpleSegment(0,0,4,2);const S=new a.StructArrayLayout4i8;S.emplaceBack(0,0,0,0),S.emplaceBack(a.EXTENT,0,a.EXTENT,0),S.emplaceBack(0,a.EXTENT,0,a.EXTENT),S.emplaceBack(a.EXTENT,a.EXTENT,a.EXTENT,a.EXTENT),this.mercatorBoundsBuffer=h.createVertexBuffer(S,a.boundsAttributes.members),this.mercatorBoundsSegments=a.SegmentVector.simpleSegment(0,0,4,2);const I=new a.StructArrayLayout3ui6;I.emplaceBack(0,1,2),I.emplaceBack(2,1,3),this.quadTriangleIndexBuffer=h.createIndexBuffer(I);const L=new a.StructArrayLayout1ui2;for(const H of[0,1,3,2,0])L.emplaceBack(H);this.debugIndexBuffer=h.createIndexBuffer(L),this.emptyTexture=new a.Texture(h,new a.RGBAImage({width:1,height:1},Uint8Array.of(0,0,0,0)),h.gl.RGBA),this.identityMat=a.create();const z=this.context.gl;this.stencilClearMode=new a.StencilMode({func:z.ALWAYS,mask:0},0,255,z.ZERO,z.ZERO,z.ZERO),this.loadTimeStamps.push(a.window.performance.now()),this.atmosphereBuffer=new wh(this.context)}getMercatorTileBoundsBuffers(){return{tileBoundsBuffer:this.mercatorBoundsBuffer,tileBoundsIndexBuffer:this.quadTriangleIndexBuffer,tileBoundsSegments:this.mercatorBoundsSegments}}getTileBoundsBuffers(h){return h._makeTileBoundsBuffers(this.context,this.transform.projection),h._tileBoundsBuffer?{tileBoundsBuffer:h._tileBoundsBuffer,tileBoundsIndexBuffer:h._tileBoundsIndexBuffer,tileBoundsSegments:h._tileBoundsSegments}:this.getMercatorTileBoundsBuffers()}clearStencil(){const h=this.context,f=h.gl;this.nextStencilID=1,this.currentStencilSource=void 0,this._tileClippingMaskIDs={},this.useProgram("clippingMask").draw(h,f.TRIANGLES,a.DepthMode.disabled,this.stencilClearMode,a.ColorMode.disabled,a.CullFaceMode.disabled,Su(this.identityMat),"$clipping",this.viewportBuffer,this.quadTriangleIndexBuffer,this.viewportSegments)}resetStencilClippingMasks(){this.terrain||(this.currentStencilSource=void 0,this._tileClippingMaskIDs={})}_renderTileClippingMasks(h,f,v){if(!f||this.currentStencilSource===f.id||!h.isTileClipped()||!v||v.length===0)return;if(this._tileClippingMaskIDs&&!this.terrain){let L=!1;for(const z of v)if(this._tileClippingMaskIDs[z.key]===void 0){L=!0;break}if(!L)return}this.currentStencilSource=f.id;const w=this.context,S=w.gl;this.nextStencilID+v.length>256&&this.clearStencil(),w.setColorMode(a.ColorMode.disabled),w.setDepthMode(a.DepthMode.disabled);const I=this.useProgram("clippingMask");this._tileClippingMaskIDs={};for(const L of v){const z=f.getTile(L),H=this._tileClippingMaskIDs[L.key]=this.nextStencilID++,{tileBoundsBuffer:q,tileBoundsIndexBuffer:ee,tileBoundsSegments:de}=this.getTileBoundsBuffers(z);I.draw(w,S.TRIANGLES,a.DepthMode.disabled,new a.StencilMode({func:S.ALWAYS,mask:0},H,255,S.KEEP,S.KEEP,S.REPLACE),a.ColorMode.disabled,a.CullFaceMode.disabled,Su(L.projMatrix),"$clipping",q,ee,de)}}stencilModeFor3D(){this.currentStencilSource=void 0,this.nextStencilID+1>256&&this.clearStencil();const h=this.nextStencilID++,f=this.context.gl;return new a.StencilMode({func:f.NOTEQUAL,mask:255},h,255,f.KEEP,f.KEEP,f.REPLACE)}
1423stencilModeForClipping(h){if(this.terrain)return this.terrain.stencilModeForRTTOverlap(h);const f=this.context.gl;return new a.StencilMode({func:f.EQUAL,mask:255},this._tileClippingMaskIDs[h.key],0,f.KEEP,f.KEEP,f.REPLACE)}stencilConfigForOverlap(h){const f=this.context.gl,v=h.sort((I,L)=>L.overscaledZ-I.overscaledZ),w=v[v.length-1].overscaledZ,S=v[0].overscaledZ-w+1;if(S>1){this.currentStencilSource=void 0,this.nextStencilID+S>256&&this.clearStencil();const I={};for(let L=0;L<S;L++)I[L+w]=new a.StencilMode({func:f.GEQUAL,mask:255},L+this.nextStencilID,255,f.KEEP,f.KEEP,f.REPLACE);return this.nextStencilID+=S,[I,v]}return[{[w]:a.StencilMode.disabled},v]}colorModeForRenderPass(){const h=this.context.gl;return this._showOverdrawInspector?new a.ColorMode([h.CONSTANT_COLOR,h.ONE],new a.Color(.125,.125,.125,0),[!0,!0,!0,!0]):this.renderPass==="opaque"?a.ColorMode.unblended:a.ColorMode.alphaBlended}depthModeForSublayer(h,f,v){if(!this.opaquePassEnabledForLayer())return a.DepthMode.disabled;const w=1-((1+this.currentLayer)*this.numSublayers+h)*this.depthEpsilon;return new a.DepthMode(v||this.context.gl.LEQUAL,f,[w,w])}opaquePassEnabledForLayer(){return this.currentLayer<this.opaquePassCutoff}render(h,f){this.style=h,this.options=f,this.imageManager=h.imageManager,this.glyphManager=h.glyphManager,this.symbolFadeChange=h.placement.symbolFadeChange(a.exported.now()),this.imageManager.beginFrame();const v=this.style.order,w=this.style._sourceCaches;for(const H in w){const q=w[H];q.used&&q.prepare(this.context)}const S={},I={},L={};for(const H in w){const q=w[H];S[H]=q.getVisibleCoordinates(),I[H]=S[H].slice().reverse(),L[H]=q.getVisibleCoordinates(!0).reverse()}this.opaquePassCutoff=1/0;for(let H=0;H<v.length;H++)if(this.style._layers[v[H]].is3D()){this.opaquePassCutoff=H;break}if(this.terrain&&(this.terrain.updateTileBinding(L),this.opaquePassCutoff=0),this.transform.projection.name!=="globe"||this.globeSharedBuffers||(this.globeSharedBuffers=new a.GlobeSharedBuffers(this.context)),!a.isMapAuthenticated(this.context.gl))return;this.renderPass="offscreen";for(const H of v){const q=this.style._layers[H],ee=h._getLayerSourceCache(q);if(!q.hasOffscreenPass()||q.isHidden(this.transform.zoom))continue;const de=ee?I[ee.id]:void 0;(q.type==="custom"||q.isSky()||de&&de.length)&&this.renderLayer(this,ee,q,de)}this.depthRangeFor3D=[0,1-(h.order.length+2)*this.numSublayers*this.depthEpsilon];const z=this.terrain;if(z&&(this.style.hasSymbolLayers()||this.style.hasCircleLayers())&&z.drawDepth(),this.context.bindFramebuffer.set(null),this.context.viewport.set([0,0,this.width,this.height]),this.context.clear({color:f.showOverdrawInspector?a.Color.black:a.Color.transparent,depth:1}),this.clearStencil(),this._showOverdrawInspector=f.showOverdrawInspector,this.renderPass="opaque",!this.terrain)for(this.currentLayer=v.length-1;this.currentLayer>=0;this.currentLayer--){const H=this.style._layers[v[this.currentLayer]],q=h._getLayerSourceCache(H);if(H.isSky())continue;const ee=q?I[q.id]:void 0;this._renderTileClippingMasks(H,q,ee),this.renderLayer(this,q,H,ee)}if(this.style.fog&&this.transform.projection.supportsFog&&function(H,q){const ee=H.context,de=ee.gl,_e=H.transform,be=new a.DepthMode(de.LEQUAL,a.DepthMode.ReadOnly,[0,1]),ve=H.useProgram("globeAtmosphere",null,_e.projection.name==="globe"?["PROJECTION_GLOBE_VIEW","FOG"]:["FOG"]),Ee=a.globeToMercatorTransition(_e.zoom),te=q.properties.get("color").toArray01(),ye=q.properties.get("high-color").toArray01(),Oe=q.properties.get("space-color").toArray01PremultipliedAlpha(),Le=a.identity$1([]);a.rotateY$1(Le,Le,-a.degToRad(_e._center.lng)),a.rotateX$1(Le,Le,a.degToRad(_e._center.lat)),a.rotateZ$1(Le,Le,_e.angle),a.rotateX$1(Le,Le,-_e._pitch);const He=a.fromQuat(new Float32Array(16),Le),Ze=a.mapValue(q.properties.get("star-intensity"),0,1,0,.25),Ye=5e-4,ot=a.mapValue(q.properties.get("horizon-blend"),0,1,Ye,.25),et=a.globeUseCustomAntiAliasing(H,ee,_e)&&ot===Ye?_e.worldSize/(2*Math.PI*1.025)-1:_e.globeRadius,_t=H.frameCounter/1e3%1,Zt=a.length(_e.globeCenterInViewSpace),dt=Math.sqrt(Math.pow(Zt,2)-Math.pow(et,2)),Bt=Math.acos(dt/Zt),St=((gt,Ft,Jt,Ut,tn,Mn,Wn,wn,Bn,mr,pr,Cn,Nr,Qr)=>({u_frustum_tl:gt,u_frustum_tr:Ft,u_frustum_br:Jt,u_frustum_bl:Ut,u_horizon:tn,u_transition:Mn,u_fadeout_range:Wn,u_color:wn,u_high_color:Bn,u_space_color:mr,u_star_intensity:pr,u_star_size:5*a.exported.devicePixelRatio,u_star_density:0,u_temporal_offset:Cn,u_horizon_angle:Nr,u_rotation_matrix:Qr}))(_e.frustumCorners.TL,_e.frustumCorners.TR,_e.frustumCorners.BR,_e.frustumCorners.BL,_e.frustumCorners.horizon,Ee,ot,te,ye,Oe,Ze,_t,Bt,He);H.prepareDrawProgram(ee,ve);const Yt=H.atmosphereBuffer;Yt&&ve.draw(ee,de.TRIANGLES,be,a.StencilMode.disabled,a.ColorMode.alphaBlended,a.CullFaceMode.backCW,St,"skybox",Yt.vertexBuffer,Yt.indexBuffer,Yt.segments)}(this,this.style.fog),this.renderPass="sky",(a.globeToMercatorTransition(this.transform.zoom)>0||this.transform.projection.name!=="globe")&&this.transform.isH
1423orizonVisible())for(this.currentLayer=0;this.currentLayer<v.length;this.currentLayer++){const H=this.style._layers[v[this.currentLayer]],q=h._getLayerSourceCache(H);H.isSky()&&this.renderLayer(this,q,H,q?I[q.id]:void 0)}for(this.renderPass="translucent",this.currentLayer=0;this.currentLayer<v.length;){const H=this.style._layers[v[this.currentLayer]],q=h._getLayerSourceCache(H);if(H.isSky()){++this.currentLayer;continue}if(this.terrain&&this.style.isLayerDraped(H)){if(H.isHidden(this.transform.zoom)){++this.currentLayer;continue}this.currentLayer=this.terrain.renderBatch(this.currentLayer);continue}const ee=q?(H.type==="symbol"?L:I)[q.id]:void 0;this._renderTileClippingMasks(H,q,q?S[q.id]:void 0),this.renderLayer(this,q,H,ee),++this.currentLayer}if(this.terrain&&this.terrain.postRender(),this.options.showTileBoundaries||this.options.showQueryGeometry||this.options.showTileAABBs){let H=null;a.values(this.style._layers).forEach(q=>{const ee=h._getLayerSourceCache(q);ee&&!q.isHidden(this.transform.zoom)&&(!H||H.getSource().maxzoom<ee.getSource().maxzoom)&&(H=ee)}),H&&this.options.showTileBoundaries&&Io.debug(this,H,H.getVisibleCoordinates())}this.options.showPadding&&function(H){const q=H.transform.padding;oc(H,H.transform.height-(q.top||0),3,ra),oc(H,q.bottom||0,3,Qs),Al(H,q.left||0,3,ia),Al(H,H.transform.width-(q.right||0),3,Js);const ee=H.transform.centerPoint;(function(de,_e,be,ve){ac(de,_e-1,be-10,2,20,ve),ac(de,_e-10,be-1,20,2,ve)})(H,ee.x,H.transform.height-ee.y,Vc)}(this),this.context.setDefault(),this.frameCounter=(this.frameCounter+1)%Number.MAX_SAFE_INTEGER,this.tileLoaded&&this.options.speedIndexTiming&&(this.loadTimeStamps.push(a.window.performance.now()),this.saveC
1423anvasCopy())}renderLayer(h,f,v,w){v.isHidden(this.transform.zoom)||(v.type==="background"||v.type==="sky"||v.type==="custom"||w&&w.length)&&(this.id=v.id,this.gpuTimingStart(v),(!h.transform.projection.unsupportedLayers||!h.transform.projection.unsupportedLayers.includes(v.type)||h.terrain&&v.type==="custom")&&Io[v.type](h,f,v,w,this.style.placement.variableOffsets,this.options.isInitialLoad),this.gpuTimingEnd())}gpuTimingStart(h){if(!this.options.gpuTiming)return;const f=this.context.extTimerQuery;let v=this.gpuTimers[h.id];v||(v=this.gpuTimers[h.id]={calls:0,cpuTime:0,query:f.createQueryEXT()}),v.calls++,f.beginQueryEXT(f.TIME_ELAPSED_EXT,v.query)}gpuTimingDeferredRenderStart(){if(this.options.gpuTimingDeferredRender){const h=this.context.extTimerQuery,f=h.createQueryEXT();this.deferredRenderGpuTimeQueries.push(f),h.beginQueryEXT(h.TIME_ELAPSED_EXT,f)}}gpuTimingDeferredRenderEnd(){if(!this.options.gpuTimingDeferredRender)return;const h=this.context.extTimerQuery;h.endQueryEXT(h.TIME_ELAPSED_EXT)}gpuTimingEnd(){if(!this.options.gpuTiming)return;const h=this.context.extTimerQuery;h.endQueryEXT(h.TIME_ELAPSED_EXT)}collectGpuTimers(){const h=this.gpuTimers;return this.gpuTimers={},h}collectDeferredRenderGpuQueries(){const h=this.deferredRenderGpuTimeQueries;return this.deferredRenderGpuTimeQueries=[],h}queryGpuTimers(h){const f={};for(const v in h){const w=h[v],S=this.context.extTimerQuery,I=S.getQueryObjectEXT(w.query,S.QUERY_RESULT_EXT)/1e6;S.deleteQueryEXT(w.query),f[v]=I}return f}queryGpuTimeDeferredRender(h){if(!this.options.gpuTimingDeferredRender)return 0;const f=this.context.extTimerQuery;let v=0;for(const w of h)v+=f.getQueryObjectEXT(w,f.QUERY_RESULT_EXT)/1e6,f.deleteQueryEXT(w);return v}translatePosMatrix(h,f,v,w,S){if(!v[0]&&!v[1])return h;const I=S?w==="map"?this.transform.angle:0:w==="viewport"?-this.transform.angle:0;if(I){const H=Math.sin(I),q=Math.cos(I);v=[v[0]*q-v[1]*H,v[0]*H+v[1]*q]}const L=[S?v[0]:Ne(f,v[0],this.transform.zoom),S?v[1]:Ne(f,v[1],this.transform.zoom),0],z=new Float32Array(16);return a.translate(z,h,L),z}saveTileTexture(h){const f=this._tileTextures[h.size[0]];f?f.push(h):this._tileTextures[h.size[0]]=[h]}getTileTexture(h){const f=this._tileTextures[h];return f&&f.length>0?f.pop():null}isPatternMissing(h){return h===null||h!==void 0&&!this.imageManager.getPattern(h.toString())}terrainRenderModeElevated(){return this.style&&!!this.style.getTerrain()&&!!this.terrain&&!this.terrain.renderingToTexture}currentGlobalDefines(){const h=this.terrain&&this.terrain.renderingToTexture,f=this.terrain&&this.terrain.exaggeration()===0,v=this.style&&this.style.fog,w=[];return this.terrainRenderModeElevated()&&w.push("TERRAIN"),this.transform.projection.name==="globe"&&w.push("GLOBE"),f&&w.push("ZERO_EXAGGERATION"),v&&!h&&v.getOpacity(this.transform.pitch)!==0&&w.push("FOG"),h&&w.push("RENDER_TO_TEXTURE"),this._showOverdrawInspector&&w.push("OVERDRAW_INSPECTOR"),w}useProgram(h,f,v){this.cache=this.cache||{};const w=v||[],S=this.currentGlobalDefines().concat(w),I=ur.cacheKey(gh[h],h,S,f);return this.cache[I]||(this.cache[I]=new ur(this.context,h,gh[h],f,of[h],S)),this.cache[I]}setCustomLayerDefaults(){this.context.unbindVAO(),this.context.cullFace.setDefault(),this.context.frontFace.setDefault(),this.context.cullFaceSide.setDefault(),this.context.activeTexture.setDefault(),this.context.pixelStoreUnpack.setDefault(),this.context.pixelStoreUnpackPremultiplyAlpha.setDefault(),this.context.pixelStoreUnpackFlipY.setDefault()}setBaseState(){const h=this.context.gl;this.context.cullFace.set(!1),this.context.viewport.set([0,0,this.width,this.height]),this.context.blendEquation.set(h.FUNC_ADD)}initDebugOverlayCanvas(){this.debugOverlayCanvas==null&&(this.debugOverlayCanvas=a.window.document.createElement("canvas"),this.debugOverlayCanvas.width=512,this.debugOverlayCanvas.height=512,this.debugOverlayTexture=new a.Texture(this.context,this.debugOverlayCanvas,this.context.gl.RGBA))}destroy(){this._terrain&&this._terrain.destroy(),this.globeSharedBuffers&&this.globeSharedBuffers.destroy(),this.emptyTexture.destroy(),this.debugOverlayTexture&&this.debugOverlayTexture.destroy(),this.atmosphereBuffer&&this.atmosphereBuffer.destroy()}prepareDrawTile(){this.terrain&&this.terrain.prepareDrawTile()}prepareDrawProgram(h,f,v){if(this.terrain&&this.terrain.renderingToTexture)return;const w=this.style.fog;if(w){const S=w.getOpacity(this.transform.pitch),I=((L,z,H,q,ee,de,_e,be,ve,Ee,te)=>{const ye=L.transform,Oe=z.properties.get("color").toArray01();Oe[3]=q;const Le=L.frameCounter/1e3%1;return{u_fog_matrix:H?ye.calculateFogTileMatrix(H):L.identityMat,u_fog_range:z.getFovAdjustedRange(ye._fov),u_fog_color:Oe,u_fog_horizon_blend:z.properties.get("horizon-blend"),u_fog_temporal_offset:Le,u_frustum_tl:ee,u_frustum_tr:de,u_frustum_br:_e,u_frustum_bl:be,u_globe_pos:ve,u_globe_radius:Ee,u_viewport:te,u_globe_transition:a.globeToMercatorTransition(ye.zoom),u_is_globe:+(ye.projection.name==="globe")}})(this,w,v,S,this.transform.frustumCorners.TL,this.transform.frustumCorners.TR,this.transform.frustumCorners.BR,this.transform.frustumCorners.BL,this.transform.globeCenterInViewSpace,this.transform.globeRadius,[this.transform.width*a.exported.devicePixelRatio,this.transform.height*a.exported.devicePixelRatio]);f.setFogUniformValues(h,I)}}setTileLoadedFlag(h){this.tileLoaded=h}saveCanvasCopy(){const h=this.canvasCopy();h&&(this.frameCopies.push(h),this.tileLoaded=!1)}canvasCopy(){const h=this.context.gl,f=h.createTexture();
1423return h.bindTexture(h.TEXTURE_2D,f),h.copyTexImage2D(h.TEXTURE_2D,0,h.RGBA,0,0,h.drawingBufferWidth,h.drawingBufferHeight,0),f}getCanvasCopiesAndTimestamps(){return{canvasCopies:this.frameCopies,timeStamps:this.loadTimeStamps}}averageElevationNeedsEasing(){if(!this.transform._elevation)return!1;const h=this.style&&this.style.fog;return!!h&&h.getOpacity(this.transform.pitch)!==0}getBackgroundTiles(){const h=this._backgroundTiles,f=this._backgroundTiles={},v=this.transform.coveringTiles({tileSize:512});for(const w of v)f[w.key]=h[w.key]||new a.Tile(w,512,this.transform.tileZoom,this);return f}clearBackgroundTiles(){this._backgroundTiles={}}}class cs{constructor(h=0,f=0,v=0,w=0){if(isNaN(h)||h<0||isNaN(f)||f<0||isNaN(v)||v<0||isNaN(w)||w<0)throw new Error("Invalid value for edge-insets, top, bottom, left and right must all be numbers");this.top=h,this.bottom=f,this.left=v,this.right=w}interpolate(h,f,v){return f.top!=null&&h.top!=null&&(this.top=a.number(h.top,f.top,v)),f.bottom!=null&&h.bottom!=null&&(this.bottom=a.number(h.bottom,f.bottom,v)),f.left!=null&&h.left!=null&&(this.left=a.number(h.left,f.left,v)),f.right!=null&&h.right!=null&&(this.right=a.number(h.right,f.right,v)),this}getCenter(h,f){const v=a.clamp((this.left+h-this.right)/2,0,h),w=a.clamp((this.top+f-this.bottom)/2,0,f);return new a.Point(v,w)}equals(h){return this.top===h.top&&this.bottom===h.bottom&&this.left===h.left&&this.right===h.right}clone(){return new cs(this.top,this.bottom,this.left,this.right)}toJSON(){return{top:this.top,bottom:this.bottom,left:this.left,right:this.right}}}function Pl(y,h){const f=a.getColumn(y,3);a.fromQuat(y,h),a.setColumn(y,3,f)}function _r(y,h){const f=a.identity$1([]);return a.rotateZ$1(f,f,-h),a.rotateX$1(f,f,-y),f}function Es(y,h){const f=[y[0],y[1],0],v=[h[0],h[1],0];if(a.length(f)>=1e-15){const I=a.normalize([],f);a.scale$2(v,I,a.dot(v,I)),h[0]=v[0],h[1]=v[1]}const w=a.cross([],h,y);if(a.len(w)<1e-15)return null;const S=Math.atan2(-w[1],w[0]);return _r(Math.atan2(Math.sqrt(y[0]*y[0]+y[1]*y[1]),-y[2]),S)}class Ml{constructor(h,f){this.position=h,this.orientation=f}get position(){return this._position}set position(h){if(h){const f=h instanceof a.MercatorCoordinate?h:new a.MercatorCoordinate(h[0],h[1],h[2]);
vendor: 4,698 bytes, line 1423
1423this._renderWorldCopies&&(f.x=a.wrap(f.x,0,1)),this._position=f}else this._position=null}lookAtPoint(h,f){if(this.orientation=null,!this.position)return;const v=this.position,w=this._elevation?this._elevation.getAtPointOrZero(a.MercatorCoordinate.fromLngLat(h)):0,S=a.MercatorCoordinate.fromLngLat(h,w),I=[S.x-v.x,S.y-v.y,S.z-v.z];f||(f=[0,0,1]),f[2]=Math.abs(f[2]),this.orientation=Es(I,f)}setPitchBearing(h,f){this.orientation=_r(a.degToRad(h),a.degToRad(-f))}}class Ou{constructor(h,f){this._transform=a.identity([]),this.orientation=f,this.position=h}get mercatorPosition(){const h=this.position;return new a.MercatorCoordinate(h[0],h[1],h[2])}get position(){const h=a.getColumn(this._transform,3);return[h[0],h[1],h[2]]}set position(h){var f;h&&a.setColumn(this._transform,3,[(f=h)[0],f[1],f[2],1])}get orientation(){return this._orientation}set orientation(h){this._orientation=h||a.identity$1([]),h&&Pl(this._transform,this._orientation)}getPitchBearing(){const h=this.forward(),f=this.right();return{bearing:Math.atan2(-f[1],f[0]),pitch:Math.atan2(Math.sqrt(h[0]*h[0]+h[1]*h[1]),-h[2])}}setPitchBearing(h,f){this._orientation=_r(h,f),Pl(this._transform,this._orientation)}forward(){const h=a.getColumn(this._transform,2);return[-h[0],-h[1],-h[2]]}up(){const h=a.getColumn(this._transform,1);return[-h[0],-h[1],-h[2]]}right(){const h=a.getColumn(this._transform,0);return[h[0],h[1],h[2]]}getCameraToWorld(h,f){const v=new Float64Array(16);return a.invert(v,this.getWorldToCamera(h,f)),v}getWorldToCameraPosition(h,f,v){const w=this.position;a.scale$2(w,w,-h);const S=new Float64Array(16);return a.fromScaling(S,[v,v,v]),a.translate(S,S,w),S[10]*=f,S}getWorldToCamera(h,f){const v=new Float64Array(16),w=new Float64Array(4),S=this.position;return a.conjugate(w,this._orientation),a.scale$2(S,S,-h),a.fromQuat(v,w),a.translate(v,v,S),v[1]*=-1,v[5]*=-1,v[9]*=-1,v[13]*=-1,v[8]*=f,v[9]*=f,v[10]*=f,v[11]*=f,v}getCameraToClipPerspective(h,f,v,w){const S=new Float64Array(16);return a.perspective(S,h,f,v,w),S}getDistanceToElevation(h,f=!1){const v=h===0?0:a.mercatorZfromAltitude(h,f?a.latFromMercatorY(this.position[1]):this.position[1]),w=this.forward();return(v-this.position[2])/w[2]}clone(){return new Ou([...this.position],[...this.orientation])}}function el(y,h){const f=sc(y.projection,y.zoom,y.width,y.height),v=function(S,I,L,z,H){const q=new a.LngLat(L.lng-180*qa,L.lat),ee=new a.LngLat(L.lng+180*qa,L.lat),de=S.project(q.lng,q.lat),_e=S.project(ee.lng,ee.lat),be=-Math.atan2(_e.y-de.y,_e.x-de.x),ve=a.MercatorCoordinate.fromLngLat(L);ve.y=a.clamp(ve.y,-1+qa,1-qa);const Ee=ve.toLngLat(),te=S.project(Ee.lng,Ee.lat),ye=a.MercatorCoordinate.fromLngLat(Ee);ye.x+=qa;const Oe=ye.toLngLat(),Le=S.project(Oe.lng,Oe.lat),He=lc(Le.x-te.x,Le.y-te.y,be),Ze=a.MercatorCoordinate.fromLngLat(Ee);Ze.y+=qa;const Ye=Ze.toLngLat(),ot=S.project(Ye.lng,Ye.lat),et=lc(ot.x-te.x,ot.y-te.y,be),_t=Math.abs(He.x)/Math.abs(et.y),Zt=a.identity([]);a.rotateZ(Zt,Zt,-be*(1-(H?0:z)));const dt=a.identity([]);return a.scale(dt,dt,[1,1-(1-_t)*z,1]),dt[4]=-et.x/et.y*z,a.rotateZ(dt,dt,be),a.multiply(dt,Zt,dt),dt}(y.projection,0,y.center,f,h),w=Th(y);return a.scale(v,v,[w,w,1]),v}function Th(y){const h=y.projection,f=sc(y.projection,y.zoom,y.width,y.height),v=af(h,y.center),w=af(h,a.LngLat.convert(h.center));return Math.pow(2,v*f+(1-f)*w)}function sc(y,h,f,v,w=1/0){const S=y.range;if(!S)return 0;const I=Math.min(w,Math.max(f,v)),L=Math.log(I/1024)/Math.LN2;return a.smoothstep(S[0]+L,S[1]+L,h)}const qa=1/4e4;function af(y,h){const f=a.clamp(h.lat,-a.MAX_MERCATOR_LATITUDE,a.MAX_MERCATOR_LATITUDE),v=new a.LngLat(h.lng-180*qa,f),w=new a.LngLat(h.lng+180*qa,f),S=y.project(v.lng,f),I=y.project(w.lng,f),L=a.MercatorCoordinate.fromLngLat(v),z=a.MercatorCoordinate.fromLngLat(w),H=I.x-S.x,q=I.y-S.y,ee=z.x-L.x,de=z.y-L.y,_e=Math.sqrt((ee*ee+de*de)/(H*H+q*q));return Math.log(_e)/Math.LN2}function lc(y,h,f){const v=Math.cos(f),w=Math.sin(f);return{x:y*v-h*w,y:y*w+h*v}}class tl{constructor(h,f,v,w,S,I,L){this.tileSize=512,this._renderWorldCopies=S===void 0||S,this._minZoom=h||0,this._maxZoom=f||22,this._minPitch=v??0,this._maxPitch=w??60,this.setProjection(I),this.setMaxBounds(L),this.width=0,this.height=0,this._center=new a.LngLat(0,0),this.zoom=0,this.angle=0,this._fov=.6435011087932844,this._pitch=0,this._nearZ=0,this._farZ=0,this._unmodified=!0,this._edgeInsets=new cs,this._projMatrixCache={},this._alignedProjMatrixCache={},this._fogTileMatrixCache={},this._distanceTileDataCache={},this._camera=new Ou,this._centerAltitude=0,this._averageElevation=0,this.cameraElevationReference="ground",this._pixelsPerMercatorPixel=1,this.globeRadius=0,this.globeCenterInViewSpace=[0,0,0],this._horizonShift=.1}
1423clone(){const h=new tl(this._minZoom,this._maxZoom,this._minPitch,this.maxPitch,this._renderWorldCopies,this.getProjection());return h._elevation=this._elevation,h._centerAltitude=this._centerAltitude,h._centerAltitudeValidForExaggeration=this._centerAltitudeValidForExaggeration,h.tileSize=this.tileSize,h.mercatorFromTransition=this.mercatorFromTransition,h.width=this.width,h.height=this.height,h.cameraElevationReference=this.cameraElevationReference,h._center=this._center,h._setZoom(this.zoom),h._seaLevelZoom=this._seaLevelZoom,h.angle=this.angle,h._fov=this._fov,h._pitch=this._pitch,h._nearZ=this._nearZ,h._farZ=this._farZ,h._averageElevation=this._averageElevation,h._unmodified=this._unmodified,h._edgeInsets=this._edgeInsets.clone(),h._camera=this._camera.clone(),h._calcMatrices(),h.freezeTileCoverage=this.freezeTileCoverage,h.frustumCorners=this.frustumCorners,h}get elevation(){return this._elevation}set elevation(h){this._elevation!==h&&(this._elevation=h,this._updateCameraOnTerrain(),this._calcMatrices())}updateElevation(h,f=!1){const v=this._elevation&&this._elevation.exaggeration()!==this._centerAltitudeValidForE
1423xaggeration;(this._seaLevelZoom==null||v)&&this._updateCameraOnTerrain(),(h||v)&&this._constrainCamera(f),this._calcMatrices()}getProjection(){return a.pick(this.projection,["name","center","parallels"])}setProjection(h){this.projectionOptions=h||{name:"mercator"};const f=this.projection?this.getProjection():void 0;this.projection=a.getProjection(this.projectionOptions);const v=!m(f,this.getProjection());return v&&this._calcMatrices(),this.mercatorFromTransition=!1,v}setMercatorFromTransition(){const h=this.projection.name;this.mercatorFromTransition=!0,this.projectionOptions={name:"mercator"},this.projection=a.getProjection({name:"mercator"});const f=h!==this.projection.name;return f&&this._calcMatrices(),f}get minZoom(){return this._minZoom}set minZoom(h){this._minZoom!==h&&(this._minZoom=h,this.zoom=Math.max(this.zoom,h))}get maxZoom(){return this._maxZoom}set maxZoom(h){this._maxZoom!==h&&(this._maxZoom=h,this.zoom=Math.min(this.zoom,h))}get minPitch(){return this._minPitch}set minPitch(h){this._minPitch!==h&&(this._minPitch=h,this.pitch=Math.max(this.pitch,h))}get maxPitch(){return this._maxPitch}set maxPitch(h){this._maxPitch!==h&&(this._maxPitch=h,this.pitch=Math.min(this.pitch,h))}get renderWorldCopies(){return this._renderWorldCopies&&this.projection.supportsWorldCopies===!0}set renderWorldCopies(h){h===void 0?h=!0:h===null&&(h=!1),this._renderWorldCopies=h}get worldSize(){return this.tileSize*this.scale}get cameraWorldSizeForFog(){const h=Math.max(this._camera.getDistanceToElevation(this._averageElevation),Number.EPSILON);return this._worldSizeFromZoom(this._zoomFromMercatorZ(h))}get cameraWorldSize(){const h=Math.max(this._camera.getDistanceToElevation(this._averageElevation,!0),Number.EPSILON);return this._worldSizeFromZoom(this._zoomFromMercatorZ(h))}get pixelsPerMeter(){return this.projection.pixelsPerMeter(this.center.lat,this.worldSize)}get cameraPixelsPerMeter(){return a.mercatorZfromAltitude(this.center.lat,this.cameraWorldSizeForFog)}get centerOffset(){return this.centerPoint._sub(this.size._div(2))}get size(){return new a.Point(this.width,this.height)}get bearing(){return a.wrap(this.rotation,-180,180)}set bearing(h){this.rotation=h}get rotation(){return-this.angle/Math.PI*180}set rotation(h){const f=-h*Math.PI/180;var v;this.angle!==f&&(this._unmodified=!1,this.angle=f,this._calcMatrices(),this.rotationMatrix=(v=new a.ARRAY_TYPE(4),a.ARRAY_TYPE!=Float32Array&&(v[1]=0,v[2]=0),v[0]=1,v[3]=1,v),function(w,S,I){var L=S[0],z=S[1],H=S[2],q=S[3],ee=Math.sin(I),de=Math.cos(I);w[0]=L*de+H*ee,w[1]=z*de+q*ee,w[2]=L*-ee+H*de,w[3]=z*-ee+q*de}(this.rotationMatrix,this.rotationMatrix,this.angle))}get pitch(){return this._pitch/Math.PI*180}set pitch(h){const f=a.clamp(h,this.minPitch,this.maxPitch)/180*Math.PI;this._pitch!==f&&(this._unmodified=!1,this._pitch=f,this._calcMatrices())}get aspect(){return this.width/this.height}get fov(){return this._fov/Math.PI*180}get fovX(){return this._fov}get fovY(){const h=1/Math.tan(.5*this.fovX);return 2*Math.atan(1/this.aspect/h)}set fov(h){h=Math.max(.01,Math.min(60,h)),this._fov!==h&&(this._unmodified=!1,this._fov=a.degToRad(h),this._calcMatrices())}get averageElevation(){return this._averageElevation}set averageElevation(h){this._averageElevation=h,this._calcFogMatrices(),this._distanceTileDataCache={}}get zoom(){return this._zoom}set zoom(h){const f=Math.min(Math.max(h,this.minZoom),this.maxZoom);this._zoom!==f&&(this._unmodified=!1,this._setZoom(f),this._updateSeaLevelZoom(),this._constrain(),this._calcMatrices())}_setZoom(h){this._zoom=h,this.scale=this.zoomScale(h),this.tileZoom=Math.floor(h),this.zoomFraction=h-this.tileZoom}_updateCameraOnTerrain(){if(!this._elevation||!this._elevation.isDataAvailableAtPoint(this.locationCoordinate(this.center)))return this._centerAltitude=0,this._seaLevelZoom=null,void(this._centerAltitudeValidForE
vendor: 6,013 bytes, line 1423
1423xaggeration=void 0);const h=this._elevation;this._centerAltitude=h.getAtPointOrZero(this.locationCoordinate(this.center)),this._centerAltitudeValidForExaggeration=h.exaggeration(),this._updateSeaLevelZoom()}_updateSeaLevelZoom(){this._centerAltitudeValidForExaggeration!==void 0&&(this._seaLevelZoom=this._zoomFromMercatorZ((this.pixelsPerMeter*this._centerAltitude+this.cameraToCenterDistance)/this.worldSize))}sampleAverageElevation(){if(!this._elevation)return 0;const h=this._elevation,f=[[.5,.2],[.3,.5],[.5,.5],[.7,.5],[.5,.8]],v=this.horizonLineFromTop();let w=0,S=0;for(let I=0;I<f.length;I++){const L=new a.Point(f[I][0]*this.width,v+f[I][1]*(this.height-v)),z=h.pointCoordinate(L);if(!z)continue;const H=1/Math.hypot(z[0]-this._camera.position[0],z[1]-this._camera.position[1]);w+=z[3]*H,S+=H}return S===0?NaN:w/S}get center(){return this._center}set center(h){h.lat===this._center.lat&&h.lng===this._center.lng||(this._unmodified=!1,this._center=h,this._terrainEnabled()&&(this.cameraElevationReference==="ground"?this._updateCameraOnTerrain():this._updateZoomFromElevation()),this._constrain(),this._calcMatrices())}_updateZoomFromElevation(){if(this._seaLevelZoom==null||!this._elevation)return;const h=this._seaLevelZoom,f=this._elevation.getAtPointOrZero(this.locationCoordinate(this.center)),v=this.pixelsPerMeter/this.worldSize*f,w=this._mercatorZfromZoom(h),S=this._mercatorZfromZoom(this._maxZoom),I=Math.max(w-v,S);this._setZoom(this._zoomFromMercatorZ(I))}get padding(){return this._edgeInsets.toJSON()}set padding(h){this._edgeInsets.equals(h)||(this._unmodified=!1,this._edgeInsets.interpolate(this._edgeInsets,h,1),this._calcMatrices())}computeZoomRelativeTo(h){const f=this.rayIntersectionCoordinate(this.pointRayIntersection(this.centerPoint,h.toAltitude()));let v;v=h.z<this._camera.position[2]?[f.x,f.y,f.z]:[h.x,h.y,h.z];const w=a.length(a.sub([],this._camera.position,v));return a.clamp(this._zoomFromMercatorZ(w),this._minZoom,this._maxZoom)}setFreeCameraOptions(h){if(!this.height||!h.position&&!h.orientation)return;this._updateCameraState();let f=!1;if(h.orientation&&!a.exactEquals(h.orientation,this._camera.orientation)&&(f=this._setCameraOrientation(h.orientation)),h.position){const v=[h.position.x,h.position.y,h.position.z];a.exactEquals$1(v,this._camera.position)||(this._setCameraPosition(v),f=!0)}f&&(this._updateStateFromCamera(),this.recenterOnTerrain())}getFreeCameraOptions(){this._updateCameraState();const h=this._camera.position,f=new Ml;return f.position=new a.MercatorCoordinate(h[0],h[1],h[2]),f.orientation=this._camera.orientation,f._elevation=this.elevation,f._renderWorldCopies=this.renderWorldCopies,f}_setCameraOrientation(h){if(!a.length$1(h))return!1;a.normalize$1(h,h);const f=a.transformQuat([],[0,0,-1],h),v=a.transformQuat([],[0,-1,0],h);if(v[2]<0)return!1;const w=Es(f,v);return!!w&&(this._camera.orientation=w,!0)}_setCameraPosition(h){const f=this.zoomScale(this.minZoom)*this.tileSize,v=this.zoomScale(this.maxZoom)*this.tileSize,w=this.cameraToCenterDistance;h[2]=a.clamp(h[2],w/v,w/f),this._camera.position=h}get centerPoint(){return this._edgeInsets.getCenter(this.width,this.height)}get fovAboveCenter(){return this._fov*(.5+this.centerOffset.y/this.height)}isPaddingEqual(h){return this._edgeInsets.equals(h)}interpolatePadding(h,f,v){this._unmodified=!1,this._edgeInsets.interpolate(h,f,v),this._constrain(),this._calcMatrices()}coveringZoomLevel(h){const f=(h.roundZoom?Math.round:Math.floor)(this.zoom+this.scaleZoom(this.tileSize/h.tileSize));return Math.max(0,f)}getVisibleUnwrappedCoordinates(h){const f=[new a.UnwrappedTileID(0,h)];if(this.renderWorldCopies){const v=this.pointCoordinate(new a.Point(0,0)),w=this.pointCoordinate(new a.Point(this.width,0)),S=this.pointCoordinate(new a.Point(this.width,this.height)),I=this.pointCoordinate(new a.Point(0,this.height)),L=Math.floor(Math.min(v.x,w.x,S.x,I.x)),z=Math.floor(Math.max(v.x,w.x,S.x,I.x)),H=1;for(let q=L-H;q<=z+H;q++)q!==0&&f.push(new a.UnwrappedTileID(q,h))}return f}coveringTiles(h){let f=this.coveringZoomLevel(h);const v=f,w=this.elevation&&!h.isTerrainDEM,S=this.projection.name==="mercator";if(h.minzoom!==void 0&&f<h.minzoom)return[];h.maxzoom!==void 0&&f>h.maxzoom&&(f=h.maxzoom);const I=this.locationCoordinate(this.center),L=this.center.lat,z=1<<f,H=[z*I.x,z*I.y,0],q=this.projection.name==="globe",ee=!q,de=a.Frustum.fromInvProjectionMatrix(this.invProjMatrix,this.worldSize,f,ee),_e=q?this._camera.mercatorPosition:this.pointCoordinate(this.getCameraPoint()),be=z*a.mercatorZfromAltitude(1,this.center.lat),ve=this._camera.position[2]/a.mercatorZfromAltitude(1,this.center.lat),Ee=[z*_e.x,z*_e.y,ve*(ee?1:be)],te=this.cameraToCenterDistance/h.tileSize*(h.roundZoom?1:.502),ye=this.pitch<=60&&this._edgeInsets.top<=this._edgeInsets.bottom&&!this._elevation&&!this.projection.isReprojectedInTileSpace?f:0,Oe=h.isTerrainDEM&&this._elevation?1e4*this._elevation.exaggeration():this._centerAltitude,Le=h.isTerrainDEM?-Oe:this._elevation?this._elevation.getMinElevationBelowMSL():0,He=this.projection.isReprojectedInTileSpace?Th(this):1,Ze=gt=>{const Jt=new a.MercatorCoordinate(gt.x+25e-6,gt.y,gt.z),Ut=new a.MercatorCoordinate(gt.x,gt.y+25e-6,gt.z),tn=gt.toLngLat(),Mn=Jt.toLngLat(),Wn=Ut.toLngLat(),wn=this.locationCoordinate(tn),Bn=this.locationCoordinate(Mn),mr=this.locationCoordinate(Wn),pr=Math.hypot(Bn.x-wn.x,Bn.y-wn.y),Cn=Math.hypot(mr.x-wn.x,mr.y-wn.y);return Math.sqrt(pr*Cn)*He/25e-6},Ye=gt=>{const Ft=Oe,Jt=Le;return{aabb:a.tileAABB(this,z,0,0,0,gt,Jt,Ft,this.projection),zoom:0,x:0,y:0,minZ:Jt,maxZ:Ft,wrap:gt,fullyVisible:!1}},ot=[];let et=[];const _t=f,Zt=h.reparseOverscaled?v:f,dt=gt=>gt*gt,Bt=dt((ve-this._centerAltitude)*be),St=gt=>{if(!this._elevation||!gt.tileID||!S)return;const Ft=this._elevation.getMinMaxForTile(gt.tileID),Jt=gt.aabb;Ft?(Jt.min[2]=Ft.min,Jt.max[2]=Ft.max,Jt.center[2]=(Jt.min[2]+Jt.max[2])/2):(gt.shouldSplit=Yt(gt),gt.shouldSplit||(Jt.min[2]=Jt.max[2]=Jt.center[2]=this._centerAltitude))},Yt=gt=>{if(gt.zoom<ye)return!0;
1423if(gt.zoom===_t)return!1;if(gt.shouldSplit!=null)return gt.shouldSplit;const Ft=gt.aabb.distanceX(Ee),Jt=gt.aabb.distanceY(Ee);let Ut=Bt,tn=1;if(q){Ut=dt(gt.aabb.distanceZ(Ee));const wn=Math.pow(2,gt.zoom),Bn=a.latFromMercatorY((gt.y+1)/wn),mr=a.latFromMercatorY(gt.y/wn),pr=Math.min(Math.max(L,Bn),mr),Cn=a.circumferenceAtLatitude(pr)/a.circumferenceAtLatitude(L);if(tn=pr===L?1/Math.max(1,this._mercatorScaleRatio-.3):Math.min(1,Cn/this._mercatorScaleRatio),this.zoom<=a.GLOBE_ZOOM_THRESHOLD_MIN&&gt.zoom===_t-1&&Cn>=.9)return!0}else if(w&&(Ut=dt(gt.aabb.distanceZ(Ee)*be)),this.projection.isReprojectedInTileSpace&&v<=5){const wn=Math.pow(2,gt.zoom),Bn=Ze(new a.MercatorCoordinate((gt.x+.5)/wn,(gt.y+.5)/wn));tn=Bn>.85?1:Bn}const Mn=Ft*Ft+Jt*Jt+Ut,Wn=dt((1<<_t-gt.zoom)*te*tn*((wn,Bn)=>{if(Bn*dt(.707)<wn)return 1;const mr=Math.sqrt(Bn/wn);return mr/(1.4144271570014144+(Math.pow(1.1,mr-1.4144271570014144+1)-1)/(1.1-1)-1)})(Math.max(Ut,Bt),Mn));return Mn<Wn};if(this.renderWorldCopies)for(let gt=1;gt<=3;gt++)ot.push(Ye(-gt)),ot.push(Ye(gt));for(ot.push(Ye(0));ot.length>0;){const gt=ot.pop(),Ft=gt.x,Jt=gt.y;let Ut=gt.fullyVisible;if(!Ut){const tn=gt.aabb.intersects(de);if(tn===0)continue;Ut=tn===2}if(gt.zoom!==_t&&Yt(gt))for(let tn=0;tn<4;tn++){const Mn=(Ft<<1)+tn%2,Wn=(Jt<<1)+(tn>>1),wn={aabb:S?gt.aabb.quadrant(tn):a.tileAABB(this,z,gt.zoom+1,Mn,Wn,gt.wrap,gt.minZ,gt.maxZ,this.projection),zoom:gt.zoom+1,x:Mn,y:Wn,wrap:gt.wrap,fullyVisible:Ut,tileID:void 0,shouldSplit:void 0,minZ:gt.minZ,maxZ:gt.maxZ};w&&!q&&(wn.tileID=new a.OverscaledTileID(gt.zoom+1===_t?Zt:gt.zoom+1,gt.wrap,gt.zoom+1,Mn,Wn),St(wn)),ot.push(wn)}else{const tn=gt.zoom===_t?Zt:gt.zoom;if(h.minzoom&&h.minzoom>tn)continue;const Mn=H[0]-(.5+Ft+(gt.wrap<<gt.zoom))*(1<<f-gt.zoom),Wn=H[1]-.5-Jt,wn=gt.tileID?gt.tileID:new a.OverscaledTileID(tn,gt.wrap,gt.zoom,Ft,Jt);et.push({tileID:wn,distanceSq:Mn*Mn+Wn*Wn})}}if(this.fogCullDistSq){const gt=this.fogCullDistSq,Ft=this.horizonLineFromTop();et=et.filter(Jt=>{const Ut=[0,0,0,1],tn=[a.EXTENT,a.EXTENT,0,1],Mn=this.calculateFogTileMatrix(Jt.tileID.toUnwrapped());a.transformMat4$1(Ut,Ut,Mn),a.transformMat4$1(tn,tn,Mn);const Wn=a.getAABBPointSquareDist(Ut,tn);if(Wn===0)return!0;let wn=!1;const Bn=this._elevation;if(Bn&&Wn>gt&&Ft!==0){const mr=this.calculateProjMatrix(Jt.tileID.toUnwrapped());let pr;h.isTerrainDEM||(pr=Bn.getMinMaxForTile(Jt.tileID)),pr||(pr={min:Le,max:Oe});const Cn=a.furthestTileCorner(this.rotation),Nr=[Cn[0]*a.EXTENT,Cn[1]*a.EXTENT,pr.max];a.transformMat4(Nr,Nr,mr),wn=(1-Nr[1])*this.height*.5<Ft}return Wn<gt||wn})}return et.sort((gt,Ft)=>gt.distanceSq-Ft.distanceSq).map(gt=>gt.tileID)}resize(h,f){this.width=h,this.height=f,this.pixelsToGLUnits=[2/h,-2/f],this._constrain(),this._calcMatrices()}get unmodified(){return this._unmodified}zoomScale(h){return Math.pow(2,h)}scaleZoom(h){return Math.log(h)/Math.LN2}project(h){const f=a.clamp(h.lat,-a.MAX_MERCATOR_LATITUDE,a.MAX_MERCATOR_LATITUDE),v=this.projection.project(h.lng,f);return new a.Point(v.x*this.worldSize,v.y*this.worldSize)}unproject(h){return this.projection.unproject(h.x/this.worldSize,h.y/this.worldSize)}get point(){return this.project(this.center)}get pointMerc(){return this.point._div(this.worldSize)}get pixelsPerMeterRatio(){return this.pixelsPerMeter/a.mercatorZfromAltitude(1,this.center.lat)/this.worldSize}setLocationAtPoint(h,f){let v,w;const S=this.centerPoint;if(this.projection.name==="globe"){const L=this.worldSize;v=(f.x-S.x)/L,w=(f.y-S.y)/L}else{const L=this.pointCoordinate(f),z=this.pointCoordinate(S);v=L.x-z.x,w=L.y-z.y}const I=this.locationCoordinate(h);this.setLocation(new a.MercatorCoordinate(I.x-v,I.y-w))}setLocation(h){this.center=this.coordinateLocation(h),this.projection.wrap&&(this.center=this.center.wrap())}locationPoint(h){return this.projection.locationPoint(this,h)}locationPoint3D(h){return this.projection.locationPoint(this,h,!0)}pointLocation(h){return this.coordinateLocation(this.pointCoordinate(h))}pointLocation3D(h){return this.coordinateLocation(this.pointCoordinate3D(h))}locationCoordinate(h,f){const v=f?a.mercatorZfromAltitude(f,h.lat):void 0,w=this.projection.project(h.lng,h.lat);return new a.MercatorCoordinate(w.x,w.y,v)}coordinateLocation(h){return this.projection.unproject(h.x,h.y)}pointRayIntersection(h,f){const v=f??this._centerAltitude,w=[h.x,h.y,0,1],S=[h.x,h.y,1,1];a.transformMat4$1(w,w,this.pixelMatrixInverse),a.transformMat4$1(S,S,this.pixelMatrixInverse);const I=S[3];a.scale$1(w,w,1/w[3]),a.scale$1(S,S,1/I);const L=w[2],z=S[2];return{p0:w,p1:S,t:L===z?0:(v-L)/(z-L)}}screenPointToMercatorRay(h){const f=[h.x,h.y,0,1],v=[h.x,h.y,1,1];return a.transformMat4$1(f,f,this.pixelMatrixInverse),a.transformMat4$1(v,v,this.pixelMatrixInverse),a.scale$1(f,f,1/f[3]),a.scale$1(v,v,1/v[3]),f[2]=a.mercatorZfromAltitude(f[2],this._center.lat)*this.worldSize,v[2]=a.mercatorZfromAltitude(v[2],this._center.lat)*this.worldSize,a.scale$1(f,f,1/this.worldSize),a.scale$1(v,v,1/this.worldSize),new a.Ray([f[0],f[1],f[2]],a.normalize([],a.sub([],v,f)))}rayIntersectionCoordinate(h){const{p0:f,p1:v,t:w}=h,S=a.mercatorZfromAltitude(f[2],this._center.lat),I=a.mercatorZfromAltitude(v[2],this._center.lat);return new a.MercatorCoordinate(a.number(f[0],v[0],w)/this.worldSize,a.number(f[1],v[1],w)/this.worldSize,a.number(S,I,w))}pointCoordinate(h,f=this._centerAltitude){return this.projection.pointCoordinate(this,h.x,h.y,f)}pointCoordinate3D(h){if(!this.elevation)return this.pointCoordinate(h);let f=this.projection.pointCoordinate3D(this,h.x,h.y);if(f)return new a.MercatorCoordinate(f[0],f[1],f[2]);let v=0,w=this.horizonLineFromTop();if(h.y>w)return this.pointCoordinate(h);const S=.02*w,I=h.clone();for(let L=0;L<10&&w-v>S;L++){I.y=a.number(v,w,.66);const z=this.projection.pointCoordinate3D(this,I.x,I.y);z?(w=I.y,f=z):v=I.y}return f?new a.MercatorCoordinate(f[0],f[1],f[2]):this.pointCoordinate(h)}isPointAboveHorizon(h){return this.projection.isPointAboveHorizon(this,h)}isPointOnSurface(h){if(h.y<0||h.y>this.height||h.x<0||h.x>this.width)return!1;if(this.elevation||this.zoom>=a.GLOBE_ZOOM_THRESHOLD_MAX)return!this.isPointAboveHorizon(h);const f=this.pointCoordinate(h);return f.y>=0&&f.y<=1}_coordinatePoint(h,f){const v=f&&this.elevation?this.elevation.getAtPointOrZero(h,this._centerAltitude):this._centerAltitude,w=[h.x*this.worldSize,h.y*this.worldSize,v+h.toAltitude(),1];return a.transformMat4$1(w,w,this.pixelMatrix),w[3]>
14230?new a.Point(w[0]/w[3],w[1]/w[3]):new a.Point(Number.MAX_VALUE,Number.MAX_VALUE)}_getBoundsNonRectangular(){const{top:h,left:f}=this._edgeInsets,v=this.height-this._edgeInsets.bottom,w=this.width-this._edgeInsets.right,S=this.pointLocation3D(new a.Point(f,h)),I=this.pointLocation3D(new a.Point(w,h)),L=this.pointLocation3D(new a.Point(w,v)),z=this.pointLocation3D(new a.Point(f,v));let H=Math.min(S.lng,I.lng,L.lng,z.lng),q=Math.max(S.lng,I.lng,L.lng,z.lng),ee=Math.min(S.lat,I.lat,L.lat,z.lat),de=Math.max(S.lat,I.lat,L.lat,z.lat);const _e=Math.pow(2,-this.zoom)/16*270,be=this.projection.name==="globe"?1:4,ve=(Ee,te,ye,Oe,Le)=>{const He=(Ee+ye)/2,Ze=(te+Oe)/2,Ye=new a.Point(He,Ze),{lng:ot,lat:et}=this.pointLocation3D(Ye),_t=Math.max(0,H-ot,ee-et,ot-q,et-de);H=Math.min(H,ot),q=Math.max(q,ot),ee=Math.min(ee,et),de=Math.max(de,et),(Le<be||_t>_e)&&(ve(Ee,te,He,Ze,Le+1),ve(He,Ze,ye,Oe,Le+1))};if(ve(f,h,w,h,1),ve(w,h,w,v,1),ve(w,v,f,v,1),ve(f,v,f,h,1),this.projection.name==="globe"){const[Ee,te]=a.polesInViewport(this);Ee?(de=90,q=180,H=-180):te&&(ee=-90,q=180,H=-180)}return new a.LngLatBounds(new a.LngLat(H,ee),new a.LngLat(q,de))}_getBoundsRectangular(h,f){const{top:v,left:w}=this._edgeInsets,S=this.height-this._edgeInsets.bottom,I=this.width-this._edgeInsets.right,L=new a.Point(w,v),z=new a.Point(I,v),H=new a.Point(I,S),q=new a.Point(w,S);let ee=this.pointCoordinate(L,h),de=this.pointCoordinate(z,h);const _e=this.pointCoordinate(H,f),be=this.pointCoordinate(q,f),ve=(Ee,te)=>(te.y-Ee.y)/(te.x-Ee.x);return ee.y>1&&de.y>=0?ee=new a.MercatorCoordinate((1-be.y)/ve(be,ee)+be.x,1):ee.y<0&&de.y<=1&&(ee=new a.MercatorCoordinate(-be.y/ve(be,ee)+be.x,0)),de.y>1&&ee.y>=0?de=new a.MercatorCoordinate((1-_e.y)/ve(_e,de)+_e.x,1):de.y<0&&ee.y<=1&&(de=new a.MercatorCoordinate(-_e.y/ve(_e,de)+_e.x,0)),new a.LngLatBounds().extend(this.coordinateLocation(ee)).extend(this.coordinateLocation(de)).extend(this.coordinateLocation(be)).extend(this.coordinateLocation(_e))}_getBoundsRectangularTerrain(){const h=this.elevation;if(!h.visibleDemTiles.length||h.isUsingMockSource())return this._getBoundsRectangular(0,0);const f=h.visibleDemTiles.reduce((v,w)=>{if(w.dem){const S=w.dem.tree;v.min=Math.min(v.min,S.minimums[0]),v.max=Math.max(v.max,S.maximums[0])}return v},{min:Number.MAX_VALUE,max:0});return this._getBoundsRectangular(f.min*h.exaggeration(),f.max*h.exaggeration())}getBounds(){return this.projection.name==="mercator"||this.projection.name==="equirectangular"?this._terrainEnabled()?this._getBoundsRectangularTerrain():this._getBoundsRectangular(0,0):this._getBoundsNonRectangular()}horizonLineFromTop(h=!0){const f=this.height/2/Math.tan(this._fov/2)/Math.tan(Math.max(this._pitch,.1))+this.centerOffset.y,v=this.height/2-f*(1-this._horizonShift);return h?Math.max(0,v):v}getMaxBounds(){return this.maxBounds}setMaxBounds(h){this.maxBounds=h,this.minLat=-a.MAX_MERCATOR_LATITUDE,this.maxLat=a.MAX_MERCATOR_LATITUDE,this.minLng=-180,this.maxLng=180,h&&(this.minLat=h.getSouth(),this.maxLat=h.getNorth(),this.minLng=h.getWest(),this.maxLng=h.getEast(),this.maxLng<this.minLng&&(this.maxLng+=360)),this.worldMinX=a.mercatorXfromLng(this.minLng)*this.tileSize,this.worldMaxX=a.mercatorXfromLng(this.maxLng)*this.tileSize,this.worldMinY=a.mercatorYfromLat(this.maxLat)*this.tileSize,this.worldMaxY=a.mercatorYfromLat(this.minLat)*this.tileSize,this._constrain()}calculatePosMatrix(h,f){return this.projection.createTileMatrix(this,f,h)}calculateDistanceTileData(h){const f=h.key,v=this._distanceTileDataCache;if(v[f])return v[f];const w=h.canonical,S=1/this.height,I=this.cameraWorldSize,L=I/this.zoomScale(w.z),z=(w.x+Math.pow(2,w.z)*h.wrap)*L,H=w.y*L,q=this.point;q.x*=I/this.worldSize,q.y*=I/this.worldSize;const ee=this.angle,de=Math.sin(-ee),_e=-Math.cos(-ee);return v[f]={bearing:[de,_e],center:[(q.x-z)*S,(q.y-H)*S],scale:L/a.EXTENT*S},v[f]}calculateFogTileMatrix(h){const f=h.key,v=this._fogTileMatrixCache;if(v[f])return v[f];const w=this.projection.createTileMatrix(this,this.cameraWorldSizeForFog,h);return a.multiply(w,this.worldToFogMatrix,w),v[f]=new Float32Array(w),v[f]}calculateProjMatrix(h,f=!1){const v=h.key,w=f?this._alignedProjMatrixCache:this._projMatrixCache;if(w[v])return w[v];const S=this.calculatePosMatrix(h,this.worldSize);return a.multiply(S,this.projection.isReprojectedInTileSpace?this.mercatorMatrix:f?this.alignedProjMatrix:this.projMatrix,S),w[v]=new Float32Array(S),w[v]}calculatePixelsToTileUnitsMatrix(h){const f=h.tileID.key,v=this._pixelsToTileUnitsCache;if(v[f])return v[f];const w=function(S,I){const{scale:L}=S.tileTransform,z=L*a.EXTENT/(S.tileSize*Math.pow(2,I.zoom-S.tileID.overscaledZ+S.tileID.canonical.z));return H=new Float32Array(4),de=(q=I.inverseAdjustmentMatrix)[1],_e=q[2],be=q[3],Ee=(ee=[z,z])[1],H[0]=q[0]*(ve=ee[0]),H[1]=de*ve,H[2]=_e*Ee,H[3]=be*Ee,H;var H,q,ee,de,_e,be,ve,Ee}(h,this);return v[f]=w,v[f]}customLayerMatrix(){return this.mercatorMatrix.slice()}globeToMercatorMatrix(){if(this.projection.name==="globe"){const h=1/this.worldSize,f=a.fromScaling([],[h,h,h]);return a.multiply(f,f,this.globeMatrix),f}}recenterOnTerrain(){if(!this._elevation||this.projection.name==="globe")return;const h=this._elevation;this._updateCameraState();const f=a.mercatorZfromAltitude(1,this._center.lat)*this.worldSize,v=this._computeCameraPosition(f),w=this._camera.forward(),S=a.mercatorZfromAltitude(1,this._center.lat);v[2]/=S,w[2]/=S,a.normalize(w,w);const I=h.raycast(v,w,h.exaggeration());if(I){const L=a.scaleAndAdd([],v,w,I),z=new a.MercatorCoordinate(L[0],L[1],a.mercatorZfromAltitude(L[2],a.latFromMercatorY(L[1]))),H=(z.z+a.length([z.x-v[0],z.y-v[1],z.z-v[2]*S]))*this._pixelsPerMercatorPixel;this._seaLevelZoom=this._zoomFromMercatorZ(H),this._centerAltitude=z.toAltitude(),this._center=this.coordinateLocation(z),this._updateZoomFromElevation(),this._constrain(),this._calcMatrices()}}_constrainCamera(h=!1){if(!this._elevation)return;const f=this._elevation,v=a.mercatorZfromAltitude(1,this._center.lat)*this.worldSize,w=this._computeCameraPosition(v),S=f.getAtPointOrZero(new a.MercatorCoordinate(...w)),I=this.pixelsPerMeter/this.worldSize*S,L=this._minimumHeightOverTerrain(),z=w[2]-I;if(z<=L)if(z<0||h){const H=this.locationCoordinate(this._center,this._centerAltitude),q=[w[0],w[1],H.z-w[2]],ee=a.length(q);q[2]-=(L-z)/this._pixelsPerMercatorPixel;const de=a.length(q);
1423if(de===0)return;a.scale$2(q,q,ee/de*this._pixelsPerMercatorPixel),this._camera.position=[w[0],w[1],H.z*this._pixelsPerMercatorPixel-q[2]],this._updateStateFromCamera()}else this._isCameraConstrained=!0}_constrain(){if(!this.center||!this.width||!this.height||this._constraining)return;this._constraining=!0;const h=this.projection.name==="globe"||this.mercatorFromTransition;if(this.projection.isReprojectedInTileSpace||h){const de=this.center;return de.lat=a.clamp(de.lat,this.minLat,this.maxLat),(this.maxBounds||!this.renderWorldCopies&&!h)&&(de.lng=a.clamp(de.lng,this.minLng,this.maxLng)),this.center=de,void(this._constraining=!1)}const f=this._unmodified,{x:v,y:w}=this.point;let S=0,I=v,L=w;const z=this.width/2,H=this.height/2,q=this.worldMinY*this.scale,ee=this.worldMaxY*this.scale;if(w-H<q&&(L=q+H),w+H>ee&&(L=ee-H),ee-q<this.height&&(S=Math.max(S,this.height/(ee-q)),L=(ee+q)/2),this.maxBounds||!this._renderWorldCopies||!this.projection.wrap){const de=this.worldMinX*this.scale,_e=this.worldMaxX*this.scale,be=this.worldSize/2-(de+_e)/2;I=(v+be+this.worldSize)%this.worldSize-be,I-z<de&&(I=de+z),I+z>_e&&(I=_e-z),_e-de<this.width&&(S=Math.max(S,this.width/(_e-de)),I=(_e+de)/2)}I===v&&L===w||(this.center=this.unproject(new a.Point(I,L))),S&&(this.zoom+=this.scaleZoom(S)),this._constrainCamera(),this._unmodified=f,this._constraining=!1}_minZoomForBounds(){let h=Math.max(0,this.scaleZoom(this.height/(this.worldMaxY-this.worldMinY)));return this.maxBounds&&(h=Math.max(h,this.scaleZoom(this.width/(this.worldMaxX-this.worldMinX)))),h}_maxCameraBoundsDistance(){return this._mercatorZfromZoom(this._minZoomForBounds())}_calcMatrices(){if(!this.height)return;const h=this.centerOffset,f=this.pixelsPerMeter;this.projection.name==="globe"&&(this._mercatorScaleRatio=a.mercatorZfromAltitude(1,this.center.lat)/a.mercatorZfromAltitude(1,a.GLOBE_SCALE_MATCH_LATITUDE));const v=sc(this.projection,this.zoom,this.width,this.height,1024);this._pixelsPerMercatorPixel=this.projection.pixelSpaceConversion(this.center.lat,this.worldSize,v),this.cameraToCenterDistance=.5/Math.tan(.5*this._fov)*this.height*this._pixelsPerMercatorPixel,this._updateCameraState(),this._farZ=this.projection.farthestPixelDistance(this),this._nearZ=this.height/50;const w=this.projection.zAxisUnit==="meters"?f:1,S=this._camera.getWorldToCamera(this.worldSize,w),I=this._camera.getCameraToClipPerspective(this._fov,this.width/this.height,this._nearZ,this._farZ);I[8]=2*-h.x/this.width,I[9]=2*h.y/this.height;let L=a.mul([],I,S);if(this.projection.isReprojectedInTileSpace){const Ze=this.locationCoordinate(this.center),Ye=a.identity([]);a.translate(Ye,Ye,[Ze.x*this.worldSize,Ze.y*this.worldSize,0]),a.multiply(Ye,Ye,el(this)),a.translate(Ye,Ye,[-Ze.x*this.worldSize,-Ze.y*this.worldSize,0]),a.multiply(L,L,Ye),this.inverseAdjustmentMatrix=function(ot){const et=el(ot,!0);return Y([],[et[0],et[1],et[4],et[5]])}(this)}else this.inverseAdjustmentMatrix=[1,0,0,1];this.mercatorMatrix=a.scale([],L,[this.worldSize,this.worldSize,this.worldSize/w,1]),this.projMatrix=L,this.invProjMatrix=a.invert(new Float64Array(16),this.projMatrix);const z=a.invert([],I);this.frustumCorners=a.FrustumCorners.fromInvProjectionMatrix(z,this.horizonLineFromTop(),this.height);const H=new Float32Array(16);a.identity(H),a.scale(H,H,[1,-1,1]),a.rotateX(H,H,this._pitch),a.rotateZ(H,H,this.angle);const q=a.perspective(new Float32Array(16),this._fov,this.width/this.height,this._nearZ,this._farZ),ee=(Math.PI/2-this._pitch)*(this.height/this._fov)*this._horizonShift;q[8]=2*-h.x/this.width,q[9]=2*(h.y+ee)/this.height,this.skyboxMatrix=a.multiply(H,q,H);const de=this.point,_e=de.x,be=de.y,ve=this.width%2/2,Ee=this.height%2/2,te=Math.cos(this.angle),ye=Math.sin(this.angle),Oe=_e-Math.round(_e)+te*ve+ye*Ee,Le=be-Math.round(be)+te*Ee+ye*ve,He=new Float64Array(L);if(a.translate(He,He,[Oe>.5?Oe-1:Oe,Le>.5?Le-1:Le,0]),this.alignedProjMatrix=He,L=a.create(),a.scale(L,L,[this.width/2,-this.height/2,1]),a.translate(L,L,[1,-1,0]),this.labelPlaneMatrix=L,L=a.create(),a.scale(L,L,[1,-1,1]),a.translate(L,L,[-1,-1,0]),a.scale(L,L,[2/this.width,2/this.height,1]),this.glCoordMatrix=L,this.pixelMatrix=a.multiply(new Float64Array(16),this.labelPlaneMatr
1423ix,this.projMatrix),this._calcFogMatrices(),this._distanceTileDataCache={},L=a.invert(new Float64Array(16),this.pixelMatrix),!L)throw new Error("failed to invert matrix");if(this.pixelMatrixInverse=L,this.projection.name==="globe"||this.mercatorFromTransition){this.globeMatrix=a.calculateGlobeMatrix(this);const Ze=[this.globeMatrix[12],this.globeMatrix[13],this.globeMatrix[14]];this.globeCenterInViewSpace=a.transformMat4(Ze,Ze,S),this.globeRadius=this.worldSize/2/Math.PI-1}else this.globeMatrix=L;this._projMatrixCache={},this._alignedProjMatrixCache={},this._pixelsToTileUnitsCache={}}_calcFogMatrices(){this._fogTileMatrixCache={};const h=this.cameraWorldSizeForFog,f=this.cameraPixelsPerMeter,v=this._camera.position,w=1/this.height/this._pixelsPerMercatorPixel,S=[h,h,f];a.scale$2(S,S,w),a.scale$2(v,v,-1),a.multiply$2(v,v,S);const I=a.create();a.translate(I,I,v),a.scale(I,I,S),this.mercatorFogMatrix=I,this.worldToFogMatrix=this._camera.getWorldToCameraPosition(h,f,w)}_computeCameraPosition(h){const f=(h=h||this.pixelsPerMeter)/this.pixelsPerMeter,v=this._camera.forward(),w=this.point,S=this._mercatorZfromZoom(this._seaLevelZoom?this._seaLevelZoom:this._zoom)*f-h/this.worldSize*this._centerAltitude;return[w.x/this.worldSize-v[0]*S,w.y/this.worldSize-v[1]*S,h/this.worldSize*this._centerAltitude-v[2]*S]}_updateCameraState(){this.height&&(this._camera.setPitchBearing(this._pitch,this.angle),this._camera.position=this._computeCameraPosition())}_translateCameraConstrained(h){const f=this._maxCameraBoundsDistance()*Math.cos(this._pitch),v=this._camera.position[2],w=h[2];let S=1;this.projection.wrap&&(this.center=this.center.wrap()),w>0&&(S=Math.min((f-v)/w,1)),this._camera.position=a.scaleAndAdd([],this._camera.position,h,S),this._updateStateFromCamera()}_updateStateFromCamera(){const h=this._camera.position,f=this._camera.forward(),{pitch:v,bearing:w}=this._camera.getPitchBearing(),S=a.mercatorZfromAltitude(this._centerAltitude,this.center.lat)*this._pixelsPerMercatorPixel,I=this._mercatorZfromZoom(this._maxZoom)*Math.cos(a.degToRad(this._maxPitch)),L=Math.max((h[2]-S)/Math.cos(v),I),z=this._zoomFromMercatorZ(L);a.scaleAndAdd(h,h,f,L),this._pitch=a.clamp(v,a.degToRad(this.minPitch),a.degToRad(this.maxPitch)),this.angle=a.wrap(w,-Math.PI,Math.PI),this._setZoom(a.clamp(z,this._minZoom,this._maxZoom)),this._updateSeaLevelZoom(),this._center=this.coordinateLocation(new a.MercatorCoordinate(h[0],h[1],h[2])),this._unmodified=!1,this._constrain(),this._calcMatrices()}_worldSizeFromZoom(h){return Math.pow(2,h)*this.tileSize}_mercatorZfromZoom(h){return this.cameraToCenterDistance/this._worldSizeFromZoom(h)}_minimumHeightOverTerrain(){const h=Math.min((this._seaLevelZoom!=null?this._seaLevelZoom:this._zoom)+4,this._maxZoom);return this._mercatorZfromZoom(h)}_zoomFromMercatorZ(h){return this.scaleZoom(this.cameraToCenterDistance/(h*this.tileSize))}zoomFromMercatorZAdjusted(h){let f=0,v=a.GLOBE_ZOOM_THRESHOLD_MAX,w=0,S=1/0;for(;v-f>1e-6&&v>f;){const I=f+.5*(v-f),L=this.tileSize*Math.pow(2,I),z=this.getCameraToCenterDistance(this.projection,I,L),H=this.scaleZoom(z/(h*this.tileSize)),q=Math.abs(I-H);q<S&&(S=q,w=I),I<H?f=I:v=I}return w}_terrainEnabled(){return!(!this._elevation||!this.projection.supportsTerrain&&(a.warnOnce("Terrain is not yet supported with alternate projections. Use mercator or globe to enable terrain."),1))}anyCornerOffEdge(h,f){const v=Math.min(h.x,f.x),w=Math.max(h.x,f.x),S=Math.min(h.y,f.y),I=Math.max(h.y,f.y);if(S<this.horizonLineFromTop(!1))return!0;if(this.projection.name!=="mercator")return!1;const L=[new a.Point(v,S),new a.Point(w,I),new a.Point(v,I),new a.Point(w,S)],z=this.renderWorldCopies?-3:0,H=this.renderWorldCopies?4:1;for(const q of L){const ee=this.pointRayIntersection(q);if(ee.t<0)return!0;const de=this.rayIntersectionCoordinate(ee);if(de.x<z||de.y<0||de.x>H||de.y>1)return!0}return!1}isHorizonVisible(){return this.pitch+a.radToDeg(this.fovAboveCenter)>88||this.anyCornerOffEdge(new a.Point(0,0),new a.Point(this.width,this.height))}zoomDeltaToMovement(h,f){const v=a.length(a.sub([],this._camera.position,h)),w=this._zoomFromMercatorZ(v)+f;return v-this._mercatorZfromZoom(w)}getCameraPoint(){if(this.projection.name==="globe"){const h=function([f,v,w],S){const I=[f,v,w,1];a.transformMat4$1(I,I,S);const L=I[3]=Math.max(I[3],1e-6);return I[0]/=L,I[1]/=L,I[2]/=L,I}([this.globeMatrix[12],this.globeMatrix[13],this.globeMatrix[14]],this.pixelMatrix);return new a.Point(h[0],h[1])}{const h=Math.tan(this._pitch)*(this.cameraToCenterDistance||1);return this.centerPoint.add(new a.Point(0,h))}}getCameraToCenterDistance(h,f=this.zoom,v=this.worldSize){const w=sc(h,f,this.width,this.height,1024),S=h.pixelSpaceConversion(this.center.lat,v,w);return .5/Math.tan(.5*this._fov)*this.height*S}getWorldToCameraMatrix(){const h=this._camera.getWorldToCamera(this.worldSize,this.projection.zAxisUnit==="meters"?this.pixelsPerMeter:1);return this.projection.name==="globe"&&a.multiply(h,h,this.globeMatrix),h}}function Eh(y,h){let f=!1,v=null;const w=()=>{v=null,f&&(y(),v=setTimeout(w,h),f=!1)};return()=>(f=!0,v||w(),v)}class Lg{constructor(h){this._hashName=h&&encodeURIComponent(h),a.bindAll(["_getCurrentHash","_onHashChange","_updateHash"],this),this._updateHash=Eh(this._updateHashUnthrottled.bind(this),300)}addTo(h){return this._map=h,a.window.addEventListener("hashchange",this._onHashChange,!1),h.on("moveend",this._updateHash),this}remove(){return this._map?(this._map.off("moveend",this._updateHash),a.window.removeEventListener("hashchange",this._onHashChange,!1),clearTimeout(this._updateHash()),this._map=void 0,this):this}getHashString(){const h=this._map;if(!h)return"";const f=sf(h);if(this._hashName){const v=this._hashName;let w=!1;const S=a.window.location.hash.slice(1).split("&").map(I=>{const L=I.split("=")[0];return L===v?(w=!0,`${L}=${f}`):I}).filter(I=>I);return w||S.push(`${v}=${f}`),`#${S.join("&")}`}return`#${f}`}_getCurrentHash(){const h=a.window.location.hash.replace("#","");if(this._hashName){let f;return h.split("&").map(v=>
1423v.split("=")).forEach(v=>{v[0]===this._hashName&&(f=v)}),(f&&f[1]||"").split("/")}return h.split("/")}_onHashChange(){const h=this._map;if(!h)return!1;const f=this._getCurrentHash();if(f.length>=3&&!f.some(v=>isNaN(v))){const v=h.dragRotate.isEnabled()&&h.touchZoomRotate.isEnabled()?+(f[3]||0):h.getBearing();return h.jumpTo({center:[+f[2],+f[1]],zoom:+f[0],bearing:v,pitch:+(f[4]||0)}),!0}return!1}_updateHashUnthrottled(){const h=a.window.location.href.replace(/(#.+)?$/,this.getHashString());a.window.history.replaceState(a.window.history.state,null,h)}}function sf(y,h){const f=y.getCenter(),v=Math.round(100*y.getZoom())/100,w=Math.ceil((v*Math.LN2+Math.log(512/360/.5))/Math.LN10),S=Math.pow(10,w),I=Math.round(f.lng*S)/S,L=Math.round(f.lat*S)/S,z=y.getBearing(),H=y.getPitch();let q=h?`/${I}/${L}/${v}`:`${v}/${L}/${I}`;return(z||H)&&(q+="/"+Math.round(10*z)/10),H&&(q+=`/${Math.round(H)}`),q}const lf={linearity:.3,easing:a.bezier(0,0,.3,1)},Fp=a.extend({deceleration:2500,maxSpeed:1400},lf),Bp=a.extend({deceleration:20,maxSpeed:1400},lf),vn=a.extend({deceleration:1e3,maxSpeed:360},lf),nl=a.extend({deceleration:1e3,maxSpeed:90},lf);class Uv{constructor(h){this._map=h,this.clear()}clear(){this._inertiaBuffer=[]}record(h){this._drainInertiaBuffer(),this._inertiaBuffer.push({time:a.exported.now(),settings:h})}_drainInertiaBuffer(){const h=this._inertiaBuffer,f=a.exported.now();for(;h.length>0&&f-h[0].time>160;)h.shift()}_onMoveEnd(h){if(this._map._prefersReducedMotion()||(this._drainInertiaBuffer(),this._inertiaBuffer.length<2))return;const f={zoom:0,bearing:0,pitch:0,pan:new a.Point(0,0),pinchAround:void 0,around:void 0};for(const{settings:S}of this._inertiaBuffer)f.zoom+=S.zoomDelta||0,f.bearing+=S.bearingDelta||0,f.pitch+=S.pitchDelta||0,S.panDelta&&f.pan._add(S.panDelta),S.around&&(f.around=S.around),S.pinchAround&&(f.pinchAround=S.pinchAround);const v=this._inertiaBuffer[this._inertiaBuffer.length-1].time-this._inertiaBuffer[0].time,w={};if(f.pan.mag()){const S=uf(f.pan.mag(),v,a.extend({},Fp,h||{}));w.offset=f.pan.mult(S.amount/f.pan.mag()),w.center=this._map.transform.center,cf(w,S)}if(f.zoom){const S=uf(f.zoom,v,Bp);w.zoom=this._map.transform.zoom+S.amount,cf(w,S)}if(f.bearing){const S=uf(f.bearing,v,vn);w.bearing=this._map.transform.bearing+a.clamp(S.amount,-179,179),cf(w,S)}if(f.pitch){const S=uf(f.pitch,v,nl);w.pitch=this._map.transform.pitch+S.amount,cf(w,S)}if(w.zoom||w.bearing){const S=f.pinchAround===void 0?f.around:f.pinchAround;w.around=S?this._map.unproject(S):this._map.getCenter()}return this.clear(),w.noMoveStart=!0,w}}function cf(y,h){(!y.duration||y.duration<h.duration)&&(y.duration=h.duration,y.easing=h.easing)}function uf(y,h,f){const{maxSpeed:v,linearity:w,deceleration:S}=f,I=a.clamp(y*w/(h/1e3),-v,v),L=Math.abs(I)/(S*w);return{easing:f.easing,duration:1e3*L,amount:I*(L/2)}}class Ho extends a.Event{preventDefault(){this._defaultPrevented=!0}get defaultPrevented(){return this._defaultPrevented}constructor(h,f,v,w={}){const S=W(f.getCanvasContainer(),v),I=f.unproject(S);super(h,a.extend({point:S,lngLat:I,originalEvent:v},w)),this._defaultPrevented=!1,this.target=f}}class hf extends a.Event{preventDefault(){this._defaultPrevented=!0}get defaultPrevented(){return this._defaultPrevented}constructor(h,f,v){const w=h==="touchend"?v.changedTouches:v.touches,S=Q(f.getCanvasContainer(),w),I=S.map(z=>f.unproject(z)),L=S.reduce((z,H,q,ee)=>z.add(H.div(ee.length)),new a.Point(0,0));super(h,{points:S,point:L,lngLats:I,lngLat:f.unproject(L),originalEvent:v}),this._defaultPrevented=!1}}class zp extends a.Event{preventDefault(){this._defaultPrevented=!0}get defaultPrevented(){return this._defaultPrevented}constructor(h,f,v){super(h,{originalEvent:v}),this._defaultPrevented=!1}}class Rg{constructor(h,f){this._map=h,this._clickTolerance=f.clickTolerance}reset(){this._mousedownPos=void 0}wheel(h){return this._firePreventable(new zp(h.type,this._map,h))}mousedown(h,f){return this._mousedownPos=f,this._firePreventable(new Ho(h.type,this._map,h))}mouseup(h){this._map.fire(new Ho(h.type,this._map,h))}preclick(h){const f=a.extend({},h);f.type="preclick",this._map.fire(new Ho(f.type,this._map,f))}click(h,f){this._mousedownPos&&this._mousedownPos.dist(f)>=this._clickTolerance||(this.preclick(h),this._map.fire(new Ho(h.type,this._map,h)))}dblclick(h){return this._firePreventable(new Ho(h.type,this._map,h))}mouseover(h){this._map.fire(new Ho(h.type,this._map,h))}mouseout(h){this._map.fire(new Ho(h.type,this._map,h))}touchstart(h){return this._firePreventable(new hf(h.type,this._map,h))}touchmove(h){this._map.fire(new hf(h.type,this._map,h))}touchend(h){this._map.fire(new hf(h.type,this._map,h))}touchcancel(h){this._map.fire(new hf(h.type,this._map,h))}
vendor: 16,086 bytes, line 1423
1423_firePreventable(h){if(this._map.fire(h),h.defaultPrevented)return{}}isEnabled(){return!0}isActive(){return!1}enable(){}disable(){}}class Np{constructor(h){this._map=h}reset(){this._delayContextMenu=!1,this._contextMenuEvent=void 0}mousemove(h){this._map.fire(new Ho(h.type,this._map,h))}mousedown(){this._delayContextMenu=!0}mouseup(){this._delayContextMenu=!1,this._contextMenuEvent&&(this._map.fire(new Ho("contextmenu",this._map,this._contextMenuEvent)),delete this._contextMenuEvent)}contextmenu(h){this._delayContextMenu?this._contextMenuEvent=h:this._map.fire(new Ho(h.type,this._map,h)),this._map.listens("contextmenu")&&h.preventDefault()}isEnabled(){return!0}isActive(){return!1}enable(){}disable(){}}class Vv{constructor(h,f){this._map=h,this._el=h.getCanvasContainer(),this._container=h.getContainer(),this._clickTolerance=f.clickTolerance||1}isEnabled(){return!!this._enabled}isActive(){return!!this._active}enable(){this.isEnabled()||(this._enabled=!0)}disable(){this.isEnabled()&&(this._enabled=!1)}mousedown(h,f){this.isEnabled()&&h.shiftKey&&h.button===0&&(R(),this._startPos=this._lastPos=f,this._active=!0)}mousemoveWindow(h,f){if(!this._active)return;const v=f,w=this._startPos,S=this._lastPos;if(!w||!S||S.equals(v)||!this._box&&v.dist(w)<this._clickTolerance)return;this._lastPos=v,this._box||(this._box=C("div","mapboxgl-boxzoom",this._container),this._container.classList.add("mapboxgl-crosshair"),this._fireEvent("boxzoomstart",h));const I=Math.min(w.x,v.x),L=Math.max(w.x,v.x),z=Math.min(w.y,v.y),H=Math.max(w.y,v.y);this._map._requestDomTask(()=>{this._box&&(this._box.style.transform=`translate(${I}px,${z}px)`,this._box.style.width=L-I+"px",this._box.style.height=H-z+"px")})}mouseupWindow(h,f){if(!this._active)return;const v=this._startPos,w=f;if(v&&h.button===0){if(this.reset(),U(),v.x!==w.x||v.y!==w.y)return this._map.fire(new a.Event("boxzoomend",{originalEvent:h})),{cameraAnimation:S=>S.fitScreenCoordinates(v,w,this._map.getBearing(),{linear:!1})};this._fireEvent("boxzoomcancel",h)}}keydown(h){this._active&&h.keyCode===27&&(this.reset(),this._fireEvent("boxzoomcancel",h))}blur(){this.reset()}reset(){this._active=!1,this._container.classList.remove("mapboxgl-crosshair"),this._box&&(this._box.remove(),this._box=null),N(),delete this._startPos,delete this._lastPos}_fireEvent(h,f){return this._map.fire(new a.Event(h,{originalEvent:f}))}}function $p(y,h){const f={};for(let v=0;v<y.length;v++)f[y[v].identifier]=h[v];return f}class Sh{constructor(h){this.reset(),this.numTouches=h.numTouches}reset(){this.centroid=void 0,this.startTime=0,this.touches={},this.aborted=!1}touchstart(h,f,v){(this.centroid||v.length>this.numTouches)&&(this.aborted=!0),this.aborted||(this.startTime===0&&(this.startTime=h.timeStamp),v.length===this.numTouches&&(this.centroid=function(w){const S=new a.Point(0,0);for(const I of w)S._add(I);return S.div(w.length)}(f),this.touches=$p(v,f)))}touchmove(h,f,v){if(this.aborted||!this.centroid)return;const w=$p(v,f);for(const S in this.touches){const I=w[S];(!I||I.dist(this.touches[S])>30)&&(this.aborted=!0)}}touchend(h,f,v){if((!this.centroid||h.timeStamp-this.startTime>500)&&(this.aborted=!0),v.length===0){const w=!this.aborted&&this.centroid;if(this.reset(),w)return w}}}class Fg{constructor(h){this.singleTap=new Sh(h),this.numTaps=h.numTaps,this.reset()}reset(){this.lastTime=1/0,this.lastTap=void 0,this.count=0,this.singleTap.reset()}touchstart(h,f,v){this.singleTap.touchstart(h,f,v)}touchmove(h,f,v){this.singleTap.touchmove(h,f,v)}touchend(h,f,v){const w=this.singleTap.touchend(h,f,v);if(w){const S=h.timeStamp-this.lastTime<500,I=!this.lastTap||this.lastTap.dist(w)<30;if(S&&I||this.reset(),this.count++,this.lastTime=h.timeStamp,this.lastTap=w,this.count===this.numTaps)return this.reset(),w}}}class N1{constructor(){this._zoomIn=new Fg({numTouches:1,numTaps:2}),this._zoomOut=new Fg({numTouches:2,numTaps:1}),this.reset()}reset(){this._active=!1,this._zoomIn.reset(),this._zoomOut.reset()}touchstart(h,f,v){this._zoomIn.touchstart(h,f,v),this._zoomOut.touchstart(h,f,v)}touchmove(h,f,v){this._zoomIn.touchmove(h,f,v),this._zoomOut.touchmove(h,f,v)}touchend(h,f,v){const w=this._zoomIn.touchend(h,f,v),S=this._zoomOut.touchend(h,f,v);return w?(this._active=!0,h.preventDefault(),setTimeout(()=>this.reset(),0),{cameraAnimation:I=>I.easeTo({duration:300,zoom:I.getZoom()+1,around:I.unproject(w)},{originalEvent:h})}):S?(this._active=!0,h.preventDefault(),setTimeout(()=>this.reset(),0),{cameraAnimation:I=>I.easeTo({duration:300,zoom:I.getZoom()-1,around:I.unproject(S)},{originalEvent:h})}):void 0}touchcancel(){this.reset()}enable(){this._enabled=!0}disable(){this._enabled=!1,this.reset()}isEnabled(){return this._enabled}isActive(){return this._active}}const Gv={0:1,2:2};class Ch{constructor(h){this.reset(),this._clickTolerance=h.clickTolerance||1}blur(){this.reset()}reset(){this._active=!1,this._moved=!1,this._lastPoint=void 0,this._eventButton=void 0}_correctButton(h,f){return!1}_move(h,f){return{}}mousedown(h,f){if(this._lastPoint)return;const v=Z(h);this._correctButton(h,v)&&(this._lastPoint=f,this._eventButton=v)}mousemoveWindow(h,f){const v=this._lastPoint;if(v){if(h.preventDefault(),this._eventButton!=null&&function(w,S){const I=Gv[S];return w.buttons===void 0||(w.buttons&I)!==I}(h,this._eventButton))this.reset();else if(this._moved||!(f.dist(v)<this._clickTolerance))return this._moved=!0,this._lastPoint=f,this._move(v,f)}}mouseupWindow(h){this._lastPoint&&Z(h)===this._eventButton&&(this._moved&&U(),this.reset())}enable(){this._enabled=!0}disable(){this._enabled=!1,this.reset()}isEnabled(){return this._enabled}isActive(){return this._active}}class Bg extends Ch{mousedown(h,f){super.mousedown(h,f),this._lastPoint&&(this._active=!0)}_correctButton(h,f){return f===0&&!h.ctrlKey}_move(h,f){return{around:f,panDelta:f.sub(h)}}}class zg extends Ch{_correctButton(h,f){return f===0&&h.ctrlKey||f===2}_move(h,f){const v=.8*(f.x-h.x);if(v)return this._active=!0,{bearingDelta:v}}contextmenu(h){h.preventDefault()}}class Ng extends Ch{_correctButton(h,f){return f===0&&h.ctrlKey||f===2}_move(h,f){const v=-.5*(f.y-h.y);if(v)return this._active=!0,{pitchDelta:v}}contextmenu(h){h.preventDefault()}}class jp{constructor(h,f){this._map=h,this._el=h.getCanvasContainer(),this._minTouches=1,this._clickTolerance=f.clickTolerance||1,this.reset(),a.bindAll(["_addTouchPanBlocker","_showTouchPanBlockerAlert"],this)}reset(){this._active=!1,this._touches={},this._sum=new a.Point(0,0)}touchstart(h,f,v){return this._calculateTransform(h,f,v)}touchmove(h,f,v){if(this._active&&!(v.length<this._minTouches)){if(this._map._cooperativeGestures&&!this._map.isMoving()){if(v.length===1&&!a.isFullscreen())return void this._showTouchPanBlockerAlert();this._alertContainer.style.visibility!=="hidden"&&(this._alertContainer.style.visibility="hidden",clearTimeout(this._alertTimer))}return h.cancelable&&h.preventDefault(),this._calculateTransform(h,f,v)}}touchend(h,f,v){this._calculateTransform(h,f,v),this._active&&v.length<this._minTouches&&this.reset()}touchcancel(){this.reset()}_calculateTransform(h,f,v){v.length>0&&(this._active=!0);const w=$p(v,f),S=new a.Point(0,0),I=new a.Point(0,0);let L=0;for(const H in w){const q=w[H],ee=this._touches[H];ee&&(S._add(q),I._add(q.sub(ee)),L++,w[H]=q)}if(this._touches=w,L<this._minTouches||!I.mag())return;const z=I.div(L);return this._sum._add(z),this._sum.mag()<this._clickTolerance?void 0:{around:S.div(L),panDelta:z}}enable(){this._enabled=!0,this._map._cooperativeGestures&&(this._addTouchPanBlocker(),this._el.classList.add("mapboxgl-touch-pan-blocker-override","mapboxgl-scrollable-page"))}disable(){this._enabled=!1,this._map._cooperativeGestures&&(clearTimeout(this._alertTimer),this._alertContainer.remove(),this._el.classList.remove("mapboxgl-touch-pan-blocker-override","mapboxgl-scrollable-page")),this.reset()}isEnabled(){return!!this._enabled}isActive(){return!!this._active}_addTouchPanBlocker(){this._map&&!this._alertContainer&&(this._alertContainer=C("div","mapboxgl-touch-pan-blocker",this._map._container),this._alertContainer.textContent=this._map._getUIString("TouchPanBlocker.Message"),this._alertContainer.style.fontSize=`${Math.max(10,Math.min(24,Math.floor(.05*this._el.clientWidth)))}px`)}_showTouchPanBlockerAlert(){this._alertContainer.style.visibility="visible",this._alertContainer.classList.add("mapboxgl-touch-pan-blocker-show"),this._alertContainer.setAttribute("role","alert"),clearTimeout(this._alertTimer),this._alertTimer=setTimeout(()=>{this._alertContainer.classList.remove("mapboxgl-touch-pan-blocker-show"),this._alertContainer.setAttribute("role","null")},500)}}class df{constructor(){this.reset()}reset(){this._active=!1,this._firstTwoTouches=void 0}_start(h){}_move(h,f,v){return{}}touchstart(h,f,v){this._firstTwoTouches||v.length<2||(this._firstTwoTouches=[v[0].identifier,v[1].identifier],this._start([f[0],f[1]]))}touchmove(h,f,v){const w=this._firstTwoTouches;if(!w)return;h.preventDefault();const[S,I]=w,L=ff(v,f,S),z=ff(v,f,I);if(!L||!z)return;const H=this._aroundCenter?null:L.add(z).div(2);return this._move([L,z],H,h)}touchend(h,f,v){if(!this._firstTwoTouches)return;const[w,S]=this._firstTwoTouches,I=ff(v,f,w),L=ff(v,f,S);I&&L||(this._active&&U(),this.reset())}touchcancel(){this.reset()}enable(h){this._enabled=!0,this._aroundCenter=!!h&&h.around==="center"}disable(){this._enabled=!1,this.reset()}isEnabled(){return this._enabled}isActive(){return this._active}}function ff(y,h,f){for(let v=0;v<y.length;v++)if(y[v].identifier===f)return h[v]}function $g(y,h){return Math.log(y/h)/Math.LN2}class qv extends df{reset(){super.reset(),this._distance=0,this._startDistance=0}_start(h){this._startDistance=this._distance=h[0].dist(h[1])}_move(h,f){const v=this._distance;if(this._distance=h[0].dist(h[1]),this._active||!(Math.abs($g(this._distance,this._startDistance))<.1))return this._active=!0,{zoomDelta:$g(this._distance,v),pinchAround:f}}}function jg(y,h){return 180*y.angleWith(h)/Math.PI}class Wv extends df{reset(){super.reset(),this._minDiameter=0,this._startVector=void 0,this._vector=void 0}_start(h){this._startVector=this._vector=h[0].sub(h[1]),this._minDiameter=h[0].dist(h[1])}_move(h,f){const v=this._vector;if(this._vector=h[0].sub(h[1]),v&&(this._active||!this._isBelowThreshold(this._vector)))return this._active=!0,{bearingDelta:jg(this._vector,v),pinchAround:f}}_isBelowThreshold(h){this._minDiameter=Math.min(this._minDiameter,h.mag());const f=25/(Math.PI*this._minDiameter)*360,v=this._startVector;if(!v)return!1;const w=jg(h,v);return Math.abs(w)<f}}function Gc(y){return Math.abs(y.y)>Math.abs(y.x)}class Hv extends df{constructor(h){super(),this._map=h}reset(){super.reset(),this._valid=void 0,this._firstMove=void 0,this._lastPoints=void 0}_start(h){this._lastPoints=h,Gc(h[0].sub(h[1]))&&(this._valid=!1)}_move(h,f,v){const w=this._lastPoints;if(!w)return;const S=h[0].sub(w[0]),I=h[1].sub(w[1]);return this._map._cooperativeGestures&&!a.isFullscreen()&&v.touches.length<3||(this._valid=this.gestureBeginsVertically(S,I,v.timeStamp),!this._valid)?void 0:(this._lastPoints=h,this._active=!0,{pitchDelta:(S.y+I.y)/2*-.5})}gestureBeginsVertically(h,f,v){if(this._valid!==void 0)return this._valid;const w=h.mag()>=2,S=f.mag()>=2;if(!w&&!S)return;if(!w||!S)return this._firstMove==null&&(this._firstMove=v),v-this._firstMove<100&&void 0;const I=h.y>0==f.y>0;return Gc(h)&&Gc(f)&&I}}const Yv={panStep:100,bearingStep:15,pitchStep:10};class $1{constructor(){const h=Yv;this._panStep=h.panStep,this._bearingStep=h.bearingStep,this._pitchStep=h.pitchStep,this._rotationDisabled=!1}blur(){this.reset()}reset(){this._active=!1}keydown(h){if(h.altKey||h.ctrlKey||h.metaKey)return;let f=0,v=0,w=0,S=0,I=0;switch(h.keyCode){case 61:case 107:case 171:case 187:f=1;break;case 189:case 109:case 173:f=-1;break;case 37:h.shiftKey?v=-1:(h.preventDefault(),S=-1);break;case 39:h.shiftKey?v=1:(h.preventDefault(),S=1);break;case 38:h.shiftKey?w=1:(h.preventDefault(),I=-1);break;case 40:h.shiftKey?w=-1:(h.preventDefault(),I=1);break;default:return}return this._rotationDisabled&&(v=0,w=0),{cameraAnimation:L=>{const z=L.getZoom();L.easeTo({duration:300,easeId:"keyboardHandler",easing:Zv,zoom:f?Math.round(z)+f*(h.shiftKey?2:1):z,bearing:L.getBearing()+v*this._bearingStep,pitch:L.getPitch()+w*this._pitchStep,offset:[-S*this._panStep,-I*this._panStep],center:L.getCenter()},{originalEvent:h})}}}enable(){this._enabled=!0}disable(){this._enabled=!1,this.reset()}isEnabled(){return this._enabled}isActive(){return this._active}disableRotation(){this._rotationDisabled=!0}enableRotation(){this._rotationDisabled=!1}}function Zv(y){return y*(2-y)}const Ug=4.000244140625;class Xv{constructor(h,f){this._map=h,this._el=h.getCanvasContainer(),this._handler=f,this._delta=0,this._defaultZoomRate=.01,this._wheelZoomRate=.0022222222222222222,a.bindAll(["_onTimeout","_addScrollZoomBlocker","_showBlockerAlert"],this)}setZoomRate(h){this._defaultZoomRate=h}setWheelZoomRate(h){this._wheelZoomRate=h}isEnabled(){return!!this._enabled}isActive(){return this._active||this._finishTimeout!==void 0}isZooming(){return!!this._zooming}enable(h){this.isEnabled()||(this._enabled=!0,this._aroundCenter=!!h&&h.around==="center",this._map._cooperativeGestures&&this._addScrollZoomBlocker())}disable(){this.isEnabled()&&(this._enabled=!1,this._map._cooperativeGestures&&(clearTimeout(this._alertTimer),this._alertContainer.remove()))}wheel(h){if(!this.isEnabled())return;if(this._map._cooperativeGestures){if(!(h.ctrlKey||h.metaKey||this.isZooming()||a.isFullscreen()))return void this._showBlockerAlert();this._alertContainer.style.visibility!=="hidden"&&(this._alertContainer.style.visibility="hidden",clearTimeout(this._alertTimer))}let f=h.deltaMode===a.window.WheelEvent.DOM_DELTA_LINE?40*h.deltaY:h.deltaY;const v=a.exported.now(),w=v-(this._lastWheelEventTime||0);this._lastWheelEventTime=v,f!==0&&f%Ug==0?this._type="wheel":f!==0&&Math.abs(f)<4?this._type="trackpad":w>400?(this._type=null,this._lastValue=f,this._timeout=setTimeout(this._onTimeout,40,h)):this._type||(this._type=Math.abs(w*f)<200?"trackpad":"wheel",this._timeout&&(clearTimeout(this._timeout),this._timeout=null,f+=this._lastValue)),h.shiftKey&&f&&(f/=4),this._type&&(this._lastWheelEvent=h,this._delta-=f,this._active||this._start(h)),h.preventDefault()}_onTimeout(h){this._type="wheel",this._delta-=this._lastValue,this._active||this._start(h)}_start(h){if(!this._delta)return;this._frameId&&(this._frameId=null),this._active=!0,this.isZooming()||(this._zooming=!0),this._finishTimeout&&(clearTimeout(this._finishTimeout),delete this._finishTimeout);const f=W(this._el,h);this._aroundPoint=this._aroundCenter?this._map.transform.centerPoint:f,this._aroundCoord=this._map.transform.pointCoordinate3D(this._aroundPoint),this._targetZoom=void 0,this._frameId||(this._frameId=!0,this._handler._triggerRenderFrame())}renderFrame(){if(!this._frameId||(this._frameId=null,!this.isActive()))return;const h=this._map.transform;this._type==="wheel"&&h.projection.wrap&&(h._center.lng>=180||h._center.lng<=-180)&&(this._prevEase=null,this._easing=null,this._lastWheelEvent=null,this._lastWheelEventTime=0);const f=()=>h._terrainEnabled()&&this._aroundCoord?h.computeZoomRelativeTo(this._aroundCoord):h.zoom;if(this._delta!==0){const z=this._type==="wheel"&&Math.abs(this._delta)>Ug?this._wheelZoomRate:this._defaultZoomRate;let H=2/(1+Math.exp(-Math.abs(this._delta*z)));this._delta<0&&H!==0&&(H=1/H);const q=f(),ee=Math.pow(2,q),de=typeof this._targetZoom=="number"?h.zoomScale(this._targetZoom):ee;this._targetZoom=Math.min(h.maxZoom,Math.max(h.minZoom,h.scaleZoom(de*H))),this._type==="wheel"&&(this._startZoom=q,this._easing=this._smoothOutEasing(200)),this._delta=0}const v=typeof this._targetZoom=="number"?this._targetZoom:f(),w=this._startZoom,S=this._easing;let I,L=!1;if(this._type==="wheel"&&w&&S){const z=Math.min((a.exported.now()-this._lastWheelEventTime)/200,1),H=S(z);I=a.number(w,v,H),z<1?this._frameId||(this._frameId=!0):L=!0}else I=v,L=!0;return this._active=!0,L&&(this._active=!1,this._finishTimeout=setTimeout(()=>
vendor: 7,435 bytes, line 1423
1423{this._zooming=!1,this._handler._triggerRenderFrame(),delete this._targetZoom,delete this._finishTimeout},200)),{noInertia:!0,needsRenderFrame:!L,zoomDelta:I-f(),around:this._aroundPoint,aroundCoord:this._aroundCoord,originalEvent:this._lastWheelEvent}}_smoothOutEasing(h){let f=a.ease;if(this._prevEase){const v=this._prevEase,w=(a.exported.now()-v.start)/v.duration,S=v.easing(w+.01)-v.easing(w),I=.27/Math.sqrt(S*S+1e-4)*.01,L=Math.sqrt(.0729-I*I);f=a.bezier(I,L,.25,1)}return this._prevEase={start:a.exported.now(),duration:h,easing:f},f}blur(){this.reset()}reset(){this._active=!1}_addScrollZoomBlocker(){this._map&&!this._alertContainer&&(this._alertContainer=C("div","mapboxgl-scroll-zoom-blocker",this._map._container),this._alertContainer.textContent=/(Mac|iPad)/i.test(a.window.navigator.userAgent)?this._map._getUIString("ScrollZoomBlocker.CmdMessage"):this._map._getUIString("ScrollZoomBlocker.CtrlMessage"),this._alertContainer.style.fontSize=`${Math.max(10,Math.min(24,Math.floor(.05*this._el.clientWidth)))}px`)}_showBlockerAlert(){this._alertContainer.style.visibility="visible",this._alertContainer.classList.add("mapboxgl-scroll-zoom-blocker-show"),this._alertContainer.setAttribute("role","alert"),clearTimeout(this._alertTimer),this._alertTimer=setTimeout(()=>{this._alertContainer.classList.remove("mapboxgl-scroll-zoom-blocker-show"),this._alertContainer.setAttribute("role","null")},200)}}class Kv{constructor(h,f){this._clickZoom=h,this._tapZoom=f}enable(){this._clickZoom.enable(),this._tapZoom.enable()}disable(){this._clickZoom.disable(),this._tapZoom.disable()}isEnabled(){return this._clickZoom.isEnabled()&&this._tapZoom.isEnabled()}isActive(){return this._clickZoom.isActive()||this._tapZoom.isActive()}}class ga{constructor(){this.reset()}reset(){this._active=!1}blur(){this.reset()}dblclick(h,f){return h.preventDefault(),{cameraAnimation:v=>{v.easeTo({duration:300,zoom:v.getZoom()+(h.shiftKey?-1:1),around:v.unproject(f)},{originalEvent:h})}}}enable(){this._enabled=!0}disable(){this._enabled=!1,this.reset()}isEnabled(){return this._enabled}isActive(){return this._active}}class j1{constructor(){this._tap=new Fg({numTouches:1,numTaps:1}),this.reset()}reset(){this._active=!1,this._swipePoint=void 0,this._swipeTouch=0,this._tapTime=0,this._tap.reset()}touchstart(h,f,v){this._swipePoint||(this._tapTime&&h.timeStamp-this._tapTime>500&&this.reset(),this._tapTime?v.length>0&&(this._swipePoint=f[0],this._swipeTouch=v[0].identifier):this._tap.touchstart(h,f,v))}touchmove(h,f,v){if(this._tapTime){if(this._swipePoint){if(v[0].identifier!==this._swipeTouch)return;const w=f[0],S=w.y-this._swipePoint.y;return this._swipePoint=w,h.preventDefault(),this._active=!0,{zoomDelta:S/128}}}else this._tap.touchmove(h,f,v)}touchend(h,f,v){this._tapTime?this._swipePoint&&v.length===0&&this.reset():this._tap.touchend(h,f,v)&&(this._tapTime=h.timeStamp)}touchcancel(){this.reset()}enable(){this._enabled=!0}disable(){this._enabled=!1,this.reset()}isEnabled(){return this._enabled}isActive(){return this._active}}class Qv{constructor(h,f,v){this._el=h,this._mousePan=f,this._touchPan=v}enable(h){this._inertiaOptions=h||{},this._mousePan.enable(),this._touchPan.enable(),this._el.classList.add("mapboxgl-touch-drag-pan")}disable(){this._mousePan.disable(),this._touchPan.disable(),this._el.classList.remove("mapboxgl-touch-drag-pan")}isEnabled(){return this._mousePan.isEnabled()&&this._touchPan.isEnabled()}isActive(){return this._mousePan.isActive()||this._touchPan.isActive()}}class U1{constructor(h,f,v){this._pitchWithRotate=h.pitchWithRotate,this._mouseRotate=f,this._mousePitch=v}enable(){this._mouseRotate.enable(),this._pitchWithRotate&&this._mousePitch.enable()}disable(){this._mouseRotate.disable(),this._mousePitch.disable()}isEnabled(){return this._mouseRotate.isEnabled()&&(!this._pitchWithRotate||this._mousePitch.isEnabled())}isActive(){return this._mouseRotate.isActive()||this._mousePitch.isActive()}}class V1{constructor(h,f,v,w){this._el=h,this._touchZoom=f,this._touchRotate=v,this._tapDragZoom=w,this._rotationDisabled=!1,this._enabled=!0}enable(h){this._touchZoom.enable(h),this._rotationDisabled||this._touchRotate.enable(h),this._tapDragZoom.enable(),this._el.classList.add("mapboxgl-touch-zoom-rotate")}disable(){this._touchZoom.disable(),this._touchRotate.disable(),this._tapDragZoom.disable(),this._el.classList.remove("mapboxgl-touch-zoom-rotate")}isEnabled(){return this._touchZoom.isEnabled()&&(this._rotationDisabled||this._touchRotate.isEnabled())&&this._tapDragZoom.isEnabled()}isActive(){return this._touchZoom.isActive()||this._touchRotate.isActive()||this._tapDragZoom.isActive()}disableRotation(){this._rotationDisabled=!0,this._touchRotate.disable()}enableRotation(){this._rotationDisabled=!1,this._touchZoom.isEnabled()&&this._touchRotate.enable()}}const Ss=y=>y.zoom||y.drag||y.pitch||y.rotate;class Jv extends a.Event{}class G1{constructor(){this.constants=[1,1,.01],this.radius=0}setup(h,f){const v=a.sub([],f,h);this.radius=a.length(v[2]<0?a.div([],v,this.constants):[v[0],v[1],0])}projectRay(h){a.div(h,h,this.constants),a.normalize(h,h),a.mul$1(h,h,this.constants);const f=a.scale$2([],h,this.radius);if(f[2]>0){const v=a.scale$2([],[0,0,1],a.dot(f,[0,0,1])),w=a.scale$2([],a.normalize([],[f[0],f[1],0]),this.radius),S=a.add([],f,a.scale$2([],a.sub([],a.add([],w,v),f),2));f[0]=S[0],f[1]=S[1]}return f}}function rl(y){return y.panDelta&&y.panDelta.mag()||y.zoomDelta||y.bearingDelta||y.pitchDelta}class Il{constructor(h,f){this._map=h,this._el=this._map.getCanvasContainer(),this._handlers=[],this._handlersById={},this._changes=[],this._inertia=new Uv(h),this._bearingSnap=f.bearingSnap,this._previousActiveHandlers={},this._trackingEllipsoid=new G1,this._dragOrigin=null,this._eventsInProgress={},this._addDefaultHandlers(f),a.bindAll(["handleEvent","handleWindowEvent"],this);const v=this._el;this._listeners=[[v,"touchstart",{passive:!0}],[v,"touchmove",{passive:!1}],[v,"touchend",void 0],[v,"touchcancel",void 0],[v,"mousedown",void 0],[v,"mousemove",void 0],[v,"mouseup",void 0],[a.window.document,"mousemove",{capture:!0}],[a.window.document,"mouseup",void 0],[v,"mouseover",void 0],[v,"mouseout",void 0],[v,"dblclick",void 0],[v,"click",void 0],[v,"keydown",{capture:!1}],[v,"keyup",void 0],[v,"wheel",{passive:!1}],[v,"contextmenu",void 0],[a.window,"blur",void 0]];for(const[w,S,I]of this._listeners)w.addEventListener(S,w===a.window.document?this.handleWindowEvent:this.handleEvent,I)}destroy(){for(const[h,f,v]of this._listeners)h.removeEventListener(f,h===a.window.document?this.handleWindowEvent:this.handleEvent,v)}_addDefaultHandlers(h){const f=this._map,v=f.getCanvasContainer();this._add("mapEvent",new Rg(f,h));const w=f.boxZoom=new Vv(f,h);this._add("boxZoom",w);const S=new N1,I=new ga;f.doubleClickZoom=new Kv(I,S),this._add("tapZoom",S),this._add("clickZoom",I);const L=new j1;this._add("tapDragZoom",L);const z=f.touchPitch=new Hv(f);this._add("touchPitch",z);const H=new zg(h),q=new Ng(h);f.dragRotate=new U1(h,H,q),this._add("mouseRotate",H,["mousePitch"]),this._add("mousePitch",q,["mouseRotate"]);const ee=new Bg(h),de=new jp(f,h);f.dragPan=new Qv(v,ee,de),this._add("mousePan",ee),this._add("touchPan",de,["touchZoom","touchRotate"]);const _e=new Wv,be=new qv;f.touchZoomRotate=new V1(v,be,_e,L),this._add("touchRotate",_e,["touchPan","touchZoom"]),this._add("touchZoom",be,["touchPan","touchRotate"]),this._add("blockableMapEvent",new 
vendor: 6,135 bytes, line 1423
1423Np(f));const ve=f.scrollZoom=new Xv(f,this);this._add("scrollZoom",ve,["mousePan"]);const Ee=f.keyboard=new $1;this._add("keyboard",Ee);for(const te of["boxZoom","doubleClickZoom","tapDragZoom","touchPitch","dragRotate","dragPan","touchZoomRotate","scrollZoom","keyboard"])h.interactive&&h[te]&&f[te].enable(h[te])}_add(h,f,v){this._handlers.push({handlerName:h,handler:f,allowed:v}),this._handlersById[h]=f}stop(h){if(!this._updatingCamera){for(const{handler:f}of this._handlers)f.reset();this._inertia.clear(),this._fireEvents({},{},h),this._changes=[]}}isActive(){for(const{handler:h}of this._handlers)if(h.isActive())return!0;return!1}isZooming(){return!!this._eventsInProgress.zoom||this._map.scrollZoom.isZooming()}isRotating(){return!!this._eventsInProgress.rotate}isMoving(){return!!Ss(this._eventsInProgress)||this.isZooming()}_isDragging(){return!!this._eventsInProgress.drag}_blockedByActive(h,f,v){for(const w in h)if(w!==v&&(!f||f.indexOf(w)<0))return!0;return!1}handleWindowEvent(h){this.handleEvent(h,`${h.type}Window`)}_getMapTouches(h){const f=[];for(const v of h)this._el.contains(v.target)&&f.push(v);return f}handleEvent(h,f){this._updatingCamera=!0;const v=h.type==="renderFrame",w=v?void 0:h,S={needsRenderFrame:!1},I={},L={},z=h.touches?this._getMapTouches(h.touches):void 0,H=z?Q(this._el,z):v?void 0:W(this._el,h);for(const{handlerName:de,handler:_e,allowed:be}of this._handlers){if(!_e.isEnabled())continue;let ve;this._blockedByActive(L,be,de)?_e.reset():_e[f||h.type]&&(ve=_e[f||h.type](h,H,z),this.mergeHandlerResult(S,I,ve,de,w),ve&&ve.needsRenderFrame&&this._triggerRenderFrame()),(ve||_e.isActive())&&(L[de]=_e)}const q={};for(const de in this._previousActiveHandlers)L[de]||(q[de]=w);this._previousActiveHandlers=L,(Object.keys(q).length||rl(S))&&(this._changes.push([S,I,q]),this._triggerRenderFrame()),(Object.keys(L).length||rl(S))&&this._map._stop(!0),this._updatingCamera=!1;const{cameraAnimation:ee}=S;ee&&(this._inertia.clear(),this._fireEvents({},{},!0),this._changes=[],ee(this._map))}mergeHandlerResult(h,f,v,w,S){if(!v)return;a.extend(h,v);const I={handlerName:w,originalEvent:v.originalEvent||S};v.zoomDelta!==void 0&&(f.zoom=I),v.panDelta!==void 0&&(f.drag=I),v.pitchDelta!==void 0&&(f.pitch=I),v.bearingDelta!==void 0&&(f.rotate=I)}_applyChanges(){const h={},f={},v={};for(const[w,S,I]of this._changes)w.panDelta&&(h.panDelta=(h.panDelta||new a.Point(0,0))._add(w.panDelta)),w.zoomDelta&&(h.zoomDelta=(h.zoomDelta||0)+w.zoomDelta),w.bearingDelta&&(h.bearingDelta=(h.bearingDelta||0)+w.bearingDelta),w.pitchDelta&&(h.pitchDelta=(h.pitchDelta||0)+w.pitchDelta),w.around!==void 0&&(h.around=w.around),w.aroundCoord!==void 0&&(h.aroundCoord=w.aroundCoord),w.pinchAround!==void 0&&(h.pinchAround=w.pinchAround),w.noInertia&&(h.noInertia=w.noInertia),a.extend(f,S),a.extend(v,I);this._updateMapTransform(h,f,v),this._changes=[]}_updateMapTransform(h,f,v){const w=this._map,S=w.transform,I=ye=>[ye.x,ye.y,ye.z];if((ye=>{const Oe=this._eventsInProgress.drag;return Oe&&!this._handlersById[Oe.handlerName].isActive()})()&&!rl(h)){const ye=S.zoom;S.cameraElevationReference="sea",S.recenterOnTerrain(),S.cameraElevationReference="ground",ye!==S.zoom&&this._map._update(!0)}if(S._isCameraConstrained&&w._stop(!0),!rl(h))return void this._fireEvents(f,v,!0);let{panDelta:L,zoomDelta:z,bearingDelta:H,pitchDelta:q,around:ee,aroundCoord:de,pinchAround:_e}=h;S._isCameraConstrained&&(z>0&&(z=0),S._isCameraConstrained=!1),_e!==void 0&&(ee=_e),(z||(ye=>f[ye]&&!this._eventsInProgress[ye])("drag"))&&ee&&(this._dragOrigin=I(S.pointCoordinate3D(ee)),this._trackingEllipsoid.setup(S._camera.position,this._dragOrigin)),S.cameraElevationReference="sea",w._stop(!0),ee=ee||w.transform.centerPoint,H&&(S.bearing+=H),q&&(S.pitch+=q),S._updateCameraState();const be=[0,0,0];if(L)if(S.projection.name==="mercator"){const ye=this._trackingEllipsoid.projectRay(S.screenPointToMercatorRay(ee).dir),Oe=this._trackingEllipsoid.projectRay(S.screenPointToMercatorRay(ee.sub(L)).dir);be[0]=Oe[0]-ye[0],be[1]=Oe[1]-ye[1]}else{const ye=S.pointCoordinate(ee);if(S.projection.name==="globe"){L=L.rotate(-S.angle);const Oe=S._pixelsPerMercatorPixel/S.worldSize;be[0]=-L.x*a.mercatorScale(a.latFromMercatorY(ye.y))*Oe,be[1]=-L.y*a.mercatorScale(S.center.lat)*Oe}else{const Oe=S.pointCoordinate(ee.sub(L));ye&&Oe&&(be[0]=Oe.x-ye.x,be[1]=Oe.y-ye.y)}}const ve=S.zoom,Ee=[0,0,0];if(z){const ye=I(de||S.pointCoordinate3D(ee)),Oe={dir:a.normalize([],a.sub([],ye,S._camera.position))};if(Oe.dir[2]<0){const Le=S.zoomDeltaToMovement(ye,z);a.scale$2(Ee,Oe.dir,Le)}}const te=a.add(be,be,Ee);S._translateCameraConstrained(te),z&&Math.abs(S.zoom-ve)>1e-4&&S.recenterOnTerrain(),S.cameraElevationReference="ground",this._map._update(),h.noInertia||this._inertia.record(h),this._fireEvents(f,v,!0)}_fireEvents(h,f,v){const w=Ss(this._eventsInProgress),S=Ss(h),I={};for(const q in h){const{originalEvent:ee}=h[q];this._eventsInProgress[q]||(I[`${q}start`]=ee),this._eventsInProgress[q]=h[q]}!w&&S&&this._fireEvent("movestart",S.originalEvent);for(const q in I)this._fireEvent(q,I[q]);S&&this._fireEvent("move",S.originalEvent);for(const q in h){const{originalEvent:ee}=h[q];this._fireEvent(q,ee)}const L={};let z;for(const q in this._eventsInProgress){const{handlerName:ee,originalEvent:de}=this._eventsInProgress[q];this._handlersById[ee].isActive()||(delete this._eventsInProgress[q],z=f[ee]||de,L[`${q}end`]=z)}for(const q in L)this._fireEvent(q,L[q]);const H=Ss(this._eventsInProgress);if(v&&(w||S)&&!H){this._updatingCamera=!0;const q=this._inertia._onMoveEnd(this._map.dragPan._inertiaOptions),ee=de=>de!==0&&-this._bearingSnap<de&&de<this._bearingSnap;q?(ee(q.bearing||this._map.getBearing())&&(q.bearing=0),this._map.easeTo(q,{originalEvent:z})):(this._map.fire(new a.Event("moveend",{originalEvent:z})),ee(this._map.getBearing())&&this._map.resetNorth()),this._updatingCamera=!1}}_fireEvent(h,f){this._map.fire(new a.Event(h,f?{originalEvent:f}:{}))}_requestFrame(){return this._map.triggerRepaint(),this._map._renderTaskQueue.add(h=>{this._frameId=void 0,this.handleEvent(new Jv("renderFrame",{timeStamp:h})),this._applyChanges()})}
1423_triggerRenderFrame(){this._frameId===void 0&&(this._frameId=this._requestFrame())}}const Du="map.setFreeCameraOptions(...) and map.getFreeCameraOptions() are not yet supported for non-mercator projections.";class Up extends a.Evented{constructor(h,f){super(),this._moving=!1,this._zooming=!1,this.transform=h,this._bearingSnap=f.bearingSnap,this._respectPrefersReducedMotion=f.respectPrefersReducedMotion!==!1,a.bindAll(["_renderFrameCallback"],this)}getCenter(){return new a.LngLat(this.transform.center.lng,this.transform.center.lat)}setCenter(h,f){return this.jumpTo({center:h},f)}panBy(h,f,v){return h=a.Point.convert(h).mult(-1),this.panTo(this.transform.center,a.extend({offset:h},f),v)}panTo(h,f,v){return this.easeTo(a.extend({center:h},f),v)}getZoom(){return this.transform.zoom}setZoom(h,f){return this.jumpTo({zoom:h},f),this}zoomTo(h,f,v){return this.easeTo(a.extend({zoom:h},f),v)}zoomIn(h,f){return this.zoomTo(this.getZoom()+1,h,f),this}zoomOut(h,f){return this.zoomTo(this.getZoom()-1,h,f),this}getBearing(){return this.transform.bearing}setBearing(h,f){return this.jumpTo({bearing:h},f),this}getPadding(){return this.transform.padding}setPadding(h,f){return this.jumpTo({padding:h},f),this}rotateTo(h,f,v){return this.easeTo(a.extend({bearing:h},f),v)}resetNorth(h,f){return this.rotateTo(0,a.extend({duration:1e3},h),f),this}resetNorthPitch(h,f){return this.easeTo(a.extend({bearing:0,pitch:0,duration:1e3},h),f),this}snapToNorth(h,f){return Math.abs(this.getBearing())<this._bearingSnap?this.resetNorth(h,f):this}getPitch(){return this.transform.pitch}setPitch(h,f){return this.jumpTo({pitch:h},f),this}cameraForBounds(h,f){h=a.LngLatBounds.convert(h);const v=f&&f.bearing||0,w=f&&f.pitch||0,S=h.getNorthWest(),I=h.getSouthEast();return this._cameraForBounds(this.transform,S,I,v,w,f)}_extendCameraOptions(h){const f={top:0,bottom:0,right:0,left:0};if(typeof(h=a.extend({padding:f,offset:[0,0],maxZoom:this.transform.maxZoom},h)).padding=="number"){const v=h.padding;h.padding={top:v,bottom:v,right:v,left:v}}return h.padding=a.extend(f,h.padding),h}_minimumAABBFrustumDistance(h,f){const v=f.max[0]-f.min[0],w=f.max[1]-f.min[1];return v/w>h.aspect?v/(2*Math.tan(.5*h.fovX)*h.aspect):w/(2*Math.tan(.5*h.fovY)*h.aspect)}_cameraForBoundsOnGlobe(h,f,v,w,S,I){const L=h.clone(),z=this._extendCameraOptions(I);L.bearing=w,L.pitch=S;const H=a.LngLat.convert(f),q=a.LngLat.convert(v),ee=.5*(H.lat+q.lat),de=.5*(H.lng+q.lng),_e=a.latLngToECEF(ee,de),be=a.normalize([],_e),ve=a.normalize([],a.cross([],be,[0,1,0])),Ee=a.cross([],ve,be),te=[ve[0],ve[1],ve[2],0,Ee[0],Ee[1],Ee[2],0,be[0],be[1],be[2],0,0,0,0,1],ye=[_e,a.latLngToECEF(H.lat,H.lng),a.latLngToECEF(q.lat,H.lng),a.latLngToECEF(q.lat,q.lng),a.latLngToECEF(H.lat,q.lng),a.latLngToECEF(ee,H.lng),a.latLngToECEF(ee,q.lng),a.latLngToECEF(H.lat,de),a.latLngToECEF(q.lat,de)];let Oe=a.Aabb.fromPoints(ye.map(Ut=>[a.dot(ve,Ut),a.dot(Ee,Ut),a.dot(be,Ut)]));const Le=a.transformMat4([],Oe.center,te);a.squaredLength(Le)===0&&a.set(Le,0,0,1),a.normalize(Le,Le),a.scale$2(Le,Le,a.GLOBE_RADIUS),L.center=a.ecefToLatLng(Le);const He=L.getWorldToCameraMatrix(),Ze=a.invert(new Float64Array(16),He);Oe=a.Aabb.applyTransform(Oe,a.multiply([],He,te)),a.transformMat4(Le,Le,He);const Ye=.5*(Oe.max[2]-Oe.min[2]),ot=this._minimumAABBFrustumDistance(L,Oe),et=a.scale$2([],[0,0,1],Ye),_t=a.add(et,Le,et),Zt=ot+(L.pitch===0?0:a.distance(Le,_t)),dt=L.globeCenterInViewSpace,Bt=a.sub([],Le,[dt[0],dt[1],dt[2]]);a.normalize(Bt,Bt),a.scale$2(Bt,Bt,Zt);const St=a.add([],Le,Bt);a.transformMat4(St,St,Ze);const Yt=a.earthRadius/a.GLOBE_RADIUS,gt=a.length(St),Ft=a.mercatorZfromAltitude(Math.max(gt*Yt-a.earthRadius,Number.EPSILON),0),Jt=Math.min(L.zoomFromMercatorZAdjusted(Ft),z.maxZoom);return Jt>.5*(a.GLOBE_ZOOM_THRESHOLD_MIN+a.GLOBE_ZOOM_THRESHOLD_MAX)?(L.setProjection({name:"mercator"}),L.zoom=Jt,this._cameraForBounds(L,f,v,w,S,I)):{center:L.center,zoom:Jt,bearing:w,pitch:S}}queryTerrainElevation(h,f){const v=this.transform.elevation;return v?(f=a.extend({},{exaggerated:!0},f),v.getAtPoint(a.MercatorCoordinate.fromLngLat(h),null,f.exaggerated)):null}_cameraForBounds(h,f,v,w,S,I){if(h.projection.name==="globe")return this._cameraForBoundsOnGlobe(h,f,v,w,S,I);const L=h.clone(),z=this._extendCameraOptions(I),H=L.padding;L.bearing=w,L.pitch=S;const q=a.LngLat.convert(f),ee=a.LngLat.convert(v),de=new a.LngLat(q.lng,ee.lat),_e=new a.LngLat(ee.lng,q.lat),be=L.project(q),ve=L.project(ee),Ee=this.queryTerrainElevation(q),te=this.queryTerrainElevation(ee),ye=this.queryTerrainElevation(de),Oe=this.queryTerrainElevation(_e),Le=[[be.x,be.y,Math.min(Ee||0,te||0,ye||0,Oe||0)],[ve.x,ve.y,Math.max(Ee||0,te||0,ye||0,Oe||0)]];let He=a.Aabb.fromPoints(Le);const Ze=L.getWorldToCameraMatrix(),Ye=a.invert(new Float64Array(16),Ze);He=a.Aabb.applyTransform(He,Ze);const ot=a.sub([],He.max,He.min),et=H.left||0,_t=H.right||0,Zt=H.bottom||0,dt=H.top||0,{left:Bt,right:St,top:Yt,bottom:gt}=z.padding,Ft=.5*(et+_t),Jt=.5*(dt+Zt),Ut=Math.min(L.scaleZoom(L.scale*Math.min((L.width-(et+_t+Bt+St))/ot[0],(L.height-(Zt+dt+gt+Yt))/ot[1])),z.maxZoom),tn=L.scale/L.zoomScale(Ut);He=new a.Aabb([He.min[0]-(Bt+Ft)*tn,He.min[1]-(gt+Jt)*tn,He.min[2]],[He.max[0]+(St+Ft)*tn,He.max[1]+(Yt+Jt)*tn,He.max[2]]);const Mn=.5*ot[2],Wn=this._minimumAABBFrustumDistance(L,He),wn=[0,0,1,0];a.transformMat4$1(wn,wn,Ze),a.normalize$2(wn,wn);const Bn=a.scale$2([],wn,Wn+Mn),mr=a.add([],He.center,Bn),pr=(typeof z.offset.x=="number"&&typeof z.offset.y=="number"?new a.Point(z.offset.x,z.offset.y):a.Point.convert(z.offset)).rotate(-a.degToRad(w));He.center[0]-=pr.x*tn,He.center[1]+=pr.y*tn,a.transformMat4(He.center,He.center,Ye),a.transformMat4(mr,mr,Ye);const Cn=[He.center[0],He.center[1],mr[2]*L.pixelsPerMeter];a.scale$2(Cn,Cn,1/L.worldSize);const Nr=a.lngFromMercatorX(Cn[0]),Qr=a.latFromMercatorY(Cn[1]),Jr=Math.min(L._zoomFromMercatorZ(Cn[2]),z.maxZoom),ei=new a.LngLat(Nr,Qr);return L.mercatorFromTransition&&Jr<.5*(a.GLOBE_ZOOM_THRESHOLD_MIN+a.GLOBE_ZOOM_THRESHOLD_MAX)?(L.setProjection({name:"globe"}),L.zoom=Jr,this._cameraForBounds(L,f,v,w,S,I)):{center:ei,zoom:Jr,bearing:w,pitch:S}}fitBounds(h,f,v){const w=this.cameraForBounds(h,f);return this._fitInternal(w,f,v)}fitScreenCoordinates(h,f,v,w,S){const I=a.Point.convert(h),L=a.Point.convert(f),z=new a.Point(Math.min(I.x,L.x),Math.min(I.y,L.y)),H=new a.Point(Math.max(I.x,L.x),Math.max(I.y,L.y));if(this.transform.projection.name==="mercator"&&this.transform.anyCornerOffEdge(I,L))return this;const q=this.transform.pointLocation3D(z),ee=this.transform.pointLocation3D(H),de=this.transform.pointLocation3D(new a.Point(z.x,H.y)),_e=this.transform.pointLocation3D(new a.Point(H.x,z.y)),be=[Math.min(q.lng,ee.lng,de.lng,_e.lng),Math.min(q.lat,ee.lat,de.lat,_e.lat)],ve=[Math.max(q.lng,ee.lng,de.lng,_e.lng),Math.max(q.lat,ee.lat,de.lat,_e.lat)],Ee=w&&w.pitch?w.pitch:this.getPitch(),te=this._cameraForBounds(this.transform,be,ve,v,Ee,w);return this._fitInternal(te,w,S)}_fitInternal(h,f,v){return h?(delete(f=a.extend(h,f)).padding,f.linear?this.easeTo(f,v):this.flyTo(f,v)):this}jumpTo(h,f){this.stop();const v=h.preloadOnly?this.transform.clone():this.transform;let w=!1,S=!1,I=!1;return"zoom"in h&&v.zoom!==+h.zoom&&(w=!0,v.zoom=+h.zoom),h.center!==void 0&&(v.center=a.LngLat.convert(h.center)),"bearing"in h&&v.bearing!==+h.bearing&&(S=!0,v.bearing=+h.bearing),"pitch"in h&&v.pitch!==+h.pitch&&(I=!0,v.pitch=+h.pitch),h.padding==null||v.
vendor: 4,808 bytes, line 1423
1423isPaddingEqual(h.padding)||(v.padding=h.padding),h.preloadOnly?(this._preloadTiles(v),this):(this.fire(new a.Event("movestart",f)).fire(new a.Event("move",f)),w&&this.fire(new a.Event("zoomstart",f)).fire(new a.Event("zoom",f)).fire(new a.Event("zoomend",f)),S&&this.fire(new a.Event("rotatestart",f)).fire(new a.Event("rotate",f)).fire(new a.Event("rotateend",f)),I&&this.fire(new a.Event("pitchstart",f)).fire(new a.Event("pitch",f)).fire(new a.Event("pitchend",f)),this.fire(new a.Event("moveend",f)))}getFreeCameraOptions(){return this.transform.projection.supportsFreeCamera||a.warnOnce(Du),this.transform.getFreeCameraOptions()}setFreeCameraOptions(h,f){const v=this.transform;if(!v.projection.supportsFreeCamera)return a.warnOnce(Du),this;this.stop();const w=v.zoom,S=v.pitch,I=v.bearing;v.setFreeCameraOptions(h);const L=w!==v.zoom,z=S!==v.pitch,H=I!==v.bearing;return this.fire(new a.Event("movestart",f)).fire(new a.Event("move",f)),L&&this.fire(new a.Event("zoomstart",f)).fire(new a.Event("zoom",f)).fire(new a.Event("zoomend",f)),H&&this.fire(new a.Event("rotatestart",f)).fire(new a.Event("rotate",f)).fire(new a.Event("rotateend",f)),z&&this.fire(new a.Event("pitchstart",f)).fire(new a.Event("pitch",f)).fire(new a.Event("pitchend",f)),this.fire(new a.Event("moveend",f)),this}easeTo(h,f){this._stop(!1,h.easeId),((h=a.extend({offset:[0,0],duration:500,easing:a.ease},h)).animate===!1||this._prefersReducedMotion(h))&&(h.duration=0);const v=this.transform,w=this.getZoom(),S=this.getBearing(),I=this.getPitch(),L=this.getPadding(),z="zoom"in h?+h.zoom:w,H="bearing"in h?this._normalizeBearing(h.bearing,S):S,q="pitch"in h?+h.pitch:I,ee="padding"in h?h.padding:v.padding,de=a.Point.convert(h.offset);let _e,be,ve;if(v.projection.name==="globe"){const et=a.MercatorCoordinate.fromLngLat(v.center),_t=de.rotate(-v.angle);et.x+=_t.x/v.worldSize,et.y+=_t.y/v.worldSize;const Zt=et.toLngLat(),dt=a.LngLat.convert(h.center||Zt);this._normalizeCenter(dt),_e=v.centerPoint.add(_t),be=new a.Point(et.x,et.y).mult(v.worldSize),ve=new a.Point(a.mercatorXfromLng(dt.lng),a.mercatorYfromLat(dt.lat)).mult(v.worldSize).sub(be)}else{_e=v.centerPoint.add(de);const et=v.pointLocation(_e),_t=a.LngLat.convert(h.center||et);this._normalizeCenter(_t),be=v.project(et),ve=v.project(_t).sub(be)}const Ee=v.zoomScale(z-w);let te,ye;h.around&&(te=a.LngLat.convert(h.around),ye=v.locationPoint(te));const Oe=this._zooming||z!==w,Le=this._rotating||S!==H,He=this._pitching||q!==I,Ze=!v.isPaddingEqual(ee),Ye=et=>_t=>{if(Oe&&(et.zoom=a.number(w,z,_t)),Le&&(et.bearing=a.number(S,H,_t)),He&&(et.pitch=a.number(I,q,_t)),Ze&&(et.interpolatePadding(L,ee,_t),_e=et.centerPoint.add(de)),te)et.setLocationAtPoint(te,ye);else{const Zt=et.zoomScale(et.zoom-w),dt=z>w?Math.min(2,Ee):Math.max(.5,Ee),Bt=Math.pow(dt,1-_t),St=et.unproject(be.add(ve.mult(_t*Bt)).mult(Zt));et.setLocationAtPoint(et.renderWorldCopies?St.wrap():St,_e)}return h.preloadOnly||this._fireMoveEvents(f),et};if(h.preloadOnly){const et=this._emulate(Ye,h.duration,v);return this._preloadTiles(et),this}const ot={moving:this._moving,zooming:this._zooming,rotating:this._rotating,pitching:this._pitching};return this._zooming=Oe,this._rotating=Le,this._pitching=He,this._padding=Ze,this._easeId=h.easeId,this._prepareEase(f,h.noMoveStart,ot),this._ease(Ye(v),et=>{v.recenterOnTerrain(),this._afterEase(f,et)},h),this}_prepareEase(h,f,v={}){this._moving=!0,this.transform.cameraElevationReference="sea",f||v.moving||this.fire(new a.Event("movestart",h)),this._zooming&&!v.zooming&&this.fire(new a.Event("zoomstart",h)),this._rotating&&!v.rotating&&this.fire(new a.Event("rotatestart",h)),this._pitching&&!v.pitching&&this.fire(new a.Event("pitchstart",h))}_fireMoveEvents(h){this.fire(new a.Event("move",h)),this._zooming&&this.fire(new a.Event("zoom",h)),this._rotating&&this.fire(new a.Event("rotate",h)),this._pitching&&this.fire(new a.Event("pitch",h))}_afterEase(h,f){if(this._easeId&&f&&this._easeId===f)return;this._easeId=void 0,this.transform.cameraElevationReference="ground";const v=this._zooming,w=this._rotating,S=this._pitching;this._moving=!1,this._zooming=!1,this._rotating=!1,this._pitching=!1,this._padding=!1,v&&this.fire(new a.Event("zoomend",h)),w&&this.fire(new a.Event("rotateend",h)),S&&this.fire(new a.Event("pitchend",h)),this.fire(new a.Event("moveend",h))}flyTo(h,f){if(this._prefersReducedMotion(h)){const Ut=a.pick(h,["center","zoom","bearing","pitch","around"]);return this.jumpTo(Ut,f)}this.stop(),h=a.extend({offset:[0,0],speed:1.2,curve:1.42,easing:a.ease},h);const v=this.transform,w=this.getZoom(),S=this.getBearing(),I=this.getPitch(),L=this.getPadding(),z="zoom"in h?a.clamp(+h.zoom,v.minZoom,v.maxZoom):w,H="bearing"in h?this._normalizeBearing(h.bearing,S):S,q="pitch"in h?+h.pitch:I,ee="padding"in h?h.padding:v.padding,de
vendor: 4,925 bytes, line 1423
1423=v.zoomScale(z-w),_e=a.Point.convert(h.offset);let be=v.centerPoint.add(_e);const ve=v.pointLocation(be),Ee=a.LngLat.convert(h.center||ve);this._normalizeCenter(Ee);const te=v.project(ve),ye=v.project(Ee).sub(te);let Oe=h.curve;const Le=Math.max(v.width,v.height),He=Le/de,Ze=ye.mag();if("minZoom"in h){const Ut=a.clamp(Math.min(h.minZoom,w,z),v.minZoom,v.maxZoom),tn=Le/v.zoomScale(Ut-w);Oe=Math.sqrt(tn/Ze*2)}const Ye=Oe*Oe;function ot(Ut){const tn=(He*He-Le*Le+(Ut?-1:1)*Ye*Ye*Ze*Ze)/(2*(Ut?He:Le)*Ye*Ze);return Math.log(Math.sqrt(tn*tn+1)-tn)}function et(Ut){return(Math.exp(Ut)-Math.exp(-Ut))/2}function _t(Ut){return(Math.exp(Ut)+Math.exp(-Ut))/2}const Zt=ot(0);let dt=function(Ut){return _t(Zt)/_t(Zt+Oe*Ut)},Bt=function(Ut){return Le*((_t(Zt)*(et(tn=Zt+Oe*Ut)/_t(tn))-et(Zt))/Ye)/Ze;var tn},St=(ot(1)-Zt)/Oe;if(Math.abs(Ze)<1e-6||!isFinite(St)){if(Math.abs(Le-He)<1e-6)return this.easeTo(h,f);const Ut=He<Le?-1:1;St=Math.abs(Math.log(He/Le))/Oe,Bt=function(){return 0},dt=function(tn){return Math.exp(Ut*Oe*tn)}}h.duration="duration"in h?+h.duration:1e3*St/("screenSpeed"in h?+h.screenSpeed/Oe:+h.speed),h.maxDuration&&h.duration>h.maxDuration&&(h.duration=0);const Yt=S!==H,gt=q!==I,Ft=!v.isPaddingEqual(ee),Jt=Ut=>tn=>{const Mn=tn*St,Wn=1/dt(Mn);Ut.zoom=tn===1?z:w+Ut.scaleZoom(Wn),Yt&&(Ut.bearing=a.number(S,H,tn)),gt&&(Ut.pitch=a.number(I,q,tn)),Ft&&(Ut.interpolatePadding(L,ee,tn),be=Ut.centerPoint.add(_e));const wn=tn===1?Ee:Ut.unproject(te.add(ye.mult(Bt(Mn))).mult(Wn));return Ut.setLocationAtPoint(Ut.renderWorldCopies?wn.wrap():wn,be),Ut._updateCameraOnTerrain(),h.preloadOnly||this._fireMoveEvents(f),Ut};if(h.preloadOnly){const Ut=this._emulate(Jt,h.duration,v);return this._preloadTiles(Ut),this}return this._zooming=!0,this._rotating=Yt,this._pitching=gt,this._padding=Ft,this._prepareEase(f,!1),this._ease(Jt(v),()=>this._afterEase(f),h),this}isEasing(){return!!this._easeFrameId}stop(){return this._stop()}_stop(h,f){if(this._easeFrameId&&(this._cancelRenderFrame(this._easeFrameId),this._easeFrameId=void 0,this._onEaseFrame=void 0),this._onEaseEnd){const v=this._onEaseEnd;this._onEaseEnd=void 0,v.call(this,f)}if(!h){const v=this.handlers;v&&v.stop(!1)}return this}_ease(h,f,v){v.animate===!1||v.duration===0?(h(1),f()):(this._easeStart=a.exported.now(),this._easeOptions=v,this._onEaseFrame=h,this._onEaseEnd=f,this._easeFrameId=this._requestRenderFrame(this._renderFrameCallback))}_renderFrameCallback(){const h=Math.min((a.exported.now()-this._easeStart)/this._easeOptions.duration,1),f=this._onEaseFrame;f&&f(this._easeOptions.easing(h)),h<1?this._easeFrameId=this._requestRenderFrame(this._renderFrameCallback):this.stop()}_normalizeBearing(h,f){h=a.wrap(h,-180,180);const v=Math.abs(h-f);return Math.abs(h-360-f)<v&&(h-=360),Math.abs(h+360-f)<v&&(h+=360),h}_normalizeCenter(h){const f=this.transform;if(!f.renderWorldCopies||f.maxBounds)return;const v=h.lng-f.center.lng;h.lng+=v>180?-360:v<-180?360:0}_prefersReducedMotion(h){return this._respectPrefersReducedMotion&&a.exported.prefersReducedMotion&&!(h&&h.essential)}_emulate(h,f,v){const w=Math.ceil(15*f/1e3),S=[],I=h(v.clone());for(let L=0;L<=w;L++){const z=I(L/w);S.push(z.clone())}return S}}class xn{constructor(h={}){this.options=h,a.bindAll(["_toggleAttribution","_updateEditLink","_updateData","_updateCompact"],this)}getDefaultPosition(){return"bottom-right"}onAdd(h){const f=this.options&&this.options.compact;return this._map=h,this._container=C("div","mapboxgl-ctrl mapboxgl-ctrl-attrib"),this._compactButton=C("button","mapboxgl-ctrl-attrib-button",this._container),C("span","mapboxgl-ctrl-icon",this._compactButton).setAttribute("aria-hidden","true"),this._compactButton.type="button",this._compactButton.addEventListener("click",this._toggleAttribution),this._setElementTitle(this._compactButton,"ToggleAttribution"),this._innerContainer=C("div","mapboxgl-ctrl-attrib-inner",this._container),this._innerContainer.setAttribute("role","list"),f&&this._container.classList.add("mapboxgl-compact"),this._updateAttributions(),this._updateEditLink(),this._map.on("styledata",this._updateData),this._map.on("sourcedata",this._updateData),this._map.on("moveend",this._updateEditLink),f===void 0&&(this._map.on("resize",this._updateCompact),this._updateCompact()),this._container}onRemove(){this._container.remove(),this._map.off("styledata",this._updateData),this._map.off("sourcedata",this._updateData),this._map.off("moveend",this._updateEditLink),this._map.off("resize",this._updateCompact),this._map=void 0,this._attribHTML=void 0}_setElementTitle(h,f){const v=this._map._getUIString(`AttributionControl.${f}`);h.setAttribute("aria-label",v),h.removeAttribute("title"),h.firstElementChild&&h.firstElementChild.setAttribute("title",v)}_toggleAttribution(){this._container.classList.contains("mapboxgl-compact-show")?(this._container.classList.remove("mapboxgl-compact-show"),this._compactButton.setAttribute("aria-expanded","fal
1423se")):(this._container.classList.add("mapboxgl-compact-show"),this._compactButton.setAttribute("aria-expanded","true"))}_updateEditLink(){let h=this._editLink;h||(h=this._editLink=this._container.querySelector(".mapbox-improve-map"));const f=[{key:"owner",value:this.styleOwner},{key:"id",value:this.styleId},{key:"access_token",value:this._map._requestManager._customAccessToken||a.config.ACCESS_TOKEN}];if(h){const v=f.reduce((w,S,I)=>(S.value&&(w+=`${S.key}=${S.value}${I<f.length-1?"&":""}`),w),"?");h.href=`${a.config.FEEDBACK_URL}/${v}#${sf(this._map,!0)}`,h.rel="noopener nofollow",this._setElementTitle(h,"MapFeedback")}}_updateData(h){!h||h.sourceDataType!=="metadata"&&h.sourceDataType!=="visibility"&&h.dataType!=="style"||(this._updateAttributions(),this._updateEditLink())}_updateAttributions(){if(!this._map.style)return;let h=[];if(this._map.style.stylesheet){const w=this._map.style.stylesheet;this.styleOwner=w.owner,this.styleId=w.id}const f=this._map.style._sourceCaches;for(const w in f){const S=f[w];if(S.used){const I=S.getSource();I.attribution&&h.indexOf(I.attribution)<0&&h.push(I.attribution)}}h.sort((w,S)=>w.length-S.length),h=h.filter((w,S)=>{for(let I=S+1;I<h.length;I++)if(h[I].indexOf(w)>=0)return!1;return!0}),this.options.customAttribution&&(Array.isArray(this.options.customAttribution)?h=[...this.options.customAttribution,...h]:h.unshift(this.options.customAttribution));const v=h.join(" | ");v!==this._attribHTML&&(this._attribHTML=v,h.length?(this._innerContainer.innerHTML=v,this._container.classList.remove("mapboxgl-attrib-empty")):this._container.classList.add("mapboxgl-attrib-empty"),this._editLink=null)}_updateCompact(){this._map.getCanvasContainer().offsetWidth<=640?this._container.classList.add("mapboxgl-compact"):this._container.classList.remove("mapboxgl-compact","mapboxgl-compact-show")}}class Vg{constructor(){a.bindAll(["_updateLogo","_updateCompact"],this)}onAdd(h){this._map=h,this._container=C("div","mapboxgl-ctrl");const f=C("a","mapboxgl-ctrl-logo");return f.target="_blank",f.rel="noopener nofollow",f.href="https://www.mapbox.com/",f.setAttribute("aria-label",this._map._getUIString("LogoControl.Title")),f.setAttribute("rel","noopener nofollow"),this._container.appendChild(f),this._container.style.display="none",this._map.on("sourcedata",this._updateLogo),this._updateLogo(),this._map.on("resize",this._updateCompact),this._updateCompact(),this._container}onRemove(){this._container.remove(),this._map.off("sourcedata",this._updateLogo),this._map.off("resize",this._updateCompact)}getDefaultPosition(){return"bottom-left"}_updateLogo(h){h&&h.sourceDataType!=="metadata"||(this._container.style.display=this._logoRequired()?"block":"none")}_logoRequired(){if(!this._map.style)return!0;const h=this._map.style._sourceCaches;if(Object.entries(h).length===0)return!0;for(const f in h){const v=h[f].getSource();if(v.hasOwnProperty("mapbox_logo")&&!v.mapbox_logo)return!1}return!0}_updateCompact(){const h=this._container.children;if(h.length){const f=h[0];this._map.getCanvasContainer().offsetWidth<250?f.classList.add("mapboxgl-compact"):f.classList.remove("mapboxgl-compact")}}}class Gg{constructor(){this._queue=[],this._id=0,this._cleared=!1,this._currentlyRunning=!1}add(h){const f=++this._id;return this._queue.push({callback:h,id:f,cancelled:!1}),f}remove(h){const f=this._currentlyRunning,v=f?this._queue.concat(f):this._queue;for(const w of v)if(w.id===h)return void(w.cancelled=!0)}run(h=0){const f=this._currentlyRunning=this._queue;this._queue=[];for(const v of f)if(!v.cancelled&&(v.callback(h),this._cleared))break;this._cleared=!1,this._currentlyRunning=!1}clear(){this._currentlyRunning&&(this._cleared=!0),this._queue=[]}}function kh(y,h,f){if(y=new a.LngLat(y.lng,y.lat),h){const v=new a.LngLat(y.lng-360,y.lat),w=new a.LngLat(y.lng+360,y.lat),S=360*Math.ceil(Math.abs(y.lng-f.center.lng)/360),I=f.locationPoint(y).distSqr(h),L=h.x<0||h.y<0||h.x>f.width||h.y>f.height;f.locationPoint(v).distSqr(h)<I&&(L||Math.abs(v.lng-f.center.lng)<S)?y=v:f.locationPoint(w).distSqr(h)<I&&(L||Math.abs(w.lng-f.center.lng)<S)&&(y=w)}for(;Math.abs(y.lng-f.center.lng)>180;){const v=f.locationPoint(y);if(v.x>=0&&v.y>=0&&v.x<=f.width&&v.y<=f.height)break;y.lng>f.center.lng?y.lng-=360:y.lng+=360}return y}
1423const Lu={center:"translate(-50%,-50%)",top:"translate(-50%,0)","top-left":"translate(0,0)","top-right":"translate(-100%,0)",bottom:"translate(-50%,-100%)","bottom-left":"translate(0,-100%)","bottom-right":"translate(-100%,-100%)",left:"translate(0,-50%)",right:"translate(-100%,-50%)"};class mn extends a.Evented{constructor(h,f){if(super(),(h instanceof a.window.HTMLElement||f)&&(h=a.extend({element:h},f)),a.bindAll(["_update","_onMove","_onUp","_addDragHandler","_onMapClick","_onKeyPress","_clearFadeTimer"],this),this._anchor=h&&h.anchor||"center",this._color=h&&h.color||"#3FB1CE",this._scale=h&&h.scale||1,this._draggable=h&&h.draggable||!1,this._clickTolerance=h&&h.clickTolerance||0,this._isDragging=!1,this._state="inactive",this._rotation=h&&h.rotation||0,this._rotationAlignment=h&&h.rotationAlignment||"auto",this._pitchAlignment=h&&h.pitchAlignment&&h.pitchAlignment||"auto",this._updateMoving=()=>this._update(!0),this._occludedOpacity=h&&h.occludedOpacity||.2,h&&h.element)this._element=h.element,this._offset=a.Point.convert(h&&h.offset||[0,0]);else{this._defaultMarker=!0,this._element=C("div");const w=41,S=27,I=A("svg",{display:"block",height:w*this._scale+"px",width:S*this._scale+"px",viewBox:`0 0 ${S} ${w}`},this._element),L=A("radialGradient",{id:"shadowGradient"},A("defs",{},I));A("stop",{offset:"10%","stop-opacity":.4},L),A("stop",{offset:"100%","stop-opacity":.05},L),A("ellipse",{cx:13.5,cy:34.8,rx:10.5,ry:5.25,fill:"url(#shadowGradient)"},I),A("path",{fill:this._color,d:"M27,13.5C27,19.07 20.25,27 14.75,34.5C14.02,35.5 12.98,35.5 12.25,34.5C6.75,27 0,19.22 0,13.5C0,6.04 6.04,0 13.5,0C20.96,0 27,6.04 27,13.5Z"},I),A("path",{opacity:.25,d:"M13.5,0C6.04,0 0,6.04 0,13.5C0,19.22 6.75,27 12.25,34.5C13,35.52 14.02,35.5 14.75,34.5C20.25,27 27,19.07 27,13.5C27,6.04 20.96,0 13.5,0ZM13.5,1C20.42,1 26,6.58 26,13.5C26,15.9 24.5,19.18 22.22,22.74C19.95,26.3 16.71,30.14 13.94,33.91C13.74,34.18 13.61,34.32 13.5,34.44C13.39,34.32 13.26,34.18 13.06,33.91C10.28,30.13 7.41,26.31 5.02,22.77C2.62,19.23 1,15.95 1,13.5C1,6.58 6.58,1 13.5,1Z"},I),A("circle",{fill:"white",cx:13.5,cy:13.5,r:5.5},I),this._offset=a.Point.convert(h&&h.offset||[0,-14])}this._element.hasAttribute("aria-label")||this._element.setAttribute("aria-label","Map marker"),this._element.classList.add("mapboxgl-marker"),this._element.addEventListener("dragstart",w=>{w.preventDefault()}),this._element.addEventListener("mousedown",w=>{w.preventDefault()});const v=this._element.classList;for(const w in Lu)v.remove(`mapboxgl-marker-anchor-${w}`);v.add(`mapboxgl-marker-anchor-${this._anchor}`),this._popup=null}addTo(h){return h===this._map||(this.remove(),this._map=h,h.getCanvasContainer().appendChild(this._element),h.on("move",this._updateMoving),h.on("moveend",this._update),h.on("remove",this._clearFadeTimer),h._addMarker(this),this.setDraggable(this._draggable),this._update(),h.on("click",this._onMapClick)),this}remove(){const h=this._map;return h&&(h.off("click",this._onMapClick),h.off("move",this._updateMoving),h.off("moveend",this._update),h.off("mousedown",this._addDragHandler),h.off("touchstart",this._addDragHandler),h.off("mouseup",this._onUp),h.off("touchend",this._onUp),h.off("mousemove",this._onMove),h.off("touchmove",this._onMove),h.off("remove",this._clearFadeTimer),h._removeMarker(this),this._map=void 0),this._clearFadeTimer(),this._element.remove(),this._popup&&this._popup.remove(),this}getLngLat(){return this._lngLat}setLngLat(h){return this._lngLat=a.LngLat.convert(h),this._pos=null,this._popup&&this._popup.setLngLat(this._lngLat),this._update(!0),this}getElement(){return this._element}setPopup(h){if(this._popup&&(this._popup.remove(),this._popup=null,this._element.removeAttribute("role"),this._element.removeEventListener("keypress",this._onKeyPress),this._originalTabIndex||this._element.removeAttribute("tabindex")),h){if(!("offset"in h.options)){const w=Math.sqrt(Math.pow(13.5,2)/2);h.options.offset=this._defaultMarker?{top:[0,0],"top-left":[0,0],"top-right":[0,0],bottom:[0,-38.1],"bottom-left":[w,-1*(38.1-13.5+w)],"bottom-right":[-w,-1*(38.1-13.5+w)],left:[13.5,-1*(38.1-13.5)],right:[-13.5,-1*(38.1-13.5)]}:this._offset}this._popup=h,h._marker=this,this._lngLat&&this._popup.setLngLat(this._lngLat),this._element.setAttribute("role","button"),this._originalTabIndex=this._element.getAttribute("tabindex"),this._originalTabIndex||this._element.setAttribute("tabindex","0"),this._element.addEventListener("keypress",this._onKeyPress),this._element.setAttribute("aria-expanded","fal
1423se")}return this}_onKeyPress(h){const f=h.code,v=h.charCode||h.keyCode;f!=="Space"&&f!=="Enter"&&v!==32&&v!==13||this.togglePopup()}_onMapClick(h){const f=h.originalEvent.target,v=this._element;this._popup&&(f===v||v.contains(f))&&this.togglePopup()}getPopup(){return this._popup}togglePopup(){const h=this._popup;return h?(h.isOpen()?(h.remove(),this._element.setAttribute("aria-expanded","false")):this._map&&(h.addTo(this._map),this._element.setAttribute("aria-expanded","true")),this):this}_behindTerrain(){const h=this._map,f=this._pos;if(!h||!f)return!1;const v=h.unproject(f),w=h.getFreeCameraOptions();if(!w.position)return!1;const S=w.position.toLngLat();return S.distanceTo(v)<.9*S.distanceTo(this._lngLat)}_evaluateOpacity(){const h=this._map;if(!h)return;const f=this._pos;if(!f||f.x<0||f.x>h.transform.width||f.y<0||f.y>h.transform.height)return void this._clearFadeTimer();const v=h.unproject(f);let w;h._showingGlobe()&&a.isLngLatBehindGlobe(h.transform,this._lngLat)?w=0:(w=1-h._queryFogOpacity(v),h.transform._terrainEnabled()&&h.getTerrain()&&this._behindTerrain()&&(w*=this._occludedOpacity)),this._element.style.opacity=`${w}`,this._element.style.pointerEvents=w>0?"auto":"none",this._popup&&this._popup._setOpacity(w),this._fadeTimer=null}_clearFadeTimer(){this._fadeTimer&&(clearTimeout(this._fadeTimer),this._fadeTimer=null)}_updateDOM(){const h=this._pos;if(!h||!this._map)return;const f=this._offset.mult(this._scale);this._element.style.transform=`
1424            translate(${h.x}px,${h.y}px)
1425            ${Lu[this._anchor]}
1426            ${this._calculateXYTransform()} ${this._calculateZTransform()}
1427            translate(${f.x}px,${f.y}px)
1428        `}_calculateXYTransform(){const h=this._pos,f=this._map,v=this.getPitchAlignment();if(!f||!h||v!=="map")return"";if(!f._showingGlobe()){const z=f.getPitch();return z?`rotateX(${z}deg)`:""}const w=a.radToDeg(a.globeTiltAtLngLat(f.transform,this._lngLat)),S=h.sub(a.globeCenterToScreenPoint(f.transform)),I=Math.abs(S.x)+Math.abs(S.y);if(I===0)return"";const L=w/I;return`rotateX(${-S.y*L}deg) rotateY(${S.x*L}deg)`}_calculateZTransform(){const h=this._pos,f=this._map;if(!f||!h)return"";let v=0;const w=this.getRotationAlignment();if(w==="map")if(f._showingGlobe()){const S=f.project(new a.LngLat(this._lngLat.lng,this._lngLat.lat+.001)),I=f.project(new a.LngLat(this._lngLat.lng,this._lngLat.lat-.001)).sub(S);v=a.radToDeg(Math.atan2(I.y,I.x))-90}else v=-f.getBearing();else if(w==="horizon"){const S=a.smoothstep(4,6,f.getZoom()),I=a.globeCenterToScreenPoint(f.transform);I.y+=S*f.transform.height;const L=h.sub(I),z=a.radToDeg(Math.atan2(L.y,L.x));v=(z>90?z-270:z+90)*(1-S)}return v+=this._rotation,v?`rotateZ(${v}deg)`:""}_update(h){a.window.cancelAnimationFrame(this._updateFrameId);const f=this._map;
vendor: 5,216 bytes, line 1428
1428f&&(f.transform.renderWorldCopies&&(this._lngLat=kh(this._lngLat,this._pos,f.transform)),this._pos=f.project(this._lngLat),h===!0?this._updateFrameId=a.window.requestAnimationFrame(()=>{this._element&&this._pos&&this._anchor&&(this._pos=this._pos.round(),this._updateDOM())}):this._pos=this._pos.round(),f._requestDomTask(()=>{this._map&&(this._element&&this._pos&&this._anchor&&this._updateDOM(),(f._showingGlobe()||f.getTerrain()||f.getFog())&&!this._fadeTimer&&(this._fadeTimer=setTimeout(this._evaluateOpacity.bind(this),60)))}))}getOffset(){return this._offset}setOffset(h){return this._offset=a.Point.convert(h),this._update(),this}_onMove(h){const f=this._map;if(!f)return;const v=this._pointerdownPos,w=this._positionDelta;if(v&&w){if(!this._isDragging){const S=this._clickTolerance||f._clickTolerance;if(h.point.dist(v)<S)return;this._isDragging=!0}this._pos=h.point.sub(w),this._lngLat=f.unproject(this._pos),this.setLngLat(this._lngLat),this._element.style.pointerEvents="none",this._state==="pending"&&(this._state="active",this.fire(new a.Event("dragstart"))),this.fire(new a.Event("drag"))}}_onUp(){this._element.style.pointerEvents="auto",this._positionDelta=null,this._pointerdownPos=null,this._isDragging=!1;const h=this._map;h&&(h.off("mousemove",this._onMove),h.off("touchmove",this._onMove)),this._state==="active"&&this.fire(new a.Event("dragend")),this._state="inactive"}_addDragHandler(h){const f=this._map,v=this._pos;f&&v&&this._element.contains(h.originalEvent.target)&&(h.preventDefault(),this._positionDelta=h.point.sub(v),this._pointerdownPos=h.point,this._state="pending",f.on("mousemove",this._onMove),f.on("touchmove",this._onMove),f.once("mouseup",this._onUp),f.once("touchend",this._onUp))}setDraggable(h){this._draggable=!!h;const f=this._map;return f&&(h?(f.on("mousedown",this._addDragHandler),f.on("touchstart",this._addDragHandler)):(f.off("mousedown",this._addDragHandler),f.off("touchstart",this._addDragHandler))),this}isDraggable(){return this._draggable}setRotation(h){return this._rotation=h||0,this._update(),this}getRotation(){return this._rotation}setRotationAlignment(h){return this._rotationAlignment=h||"auto",this._update(),this}getRotationAlignment(){return this._rotationAlignment==="auto"||this._rotationAlignment==="horizon"&&this._map&&!this._map._showingGlobe()?"viewport":this._rotationAlignment}setPitchAlignment(h){return this._pitchAlignment=h||"auto",this._update(),this}getPitchAlignment(){return this._pitchAlignment==="auto"?this.getRotationAlignment():this._pitchAlignment}setOccludedOpacity(h){return this._occludedOpacity=h||.2,this._update(),this}getOccludedOpacity(){return this._occludedOpacity}}const qg={closeButton:!0,closeOnClick:!0,focusAfterOpen:!0,className:"",maxWidth:"240px"},q1=["a[href]","[tabindex]:not([tabindex='-1'])","[contenteditable]:not([contenteditable='false'])","button:not([disabled])","input:not([disabled])","select:not([disabled])","textarea:not([disabled])"].join(", ");function e0(y=new a.Point(0,0),h="bottom"){if(typeof y=="number"){const f=Math.round(Math.sqrt(.5*Math.pow(y,2)));switch(h){case"top":return new a.Point(0,y);case"top-left":return new a.Point(f,f);case"top-right":return new a.Point(-f,f);case"bottom":return new a.Point(0,-y);case"bottom-left":return new a.Point(f,-f);case"bottom-right":return new a.Point(-f,-f);case"left":return new a.Point(y,0);case"right":return new a.Point(-y,0)}return new a.Point(0,0)}return y instanceof a.Point||Array.isArray(y)?a.Point.convert(y):a.Point.convert(y[h]||[0,0])}class Wg{constructor(h){this.jumpTo(h)}getValue(h){if(h<=this._startTime)return this._start;if(h>=this._endTime)return this._end;const f=a.easeCubicInOut((h-this._startTime)/(this._endTime-this._startTime));return this._start*(1-f)+this._end*f}isEasing(h){return h>=this._startTime&&h<=this._endTime}jumpTo(h){this._startTime=-1/0,this._endTime=-1/0,this._start=h,this._end=h}easeTo(h,f,v){this._start=this.getValue(f),this._end=h,this._startTime=f,this._endTime=f+v}}const t0={"AttributionControl.ToggleAttribution":"Toggle attribution","AttributionControl.MapFeedback":"Map feedback","FullscreenControl.Enter":"Enter fullscreen","FullscreenControl.Exit":"Exit fullscreen","GeolocateControl.FindMyLocation":"Find my location","GeolocateControl.LocationNotAvailable":"Location not available","LogoControl.Title":"Mapbox logo","Map.Title":"Map","NavigationControl.ResetBearing":"Reset bearing to north","NavigationControl.ZoomIn":"Zoom in","NavigationControl.ZoomOut":"Zoom out","ScrollZoomBlocker.CtrlMessage":"Use ctrl + scroll to zoom the map","ScrollZoomBlocker.CmdMessage":"Use ⌘ + scroll to zoom the map","TouchPanBlocker.Message":"Use two fingers to move the map"},n0={center:[0,0],zoom:0,bearing:0,pitch:0,minZoom:-2,maxZoom:22,minPitch:0,maxPitch:85,interactive:!0,scrollZoom:!0,boxZoom:!0,dragRotate:!0,dragPan:!0,keyboard:!0,doubleClickZoom:!0,touchZoomRotate:!0,touchPitch:!0,cooperativeGestures:!1,performanceMetricsCollection:!0,bearingSnap:7,clickTolerance:3,pitchWithRotate:!0,hash:!1,attributionControl:!0,failIfMajorPerformanceCaveat:!1,preserveDrawingBuffer:!1,trackResize:!0,optimizeForTerrain:!0,renderWorldCopies:!0,refreshExpiredTiles:!0,minTileCacheSize:null,maxTileC
1428acheSize:null,localIdeographFontFamily:"sans-serif",localFontFamily:null,transformRequest:null,accessToken:null,fadeDuration:300,respectPrefersReducedMotion:!0,crossSourceCollisions:!0},W1={showCompass:!0,showZoom:!0,visualizePitch:!1};class H1{constructor(h,f,v=!1){this._clickTolerance=10,this.element=f,this.mouseRotate=new zg({clickTolerance:h.dragRotate._mouseRotate._clickTolerance}),this.map=h,v&&(this.mousePitch=new Ng({clickTolerance:h.dragRotate._mousePitch._clickTolerance})),a.bindAll(["mousedown","mousemove","mouseup","touchstart","touchmove","touchend","reset"],this),f.addEventListener("mousedown",this.mousedown),f.addEventListener("touchstart",this.touchstart,{passive:!1}),f.addEventListener("touchmove",this.touchmove),f.addEventListener("touchend",this.touchend),f.addEventListener("touchcancel",this.reset)}down(h,f){this.mouseRotate.mousedown(h,f),this.mousePitch&&this.mousePitch.mousedown(h,f),R()}move(h,f){const v=this.map,w=this.mouseRotate.mousemoveWindow(h,f),S=w&&w.bearingDelta;if(S&&v.setBearing(v.getBearing()+S),this.mousePitch){const I=this.mousePitch.mousemoveWindow(h,f),L=I&&I.pitchDelta;L&&v.setPitch(v.getPitch()+L)}}off(){const h=this.element;h.removeEventListener("mousedown",this.mousedown),h.removeEventListener("touchstart",this.touchstart,{passive:!1}),h.removeEventListener("touchmove",this.touchmove),h.removeEventListener("touchend",this.touchend),h.removeEventListener("touchcancel",this.reset),this.offTemp()}offTemp(){N(),a.window.removeEventListener("mousemove",this.mousemove),a.window.removeEventListener("mouseup",this.mouseup)}mousedown(h){this.down(a.extend({},h,{ctrlKey:!0,preventDefault:()=>h.preventDefault()}),W(this.element,h)),a.window.addEventListener("mousemove",this.mousemove),a.window.addEventListener("mouseup",this.mouseup)}mousemove(h){this.move(h,W(this.element,h))}mouseup(h){this.mouseRotate.mouseupWindow(h),this.mousePitch&&this.mousePitch.mouseupWindow(h),this.offTemp()}touchstart(h){h.targetTouches.length!==1?this.reset():(this._startPos=this._lastPos=Q(this.element,h.targetTouches)[0],this.down({type:"mousedown",button:0,ctrlKey:!0,preventDefault:()=>h.preventDefault()},this._startPos))}touchmove(h){h.targetTouches.length!==1?this.reset():(this._lastPos=Q(this.element,h.targetTouches)[0],this.move({preventDefault:()=>h.preventDefault()},this._lastPos))}touchend(h){h.targetTouches.length===0&&this._startPos&&this._lastPos&&this._startPos.dist(this._lastPos)<this._clickTolerance&&this.element.click(),this.reset()}reset(){this.mouseRotate.reset(),this.mousePitch&&this.mousePitch.reset(),delete this._startPos,delete this._lastPos,this.offTemp()}}const Hg={positionOptions:{enableHighAccuracy:!1,maximumAge:0,timeout:6e3},fitBoundsOptions:{maxZoom:15},trackUserLocation:!1,showAccuracyCircle:!0,showUserLocation:!0,showUserHeading:!1},Yg={maxWidth:100,unit:"metric"},Zg={kilometer:"km",meter:"m",mile:"mi",foot:"ft","nautical-mile":"nm"},Ah={version:a.version,supported:g,setRTLTextPlugin:a.setRTLTextPlugin,getRTLTextPluginStatus:a.getRTLTextPluginStatus,Map:class extends Up{constructor(y){if(a.LivePerformanceUtils.mark(a.PerformanceMarkers.create),(y=a.extend({},n0,y)).minZoom!=null&&y.maxZoom!=null&&y.minZoom>y.maxZoom)throw new Error("maxZoom must be greater than or equal to minZoom");if(y.minPitch!=null&&y.maxPitch!=null&&y.minPitch>y.maxPitch)throw new Error("maxPitch must be greater than or equal to minPitch");if(y.minPitch!=null&&y.minPitch<0)throw new Error("minPitch must be greater than or equal to 0");if(y.maxPitch!=null&&y.maxPitch>85)throw new Error("maxPitch must be less than or equal to 85");if(y.antialias&&a.isSafariWithAntialiasingBug(a.window)&&(y.antialias=!1,a.warnOnce("Antialiasing is disabled for this WebGL context to avoid browser bug: https://github.com/mapbox/mapbox-gl-js/issues/11609")),super(new tl(y.minZoom,y.maxZoom,y.minPitch,y.maxPitch,y.renderWorldCopies),y),this._interactive=y.interactive,this._minTileCacheSize=y.minTileCacheSize,this._maxTileCacheSize=y.maxTileCacheSize,this._failIfMajorPerformanceCaveat=y.failIfMajorPerformanceCaveat,this._preserveDrawingBuffer=y.preserveDrawingBuffer,this._antialias=y.antialias,this._useWebGL2=y.useWebGL2,this._trackResize=y.trackResize,this._bearingSnap=y.bearingSnap,this._refreshExpiredTiles=y.refreshExpiredTiles,this._fadeDuration=y.fadeDuration,this._isInitialLoad=!0,this._crossSourceCollisions=y.crossSourceCollisions,this._collectResourceTiming=y.collectResourceTiming,this._optimizeForTerrain=y.optimizeForTerrain,this._language=this._parseLanguage(y.language),this._worldview=y.worldview,this._renderTaskQueue=new Gg,this._domRenderTaskQueue=new Gg,this._controls=[],this._markers=[],this._popups=[],this._mapId=a.uniqueId(),this._locale=a.extend({},t0,y.locale),this._clickTolerance=y.clickTolerance,this._cooperativeGestures=y.cooperativeGestures,this._performanceMetricsCollection=y.performanceMetricsCollection,this._containerWidth=0,this._containerHeight=0,this._averageElevationLastSampledAt=-1/0,this._averageElevationExaggeration=0,this._averageElevation=new Wg(0),this._interactionRange=[1/0,-1/0],this._visibilityHidden=0,this._useExplicitProjection=!1,this._requestManager=new a.RequestManager(y.transformRequest,y.accessToken,y.testMode),this._silenceAuthErrors=!!y.testMode,typeof y.container=="string"){if(this._container=a.window.document.getElementById(y.container),!this._container)throw new Error(`Container '${y.container}' not found.`)}else{if(!(y.container instanceof a.window.HTMLElement))throw new Error("Invalid type: 'container' must be a String or HTMLElement.");this._container=y.container}if(this._container.childNodes.length>0&&a.warnOnce("The map container element should be empty, otherwise the map's interactivity will be negatively impacted. If you want to display a message when WebGL is not supported, use the Mapbox GL Supported plugin instead."),y.maxBounds&&this.setMaxBounds(y.maxBounds),a.bindAll(["_onWindowOnline","_onWindowResize","_onVisibilityChange","_onMapScroll","_contextLost","_contextRestored"],this),this._setupContainer(),this._setupPainter(),this.painter===void 0)throw new Error("Failed to initialize WebGL.");this.on("move",()=>this._update(!1)),this.on("moveend",()=>this._update(!1)),this.on("zoom",()=>this._update(!0)),a.window!==void 0&&(a.window.addEventListener("online",this._onWindowOnline,!1),a.window.addEventListener("resize",this._onWindowResize,!1),a.window.addEventListener("orientationchange",this._onWindowResize,!1),a.window.addEventListener("webkitfullscreenchange",this._onWindowResize,!1),a.window.addEventListener("visibilitychange",this._onVisibilityChange,!1)),this.handlers=new Il(this,y),this._localFontFamily=y.localFontFamily,this._localIdeographFontFamily=y.localIdeographFontFamily,y.style&&this.setStyle(y.style,{localFontFamily:this._localFontFamily,localIdeographFontFamily:this._localIdeographFontFamily}),y.projection&&this.setProjection(y.projection),this._hash=y.hash&&new Lg(typeof y.hash=="string"&&y.hash||void 0).addTo(this),this._hash&&this._hash._onHashChange()||(this.jumpTo({center:y.center,zoom:y.zoom,bearing:y.bearing,pitch:y.pitch}),y.bounds&&(this.resize(),this.fitBounds(y.bounds,a.extend({},y.fitBoundsOptions,{duration:0})))),this.resize(),y.attributionControl&&this.addControl(new xn({customAttribution:y.customAttribution}
vendor: 5,097 bytes, line 1428
1428)),this._logoControl=new Vg,this.addControl(this._logoControl,y.logoPosition),this.on("style.load",()=>{this.transform.unmodified&&this.jumpTo(this.style.stylesheet)}),this.on("data",h=>{this._update(h.dataType==="style"),this.fire(new a.Event(`${h.dataType}data`,h))}),this.on("dataloading",h=>{this.fire(new a.Event(`${h.dataType}dataloading`,h))})}_getMapId(){return this._mapId}addControl(y,h){if(h===void 0&&(h=y.getDefaultPosition?y.getDefaultPosition():"top-right"),!y||!y.onAdd)return this.fire(new a.ErrorEvent(new Error("Invalid argument to map.addControl(). Argument must be a control with onAdd and onRemove methods.")));const f=y.onAdd(this);this._controls.push(y);const v=this._controlPositions[h];return h.indexOf("bottom")!==-1?v.insertBefore(f,v.firstChild):v.appendChild(f),this}removeControl(y){if(!y||!y.onRemove)return this.fire(new a.ErrorEvent(new Error("Invalid argument to map.removeControl(). Argument must be a control with onAdd and onRemove methods.")));const h=this._controls.indexOf(y);return h>-1&&this._controls.splice(h,1),y.onRemove(this),this}hasControl(y){return this._controls.indexOf(y)>-1}getContainer(){return this._container}getCanvasContainer(){return this._canvasContainer}getCanvas(){return this._canvas}resize(y){if(this._updateContainerDimensions(),this._containerWidth===this.transform.width&&this._containerHeight===this.transform.height)return this;this._resizeCanvas(this._containerWidth,this._containerHeight),this.transform.resize(this._containerWidth,this._containerHeight),this.painter.resize(Math.ceil(this._containerWidth),Math.ceil(this._containerHeight));const h=!this._moving;return h&&this.fire(new a.Event("movestart",y)).fire(new a.Event("move",y)),this.fire(new a.Event("resize",y)),h&&this.fire(new a.Event("moveend",y)),this}getBounds(){return this.transform.getBounds()}getMaxBounds(){return this.transform.getMaxBounds()||null}setMaxBounds(y){return this.transform.setMaxBounds(a.LngLatBounds.convert(y)),this._update()}setMinZoom(y){if((y=y??-2)>=-2&&y<=this.transform.maxZoom)return this.transform.minZoom=y,this._update(),this.getZoom()<y?this.setZoom(y):this.fire(new a.Event("zoomstart")).fire(new a.Event("zoom")).fire(new a.Event("zoomend")),this;throw new Error("minZoom must be between -2 and the current maxZoom, inclusive")}getMinZoom(){return this.transform.minZoom}setMaxZoom(y){if((y=y??22)>=this.transform.minZoom)return this.transform.maxZoom=y,this._update(),this.getZoom()>y?this.setZoom(y):this.fire(new a.Event("zoomstart")).fire(new a.Event("zoom")).fire(new a.Event("zoomend")),this;throw new Error("maxZoom must be greater than the current minZoom")}getMaxZoom(){return this.transform.maxZoom}setMinPitch(y){if((y=y??0)<0)throw new Error("minPitch must be greater than or equal to 0");if(y>=0&&y<=this.transform.maxPitch)return this.transform.minPitch=y,this._update(),this.getPitch()<y?this.setPitch(y):this.fire(new a.Event("pitchstart")).fire(new a.Event("pitch")).fire(new a.Event("pitchend")),this;throw new Error("minPitch must be between 0 and the current maxPitch, inclusive")}getMinPitch(){return this.transform.minPitch}setMaxPitch(y){if((y=y??85)>85)throw new Error("maxPitch must be less than or equal to 85");if(y>=this.transform.minPitch)return this.transform.maxPitch=y,this._update(),this.getPitch()>y?this.setPitch(y):this.fire(new a.Event("pitchstart")).fire(new a.Event("pitch")).fire(new a.Event("pitchend")),this;throw new Error("maxPitch must be greater than or equal to minPitch")}getMaxPitch(){return this.transform.maxPitch}getRenderWorldCopies(){return this.transform.renderWorldCopies}setRenderWorldCopies(y){return this.transform.renderWorldCopies=y,this.transform.renderWorldCopies||this._forceMarkerAndPopupUpdate(!0),this._update()}getLanguage(){return this._language}_parseLanguage(y){return y==="auto"?a.window.navigator.language:Array.isArray(y)?y.length===0?void 0:y.map(h=>h==="auto"?a.window.navigator.language:h):y}setLanguage(y){const h=this._parseLanguage(y);if(!this.style||h===this._language)return this;this._language=h,this.style._reloadSources();for(const f of this._controls)f._setLanguage&&f._setLanguage(this._language);return this}getWorldview(){return this._worldview}setWorldview(y){return this.style&&y!==this._worldview?(this._worldview=y,this.style._reloadSources(),this):this}getProjection(){return this.transform.mercatorFromTransition?{name:"globe",center:[0,0]}:this.transform.getProjection()}_showingGlobe(){return this.transform.projection.name==="globe"}setProjection(y){return this._lazyInitEmptyStyle(),y?typeof y=="string"&&(y={name:y}):y=null,this._useExplicitProjection=!!y,this._prioritizeAndUpdateProjection(y,this.style.stylesheet?this.style.stylesheet.projection:null)}_updateProjectionTransition(){if(this.getProjection().name!=="globe")return;const y=this.transform,h=y.projection.name;let f;h==="globe"&&y.zoom>=a.GLOBE_ZOOM_THRESHOLD_MAX?(y.setMercatorFromTransition(),f=!0):h==="mercator"&&y.zoom<a.GLOBE_ZOOM_THRESHOLD_MAX&&(y.setProjection({name:"globe"}),f=!0),f&&(this.style.applyProjectionUpdate(),this.style._forceSymbolLayer
1428Update())}_prioritizeAndUpdateProjection(y,h){return this._updateProjection(y||h||{name:"mercator"})}_updateProjection(y){let h;if(h=y.name==="globe"&&this.transform.zoom>=a.GLOBE_ZOOM_THRESHOLD_MAX?this.transform.setMercatorFromTransition():this.transform.setProjection(y),this.style.applyProjectionUpdate(),h){this.painter.clearBackgroundTiles();for(const f in this.style._sourceCaches)this.style._sourceCaches[f].clearTiles();this._update(!0),this._forceMarkerAndPopupUpdate(!0)}return this}project(y){return this.transform.locationPoint3D(a.LngLat.convert(y))}unproject(y){return this.transform.pointLocation3D(a.Point.convert(y))}isMoving(){return this._moving||this.handlers&&this.handlers.isMoving()||!1}isZooming(){return this._zooming||this.handlers&&this.handlers.isZooming()||!1}isRotating(){return this._rotating||this.handlers&&this.handlers.isRotating()||!1}_isDragging(){return this.handlers&&this.handlers._isDragging()||!1}_createDelegatedListener(y,h,f){if(y==="mouseenter"||y==="mouseover"){let v=!1;const w=I=>{const L=h.filter(H=>this.getLayer(H)),z=L.length?this.queryRenderedFeatures(I.point,{layers:L}):[];z.length?v||(v=!0,f.call(this,new Ho(y,this,I.originalEvent,{features:z}))):v=!1},S=()=>{v=!1};return{layers:new Set(h),listener:f,delegates:{mousemove:w,mouseout:S}}}if(y==="mouseleave"||y==="mouseout"){let v=!1;const w=I=>{const L=h.filter(z=>this.getLayer(z));(L.length?this.queryRenderedFeatures(I.point,{layers:L}):[]).length?v=!0:v&&(v=!1,f.call(this,new Ho(y,this,I.originalEvent)))},S=I=>{v&&(v=!1,f.call(this,new Ho(y,this,I.originalEvent)))};return{layers:new Set(h),listener:f,delegates:{mousemove:w,mouseout:S}}}{const v=w=>{const S=h.filter(L=>this.getLayer(L)),I=S.length?this.queryRenderedFeatures(w.point,{layers:S}):[];I.length&&(w.features=I,f.call(this,w),delete w.features)};return{layers:new Set(h),listener:f,delegates:{[y]:v}}}}on(y,h,f){if(f===void 0)return super.on(y,h);Array.isArray(h)||(h=[h]);const v=this._createDelegatedListener(y,h,f);this._delegatedListeners=this._delegatedListeners||{},this._delegatedListeners[y]=this._delegatedListeners[y]||[],this._delegatedListeners[y].push(v);for(const w in v.delegates)this.on(w,v.delegates[w]);return this}once(y,h,f){if(f===void 0)return super.once(y,h);Array.isArray(h)||(h=[h]);const v=this._createDelegatedListener(y,h,f);for(const w in v.delegates)this.once(w,v.delegates[w]);return this}off(y,h,f){if(f===void 0)return super.off(y,h);h=new Set(Array.isArray(h)?h:[h]);const v=(S,I)=>{if(S.size!==I.size)return!1;for(const L of S)if(!I.has(L))return!1;return!0},w=this._delegatedListeners?this._delegatedListeners[y]:void 0;return w&&(S=>{for(let I=0;I<S.length;I++){const L=S[I];if(L.listener===f&&v(L.layers,h)){for(const z in L.delegates)this.off(z,L.delegates[z]);return S.splice(I,1),this}}})(w),this}queryRenderedFeatures(y,h){return this.style?(h!==void 0||y===void 0||y instanceof a.Point||Array.isArray(y)||(h=y,y=void 0),this.style.queryRenderedFeatures(y=y||[[0,0],[this.transform.width,this.transform.height]],h=h||{},this.transform)):[]}querySourceFeatures(y,h){return this.style.querySourceFeatures(y,h)}isPointOnSurface(y){const{name:h}=this.transform.projection;return h!=="globe"&&h!=="mercator"&&a.warnOnce(`${h} projection does not support isPointOnSurface, this API may behave unexpectedly.`),this.transform.isPointOnSurface(a.Point.convert(y))}setStyle(y,h){return(h=a.extend({},{localIdeographFontFamily:this._localIdeographFontFamily,localFontFamily:this._localFontFamily},h)).diff!==!1&&h.localIdeographFontFamily===this._localIdeographFontFamily&&h.localFontFamily===this._localFontFamily&&this.style&&y?(this._diffStyle(y,h),this):(this._localIdeographFontFamily=h.localIdeographFontFamily,this._localFontFamily=h.localFontFamily,this._updateStyle(y,h))}_getUIString(y){const h=this._locale[y];if(h==null)throw new Error(`Missing UI string '${y}'`);return h}_updateStyle(y,h){return this.style&&(this.style.setEventedParent(null),this.style._remove(),this.style=void 0),y&&(this.style=new ss(this,h||{}),this.style.setEventedParent(this,{style:this.style}),typeof y=="string"?this.style.loadURL(y):this.style.loadJSON(y)),this._updateTerrain(),this}_lazyInitEmptyStyle(){this.style||(this.style=new ss(this,{}),this.style.setEventedParent(this,{style:this.style}),this.style.loadEmpty())}_diffStyle(y,h){if(typeof y=="string"){const f=this._requestManager.normalizeStyleURL(y),v=this._requestManager.transformRequest(f,a.ResourceType.Style);a.getJSON(v,(w,S)=>{w?this.fire(new a.ErrorEvent(w)):S&&this._updateDiff(S,h)})}else typeof y=="object"&&this._updateDiff(y,h)}_updateDiff(y,h){try{this.style.setState(y)&&this._update(!0)}catch(f){a.warnOnce(`Unable to perform style diff: ${f.message||f.error||f}.  Rebuilding the style from scratch.`),this._updateStyle(y,h)}}getStyle(){if(this.style)return this.style.serialize()}isStyleLoaded(){return this.style?this.style.loaded():(a.warnOnce("There is no style added to the map."),!1)}addSource(y,h){return this._lazyInitEmptyStyle(),this.style.addSource(y,h),this._update(!0)}isSourceLoaded(y){return!!this.style&&this.style._isSourceCacheLoaded(y)}areTilesLoaded(){const y=this.style&&this.style._sourceCaches;for(const h in y){const f=y[h]._tiles;for(const v in f){const w=f[v];if(w.state!=="loaded"&&w.state!=="errored")return!1}}return!0}addSourceType(y,h,f){this._lazyInitEmptyStyle(),this.style.addSourceType(y,h,f)}removeSource(y){return this.style.removeSource(y),this._updateTerrain(),this._update(!0)}getSource(y){return this.style.getSource(y)}addImage(y,h,{pixelRatio:f=1,sdf:v=!1,stretchX:w,stretchY:S,content:I}={}){if(this._lazyInitEmptyStyle(),h instanceof a.window.HTMLImageElement||a.window.ImageBitmap&&h instanceof a.window.ImageBitmap){const{width:L,height:z,data:
1428H}=a.exported.getImageData(h);this.style.addImage(y,{data:new a.RGBAImage({width:L,height:z},H),pixelRatio:f,stretchX:w,stretchY:S,content:I,sdf:v,version:0})}else if(h.width===void 0||h.height===void 0)this.fire(new a.ErrorEvent(new Error("Invalid arguments to map.addImage(). The second argument must be an `HTMLImageElement`, `ImageData`, `ImageBitmap`, or object with `width`, `height`, and `data` properties with the same format as `ImageData`")));else{const{width:L,height:z}=h,H=h;this.style.addImage(y,{data:new a.RGBAImage({width:L,height:z},new Uint8Array(H.data)),pixelRatio:f,stretchX:w,stretchY:S,content:I,sdf:v,version:0,userImage:H}),H.onAdd&&H.onAdd(this,y)}}updateImage(y,h){const f=this.style.getImage(y);if(!f)return void this.fire(new a.ErrorEvent(new Error("The map has no image with that id. If you are adding a new image use `map.addImage(...)` instead.")));const v=h instanceof a.window.HTMLImageElement||a.window.ImageBitmap&&h instanceof a.window.ImageBitmap?a.exported.getImageData(h):h,{width:w,height:S}=v;w!==void 0&&S!==void 0?w===f.data.width&&S===f.data.height?(f.data.replace(v.data,!(h instanceof a.window.HTMLImageElement||a.window.ImageBitmap&&h instanceof a.window.ImageBitmap)),this.style.updateImage(y,f)):this.fire(new a.ErrorEvent(new Error(`The width and height of the updated image (${w}, ${S})
1429                must be that same as the previous version of the image
1430                (${f.data.width}, ${f.data.height})`))):this.fire(new a.ErrorEvent(new Error("Invalid arguments to map.updateImage(). The second argument must be an `HTMLImageElement`, `ImageData`, `ImageBitmap`, or object with `width`, `height`, and `data` properties with the same format as `ImageData`")))}hasImage(y){return y?!!this.style.getImage(y):(this.fire(new a.ErrorEvent(new Error("Missing required image id"))),!1)}removeImage(y){this.style.removeImage(y)}loadImage(y,h){a.getImage(this._requestManager.transformRequest(y,a.ResourceType.Image),(f,v)=>{h(f,v instanceof a.window.HTMLImageElement?a.exported.getImageData(v):v)})}listImages(){return this.style.listImages()}addLayer(y,h){return this._lazyInitEmptyStyle(),this.style.addLayer(y,h),this._update(!0)}moveLayer(y,h){return this.style.moveLayer(y,h),this._update(!0)}removeLayer(y){return this.style.removeLayer(y),this._update(!0)}getLayer(y){return this.style.getLayer(y)}setLayerZoomRange(y,h,f){return this.style.setLayerZoomRange(y,h,f),this._update(!0)}setFilter(y,h,f={}){return this.style.setFilter(y,h,f),this._update(!0)}getFilter(y){return this.style.getFilter(y)}setPaintProperty(y,h,f,v={}){return this.style.setPaintProperty(y,h,f,v),this._update(!0)}getPaintProperty(y,h){return this.style.getPaintProperty(y,h)}setLayoutProperty(y,h,f,v={}){return this.style.setLayoutProperty(y,h,f,v),this._update(!0)}getLayoutProperty(y,h){return this.style.getLayoutProperty(y,h)}setLight(y,h={}){return this._lazyInitEmptyStyle(),this.style.setLight(y,h),this._update(!0)}getLight(){return this.style.getLight()}setTerrain(y){return this._lazyInitEmptyStyle(),!y&&this.transform.projection.requiresDraping?this.style.setTerrainForDraping():this.style.setTerrain(y),this._averageElevationLastSampledAt=-1/0,this._update(!0)}getTerrain(){return this.style?this.style.getTerrain():null}setFog(y){return this._lazyInitEmptyStyle(),this.style.setFog(y),this._update(!0)}getFog(){return this.style?this.style.getFog():null}_queryFogOpacity(y){return this.style&&this.style.fog?this.style.fog.getOpacityAtLatLng(a.LngLat.convert(y),this.transform):0}setFeatureState(y,h){return this.style.setFeatureState(y,h),this._update()}removeFeatureState(y,h){return this.style.removeFeatureState(y,h),this._update()}getFeatureState(y){return this.style.getFeatureState(y)}_updateContainerDimensions(){if(!this._container)return;const y=this._container.getBoundingClientRect().width||400,h=this._container.getBoundingClientRect().height||300;let f,v,w,S=this._container;for(;S&&(!v||!w);){const I=a.window.getComputedStyle(S).transform;I&&I!=="none"&&(f=I.match(/matrix.*\((.+)\)/)[1].split(", "),f[0]&&f[0]!=="0"&&f[0]!=="1"&&(v=f[0]),f[3]&&f[3]!=="0"&&f[3]!=="1"&&(w=f[3])),S=S.parentElement}this._containerWidth=v?Math.abs(y/v):y,this._containerHeight=w?Math.abs(h/w):h}_detectMissingCSS(){a.window.getComputedStyle(this._missingCSSCanary).getPropertyValue("background-color")!=="rgb(250, 128, 114)"&&a.warnOnce("This page appears to be missing CSS declarations for Mapbox GL JS, which may cause the map to display incorrectly. Please ensure your page includes mapbox-gl.css, as described 
1430in https://www.mapbox.com/mapbox-gl-js/api/.")}_setupContainer(){const y=this._container;y.classList.add("mapboxgl-map"),(this._missingCSSCanary=C("div","mapboxgl-canary",y)).style.visibility="hidden",this._detectMissingCSS();const h=this._canvasContainer=C("div","mapboxgl-canvas-container",y);this._interactive&&h.classList.add("mapboxgl-interactive"),this._canvas=C("canvas","mapboxgl-canvas",h),this._canvas.addEventListener("webglcontextlost",this._contextLost,!1),this._canvas.addEventListener("webglcontextrestored",this._contextRestored,!1),this._canvas.setAttribute("tabindex","0"),this._canvas.setAttribute("aria-label",this._getUIString("Map.Title")),this._canvas.setAttribute("role","region"),this._updateContainerDimensions(),this._resizeCanvas(this._containerWidth,this._containerHeight);const f=this._controlContainer=C("div","mapboxgl-control-container",y),v=this._controlPositions={};["top-left","top-right","bottom-left","bottom-right"].forEach(w=>{v[w]=C("div",`mapboxgl-ctrl-${w}`,f)}),this._container.addEventListener("scroll",this._onMapScroll,!1)}_resizeCanvas(y,h){const f=a.exported.devicePixelRatio||1;this._canvas.width=f*Math.ceil(y),this._canvas.height=f*Math.ceil(h),this._canvas.style.width=`${y}px`,this._canvas.style.height=`${h}px`}_addMarker(y){this._markers.push(y)}_removeMarker(y){const h=this._markers.indexOf(y);h!==-1&&this._markers.splice(h,1)}_addPopup(y){this._popups.push(y)}_removePopup(y){const h=this._popups.indexOf(y);h!==-1&&this._popups.splice(h,1)}_setupPainter(){const y=a.extend({},g.webGLContextAttributes,{failIfMajorPerformanceCaveat:this._failIfMajorPerformanceCaveat,preserveDrawingBuffer:this._preserveDrawingBuffer,antialias:this._antialias||!1}),h=this._useWebGL2&&this._canvas.getContext("webgl2",y),f=h||this._canvas.getContext("webgl",y)||this._canvas.getContext("experimental-webgl",y);f?(this._useWebGL2&&!h&&a.warnOnce("Failed to create WebGL 2 context. Using WebGL 1."),a.storeAuthState(f,!0),this.painter=new ma(f,this.transform,!!h),this.on("data",v=>{v.dataType==="source"&&this.painter.setTileLoadedFlag(!0)}),a.exported$1.testSupport(f)):this.fire(new a.ErrorEvent(new Error("Failed to initialize WebGL")))}_contextLost(y){y.preventDefault(),this._frame&&(this._frame.cancel(),this._frame=null),this.fire(new a.Event("webglcontextlost",{originalEvent:y}))}_contextRestored(y){this._setupPainter(),this.resize(),this._update(),this.fire(new a.Event("webglcontextrestored",{originalEvent:y}))}_onMapScroll(y){if(y.target===this._container)return this._container.scrollTop=0,this._container.scrollLeft=0,!1}loaded(){return!this._styleDirty&&!this._sourcesDirty&&!!this.style&&this.style.loaded()}_update(y){return this.style?(this._styleDirty=this._styleDirty||y,this._sourcesDirty=!0,this.triggerRepaint(),this):this}_requestRenderFrame(y){return this._update(),this._renderTaskQueue.add(y)}_cancelRenderFrame(y){this._renderTaskQueue.remove(y)}_requestDomTask(y){!this.loaded()||this.loaded()&&!this.isMoving()?y():this._domRenderTaskQueue.add(y)}_render(y){let h;const f=this.painter.context.extTimerQuery,v=a.exported.now();if(this.listens("gpu-timing-frame")&&(h=f.createQueryEXT(),f.beginQueryEXT(f.TIME_ELAPSED_EXT,h)),this.painter.context.setDirty(),this.painter.setBaseState(),(this.isMoving()||this.isRotating()||this.isZooming())&&(this._interactionRange[0]=Math.min(this._interactionRange[0],a.window.performance.now()),this._interactionRange[1]=Math.max(this._interactionRange[1],a.window.performance.now())),this._renderTaskQueue.run(y),this._domRenderTaskQueue.run(y),this._removed)return;this._updateProjectionTransition();const w=this._isInitialLoad?0:this._fadeDuration;if(this.style&&this._styleDirty){this._styleDirty=!1;const L=this.transform.zoom,z=this.transform.pitch,H=a.exported.now(),q=new a.EvaluationParameters(L,{now:H,fadeDuration:w,pitch:z,transition:this.style.getTransition()});this.style.update(q)}this.style&&this.style.fog&&this.style.fog.hasTransition()&&(this.style._markersNeedUpdate=!0,this._sourcesDirty=!0);let S=!1;if(this.style&&this._sourcesDirty?(this._sourcesDirty=!1,this.painter._updateFog(this.style),this._updateTerrain(),S=this._updateAverageElevation(v),this.style._updateSources(this.transform),this._forceMar
vendor: 10,441 bytes, line 1430
1430kerAndPopupUpdate()):S=this._updateAverageElevation(v),this._placementDirty=this.style&&this.style._updatePlacement(this.painter.transform,this.showCollisionBoxes,w,this._crossSourceCollisions),this.style&&this.painter.render(this.style,{showTileBoundaries:this.showTileBoundaries,showTerrainWireframe:this.showTerrainWireframe,showOverdrawInspector:this._showOverdrawInspector,showQueryGeometry:!!this._showQueryGeometry,showTileAABBs:this.showTileAABBs,rotating:this.isRotating(),zooming:this.isZooming(),moving:this.isMoving(),fadeDuration:w,isInitialLoad:this._isInitialLoad,showPadding:this.showPadding,gpuTiming:!!this.listens("gpu-timing-layer"),gpuTimingDeferredRender:!!this.listens("gpu-timing-deferred-render"),speedIndexTiming:this.speedIndexTiming}),this.fire(new a.Event("render")),this.loaded()&&!this._loaded&&(this._loaded=!0,this.fire(new a.Event("load"))),this.style&&this.style.hasTransitions()&&(this._styleDirty=!0),this.style&&!this._placementDirty&&this.style._releaseSymbolFadeTiles(),h){const L=a.exported.now()-v;f.endQueryEXT(f.TIME_ELAPSED_EXT,h),setTimeout(()=>{const z=f.getQueryObjectEXT(h,f.QUERY_RESULT_EXT)/1e6;f.deleteQueryEXT(h),this.fire(new a.Event("gpu-timing-frame",{cpuTime:L,gpuTime:z})),a.window.performance.mark("frame-gpu",{startTime:v,detail:{gpuTime:z}})},50)}if(this.listens("gpu-timing-layer")){const L=this.painter.collectGpuTimers();setTimeout(()=>{const z=this.painter.queryGpuTimers(L);this.fire(new a.Event("gpu-timing-layer",{layerTimes:z}))},50)}if(this.listens("gpu-timing-deferred-render")){const L=this.painter.collectDeferredRenderGpuQueries();setTimeout(()=>{const z=this.painter.queryGpuTimeDeferredRender(L);this.fire(new a.Event("gpu-timing-deferred-render",{gpuTime:z}))},50)}const I=this._sourcesDirty||this._styleDirty||this._placementDirty||S;if(I||this._repaint)this.triggerRepaint();else{const L=!this.isMoving()&&this.loaded();if(L&&(S=this._updateAverageElevation(v,!0)),S)this.triggerRepaint();else if(this._triggerFrame(!1),L&&(this.fire(new a.Event("idle")),this._isInitialLoad=!1,this.speedIndexTiming)){const z=this._calculateSpeedIndex();this.fire(new a.Event("speedindexcompleted",{speedIndex:z})),this.speedIndexTiming=!1}}!this._loaded||this._fullyLoaded||I||(this._fullyLoaded=!0,a.LivePerformanceUtils.mark(a.PerformanceMarkers.fullLoad),this._performanceMetricsCollection&&a.postPerformanceEvent(this._requestManager._customAccessToken,{width:this.painter.width,height:this.painter.height,interactionRange:this._interactionRange,visibilityHidden:this._visibilityHidden,terrainEnabled:!!this.painter.style.getTerrain(),fogEnabled:!!this.painter.style.getFog(),projection:this.getProjection().name,zoom:this.transform.zoom,renderer:this.painter.context.renderer,vendor:this.painter.context.vendor}),this._authenticate())}_forceMarkerAndPopupUpdate(y){for(const h of this._markers)y&&!this.getRenderWorldCopies()&&(h._lngLat=h._lngLat.wrap()),h._update();for(const h of this._popups)!y||this.getRenderWorldCopies()||h._trackPointer||(h._lngLat=h._lngLat.wrap()),h._update()}_updateAverageElevation(y,h=!1){const f=v=>(this.transform.averageElevation=v,this._update(!1),!0);if(!this.painter.averageElevationNeedsEasing())return this.transform.averageElevation!==0&&f(0);if((h||y-this._averageElevationLastSampledAt>500)&&!this._averageElevation.isEasing(y)){const v=this.transform.averageElevation;let w=this.transform.sampleAverageElevation(),S=!1;this.transform.elevation&&(S=this.transform.elevation.exaggeration()!==this._averageElevationExaggeration,this._averageElevationExaggeration=this.transform.elevation.exaggeration()),isNaN(w)?w=0:this._averageElevationLastSampledAt=y;const I=Math.abs(v-w);if(I>1){if(this._isInitialLoad||S)return this._averageElevation.jumpTo(w),f(w);this._averageElevation.easeTo(w,y,300)}else if(I>1e-4)return this._averageElevation.jumpTo(w),f(w)}return!!this._averageElevation.isEasing(y)&&f(this._averageElevation.getValue(y))}_authenticate(){a.getMapSessionAPI(this._getMapId(),this._requestManager._skuToken,this._requestManager._customAccessToken,y=>{if(y&&(y.message===a.AUTH_ERR_MSG||y.status===401)){const h=this.painter.context.gl;a.storeAuthState(h,!1),this._logoControl instanceof Vg&&this._logoControl._updateLogo(),h&&h.clear(h.DEPTH_BUFFER_BIT|h.COLOR_BUFFER_BIT|h.STENCIL_BUFFER_BIT),this._silenceAuthErrors||this.fire(new a.ErrorEvent(new Error("A valid Mapbox access token is required to use Mapbox GL JS. To create an account or a new access token, visit https://account.mapbox.com/")))}}),a.postMapLoadEvent(this._getMapId(),this._requestManager._skuToken,this._requestManager._customAccessToken,()=>{})}_updateTerrain(){const y=this._isDragging();this.painter.updateTerrain(this.style,y)}_calculateSpeedIndex(){const y=this.painter.canvasCopy(),h=this.painter.getCanvasCopiesAndTimestamps();h.timeStamps.push(performance.now());const f=this.painter.context.gl,v=f.createFramebuffer();function w(S){f.framebufferTexture2D(f.FRAMEBUFFER,f.COLOR_ATTACHMENT0,f.TEXTURE_2D,S,0);const I=new Uint8Array(f.drawingBufferWidth*f.drawingBufferHeight*4);return f.readPixels(0,0,f.drawingBufferWidth,f.drawingBufferHeight,f.RGBA,f.UNSIGNED_BYTE,I),I}return f.bindFramebuffer(f.FRAMEBUFFER,v),this._canvasPixelComparison(w(y),h.canvasCopies.map(w),h.timeStamps)}_canvasPixelComparison(y,h,f){let v=f[1]-f[0];const w=y.length/4;for(let S=0;S<h.length;S++){const I=h[S];let L=0;for(let z=0;z<I.length;z+=4)I[z]===y[z]&&I[z+1]===y[z+1]&&I[z+2]===y[z+2]&&I[z+3]===y[z+3]&&(L+=1);v+=(f[S+2]-f[S+1])*(1-L/w)}return v}remove(){this._hash&&this._hash.remove();for(const h of this._controls)h.onRemove(this);this._controls=[],this._frame&&(this._frame.cancel(),this._frame=null),this._renderTaskQueue.clear(),this._domRenderTaskQueue.clear(),this.style&&this.style.destroy(),this.painter.destroy(),this.handlers&&this.handlers.destroy(),this.handlers=void 0,this.setStyle(null),a.window!==void 0&&(a.window.removeEventListener("resize",this._onWindowResize,!1),a.window.removeEventListener("orientationchange",this._onWindowResize,!1),a.window.removeEventListener("webkitfullscreenchange",this._onWindowResize,!1),a.window.removeEventListener("online",this._onWindowOnline,!1),a.window.removeEventListener("visibilitychange",this._onVisibilityChange,!1));const y=this.painter.context.gl.getExtension("WEBGL_lose_context");y&&y.loseContext(),this._canvas.removeEventListener("webglcontextlost",this._contextLost,!1),this._canvas.removeEventListener("webglcontextrestored",this._contextRestored,!1),this._canvasContainer.remove(),this._controlContainer.remove(),this._missingCSSCanary.remove(),this._canvas=void 0,this._canvasContainer=void 0,this._controlContainer=void 0,this._missingCSSCanary=void 0,this._container.classList.remove("mapboxgl-map"),this._container.removeEventListener("scroll",this._onMapScroll,!1),a.removeAuthState(this.painter.context.gl),this._removed=!0,this.fire(new a.Event("remove"))}triggerRepaint(){this._triggerFrame(!0)}_triggerFrame(y){this._renderNextFrame=this._renderNextFrame||y,this.style&&!this._frame&&(this._frame=a.exported.frame(h=>{const f=!!this._renderNextFrame;this._frame=null,this._renderNextFrame=null,f&&this._render(h)}))}_preloadTiles(y){const h=this.style?Object.values(this.style._sourceCaches):[];return a.asyncAll(h,(f,v)=>f._preloadTiles(y,v),()=>{this.triggerRepaint()}),this}_onWindowOnline(){this._update()}_onWindowResize(y){this._trackResize&&this.resize({originalEvent:y})._update()}_onVisibilityChange(){a.window.document.visibilityState==="hidden"&&this._visibilityHidden++}get showTileBoundaries(){return!!this._showTileBoundaries}set showTileBoundaries(y){this._showTileBoundaries!==y&&(this._showTileBoundaries=y,this._update())}get showTerrainWireframe(){return!!this._showTerrainWireframe}set showTerrainWireframe(y){this._showTerrainWireframe!==y&&(this._showTerrainWireframe=y,this._update())}get speedIndexTiming(){return!!this._speedIndexTiming}set speedIndexTiming(y){this._speedIndexTiming!==y&&(this._speedIndexTiming=y,this._update())}get showPadding(){return!!this._showPadding}set showPadding(y){this._showPadding!==y&&(this._showPadding=y,this._update())}get showCollisionBoxes(){return!!this._showCollisionBoxes}set showCollisionBoxes(y){this._showCollisionBoxes!==y&&(this._showCollisionBoxes=y,y?this.style._generateCollisionBoxes():this._update())}get showOverdrawInspector(){return!!this._showOverdrawInspector}set showOverdrawInspector(y){this._showOverdrawInspector!==y&&(this._showOverdrawInspector=y,this._update())}get repaint(){return!!this._repaint}set repaint(y){this._repaint!==y&&(this._repaint=y,this.triggerRepaint())}get vertices(){return!!this._vertices}set vertices(y){this._vertices=y,this._update()}get showTileAABBs(){return!!this._showTileAABBs}set showTileAABBs(y){this._showTileAABBs!==y&&(this._showTileAABBs=y,y&&this._update())}_setCacheLimits(y,h){a.setCacheLimits(y,h)}get version(){return a.version}},NavigationControl:class{constructor(y){this.options=a.extend({},W1,y),this._container=C("div","mapboxgl-ctrl mapboxgl-ctrl-group"),this._container.addEventListener("contextmenu",h=>h.preventDefault()),this.options.showZoom&&(a.bindAll(["_setButtonTitle","_updateZoomButtons"],this),this._zoomInButton=this._createButton("mapboxgl-ctrl-zoom-in",h=>{this._map&&this._map.zoomIn({},{originalEvent:h})}),C("span","mapboxgl-ctrl-icon",this._zoomInButton).setAttribute("aria-hidden","true"),this._zoomOutButton=this._createButton("mapboxgl-ctrl-zoom-out",h=>{this._map&&this._map.zoomOut({},{originalEvent:h})}),C("span","mapboxgl-ctrl-icon",this._zoomOutButton).setAttribute("aria-hidden","true")),this.options.showCompass&&(a.bindAll(["_rotateCompassArrow"],this),this._compass=this._createButton("mapboxgl-ctrl-compass",h=>{const f=this._map;f&&(this.options.visualizePitch?f.resetNorthPitch({},{originalEvent:h}):f.resetNorth({},{originalEvent:h}))}),this._compassIcon=C("span","mapboxgl-ctrl-icon",this._compass),this._compassIcon.setAttribute("aria-hidden","true"))}_updateZoomButtons(){const y=this._map;if(!y)return;const h=y.getZoom(),f=h===y.getMaxZoom(),v=h===y.getMinZoom();this._zoomInButton.disabled=f,this._zoomOutButton.disabled=v,this._zoomInButton.setAttribute("aria-disabled",f.toString()),this._zoomOutButton.setAttribute("aria-disabled",v.toString())}_rotateCompassArrow(){const y=this._map;if(!y)return;const h=this.options.visualizePitch?`scale(${1/Math.pow(Math.cos(y.transform.pitch*(Math.PI/180)
1430),.5)}) rotateX(${y.transform.pitch}deg) rotateZ(${y.transform.angle*(180/Math.PI)}deg)`:`rotate(${y.transform.angle*(180/Math.PI)}deg)`;y._requestDomTask(()=>{this._compassIcon&&(this._compassIcon.style.transform=h)})}onAdd(y){return this._map=y,this.options.showZoom&&(this._setButtonTitle(this._zoomInButton,"ZoomIn"),this._setButtonTitle(this._zoomOutButton,"ZoomOut"),y.on("zoom",this._updateZoomButtons),this._updateZoomButtons()),this.options.showCompass&&(this._setButtonTitle(this._compass,"ResetBearing"),this.options.visualizePitch&&y.on("pitch",this._rotateCompassArrow),y.on("rotate",this._rotateCompassArrow),this._rotateCompassArrow(),this._handler=new H1(y,this._compass,this.options.visualizePitch)),this._container}onRemove(){const y=this._map;y&&(this._container.remove(),this.options.showZoom&&y.off("zoom",this._updateZoomButtons),this.options.showCompass&&(this.options.visualizePitch&&y.off("pitch",this._rotateCompassArrow),y.off("rotate",this._rotateCompassArrow),this._handler&&this._handler.off(),this._handler=void 0),this._map=void 0)}_createButton(y,h){const f=C("button",y,this._container);return f.type="button",f.addEventListener("click",h),f}_setButtonTitle(y,h){if(!this._map)return;const f=this._map._getUIString(`NavigationControl.${h}`);y.setAttribute("aria-label",f),y.firstElementChild&&y.firstElementChild.setAttribute("title",f)}},GeolocateControl:class extends a.Evented{constructor(y){super(),this.options=a.extend({geolocation:a.window.navigator.geolocation},Hg,y),a.bindAll(["_onSuccess","_onError","_onZoom","_finish","_setupUI","_updateCamera","_updateMarker","_updateMarkerRotation","_onDeviceOrientation"],this),this._updateMarkerRotationThrottled=Eh(this._updateMarkerRotation,20),this._numberOfWatches=0}onAdd(y){return this._map=y,this._container=C("div","mapboxgl-ctrl mapboxgl-ctrl-group"),this._checkGeolocationSupport(this._setupUI),this._container}onRemove(){this._geolocationWatchID!==void 0&&(this.options.geolocation.clearWatch(this._geolocationWatchID),this._geolocationWatchID=void 0),this.options.showUserLocation&&this._userLocationDotMarker&&this._userLocationDotMarker.remove(),this.options.showAccuracyCircle&&this._accuracyCircleMarker&&this._accuracyCircleMarker.remove(),this._container.remove(),this._map.off("zoom",this._onZoom),this._map=void 0,this._numberOfWatches=0,this._noTimeout=!1}_checkGeolocationSupport(y){const h=(f=!!this.options.geolocation)=>{this._supportsGeolocation=f,y(f)};this._supportsGeolocation!==void 0?y(this._supportsGeolocation):a.window.navigator.permissions!==void 0?a.window.navigator.permissions.query({name:"geolocation"}).then(f=>h(f.state!=="denied")).catch(()=>h()):h()}_isOutOfMapMaxBounds(y){const h=this._map.getMaxBounds(),f=y.coords;return!!h&&(f.longitude<h.getWest()||f.longitude>h.getEast()||f.latitude<h.getSouth()||f.latitude>h.getNorth())}_setErrorState(){switch(this._watchState){case"WAITING_ACTIVE":this._watchState="ACTIVE_ERROR",this._geolocateButton.classList.remove("mapboxgl-ctrl-geolocate-active"),this._geolocateButton.classList.add("mapboxgl-ctrl-geolocate-active-error");break;case"ACTIVE_LOCK":this._watchState="ACTIVE_ERROR",this._geolocateButton.classList.remove("mapboxgl-ctrl-geolocate-active"),this._geolocateButton.classList.add("mapboxgl-ctrl-geolocate-active-error"),this._geolocateButton.classList.add("mapboxgl-ctrl-geolocate-waiting");break;case"BACKGROUND":this._watchState="BACKGROUND_ERROR",this._geolocateButton.classList.remove("mapboxgl-ctrl-geolocate-background"),this._geolocateButton.classList.add("mapboxgl-ctrl-geolocate-background-error"),this._geolocateButton.classList.add("mapboxgl-ctrl-geolocate-waiting")}}_onSuccess(y){if(this._map){if(this._isOutOfMapMaxBounds(y))return this._setErrorState(),this.fire(new a.Event("outofmaxbounds",y)),this._updateMarker(),void this._finish();if(this.options.trackUserLocation)switch(this._lastKnownPosition=y,this._watchState){case"WAITING_ACTIVE":case"ACTIVE_LOCK":case"ACTIVE_ERROR":this._watchState="ACTIVE_LOCK",this._geolocateButton.classList.remove("mapboxgl-ctrl-geolocate-waiting"),this._geolocateButton.classList.remove("mapboxgl-ctrl-geolocate-active-error"),this._geolocateButton.classList.add("mapboxgl-ctrl-geolocate-active");break;case"BACKGROUND":case"BACKGROUND_ERROR":this._watchState="BACKGROUND",this._geolocateButton.classList.remove("mapboxgl-ctrl-geolocate-waiting"),this._geolocateButton.classList.remove("mapboxgl-ctrl-geolocate-background-error"),this._geolocateButton.classList.add("mapboxgl-ctrl-geolocate-background")}this.options.showUserLocation&&this._watchState!=="OFF"&&this._updateMarker(y),this.options.trackUserLocation&&this._watchState!=="ACTIVE_LOCK"||this._updateCamera(y),this.options.showUserLocation&&this._dotElement.classList.remove("mapboxgl-user-location-dot-stale"),this.fire(new a.Event("geolocate",y)),this._finish()}}_updateCamera(y){const h=new a.LngLat(y.coords.longitude,y.coords.latitude),f=y.coords.accuracy,v=this._map.getBearing(),w=a.extend({bearing:v},this.options.fitBoundsOptions);this._map.fitBounds(h.toBounds(f),w,{geolocateSource:!0})}_updateMarker(y){if(y){const h=new a.LngLat(y.coords.longitude,y.coords.latitude);this._accuracyCircleMarker.setLngLat(h).addTo(this._map),this._userLocationDotMarker.setLngLat(h).addTo(this._map),this._accuracy=y.coords.accuracy,this.options.showUserLocation&&this.options.showAccuracyCircle&&this._updateCircleRadius()}else this._userLocationDotMarker.remove(),this._accuracyCircleMarker.remove()}_updateCircleRadius(){const y=this._map.transform,h=a.mercatorZfromAltitude(1,y._center.lat)*y.worldSize,f=Math.ceil(2*this._accuracy*h);this._circleElement.style.width=`${f}px`,this._circleElement.style.height=`${f}px`}_onZoom(){this.options.showUserLocation&&this.options.showAccuracyCircle&&this._updateCircleRadius()}_updateMarkerRotation(){this._userLocationDotMarker&&typeof this._heading=="number"?(this._userLocationDotMarker.setRotation(this._heading),this._dotElement.classList.add("mapboxgl-user-location-show-heading")):(this._dotElement.classList.remove("mapboxgl-user-location-show-heading"),this._userLocationDotMarker.setRotation(0))}_onError(y){if(this._map){if(this.options.trackUserLocation)if(y.code===1){this._watchState="OFF",this._geolocateButton.classList.remove("mapboxgl-ctrl-geolocate-waiting"),this._geolocateButton.classList.remove("mapboxgl-ctrl-geolocate-active"),this._geolocateButton.classList.remove("mapboxgl-ctrl-geolocate-active-error"),this._geolocateButton.classList.remove("mapboxgl-ctrl-geolocate-background"),this._geolocateButton.classList.remove("mapboxgl-ctrl-geolocate-background-error"),this._geolocateButton.disabled=!0;const h=this._map._getUIString("GeolocateControl.LocationNotAvailable");this._geolocateButton.setAttribute("aria-label",h),this._geolocateButton.firstElementChild&&this._geolocateButton.firstElementChild.setAttribute("title",h),this._geolocationWatchID!==void 0&&this._clearWatch()}else{if(y.code===3&&this._noTimeout)return;this._setErrorState()}this._watchState!=="OFF"&&this.options.showUserLocation&&this._dotElement.classList.add("mapboxgl-user-location-dot-stale"),this.fire(new a.Event("error",y)),this._finish()}}_finish(){this._timeoutId&&clearTimeout(this._timeoutId),this._timeoutId=void 0}_setupUI(y){if(this._map!==void 0){if(this._container.addEventListener("contextmenu",h=>h.preventDefault()),this._geolocateButton=C("button","mapboxgl-ctrl-geolocate",this._container),C("span","mapboxgl-ctrl-icon",this._geolocateButton).setAttribute("aria-hidden","true"),this._geolocateButton.type="button",y===!1){a.warnOnce("Geolocation support is not available so the GeolocateControl will be disabled.");const h=this._map._getUIString("GeolocateControl.LocationNotAvailable");this._geolocateButton.disabled=!0,this._geolocateButton.setAttribute("aria-label",h),this._geolocateButton.firstElementChild&&this._geolocateButton.firstElementChild.setAttribute("title",h)}else{const h=this._map._getUIString("GeolocateControl.FindMyLocation");this._geolocateButton.setAttribute("aria-label",h),this._geolocateButton.firstElementChild&&this._geolocateButton.firstElementChild.setAttribute("title",h)}this.options.trackUserLocation&&(this._geolocateButton.setAttribute("aria-pressed","fal
1430se"),this._watchState="OFF"),this.options.showUserLocation&&(this._dotElement=C("div","mapboxgl-user-location"),this._dotElement.appendChild(C("div","mapboxgl-user-location-dot")),this._dotElement.appendChild(C("div","mapboxgl-user-location-heading")),this._userLocationDotMarker=new mn({element:this._dotElement,rotationAlignment:"map",pitchAlignment:"map"}),this._circleElement=C("div","mapboxgl-user-location-accuracy-circle"),this._accuracyCircleMarker=new mn({element:this._circleElement,pitchAlignment:"map"}),this.options.trackUserLocation&&(this._watchState="OFF"),this._map.on("zoom",this._onZoom)),this._geolocateButton.addEventListener("click",this.trigger.bind(this)),this._setup=!0,this.options.trackUserLocation&&this._map.on("movestart",h=>{h.geolocateSource||this._watchState!=="ACTIVE_LOCK"||h.originalEvent&&h.originalEvent.type==="resize"||(this._watchState="BACKGROUND",this._geolocateButton.classList.add("mapboxgl-ctrl-geolocate-background"),this._geolocateButton.classList.remove("mapboxgl-ctrl-geolocate-active"),this.fire(new a.Event("trackuserlocationend")))})}}_onDeviceOrientation(y){this._userLocationDotMarker&&(y.webkitCompassHeading?this._heading=y.webkitCompassHeading:y.absolute===!0&&(this._heading=-1*y.alpha),this._updateMarkerRotationThrottled())}trigger(){if(!this._setup)return a.warnOnce("Geolocate control triggered before added to a map"),!1;if(this.options.trackUserLocation){switch(this._watchState){case"OFF":this._watchState="WAITING_ACTIVE",this.fire(new a.Event("trackuserlocationstart"));break;case"WAITING_ACTIVE":case"ACTIVE_LOCK":case"ACTIVE_ERROR":case"BACKGROUND_ERROR":this._numberOfWatches--,this._noTimeout=!1,this._watchState="OFF",this._geolocateButton.classList.remove("mapboxgl-ctrl-geolocate-waiting"),this._geolocateButton.classList.remove("mapboxgl-ctrl-geolocate-active"),this._geolocateButton.classList.remove("mapboxgl-ctrl-geolocate-active-error"),this._geolocateButton.classList.remove("mapboxgl-ctrl-geolocate-background"),this._geolocateButton.classList.remove("mapboxgl-ctrl-geolocate-background-error"),this.fire(new a.Event("trackuserlocationend"));break;case"BACKGROUND":this._watchState="ACTIVE_LOCK",this._geolocateButton.classList.remove("mapboxgl-ctrl-geolocate-background"),this._lastKnownPosition&&this._updateCamera(this._lastKnownPosition),this.fire(new a.Event("trackuserlocationstart"))}switch(this._watchState){case"WAITING_ACTIVE":this._geolocateButton.classList.add("mapboxgl-ctrl-geolocate-waiting"),this._geolocateButton.classList.add("mapboxgl-ctrl-geolocate-active");break;case"ACTIVE_LOCK":this._geolocateButton.classList.add("mapboxgl-ctrl-geolocate-active");break;case"ACTIVE_ERROR":this._geolocateButton.classList.add("mapboxgl-ctrl-geolocate-waiting"),this._geolocateButton.classList.add("mapboxgl-ctrl-geolocate-active-error");break;case"BACKGROUND":this._geolocateButton.classList.add("mapboxgl-ctrl-geolocate-background");break;case"BACKGROUND_ERROR":this._geolocateButton.classList.add("mapboxgl-ctrl-geolocate-waiting"),this._geolocateButton.classList.add("mapboxgl-ctrl-geolocate-background-error")}if(this._watchState==="OFF"&&this._geolocationWatchID!==void 0)this._clearWatch();else if(this._geolocationWatchID===void 0){let y;this._geolocateButton.classList.add("mapboxgl-ctrl-geolocate-waiting"),this._geolocateButton.setAttribute("aria-pressed","true"),this._numberOfWatches++,this._numberOfWatches>1?(y={maximumAge:6e5,timeout:0},this._noTimeout=!0):(y=this.options.positionOptions,this._noTimeout=!1),this._geolocationWatchID=this.options.geolocation.watchPosition(this._onSuccess,this._onError,y),this.options.showUserHeading&&this._addDeviceOrientationListener()}}else this.options.geolocation.getCurrentPosition(this._onSuccess,this._onError,this.options.positionOptions),this._timeoutId=setTimeout(this._finish,1e4);return!0}_addDeviceOrientationListener(){const y=()=>{a.window.addEventListener("ondeviceorientationabsolute"in a.window?"deviceorientationabsolute":"deviceorientation",this._onDeviceOrientation)};a.window.DeviceMotionEvent!==void 0&&typeof a.window.DeviceMotionEvent.requestPermission=="function"?DeviceOrientationEvent.requestPermission().then(h=>{h==="granted"&&y()}).catch(console.error):y()}_clearWatch(){this.options.geolocation.clearWatch(this._geolocationWatchID),a.window.removeEventListener("deviceorientation",this._onDeviceOrientation),a.window.removeEventListener("deviceorientationabsolute",this._onDeviceOrientation),this._geolocationWatchID=void 0,this._geolocateButton.classList.remove("mapboxgl-ctrl-geolocate-waiting"),this._geolocateButton.setAttribute("aria-pressed","fal
1430se"),this.options.showUserLocation&&this._updateMarker(null)}},AttributionControl:xn,ScaleControl:class{constructor(y){this.options=a.extend({},Yg,y),this._isNumberFormatSupported=function(){try{return new Intl.NumberFormat("en",{style:"unit",unitDisplay:"short",unit:"meter"}),!0}catch{return!1}}(),a.bindAll(["_update","_setScale","setUnit"],this)}getDefaultPosition(){return"bottom-left"}_update(){const y=this.options.maxWidth||100,h=this._map,f=h._containerHeight/2,v=h._containerWidth/2-y/2,w=h.unproject([v,f]),S=h.unproject([v+y,f]),I=w.distanceTo(S);if(this.options.unit==="imperial"){const L=3.2808*I;L>5280?this._setScale(y,L/5280,"mile"):this._setScale(y,L,"foot")}else this.options.unit==="nautical"?this._setScale(y,I/1852,"nautical-mile"):I>=1e3?this._setScale(y,I/1e3,"kilometer"):this._setScale(y,I,"meter")}_setScale(y,h,f){this._map._requestDomTask(()=>{const v=function(S){const I=Math.pow(10,`${Math.floor(S)}`.length-1);let L=S/I;return L=L>=10?10:L>=5?5:L>=3?3:L>=2?2:L>=1?1:function(z){const H=Math.pow(10,Math.ceil(-Math.log(z)/Math.LN10));return Math.round(z*H)/H}(L),I*L}(h),w=v/h;this._container.innerHTML=this._isNumberFormatSupported&&f!=="nautical-mile"?new Intl.NumberFormat(this._language,{style:"unit",unitDisplay:"short",unit:f}).format(v):`${v}&nbsp;${Zg[f]}`,this._container.style.width=y*w+"px"})}onAdd(y){return this._map=y,this._language=y.getLanguage(),this._container=C("div","mapboxgl-ctrl mapboxgl-ctrl-scale",y.getContainer()),this._container.dir="auto",this._map.on("move",this._update),this._update(),this._container}onRemove(){this._container.remove(),this._map.off("move",this._update),this._map=void 0}_setLanguage(y){this._language=y,this._update()}setUnit(y){this.options.unit=y,this._update()}},FullscreenControl:class{constructor(y){this._fullscreen=!1,y&&y.container&&(y.container instanceof a.window.HTMLElement?this._container=y.container:a.warnOnce("Full screen control 'container' must be a DOM element.")),a.bindAll(["_onClickFullscreen","_changeIcon"],this),"onfullscreenchange"in a.window.document?this._fullscreenchange="fullscreenchange":"onwebkitfullscreenchange"in a.window.document&&(this._fullscreenchange="webkitfullscreenchange")}onAdd(y){return this._map=y,this._container||(this._container=this._map.getContainer()),this._controlContainer=C("div","mapboxgl-ctrl mapboxgl-ctrl-group"),this._checkFullscreenSupport()?this._setupUI():(this._controlContainer.style.display="none",a.warnOnce("This device does not support fullscreen mode.")),this._controlContainer}onRemove(){this._controlContainer.remove(),this._map=null,a.window.document.removeEventListener(this._fullscreenchange,this._changeIcon)}_checkFullscreenSupport(){return!(!a.window.document.fullscreenEnabled&&!a.window.document.webkitFullscreenEnabled)}_setupUI(){const y=this._fullscreenButton=C("button","mapboxgl-ctrl-fullscreen",this._controlContainer);C("span","mapboxgl-ctrl-icon",y).setAttribute("aria-hidden","true"),y.type="button",this._updateTitle(),this._fullscreenButton.addEventListener("click",this._onClickFullscreen),a.window.document.addEventListener(this._fullscreenchange,this._changeIcon)}_updateTitle(){const y=this._getTitle();this._fullscreenButton.setAttribute("aria-label",y),this._fullscreenButton.firstElementChild&&this._fullscreenButton.firstElementChild.setAttribute("title",y)}_getTitle(){return this._map._getUIString(this._isFullscreen()?"FullscreenControl.Exit":"FullscreenControl.Enter")}_isFullscreen(){return this._fullscreen}_changeIcon(){(a.window.document.fullscreenElement||a.window.document.webkitFullscreenElement)===this._container!==this._fullscreen&&(this._fullscreen=!this._fullscreen,this._fullscreenButton.classList.toggle("mapboxgl-ctrl-shrink"),this._fullscreenButton.classList.toggle("mapboxgl-ctrl-fullscreen"),this._updateTitle())}_onClickFullscreen(){this._isFullscreen()?a.window.document.exitFullscreen?a.window.document.exitFullscreen():a.window.document.webkitCancelFullScreen&&a.window.document.webkitCancelFullScreen():this._container.requestFullscreen?this._container.requestFullscreen():this._container.webkitRequestFullscreen&&this._container.webkitRequestFullscreen()}},Popup:class extends a.Evented{constructor(y){super(),this.options=a.extend(Object.create(qg),y),a.bindAll(["_update","_onClose","remove","_onMouseEvent"],this),this._classList=new Set(y&&y.className?y.className.trim().split(/\s+/):[])}addTo(y){return this._map&&this.remove(),this._map=y,this.options.closeOnClick&&y.on("preclick",this._onClose),this.options.closeOnMove&&y.on("move",this._onClose),y.on("remove",this.remove),this._update(),y._addPopup(this),this._focusFirstElement(),this._trackPointer?(y.on("mousemove",this._onMouseEvent),y.on("mouseup",this._onMouseEvent),y._canvasContainer.classList.add("mapboxgl-track-pointer")):y.on("move",this._update),this.fire(new a.Event("open")),this}isOpen(){return!!this._map}remove(){this._content&&this._content.remove(),this._container&&(this._container.remove(),this._container=void 0);const y=this._map;return y&&(y.off("move",this._update),y.off("move",this._onClose),y.off("preclick",this._onClose),y.off("click",this._onClose),y.off("remove",this.remove),y.off("mousemove",this._onMouseEvent),y.off("mouseup",this._onMouseEvent),y.off("drag",this._onMouseEvent),y._canvasContainer&&y._canvasContainer.classList.remove("mapboxgl-track-pointer"),y._removePopup(this),this._map=void 0),this.fire(new a.Event("close")),this}getLngLat(){return this._lngLat}setLngLat(y){this._lngLat=a.LngLat.convert(y),this._pos=null,this._trackPointer=!1,this._update();const h=this._map;return h&&(h.on("move",this._update),h.off("mousemove",this._onMouseEvent),h._canvasContainer.classList.remove("mapboxgl-track-pointer")),this}trackPointer(){this._trackPointer=!0,this._pos=null,this._update();const y=this._map;return y&&(y.off("move",this._update),y.on("mousemove",this._onMouseEvent),y.on("drag",this._onMouseEvent),y._canvasContainer.classList.add("mapboxgl-track-pointer")),this}getElement(){return this._container}setText(y){return this.setDOMContent(a.window.document.createTextNode(y))}setHTML(y){const h=a.window.document.createDocumentFragment(),f=a.window.document.createElement("body");let v;for(f.innerHTML=y;v=f.firstChild,v;)h.appendChild(v);return this.setDOMContent(h)}getMaxWidth(){return this._container&&this._container.style.maxWidth}setMaxWidth(y){return this.options.maxWidth=y,this._update(),this}setDOMContent(y){let h=this._content;if(h)for(;h.hasChildNodes();)h.firstChild&&h.removeChild(h.firstChild);else h=this._content=C("div","mapboxgl-popup-content",this._container||void 0);if(h.appendChild(y),this.options.closeButton){const f=this._closeButton=C("button","mapboxgl-popup-close-button",h);f.type="button",f.setAttribute("aria-label","Close popup"),f.setAttribute("aria-hidden","true"),f.innerHTML="&#215;",f.addEventListener("click",this._onClose)}return this._update(),this._focusFirstElement(),this}addClassName(y){return this._classList.add(y),this._updateClassList(),this}removeClassName(y){return this._classList.delete(y),this._updateClassList(),this}setOffset(y){return this.options.offset=y,this._update(),this}toggleClassName(y){let h;return this._classList.delete(y)?h=!1:(this._classList.add(y),h=!0),this._updateClassList(),h}_onMouseEvent(y){this._update(y.point)}_getAnchor(y){if(this.options.anchor)return this.options.anchor;const h=this._map,f=this._container,v=this._pos;
1430if(!h||!f||!v)return"bottom";const w=f.offsetWidth,S=f.offsetHeight,I=v.x<w/2,L=v.x>h.transform.width-w/2;if(v.y+y<S)return I?"top-left":L?"top-right":"top";if(v.y>h.transform.height-S){if(I)return"bottom-left";if(L)return"bottom-right"}return I?"left":L?"right":"bottom"}_updateClassList(){const y=this._container;if(!y)return;const h=[...this._classList];h.push("mapboxgl-popup"),this._anchor&&h.push(`mapboxgl-popup-anchor-${this._anchor}`),this._trackPointer&&h.push("mapboxgl-popup-track-pointer"),y.className=h.join(" ")}_update(y){const h=this._map,f=this._content;if(!h||!this._lngLat&&!this._trackPointer||!f)return;let v=this._container;if(v||(v=this._container=C("div","mapboxgl-popup",h.getContainer()),this._tip=C("div","mapboxgl-popup-tip",v),v.appendChild(f)),this.options.maxWidth&&v.style.maxWidth!==this.options.maxWidth&&(v.style.maxWidth=this.options.maxWidth),h.transform.renderWorldCopies&&!this._trackPointer&&(this._lngLat=kh(this._lngLat,this._pos,h.transform)),!this._trackPointer||y){const w=this._pos=this._trackPointer&&y?y:h.project(this._lngLat),S=e0(this.options.offset),I=this._anchor=this._getAnchor(S.y),L=e0(this.options.offset,I),z=w.add(L).round();h._requestDomTask(()=>{this._container&&I&&(this._container.style.transform=`${Lu[I]} translate(${z.x}px,${z.y}px)`)})}if(!this._marker&&h._showingGlobe()){const w=a.isLngLatBehindGlobe(h.transform,this._lngLat)?0:1;this._setOpacity(w)}this._updateClassList()}_focusFirstElement(){if(!this.options.focusAfterOpen||!this._container)return;const y=this._container.querySelector(q1);y&&y.focus()}_onClose(){this.remove()}_setOpacity(y){this._container&&(this._container.style.opacity=`${y}`),this._content&&(this._content.style.pointerEvents=y?"auto":"none")}},Marker:mn,Style:ss,LngLat:a.LngLat,LngLatBounds:a.LngLatBounds,Point:a.Point,MercatorCoordinate:a.MercatorCoordinate,FreeCameraOptions:Ml,Evented:a.Evented,config:a.config,prewarm:function(){Lc().acquire(ws)},clearPrewarmedResources:function(){const y=Hr;y&&(y.isPreloaded()&&y.numActive()===1?(y.release(ws),Hr=null):console.warn("Could not clear WebWorkers since there are active Map instances that still reference it. The pre-warmed WebWorker pool can only be cleared when all map instances have been removed with map.remove()"))},get accessToken(){return a.config.ACCESS_TOKEN},set accessToken(y){a.config.ACCESS_TOKEN=y},get baseApiUrl(){return a.config.API_URL},set baseApiUrl(y){a.config.API_URL=y},get workerCount(){return Po.workerCount},set workerCount(y){Po.workerCount=y},get maxParallelImageRequests(){return a.config.MAX_PARALLEL_IMAGE_REQUESTS},set maxParallelImageRequests(y){a.config.MAX_PARALLEL_IMAGE_REQUESTS=y},clearStorage(y){a.clearTileCache(y)},workerUrl:"",workerClass:null,setNow:a.exported.setNow,restoreNow:a.exported.restoreNow};return Ah});var c=i;return c})})(T5);var P2=T5.exports;const _u=Rd(P2);var Ag=qie,Gie=Object.prototype.hasOwnProperty;function qie(){for(var e={},t=0;t<arguments.length;t++){var n=arguments[t];for(var r in n)Gie.call(n,r)&&(e[r]=n[r])}return e}var S5={exports:{}};(function(e,t){(function(){var n={};e.exports=n,n.simpleFilter=function(r,i){return i.filter(function(s){return n.test(r,s)})},n.test=function(r,i){return n.match(r,i)!==null},n.match=function(r,i,s){s=s||{};var c=0,a=[],m=i.length,g=0,x=0,T=s.pre||"",C=s.post||"",A=s.caseSensitive&&i||i.toLowerCase(),P;r=s.caseSensitive&&r||r.toLowerCase();for(var D=0;D<m;D++)P=i[D],A[D]===r[c]?(P=T+P+C,c+=1,x+=1+x):x=0,g+=x,a[a.length]=P;return c===r.length?(g=A===r?1/0:g,{rendered:a.join(""),score:g}):null},n.filter=function(r,i,s){return!i||i.length===0?[]:typeof r!="string"?i:(s=s||{},i.reduce(function(c,a,m,g){var x=a;s.extract&&(x=s.extract(a));var T=n.match(r,x,s);return T!=null&&(c[c.length]={string:T.rendered,score:T.score,index:m,original:a}),c},[]).sort(function(c,a){var m=a.score-c.score;return m||c.index-a.index}))}})()})(S5);var Wie=S5.exports,qs=function(e){return this.component=e,this.items=[],this.active=0,this.wrapper=document.createElement("div"),this.wrapper.className="suggestions-wrapper",this.element=document.createElement("ul"),this.element.className="suggestions",this.wrapper.appendChild(this.element),this.selectingListItem=!1,e.el.parentNode.insertBefore(this.wrapper,e.el.nextSibling),this};qs.prototype.show=function(){this.element.style.display="block"};qs.prototype.hide=function(){this.element.style.display="none"};qs.prototype.add=function(e){this.items.push(e)};qs.prototype.clear=function(){this.items=[],this.active=0};qs.prototype.isEmpty=function(){return!this.items.length};qs.prototype.isVisible=function(){return this.element.style.display==="block"};qs.prototype.draw=function(){if(this.element.innerHTML="",this.items.length===0){this.hide();return}for(var e=0;e<this.items.length;e++)this.drawItem(this.items[e],this.active===e);this.show()};qs.prototype.drawItem=function(e,t){var n=document.createElement("li"),r=document.createElement("a");t&&(n.className+=" active"),r.innerHTML=e.string,n.appendChild(r),this.element.appendChild(n),n.addEventListener("mousedown",function(){this.selectingListItem=!0}.bind(this)),n.addEventListener("mouseup",function(){this.handleMouseUp.call(this,e)}.bind(this))};qs.prototype.handleMouseUp=function(e){this.selectingListItem=!1,this.component.value(e.original),this.clear(),this.draw()};qs.prototype.move=function(e){this.active=e,this.draw()};qs.prototype.previous=function(){this.move(this.active===0?this.items.length-1:this.active-1)};qs.prototype.next=function(){this.move(this.active===this.items.length-1?0:this.active+1)};qs.prototype.drawError=function(e){var t=document.createElement("li");t.innerHTML=e,this.element.appendChild(t),this.show()};var Hie=qs,Yie=Ag,Zie=Wie,Xie=Hie,rs=function(e,t,n){return n=n||{},this.options=Yie({minLength:2,limit:5,filter:!0,hideOnBlur:!0},n),this.el=e,this.data=t||[],this.list=new Xie(this),this.query="",this.selected=null,this.list.draw(),this.el.addEventListener("keyup",function(r){this.handleKeyUp(r.keyCode)}.bind(this),!1),this.el.addEventListener("keydown",function(r){this.handleKeyDown(r)}.bind(this)),this.el.addEventListener("focus",function(){this.handleFocus()}.bind(this)),this.el.addEventListener("blur",function(){this.handleBlur()}.bind(this)),this.el.addEventListener("paste",function(r){this.handlePaste(r)}.bind(this)),this.render=this.options.render?this.options.render.bind(this):this.render.bind(this),this.getItemV
1430alue=this.options.getItemValue?this.options.getItemValue.bind(this):this.getItemValue.bind(this),this};rs.prototype.handleKeyUp=function(e){e===40||e===38||e===27||e===13||e===9||this.handleInputChange(this.el.value)};rs.prototype.handleKeyDown=function(e){switch(e.keyCode){case 13:case 9:this.list.isEmpty()||(this.list.isVisible()&&e.preventDefault(),this.value(this.list.items[this.list.active].original),this.list.hide());break;case 27:this.list.isEmpty()||this.list.hide();break;case 38:this.list.previous();break;case 40:this.list.next();break}};rs.prototype.handleBlur=function(){!this.list.selectingListItem&&this.options.hideOnBlur&&this.list.hide()};rs.prototype.handlePaste=function(e){if(e.clipboardData)this.handleInputChange(e.clipboardData.getData("Text"));else{var t=this;setTimeout(function(){t.handleInputChange(e.target.value)},100)}};rs.prototype.handleInputChange=function(e){if(this.query=this.normalize(e),this.list.clear(),this.query.length<this.options.minLength){this.list.draw();return}this.getCandidates(function(t){for(var n=0;n<t.length&&(this.list.add(t[n]),n!==this.options.limit-1);n++);this.list.draw()}.bind(this))};rs.prototype.handleFocus=function(){this.list.isEmpty()||this.list.show(),this.list.selectingListItem=!1};rs.prototype.update=function(e){this.data=e,this.handleKeyUp()};rs.prototype.clear=function(){this.data=[],this.list.clear()};rs.prototype.normalize=function(e){return e=e.toLowerCase(),e};rs.prototype.match=function(e,t){return e.indexOf(t)>-1};rs.prototype.value=function(e){if(this.selected=e,this.el.value=this.getItemValue(e),document.createEvent){var t=document.createEvent("HTMLEvents");t.initEvent("change",!0,!1),this.el.dispatchEvent(t)}else this.el.fireEvent("onchange")};rs.prototype.getCandidates=function(e){var t={pre:"<strong>",post:"</strong>",extract:function(r){return this.getItemValue(r)}.bind(this)},n;this.options.filter?(n=Zie.filter(this.query,this.data,t),n=n.map(function(r){return{original:r.original,string:this.render(r.original,r.string)}}.bind(this))):n=this.data.map(function(r){var i=this.render(r);return{original:r,string:i}}.bind(this)),e(n)};
1430rs.prototype.getItemValue=function(e){return e};rs.prototype.render=function(e,t){if(t)return t;for(var n=e.original?this.getItemValue(e.original):this.getItemValue(e),r=this.normalize(n),i=r.lastIndexOf(this.query);i>-1;){var s=i+this.query.length;n=n.slice(0,i)+"<strong>"+n.slice(i,s)+"</strong>"+n.slice(s),i=r.slice(0,i).lastIndexOf(this.query)}return n};rs.prototype.renderError=function(e){this.list.drawError(e)};var Kie=rs,C5=Kie,Qie=C5;typeof window<"u"&&(window.Suggestions=C5);var Jie="Expected a function",RL=0/0,eoe="[object Symbol]",toe=/^\s+|\s+$/g,noe=/^[-+]0x[0-9a-f]+$/i,roe=/^0b[01]+$/i,ioe=/^0o[0-7]+$/i,ooe=parseInt,aoe=typeof oo=="object"&&oo&&oo.Object===Object&&oo,soe=typeof self=="object"&&self&&self.Object===Object&&self,loe=aoe||soe||Function("return this")(),coe=Object.prototype,uoe=coe.toString,hoe=Math.max,doe=Math.min,nE=function(){return loe.Date.now()};function foe(e,t,n){var r,i,s,c,a,m,g=0,x=!1,T=!1,C=!0;if(typeof e!="function")throw new TypeError(Jie);t=FL(t)||0,fC(n)&&(x=!!n.leading,T="maxWait"in n,s=T?hoe(FL(n.maxWait)||0,t):s,C="trailing"in n?!!n.trailing:C);function A(Q){var Z=r,K=i;return r=i=void 0,g=Q,c=e.apply(K,Z),c}function P(Q){return g=Q,a=setTimeout(R,t),x?A(Q):c}function D(Q){var Z=Q-m,K=Q-g,Y=t-Z;return T?doe(Y,s-K):Y}function B(Q){var Z=Q-m,K=Q-g;return m===void 0||Z>=t||Z<0||T&&K>=s}function R(){var Q=nE();if(B(Q))return N(Q);a=setTimeout(R,D(Q))}function N(Q){return a=void 0,C&&r?A(Q):(r=i=void 0,c)}function j(){a!==void 0&&clearTimeout(a),g=0,r=m=i=a=void 0}function U(){return a===void 0?c:N(nE())}function W(){var Q=nE(),Z=B(Q);if(r=arguments,i=this,m=Q,Z){if(a===void 0)return P(m);if(T)return a=setTimeout(R,t),A(m)}return a===void 0&&(a=setTimeout(R,t)),c}return W.cancel=j,W.flush=U,W}function fC(e){var t=typeof e;return!!e&&(t=="object"||t=="function")}function poe(e){return!!e&&typeof e=="object"}function moe(e){return typeof e=="symbol"||poe(e)&&uoe.call(e)==eoe}function FL(e){if(typeof e=="number")return e;if(moe(e))return RL;if(fC(e)){var t=typeof e.valueOf=="function"?e.valueOf():e;e=fC(t)?t+"":t}if(typeof e!="string")return e===0?e:+e;e=e.replace(toe,"");var n=roe.test(e);return n||ioe.test(e)?ooe(e.slice(2),n?2:8):noe.test(e)?RL:+e}var goe=foe,M2={exports:{}},Wm=typeof Reflect=="object"?Reflect:null,BL=Wm&&typeof Wm.apply=="function"?Wm.apply:function(t,n,r){return Function.prototype.apply.call(t,n,r)},Lb;Wm&&typeof Wm.ownKeys=="function"?Lb=Wm.ownKeys:Object.getOwnPropertySymbols?Lb=function(t){return Object.getOwnPropertyNames(t).concat(Object.getOwnPropertySymbols(t))}:Lb=function(t){return Object.getOwnPropertyNames(t)};function yoe(e){console&&console.warn&&console.warn(e)}var k5=Number.isNaN||function(t){return t!==t};function zi(){zi.init.call(this)}M2.exports=zi;M2.exports.once=xoe;zi.EventEmitter=zi;zi.prototype._events=void 0;zi.prototype._eventsCount=0;zi.prototype._maxListeners=void 0;var zL=10;function E1(e){if(typeof e!="function")throw new TypeError('The "listener" argument must be of type Function. Received type '+typeof e)}Object.defineProperty(zi,"defaultMaxListeners",{enumerable:!0,get:function(){return zL},set:function(e){if(typeof e!="number"||e<0||k5(e))throw new RangeError('The value of "defaultMaxListeners" is out of range. It must be a non-negative number. Received '+e+".");zL=e}});zi.init=function(){(this._events===void 0||this._events===Object.getPrototypeOf(this)._events)&&(this._events=Object.create(null),this._eventsCount=0),this._maxListeners=this._maxListeners||void 0};zi.prototype.setMaxListeners=function(t){if(typeof t!="number"||t<0||k5(t))throw new RangeError('The value of "n" is out of range. It must be a non-negative number. Received '+t+".");return this._maxListeners=t,this};function A5(e){return e._maxListeners===void 0?zi.defaultMaxListeners:e._maxListeners}zi.prototype.getMaxListeners=function(){return A5(this)};zi.prototype.emit=function(t){for(var n=[],r=1;r<arguments.length;r++)n.push(arguments[r]);var i=t==="error",s=this._events;if(s!==void 0)i=i&&s.error===void 0;else if(!i)return!1;if(i){var c;if(n.length>0&&(c=n[0]),c instanceof Error)throw c;var a=new Error("Unhandled error."+(c?" ("+c.message+")":""));throw a.context=c,a}var m=s[t];if(m===void 0)return!1;if(typeof m=="function")BL(m,this,n);else for(var g=m.length,x=D5(m,g),r=0;r<g;++r)BL(x[r],this,n);return!0};function P5(e,t,n,r){var i,s,c;if(E1(n),s=e._events,s===void 0?(s=e._events=Object.create(null),e._eventsCount=0):(s.newListener!==void 0&&(e.emit("newListener",t,n.listener?n.listener:n),s=e._events),c=s[t]),c===void 0)c=s[t]=n,++e._eventsCount;else if(typeof c=="function"?c=s[t]=r?[n,c]:[c,n]:r?c.unshift(n):c.push(n),i=A5(e),i>0&&c.length>i&&!c.warned){c.warned=!0;var a=new Error("Possible EventEmitter memory leak detected. "+c.length+" "+String(t)+" listeners added. Use emitter.setMaxListeners() to increase limit");a.name="MaxListenersExceededWarning",a.emitter=e,a.type=t,a.count=c.length,yoe(a)}return e}zi.prototype.addListener=function(t,n){return P5(this,t,n,!1)};zi.prototype.on=zi.prototype.addListener;zi.prototype.prependListener=function(t,n){return P5(this,t,n,!0)};function _oe(){if(!this.fired)return this.target.removeListener(this.type,this.wrapFn),this.fired=!0,arguments.length===0?this.listener.call(this.target):this.listener.apply(this.target,arguments)}function M5(e,t,n){var r={fired:!1,wrapFn:void 0,target:e,type:t,listener:n},i=_oe.bind(r);return i.listener=n,r.wrapFn=i,i}zi.prototype.once=function(t,n){return E1(n),this.on(t,M5(this,t,n)),this};zi.prototype.prependOnceListener=function(t,n){return E1(n),this.prependListener(t,M5(this,t,n)),this};zi.prototype.removeListener=function(t,n){var r,i,s,c,a;if(E1(n),i=this._events,i===void 0)return this;if(r=i[t],r===void 0)return this;if(r===n||r.listener===n)--this._eventsCount===0?this._events=Object.create(null):(delete i[t],i.removeListener&&this.emit
1430("removeListener",t,r.listener||n));else if(typeof r!="function"){for(s=-1,c=r.length-1;c>=0;c--)if(r[c]===n||r[c].listener===n){a=r[c].listener,s=c;break}if(s<0)return this;s===0?r.shift():voe(r,s),r.length===1&&(i[t]=r[0]),i.removeListener!==void 0&&this.emit("removeListener",t,a||n)}return this};zi.prototype.off=zi.prototype.removeListener;zi.prototype.removeAllListeners=function(t){var n,r,i;if(r=this._events,r===void 0)return this;if(r.removeListener===void 0)return arguments.length===0?(this._events=Object.create(null),this._eventsCount=0):r[t]!==void 0&&(--this._eventsCount===0?this._events=Object.create(null):delete r[t]),this;if(arguments.length===0){var s=Object.keys(r),c;for(i=0;i<s.length;++i)c=s[i],c!=="removeListener"&&this.removeAllListeners(c);return this.removeAllListeners("removeListener"),this._events=Object.create(null),this._eventsCount=0,this}if(n=r[t],typeof n=="function")this.removeListener(t,n);else if(n!==void 0)for(i=n.length-1;i>=0;i--)this.removeListener(t,n[i]);return this};function I5(e,t,n){var r=e._events;if(r===void 0)return[];var i=r[t];return i===void 0?[]:typeof i=="function"?n?[i.listener||i]:[i]:n?boe(i):D5(i,i.length)}zi.prototype.listeners=function(t){return I5(this,t,!0)};zi.prototype.rawListeners=function(t){return I5(this,t,!1)};zi.listenerCount=function(e,t){return typeof e.listenerCount=="function"?e.listenerCount(t):O5.call(e,t)};zi.prototype.listenerCount=O5;function O5(e){var t=this._events;if(t!==void 0){var n=t[e];if(typeof n=="function")return 1;if(n!==void 0)return n.length}return 0}zi.prototype.eventNames=function(){return this._eventsCount>0?Lb(this._events):[]};function D5(e,t){for(var n=new Array(t),r=0;r<t;++r)n[r]=e[r];return n}function voe(e,t){for(;t+1<e.length;t++)e[t]=e[t+1];e.pop()}function boe(e){for(var t=new Array(e.length),n=0;n<t.length;++n)t[n]=e[n].listener||e[n];return t}function xoe(e,t){return new Promise(function(n,r){function i(c){e.removeListener(t,s),r(c)}function s(){typeof e.removeListener=="function"&&e.removeListener("error",i),n([].slice.call(arguments))}L5(e,t,s,{once:!0}),t!=="error"&&woe(e,i,{once:!0})})}function woe(e,t,n){typeof e.on=="function"&&L5(e,"error",t,n)}function L5(e,t,n,r){if(typeof e.on=="function")r.once?e.once(t,n):e.on(t,n);else if(typeof e.addEventListener=="function")e.addEventListener(t,function i(s){r.once&&e.removeEventListener(t,i),n(s)});else throw new TypeError('The "emitter" argument must be of type EventEmitter. Received type '+typeof e)}var Toe=M2.exports,Eoe={fr:{name:"France",bbox:[[-4.59235,41.380007],[9.560016,51.148506]]},us:{name:"United States",bbox:[[-171.791111,18.91619],[-66.96466,71.357764]]},ru:{name:"Russia",bbox:[[19.66064,41.151416],[190.10042,81.2504]]},ca:{name:"Canada",bbox:[[-140.99778,41.675105],[-52.648099,83.23324]]}};function Soe(e){var t=e.match(/\s*(.+)\s*=\s*"?([^"]+)"?/);return t?{key:t[1],value:t[2]}:null}function Coe(e){var t=e.match(/<?([^>]*)>(.*)/);if(!t)return null;var n=t[1],r=t[2].split(";"),i=null,s=r.reduce(function(c,a){var m=Soe(a);return m?m.key==="rel"?(i||(i=m.value),c):(c[m.key]=m.value,c):c},{});return i?{url:n,rel:i,params:s}:null}function koe(e){return e?e.split(/,\s*</).reduce(function(t,n){var r=Coe(n);if(!r)return t;var i=r.rel.split(/\s+/);return i.forEach(function(s){t[s]||(t[s]={url:r.url,params:r.params})}),t},{}):{}}var Aoe=koe,Poe=Aoe;function I2(e,t){this.request=e,this.headers=t.headers,this.rawBody=t.body,this.statusCode=t.statusCode;try{this.body=JSON.parse(t.body||"{}")}catch{this.body=t.body}this.links=Poe(this.headers.link)}I2.prototype.hasNextPage=function(){return!!this.links.next};I2.prototype.nextPage=function(){return this.hasNextPage()?this.request._extend({path:this.links.next.url}):null};var Moe=I2,S1={API_ORIGIN:"https://api.mapbox.com",EVENT_PROGRESS_DOWNLOAD:"downloadProgress",EVENT_PROGRESS_UPLOAD:"uploadProgress",EVENT_ERROR:"error",EVENT_RESPONSE:"response",ERROR_HTTP:"HttpError",ERROR_REQUEST_ABORTED:"RequestAbortedError"},NL=S1;function Ioe(e){var t=e.type||NL.ERROR_HTTP,n;if(e.body)try{n=JSON.parse(e.body)}catch{n=e.body}else n=null;var r=e.message||null;r||(typeof n=="string"?r=n:n&&typeof n.message=="string"?r=n.message:t===NL.ERROR_REQUEST_ABORTED&&(r="Request aborted")),this.message=r,this.type=t,this.statusCode=e.statusCode||null,this.request=e.request,this.body=n}var Ooe=Ioe;function Doe(e){var t=e.indexOf(":"),n=e.substring(0,t).trim().toLowerCase(),r=e.substring(t+1).trim();return{name:n,value:r}}function Loe(e){var t={};
1430return e&&e.trim().split(/[\r|\n]+/).forEach(function(n){var r=Doe(n);t[r.name]=r.value}),t}var Roe=Loe,Foe=Moe,$L=Ooe,rE=S1,Boe=Roe,xx={};function zoe(e){var t=xx[e.id];t&&(t.abort(),delete xx[e.id])}function Noe(e,t){return new Foe(e,{body:t.response,headers:Boe(t.getAllResponseHeaders()),statusCode:t.status})}function jL(e){var t=e.total,n=e.loaded,r=100*n/t;return{total:t,transferred:n,percent:r}}function R5(e,t){return new Promise(function(n,r){t.onprogress=function(c){e.emitter.emit(rE.EVENT_PROGRESS_DOWNLOAD,jL(c))};var i=e.file;i&&(t.upload.onprogress=function(c){e.emitter.emit(rE.EVENT_PROGRESS_UPLOAD,jL(c))}),t.onerror=function(c){r(c)},t.onabort=function(){var c=new $L({request:e,type:rE.ERROR_REQUEST_ABORTED});r(c)},t.onload=function(){if(delete xx[e.id],t.status<200||t.status>=400){var c=new $L({request:e,body:t.response,statusCode:t.status});r(c);return}n(t)};var s=e.body;typeof s=="string"?t.send(s):s?t.send(JSON.stringify(s)):i?t.send(i):t.send(),xx[e.id]=t}).then(function(n){return Noe(e,n)})}function F5(e,t){var n=e.url(t),r=new window.XMLHttpRequest;return r.open(e.method,n),Object.keys(e.headers).forEach(function(i){r.setRequestHeader(i,e.headers[i])}),r}function $oe(e){return Promise.resolve().then(function(){var t=F5(e,e.client.accessToken);return R5(e,t)})}var joe={browserAbort:zoe,sendRequestXhr:R5,browserSend:$oe,createRequestXhr:F5},wx={exports:{}};/*! http://mths.be/base64 v0.1.0 by @mathias | MIT license */wx.exports;(function(e,t){(function(n){var r=t,i=e&&e.exports==r&&e,s=typeof oo=="object"&&oo;(s.global===s||s.window===s)&&(n=s);var c=function(P){this.message=P};c.prototype=new Error,c.prototype.name="InvalidCharacterError";var a=function(P){throw new c(P)},m="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",g=/[\t\n\f\r ]/g,x=function(P){P=String(P).replace(g,"");var D=P.length;D%4==0&&(P=P.replace(/==?$/,""),D=P.length),(D%4==1||/[^+a-zA-Z0-9/]/.test(P))&&a("Invalid character: the string to be decoded is not correctly encoded.");for(var B=0,R,N,j="",U=-1;++U<D;)N=m.indexOf(P.charAt(U)),R=B%4?R*64+N:N,B++%4&&(j+=String.fromCharCode(255&R>>(-2*B&6)));return j},T=function(P){P=String(P),/[^\0-\xFF]/.test(P)&&a("The string to be encoded contains characters outside of the Latin1 range.");for(var D=P.length%3,B="",R=-1,N,j,U,W,Q=P.length-D;++R<Q;)N=P.charCodeAt(R)<<16,j=P.charCodeAt(++R)<<8,U=P.charCodeAt(++R),W=N+j+U,B+=m.charAt(W>>18&63)+m.charAt(W>>12&63)+m.charAt(W>>6&63)+m.charAt(W&63);return D==2?(N=P.charCodeAt(R)<<8,j=P.charCodeAt(++R),W=N+j,B+=m.charAt(W>>10)+m.charAt(W>>4&63)+m.charAt(W<<2&63)+"="):D==1&&(W=P.charCodeAt(R),B+=m.charAt(W>>2)+m.charAt(W<<4&63)+"=="),B},C={encode:T,decode:x,version:"0.1.0"};if(r&&!r.nodeType)if(i)i.exports=C;else for(var A in C)C.hasOwnProperty(A)&&(r[A]=C[A]);else n.base64=C})(oo)})(wx,wx.exports);var Uoe=wx.exports,Voe=Uoe,iE={};function Goe(e){if(iE[e])return iE[e];var t=e.split("."),n=t[0],r=t[1];if(!r)throw new Error("Invalid token");var i=qoe(r),s={usage:n,user:i.u};return Rf(i,"a")&&(s.authorization=i.a),Rf(i,"exp")&&(s.expires=i.exp*1e3),Rf(i,"iat")&&(s.created=i.iat*1e3),Rf(i,"scopes")&&(s.scopes=i.scopes),Rf(i,"client")&&(s.client=i.client),Rf(i,"ll")&&(s.lastLogin=i.ll),Rf(i,"iu")&&(s.impersonator=i.iu),iE[e]=s,s}function qoe(e){try{return JSON.parse(Voe.decode(e))}catch{throw new Error("Invalid token")}}function Rf(e,t){return Object.prototype.hasOwnProperty.call(e,t)}var B5=Goe,z5={exports:{}};(function(e){var t=Object.prototype.hasOwnProperty,n="~";function r(){}Object.create&&(r.prototype=Object.create(null),new r().__proto__||(n=!1));function i(m,g,x){this.fn=m,this.context=g,this.once=x||!1}
1430function s(m,g,x,T,C){if(typeof x!="function")throw new TypeError("The listener must be a function");var A=new i(x,T||m,C),P=n?n+g:g;return m._events[P]?m._events[P].fn?m._events[P]=[m._events[P],A]:m._events[P].push(A):(m._events[P]=A,m._eventsCount++),m}function c(m,g){--m._eventsCount===0?m._events=new r:delete m._events[g]}function a(){this._events=new r,this._eventsCount=0}a.prototype.eventNames=function(){var g=[],x,T;if(this._eventsCount===0)return g;for(T in x=this._events)t.call(x,T)&&g.push(n?T.slice(1):T);return Object.getOwnPropertySymbols?g.concat(Object.getOwnPropertySymbols(x)):g},a.prototype.listeners=function(g){var x=n?n+g:g,T=this._events[x];if(!T)return[];if(T.fn)return[T.fn];for(var C=0,A=T.length,P=new Array(A);C<A;C++)P[C]=T[C].fn;return P},a.prototype.listenerCount=function(g){var x=n?n+g:g,T=this._events[x];return T?T.fn?1:T.length:0},a.prototype.emit=function(g,x,T,C,A,P){var D=n?n+g:g;if(!this._events[D])return!1;var B=this._events[D],R=arguments.length,N,j;if(B.fn){switch(B.once&&this.removeListener(g,B.fn,void 0,!0),R){case 1:return B.fn.call(B.context),!0;case 2:return B.fn.call(B.context,x),!0;case 3:return B.fn.call(B.context,x,T),!0;case 4:return B.fn.call(B.context,x,T,C),!0;case 5:return B.fn.call(B.context,x,T,C,A),!0;case 6:return B.fn.call(B.context,x,T,C,A,P),!0}for(j=1,N=new Array(R-1);j<R;j++)N[j-1]=arguments[j];B.fn.apply(B.context,N)}else{var U=B.length,W;for(j=0;j<U;j++)switch(B[j].once&&this.removeListener(g,B[j].fn,void 0,!0),R){case 1:B[j].fn.call(B[j].context);break;case 2:B[j].fn.call(B[j].context,x);break;case 3:B[j].fn.call(B[j].context,x,T);break;case 4:B[j].fn.call(B[j].context,x,T,C);break;default:if(!N)for(W=1,N=new Array(R-1);W<R;W++)N[W-1]=arguments[W];B[j].fn.apply(B[j].context,N)}}return!0},a.prototype.on=function(g,x,T){return s(this,g,x,T,!1)},a.prototype.once=function(g,x,T){return s(this,g,x,T,!0)},a.prototype.removeListener=function(g,x,T,C){var A=n?n+g:g;if(!this._events[A])return this;if(!x)return c(this,A),this;var P=this._events[A];if(P.fn)P.fn===x&&(!C||P.once)&&(!T||P.context===T)&&c(this,A);else{for(var D=0,B=[],R=P.length;D<R;D++)(P[D].fn!==x||C&&!P[D].once||T&&P[D].context!==T)&&B.push(P[D]);B.length?this._events[A]=B.length===1?B[0]:B:c(this,A)}return this},a.prototype.removeAllListeners=function(g){var x;return g?(x=n?n+g:g,this._events[x]&&c(this,x)):(this._events=new r,this._eventsCount=0),this},a.prototype.off=a.prototype.removeListener,a.prototype.addListener=a.prototype.on,a.prefixed=n,a.EventEmitter=a,e.exports=a})(z5);var Woe=z5.exports;function Hoe(e){return e.map(encodeURIComponent).join(",")}function N5(e){return Array.isArray(e)?Hoe(e):encodeURIComponent(String(e))}function $5(e,t,n){if(n===!1||n===null)return e;var r=/\?/.test(e)?"&":"?",i=encodeURIComponent(t);return n!==void 0&&n!==""&&n!==!0&&(i+="="+N5(n)),""+e+r+i}function Yoe(e,t){if(!t)return e;var n=e;return Object.keys(t).forEach(function(r){var i=t[r];i!==void 0&&(Array.isArray(i)&&(i=i.filter(function(s){return s!=null}).join(",")),n=$5(n,r,i))}),n}function Zoe(e,t){if(!t||e.slice(0,4)==="http")return e;var n=e[0]==="/"?"":"/";return""+t.replace(/\/$/,"")+n+e}function Xoe(e,t){return t?e.replace(/\/:([a-zA-Z0-9]+)/g,function(n,r){var i=t[r];if(i===void 0)throw new Error("Unspecified route parameter "+r);var s=N5(i);return"/"+s}):e}var Koe={appendQueryObject:Yoe,appendQueryParam:$5,prependOrigin:Zoe,interpolateRouteParams:Xoe},Qoe=B5,O2=Ag,Joe=Woe,lb=Koe,UL=S1,eae=1;function Od(e,t){if(!e)throw new Error("MapiRequest requires a client");if(!t||!t.path||!t.method)throw new Error("MapiRequest requires an options object with path and method properties");var n={};t.body&&(n["content-type"]="application/json");var r=O2(n,t.headers),i=Object.keys(r).reduce(function(s,c){return s[c.toLowerCase()]=r[c],s},{});this.id=eae++,this._options=t,this.emitter=new Joe,this.client=e,this.response=null,this.error=null,this.sent=!1,this.aborted=!1,this.path=t.path,this.method=t.method,this.origin=t.origin||e.origin,this.query=t.query||{},this.params=t.params||{},this.body=t.body||null,this.file=t.file||null,this.encoding=t.encoding||"utf8",this.sendFileAs=t.sendFileAs||null,this.headers=i}Od.prototype.url=function(t){var n=lb.prependOrigin(this.path,this.origin);n=lb.appendQueryObject(n,this.query);var r=this.params,i=t??this.client.accessToken;if(i){n=lb.appendQueryParam(n,"access_token",i);var s=Qoe(i).user;r=O2({ownerId:s},r)}
1430return n=lb.interpolateRouteParams(n,r),n};Od.prototype.send=function(){var t=this;if(t.sent)throw new Error("This request has already been sent. Check the response and error properties. Create a new request with clone().");return t.sent=!0,t.client.sendRequest(t).then(function(n){return t.response=n,t.emitter.emit(UL.EVENT_RESPONSE,n),n},function(n){throw t.error=n,t.emitter.emit(UL.EVENT_ERROR,n),n})};Od.prototype.abort=function(){this._nextPageRequest&&(this._nextPageRequest.abort(),delete this._nextPageRequest),!(this.response||this.error||this.aborted)&&(this.aborted=!0,this.client.abortRequest(this))};Od.prototype.eachPage=function(t){var n=this;function r(c){function a(){delete n._nextPageRequest;var m=c.nextPage();m&&(n._nextPageRequest=m,s(m))}t(null,c,a)}function i(c){t(c,null,function(){})}function s(c){c.send().then(r,i)}s(this)};Od.prototype.clone=function(){return this._extend()};Od.prototype._extend=function(t){var n=O2(this._options,t);return new Od(this.client,n)};var tae=Od,nae=B5,rae=tae,iae=S1;function j5(e){if(!e||!e.accessToken)throw new Error("Cannot create a client without an access token");nae(e.accessToken),this.accessToken=e.accessToken,this.origin=e.origin||iae.API_ORIGIN}j5.prototype.createRequest=function(t){return new rae(this,t)};var U5=j5,V5=joe,G5=U5;function fg(e){G5.call(this,e)}fg.prototype=Object.create(G5.prototype);fg.prototype.constructor=fg;fg.prototype.sendRequest=V5.browserSend;fg.prototype.abortRequest=V5.browserAbort;function oae(e){return new fg(e)}var q5=oae,aae=q5,sae=aae,lae=Object.prototype.toString,cae=function(e){var t;return lae.call(e)==="[object Object]"&&(t=Object.getPrototypeOf(e),t===null||t===Object.getPrototypeOf({}))},uae=cae,hae=Ag,W5="value",oE=`
1431  `,Ki={};Ki.assert=function(e,t){return t=t||{},function(n){var r=Dd(e,n);if(r){var i=D2(r,t);throw t.apiName&&(i=t.apiName+": "+i),new Error(i)}}};Ki.shape=function(t){var n=mae(t);return function(i){var s=Dd(Ki.plainObject,i);if(s)return s;for(var c,a,m=[],g=0;g<n.length;g++)c=n[g].key,a=n[g].value,s=Dd(a,i[c]),s&&m.push([c].concat(s));return m.length<2?m[0]:function(x){m=m.map(function(A){var P=A[0],D=D2(A,x).split(`
1432`).join(oE);return"- "+P+": "+D});var T=x.path.join("."),C=T===W5?"":" of "+T;return"The following properties"+C+" have invalid values:"+oE+m.join(oE)}}};Ki.strictShape=function(t){var n=Ki.shape(t);return function(i){var s=n(i);if(s)return s;var c=Object.keys(i).reduce(function(a,m){return t[m]===void 0&&a.push(m),a},[]);if(c.length!==0)return function(){return"The following keys are invalid: "+c.join(", ")}}};Ki.arrayOf=function(t){return H5(t)};Ki.tuple=function(){var t=Array.isArray(arguments[0])?arguments[0]:Array.prototype.slice.call(arguments);return H5(t)};function H5(e){var t=Array.isArray(e),n=function(r){return t?e[r]:e};return function(i){var s=Dd(Ki.plainArray,i);if(s)return s;if(t&&i.length!==e.length)return"an array with "+e.length+" items";for(var c=0;c<i.length;c++)if(s=Dd(n(c),i[c]),s)return[c].concat(s)}}Ki.required=function(t){function n(r){return r==null?function(i){return Y5(i,Z5(i.path)?"cannot be undefined/null.":"is required.")}:t.apply(this,arguments)}return n.__required=!0,n};Ki.oneOfType=function(){var t=Array.isArray(arguments[0])?arguments[0]:Array.prototype.slice.call(arguments);return function(r){var i=t.map(function(s){return Dd(s,r)}).filter(Boolean);if(i.length===t.length)return i.every(function(s){return s.length===1&&typeof s[0]=="string"})?dae(i.map(function(s){return s[0]})):i.reduce(function(s,c){return c.length>s.length?c:s})}};Ki.equal=function(t){return function(r){if(r!==t)return JSON.stringify(t)}};Ki.oneOf=function(){var t=Array.isArray(arguments[0])?arguments[0]:Array.prototype.slice.call(arguments),n=t.map(function(r){return Ki.equal(r)});return Ki.oneOfType.apply(this,n)};Ki.range=function(t){var n=t[0],r=t[1];return function(s){var c=Dd(Ki.number,s);if(c||s<n||s>r)return"number between "+n+" & "+r+" (inclusive)"}};Ki.any=function(){};Ki.boolean=function(t){if(typeof t!="boolean")return"boolean"};Ki.number=function(t){if(typeof t!="number")return"number"};Ki.plainArray=function(t){if(!Array.isArray(t))return"array"};Ki.plainObject=function(t){if(!uae(t))return"object"};Ki.string=function(t){if(typeof t!="string")return"string"};Ki.func=function(t){if(typeof t!="function")return"function"};function Dd(e,t){if(!(t==null&&!e.hasOwnProperty("__required"))){var n=e(t);if(n)return Array.isArray(n)?n:[n]}}function D2(e,t){var n=e.length,r=e[n-1],i=e.slice(0,n-1);return i.length===0&&(i=[W5]),t=hae(t,{path:i}),typeof r=="function"?r(t):Y5(t,fae(r))}function dae(e){return e.length<2?e[0]:e.length===2?e.join(" or "):e.slice(0,-1).join(", ")+", or "+e.slice(-1)}function fae(e){return"must be "+pae(e)+"."}function pae(e){return/^an? /.test(e)?e:/^[aeiou]/i.test(e)?"an "+e:/^[a-z]/i.test(e)?"a "+e:e}function Y5(e,t){var n=Z5(e.path),r=e.path.join(".")+" "+t,i=n?"Item at position ":"";return i+r}function Z5(e){return typeof e[e.length-1]=="number"||typeof e[0]=="number"}function mae(e){return Object.keys(e||{}).map(function(t){return{key:t,value:e[t]}})}Ki.validate=Dd;Ki.processMessage=D2;var gae=Ki,yae=Ag,Hm=gae;function _ae(e){if(typeof window<"u")return e instanceof globalThis.Blob||e instanceof globalThis.ArrayBuffer?void 0:"Blob or ArrayBuffer";if(!(typeof e=="string"||e.pipe!==void 0))return"Filename or Readable stream"}function vae(e,t){return Hm.assert(Hm.strictShape(e),t)}function bae(e){var t="date";if(typeof e=="boolean")return t;try{var n=new Date(e);if(n.getTime&&isNaN(n.getTime()))return t}catch{return t}}function xae(e){return Hm.tuple(Hm.number,Hm.number)(e)}var wae=yae(Hm,{file:_ae,date:bae,coordinates:xae,assertShape:vae});function Tae(e,t){var n=function(r,i){return t.indexOf(r)!==-1&&i!==void 0};return typeof t=="function"&&(n=t),Object.keys(e).filter(function(r){return n(r,e[r])}).reduce(function(r,i){return r[i]=e[i],r},{})}var Eae=Tae;function Sae(e,t){return Object.keys(e).reduce(function(n,r){return n[r]=t(r,e[r]),n},{})}var Cae=Sae,kae=Cae;function Aae(e){return kae(e,function(t,n){return typeof n=="boolean"?JSON.stringify(n):n})}var Pae=Aae,Mae=U5,Iae=q5;function Oae(e){return function(t){var n;Mae.prototype.isPrototypeOf(t)?n=t:n=Iae(t);var r=Object.create(e);return r.client=n,r}}var Dae=Oae,X5=Ag,$r=wae,Tx=Eae,K5=Pae,Lae=Dae,L2={},Q5=["country","region","postcode","district","place","locality","neighborhood","address","poi","poi.landmark"];L2.forwardGeocode=function(e){$r.assertShape({query:$r.required($r.string),mode:$r.oneOf("mapbox.places","mapbox.places-permanent"),countries:$r.arrayOf($r.string),proximity:$r.oneOf($r.coordinates,"ip"),types:$r.arrayOf($r.oneOf(Q5)),autocomplete:$r.boolean,bbox:$r.arrayOf($r.number),limit:$r.number,language:$r.arrayOf($r.string),routing:$r.boolean,fuzzyMatch:$r.boolean,worldview:$r.string})(e),e.mode=e.mode||"mapbox.places";var t=K5(X5({country:e.countries},Tx(e,["proximity","types","autocomplete","bbox","limit","language","rout
1432ing","fuzzyMatch","worldview"])));return this.client.createRequest({method:"GET",path:"/geocoding/v5/:mode/:query.json",params:Tx(e,["mode","query"]),query:t})};L2.reverseGeocode=function(e){$r.assertShape({query:$r.required($r.coordinates),mode:$r.oneOf("mapbox.places","mapbox.places-permanent"),countries:$r.arrayOf($r.string),types:$r.arrayOf($r.oneOf(Q5)),bbox:$r.arrayOf($r.number),limit:$r.number,language:$r.arrayOf($r.string),reverseMode:$r.oneOf("distance","score"),routing:$r.boolean,worldview:$r.string})(e),e.mode=e.mode||"mapbox.places";var t=K5(X5({country:e.countries},Tx(e,["country","types","bbox","limit","language","reverseMode","routing","worldview"])));return this.client.createRequest({method:"GET",path:"/geocoding/v5/:mode/:query.json",params:Tx(e,["mode","query"]),query:t})};var Rae=Lae(L2);let Fae="useandom-26T198340PX75pxJACKVERYMINDBUSHWOLF_GQZbfghjklqvwyzrict",J5=e=>crypto.getRandomValues(new Uint8Array(e)),e4=(e,t,n)=>{let r=(2<<Math.log(e.length-1)/Math.LN2)-1,i=-~(1.6*r*t/e.length);return(s=t)=>{let c="";for(;;){let a=n(i),m=i;for(;m--;)if(c+=e[a[m]&r]||"",c.length===s)return c}}},Bae=(e,t=21)=>e4(e,t,J5),zae=(e=21)=>crypto.getRandomValues(new Uint8Array(e)).reduce((t,n)=>(n&=63,n<36?t+=n.toString(36):n<62?t+=(n-26).toString(36).toUpperCase():n>62?t+="-":t+="_",t),"");const Nae=Object.freeze(Object.defineProperty({__proto__:null,customAlphabet:Bae,customRandom:e4,nanoid:zae,random:J5,urlAlphabet:Fae},Symbol.toStringTag,{value:"Module"})),$ae=eQ(Nae);var jae=$ae.nanoid;function t4(e){this.origin=e.origin||"https://api.mapbox.com",this.endpoint="events/v2",this.access_token=e.accessToken,this.version="0.2.0",this.sessionID=this.generateSessionID(),this.userAgent=this.getUserAgent(),this.options=e,this.send=this.send.bind(this),this.countries=e.countries?e.countries.split(","):null,this.types=e.types?e.types.split(","):null,this.bbox=e.bbox?e.bbox:null,this.language=e.language?e.language.split(","):null,this.limit=e.limit?+e.limit:null,this.locale=navigator.language||null,this.enableEventLogging=this.shouldEnableLogging(e),this.eventQueue=new Array,this.flushInterval=e.flushInterval||1e3,this.maxQueueSize=e.maxQueueSize||100,this.timer=this.flushInterval?setTimeout(this.flush.bind(this),this.flushInterval):null,this.lastSentInput="",this.lastSentIndex=0}t4.prototype={select:function(e,t){var n=this.getSelectedIndex(e,t),r=this.getEventPayload("search.select",t);if(r.resultIndex=n,r.resultPlaceName=e.place_name,r.resultId=e.id,!(n===this.lastSentIndex&&r.queryString===this.lastSentInput||n==-1)&&(this.lastSentIndex=n,this.lastSentInput=r.queryString,!!r.queryString))return this.push(r)},start:function(e){var t=this.getEventPayload("search.start",e);if(t.queryString)return this.push(t)},keyevent:function(e,t){if(e.key&&!(e.metaKey||[9,27,37,39,13,38,40].indexOf(e.keyCode)!==-1)){var n=this.getEventPayload("search.keystroke",t);if(n.lastAction=e.key,!!n.queryString)return this.push(n)}},send:function(e,t){if(!this.enableEventLogging)return t?t():void 0;var n=this.getRequestOptions(e);this.request(n,function(r){if(r)return this.handleError(r,t);if(t)return t()}.bind(this))},getRequestOptions:function(e){Array.isArray(e)||(e=[e]);var t={method:"POST",host:this.origin,path:this.endpoint+"?access_token="+this.access_token,headers:{"Content-Type":"application/json"},body:JSON.stringify(e)};return t},getEventPayload:function(e,t){var n;t.options.proximity?typeof t.options.proximity=="object"?n=[t.options.proximity.longitude,t.options.proximity.latitude]:t.options.proximity==="ip"?n=[999,999]:n=t.options.proximity:n=null;var r=t._map?t._map.getZoom():void 0,i={event:e,created:+new Date,sessionIdentifier:this.sessionID,country:this.countries,userAgent:this.userAgent,language:this.language,bbox:this.bbox,types:this.types,endpoint:"mapbox.places",autocomplete:t.options.autocomplete,fuzzyMatch:t.options.fuzzyMatch,proximity:n,limit:t.options.limit,routing:t.options.routing,worldview:t.options.worldview,mapZoom:r,keyboardLocale:this.locale};return e==="search.select"?i.queryString=t.inputString:e!="search.select"&&t._inputEl?i.queryString=t._inputEl.value:i.queryString=t.inputString,i},request:function(e,t){var n=new XMLHttpRequest;n.onreadystatechange=function(){if(this.readyState==4)return this.status==204?t(null):t(this.statusText)}
1432,n.open(e.method,e.host+"/"+e.path,!0);for(var r in e.headers){var i=e.headers[r];n.setRequestHeader(r,i)}n.send(e.body)},handleError:function(e,t){if(t)return t(e)},generateSessionID:function(){return jae()},getUserAgent:function(){return"mapbox-gl-geocoder."+this.version+"."+navigator.userAgent},getSelectedIndex:function(e,t){if(t._typeahead){var n=t._typeahead.data,r=e.id,i=n.map(function(c){return c.id}),s=i.indexOf(r);return s}},shouldEnableLogging:function(e){return!(e.enableEventLogging===!1||e.origin&&e.origin!=="https://api.mapbox.com"||e.localGeocoder||e.filter)},flush:function(){this.eventQueue.length>0&&(this.send(this.eventQueue),this.eventQueue=new Array),this.timer&&clearTimeout(this.timer),this.flushInterval&&(this.timer=setTimeout(this.flush.bind(this),this.flushInterval))},push:function(e,t){this.eventQueue.push(e),(this.eventQueue.length>=this.maxQueueSize||t)&&this.flush()},remove:function(){this.flush()}};var Uae=t4,Vae={de:"Suche",it:"Ricerca",en:"Search",nl:"Zoeken",fr:"Chercher",ca:"Cerca",he:"לחפש",ja:"サーチ",lv:"Meklēt",pt:"Procurar",sr:"Претрага",zh:"搜索",cs:"Vyhledávání",hu:"Keresés",ka:"ძიება",nb:"Søke",sk:"Vyhľadávanie",th:"ค้นหา",fi:"Hae",is:"Leita",ko:"수색",pl:"Szukaj",sl:"Iskanje",fa:"جستجو",ru:"Поиск"},Gae={placeholder:Vae},n4={exports:{}};(function(e){(function(t,n,r){e.exports?e.exports=r():t[n]=r()})(oo,"subtag",function(){var t="",n=/^([a-zA-Z]{2,3})(?:[_-]+([a-zA-Z]{3})(?=$|[_-]+))?(?:[_-]+([a-zA-Z]{4})(?=$|[_-]+))?(?:[_-]+([a-zA-Z]{2}|[0-9]{3})(?=$|[_-]+))?/;function r(m){return m.match(n)||[]}function i(m){return r(m).filter(function(g,x){return g&&x})}function s(m){return m=r(m),{language:m[1]||t,extlang:m[2]||t,script:m[3]||t,region:m[4]||t}}function c(m,g,x){Object.defineProperty(m,g,{value:x,enumerable:!0})}function a(m,g,x){function T(C){return r(C)[m]||t}c(T,"pattern",g),c(s,x,T)}return a(1,/^[a-zA-Z]{2,3}$/,"language"),a(2,/^[a-zA-Z]{3}$/,"extlang"),a(3,/^[a-zA-Z]{4}$/,"script"),a(4,/^[a-zA-Z]{2}$|^[0-9]{3}$/,"region"),c(s,"split",i),s})})(n4);var qae=n4.exports;function r4(){}r4.prototype={isSupport:function(){return!!window.navigator.geolocation},getCurrentPosition:function(){const e={enableHighAccuracy:!0};return new Promise(function(t,n){window.navigator.geolocation.getCurrentPosition(t,n,e)})}};var Wae=r4;function Hae(e,t){const n=i4(e),r=["address","street","place","country"];var i;if(typeof t=="function")return t(n);const s=r.indexOf(t);return s===-1?i=r:i=r.slice(s),i.reduce(function(c,a){return n[a]?(c!==""&&(c=c+", "),c+n[a]):c},"")}function i4(e){const t=e.address||"",n=e.text||"",r=e.place_name||"",s={address:r.split(",")[0],houseNumber:t,street:n,placeName:r};return e.context.forEach(function(c){const a=c.id.split(".")[0];s[a]=c.text}),s}const Yae=/^[ ]*(-?\d{1,3}(\.\d{0,256})?)[, ]+(-?\d{1,3}(\.\d{0,256})?)[ ]*$/;var Zae={transformFeatureToGeolocationText:Hae,getAddressInfo:i4,REVERSE_GEOCODE_COORD_RGX:Yae},Xae=Qie,Kae=goe,Uf=Ag,Qae=Toe.EventEmitter,VL=Eoe,aE=sae,sE=Rae,Jae=Uae,ese=Gae,tse=qae,nse=Wae,GL=Zae;const qh={FORWARD:0,LOCAL:1,REVERSE:2};function rse(){var e=document.createElement("div");return e.className="mapboxgl-ctrl-geocoder--powered-by",e.innerHTML='<a href="https://www.mapbox.com/search-service" target="_blank">Powered by Mapbox</a>',e}function o4(e){this._eventEmitter=new Qae,this.options=Uf({},this.options,e),this.inputString="",this.fresh=!0,this.lastSelected=null,this.geolocation=new nse}o4.prototype={options:{zoom:16,flyTo:!0,trackProximity:!0,minLength:2,reverseGeocode:!1,flipCoordinates:!1,limit:5,origin:"https://api.mapbox.com",enableEventLogging:!0,marker:!0,mapboxgl:null,collapsed:!1,clearAndBlurOnEsc:!1,clearOnBlur:!1,enableGeolocation:!1,addressAccuracy:"street",getItemValue:function(e){return e.place_name},render:function(e){var t=e.place_name.split(",");return'<div class="mapboxgl-ctrl-geocoder--suggestion"><div class="mapboxgl-ctrl-geocoder--suggestion-title">'+t[0]+'</div><div class="mapboxgl-ctrl-geocoder--suggestion-address">'+t.splice(1,t.length).join(",")+"</div></div>"}},addTo:function(e){function t(n,r){if(!document.body.contains(r))throw new Error("Element provided to #addTo() exists, but is not in the DOM");const i=n.onAdd();r.appendChild(i)}if(e._controlContainer)e.addControl(this);else if(e instanceof HTMLElement)t(this,e);else if(typeof e=="string"){const n=document.querySelectorAll(e);if(n.length===0)throw new Error("Element ",e,"not found.");if(n.length>1)throw new Error("Geocoder can only be added to a single html element");t(this,n[0])}else throw new Error("Error: addTo must be a mapbox-gl-js map, an html element, or a CSS selector query for a single html element")},onAdd:function(e){if(e&&typeof e!="string"&&(this._map=e),this.setLanguage(),this.options.localGeocoderOnly||(this.geocoderService=sE(aE({accessToken:this.options.accessToken,origin:this.options.origin}))),this.options.localGeocoderOnly&&!this.options.localGeocoder)throw new Error("A localGeocoder function must be specified to use localGeocoderOnly mode");this.eventManager=new Jae(this.options),this._onChange=this._onChange.bind(this),this._onKeyDown=this._onKeyDown.bind(this),this._onPaste=this._onPaste.bind(this),this._onBlur=this._onBlur.bind(this),this._showButton=this._showButton.bind(this),this._hideButton=this._hideButton.bind(this),this._onQueryResult=this._onQueryResult.bind(this),this.clear=this.clear.bind(this),this._updateProximity=this._updateProximity.bind(this),this._collapse=this._collapse.bind(this),this._unCollapse=this._unCollapse.bind(this),this._clear=this._clear.bind(this),this._clearOnBlur=this._clearOnBlur.bind(this),this._geolocateUser=this._geolocateUser.bind(this);var t=this.container=document.createElement("div");t.className="mapboxgl-ctrl-geocoder mapboxgl-ctrl";var n=this.createIcon("search",'<path d="M7.4 2.5c-2.7 0-4.9 2.2-4.9 4.9s2.2 4.9 4.9 4.9c1 0 1.8-.2 2.5-.8l3.7 3.7c.2.2.4.3.8.3.7 0 1.1-.4 1.1-1.1 0-.3-.1-.5-.3-.8L11.4 10c.4-.8.8-1.6.8-2.5.1-2.8-2.1-5-4.8-5zm0 1.6c1.8 0 3.2 1.4 3.2 3.2s-1.4 3.2-3.2 3.2-3.3-1.3-3.3-3.1 1.4-3.3 3.3-3.3z"/>');this._inputEl=document.createElement("input"),this._inputEl.type="text",this._inputEl.className="mapboxgl-ctrl-geocoder--input",this.setPlaceholder(),this.options.collapsed&&(this._collapse(),this.container.addEventListener("mouseenter",this._unCollapse),this.container.addEventListener("mouseleave",this._collapse),this._inputEl.addEventListener("focus",this._unCollapse)),(this.options.collapsed||this.options.clearOnBlur)&&this._inputEl.addEventListener("blur",this._onBlur),this._inputEl.addEventListener("keydown",Kae(this._onKeyDown,200)),this._inputEl.addEventListener("paste",this._onPaste),this._inputEl.addEventListener("change",this._onChange),this.container.addEventListener("mouseenter",this._showButton),this.container.addEventListener("mouseleave",this._hideButton),this._inputEl.addEventListener("keyup",function(g){this.eventManager.keyevent(g,this)}.bind(this));var r=document.createElement("div");r.classList.add("mapboxgl-ctrl-geocoder--pin-right"),this._clearEl=document.createElement("button"),this._clearEl.setAttribute("aria-label","Clear"),this._clearEl.addEventListener("click",this.clear),this._clearEl.className="mapboxgl-ctrl-geocoder--button";var i=this.createIcon("close",'<path d="M3.8 2.5c-.6 0-1.3.7-1.3 1.3 0 .3.2.7.5.8L7.2 9 3 13.2c-.3.3-.5.7-.5 1 0 .6.7 1.3 1.3 1.3.3 0 .7-.2 1-.5L9 10.8l4.2 4.2c.2.3.7.3 1 .3.6 0 1.3-.7 1.3-1.3 0-.3-.2-.7-.3-1l-4.4-4L15 4.6c.3-.2.5-.5.5-.8 0-.7-.7-1.3-1.3-1.3-.3 0-.7.2-1 .3L9 7.1 4.8 2.8c-.3-.1-.7-.3-1-.3z"/>');if(this._clearEl.appendChild(i),this._loadingEl=this.createIcon("loading",'<path fill="#333" d="M4.4 4.4l.8.8c2.1-2.1 5.5-2.1 7.6 0l.8-.8c-2.5-2.5-6.7-2.5-9.2 0z"/><path opacity=".1" d="M12.8 12.9c-2.1 2.1-5.5 2.1-7.6 0-2.1-2.1-2.1-5.5 0-7.7l-.8-.8c-2.5 2.5-2.5 6.7 0 9.2s6.6 2.5 9.2 0 2.5-6.
14326 0-9.2l-.8.8c2.2 2.1 2.2 5.6 0 7.7z"/>'),r.appendChild(this._clearEl),r.appendChild(this._loadingEl),t.appendChild(n),t.appendChild(this._inputEl),t.appendChild(r),this.options.enableGeolocation&&this.geolocation.isSupport()){this._geolocateEl=document.createElement("button"),this._geolocateEl.setAttribute("aria-label","Geolocate"),this._geolocateEl.addEventListener("click",this._geolocateUser),this._geolocateEl.className="mapboxgl-ctrl-geocoder--button";var s=this.createIcon("geolocate",'<path d="M12.999 3.677L2.042 8.269c-.962.403-.747 1.823.29 1.912l5.032.431.431 5.033c.089 1.037 1.509 1.252 1.912.29l4.592-10.957c.345-.822-.477-1.644-1.299-1.299z" fill="#4264fb"/>');this._geolocateEl.appendChild(s),r.appendChild(this._geolocateEl),this._showGeolocateButton()}var c=this._typeahead=new Xae(this._inputEl,[],{filter:!1,minLength:this.options.minLength,limit:this.options.limit});this.setRenderFunction(this.options.render),c.getItemValue=this.options.getItemValue;var a=c.list.draw,m=this._footerNode=rse();return c.list.draw=function(){a.call(this),m.addEventListener("mousedown",function(){this.selectingListItem=!0}.bind(this)),m.addEventListener("mouseup",function(){this.selectingListItem=!1}.bind(this)),this.element.appendChild(m)},this.mapMarker=null,this._handleMarker=this._handleMarker.bind(this),this._map&&(this.options.trackProximity&&(this._updateProximity(),this._map.on("moveend",this._updateProximity)),this._mapboxgl=this.options.mapboxgl,!this._mapboxgl&&this.options.marker&&(console.error("No mapboxgl detected in options. Map markers are disabled. Please set options.mapboxgl."),this.options.marker=!1)),t},_geolocateUser:function(){this._hideGeolocateButton(),this._showLoadingIcon(),this.geolocation.getCurrentPosition().then(function(e){this._hideLoadingIcon();const t={geometry:{type:"Point",coordinates:[e.coords.longitude,e.coords.latitude]}};this._handleMarker(t),this._fly(t),this._typeahead.clear(),this._typeahead.selected=!0,this.lastSelected=JSON.stringify(t),this._showClearButton(),this.fresh=!1;const n={limit:1,language:[this.options.language],query:t.geometry.coordinates,types:["address"]};if(this.options.localGeocoderOnly){const r=t.geometry.coordinates[0]+","+t.geometry.coordinates[1];this._setInputValue(r),this._eventEmitter.emit("result",{result:t})}else this.geocoderService.reverseGeocode(n).send().then(function(r){const i=r.body.features[0];if(i){const s=GL.transformFeatureToGeolocationText(i,this.options.addressAccuracy);this._setInputValue(s),i.user_coordinates=t.geometry.coordinates,this._eventEmitter.emit("result",{result:i})}else this._eventEmitter.emit("result",{result:{user_coordinates:t.geometry.coordinates}})}.bind(this))}.bind(this)).catch(function(e){e.code===1?this._renderUserDeniedGeolocationError():this._renderLocationError(),this._hideLoadingIcon(),this._showGeolocateButton(),this._hideAttribution()}.bind(this))},createIcon:function(e,t){var n=document.createElementNS("http://www.w3.org/2000/svg","svg");return n.setAttribute("class","mapboxgl-ctrl-geocoder--icon mapboxgl-ctrl-geocoder--icon-"+e),n.setAttribute("viewBox","0 0 18 18"),n.setAttribute("xml:space","preserve"),n.setAttribute("width",18),n.setAttribute("height",18),n.innerHTML=t,n},onRemove:function(){return this.container.parentNode.removeChild(this.container),this.options.trackProximity&&this._map&&this._map.off("moveend",this._updateProximity),this._removeMarker(),this._map=null,this},_setInputValue:function(e){this._inputEl.value=e,setTimeout(function(){this._inputEl.focus(),this._inputEl.scrollLeft=0,this._inputEl.setSelectionRange(0,0)}.bind(this),1)},_onPaste:function(e){var t=(e.clipboardData||window.clipboardData).getData("text");t.length>=this.options.minLength&&this._geocode(t)},_onKeyDown:function(e){var t=27,n=9;if(e.keyCode===t&&this.options.clearAndBlurOnEsc)return this._clear(e),this._inputEl.blur();var r=e.target&&e.target.shadowRoot?e.target.shadowRoot.activeElement:e.target,i=r?r.value:"";if(!i)return this.fresh=!0,e.keyCode!==n&&this.clear(e),this._showGeolocateButton(),this._hideClearButton();this._hideGeolocateButton(),!(e.metaKey||[n,t,37,39,13,38,40].indexOf(e.keyCode)!==-1)&&r.value.length>=this.options.minLength&&this._geocode(r.value)},_showButton:function(){this._typeahead.selected&&this._showClearButton()},_hideButton:function(){this._typeahead.selected&&this._hideClearButton()},_showClearButton:function(){this._clearEl.style.display="block"},_hideClearButton:function(){this._clearEl.style.display="none"},_showGeolocateButton:function(){this._geolocateEl&&this.geolocation.isSupport()&&(this._geolocateEl.style.display="block")},_hideGeolocateButton:function(){this._geolocateEl&&(this._geolocateEl.style.display="none")},_showLoadingIcon:function(){this._loadingEl.style.display="block"},_hideLoadingIcon:function(){this._loadingEl.style.display="none"},_showAttribution:function(){this._footerNode.style.display="block"},_hideAttribution:function(){this._footerNode.style.display="none"},_onBlur:function(e){this.options.clearOnBlur&&this._clearOnBlur(e),this.options.collapsed&&this._collapse()},_onChange:function(){var e=this._typeahead.selected;e&&JSON.stringify(e)!==this.lastSelected&&(this._hideClearButton(),this.options.flyTo&&this._fly(e),this.options.marker&&this._mapboxgl&&this._handleMarker(e),this._inputEl.focus(),this._inputEl.scrollLeft=0,this._inputEl.setSelectionRange(0,0),this.lastSelected=JSON.stringify(e),this._eventEmitter.emit("result",{result:e}),this.eventManager.select(e,this))},_fly:function(e){var t;if(e.properties&&VL[e.properties.short_code])t=Uf({},this.options.flyTo),this._map&&this._map.fitBounds(VL[e.properties.short_code].bbox,t);else if(e.bbox){var n=e.bbox;t=Uf({},this.options.flyTo),this._map&&this._map.fitBounds([[n[0],n[1]],[n[2],n[3]]],t)}else{var r={zoom:this.options.zoom};t=Uf({},r,this.options.flyTo),e.center?t.center=e.center:e.geometry&&e.geometry.type&&e.geometry.type==="Point"&&e.geometry.coordinates&&(t.center=e.geometry.coordinates),this._map&&this._map.flyTo(t)}},_requestType:function(e,t){var n;return e.localGeocoderOnly?n=qh.LOCAL:e.reverseGeocode&&GL.REVERSE_GEOCODE_COORD_RGX.test(t)?n=qh.REVERSE:n=qh.FORWARD,n},_setupConfig:function(e,t){const n=["bbox","limit","proximity","countries","types","language","reverseMode","mode","autocomplete","fuzzyMatch","routing","worldview"],r=/[\s,]+/;var i=this,s=n.reduce(function(a,m){if(i.options[m]===void 0||i.options[m]===null)return a;["countries","types","language"].indexOf(m)>-1?a[m]=i.options[m].split(r):a[m]=i.options[m];const g=typeof i.options[m].longitude=="number"&&typeof i.options[m].latitude=="number";if(m==="proximity"&&g){const x=i.options[m].longitude,T=i.options[m].latitude;a[m]=[x,T]}return a},{});switch(e){case qh.REVERSE:{var c=t.split(r).map(function(a){return parseFloat(a,10)});i.options.flipCoordinates||c.reverse(),s.types&&s.types[0],s=Uf(s,{query:c,limit:1}),["proximity","autocomplete","fuzzyMatch","bbox"].forEach(function(a){a in s&&delete s[a]})}break;case qh.FORWARD:{const a=t.trim();/^(-?\d{1,3}(\.\d{0,256})?)[, ]+(-?\d{1,3}(\.\d{0,256})?)?$/.test(a)&&(t=t.replace(/,/g," ")),s=Uf(s,{query:t})}break}return s},_geocode:function(e){this.inputString=e,this._showLoadingIcon(),this._eventEmitter.emit("loading",{query:e});const t=this._requestType(this.options,e),n=this._setupConfig(t,e);var r;switch(t){case qh.LOCAL:r=Promise.resolve();break;case qh.FORWARD:r=this.geocoderService.forwardGeocode(n).send();break;case qh.REVERSE:r=this.geocoderService.reverseGeocode(n).send();break}var i=this.options.localGeocoder?this.options.localGeocoder(e)||[]:[],s=[],c=null;return r.catch(function(a){c=a}.bind(this)).then(function(a){this._hideLoadingIcon();var m={};return a?a.statusCode=="200"&&(m=a.body,m.request=a.request,m.headers=a.headers):m={type:"FeatureCollection",features:[]},m.config=n,this.fresh&&(this.eventManager.start(this),this.fresh=!1),m.features=m.features?i.concat(m.features):i,this.options.externalGeocoder?(s=this.options.externalGeocoder(e,m.features)||Promise.resolve([]),s.then(function(g){return m.features=m.features?g.concat(m.features):g,m},function(){return m})):m}
1432.bind(this)).then(function(a){if(c)throw c;this.options.filter&&a.features.length&&(a.features=a.features.filter(this.options.filter)),a.features.length?(this._showClearButton(),this._hideGeolocateButton(),this._showAttribution(),this._eventEmitter.emit("results",a),this._typeahead.update(a.features)):(this._hideClearButton(),this._hideAttribution(),this._typeahead.selected=null,this._renderNoResults(),this._eventEmitter.emit("results",a))}.bind(this)).catch(function(a){this._hideLoadingIcon(),this._hideAttribution(),i.length&&this.options.localGeocoder||s.length&&this.options.externalGeocoder?(this._showClearButton(),this._hideGeolocateButton(),this._typeahead.update(i)):(this._hideClearButton(),this._typeahead.selected=null,this._renderError()),this._eventEmitter.emit("results",{features:i}),this._eventEmitter.emit("error",{error:a})}.bind(this)),r},_clear:function(e){e&&e.preventDefault(),this._inputEl.value="",this._typeahead.selected=null,this._typeahead.clear(),this._onChange(),this._hideClearButton(),this._showGeolocateButton(),this._removeMarker(),this.lastSelected=null,this._eventEmitter.emit("clear"),this.fresh=!0},clear:function(e){this._clear(e),this._inputEl.focus()},_clearOnBlur:function(e){var t=this;e.relatedTarget&&t._clear(e)},_onQueryResult:function(e){var t=e.body;if(t.features.length){var n=t.features[0];this._typeahead.selected=n,this._inputEl.value=n.place_name,this._onChange()}},_updateProximity:function(){if(!(!this._map||!this.options.trackProximity))if(this._map.getZoom()>9){var e=this._map.getCenter().wrap();this.setProximity({longitude:e.lng,latitude:e.lat},!1)}else this.setProximity(null,!1)},_collapse:function(){!this._inputEl.value&&this._inputEl!==document.activeElement&&this.container.classList.add("mapboxgl-ctrl-geocoder--collapsed")},_unCollapse:function(){this.container.classList.remove("mapboxgl-ctrl-geocoder--collapsed")},query:function(e){return this._geocode(e).then(this._onQueryResult),this},_renderError:function(){var e="<div class='mapbox-gl-geocoder--error'>There was an error reaching the server</div>";this._renderMessage(e)},_renderLocationError:function(){var e="<div class='mapbox-gl-geocoder--error'>A location error has occurred</div>";this._renderMessage(e)},_renderNoResults:function(){var e="<div class='mapbox-gl-geocoder--error mapbox-gl-geocoder--no-results'>No results found</div>";this._renderMessage(e)},_renderUserDeniedGeolocationError:function(){var e="<div class='mapbox-gl-geocoder--error'>Geolocation permission denied</div>";this._renderMessage(e)},_renderMessage:function(e){this._typeahead.update([]),this._typeahead.selected=null,this._typeahead.clear(),this._typeahead.renderError(e)},_getPlaceholderText:function(){if(this.options.placeholder)return this.options.placeholder;if(this.options.language){var e=this.options.language.split(",")[0],t=tse.language(e),n=ese.placeholder[t];if(n)return n}return"Search"},setInput:function(e){return this._inputEl.value=e,this._typeahead.selected=null,this._typeahead.clear(),e.length>=this.options.minLength&&this._geocode(e),this},setProximity:function(e,t=!0){return this.options.proximity=e,t&&(this.options.trackProximity=!1),this},getProximity:function(){return this.options.proximity},setRenderFunction:function(e){return e&&typeof e=="function"&&(this._typeahead.render=e),this},getRenderFunction:function(){return this._typeahead.render},setLanguage:function(e){var t=navigator.language||navigator.userLanguage||navigator.browserLanguage;return this.options.language=e||this.options.language||t,this},getLanguage:function(){return this.options.language},getZoom:function(){return this.options.zoom},setZoom:function(e){return this.options.zoom=e,this},getFlyTo:function(){return this.options.flyTo},setFlyTo:function(e){return this.options.flyTo=e,this},getPlaceholder:function(){return this.options.placeholder},setPlaceholder:function(e){return this.placeholder=e||this._getPlaceholderText(),this._inputEl.placeholder=this.placeholder,this._inputEl.setAttribute("aria-label",this.placeholder),this},getBbox:function(){return this.options.bbox},setBbox:function(e){return this.options.bbox=e,this},getCountries:function(){return this.options.countries},setCountries:function(e){return this.options.countries=e,this},getTypes:function(){return this.options.types},setTypes:function(e){return this.options.types=e,this},getMinLength:function(){return this.options.minLength},setMinLength:function(e){return this.options.minLength=e,this._typeahead&&(this._typeahead.options.minLength=e),this},getLimit:function(){return this.options.limit},setLimit:function(e){return this.options.limit=e,this._typeahead&&(this._typeahead.options.limit=e),this},getFilter:function(){return this.options.filter},setFilter:function(e){return this.options.filter=e,this},setOrigin:function(e){return this.options.origin=e,this.geocoderService=sE(aE({accessToken:this.options.accessToken,origin:this.options.origin})),this},getOrigin:function(){return this.options.origin},setAccessToken:function(e){return this.options.accessToken=e,this.geocoderService=sE(aE({accessToken:this.options.accessToken,origin:this.options.origin})),this},setAutocomplete:function(e){return this.options.autocomplete=e,this},getAutocomplete:function(){return this.options.autocomplete},setFuzzyMatch:function(e){return this.options.fuzzyMatch=e,this},getFuzzyMatch:function(){return this.options.fuzzyMatch},setRouting:function(e){return this.options.routing=e,this},getRouting:function(){return this.options.routing},setWorldview:function(e){return this.options.worldview=e,this},getWorldview:function(){return this.options.worldview},_handleMarker:function(e){if(this._map){this._removeMarker();var t={color:"#4668F2"},n=Uf({},t,this.options.marker);return this.mapMarker=new this._mapboxgl.Marker(n),e.center?this.mapMarker.setLngLat(e.center).addTo(this._map):e.geometry&&e.geometry.type&&e.geometry.type==="Point"&&e.geometry.coordinates&&this.mapMarker.setLngLat(e.geometry.coordinates).addTo(this._map),this}},_removeMarker:function(){this.mapMarker&&(this.mapMarker.remove(),this.mapMarker=null)},on:function(e,t){return this._eventEmitter.on(e,t),this},off:function(e,t){return this._eventEmitter.removeListener(e,t),this.eventManager.remove(),this}};var ise=o4;const ose=Rd(ise);var a4={}
1432,ase=oo&&oo.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(a4,"__esModule",{value:!0});const sse=ase(k2);var C1=a4.default=sse.default,lse=function e(t,n){if(t===n)return!0;if(t&&n&&typeof t=="object"&&typeof n=="object"){if(t.constructor!==n.constructor)return!1;var r,i,s;if(Array.isArray(t)){if(r=t.length,r!=n.length)return!1;for(i=r;i--!==0;)if(!e(t[i],n[i]))return!1;return!0}if(t.constructor===RegExp)return t.source===n.source&&t.flags===n.flags;if(t.valueOf!==Object.prototype.valueOf)return t.valueOf()===n.valueOf();if(t.toString!==Object.prototype.toString)return t.toString()===n.toString();if(s=Object.keys(t),r=s.length,r!==Object.keys(n).length)return!1;for(i=r;i--!==0;)if(!Object.prototype.hasOwnProperty.call(n,s[i]))return!1;for(i=r;i--!==0;){var c=s[i];if(!e(t[c],n[c]))return!1}return!0}return t!==t&&n!==n};const s4=Rd(lse);var l4={exports:{}};(function(e,t){(function(n,r){e.exports=r()})(oo,function(){var n=function(O,G){var he={drag:[],click:[],mousemove:[],mousedown:[],mouseup:[],mouseout:[],keydown:[],keyup:[],touchstart:[],touchmove:[],touchend:[],tap:[]},Re={on:function(Qe,it,Qt){if(he[Qe]===void 0)throw new Error("Invalid event type: "+Qe);he[Qe].push({selector:it,fn:Qt})},render:function(Qe){G.store.featureChanged(Qe)}},Ve=function(Qe,it){for(var Qt=he[Qe],on=Qt.length;on--;){var _n=Qt[on];if(_n.selector(it)){_n.fn.call(Re,it)||G.store.render(),G.ui.updateMapClasses();break}}};return O.start.call(Re),{render:O.render,stop:function(){O.stop&&O.stop()},trash:function(){O.trash&&(O.trash(),G.store.render())},combineFeatures:function(){O.combineFeatures&&O.combineFeatures()},uncombineFeatures:function(){O.uncombineFeatures&&O.uncombineFeatures()},drag:function(Qe){Ve("drag",Qe)},click:function(Qe){Ve("click",Qe)},mousemove:function(Qe){Ve("mousemove",Qe)},mousedown:function(Qe){Ve("mousedown",Qe)},mouseup:function(Qe){Ve("mouseup",Qe)},mouseout:function(Qe){Ve("mouseout",Qe)},keydown:function(Qe){Ve("keydown",Qe)},keyup:function(Qe){Ve("keyup",Qe)},touchstart:function(Qe){Ve("touchstart",Qe)},touchmove:function(Qe){Ve("touchmove",Qe)},touchend:function(Qe){Ve("touchend",Qe)},tap:function(Qe){Ve("tap",Qe)}}};function r(O){return O&&O.__esModule&&Object.prototype.hasOwnProperty.call(O,"default")?O.default:O}function i(O){if(O.__esModule)return O;var G=O.default;if(typeof G=="function"){var he=function Re(){if(this instanceof Re){var Ve=[null];Ve.push.apply(Ve,arguments);var Qe=Function.bind.apply(G,Ve);return new Qe}return G.apply(this,arguments)};he.prototype=G.prototype}else he={};return Object.defineProperty(he,"__esModule",{value:!0}),Object.keys(O).forEach(function(Re){var Ve=Object.getOwnPropertyDescriptor(O,Re);Object.defineProperty(he,Re,Ve.get?Ve:{enumerable:!0,get:function(){return O[Re]}})}),he}var s={},c={RADIUS:6378137,FLATTENING:1/298.257223563,POLAR_RADIUS:63567523142e-4},a=c;function m(O){var G=0;if(O&&O.length>0){G+=Math.abs(g(O[0]));for(var he=1;he<O.length;he++)G-=Math.abs(g(O[he]))}return G}function g(O){var G,he,Re,Ve,Qe,it,Qt=0,on=O.length;if(on>2){for(it=0;it<on;it++)it===on-2?(Re=on-2,Ve=on-1,Qe=0):it===on-1?(Re=on-1,Ve=0,Qe=1):(Re=it,Ve=it+1,Qe=it+2),G=O[Re],he=O[Ve],Qt+=(x(O[Qe][0])-x(G[0]))*Math.sin(x(he[1]));Qt=Qt*a.RADIUS*a.RADIUS/2}return Qt}function x(O){return O*Math.PI/180}s.geometry=function O(G){var he,Re=0;switch(G.type){case"Polygon":return m(G.coordinates);case"MultiPolygon":for(he=0;he<G.coordinates.length;he++)Re+=m(G.coordinates[he]);return Re;case"Point":case"MultiPoint":case"LineString":case"MultiLineString":return 0;case"GeometryCollection":for(he=0;he<G.geometries.length;he++)Re+=O(G.geometries[he]);return Re}},s.ring=g;var T={CONTROL_BASE:"mapboxgl-ctrl",CONTROL_PREFIX:"mapboxgl-ctrl-",CONTROL_BUTTON:"mapbox-gl-draw_ctrl-draw-btn",CONTROL_BUTTON_LINE:"mapbox-gl-draw_line",CONTROL_BUTTON_POLYGON:"mapbox-gl-draw_polygon",CONTROL_BUTTON_POINT:"mapbox-gl-draw_point",CONTROL_BUTTON_TRASH:"mapbox-gl-draw_trash",CONTROL_BUTTON_COMBINE_FEATURES:"mapbox-gl-draw_combine",CONTROL_BUTTON_UNCOMBINE_FEATURES:"mapbox-gl-draw_uncombine",CONTROL_GROUP:"mapboxgl-ctrl-group",ATTRIBUTION:"mapboxgl-ctrl-attrib",ACTIVE_BUTTON:"active",BOX_SELECT:"mapbox-gl-draw_boxselect"},C={HOT:"mapbox-gl-draw-hot",COLD:"mapbox-gl-draw-cold"},A={ADD:"add",MOVE:"move",DRAG:"drag",POINTER:"pointer",NONE:"none"},P={POLYGON:"polygon",LINE:"line_string",POINT:"point"},D={FEATURE:"Feature",POLYGON:"Polygon",LINE_STRING:"LineString",POINT:"Point",FEATURE_COLLECTION:"FeatureCollection",MULTI_PREFIX:"Multi",MULTI_POINT:"MultiPoint",MULTI_LINE_STRING:"MultiLineString",MULTI_POLYGON:"MultiPolygon"},B={DRAW_LINE_STRING:"draw_line_string",DRAW_POLYGON:"draw_polygon",DRAW_POINT:"draw_point",SIMPLE_SELECT:"simple_select",DIRECT_SELECT:"direct_select",STATIC:"static"}
1432,R={CREATE:"draw.create",DELETE:"draw.delete",UPDATE:"draw.update",SELECTION_CHANGE:"draw.selectionchange",MODE_CHANGE:"draw.modechange",ACTIONABLE:"draw.actionable",RENDER:"draw.render",COMBINE_FEATURES:"draw.combine",UNCOMBINE_FEATURES:"draw.uncombine"},N={MOVE:"move",CHANGE_COORDINATES:"change_coordinates"},j={FEATURE:"feature",MIDPOINT:"midpoint",VERTEX:"vertex"},U={ACTIVE:"true",INACTIVE:"false"},W=["scrollZoom","boxZoom","dragRotate","dragPan","keyboard","doubleClickZoom","touchZoomRotate"],Q=-85,Z=Object.freeze({__proto__:null,classes:T,sources:C,cursors:A,types:P,geojsonTypes:D,modes:B,events:R,updateActions:N,meta:j,activeStates:U,interactions:W,LAT_MIN:-90,LAT_RENDERED_MIN:Q,LAT_MAX:90,LAT_RENDERED_MAX:85,LNG_MIN:-270,LNG_MAX:270}),K={Point:0,LineString:1,MultiLineString:1,Polygon:2};function Y(O,G){var he=K[O.geometry.type]-K[G.geometry.type];return he===0&&O.geometry.type===D.POLYGON?O.area-G.area:he}function me(O){return O.map(function(G){return G.geometry.type===D.POLYGON&&(G.area=s.geometry({type:D.FEATURE,property:{},geometry:G.geometry})),G}).sort(Y).map(function(G){return delete G.area,G})}function ge(O,G){return G===void 0&&(G=0),[[O.point.x-G,O.point.y-G],[O.point.x+G,O.point.y+G]]}function ce(O){if(this._items={},this._nums={},this._length=O?O.length:0,O)for(var G=0,he=O.length;G<he;G++)this.add(O[G]),O[G]!==void 0&&(typeof O[G]=="string"?this._items[O[G]]=G:this._nums[O[G]]=G)}ce.prototype.add=function(O){return this.has(O)||(this._length++,typeof O=="string"?this._items[O]=this._length:this._nums[O]=this._length),this},ce.prototype.delete=function(O){return this.has(O)===!1||(this._length--,delete this._items[O],delete this._nums[O]),this},ce.prototype.has=function(O){return(typeof O=="string"||typeof O=="number")&&(this._items[O]!==void 0||this._nums[O]!==void 0)},ce.prototype.values=function(){var O=this,G=[];return Object.keys(this._items).forEach(function(he){G.push({k:he,v:O._items[he]})}),Object.keys(this._nums).forEach(function(he){G.push({k:JSON.parse(he),v:O._nums[he]})}),G.sort(function(he,Re){return he.v-Re.v}).map(function(he){return he.k})},ce.prototype.clear=function(){return this._length=0,this._items={},this._nums={},this};var fe=[j.FEATURE,j.MIDPOINT,j.VERTEX],ie={click:function(O,G,he){return xe(O,G,he,he.options.clickBuffer)},touch:function(O,G,he){return xe(O,G,he,he.options.touchBuffer)}};function xe(O,G,he,Re){if(he.map===null)return[];var Ve=O?ge(O,Re):G,Qe={};he.options.styles&&(Qe.layers=he.options.styles.map(function(_n){return _n.id}).filter(function(_n){return he.map.getLayer(_n)!=null}));var it=he.map.queryRenderedFeatures(Ve,Qe).filter(function(_n){return fe.indexOf(_n.properties.meta)!==-1}),Qt=new ce,on=[];return it.forEach(function(_n){var bn=_n.properties.id;Qt.has(bn)||(Qt.add(bn),on.push(_n))}),me(on)}function Te(O,G){var he=ie.click(O,null,G),Re={mouse:A.NONE};return he[0]&&(Re.mouse=he[0].properties.active===U.ACTIVE?A.MOVE:A.POINTER,Re.feature=he[0].properties.meta),G.events.currentModeName().indexOf("draw")!==-1&&(Re.mouse=A.ADD),G.ui.queueMapClasses(Re),G.ui.updateMapClasses(),he[0]}function oe(O,G){var he=O.x-G.x,Re=O.y-G.y;return Math.sqrt(he*he+Re*Re)}function ne(O,G,he){he===void 0&&(he={});var Re=he.fineTolerance!=null?he.fineTolerance:4,Ve=he.grossTolerance!=null?he.grossTolerance:12,Qe=he.interval!=null?he.interval:500;O.point=O.point||G.point,O.time=O.time||G.time;var it=oe(O.point,G.point);return it<Re||it<Ve&&G.time-O.time<Qe}function le(O,G,he){he===void 0&&(he={});var Re=he.tolerance!=null?he.tolerance:25,Ve=he.interval!=null?he.interval:250;return O.point=O.point||G.point,O.time=O.time||G.time,oe(O.point,G.point)<Re&&G.time-O.time<Ve}var se={exports:{}},Ne=se.exports=function(O,G){if(G||(G=16),O===void 0&&(O=128),O<=0)return"0";for(var he=Math.log(Math.pow(2,O))/Math.log(G),Re=2;he===1/0;Re*=2)he=Math.log(Math.pow(2,O/Re))/Math.log(G)*Re;var Ve=he-Math.floor(he),Qe="";for(Re=0;Re<Math.floor(he);Re++)Qe=Math.floor(Math.random()*G).toString(G)+Qe;if(Ve){var it=Math.pow(G,Ve);Qe=Math.floor(Math.random()*it).toString(G)+Qe}var Qt=parseInt(Qe,G);return Qt!==1/0&&Qt>=Math.pow(2,O)?Ne(O,G):Qe};Ne.rack=function(O,G,he){var Re=function(Qe){var it=0;do{if(it++>10){if(!he)throw new Error("too many ID collisions, use more bits");O+=he}var Qt=Ne(O,G)}while(Object.hasOwnProperty.call(Ve,Qt));return Ve[Qt]=Qe,Qt},Ve=Re.hats={};return Re.get=function(Qe){return Re.hats[Qe]},Re.set=function(Qe,it){return Re.hats[Qe]=it,Re},Re.bits=O||128,Re.base=G||16,Re};var Se=r(se.exports),xt=function(O,G){this.ctx=O,this.properties=G.properties||{},this.coordinates=G.geometry.coordinates,this.id=G.id||Se(),this.type=G.geometry.type};xt.prototype.changed=function(){this.ctx.store.featureChanged(this.id)},xt.prototype.incomingCoords=function(O){this.setCoordinates(O)},xt.prototype.setCoordinates=function(O){this.coordinates=O,this.changed()},xt.prototype.getCoordinates=function(){return JSON.parse(JSON.stringify(this.coordinates))},xt.prototype.setProperty=function(O,G){this.properties[O]=G},xt.prototype.toGeoJSON=function(){return JSON.parse(JSON.stringify({id:this.id,type:D.FEATURE,properties:this.properties,geometry:{coordinates:this.getCoordinates(),type:this.t
1432ype}}))},xt.prototype.internal=function(O){var G={id:this.id,meta:j.FEATURE,"meta:type":this.type,active:U.INACTIVE,mode:O};if(this.ctx.options.userProperties)for(var he in this.properties)G["user_"+he]=this.properties[he];return{type:D.FEATURE,properties:G,geometry:{coordinates:this.getCoordinates(),type:this.type}}};var kt=function(O,G){xt.call(this,O,G)};(kt.prototype=Object.create(xt.prototype)).isValid=function(){return typeof this.coordinates[0]=="number"&&typeof this.coordinates[1]=="number"},kt.prototype.updateCoordinate=function(O,G,he){this.coordinates=arguments.length===3?[G,he]:[O,G],this.changed()},kt.prototype.getCoordinate=function(){return this.getCoordinates()};var wt=function(O,G){xt.call(this,O,G)};(wt.prototype=Object.create(xt.prototype)).isValid=function(){return this.coordinates.length>1},wt.prototype.addCoordinate=function(O,G,he){this.changed();var Re=parseInt(O,10);this.coordinates.splice(Re,0,[G,he])},wt.prototype.getCoordinate=function(O){var G=parseInt(O,10);return JSON.parse(JSON.str
1432ingify(this.coordinates[G]))},wt.prototype.removeCoordinate=function(O){this.changed(),this.coordinates.splice(parseInt(O,10),1)},wt.prototype.updateCoordinate=function(O,G,he){var Re=parseInt(O,10);this.coordinates[Re]=[G,he],this.changed()};var Ue=function(O,G){xt.call(this,O,G),this.coordinates=this.coordinates.map(function(he){return he.slice(0,-1)})};(Ue.prototype=Object.create(xt.prototype)).isValid=function(){return this.coordinates.length!==0&&this.coordinates.every(function(O){return O.length>2})},Ue.prototype.incomingCoords=function(O){this.coordinates=O.map(function(G){return G.slice(0,-1)}),this.changed()},Ue.prototype.setCoordinates=function(O){this.coordinates=O,this.changed()},Ue.prototype.addCoordinate=function(O,G,he){this.changed();var Re=O.split(".").map(function(Ve){return parseInt(Ve,10)});this.coordinates[Re[0]].splice(Re[1],0,[G,he])},Ue.prototype.removeCoordinate=function(O){this.changed();var G=O.split(".").map(function(Re){return parseInt(Re,10)}),he=this.coordinates[G[0]];he&&(he.splice(G[1],1),he.length<3&&this.coordinates.splice(G[0],1))},Ue.prototype.getCoordinate=function(O){var G=O.split(".").map(function(Re){return parseInt(Re,10)}),he=this.coordinates[G[0]];return JSON.parse(JSON.stringify(he[G[1]]))},Ue.prototype.getCoordinates=function(){return this.coordinates.map(function(O){return O.concat([O[0]])})},Ue.prototype.updateCoordinate=function(O,G,he){this.changed();var Re=O.split("."),Ve=parseInt(Re[0],10),Qe=parseInt(Re[1],10);this.coordinates[Ve]===void 0&&(this.coordinates[Ve]=[]),this.coordinates[Ve][Qe]=[G,he]};var je={MultiPoint:kt,MultiLineString:wt,MultiPolygon:Ue},st=function(O,G,he,Re,Ve){var Qe=he.split("."),it=parseInt(Qe[0],10),Qt=Qe[1]?Qe.slice(1).join("."):null;return O[it][G](Qt,Re,Ve)},tt=function(O,G){if(xt.call(this,O,G),delete this.coordinates,this.model=je[G.geometry.type],this.model===void 0)throw new TypeError(G.geometry.type+" is not a valid type");this.features=this._coordinatesToFeatures(G.geometry.coordinates)};function Me(O){this.map=O.map,this.drawConfig=JSON.parse(JSON.stringify(O.options||{})),this._ctx=O}(tt.prototype=Object.create(xt.prototype))._coordinatesToFeatures=function(O){var G=this,he=this.model.bind(this);return O.map(function(Re){return new he(G.ctx,{id:Se(),type:D.FEATURE,properties:{},geometry:{coordinates:Re,type:G.type.replace("Multi","")}})})},tt.prototype.isValid=function(){return this.features.every(function(O){return O.isValid()})},tt.prototype.setCoordinates=function(O){this.features=this._coordinatesToFeatures(O),this.changed()},tt.prototype.getCoordinate=function(O){return st(this.features,"getCoordinate",O)},tt.prototype.getCoordinates=function(){return JSON.parse(JSON.stringify(this.features.map(function(O){return O.type===D.POLYGON?O.getCoordinates():O.coordinates})))},tt.prototype.updateCoordinate=function(O,G,he){st(this.features,"updateCoordinate",O,G,he),this.changed()},tt.prototype.addCoordinate=function(O,G,he){st(this.features,"addCoordinate",O,G,he),this.changed()},tt.prototype.removeCoordinate=function(O){st(this.features,"removeCoordinate",O),this.changed()},tt.prototype.getFeatures=function(){return this.features},Me.prototype.setSelected=function(O){return this._ctx.store.setSelected(O)},Me.prototype.setSelectedCoordinates=function(O){var G=this;this._ctx.store.setSelectedCoordinates(O),O.reduce(function(he,Re){return he[Re.feature_id]===void 0&&(he[Re.feature_id]=!0,G._ctx.store.get(Re.feature_id).changed()),he},{})},Me.prototype.getSelected=function(){return this._ctx.store.getSelected()},Me.prototype.getSelectedIds=function(){return this._ctx.store.getSelectedIds()},Me.prototype.isSelected=function(O){return this._ctx.store.isSelected(O)},Me.prototype.getFeature=function(O){return this._ctx.store.get(O)},Me.prototype.select=function(O){return this._ctx.store.select(O)},Me.prototype.deselect=function(O){return this._ctx.store.deselect(O)},Me.prototype.deleteFeature=function(O,G){return G===void 0&&(G={}),this._ctx.store.delete(O,G)},Me.prototype.addFeature=function(O){return this._ctx.store.add(O)},Me.prototype.clearSelectedFeatures=function(){return this._ctx.store.clearSelected()},Me.prototype.clearSelectedCoordinates=function(){return this._ctx.store.clearSelectedCoordinates()},Me.prototype.setActionableState=function(O){O===void 0&&(O={});var G={trash:O.trash||!1,combineFeatures:O.combineFeatures||!1,uncombineFeatures:O.uncombineFeatures||!1};return this._ctx.events.actionable(G)}
1432,Me.prototype.changeMode=function(O,G,he){return G===void 0&&(G={}),he===void 0&&(he={}),this._ctx.events.changeMode(O,G,he)},Me.prototype.updateUIClasses=function(O){return this._ctx.ui.queueMapClasses(O)},Me.prototype.activateUIButton=function(O){return this._ctx.ui.setActiveButton(O)},Me.prototype.featuresAt=function(O,G,he){if(he===void 0&&(he="click"),he!=="click"&&he!=="touch")throw new Error("invalid buffer type");return ie[he](O,G,this._ctx)},Me.prototype.newFeature=function(O){var G=O.geometry.type;return G===D.POINT?new kt(this._ctx,O):G===D.LINE_STRING?new wt(this._ctx,O):G===D.POLYGON?new Ue(this._ctx,O):new tt(this._ctx,O)},Me.prototype.isInstanceOf=function(O,G){if(O===D.POINT)return G instanceof kt;if(O===D.LINE_STRING)return G instanceof wt;if(O===D.POLYGON)return G instanceof Ue;if(O==="MultiFeature")return G instanceof tt;throw new Error("Unknown feature class: "+O)},Me.prototype.doRender=function(O){return this._ctx.store.featureChanged(O)},Me.prototype.onSetup=function(){},Me.prototype.onDrag=function(){},Me.prototype.onClick=function(){},Me.prototype.onMouseMove=function(){},Me.prototype.onMouseDown=function(){},Me.prototype.onMouseUp=function(){},Me.prototype.onMouseOut=function(){},Me.prototype.onKeyUp=function(){},Me.prototype.onKeyDown=function(){},Me.prototype.onTouchStart=function(){},Me.prototype.onTouchMove=function(){},Me.prototype.onTouchEnd=function(){},Me.prototype.onTap=function(){},Me.prototype.onStop=function(){},Me.prototype.onTrash=function(){},Me.prototype.onCombineFeature=function(){},Me.prototype.onUncombineFeature=function(){},Me.prototype.toDisplayFeatures=function(){throw new Error("You must overwrite toDisplayFeatures")};var lt={drag:"onDrag",click:"onClick",mousemove:"onMouseMove",mousedown:"onMouseDown",mouseup:"onMouseUp",mouseout:"onMouseOut",keyup:"onKeyUp",keydown:"onKeyDown",touchstart:"onTouchStart",touchmove:"onTouchMove",touchend:"onTouchEnd",tap:"onTap"},Ae=Object.keys(lt);function we(O){var G=Object.keys(O);return function(he,Re){Re===void 0&&(Re={});var Ve={},Qe=G.reduce(function(it,Qt){return it[Qt]=O[Qt],it},new Me(he));return{start:function(){var it=this;Ve=Qe.onSetup(Re),Ae.forEach(function(Qt){var on,_n=lt[Qt],bn=function(){return!1};O[_n]&&(bn=function(){return!0}),it.on(Qt,bn,(on=_n,function(cn){return Qe[on](Ve,cn)}))})},stop:function(){Qe.onStop(Ve)},trash:function(){Qe.onTrash(Ve)},combineFeatures:function(){Qe.onCombineFeatures(Ve)},uncombineFeatures:function(){Qe.onUncombineFeatures(Ve)},render:function(it,Qt){Qe.toDisplayFeatures(Ve,it,Qt)}}}}function Je(O){return[].concat(O).filter(function(G){return G!==void 0})}function ct(){var O=this;if(!(O.ctx.map&&O.ctx.map.getSource(C.HOT)!==void 0))return on();var G=O.ctx.events.currentModeName();O.ctx.ui.queueMapClasses({mode:G});var he=[],Re=[];O.isDirty?Re=O.getAllIds():(he=O.getChangedIds().filter(function(_n){return O.get(_n)!==void 0}),Re=O.sources.hot.filter(function(_n){return _n.properties.id&&he.indexOf(_n.properties.id)===-1&&O.get(_n.properties.id)!==void 0}).map(function(_n){return _n.properties.id})),O.sources.hot=[];var Ve=O.sources.cold.length;O.sources.cold=O.isDirty?[]:O.sources.cold.filter(function(_n){var bn=_n.properties.id||_n.properties.parent;return he.indexOf(bn)===-1});var Qe=Ve!==O.sources.cold.length||Re.length>0;function it(_n,bn){var cn=O.get(_n).internal(G);O.ctx.events.currentModeRender(cn,function(qn){O.sources[bn].push(qn)})}if(he.forEach(function(_n){return it(_n,"hot")}),Re.forEach(function(_n){return it(_n,"cold")}),Qe&&O.ctx.map.getSource(C.COLD).setData({type:D.FEATURE_COLLECTION,features:O.sources.cold}),O.ctx.map.getSource(C.HOT).setData({type:D.FEATURE_COLLECTION,features:O.sources.hot}),O._emitSelectionChange&&(O.ctx.map.fire(R.SELECTION_CHANGE,{features:O.getSelected().map(function(_n){return _n.toGeoJSON()}),points:O.getSelectedCoordinates().map(function(_n){return{type:D.FEATURE,properties:{},geometry:{type:D.POINT,coordinates:_n.coordinates}}})}),O._emitSelectionChange=!1),O._deletedFeaturesToEmit.length){var Qt=O._deletedFeaturesToEmit.map(function(_n){return _n.toGeoJSON()});O._deletedFeaturesToEmit=[],O.ctx.map.fire(R.DELETE,{features:Qt})}function on(){O.isDirty=!1,O.clearChangedIds()}on(),O.ctx.map.fire(R.RENDER,{})}function mt(O){var G,he=this;this._features={},this._featureIds=new ce,this._selectedFeatureIds=new ce,this._selectedCoordinates=[],this._changedFeatureIds=new ce,this._deletedFeaturesToEmit=[],this._emitSelectionChange=!1,this._mapInitialConfig={},this.ctx=O,this.sources={hot:[],cold:[]},this.render=function(){G||(G=requestAnimationFrame(function(){G=null,ct.call(he)}))},this.isDirty=!1}function Vt(O,G){var he=O._selectedCoordinates.filter(function(Re){return O._selectedFeatureIds.has(Re.feature_id)});
1432O._selectedCoordinates.length===he.length||G.silent||(O._emitSelectionChange=!0),O._selectedCoordinates=he}mt.prototype.createRenderBatch=function(){var O=this,G=this.render,he=0;return this.render=function(){he++},function(){O.render=G,he>0&&O.render()}},mt.prototype.setDirty=function(){return this.isDirty=!0,this},mt.prototype.featureChanged=function(O){return this._changedFeatureIds.add(O),this},mt.prototype.getChangedIds=function(){return this._changedFeatureIds.values()},mt.prototype.clearChangedIds=function(){return this._changedFeatureIds.clear(),this},mt.prototype.getAllIds=function(){return this._featureIds.values()},mt.prototype.add=function(O){return this.featureChanged(O.id),this._features[O.id]=O,this._featureIds.add(O.id),this},mt.prototype.delete=function(O,G){var he=this;return G===void 0&&(G={}),Je(O).forEach(function(Re){he._featureIds.has(Re)&&(he._featureIds.delete(Re),he._selectedFeatureIds.delete(Re),G.silent||he._deletedFeaturesToEmit.indexOf(he._features[Re])===-1&&he._deletedFeaturesToEmit.push(he._features[Re]),delete he._features[Re],he.isDirty=!0)}),Vt(this,G),this},mt.prototype.get=function(O){return this._features[O]},mt.prototype.getAll=function(){var O=this;return Object.keys(this._features).map(function(G){return O._features[G]})},mt.prototype.select=function(O,G){var he=this;return G===void 0&&(G={}),Je(O).forEach(function(Re){he._selectedFeatureIds.has(Re)||(he._selectedFeatureIds.add(Re),he._changedFeatureIds.add(Re),G.silent||(he._emitSelectionChange=!0))}),this},mt.prototype.deselect=function(O,G){var he=this;return G===void 0&&(G={}),Je(O).forEach(function(Re){he._selectedFeatureIds.has(Re)&&(he._selectedFeatureIds.delete(Re),he._changedFeatureIds.add(Re),G.silent||(he._emitSelectionChange=!0))}),Vt(this,G),this},mt.prototype.clearSelected=function(O){return O===void 0&&(O={}),this.deselect(this._selectedFeatureIds.values(),{silent:O.silent}),this},mt.prototype.setSelected=function(O,G){var he=this;return G===void 0&&(G={}),O=Je(O),this.deselect(this._selectedFeatureIds.values().filter(function(Re){return O.indexOf(Re)===-1}),{silent:G.silent}),this.select(O.filter(function(Re){return!he._selectedFeatureIds.has(Re)}),{silent:G.silent}),this},mt.prototype.setSelectedCoordinates=function(O){return this._selectedCoordinates=O,this._emitSelectionChange=!0,this},mt.prototype.clearSelectedCoordinates=function(){return this._selectedCoordinates=[],this._emitSelectionChange=!0,this},mt.prototype.getSelectedIds=function(){return this._selectedFeatureIds.values()},mt.prototype.getSelected=function(){var O=this;return this._selectedFeatureIds.values().map(function(G){return O.get(G)})},mt.prototype.getSelectedCoordinates=function(){var O=this;return this._selectedCoordinates.map(function(G){return{coordinates:O.get(G.feature_id).getCoordinate(G.coord_path)}})},mt.prototype.isSelected=function(O){return this._selectedFeatureIds.has(O)},mt.prototype.setFeatureProperty=function(O,G,he){this.get(O).setProperty(G,he),this.featureChanged(O)},mt.prototype.storeMapConfig=function(){var O=this;W.forEach(function(G){O.ctx.map[G]&&(O._mapInitialConfig[G]=O.ctx.map[G].isEnabled())})},mt.prototype.restoreMapConfig=function(){var O=this;Object.keys(this._mapInitialConfig).forEach(function(G){O._mapInitialConfig[G]?O.ctx.map[G].enable():O.ctx.map[G].disable()})},mt.prototype.getInitialConfigValue=function(O){return this._mapInitialConfig[O]===void 0||this._mapInitialConfig[O]};var Ie=function(){for(var O=arguments,G={},he=0;he<arguments.length;he++){var Re=O[he];for(var Ve in Re)Pe.call(Re,Ve)&&(G[Ve]=Re[Ve])}return G},Pe=Object.prototype.hasOwnProperty,rt=r(Ie),Tt=["mode","feature","mouse"];function pn(O){var G=null,he=null,Re={onRemove:function(){return O.map.off("load",Re.connect),clearInterval(he),Re.removeLayers(),O.store.restoreMapConfig(),O.ui.removeButtons(),O.events.removeEventListeners(),O.ui.clearMapClasses(),O.boxZoomInitial&&O.map.boxZoom.enable(),O.map=null,O.container=null,O.store=null,G&&G.parentNode&&G.parentNode.removeChild(G),G=null,this},connect:function(){O.map.off("load",Re.connect),clearInterval(he),Re.addLayers(),O.store.storeMapConfig(),O.events.addEventListeners()},onAdd:function(Ve){var Qe=Ve.fire;return Ve.fire=function(it,Qt){var on=arguments;return Qe.length===1&&arguments.length!==1&&(on=[rt({},{type:it},Qt)]),Qe.apply(Ve,on)},O.map=Ve,O.events=function(it){var Qt=Object.keys(it.options.modes).reduce(function(Rt,An){return Rt[An]=we(it.options.modes[An]),Rt},{}),on={},_n={},bn={},cn=null,qn=null;bn.drag=function(Rt,An){An({point:Rt.point,time:new Date().getTime()})?(it.ui.queueMapClasses({mouse:A.DRAG}),qn.drag(Rt)):Rt.originalEvent.stopPropagation()},bn.mousedrag=function(Rt){bn.drag(Rt,function(An){return!ne(on,An)})}
1432,bn.touchdrag=function(Rt){bn.drag(Rt,function(An){return!le(_n,An)})},bn.mousemove=function(Rt){if((Rt.originalEvent.buttons!==void 0?Rt.originalEvent.buttons:Rt.originalEvent.which)===1)return bn.mousedrag(Rt);var An=Te(Rt,it);Rt.featureTarget=An,qn.mousemove(Rt)},bn.mousedown=function(Rt){on={time:new Date().getTime(),point:Rt.point};var An=Te(Rt,it);Rt.featureTarget=An,qn.mousedown(Rt)},bn.mouseup=function(Rt){var An=Te(Rt,it);Rt.featureTarget=An,ne(on,{point:Rt.point,time:new Date().getTime()})?qn.click(Rt):qn.mouseup(Rt)},bn.mouseout=function(Rt){qn.mouseout(Rt)},bn.touchstart=function(Rt){if(it.options.touchEnabled){_n={time:new Date().getTime(),point:Rt.point};var An=ie.touch(Rt,null,it)[0];Rt.featureTarget=An,qn.touchstart(Rt)}},bn.touchmove=function(Rt){if(it.options.touchEnabled)return qn.touchmove(Rt),bn.touchdrag(Rt)},bn.touchend=function(Rt){if(Rt.originalEvent.preventDefault(),it.options.touchEnabled){var An=ie.touch(Rt,null,it)[0];Rt.featureTarget=An,le(_n,{time:new Date().getTime(),point:Rt.point})?qn.tap(Rt):qn.touchend(Rt)}};var vi=function(Rt){return!(Rt===8||Rt===46||Rt>=48&&Rt<=57)};function Zn(Rt,An,Fr){Fr===void 0&&(Fr={}),qn.stop();var Br=Qt[Rt];if(Br===void 0)throw new Error(Rt+" is not valid");cn=Rt;var zr=Br(it,An);qn=n(zr,it),Fr.silent||it.map.fire(R.MODE_CHANGE,{mode:Rt}),it.store.setDirty(),it.store.render()}bn.keydown=function(Rt){(Rt.srcElement||Rt.target).classList.contains("mapboxgl-canvas")&&(Rt.keyCode!==8&&Rt.keyCode!==46||!it.options.controls.trash?vi(Rt.keyCode)?qn.keydown(Rt):Rt.keyCode===49&&it.options.controls.point?Zn(B.DRAW_POINT):Rt.keyCode===50&&it.options.controls.line_string?Zn(B.DRAW_LINE_STRING):Rt.keyCode===51&&it.options.controls.polygon&&Zn(B.DRAW_POLYGON):(Rt.preventDefault(),qn.trash()))},bn.keyup=function(Rt){vi(Rt.keyCode)&&qn.keyup(Rt)},bn.zoomend=function(){it.store.changeZoom()},bn.data=function(Rt){if(Rt.dataType==="style"){var An=it.setup,Fr=it.map,Br=it.options,zr=it.store;Br.styles.some(function(dh){return Fr.getLayer(dh.id)})||(An.addLayers(),zr.setDirty(),zr.render())}};var Pr={trash:!1,combineFeatures:!1,uncombineFeatures:!1};return{start:function(){cn=it.options.defaultMode,qn=n(Qt[cn](it),it)},changeMode:Zn,actionable:function(Rt){var An=!1;Object.keys(Rt).forEach(function(Fr){if(Pr[Fr]===void 0)throw new Error("Invalid action type");Pr[Fr]!==Rt[Fr]&&(An=!0),Pr[Fr]=Rt[Fr]}),An&&it.map.fire(R.ACTIONABLE,{actions:Pr})},currentModeName:function(){return cn},currentModeRender:function(Rt,An){return qn.render(Rt,An)},fire:function(Rt,An){bn[Rt]&&bn[Rt](An)},addEventListeners:function(){it.map.on("mousemove",bn.mousemove),it.map.on("mousedown",bn.mousedown),it.map.on("mouseup",bn.mouseup),it.map.on("data",bn.data),it.map.on("touchmove",bn.touchmove),it.map.on("touchstart",bn.touchstart),it.map.on("touchend",bn.touchend),it.container.addEventListener("mouseout",bn.mouseout),it.options.keybindings&&(it.container.addEventListener("keydown",bn.keydown),it.container.addEventListener("keyup",bn.keyup))},removeEventListeners:function(){it.map.off("mousemove",bn.mousemove),it.map.off("mousedown",bn.mousedown),it.map.off("mouseup",bn.mouseup),it.map.off("data",bn.data),it.map.off("touchmove",bn.touchmove),it.map.off("touchstart",bn.touchstart),it.map.off("touchend",bn.touchend),it.container.removeEventListener("mouseout",bn.mouseout),it.options.keybindings&&(it.container.removeEventListener("keydown",bn.keydown),it.container.removeEventListener("keyup",bn.keyup))},trash:function(Rt){qn.trash(Rt)},combineFeatures:function(){qn.combineFeatures()},uncombineFeatures:function(){qn.uncombineFeatures()},getMode:function(){return cn}}}(O),O.ui=function(it){var Qt={},on=null,_n={mode:null,feature:null,mouse:null},bn={mode:null,feature:null,mouse:null};function cn(Rt){bn=rt(bn,Rt)}function qn(){var Rt,An;if(it.container){var Fr=[],Br=[];Tt.forEach(function(zr){bn[zr]!==_n[zr]&&(Fr.push(zr+"-"+_n[zr]),bn[zr]!==null&&Br.push(zr+"-"+bn[zr]))}),Fr.length>0&&(Rt=it.container.classList).remove.apply(Rt,Fr),Br.length>0&&(An=it.container.classList).add.apply(An,Br),_n=rt(_n,bn)}}function vi(Rt,An){An===void 0&&(An={});var Fr=document.createElement("button");return Fr.className=T.CONTROL_BUTTON+" "+An.className,Fr.setAttribute("title",An.title),An.container.appendChild(Fr),Fr.addEventListener("click",function(Br){if(Br.preventDefault(),Br.stopPropagation(),Br.target===on)return Zn(),void An.onDeactivate();Pr(Rt),An.onActivate()},!0),Fr}function Zn(){on&&(on.classList.remove(T.ACTIVE_BUTTON),on=null)}function Pr(Rt){Zn();var An=Qt[Rt];An&&An&&Rt!=="trash"&&(An.classList.add(T.ACTIVE_BUTTON),on=An)}return{setActiveButton:Pr,queueMapClasses:cn,updateMapClasses:qn,clearMapClasses:function(){cn({mode:null,feature:null,mouse:null}),qn()},addButtons:function(){var Rt=it.options.controls,An=document.createElement("div");return An.className=T.CONTROL_GROUP+" "+T.CONTROL_BASE,Rt&&(Rt[P.LINE]&&(Qt[P.LINE]=vi(P.LINE,{container:An,className:T.CONTROL_BUTTON_LINE,title:"LineString tool "+(it.options.keybindings?"(l)":""),onActivate:function(){return it.events.changeMode(B.DRAW_LINE_STRING)},onDeactivate:function(){return it.events.trash()}})),Rt[P.POLYGON]&&(Qt[P.POLYGON]=vi(P.POLYGON,{container:An,className:T.CONTROL_BUTTON_POLYGON,title:"Polygon tool "+(it.options.keybindings?"(p)":""),onActivate:function(){return it.events.changeMode(B.DRAW_POLYGON)},onDeactivate:function(){return it.events.trash()}})),Rt[P.POINT]&&(Qt[P.POINT]=vi(P.POINT,{container:An,className:T.CONTROL_BUTTON_POINT,title:"Marker tool "+(it.options.keybindings?"(m)":""),onActivate:function(){return it.events.changeMode(B.DRAW_POINT)},onDeactivate:function(){return it.events.trash()}})),Rt.trash&&(Qt.trash=vi("trash",{container:An,className:T.CONTROL_BUTTON_TRASH,title:"Delete",onActivate:function(){it.events.trash()}})),Rt.combine_features&&(Qt.combine_features=vi("combineFeatures",{container:An,className:T.CONTROL_BUTTON_COMB
1432INE_FEATURES,title:"Combine",onActivate:function(){it.events.combineFeatures()}})),Rt.uncombine_features&&(Qt.uncombine_features=vi("uncombineFeatures",{container:An,className:T.CONTROL_BUTTON_UNCOMBINE_FEATURES,title:"Uncombine",onActivate:function(){it.events.uncombineFeatures()}}))),An},removeButtons:function(){Object.keys(Qt).forEach(function(Rt){var An=Qt[Rt];An.parentNode&&An.parentNode.removeChild(An),delete Qt[Rt]})}}}(O),O.container=Ve.getContainer(),O.store=new mt(O),G=O.ui.addButtons(),O.options.boxSelect&&(O.boxZoomInitial=Ve.boxZoom.isEnabled(),Ve.boxZoom.disable(),Ve.dragPan.disable(),Ve.dragPan.enable()),Ve.loaded()?Re.connect():(Ve.on("load",Re.connect),he=setInterval(function(){Ve.loaded()&&Re.connect()},16)),O.events.start(),G},addLayers:function(){O.map.addSource(C.COLD,{data:{type:D.FEATURE_COLLECTION,features:[]},type:"geojson"}),O.map.addSource(C.HOT,{data:{type:D.FEATURE_COLLECTION,features:[]},type:"geojson"}),O.options.styles.forEach(function(Ve){O.map.addLayer(Ve)}),O.store.setDirty(!0),O.store.render()},removeLayers:function(){O.options.styles.forEach(function(Ve){O.map.getLayer(Ve.id)&&O.map.removeLayer(Ve.id)}),O.map.getSource(C.COLD)&&O.map.removeSource(C.COLD),O.map.getSource(C.HOT)&&O.map.removeSource(C.HOT)}};return O.setup=Re,Re}var qt=[{id:"gl-draw-polygon-fill-inactive",type:"fill",filter:["all",["==","active","false"],["==","$type","Polygon"],["!=","mode","static"]],paint:{"fill-color":"#3bb2d0","fill-outline-color":"#3bb2d0","fill-opacity":.1}},{id:"gl-draw-polygon-fill-active",type:"fill",filter:["all",["==","active","true"],["==","$type","Polygon"]],paint:{"fill-color":"#fbb03b","fill-outline-color":"#fbb03b","fill-opacity":.1}},{id:"gl-draw-polygon-midpoint",type:"circle",filter:["all",["==","$type","Point"],["==","meta","midpoint"]],paint:{"circle-radius":3,"circle-color":"#fbb03b"}},{id:"gl-draw-polygon-stroke-inactive",type:"line",filter:["all",["==","active","false"],["==","$type","Polygon"],["!=","mode","static"]],layout:{"line-cap":"round","line-join":"round"},paint:{"line-color":"#3bb2d0","line-width":2}},{id:"gl-draw-polygon-stroke-active",type:"line",filter:["all",["==","active","true"],["==","$type","Polygon"]],layout:{"line-cap":"round","line-join":"round"},paint:{"line-color":"#fbb03b","line-dasharray":[.2,2],"line-width":2}},{id:"gl-draw-line-inactive",type:"line",filter:["all",["==","active","false"],["==","$type","LineString"],["!=","mode","static"]],layout:{"line-cap":"round","line-join":"round"},paint:{"line-color":"#3bb2d0","line-width":2}},{id:"gl-draw-line-active",type:"line",filter:["all",["==","$type","LineString"],["==","active","true"]],layout:{"line-cap":"round","line-join":"round"},paint:{"line-color":"#fbb03b","line-dasharray":[.2,2],"line-width":2}},{id:"gl-draw-polygon-and-line-vertex-stroke-inactive",type:"circle",filter:["all",["==","meta","vertex"],["==","$type","Point"],["!=","mode","static"]],paint:{"circle-radius":5,"circle-color":"#fff"}},{id:"gl-draw-polygon-and-line-vertex-inactive",type:"circle",filter:["all",["==","meta","vertex"],["==","$type","Point"],["!=","mode","static"]],paint:{"circle-radius":3,"circle-color":"#fbb03b"}},{id:"gl-draw-point-point-stroke-inactive",type:"circle",filter:["all",["==","active","false"],["==","$type","Point"],["==","meta","feature"],["!=","mode","static"]],paint:{"circle-radius":5,"circle-opacity":1,"circle-color":"#fff"}},{id:"gl-draw-point-inactive",type:"circle",filter:["all",["==","active","false"],["==","$type","Point"],["==","meta","feature"],["!=","mode","static"]],paint:{"circle-radius":3,"circle-color":"#3bb2d0"}},{id:"gl-draw-point-stroke-active",type:"circle",filter:["all",["==","$type","Point"],["==","active","true"],["!=","meta","midpoint"]],paint:{"circle-radius":7,"circle-color":"#fff"}},{id:"gl-draw-point-active",type:"circle",filter:["all",["==","$type","Point"],["!=","meta","midpoint"],["==","active","true"]],paint:{"circle-radius":5,"circle-color":"#fbb03b"}},{id:"gl-draw-polygon-fill-static",type:"fill",filter:["all",["==","mode","static"],["==","$type","Polygon"]],paint:{"fill-color":"#404040","fill-outline-color":"#404040","fill-opacity":.1}},{id:"gl-draw-polygon-stroke-static",type:"line",filter:["all",["==","mode","static"],["==","$type","Polygon"]],layout:{"line-cap":"round","line-join":"round"},paint:{"line-color":"#404040","line-width":2}},{id:"gl-draw-line-static",type:"line",filter:["all",["==","mode","static"],["==","$type","LineString"]],layout:{"line-cap":"round","line-join":"round"},paint:{"line-color":"#404040","line-width":2}},{id:"gl-draw-point-static",type:"circle",filter:["all",["==","mode","static"],["==","$type","Point"]],paint:{"circle-radius":5,"circle-color":"#404040"}}];function nt(O){return function(G){var he=G.featureTarget;return!!he&&!!he.properties&&he.properties.meta===O}}function It(O){return!!O.originalEvent&&!!O.originalEvent.shiftKey&&O.originalEvent.button===0}function $t(O){return!!O.featureTarget&&!!O.featureTarget.properties&&O.featureTarget.properties.active===U.ACTIVE&&O.featureTarget.properties.meta===j.FEATURE}function $e(O){return!!O.featureTarget&&!!O.featureTarget.properties&&O.featureTarget.properties.active===U.INACTIVE&&O.featureTarget.properties.meta===j.FEATURE}function pt(O){return O.featureTarget===void 0}function gn(O){return!!O.featureTarget&&!!O.featureTarget.properties&&O.featureTarget.properties.meta===j.FEATURE}function Pn(O){var G=O.featureTarget;return!!G&&!!G.properties&&G.properties.meta===j.VERTEX}function gr(O){return!!O.originalEvent&&O.originalEvent.shiftKey===!0}function Ji(O){return O.keyCode===27}function Ni(O){return O.keyCode===13}var Bo=Object.freeze({__proto__:null,isOfMetaType:nt,isShiftMousedown:It,isActiveFeature:$t,isInactiveFeature:$e,noTarget:pt,isFeature:gn,isVertex:Pn,isShiftDown:gr,isEscapeKey:Ji,isEnterKey:Ni,isTrue:function(){return!0}}),_i=Wr;function Wr(O,G){this.x=O,this.y=G}Wr.prototype={clone:function(){return new Wr(this.x,this.y)},add:function(O){return this.clone()._add(O)},sub:function(O){return this.clone()._sub(O)},multByPoint:function(O){return this.clone()._multByPoint(O)},divByPoint:function(O){return this.clone()._divByPoint(O)},mult:function(O){return this.clone()._mult(O)},div:function(O){return this.clone()._div(O)},rotate:function(O){return this.clone()._rotate(O)}
1432,rotateAround:function(O,G){return this.clone()._rotateAround(O,G)},matMult:function(O){return this.clone()._matMult(O)},unit:function(){return this.clone()._unit()},perp:function(){return this.clone()._perp()},round:function(){return this.clone()._round()},mag:function(){return Math.sqrt(this.x*this.x+this.y*this.y)},equals:function(O){return this.x===O.x&&this.y===O.y},dist:function(O){return Math.sqrt(this.distSqr(O))},distSqr:function(O){var G=O.x-this.x,he=O.y-this.y;return G*G+he*he},angle:function(){return Math.atan2(this.y,this.x)},angleTo:function(O){return Math.atan2(this.y-O.y,this.x-O.x)},angleWith:function(O){return this.angleWithSep(O.x,O.y)},angleWithSep:function(O,G){return Math.atan2(this.x*G-this.y*O,this.x*O+this.y*G)},_matMult:function(O){var G=O[0]*this.x+O[1]*this.y,he=O[2]*this.x+O[3]*this.y;return this.x=G,this.y=he,this},_add:function(O){return this.x+=O.x,this.y+=O.y,this},_sub:function(O){return this.x-=O.x,this.y-=O.y,this},_mult:function(O){return this.x*=O,this.y*=O,this},_div:function(O){return this.x/=O,this.y/=O,this},_multByPoint:function(O){return this.x*=O.x,this.y*=O.y,this},_divByPoint:function(O){return this.x/=O.x,this.y/=O.y,this},_unit:function(){return this._div(this.mag()),this},_perp:function(){var O=this.y;return this.y=this.x,this.x=-O,this},_rotate:function(O){var G=Math.cos(O),he=Math.sin(O),Re=G*this.x-he*this.y,Ve=he*this.x+G*this.y;return this.x=Re,this.y=Ve,this},_rotateAround:function(O,G){var he=Math.cos(O),Re=Math.sin(O),Ve=G.x+he*(this.x-G.x)-Re*(this.y-G.y),Qe=G.y+Re*(this.x-G.x)+he*(this.y-G.y);return this.x=Ve,this.y=Qe,this},_round:function(){return this.x=Math.round(this.x),this.y=Math.round(this.y),this}},Wr.convert=function(O){return O instanceof Wr?O:Array.isArray(O)?new Wr(O[0],O[1]):O};var Ao=r(_i);function xs(O,G){var he=G.getBoundingClientRect();return new Ao(O.clientX-he.left-(G.clientLeft||0),O.clientY-he.top-(G.clientTop||0))}function Fe(O,G,he,Re){return{type:D.FEATURE,properties:{meta:j.VERTEX,parent:O,coord_path:he,active:Re?U.ACTIVE:U.INACTIVE},geometry:{type:D.POINT,coordinates:G}}}function ae(O,G,he){var Re=G.geometry.coordinates,Ve=he.geometry.coordinates;if(Re[1]>85||Re[1]<Q||Ve[1]>85||Ve[1]<Q)return null;var Qe={lng:(Re[0]+Ve[0])/2,lat:(Re[1]+Ve[1])/2};return{type:D.FEATURE,properties:{meta:j.MIDPOINT,parent:O,lng:Qe.lng,lat:Qe.lat,coord_path:he.properties.coord_path},geometry:{type:D.POINT,coordinates:[Qe.lng,Qe.lat]}}}function ue(O,G,he){G===void 0&&(G={}),he===void 0&&(he=null);var Re,Ve=O.geometry,Qe=Ve.type,it=Ve.coordinates,Qt=O.properties&&O.properties.id,on=[];function _n(cn,qn){var vi="",Zn=null;cn.forEach(function(Pr,Rt){var An=qn!=null?qn+"."+Rt:String(Rt),Fr=Fe(Qt,Pr,An,bn(An));if(G.midpoints&&Zn){var Br=ae(Qt,Zn,Fr);Br&&on.push(Br)}Zn=Fr;var zr=JSON.stringify(Pr);vi!==zr&&on.push(Fr),Rt===0&&(vi=zr)})}function bn(cn){return!!G.selectedPaths&&G.selectedPaths.indexOf(cn)!==-1}return Qe===D.POINT?on.push(Fe(Qt,it,he,bn(he))):Qe===D.POLYGON?it.forEach(function(cn,qn){_n(cn,he!==null?he+"."+qn:String(qn))}):Qe===D.LINE_STRING?_n(it,he):Qe.indexOf(D.MULTI_PREFIX)===0&&(Re=Qe.replace(D.MULTI_PREFIX,""),it.forEach(function(cn,qn){var vi={type:D.FEATURE,properties:O.properties,geometry:{type:Re,coordinates:cn}};on=on.concat(ue(vi,G,qn))})),on}var De={enable:function(O){setTimeout(function(){O.map&&O.map.doubleClickZoom&&O._ctx&&O._ctx.store&&O._ctx.store.getInitialConfigValue&&O._ctx.store.getInitialConfigValue("doubleClickZoom")&&O.map.doubleClickZoom.enable()},0)},disable:function(O){setTimeout(function(){O.map&&O.map.doubleClickZoom&&O.map.doubleClickZoom.disable()},0)}},qe={exports:{}},Xe=function(O){if(!O||!O.type)return null;var G=ht[O.type];if(!G)return null;if(G==="geometry")return{type:"FeatureCollection",features:[{type:"Feature",properties:{},geometry:O}]};if(G==="feature")return{type:"FeatureCollection",features:[O]};if(G==="featurecollection")return O},ht={Point:"geometry",MultiPoint:"geometry",LineString:"geometry",MultiLineString:"geometry",Polygon:"geometry",MultiPolygon:"geometry",GeometryCollection:"geometry",Feature:"feature",FeatureCollection:"featurecollection"},ut=r(Xe),Ke=Object.freeze({__proto__:null,default:function O(G){switch(G&&G.type||null){case"FeatureCollection":return G.features=G.features.reduce(function(he,Re){return he.concat(O(Re))},[]),G;case"Feature":return G.geometry?O(G.geometry).map(function(he){var Re={type:"Feature",properties:JSON.parse(JSON.stringify(G.properties)),geometry:he};return G.id!==void 0&&(Re.id=G.id),Re}):[G];case"MultiPoint":return G.coordinates.map(function(he){return{type:"Point",coordinates:he}}
1432);case"MultiPolygon":return G.coordinates.map(function(he){return{type:"Polygon",coordinates:he}});case"MultiLineString":return G.coordinates.map(function(he){return{type:"LineString",coordinates:he}});case"GeometryCollection":return G.geometries.map(O).reduce(function(he,Re){return he.concat(Re)},[]);case"Point":case"Polygon":case"LineString":return[G]}}}),Et=Xe,en=i(Ke),ln=function(O){return function G(he){return Array.isArray(he)&&he.length&&typeof he[0]=="number"?[he]:he.reduce(function(Re,Ve){return Array.isArray(Ve)&&Array.isArray(Ve[0])?Re.concat(G(Ve)):(Re.push(Ve),Re)},[])}(O)};en instanceof Function||(en=en.default);var Kt={exports:{}},Xn=Kt.exports=function(O){return new jn(O)};function jn(O){this.value=O}function Yn(O,G,he){var Re=[],Ve=[],Qe=!0;return function it(Qt){var on=he?or(Qt):Qt,_n={},bn=!0,cn={node:on,node_:Qt,path:[].concat(Re),parent:Ve[Ve.length-1],parents:Ve,key:Re.slice(-1)[0],isRoot:Re.length===0,level:Re.length,circular:null,update:function(Zn,Pr){cn.isRoot||(cn.parent.node[cn.key]=Zn),cn.node=Zn,Pr&&(bn=!1)},delete:function(Zn){delete cn.parent.node[cn.key],Zn&&(bn=!1)},remove:function(Zn){Wi(cn.parent.node)?cn.parent.node.splice(cn.key,1):delete cn.parent.node[cn.key],Zn&&(bn=!1)},keys:null,before:function(Zn){_n.before=Zn},after:function(Zn){_n.after=Zn},pre:function(Zn){_n.pre=Zn},post:function(Zn){_n.post=Zn},stop:function(){Qe=!1},block:function(){bn=!1}};if(!Qe)return cn;function qn(){if(typeof cn.node=="object"&&cn.node!==null){cn.keys&&cn.node_===cn.node||(cn.keys=lr(cn.node)),cn.isLeaf=cn.keys.length==0;for(var Zn=0;Zn<Ve.length;Zn++)if(Ve[Zn].node_===Qt){cn.circular=Ve[Zn];break}}else cn.isLeaf=!0,cn.keys=null;cn.notLeaf=!cn.isLeaf,cn.notRoot=!cn.isRoot}qn();var vi=G.call(cn,cn.node);return vi!==void 0&&cn.update&&cn.update(vi),_n.before&&_n.before.call(cn,cn.node),bn&&(typeof cn.node!="object"||cn.node===null||cn.circular||(Ve.push(cn),qn(),po(cn.keys,function(Zn,Pr){Re.push(Zn),_n.pre&&_n.pre.call(cn,cn.node[Zn],Zn);var Rt=it(cn.node[Zn]);he&&$i.call(cn.node,Zn)&&(cn.node[Zn]=Rt.node),Rt.isLast=Pr==cn.keys.length-1,Rt.isFirst=Pr==0,_n.post&&_n.post.call(cn,Rt),Re.pop()}),Ve.pop()),_n.after&&_n.after.call(cn,cn.node)),cn}(O).node}function or(O){if(typeof O=="object"&&O!==null){var G;if(Wi(O))G=[];else if(Gr(O)==="[object Date]")G=new Date(O.getTime?O.getTime():O);else if(function(Ve){return Gr(Ve)==="[object RegExp]"}(O))G=new RegExp(O);else if(function(Ve){return Gr(Ve)==="[object Error]"}(O))G={message:O.message};else if(function(Ve){return Gr(Ve)==="[object Boolean]"}(O))G=new Boolean(O);else if(function(Ve){return Gr(Ve)==="[object Number]"}
1432(O))G=new Number(O);else if(function(Ve){return Gr(Ve)==="[object String]"}(O))G=new String(O);else if(Object.create&&Object.getPrototypeOf)G=Object.create(Object.getPrototypeOf(O));else if(O.constructor===Object)G={};else{var he=O.constructor&&O.constructor.prototype||O.__proto__||{},Re=function(){};Re.prototype=he,G=new Re}return po(lr(O),function(Ve){G[Ve]=O[Ve]}),G}return O}jn.prototype.get=function(O){for(var G=this.value,he=0;he<O.length;he++){var Re=O[he];if(!G||!$i.call(G,Re)){G=void 0;break}G=G[Re]}return G},jn.prototype.has=function(O){for(var G=this.value,he=0;he<O.length;he++){var Re=O[he];if(!G||!$i.call(G,Re))return!1;G=G[Re]}return!0},jn.prototype.set=function(O,G){for(var he=this.value,Re=0;Re<O.length-1;Re++){var Ve=O[Re];$i.call(he,Ve)||(he[Ve]={}),he=he[Ve]}return he[O[Re]]=G,G},jn.prototype.map=function(O){return Yn(this.value,O,!0)},jn.prototype.forEach=function(O){return this.value=Yn(this.value,O,!1),this.value},jn.prototype.reduce=function(O,G){var he=arguments.length===1,Re=he?this.value:G;return this.forEach(function(Ve){this.isRoot&&he||(Re=O.call(this,Re,Ve))}),Re},jn.prototype.paths=function(){var O=[];return this.forEach(function(G){O.push(this.path)}),O},jn.prototype.nodes=function(){var O=[];return this.forEach(function(G){O.push(this.node)}),O},jn.prototype.clone=function(){var O=[],G=[];return function he(Re){for(var Ve=0;Ve<O.length;Ve++)if(O[Ve]===Re)return G[Ve];if(typeof Re=="object"&&Re!==null){var Qe=or(Re);return O.push(Re),G.push(Qe),po(lr(Re),function(it){Qe[it]=he(Re[it])}),O.pop(),G.pop(),Qe}return Re}(this.value)};var lr=Object.keys||function(O){var G=[];for(var he in O)G.push(he);return G};function Gr(O){return Object.prototype.toString.call(O)}var Wi=Array.isArray||function(O){return Object.prototype.toString.call(O)==="[object Array]"},po=function(O,G){if(O.forEach)return O.forEach(G);for(var he=0;he<O.length;he++)G(O[he],he,O)};po(lr(jn.prototype),function(O){Xn[O]=function(G){var he=[].slice.call(arguments,1),Re=new jn(G);return Re[O].apply(Re,he)}});var $i=Object.hasOwnProperty||function(O,G){return G in O},ws=Kt.exports,Po=Hr;function Hr(O){if(!(this instanceof Hr))return new Hr(O);this._bbox=O||[1/0,1/0,-1/0,-1/0],this._valid=!!O}Hr.prototype.include=function(O){return this._valid=!0,this._bbox[0]=Math.min(this._bbox[0],O[0]),this._bbox[1]=Math.min(this._bbox[1],O[1]),this._bbox[2]=Math.max(this._bbox[2],O[0]),this._bbox[3]=Math.max(this._bbox[3],O[1]),this},Hr.prototype.equals=function(O){var G;return G=O instanceof Hr?O.bbox():O,this._bbox[0]==G[0]&&this._bbox[1]==G[1]&&this._bbox[2]==G[2]&&this._bbox[3]==G[3]},Hr.prototype.center=function(O){return this._valid?[(this._bbox[0]+this._bbox[2])/2,(this._bbox[1]+this._bbox[3])/2]:null},Hr.prototype.union=function(O){var G;return this._valid=!0,G=O instanceof Hr?O.bbox():O,this._bbox[0]=Math.min(this._bbox[0],G[0]),this._bbox[1]=Math.min(this._bbox[1],G[1]),this._bbox[2]=Math.max(this._bbox[2],G[2]),this._bbox[3]=Math.max(this._bbox[3],G[3]),this},Hr.prototype.bbox=function(){return this._valid?this._bbox:null},Hr.prototype.contains=function(O){if(!O)return this._fastContains();if(!this._valid)return null;var G=O[0],he=O[1];return this._bbox[0]<=G&&this._bbox[1]<=he&&this._bbox[2]>=G&&this._bbox[3]>=he},Hr.prototype.intersect=function(O){return this._valid?(G=O instanceof Hr?O.bbox():O,!(this._bbox[0]>G[2]||this._bbox[2]<G[0]||this._bbox[3]<G[1]||this._bbox[1]>G[3])):null;var G},Hr.prototype._fastContains=function(){if(!this._valid)return new Function("return null;");var O="return "+this._bbox[0]+"<= ll[0] &&"+this._bbox[1]+"<= ll[1] &&"+this._bbox[2]+">= ll[0] &&"+this._bbox[3]+">= ll[1]";return new Function("ll",O)},Hr.prototype.polygon=function(){return this._valid?{type:"Polygon",coordinates:[[[this._bbox[0],this._bbox[1]],[this._bbox[2],this._bbox[1]],[this._bbox[2],this._bbox[3]],[this._bbox[0],this._bbox[3]],[this._bbox[0],this._bbox[1]]]]}:null};var Lc=function(O){if(!O)return[];var G=en(Et(O)),he=[];return G.features.forEach(function(Re){Re.geometry&&(he=he.concat(ln(Re.geometry.coordinates)))}),he},Ig=ws,Cp=Po,Er={features:["FeatureCollection"],coordinates:["Point","MultiPoint","LineString","MultiLineString","Polygon","MultiPolygon"],geometry:["Feature"],geometries:["GeometryCollection"]},Ud=Object.keys(Er);function Jl(O){for(var G=Cp(),he=Lc(O),Re=0;Re<he.length;Re++)G.include(he[Re]);return G}qe.exports=function(O){return Jl(O).bbox()},qe.exports.polygon=function(O){return Jl(O).polygon()},qe.exports.bboxify=function(O){return Ig(O).map(function(G){G&&Ud.some(function(he){return!!G[he]&&Er[he].indexOf(G.type)!==-1})&&(G.bbox=Jl(G).bbox(),this.update(G))})};var Vd=r(qe.exports),ec=-90;function $a(O,G){var he=ec,Re=90,Ve=ec,Qe=90,it=270,Qt=-270;O.forEach(function(_n){var bn=Vd(_n),cn=bn[1],qn=bn[3],vi=bn[0],Zn=bn[2];cn>he&&(he=cn),qn<Re&&(Re=qn),qn>Ve&&(Ve=qn),cn<Qe&&(Qe=cn),vi<it&&(it=vi),Zn>Qt&&(Qt=Zn)});var on=G;return he+on.lat>85&&(on.lat=85-he),Ve+on.lat>90&&(on.lat=90-Ve),Re+on.lat<-85&&(on.lat=-85-Re),Qe+on.lat<ec&&(on.lat=ec-Qe),it+on.lng<=-270&&(on.lng+=360*Math.ceil(Math.abs(on.lng)/360)),Qt+on.lng>=270&&(on.lng-=360*Math.ceil(Math.abs(on.lng)/360)),on}function is(O,G){var he=$a(O.map(function(Re){return Re.toGeoJSON()}),G);O.forEach(function(Re){var Ve,Qe=Re.getCoordinates(),it=function(on){var _n={lng:on[0]+he.lng,lat:on[1]+he.lat};return[_n.lng,_n.lat]},Qt=function(on){return on.map(function(_n){return it(_n)})};Re.type===D.POINT?Ve=it(Qe):Re.type===D.LINE_STRING||Re.type===D.MULTI_POINT?Ve=Qe.map(it):Re.type===D.POLYGON||Re.type===D.MULTI_LINE_STRING?Ve=Qe.map(Qt):Re.type===D.MULTI_POLYGON&&(Ve=Qe.map(function(on){return on.map(function(_n){return Qt(_n)})})),Re.incomingCoords(Ve)})}var eo={onSetup:function(O){var G=this,he={dragMoveLocation:null,boxSelectStartLocation:null,boxSelectElement:void 0,boxSelecting:!1,canBoxSelect:!1,dragMoving:!1,canDragMove:!1,initiallySelectedFeatureIds:O.featureIds||[]};return this.setSelected(he.initiallySelectedFeatureIds.filter(function(Re){return G.getFeature(Re)!==void 0})),this.fireActionable(),this.setActionableState({combineFeatures:!0,uncombineFeatures:!0,trash:!0}),he},fireUpdate:function(){this.map.fire(R.UPDATE,{action:N.MOVE,features:this.getSelected().map(function(O){return O.toGeoJSON()})})}
1432,fireActionable:function(){var O=this,G=this.getSelected(),he=G.filter(function(Qt){return O.isInstanceOf("MultiFeature",Qt)}),Re=!1;if(G.length>1){Re=!0;var Ve=G[0].type.replace("Multi","");G.forEach(function(Qt){Qt.type.replace("Multi","")!==Ve&&(Re=!1)})}var Qe=he.length>0,it=G.length>0;this.setActionableState({combineFeatures:Re,uncombineFeatures:Qe,trash:it})},getUniqueIds:function(O){return O.length?O.map(function(G){return G.properties.id}).filter(function(G){return G!==void 0}).reduce(function(G,he){return G.add(he),G},new ce).values():[]},stopExtendedInteractions:function(O){O.boxSelectElement&&(O.boxSelectElement.parentNode&&O.boxSelectElement.parentNode.removeChild(O.boxSelectElement),O.boxSelectElement=null),this.map.dragPan.enable(),O.boxSelecting=!1,O.canBoxSelect=!1,O.dragMoving=!1,O.canDragMove=!1},onStop:function(){De.enable(this)},onMouseMove:function(O,G){return gn(G)&&O.dragMoving&&this.fireUpdate(),this.stopExtendedInteractions(O),!0},onMouseOut:function(O){return!O.dragMoving||this.fireUpdate()}};eo.onTap=eo.onClick=function(O,G){return pt(G)?this.clickAnywhere(O,G):nt(j.VERTEX)(G)?this.clickOnVertex(O,G):gn(G)?this.clickOnFeature(O,G):void 0},eo.clickAnywhere=function(O){var G=this,he=this.getSelectedIds();he.length&&(this.clearSelectedFeatures(),he.forEach(function(Re){return G.doRender(Re)})),De.enable(this),this.stopExtendedInteractions(O)},eo.clickOnVertex=function(O,G){this.changeMode(B.DIRECT_SELECT,{featureId:G.featureTarget.properties.parent,coordPath:G.featureTarget.properties.coord_path,startPos:G.lngLat}),this.updateUIClasses({mouse:A.MOVE})},eo.startOnActiveFeature=function(O,G){this.stopExtendedInteractions(O),this.map.dragPan.disable(),this.doRender(G.featureTarget.properties.id),O.canDragMove=!0,O.dragMoveLocation=G.lngLat},eo.clickOnFeature=function(O,G){var he=this;De.disable(this),this.stopExtendedInteractions(O);var Re=gr(G),Ve=this.getSelectedIds(),Qe=G.featureTarget.properties.id,it=this.isSelected(Qe);if(!Re&&it&&this.getFeature(Qe).type!==D.POINT)return this.changeMode(B.DIRECT_SELECT,{featureId:Qe});it&&Re?(this.deselect(Qe),this.updateUIClasses({mouse:A.POINTER}),Ve.length===1&&De.enable(this)):!it&&Re?(this.select(Qe),this.updateUIClasses({mouse:A.MOVE})):it||Re||(Ve.forEach(function(Qt){return he.doRender(Qt)}),this.setSelected(Qe),this.updateUIClasses({mouse:A.MOVE})),this.doRender(Qe)},eo.onMouseDown=function(O,G){return $t(G)?this.startOnActiveFeature
1432(O,G):this.drawConfig.boxSelect&&It(G)?this.startBoxSelect(O,G):void 0},eo.startBoxSelect=function(O,G){this.stopExtendedInteractions(O),this.map.dragPan.disable(),O.boxSelectStartLocation=xs(G.originalEvent,this.map.getContainer()),O.canBoxSelect=!0},eo.onTouchStart=function(O,G){if($t(G))return this.startOnActiveFeature(O,G)},eo.onDrag=function(O,G){return O.canDragMove?this.dragMove(O,G):this.drawConfig.boxSelect&&O.canBoxSelect?this.whileBoxSelect(O,G):void 0},eo.whileBoxSelect=function(O,G){O.boxSelecting=!0,this.updateUIClasses({mouse:A.ADD}),O.boxSelectElement||(O.boxSelectElement=document.createElement("div"),O.boxSelectElement.classList.add(T.BOX_SELECT),this.map.getContainer().appendChild(O.boxSelectElement));var he=xs(G.originalEvent,this.map.getContainer()),Re=Math.min(O.boxSelectStartLocation.x,he.x),Ve=Math.max(O.boxSelectStartLocation.x,he.x),Qe=Math.min(O.boxSelectStartLocation.y,he.y),it=Math.max(O.boxSelectStartLocation.y,he.y),Qt="translate("+Re+"px, "+Qe+"px)";O.boxSelectElement.style.transform=Qt,O.boxSelectElement.style.WebkitTransform=Qt,O.boxSelectElement.style.width=Ve-Re+"px",O.boxSelectElement.style.height=it-Qe+"px"},eo.dragMove=function(O,G){O.dragMoving=!0,G.originalEvent.stopPropagation();var he={lng:G.lngLat.lng-O.dragMoveLocation.lng,lat:G.lngLat.lat-O.dragMoveLocation.lat};is(this.getSelected(),he),O.dragMoveLocation=G.lngLat},eo.onTouchEnd=eo.onMouseUp=function(O,G){var he=this;if(O.dragMoving)this.fireUpdate();else if(O.boxSelecting){var Re=[O.boxSelectStartLocation,xs(G.originalEvent,this.map.getContainer())],Ve=this.featuresAt(null,Re,"click"),Qe=this.getUniqueIds(Ve).filter(function(it){return!he.isSelected(it)});Qe.length&&(this.select(Qe),Qe.forEach(function(it){return he.doRender(it)}),this.updateUIClasses({mouse:A.MOVE}))}this.stopExtendedInteractions(O)},eo.toDisplayFeatures=function(O,G,he){G.properties.active=this.isSelected(G.properties.id)?U.ACTIVE:U.INACTIVE,he(G),this.fireActionable(),G.properties.active===U.ACTIVE&&G.geometry.type!==D.POINT&&ue(G).forEach(he)},eo.onTrash=function(){this.deleteFeature(this.getSelectedIds()),this.fireActionable()},eo.onCombineFeatures=function(){var O=this.getSelected();if(!(O.length===0||O.length<2)){for(var G=[],he=[],Re=O[0].type.replace("Multi",""),Ve=0;Ve<O.length;Ve++){var Qe=O[Ve];if(Qe.type.replace("Multi","")!==Re)return;
1432Qe.type.includes("Multi")?Qe.getCoordinates().forEach(function(Qt){G.push(Qt)}):G.push(Qe.getCoordinates()),he.push(Qe.toGeoJSON())}if(he.length>1){var it=this.newFeature({type:D.FEATURE,properties:he[0].properties,geometry:{type:"Multi"+Re,coordinates:G}});this.addFeature(it),this.deleteFeature(this.getSelectedIds(),{silent:!0}),this.setSelected([it.id]),this.map.fire(R.COMBINE_FEATURES,{createdFeatures:[it.toGeoJSON()],deletedFeatures:he})}this.fireActionable()}},eo.onUncombineFeatures=function(){var O=this,G=this.getSelected();if(G.length!==0){for(var he=[],Re=[],Ve=function(it){var Qt=G[it];O.isInstanceOf("MultiFeature",Qt)&&(Qt.getFeatures().forEach(function(on){O.addFeature(on),on.properties=Qt.properties,he.push(on.toGeoJSON()),O.select([on.id])}),O.deleteFeature(Qt.id,{silent:!0}),Re.push(Qt.toGeoJSON()))},Qe=0;Qe<G.length;Qe++)Ve(Qe);he.length>1&&this.map.fire(R.UNCOMBINE_FEATURES,{createdFeatures:he,deletedFeatures:Re}),this.fireActionable()}};var hh=nt(j.VERTEX),vl=nt(j.MIDPOINT),Wo={fireUpdate:function(){this.map.fire(R.UPDATE,{action:N.CHANGE_COORDINATES,features:this.getSelected().map(function(O){return O.toGeoJSON()})})},fireActionable:function(O){this.setActionableState({combineFeatures:!1,uncombineFeatures:!1,trash:O.selectedCoordPaths.length>0})},startDragging:function(O,G){this.map.dragPan.disable(),O.canDragMove=!0,O.dragMoveLocation=G.lngLat},stopDragging:function(O){this.map.dragPan.enable(),O.dragMoving=!1,O.canDragMove=!1,O.dragMoveLocation=null},onVertex:function(O,G){this.startDragging(O,G);var he=G.featureTarget.properties,Re=O.selectedCoordPaths.indexOf(he.coord_path);gr(G)||Re!==-1?gr(G)&&Re===-1&&O.selectedCoordPaths.push(he.coord_path):O.selectedCoordPaths=[he.coord_path];var Ve=this.pathsToCoordinates(O.featureId,O.selectedCoordPaths);this.setSelectedCoordinates(Ve)},onMidpoint:function(O,G){this.startDragging(O,G);var he=G.featureTarget.properties;O.feature.addCoordinate(he.coord_path,he.lng,he.lat),this.fireUpdate(),O.selectedCoordPaths=[he.coord_path]},pathsToCoordinates:function(O,G){return G.map(function(he){return{feature_id:O,coord_path:he}})},onFeature:function(O,G){O.selectedCoordPaths.length===0?this.startDragging(O,G):this.stopDragging(O)},dragFeature:function(O,G,he){is(this.getSelected(),he),O.dragMoveLocation=G.lngLat},dragVertex:function(O,G,he){for(var Re=O.selectedCoordPaths.map(function(Qt){return O.feature.getCoordinate(Qt)}),Ve=$a(Re.map(function(Qt){return{type:D.FEATURE,properties:{},geometry:{type:D.POINT,coordinates:Qt}}}),he),Qe=0;Qe<Re.length;Qe++){var it=Re[Qe];O.feature.updateCoordinate(O.selectedCoordPaths[Qe],it[0]+Ve.lng,it[1]+Ve.lat)}},clickNoTarget:function(){this.changeMode(B.SIMPLE_SELECT)},clickInactive:function(){this.changeMode(B.SIMPLE_SELECT)},clickActiveFeature:function(O){O.selectedCoordPaths=[],this.clearSelectedCoordinates(),O.feature.changed()},onSetup:function(O){var G=O.featureId,he=this.getFeature(G);if(!he)throw new Error("You must provide a featureId to enter direct_select mode");if(he.type===D.POINT)throw new TypeError("direct_select mode doesn't handle point features");var Re={featureId:G,feature:he,dragMoveLocation:O.startPos||null,dragMoving:!1,canDragMove:!1,selectedCoordPaths:O.coordPath?[O.coordPath]:[]};return this.setSelectedCoordinates(this.pathsToCoordinates(G,Re.selectedCoordPaths)),this.setSelected(G),De.disable(this),this.setActionableState({trash:!0}),Re},onStop:function(){De.enable(this),this.clearSelectedCoordinates()},toDisplayFeatures:function(O,G,he){O.featureId===G.properties.id?(G.properties.active=U.ACTIVE,he(G),ue(G,{map:this.map,midpoints:!0,selectedPaths:O.selectedCoordPaths}).forEach(he)):(G.properties.active=U.INACTIVE,he(G)),this.fireActionable(O)},onTrash:function(O){O.selectedCoordPaths.sort(function(G,he){return he.localeCompare(G,"en",{numeric:!0})}).forEach(function(G){return O.feature.removeCoordinate(G)}),this.fireUpdate(),O.selectedCoordPaths=[],this.clearSelectedCoordinates(),this.fireActionable(O),O.feature.isValid()===!1&&(this.deleteFeature([O.featureId]),this.changeMode(B.SIMPLE_SELECT,{}))},onMouseMove:function(O,G){var he=$t(G),Re=hh(G),Ve=vl(G),Qe=O.selectedCoordPaths.length===0;return he&&Qe||Re&&!Qe?this.updateUIClasses({mouse:A.MOVE}
1432):this.updateUIClasses({mouse:A.NONE}),(Re||he||Ve)&&O.dragMoving&&this.fireUpdate(),this.stopDragging(O),!0},onMouseOut:function(O){return O.dragMoving&&this.fireUpdate(),!0}};Wo.onTouchStart=Wo.onMouseDown=function(O,G){return hh(G)?this.onVertex(O,G):$t(G)?this.onFeature(O,G):vl(G)?this.onMidpoint(O,G):void 0},Wo.onDrag=function(O,G){if(O.canDragMove===!0){O.dragMoving=!0,G.originalEvent.stopPropagation();var he={lng:G.lngLat.lng-O.dragMoveLocation.lng,lat:G.lngLat.lat-O.dragMoveLocation.lat};O.selectedCoordPaths.length>0?this.dragVertex(O,G,he):this.dragFeature(O,G,he),O.dragMoveLocation=G.lngLat}},Wo.onClick=function(O,G){return pt(G)?this.clickNoTarget(O,G):$t(G)?this.clickActiveFeature(O,G):$e(G)?this.clickInactive(O,G):void this.stopDragging(O)},Wo.onTap=function(O,G){return pt(G)?this.clickNoTarget(O,G):$t(G)?this.clickActiveFeature(O,G):$e(G)?this.clickInactive(O,G):void 0},Wo.onTouchEnd=Wo.onMouseUp=function(O){O.dragMoving&&this.fireUpdate(),this.stopDragging(O)};var fa={};function Pt(O,G){return!!O.lngLat&&O.lngLat.lng===G[0]&&O.lngLat.lat===G[1]}fa.onSetup=function(){var O=this.newFeature({type:D.FEATURE,properties:{},geometry:{type:D.POINT,coordinates:[]}});return this.addFeature(O),this.clearSelectedFeatures(),this.updateUIClasses({mouse:A.ADD}),this.activateUIButton(P.POINT),this.setActionableState({trash:!0}),{point:O}},fa.stopDrawingAndRemove=function(O){this.deleteFeature([O.point.id],{silent:!0}),this.changeMode(B.SIMPLE_SELECT)},fa.onTap=fa.onClick=function(O,G){this.updateUIClasses({mouse:A.MOVE}),O.point.updateCoordinate("",G.lngLat.lng,G.lngLat.lat),this.map.fire(R.CREATE,{features:[O.point.toGeoJSON()]}),this.changeMode(B.SIMPLE_SELECT,{featureIds:[O.point.id]})},fa.onStop=function(O){this.activateUIButton(),O.point.getCoordinate().length||this.deleteFeature([O.point.id],{silent:!0})},fa.toDisplayFeatures=function(O,G,he){var Re=G.properties.id===O.point.id;if(G.properties.active=Re?U.ACTIVE:U.INACTIVE,!Re)return he(G)},fa.onTrash=fa.stopDrawingAndRemove,fa.onKeyUp=function(O,G){if(Ji(G)||Ni(G))return this.stopDrawingAndRemove(O,G)};var ta={onSetup:function(){var O=this.newFeature({type:D.FEATURE,properties:{},geometry:{type:D.POLYGON,coordinates:[[]]}});return this.addFeature(O),this.clearSelectedFeatures(),De.disable(this),this.updateUIClasses({mouse:A.ADD}),this.activateUIButton(P.POLYGON),this.setActionableState({trash:!0}),{polygon:O,currentVertexPosition:0}},clickAnywhere:function(O,G){if(O.currentVertexPosition>0&&Pt(G,O.polygon.coordinates[0][O.currentVertexPosition-1]))return this.changeMode(B.SIMPLE_SELECT,{featureIds:[O.polygon.id]});this.updateUIClasses({mouse:A.ADD}),O.polygon.updateCoordinate("0."+O.currentVertexPosition,G.lngLat.lng,G.lngLat.lat),O.currentVertexPosition++,O.polygon.updateCoordinate("0."+O.currentVertexPosition,G.lngLat.lng,G.lngLat.lat)},clickOnVertex:function(O){return this.changeMode(B.SIMPLE_SELECT,{featureIds:[O.polygon.id]})},onMouseMove:function(O,G){O.polygon.updateCoordinate("0."+O.currentVertexPosition,G.lngLat.lng,G.lngLat.lat),Pn(G)&&this.updateUIClasses({mouse:A.POINTER})}};ta.onTap=ta.onClick=function(O,G){return Pn(G)?this.clickOnVertex(O,G):this.clickAnywhere(O,G)},ta.onKeyUp=function(O,G){Ji(G)?(this.deleteFeature([O.polygon.id],{silent:!0}),this.changeMode(B.SIMPLE_SELECT)):Ni(G)&&this.changeMode(B.SIMPLE_SELECT,{featureIds:[O.polygon.id]})},ta.onStop=function(O){this.updateUIClasses({mouse:A.NONE}),De.enable(this),this.activateUIButton(),this.getFeature(O.polygon.id)!==void 0&&(O.polygon.removeCoordinate("0."+O.currentVertexPosition),O.polygon.isValid()?this.map.fire(R.CREATE,{features:[O.polygon.toGeoJSON()]}):(this.deleteFeature([O.polygon.id],{silent:!0}),this.changeMode(B.SIMPLE_SELECT,{},{silent:!0})))},ta.toDisplayFeatures=function(O,G,he){var Re=G.properties.id===O.polygon.id;if(G.properties.active=Re?U.ACTIVE:U.INACTIVE,!Re)return he(G);if(G.geometry.coordinates.length!==0){var Ve=G.geometry.coordinates[0].length;if(!(Ve<3)){if(G.properties.meta=j.FEATURE,he(Fe(O.polygon.id,G.geometry.coordinates[0][0],"0.0",!1)),Ve>3){var Qe=G.geometry.coordinates[0].length-3;he(Fe(O.polygon.id,G.geometry.coordinates[0][Qe],"0."+Qe,!1))}if(Ve<=4){var it=[[G.geometry.coordinates[0][0][0],G.geometry.coordinates[0][0][1]],[G.geometry.coordinates[0][1][0],G.geometry.coordinates[0][1][1]]];if(he({type:D.FEATURE,properties:G.properties,geometry:{coordinates:it,type:D.LINE_STRING}}),Ve===3)return}return he(G)}}}
1432,ta.onTrash=function(O){this.deleteFeature([O.polygon.id],{silent:!0}),this.changeMode(B.SIMPLE_SELECT)};var ci={onSetup:function(O){var G,he,Re=(O=O||{}).featureId,Ve="forward";if(Re){if(!(G=this.getFeature(Re)))throw new Error("Could not find a feature with the provided featureId");var Qe=O.from;if(Qe&&Qe.type==="Feature"&&Qe.geometry&&Qe.geometry.type==="Point"&&(Qe=Qe.geometry),Qe&&Qe.type==="Point"&&Qe.coordinates&&Qe.coordinates.length===2&&(Qe=Qe.coordinates),!Qe||!Array.isArray(Qe))throw new Error("Please use the `from` property to indicate which point to continue the line from");var it=G.coordinates.length-1;if(G.coordinates[it][0]===Qe[0]&&G.coordinates[it][1]===Qe[1])he=it+1,G.addCoordinate.apply(G,[he].concat(G.coordinates[it]));else{if(G.coordinates[0][0]!==Qe[0]||G.coordinates[0][1]!==Qe[1])throw new Error("`from` should match the point at either the start or the end of the provided LineString");Ve="backwards",he=0,G.addCoordinate.apply(G,[he].concat(G.coordinates[0]))}}else G=this.newFeature({type:D.FEATURE,properties:{},geometry:{type:D.LINE_STRING,coordinates:[]}}),he=0,this.addFeature(G);return this.clearSelectedFeatures(),De.disable(this),this.updateUIClasses({mouse:A.ADD}),this.activateUIButton(P.LINE),this.setActionableState({trash:!0}),{line:G,currentVertexPosition:he,direction:Ve}},clickAnywhere:function(O,G){if(O.currentVertexPosition>0&&Pt(G,O.line.coordinates[O.currentVertexPosition-1])||O.direction==="backwards"&&Pt(G,O.line.coordinates[O.currentVertexPosition+1]))return this.changeMode(B.SIMPLE_SELECT,{featureIds:[O.line.id]});this.updateUIClasses({mouse:A.ADD}),O.line.updateCoordinate(O.currentVertexPosition,G.lngLat.lng,G.lngLat.lat),O.direction==="forward"?(O.currentVertexPosition++,O.line.updateCoordinate(O.currentVertexPosition,G.lngLat.lng,G.lngLat.lat)):O.line.addCoordinate(0,G.lngLat.lng,G.lngLat.lat)},clickOnVertex:function(O){return this.changeMode(B.SIMPLE_SELECT,{featureIds:[O.line.id]})},onMouseMove:function(O,G){O.line.updateCoordinate(O.currentVertexPosition,G.lngLat.lng,G.lngLat.lat),Pn(G)&&this.updateUIClasses({mouse:A.POINTER})}};ci.onTap=ci.onClick=function(O,G){if(Pn(G))return this.clickOnVertex(O,G);this.clickAnywhere(O,G)},ci.onKeyUp=function(O,G){Ni(G)?this.changeMode(B.SIMPLE_SELECT,{featureIds:[O.line.id]}):Ji(G)&&(this.deleteFeature([O.line.id],{silent:!0}),this.changeMode(B.SIMPLE_SELECT))},ci.onStop=function(O){De.enable(this),this.activateUIButton(),this.getFeature(O.line.id)!==void 0&&(O.line.removeCoordinate(""+O.currentVertexPosition),O.line.isValid()?this.map.fire(R.CREATE,{features:[O.line.toGeoJSON()]}):(this.deleteFeature([O.line.id],{silent:!0}),this.changeMode(B.SIMPLE_SELECT,{},{silent:!0})))},ci.onTrash=function(O){this.deleteFeature([O.line.id],{silent:!0}),this.changeMode(B.SIMPLE_SELECT)},ci.toDisplayFeatures=function(O,G,he){var Re=G.properties.id===O.line.id;if(G.properties.active=Re?U.ACTIVE:U.INACTIVE,!Re)return he(G);G.geometry.coordinates.length<2||(G.properties.meta=j.FEATURE,he(Fe(O.line.id,G.geometry.coordinates[O.direction==="forward"?G.geometry.coordinates.length-2:1],""+(O.direction==="forward"?G.geometry.coordinates.length-2:1),!1)),he(G))};var mo={simple_select:eo,direct_select:Wo,draw_point:fa,draw_polygon:ta,draw_line_string:ci},kp={defaultMode:B.SIMPLE_SELECT,keybindings:!0,touchEnabled:!0,clickBuffer:2,touchBuffer:25,boxSelect:!0,displayControlsDefault:!0,styles:qt,modes:mo,controls:{},userProperties:!1},Ts={point:!0,line_string:!0,polygon:!0,trash:!0,combine_features:!0,uncombine_features:!0},Gd={point:!1,line_string:!1,polygon:!1,trash:!1,combine_features:!1,uncombine_features:!1};function qd(O,G){return O.map(function(he){return he.source?he:rt(he,{id:he.id+"."+G,source:G==="hot"?C.HOT:C.COLD})})}var bl={exports:{}};(function(O,G){var he="__lodash_hash_undefined__",Re=9007199254740991,Ve="[object Arguments]",Qe="[object Array]",it="[object Boolean]",Qt="[object Date]",on="[object Error]",_n="[object Function]",bn="[object Map]",cn="[object Number]",qn="[object Object]",vi="[object Promise]",Zn="[object RegExp]",Pr="[object Set]",Rt="[object String]",An="[object Symbol]",Fr="[object WeakMap]",Br="[object ArrayBuffer]",zr="[object DataView]",dh=/^\[object .+?Constructor\]$/,xu=/^(?:0|[1-9]\d*)$/,Kn={};
1432Kn["[object Float32Array]"]=Kn["[object Float64Array]"]=Kn["[object Int8Array]"]=Kn["[object Int16Array]"]=Kn["[object Int32Array]"]=Kn["[object Uint8Array]"]=Kn["[object Uint8ClampedArray]"]=Kn["[object Uint16Array]"]=Kn["[object Uint32Array]"]=!0,Kn[Ve]=Kn[Qe]=Kn[Br]=Kn[it]=Kn[zr]=Kn[Qt]=Kn[on]=Kn[_n]=Kn[bn]=Kn[cn]=Kn[qn]=Kn[Zn]=Kn[Pr]=Kn[Rt]=Kn[Fr]=!1;var Rc=typeof oo=="object"&&oo&&oo.Object===Object&&oo,Wd=typeof self=="object"&&self&&self.Object===Object&&self,na=Rc||Wd||Function("return this")(),Mo=G&&!G.nodeType&&G,fh=Mo&&O&&!O.nodeType&&O,ph=fh&&fh.exports===Mo,as=ph&&Rc.process,Ws=function(){try{return as&&as.binding&&as.binding("util")}catch{}}(),wu=Ws&&Ws.isTypedArray;function Og(at,Ot){for(var yn=-1,Fn=at==null?0:at.length;++yn<Fn;)if(Ot(at[yn],yn,at))return!0;return!1}function Hd(at){var Ot=-1,yn=Array(at.size);return at.forEach(function(Fn,wi){yn[++Ot]=[wi,Fn]}),yn}function Fc(at){var Ot=-1,yn=Array(at.size);return at.forEach(function(Fn){yn[++Ot]=Fn}),yn}var ss,mh,xl,Hs=Array.prototype,Tu=Function.prototype,ja=Object.prototype,Bc=na["__core-js_shared__"],tc=Tu.toString,pa=ja.hasOwnProperty,Yd=(ss=/[^.]+$/.exec(Bc&&Bc.keys&&Bc.keys.IE_PROTO||""))?"Symbol(src)_1."+ss:"",Eu=ja.toString,Zd=RegExp("^"+tc.call(pa).replace(/[\\^$.*+?()[\]{}|]/g,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),gh=ph?na.Buffer:void 0,Ys=na.Symbol,Sr=na.Uint8Array,Ap=ja.propertyIsEnumerable,Xd=Hs.splice,wl=Ys?Ys.toStringTag:void 0,yh=Object.getOwnPropertySymbols,Pp=gh?gh.isBuffer:void 0,Kd=(mh=Object.keys,xl=Object,function(at){return mh(xl(at))}),Tl=rc(na,"DataView"),El=rc(na,"Map"),Sl=rc(na,"Promise"),ls=rc(na,"Set"),Zs=rc(na,"WeakMap"),Cl=rc(Object,"create"),Mp=Ks(Tl),Su=Ks(El),Qd=Ks(Sl),Jd=Ks(ls),_h=Ks(Zs),Cu=Ys?Ys.prototype:void 0,ku=Cu?Cu.valueOf:void 0;function ur(at){var Ot=-1,yn=at==null?0:at.length;for(this.clear();++Ot<yn;){var Fn=at[Ot];this.set(Fn[0],Fn[1])}}function Pa(at){var Ot=-1,yn=at==null?0:at.length;for(this.clear();++Ot<yn;){var Fn=at[Ot];this.set(Fn[0],Fn[1])}}function kl(at){var Ot=-1,yn=at==null?0:at.length;for(this.clear();++Ot<yn;){var Fn=at[Ot];this.set(Fn[0],Fn[1])}}function zc(at){var Ot=-1,yn=at==null?0:at.length;for(this.__data__=new kl;++Ot<yn;)this.add(at[Ot])}function Xs(at){var Ot=this.__data__=new Pa(at);this.size=Ot.size}function nc(at,Ot){var yn=Ma(at),Fn=!yn&&nf(at),wi=!yn&&!Fn&&Uc(at),xr=!yn&&!Fn&&!wi&&Dp(at),ji=yn||Fn||wi||xr,Pi=ji?function(lo,ra){for(var Qs=-1,ia=Array(lo);++Qs<lo;)ia[Qs]=ra(Qs);return ia}(at.length,String):[],Va=Pi.length;for(var Hi in at)!Ot&&!pa.call(at,Hi)||ji&&(Hi=="length"||wi&&(Hi=="offset"||Hi=="parent")||xr&&(Hi=="buffer"||Hi=="byteLength"||Hi=="byteOffset")||$c(Hi,Va))||Pi.push(Hi);return Pi}function Nc(at,Ot){for(var yn=at.length;yn--;)if(jc(at[yn][0],Ot))return yn;return-1}function Au(at){return at==null?at===void 0?"[object Undefined]":"[object Null]":wl&&wl in Object(at)?function(Ot){var yn=pa.call(Ot,wl),Fn=Ot[wl];try{Ot[wl]=void 0;var wi=!0}catch{}var xr=Eu.call(Ot);return wi&&(yn?Ot[wl]=Fn:delete Ot[wl]),xr}(at):function(Ot){return Eu.call(Ot)}(at)}function Ip(at){return ic(at)&&Au(at)==Ve}function Op(at,Ot,yn,Fn,wi){return at===Ot||(at==null||Ot==null||!ic(at)&&!ic(Ot)?at!=at&&Ot!=Ot:function(xr,ji,Pi,Va,Hi,lo){var ra=Ma(xr),Qs=Ma(ji),ia=ra?Qe:Ua(xr),Js=Qs?Qe:Ua(ji),Vc=(ia=ia==Ve?qn:ia)==qn,xh=(Js=Js==Ve?qn:Js)==qn,oc=ia==Js;if(oc&&Uc(xr)){if(!Uc(ji))return!1;ra=!0,Vc=!1}if(oc&&!Vc)return lo||(lo=new Xs),ra||Dp(xr)?vh(xr,ji,Pi,Va,Hi,lo):function(Cr,Lr,oa,Ga,wh,Io,ma){switch(oa){case zr:if(Cr.byteLength!=Lr.byteLength||Cr.byteOffset!=Lr.byteOffset)return!1;Cr=Cr.buffer,Lr=Lr.buffer;case Br:return!(Cr.byteLength!=Lr.byteLength||!Io(new Sr(Cr),new Sr(Lr)));case it:case Qt:case cn:return jc(+Cr,+Lr);case on:return Cr.name==Lr.name&&Cr.message==Lr.message;case Zn:case Rt:return Cr==Lr+"";case bn:var cs=Hd;case Pr:var Pl=1&Ga;if(cs||(cs=Fc),Cr.size!=Lr.size&&!Pl)return!1;var _r=ma.get(Cr);if(_r)return _r==Lr;Ga|=2,ma.set(Cr,Lr);var Es=vh(cs(Cr),cs(Lr),Ga,wh,Io,ma);return ma.delete(Cr),Es;case An:if(ku)return ku.call(Cr)==ku.call(Lr)}return!1}(xr,ji,ia,Pi,Va,Hi,lo);if(!(1&Pi)){var Al=Vc&&pa.call(xr,"__wrapped__"),ac=xh&&pa.call(ji,"__wrapped__");
1432if(Al||ac){var Lp=Al?xr.value():xr,Rp=ac?ji.value():ji;return lo||(lo=new Xs),Hi(Lp,Rp,Pi,Va,lo)}}return oc?(lo||(lo=new Xs),function(Cr,Lr,oa,Ga,wh,Io){var ma=1&oa,cs=Pu(Cr),Pl=cs.length,_r=Pu(Lr).length;if(Pl!=_r&&!ma)return!1;for(var Es=Pl;Es--;){var Ml=cs[Es];if(!(ma?Ml in Lr:pa.call(Lr,Ml)))return!1}var Ou=Io.get(Cr);if(Ou&&Io.get(Lr))return Ou==Lr;var el=!0;Io.set(Cr,Lr),Io.set(Lr,Cr);for(var Th=ma;++Es<Pl;){var sc=Cr[Ml=cs[Es]],qa=Lr[Ml];if(Ga)var af=ma?Ga(qa,sc,Ml,Lr,Cr,Io):Ga(sc,qa,Ml,Cr,Lr,Io);if(!(af===void 0?sc===qa||wh(sc,qa,oa,Ga,Io):af)){el=!1;break}Th||(Th=Ml=="constructor")}if(el&&!Th){var lc=Cr.constructor,tl=Lr.constructor;lc==tl||!("constructor"in Cr)||!("constructor"in Lr)||typeof lc=="function"&&lc instanceof lc&&typeof tl=="function"&&tl instanceof tl||(el=!1)}return Io.delete(Cr),Io.delete(Lr),el}(xr,ji,Pi,Va,Hi,lo)):!1}(at,Ot,yn,Fn,Op,wi))}function ef(at){return!(!rf(at)||function(Ot){return!!Yd&&Yd in Ot}(at))&&(bh(at)?Zd:dh).test(Ks(at))}function tf(at){if(yn=(Ot=at)&&Ot.constructor,Fn=typeof yn=="function"&&yn.prototype||ja,Ot!==Fn)return Kd(at);var Ot,yn,Fn,wi=[];for(var xr in Object(at))pa.call(at,xr)&&xr!="constructor"&&wi.push(xr);return wi}function vh(at,Ot,yn,Fn,wi,xr){var ji=1&yn,Pi=at.length,Va=Ot.length;if(Pi!=Va&&!(ji&&Va>Pi))return!1;var Hi=xr.get(at);if(Hi&&xr.get(Ot))return Hi==Ot;var lo=-1,ra=!0,Qs=2&yn?new zc:void 0;for(xr.set(at,Ot),xr.set(Ot,at);++lo<Pi;){var ia=at[lo],Js=Ot[lo];if(Fn)var Vc=ji?Fn(Js,ia,lo,Ot,at,xr):Fn(ia,Js,lo,at,Ot,xr);if(Vc!==void 0){if(Vc)continue;ra=!1;break}if(Qs){if(!Og(Ot,function(xh,oc){if(Al=oc,!Qs.has(Al)&&(ia===xh||wi(ia,xh,yn,Fn,xr)))return Qs.push(oc);var Al})){ra=!1;break}}else if(ia!==Js&&!wi(ia,Js,yn,Fn,xr)){ra=!1;break}}return xr.delete(at),xr.delete(Ot),ra}function Pu(at){return function(Ot,yn,Fn){var wi=yn(Ot);return Ma(Ot)?wi:function(xr,ji){for(var Pi=-1,Va=ji.length,Hi=xr.length;++Pi<Va;)xr[Hi+Pi]=ji[Pi];return xr}(wi,Fn(Ot))}(at,of,Dg)}function Mu(at,Ot){var yn,Fn,wi=at.__data__;return((Fn=typeof(yn=Ot))=="string"||Fn=="number"||Fn=="symbol"||Fn=="boolean"?yn!=="__proto__":yn===null)?wi[typeof Ot=="string"?"string":"hash"]:wi.map}function rc(at,Ot){var yn=function(Fn,wi){return Fn==null?void 0:Fn[wi]}(at,Ot);return ef(yn)?yn:void 0}ur.prototype.clear=function(){this.__data__=Cl?Cl(null):{},this.size=0},ur.prototype.delete=function(at){var Ot=this.has(at)&&delete this.__data__[at];return this.size-=Ot?1:0,Ot},ur.prototype.get=function(at){var Ot=this.__data__;if(Cl){var yn=Ot[at];return yn===he?void 0:yn}return pa.call(Ot,at)?Ot[at]:void 0},ur.prototype.has=function(at){var Ot=this.__data__;return Cl?Ot[at]!==void 0:pa.call(Ot,at)},ur.prototype.set=function(at,Ot){var yn=this.__data__;return this.size+=this.has(at)?0:1,yn[at]=Cl&&Ot===void 0?he:Ot,this},Pa.prototype.clear=function(){this.__data__=[],this.size=0},Pa.prototype.delete=function(at){var Ot=this.__data__,yn=Nc(Ot,at);return!(yn<0)&&(yn==Ot.length-1?Ot.pop():Xd.call(Ot,yn,1),--this.size,!0)},Pa.prototype.get=function(at){var Ot=this.__data__,yn=Nc(Ot,at);return yn<0?void 0:Ot[yn][1]},Pa.prototype.has=function(at){return Nc(this.__data__,at)>-1},Pa.prototype.set=function(at,Ot){var yn=this.__data__,Fn=Nc(yn,at);return Fn<0?(++this.size,yn.push([at,Ot])):yn[Fn][1]=Ot,this},kl.prototype.clear=function(){this.size=0,this.__data__={hash:new ur,map:new(El||Pa),string:new ur}},kl.prototype.delete=function(at){var Ot=Mu(this,at).delete(at);return this.size-=Ot?1:0,Ot},kl.prototype.get=function(at){return Mu(this,at).get(at)},kl.prototype.has=function(at){return Mu(this,at).has(at)},kl.prototype.set=function(at,Ot){var yn=Mu(this,at),Fn=yn.size;return yn.set(at,Ot),this.size+=yn.size==Fn?0:1,this},zc.prototype.add=zc.prototype.push=function(at){return this.__data__.set(at,he),this},zc.prototype.has=function(at){return this.__data__.has(at)},Xs.prototype.clear=function(){this.__data__=new Pa,this.size=0},Xs.prototype.delete=function(at){var Ot=this.__data__,yn=Ot.delete(at);return this.size=Ot.size,yn},Xs.prototype.get=function(at){return this.__data__.get(at)},Xs.prototype.has=function(at){return this.__data__.has(at)},Xs.prototype.set=function(at,Ot){var yn=this.__data__;if(yn instanceof Pa){var Fn=yn.__data__;if(!El||Fn.length<199)return Fn.push([at,Ot]),this.size=++yn.size,this;yn=this.__data__=new kl(Fn)}return yn.set(at,Ot),this.size=yn.size,this};var Dg=yh?function(at){return at==null?[]:(at=Object(at),function(Ot,yn){for(var Fn=-1,wi=Ot==null?0:Ot.length,xr=0,ji=[];++Fn<wi;){var Pi=Ot[Fn];yn(Pi,Fn,Ot)&&(ji[xr++]=Pi)}return ji}(yh(at),function(Ot){return Ap.call(at,Ot)}))}:function(){return[]},Ua=Au;function $c(at,Ot){return!!(Ot=Ot??Re)&&(typeof at=="number"||xu.test(at))&&at>-1&&at%1==0&&at<Ot}function Ks(at){if(at!=null){try{return tc.call(at)}catch{}try{return at+""}catch{}}return""}function jc(at,Ot){return at===Ot||at!=at&&Ot!=Ot}(Tl&&Ua(new Tl(new ArrayBuffer(1)))!=zr||El&&Ua(new El)!=bn||Sl&&Ua(Sl.resolve())!=vi||ls&&Ua(new ls)!=Pr||Zs&&Ua(new Zs)!=Fr)&&(Ua=function(at){var Ot=Au(at),yn=Ot==qn?at.constructor:void 0,Fn=yn?Ks(yn):"";if(Fn)switch(Fn){case Mp:return zr;case Su:return bn;case Qd:return vi;case Jd:return Pr;case _h:return Fr}return Ot});var nf=Ip(function(){return arguments}())?Ip:function(at){return ic(at)&&pa.call(at,"callee")&&!Ap.call(at,"callee")},Ma=Array.isArray,Uc=Pp||function(){return!1};function bh(at){if(!rf(at))return!1;var Ot=Au(at);return Ot==_n||Ot=="[object GeneratorFunction]"||Ot=="[object AsyncFunction]"||Ot=="[object Proxy]"}function Iu(at){return typeof at=="number"&&at>-1&&at%1==0&&at<=Re}function rf(at){var Ot=typeof at;return at!=null&&(Ot=="object"||Ot=="function")}function ic(at){return at!=null&&typeof at=="object"}var Dp=wu?function(at){return function(Ot){return at(Ot)}}(wu):function(at){return ic(at)&&Iu(at.length)&&!!Kn[Au(at)]};function of(at){return(Ot=at)!=null&&Iu(Ot.length)&&!bh(Ot)?nc(at):tf(at);var Ot}O.exports=function(at,Ot){return Op(at,Ot)}})(bl,bl.exports);var dn=r(bl.exports);function fr(O,G){return O.length===G.length&&JSON.stringify(O.map(function(he){return he}).sort())===JSON.stringify(G.map(function(he){return he}).sort())}var cr={Polygon:Ue,LineString:wt,Point:kt,MultiPolygon:tt,MultiLineString:tt,MultiPoint:tt},Aa=Object.freeze({__proto__:null,CommonSelectors:Bo,constrainFeatureMovement:$a,createMidPoint:ae,createSupplementaryPoints:ue,createVertex:Fe,doubleClickZoom:De,euclideanDistance:oe,featuresAt:ie,getFeatureAtAndSetCursors:Te,isClick:ne,isEventAtCoordinates:Pt,isTap:le,mapEventToBoundingBox:ge,ModeHandler:n,moveFeatures:is,sortFeatures:me,stringSetsAreEqual:fr,StringSet:ce,theme:qt,toDenseArray:Je}),os=function(O,G){var he={options:O=function(Ve){Ve===void 0&&(Ve={});var Qe=rt(Ve);return Ve.controls||(Qe.controls={}
1432),Ve.displayControlsDefault===!1?Qe.controls=rt(Gd,Ve.controls):Qe.controls=rt(Ts,Ve.controls),(Qe=rt(kp,Qe)).styles=qd(Qe.styles,"cold").concat(qd(Qe.styles,"hot")),Qe}(O)};G=function(Ve,Qe){return Qe.modes=B,Qe.getFeatureIdsAt=function(it){return ie.click({point:it},null,Ve).map(function(Qt){return Qt.properties.id})},Qe.getSelectedIds=function(){return Ve.store.getSelectedIds()},Qe.getSelected=function(){return{type:D.FEATURE_COLLECTION,features:Ve.store.getSelectedIds().map(function(it){return Ve.store.get(it)}).map(function(it){return it.toGeoJSON()})}},Qe.getSelectedPoints=function(){return{type:D.FEATURE_COLLECTION,features:Ve.store.getSelectedCoordinates().map(function(it){return{type:D.FEATURE,properties:{},geometry:{type:D.POINT,coordinates:it.coordinates}}})}},Qe.set=function(it){if(it.type===void 0||it.type!==D.FEATURE_COLLECTION||!Array.isArray(it.features))throw new Error("Invalid FeatureCollection");var Qt=Ve.store.createRenderBatch(),on=Ve.store.getAllIds().slice(),_n=Qe.add(it),bn=new ce(_n);return(on=on.filter(function(cn){return!bn.has(cn)})).length&&Qe.delete(on),Qt(),_n},Qe.add=function(it){var Qt=JSON.parse(JSON.stringify(ut(it))).features.map(function(on){if(on.id=on.id||Se(),on.geometry===null)throw new Error("Invalid geometry: null");if(Ve.store.get(on.id)===void 0||Ve.store.get(on.id).type!==on.geometry.type){var _n=cr[on.geometry.type];if(_n===void 0)throw new Error("Invalid geometry type: "+on.geometry.type+".");var bn=new _n(Ve,on);Ve.store.add(bn)}else{var cn=Ve.store.get(on.id);cn.properties=on.properties,dn(cn.properties,on.properties)||Ve.store.featureChanged(cn.id),dn(cn.getCoordinates(),on.geometry.coordinates)||cn.incomingCoords(on.geometry.coordinates)}return on.id});return Ve.store.render(),Qt},Qe.get=function(it){var Qt=Ve.store.get(it);if(Qt)return Qt.toGeoJSON()},Qe.getAll=function(){return{type:D.FEATURE_COLLECTION,features:Ve.store.getAll().map(function(it){return it.toGeoJSON()})}},Qe.delete=function(it){return Ve.store.delete(it,{silent:!0}),Qe.getMode()!==B.DIRECT_SELECT||Ve.store.getSelectedIds().length?Ve.store.render():Ve.events.changeMode(B.SIMPLE_SELECT,void 0,{silent:!0}),Qe},Qe.deleteAll=function(){return Ve.store.delete(Ve.store.getAllIds(),{silent:!0}),Qe.getMode()===B.DIRECT_SELECT?Ve.events.changeMode(B.SIMPLE_SELECT,void 0,{silent:!0}):Ve.store.render(),Qe},Qe.changeMode=function(it,Qt){return Qt===void 0&&(Qt={}),it===B.SIMPLE_SELECT&&Qe.getMode()===B.SIMPLE_SELECT?(fr(Qt.featureIds||[],Ve.store.getSelectedIds())||
1432(Ve.store.setSelected(Qt.featureIds,{silent:!0}),Ve.store.render()),Qe):(it===B.DIRECT_SELECT&&Qe.getMode()===B.DIRECT_SELECT&&Qt.featureId===Ve.store.getSelectedIds()[0]||Ve.events.changeMode(it,Qt,{silent:!0}),Qe)},Qe.getMode=function(){return Ve.events.getMode()},Qe.trash=function(){return Ve.events.trash({silent:!0}),Qe},Qe.combineFeatures=function(){return Ve.events.combineFeatures({silent:!0}),Qe},Qe.uncombineFeatures=function(){return Ve.events.uncombineFeatures({silent:!0}),Qe},Qe.setFeatureProperty=function(it,Qt,on){return Ve.store.setFeatureProperty(it,Qt,on),Qe},Qe}(he,G),he.api=G;var Re=pn(he);return G.onAdd=Re.onAdd,G.onRemove=Re.onRemove,G.types=P,G.options=O,G};function tr(O){os(O,this)}return tr.modes=mo,tr.constants=Z,tr.lib=Aa,tr})})(l4);var cse=l4.exports;const use=Rd(cse);function Dn(e,t,n,r){function i(s){return s instanceof n?s:new n(function(c){c(s)})}return new(n||(n=Promise))(function(s,c){function a(x){try{g(r.next(x))}catch(T){c(T)}}function m(x){try{g(r.throw(x))}catch(T){c(T)}}function g(x){x.done?s(x.value):i(x.value).then(a,m)}g((r=r.apply(e,t||[])).next())})}const c4=e=>e&&e.outerHTML!=="<div></div>",Vo=(e,t,n=[void 0])=>{const r={},i=t||Object.keys(e);for(const s of i)n.some(c=>c===e[s])||(r[s]=e[s]);return r},u4=(e,t)=>e.parent?e.parent.type?e.parent.type.name===t:e.parent.vnode.tag?e.parent.vnode.tag.endsWith(t):!1:!1,hse=(e,t)=>e.parent?e.parent.type?e.parent.type.name.includes(t):e.parent.vnode.tag?e.parent.vnode.tag.includes(t):!1:!1,R2=(e,t,n)=>{for(const r of n)e.on(r,i=>{t.emit(r,i)})};var dse=()=>navigator.userAgent.toLowerCase().includes("safari")&&!navigator.userAgent.toLocaleLowerCase().includes("chrome");const fse=(e,t,n,r)=>Dn(void 0,void 0,void 0,function*(){const i=e?yield e.promise:null,s=mse(n),c=new ose(s);u4(r,"MapboxMap")&&i?i.addControl(c):(r.parent&&c.addTo(r.refs.geocoder),c4(r.refs["custom-input"])&&gse(r.refs["custom-input"],c,r)),t.resolve(c)}),pse=(e,t)=>Dn(void 0,void 0,void 0,function*(){const n=yield e.promise;n.on("result",r=>{t.emit("result",r.result),t.proxy.geocoderState.result=r.result}),n.on("results",r=>{t.emit("results",r),t.proxy.geocoderState.results=r}),n.on("error",r=>{t.emit("error",r),t.proxy.geocoderState.error=r}),n.on("loading",r=>{t.emit("loading",r),t.proxy.geocoderState.loading=r}),n.on("clear",()=>{t.emit("clear")})}),mse=e=>{const t=Vo(e);return t.accessToken=e.accessToken||_u.accessToken,t.mapboxgl=_u,t},gse=(e,t,n)=>{if(n&&n.proxy){n.proxy.showOriginalGeocoder&&(n.proxy.showOriginalGeocoder=!1);const r=e.getElementsByTagName("input");if(!r)throw new Error("MapboxGeocoderControl: No inputs found");const i=r[0];i.addEventListener("keyup",s=>{t.query(i.value),dse()&&(setTimeout(()=>{i.focus()},100),setTimeout(()=>{i.focus()},200))})}};var h4=sr({name:"MapboxGeocoderControl",props:{accessToken:{type:String,default:""},origin:{type:String},zoom:{type:Number},flyTo:{type:[Boolean,Object],default:()=>{}},placeholder:{type:String},proximity:{type:Object},trackProximity:{type:Boolean,default:()=>{}},collapsed:{type:Boolean,default:()=>{}},clearAndBlurOnEsc:{type:Boolean,default:()=>{}},clearOnBlur:{type:Boolean,default:()=>{}},bbox:{type:Array},countries:{type:String},types:{type:String},minLength:{type:Number},limit:{type:Number},language:{type:String},filter:{type:Function},localGeocoder:{type:Function},externalGeocoder:{type:Function},reverseGeocode:{type:Boolean,default:()=>{}},enableEventLogging:{type:Boolean,default:()=>{}},marker:{type:Boolean,default:()=>{}},render:{type:Function},getItemValue:{type:Function},mode:{type:String},localGeocoderOnly:{type:Boolean,default:()=>{}}},setup(e){const t=dr("vmb_map",null),n=new Ep,r=jt(!0),i=jt({result:{},results:{},error:null,loading:null});return Dr(()=>Dn(this,void 0,void 0,function*(){const s=ko();s&&(yield fse(t,n,e,s)),s&&(yield pse(n,s))})),Bi(()=>Dn(this,void 0,void 0,function*(){const s=yield n.promise;if(t){const c=yield t.promise;c._removed||c.removeControl(s)}})),Nn(e,()=>Dn(this,void 0,void 0,function*(){})),{showOriginalGeocoder:r,geocoderState:i}}});const yse={ref:"geocoder"},_se={ref:"custom-input"};function vse(e,t,n,r,i,s){return At(),Wt("div",null,[pd(Un("div",yse,null,512),[[gd,e.showOriginalGeocoder]]),Un("div",_se,[En(e.$slots,"input",{result:e.geocoderState.result,results:e.geocoderState.results,error:e.geocoderState.error,loading:e.geocoderState.loading})],512)])}h4.render=vse;var jl=(e,t,n)=>e&&e.value!==void 0?Nn(e,t,n):null;function bse(e,t,n){if(window.ResizeObserver)wse(e,t);else{const r=Tse(e,n);Nn(r,()=>{t.resize()})}}function xse(e,t){t.value&&e.touchZoomRotate.enable(),Nn(t,n=>{n?e.touchZoomRotate.enable():e.touchZoomRotate.disable()})}function wse(e,t){if(!e.value)throw new Error("Could not enable auto-resize because root container could not be found");new window.ResizeObserver(()=>t.resize()).observe(e.value)}function Tse(e,t){const n=ko(),r=so(new DOMRect(0,0,0,0).toJSON());if(n){let i=e.value?e.value.getBoundingClientRect():new DOMRect(0,0,0,0);addEventListener("resize",s=>{setTimeout(()=>{if(e.value){const c=e.value.getBoundingClientRect().toJSON(),a=i.width!==c.width||i.height!==c.height;i=c,a&&Object.assign(r,c)}},t||0)})}return r}const d4=e=>({height:e.height,width:e.width,"--zoom-logo":e.zoomLogo>=.8?e.zoomLogo:1}),Ese=e=>e.includes("/")?e:`mapbox://styles/mapbox/${e}`,Sse=(e,t)=>{const n=Vo(e,["accessToken","antialias","attributionControl","bearing","bearingSnap","boun
1432ds","boxZoom","center","clickTolerance","collectResourceTiming","container","cooperativeGestures","crossSourceCollisions","customAttribution","doubleClickZoom","dragPan","dragRotate","fadeDuration","failIfMajorPerformanceCaveat","fitBoundsOptions","hash","interactive","keyboard","localIdeographFontFamily","logoPosition","maxBounds","maxPitch","maxTileCacheSize","maxZoom","minPitch","minZoom","pitch","pitchWithRotate","preserveDrawingBuffer","projection","refreshExpiredTiles","renderWorldCopies","scrollZoom","touchZoomRotate","trackResize","transformRequest","zoom"]);return n.style=Ese(e.mapStyle),n.container=t,n},Cse=(e,t,n,r)=>(()=>{const i=n.value,s=Sse(e,i),c=new _u.Map(s);c.on("load",()=>{t.resolve(c)}),e.autoResize&&bse(r,c,e.autoResizeDelay),e.touchZoomRotate&&xse(c,Us(e,"touchZoomRotate"))})(),kse=(e,t)=>{t.value=d4(e)};function Ase(e,t,n){return Dn(this,void 0,void 0,function*(){const{cooperativeGestures:r,width:i,height:s,bearing:c,maxBounds:a,maxPitch:m,minZoom:g,maxZoom:x,minPitch:T,pitch:C,projection:A,renderWorldCopies:P,zoom:D,mapStyle:B}=wv(t),{center:R,flyToOptions:N}=n;yield Mse(e,i,s),yield Ise(e,{bearing:c,maxBounds:a,maxPitch:m,minPitch:T,pitch:C,renderWorldCopies:P}),yield Ose(e,{maxZoom:x,center:R,flyToOptions:N,minZoom:g,zoom:D}),yield Pse(e,B),yield Dse(e,A)})}function Pse(e,t){return Dn(this,void 0,void 0,function*(){const n=yield e.promise;Nn(t,r=>n.setStyle(r))})}function Mse(e,t,n){return Dn(this,void 0,void 0,function*(){const r=yield e.promise;Nn(t,()=>r.resize()),Nn(n,()=>r.resize())})}function Ise(e,t){return Dn(this,void 0,void 0,function*(){const n=yield e.promise;jl(t.bearing,r=>n.setBearing(r)),jl(t.maxBounds,r=>n.setMaxBounds(r)),jl(t.maxPitch,r=>n.setMaxPitch(r)),jl(t.minPitch,r=>n.setMinPitch(r)),jl(t.pitch,r=>n.setPitch(r)),jl(t.renderWorldCopies,r=>n.setRenderWorldCopies(r))})}function Ose(e,t){jl(t.center,n=>Hy(e,{center:n}),{deep:!0}),jl(t.flyToOptions,n=>Hy(e,{flyToOptions:n}),{deep:!0}),jl(t.maxZoom,n=>Hy(e,{maxZoom:n})),jl(t.minZoom,n=>
1432Hy(e,{minZoom:n})),jl(t.zoom,n=>Hy(e,{zoom:n}))}function Dse(e,t){return Dn(this,void 0,void 0,function*(){const n=yield e.promise;jl(t,r=>n.setProjection(r))})}function Hy(e,t){return Dn(this,void 0,void 0,function*(){const n=yield e.promise,r=t.flyToOptions?Vo(t.flyToOptions,["curve","maxDuration","minZoom","screenSpeed","speed"]):{};t.center&&(r.center=t.center),t.zoom&&(r.zoom=t.zoom),n.flyTo(r)})}const f4=["boxzoomstart","click","contextmenu","data","dataloading","dblclick","drag","dragend","dragstart","error","idle","load","mousedown","mouseenter","mouseleave","mousemouve","mouseout","mouseover","mouseup","move","moveend","movestart","pitch","pitchend","pitchstart","remove","resize","rotate","rotateend","rotatestart","sourcedata","sourcedataloading","styledata","styledataloading","styleimagemissing","touchcancel","touchend","touchstart","webglcontextlost","webglcontextrestored","wheel","zoom","zoomend","zoomstart"],Lse=[...f4,"update:center","update:flyToOptions","update:zoom","update:pitch","update:bearing","loaded"],Rse=(e,t)=>Dn(void 0,void 0,void 0,function*(){const n=yield e.promise;R2(n,t,f4),t.emit("loaded",n),n.on("zoomend",r=>{t.emit("update:zoom",r.target.getZoom()),t.emit("update:center",r.target.getCenter().toArray())}),n.on("dragend",r=>{t.emit("update:center",r.target.getCenter().toArray())}),n.on("pitchend",r=>{t.emit("update:pitch",r.target.getPitch())}),n.on("rotateend",r=>{t.emit("update:bearing",r.target.getBearing())})}),Fse=e=>{const t=["string","number","boolean"];let n=!1;return e===null&&(n=!0),t.some(r=>typeof e===r)&&(n=!0),n};function qL(e,t="change",n="value"){const r=ko(),i=t instanceof Array?t:[t];if(!r)throw new Error("vmodel: Instance not found");const s=jt(r.props[n]||e);for(const c of i)Nn(s,a=>{r.emit(c,s.value)});return Nn(r.props,()=>{(Fse(r.props[n])?r.props[n]!==s.value:!s4(r.props[n],s.value))&&(s.value=r.props[n])}),s}var F2=sr({name:"MapboxMap",emits:Lse,props:{accessToken:{type:String,required:!0},height:{type:String,default:"100%"},width:{type:String,default:"100%"},container:{type:[Object,String],default:""},minZoom:{type:Number,default:0},maxZoom:{type:Number,default:22},minPitch:{type:Number,default:0},maxPitch:{type:Number,default:60},mapStyle:{type:[Object,String],default:"mapbox://styles/mapbox/streets-v11"},hash:{type:Boolean},interactive:{type:Boolean,default:!0},bearingSnap:{type:Number},pitchWithRotate:{type:Boolean,default:!0},clickTolerance:{type:Number},attributionControl:{type:Boolean,default:!0},customAttribution:{type:Array},logoPosition:{type:String,default:"bottom-left"},failIfMajorPerformanceCaveat:{type:Boolean},preserveDrawingBuffer:{type:Boolean},antialias:{type:Boolean},refreshExpiredTiles:{type:Boolean},maxBounds:{type:[Array,Object]},scrollZoom:{type:[Boolean,Object],default:!0},boxZoom:{type:Boolean},dragRotate:{type:Boolean,default:!0},dragPan:{type:[Object,Boolean],default:!0},keyboard:{type:Boolean},doubleClickZoom:{type:Boolean},touchZoomRotate:{type:[Boolean,Object],default:!0},trackResize:{type:Boolean,default:!0},center:{default:()=>[0,0]},zoom:{type:Number},bearing:{type:Number},pitch:{type:Number},bounds:{type:Array},fitBoundsOptions:{type:Object},renderWorldCopies:{type:Boolean,default:!0},maxTileCacheSize:{type:Number,default:null},localIdeographFontFamily:{type:String,default:"sans-serif"},transformRequest:{type:Function,default:null},collectResourceTiming:{type:Boolean,default:!1},fadeDuration:{type:Number,default:300},crossSourceCollisions:{type:Boolean,default:!0},zoomLogo:{type:Number,default:1},flyToOptions:{default:()=>({})},autoResize:{type:Boolean,default:!1},autoResizeDelay:{type:Number},cooperativeGestures:{type:Boolean,default:!1},projection:{type:String}},setup:e=>{const t=jt(null),n=jt(null),r=new C1;ea("vmb_map",r);const i=qL(e,"update:center","center"),s=qL(e,"update:flyToOptions","flyToOptions"),c=jt(d4(e));return Nn(e,a=>Dn(void 0,void 0,void 0,function*(){kse(a,c)})),Ase(r,e,{center:i,flyToOptions:s}),Dr(()=>Dn(void 0,void 0,void 0,function*(){const a=ko();_u.accessToken=e.accessToken,Cse(e,r,n,t),a&&(yield Rse(r,a))})),Bi(()=>Dn(void 0,void 0,void 0,function*(){(yield r.promise).remove()})),{vmb_map:r,root:t,style:c,i_center:i,i_flyToOptions:s,mapContainer:n}}});const Bse={key:1};function zse(e,t,n,r,i,s){return At(),Wt("div",{style:Sa(e.style),ref:"root",class:"mapbox-map"},[Un("div",null,[En(e.$slots,"default")]),e.vmb_map.isResolved?(At(),Wt("div",{key:0,ref:"mapContainer",class:"map-container",style:Sa({height:e.height,width:e.width})},null,4)):(At(),Wt("div",Bse,[En(e.$slots,"loader",{},()=>[Un("div",{style:Sa(e.style)}
1432,null,4)])]))],4)}function Nse(e,t){t===void 0&&(t={});var n=t.insertAt;if(!(!e||typeof document>"u")){var r=document.head||document.getElementsByTagName("head")[0],i=document.createElement("style");i.type="text/css",n==="top"&&r.firstChild?r.insertBefore(i,r.firstChild):r.appendChild(i),i.styleSheet?i.styleSheet.cssText=e:i.appendChild(document.createTextNode(e))}}var $se=`[data-v-55cc3ed8] .mapboxgl-ctrl-logo {
1433  zoom: var(--zoom-logo);
1434}`;Nse($se);F2.render=zse;F2.__scopeId="data-v-55cc3ed8";var jse={setup(){return{vmb_map:dr("vmb_map",null)}}};const Use=e=>u4(e,"MapboxMarker"),Vse=e=>Vo(e,["element","offset","anchor","color","draggable","clickTolerance","rotation","rotationAlignment","pitchAlignment","scale"]),p4=["drag","dragend","dragstart"],Gse=[...p4,"update:lngLat","click"],qse=(e,t)=>{R2(e,t,p4),e.on("dragend",n=>t.emit("update:lngLat",n.target._lngLat.toArray())),e.getElement().addEventListener("click",n=>t.emit("click",n))},Wse=(e,t)=>Dn(void 0,void 0,void 0,function*(){const n=yield t.promise,r=Vo(e);typeof r.draggable=="boolean"&&n.setDraggable(r.draggable),r.lngLat&&n.setLngLat(r.lngLat),r.offset&&n.setOffset(r.offset),r.rotation&&n.setRotation(r.rotation),r.pitchAlignment&&n.setPitchAlignment(r.pitchAlignment),r.rotationAlignment&&n.setRotationAlignment(r.rotationAlignment)}),Hse=(e,t,n,r,i,s)=>Dn(void 0,void 0,void 0,function*(){const c=yield t.promise;s&&c4(s.value)&&(e.element=s.value);const a=new P2.Marker(e).setLngLat(i);a.addTo(c),n.resolve(a)});var m4=sr({name:"MapboxMarker",emits:Gse,props:{lngLat:{default:()=>[0,0]},offset:{type:[Array],default:()=>[0,0]},anchor:{type:String,default:()=>"bottom"},color:{type:String,default:"#4668F2"},scale:{type:Number,default:1},draggable:{type:Boolean,default:!1},rotation:{type:Number,default:0},pitchAlignment:{type:String,default:"auto"},rotationAlignment:{type:String,default:"auto"}},setup(e){const{vmb_map:t}=jse.setup(),n=new Ep,r=jt(null),i=Vse(e);return ea("vmb_marker",n),Dr(()=>Dn(this,void 0,void 0,function*(){const s=ko();if(s&&t){yield Hse(i,t,n,s,e.lngLat,r);const c=yield n.promise;qse(c,s)}})),Bi(()=>Dn(this,void 0,void 0,function*(){(yield n.promise).remove()})),Nn(e,s=>Dn(this,void 0,void 0,function*(){yield Wse(s,n)})),{icon:r}}});const Yse={ref:"icon"},Zse=["height","width"],Xse={"fill-rule":"nonzero"},Kse=C3('<g transform="translate(3.0, 29.0)" fill="#000000"><ellipse opacity="0.04" cx="10.5" cy="5.80029008" rx="10.5" ry="5.25002273"></ellipse><ellipse opacity="0.04" cx="10.5" cy="5.80029008" rx="10.5" ry="5.25002273"></ellipse><ellipse opacity="0.04" cx="10.5" cy="5.80029008" rx="9.5" ry="4.77275007"></ellipse><ellipse opacity="0.04" cx="10.5" cy="5.80029008" rx="8.5" ry="4.29549936"></ellipse><ellipse opacity="0.04" cx="10.5" cy="5.80029008" rx="7.5" ry="3.81822308"></ellipse><ellipse opacity="0.04" cx="10.5" cy="5.80029008" rx="6.5" ry="3.34094679"></ellipse><ellipse opacity="0.04" cx="10.5" cy="5.80029008" rx="5.5" ry="2.86367051"></ellipse><ellipse opacity="0.04" cx="10.5" cy="5.80029008" rx="4.5" ry="2.38636864"></ellipse></g>',1),Qse=["fill"],Jse=Un("path",{d:"M27,13.5 C27,19.074644 20.250001,27.000002 14.75,34.500002 C14.016665,35.500004 12.983335,35.500004 12.25,34.500002 C6.7499993,27.000002 0,19.222562 0,13.5 C0,6.0441559 6.0441559,0 13.5,0 C20.955844,0 27,6.0441559 27,13.5 Z"},null,-1),ele=[Jse],tle=C3('<g opacity="0.25" fill="#000000"><path d="M13.5,0 C6.0441559,0 0,6.0441559 0,13.5 C0,19.222562 6.7499993,27 12.25,34.5 C13,35.522727 14.016664,35.500004 14.75,34.5 C20.250001,27 27,19.074644 27,13.5 C27,6.0441559 20.955844,0 13.5,0 Z M13.5,1 C20.415404,1 26,6.584596 26,13.5 C26,15.898657 24.495584,19.181431 22.220703,22.738281 C19.945823,26.295132 16.705119,30.142167 13.943359,33.908203 C13.743445,34.180814 13.612715,34.322738 13.5,34.441406 C13.387285,34.322738 13.256555,34.180814 13.056641,33.908203 C10.284481,30.127985 7.4148684,26.314159 5.015625,22.773438 C2.6163816,19.232715 1,15.953538 1,13.5 C1,6.584596 6.584596,1 13.5,1 Z"></path></g><g transform="translate(6.0, 7.0)" fill="#FFFFFF"></g><g transform="translate(8.0, 8.0)"><circle fill="#000000" opacity="0.25" cx="5.5" cy="5.5" r="5.4999962"></circle><circle fill="#FFFFFF" cx="5.5" cy="5.5" r="5.4999962"></circle></g>',3);function nle(e,t,n,r,i,s){return At(),Wt("div",null,[Un("div",Yse,[En(e.$slots,"icon",{},()=>[(At(),Wt("svg",{display:"block",height:42*e.scale+"px",width:27*e.scale+"px",viewBox:"0 0 27 41"},[Un("g",Xse,[Kse,Un("g",{fill:e.color},ele,8,Qse),tle])],8,Zse))])],512),En(e.$slots,"default")])}m4.render=nle;
1434const rle=e=>{const{showCompass:t,showZoom:n,vizualizePitch:r}=e;return{showCompass:t,showZoom:n,vizualizePitch:r}},ile=(e,t,n)=>(()=>Dn(void 0,void 0,void 0,function*(){(yield t.promise).addControl(e,n)}))();var g4=sr({name:"MapboxNavigationControl",props:{showCompass:{type:Boolean,default:!0},showZoom:{type:Boolean,default:!0},visualizePitch:{type:Boolean,default:!1},position:{type:String,default:()=>"top-right"}},setup(e){const t=dr("vmb_map",null),n=rle(e),r=new _u.NavigationControl(n),i=e.position;Dr(()=>{t&&ile(r,t,i)}),Bi(()=>Dn(this,void 0,void 0,function*(){t&&(yield t.promise).removeControl(r)}))}});function ole(e,t,n,r,i,s){return At(),Wt("div")}g4.render=ole;const ale=(e,t)=>{t.getLayer(e)&&t.removeLayer(e)},sle=(e,t)=>{t.getSource(e)&&t.removeSource(e)},lle=e=>hse(e,"MapboxGeogeometry"),a_=e=>e/110.574,s_=(e,t)=>e/(Math.cos(t*Math.PI/180)*111.32),k1=(e,t)=>Dn(void 0,void 0,void 0,function*(){const n=yield e.promise,r=t;ale(r.id,n),sle(r.id,n),n.addSource(r.id,r.getGeoJSON())}),A1=(e,t,n)=>Dn(void 0,void 0,void 0,function*(){const r=yield t.promise,i=n,s=Vo(e),c=r.getSource(i.id);i.updateOptions(s),c.setData(i.getGeoJSON().data)}),cle=(e,t,n)=>Dn(void 0,void 0,void 0,function*(){t&&(yield t.promise).setPopup(n)}),ule=(e,t,n)=>Dn(void 0,void 0,void 0,function*(){const r=yield t.promise,i=yield e.promise;if(r.id){const s=yield r.geogeometry.promise;i.on("click",r.id,c=>{const a=s.center;n.setLngLat(a).addTo(i)})}}),y4=e=>Vo(e,["closeButton","closeOnClick","closeOnMove","focusAfterOpen","anchor","offset","className","maxWidth"]),hle=(e,t,n,r,i,s)=>Dn(void 0,void 0,void 0,function*(){const c=yield t.promise,a=n;s.value&&a.setDOMContent(s.value),Use(e)?yield cle(e,r,a):lle(e)&&i?yield ule(t,i,a):a.addTo(c)}),_4=["close","open"],dle=[..._4],fle=(e,t)=>{R2(e,t,_4)},ple=(e,t)=>Dn(void 0,void 0,void 0,function*(){const n=y4(e);n.maxWidth&&t.setMaxWidth(n.maxWidth),n.offset&&t.setOffset(n.offset),e.lngLat&&t.setLngLat(e.lngLat)});var v4=sr({name:"MapboxPopup",emits:dle,props:{lngLat:{type:[Object,Array],default:()=>[0,0]},closeButton:{type:Boolean,default:!1},closeOnClick:{type:Boolean,default:!0},closeOnMove:{type:Boolean,default:!1},anchor:{type:String,default:void 0},offset:{type:[Number,Array],default:void 0},className:{type:String},focusAfterOpen:{type:Boolean,default:!0},maxWidth:{type:String,default:"500px"},renderless:{type:Boolean,default:!1}},setup(e){const t=jt(null),n=dr("vmb_map",null),r=dr("vmb_marker",null),i=dr("vmb_geogeometry_paint",null),s=y4(e),c=new _u.Popup(s).setLngLat(e.lngLat);return Dr(()=>Dn(this,void 0,void 0,function*(){const a=ko();n&&a&&(yield hle(a,n,c,r,i,t),fle(c,a))})),Nn(e,a=>{ple(a,c)}),Bi(()=>Dn(this,void 0,void 0,function*(){c.remove()})),{content:t}}});const mle={ref:"content"};function gle(e,t,n,r,i,s){return At(),Wt("div",mle,[En(e.$slots,"default")],512)}v4.render=gle;const yle=e=>Vo(e),_le=(e,t)=>Dn(void 0,void 0,void 0,function*(){(yield e.promise).addControl(t)});var b4=sr({name:"MapboxAttributionControl",props:{compact:{type:Boolean,default:!1},customAttribution:{type:[String,Array],default:void 0}},setup(e){const t=yle(e),n=new _u.AttributionControl(t),r=dr("vmb_map",null);Dr(()=>Dn(this,void 0,void 0,function*(){r&&_le(r,n)})),Bi(()=>Dn(this,void 0,void 0,function*(){r&&(yield r.promise).removeControl(n)}))}});function vle(e,t,n,r,i,s){return At(),Wt("div")}b4.render=vle;const ble=e=>{const{maxWidth:t,unit:n}=e;return{maxWidth:t,unit:n}},xle=(e,t)=>Dn(void 0,void 0,void 0,function*(){(yield e.promise).addControl(t)});var x4=sr({name:"MapboxScaleControl",props:{maxWidth:{type:Number,default:100},unit:{type:String,default:"metric"}},setup(e){const t=ble(e),n=new _u.ScaleControl(t),r=dr("vmb_map",null);Dr(()=>Dn(this,void 0,void 0,function*(){r&&(yield xle(r,n))})),Bi(()=>Dn(this,void 0,void 0,function*(){r&&(yield r.promise).removeControl(n)}))}});function wle(e,t,n,r,i,s){return At(),Wt("div")}x4.render=wle;const Tle=e=>Vo(e),Ele=(e,t)=>Dn(void 0,void 0,void 0,function*(){(yield t.promise).addControl(e)});var w4=sr({name:"MapboxFullscreenControl",props:{container:{type:Object,default:void 0}},setup(e){const t=dr("vmb_map",null),n=Tle(e),r=new _u.FullscreenControl(n);Dr(()=>Dn(this,void 0,void 0,function*(){t&&(yield Ele(r,t))})),Bi(()=>Dn(this,void 0,void 0,function*(){t&&(yield t.promise).removeControl(r)}))}});function Sle(e,t,n,r,i,s){return At(),Wt("div")}w4.render=Sle;const Cle=e=>Vo(e,["position"]),kle=(e,t)=>
1434{e.on("draw.create",n=>{t.emit("create",n)}),e.on("draw.update",n=>{t.emit("update",n)}),e.on("draw.delete",n=>{t.emit("delete",n)}),e.on("draw.selectionchange",n=>{t.emit("selectionchange",n)})},Ale=(e,t,n,r)=>Dn(void 0,void 0,void 0,function*(){r.emit("loaded",t);const i=yield e.promise;kle(i,r),i.addControl(t,n.position)});var T4=sr({name:"MapboxDrawControl",props:{position:{type:String,default:"top-left"}},setup(e){const t=Cle(e),n=new use,r=dr("vmb_map",null);Dr(()=>Dn(this,void 0,void 0,function*(){const i=ko();r&&i&&Ale(r,n,t,i)})),Bi(()=>Dn(this,void 0,void 0,function*(){r&&(yield r.promise).removeControl(n)}))}});function Ple(e,t,n,r,i,s){return At(),Wt("div")}T4.render=Ple;var E4=sr({name:"MapboxSourceGeoJson",props:{container:{type:Object,default:void 0}},setup(e){const t=dr("vmb_map",null);new P2.GeoJSONSource,Dr(()=>Dn(this,void 0,void 0,function*(){t&&(yield t.promise).addSource}))}});const Mle={ref:"features"};function Ile(e,t,n,r,i,s){return At(),Wt("div",Mle,[En(e.$slots,"default")],512)}E4.render=Ile;const Ole=e=>Vo(e);var S4=sr({name:"MapboxGeolocateControl",props:{positionOptions:{type:Object,default:()=>({enableHighAccuracy:!1,timeout:6e3})},fitBoundsOptions:{type:Object,default:()=>({maxZoom:15})},trackUserLocation:{type:Boolean,default:!1},showAccuracyCircle:{type:Boolean,default:!0},showUserLocation:{type:Boolean,default:!0}},setup(e){const t=dr("vmb_map",null),n=Ole(e),r=new _u.GeolocateControl(n);Dr(()=>Dn(this,void 0,void 0,function*(){t&&(yield t.promise).addControl(r)})),Bi(()=>Dn(this,void 0,void 0,function*(){t&&(yield t.promise).removeControl(r)}))}});function Dle(e,t,n,r,i,s){return At(),Wt("div")}S4.render=Dle;class P1{constructor(t){this.id=t.id,this.fillColor=t.fillColor||"#4668F2",this.antialias=typeof t.antialias=="boolean"?t.antialias:!0,this.opacity=typeof t.opacity=="number"?t.opacity:.6,t.outlineColor&&(this.outlineColor=t.outlineColor),this.deferred=new Ep,ea("vmb_geogeometry",this.deferred)}updateOptions(t){t.fillColor&&(this.fillColor=t.fillColor),typeof t.antialias=="boolean"&&(this.antialias=t.antialias),typeof t.opacity=="number"&&(this.opacity=t.opacity),t.outlineColor&&(this.outlineColor=t.outlineColor)}getPaint(){const t={};return this.fillColor&&(t["fill-color"]=this.fillColor),this.antialias&&(t["fill-antialias"]=this.antialias),this.opacity&&(t["fill-opacity"]=this.opacity),this.outlineColor&&(t["fill-outline-color"]=this.outlineColor),t}getLayer(){return{id:this.id,type:"fill",source:this.id,layout:{},paint:this.getPaint()}}}class Lle extends P1{constructor(t){super(t),this.edges=t.edges||10,this.radius=t.radius,this.center=t.center}updateOptions(t){super.updateOptions(t),t.edges&&(this.edges=t.edges),t.radiu
1434s&&(this.radius=t.radius),t.center&&(this.center=t.center)}getGeoJSON(){const t=this.edges,n=s_(this.radius,this.center[1]),r=a_(this.radius),i=[];for(let s=0;s<t;s++){const c=s/t*(2*Math.PI),a=n*Math.cos(c),m=r*Math.sin(c);i.push([this.center[0]+a,this.center[1]+m])}return i.push(i[0]),{type:"geojson",data:{type:"FeatureCollection",features:[{type:"Feature",geometry:{type:"Polygon",coordinates:[i]},properties:{}}]}}}}class C4{constructor(t){this.geogeometry=t.geogeometry,this.deferred=new Ep,ea("vmb_geogeometry_paint",this.deferred)}_init(t,n){return Dn(this,void 0,void 0,function*(){const r=yield this.geogeometry.promise;this.geoId=r.id,this.id=`${this.geoId}-${t}-${n}`})}setGeoId(t){this.geoId=t}}let WL=0;class Rle extends C4{constructor(t){super(t),this.geoId=t.geoId,this.id=`${t.geoId}-fill-${WL++}`,this.color=t.color||"#4668F2",this.antialias=typeof t.antialias=="boolean"?t.antialias:!0,this.opacity=typeof t.opacity=="number"?t.opacity:.6,t.outlineColor&&(this.outlineColor=t.outlineColor)}init(){const t=Object.create(null,{_init:{get:()=>super._init}});return Dn(this,void 0,void 0,function*(){yield t._init.call(this,"fill",WL++)})}getPaint(){const t={};return this.color&&(t["fill-color"]=this.color),this.antialias&&(t["fill-antialias"]=this.antialias),this.opacity&&(t["fill-opacity"]=this.opacity),this.outlineColor&&(t["fill-outline-color"]=this.outlineColor),t}update(t,n){return Dn(this,void 0,void 0,function*(){const r=yield n.promise,i=Vo(t);this.id&&(i.color&&i.color!==this.color&&(r.setPaintProperty(this.id,"fill-color",i.color),this.color=i.color),typeof i.antialias=="boolean"&&i.antialias!==this.antialias&&(r.setPaintProperty(this.id,"fill-antialias",i.antialias),this.antialias=i.antialias),typeof i.opacity=="number"&&i.opacity!==this.opacity&&(r.setPaintProperty(this.id,"fill-opacity",i.opacity),this.opacity=i.opacity),i.outlineColor&&i.outlineColor!==this.outlineColor&&(r.setPaintProperty(this.id,"fill-outline-color",i.outlineColor),this.outlineColor=i.outlineColor))})}getLayer(){if(this.id)return{id:this.id,type:"fill",source:this.geoId,layout:{},paint:this.getPaint()};throw new Error("Geogeometry.Paint.Fill: Cannot get layer. Not initialized")}}var Pg=sr({name:"MapboxGeogeometryFill",props:{color:{type:String,default:"#4668F2"},antialias:{type:Boolean,default:!0},opacity:{type:Number,default:.6},outlineColor:{type:String}},setup(e){const t=dr("vmb_geogeometry",null),n=new Ep,r=dr("vmb_map",null);if(!t)throw new Error("MapboxGeogeometryFill: no geogeometry found as parent");const i=new Rle(Object.assign(Object.assign({},Vo(e)),{geogeometry:t}));return ea("vmb_fill",n),Dr(()=>Dn(this,void 0,void 0,function*(){if(r&&t){const s=yield r.promise;(yield t.promise)&&s&&(yield i.init(),s.addLayer(i.getLayer()),n.resolve(i),i.deferred.resolve(i))}})),Nn(e,()=>Dn(this,void 0,void 0,function*(){const s=yield n.promise;s&&r&&s.update(e,r)})),Bi(()=>Dn(this,void 0,void 0,function*(){r&&i.id&&(yield r.promise).removeLayer(i.id)})),{}}});function Fle(e,t,n,r,i,s){return At(),Wt("div",null,[En(e.$slots,"default")])}Pg.render=Fle;let Ble=0;var k4=sr({name:"MapboxGeogeometryCircle",components:{MapboxGeogeometryFill:Pg},props:{id:{type:String,default:"circle"},center:{type:Array,required:!0},radius:{type:Number,required:!0},edges:{type:Number,default:10},fillColor:{type:String},outlineColor:{type:String},opacity:{type:Number},antialias:{type:Boolean}},setup(e){const t=dr("vmb_map",null),n=new C1,r=`${e.id}-${Ble++}`,i=new Lle(Vo(Object.assign(Object.assign({},e),{id:r}),["id","radius","center","edges","fillColor","outlineColor","opacity","antialias"]));ea("vmb_circle",n),Dr(()=>Dn(this,void 0,void 0,function*(){t&&(yield k1(t,i),n.resolve(i),i.deferred.resolve(i))})),Nn(e,()=>Dn(this,void 0,void 0,function*(){t&&(yield A1(e,t,i))})),Bi(()=>Dn(this,void 0,void 0,function*(){t&&(yield t.promise).removeLayer(i.id)}))}});const zle={ref:"features"};function Nle(e,t,n,r,i,s){const c=Zx("mapbox-geogeometry-fill");return At(),Wt("div",zle,[En(e.$slots,"default",{},()=>[sn(c,{color:e.fillColor,outlineColor:e.outlineColor,opacity:e.opacity,antialias:e.antialias},{default:wr(()=>[En(e.$slots,"popup")]),_:3},8,["color","outlineColor","opacity","antialias"])])],512)}k4.render=Nle;class $le extends P1{constructor(t){super(t),this.path=t.path}updateOptions(t){super.updateOptions(t),t.path&&(this.path=t.path)}get center(){const t=this.path.reduce((n,r)=>[n[0]+r[0],n[1]+r[1]]);return[t[0]/this.path.length,t[1]/this.path.length]}getGeoJSON(){return{type:"geojson",data:{type:"FeatureCollection",features:[{type:"Feature",geometry:{type:"Polygon",coordinates:[this.path]},properties:{}}]}}}}let jle=0;var A4=sr({name:"MapboxGeogeometryPolygon",components:{MapboxGeogeometryFill:Pg},props:{id:{type:String,default:"polygon"},path:{type:Array,required:!0},fillColor:{type:String},outlineColor:{type:String},opacity:{type:Number},antialias:{type:Boolean}},setup(e){const t=dr("vmb_map",null),n=new C1,r=`${e.id}-${jle++}`,i=new $le(Vo(Object.assign(Object.assign({},e),{id:r}),["id","path","fillColor","outlineColor","opacity","antialias"]));ea("vmb_polygon",n),Dr(()=>Dn(this,void 0,void 0,function*(){t&&(yield k1(t,i),n.resolve(i),i.deferred.resolve(i))})),Nn(e,()=>Dn(this,void 0,void 0,function*(){t&&(i.updateOptions(e),yield A1(e,t,i))})),Bi(()=>Dn(this,void 0,void 0,function*(){t&&(yield t.promise).removeLayer(i.id)}))}});const Ule={ref:"features"};function Vle(e,t,n,r,i,s){const c=Zx("mapbox-geogeometry-fill");return At(),Wt("div",Ule,[En(e.$slots,"default",{},()=>[sn(c,{color:e.fillColor,outlineColor:e.outlineColor,opacity:e.opacity,antialias:e.antialias},{default:wr(()=>[En(e.$slots,"popup")]),_:3},8,["color","outlineColor","opacity","antialias"])])],512)}A4.render=Vle;const Gle=(e,t)=>
1434{if(e.length!==4)throw"MapboxGeogeometryRectangle.rotateRectagle: Not a rectangle. Please supply exactly four coordinates";const n=t*Math.PI/180,r=[];for(let i=0;i<e.length;i++)r.push([e[i][0]*Math.cos(n)-e[i][1]*Math.sin(n),e[i][0]*Math.sin(n)+e[i][1]*Math.cos(n)]);return r};class qle extends P1{constructor(t){super(t),this.width=t.width,this.height=t.height,this.center=t.center,this.rotationDeg=t.rotationDeg||0}updateOptions(t){super.updateOptions(t),t.width&&(this.width=t.width),t.height&&(this.height=t.height),typeof t.rotationDeg=="number"&&t.rotationDeg!==this.rotationDeg&&(this.rotationDeg=t.rotationDeg)}get coordinates(){const t=Gle([[this.width/2,this.height/2],[-this.width/2,this.height/2],[-this.width/2,-this.height/2],[this.width/2,-this.height/2]],this.rotationDeg);return[[this.center[0]+s_(t[0][0],this.center[1]),this.center[1]+a_(t[0][1])],[this.center[0]+s_(t[1][0],this.center[1]),this.center[1]+a_(t[1][1])],[this.center[0]+s_(t[2][0],this.center[1]),this.center[1]+a_(t[2][1])],[this.center[0]+s_(t[3][0],this.center[1]),this.center[1]+a_(t[3][1])]]}getGeoJSON(){return{type:"geojson",data:{type:"FeatureCollection",features:[{type:"Feature",geometry:{type:"Polygon",coordinates:[[...this.coordinates,this.coordinates[0]]]},properties:{}}]}}}}let Wle=0;var P4=sr({name:"MapboxGeogeometryRectangle",components:{MapboxGeogeometryFill:Pg},props:{id:{type:String,default:"rectangle"},center:{type:Array,required:!0},width:{type:Number,required:!0},height:{type:Number,required:!0},fillColor:{type:String},outlineColor:{type:String},opacity:{type:Number,default:.6},antialias:{type:Boolean,default:!0},rotationDeg:{type:Number}},setup(e){const t=dr("vmb_map",null),n=new C1,r=`${e.id}-${Wle++}`,i=new qle(Vo(Object.assign(Object.assign({},e),{id:r}),["id","width","height","center","fillColor","outlineColor","opacity","antialias","rotationDeg"]));ea("vmb_rectangle",n),Dr(()=>Dn(this,void 0,void 0,function*(){t&&(yield k1(t,i),n.resolve(i),i.deferred.resolve(i))})),Bi(()=>Dn(this,void 0,void 0,function*(){t&&(yield t.promise).removeLayer(i.id)})),Nn(e,()=>Dn(this,void 0,void 0,function*(){t&&(yield A1(e,t,i))}))}});const Hle={ref:"features"};function Yle(e,t,n,r,i,s){const c=Zx("mapbox-geogeometry-fill");return At(),Wt("div",Hle,[En(e.$slots,"default",{},()=>[sn(c,{color:e.fillColor,outlineColor:e.outlineColor,opacity:e.opacity,antialias:e.antialias},{default:wr(()=>[En(e.$slots,"popup")]),_:3},8,["color","outlineColor","opacity","antialias"])])],512)}P4.render=Yle;const Zle=e=>e.length<=1?!1:e[0][0]===e[e.length-1][0]&&e[0][1]===e[e.length-1][1],Xle=e=>e.length===0||e[0].length===2&&typeof e[0][0]=="number"&&typeof e[0][1]=="number",M4=(e,t=0,n=[0,0])=>{let r=t;const i=[n[0],n[1]];if(Xle(e)){Zle(e)&&e.pop();for(const s of e)i[0]=(s[0]+i[0]*r)/(r+1),i[1]=(s[1]+i[1]*r)/(r+1),r++}else for(const s of e){const{visited:c,center:a}=M4(s);i[0]=(i[0]*r+a[0]*c)/(c+r),i[1]=(i[1]*r+a[1]*c)/(c+r),r+=c}return{visited:r,center:i}},I4=(e,t=0,n=[0,0])=>{let r=t;const i=[n[0],n[1]];switch(e.geometry.type){case"Polygon":case"LineString":{const{center:s,visited:c}=M4(e.geometry.coordinates);i[0]=(i[0]*r+s[0]*c)/(c+r),i[1]=(i[1]*r+s[1]*c)/(c+r),r+=c;break}}return{visited:r,center:i}},Kle=(e,t=0,n=[0,0])=>{let r=t;const i=[n[0],n[1]];for(const s of e.features){const{center:c,visited:a}=I4(s);i[0]=(i[0]*r+c[0]*a)/(a+r),i[1]=(i[1]*r+c[1]*a)/(a+r),r+=a;break}return{visited:r,center:i}};class Qle extends P1{constructor(t){super(t),this.source=t.source}updateOptions(t){super.updateOptions(t),t.source&&(this.source=t.source)}get center(){const t=this.getGeoJSONData();if(!t||!t.type)return console.warn("Geogeometry Raw: Could not get center. Coordinates could not be obtained"),[0,0];if(t.type==="Feature")return I4(t).center;if(t.type==="FeatureCollection")return Kle(t).center;throw new Error("Geogeometry Raw: Unknown Error getting Center")}getGeoJSON(){return this.source.type==="geojson"?this.source:{type:"geojson",data:this.source}}getGeoJSONData(){return this.getGeoJSON().data}}let Jle=0;var O4=sr({name:"MapboxGeogeometryRaw",components:{MapboxGeogeometryFill:Pg},props:{source:{type:Object,required:!0},id:{type:String,default:"raw"},fillColor:{type:String,default:"red"},outlineColor:{type:String},opacity:{type:Number},antialias:{type:Boolean}},setup(e){const t=dr("vmb_map",null),n=new Ep,r=`${e.id}-${Jle++}`,i=new Qle(Vo(Object.assign(Object.assign({},e),{id:r}),["source","id","fillColor","outlineColor","opacity","antialias"]));ea("vmb_raw",n),Dr(()=>Dn(this,void 0,void 0,function*(){t&&(yield k1(t,i),n.resolve(i),i.deferred.resolve(i))})),Nn(e,()=>Dn(this,void 0,void 0,function*(){t&&(i.updateOptions(e),yield A1(e,t,i))})),Bi(()=>Dn(this,void 0,void 0,function*(){t&&(yield t.promise).removeLayer(i.id)}))}});const ece={ref:"features"};function tce(e,t,n,r,i,s){return Zx("mapbox-geogeometry-fill"),At(),Wt("div",ece,[En(e.$slots,"default",{},()=>[hn("",!0)])],512)}O4.render=tce;let nce=0;class rce extends C4{constructor(t){super(t),this.color=t.color||"#000",this.opacity=typeof t.opacity=="number"?t.opacity:.6,t.geoId&&(this.geoId=t.geoId),typeof t.blur=="number"&&(this.blur=t.blur),t.cap&&(this.cap=t.cap),t.join&&(this.join=t.join),typeof t.width=="number"&&(this.width=t.width),t.translate&&(this.translate=t.translate),typeof t.offset=="number"&&(this.offset=t.offset),t.dasharray&&(this.dasharray=t.dasharray),typeof t.gapWidth=="number"&&(this.gapWidth=t.gapWidth),t.gradient&&(this.gradient=t.gradient),typeof t.miterLimit=="number"&&(this.miterLimit=t.miterLimit),typeof t.roundLimit=="number"&&(this.roundLimit=t.roundLimit),typeof t.sort
1434Key=="number"&&(this.sortKey=t.sortKey),t.translateAnchor&&(this.translateAnchor=t.translateAnchor)}getPaint(){const t={"line-blur":this.blur,"line-opacity":this.opacity,"line-color":this.color,"line-width":this.width,"line-translate":this.translate,"line-offset":this.offset,"line-dasharray":this.dasharray,"line-gap-width":this.gapWidth,"line-translate-anchor":this.translateAnchor},n=Vo(t);return console.log(n),n}getLayout(){const t={"line-cap":this.cap,"line-join":this.join,"line-miter-limit":this.miterLimit,"line-round-limit":this.roundLimit,"line-sort-key":this.sortKey},n=Vo(t);return console.log(n),n}init(){return super._init("line",nce++),this}update(t,n){return Dn(this,void 0,void 0,function*(){const r=yield n.promise,i=Vo(t);this.id&&(i.color&&i.color!==this.color&&(r.setPaintProperty(this.id,"line-color",i.color),this.color=i.color),typeof i.blur=="number"&&i.blur!==this.blur&&(r.setPaintProperty(this.id,"line-blur",i.blur),this.blur=i.blur),i.cap&&i.cap!==this.cap&&(r.setPaintProperty(this.id,"line-cap",i.cap),this.cap=i.cap),i.join&&i.join!==this.join&&(r.setPaintProperty(this.id,"line-join",i.join),this.join=i.join),typeof i.opacity=="number"&&i.opacity!==this.opacity&&(r.setPaintProperty(this.id,"line-opacity",i.opacity),this.opacity=i.opacity),typeof i.width=="number"&&i.width!==this.width&&(r.setPaintProperty(this.id,"line-width",i.width),this.width=i.width),i.translate&&this.translate&&(i.translate[0]!==this.translate[0]||i.translate[1]!==this.translate[1])&&(r.setPaintProperty(this.id,"line-translate",i.translate),this.translate=i.translate),typeof i.offset=="number"&&this.offset!==i.offset&&(r.setPaintProperty(this.id,"line-offset",i.offset),this.offset=i.offset),i.dasharray&&!s4(this.dasharray,i.dasharray)&&(r.setPaintProperty(this.id,"line-dasharray",i.dasharray),this.dasharray=i.dasharray),typeof i.gapWidth=="number"&&this.gapWidth!==i.gapWidth&&(r.setPaintProperty(this.id,"line-gap-width",i.gapWidth),this.gapWidth=i.gapWidth),typeof i.miterLimit=="number"&&this.miterLimit!==i.miterLimit&&(r.setPaintProperty(this.id,"line-miter-limit",i.miterLimit),this.miterLimit=i.miterLimit),typeof i.roundLimit=="number"&&this.roundLimit!==i.roundLimit&&(r.setPaintProperty(this.id,"line-round-limit",i.roundLimit),this.roundLimit=i.roundLimit),typeof i.sortKey=="number"&&(r.setPaintProperty(this.id,"line-sort-key",i.sortKey),this.sortKey=i.sortKey),i.translateAnchor&&this.translateAnchor!==i.translateAnchor&&(r.setPaintProperty(this.id,"line-translate-anchor",i.translateAnchor),this.translateAnchor=i.translateAnchor))})}getLayer(){if(this.id)return{id:this.id,type:"line",source:this.geoId,layout:this.getLayout(),paint:this.getPaint()};throw new Error("Geogeometry.Paint.Line: Cannot get Layer. Not initialized")}}var D4=sr({name:"MapboxGeogeometryLine",props:{blur:{type:Number},cap:{type:String},join:{type:String},opacity:{type:Number,default:1},color:{type:String,default:"#4668F2"},width:{type:Number},translate:{type:Array},offset:{type:Number},dasharray:{type:Array},gapWidth:{type:Number}},setup(e){const t=dr("vmb_geogeometry",null),n=new Ep,r=dr("vmb_map",null);if(ea("vmb_paint",n),!t)throw new Error("MapboxGeogeometryLine: no geogeometry found as parent");const i=new rce(Object.assign(Object.assign({},Vo(e)),{geogeometry:t}));return Dr(()=>Dn(this,void 0,void 0,function*(){if(r&&t){yield i.init();const s=yield r.promise;(yield t.promise)&&s&&(s.addLayer(i.getLayer()),n.resolve(i))}})),Nn(e,()=>Dn(this,void 0,void 0,function*(){const s=yield n.promise;s&&r&&s.update(e,r)})),Bi(()=>Dn(this,void 0,void 0,function*(){r&&i.id&&(yield r.promise).removeLayer(i.id)})),{}}});function ice(e,t,n,r,i,s){return At(),Wt("div")}D4.render=ice;var HL=Object.freeze({__proto__:null,MapboxGeocoderControl:h4,MapboxMap:F2,MapboxMarker:m4,MapboxNavigationControl:g4,MapboxPopup:v4,MapboxAttributionControl:b4,MapboxScaleControl:x4,MapboxFullscreenControl:w4,MapboxDrawControl:T4,MapboxSourceGeoJson:E4,MapboxGeolocateControl:S4,MapboxGeogeometryCircle:k4,MapboxGeogeometryPolygon:A4,MapboxGeogeometryRectangle:P4,MapboxGeogeometryRaw:O4,MapboxGeogeometryFill:Pg,MapboxGeogeometryLine:D4}),oce=e=>
1434{Object.keys(HL).forEach(t=>{e.component(t,HL[t])})};const ace=Gi(e=>{e.vueApp.use(oce)});var sce=4,lce=.001,cce=1e-7,uce=10,l_=11,cb=1/(l_-1),hce=typeof Float32Array=="function";function L4(e,t){return 1-3*t+3*e}function R4(e,t){return 3*t-6*e}function F4(e){return 3*e}function Ex(e,t,n){return((L4(t,n)*e+R4(t,n))*e+F4(t))*e}function B4(e,t,n){return 3*L4(t,n)*e*e+2*R4(t,n)*e+F4(t)}function dce(e,t,n,r,i){var s,c,a=0;do c=t+(n-t)/2,s=Ex(c,r,i)-e,s>0?n=c:t=c;while(Math.abs(s)>cce&&++a<uce);return c}function fce(e,t,n,r){for(var i=0;i<sce;++i){var s=B4(t,n,r);if(s===0)return t;var c=Ex(t,n,r)-e;t-=c/s}return t}function pce(e){return e}var mce=function(t,n,r,i){if(!(0<=t&&t<=1&&0<=r&&r<=1))throw new Error("bezier x values must be in [0, 1] range");if(t===n&&r===i)return pce;for(var s=hce?new Float32Array(l_):new Array(l_),c=0;c<l_;++c)s[c]=Ex(c*cb,t,r);function a(m){for(var g=0,x=1,T=l_-1;x!==T&&s[x]<=m;++x)g+=cb;--x;var C=(m-s[x])/(s[x+1]-s[x]),A=g+C*cb,P=B4(A,t,r);return P>=lce?fce(m,A,t,r):P===0?A:dce(m,g,g+cb,t,r)}return function(g){return g===0?0:g===1?1:Ex(a(g),n,i)}};const YL=Rd(mce),ZL={ease:[.25,.1,.25,1],linear:[0,0,1,1],"ease-in":[.42,0,1,1],"ease-out":[0,0,.58,1],"ease-in-out":[.42,0,.58,1]};let z4=!1;try{let e=Object.defineProperty({},"passive",{get:function(){z4=!0}});window.addEventListener("test",null,e)}catch{}const ed={$(e){return typeof e!="string"?e:document.querySelector(e)},on(e,t,n,r={passive:!1}){t instanceof Array||(t=[t]);for(let i=0;i<t.length;i++)e.addEventListener(t[i],n,z4?r:!1)},off(e,t,n){t instanceof Array||(t=[t]);for(let r=0;r<t.length;r++)e.removeEventListener(t[r],n)},cumulativeOffset(e){let t=0,n=0;do t+=e.offsetTop||0,n+=e.offsetLeft||0,e=e.offsetParent;while(e);return{top:t,left:n}}},XL=["mousedown","wheel","DOMMouseScroll","mousewheel","keyup","touchmove"];let Ds={container:"body",duration:500,lazy:!0,easing:"ease",offset:0,force:!0,cancelable:!0,onStart:!1,onDone:!1,onCancel:!1,x:!1,y:!0};function N4(e){Ds=Object.assign({},Ds,e)}const $4=()=>{let e,t,n,r,i,s,c,a,m,g,x,T,C,A,P,D,B,R,N,j,U,W,Q,Z=le=>{a&&(Q=le,j=!0)},K,Y,me,ge;function ce(le){let se=le.scrollTop;return le.tagName.toLowerCase()==="body"&&(se=se||document.documentElement.scrollTop),se}function fe(le){let se=le.scrollLeft;return le.tagName.toLowerCase()==="body"&&(se=se||document.documentElement.scrollLeft),se}
1434function ie(){U=ed.cumulativeOffset(t),W=ed.cumulativeOffset(e),T&&(P=W.left-U.left+s,R=P-A),C&&(B=W.top-U.top+s,N=B-D)}function xe(le){if(j)return Te();Y||(Y=le),i||ie(),me=le-Y,ge=Math.min(me/n,1),ge=K(ge),oe(t,D+N*ge,A+R*ge),me<n?window.requestAnimationFrame(xe):Te()}function Te(){j||oe(t,B,P),Y=!1,ed.off(t,XL,Z),j&&x&&x(Q,e),!j&&g&&g(e)}function oe(le,se,Ne){C&&(le.scrollTop=se),T&&(le.scrollLeft=Ne),le.tagName.toLowerCase()==="body"&&(C&&(document.documentElement.scrollTop=se),T&&(document.documentElement.scrollLeft=Ne))}function ne(le,se,Ne={}){if(typeof se=="object"?Ne=se:typeof se=="number"&&(Ne.duration=se),e=ed.$(le),!e)return console.warn("[vue-scrollto warn]: Trying to scroll to an element that is not on the page: "+le);if(t=ed.$(Ne.container||Ds.container),n=Ne.hasOwnProperty("duration")?Ne.duration:Ds.duration,i=Ne.hasOwnProperty("lazy")?Ne.lazy:Ds.lazy,r=Ne.easing||Ds.easing,s=Ne.hasOwnProperty("offset")?Ne.offset:Ds.offset,c=Ne.hasOwnProperty("force")?Ne.force!==!1:Ds.force,a=Ne.hasOwnProperty("cancelable")?Ne.cancelable!==!1:Ds.cancelable,m=Ne.onStart||Ds.onStart,g=Ne.onDone||Ds.onDone,x=Ne.onCancel||Ds.onCancel,T=Ne.x===void 0?Ds.x:Ne.x,C=Ne.y===void 0?Ds.y:Ne.y,typeof s=="function"&&(s=s(e,t)),A=fe(t),D=ce(t),ie(),j=!1,!c){const Se=t.tagName.toLowerCase()==="body"?document.documentElement.clientHeight||window.innerHeight:t.offsetHeight,xt=D,kt=xt+Se,wt=B-s,Ue=wt+e.offsetHeight;if(wt>=xt&&Ue<=kt){g&&g(e);return}}if(m&&m(e),!N&&!R){g&&g(e);return}return typeof r=="string"&&(r=ZL[r]||ZL.ease),K=YL.apply(YL,r),ed.on(t,XL,Z,{passive:!0}),window.requestAnimationFrame(xe),()=>{Q=null,j=!0}}return ne},pC=$4();let bd=[];function gce(e){for(let t=0;t<bd.length;++t)if(bd[t].el===e)return bd.splice(t,1),!0;return!1}function yce(e){for(let t=0;t<bd.length;++t)if(bd[t].el===e)return bd[t]}function mC(e){let t=yce(e);return t||(bd.push(t={el:e,binding:{}}),t)}function KL(e){const t=mC(this).binding;if(t.value){if(e.preventDefault(),typeof t.value=="string")return pC(t.value);pC(t.value.el||t.value.element,t.value)}}const gm={bind(e,t){mC(e).binding=t,ed.on(e,"click",KL)},unbind(e){gce(e),ed.off(e,"click",KL)},update(e,t){mC(e).binding=t}},pg={bind:gm.bind,unbind:gm.unbind,update:gm.update,beforeMount:gm.bind,unmounted:gm.unbind,updated:gm.update,scrollTo:pC,bindings:bd},j4=function(e,t){t&&N4(t),e.directive("scroll-to",pg);const n=e.config.globalProperties||e.prototype;n.$scrollTo=pg.scrollTo};typeof window<"u"&&window.Vue&&(window.VueScrollTo=pg,window.VueScrollTo.setDefaults=N4,window.VueScrollTo.scroller=$4,window.Vue.use&&window.Vue.use(j4));pg.install=j4;const _ce=Gi(e=>(e.vueApp.directive("scroll-to",{mounted(t,n){const{element:r,duration:i}=n.value;t.addEventListener("click",s=>{s.preventDefault(),pg.scrollTo(r,i,{easing:[.12,0,.39,0]})})}}),{provide:{scrollTo:pg.scrollTo}}));var U4=typeof window<"u",vce=()=>U4?window.innerWidth:0,bce=()=>U4?window.innerHeight:0,xce=e=>e??vce(),wce=e=>e??bce(),Tce=e=>({width:xce(e==null?void 0:e.width),height:wce(e==null?void 0:e.height)}),Ece=e=>{let t=so(Tce()),n=({width:r,height:i})=>{t.width=r,t.height=i};return e().addObserver("option-api",n).subscribe(),{computed:{$windowWidth(){return t.width},$windowHeight(){return t.height}}}},id,ep,pv,od,ad,mv,gC,gv,yC,Nx,V4,EF,Sce=(EF=class{constructor(e){Oa(this,mv);Oa(this,gv);Oa(this,Nx);Oa(this,id,new Map);Oa(this,ep,void 0);Oa(this,pv,void 0);Oa(this,od,!1);Oa(this,ad,void 0);let{delay:t=33}=e??{};sl(this,ep,t),sl(this,ad,vc(this,Nx,V4).bind(this))}addObserver(e,t){return pi(this,id).set(e,t),t(vc(this,mv,gC).call(this)),this}deleteObserver(e){return pi(this,id).delete(e),this}deleteObservers(){return pi(this,id).clear(),this}notifyObservers(e){return pi(this,id).forEach(t=>{t(e)}),this}subscribe(){return typeof window>"u"?this:pi(this,od)?this:(window.addEventListener("resize",pi(this,ad)),window.addEventListener("orientationchange",pi(this,ad)),sl(this,od,!0),this)}unsubscribe(){return pi(this,od)?(window.removeEventListener("resize",pi(this,ad)),window.removeEventListener("orientationchange",pi(this,ad)),sl(this,od,!1),this):this}setDelay(e){return sl(this,ep,e),this}info(){return{delay:pi(this,ep),subscribed:pi(this,od),observersCount:pi(this,id).size}}
1434dispatch(){return vc(this,gv,yC).call(this),this}},id=new WeakMap,ep=new WeakMap,pv=new WeakMap,od=new WeakMap,ad=new WeakMap,mv=new WeakSet,gC=function(){return typeof window>"u"?{width:0,height:0}:{width:window.innerWidth,height:window.innerHeight}},gv=new WeakSet,yC=function(){let e=vc(this,mv,gC).call(this);this.notifyObservers(e)},Nx=new WeakSet,V4=function(){clearTimeout(pi(this,pv)),window.setTimeout(()=>{},1),sl(this,pv,window.setTimeout(()=>{vc(this,gv,yC).call(this)},pi(this,ep)))},EF),lE,QL=()=>(lE||(lE=new Sce),lE);function Cce(e,{delay:t=33}={}){let n=Ece(QL);QL().setDelay(t),e.mixin({mixins:[n]})}var kce={install:Cce};const Ace=Gi(e=>{e.vueApp.use(kce)});function Zl(e){"@babel/helpers - typeof";return Zl=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},Zl(e)}function ir(e){if(e===null||e===!0||e===!1)return NaN;var t=Number(e);return isNaN(t)?t:t<0?Math.ceil(t):Math.floor(t)}function Vn(e,t){if(t.length<e)throw new TypeError(e+" argument"+(e>1?"s":"")+" required, but only "+t.length+" present")}function ar(e){Vn(1,arguments);var t=Object.prototype.toString.call(e);return e instanceof Date||Zl(e)==="object"&&t==="[object Date]"?new Date(e.getTime()):typeof e=="number"||t==="[object Number]"?new Date(e):((typeof e=="string"||t==="[object String]")&&typeof console<"u"&&(console.warn("Starting with v2.0.0-beta.1 date-fns doesn't accept strings as date arguments. Please use `parseISO` to parse strings. See: https://github.com/date-fns/date-fns/blob/master/docs/upgradeGuide.md#string-arguments"),console.warn(new Error().stack)),new Date(NaN))}function Xu(e,t){Vn(2,arguments);var n=ar(e),r=ir(t);return isNaN(r)?new Date(NaN):(r&&n.setDate(n.getDate()+r),n)}function du(e,t){Vn(2,arguments);var n=ar(e),r=ir(t);if(isNaN(r))return new Date(NaN);if(!r)return n;var i=n.getDate(),s=new Date(n.getTime());s.setMonth(n.getMonth()+r+1,0);var c=s.getDate();return i>=c?s:(n.setFullYear(s.getFullYear(),s.getMonth(),i),n)}function G4(e,t){if(Vn(2,arguments),!t||Zl(t)!=="object")return new Date(NaN);var n=t.years?ir(t.years):0,r=t.months?ir(t.months):0,i=t.weeks?ir(t.weeks):0,s=t.days?ir(t.days):0,c=t.hours?ir(t.hours):0,a=t.minutes?ir(t.minutes):0,m=t.seconds?ir(t.seconds):0,g=ar(e),x=r||n?du(g,r+n*12):g,T=s||i?Xu(x,s+i*7):x,C=a+c*60,A=m+C*60,P=A*1e3,D=new Date(T.getTime()+P);return D}function Pce(e,t){Vn(2,arguments);var n=ar(e).getTime(),r=ir(t);return new Date(n+r)}var Mce={};function bu(){return Mce}function yp(e,t){var n,r,i,s,c,a,m,g;Vn(1,arguments);var x=bu(),T=ir((n=(r=(i=(s=t==null?void 0:t.weekStartsOn)!==null&&s!==void 0?s:t==null||(c=t.locale)===null||c===void 0||(a=c.options)===null||a===void 0?void 0:a.weekStartsOn)!==null&&i!==void 0?i:x.weekStartsOn)!==null&&r!==void 0?r:(m=x.locale)===null||m===void 0||(g=m.options)===null||g===void 0?void 0:g.weekStartsOn)!==null&&n!==void 0?n:0);if(!(T>=0&&T<=6))throw new RangeError("weekStartsOn must be between 0 and 6 inclusively");var C=ar(e),A=C.getDay(),P=(A<T?7:0)+A-T;return C.setDate(C.getDate()-P),C.setHours(0,0,0,0),C}function Sx(e){return Vn(1,arguments),yp(e,{weekStartsOn:1})}function Ice(e){Vn(1,arguments);var t=ar(e),n=t.getFullYear(),r=new Date(0);r.setFullYear(n+1,0,4),r.setHours(0,0,0,0);var i=Sx(r),s=new Date(0);s.setFullYear(n,0,4),s.setHours(0,0,0,0);var c=Sx(s);return t.getTime()>=i.getTime()?n+1:t.getTime()>=c.getTime()?n:n-1}function Oce(e){Vn(1,arguments);var t=Ice(e),n=new Date(0);n.setFullYear(t,0,4),n.setHours(0,0,0,0);var r=Sx(n);return r}function Cx(e){var t=new Date(Date.UTC(e.getFullYear(),e.getMonth(),e.getDate(),e.getHours(),e.getMinutes(),e.getSeconds(),e.getMilliseconds()));return t.setUTCFullYear(e.getFullYear()),e.getTime()-t.getTime()}function JL(e){Vn(1,arguments);var t=ar(e);return t.setHours(0,0,0,0),t}var Dce=864e5;function Lce(e,t){Vn(2,arguments);var n=JL(e),r=JL(t),i=n.getTime()-Cx(n),s=r.getTime()-Cx(r);return Math.round((i-s)/Dce)}function B2(e,t){Vn(2,arguments);var n=ir(t);return du(e,n*12)}var z2=6e4,N2=36e5,Rce=1e3;function q4(e){return Vn(1,arguments),e instanceof Date||Zl(e)==="object"&&Object.prototype.toString.call(e)==="[object Date]"}
vendor: 13,425 bytes, line 1434
1434function S_(e){if(Vn(1,arguments),!q4(e)&&typeof e!="number")return!1;var t=ar(e);return!isNaN(Number(t))}function W4(e,t){var n;Vn(1,arguments);var r=e||{},i=ar(r.start),s=ar(r.end),c=s.getTime();if(!(i.getTime()<=c))throw new RangeError("Invalid interval");var a=[],m=i;m.setHours(0,0,0,0);var g=Number((n=t==null?void 0:t.step)!==null&&n!==void 0?n:1);if(g<1||isNaN(g))throw new RangeError("`options.step` must be a number greater than 1");for(;m.getTime()<=c;)a.push(ar(m)),m.setDate(m.getDate()+g),m.setHours(0,0,0,0);return a}function Fce(e,t){var n,r,i,s,c,a,m,g;Vn(1,arguments);var x=bu(),T=ir((n=(r=(i=(s=t==null?void 0:t.weekStartsOn)!==null&&s!==void 0?s:t==null||(c=t.locale)===null||c===void 0||(a=c.options)===null||a===void 0?void 0:a.weekStartsOn)!==null&&i!==void 0?i:x.weekStartsOn)!==null&&r!==void 0?r:(m=x.locale)===null||m===void 0||(g=m.options)===null||g===void 0?void 0:g.weekStartsOn)!==null&&n!==void 0?n:0);if(!(T>=0&&T<=6))throw new RangeError("weekStartsOn must be between 0 and 6 inclusively");var C=ar(e),A=C.getDay(),P=(A<T?-7:0)+6-(A-T);return C.setDate(C.getDate()+P),C.setHours(23,59,59,999),C}function H4(e,t){Vn(2,arguments);var n=ir(t);return Pce(e,-n)}var Bce=864e5;function zce(e){Vn(1,arguments);var t=ar(e),n=t.getTime();t.setUTCMonth(0,1),t.setUTCHours(0,0,0,0);var r=t.getTime(),i=n-r;return Math.floor(i/Bce)+1}function mg(e){Vn(1,arguments);var t=1,n=ar(e),r=n.getUTCDay(),i=(r<t?7:0)+r-t;return n.setUTCDate(n.getUTCDate()-i),n.setUTCHours(0,0,0,0),n}function Y4(e){Vn(1,arguments);var t=ar(e),n=t.getUTCFullYear(),r=new Date(0);r.setUTCFullYear(n+1,0,4),r.setUTCHours(0,0,0,0);var i=mg(r),s=new Date(0);s.setUTCFullYear(n,0,4),s.setUTCHours(0,0,0,0);var c=mg(s);return t.getTime()>=i.getTime()?n+1:t.getTime()>=c.getTime()?n:n-1}function Nce(e){Vn(1,arguments);var t=Y4(e),n=new Date(0);n.setUTCFullYear(t,0,4),n.setUTCHours(0,0,0,0);var r=mg(n);return r}var $ce=6048e5;function Z4(e){Vn(1,arguments);var t=ar(e),n=mg(t).getTime()-Nce(t).getTime();return Math.round(n/$ce)+1}function _p(e,t){var n,r,i,s,c,a,m,g;Vn(1,arguments);var x=bu(),T=ir((n=(r=(i=(s=t==null?void 0:t.weekStartsOn)!==null&&s!==void 0?s:t==null||(c=t.locale)===null||c===void 0||(a=c.options)===null||a===void 0?void 0:a.weekStartsOn)!==null&&i!==void 0?i:x.weekStartsOn)!==null&&r!==void 0?r:(m=x.locale)===null||m===void 0||(g=m.options)===null||g===void 0?void 0:g.weekStartsOn)!==null&&n!==void 0?n:0);if(!(T>=0&&T<=6))throw new RangeError("weekStartsOn must be between 0 and 6 inclusively");var C=ar(e),A=C.getUTCDay(),P=(A<T?7:0)+A-T;return C.setUTCDate(C.getUTCDate()-P),C.setUTCHours(0,0,0,0),C}function $2(e,t){var n,r,i,s,c,a,m,g;Vn(1,arguments);var x=ar(e),T=x.getUTCFullYear(),C=bu(),A=ir((n=(r=(i=(s=t==null?void 0:t.firstWeekContainsDate)!==null&&s!==void 0?s:t==null||(c=t.locale)===null||c===void 0||(a=c.options)===null||a===void 0?void 0:a.firstWeekContainsDate)!==null&&i!==void 0?i:C.firstWeekContainsDate)!==null&&r!==void 0?r:(m=C.locale)===null||m===void 0||(g=m.options)===null||g===void 0?void 0:g.firstWeekContainsDate)!==null&&n!==void 0?n:1);if(!(A>=1&&A<=7))throw new RangeError("firstWeekContainsDate must be between 1 and 7 inclusively");var P=new Date(0);P.setUTCFullYear(T+1,0,A),P.setUTCHours(0,0,0,0);var D=_p(P,t),B=new Date(0);B.setUTCFullYear(T,0,A),B.setUTCHours(0,0,0,0);var R=_p(B,t);return x.getTime()>=D.getTime()?T+1:x.getTime()>=R.getTime()?T:T-1}function jce(e,t){var n,r,i,s,c,a,m,g;Vn(1,arguments);var x=bu(),T=ir((n=(r=(i=(s=t==null?void 0:t.firstWeekContainsDate)!==null&&s!==void 0?s:t==null||(c=t.locale)===null||c===void 0||(a=c.options)===null||a===void 0?void 0:a.firstWeekContainsDate)!==null&&i!==void 0?i:x.firstWeekContainsDate)!==null&&r!==void 0?r:(m=x.locale)===null||m===void 0||(g=m.options)===null||g===void 0?void 0:g.firstWeekContainsDate)!==null&&n!==void 0?n:1),C=$2(e,t),A=new Date(0);A.setUTCFullYear(C,0,T),A.setUTCHours(0,0,0,0);var P=_p(A,t);return P}var Uce=6048e5;function X4(e,t){Vn(1,arguments);var n=ar(e),r=_p(n,t).getTime()-jce(n,t).getTime();return Math.round(r/Uce)+1}function Ei(e,t){for(var n=e<0?"-":"",r=Math.abs(e).toString();r.length<t;)r="0"+r;return n+r}var Vce={y:function(t,n){var r=t.getUTCFullYear(),i=r>0?r:1-r;return Ei(n==="yy"?i%100:i,n.length)},M:function(t,n){var r=t.getUTCMonth();return n==="M"?String(r+1):Ei(r+1,2)},d:function(t,n){return Ei(t.getUTCDate(),n.length)},a:function(t,n){var r=t.getUTCHours()/12>=1?"pm":"am";switch(n){case"a":case"aa":return r.toUpperCase();case"aaa":return r;case"aaaaa":return r[0];case"aaaa":default:return r==="am"?"a.m.":"p.m."}},h:function(t,n){return Ei(t.getUTCHours()%12||12,n.length)},H:function(t,n){return Ei(t.getUTCHours(),n.length)},m:function(t,n){return Ei(t.getUTCMinutes(),n.length)},s:function(t,n){return Ei(t.getUTCSeconds(),n.length)},S:function(t,n){var r=n.length,i=t.getUTCMilliseconds(),s=Math.floor(i*Math.pow(10,r-3));return Ei(s,n.length)}};const Wh=Vce;var ym={am:"am",pm:"pm",midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},Gce={G:function(t,n,r){var i=t.getUTCFullYear()>0?1:0;switch(n){case"G":case"GG":case"GGG":return r.era(i,{width:"abbreviated"});case"GGGGG":return r.era(i,{width:"narrow"});case"GGGG":default:return r.era(i,{width:"wide"})}},y:function(t,n,r){if(n==="yo"){var i=t.getUTCFullYear(),s=i>0?i:1-i;return r.ordinalNumber(s,{unit:"year"})}return Wh.y(t,n)},Y:function(t,n,r,i){var s=$2(t,i),c=s>0?s:1-s;if(n==="YY"){var a=c%100;return Ei(a,2)}return n==="Yo"?r.ordinalNumber(c,{unit:"year"}):Ei(c,n.length)},R:function(t,n){var r=Y4(t);return Ei(r,n.length)},u:function(t,n){var r=t.getUTCFullYear();return Ei(r,n.length)},Q:function(t,n,r){var i=Math.ceil((t.getUTCMonth()+1)/3);switch(n){case"Q":return String(i);case"QQ":return Ei(i,2);case"Qo":return r.ordinalNumber(i,{unit:"quarter"});case"QQQ":return r.quarter(i,{width:"abbreviated",context:"formatting"});case"QQQQQ":return r.quarter(i,{width:"narrow",context:"formatting"});case"QQQQ":default:return r.quarter(i,{width:"wide",context:"formatting"})}},q:function(t,n,r){var i=Math.ceil((t.getUTCMonth()+1)/3);switch(n){case"q":return String(i);case"qq":return Ei(i,2);case"qo":return r.ordinalNumber(i,{unit:"quarter"});case"qqq":return r.quarter(i,{width:"abbreviated",context:"standalone"});case"qqqqq":return r.quarter(i,{width:"narrow",context:"standalone"});case"qqqq":default:return r.quarter(i,{width:"wide",context:"standalone"})}},M:function(t,n,r){var i=t.getUTCMonth();switch(n){case"M":case"MM":return Wh.M(t,n);case"Mo":return r.ordinalNumber(i+1,{unit:"month"});case"MMM":return r.month(i,{width:"abbreviated",context:"formatting"});case"MMMMM":return r.month(i,{width:"narrow",context:"formatting"});case"MMMM":default:return r.month(i,{width:"wide",context:"formatting"})}},L:function(t,n,r){var i=t.getUTCMonth();switch(n){case"L":return String(i+1);case"LL":return Ei(i+1,2);case"Lo":return r.ordinalNumber(i+1,{unit:"month"});case"LLL":return r.month(i,{width:"abbreviated",context:"standalone"});case"LLLLL":return r.month(i,{width:"narrow",context:"standalone"});case"LLLL":default:return r.month(i,{width:"wide",context:"standalone"})}},w:function(t,n,r,i){var s=X4(t,i);return n==="wo"?r.ordinalNumber(s,{unit:"week"}):Ei(s,n.length)},I:function(t,n,r){var i=Z4(t);return n==="Io"?r.ordinalNumber(i,{unit:"week"}):Ei(i,n.length)},d:function(t,n,r){return n==="do"?r.ordinalNumber(t.getUTCDate(),{unit:"date"}):Wh.d(t,n)},D:function(t,n,r){var i=zce(t);return n==="Do"?r.ordinalNumber(i,{unit:"dayOfYear"}):Ei(i,n.length)},E:function(t,n,r){var i=t.getUTCDay();switch(n){case"E":case"EE":case"EEE":return r.day(i,{width:"abbreviated",context:"formatting"});case"EEEEE":return r.day(i,{width:"narrow",context:"formatting"});case"EEEEEE":return r.day(i,{width:"short",context:"formatting"});case"EEEE":default:return r.day(i,{width:"wide",context:"formatting"})}},e:function(t,n,r,i){var s=t.getUTCDay(),c=(s-i.weekStartsOn+8)%7||7;switch(n){case"e":return String(c);case"ee":return Ei(c,2);case"eo":return r.ordinalNumber(c,{unit:"day"});case"eee":return r.day(s,{width:"abbreviated",context:"formatting"});case"eeeee":return r.day(s,{width:"narrow",context:"formatting"});case"eeeeee":return r.day(s,{width:"short",context:"formatting"});case"eeee":default:return r.day(s,{width:"wide",context:"formatting"})}},c:function(t,n,r,i){var s=t.getUTCDay(),c=(s-i.weekStartsOn+8)%7||7;switch(n){case"c":return String(c);case"cc":return Ei(c,n.length);case"co":return r.ordinalNumber(c,{unit:"day"});case"ccc":return r.day(s,{width:"abbreviated",context:"standalone"});case"ccccc":return r.day(s,{width:"narrow",context:"standalone"});case"cccccc":return r.day(s,{width:"short",context:"standalone"});case"cccc":default:return r.day(s,{width:"wide",context:"standalone"})}},i:function(t,n,r){var i=t.getUTCDay(),s=i===0?7:i;switch(n){case"i":return String(s);case"ii":return Ei(s,n.length);case"io":return r.ordinalNumber(s,{unit:"day"});case"iii":return r.day(i,{width:"abbreviated",context:"formatting"});case"iiiii":return r.day(i,{width:"narrow",context:"formatting"});case"iiiiii":return r.day(i,{width:"short",context:"formatting"});case"iiii":default:return r.day(i,{width:"wide",context:"formatting"})}},a:function(t,n,r){var i=t.getUTCHours(),s=i/12>=1?"pm":"am";switch(n){case"a":case"aa":return r.dayPeriod(s,{width:"abbreviated",context:"formatting"});case"aaa":return r.dayPeriod(s,{width:"abbreviated",context:"formatting"}).toLowerCase();case"aaaaa":return r.dayPeriod(s,{width:"narrow",context:"formatting"});case"aaaa":default:return r.dayPeriod(s,{width:"wide",context:"formatting"})}},b:function(t,n,r){var i=t.getUTCHours(),s;switch(i===12?s=ym.noon:i===0?s=ym.midnight:s=i/12>=1?"pm":"am",n){case"b":case"bb":return r.dayPeriod(s,{width:"abbreviated",context:"formatting"});case"bbb":return r.dayPeriod(s,{width:"abbreviated",context:"formatting"}).toLowerCase();case"bbbbb":return r.dayPeriod(s,{width:"narrow",context:"formatting"});case"bbbb":default:return r.dayPeriod(s,{width:"wide",context:"formatting"})}},B:function(t,n,r){var i=t.getUTCHours(),s;switch(i>=17?s=ym.evening:i>=12?s=ym.afternoon:i>=4?s=ym.morning:s=ym.night,n){case"B":case"BB":case"BBB":return r.dayPeriod(s,{width:"abbreviated",context:"formatting"});case"BBBBB":return r.dayPeriod(s,{width:"narrow",context:"formatting"});case"BBBB":default:return r.dayPeriod(s,{width:"wide",context:"formatting"})}},h:function(t,n,r){if(n==="ho"){var i=t.getUTCHours()%12;return i===0&&(i=12),r.ordinalNumber(i,{unit:"hour"})}return Wh.h(t,n)},H:function(t,n,r){return n==="Ho"?r.ordinalNumber(t.getUTCHours(),{unit:"hour"}):Wh.H(t,n)},K:function(t,n,r){var i=t.getUTCHours()%12;return n==="Ko"?r.ordinalNumber(i,{unit:"hour"}):Ei(i,n.length)},k:function(t,n,r){var i=t.getUTCHours();return i===0&&(i=24),n==="ko"?r.ordinalNumber(i,{unit:"hour"}):Ei(i,n.length)},m:function(t,n,r){return n==="mo"?r.ordinalNumber(t.getUTCMinutes(),{unit:"minute"}):Wh.m(t,n)},s:function(t,n,r){return n==="so"?r.ordinalNumber(t.getUTCSeconds(),{unit:"second"}):Wh.s(t,n)},S:function(t,n){return Wh.S(t,n)},X:function(t,n,r,i){var s=i._originalDate||t,c=s.getTimezoneOffset();if(c===0)return"Z";switch(n){case"X":return tR(c);case"XXXX":case"XX":return Vf(c);case"XXXXX":case"XXX":default:return Vf(c,":")}},x:function(t,n,r,i){var s=i._originalDate||t,c=s.getTimezoneOffset();switch(n){case"x":return tR(c);case"xxxx":case"xx":return Vf(c);case"xxxxx":case"xxx":default:return Vf(c,":")}},O:function(t,n,r,i){var s=i._originalDate||t,c=s.getTimezoneOffset();switch(n){case"O":case"OO":case"OOO":return"GMT"+eR(c,":");case"OOOO":default:return"GMT"+Vf(c,":")}},z:function(t,n,r,i){var s=i._originalDate||t,c=s.getTimezoneOffset();switch(n){case"z":case"zz":case"zzz":return"GMT"+eR(c,":");case"zzzz":default:return"GMT"+Vf(c,":")}},t:function(t,n,r,i){var s=i._originalDate||t,c=Math.floor(s.getTime()/1e3);return Ei(c,n.length)},T:function(t,n,r,i){var s=i._originalDate||t,c=s.getTime();return Ei(c,n.length)}};function eR(e,t){var n=e>0?"-":"+",r=Math.abs(e),i=Math.floor(r/60),s=r%60;if(s===0)return n+String(i);var c=t||"";return n+String(i)+c+Ei(s,2)}function tR(e,t){if(e%60===0){var n=e>0?"-":"+";return n+Ei(Math.abs(e)/60,2)}return Vf(e,t)}function Vf(e,t){var n=t||"",r=e>0?"-":"+",i=Math.abs(e),s=Ei(Math.floor(i/60),2),c=Ei(i%60,2);return r+s+n+c}const qce=Gce;var nR=function(t,n){switch(t){case"P":return n.date({width:"short"});case"PP":return n.date({width:"medium"});case"PPP":return n.date({width:"long"});case"PPPP":default:return n.date({width:"full"})}},K4=function(t,n){switch(t){case"p":return n.time({width:"short"});case"pp":return n.time({width:"medium"});case"ppp":return n.time({width:"long"});case"pppp":default:return n.time({width:"full"})}},Wce=function(t,n){var r=t.match(/(P+)(p+)?/)||[],i=r[1],s=r[2];if(!s)return nR(t,n);var c;switch(i){case"P":c=n.dateTime({width:"short"});break;case"PP":c=n.dateTime({width:"medium"});break;case"PPP":c=n.dateTime({width:"long"});break;case"PPPP":default:c=n.dateTime({width:"full"});break}return c.replace("{{date}}",nR(i,n)).replace("{{time}}",K4(s,n))},Hce={p:K4,P:Wce};const _C=Hce;var Yce=["D","DD"],Zce=["YY","YYYY"];function Q4(e){return Yce.indexOf(e)!==-1}function J4(e){return Zce.indexOf(e)!==-1}function kx(e,t,n){if(e==="YYYY")throw new RangeError("Use `yyyy` instead of `YYYY` (in `".concat(t,"`) for formatting years to the input `").
vendor: 8,389 bytes, line 1434
1434concat(n,"`; see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md"));if(e==="YY")throw new RangeError("Use `yy` instead of `YY` (in `".concat(t,"`) for formatting years to the input `").concat(n,"`; see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md"));if(e==="D")throw new RangeError("Use `d` instead of `D` (in `".concat(t,"`) for formatting days of the month to the input `").concat(n,"`; see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md"));if(e==="DD")throw new RangeError("Use `dd` instead of `DD` (in `".concat(t,"`) for formatting days of the month to the input `").concat(n,"`; see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md"))}var Xce={lessThanXSeconds:{one:"less than a second",other:"less than {{count}} seconds"},xSeconds:{one:"1 second",other:"{{count}} seconds"},halfAMinute:"half a minute",lessThanXMinutes:{one:"less than a minute",other:"less than {{count}} minutes"},xMinutes:{one:"1 minute",other:"{{count}} minutes"},aboutXHours:{one:"about 1 hour",other:"about {{count}} hours"},xHours:{one:"1 hour",other:"{{count}} hours"},xDays:{one:"1 day",other:"{{count}} days"},aboutXWeeks:{one:"about 1 week",other:"about {{count}} weeks"},xWeeks:{one:"1 week",other:"{{count}} weeks"},aboutXMonths:{one:"about 1 month",other:"about {{count}} months"},xMonths:{one:"1 month",other:"{{count}} months"},aboutXYears:{one:"about 1 year",other:"about {{count}} years"},xYears:{one:"1 year",other:"{{count}} years"},overXYears:{one:"over 1 year",other:"over {{count}} years"},almostXYears:{one:"almost 1 year",other:"almost {{count}} years"}},Kce=function(t,n,r){var i,s=Xce[t];return typeof s=="string"?i=s:n===1?i=s.one:i=s.other.replace("{{count}}",n.toString()),r!=null&&r.addSuffix?r.comparison&&r.comparison>0?"in "+i:i+" ago":i};const Qce=Kce;function cE(e){return function(){var t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},n=t.width?String(t.width):e.defaultWidth,r=e.formats[n]||e.formats[e.defaultWidth];return r}}var Jce={full:"EEEE, MMMM do, y",long:"MMMM do, y",medium:"MMM d, y",short:"MM/dd/yyyy"},eue={full:"h:mm:ss a zzzz",long:"h:mm:ss a z",medium:"h:mm:ss a",short:"h:mm a"},tue={full:"{{date}} 'at' {{time}}",long:"{{date}} 'at' {{time}}",medium:"{{date}}, {{time}}",short:"{{date}}, {{time}}"},nue={date:cE({formats:Jce,defaultWidth:"full"}),time:cE({formats:eue,defaultWidth:"full"}),dateTime:cE({formats:tue,defaultWidth:"full"})};const rue=nue;var iue={lastWeek:"'last' eeee 'at' p",yesterday:"'yesterday at' p",today:"'today at' p",tomorrow:"'tomorrow at' p",nextWeek:"eeee 'at' p",other:"P"},oue=function(t,n,r,i){return iue[t]};const aue=oue;function Yy(e){return function(t,n){var r=n!=null&&n.context?String(n.context):"standalone",i;if(r==="formatting"&&e.formattingValues){var s=e.defaultFormattingWidth||e.defaultWidth,c=n!=null&&n.width?String(n.width):s;i=e.formattingValues[c]||e.formattingValues[s]}else{var a=e.defaultWidth,m=n!=null&&n.width?String(n.width):e.defaultWidth;i=e.values[m]||e.values[a]}var g=e.argumentCallback?e.argumentCallback(t):t;return i[g]}}var sue={narrow:["B","A"],abbreviated:["BC","AD"],wide:["Before Christ","Anno Domini"]},lue={narrow:["1","2","3","4"],abbreviated:["Q1","Q2","Q3","Q4"],wide:["1st quarter","2nd quarter","3rd quarter","4th quarter"]},cue={narrow:["J","F","M","A","M","J","J","A","S","O","N","D"],abbreviated:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],wide:["January","February","March","April","May","June","July","August","September","October","November","December"]},uue={narrow:["S","M","T","W","T","F","S"],short:["Su","Mo","Tu","We","Th","Fr","Sa"],abbreviated:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],wide:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"]},hue={narrow:{am:"a",pm:"p",midnight:"mi",noon:"n",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},abbreviated:{am:"AM",pm:"PM",midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},wide:{am:"a.m.",pm:"p.m.",midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"}},due={narrow:{am:"a",pm:"p",midnight:"mi",noon:"n",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"},abbreviated:{am:"AM",pm:"PM",midnight:"midnight",noon:"noon",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"},wide:{am:"a.m.",pm:"p.m.",midnight:"midnight",noon:"noon",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"}},fue=function(t,n){var r=Number(t),i=r%100;if(i>20||i<10)switch(i%10){case 1:return r+"st";case 2:return r+"nd";case 3:return r+"rd"}return r+"th"},pue={ordinalNumber:fue,era:Yy({values:sue,defaultWidth:"wide"}),quarter:Yy({values:lue,defaultWidth:"wide",argumentCallback:function(t){return t-1}}),month:Yy({values:cue,defaultWidth:"wide"}),day:Yy({values:uue,defaultWidth:"wide"}),dayPeriod:Yy({values:hue,defaultWidth:"wide",formattingValues:due,defaultFormattingWidth:"wide"})};const mue=pue;function Zy(e){return function(t){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},r=n.width,i=r&&e.matchPatterns[r]||e.matchPatterns[e.defaultMatchWidth],s=t.match(i);if(!s)return null;var c=s[0],a=r&&e.parsePatterns[r]||e.parsePatterns[e.defaultParseWidth],m=Array.isArray(a)?yue(a,function(T){return T.test(c)}):gue(a,function(T){return T.test(c)}),g;g=e.valueCallback?e.valueCallback(m):m,g=n.valueCallback?n.valueCallback(g):g;var x=t.slice(c.length);return{value:g,rest:x}}}function gue(e,t){for(var n in e)if(e.hasOwnProperty(n)&&t(e[n]))return n}function yue(e,t){for(var n=0;n<e.length;n++)if(t(e[n]))return n}function _ue(e){return function(t){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},r=t.match(e.matchPattern);if(!r)return null;var i=r[0],s=t.match(e.parsePattern);if(!s)return null;var c=e.valueCallback?e.valueCallback(s[0]):s[0];c=n.valueCallback?n.valueCallback(c):c;var a=t.slice(i.length);return{value:c,rest:a}}}var vue=/^(\d+)(th|st|nd|rd)?/i,bue=/\d+/i,xue={narrow:/^(b|a)/i,abbreviated:/^(b\.?\s?c\.?|b\.?\s?c\.?\s?e\.?|a\.?\s?d\.?|c\.?\s?e\.?)/i,wide:/^(before christ|before common era|anno domini|common era)/i},wue={any:[/^b/i,/^(a|c)/i]},Tue={narrow:/^[1234]/i,abbreviated:/^q[1234]/i,wide:/^[1234](th|st|nd|rd)? quarter/i},Eue={any:[/1/i,/2/i,/3/i,/4/i]},Sue={narrow:/^[jfmasond]/i,abbreviated:/^(jan|feb|mar|apr|may|jun|jul|aug|sep|oct|nov|dec)/i,wide:/^(january|february|march|april|may|june|july|august|september|october|november|december)/i},Cue={narrow:[/^j/i,/^f/i,/^m/i,/^a/i,/^m/i,/^j/i,/^j/i,/^a/i,/^s/i,/^o/i,/^n/i,/^d/i],any:[/^ja/i,/^f/i,/^mar/i,/^ap/i,/^may/i,/^jun/i,/^jul/i,/^au/i,/^s/i,/^o/i,/^n/i,/^d/i]},kue={narrow:/^[smtwf]/i,short:/^(su|mo|tu|we|th|fr|sa)/i,abbreviated:/^(sun|mon|tue|wed|thu|fri|sat)/i,wide:/^(sunday|monday|tuesday|wednesday|thursday|friday|saturday)/i},Aue={narrow:[/^s/i,/^m/i,/^t/i,/^w/i,/^t/i,/^f/i,/^s/i],any:[/^su/i,/^m/i,/^tu/i,/^w/i,/^th/i,/^f/i,/^sa/i]},Pue={narrow:/^(a|p|mi|n|(in the|at) (morning|afternoon|evening|night))/i,any:/^([ap]\.?\s?m\.?|midnight|noon|(in the|at) (morning|afternoon|evening|night))/i},Mue={any:{am:/^a/i,pm:/^p/i,midnight:/^mi/i,noon:/^no/i,morning:/morning/i,afternoon:/afternoon/i,evening:/evening/i,night:/night/i}},Iue={ordinalNumber:_ue({matchPattern:vue,parsePattern:bue,valueCallback:function(t){return parseInt(t,10)}}),era:Zy({matchPatterns:xue,defaultMatchWidth:"wide",parsePatterns:wue,defaultParseWidth:"any"}),quarter:Zy({matchPatterns:Tue,defaultMatchWidth:"wide",parsePatterns:Eue,defaultParseWidth:"any",valueCallback:function(t){return t+1}}),month:Zy({matchPatterns:Sue,defaultMatchWidth:"wide",parsePatterns:Cue,defaultParseWidth:"any"}),day:Zy({matchPatterns:kue,defaultMatchWidth:"wide",parsePatterns:Aue,defaultParseWidth:"any"}),dayPeriod:Zy({matchPatterns:Pue,defaultMatchWidth:"any",parsePatterns:Mue,defaultParseWidth:"any"})};const Oue=Iue;var Due={code:"en-US",formatDistance:Qce,formatLong:rue,formatRelative:aue,localize:mue,match:Oue,options:{weekStartsOn:0,firstWeekContainsDate:1}};const e$=Due;var Lue=/[yYQqMLwIdDecihHKkms]o|(\w)\1*|''|'(''|[^'])+('|$)|./g,Rue=/P+p+|P+|p+|''|'(''|[^'])+('|$)|./g,Fue=/^'([^]*?)'?$/,Bue=/''/g,zue=/[a-zA-Z]/;
1434function cp(e,t,n){var r,i,s,c,a,m,g,x,T,C,A,P,D,B,R,N,j,U;Vn(2,arguments);var W=String(t),Q=bu(),Z=(r=(i=n==null?void 0:n.locale)!==null&&i!==void 0?i:Q.locale)!==null&&r!==void 0?r:e$,K=ir((s=(c=(a=(m=n==null?void 0:n.firstWeekContainsDate)!==null&&m!==void 0?m:n==null||(g=n.locale)===null||g===void 0||(x=g.options)===null||x===void 0?void 0:x.firstWeekContainsDate)!==null&&a!==void 0?a:Q.firstWeekContainsDate)!==null&&c!==void 0?c:(T=Q.locale)===null||T===void 0||(C=T.options)===null||C===void 0?void 0:C.firstWeekContainsDate)!==null&&s!==void 0?s:1);if(!(K>=1&&K<=7))throw new RangeError("firstWeekContainsDate must be between 1 and 7 inclusively");var Y=ir((A=(P=(D=(B=n==null?void 0:n.weekStartsOn)!==null&&B!==void 0?B:n==null||(R=n.locale)===null||R===void 0||(N=R.options)===null||N===void 0?void 0:N.weekStartsOn)!==null&&D!==void 0?D:Q.weekStartsOn)!==null&&P!==void 0?P:(j=Q.locale)===null||j===void 0||(U=j.options)===null||U===void 0?void 0:U.weekStartsOn)!==null&&A!==void 0?A:0);if(!(Y>=0&&Y<=6))throw new RangeError("weekStartsOn must be between 0 and 6 inclusively");if(!Z.localize)throw new RangeError("locale must contain localize property");if(!Z.formatLong)throw new RangeError("locale must contain formatLong property");var me=ar(e);if(!S_(me))throw new RangeError("Invalid time value");var ge=Cx(me),ce=H4(me,ge),fe={firstWeekContainsDate:K,weekStartsOn:Y,locale:Z,_originalDate:me},ie=W.match(Rue).map(function(xe){var Te=xe[0];if(Te==="p"||Te==="P"){var oe=_C[Te];return oe(xe,Z.formatLong)}return xe}).join("").match(Lue).map(function(xe){if(xe==="''")return"'";var Te=xe[0];if(Te==="'")return Nue(xe);var oe=qce[Te];if(oe)return!(n!=null&&n.useAdditionalWeekYearTokens)&&J4(xe)&&kx(xe,t,String(e)),!(n!=null&&n.useAdditionalDayOfYearTokens)&&Q4(xe)&&kx(xe,t,String(e)),oe(ce,xe,Z.localize,fe);if(Te.match(zue))throw new RangeError("Format string contains an unescaped latin alphabet character `"+Te+"`");return xe}).join("");return ie}function Nue(e){var t=e.match(Fue);return t?t[1].replace(Bue,"'"):e}function $ue(e,t){if(e==null)throw new TypeError("assign requires that input parameter not be null or undefined");for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n]);return e}function jue(e){Vn(1,arguments);var t=ar(e),n=t.getDay();return n}function Uue(e){Vn(1,arguments);var t=ar(e),n=t.getFullYear(),r=t.getMonth(),i=new Date(0);return i.setFullYear(n,r+1,0),i.setHours(0,0,0,0),i.getDate()}function fu(e){Vn(1,arguments);var t=ar(e),n=t.getHours();return n}var Vue=6048e5;function Gue(e){Vn(1,arguments);var t=ar(e),n=Sx(t).getTime()-Oce(t).getTime();return Math.round(n/Vue)+1}function pu(e){Vn(1,arguments);var t=ar(e),n=t.getMinutes();return n}function mi(e){Vn(1,arguments);var t=ar(e),n=t.getMonth();return n}function gg(e){Vn(1,arguments);var t=ar(e),n=t.getSeconds();return n}function que(e,t){var n,r,i,s,c,a,m,g;Vn(1,arguments);var x=ar(e),T=x.getFullYear(),C=bu(),A=ir((n=(r=(i=(s=t==null?void 0:t.firstWeekContainsDate)!==null&&s!==void 0?s:t==null||(c=t.locale)===null||c===void 0||(a=c.options)===null||a===void 0?void 0:a.firstWeekContainsDate)!==null&&i!==void 0?i:C.firstWeekContainsDate)!==null&&r!==void 0?r:(m=C.locale)===null||m===void 0||(g=m.options)===null||g===void 0?void 0:g.firstWeekContainsDate)!==null&&n!==void 0?n:1);if(!(A>=1&&A<=7))throw new RangeError("firstWeekContainsDate must be between 1 and 7 inclusively");var P=new Date(0);P.setFullYear(T+1,0,A),P.setHours(0,0,0,0);var D=yp(P,t),B=new Date(0);B.setFullYear(T,0,A),B.setHours(0,0,0,0);var R=yp(B,t);return x.getTime()>=D.getTime()?T+1:x.getTime()>=R.getTime()?T:T-1}function Wue(e,t){var n,r,i,s,c,a,m,g;Vn(1,arguments);var x=bu(),T=ir((n=(r=(i=(s=t==null?void 0:t.firstWeekContainsDate)!==null&&s!==void 0?s:t==null||(c=t.locale)===null||c===void 0||(a=c.options)===null||a===void 0?void 0:a.firstWeekContainsDate)!==null&&i!==void 0?i:x.firstWeekContainsDate)!==null&&r!==void 0?r:(m=x.locale)===null||m===void 0||(g=m.options)===null||g===void 0?void 0:g.firstWeekContainsDate)!==null&&n!==void 0?n:1),C=que(e,t),A=new Date(0);A.setFullYear(C,0,T),A.setHours(0,0,0,0);var P=yp(A,t);return P}var Hue=6048e5;function Yue(e,t){Vn(1,arguments);var n=ar(e),r=yp(n,t).getTime()-Wue(n,t).getTime();return Math.round(r/Hue)+1}function ai(e){return Vn(1,arguments),ar(e).getFullYear()}function tv(e,t){Vn(2,arguments);var n=ar(e),r=ar(t);return n.getTime()>r.getTime()}function nv(e,t){Vn(2,arguments);var n=ar(e),r=ar(t);return n.getTime()<r.getTime()}
1434function Om(e,t){Vn(2,arguments);var n=ar(e),r=ar(t);return n.getTime()===r.getTime()}function rR(e,t){(t==null||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}function Zue(e,t){if(e){if(typeof e=="string")return rR(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);if(n==="Object"&&e.constructor&&(n=e.constructor.name),n==="Map"||n==="Set")return Array.from(e);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return rR(e,t)}}function iR(e,t){var n=typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(!n){if(Array.isArray(e)||(n=Zue(e))||t&&e&&typeof e.length=="number"){n&&(e=n);var r=0,i=function(){};return{s:i,n:function(){return r>=e.length?{done:!0}:{done:!1,value:e[r++]}},e:function(g){throw g},f:i}}throw new TypeError(`Invalid attempt to iterate non-iterable instance.
1435In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}var s=!0,c=!1,a;return{s:function(){n=n.call(e)},n:function(){var g=n.next();return s=g.done,g},e:function(g){c=!0,a=g},f:function(){try{!s&&n.return!=null&&n.return()}finally{if(c)throw a}}}}function Ln(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}
1435function vC(e,t){return vC=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,i){return r.__proto__=i,r},vC(e,t)}function Xr(e,t){if(typeof t!="function"&&t!==null)throw new TypeError("Super expression must either be null or a function");e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,writable:!0,configurable:!0}}),Object.defineProperty(e,"prototype",{writable:!1}),t&&vC(e,t)}function Ax(e){return Ax=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(n){return n.__proto__||Object.getPrototypeOf(n)},Ax(e)}function Xue(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}function Kue(e,t){if(t&&(Zl(t)==="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return Ln(e)}function Kr(e){var t=Xue();return function(){var r=Ax(e),i;if(t){var s=Ax(this).constructor;i=Reflect.construct(r,arguments,s)}else i=r.apply(this,arguments);return Kue(this,i)}}function Ur(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Que(e,t){if(Zl(e)!=="object"||e===null)return e;var n=e[Symbol.toPrimitive];if(n!==void 0){var r=n.call(e,t||"default");if(Zl(r)!=="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function t$(e){var t=Que(e,"string");return Zl(t)==="symbol"?t:String(t)}function oR(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,t$(r.key),r)}}function Vr(e,t,n){return t&&oR(e.prototype,t),n&&oR(e,n),Object.defineProperty(e,"prototype",{writable:!1}),e}function kn(e,t,n){return t=t$(t),t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var Jue=10,n$=function(){function e(){Ur(this,e),kn(this,"priority",void 0),kn(this,"subPriority",0)}return Vr(e,[{key:"validate",value:function(n,r){return!0}}]),e}(),ehe=function(e){Xr(n,e);var t=Kr(n);function n(r,i,s,c,a){var m;return Ur(this,n),m=t.call(this),m.value=r,m.validateValue=i,m.setValue=s,m.priority=c,a&&(m.subPriority=a),m}return Vr(n,[{key:"validate",value:function(i,s){return this.validateValue(i,this.value,s)}},{key:"set",value:function(i,s,c){return this.setValue(i,s,this.value,c)}}]),n}(n$),the=function(e){Xr(n,e);var t=Kr(n);function n(){var r;Ur(this,n);for(var i=arguments.length,s=new Array(i),c=0;c<i;c++)s[c]=arguments[c];return r=t.call.apply(t,[this].concat(s)),kn(Ln(r),"priority",Jue),kn(Ln(r),"subPriority",-1),r}return Vr(n,[{key:"set",value:function(i,s){if(s.timestampIsSet)return i;var c=new Date(0);return c.setFullYear(i.getUTCFullYear(),i.getUTCMonth(),i.getUTCDate()),c.setHours(i.getUTCHours(),i.getUTCMinutes(),i.getUTCSeconds(),i.getUTCMilliseconds()),c}}]),n}(n$),yi=function(){function e(){Ur(this,e),kn(this,"incompatibleTokens",void 0),kn(this,"priority",void 0),kn(this,"subPriority",void 0)}return Vr(e,[{key:"run",value:function(n,r,i,s){var c=this.parse(n,r,i,s);return c?{setter:new ehe(c.value,this.validate,this.set,this.priority,this.subPriority),rest:c.rest}:null}},{key:"validate",value:function(n,r,i){return!0}}]),e}(),nhe=function(e){Xr(n,e);var t=Kr(n);function n(){var r;Ur(this,n);for(var i=arguments.length,s=new Array(i),c=0;c<i;c++)s[c]=arguments[c];return r=t.call.apply(t,[this].concat(s)),kn(Ln(r),"priority",140),kn(Ln(r),"incompatibleTokens",["R","u","t","T"]),r}return Vr(n,[{key:"parse",value:function(i,s,c){switch(s){case"G":case"GG":case"GGG":return c.era(i,{width:"abbreviated"})||c.era(i,{width:"narrow"});case"GGGGG":return c.era(i,{width:"narrow"});case"GGGG":default:return c.era(i,{width:"wide"})||c.era(i,{width:"abbreviated"})||c.era(i,{width:"narrow"})}}},{key:"set",value:function(i,s,c){return s.era=c,i.setUTCFullYear(c,0,1),i.setUTCHours(0,0,0,0),i}}]),n}(yi),jo={month:/^(1[0-2]|0?\d)/,date:/^(3[0-1]|[0-2]?\d)/,dayOfYear:/^(36[0-6]|3[0-5]\d|[0-2]?\d?\d)/,week:/^(5[0-3]|[0-4]?\d)/,hour23h:/^(2[0-3]|[0-1]?\d)/,hour24h:/^(2[0-4]|[0-1]?\d)/,hour11h:/^(1[0-1]|0?\d)/,hour12h:/^(1[0-2]|0?\d)/,minute:/^[0-5]?\d/,second:/^[0-5]?\d/,singleDigit:/^\d/,twoDigits:/^\d{1,2}/,threeDigits:/^\d{1,3}/,fourDigits:/^\d{1,4}/,anyDigitsSigned:/^-?\d+/,singleDigitSigned:/^-?\d/,twoDigitsSigned:/^-?\d{1,2}/,threeDigitsSigned:/^-?\d{1,3}/,fourDigitsSigned:/^-?\d{1,4}/}
vendor: 27,417 bytes, line 1435
1435,au={basicOptionalMinutes:/^([+-])(\d{2})(\d{2})?|Z/,basic:/^([+-])(\d{2})(\d{2})|Z/,basicOptionalSeconds:/^([+-])(\d{2})(\d{2})((\d{2}))?|Z/,extended:/^([+-])(\d{2}):(\d{2})|Z/,extendedOptionalSeconds:/^([+-])(\d{2}):(\d{2})(:(\d{2}))?|Z/};function Uo(e,t){return e&&{value:t(e.value),rest:e.rest}}function Co(e,t){var n=t.match(e);return n?{value:parseInt(n[0],10),rest:t.slice(n[0].length)}:null}function su(e,t){var n=t.match(e);if(!n)return null;if(n[0]==="Z")return{value:0,rest:t.slice(1)};var r=n[1]==="+"?1:-1,i=n[2]?parseInt(n[2],10):0,s=n[3]?parseInt(n[3],10):0,c=n[5]?parseInt(n[5],10):0;return{value:r*(i*N2+s*z2+c*Rce),rest:t.slice(n[0].length)}}function r$(e){return Co(jo.anyDigitsSigned,e)}function Fo(e,t){switch(e){case 1:return Co(jo.singleDigit,t);case 2:return Co(jo.twoDigits,t);case 3:return Co(jo.threeDigits,t);case 4:return Co(jo.fourDigits,t);default:return Co(new RegExp("^\\d{1,"+e+"}"),t)}}function Px(e,t){switch(e){case 1:return Co(jo.singleDigitSigned,t);case 2:return Co(jo.twoDigitsSigned,t);case 3:return Co(jo.threeDigitsSigned,t);case 4:return Co(jo.fourDigitsSigned,t);default:return Co(new RegExp("^-?\\d{1,"+e+"}"),t)}}function j2(e){switch(e){case"morning":return 4;case"evening":return 17;case"pm":case"noon":case"afternoon":return 12;case"am":case"midnight":case"night":default:return 0}}function i$(e,t){var n=t>0,r=n?t:1-t,i;if(r<=50)i=e||100;else{var s=r+50,c=Math.floor(s/100)*100,a=e>=s%100;i=e+c-(a?100:0)}return n?i:1-i}function o$(e){return e%400===0||e%4===0&&e%100!==0}var rhe=function(e){Xr(n,e);var t=Kr(n);function n(){var r;Ur(this,n);for(var i=arguments.length,s=new Array(i),c=0;c<i;c++)s[c]=arguments[c];return r=t.call.apply(t,[this].concat(s)),kn(Ln(r),"priority",130),kn(Ln(r),"incompatibleTokens",["Y","R","u","w","I","i","e","c","t","T"]),r}return Vr(n,[{key:"parse",value:function(i,s,c){var a=function(g){return{year:g,isTwoDigitYear:s==="yy"}};switch(s){case"y":return Uo(Fo(4,i),a);case"yo":return Uo(c.ordinalNumber(i,{unit:"year"}),a);default:return Uo(Fo(s.length,i),a)}}},{key:"validate",value:function(i,s){return s.isTwoDigitYear||s.year>0}},{key:"set",value:function(i,s,c){var a=i.getUTCFullYear();if(c.isTwoDigitYear){var m=i$(c.year,a);return i.setUTCFullYear(m,0,1),i.setUTCHours(0,0,0,0),i}var g=!("era"in s)||s.era===1?c.year:1-c.year;return i.setUTCFullYear(g,0,1),i.setUTCHours(0,0,0,0),i}}]),n}(yi),ihe=function(e){Xr(n,e);var t=Kr(n);function n(){var r;Ur(this,n);for(var i=arguments.length,s=new Array(i),c=0;c<i;c++)s[c]=arguments[c];return r=t.call.apply(t,[this].concat(s)),kn(Ln(r),"priority",130),kn(Ln(r),"incompatibleTokens",["y","R","u","Q","q","M","L","I","d","D","i","t","T"]),r}return Vr(n,[{key:"parse",value:function(i,s,c){var a=function(g){return{year:g,isTwoDigitYear:s==="YY"}};switch(s){case"Y":return Uo(Fo(4,i),a);case"Yo":return Uo(c.ordinalNumber(i,{unit:"year"}),a);default:return Uo(Fo(s.length,i),a)}}},{key:"validate",value:function(i,s){return s.isTwoDigitYear||s.year>0}},{key:"set",value:function(i,s,c,a){var m=$2(i,a);if(c.isTwoDigitYear){var g=i$(c.year,m);return i.setUTCFullYear(g,0,a.firstWeekContainsDate),i.setUTCHours(0,0,0,0),_p(i,a)}var x=!("era"in s)||s.era===1?c.year:1-c.year;return i.setUTCFullYear(x,0,a.firstWeekContainsDate),i.setUTCHours(0,0,0,0),_p(i,a)}}]),n}(yi),ohe=function(e){Xr(n,e);var t=Kr(n);function n(){var r;Ur(this,n);for(var i=arguments.length,s=new Array(i),c=0;c<i;c++)s[c]=arguments[c];return r=t.call.apply(t,[this].concat(s)),kn(Ln(r),"priority",130),kn(Ln(r),"incompatibleTokens",["G","y","Y","u","Q","q","M","L","w","d","D","e","c","t","T"]),r}return Vr(n,[{key:"parse",value:function(i,s){return Px(s==="R"?4:s.length,i)}},{key:"set",value:function(i,s,c){var a=new Date(0);return a.setUTCFullYear(c,0,4),a.setUTCHours(0,0,0,0),mg(a)}}]),n}(yi),ahe=function(e){Xr(n,e);var t=Kr(n);function n(){var r;Ur(this,n);for(var i=arguments.length,s=new Array(i),c=0;c<i;c++)s[c]=arguments[c];return r=t.call.apply(t,[this].concat(s)),kn(Ln(r),"priority",130),kn(Ln(r),"incompatibleTokens",["G","y","Y","R","w","I","i","e","c","t","T"]),r}return Vr(n,[{key:"parse",value:function(i,s){return Px(s==="u"?4:s.length,i)}},{key:"set",value:function(i,s,c){return i.setUTCFullYear(c,0,1),i.setUTCHours(0,0,0,0),i}}]),n}(yi),she=function(e){Xr(n,e);var t=Kr(n);function n(){var r;Ur(this,n);for(var i=arguments.length,s=new Array(i),c=0;c<i;c++)s[c]=arguments[c];return r=t.call.apply(t,[this].concat(s)),kn(Ln(r),"priority",120),kn(Ln(r),"incompatibleTokens",["Y","R","q","M","L","w","I","d","D","i","e","c","t","T"]),r}return Vr(n,[{key:"parse",value:function(i,s,c){switch(s){case"Q":case"QQ":return Fo(s.length,i);case"Qo":return c.ordinalNumber(i,{unit:"quarter"});case"QQQ":return c.quarter(i,{width:"abbreviated",context:"formatting"})||c.quarter(i,{width:"narrow",context:"formatting"});case"QQQQQ":return c.quarter(i,{width:"narrow",context:"formatting"});case"QQQQ":default:return c.quarter(i,{width:"wide",context:"formatting"})||c.quarter(i,{width:"abbreviated",context:"formatting"})||c.quarter(i,{width:"narrow",context:"formatting"})}}},{key:"validate",value:function(i,s){return s>=1&&s<=4}},{key:"set",value:function(i,s,c){return i.setUTCMonth((c-1)*3,1),i.setUTCHours(0,0,0,0),i}}]),n}(yi),lhe=function(e){Xr(n,e);var t=Kr(n);function n(){var r;Ur(this,n);for(var i=arguments.length,s=new Array(i),c=0;c<i;c++)s[c]=arguments[c];return r=t.call.apply(t,[this].concat(s)),kn(Ln(r),"priority",120),kn(Ln(r),"incompatibleTokens",["Y","R","Q","M","L","w","I","d","D","i","e","c","t","T"]),r}return Vr(n,[{key:"parse",value:function(i,s,c){switch(s){case"q":case"qq":return Fo(s.length,i);case"qo":return c.ordinalNumber(i,{unit:"quarter"});case"qqq":return c.quarter(i,{width:"abbreviated",context:"standalone"})||c.quarter(i,{width:"narrow",context:"standalone"});case"qqqqq":return c.quarter(i,{width:"narrow",context:"standalone"});case"qqqq":default:return c.quarter(i,{width:"wide",context:"standalone"})||c.quarter(i,{width:"abbreviated",context:"standalone"})||c.quarter(i,{width:"narrow",context:"standalone"})}}},{key:"validate",value:function(i,s){return s>=1&&s<=4}},{key:"set",value:function(i,s,c){return i.setUTCMonth((c-1)*3,1),i.setUTCHours(0,0,0,0),i}}]),n}(yi),che=function(e){Xr(n,e);var t=Kr(n);function n(){var r;Ur(this,n);for(var i=arguments.length,s=new Array(i),c=0;c<i;c++)s[c]=arguments[c];return r=t.call.apply(t,[this].concat(s)),kn(Ln(r),"incompatibleTokens",["Y","R","q","Q","L","w","I","D","i","e","c","t","T"]),kn(Ln(r),"priority",110),r}return Vr(n,[{key:"parse",value:function(i,s,c){var a=function(g){return g-1};switch(s){case"M":return Uo(Co(jo.month,i),a);case"MM":return Uo(Fo(2,i),a);case"Mo":return Uo(c.ordinalNumber(i,{unit:"month"}),a);case"MMM":return c.month(i,{width:"abbreviated",context:"formatting"})||c.month(i,{width:"narrow",context:"formatting"});case"MMMMM":return c.month(i,{width:"narrow",context:"formatting"});case"MMMM":default:return c.month(i,{width:"wide",context:"formatting"})||c.month(i,{width:"abbreviated",context:"formatting"})||c.month(i,{width:"narrow",context:"formatting"})}}},{key:"validate",value:function(i,s){return s>=0&&s<=11}},{key:"set",value:function(i,s,c){return i.setUTCMonth(c,1),i.setUTCHours(0,0,0,0),i}}]),n}(yi),uhe=function(e){Xr(n,e);var t=Kr(n);function n(){var r;Ur(this,n);for(var i=arguments.length,s=new Array(i),c=0;c<i;c++)s[c]=arguments[c];return r=t.call.apply(t,[this].concat(s)),kn(Ln(r),"priority",110),kn(Ln(r),"incompatibleTokens",["Y","R","q","Q","M","w","I","D","i","e","c","t","T"]),r}return Vr(n,[{key:"parse",value:function(i,s,c){var a=function(g){return g-1};switch(s){case"L":return Uo(Co(jo.month,i),a);case"LL":return Uo(Fo(2,i),a);case"Lo":return Uo(c.ordinalNumber(i,{unit:"month"}),a);case"LLL":return c.month(i,{width:"abbreviated",context:"standalone"})||c.month(i,{width:"narrow",context:"standalone"});case"LLLLL":return c.month(i,{width:"narrow",context:"standalone"});case"LLLL":default:return c.month(i,{width:"wide",context:"standalone"})||c.month(i,{width:"abbreviated",context:"standalone"})||c.month(i,{width:"narrow",context:"standalone"})}}},{key:"validate",value:function(i,s){return s>=0&&s<=11}},{key:"set",value:function(i,s,c){return i.setUTCMonth(c,1),i.setUTCHours(0,0,0,0),i}}]),n}(yi);function hhe(e,t,n){Vn(2,arguments);var r=ar(e),i=ir(t),s=X4(r,n)-i;return r.setUTCDate(r.getUTCDate()-s*7),r}var dhe=function(e){Xr(n,e);var t=Kr(n);function n(){var r;Ur(this,n);for(var i=arguments.length,s=new Array(i),c=0;c<i;c++)s[c]=arguments[c];return r=t.call.apply(t,[this].concat(s)),kn(Ln(r),"priority",100),kn(Ln(r),"incompatibleTokens",["y","R","u","q","Q","M","L","I","d","D","i","t","T"]),r}return Vr(n,[{key:"parse",value:function(i,s,c){switch(s){case"w":return Co(jo.week,i);case"wo":return c.ordinalNumber(i,{unit:"week"});default:return Fo(s.length,i)}}},{key:"validate",value:function(i,s){return s>=1&&s<=53}},{key:"set",value:function(i,s,c,a){return _p(hhe(i,c,a),a)}}]),n}(yi);function fhe(e,t){Vn(2,arguments);var n=ar(e),r=ir(t),i=Z4(n)-r;return n.setUTCDate(n.getUTCDate()-i*7),n}var phe=function(e){Xr(n,e);var t=Kr(n);function n(){var r;Ur(this,n);for(var i=arguments.length,s=new Array(i),c=0;c<i;c++)s[c]=arguments[c];return r=t.call.apply(t,[this].concat(s)),kn(Ln(r),"priority",100),kn(Ln(r),"incompatibleTokens",["y","Y","u","q","Q","M","L","w","d","D","e","c","t","T"]),r}return Vr(n,[{key:"parse",value:function(i,s,c){switch(s){case"I":return Co(jo.week,i);case"Io":return c.ordinalNumber(i,{unit:"week"});default:return Fo(s.length,i)}}},{key:"validate",value:function(i,s){return s>=1&&s<=53}},{key:"set",value:function(i,s,c){return mg(fhe(i,c))}}]),n}(yi),mhe=[31,28,31,30,31,30,31,31,30,31,30,31],ghe=[31,29,31,30,31,30,31,31,30,31,30,31],yhe=function(e){Xr(n,e);var t=Kr(n);function n(){var r;Ur(this,n);for(var i=arguments.length,s=new Array(i),c=0;c<i;c++)s[c]=arguments[c];return r=t.call.apply(t,[this].concat(s)),kn(Ln(r),"priority",90),kn(Ln(r),"subPriority",1),kn(Ln(r),"incompatibleTokens",["Y","R","q","Q","w","I","D","i","e","c","t","T"]),r}return Vr(n,[{key:"parse",value:function(i,s,c){switch(s){case"d":return Co(jo.date,i);case"do":return c.ordinalNumber(i,{unit:"date"});default:return Fo(s.length,i)}}},{key:"validate",value:function(i,s){var c=i.getUTCFullYear(),a=o$(c),m=i.getUTCMonth();return a?s>=1&&s<=ghe[m]:s>=1&&s<=mhe[m]}},{key:"set",value:function(i,s,c){return i.setUTCDate(c),i.setUTCHours(0,0,0,0),i}}]),n}(yi),_he=function(e){Xr(n,e);var t=Kr(n);function n(){var r;Ur(this,n);for(var i=arguments.length,s=new Array(i),c=0;c<i;c++)s[c]=arguments[c];return r=t.call.apply(t,[this].concat(s)),kn(Ln(r),"priority",90),kn(Ln(r),"subpriority",1),kn(Ln(r),"incompatibleTokens",["Y","R","q","Q","M","L","w","I","d","E","i","e","c","t","T"]),r}return Vr(n,[{key:"parse",value:function(i,s,c){switch(s){case"D":case"DD":return Co(jo.dayOfYear,i);case"Do":return c.ordinalNumber(i,{unit:"date"});default:return Fo(s.length,i)}}},{key:"validate",value:function(i,s){var c=i.getUTCFullYear(),a=o$(c);return a?s>=1&&s<=366:s>=1&&s<=365}},{key:"set",value:function(i,s,c){return i.setUTCMonth(0,c),i.setUTCHours(0,0,0,0),i}}]),n}(yi);function U2(e,t,n){var r,i,s,c,a,m,g,x;Vn(2,arguments);var T=bu(),C=ir((r=(i=(s=(c=n==null?void 0:n.weekStartsOn)!==null&&c!==void 0?c:n==null||(a=n.locale)===null||a===void 0||(m=a.options)===null||m===void 0?void 0:m.weekStartsOn)!==null&&s!==void 0?s:T.weekStartsOn)!==null&&i!==void 0?i:(g=T.locale)===null||g===void 0||(x=g.options)===null||x===void 0?void 0:x.weekStartsOn)!==null&&r!==void 0?r:0);if(!(C>=0&&C<=6))throw new RangeError("weekStartsOn must be between 0 and 6 inclusively");var A=ar(e),P=ir(t),D=A.getUTCDay(),B=P%7,R=(B+7)%7,N=(R<C?7:0)+P-D;return A.setUTCDate(A.getUTCDate()+N),A}var vhe=function(e){Xr(n,e);var t=Kr(n);function n(){var r;Ur(this,n);for(var i=arguments.length,s=new Array(i),c=0;c<i;c++)s[c]=arguments[c];return r=t.call.apply(t,[this].concat(s)),kn(Ln(r),"priority",90),kn(Ln(r),"incompatibleTokens",["D","i","e","c","t","T"]),r}return Vr(n,[{key:"parse",value:function(i,s,c){switch(s){case"E":case"EE":case"EEE":return c.day(i,{width:"abbreviated",context:"formatting"})||c.day(i,{width:"short",context:"formatting"})||c.day(i,{width:"narrow",context:"formatting"});case"EEEEE":return c.day(i,{width:"narrow",context:"formatting"});case"EEEEEE":return c.day(i,{width:"short",context:"formatting"})||c.day(i,{width:"narrow",context:"formatting"});case"EEEE":default:return c.day(i,{width:"wide",context:"formatting"})||c.day(i,{width:"abbreviated",context:"formatting"})||c.day(i,{width:"short",context:"formatting"})||c.day(i,{width:"narrow",context:"formatting"})}}},{key:"validate",value:function(i,s){return s>=0&&s<=6}},{key:"set",value:function(i,s,c,a){return i=U2(i,c,a),i.setUTCHours(0,0,0,0),i}}]),n}(yi),bhe=function(e){Xr(n,e);var t=Kr(n);function n(){var r;Ur(this,n);for(var i=arguments.length,s=new Array(i),c=0;c<i;c++)s[c]=arguments[c];return r=t.call.apply(t,[this].concat(s)),kn(Ln(r),"priority",90),kn(Ln(r),"incompatibleTokens",["y","R","u","q","Q","M","L","I","d","D","E","i","c","t","T"]),r}return Vr(n,[{key:"parse",value:function(i,s,c,a){var m=function(x){var T=Math.floor((x-1)/7)*7;return(x+a.weekStartsOn+6)%7+T};switch(s){case"e":case"ee":return Uo(Fo(s.length,i),m);case"eo":return Uo(c.ordinalNumber(i,{unit:"day"}),m);case"eee":return c.day(i,{width:"abbreviated",context:"formatting"})||c.day(i,{width:"short",context:"formatting"})||c.day(i,{width:"narrow",context:"formatting"});case"eeeee":return c.day(i,{width:"narrow",context:"formatting"});case"eeeeee":return c.day(i,{width:"short",context:"formatting"})||c.day(i,{width:"narrow",context:"formatting"});case"eeee":default:return c.day(i,{width:"wide",context:"formatting"})||c.day(i,{width:"abbreviated",context:"formatting"})||c.day(i,{width:"short",context:"formatting"})||c.day(i,{width:"narrow",context:"formatting"})}}},{key:"validate",value:function(i,s){return s>=0&&s<=6}},{key:"set",value:function(i,s,c,a){return i=U2(i,c,a),i.setUTCHours(0,0,0,0),i}}]),n}(yi),xhe=function(e){Xr(n,e);var t=Kr(n);function n(){var r;Ur(this,n);for(var i=arguments.length,s=new Array(i),c=0;c<i;c++)s[c]=arguments[c];return r=t.call.apply(t,[this].concat(s)),kn(Ln(r),"priority",90),kn(Ln(r),"incompatibleTokens",["y","R","u","q","Q","M","L","I","d","D","E","i","e","t","T"]),r}return Vr(n,[{key:"parse",value:function(i,s,c,a){var m=function(x){var T=Math.floor((x-1)/7)*7;return(x+a.weekStartsOn+6)%7+T};switch(s){case"c":case"cc":return Uo(Fo(s.length,i),m);case"co":return Uo(c.ordinalNumber(i,{unit:"day"}),m);case"ccc":return c.day(i,{width:"abbreviated",context:"standalone"})||c.day(i,{width:"short",context:"standalone"})||c.day(i,{width:"narrow",context:"standalone"});case"ccccc":return c.day(i,{width:"narrow",context:"standalone"});case"cccccc":return c.day(i,{width:"short",context:"standalone"})||c.day(i,{width:"narrow",context:"standalone"});case"cccc":default:return c.day(i,{width:"wide",context:"standalone"})||c.day(i,{width:"abbreviated",context:"standalone"})||c.day(i,{width:"short",context:"standalone"})||c.day(i,{width:"narrow",context:"standalone"})}}},{key:"validate",value:function(i,s){return s>=0&&s<=6}},{key:"set",value:function(i,s,c,a){return i=U2(i,c,a),i.setUTCHours(0,0,0,0),i}}]),n}(yi);function whe(e,t){Vn(2,arguments);var n=ir(t);n%7===0&&(n=n-7);var r=1,i=ar(e),s=i.getUTCDay(),c=n%7,a=(c+7)%7,m=(a<r?7:0)+n-s;return i.setUTCDate(i.getUTCDate()+m),i}var The=function(e){Xr(n,e);var t=Kr(n);function n(){var r;Ur(this,n);for(var i=arguments.length,s=new Array(i),c=0;c<i;c++)s[c]=arguments[c];return r=t.call.apply(t,[this].concat(s)),kn(Ln(r),"priority",90),kn(Ln(r),"incompatibleTokens",["y","Y","u","q","Q","M","L","w","d","D","E","e","c","t","T"]),r}return Vr(n,[{key:"parse",value:function(i,s,c){var a=function(g){return g===0?7:g};switch(s){case"i":case"ii":return Fo(s.length,i);case"io":return c.ordinalNumber(i,{unit:"day"});case"iii":return Uo(c.day(i,{width:"abbreviated",context:"formatting"})||c.day(i,{width:"short",context:"formatting"})||c.day(i,{width:"narrow",context:"formatting"}),a);case"iiiii":return Uo(c.day(i,{width:"narrow",context:"formatting"}),a);case"iiiiii":return Uo(c.day(i,{width:"short",context:"formatting"})||c.day(i,{width:"narrow",context:"formatting"}),a);case"iiii":default:return Uo(c.day(i,{width:"wide",context:"formatting"})||c.day(i,{width:"abbreviated",context:"formatting"})||c.day(i,{width:"short",context:"formatting"})||c.day(i,{width:"narrow",context:"formatting"}),a)}}},{key:"validate",value:function(i,s){return s>=1&&s<=7}},{key:"set",value:function(i,s,c){return i=whe(i,c),i.setUTCHours(0,0,0,0),i}}]),n}(yi),Ehe=function(e){Xr(n,e);var t=Kr(n);function n(){var r;Ur(this,n);for(var i=arguments.length,s=new Array(i),c=0;c<i;c++)s[c]=arguments[c];return r=t.call.apply(t,[this].concat(s)),kn(Ln(r),"priority",80),kn(Ln(r),"incompatibleTokens",["b","B","H","k","t","T"]),r}return Vr(n,[{key:"parse",value:function(i,s,c){switch(s){case"a":case"aa":case"aaa":return c.dayPeriod(i,{width:"abbreviated",context:"formatting"})||c.dayPeriod(i,{width:"narrow",context:"formatting"});case"aaaaa":return c.dayPeriod(i,{width:"narrow",context:"formatting"});case"aaaa":default:return c.dayPeriod(i,{width:"wide",context:"formatting"})||c.dayPeriod(i,{width:"abbreviated",context:"formatting"})||c.dayPeriod(i,{width:"narrow",context:"formatting"})}}},{key:"set",value:function(i,s,c){return i.setUTCHours(j2(c),0,0,0),i}}]),n}(yi),She=function(e){Xr(n,e);var t=Kr(n);function n(){var r;Ur(this,n);for(var i=arguments.length,s=new Array(i),c=0;c<i;c++)s[c]=arguments[c];return r=t.call.apply(t,[this].concat(s)),kn(Ln(r),"priority",80),kn(Ln(r),"incompatibleTokens",["a","B","H","k","t","T"]),r}return Vr(n,[{key:"parse",value:function(i,s,c){switch(s){case"b":case"bb":case"bbb":return c.dayPeriod(i,{width:"abbreviated",context:"formatting"})||c.dayPeriod(i,{width:"narrow",context:"formatting"});case"bbbbb":return c.dayPeriod(i,{width:"narrow",context:"formatting"});case"bbbb":default:return c.dayPeriod(i,{width:"wide",context:"formatting"})||c.dayPeriod(i,{width:"abbreviated",context:"formatting"})||c.dayPeriod(i,{width:"narrow",context:"formatting"})}}},{key:"set",value:function(i,s,c){return i.setUTCHours(j2(c),0,0,0),i}}]),n}(yi),Che=function(e){Xr(n,e);var t=Kr(n);function n(){var r;Ur(this,n);for(var i=arguments.length,s=new Array(i),c=0;c<i;c++)s[c]=arguments[c];return r=t.call.apply(t,[this].concat(s)),kn(Ln(r),"priority",80),kn(Ln(r),"incompatibleTokens",["a","b","t","T"]),r}return Vr(n,[{key:"parse",value:function(i,s,c){switch(s){case"B":case"BB":case"BBB":return c.dayPeriod(i,{width:"abbreviated",context:"formatting"})||c.dayPeriod(i,{width:"narrow",context:"formatting"});case"BBBBB":return c.dayPeriod(i,{width:"narrow",context:"formatting"});case"BBBB":default:return c.dayPeriod(i,{width:"wide",context:"formatting"})||c.dayPeriod(i,{width:"abbreviated",context:"formatting"})||c.dayPeriod(i,{width:"narrow",context:"formatting"})}}},{key:"set",value:function(i,s,c){return i.setUTCHours(j2(c),0,0,0),i}}]),n}(yi),khe=function(e){Xr(n,e);var t=Kr(n);function n(){var r;Ur(this,n);for(var i=arguments.length,s=new Array(i),c=0;c<i;c++)s[c]=arguments[c];return r=t.call.apply(t,[this].concat(s)),kn(Ln(r),"priority",70),kn(Ln(r),"incompatibleTokens",["H","K","k","t","T"]),r}return Vr(n,[{key:"parse",value:function(i,s,c){switch(s){case"h":return Co(jo.hour12h,i);case"ho":return c.ordinalNumber(i,{unit:"hour"});default:return Fo(s.length,i)}}},{key:"validate",value:function(i,s){return s>=1&&s<=12}},{key:"set",value:function(i,s,c){var a=i.getUTCHours()>=12;return a&&c<12?i.setUTCHours(c+12,0,0,0):!a&&c===12?i.setUTCHours(0,0,0,0):i.setUTCHours(c,0,0,0),i}}]),n}(yi),Ahe=function(e){Xr(n,e);var t=Kr(n);function n(){var r;Ur(this,n);for(var i=arguments.length,s=new Array(i),c=0;c<i;c++)s[c]=arguments[c];return r=t.call.apply(t,[this].concat(s)),kn(Ln(r),"priority",70),kn(Ln(r),"incompatibleTokens",["a","b","h","K","k","t","T"]),r}return Vr(n,[{key:"parse",value:function(i,s,c){switch(s){case"H":return Co(jo.hour23h,i);case"Ho":return c.ordinalNumber(i,{unit:"hour"});default:return Fo(s.length,i)}}},{key:"validate",value:function(i,s){return s>=0&&s<=23}},{key:"set",value:function(i,s,c){return i.setUTCHours(c,0,0,0),i}}]),n}(yi),Phe=function(e){Xr(n,e);var t=Kr(n);function n(){var r;Ur(this,n);for(var i=arguments.length,s=new Array(i),c=0;c<i;c++)s[c]=arguments[c];return r=t.call.apply(t,[this].concat(s)),kn(Ln(r),"priority",70),kn(Ln(r),"incompatibleTokens",["h","H","k","t","T"]),r}return Vr(n,[{key:"parse",value:function(i,s,c){switch(s){case"K":return Co(jo.hour11h,i);case"Ko":return c.ordinalNumber(i,{unit:"hour"});default:return Fo(s.length,i)}}},{key:"validate",value:function(i,s){return s>=0&&s<=11}},{key:"set",value:function(i,s,c){var a=i.getUTCHours()>=12;return a&&c<12?i.setUTCHours(c+12,0,0,0):i.setUTCHours(c,0,0,0),i}}]),n}(yi),Mhe=function(e){Xr(n,e);var t=Kr(n);function n(){var r;Ur(this,n);for(var i=arguments.length,s=new Array(i),c=0;c<i;c++)s[c]=arguments[c];return r=t.call.apply(t,[this].concat(s)),kn(Ln(r),"priority",70),kn(Ln(r),"incompatibleTokens",["a","b","h","H","K","t","T"]),r}return Vr(n,[{key:"parse",value:function(i,s,c){switch(s){case"k":return Co(jo.hour24h,i);case"ko":return c.ordinalNumber(i,{unit:"hour"});default:return Fo(s.length,i)}}},{key:"validate",value:function(i,s){return s>=1&&s<=24}},{key:"set",value:function(i,s,c){var a=c<=24?c%24:c;return i.setUTCHours(a,0,0,0),i}}]),n}(yi),Ihe=function(e){Xr(n,e);var t=Kr(n);function n(){var r;Ur(this,n);for(var i=arguments.length,s=new Array(i),c=0;c<i;c++)s[c]=arguments[c];return r=t.call.apply(t,[this].concat(s)),kn(Ln(r),"priority",60),kn(Ln(r),"incompatibleTokens",["t","T"]),r}return Vr(n,[{key:"parse",value:function(i,s,c){switch(s){case"m":return Co(jo.minute,i);case"mo":return c.ordinalNumber(i,{unit:"minute"});default:return Fo(s.length,i)}}},{key:"validate",value:function(i,s){return s>=0&&s<=59}},{key:"set",value:function(i,s,c){return i.setUTCMinutes(c,0,0),i}}]),n}(yi),Ohe=function(e){Xr(n,e);var t=Kr(n);function n(){var r;Ur(this,n);for(var i=arguments.length,s=new Array(i),c=0;c<i;c++)s[c]=arguments[c];return r=t.call.apply(t,[this].concat(s)),kn(Ln(r),"priority",50),kn(Ln(r),"incompatibleTokens",["t","T"]),r}return Vr(n,[{key:"parse",value:function(i,s,c){switch(s){case"s":return Co(jo.second,i);case"so":return c.ordinalNumber(i,{unit:"second"});default:return Fo(s.length,i)}}},{key:"validate",value:function(i,s){return s>=0&&s<=59}},{key:"set",value:function(i,s,c){return i.setUTCSeconds(c,0),i}}]),n}(yi),Dhe=function(e){Xr(n,e);var t=Kr(n);function n(){var r;Ur(this,n);for(var i=arguments.length,s=new Array(i),c=0;c<i;c++)s[c]=arguments[c];return r=t.call.apply(t,[this].concat(s)),kn(Ln(r),"priority",30),kn(Ln(r),"incompatibleTokens",["t","T"]),r}return Vr(n,[{key:"parse",value:function(i,s){var c=function(m){return Math.floor(m*Math.pow(10,-s.length+3))};return Uo(Fo(s.length,i),c)}},{key:"set",value:function(i,s,c){return i.setUTCMilliseconds(c),i}}]),n}(yi),Lhe=function(e){Xr(n,e);var t=Kr(n);function n(){var r;Ur(this,n);for(var i=arguments.length,s=new Array(i),c=0;c<i;c++)s[c]=arguments[c];return r=t.call.apply(t,[this].concat(s)),kn(Ln(r),"priority",10),kn(Ln(r),"incompatibleTokens",["t","T","x"]),r}return Vr(n,[{key:"parse",value:function(i,s){switch(s){case"X":return su(au.basicOptionalMinutes,i);case"XX":return su(au.basic,i);case"XXXX":return su(au.basicOptionalSeconds,i);case"XXXXX":return su(au.extendedOptionalSeconds,i);case"XXX":default:return su(au.extended,i)}}},{key:"set",value:function(i,s,c){return s.timestampIsSet?i:new Date(i.getTime()-c)}}]),n}(yi),Rhe=function(e){Xr(n,e);var t=Kr(n);function n(){var r;Ur(this,n);for(var i=arguments.length,s=new Array(i),c=0;c<i;c++)s[c]=arguments[c];return r=t.call.apply(t,[this].concat(s)),kn(Ln(r),"priority",10),kn(Ln(r),"incompatibleTokens",["t","T","X"]),r}return Vr(n,[{key:"parse",value:function(i,s){switch(s){case"x":return su(au.basicOptionalMinutes,i);case"xx":return su(au.basic,i);case"xxxx":return su(au.basicOptionalSeconds,i);case"xxxxx":return su(au.extendedOptionalSeconds,i);case"xxx":default:return su(au.extended,i)}}},{key:"set",value:function(i,s,c){return s.timestampIsSet?i:new Date(i.getTime()-c)}}]),n}(yi),Fhe=function(e){Xr(n,e);var t=Kr(n);function n(){var r;Ur(this,n);for(var i=arguments.length,s=new Array(i),c=0;c<i;c++)s[c]=arguments[c];return r=t.call.apply(t,[this].concat(s)),kn(Ln(r),"priority",40),kn(Ln(r),"incompatibleTokens","*"),r}return Vr(n,[{key:"parse",value:function(i){return r$(i)}},{key:"set",value:function(i,s,c){return[new Date(c*1e3),{timestampIsSet:!0}]}}]),n}(yi),Bhe=function(e){Xr(n,e);var t=Kr(n);function n(){var r;Ur(this,n);for(var i=arguments.length,s=new Array(i),c=0;c<i;c++)s[c]=arguments[c];return r=t.call.apply(t,[this].concat(s)),kn(Ln(r),"priority",20),kn(Ln(r),"incompatibleTokens","*"),r}return Vr(n,[{key:"parse",value:function(i){return r$(i)}},{key:"set",value:function(i,s,c){return[new Date(c),{timestampIsSet:!0}]}}]),n}(yi),zhe={G:new nhe,y:new rhe,Y:new ihe,R:new ohe,u:new ahe,Q:new she,q:new lhe,M:new che,L:new uhe,w:new dhe,I:new phe,d:new yhe,D:new _he,E:new vhe,e:new bhe,c:new xhe,i:new The,a:new Ehe,b:new She,B:new Che,h:new khe,H:new Ahe,K:new Phe,k:new Mhe,m:new Ihe,s:new Ohe,S:new Dhe,X:new Lhe,x:new Rhe,t:new Fhe,T:new Bhe},Nhe=/[yYQqMLwIdDecihHKkms]o|(\w)\1*|''|'(''|[^'])+('|$)|./g,$he=/P+p+|P+|p+|''|'(''|[^'])+('|$)|./g,jhe=/^'([^]*?)'?$/,Uhe=/''/g,Vhe=/\S/,Ghe=/[a-zA-Z]/;function bC(e,t,n,r){var i,s,c,a,m,g,x,T,C,A,P,D,B,R,N,j,U,W;Vn(3,arguments);var Q=String(e),Z=String(t),K=bu(),Y=(i=(s=r==null?void 0:r.locale)!==null&&s!==void 0?s:K.locale)!==null&&i!==void 0?i:e$;if(!Y.match)throw new RangeError("locale must contain match property");var me=ir((c=(a=(m=(g=r==null?void 0:r.firstWeekContainsDate)!==null&&g!==void 0?g:r==null||(x=r.locale)===null||x===void 0||(T=x.options)===null||T===void 0?void 0:T.firstWeekContainsDate)!==null&&m!==void 0?m:K.firstWeekContainsDate)!==null&&a!==void 0?a:(C=K.locale)===null||C===void 0||(A=C.options)===null||A===void 0?void 0:A.firstWeekContainsDate)!==null&&c!==void 0?c:1);if(!(me>=1&&me<=7))throw new RangeError("firstWeekContainsDate must be between 1 and 7 inclusively");var ge=ir((P=(D=(B=(R=r==null?void 0:r.weekStartsOn)!==null&&R!==void 0?R:r==null||(N=r.locale)===null||N===void 0||(j=N.options)===null||j===void 0?void 0:j.weekStartsOn)!==null&&B!==void 0?B:K.weekStartsOn)!==null&&D!==void 0?D:(U=K.locale)===null||U===void 0||(W=U.options)===null||W===void 0?void 0:W.weekStartsOn)!==null&&P!==void 0?P:0);if(!(ge>=0&&ge<=6))throw new RangeError("weekStartsOn must be between 0 and 6 inclusively");if(Z==="")return Q===""?ar(n):new Date(NaN);var ce={firstWeekContainsDate:me,weekStartsOn:ge,locale:Y},fe=[new the],ie=Z.match($he).map(function(st){var tt=st[0];if(tt in _C){var Me=_C[tt];return Me(st,Y.formatLong)}return st}).join("").match(Nhe),xe=[],Te=iR(ie),oe;try{var ne=function(){var tt=oe.value;!(r!=null&&r.useAdditionalWeekYearTokens)&&J4(tt)&&kx(tt,Z,e),!(r!=null&&r.useAdditionalDayOfYearTokens)&&Q4(tt)&&kx(tt,Z,e);var Me=tt[0],lt=zhe[Me];if(lt){var Ae=lt.incompatibleTokens;if(Array.isArray(Ae)){var we=xe.find(function(ct){return Ae.includes(ct.token)||ct.token===Me});
1435if(we)throw new RangeError("The format string mustn't contain `".concat(we.fullToken,"` and `").concat(tt,"` at the same time"))}else if(lt.incompatibleTokens==="*"&&xe.length>0)throw new RangeError("The format string mustn't contain `".concat(tt,"` and any other token at the same time"));xe.push({token:Me,fullToken:tt});var Je=lt.run(Q,tt,Y.match,ce);if(!Je)return{v:new Date(NaN)};fe.push(Je.setter),Q=Je.rest}else{if(Me.match(Ghe))throw new RangeError("Format string contains an unescaped latin alphabet character `"+Me+"`");if(tt==="''"?tt="'":Me==="'"&&(tt=qhe(tt)),Q.indexOf(tt)===0)Q=Q.slice(tt.length);else return{v:new Date(NaN)}}};for(Te.s();!(oe=Te.n()).done;){var le=ne();if(Zl(le)==="object")return le.v}}catch(st){Te.e(st)}finally{Te.f()}if(Q.length>0&&Vhe.test(Q))return new Date(NaN);var se=fe.map(function(st){return st.priority}).sort(function(st,tt){return tt-st}).filter(function(st,tt,Me){return Me.indexOf(st)===tt}).map(function(st){return fe.filter(function(tt){return tt.priority===st}).sort(function(tt,Me){return Me.subPriority-tt.subPriority})}).map(function(st){return st[0]}),Ne=ar(n);if(isNaN(Ne.getTime()))return new Date(NaN);var Se=H4(Ne,Cx(Ne)),xt={},kt=iR(se),wt;try{for(kt.s();!(wt=kt.n()).done;){var Ue=wt.value;if(!Ue.validate(Se,ce))return new Date(NaN);var je=Ue.set(Se,xt,ce);Array.isArray(je)?(Se=je[0],$ue(xt,je[1])):Se=je}}catch(st){kt.e(st)}finally{kt.f()}return Se}function qhe(e){return e.match(jhe)[1].replace(Uhe,"'")}function Whe(e,t){Vn(2,arguments);var n=ir(t);return Xu(e,-n)}function Hhe(e,t){var n;Vn(1,arguments);var r=ir((n=t==null?void 0:t.additionalDigits)!==null&&n!==void 0?n:2);if(r!==2&&r!==1&&r!==0)throw new RangeError("additionalDigits must be 0, 1 or 2");if(!(typeof e=="string"||Object.prototype.toString.call(e)==="[object String]"))return new Date(NaN);var i=Khe(e),s;if(i.date){var c=Qhe(i.date,r);s=Jhe(c.restDateString,c.year)}if(!s||isNaN(s.getTime()))return new Date(NaN);var a=s.getTime(),m=0,g;if(i.time&&(m=ede(i.time),isNaN(m)))return new Date(NaN);if(i.timezone){if(g=tde(i.timezone),isNaN(g))return new Date(NaN)}else{var x=new Date(a+m),T=new Date(0);return T.setFullYear(x.getUTCFullYear(),x.getUTCMonth(),x.getUTCDate()),T.setHours(x.getUTCHours(),x.getUTCMinutes(),x.getUTCSeconds(),x.getUTCMilliseconds()),T}return new Date(a+m+g)}var ub={dateTimeDelimiter:/[T ]/,timeZoneDelimiter:/[Z ]/i,timezone:/([Z+-].*)$/},Yhe=/^-?(?:(\d{3})|(\d{2})(?:-?(\d{2}))?|W(\d{2})(?:-?(\d{1}))?|)$/,Zhe=/^(\d{2}(?:[.,]\d*)?)(?::?(\d{2}(?:[.,]\d*)?))?(?::?(\d{2}(?:[.,]\d*)?))?$/,Xhe=/^([+-])(\d{2})(?::?(\d{2}))?$/;function Khe(e){var t={},n=e.split(ub.dateTimeDelimiter),r;if(n.length>2)return t;if(/:/.test(n[0])?r=n[0]:(t.date=n[0],r=n[1],ub.timeZoneDelimiter.test(t.date)&&(t.date=e.split(ub.timeZoneDelimiter)[0],r=e.substr(t.date.length,e.length))),r){var i=ub.timezone.exec(r);i?(t.time=r.replace(i[1],""),t.timezone=i[1]):t.time=r}return t}function Qhe(e,t){var n=new RegExp("^(?:(\\d{4}|[+-]\\d{"+(4+t)+"})|(\\d{2}|[+-]\\d{"+(2+t)+"})$)"),r=e.match(n);if(!r)return{year:NaN,restDateString:""};var i=r[1]?parseInt(r[1]):null,s=r[2]?parseInt(r[2]):null;return{year:s===null?i:s*100,restDateString:e.slice((r[1]||r[2]).length)}}function Jhe(e,t){if(t===null)return new Date(NaN);var n=e.match(Yhe);if(!n)return new Date(NaN);var r=!!n[4],i=Xy(n[1]),s=Xy(n[2])-1,c=Xy(n[3]),a=Xy(n[4]),m=Xy(n[5])-1;if(r)return ade(t,a,m)?nde(t,a,m):new Date(NaN);var g=new Date(0);return!ide(t,s,c)||!ode(t,i)?new Date(NaN):(g.setUTCFullYear(t,s,Math.max(i,c)),g)}function Xy(e){return e?parseInt(e):1}function ede(e){var t=e.match(Zhe);if(!t)return NaN;var n=uE(t[1]),r=uE(t[2]),i=uE(t[3]);return sde(n,r,i)?n*N2+r*z2+i*1e3:NaN}function uE(e){return e&&parseFloat(e.replace(",","."))||0}function tde(e){if(e==="Z")return 0;var t=e.match(Xhe);if(!t)return 0;var n=t[1]==="+"?-1:1,r=parseInt(t[2]),i=t[3]&&parseInt(t[3])||0;return lde(r,i)?n*(r*N2+i*z2):NaN}function nde(e,t,n){var r=new Date(0);r.setUTCFullYear(e,0,4);var i=r.getUTCDay()||7,s=(t-1)*7+n+1-i;return r.setUTCDate(r.getUTCDate()+s),r}var rde=[31,null,31,30,31,30,31,31,30,31,30,31];function a$(e){return e%400===0||e%4===0&&e%100!==0}function ide(e,t,n){return t>=0&&t<=11&&n>=1&&n<=(rde[t]||(a$(e)?29:28))}function ode(e,t){return t>=1&&t<=(a$(e)?366:365)}function ade(e,t,n){return t>=1&&t<=53&&n>=0&&n<=6}function sde(e,t,n){return e===24?t===0&&n===0:n>=0&&n<60&&t>=0&&t<60&&e>=0&&e<25}function lde(e,t){return t>=0&&t<=59}function s$(e,t){Vn(2,arguments);var n=ar(e),r=ir(t),i=n.getFullYear(),s=n.getDate(),c=new Date(0);c.setFullYear(i,r,15),c.setHours(0,0,0,0);var a=Uue(c);return n.setMonth(r,Math.min(s,a)),n}function ho(e,t){if(Vn(2,arguments),Zl(t)!=="object"||t===null)throw new RangeError("values parameter must be an object");var n=ar(e);return isNaN(n.getTime())?new Date(NaN):(t.year!=null&&n.setFullYear(t.year),t.month!=null&&(n=s$(n,t.month)),t.date!=null&&n.setDate(ir(t.date)),t.hours!=null&&n.setHours(ir(t.hours)),t.minutes!=null&&n.setMinutes(ir(t.minutes)),t.seconds!=null&&n.setSeconds(ir(t.seconds)),t.milliseconds!=null&&n.setMilliseconds(ir(t.milliseconds)),n)}function l$(e,t){Vn(2,arguments);var n=ar(e),r=ir(t);return n.setHours(r),n}function V2(e,t){Vn(2,arguments);var n=ar(e),r=ir(t);return n.setMilliseconds(r),n}function c$(e,t){Vn(2,arguments);var n=ar(e),r=ir(t);return n.setMinutes(r),n}function u$(e,t){Vn(2,arguments);var n=ar(e),r=ir(t);return n.setSeconds(r),n}function up(e,t){Vn(2,arguments);var n=ar(e),r=ir(t);return isNaN(n.getTime())?new Date(NaN):(n.setFullYear(r),n)}function yg(e,t){Vn(2,arguments);
1435var n=ir(t);return du(e,-n)}function cde(e,t){if(Vn(2,arguments),!t||Zl(t)!=="object")return new Date(NaN);var n=t.years?ir(t.years):0,r=t.months?ir(t.months):0,i=t.weeks?ir(t.weeks):0,s=t.days?ir(t.days):0,c=t.hours?ir(t.hours):0,a=t.minutes?ir(t.minutes):0,m=t.seconds?ir(t.seconds):0,g=yg(e,r+n*12),x=Whe(g,s+i*7),T=a+c*60,C=m+T*60,A=C*1e3,P=new Date(x.getTime()-A);return P}function h$(e,t){Vn(2,arguments);var n=ir(t);return B2(e,-n)}function Rv(){return At(),Wt("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",fill:"currentColor","aria-hidden":"true",class:"dp__icon"},[Un("path",{d:"M29.333 8c0-2.208-1.792-4-4-4h-18.667c-2.208 0-4 1.792-4 4v18.667c0 2.208 1.792 4 4 4h18.667c2.208 0 4-1.792 4-4v-18.667zM26.667 8v18.667c0 0.736-0.597 1.333-1.333 1.333 0 0-18.667 0-18.667 0-0.736 0-1.333-0.597-1.333-1.333 0 0 0-18.667 0-18.667 0-0.736 0.597-1.333 1.333-1.333 0 0 18.667 0 18.667 0 0.736 0 1.333 0.597 1.333 1.333z"}),Un("path",{d:"M20 2.667v5.333c0 0.736 0.597 1.333 1.333 1.333s1.333-0.597 1.333-1.333v-5.333c0-0.736-0.597-1.333-1.333-1.333s-1.333 0.597-1.333 1.333z"}),Un("path",{d:"M9.333 2.667v5.333c0 0.736 0.597 1.333 1.333 1.333s1.333-0.597 1.333-1.333v-5.333c0-0.736-0.597-1.333-1.333-1.333s-1.333 0.597-1.333 1.333z"}),Un("path",{d:"M4 14.667h24c0.736 0 1.333-0.597 1.333-1.333s-0.597-1.333-1.333-1.333h-24c-0.736 0-1.333 0.597-1.333 1.333s0.597 1.333 1.333 1.333z"})])}Rv.compatConfig={MODE:3};function d$(){return At(),Wt("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",fill:"currentColor","aria-hidden":"true",class:"dp__icon"},[Un("path",{d:"M23.057 7.057l-16 16c-0.52 0.52-0.52 1.365 0 1.885s1.365 0.52 1.885 0l16-16c0.52-0.52 0.52-1.365 0-1.885s-1.365-0.52-1.885 0z"}),Un("path",{d:"M7.057 8.943l16 16c0.52 0.52 1.365 0.52 1.885 0s0.52-1.365 0-1.885l-16-16c-0.52-0.52-1.365-0.52-1.885 0s-0.52 1.365 0 1.885z"})])}d$.compatConfig={MODE:3};function G2(){return At(),Wt("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",fill:"currentColor","aria-hidden":"true",class:"dp__icon"},[Un("path",{d:"M20.943 23.057l-7.057-7.057c0 0 7.057-7.057 7.057-7.057 0.52-0.52 0.52-1.365 0-1.885s-1.365-0.52-1.885 0l-8 8c-0.521 0.521-0.521 1.365 0 1.885l8 8c0.52 0.52 1.365 0.52 1.885 0s0.52-1.365 0-1.885z"})])}G2.compatConfig={MODE:3};function q2(){return At(),Wt("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",fill:"currentColor","aria-hidden":"true",class:"dp__icon"},[Un("path",{d:"M12.943 24.943l8-8c0.521-0.521 0.521-1.365 0-1.885l-8-8c-0.52-0.52-1.365-0.52-1.885 0s-0.52 1.365 0 1.885l7.057 7.057c0 0-7.057 7.057-7.057 7.057-0.52 0.52-0.52 1.365 0 1.885s1.365 0.52 1.885 0z"})])}q2.compatConfig={MODE:3};function W2(){return At(),Wt("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",fill:"currentColor","aria-hidden":"true",class:"dp__icon"},[Un("path",{d:"M16 1.333c-8.095 0-14.667 6.572-14.667 14.667s6.572 14.667 14.667 14.667c8.095 0 14.667-6.572 14.667-14.667s-6.572-14.667-14.667-14.667zM16 4c6.623 0 12 5.377 12 12s-5.377 12-12 12c-6.623 0-12-5.377-12-12s5.377-12 12-12z"}),Un("path",{d:"M14.667 8v8c0 0.505 0.285 0.967 0.737 1.193l5.333 2.667c0.658 0.329 1.46 0.062 1.789-0.596s0.062-1.46-0.596-1.789l-4.596-2.298c0 0 0-7.176 0-7.176 0-0.736-0.597-1.333-1.333-1.333s-1.333 0.597-1.333 1.333z"})])}W2.compatConfig={MODE:3};function H2(){return At(),Wt("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",fill:"currentColor","aria-hidden":"true",class:"dp__icon"},[Un("path",{d:"M24.943 19.057l-8-8c-0.521-0.521-1.365-0.521-1.885 0l-8 8c-0.52 0.52-0.52 1.365 0 1.885s1.365 0.52 1.885 0l7.057-7.057c0 0 7.057 7.057 7.057 7.057 0.52 0.52 1.365 0.52 1.885 0s0.52-1.365 0-1.885z"})])}H2.compatConfig={MODE:3};function Y2(){return At(),Wt("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",fill:"currentColor","aria-hidden":"true",class:"dp__icon"},[Un("path",{d:"M7.057 12.943l8 8c0.521 0.521 1.365 0.521 1.885 0l8-8c0.52-0.52 0.52-1.365 0-1.885s-1.365-0.52-1.885 0l-7.057 7.057c0 0-7.057-7.057-7.057-7.057-0.52-0.52-1.365-0.52-1.885 0s-0.52 1.365 0 1.885z"})])}Y2.compatConfig={MODE:3};
1435function Z2(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var f$={exports:{}};(function(e){function t(n){return n&&n.__esModule?n:{default:n}}e.exports=t,e.exports.__esModule=!0,e.exports.default=e.exports})(f$);var ude=f$.exports,xC={exports:{}};(function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.default=n;function n(r){if(r===null||r===!0||r===!1)return NaN;var i=Number(r);return isNaN(i)?i:i<0?Math.ceil(i):Math.floor(i)}e.exports=t.default})(xC,xC.exports);var hde=xC.exports;const dde=Z2(hde);var wC={exports:{}};(function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.default=n;function n(r){var i=new Date(Date.UTC(r.getFullYear(),r.getMonth(),r.getDate(),r.getHours(),r.getMinutes(),r.getSeconds(),r.getMilliseconds()));return i.setUTCFullYear(r.getFullYear()),r.getTime()-i.getTime()}e.exports=t.default})(wC,wC.exports);var fde=wC.exports;const aR=Z2(fde);function pde(e,t){var n=_de(t);return n.formatToParts?gde(n,e):yde(n,e)}var mde={year:0,month:1,day:2,hour:3,minute:4,second:5};function gde(e,t){try{for(var n=e.formatToParts(t),r=[],i=0;i<n.length;i++){var s=mde[n[i].type];s>=0&&(r[s]=parseInt(n[i].value,10))}return r}catch(c){if(c instanceof RangeError)return[NaN];throw c}}function yde(e,t){var n=e.format(t).replace(/\u200E/g,""),r=/(\d+)\/(\d+)\/(\d+),? (\d+):(\d+):(\d+)/.exec(n);return[r[3],r[1],r[2],r[4],r[5],r[6]]}var hE={};function _de(e){if(!hE[e]){var t=new Intl.DateTimeFormat("en-US",{hour12:!1,timeZone:"America/New_York",year:"numeric",month:"numeric",day:"2-digit",hour:"2-digit",minute:"2-digit",second:"2-digit"}).format(new Date("2014-06-25T04:00:00.123Z")),n=t==="06/25/2014, 00:00:00"||t==="‎06‎/‎25‎/‎2014‎ ‎00‎:‎00‎:‎00";hE[e]=n?new Intl.DateTimeFormat("en-US",{hour12:!1,timeZone:e,year:"numeric",month:"numeric",day:"2-digit",hour:"2-digit",minute:"2-digit",second:"2-digit"}):new Intl.DateTimeFormat("en-US",{hourCycle:"h23",timeZone:e,year:"numeric",month:"numeric",day:"2-digit",hour:"2-digit",minute:"2-digit",second:"2-digit"})}return hE[e]}function X2(e,t,n,r,i,s,c){var a=new Date(0);return a.setUTCFullYear(e,t,n),a.setUTCHours(r,i,s,c),a}var sR=36e5,vde=6e4,dE={timezone:/([Z+-].*)$/,timezoneZ:/^(Z)$/,timezoneHH:/^([+-]\d{2})$/,timezoneHHMM:/^([+-]\d{2}):?(\d{2})$/};function K2(e,t,n){var r,i;if(!e||(r=dE.timezoneZ.exec(e),r))return 0;var s;if(r=dE.timezoneHH.exec(e),r)return s=parseInt(r[1],10),lR(s)?-(s*sR):NaN;if(r=dE.timezoneHHMM.exec(e),r){s=parseInt(r[1],10);var c=parseInt(r[2],10);return lR(s,c)?(i=Math.abs(s)*sR+c*vde,s>0?-i:i):NaN}if(wde(e)){t=new Date(t||Date.now());var a=n?t:bde(t),m=TC(a,e),g=n?m:xde(t,m,e);return-g}return NaN}function bde(e){return X2(e.getFullYear(),e.getMonth(),e.getDate(),e.getHours(),e.getMinutes(),e.getSeconds(),e.getMilliseconds())}function TC(e,t){var n=pde(e,t),r=X2(n[0],n[1]-1,n[2],n[3]%24,n[4],n[5],0).getTime(),i=e.getTime(),s=i%1e3;return i-=s>=0?s:1e3+s,r-i}function xde(e,t,n){var r=e.getTime(),i=r-t,s=TC(new Date(i),n);if(t===s)return t;i-=s-t;var c=TC(new Date(i),n);return s===c?s:Math.max(s,c)}function lR(e,t){return-23<=e&&e<=23&&(t==null||0<=t&&t<=59)}var cR={};function wde(e){if(cR[e])return!0;try{return new Intl.DateTimeFormat(void 0,{timeZone:e}),cR[e]=!0,!0}catch{return!1}}var p$=/(Z|[+-]\d{2}(?::?\d{2})?| UTC| [a-zA-Z]+\/[a-zA-Z_]+(?:\/[a-zA-Z_]+)?)$/,fE=36e5,uR=6e4,Tde=2,gs={dateTimePattern:/^([0-9W+-]+)(T| )(.*)/,datePattern:/^([0-9W+-]+)(.*)/,plainTime:/:/,YY:/^(\d{2})$/,YYY:[/^([+-]\d{2})$/,/^([+-]\d{3})$/,/^([+-]\d{4})$/],YYYY:/^(\d{4})/,YYYYY:[/^([+-]\d{4})/,/^([+-]\d{5})/,/^([+-]\d{6})/],MM:/^-(\d{2})$/,DDD:/^-?(\d{3})$/,MMDD:/^-?(\d{2})-?(\d{2})$/,Www:/^-?W(\d{2})$/,WwwD:/^-?W(\d{2})-?(\d{1})$/,HH:/^(\d{2}([.,]\d*)?)$/,HHMM:/^(\d{2}):?(\d{2}([.,]\d*)?)$/,HHMMSS:/^(\d{2}):?(\d{2}):?(\d{2}([.,]\d*)?)$/,timeZone:p$};function EC(e,t){if(arguments.length<1)throw new TypeError("1 argument required, but only "+arguments.length+" present");if(e===null)return new Date(NaN);var n=t||{},r=n.additionalDigits==null?Tde:dde(n.additionalDigits);if(r!==2&&r!==1&&r!==0)throw new RangeError("additionalDigits must be 0, 1 or 2");if(e instanceof Date||typeof e=="object"&&Object.prototype.toString.call(e)==="[object Date]")return new Date(e.getTime());if(typeof e=="number"||Object.prototype.toString.call(e)==="[object Number]")return new Date(e);if(!(typeof e=="string"||Object.prototype.toString.call(e)==="[object String]"))return new Date(NaN);var i=Ede(e),s=Sde(i.date,r),c=s.year,a=s.restDateString,m=Cde(a,c);if(isNaN(m))return new Date(NaN);if(m){var g=m.getTime(),x=0,T;if(i.time&&(x=kde(i.time),isNaN(x)))return new Date(NaN);if(i.timeZone||n.timeZone){if(T=K2(i.timeZone||n.timeZone,new Date(g+x)),isNaN(T))return new Date(NaN)}else T=aR(new Date(g+x)),T=aR(new Date(g+x+T));return new Date(g+x+T)}else return new Date(NaN)}function Ede(e){var t={},n=gs.dateTimePattern.exec(e),r;if(n?(t.date=n[1],r=n[3]):(n=gs.datePattern.exec(e),n?(t.date=n[1],r=n[2]):(t.date=null,r=e)),r){var i=gs.timeZone.exec(r);i?(t.time=r.replace(i[1],""),t.timeZone=i[1].trim()):t.time=r}return t}function Sde(e,t){var n=gs.YYY[t],r=gs.YYYYY[t],i;if(i=gs.YYYY.exec(e)||r.exec(e),i){var s=i[1];return{year:parseInt(s,10),restDateString:e.slice(s.length)}}if(i=gs.YY.exec(e)||n.exec(e),i){var c=i[1];return{year:parseInt(c,10)*100,restDateString:e.slice(c.length)}}return{year:null}}function Cde(e,t){if(t===null)return null;var n,r,i,s;if(e.length===0)return r=new Date(0),r.setUTCFullYear(t),r;if(n=gs.MM.exec(e),n)return r=new Date(0),i=parseInt(n[1],10)-1,dR(t,i)?(r.setUTCFullYear(t,i),r):new Date(NaN);if(n=gs.DDD.exec(e),n){r=new Date(0);var c=parseInt(n[1],10);return Mde(t,c)?(r.setUTCFullYear(t,0,c),r):new Date(NaN)}if(n=gs.MMDD.exec(e),n){r=new Date(0),i=parseInt(n[1],10)-1;var a=parseInt(n[2],10);return dR(t,i,a)?(r.setUTCFullYear(t,i,a),r):new Date(NaN)}if(n=gs.Www.exec(e),n)return s=parseInt(n[1],10)-1,fR(t,s)?hR(t,s):new Date(NaN);if(n=gs.WwwD.exec(e),n){s=parseInt(n[1],10)-1;var m=parseInt(n[2],10)-1;return fR(t,s,m)?hR(t,s,m):new Date(NaN)}return null}function kde(e){var t,n,r;if(t=gs.HH.exec(e),t)return n=parseFloat(t[1].replace(",",".")),pE(n)?n%24*fE:NaN;if(t=gs.HHMM.exec(e),t)return n=parseInt(t[1],10),r=parseFloat(t[2].replace(",",".")),pE(n,r)?n%24*fE+r*uR:NaN;if(t=gs.HHMMSS.exec(e),t){n=parseInt(t[1],10),r=parseInt(t[2],10);var i=parseFloat(t[3].replace(",","."));return pE(n,r,i)?n%24*fE+r*uR+i*1e3:NaN}return null}
1435function hR(e,t,n){t=t||0,n=n||0;var r=new Date(0);r.setUTCFullYear(e,0,4);var i=r.getUTCDay()||7,s=t*7+n+1-i;return r.setUTCDate(r.getUTCDate()+s),r}var Ade=[31,28,31,30,31,30,31,31,30,31,30,31],Pde=[31,29,31,30,31,30,31,31,30,31,30,31];function m$(e){return e%400===0||e%4===0&&e%100!==0}function dR(e,t,n){if(t<0||t>11)return!1;if(n!=null){if(n<1)return!1;var r=m$(e);if(r&&n>Pde[t]||!r&&n>Ade[t])return!1}return!0}function Mde(e,t){if(t<1)return!1;var n=m$(e);return!(n&&t>366||!n&&t>365)}function fR(e,t,n){return!(t<0||t>52||n!=null&&(n<0||n>6))}function pE(e,t,n){return!(e!=null&&(e<0||e>=25)||t!=null&&(t<0||t>=60)||n!=null&&(n<0||n>=60))}var SC={exports:{}},CC={exports:{}};(function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.default=n;function n(r,i){if(r==null)throw new TypeError("assign requires that input parameter not be null or undefined");for(var s in i)Object.prototype.hasOwnProperty.call(i,s)&&(r[s]=i[s]);return r}e.exports=t.default})(CC,CC.exports);var Ide=CC.exports;(function(e,t){var n=ude.default;Object.defineProperty(t,"__esModule",{value:!0}),t.default=i;var r=n(Ide);function i(s){return(0,r.default)({},s)}e.exports=t.default})(SC,SC.exports);var Ode=SC.exports;const Dde=Z2(Ode);function Lde(e,t,n){var r=EC(e,n),i=K2(t,r,!0),s=new Date(r.getTime()-i),c=new Date(0);return c.setFullYear(s.getUTCFullYear(),s.getUTCMonth(),s.getUTCDate()),c.setHours(s.getUTCHours(),s.getUTCMinutes(),s.getUTCSeconds(),s.getUTCMilliseconds()),c}function Rde(e,t,n){if(typeof e=="string"&&!e.match(p$)){var r=Dde(n);return r.timeZone=t,EC(e,r)}var i=EC(e,n),s=X2(i.getFullYear(),i.getMonth(),i.getDate(),i.getHours(),i.getMinutes(),i.getSeconds(),i.getMilliseconds()).getTime(),c=K2(t,new Date(s));return new Date(s+c)}function pR(e){return t=>new Intl.DateTimeFormat(e,{weekday:"short",timeZone:"UTC"}).format(new Date(`2017-01-0${t}T00:00:00+00:00`)).slice(0,2)}function Fde(e){return t=>cp(new Date(`2017-01-0${t}T00:00:00+00:00`),"EEEEEE",{locale:e})}const Bde=(e,t,n)=>{const r=[1,2,3,4,5,6,7];let i;if(e!==null)try{i=r.map(Fde(e))}catch{i=r.map(pR(t))}else i=r.map(pR(t));const s=i.slice(0,n),c=i.slice(n+1,i.length);return[i[n]].concat(...c).concat(...s)},Q2=(e,t)=>{const n=[];for(let r=+e[0];r<=+e[1];r++)n.push({value:+r,text:`${r}`});return t?n.reverse():n},g$=(e,t,n)=>{const r=[1,2,3,4,5,6,7,8,9,10,11,12].map(s=>{const c=s<10?`0${s}`:s;return new Date(`2017-${c}-01T00:00:00+00:00`)});if(e!==null)try{const s=n==="long"?"MMMM":"MMM";return r.map((c,a)=>{const m=cp(c,s,{locale:e});return{text:m.charAt(0).toUpperCase()+m.substring(1),value:a}})}catch{}const i=new Intl.DateTimeFormat(t,{month:n,timeZone:"UTC"});return r.map((s,c)=>{const a=i.format(s);return{text:a.charAt(0).toUpperCase()+a.substring(1),value:c}})},zde=e=>[12,1,2,3,4,5,6,7,8,9,10,11,12,1,2,3,4,5,6,7,8,9,10,11][e],ca=e=>{const t=bt(e);return t!=null&&t.$el?t==null?void 0:t.$el:t},Nde=e=>Object.assign({type:"dot"},e),y$=e=>Array.isArray(e)?!!e[0]&&!!e[1]:!1,Mx={prop:e=>`"${e}" prop must be enabled!`,dateArr:e=>`You need to use array as "model-value" binding in order to support "${e}"`},ba=e=>e,mR=e=>e===0?e:!e||isNaN(+e)?null:+e,gR=e=>e===null,$de=e=>{if(e)return[...e.querySelectorAll("input, button, select, textarea, a[href]")][0]},jde=e=>{const t=[],n=r=>r.filter(i=>i);for(let r=0;r<e.length;r+=3){const i=[e[r],e[r+1],e[r+2]];t.push(n(i))}return t},rv=(e,t,n)=>{const r=n??n===0,i=t??t===0;if(!r&&!i)return!1;const s=+n,c=+t;return r&&i?+e>s||+e<c:r?+e>s:i?+e<c:!1},_g=(e,t)=>jde(e).map(n=>n.map(r=>{const{active:i,disabled:s,isBetween:c}=t(r);return{...r,active:i,disabled:s,className:{dp__overlay_cell_active:i,dp__overlay_cell:!i,dp__overlay_cell_disabled:s,dp__overlay_cell_pad:!0,dp__overlay_cell_active_disabled:s&&i,dp__cell_in_between:c}}})),yR=(e,t,n,r,i)=>{const s=bC(e,t.slice(0,e.length),new Date);return S_(s)&&q4(s)?r||i?s:ho(s,{hours:+n.hours,minutes:+(n==null?void 0:n.minutes),seconds:+(n==null?void 0:n.seconds),milliseconds:0}):null},Ude=(e,t,n,r,i)=>{const s=Array.isArray(n)?n[0]:n;if(typeof t=="string")return yR(e,t,s,r,i);if(Array.isArray(t)){let c=null;for(const a of t)if(c=yR(e,a,s,r,i),c)break;return c}return typeof t=="function"?t(e):null},an=e=>e?new Date(e):new Date,Vde=(e,t,n)=>{if(t){const i=(e.getMonth()+1).toString().padStart(2,"0"),s=e.getDate().toString().padStart(2,"0"),c=e.getHours().toString().padStart(2,"0"),a=e.getMinutes().toString().padStart(2,"0"),m=n?e.getSeconds().toString().padStart(2,"0"):"00";return`${e.getFullYear()}-${i}-${s}T${c}:${a}:${m}.000Z`}const r=Date.UTC(e.getUTCFullYear(),e.getUTCMonth(),e.getUTCDate(),e.getUTCHours(),e.getUTCMinutes(),e.getUTCSeconds());return new Date(r).toISOString()},Xl=e=>{let t=an(JSON.parse(JSON.stringify(e)));return t=l$(t,0),t=c$(t,0),t=u$(t,0),t=V2(t,0),t},xd=(e,t,n,r)=>{let i=e?an(e):an();return(t||t===0)&&(i=l$(i,+t)),(n||n===0)&&(i=c$(i,+n)),(r||r===0)&&(i=u$(i,+r)),V2(i,
14350)},za=(e,t)=>!e||!t?!1:nv(Xl(e),Xl(t)),ki=(e,t)=>!e||!t?!1:Om(Xl(e),Xl(t)),es=(e,t)=>!e||!t?!1:tv(Xl(e),Xl(t)),J2=(e,t,n)=>e!=null&&e[0]&&e!=null&&e[1]?es(n,e[0])&&za(n,e[1]):e!=null&&e[0]&&t?es(n,e[0])&&za(n,t)||za(n,e[0])&&es(n,t):!1,Sc=e=>{const t=ho(new Date(e),{date:1});return Xl(t)},mE=(e,t,n)=>t&&(n||n===0)?Object.fromEntries(["hours","minutes","seconds"].map(r=>r===t?[r,n]:[r,isNaN(+e[r])?void 0:+e[r]])):{hours:isNaN(+e.hours)?void 0:+e.hours,minutes:isNaN(+e.minutes)?void 0:+e.minutes,seconds:isNaN(+e.seconds)?void 0:+e.seconds},hp=e=>({hours:fu(e),minutes:pu(e),seconds:gg(e)}),_$=(e,t)=>{if(t){const n=ai(an(t));if(n>e)return 12;if(n===e)return mi(an(t))}},v$=(e,t)=>{if(t){const n=ai(an(t));return n<e?-1:n===e?mi(an(t)):void 0}},vg=e=>{if(e)return ai(an(e))},uu=(e,t)=>t?Lde(e,t):e,Gde=(e,t)=>t?Rde(e,t):e,_R=e=>e instanceof Date?e:Hhe(e),b$=(e,t)=>{const n=es(e,t)?t:e,r=es(t,e)?t:e;return W4({start:n,end:r})},qde=e=>{const t=du(e,1);return{month:mi(t),year:ai(t)}},Rb=(e,t,n)=>{const r=yp(uu(e,t),{weekStartsOn:+n}),i=Fce(uu(e,t),{weekStartsOn:+n});return[r,i]},x$=(e,t)=>
1435{const n={hours:fu(an()),minutes:pu(an()),seconds:t?gg(an()):0};return Object.assign(n,e)},ud=(e,t,n)=>[ho(an(e),{date:1}),ho(an(),{month:t,year:n,date:1})],Ju=(e,t,n)=>{let r=e?an(e):an();return(t||t===0)&&(r=s$(r,t)),n&&(r=up(r,n)),r},w$=(e,t,n,r,i)=>{if(!r||i&&!t||!i&&!n)return!1;const s=i?du(e,1):yg(e,1),c=[mi(s),ai(s)];return i?!Hde(...c,t):!Wde(...c,n)},Wde=(e,t,n)=>za(...ud(n,e,t))||ki(...ud(n,e,t)),Hde=(e,t,n)=>es(...ud(n,e,t))||ki(...ud(n,e,t)),T$=(e,t,n,r,i,s)=>{if(typeof t=="function")return t(e);const c=n?{locale:n}:void 0;return Array.isArray(e)?`${cp(e[0],s,c)}${i&&!e[1]?"":r}${e[1]?cp(e[1],s,c):""}`:cp(e,s,c)},_m=e=>{if(e)return null;throw new Error(Mx.prop("partial-range"))},hb=(e,t)=>{if(t)return e();throw new Error(Mx.prop("range"))},kC=e=>Array.isArray(e)?S_(e[0])&&(e[1]?S_(e[1]):!0):e?S_(e):!1,Yde=e=>ho(an(),{hours:+e.hours||0,minutes:+e.minutes||0,seconds:+e.seconds||0}),gE=(e,t,n,r)=>{if(!e)return!0;if(r){const i=n==="max"?nv(e,t):tv(e,t),s={seconds:0,milliseconds:0};return i||Om(ho(e,s),ho(t,s))}return n==="max"?e.getTime()<=t.getTime():e.getTime()>=t.getTime()},vR=(e,t,n,r,i)=>{const s=e?Yde(e):an(t);return Array.isArray(r)?gE(r[0],s,n,!!t)&&gE(r[1],s,n,!!t)&&i:gE(r,s,n,!!t)&&i},yE=e=>ho(an(),hp(e)),Zde=(e,t)=>Array.isArray(e)?e.map(n=>an(n)).filter(n=>ai(an(n))===t).map(n=>mi(n)):[],Ky=so({menuFocused:!1,shiftKeyInMenu:!1}),E$=()=>{const e=n=>{Ky.menuFocused=n},t=n=>{Ky.shiftKeyInMenu!==n&&(Ky.shiftKeyInMenu=n)};return{control:yt(()=>({shiftKeyInMenu:Ky.shiftKeyInMenu,menuFocused:Ky.menuFocused})),setMenuFocused:e,setShiftKey:t}},no=so({monthYear:[],calendar:[],time:[],actionRow:[],selectionGrid:[],timePicker:{0:[],1:[]},monthPicker:[]}),_E=jt(null),db=jt(!1),vE=jt(!1),bE=jt(!1),xE=jt(!1),hs=jt(0),La=jt(0),$d=()=>{const e=yt(()=>db.value?[...no.selectionGrid,no.actionRow].filter(T=>T.length):vE.value?[...no.timePicker[0],...no.timePicker[1],xE.value?[]:[_E.value],no.actionRow].filter(T=>T.length):bE.value?[...no.monthPicker,no.actionRow]:[no.monthYear,...no.calendar,no.time,no.actionRow].filter(T=>T.length)),t=T=>{hs.value=T?hs.value+1:hs.value-1;let C=null;e.value[La.value]&&(C=e.value[La.value][hs.value]),C||(hs.value=T?hs.value-1:hs.value+1)},n=T=>{La.value===0&&!T||La.value===e.value.length&&T||(La.value=T?La.value+1:La.value-1,e.value[La.value]?e.value[La.value]&&!e.value[La.value][hs.value]&&hs.value!==0&&(hs.value=e.value[La.value].length-1):La.value=T?La.value-1:La.value+1)},r=T=>{let C=null;e.value[La.value]&&(C=e.value[La.value][hs.value]),C?C.focus({preventScroll:!db.value}):hs.value=T?hs.value-1:hs.value+1},i=()=>{t(!0),r(!0)},s=()=>{t(!1),r(!1)},c=()=>{n(!1),r(!0)},a=()=>{n(!0),r(!0)},m=(T,C)=>{no[C]=T},g=(T,C)=>{no[C]=T},x=()=>{hs.value=0,La.value=0};return{buildMatrix:m,buildMultiLevelMatrix:g,setTimePickerBackRef:T=>{_E.value=T},setSelectionGrid:T=>{db.value=T,x(),T||(no.selectionGrid=[])},setTimePicker:(T,C=!1)=>{vE.value=T,xE.value=C,x(),T||(no.timePicker[0]=[],no.timePicker[1]=[])},setTimePickerElements:(T,C=0)=>{no.timePicker[C]=T},arrowRight:i,arrowLeft:s,arrowUp:c,arrowDown:a,clearArrowNav:()=>{no.monthYear=[],no.calendar=[],no.time=[],no.actionRow=[],no.selectionGrid=[],no.timePicker[0]=[],no.timePicker[1]=[],db.value=!1,vE.value=!1,xE.value=!1,bE.value=!1,x(),_E.value=null},setMonthPicker:T=>{bE.value=T,x()},refSets:no}},bR=e=>({menuAppearTop:"dp-menu-appear-top",menuAppearBottom:"dp-menu-appear-bottom",open:"dp-slide-down",close:"dp-slide-up",next:"calendar-next",previous:"calendar-prev",vNext:"dp-slide-up",vPrevious:"dp-slide-down",...e??{}}),Xde=e=>({toggleOverlay:"Toggle overlay",menu:"Datepicker menu",input:"Datepicker input",calendarWrap:"Calendar wrapper",calendarDays:"Calendar days",openTimePicker:"Open time picker",closeTimePicker:"Close time Picker",incrementValue:t=>`Increment ${t}`,decrementValue:t=>`Decrement ${t}`,openTpOverlay:t=>`Open ${t} overlay`,amPmButton:"Switch AM/PM mode",openYearsOverlay:"Open years overlay",openMonthsOverlay:"Open months overlay",nextMonth:"Next month",prevMonth:"Previous month",nextYear:"Next year",prevYear:"Previous year",day:()=>"",...e??{}}),xR=e=>e?typeof e=="boolean"?e?2:0:+e>=2?+e:2:0,Kde=e=>{const t=typeof e=="object"&&e,n={static:!0,solo:!1};if(!e)return{...n,count:xR(!1)};const r=t?e:{},i=t?r.count??!0:e,s=xR(i);return Object.assign(n,r,{count:s})},Qde=(e,t,n)=>e||(typeof n=="string"?n:t),Jde=e=>typeof e=="boolean"?e?bR({}):!1:bR(e),efe=e=>{const t={enterSubmit:!0,tabSubmit:!0,openMenu:!0,rangeSeparator:" - "};return typeof e=="object"?{...t,...e??{},enabled:!0}:{...t,enabled:e}},tfe=e=>({months:[],years:[],times:{hours:[],minutes:[],seconds:[]},...e??{}}),nfe=e=>({showSelect:!0,showCancel:!0,showNow:!1,showPreview:!0,...e??{}}),rfe=e=>{const t={input:!1};return typeof e=="object"?{...t,...e??{},enabled:!0}:{enabled:e,...t}},Na=e=>{const t=()=>{const P=e.enableSeconds?":ss":"";return e.is24?`HH:mm${P}`:`hh:mm${P} aa`},n=()=>e.format?e.format:e.monthPicker?"MM/yyyy":e.timePicker?t():e.weekPicker?"MM/dd/yyyy":e.yearPicker?"yyyy":e.enableTimePicker?`MM/dd/yyyy, ${t()}`:"MM/dd/yyyy",r=P=>x$(P,e.enableSeconds),i=()=>e.range?e.startTime&&Array.isArray(e.startTime)?[r(e.startTime[0]),r(e.startTime[1])]:null:e.startTime&&!Array.isArray(e.startTime)?r(e.startTime):null,s=yt(()=>Kde(e.multiCalendars)),c=yt(()=>i()),a=yt(()=>Xde(e.ariaLabels)),m=yt(()=>tfe(e.filters)),g=yt(()=>Jde(e.transitions)),x=yt(()=>nfe(e.actionRow)),T=yt(()=>Qde(e.previewFormat,e.format,n())),C=yt(()=>efe(e.textInput)),A=yt(()=>rfe(e.inline));return{defaultedTransitions:g,defaultedMultiCalendars:s,defaultedStartTime:c,defaultedAriaLabels:a,defaultedFilters:m,defaultedActionRow:x,defaultedPreviewFormat:T,defaultedTextInput:C,defaultedInline:A,getDefaultPattern:n,getDefaultStartTime:i}}
1435,ife=(e,t,n)=>{const r=jt(),{defaultedTextInput:i,getDefaultPattern:s}=Na(t),c=jt(""),a=Us(t,"format");Nn(r,()=>{e("internal-model-change",r.value)}),Nn(a,()=>{ie()});const m=se=>Gde(se,t.timezone),g=se=>uu(se,t.timezone),x=(se,Ne)=>T$(se,t.format,t.formatLocale,i.value.rangeSeparator,t.modelAuto,Ne??s()),T=se=>{const Ne=se??an();return t.modelType?Te(Ne):{hours:fu(Ne),minutes:pu(Ne),seconds:t.enableSeconds?gg(Ne):0}},C=se=>t.modelType?Te(se):{month:mi(se),year:ai(se)},A=se=>Array.isArray(se)?hb(()=>[up(an(),se[0]),se[1]?up(an(),se[1]):_m(t.partialRange)],t.range):up(an(),+se),P=(se,Ne)=>(typeof se=="string"||typeof se=="number")&&t.modelType?xe(se):Ne,D=se=>Array.isArray(se)?[P(se[0],xd(null,+se[0].hours,+se[0].minutes,se[0].seconds)),P(se[1],xd(null,+se[1].hours,+se[1].minutes,se[1].seconds))]:P(se,xd(null,se.hours,se.minutes,se.seconds)),B=se=>Array.isArray(se)?t.multiDates?se.map(Ne=>P(Ne,Ju(null,+Ne.month,+Ne.year))):hb(()=>[P(se[0],Ju(null,+se[0].month,+se[0].year)),P(se[1],se[1]?Ju(null,+se[1].month,+se[1].year):_m(t.partialRange))],t.range):P(se,Ju(null,+se.month,+se.year)),R=se=>{if(Array.isArray(se))return se.map(Ne=>xe(Ne));throw new Error(Mx.dateArr("multi-dates"))},N=se=>{if(Array.isArray(se))return[an(se[0]),an(se[1])];throw new Error(Mx.dateArr("week-picker"))},j=se=>t.modelAuto?Array.isArray(se)?[xe(se[0]),xe(se[1])]:t.autoApply?[xe(se)]:[xe(se),null]:Array.isArray(se)?hb(()=>[xe(se[0]),se[1]?xe(se[1]):_m(t.partialRange)],t.range):xe(se),U=()=>{Array.isArray(r.value)&&t.range&&r.value.length===1&&r.value.push(_m(t.partialRange))},W=()=>{const se=r.value;return[Te(se[0]),se[1]?Te(se[1]):_m(t.partialRange)]},Q=()=>r.value[1]?W():Te(ba(r.value[0])),Z=()=>(r.value||[]).map(se=>Te(se)),K=()=>(U(),t.modelAuto?Q():t.multiDates?Z():Array.isArray(r.value)?hb(()=>W(),t.range):Te(ba(r.value))),Y=se=>!se||Array.isArray(se)&&!se.length?null:t.timePicker?D(ba(se)):t.monthPicker?B(ba(se)):t.yearPicker?A(ba(se)):t.multiDates?R(ba(se)):t.weekPicker?N(ba(se)):j(ba(se)),me=se=>{const Ne=Y(se);kC(ba(Ne))?(r.value=ba(Ne),ie()):(r.value=null,c.value="")},ge=()=>{const se=Ne=>cp(Ne,i.value.format);return`${se(r.value[0])} ${i.value.rangeSeparator} ${r.value[1]?se(r.value[1]):""}`},ce=()=>n.value&&r.value?Array.isArray(r.value)?ge():cp(r.value,i.value.format):x(r.value),fe=()=>r.value?t.multiDates?r.value.map(se=>x(se)).join("; "):i.value.enabled&&typeof i.value.format=="string"?ce():x(r.value):"",ie=()=>{!t.format||typeof t.format=="string"||i.value.enabled&&typeof i.value.format=="string"?c.value=fe():c.value=t.format(r.value)},xe=se=>{if(t.utc){const Ne=new Date(se);return t.utc==="preserve"?new Date(Ne.getTime()+Ne.getTimezoneOffset()*6e4):Ne}return t.modelType?t.modelType==="date"||t.modelType==="timestamp"?g(new Date(se)):t.modelType==="format"&&(typeof t.format=="string"||!t.format)?bC(se,s(),new Date):g(bC(se,t.modelType,new Date)):g(new Date(se))},Te=se=>se?t.utc?Vde(se,t.utc==="preserve",t.enableSeconds):t.modelType?t.modelType==="timestamp"?+m(se):t.modelType==="format"&&(typeof t.format=="string"||!t.format)?x(m(se)):x(m(se),t.modelType):m(se):"",oe=(se,Ne=!1)=>{if(e("update:model-value",se),t.emitTimezone&&Ne){const Se=Array.isArray(se)?se.map(xt=>uu(ba(xt)),t.emitTimezone):uu(ba(se),t.emitTimezone);e("update:model-timezone-value",Se)}},ne=se=>Array.isArray(r.value)?t.multiDates?r.value.map(Ne=>se(Ne)):[se(r.value[0]),r.value[1]?se(r.value[1]):_m(t.partialRange)]:se(ba(r.value)),le=se=>oe(ba(ne(se)));return{inputValue:c,internalModelValue:r,checkBeforeEmit:()=>r.value?t.range?t.partialRange?r.value.length>=1:r.value.length===2:!!r.value:!1,parseExternalModelValue:me,formatInputValue:ie,emitModelValue:()=>(ie(),t.monthPicker?le(C):t.timePicker?le(T):t.yearPicker?le(ai):t.weekPicker?oe(r.value,!0):oe(K(),!0))}},ofe=(e,t)=>{const{defaultedFilters:n}=Na(e),{validateMonthYearInRange:r}=Bv(e),i=(g,x)=>{let T=g;return n.value.months.includes(mi(T))?(T=x?du(g,1):yg(g,1),i(T,x)):T},s=(g,x)=>{let T=g;return n.value.years.includes(ai(T))?(T=x?B2(g,1):h$(g,1),s(T,x)):T},c=g=>{const x=ho(new Date,{month:e.month,year:e.year});let T=g?du(x,1):yg(x,1);e.disableYearSelect&&(T=up(T,e.year));let C=mi(T),A=ai(T);n.value.months.includes(C)&&(T=i(T,g),C=mi(T),A=ai(T)),n.value.years.includes(A)&&(T=s(T,g),A=ai(T)),r(C,A,g,e.preventMinMaxNavigation)&&a(C,A)},a=(g,x)=>{t("update-month-year",{month:g,year:x})},m=yt(()=>g=>w$(ho(new Date,{month:e.month,year:e.year}),e.maxDate,e.minDate,e.preventMinMaxNavigation,g));return{handleMonthYearChange:c,isDisabled:m,updateMonthYear:a}};var Cm=(e=>(e.center="center",e.left="left",e.right="right",e))(Cm||{}),xc=(e=>(e.month="month",e.year="year",e))(xc||{}),Gf=(e=>(e.top="top",e.bottom="bottom",e))(Gf||{}),dp=(e=>(e.header="header",e.calendar="calendar",e.timePicker="timePicker",e))(dp||{});const afe=(e,t,n,r,i,s,c)=>{const a=jt({}),m=jt(!1),g=jt({top:"0",left:"0"}),x=jt(!1),T=Us(c,"teleportCenter");Nn(T,()=>{g.value=JSON.parse(JSON.stringify({})),j()});const C=ie=>{if(c.teleport){const xe=ie.getBoundingClientRect();return{left:xe.left+window.scrollX,top:xe.top+window.scrollY}}return{top:0,left:0}},A=(ie,xe)=>
1435{g.value.left=`${ie+xe-a.value.width}px`},P=ie=>{g.value.left=`${ie}px`},D=(ie,xe)=>{c.position===Cm.left&&P(ie),c.position===Cm.right&&A(ie,xe),c.position===Cm.center&&(g.value.left=`${ie+xe/2-a.value.width/2}px`)},B=ie=>{const{width:xe,height:Te}=ie.getBoundingClientRect(),{top:oe,left:ne}=c.altPosition?c.altPosition(ie):C(ie);return{top:+oe,left:+ne,width:xe,height:Te}},R=()=>{g.value.left="50%",g.value.top="50%",g.value.transform="translate(-50%, -50%)",g.value.position="fixed",delete g.value.opacity},N=()=>{const ie=ca(n),{top:xe,left:Te,transform:oe}=c.altPosition(ie);g.value={top:`${xe}px`,left:`${Te}px`,transform:oe??""}},j=(ie=!0)=>{var xe;if(!i.value.enabled){if(T.value)return R();if(c.altPosition!==null)return N();if(ie){const Te=c.teleport?(xe=t.value)==null?void 0:xe.$el:e.value;Te&&(a.value=Te.getBoundingClientRect()),s("recalculate-position")}return me()}},U=({inputEl:ie,left:xe,width:Te})=>{window.screen.width>768&&!m.value&&D(xe,Te),Z(ie)},W=ie=>{const{top:xe,left:Te,height:oe,width:ne}=B(ie);g.value.top=`${oe+xe+ +c.offset}px`,x.value=!1,m.value||(g.value.left=`${Te+ne/2-a.value.width/2}px`),U({inputEl:ie,left:Te,width:ne})},Q=ie=>{const{top:xe,left:Te,width:oe}=B(ie);g.value.top=`${xe-+c.offset-a.value.height}px`,x.value=!0,U({inputEl:ie,left:Te,width:oe})},Z=ie=>{if(c.autoPosition){const{left:xe,width:Te}=B(ie),{left:oe,right:ne}=a.value;if(!m.value){if(Math.abs(oe)!==Math.abs(ne)){if(oe<=0)return m.value=!0,P(xe);if(ne>=document.documentElement.clientWidth)return m.value=!0,A(xe,Te)}return D(xe,Te)}}},K=()=>{const ie=ca(n);if(ie){const{height:xe}=a.value,{top:Te,height:oe}=ie.getBoundingClientRect(),ne=window.innerHeight-Te-oe,le=Te;return xe<=ne?Gf.bottom:xe>ne&&xe<=le?Gf.top:ne>=le?Gf.bottom:Gf.top}return Gf.bottom},Y=ie=>K()===Gf.bottom?W(ie):Q(ie),me=()=>{const ie=ca(n);if(ie)return c.autoPosition?Y(ie):W(ie)},ge=function(ie){if(ie){const xe=ie.scrollHeight>ie.clientHeight,Te=window.getComputedStyle(ie).overflowY.indexOf("hidden")!==-1;return xe&&!Te}return!0},ce=function(ie){return!ie||ie===document.body||ie.nodeType===Node.DOCUMENT_FRAGMENT_NODE?window:ge(ie)?ie:ce(ie.parentNode)},fe=ie=>{if(ie)switch(c.position){case Cm.left:return{left:0,transform:"translateX(0)"};case Cm.right:return{left:`${ie.width}px`,transform:"translateX(-100%)"};default:return{left:`${ie.width/2}px`,transform:"translateX(-50%)"}}return{}};return{openOnTop:x,menuStyle:g,xCorrect:m,setMenuPosition:j,getScrollableParent:ce,shadowRender:(ie,xe)=>{var Te,oe,ne;const le=document.createElement("div"),se=(Te=ca(n))==null?void 0:Te.getBoundingClientRect();le.setAttribute("id","dp--temp-container");
1435const Ne=(oe=r.value)!=null&&oe.clientWidth?r.value:document.body;Ne.append(le);const Se=document.getElementById("dp--temp-container"),xt=fe(se),kt=ao(ie,{...xe,shadow:!0,style:{opacity:0,position:"absolute",...xt}});LI(kt,Se),a.value=(ne=kt.el)==null?void 0:ne.getBoundingClientRect(),LI(null,Se),Ne.removeChild(Se)}}},Ff=[{name:"clock-icon",use:["time","calendar","shared"]},{name:"arrow-left",use:["month-year","calendar","shared"]},{name:"arrow-right",use:["month-year","calendar","shared"]},{name:"arrow-up",use:["time","calendar","month-year","shared"]},{name:"arrow-down",use:["time","calendar","month-year","shared"]},{name:"calendar-icon",use:["month-year","time","calendar","shared"]},{name:"day",use:["calendar","shared"]},{name:"month-overlay-value",use:["calendar","month-year","shared"]},{name:"year-overlay-value",use:["calendar","month-year","shared"]},{name:"year-overlay",use:["month-year","shared"]},{name:"month-overlay",use:["month-year","shared"]},{name:"month-overlay-header",use:["month-year","shared"]},{name:"year-overlay-header",use:["month-year","shared"]},{name:"hours-overlay-value",use:["calendar","time","shared"]},{name:"minutes-overlay-value",use:["calendar","time","shared"]},{name:"seconds-overlay-value",use:["calendar","time","shared"]},{name:"hours",use:["calendar","time","shared"]},{name:"minutes",use:["calendar","time","shared"]},{name:"month",use:["calendar","month-year","shared"]},{name:"year",use:["calendar","month-year","shared"]},{name:"action-buttons",use:["action"]},{name:"action-preview",use:["action"]},{name:"calendar-header",use:["calendar","shared"]},{name:"marker-tooltip",use:["calendar","shared"]},{name:"action-extra",use:["menu"]},{name:"time-picker-overlay",use:["calendar","time","shared"]},{name:"am-pm-button",use:["calendar","time","shared"]},{name:"left-sidebar",use:["menu"]},{name:"right-sidebar",use:["menu"]},{name:"month-year",use:["month-year","shared"]},{name:"time-picker",use:["menu","shared"]},{name:"action-row",use:["action"]},{name:"marker",use:["calendar","shared"]}],sfe=[{name:"trigger"},{name:"input-icon"},{name:"clear-icon"},{name:"dp-input"}],lfe={all:()=>Ff,monthYear:()=>Ff.filter(e=>e.use.includes("month-year")),input:()=>sfe,timePicker:()=>Ff.filter(e=>e.use.includes("time")),action:()=>Ff.filter(e=>e.use.includes("action")),calendar:()=>Ff.filter(e=>e.use.includes("calendar")),menu:()=>Ff.filter(e=>e.use.includes("menu")),shared:()=>Ff.filter(e=>e.use.includes("shared"))},kc=(e,t,n)=>{const r=[];return lfe[t]().forEach(i=>{e[i.name]&&r.push(i.name)}),n!=null&&n.length&&n.forEach(i=>{i.slot&&r.push(i.slot)}),r},Fv=e=>{const t=yt(()=>r=>e.value?r?e.value.open:e.value.close:""),n=yt(()=>r=>e.value?r?e.value.menuAppearTop:e.value.menuAppearBottom:"");return{transitionName:t,showTransition:!!e.value,menuTransition:n}},M1=(e,t)=>{const n=jt([{month:mi(an()),year:ai(an())}]),r=so({hours:e.range?[fu(an()),fu(an())]:fu(an()),minutes:e.range?[pu(an()),pu(an())]:pu(an()),seconds:e.range?[0,0]:0}),i=yt({get:()=>e.internalModelValue,set:a=>{!e.readonly&&!e.disabled&&t("update:internal-model-value",a)}}),s=yt(()=>a=>n.value[a]?n.value[a].month:0),c=yt(()=>a=>n.value[a]?n.value[a].year:0);return{calendars:n,time:r,modelValue:i,month:s,year:c}},cfe=(e,t)=>{const{defaultedMultiCalendars:n}=Na(t),{isDisabled:r,matchDate:i}=Bv(t),s=jt(null),c=jt(an()),a=ne=>{!ne.current&&t.hideOffsetDates||(s.value=ne.value)},m=()=>{s.value=null},g=ne=>Array.isArray(e.value)&&t.range&&e.value[0]&&s.value?ne?es(s.value,e.value[0]):za(s.value,e.value[0]):!0,x=(ne,le)=>{const se=()=>e.value?le?e.value[0]||null:e.value[1]:null,Ne=e.value&&Array.isArray(e.value)?se():null;return ki(an(ne.value),Ne)},T=ne=>{const le=Array.isArray(e.value)?e.value[0]:null;return ne?!za(s.value??null,le):!0},C=(ne,le=!0)=>(t.range||t.weekPicker)&&Array.isArray(e.value)&&e.value.length===2?t.hideOffsetDates&&!ne.current?!1:ki(an(ne.value),e.value[le?0:1]):t.range?x(ne,le)&&T(le)||ki(ne.value,Array.isArray(e.value)?e.value[0]:null)&&g(le):!1,A=(ne,le,se)=>Array.isArray(e.value)&&e.value[0]&&e.value.length===1?ne?!1:se?es(e.value[0],le.value):za(e.value[0],le.value):!1,P=ne=>!e.value||t.hideOffsetDates&&!ne.current?!1:t.range?t.modelAuto&&Array.isArray(e.value)?ki(ne.value,e.value[0]?e.value[0]:c.value):!1:t.multiDates&&Array.isArray(e.value)?e.value.some(le=>ki(le,ne.value)):ki(ne.value,e.value?e.value:c.value),D=ne=>{if(t.autoRange||t.weekPicker){if(s.value){if(t.hideOffsetDates&&!ne.current)return!1;
1435const le=Xu(s.value,+t.autoRange),se=Rb(an(s.value),t.timezone,t.weekStart);return t.weekPicker?ki(se[1],an(ne.value)):ki(le,an(ne.value))}return!1}return!1},B=ne=>{if(t.autoRange||t.weekPicker){if(s.value){const le=Xu(s.value,+t.autoRange);if(t.hideOffsetDates&&!ne.current)return!1;const se=Rb(an(s.value),t.timezone,t.weekStart);return t.weekPicker?es(ne.value,se[0])&&za(ne.value,se[1]):es(ne.value,s.value)&&za(ne.value,le)}return!1}return!1},R=ne=>{if(t.autoRange||t.weekPicker){if(s.value){if(t.hideOffsetDates&&!ne.current)return!1;const le=Rb(an(s.value),t.timezone,t.weekStart);return t.weekPicker?ki(le[0],ne.value):ki(s.value,ne.value)}return!1}return!1},N=ne=>J2(e.value,s.value,ne.value),j=()=>t.modelAuto&&Array.isArray(t.internalModelValue)?!!t.internalModelValue[0]:!1,U=()=>t.modelAuto?y$(t.internalModelValue):!0,W=ne=>{if(Array.isArray(e.value)&&e.value.length||t.weekPicker)return!1;const le=t.range?!C(ne)&&!C(ne,!1):!0;return!r(ne.value)&&!P(ne)&&!(!ne.current&&t.hideOffsetDates)&&le},Q=ne=>t.range?t.modelAuto?j()&&P(ne):!1:P(ne),Z=ne=>{var le;return t.highlight?i(ne.value,(le=t.arrMapValues)!=null&&le.highlightedDates?t.arrMapValues.highlightedDates:t.highlight):!1},K=ne=>r(ne.value)&&t.highlightDisabledDays===!1,Y=ne=>{var le;return(le=t.highlightWeekDays)==null?void 0:le.includes(ne.value.getDay())},me=ne=>(t.range||t.weekPicker)&&(!(n.value.count>0)||ne.current)&&U()&&!(!ne.current&&t.hideOffsetDates)&&!P(ne)?N(ne):!1,ge=ne=>{const{isRangeStart:le,isRangeEnd:se}=ie(ne),Ne=t.range?le||se:!1;return{dp__cell_offset:!ne.current,dp__pointer:!t.disabled&&!(!ne.current&&t.hideOffsetDates)&&!r(ne.value),dp__cell_disabled:r(ne.value),dp__cell_highlight:!K(ne)&&(Z(ne)||Y(ne))&&!Q(ne)&&!Ne,dp__cell_highlight_active:!K(ne)&&(Z(ne)||Y(ne))&&Q(ne),dp__today:!t.noToday&&ki(ne.value,c.value)&&ne.current}},ce=ne=>({dp__active_date:Q(ne),dp__date_hover:W(ne)}),fe=ne=>({...xe(ne),...Te(ne),dp__range_between_week:me(ne)&&t.weekPicker}),ie=ne=>{const le=n.value.count>0?ne.current&&C(ne)&&U():C(ne)&&U(),se=n.value.count>0?ne.current&&C(ne,!1)&&U():C(ne,!1)&&U();return{isRangeStart:le,isRangeEnd:se}},xe=ne=>{const{isRangeStart:le,isRangeEnd:se}=ie(ne);return{dp__range_start:le,dp__range_end:se,dp__range_between:me(ne)&&!t.weekPicker,dp__date_hover_start:A(W(ne),ne,!0),dp__date_hover_end:A(W(ne),ne,!1)}},Te=ne=>({...xe(ne),dp__cell_auto_range:B(ne),dp__cell_auto_range_start:R(ne),dp__cell_auto_range_end:D(ne)}),oe=ne=>t.range?t.autoRange?Te(ne):t.modelAuto?{...ce(ne),...xe(ne)}:xe(ne):t.weekPicker?fe(ne):ce(ne);return{setHoverDate:a,clearHoverDate:m,getDayClassData:ne=>t.hideOffsetDates&&!ne.current?{}:{...ge(ne),...oe(ne),[t.dayClass?t.dayClass(ne.value):""]:!0,[t.calendarCellClassName]:!!t.calendarCellClassName}}},Bv=e=>{const{defaultedFilters:t}=Na(e),n=K=>{const Y=Xl(r(an(K))).toISOString(),[me]=Y.split("T");return me},r=K=>uu(K,e.timezone),i=K=>{var Y;const me=e.maxDate?es(r(K),r(an(e.maxDate))):!1,ge=e.minDate?za(r(K),r(an(e.minDate))):!1,ce=m(K,(Y=e.arrMapValues)!=null&&Y.disabledDates?e.arrMapValues.disabledDates:e.disabledDates),fe=t.value.months.map(ne=>+ne).includes(mi(K)),ie=e.disabledWeekDays.length?e.disabledWeekDays.some(ne=>+ne===jue(K)):!1,xe=x(K),Te=ai(K),oe=Te<+e.yearRange[0]||Te>+e.yearRange[1];return!(me||ge||ce||fe||oe||ie||xe)},s=(K,Y)=>za(...ud(e.minDate,K,Y))||ki(...ud(e.minDate,K,Y)),c=(K,Y)=>es(...ud(e.maxDate,K,Y))||ki(...ud(e.maxDate,K,Y)),a=(K,Y,me)=>{let ge=!1;return e.maxDate&&me&&c(K,Y)&&(ge=!0),e.minDate&&!me&&s(K,Y)&&(ge=!0),ge},m=(K,Y)=>K?Y instanceof Map?!!Y.get(n(K)):Array.isArray(Y)?Y.some(me=>ki(r(an(me)),r(K))):Y?Y(an(JSON.parse(JSON.stringify(K)))):!1:!0,g=(K,Y,me,ge)=>{let ce=!1;return ge?e.minDate&&e.maxDate?ce=a(K,Y,me):(e.minDate&&s(K,Y)||e.maxDate&&c(K,Y))&&(ce=!0):ce=!0,ce},x=K=>{var Y,me,ge,ce,fe;return Array.isArray(e.allowedDates)&&!((Y=e.allowedDates)!=null&&Y.length)?!0:(me=e.arrMapValues)!=null&&me.allowedDates?!m(K,(ge=e.arrMapValues)==null?void 0:ge.allowedDates):(ce=e.allowedDates)!=null&&ce.length?!((fe=e.allowedDates)!=null&&fe.some(ie=>ki(r(an(ie)),r(K)))):!1},T=K=>!i(K),C=K=>!W4({start:K[0],end:K[1]}).some(Y=>T(Y)),A=(K,Y,me=0)=>{if(Array.isArray(Y)&&Y[me]){const ge=Lce(K,Y[me]),ce=b$(Y[me],K),fe=ce.length===1?0:ce.filter(xe=>T(xe)).length,ie=Math.abs(ge)-fe;if(e.minRange&&e.maxRange)return ie>=+e.minRange&&ie<=+e.maxRange;if(e.minRange)return ie>=+e.minRange;if(e.maxRange)return ie<=+e.maxRange}return!0},P=K=>new Map(K.map(Y=>[n(Y),!0])),D=K=>Array.isArray(K)&&K.length>0,B=()=>{const K={disabledDates:null,allowedDates:null,highlightedDates:null};return D(e.allowedDates)&&(K.allowedDates=P(e.allowedDates)),D(e.highlight)&&(K.highlightedDates=P(e.highlight)),D(e.disabledDates)&&(K.disabledDates=P(e.disabledDates)),K},R=()=>!e.enableTimePicker||e.monthPicker||e.yearPicker||e.ignoreTimeValidation,N=K=>Array.isArray(K)?[K[0]?yE(K[0]):null,K[1]?yE(K[1]):null]:yE(K),j=(K,Y,me)=>K.find(ge=>+ge.hours===fu(Y)&&ge.minutes==="*"?!0:+ge.minutes===pu(Y))&&me,U=(K,Y,me)=>{const[ge,ce]=K,[fe,ie]=Y;return!j(ge,fe,me)&&!j(ce,ie,me)&&me},W=(K,Y)=>{const me=Array.isArray(Y)?Y:[Y];return Array.isArray(e.disabledTimes)?Array.isArray(e.disabledTimes[0])?U(e.disabledTimes,me,K):!me.some(ge=>j(e.disabledTimes,ge,K)):K},Q=(K,Y)=>{const me=Array.isArray(Y)?[hp(Y[0]),Y[1]?hp(Y[1]):void 0]:hp(Y),ge=!e.disabledTimes(me);return K&&ge},Z=(K,Y)=>e.disabledTimes?Array.isArray(e.disabledTimes)?W(Y,K):Q(Y,K):Y;return{isDisabled:T,validateDate:i,validateMonthYearInRange:g,isDateRangeAllowed:C,checkMinMaxRange:A,matchDate:m,mapDatesArrToMap:B,isValidTime:K=>{let Y=!0;if(!K||R())return!0;const me=!e.minDate&&!e.maxDate?N(K):K;return(e.maxTime||e.maxDate)&&(Y=vR(e.maxTime,e.maxDate,"max",ba(me),Y)),(e.minTime||e.minDate)&&(Y=vR(e.minTime,e.minDate,"min",ba(me),Y)),Z(K,Y)}}},I1=()=>{const e=yt(()=>(r,i)=>r==null?void 0:r.includes(i)),t=yt(()=>(r,i)=>r.count?r.solo?!0:i===0:!0),n=yt(()=>(r,i)=>r.count?r.solo?!0:i===r.count-1:!0);return{hideNavigationButtons:e,showLeftIcon:t,showRightIcon:n}}
1435,ufe=(e,t,n)=>{const r=jt(0),i=so({[dp.timePicker]:!e.enableTimePicker||e.timePicker||e.monthPicker,[dp.calendar]:!1,[dp.header]:!1}),s=x=>{var T;(T=e.flow)!=null&&T.length&&(i[x]=!0,Object.keys(i).filter(C=>!i[C]).length||g())},c=()=>{var x;(x=e.flow)!=null&&x.length&&r.value!==-1&&(r.value+=1,t("flow-step",r.value),g())},a=()=>{r.value=-1},m=(x,T,...C)=>{e.flow[r.value]===x&&n.value&&n.value[T](...C)},g=()=>{m("month","toggleMonthPicker",!0),m("year","toggleYearPicker",!0),m("calendar","toggleTimePicker",!1,!0),m("time","toggleTimePicker",!0,!0);const x=e.flow[r.value];(x==="hours"||x==="minutes"||x==="seconds")&&m(x,"toggleTimePicker",!0,!0,x)};return{childMount:s,updateFlowStep:c,resetFlow:a,flowStep:r}},O1={multiCalendars:{type:[Boolean,Number,String,Object],default:void 0},modelValue:{type:[String,Date,Array,Object,Number],default:null},modelType:{type:String,default:null},position:{type:String,default:"center"},dark:{type:Boolean,default:!1},format:{type:[String,Function],default:()=>null},closeOnScroll:{type:Boolean,default:!1},autoPosition:{type:Boolean,default:!0},closeOnAutoApply:{type:Boolean,default:!0},altPosition:{type:Function,default:null},transitions:{type:[Boolean,Object],default:!0},formatLocale:{type:Object,default:null},utc:{type:[Boolean,String],default:!1},ariaLabels:{type:Object,default:()=>({})},offset:{type:[Number,String],default:10},hideNavigation:{type:Array,default:()=>[]},timezone:{type:String,default:null},emitTimezone:{type:String,default:null},vertical:{type:Boolean,default:!1},disableMonthYearSelect:{type:Boolean,default:!1},disableYearSelect:{type:Boolean,default:!1},menuClassName:{type:String,default:null},dayClass:{type:Function,default:null},yearRange:{type:Array,default:()=>[1900,2100]},calendarCellClassName:{type:String,default:null},enableTimePicker:{type:Boolean,default:!0},autoApply:{type:Boolean,default:!1},disabledDates:{type:[Array,Function],default:()=>[]},monthNameFormat:{type:String,default:"short"},startDate:{type:[Date,String],default:null},startTime:{type:[Object,Array],default:null},hideOffsetDates:{type:Boolean,default:!1},autoRange:{type:[Number,String],default:null},noToday:{type:Boolean,default:!1},disabledWeekDays:{type:Array,default:()=>[]},allowedDates:{type:Array,default:null},nowButtonLabel:{type:String,default:"Now"},markers:{type:Array,default:()=>[]},modeHeight:{type:[Number,String],default:255},escClose:{type:Boolean,default:!0},spaceConfirm:{type:Boolean,default:!0},monthChangeOnArrows:{type:Boolean,default:!0},presetDates:{type:Array,default:()=>[]},flow:{type:Array,default:()=>[]},partialFlow:{type:Boolean,default:!1},preventMinMaxNavigation:{type:Boolean,default:!1},minRange:{type:[Number,String],default:null},maxRange:{type:[Number,String],default:null},multiDatesLimit:{type:[Number,String],default:null},reverseYears:{type:Boolean,default:!1},keepActionRow:{type:Boolean,default:!1},weekPicker:{type:Boolean,default:!1},filters:{type:Object,default:()=>({})},arrowNavigation:{type:Boolean,default:!1},disableTimeRangeValidation:{type:Boolean,default:!1},highlight:{type:[Array,Function],default:null},highlightWeekDays:{type:Array,default:null},highlightDisabledDays:{type:Boolean,default:!1},teleport:{type:[String,Boolean],default:null},teleportCenter:{type:Boolean,default:!1},locale:{type:String,default:"en-Us"},weekNumName:{type:String,default:"W"},weekStart:{type:[Number,String],default:1},weekNumbers:{type:[String,Function],default:null},calendarClassName:{type:String,default:null},noSwipe:{type:Boolean,default:!1},monthChangeOnScroll:{type:[Boolean,String],default:!0},dayNames:{type:[Function,Array],default:null},monthPicker:{type:Boolean,default:!1},customProps:{type:Object,default:null},yearPicker:{type:Boolean,default:!1},modelAuto:{type:Boolean,default:!1},selectText:{type:String,default:"Select"},cancelText:{type:String,default:"Cancel"},previewFormat:{type:[String,Function],default:()=>""},multiDates:{type:Boolean,default:!1},partialRange:{type:Boolean,default:!0},ignoreTimeValidation:{type:Boolean,default:!1},minDate:{type:[Date,String],default:null},maxDate:{type:[Date,String],default:null},minTime:{type:Object,default:null},maxTime:{type:Object,default:null},name:{type:String,default:null},placeholder:{type:String,default:""},hideInputIcon:{type:Boolean,default:!1},clearable:{type:Boolean,default:!0},state:{type:Boolean,default:null},required:{type:Boolean,default:!1},autocomplete:{type:String,default:"off"},inputClassName:{type:String,default:null},fixedStart:{type:Boolean,default:!1},fixedEnd:{type:Boolean,default:!1},timePicker:{type:Boolean,default:!1},enableSeconds:{type:Boolean,default:!1},is24:{type:Boolean,default:!0},noHoursOverlay:{type:Boolean,default:!1},noMinutesOverlay:{type:Boolean,default:!1},noSecondsOverlay:{type:Boolean,default:!1},hoursGridIncrement:{type:[String,Number],default:1},minutesGridIncrement:{type:[String,Number],default:5},secondsGridIncrement:{type:[String,Number],default:5},hoursIncrement:{type:[Number,String],default:1},minutesIncrement:{type:[Number,String],default:1},secondsIncrement:{type:[Number,String],default:1},range:{type:Boolean,default:!1},uid:{type:String,default:null},disabled:{type:Boolean,default:!1},readonly:{type:Boolean,default:!1},inline:{type:[Boolean,Object],default:!1},textInput:{type:[Boolean,Object],default:!1},onClickOutside:{type:Function,default:null},noDisabledRange:{type:Boolean,default:!1},sixWeeks:{type:[Boolean,String],default:!1},actionRow:{type:Object,default:()=>({})},allowPreventDefault:{type:Boolean,default:!1},closeOnClearValue:{type:Boolean,default:!0},focusStartDate:{type:Boolean,default:!1},disabledTimes:{type:[Function,Array],default:void 0},showLastInRange:{type:Boolean,default:!0},timePickerInline:{type:Boolean,default:!1},calendar:{type:Function,default:null}},uh={...O1,shadow:{type:Boolean,default:!1},flowStep:{type:Number,default:0},internalModelValue:{type:[Date,Array],default:null},arrMapValues:{type:Object,default:()=>({})}},hfe={key:1,class:"dp__input_wrap"},dfe=["id","name","inputmode","placeholder","disabled","readonly","required","value","autocomplete","aria-label","onKeydown"],ffe={key:2,class:"dp__clear_icon"},pfe=sr({compatConfig:{MODE:3},__name:"DatepickerInput",props:{isMenuOpen:{type:Boolean,default:!1},inputValue:{type:String,default:""},...O1},emits:["clear","open","update:input-value","set-input-date","close","select-date","set-empty-date","toggle","focus-prev","focus","blur","real-blur"],setup(e,{expose:t,emit:n}){const r=e,{defaultedTextInput:i,defaultedAriaLabels:s,defaultedInline:c,getDefaultPattern:a,getDefaultStartTime:m}=Na(r),g=jt(),x=jt(null),T=jt(!1),C=jt(!1),A=yt(()=>({dp__pointer:!r.disabled&&!r.readonly&&!i.value.enabled,dp__disabled:r.disabled,dp__input_readonly:!i.value.enabled,dp__input:!0,dp__input_icon_pad:!r.hideInputIcon,dp__input_valid:r.state,dp__input_invalid:r.state===!1,dp__input_focus:T.value||r.isMenuOpen,dp__input_reg:!i.value.enabled,[r.inputClassName]:!!r.inputClassName})),P=()=>{n("set-input-date",null),r.autoApply&&(n("set-empty-date"),g.value=null)},D=ge=>{const ce=m();return Ude(ge,i.value.format??a(),ce??x$({},r.enableSeconds),r.inputValue,C.value)},B=ge=>{const{rangeSeparator:ce}=i.value,[fe,ie]=ge.split(`${ce}`);if(fe){const xe=D(fe.trim()),Te=ie?D(ie.trim()):null,oe=xe&&Te?[xe,Te]:[xe];g.value=xe?oe:null}},R=()=>{C.value=!0},N=ge=>{if(r.range)B(ge);else if(r.multiDates){const ce=ge.split(";");g.value=ce.map(fe=>D(fe.trim())).filter(fe=>fe)}else g.value=D(ge)},j=ge=>{var ce;const fe=typeof ge=="string"?ge:(ce=ge.target)==null?void 0:ce.value;fe!==""?(i.value.openMenu&&!r.isMenuOpen&&n("open"),N(fe),n("set-input-date",g.value)):P(),C.value=!1,n("update:input-value",fe)},U=ge=>{i.value.enabled?(N(ge.target.value),i.value.enterSubmit&&kC(g.value)&&r.inputValue!==""?(n("set-input-date",g.value,!0),g.value=null):i.value.enterSubmit&&r.inputValue===""&&(g.value=null,n("clear"))):Z(ge)},W=ge=>{i.value.enabled&&i.value.tabSubmit&&N(ge.target.value),i.value.tabSubmit&&kC(g.value)&&r.inputValue!==""?(n("set-input-date",g.value,!0),g.value=null):i.value.tabSubmit&&r.inputValue===""&&(g.value=null,n("clear"))},Q=()=>{T.value=!0,n("focus")},Z=ge=>{ge.preventDefault(),ge.stopImmediatePropagation(),ge.stopPropagation(),i.value.enabled&&i.value.openMenu&&!c.value.input&&!r.isMenuOpen?n("open"):i.value.enabled||n("toggle")},K=()=>{n("real-blur"),T.value=!1,(!r.isMenuOpen||c.value.enabled&&c.value.input)&&n("blur"),r.autoApply&&i.value.enabled&&g.value&&!r.isMenuOpen&&
1435(n("set-input-date",g.value),n("select-date"),g.value=null)},Y=()=>{n("clear")},me=ge=>{if(!i.value.enabled){if(ge.code==="Tab")return;ge.preventDefault()}};return t({focusInput:()=>{var ge;(ge=x.value)==null||ge.focus({preventScroll:!0})},setParsedDate:ge=>{g.value=ge}}),(ge,ce)=>{var fe;return At(),Wt("div",{onClick:Z},[ge.$slots.trigger&&!ge.$slots["dp-input"]&&!bt(c).enabled?En(ge.$slots,"trigger",{key:0}):hn("",!0),!ge.$slots.trigger&&(!bt(c).enabled||bt(c).input)?(At(),Wt("div",hfe,[ge.$slots["dp-input"]&&!ge.$slots.trigger&&!bt(c).enabled?En(ge.$slots,"dp-input",{key:0,value:e.inputValue,isMenuOpen:e.isMenuOpen,onInput:j,onEnter:U,onTab:W,onClear:Y,onBlur:K,onKeypress:me,onPaste:R}):hn("",!0),ge.$slots["dp-input"]?hn("",!0):(At(),Wt("input",{key:1,ref_key:"inputRef",ref:x,id:ge.uid?`dp-input-${ge.uid}`:void 0,name:ge.name,class:qr(A.value),inputmode:bt(i).enabled?"text":"none",placeholder:ge.placeholder,disabled:ge.disabled,readonly:ge.readonly,required:ge.required,value:e.inputValue,autocomplete:ge.autocomplete,"aria-label":(fe=bt(s))==null?void 0:fe.input,onInput:j,onKeydown:[br(U,["enter"]),br(W,["tab"]),me],onBlur:K,onFocus:Q,onKeypress:me,onPaste:R},null,42,dfe)),Un("div",{onClick:ce[2]||(ce[2]=ie=>n("toggle"))},[ge.$slots["input-icon"]&&!ge.hideInputIcon?(At(),Wt("span",{key:0,class:"dp__input_icon",onClick:ce[0]||(ce[0]=ie=>n("toggle"))},[En(ge.$slots,"input-icon")])):hn("",!0),!ge.$slots["input-icon"]&&!ge.hideInputIcon&&!ge.$slots["dp-input"]?(At(),Tr(bt(Rv),{key:1,onClick:ce[1]||(ce[1]=ie=>n("toggle")),class:"dp__input_icon dp__input_icons"})):hn("",!0)]),ge.$slots["clear-icon"]&&e.inputValue&&ge.clearable&&!ge.disabled&&!ge.readonly?(At(),Wt("span",ffe,[En(ge.$slots,"clear-icon",{clear:Y})])):hn("",!0),ge.clearable&&!ge.$slots["clear-icon"]&&e.inputValue&&!ge.disabled&&!ge.readonly?(At(),Tr(bt(d$),{key:3,class:"dp__clear_icon dp__input_icons",onClick:Di(Y,["stop","prevent"])},null,8,["onClick"])):hn("",!0)])):hn("",!0)])}}}),mfe=["title"],gfe={class:"dp__action_buttons"},yfe=["onKeydown","disabled"],_fe=sr({compatConfig:{MODE:3},__name:"ActionRow",props:{menuMount:{type:Boolean,default:!1},calendarWidth:{type:Number,default:0},...uh},emits:["close-picker","select-date","select-now","invalid-select"],setup(e,{emit:t}){const n=e,{defaultedActionRow:r,defaultedPreviewFormat:i,defaultedMultiCalendars:s,defaultedTextInput:c,defaultedInline:a,getDefaultPattern:m}=Na(n),{isValidTime:g}=Bv(n),{buildMatrix:x}=$d(),T=jt(null),C=jt(null);Dr(()=>{n.arrowNavigation&&x([ca(T),ca(C)],"actionRow")});const A=yt(()=>n.range&&!n.partialRange&&n.internalModelValue?n.internalModelValue.length===2:!0),P=yt(()=>!D.value||!B.value||!A.value),D=yt(()=>!n.enableTimePicker||n.ignoreTimeValidation?!0:g(n.internalModelValue)),B=yt(()=>n.monthPicker?n.range&&Array.isArray(n.internalModelValue)?!n.internalModelValue.filter(Y=>!Z(Y)).length:Z(n.internalModelValue):!0),R=()=>{const Y=i.value;return n.timePicker||n.monthPicker,Y(ba(n.internalModelValue))},N=()=>{const Y=n.internalModelValue;return s.value.count>0?`${j(Y[0])} - ${j(Y[1])}`:[j(Y[0]),j(Y[1])]},j=Y=>T$(Y,i.value,n.formatLocale,c.value.rangeSeparator,n.modelAuto,m()),U=yt(()=>!n.internalModelValue||!n.menuMount?"":typeof i.value=="string"?Array.isArray(n.internalModelValue)?n.internalModelValue.length===2&&n.internalModelValue[1]?N():n.multiDates?n.internalModelValue.map(Y=>`${j(Y)}`):n.modelAuto?`${j(n.internalModelValue[0])}`:`${j(n.internalModelValue[0])} -`:j(n.internalModelValue):R()),W=()=>n.multiDates?"; ":" - ",Q=yt(()=>Array.isArray(U.value)?U.value.join(W()):U.value),Z=Y=>{if(!n.monthPicker)return!0;let me=!0;const ge=an(Sc(Y));if(n.minDate&&n.maxDate){const ce=an(Sc(n.minDate)),fe=an(Sc(n.maxDate));return es(ge,ce)&&za(ge,fe)||ki(ge,ce)||ki(ge,fe)}if(n.minDate){const ce=an(Sc(n.minDate));me=es(ge,ce)||ki(ge,ce)}if(n.maxDate){const ce=an(Sc(n.maxDate));me=za(ge,ce)||ki(ge,ce)}return me},K=()=>{D.value&&B.value&&A.value?t("select-date"):t("invalid-select")};return(Y,me)=>(At(),Wt("div",{class:"dp__action_row",style:Sa(e.calendarWidth?{width:`${e.calendarWidth}px`}:{})},[Y.$slots["action-row"]?En(Y.$slots,"action-row",ys(Li({key:0},{internalModelValue:Y.internalModelValue,disabled:P.value,selectDate:()=>Y.$emit("select-date"),closePicker:()=>Y.$emit("close-picker")}))):(At(),Wt(Hn,{key:1},[bt(r).showPreview?(At(),Wt("div",{key:0,class:"dp__selection_preview",title:Q.value},[Y.$slots["action-preview"]?En(Y.$slots,"action-preview",{key:0,value:Y.internalModelValue}):hn("",!0),Y.$slots["action-preview"]?hn("",!0):(At(),Wt(Hn,{key:1},[mu(Ba(Q.value),1)],64))],8,mfe)):hn("",!0),Un("div",gfe,[Y.$slots["action-buttons"]?En(Y.$slots,"action-buttons",{key:0,value:Y.internalModelValue}):hn("",!0),Y.$slots["action-buttons"]?hn("",!0):(At(),Wt(Hn,{key:1}
1435,[!bt(a).enabled&&bt(r).showCancel?(At(),Wt("button",{key:0,type:"button",ref_key:"cancelButtonRef",ref:T,class:"dp__action_button dp__action_cancel",onClick:me[0]||(me[0]=ge=>Y.$emit("close-picker")),onKeydown:[me[1]||(me[1]=br(ge=>Y.$emit("close-picker"),["enter"])),me[2]||(me[2]=br(ge=>Y.$emit("close-picker"),["space"]))]},Ba(Y.cancelText),545)):hn("",!0),bt(r).showNow?(At(),Wt("button",{key:1,type:"button",ref_key:"cancelButtonRef",ref:T,class:"dp__action_button dp__action_cancel",onClick:me[3]||(me[3]=ge=>Y.$emit("select-now")),onKeydown:[me[4]||(me[4]=br(ge=>Y.$emit("select-now"),["enter"])),me[5]||(me[5]=br(ge=>Y.$emit("select-now"),["space"]))]},Ba(Y.nowButtonLabel),545)):hn("",!0),bt(r).showSelect?(At(),Wt("button",{key:2,type:"button",class:"dp__action_button dp__action_select",onKeydown:[br(K,["enter"]),br(K,["space"])],onClick:K,disabled:P.value,ref_key:"selectButtonRef",ref:C},Ba(Y.selectText),41,yfe)):hn("",!0)],64))])],64))],4))}}),vfe=["onKeydown"],bfe={class:"dp__selection_grid_header"},xfe=["aria-selected","aria-disabled","onClick","onKeydown","onMouseover"],wfe=["aria-label","onKeydown"],iv=sr({__name:"SelectionOverlay",props:{items:{},type:{},isLast:{type:Boolean},arrowNavigation:{type:Boolean},skipButtonRef:{type:Boolean},headerRefs:{},hideNavigation:{},escClose:{type:Boolean},useRelative:{type:Boolean},height:{},textInput:{type:[Boolean,Object]}},emits:["selected","toggle","reset-flow","hover-value"],setup(e,{expose:t,emit:n}){const r=e,{setSelectionGrid:i,buildMultiLevelMatrix:s,setMonthPicker:c}=$d(),{defaultedAriaLabels:a,defaultedTextInput:m}=Na(r),{hideNavigationButtons:g}=I1(),x=jt(!1),T=jt(null),C=jt(null),A=jt([]),P=jt(),D=jt(null),B=jt(0),R=jt(null);c3(()=>{T.value=null}),Dr(()=>{Qi().then(()=>Y()),j(),N(!0)}),Bi(()=>N(!1));const N=oe=>{var ne;r.arrowNavigation&&((ne=r.headerRefs)!=null&&ne.length?c(oe):i(oe))},j=()=>{var oe;const ne=ca(C);ne&&(m.value.enabled||(T.value?(oe=T.value)==null||oe.focus({preventScroll:!0}):ne.focus({preventScroll:!0})),x.value=ne.clientHeight<ne.scrollHeight)},U=yt(()=>({dp__overlay:!0,"dp--overlay-absolute":!r.useRelative,"dp--overlay-relative":r.useRelative})),W=yt(()=>r.useRelative?{height:`${r.height}px`,width:"260px"}:void 0),Q=yt(()=>({dp__overlay_col:!0})),Z=yt(()=>({dp__btn:!0,dp__button:!0,dp__overlay_action:!0,dp__over_action_scroll:x.value,dp__button_bottom:r.isLast})),K=yt(()=>{var oe,ne;return{dp__overlay_container:!0,dp__container_flex:((oe=r.items)==null?void 0:oe.length)<=6,dp__container_block:((ne=r.items)==null?void 0:ne.length)>6}}),Y=()=>{Qi().then(()=>{const oe=ca(T),ne=ca(C),le=ca(D),se=ca(R),Ne=le?le.getBoundingClientRect().height:0;ne&&(B.value=ne.getBoundingClientRect().height-Ne),oe&&se&&(se.scrollTop=oe.offsetTop-se.offsetTop-(B.value/2-oe.getBoundingClientRect().height)-Ne)})},me=oe=>{oe.disabled||n("selected",oe.value)},ge=()=>{n("toggle"),n("reset-flow")},ce=()=>{r.escClose&&ge()},fe=(oe,ne,le,se)=>{oe&&(ne.active&&(T.value=oe),r.arrowNavigation&&(Array.isArray(A.value[le])?A.value[le][se]=oe:A.value[le]=[oe],ie()))},ie=()=>{var oe,ne;const le=(oe=r.headerRefs)!=null&&oe.length?[r.headerRefs].concat(A.value):A.value.concat([r.skipButtonRef?[]:[D.value]]);s(ba(le),(ne=r.headerRefs)!=null&&ne.length?"monthPicker":"selectionGrid")},xe=oe=>{r.arrowNavigation||oe.stopImmediatePropagation()},Te=oe=>{P.value=oe,n("hover-value",oe)};return t({focusGrid:j}),(oe,ne)=>{var le;return At(),Wt("div",{ref_key:"gridWrapRef",ref:C,class:qr(U.value),style:Sa(W.value),role:"dialog",tabindex:"0",onKeydown:[br(Di(ce,["prevent"]),["esc"]),ne[0]||(ne[0]=br(Di(se=>xe(se),["prevent"]),["left"])),ne[1]||(ne[1]=br(Di(se=>xe(se),["prevent"]),["up"])),ne[2]||(ne[2]=br(Di(se=>xe(se),["prevent"]),["down"])),ne[3]||(ne[3]=br(Di(se=>xe(se),["prevent"]),["right"]))]},[Un("div",{class:qr(K.value),ref_key:"containerRef",ref:R,role:"grid",style:Sa({height:`${B.value}px`})},[Un("div",bfe,[En(oe.$slots,"header")]),oe.$slots.overlay?En(oe.$slots,"overlay",{key:0}):(At(!0),Wt(Hn,{key:1},$o(oe.items,(se,Ne)=>(At(),Wt("div",{class:qr(["dp__overlay_row",{dp__flex_row:oe.items.length>=3}]),key:Ne,role:"row"},[(At(!0),Wt(Hn,null,$o(se,(Se,xt)=>(At(),Wt("div",{role:"gridcell",class:qr(Q.value),key:Se.value,"aria-selected":Se.active,"aria-disabled":Se.disabled||void 0,ref_for:!0,ref:kt=>fe(kt,Se,Ne,xt),tabindex:"0",onClick:kt=>me(Se),onKeydown:[br(Di(kt=>me(Se),["prevent"]),["enter"]),br(Di(kt=>me(Se),["prevent"]),["space"])],onMouseover:kt=>Te(Se.value)}
1435,[Un("div",{class:qr(Se.className)},[oe.$slots.item?En(oe.$slots,"item",{key:0,item:Se}):hn("",!0),oe.$slots.item?hn("",!0):(At(),Wt(Hn,{key:1},[mu(Ba(Se.text),1)],64))],2)],42,xfe))),128))],2))),128))],6),oe.$slots["button-icon"]?pd((At(),Wt("button",{key:0,role:"button","aria-label":(le=bt(a))==null?void 0:le.toggleOverlay,class:qr(Z.value),tabindex:"0",ref_key:"toggleButton",ref:D,onClick:ge,onKeydown:[br(ge,["enter"]),br(ge,["tab"])]},[En(oe.$slots,"button-icon")],42,wfe)),[[gd,!bt(g)(oe.hideNavigation,oe.type)]]):hn("",!0)],46,vfe)}}}),eA=sr({__name:"InstanceWrap",props:{multiCalendars:{},stretch:{type:Boolean}},setup(e){const t=e,n=yt(()=>t.multiCalendars>0?[...Array(t.multiCalendars).keys()]:[0]),r=yt(()=>({dp__instance_calendar:t.multiCalendars>0}));return(i,s)=>(At(),Wt("div",{class:qr({dp__menu_inner:!i.stretch,"dp--menu--inner-stretched":i.stretch,dp__flex_display:i.multiCalendars>0})},[(At(!0),Wt(Hn,null,$o(n.value,(c,a)=>(At(),Wt("div",{key:c,class:qr(r.value)},[En(i.$slots,"default",{instance:c,index:a})],2))),128))],2))}}),Tfe=["aria-label","aria-disabled"],C_=sr({compatConfig:{MODE:3},__name:"ArrowBtn",props:{ariaLabel:{},disabled:{type:Boolean}},emits:["activate","set-ref"],setup(e,{emit:t}){const n=jt(null);return Dr(()=>t("set-ref",n)),(r,i)=>(At(),Wt("button",{type:"button",class:"dp__btn dp--arrow-btn-nav",onClick:i[0]||(i[0]=s=>r.$emit("activate")),onKeydown:[i[1]||(i[1]=br(Di(s=>r.$emit("activate"),["prevent"]),["enter"])),i[2]||(i[2]=br(Di(s=>r.$emit("activate"),["prevent"]),["space"]))],tabindex:"0","aria-label":r.ariaLabel,"aria-disabled":r.disabled||void 0,ref_key:"elRef",ref:n},[Un("span",{class:qr(["dp__inner_nav",{dp__inner_nav_disabled:r.disabled}])},[En(r.$slots,"default")],2)],40,Tfe))}}
1435),tA=(e,t,n)=>{if(t.value&&Array.isArray(t.value))if(t.value.some(r=>ki(e,r))){const r=t.value.filter(i=>!ki(i,e));t.value=r.length?r:null}else(n&&+n>t.value.length||!n)&&t.value.push(e);else t.value=[e]},S$=(e,t,n)=>{let r=e.value?e.value.slice():[];return r.length===2&&r[1]!==null&&(r=[]),r.length?za(t,r[0])?(r.unshift(t),n("range-start",r[0]),n("range-start",r[1])):(r[1]=t,n("range-end",t)):(r=[t],n("range-start",t)),e.value=r,r},nA=(e,t,n,r)=>{e[0]&&e[1]&&n&&t("auto-apply"),e[0]&&!e[1]&&r&&n&&t("auto-apply")},Efe=(e,t)=>{const{defaultedMultiCalendars:n,defaultedAriaLabels:r,defaultedTransitions:i}=Na(e),{modelValue:s,year:c,month:a,calendars:m}=M1(e,t),g=yt(()=>g$(e.formatLocale,e.locale,e.monthNameFormat)),x=yt(()=>Q2(e.yearRange,e.reverseYears)),T=jt(null),C=()=>{for(let ce=0;ce<n.value.count;ce++)if(ce===0)m.value[ce]=m.value[0];else{const fe=ho(an(),m.value[ce-1]);m.value[ce]={month:mi(fe),year:ai(B2(fe,ce))}}},A=ce=>{if(!ce)return C();const fe=ho(an(),m.value[ce]);return m.value[0].year=ai(h$(fe,n.value.count-1)),C()},P=ce=>e.focusStartDate?ce[0]:ce[1]?ce[1]:ce[0],D=()=>{if(s.value){const ce=Array.isArray(s.value)?P(s.value):s.value;m.value[0]={month:mi(ce),year:ai(ce)}}};Dr(()=>{D(),n.value.count&&C()});const B=yt(()=>(ce,fe)=>{const ie=ho(Sc(new Date),{month:a.value(ce),year:c.value(ce)});return w$(ie,e.maxDate,e.minDate,e.preventMinMaxNavigation,fe)}),R=ce=>ce?{month:mi(ce),year:ai(ce)}:{month:null,year:null},N=()=>s.value?Array.isArray(s.value)?s.value.map(ce=>R(ce)):R(s.value):R(),j=(ce,fe)=>{const ie=m.value[ce],xe=N();return Array.isArray(xe)?xe.some(Te=>Te.year===(ie==null?void 0:ie.year)&&Te.month===fe):(ie==null?void 0:ie.year)===xe.year&&fe===xe.month},U=(ce,fe,ie)=>{var xe,Te;const oe=N();return Array.isArray(oe)?c.value(fe)===((xe=oe[ie])==null?void 0:xe.year)&&ce===((Te=oe[ie])==null?void 0:Te.month):!1},W=(ce,fe)=>{if(e.range){const ie=N();if(Array.isArray(s.value)&&Array.isArray(ie)){const xe=U(ce,fe,0)||U(ce,fe,1),Te=Ju(Sc(an()),ce,c.value(fe));return J2(s.value,T.value,Te)&&!xe}return!1}return!1},Q=yt(()=>ce=>_g(g.value,fe=>{const ie=j(ce,fe.value),xe=rv(fe.value,_$(c.value(ce),e.minDate),v$(c.value(ce),e.maxDate))||Zde(e.disabledDates,c.value(ce)).includes(fe.value),Te=W(fe.value,ce);return{active:ie,disabled:xe,isBetween:Te}})),Z=yt(()=>ce=>_g(x.value,fe=>{const ie=c.value(ce)===fe.value,xe=rv(fe.value,vg(e.minDate),vg(e.maxDate));return{active:ie,disabled:xe}})),K=(ce,fe)=>Ju(Sc(an()),ce,c.value(fe)),Y=(ce,fe)=>{const ie=s.value?s.value:Sc(new Date);s.value=Ju(ie,ce,c.value(fe)),t("auto-apply")},me=(ce,fe)=>{const ie=S$(s,K(ce,fe),t);nA(ie,t,e.autoApply,e.modelAuto)},ge=(ce,fe)=>{tA(K(ce,fe),s,e.multiDatesLimit),t("auto-apply",!0)};return{groupedMonths:Q,groupedYears:Z,year:c,isDisabled:B,defaultedMultiCalendars:n,defaultedAriaLabels:r,defaultedTransitions:i,setHoverDate:(ce,fe)=>{T.value=K(ce,fe)},selectMonth:(ce,fe)=>(m.value[fe].month=ce,e.multiDates?ge(ce,fe):e.range?me(ce,fe):Y(ce,fe)),selectYear:(ce,fe)=>{m.value[fe].year=ce,n.value.count&&!n.value.solo&&A(fe)}}},Sfe={class:"dp__month_picker_header"},Cfe=["aria-label","onClick","onKeydown"],kfe=sr({compatConfig:{MODE:3},__name:"MonthPicker",props:{...uh},emits:["update:internal-model-value","overlay-closed","reset-flow","range-start","range-end","auto-apply"],setup(e,{emit:t}){const n=e,{groupedMonths:r,groupedYears:i,year:s,isDisabled:c,defaultedMultiCalendars:a,defaultedAriaLabels:m,defaultedTransitions:g,setHoverDate:x,selectMonth:T,selectYear:C}=Efe(n,t),{transitionName:A,showTransition:P}=Fv(g),{showRightIcon:D,showLeftIcon:B}=I1(),R=jt([!1]),N=(W,Q)=>{C(W,Q),U(Q)},j=(W,Q=!1)=>{if(!c.value(W,Q)){const Z=Q?s.value(W)+1:s.value(W)-1;C(Z,W)}},U=(W,Q=!1,Z)=>{Q||t("reset-flow"),Z!==void 0?R.value[W]=Z:R.value[W]=!R.value[W],R.value||t("overlay-closed")};return(W,Q)=>(At(),Tr(eA,{"multi-calendars":bt(a).count,stretch:""},{default:wr(({instance:Z})=>[sn(iv,{items:bt(r)(Z),"arrow-navigation":W.arrowNavigation,"is-last":W.autoApply&&!W.keepActionRow,"esc-close":W.escClose,height:W.modeHeight,onSelected:K=>bt(T)(K,Z),onHoverValue:K=>bt(x)(K,Z),"use-relative":"",type:"month"},{header:wr(()=>{var K,Y,me;return[Un("div",Sfe,[bt(B)(bt(a),Z)?(At(),Tr(C_,{key:0,ref:"mpPrevIconRef","aria-label":(K=bt(m))==null?void 0:K.prevYear,disabled:bt(c)(Z,!1),onActivate:ge=>j(Z,!1)},{default:wr(()=>[W.$slots["arrow-left"]?En(W.$slots,"arrow-left",{key:0}):hn("",!0),W.$slots["arrow-left"]?hn("",!0):(At(),Tr(bt(G2),{key:1}))]),_:2},1032,["aria-label","disabled","onActivate"])):hn("",!0),Un("div",{class:"dp--year-select",role:"button",ref:"mpYearButtonRef","aria-label":(Y=bt(m))==null?void 0:Y.openYearsOverlay,tabindex:"0",onClick:()=>U(Z,!1),onKeydown:br(()=>U(Z,!1),["enter"])},[W.$slots.year?En(W.$slots,"year",{key:0,year:bt(s)(Z)}):hn("",!0),W.$slots.year?hn("",!0):(At(),Wt(Hn,{key:1},[mu(Ba(bt(s)(Z)),1)],64))],40,Cfe),bt(D)(bt(a),Z)?(At(),Tr(C_,{key:1,ref:"mpNextIconRef","aria-label":(me=bt(m))==null?void 0:me.nextYear,disabled:bt(c)(Z,!1),onActivate:ge=>j(Z,!0)},{default:wr(()=>[W.$slots["arrow-right"]?En(W.$slots,"arrow-right",{key:0}):hn("",!0),W.$slots["arrow-right"]?hn("",!0):(At(),Tr(bt(q2),{key:1}))]),_:2},1032,["aria-label","disabled","onActivate"])):hn("",!0),sn(bs,{name:bt(A)(R.value[Z]),css:bt(P)},{default:wr(()=>
1435[R.value[Z]?(At(),Tr(iv,{key:0,items:bt(i)(Z),"text-input":W.textInput,"esc-close":W.escClose,onToggle:ge=>U(Z),onSelected:ge=>N(ge,Z),"is-last":W.autoApply&&!W.keepActionRow,type:"year"},pl({"button-icon":wr(()=>[W.$slots["calendar-icon"]?En(W.$slots,"calendar-icon",{key:0}):hn("",!0),W.$slots["calendar-icon"]?hn("",!0):(At(),Tr(bt(Rv),{key:1}))]),_:2},[W.$slots["year-overlay-value"]?{name:"item",fn:wr(({item:ge})=>[En(W.$slots,"year-overlay-value",{text:ge.text,value:ge.value})]),key:"0"}:void 0]),1032,["items","text-input","esc-close","onToggle","onSelected","is-last"])):hn("",!0)]),_:2},1032,["name","css"])])]}),_:2},1032,["items","arrow-navigation","is-last","esc-close","height","onSelected","onHoverValue"])]),_:3},8,["multi-calendars"]))}}),Afe=(e,t)=>{const{modelValue:n}=M1(e,t),r=jt(null),i=m=>Array.isArray(n.value)?n.value.some(g=>ai(g)===m):n.value?ai(n.value)===m:!1,s=m=>e.range&&Array.isArray(n.value)?J2(n.value,r.value,a(m)):!1,c=yt(()=>_g(Q2(e.yearRange,e.reverseYears),m=>{const g=i(m.value),x=rv(m.value,vg(e.minDate),vg(e.maxDate)),T=s(m.value);return{active:g,disabled:x,isBetween:T}})),a=m=>up(Sc(new Date),m);return{groupedYears:c,setHoverValue:m=>{r.value=up(Sc(new Date),m)},selectYear:m=>{if(e.multiDates)return tA(a(m),n,e.multiDatesLimit),t("auto-apply",!0);if(e.range){const g=S$(n,a(m),t);return nA(g,t,e.autoApply,e.modelAuto)}n.value=a(m),t("auto-apply")}}},Pfe=sr({compatConfig:{MODE:3},__name:"YearPicker",props:{...uh},emits:["update:internal-model-value","reset-flow","range-start","range-end","auto-apply"],setup(e,{emit:t}){const n=e,{groupedYears:r,selectYear:i,setHoverValue:s}=Afe(n,t);return(c,a)=>(At(),Tr(iv,{items:bt(r),"is-last":c.autoApply&&!c.keepActionRow,height:c.modeHeight,type:"year","use-relative":"",onSelected:bt(i),onHoverValue:bt(s)},pl({_:2},[c.$slots["year-overlay-value"]?{name:"item",fn:wr(({item:m})=>[En(c.$slots,"year-overlay-value",{text:m.text,value:m.value})]),key:"0"}:void 0]),1032,["items","is-last","height","onSelected","onHoverValue"]))}}),Mfe={key:0,class:"dp__time_input"},Ife=["aria-label","onKeydown","onClick"],Ofe=Un("span",{class:"dp__tp_inline_btn_bar dp__tp_btn_in_l"},null,-1),Dfe=Un("span",{class:"dp__tp_inline_btn_bar dp__tp_btn_in_r"},null,-1),Lfe=["aria-label","disabled","onKeydown","onClick"],Rfe=["aria-label","onKeydown","onClick"],Ffe=Un("span",{class:"dp__tp_inline_btn_bar dp__tp_btn_in_l"},null,-1),Bfe=Un("span",{class:"dp__tp_inline_btn_bar dp__tp_btn_in_r"},null,-1),zfe={key:0},Nfe=["aria-label","onKeydown"],$fe=sr({compatConfig:{MODE:3},__name:"TimeInput",props:{hours:{type:Number,default:0},minutes:{type:Number,default:0},seconds:{type:Number,default:0},closeTimePickerBtn:{type:Object,default:null},order:{type:Number,default:0},disabledTimesConfig:{type:Function,default:null},...uh},emits:["set-hours","set-minutes","update:hours","update:minutes","update:seconds","reset-flow","mounted","overlay-closed","am-pm-change"],setup(e,{expose:t,emit:n}){const r=e,{setTimePickerElements:i,setTimePickerBackRef:s}=$d(),{defaultedAriaLabels:c,defaultedTransitions:a,defaultedFilters:m}=Na(r),{transitionName:g,showTransition:x}=Fv(a),T=so({hours:!1,minutes:!1,seconds:!1}),C=jt("AM"),A=jt(null),P=jt([]);Dr(()=>{n("mounted")});const D=Se=>ho(new Date,{hours:Se.hours,minutes:Se.minutes,seconds:r.enableSeconds?Se.seconds:0,milliseconds:0}),B=yt(()=>Se=>me(Se,r[Se])),R=yt(()=>({hours:r.hours,minutes:r.minutes,seconds:r.seconds})),N=yt(()=>Se=>!ce(+r[Se]+ +r[`${Se}Increment`],Se)),j=yt(()=>Se=>!ce(+r[Se]-+r[`${Se}Increment`],Se)),U=(Se,xt)=>G4(ho(an(),Se),xt),W=(Se,xt)=>cde(ho(an(),Se),xt),Q=yt(()=>({dp__time_col:!0,dp__time_col_block:!r.timePickerInline,dp__time_col_reg_block:!r.enableSeconds&&r.is24&&!r.timePickerInline,dp__time_col_reg_inline:!r.enableSeconds&&r.is24&&r.timePickerInline,dp__time_col_reg_with_button:!r.enableSeconds&&!r.is24,dp__time_col_sec:r.enableSeconds&&r.is24,dp__time_col_sec_with_button:r.enableSeconds&&!r.is24})),Z=yt(()=>{const Se=[{type:"hours"},{type:"",separator:!0},{type:"minutes"}];return r.enableSeconds?Se.concat([{type:"",separator:!0},{type:"seconds"}]):Se}),K=yt(()=>Z.value.filter(Se=>!Se.separator)),Y=yt(()=>Se=>{if(Se==="hours"){const xt=oe(+r.hours);return{text:xt<10?`0${xt}`:`${xt}`,value:xt}}return{text:r[Se]<10?`0${r[Se]}`:`${r[Se]}`,value:r[Se]}}),me=(Se,xt)=>{var kt;if(!r.disabledTimesConfig)return!1;const wt=r.disabledTimesConfig(r.order,Se==="hours"?xt:void 0);return wt[Se]?!!((kt=wt[Se])!=null&&kt.includes(xt)):!0},ge=Se=>{const xt=r.is24?24:12,kt=Se==="hours"?xt:60,wt=+r[`${Se}GridIncrement`],Ue=Se==="hours"&&!r.is24?wt:0,je=[];for(let st=Ue;st<kt;st+=wt)je.push({value:st,text:st<10?`0${st}`:`${st}`});return Se==="hours"&&!r.is24&&je.push({value:0,text:"12"}),_g(je,st=>({active:!1,disabled:m.value.times[Se].includes(st.value)||!ce(st.value,Se)||me(Se,st.value)}))},ce=(Se,xt)=>{const kt=r.minTime?D(mE(r.minTime)):null,wt=r.maxTime?D(mE(r.maxTime)):null,Ue=D(mE(R.value,xt,Se));return kt&&wt?(nv(Ue,wt)||Om(Ue,wt))&&(tv(Ue,kt)||Om(Ue,kt)):kt?tv(Ue,kt)||Om(Ue,kt):wt?nv(Ue,wt)||Om(Ue,wt):!0},fe=Se=>r[`no${Se[0].toUpperCase()+Se.slice(1)}Overlay`],ie=Se=>{fe(Se)||(T[Se]=!T[Se],T[Se]||n("overlay-closed"))},xe=Se=>Se==="hours"?fu:Se==="minutes"?pu:gg,Te=(Se,xt=!0)=>{const kt=xt?U:W,wt=xt?+r[`${Se}Increment`]:-+r[`${Se}Increment`];ce(+r[Se]+wt,Se)&&n(`update:${Se}`,xe(Se)(kt({[Se]:+r[Se]},{[Se]:+r[`${Se}Increment`]})))},oe=Se=>r.is24?Se:(Se>=12?C.value="PM":C.value="AM",zde(Se)),ne=()=>{C.value==="PM"?(C.value="AM",n("update:hours",r.hours-12)):(C.value="PM",n("update:hours",r.hours+12)),n("am-pm-change",C.value)},le=Se=>{T[Se]=!0},se=(Se,xt,kt)=>{if(Se&&r.arrowNavigation){Array.isArray(P.value[xt])?P.value[xt][kt]=Se:P.value[xt]=[Se];const wt=P.value.reduce((Ue,je)=>je.map((st,tt)=>[...Ue[tt]||[],je[tt]]),[]);s(r.closeTimePickerBtn),A.value&&(wt[1]=wt[1].concat(A.value)),i(wt,r.order)}},Ne=(Se,xt)=>(ie(Se),Se==="hours"&&!r.is24?n(`update:${Se}`,C.value==="PM"?xt+12:xt):n(`update:${Se}`,xt));
1435return t({openChildCmp:le}),(Se,xt)=>{var kt;return Se.disabled?hn("",!0):(At(),Wt("div",Mfe,[(At(!0),Wt(Hn,null,$o(Z.value,(wt,Ue)=>{var je,st,tt;return At(),Wt("div",{key:Ue,class:qr(Q.value)},[wt.separator?(At(),Wt(Hn,{key:0},[mu(" : ")],64)):(At(),Wt(Hn,{key:1},[Un("button",{type:"button",class:qr({dp__btn:!0,dp__inc_dec_button:!r.timePickerInline,dp__inc_dec_button_inline:r.timePickerInline,dp__tp_inline_btn_top:r.timePickerInline,dp__inc_dec_button_disabled:N.value(wt.type)}),"aria-label":(je=bt(c))==null?void 0:je.incrementValue(wt.type),tabindex:"0",onKeydown:[br(Di(Me=>Te(wt.type),["prevent"]),["enter"]),br(Di(Me=>Te(wt.type),["prevent"]),["space"])],onClick:Me=>Te(wt.type),ref_for:!0,ref:Me=>se(Me,Ue,0)},[r.timePickerInline?(At(),Wt(Hn,{key:1},[Ofe,Dfe],64)):(At(),Wt(Hn,{key:0},[Se.$slots["arrow-up"]?En(Se.$slots,"arrow-up",{key:0}):hn("",!0),Se.$slots["arrow-up"]?hn("",!0):(At(),Tr(bt(H2),{key:1}))],64))],42,Ife),Un("button",{type:"button","aria-label":(st=bt(c))==null?void 0:st.openTpOverlay(wt.type),class:qr({dp__time_display:!0,dp__time_display_block:!r.timePickerInline,dp__time_display_inline:r.timePickerInline,"dp--time-invalid":B.value(wt.type),"dp--time-overlay-btn":!B.value(wt.type)}),disabled:fe(wt.type),tabindex:"0",onKeydown:[br(Di(Me=>ie(wt.type),["prevent"]),["enter"]),br(Di(Me=>ie(wt.type),["prevent"]),["space"])],onClick:Me=>ie(wt.type),ref_for:!0,ref:Me=>se(Me,Ue,1)},[Se.$slots[wt.type]?En(Se.$slots,wt.type,{key:0,text:Y.value(wt.type).text,value:Y.value(wt.type).value}):hn("",!0),Se.$slots[wt.type]?hn("",!0):(At(),Wt(Hn,{key:1},[mu(Ba(Y.value(wt.type).text),1)],64))],42,Lfe),Un("button",{type:"button",class:qr({dp__btn:!0,dp__inc_dec_button:!r.timePickerInline,dp__inc_dec_button_inline:r.timePickerInline,dp__tp_inline_btn_bottom:r.timePickerInline,dp__inc_dec_button_disabled:j.value(wt.type)}),"aria-label":(tt=bt(c))==null?void 0:tt.decrementValue(wt.type),tabindex:"0",onKeydown:[br(Di(Me=>Te(wt.type,!1),["prevent"]),["enter"]),br(Di(Me=>Te(wt.type,!1),["prevent"]),["space"])],onClick:Me=>Te(wt.type,!1),ref_for:!0,ref:Me=>se(Me,Ue,2)},[r.timePickerInline?(At(),Wt(Hn,{key:1},[Ffe,Bfe],64)):(At(),Wt(Hn,{key:0},[Se.$slots["arrow-down"]?En(Se.$slots,"arrow-down",{key:0}):hn("",!0),Se.$slots["arrow-down"]?hn("",!0):(At(),Tr(bt(Y2),{key:1}))],64))],42,Rfe)],64))],2)}),128)),Se.is24?hn("",!0):(At(),Wt("div",zfe,[Se.$slots["am-pm-button"]?En(Se.$slots,"am-pm-button",{key:0,toggle:ne,value:C.value}):hn("",!0),Se.$slots["am-pm-button"]?hn("",!0):(At(),Wt("button",{key:1,ref_key:"amPmButton",ref:A,type:"button",class:"dp__pm_am_button",role:"button","aria-label":(kt=bt(c))==null?void 0:kt.amPmButton,tabindex:"0",onClick:ne,onKeydown:[br(Di(ne,["prevent"]),["enter"]),br(Di(ne,["prevent"]),["space"])]},Ba(C.value),41,Nfe))])),(At(!0),Wt(Hn,null,$o(K.value,(wt,Ue)=>(At(),Tr(bs,{key:Ue,name:bt(g)(T[wt.type]),css:bt(x)},{default:wr(()=>[T[wt.type]?(At(),Tr(iv,{key:0,items:ge(wt.type),"is-last":Se.autoApply&&!Se.keepActionRow,"esc-close":Se.escClose,type:wt.type,"text-input":Se.textInput,"arrow-navigation":Se.arrowNavigation,onSelected:je=>Ne(wt.type,je),onToggle:je=>ie(wt.type),onResetFlow:xt[0]||(xt[0]=je=>Se.$emit("reset-flow"))},pl({"button-icon":wr(()=>[Se.$slots["clock-icon"]?En(Se.$slots,"clock-icon",{key:0}):hn("",!0),Se.$slots["clock-icon"]?hn("",!0):(At(),Tr(bt(W2),{key:1}))]),_:2},[Se.$slots[`${wt.type}-overlay-value`]?{name:"item",fn:wr(({item:je})=>[En(Se.$slots,`${wt.type}-overlay-value`,{text:je.text,value:je.value})]),key:"0"}:void 0]),1032,["items","is-last","esc-close","type","text-input","arrow-navigation","onSelected","onToggle"])):hn("",!0)]),_:2},1032,["name","css"]))),128))]))}}}),jfe=["aria-label"],Ufe=["tabindex"],Vfe=["aria-label"],C$=sr({compatConfig:{MODE:3},__name:"TimePicker",props:{hours:{type:[Number,Array],default:0},minutes:{type:[Number,Array],default:0},seconds:{type:[Number,Array],default:0},disabledTimesConfig:{type:Function,default:null},...uh},emits:["update:hours","update:minutes","update:seconds","mount","reset-flow","overlay-opened","overlay-closed","am-pm-change"],setup(e,{expose:t,emit:n}){const r=e,{buildMatrix:i,setTimePicker:s}=$d(),c=Sv(),{defaultedTransitions:a,defaultedAriaLabels:m,defaultedTextInput:g}=Na(r),{transitionName:x,showTransition:T}=Fv(a),{hideNavigationButtons:C}=I1(),A=jt(null),P=jt(null),D=jt([]),B=jt(null);Dr(()=>{n("mount"),!r.timePicker&&r.arrowNavigation?i([ca(A.value)],"time"):s(!0,r.timePicker)});const R=yt(()=>r.range&&r.modelAuto?y$(r.internalModelValue):!0),N=jt(!1),j=fe=>({hours:Array.isArray(r.hours)?r.hours[fe]:r.hours,minutes:Array.isArray(r.minutes)?r.minutes[fe]:r.minutes,seconds:Array.isArray(r.seconds)?r.seconds[fe]:r.seconds}),U=yt(()=>{const fe=[];if(r.range)for(let ie=0;ie<2;ie++)fe.push(j(ie));else fe.push(j(0));return fe}),W=(fe,ie=!1,xe="")=>{ie||n("reset-flow"),N.value=fe,n(fe?"overlay-opened":"overlay-closed"),r.arrowNavigation&&s(fe),Qi(()=>{xe!==""&&D.value[0]&&D.value[0].openChildCmp(xe)})},Q=yt(()=>({dp__btn:!0,dp__button:!0,dp__button_bottom:r.autoApply&&!r.keepActionRow})),Z=kc(c,"timePicker"),K=(fe,ie,xe)=>r.range?ie===0?[fe,U.value[1][xe]]:[U.value[0][xe],fe]:fe,Y=fe=>{n("update:hours",fe)},me=fe=>{n("update:minutes",fe)},ge=fe=>{n("update:seconds",fe)},ce=()=>{if(B.value&&!g.value.enabled){const fe=$de(B.value);fe&&fe.focus({preventScroll:!0})}};return t({toggleTimePicker:W}),(fe,ie)=>{var xe;return At(),Wt("div",null,[!fe.timePicker&&!fe.timePickerInline?pd((At(),Wt("button",{key:0,t
1435ype:"button",class:qr(Q.value),"aria-label":(xe=bt(m))==null?void 0:xe.openTimePicker,tabindex:"0",ref_key:"openTimePickerBtn",ref:A,onKeydown:[ie[0]||(ie[0]=br(Te=>W(!0),["enter"])),ie[1]||(ie[1]=br(Te=>W(!0),["space"]))],onClick:ie[2]||(ie[2]=Te=>W(!0))},[fe.$slots["clock-icon"]?En(fe.$slots,"clock-icon",{key:0}):hn("",!0),fe.$slots["clock-icon"]?hn("",!0):(At(),Tr(bt(W2),{key:1}))],42,jfe)),[[gd,!bt(C)(fe.hideNavigation,"time")]]):hn("",!0),sn(bs,{name:bt(x)(N.value),css:bt(T)&&!fe.timePickerInline},{default:wr(()=>{var Te;return[N.value||fe.timePicker||fe.timePickerInline?(At(),Wt("div",{key:0,class:qr({dp__overlay:!fe.timePickerInline,"dp--overlay-absolute":!r.timePicker&&!fe.timePickerInline,"dp--overlay-relative":r.timePicker}),style:Sa(fe.timePicker?{height:`${fe.modeHeight}px`}:void 0),ref_key:"overlayRef",ref:B,tabindex:fe.timePickerInline?void 0:0},[Un("div",{class:qr(fe.timePickerInline?"dp__time_picker_inline_container":"dp__overlay_container dp__container_flex dp__time_picker_overlay_container"),style:{display:"flex"}},[fe.$slots["time-picker-overlay"]?En(fe.$slots,"time-picker-overlay",{key:0,hours:e.hours,minutes:e.minutes,seconds:e.seconds,setHours:Y,setMinutes:me,setSeconds:ge}):hn("",!0),fe.$slots["time-picker-overlay"]?hn("",!0):(At(),Wt("div",{key:1,class:qr(fe.timePickerInline?"dp__flex":"dp__overlay_row dp__flex_row")},[(At(!0),Wt(Hn,null,$o(U.value,(oe,ne)=>pd((At(),Tr($fe,Li({key:ne},{...fe.$props,order:ne,hours:oe.hours,minutes:oe.minutes,seconds:oe.seconds,closeTimePickerBtn:P.value,disabledTimesConfig:e.disabledTimesConfig,disabled:ne===0?fe.fixedStart:fe.fixedEnd},{ref_for:!0,ref_key:"timeInputRefs",ref:D,"onUpdate:hours":le=>Y(K(le,ne,"hours")),"onUpdate:minutes":le=>me(K(le,ne,"minutes")),"onUpdate:seconds":le=>ge(K(le,ne,"seconds")),onMounted:ce,onOverlayClosed:ce,onAmPmChange:ie[3]||(ie[3]=le=>fe.$emit("am-pm-change",le))}),pl({_:2},[$o(bt(Z),(le,se)=>({name:le,fn:wr(Ne=>[En(fe.$slots,le,ys(dl(Ne)))])}))]),1040,["onUpdate:hours","onUpdate:minutes","onUpdate:seconds"])),[[gd,ne===0?!0:R.value]])),128))],2)),!fe.timePicker&&!fe.timePickerInline?pd((At(),Wt("button",{key:2,type:"button",ref_key:"closeTimePickerBtn",ref:P,class:qr(Q.value),"aria-label":(Te=bt(m))==null?void 0:Te.closeTimePicker,tabindex:"0",onKeydown:[ie[4]||(ie[4]=br(oe=>W(!1),["enter"])),ie[5]||(ie[5]=br(oe=>W(!1),["space"]))],onClick:ie[6]||(ie[6]=oe=>W(!1))},[fe.$slots["calendar-icon"]?En(fe.$slots,"calendar-icon",{key:0}):hn("",!0),fe.$slots["calendar-icon"]?hn("",!0):(At(),Tr(bt(Rv),{key:1}))],42,Vfe)),[[gd,!bt(C)(fe.hideNavigation,"time")]]):hn("",!0)],2)],14,Ufe)):hn("",!0)]}),_:3},8,["name","css"])])}}}),k$=(e,t,n,r)=>{const i=(R,N)=>Array.isArray(t[R])?t[R][N]:t[R],s=R=>e.enableSeconds?Array.isArray(t.seconds)?t.seconds[R]:t.seconds:0,c=(R,N)=>R?N!==void 0?xd(R,i("hours",N),i("minutes",N),s(N)):xd(R,t.hours,t.minutes,s()):an(),a=(R,N)=>{t[R]=N},m=(R,N)=>{const j=Object.fromEntries(Object.keys(t).map(U=>U===R?[U,N]:[U,t[U]].slice()));if(e.range&&!e.disableTimeRangeValidation){const U=Q=>n.value?xd(n.value[Q],j.hours[Q],j.minutes[Q],j.seconds[Q]):null,W=Q=>V2(n.value[Q],0);return!(ki(U(0),U(1))&&(tv(U(0),W(1))||nv(U(1),W(0))))}return!0},g=(R,N)=>{m(R,N)&&(a(R,N),r&&r())},x=R=>{g("hours",R)},T=R=>{g("minutes",R)},C=R=>{g("seconds",R)},A=(R,N,j,U)=>{N&&x(R),!N&&!j&&T(R),j&&C(R),n.value&&U(n.value)},P=R=>{if(R){const N=Array.isArray(R),j=N?[+R[0].hours,+R[1].hours]:+R.hours,U=N?[+R[0].minutes,+R[1].minutes]:+R.minutes,W=N?[+R[0].seconds,+R[1].seconds]:+R.seconds;a("hours",j),a("minutes",U),e.enableSeconds&&a("seconds",W)}},D=(R,N)=>{const j={hours:Array.isArray(t.hours)?t.hours[R]:t.hours,disabledArr:[]};return(N||N===0)&&(j.hours=N),Array.isArray(e.disabledTimes)&&(j.disabledArr=e.range&&Array.isArray(e.disabledTimes[R])?e.disabledTimes[R]:e.disabledTimes),j},B=yt(()=>(R,N)=>{var j;if(Array.isArray(e.disabledTimes)){const{disabledArr:U,hours:W}=D(R,N),Q=U.filter(Z=>+Z.hours===W);return((j=Q[0])==null?void 0:j.minutes)==="*"?{hours:[W],minutes:void 0,seconds:void 0}:{hours:[],minutes:(Q==null?void 0:Q.map(Z=>+Z.minutes))??[],seconds:(Q==null?void 0:Q.map(Z=>Z.seconds?+Z.seconds:void 0))??[]}}return{hours:[],minutes:[],seconds:[]}});return{setTime:a,updateHours:x,updateMinutes:T,updateSeconds:C,get
1435SetDateTime:c,updateTimeValues:A,getSecondsValue:s,assignStartTime:P,disabledTimesConfig:B}},Gfe=(e,t)=>{const{modelValue:n,time:r}=M1(e,t),{defaultedStartTime:i}=Na(e),{updateTimeValues:s,getSetDateTime:c,setTime:a,assignStartTime:m,disabledTimesConfig:g}=k$(e,r,n),x=R=>{const{hours:N,minutes:j,seconds:U}=R;return{hours:+N,minutes:+j,seconds:U?+U:0}},T=()=>{if(e.startTime){if(Array.isArray(e.startTime)){const N=x(e.startTime[0]),j=x(e.startTime[1]);return[ho(an(),N),ho(an(),j)]}const R=x(e.startTime);return ho(an(),R)}return e.range?[null,null]:null},C=()=>{if(e.range){const[R,N]=T();n.value=[c(R,0),c(N,1)]}else n.value=c(T())},A=R=>Array.isArray(R)?[hp(an(R[0])),hp(an(R[1]))]:[hp(R??an())],P=(R,N,j)=>{a("hours",R),a("minutes",N),e.enableSeconds&&a("seconds",j)},D=()=>{const[R,N]=A(n.value);return e.range?P([R.hours,N.hours],[R.minutes,N.minutes],[R.seconds,N.minutes]):P(R.hours,R.minutes,R.seconds)};Dr(()=>{if(!e.shadow)return m(i.value),n.value?D():C()});const B=()=>{Array.isArray(n.value)?n.value=n.value.map((R,N)=>R&&c(R,N)):n.value=c(n.value),t("time-update")};return{time:r,disabledTimesConfig:g,updateTime:(R,N=!0,j=!1)=>{s(R,N,j,B)}}},qfe=sr({compatConfig:{MODE:3},__name:"TimePickerSolo",props:{...uh},emits:["update:internal-model-value","time-update","am-pm-change"],setup(e,{emit:t}){const n=e,r=Sv(),i=kc(r,"timePicker"),{time:s,disabledTimesConfig:c,updateTime:a}=Gfe(n,t);return(m,g)=>(At(),Tr(eA,{"multi-calendars":0,stretch:""},{default:wr(()=>[sn(C$,Li(m.$props,{hours:bt(s).hours,minutes:bt(s).minutes,seconds:bt(s).seconds,"internal-model-value":m.internalModelValue,"disabled-times-config":bt(c),"onUpdate:hours":g[0]||(g[0]=x=>bt(a)(x)),"onUpdate:minutes":g[1]||(g[1]=x=>bt(a)(x,!1)),"onUpdate:seconds":g[2]||(g[2]=x=>bt(a)(x,!1,!0)),onAmPmChange:g[3]||(g[3]=x=>m.$emit("am-pm-change",x))}),pl({_:2},[$o(bt(i),(x,T)=>({name:x,fn:wr(C=>[En(m.$slots,x,ys(dl(C)))])}))]),1040,["hours","minutes","seconds","internal-model-value","disabled-times-config"])]),_:3}))}}),Wfe={class:"dp__month_year_row"},Hfe=["aria-label","onClick","onKeydown"],Yfe=sr({compatConfig:{MODE:3},__name:"DpHeader",props:{month:{type:Number,default:0},year:{type:Number,default:0},instance:{type:Number,default:0},years:{type:Array,default:()=>[]},months:{type:Array,default:()=>[]},...uh},emits:["update-month-year","mount","reset-flow","overlay-closed"],setup(e,{expose:t,emit:n}){const r=e,{defaultedTransitions:i,defaultedAriaLabels:s,defaultedMultiCalendars:c,defaultedFilters:a}=Na(r),{transitionName:m,showTransition:g}=Fv(i),{buildMatrix:x}=$d(),{handleMonthYearChange:T,isDisabled:C,updateMonthYear:A}=ofe(r,n),{showLeftIcon:P,showRightIcon:D}=I1(),B=jt(!1),R=jt(!1),N=jt([null,null,null,null]);Dr(()=>{n("mount")});const j=oe=>({get:()=>r[oe],set:ne=>{const le=oe===xc.month?xc.year:xc.month;n("update-month-year",{[oe]:ne,[le]:r[le]}),oe===xc.month?ge(!0):ce(!0)}}),U=yt(j(xc.month)),W=yt(j(xc.year)),Q=yt(()=>oe=>({month:r.month,year:r.year,items:oe===xc.month?r.months:r.years,instance:r.instance,updateMonthYear:A,toggle:oe===xc.month?ge:ce})),Z=yt(()=>r.months.find(ne=>ne.value===r.month)||{text:"",value:0}),K=yt(()=>_g(r.months,oe=>{const ne=r.month===oe.value,le=rv(oe.value,_$(r.year,r.minDate),v$(r.year,r.maxDate))||a.value.months.includes(oe.value);return{active:ne,disabled:le}})),Y=yt(()=>_g(r.years,oe=>{const ne=r.year===oe.value,le=rv(oe.value,vg(r.minDate),vg(r.maxDate))||a.value.years.includes(oe.value);return{active:ne,disabled:le}})),me=(oe,ne)=>{ne!==void 0?oe.value=ne:oe.value=!oe.value,oe.value||n("overlay-closed")},ge=(oe=!1,ne)=>{fe(oe),me(B,ne)},ce=(oe=!1,ne)=>{fe(oe),me(R,ne)},fe=oe=>{oe||n("reset-flow")},ie=(oe,ne)=>{r.arrowNavigation&&(N.value[ne]=ca(oe),x(N.value,"monthYear"))},xe=yt(()=>{var oe,ne;return[{type:xc.month,index:1,toggle:ge,modelValue:U.value,updateModelValue:le=>U.value=le,text:Z.value.text,showSelectionGrid:B.value,items:K.value,ariaLabel:(oe=s.value)==null?void 0:oe.openMonthsOverlay},{type:xc.year,index:2,toggle:ce,modelValue:W.value,updateModelValue:le=>W.value=le,text:r.year,showSelectionGrid:R.value,items:Y.value,ariaLabel:(ne=s.value)==null?void 0:ne.openYearsOverlay}]}),Te=yt(()=>r.disableYearSelect?[xe.value[0]]:xe.value);return t({toggleMonthPicker:ge,toggleYearPicker:ce,handleMonthYearChange:T}
1435),(oe,ne)=>{var le,se,Ne;return At(),Wt("div",Wfe,[oe.$slots["month-year"]?En(oe.$slots,"month-year",ys(Li({key:0},{month:e.month,year:e.year,months:e.months,years:e.years,updateMonthYear:bt(A),handleMonthYearChange:bt(T),instance:e.instance}))):(At(),Wt(Hn,{key:1},[bt(P)(bt(c),e.instance)&&!oe.vertical?(At(),Tr(C_,{key:0,"aria-label":(le=bt(s))==null?void 0:le.prevMonth,disabled:bt(C)(!1),onActivate:ne[0]||(ne[0]=Se=>bt(T)(!1)),onSetRef:ne[1]||(ne[1]=Se=>ie(Se,0))},{default:wr(()=>[oe.$slots["arrow-left"]?En(oe.$slots,"arrow-left",{key:0}):hn("",!0),oe.$slots["arrow-left"]?hn("",!0):(At(),Tr(bt(G2),{key:1}))]),_:3},8,["aria-label","disabled"])):hn("",!0),Un("div",{class:qr(["dp__month_year_wrap",{dp__year_disable_select:oe.disableYearSelect}])},[(At(!0),Wt(Hn,null,$o(Te.value,(Se,xt)=>(At(),Wt(Hn,{key:Se.type},[Un("button",{type:"button",class:"dp__btn dp__month_year_select",tabindex:"0","aria-label":Se.ariaLabel,ref_for:!0,ref:kt=>ie(kt,xt+1),onClick:Se.toggle,onKeydown:[br(Di(Se.toggle,["prevent"]),["enter"]),br(Di(Se.toggle,["prevent"]),["space"])]},[oe.$slots[Se.type]?En(oe.$slots,Se.type,{key:0,text:Se.text,value:r[Se.type]}):hn("",!0),oe.$slots[Se.type]?hn("",!0):(At(),Wt(Hn,{key:1},[mu(Ba(Se.text),1)],64))],40,Hfe),sn(bs,{name:bt(m)(Se.showSelectionGrid),css:bt(g)},{default:wr(()=>[Se.showSelectionGrid?(At(),Tr(iv,{key:0,items:Se.items,"arrow-navigation":oe.arrowNavigation,"hide-navigation":oe.hideNavigation,"is-last":oe.autoApply&&!oe.keepActionRow,"skip-button-ref":!1,type:Se.type,"header-refs":[],"esc-close":oe.escClose,"text-input":oe.textInput,onSelected:Se.updateModelValue,onToggle:Se.toggle},pl({"button-icon":wr(()=>[oe.$slots["calendar-icon"]?En(oe.$slots,"calendar-icon",{key:0}):hn("",!0),oe.$slots["calendar-icon"]?hn("",!0):(At(),Tr(bt(Rv),{key:1}))]),_:2},[oe.$slots[`${Se.type}-overlay-val`]?{name:"item",fn:wr(({item:kt})=>[En(oe.$slots,`${Se.type}-overlay-val`,{text:kt.text,value:kt.value})]),key:"0"}:void 0,oe.$slots[`${Se.type}-overlay`]?{name:"overlay",fn:wr(()=>[En(oe.$slots,`${Se.type}-overlay`,ys(dl(Q.value(Se.type))))]),key:"1"}:void 0,oe.$slots[`${Se.type}-overlay-header`]?{name:"header",fn:wr(()=>[En(oe.$slots,`${Se.type}-overlay-header`,{toggle:Se.toggle})]),key:"2"}:void 0]),1032,["items","arrow-navigation","hide-navigation","is-last","type","esc-close","text-input","onSelected","onToggle"])):hn("",!0)]),_:2},1032,["name","css"])],64))),128))],2),bt(P)(bt(c),e.instance)&&oe.vertical?(At(),Tr(C_,{key:1,"aria-label":(se=bt(s))==null?void 0:se.prevMonth,disabled:bt(C)(!1),onActivate:ne[2]||(ne[2]=Se=>bt(T)(!1))},{default:wr(()=>[oe.$slots["arrow-up"]?En(oe.$slots,"arrow-up",{key:0}):hn("",!0),oe.$slots["arrow-up"]?hn("",!0):(At(),Tr(bt(H2),{key:1}))]),_:3},8,["aria-label","disabled"])):hn("",!0),bt(D)(bt(c),e.instance)?(At(),Tr(C_,{key:2,ref:"rightIcon",disabled:bt(C)(!0),"aria-label":(Ne=bt(s))==null?void 0:Ne.nextMonth,onActivate:ne[3]||(ne[3]=Se=>bt(T)(!0)),onSetRef:ne[4]||(ne[4]=Se=>ie(Se,oe.disableYearSelect?2:3))},{default:wr(()=>[oe.$slots[oe.vertical?"arrow-down":"arrow-right"]?En(oe.$slots,oe.vertical?"arrow-down":"arrow-right",{key:0}):hn("",!0),oe.$slots[oe.vertical?"arrow-down":"arrow-right"]?hn("",!0):(At(),Tr(Ev(oe.vertical?bt(Y2):bt(q2)),{key:1}))]),_:3},8,["disabled","aria-label"])):hn("",!0)],64))])}}}),Zfe=["aria-label"],Xfe={class:"dp__calendar_header",role:"row"},Kfe={key:0,class:"dp__calendar_header_item",role:"gridcell"},Qfe=Un("div",{class:"dp__calendar_header_separator"},null,-1),Jfe=["aria-label"],epe={key:0,role:"gridcell",class:"dp__calendar_item dp__week_num"},tpe={class:"dp__cell_inner"},npe=["aria-selected","aria-disabled","aria-label","onClick","onKeydown","onMouseenter","onMouseleave"],rpe=sr({compatConfig:{MODE:3},__name:"DpCalendar",props:{mappedDates:{type:Array,default:()=>[]},instance:{type:Number,default:0},month:{type:Number,default:0},year:{type:Number,default:0},...uh},emits:["select-date","set-hover-date","handle-scroll","mount","handle-swipe","handle-space","tooltip-open","tooltip-close"],setup(e,{expose:t,emit:n}){const r=e,{buildMultiLevelMatrix:i}=$d(),{defaultedTransitions:s,defaultedAriaLabels:c,defaultedMultiCalendars:a}=Na(r),m=jt(null),g=jt({bottom:"",left:"",transform:""}),x=jt([]),T=jt(null),C=jt(!0),A=jt(""),P=jt({startX:0,endX:0,startY:0,endY:0}),D=jt([]),B=jt({left:"50%"}),R=yt(()=>r.calendar?r.calendar(r.mappedDates):r.mappedDates),N=yt(()=>r.dayNames?Array.isArray(r.dayNames)?r.dayNames:r.dayNames(r.locale,+r.weekStart):Bde(r.formatLocale,r.locale,+r.weekStart));Dr(()=>{n("mount",{cmp:"calendar",refs:x}),r.noSwipe||T.value&&(T.value.addEventListener("touchstart",ce,{passive:!1}),T.value.addEventListener("touchend",fe,{passive:!1}),T.value.addEventListener("touchmove",ie,{passive:!1}
1435)),r.monthChangeOnScroll&&T.value&&T.value.addEventListener("wheel",oe,{passive:!1})});const j=le=>le?r.vertical?"vNext":"next":r.vertical?"vPrevious":"previous",U=(le,se)=>{if(r.transitions){const Ne=Xl(Ju(an(),r.month,r.year));A.value=es(Xl(Ju(an(),le,se)),Ne)?s.value[j(!0)]:s.value[j(!1)],C.value=!1,Qi(()=>{C.value=!0})}},W=yt(()=>({[r.calendarClassName]:!!r.calendarClassName})),Q=yt(()=>le=>{const se=Nde(le);return{dp__marker_dot:se.type==="dot",dp__marker_line:se.type==="line"}}),Z=yt(()=>le=>ki(le,m.value)),K=yt(()=>({dp__calendar:!0,dp__calendar_next:a.value.count>0&&r.instance!==0})),Y=yt(()=>le=>r.hideOffsetDates?le.current:!0),me=async(le,se,Ne)=>{var Se,xt;if(n("set-hover-date",le),(xt=(Se=le.marker)==null?void 0:Se.tooltip)!=null&&xt.length){const kt=ca(x.value[se][Ne]);if(kt){const{width:wt,height:Ue}=kt.getBoundingClientRect();m.value=le.value;let je={left:`${wt/2}px`},st=-50;if(await Qi(),D.value[0]){const{left:tt,width:Me}=D.value[0].getBoundingClientRect();tt<0&&(je={left:"0"},st=0,B.value.left=`${wt/2}px`),window.innerWidth<tt+Me&&(je={right:"0"},st=0,B.value.left=`${Me-wt/2}px`)}g.value={bottom:`${Ue}px`,...je,transform:`translateX(${st}%)`},n("tooltip-open",le.marker)}}},ge=le=>{m.value&&(m.value=null,g.value=JSON.parse(JSON.stringify({bottom:"",left:"",transform:""})),n("tooltip-close",le.marker))},ce=le=>{P.value.startX=le.changedTouches[0].screenX,P.value.startY=le.changedTouches[0].screenY},fe=le=>{P.value.endX=le.changedTouches[0].screenX,P.value.endY=le.changedTouches[0].screenY,xe()},ie=le=>{r.vertical&&!r.inline&&le.preventDefault()},xe=()=>{const le=r.vertical?"Y":"X";Math.abs(P.value[`start${le}`]-P.value[`end${le}`])>10&&n("handle-swipe",P.value[`start${le}`]>P.value[`end${le}`]?"right":"left")},Te=(le,se,Ne)=>{le&&(Array.isArray(x.value[se])?x.value[se][Ne]=le:x.value[se]=[le]),r.arrowNavigation&&i(x.value,"calendar")},oe=le=>{r.monthChangeOnScroll&&(le.preventDefault(),n("handle-scroll",le))},ne=le=>{const se=le[0];return r.weekNumbers==="local"?Yue(se.value,{weekStartsOn:+r.weekStart}):r.weekNumbers==="iso"?Gue(se.value):typeof r.weekNumbers=="function"?r.weekNumbers(se.value):""};return t({triggerTransition:U}),(le,se)=>{var Ne;return At(),Wt("div",{class:qr(K.value)},[Un("div",{ref_key:"calendarWrapRef",ref:T,role:"grid",class:qr(W.value),"aria-label":(Ne=bt(c))==null?void 0:Ne.calendarWrap},[(At(),Wt(Hn,{key:0},[Un("div",Xfe,[le.weekNumbers?(At(),Wt("div",Kfe,Ba(le.weekNumName),1)):hn("",!0),(At(!0),Wt(Hn,null,$o(N.value,(Se,xt)=>(At(),Wt("div",{class:"dp__calendar_header_item",role:"gridcell",key:xt},[le.$slots["calendar-header"]?En(le.$slots,"calendar-header",{key:0,day:Se,index:xt}):hn("",!0),le.$slots["calendar-header"]?hn("",!0):(At(),Wt(Hn,{key:1},[mu(Ba(Se),1)],64))]))),128))]),Qfe,sn(bs,{name:A.value,css:!!le.transitions},{default:wr(()=>{var Se;return[C.value?(At(),Wt("div",{key:0,class:"dp__calendar",role:"grid","aria-label":((Se=bt(c))==null?void 0:Se.calendarDays)||void 0},[(At(!0),Wt(Hn,null,$o(R.value,(xt,kt)=>(At(),Wt("div",{class:"dp__calendar_row",role:"row",key:kt},[le.weekNumbers?(At(),Wt("div",epe,[Un("div",tpe,Ba(ne(xt.days)),1)])):hn("",!0),(At(!0),Wt(Hn,null,$o(xt.days,(wt,Ue)=>{var je,st,tt;return At(),Wt("div",{role:"gridcell",class:"dp__calendar_item",ref_for:!0,ref:Me=>Te(Me,kt,Ue),key:Ue+kt,"aria-selected":wt.classData.dp__active_date||wt.classData.dp__range_start||wt.classData.dp__range_start,"aria-disabled":wt.classData.dp__cell_disabled||void 0,"aria-label":(st=(je=bt(c))==null?void 0:je.day)==null?void 0:st.call(je,wt),tabindex:"0",onClick:Di(Me=>le.$emit("select-date",wt),["stop","prevent"]),onKeydown:[br(Me=>le.$emit("select-date",wt),["enter"]),br(Me=>le.$emit("handle-space",wt),["space"])],onMouseenter:Me=>me(wt,kt,Ue),onMouseleave:Me=>ge(wt)},[Un("div",{class:qr(["dp__cell_inner",wt.classData])},[le.$slots.day&&Y.value(wt)?En(le.$slots,"day",{key:0,day:+wt.text,date:wt.value}):hn("",!0),le.$slots.day?hn("",!0):(At(),Wt(Hn,{key:1},[mu(Ba(wt.text),1)],64)),wt.marker&&Y.value(wt)?(At(),Wt(Hn,{key:2},[le.$slots.marker?En(le.$slots,"marker",{key:0,marker:wt.marker,day:+wt.text,date:wt.value}):(At(),Wt("div",{key:1,class:qr(Q.value(wt.marker)),style:Sa(wt.marker.color?{backgroundColor:wt.marker.color}:{})},null,6))],64)):hn("",!0),Z.value(wt.value)?(At(),Wt("div",{key:3,class:"dp__marker_tooltip",ref_for:!0,ref_key:"activeTooltip",ref:D,style:Sa(g.value)},[(tt=wt.marker)!=null&&tt.tooltip?(At(),Wt("div",{key:0,class:"dp__tooltip_content",onClick:se[0]||(se[0]=Di(()=>{},["stop"]))},[(At(!0),Wt(Hn,null,$o(wt.marker.tooltip,(Me,lt)=>(At(),Wt("div",{key:lt,class:"dp__tooltip_text"},[le.$slots["marker-tooltip"]?En(le.$slots,"marker-tooltip",{key:0,tooltip:Me,day:wt.value}):hn("",!0),le.$slots["marker-tooltip"]?hn("",!0):(At(),Wt(Hn,{key:1},[Un("div",{class:"dp__tooltip_mark",style:Sa(Me.color?{backgroundColor:Me.color}:{})},null,4),Un("div",null,Ba(Me.text),1)],64))]))),128)),Un("div",{class:"dp__arrow_bottom_tp",style:Sa(B.value)},null,4)])):hn("",!0)],4)):hn("",!0)],2)],40,npe)}),128))]))),128))],8,Jfe)):hn("",!0)]}),_:3},8,["name","css"])],64))],10,Zfe)],2)}}}),wR=e=>Array.isArray(e),ipe=(e,t,n,r)=>
1435{const i=jt([]),{modelValue:s,calendars:c,time:a}=M1(e,t),{defaultedMultiCalendars:m,defaultedStartTime:g}=Na(e),{validateMonthYearInRange:x,isDisabled:T,isDateRangeAllowed:C,checkMinMaxRange:A}=Bv(e),{updateTimeValues:P,getSetDateTime:D,setTime:B,assignStartTime:R,disabledTimesConfig:N}=k$(e,a,s,r),j=yt(()=>$e=>c.value[$e]?c.value[$e].month:0),U=yt(()=>$e=>c.value[$e]?c.value[$e].year:0),W=($e,pt,gn)=>{var Pn,gr;c.value[$e]||(c.value[$e]={month:0,year:0}),c.value[$e].month=gR(pt)?(Pn=c.value[$e])==null?void 0:Pn.month:pt,c.value[$e].year=gR(gn)?(gr=c.value[$e])==null?void 0:gr.year:gn},Q=()=>{e.autoApply&&t("select-date")};Nn(s,($e,pt)=>{JSON.stringify($e)!==JSON.stringify(pt)&&Y()}),Dr(()=>{e.shadow||(s.value||(le(),g.value&&R(g.value)),Y(!0),e.focusStartDate&&e.startDate&&le())});const Z=yt(()=>{var $e;return($e=e.flow)!=null&&$e.length&&!e.partialFlow?e.flowStep===e.flow.length:!0}),K=()=>{e.autoApply&&Z.value&&t("auto-apply",e.partialFlow)},Y=($e=!1)=>{if(s.value)return Array.isArray(s.value)?(i.value=s.value,xe($e)):ge(s.value,$e);if(m.value.count&&$e&&!e.startDate)return me(an(),$e)},me=($e,pt=!1)=>{if((!m.value.count||!m.value.static||pt)&&W(0,mi($e),ai($e)),m.value.count)for(let gn=1;gn<m.value.count;gn++){const Pn=ho(an(),{month:j.value(gn-1),year:U.value(gn-1)}),gr=G4(Pn,{months:1});c.value[gn]={month:mi(gr),year:ai(gr)}}},ge=($e,pt)=>{me($e),B("hours",fu($e)),B("minutes",pu($e)),B("seconds",gg($e)),m.value.count&&pt&&ne()},ce=$e=>{if(m.value.count){if(m.value.solo)return 0;const pt=mi($e[0]),gn=mi($e[1]);return Math.abs(gn-pt)<m.value.count?0:1}return 1},fe=($e,pt)=>{$e[1]&&e.showLastInRange?me($e[ce($e)],pt):me($e[0],pt);const gn=(Pn,gr)=>[Pn($e[0]),$e[1]?Pn($e[1]):a[gr][1]];B("hours",gn(fu,"hours")),B("minutes",gn(pu,"minutes")),B("seconds",gn(gg,"seconds"))},ie=($e,pt)=>{if((e.range||e.weekPicker)&&!e.multiDates)return fe($e,pt);if(e.multiDates&&pt){const gn=$e[$e.length-1];return ge(gn,pt)}},xe=$e=>{const pt=s.value;ie(pt,$e),m.value.count&&m.value.solo&&ne()},Te=($e,pt)=>{const gn=ho(an(),{month:j.value(pt),year:U.value(pt)}),Pn=$e<0?du(gn,1):yg(gn,1);x(mi(Pn),ai(Pn),$e<0,e.preventMinMaxNavigation)&&(W(pt,mi(Pn),ai(Pn)),m.value.count&&!m.value.solo&&oe(pt),n())},oe=$e=>{for(let pt=$e-1;pt>=0;pt--){const gn=yg(ho(an(),{month:j.value(pt+1),year:U.value(pt+1)}),1);W(pt,mi(gn),ai(gn))}for(let pt=$e+1;pt<=m.value.count-1;pt++){const gn=du(ho(an(),{month:j.value(pt-1),year:U.value(pt-1)}),1);W(pt,mi(gn),ai(gn))}},ne=()=>{if(Array.isArray(s.value)&&s.value.length===2){const $e=an(an(s.value[1]?s.value[1]:du(s.value[0],1))),[pt,gn]=[mi(s.value[0]),ai(s.value[0])],[Pn,gr]=[mi(s.value[1]),ai(s.value[1])];(pt!==Pn||pt===Pn&&gn!==gr)&&m.value.solo&&W(1,mi($e),ai($e))}else s.value&&!Array.isArray(s.value)&&(W(0,mi(s.value),ai(s.value)),me(an()))},le=()=>{e.startDate&&(W(0,mi(an(e.startDate)),ai(an(e.startDate))),m.value.count&&oe(0))},se=($e,pt)=>{e.monthChangeOnScroll&&Te(e.monthChangeOnScroll!=="inverse"?-$e.deltaY:$e.deltaY,pt)},Ne=($e,pt,gn=!1)=>{e.monthChangeOnArrows&&e.vertical===gn&&Se($e,pt)},Se=($e,pt)=>{Te($e==="right"?-1:1,pt)},xt=$e=>e.markers.find(pt=>ki(_R($e.value),_R(pt.date))),kt=($e,pt)=>{switch(e.sixWeeks===!0?"append":e.sixWeeks){case"prepend":return[!0,!1];case"center":return[$e==0,!0];case"fair":return[$e==0||pt>$e,!0];case"append":return[!1,!1];default:return[!1,!1]}},wt=($e,pt,gn,Pn)=>{if(e.sixWeeks&&$e.length<6){const gr=6-$e.length,Ji=(pt.getDay()+7-Pn)%7,Ni=6-(gn.getDay()+7-Pn)%7,[Bo,_i]=kt(Ji,Ni);for(let Wr=1;Wr<=gr;Wr++)if(_i?!!(Wr%2)==Bo:Bo){const Ao=$e[0].days[0],xs=Ue(Xu(Ao.value,-7),mi(pt));$e.unshift({days:xs})}else{const Ao=$e[$e.length-1],xs=Ao.days[Ao.days.length-1],Fe=Ue(Xu(xs.value,1),mi(pt));$e.push({days:Fe})}}return $e},Ue=($e,pt)=>{const gn=an(JSON.parse(JSON.stringify($e))),Pn=[];for(let gr=0;gr<7;gr++){const Ji=Xu(gn,gr),Ni=mi(Ji)!==pt;Pn.push({text:e.hideOffsetDates&&Ni?"":Ji.getDate(),value:Ji,current:!Ni,classData:{}})}return Pn},je=($e,pt)=>{const gn=[],Pn=an(uu(new Date(pt,$e),e.timezone)),gr=an(uu(new Date(pt,$e+1,0),e.timezone)),Ji=e.weekStart,Ni=yp(Pn,{weekStartsOn:Ji}),Bo=_i=>{const Wr=Ue(_i,$e);if(gn.push({days:Wr}),!gn[gn.length-1].days.some(Ao=>ki(Xl(Ao.value),Xl(gr)))){const Ao=Xu(_i,7);Bo(Ao)}};return Bo(Ni),wt(gn,Pn,gr,Ji)},st=$e=>(s.value=Rb(an($e.value),e.timezone,e.weekStart),K()),tt=$e=>{const pt=xd(an($e.value),a.hours,a.minutes,Vt());e.multiDates?tA(pt,s,e.multiDatesLimit):s.value=pt,r(),Qi().then(()=>{K()})},Me=$e=>e.noDisabledRange?b$(i.value[0],$e).some(pt=>T(pt)):!1,lt=()=>{i.value=s.value?s.value.slice():[],i.value.length===2&&!(e.fixedStart||e.fixedEnd)&&(i.value=[])},Ae=($e,pt)=>{const gn=[an($e.value),Xu(an($e.value),+e.autoRange)];C(gn)&&(pt&&we($e.value),i.value=gn)},we=$e=>{const pt=mi(an($e)),gn=ai(an($e));if(W(0,pt,gn),m.value.count>0)for(let Pn=1;Pn<m.value.count;Pn++){const gr=qde(ho(an($e),{year:j.value(Pn-1),month:U.value(Pn-1)}));W(Pn,gr.month,gr.year)}},Je=$e=>Array.isArray(s.value)&&s.value.length===2?e.fixedStart&&(es($e,s.value[0])||ki($e,s.value[0]))?[s.value[0],$e]:e.fixedEnd&&(za($e,s.value[1])||ki($e,s.value[1]))?[$e,s.value[1]]:(t("invalid-fixed-range",$e),s.value):[],ct=$e=>{Me($e.value)||!A($e.value,s.value,e.fixedStart?0:1)||(i.value=Je(an($e.value)))},mt=($e,pt)=>{if(lt(),e.autoRange)return Ae($e,pt);if(e.fixedStart||e.fixedEnd)return ct($e);i.value[0]?A(an($e.value),s.value)&&!Me($e.value)&&(za(an($e.value),an(i.value[0]))?(i.value.unshift(an($e.value)),t("range-end",
1435i.value[0])):(i.value[1]=an($e.value),t("range-end",i.value[1]))):(i.value[0]=an($e.value),t("range-start",i.value[0]))},Vt=($e=!0)=>e.enableSeconds?Array.isArray(a.seconds)?$e?a.seconds[0]:a.seconds[1]:a.seconds:0,Ie=$e=>{i.value[$e]=xd(i.value[$e],a.hours[$e],a.minutes[$e],Vt($e!==1))},Pe=()=>{var $e,pt;i.value[0]&&i.value[1]&&+(($e=i.value)==null?void 0:$e[0])>+((pt=i.value)==null?void 0:pt[1])&&(i.value.reverse(),t("range-start",i.value[0]),t("range-end",i.value[1]))},rt=()=>{i.value.length&&(i.value[0]&&!i.value[1]?Ie(0):(Ie(0),Ie(1),r()),Pe(),s.value=i.value.slice(),nA(i.value,t,e.autoApply,e.modelAuto))},Tt=($e,pt=!1)=>{if(!(T($e.value)||!$e.current&&e.hideOffsetDates)){if(e.weekPicker)return st($e);if(!e.range)return tt($e);wR(a.hours)&&wR(a.minutes)&&!e.multiDates&&(mt($e,pt),rt())}},pn=($e,pt)=>{W($e,pt.month,pt.year),m.value.count&&!m.value.solo&&oe($e),t("update-month-year",{instance:$e,month:pt.month,year:pt.year}),n(m.value.solo?$e:void 0),r()},qt=($e,pt)=>{Array.isArray($e)&&$e.length<=2&&e.range?s.value=$e.map(gn=>uu(an(gn),pt?void 0:e.timezone)):Array.isArray($e)||(s.value=uu(an($e),pt?void 0:e.timezone)),Q(),e.multiCalendars&&Qi().then(()=>Y(!0))},nt=()=>{e.range?s.value&&Array.isArray(s.value)&&s.value[0]?s.value=za(an(),s.value[0])?[an(),s.value[0]]:[s.value[0],an()]:s.value=[an()]:s.value=an(),Q()},It=()=>{if(Array.isArray(s.value))if(e.multiDates){const $e=$t();s.value[s.value.length-1]=D($e)}else s.value=s.value.map(($e,pt)=>$e&&D($e,pt));else s.value=D(s.value);t("time-update")},$t=()=>Array.isArray(s.value)&&s.value.length?s.value[s.value.length-1]:null;return{calendars:c,modelValue:s,month:j,year:U,time:a,disabledTimesConfig:N,getCalendarDays:je,getMarker:xt,handleScroll:se,handleSwipe:Se,handleArrow:Ne,selectDate:Tt,updateMonthYear:pn,presetDate:qt,selectCurrentDate:nt,updateTime:($e,pt=!0,gn=!1)=>{P($e,pt,gn,It)}}},ope={key:0},ape=sr({__name:"DatePicker",props:{...uh},emits:["tooltip-open","tooltip-close","mount","update:internal-model-value","update-flow-step","reset-flow","auto-apply","focus-menu","select-date","range-start","range-end","invalid-fixed-range","time-update","am-pm-change","time-picker-open","time-picker-close","recalculate-position","update-month-year"],setup(e,{expose:t,emit:n}){const r=e,{calendars:i,month:s,year:c,modelValue:a,time:m,disabledTimesConfig:g,getCalendarDays:x,getMarker:T,handleArrow:C,handleScroll:A,handleSwipe:P,selectDate:D,updateMonthYear:B,presetDate:R,selectCurrentDate:N,updateTime:j}=ipe(r,n,oe,ne),U=Sv(),{setHoverDate:W,getDayClassData:Q,clearHoverDate:Z}=cfe(a,r),{defaultedMultiCalendars:K}=Na(r),Y=jt([]),me=jt([]),ge=jt(null),ce=kc(U,"calendar"),fe=kc(U,"monthYear"),ie=kc(U,"timePicker"),xe=se=>{r.shadow||n("mount",se)};Nn(i,()=>{r.shadow||setTimeout(()=>{n("recalculate-position")},0)},{deep:!0});const Te=yt(()=>se=>x(s.value(se),c.value(se)).map(Ne=>({...Ne,days:Ne.days.map(Se=>(Se.marker=T(Se),Se.classData=Q(Se),Se))})));function oe(se){var Ne;se||se===0?(Ne=me.value[se])==null||Ne.triggerTransition(s.value(se),c.value(se)):me.value.forEach((Se,xt)=>Se.triggerTransition(s.value(xt),c.value(xt)))}function ne(){n("update-flow-step")}const le=(se,Ne=!1)=>{D(se,Ne),r.spaceConfirm&&n("select-date")};return t({clearHoverDate:Z,presetDate:R,selectCurrentDate:N,toggleMonthPicker:(se,Ne,Se=0)=>{var xt;(xt=Y.value[Se])==null||xt.toggleMonthPicker(se,Ne)},toggleYearPicker:(se,Ne,Se=0)=>{var xt;(xt=Y.value[Se])==null||xt.toggleYearPicker(se,Ne)},toggleTimePicker:(se,Ne,Se)=>{var xt;(xt=ge.value)==null||xt.toggleTimePicker(se,Ne,Se)},handleArrow:C,updateMonthYear:B,getSidebarProps:()=>({modelValue:a,month:s,year:c,time:m,updateTime:j,updateMonthYear:B,selectDate:D,presetDate:R})}),(se,Ne)=>(At(),Wt(Hn,null,[sn(eA,{"multi-calendars":bt(K).count},{default:wr(({instance:Se,index:xt})=>[se.disableMonthYearSelect?hn("",!0):(At(),Tr(Yfe,Li({key:0,ref:kt=>{kt&&(Y.value[xt]=kt)},months:bt(g$)(se.formatLocale,se.locale,se.monthNameFormat),years:bt(Q2)(se.yearRange,se.reverseYears),month:bt(s)(Se),year:bt(c)(Se),instance:Se},se.$props,{onMount:Ne[0]||(Ne[0]=kt=>xe(bt(dp).header)),onResetFlow:Ne[1]||(Ne[1]=kt=>se.$emit("reset-flow")),onUpdateMonthYear:kt=>bt(B)(Se,kt),onOverlayClosed:Ne[2]||(Ne[2]=kt=>se.$emit("focus-menu"))}),pl({_:2},[$o(bt(fe),(kt,wt)=>({name:kt,fn:wr(Ue=>[En(se.$slots,kt,ys(dl(Ue)))])}))]),1040,["months","years","month","year","instance","onUpdateMonthYear"])),sn(rpe,Li({ref:kt=>{kt&&(me.value[xt]=kt)},"mapped-dates":Te.value(Se),month:bt(s)(Se),year:bt(c)(Se)},se.$props,{onSelectDate:kt=>bt(D)(kt,Se!==1),onHandleSpace:kt=>le(kt,Se!==1),onSetHoverDate:Ne[3]||(Ne[3]=kt=>bt(W)(kt)),onHandleScroll:kt=>bt(A)(kt,Se),onHandleSwipe:kt=>bt(P)(kt,Se),onMount:Ne[4]||(Ne[4]=kt=>
1435xe(bt(dp).calendar)),onResetFlow:Ne[5]||(Ne[5]=kt=>se.$emit("reset-flow")),onTooltipOpen:Ne[6]||(Ne[6]=kt=>se.$emit("tooltip-open",kt)),onTooltipClose:Ne[7]||(Ne[7]=kt=>se.$emit("tooltip-close",kt))}),pl({_:2},[$o(bt(ce),(kt,wt)=>({name:kt,fn:wr(Ue=>[En(se.$slots,kt,ys(dl({...Ue})))])}))]),1040,["mapped-dates","month","year","onSelectDate","onHandleSpace","onHandleScroll","onHandleSwipe"])]),_:3},8,["multi-calendars"]),se.enableTimePicker?(At(),Wt("div",ope,[se.$slots["time-picker"]?En(se.$slots,"time-picker",ys(Li({key:0},{time:bt(m),updateTime:bt(j)}))):(At(),Tr(C$,Li({key:1,ref_key:"timePickerRef",ref:ge},se.$props,{hours:bt(m).hours,minutes:bt(m).minutes,seconds:bt(m).seconds,"internal-model-value":se.internalModelValue,"disabled-times-config":bt(g),onMount:Ne[8]||(Ne[8]=Se=>xe(bt(dp).timePicker)),"onUpdate:hours":Ne[9]||(Ne[9]=Se=>bt(j)(Se)),"onUpdate:minutes":Ne[10]||(Ne[10]=Se=>bt(j)(Se,!1)),"onUpdate:seconds":Ne[11]||(Ne[11]=Se=>bt(j)(Se,!1,!0)),onResetFlow:Ne[12]||(Ne[12]=Se=>se.$emit("reset-flow")),onOverlayClosed:Ne[13]||(Ne[13]=Se=>se.$emit("time-picker-close")),onOverlayOpened:Ne[14]||(Ne[14]=Se=>se.$emit("time-picker-open",Se)),onAmPmChange:Ne[15]||(Ne[15]=Se=>se.$emit("am-pm-change",Se))}),pl({_:2},[$o(bt(ie),(Se,xt)=>({name:Se,fn:wr(kt=>[En(se.$slots,Se,ys(dl(kt)))])}))]),1040,["hours","minutes","seconds","internal-model-value","disabled-times-config"]))])):hn("",!0)],64))}}),spe=["id","onKeydown"],lpe={key:0,class:"dp__sidebar_left"},cpe={key:1,class:"dp--preset-dates"},upe=["onClick","onKeydown"],hpe={key:2,class:"dp__sidebar_right"},dpe={key:3,class:"dp__action_extra"},TR=sr({compatConfig:{MODE:3},__name:"DatepickerMenu",props:{...O1,shadow:{type:Boolean,default:!1},openOnTop:{type:Boolean,default:!1},internalModelValue:{type:[Date,Array],default:null},arrMapValues:{type:Object,default:()=>({})}},emits:["close-picker","select-date","auto-apply","time-update","flow-step","update-month-year","invalid-select","update:internal-model-value","recalculate-position","invalid-fixed-range","tooltip-open","tooltip-close","time-picker-open","time-picker-close","am-pm-change","range-start","range-end"],setup(e,{expose:t,emit:n}){const r=e,i=yt(()=>{const{openOnTop:Me,...lt}=r;return{...lt,flowStep:Q.value}}),{setMenuFocused:s,setShiftKey:c,control:a}=E$(),m=Sv(),{defaultedTextInput:g,defaultedInline:x}=Na(r),T=jt(null),C=jt(0),A=jt(null),P=jt(null),D=jt(!1),B=jt(null);Dr(()=>{if(!r.shadow){D.value=!0,R(),window.addEventListener("resize",R);const Me=ca(A);if(Me&&!g.value.enabled&&!x.value.enabled&&(s(!0),ge()),Me){const lt=Ae=>{r.allowPreventDefault&&Ae.preventDefault(),Ae.stopImmediatePropagation(),Ae.stopPropagation()};Me.addEventListener("pointerdown",lt),Me.addEventListener("mousedown",lt)}}}),Bi(()=>{window.removeEventListener("resize",R)});const R=()=>{const Me=ca(P);Me&&(C.value=Me.getBoundingClientRect().width)},{arrowRight:N,arrowLeft:j,arrowDown:U,arrowUp:W}=$d(),{flowStep:Q,updateFlowStep:Z,childMount:K,resetFlow:Y}=ufe(r,n,B),me=yt(()=>r.monthPicker?kfe:r.yearPicker?Pfe:r.timePicker?qfe:ape),ge=()=>{const Me=ca(A);Me&&Me.focus({preventScroll:!0})},ce=yt(()=>{var Me;return((Me=B.value)==null?void 0:Me.getSidebarProps())||{}}),fe=()=>{r.openOnTop&&n("recalculate-position")},ie=kc(m,"action"),xe=yt(()=>r.monthPicker||r.yearPicker?kc(m,"monthYear"):r.timePicker?kc(m,"timePicker"):kc(m,"shared")),Te=yt(()=>r.openOnTop?"dp__arrow_bottom":"dp__arrow_top"),oe=yt(()=>({dp__menu_disabled:r.disabled,dp__menu_readonly:r.readonly})),ne=yt(()=>({dp__menu:!0,dp__menu_index:!x.value.enabled,dp__relative:x.value.enabled,[r.menuClassName]:!!r.menuClassName})),le=Me=>{Me.stopPropagation(),Me.stopImmediatePropagation()},se=()=>{r.escClose&&n("close-picker")},Ne=Me=>{if(r.arrowNavigation){if(Me==="up")return W();if(Me==="down")return U();if(Me==="left")return j();if(Me==="right")return N()}else Me==="left"||Me==="up"?Ue("handleArrow","left",0,Me==="up"):Ue("handleArrow","right",0,Me==="down")},Se=Me=>{c(Me.shiftKey),!r.disableMonthYearSelect&&Me.code==="Tab"&&Me.target.classList.contains("dp__menu")&&a.value.shiftKeyInMenu&&(Me.preventDefault(),Me.stopImmediatePropagation(),n("close-picker"))},xt=()=>{ge(),n("time-picker-close")},kt=Me=>{var lt,Ae,we;(lt=B.value)==null||lt.toggleTimePicker(!1,!1),(Ae=B.value)==null||Ae.toggleMonthPicker(!1,!1,Me),(we=B.value)==null||we.toggleYearPicker(!1,!1,Me)},wt=(Me,lt=0)=>{var Ae,we,Je;return Me==="month"?(Ae=B.value)==null?void 0:Ae.toggleMonthPicker(!1,!0,lt):Me==="year"?(we=B.value)==null?void 0:we.toggleYearPicker(!1,!0,lt):Me==="time"?(Je=B.value)==null?void 0:Je.toggleTimePicker(!0,!1):kt(lt)},Ue=(Me,...lt)=>{var Ae,we;(Ae=B.value)!=null&&Ae[Me]&&((we=B.value)==null||we[Me](...lt))},je=()=>{Ue("selectCurrentDate")},st=(Me,lt)=>{Ue("presetDate",Me,lt)},tt=()=>{Ue("clearHoverDate")};return t({updateMonthYear:(Me,lt)=>{Ue("updateMonthYear",Me,lt)},switchView:wt}),(Me,lt)=>{var Ae;return At(),Wt("div",{id:Me.uid?`dp-menu-${Me.uid}`:void 0,tabindex:"0",ref_key:"dpMenuRef",ref:A,role:"dialog",class:qr(ne.value),onMouseleave:tt,onClick:le,onKeydown:[br(se,["esc"]),lt[15]||(lt[15]=br(Di(we=>Ne("left"),["prevent"]),["left"])),lt[16]||(lt[16]=br(Di(we=>Ne("up"),["prevent"]),["up"])),lt[17]||(lt[17]=br(Di(we=>Ne("down"),["prevent"]),["down"])),lt[18]||(lt[18]=br(Di(we=>Ne("right"),["prevent"]),["right"])),Se]},[(Me.disabled||Me.readonly)&&bt(x).enabled?(At(),Wt("div",{key:0,class:qr(oe.value)},null,2)):hn("",!0),!bt(x).enabled&&!Me.teleportCenter?(At(),Wt("div",{key:1,class:qr(Te.value)},null,2)):hn("",!0),Un("div",{ref_key:"innerMenuRef",ref:P,class:qr({dp__menu_content_wrapper:((Ae=Me.presetDates)==null?void 0:Ae.length)||!!Me.$slots["left-sidebar"]||!!Me.$slots["right-sidebar"]}),style:Sa({"--dp-menu-width":`${C.value}px`})},[Me.$slots["left-sidebar"]?(At(),Wt("div",lpe,[En(Me.$slots,"left-sidebar",
1435ys(dl(ce.value)))])):hn("",!0),Me.presetDates.length?(At(),Wt("div",cpe,[(At(!0),Wt(Hn,null,$o(Me.presetDates,(we,Je)=>(At(),Wt("div",{key:Je,style:Sa(we.style||{}),class:"dp--preset-range"},[we.slot?En(Me.$slots,we.slot,{key:0,presetDate:st,label:we.label,value:we.value}):(At(),Wt("div",{key:1,role:"button",tabindex:"0",onClick:ct=>st(we.value,we.noTz),onKeydown:[br(Di(ct=>st(we.value,we.noTz),["prevent"]),["enter"]),br(Di(ct=>st(we.value,we.noTz),["prevent"]),["space"])]},Ba(we.label),41,upe))],4))),128))])):hn("",!0),Un("div",{class:"dp__instance_calendar",ref_key:"calendarWrapperRef",ref:T,role:"document"},[(At(),Tr(Ev(me.value),Li({ref_key:"dynCmpRef",ref:B},i.value,{"flow-step":bt(Q),onMount:bt(K),onUpdateFlowStep:bt(Z),onResetFlow:bt(Y),onFocusMenu:ge,onSelectDate:lt[0]||(lt[0]=we=>Me.$emit("select-date")),onTooltipOpen:lt[1]||(lt[1]=we=>Me.$emit("tooltip-open",we)),onTooltipClose:lt[2]||(lt[2]=we=>Me.$emit("tooltip-close",we)),onAutoApply:lt[3]||(lt[3]=we=>Me.$emit("auto-apply",we)),onRangeStart:lt[4]||(lt[4]=we=>Me.$emit("range-start",we)),onRangeEnd:lt[5]||(lt[5]=we=>Me.$emit("range-end",we)),onInvalidFixedRange:lt[6]||(lt[6]=we=>Me.$emit("invalid-fixed-range",we)),onTimeUpdate:lt[7]||(lt[7]=we=>Me.$emit("time-update")),onAmPmChange:lt[8]||(lt[8]=we=>Me.$emit("am-pm-change",we)),onTimePickerOpen:lt[9]||(lt[9]=we=>Me.$emit("time-picker-open",we)),onTimePickerClose:xt,onRecalculatePosition:fe,onUpdateMonthYear:lt[10]||(lt[10]=we=>Me.$emit("update-month-year",we)),"onUpdate:internalModelValue":lt[11]||(lt[11]=we=>Me.$emit("update:internal-model-value",we))}),pl({_:2},[$o(xe.value,(we,Je)=>({name:we,fn:wr(ct=>[En(Me.$slots,we,ys(dl({...ct})))])}))]),1040,["flow-step","onMount","onUpdateFlowStep","onResetFlow"]))],512),Me.$slots["right-sidebar"]?(At(),Wt("div",hpe,[En(Me.$slots,"right-sidebar",ys(dl(ce.value)))])):hn("",!0),Me.$slots["action-extra"]?(At(),Wt("div",dpe,[Me.$slots["action-extra"]?En(Me.$slots,"action-extra",{key:0,selectCurrentDate:je}):hn("",!0)])):hn("",!0)],6),!Me.autoApply||Me.keepActionRow?(At(),Tr(_fe,Li({key:2,"menu-mount":D.value},i.value,{"calendar-width":C.value,onClosePicker:lt[12]||(lt[12]=we=>Me.$emit("close-picker")),onSelectDate:lt[13]||(lt[13]=we=>Me.$emit("select-date")),onInvalidSelect:lt[14]||(lt[14]=we=>Me.$emit("invalid-select")),onSelectNow:je}),pl({_:2},[$o(bt(ie),(we,Je)=>({name:we,fn:wr(ct=>[En(Me.$slots,we,ys(dl({...ct})))])}))]),1040,["menu-mount","calendar-width"])):hn("",!0)],42,spe)}}}),fpe=typeof window<"u"?window:void 0,wE=()=>{},ppe=e=>QC()?($s(e),!0):!1,mpe=(e,t,n,r)=>{if(!e)return wE;let i=wE;const s=Nn(()=>bt(e),a=>{i(),a&&(a.addEventListener(t,n,r),i=()=>{a.removeEventListener(t,n,r),i=wE})},{immediate:!0,flush:"post"}),c=()=>{s(),i()};return ppe(c),c},gpe=(e,t,n,r={})=>{const{window:i=fpe,event:s="pointerdown"}=r;return i?mpe(i,s,c=>{const a=ca(e),m=ca(t);!a||!m||a===c.target||c.composedPath().includes(a)||c.composedPath().includes(m)||n(c)},{passive:!0}):void 0},ype=sr({compatConfig:{MODE:3},__name:"VueDatePicker",props:{...O1},emits:["update:model-value","update:model-timezone-value","text-submit","closed","cleared","open","focus","blur","internal-model-change","recalculate-position","flow-step","update-month-year","invalid-select","invalid-fixed-range","tooltip-open","tooltip-close","time-picker-open","time-picker-close","am-pm-change","range-start","range-end"],setup(e,{expose:t,emit:n}){const r=e,i=Sv(),s=jt(!1),c=Us(r,"modelValue"),a=Us(r,"timezone"),m=jt(null),g=jt(null),x=jt(null),T=jt(!1),C=jt(null),{setMenuFocused:A,setShiftKey:P}=E$(),{clearArrowNav:D}=$d(),{mapDatesArrToMap:B,validateDate:R,isValidTime:N}=Bv(r),{defaultedTransitions:j,defaultedTextInput:U,defaultedInline:W}=Na(r),{menuTransition:Q,showTransition:Z}=Fv(j);Dr(()=>{le(r.modelValue),Qi().then(()=>{W.value.enabled||(xe(C.value).addEventListener("scroll",Ue),window.addEventListener("resize",je))}),W.value.enabled&&(s.value=!0)});const K=yt(()=>B());Bi(()=>{if(!W.value.enabled){const $t=xe(C.value);$t&&$t.removeEventListener("scroll",Ue),window.removeEventListener("resize",je)}});const Y=kc(i,"all",r.presetDates),me=kc(i,"input");Nn([c,a],()=>{le(c.value)},{deep:!0});const{openOnTop:ge,menuStyle:ce,xCorrect:fe,setMenuPosition:ie,getScrollableParent:xe,shadowRender:Te}=afe(m,g,x,C,W,n,r),{inputValue:oe,internalModelValue:ne,parseExternalModelValue:le,emitModelValue:se,formatInputValue:Ne,checkBeforeEmit:Se}=ife(n,r,T),xt=yt(()=>({dp__main:!0,dp__theme_dark:r.dark,dp__theme_light:!r.dark,dp__flex_display:W.value.enabled,dp__flex_display_with_input:W.value.input})),kt=yt(()=>
1435r.dark?"dp__theme_dark":"dp__theme_light"),wt=yt(()=>r.teleport?{to:typeof r.teleport=="boolean"?"body":r.teleport,disabled:W.value.enabled}:{class:"dp__outer_menu_wrap"}),Ue=()=>{s.value&&(r.closeOnScroll?mt():ie())},je=()=>{s.value&&ie()},st=()=>{!r.disabled&&!r.readonly&&(Te(TR,r),ie(!1),s.value=!0,s.value&&n("open"),s.value||ct(),le(r.modelValue))},tt=()=>{oe.value="",ct(),n("update:model-value",null),n("update:model-timezone-value",null),n("cleared"),r.closeOnClearValue&&mt()},Me=()=>{const $t=ne.value;return!$t||!Array.isArray($t)&&R($t)?!0:Array.isArray($t)?$t.length===2&&R($t[0])&&R($t[1])?!0:r.partialRange&&!r.timePicker?R($t[0]):!1:!1},lt=()=>{Se()&&Me()?(se(),mt()):n("invalid-select",ne.value)},Ae=$t=>{we(),se(),r.closeOnAutoApply&&!$t&&mt()},we=()=>{x.value&&U.value.enabled&&x.value.setParsedDate(ne.value)},Je=($t=!1)=>{r.autoApply&&N(ne.value)&&Me()&&(r.range&&Array.isArray(ne.value)?(r.partialRange||ne.value.length===2)&&Ae($t):Ae($t))},ct=()=>{U.value.enabled||(ne.value=null)},mt=()=>{W.value.enabled||(s.value&&(s.value=!1,fe.value=!1,A(!1),P(!1),D(),n("closed"),oe.value&&le(c.value)),ct(),n("blur"))},Vt=($t,$e)=>{if(!$t){ne.value=null;return}ne.value=$t,$e&&(lt(),n("text-submit"))},Ie=()=>{r.autoApply&&N(ne.value)&&se(),we()},Pe=()=>s.value?mt():st(),rt=$t=>{ne.value=$t},Tt=()=>{U.value.enabled&&(T.value=!0,Ne()),n("focus")},pn=()=>{U.value.enabled&&(T.value=!1,le(r.modelValue)),n("blur")},qt=$t=>{g.value&&g.value.updateMonthYear(0,{month:mR($t.month),year:mR($t.year)})},nt=$t=>{le($t??r.modelValue)},It=($t,$e)=>{var pt;(pt=g.value)==null||pt.switchView($t,$e)};return gpe(m,x,r.onClickOutside?()=>r.onClickOutside(Me):mt),t({closeMenu:mt,selectDate:lt,clearValue:tt,openMenu:st,onScroll:Ue,formatInputValue:Ne,updateInternalModelValue:rt,setMonthYear:qt,parseModel:nt,switchView:It}),($t,$e)=>(At(),Wt("div",{class:qr(xt.value),ref_key:"pickerWrapperRef",ref:C},[sn(pfe,Li({ref_key:"inputRef",ref:x,"is-menu-open":s.value,"input-value":bt(oe),"onUpdate:inputValue":$e[0]||($e[0]=pt=>Ai(oe)?oe.value=pt:null)},$t.$props,{onClear:tt,onOpen:st,onSetInputDate:Vt,onSetEmptyDate:bt(se),onSelectDate:lt,onToggle:Pe,onClose:mt,onFocus:Tt,onBlur:pn,onRealBlur:$e[1]||($e[1]=pt=>T.value=!1)}),pl({_:2},[$o(bt(me),(pt,gn)=>({name:pt,fn:wr(Pn=>[En($t.$slots,pt,ys(dl(Pn)))])}))]),1040,["is-menu-open","input-value","onSetEmptyDate"]),sn(bs,{name:bt(Q)(bt(ge)),css:bt(Z)&&!bt(W).enabled},{default:wr(()=>[s.value?(At(),Tr(Ev($t.teleport?x3:"div"),Li({key:0,ref_key:"dpWrapMenuRef",ref:m},wt.value,{class:{"dp--menu-wrapper":!bt(W).enabled},style:bt(W).enabled?void 0:bt(ce)}),{default:wr(()=>[sn(TR,Li({ref_key:"dpMenuRef",ref:g,class:{[kt.value]:!0,"dp--menu-wrapper":$t.teleport},style:$t.teleport?bt(ce):void 0,"open-on-top":bt(ge),"arr-map-values":K.value},$t.$props,{"internal-model-value":bt(ne),"onUpdate:internalModelValue":$e[2]||($e[2]=pt=>Ai(ne)?ne.value=pt:null),onClosePicker:mt,onSelectDate:lt,onAutoApply:Je,onTimeUpdate:Ie,onFlowStep:$e[3]||($e[3]=pt=>$t.$emit("flow-step",pt)),onUpdateMonthYear:$e[4]||($e[4]=pt=>$t.$emit("update-month-year",pt)),onInvalidSelect:$e[5]||($e[5]=pt=>$t.$emit("invalid-select",bt(ne))),onInvalidFixedRange:$e[6]||($e[6]=pt=>$t.$emit("invalid-fixed-range",pt)),onRecalculatePosition:bt(ie),onTooltipOpen:$e[7]||($e[7]=pt=>$t.$emit("tooltip-open",pt)),onTooltipClose:$e[8]||($e[8]=pt=>$t.$emit("tooltip-close",pt)),onTimePickerOpen:$e[9]||($e[9]=pt=>$t.$emit("time-picker-open",pt)),onTimePickerClose:$e[10]||($e[10]=pt=>$t.$emit("time-picker-close",pt)),onAmPmChange:$e[11]||($e[11]=pt=>$t.$emit("am-pm-change",pt)),onRangeStart:$e[12]||($e[12]=pt=>$t.$emit("range-start",pt)),onRangeEnd:$e[13]||($e[13]=pt=>$t.$emit("range-end",pt))}),pl({_:2},[$o(bt(Y),(pt,gn)=>({name:pt,fn:wr(Pn=>[En($t.$slots,pt,ys(dl({...Pn})))])}))]),1040,["class","style","open-on-top","arr-map-values","internal-model-value","onRecalculatePosition"])]),_:3},16,["class","style"])):hn("",!0)]),_:3},8,["name","css"])],2))}}),rA=(()=>{const e=ype;return e.install=t=>{t.component("Vue3DatePicker",e)},e})(),_pe=Object.freeze(Object.defineProperty({__proto__:null,default:rA},Symbol.toStringTag,{value:"Module"}));Object.entries(_pe).forEach(([e,t])=>{e!=="default"&&(rA[e]=t)});const vpe=Gi(e=>
1435{e.vueApp.component("VueDatePicker",rA)}),bpe={VAppBar:{elevation:0},VBtn:{variant:"flat"},VTextField:{color:"primary",density:"comfortable"}},Rs={black:"#000",white:"#fff",slate:{50:"#f8fafc",100:"#f1f5f9",200:"#e2e8f0",300:"#cbd5e1",400:"#94a3b8",500:"#64748b",600:"#475569",700:"#334155",800:"#1e293b",900:"#0f172a",950:"#020617"},gray:{50:"#f9fafb",100:"#f3f4f6",200:"#e5e7eb",300:"#d1d5db",400:"#9ca3af",500:"#6b7280",600:"#4b5563",700:"#374151",800:"#1f2937",900:"#111827",950:"#030712"},zinc:{50:"#fafafa",100:"#f4f4f5",200:"#e4e4e7",300:"#d4d4d8",400:"#a1a1aa",500:"#71717a",600:"#52525b",700:"#3f3f46",800:"#27272a",900:"#18181b",950:"#09090b"},neutral:{50:"#fafafa",100:"#f5f5f5",200:"#e5e5e5",300:"#d4d4d4",400:"#a3a3a3",500:"#737373",600:"#525252",700:"#404040",800:"#262626",900:"#171717",950:"#0a0a0a"},stone:{50:"#fafaf9",100:"#f5f5f4",200:"#e7e5e4",300:"#d6d3d1",400:"#a8a29e",500:"#78716c",600:"#57534e",700:"#44403c",800:"#292524",900:"#1c1917",950:"#0c0a09"},red:{50:"#fef2f2",100:"#fee2e2",200:"#fecaca",300:"#fca5a5",400:"#f87171",500:"#ef4444",600:"#dc2626",700:"#b91c1c",800:"#991b1b",900:"#7f1d1d",950:"#450a0a"},orange:{50:"#fff7ed",100:"#ffedd5",200:"#fed7aa",300:"#fdba74",400:"#fb923c",500:"#f97316",600:"#ea580c",700:"#c2410c",800:"#9a3412",900:"#7c2d12",950:"#431407"},amber:{50:"#fffbeb",100:"#fef3c7",200:"#fde68a",300:"#fcd34d",400:"#fbbf24",500:"#f59e0b",600:"#d97706",700:"#b45309",800:"#92400e",900:"#78350f",950:"#451a03"},yellow:{50:"#fefce8",100:"#fef9c3",200:"#fef08a",300:"#fde047",400:"#facc15",500:"#eab308",600:"#ca8a04",700:"#a16207",800:"#854d0e",900:"#713f12",950:"#422006"},lime:{50:"#f7fee7",100:"#ecfccb",200:"#d9f99d",300:"#bef264",400:"#a3e635",500:"#84cc16",600:"#65a30d",700:"#4d7c0f",800:"#3f6212",900:"#365314",950:"#1a2e05"},green:{50:"#f0fdf4",100:"#dcfce7",200:"#bbf7d0",300:"#86efac",400:"#4ade80",500:"#22c55e",600:"#16a34a",700:"#15803d",800:"#166534",900:"#14532d",950:"#052e16"},emerald:{50:"#ecfdf5",100:"#d1fae5",200:"#a7f3d0",300:"#6ee7b7",400:"#34d399",500:"#10b981",600:"#059669",700:"#047857",800:"#065f46",900:"#064e3b",950:"#022c22"},teal:{50:"#f0fdfa",100:"#ccfbf1",200:"#99f6e4",300:"#5eead4",400:"#2dd4bf",500:"#14b8a6",600:"#0d9488",700:"#0f766e",800:"#115e59",900:"#134e4a",950:"#042f2e"},cyan:{50:"#ecfeff",100:"#cffafe",200:"#a5f3fc",300:"#67e8f9",400:"#22d3ee",500:"#06b6d4",600:"#0891b2",700:"#0e7490",800:"#155e75",900:"#164e63",950:"#083344"},sky:{50:"#f0f9ff",100:"#e0f2fe",200:"#bae6fd",300:"#7dd3fc",400:"#38bdf8",500:"#0ea5e9",600:"#0284c7",700:"#0369a1",800:"#075985",900:"#0c4a6e",950:"#082f49"},blue:{50:"#eff6ff",100:"#dbeafe",200:"#bfdbfe",300:"#93c5fd",400:"#60a5fa",500:"#3b82f6",600:"#2563eb",700:"#1d4ed8",800:"#1e40af",900:"#1e3a8a",950:"#172554"},indigo:{50:"#eef2ff",100:"#e0e7ff",200:"#c7d2fe",300:"#a5b4fc",400:"#818cf8",500:"#6366f1",600:"#4f46e5",700:"#4338ca",800:"#3730a3",900:"#312e81",950:"#1e1b4b"},violet:{50:"#f5f3ff",100:"#ede9fe",200:"#ddd6fe",300:"#c4b5fd",400:"#a78bfa",500:"#8b5cf6",600:"#7c3aed",700:"#6d28d9",800:"#5b21b6",900:"#4c1d95",950:"#2e1065"},purple:{50:"#faf5ff",100:"#f3e8ff",200:"#e9d5ff",300:"#d8b4fe",400:"#c084fc",500:"#a855f7",600:"#9333ea",700:"#7e22ce",800:"#6b21a8",900:"#581c87",950:"#3b0764"},fuchsia:{50:"#fdf4ff",100:"#fae8ff",200:"#f5d0fe",300:"#f0abfc",400:"#e879f9",500:"#d946ef",600:"#c026d3",700:"#a21caf",800:"#86198f",900:"#701a75",950:"#4a044e"},pink:{50:"#fdf2f8",100:"#fce7f3",200:"#fbcfe8",300:"#f9a8d4",400:"#f472b6",500:"#ec4899",600:"#db2777",700:"#be185d",800:"#9d174d",900:"#831843",950:"#500724"},rose:{50:"#fff1f2",100:"#ffe4e6",200:"#fecdd3",300:"#fda4af",400:"#fb7185",500:"#f43f5e",600:"#e11d48",700:"#be123c",800:"#9f1239",900:"#881337",950:"#4c0519"}},xpe="light",ER={dark:!1,colors:{background:"#f9fafd",surface:"#FFFFFF",primary:Rs.indigo[600],secondary:Rs.purple[600],error:Rs.red[500],info:Rs.blue[500],success:Rs.emerald[500],warning:Rs.amber[500]}},wpe={dark:!0,colors:{background:Rs.slate[950],surface:Rs.slate[900],primary:Rs.indigo[500],secondary:Rs.purple[500],error:Rs.red[500],info:Rs.blue[500],success:Rs.emerald[500],warning:Rs.amber[500]}},k_=/^[a-z0-9]+(-[a-z0-9]+)*$/,D1=(e,t,n,r="")=>{const i=e.split(":");if(e.slice(0,1)==="@"){if(i.length<2||i.length>3)return null;r=i.shift().slice(1)}if(i.length>3||!i.length)return null;if(i.length>1){const a=i.pop(),m=i.pop(),g={provider:i.length>0?i[0]:r,prefix:m,name:a};return t&&!Fb(g)?null:g}const s=i[0],c=s.split("-");if(c.length>1){const a={provider:r,prefix:c.shift(),name:c.join("-")};return t&&!Fb(a)?null:a}if(n&&r===""){const a={provider:r,prefix:"",name:s};return t&&!Fb(a,n)?null:a}return null},Fb=(e,t)=>
1435e?!!((e.provider===""||e.provider.match(k_))&&(t&&e.prefix===""||e.prefix.match(k_))&&e.name.match(k_)):!1,A$=Object.freeze({left:0,top:0,width:16,height:16}),Ix=Object.freeze({rotate:0,vFlip:!1,hFlip:!1}),L1=Object.freeze({...A$,...Ix}),AC=Object.freeze({...L1,body:"",hidden:!1});function Tpe(e,t){const n={};!e.hFlip!=!t.hFlip&&(n.hFlip=!0),!e.vFlip!=!t.vFlip&&(n.vFlip=!0);const r=((e.rotate||0)+(t.rotate||0))%4;return r&&(n.rotate=r),n}function SR(e,t){const n=Tpe(e,t);for(const r in AC)r in Ix?r in e&&!(r in n)&&(n[r]=Ix[r]):r in t?n[r]=t[r]:r in e&&(n[r]=e[r]);return n}function Epe(e,t){const n=e.icons,r=e.aliases||Object.create(null),i=Object.create(null);function s(c){if(n[c])return i[c]=[];if(!(c in i)){i[c]=null;const a=r[c]&&r[c].parent,m=a&&s(a);m&&(i[c]=[a].concat(m))}return i[c]}return(t||Object.keys(n).concat(Object.keys(r))).forEach(s),i}function Spe(e,t,n){const r=e.icons,i=e.aliases||Object.create(null);let s={};function c(a){s=SR(r[a]||i[a],s)}return c(t),n.forEach(c),SR(e,s)}function P$(e,t){const n=[];if(typeof e!="object"||typeof e.icons!="object")return n;e.not_found instanceof Array&&e.not_found.forEach(i=>{t(i,null),n.push(i)});const r=Epe(e);for(const i in r){const s=r[i];s&&(t(i,Spe(e,i,s)),n.push(i))}return n}const Cpe={provider:"",aliases:{},not_found:{},...A$};function TE(e,t){for(const n in t)if(n in e&&typeof e[n]!=typeof t[n])return!1;return!0}function M$(e){if(typeof e!="object"||e===null)return null;const t=e;if(typeof t.prefix!="string"||!e.icons||typeof e.icons!="object"||!TE(e,Cpe))return null;const n=t.icons;for(const i in n){const s=n[i];if(!i.match(k_)||typeof s.body!="string"||!TE(s,AC))return null}const r=t.aliases||Object.create(null);for(const i in r){const s=r[i],c=s.parent;if(!i.match(k_)||typeof c!="string"||!n[c]&&!r[c]||!TE(s,AC))return null}return t}const CR=Object.create(null);function kpe(e,t){return{provider:e,prefix:t,icons:Object.create(null),missing:new Set}}function vp(e,t){const n=CR[e]||(CR[e]=Object.create(null));return n[t]||(n[t]=kpe(e,t))}function iA(e,t){return M$(t)?P$(t,(n,r)=>{r?e.icons[n]=r:e.missing.add(n)}):[]}function Ape(e,t,n){try{if(typeof n.body=="string")return e.icons[t]={...n},!0}catch{}return!1}let ov=!1;function I$(e){return typeof e=="boolean"&&(ov=e),ov}function Ppe(e){const t=typeof e=="string"?D1(e,!0,ov):e;if(t){const n=vp(t.provider,t.prefix),r=t.name;return n.icons[r]||(n.missing.has(r)?null:void 0)}}function Mpe(e,t){const n=D1(e,!0,ov);if(!n)return!1;const r=vp(n.provider,n.prefix);return Ape(r,n.name,t)}function Ipe(e,t){if(typeof e!="object")return!1;if(typeof t!="string"&&(t=e.provider||""),ov&&!t&&!e.prefix){let i=!1;return M$(e)&&(e.prefix="",P$(e,(s,c)=>{c&&Mpe(s,c)&&(i=!0)})),i}const n=e.prefix;if(!Fb({provider:t,prefix:n,name:"a"}))return!1;const r=vp(t,n);return!!iA(r,e)}const O$=Object.freeze({width:null,height:null}),D$=Object.freeze({...O$,...Ix}),Ope=/(-?[0-9.]*[0-9]+[0-9.]*)/g,Dpe=/^-?[0-9.]*[0-9]+[0-9.]*$/g;function kR(e,t,n){if(t===1)return e;if(n=n||100,typeof e=="number")return Math.ceil(e*t*n)/n;if(typeof e!="string")return e;const r=e.split(Ope);if(r===null||!r.length)return e;const i=[];let s=r.shift(),c=Dpe.test(s);for(;;){if(c){const a=parseFloat(s);isNaN(a)?i.push(s):i.push(Math.ceil(a*t*n)/n)}else i.push(s);if(s=r.shift(),s===void 0)return i.join("");c=!c}}const Lpe=e=>e==="unset"||e==="undefined"||e==="none";function Rpe(e,t){const n={...L1,...e},r={...D$,...t},i={left:n.left,top:n.top,width:n.width,height:n.height};let s=n.body;[n,r].forEach(P=>{const D=[],B=P.hFlip,R=P.vFlip;let N=P.rotate;B?R?N+=2:(D.push("translate("+(i.width+i.left).toString()+" "+(0-i.top).toString()+")"),D.push("scale(-1 1)"),i.top=i.left=0):R&&(D.push("translate("+(0-i.left).toString()+" "+(i.height+i.top).toString()+")"),D.push("scale(1 -1)"),i.top=i.left=0);let j;switch(N<0&&(N-=Math.floor(N/4)*4),N=N%4,N){case 1:j=i.height/2+i.top,D.unshift("rotate(90 "+j.toString()+" "+j.toString()+")");break;case 2:D.unshift("rotate(180 "+(i.width/2+i.left).toString()+" "+(i.height/2+i.top).toString()+")");break;case 3:j=i.width/2+i.left,D.unshift("rotate(-90 "+j.toString()+" "+j.toString()+")");break}N%2===1&&(i.left!==i.top&&(j=i.left,i.left=i.top,i.top=j),i.width!==i.height&&(j=i.width,i.width=i.height,i.height=j)),D.length&&(s='<g transform="'+D.join(" ")+'">'+s+"</g>")});const c=r.width,a=r.height,m=i.width,g=i.height;let x,T;c===null?(T=a===null?"1em":a==="auto"?g:a,x=kR(T,m/g)):(x=c==="auto"?m:c,T=a===null?kR(x,g/m):a==="auto"?g:a);const C={},A=(P,D)=>{Lpe(D)||(C[P]=D.toString())};
1435return A("width",x),A("height",T),C.viewBox=i.left.toString()+" "+i.top.toString()+" "+m.toString()+" "+g.toString(),{attributes:C,body:s}}const Fpe=/\sid="(\S+)"/g,Bpe="IconifyId"+Date.now().toString(16)+(Math.random()*16777216|0).toString(16);let zpe=0;function Npe(e,t=Bpe){const n=[];let r;for(;r=Fpe.exec(e);)n.push(r[1]);if(!n.length)return e;const i="suffix"+(Math.random()*16777216|Date.now()).toString(16);return n.forEach(s=>{const c=typeof t=="function"?t(s):t+(zpe++).toString(),a=s.replace(/[.*+?^${}()|[\]\\]/g,"\\$&");e=e.replace(new RegExp('([#;"])('+a+')([")]|\\.[a-z])',"g"),"$1"+c+i+"$3")}),e=e.replace(new RegExp(i,"g"),""),e}const PC=Object.create(null);function $pe(e,t){PC[e]=t}function MC(e){return PC[e]||PC[""]}function oA(e){let t;if(typeof e.resources=="string")t=[e.resources];else if(t=e.resources,!(t instanceof Array)||!t.length)return null;return{resources:t,path:e.path||"/",maxURL:e.maxURL||500,rotate:e.rotate||750,timeout:e.timeout||5e3,random:e.random===!0,index:e.index||0,dataAfterTimeout:e.dataAfterTimeout!==!1}}const aA=Object.create(null),Qy=["https://api.simplesvg.com","https://api.unisvg.com"],Bb=[];for(;Qy.length>0;)Qy.length===1||Math.random()>.5?Bb.push(Qy.shift()):Bb.push(Qy.pop());aA[""]=oA({resources:["https://api.iconify.design"].concat(Bb)});function jpe(e,t){const n=oA(t);return n===null?!1:(aA[e]=n,!0)}function sA(e){return aA[e]}const Upe=()=>{let e;try{if(e=fetch,typeof e=="function")return e}catch{}};let AR=Upe();function Vpe(e,t){const n=sA(e);if(!n)return 0;let r;if(!n.maxURL)r=0;else{let i=0;n.resources.forEach(c=>{i=Math.max(i,c.length)});const s=t+".json?icons=";r=n.maxURL-i-n.path.length-s.length}return r}function Gpe(e){return e===404}const qpe=(e,t,n)=>{const r=[],i=Vpe(e,t),s="icons";let c={type:s,provider:e,prefix:t,icons:[]},a=0;return n.forEach((m,g)=>{a+=m.length+1,a>=i&&g>0&&(r.push(c),c={type:s,provider:e,prefix:t,icons:[]},a=m.length),c.icons.push(m)}),r.push(c),r};function Wpe(e){if(typeof e=="string"){const t=sA(e);if(t)return t.path}return"/"}const Hpe=(e,t,n)=>{if(!AR){n("abort",424);return}let r=Wpe(t.provider);switch(t.type){case"icons":{const s=t.prefix,a=t.icons.join(","),m=new URLSearchParams({icons:a});r+=s+".json?"+m.toString();break}case"custom":{const s=t.uri;r+=s.slice(0,1)==="/"?s.slice(1):s;break}default:n("abort",400);return}let i=503;AR(e+r).then(s=>{const c=s.status;if(c!==200){setTimeout(()=>{n(Gpe(c)?"abort":"next",c)});return}return i=501,s.json()}).then(s=>{if(typeof s!="object"||s===null){setTimeout(()=>{s===404?n("abort",s):n("next",i)});return}setTimeout(()=>{n("success",s)})}).catch(()=>{n("next",i)})},Ype={prepare:qpe,send:Hpe};function Zpe(e){const t={loaded:[],missing:[],pending:[]},n=Object.create(null);e.sort((i,s)=>i.provider!==s.provider?i.provider.localeCompare(s.provider):i.prefix!==s.prefix?i.prefix.localeCompare(s.prefix):i.name.localeCompare(s.name));let r={provider:"",prefix:"",name:""};return e.forEach(i=>{if(r.name===i.name&&r.prefix===i.prefix&&r.provider===i.provider)return;r=i;const s=i.provider,c=i.prefix,a=i.name,m=n[s]||(n[s]=Object.create(null)),g=m[c]||(m[c]=vp(s,c));let x;a in g.icons?x=t.loaded:c===""||g.missing.has(a)?x=t.missing:x=t.pending;const T={provider:s,prefix:c,name:a};x.push(T)}),t}function L$(e,t){e.forEach(n=>{const r=n.loaderCallbacks;r&&(n.loaderCallbacks=r.filter(i=>i.id!==t))})}function Xpe(e){e.pendingCallbacksFlag||(e.pendingCallbacksFlag=!0,setTimeout(()=>{e.pendingCallbacksFlag=!1;const t=e.loaderCallbacks?e.loaderCallbacks.slice(0):[];if(!t.length)return;let n=!1;const r=e.provider,i=e.prefix;t.forEach(s=>{const c=s.icons,a=c.pending.length;c.pending=c.pending.filter(m=>{if(m.prefix!==i)return!0;const g=m.name;if(e.icons[g])c.loaded.push({provider:r,prefix:i,name:g});else if(e.missing.has(g))c.missing.push({provider:r,prefix:i,name:g});else return n=!0,!0;return!1}),c.pending.length!==a&&(n||L$([e],s.id),s.callback(c.loaded.slice(0),c.missing.slice(0),c.pending.slice(0),s.abort))})}))}let Kpe=0;function Qpe(e,t,n){const r=Kpe++,i=L$.bind(null,n,r);if(!t.pending.length)return i;const s={id:r,icons:t,callback:e,abort:i};
1435return n.forEach(c=>{(c.loaderCallbacks||(c.loaderCallbacks=[])).push(s)}),i}function Jpe(e,t=!0,n=!1){const r=[];return e.forEach(i=>{const s=typeof i=="string"?D1(i,t,n):i;s&&r.push(s)}),r}var eme={resources:[],index:0,timeout:2e3,rotate:750,random:!1,dataAfterTimeout:!1};function tme(e,t,n,r){const i=e.resources.length,s=e.random?Math.floor(Math.random()*i):e.index;let c;if(e.random){let Q=e.resources.slice(0);for(c=[];Q.length>1;){const Z=Math.floor(Math.random()*Q.length);c.push(Q[Z]),Q=Q.slice(0,Z).concat(Q.slice(Z+1))}c=c.concat(Q)}else c=e.resources.slice(s).concat(e.resources.slice(0,s));const a=Date.now();let m="pending",g=0,x,T=null,C=[],A=[];typeof r=="function"&&A.push(r);function P(){T&&(clearTimeout(T),T=null)}function D(){m==="pending"&&(m="aborted"),P(),C.forEach(Q=>{Q.status==="pending"&&(Q.status="aborted")}),C=[]}function B(Q,Z){Z&&(A=[]),typeof Q=="function"&&A.push(Q)}function R(){return{startTime:a,payload:t,status:m,queriesSent:g,queriesPending:C.length,subscribe:B,abort:D}}function N(){m="failed",A.forEach(Q=>{Q(void 0,x)})}function j(){C.forEach(Q=>{Q.status==="pending"&&(Q.status="aborted")}),C=[]}function U(Q,Z,K){const Y=Z!=="success";switch(C=C.filter(me=>me!==Q),m){case"pending":break;case"failed":if(Y||!e.dataAfterTimeout)return;break;default:return}if(Z==="abort"){x=K,N();return}if(Y){x=K,C.length||(c.length?W():N());return}if(P(),j(),!e.random){const me=e.resources.indexOf(Q.resource);me!==-1&&me!==e.index&&(e.index=me)}m="completed",A.forEach(me=>{me(K)})}function W(){if(m!=="pending")return;P();const Q=c.shift();if(Q===void 0){if(C.length){T=setTimeout(()=>{P(),m==="pending"&&(j(),N())},e.timeout);return}N();return}const Z={status:"pending",resource:Q,callback:(K,Y)=>{U(Z,K,Y)}};C.push(Z),g++,T=setTimeout(W,e.rotate),n(Q,t,Z.callback)}return setTimeout(W),R}function R$(e){const t={...eme,...e};let n=[];function r(){n=n.filter(a=>a().status==="pending")}function i(a,m,g){const x=tme(t,a,m,(T,C)=>{r(),g&&g(T,C)});return n.push(x),x}function s(a){return n.find(m=>a(m))||null}return{query:i,find:s,setIndex:a=>{t.index=a},getIndex:()=>t.index,cleanup:r}}function PR(){}const EE=Object.create(null);function nme(e){if(!EE[e]){const t=sA(e);if(!t)return;const n=R$(t),r={config:t,redundancy:n};EE[e]=r}return EE[e]}function rme(e,t,n){let r,i;if(typeof e=="string"){const s=MC(e);if(!s)return n(void 0,424),PR;i=s.send;const c=nme(e);c&&(r=c.redundancy)}else{const s=oA(e);if(s){r=R$(s);const c=e.resources?e.resources[0]:"",a=MC(c);a&&(i=a.send)}}return!r||!i?(n(void 0,424),PR):r.query(t,i,n)().abort}const MR="iconify2",av="iconify",F$=av+"-count",IR=av+"-version",B$=36e5,ime=168;function IC(e,t){try{return e.getItem(t)}catch{}}function lA(e,t,n){try{return e.setItem(t,n),!0}catch{}}function OR(e,t){try{e.removeItem(t)}catch{}}function OC(e,t){return lA(e,F$,t.toString())}function DC(e){return parseInt(IC(e,F$))||0}const R1={local:!0,session:!0},z$={local:new Set,session:new Set};let cA=!1;function ome(e){cA=e}let fb=typeof window>"u"?{}:window;function N$(e){const t=e+"Storage";try{if(fb&&fb[t]&&typeof fb[t].length=="number")return fb[t]}catch{}R1[e]=!1}function $$(e,t){const n=N$(e);if(!n)return;const r=IC(n,IR);if(r!==MR){if(r){const a=DC(n);for(let m=0;m<a;m++)OR(n,av+m.toString())}lA(n,IR,MR),OC(n,0);return}const i=Math.floor(Date.now()/B$)-ime,s=a=>{const m=av+a.toString(),g=IC(n,m);if(typeof g=="string"){try{const x=JSON.parse(g);if(typeof x=="object"&&typeof x.cached=="number"&&x.cached>i&&typeof x.provider=="string"&&typeof x.data=="object"&&typeof x.data.prefix=="string"&&t(x,a))return!0}catch{}OR(n,m)}};let c=DC(n);for(let a=c-1;a>=0;a--)s(a)||(a===c-1?(c--,OC(n,c)):z$[e].add(a))}function j$(){if(!cA){ome(!0);for(const e in R1)$$(e,t=>{const n=t.data,r=t.provider,i=n.prefix,s=vp(r,i);if(!iA(s,n).length)return!1;const c=n.lastModified||-1;return s.lastModifiedCached=s.lastModifiedCached?Math.min(s.lastModifiedCached,c):c,!0})}}function ame(e,t){const n=e.lastModifiedCached;if(n&&n>=t)return n===t;if(e.lastModifiedCached=t,n)for(const r in R1)$$(r,i=>{const s=i.data;return i.provider!==e.provider||s.prefix!==e.prefix||s.lastModified===t});return!0}function sme(e,t){cA||j$();function n(r){let i;if(!R1[r]||!(i=N$(r)))return;const s=z$[r];let c;if(s.size)s.delete(c=Array.from(s).shift());else if(c=DC(i),!OC(i,c+1))return;const a={cached:Math.floor(Date.now()/B$),provider:e.provider,data:t};return lA(i,av+c.toString(),JSON.stringify(a))}t.lastModified&&!ame(e,t.lastModified)||Object.keys(t.icons).length&&(t.not_found&&(t=Object.assign({},t),delete t.not_found),n("local")||n("session"))}function DR(){}function lme(e){e.iconsLoaderFlag||(e.iconsLoaderFlag=!0,setTimeout(()=>{e.iconsLoaderFlag=!1,Xpe(e)}))}function cme(e,t){e.iconsToLoad?e.iconsToLoad=e.iconsToLoad.concat(t).sort():e.iconsToLoad=t,e.iconsQueueFlag||(e.iconsQueueFlag=!0,setTimeout(()=>{e.iconsQueueFlag=!1;const{provider:n,prefix:r}=e,i=e.iconsToLoad;delete e.iconsToLoad;let s;if(!i||!(s=MC(n)))return;
1435s.prepare(n,r,i).forEach(a=>{rme(n,a,m=>{if(typeof m!="object")a.icons.forEach(g=>{e.missing.add(g)});else try{const g=iA(e,m);if(!g.length)return;const x=e.pendingIcons;x&&g.forEach(T=>{x.delete(T)}),sme(e,m)}catch(g){console.error(g)}lme(e)})})}))}const ume=(e,t)=>{const n=Jpe(e,!0,I$()),r=Zpe(n);if(!r.pending.length){let m=!0;return t&&setTimeout(()=>{m&&t(r.loaded,r.missing,r.pending,DR)}),()=>{m=!1}}const i=Object.create(null),s=[];let c,a;return r.pending.forEach(m=>{const{provider:g,prefix:x}=m;if(x===a&&g===c)return;c=g,a=x,s.push(vp(g,x));const T=i[g]||(i[g]=Object.create(null));T[x]||(T[x]=[])}),r.pending.forEach(m=>{const{provider:g,prefix:x,name:T}=m,C=vp(g,x),A=C.pendingIcons||(C.pendingIcons=new Set);A.has(T)||(A.add(T),i[g][x].push(T))}),s.forEach(m=>{const{provider:g,prefix:x}=m;i[g][x].length&&cme(m,i[g][x])}),t?Qpe(t,r,s):DR};function hme(e,t){const n={...e};for(const r in t){const i=t[r],s=typeof i;r in O$?(i===null||i&&(s==="string"||s==="number"))&&(n[r]=i):s===typeof n[r]&&(n[r]=r==="rotate"?i%4:i)}return n}const dme=/[\s,]+/;function fme(e,t){t.split(dme).forEach(n=>{switch(n.trim()){case"horizontal":e.hFlip=!0;break;case"vertical":e.vFlip=!0;break}})}function pme(e,t=0){const n=e.replace(/^-?[0-9.]*/,"");function r(i){for(;i<0;)i+=4;return i%4}if(n===""){const i=parseInt(e);return isNaN(i)?0:r(i)}else if(n!==e){let i=0;switch(n){case"%":i=25;break;case"deg":i=90}if(i){let s=parseFloat(e.slice(0,e.length-n.length));return isNaN(s)?0:(s=s/i,s%1===0?r(s):0)}}return t}function mme(e,t){let n=e.indexOf("xlink:")===-1?"":' xmlns:xlink="http://www.w3.org/1999/xlink"';for(const r in t)n+=" "+r+'="'+t[r]+'"';return'<svg xmlns="http://www.w3.org/2000/svg"'+n+">"+e+"</svg>"}function gme(e){return e.replace(/"/g,"'").replace(/%/g,"%25").replace(/#/g,"%23").replace(/</g,"%3C").replace(/>/g,"%3E").replace(/\s+/g," ")}function yme(e){return"data:image/svg+xml,"+gme(e)}function _me(e){return'url("'+yme(e)+'")'}const LR={...D$,inline:!1},vme={xmlns:"http://www.w3.org/2000/svg","xmlns:xlink":"http://www.w3.org/1999/xlink","aria-hidden":!0,role:"img"},bme={display:"inline-block"},LC={backgroundColor:"currentColor"},U$={backgroundColor:"transparent"},RR={Image:"var(--svg)",Repeat:"no-repeat",Size:"100% 100%"},FR={webkitMask:LC,mask:LC,background:U$};for(const e in FR){const t=FR[e];for(const n in RR)t[e+n]=RR[n]}const zb={};["horizontal","vertical"].forEach(e=>{const t=e.slice(0,1)+"Flip";zb[e+"-flip"]=t,zb[e.slice(0,1)+"-flip"]=t,zb[e+"Flip"]=t});function BR(e){return e+(e.match(/^[-0-9.]+$/)?"px":"")}const zR=(e,t)=>{const n=hme(LR,t),r={...vme},i=t.mode||"svg",s={},c=t.style,a=typeof c=="object"&&!(c instanceof Array)?c:{};for(let D in t){const B=t[D];if(B!==void 0)switch(D){case"icon":case"style":case"onLoad":case"mode":break;case"inline":case"hFlip":case"vFlip":n[D]=B===!0||B==="true"||B===1;break;case"flip":typeof B=="string"&&fme(n,B);break;case"color":s.color=B;break;case"rotate":typeof B=="string"?n[D]=pme(B):typeof B=="number"&&(n[D]=B);break;case"ariaHidden":case"aria-hidden":B!==!0&&B!=="true"&&delete r["aria-hidden"];break;default:{const R=zb[D];R?(B===!0||B==="true"||B===1)&&(n[R]=!0):LR[D]===void 0&&(r[D]=B)}}}const m=Rpe(e,n),g=m.attributes;if(n.inline&&(s.verticalAlign="-0.125em"),i==="svg"){r.style={...s,...a},Object.assign(r,g);let D=0,B=t.id;return typeof B=="string"&&(B=B.replace(/-/g,"_")),r.innerHTML=Npe(m.body,B?()=>B+"ID"+D++:"iconifyVue"),ao("svg",r)}const{body:x,width:T,height:C}=e,A=i==="mask"||(i==="bg"?!1:x.indexOf("currentColor")!==-1),P=mme(x,{...g,width:T+"",height:C+""});return r.style={...s,"--svg":_me(P),width:BR(g.width),height:BR(g.height),...bme,...A?LC:U$,...a},ao("span",r)};I$(!0);$pe("",Ype);if(typeof document<"u"&&typeof window<"u"){j$();const e=window;if(e.IconifyPreload!==void 0){const t=e.IconifyPreload,n="Invalid IconifyPreload syntax.";typeof t=="object"&&t!==null&&(t instanceof Array?t:[t]).forEach(r=>{try{(typeof r!="object"||r===null||r instanceof Array||typeof r.icons!="object"||typeof r.prefix!="string"||!Ipe(r))&&console.error(n)}catch{console.error(n)}})}if(e.IconifyProviders!==void 0){const t=e.IconifyProviders;if(typeof t=="object"&&t!==null)for(let n in t){const r="IconifyProviders["+n+"] is invali
1435d.";try{const i=t[n];if(typeof i!="object"||!i||i.resources===void 0)continue;jpe(n,i)||console.error(r)}catch{console.error(r)}}}}const xme={...L1,body:""},wme=sr({inheritAttrs:!1,data(){return{iconMounted:!1,counter:0}},mounted(){this._name="",this._loadingIcon=null,this.iconMounted=!0},unmounted(){this.abortLoading()},methods:{abortLoading(){this._loadingIcon&&(this._loadingIcon.abort(),this._loadingIcon=null)},getIcon(e,t){if(typeof e=="object"&&e!==null&&typeof e.body=="string")return this._name="",this.abortLoading(),{data:e};let n;if(typeof e!="string"||(n=D1(e,!1,!0))===null)return this.abortLoading(),null;const r=Ppe(n);if(!r)return(!this._loadingIcon||this._loadingIcon.name!==e)&&(this.abortLoading(),this._name="",r!==null&&(this._loadingIcon={name:e,abort:ume([n],()=>{this.counter++})})),null;this.abortLoading(),this._name!==e&&(this._name=e,t&&t(e));const i=["iconify"];return n.prefix!==""&&i.push("iconify--"+n.prefix),n.provider!==""&&i.push("iconify--"+n.provider),{data:r,classes:i}}},render(){this.counter;const e=this.$attrs,t=this.iconMounted?this.getIcon(e.icon,e.onLoad):null;if(!t)return zR(xme,e);let n=e;return t.classes&&(n={...e,class:(typeof e.class=="string"?e.class+" ":"")+t.classes.join(" ")}),zR({...L1,...t.data},n)}}),Tme={collapse:"ph:caret-up",complete:"ph:check",cancel:"ph:x-circle",close:"ph:x",delete:"ph:trash",clear:"ph:x-circle",success:"ph:check-circle",info:"ph:info",warning:"ph:warning",error:"ph:x-circle",prev:"ph:caret-left",next:"ph:caret-right",checkboxOn:"ph:check-square-fill",checkboxOff:"ph:square",checkboxIndeterminate:"ph:square-logo-fill",delimiter:"ph:circle-fill",sort:"ph:arrows-down-up-fill",expand:"ph:caret-down",menu:"ph:list",subgroup:"ph:caret-down-fill",dropdown:"ph:caret-down-fill",radioOn:"ph:radio-button-fill",radioOff:"ph:circle",edit:"ph:note-pencil",ratingEmpty:"ph:star",ratingFull:"ph:star-fill",ratingHalf:"ph:star-half-fill",loading:"ph:spinner",first:"ph:caret-double-left-duotone",last:"ph:caret-double-right-duotone",unfold:"ph:arrows-down-up",file:"ph:paperclip",plus:"ph:plus",minus:"ph:minus",sortAsc:"ph:sort-ascending",sortDesc:"ph:sort-descending"},Eme={component:e=>ao(wme,{...e})};function zv(e,t){let n;function r(){n=xg(),n.run(()=>t.length?t(()=>{n==null||n.stop(),r()}):t())}Nn(e,i=>{i&&!n?r():i||(n==null||n.stop(),n=void 0)},{immediate:!0}),$s(()=>{n==null||n.stop()})}const Ro=typeof window<"u",Sme=Ro&&"IntersectionObserver"in window,Cme=Ro&&("ontouchstart"in window||window.navigator.maxTouchPoints>0);function NR(e,t,n){kme(e,t),t.set(e,n)}function kme(e,t){if(t.has(e))throw new TypeError("Cannot initialize the same private elements twice on an object")}function Ame(e,t,n){var r=V$(e,t,"set");return Pme(e,r,n),n}function Pme(e,t,n){if(t.set)t.set.call(e,n);else{if(!t.writable)throw new TypeError("attempted to set read only private field");t.value=n}}function Bf(e,t){var n=V$(e,t,"get");return Mme(e,n)}function V$(e,t,n){if(!t.has(e))throw new TypeError("attempted to "+n+" private field on non-instance");return t.get(e)}function Mme(e,t){return t.get?t.get.call(e):t.value}function G$(e,t,n){const r=t.length-1;if(r<0)return e===void 0?n:e;for(let i=0;i<r;i++){if(e==null)return n;e=e[t[i]]}return e==null||e[t[r]]===void 0?n:e[t[r]]}function Ime(e,t){if(e===t)return!0;if(e instanceof Date&&t instanceof Date&&e.getTime()!==t.getTime()||e!==Object(e)||t!==Object(t))return!1;const n=Object.keys(e);return n.length!==Object.keys(t).length?!1:n.every(r=>Ime(e[r],t[r]))}function RC(e,t,n){return e==null||!t||typeof t!="string"?n:e[t]!==void 0?e[t]:(t=t.replace(/\[(\w+)\]/g,".$1"),t=t.replace(/^\./,""),G$(e,t.split("."),n))}function I_e(e,t,n){if(t==null)return e===void 0?n:e;if(e!==Object(e)){if(typeof t!="function")return n;const i=t(e,n);return typeof i>"u"?n:i}if(typeof t=="string")return RC(e,t,n);if(Array.isArray(t))return G$(e,t,n);if(typeof t!="function")return n;const r=t(e,n);return typeof r>"u"?n:r}function q$(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0;return Array.from({length:e},(n,r)=>t+r)}function si(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"px";if(!(e==null||e===""))return isNaN(+e)?String(e):isFinite(+e)?`${Number(e)}${t}`:void 0}function $R(e){return e!==null&&typeof e=="object"&&!Array.isArray(e)}function FC(e){return e&&"$el"in e?e.$el:e}const O_e=Object.freeze({enter:13,tab:9,delete:46,esc:27,space:32,up:38,down:40,left
1435:37,right:39,end:35,home:36,del:46,backspace:8,insert:45,pageup:33,pagedown:34,shift:16}),D_e=Object.freeze({enter:"Enter",tab:"Tab",delete:"Delete",esc:"Escape",space:"Space",up:"ArrowUp",down:"ArrowDown",left:"ArrowLeft",right:"ArrowRight",end:"End",home:"Home",del:"Delete",backspace:"Backspace",insert:"Insert",pageup:"PageUp",pagedown:"PageDown",shift:"Shift"});function L_e(e){return Object.keys(e)}function SE(e,t){return t.every(n=>e.hasOwnProperty(n))}function uA(e,t,n){const r=Object.create(null),i=Object.create(null);for(const s in e)t.some(c=>c instanceof RegExp?c.test(s):c===s)&&!(n!=null&&n.some(c=>c===s))?r[s]=e[s]:i[s]=e[s];return[r,i]}function R_e(e,t){const n={...e};return t.forEach(r=>delete n[r]),n}function Ome(e,t){const n={};return t.forEach(r=>n[r]=e[r]),n}function Dme(e){return uA(e,["class","style","id",/^data-/])}function F_e(e){return e==null?[]:Array.isArray(e)?e:[e]}function BC(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0,n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:1;return Math.max(t,Math.min(n,e))}function B_e(e){const t=e.toString().trim();return t.includes(".")?t.length-t.indexOf(".")-1:0}function jR(e,t){let n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:"0";return e+n.repeat(Math.max(0,t-e.length))}function Lme(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:1;const n=[];let r=0;for(;r<e.length;)n.push(e.substr(r,t)),r+=t;return n}function ql(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},n=arguments.length>2?arguments[2]:void 0;const r={};for(const i in e)r[i]=e[i];for(const i in t){const s=e[i],c=t[i];if($R(s)&&$R(c)){r[i]=ql(s,c,n);continue}if(Array.isArray(s)&&Array.isArray(c)&&n){r[i]=n(s,c);continue}r[i]=c}return r}function W$(e){return e.map(t=>t.type===Hn?W$(t.children):t).flat()}function fp(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:"";if(fp.cache.has(e))return fp.cache.get(e);const t=e.replace(/[^a-z]/gi,"-").replace(/\B([A-Z])/g,"-$1").toLowerCase();return fp.cache.set(e,t),t}fp.cache=new Map;function CE(e,t){if(!t||typeof t!="object")return[];if(Array.isArray(t))return t.map(n=>CE(e,n)).flat(1);if(Array.isArray(t.children))return t.children.map(n=>CE(e,n)).flat(1);if(t.component){if(Object.getOwnPropertySymbols(t.component.provides).includes(e))return[t.component];if(t.component.subTree)return CE(e,t.component.subTree).flat(1)}return[]}var pb=new WeakMap,vm=new WeakMap;class z_e{constructor(t){NR(this,pb,{writable:!0,value:[]}),NR(this,vm,{writable:!0,value:0}),this.size=t}push(t){Bf(this,pb)[Bf(this,vm)]=t,Ame(this,vm,(Bf(this,vm)+1)%this.size)}values(){return Bf(this,pb).slice(Bf(this,vm)).concat(Bf(this,pb).slice(0,Bf(this,vm)))}}function hA(e){const t=so({}),n=yt(e);return sh(()=>{for(const r in n.value)t[r]=n.value[r]},{flush:"sync"}),wv(t)}function Ox(e,t){return e.includes(t)}const Rme=/^on[^a-z]/,dA=e=>Rme.test(e);function H$(e){return e[2].toLowerCase()+e.slice(3)}const Nb=()=>[Function,Array];function UR(e,t){return t="on"+_v(t),!!(e[t]||e[`${t}Once`]||e[`${t}Capture`]||e[`${t}OnceCapture`]||e[`${t}CaptureOnce`])}function N_e(e){for(var t=arguments.length,n=new Array(t>1?t-1:0),r=1;r<t;r++)n[r-1]=arguments[r];if(Array.isArray(e))for(const i of e)i(...n);else typeof e=="function"&&e(...n)}function Fme(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!0;const n=["button","[href]",'input:not([type="hidden"])',"select","textarea","[tabindex]"].map(r=>`${r}${t?':not([tabindex="-1"])':""}:not([disabled])`).join(", ");return[...e.querySelectorAll(n)]}function Bme(e,t,n){let r,i=e.indexOf(document.activeElement);const s=t==="next"?1:-1;do i+=s,r=e[i];while((!r||r.offsetParent==null||!((n==null?void 0:n(r))??!0))&&i<e.length&&i>=0);return r}function zC(e,t){var r,i,s,c;const n=Fme(e);if(!t)(e===document.activeElement||!e.contains(document.activeElement))&&((r=n[0])==null||r.focus());else if(t==="first")(i=n[0])==null||i.focus();else if(t==="last")(s=n.at(-1))==null||s.focus();else if(typeof t=="number")(c=n[t])==null||c.focus();else{const a=Bme(n,t);
vendor: 5,253 bytes, lines 1435-1436
1435a?a.focus():zC(e,t==="next"?"first":"last")}}function $_e(e){return e==null||typeof e=="string"&&e.trim()===""}function j_e(){}function zme(e,t){if(!(Ro&&typeof CSS<"u"&&typeof CSS.supports<"u"&&CSS.supports(`selector(${t})`)))return null;try{return!!e&&e.matches(t)}catch{return null}}const Y$=["top","bottom"],Nme=["start","end","left","right"];function NC(e,t){let[n,r]=e.split(" ");return r||(r=Ox(Y$,n)?"start":Ox(Nme,n)?"top":"center"),{side:VR(n,t),align:VR(r,t)}}function VR(e,t){return e==="start"?t?"right":"left":e==="end"?t?"left":"right":e}function kE(e){return{side:{center:"center",top:"bottom",bottom:"top",left:"right",right:"left"}[e.side],align:e.align}}function AE(e){return{side:e.side,align:{center:"center",top:"bottom",bottom:"top",left:"right",right:"left"}[e.align]}}function GR(e){return{side:e.align,align:e.side}}function qR(e){return Ox(Y$,e.side)?"y":"x"}class Ym{constructor(t){let{x:n,y:r,width:i,height:s}=t;this.x=n,this.y=r,this.width=i,this.height=s}get top(){return this.y}get bottom(){return this.y+this.height}get left(){return this.x}get right(){return this.x+this.width}}function WR(e,t){return{x:{before:Math.max(0,t.left-e.left),after:Math.max(0,e.right-t.right)},y:{before:Math.max(0,t.top-e.top),after:Math.max(0,e.bottom-t.bottom)}}}function Z$(e){const t=e.getBoundingClientRect(),n=getComputedStyle(e),r=n.transform;if(r){let i,s,c,a,m;if(r.startsWith("matrix3d("))i=r.slice(9,-1).split(/, /),s=+i[0],c=+i[5],a=+i[12],m=+i[13];else if(r.startsWith("matrix("))i=r.slice(7,-1).split(/, /),s=+i[0],c=+i[3],a=+i[4],m=+i[5];else return new Ym(t);const g=n.transformOrigin,x=t.x-a-(1-s)*parseFloat(g),T=t.y-m-(1-c)*parseFloat(g.slice(g.indexOf(" ")+1)),C=s?t.width/s:e.offsetWidth+1,A=c?t.height/c:e.offsetHeight+1;return new Ym({x,y:T,width:C,height:A})}else return new Ym(t)}function X$(e,t,n){if(typeof e.animate>"u")return{finished:Promise.resolve()};let r;try{r=e.animate(t,n)}catch{return{finished:Promise.resolve()}}return typeof r.finished>"u"&&(r.finished=new Promise(i=>{r.onfinish=()=>{i(r)}})),r}const $b=new WeakMap;function $me(e,t){Object.keys(t).forEach(n=>{if(dA(n)){const r=H$(n),i=$b.get(e);if(t[n]==null)i==null||i.forEach(s=>{const[c,a]=s;c===r&&(e.removeEventListener(r,a),i.delete(s))});else if(!i||![...i].some(s=>s[0]===r&&s[1]===t[n])){e.addEventListener(r,t[n]);const s=i||new Set;s.add([r,t[n]]),$b.has(e)||$b.set(e,s)}}else t[n]==null?e.removeAttribute(n):e.setAttribute(n,t[n])})}function jme(e,t){Object.keys(t).forEach(n=>{if(dA(n)){const r=H$(n),i=$b.get(e);i==null||i.forEach(s=>{const[c,a]=s;c===r&&(e.removeEventListener(r,a),i.delete(s))})}else e.removeAttribute(n)})}function U_e(e,t){t=Array.isArray(t)?t.slice(0,-1).map(n=>`'${n}'`).join(", ")+` or '${t.at(-1)}'`:`'${t}'`}const Dx=.20689655172413793,Ume=e=>e>Dx**3?Math.cbrt(e):e/(3*Dx**2)+4/29,Vme=e=>e>Dx?e**3:3*Dx**2*(e-4/29);function K$(e){const t=Ume,n=t(e[1]);return[116*n-16,500*(t(e[0]/.95047)-n),200*(n-t(e[2]/1.08883))]}function Q$(e){const t=Vme,n=(e[0]+16)/116;return[t(n+e[1]/500)*.95047,t(n),t(n-e[2]/200)*1.08883]}const Gme=[[3.2406,-1.5372,-.4986],[-.9689,1.8758,.0415],[.0557,-.204,1.057]],qme=e=>e<=.0031308?e*12.92:1.055*e**(1/2.4)-.055,Wme=[[.4124,.3576,.1805],[.2126,.7152,.0722],[.0193,.1192,.9505]],Hme=e=>e<=.04045?e/12.92:((e+.055)/1.055)**2.4;function J$(e){const t=Array(3),n=qme,r=Gme;for(let i=0;i<3;++i)t[i]=Math.round(BC(n(r[i][0]*e[0]+r[i][1]*e[1]+r[i][2]*e[2]))*255);return{r:t[0],g:t[1],b:t[2]}}function fA(e){let{r:t,g:n,b:r}=e;const i=[0,0,0],s=Hme,c=Wme;t=s(t/255),n=s(n/255),r=s(r/255);for(let a=0;a<3;++a)i[a]=c[a][0]*t+c[a][1]*n+c[a][2]*r;return i}function HR(e){return!!e&&/^(#|var\(--|(rgb|hsl)a?\()/.test(e)}const YR=/^(?<fn>(?:rgb|hsl)a?)\((?<values>.+)\)/,Yme={rgb:(e,t,n,r)=>({r:e,g:t,b:n,a:r}),rgba:(e,t,n,r)=>({r:e,g:t,b:n,a:r}),hsl:(e,t,n,r)=>ZR({h:e,s:t,l:n,a:r}),hsla:(e,t,n,r)=>ZR({h:e,s:t,l:n,a:r}),hsv:(e,t,n,r)=>sv({h:e,s:t,v:n,a:r}),hsva:(e,t,n,r)=>sv({h:e,s:t,v:n,a:r})};function Qf(e){if(typeof e=="number")return{r:(e&16711680)>>16,g:(e&65280)>>8,b:e&255};if(typeof e=="string"&&YR.test(e)){const{groups:t}=e.match(YR),{fn:n,values:r}=t,i=r.split(/,\s*/).map(s=>s.endsWith("%")&&["hsl","hsla","hsv","hsva"].includes(n)?parseFloat(s)/100:parseFloat(s));return Yme[n](...i)}else if(typeof e=="string"){let t=e.startsWith("#")?e.slice(1):e;return[3,4].includes(t.length)?t=t.split("").map(n=>n+n).join(""):[6,8].includes(t.length),Xme(t)}else if(typeof e=="object"){if(SE(e,["r","g","b"]))return e;if(SE(e,["h","s","l"]))return sv(ej(e));if(SE(e,["h","s","v"]))return sv(e)}throw new TypeError(`Invalid color: ${e==null?e:String(e)||e.constructor.name}
1436Expected #hex, #hexa, rgb(), rgba(), hsl(), hsla(), object or number`)}function sv(e){const{h:t,s:n,v:r,a:i}=e,s=a=>{const m=(a+t/60)%6;return r-r*n*Math.max(Math.min(m,4-m,1),0)},c=[s(5),s(3),s(1)].map(a=>Math.round(a*255));return{r:c[0],g:c[1],b:c[2],a:i}}function ZR(e){return sv(ej(e))}function ej(e){const{h:t,s:n,l:r,a:i}=e,s=r+n*Math.min(r,1-r),c=s===0?0:2-2*r/s;return{h:t,s:c,v:s,a:i}}function mb(e){const t=Math.round(e).toString(16);return("00".substr(0,2-t.length)+t).toUpperCase()}function Zme(e){let{r:t,g:n,b:r,a:i}=e;return`#${[mb(t),mb(n),mb(r),i!==void 0?mb(Math.round(i*255)):""].join("")}`}
1436function Xme(e){e=Kme(e);let[t,n,r,i]=Lme(e,2).map(s=>parseInt(s,16));return i=i===void 0?i:i/255,{r:t,g:n,b:r,a:i}}function Kme(e){return e.startsWith("#")&&(e=e.slice(1)),e=e.replace(/([^0-9a-f])/gi,"F"),(e.length===3||e.length===4)&&(e=e.split("").map(t=>t+t).join("")),e.length!==6&&(e=jR(jR(e,6),8,"F")),e}function Qme(e,t){const n=K$(fA(e));return n[0]=n[0]+t*10,J$(Q$(n))}function Jme(e,t){const n=K$(fA(e));return n[0]=n[0]-t*10,J$(Q$(n))}function ege(e){const t=Qf(e);return fA(t)[1]}function qi(e,t){return n=>Object.keys(e).reduce((r,i)=>{const c=typeof e[i]=="object"&&e[i]!=null&&!Array.isArray(e[i])?e[i]:{type:e[i]};return n&&i in n?r[i]={...c,default:n[i]}:r[i]=c,t&&!r[i].source&&(r[i].source=t),r},{})}const Sp=qi({class:[String,Array],style:{type:[String,Array,Object],default:null}},"component");function Nv(e){if(e._setup=e._setup??e.setup,!e.name)return e;if(e._setup){e.props=qi(e.props??{},e.name)();const t=Object.keys(e.props);e.filterProps=function(r){return uA(r,t,["class","style"])},e.props._as=String,e.setup=function(r,i){const s=gA();if(!s.value)return e._setup(r,i);const{props:c,provideSubDefaults:a}=sge(r,r._as??e.name,s),m=e._setup(c,i);return a(),m}}return e}function Dc(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:!0;return t=>(e?Nv:sr)(t)}function V_e(e,t){return t.props=e,t}function tj(e){if(typeof e.getRootNode!="function"){for(;e.parentNode;)e=e.parentNode;return e!==document?null:document}const t=e.getRootNode();return t!==document&&t.getRootNode({composed:!0})!==document?null:t}const nj="cubic-bezier(0.4, 0, 0.2, 1)",G_e="cubic-bezier(0.0, 0, 0.2, 1)",q_e="cubic-bezier(0.4, 0, 1, 1)";function Ql(e,t){const n=ko();if(!n)throw new Error(`[Vuetify] ${e} ${t||"must be called from inside a setup function"}`);return n}function F1(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:"composables";const t=Ql(e).type;return fp((t==null?void 0:t.aliasName)||(t==null?void 0:t.name))}let rj=0,jb=new WeakMap;function pA(){const e=Ql("getUid");if(jb.has(e))return jb.get(e);{const t=rj++;return jb.set(e,t),t}}pA.reset=()=>{rj=0,jb=new WeakMap};function tge(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1;for(;e;){if(t?nge(e):mA(e))return e;e=e.parentElement}return document.scrollingElement}function Lx(e,t){const n=[];if(t&&e&&!t.contains(e))return n;for(;e&&(mA(e)&&n.push(e),e!==t);)e=e.parentElement;return n}function mA(e){if(!e||e.nodeType!==Node.ELEMENT_NODE)return!1;const t=window.getComputedStyle(e);return t.overflowY==="scroll"||t.overflowY==="auto"&&e.scrollHeight>e.clientHeight}function nge(e){if(!e||e.nodeType!==Node.ELEMENT_NODE)return!1;const t=window.getComputedStyle(e);return["scroll","auto"].includes(t.overflowY)}function rge(e){const{provides:t}=Ql("injectSelf");if(t&&e in t)return t[e]}function ige(e){for(;e;){if(window.getComputedStyle(e).position==="fixed")return!0;e=e.offsetParent}return!1}function jd(e){const t=Ql("useRender");t.render=e}const lv=Symbol.for("vuetify:defaults");function oge(e){return jt(e)}function gA(){const e=dr(lv);if(!e)throw new Error("[Vuetify] Could not find defaults instance");return e}function ij(e,t){const n=gA(),r=jt(e),i=yt(()=>{if(bt(t==null?void 0:t.disabled))return n.value;const c=bt(t==null?void 0:t.scoped),a=bt(t==null?void 0:t.reset),m=bt(t==null?void 0:t.root);let g=ql(r.value,{prev:n.value});if(c)return g;if(a||m){const x=Number(a||1/0);for(let T=0;T<=x&&!(!g||!("prev"in g));T++)g=g.prev;return g&&typeof m=="string"&&m in g&&(g=ql(ql(g,{prev:g}),g[m])),g}return g.prev?ql(g.prev,g):g});return ea(lv,i),i}function age(e,t){var n,r;return typeof((n=e.props)==null?void 0:n[t])<"u"||typeof((r=e.props)==null?void 0:r[fp(t)])<"u"}function sge(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},t=arguments.length>1?arguments[1]:void 0,n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:gA();const r=Ql("useDefaults");if(t=t??r.type.name??r.type.__name,!t)throw new Error("[Vuetify] Could not determine component name");const i=yt(()=>{var m;return(m=n.value)==null?void 0:m[e._as??t]}),s=new Proxy(e,{get(m,g){var T,C,A,P;const x=Reflect.get(m,g);return g==="class"||g==="style"?[(T=i.value)==null?void 0:T[g],x].filter(D=>D!=null):typeof g=="string"&&!age(r.vnode,g)?((C=i.value)==null?void 0:C[g])??((P=(A=n.value)==null?void 0:A.global)==null?void 0:P[g])??x:x}}),c=ua();sh(()=>
1436{if(i.value){const m=Object.entries(i.value).filter(g=>{let[x]=g;return x.startsWith(x[0].toUpperCase())});m.length&&(c.value=Object.fromEntries(m))}});function a(){zv(c,()=>{var m;ij(ql(((m=rge(lv))==null?void 0:m.value)??{},c.value))})}return{props:s,provideSubDefaults:a}}const W_e=["sm","md","lg","xl","xxl"],$C=Symbol.for("vuetify:display"),XR={mobileBreakpoint:"lg",thresholds:{xs:0,sm:600,md:960,lg:1280,xl:1920,xxl:2560}},lge=function(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:XR;return ql(XR,e)};function KR(e){return Ro&&!e?window.innerWidth:typeof e=="object"&&e.clientWidth||0}function QR(e){return Ro&&!e?window.innerHeight:typeof e=="object"&&e.clientHeight||0}function JR(e){const t=Ro&&!e?window.navigator.userAgent:"ssr";function n(P){return!!t.match(P)}const r=n(/android/i),i=n(/iphone|ipad|ipod/i),s=n(/cordova/i),c=n(/electron/i),a=n(/chrome/i),m=n(/edge/i),g=n(/firefox/i),x=n(/opera/i),T=n(/win/i),C=n(/mac/i),A=n(/linux/i);return{android:r,ios:i,cordova:s,electron:c,chrome:a,edge:m,firefox:g,opera:x,win:T,mac:C,linux:A,touch:Cme,ssr:t==="ssr"}}function cge(e,t){const{thresholds:n,mobileBreakpoint:r}=lge(e),i=ua(QR(t)),s=ua(JR(t)),c=so({}),a=ua(KR(t));function m(){i.value=QR(),a.value=KR()}function g(){m(),s.value=JR()}return sh(()=>{const x=a.value<n.sm,T=a.value<n.md&&!x,C=a.value<n.lg&&!(T||x),A=a.value<n.xl&&!(C||T||x),P=a.value<n.xxl&&!(A||C||T||x),D=a.value>=n.xxl,B=x?"xs":T?"sm":C?"md":A?"lg":P?"xl":"xxl",R=typeof r=="number"?r:n[r],N=a.value<R;c.xs=x,c.sm=T,c.md=C,c.lg=A,c.xl=P,c.xxl=D,c.smAndUp=!x,c.mdAndUp=!(x||T),c.lgAndUp=!(x||T||C),c.xlAndUp=!(x||T||C||A),c.smAndDown=!(C||A||P||D),c.mdAndDown=!(A||P||D),c.lgAndDown=!(P||D),c.xlAndDown=!D,c.name=B,c.height=i.value,c.width=a.value,c.mobile=N,c.mobileBreakpoint=r,c.platform=s.value,c.thresholds=n}),Ro&&window.addEventListener("resize",m,{passive:!0}),{...wv(c),update:g,ssr:!!t}}function uge(){const e=dr($C);if(!e)throw new Error("Could not find Vuetify display injection");return e}const hge={collapse:"mdi-chevron-up",complete:"mdi-check",cancel:"mdi-close-circle",close:"mdi-close",delete:"mdi-close-circle",clear:"mdi-close-circle",success:"mdi-check-circle",info:"mdi-information",warning:"mdi-alert-circle",error:"mdi-close-circle",prev:"mdi-chevron-left",next:"mdi-chevron-right",checkboxOn:"mdi-checkbox-marked",checkboxOff:"mdi-checkbox-blank-outline",checkboxIndeterminate:"mdi-minus-box",delimiter:"mdi-circle",sortAsc:"mdi-arrow-up",sortDesc:"mdi-arrow-down",expand:"mdi-chevron-down",menu:"mdi-menu",subgroup:"mdi-menu-down",dropdown:"mdi-menu-down",radioOn:"mdi-radiobox-marked",radioOff:"mdi-radiobox-blank",edit:"mdi-pencil",ratingEmpty:"mdi-star-outline",ratingFull:"mdi-star",ratingHalf:"mdi-star-half-full",loading:"mdi-cached",first:"mdi-page-first",last:"mdi-page-last",unfold:"mdi-unfold-more-horizontal",file:"mdi-paperclip",plus:"mdi-plus",minus:"mdi-minus",calendar:"mdi-calendar"},dge={component:e=>ao(aj,{...e,class:"mdi"})},A_=[String,Function,Object,Array],jC=Symbol.for("vuetify:icons"),B1=qi({icon:{type:A_},tag:{type:String,required:!0}},"icon"),eF=Dc()({name:"VComponentIcon",props:B1(),setup(e,t){let{slots:n}=t;return()=>{const r=e.icon;return sn(e.tag,null,{default:()=>{var i;return[e.icon?sn(r,null,null):(i=n.default)==null?void 0:i.call(n)]}})}}}),oj=Nv({name:"VSvgIcon",inheritAttrs:!1,props:B1(),setup(e,t){let{attrs:n}=t;return()=>sn(e.tag,Li(n,{style:null}),{default:()=>[sn("svg",{class:"v-icon__svg",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",role:"img","aria-hidden":"true"},[Array.isArray(e.icon)?e.icon.map(r=>Array.isArray(r)?sn("path",{d:r[0],"fill-opacity":r[1]},null):sn("path",{d:r},null)):sn("path",{d:e.icon},null)])]})}});B1();const aj=Nv({name:"VClassIcon",props:B1(),setup(e){return()=>sn(e.tag,{class:e.icon},null)}}),fge={svg:{component:oj},class:{component:aj}};function pge(e){return ql({defaultSet:"mdi",sets:{...fge,mdi:dge},aliases:{...hge,vuetify:["M8.2241 14.2009L12 21L22 3H14.4459L8.2241 14.2009Z",["M7.26303 12.4733L7.00113 12L2 3H12.5261C12.5261 3 12.5261 3 12.5261 3L7.26303 12.4733Z",.6]],"vuetify-outline":"svg:M7.26 12.47 12.53 3H2L7.26 12.47ZM14.45 3 8.22 14.2 12 21 22 3H14.45ZM18.6 5 12 16.88 10.51 14.2 15.62 5ZM7.26 8.35 5.4 5H9.13L7.26 8.35Z"}},e)}const mge=e=>{const t=dr(jC);if(!t)throw new Error("Missing Vuetify Icons provide!");return{iconData:yt(()=>{var m;const r=bt(e);if(!r)return{component:eF};let i=r;if(typeof i=="string"&&(i=i.trim(),i.startsWith("$")&&(i=(m=t.aliases)==null?void 0:m[i.slice(1)])),!i)throw new Error(`Could not find aliased icon "${r}"`);if(Array.isArray(i))return{component:oj,icon:i};
vendor: 4,289 bytes, line 1436
1436if(typeof i!="string")return{component:eF,icon:i};const s=Object.keys(t.sets).find(g=>typeof i=="string"&&i.startsWith(`${g}:`)),c=s?i.slice(s.length+1):i;return{component:t.sets[s??t.defaultSet].component,icon:c}})}},gge={badge:"Badge",close:"Close",dataIterator:{noResultsText:"No matching records found",loadingText:"Loading items..."},dataTable:{itemsPerPageText:"Rows per page:",ariaLabel:{sortDescending:"Sorted descending.",sortAscending:"Sorted ascending.",sortNone:"Not sorted.",activateNone:"Activate to remove sorting.",activateDescending:"Activate to sort descending.",activateAscending:"Activate to sort ascending."},sortBy:"Sort by"},dataFooter:{itemsPerPageText:"Items per page:",itemsPerPageAll:"All",nextPage:"Next page",prevPage:"Previous page",firstPage:"First page",lastPage:"Last page",pageText:"{0}-{1} of {2}"},dateRangeInput:{divider:"to"},datePicker:{ok:"OK",cancel:"Cancel",range:{title:"Select dates",header:"Enter dates"},title:"Select date",header:"Enter date",input:{placeholder:"Enter date"}},noDataText:"No data available",carousel:{prev:"Previous visual",next:"Next visual",ariaLabel:{delimiter:"Carousel slide {0} of {1}"}},calendar:{moreEvents:"{0} more"},input:{clear:"Clear {0}",prependAction:"{0} prepended action",appendAction:"{0} appended action",otp:"Please enter OTP character {0}"},fileInput:{counter:"{0} files",counterSize:"{0} files ({1} in total)"},timePicker:{am:"AM",pm:"PM"},pagination:{ariaLabel:{root:"Pagination Navigation",next:"Next page",previous:"Previous page",page:"Go to page {0}",currentPage:"Page {0}, Current page",first:"First page",last:"Last page"}},stepper:{next:"Next",prev:"Previous"},rating:{ariaLabel:{item:"Rating {0} of {1}"}},loading:"Loading...",infiniteScroll:{loadMore:"Load more",empty:"No more"}},yge={af:!1,ar:!0,bg:!1,ca:!1,ckb:!1,cs:!1,de:!1,el:!1,en:!1,es:!1,et:!1,fa:!0,fi:!1,fr:!1,hr:!1,hu:!1,he:!0,id:!1,it:!1,ja:!1,ko:!1,lv:!1,lt:!1,nl:!1,no:!1,pl:!1,pt:!1,ro:!1,ru:!1,sk:!1,sl:!1,srCyrl:!1,srLatn:!1,sv:!1,th:!1,tr:!1,az:!1,uk:!1,vi:!1,zhHans:!1,zhHant:!1};function $v(e,t,n){let r=arguments.length>3&&arguments[3]!==void 0?arguments[3]:T=>T,i=arguments.length>4&&arguments[4]!==void 0?arguments[4]:T=>T;const s=Ql("useProxiedModel"),c=jt(e[t]!==void 0?e[t]:n),a=fp(t),g=yt(a!==t?()=>{var T,C,A,P;return e[t],!!(((T=s.vnode.props)!=null&&T.hasOwnProperty(t)||(C=s.vnode.props)!=null&&C.hasOwnProperty(a))&&((A=s.vnode.props)!=null&&A.hasOwnProperty(`onUpdate:${t}`)||(P=s.vnode.props)!=null&&P.hasOwnProperty(`onUpdate:${a}`)))}:()=>{var T,C;return e[t],!!((T=s.vnode.props)!=null&&T.hasOwnProperty(t)&&((C=s.vnode.props)!=null&&C.hasOwnProperty(`onUpdate:${t}`)))});zv(()=>!g.value,()=>{Nn(()=>e[t],T=>{c.value=T})});const x=yt({get(){const T=e[t];return r(g.value?T:c.value)},set(T){const C=i(T),A=Ar(g.value?e[t]:c.value);A===C||r(A)===T||(c.value=C,s==null||s.emit(`update:${t}`,C))}});return Object.defineProperty(x,"externalValue",{get:()=>g.value?e[t]:c.value}),x}const tF="$vuetify.",nF=(e,t)=>e.replace(/\{(\d+)\}/g,(n,r)=>String(t[+r])),sj=(e,t,n)=>function(r){for(var i=arguments.length,s=new Array(i>1?i-1:0),c=1;c<i;c++)s[c-1]=arguments[c];if(!r.startsWith(tF))return nF(r,s);const a=r.replace(tF,""),m=e.value&&n.value[e.value],g=t.value&&n.value[t.value];let x=RC(m,a,null);return x||(`${r}${e.value}`,x=RC(g,a,null)),x||(x=r),typeof x!="string"&&(x=r),nF(x,s)};function lj(e,t){return(n,r)=>new Intl.NumberFormat([e.value,t.value],r).format(n)}function PE(e,t,n){const r=$v(e,t,e[t]??n.value);return r.value=e[t]??n.value,Nn(n,i=>{e[t]==null&&(r.value=n.value)}),r}function cj(e){return t=>{const n=PE(t,"locale",e.current),r=PE(t,"fallback",e.fallback),i=PE(t,"messages",e.messages);return{name:"vuetify",current:n,fallback:r,messages:i,t:sj(n,r,i),n:lj(n,r),provide:cj({current:n,fallback:r,messages:i})}}}function _ge(e){const t=ua((e==null?void 0:e.locale)??"en"),n=ua((e==null?void 0:e.fallback)??"en"),r=jt({en:gge,...e==null?void 0:e.messages});return{name:"vuetify",current:t,fallback:n,messages:r,t:sj(t,n,r),n:lj(t,n),provide:cj({current:t,fallback:n,messages:r})}}const Rx=Symbol.for("vuetify:locale");function vge(e){return e.name!=null}function bge(e){const t=e!=null&&e.adapter&&vge(e==null?void 0:e.adapter)?e==null?void 0:e.adapter:_ge(e),n=xge(t,e);return{...t,...n}}
1436function uj(){const e=dr(Rx);if(!e)throw new Error("[Vuetify] Could not find injected locale instance");return e}function xge(e,t){const n=jt((t==null?void 0:t.rtl)??yge),r=yt(()=>n.value[e.current.value]??!1);return{isRtl:r,rtl:n,rtlClasses:yt(()=>`v-locale--is-${r.value?"rtl":"ltr"}`)}}function z1(){const e=dr(Rx);if(!e)throw new Error("[Vuetify] Could not find injected rtl instance");return{isRtl:e.isRtl,rtlClasses:e.rtlClasses}}const bm=2.4,rF=.2126729,iF=.7151522,oF=.072175,wge=.55,Tge=.58,Ege=.57,Sge=.62,gb=.03,aF=1.45,Cge=5e-4,kge=1.25,Age=1.25,sF=.078,lF=12.82051282051282,yb=.06,cF=.001;function uF(e,t){const n=(e.r/255)**bm,r=(e.g/255)**bm,i=(e.b/255)**bm,s=(t.r/255)**bm,c=(t.g/255)**bm,a=(t.b/255)**bm;let m=n*rF+r*iF+i*oF,g=s*rF+c*iF+a*oF;if(m<=gb&&(m+=(gb-m)**aF),g<=gb&&(g+=(gb-g)**aF),Math.abs(g-m)<Cge)return 0;let x;if(g>m){const T=(g**wge-m**Tge)*kge;x=T<cF?0:T<sF?T-T*lF*yb:T-yb}else{const T=(g**Sge-m**Ege)*Age;x=T>-cF?0:T>-sF?T-T*lF*yb:T+yb}return x*100}const cv=Symbol.for("vuetify:theme"),Mg=qi({theme:String},"theme"),Jy={defaultTheme:"light",variations:{colors:[],lighten:0,darken:0},themes:{light:{dark:!1,colors:{background:"#FFFFFF",surface:"#FFFFFF","surface-variant":"#424242","on-surface-variant":"#EEEEEE",primary:"#6200EE","primary-darken-1":"#3700B3",secondary:"#03DAC6","secondary-darken-1":"#018786",error:"#B00020",info:"#2196F3",success:"#4CAF50",warning:"#FB8C00"},variables:{"border-color":"#000000","border-opacity":.12,"high-emphasis-opacity":.87,"medium-emphasis-opacity":.6,"disabled-opacity":.38,"idle-opacity":.04,"hover-opacity":.04,"focus-opacity":.12,"selected-opacity":.08,"activated-opacity":.12,"pressed-opacity":.12,"dragged-opacity":.08,"theme-kbd":"#212529","theme-on-kbd":"#FFFFFF","theme-code":"#F5F5F5","theme-on-code":"#000000"}},dark:{dark:!0,colors:{background:"#121212",surface:"#212121","surface-variant":"#BDBDBD","on-surface-variant":"#424242",primary:"#BB86FC","primary-darken-1":"#3700B3",secondary:"#03DAC5","secondary-darken-1":"#03DAC5",error:"#CF6679",info:"#2196F3",success:"#4CAF50",warning:"#FB8C00"},variables:{"border-color":"#FFFFFF","border-opacity":.12,"high-emphasis-opacity":1,"medium-emphasis-opacity":.7,"disabled-opacity":.5,"idle-opacity":.1,"hover-opacity":.04,"focus-opacity":.12,"selected-opacity":.08,"activated-opacity":.12,"pressed-opacity":.16,"dragged-opacity":.08,"theme-kbd":"#212529","theme-on-kbd":"#FFFFFF","theme-code":"#343434","theme-on-code":"#CCCCCC"}}}};function Pge(){var n,r;let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:Jy;if(!e)return{...Jy,isDisabled:!0};const t={};for(const[i,s]of Object.entries(e.themes??{})){const c=s.dark||i==="dark"?(n=Jy.themes)==null?void 0:n.dark:(r=Jy.themes)==null?void 0:r.light;t[i]=ql(c,s)}return ql(Jy,{...e,themes:t})}function Mge(e){const t=Pge(e),n=jt(t.defaultTheme),r=jt(t.themes),i=yt(()=>{const x={};for(const[T,C]of Object.entries(r.value)){const A=x[T]={...C,colors:{...C.colors}};if(t.variations)for(const P of t.variations.colors){const D=A.colors[P];if(D)for(const B of["lighten","darken"]){const R=B==="lighten"?Qme:Jme;for(const N of q$(t.variations[B],1))A.colors[`${P}-${B}-${N}`]=Zme(R(Qf(D),N))}}for(const P of Object.keys(A.colors)){if(/^on-[a-z]/.test(P)||A.colors[`on-${P}`])continue;const D=`on-${P}`,B=Qf(A.colors[P]),R=Math.abs(uF(Qf(0),B)),N=Math.abs(uF(Qf(16777215),B));A.colors[D]=N>Math.min(R,50)?"#fff":"#000"}}return x}),s=yt(()=>i.value[n.value]),c=yt(()=>{const x=[];s.value.dark&&zf(x,":root",["color-scheme: dark"]),zf(x,":root",hF(s.value));for(const[P,D]of Object.entries(i.value))zf(x,`.v-theme--${P}`,[`color-scheme: ${D.dark?"dark":"normal"}`,...hF(D)]);const T=[],C=[],A=new Set(Object.values(i.value).flatMap(P=>Object.keys(P.colors)));for(const P of A)/^on-[a-z]/.test(P)?zf(C,`.${P}`,[`color: rgb(var(--v-theme-${P})) !important`]):(zf(T,`.bg-${P}`,[`--v-theme-overlay-multiplier: var(--v-theme-${P}-overlay-multiplier)`,`background-color: rgb(var(--v-theme-${P})) !important`,`color: rgb(var(--v-theme-on-${P})) !important`]),zf(C,`.text-${P}`,[`color: rgb(var(--v-theme-${P})) !important`]),zf(C,`.border-${P}`,[`--v-border-color: var(--v-theme-${P})`]));return x.push(...T,...C),x.map((P,D)=>D===0?P:`    ${P}`).join("")});function a(){return{style:[{children:c.value,id:"vuetify-theme-stylesheet",nonce:t.cspNonce||!1}]}}function m(x){if(t.isDisabled)return;const T=x._context.provides.usehead;if(T)if(T.push){const C=T.push(a);Ro&&Nn(c,()=>{C.patch(a)})}else Ro?(T.addHeadObjs(yt(a)),sh(()=>T.updateDOM())):T.addHeadObjs(a());else{let A=function(){if(typeof document<"u"&&!C){const P=document.createElement("style");P.type="text/css",P.id="vuetify-theme-stylesheet",t.cspNonce&&P.setAttribute("nonce",t.cspNonce),C=P,document.head.appendChild(C)}C&&(C.innerHTML=c.value)},C=Ro?document.getElementById("vuetify-theme-stylesheet"):null;Ro?Nn(c,A,{immediate:!0}):A()}}const g=yt(()=>t.isDisabled?void 0:`v-theme--${n.value}`);return{install:m,isDisabled:t.isDisabled,name:n,themes:r,current:s,computedThemes:i,themeClasses:g,styles:c,global:{name:n,current:s}}}function jv(e){Ql("provideTheme");const t=dr(cv,null);if(!t)throw new Error("Could not find Vuetify theme injection");const n=yt(()=>e.theme??(t==null?void 0:t.name.value)),r=yt(()=>t.isDisabled?void 0:`v-theme--${n.value}`),i={...t,name:n,themeClasses:r};return ea(cv,i),i}function H_e(){Ql("useTheme");const e=dr(cv,null);if(!e)throw new Error("Could not find Vuetify theme injection");return e}function zf(e,t,n){e.push(`${t} {
1437`,...n.map(r=>`  ${r};
1438`),`}
1439`)}function hF(e){const t=e.dark?2:1,n=e.dark?1:2,r=[];for(const[i,s]of Object.entries(e.colors)){const c=Qf(s);
1439r.push(`--v-theme-${i}: ${c.r},${c.g},${c.b}`),i.startsWith("on-")||r.push(`--v-theme-${i}-overlay-multiplier: ${ege(s)>.18?t:n}`)}for(const[i,s]of Object.entries(e.variables)){const c=typeof s=="string"&&s.startsWith("#")?Qf(s):void 0,a=c?`${c.r}, ${c.g}, ${c.b}`:void 0;r.push(`--v-${i}: ${a??s}`)}return r}const UC={"001":1,AD:1,AE:6,AF:6,AG:0,AI:1,AL:1,AM:1,AN:1,AR:1,AS:0,AT:1,AU:1,AX:1,AZ:1,BA:1,BD:0,BE:1,BG:1,BH:6,BM:1,BN:1,BR:0,BS:0,BT:0,BW:0,BY:1,BZ:0,CA:0,CH:1,CL:1,CM:1,CN:1,CO:0,CR:1,CY:1,CZ:1,DE:1,DJ:6,DK:1,DM:0,DO:0,DZ:6,EC:1,EE:1,EG:6,ES:1,ET:0,FI:1,FJ:1,FO:1,FR:1,GB:1,"GB-alt-variant":0,GE:1,GF:1,GP:1,GR:1,GT:0,GU:0,HK:0,HN:0,HR:1,HU:1,ID:0,IE:1,IL:0,IN:0,IQ:6,IR:6,IS:1,IT:1,JM:0,JO:6,JP:0,KE:0,KG:1,KH:0,KR:0,KW:6,KZ:1,LA:0,LB:1,LI:1,LK:1,LT:1,LU:1,LV:1,LY:6,MC:1,MD:1,ME:1,MH:0,MK:1,MM:0,MN:1,MO:0,MQ:1,MT:0,MV:5,MX:0,MY:1,MZ:0,NI:0,NL:1,NO:1,NP:0,NZ:1,OM:6,PA:0,PE:0,PH:0,PK:0,PL:1,PR:0,PT:0,PY:0,QA:6,RE:1,RO:1,RS:1,RU:1,SA:0,SD:6,SE:1,SG:0,SI:1,SK:1,SM:1,SV:0,SY:6,TH:0,TJ:1,TM:1,TR:1,TT:0,TW:0,UA:1,UM:0,US:0,UY:1,UZ:1,VA:1,VE:0,VI:0,VN:1,WS:0,XK:1,YE:0,ZA:0,ZW:0};function Ige(e,t){const n=[];let r=[];const i=hj(e),s=dj(e),c=i.getDay()-UC[t.slice(-2).toUpperCase()],a=s.getDay()-UC[t.slice(-2).toUpperCase()];for(let m=0;m<c;m++){const g=new Date(i);g.setDate(g.getDate()-(c-m)),r.push(g)}for(let m=1;m<=s.getDate();m++){const g=new Date(e.getFullYear(),e.getMonth(),m);r.push(g),r.length===7&&(n.push(r),r=[])}for(let m=1;m<7-a;m++){const g=new Date(s);g.setDate(g.getDate()+m),r.push(g)}return n.push(r),n}function hj(e){return new Date(e.getFullYear(),e.getMonth(),1)}function dj(e){return new Date(e.getFullYear(),e.getMonth()+1,0)}function Oge(e){const t=e.split("-").map(Number);return new Date(t[0],t[1]-1,t[2])}const Dge=/([12]\d{3}-([1-9]|0[1-9]|1[0-2])-([1-9]|0[1-9]|[12]\d|3[01]))/;function Lge(e){if(e==null)return new Date;if(e instanceof Date)return e;if(typeof e=="string"){let t;if(Dge.test(e))return Oge(e);if(t=Date.parse(e),!isNaN(t))return new Date(t)}return null}const dF=new Date(2e3,0,2);function Rge(e){const t=UC[e.slice(-2).toUpperCase()];return q$(7).map(n=>{const r=new Date(dF);return r.setDate(dF.getDate()+t+n),new Intl.DateTimeFormat(e,{weekday:"narrow"}).format(r)})}function Fge(e,t,n){const r=new Date(e);let i={};switch(t){case"fullDateWithWeekday":i={weekday:"long",day:"numeric",month:"long",year:"numeric"};break;case"normalDateWithWeekday":i={weekday:"short",day:"numeric",month:"short"};break;case"keyboardDate":i={};break;case"monthAndDate":i={month:"long",day:"numeric"};break;case"monthAndYear":i={month:"long",year:"numeric"};break;case"dayOfMonth":i={day:"numeric"};break;default:i={timeZone:"UTC",timeZoneName:"short"}}return new Intl.DateTimeFormat(n,i).format(r)}function Bge(e,t){const n=new Date(e);return n.setDate(n.getDate()+t),n}function zge(e,t){const n=new Date(e);return n.setMonth(n.getMonth()+t),n}function Nge(e){return e.getFullYear()}function $ge(e){return e.getMonth()}function jge(e){return new Date(e.getFullYear(),0,1)}function Uge(e){return new Date(e.getFullYear(),11,31)}function Vge(e,t){return VC(e,t[0])&&qge(e,t[1])}function Gge(e){const t=new Date(e);return t instanceof Date&&!isNaN(t.getTime())}function VC(e,t){return e.getTime()>t.getTime()}function qge(e,t){return e.getTime()<t.getTime()}function fF(e,t){return e.getTime()===t.getTime()}function Wge(e,t){return e.getDate()===t.getDate()&&e.getMonth()===t.getMonth()&&e.getFullYear()===t.getFullYear()}function Hge(e,t){return e.getMonth()===t.getMonth()&&e.getFullYear()===t.getFullYear()}function Yge(e,t,n){const r=new Date(e),i=new Date(t);return n==="month"?r.getMonth()-i.getMonth()+(r.getFullYear()-i.getFullYear())*12:Math.floor((r.getTime()-i.getTime())/(1e3*60*60*24))}function Zge(e,t){const n=new Date(e);return n.setFullYear(t),n}class Xge{constructor(t){this.locale=t.locale}date(t){return Lge(t)}toJsDate(t){return t}addDays(t,n){return Bge(t,n)}addMonths(t,n){return zge(t,n)}getWeekArray(t){return Ige(t,this.locale)}startOfMonth(t){return hj(t)}endOfMonth(t){return dj(t)}format(t,n){return Fge(t,n,this.locale)}isEqual(t,n){return fF(t,n)}isValid(t){return Gge(t)}isWithinRange(t,n){return Vge(t,n)}isAfter(t,n){return VC(t,n)}isBefore(t,n){return!VC(t,n)&&!fF(t,n)}isSameDay(t,n){return Wge(t,n)}isSameMonth(t,n){return Hge(t,n)}setYear(t,n){return Zge(t,n)}getDiff(t,n,r){return Yge(t,n,r)}getWeekdays(){return Rge(this.locale)}getYear(t){return Nge(t)}getMonth(t){return $ge(t)}startOfYear(t){return jge(t)}endOfYear(t){return Uge(t)}}const pF=Symbol.for("vuetify:date-adapter");function Kge(e){return ql({adapter:Xge,locale:{af:"af-ZA",bg:"bg-BG",ca:"ca-ES",ckb:"",cs:"",de:"de-DE",el:"el-GR",en:"en-US",et:"et-EE",fa:"fa-IR",fi:"fi-FI",hr:"hr-HR",hu:"hu-HU",he:"he-IL",id:"id-ID",it:"it-IT",ja:"ja-JP",ko:"ko-KR",lv:"lv-LV",lt:"lt-LT",nl:"nl-NL",no:"nn-NO",pl:"pl-PL",pt:"pt-PT",ro:"ro-RO",ru:"ru-RU",sk:"sk-SK",sl:"sl-SI",srCyrl:"sr-SP",srLatn:"sr-SP",sv:"sv-SE",th:"th-TH",tr:"tr-TR",az:"az-AZ",uk:"uk-UA",vi:"vi-VN",zhHans:"zh-CN",zhHant:"zh-TW"}},e)}function Qge(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"content";const n=jt(),r=jt();if(Ro){const i=new ResizeObserver(s=>{e==null||e(s,i),s.length&&(t==="content"?r.value=s[0].contentRect:r.value=s[0].target.getBoundingClientRect())});xp(()=>{i.disconnect()}),Nn(n,(s,c)=>{c&&(i.unobserve(FC(c)),r.value=void 0),s&&i.observe(FC(s))},{flush:"post"})}return{resizeRef:n,contentRect:bv(r)}}function fj(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};const{blueprint:t,...n}=e,r=ql(t,n),{aliases:i={},components:s={},directives:c={}}=r,a=oge(r.defaults),m=cge(r.display,r.ssr),g=Mge(r.theme),x=pge(r.icons),T=bge(r.locale),C=Kge(r.date);return{install:P=>
1439{for(const D in c)P.directive(D,c[D]);for(const D in s)P.component(D,s[D]);for(const D in i)P.component(D,Nv({...i[D],name:D,aliasName:i[D].name}));if(g.install(P),P.provide(lv,a),P.provide($C,m),P.provide(cv,g),P.provide(jC,x),P.provide(Rx,T),P.provide(pF,C),Ro&&r.ssr)if(P.$nuxt)P.$nuxt.hook("app:suspense:resolve",()=>{m.update()});else{const{mount:D}=P;P.mount=function(){const B=D(...arguments);return Qi(()=>m.update()),P.mount=D,B}}pA.reset(),P.mixin({computed:{$vuetify(){return so({defaults:xm.call(this,lv),display:xm.call(this,$C),theme:xm.call(this,cv),icons:xm.call(this,jC),locale:xm.call(this,Rx),date:xm.call(this,pF)})}}})},defaults:a,display:m,theme:g,icons:x,locale:T,date:C}}const Jge="3.3.12";fj.version=Jge;function xm(e){var r,i;const t=this.$,n=((r=t.parent)==null?void 0:r.provides)??((i=t.vnode.appContext)==null?void 0:i.provides);if(n&&e in n)return n[e]}const eye=qi({text:String,clickable:Boolean,...Sp(),...Mg()},"VLabel"),tye=Dc()({name:"VLabel",props:eye(),setup(e,t){let{slots:n}=t;return jd(()=>{var r;return sn("label",{class:["v-label",{"v-label--clickable":e.clickable},e.class],style:e.style},[e.text,(r=n.default)==null?void 0:r.call(n)])}),{}}}),nye=qi({floating:Boolean,...Sp()},"VFieldLabel"),_b=Dc()({name:"VFieldLabel",props:nye(),setup(e,t){let{slots:n}=t;return jd(()=>sn(tye,{class:["v-field-label",{"v-field-label--floating":e.floating},e.class],style:e.style,"aria-hidden":e.floating||void 0},n)),{}}}),rye=qi({disabled:Boolean,group:Boolean,hideOnLeave:Boolean,leaveAbsolute:Boolean,mode:String,origin:String},"transition");function _l(e,t,n){return Dc()({name:e,props:rye({mode:n,origin:t}),setup(r,i){let{slots:s}=i;const c={onBeforeEnter(a){r.origin&&(a.style.transformOrigin=r.origin)},onLeave(a){if(r.leaveAbsolute){const{offsetTop:m,offsetLeft:g,offsetWidth:x,offsetHeight:T}=a;a._transitionInitialStyles={position:a.style.position,top:a.style.top,left:a.style.left,width:a.style.width,height:a.style.height},a.style.position="absolute",a.style.top=`${m}px`,a.style.left=`${g}px`,a.style.width=`${x}px`,a.style.height=`${T}px`}r.hideOnLeave&&a.style.setProperty("display","none","important")},onAfterLeave(a){if(r.leaveAbsolute&&(a!=null&&a._transitionInitialStyles)){const{position:m,top:g,left:x,width:T,height:C}=a._transitionInitialStyles;delete a._transitionInitialStyles,a.style.position=m||"",a.style.top=g||"",a.style.left=x||"",a.style.width=T||"",a.style.height=C||""}}};return()=>{const a=r.group?MG:bs;return ao(a,{name:r.disabled?"":e,css:!r.disabled,...r.group?void 0:{mode:r.mode},...r.disabled?{}:c},s.default)}}})}function pj(e,t){let n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:"in-out";return Dc()({name:e,props:{mode:{type:String,default:n},disabled:Boolean},setup(r,i){let{slots:s}=i;return()=>ao(bs,{name:r.disabled?"":e,css:!r.disabled,...r.disabled?{}:t},s.default)}})}function mj(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:"";const n=(arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1)?"width":"height",r=Pc(`offset-${n}`);return{onBeforeEnter(c){c._parent=c.parentNode,c._initialStyle={transition:c.style.transition,overflow:c.style.overflow,[n]:c.style[n]}},onEnter(c){const a=c._initialStyle;c.style.setProperty("transition","none","important"),c.style.overflow="hidden";const m=`${c[r]}px`;c.style[n]="0",c.offsetHeight,c.style.transition=a.transition,e&&c._parent&&c._parent.classList.add(e),requestAnimationFrame(()=>{c.style[n]=m})},onAfterEnter:s,onEnterCancelled:s,onLeave(c){c._initialStyle={transition:"",overflow:c.style.overflow,[n]:c.style[n]},c.style.overflow="hidden",c.style[n]=`${c[r]}px`,c.offsetHeight,requestAnimationFrame(()=>c.style[n]="0")},onAfterLeave:i,onLeaveCancelled:i};function i(c){e&&c._parent&&c._parent.classList.remove(e),s(c)}function s(c){const a=c._initialStyle[n];c.style.overflow=c._initialStyle.overflow,a!=null&&(c.style[n]=a),delete c._initialStyle}}_l("fab-transition","center center","out-in");_l("dialog-bottom-transition");_l("dialog-top-transition");const Y_e=_l("fade-transition"),Z_e=_l("scale-transition");_l("scroll-x-transition");_l("scroll-x-reverse-transition");_l("scroll-y-transition");_l("scroll-y-reverse-transition");_l("slide-x-transition");_l("slide-x-reverse-transition");const X_e=_l("slide-y-transition");_l("slide-y-reverse-transition");const K_e=pj("expand-transition",mj()),iye=pj("expand-x-transition",mj("",!0));function gj(e){return hA(()=>{const t=[],n={};return e.value.background&&(HR(e.value.background)?n.backgroundColor=e.value.background:t.push(`bg-${e.value.background}`)),e.value.text&&(HR(e.value.text)?(n.color=e.value.text,n.caretColor=e.value.text):t.push(`text-${e.value.text}`)),{colorClasses:t,colorStyles:n}})}function uv(e,t){const n=yt(()=>({text:Ai(e)?e.value:t?e[t]:null})),{colorClasses:r,colorStyles:i}=gj(n);return{textColorClasses:r,textColorStyles:i}}function Fx(e,t){const n=yt(()=>({background:Ai(e)?e.value:t?e[t]:null})),{colorClasses:r,colorStyles:i}=gj(n);return{backgroundColorClasses:r,backgroundColorStyles:i}}const oye=["x-small","small","default","large","x-large"],yj=qi({size:{type:[String,Number],default:"default"}},"size");function _j(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:F1();return hA(()=>{let n,r;return Ox(oye,e.size)?n=`${t}--size-${e.size}`:e.size&&(r={width:si(e.size),height:si(e.size)}),{sizeClasses:n,sizeStyles:r}})}const yA=qi({tag:{type:String,default:"div"}},"tag"),aye=qi({color:String,start:Boolean,end:Boolean,icon:A_,...Sp(),...yj(),...yA({tag:"i"}),...Mg()},"VIcon"),sye=Dc()({name:"VIcon",props:aye(),setup(e,t){let{attrs:n,slots:r}=t;const i=jt(),{themeClasses:s}=jv(e),{iconData:c}=mge(yt(()=>i.value||e.icon)),{sizeClasses:a}=_j(e),{textColorClasses:m,textColorStyles:g}=uv(Us(e,"color"));return jd(()=>{var T,C;const x=(T=r.default)==null?void 0:T.call(r);return x&&(i.value=(C=W$(x).filter(A=>A.type===Td&&A.children&&typeof A.children=="string")[0])==null?void 0:C.children),sn(c.value.component,{tag:e.tag,icon:c.value.icon,class:["v-icon","notranslate",s.value,a.value,m.value,{"v-icon--clickable":!!n.onClick,"v-icon--start":e.start,"v-icon--end":e.end},e.class],style:[a.value?void 0:{fontSize:si(e.size),height:si(e.size),width:si(e.size)},g.value,e.style],role:n.onClick?"button":void 0,"aria-hidden":!n.onClick},{default:()=>[x]})}),{}}});function lye(e){const{t}=uj();function n(r){let{name:i}=r;
1439const s={prepend:"prependAction",prependInner:"prependAction",append:"appendAction",appendInner:"appendAction",clear:"clear"}[i],c=e[`onClick:${i}`],a=c&&s?t(`$vuetify.input.${s}`,e.label??""):void 0;return sn(sye,{icon:e[`${i}Icon`],"aria-label":a,onClick:c},null)}return{InputIcon:n}}const vj=qi({focused:Boolean,"onUpdate:focused":Nb()},"focus");function bj(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:F1();const n=$v(e,"focused"),r=yt(()=>({[`${t}--focused`]:n.value}));function i(){n.value=!0}function s(){n.value=!1}return{focusClasses:r,isFocused:n,focus:i,blur:s}}function xj(e,t){const n=jt(),r=ua(!1);if(Sme){const i=new IntersectionObserver(s=>{e==null||e(s,i),r.value=!!s.find(c=>c.isIntersecting)},t);xp(()=>{i.disconnect()}),Nn(n,(s,c)=>{c&&(i.unobserve(c),r.value=!1),s&&i.observe(s)},{flush:"post"})}return{intersectionRef:n,isIntersecting:r}}const mF={center:"center",top:"bottom",bottom:"top",left:"right",right:"left"},cye=qi({location:String},"location");function uye(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1,n=arguments.length>2?arguments[2]:void 0;const{isRtl:r}=z1();return{locationStyles:yt(()=>{if(!e.location)return{};const{side:s,align:c}=NC(e.location.split(" ").length>1?e.location:`${e.location} center`,r.value);function a(g){return n?n(g):0}const m={};return s!=="center"&&(t?m[mF[s]]=`calc(100% - ${a(s)}px)`:m[s]=0),c!=="center"?t?m[mF[c]]=`calc(100% - ${a(c)}px)`:m[c]=0:(s==="center"?m.top=m.left="50%":m[{top:"left",bottom:"left",left:"top",right:"top"}[s]]="50%",m.transform={top:"translateX(-50%)",bottom:"translateX(-50%)",left:"translateY(-50%)",right:"translateY(-50%)",center:"translate(-50%, -50%)"}[s]),m})}}const wj=qi({rounded:{type:[Boolean,Number,String],default:void 0}},"rounded");function Tj(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:F1();
vendor: 4,568 bytes, line 1439
1439return{roundedClasses:yt(()=>{const r=Ai(e)?e.value:e.rounded,i=[];if(r===!0||r==="")i.push(`${t}--rounded`);else if(typeof r=="string"||r===0)for(const s of String(r).split(" "))i.push(`rounded-${s}`);return i})}}const hye=qi({absolute:Boolean,active:{type:Boolean,default:!0},bgColor:String,bgOpacity:[Number,String],bufferValue:{type:[Number,String],default:0},clickable:Boolean,color:String,height:{type:[Number,String],default:4},indeterminate:Boolean,max:{type:[Number,String],default:100},modelValue:{type:[Number,String],default:0},reverse:Boolean,stream:Boolean,striped:Boolean,roundedBar:Boolean,...Sp(),...cye({location:"top"}),...wj(),...yA(),...Mg()},"VProgressLinear"),dye=Dc()({name:"VProgressLinear",props:hye(),emits:{"update:modelValue":e=>!0},setup(e,t){let{slots:n}=t;const r=$v(e,"modelValue"),{isRtl:i,rtlClasses:s}=z1(),{themeClasses:c}=jv(e),{locationStyles:a}=uye(e),{textColorClasses:m,textColorStyles:g}=uv(e,"color"),{backgroundColorClasses:x,backgroundColorStyles:T}=Fx(yt(()=>e.bgColor||e.color)),{backgroundColorClasses:C,backgroundColorStyles:A}=Fx(e,"color"),{roundedClasses:P}=Tj(e),{intersectionRef:D,isIntersecting:B}=xj(),R=yt(()=>parseInt(e.max,10)),N=yt(()=>parseInt(e.height,10)),j=yt(()=>parseFloat(e.bufferValue)/R.value*100),U=yt(()=>parseFloat(r.value)/R.value*100),W=yt(()=>i.value!==e.reverse),Q=yt(()=>e.indeterminate?"fade-transition":"slide-x-transition"),Z=yt(()=>e.bgOpacity==null?e.bgOpacity:parseFloat(e.bgOpacity));function K(Y){if(!D.value)return;const{left:me,right:ge,width:ce}=D.value.getBoundingClientRect(),fe=W.value?ce-Y.clientX+(ge-ce):Y.clientX-me;r.value=Math.round(fe/ce*R.value)}return jd(()=>sn(e.tag,{ref:D,class:["v-progress-linear",{"v-progress-linear--absolute":e.absolute,"v-progress-linear--active":e.active&&B.value,"v-progress-linear--reverse":W.value,"v-progress-linear--rounded":e.rounded,"v-progress-linear--rounded-bar":e.roundedBar,"v-progress-linear--striped":e.striped},P.value,c.value,s.value,e.class],style:[{bottom:e.location==="bottom"?0:void 0,top:e.location==="top"?0:void 0,height:e.active?si(N.value):0,"--v-progress-linear-height":si(N.value),...a.value},e.style],role:"progressbar","aria-hidden":e.active?"false":"true","aria-valuemin":"0","aria-valuemax":e.max,"aria-valuenow":e.indeterminate?void 0:U.value,onClick:e.clickable&&K},{default:()=>[e.stream&&sn("div",{key:"stream",class:["v-progress-linear__stream",m.value],style:{...g.value,[W.value?"left":"right"]:si(-N.value),borderTop:`${si(N.value/2)} dotted`,opacity:Z.value,top:`calc(50% - ${si(N.value/4)})`,width:si(100-j.value,"%"),"--v-progress-linear-stream-to":si(N.value*(W.value?1:-1))}},null),sn("div",{class:["v-progress-linear__background",x.value],style:[T.value,{opacity:Z.value,width:si(e.stream?j.value:100,"%")}]},null),sn(bs,{name:Q.value},{default:()=>[e.indeterminate?sn("div",{class:"v-progress-linear__indeterminate"},[["long","short"].map(Y=>sn("div",{key:Y,class:["v-progress-linear__indeterminate",Y,C.value],style:A.value},null))]):sn("div",{class:["v-progress-linear__determinate",C.value],style:[A.value,{width:si(U.value,"%")}]},null)]}),n.default&&sn("div",{class:"v-progress-linear__content"},[n.default({value:U.value,buffer:j.value})])]})),{}}}),fye=qi({loading:[Boolean,String]},"loader");function pye(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:F1();return{loaderClasses:yt(()=>({[`${t}--loading`]:e.loading}))}}function mye(e,t){var r;let{slots:n}=t;return sn("div",{class:`${e.name}__loader`},[((r=n.default)==null?void 0:r.call(n,{color:e.color,isActive:e.active}))||sn(dye,{active:e.active,color:e.color,height:"2",indeterminate:!0},null)])}const gye=["underlined","outlined","filled","solo","solo-inverted","solo-filled","plain"],Ej=qi({appendInnerIcon:A_,bgColor:String,clearable:Boolean,clearIcon:{type:A_,default:"$clear"},active:Boolean,centerAffix:{type:Boolean,default:void 0},color:String,baseColor:String,dirty:Boolean,disabled:{type:Boolean,default:null},error:Boolean,flat:Boolean,label:String,persistentClear:Boolean,prependInnerIcon:A_,reverse:Boolean,singleLine:Boolean,variant:{type:String,default:"filled",validator:e=>gye.includes(e)},"onClick:clear":Nb(),"onClick:appendInner":Nb(),"onClick:prependInner":Nb(),...Sp(),...fye(),...wj(),...Mg()},"VField"),Sj=Dc()({name:"VField",inheritAttrs:!1,props:{id:String,...vj(),...Ej()},emits:{"update:focused":e=>!0,"update:modelValue":e=>!0},setup(e,t){let{attrs:n,emit:r,slots:i}=t;const{themeClasses:s}=jv(e),{loaderClasses:c}=pye(e),{focusClasses:a,isFocused:m,focus:g,blur:x}=bj(e),{InputIcon:T}
1439=lye(e),{roundedClasses:C}=Tj(e),{rtlClasses:A}=z1(),P=yt(()=>e.dirty||e.active),D=yt(()=>!e.singleLine&&!!(e.label||i.label)),B=pA(),R=yt(()=>e.id||`input-${B}`),N=yt(()=>`${R.value}-messages`),j=jt(),U=jt(),W=jt(),Q=yt(()=>["plain","underlined"].includes(e.variant)),{backgroundColorClasses:Z,backgroundColorStyles:K}=Fx(Us(e,"bgColor")),{textColorClasses:Y,textColorStyles:me}=uv(yt(()=>e.error||e.disabled?void 0:P.value&&m.value?e.color:e.baseColor));Nn(P,fe=>{if(D.value){const ie=j.value.$el,xe=U.value.$el;requestAnimationFrame(()=>{const Te=Z$(ie),oe=xe.getBoundingClientRect(),ne=oe.x-Te.x,le=oe.y-Te.y-(Te.height/2-oe.height/2),se=oe.width/.75,Ne=Math.abs(se-Te.width)>1?{maxWidth:si(se)}:void 0,Se=getComputedStyle(ie),xt=getComputedStyle(xe),kt=parseFloat(Se.transitionDuration)*1e3||150,wt=parseFloat(xt.getPropertyValue("--v-field-label-scale")),Ue=xt.getPropertyValue("color");ie.style.visibility="visible",xe.style.visibility="hidden",X$(ie,{transform:`translate(${ne}px, ${le}px) scale(${wt})`,color:Ue,...Ne},{duration:kt,easing:nj,direction:fe?"normal":"reverse"}).finished.then(()=>{ie.style.removeProperty("visibility"),xe.style.removeProperty("visibility")})})}},{flush:"post"});const ge=yt(()=>({isActive:P,isFocused:m,controlRef:W,blur:x,focus:g}));function ce(fe){fe.target!==document.activeElement&&fe.preventDefault()}return jd(()=>{var ne,le,se;const fe=e.variant==="outlined",ie=i["prepend-inner"]||e.prependInnerIcon,xe=!!(e.clearable||i.clear),Te=!!(i["append-inner"]||e.appendInnerIcon||xe),oe=i.label?i.label({...ge.value,label:e.label,props:{for:R.value}}):e.label;return sn("div",Li({class:["v-field",{"v-field--active":P.value,"v-field--appended":Te,"v-field--center-affix":e.centerAffix??!Q.value,"v-field--disabled":e.disabled,"v-field--dirty":e.dirty,"v-field--error":e.error,"v-field--flat":e.flat,"v-field--has-background":!!e.bgColor,"v-field--persistent-clear":e.persistentClear,"v-field--prepended":ie,"v-field--reverse":e.reverse,"v-field--single-line":e.singleLine,"v-field--no-label":!oe,[`v-field--variant-${e.variant}`]:!0},s.value,Z.value,a.value,c.value,C.value,A.value,e.class],style:[K.value,me.value,e.style],onClick:ce},n),[sn("div",{class:"v-field__overlay"},null),sn(mye,{name:"v-field",active:!!e.loading,color:e.error?"error":typeof e.loading=="string"?e.loading:e.color},{default:i.loader}),ie&&sn("div",{key:"prepend",class:"v-field__prepend-inner"},[e.prependInnerIcon&&sn(T,{key:"prepend-icon",name:"prependInner"},null),(ne=i["prepend-inner"])==null?void 0:ne.call(i,ge.value)]),sn("div",{class:"v-field__field","data-no-activator":""},[["filled","solo","solo-inverted","solo-filled"].includes(e.variant)&&D.value&&sn(_b,{key:"floating-label",ref:U,class:[Y.value],floating:!0,for:R.value},{default:()=>[oe]}),sn(_b,{ref:j,for:R.value},{default:()=>[oe]}),(le=i.default)==null?void 0:le.call(i,{...ge.value,props:{id:R.value,class:"v-field__input","aria-describedby":N.value},focus:g,blur:x})]),xe&&sn(iye,{key:"clear"},{default:()=>[pd(sn("div",{class:"v-field__clearable",onMousedown:Ne=>{Ne.preventDefault(),Ne.stopPropagation()}},[i.clear?i.clear():sn(T,{name:"clear"},null)]),[[gd,e.dirty]])]}),Te&&sn("div",{key:"append",class:"v-field__append-inner"},[(se=i["append-inner"])==null?void 0:se.call(i,ge.value),e.appendInnerIcon&&sn(T,{key:"append-icon",name:"appendInner"},null)]),sn("div",{class:["v-field__outline",Y.value]},[fe&&sn(Hn,null,[sn("div",{class:"v-field__outline__start"},null),D.value&&sn("div",{class:"v-field__outline__notch"},[sn(_b,{ref:U,floating:!0,for:R.value},{default:()=>[oe]})]),sn("div",{class:"v-field__outline__end"},null)]),Q.value&&D.value&&sn(_b,{ref:U,floating:!0,for:R.value},{default:()=>[oe]})])])}),{controlRef:W}}});function Q_e(e){const t=Object.keys(Sj.props).filter(n=>!dA(n)&&n!=="class"&&n!=="style");return uA(e,t)}function ME(e,t){return{x:e.x+t.x,y:e.y+t.y}}function yye(e,t){return{x:e.x-t.x,y:e.y-t.y}}function gF(e,t){if(e.side==="top"||e.side==="bottom"){const{side:n,align:r}=e,i=r==="left"?0:r==="center"?t.width/2:r==="right"?t.width:r,s=n==="top"?0:n==="bottom"?t.height:n;return ME({x:i,y:s},t)}else if(e.side==="left"||e.side==="right"){const{side:n,align:r}=e,i=n==="left"?0:n==="right"?t.width:n,s=r==="top"?0:r==="center"?t.height/2:r==="bottom"?t.height:r;return ME({x:i,y:s},t)}return ME({x:t.width/2,y:t.height/2},t)}const Cj={static:bye,connected:wye},_ye=qi({locationStrategy:{type:[String,Function],default:"static",validator:e=>typeof e=="function"||e in Cj},location:{type:String,default:"bottom"},origin:{type:String,default:"auto"},offset:[Number,String,Array]},"VOverlay-location-strategies");function vye(e,t){const n=jt({}),r=jt();Ro&&(zv(()=>!!(t.isActive.value&&e.locationStrategy),s=>{var c,a;Nn(()=>e.locationStrategy,s),$s(()=>{r.value=void 0}),typeof e.locationStrategy=="function"?r.value=(c=e.locationStrategy(t,e,n))==null?void 0:c.updateLocation:r.value=(a=Cj[e.locationStrategy](t,e,n))==null?void 0:a.updateLocation}),window.addEventListener("resize",i,{passive:!0}),$s(()=>{window.removeEventListener("resize",i),r.value=void 0}));function i(s){var c;(c=r.value)==null||c.call(r,s)}return{contentStyles:n,updateLocation:r}}function bye(){}function xye(e,t){t?e.style.removeProperty("left"):e.style.removeProperty("right");const n=Z$(e);return t?n.x+=parseFloat(e.style.right||0):n.x-=parseFloat(e.style.left||0),n.y-=parseFloat(e.style.top||0),n}function wye(e,t,n){ige(e.activatorEl.value)&&Object.assign(n.value,{position:"fixed",top:0,[e.isRtl.value?"right":"left"]:0});const{preferredAnchor:i,preferredOrigin:s}=hA(()=>{const P=NC(t.location,e.isRtl.value),D=t.origin==="overlap"?P:t.origin==="auto"?kE(P):NC(t.origin,e.isRtl.value);return P.side===D.side&&P.align===AE(D).align?{preferredAnchor:GR(P),preferredOrigin:GR(D)}:{preferredAnchor:P,preferredOrigin:D}}),[c,a,m,g]=["minWidth","minHeight","maxWidth","maxHeight"].map(P=>yt(()=>{const D=parseFloat(t[P]);return isNaN(D)?1/0:D})),x=yt(()=>{if(Array.isArray(t.offset))return t.offset;if(typeof t.offset=="string"){const P=t.offset.split(" ").map(parseFloat);return P.length<2&&P.push(0),P}return typeof t.offset=="number"?[t.offset,0]:[0,0]});let T=!1;const C=new ResizeObserver(()=>{T&&A()});Nn([e.activatorEl,e.contentEl],(P,D)=>{let[B,R]=P,[N,j]=D;N&&C.unobserve(N),B&&C.observe(B),j&&C.unobserve(j),R&&C.observe(R)},{immediate:!0}),$s(()=>{C.disconnect()});function A(){if(T=!1,requestAnimationFrame(()=>{requestAnimationFrame(()=>T=!0)}),!e.activatorEl.value||!e.contentEl.value)return;const P=e.activatorEl.value.getBoundingClientRect(),D=xye(e.contentEl.value,e.isRtl.value),B=Lx(e.contentEl.value),R=12;B.length||(B.push(document.documentElement),e.contentEl.value.style.top&&e.contentEl.value.style.left||(D.x-=parseFloat(document.documentElement.style.getPropertyValue("--v-body-scroll-x")||0),D.y-=parseFloat(document.documentElement.style.getPropertyValue("--v-body-scroll-y")||0)));const N=B.reduce((ge,ce)=>{const fe=ce.getBoundingClientRect(),ie=new Ym({x:ce===document.documentElement?0:fe.x,y:ce===document.documentElement?0:fe.y,width:ce.clientWidth,height:ce.clientHeight});return ge?new Ym({x:Math.max(ge.left,ie.left),y:Math.max(ge.top,ie.top),width:Math.min(ge.right,ie.right)-Math.max(ge.left,ie.left),height:Math.min(ge.bottom,ie.bottom)-Math.max(ge.top,ie.top)}):ie},void 0);
vendor: 1,735 bytes, line 1439
1439N.x+=R,N.y+=R,N.width-=R*2,N.height-=R*2;let j={anchor:i.value,origin:s.value};function U(ge){const ce=new Ym(D),fe=gF(ge.anchor,P),ie=gF(ge.origin,ce);let{x:xe,y:Te}=yye(fe,ie);switch(ge.anchor.side){case"top":Te-=x.value[0];break;case"bottom":Te+=x.value[0];break;case"left":xe-=x.value[0];break;case"right":xe+=x.value[0];break}switch(ge.anchor.align){case"top":Te-=x.value[1];break;case"bottom":Te+=x.value[1];break;case"left":xe-=x.value[1];break;case"right":xe+=x.value[1];break}return ce.x+=xe,ce.y+=Te,ce.width=Math.min(ce.width,m.value),ce.height=Math.min(ce.height,g.value),{overflows:WR(ce,N),x:xe,y:Te}}let W=0,Q=0;const Z={x:0,y:0},K={x:!1,y:!1};let Y=-1;for(;!(Y++>10);){const{x:ge,y:ce,overflows:fe}=U(j);W+=ge,Q+=ce,D.x+=ge,D.y+=ce;{const ie=qR(j.anchor),xe=fe.x.before||fe.x.after,Te=fe.y.before||fe.y.after;let oe=!1;if(["x","y"].forEach(ne=>{if(ne==="x"&&xe&&!K.x||ne==="y"&&Te&&!K.y){const le={anchor:{...j.anchor},origin:{...j.origin}},se=ne==="x"?ie==="y"?AE:kE:ie==="y"?kE:AE;le.anchor=se(le.anchor),le.origin=se(le.origin);const{overflows:Ne}=U(le);(Ne[ne].before<=fe[ne].before&&Ne[ne].after<=fe[ne].after||Ne[ne].before+Ne[ne].after<(fe[ne].before+fe[ne].after)/2)&&(j=le,oe=K[ne]=!0)}}),oe)continue}fe.x.before&&(W+=fe.x.before,D.x+=fe.x.before),fe.x.after&&(W-=fe.x.after,D.x-=fe.x.after),fe.y.before&&(Q+=fe.y.before,D.y+=fe.y.before),fe.y.after&&(Q-=fe.y.after,D.y-=fe.y.after);{const ie=WR(D,N);Z.x=N.width-ie.x.before-ie.x.after,Z.y=N.height-ie.y.before-ie.y.after,W+=ie.x.before,D.x+=ie.x.before,Q+=ie.y.before,D.y+=ie.y.before}break}const me=qR(j.anchor);return Object.assign(n.value,{"--v-overlay-anchor-origin":`${j.anchor.side} ${j.anchor.align}`,transformOrigin:`${j.origin.side} ${j.origin.align}
1439`,top:si(IE(Q)),left:e.isRtl.value?void 0:si(IE(W)),right:e.isRtl.value?si(IE(-W)):void 0,minWidth:si(me==="y"?Math.min(c.value,P.width):c.value),maxWidth:si(yF(BC(Z.x,c.value===1/0?0:c.value,m.value))),maxHeight:si(yF(BC(Z.y,a.value===1/0?0:a.value,g.value)))}),{available:Z,contentBox:D}}return Nn(()=>[i.value,s.value,t.offset,t.minWidth,t.minHeight,t.maxWidth,t.maxHeight],()=>A()),Qi(()=>{const P=A();if(!P)return;const{available:D,contentBox:B}=P;B.height>D.y&&requestAnimationFrame(()=>{A(),requestAnimationFrame(()=>{A()})})}),{updateLocation:A}}function IE(e){return Math.round(e*devicePixelRatio)/devicePixelRatio}function yF(e){return Math.ceil(e*devicePixelRatio)/devicePixelRatio}let GC=!0;const Bx=[];function Tye(e){!GC||Bx.length?(Bx.push(e),qC()):(GC=!1,e(),qC())}let _F=-1;function qC(){cancelAnimationFrame(_F),_F=requestAnimationFrame(()=>{const e=Bx.shift();e&&e(),Bx.length?qC():GC=!0})}const Ub={none:null,close:Cye,block:kye,reposition:Aye},Eye=qi({scrollStrategy:{type:[String,Function],default:"block",validator:e=>typeof e=="function"||e in Ub}},"VOverlay-scroll-strategies");function Sye(e,t){if(!Ro)return;let n;sh(async()=>{n==null||n.stop(),t.isActive.value&&e.scrollStrategy&&(n=xg(),await Qi(),n.active&&n.run(()=>{var r;typeof e.scrollStrategy=="function"?e.scrollStrategy(t,e,n):(r=Ub[e.scrollStrategy])==null||r.call(Ub,t,e,n)}))}),$s(()=>{n==null||n.stop()})}function Cye(e){function t(n){e.isActive.value=!1}kj(e.activatorEl.value??e.contentEl.value,t)}function kye(e,t){var c;const n=(c=e.root.value)==null?void 0:c.offsetParent,r=[...new Set([...Lx(e.activatorEl.value,t.contained?n:void 0),...Lx(e.contentEl.value,t.contained?n:void 0)])].filter(a=>!a.classList.contains("v-overlay-scroll-blocked")),i=window.innerWidth-document.documentElement.offsetWidth,s=(a=>mA(a)&&a)(n||document.documentElement);s&&e.root.value.classList.add("v-overlay--scroll-blocked"),r.forEach((a,m)=>{a.style.setProperty("--v-body-scroll-x",si(-a.scrollLeft)),a.style.setProperty("--v-body-scroll-y",si(-a.scrollTop)),a!==document.documentElement&&a.style.setProperty("--v-scrollbar-offset",si(i)),a.classList.add("v-overlay-scroll-blocked")}),$s(()=>{r.forEach((a,m)=>{const g=parseFloat(a.style.getPropertyValue("--v-body-scroll-x")),x=parseFloat(a.style.getPropertyValue("--v-body-scroll-y"));a.style.removeProperty("--v-body-scroll-x"),a.style.removeProperty("--v-body-scroll-y"),a.style.removeProperty("--v-scrollbar-offset"),a.classList.remove("v-overlay-scroll-blocked"),a.scrollLeft=-g,a.scrollTop=-x}),s&&e.root.value.classList.remove("v-overlay--scroll-blocked")})}function Aye(e,t,n){let r=!1,i=-1,s=-1;function c(a){Tye(()=>{var x,T;const m=performance.now();(T=(x=e.updateLocation).value)==null||T.call(x,a),r=(performance.now()-m)/(1e3/60)>2})}s=(typeof requestIdleCallback>"u"?a=>a():requestIdleCallback)(()=>{n.run(()=>{kj(e.activatorEl.value??e.contentEl.value,a=>{r?(cancelAnimationFrame(i),i=requestAnimationFrame(()=>{i=requestAnimationFrame(()=>{c(a)})})):c(a)})})}),$s(()=>{typeof cancelIdleCallback<"u"&&cancelIdleCallback(s),cancelAnimationFrame(i)})}function kj(e,t){const n=[document,...Lx(e)];n.forEach(r=>{r.addEventListener("scroll",t,{passive:!0})}),$s(()=>{n.forEach(r=>{r.removeEventListener("scroll",t)})})}const Pye=Symbol.for("vuetify:v-menu"),Mye=qi({closeDelay:[Number,String],openDelay:[Number,String]},"delay");function Iye(e,t){const n={},r=i=>()=>{if(!Ro)return Promise.resolve(!0);const s=i==="openDelay";return n.closeDelay&&window.clearTimeout(n.closeDelay),delete n.closeDelay,n.openDelay&&window.clearTimeout(n.openDelay),delete n.openDelay,new Promise(c=>{const a=parseInt(e[i]??0,10);n[i]=window.setTimeout(()=>{t==null||t(s),c(s)},a)})};return{runCloseDelay:r("closeDelay"),runOpenDelay:r("openDelay")}}const Oye=qi({activator:[String,Object],activatorProps:{type:Object,default:()=>({})},openOnClick:{type:Boolean,default:void 0},openOnHover:Boolean,openOnFocus:{type:Boolean,default:void 0},closeOnContentClick:Boolean,...Mye()},"VOverlay-activator");function Dye(e,t){let{isActive:n,isTop:r}=t;const i=jt();let s=!1,c=!1,a=!0;const m=yt(()=>e.openOnFocus||e.openOnFocus==null&&e.openOnHover),g=yt(()=>e.openOnClick||e.openOnClick==null&&!e.openOnHover&&!m.value),{runOpenDelay:x,runCloseDelay:T}=Iye(e,j=>{j===(e.openOnHover&&s||m.value&&c)&&!(e.openOnHover&&n.value&&!r.value)&&(n.value!==j&&(a=!0),n.value=j)}),C={onClick:j=>{j.stopPropagation(),i.value=j.currentTarget||j.target,n.value=!n.value},onMouseenter:j=>{var U;(U=j.sourceCapabilities)!=null&&U.firesTouchEvents||(s=!0,i.value=j.currentTarget||j.target,x())},onMouseleave:j=>{s=!1,T()},onFocus:j=>{zme(j.target,":focus-visible")!==!1&&(c=!0,j.stopPropagation(),i.value=j.currentTarget||j.target,x())},onBlur:j=>{c=!1,j.stopPropagation(),T()}},A=yt(()=>{const j={};return g.value&&(j.onClick=C.onClick),e.openOnHover&&(j.onMouseenter=C.onMouseenter,j.onMouseleave=C.onMouseleave),m.value&&(j.onFocus=C.onFocus,j.onBlur=C.onBlur),j}),P=yt(()=>{const j={};if(e.openOnHover&&(j.onMouseenter=()=>{s=!0,x()},j.onMouseleave=()=>{s=!1,T()}),m.value&&(j.onFocusin=()=>{c=!0,x()},j.onFocusout=()=>{c=!1,T()}),e.closeOnContentClick){const U=dr(Pye,null);j.onClick=()=>{n.value=!1,U==null||U.closeParents()}}return j}),D=yt(()=>{const j={};return e.openOnHover&&(j.onMouseenter=()=>{a&&(s=!0,a=!1,x())},j.onMouseleave=()=>{s=!1,T()}),j});Nn(r,j=>{j&&(e.openOnHover&&!s&&(!m.value||!c)||m.value&&!c&&(!e.openOnHover||!s))&&(n.value=!1)});const B=jt();sh(()=>{B.value&&Qi(()=>{i.value=FC(B.value)})});const R=Ql("useActivator");let N;return Nn(()=>!!e.activator,j=>{j&&Ro?(N=xg(),N.run(()=>{Lye(e,R,{activatorEl:i,activatorEvents:A})})):N&&N.stop()},{flush:"post",immediate:!0}),$s(()=>{N==null||N.stop()}),{activatorEl:i,activatorRef:B,activatorEvents:A,contentEvents:P,scrimEvents:D}}function Lye(e,t,n){let{activatorEl:r,activatorEvents:i}=n;Nn(()=>e.activator,(m,g)=>{if(g&&m!==g){const x=a(g);x&&c(x)}m&&Qi(()=>s())},{immediate:!0}),Nn(()=>e.activatorProps,()=>{s()}),$s(()=>{c()});function s(){let m=arguments.length>0&&arguments[0]!==void 0?arguments[0]:a(),g=arguments.length>1&&arguments[1]!==void 0?arguments[1]:e.activatorProps;m&&$me(m,Li(i.value,g))}function c(){let m=arguments.length>0&&arguments[0]!==void 0?arguments[0]:a(),g=arguments.length>1&&arguments[1]!==void 0?arguments[1]:e.activatorProps;m&&jme(m,Li(i.value,g))}function a(){var x,T;let m=arguments.length>0&&arguments[0]!==void 0?arguments[0]:e.activator,g;if(m)if(m==="parent"){let C=(T=(x=t==null?void 0:t.proxy)==null?void 0:x.$el)==null?void 0:T.parentNode;for(;C.hasAttribute("data-no-activator");)C=C.parentNode;g=C}else typeof m=="string"?g=document.querySelector(m):"$el"in m?g=m.$el:g=m;return r.value=(g==null?void 0:g.nodeType)===Node.ELEMENT_NODE?g:null,r.value}}const Aj=qi({height:[Number,String],maxHeight:[Number,String],maxWidth:[Number,String],minHeight:[Number,String],minWidth:[Number,String],width:[Number,String]},"dimension");function Pj(e){return{dimensionStyles:yt(()=>
1439({height:si(e.height),maxHeight:si(e.maxHeight),maxWidth:si(e.maxWidth),minHeight:si(e.minHeight),minWidth:si(e.minWidth),width:si(e.width)}))}}function Rye(){if(!Ro)return ua(!1);const{ssr:e}=uge();if(e){const t=ua(!1);return Dr(()=>{t.value=!0}),t}else return ua(!0)}const Fye=qi({eager:Boolean},"lazy");function Bye(e,t){const n=ua(!1),r=yt(()=>n.value||e.eager||t.value);Nn(t,()=>n.value=!0);function i(){e.eager||(n.value=!1)}return{isBooted:n,hasContent:r,onAfterLeave:i}}function zye(){var e,t;return(t=(e=Ql("useRouter"))==null?void 0:e.proxy)==null?void 0:t.$router}function J_e(e,t){const n=Ev("RouterLink"),r=yt(()=>!!(e.href||e.to)),i=yt(()=>(r==null?void 0:r.value)||UR(t,"click")||UR(e,"click"));if(typeof n=="string")return{isLink:r,isClickable:i,href:Us(e,"href")};const s=e.to?n.useLink(e):void 0;return{isLink:r,isClickable:i,route:s==null?void 0:s.route,navigate:s==null?void 0:s.navigate,isActive:s&&yt(()=>{var c,a;return e.exact?(c=s.isExactActive)==null?void 0:c.value:(a=s.isActive)==null?void 0:a.value}),href:yt(()=>e.to?s==null?void 0:s.route.value.href:e.href)}}const eve=qi({href:String,replace:Boolean,to:[String,Object],exact:Boolean},"router");let OE=!1;function Nye(e,t){let n=!1,r,i;Ro&&(Qi(()=>{window.addEventListener("popstate",s),r=e==null?void 0:e.beforeEach((c,a,m)=>{OE?n?t(m):m():setTimeout(()=>n?t(m):m()),OE=!0}),i=e==null?void 0:e.afterEach(()=>{OE=!1})}),$s(()=>{window.removeEventListener("popstate",s),r==null||r(),i==null||i()}));function s(c){var a;(a=c.state)!=null&&a.replaced||(n=!0,setTimeout(()=>n=!1))}}function $ye(){const t=Ql("useScopeId").vnode.scopeId;return{scopeId:t?{[t]:""}:void 0}}const vF=Symbol.for("vuetify:stack"),e_=so([]);function jye(e,t,n){const r=Ql("useStack"),i=!n,s=dr(vF,void 0),c=so({activeChildren:new Set});ea(vF,c);const a=ua(+t.value);zv(e,()=>{var T;const x=(T=e_.at(-1))==null?void 0:T[1];a.value=x?x+10:+t.value,i&&e_.push([r.uid,a.value]),s==null||s.activeChildren.add(r.uid),$s(()=>{if(i){const C=Ar(e_).findIndex(A=>A[0]===r.uid);e_.splice(C,1)}s==null||s.activeChildren.delete(r.uid)})});const m=ua(!0);i&&sh(()=>{var T;const x=((T=e_.at(-1))==null?void 0:T[0])===r.uid;setTimeout(()=>m.value=x)});const g=yt(()=>!c.activeChildren.size);return{globalTop:bv(m),localTop:g,stackStyles:yt(()=>({zIndex:a.value}))}}function Uye(e){return{teleportTarget:yt(()=>{const n=e.value;if(n===!0||!Ro)return;const r=n===!1?document.body:typeof n=="string"?document.querySelector(n):n;if(r==null)return;let i=r.querySelector(":scope > .v-overlay-container");return i||(i=document.createElement("div"),i.className="v-overlay-container",r.appendChild(i)),i})}}const Vye=qi({transition:{type:[Boolean,String,Object],default:"fade-transition",validator:e=>e!==!0}},"transition"),Gye=(e,t)=>{let{slots:n}=t;const{transition:r,disabled:i,...s}=e,{component:c=bs,...a}=typeof r=="object"?r:{};return ao(c,Li(typeof r=="string"?{name:i?"":r}:a,s,{disabled:i}),n)};function qye(){return!0}function Mj(e,t,n){if(!e||Ij(e,n)===!1)return!1;const r=tj(t);if(typeof ShadowRoot<"u"&&r instanceof ShadowRoot&&r.host===e.target)return!1;const i=(typeof n.value=="object"&&n.value.include||(()=>[]))();return i.push(t),!i.some(s=>s==null?void 0:s.contains(e.target))}function Ij(e,t){return(typeof t.value=="object"&&t.value.closeConditional||qye)(e)}function Wye(e,t,n){const r=typeof n.value=="function"?n.value:n.value.handler;t._clickOutside.lastMousedownWasOutside&&Mj(e,t,n)&&setTimeout(()=>{Ij(e,n)&&r&&r(e)},0)}function bF(e,t){const n=tj(e);t(document),typeof ShadowRoot<"u"&&n instanceof ShadowRoot&&t(n)}const Hye={mounted(e,t){const n=i=>Wye(i,e,t),r=i=>{e._clickOutside.lastMousedownWasOutside=Mj(i,e,t)};bF(e,i=>{i.addEventListener("click",n,!0),i.addEventListener("mousedown",r,!0)}),e._clickOutside||(e._clickOutside={lastMousedownWasOutside:!1}),e._clickOutside[t.instance.$.uid]={onClick:n,onMousedown:r}},unmounted(e,t){e._clickOutside&&(bF(e,n=>{var s;if(!n||!((s=e._clickOutside)!=null&&s[t.instance.$.uid]))return;const{onClick:r,onMousedown:i}=e._clickOutside[t.instance.$.uid];n.removeEventListener("click",r,!0),n.removeEventListener("mousedown",i,!0)}),delete e._clickOutside[t.instance.$.uid])}};function Yye(e){const{modelValue:t,color:n,...r}=e;return sn(bs,{name:"fade-transition",appear:!0},{default:()=>[e.modelValue&&sn("div",Li({class:["v-overlay__scrim",e.color.backgroundColorClasses.value],style:e.color.backgroundColorStyles.value},r),null)]})}const Zye=qi({absolute:Boolean,attach:[Boolean,String,Object],closeOnBack:{type:Boolean,default:!0},contained:Boolean,contentClass:null,contentProps:null,disabled:Boolean,noClickAnimation:Boolean,modelValue:Boolean,persistent:Boolean,scrim:{type:[Boolean,String],default:!0},zIndex:{type:[Number,String],default:2e3},...Oye(),...Sp(),...Aj(),...Fye(),..._ye(),...Eye(),...Mg(),...Vye()},"VOverlay"),Xye=Dc()({name:"VOverlay",directives:{ClickOutside:Hye},inheritAttrs:!1,props:{_disableGlobalStack:Boolean,...Zye()},emits:{"click:outside":e=>!0,"update:modelValue":e=>!0,afterLeave:()=>!0},setup(e,t){let{slots:n,attrs:r,emit:i}=t;const s=$v(e,"modelValue"),c=yt({get:()=>s.value,set:le=>{le&&e.disabled||(s.value=le)}}),{teleportTarget:a}=Uye(yt(()=>e.attach||e.contained)),{themeClasses:m}=jv(e),{rtlClasses:g,isRtl:x}=z1(),{hasContent:T,onAfterLeave:C}=Bye(e,c),A=Fx(yt(()=>typeof e.scrim=="string"?e.scrim:null)),{globalTop:P,localTop:D,stackStyles:B}=jye(c,Us(e,"zIndex"),e._disableGlobalStack),{activatorEl:R,activatorRef:N,activatorEvents:j,contentEvents:U,scrimEvents:W}=Dye(e,{isActive:c,isTop:D}),{dimensionStyles:Q}=Pj(e),Z=Rye(),{scopeId:K}=$ye();Nn(()=>e.disabled,le=>{le&&(c.value=!1)});const Y=jt(),me=jt(),{contentStyles:ge,updateLocation:ce}=vye(e,{isRtl:x,contentEl:me,activatorEl:R,isActive:c});Sye(e,{root:Y,contentEl:me,activatorEl:R,isActive:c,updateLocation:ce});function fe(le){i("click:outside",le),e.persistent?ne():c.value=!1}function ie(){return c.value&&P.value}Ro&&Nn(c,le=>{le?window.addEventListener("keydown",xe):window.removeEventListener("keydown",xe)},{immediate:!0});function xe(le){var se,Ne;le.key==="Escape"&&P.value&&(e.persistent?ne():(c.value=!1,(se=me.value)!=null&&se.contains(document.activeElement)&&((Ne=R.value)==null||Ne.focu
vendor: 4,106 bytes, line 1439
1439s())))}const Te=zye();zv(()=>e.closeOnBack,()=>{Nye(Te,le=>{P.value&&c.value?(le(!1),e.persistent?ne():c.value=!1):le()})});const oe=jt();Nn(()=>c.value&&(e.absolute||e.contained)&&a.value==null,le=>{if(le){const se=tge(Y.value);se&&se!==document.scrollingElement&&(oe.value=se.scrollTop)}});function ne(){e.noClickAnimation||me.value&&X$(me.value,[{transformOrigin:"center"},{transform:"scale(1.03)"},{transformOrigin:"center"}],{duration:150,easing:nj})}return jd(()=>{var le;return sn(Hn,null,[(le=n.activator)==null?void 0:le.call(n,{isActive:c.value,props:Li({ref:N},j.value,e.activatorProps)}),Z.value&&T.value&&sn(x3,{disabled:!a.value,to:a.value},{default:()=>[sn("div",Li({class:["v-overlay",{"v-overlay--absolute":e.absolute||e.contained,"v-overlay--active":c.value,"v-overlay--contained":e.contained},m.value,g.value,e.class],style:[B.value,{top:si(oe.value)},e.style],ref:Y},K,r),[sn(Yye,Li({color:A,modelValue:c.value&&!!e.scrim},W.value),null),sn(Gye,{appear:!0,persisted:!0,transition:e.transition,target:R.value,onAfterLeave:()=>{C(),i("afterLeave")}},{default:()=>{var se;return[pd(sn("div",Li({ref:me,class:["v-overlay__content",e.contentClass],style:[Q.value,ge.value]},U.value,e.contentProps),[(se=n.default)==null?void 0:se.call(n,{isActive:c})]),[[gd,c.value],[I8("click-outside"),{handler:fe,closeConditional:ie,include:()=>[R.value]}]])]}})])]})])}),{activatorEl:R,animateClick:ne,contentEl:me,globalTop:P,localTop:D,updateLocation:ce}}});const Kye=qi({bgColor:String,color:String,indeterminate:[Boolean,String],modelValue:{type:[Number,String],default:0},rotate:{type:[Number,String],default:0},width:{type:[Number,String],default:4},...Sp(),...yj(),...yA({tag:"div"}),...Mg()},"VProgressCircular"),Qye=Dc()({name:"VProgressCircular",props:Kye(),setup(e,t){let{slots:n}=t;const r=20,i=2*Math.PI*r,s=jt(),{themeClasses:c}=jv(e),{sizeClasses:a,sizeStyles:m}=_j(e),{textColorClasses:g,textColorStyles:x}=uv(Us(e,"color")),{textColorClasses:T,textColorStyles:C}=uv(Us(e,"bgColor")),{intersectionRef:A,isIntersecting:P}=xj(),{resizeRef:D,contentRect:B}=Qge(),R=yt(()=>Math.max(0,Math.min(100,parseFloat(e.modelValue)))),N=yt(()=>Number(e.width)),j=yt(()=>m.value?Number(e.size):B.value?B.value.width:Math.max(N.value,32)),U=yt(()=>r/(1-N.value/j.value)*2),W=yt(()=>N.value/j.value*U.value),Q=yt(()=>si((100-R.value)/100*i));return sh(()=>{A.value=s.value,D.value=s.value}),jd(()=>sn(e.tag,{ref:s,class:["v-progress-circular",{"v-progress-circular--indeterminate":!!e.indeterminate,"v-progress-circular--visible":P.value,"v-progress-circular--disable-shrink":e.indeterminate==="disable-shrink"},c.value,a.value,g.value,e.class],style:[m.value,x.value,e.style],role:"progressbar","aria-valuemin":"0","aria-valuemax":"100","aria-valuenow":e.indeterminate?void 0:R.value},{default:()=>[sn("svg",{style:{transform:`rotate(calc(-90deg + ${Number(e.rotate)}deg))`},xmlns:"http://www.w3.org/2000/svg",viewBox:`0 0 ${U.value} ${U.value}`},[sn("circle",{class:["v-progress-circular__underlay",T.value],style:C.value,fill:"transparent",cx:"50%",cy:"50%",r,"stroke-width":W.value,"stroke-dasharray":i,"stroke-dashoffset":0},null),sn("circle",{class:"v-progress-circular__overlay",fill:"transparent",cx:"50%",cy:"50%",r,"stroke-width":W.value,"stroke-dasharray":i,"stroke-dashoffset":Q.value},null)]),n.default&&sn("div",{class:"v-progress-circular__content"},[n.default({value:R.value})])]})),{}}}),Jye=qi({autofocus:Boolean,divider:String,focusAll:Boolean,label:{type:String,default:"$vuetify.input.otp"},length:{type:[Number,String],default:6},modelValue:{type:[Number,String],default:void 0},placeholder:String,type:{type:String,default:"text"},...Aj(),...vj(),...Ome(Ej({variant:"outlined"}),["baseColor","bgColor","class","color","disabled","error","loading","rounded","style","theme","variant"])},"VOtpInput"),e_e=Dc()({name:"VOtpInput",props:Jye(),emits:{finish:e=>!0,"update:focused":e=>!0,"update:modelValue":e=>!0},setup(e,t){let{attrs:n,emit:r,slots:i}=t;const{dimensionStyles:s}=Pj(e),{isFocused:c,focus:a,blur:m}=bj(e),g=$v(e,"modelValue","",Q=>String(Q).split(""),Q=>Q.join("")),{t:x}
1439=uj(),T=yt(()=>Array(Number(e.length)).fill(0)),C=jt(-1),A=jt(),P=jt([]),D=yt(()=>P.value[C.value]);function B(){const Q=g.value.slice(),Z=D.value.value;Q[C.value]=Z,g.value=Q;let K=null;C.value>g.value.length?K=g.value.length+1:C.value+1!==Number(e.length)?K="next":requestAnimationFrame(()=>{var Y;return(Y=D.value)==null?void 0:Y.blur()}),K&&zC(A.value,K)}function R(Q){const Z=g.value.slice(),K=C.value;let Y=null;["ArrowLeft","ArrowRight","Backspace","Delete"].includes(Q.key)&&(Q.preventDefault(),Q.key==="ArrowLeft"?Y="prev":Q.key==="ArrowRight"?Y="next":["Backspace","Delete"].includes(Q.key)&&(Z[C.value]="",g.value=Z,C.value>0&&Q.key==="Backspace"?Y="prev":requestAnimationFrame(()=>{P.value[K].select()})),requestAnimationFrame(()=>{Y!=null&&zC(A.value,Y)}))}function N(Q,Z){var K,Y;Z.preventDefault(),Z.stopPropagation(),g.value=(((K=Z==null?void 0:Z.clipboardData)==null?void 0:K.getData("Text"))??"").split(""),(Y=P.value)==null||Y[Q].blur()}function j(){g.value=[]}function U(Q,Z){a(),C.value=Z}function W(){m(),C.value=-1}return ij({VField:{disabled:yt(()=>e.disabled),error:yt(()=>e.error),variant:yt(()=>e.variant)}},{scoped:!0}),Nn(g,Q=>{Q.length===e.length&&r("finish",Q.join(""))},{deep:!0}),Nn(C,Q=>{Q<0||Ro&&window.requestAnimationFrame(()=>{P.value[Q].select()})}),jd(()=>{var K;const[Q,Z]=Dme(n);return sn("div",Li({class:["v-otp-input",{"v-otp-input--divided":!!e.divider},e.class],style:[e.style]},Q),[sn("div",{ref:A,class:"v-otp-input__content",style:[s.value]},[T.value.map((Y,me)=>sn(Hn,null,[e.divider&&me!==0&&sn("span",{class:"v-otp-input__divider"},[e.divider]),sn(Sj,{focused:c.value&&e.focusAll||C.value===me,key:me},{...i,default:()=>sn("input",{ref:ge=>P.value[me]=ge,"aria-label":x(e.label,me+1),autofocus:me===0&&e.autofocus,autocomplete:"one-time-code",class:["v-otp-input__field"],inputmode:"text",min:e.type==="number"?0:void 0,maxlength:"1",placeholder:e.placeholder,type:e.type,value:g.value[me],onInput:B,onFocus:ge=>U(ge,me),onBlur:W,onKeydown:R,onPaste:ge=>N(me,ge)},null)})])),sn("input",Li({class:"v-otp-input-input",type:"hidden"},Z,{value:g.value.join("")}),null),sn(Xye,{contained:!0,"content-class":"v-otp-input__loader","model-value":!!e.loading,persistent:!0},{default:()=>{var Y;return[((Y=i.loader)==null?void 0:Y.call(i))??sn(Qye,{color:typeof e.loading=="boolean"?void 0:e.loading,indeterminate:!0,size:"24",width:"2"},null)]}}),(K=i.default)==null?void 0:K.call(i)])])}),{blur:()=>{var Q;(Q=P.value)==null||Q.some(Z=>Z.blur())},focus:()=>{var Q;(Q=P.value)==null||Q[0].focus()},reset:j,isFocused:c}}}),t_e=Gi(e=>{const t=fj({components:{VOtpInput:e_e},ssr:!0,defaults:bpe,theme:{defaultTheme:xpe,themes:{light:{...ER,colors:{...ER.colors,primary:"#FFCD03",secondary:"#E32726"}},dark:wpe}},icons:{defaultSet:"custom",aliases:Tme,sets:{custom:Eme}}});e.vueApp.use(t)}),n_e=[lH,_7,Y7,Z7,X7,K7,r9,o9,iX,_X,vX,zK,ZK,JK,rQ,oQ,Jee,fne,bne,Fre,Zre,$ie,ace,_ce,Ace,vpe,t_e],r_e=(e,t)=>t.path.replace(/(:\w+)\([^)]+\)/g,"$1").replace(/(:\w+)[?+*]/g,"$1").replace(/:\w+/g,n=>{var r;return((r=e.params[n.slice(1)])==null?void 0:r.toString())||""}),WC=(e,t)=>{const n=e.route.matched.find(i=>{var s;return((s=i.components)==null?void 0:s.default)===e.Component.type}),r=t??(n==null?void 0:n.meta.key)??(n&&r_e(e.route,n));return typeof r=="function"?r(e.route):r},i_e=(e,t)=>({default:()=>e?ao(S8,e===!0?{}:e,t):t}),o_e=sr({name:"RouteProvider",props:{vnode:{type:Object,required:!0},route:{type:Object,required:!0},vnodeRef:Object,renderKey:String,trackRootNodes:Boolean},setup(e){const t=e.renderKey,n=e.route,r={};for(const i in e.route)Object.defineProperty(r,i,{get:()=>t===e.renderKey?e.route[i]:n[i]});return ea(Cv,vv(r)),()=>ao(e.vnode,{ref:e.vnodeRef})}}),Oj=(e,t,n)=>(t=t===!0?{}:t,{default:()=>{var r;return t?ao(e,t,n):(r=n.default)==null?void 0:r.call(n)}}),a_e=sr({name:"NuxtPage",inheritAttrs:!1,props:{name:{type:String},transition:{type:[Boolean,Object],default:void 0},keepalive:{type:[Boolean,Object],default:void 0},route:{type:Object},pageKey:{type:[Function,String],default:null}},setup(e,{attrs:t,expose:n}){const r=qo(),i=jt(),s=dr(Cv,null);n({pageRef:i});const c=dr(aB,null);let a;const m=r.deferHydration();return()=>ao(bB,{name:e.name,route:e.route,...t},{default:g=>{const x=c_e(s,g.route,g.Component),T=s&&s.matched.length===g.route.matched.length;if(!g.Component)return a&&!T?a:void 0;if(a&&c&&!c.isCurrent(g.route))return a;
1439if(x&&s&&(!c||c!=null&&c.isCurrent(s)))return T?a:null;const C=WC(g,e.pageKey),A=!!(e.transition??g.route.meta.pageTransition??JE),P=A&&l_e([e.transition,g.route.meta.pageTransition,JE,{onAfterLeave:()=>{r.callHook("page:transition:finish",g.Component)}}].filter(Boolean));return a=Oj(bs,A&&P,i_e(e.keepalive??g.route.meta.keepalive??VW,ao(ck,{suspensible:!0,onPending:()=>r.callHook("page:start",g.Component),onResolve:()=>{Qi(()=>r.callHook("page:finish",g.Component).finally(m))}},{default:()=>ao(o_e,{key:C,vnode:g.Component,route:g.route,renderKey:C,trackRootNodes:A,vnodeRef:i})}))).default(),a}})}});function s_e(e){return Array.isArray(e)?e:e?[e]:[]}function l_e(e){const t=e.map(n=>({...n,onAfterLeave:s_e(n.onAfterLeave)}));return tH(...t)}function c_e(e,t,n){if(!e)return!1;const r=t.matched.findIndex(i=>{var s;return((s=i.components)==null?void 0:s.default)===(n==null?void 0:n.type)});return!r||r===-1?!1:t.matched.slice(0,r).some((i,s)=>{var c,a,m;return((c=i.components)==null?void 0:c.default)!==((m=(a=e.matched[s])==null?void 0:a.components)==null?void 0:m.default)})||n&&WC({route:t,Component:n})!==WC({route:e,Component:n})}const u_e=sr({name:"LayoutLoader",inheritAttrs:!1,props:{name:String,layoutProps:Object},async setup(e,t){const n=await Zf[e.name]().then(r=>r.default||r);return()=>ao(n,e.layoutProps,t.slots)}}),h_e=sr({name:"NuxtLayout",inheritAttrs:!1,props:{name:{type:[String,Boolean,Object],default:null}},setup(e,t){const n=qo(),r=dr(Cv),i=r===sB()?h7():r,s=yt(()=>bt(e.name)??i.meta.layout??"default"),c=jt();t.expose({layoutRef:c});const a=n.deferHydration();return()=>{const m=s.value&&s.value in Zf,g=i.meta.layoutTransition??UW;return Oj(bs,m&&g,{default:()=>ao(ck,{suspensible:!0,onResolve:()=>{Qi(a)}},{default:()=>ao(d_e,{layoutProps:Li(t.attrs,{ref:c}),key:s.value,name:s.value,shouldProvide:!e.name,hasTransition:!!g},t.slots)})}).default()}}}),d_e=sr({name:"NuxtLayoutProvider",inheritAttrs:!1,props:{name:{type:[String,Boolean]},layoutProps:{type:Object},hasTransition:{type:Boolean},shouldProvide:{type:Boolean}},setup(e,t){const n=e.name;return e.shouldProvide&&ea(aB,{isCurrent:r=>n===(r.meta.layout??"default")}),()=>{var r,i;return!n||typeof n=="string"&&!(n in Zf)?(i=(r=t.slots).default)==null?void 0:i.call(r):ao(u_e,{key:n,layoutProps:e.layoutProps,name:n},t.slots)}}});const f_e={setup(){const{width:e}=qz();return{width:e}},computed:{isDesktop(){return this.width>640}},watch:{isDesktop(e){this.$stores.layout.updateIsDesktop(e)}},created(){this.$stores.layout.updateIsDesktop(this.isDesktop)}};function p_e(e,t,n,r,i,s){const c=a_e,a=h_e;return At(),Tr(a,{name:"default"},{default:wr(()=>[sn(c)]),_:1})}const m_e=Lv(f_e,[["render",p_e]]),g_e=sr({__name:"error",setup(e){return(()=>lB({redirect:"/"}))(),(n,r)=>(At(),Wt("div"))}}),y_e={__name:"nuxt-root",setup(e){const t=()=>null,n=qo(),r=n.deferHydration(),i=!1;ea(Cv,sB()),n.hooks.callHookWith(a=>a.map(m=>m()),"vue:setup");const s=e1();u3((a,m,g)=>{if(n.hooks.callHook("vue:error",a,m,g).catch(x=>console.error("[nuxt] Error in `vue:error` hook",x)),sH(a)&&(a.fatal||a.unhandled))return n.runWithContext(()=>km(a)),!1});const{islandContext:c}=!1;return(a,m)=>(At(),Tr(ck,{onResolve:bt(r)},{default:wr(()=>[bt(s)?(At(),Tr(bt(g_e),{key:0,error:bt(s)},null,8,["error"])):bt(c)?(At(),Tr(bt(t),{key:1,context:bt(c)},null,8,["context"])):bt(i)?(At(),Tr(Ev(bt(i)),{key:2})):(At(),Tr(bt(m_e),{key:3}))]),_:1},8,["onResolve"]))}},xF=y_e;globalThis.$fetch||(globalThis.$fetch=Cq.create({baseURL:Aq()}));let wF;{let e;wF=async function(){var s,c;if(e)return e;const r=!!((s=window.__NUXT__)!=null&&s.serverRendered||((c=document.getElementById("__NUXT_DATA__"))==null?void 0:c.dataset.ssr)==="true")?NG(xF):WE(xF),i=jq({vueApp:r});try{await Vq(i,n_e)}catch(a){await i.callHook("app:error",a),i.payload.error=i.payload.error||a}try{await i.hooks.callHook("app:created",r),await i.hooks.callHook("app:beforeMount",r),r.mount("#"+GW),await i.hooks.callHook("app:mounted",r),await Qi()}catch(a){await i.callHook("app:error",a),i.payload.error=i.payload.error||a}return r},e=wF().catch(t=>{console.error("Error while mounting app:",t)})}export{En as $,Mg as A,Fx as B,Us as C,Tj as D,jv as E,Hn as F,z1 as G,ua as H,yt as I,ij as J,si as K,K_e as L,Li as M,L_e as N,uj as O,jt as P,Nn as Q,ea as R,I8 as S,Fye as T,dr as U,sye as V,Bye as W,gd as X,Gye as Y,Qi as Z,Lv as _,Tr as a,a3 as a$,ys as a0,$v as a1,pye as a2,b
1439j as a3,pA as a4,Dme as a5,mye as a6,Qye as a7,F1 as a8,A_ as a9,bs as aA,X$ as aB,G_e as aC,nj as aD,q_e as aE,Z$ as aF,Vye as aG,l3 as aH,Sme as aI,_v as aJ,Pc as aK,ao as aL,R_e as aM,X_e as aN,uv as aO,vj as aP,zv as aQ,Nb as aR,lye as aS,$s as aT,tye as aU,zme as aV,H_e as aW,uge as aX,Qge as aY,Y_e as aZ,BC as a_,Aj as aa,fye as ab,cye as ac,eve as ad,yj as ae,Pj as af,uye as ag,_j as ah,J_e as ai,Zye as aj,$ye as ak,Ro as al,Xye as am,Fme as an,$R as ao,O_e as ap,Ai as aq,gj as ar,Ql as as,xp as at,so as au,Dr as av,Ime as aw,F_e as ax,CE as ay,wv as az,sn as b,Sn as b$,o3 as b0,bv as b1,iye as b2,qz as b3,Ej as b4,Q_e as b5,Sj as b6,nh as b7,N_e as b8,QC as b9,j_e as bA,h_e as bB,xj as bC,sB as bD,v_e as bE,P_e as bF,E_e as bG,m9 as bH,S_e as bI,k_e as bJ,C_e as bK,v9 as bL,f9 as bM,Ta as bN,EO as bO,T_e as bP,Lt as bQ,B_e as bR,Z_e as bS,D_e as bT,Rd as bU,oo as bV,eQ as bW,nne as bX,C3 as bY,_5 as bZ,Eg as b_,ko as ba,sh as bb,sr as bc,$W as bd,q$ as be,tge as bf,I_e as bg,Nv as bh,uA as bi,zC as bj,Pye as bk,Bme as bl,Ar as bm,U_e as bn,qo as bo,Sg as bp,Qx as bq,wk as br,tq as bs,ZE as bt,V3 as bu,x_e as bv,RC as bw,$_e as bx,V_e as by,wa as bz,Wt as c,z_e as c0,zye as c1,VR as c2,b_e as c3,W_e as c4,pne as c5,mu as d,Un as e,hn as f,Di as g,u8 as h,tte as i,pd as j,Zx as k,Sa as l,a_e as m,qr as n,At as o,c8 as p,qi as q,$o as r,Sp as s,Ba as t,bt as u,yA as v,wr as w,Dc as x,jd as y,wj as z};

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.