vendor: 11,718 bytes, lines 1-9
1/** 2* @vue/shared v3.5.30 3* (c) 2018-present Yuxi (Evan) You and Vue contributors 4* @license MIT 5**/function Ea(e){const t=Object.create(null);for(const r of e.split(","))t[r]=1;return r=>r in t}const Dt={},Pd=[],qi=()=>{},_d=()=>!1,Pc=e=>e.charCodeAt(0)===111&&e.charCodeAt(1)===110&&(e.charCodeAt(2)>122||e.charCodeAt(2)<97),g3=e=>e.startsWith("onUpdate:"),Ct=Object.assign,_3=(e,t)=>{const r=e.indexOf(t);r>-1&&e.splice(r,1)},Zz=Object.prototype.hasOwnProperty,Kt=(e,t)=>Zz.call(e,t),Le=Array.isArray,Md=e=>Nh(e)==="[object Map]",Mc=e=>Nh(e)==="[object Set]",qS=e=>Nh(e)==="[object Date]",Kz=e=>Nh(e)==="[object RegExp]",nt=e=>typeof e=="function",ft=e=>typeof e=="string",ea=e=>typeof e=="symbol",Ht=e=>e!==null&&typeof e=="object",y3=e=>(Ht(e)||nt(e))&&nt(e.then)&&nt(e.catch),pP=Object.prototype.toString,Nh=e=>pP.call(e),Xz=e=>Nh(e).slice(8,-1),Ky=e=>Nh(e)==="[object Object]",Xy=e=>ft(e)&&e!=="NaN"&&e[0]!=="-"&&""+parseInt(e,10)===e,Vo=Ea(",key,ref,ref_for,ref_key,onVnodeBeforeMount,onVnodeMounted,onVnodeBeforeUpdate,onVnodeUpdated,onVnodeBeforeUnmount,onVnodeUnmounted"),Jz=Ea("bind,cloak,else-if,else,for,html,if,model,on,once,pre,show,slot,text,memo"),Jy=e=>{const t=Object.create(null);return(r=>t[r]||(t[r]=e(r)))},Qz=/-\w/g,ar=Jy(e=>e.replace(Qz,t=>t.slice(1).toUpperCase())),eN=/\B([A-Z])/g,Un=Jy(e=>e.replace(eN,"-$1").toLowerCase()),Ic=Jy(e=>e.charAt(0).toUpperCase()+e.slice(1)),Id=Jy(e=>e?`on${Ic(e)}`:""),Oi=(e,t)=>!Object.is(e,t),Ad=(e,...t)=>{for(let r=0;r<e.length;r++)e[r](...t)},mP=(e,t,r,i=!1)=>{Object.defineProperty(e,t,{configurable:!0,enumerable:!1,writable:i,value:r})},Qy=e=>{const t=parseFloat(e);return isNaN(t)?e:t},$_=e=>{const t=ft(e)?Number(e):NaN;return isNaN(t)?e:t};let GS;const e1=()=>GS||(GS=typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:typeof global<"u"?global:{});function tN(e,t){return e+JSON.stringify(t,(r,i)=>typeof i=="function"?i.toString():i)}const rN="Infinity,undefined,NaN,isFinite,isNaN,parseFloat,parseInt,decodeURI,decodeURIComponent,encodeURI,encodeURIComponent,Math,Number,Date,Array,Object,Boolean,String,RegExp,Map,Set,JSON,Intl,BigInt,console,Error,Symbol",iN=Ea(rN);function Qt(e){if(Le(e)){const t={};for(let r=0;r<e.length;r++){const i=e[r],n=ft(i)?gP(i):Qt(i);if(n)for(const a in n)t[a]=n[a]}return t}else if(ft(e)||Ht(e))return e}const nN=/;(?![^(]*\))/g,aN=/:([^]+)/,sN=/\/\*[^]*?\*\//g;function gP(e){const t={};return e.replace(sN,"").split(nN).forEach(r=>{if(r){const i=r.split(aN);i.length>1&&(t[i[0].trim()]=i[1].trim())}}),t}function pe(e){let t="";if(ft(e))t=e;else if(Le(e))for(let r=0;r<e.length;r++){const i=pe(e[r]);i&&(t+=i+" ")}else if(Ht(e))for(const r in e)e[r]&&(t+=r+" ");return t.trim()}function Gu(e){if(!e)return null;let{class:t,style:r}=e;return t&&!ft(t)&&(e.class=pe(t)),r&&(e.style=Qt(r)),e}const oN="html,body,base,head,link,meta,style,title,address,article,aside,footer,header,hgroup,h1,h2,h3,h4,h5,h6,nav,section,div,dd,dl,dt,figcaption,figure,picture,hr,img,li,main,ol,p,pre,ul,a,b,abbr,bdi,bdo,br,cite,code,data,dfn,em,i,kbd,mark,q,rp,rt,ruby,s,samp,small,span,strong,sub,sup,time,u,var,wbr,area,audio,map,track,video,embed,object,param,source,canvas,script,noscript,del,ins,caption,col,colgroup,table,thead,tbody,td,th,tr,button,datalist,fieldset,form,input,label,legend,meter,optgroup,option,output,progress,select,textarea,details,dialog,menu,summary,template,blockquote,iframe,tfoot",lN="svg,animate,animateMotion,animateTransform,circle,clipPath,color-profile,defs,desc,discard,ellipse,feBlend,feColorMatrix,feComponentTransfer,feComposite,feConvolveMatrix,feDiffuseLighting,feDisplacementMap,feDistantLight,feDropShadow,feFlood,feFuncA,feFuncB,feFuncG,feFuncR,feGaussianBlur,feImage,feMerge,feMergeNode,feMorphology,feOffset,fePointLight,feSpecularLighting,feSpotLight,feTile,feTurbulence,filter,foreignObject,g,hatch,hatchpath,image,line,linearGradient,marker,mask,mesh,meshgradient,meshpatch,meshrow,metadata,mpath,path,pattern,polygon,polyline,radialGradient,rect,set,solidcolor,stop,switch,symbol,text,textPath,title,tspan,unknown,use,view",uN="annotation,annotation-xml,maction,maligngroup,malignmark,math,menclose,merror,mfenced,mfrac,mfraction,mglyph,mi,mlabeledtr,mlongdiv,mmultiscripts,mn,mo,mover,mpadded,mphantom,mprescripts,mroot,mrow,ms,mscarries,mscarry,msgroup,msline,mspace,msqrt,msrow,mstack,mstyle,msub,msubsup,msup,mtable,mtd,mtext,mtr,munder,munderover,none,semantics",cN="area,base,br,col,embed,hr,img,input,link,meta,param,source,track,wbr",dN=Ea(oN),hN=Ea(lN),fN=Ea(uN),pN=Ea(cN),mN="itemscope,allowfullscreen,formnovalidate,ismap,nomodule,novalidate,readonly",gN=Ea(mN);function _P(e){return!!e||e===""}function _N(e,t){if(e.length!==t.length)return!1;let r=!0;for(let i=0;r&&i<e.length;i++)r=Ko(e[i],t[i]);return r}function Ko(e,t){if(e===t)return!0;let r=qS(e),i=qS(t);if(r||i)return r&&i?e.getTime()===t.getTime():!1;if(r=ea(e),i=ea(t),r||i)return e===t;if(r=Le(e),i=Le(t),r||i)return r&&i?_N(e,t):!1;if(r=Ht(e),i=Ht(t),r||i){if(!r||!i)return!1;const n=Object.keys(e).length,a=Object.keys(t).length;if(n!==a)return!1;for(const s in e){const o=e.hasOwnProperty(s),l=t.hasOwnProperty(s);if(o&&!l||!o&&l||!Ko(e[s],t[s]))return!1}}return String(e)===String(t)}function t1(e,t){return e.findIndex(r=>Ko(r,t))}const yP=e=>!!(e&&e.__v_isRef===!0),Q=e=>ft(e)?e:e==null?"":Le(e)||Ht(e)&&(e.toString===pP||!nt(e.toString))?yP(e)?Q(e.value):JSON.stringify(e,vP,2):String(e),vP=(e,t)=>yP(t)?vP(e,t.value):Md(t)?{[`Map(${t.size})`]:[...t.entries()].reduce((r,[i,n],a)=>(r[Sv(i,a)+" =>"]=n,r),{})}:Mc(t)?{[`Set(${t.size})`]:[...t.values()].map(r=>Sv(r))}:ea(t)?Sv(t):Ht(t)&&!Le(t)&&!Ky(t)?String(t):t,Sv=(e,t="")=>{var r;return ea(e)?`Symbol(${(r=e.description)!=null?r:t})`:e};function yN(e){return e==null?"initial":typeof e=="string"?e===""?" ":e:String(e)}/** 6* @vue/reactivity v3.5.30 7* (c) 2018-present Yuxi (Evan) You and Vue contributors 8* @license MIT 9**/let en;class v3{constructor(t=!1){this.detached=t,this._active=!0,this._on=0,this.effects=[],this.cleanups=[],this._isPaused=!1,this.__v_skip=!0,this.parent=en,!t&&en&&(this.index=(en.scopes||(en.scopes=[])).push(this)-1)}get active(){return this._active}pause(){if(this._active){this._isPaused=!0;let t,r;if(this.scopes)for(t=0,r=this.scopes.length;t<r;t++)this.scopes[t].pause();for(t=0,r=this.effects.length;t<r;t++)this.effects[t].pause()}}resume(){if(this._active&&this._isPaused){this._isPaused=!1;let t,r;if(this.scopes)for(t=0,r=this.scopes.length;t<r;t++)this.scopes[t].resume();for(t=0,r=this.effects.length;t<r;t++)this.effects[t].resume()}}run(t){if(this._active){const r=en;try{return en=this,t()}finally{en=r}}}on(){++this._on===1&&(this.prevScope=en,en=this)}off(){this._on>0&&--this._on===0&&(en=this.prevScope,this.prevScope=void 0)}stop(t){if(this._active){this._active=!1;let r,i;for(r=0,i=this.effects.length;r<i;r++)this.effects[r].stop();for(this.effects.length=0,r=0,i=this.cleanups.length;r<i;r++)this.cleanups[r]();if(this.cleanups.length=0,this.scopes){for(r=0,i=this.scopes.length;r<i;r++)this.scopes[r].stop(!0);this.scopes.length=0}if(!this.detached&&this.parent&&!t){const n=this.parent.scopes.pop();n&&n!==this&&(this.parent.scopes[this.index]=n,n.index=this.index)}this.parent=void 0}}}function b3(e){return new v3(e)}function x3(){return en}function bP(e,t=!1){en&&en.cleanups.push(e)}let mr;const Tv=new WeakSet;class zp{constructor(t){this.fn=t,this.deps=void 0,this.depsTail=void 0,this.flags=5,this.next=void 0,this.cleanup=void 0,this.scheduler=void 0,en&&en.active&&en.effects.push(this)}pause(){this.flags|=64}resume(){this.flags&64&&(this.flags&=-65,Tv.has(this)&&(Tv.delete(this),this.trigger()))}notify(){this.flags&2&&!(this.flags&32)||this.flags&8||wP(this)}run(){if(!(this.flags&1))return this.fn();this.flags|=2,HS(this),$P(this);const t=mr,r=bs;mr=this,bs=!0;try{return this.fn()}finally{SP(this),mr=t,bs=r,this.flags&=-3}}stop(){if(this.flags&1){for(let t=this.deps;t;t=t.nextDep)S3(t);this.deps=this.depsTail=void 0,HS(this),this.onStop&&this.onStop(),this.flags&=-2}}trigger(){this.flags&64?Tv.add(this):this.scheduler?this.scheduler():this.runIfDirty()}runIfDirty(){h2(this)&&this.run()}get dirty(){return h2(this)}}let xP=0,rp,ip;function wP(e,t=!1){if(e.flags|=8,t){e.next=ip,ip=e;return}e.next=rp,rp=e}function w3(){xP++}function $3(){if(--xP>0)return;if(ip){let t=ip;for(ip=void 0;t;){const r=t.next;t.next=void 0,t.flags&=-9,t=r}}let e;for(;rp;){let t=rp;for(rp=void 0;t;){const r=t.next;if(t.next=void 0,t.flags&=-9,t.flags&1)try{t.trigger()}catch(i){e||(e=i)}t=r}}if(e)throw e}function $P(e){for(let t=e.deps;t;t=t.nextDep)t.version=-1,t.prevActiveLink=t.dep.activeLink,t.dep.activeLink=t}function SP(e){let t,r=e.depsTail,i=r;for(;i;){const n=i.prevDep;i.version===-1?(i===r&&(r=n),S3(i),vN(i)):t=i,i.dep.activeLink=i.prevActiveLink,i.prevActiveLink=void 0,i=n}e.deps=t,e.depsTail=r}function h2(e){for(let t=e.deps;t;t=t.nextDep)if(t.dep.version!==t.version||t.dep.computed&&(TP(t.dep.computed)||t.dep.version!==t.version))return!0;return!!e._dirty}function TP(e){if(e.flags&4&&!(e.flags&16)||(e.flags&=-17,e.globalVersion===Np)||(e.globalVersion=Np,!e.isSSR&&e.flags&128&&(!e.deps&&!e._dirty||!h2(e))))return;e.flags|=2;const t=e.dep,r=mr,i=bs;mr=e,bs=!0;try{$P(e);const n=e.fn(e._value);(t.version===0||Oi(n,e._value))&&(e.flags|=128,e._value=n,t.version++)}catch(n){throw t.version++,n}finally{mr=r,bs=i,SP(e),e.flags&=-3}}function S3(e,t=!1){const{dep:r,prevSub:i,nextSub:n}=e;if(i&&(i.nextSub=n,e.prevSub=void 0),n&&(n.prevSub=i,e.nextSub=void 0),r.subs===e&&(r.subs=i,!i&&r.computed)){r.computed.flags&=-5;for(let a=r.computed.deps;a;a=a.nextDep)S3(a,!0)}!t&&!--r.sc&&r.map&&r.map.delete(r.key)}function vN(e){const{prevDep:t,nextDep:r}=e;t&&(t.nextDep=r,e.prevDep=void 0),r&&(r.prevDep=t,e.nextDep=void 0)}function bN(e,t){e.effect instanceof zp&&(e=e.effect.fn);const r=new zp(e);t&&Ct(r,t);try{r.run()}catch(n){throw r.stop(),n}const i=r.run.bind(r);return i.effect=r,i}function xN(e){e.effect.stop()}let bs=!0;const CP=[];function Xo(){CP.push(bs),bs=!1}function Jo(){const e=CP.pop();bs=e===void 0?!0:e}function HS(e){const{cleanup:t}=e;if(e.cleanup=void 0,t){const r=mr;mr=void 0;try{t()}finally{mr=r}}}let Np=0;class wN{constructor(t,r){this.sub=t,this.dep=r,this.version=r.version,this.nextDep=this.prevDep=this.nextSub=this.prevSub=this.prevActiveLink=void 0}}class r1{constructor(t){this.computed=t,this.version=0,this.activeLink=void 0,this.subs=void 0,this.map=void 0,this.key=void 0,this.sc=0,this.__v_skip=!0}track(t){if(!mr||!bs||mr===this.computed)return;let r=this.activeLink;if(r===void 0||r.sub!==mr)r=this.activeLink=new wN(mr,this),mr.deps?(r.prevDep=mr.depsTail,mr.depsTail.nextDep=r,mr.depsTail=r):mr.deps=mr.depsTail=r,kP(r);else if(r.version===-1&&(r.version=this.version,r.nextDep)){const i=r.nextDep;i.prevDep=r.prevDep,r.prevDep&&(r.prevDep.nextDep=i),r.prevDep=mr.depsTail,r.nextDep=void 0,mr.depsTail.nextDep=r,mr.depsTail=r,mr.deps===r&&(mr.deps=i)}return r}trigger(t){this.version++,Np++,this.notify(t)}notify(t){w3();try{for(let r=this.subs;r;r=r.prevSub)r.sub.notify()&&r.sub.dep.notify()}finally{$3()}}}function kP(e){if(e.dep.sc++,e.sub.flags&4){const t=e.dep.computed;if(t&&!e.dep.subs){t.flags|=20;for(let i=t.deps;i;i=i.nextDep)kP(i)}const r=e.dep.subs;r!==e&&(e.prevSub=r,r&&(r.nextSub=e)),e.dep.subs=e}}const S_=new WeakMap,Hu=Symbol(""),f2=Symbol(""),Bp=Symbol("");function an(e,t,r){if(bs&&mr){let i=S_.get(e);i||S_.set(e,i=new Map);let n=i.get(r);n||(i.set(r,n=new r1),n.map=i,n.key=r),n.track()}}function Po(e,t,r,i,n,a){const s=S_.get(e);if(!s){Np++;return}const o=l=>{l&&l.trigger()};if(w3(),t==="clear")s.forEach(o);else{const l=Le(e),u=l&&Xy(r);if(l&&r==="length"){const c=Number(i);
vendor: 3,425 bytes, line 9
9s.forEach((d,h)=>{(h==="length"||h===Bp||!ea(h)&&h>=c)&&o(d)})}else switch((r!==void 0||s.has(void 0))&&o(s.get(r)),u&&o(s.get(Bp)),t){case"add":l?u&&o(s.get("length")):(o(s.get(Hu)),Md(e)&&o(s.get(f2)));break;case"delete":l||(o(s.get(Hu)),Md(e)&&o(s.get(f2)));break;case"set":Md(e)&&o(s.get(Hu));break}}$3()}function $N(e,t){const r=S_.get(e);return r&&r.get(t)}function Vc(e){const t=Ft(e);return t===e?t:(an(t,"iterate",Bp),Gn(e)?t:t.map(Cs))}function i1(e){return an(e=Ft(e),"iterate",Bp),e}function Hs(e,t){return ao(e)?rh(xs(e)?Cs(t):t):Cs(t)}const SN={__proto__:null,[Symbol.iterator](){return Cv(this,Symbol.iterator,e=>Hs(this,e))},concat(...e){return Vc(this).concat(...e.map(t=>Le(t)?Vc(t):t))},entries(){return Cv(this,"entries",e=>(e[1]=Hs(this,e[1]),e))},every(e,t){return _o(this,"every",e,t,void 0,arguments)},filter(e,t){return _o(this,"filter",e,t,r=>r.map(i=>Hs(this,i)),arguments)},find(e,t){return _o(this,"find",e,t,r=>Hs(this,r),arguments)},findIndex(e,t){return _o(this,"findIndex",e,t,void 0,arguments)},findLast(e,t){return _o(this,"findLast",e,t,r=>Hs(this,r),arguments)},findLastIndex(e,t){return _o(this,"findLastIndex",e,t,void 0,arguments)},forEach(e,t){return _o(this,"forEach",e,t,void 0,arguments)},includes(...e){return kv(this,"includes",e)},indexOf(...e){return kv(this,"indexOf",e)},join(e){return Vc(this).join(e)},lastIndexOf(...e){return kv(this,"lastIndexOf",e)},map(e,t){return _o(this,"map",e,t,void 0,arguments)},pop(){return lf(this,"pop")},push(...e){return lf(this,"push",e)},reduce(e,...t){return YS(this,"reduce",e,t)},reduceRight(e,...t){return YS(this,"reduceRight",e,t)},shift(){return lf(this,"shift")},some(e,t){return _o(this,"some",e,t,void 0,arguments)},splice(...e){return lf(this,"splice",e)},toReversed(){return Vc(this).toReversed()},toSorted(e){return Vc(this).toSorted(e)},toSpliced(...e){return Vc(this).toSpliced(...e)},unshift(...e){return lf(this,"unshift",e)},values(){return Cv(this,"values",e=>Hs(this,e))}};function Cv(e,t,r){const i=i1(e),n=i[t]();return i!==e&&!Gn(e)&&(n._next=n.next,n.next=()=>{const a=n._next();return a.done||(a.value=r(a.value)),a}),n}const TN=Array.prototype;function _o(e,t,r,i,n,a){const s=i1(e),o=s!==e&&!Gn(e),l=s[t];if(l!==TN[t]){const d=l.apply(e,a);return o?Cs(d):d}let u=r;s!==e&&(o?u=function(d,h){return r.call(this,Hs(e,d),h,e)}:r.length>2&&(u=function(d,h){return r.call(this,d,h,e)}));const c=l.call(s,u,i);return o&&n?n(c):c}function YS(e,t,r,i){const n=i1(e),a=n!==e&&!Gn(e);let s=r,o=!1;n!==e&&(a?(o=i.length===0,s=function(u,c,d){return o&&(o=!1,u=Hs(e,u)),r.call(this,u,Hs(e,c),d,e)}):r.length>3&&(s=function(u,c,d){return r.call(this,u,c,d,e)}));const l=n[t](s,...i);return o?Hs(e,l):l}function kv(e,t,r){const i=Ft(e);an(i,"iterate",Bp);const n=i[t](...r);return(n===-1||n===!1)&&Vm(r[0])?(r[0]=Ft(r[0]),i[t](...r)):n}function lf(e,t,r=[]){Xo(),w3();const i=Ft(e)[t].apply(e,r);return $3(),Jo(),i}const CN=Ea("__proto__,__v_isRef,__isVue"),EP=new Set(Object.getOwnPropertyNames(Symbol).filter(e=>e!=="arguments"&&e!=="caller").map(e=>Symbol[e]).filter(ea));function kN(e){ea(e)||(e=String(e));const t=Ft(this);return an(t,"has",e),t.hasOwnProperty(e)}class PP{constructor(t=!1,r=!1){this._isReadonly=t,this._isShallow=r}get(t,r,i){if(r==="__v_skip")return t.__v_skip;const n=this._isReadonly,a=this._isShallow;if(r==="__v_isReactive")return!n;if(r==="__v_isReadonly")return n;if(r==="__v_isShallow")return a;
vendor: 4,610 bytes, line 9
9if(r==="__v_raw")return i===(n?a?OP:RP:a?DP:AP).get(t)||Object.getPrototypeOf(t)===Object.getPrototypeOf(i)?t:void 0;const s=Le(t);if(!n){let l;if(s&&(l=SN[r]))return l;if(r==="hasOwnProperty")return kN}const o=Reflect.get(t,r,er(t)?t:i);if((ea(r)?EP.has(r):CN(r))||(n||an(t,"get",r),a))return o;if(er(o)){const l=s&&Xy(r)?o:o.value;return n&&Ht(l)?T_(l):l}return Ht(o)?n?T_(o):An(o):o}}class MP extends PP{constructor(t=!1){super(!1,t)}set(t,r,i,n){let a=t[r];const s=Le(t)&&Xy(r);if(!this._isShallow){const u=ao(a);if(!Gn(i)&&!ao(i)&&(a=Ft(a),i=Ft(i)),!s&&er(a)&&!er(i))return u||(a.value=i),!0}const o=s?Number(r)<t.length:Kt(t,r),l=Reflect.set(t,r,i,er(t)?t:n);return t===Ft(n)&&(o?Oi(i,a)&&Po(t,"set",r,i):Po(t,"add",r,i)),l}deleteProperty(t,r){const i=Kt(t,r);t[r];const n=Reflect.deleteProperty(t,r);return n&&i&&Po(t,"delete",r,void 0),n}has(t,r){const i=Reflect.has(t,r);return(!ea(r)||!EP.has(r))&&an(t,"has",r),i}ownKeys(t){return an(t,"iterate",Le(t)?"length":Hu),Reflect.ownKeys(t)}}class IP extends PP{constructor(t=!1){super(!0,t)}set(t,r){return!0}deleteProperty(t,r){return!0}}const EN=new MP,PN=new IP,MN=new MP(!0),IN=new IP(!0),p2=e=>e,Pg=e=>Reflect.getPrototypeOf(e);function AN(e,t,r){return function(...i){const n=this.__v_raw,a=Ft(n),s=Md(a),o=e==="entries"||e===Symbol.iterator&&s,l=e==="keys"&&s,u=n[e](...i),c=r?p2:t?rh:Cs;return!t&&an(a,"iterate",l?f2:Hu),Ct(Object.create(u),{next(){const{value:d,done:h}=u.next();return h?{value:d,done:h}:{value:o?[c(d[0]),c(d[1])]:c(d),done:h}}})}}function Mg(e){return function(...t){return e==="delete"?!1:e==="clear"?void 0:this}}function DN(e,t){const r={get(n){const a=this.__v_raw,s=Ft(a),o=Ft(n);e||(Oi(n,o)&&an(s,"get",n),an(s,"get",o));const{has:l}=Pg(s),u=t?p2:e?rh:Cs;if(l.call(s,n))return u(a.get(n));if(l.call(s,o))return u(a.get(o));a!==s&&a.get(n)},get size(){const n=this.__v_raw;return!e&&an(Ft(n),"iterate",Hu),n.size},has(n){const a=this.__v_raw,s=Ft(a),o=Ft(n);return e||(Oi(n,o)&&an(s,"has",n),an(s,"has",o)),n===o?a.has(n):a.has(n)||a.has(o)},forEach(n,a){const s=this,o=s.__v_raw,l=Ft(o),u=t?p2:e?rh:Cs;return!e&&an(l,"iterate",Hu),o.forEach((c,d)=>n.call(a,u(c),u(d),s))}};return Ct(r,e?{add:Mg("add"),set:Mg("set"),delete:Mg("delete"),clear:Mg("clear")}:{add(n){const a=Ft(this),s=Pg(a),o=Ft(n),l=!t&&!Gn(n)&&!ao(n)?o:n;return s.has.call(a,l)||Oi(n,l)&&s.has.call(a,n)||Oi(o,l)&&s.has.call(a,o)||(a.add(l),Po(a,"add",l,l)),this},set(n,a){!t&&!Gn(a)&&!ao(a)&&(a=Ft(a));const s=Ft(this),{has:o,get:l}=Pg(s);let u=o.call(s,n);u||(n=Ft(n),u=o.call(s,n));const c=l.call(s,n);return s.set(n,a),u?Oi(a,c)&&Po(s,"set",n,a):Po(s,"add",n,a),this},delete(n){const a=Ft(this),{has:s,get:o}=Pg(a);let l=s.call(a,n);l||(n=Ft(n),l=s.call(a,n)),o&&o.call(a,n);const u=a.delete(n);return l&&Po(a,"delete",n,void 0),u},clear(){const n=Ft(this),a=n.size!==0,s=n.clear();return a&&Po(n,"clear",void 0,void 0),s}}),["keys","values","entries",Symbol.iterator].forEach(n=>{r[n]=AN(n,e,t)}),r}function n1(e,t){const r=DN(e,t);return(i,n,a)=>n==="__v_isReactive"?!e:n==="__v_isReadonly"?e:n==="__v_raw"?i:Reflect.get(Kt(r,n)&&n in i?r:i,n,a)}const RN={get:n1(!1,!1)},ON={get:n1(!1,!0)},LN={get:n1(!0,!1)},FN={get:n1(!0,!0)},AP=new WeakMap,DP=new WeakMap,RP=new WeakMap,OP=new WeakMap;function zN(e){switch(e){case"Object":case"Array":return 1;case"Map":case"Set":case"WeakMap":case"WeakSet":return 2;default:return 0}}function NN(e){return e.__v_skip||!Object.isExtensible(e)?0:zN(Xz(e))}function An(e){return ao(e)?e:a1(e,!1,EN,RN,AP)}function jp(e){return a1(e,!1,MN,ON,DP)}function T_(e){return a1(e,!0,PN,LN,RP)}function BN(e){return a1(e,!0,IN,FN,OP)}function a1(e,t,r,i,n){if(!Ht(e)||e.__v_raw&&!(t&&e.__v_isReactive))return e;const a=NN(e);if(a===0)return e;const s=n.get(e);if(s)return s;const o=new Proxy(e,a===2?i:r);return n.set(e,o),o}function xs(e){return ao(e)?xs(e.__v_raw):!!(e&&e.__v_isReactive)}function ao(e){return!!(e&&e.__v_isReadonly)}function Gn(e){return!!(e&&e.__v_isShallow)}function Vm(e){return e?!!e.__v_raw:!1}function Ft(e){const t=e&&e.__v_raw;return t?Ft(t):e}function mc(e){return!Kt(e,"__v_skip")&&Object.isExtensible(e)&&mP(e,"__v_skip",!0),e}const Cs=e=>Ht(e)?An(e):e,rh=e=>Ht(e)?T_(e):e;function er(e){return e?e.__v_isRef===!0:!1}function se(e){return LP(e,!1)}function Yu(e){return LP(e,!0)}function LP(e,t){return er(e)?e:new jN(e,t)}class jN{constructor(t,r){this.dep=new r1,this.__v_isRef=!0,this.__v_isShallow=!1,this._rawValue=r?t:Ft(t),this._value=r?t:Cs(t),this.__v_isShallow=r}get value(){return this.dep.track(),this._value}set value(t){const r=this._rawValue,i=this.__v_isShallow||Gn(t)||ao(t);
vendor: 3,238 bytes, line 9
9t=i?t:Ft(t),Oi(t,r)&&(this._rawValue=t,this._value=i?t:Cs(t),this.dep.trigger())}}function UN(e){e.dep&&e.dep.trigger()}function le(e){return er(e)?e.value:e}function VN(e){return nt(e)?e():le(e)}const qN={get:(e,t,r)=>t==="__v_raw"?e:le(Reflect.get(e,t,r)),set:(e,t,r,i)=>{const n=e[t];return er(n)&&!er(r)?(n.value=r,!0):Reflect.set(e,t,r,i)}};function T3(e){return xs(e)?e:new Proxy(e,qN)}class GN{constructor(t){this.__v_isRef=!0,this._value=void 0;const r=this.dep=new r1,{get:i,set:n}=t(r.track.bind(r),r.trigger.bind(r));this._get=i,this._set=n}get value(){return this._value=this._get()}set value(t){this._set(t)}}function FP(e){return new GN(e)}function s1(e){const t=Le(e)?new Array(e.length):{};for(const r in e)t[r]=zP(e,r);return t}class HN{constructor(t,r,i){this._object=t,this._key=r,this._defaultValue=i,this.__v_isRef=!0,this._value=void 0,this._raw=Ft(t);let n=!0,a=t;if(!Le(t)||!Xy(String(r)))do n=!Vm(a)||Gn(a);while(n&&(a=a.__v_raw));this._shallow=n}get value(){let t=this._object[this._key];return this._shallow&&(t=le(t)),this._value=t===void 0?this._defaultValue:t}set value(t){if(this._shallow&&er(this._raw[this._key])){const r=this._object[this._key];if(er(r)){r.value=t;return}}this._object[this._key]=t}get dep(){return $N(this._raw,this._key)}}class YN{constructor(t){this._getter=t,this.__v_isRef=!0,this.__v_isReadonly=!0,this._value=void 0}get value(){return this._value=this._getter()}}function Wu(e,t,r){return er(e)?e:nt(e)?new YN(e):Ht(e)&&arguments.length>1?zP(e,t,r):se(e)}function zP(e,t,r){return new HN(e,t,r)}class WN{constructor(t,r,i){this.fn=t,this.setter=r,this._value=void 0,this.dep=new r1(this),this.__v_isRef=!0,this.deps=void 0,this.depsTail=void 0,this.flags=16,this.globalVersion=Np-1,this.next=void 0,this.effect=this,this.__v_isReadonly=!r,this.isSSR=i}notify(){if(this.flags|=16,!(this.flags&8)&&mr!==this)return wP(this,!0),!0}get value(){const t=this.dep.track();return TP(this),t&&(t.version=this.dep.version),this._value}set value(t){this.setter&&this.setter(t)}}function ZN(e,t,r=!1){let i,n;return nt(e)?i=e:(i=e.get,n=e.set),new WN(i,n,r)}const KN={GET:"get",HAS:"has",ITERATE:"iterate"},XN={SET:"set",ADD:"add",DELETE:"delete",CLEAR:"clear"},Ig={},C_=new WeakMap;let Ml;function JN(){return Ml}function NP(e,t=!1,r=Ml){if(r){let i=C_.get(r);i||C_.set(r,i=[]),i.push(e)}}function QN(e,t,r=Dt){const{immediate:i,deep:n,once:a,scheduler:s,augmentJob:o,call:l}=r,u=y=>n?y:Gn(y)||n===!1||n===0?Mo(y,1):Mo(y);let c,d,h,f,p=!1,m=!1;if(er(e)?(d=()=>e.value,p=Gn(e)):xs(e)?(d=()=>u(e),p=!0):Le(e)?(m=!0,p=e.some(y=>xs(y)||Gn(y)),d=()=>e.map(y=>{if(er(y))return y.value;if(xs(y))return u(y);if(nt(y))return l?l(y,2):y()})):nt(e)?t?d=l?()=>l(e,2):e:d=()=>{if(h){Xo();try{h()}finally{Jo()}}const y=Ml;Ml=c;try{return l?l(e,3,[f]):e(f)}finally{Ml=y}}:d=qi,t&&n){const y=d,w=n===!0?1/0:n;d=()=>Mo(y(),w)}const g=x3(),v=()=>{c.stop(),g&&g.active&&_3(g.effects,c)};if(a&&t){const y=t;t=(...w)=>{y(...w),v()}}let x=m?new Array(e.length).fill(Ig):Ig;const _=y=>{if(!(!(c.flags&1)||!c.dirty&&!y))if(t){const w=c.run();if(n||p||(m?w.some(($,S)=>Oi($,x[S])):Oi(w,x))){h&&h();const $=Ml;Ml=c;try{const S=[w,x===Ig?void 0:m&&x[0]===Ig?[]:x,f];x=w,l?l(t,3,S):t(...S)}finally{Ml=$}}}else c.run()};
vendor: 36,162 bytes, lines 9-15
9return o&&o(_),c=new zp(d),c.scheduler=s?()=>s(_,!1):_,f=y=>NP(y,!1,c),h=c.onStop=()=>{const y=C_.get(c);if(y){if(l)l(y,4);else for(const w of y)w();C_.delete(c)}},t?i?_(!0):x=c.run():s?s(_.bind(null,!0),!0):c.run(),v.pause=c.pause.bind(c),v.resume=c.resume.bind(c),v.stop=v,v}function Mo(e,t=1/0,r){if(t<=0||!Ht(e)||e.__v_skip||(r=r||new Map,(r.get(e)||0)>=t))return e;if(r.set(e,t),t--,er(e))Mo(e.value,t,r);else if(Le(e))for(let i=0;i<e.length;i++)Mo(e[i],t,r);else if(Mc(e)||Md(e))e.forEach(i=>{Mo(i,t,r)});else if(Ky(e)){for(const i in e)Mo(e[i],t,r);for(const i of Object.getOwnPropertySymbols(e))Object.prototype.propertyIsEnumerable.call(e,i)&&Mo(e[i],t,r)}return e}/** 10* @vue/runtime-core v3.5.30 11* (c) 2018-present Yuxi (Evan) You and Vue contributors 12* @license MIT 13**/const BP=[];function eB(e){BP.push(e)}function tB(){BP.pop()}function rB(e,t){}const iB={SETUP_FUNCTION:0,0:"SETUP_FUNCTION",RENDER_FUNCTION:1,1:"RENDER_FUNCTION",NATIVE_EVENT_HANDLER:5,5:"NATIVE_EVENT_HANDLER",COMPONENT_EVENT_HANDLER:6,6:"COMPONENT_EVENT_HANDLER",VNODE_HOOK:7,7:"VNODE_HOOK",DIRECTIVE_HOOK:8,8:"DIRECTIVE_HOOK",TRANSITION_HOOK:9,9:"TRANSITION_HOOK",APP_ERROR_HANDLER:10,10:"APP_ERROR_HANDLER",APP_WARN_HANDLER:11,11:"APP_WARN_HANDLER",FUNCTION_REF:12,12:"FUNCTION_REF",ASYNC_COMPONENT_LOADER:13,13:"ASYNC_COMPONENT_LOADER",SCHEDULER:14,14:"SCHEDULER",COMPONENT_UPDATE:15,15:"COMPONENT_UPDATE",APP_UNMOUNT_CLEANUP:16,16:"APP_UNMOUNT_CLEANUP"},nB={sp:"serverPrefetch hook",bc:"beforeCreate hook",c:"created hook",bm:"beforeMount hook",m:"mounted hook",bu:"beforeUpdate hook",u:"updated",bum:"beforeUnmount hook",um:"unmounted hook",a:"activated hook",da:"deactivated hook",ec:"errorCaptured hook",rtc:"renderTracked hook",rtg:"renderTriggered hook",0:"setup function",1:"render function",2:"watcher getter",3:"watcher callback",4:"watcher cleanup function",5:"native event handler",6:"component event handler",7:"vnode hook",8:"directive hook",9:"transition hook",10:"app errorHandler",11:"app warnHandler",12:"ref function",13:"async component loader",14:"scheduler flush",15:"component update",16:"app unmount cleanup function"};function Bh(e,t,r,i){try{return i?e(...i):e()}catch(n){Ac(n,t,r)}}function is(e,t,r,i){if(nt(e)){const n=Bh(e,t,r,i);return n&&y3(n)&&n.catch(a=>{Ac(a,t,r)}),n}if(Le(e)){const n=[];for(let a=0;a<e.length;a++)n.push(is(e[a],t,r,i));return n}}function Ac(e,t,r,i=!0){const n=t?t.vnode:null,{errorHandler:a,throwUnhandledErrorInProduction:s}=t&&t.appContext.config||Dt;if(t){let o=t.parent;const l=t.proxy,u=`https://vuejs.org/error-reference/#runtime-${r}`;for(;o;){const c=o.ec;if(c){for(let d=0;d<c.length;d++)if(c[d](e,l,u)===!1)return}o=o.parent}if(a){Xo(),Bh(a,null,10,[e,l,u]),Jo();return}}aB(e,r,n,i,s)}function aB(e,t,r,i=!0,n=!1){if(n)throw e;console.error(e)}const Tn=[];let Ns=-1;const Dd=[];let Il=null,nd=0;const jP=Promise.resolve();let k_=null;function Bi(e){const t=k_||jP;return e?t.then(this?e.bind(this):e):t}function sB(e){let t=Ns+1,r=Tn.length;for(;t<r;){const i=t+r>>>1,n=Tn[i],a=Vp(n);a<e||a===e&&n.flags&2?t=i+1:r=i}return t}function C3(e){if(!(e.flags&1)){const t=Vp(e),r=Tn[Tn.length-1];!r||!(e.flags&2)&&t>=Vp(r)?Tn.push(e):Tn.splice(sB(t),0,e),e.flags|=1,UP()}}function UP(){k_||(k_=jP.then(VP))}function Up(e){Le(e)?Dd.push(...e):Il&&e.id===-1?Il.splice(nd+1,0,e):e.flags&1||(Dd.push(e),e.flags|=1),UP()}function WS(e,t,r=Ns+1){for(;r<Tn.length;r++){const i=Tn[r];if(i&&i.flags&2){if(e&&i.id!==e.uid)continue;Tn.splice(r,1),r--,i.flags&4&&(i.flags&=-2),i(),i.flags&4||(i.flags&=-2)}}}function E_(e){if(Dd.length){const t=[...new Set(Dd)].sort((r,i)=>Vp(r)-Vp(i));if(Dd.length=0,Il){Il.push(...t);return}for(Il=t,nd=0;nd<Il.length;nd++){const r=Il[nd];r.flags&4&&(r.flags&=-2),r.flags&8||r(),r.flags&=-2}Il=null,nd=0}}const Vp=e=>e.id==null?e.flags&2?-1:1/0:e.id;function VP(e){try{for(Ns=0;Ns<Tn.length;Ns++){const t=Tn[Ns];t&&!(t.flags&8)&&(t.flags&4&&(t.flags&=-2),Bh(t,t.i,t.i?15:14),t.flags&4||(t.flags&=-2))}}finally{for(;Ns<Tn.length;Ns++){const t=Tn[Ns];t&&(t.flags&=-2)}Ns=-1,Tn.length=0,E_(),k_=null,(Tn.length||Dd.length)&&VP()}}let ad,Ag=[];function qP(e,t){var r,i;ad=e,ad?(ad.enabled=!0,Ag.forEach(({event:n,args:a})=>ad.emit(n,...a)),Ag=[]):typeof window<"u"&&window.HTMLElement&&!((i=(r=window.navigator)==null?void 0:r.userAgent)!=null&&i.includes("jsdom"))?((t.__VUE_DEVTOOLS_HOOK_REPLAY__=t.__VUE_DEVTOOLS_HOOK_REPLAY__||[]).push(a=>{qP(a,t)}),setTimeout(()=>{ad||(t.__VUE_DEVTOOLS_HOOK_REPLAY__=null,Ag=[])},3e3)):Ag=[]}let ji=null,o1=null;function qp(e){const t=ji;return ji=e,o1=e&&e.type.__scopeId||null,t}function oB(e){o1=e}function lB(){o1=null}const uB=e=>_t;function _t(e,t=ji,r){if(!t||e._n)return e;const i=(...n)=>{i._d&&Wp(-1);const a=qp(t);let s;try{s=e(...n)}finally{qp(a),i._d&&Wp(1)}return s};return i._n=!0,i._c=!0,i._d=!0,i}function it(e,t){if(ji===null)return e;const r=Hm(ji),i=e.dirs||(e.dirs=[]);for(let n=0;n<t.length;n++){let[a,s,o,l=Dt]=t[n];a&&(nt(a)&&(a={mounted:a,updated:a}),a.deep&&Mo(s),i.push({dir:a,instance:r,value:s,oldValue:void 0,arg:o,modifiers:l}))}return e}function Bs(e,t,r,i){const n=e.dirs,a=t&&t.dirs;for(let s=0;s<n.length;s++){const o=n[s];a&&(o.oldValue=a[s].value);let l=o.dir[i];l&&(Xo(),is(l,r,8,[e.el,o,e,t]),Jo())}}function xa(e,t){if(Ni){let r=Ni.provides;const i=Ni.parent&&Ni.parent.provides;i===r&&(r=Ni.provides=Object.create(i)),r[e]=t}}function Gi(e,t,r=!1){const i=pn();if(i||Zu){let n=Zu?Zu._context.provides:i?i.parent==null||i.ce?i.vnode.appContext&&i.vnode.appContext.provides:i.parent.provides:void 0;if(n&&e in n)return n[e];if(arguments.length>1)return r&&nt(t)?t.call(i&&i.proxy):t}}function GP(){return!!(pn()||Zu)}const HP=Symbol.for("v-scx"),YP=()=>Gi(HP);function Rd(e,t){return qm(e,null,t)}function cB(e,t){return qm(e,null,{flush:"post"})}function WP(e,t){return qm(e,null,{flush:"sync"})}function tt(e,t,r){return qm(e,t,r)}function qm(e,t,r=Dt){const{immediate:i,deep:n,flush:a,once:s}=r,o=Ct({},r),l=t&&i||!t&&a!=="post";let u;if(_c){if(a==="sync"){const f=YP();u=f.__watcherHandles||(f.__watcherHandles=[])}else if(!l){const f=()=>{};return f.stop=qi,f.resume=qi,f.pause=qi,f}}const c=Ni;o.call=(f,p,m)=>is(f,c,p,m);let d=!1;a==="post"?o.scheduler=f=>{Jr(f,c&&c.suspense)}:a!=="sync"&&(d=!0,o.scheduler=(f,p)=>{p?f():C3(f)}),o.augmentJob=f=>{t&&(f.flags|=4),d&&(f.flags|=2,c&&(f.id=c.uid,f.i=c))};const h=QN(e,t,o);return _c&&(u?u.push(h):l&&h()),h}function dB(e,t,r){const i=this.proxy,n=ft(e)?e.includes(".")?ZP(i,e):()=>i[e]:e.bind(i,i);let a;nt(t)?a=t:(a=t.handler,r=t);const s=Uh(this),o=qm(n,a.bind(i),r);return s(),o}function ZP(e,t){const r=t.split(".");return()=>{let i=e;for(let n=0;n<r.length&&i;n++)i=i[r[n]];return i}}const KP=Symbol("_vte"),XP=e=>e.__isTeleport,np=e=>e&&(e.disabled||e.disabled===""),ZS=e=>e&&(e.defer||e.defer===""),KS=e=>typeof SVGElement<"u"&&e instanceof SVGElement,XS=e=>typeof MathMLElement=="function"&&e instanceof MathMLElement,m2=(e,t)=>{const r=e&&e.to;return ft(r)?t?t(r):null:r},JP={name:"Teleport",__isTeleport:!0,process(e,t,r,i,n,a,s,o,l,u){const{mc:c,pc:d,pbc:h,o:{insert:f,querySelector:p,createText:m,createComment:g}}=u,v=np(t.props);let{shapeFlag:x,children:_,dynamicChildren:y}=t;if(e==null){const w=t.el=m(""),$=t.anchor=m("");f(w,r,i),f($,r,i);const S=(C,I)=>{x&16&&c(_,C,I,n,a,s,o,l)},E=()=>{const C=t.target=m2(t.props,p),I=g2(C,t,m,f);C&&(s!=="svg"&&KS(C)?s="svg":s!=="mathml"&&XS(C)&&(s="mathml"),n&&n.isCE&&(n.ce._teleportTargets||(n.ce._teleportTargets=new Set)).add(C),v||(S(C,I),L0(t,!1)))};v&&(S(r,$),L0(t,!0)),ZS(t.props)?(t.el.__isMounted=!1,Jr(()=>{E(),delete t.el.__isMounted},a)):E()}else{if(ZS(t.props)&&e.el.__isMounted===!1){Jr(()=>{JP.process(e,t,r,i,n,a,s,o,l,u)},a);return}t.el=e.el,t.targetStart=e.targetStart;const w=t.anchor=e.anchor,$=t.target=e.target,S=t.targetAnchor=e.targetAnchor,E=np(e.props),C=E?r:$,I=E?w:S;if(s==="svg"||KS($)?s="svg":(s==="mathml"||XS($))&&(s="mathml"),y?(h(e.dynamicChildren,y,C,n,a,s,o),z3(e,t,!0)):l||d(e,t,C,I,n,a,s,o,!1),v)E?t.props&&e.props&&t.props.to!==e.props.to&&(t.props.to=e.props.to):Dg(t,r,w,u,1);else if((t.props&&t.props.to)!==(e.props&&e.props.to)){const P=t.target=m2(t.props,p);P&&Dg(t,P,null,u,0)}else E&&Dg(t,$,S,u,1);L0(t,v)}},remove(e,t,r,{um:i,o:{remove:n}},a){const{shapeFlag:s,children:o,anchor:l,targetStart:u,targetAnchor:c,target:d,props:h}=e;if(d&&(n(u),n(c)),a&&n(l),s&16){const f=a||!np(h);for(let p=0;p<o.length;p++){const m=o[p];i(m,t,r,f,!!m.dynamicChildren)}}},move:Dg,hydrate:hB};function Dg(e,t,r,{o:{insert:i},m:n},a=2){a===0&&i(e.targetAnchor,t,r);const{el:s,anchor:o,shapeFlag:l,children:u,props:c}=e,d=a===2;if(d&&i(s,t,r),(!d||np(c))&&l&16)for(let h=0;h<u.length;h++)n(u[h],t,r,2);d&&i(o,t,r)}function hB(e,t,r,i,n,a,{o:{nextSibling:s,parentNode:o,querySelector:l,insert:u,createText:c}},d){function h(g,v){let x=v;for(;x;){if(x&&x.nodeType===8){if(x.data==="teleport start anchor")t.targetStart=x;else if(x.data==="teleport anchor"){t.targetAnchor=x,g._lpa=t.targetAnchor&&s(t.targetAnchor);break}}x=s(x)}}function f(g,v){v.anchor=d(s(g),v,o(g),r,i,n,a)}const p=t.target=m2(t.props,l),m=np(t.props);if(p){const g=p._lpa||p.firstChild;t.shapeFlag&16&&(m?(f(e,t),h(p,g),t.targetAnchor||g2(p,t,c,u,o(e)===p?e:null)):(t.anchor=s(e),h(p,g),t.targetAnchor||g2(p,t,c,u),d(g&&s(g),t,p,r,i,n,a))),L0(t,m)}else m&&t.shapeFlag&16&&(f(e,t),t.targetStart=e,t.targetAnchor=s(e));return t.anchor&&s(t.anchor)}const QP=JP;function L0(e,t){const r=e.ctx;if(r&&r.ut){let i,n;for(t?(i=e.el,n=e.anchor):(i=e.targetStart,n=e.targetAnchor);i&&i!==n;)i.nodeType===1&&i.setAttribute("data-v-owner",r.uid),i=i.nextSibling;r.ut()}}function g2(e,t,r,i,n=null){const a=t.targetStart=r(""),s=t.targetAnchor=r("");return a[KP]=s,e&&(i(a,e,n),i(s,e,n)),s}const js=Symbol("_leaveCb"),uf=Symbol("_enterCb");function k3(){const e={isMounted:!1,isLeaving:!1,isUnmounting:!1,leavingVNodes:new Map};return or(()=>{e.isMounted=!0}),ra(()=>{e.isUnmounting=!0}),e}const Ma=[Function,Array],E3={mode:String,appear:Boolean,persisted:Boolean,onBeforeEnter:Ma,onEnter:Ma,onAfterEnter:Ma,onEnterCancelled:Ma,onBeforeLeave:Ma,onLeave:Ma,onAfterLeave:Ma,onLeaveCancelled:Ma,onBeforeAppear:Ma,onAppear:Ma,onAfterAppear:Ma,onAppearCancelled:Ma},eM=e=>{const t=e.subTree;return t.component?eM(t.component):t},fB={name:"BaseTransition",props:E3,setup(e,{slots:t}){const r=pn(),i=k3();return()=>{const n=t.default&&l1(t.default(),!0);if(!n||!n.length)return;const a=tM(n),s=Ft(e),{mode:o}=s;if(i.isLeaving)return Ev(a);const l=JS(a);if(!l)return Ev(a);let u=ih(l,s,i,r,d=>u=d);l.type!==ti&&Qo(l,u);let c=r.subTree&&JS(r.subTree);if(c&&c.type!==ti&&!gs(c,l)&&eM(r).type!==ti){let d=ih(c,s,i,r);if(Qo(c,d),o==="out-in"&&l.type!==ti)return i.isLeaving=!0,d.afterLeave=()=>{i.isLeaving=!1,r.job.flags&8||r.update(),delete d.afterLeave,c=void 0},Ev(a);o==="in-out"&&l.type!==ti?d.delayLeave=(h,f,p)=>{const m=iM(i,c);m[String(c.key)]=c,h[js]=()=>{f(),h[js]=void 0,delete u.delayedLeave,c=void 0},u.delayedLeave=()=>{p(),delete u.delayedLeave,c=void 0}}:c=void 0}else c&&(c=void 0);return a}}};function tM(e){let t=e[0];if(e.length>1){for(const r of e)if(r.type!==ti){t=r;break}}return t}const rM=fB;function iM(e,t){const{leavingVNodes:r}=e;let i=r.get(t.type);return i||(i=Object.create(null),r.set(t.type,i)),i}function ih(e,t,r,i,n){const{appear:a,mode:s,persisted:o=!1,onBeforeEnter:l,onEnter:u,onAfterEnter:c,onEnterCancelled:d,onBeforeLeave:h,onLeave:f,onAfterLeave:p,onLeaveCancelled:m,onBeforeAppear:g,onAppear:v,onAfterAppear:x,onAppearCancelled:_}=t,y=String(e.key),w=iM(r,e),$=(C,I)=>{C&&is(C,i,9,I)},S=(C,I)=>{const P=I[1];$(C,I),Le(C)?C.every(T=>T.length<=1)&&P():C.length<=1&&P()},E={mode:s,persisted:o,beforeEnter(C){let I=l;if(!r.isMounted)if(a)I=g||l;else return;C[js]&&C[js](!0);const P=w[y];P&&gs(e,P)&&P.el[js]&&P.el[js](),$(I,[C])},enter(C){if(w[y]===e)return;let I=u,P=c,T=d;if(!r.isMounted)if(a)I=v||u,P=x||c,T=_||d;else return;let D=!1;C[uf]=z=>{D||(D=!0,z?$(T,[C]):$(P,[C]),E.delayedLeave&&E.delayedLeave(),C[uf]=void 0)};const A=C[uf].bind(null,!1);I?S(I,[C,A]):A()},leave(C,I){const P=String(e.key);if(C[uf]&&C[uf](!0),r.isUnmounting)return I();$(h,[C]);let T=!1;C[js]=A=>{T||(T=!0,I(),A?$(m,[C]):$(p,[C]),C[js]=void 0,w[P]===e&&delete w[P])};const D=C[js].bind(null,!1);w[P]=e,f?S(f,[C,D]):D()},clone(C){const I=ih(C,t,r,i,n);return n&&n(I),I}};return E}function Ev(e){if(Gm(e))return e=ks(e),e.children=null,e}function JS(e){if(!Gm(e))return XP(e.type)&&e.children?tM(e.children):e;if(e.component)return e.component.subTree;const{shapeFlag:t,children:r}=e;if(r){if(t&16)return r[0];if(t&32&&nt(r.default))return r.default()}}function Qo(e,t){e.shapeFlag&6&&e.component?(e.transition=t,Qo(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 l1(e,t=!1,r){let i=[],n=0;for(let a=0;a<e.length;a++){let s=e[a];const o=r==null?s.key:String(r)+String(s.key!=null?s.key:a);s.type===xe?(s.patchFlag&128&&n++,i=i.concat(l1(s.children,t,o))):(t||s.type!==ti)&&i.push(o!=null?ks(s,{key:o}):s)}if(n>1)for(let a=0;a<i.length;a++)i[a].patchFlag=-2;return i}function fr(e,t){return nt(e)?Ct({name:e.name},t,{setup:e}):e}function nM(){const e=pn();return e?(e.appContext.config.idPrefix||"v")+"-"+e.ids[0]+e.ids[1]++:""}function P3(e){e.ids=[e.ids[0]+e.ids[2]+++"-",0,0]}function pB(e){const t=pn(),r=Yu(null);if(t){const n=t.refs===Dt?t.refs={}:t.refs;Object.defineProperty(n,e,{enumerable:!0,get:()=>r.value,set:a=>r.value=a})}return r}function QS(e,t){let r;return!!((r=Object.getOwnPropertyDescriptor(e,t))&&!r.configurable)}const P_=new WeakMap;function Od(e,t,r,i,n=!1){if(Le(e)){e.forEach((m,g)=>Od(m,t&&(Le(t)?t[g]:t),r,i,n));return}if(qo(i)&&!n){i.shapeFlag&512&&i.type.__asyncResolved&&i.component.subTree.component&&Od(e,t,r,i.component.subTree);return}const a=i.shapeFlag&4?Hm(i.component):i.el,s=n?null:a,{i:o,r:l}=e,u=t&&t.r,c=o.refs===Dt?o.refs={}:o.refs,d=o.setupState,h=Ft(d),f=d===Dt?_d:m=>QS(c,m)?!1:Kt(h,m),p=(m,g)=>!(g&&QS(c,g));if(u!=null&&u!==l){if(e5(t),ft(u))c[u]=null,f(u)&&(d[u]=null);else if(er(u)){const m=t;p(u,m.k)&&(u.value=null),m.k&&(c[m.k]=null)}}if(nt(l))Bh(l,o,12,[s,c]);else{const m=ft(l),g=er(l);if(m||g){const v=()=>{if(e.f){const x=m?f(l)?d[l]:c[l]:p()||!e.k?l.value:c[e.k];if(n)Le(x)&&_3(x,a);else if(Le(x))x.includes(a)||x.push(a);else if(m)c[l]=[a],f(l)&&(d[l]=c[l]);else{const _=[a];p(l,e.k)&&(l.value=_),e.k&&(c[e.k]=_)}}else m?(c[l]=s,f(l)&&(d[l]=s)):g&&(p(l,e.k)&&(l.value=s),e.k&&(c[e.k]=s))};if(s){const x=()=>{v(),P_.delete(e)};x.id=-1,P_.set(e,x),Jr(x,r)}else e5(e),v()}}}function e5(e){const t=P_.get(e);t&&(t.flags|=8,P_.delete(e))}let t5=!1;const qc=()=>{t5||(console.error("Hydration completed but contains mismatches."),t5=!0)},mB=e=>e.namespaceURI.includes("svg")&&e.tagName!=="foreignObject",gB=e=>e.namespaceURI.includes("MathML"),Rg=e=>{if(e.nodeType===1){if(mB(e))return"svg";if(gB(e))return"mathml"}},yd=e=>e.nodeType===8;function _B(e){const{mt:t,p:r,o:{patchProp:i,createText:n,nextSibling:a,parentNode:s,remove:o,insert:l,createComment:u}}=e,c=(_,y)=>{if(!y.hasChildNodes()){r(null,_,y),E_(),y._vnode=_;return}d(y.firstChild,_,null,null,null),E_(),y._vnode=_},d=(_,y,w,$,S,E=!1)=>{E=E||!!y.dynamicChildren;const C=yd(_)&&_.data==="[",I=()=>m(_,y,w,$,S,C),{type:P,ref:T,shapeFlag:D,patchFlag:A}=y;let z=_.nodeType;y.el=_,A===-2&&(E=!1,y.dynamicChildren=null);let R=null;switch(P){case Hl:z!==3?y.children===""?(l(y.el=n(""),s(_),_),R=_):R=I():(_.data!==y.children&&(qc(),_.data=y.children),R=a(_));break;case ti:x(_)?(R=a(_),v(y.el=_.content.firstChild,_,w)):z!==8||C?R=I():R=a(_);break;case Ku:if(C&&(_=a(_),z=_.nodeType),z===1||z===3){R=_;const O=!y.children.length;for(let V=0;V<y.staticCount;V++)O&&(y.children+=R.nodeType===1?R.outerHTML:R.data),V===y.staticCount-1&&(y.anchor=R),R=a(R);return C?a(R):R}else I();break;case xe:C?R=p(_,y,w,$,S,E):R=I();break;default:if(D&1)(z!==1||y.type.toLowerCase()!==_.tagName.toLowerCase())&&!x(_)?R=I():R=h(_,y,w,$,S,E);else if(D&6){y.slotScopeIds=S;const O=s(_);if(C?R=g(_):yd(_)&&_.data==="teleport start"?R=g(_,_.data,"teleport end"):R=a(_),t(y,O,null,w,$,Rg(O),E),qo(y)&&!y.type.__asyncResolved){let V;C?(V=be(xe),V.anchor=R?R.previousSibling:O.lastChild):V=_.nodeType===3?Ze(""):be("div"),V.el=_,y.component.subTree=V}}else D&64?z!==8?R=I():R=y.type.hydrate(_,y,w,$,S,E,e,f):D&128&&(R=y.type.hydrate(_,y,w,$,Rg(s(_)),S,E,e,d))}return T!=null&&Od(T,null,$,y),R},h=(_,y,w,$,S,E)=>{E=E||!!y.dynamicChildren;const{type:C,props:I,patchFlag:P,shapeFlag:T,dirs:D,transition:A}=y,z=C==="input"||C==="option";if(z||P!==-1){D&&Bs(y,null,w,"created");let R=!1;if(x(_)){R=DM(null,A)&&w&&w.vnode.props&&w.vnode.props.appear;const V=_.content.firstChild;if(R){const Y=V.getAttribute("class");Y&&(V.$cls=Y),A.beforeEnter(V)}v(V,_,w),y.el=_=V}if(T&16&&!(I&&(I.innerHTML||I.textContent))){let V=f(_.firstChild,y,_,w,$,S,E);for(;V;){Og(_,1)||qc();const Y=V;V=V.nextSibling,o(Y)}}else if(T&8){let V=y.children;V[0]===` 14`&&(_.tagName==="PRE"||_.tagName==="TEXTAREA")&&(V=V.slice(1));const{textContent:Y}=_;Y!==V&&Y!==V.replace(/\r\n|\r/g,` 15`)&&(Og(_,0)||qc(),_.textContent=y.children)}if(I){if(z||!E||P&48){const V=_.tagName.includes("-");for(const Y in I)(z&&(Y.endsWith("value")||Y==="indeterminate")||Pc(Y)&&!Vo(Y)||Y[0]==="."||V&&!Vo(Y))&&i(_,Y,null,I[Y],void 0,w)}else if(I.onClick)i(_,"onClick",null,I.onClick,void 0,w);else if(P&4&&xs(I.style))for(const V in I.style)I.style[V]}let O;(O=I&&I.onVnodeBeforeMount)&&Ln(O,w,y),D&&Bs(y,null,w,"beforeMount"),((O=I&&I.onVnodeMounted)||D||R)&&FM(()=>{O&&Ln(O,w,y),R&&A.enter(_),D&&Bs(y,null,w,"mounted")},$)}return _.nextSibling},f=(_,y,w,$,S,E,C)=>{C=C||!!y.dynamicChildren;const I=y.children,P=I.length;for(let T=0;T<P;T++){const D=C?I[T]:I[T]=Bn(I[T]),A=D.type===Hl;_?(A&&!C&&T+1<P&&Bn(I[T+1]).type===Hl&&(l(n(_.data.slice(D.children.length)),w,a(_)),_.data=D.children),_=d(_,D,$,S,E,C)):A&&!D.children?l(D.el=n(""),w):(Og(w,1)||qc(),r(null,D,w,null,$,S,Rg(w),E))}return _},p=(_,y,w,$,S,E)=>{const{slotScopeIds:C}=y;C&&(S=S?S.concat(C):C);const I=s(_),P=f(a(_),y,I,w,$,S,E);return P&&yd(P)&&P.data==="]"?a(y.anchor=P):(qc(),l(y.anchor=u("]"),I,P),P)},m=(_,y,w,$,S,E)=>{if(Og(_.parentElement,1)||qc(),y.el=null,E){const P=g(_);for(;;){const T=a(_);if(T&&T!==P)o(T);else break}}const C=a(_),I=s(_);return o(_),r(null,y,I,C,w,$,Rg(I),S),w&&(w.vnode.el=y.el,h1(w,y.el)),C},g=(_,y="[",w="]")=>{let $=0;for(;_;)if(_=a(_),_&&yd(_)&&(_.data===y&&$++,_.data===w)){if($===0)return a(_);$--}return _},v=(_,y,w)=>{const $=y.parentNode;$&&$.replaceChild(_,y);let S=w;for(;S;)S.vnode.el===y&&(S.vnode.el=S.subTree.el=_),S=S.parent},x=_=>_.nodeType===1&&_.tagName==="TEMPLATE";return[c,d]}const r5="data-allow-mismatch",yB={0:"text",1:"children",2:"class",3:"style",4:"attribute"};function Og(e,t){if(t===0||t===1)for(;e&&!e.hasAttribute(r5);)e=e.parentElement;const r=e&&e.getAttribute(r5);if(r==null)return!1;if(r==="")return!0;{const i=r.split(",");return t===0&&i.includes("children")?!0:i.includes(yB[t])}}const vB=e1().requestIdleCallback||(e=>setTimeout(e,1)),bB=e1().cancelIdleCallback||(e=>clearTimeout(e)),xB=(e=1e4)=>t=>{const r=vB(t,{timeout:e});return()=>bB(r)};function wB(e){const{top:t,left:r,bottom:i,right:n}=e.getBoundingClientRect(),{innerHeight:a,innerWidth:s}=window;return(t>0&&t<a||i>0&&i<a)&&(r>0&&r<s||n>0&&n<s)}const $B=e=>(t,r)=>{const i=new IntersectionObserver(n=>{for(const a of n)if(a.isIntersecting){i.disconnect(),t();break}},e);return r(n=>{if(n instanceof Element){if(wB(n))return t(),i.disconnect(),!1;i.observe(n)}}),()=>i.disconnect()},SB=e=>t=>{if(e){const r=matchMedia(e);if(r.matches)t();else return r.addEventListener("change",t,{once:!0}),()=>r.removeEventListener("change",t)}},TB=(e=[])=>(t,r)=>{ft(e)&&(e=[e]);let i=!1;const n=s=>{i||(i=!0,a(),t(),s.target.dispatchEvent(new s.constructor(s.type,s)))},a=()=>{r(s=>{for(const o of e)s.removeEventListener(o,n)})};return r(s=>{for(const o of e)s.addEventListener(o,n,{once:!0})}),a};function CB(e,t){if(yd(e)&&e.data==="["){let r=1,i=e.nextSibling;for(;i;){if(i.nodeType===1){if(t(i)===!1)break}else if(yd(i))if(i.data==="]"){if(--r===0)break}else i.data==="["&&r++;i=i.nextSibling}}else t(e)}const qo=e=>!!e.type.__asyncLoader;function kB(e){nt(e)&&(e={loader:e});const{loader:t,loadingComponent:r,errorComponent:i,delay:n=200,hydrate:a,timeout:s,suspensible:o=!0,onError:l}=e;let u=null,c,d=0;const h=()=>(d++,u=null,f()),f=()=>{let p;return u||(p=u=t().catch(m=>{if(m=m instanceof Error?m:new Error(String(m)),l)return new Promise((g,v)=>{l(m,()=>g(h()),()=>v(m),d+1)});throw m}).then(m=>p!==u&&u?u:(m&&(m.__esModule||m[Symbol.toStringTag]==="Module")&&(m=m.default),c=m,m)))};return fr({name:"AsyncComponentWrapper",__asyncLoader:f,__asyncHydrate(p,m,g){let v=!1;(m.bu||(m.bu=[])).push(()=>v=!0);const x=()=>{v||g()},_=a?()=>{const y=a(x,w=>CB(p,w));y&&(m.bum||(m.bum=[])).push(y)}:x;c?_():f().then(()=>!m.isUnmounted&&_())},get __asyncResolved(){return c},setup(){const p=Ni;if(P3(p),c)return()=>Lg(c,p);const m=_=>{u=null,Ac(_,p,13,!i)};if(o&&p.suspense||_c)return f().then(_=>()=>Lg(_,p)).catch(_=>(m(_),()=>i?be(i,{error:_}):null));const g=se(!1),v=se(),x=se(!!n);return n&&setTimeout(()=>{x.value=!1},n),s!=null&&setTimeout(()=>{if(!g.value&&!v.value){const _=new Error(`Async component timed out after ${s}ms.`);m(_),v.value=_}},s),f().then(()=>{g.value=!0,p.parent&&Gm(p.parent.vnode)&&p.parent.update()}).catch(_=>{m(_),v.value=_}),()=>{if(g.value&&c)return Lg(c,p);if(v.value&&i)return be(i,{error:v.value});if(r&&!x.value)return Lg(r,p)}}})}function Lg(e,t){const{ref:r,props:i,children:n,ce:a}=t.vnode,s=be(e,i,n);return s.ref=r,s.ce=a,delete t.vnode.ce,s}const Gm=e=>e.type.__isKeepAlive,EB={name:"KeepAlive",__isKeepAlive:!0,props:{include:[String,RegExp,Array],exclude:[String,RegExp,Array],max:[String,Number]},setup(e,{slots:t}){const r=pn(),i=r.ctx;if(!i.renderer)return()=>{const x=t.default&&t.default();return x&&x.length===1?x[0]:x};const n=new Map,a=new Set;let s=null;const o=r.suspense,{renderer:{p:l,m:u,um:c,o:{createElement:d}}}=i,h=d("div");i.activate=(x,_,y,w,$)=>{const S=x.component;u(x,_,y,0,o),l(S.vnode,x,_,y,S,o,w,x.slotScopeIds,$),Jr(()=>{S.isDeactivated=!1,S.a&&Ad(S.a);const E=x.props&&x.props.onVnodeMounted;E&&Ln(E,S.parent,x)},o)},i.deactivate=x=>{const _=x.component;I_(_.m),I_(_.a),u(x,h,null,1,o),Jr(()=>{_.da&&Ad(_.da);const y=x.props&&x.props.onVnodeUnmounted;y&&Ln(y,_.parent,x),_.isDeactivated=!0},o)};function f(x){Pv(x),c(x,r,o,!0)}function p(x){n.forEach((_,y)=>{const w=T2(qo(_)?_.type.__asyncResolved||{}:_.type);w&&!x(w)&&m(y)})}function m(x){const _=n.get(x);_&&(!s||!gs(_,s))?f(_):s&&Pv(s),n.delete(x),a.delete(x)}tt(()=>[e.include,e.exclude],([x,_])=>{x&&p(y=>zf(x,y)),_&&p(y=>!zf(_,y))},{flush:"post",deep:!0});let g=null;const v=()=>{g!=null&&(A_(r.subTree.type)?Jr(()=>{n.set(g,Fg(r.subTree))},r.subTree.suspense):n.set(g,Fg(r.subTree)))};return or(v),jh(v),ra(()=>{n.forEach(x=>{const{subTree:_,suspense:y}=r,w=Fg(_);if(x.type===w.type&&x.key===w.key){Pv(w);const $=w.component.da;$&&Jr($,y);return}f(x)})}),()=>{if(g=null,!t.default)return s=null;const x=t.default(),_=x[0];if(x.length>1)return s=null,x;if(!el(_)||!(_.shapeFlag&4)&&!(_.shapeFlag&128))return s=null,_;let y=Fg(_);if(y.type===ti)return s=null,y;const w=y.type,$=T2(qo(y)?y.type.__asyncResolved||{}:w),{include:S,exclude:E,max:C}=e;if(S&&(!$||!zf(S,$))||E&&$&&zf(E,$))return y.shapeFlag&=-257,s=y,_;const I=y.key==null?w:y.key,P=n.get(I);return y.el&&(y=ks(y),_.shapeFlag&128&&(_.ssContent=y)),g=I,P?(y.el=P.el,y.component=P.component,y.transition&&Qo(y,y.transition),y.shapeFlag|=512,a.delete(I),a.add(I)):(a.add(I),C&&a.size>parseInt(C,10)&&m(a.values().next().value)),y.shapeFlag|=256,s=y,A_(_.type)?_:y}}},PB=EB;function zf(e,t){return Le(e)?e.some(r=>zf(r,t)):ft(e)?e.split(",").includes(t):Kz(e)?(e.lastIndex=0,e.test(t)):!1}function aM(e,t){oM(e,"a",t)}function sM(e,t){oM(e,"da",t)}function oM(e,t,r=Ni){const i=e.__wdc||(e.__wdc=()=>{let n=r;for(;n;){if(n.isDeactivated)return;n=n.parent}return e()});if(u1(t,i,r),r){let n=r.parent;for(;n&&n.parent;)Gm(n.parent.vnode)&&MB(i,t,r,n),n=n.parent}}function MB(e,t,r,i){const n=u1(t,e,i,!0);ss(()=>{_3(i[t],n)},r)}function Pv(e){e.shapeFlag&=-257,e.shapeFlag&=-513}function Fg(e){return e.shapeFlag&128?e.ssContent:e}function u1(e,t,r=Ni,i=!1){if(r){const n=r[e]||(r[e]=[]),a=t.__weh||(t.__weh=(...s)=>{Xo();const o=Uh(r),l=is(t,r,e,s);return o(),Jo(),l});return i?n.unshift(a):n.push(a),a}}const pl=e=>(t,r=Ni)=>{(!_c||e==="sp")&&u1(e,(...i)=>t(...i),r)},lM=pl("bm"),or=pl("m"),M3=pl("bu"),jh=pl("u"),ra=pl("bum"),ss=pl("um"),uM=pl("sp"),cM=pl("rtg"),dM=pl("rtc");function hM(e,t=Ni){u1("ec",e,t)}const I3="components",IB="directives";function qr(e,t){return D3(I3,e,!0,t)||e}const fM=Symbol.for("v-ndc");function c1(e){return ft(e)?D3(I3,e,!1)||e:e||fM}function A3(e){return D3(IB,e)}function D3(e,t,r=!0,i=!1){const n=ji||Ni;if(n){const a=n.type;if(e===I3){const o=T2(a,!1);if(o&&(o===t||o===ar(t)||o===Ic(ar(t))))return a}const s=i5(n[e]||a[e],t)||i5(n.appContext[e],t);return!s&&i?a:s}}function i5(e,t){return e&&(e[t]||e[ar(t)]||e[Ic(ar(t))])}function Me(e,t,r,i){let n;const a=r&&r[i],s=Le(e);if(s||ft(e)){const o=s&&xs(e);let l=!1,u=!1;o&&(l=!Gn(e),u=ao(e),e=i1(e)),n=new Array(e.length);for(let c=0,d=e.length;c<d;c++)n[c]=t(l?u?rh(Cs(e[c])):Cs(e[c]):e[c],c,void 0,a&&a[c])}else if(typeof e=="number"){n=new Array(e);for(let o=0;o<e;o++)n[o]=t(o+1,o,void 0,a&&a[o])}else if(Ht(e))if(e[Symbol.iterator])n=Array.from(e,(o,l)=>t(o,l,void 0,a&&a[l]));else{const o=Object.keys(e);n=new Array(o.length);for(let l=0,u=o.length;l<u;l++){const c=o[l];n[l]=t(e[c],c,l,a&&a[l])}}else n=[];return r&&(r[i]=n),n}function pM(e,t){for(let r=0;r<t.length;r++){const i=t[r];if(Le(i))for(let n=0;n<i.length;n++)e[i[n].name]=i[n].fn;else i&&(e[i.name]=i.key?(...n)=>{const a=i.fn(...n);return a&&(a.key=i.key),a}:i.fn)}return e}function ws(e,t,r={},i,n){if(ji.ce||ji.parent&&qo(ji.parent)&&ji.parent.ce){const u=Object.keys(r).length>0;return t!=="default"&&(r.name=t),k(),Mt(xe,null,[be("slot",r,i&&i())],u?-2:64)}let a=e[t];a&&a._c&&(a._d=!1),k();const s=a&&R3(a(r)),o=r.key||s&&s.key,l=Mt(xe,{key:(o&&!ea(o)?o:`_${t}`)+(!s&&i?"_fb":"")},s||(i?i():[]),s&&e._===1?64:-2);return!n&&l.scopeId&&(l.slotScopeIds=[l.scopeId+"-s"]),a&&a._c&&(a._d=!0),l}function R3(e){return e.some(t=>el(t)?!(t.type===ti||t.type===xe&&!R3(t.children)):!0)?e:null}function mM(e,t){const r={};for(const i in e)r[t&&/[A-Z]/.test(i)?`on:${i}`:Id(i)]=e[i];return r}const _2=e=>e?UM(e)?Hm(e):_2(e.parent):null,ap=Ct(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=>_2(e.parent),$root:e=>_2(e.root),$host:e=>e.ce,$emit:e=>e.emit,$options:e=>O3(e),$forceUpdate:e=>e.f||(e.f=()=>{C3(e.update)}),$nextTick:e=>e.n||(e.n=Bi.bind(e.proxy)),$watch:e=>dB.bind(e)}),Mv=(e,t)=>e!==Dt&&!e.__isScriptSetup&&Kt(e,t),y2={get({_:e},t){if(t==="__v_skip")return!0;const{ctx:r,setupState:i,data:n,props:a,accessCache:s,type:o,appContext:l}=e;if(t[0]!=="$"){const h=s[t];if(h!==void 0)switch(h){case 1:return i[t];case 2:return n[t];case 4:return r[t];case 3:return a[t]}else{if(Mv(i,t))return s[t]=1,i[t];if(n!==Dt&&Kt(n,t))return s[t]=2,n[t];if(Kt(a,t))return s[t]=3,a[t];if(r!==Dt&&Kt(r,t))return s[t]=4,r[t];v2&&(s[t]=0)}}const u=ap[t];let c,d;if(u)return t==="$attrs"&&an(e.attrs,"get",""),u(e);if((c=o.__cssModules)&&(c=c[t]))return c;if(r!==Dt&&Kt(r,t))return s[t]=4,r[t];if(d=l.config.globalProperties,Kt(d,t))return d[t]},set({_:e},t,r){const{data:i,setupState:n,ctx:a}=e;return Mv(n,t)?(n[t]=r,!0):i!==Dt&&Kt(i,t)?(i[t]=r,!0):Kt(e.props,t)||t[0]==="$"&&t.slice(1)in e?!1:(a[t]=r,!0)},has({_:{data:e,setupState:t,accessCache:r,ctx:i,appContext:n,props:a,type:s}},o){let l;return!!(r[o]||e!==Dt&&o[0]!=="$"&&Kt(e,o)||Mv(t,o)||Kt(a,o)||Kt(i,o)||Kt(ap,o)||Kt(n.config.globalProperties,o)||(l=s.__cssModules)&&l[o])},defineProperty(e,t,r){return r.get!=null?e._.accessCache[t]=0:Kt(r,"value")&&this.set(e,t,r.value,null),Reflect.defineProperty(e,t,r)}},AB=Ct({},y2,{get(e,t){if(t!==Symbol.unscopables)return y2.get(e,t,e)},has(e,t){return t[0]!=="_"&&!iN(t)}});function DB(){return null}function RB(){return null}function OB(e){}function LB(e){}function FB(){return null}function zB(){}function NB(e,t){return null}function BB(){return gM().slots}function jB(){return gM().attrs}function gM(e){const t=pn();return t.setupContext||(t.setupContext=HM(t))}function Gp(e){return Le(e)?e.reduce((t,r)=>(t[r]=null,t),{}):e}function UB(e,t){const r=Gp(e);for(const i in t){if(i.startsWith("__skip"))continue;let n=r[i];n?Le(n)||nt(n)?n=r[i]={type:n,default:t[i]}:n.default=t[i]:n===null&&(n=r[i]={default:t[i]}),n&&t[`__skip_${i}`]&&(n.skipFactory=!0)}return r}function Hp(e,t){return!e||!t?e||t:Le(e)&&Le(t)?e.concat(t):Ct({},Gp(e),Gp(t))}function VB(e,t){const r={};for(const i in e)t.includes(i)||Object.defineProperty(r,i,{enumerable:!0,get:()=>e[i]});return r}function qB(e){const t=pn(),r=_c;let i=e();R_(),r&&Fd(!1);const n=()=>{Uh(t),r&&Fd(!0)},a=()=>{pn()!==t&&t.scope.off(),R_(),r&&Fd(!1)};return y3(i)&&(i=i.catch(s=>{throw n(),Promise.resolve().then(()=>Promise.resolve().then(a)),s})),[i,()=>{n(),Promise.resolve().then(a)}]}let v2=!0;function GB(e){const t=O3(e),r=e.proxy,i=e.ctx;v2=!1,t.beforeCreate&&n5(t.beforeCreate,e,"bc");const{data:n,computed:a,methods:s,watch:o,provide:l,inject:u,created:c,beforeMount:d,mounted:h,beforeUpdate:f,updated:p,activated:m,deactivated:g,beforeDestroy:v,beforeUnmount:x,destroyed:_,unmounted:y,render:w,renderTracked:$,renderTriggered:S,errorCaptured:E,serverPrefetch:C,expose:I,inheritAttrs:P,components:T,directives:D,filters:A}=t;if(u&&HB(u,i,null),s)for(const O in s){const V=s[O];nt(V)&&(i[O]=V.bind(r))}if(n){const O=n.call(r,r);Ht(O)&&(e.data=An(O))}if(v2=!0,a)for(const O in a){const V=a[O],Y=nt(V)?V.bind(r,r):nt(V.get)?V.get.bind(r,r):qi,F=!nt(V)&&nt(V.set)?V.set.bind(r):qi,ae=H({get:Y,set:F});Object.defineProperty(i,O,{enumerable:!0,configurable:!0,get:()=>ae.value,set:ue=>ae.value=ue})}if(o)for(const O in o)_M(o[O],i,r,O);if(l){const O=nt(l)?l.call(r):l;Reflect.ownKeys(O).forEach(V=>{xa(V,O[V])})}c&&n5(c,e,"c");function R(O,V){Le(V)?V.forEach(Y=>O(Y.bind(r))):V&&O(V.bind(r))}if(R(lM,d),R(or,h),R(M3,f),R(jh,p),R(aM,m),R(sM,g),R(hM,E),R(dM,$),R(cM,S),R(ra,x),R(ss,y),R(uM,C),Le(I))if(I.length){const O=e.exposed||(e.exposed={});I.forEach(V=>{Object.defineProperty(O,V,{get:()=>r[V],set:Y=>r[V]=Y,enumerable:!0})})}else e.exposed||(e.exposed={});w&&e.render===qi&&(e.render=w),P!=null&&(e.inheritAttrs=P),T&&(e.components=T),D&&(e.directives=D),C&&P3(e)}function HB(e,t,r=qi){Le(e)&&(e=b2(e));for(const i in e){const n=e[i];let a;Ht(n)?"default"in n?a=Gi(n.from||i,n.default,!0):a=Gi(n.from||i):a=Gi(n),er(a)?Object.defineProperty(t,i,{enumerable:!0,configurable:!0,get:()=>a.value,set:s=>a.value=s}):t[i]=a}}function n5(e,t,r){is(Le(e)?e.map(i=>i.bind(t.proxy)):e.bind(t.proxy),t,r)}function _M(e,t,r,i){let n=i.includes(".")?ZP(r,i):()=>r[i];if(ft(e)){const a=t[e];nt(a)&&tt(n,a)}else if(nt(e))tt(n,e.bind(r));else if(Ht(e))if(Le(e))e.forEach(a=>_M(a,t,r,i));else{const a=nt(e.handler)?e.handler.bind(r):t[e.handler];nt(a)&&tt(n,a,e)}}function O3(e){const t=e.type,{mixins:r,extends:i}=t,{mixins:n,optionsCache:a,config:{optionMergeStrategies:s}}=e.appContext,o=a.get(t);let l;return o?l=o:!n.length&&!r&&!i?l=t:(l={},n.length&&n.forEach(u=>M_(l,u,s,!0)),M_(l,t,s)),Ht(t)&&a.set(t,l),l}function M_(e,t,r,i=!1){const{mixins:n,extends:a}=t;a&&M_(e,a,r,!0),n&&n.forEach(s=>M_(e,s,r,!0));for(const s in t)if(!(i&&s==="expose")){const o=YB[s]||r&&r[s];e[s]=o?o(e[s],t[s]):t[s]}return e}const YB={data:a5,props:s5,emits:s5,methods:Nf,computed:Nf,beforeCreate:vn,created:vn,beforeMount:vn,mounted:vn,beforeUpdate:vn,updated:vn,beforeDestroy:vn,beforeUnmount:vn,destroyed:vn,unmounted:vn,activated:vn,deactivated:vn,errorCaptured:vn,serverPrefetch:vn,components:Nf,directives:Nf,watch:ZB,provide:a5,inject:WB};function a5(e,t){return t?e?function(){return Ct(nt(e)?e.call(this,this):e,nt(t)?t.call(this,this):t)}:t:e}function WB(e,t){return Nf(b2(e),b2(t))}function b2(e){if(Le(e)){const t={};for(let r=0;r<e.length;r++)t[e[r]]=e[r];return t}return e}function vn(e,t){return e?[...new Set([].concat(e,t))]:t}function Nf(e,t){return e?Ct(Object.create(null),e,t):t}function s5(e,t){return e?Le(e)&&Le(t)?[...new Set([...e,...t])]:Ct(Object.create(null),Gp(e),Gp(t??{})):t}function ZB(e,t){if(!e)return t;if(!t)return e;const r=Ct(Object.create(null),e);for(const i in t)r[i]=vn(e[i],t[i]);return r}function yM(){return{app:null,config:{isNativeTag:_d,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 KB=0;function XB(e,t){return function(i,n=null){nt(i)||(i=Ct({},i)),n!=null&&!Ht(n)&&(n=null);const a=yM(),s=new WeakSet,o=[];let l=!1;const u=a.app={_uid:KB++,_component:i,_props:n,_container:null,_context:a,_instance:null,version:WM,get config(){return a.config},set config(c){},use(c,...d){return s.has(c)||(c&&nt(c.install)?(s.add(c),c.install(u,...d)):nt(c)&&(s.add(c),c(u,...d))),u},mixin(c){return a.mixins.includes(c)||a.mixins.push(c),u},component(c,d){return d?(a.components[c]=d,u):a.components[c]},directive(c,d){return d?(a.directives[c]=d,u):a.directives[c]},mount(c,d,h){if(!l){const f=u._ceVNode||be(i,n);return f.appContext=a,h===!0?h="svg":h===!1&&(h=void 0),d&&t?t(f,c):e(f,c,h),l=!0,u._container=c,c.__vue_app__=u,Hm(f.component)}},onUnmount(c){o.push(c)},unmount(){l&&(is(o,u._instance,16),e(null,u._container),delete u._container.__vue_app__)},provide(c,d){return a.provides[c]=d,u},runWithContext(c){const d=Zu;Zu=u;try{return c()}finally{Zu=d}}};return u}}let Zu=null;function Al(e,t,r=Dt){const i=pn(),n=ar(t),a=Un(t),s=vM(e,n),o=FP((l,u)=>{let c,d=Dt,h;return WP(()=>{const f=e[n];Oi(c,f)&&(c=f,u())}),{get(){return l(),r.get?r.get(c):c},set(f){const p=r.set?r.set(f):f;if(!Oi(p,c)&&!(d!==Dt&&Oi(f,d)))return;const m=i.vnode.props;m&&(t in m||n in m||a in m)&&(`onUpdate:${t}`in m||`onUpdate:${n}`in m||`onUpdate:${a}`in m)||(c=f,u()),i.emit(`update:${t}`,p),Oi(f,p)&&Oi(f,d)&&!Oi(p,h)&&u(),d=f,h=p}}});return o[Symbol.iterator]=()=>{let l=0;return{next(){return l<2?{value:l++?s||Dt:o,done:!1}:{done:!0}}}},o}const vM=(e,t)=>t==="modelValue"||t==="model-value"?e.modelModifiers:e[`${t}Modifiers`]||e[`${ar(t)}Modifiers`]||e[`${Un(t)}Modifiers`];function JB(e,t,...r){if(e.isUnmounted)return;const i=e.vnode.props||Dt;let n=r;const a=t.startsWith("update:"),s=a&&vM(i,t.slice(7));s&&(s.trim&&(n=r.map(c=>ft(c)?c.trim():c)),s.number&&(n=r.map(Qy)));let o,l=i[o=Id(t)]||i[o=Id(ar(t))];!l&&a&&(l=i[o=Id(Un(t))]),l&&is(l,e,6,n);const u=i[o+"Once"];if(u){if(!e.emitted)e.emitted={};else if(e.emitted[o])return;e.emitted[o]=!0,is(u,e,6,n)}}const QB=new WeakMap;function bM(e,t,r=!1){const i=r?QB:t.emitsCache,n=i.get(e);if(n!==void 0)return n;const a=e.emits;let s={},o=!1;if(!nt(e)){const l=u=>{const c=bM(u,t,!0);c&&(o=!0,Ct(s,c))};!r&&t.mixins.length&&t.mixins.forEach(l),e.extends&&l(e.extends),e.mixins&&e.mixins.forEach(l)}return!a&&!o?(Ht(e)&&i.set(e,null),null):(Le(a)?a.forEach(l=>s[l]=null):Ct(s,a),Ht(e)&&i.set(e,s),s)}function d1(e,t){return!e||!Pc(t)?!1:(t=t.slice(2).replace(/Once$/,""),Kt(e,t[0].toLowerCase()+t.slice(1))||Kt(e,Un(t))||Kt(e,t))}function F0(e){const{type:t,vnode:r,proxy:i,withProxy:n,propsOptions:[a],slots:s,attrs:o,emit:l,render:u,renderCache:c,props:d,data:h,setupState:f,ctx:p,inheritAttrs:m}=e,g=qp(e);let v,x;try{if(r.shapeFlag&4){const y=n||i,w=y;v=Bn(u.call(w,y,c,d,f,h,p)),x=o}else{const y=t;v=Bn(y.length>1?y(d,{attrs:o,slots:s,emit:l}):y(d,null)),x=t.props?o:tj(o)}}catch(y){sp.length=0,Ac(y,e,1),v=be(ti)}let _=v;if(x&&m!==!1){const y=Object.keys(x),{shapeFlag:w}=_;y.length&&w&7&&(a&&y.some(g3)&&(x=rj(x,a)),_=ks(_,x,!1,!0))}return r.dirs&&(_=ks(_,null,!1,!0),_.dirs=_.dirs?_.dirs.concat(r.dirs):r.dirs),r.transition&&Qo(_,r.transition),v=_,qp(g),v}function ej(e,t=!0){let r;for(let i=0;i<e.length;i++){const n=e[i];
vendor: 16,456 bytes, line 15
15if(el(n)){if(n.type!==ti||n.children==="v-if"){if(r)return;r=n}}else return}return r}const tj=e=>{let t;for(const r in e)(r==="class"||r==="style"||Pc(r))&&((t||(t={}))[r]=e[r]);return t},rj=(e,t)=>{const r={};for(const i in e)(!g3(i)||!(i.slice(9)in t))&&(r[i]=e[i]);return r};function ij(e,t,r){const{props:i,children:n,component:a}=e,{props:s,children:o,patchFlag:l}=t,u=a.emitsOptions;if(t.dirs||t.transition)return!0;if(r&&l>=0){if(l&1024)return!0;if(l&16)return i?o5(i,s,u):!!s;if(l&8){const c=t.dynamicProps;for(let d=0;d<c.length;d++){const h=c[d];if(xM(s,i,h)&&!d1(u,h))return!0}}}else return(n||o)&&(!o||!o.$stable)?!0:i===s?!1:i?s?o5(i,s,u):!0:!!s;return!1}function o5(e,t,r){const i=Object.keys(t);if(i.length!==Object.keys(e).length)return!0;for(let n=0;n<i.length;n++){const a=i[n];if(xM(t,e,a)&&!d1(r,a))return!0}return!1}function xM(e,t,r){const i=e[r],n=t[r];return r==="style"&&Ht(i)&&Ht(n)?!Ko(i,n):i!==n}function h1({vnode:e,parent:t},r){for(;t;){const i=t.subTree;if(i.suspense&&i.suspense.activeBranch===e&&(i.el=e.el),i===e)(e=t.vnode).el=r,t=t.parent;else break}}const wM={},$M=()=>Object.create(wM),SM=e=>Object.getPrototypeOf(e)===wM;function nj(e,t,r,i=!1){const n={},a=$M();e.propsDefaults=Object.create(null),TM(e,t,n,a);for(const s in e.propsOptions[0])s in n||(n[s]=void 0);r?e.props=i?n:jp(n):e.type.props?e.props=n:e.props=a,e.attrs=a}function aj(e,t,r,i){const{props:n,attrs:a,vnode:{patchFlag:s}}=e,o=Ft(n),[l]=e.propsOptions;let u=!1;if((i||s>0)&&!(s&16)){if(s&8){const c=e.vnode.dynamicProps;for(let d=0;d<c.length;d++){let h=c[d];if(d1(e.emitsOptions,h))continue;const f=t[h];if(l)if(Kt(a,h))f!==a[h]&&(a[h]=f,u=!0);else{const p=ar(h);n[p]=x2(l,o,p,f,e,!1)}else f!==a[h]&&(a[h]=f,u=!0)}}}else{TM(e,t,n,a)&&(u=!0);let c;for(const d in o)(!t||!Kt(t,d)&&((c=Un(d))===d||!Kt(t,c)))&&(l?r&&(r[d]!==void 0||r[c]!==void 0)&&(n[d]=x2(l,o,d,void 0,e,!0)):delete n[d]);if(a!==o)for(const d in a)(!t||!Kt(t,d))&&(delete a[d],u=!0)}u&&Po(e.attrs,"set","")}function TM(e,t,r,i){const[n,a]=e.propsOptions;let s=!1,o;if(t)for(let l in t){if(Vo(l))continue;const u=t[l];let c;n&&Kt(n,c=ar(l))?!a||!a.includes(c)?r[c]=u:(o||(o={}))[c]=u:d1(e.emitsOptions,l)||(!(l in i)||u!==i[l])&&(i[l]=u,s=!0)}if(a){const l=Ft(r),u=o||Dt;for(let c=0;c<a.length;c++){const d=a[c];r[d]=x2(n,l,d,u[d],e,!Kt(u,d))}}return s}function x2(e,t,r,i,n,a){const s=e[r];if(s!=null){const o=Kt(s,"default");if(o&&i===void 0){const l=s.default;if(s.type!==Function&&!s.skipFactory&&nt(l)){const{propsDefaults:u}=n;if(r in u)i=u[r];else{const c=Uh(n);i=u[r]=l.call(null,t),c()}}else i=l;n.ce&&n.ce._setProp(r,i)}s[0]&&(a&&!o?i=!1:s[1]&&(i===""||i===Un(r))&&(i=!0))}return i}const sj=new WeakMap;function CM(e,t,r=!1){const i=r?sj:t.propsCache,n=i.get(e);if(n)return n;const a=e.props,s={},o=[];let l=!1;if(!nt(e)){const c=d=>{l=!0;const[h,f]=CM(d,t,!0);Ct(s,h),f&&o.push(...f)};!r&&t.mixins.length&&t.mixins.forEach(c),e.extends&&c(e.extends),e.mixins&&e.mixins.forEach(c)}if(!a&&!l)return Ht(e)&&i.set(e,Pd),Pd;if(Le(a))for(let c=0;c<a.length;c++){const d=ar(a[c]);l5(d)&&(s[d]=Dt)}else if(a)for(const c in a){const d=ar(c);if(l5(d)){const h=a[c],f=s[d]=Le(h)||nt(h)?{type:h}:Ct({},h),p=f.type;let m=!1,g=!0;if(Le(p))for(let v=0;v<p.length;++v){const x=p[v],_=nt(x)&&x.name;if(_==="Boolean"){m=!0;break}else _==="String"&&(g=!1)}else m=nt(p)&&p.name==="Boolean";f[0]=m,f[1]=g,(m||Kt(f,"default"))&&o.push(d)}}const u=[s,o];return Ht(e)&&i.set(e,u),u}function l5(e){return e[0]!=="$"&&!Vo(e)}const L3=e=>e==="_"||e==="_ctx"||e==="$stable",F3=e=>Le(e)?e.map(Bn):[Bn(e)],oj=(e,t,r)=>{if(t._n)return t;const i=_t((...n)=>F3(t(...n)),r);return i._c=!1,i},kM=(e,t,r)=>{const i=e._ctx;for(const n in e){if(L3(n))continue;const a=e[n];if(nt(a))t[n]=oj(n,a,i);else if(a!=null){const s=F3(a);t[n]=()=>s}}},EM=(e,t)=>{const r=F3(t);e.slots.default=()=>r},PM=(e,t,r)=>{for(const i in t)(r||!L3(i))&&(e[i]=t[i])},lj=(e,t,r)=>{const i=e.slots=$M();if(e.vnode.shapeFlag&32){const n=t._;n?(PM(i,t,r),r&&mP(i,"_",n,!0)):kM(t,i)}else t&&EM(e,t)},uj=(e,t,r)=>{const{vnode:i,slots:n}=e;let a=!0,s=Dt;if(i.shapeFlag&32){const o=t._;o?r&&o===1?a=!1:PM(n,t,r):(a=!t.$stable,kM(t,n)),s=t}else t&&(EM(e,t),s={default:1});if(a)for(const o in n)!L3(o)&&s[o]==null&&delete n[o]},Jr=FM;function MM(e){return AM(e)}function IM(e){return AM(e,_B)}function AM(e,t){const r=e1();r.__VUE__=!0;const{insert:i,remove:n,patchProp:a,createElement:s,createText:o,createComment:l,setText:u,setElementText:c,parentNode:d,nextSibling:h,setScopeId:f=qi,insertStaticContent:p}=e,m=(j,W,G,ie=null,U=null,ne=null,me=void 0,J=null,N=!!W.dynamicChildren)=>{if(j===W)return;j&&!gs(j,W)&&(ie=$e(j),ue(j,U,ne,!0),j=null),W.patchFlag===-2&&(N=!1,W.dynamicChildren=null);const{type:q,ref:te,shapeFlag:ee}=W;switch(q){case Hl:g(j,W,G,ie);break;case ti:v(j,W,G,ie);break;case Ku:j==null&&x(W,G,ie,me);break;case xe:T(j,W,G,ie,U,ne,me,J,N);break;default:ee&1?w(j,W,G,ie,U,ne,me,J,N):ee&6?D(j,W,G,ie,U,ne,me,J,N):(ee&64||ee&128)&&q.process(j,W,G,ie,U,ne,me,J,N,ze)}te!=null&&U?Od(te,j&&j.ref,ne,W||j,!W):te==null&&j&&j.ref!=null&&Od(j.ref,null,ne,j,!0)},g=(j,W,G,ie)=>{if(j==null)i(W.el=o(W.children),G,ie);else{const U=W.el=j.el;W.children!==j.children&&u(U,W.children)}},v=(j,W,G,ie)=>{j==null?i(W.el=l(W.children||""),G,ie):W.el=j.el},x=(j,W,G,ie)=>{[j.el,j.anchor]=p(j.children,W,G,ie,j.el,j.anchor)},_=({el:j,anchor:W},G,ie)=>{let U;for(;j&&j!==W;)U=h(j),i(j,G,ie),j=U;i(W,G,ie)},y=({el:j,anchor:W})=>{let G;for(;j&&j!==W;)G=h(j),n(j),j=G;n(W)},w=(j,W,G,ie,U,ne,me,J,N)=>{if(W.type==="svg"?me="svg":W.type==="math"&&(me="mathml"),j==null)$(W,G,ie,U,ne,me,J,N);else{const q=j.el&&j.el._isVueCE?j.el:null;try{q&&q._beginPatch(),C(j,W,U,ne,me,J,N)}finally{q&&q._endPatch()}}},$=(j,W,G,ie,U,ne,me,J)=>{let N,q;const{props:te,shapeFlag:ee,transition:oe,dirs:Se}=j;if(N=j.el=s(j.type,ne,te&&te.is,te),ee&8?c(N,j.children):ee&16&&E(j.children,N,null,ie,U,Iv(j,ne),me,J),Se&&Bs(j,null,ie,"created"),S(N,j,j.scopeId,me,ie),te){for(const De in te)De!=="value"&&!Vo(De)&&a(N,De,null,te[De],ne,ie);"value"in te&&a(N,"value",null,te.value,ne),(q=te.onVnodeBeforeMount)&&Ln(q,ie,j)}Se&&Bs(j,null,ie,"beforeMount");const we=DM(U,oe);we&&oe.beforeEnter(N),i(N,W,G),((q=te&&te.onVnodeMounted)||we||Se)&&Jr(()=>{q&&Ln(q,ie,j),we&&oe.enter(N),Se&&Bs(j,null,ie,"mounted")},U)},S=(j,W,G,ie,U)=>{if(G&&f(j,G),ie)for(let ne=0;ne<ie.length;ne++)f(j,ie[ne]);if(U){let ne=U.subTree;if(W===ne||A_(ne.type)&&(ne.ssContent===W||ne.ssFallback===W)){const me=U.vnode;S(j,me,me.scopeId,me.slotScopeIds,U.parent)}}},E=(j,W,G,ie,U,ne,me,J,N=0)=>{for(let q=N;q<j.length;q++){const te=j[q]=J?Co(j[q]):Bn(j[q]);m(null,te,W,G,ie,U,ne,me,J)}},C=(j,W,G,ie,U,ne,me)=>{const J=W.el=j.el;let{patchFlag:N,dynamicChildren:q,dirs:te}=W;N|=j.patchFlag&16;const ee=j.props||Dt,oe=W.props||Dt;let Se;if(G&&xu(G,!1),(Se=oe.onVnodeBeforeUpdate)&&Ln(Se,G,W,j),te&&Bs(W,j,G,"beforeUpdate"),G&&xu(G,!0),(ee.innerHTML&&oe.innerHTML==null||ee.textContent&&oe.textContent==null)&&c(J,""),q?I(j.dynamicChildren,q,J,G,ie,Iv(W,U),ne):me||V(j,W,J,null,G,ie,Iv(W,U),ne,!1),N>0){if(N&16)P(J,ee,oe,G,U);else if(N&2&&ee.class!==oe.class&&a(J,"class",null,oe.class,U),N&4&&a(J,"style",ee.style,oe.style,U),N&8){const we=W.dynamicProps;for(let De=0;De<we.length;De++){const Ue=we[De],xt=ee[Ue],kt=oe[Ue];(kt!==xt||Ue==="value")&&a(J,Ue,xt,kt,U,G)}}N&1&&j.children!==W.children&&c(J,W.children)}else!me&&q==null&&P(J,ee,oe,G,U);((Se=oe.onVnodeUpdated)||te)&&Jr(()=>{Se&&Ln(Se,G,W,j),te&&Bs(W,j,G,"updated")},ie)},I=(j,W,G,ie,U,ne,me)=>{for(let J=0;J<W.length;J++){const N=j[J],q=W[J],te=N.el&&(N.type===xe||!gs(N,q)||N.shapeFlag&198)?d(N.el):G;m(N,q,te,null,ie,U,ne,me,!0)}},P=(j,W,G,ie,U)=>{if(W!==G){if(W!==Dt)for(const ne in W)!Vo(ne)&&!(ne in G)&&a(j,ne,W[ne],null,U,ie);for(const ne in G){if(Vo(ne))continue;const me=G[ne],J=W[ne];me!==J&&ne!=="value"&&a(j,ne,J,me,U,ie)}"value"in G&&a(j,"value",W.value,G.value,U)}},T=(j,W,G,ie,U,ne,me,J,N)=>{const q=W.el=j?j.el:o(""),te=W.anchor=j?j.anchor:o("");let{patchFlag:ee,dynamicChildren:oe,slotScopeIds:Se}=W;Se&&(J=J?J.concat(Se):Se),j==null?(i(q,G,ie),i(te,G,ie),E(W.children||[],G,te,U,ne,me,J,N)):ee>0&&ee&64&&oe&&j.dynamicChildren&&j.dynamicChildren.length===oe.length?(I(j.dynamicChildren,oe,G,U,ne,me,J),(W.key!=null||U&&W===U.subTree)&&z3(j,W,!0)):V(j,W,G,te,U,ne,me,J,N)},D=(j,W,G,ie,U,ne,me,J,N)=>{W.slotScopeIds=J,j==null?W.shapeFlag&512?U.ctx.activate(W,G,ie,me,N):A(W,G,ie,U,ne,me,N):z(j,W,N)},A=(j,W,G,ie,U,ne,me)=>{const J=j.component=jM(j,ie,U);if(Gm(j)&&(J.ctx.renderer=ze),VM(J,!1,me),J.asyncDep){if(U&&U.registerDep(J,R,me),!j.el){const N=J.subTree=be(ti);v(null,N,W,G),j.placeholder=N.el}}else R(J,j,W,G,U,ne,me)},z=(j,W,G)=>{const ie=W.component=j.component;if(ij(j,W,G))if(ie.asyncDep&&!ie.asyncResolved){O(ie,W,G);return}else ie.next=W,ie.update();else W.el=j.el,ie.vnode=W},R=(j,W,G,ie,U,ne,me)=>{const J=()=>{if(j.isMounted){let{next:ee,bu:oe,u:Se,parent:we,vnode:De}=j;{const rr=RM(j);if(rr){ee&&(ee.el=De.el,O(j,ee,me)),rr.asyncDep.then(()=>{Jr(()=>{j.isUnmounted||q()},U)});return}}let Ue=ee,xt;xu(j,!1),ee?(ee.el=De.el,O(j,ee,me)):ee=De,oe&&Ad(oe),(xt=ee.props&&ee.props.onVnodeBeforeUpdate)&&Ln(xt,we,ee,De),xu(j,!0);const kt=F0(j),ot=j.subTree;j.subTree=kt,m(ot,kt,d(ot.el),$e(ot),j,U,ne),ee.el=kt.el,Ue===null&&h1(j,kt.el),Se&&Jr(Se,U),(xt=ee.props&&ee.props.onVnodeUpdated)&&Jr(()=>Ln(xt,we,ee,De),U)}else{let ee;const{el:oe,props:Se}=W,{bm:we,m:De,parent:Ue,root:xt,type:kt}=j,ot=qo(W);if(xu(j,!1),we&&Ad(we),!ot&&(ee=Se&&Se.onVnodeBeforeMount)&&Ln(ee,Ue,W),xu(j,!0),oe&&qe){const rr=()=>{j.subTree=F0(j),qe(oe,j.subTree,j,U,null)};ot&&kt.__asyncHydrate?kt.__asyncHydrate(oe,j,rr):rr()}else{xt.ce&&xt.ce._hasShadowRoot()&&xt.ce._injectChildStyle(kt,j.parent?j.parent.type:void 0);const rr=j.subTree=F0(j);m(null,rr,G,ie,j,U,ne),W.el=rr.el}if(De&&Jr(De,U),!ot&&(ee=Se&&Se.onVnodeMounted)){const rr=W;Jr(()=>Ln(ee,Ue,rr),U)}(W.shapeFlag&256||Ue&&qo(Ue.vnode)&&Ue.vnode.shapeFlag&256)&&j.a&&Jr(j.a,U),j.isMounted=!0,W=G=ie=null}};j.scope.on();const N=j.effect=new zp(J);j.scope.off();const q=j.update=N.run.bind(N),te=j.job=N.runIfDirty.bind(N);te.i=j,te.id=j.uid,N.scheduler=()=>C3(te),xu(j,!0),q()},O=(j,W,G)=>{W.component=j;const ie=j.vnode.props;j.vnode=W,j.next=null,aj(j,W.props,ie,G),uj(j,W.children,G),Xo(),WS(j),Jo()},V=(j,W,G,ie,U,ne,me,J,N=!1)=>{const q=j&&j.children,te=j?j.shapeFlag:0,ee=W.children,{patchFlag:oe,shapeFlag:Se}=W;if(oe>0){if(oe&128){F(q,ee,G,ie,U,ne,me,J,N);return}else if(oe&256){Y(q,ee,G,ie,U,ne,me,J,N);return}}Se&8?(te&16&&ve(q,U,ne),ee!==q&&c(G,ee)):te&16?Se&16?F(q,ee,G,ie,U,ne,me,J,N):ve(q,U,ne,!0):(te&8&&c(G,""),Se&16&&E(ee,G,ie,U,ne,me,J,N))},Y=(j,W,G,ie,U,ne,me,J,N)=>{j=j||Pd,W=W||Pd;const q=j.length,te=W.length,ee=Math.min(q,te);let oe;for(oe=0;oe<ee;oe++){const Se=W[oe]=N?Co(W[oe]):Bn(W[oe]);m(j[oe],Se,G,null,U,ne,me,J,N)}q>te?ve(j,U,ne,!0,!1,ee):E(W,G,ie,U,ne,me,J,N,ee)},F=(j,W,G,ie,U,ne,me,J,N)=>{let q=0;const te=W.length;let ee=j.length-1,oe=te-1;for(;q<=ee&&q<=oe;){const Se=j[q],we=W[q]=N?Co(W[q]):Bn(W[q]);if(gs(Se,we))m(Se,we,G,null,U,ne,me,J,N);else break;q++}for(;q<=ee&&q<=oe;){const Se=j[ee],we=W[oe]=N?Co(W[oe]):Bn(W[oe]);if(gs(Se,we))m(Se,we,G,null,U,ne,me,J,N);else break;ee--,oe--}if(q>ee){if(q<=oe){const Se=oe+1,we=Se<te?W[Se].el:ie;for(;q<=oe;)m(null,W[q]=N?Co(W[q]):Bn(W[q]),G,we,U,ne,me,J,N),q++}}else if(q>oe)for(;q<=ee;)ue(j[q],U,ne,!0),q++;else{const Se=q,we=q,De=new Map;for(q=we;q<=oe;q++){const Vt=W[q]=N?Co(W[q]):Bn(W[q]);Vt.key!=null&&De.set(Vt.key,q)}let Ue,xt=0;const kt=oe-we+1;let ot=!1,rr=0;const Cr=new Array(kt);for(q=0;q<kt;q++)Cr[q]=0;for(q=Se;q<=ee;q++){const Vt=j[q];if(xt>=kt){ue(Vt,U,ne,!0);continue}let ge;if(Vt.key!=null)ge=De.get(Vt.key);else for(Ue=we;Ue<=oe;Ue++)if(Cr[Ue-we]===0&&gs(Vt,W[Ue])){ge=Ue;break}ge===void 0?ue(Vt,U,ne,!0):(Cr[ge-we]=q+1,ge>=rr?rr=ge:ot=!0,m(Vt,W[ge],G,null,U,ne,me,J,N),xt++)}const xi=ot?cj(Cr):Pd;for(Ue=xi.length-1,q=kt-1;q>=0;q--){const Vt=we+q,ge=W[Vt],B=W[Vt+1],re=Vt+1<te?B.el||OM(B):ie;Cr[q]===0?m(null,ge,G,re,U,ne,me,J,N):ot&&(Ue<0||q!==xi[Ue]?ae(ge,G,re,2):Ue--)}}},ae=(j,W,G,ie,U=null)=>{const{el:ne,type:me,transition:J,children:N,shapeFlag:q}=j;if(q&6){ae(j.component.subTree,W,G,ie);return}if(q&128){j.suspense.move(W,G,ie);return}if(q&64){me.move(j,W,G,ze);return}if(me===xe){i(ne,W,G);for(let ee=0;ee<N.length;ee++)ae(N[ee],W,G,ie);i(j.anchor,W,G);return}if(me===Ku){_(j,W,G);return}if(ie!==2&&q&1&&J)if(ie===0)J.beforeEnter(ne),i(ne,W,G),Jr(()=>J.enter(ne),U);else{const{leave:ee,delayLeave:oe,afterLeave:Se}=J,we=()=>{j.ctx.isUnmounted?n(ne):i(ne,W,G)},De=()=>{ne._isLeaving&&ne[js](!0),ee(ne,()=>{we(),Se&&Se()})};oe?oe(ne,we,De):De()}else i(ne,W,G)},ue=(j,W,G,ie=!1,U=!1)=>{const{type:ne,props:me,ref:J,children:N,dynamicChildren:q,shapeFlag:te,patchFlag:ee,dirs:oe,cacheIndex:Se}=j;if(ee===-2&&(U=!1),J!=null&&(Xo(),Od(J,null,G,j,!0),Jo()),Se!=null&&(W.renderCache[Se]=void 0),te&256){W.ctx.deactivate(j);return}const we=te&1&&oe,De=!qo(j);let Ue;if(De&&(Ue=me&&me.onVnodeBeforeUnmount)&&Ln(Ue,W,j),te&6)fe(j.component,G,ie);else{if(te&128){j.suspense.unmount(G,ie);return}we&&Bs(j,null,W,"beforeUnmount"),te&64?j.type.remove(j,W,G,ze,ie):q&&!q.hasOnce&&(ne!==xe||ee>0&&ee&64)?ve(q,W,G,!1,!0):(ne===xe&&ee&384||!U&&te&16)&&ve(N,W,G),ie&&Z(j)}(De&&(Ue=me&&me.onVnodeUnmounted)||we)&&Jr(()=>{Ue&&Ln(Ue,W,j),we&&Bs(j,null,W,"unmounted")},G)},Z=j=>{const{type:W,el:G,anchor:ie,transition:U}=j;if(W===xe){K(G,ie);return}if(W===Ku){y(j);return}const ne=()=>{n(G),U&&!U.persisted&&U.afterLeave&&U.afterLeave()};if(j.shapeFlag&1&&U&&!U.persisted){const{leave:me,delayLeave:J}=U,N=()=>me(G,ne);J?J(j.el,ne,N):N()}else ne()},K=(j,W)=>{let G;for(;j!==W;)G=h(j),n(j),j=G;n(W)},fe=(j,W,G)=>{const{bum:ie,scope:U,job:ne,subTree:me,um:J,m:N,a:q}=j;I_(N),I_(q),ie&&Ad(ie),U.stop(),ne&&(ne.flags|=8,ue(me,j,W,G)),J&&Jr(J,W),Jr(()=>{j.isUnmounted=!0},W)},ve=(j,W,G,ie=!1,U=!1,ne=0)=>{for(let me=ne;me<j.length;me++)ue(j[me],W,G,ie,U)},$e=j=>{if(j.shapeFlag&6)return $e(j.component.subTree);if(j.shapeFlag&128)return j.suspense.next();const W=h(j.anchor||j.el),G=W&&W[KP];return G?h(G):W};let Re=!1;const Oe=(j,W,G)=>{let ie;j==null?W._vnode&&(ue(W._vnode,null,null,!0),ie=W._vnode.component):m(W._vnode||null,j,W,null,null,null,G),W._vnode=j,Re||(Re=!0,WS(ie),E_(),Re=!1)},ze={p:m,um:ue,m:ae,r:Z,mt:A,mc:E,pc:V,pbc:I,n:$e,o:e};let Be,qe;return t&&([Be,qe]=t(ze)),{render:Oe,hydrate:Be,createApp:XB(Oe,Be)}}function Iv({type:e,props:t},r){return r==="svg"&&e==="foreignObject"||r==="mathml"&&e==="annotation-xml"&&t&&t.encoding&&t.encoding.includes("html")?void 0:r}function xu({effect:e,job:t},r){r?(e.flags|=32,t.flags|=4):(e.flags&=-33,t.flags&=-5)}function DM(e,t){return(!e||e&&!e.pendingBranch)&&t&&!t.persisted}function z3(e,t,r=!1){const i=e.children,n=t.children;if(Le(i)&&Le(n))for(let a=0;a<i.length;a++){const s=i[a];let o=n[a];o.shapeFlag&1&&!o.dynamicChildren&&((o.patchFlag<=0||o.patchFlag===32)&&(o=n[a]=Co(n[a]),o.el=s.el),!r&&o.patchFlag!==-2&&z3(s,o)),o.type===Hl&&(o.patchFlag===-1&&(o=n[a]=Co(o)),o.el=s.el),o.type===ti&&!o.el&&(o.el=s.el)}}function cj(e){const t=e.slice(),r=[0];let i,n,a,s,o;const l=e.length;for(i=0;i<l;i++){const u=e[i];if(u!==0){if(n=r[r.length-1],e[n]<u){t[i]=n,r.push(i);continue}for(a=0,s=r.length-1;a<s;)o=a+s>>1,e[r[o]]<u?a=o+1:s=o;u<e[r[a]]&&(a>0&&(t[i]=r[a-1]),r[a]=i)}}for(a=r.length,s=r[a-1];a-- >0;)r[a]=s,s=t[s];return r}function RM(e){const t=e.subTree.component;if(t)return t.asyncDep&&!t.asyncResolved?t:RM(t)}function I_(e){if(e)for(let t=0;t<e.length;t++)e[t].flags|=8}function OM(e){if(e.placeholder)return e.placeholder;const t=e.component;return t?OM(t.subTree):null}const A_=e=>e.__isSuspense;let w2=0;const dj={name:"Suspense",__isSuspense:!0,process(e,t,r,i,n,a,s,o,l,u){if(e==null)fj(t,r,i,n,a,s,o,l,u);else{if(a&&a.deps>0&&!e.suspense.isInFallback){t.suspense=e.suspense,t.suspense.vnode=t,t.el=e.el;return}pj(e,t,r,i,n,s,o,l,u)}},hydrate:mj,normalize:gj},hj=dj;function Yp(e,t){const r=e.props&&e.props[t];nt(r)&&r()}function fj(e,t,r,i,n,a,s,o,l){const{p:u,o:{createElement:c}}=l,d=c("div"),h=e.suspense=LM(e,n,i,t,d,r,a,s,o,l);u(null,h.pendingBranch=e.ssContent,d,null,i,h,a,s),h.deps>0?(Yp(e,"onPending"),Yp(e,"onFallback"),u(null,e.ssFallback,t,r,i,null,a,s),Ld(h,e.ssFallback)):h.resolve(!1,!0)}function pj(e,t,r,i,n,a,s,o,{p:l,um:u,o:{createElement:c}}){const d=t.suspense=e.suspense;d.vnode=t,t.el=e.el;const h=t.ssContent,f=t.ssFallback,{activeBranch:p,pendingBranch:m,isInFallback:g,isHydrating:v}=d;
vendor: 11,240 bytes, lines 15-18
15if(m)d.pendingBranch=h,gs(m,h)?(l(m,h,d.hiddenContainer,null,n,d,a,s,o),d.deps<=0?d.resolve():g&&(v||(l(p,f,r,i,n,null,a,s,o),Ld(d,f)))):(d.pendingId=w2++,v?(d.isHydrating=!1,d.activeBranch=m):u(m,n,d),d.deps=0,d.effects.length=0,d.hiddenContainer=c("div"),g?(l(null,h,d.hiddenContainer,null,n,d,a,s,o),d.deps<=0?d.resolve():(l(p,f,r,i,n,null,a,s,o),Ld(d,f))):p&&gs(p,h)?(l(p,h,r,i,n,d,a,s,o),d.resolve(!0)):(l(null,h,d.hiddenContainer,null,n,d,a,s,o),d.deps<=0&&d.resolve()));else if(p&&gs(p,h))l(p,h,r,i,n,d,a,s,o),Ld(d,h);else if(Yp(t,"onPending"),d.pendingBranch=h,h.shapeFlag&512?d.pendingId=h.component.suspenseId:d.pendingId=w2++,l(null,h,d.hiddenContainer,null,n,d,a,s,o),d.deps<=0)d.resolve();else{const{timeout:x,pendingId:_}=d;x>0?setTimeout(()=>{d.pendingId===_&&d.fallback(f)},x):x===0&&d.fallback(f)}}function LM(e,t,r,i,n,a,s,o,l,u,c=!1){const{p:d,m:h,um:f,n:p,o:{parentNode:m,remove:g}}=u;let v;const x=_j(e);x&&t&&t.pendingBranch&&(v=t.pendingId,t.deps++);const _=e.props?$_(e.props.timeout):void 0,y=a,w={vnode:e,parent:t,parentComponent:r,namespace:s,container:i,hiddenContainer:n,deps:0,pendingId:w2++,timeout:typeof _=="number"?_:-1,activeBranch:null,pendingBranch:null,isInFallback:!c,isHydrating:c,isUnmounted:!1,effects:[],resolve($=!1,S=!1){const{vnode:E,activeBranch:C,pendingBranch:I,pendingId:P,effects:T,parentComponent:D,container:A,isInFallback:z}=w;let R=!1;w.isHydrating?w.isHydrating=!1:$||(R=C&&I.transition&&I.transition.mode==="out-in",R&&(C.transition.afterLeave=()=>{P===w.pendingId&&(h(I,A,a===y?p(C):a,0),Up(T),z&&E.ssFallback&&(E.ssFallback.el=null))}),C&&(m(C.el)===A&&(a=p(C)),f(C,D,w,!0),!R&&z&&E.ssFallback&&Jr(()=>E.ssFallback.el=null,w)),R||h(I,A,a,0)),Ld(w,I),w.pendingBranch=null,w.isInFallback=!1;let O=w.parent,V=!1;for(;O;){if(O.pendingBranch){O.effects.push(...T),V=!0;break}O=O.parent}!V&&!R&&Up(T),w.effects=[],x&&t&&t.pendingBranch&&v===t.pendingId&&(t.deps--,t.deps===0&&!S&&t.resolve()),Yp(E,"onResolve")},fallback($){if(!w.pendingBranch)return;const{vnode:S,activeBranch:E,parentComponent:C,container:I,namespace:P}=w;Yp(S,"onFallback");const T=p(E),D=()=>{w.isInFallback&&(d(null,$,I,T,C,null,P,o,l),Ld(w,$))},A=$.transition&&$.transition.mode==="out-in";A&&(E.transition.afterLeave=D),w.isInFallback=!0,f(E,C,null,!0),A||D()},move($,S,E){w.activeBranch&&h(w.activeBranch,$,S,E),w.container=$},next(){return w.activeBranch&&p(w.activeBranch)},registerDep($,S,E){const C=!!w.pendingBranch;C&&w.deps++;const I=$.vnode.el;$.asyncDep.catch(P=>{Ac(P,$,0)}).then(P=>{if($.isUnmounted||w.isUnmounted||w.pendingId!==$.suspenseId)return;$.asyncResolved=!0;const{vnode:T}=$;$2($,P,!1),I&&(T.el=I);const D=!I&&$.subTree.el;S($,T,m(I||$.subTree.el),I?null:p($.subTree),w,s,E),D&&(T.placeholder=null,g(D)),h1($,T.el),C&&--w.deps===0&&w.resolve()})},unmount($,S){w.isUnmounted=!0,w.activeBranch&&f(w.activeBranch,r,$,S),w.pendingBranch&&f(w.pendingBranch,r,$,S)}};return w}function mj(e,t,r,i,n,a,s,o,l){const u=t.suspense=LM(t,i,r,e.parentNode,document.createElement("div"),null,n,a,s,o,!0),c=l(e,u.pendingBranch=t.ssContent,r,u,a,s);return u.deps===0&&u.resolve(!1,!0),c}function gj(e){const{shapeFlag:t,children:r}=e,i=t&32;e.ssContent=u5(i?r.default:r),e.ssFallback=i?u5(r.fallback):be(ti)}function u5(e){let t;if(nt(e)){const r=gc&&e._c;r&&(e._d=!1,k()),e=e(),r&&(e._d=!0,t=un,zM())}return Le(e)&&(e=ej(e)),e=Bn(e),t&&!e.dynamicChildren&&(e.dynamicChildren=t.filter(r=>r!==e)),e}function FM(e,t){t&&t.pendingBranch?Le(e)?t.effects.push(...e):t.effects.push(e):Up(e)}function Ld(e,t){e.activeBranch=t;const{vnode:r,parentComponent:i}=e;let n=t.el;for(;!n&&t.component;)t=t.component.subTree,n=t.el;r.el=n,i&&i.subTree===r&&(i.vnode.el=n,h1(i,n))}function _j(e){const t=e.props&&e.props.suspensible;return t!=null&&t!==!1}const xe=Symbol.for("v-fgt"),Hl=Symbol.for("v-txt"),ti=Symbol.for("v-cmt"),Ku=Symbol.for("v-stc"),sp=[];let un=null;function k(e=!1){sp.push(un=e?null:[])}function zM(){sp.pop(),un=sp[sp.length-1]||null}let gc=1;function Wp(e,t=!1){gc+=e,e<0&&un&&t&&(un.hasOnce=!0)}function NM(e){return e.dynamicChildren=gc>0?un||Pd:null,zM(),gc>0&&un&&un.push(e),e}function M(e,t,r,i,n,a){return NM(b(e,t,r,i,n,a,!0))}function Mt(e,t,r,i,n){return NM(be(e,t,r,i,n,!0))}function el(e){return e?e.__v_isVNode===!0:!1}function gs(e,t){return e.type===t.type&&e.key===t.key}function yj(e){}const BM=({key:e})=>e??null,z0=({ref:e,ref_key:t,ref_for:r})=>(typeof e=="number"&&(e=""+e),e!=null?ft(e)||er(e)||nt(e)?{i:ji,r:e,k:t,f:!!r}:e:null);function b(e,t=null,r=null,i=0,n=null,a=e===xe?0:1,s=!1,o=!1){const l={__v_isVNode:!0,__v_skip:!0,type:e,props:t,key:t&&BM(t),ref:t&&z0(t),scopeId:o1,slotScopeIds:null,children:r,component:null,suspense:null,ssContent:null,ssFallback:null,dirs:null,transition:null,el:null,anchor:null,target:null,targetStart:null,targetAnchor:null,staticCount:0,shapeFlag:a,patchFlag:i,dynamicProps:n,dynamicChildren:null,appContext:null,ctx:ji};return o?(N3(l,r),a&128&&e.normalize(l)):r&&(l.shapeFlag|=ft(r)?8:16),gc>0&&!s&&un&&(l.patchFlag>0||a&6)&&l.patchFlag!==32&&un.push(l),l}const be=vj;function vj(e,t=null,r=null,i=0,n=null,a=!1){if((!e||e===fM)&&(e=ti),el(e)){const o=ks(e,t,!0);return r&&N3(o,r),gc>0&&!a&&un&&(o.shapeFlag&6?un[un.indexOf(e)]=o:un.push(o)),o.patchFlag=-2,o}if(Tj(e)&&(e=e.__vccOpts),t){t=nh(t);let{class:o,style:l}=t;o&&!ft(o)&&(t.class=pe(o)),Ht(l)&&(Vm(l)&&!Le(l)&&(l=Ct({},l)),t.style=Qt(l))}const s=ft(e)?1:A_(e)?128:XP(e)?64:Ht(e)?4:nt(e)?2:0;return b(e,t,r,i,n,s,a,!0)}function nh(e){return e?Vm(e)||SM(e)?Ct({},e):e:null}function ks(e,t,r=!1,i=!1){const{props:n,ref:a,patchFlag:s,children:o,transition:l}=e,u=t?Ha(n||{},t):n,c={__v_isVNode:!0,__v_skip:!0,type:e.type,props:u,key:u&&BM(u),ref:t&&t.ref?r&&a?Le(a)?a.concat(z0(t)):[a,z0(t)]:z0(t):a,scopeId:e.scopeId,slotScopeIds:e.slotScopeIds,children:o,target:e.target,targetStart:e.targetStart,targetAnchor:e.targetAnchor,staticCount:e.staticCount,shapeFlag:e.shapeFlag,patchFlag:t&&e.type!==xe?s===-1?16:s|16:s,dynamicProps:e.dynamicProps,dynamicChildren:e.dynamicChildren,appContext:e.appContext,dirs:e.dirs,transition:l,component:e.component,suspense:e.suspense,ssContent:e.ssContent&&ks(e.ssContent),ssFallback:e.ssFallback&&ks(e.ssFallback),placeholder:e.placeholder,el:e.el,anchor:e.anchor,ctx:e.ctx,ce:e.ce};return l&&i&&Qo(c,l.clone(c)),c}function Ze(e=" ",t=0){return be(Hl,null,e,t)}function so(e,t){const r=be(Ku,null,e);return r.staticCount=t,r}function X(e="",t=!1){return t?(k(),Mt(ti,null,e)):be(ti,null,e)}function Bn(e){return e==null||typeof e=="boolean"?be(ti):Le(e)?be(xe,null,e.slice()):el(e)?Co(e):be(Hl,null,String(e))}function Co(e){return e.el===null&&e.patchFlag!==-1||e.memo?e:ks(e)}function N3(e,t){let r=0;const{shapeFlag:i}=e;if(t==null)t=null;else if(Le(t))r=16;else if(typeof t=="object")if(i&65){const n=t.default;n&&(n._c&&(n._d=!1),N3(e,n()),n._c&&(n._d=!0));return}else{r=32;const n=t._;!n&&!SM(t)?t._ctx=ji:n===3&&ji&&(ji.slots._===1?t._=1:(t._=2,e.patchFlag|=1024))}else nt(t)?(t={default:t,_ctx:ji},r=32):(t=String(t),i&64?(r=16,t=[Ze(t)]):r=8);e.children=t,e.shapeFlag|=r}function Ha(...e){const t={};for(let r=0;r<e.length;r++){const i=e[r];for(const n in i)if(n==="class")t.class!==i.class&&(t.class=pe([t.class,i.class]));else if(n==="style")t.style=Qt([t.style,i.style]);else if(Pc(n)){const a=t[n],s=i[n];s&&a!==s&&!(Le(a)&&a.includes(s))&&(t[n]=a?[].concat(a,s):s)}else n!==""&&(t[n]=i[n])}return t}function Ln(e,t,r,i=null){is(e,t,7,[r,i])}const bj=yM();let xj=0;function jM(e,t,r){const i=e.type,n=(t?t.appContext:e.appContext)||bj,a={uid:xj++,vnode:e,type:i,parent:t,appContext:n,root:null,next:null,subTree:null,effect:null,update:null,job:null,scope:new v3(!0),render:null,proxy:null,exposed:null,exposeProxy:null,withProxy:null,provides:t?t.provides:Object.create(n.provides),ids:t?t.ids:["",0,0],accessCache:null,renderCache:[],components:null,directives:null,propsOptions:CM(i,n),emitsOptions:bM(i,n),emit:null,emitted:null,propsDefaults:Dt,inheritAttrs:i.inheritAttrs,ctx:Dt,data:Dt,props:Dt,attrs:Dt,slots:Dt,refs:Dt,setupState:Dt,setupContext:null,suspense:r,suspenseId:r?r.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 a.ctx={_:a},a.root=t?t.root:a,a.emit=JB.bind(null,a),e.ce&&e.ce(a),a}let Ni=null;const pn=()=>Ni||ji;let D_,Fd;{const e=e1(),t=(r,i)=>{let n;return(n=e[r])||(n=e[r]=[]),n.push(i),a=>{n.length>1?n.forEach(s=>s(a)):n[0](a)}};D_=t("__VUE_INSTANCE_SETTERS__",r=>Ni=r),Fd=t("__VUE_SSR_SETTERS__",r=>_c=r)}const Uh=e=>{const t=Ni;return D_(e),e.scope.on(),()=>{e.scope.off(),D_(t)}},R_=()=>{Ni&&Ni.scope.off(),D_(null)};function UM(e){return e.vnode.shapeFlag&4}let _c=!1;function VM(e,t=!1,r=!1){t&&Fd(t);const{props:i,children:n}=e.vnode,a=UM(e);nj(e,i,a,t),lj(e,n,r||t);const s=a?wj(e,t):void 0;return t&&Fd(!1),s}function wj(e,t){const r=e.type;e.accessCache=Object.create(null),e.proxy=new Proxy(e.ctx,y2);const{setup:i}=r;if(i){Xo();const n=e.setupContext=i.length>1?HM(e):null,a=Uh(e),s=Bh(i,e,0,[e.props,n]),o=y3(s);if(Jo(),a(),(o||e.sp)&&!qo(e)&&P3(e),o){if(s.then(R_,R_),t)return s.then(l=>{$2(e,l,t)}).catch(l=>{Ac(l,e,0)});e.asyncDep=s}else $2(e,s,t)}else GM(e,t)}function $2(e,t,r){nt(t)?e.type.__ssrInlineRender?e.ssrRender=t:e.render=t:Ht(t)&&(e.setupState=T3(t)),GM(e,r)}let O_,S2;function qM(e){O_=e,S2=t=>{t.render._rc&&(t.withProxy=new Proxy(t.ctx,AB))}}const $j=()=>!O_;function GM(e,t,r){const i=e.type;if(!e.render){if(!t&&O_&&!i.render){const n=i.template||O3(e).template;if(n){const{isCustomElement:a,compilerOptions:s}=e.appContext.config,{delimiters:o,compilerOptions:l}=i,u=Ct(Ct({isCustomElement:a,delimiters:o},s),l);i.render=O_(n,u)}}e.render=i.render||qi,S2&&S2(e)}{const n=Uh(e);Xo();try{GB(e)}finally{Jo(),n()}}}const Sj={get(e,t){return an(e,"get",""),e[t]}};function HM(e){const t=r=>{e.exposed=r||{}};return{attrs:new Proxy(e.attrs,Sj),slots:e.slots,emit:e.emit,expose:t}}function Hm(e){return e.exposed?e.exposeProxy||(e.exposeProxy=new Proxy(T3(mc(e.exposed)),{get(t,r){if(r in t)return t[r];if(r in ap)return ap[r](e)},has(t,r){return r in t||r in ap}})):e.proxy}function T2(e,t=!0){return nt(e)?e.displayName||e.name:e.name||t&&e.__name}function Tj(e){return nt(e)&&"__vccOpts"in e}const H=(e,t)=>ZN(e,t,_c);function qa(e,t,r){try{Wp(-1);const i=arguments.length;return i===2?Ht(t)&&!Le(t)?el(t)?be(e,null,[t]):be(e,t):be(e,null,t):(i>3?r=Array.prototype.slice.call(arguments,2):i===3&&el(r)&&(r=[r]),be(e,t,r))}finally{Wp(1)}}function Cj(){}function kj(e,t,r,i){const n=r[i];if(n&&YM(n,e))return n;const a=t();return a.memo=e.slice(),a.cacheIndex=i,r[i]=a}function YM(e,t){const r=e.memo;if(r.length!=t.length)return!1;for(let i=0;i<r.length;i++)if(Oi(r[i],t[i]))return!1;return gc>0&&un&&un.push(e),!0}const WM="3.5.30",Ej=qi,Pj=nB,Mj=ad,Ij=qP,Aj={createComponentInstance:jM,setupComponent:VM,renderComponentRoot:F0,setCurrentRenderingInstance:qp,isVNode:el,normalizeVNode:Bn,getComponentPublicInstance:Hm,ensureValidVNode:R3,pushWarningContext:eB,popWarningContext:tB},Dj=Aj,Rj=null,Oj=null,Lj=null;/** 16* @vue/runtime-dom v3.5.30 17* (c) 2018-present Yuxi (Evan) You and Vue contributors 18* @license MIT
19**/let C2;const c5=typeof window<"u"&&window.trustedTypes;if(c5)try{C2=c5.createPolicy("vue",{createHTML:e=>e})}catch{}const ZM=C2?e=>C2.createHTML(e):e=>e,Fj="http://www.w3.org/2000/svg",zj="http://www.w3.org/1998/Math/MathML",So=typeof document<"u"?document:null,d5=So&&So.createElement("template"),KM={insert:(e,t,r)=>{t.insertBefore(e,r||null)},remove:e=>{const t=e.parentNode;t&&t.removeChild(e)},createElement:(e,t,r,i)=>{const n=t==="svg"?So.createElementNS(Fj,e):t==="mathml"?So.createElementNS(zj,e):r?So.createElement(e,{is:r}):So.createElement(e);return e==="select"&&i&&i.multiple!=null&&n.setAttribute("multiple",i.multiple),n},createText:e=>So.createTextNode(e),createComment:e=>So.createComment(e),setText:(e,t)=>{e.nodeValue=t},setElementText:(e,t)=>{e.textContent=t},parentNode:e=>e.parentNode,nextSibling:e=>e.nextSibling,querySelector:e=>So.querySelector(e),setScopeId(e,t){e.setAttribute(t,"")},insertStaticContent(e,t,r,i,n,a){const s=r?r.previousSibling:t.lastChild;if(n&&(n===a||n.nextSibling))for(;t.insertBefore(n.cloneNode(!0),r),!(n===a||!(n=n.nextSibling)););else{d5.innerHTML=ZM(i==="svg"?`<svg>${e}</svg>`:i==="mathml"?`<math>${e}</math>`:e);const o=d5.content;if(i==="svg"||i==="mathml"){const l=o.firstChild;for(;l.firstChild;)o.appendChild(l.firstChild);o.removeChild(l)}t.insertBefore(o,r)}return[s?s.nextSibling:t.firstChild,r?r.previousSibling:t.lastChild]}},vl="transition",cf="animation",ah=Symbol("_vtc"),XM={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},JM=Ct({},E3,XM),Nj=e=>(e.displayName="Transition",e.props=JM,e),Ym=Nj((e,{slots:t})=>qa(rM,QM(e),t)),wu=(e,t=[])=>{Le(e)?e.forEach(r=>r(...t)):e&&e(...t)},h5=e=>e?Le(e)?e.some(t=>t.length>1):e.length>1:!1;function QM(e){const t={};for(const T in e)T in XM||(t[T]=e[T]);if(e.css===!1)return t;const{name:r="v",type:i,duration:n,enterFromClass:a=`${r}-enter-from`,enterActiveClass:s=`${r}-enter-active`,enterToClass:o=`${r}-enter-to`,appearFromClass:l=a,appearActiveClass:u=s,appearToClass:c=o,leaveFromClass:d=`${r}-leave-from`,leaveActiveClass:h=`${r}-leave-active`,leaveToClass:f=`${r}-leave-to`}=e,p=Bj(n),m=p&&p[0],g=p&&p[1],{onBeforeEnter:v,onEnter:x,onEnterCancelled:_,onLeave:y,onLeaveCancelled:w,onBeforeAppear:$=v,onAppear:S=x,onAppearCancelled:E=_}=t,C=(T,D,A,z)=>{T._enterCancelled=z,Cl(T,D?c:o),Cl(T,D?u:s),A&&A()},I=(T,D)=>{T._isLeaving=!1,Cl(T,d),Cl(T,f),Cl(T,h),D&&D()},P=T=>(D,A)=>{const z=T?S:x,R=()=>C(D,T,A);wu(z,[D,R]),f5(()=>{Cl(D,T?l:a),zs(D,T?c:o),h5(z)||p5(D,i,m,R)})};return Ct(t,{onBeforeEnter(T){wu(v,[T]),zs(T,a),zs(T,s)},onBeforeAppear(T){wu($,[T]),zs(T,l),zs(T,u)},onEnter:P(!1),onAppear:P(!0),onLeave(T,D){T._isLeaving=!0;const A=()=>I(T,D);zs(T,d),T._enterCancelled?(zs(T,h),k2(T)):(k2(T),zs(T,h)),f5(()=>{T._isLeaving&&(Cl(T,d),zs(T,f),h5(y)||p5(T,i,g,A))}),wu(y,[T,A])},onEnterCancelled(T){C(T,!1,void 0,!0),wu(_,[T])},onAppearCancelled(T){C(T,!0,void 0,!0),wu(E,[T])},onLeaveCancelled(T){I(T),wu(w,[T])}})}function Bj(e){if(e==null)return null;if(Ht(e))return[Av(e.enter),Av(e.leave)];{const t=Av(e);return[t,t]}}function Av(e){return $_(e)}function zs(e,t){t.split(/\s+/).forEach(r=>r&&e.classList.add(r)),(e[ah]||(e[ah]=new Set)).add(t)}function Cl(e,t){t.split(/\s+/).forEach(i=>i&&e.classList.remove(i));const r=e[ah];r&&(r.delete(t),r.size||(e[ah]=void 0))}function f5(e){requestAnimationFrame(()=>{requestAnimationFrame(e)})}let jj=0;function p5(e,t,r,i){const n=e._endId=++jj,a=()=>{n===e._endId&&i()};if(r!=null)return setTimeout(a,r);const{type:s,timeout:o,propCount:l}=eI(e,t);if(!s)return i();const u=s+"end";let c=0;const d=()=>{e.removeEventListener(u,h),a()},h=f=>{f.target===e&&++c>=l&&d()};setTimeout(()=>{c<l&&d()},o+1),e.addEventListener(u,h)}function eI(e,t){const r=window.getComputedStyle(e),i=p=>(r[p]||"").split(", "),n=i(`${vl}Delay`),a=i(`${vl}Duration`),s=m5(n,a),o=i(`${cf}Delay`),l=i(`${cf}Duration`),u=m5(o,l);let c=null,d=0,h=0;t===vl?s>0&&(c=vl,d=s,h=a.length):t===cf?u>0&&(c=cf,d=u,h=l.length):(d=Math.max(s,u),c=d>0?s>u?vl:cf:null,h=c?c===vl?a.length:l.length:0);const f=c===vl&&/\b(?:transform|all)(?:,|$)/.test(i(`${vl}Property`).toString());return{type:c,timeout:d,propCount:h,hasTransform:f}}function m5(e,t){for(;e.length<t.length;)e=e.concat(e);return Math.max(...t.map((r,i)=>g5(r)+g5(e[i])))}function g5(e){return e==="auto"?0:Number(e.slice(0,-1).replace(",","."))*1e3}function k2(e){return(e?e.ownerDocument:document).body.offsetHeight}function Uj(e,t,r){const i=e[ah];i&&(t=(t?[t,...i]:[...i]).join(" ")),t==null?e.removeAttribute("class"):r?e.setAttribute("class",t):e.className=t}const L_=Symbol("_vod"),tI=Symbol("_vsh"),Dn={name:"show",beforeMount(e,{value:t},{transition:r}){e[L_]=e.style.display==="none"?"":e.style.display,r&&t?r.beforeEnter(e):df(e,t)}
vendor: 8,051 bytes, line 19
19,mounted(e,{value:t},{transition:r}){r&&t&&r.enter(e)},updated(e,{value:t,oldValue:r},{transition:i}){!t!=!r&&(i?t?(i.beforeEnter(e),df(e,!0),i.enter(e)):i.leave(e,()=>{df(e,!1)}):df(e,t))},beforeUnmount(e,{value:t}){df(e,t)}};function df(e,t){e.style.display=t?e[L_]:"none",e[tI]=!t}function Vj(){Dn.getSSRProps=({value:e})=>{if(!e)return{style:{display:"none"}}}}const rI=Symbol("");function iI(e){const t=pn();if(!t)return;const r=t.ut=(n=e(t.proxy))=>{Array.from(document.querySelectorAll(`[data-v-owner="${t.uid}"]`)).forEach(a=>F_(a,n))},i=()=>{const n=e(t.proxy);t.ce?F_(t.ce,n):E2(t.subTree,n),r(n)};M3(()=>{Up(i)}),or(()=>{tt(i,qi,{flush:"post"});const n=new MutationObserver(i);n.observe(t.subTree.el.parentNode,{childList:!0}),ss(()=>n.disconnect())})}function E2(e,t){if(e.shapeFlag&128){const r=e.suspense;e=r.activeBranch,r.pendingBranch&&!r.isHydrating&&r.effects.push(()=>{E2(r.activeBranch,t)})}for(;e.component;)e=e.component.subTree;if(e.shapeFlag&1&&e.el)F_(e.el,t);else if(e.type===xe)e.children.forEach(r=>E2(r,t));else if(e.type===Ku){let{el:r,anchor:i}=e;for(;r&&(F_(r,t),r!==i);)r=r.nextSibling}}function F_(e,t){if(e.nodeType===1){const r=e.style;let i="";for(const n in t){const a=yN(t[n]);r.setProperty(`--${n}`,a),i+=`--${n}: ${a};`}r[rI]=i}}const qj=/(?:^|;)\s*display\s*:/;function Gj(e,t,r){const i=e.style,n=ft(r);let a=!1;if(r&&!n){if(t)if(ft(t))for(const s of t.split(";")){const o=s.slice(0,s.indexOf(":")).trim();r[o]==null&&N0(i,o,"")}else for(const s in t)r[s]==null&&N0(i,s,"");for(const s in r)s==="display"&&(a=!0),N0(i,s,r[s])}else if(n){if(t!==r){const s=i[rI];s&&(r+=";"+s),i.cssText=r,a=qj.test(r)}}else t&&e.removeAttribute("style");L_ in e&&(e[L_]=a?i.display:"",e[tI]&&(i.display="none"))}const _5=/\s*!important$/;function N0(e,t,r){if(Le(r))r.forEach(i=>N0(e,t,i));else if(r==null&&(r=""),t.startsWith("--"))e.setProperty(t,r);else{const i=Hj(e,t);_5.test(r)?e.setProperty(Un(i),r.replace(_5,""),"important"):e[i]=r}}const y5=["Webkit","Moz","ms"],Dv={};function Hj(e,t){const r=Dv[t];if(r)return r;let i=ar(t);if(i!=="filter"&&i in e)return Dv[t]=i;i=Ic(i);for(let n=0;n<y5.length;n++){const a=y5[n]+i;if(a in e)return Dv[t]=a}return t}const v5="http://www.w3.org/1999/xlink";function b5(e,t,r,i,n,a=gN(t)){i&&t.startsWith("xlink:")?r==null?e.removeAttributeNS(v5,t.slice(6,t.length)):e.setAttributeNS(v5,t,r):r==null||a&&!_P(r)?e.removeAttribute(t):e.setAttribute(t,a?"":ea(r)?String(r):r)}function x5(e,t,r,i,n){if(t==="innerHTML"||t==="textContent"){r!=null&&(e[t]=t==="innerHTML"?ZM(r):r);return}const a=e.tagName;if(t==="value"&&a!=="PROGRESS"&&!a.includes("-")){const o=a==="OPTION"?e.getAttribute("value")||"":e.value,l=r==null?e.type==="checkbox"?"on":"":String(r);(o!==l||!("_value"in e))&&(e.value=l),r==null&&e.removeAttribute(t),e._value=r;return}let s=!1;if(r===""||r==null){const o=typeof e[t];o==="boolean"?r=_P(r):r==null&&o==="string"?(r="",s=!0):o==="number"&&(r=0,s=!0)}try{e[t]=r}catch{}s&&e.removeAttribute(n||t)}function Io(e,t,r,i){e.addEventListener(t,r,i)}function Yj(e,t,r,i){e.removeEventListener(t,r,i)}const w5=Symbol("_vei");function Wj(e,t,r,i,n=null){const a=e[w5]||(e[w5]={}),s=a[t];if(i&&s)s.value=i;else{const[o,l]=Zj(t);if(i){const u=a[t]=Jj(i,n);Io(e,o,u,l)}else s&&(Yj(e,o,s,l),a[t]=void 0)}}const $5=/(?:Once|Passive|Capture)$/;function Zj(e){let t;if($5.test(e)){t={};let i;for(;i=e.match($5);)e=e.slice(0,e.length-i[0].length),t[i[0].toLowerCase()]=!0}return[e[2]===":"?e.slice(3):Un(e.slice(2)),t]}let Rv=0;const Kj=Promise.resolve(),Xj=()=>Rv||(Kj.then(()=>Rv=0),Rv=Date.now());function Jj(e,t){const r=i=>{if(!i._vts)i._vts=Date.now();else if(i._vts<=r.attached)return;is(Qj(i,r.value),t,5,[i])};return r.value=e,r.attached=Xj(),r}function Qj(e,t){if(Le(t)){const r=e.stopImmediatePropagation;return e.stopImmediatePropagation=()=>{r.call(e),e._stopped=!0},t.map(i=>n=>!n._stopped&&i&&i(n))}else return t}const S5=e=>e.charCodeAt(0)===111&&e.charCodeAt(1)===110&&e.charCodeAt(2)>96&&e.charCodeAt(2)<123,nI=(e,t,r,i,n,a)=>{const s=n==="svg";t==="class"?Uj(e,i,s):t==="style"?Gj(e,r,i):Pc(t)?g3(t)||Wj(e,t,r,i,a):(t[0]==="."?(t=t.slice(1),!0):t[0]==="^"?(t=t.slice(1),!1):eU(e,t,i,s))?(x5(e,t,i),!e.tagName.includes("-")&&(t==="value"||t==="checked"||t==="selected")&&b5(e,t,i,s,a,t!=="value")):e._isVueCE&&(tU(e,t)||e._def.__asyncLoader&&(/[A-Z]/.test(t)||!ft(i)))?x5(e,ar(t),i,a,t):(t==="true-value"?e._trueValue=i:t==="false-value"&&(e._falseValue=i),b5(e,t,i,s))};function eU(e,t,r,i){if(i)return!!(t==="innerHTML"||t==="textContent"||t in e&&S5(t)&&nt(r));if(t==="spellcheck"||t==="draggable"||t==="translate"||t==="autocorrect"||t==="sandbox"&&e.tagName==="IFRAME"||t==="form"||t==="list"&&e.tagName==="INPUT"||t==="type"&&e.tagName==="TEXTAREA")return!1;if(t==="width"||t==="height"){const n=e.tagName;if(n==="IMG"||n==="VIDEO"||n==="CANVAS"||n==="SOURCE")return!1}return S5(t)&&ft(r)?!1:t in e}function tU(e,t){const r=e._def.props;if(!r)return!1;const i=ar(t);return Array.isArray(r)?r.some(n=>ar(n)===i):Object.keys(r).some(n=>ar(n)===i)}const T5={};function aI(e,t,r){let i=fr(e,t);Ky(i)&&(i=Ct({},i,t));class n extends f1{constructor(s){super(i,s,r)}}return n.def=i,n}const rU=((e,t)=>aI(e,t,gI)),iU=typeof HTMLElement<"u"?HTMLElement:class{};class f1 extends iU{constructor(t,r={},i=N_){super(),this._def=t,this._props=r,this._createApp=i,this._isVueCE=!0,this._instance=null,this._app=null,this._nonce=this._def.nonce,this._connected=!1,this._resolved=!1,this._patching=!1,this._dirty=!1,this._numberProps=null,this._styleChildren=new WeakSet,this._styleAnchors=new WeakMap,this._ob=null,this.shadowRoot&&i!==N_?this._root=this.shadowRoot:t.shadowRoot!==!1?(this.attachShadow(Ct({},t.shadowRootOptions,{mode:"open"})),this._root=this.shadowRoot):this._root=this}connectedCallback(){if(!this.isConnected)return;!this.shadowRoot&&!this._resolved&&this._parseSlots(),this._connected=!0;let t=this;for(;t=t&&(t.assignedSlot||t.parentNode||t.host);)if(t instanceof f1){this._parent=t;break}this._instance||(this._resolved?this._mount(this._def):t&&t._pendingResolve?this._pendingResolve=t._pendingResolve.then(()=>{this._pendingResolve=void 0,this._resolveDef()}):this._resolveDef())}_setParent(t=this._parent){t&&(this._instance.parent=t._instance,this._inheritParentContext(t))}_inheritParentContext(t=this._parent){t&&this._app&&Object.setPrototypeOf(this._app._context.provides,t._instance.provides)}disconnectedCallback(){this._connected=!1,Bi(()=>{this._connected||(this._ob&&(this._ob.disconnect(),this._ob=null),this._app&&this._app.unmount(),this._instance&&(this._instance.ce=void 0),this._app=this._instance=null,this._teleportTargets&&(this._teleportTargets.clear(),this._teleportTargets=void 0))})}_processMutations(t){for(const r of t)this._setAttr(r.attributeName)}_resolveDef(){if(this._pendingResolve)return;for(let i=0;i<this.attributes.length;i++)this._setAttr(this.attributes[i].name);this._ob=new MutationObserver(this._processMutations.bind(this)),this._ob.observe(this,{attributes:!0});const t=(i,n=!1)=>{this._resolved=!0,this._pendingResolve=void 0;const{props:a,styles:s}=i;let o;if(a&&!Le(a))for(const l in a){const u=a[l];(u===Number||u&&u.type===Number)&&(l in this._props&&(this._props[l]=$_(this._props[l])),(o||(o=Object.create(null)))[ar(l)]=!0)}this._numberProps=o,this._resolveProps(i),this.shadowRoot&&this._applyStyles(s),this._mount(i)},r=this._def.__asyncLoader;r?this._pendingResolve=r().then(i=>{i.configureApp=this._def.configureApp,t(this._def=i,!0)}):t(this._def)}_mount(t){this._app=this._createApp(t),this._inheritParentContext(),t.configureApp&&t.configureApp(this._app),this._app._ceVNode=this._createVNode(),this._app.mount(this._root);const r=this._instance&&this._instance.exposed;if(r)for(const i in r)Kt(this,i)||Object.defineProperty(this,i,{get:()=>le(r[i])})}_resolveProps(t){const{props:r}=t,i=Le(r)?r:Object.keys(r||{});for(const n of Object.keys(this))n[0]!=="_"&&i.includes(n)&&this._setProp(n,this[n]);for(const n of i.map(ar))Object.defineProperty(this,n,{get(){return this._getProp(n)}
19,set(a){this._setProp(n,a,!0,!this._patching)}})}_setAttr(t){if(t.startsWith("data-v-"))return;const r=this.hasAttribute(t);let i=r?this.getAttribute(t):T5;const n=ar(t);r&&this._numberProps&&this._numberProps[n]&&(i=$_(i)),this._setProp(n,i,!1,!0)}_getProp(t){return this._props[t]}_setProp(t,r,i=!0,n=!1){if(r!==this._props[t]&&(this._dirty=!0,r===T5?delete this._props[t]:(this._props[t]=r,t==="key"&&this._app&&(this._app._ceVNode.key=r)),n&&this._instance&&this._update(),i)){const a=this._ob;a&&(this._processMutations(a.takeRecords()),a.disconnect()),r===!0?this.setAttribute(Un(t),""):typeof r=="string"||typeof r=="number"?this.setAttribute(Un(t),r+""):r||this.removeAttribute(Un(t)),a&&a.observe(this,{attributes:!0})}}_update(){const t=this._createVNode();this._app&&(t.appContext=this._app._context),mI(t,this._root)}_createVNode(){const t={};this.shadowRoot||(t.onVnodeMounted=t.onVnodeUpdated=this._renderSlots.bind(this));const r=be(this._def,Ct(t,this._props));return this._instance||(r.ce=i=>{this._instance=i,i.ce=this,i.isCE=!0;const n=(a,s)=>{this.dispatchEvent(new CustomEvent(a,Ky(s[0])?Ct({detail:s},s[0]):{detail:s}))};i.emit=(a,...s)=>{n(a,s),Un(a)!==a&&n(Un(a),s)},this._setParent()}),r}_applyStyles(t,r,i){if(!t)return;if(r){if(r===this._def||this._styleChildren.has(r))return;this._styleChildren.add(r)}const n=this._nonce,a=this.shadowRoot,s=i?this._getStyleAnchor(i)||this._getStyleAnchor(this._def):this._getRootStyleInsertionAnchor(a);let o=null;for(let l=t.length-1;l>=0;l--){const u=document.createElement("style");n&&u.setAttribute("nonce",n),u.textContent=t[l],a.insertBefore(u,o||s),o=u,l===0&&(i||this._styleAnchors.set(this._def,u),r&&this._styleAnchors.set(r,u))}}_getStyleAnchor(t){if(!t)return null;const r=this._styleAnchors.get(t);return r&&r.parentNode===this.shadowRoot?r:(r&&this._styleAnchors.delete(t),null)}_getRootStyleInsertionAnchor(t){for(let r=0;r<t.childNodes.length;r++){const i=t.childNodes[r];if(!(i instanceof HTMLStyleElement))return i}return null}_parseSlots(){const t=this._slots={};let r;for(;r=this.firstChild;){const i=r.nodeType===1&&r.getAttribute("slot")||"default";(t[i]||(t[i]=[])).push(r),this.removeChild(r)}}_renderSlots(){const t=this._getSlots(),r=this._instance.type.__scopeId;for(let i=0;i<t.length;i++){const n=t[i],a=n.getAttribute("name")||"default",s=this._slots[a],o=n.parentNode;if(s)for(const l of s){if(r&&l.nodeType===1){const u=r+"-s",c=document.createTreeWalker(l,1);l.setAttribute(u,"");let d;for(;d=c.nextNode();)d.setAttribute(u,"")}o.insertBefore(l,n)}else for(;n.firstChild;)o.insertBefore(n.firstChild,n);o.removeChild(n)}}_getSlots(){const t=[this];this._teleportTargets&&t.push(...this._teleportTargets);const r=new Set;for(const i of t){const n=i.querySelectorAll("slot");for(let a=0;a<n.length;a++)r.add(n[a])}return Array.from(r)}_injectChildStyle(t,r){this._applyStyles(t.styles,t,r)}_beginPatch(){this._patching=!0,this._dirty=!1}_endPatch(){this._patching=!1,this._dirty&&this._instance&&this._update()}_hasShadowRoot(){return this._def.shadowRoot!==!1}_removeChildStyle(t){}}function sI(e){const t=pn(),r=t&&t.ce;return r||null}function nU(){const e=sI();return e&&e.shadowRoot}function aU(e="$style"){{const t=pn();if(!t)return Dt;const r=t.type.__cssModules;if(!r)return Dt;const i=r[e];return i||Dt}}const oI=new WeakMap,lI=new WeakMap,z_=Symbol("_moveCb"),C5=Symbol("_enterCb"),sU=e=>(delete e.props.mode,e),oU=sU({name:"TransitionGroup",props:Ct({},JM,{tag:String,moveClass:String}),setup(e,{slots:t}){const r=pn(),i=k3();let n,a;return jh(()=>{if(!n.length)return;const s=e.moveClass||`${e.name||"v"}-move`;if(!hU(n[0].el,r.vnode.el,s)){n=[];return}n.forEach(uU),n.forEach(cU);const o=n.filter(dU);k2(r.vnode.el),o.forEach(l=>{const u=l.el,c=u.style;zs(u,s),c.transform=c.webkitTransform=c.transitionDuration="";const d=u[z_]=h=>{h&&h.target!==u||(!h||h.propertyName.endsWith("transform"))&&(u.removeEventListener("transitionend",d),u[z_]=null,Cl(u,s))};u.addEventListener("transitionend",d)}),n=[]}),()=>{const s=Ft(e),o=QM(s);let l=s.tag||xe;if(n=[],a)for(let u=0;u<a.length;u++){const c=a[u];c.el&&c.el instanceof Element&&(n.push(c),Qo(c,ih(c,o,i,r)),oI.set(c,uI(c.el)))}a=t.default?l1(t.default()):[];for(let u=0;u<a.length;u++){const c=a[u];c.key!=null&&Qo(c,ih(c,o,i,r))}return be(l,null,a)}}}),lU=oU;function uU(e){const t=e.el;t[z_]&&t[z_](),t[C5]&&t[C5]()}function cU(e){lI.set(e,uI(e.el))}function dU(e){const t=oI.get(e),r=lI.get(e),i=t.left-r.left,n=t.top-r.top;if(i||n){const a=e.el,s=a.style,o=a.getBoundingClientRect();let l=1,u=1;return a.offsetWidth&&(l=o.width/a.offsetWidth),a.offsetHeight&&(u=o.height/a.offsetHeight),(!Number.isFinite(l)||l===0)&&(l=1),(!Number.isFinite(u)||u===0)&&(u=1),Math.abs(l-1)<.01&&(l=1),Math.abs(u-1)<.01&&(u=1),s.transform=s.webkitTransform=`translate(${i/l}px,${n/u}px)`,s.transitionDuration="0s",e}}function uI(e){const t=e.getBoundingClientRect();return{left:t.left,top:t.top}}function hU(e,t,r){const i=e.cloneNode(),n=e[ah];
vendor: 65,282 bytes, lines 19-32
19n&&n.forEach(o=>{o.split(/\s+/).forEach(l=>l&&i.classList.remove(l))}),r.split(/\s+/).forEach(o=>o&&i.classList.add(o)),i.style.display="none";const a=t.nodeType===1?t:t.parentNode;a.appendChild(i);const{hasTransform:s}=eI(i);return a.removeChild(i),s}const tu=e=>{const t=e.props["onUpdate:modelValue"]||!1;return Le(t)?r=>Ad(t,r):t};function fU(e){e.target.composing=!0}function k5(e){const t=e.target;t.composing&&(t.composing=!1,t.dispatchEvent(new Event("input")))}const Ja=Symbol("_assign");function E5(e,t,r){return t&&(e=e.trim()),r&&(e=Qy(e)),e}const ui={created(e,{modifiers:{lazy:t,trim:r,number:i}},n){e[Ja]=tu(n);const a=i||n.props&&n.props.type==="number";Io(e,t?"change":"input",s=>{s.target.composing||e[Ja](E5(e.value,r,a))}),(r||a)&&Io(e,"change",()=>{e.value=E5(e.value,r,a)}),t||(Io(e,"compositionstart",fU),Io(e,"compositionend",k5),Io(e,"change",k5))},mounted(e,{value:t}){e.value=t??""},beforeUpdate(e,{value:t,oldValue:r,modifiers:{lazy:i,trim:n,number:a}},s){if(e[Ja]=tu(s),e.composing)return;const o=(a||e.type==="number")&&!/^0\d/.test(e.value)?Qy(e.value):e.value,l=t??"";o!==l&&(document.activeElement===e&&e.type!=="range"&&(i&&t===r||n&&e.value.trim()===l)||(e.value=l))}},_s={deep:!0,created(e,t,r){e[Ja]=tu(r),Io(e,"change",()=>{const i=e._modelValue,n=sh(e),a=e.checked,s=e[Ja];if(Le(i)){const o=t1(i,n),l=o!==-1;if(a&&!l)s(i.concat(n));else if(!a&&l){const u=[...i];u.splice(o,1),s(u)}}else if(Mc(i)){const o=new Set(i);a?o.add(n):o.delete(n),s(o)}else s(cI(e,a))})},mounted:P5,beforeUpdate(e,t,r){e[Ja]=tu(r),P5(e,t,r)}};function P5(e,{value:t,oldValue:r},i){e._modelValue=t;let n;if(Le(t))n=t1(t,i.props.value)>-1;else if(Mc(t))n=t.has(i.props.value);else{if(t===r)return;n=Ko(t,cI(e,!0))}e.checked!==n&&(e.checked=n)}const p1={created(e,{value:t},r){e.checked=Ko(t,r.props.value),e[Ja]=tu(r),Io(e,"change",()=>{e[Ja](sh(e))})},beforeUpdate(e,{value:t,oldValue:r},i){e[Ja]=tu(i),t!==r&&(e.checked=Ko(t,i.props.value))}},Yl={deep:!0,created(e,{value:t,modifiers:{number:r}},i){const n=Mc(t);Io(e,"change",()=>{const a=Array.prototype.filter.call(e.options,s=>s.selected).map(s=>r?Qy(sh(s)):sh(s));e[Ja](e.multiple?n?new Set(a):a:a[0]),e._assigning=!0,Bi(()=>{e._assigning=!1})}),e[Ja]=tu(i)},mounted(e,{value:t}){M5(e,t)},beforeUpdate(e,t,r){e[Ja]=tu(r)},updated(e,{value:t}){e._assigning||M5(e,t)}};function M5(e,t){const r=e.multiple,i=Le(t);if(!(r&&!i&&!Mc(t))){for(let n=0,a=e.options.length;n<a;n++){const s=e.options[n],o=sh(s);if(r)if(i){const l=typeof o;l==="string"||l==="number"?s.selected=t.some(u=>String(u)===String(o)):s.selected=t1(t,o)>-1}else s.selected=t.has(o);else if(Ko(sh(s),t)){e.selectedIndex!==n&&(e.selectedIndex=n);return}}!r&&e.selectedIndex!==-1&&(e.selectedIndex=-1)}}function sh(e){return"_value"in e?e._value:e.value}function cI(e,t){const r=t?"_trueValue":"_falseValue";return r in e?e[r]:t}const m1={created(e,t,r){zg(e,t,r,null,"created")},mounted(e,t,r){zg(e,t,r,null,"mounted")},beforeUpdate(e,t,r,i){zg(e,t,r,i,"beforeUpdate")},updated(e,t,r,i){zg(e,t,r,i,"updated")}};function dI(e,t){switch(e){case"SELECT":return Yl;case"TEXTAREA":return ui;default:switch(t){case"checkbox":return _s;case"radio":return p1;default:return ui}}}function zg(e,t,r,i,n){const s=dI(e.tagName,r.props&&r.props.type)[n];s&&s(e,t,r,i)}function pU(){ui.getSSRProps=({value:e})=>({value:e}),p1.getSSRProps=({value:e},t)=>{if(t.props&&Ko(t.props.value,e))return{checked:!0}},_s.getSSRProps=({value:e},t)=>{if(Le(e)){if(t.props&&t1(e,t.props.value)>-1)return{checked:!0}}else if(Mc(e)){if(t.props&&e.has(t.props.value))return{checked:!0}}else if(e)return{checked:!0}},m1.getSSRProps=(e,t)=>{if(typeof t.type!="string")return;const r=dI(t.type.toUpperCase(),t.props&&t.props.type);if(r.getSSRProps)return r.getSSRProps(e,t)}}const mU=["ctrl","shift","alt","meta"],gU={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)=>mU.some(r=>e[`${r}Key`]&&!t.includes(r))},di=(e,t)=>{if(!e)return e;const r=e._withMods||(e._withMods={}),i=t.join(".");return r[i]||(r[i]=((n,...a)=>{for(let s=0;s<t.length;s++){const o=gU[t[s]];if(o&&o(n,t))return}return e(n,...a)}))},_U={esc:"escape",space:" ",up:"arrow-up",left:"arrow-left",right:"arrow-right",down:"arrow-down",delete:"backspace"},Ao=(e,t)=>{const r=e._withKeys||(e._withKeys={}),i=t.join(".");return r[i]||(r[i]=(n=>{if(!("key"in n))return;const a=Un(n.key);if(t.some(s=>s===a||_U[s]===a))return e(n)}))},hI=Ct({patchProp:nI},KM);let op,I5=!1;function fI(){return op||(op=MM(hI))}function pI(){return op=I5?op:IM(hI),I5=!0,op}const mI=((...e)=>{fI().render(...e)}),yU=((...e)=>{pI().hydrate(...e)}),N_=((...e)=>{const t=fI().createApp(...e),{mount:r}=t;return t.mount=i=>{const n=yI(i);if(!n)return;const a=t._component;!nt(a)&&!a.render&&!a.template&&(a.template=n.innerHTML),n.nodeType===1&&(n.textContent="");const s=r(n,!1,_I(n));return n instanceof Element&&(n.removeAttribute("v-cloak"),n.setAttribute("data-v-app","")),s},t}),gI=((...e)=>{const t=pI().createApp(...e),{mount:r}=t;return t.mount=i=>{const n=yI(i);if(n)return r(n,!0,_I(n))},t});function _I(e){if(e instanceof SVGElement)return"svg";if(typeof MathMLElement=="function"&&e instanceof MathMLElement)return"mathml"}function yI(e){return ft(e)?document.querySelector(e):e}let A5=!1;const vU=()=>{A5||(A5=!0,pU(),Vj())},bU=Object.freeze(Object.defineProperty({__proto__:null,BaseTransition:rM,BaseTransitionPropsValidators:E3,Comment:ti,DeprecationTypes:Lj,EffectScope:v3,ErrorCodes:iB,ErrorTypeStrings:Pj,Fragment:xe,KeepAlive:PB,ReactiveEffect:zp,Static:Ku,Suspense:hj,Teleport:QP,Text:Hl,TrackOpTypes:KN,Transition:Ym,TransitionGroup:lU,TriggerOpTypes:XN,VueElement:f1,assertNumber:rB,callWithAsyncErrorHandling:is,callWithErrorHandling:Bh,camelize:ar,capitalize:Ic,cloneVNode:ks,compatUtils:Oj,computed:H,createApp:N_,createBlock:Mt,createCommentVNode:X,createElementBlock:M,createElementVNode:b,createHydrationRenderer:IM,createPropsRestProxy:VB,createRenderer:MM,createSSRApp:gI,createSlots:pM,createStaticVNode:so,createTextVNode:Ze,createVNode:be,customRef:FP,defineAsyncComponent:kB,defineComponent:fr,defineCustomElement:aI,defineEmits:RB,defineExpose:OB,defineModel:zB,defineOptions:LB,defineProps:DB,defineSSRCustomElement:rU,defineSlots:FB,devtools:Mj,effect:bN,effectScope:b3,getCurrentInstance:pn,getCurrentScope:x3,getCurrentWatcher:JN,getTransitionRawChildren:l1,guardReactiveProps:nh,h:qa,handleError:Ac,hasInjectionContext:GP,hydrate:yU,hydrateOnIdle:xB,hydrateOnInteraction:TB,hydrateOnMediaQuery:SB,hydrateOnVisible:$B,initCustomFormatter:Cj,initDirectivesForSSR:vU,inject:Gi,isMemoSame:YM,isProxy:Vm,isReactive:xs,isReadonly:ao,isRef:er,isRuntimeOnly:$j,isShallow:Gn,isVNode:el,markRaw:mc,mergeDefaults:UB,mergeModels:Hp,mergeProps:Ha,nextTick:Bi,nodeOps:KM,normalizeClass:pe,normalizeProps:Gu,normalizeStyle:Qt,onActivated:aM,onBeforeMount:lM,onBeforeUnmount:ra,onBeforeUpdate:M3,onDeactivated:sM,onErrorCaptured:hM,onMounted:or,onRenderTracked:dM,onRenderTriggered:cM,onScopeDispose:bP,onServerPrefetch:uM,onUnmounted:ss,onUpdated:jh,onWatcherCleanup:NP,openBlock:k,patchProp:nI,popScopeId:lB,provide:xa,proxyRefs:T3,pushScopeId:oB,queuePostFlushCb:Up,reactive:An,readonly:T_,ref:se,registerRuntimeCompiler:qM,render:mI,renderList:Me,renderSlot:ws,resolveComponent:qr,resolveDirective:A3,resolveDynamicComponent:c1,resolveFilter:Rj,resolveTransitionHooks:ih,setBlockTracking:Wp,setDevtoolsHook:Ij,setTransitionHooks:Qo,shallowReactive:jp,shallowReadonly:BN,shallowRef:Yu,ssrContextKey:HP,ssrUtils:Dj,stop:xN,toDisplayString:Q,toHandlerKey:Id,toHandlers:mM,toRaw:Ft,toRef:Wu,toRefs:s1,toValue:VN,transformVNodeArgs:yj,triggerRef:UN,unref:le,useAttrs:jB,useCssModule:aU,useCssVars:iI,useHost:sI,useId:nM,useModel:Al,useSSRContext:YP,useShadowRoot:nU,useSlots:BB,useTemplateRef:pB,useTransitionState:k3,vModelCheckbox:_s,vModelDynamic:m1,vModelRadio:p1,vModelSelect:Yl,vModelText:ui,vShow:Dn,version:WM,warn:Ej,watch:tt,watchEffect:Rd,watchPostEffect:cB,watchSyncEffect:WP,withAsyncContext:qB,withCtx:_t,withDefaults:NB,withDirectives:it,withKeys:Ao,withMemo:kj,withModifiers:di,withScopeId:uB},Symbol.toStringTag,{value:"Module"}));/** 20* @vue/compiler-core v3.5.30 21* (c) 2018-present Yuxi (Evan) You and Vue contributors 22* @license MIT 23**/const Zp=Symbol(""),lp=Symbol(""),B3=Symbol(""),B_=Symbol(""),vI=Symbol(""),yc=Symbol(""),bI=Symbol(""),xI=Symbol(""),j3=Symbol(""),U3=Symbol(""),Wm=Symbol(""),V3=Symbol(""),wI=Symbol(""),q3=Symbol(""),G3=Symbol(""),H3=Symbol(""),Y3=Symbol(""),W3=Symbol(""),Z3=Symbol(""),$I=Symbol(""),SI=Symbol(""),g1=Symbol(""),j_=Symbol(""),K3=Symbol(""),X3=Symbol(""),Kp=Symbol(""),Zm=Symbol(""),J3=Symbol(""),P2=Symbol(""),xU=Symbol(""),M2=Symbol(""),U_=Symbol(""),wU=Symbol(""),$U=Symbol(""),Q3=Symbol(""),SU=Symbol(""),TU=Symbol(""),e4=Symbol(""),TI=Symbol(""),oh={[Zp]:"Fragment",[lp]:"Teleport",[B3]:"Suspense",[B_]:"KeepAlive",[vI]:"BaseTransition",[yc]:"openBlock",[bI]:"createBlock",[xI]:"createElementBlock",[j3]:"createVNode",[U3]:"createElementVNode",[Wm]:"createCommentVNode",[V3]:"createTextVNode",[wI]:"createStaticVNode",[q3]:"resolveComponent",[G3]:"resolveDynamicComponent",[H3]:"resolveDirective",[Y3]:"resolveFilter",[W3]:"withDirectives",[Z3]:"renderList",[$I]:"renderSlot",[SI]:"createSlots",[g1]:"toDisplayString",[j_]:"mergeProps",[K3]:"normalizeClass",[X3]:"normalizeStyle",[Kp]:"normalizeProps",[Zm]:"guardReactiveProps",[J3]:"toHandlers",[P2]:"camelize",[xU]:"capitalize",[M2]:"toHandlerKey",[U_]:"setBlockTracking",[wU]:"pushScopeId",[$U]:"popScopeId",[Q3]:"withCtx",[SU]:"unref",[TU]:"isRef",[e4]:"withMemo",[TI]:"isMemoSame"};function CU(e){Object.getOwnPropertySymbols(e).forEach(t=>{oh[t]=e[t]})}const Pa={start:{line:1,column:1,offset:0},end:{line:1,column:1,offset:0},source:""};function kU(e,t=""){return{type:0,source:t,children:e,helpers:new Set,components:[],directives:[],hoists:[],imports:[],cached:[],temps:0,codegenNode:void 0,loc:Pa}}function Xp(e,t,r,i,n,a,s,o=!1,l=!1,u=!1,c=Pa){return e&&(o?(e.helper(yc),e.helper(ch(e.inSSR,u))):e.helper(uh(e.inSSR,u)),s&&e.helper(W3)),{type:13,tag:t,props:r,children:i,patchFlag:n,dynamicProps:a,directives:s,isBlock:o,disableTracking:l,isComponent:u,loc:c}}function Xu(e,t=Pa){return{type:17,loc:t,elements:e}}function Ya(e,t=Pa){return{type:15,loc:t,properties:e}}function hi(e,t){return{type:16,loc:Pa,key:ft(e)?bt(e,!0):e,value:t}}function bt(e,t=!1,r=Pa,i=0){return{type:4,loc:r,content:e,isStatic:t,constType:t?3:i}}function $s(e,t=Pa){return{type:8,loc:t,children:e}}function yi(e,t=[],r=Pa){return{type:14,loc:r,callee:e,arguments:t}}function lh(e,t=void 0,r=!1,i=!1,n=Pa){return{type:18,params:e,returns:t,newline:r,isSlot:i,loc:n}}function I2(e,t,r,i=!0){return{type:19,test:e,consequent:t,alternate:r,newline:i,loc:Pa}}function EU(e,t,r=!1,i=!1){return{type:20,index:e,value:t,needPauseTracking:r,inVOnce:i,needArraySpread:!1,loc:Pa}}function PU(e){return{type:21,body:e,loc:Pa}}function uh(e,t){return e||t?j3:U3}function ch(e,t){return e||t?bI:xI}function t4(e,{helper:t,removeHelper:r,inSSR:i}){e.isBlock||(e.isBlock=!0,r(uh(i,e.isComponent)),t(yc),t(ch(i,e.isComponent)))}const D5=new Uint8Array([123,123]),R5=new Uint8Array([125,125]);function O5(e){return e>=97&&e<=122||e>=65&&e<=90}function sa(e){return e===32||e===10||e===9||e===12||e===13}function bl(e){return e===47||e===62||sa(e)}function V_(e){const t=new Uint8Array(e.length);for(let r=0;r<e.length;r++)t[r]=e.charCodeAt(r);return t}const Ki={Cdata:new Uint8Array([67,68,65,84,65,91]),CdataEnd:new Uint8Array([93,93,62]),CommentEnd:new Uint8Array([45,45,62]),ScriptEnd:new Uint8Array([60,47,115,99,114,105,112,116]),StyleEnd:new Uint8Array([60,47,115,116,121,108,101]),TitleEnd:new Uint8Array([60,47,116,105,116,108,101]),TextareaEnd:new Uint8Array([60,47,116,101,120,116,97,114,101,97])};class MU{constructor(t,r){this.stack=t,this.cbs=r,this.state=1,this.buffer="",this.sectionStart=0,this.index=0,this.entityStart=0,this.baseState=1,this.inRCDATA=!1,this.inXML=!1,this.inVPre=!1,this.newlines=[],this.mode=0,this.delimiterOpen=D5,this.delimiterClose=R5,this.delimiterIndex=-1,this.currentSequence=void 0,this.sequenceIndex=0}get inSFCRoot(){return this.mode===2&&this.stack.length===0}reset(){this.state=1,this.mode=0,this.buffer="",this.sectionStart=0,this.index=0,this.baseState=1,this.inRCDATA=!1,this.currentSequence=void 0,this.newlines.length=0,this.delimiterOpen=D5,this.delimiterClose=R5}getPos(t){let r=1,i=t+1;const n=this.newlines.length;let a=-1;if(n>100){let s=-1,o=n;for(;s+1<o;){const l=s+o>>>1;this.newlines[l]<t?s=l:o=l}a=s}else for(let s=n-1;s>=0;s--)if(t>this.newlines[s]){a=s;break}return a>=0&&(r=a+2,i=t-this.newlines[a]),{column:i,line:r,offset:t}}peek(){return this.buffer.charCodeAt(this.index+1)}stateText(t){t===60?(this.index>this.sectionStart&&this.cbs.ontext(this.sectionStart,this.index),this.state=5,this.sectionStart=this.index):!this.inVPre&&t===this.delimiterOpen[0]&&(this.state=2,this.delimiterIndex=0,this.stateInterpolationOpen(t))}stateInterpolationOpen(t){if(t===this.delimiterOpen[this.delimiterIndex])if(this.delimiterIndex===this.delimiterOpen.length-1){const r=this.index+1-this.delimiterOpen.length;r>this.sectionStart&&this.cbs.ontext(this.sectionStart,r),this.state=3,this.sectionStart=r}else this.delimiterIndex++;else this.inRCDATA?(this.state=32,this.stateInRCDATA(t)):(this.state=1,this.stateText(t))}stateInterpolation(t){t===this.delimiterClose[0]&&(this.state=4,this.delimiterIndex=0,this.stateInterpolationClose(t))}stateInterpolationClose(t){t===this.delimiterClose[this.delimiterIndex]?this.delimiterIndex===this.delimiterClose.length-1?(this.cbs.oninterpolation(this.sectionStart,this.index+1),this.inRCDATA?this.state=32:this.state=1,this.sectionStart=this.index+1):this.delimiterIndex++:(this.state=3,this.stateInterpolation(t))}stateSpecialStartSequence(t){const r=this.sequenceIndex===this.currentSequence.length;if(!(r?bl(t):(t|32)===this.currentSequence[this.sequenceIndex]))this.inRCDATA=!1;else if(!r){this.sequenceIndex++;return}this.sequenceIndex=0,this.state=6,this.stateInTagName(t)}stateInRCDATA(t){if(this.sequenceIndex===this.currentSequence.length){if(t===62||sa(t)){const r=this.index-this.currentSequence.length;if(this.sectionStart<r){const i=this.index;this.index=r,this.cbs.ontext(this.sectionStart,r),this.index=i}this.sectionStart=r+2,this.stateInClosingTagName(t),this.inRCDATA=!1;return}this.sequenceIndex=0}(t|32)===this.currentSequence[this.sequenceIndex]?this.sequenceIndex+=1:this.sequenceIndex===0?this.currentSequence===Ki.TitleEnd||this.currentSequence===Ki.TextareaEnd&&!this.inSFCRoot?!this.inVPre&&t===this.delimiterOpen[0]&&(this.state=2,this.delimiterIndex=0,this.stateInterpolationOpen(t)):this.fastForwardTo(60)&&(this.sequenceIndex=1):this.sequenceIndex=+(t===60)}stateCDATASequence(t){t===Ki.Cdata[this.sequenceIndex]?++this.sequenceIndex===Ki.Cdata.length&&(this.state=28,this.currentSequence=Ki.CdataEnd,this.sequenceIndex=0,this.sectionStart=this.index+1):(this.sequenceIndex=0,this.state=23,this.stateInDeclaration(t))}fastForwardTo(t){for(;++this.index<this.buffer.length;){const r=this.buffer.charCodeAt(this.index);if(r===10&&this.newlines.push(this.index),r===t)return!0}return this.index=this.buffer.length-1,!1}stateInCommentLike(t){t===this.currentSequence[this.sequenceIndex]?++this.sequenceIndex===this.currentSequence.length&&(this.currentSequence===Ki.CdataEnd?this.cbs.oncdata(this.sectionStart,this.index-2):this.cbs.oncomment(this.sectionStart,this.index-2),this.sequenceIndex=0,this.sectionStart=this.index+1,this.state=1):this.sequenceIndex===0?this.fastForwardTo(this.currentSequence[0])&&(this.sequenceIndex=1):t!==this.currentSequence[this.sequenceIndex-1]&&(this.sequenceIndex=0)}startSpecial(t,r){this.enterRCDATA(t,r),this.state=31}enterRCDATA(t,r){this.inRCDATA=!0,this.currentSequence=t,this.sequenceIndex=r}stateBeforeTagName(t){t===33?(this.state=22,this.sectionStart=this.index+1):t===63?(this.state=24,this.sectionStart=this.index+1):O5(t)?(this.sectionStart=this.index,this.mode===0?this.state=6:this.inSFCRoot?this.state=34:this.inXML?this.state=6:t===116?this.state=30:this.state=t===115?29:6):t===47?this.state=8:(this.state=1,this.stateText(t))}stateInTagName(t){bl(t)&&this.handleTagName(t)}stateInSFCRootTagName(t){if(bl(t)){const r=this.buffer.slice(this.sectionStart,this.index);r!=="template"&&this.enterRCDATA(V_("</"+r),0),this.handleTagName(t)}}handleTagName(t){this.cbs.onopentagname(this.sectionStart,this.index),this.sectionStart=-1,this.state=11,this.stateBeforeAttrName(t)}stateBeforeClosingTagName(t){sa(t)||(t===62?(this.state=1,this.sectionStart=this.index+1):(this.state=O5(t)?9:27,this.sectionStart=this.index))}stateInClosingTagName(t){(t===62||sa(t))&&(this.cbs.onclosetag(this.sectionStart,this.index),this.sectionStart=-1,this.state=10,this.stateAfterClosingTagName(t))}stateAfterClosingTagName(t){t===62&&(this.state=1,this.sectionStart=this.index+1)}stateBeforeAttrName(t){t===62?(this.cbs.onopentagend(this.index),this.inRCDATA?this.state=32:this.state=1,this.sectionStart=this.index+1):t===47?this.state=7:t===60&&this.peek()===47?(this.cbs.onopentagend(this.index),this.state=5,this.sectionStart=this.index):sa(t)||this.handleAttrStart(t)}handleAttrStart(t){t===118&&this.peek()===45?(this.state=13,this.sectionStart=this.index):t===46||t===58||t===64||t===35?(this.cbs.ondirname(this.index,this.index+1),this.state=14,this.sectionStart=this.index+1):(this.state=12,this.sectionStart=this.index)}stateInSelfClosingTag(t){t===62?(this.cbs.onselfclosingtag(this.index),this.state=1,this.sectionStart=this.index+1,this.inRCDATA=!1):sa(t)||(this.state=11,this.stateBeforeAttrName(t))}stateInAttrName(t){(t===61||bl(t))&&(this.cbs.onattribname(this.sectionStart,this.index),this.handleAttrNameEnd(t))}stateInDirName(t){t===61||bl(t)?(this.cbs.ondirname(this.sectionStart,this.index),this.handleAttrNameEnd(t)):t===58?(this.cbs.ondirname(this.sectionStart,this.index),this.state=14,this.sectionStart=this.index+1):t===46&&(this.cbs.ondirname(this.sectionStart,this.index),this.state=16,this.sectionStart=this.index+1)}stateInDirArg(t){t===61||bl(t)?(this.cbs.ondirarg(this.sectionStart,this.index),this.handleAttrNameEnd(t)):t===91?this.state=15:t===46&&(this.cbs.ondirarg(this.sectionStart,this.index),this.state=16,this.sectionStart=this.index+1)}stateInDynamicDirArg(t){t===93?this.state=14:(t===61||bl(t))&&(this.cbs.ondirarg(this.sectionStart,this.index+1),this.handleAttrNameEnd(t))}stateInDirModifier(t){t===61||bl(t)?(this.cbs.ondirmodifier(this.sectionStart,this.index),this.handleAttrNameEnd(t)):t===46&&(this.cbs.ondirmodifier(this.sectionStart,this.index),this.sectionStart=this.index+1)}handleAttrNameEnd(t){this.sectionStart=this.index,this.state=17,this.cbs.onattribnameend(this.index),this.stateAfterAttrName(t)}stateAfterAttrName(t){t===61?this.state=18:t===47||t===62?(this.cbs.onattribend(0,this.sectionStart),this.sectionStart=-1,this.state=11,this.stateBeforeAttrName(t)):sa(t)||(this.cbs.onattribend(0,this.sectionStart),this.handleAttrStart(t))}stateBeforeAttrValue(t){t===34?(this.state=19,this.sectionStart=this.index+1):t===39?(this.state=20,this.sectionStart=this.index+1):sa(t)||(this.sectionStart=this.index,this.state=21,this.stateInAttrValueNoQuotes(t))}handleInAttrValue(t,r){(t===r||this.fastForwardTo(r))&&(this.cbs.onattribdata(this.sectionStart,this.index),this.sectionStart=-1,this.cbs.onattribend(r===34?3:2,this.index+1),this.state=11)}stateInAttrValueDoubleQuotes(t){this.handleInAttrValue(t,34)}stateInAttrValueSingleQuotes(t){this.handleInAttrValue(t,39)}stateInAttrValueNoQuotes(t){sa(t)||t===62?(this.cbs.onattribdata(this.sectionStart,this.index),this.sectionStart=-1,this.cbs.onattribend(1,this.index),this.state=11,this.stateBeforeAttrName(t)):(t===39||t===60||t===61||t===96)&&this.cbs.onerr(18,this.index)}stateBeforeDeclaration(t){t===91?(this.state=26,this.sequenceIndex=0):this.state=t===45?25:23}stateInDeclaration(t){(t===62||this.fastForwardTo(62))&&(this.state=1,this.sectionStart=this.index+1)}stateInProcessingInstruction(t){(t===62||this.fastForwardTo(62))&&(this.cbs.onprocessinginstruction(this.sectionStart,this.index),this.state=1,this.sectionStart=this.index+1)}stateBeforeComment(t){t===45?(this.state=28,this.currentSequence=Ki.CommentEnd,this.sequenceIndex=2,this.sectionStart=this.index+1):this.state=23}stateInSpecialComment(t){(t===62||this.fastForwardTo(62))&&(this.cbs.oncomment(this.sectionStart,this.index),this.state=1,this.sectionStart=this.index+1)}stateBeforeSpecialS(t){t===Ki.ScriptEnd[3]?this.startSpecial(Ki.ScriptEnd,4):t===Ki.StyleEnd[3]?this.startSpecial(Ki.StyleEnd,4):(this.state=6,this.stateInTagName(t))}stateBeforeSpecialT(t){t===Ki.TitleEnd[3]?this.startSpecial(Ki.TitleEnd,4):t===Ki.TextareaEnd[3]?this.startSpecial(Ki.TextareaEnd,4):(this.state=6,this.stateInTagName(t))}startEntity(){}stateInEntity(){}parse(t){for(this.buffer=t;this.index<this.buffer.length;){const r=this.buffer.charCodeAt(this.index);switch(r===10&&this.state!==33&&this.newlines.push(this.index),this.state){case 1:{this.stateText(r);break}case 2:{this.stateInterpolationOpen(r);break}case 3:{this.stateInterpolation(r);break}case 4:{this.stateInterpolationClose(r);break}case 31:{this.stateSpecialStartSequence(r);break}case 32:{this.stateInRCDATA(r);break}case 26:{this.stateCDATASequence(r);break}case 19:{this.stateInAttrValueDoubleQuotes(r);break}case 12:{this.stateInAttrName(r);break}case 13:{this.stateInDirName(r);break}case 14:{this.stateInDirArg(r);break}case 15:{this.stateInDynamicDirArg(r);break}case 16:{this.stateInDirModifier(r);break}case 28:{this.stateInCommentLike(r);break}case 27:{this.stateInSpecialComment(r);break}case 11:{this.stateBeforeAttrName(r);break}case 6:{this.stateInTagName(r);break}case 34:{this.stateInSFCRootTagName(r);break}case 9:{this.stateInClosingTagName(r);break}case 5:{this.stateBeforeTagName(r);break}case 17:{this.stateAfterAttrName(r);break}case 20:{this.stateInAttrValueSingleQuotes(r);break}case 18:{this.stateBeforeAttrValue(r);break}case 8:{this.stateBeforeClosingTagName(r);break}case 10:{this.stateAfterClosingTagName(r);break}case 29:{this.stateBeforeSpecialS(r);break}case 30:{this.stateBeforeSpecialT(r);break}case 21:{this.stateInAttrValueNoQuotes(r);break}case 7:{this.stateInSelfClosingTag(r);break}case 23:{this.stateInDeclaration(r);break}case 22:{this.stateBeforeDeclaration(r);break}case 25:{this.stateBeforeComment(r);break}case 24:{this.stateInProcessingInstruction(r);break}case 33:{this.stateInEntity();break}}this.index++}this.cleanup(),this.finish()}cleanup(){this.sectionStart!==this.index&&(this.state===1||this.state===32&&this.sequenceIndex===0?(this.cbs.ontext(this.sectionStart,this.index),this.sectionStart=this.index):(this.state===19||this.state===20||this.state===21)&&(this.cbs.onattribdata(this.sectionStart,this.index),this.sectionStart=this.index))}finish(){this.handleTrailingData(),this.cbs.onend()}handleTrailingData(){const t=this.buffer.length;this.sectionStart>=t||(this.state===28?this.currentSequence===Ki.CdataEnd?this.cbs.oncdata(this.sectionStart,t):this.cbs.oncomment(this.sectionStart,t):this.state===6||this.state===11||this.state===18||this.state===17||this.state===12||this.state===13||this.state===14||this.state===15||this.state===16||this.state===20||this.state===19||this.state===21||this.state===9||this.cbs.ontext(this.sectionStart,t))}emitCodePoint(t,r){}}function L5(e,{compatConfig:t}){const r=t&&t[e];return e==="MODE"?r||3:r}function Ju(e,t){const r=L5("MODE",t),i=L5(e,t);return r===3?i===!0:i!==!1}function Jp(e,t,r,...i){return Ju(e,t)}function r4(e){throw e}function CI(e){}function wr(e,t,r,i){const n=`https://vuejs.org/error-reference/#compiler-${e}`,a=new SyntaxError(String(n));return a.code=e,a.loc=t,a}const Vn=e=>e.type===4&&e.isStatic;function kI(e){switch(e){case"Teleport":case"teleport":return lp;case"Suspense":case"suspense":return B3;case"KeepAlive":case"keep-alive":return B_;case"BaseTransition":case"base-transition":return vI}}const IU=/^$|^\d|[^\$\w\xA0-\uFFFF]/,i4=e=>!IU.test(e),EI=/[A-Za-z_$\xA0-\uFFFF]/,AU=/[\.\?\w$\xA0-\uFFFF]/,DU=/\s+[.[]\s*|\s*[.[]\s+/g,PI=e=>e.type===4?e.content:e.loc.source,RU=e=>{const t=PI(e).trim().replace(DU,o=>o.trim());let r=0,i=[],n=0,a=0,s=null;for(let o=0;o<t.length;o++){const l=t.charAt(o);switch(r){case 0:if(l==="[")i.push(r),r=1,n++;else if(l==="(")i.push(r),r=2,a++;else if(!(o===0?EI:AU).test(l))return!1;break;case 1:l==="'"||l==='"'||l==="`"?(i.push(r),r=3,s=l):l==="["?n++:l==="]"&&(--n||(r=i.pop()));break;case 2:if(l==="'"||l==='"'||l==="`")i.push(r),r=3,s=l;else if(l==="(")a++;else if(l===")"){if(o===t.length-1)return!1;--a||(r=i.pop())}break;case 3:l===s&&(r=i.pop(),s=null);break}}return!n&&!a},MI=RU,OU=/^\s*(?:async\s*)?(?:\([^)]*?\)|[\w$_]+)\s*(?::[^=]+)?=>|^\s*(?:async\s+)?function(?:\s+[\w$]+)?\s*\(/,LU=e=>OU.test(PI(e)),FU=LU;function Ba(e,t,r=!1){for(let i=0;i<e.props.length;i++){const n=e.props[i];if(n.type===7&&(r||n.exp)&&(ft(t)?n.name===t:t.test(n.name)))return n}}function _1(e,t,r=!1,i=!1){for(let n=0;n<e.props.length;n++){const a=e.props[n];if(a.type===6){if(r)continue;if(a.name===t&&(a.value||i))return a}else if(a.name==="bind"&&(a.exp||i)&&Lu(a.arg,t))return a}}function Lu(e,t){return!!(e&&Vn(e)&&e.content===t)}function zU(e){return e.props.some(t=>t.type===7&&t.name==="bind"&&(!t.arg||t.arg.type!==4||!t.arg.isStatic))}function Ov(e){return e.type===5||e.type===2}function F5(e){return e.type===7&&e.name==="pre"}function NU(e){return e.type===7&&e.name==="slot"}function q_(e){return e.type===1&&e.tagType===3}function G_(e){return e.type===1&&e.tagType===2}const BU=new Set([Kp,Zm]);function II(e,t=[]){if(e&&!ft(e)&&e.type===14){const r=e.callee;if(!ft(r)&&BU.has(r))return II(e.arguments[0],t.concat(e))}return[e,t]}function H_(e,t,r){let i,n=e.type===13?e.props:e.arguments[2],a=[],s;if(n&&!ft(n)&&n.type===14){const o=II(n);n=o[0],a=o[1],s=a[a.length-1]}if(n==null||ft(n))i=Ya([t]);else if(n.type===14){const o=n.arguments[0];!ft(o)&&o.type===15?z5(t,o)||o.properties.unshift(t):n.callee===J3?i=yi(r.helper(j_),[Ya([t]),n]):n.arguments.unshift(Ya([t])),!i&&(i=n)}else n.type===15?(z5(t,n)||n.properties.unshift(t),i=n):(i=yi(r.helper(j_),[Ya([t]),n]),s&&s.callee===Zm&&(s=a[a.length-2]));e.type===13?s?s.arguments[0]=i:e.props=i:s?s.arguments[0]=i:e.arguments[2]=i}function z5(e,t){let r=!1;if(e.key.type===4){const i=e.key.content;r=t.properties.some(n=>n.key.type===4&&n.key.content===i)}return r}function Qp(e,t){return`_${t}_${e.replace(/[^\w]/g,(r,i)=>r==="-"?"_":e.charCodeAt(i).toString())}`}function jU(e){return e.type===14&&e.callee===e4?e.arguments[1].returns:e}const UU=/([\s\S]*?)\s+(?:in|of)\s+(\S[\s\S]*)/;function AI(e){for(let t=0;t<e.length;t++)if(!sa(e.charCodeAt(t)))return!1;return!0}function n4(e){return e.type===2&&AI(e.content)||e.type===12&&n4(e.content)}function DI(e){return e.type===3||n4(e)}const RI={parseMode:"base",ns:0,delimiters:["{{","}}"],getNamespace:()=>0,isVoidTag:_d,isPreTag:_d,isIgnoreNewlineTag:_d,isCustomElement:_d,onError:r4,onWarn:CI,comments:!1,prefixIdentifiers:!1};let Xt=RI,em=null,Go="",tn=null,At=null,On="",bo=-1,ku=-1,a4=0,Dl=!1,A2=null;const Pr=[],Gr=new MU(Pr,{onerr:yo,ontext(e,t){Ng(Di(e,t),e,t)},ontextentity(e,t,r){Ng(e,t,r)},oninterpolation(e,t){if(Dl)return Ng(Di(e,t),e,t);let r=e+Gr.delimiterOpen.length,i=t-Gr.delimiterClose.length;for(;sa(Go.charCodeAt(r));)r++;for(;sa(Go.charCodeAt(i-1));)i--;let n=Di(r,i);n.includes("&")&&(n=Xt.decodeEntities(n,!1)),D2({type:5,content:j0(n,!1,Xr(r,i)),loc:Xr(e,t)})},onopentagname(e,t){const r=Di(e,t);tn={type:1,tag:r,ns:Xt.getNamespace(r,Pr[0],Xt.ns),tagType:0,props:[],children:[],loc:Xr(e-1,t),codegenNode:void 0}},onopentagend(e){B5(e)},onclosetag(e,t){const r=Di(e,t);if(!Xt.isVoidTag(r)){let i=!1;for(let n=0;n<Pr.length;n++)if(Pr[n].tag.toLowerCase()===r.toLowerCase()){i=!0,n>0&&yo(24,Pr[0].loc.start.offset);for(let s=0;s<=n;s++){const o=Pr.shift();B0(o,t,s<n)}break}i||yo(23,OI(e,60))}},onselfclosingtag(e){const t=tn.tag;tn.isSelfClosing=!0,B5(e),Pr[0]&&Pr[0].tag===t&&B0(Pr.shift(),e)},onattribname(e,t){At={type:6,name:Di(e,t),nameLoc:Xr(e,t),value:void 0,loc:Xr(e)}},ondirname(e,t){const r=Di(e,t),i=r==="."||r===":"?"bind":r==="@"?"on":r==="#"?"slot":r.slice(2);if(!Dl&&i===""&&yo(26,e),Dl||i==="")At={type:6,name:r,nameLoc:Xr(e,t),value:void 0,loc:Xr(e)};else if(At={type:7,name:i,rawName:r,exp:void 0,arg:void 0,modifiers:r==="."?[bt("prop")]:[],loc:Xr(e)},i==="pre"){Dl=Gr.inVPre=!0,A2=tn;const n=tn.props;for(let a=0;a<n.length;a++)n[a].type===7&&(n[a]=JU(n[a]))}},ondirarg(e,t){if(e===t)return;const r=Di(e,t);if(Dl&&!F5(At))At.name+=r,Fu(At.nameLoc,t);else{const i=r[0]!=="[";At.arg=j0(i?r:r.slice(1,-1),i,Xr(e,t),i?3:0)}},ondirmodifier(e,t){const r=Di(e,t);if(Dl&&!F5(At))At.name+="."+r,Fu(At.nameLoc,t);else if(At.name==="slot"){const i=At.arg;i&&(i.content+="."+r,Fu(i.loc,t))}else{const i=bt(r,!0,Xr(e,t));At.modifiers.push(i)}},onattribdata(e,t){On+=Di(e,t),bo<0&&(bo=e),ku=t},onattribentity(e,t,r){On+=e,bo<0&&(bo=t),ku=r},onattribnameend(e){const t=At.loc.start.offset,r=Di(t,e);At.type===7&&(At.rawName=r),tn.props.some(i=>(i.type===7?i.rawName:i.name)===r)&&yo(2,t)},onattribend(e,t){if(tn&&At){if(Fu(At.loc,t),e!==0)if(On.includes("&")&&(On=Xt.decodeEntities(On,!0)),At.type===6)At.name==="class"&&(On=FI(On).trim()),e===1&&!On&&yo(13,t),At.value={type:2,content:On,loc:e===1?Xr(bo,ku):Xr(bo-1,ku+1)},Gr.inSFCRoot&&tn.tag==="template"&&At.name==="lang"&&On&&On!=="html"&&Gr.enterRCDATA(V_("</template"),0);else{let r=0;At.exp=j0(On,!1,Xr(bo,ku),0,r),At.name==="for"&&(At.forParseResult=qU(At.exp));let i=-1;At.name==="bind"&&(i=At.modifiers.findIndex(n=>n.content==="sync"))>-1&&Jp("COMPILER_V_BIND_SYNC",Xt,At.loc,At.arg.loc.source)&&(At.name="model",At.modifiers.splice(i,1))}(At.type!==7||At.name!=="pre")&&tn.props.push(At)}On="",bo=ku=-1},oncomment(e,t){Xt.comments&&D2({type:3,content:Di(e,t),loc:Xr(e-4,t+3)})},onend(){const e=Go.length;for(let t=0;t<Pr.length;t++)B0(Pr[t],e-1),yo(24,Pr[t].loc.start.offset)},oncdata(e,t){Pr[0].ns!==0?Ng(Di(e,t),e,t):yo(1,e-9)},onprocessinginstruction(e){(Pr[0]?Pr[0].ns:Xt.ns)===0&&yo(21,e-1)}}),N5=/,([^,\}\]]*)(?:,([^,\}\]]*))?$/,VU=/^\(|\)$/g;function qU(e){const t=e.loc,r=e.content,i=r.match(UU);if(!i)return;const[,n,a]=i,s=(d,h,f=!1)=>{const p=t.start.offset+h,m=p+d.length;return j0(d,!1,Xr(p,m),0,f?1:0)},o={source:s(a.trim(),r.indexOf(a,n.length)),value:void 0,key:void 0,index:void 0,finalized:!1};let l=n.trim().replace(VU,"").trim();const u=n.indexOf(l),c=l.match(N5);if(c){l=l.replace(N5,"").trim();const d=c[1].trim();let h;if(d&&(h=r.indexOf(d,u+l.length),o.key=s(d,h,!0)),c[2]){const f=c[2].trim();f&&(o.index=s(f,r.indexOf(f,o.key?h+d.length:u+l.length),!0))}}return l&&(o.value=s(l,u,!0)),o}function Di(e,t){return Go.slice(e,t)}function B5(e){Gr.inSFCRoot&&(tn.innerLoc=Xr(e+1,e+1)),D2(tn);const{tag:t,ns:r}=tn;r===0&&Xt.isPreTag(t)&&a4++,Xt.isVoidTag(t)?B0(tn,e):(Pr.unshift(tn),(r===1||r===2)&&(Gr.inXML=!0)),tn=null}function Ng(e,t,r){{const a=Pr[0]&&Pr[0].tag;a!=="script"&&a!=="style"&&e.includes("&")&&(e=Xt.decodeEntities(e,!1))}const i=Pr[0]||em,n=i.children[i.children.length-1];n&&n.type===2?(n.content+=e,Fu(n.loc,r)):i.children.push({type:2,content:e,loc:Xr(t,r)})}function B0(e,t,r=!1){r?Fu(e.loc,OI(t,60)):Fu(e.loc,GU(t,62)+1),Gr.inSFCRoot&&(e.children.length?e.innerLoc.end=Ct({},e.children[e.children.length-1].loc.end):e.innerLoc.end=Ct({},e.innerLoc.start),e.innerLoc.source=Di(e.innerLoc.start.offset,e.innerLoc.end.offset));const{tag:i,ns:n,children:a}=e;if(Dl||(i==="slot"?e.tagType=2:j5(e)?e.tagType=3:YU(e)&&(e.tagType=1)),Gr.inRCDATA||(e.children=LI(a)),n===0&&Xt.isIgnoreNewlineTag(i)){const s=a[0];s&&s.type===2&&(s.content=s.content.replace(/^\r?\n/,""))}n===0&&Xt.isPreTag(i)&&a4--,A2===e&&(Dl=Gr.inVPre=!1,A2=null),Gr.inXML&&(Pr[0]?Pr[0].ns:Xt.ns)===0&&(Gr.inXML=!1);{const s=e.props;if(!Gr.inSFCRoot&&Ju("COMPILER_NATIVE_TEMPLATE",Xt)&&e.tag==="template"&&!j5(e)){const l=Pr[0]||em,u=l.children.indexOf(e);l.children.splice(u,1,...e.children)}const o=s.find(l=>l.type===6&&l.name==="inline-template");o&&Jp("COMPILER_INLINE_TEMPLATE",Xt,o.loc)&&e.children.length&&(o.value={type:2,content:Di(e.children[0].loc.start.offset,e.children[e.children.length-1].loc.end.offset),loc:o.loc})}}function GU(e,t){let r=e;for(;Go.charCodeAt(r)!==t&&r<Go.length-1;)r++;return r}function OI(e,t){let r=e;for(;Go.charCodeAt(r)!==t&&r>=0;)r--;return r}const HU=new Set(["if","else","else-if","for","slot"]);function j5({tag:e,props:t}){if(e==="template"){for(let r=0;r<t.length;r++)if(t[r].type===7&&HU.has(t[r].name))return!0}return!1}function YU({tag:e,props:t}){if(Xt.isCustomElement(e))return!1;if(e==="component"||WU(e.charCodeAt(0))||kI(e)||Xt.isBuiltInComponent&&Xt.isBuiltInComponent(e)||Xt.isNativeTag&&!Xt.isNativeTag(e))return!0;for(let r=0;r<t.length;r++){const i=t[r];if(i.type===6){if(i.name==="is"&&i.value){if(i.value.content.startsWith("vue:"))return!0;if(Jp("COMPILER_IS_ON_ELEMENT",Xt,i.loc))return!0}}else if(i.name==="bind"&&Lu(i.arg,"is")&&Jp("COMPILER_IS_ON_ELEMENT",Xt,i.loc))return!0}return!1}function WU(e){return e>64&&e<91}const ZU=/\r\n/g;function LI(e){const t=Xt.whitespace!=="preserve";let r=!1;for(let i=0;i<e.length;i++){const n=e[i];if(n.type===2)if(a4)n.content=n.content.replace(ZU,` 24`);else if(AI(n.content)){const a=e[i-1]&&e[i-1].type,s=e[i+1]&&e[i+1].type;!a||!s||t&&(a===3&&(s===3||s===1)||a===1&&(s===3||s===1&&KU(n.content)))?(r=!0,e[i]=null):n.content=" "}else t&&(n.content=FI(n.content))}return r?e.filter(Boolean):e}function KU(e){for(let t=0;t<e.length;t++){const r=e.charCodeAt(t);if(r===10||r===13)return!0}return!1}function FI(e){let t="",r=!1;for(let i=0;i<e.length;i++)sa(e.charCodeAt(i))?r||(t+=" ",r=!0):(t+=e[i],r=!1);return t}function D2(e){(Pr[0]||em).children.push(e)}function Xr(e,t){return{start:Gr.getPos(e),end:t==null?t:Gr.getPos(t),source:t==null?t:Di(e,t)}}function XU(e){return Xr(e.start.offset,e.end.offset)}function Fu(e,t){e.end=Gr.getPos(t),e.source=Di(e.start.offset,t)}function JU(e){const t={type:6,name:e.rawName,nameLoc:Xr(e.loc.start.offset,e.loc.start.offset+e.rawName.length),value:void 0,loc:e.loc};if(e.exp){const r=e.exp.loc;r.end.offset<e.loc.end.offset&&(r.start.offset--,r.start.column--,r.end.offset++,r.end.column++),t.value={type:2,content:e.exp.content,loc:r}}return t}function j0(e,t=!1,r,i=0,n=0){return bt(e,t,r,i)}function yo(e,t,r){Xt.onError(wr(e,Xr(t,t)))}function QU(){Gr.reset(),tn=null,At=null,On="",bo=-1,ku=-1,Pr.length=0}function eV(e,t){if(QU(),Go=e,Xt=Ct({},RI),t){let n;for(n in t)t[n]!=null&&(Xt[n]=t[n])}Gr.mode=Xt.parseMode==="html"?1:Xt.parseMode==="sfc"?2:0,Gr.inXML=Xt.ns===1||Xt.ns===2;const r=t&&t.delimiters;r&&(Gr.delimiterOpen=V_(r[0]),Gr.delimiterClose=V_(r[1]));const i=em=kU([],e);return Gr.parse(Go),i.loc=Xr(0,e.length),i.children=LI(i.children),em=null,i}function tV(e,t){U0(e,void 0,t,!!zI(e))}function zI(e){const t=e.children.filter(r=>r.type!==3);return t.length===1&&t[0].type===1&&!G_(t[0])?t[0]:null}function U0(e,t,r,i=!1,n=!1){const{children:a}=e,s=[];for(let c=0;c<a.length;c++){const d=a[c];if(d.type===1&&d.tagType===0){const h=i?0:ma(d,r);if(h>0){if(h>=2){d.codegenNode.patchFlag=-1,s.push(d);continue}}else{const f=d.codegenNode;if(f.type===13){const p=f.patchFlag;if((p===void 0||p===512||p===1)&&BI(d,r)>=2){const m=jI(d);m&&(f.props=r.hoist(m))}f.dynamicProps&&(f.dynamicProps=r.hoist(f.dynamicProps))}}}else if(d.type===12&&(i?0:ma(d,r))>=2){d.codegenNode.type===14&&d.codegenNode.arguments.length>0&&d.codegenNode.arguments.push("-1"),s.push(d);continue}if(d.type===1){const h=d.tagType===1;h&&r.scopes.vSlot++,U0(d,e,r,!1,n),h&&r.scopes.vSlot--}else if(d.type===11)U0(d,e,r,d.children.length===1,!0);else if(d.type===9)for(let h=0;h<d.branches.length;h++)U0(d.branches[h],e,r,d.branches[h].children.length===1,n)}let o=!1;if(s.length===a.length&&e.type===1){if(e.tagType===0&&e.codegenNode&&e.codegenNode.type===13&&Le(e.codegenNode.children))e.codegenNode.children=l(Xu(e.codegenNode.children)),o=!0;else if(e.tagType===1&&e.codegenNode&&e.codegenNode.type===13&&e.codegenNode.children&&!Le(e.codegenNode.children)&&e.codegenNode.children.type===15){const c=u(e.codegenNode,"default");c&&(c.returns=l(Xu(c.returns)),o=!0)}else if(e.tagType===3&&t&&t.type===1&&t.tagType===1&&t.codegenNode&&t.codegenNode.type===13&&t.codegenNode.children&&!Le(t.codegenNode.children)&&t.codegenNode.children.type===15){const c=Ba(e,"slot",!0),d=c&&c.arg&&u(t.codegenNode,c.arg);d&&(d.returns=l(Xu(d.returns)),o=!0)}}if(!o)for(const c of s)c.codegenNode=r.cache(c.codegenNode);function l(c){const d=r.cache(c);return d.needArraySpread=!0,d}function u(c,d){if(c.children&&!Le(c.children)&&c.children.type===15){const h=c.children.properties.find(f=>f.key===d||f.key.content===d);return h&&h.value}}s.length&&r.transformHoist&&r.transformHoist(a,r,e)}function ma(e,t){const{constantCache:r}=t;switch(e.type){case 1:if(e.tagType!==0)return 0;const i=r.get(e);if(i!==void 0)return i;const n=e.codegenNode;if(n.type!==13||n.isBlock&&e.tag!=="svg"&&e.tag!=="foreignObject"&&e.tag!=="math")return 0;if(n.patchFlag===void 0){let s=3;const o=BI(e,t);if(o===0)return r.set(e,0),0;o<s&&(s=o);for(let l=0;l<e.children.length;l++){const u=ma(e.children[l],t);if(u===0)return r.set(e,0),0;u<s&&(s=u)}if(s>1)for(let l=0;l<e.props.length;l++){const u=e.props[l];if(u.type===7&&u.name==="bind"&&u.exp){const c=ma(u.exp,t);if(c===0)return r.set(e,0),0;c<s&&(s=c)}}if(n.isBlock){for(let l=0;l<e.props.length;l++)if(e.props[l].type===7)return r.set(e,0),0;t.removeHelper(yc),t.removeHelper(ch(t.inSSR,n.isComponent)),n.isBlock=!1,t.helper(uh(t.inSSR,n.isComponent))}return r.set(e,s),s}else return r.set(e,0),0;case 2:case 3:return 3;case 9:case 11:case 10:return 0;case 5:case 12:return ma(e.content,t);case 4:return e.constType;case 8:let a=3;for(let s=0;s<e.children.length;s++){const o=e.children[s];if(ft(o)||ea(o))continue;const l=ma(o,t);if(l===0)return 0;l<a&&(a=l)}return a;case 20:return 2;default:return 0}}const rV=new Set([K3,X3,Kp,Zm]);function NI(e,t){if(e.type===14&&!ft(e.callee)&&rV.has(e.callee)){const r=e.arguments[0];if(r.type===4)return ma(r,t);if(r.type===14)return NI(r,t)}return 0}function BI(e,t){let r=3;const i=jI(e);if(i&&i.type===15){const{properties:n}=i;for(let a=0;a<n.length;a++){const{key:s,value:o}=n[a],l=ma(s,t);if(l===0)return l;l<r&&(r=l);let u;if(o.type===4?u=ma(o,t):o.type===14?u=NI(o,t):u=0,u===0)return u;u<r&&(r=u)}}return r}function jI(e){const t=e.codegenNode;if(t.type===13)return t.props}function iV(e,{filename:t="",prefixIdentifiers:r=!1,hoistStatic:i=!1,hmr:n=!1,cacheHandlers:a=!1,nodeTransforms:s=[],directiveTransforms:o={},transformHoist:l=null,isBuiltInComponent:u=qi,isCustomElement:c=qi,expressionPlugins:d=[],scopeId:h=null,slotted:f=!0,ssr:p=!1,inSSR:m=!1,ssrCssVars:g="",bindingMetadata:v=Dt,inline:x=!1,isTS:_=!1,onError:y=r4,onWarn:w=CI,compatConfig:$}){const S=t.replace(/\?.*$/,"").match(/([^/\\]+)\.\w+$/),E={filename:t,selfName:S&&Ic(ar(S[1])),prefixIdentifiers:r,hoistStatic:i,hmr:n,cacheHandlers:a,nodeTransforms:s,directiveTransforms:o,transformHoist:l,isBuiltInComponent:u,isCustomElement:c,expressionPlugins:d,scopeId:h,slotted:f,ssr:p,inSSR:m,ssrCssVars:g,bindingMetadata:v,inline:x,isTS:_,onError:y,onWarn:w,compatConfig:$,root:e,helpers:new Map,components:new Set,directives:new Set,hoists:[],imports:[],cached:[],constantCache:new WeakMap,temps:0,identifiers:Object.create(null),scopes:{vFor:0,vSlot:0,vPre:0,vOnce:0},parent:null,grandParent:null,currentNode:e,childIndex:0,inVOnce:!1,helper(C){const I=E.helpers.get(C)||0;return E.helpers.set(C,I+1),C},removeHelper(C){const I=E.helpers.get(C);if(I){const P=I-1;P?E.helpers.set(C,P):E.helpers.delete(C)}},helperString(C){return`_${oh[E.helper(C)]}`},replaceNode(C){E.parent.children[E.childIndex]=E.currentNode=C},removeNode(C){const I=E.parent.children,P=C?I.indexOf(C):E.currentNode?E.childIndex:-1;!C||C===E.currentNode?(E.currentNode=null,E.onNodeRemoved()):E.childIndex>P&&(E.childIndex--,E.onNodeRemoved()),E.parent.children.splice(P,1)},onNodeRemoved:qi,addIdentifiers(C){},removeIdentifiers(C){},hoist(C){ft(C)&&(C=bt(C)),E.hoists.push(C);const I=bt(`_hoisted_${E.hoists.length}`,!1,C.loc,2);return I.hoisted=C,I},cache(C,I=!1,P=!1){const T=EU(E.cached.length,C,I,P);return E.cached.push(T),T}};return E.filters=new Set,E}function nV(e,t){const r=iV(e,t);y1(e,r),t.hoistStatic&&tV(e,r),t.ssr||aV(e,r),e.helpers=new Set([...r.helpers.keys()]),e.components=[...r.components],e.directives=[...r.directives],e.imports=r.imports,e.hoists=r.hoists,e.temps=r.temps,e.cached=r.cached,e.transformed=!0,e.filters=[...r.filters]}function aV(e,t){const{helper:r}=t,{children:i}=e;if(i.length===1){const n=zI(e);if(n&&n.codegenNode){const a=n.codegenNode;a.type===13&&t4(a,t),e.codegenNode=a}else e.codegenNode=i[0]}else if(i.length>1){let n=64;e.codegenNode=Xp(t,r(Zp),void 0,e.children,n,void 0,void 0,!0,void 0,!1)}}function sV(e,t){let r=0;const i=()=>{r--};for(;r<e.children.length;r++){const n=e.children[r];ft(n)||(t.grandParent=t.parent,t.parent=e,t.childIndex=r,t.onNodeRemoved=i,y1(n,t))}}function y1(e,t){t.currentNode=e;const{nodeTransforms:r}=t,i=[];for(let a=0;a<r.length;a++){const s=r[a](e,t);if(s&&(Le(s)?i.push(...s):i.push(s)),t.currentNode)e=t.currentNode;else return}switch(e.type){case 3:t.ssr||t.helper(Wm);break;case 5:t.ssr||t.helper(g1);break;case 9:for(let a=0;a<e.branches.length;a++)y1(e.branches[a],t);break;case 10:case 11:case 1:case 0:sV(e,t);break}t.currentNode=e;let n=i.length;for(;n--;)i[n]()}function UI(e,t){const r=ft(e)?i=>i===e:i=>e.test(i);return(i,n)=>{if(i.type===1){const{props:a}=i;if(i.tagType===3&&a.some(NU))return;const s=[];for(let o=0;o<a.length;o++){const l=a[o];if(l.type===7&&r(l.name)){a.splice(o,1),o--;const u=t(i,l,n);u&&s.push(u)}}return s}}}const v1="/*@__PURE__*/",VI=e=>`${oh[e]}: _${oh[e]}`;function oV(e,{mode:t="function",prefixIdentifiers:r=t==="module",sourceMap:i=!1,filename:n="template.vue.html",scopeId:a=null,optimizeImports:s=!1,runtimeGlobalName:o="Vue",runtimeModuleName:l="vue",ssrRuntimeModuleName:u="vue/server-renderer",ssr:c=!1,isTS:d=!1,inSSR:h=!1}){const f={mode:t,prefixIdentifiers:r,sourceMap:i,filename:n,scopeId:a,optimizeImports:s,runtimeGlobalName:o,runtimeModuleName:l,ssrRuntimeModuleName:u,ssr:c,isTS:d,inSSR:h,source:e.source,code:"",column:1,line:1,offset:0,indentLevel:0,pure:!1,map:void 0,helper(m){return`_${oh[m]}`},push(m,g=-2,v){f.code+=m},indent(){p(++f.indentLevel)},deindent(m=!1){m?--f.indentLevel:p(--f.indentLevel)},newline(){p(f.indentLevel)}};function p(m){f.push(` 25`+" ".repeat(m),0)}return f}function lV(e,t={}){const r=oV(e,t);t.onContextCreated&&t.onContextCreated(r);const{mode:i,push:n,prefixIdentifiers:a,indent:s,deindent:o,newline:l,scopeId:u,ssr:c}=r,d=Array.from(e.helpers),h=d.length>0,f=!a&&i!=="module";uV(e,r);const m=c?"ssrRender":"render",v=(c?["_ctx","_push","_parent","_attrs"]:["_ctx","_cache"]).join(", ");if(n(`function ${m}(${v}) {`),s(),f&&(n("with (_ctx) {"),s(),h&&(n(`const { ${d.map(VI).join(", ")} } = _Vue 26`,-1),l())),e.components.length&&(Lv(e.components,"component",r),(e.directives.length||e.temps>0)&&l()),e.directives.length&&(Lv(e.directives,"directive",r),e.temps>0&&l()),e.filters&&e.filters.length&&(l(),Lv(e.filters,"filter",r),l()),e.temps>0){n("let ");for(let x=0;x<e.temps;x++)n(`${x>0?", ":""}_temp${x}`)}return(e.components.length||e.directives.length||e.temps)&&(n(` 27`,0),l()),c||n("return "),e.codegenNode?dn(e.codegenNode,r):n("null"),f&&(o(),n("}")),o(),n("}"),{ast:e,code:r.code,preamble:"",map:r.map?r.map.toJSON():void 0}}function uV(e,t){const{ssr:r,prefixIdentifiers:i,push:n,newline:a,runtimeModuleName:s,runtimeGlobalName:o,ssrRuntimeModuleName:l}=t,u=o,c=Array.from(e.helpers);if(c.length>0&&(n(`const _Vue = ${u} 28`,-1),e.hoists.length)){const d=[j3,U3,Wm,V3,wI].filter(h=>c.includes(h)).map(VI).join(", ");n(`const { ${d} } = _Vue 29`,-1)}cV(e.hoists,t),a(),n("return ")}function Lv(e,t,{helper:r,push:i,newline:n,isTS:a}){const s=r(t==="filter"?Y3:t==="component"?q3:H3);for(let o=0;o<e.length;o++){let l=e[o];const u=l.endsWith("__self");u&&(l=l.slice(0,-6)),i(`const ${Qp(l,t)} = ${s}(${JSON.stringify(l)}${u?", true":""})${a?"!":""}`),o<e.length-1&&n()}}function cV(e,t){if(!e.length)return;t.pure=!0;const{push:r,newline:i}=t;i();for(let n=0;n<e.length;n++){const a=e[n];a&&(r(`const _hoisted_${n+1} = `),dn(a,t),i())}t.pure=!1}function s4(e,t){const r=e.length>3||!1;t.push("["),r&&t.indent(),Km(e,t,r),r&&t.deindent(),t.push("]")}function Km(e,t,r=!1,i=!0){const{push:n,newline:a}=t;for(let s=0;s<e.length;s++){const o=e[s];ft(o)?n(o,-3):Le(o)?s4(o,t):dn(o,t),s<e.length-1&&(r?(i&&n(","),a()):i&&n(", "))}}function dn(e,t){if(ft(e)){t.push(e,-3);return}if(ea(e)){t.push(t.helper(e));return}switch(e.type){case 1:case 9:case 11:dn(e.codegenNode,t);break;case 2:dV(e,t);break;case 4:qI(e,t);break;case 5:hV(e,t);break;case 12:dn(e.codegenNode,t);break;case 8:GI(e,t);break;case 3:pV(e,t);break;case 13:mV(e,t);break;case 14:_V(e,t);break;case 15:yV(e,t);break;case 17:vV(e,t);break;case 18:bV(e,t);break;case 19:xV(e,t);break;case 20:wV(e,t);break;case 21:Km(e.body,t,!0,!1);break}}function dV(e,t){t.push(JSON.stringify(e.content),-3,e)}function qI(e,t){const{content:r,isStatic:i}=e;t.push(i?JSON.stringify(r):r,-3,e)}function hV(e,t){const{push:r,helper:i,pure:n}=t;n&&r(v1),r(`${i(g1)}(`),dn(e.content,t),r(")")}function GI(e,t){for(let r=0;r<e.children.length;r++){const i=e.children[r];ft(i)?t.push(i,-3):dn(i,t)}}function fV(e,t){const{push:r}=t;if(e.type===8)r("["),GI(e,t),r("]");else if(e.isStatic){const i=i4(e.content)?e.content:JSON.stringify(e.content);r(i,-2,e)}else r(`[${e.content}]`,-3,e)}function pV(e,t){const{push:r,helper:i,pure:n}=t;n&&r(v1),r(`${i(Wm)}(${JSON.stringify(e.content)})`,-3,e)}function mV(e,t){const{push:r,helper:i,pure:n}=t,{tag:a,props:s,children:o,patchFlag:l,dynamicProps:u,directives:c,isBlock:d,disableTracking:h,isComponent:f}=e;let p;l&&(p=String(l)),c&&r(i(W3)+"("),d&&r(`(${i(yc)}(${h?"true":""}), `),n&&r(v1);const m=d?ch(t.inSSR,f):uh(t.inSSR,f);r(i(m)+"(",-2,e),Km(gV([a,s,o,p,u]),t),r(")"),d&&r(")"),c&&(r(", "),dn(c,t),r(")"))}function gV(e){let t=e.length;for(;t--&&e[t]==null;);return e.slice(0,t+1).map(r=>r||"null")}function _V(e,t){const{push:r,helper:i,pure:n}=t,a=ft(e.callee)?e.callee:i(e.callee);n&&r(v1),r(a+"(",-2,e),Km(e.arguments,t),r(")")}function yV(e,t){const{push:r,indent:i,deindent:n,newline:a}=t,{properties:s}=e;if(!s.length){r("{}",-2,e);return}const o=s.length>1||!1;r(o?"{":"{ "),o&&i();for(let l=0;l<s.length;l++){const{key:u,value:c}=s[l];fV(u,t),r(": "),dn(c,t),l<s.length-1&&(r(","),a())}o&&n(),r(o?"}":" }")}function vV(e,t){s4(e.elements,t)}function bV(e,t){const{push:r,indent:i,deindent:n}=t,{params:a,returns:s,body:o,newline:l,isSlot:u}=e;u&&r(`_${oh[Q3]}(`),r("(",-2,e),Le(a)?Km(a,t):a&&dn(a,t),r(") => "),(l||o)&&(r("{"),i()),s?(l&&r("return "),Le(s)?s4(s,t):dn(s,t)):o&&dn(o,t),(l||o)&&(n(),r("}")),u&&(e.isNonScopedSlot&&r(", undefined, true"),r(")"))}function xV(e,t){const{test:r,consequent:i,alternate:n,newline:a}=e,{push:s,indent:o,deindent:l,newline:u}=t;if(r.type===4){const d=!i4(r.content);d&&s("("),qI(r,t),d&&s(")")}else s("("),dn(r,t),s(")");a&&o(),t.indentLevel++,a||s(" "),s("? "),dn(i,t),t.indentLevel--,a&&u(),a||s(" "),s(": ");const c=n.type===19;c||t.indentLevel++,dn(n,t),c||t.indentLevel--,a&&l(!0)}function wV(e,t){const{push:r,helper:i,indent:n,deindent:a,newline:s}=t,{needPauseTracking:o,needArraySpread:l}=e;l&&r("[...("),r(`_cache[${e.index}] || (`),o&&(n(),r(`${i(U_)}(-1`),e.inVOnce&&r(", true"),r("),"),s(),r("(")),r(`_cache[${e.index}] = `),dn(e.value,t),o&&(r(`).cacheIndex = ${e.index},`),s(),r(`${i(U_)}(1),`),s(),r(`_cache[${e.index}]`),a()),r(")"),l&&r(")]")}new RegExp("\\b"+"arguments,await,break,case,catch,class,const,continue,debugger,default,delete,do,else,export,extends,finally,for,function,if,import,let,new,return,super,switch,throw,try,var,void,while,with,yield".split(",").join("\\b|\\b")+"\\b");const $V=UI(/^(?:if|else|else-if)$/,(e,t,r)=>SV(e,t,r,(i,n,a)=>{const s=r.parent.children;let o=s.indexOf(i),l=0;for(;o-->=0;){const u=s[o];u&&u.type===9&&(l+=u.branches.length)}return()=>{if(a)i.codegenNode=V5(n,l,r);else{const u=TV(i.codegenNode);u.alternate=V5(n,l+i.branches.length-1,r)}}}));function SV(e,t,r,i){if(t.name!=="else"&&(!t.exp||!t.exp.content.trim())){const n=t.exp?t.exp.loc:e.loc;r.onError(wr(28,t.loc)),t.exp=bt("true",!1,n)}if(t.name==="if"){const n=U5(e,t),a={type:9,loc:XU(e.loc),branches:[n]};if(r.replaceNode(a),i)return i(a,n,!0)}else{const n=r.parent.children;let a=n.indexOf(e);for(;a-->=-1;){const s=n[a];if(s&&DI(s)){r.removeNode(s);continue}if(s&&s.type===9){(t.name==="else-if"||t.name==="else")&&s.branches[s.branches.length-1].condition===void 0&&r.onError(wr(30,e.loc)),r.removeNode();const o=U5(e,t);s.branches.push(o);const l=i&&i(s,o,!1);y1(o,r),l&&l(),r.currentNode=null}else r.onError(wr(30,e.loc));break}}}function U5(e,t){const r=e.tagType===3;return{type:10,loc:e.loc,condition:t.name==="else"?void 0:t.exp,children:r&&!Ba(e,"for")?e.children:[e],userKey:_1(e,"key"),isTemplateIf:r}}function V5(e,t,r){return e.condition?I2(e.condition,q5(e,t,r),yi(r.helper(Wm),['""',"true"])):q5(e,t,r)}function q5(e,t,r){const{helper:i}=r,n=hi("key",bt(`${t}`,!1,Pa,2)),{children:a}=e,s=a[0];if(a.length!==1||s.type!==1)if(a.length===1&&s.type===11){const l=s.codegenNode;return H_(l,n,r),l}else return Xp(r,i(Zp),Ya([n]),a,64,void 0,void 0,!0,!1,!1,e.loc);else{const l=s.codegenNode,u=jU(l);return u.type===13&&t4(u,r),H_(u,n,r),l}}function TV(e){for(;;)if(e.type===19)if(e.alternate.type===19)e=e.alternate;else return e;else e.type===20&&(e=e.value)}const CV=UI("for",(e,t,r)=>{const{helper:i,removeHelper:n}=r;return kV(e,t,r,a=>{const s=yi(i(Z3),[a.source]),o=q_(e),l=Ba(e,"memo"),u=_1(e,"key",!1,!0);u&&u.type;let c=u&&(u.type===6?u.value?bt(u.value.content,!0):void 0:u.exp);const d=u&&c?hi("key",c):null,h=a.source.type===4&&a.source.constType>0,f=h?64:u?128:256;return a.codegenNode=Xp(r,i(Zp),void 0,s,f,void 0,void 0,!0,!h,!1,e.loc),()=>{let p;const{children:m}=a,g=m.length!==1||m[0].type!==1,v=G_(e)?e:o&&e.children.length===1&&G_(e.children[0])?e.children[0]:null;if(v?(p=v.codegenNode,o&&d&&H_(p,d,r)):g?p=Xp(r,i(Zp),d?Ya([d]):void 0,e.children,64,void 0,void 0,!0,void 0,!1):(p=m[0].codegenNode,o&&d&&H_(p,d,r),p.isBlock!==!h&&(p.isBlock?(n(yc),n(ch(r.inSSR,p.isComponent))):n(uh(r.inSSR,p.isComponent))),p.isBlock=!h,p.isBlock?(i(yc),i(ch(r.inSSR,p.isComponent))):i(uh(r.inSSR,p.isComponent))),l){const x=lh(R2(a.parseResult,[bt("_cached")]));x.body=PU([$s(["const _memo = (",l.exp,")"]),$s(["if (_cached",...c?[" && _cached.key === ",c]:[],` && ${r.helperString(TI)}(_cached, _memo)) return _cached`]),$s(["const _item = ",p]),bt("_item.memo = _memo"),bt("return _item")]),s.arguments.push(x,bt("_cache"),bt(String(r.cached.length))),r.cached.push(null)}else s.arguments.push(lh(R2(a.parseResult),p,!0))}})});function kV(e,t,r,i){if(!t.exp){r.onError(wr(31,t.loc));return}const n=t.forParseResult;if(!n){r.onError(wr(32,t.loc));return}HI(n);const{addIdentifiers:a,removeIdentifiers:s,scopes:o}=r,{source:l,value:u,key:c,index:d}=n,h={type:11,loc:t.loc,source:l,valueAlias:u,keyAlias:c,objectIndexAlias:d,parseResult:n,children:q_(e)?e.children:[e]};r.replaceNode(h),o.vFor++;const f=i&&i(h);return()=>{o.vFor--,f&&f()}}function HI(e,t){e.finalized||(e.finalized=!0)}function R2({value:e,key:t,index:r},i=[]){return EV([e,t,r,...i])}function EV(e){let t=e.length;for(;t--&&!e[t];);return e.slice(0,t+1).map((r,i)=>r||bt("_".repeat(i+1),!1))}const G5=bt("undefined",!1),PV=(e,t)=>{if(e.type===1&&(e.tagType===1||e.tagType===3)){const r=Ba(e,"slot");if(r)return r.exp,t.scopes.vSlot++,()=>{t.scopes.vSlot--}}},MV=(e,t,r,i)=>lh(e,r,!1,!0,r.length?r[0].loc:i);function IV(e,t,r=MV){t.helper(Q3);const{children:i,loc:n}=e,a=[],s=[];let o=t.scopes.vSlot>0||t.scopes.vFor>0;const l=Ba(e,"slot",!0);if(l){const{arg:g,exp:v}=l;g&&!Vn(g)&&(o=!0),a.push(hi(g||bt("default",!0),r(v,void 0,i,n)))}let u=!1,c=!1;const d=[],h=new Set;let f=0;for(let g=0;g<i.length;g++){const v=i[g];let x;if(!q_(v)||!(x=Ba(v,"slot",!0))){v.type!==3&&d.push(v);continue}if(l){t.onError(wr(37,x.loc));break}u=!0;const{children:_,loc:y}=v,{arg:w=bt("default",!0),exp:$,loc:S}=x;let E;Vn(w)?E=w?w.content:"default":o=!0;const C=Ba(v,"for"),I=r($,C,_,y);let P,T;if(P=Ba(v,"if"))o=!0,s.push(I2(P.exp,Bg(w,I,f++),G5));else if(T=Ba(v,/^else(?:-if)?$/,!0)){let D=g,A;for(;D--&&(A=i[D],!!DI(A)););if(A&&q_(A)&&Ba(A,/^(?:else-)?if$/)){let z=s[s.length-1];for(;z.alternate.type===19;)z=z.alternate;z.alternate=T.exp?I2(T.exp,Bg(w,I,f++),G5):Bg(w,I,f++)}else t.onError(wr(30,T.loc))}else if(C){o=!0;const D=C.forParseResult;D?(HI(D),s.push(yi(t.helper(Z3),[D.source,lh(R2(D),Bg(w,I),!0)]))):t.onError(wr(32,C.loc))}else{if(E){if(h.has(E)){t.onError(wr(38,S));continue}h.add(E),E==="default"&&(c=!0)}a.push(hi(w,I))}}if(!l){const g=(v,x)=>{const _=r(v,void 0,x,n);return t.compatConfig&&(_.isNonScopedSlot=!0),hi("default",_)};u?d.length&&!d.every(n4)&&(c?t.onError(wr(39,d[0].loc)):a.push(g(void 0,d))):a.push(g(void 0,i))}const p=o?2:V0(e.children)?3:1;let m=Ya(a.concat(hi("_",bt(p+"",!1))),n);return s.length&&(m=yi(t.helper(SI),[m,Xu(s)])),{slots:m,hasDynamicSlots:o}}function Bg(e,t,r){const i=[hi("name",e),hi("fn",t)];return r!=null&&i.push(hi("key",bt(String(r),!0))),Ya(i)}function V0(e){for(let t=0;t<e.length;t++){const r=e[t];switch(r.type){case 1:if(r.tagType===2||V0(r.children))return!0;break;case 9:if(V0(r.branches))return!0;break;case 10:case 11:if(V0(r.children))return!0;break}}return!1}const YI=new WeakMap,AV=(e,t)=>function(){if(e=t.currentNode,!(e.type===1&&(e.tagType===0||e.tagType===1)))return;const{tag:i,props:n}=e,a=e.tagType===1;let s=a?DV(e,t):`"${i}"`;const o=Ht(s)&&s.callee===G3;let l,u,c=0,d,h,f,p=o||s===lp||s===B3||!a&&(i==="svg"||i==="foreignObject"||i==="math");if(n.length>0){const m=WI(e,t,void 0,a,o);l=m.props,c=m.patchFlag,h=m.dynamicPropNames;const g=m.directives;f=g&&g.length?Xu(g.map(v=>OV(v,t))):void 0,m.shouldUseBlock&&(p=!0)}if(e.children.length>0)if(s===B_&&(p=!0,c|=1024),a&&s!==lp&&s!==B_){const{slots:g,hasDynamicSlots:v}=IV(e,t);u=g,v&&(c|=1024)}else if(e.children.length===1&&s!==lp){const g=e.children[0],v=g.type,x=v===5||v===8;x&&ma(g,t)===0&&(c|=1),x||v===2?u=g:u=e.children}else u=e.children;h&&h.length&&(d=LV(h)),e.codegenNode=Xp(t,s,l,u,c===0?void 0:c,d,f,!!p,!1,a,e.loc)};function DV(e,t,r=!1){let{tag:i}=e;const n=O2(i),a=_1(e,"is",!1,!0);if(a)if(n||Ju("COMPILER_IS_ON_ELEMENT",t)){let o;if(a.type===6?o=a.value&&bt(a.value.content,!0):(o=a.exp,o||(o=bt("is",!1,a.arg.loc))),o)return yi(t.helper(G3),[o])}else a.type===6&&a.value.content.startsWith("vue:")&&(i=a.value.content.slice(4));const s=kI(i)||t.isBuiltInComponent(i);return s?(r||t.helper(s),s):(t.helper(q3),t.components.add(i),Qp(i,"component"))}function WI(e,t,r=e.props,i,n,a=!1){const{tag:s,loc:o,children:l}=e;let u=[];const c=[],d=[],h=l.length>0;let f=!1,p=0,m=!1,g=!1,v=!1,x=!1,_=!1,y=!1;const w=[],$=I=>{u.length&&(c.push(Ya(H5(u),o)),u=[]),I&&c.push(I)},S=()=>{t.scopes.vFor>0&&u.push(hi(bt("ref_for",!0),bt("true")))},E=({key:I,value:P})=>{if(Vn(I)){const T=I.content,D=Pc(T);if(D&&(!i||n)&&T.toLowerCase()!=="onclick"&&T!=="onUpdate:modelValue"&&!Vo(T)&&(x=!0),D&&Vo(T)&&(y=!0),D&&P.type===14&&(P=P.arguments[0]),P.type===20||(P.type===4||P.type===8)&&ma(P,t)>0)return;T==="ref"?m=!0:T==="class"?g=!0:T==="style"?v=!0:T!=="key"&&!w.includes(T)&&w.push(T),i&&(T==="class"||T==="style")&&!w.includes(T)&&w.push(T)}else _=!0};for(let I=0;I<r.length;I++){const P=r[I];if(P.type===6){const{loc:T,name:D,nameLoc:A,value:z}=P;let R=!0;if(D==="ref"&&(m=!0,S()),D==="is"&&(O2(s)||z&&z.content.startsWith("vue:")||Ju("COMPILER_IS_ON_ELEMENT",t)))continue;u.push(hi(bt(D,!0,A),bt(z?z.content:"",R,z?z.loc:T)))}else{const{name:T,arg:D,exp:A,loc:z,modifiers:R}=P,O=T==="bind",V=T==="on";if(T==="slot"){i||t.onError(wr(40,z));continue}if(T==="once"||T==="memo"||T==="is"||O&&Lu(D,"is")&&(O2(s)||Ju("COMPILER_IS_ON_ELEMENT",t))||V&&a)continue;if((O&&Lu(D,"key")||V&&h&&Lu(D,"vue:before-update"))&&(f=!0),O&&Lu(D,"ref")&&S(),!D&&(O||V)){if(_=!0,A)if(O){if($(),Ju("COMPILER_V_BIND_OBJECT_ORDER",t)){c.unshift(A);continue}S(),$(),c.push(A)}else $({type:14,loc:z,callee:t.helper(J3),arguments:i?[A]:[A,"true"]});else t.onError(wr(O?34:35,z));continue}O&&R.some(F=>F.content==="prop")&&(p|=32);const Y=t.directiveTransforms[T];if(Y){const{props:F,needRuntime:ae}=Y(P,e,t);!a&&F.forEach(E),V&&D&&!Vn(D)?$(Ya(F,o)):u.push(...F),ae&&(d.push(P),ea(ae)&&YI.set(P,ae))}else Jz(T)||(d.push(P),h&&(f=!0))}}let C;if(c.length?($(),c.length>1?C=yi(t.helper(j_),c,o):C=c[0]):u.length&&(C=Ya(H5(u),o)),_?p|=16:(g&&!i&&(p|=2),v&&!i&&(p|=4),w.length&&(p|=8),x&&(p|=32)),!f&&(p===0||p===32)&&(m||y||d.length>0)&&(p|=512),!t.inSSR&&C)switch(C.type){case 15:let I=-1,P=-1,T=!1;for(let z=0;z<C.properties.length;z++){const R=C.properties[z].key;Vn(R)?R.content==="class"?I=z:R.content==="style"&&(P=z):R.isHandlerKey||(T=!0)}const D=C.properties[I],A=C.properties[P];T?C=yi(t.helper(Kp),[C]):(D&&!Vn(D.value)&&(D.value=yi(t.helper(K3),[D.value])),A&&(v||A.value.type===4&&A.value.content.trim()[0]==="["||A.value.type===17)&&(A.value=yi(t.helper(X3),[A.value])));break;case 14:break;default:C=yi(t.helper(Kp),[yi(t.helper(Zm),[C])]);break}return{props:C,directives:d,patchFlag:p,dynamicPropNames:w,shouldUseBlock:f}}function H5(e){const t=new Map,r=[];for(let i=0;i<e.length;i++){const n=e[i];if(n.key.type===8||!n.key.isStatic){r.push(n);continue}const a=n.key.content,s=t.get(a);s?(a==="style"||a==="class"||Pc(a))&&RV(s,n):(t.set(a,n),r.push(n))}return r}function RV(e,t){e.value.type===17?e.value.elements.push(t.value):e.value=Xu([e.value,t.value],e.loc)}function OV(e,t){const r=[],i=YI.get(e);i?r.push(t.helperString(i)):(t.helper(H3),t.directives.add(e.name),r.push(Qp(e.name,"directive")));const{loc:n}=e;if(e.exp&&r.push(e.exp),e.arg&&(e.exp||r.push("void 0"),r.push(e.arg)),Object.keys(e.modifiers).length){e.arg||(e.exp||r.push("void 0"),r.push("void 0"));const a=bt("true",!1,n);r.push(Ya(e.modifiers.map(s=>hi(s,a)),n))}return Xu(r,e.loc)}function LV(e){let t="[";for(let r=0,i=e.length;r<i;r++)t+=JSON.stringify(e[r]),r<i-1&&(t+=", ");return t+"]"}function O2(e){return e==="component"||e==="Component"}const FV=(e,t)=>{if(G_(e)){const{children:r,loc:i}=e,{slotName:n,slotProps:a}=zV(e,t),s=[t.prefixIdentifiers?"_ctx.$slots":"$slots",n,"{}","undefined","true"];let o=2;a&&(s[2]=a,o=3),r.length&&(s[3]=lh([],r,!1,!1,i),o=4),t.scopeId&&!t.slotted&&(o=5),s.splice(o),e.codegenNode=yi(t.helper($I),s,i)}};function zV(e,t){let r='"default"',i;const n=[];for(let a=0;a<e.props.length;a++){const s=e.props[a];if(s.type===6)s.value&&(s.name==="name"?r=JSON.stringify(s.value.content):(s.name=ar(s.name),n.push(s)));else if(s.name==="bind"&&Lu(s.arg,"name")){if(s.exp)r=s.exp;else if(s.arg&&s.arg.type===4){const o=ar(s.arg.content);r=s.exp=bt(o,!1,s.arg.loc)}}else s.name==="bind"&&s.arg&&Vn(s.arg)&&(s.arg.content=ar(s.arg.content)),n.push(s)}if(n.length>0){const{props:a,directives:s}=WI(e,t,n,!1,!1);i=a,s.length&&t.onError(wr(36,s[0].loc))}return{slotName:r,slotProps:i}}const ZI=(e,t,r,i)=>{const{loc:n,modifiers:a,arg:s}=e;!e.exp&&!a.length&&r.onError(wr(35,n));let o;if(s.type===4)if(s.isStatic){let d=s.content;d.startsWith("vue:")&&(d=`vnode-${d.slice(4)}`);const h=t.tagType!==0||d.startsWith("vnode")||!/[A-Z]/.test(d)?Id(ar(d)):`on:${d}`;o=bt(h,!0,s.loc)}else o=$s([`${r.helperString(M2)}(`,s,")"]);else o=s,o.children.unshift(`${r.helperString(M2)}(`),o.children.push(")");let l=e.exp;l&&!l.content.trim()&&(l=void 0);let u=r.cacheHandlers&&!l&&!r.inVOnce;if(l){const d=MI(l),h=!(d||FU(l)),f=l.content.includes(";");(h||u&&d)&&(l=$s([`${h?"$event":"(...args)"} => ${f?"{":"("}`,l,f?"}":")"]))}let c={props:[hi(o,l||bt("() => {}",!1,n))]};return i&&(c=i(c)),u&&(c.props[0].value=r.cache(c.props[0].value)),c.props.forEach(d=>d.key.isHandlerKey=!0),c},NV=(e,t,r)=>{const{modifiers:i,loc:n}=e,a=e.arg;let{exp:s}=e;return s&&s.type===4&&!s.content.trim()&&(s=void 0),a.type!==4?(a.children.unshift("("),a.children.push(') || ""')):a.isStatic||(a.content=a.content?`${a.content} || ""`:'""'),i.some(o=>o.content==="camel")&&(a.type===4?a.isStatic?a.content=ar(a.content):a.content=`${r.helperString(P2)}(${a.content})`:(a.children.unshift(`${r.helperString(P2)}(`),a.children.push(")"))),r.inSSR||(i.some(o=>o.content==="prop")&&Y5(a,"."),i.some(o=>o.content==="attr")&&Y5(a,"^")),{props:[hi(a,s)]}},Y5=(e,t)=>{e.type===4?e.isStatic?e.content=t+e.content:e.content=`\`${t}\${${e.content}}\``:(e.children.unshift(`'${t}' + (`),e.children.push(")"))},BV=(e,t)=>{if(e.type===0||e.type===1||e.type===11||e.type===10)return()=>{const r=e.children;let i,n=!1;for(let a=0;a<r.length;a++){const s=r[a];if(Ov(s)){n=!0;for(let o=a+1;o<r.length;o++){const l=r[o];if(Ov(l))i||(i=r[a]=$s([s],s.loc)),i.children.push(" + ",l),r.splice(o,1),o--;else{i=void 0;break}}}}if(!(!n||r.length===1&&(e.type===0||e.type===1&&e.tagType===0&&!e.props.find(a=>a.type===7&&!t.directiveTransforms[a.name])&&e.tag!=="template")))for(let a=0;a<r.length;a++){const s=r[a];if(Ov(s)||s.type===8){const o=[];(s.type!==2||s.content!==" ")&&o.push(s),!t.ssr&&ma(s,t)===0&&o.push("1"),r[a]={type:12,content:s,loc:s.loc,codegenNode:yi(t.helper(V3),o)}}}}},W5=new WeakSet,jV=(e,t)=>{if(e.type===1&&Ba(e,"once",!0))return W5.has(e)||t.inVOnce||t.inSSR?void 0:(W5.add(e),t.inVOnce=!0,t.helper(U_),()=>{t.inVOnce=!1;const r=t.currentNode;r.codegenNode&&(r.codegenNode=t.cache(r.codegenNode,!0,!0))})},KI=(e,t,r)=>{const{exp:i,arg:n}=e;if(!i)return r.onError(wr(41,e.loc)),hf();const a=i.loc.source.trim(),s=i.type===4?i.content:a,o=r.bindingMetadata[a];if(o==="props"||o==="props-aliased")return r.onError(wr(44,i.loc)),hf();if(o==="literal-const"||o==="setup-const")return r.onError(wr(45,i.loc)),hf();if(!s.trim()||!MI(i))return r.onError(wr(42,i.loc)),hf();const l=n||bt("modelValue",!0),u=n?Vn(n)?`onUpdate:${ar(n.content)}`:$s(['"onUpdate:" + ',n]):"onUpdate:modelValue";let c;const d=r.isTS?"($event: any)":"$event";c=$s([`${d} => ((`,i,") = $event)"]);const h=[hi(l,e.exp),hi(u,c)];if(e.modifiers.length&&t.tagType===1){const f=e.modifiers.map(m=>m.content).map(m=>(i4(m)?m:JSON.stringify(m))+": true").join(", "),p=n?Vn(n)?`${n.content}Modifiers`:$s([n,' + "Modifiers"']):"modelModifiers";h.push(hi(p,bt(`{ ${f} }`,!1,e.loc,2)))}return hf(h)};function hf(e=[]){return{props:e}}const UV=/[\w).+\-_$\]]/,VV=(e,t)=>{Ju("COMPILER_FILTERS",t)&&(e.type===5?Y_(e.content,t):e.type===1&&e.props.forEach(r=>{r.type===7&&r.name!=="for"&&r.exp&&Y_(r.exp,t)}))};function Y_(e,t){if(e.type===4)Z5(e,t);else for(let r=0;r<e.children.length;r++){const i=e.children[r];typeof i=="object"&&(i.type===4?Z5(i,t):i.type===8?Y_(e,t):i.type===5&&Y_(i.content,t))}}function Z5(e,t){const r=e.content;let i=!1,n=!1,a=!1,s=!1,o=0,l=0,u=0,c=0,d,h,f,p,m=[];for(f=0;f<r.length;f++)if(h=d,d=r.charCodeAt(f),i)d===39&&h!==92&&(i=!1);else if(n)d===34&&h!==92&&(n=!1);else if(a)d===96&&h!==92&&(a=!1);else if(s)d===47&&h!==92&&(s=!1);else if(d===124&&r.charCodeAt(f+1)!==124&&r.charCodeAt(f-1)!==124&&!o&&!l&&!u)p===void 0?(c=f+1,p=r.slice(0,f).trim()):g();else{switch(d){case 34:n=!0;break;case 39:i=!0;break;case 96:a=!0;break;case 40:u++;break;case 41:u--;break;case 91:l++;break;case 93:l--;break;case 123:o++;break;case 125:o--;break}if(d===47){let v=f-1,x;for(;v>=0&&(x=r.charAt(v),x===" ");v--);(!x||!UV.test(x))&&(s=!0)}}p===void 0?p=r.slice(0,f).trim():c!==0&&g();function g(){m.push(r.slice(c,f).trim()),c=f+1}if(m.length){for(f=0;f<m.length;f++)p=qV(p,m[f],t);e.content=p,e.ast=void 0}}function qV(e,t,r){r.helper(Y3);const i=t.indexOf("(");if(i<0)return r.filters.add(t),`${Qp(t,"filter")}(${e})`;{const n=t.slice(0,i),a=t.slice(i+1);return r.filters.add(n),`${Qp(n,"filter")}(${e}${a!==")"?","+a:a}`}}const K5=new WeakSet,GV=(e,t)=>{if(e.type===1){const r=Ba(e,"memo");return!r||K5.has(e)||t.inSSR?void 0:(K5.add(e),()=>{const i=e.codegenNode||t.currentNode.codegenNode;i&&i.type===13&&(e.tagType!==1&&t4(i,t),e.codegenNode=yi(t.helper(e4),[r.exp,lh(void 0,i),"_cache",String(t.cached.length)]),t.cached.push(null))})}},HV=(e,t)=>{if(e.type===1){for(const r of e.props)if(r.type===7&&r.name==="bind"&&(!r.exp||r.exp.type===4&&!r.exp.content.trim())&&r.arg){const i=r.arg;if(i.type!==4||!i.isStatic)t.onError(wr(53,i.loc)),r.exp=bt("",!0,i.loc);else{const n=ar(i.content);(EI.test(n[0])||n[0]==="-")&&(r.exp=bt(n,!1,i.loc))}}}};function YV(e){return[[HV,jV,$V,GV,CV,VV,FV,AV,PV,BV],{on:ZI,bind:NV,model:KI}]}function WV(e,t={}){const r=t.onError||r4,i=t.mode==="module";t.prefixIdentifiers===!0?r(wr(48)):i&&r(wr(49));const n=!1;t.cacheHandlers&&r(wr(50)),t.scopeId&&!i&&r(wr(51));const a=Ct({},t,{prefixIdentifiers:n}),s=ft(e)?eV(e,a):e,[o,l]=YV();return nV(s,Ct({},a,{nodeTransforms:[...o,...t.nodeTransforms||[]],directiveTransforms:Ct({},l,t.directiveTransforms||{})})),lV(s,a)}const ZV=()=>({props:[]});/** 30* @vue/compiler-dom v3.5.30 31* (c) 2018-present Yuxi (Evan) You and Vue contributors 32* @license MIT
33**/const XI=Symbol(""),JI=Symbol(""),QI=Symbol(""),eA=Symbol(""),L2=Symbol(""),tA=Symbol(""),rA=Symbol(""),iA=Symbol(""),nA=Symbol(""),aA=Symbol("");CU({[XI]:"vModelRadio",[JI]:"vModelCheckbox",[QI]:"vModelText",[eA]:"vModelSelect",[L2]:"vModelDynamic",[tA]:"withModifiers",[rA]:"withKeys",[iA]:"vShow",[nA]:"Transition",[aA]:"TransitionGroup"});let Gc;function KV(e,t=!1){return Gc||(Gc=document.createElement("div")),t?(Gc.innerHTML=`<div foo="${e.replace(/"/g,""")}">`,Gc.children[0].getAttribute("foo")):(Gc.innerHTML=e,Gc.textContent)}const XV={parseMode:"html",isVoidTag:pN,isNativeTag:e=>dN(e)||hN(e)||fN(e),isPreTag:e=>e==="pre",isIgnoreNewlineTag:e=>e==="pre"||e==="textarea",decodeEntities:KV,isBuiltInComponent:e=>{if(e==="Transition"||e==="transition")return nA;if(e==="TransitionGroup"||e==="transition-group")return aA},getNamespace(e,t,r){let i=t?t.ns:r;if(t&&i===2)if(t.tag==="annotation-xml"){if(e==="svg")return 1;t.props.some(n=>n.type===6&&n.name==="encoding"&&n.value!=null&&(n.value.content==="text/html"||n.value.content==="application/xhtml+xml"))&&(i=0)}else/^m(?:[ions]|text)$/.test(t.tag)&&e!=="mglyph"&&e!=="malignmark"&&(i=0);else t&&i===1&&(t.tag==="foreignObject"||t.tag==="desc"||t.tag==="title")&&(i=0);if(i===0){if(e==="svg")return 1;if(e==="math")return 2}return i}},JV=e=>{e.type===1&&e.props.forEach((t,r)=>{t.type===6&&t.name==="style"&&t.value&&(e.props[r]={type:7,name:"bind",arg:bt("style",!0,t.loc),exp:QV(t.value.content,t.loc),modifiers:[],loc:t.loc})})},QV=(e,t)=>{const r=gP(e);return bt(JSON.stringify(r),!1,t,3)};function Wl(e,t){return wr(e,t)}const eq=(e,t,r)=>{const{exp:i,loc:n}=e;return i||r.onError(Wl(54,n)),t.children.length&&(r.onError(Wl(55,n)),t.children.length=0),{props:[hi(bt("innerHTML",!0,n),i||bt("",!0))]}},tq=(e,t,r)=>{const{exp:i,loc:n}=e;return i||r.onError(Wl(56,n)),t.children.length&&(r.onError(Wl(57,n)),t.children.length=0),{props:[hi(bt("textContent",!0),i?ma(i,r)>0?i:yi(r.helperString(g1),[i],n):bt("",!0))]}},rq=(e,t,r)=>{const i=KI(e,t,r);if(!i.props.length||t.tagType===1)return i;e.arg&&r.onError(Wl(59,e.arg.loc));const{tag:n}=t,a=r.isCustomElement(n);if(n==="input"||n==="textarea"||n==="select"||a){let s=QI,o=!1;if(n==="input"||a){const l=_1(t,"type");if(l){if(l.type===7)s=L2;else if(l.value)switch(l.value.content){case"radio":s=XI;break;case"checkbox":s=JI;break;case"file":o=!0,r.onError(Wl(60,e.loc));break}}else zU(t)&&(s=L2)}else n==="select"&&(s=eA);o||(i.needRuntime=r.helper(s))}else r.onError(Wl(58,e.loc));return i.props=i.props.filter(s=>!(s.key.type===4&&s.key.content==="modelValue")),i},iq=Ea("passive,once,capture"),nq=Ea("stop,prevent,self,ctrl,shift,alt,meta,exact,middle"),aq=Ea("left,right"),sA=Ea("onkeyup,onkeydown,onkeypress"),sq=(e,t,r,i)=>{const n=[],a=[],s=[];for(let o=0;o<t.length;o++){const l=t[o].content;l==="native"&&Jp("COMPILER_V_ON_NATIVE",r)||iq(l)?s.push(l):aq(l)?Vn(e)?sA(e.content.toLowerCase())?n.push(l):a.push(l):(n.push(l),a.push(l)):nq(l)?a.push(l):n.push(l)}return{keyModifiers:n,nonKeyModifiers:a,eventOptionModifiers:s}},X5=(e,t)=>Vn(e)&&e.content.toLowerCase()==="onclick"?bt(t,!0):e.type!==4?$s(["(",e,`) === "onClick" ? "${t}" : (`,e,")"]):e,oq=(e,t,r)=>ZI(e,t,r,i=>{const{modifiers:n}=e;if(!n.length)return i;let{key:a,value:s}=i.props[0];const{keyModifiers:o,nonKeyModifiers:l,eventOptionModifiers:u}=sq(a,n,r,e.loc);if(l.includes("right")&&(a=X5(a,"onContextmenu")),l.includes("middle")&&(a=X5(a,"onMouseup")),l.length&&(s=yi(r.helper(tA),[s,JSON.stringify(l)])),o.length&&(!Vn(a)||sA(a.content.toLowerCase()))&&(s=yi(r.helper(rA),[s,JSON.stringify(o)])),u.length){const c=u.map(Ic).join("");a=Vn(a)?bt(`${a.content}${c}`,!0):$s(["(",a,`) + "${c}"`])}return{props:[hi(a,s)]}}),lq=(e,t,r)=>{const{exp:i,loc:n}=e;
vendor: 4,951 bytes, lines 33-41
33return i||r.onError(Wl(62,n)),{props:[],needRuntime:r.helper(iA)}},uq=(e,t)=>{e.type===1&&e.tagType===0&&(e.tag==="script"||e.tag==="style")&&t.removeNode()},cq=[JV],dq={cloak:ZV,html:eq,text:tq,model:rq,on:oq,show:lq};function hq(e,t={}){return WV(e,Ct({},XV,t,{nodeTransforms:[uq,...cq,...t.nodeTransforms||[]],directiveTransforms:Ct({},dq,t.directiveTransforms||{}),transformHoist:null}))}/** 34* vue v3.5.30 35* (c) 2018-present Yuxi (Evan) You and Vue contributors 36* @license MIT 37**/const J5=Object.create(null);function fq(e,t){if(!ft(e))if(e.nodeType)e=e.innerHTML;else return qi;const r=tN(e,t),i=J5[r];if(i)return i;if(e[0]==="#"){const o=document.querySelector(e);e=o?o.innerHTML:""}const n=Ct({hoistStatic:!0,onError:void 0,onWarn:qi},t);!n.isCustomElement&&typeof customElements<"u"&&(n.isCustomElement=o=>!!customElements.get(o));const{code:a}=hq(e,n),s=new Function("Vue",a)(bU);return s._rc=!0,J5[r]=s}qM(fq);/*! 38 * pinia v3.0.4 39 * (c) 2025 Eduardo San Martin Morote 40 * @license MIT 41 */let oA;const b1=e=>oA=e,lA=Symbol();function F2(e){return e&&typeof e=="object"&&Object.prototype.toString.call(e)==="[object Object]"&&typeof e.toJSON!="function"}var up;(function(e){e.direct="direct",e.patchObject="patch object",e.patchFunction="patch function"})(up||(up={}));function pq(){const e=b3(!0),t=e.run(()=>se({}));let r=[],i=[];const n=mc({install(a){b1(n),n._a=a,a.provide(lA,n),a.config.globalProperties.$pinia=n,i.forEach(s=>r.push(s)),i=[]},use(a){return this._a?r.push(a):i.push(a),this},_p:r,_a:null,_e:e,_s:new Map,state:t});return n}const uA=()=>{};function Q5(e,t,r,i=uA){e.add(t);const n=()=>{e.delete(t)&&i()};return!r&&x3()&&bP(n),n}function Hc(e,...t){e.forEach(r=>{r(...t)})}const mq=e=>e(),eT=Symbol(),Fv=Symbol();function z2(e,t){e instanceof Map&&t instanceof Map?t.forEach((r,i)=>e.set(i,r)):e instanceof Set&&t instanceof Set&&t.forEach(e.add,e);for(const r in t){if(!t.hasOwnProperty(r))continue;const i=t[r],n=e[r];F2(n)&&F2(i)&&e.hasOwnProperty(r)&&!er(i)&&!xs(i)?e[r]=z2(n,i):e[r]=i}return e}const gq=Symbol();function _q(e){return!F2(e)||!Object.prototype.hasOwnProperty.call(e,gq)}const{assign:kl}=Object;function yq(e){return!!(er(e)&&e.effect)}function vq(e,t,r,i){const{state:n,actions:a,getters:s}=t,o=r.state.value[e];let l;function u(){o||(r.state.value[e]=n?n():{});const c=s1(r.state.value[e]);return kl(c,a,Object.keys(s||{}).reduce((d,h)=>(d[h]=mc(H(()=>{b1(r);const f=r._s.get(e);return s[h].call(f,f)})),d),{}))}return l=cA(e,u,t,r,i,!0),l}function cA(e,t,r={},i,n,a){let s;const o=kl({actions:{}},r),l={deep:!0};let u,c,d=new Set,h=new Set,f;const p=i.state.value[e];!a&&!p&&(i.state.value[e]={});let m;function g(E){let C;u=c=!1,typeof E=="function"?(E(i.state.value[e]),C={type:up.patchFunction,storeId:e,events:f}):(z2(i.state.value[e],E),C={type:up.patchObject,payload:E,storeId:e,events:f});const I=m=Symbol();Bi().then(()=>{m===I&&(u=!0)}),c=!0,Hc(d,C,i.state.value[e])}const v=a?function(){const{state:C}=r,I=C?C():{};this.$patch(P=>{kl(P,I)})}:uA;function x(){s.stop(),d.clear(),h.clear(),i._s.delete(e)}const _=(E,C="")=>{if(eT in E)return E[Fv]=C,E;const I=function(){b1(i);const P=Array.from(arguments),T=new Set,D=new Set;function A(O){T.add(O)}function z(O){D.add(O)}Hc(h,{args:P,name:I[Fv],store:w,after:A,onError:z});let R;try{R=E.apply(this&&this.$id===e?this:w,P)}catch(O){throw Hc(D,O),O}return R instanceof Promise?R.then(O=>(Hc(T,O),O)).catch(O=>(Hc(D,O),Promise.reject(O))):(Hc(T,R),R)};return I[eT]=!0,I[Fv]=C,I},y={_p:i,$id:e,$onAction:Q5.bind(null,h),$patch:g,$reset:v,$subscribe(E,C={}){const I=Q5(d,E,C.detached,()=>P()),P=s.run(()=>tt(()=>i.state.value[e],T=>{(C.flush==="sync"?c:u)&&E({storeId:e,type:up.direct,events:f},T)},kl({},l,C)));return I},$dispose:x},w=An(y);i._s.set(e,w);const S=(i._a&&i._a.runWithContext||mq)(()=>i._e.run(()=>(s=b3()).run(()=>t({action:_}))));for(const E in S){const C=S[E];if(er(C)&&!yq(C)||xs(C))a||(p&&_q(C)&&(er(C)?C.value=p[E]:z2(C,p[E])),i.state.value[e][E]=C);else if(typeof C=="function"){const I=_(C,E);S[E]=I,o.actions[E]=C}}return kl(w,S),kl(Ft(w),S),Object.defineProperty(w,"$state",{get:()=>i.state.value[e],set:E=>{g(C=>{kl(C,E)})}}),i._p.forEach(E=>{kl(w,s.run(()=>E({store:w,app:i._a,pinia:i,options:o})))}),p&&a&&r.hydrate&&r.hydrate(w.$state,p),u=!0,c=!0,w}/*! #__NO_SIDE_EFFECTS__ */function dA(e,t,r){let i;const n=typeof t=="function";i=n?r:t;function a(s,o){const l=GP();return s=s||(l?Gi(lA,null):null),s&&b1(s),s=oA,s._s.has(e)||(n?cA(e,t,i,s):vq(e,i,s)),s._s.get(e)}return a.$id=e,a}const zd=typeof __SENTRY_DEBUG__>"u"||__SENTRY_DEBUG__,tl=globalThis,cp="10.47.0";function o4(){return l4(tl),tl}function l4(e){const t=e.__SENTRY__=e.__SENTRY__||{};return t.version=t.version||cp,t[cp]=t[cp]||{}}function u4(e,t,r=tl){const i=r.__SENTRY__=r.__SENTRY__||{},n=i[cp]=i[cp]||{};return n[e]||(n[e]=t())}const bq="Sentry Logger ",tT={};function hA(e){if(!("console"in tl))return e();const t=tl.console,r={},i=Object.keys(tT);
41i.forEach(n=>{const a=tT[n];r[n]=t[n],t[n]=a});try{return e()}finally{i.forEach(n=>{t[n]=r[n]})}}function xq(){d4().enabled=!0}function wq(){d4().enabled=!1}function fA(){return d4().enabled}function $q(...e){c4("log",...e)}function Sq(...e){c4("warn",...e)}function Tq(...e){c4("error",...e)}function c4(e,...t){zd&&fA()&&hA(()=>{tl.console[e](`${bq}[${e}]:`,...t)})}function d4(){return zd?u4("loggerSettings",()=>({enabled:!1})):{enabled:!1}}const q0={enable:xq,disable:wq,isEnabled:fA,log:$q,warn:Sq,error:Tq},Cq=Object.prototype.toString;function kq(e,t){return Cq.call(e)===`[object ${t}]`}function Eq(e){return kq(e,"Object")}function Pq(e){return!!(e!=null&&e.then&&typeof e.then=="function")}function Mq(e,t,r){try{Object.defineProperty(e,t,{value:r,writable:!0,configurable:!0})}catch{zd&&q0.log(`Failed to add non-enumerable property "${t}" to object`,e)}}let Yc;function x1(e){if(Yc!==void 0)return Yc?Yc(e):e();const t=Symbol.for("__SENTRY_SAFE_RANDOM_ID_WRAPPER__"),r=tl;return t in r&&typeof r[t]=="function"?(Yc=r[t],Yc(e)):(Yc=null,e())}function N2(){return x1(()=>Math.random())}function Iq(){return x1(()=>Date.now())}function Aq(e,t=0){return typeof e!="string"||t===0||e.length<=t?e:`${e.slice(0,t)}...`}function Dq(){const e=tl;return e.crypto||e.msCrypto}let zv;function Rq(){return N2()*16}
41function dp(e=Dq()){try{if(e!=null&&e.randomUUID)return x1(()=>e.randomUUID()).replace(/-/g,"")}catch{}return zv||(zv="10000000100040008000"+1e11),zv.replace(/[018]/g,t=>(t^(Rq()&15)>>t/4).toString(16))}const pA=1e3;function h4(){return Iq()/pA}function Oq(){const{performance:e}=tl;if(!(e!=null&&e.now)||!e.timeOrigin)return h4;const t=e.timeOrigin;return()=>(t+x1(()=>e.now()))/pA}let rT;function Lq(){return(rT??(rT=Oq()))()}function Fq(e,t={}){if(t.user&&(!e.ipAddress&&t.user.ip_address&&(e.ipAddress=t.user.ip_address),!e.did&&!t.did&&(e.did=t.user.id||t.user.email||t.user.username)),e.timestamp=t.timestamp||Lq(),t.abnormal_mechanism&&(e.abnormal_mechanism=t.abnormal_mechanism),t.ignoreDuration&&(e.ignoreDuration=t.ignoreDuration),t.sid&&(e.sid=t.sid.length===32?t.sid:dp()),t.init!==void 0&&(e.init=t.init),!e.did&&t.did&&(e.did=`${t.did}`),typeof t.started=="number"&&(e.started=t.started),e.ignoreDuration)e.duration=void 0;else if(typeof t.duration=="number")e.duration=t.duration;else{const r=e.timestamp-e.started;e.duration=r>=0?r:0}t.release&&(e.release=t.release),t.environment&&(e.environment=t.environment),!e.ipAddress&&t.ipAddress&&(e.ipAddress=t.ipAddress),!e.userAgent&&t.userAgent&&(e.userAgent=t.userAgent),typeof t.errors=="number"&&(e.errors=t.errors),t.status&&(e.status=t.status)}function mA(e,t,r=2){if(!t||typeof t!="object"||r<=0)return t;if(e&&Object.keys(t).length===0)return e;const i={...e};for(const n in t)Object.prototype.hasOwnProperty.call(t,n)&&(i[n]=mA(i[n],t[n],r-1));return i}function iT(){return dp()}const B2="_sentrySpan";function nT(e,t){t?Mq(e,B2,t):delete e[B2]}function aT(e){return e[B2]}const zq=100;class ru{constructor(){this._notifyingListeners=!1,this._scopeListeners=[],this._eventProcessors=[],this._breadcrumbs=[],this._attachments=[],this._user={},this._tags={},this._attributes={},this._extra={},this._contexts={},this._sdkProcessingMetadata={},this._propagationContext={traceId:iT(),sampleRand:N2()}}clone(){const t=new ru;return t._breadcrumbs=[...this._breadcrumbs],t._tags={...this._tags},t._attributes={...this._attributes},t._extra={...this._extra},t._contexts={...this._contexts},this._contexts.flags&&(t._contexts.flags={values:[...this._contexts.flags.values]}),t._user=this._user,t._level=this._level,t._session=this._session,t._transactionName=this._transactionName,t._fingerprint=this._fingerprint,t._eventProcessors=[...this._eventProcessors],t._attachments=[...this._attachments],t._sdkProcessingMetadata={...this._sdkProcessingMetadata},t._propagationContext={...this._propagationContext},t._client=this._client,t._lastEventId=this._lastEventId,t._conversationId=this._conversationId,nT(t,aT(this)),t}setClient(t){this._client=t}setLastEventId(t){this._lastEventId=t}getClient(){return this._client}lastEventId(){return this._lastEventId}addScopeListener(t){this._scopeListeners.push(t)}addEventProcessor(t){return this._eventProcessors.push(t),this}setUser(t){return this._user=t||{email:void 0,id:void 0,ip_address:void 0,username:void 0},this._session&&Fq(this._session,{user:t}),this._notifyScopeListeners(),this}getUser(){return this._user}setConversationId(t){return this._conversationId=t||void 0,this._notifyScopeListeners(),this}setTags(t){return this._tags={...this._tags,...t},this._notifyScopeListeners(),this}setTag(t,r){return this.setTags({[t]:r})}setAttributes(t){return this._attributes={...this._attributes,...t},this._notifyScopeListeners(),this}setAttribute(t,r){return this.setAttributes({[t]:r})}removeAttribute(t){return t in this._attributes&&(delete this._attributes[t],this._notifyScopeListeners()),this}setExtras(t){return this._extra={...this._extra,...t},this._notifyScopeListeners(),this}setExtra(t,r){return this._extra={...this._extra,[t]:r},this._notifyScopeListeners(),this}setFingerprint(t){return this._fingerprint=t,this._notifyScopeListeners(),this}setLevel(t){return this._level=t,this._notifyScopeListeners(),this}setTransactionName(t){return this._transactionName=t,this._notifyScopeListeners(),this}setContext(t,r){return r===null?delete this._contexts[t]:this._contexts[t]=r,this._notifyScopeListeners(),this}setSession(t){return t?this._session=t:delete this._session,this._notifyScopeListeners(),this}getSession(){return this._session}update(t){if(!t)return this;const r=typeof t=="function"?t(this):t,i=r instanceof ru?r.getScopeData():Eq(r)?t:void 0,{tags:n,attributes:a,extra:s,user:o,contexts:l,level:u,fingerprint:c=[],propagationContext:d,conversationId:h}=i||{};return this._tags={...this._tags,...n},this._attributes={...this._attributes,...a},this._extra={...this._extra,...s},this._contexts={...this._contexts,...l},o&&Object.keys(o).length&&(this._user=o),u&&(this._level=u),c.length&&(this._fingerprint=c),d&&(this._propagationContext=d),h&&(this._conversationId=h),this}clear(){return this._breadcrumbs=[],this._tags={},this._attributes={},this._extra={},this._user={},this._contexts={},this._level=void 0,this._transactionName=void 0,this._fingerprint=void 0,this._session=void 0,this._conversationId=void 0,nT(this,void 0),this._attachments=[],this.setPropagationContext({traceId:iT(),sampleRand:N2(
41)}),this._notifyScopeListeners(),this}addBreadcrumb(t,r){var a;const i=typeof r=="number"?r:zq;if(i<=0)return this;const n={timestamp:h4(),...t,message:t.message?Aq(t.message,2048):t.message};return this._breadcrumbs.push(n),this._breadcrumbs.length>i&&(this._breadcrumbs=this._breadcrumbs.slice(-i),(a=this._client)==null||a.recordDroppedEvent("buffer_overflow","log_item")),this._notifyScopeListeners(),this}getLastBreadcrumb(){return this._breadcrumbs[this._breadcrumbs.length-1]}clearBreadcrumbs(){return this._breadcrumbs=[],this._notifyScopeListeners(),this}addAttachment(t){return this._attachments.push(t),this}clearAttachments(){return this._attachments=[],this}getScopeData(){return{breadcrumbs:this._breadcrumbs,attachments:this._attachments,contexts:this._contexts,tags:this._tags,attributes:this._attributes,extra:this._extra,user:this._user,level:this._level,fingerprint:this._fingerprint||[],eventProcessors:this._eventProcessors,propagationContext:this._propagationContext,sdkProcessingMetadata:this._sdkProcessingMetadata,transactionName:this._transactionName,span:aT(this),conversationId:this._conversationId}}setSDKProcessingMetadata(t){return this._sdkProcessingMetadata=mA(this._sdkProcessingMetadata,t,2),this}setPropagationContext(t){return this._propagationContext=t,this}getPropagationContext(){return this._propagationContext}captureException(t,r){const i=(r==null?void 0:r.event_id)||dp();if(!this._client)return zd&&q0.warn("No client configured on scope - will not capture exception!"),i;const n=new Error("Sentry syntheticException");return this._client.captureException(t,{originalException:t,syntheticException:n,...r,event_id:i},this),i}captureMessage(t,r,i){const n=(i==null?void 0:i.event_id)||dp();if(!this._client)return zd&&q0.warn("No client configured on scope - will not capture message!"),n;const a=(i==null?void 0:i.syntheticException)??new Error(t);return this._client.captureMessage(t,r,{originalException:t,syntheticException:a,...i,event_id:n},this),n}captureEvent(t,r){const i=t.event_id||(r==null?void 0:r.event_id)||dp();return this._client?(this._client.captureEvent(t,{...r,event_id:i},this),i):(zd&&q0.warn("No client configured on scope - will not capture event!"),i)}_notifyScopeListeners(){this._notifyingListeners||(this._notifyingListeners=!0,this._scopeListeners.forEach(t=>{t(this)}),this._notifyingListeners=!1)}}function Nq(){return u4("defaultCurrentScope",()=>new ru)}function Bq(){return u4("defaultIsolationScope",()=>new ru)}const sT=e=>e instanceof Promise&&!e[gA],gA=Symbol("chained PromiseLike"),jq=(e,t,r)=>{const i=e.then(n=>(t(n),n),n=>{throw r(n),n});return sT(i)&&sT(e)?i:Uq(e,i)},Uq=(e,t)=>{let r=!1;for(const i in e){if(i in t)continue;r=!0;const n=e[i];typeof n=="function"?Object.defineProperty(t,i,{value:(...a)=>n.apply(e,a),enumerable:!0,configurable:!0,writable:!0}):t[i]=n}return r&&Object.assign(t,{[gA]:!0}),t};class Vq{constructor(t,r){let i;t?i=t:i=new ru;let n;r?n=r:n=new ru,this._stack=[{scope:i}],this._isolationScope=n}withScope(t){const r=this._pushScope();let i;try{i=t(r)}catch(n){throw this._popScope(),n}return Pq(i)?jq(i,()=>this._popScope(),()=>this._popScope()):(this._popScope(),i)}getClient(){return this.getStackTop().client}getScope(){return this.getStackTop().scope}getIsolationScope(){return this._isolationScope}getStackTop(){return this._stack[this._stack.length-1]}_pushScope(){const t=this.getScope().clone();return this._stack.push({client:this.getClient(),scope:t}),t}_popScope(){return this._stack.length<=1?!1:!!this._stack.pop()}}function dh(){const e=o4(),t=l4(e);return t.stack=t.stack||new Vq(Nq(),Bq())}function qq(e){return dh().withScope(e)}function Gq(e,t){const r=dh();return r.withScope(()=>(r.getStackTop().scope=e,t(e)))}function oT(e){return dh().withScope(()=>e(dh().getIsolationScope()))}function Hq(){return{withIsolationScope:oT,withScope:qq,withSetScope:Gq,withSetIsolationScope:(e,t)=>oT(t),getCurrentScope:()=>dh().getScope(),getIsolationScope:()=>dh().getIsolationScope()}}function _A(e){const t=l4(e);return t.acs?t.acs:Hq()}function yA(){const e=o4();return _A(e).getCurrentScope()}function Yq(){const e=o4();return _A(e).getIsolationScope()}function Wq(){return yA().getClient()}function Zq(e){if(e)return Kq(e)?{captureContext:e}:Jq(e)?{captureContext:e}:e}function Kq(e){return e instanceof ru||typeof e=="function"}const Xq=["user","level","extra","contexts","tags","fingerprint","propagationContext"];function Jq(e){return Object.keys(e).some(t=>Xq.includes(t))}function vA(e,t){return yA().captureException(e,Zq(t))}const Qq=100;function lT(e,t){const r=Wq(),i=Yq();if(!r)return;const{beforeBreadcrumb:n=null,maxBreadcrumbs:a=Qq}=r.getOptions();if(a<=0)return;const o={timestamp:h4(),...e},l=n?hA(()=>n(o,t)):o;l!==null&&(r.emit&&r.emit("beforeAddBreadcrumb",l,t),i.addBreadcrumb(l,a))}var Hn="top",ns="bottom",as="right",Yn="left",f4="auto",Xm=[Hn,ns,as,Yn],hh="start",tm="end",eG="clippingParents",bA="viewport",ff="popper",tG="reference",uT=Xm.reduce(function(e,t){return e.concat([t+"-"+hh,t+"-"+tm])},[]),xA=[].concat(Xm,[f4]).reduce(function(e,t){return e.concat([t,t+"-"+hh,t+"-"+tm])},[]),rG="beforeRead",iG="read",nG="afterRead",aG="beforeMain",sG="main",oG="afterMain",lG="beforeWrite",uG="write",cG="afterWrite",dG=[rG,iG,nG,aG,sG,oG,lG,uG,cG];function oo(e){return e?(e.nodeName||"").toLowerCase():null}function $a(e){if(e==null)return window;if(e.toString()!=="[object Window]"){var t=e.ownerDocument;return t&&t.defaultView||window}return e}function vc(e){var t=$a(e).Element;return e instanceof t||e instanceof Element}function Qa(e){var t=$a(e).HTMLElement;return e instanceof t||e instanceof HTMLElement}function p4(e){if(typeof ShadowRoot>"u")return!1;var t=$a(e).ShadowRoot;return e instanceof t||e instanceof ShadowRoot}function hG(e){var t=e.state;
vendor: 19,464 bytes, line 41
41Object.keys(t.elements).forEach(function(r){var i=t.styles[r]||{},n=t.attributes[r]||{},a=t.elements[r];!Qa(a)||!oo(a)||(Object.assign(a.style,i),Object.keys(n).forEach(function(s){var o=n[s];o===!1?a.removeAttribute(s):a.setAttribute(s,o===!0?"":o)}))})}function fG(e){var t=e.state,r={popper:{position:t.options.strategy,left:"0",top:"0",margin:"0"},arrow:{position:"absolute"},reference:{}};return Object.assign(t.elements.popper.style,r.popper),t.styles=r,t.elements.arrow&&Object.assign(t.elements.arrow.style,r.arrow),function(){Object.keys(t.elements).forEach(function(i){var n=t.elements[i],a=t.attributes[i]||{},s=Object.keys(t.styles.hasOwnProperty(i)?t.styles[i]:r[i]),o=s.reduce(function(l,u){return l[u]="",l},{});!Qa(n)||!oo(n)||(Object.assign(n.style,o),Object.keys(a).forEach(function(l){n.removeAttribute(l)}))})}}const pG={name:"applyStyles",enabled:!0,phase:"write",fn:hG,effect:fG,requires:["computeStyles"]};function to(e){return e.split("-")[0]}var Qu=Math.max,W_=Math.min,fh=Math.round;function j2(){var e=navigator.userAgentData;return e!=null&&e.brands&&Array.isArray(e.brands)?e.brands.map(function(t){return t.brand+"/"+t.version}).join(" "):navigator.userAgent}function wA(){return!/^((?!chrome|android).)*safari/i.test(j2())}function ph(e,t,r){t===void 0&&(t=!1),r===void 0&&(r=!1);var i=e.getBoundingClientRect(),n=1,a=1;t&&Qa(e)&&(n=e.offsetWidth>0&&fh(i.width)/e.offsetWidth||1,a=e.offsetHeight>0&&fh(i.height)/e.offsetHeight||1);var s=vc(e)?$a(e):window,o=s.visualViewport,l=!wA()&&r,u=(i.left+(l&&o?o.offsetLeft:0))/n,c=(i.top+(l&&o?o.offsetTop:0))/a,d=i.width/n,h=i.height/a;return{width:d,height:h,top:c,right:u+d,bottom:c+h,left:u,x:u,y:c}}function m4(e){var t=ph(e),r=e.offsetWidth,i=e.offsetHeight;return Math.abs(t.width-r)<=1&&(r=t.width),Math.abs(t.height-i)<=1&&(i=t.height),{x:e.offsetLeft,y:e.offsetTop,width:r,height:i}}function $A(e,t){var r=t.getRootNode&&t.getRootNode();if(e.contains(t))return!0;if(r&&p4(r)){var i=t;do{if(i&&e.isSameNode(i))return!0;i=i.parentNode||i.host}while(i)}return!1}function rl(e){return $a(e).getComputedStyle(e)}function mG(e){return["table","td","th"].indexOf(oo(e))>=0}function fu(e){return((vc(e)?e.ownerDocument:e.document)||window.document).documentElement}function w1(e){return oo(e)==="html"?e:e.assignedSlot||e.parentNode||(p4(e)?e.host:null)||fu(e)}function cT(e){return!Qa(e)||rl(e).position==="fixed"?null:e.offsetParent}function gG(e){var t=/firefox/i.test(j2()),r=/Trident/i.test(j2());if(r&&Qa(e)){var i=rl(e);if(i.position==="fixed")return null}var n=w1(e);for(p4(n)&&(n=n.host);Qa(n)&&["html","body"].indexOf(oo(n))<0;){var a=rl(n);if(a.transform!=="none"||a.perspective!=="none"||a.contain==="paint"||["transform","perspective"].indexOf(a.willChange)!==-1||t&&a.willChange==="filter"||t&&a.filter&&a.filter!=="none")return n;n=n.parentNode}return null}function Jm(e){for(var t=$a(e),r=cT(e);r&&mG(r)&&rl(r).position==="static";)r=cT(r);return r&&(oo(r)==="html"||oo(r)==="body"&&rl(r).position==="static")?t:r||gG(e)||t}function g4(e){return["top","bottom"].indexOf(e)>=0?"x":"y"}function hp(e,t,r){return Qu(e,W_(t,r))}function _G(e,t,r){var i=hp(e,t,r);return i>r?r:i}function SA(){return{top:0,right:0,bottom:0,left:0}}function TA(e){return Object.assign({},SA(),e)}function CA(e,t){return t.reduce(function(r,i){return r[i]=e,r},{})}var yG=function(t,r){return t=typeof t=="function"?t(Object.assign({},r.rects,{placement:r.placement})):t,TA(typeof t!="number"?t:CA(t,Xm))};function vG(e){var t,r=e.state,i=e.name,n=e.options,a=r.elements.arrow,s=r.modifiersData.popperOffsets,o=to(r.placement),l=g4(o),u=[Yn,as].indexOf(o)>=0,c=u?"height":"width";if(!(!a||!s)){var d=yG(n.padding,r),h=m4(a),f=l==="y"?Hn:Yn,p=l==="y"?ns:as,m=r.rects.reference[c]+r.rects.reference[l]-s[l]-r.rects.popper[c],g=s[l]-r.rects.reference[l],v=Jm(a),x=v?l==="y"?v.clientHeight||0:v.clientWidth||0:0,_=m/2-g/2,y=d[f],w=x-h[c]-d[p],$=x/2-h[c]/2+_,S=hp(y,$,w),E=l;r.modifiersData[i]=(t={},t[E]=S,t.centerOffset=S-$,t)}}function bG(e){var t=e.state,r=e.options,i=r.element,n=i===void 0?"[data-popper-arrow]":i;n!=null&&(typeof n=="string"&&(n=t.elements.popper.querySelector(n),!n)||$A(t.elements.popper,n)&&(t.elements.arrow=n))}const xG={name:"arrow",enabled:!0,phase:"main",fn:vG,effect:bG,requires:["popperOffsets"],requiresIfExists:["preventOverflow"]};function mh(e){return e.split("-")[1]}var wG={top:"auto",right:"auto",bottom:"auto",left:"auto"};function $G(e,t){var r=e.x,i=e.y,n=t.devicePixelRatio||1;return{x:fh(r*n)/n||0,y:fh(i*n)/n||0}}function dT(e){var t,r=e.popper,i=e.popperRect,n=e.placement,a=e.variation,s=e.offsets,o=e.position,l=e.gpuAcceleration,u=e.adaptive,c=e.roundOffsets,d=e.isFixed,h=s.x,f=h===void 0?0:h,p=s.y,m=p===void 0?0:p,g=typeof c=="function"?c({x:f,y:m}):{x:f,y:m};f=g.x,m=g.y;var v=s.hasOwnProperty("x"),x=s.hasOwnProperty("y"),_=Yn,y=Hn,w=window;if(u){var $=Jm(r),S="clientHeight",E="clientWidth";if($===$a(r)&&($=fu(r),rl($).position!=="static"&&o==="absolute"&&(S="scrollHeight",E="scrollWidth")),$=$,n===Hn||(n===Yn||n===as)&&a===tm){y=ns;var C=d&&$===w&&w.visualViewport?w.visualViewport.height:$[S];m-=C-i.height,m*=l?1:-1}if(n===Yn||(n===Hn||n===ns)&&a===tm){_=as;var I=d&&$===w&&w.visualViewport?w.visualViewport.width:$[E];f-=I-i.width,f*=l?1:-1}}var P=Object.assign({position:o},u&&wG),T=c===!0?$G({x:f,y:m},$a(r)):{x:f,y:m};if(f=T.x,m=T.y,l){var D;return Object.assign({},P,(D={},D[y]=x?"0":"",D[_]=v?"0":"",D.transform=(w.devicePixelRatio||1)<=1?"translate("+f+"px, "+m+"px)":"translate3d("+f+"px, "+m+"px, 0)",D))}return Object.assign({},P,(t={},t[y]=x?m+"px":"",t[_]=v?f+"px":"",t.transform="",t))}function SG(e){var t=e.state,r=e.options,i=r.gpuAcceleration,n=i===void 0?!0:i,a=r.adaptive,s=a===void 0?!0:a,o=r.roundOffsets,l=o===void 0?!0:o,u={placement:to(t.placement),variation:mh(t.placement),popper:t.elements.popper,popperRect:t.rects.popper,gpuAcceleration:n,isFixed:t.options.strategy==="fixed"};t.modifiersData.popperOffsets!=null&&(t.styles.popper=Object.assign({},t.styles.popper,dT(Object.assign({},u,{offsets:t.modifiersData.popperOffsets,position:t.options.strategy,adaptive:s,roundOffsets:l})))),t.modifiersData.arrow!=null&&(t.styles.arrow=Object.assign({},t.styles.arrow,dT(Object.assign({},u,{offsets:t.modifiersData.arrow,position:"absolute",adaptive:!1,roundOffsets:l})))),t.attributes.popper=Object.assign({},t.attributes.popper,{"data-popper-placement":t.placement})}const TG={name:"computeStyles",enabled:!0,phase:"beforeWrite",fn:SG,data:{}};var jg={passive:!0};function CG(e){var t=e.state,r=e.instance,i=e.options,n=i.scroll,a=n===void 0?!0:n,s=i.resize,o=s===void 0?!0:s,l=$a(t.elements.popper),u=[].concat(t.scrollParents.reference,t.scrollParents.popper);return a&&u.forEach(function(c){c.addEventListener("scroll",r.update,jg)}),o&&l.addEventListener("resize",r.update,jg),function(){a&&u.forEach(function(c){c.removeEventListener("scroll",r.update,jg)}),o&&l.removeEventListener("resize",r.update,jg)}}const kG={name:"eventListeners",enabled:!0,phase:"write",fn:function(){},effect:CG,data:{}};var EG={left:"right",right:"left",bottom:"top",top:"bottom"};function G0(e){return e.replace(/left|right|bottom|top/g,function(t){return EG[t]})}var PG={start:"end",end:"start"};function hT(e){return e.replace(/start|end/g,function(t){return PG[t]})}function _4(e){var t=$a(e),r=t.pageXOffset,i=t.pageYOffset;return{scrollLeft:r,scrollTop:i}}function y4(e){return ph(fu(e)).left+_4(e).scrollLeft}function MG(e,t){var r=$a(e),i=fu(e),n=r.visualViewport,a=i.clientWidth,s=i.clientHeight,o=0,l=0;if(n){a=n.width,s=n.height;var u=wA();(u||!u&&t==="fixed")&&(o=n.offsetLeft,l=n.offsetTop)}return{width:a,height:s,x:o+y4(e),y:l}}function IG(e){var t,r=fu(e),i=_4(e),n=(t=e.ownerDocument)==null?void 0:t.body,a=Qu(r.scrollWidth,r.clientWidth,n?n.scrollWidth:0,n?n.clientWidth:0),s=Qu(r.scrollHeight,r.clientHeight,n?n.scrollHeight:0,n?n.clientHeight:0),o=-i.scrollLeft+y4(e),l=-i.scrollTop;return rl(n||r).direction==="rtl"&&(o+=Qu(r.clientWidth,n?n.clientWidth:0)-a),{width:a,height:s,x:o,y:l}}function v4(e){var t=rl(e),r=t.overflow,i=t.overflowX,n=t.overflowY;return/auto|scroll|overlay|hidden/.test(r+n+i)}function kA(e){return["html","body","#document"].indexOf(oo(e))>=0?e.ownerDocument.body:Qa(e)&&v4(e)?e:kA(w1(e))}function fp(e,t){var r;t===void 0&&(t=[]);var i=kA(e),n=i===((r=e.ownerDocument)==null?void 0:r.body),a=$a(i),s=n?[a].concat(a.visualViewport||[],v4(i)?i:[]):i,o=t.concat(s);return n?o:o.concat(fp(w1(s)))}function U2(e){return Object.assign({},e,{left:e.x,top:e.y,right:e.x+e.width,bottom:e.y+e.height})}function AG(e,t){var r=ph(e,!1,t==="fixed");return r.top=r.top+e.clientTop,r.left=r.left+e.clientLeft,r.bottom=r.top+e.clientHeight,r.right=r.left+e.clientWidth,r.width=e.clientWidth,r.height=e.clientHeight,r.x=r.left,r.y=r.top,r}function fT(e,t,r){return t===bA?U2(MG(e,r)):vc(t)?AG(t,r):U2(IG(fu(e)))}function DG(e){var t=fp(w1(e)),r=["absolute","fixed"].indexOf(rl(e).position)>=0,i=r&&Qa(e)?Jm(e):e;return vc(i)?t.filter(function(n){return vc(n)&&$A(n,i)&&oo(n)!=="body"}):[]}function RG(e,t,r,i){var n=t==="clippingParents"?DG(e):[].concat(t),a=[].concat(n,[r]),s=a[0],o=a.reduce(function(l,u){var c=fT(e,u,i);return l.top=Qu(c.top,l.top),l.right=W_(c.right,l.right),l.bottom=W_(c.bottom,l.bottom),l.left=Qu(c.left,l.left),l},fT(e,s,i));return o.width=o.right-o.left,o.height=o.bottom-o.top,o.x=o.left,o.y=o.top,o}function EA(e){var t=e.reference,r=e.element,i=e.placement,n=i?to(i):null,a=i?mh(i):null,s=t.x+t.width/2-r.width/2,o=t.y+t.height/2-r.height/2,l;switch(n){case Hn:l={x:s,y:t.y-r.height};break;case ns:l={x:s,y:t.y+t.height};break;case as:l={x:t.x+t.width,y:o};break;case Yn:l={x:t.x-r.width,y:o};break;default:l={x:t.x,y:t.y}}var u=n?g4(n):null;if(u!=null){var c=u==="y"?"height":"width";switch(a){case hh:l[u]=l[u]-(t[c]/2-r[c]/2);break;case tm:l[u]=l[u]+(t[c]/2-r[c]/2);break}}return l}function rm(e,t){t===void 0&&(t={});var r=t,i=r.placement,n=i===void 0?e.placement:i,a=r.strategy,s=a===void 0?e.strategy:a,o=r.boundary,l=o===void 0?eG:o,u=r.rootBoundary,c=u===void 0?bA:u,d=r.elementContext,h=d===void 0?ff:d,f=r.altBoundary,p=f===void 0?!1:f,m=r.padding,g=m===void 0?0:m,v=TA(typeof g!="number"?g:CA(g,Xm)),x=h===ff?tG:ff,_=e.rects.popper,y=e.elements[p?x:h],w=RG(vc(y)?y:y.contextElement||fu(e.elements.popper),l,c,s),$=ph(e.elements.reference),S=EA({reference:$,element:_,placement:n}),E=U2(Object.assign({},_,S)),C=h===ff?E:$,I={top:w.top-C.top+v.top,bottom:C.bottom-w.bottom+v.bottom,left:w.left-C.left+v.left,right:C.right-w.right+v.right},P=e.modifiersData.offset;if(h===ff&&P){var T=P[n];Object.keys(I).forEach(function(D){var A=[as,ns].indexOf(D)>=0?1:-1,z=[Hn,ns].indexOf(D)>=0?"y":"x";I[D]+=T[z]*A})}return I}function OG(e,t){t===void 0&&(t={});var r=t,i=r.placement,n=r.boundary,a=r.rootBoundary,s=r.padding,o=r.flipVariations,l=r.allowedAutoPlacements,u=l===void 0?xA:l,c=mh(i),d=c?o?uT:uT.filter(function(p){return mh(p)===c}):Xm,h=d.filter(function(p){return u.indexOf(p)>=0});h.length===0&&(h=d);var f=h.reduce(function(p,m){return p[m]=rm(e,{placement:m,boundary:n,rootBoundary:a,padding:s})[to(m)],p},{});return Object.keys(f).sort(function(p,m){return f[p]-f[m]})}function LG(e){if(to(e)===f4)return[];var t=G0(e);return[hT(e),t,hT(t)]}function FG(e){var t=e.state,r=e.options,i=e.name;if(!t.modifiersData[i]._skip){for(var n=r.mainAxis,a=n===void 0?!0:n,s=r.altAxis,o=s===void 0?!0:s,l=r.fallbackPlacements,u=r.padding,c=r.boundary,d=r.rootBoundary,h=r.altBoundary,f=r.flipVariations,p=f===void 0?!0:f,m=r.allowedAutoPlacements,g=t.options.placement,v=to(g),x=v===g,_=l||(x||!p?[G0(g)]:LG(g)),y=[g].concat(_).reduce(function(K,fe){return K.concat(to(fe)===f4?OG(t,{placement:fe,boundary:c,rootBoundary:d,padding:u,flipVariations:p,allowedAutoPlacements:m}):fe)},[]),w=t.rects.reference,$=t.rects.popper,S=new Map,E=!0,C=y[0],I=0;I<y.length;I++){var P=y[I],T=to(P),D=mh(P)===hh,A=[Hn,ns].indexOf(T)>=0,z=A?"width":"height",R=rm(t,{placement:P,boundary:c,rootBoundary:d,altBoundary:h,padding:u}),O=A?D?as:Yn:D?ns:Hn;w[z]>$[z]&&(O=G0(O));var V=G0(O),Y=[];if(a&&Y.push(R[T]<=0),o&&Y.push(R[O]<=0,R[V]<=0),Y.every(function(K){return K})){C=P,E=!1;break}S.set(P,Y)}if(E)for(var F=p?3:1,ae=function(fe){var ve=y.find(function($e){var Re=S.get($e);if(Re)return Re.slice(0,fe).every(function(Oe){return Oe})});if(ve)return C=ve,"break"},ue=F;ue>0;ue--){var Z=ae(ue);if(Z==="break")break}t.placement!==C&&(t.modifiersData[i]._skip=!0,t.placement=C,t.reset=!0)}}const zG={name:"flip",enabled:!0,phase:"main",fn:FG,requiresIfExists:["offset"],data:{_skip:!1}};function pT(e,t,r){return r===void 0&&(r={x:0,y:0}),{top:e.top-t.height-r.y,right:e.right-t.width+r.x,bottom:e.bottom-t.height+r.y,left:e.left-t.width-r.x}}function mT(e){return[Hn,as,ns,Yn].some(function(t){return e[t]>=0})}function NG(e){var t=e.state,r=e.name,i=t.rects.reference,n=t.rects.popper,a=t.modifiersData.preventOverflow,s=rm(t,{elementContext:"reference"}),o=rm(t,{altBoundary:!0}),l=pT(s,i),u=pT(o,n,a),c=mT(l),d=mT(u);t.modifiersData[r]={referenceClippingOffsets:l,popperEscapeOffsets:u,isReferenceHidden:c,hasPopperEscaped:d},t.attributes.popper=Object.assign({},t.attributes.popper,{"data-popper-reference-hidden":c,"data-popper-escaped":d})}const BG={name:"hide",enabled:!0,phase:"main",requiresIfExists:["preventOverflow"],fn:NG};function jG(e,t,r){var i=to(e),n=[Yn,Hn].indexOf(i)>=0?-1:1,a=typeof r=="function"?r(Object.assign({},t,{placement:e})):r,s=a[0],o=a[1];return s=s||0,o=(o||0)*n,[Yn,as].indexOf(i)>=0?{x:o,y:s}:{x:s,y:o}}function UG(e){var t=e.state,r=e.options,i=e.name,n=r.offset,a=n===void 0?[0,0]:n,s=xA.reduce(function(c,d){return c[d]=jG(d,t.rects,a),c},{}),o=s[t.placement],l=o.x,u=o.y;t.modifiersData.popperOffsets!=null&&(t.modifiersData.popperOffsets.x+=l,t.modifiersData.popperOffsets.y+=u),t.modifiersData[i]=s}const VG={name:"offset",enabled:!0,phase:"main",requires:["popperOffsets"],fn:UG};function qG(e){var t=e.state,r=e.name;t.modifiersData[r]=EA({reference:t.rects.reference,element:t.rects.popper,placement:t.placement})}const GG={name:"popperOffsets",enabled:!0,phase:"read",fn:qG,data:{}};function HG(e){return e==="x"?"y":"x"}function YG(e){var t=e.state,r=e.options,i=e.name,n=r.mainAxis,a=n===void 0?!0:n,s=r.altAxis,o=s===void 0?!1:s,l=r.boundary,u=r.rootBoundary,c=r.altBoundary,d=r.padding,h=r.tether,f=h===void 0?!0:h,p=r.tetherOffset,m=p===void 0?0:p,g=rm(t,{boundary:l,rootBoundary:u,padding:d,altBoundary:c}),v=to(t.placement),x=mh(t.placement),_=!x,y=g4(v),w=HG(y),$=t.modifiersData.popperOffsets,S=t.rects.reference,E=t.rects.popper,C=typeof m=="function"?m(Object.assign({},t.rects,{placement:t.placement})):m,I=typeof C=="number"?{mainAxis:C,altAxis:C}:Object.assign({mainAxis:0,altAxis:0},C),P=t.modifiersData.offset?t.modifiersData.offset[t.placement]:null,T={x:0,y:0};if($){if(a){var D,A=y==="y"?Hn:Yn,z=y==="y"?ns:as,R=y==="y"?"height":"width",O=$[y],V=O+g[A],Y=O-g[z],F=f?-E[R]/2:0,ae=x===hh?S[R]:E[R],ue=x===hh?-E[R]:-S[R],Z=t.elements.arrow,K=f&&Z?m4(Z):{width:0,height:0},fe=t.modifiersData["arrow#persistent"]?t.modifiersData["arrow#persistent"].padding:SA(),ve=fe[A],$e=fe[z],Re=hp(0,S[R],K[R]),Oe=_?S[R]/2-F-Re-ve-I.mainAxis:ae-Re-ve-I.mainAxis,ze=_?-S[R]/2+F+Re+$e+I.mainAxis:ue+Re+$e+I.mainAxis,Be=t.elements.arrow&&Jm(t.elements.arrow),qe=Be?y==="y"?Be.clientTop||0:Be.clientLeft||0:0,j=(D=P==null?void 0:P[y])!=null?D:0,W=O+Oe-j-qe,G=O+ze-j,ie=hp(f?W_(V,W):V,O,f?Qu(Y,G):Y);$[y]=ie,T[y]=ie-O}if(o){var U,ne=y==="x"?Hn:Yn,me=y==="x"?ns:as,J=$[w],N=w==="y"?"height":"width",q=J+g[ne],te=J-g[me],ee=[Hn,Yn].indexOf(v)!==-1,oe=(U=P==null?void 0:P[w])!=null?U:0,Se=ee?q:J-S[N]-E[N]-oe+I.altAxis,we=ee?J+S[N]+E[N]-oe-I.altAxis:te,De=f&&ee?_G(Se,J,we):hp(f?Se:q,J,f?we:te);$[w]=De,T[w]=De-J}t.modifiersData[i]=T}}const WG={name:"preventOverflow",enabled:!0,phase:"main",fn:YG,requiresIfExists:["offset"]};function ZG(e){return{scrollLeft:e.scrollLeft,scrollTop:e.scrollTop}}function KG(e){return e===$a(e)||!Qa(e)?_4(e):ZG(e)}function XG(e){var t=e.getBoundingClientRect(),r=fh(t.width)/e.offsetWidth||1,i=fh(t.height)/e.offsetHeight||1;return r!==1||i!==1}function JG(e,t,r){r===void 0&&(r=!1);var i=Qa(t),n=Qa(t)&&XG(t),a=fu(t),s=ph(e,n,r),o={scrollLeft:0,scrollTop:0},l={x:0,y:0};return(i||!i&&!r)&&((oo(t)!=="body"||v4(a))&&(o=KG(t)),Qa(t)?(l=ph(t,!0),l.x+=t.clientLeft,l.y+=t.clientTop):a&&(l.x=y4(a))),{x:s.left+o.scrollLeft-l.x,y:s.top+o.scrollTop-l.y,width:s.width,height:s.height}}function QG(e){var t=new Map,r=new Set,i=[];e.forEach(function(a){t.set(a.name,a)});function n(a){r.add(a.name);var s=[].concat(a.requires||[],a.requiresIfExists||[]);s.forEach(function(o){if(!r.has(o)){var l=t.get(o);l&&n(l)}}),i.push(a)}return e.forEach(function(a){r.has(a.name)||n(a)}),i}function eH(e){var t=QG(e);return dG.reduce(function(r,i){return r.concat(t.filter(function(n){return n.phase===i}))},[])}function tH(e){var t;return function(){return t||(t=new Promise(function(r){Promise.resolve().then(function(){t=void 0,r(e())})})),t}}function rH(e){var t=e.reduce(function(r,i){var n=r[i.name];return r[i.name]=n?Object.assign({},n,i,{options:Object.assign({},n.options,i.options),data:Object.assign({},n.data,i.data)}):i,r},{});return Object.keys(t).map(function(r){return t[r]})}var gT={placement:"bottom",modifiers:[],strategy:"absolute"};function _T(){for(var e=arguments.length,t=new Array(e),r=0;r<e;r++)t[r]=arguments[r];return!t.some(function(i){return!(i&&typeof i.getBoundingClientRect=="function")})}function iH(e){e===void 0&&(e={});var t=e,r=t.defaultModifiers,i=r===void 0?[]:r,n=t.defaultOptions,a=n===void 0?gT:n;return function(o,l,u){u===void 0&&(u=a);var c={placement:"bottom",orderedModifiers:[],options:Object.assign({},gT,a),modifiersData:{},elements:{reference:o,popper:l},attributes:{},styles:{}},d=[],h=!1,f={state:c,setOptions:function(v){var x=typeof v=="function"?v(c.options):v;m(),c.options=Object.assign({},a,c.options,x),c.scrollParents={reference:vc(o)?fp(o):o.contextElement?fp(o.contextElement):[],popper:fp(l)};var _=eH(rH([].concat(i,c.options.modifiers)));return c.orderedModifiers=_.filter(function(y){return y.enabled}),p(),f.update()},forceUpdate:function(){if(!h){var v=c.elements,x=v.reference,_=v.popper;if(_T(x,_)){c.rects={reference:JG(x,Jm(_),c.options.strategy==="fixed"),popper:m4(_)},c.reset=!1,c.placement=c.options.placement,c.orderedModifiers.forEach(function(I){return c.modifiersData[I.name]=Object.assign({},I.data)});for(var y=0;y<c.orderedModifiers.length;y++){if(c.reset===!0){c.reset=!1,y=-1;continue}var w=c.orderedModifiers[y],$=w.fn,S=w.options,E=S===void 0?{}:S,C=w.name;typeof $=="function"&&(c=$({state:c,options:E,name:C,instance:f})||c)}}}},update:tH(function(){return new Promise(function(g){f.forceUpdate(),g(c)})}),destroy:function(){m(),h=!0}};if(!_T(o,l))return f;f.setOptions(u).then(function(g){!h&&u.onFirstUpdate&&u.onFirstUpdate(g)});function p(){c.orderedModifiers.forEach(function(g){var v=g.name,x=g.options,_=x===void 0?{}:x,y=g.effect;if(typeof y=="function"){var w=y({state:c,name:v,instance:f,options:_}),$=function(){};d.push(w||$)}})}function m(){d.forEach(function(g){return g()}),d=[]}return f}}var nH=[kG,GG,TG,pG,VG,zG,WG,xG,BG],aH=iH({defaultModifiers:nH}),sH=Object.defineProperty,oH=(e,t,r)=>t in e?sH(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,Xe=(e,t,r)=>(oH(e,typeof t!="symbol"?t+"":t,r),r),Ug=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};
vendor: 11,983 bytes, line 41
41function PA(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var lH=Object.prototype,uH=lH.hasOwnProperty;function cH(e,t){return e!=null&&uH.call(e,t)}var dH=cH,hH=Array.isArray,Is=hH,fH=typeof Ug=="object"&&Ug&&Ug.Object===Object&&Ug,MA=fH,pH=MA,mH=typeof self=="object"&&self&&self.Object===Object&&self,gH=pH||mH||Function("return this")(),ho=gH,_H=ho,yH=_H.Symbol,$1=yH,yT=$1,IA=Object.prototype,vH=IA.hasOwnProperty,bH=IA.toString,pf=yT?yT.toStringTag:void 0;function xH(e){var t=vH.call(e,pf),r=e[pf];try{e[pf]=void 0;var i=!0}catch{}var n=bH.call(e);return i&&(t?e[pf]=r:delete e[pf]),n}var wH=xH,$H=Object.prototype,SH=$H.toString;function TH(e){return SH.call(e)}var CH=TH,vT=$1,kH=wH,EH=CH,PH="[object Null]",MH="[object Undefined]",bT=vT?vT.toStringTag:void 0;function IH(e){return e==null?e===void 0?MH:PH:bT&&bT in Object(e)?kH(e):EH(e)}var fo=IH;function AH(e){return e!=null&&typeof e=="object"}var As=AH,DH=fo,RH=As,OH="[object Symbol]";function LH(e){return typeof e=="symbol"||RH(e)&&DH(e)==OH}var b4=LH,FH=Is,zH=b4,NH=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,BH=/^\w*$/;function jH(e,t){if(FH(e))return!1;var r=typeof e;return r=="number"||r=="symbol"||r=="boolean"||e==null||zH(e)?!0:BH.test(e)||!NH.test(e)||t!=null&&e in Object(t)}var x4=jH;function UH(e){var t=typeof e;return e!=null&&(t=="object"||t=="function")}var ml=UH,VH=fo,qH=ml,GH="[object AsyncFunction]",HH="[object Function]",YH="[object GeneratorFunction]",WH="[object Proxy]";function ZH(e){if(!qH(e))return!1;var t=VH(e);return t==HH||t==YH||t==GH||t==WH}var Dc=ZH,KH=ho,XH=KH["__core-js_shared__"],JH=XH,Nv=JH,xT=(function(){var e=/[^.]+$/.exec(Nv&&Nv.keys&&Nv.keys.IE_PROTO||"");return e?"Symbol(src)_1."+e:""})();function QH(e){return!!xT&&xT in e}var eY=QH,tY=Function.prototype,rY=tY.toString;function iY(e){if(e!=null){try{return rY.call(e)}catch{}try{return e+""}catch{}}return""}var AA=iY,nY=Dc,aY=eY,sY=ml,oY=AA,lY=/[\\^$.*+?()[\]{}|]/g,uY=/^\[object .+?Constructor\]$/,cY=Function.prototype,dY=Object.prototype,hY=cY.toString,fY=dY.hasOwnProperty,pY=RegExp("^"+hY.call(fY).replace(lY,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function mY(e){if(!sY(e)||aY(e))return!1;var t=nY(e)?pY:uY;return t.test(oY(e))}var gY=mY;function _Y(e,t){return e==null?void 0:e[t]}var yY=_Y,vY=gY,bY=yY;function xY(e,t){var r=bY(e,t);return vY(r)?r:void 0}var Rc=xY,wY=Rc,$Y=wY(Object,"create"),S1=$Y,wT=S1;function SY(){this.__data__=wT?wT(null):{},this.size=0}var TY=SY;function CY(e){var t=this.has(e)&&delete this.__data__[e];return this.size-=t?1:0,t}var kY=CY,EY=S1,PY="__lodash_hash_undefined__",MY=Object.prototype,IY=MY.hasOwnProperty;function AY(e){var t=this.__data__;if(EY){var r=t[e];return r===PY?void 0:r}return IY.call(t,e)?t[e]:void 0}var DY=AY,RY=S1,OY=Object.prototype,LY=OY.hasOwnProperty;function FY(e){var t=this.__data__;return RY?t[e]!==void 0:LY.call(t,e)}var zY=FY,NY=S1,BY="__lodash_hash_undefined__";function jY(e,t){var r=this.__data__;return this.size+=this.has(e)?0:1,r[e]=NY&&t===void 0?BY:t,this}var UY=jY,VY=TY,qY=kY,GY=DY,HY=zY,YY=UY;function Vh(e){var t=-1,r=e==null?0:e.length;for(this.clear();++t<r;){var i=e[t];this.set(i[0],i[1])}}Vh.prototype.clear=VY;Vh.prototype.delete=qY;Vh.prototype.get=GY;Vh.prototype.has=HY;Vh.prototype.set=YY;var WY=Vh;function ZY(){this.__data__=[],this.size=0}var KY=ZY;function XY(e,t){return e===t||e!==e&&t!==t}var qh=XY,JY=qh;function QY(e,t){for(var r=e.length;r--;)if(JY(e[r][0],t))return r;return-1}var T1=QY,eW=T1,tW=Array.prototype,rW=tW.splice;function iW(e){var t=this.__data__,r=eW(t,e);if(r<0)return!1;var i=t.length-1;return r==i?t.pop():rW.call(t,r,1),--this.size,!0}var nW=iW,aW=T1;function sW(e){var t=this.__data__,r=aW(t,e);return r<0?void 0:t[r][1]}var oW=sW,lW=T1;function uW(e){return lW(this.__data__,e)>-1}var cW=uW,dW=T1;function hW(e,t){var r=this.__data__,i=dW(r,e);return i<0?(++this.size,r.push([e,t])):r[i][1]=t,this}var fW=hW,pW=KY,mW=nW,gW=oW,_W=cW,yW=fW;function Gh(e){var t=-1,r=e==null?0:e.length;for(this.clear();++t<r;){var i=e[t];this.set(i[0],i[1])}}Gh.prototype.clear=pW;Gh.prototype.delete=mW;Gh.prototype.get=gW;Gh.prototype.has=_W;Gh.prototype.set=yW;var C1=Gh,vW=Rc,bW=ho,xW=vW(bW,"Map"),w4=xW,$T=WY,wW=C1,$W=w4;function SW(){this.size=0,this.__data__={hash:new $T,map:new($W||wW),string:new $T}}var TW=SW;function CW(e){var t=typeof e;return t=="string"||t=="number"||t=="symbol"||t=="boolean"?e!=="__proto__":e===null}var kW=CW,EW=kW;function PW(e,t){var r=e.__data__;return EW(t)?r[typeof t=="string"?"string":"hash"]:r.map}var k1=PW,MW=k1;function IW(e){var t=MW(this,e).delete(e);return this.size-=t?1:0,t}var AW=IW,DW=k1;function RW(e){return DW(this,e).get(e)}var OW=RW,LW=k1;function FW(e){return LW(this,e).has(e)}var zW=FW,NW=k1;function BW(e,t){var r=NW(this,e),i=r.size;return r.set(e,t),this.size+=r.size==i?0:1,this}var jW=BW,UW=TW,VW=AW,qW=OW,GW=zW,HW=jW;function Hh(e){var t=-1,r=e==null?0:e.length;for(this.clear();++t<r;){var i=e[t];this.set(i[0],i[1])}}Hh.prototype.clear=UW;Hh.prototype.delete=VW;Hh.prototype.get=qW;Hh.prototype.has=GW;Hh.prototype.set=HW;var $4=Hh,DA=$4,YW="Expected a function";function S4(e,t){if(typeof e!="function"||t!=null&&typeof t!="function")throw new TypeError(YW);var r=function(){var i=arguments,n=t?t.apply(this,i):i[0],a=r.cache;if(a.has(n))return a.get(n);var s=e.apply(this,i);return r.cache=a.set(n,s)||a,s};return r.cache=new(S4.Cache||DA),r}S4.Cache=DA;var WW=S4,ZW=WW,KW=500;function XW(e){var t=ZW(e,function(i){return r.size===KW&&r.clear(),i}),r=t.cache;return t}var JW=XW,QW=JW,eZ=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,tZ=/\\(\\)?/g,rZ=QW(function(e){var t=[];return e.charCodeAt(0)===46&&t.push(""),e.replace(eZ,function(r,i,n,a){t.push(n?a.replace(tZ,"$1"):i||r)}),t}),iZ=rZ;function nZ(e,t){for(var r=-1,i=e==null?0:e.length,n=Array(i);++r<i;)n[r]=t(e[r],r,e);return n}var aZ=nZ,ST=$1,sZ=aZ,oZ=Is,lZ=b4,TT=ST?ST.prototype:void 0,CT=TT?TT.toString:void 0;function RA(e){if(typeof e=="string")return e;if(oZ(e))return sZ(e,RA)+"";if(lZ(e))return CT?CT.call(e):"";var t=e+"";return t=="0"&&1/e==-1/0?"-0":t}var uZ=RA,cZ=uZ;function dZ(e){return e==null?"":cZ(e)}var hZ=dZ,fZ=Is,pZ=x4,mZ=iZ,gZ=hZ;function _Z(e,t){return fZ(e)?e:pZ(e,t)?[e]:mZ(gZ(e))}var OA=_Z,yZ=fo,vZ=As,bZ="[object Arguments]";function xZ(e){return vZ(e)&&yZ(e)==bZ}var wZ=xZ,kT=wZ,$Z=As,LA=Object.prototype,SZ=LA.hasOwnProperty,TZ=LA.propertyIsEnumerable,CZ=kT((function(){return arguments})())?kT:function(e){return $Z(e)&&SZ.call(e,"callee")&&!TZ.call(e,"callee")},T4=CZ,kZ=9007199254740991,EZ=/^(?:0|[1-9]\d*)$/;function PZ(e,t){var r=typeof e;return t=t??kZ,!!t&&(r=="number"||r!="symbol"&&EZ.test(e))&&e>-1&&e%1==0&&e<t}var C4=PZ,MZ=9007199254740991;function IZ(e){return typeof e=="number"&&e>-1&&e%1==0&&e<=MZ}var k4=IZ,AZ=b4;function DZ(e){if(typeof e=="string"||AZ(e))return e;var t=e+"";return t=="0"&&1/e==-1/0?"-0":t}var E1=DZ,RZ=OA,OZ=T4,LZ=Is,FZ=C4,zZ=k4,NZ=E1;function BZ(e,t,r){t=RZ(t,e);for(var i=-1,n=t.length,a=!1;++i<n;){var s=NZ(t[i]);if(!(a=e!=null&&r(e,s)))break;e=e[s]}return a||++i!=n?a:(n=e==null?0:e.length,!!n&&zZ(n)&&FZ(s,n)&&(LZ(e)||OZ(e)))}var FA=BZ,jZ=dH,UZ=FA;function VZ(e,t){return e!=null&&UZ(e,t,jZ)}var zA=VZ,qZ=fo,GZ=As,HZ="[object Date]";function YZ(e){return GZ(e)&&qZ(e)==HZ}var WZ=YZ;function ZZ(e){return function(t){return e(t)}}var NA=ZZ,im={},KZ={get exports(){return im},set exports(e){im=e}};(function(e,t){var r=MA,i=t&&!t.nodeType&&t,n=i&&!0&&e&&!e.nodeType&&e,a=n&&n.exports===i,s=a&&r.process,o=(function(){try{var l=n&&n.require&&n.require("util").types;return l||s&&s.binding&&s.binding("util")}catch{}})();e.exports=o})(KZ,im);var XZ=WZ,JZ=NA,ET=im,PT=ET&&ET.isDate,QZ=PT?JZ(PT):XZ,eK=QZ,tK=fo,rK=Is,iK=As,nK="[object String]";function aK(e){return typeof e=="string"||!rK(e)&&iK(e)&&tK(e)==nK}var Zs=aK;function sK(e,t){for(var r=-1,i=e==null?0:e.length;++r<i;)if(t(e[r],r,e))return!0;return!1}var BA=sK,oK=C1;function lK(){this.__data__=new oK,this.size=0}var uK=lK;function cK(e){var t=this.__data__,r=t.delete(e);return this.size=t.size,r}var dK=cK;function hK(e){return this.__data__.get(e)}var fK=hK;function pK(e){return this.__data__.has(e)}var mK=pK,gK=C1,_K=w4,yK=$4,vK=200;function bK(e,t){var r=this.__data__;if(r instanceof gK){var i=r.__data__;if(!_K||i.length<vK-1)return i.push([e,t]),this.size=++r.size,this;r=this.__data__=new yK(i)}return r.set(e,t),this.size=r.size,this}var xK=bK,wK=C1,$K=uK,SK=dK,TK=fK,CK=mK,kK=xK;function Yh(e){var t=this.__data__=new wK(e);this.size=t.size}Yh.prototype.clear=$K;Yh.prototype.delete=SK;Yh.prototype.get=TK;Yh.prototype.has=CK;Yh.prototype.set=kK;var E4=Yh,EK="__lodash_hash_undefined__";function PK(e){return this.__data__.set(e,EK),this}var MK=PK;function IK(e){return this.__data__.has(e)}var AK=IK,DK=$4,RK=MK,OK=AK;function Z_(e){var t=-1,r=e==null?0:e.length;for(this.__data__=new DK;++t<r;)this.add(e[t])}Z_.prototype.add=Z_.prototype.push=RK;Z_.prototype.has=OK;var LK=Z_;function FK(e,t){return e.has(t)}var zK=FK,NK=LK,BK=BA,jK=zK,UK=1,VK=2;function qK(e,t,r,i,n,a){var s=r&UK,o=e.length,l=t.length;if(o!=l&&!(s&&l>o))return!1;var u=a.get(e),c=a.get(t);if(u&&c)return u==t&&c==e;var d=-1,h=!0,f=r&VK?new NK:void 0;for(a.set(e,t),a.set(t,e);++d<o;){var p=e[d],m=t[d];if(i)var g=s?i(m,p,d,t,e,a):i(p,m,d,e,t,a);if(g!==void 0){if(g)continue;h=!1;break}if(f){if(!BK(t,function(v,x){if(!jK(f,x)&&(p===v||n(p,v,r,i,a)))return f.push(x)})){h=!1;break}}else if(!(p===m||n(p,m,r,i,a))){h=!1;break}}return a.delete(e),a.delete(t),h}var jA=qK,GK=ho,HK=GK.Uint8Array,UA=HK;function YK(e){var t=-1,r=Array(e.size);return e.forEach(function(i,n){r[++t]=[n,i]}),r}var WK=YK;function ZK(e){var t=-1,r=Array(e.size);return e.forEach(function(i){r[++t]=i}),r}var KK=ZK,MT=$1,IT=UA,XK=qh,JK=jA,QK=WK,eX=KK,tX=1,rX=2,iX="[object Boolean]",nX="[object Date]",aX="[object Error]",sX="[object Map]",oX="[object Number]",lX="[object RegExp]",uX="[object Set]",cX="[object String]",dX="[object Symbol]",hX="[object ArrayBuffer]",fX="[object DataView]",AT=MT?MT.prototype:void 0,Bv=AT?AT.valueOf:void 0;function pX(e,t,r,i,n,a,s){switch(r){case fX:if(e.byteLength!=t.byteLength||e.byteOffset!=t.byteOffset)return!1;e=e.buffer,t=t.buffer;case hX:return!(e.byteLength!=t.byteLength||!a(new IT(e),new IT(t)));case iX:case nX:case oX:return XK(+e,+t);case aX:return e.name==t.name&&e.message==t.message;case lX:case cX:return e==t+"";case sX:var o=QK;case uX:var l=i&tX;if(o||(o=eX),e.size!=t.size&&!l)return!1;var u=s.get(e);if(u)return u==t;i|=rX,s.set(e,t);var c=JK(o(e),o(t),i,n,a,s);return s.delete(e),c;case dX:if(Bv)return Bv.call(e)==Bv.call(t)}return!1}var mX=pX;function gX(e,t){for(var r=-1,i=t.length,n=e.length;++r<i;)e[n+r]=t[r];return e}var _X=gX,yX=_X,vX=Is;function bX(e,t,r){var i=t(e);return vX(e)?i:yX(i,r(e))}var xX=bX;function wX(e,t){for(var r=-1,i=e==null?0:e.length,n=0,a=[];++r<i;){var s=e[r];t(s,r,e)&&(a[n++]=s)}return a}var $X=wX;function SX(){return[]}var TX=SX,CX=$X,kX=TX,EX=Object.prototype,PX=EX.propertyIsEnumerable,DT=Object.getOwnPropertySymbols,MX=DT?function(e){return e==null?[]:(e=Object(e),CX(DT(e),function(t){return PX.call(e,t)}))}:kX,IX=MX;function AX(e,t){for(var r=-1,i=Array(e);++r<e;)i[r]=t(r);return i}var DX=AX,gh={},RX={get exports(){return gh},set exports(e){gh=e}};function OX(){return!1}var LX=OX;(function(e,t){var r=ho,i=LX,n=t&&!t.nodeType&&t,a=n&&!0&&e&&!e.nodeType&&e,s=a&&a.exports===n,o=s?r.Buffer:void 0,l=o?o.isBuffer:void 0,u=l||i;e.exports=u})(RX,gh);var FX=fo,zX=k4,NX=As,BX="[object Arguments]",jX="[object Array]",UX="[object Boolean]",VX="[object Date]",qX="[object Error]",GX="[object Function]",HX="[object Map]",YX="[object Number]",WX="[object Object]",ZX="[object RegExp]",KX="[object Set]",XX="[object String]",JX="[object WeakMap]",QX="[object ArrayBuffer]",eJ="[object DataView]",tJ="[object Float32Array]",rJ="[object Float64Array
41]",iJ="[object Int8Array]",nJ="[object Int16Array]",aJ="[object Int32Array]",sJ="[object Uint8Array]",oJ="[object Uint8ClampedArray]",lJ="[object Uint16Array]",uJ="[object Uint32Array]",br={};br[tJ]=br[rJ]=br[iJ]=br[nJ]=br[aJ]=br[sJ]=br[oJ]=br[lJ]=br[uJ]=!0;br[BX]=br[jX]=br[QX]=br[UX]=br[eJ]=br[VX]=br[qX]=br[GX]=br[HX]=br[YX]=br[WX]=br[ZX]=br[KX]=br[XX]=br[JX]=!1;function cJ(e){return NX(e)&&zX(e.length)&&!!br[FX(e)]}var dJ=cJ,hJ=dJ,fJ=NA,RT=im,OT=RT&&RT.isTypedArray,pJ=OT?fJ(OT):hJ,P4=pJ,mJ=DX,gJ=T4,_J=Is,yJ=gh,vJ=C4,bJ=P4,xJ=Object.prototype,wJ=xJ.hasOwnProperty;function $J(e,t){var r=_J(e),i=!r&&gJ(e),n=!r&&!i&&yJ(e),a=!r&&!i&&!n&&bJ(e),s=r||i||n||a,o=s?mJ(e.length,String):[],l=o.length;for(var u in e)(t||wJ.call(e,u))&&!(s&&(u=="length"||n&&(u=="offset"||u=="parent")||a&&(u=="buffer"||u=="byteLength"||u=="byteOffset")||vJ(u,l)))&&o.push(u);return o}var VA=$J,SJ=Object.prototype;function TJ(e){var t=e&&e.constructor,r=typeof t=="function"&&t.prototype||SJ;return e===r}var M4=TJ;function CJ(e,t){return function(r){return e(t(r))}}var qA=CJ,kJ=qA,EJ=kJ(Object.keys,Object),PJ=EJ,MJ=M4,IJ=PJ,AJ=Object.prototype,DJ=AJ.hasOwnProperty;function RJ(e){if(!MJ(e))return IJ(e);var t=[];for(var r in Object(e))DJ.call(e,r)&&r!="constructor"&&t.push(r);return t}var OJ=RJ,LJ=Dc,FJ=k4;function zJ(e){return e!=null&&FJ(e.length)&&!LJ(e)}var Qm=zJ,NJ=VA,BJ=OJ,jJ=Qm;function UJ(e){return jJ(e)?NJ(e):BJ(e)}var I4=UJ,VJ=xX,qJ=IX,GJ=I4;function HJ(e){return VJ(e,GJ,qJ)}var YJ=HJ,LT=YJ,WJ=1,ZJ=Object.prototype,KJ=ZJ.hasOwnProperty;function XJ(e,t,r,i,n,a){var s=r&WJ,o=LT(e),l=o.length,u=LT(t),c=u.length;if(l!=c&&!s)return!1;for(var d=l;d--;){var h=o[d];if(!(s?h in t:KJ.call(t,h)))return!1}var f=a.get(e),p=a.get(t);if(f&&p)return f==t&&p==e;var m=!0;a.set(e,t),a.set(t,e);for(var g=s;++d<l;){h=o[d];var v=e[h],x=t[h];if(i)var _=s?i(x,v,h,t,e,a):i(v,x,h,e,t,a);if(!(_===void 0?v===x||n(v,x,r,i,a):_)){m=!1;break}g||(g=h=="constructor")}if(m&&!g){var y=e.constructor,w=t.constructor;y!=w&&"constructor"in e&&"constructor"in t&&!(typeof y=="function"&&y instanceof y&&typeof w=="function"&&w instanceof w)&&(m=!1)}return a.delete(e),a.delete(t),m}var JJ=XJ,QJ=Rc,eQ=ho,tQ=QJ(eQ,"DataView"),rQ=tQ,iQ=Rc,nQ=ho,aQ=iQ(nQ,"Promise"),sQ=aQ,oQ=Rc,lQ=ho,uQ=oQ(lQ,"Set"),cQ=uQ,dQ=Rc,hQ=ho,fQ=dQ(hQ,"WeakMap"),pQ=fQ,V2=rQ,q2=w4,G2=sQ,H2=cQ,Y2=pQ,GA=fo,Wh=AA,FT="[object Map]",mQ="[object Object]",zT="[object Promise]",NT="[object Set]",BT="[object WeakMap]",jT="[object DataView]",gQ=Wh(V2),_Q=Wh(q2),yQ=Wh(G2),vQ=Wh(H2),bQ=Wh(Y2),Eu=GA;(V2&&Eu(new V2(new ArrayBuffer(1)))!=jT||q2&&Eu(new q2)!=FT||G2&&Eu(G2.resolve())!=zT||H2&&Eu(new H2)!=NT||Y2&&Eu(new Y2)!=BT)&&(Eu=function(e){var t=GA(e),r=t==mQ?e.constructor:void 0,i=r?Wh(r):"";if(i)switch(i){case gQ:return jT;case _Q:return FT;case yQ:return zT;case vQ:return NT;case bQ:return BT}return t});var xQ=Eu,jv=E4,wQ=jA,$Q=mX,SQ=JJ,UT=xQ,VT=Is,qT=gh,TQ=P4,CQ=1,GT="[object Arguments]",HT="[object Array]",Vg="[object Object]",kQ=Object.prototype,YT=kQ.hasOwnProperty;function EQ(e,t,r,i,n,a){var s=VT(e),o=VT(t),l=s?HT:UT(e),u=o?HT:UT(t);l=l==GT?Vg:l,u=u==GT?Vg:u;var c=l==Vg,d=u==Vg,h=l==u;if(h&&qT(e)){if(!qT(t))return!1;s=!0,c=!1}if(h&&!c)return a||(a=new jv),s||TQ(e)?wQ(e,t,r,i,n,a):$Q(e,t,l,r,i,n,a);if(!(r&CQ)){var f=c&&YT.call(e,"__wrapped__"),p=d&&YT.call(t,"__wrapped__");
41if(f||p){var m=f?e.value():e,g=p?t.value():t;return a||(a=new jv),n(m,g,r,i,a)}}return h?(a||(a=new jv),SQ(e,t,r,i,n,a)):!1}var PQ=EQ,MQ=PQ,WT=As;function HA(e,t,r,i,n){return e===t?!0:e==null||t==null||!WT(e)&&!WT(t)?e!==e&&t!==t:MQ(e,t,r,i,HA,n)}var YA=HA,IQ=E4,AQ=YA,DQ=1,RQ=2;function OQ(e,t,r,i){var n=r.length,a=n,s=!i;if(e==null)return!a;for(e=Object(e);n--;){var o=r[n];if(s&&o[2]?o[1]!==e[o[0]]:!(o[0]in e))return!1}for(;++n<a;){o=r[n];var l=o[0],u=e[l],c=o[1];if(s&&o[2]){if(u===void 0&&!(l in e))return!1}else{var d=new IQ;if(i)var h=i(u,c,l,e,t,d);if(!(h===void 0?AQ(c,u,DQ|RQ,i,d):h))return!1}}return!0}var LQ=OQ,FQ=ml;function zQ(e){return e===e&&!FQ(e)}var WA=zQ,NQ=WA,BQ=I4;function jQ(e){for(var t=BQ(e),r=t.length;r--;){var i=t[r],n=e[i];t[r]=[i,n,NQ(n)]}return t}var UQ=jQ;function VQ(e,t){return function(r){return r==null?!1:r[e]===t&&(t!==void 0||e in Object(r))}}var ZA=VQ,qQ=LQ,GQ=UQ,HQ=ZA;function YQ(e){var t=GQ(e);return t.length==1&&t[0][2]?HQ(t[0][0],t[0][1]):function(r){return r===e||qQ(r,e,t)}}var WQ=YQ,ZQ=OA,KQ=E1;function XQ(e,t){t=ZQ(t,e);for(var r=0,i=t.length;e!=null&&r<i;)e=e[KQ(t[r++])];return r&&r==i?e:void 0}var KA=XQ,JQ=KA;function QQ(e,t,r){var i=e==null?void 0:JQ(e,t);return i===void 0?r:i}var zu=QQ;function eee(e,t){return e!=null&&t in Object(e)}var tee=eee,ree=tee,iee=FA;function nee(e,t){return e!=null&&iee(e,t,ree)}var aee=nee,see=YA,oee=zu,lee=aee,uee=x4,cee=WA,dee=ZA,hee=E1,fee=1,pee=2;function mee(e,t){return uee(e)&&cee(t)?dee(hee(e),t):function(r){var i=oee(r,e);return i===void 0&&i===t?lee(r,e):see(t,i,fee|pee)}}var gee=mee;function _ee(e){return e}var A4=_ee;function yee(e){return function(t){return t==null?void 0:t[e]}}var vee=yee,bee=KA;function xee(e){return function(t){return bee(t,e)}}var wee=xee,$ee=vee,See=wee,Tee=x4,Cee=E1;function kee(e){return Tee(e)?$ee(Cee(e)):See(e)}var Eee=kee,Pee=WQ,Mee=gee,Iee=A4,Aee=Is,Dee=Eee;function Ree(e){return typeof e=="function"?e:e==null?Iee:typeof e=="object"?Aee(e)?Mee(e[0],e[1]):Pee(e):Dee(e)}var XA=Ree;function Oee(e){return function(t,r,i){for(var n=-1,a=Object(t),s=i(t),o=s.length;o--;){var l=s[e?o:++n];if(r(a[l],l,a)===!1)break}return t}}var Lee=Oee,Fee=Lee,zee=Fee(),JA=zee,Nee=JA,Bee=I4;function jee(e,t){return e&&Nee(e,t,Bee)}var QA=jee,Uee=Qm;function Vee(e,t){return function(r,i){if(r==null)return r;if(!Uee(r))return e(r,i);for(var n=r.length,a=t?n:-1,s=Object(r);(t?a--:++a<n)&&i(s[a],a,s)!==!1;);return r}}var qee=Vee,Gee=QA,Hee=qee,Yee=Hee(Gee),Wee=Yee,Zee=Wee;function Kee(e,t){var r;return Zee(e,function(i,n,a){return r=t(i,n,a),!r}),!!r}var Xee=Kee,Jee=qh,Qee=Qm,ete=C4,tte=ml;function rte(e,t,r){if(!tte(r))return!1;var i=typeof t;return(i=="number"?Qee(r)&&ete(t,r.length):i=="string"&&t in r)?Jee(r[t],e):!1}var D4=rte,ite=BA,nte=XA,ate=Xee,ste=Is,ote=D4;function lte(e,t,r){var i=ste(e)?ite:ate;return r&&ote(e,t,r)&&(t=void 0),i(e,nte(t))}var ute=lte,cte=fo,dte=As,hte="[object Boolean]";function fte(e){return e===!0||e===!1||dte(e)&&cte(e)==hte}var pte=fte,mte=fo,gte=As,_te="[object Number]";function yte(e){return typeof e=="number"||gte(e)&&mte(e)==_te}var Es=yte,vte=Rc,bte=(function(){try{var e=vte(Object,"defineProperty");return e({},"",{}),e}catch{}})(),e9=bte,ZT=e9;function xte(e,t,r){t=="__proto__"&&ZT?ZT(e,t,{configurable:!0,enumerable:!0,value:r,writable:!0}):e[t]=r}var P1=xte,wte=P1,$te=qh,Ste=Object.prototype,Tte=Ste.hasOwnProperty;function Cte(e,t,r){var i=e[t];(!(Tte.call(e,t)&&$te(i,r))||r===void 0&&!(t in e))&&wte(e,t,r)}var kte=Cte,Ete=P1,Pte=QA,Mte=XA;function Ite(e,t){var r={};return t=Mte(t),Pte(e,function(i,n,a){Ete(r,n,t(i,n,a))}),r}var Ate=Ite;function Dte(e,t,r){switch(r.length){case 0:return e.call(t);case 1:return e.call(t,r[0]);case 2:return e.call(t,r[0],r[1]);case 3:return e.call(t,r[0],r[1],r[2])}return e.apply(t,r)}var t9=Dte,Rte=t9,KT=Math.max;function Ote(e,t,r){return t=KT(t===void 0?e.length-1:t,0),function(){for(var i=arguments,n=-1,a=KT(i.length-t,0),s=Array(a);++n<a;)s[n]=i[t+n];n=-1;for(var o=Array(t+1);++n<t;)o[n]=i[n];return o[t]=r(s),Rte(e,this,o)}}var Lte=Ote;function Fte(e){return function(){return e}}var zte=Fte,Nte=zte,XT=e9,Bte=A4,jte=XT?function(e,t){return XT(e,"toString",{configurable:!0,enumerable:!1,value:Nte(t),writable:!0})}:Bte,Ute=jte,Vte=800,qte=16,Gte=Date.now;function Hte(e){var t=0,r=0;return function(){var i=Gte(),n=qte-(i-r);if(r=i,n>0){if(++t>=Vte)return arguments[0]}else t=0;return e.apply(void 0,arguments)}}var Yte=Hte,Wte=Ute,Zte=Yte,Kte=Zte(Wte),Xte=Kte,Jte=A4,Qte=Lte,ere=Xte;function tre(e,t){return ere(Qte(e,t,Jte),e+"")}var R4=tre;function rre(e){var t=[];if(e!=null)for(var r in Object(e))t.push(r);return t}var ire=rre,nre=ml,are=M4,sre=ire,ore=Object.prototype,lre=ore.hasOwnProperty;function ure(e){if(!nre(e))return sre(e);var t=are(e),r=[];for(var i in e)i=="constructor"&&(t||!lre.call(e,i))||r.push(i);return r}var cre=ure,dre=VA,hre=cre,fre=Qm;function pre(e){return fre(e)?dre(e,!0):hre(e)}var O4=pre,mre=R4,gre=qh,_re=D4,yre=O4,r9=Object.prototype,vre=r9.hasOwnProperty,bre=mre(function(e,t){e=Object(e);var r=-1,i=t.length,n=i>2?t[2]:void 0;for(n&&_re(t[0],t[1],n)&&(i=1);++r<i;)for(var a=t[r],s=yre(a),o=-1,l=s.length;++o<l;){var u=s[o],c=e[u];(c===void 0||gre(c,r9[u])&&!vre.call(e,u))&&(e[u]=a[u])}return e}),JT=bre,xre=P1,wre=qh;function $re(e,t,r){(r!==void 0&&!wre(e[t],r)||r===void 0&&!(t in e))&&xre(e,t,r)}var i9=$re,K_={},Sre={get exports(){return K_},set exports(e){K_=e}};(function(e,t){var r=ho,i=t&&!t.nodeType&&t,n=i&&!0&&e&&!e.nodeType&&e,a=n&&n.exports===i,s=a?r.Buffer:void 0,o=s?s.allocUnsafe:void 0;function l(u,c){if(c)return u.slice();var d=u.length,h=o?o(d):new u.constructor(d);return u.copy(h),h}e.exports=l})(Sre,K_);var QT=UA;function Tre(e){var t=new e.constructor(e.byteLength);return new QT(t).set(new QT(e)),t}var Cre=Tre,kre=Cre;function Ere(e,t){var r=t?kre(e.buffer):e.buffer;return new e.constructor(r,e.byteOffset,e.length)}var Pre=Ere;function Mre(e,t){var r=-1,i=e.length;for(t||(t=Array(i));++r<i;)t[r]=e[r];return t}var Ire=Mre,Are=ml,e6=Object.create,Dre=(function(){function e(){}return function(t){if(!Are(t))return{};if(e6)return e6(t);e.prototype=t;var r=new e;return e.prototype=void 0,r}})(),Rre=Dre,Ore=qA,Lre=Ore(Object.getPrototypeOf,Object),n9=Lre,Fre=Rre,zre=n9,Nre=M4;function Bre(e){return typeof e.constructor=="function"&&!Nre(e)?Fre(zre(e)):{}}var jre=Bre,Ure=Qm,Vre=As;function qre(e){return Vre(e)&&Ure(e)}var Gre=qre,Hre=fo,Yre=n9,Wre=As,Zre="[object Object]",Kre=Function.prototype,Xre=Object.prototype,a9=Kre.toString,Jre=Xre.hasOwnProperty,Qre=a9.call(Object);function eie(e){if(!Wre(e)||Hre(e)!=Zre)return!1;var t=Yre(e);
41if(t===null)return!0;var r=Jre.call(t,"constructor")&&t.constructor;return typeof r=="function"&&r instanceof r&&a9.call(r)==Qre}var tie=eie;function rie(e,t){if(!(t==="constructor"&&typeof e[t]=="function")&&t!="__proto__")return e[t]}var s9=rie,iie=kte,nie=P1;function aie(e,t,r,i){var n=!r;r||(r={});for(var a=-1,s=t.length;++a<s;){var o=t[a],l=i?i(r[o],e[o],o,r,e):void 0;l===void 0&&(l=e[o]),n?nie(r,o,l):iie(r,o,l)}return r}var sie=aie,oie=sie,lie=O4;function uie(e){return oie(e,lie(e))}var cie=uie,t6=i9,die=K_,hie=Pre,fie=Ire,pie=jre,r6=T4,i6=Is,mie=Gre,gie=gh,_ie=Dc,yie=ml,vie=tie,bie=P4,n6=s9,xie=cie;function wie(e,t,r,i,n,a,s){var o=n6(e,r),l=n6(t,r),u=s.get(l);if(u){t6(e,r,u);return}var c=a?a(o,l,r+"",e,t,s):void 0,d=c===void 0;if(d){var h=i6(l),f=!h&&gie(l),p=!h&&!f&&bie(l);c=l,h||f||p?i6(o)?c=o:mie(o)?c=fie(o):f?(d=!1,c=die(l,!0)):p?(d=!1,c=hie(l,!0)):c=[]:vie(l)||r6(l)?(c=o,r6(o)?c=xie(o):(!yie(o)||_ie(o))&&(c=pie(l))):d=!1}d&&(s.set(l,c),n(c,l,i,a,s),s.delete(l)),t6(e,r,c)}var $ie=wie,Sie=E4,Tie=i9,Cie=JA,kie=$ie,Eie=ml,Pie=O4,Mie=s9;function o9(e,t,r,i,n){e!==t&&Cie(t,function(a,s){if(n||(n=new Sie),Eie(a))kie(e,t,s,r,o9,i,n);else{var o=i?i(Mie(e,s),a,s+"",e,t,n):void 0;o===void 0&&(o=a),Tie(e,s,o)}},Pie)}var l9=o9,Iie=l9,a6=ml;function u9(e,t,r,i,n,a){return a6(e)&&a6(t)&&(a.set(t,e),Iie(e,t,void 0,u9,a),a.delete(t)),e}var Aie=u9,Die=R4,Rie=D4;function Oie(e){return Die(function(t,r){var i=-1,n=r.length,a=n>1?r[n-1]:void 0,s=n>2?r[2]:void 0;for(a=e.length>3&&typeof a=="function"?(n--,a):void 0,s&&Rie(r[0],r[1],s)&&(a=n<3?void 0:a,n=1),t=Object(t);++i<n;){var o=r[i];o&&e(t,o,i,a)}return t})}var Lie=Oie,Fie=l9,zie=Lie,Nie=zie(function(e,t,r,i){Fie(e,t,r,i)}),Bie=Nie,jie=t9,Uie=R4,Vie=Aie,qie=Bie,Gie=Uie(function(e){return e.push(void 0,Vie),jie(qie,void 0,e)}),_h=Gie;function Hie(e){return e&&e.length?e[0]:void 0}var c9=Hie;function Yie(e){var t=e==null?0:e.length;return t?e[t-1]:void 0}var vd=Yie;const Wie=e=>Object.prototype.toString.call(e).slice(8,-1),Nd=e=>eK(e)&&!isNaN(e.getTime()),il=e=>Wie(e)==="Object",d9=zA,s6=(e,t)=>ute(t,r=>zA(e,r)),ir=(e,t,r="0")=>{for(e=e!=null?String(e):"",t=t||2;e.length<t;)e=`${r}${e}`;return e},es=e=>Array.isArray(e),Oo=e=>es(e)&&e.length>0,X_=e=>e==null?null:document&&Zs(e)?document.querySelector(e):e.$el??e,Ol=(e,t,r,i=void 0)=>{e.removeEventListener(t,r,i)},Ll=(e,t,r,i=void 0)=>(e.addEventListener(t,r,i),()=>Ol(e,t,r,i)),H0=(e,t)=>!!e&&!!t&&(e===t||e.contains(t)),qg=(e,t)=>{(e.key===" "||e.key==="Enter")&&(t(e),e.preventDefault())},h9=(e,...t)=>{const r={};let i;for(i in e)t.includes(i)||(r[i]=e[i]);return r},f9=(e,t)=>{const r={};return t.forEach(i=>{i in e&&(r[i]=e[i])}),r};function Zie(e,t,r){return Math.min(Math.max(e,t),r)}var J_={},Kie={get exports(){return J_},set exports(e){J_=e}};(function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.default=r;function r(i){if(i===null||i===!0||i===!1)return NaN;var n=Number(i);return isNaN(n)?n:n<0?Math.ceil(n):Math.floor(n)}e.exports=t.default})(Kie,J_);const Xie=PA(J_);var Q_={},Jie={get exports(){return Q_},set exports(e){Q_=e}};(function(e,t){Object.defineProperty(t,"__esModule",{value:!0}),t.default=r;function r(i){var n=new Date(Date.UTC(i.getFullYear(),i.getMonth(),i.getDate(),i.getHours(),i.getMinutes(),i.getSeconds(),i.getMilliseconds()));return n.setUTCFullYear(i.getFullYear()),i.getTime()-n.getTime()}e.exports=t.default})(Jie,Q_);const o6=PA(Q_);function Qie(e,t){var r=ine(t);return r.formatToParts?tne(r,e):rne(r,e)}var ene={year:0,month:1,day:2,hour:3,minute:4,second:5};function tne(e,t){try{for(var r=e.formatToParts(t),i=[],n=0;n<r.length;n++){var a=ene[r[n].type];a>=0&&(i[a]=parseInt(r[n].value,10))}return i}catch(s){if(s instanceof RangeError)return[NaN];throw s}}function rne(e,t){var r=e.format(t).replace(/\u200E/g,""),i=/(\d+)\/(\d+)\/(\d+),? (\d+):(\d+):(\d+)/.exec(r);return[i[3],i[1],i[2],i[4],i[5],i[6]]}var Uv={};function ine(e){if(!Uv[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")),r=t==="06/25/2014, 00:00:00"||t==="â06â/â25â/â2014â â00â:â00â:â00";
41Uv[e]=r?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 Uv[e]}function p9(e,t,r,i,n,a,s){var o=new Date(0);return o.setUTCFullYear(e,t,r),o.setUTCHours(i,n,a,s),o}var l6=36e5,nne=6e4,Vv={timezoneZ:/^(Z)$/,timezoneHH:/^([+-]\d{2})$/,timezoneHHMM:/^([+-]\d{2}):?(\d{2})$/};function ane(e,t,r){var i,n;if(!e||(i=Vv.timezoneZ.exec(e),i))return 0;var a;if(i=Vv.timezoneHH.exec(e),i)return a=parseInt(i[1],10),u6(a)?-(a*l6):NaN;if(i=Vv.timezoneHHMM.exec(e),i){a=parseInt(i[1],10);var s=parseInt(i[2],10);return u6(a,s)?(n=Math.abs(a)*l6+s*nne,a>0?-n:n):NaN}if(lne(e)){t=new Date(t||Date.now());var o=sne(t),l=W2(o,e),u=one(t,l,e);return-u}return NaN}function sne(e){return p9(e.getFullYear(),e.getMonth(),e.getDate(),e.getHours(),e.getMinutes(),e.getSeconds(),e.getMilliseconds())}function W2(e,t){var r=Qie(e,t),i=p9(r[0],r[1]-1,r[2],r[3]%24,r[4],r[5],0).getTime(),n=e.getTime(),a=n%1e3;return n-=a>=0?a:1e3+a,i-n}function one(e,t,r){var i=e.getTime(),n=i-t,a=W2(new Date(n),r);if(t===a)return t;n-=a-t;var s=W2(new Date(n),r);return a===s?a:Math.max(a,s)}function u6(e,t){return-23<=e&&e<=23&&(t==null||0<=t&&t<=59)}var c6={};function lne(e){if(c6[e])return!0;try{return new Intl.DateTimeFormat(void 0,{timeZone:e}),c6[e]=!0,!0}catch{return!1}}var une=/(Z|[+-]\d{2}(?::?\d{2})?| UTC| [a-zA-Z]+\/[a-zA-Z_]+(?:\/[a-zA-Z_]+)?)$/;const cne=une;var qv=36e5,d6=6e4,dne=2,En={dateTimePattern:/^([0-9W+-]+)(T| )(.*)/,datePattern:/^([0-9W+-]+)(.*)/,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:cne};function hne(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 r=t||{},i=r.additionalDigits==null?dne:Xie(r.additionalDigits);if(i!==2&&i!==1&&i!==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 n=fne(e),a=pne(n.date,i),s=a.year,o=a.restDateString,l=mne(o,s);if(isNaN(l))return new Date(NaN);if(l){var u=l.getTime(),c=0,d;if(n.time&&(c=gne(n.time),isNaN(c)))return new Date(NaN);if(n.timeZone||r.timeZone){if(d=ane(n.timeZone||r.timeZone,new Date(u+c)),isNaN(d))return new Date(NaN)}else d=o6(new Date(u+c)),d=o6(new Date(u+c+d));return new Date(u+c+d)}else return new Date(NaN)}function fne(e){var t={},r=En.dateTimePattern.exec(e),i;if(r?(t.date=r[1],i=r[3]):(r=En.datePattern.exec(e),r?(t.date=r[1],i=r[2]):(t.date=null,i=e)),i){var n=En.timeZone.exec(i);n?(t.time=i.replace(n[1],""),t.timeZone=n[1].trim()):t.time=i}return t}function pne(e,t){var r=En.YYY[t],i=En.YYYYY[t],n;if(n=En.YYYY.exec(e)||i.exec(e),n){var a=n[1];return{year:parseInt(a,10),restDateString:e.slice(a.length)}}if(n=En.YY.exec(e)||r.exec(e),n){var s=n[1];return{year:parseInt(s,10)*100,restDateString:e.slice(s.length)}}return{year:null}}function mne(e,t){if(t===null)return null;var r,i,n,a;if(e.length===0)return i=new Date(0),i.setUTCFullYear(t),i;if(r=En.MM.exec(e),r)return i=new Date(0),n=parseInt(r[1],10)-1,f6(t,n)?(i.setUTCFullYear(t,n),i):new Date(NaN);if(r=En.DDD.exec(e),r){i=new Date(0);var s=parseInt(r[1],10);return vne(t,s)?(i.setUTCFullYear(t,0,s),i):new Date(NaN)}if(r=En.MMDD.exec(e),r){i=new Date(0),n=parseInt(r[1],10)-1;var o=parseInt(r[2],10);return f6(t,n,o)?(i.setUTCFullYear(t,n,o),i):new Date(NaN)}if(r=En.Www.exec(e),r)return a=parseInt(r[1],10)-1,p6(t,a)?h6(t,a):new Date(NaN);if(r=En.WwwD.exec(e),r){a=parseInt(r[1],10)-1;var l=parseInt(r[2],10)-1;return p6(t,a,l)?h6(t,a,l):new Date(NaN)}return null}function gne(e){var t,r,i;if(t=En.HH.exec(e),t)return r=parseFloat(t[1].replace(",",".")),Gv(r)?r%24*qv:NaN;if(t=En.HHMM.exec(e),t)return r=parseInt(t[1],10),i=parseFloat(t[2].replace(",",".")),Gv(r,i)?r%24*qv+i*d6:NaN;if(t=En.HHMMSS.exec(e),t){r=parseInt(t[1],10),i=parseInt(t[2],10);var n=parseFloat(t[3].replace(",","."));return Gv(r,i,n)?r%24*qv+i*d6+n*1e3:NaN}return null}
41function h6(e,t,r){t=t||0,r=r||0;var i=new Date(0);i.setUTCFullYear(e,0,4);var n=i.getUTCDay()||7,a=t*7+r+1-n;return i.setUTCDate(i.getUTCDate()+a),i}var _ne=[31,28,31,30,31,30,31,31,30,31,30,31],yne=[31,29,31,30,31,30,31,31,30,31,30,31];function m9(e){return e%400===0||e%4===0&&e%100!==0}function f6(e,t,r){if(t<0||t>11)return!1;if(r!=null){if(r<1)return!1;var i=m9(e);if(i&&r>yne[t]||!i&&r>_ne[t])return!1}return!0}function vne(e,t){if(t<1)return!1;var r=m9(e);return!(r&&t>366||!r&&t>365)}function p6(e,t,r){return!(t<0||t>52||r!=null&&(r<0||r>6))}function Gv(e,t,r){return!(e!=null&&(e<0||e>=25)||t!=null&&(t<0||t>=60)||r!=null&&(r<0||r>=60))}function gn(e,t){if(t.length<e)throw new TypeError(e+" argument"+(e>1?"s":"")+" required, but only "+t.length+" present")}function Y0(e){"@babel/helpers - typeof";return typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?Y0=function(r){return typeof r}:Y0=function(r){return r&&typeof Symbol=="function"&&r.constructor===Symbol&&r!==Symbol.prototype?"symbol":typeof r},Y0(e)}function gl(e){gn(1,arguments);var t=Object.prototype.toString.call(e);return e instanceof Date||Y0(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 Zh(e){if(e===null||e===!0||e===!1)return NaN;var t=Number(e);return isNaN(t)?t:t<0?Math.ceil(t):Math.floor(t)}var bne={};function L4(){return bne}function bc(e,t){var r,i,n,a,s,o,l,u;gn(1,arguments);var c=L4(),d=Zh((r=(i=(n=(a=t==null?void 0:t.weekStartsOn)!==null&&a!==void 0?a:t==null||(s=t.locale)===null||s===void 0||(o=s.options)===null||o===void 0?void 0:o.weekStartsOn)!==null&&n!==void 0?n:c.weekStartsOn)!==null&&i!==void 0?i:(l=c.locale)===null||l===void 0||(u=l.options)===null||u===void 0?void 0:u.weekStartsOn)!==null&&r!==void 0?r:0);if(!(d>=0&&d<=6))throw new RangeError("weekStartsOn must be between 0 and 6 inclusively");var h=gl(e),f=h.getDay(),p=(f<d?7:0)+f-d;return h.setDate(h.getDate()-p),h.setHours(0,0,0,0),h}function m6(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()}var xne=6048e5;function wne(e,t,r){gn(2,arguments);var i=bc(e,r),n=bc(t,r),a=i.getTime()-m6(i),s=n.getTime()-m6(n);return Math.round((a-s)/xne)}function $ne(e){gn(1,arguments);var t=gl(e),r=t.getMonth();return t.setFullYear(t.getFullYear(),r+1,0),t.setHours(0,0,0,0),t}function Sne(e){gn(1,arguments);var t=gl(e);return t.setDate(1),t.setHours(0,0,0,0),t}function Tne(e,t){return gn(1,arguments),wne($ne(e),Sne(e),t)+1}function Cne(e,t){var r,i,n,a,s,o,l,u;gn(1,arguments);var c=gl(e),d=c.getFullYear(),h=L4(),f=Zh((r=(i=(n=(a=t==null?void 0:t.firstWeekContainsDate)!==null&&a!==void 0?a:t==null||(s=t.locale)===null||s===void 0||(o=s.options)===null||o===void 0?void 0:o.firstWeekContainsDate)!==null&&n!==void 0?n:h.firstWeekContainsDate)!==null&&i!==void 0?i:(l=h.locale)===null||l===void 0||(u=l.options)===null||u===void 0?void 0:u.firstWeekContainsDate)!==null&&r!==void 0?r:1);if(!(f>=1&&f<=7))throw new RangeError("firstWeekContainsDate must be between 1 and 7 inclusively");var p=new Date(0);p.setFullYear(d+1,0,f),p.setHours(0,0,0,0);var m=bc(p,t),g=new Date(0);g.setFullYear(d,0,f),g.setHours(0,0,0,0);var v=bc(g,t);return c.getTime()>=m.getTime()?d+1:c.getTime()>=v.getTime()?d:d-1}function kne(e,t){var r,i,n,a,s,o,l,u;gn(1,arguments);var c=L4(),d=Zh((r=(i=(n=(a=t==null?void 0:t.firstWeekContainsDate)!==null&&a!==void 0?a:t==null||(s=t.locale)===null||s===void 0||(o=s.options)===null||o===void 0?void 0:o.firstWeekContainsDate)!==null&&n!==void 0?n:c.firstWeekContainsDate)!==null&&i!==void 0?i:(l=c.locale)===null||l===void 0||(u=l.options)===null||u===void 0?void 0:u.firstWeekContainsDate)!==null&&r!==void 0?r:1),h=Cne(e,t),f=new Date(0);f.setFullYear(h,0,d),f.setHours(0,0,0,0);var p=bc(f,t);return p}var Ene=6048e5;function Pne(e,t){gn(1,arguments);var r=gl(e),i=bc(r,t).getTime()-kne(r,t).getTime();return Math.round(i/Ene)+1}function ey(e){return gn(1,arguments),bc(e,{weekStartsOn:1}
41)}function Mne(e){gn(1,arguments);var t=gl(e),r=t.getFullYear(),i=new Date(0);i.setFullYear(r+1,0,4),i.setHours(0,0,0,0);var n=ey(i),a=new Date(0);a.setFullYear(r,0,4),a.setHours(0,0,0,0);var s=ey(a);return t.getTime()>=n.getTime()?r+1:t.getTime()>=s.getTime()?r:r-1}function Ine(e){gn(1,arguments);var t=Mne(e),r=new Date(0);r.setFullYear(t,0,4),r.setHours(0,0,0,0);var i=ey(r);return i}var Ane=6048e5;function Dne(e){gn(1,arguments);var t=gl(e),r=ey(t).getTime()-Ine(t).getTime();return Math.round(r/Ane)+1}function Cn(e,t){gn(2,arguments);var r=gl(e),i=Zh(t);return isNaN(i)?new Date(NaN):(i&&r.setDate(r.getDate()+i),r)}function ty(e,t){gn(2,arguments);var r=gl(e),i=Zh(t);if(isNaN(i))return new Date(NaN);if(!i)return r;var n=r.getDate(),a=new Date(r.getTime());a.setMonth(r.getMonth()+i+1,0);var s=a.getDate();return n>=s?a:(r.setFullYear(a.getFullYear(),a.getMonth(),n),r)}function g6(e,t){gn(2,arguments);var r=Zh(t);return ty(e,r*12)}const Rne={daily:["year","month","day"],weekly:["year","month","week"],monthly:["year","month"]};function One({monthComps:e,prevMonthComps:t,nextMonthComps:r},i){const n=[],{firstDayOfWeek:a,firstWeekday:s,isoWeeknumbers:o,weeknumbers:l,numDays:u,numWeeks:c}=e,d=s+(s<a?Qi:0)-a;let h=!0,f=!1,p=!1,m=0;const g=new Intl.DateTimeFormat(i.id,{weekday:"long",year:"numeric",month:"short",day:"numeric"});let v=t.numDays-d+1,x=t.numDays-v+1,_=Math.floor((v-1)/Qi+1),y=1,w=t.numWeeks,$=1,S=t.month,E=t.year;const C=new Date,I=C.getDate(),P=C.getMonth()+1,T=C.getFullYear();for(let D=1;D<=Eae;D++){for(let A=1,z=a;A<=Qi;A++,z+=z===Qi?1-Qi:1){h&&z===s&&(v=1,x=e.numDays,_=Math.floor((v-1)/Qi+1),y=Math.floor((u-v)/Qi+1),w=1,$=c,S=e.month,E=e.year,h=!1,f=!0);const R=i.getDateFromParams(E,S,v,0,0,0,0),O=i.getDateFromParams(E,S,v,12,0,0,0),V=i.getDateFromParams(E,S,v,23,59,59,999),Y=R,F=`${ir(E,4)}-${ir(S,2)}-${ir(v,2)}`,ae=A,ue=Qi-A,Z=l[D-1],K=o[D-1],fe=v===I&&S===P&&E===T,ve=f&&v===1,$e=f&&v===u,Re=D===1,Oe=D===c,ze=A===1,Be=A===Qi,qe=k9(E,S,v);n.push({locale:i,id:F,position:++m,label:v.toString(),ariaLabel:g.format(new Date(E,S-1,v)),day:v,dayFromEnd:x,weekday:z,weekdayPosition:ae,weekdayPositionFromEnd:ue,weekdayOrdinal:_,weekdayOrdinalFromEnd:y,week:w,weekFromEnd:$,weekPosition:D,weeknumber:Z,isoWeeknumber:K,month:S,year:E,date:Y,startDate:R,endDate:V,noonDate:O,dayIndex:qe,isToday:fe,isFirstDay:ve,isLastDay:$e,isDisabled:!f,isFocusable:!f,isFocused:!1,inMonth:f,inPrevMonth:h,inNextMonth:p,onTop:Re,onBottom:Oe,onLeft:ze,onRight:Be,classes:[`id-${F}`,`day-${v}`,`day-from-end-${x}`,`weekday-${z}`,`weekday-position-${ae}`,`weekday-ordinal-${_}`,`weekday-ordinal-from-end-${y}`,`week-${w}`,`week-from-end-${$}`,{"is-today":fe,"is-first-day":ve,"is-last-day":$e,"in-month":f,"in-prev-month":h,"in-next-month":p,"on-top":Re,"on-bottom":Oe,"on-left":ze,"on-right":Be}]}),f&&$e?(f=!1,p=!0,v=1,x=u,_=1,y=Math.floor((u-v)/Qi+1),w=1,$=r.numWeeks,S=r.month,E=r.year):(v++,x--,_=Math.floor((v-1)/Qi+1),y=Math.floor((u-v)/Qi+1))}w++,$--}return n}function Lne(e,t,r,i){const n=e.reduce((a,s,o)=>{const l=Math.floor(o/7);let u=a[l];return u||(u={id:`week-${l+1}`,title:"",week:s.week,weekPosition:s.weekPosition,weeknumber:s.weeknumber,isoWeeknumber:s.isoWeeknumber,weeknumberDis
41play:t?s.weeknumber:r?s.isoWeeknumber:void 0,days:[]},a[l]=u),u.days.push(s),a},Array(e.length/Qi));return n.forEach(a=>{const s=a.days[0],o=a.days[a.days.length-1];s.month===o.month?a.title=`${i.formatDate(s.date,"MMMM YYYY")}`:s.year===o.year?a.title=`${i.formatDate(s.date,"MMM")} - ${i.formatDate(o.date,"MMM YYYY")}`:a.title=`${i.formatDate(s.date,"MMM YYYY")} - ${i.formatDate(o.date,"MMM YYYY")}`}),n}function Fne(e,t){return e.days.map(r=>({label:t.formatDate(r.date,t.masks.weekdays),weekday:r.weekday}))}function zne(e,t){return`${t}.${ir(e,2)}`}function g9(e,t,r){return f9(r.getDateParts(r.toDate(e)),Rne[t])}function _9({day:e,week:t,month:r,year:i},n,a,s){if(a==="daily"&&e){const o=new Date(i,r-1,e),l=Cn(o,n);return{day:l.getDate(),month:l.getMonth()+1,year:l.getFullYear()}}else if(a==="weekly"&&t){const l=s.getMonthParts(r,i).firstDayOfMonth,u=Cn(l,(t-1+n)*7),c=s.getDateParts(u);return{week:c.week,month:c.month,year:c.year}}else{const o=new Date(i,r-1,1),l=ty(o,n);return{month:l.getMonth()+1,year:l.getFullYear()}}}function Ks(e){return e!=null&&e.month!=null&&e.year!=null}function Z2(e,t){return!Ks(e)||!Ks(t)?!1:(e=e,t=t,e.year!==t.year?e.year<t.year:e.month&&t.month&&e.month!==t.month?e.month<t.month:e.week&&t.week&&e.week!==t.week?e.week<t.week:e.day&&t.day&&e.day!==t.day?e.day<t.day:!1)}function ry(e,t){return!Ks(e)||!Ks(t)?!1:(e=e,t=t,e.year!==t.year?e.year>t.year:e.month&&t.month&&e.month!==t.month?e.month>t.month:e.week&&t.week&&e.week!==t.week?e.week>t.week:e.day&&t.day&&e.day!==t.day?e.day>t.day:!1)}function Nne(e,t,r){return(e||!1)&&!Z2(e,t)&&!ry(e,r)}function Bne(e,t){return!e&&t||e&&!t?!1:!e&&!t?!0:(e=e,t=t,e.year===t.year&&e.month===t.month&&e.week===t.week&&e.day===t.day)}function jne(e,t,r,i){if(!Ks(e)||!Ks(t))return[];const n=[];for(;!ry(e,t);)n.push(e),e=_9(e,1,r,i);return n}function y9(e){const{day:t,week:r,month:i,year:n}=e;let a=`${n}-${ir(i,2)}`;return r&&(a=`${a}-w${r}`),t&&(a=`${a}-${ir(t,2)}`),a}function Une(e,t){const{month:r,year:i,showWeeknumbers:n,showIsoWeeknumbers:a}=e,s=new Date(i,r-1,15),o=t.getMonthParts(r,i),l=t.getPrevMonthParts(r,i),u=t.getNextMonthParts(r,i),c=One({monthComps:o,prevMonthComps:l,nextMonthComps:u},t),d=Lne(c,n,a,t),h=Fne(d[0],t);return{id:y9(e),month:r,year:i,monthTitle:t.formatDate(s,t.masks.title),shortMonthLabel:t.formatDate(s,"MMM"),monthLabel:t.formatDate(s,"MMMM"),shortYearLabel:i.toString().substring(2),yearLabel:i.toString(),monthComps:o,prevMonthComps:l,nextMonthComps:u,days:c,weeks:d,weekdays:h}}function Vne(e,t){const{day:r,week:i,view:n,trimWeeks:a}=e,s={...t,...e,title:"",viewDays:[],viewWeeks:[]};switch(n){case"daily":{let o=s.days.find(u=>u.inMonth);r?o=s.days.find(u=>u.day===r&&u.inMonth)||o:i&&(o=s.days.find(u=>u.week===i&&u.inMonth));const l=s.weeks[o.week-1];s.viewWeeks=[l],s.viewDays=[o],s.week=o.week,s.weekTitle=l.title,s.day=o.day,s.dayTitle=o.ariaLabel,s.title=s.dayTitle;break}case"weekly":{s.week=i||1;const o=s.weeks[s.week-1];s.viewWeeks=[o],s.viewDays=o.days,s.weekTitle=o.title,s.title=s.weekTitle;break}default:{s.title=s.monthTitle,s.viewWeeks=s.weeks.slice(0,a?s.monthComps.numWeeks:void 0),s.viewDays=s.days;break}}return s}class _6{constructor(t,r,i){Xe(this,"keys",[]),Xe(this,"store",{}),this.size=t,this.createKey=r,this.createItem=i}get(...t){const r=this.createKey(...t);return this.store[r]}getOrSet(...t){const r=this.createKey(...t);if(this.store[r])return this.store[r];const i=this.createItem(...t);if(this.keys.length>=this.size){const n=this.keys.shift();n!=null&&delete this.store[n]}return this.keys.push(r),this.store[r]=i,i}}class Bd{constructor(t,r=new iy){Xe(this,"order"),Xe(this,"locale"),Xe(this,"start",null),Xe(this,"end",null),Xe(this,"repeat",null);var i;this.locale=r;const{start:n,end:a,span:s,order:o,repeat:l}=t;Nd(n)&&(this.start=r.getDateParts(n)),Nd(a)?this.end=r.getDateParts(a):this.start!=null&&s&&(this.end=r.getDateParts(Cn(this.start.date,s-1))),this.order=o??0,l&&(this.repeat=new ny({from:(i=this.start)==null?void 0:i.date,...l},{locale:this.locale}))}static fromMany(t,r){return(es(t)?t:[t]).filter(i=>i).map(i=>Bd.from(i,r))}static from(t,r){if(t instanceof Bd)return t;const i={start:null,end:null};return t!=null&&(es(t)?(i.start=t[0]??null,i.end=t[1]??null):il(t)?Object.assign(i,t):(i.start=t,i.end=t)),i.start!=null&&(i.start=new Date(i.start)),i.end!=null&&(i.end=new Date(i.end)),new Bd(i,r)}get opts(){const{order:t,locale:r}=this;return{order:t,locale:r}}get hasRepeat(){return!!this.repeat}get isSingleDay(){const{start:t,end:r}=this;return t&&r&&t.year===r.year&&t.month===r.month&&t.day===r.day}get isMultiDay(){return!this.isSingleDay}get daySpan(){return this.start==null||this.end==null?this.hasRepeat?1:1/0:this.end.dayIndex-this.start.dayIndex}startsOnDay(t){var r,i;return((r=this.start)==null?void 0:r.dayIndex)===t.dayIndex||!!((i=this.repeat)!=null&&i.passes(t))}intersectsDay(t){return this.intersectsDayRange(t,t)}intersectsRange(t){var r,i;
41return this.intersectsDayRange(((r=t.start)==null?void 0:r.dayIndex)??-1/0,((i=t.end)==null?void 0:i.dayIndex)??1/0)}intersectsDayRange(t,r){return!(this.start&&this.start.dayIndex>r||this.end&&this.end.dayIndex<t)}}class qne{constructor(){Xe(this,"records",{})}render(t,r,i){var n,a,s,o;let l=null;const u=i[0].dayIndex,c=i[i.length-1].dayIndex;return r.hasRepeat?i.forEach(d=>{var h,f;if(r.startsOnDay(d)){const p=r.daySpan<1/0?r.daySpan:1;l={startDay:d.dayIndex,startTime:((h=r.start)==null?void 0:h.time)??0,endDay:d.dayIndex+p-1,endTime:((f=r.end)==null?void 0:f.time)??W0},this.getRangeRecords(t).push(l)}}):r.intersectsDayRange(u,c)&&(l={startDay:((n=r.start)==null?void 0:n.dayIndex)??-1/0,startTime:((a=r.start)==null?void 0:a.time)??-1/0,endDay:((s=r.end)==null?void 0:s.dayIndex)??1/0,endTime:((o=r.end)==null?void 0:o.time)??1/0},this.getRangeRecords(t).push(l)),l}getRangeRecords(t){let r=this.records[t.key];return r||(r={ranges:[],data:t},this.records[t.key]=r),r.ranges}getCell(t,r){return this.getCells(r).find(a=>a.data.key===t)}cellExists(t,r){const i=this.records[t];return i==null?!1:i.ranges.some(n=>n.startDay<=r&&n.endDay>=r)}getCells(t){const r=Object.values(this.records),i=[],{dayIndex:n}=t;return r.forEach(({data:a,ranges:s})=>{s.filter(o=>o.startDay<=n&&o.endDay>=n).forEach(o=>{const l=n===o.startDay,u=n===o.endDay,c=l?o.startTime:0,d=new Date(t.startDate.getTime()+c),h=u?o.endTime:W0,f=new Date(t.endDate.getTime()+h),p=c===0&&h===W0,m=a.order||0;i.push({...o,data:a,onStart:l,onEnd:u,startTime:c,startDate:d,endTime:h,endDate:f,allDay:p,order:m})})}),i.sort((a,s)=>a.order-s.order),i}}const nl={ar:{dow:7,L:"D/âM/âYYYY"},bg:{dow:2,L:"D.MM.YYYY"},ca:{dow:2,L:"DD/MM/YYYY"},"zh-CN":{dow:2,L:"YYYY/MM/DD"},"zh-TW":{dow:1,L:"YYYY/MM/DD"},hr:{dow:2,L:"DD.MM.YYYY"},cs:{dow:2,L:"DD.MM.YYYY"},da:{dow:2,L:"DD.MM.YYYY"},nl:{dow:2,L:"DD-MM-YYYY"},"en-US":{dow:1,L:"MM/DD/YYYY"},"en-AU":{dow:2,L:"DD/MM/YYYY"},"en-CA":{dow:1,L:"YYYY-MM-DD"},"en-GB":{dow:2,L:"DD/MM/YYYY"},"en-IE":{dow:2,L:"DD-MM-YYYY"},"en-NZ":{dow:2,L:"DD/MM/YYYY"},"en-ZA":{dow:1,L:"YYYY/MM/DD"},eo:{dow:2,L:"YYYY-MM-DD"},et:{dow:2,L:"DD.MM.YYYY"},fi:{dow:2,L:"DD.MM.YYYY"},fr:{dow:2,L:"DD/MM/YYYY"},"fr-CA":{dow:1,L:"YYYY-MM-DD"},"fr-CH":{dow:2,L:"DD.MM.YYYY"},de:{dow:2,L:"DD.MM.YYYY"},he:{dow:1,L:"DD.MM.YYYY"},id:{dow:2,L:"DD/MM/YYYY"},it:{dow:2,L:"DD/MM/YYYY"},ja:{dow:1,L:"YYYYå¹´MæDæ¥"},ko:{dow:1,L:"YYYY.MM.DD"},lv:{dow:2,L:"DD.MM.YYYY"},lt:{dow:2,L:"DD.MM.YYYY"},mk:{dow:2,L:"D.MM.YYYY"},nb:{dow:2,L:"D. MMMM YYYY"},nn:{dow:2,L:"D. MMMM YYYY"}
41,pl:{dow:2,L:"DD.MM.YYYY"},pt:{dow:2,L:"DD/MM/YYYY"},ro:{dow:2,L:"DD.MM.YYYY"},ru:{dow:2,L:"DD.MM.YYYY"},sk:{dow:2,L:"DD.MM.YYYY"},"es-ES":{dow:2,L:"DD/MM/YYYY"},"es-MX":{dow:2,L:"DD/MM/YYYY"},sv:{dow:2,L:"YYYY-MM-DD"},th:{dow:1,L:"DD/MM/YYYY"},tr:{dow:2,L:"DD.MM.YYYY"},uk:{dow:2,L:"DD.MM.YYYY"},vi:{dow:2,L:"DD/MM/YYYY"}};nl.en=nl["en-US"];nl.es=nl["es-ES"];nl.no=nl.nb;nl.zh=nl["zh-CN"];const Gne=Object.entries(nl).reduce((e,[t,{dow:r,L:i}])=>(e[t]={id:t,firstDayOfWeek:r,masks:{L:i}},e),{}),Hne="MMMM YYYY",Yne="W",Wne="MMM",Zne="h A",Kne=["L","YYYY-MM-DD","YYYY/MM/DD"],Xne=["L h:mm A","YYYY-MM-DD h:mm A","YYYY/MM/DD h:mm A"],Jne=["L HH:mm","YYYY-MM-DD HH:mm","YYYY/MM/DD HH:mm"],Qne=["h:mm A"],eae=["HH:mm"],tae="WWW, MMM D, YYYY",rae=["L","YYYY-MM-DD","YYYY/MM/DD"],iae="iso",nae="YYYY-MM-DDTHH:mm:ss.SSSZ",aae={title:Hne,weekdays:Yne,navMonths:Wne,hours:Zne,input:Kne,inputDateTime:Xne,inputDateTime24hr:Jne,inputTime:Qne,inputTime24hr:eae,dayPopover:tae,data:rae,model:iae,iso:nae},sae=300,oae=60,lae=80,uae={maxSwipeTime:sae,minHorizontalSwipeDistance:oae,maxVerticalSwipeDistance:lae},cae={componentPrefix:"V",color:"blue",isDark:!1,navVisibility:"click",titlePosition:"center",transition:"slide-h",touch:uae,masks:aae,locales:Gne,datePicker:{updateOnInput:!0,inputDebounce:1e3,popover:{visibility:"hover-focus",placement:"bottom-start",isInteractive:!0}}},jd=An(cae),dae=H(()=>Ate(jd.locales,e=>(e.masks=_h(e.masks,jd.masks),e))),iu=e=>typeof window<"u"&&d9(window.__vcalendar__,e)?zu(window.__vcalendar__,e):zu(jd,e),hae=(e,t)=>(e.config.globalProperties.$VCalendar=jd,Object.assign(jd,_h(t,jd))),fae=12,pae=5;function mae(e,t){const r=new Intl.DateTimeFormat().resolvedOptions().locale;let i;Zs(e)?i=e:d9(e,"id")&&(i=e.id),i=(i||r).toLowerCase();const n=Object.keys(t),a=l=>n.find(u=>u.toLowerCase()===l);i=a(i)||a(i.substring(0,2))||r;const s={...t["en-IE"],...t[i],id:i,monthCacheSize:fae,pageCacheSize:pae};return il(e)?_h(e,s):s}class iy{constructor(t=void 0,r){Xe(this,"id"),Xe(this,"daysInWeek"),Xe(this,"firstDayOfWeek"),Xe(this,"masks"),Xe(this,"timezone"),Xe(this,"hourLabels"),Xe(this,"dayNames"),Xe(this,"dayNamesShort"),Xe(this,"dayNamesShorter"),Xe(this,"dayNamesNarrow"),Xe(this,"monthNames"),Xe(this,"monthNamesShort"),Xe(this,"relativeTimeNames"),Xe(this,"amPm",["am","pm"]),Xe(this,"monthCache"),Xe(this,"pageCache");const{id:i,firstDayOfWeek:n,masks:a,monthCacheSize:s,pageCacheSize:o}=mae(t,dae.value);this.monthCache=new _6(s,Fae,zae),this.pageCache=new _6(o,y9,Une),this.id=i,this.daysInWeek=Qi,this.firstDayOfWeek=Zie(n,1,Qi),this.masks=a,this.timezone=r||void 0,this.hourLabels=this.getHourLabels(),this.dayNames=Hv("long",this.id),this.dayNamesShort=Hv("short",this.id),this.dayNamesShorter=this.dayNamesShort.map(l=>l.substring(0,2)),this.dayNamesNarrow=Hv("narrow",this.id),this.monthNames=$6("long",this.id),this.monthNamesShort=$6("short",this.id),this.relativeTimeNames=jae(this.id)}formatDate(t,r){return Hae(t,r,this)}parseDate(t,r){return S6(t,r,this)}toDate(t,r={}){const i=new Date(NaN);let n=i;const{fillDate:a,mask:s,patch:o,rules:l}=r;if(Es(t)?(r.type="number",n=new Date(+t)):Zs(t)?(r.type="string",n=t?S6(t,s||"iso",this):i):Nd(t)?(r.type="date",n=new Date(t.getTime())):F4(t)&&(r.type="object",n=this.getDateFromParts(t)),n&&(o||l)){let u=this.getDateParts(n);if(o&&a!=null){const c=this.getDateParts(this.toDate(a));u=this.getDateParts(this.toDate({...c,...f9(u,kae[o])}))}l&&(u=Gae(u,l)),n=this.getDateFromParts(u)}return n||i}toDateOrNull(t,r={}){const i=this.toDate(t,r);return isNaN(i.getTime())?null:i}fromDate(t,{type:r,mask:i}={}){switch(r){case"number":return t?t.getTime():NaN;case"string":return t?this.formatDate(t,i||"iso"):"";case"object":return t?this.getDateParts(t):null;default:return t?new Date(t):null}}range(t){return Bd.from(t,this)}ranges(t){return Bd.fromMany(t,this)}getDateParts(t){return Lae(t,this)}getDateFromParts(t){return P9(t,this.timezone)}getDateFromParams(t,r,i,n,a,s,o){return this.getDateFromParts({year:t,month:r,day:i,hours:n,minutes:a,seconds:s,milliseconds:o})}getPage(t){const r=this.pageCache.getOrSet(t,this);return Vne(t,r)}getMonthParts(t,r){const{firstDayOfWeek:i}=this;return this.monthCache.getOrSet(t,r,i)}getThisMonthParts(){const t=new Date;return this.getMonthParts(t.getMonth()+1,t.getFullYear())}getPrevMonthParts(t,r){return t===1?this.getMonthParts(12,r-1):this.getMonthParts(t-1,r)}getNextMonthParts(t,r){return t===12?this.getMonthParts(1,r+1):this.getMonthParts(t+1,r)}getHourLabels(){return Bae().map(t=>this.formatDate(t,this.masks.hours))}getDayId(t){return this.formatDate(t,"YYYY-MM-DD")}}var sd=(e=>(e.Any="any",e.All="all",e))(sd||{}),v9=(e=>(e.Days="days",e.Weeks="weeks",e.Months="months",e.Years="years",e))(v9||{}),b9=(e=>(e.Days="days",e.Weekdays="weekdays",e.Weeks="weeks",e.Months="months",e.Years="years",e))(b9||{}),x9=(e=>(e.OrdinalWeekdays="ordinalWeekdays",e))(x9||{});class gae{constructor(t,r,i){Xe(this,"validated",!0),this.type=t,this.interval=r,this.from=i,this.from||(console.error('A valid "from" date is required for date interval rule. This rule will be skipped.'),this.validated=!1)}passes(t){if(!this.validated)return!0;const{date:r}=t;switch(this.type){case"days":return z4(this.from.date,r)%this.interval===0;case"weeks":return Rae(this.from.date,r)%this.interval===0;case"months":return Oae(this.from.date,r)%this.interval===0;case"years":return E9(this.from.date,r)%this.interval===0;default:return!1}}}class Kh{constructor(t,r,i,n){Xe(this,"components",[]),this.type=t,this.validator=i,this.getter=n,this.components=this.normalizeComponents(r)}static create(t,r){switch(t){case"days":return new _ae(r);case"weekdays":return new yae(r);case"weeks":return new vae(r);case"months":return new bae(r);case"years":return new xae(r)}}normalizeComponents(t){if(this.validator(t))return[t];if(!es(t))return[];const r=[];return t.forEach(i=>
41{if(!this.validator(i)){console.error(`Component value ${i} in invalid for "${this.type}" rule. This rule will be skipped.`);return}r.push(i)}),r}passes(t){return this.getter(t).some(n=>this.components.includes(n))}}class _ae extends Kh{constructor(t){super("days",t,Sae,({day:r,dayFromEnd:i})=>[r,-i])}}class yae extends Kh{constructor(t){super("weekdays",t,K2,({weekday:r})=>[r])}}class vae extends Kh{constructor(t){super("weeks",t,Tae,({week:r,weekFromEnd:i})=>[r,-i])}}class bae extends Kh{constructor(t){super("months",t,Cae,({month:r})=>[r])}}class xae extends Kh{constructor(t){super("years",t,Es,({year:r})=>[r])}}class wae{constructor(t,r){Xe(this,"components"),this.type=t,this.components=this.normalizeComponents(r)}normalizeArrayConfig(t){const r=[];return t.forEach((i,n)=>{if(Es(i)){if(n===0)return;if(!y6(t[0])){console.error(`Ordinal range for "${this.type}" rule is from -5 to -1 or 1 to 5. This rule will be skipped.`);return}if(!K2(i)){console.error(`Acceptable range for "${this.type}" rule is from 1 to 5. This rule will be skipped`);return}r.push([t[0],i])}else es(i)&&r.push(...this.normalizeArrayConfig(i))}),r}normalizeComponents(t){const r=[];return t.forEach((i,n)=>{if(Es(i)){if(n===0)return;if(!y6(t[0])){console.error(`Ordinal range for "${this.type}" rule is from -5 to -1 or 1 to 5. This rule will be skipped.`);return}if(!K2(i)){console.error(`Acceptable range for "${this.type}" rule is from 1 to 5. This rule will be skipped`);return}r.push([t[0],i])}else es(i)&&r.push(...this.normalizeArrayConfig(i))}),r}passes(t){const{weekday:r,weekdayOrdinal:i,weekdayOrdinalFromEnd:n}=t;return this.components.some(([a,s])=>(a===i||a===-n)&&r===s)}}class $ae{constructor(t){Xe(this,"type","function"),Xe(this,"validated",!0),this.fn=t,Dc(t)||(console.error("The function rule requires a valid function. This rule will be skipped."),this.validated=!1)}passes(t){return this.validated?this.fn(t):!0}}class ny{constructor(t,r={},i){Xe(this,"validated",!0),Xe(this,"config"),Xe(this,"type",sd.Any),Xe(this,"from"),Xe(this,"until"),Xe(this,"rules",[]),Xe(this,"locale",new iy),this.parent=i,r.locale&&(this.locale=r.locale),this.config=t,Dc(t)?(this.type=sd.All,this.rules=[new $ae(t)]):es(t)?(this.type=sd.Any,this.rules=t.map(n=>new ny(n,r,this))):il(t)?(this.type=sd.All,this.from=t.from?this.locale.getDateParts(t.from):i==null?void 0:i.from,this.until=t.until?this.locale.getDateParts(t.until):i==null?void 0:i.until,this.rules=this.getObjectRules(t)):(console.error("Rule group configuration must be an object or an array."),this.validated=!1)}getObjectRules(t){const r=[];if(t.every&&(Zs(t.every)&&(t.every=[1,`${t.every}s`]),es(t.every))){const[i=1,n=v9.Days]=t.every;r.push(new gae(n,i,this.from))}return Object.values(b9).forEach(i=>{i in t&&r.push(Kh.create(i,t[i]))}),Object.values(x9).forEach(i=>{i in t&&r.push(new wae(i,t[i]))}),t.on!=null&&(es(t.on)||(t.on=[t.on]),r.push(new ny(t.on,{locale:this.locale},this.parent))),r}passes(t){return this.validated?this.from&&t.dayIndex<=this.from.dayIndex||this.until&&t.dayIndex>=this.until.dayIndex?!1:this.type===sd.Any?this.rules.some(r=>r.passes(t)):this.rules.every(r=>r.passes(t)):!0}}function Sae(e){return Es(e)?e>=1&&e<=31:!1}function K2(e){return Es(e)?e>=1&&e<=7:!1}function Tae(e){return Es(e)?e>=-6&&e<=-1||e>=1&&e<=6:!1}function Cae(e){return Es(e)?e>=1&&e<=12:!1}function y6(e){return!(!Es(e)||e<-5||e>5||e===0)}const kae={dateTime:["year","month","day","hours","minutes","seconds","milliseconds"],date:["year","month","day"],time:["hours","minutes","seconds","milliseconds"]},Qi=7,Eae=6,w9=1e3,$9=w9*60,S9=$9*60,W0=S9*24,Pae=[31,28,31,30,31,30,31,31,30,31,30,31],Mae=["L","iso"],Bf={milliseconds:[0,999,3],seconds:[0,59,2],minutes:[0,59,2],hours:[0,23,2]},T9=/d{1,2}|W{1,4}|M{1,4}|YY(?:YY)?|S{1,3}|Do|Z{1,4}|([HhMsDm])\1?|[aA]|"[^"]*"|'[^']*'/g,Iae=/\[([^]*?)\]/gm,v6={D(e){return e.day},DD(e){return ir(e.day,2)},d(e){return e.weekday-1},dd(e){return ir(e.weekday-1,2)},W(e,t){return t.dayNamesNarrow[e.weekday-1]},WW(e,t){return t.dayNamesShorter[e.weekday-1]},WWW(e,t){return t.dayNamesShort[e.weekday-1]},WWWW(e,t){return t.dayNames[e.weekday-1]},M(e){return e.month},MM(e){return ir(e.month,2)},MMM(e,t){return t.monthNamesShort[e.month-1]},MMMM(e,t){return t.monthNames[e.month-1]},YY(e){return String(e.year).substr(2)},YYYY(e){return ir(e.year,4)},h(e){return e.hours%12||12},hh(e){return ir(e.hours%12||12,2)},H(e){return e.hours},HH(e){return ir(e.hours,2)},m(e){return e.minutes},mm(e){return ir(e.minutes,2)},s(e){return e.seconds},ss(e){return ir(e.seconds,2)},S(e){return Math.round(e.milliseconds/100)},SS(e){return ir(Math.round(e.milliseconds/10),2)},SSS(e){return ir(e.milliseconds,3)},a(e,t){return e.hours<12?t.amPm[0]:t.amPm[1]},A(e,t){return e.hours<12?t.amPm[0].toUpperCase():t.amPm[1].toUpperCase()},Z(){return"Z"},ZZ(e){const t=e.timezoneOffset;return`${t>0?"-":"+"}${ir(Math.floor(Math.abs(t)/60),2)}`},ZZZ(e){const t=e.timezoneOffset;return`${t>0?"-":"+"}${ir(Math.floor(Math.abs(t)/60)*100+Math.abs(t)%60,4)}`},ZZZZ(e){const t=e.timezoneOffset;return`${t>0?"-":"+"}${ir(Math.floor(Math.abs(t)/60),2)}:${ir(Math.abs(t)%60,2)}`}},xl=/\d\d?/,Aae=/\d{3}/,Dae=/\d{4}/,mf=/[0-9]*['a-z\u00A0-\u05FF\u0700-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF]+|[\u0600-\u06FF/]+(\s*?[\u0600-\u06FF]+){1,2}/i,b6=()=>{},x6=e=>(t,r,i)=>{const n=i[e].indexOf(r.charAt(0).toUpperCase()+r.substr(1).toLowerCase());~n&&(t.month=n)},hr={D:[xl,(e,t)=>{e.day=t}],Do:[new RegExp(xl.source+mf.source),(e,t)=>{e.day=parseInt(t,10)}],d:[xl,b6],W:[mf,b6],M:[xl,(e,t)=>{e.month=t-1}],MMM:[mf,x6("monthNamesShort")],MMMM:[mf,x6("monthNames")],YY:[xl,(e,t)=>{const i=+new Date().getFullYear().toString().substr(0,2);e.year=+`${t>68?i-1:i}${t}`}],YYYY:[Dae,(e,t)=>{e.year=t}],S:[/\d/,(e,t)=>{e.milliseconds=t*100}],SS:[/\d{2}/,(e,t)=>{e.milliseconds=t*10}],SSS:[Aae,(e,t)=>{e.milliseconds=t}],h:[xl,(e,t)=>{e.hours=t}],m:[xl,(e,t)=>{e.minutes=t}],s:[xl,(e,t)=>{e.seconds=t}],a:[mf,(e,t,r)=>{const i=t.toLowerCase();i===r.amPm[0]?e.isPm=!1:i===r.amPm[1]&&(e.isPm=!0)}],Z:[/[^\s]*?[+-]\d\d:?\d\d|[^\s]*?Z?/,(e,t)=>{t==="Z"&&(t="+00:00");const r=`${t}`.match(/([+-]|\d\d)/gi);if(r){const i=+r[1]*60+parseInt(r[2],10);
41e.timezoneOffset=r[0]==="+"?i:-i}}]};hr.DD=hr.D;hr.dd=hr.d;hr.WWWW=hr.WWW=hr.WW=hr.W;hr.MM=hr.M;hr.mm=hr.m;hr.hh=hr.H=hr.HH=hr.h;hr.ss=hr.s;hr.A=hr.a;hr.ZZZZ=hr.ZZZ=hr.ZZ=hr.Z;function C9(e,t){return(Oo(e)&&e||[Zs(e)&&e||"YYYY-MM-DD"]).map(r=>Mae.reduce((i,n)=>i.replace(n,t.masks[n]||""),r))}function F4(e){return il(e)&&"year"in e&&"month"in e&&"day"in e}function w6(e,t=1){const r=e.getDay()+1,i=r>=t?t-r:-(7-(t-r));return Cn(e,i)}function k9(e,t,r){const i=Date.UTC(e,t-1,r);return z4(new Date(0),new Date(i))}function z4(e,t){return Math.round((t.getTime()-e.getTime())/W0)}function Rae(e,t){return Math.ceil(z4(w6(e),w6(t))/7)}function E9(e,t){return t.getUTCFullYear()-e.getUTCFullYear()}function Oae(e,t){return E9(e,t)*12+(t.getMonth()-e.getMonth())}function P9(e,t=""){const r=new Date,{year:i=r.getFullYear(),month:n=r.getMonth()+1,day:a=r.getDate(),hours:s=0,minutes:o=0,seconds:l=0,milliseconds:u=0}=e;if(t){const c=`${ir(i,4)}-${ir(n,2)}-${ir(a,2)}T${ir(s,2)}:${ir(o,2)}:${ir(l,2)}.${ir(u,3)}`;return hne(c,{timeZone:t})}return new Date(i,n-1,a,s,o,l,u)}function Lae(e,t){let r=new Date(e.getTime());t.timezone&&(r=new Date(e.toLocaleString("en-US",{timeZone:t.timezone})),r.setMilliseconds(e.getMilliseconds()));const i=r.getMilliseconds(),n=r.getSeconds(),a=r.getMinutes(),s=r.getHours(),o=i+n*w9+a*$9+s*S9,l=r.getMonth()+1,u=r.getFullYear(),c=t.getMonthParts(l,u),d=r.getDate(),h=c.numDays-d+1,f=r.getDay()+1,p=Math.floor((d-1)/7+1),m=Math.floor((c.numDays-d)/7+1),g=Math.ceil((d+Math.abs(c.firstWeekday-c.firstDayOfWeek))/7),v=c.numWeeks-g+1,x=c.weeknumbers[g],_=k9(u,l,d);return{milliseconds:i,seconds:n,minutes:a,hours:s,time:o,day:d,dayFromEnd:h,weekday:f,weekdayOrdinal:p,weekdayOrdinalFromEnd:m,week:g,weekFromEnd:v,weeknumber:x,month:l,year:u,date:r,dateTime:r.getTime(),dayIndex:_,timezoneOffset:0,isValid:!0}}function Fae(e,t,r){return`${t}-${e}-${r}`}function zae(e,t,r){const i=t%4===0&&t%100!==0||t%400===0,n=new Date(t,e-1,1),a=n.getDay()+1,s=e===2&&i?29:Pae[e-1],o=r-1,l=Tne(n,{weekStartsOn:o}),u=[],c=[];for(let d=0;d<l;d++){const h=Cn(n,d*7);u.push(Pne(h,{weekStartsOn:o})),c.push(Dne(h))}return{firstDayOfWeek:r,firstDayOfMonth:n,inLeapYear:i,firstWeekday:a,numDays:s,numWeeks:l,month:e,year:t,weeknumbers:u,isoWeeknumbers:c}}function Nae(){const e=[];for(let n=0;n<Qi;n++)e.push(P9({year:2020,month:1,day:5+n,hours:12}));return e}function Hv(e,t=void 0){const r=new Intl.DateTimeFormat(t,{weekday:e});return Nae().map(i=>r.format(i))}function Bae(){const e=[];for(let t=0;t<=24;t++)e.push(new Date(2e3,0,1,t));return e}function jae(e=void 0){const t=["second","minute","hour","day","week","month","quarter","year"],r=new Intl.RelativeTimeFormat(e);return t.reduce((i,n)=>{const a=r.formatToParts(100,n);return i[n]=a[1].unit,i},{})}function M9(){const e=[];for(let t=0;t<12;t++)e.push(new Date(2e3,t,15));return e}function $6(e,t=void 0){const r=new Intl.DateTimeFormat(t,{month:e,timeZone:"UTC"});return M9().map(i=>r.format(i))}function Uae(e,t,r){return Es(t)?t===e:es(t)?t.includes(e):Dc(t)?t(e,r):!(t.min!=null&&t.min>e||t.max!=null&&t.max<e||t.interval!=null&&e%t.interval!==0)}function jf(e,t,r){const i=[],[n,a,s]=t;for(let o=n;o<=a;o++)(r==null||Uae(o,r,e))&&i.push({value:o,label:ir(o,s)});return i}function Vae(e,t){return{milliseconds:jf(e,Bf.milliseconds,t.milliseconds),seconds:jf(e,Bf.seconds,t.seconds),minutes:jf(e,Bf.minutes,t.minutes),hours:jf(e,Bf.hours,t.hours)}}function qae(e,t,r,i){const a=jf(e,t,i).reduce((s,o)=>{if(o.disabled)return s;if(isNaN(s))return o.value;const l=Math.abs(s-r);return Math.abs(o.value-r)<l?o.value:s},NaN);return isNaN(a)?r:a}function Gae(e,t){const r={...e};return Object.entries(t).forEach(([i,n])=>{const a=Bf[i],s=e[i];r[i]=qae(e,a,s,n)}),r}function S6(e,t,r){return C9(t,r).map(n=>{if(typeof n!="string")throw new Error("Invalid mask");let a=e;if(a.length>1e3)return!1;let s=!0;const o={};if(n.replace(T9,c=>{if(hr[c]){const d=hr[c],h=a.search(d[0]);~h?a.replace(d[0],f=>(d[1](o,f,r),a=a.substr(h+f.length),f)):s=!1}return hr[c]?"":c.slice(1,c.length-1)}),!s)return!1;const l=new Date;o.hours!=null&&(o.isPm===!0&&+o.hours!=12?o.hours=+o.hours+12:o.isPm===!1&&+o.hours==12&&(o.hours=0));let u;return o.timezoneOffset!=null?(o.minutes=+(o.minutes||0)-+o.timezoneOffset,u=new Date(Date.UTC(o.year||l.getFullYear(),o.month||0,o.day||1,o.hours||0,o.minutes||0,o.seconds||0,o.milliseconds||0))):u=r.getDateFromParts({year:o.year||l.getFullYear(),month:(o.month||0)+1,day:o.day||1,hours:o.hours||0,minutes:o.minutes||0,seconds:o.seconds||0,milliseconds:o.milliseconds||0}),u}).find(n=>n)||new Date(e)}function Hae(e,t,r){if(e==null)return"";let i=C9(t,r)[0];/Z$/.test(i)&&(r.timezone="utc");const n=[];i=i.replace(Iae,(s,o)=>(n.push(o),"??"));const a=r.getDateParts(e);return i=i.replace(T9,s=>s in v6?v6[s](a,r):s.slice(1,s.length-1)),i.replace(/\?\?/g,()=>n.shift())}let Yae=0;class I9{constructor(t,r,i){Xe(this,"key",""),Xe(this,"hashcode",""),Xe(this,"highlight",null),Xe(this,"content",null),Xe(this,"dot",null),Xe(this,"bar",null),Xe(this,"event",null),Xe(this,"popover",null),Xe(this,"customData",null),Xe(this,"ranges"),Xe(this,"hasRanges",!1),Xe(this,"order",0),Xe(this,"pinPage",!1),Xe(this,"maxRepeatSpan",0),Xe(this,"locale");const{dates:n}=Object.assign(this,{hashcode:"",order:0,pinPage:!1},t);this.key||(this.key=++Yae),this.locale=i,r.normalizeGlyphs(this),this.ranges=i.ranges(n??[]),this.hasRanges=!!Oo(this.ranges),this.maxRepeatSpan=this.ranges.filter(a=>a.hasRepeat).map(a=>a.daySpan).reduce((a,s)=>Math.max(a,s),0)}intersectsRange({start:t,end:r}){if(t==null||r==null)return!1;const i=this.ranges.filter(s=>!s.hasRepeat);for(const s of i)if(s.intersectsDayRange(t.dayIndex,r.dayIndex))return!0;const n=this.ranges.filter(s=>s.hasRepeat);if(!n.length)return!1;let a=t;for(this.maxRepeatSpan>1&&(a=this.locale.getDateParts(Cn(a.date,-this.maxRepeatSpan)));a.dayIndex<=r.dayIndex;){for(const s of n)if(s.startsOnDay(a))return!0;a=this.locale.getDateParts(Cn(a.date,1))}return!1}}function X2(e){document&&document.dispatchEvent(new CustomEvent("show-popover",{detail:e}))}function nm(e){document&&document.dispatchEvent(new CustomEvent("hide-popover",{detail:e}))}function A9(e){document&&document.dispatchEvent(new CustomEvent("toggle-popover",{detail:e}))}function D9(e){const{visibility:t}=e,r=t==="click",i=t==="hover",n=t==="hover-focus",a=t==="focus";e.autoHide=!r;let s=!1,o=!1;const l=p=>{r&&(A9({...e,target:e.target||p.currentTarget}),p.stopPropagation())},u=p=>{s||(s=!0,(i||n)&&X2({...e,target:e.target||p.currentTarget}))},c=()=>{s&&(s=!1,(i||n&&!o)&&nm(e))},d=p=>{o||(o=!0,(a||n)&&X2({...e,target:e.target||p.currentTarget}))},h=p=>{o&&!H0(p.currentTarget,p.relatedTarget)&&(o=!1,(a||n&&!s)&&nm(e))},f={};switch(e.visibility){case"click":f.click=l;break;case"hover":f.mousemove=u,f.mouseleave=c;break;
41case"focus":f.focusin=d,f.focusout=h;break;case"hover-focus":f.mousemove=u,f.mouseleave=c,f.focusin=d,f.focusout=h;break}return f}const T6=e=>{const t=X_(e);if(t==null)return;const r=t.popoverHandlers;!r||!r.length||(r.forEach(i=>i()),delete t.popoverHandlers)},C6=(e,t)=>{const r=X_(e);if(r==null)return;const i=[],n=D9(t);Object.entries(n).forEach(([a,s])=>{i.push(Ll(r,a,s))}),r.popoverHandlers=i},R9={mounted(e,t){const{value:r}=t;r&&C6(e,r)},updated(e,t){const{oldValue:r,value:i}=t,n=r==null?void 0:r.visibility,a=i==null?void 0:i.visibility;n!==a&&(n&&(T6(e),a||nm(r)),a&&C6(e,i))},unmounted(e){T6(e)}},Wae=(e,t,{maxSwipeTime:r,minHorizontalSwipeDistance:i,maxVerticalSwipeDistance:n})=>{if(!e||!e.addEventListener||!Dc(t))return null;let a=0,s=0,o=null,l=!1;function u(d){const h=d.changedTouches[0];a=h.screenX,s=h.screenY,o=new Date().getTime(),l=!0}function c(d){if(!l||!o)return;l=!1;const h=d.changedTouches[0],f=h.screenX-a,p=h.screenY-s;if(new Date().getTime()-o<r&&Math.abs(f)>=i&&Math.abs(p)<=n){const g={toLeft:!1,toRight:!1};f<0?g.toLeft=!0:g.toRight=!0,t(g)}}return Ll(e,"touchstart",u,{passive:!0}),Ll(e,"touchend",c,{passive:!0}),()=>{Ol(e,"touchstart",u),Ol(e,"touchend",c)}},Z0={},Zae=(e,t=10)=>{Z0[e]=Date.now()+t},Kae=(e,t)=>{if(e in Z0){const r=Z0[e];if(Date.now()<r)return;delete Z0[e]}t()};function O9(){return typeof window<"u"}function Xae(e){return O9()&&e in window}function Jae(e){const t=se(!1),r=H(()=>t.value?"dark":"light");let i,n;function a(f){t.value=f.matches}function s(){Xae("matchMedia")&&(i=window.matchMedia("(prefers-color-scheme: dark)"),i.addEventListener("change",a),t.value=i.matches)}function o(){const{selector:f=":root",darkClass:p="dark"}=e.value,m=document.querySelector(f);t.value=m.classList.contains(p)}function l(f){const{selector:p=":root",darkClass:m="dark"}=f;if(O9()&&p&&m){const g=document.querySelector(p);g&&(n=new MutationObserver(o),n.observe(g,{attributes:!0,attributeFilter:["class"]}),t.value=g.classList.contains(m))}}function u(){d();const f=typeof e.value;f==="string"&&e.value.toLowerCase()==="system"?s():f==="object"?l(e.value):t.value=!!e.value}const c=tt(()=>e.value,()=>u(),{immediate:!0});function d(){i&&(i.removeEventListener("change",a),i=void 0),n&&(n.disconnect(),n=void 0)}function h(){d(),c()}return ss(()=>h()),{isDark:t,displayMode:r,cleanup:h}}const Qae=["base","start","end","startEnd"],ese=["class","wrapperClass","contentClass","style","contentStyle","color","fillMode"],tse={base:{},start:{},end:{}};function N4(e,t,r=tse){let i=e,n={};t===!0||Zs(t)?(i=Zs(t)?t:i,n={...r}):il(t)&&(s6(t,Qae)?n={...t}:n={base:{...t},start:{...t},end:{...t}});const a=_h(n,{start:n.startEnd,end:n.startEnd},r);return Object.entries(a).forEach(([s,o])=>{let l=i;o===!0||Zs(o)?(l=Zs(o)?o:l,a[s]={color:l}):il(o)&&(s6(o,ese)?a[s]={...o}:a[s]={}),_h(a[s],{color:l})}),a}class rse{constructor(){Xe(this,"type","highlight")}normalizeConfig(t,r){return N4(t,r,{base:{fillMode:"light"},start:{fillMode:"solid"},end:{fillMode:"solid"}})}prepareRender(t){t.highlights=[],t.content||(t.content=[])}render({data:t,onStart:r,onEnd:i},n){const{key:a,highlight:s}=t;if(!s)return;const{highlights:o}=n,{base:l,start:u,end:c}=s;r&&i?o.push({...u,key:a,wrapperClass:`vc-day-layer vc-day-box-center-center vc-attr vc-${u.color}`,class:[`vc-highlight vc-highlight-bg-${u.fillMode}`,u.class],contentClass:[`vc-attr vc-highlight-content-${u.fillMode} vc-${u.color}`,u.contentClass]}):r?(o.push({...l,key:`${a}-base`,wrapperClass:`vc-day-layer vc-day-box-right-center vc-attr vc-${l.color}`,class:[`vc-highlight vc-highlight-base-start vc-highlight-bg-${l.fillMode}`,l.class]}),o.push({...u,key:a,wrapperClass:`vc-day-layer vc-day-box-center-center vc-attr vc-${u.color}`,class:[`vc-highlight vc-highlight-bg-${u.fillMode}`,u.class],contentClass:[`vc-attr vc-highlight-content-${u.fillMode} vc-${u.color}`,u.contentClass]})):i?(o.push({...l,key:`${a}-base`,wrapperClass:`vc-day-layer vc-day-box-left-center vc-attr vc-${l.color}`,class:[`vc-highlight vc-highlight-base-end vc-highlight-bg-${l.fillMode}`,l.class]}),o.push({...c,key:a,wrapperClass:`vc-day-layer vc-day-box-center-center vc-attr vc-${c.color}`,class:[`vc-highlight vc-highlight-bg-${c.fillMode}`,c.class],contentClass:[`vc-attr vc-highlight-content-${c.fillMode} vc-${c.color}
41`,c.contentClass]})):o.push({...l,key:`${a}-middle`,wrapperClass:`vc-day-layer vc-day-box-center-center vc-attr vc-${l.color}`,class:[`vc-highlight vc-highlight-base-middle vc-highlight-bg-${l.fillMode}`,l.class],contentClass:[`vc-attr vc-highlight-content-${l.fillMode} vc-${l.color}`,l.contentClass]})}}class B4{constructor(t,r){Xe(this,"type",""),Xe(this,"collectionType",""),this.type=t,this.collectionType=r}normalizeConfig(t,r){return N4(t,r)}prepareRender(t){t[this.collectionType]=[]}render({data:t,onStart:r,onEnd:i},n){const{key:a}=t,s=t[this.type];if(!a||!s)return;const o=n[this.collectionType],{base:l,start:u,end:c}=s;r?o.push({...u,key:a,class:[`vc-${this.type} vc-${this.type}-start vc-${u.color} vc-attr`,u.class]}):i?o.push({...c,key:a,class:[`vc-${this.type} vc-${this.type}-end vc-${c.color} vc-attr`,c.class]}):o.push({...l,key:a,class:[`vc-${this.type} vc-${this.type}-base vc-${l.color} vc-attr`,l.class]})}}class ise extends B4{constructor(){super("content","content")}normalizeConfig(t,r){return N4("base",r)}}class nse extends B4{constructor(){super("dot","dots")}}class ase extends B4{constructor(){super("bar","bars")}}class sse{constructor(t){Xe(this,"color"),Xe(this,"renderers",[new ise,new rse,new nse,new ase]),this.color=t}normalizeGlyphs(t){this.renderers.forEach(r=>{const i=r.type;t[i]!=null&&(t[i]=r.normalizeConfig(this.color,t[i]))})}prepareRender(t={}){return this.renderers.forEach(r=>{r.prepareRender(t)}),t}render(t,r){this.renderers.forEach(i=>{i.render(t,r)})}}const L9=Symbol("__vc_base_context__"),F9={color:{type:String,default:()=>iu("color")},isDark:{type:[Boolean,String,Object],default:()=>iu("isDark")},firstDayOfWeek:Number,masks:Object,locale:[String,Object],timezone:String,minDate:null,maxDate:null,disabledDates:null};function z9(e){const t=H(()=>e.color??""),r=H(()=>e.isDark??!1),{displayMode:i}=Jae(r),n=H(()=>new sse(t.value)),a=H(()=>{if(e.locale instanceof iy)return e.locale;const h=il(e.locale)?e.locale:{id:e.locale,firstDayOfWeek:e.firstDayOfWeek,masks:e.masks};return new iy(h,e.timezone)}),s=H(()=>a.value.masks),o=H(()=>e.minDate),l=H(()=>e.maxDate),u=H(()=>{const h=e.disabledDates?[...e.disabledDates]:[];return o.value!=null&&h.push({start:null,end:Cn(a.value.toDate(o.value),-1)}),l.value!=null&&h.push({start:Cn(a.value.toDate(l.value),1),end:null}),a.value.ranges(h)}),c=H(()=>new I9({key:"disabled",dates:u.value,order:100},n.value,a.value)),d={color:t,isDark:r,displayMode:i,theme:n,locale:a,masks:s,minDate:o,maxDate:l,disabledDates:u,disabledAttribute:c};return xa(L9,d),d}function ose(e){return Gi(L9,()=>z9(e),!0)}function N9(e){return`__vc_slot_${e}__`}function B9(e,t={}){Object.keys(e).forEach(r=>{xa(N9(t[r]??r),e[r])})}function j9(e){return Gi(N9(e),null)}const lse={...F9,view:{type:String,default:"monthly",validator(e){return["daily","weekly","monthly"].includes(e)}},rows:{type:Number,default:1},columns:{type:Number,default:1},step:Number,titlePosition:{type:String,default:()=>iu("titlePosition")},navVisibility:{type:String,default:()=>iu("navVisibility")},showWeeknumbers:[Boolean,String],showIsoWeeknumbers:[Boolean,String],expanded:Boolean,borderless:Boolean,transparent:Boolean,initialPage:Object,initialPagePosition:{type:Number,default:1},minPage:Object,maxPage:Object,transition:String,attributes:Array,trimWeeks:Boolean,disablePageSwipe:Boolean},use=["dayclick","daymouseenter","daymouseleave","dayfocusin","dayfocusout","daykeydown","weeknumberclick","transition-start","transition-end","did-move","update:view","update:pages"],U9=Symbol("__vc_calendar_context__");function cse(e,{slots:t,emit:r}){const i=se(null),n=se(null),a=se(new Date().getDate()),s=se(!1),o=se(Symbol()),l=se(Symbol()),u=se(e.view),c=se([]),d=se("");let h=null,f=null;B9(t);const{theme:p,color:m,displayMode:g,locale:v,masks:x,minDate:_,maxDate:y,disabledAttribute:w,disabledDates:$}=ose(e),S=H(()=>e.rows*e.columns),E=H(()=>e.step||S.value),C=H(()=>c9(c.value)??null),I=H(()=>vd(c.value)??null),P=H(()=>e.minPage||(_.value?ue(_.value):null)),T=H(()=>e.maxPage||(y.value?ue(y.value):null)),D=H(()=>e.navVisibility),A=H(()=>!!e.showWeeknumbers),z=H(()=>!!e.showIsoWeeknumbers),R=H(()=>u.value==="monthly"),O=H(()=>u.value==="weekly"),V=H(()=>u.value==="daily"),Y=()=>{s.value=!0,r("transition-start")},F=()=>{s.value=!1,r("transition-end"),h&&(h.resolve(!0),h=null)},ae=(ge,B,re=u.value)=>_9(ge,B,re,v.value),ue=ge=>g9(ge,u.value,v.value),Z=ge=>{!w.value||!Oe.value||(ge.isDisabled=Oe.value.cellExists(w.value.key,ge.dayIndex))},K=ge=>{ge.isFocusable=ge.inMonth&&ge.day===a.value},fe=(ge,B)=>{for(const re of ge)for(const _e of re.days)if(B(_e)===!1)return},ve=H(()=>c.value.reduce((ge,B)=>(ge.push(...B.viewDays),ge),[])),$e=H(()=>{const ge=[];
41return(e.attributes||[]).forEach((B,re)=>{!B||!B.dates||ge.push(new I9({...B,order:B.order||0},p.value,v.value))}),w.value&&ge.push(w.value),ge}),Re=H(()=>Oo($e.value)),Oe=H(()=>{const ge=new qne;return $e.value.forEach(B=>{B.ranges.forEach(re=>{ge.render(B,re,ve.value)})}),ge}),ze=H(()=>ve.value.reduce((ge,B)=>(ge[B.dayIndex]={day:B,cells:[]},ge[B.dayIndex].cells.push(...Oe.value.getCells(B)),ge),{})),Be=(ge,B)=>{const re=e.showWeeknumbers||e.showIsoWeeknumbers;return re==null?"":pte(re)?re?"left":"":re.startsWith("right")?B>1?"right":re:ge>1?"left":re},qe=()=>{var ge,B;if(!Re.value)return null;const re=$e.value.find(Fe=>Fe.pinPage)||$e.value[0];if(!re||!re.hasRanges)return null;const[_e]=re.ranges,Ee=((ge=_e.start)==null?void 0:ge.date)||((B=_e.end)==null?void 0:B.date);return Ee?ue(Ee):null},j=()=>{if(Ks(C.value))return C.value;const ge=qe();return Ks(ge)?ge:ue(new Date)},W=(ge,B={})=>{const{view:re=u.value,position:_e=1,force:Ee}=B,Fe=_e>0?1-_e:-(S.value+_e);let ht=ae(ge,Fe,re),Et=ae(ht,S.value-1,re);return Ee||(Z2(ht,P.value)?ht=P.value:ry(Et,T.value)&&(ht=ae(T.value,1-S.value)),Et=ae(ht,S.value-1)),{fromPage:ht,toPage:Et}},G=(ge,B,re="")=>{if(re==="none"||re==="fade")return re;if((ge==null?void 0:ge.view)!==(B==null?void 0:B.view))return"fade";const _e=ry(B,ge),Ee=Z2(B,ge);return!_e&&!Ee?"fade":re==="slide-v"?Ee?"slide-down":"slide-up":Ee?"slide-right":"slide-left"},ie=(ge={})=>new Promise((B,re)=>{const{position:_e=1,force:Ee=!1,transition:Fe}=ge,ht=Ks(ge.page)?ge.page:j(),{fromPage:Et}=W(ht,{position:_e,force:Ee}),lr=[];for(let Br=0;Br<S.value;Br++){const ls=ae(Et,Br),Ke=Br+1,et=Math.ceil(Ke/e.columns),It=e.rows-et+1,Ie=Ke%e.columns||e.columns,st=e.columns-Ie+1,Qe=Be(Ie,st);lr.push(v.value.getPage({...ls,view:u.value,titlePosition:e.titlePosition,trimWeeks:e.trimWeeks,position:Ke,row:et,rowFromEnd:It,column:Ie,columnFromEnd:st,showWeeknumbers:A.value,showIsoWeeknumbers:z.value,weeknumberPosition:Qe}))}d.value=G(c.value[0],lr[0],Fe),c.value=lr,d.value&&d.value!=="none"?h={resolve:B,reject:re}:B(!0)}),U=ge=>{const B=C.value??ue(new Date);return ae(B,ge)},ne=(ge,B={})=>{const re=Ks(ge)?ge:ue(ge);return Object.assign(B,W(re,{...B,force:!0})),jne(B.fromPage,B.toPage,u.value,v.value).map(Ee=>Nne(Ee,P.value,T.value)).some(Ee=>Ee)},me=(ge,B={})=>ne(U(ge),B),J=H(()=>me(-E.value)),N=H(()=>me(E.value)),q=async(ge,B={})=>!B.force&&!ne(ge,B)?!1:(B.fromPage&&!Bne(B.fromPage,C.value)&&(nm({id:o.value,hideDelay:0}),B.view&&(Zae("view",10),u.value=B.view),await ie({...B,page:B.fromPage,position:1,force:!0}),r("did-move",c.value)),!0),te=(ge,B={})=>q(U(ge),B),ee=()=>te(-E.value),oe=()=>te(E.value),Se=ge=>{const B=R.value?".in-month":"",re=`.id-${v.value.getDayId(ge)}${B}`,_e=`${re}.vc-focusable, ${re} .vc-focusable`,Ee=i.value;if(Ee){const Fe=Ee.querySelector(_e);if(Fe)return Fe.focus(),!0}return!1},we=async(ge,B={})=>Se(ge)?!0:(await q(ge,B),Se(ge)),De=(ge,B)=>{a.value=ge.day,r("dayclick",ge,B)},Ue=(ge,B)=>{r("daymouseenter",ge,B)},xt=(ge,B)=>{r("daymouseleave",ge,B)},kt=(ge,B)=>{a.value=ge.day,n.value=ge,ge.isFocused=!0,r("dayfocusin",ge,B)},ot=(ge,B)=>{n.value=null,ge.isFocused=!1,r("dayfocusout",ge,B)},rr=(ge,B)=>{r("daykeydown",ge,B);const re=ge.noonDate;let _e=null;switch(B.key){case"ArrowLeft":{_e=Cn(re,-1);break}case"ArrowRight":{_e=Cn(re,1);break}case"ArrowUp":{_e=Cn(re,-7);break}case"ArrowDown":{_e=Cn(re,7);break}case"Home":{_e=Cn(re,-ge.weekdayPosition+1);break}case"End":{_e=Cn(re,ge.weekdayPositionFromEnd);break}case"PageUp":{B.altKey?_e=g6(re,-1):_e=ty(re,-1);break}case"PageDown":{B.altKey?_e=g6(re,1):_e=ty(re,1);break}}_e&&(B.preventDefault(),we(_e).catch())},Cr=ge=>{const B=n.value;B!=null&&rr(B,ge)},xi=(ge,B)=>{r("weeknumberclick",ge,B)};ie({page:e.initialPage,position:e.initialPagePosition}),or(()=>{!e.disablePageSwipe&&i.value&&(f=Wae(i.value,({toLeft:ge=!1,toRight:B=!1})=>{ge?oe():B&&ee()},iu("touch")))}),ss(()=>{c.value=[],f&&f()}),tt(()=>v.value,()=>{ie()}),tt(()=>S.value,()=>ie()),tt(()=>e.view,()=>u.value=e.view),tt(()=>u.value,()=>{Kae("view",()=>{ie()}),r("update:view",u.value)}),tt(()=>a.value,()=>{fe(c.value,ge=>K(ge))}),Rd(()=>{r("update:pages",c.value),fe(c.value,ge=>{Z(ge),K(ge)})});const Vt={emit:r,containerRef:i,focusedDay:n,inTransition:s,navPopoverId:o,dayPopoverId:l,view:u,pages:c,transitionName:d,theme:p,color:m,displayMode:g,locale:v,masks:x,attributes:$e,disabledAttribute:w,disabledDates:$,attributeContext:Oe,days:ve,dayCells:ze,count:S,step:E,firstPage:C,lastPage:I,canMovePrev:J,canMoveNext:N,minPage:P,maxPage:T,isMonthly:R,isWeekly:O,isDaily:V,navVisibility:D,showWeeknumbers:A,showIsoWeeknumbers:z,getDateAddress:ue,canMove:ne,canMoveBy:me,move:q,moveBy:te,movePrev:ee,moveNext:oe,onTransitionBeforeEnter:Y,onTransitionAfterEnter:F,tryFocusDate:Se,focusDate:we,onKeydown:Cr,onDayKeydown:rr,onDayClick:De,onDayMouseenter:Ue,onDayMouseleave:xt,onDayFocusin:kt,onDayFocusout:ot,onWeeknumberClick:xi};return xa(U9,Vt),Vt}function Oc(){const e=Gi(U9);if(e)return e;throw new Error("Calendar context missing. Please verify this component is nested within a valid context provider.")}const dse=fr({inheritAttrs:!1,emits:["before-show","after-show","before-hide","after-hide"],props:{id:{type:[Number,String,Symbol],required:!0},showDelay:{type:Number,default:0},hideDelay:{type:Number,default:110}
41,boundarySelector:{type:String}},setup(e,{emit:t}){let r;const i=se();let n=null,a=null;const s=An({isVisible:!1,target:null,data:null,transition:"slide-fade",placement:"bottom",direction:"",positionFixed:!1,modifiers:[],isInteractive:!0,visibility:"click",isHovered:!1,isFocused:!1,autoHide:!1,force:!1});function o(F){F&&(s.direction=F.split("-")[0])}function l({placement:F,options:ae}){o(F||(ae==null?void 0:ae.placement))}const u=H(()=>({placement:s.placement,strategy:s.positionFixed?"fixed":"absolute",boundary:"",modifiers:[{name:"onUpdate",enabled:!0,phase:"afterWrite",fn:l},...s.modifiers||[]],onFirstUpdate:l})),c=H(()=>{const F=s.direction==="left"||s.direction==="right";let ae="";if(s.placement){const ue=s.placement.split("-");ue.length>1&&(ae=ue[1])}return["start","top","left"].includes(ae)?F?"top":"left":["end","bottom","right"].includes(ae)?F?"bottom":"right":F?"middle":"center"});function d(){a&&(a.destroy(),a=null)}function h(){Bi(()=>{const F=X_(s.target);!F||!i.value||(a&&a.state.elements.reference!==F&&d(),a?a.update():a=aH(F,i.value,u.value))})}function f(F){Object.assign(s,h9(F,"force"))}function p(F,ae){clearTimeout(r),F>0?r=setTimeout(ae,F):ae()}function m(F){return!F||!a?!1:X_(F)===a.state.elements.reference}async function g(F={}){s.force||(F.force&&(s.force=!0),p(F.showDelay??e.showDelay,()=>{s.isVisible&&(s.force=!1),f({...F,isVisible:!0}),h()}))}function v(F={}){a&&(F.target&&!m(F.target)||s.force||(F.force&&(s.force=!0),p(F.hideDelay??e.hideDelay,()=>{s.isVisible||(s.force=!1),s.isVisible=!1})))}function x(F={}){F.target!=null&&(s.isVisible&&m(F.target)?v(F):g(F))}function _(F){if(!a)return;const ae=a.state.elements.reference;if(!i.value||!ae)return;const ue=F.target;H0(i.value,ue)||H0(ae,ue)||v({force:!0})}function y(F){(F.key==="Esc"||F.key==="Escape")&&v()}function w({detail:F}){!F.id||F.id!==e.id||g(F)}function $({detail:F}){!F.id||F.id!==e.id||v(F)}function S({detail:F}){!F.id||F.id!==e.id||x(F)}function E(){Ll(document,"keydown",y),Ll(document,"click",_),Ll(document,"show-popover",w),Ll(document,"hide-popover",$),Ll(document,"toggle-popover",S)}function C(){Ol(document,"keydown",y),Ol(document,"click",_),Ol(document,"show-popover",w),Ol(document,"hide-popover",$),Ol(document,"toggle-popover",S)}function I(F){t("before-show",F)}function P(F){s.force=!1,t("after-show",F)}function T(F){t("before-hide",F)}function D(F){s.force=!1,d(),t("after-hide",F)}function A(F){F.stopPropagation()}function z(){s.isHovered=!0,s.isInteractive&&["hover","hover-focus"].includes(s.visibility)&&g()}function R(){if(s.isHovered=!1,!a)return;const F=a.state.elements.reference;s.autoHide&&!s.isFocused&&(!F||F!==document.activeElement)&&["hover","hover-focus"].includes(s.visibility)&&v()}function O(){s.isFocused=!0,s.isInteractive&&["focus","hover-focus"].includes(s.visibility)&&g()}function V(F){["focus","hover-focus"].includes(s.visibility)&&(!F.relatedTarget||!H0(i.value,F.relatedTarget))&&(s.isFocused=!1,!s.isHovered&&s.autoHide&&v())}function Y(){n!=null&&(n.disconnect(),n=null)}return tt(()=>i.value,F=>{Y(),F&&(n=new ResizeObserver(()=>{a&&a.update()}),n.observe(F))}),tt(()=>s.placement,o,{immediate:!0}),or(()=>{E()}),ss(()=>{d(),Y(),C()}),{...s1(s),popoverRef:i,alignment:c,hide:v,setupPopper:h,beforeEnter:I,afterEnter:P,beforeLeave:T,afterLeave:D,onClick:A,onMouseOver:z,onMouseLeave:R,onFocusIn:O,onFocusOut:V}}}),pu=(e,t)=>{const r=e.__vccOpts||e;for(const[i,n]of t)r[i]=n;return r};function hse(e,t,r,i,n,a){return k(),M("div",{class:pe(["vc-popover-content-wrapper",{"is-interactive":e.isInteractive}]),ref:"popoverRef",onClick:t[0]||(t[0]=(...s)=>e.onClick&&e.onClick(...s)),onMouseover:t[1]||(t[1]=(...s)=>e.onMouseOver&&e.onMouseOver(...s)),onMouseleave:t[2]||(t[2]=(...s)=>e.onMouseLeave&&e.onMouseLeave(...s)),onFocusin:t[3]||(t[3]=(...s)=>e.onFocusIn&&e.onFocusIn(...s)),onFocusout:t[4]||(t[4]=(...s)=>e.onFocusOut&&e.onFocusOut(...s))},[be(Ym,{name:`vc-${e.transition}`,appear:"",onBeforeEnter:e.beforeEnter,onAfterEnter:e.afterEnter,onBeforeLeave:e.beforeLeave,onAfterLeave:e.afterLeave},{default:_t(()=>[e.isVisible?(k(),M("div",Ha({key:0,tabindex:"-1",class:`vc-popover-content direction-${e.direction}`},e.$attrs),[ws(e.$slots,"default",{direction:e.direction,alignment:e.alignment,data:e.data,hide:e.hide},()=>[Ze(Q(e.data),1)]),b("span",{class:pe(["vc-popover-caret",`direction-${e.direction}`,`align-${e.alignment}`])},null,2)],16)):X("",!0)]),_:3},8,["name","onBeforeEnter","onAfterEnter","onBeforeLeave","onAfterLeave"])],34)}const M1=pu(dse,[["render",hse]]),fse={class:"vc-day-popover-row"},pse={key:0,class:"vc-day-popover-row-indicator"},mse={class:"vc-day-popover-row-label"},V9=fr({__name:"PopoverRow",props:{attribute:null},setup(e){const t=e,r=H(()=>{const{content:i,highlight:n,dot:a,bar:s,popover:o}=t.attribute;return o&&o.hideIndicator?null:i?{class:`vc-bar vc-day-popover-row-bar vc-attr vc-${i.base.color}`}
41:n?{class:`vc-highlight-bg-solid vc-day-popover-row-highlight vc-attr vc-${n.base.color}`}:a?{class:`vc-dot vc-attr vc-${a.base.color}`}:s?{class:`vc-bar vc-day-popover-row-bar vc-attr vc-${s.base.color}`}:null});return(i,n)=>(k(),M("div",fse,[le(r)?(k(),M("div",pse,[b("span",{class:pe(le(r).class)},null,2)])):X("",!0),b("div",mse,[ws(i.$slots,"default",{},()=>[Ze(Q(e.attribute.popover?e.attribute.popover.label:"No content provided"),1)])])]))}}),gse={inheritAttrs:!1},Wa=fr({...gse,__name:"CalendarSlot",props:{name:null},setup(e){const r=j9(e.name);return(i,n)=>le(r)?(k(),Mt(c1(le(r)),Gu(Ha({key:0},i.$attrs)),null,16)):ws(i.$slots,"default",{key:1})}}),_se={class:"vc-day-popover-container"},yse={key:0,class:"vc-day-popover-header"},vse=fr({__name:"CalendarDayPopover",setup(e){const{dayPopoverId:t,displayMode:r,color:i,masks:n,locale:a}=Oc();function s(l,u){return a.value.formatDate(l,u)}function o(l){return a.value.formatDate(l.date,n.value.dayPopover)}return(l,u)=>(k(),Mt(M1,{id:le(t),class:pe([`vc-${le(i)}`,`vc-${le(r)}`])},{default:_t(({data:{day:c,attributes:d},hide:h})=>[be(Wa,{name:"day-popover",day:c,"day-title":o(c),attributes:d,format:s,masks:le(n),hide:h},{default:_t(()=>[b("div",_se,[le(n).dayPopover?(k(),M("div",yse,Q(o(c)),1)):X("",!0),(k(!0),M(xe,null,Me(d,f=>(k(),Mt(V9,{key:f.key,attribute:f},null,8,["attribute"]))),128))])]),_:2},1032,["day","day-title","attributes","masks","hide"])]),_:1},8,["id","class"]))}}),bse={},xse={"stroke-linecap":"round","stroke-linejoin":"round",viewBox:"0 0 24 24"},wse=b("polyline",{points:"9 18 15 12 9 6"},null,-1),$se=[wse];function Sse(e,t){return k(),M("svg",xse,$se)}const Tse=pu(bse,[["render",Sse]]),Cse={},kse={"stroke-linecap":"round","stroke-linejoin":"round",viewBox:"0 0 24 24"},Ese=b("polyline",{points:"15 18 9 12 15 6"},null,-1),Pse=[Ese];function Mse(e,t){return k(),M("svg",kse,Pse)}const Ise=pu(Cse,[["render",Mse]]),Ase={},Dse={"stroke-linecap":"round","stroke-linejoin":"round",viewBox:"0 0 24 24"},Rse=b("polyline",{points:"6 9 12 15 18 9"},null,-1),Ose=[Rse];function Lse(e,t){return k(),M("svg",Dse,Ose)}const Fse=pu(Ase,[["render",Lse]]),zse={},Nse={fill:"none","stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",viewBox:"0 0 24 24"},Bse=b("path",{d:"M12 8v4l3 3m6-3a9 9 0 11-18 0 9 9 0 0118 0z"},null,-1),jse=[Bse];function Use(e,t){return k(),M("svg",Nse,jse)}const Vse=pu(zse,[["render",Use]]),qse=Object.freeze(Object.defineProperty({__proto__:null,IconChevronDown:Fse,IconChevronLeft:Ise,IconChevronRight:Tse,IconClock:Vse},Symbol.toStringTag,{value:"Module"})),yh=fr({__name:"BaseIcon",props:{name:{type:String,required:!0},width:{type:String},height:{type:String},size:{type:String,default:"26"},viewBox:{type:String}},setup(e){const t=e,r=H(()=>t.width||t.size),i=H(()=>t.height||t.size),n=H(()=>qse[`Icon${t.name}`]);return(a,s)=>(k(),Mt(c1(le(n)),{width:le(r),height:le(i),class:"vc-base-icon"},null,8,["width","height"]))}}),Gse=["disabled"],Hse={key:1,class:"vc-title-wrapper"},Yse={type:"button",class:"vc-title"},Wse=["disabled"],q9=fr({__name:"CalendarHeader",props:{page:null,layout:null,isLg:{type:Boolean},isXl:{type:Boolean},is2xl:{type:Boolean},hideTitle:{type:Boolean},hideArrows:{type:Boolean}},setup(e){const t=e,{navPopoverId:r,navVisibility:i,canMovePrev:n,movePrev:a,canMoveNext:s,moveNext:o}=Oc(),l=H(()=>{switch(t.page.titlePosition){case"left":return"bottom-start";case"right":return"bottom-end";default:return"bottom"}}),u=H(()=>{const{page:m}=t;return{id:r.value,visibility:i.value,placement:l.value,modifiers:[{name:"flip",options:{fallbackPlacements:["bottom"]}}],data:{page:m},isInteractive:!0}}),c=H(()=>t.page.titlePosition.includes("left")),d=H(()=>t.page.titlePosition.includes("right")),h=H(()=>t.layout?t.layout:c.value?"tu-pn":d.value?"pn-tu":"p-tu-n;"),f=H(()=>({prev:h.value.includes("p")&&!t.hideArrows,title:h.value.includes("t")&&!t.hideTitle,next:h.value.includes("n")&&!t.hideArrows})),p=H(()=>({gridTemplateColumns:h.value.split("").map(g=>{switch(g){case"p":return"[prev] auto";case"n":return"[next] auto";case"t":return"[title] auto";case"-":return"1fr";default:return""}}).join(" ")}));return(m,g)=>(k(),M("div",{class:pe(["vc-header",{"is-lg":e.isLg,"is-xl":e.isXl,"is-2xl":e.is2xl}]),style:Qt(le(p))}
41,[le(f).prev?(k(),M("button",{key:0,type:"button",class:"vc-arrow vc-prev vc-focus",disabled:!le(n),onClick:g[0]||(g[0]=(...v)=>le(a)&&le(a)(...v)),onKeydown:g[1]||(g[1]=Ao((...v)=>le(a)&&le(a)(...v),["space","enter"]))},[be(Wa,{name:"header-prev-button",disabled:!le(n)},{default:_t(()=>[be(yh,{name:"ChevronLeft",size:"24"})]),_:1},8,["disabled"])],40,Gse)):X("",!0),le(f).title?(k(),M("div",Hse,[be(Wa,{name:"header-title-wrapper"},{default:_t(()=>[it((k(),M("button",Yse,[be(Wa,{name:"header-title",title:e.page.title},{default:_t(()=>[b("span",null,Q(e.page.title),1)]),_:1},8,["title"])])),[[le(R9),le(u)]])]),_:1})])):X("",!0),le(f).next?(k(),M("button",{key:2,type:"button",class:"vc-arrow vc-next vc-focus",disabled:!le(s),onClick:g[2]||(g[2]=(...v)=>le(o)&&le(o)(...v)),onKeydown:g[3]||(g[3]=Ao((...v)=>le(o)&&le(o)(...v),["space","enter"]))},[be(Wa,{name:"header-next-button",disabled:!le(s)},{default:_t(()=>[be(yh,{name:"ChevronRight",size:"24"})]),_:1},8,["disabled"])],40,Wse)):X("",!0)],6))}}),G9=Symbol("__vc_page_context__");function Zse(e){const{locale:t,getDateAddress:r,canMove:i}=Oc();function n(o,l){const{month:u,year:c}=r(new Date);return M9().map((d,h)=>{const f=h+1;return{month:f,year:o,id:zne(f,o),label:t.value.formatDate(d,l),ariaLabel:t.value.formatDate(d,"MMMM"),isActive:f===e.value.month&&o===e.value.year,isCurrent:f===u&&o===c,isDisabled:!i({month:f,year:o},{position:e.value.position})}})}function a(o,l){const{year:u}=r(new Date),{position:c}=e.value,d=[];for(let h=o;h<=l;h+=1){const f=[...Array(12).keys()].some(p=>i({month:p+1,year:h},{position:c}));d.push({year:h,id:h.toString(),label:h.toString(),ariaLabel:h.toString(),isActive:h===e.value.year,isCurrent:h===u,isDisabled:!f})}return d}const s={page:e,getMonthItems:n,getYearItems:a};return xa(G9,s),s}function H9(){const e=Gi(G9);if(e)return e;throw new Error("Page context missing. Please verify this component is nested within a valid context provider.")}const Kse={class:"vc-nav-header"},Xse=["disabled"],Jse=["disabled"],Qse={class:"vc-nav-items"},eoe=["data-id","aria-label","disabled","onClick","onKeydown"],toe=fr({__name:"CalendarNav",setup(e){const{masks:t,move:r}=Oc(),{page:i,getMonthItems:n,getYearItems:a}=H9(),s=se(!0),o=12,l=se(i.value.year),u=se(h(i.value.year)),c=se(null);function d(){setTimeout(()=>{if(c.value==null)return;const ue=c.value.querySelector(".vc-nav-item:not(:disabled)");ue&&ue.focus()},10)}function h(ue){return Math.floor(ue/o)}function f(){s.value=!s.value}function p(ue){return ue*o}function m(ue){return o*(ue+1)-1}function g(){O.value&&(s.value&&x(),y())}function v(){V.value&&(s.value&&_(),w())}function x(){l.value--}function _(){l.value++}function y(){u.value--}function w(){u.value++}const $=H(()=>n(l.value,t.value.navMonths).map(ue=>({...ue,click:()=>r({month:ue.month,year:ue.year},{position:i.value.position})}))),S=H(()=>n(l.value-1,t.value.navMonths)),E=H(()=>S.value.some(ue=>!ue.isDisabled)),C=H(()=>n(l.value+1,t.value.navMonths)),I=H(()=>C.value.some(ue=>!ue.isDisabled)),P=H(()=>a(p(u.value),m(u.value)).map(ue=>({...ue,click:()=>{l.value=ue.year,s.value=!0,d()}}))),T=H(()=>a(p(u.value-1),m(u.value-1))),D=H(()=>T.value.some(ue=>!ue.isDisabled)),A=H(()=>a(p(u.value+1),m(u.value+1))),z=H(()=>A.value.some(ue=>!ue.isDisabled)),R=H(()=>s.value?$.value:P.value),O=H(()=>s.value?E.value:D.value),V=H(()=>s.value?I.value:z.value),Y=H(()=>c9(P.value.map(ue=>ue.year))),F=H(()=>vd(P.value.map(ue=>ue.year))),ae=H(()=>s.value?l.value:`${Y.value} - ${F.value}`);return Rd(()=>{l.value=i.value.year,d()}),tt(()=>l.value,ue=>u.value=h(ue)),or(()=>d()),(ue,Z)=>(k(),M("div",{class:"vc-nav-container",ref_key:"navContainer",ref:c},[b("div",Kse,[b("button",{type:"button",class:"vc-nav-arrow is-left vc-focus",disabled:!le(O),onClick:g,onKeydown:Z[0]||(Z[0]=K=>le(qg)(K,g))},[be(Wa,{name:"nav-prev-button",move:g,disabled:!le(O)},{default:_t(()=>[be(yh,{name:"ChevronLeft",width:"22px",height:"24px"})]),_:1},8,["disabled"])],40,Xse),b("button",{type:"button",class:"vc-nav-title vc-focus",onClick:f,onKeydown:Z[1]||(Z[1]=K=>le(qg)(K,f))},Q(le(ae)),33),b("button",{type:"button",class:"vc-nav-arrow is-right vc-focus",disabled:!le(V),onClick:v,onKeydown:Z[2]||(Z[2]=K=>le(qg)(K,v))},[be(Wa,{name:"nav-next-button",move:v,disabled:!le(V)},{default:_t(()=>[be(yh,{name:"ChevronRight",width:"22px",height:"24px"})]),_:1},8,["disabled"])],40,Jse)]),b("div",Qse,[(k(!0),M(xe,null,Me(le(R),K=>(k(),M("button",{key:K.label,type:"button","data-id":K.id,"aria-label":K.ariaLabel,class:
41pe(["vc-nav-item vc-focus",[K.isActive?"is-active":K.isCurrent?"is-current":""]]),disabled:K.isDisabled,onClick:K.click,onKeydown:fe=>le(qg)(fe,K.click)},Q(K.label),43,eoe))),128))])],512))}}),Y9=fr({__name:"CalendarPageProvider",props:{page:null},setup(e){return Zse(Wu(e,"page")),(r,i)=>ws(r.$slots,"default")}}),roe=fr({__name:"CalendarNavPopover",setup(e){const{navPopoverId:t,color:r,displayMode:i}=Oc();return(n,a)=>(k(),Mt(M1,{id:le(t),class:pe(["vc-nav-popover-container",`vc-${le(r)}`,`vc-${le(i)}`])},{default:_t(({data:s})=>[be(Y9,{page:s.page},{default:_t(()=>[be(Wa,{name:"nav"},{default:_t(()=>[be(toe)]),_:1})]),_:2},1032,["page"])]),_:1},8,["id","class"]))}}),ioe=fr({directives:{popover:R9},components:{CalendarSlot:Wa},props:{day:{type:Object,required:!0}},setup(e){const{locale:t,theme:r,attributeContext:i,dayPopoverId:n,onDayClick:a,onDayMouseenter:s,onDayMouseleave:o,onDayFocusin:l,onDayFocusout:u,onDayKeydown:c}=Oc(),d=H(()=>e.day),h=H(()=>i.value.getCells(d.value)),f=H(()=>h.value.map(z=>z.data)),p=H(()=>({...d.value,attributes:f.value,attributeCells:h.value}));function m({data:z},{popovers:R}){const{key:O,customData:V,popover:Y}=z;if(!Y)return;const F=JT({key:O,customData:V,attribute:z},{...Y},{visibility:Y.label?"hover":"click",placement:"bottom",isInteractive:!Y.label});R.splice(0,0,F)}const g=H(()=>{const z={...r.value.prepareRender({}),popovers:[]};return h.value.forEach(R=>{r.value.render(R,z),m(R,z)}),z}),v=H(()=>g.value.highlights),x=H(()=>!!Oo(v.value)),_=H(()=>g.value.content),y=H(()=>g.value.dots),w=H(()=>!!Oo(y.value)),$=H(()=>g.value.bars),S=H(()=>!!Oo($.value)),E=H(()=>g.value.popovers),C=H(()=>E.value.map(z=>z.attribute)),I=j9("day-content"),P=H(()=>["vc-day",...d.value.classes,{"vc-day-box-center-center":!I},{"is-not-in-month":!e.day.inMonth}]),T=H(()=>{let z;d.value.isFocusable?z="0":z="-1";const R=["vc-day-content vc-focusable vc-focus vc-attr",{"vc-disabled":d.value.isDisabled},zu(vd(v.value),"contentClass"),zu(vd(_.value),"class")||""],O={...zu(vd(v.value),"contentStyle"),...zu(vd(_.value),"style")};return{class:R,style:O,tabindex:z,"aria-label":d.value.ariaLabel,"aria-disabled":!!d.value.isDisabled,role:"button"}}),D=H(()=>({click(z){a(p.value,z)},mouseenter(z){s(p.value,z)},mouseleave(z){o(p.value,z)},focusin(z){l(p.value,z)},focusout(z){u(p.value,z)},keydown(z){c(p.value,z)}})),A=H(()=>Oo(E.value)?JT({id:n.value,data:{day:d,attributes:C.value}},...E.value):null);return{attributes:f,attributeCells:h,bars:$,dayClasses:P,dayContentProps:T,dayContentEvents:D,dayPopover:A,glyphs:g,dots:y,hasDots:w,hasBars:S,highlights:v,hasHighlights:x,locale:t,popovers:E}}}),noe={key:0,class:"vc-highlights vc-day-layer"},aoe={key:1,class:"vc-day-layer vc-day-box-center-bottom"},soe={class:"vc-dots"},ooe={key:2,class:"vc-day-layer vc-day-box-center-bottom"},loe={class:"vc-bars"};function uoe(e,t,r,i,n,a){const s=qr("CalendarSlot"),o=A3("popover");return k(),M("div",{class:pe(e.dayClasses)},[e.hasHighlights?(k(),M("div",noe,[(k(!0),M(xe,null,Me(e.highlights,({key:l,wrapperClass:u,class:c,style:d})=>(k(),M("div",{key:l,class:pe(u)},[b("div",{class:pe(c),style:Qt(d)},null,6)],2))),128))])):X("",!0),be(s,{name:"day-content",day:e.day,attributes:e.attributes,"attribute-cells":e.attributeCells,dayProps:e.dayContentProps,dayEvents:e.dayContentEvents,locale:e.locale},{default:_t(()=>[it((k(),M("div",Ha(e.dayContentProps,mM(e.dayContentEvents,!0)),[Ze(Q(e.day.label),1)],16)),[[o,e.dayPopover]])]),_:1},8,["day","attributes","attribute-cells","dayProps","dayEvents","locale"]),e.hasDots?(k(),M("div",aoe,[b("div",soe,[(k(!0),M(xe,null,Me(e.dots,({key:l,class:u,style:c})=>(k(),M("span",{key:l,class:pe(u),style:Qt(c)},null,6))),128))])])):X("",!0),e.hasBars?(k(),M("div",ooe,[b("div",loe,[(k(!0),M(xe,null,Me(e.bars,({key:l,class:u,style:c})=>(k(),M("span",{key:l,class:pe(u),style:Qt(c)},null,6))),128))])])):X("",!0)],2)}const coe=pu(ioe,[["render",uoe]]),doe={class:"vc-weekdays"},hoe=["onClick"],foe={inheritAttrs:!1},poe=fr({...foe,__name:"CalendarPage",setup(e){const{page:t}=H9(),{onWeeknumberClick:r}=Oc();return(i,n)=>(k(),M("div",{class:pe(["vc-pane",`row-${le(t).row}`,`row-from-end-${le(t).rowFromEnd}`,`column-${le(t).column}`,`column-from-end-${le(t).columnFromEnd}`]),ref:"pane"},[be(q9,{page:le(t),"is-lg":"","hide-arrows":""},null,8,["page"]),b("div",{class:pe(["vc-weeks",{[`vc-show-weeknumbers-${le(t).weeknumberPosition}`]:le(t).weeknumberPosition}])},[b("div",doe,[(k(!0),M(xe,null,Me(le(t).weekdays,({weekday:a,label:s},o)=>(k(),M("div",{key:o,class:pe(`vc-weekday vc-weekday-${a}`)}
41,Q(s),3))),128))]),(k(!0),M(xe,null,Me(le(t).viewWeeks,a=>(k(),M("div",{key:`weeknumber-${a.weeknumber}`,class:"vc-week"},[le(t).weeknumberPosition?(k(),M("div",{key:0,class:pe(["vc-weeknumber",`is-${le(t).weeknumberPosition}`])},[b("span",{class:pe(["vc-weeknumber-content"]),onClick:s=>le(r)(a,s)},Q(a.weeknumberDisplay),9,hoe)],2)):X("",!0),(k(!0),M(xe,null,Me(a.days,s=>(k(),Mt(coe,{key:s.id,day:s},null,8,["day"]))),128))]))),128))],2)],2))}}),moe=fr({components:{CalendarHeader:q9,CalendarPage:poe,CalendarNavPopover:roe,CalendarDayPopover:vse,CalendarPageProvider:Y9,CalendarSlot:Wa},props:lse,emit:use,setup(e,{emit:t,slots:r}){return cse(e,{emit:t,slots:r})}}),goe={class:"vc-pane-header-wrapper"};function _oe(e,t,r,i,n,a){const s=qr("CalendarHeader"),o=qr("CalendarPage"),l=qr("CalendarSlot"),u=qr("CalendarPageProvider"),c=qr("CalendarDayPopover"),d=qr("CalendarNavPopover");return k(),M(xe,null,[b("div",Ha({"data-helptext":"Press the arrow keys to navigate by day, Home and End to navigate to week ends, PageUp and PageDown to navigate by month, Alt+PageUp and Alt+PageDown to navigate by year"},e.$attrs,{class:["vc-container",`vc-${e.view}`,`vc-${e.color}`,`vc-${e.displayMode}`,{"vc-expanded":e.expanded,"vc-bordered":!e.borderless,"vc-transparent":e.transparent}],onMouseup:t[0]||(t[0]=di(()=>{},["prevent"])),ref:"containerRef"}),[b("div",{class:pe(["vc-pane-container",{"in-transition":e.inTransition}])},[b("div",goe,[e.firstPage?(k(),Mt(s,{key:0,page:e.firstPage,"is-lg":"","hide-title":""},null,8,["page"])):X("",!0)]),be(Ym,{name:`vc-${e.transitionName}`,onBeforeEnter:e.onTransitionBeforeEnter,onAfterEnter:e.onTransitionAfterEnter},{default:_t(()=>[(k(),M("div",{key:e.pages[0].id,class:"vc-pane-layout",style:Qt({gridTemplateColumns:`repeat(${e.columns}, 1fr)`})},[(k(!0),M(xe,null,Me(e.pages,h=>(k(),Mt(u,{key:h.id,page:h},{default:_t(()=>[be(l,{name:"page",page:h},{default:_t(()=>[be(o)]),_:2},1032,["page"])]),_:2},1032,["page"]))),128))],4))]),_:1},8,["name","onBeforeEnter","onAfterEnter"]),be(l,{name:"footer"})],2)],16),be(c),be(d)],64)}const W9=pu(moe,[["render",_oe]]),Z9=Symbol("__vc_date_picker_context__"),yoe={...F9,mode:{type:String,default:"date"},modelValue:{type:[Number,String,Date,Object]},modelModifiers:{type:Object,default:()=>({})},rules:[String,Object],is24hr:Boolean,hideTimeHeader:Boolean,timeAccuracy:{type:Number,default:2},isRequired:Boolean,isRange:Boolean,updateOnInput:{type:Boolean,default:()=>iu("datePicker.updateOnInput")},inputDebounce:{type:Number,default:()=>iu("datePicker.inputDebounce")},popover:{type:[Boolean,Object],default:!0},dragAttribute:Object,selectAttribute:Object,attributes:[Object,Array]},voe=["update:modelValue","drag","dayclick","daykeydown","popover-will-show","popover-did-show","popover-will-hide","popover-did-hide"];function boe(e,{emit:t,slots:r}){B9(r,{footer:"dp-footer"});const i=z9(e),{locale:n,masks:a,disabledAttribute:s}=i,o=se(!1),l=se(Symbol()),u=se(null),c=se(null),d=se(["",""]),h=se(null),f=se(null);let p,m,g=!0;const v=H(()=>e.isRange||e.modelModifiers.range===!0),x=H(()=>v.value&&u.value!=null?u.value.start:null),_=H(()=>v.value&&u.value!=null?u.value.end:null),y=H(()=>e.mode.toLowerCase()==="date"),w=H(()=>e.mode.toLowerCase()==="datetime"),$=H(()=>e.mode.toLowerCase()==="time"),S=H(()=>!!c.value),E=H(()=>{let B="date";e.modelModifiers.number&&(B="number"),e.modelModifiers.string&&(B="string");const re=a.value.modelValue||"iso";return Z({type:B,mask:re})}),C=H(()=>me(c.value??u.value)),I=H(()=>$.value?e.is24hr?a.value.inputTime24hr:a.value.inputTime:w.value?e.is24hr?a.value.inputDateTime24hr:a.value.inputDateTime:a.value.input),P=H(()=>/[Hh]/g.test(I.value)),T=H(()=>/[dD]{1,2}|Do|W{1,4}|M{1,4}|YY(?:YY)?/g.test(I.value)),D=H(()=>{if(P.value&&T.value)return"dateTime";if(T.value)return"date";if(P.value)return"time"}),A=H(()=>{var B;const re=((B=h.value)==null?void 0:B.$el.previousElementSibling)??void 0;return _h({},e.popover,iu("datePicker.popover"),{target:re})}),z=H(()=>D9({...A.value,id:l.value})),R=H(()=>v.value?{start:d.value[0],end:d.value[1]}:d.value[0]),O=H(()=>{const B=["start","end"].map(re=>({input:ie(re),change:U(re),keyup:ne,...e.popover&&z.value}));return v.value?{start:B[0],end:B[1]}:B[0]}),V=H(()=>
41{if(!$e(u.value))return null;const B={key:"select-drag",...e.selectAttribute,dates:u.value,pinPage:!0},{dot:re,bar:_e,highlight:Ee,content:Fe}=B;return!re&&!_e&&!Ee&&!Fe&&(B.highlight=!0),B}),Y=H(()=>{if(!v.value||!$e(c.value))return null;const B={key:"select-drag",...e.dragAttribute,dates:c.value},{dot:re,bar:_e,highlight:Ee,content:Fe}=B;return!re&&!_e&&!Ee&&!Fe&&(B.highlight={startEnd:{fillMode:"outline"}}),B}),F=H(()=>{const B=es(e.attributes)?[...e.attributes]:[];return Y.value?B.unshift(Y.value):V.value&&B.unshift(V.value),B}),ae=H(()=>Z(e.rules==="auto"?ue():e.rules??{}));function ue(){const B={ms:[0,999],sec:[0,59],min:[0,59],hr:[0,23]},re=y.value?0:e.timeAccuracy;return[0,1].map(_e=>{switch(re){case 0:return{hours:B.hr[_e],minutes:B.min[_e],seconds:B.sec[_e],milliseconds:B.ms[_e]};case 1:return{minutes:B.min[_e],seconds:B.sec[_e],milliseconds:B.ms[_e]};case 3:return{milliseconds:B.ms[_e]};case 4:return{};default:return{seconds:B.sec[_e],milliseconds:B.ms[_e]}}})}function Z(B){return es(B)?B.length===1?[B[0],B[0]]:B:[B,B]}function K(B){return Z(B).map((re,_e)=>({...re,rules:ae.value[_e]}))}function fe(B){return B==null?!1:Es(B)?!isNaN(B):Nd(B)?!isNaN(B.getTime()):Zs(B)?B!=="":F4(B)}function ve(B){return il(B)&&"start"in B&&"end"in B&&fe(B.start??null)&&fe(B.end??null)}function $e(B){return ve(B)||fe(B)}function Re(B,re){if(B==null&&re==null)return!0;if(B==null||re==null)return!1;const _e=Nd(B),Ee=Nd(re);return _e&&Ee?B.getTime()===re.getTime():_e||Ee?!1:Re(B.start,re.start)&&Re(B.end,re.end)}function Oe(B){return!$e(B)||!s.value?!1:s.value.intersectsRange(n.value.range(B))}function ze(B,re,_e,Ee){if(!$e(B))return null;if(ve(B)){const Fe=n.value.toDate(B.start,{...re[0],fillDate:x.value??void 0,patch:_e}),ht=n.value.toDate(B.end,{...re[1],fillDate:_.value??void 0,patch:_e});return ot({start:Fe,end:ht},Ee)}return n.value.toDateOrNull(B,{...re[0],fillDate:u.value,patch:_e})}function Be(B,re){return ve(B)?{start:n.value.fromDate(B.start,re[0]),end:n.value.fromDate(B.end,re[1])}:v.value?null:n.value.fromDate(B,re[0])}function qe(B,re={}){return clearTimeout(p),new Promise(_e=>{const{debounce:Ee=0,...Fe}=re;Ee>0?p=window.setTimeout(()=>{_e(j(B,Fe))},Ee):_e(j(B,Fe))})}function j(B,{config:re=E.value,patch:_e="dateTime",clearIfEqual:Ee=!1,formatInput:Fe=!0,hidePopover:ht=!1,dragging:Et=S.value,targetPriority:lr,moveToValue:Br=!1}={}){const ls=K(re);let Ke=ze(B,ls,_e,lr);if(Oe(Ke)){if(Et)return null;Ke=u.value,ht=!1}else Ke==null&&e.isRequired?Ke=u.value:Ke!=null&&Re(u.value,Ke)&&Ee&&(Ke=null);const It=Et?c:u,Ie=!Re(It.value,Ke);It.value=Ke,Et||(c.value=null);const st=Be(Ke,E.value);return Ie&&(g=!1,t(Et?"drag":"update:modelValue",st),Bi(()=>g=!0)),ht&&!Et&&xt(),Fe&&W(),Br&&Bi(()=>xi(lr??"start")),st}function W(){Bi(()=>{const B=K({type:"string",mask:I.value}),re=Be(c.value??u.value,B);v.value?d.value=[re&&re.start,re&&re.end]:d.value=[re,""]})}function G(B,re,_e){d.value.splice(re==="start"?0:1,1,B);const Ee=v.value?{start:d.value[0],end:d.value[1]||d.value[0]}:B,Fe={type:"string",mask:I.value};qe(Ee,{..._e,config:Fe,patch:D.value,targetPriority:re,moveToValue:!0})}function ie(B){return re=>{e.updateOnInput&&G(re.currentTarget.value,B,{formatInput:!1,hidePopover:!1,debounce:e.inputDebounce})}}function U(B){return re=>{G(re.currentTarget.value,B,{formatInput:!0,hidePopover:!1})}}function ne(B){B.key==="Escape"&&qe(u.value,{formatInput:!0,hidePopover:!0})}function me(B){return v.value?[B&&B.start?n.value.getDateParts(B.start):null,B&&B.end?n.value.getDateParts(B.end):null]:[B?n.value.getDateParts(B):null]}function J(){c.value=null,W()}function N(B){t("popover-will-show",B)}function q(B){t("popover-did-show",B)}function te(B){J(),t("popover-will-hide",B)}function ee(B){t("popover-did-hide",B)}function oe(B){const re={patch:"date",formatInput:!0,hidePopover:!0};if(v.value){const _e=!S.value;_e?m={start:B.startDate,end:B.endDate}:m!=null&&(m.end=B.date),qe(m,{...re,dragging:_e})}else qe(B.date,{...re,clearIfEqual:!e.isRequired})}function Se(B,re){oe(B),t("dayclick",B,re)}function we(B,re){switch(re.key){case" ":case"Enter":{oe(B),re.preventDefault();break}case"Escape":xt()}t("daykeydown",B,re)}function De(B,re){!S.value||m==null||(m.end=B.date,qe(ot(m),{patch:"date",formatInput:!0}))}function Ue(B={}){X2({...A.value,...B,isInteractive:!0,id:l.value})}function xt(B={}){nm({hideDelay:10,force:!0,...A.value,...B,id:l.value})}
41function kt(B){A9({...A.value,...B,isInteractive:!0,id:l.value})}function ot(B,re){const{start:_e,end:Ee}=B;if(_e>Ee)switch(re){case"start":return{start:_e,end:_e};case"end":return{start:Ee,end:Ee};default:return{start:Ee,end:_e}}return{start:_e,end:Ee}}async function rr(B,re={}){return f.value==null?!1:f.value.move(B,re)}async function Cr(B,re={}){return f.value==null?!1:f.value.moveBy(B,re)}async function xi(B,re={}){const _e=u.value;if(f.value==null||!$e(_e))return!1;const Ee=B!=="end",Fe=Ee?1:-1,ht=ve(_e)?Ee?_e.start:_e.end:_e,Et=g9(ht,"monthly",n.value);return f.value.move(Et,{position:Fe,...re})}tt(()=>e.isRange,B=>{B&&console.warn("The `is-range` prop will be deprecated in future releases. Please use the `range` modifier.")},{immediate:!0}),tt(()=>v.value,()=>{j(null,{formatInput:!0})}),tt(()=>I.value,()=>W()),tt(()=>e.modelValue,B=>{g&&j(B,{formatInput:!0,hidePopover:!1})}),tt(()=>ae.value,()=>{il(e.rules)&&j(e.modelValue,{formatInput:!0,hidePopover:!1})}),tt(()=>e.timezone,()=>{j(u.value,{formatInput:!0})});const Vt=Z(E.value);u.value=ze(e.modelValue??null,Vt,"dateTime"),or(()=>{j(e.modelValue,{formatInput:!0,hidePopover:!1})}),Bi(()=>o.value=!0);const ge={...i,showCalendar:o,datePickerPopoverId:l,popoverRef:h,popoverEvents:z,calendarRef:f,
41isRange:v,isTimeMode:$,isDateTimeMode:w,is24hr:Wu(e,"is24hr"),hideTimeHeader:Wu(e,"hideTimeHeader"),timeAccuracy:Wu(e,"timeAccuracy"),isDragging:S,inputValue:R,inputEvents:O,dateParts:C,attributes:F,rules:ae,move:rr,moveBy:Cr,moveToValue:xi,updateValue:qe,showPopover:Ue,hidePopover:xt,togglePopover:kt,onDayClick:Se,onDayKeydown:we,onDayMouseEnter:De,onPopoverBeforeShow:N,onPopoverAfterShow:q,onPopoverBeforeHide:te,onPopoverAfterHide:ee};return xa(Z9,ge),ge}function j4(){const e=Gi(Z9);if(e)return e;throw new Error("DatePicker context missing. Please verify this component is nested within a valid context provider.")}const xoe=[{value:0,label:"12"},{value:1,label:"1"},{value:2,label:"2"},{value:3,label:"3"},{value:4,label:"4"},{value:5,label:"5"},{value:6,label:"6"},{value:7,label:"7"},{value:8,label:"8"},{value:9,label:"9"},{value:10,label:"10"},{value:11,label:"11"}],woe=[{value:12,label:"12"},{value:13,label:"1"},{value:14,label:"2"},{value:15,label:"3"},{value:16,label:"4"},{value:17,label:"5"},{value:18,label:"6"},{value:19,label:"7"},{value:20,label:"8"},{value:21,label:"9"},{value:22,label:"10"},{value:23,label:"11"}];function $oe(e){const t=j4(),{locale:r,isRange:i,isTimeMode:n,dateParts:a,rules:s,is24hr:o,hideTimeHeader:l,timeAccuracy:u,updateValue:c}=t;function d(T){T=Object.assign(f.value,T);let D=null;if(i.value){const A=h.value?T:a.value[0],z=h.value?a.value[1]:T;D={start:A,end:z}}else D=T;c(D,{patch:"time",targetPriority:h.value?"start":"end",moveToValue:!0})}const h=H(()=>e.position===0),f=H(()=>a.value[e.position]||{isValid:!1}),p=H(()=>F4(f.value)),m=H(()=>!!f.value.isValid),g=H(()=>!l.value&&m.value),v=H(()=>{if(!p.value)return null;let T=r.value.toDate(f.value);return f.value.hours===24&&(T=new Date(T.getTime()-1)),T}),x=H({get(){return f.value.hours},set(T){d({hours:T})}}),_=H({get(){return f.value.minutes},set(T){d({minutes:T})}}),y=H({get(){return f.value.seconds},set(T){d({seconds:T})}}),w=H({get(){return f.value.milliseconds},set(T){d({milliseconds:T})}}),$=H({get(){return f.value.hours<12},set(T){T=String(T).toLowerCase()=="true";let D=x.value;T&&D>=12?D-=12:!T&&D<12&&(D+=12),d({hours:D})}}),S=H(()=>Vae(f.value,s.value[e.position])),E=H(()=>xoe.filter(T=>S.value.hours.some(D=>D.value===T.value))),C=H(()=>woe.filter(T=>S.value.hours.some(D=>D.value===T.value))),I=H(()=>o.value?S.value.hours:$.value?E.value:C.value),P=H(()=>{const T=[];return Oo(E.value)&&T.push({value:!0,label:"AM"}),Oo(C.value)&&T.push({value:!1,label:"PM"}),T});return{...t,showHeader:g,timeAccuracy:u,parts:f,isValid:m,date:v,hours:x,minutes:_,seconds:y,milliseconds:w,options:S,hourOptions:I,isAM:$,isAMOptions:P,is24hr:o}}const Soe=["value"],Toe=["value","disabled"],Coe={key:1,class:"vc-base-sizer","aria-hidden":"true"},koe={inheritAttrs:!1},gf=fr({...koe,__name:"BaseSelect",props:{options:null,modelValue:null,alignRight:{type:Boolean},alignLeft:{type:Boolean},showIcon:{type:Boolean},fitContent:{type:Boolean}},emits:["update:modelValue"],setup(e){const t=e,r=H(()=>{const i=t.options.find(n=>n.value===t.modelValue);return i==null?void 0:i.label});return(i,n)=>(k(),M("div",{class:pe(["vc-base-select",{"vc-fit-content":e.fitContent,"vc-has-icon":e.showIcon}])},[b("select",Ha(i.$attrs,{value:e.modelValue,class:["vc-focus",{"vc-align-right":e.alignRight,"vc-align-left":e.alignLeft}],onChange:n[0]||(n[0]=a=>i.$emit("update:modelValue",a.target.value))}),[(k(!0),M(xe,null,Me(e.options,a=>(k(),M("option",{key:a.value,value:a.value,disabled:a.disabled},Q(a.label),9,Toe))),128))],16,Soe),e.showIcon?(k(),Mt(yh,{key:0,name:"ChevronDown",size:"18"})):X("",!0),e.fitContent?(k(),M("div",Coe,Q(le(r)),1)):X("",!0)],2))}}),Eoe={key:0,class:"vc-time-header"},Poe={class:"vc-time-weekday"},Moe={class:"vc-time-month"},Ioe={class:"vc-time-day"},Aoe={class:"vc-time-year"},Doe={class:"vc-time-select-group"},Roe=b("span",{class:"vc-time-colon"},":",-1),Ooe=b("span",{class:"vc-time-colon"},":",-1),Loe=b("span",{class:"vc-time-decimal"},".",-1),k6=fr({__name:"TimePicker",props:{position:null},setup(e,{expose:t}){const i=$oe(e);t(i);const{locale:n,isValid:a,date:s,hours:o,minutes:l,seconds:u,milliseconds:c,options:d,hourOptions:h,isTimeMode:f,isAM:p,isAMOptions:m,is24hr:g,showHeader:v,timeAccuracy:x}=i;return(_,y)=>(k(),M("div",{class:pe(["vc-time-picker",[{"vc-invalid":!le(a),"vc-attached":!le(f)}]])},[be(Wa,{name:"time-header"},{default:_t(()=>[le(v)&&le(s)?(k(),M("div",Eoe,[b("span",Poe,Q(le(n).formatDate(le(s),"WWW")),1),b("span",Moe,Q(le(n).formatDate(le(s),"MMM")),1),b("span",Ioe,Q(le(n).formatDate(le(s),"D")),1
41),b("span",Aoe,Q(le(n).formatDate(le(s),"YYYY")),1)])):X("",!0)]),_:1}),b("div",Doe,[be(yh,{name:"Clock",size:"17"}),be(gf,{modelValue:le(o),"onUpdate:modelValue":y[0]||(y[0]=w=>er(o)?o.value=w:null),modelModifiers:{number:!0},options:le(h),class:"vc-time-select-hours","align-right":""},null,8,["modelValue","options"]),le(x)>1?(k(),M(xe,{key:0},[Roe,be(gf,{modelValue:le(l),"onUpdate:modelValue":y[1]||(y[1]=w=>er(l)?l.value=w:null),modelModifiers:{number:!0},options:le(d).minutes,class:"vc-time-select-minutes","align-left":le(x)===2},null,8,["modelValue","options","align-left"])],64)):X("",!0),le(x)>2?(k(),M(xe,{key:1},[Ooe,be(gf,{modelValue:le(u),"onUpdate:modelValue":y[2]||(y[2]=w=>er(u)?u.value=w:null),modelModifiers:{number:!0},options:le(d).seconds,class:"vc-time-select-seconds","align-left":le(x)===3},null,8,["modelValue","options","align-left"])],64)):X("",!0),le(x)>3?(k(),M(xe,{key:2},[Loe,be(gf,{modelValue:le(c),"onUpdate:modelValue":y[3]||(y[3]=w=>er(c)?c.value=w:null),modelModifiers:{number:!0},options:le(d).milliseconds,class:"vc-time-select-milliseconds","align-left":""},null,8,["modelValue","options"])],64)):X("",!0),le(g)?X("",!0):(k(),Mt(gf,{key:3,modelValue:le(p),"onUpdate:modelValue":y[4]||(y[4]=w=>er(p)?p.value=w:null),options:le(m)},null,8,["modelValue","options"]))])],2))}}),K9=fr({__name:"DatePickerBase",setup(e){const{attributes:t,calendarRef:r,color:i,displayMode:n,isDateTimeMode:a,isTimeMode:s,isRange:o,onDayCl
41ick:l,onDayMouseEnter:u,onDayKeydown:c}=j4(),d=o.value?[0,1]:[0];return(h,f)=>le(s)?(k(),M("div",{key:0,class:pe(`vc-container vc-bordered vc-${le(i)} vc-${le(n)}`)},[(k(!0),M(xe,null,Me(le(d),p=>(k(),Mt(k6,{key:p,position:p},null,8,["position"]))),128))],2)):(k(),Mt(W9,{key:1,attributes:le(t),ref_key:"calendarRef",ref:r,onDayclick:le(l),onDaymouseenter:le(u),onDaykeydown:le(c)},{footer:_t(()=>[le(a)?(k(!0),M(xe,{key:0},Me(le(d),p=>(k(),Mt(k6,{key:p,position:p},null,8,["position"]))),128)):X("",!0),be(Wa,{name:"dp-footer"})]),_:1},8,["attributes","onDayclick","onDaymouseenter","onDaykeydown"]))}}),Foe={inheritAttrs:!1},zoe=fr({...Foe,__name:"DatePickerPopover",setup(e){const{datePickerPopoverId:t,color:r,displayMode:i,popoverRef:n,onPopoverBeforeShow:a,onPopoverAfterShow:s,onPopoverBeforeHide:o,onPopoverAfterHide:l}=j4();return(u,c)=>(k(),Mt(M1,{id:le(t),placement:"bottom-start",class:pe(`vc-date-picker-content vc-${le(r)} vc-${le(i)}`),ref_key:"popoverRef",ref:n,onBeforeShow:le(a),onAfterShow:le(s),onBeforeHide:le(o),onAfterHide:le(l)},{default:_t(()=>[be(K9,Gu(nh(u.$attrs)),null,16)]),_:1},8,["id","class","onBeforeShow","onAfterShow","onBeforeHide","onAfterHide"]))}}),Noe=fr({inheritAttrs:!1,emits:voe,props:yoe,components:{DatePickerBase:K9,DatePickerPopover:zoe},setup(e,t){const r=boe(e,t),i=An(h9(r,"calendarRef","popoverRef"));return{...r,slotCtx:i}}});function Boe(e,t,r,i,n,a){const s=qr("DatePickerPopover"),o=qr("DatePickerBase");return e.$slots.default?(k(),M(xe,{key:0},[ws(e.$slots,"default",Gu(nh(e.slotCtx))),be(s,Gu(nh(e.$attrs)),null,16)],64)):(k(),Mt(o,Gu(Ha({key:1},e.$attrs)),null,16))}const joe=pu(Noe,[["render",Boe]]),E6=Object.freeze(Object.defineProperty({__proto__:null,Calendar:W9,DatePicker:joe,Popover:M1,PopoverRow:V9},Symbol.toStringTag,{value:"Module"})),Uoe=(e,t={})=>{e.use(hae,t);const r=e.config.globalProperties.$VCalendar.componentPrefix;for(const i in E6){const n=E6[i];e.component(`${r}${i}`,n)}},Voe={install:Uoe},qoe="modulepreload",Goe=function(e){return"/build/"+e},P6={},Hoe=function(t,r,i){let n=Promise.resolve();if(r&&r.length>0){let s=function(u){return Promise.all(u.map(c=>Promise.resolve(c).then(d=>({status:"fulfilled",value:d}),d=>({status:"rejected",reason:d}))))};document.getElementsByTagName("link");const o=document.querySelector("meta[property=csp-nonce]"),l=(o==null?void 0:o.nonce)||(o==null?void 0:o.getAttribute("nonce"));n=s(r.map(u=>{if(u=Goe(u),u in P6)return;P6[u]=!0;const c=u.endsWith(".css"),d=c?'[rel="stylesheet"]':"";if(document.querySelector(`link[href="${u}"]${d}`))return;const h=document.createElement("link");if(h.rel=c?"stylesheet":qoe,c||(h.as="script"),h.crossOrigin="",h.href=u,l&&h.setAttribute("nonce",l),document.head.appendChild(h),c)return new Promise((f,p)=>{h.addEventListener("load",f),h.addEventListener("error",()=>p(new Error(`Unable to preload CSS for ${u}`)))})}))}function a(s){const o=new Event("vite:preloadError",{cancelable:!0});if(o.payload=s,window.dispatchEvent(o),!o.defaultPrevented)throw s}return n.then(s=>{for(const o of s||[])o.status==="rejected"&&a(o.reason);return t().catch(a)})},Yoe
vendor: 83,479 bytes, line 41
41={version:4,country_calling_codes:{1:["US","AG","AI","AS","BB","BM","BS","CA","DM","DO","GD","GU","JM","KN","KY","LC","MP","MS","PR","SX","TC","TT","VC","VG","VI"],7:["RU","KZ"],20:["EG"],27:["ZA"],30:["GR"],31:["NL"],32:["BE"],33:["FR"],34:["ES"],36:["HU"],39:["IT","VA"],40:["RO"],41:["CH"],43:["AT"],44:["GB","GG","IM","JE"],45:["DK"],46:["SE"],47:["NO","SJ"],48:["PL"],49:["DE"],51:["PE"],52:["MX"],53:["CU"],54:["AR"],55:["BR"],56:["CL"],57:["CO"],58:["VE"],60:["MY"],61:["AU","CC","CX"],62:["ID"],63:["PH"],64:["NZ"],65:["SG"],66:["TH"],81:["JP"],82:["KR"],84:["VN"],86:["CN"],90:["TR"],91:["IN"],92:["PK"],93:["AF"],94:["LK"],95:["MM"],98:["IR"],211:["SS"],212:["MA","EH"],213:["DZ"],216:["TN"],218:["LY"],220:["GM"],221:["SN"],222:["MR"],223:["ML"],224:["GN"],225:["CI"],226:["BF"],227:["NE"],228:["TG"],229:["BJ"],230:["MU"],231:["LR"],232:["SL"],233:["GH"],234:["NG"],235:["TD"],236:["CF"],237:["CM"],238:["CV"],239:["ST"],240:["GQ"],241:["GA"],242:["CG"],243:["CD"],244:["AO"],245:["GW"],246:["IO"],247:["AC"],248:["SC"],249:["SD"],250:["RW"],251:["ET"],252:["SO"],253:["DJ"],254:["KE"],255:["TZ"],256:["UG"],257:["BI"],258:["MZ"],260:["ZM"],261:["MG"],262:["RE","YT"],263:["ZW"],264:["NA"],265:["MW"],266:["LS"],267:["BW"],268:["SZ"],269:["KM"],290:["SH","TA"],291:["ER"],297:["AW"],298:["FO"],299:["GL"],350:["GI"],351:["PT"],352:["LU"],353:["IE"],354:["IS"],355:["AL"],356:["MT"],357:["CY"],358:["FI","AX"],359:["BG"],370:["LT"],371:["LV"],372:["EE"],373:["MD"],374:["AM"],375:["BY"],376:["AD"],377:["MC"],378:["SM"],380:["UA"],381:["RS"],382:["ME"],383:["XK"],385:["HR"],386:["SI"],387:["BA"],389:["MK"],420:["CZ"],421:["SK"],423:["LI"],500:["FK"],501:["BZ"],502:["GT"],503:["SV"],504:["HN"],505:["NI"],506:["CR"],507:["PA"],508:["PM"],509:["HT"],590:["GP","BL","MF"],591:["BO"],592:["GY"],593:["EC"],594:["GF"],595:["PY"],596:["MQ"],597:["SR"],598:["UY"],599:["CW","BQ"],670:["TL"],672:["NF"],673:["BN"],674:["NR"],675:["PG"],676:["TO"],677:["SB"],678:["VU"],679:["FJ"],680:["PW"],681:["WF"],682:["CK"],683:["NU"],685:["WS"],686:["KI"],687:["NC"],688:["TV"],689:["PF"],690:["TK"],691:["FM"],692:["MH"],850:["KP"],852:["HK"],853:["MO"],855:["KH"],856:["LA"],880:["BD"],886:["TW"],960:["MV"],961:["LB"],962:["JO"],963:["SY"],964:["IQ"],965:["KW"],966:["SA"],967:["YE"],968:["OM"],970:["PS"],971:["AE"],972:["IL"],973:["BH"],974:["QA"],975:["BT"],976:["MN"],977:["NP"],992:["TJ"],993:["TM"],994:["AZ"],995:["GE"],996:["KG"],998:["UZ"]},countries:{AC:["247","00","(?:[01589]\\d|[46])\\d{4}",[5,6]],AD:["376","00","(?:1|6\\d)\\d{7}|[135-9]\\d{5}",[6,8,9],[["(\\d{3})(\\d{3})","$1 $2",["[135-9]"]],["(\\d{4})(\\d{4})","$1 $2",["1"]],["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["6"]]]],AE:["971","00","(?:[4-7]\\d|9[0-689])\\d{7}|800\\d{2,9}|[2-4679]\\d{7}",[5,6,7,8,9,10,11,12],[["(\\d{3})(\\d{2,9})","$1 $2",["60|8"]],["(\\d)(\\d{3})(\\d{4})","$1 $2 $3",["[236]|[479][2-8]"],"0$1"],["(\\d{3})(\\d)(\\d{5})","$1 $2 $3",["[479]"]],["(\\d{2})(\\d{3})(\\d{4})","$1 $2 $3",["5"],"0$1"]],"0"],AF:["93","00","[2-7]\\d{8}",[9],[["(\\d{2})(\\d{3})(\\d{4})","$1 $2 $3",["[2-7]"],"0$1"]],"0"],AG:["1","011","(?:268|[58]\\d\\d|900)\\d{7}",[10],0,"1",0,"([457]\\d{6})$|1","268$1",0,"268"],AI:["1","011","(?:264|[58]\\d\\d|900)\\d{7}",[10],0,"1",0,"([2457]\\d{6})$|1","264$1",0,"264"],AL:["355","00","(?:700\\d\\d|900)\\d{3}|8\\d{5,7}|(?:[2-5]|6\\d)\\d{7}",[6,7,8,9],[["(\\d{3})(\\d{3,4})","$1 $2",["80|9"],"0$1"],["(\\d)(\\d{3})(\\d{4})","$1 $2 $3",["4[2-6]"],"0$1"],["(\\d{2})(\\d{3})(\\d{3})","$1 $2 $3",["[2358][2-5]|4"],"0$1"],["(\\d{3})(\\d{5})","$1 $2",["[23578]"],"0$1"],["(\\d{2})(\\d{3})(\\d{4})","$1 $2 $3",["6"],"0$1"]],"0"],AM:["374","00","(?:[1-489]\\d|55|60|77)\\d{6}",[8],[["(\\d{3})(\\d{2})(\\d{3})","$1 $2 $3",["[89]0"],"0 $1"],["(\\d{3})(\\d{5})","$1 $2",["2|3[12]"],"(0$1)"],["(\\d{2})(\\d{6})","$1 $2",["1|47"],"(0$1)"],["(\\d{2})(\\d{6})","$1 $2",["[3-9]"],"0$1"]],"0"],AO:["244","00","[29]\\d{8}",[9],[["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["[29]"]]]],AR:["54","00","(?:11|[89]\\d\\d)\\d{8}|[2368]\\d{9}",[10,11],[["(\\d{4})(\\d{2})(\\d{4})","$1 $2-$3",["2(?:2[024-9]|3[0-59]|47|6[245]|9[02-8])|3(?:3[28]|4[03-9]|5[2-46-8]|7[1-578]|8[2-9])","2(?:[23]02|6(?:[25]|4[6-8])|9(?:[02356]|4[02568]|72|8[23]))|3(?:3[28]|4(?:[04679]|3[5-8]|5[4-68]|8[2379])|5(?:[2467]|3[237]|8[2-5])|7[1-578]|8(?:[2469]|3[2578]|5[4-8]|7[36-8]|8[5-8]))|2(?:2[24-9]|3[1-59]|47)","2(?:[23]02|6(?:[25]|4(?:64|[78]))|9(?:[02356]|4(?:[0268]|5[2-6])|72|8[23]))|3(?:3[28]|4(?:[04679]|3[78]|5(?:4[46]|8)|8[2379])|5(?:[2467]|3[237]|8[23])|7[1-578]|8(?:[2469]|3[278]|5[56][46]|86[3-6]))|2(?:2[24-9]|3[1-59]|47)|38(?:[58][78]|7[378])|3(?:4[35][56]|58[45]|8(?:[38]5|54|76))[4-6]","2(?:[23]02|6(?:[25]|4(?:64|[78]))|9(?:[02356]|4(?:[0268]|5[2-6])|72|8[23]))|3(?:3[28]|4(?:[04679]|3(?:5(?:4[0-25689]|[56])|[78])|58|8[2379])|5(?:[2467]|3[237]|8(?:[23]|4(?:[45]|60)|5(?:4[0-39]|5|64)))|7[1-578]|8(?:[2469]|3[278]|54(?:4|5[13-7]|6[89])|86[3-6]))|2(?:2[24-9]|3[1-59]|47)|38(?:[58][78]|7[378])|3(?:454|85[56])[46]|3(?:4(?:36|5[56])|8(?:[38]5|76))[4-6]"],"0$1",1],["(\\d{2})(\\d{4})(\\d{4})","$1 $2-$3",["1"],"0$1",1],["(\\d{3})(\\d{3})(\\d{4})","$1-$2-$3",["[68]"],"0$1"],["(\\d{3})(\\d{3})(\\d{4})","$1 $2-$3",["[23]"],"0$1",1],["(\\d)(\\d{4})(\\d{2})(\\d{4})","$2 15-$3-$4",["9(?:2[2-469]|3[3-578])","9(?:2(?:2[024-9]|3[0-59]|47|6[245]|9[02-8])|3(?:3[28]|4[03-9]|5[2-46-8]|7[1-578]|8[2-9]))","9(?:2(?:[23]02|6(?:[25]|4[6-8])|9(?:[02356]|4[02568]|72|8[23]))|3(?:3[28]|4(?:[04679]|3[5-8]|5[4-68]|8[2379])|5(?:[2467]|3[237]|8[2-5])|7[1-578]|8(?:[2469]|3[2578]|5[4-8]|7[36-8]|8[5-8])))|92(?:2[24-9]|3[1-59]|47)","9(?:2(?:[23]02|6(?:[25]|4(?:64|[78]))|9(?:[02356]|4(?:[0268]|5[2-6])|72|8[23]))|3(?:3[28]|4(?:[04679]|3[78]|5(?:4[46]|8)|8[2379])|5(?:[2467]|3[237]|8[23])|7[1-578]|8(?:[2469]|3[278]|5(?:[56][46]|[78])|7[378]|8(?:6[3-6]|[78]))))|92(?:2[24-9]|3[1-59]|47)|93(?:4[35][56]|58[45]|8(?:[38]5|54|76))[4-6]","9(?:2(?:[23]02|6(?:[25]|4(?:64|[78]))|9(?:[02356]|4(?:[0268]|5[2-6])|72|8[23]))|3(?:3[28]|4(?:[04679]|3(?:5(?:4[0-25689]|[56])|[78])|5(?:4[46]|8)|8[2379])|5(?:[2467]|3[237]|8(?:[23]|4(?:[45]|60)|5(?:4[0-39]|5|64)))|7[1-578]|8(?:[2469]|3[278]|5(?:4(?:4|5[13-7]|6[89])|[56][46]|[78])|7[378]|8(?:6[3-6]|[78]))))|92(?:2[24-9]|3[1-59]|47)|93(?:4(?:36|5[56])|8(?:[38]5|76))[4-6]"],"0$1",0,"$1 $2 $3-$4"],["(\\d)(\\d{2})(\\d{4})(\\d{4})","$2 15-$3-$4",["91"],"0$1",0,"$1 $2 $3-$4"],["(\\d{3})(\\d{3})(\\d{5})","$1-$2-$3",["8"],"0$1"],["(\\d)(\\d{3})(\\d{3})(\\d{4})","$2 15-$3-$4",["9"],"0$1",0,"$1 $2 $3-$4"]],"0",0,"0?(?:(11|2(?:2(?:02?|[13]|2[13-79]|4[1-6]|5[2457]|6[124-8]|7[1-4]|8[13-6]|9[1267])|3(?:02?|1[467]|2[03-6]|3[13-8]|[49][2-6]|5[2-8]|[67])|4(?:7[3-578]|9)|6(?:[0136]|2[24-6]|4[6-8]?|5[15-8])|80|9(?:0[1-3]|[19]|2\\d|3[1-6]|4[02568]?|5[2-4]|6[2-46]|72?|8[23]?))|3(?:3(?:2[79]|6|8[2578])|4(?:0[0-24-9]|[12]|3[5-8]?|4[24-7]|5[4-68]?|6[02-9]|7[126]|8[2379]?|9[1-36-8])|5(?:1|2[1245]|3[237]?|4[1-46-9]|6[2-4]|7[1-6]|8[2-5]?)|6[24]|7(?:[069]|1[1568]|2[15]|3[145]|4[13]|5[14-8]|7[2-57]|8[126])|8(?:[01]|2[15-7]|3[2578]?|4[13-6]|5[4-8]?|6[1-357-9]|7[36-8]?|8[5-8]?|9[124])))15)?","9$1"],AS:["1","011","(?:[58]\\d\\d|684|900)\\d{7}",[10],0,"1",0,"([267]\\d{6})$|1","684$1",0,"684"],AT:["43","00","1\\d{3,12}|2\\d{6,12}|43(?:(?:0\\d|5[02-9])\\d{3,9}|2\\d{4,5}|[3467]\\d{4}|8\\d{4,6}|9\\d{4,7})|5\\d{4,12}|8\\d{7,12}|9\\d{8,12}|(?:[367]\\d|4[0-24-9])\\d{4,11}",[4,5,6,7,8,9,10,11,12,13],[["(\\d)(\\d{3,12})","$1 $2",["1(?:11|[2-9])"],"0$1"],["(\\d{3})(\\d{2})","$1 $2",["517"],"0$1"],["(\\d{2})(\\d{3,5})","$1 $2",["5[079]"],"0$1"],["(\\d{3})(\\d{3,10})","$1 $2",["(?:31|4)6|51|6(?:48|5[0-3579]|[6-9])|7(?:20|32|8)|[89]","(?:31|4)6|51|6(?:485|5[0-3579]|[6-9])|7(?:20|32|8)|[89]"],"0$1"],["(\\d{4})(\\d{3,9})","$1 $2",["[2-467]|5[2-6]"],"0$1"],["(\\d{2})(\\d{3})(\\d{3,4})","$1 $2 $3",["5"],"0$1"],["(\\d{2})(\\d{4})(\\d{4,7})","$1 $2 $3",["5"],"0$1"]],"0"],AU:["61","001[14-689]|14(?:1[14]|34|4[17]|[56]6|7[47]|88)0011","1(?:[0-79]\\d{7}(?:\\d(?:\\d{2})?)?|8[0-24-9]\\d{7})|[2-478]\\d{8}|1\\d{4,7}",[5,6,7,8,9,10,12],[["(\\d{2})(\\d{3,4})","$1 $2",["16"],"0$1"],["(\\d{2})(\\d{3})(\\d{2,4})","$1 $2 $3",["16"],"0$1"],["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["14|4"],"0$1"],["(\\d)(\\d{4})(\\d{4})","$1 $2 $3",["[2378]"],"(0$1)"],["(\\d{4})(\\d{3})(\\d{3})","$1 $2 $3",["1(?:30|[89])"]]],"0",0,"(183[12])|0",0,0,0,[["(?:(?:241|349)0\\d\\d|8(?:51(?:0(?:0[03-9]|[12479]\\d|3[2-9]|5[0-8]|6[1-9]|8[0-7])|1(?:[0235689]\\d|1[0-69]|4[0-589]|7[0-47-9])|2(?:0[0-79]|[18][13579]|2[14-9]|3[0-46-9]|[4-6]\\d|7[89]|9[0-4])|[34]\\d\\d)|91(?:(?:[0-58]\\d|6[0135-9])\\d|7(?:0[0-24-9]|[1-9]\\d)|9(?:[0-46-9]\\d|5[0-79]))))\\d{3}|(?:2(?:[0-26-9]\\d|3[0-8]|4[02-9]|5[0135-9])|3(?:[0-3589]\\d|4[0-578]|6[1-9]|7[0-35-9])|7(?:[013-57-9]\\d|2[0-8])|8(?:55|6[0-8]|[78]\\d|9[02-9]))\\d{6}",[9]],["4(?:79[01]|83[0-36-9]|95[0-3])\\d{5}|4(?:[0-36]\\d|4[047-9]|[58][0-24-9]|7[02-8]|9[0-47-9])\\d{6}",[9]],["180(?:0\\d{3}|2)\\d{3}",[7,10]],["190[0-26]\\d{6}",[10]],0,0,0,["163\\d{2,6}",[5,6,7,8,9]],["14(?:5(?:1[0458]|[23][458])|71\\d)\\d{4}",[9]],["13(?:00\\d{6}(?:\\d{2})?|45[0-4]\\d{3})|13\\d{4}",[6,8,10,12]]],"0011"],AW:["297","00","(?:[25-79]\\d\\d|800)\\d{4}",[7],[["(\\d{3})(\\d{4})","$1 $2",["[25-9]"]]]],AX:["358","00|99(?:[01469]|5(?:[14]1|3[23]|5[59]|77|88|9[09]))","2\\d{4,9}|35\\d{4,5}|(?:60\\d\\d|800)\\d{4,6}|7\\d{5,11}|(?:[14]\\d|3[0-46-9]|50)\\d{4,8}",[5,6,7,8,9,10,11,12],0,"0",0,0,0,0,"18",0,"00"],AZ:["994","00","365\\d{6}|(?:[124579]\\d|60|88)\\d{7}",[9],[["(\\d{3})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["90"],"0$1"],["(\\d{2})(\\d{3})(\\d{2})(\\d{2})","$1 $2 $3 $4",["1[28]|2|365|46","1[28]|2|365[45]|46","1[28]|2|365(?:4|5[02])|46"],"(0$1)"],["(\\d{2})(\\d{3})(\\d{2})(\\d{2})","$1 $2 $3 $4",["[13-9]"],"0$1"]],"0"],BA:["387","00","6\\d{8}|(?:[35689]\\d|49|70)\\d{6}",[8,9],[["(\\d{2})(\\d{3})(\\d{3})","$1 $2 $3",["6[1-3]|[7-9]"],"0$1"],["(\\d{2})(\\d{3})(\\d{3})","$1 $2-$3",["[3-5]|6[56]"],"0$1"],["(\\d{2})(\\d{2})(\\d{2})(\\d{3})","$1 $2 $3 $4",["6"],"0$1"]],"0"],BB:["1","011","(?:246|[58]\\d\\d|900)\\d{7}",[10],0,"1",0,"([2-9]\\d{6})$|1","246$1",0,"246"],BD:["880","00","[1-469]\\d{9}|8[0-79]\\d{7,8}|[2-79]\\d{8}|[2-9]\\d{7}|[3-9]\\d{6}|[57-9]\\d{5}",[6,7,8,9,10],[["(\\d{2})(\\d{4,6})","$1-$2",["31[5-8]|[459]1"],"0$1"],["(\\d{3})(\\d{3,7})","$1-$2",["3(?:[67]|8[013-9])|4(?:6[168]|7|[89][18])|5(?:6[128]|9)|6(?:[15]|28|4[14])|7[2-589]|8(?:0[014-9]|[12])|9[358]|(?:3[2-5]|4[235]|5[2-578]|6[0389]|76|8[3-7]|9[24])1|(?:44|66)[01346-9]"],"0$1"],["(\\d{4})(\\d{3,6})","$1-$2",["[13-9]|2[23]"],"0$1"],["(\\d)(\\d{7,8})","$1-$2",["2"],"0$1"]],"0"],BE:["32","00","4\\d{8}|[1-9]\\d{7}",[8,9],[["(\\d{3})(\\d{2})(\\d{3})","$1 $2 $3",["(?:80|9)0"],"0$1"],["(\\d)(\\d{3})(\\d{2})(\\d{2})","$1 $2 $3 $4",["[239]|4[23]"],"0$1"],["(\\d{2})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["[15-8]"],"0$1"],["(\\d{3})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["4"],"0$1"]],"0"],BF:["226","00","(?:[025-7]\\d|44)\\d{6}",[8],[["(\\d{2})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["[024-7]"]]]],BG:["359","00","00800\\d{7}|[2-7]\\d{6,7}|[89]\\d{6,8}|2\\d{5}",[6,7,8,9,12],[["(\\d)(\\d)(\\d{2})(\\d{2})","$1 $2 $3 $4",["2"],"0$1"],["(\\d{3})(\\d{4})","$1 $2",["43[1-6]|70[1-9]"],"0$1"],["(\\d)(\\d{3})(\\d{3,4})","$1 $2 $3",["2"],"0$1"],["(\\d{2})(\\d{3})(\\d{2,3})","$1 $2 $3",["[356]|4[124-7]|7[1-9]|8[1-6]|9[1-7]"],"0$1"],["(\\d{3})(\\d{2})(\\d{3})","$1 $2 $3",["(?:70|8)0"],"0$1"],["(\\d{3})(\\d{3})(\\d{2})","$1 $2 $3",["43[1-7]|7"],"0$1"],["(\\d{2})(\\d{3})(\\d{3,4})","$1 $2 $3",["[48]|9[08]"],"0$1"],["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["9"],"0$1"]],"0"],BH:["973","00","[136-9]\\d{7}",[8],[["(\\d{4})(\\d{4})","$1 $2",["[13679]|8[02-4679]"]]]],BI:["257","00","(?:[267]\\d|31)\\d{6}",[8],[["(\\d{2})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["[2367]"]]]],BJ:["229","00","(?:01\\d|8)\\d{7}",[8,10],[["(\\d{2})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["8"]],["(\\d{2})(\\d{2})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4 $5",["0"]]]],BL:["590","00","(?:590\\d|7090)\\d{5}|(?:69|80|9\\d)\\d{7}",[9],0,"0",0,0,0,0,0,[["590(?:2[7-9]|3[3-7]|5[12]|87)\\d{4}"],["(?:69(?:0\\d\\d|1(?:2[2-9]|3[0-5])|4(?:0[89]|1[2-6]|9\\d)|6(?:1[016-9]|5[0-4]|[67]\\d))|7090[0-4])\\d{4}"],["80[0-5]\\d{6}"],0,0,0,0,0,["9(?:(?:39[5-7]|76[018])\\d|475[0-6])\\d{4}"]]],BM:["1","011","(?:441|[58]\\d\\d|900)\\d{7}",[10],0,"1",0,"([2-9]\\d{6})$|1","441$1",0,"441"],BN:["673","00","[2-578]\\d{6}",[7],[["(\\d{3})(\\d{4})","$1 $2",["[2-578]"]]]],BO:["591","00(?:1\\d)?","8001\\d{5}|(?:[2-467]\\d|50)\\d{6}",[8,9],[["(\\d)(\\d{7})","$1 $2",["[235]|4[46]"]],["(\\d{8})","$1",["[67]"]],["(\\d{3})(\\d{2})(\\d{4})","$1 $2 $3",["8"]]],"0",0,"0(1\\d)?"],BQ:["599","00","(?:[34]1|7\\d)\\d{5}",[7],0,0,0,0,0,0,"[347]"],BR:["55","00(?:1[245]|2[1-35]|31|4[13]|[56]5|99)","[1-467]\\d{9,10}|55[0-46-9]\\d{8}|[34]\\d{7}|55\\d{7,8}|(?:5[0-46-9]|[89]\\d)\\d{7,9}",[8,9,10,11],[["(\\d{4})(\\d{4})","$1-$2",["300|4(?:0[02]|37|86)","300|4(?:0(?:0|20)|370|864)"]],["(\\d{3})(\\d{2,3})(\\d{4})","$1 $2 $3",["(?:[358]|90)0"],"0$1"],["(\\d{2})(\\d{4})(\\d{4})","$1 $2-$3",["(?:[14689][1-9]|2[12478]|3[1-578]|5[13-5]|7[13-579])[2-57]"],"($1)"],["(\\d{2})(\\d{5})(\\d{4})","$1 $2-$3",["[16][1-9]|[2-57-9]"],"($1)"]],"0",0,"(?:0|90)(?:(1[245]|2[1-35]|31|4[13]|[56]5|99)(\\d{10,11}))?","$2"],BS:["1","011","(?:242|[58]\\d\\d|900)\\d{7}",[10],0,"1",0,"([3-8]\\d{6})$|1","242$1",0,"242"],BT:["975","00","[178]\\d{7}|[2-8]\\d{6}",[7,8],[["(\\d)(\\d{3})(\\d{3})","$1 $2 $3",["[2-6]|7[246]|8[2-4]"]],["(\\d{2})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["1[67]|[78]"]]]],BW:["267","00","(?:0800|(?:[37]|800)\\d)\\d{6}|(?:[2-6]\\d|90)\\d{5}",[7,8,10],[["(\\d{2})(\\d{5})","$1 $2",["90"]],["(\\d{3})(\\d{4})","$1 $2",["[24-6]|3[15-9]"]],["(\\d{2})(\\d{3})(\\d{3})","$1 $2 $3",["[37]"]],["(\\d{4})(\\d{3})(\\d{3})","$1 $2 $3",["0"]],["(\\d{3})(\\d{4})(\\d{3})","$1 $2 $3",["8"]]]],BY:["375","810","(?:[12]\\d|33|44|902)\\d{7}|8(?:0[0-79]\\d{5,7}|[1-7]\\d{9})|8(?:1[0-489]|[5-79]\\d)\\d{7}|8[1-79]\\d{6,7}|8[0-79]\\d{5}|8\\d{5}",[6,7,8,9,10,11],[["(\\d{3})(\\d{3})","$1 $2",["800"],"8 $1"],["(\\d{3})(\\d{2})(\\d{2,4})","$1 $2 $3",["800"],"8 $1"],["(\\d{4})(\\d{2})(\\d{3})","$1 $2-$3",["1(?:5[169]|6[3-5]|7[179])|2(?:1[35]|2[34]|3[3-5])","1(?:5[169]|6(?:3[1-3]|4|5[125])|7(?:1[3-9]|7[0-24-6]|9[2-7]))|2(?:1[35]|2[34]|3[3-5])"],"8 0$1"],["(\\d{3})(\\d{2})(\\d{2})(\\d{2})","$1 $2-$3-$4",["1(?:[56]|7[467])|2[1-3]"],"8 0$1"],["(\\d{2})(\\d{3})(\\d{2})(\\d{2})","$1 $2-$3-$4",["[1-4]"],"8 0$1"],["(\\d{3})(\\d{3,4})(\\d{4})","$1 $2 $3",["[89]"],"8 $1"]],"8",0,"0|80?",0,0,0,0,"8~10"],BZ:["501","00","(?:0800\\d|[2-8])\\d{6}",[7,11],[["(\\d{3})(\\d{4})","$1-$2",["[2-8]"]],["(\\d)(\\d{3})(\\d{4})(\\d{3})","$1-$2-$3-$4",["0"]]]],CA:["1","011","[2-9]\\d{9}|3\\d{6}",[7,10],0,"1",0,0,0,0,0,[["(?:2(?:04|[23]6|[48]9|5[07]|63)|3(?:06|43|54|6[578]|82)|4(?:03|1[68]|[26]8|3[178]|50|74)|5(?:06|1[49]|48|79|8[147])|6(?:04|[18]3|39|47|72)|7(?:0[59]|42|53|78|8[02])|8(?:[06]7|19|25|7[39])|9(?:0[25]|42))[2-9]\\d{6}",[10]],["",[10]],["8(?:00|33|44|55|66|77|88)[2-9]\\d{6}",[10]],["900[2-9]\\d{6}",[10]],["52(?:3(?:[2-46-9][02-9]\\d|5(?:[02-46-9]\\d|5[0-46-9]))|4(?:[2-478][02-9]\\d|5(?:[034]\\d|2[024-9]|5[0-46-9])|6(?:0[1-9]|[2-9]\\d)|9(?:[05-9]\\d|2[0-5]|49)))\\d{4}|52[34][2-9]1[02-9]\\d{4}|(?:5(?:2[125-9]|3[23]|44|66|77|88)|6(?:22|33))[2-9]\\d{6}",[10]],0,["310\\d{4}",[7]],0,["600[2-9]\\d{6}",[10]]]],CC:["61","001[14-689]|14(?:1[14]|34|4[17]|[56]6|7[47]|88)0011","1(?:[0-79]\\d{8}(?:\\d{2})?|8[0-24-9]\\d{7})|[148]\\d{8}|1\\d{5,7}",[6,7,8,9,10,12],0,"0",0,"([59]\\d{7})$|0","8$1",0,0,[["8(?:51(?:0(?:02|31|60|89)|1(?:18|76)|223)|91(?:0(?:1[0-2]|29)|1(?:[28]2|50|79)|2(?:10|64)|3(?:[06]8|22)|4[29]8|62\\d|70[23]|959))\\d{3}",[9]],["4(?:79[01]|83[0-36-9]|95[0-3])\\d{5}|4(?:[0-36]\\d|4[047-9]|[58][0-24-9]|7[02-8]|9[0-47-9])\\d{6}",[9]],["180(?:0\\d{3}|2)\\d{3}",[7,10]],["190[0-26]\\d{6}",[10]],0,0,0,0,["14(?:5(?:1[0458]|[23][458])|71\\d)\\d{4}",[9]],["13(?:00\\d{6}(?:\\d{2})?|45[0-4]\\d{3})|13\\d{4}",[6,8,10,12]]],"0011"],CD:["243","00","(?:(?:[189]|5\\d)\\d|2)\\d{7}|[1-68]\\d{6}",[7,8,9,10],[["(\\d{2})(\\d{2})(\\d{3})","$1 $2 $3",["88"],"0$1"],["(\\d{2})(\\d{5})","$1 $2",["[1-6]"],"0$1"],["(\\d{2})(\\d{2})(\\d{4})","$1 $2 $3",["2"],"0$1"],["(\\d{2})(\\d{3})(\\d{4})","$1 $2 $3",["1"],"0$1"],["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["[89]"],"0$1"],["(\\d{2})(\\d{2})(\\d{3})(\\d{3})","$1 $2 $3 $4",["5"],"0$1"]],"0"],CF:["236","00","8776\\d{4}|(?:[27]\\d|61)\\d{6}",[8],[["(\\d{2})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["[26-8]"]]]],CG:["242","00","222\\d{6}|(?:0\\d|80)\\d{7}",[9],[["(\\d)(\\d{4})(\\d{4})","$1 $2 $3",["8"]],["(\\d{2})(\\d{3})(\\d{4})","$1 $2 $3",["[02]"]]]],CH:["41","00","8\\d{11}|[2-9]\\d{8}",[9,12],[["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["8[047]|90"],"0$1"],["(\\d{2})(\\d{3})(\\d{2})(\\d{2})","$1 $2 $3 $4",["[2-79]|81"],"0$1"],["(\\d{3})(\\d{2})(\\d{3})(\\d{2})(\\d{2})","$1 $2 $3 $4 $5",["8"],"0$1"]],"0"],CI:["225","00","[02]\\d{9}",[10],[["(\\d{2})(\\d{2})(\\d)(\\d{5})","$1 $2 $3 $4",["2"]],["(\\d{2})(\\d{2})(\\d{2})(\\d{4})","$1 $2 $3 $4",["0"]]]],CK:["682","00","[2-578]\\d{4}",[5],[["(\\d{2})(\\d{3})","$1 $2",["[2-578]"]]]],CL:["56","(?:0|1(?:1[0-69]|2[02-5]|5[13-58]|69|7[0167]|8[018]))0","12300\\d{6}|6\\d{9,10}|[2-9]\\d{8}",[9,10,11],[["(\\d{5})(\\d{4})","$1 $2",["219","2196"],"($1)"],["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["60|809"]],["(\\d{2})(\\d{3})(\\d{4})","$1 $2 $3",["44"]],["(\\d)(\\d{4})(\\d{4})","$1 $2 $3",["2[1-36]"],"($1)"],["(\\d)(\\d{4})(\\d{4})","$1 $2 $3",["9(?:10|[2-9])"]],["(\\d{2})(\\d{3})(\\d{4})","$1 $2 $3",["3[2-5]|[47]|5[1-3578]|6[13-57]|8(?:0[1-8]|[1-9])"],"($1)"],["(\\d{3})(\\d{3})(\\d{3,4})","$1 $2 $3",["60|8"]],["(\\d{4})(\\d{3})(\\d{4})","$1 $2 $3",["1"]],["(\\d{3})(\\d{3})(\\d{2})(\\d{3})","$1 $2 $3 $4",["60"]]]],CM:["237","00","[26]\\d{8}|88\\d{6,7}",[8,9],[["(\\d{2})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["88"]],["(\\d)(\\d{2})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4 $5",["[26]|88"]]]],CN:["86","00|1(?:[12]\\d|79)\\d\\d00","(?:(?:1[03-689]|2\\d)\\d\\d|6)\\d{8}|1\\d{10}|[126]\\d{6}(?:\\d(?:\\d{2})?)?|86\\d{5,6}|(?:[3-579]\\d|8[0-57-9])\\d{5,9}",[7,8,9,10,11,12],[["(\\d{2})(\\d{5,6})","$1 $2",["(?:10|2[0-57-9])[19]|3(?:[157]|35|49|9[1-68])|4(?:1[124-9]|2[179]|6[47-9]|7|8[23])|5(?:[1357]|2[37]|4[36]|6[1-46]|80)|6(?:3[1-5]|6[0238]|9[12])|7(?:01|[1579]|2[248]|3[014-9]|4[3-6]|6[023689])|8(?:07|1[236-8]|2[5-7]|[37]|8[36-8]|9[1-8])|9(?:0[1-3689]|1[1-79]|3|4[13]|5[1-5]|7[0-79]|9[0-35-9])|(?:4[35]|59|85)[1-9]","(?:10|2[0-57-9])(?:1[02]|9[56])|8078|(?:3(?:[157]\\d|35|49|9[1-68])|4(?:1[124-9]|2[179]|[35][1-9]|6[47-9]|7\\d|8[23])|5(?:[1357]\\d|2[37]|4[36]|6[1-46]|80|9[1-9])|6(?:3[1-5]|6[0238]|9[12])|7(?:01|[1579]\\d|2[248]|3[014-9]|4[3-6]|6[023689])|8(?:1[236-8]|2[5-7]|[37]\\d|5[1-9]|8[36-8]|9[1-8])|9(?:0[1-3689]|1[1-79]|3\\d|4[13]|5[1-5]|7[0-79]|9[0-35-9]))1","10(?:1(?:0|23)|9[56])|2[0-57-9](?:1(?:00|23)|9[56])|80781|(?:3(?:[157]\\d|35|49|9[1-68])|4(?:1[124-9]|2[179]|[35][1-9]|6[47-9]|7\\d|8[23])|5(?:[1357]\\d|2[37]|4[36]|6[1-46]|80|9[1-9])|6(?:3[1-5]|6[0238]|9[12])|7(?:01|[1579]\\d|2[248]|3[014-9]|4[3-6]|6[023689])|8(?:1[236-8]|2[5-7]|[37]\\d|5[1-9]|8[36-8]|9[1-8])|9(?:0[1-3689]|1[1-79]|3\\d|4[13]|5[1-5]|7[0-79]|9[0-35-9]))12","10(?:1(?:0|23)|9[56])|2[0-57-9](?:1(?:00|23)|9[56])|807812|(?:3(?:[157]\\d|35|49|9[1-68])|4(?:1[124-9]|2[179]|[35][1-9]|6[47-9]|7\\d|8[23])|5(?:[1357]\\d|2[37]|4[36]|6[1-46]|80|9[1-9])|6(?:3[1-5]|6[0238]|9[12])|7(?:01|[1579]\\d|2[248]|3[014-9]|4[3-6]|6[023689])|8(?:1[236-8]|2[5-7]|[37]\\d|5[1-9]|8[36-8]|9[1-8])|9(?:0[1-3689]|1[1-79]|3\\d|4[13]|5[1-5]|7[0-79]|9[0-35-9]))123","10(?:1(?:0|23)|9[56])|2[0-57-9](?:1(?:00|23)|9[56])|(?:3(?:[157]\\d|35|49|9[1-68])|4(?:1[124-9]|2[179]|[35][1-9]|6[47-9]|7\\d|8[23])|5(?:[1357]\\d|2[37]|4[36]|6[1-46]|80|9[1-9])|6(?:3[1-5]|6[0238]|9[12])|7(?:01|[1579]\\d|2[248]|3[014-9]|4[3-6]|6[023689])|8(?:078|1[236-8]|2[5-7]|[37]\\d|5[1-9]|8[36-8]|9[1-8])|9(?:0[1-3689]|1[1-79]|3\\d|4[13]|5[1-5]|7[0-79]|9[0-35-9]))123"],"0$1"],["(\\d{3})(\\d{5,6})","$1 $2",["3(?:[157]|35|49|9[1-68])|4(?:[17]|2[179]|6[47-9]|8[23])|5(?:[1357]|2[37]|4[36]|6[1-46]|80)|6(?:3[1-5]|6[0238]|9[12])|7(?:01|[1579]|2[248]|3[014-9]|4[3-6]|6[023689])|8(?:1[236-8]|2[5-7]|[37]|8[36-8]|9[1-8])|9(?:0[1-3689]|1[1-79]|[379]|4[13]|5[1-5])|(?:4[35]|59|85)[1-9]","(?:3(?:[157]\\d|35|49|9[1-68])|4(?:[17]\\d|2[179]|[35][1-9]|6[47-9]|8[23])|5(?:[1357]\\d|2[37]|4[36]|6[1-46]|80|9[1-9])|6(?:3[1-5]|6[0238]|9[12])|7(?:01|[1579]\\d|2[248]|3[014-9]|4[3-6]|6[023689])|8(?:1[236-8]|2[5-7]|[37]\\d|5[1-9]|8[36-8]|9[1-8])|9(?:0[1-3689]|1[1-79]|[379]\\d|4[13]|5[1-5]))[19]","85[23](?:10|95)|(?:3(?:[157]\\d|35|49|9[1-68])|4(?:[17]\\d|2[179]|[35][1-9]|6[47-9]|8[23])|5(?:[1357]\\d|2[37]|4[36]|6[1-46]|80|9[1-9])|6(?:3[1-5]|6[0238]|9[12])|7(?:01|[1579]\\d|2[248]|3[014-9]|4[3-6]|6[023689])|8(?:1[236-8]|2[5-7]|[37]\\d|5[14-9]|8[36-8]|9[1-8])|9(?:0[1-3689]|1[1-79]|[379]\\d|4[13]|5[1-5]))(?:10|9[56])","85[23](?:100|95)|(?:3(?:[157]\\d|35|49|9[1-68])|4(?:[17]\\d|2[179]|[35][1-9]|6[47-9]|8[23])|5(?:[1357]\\d|2[37]|4[36]|6[1-46]|80|9[1-9])|6(?:3[1-5]|6[0238]|9[12])|7(?:01|[1579]\\d|2[248]|3[014-9]|4[3-6]|6[023689])|8(?:1[236-8]|2[5-7]|[37]\\d|5[14-9]|8[36-8]|9[1-8])|9(?:0[1-3689]|1[1-79]|[379]\\d|4[13]|5[1-5]))(?:100|9[56])"],"0$1"],["(\\d{3})(\\d{3})(\\d{4})","$1 $2 $3",["(?:4|80)0"]],["(\\d{2})(\\d{4})(\\d{4})","$1 $2 $3",["10|2(?:[02-57-9]|1[1-9])","10|2(?:[02-57-9]|1[1-9])","10[0-79]|2(?:[02-57-9]|1[1-79])|(?:10|21)8(?:0[1-9]|[1-9])"],"0$1",1],["(\\d{3})(\\d{3})(\\d{4})","$1 $2 $3",["3(?:[3-59]|7[02-68])|4(?:[26-8]|3[3-9]|5[2-9])|5(?:3[03-9]|[468]|7[028]|9[2-46-9])|6|7(?:[0-247]|3[04-9]|5[0-4689]|6[2368])|8(?:[1-358]|9[1-7])|9(?:[013479]|5[1-5])|(?:[34]1|55|79|87)[02-9]"],"0$1",1],["(\\d{3})(\\d{7,8})","$1 $2",["9"]],["(\\d{4})(\\d{3})(\\d{4})","$1 $2 $3",["80"],"0$1",1],["(\\d{3})(\\d{4})(\\d{4})","$1 $2 $3",["[3-578]"],"0$1",1],["(\\d{3})(\\d{4})(\\d{4})","$1 $2 $3",["1[3-9]"]],["(\\d{2})(\\d{3})(\\d{3})(\\d{4})","$1 $2 $3 $4",["[12]"],"0$1",1]],"0",0,"(1(?:[12]\\d|79)\\d\\d)|0",0,0,0,0,"00"],CO:["57","00(?:4(?:[14]4|56)|[579])","(?:46|60\\d\\d)\\d{6}|(?:1\\d|[39])\\d{9}",[8,10,11],[["(\\d{4})(\\d{4})","$1 $2",["46"]],["(\\d{3})(\\d{7})","$1 $2",["6|90"],"($1)"],["(\\d{3})(\\d{7})","$1 $2",["3[0-357]|9[14]"]],["(\\d)(\\d{3})(\\d{7})","$1-$2-$3",["1"],"0$1",0,"$1 $2 $3"]],"0",0,"0([3579]|4(?:[14]4|56))?"],CR:["506","00","(?:8\\d|90)\\d{8}|(?:[24-8]\\d{3}|3005)\\d{4}",[8,10],[["(\\d{4})(\\d{4})","$1 $2",["[2-7]|8[3-9]"]],["(\\d{3})(\\d{3})(\\d{4})","$1-$2-$3",["[89]"]]],0,0,"(19(?:0[0-2468]|1[09]|20|66|77|99))"],CU:["53","119","(?:[2-7]|8\\d\\d)\\d{7}|[2-47]\\d{6}|[34]\\d{5}",[6,7,8,10],[["(\\d{2})(\\d{4,6})","$1 $2",["2[1-4]|[34]"],"(0$1)"],["(\\d)(\\d{6,7})","$1 $2",["7"],"(0$1)"],["(\\d)(\\d{7})","$1 $2",["[56]"],"0$1"],["(\\d{3})(\\d{7})","$1 $2",["8"],"0$1"]],"0"],CV:["238","0","(?:[2-59]\\d\\d|800)\\d{4}",[7],[["(\\d{3})(\\d{2})(\\d{2})","$1 $2 $3",["[2-589]"]]]],CW:["599","00","(?:[34]1|60|(?:7|9\\d)\\d)\\d{5}",[7,8],[["(\\d{3})(\\d{4})","$1 $2",["[3467]"]],["(\\d)(\\d{3})(\\d{4})","$1 $2 $3",["9[4-8]"]]],0,0,0,0,0,"[69]"],CX:["61","001[14-689]|14(?:1[14]|34|4[17]|[56]6|7[47]|88)0011","1(?:[0-79]\\d{8}(?:\\d{2})?|8[0-24-9]\\d{7})|[148]\\d{8}|1\\d{5,7}",[6,7,8,9,10,12],0,"0",0,"([59]\\d{7})$|0","8$1",0,0,[["8(?:51(?:0(?:01|30|59|88)|1(?:17|46|75)|2(?:22|35))|91(?:00[6-9]|1(?:[28]1|49|78)|2(?:09|63)|3(?:12|26|75)|4(?:56|97)|64\\d|7(?:0[01]|1[0-2])|958))\\d{3}",[9]],["4(?:79[01]|83[0-36-9]|95[0-3])\\d{5}|4(?:[0-36]\\d|4[047-9]|[58][0-24-9]|7[02-8]|9[0-47-9])\\d{6}",[9]],["180(?:0\\d{3}|2)\\d{3}",[7,10]],["190[0-26]\\d{6}",[10]],0,0,0,0,["14(?:5(?:1[0458]|[23][458])|71\\d)\\d{4}",[9]],["13(?:00\\d{6}(?:\\d{2})?|45[0-4]\\d{3})|13\\d{4}",[6,8,10,12]]],"0011"],CY:["357","00","(?:[279]\\d|[58]0)\\d{6}",[8],[["(\\d{2})(\\d{6})","$1 $2",["[257-9]"]]]],CZ:["420","00","(?:[2-578]\\d|60)\\d{7}|9\\d{8,11}",[9,10,11,12],[["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["[2-8]|9[015-7]"]],["(\\d{2})(\\d{3})(\\d{3})(\\d{2})","$1 $2 $3 $4",["96"]],["(\\d{2})(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3 $4",["9"]],["(\\d{3})(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3 $4",["9"]]]],DE:["49","00","[2579]\\d{5,14}|49(?:[34]0|69|8\\d)\\d\\d?|49(?:37|49|60|7[089]|9\\d)\\d{1,3}|49(?:2[024-9]|3[2-689]|7[1-7])\\d{1,8}|(?:1|[368]\\d|4[0-8])\\d{3,13}|49(?:[015]\\d|2[13]|31|[46][1-8])\\d{1,9}",[4,5,6,7,8,9,10,11,12,13,14,15],[["(\\d{2})(\\d{3,13})","$1 $2",["3[02]|40|[68]9"],"0$1"],["(\\d{3})(\\d{3,12})","$1 $2",["2(?:0[1-389]|1[124]|2[18]|3[14])|3(?:[35-9][15]|4[015])|906|(?:2[4-9]|4[2-9]|[579][1-9]|[68][1-8])1","2(?:0[1-389]|12[0-8])|3(?:[35-9][15]|4[015])|906|2(?:[13][14]|2[18])|(?:2[4-9]|4[2-9]|[579][1-9]|[68][1-8])1"],"0$1"],["(\\d{4})(\\d{2,11})","$1 $2",["[24-6]|3(?:[3569][02-46-9]|4[2-4679]|7[2-467]|8[2-46-8])|70[2-8]|8(?:0[2-9]|[1-8])|90[7-9]|[79][1-9]","[24-6]|3(?:3(?:0[1-467]|2[127-9]|3[124578]|7[1257-9]|8[1256]|9[145])|4(?:2[135]|4[13578]|9[1346])|5(?:0[14]|2[1-3589]|6[1-4]|7[13468]|8[13568])|6(?:2[1-489]|3[124-6]|6[13]|7[12579]|8[1-356]|9[135])|7(?:2[1-7]|4[145]|6[1-5]|7[1-4])|8(?:21|3[1468]|6|7[1467]|8[136])|9(?:0[12479]|2[1358]|4[134679]|6[1-9]|7[136]|8[147]|9[1468]))|70[2-8]|8(?:0[2-9]|[1-8])|90[7-9]|[79][1-9]|3[68]4[1347]|3(?:47|60)[1356]|3(?:3[46]|46|5[49])[1246]|3[4579]3[1357]"],"0$1"],["(\\d{3})(\\d{4})","$1 $2",["138"],"0$1"],["(\\d{5})(\\d{2,10})","$1 $2",["3"],"0$1"],["(\\d{3})(\\d{5,11})","$1 $2",["181"],"0$1"],["(\\d{3})(\\d)(\\d{4,10})","$1 $2 $3",["1(?:3|80)|9"],"0$1"],["(\\d{3})(\\d{7,8})","$1 $2",["1[67]"],"0$1"],["(\\d{3})(\\d{7,12})","$1 $2",["8"],"0$1"],["(\\d{5})(\\d{6})","$1 $2",["185","1850","18500"],"0$1"],["(\\d{3})(\\d{4})(\\d{4})","$1 $2 $3",["7"],"0$1"],["(\\d{4})(\\d{7})","$1 $2",["18[68]"],"0$1"],["(\\d{4})(\\d{7})","$1 $2",["15[1279]"],"0$1"],["(\\d{5})(\\d{6})","$1 $2",["15[03568]","15(?:[0568]|3[13])"],"0$1"],["(\\d{3})(\\d{8})","$1 $2",["18"],"0$1"],["(\\d{3})(\\d{2})(\\d{7,8})","$1 $2 $3",["1(?:6[023]|7)"],"0$1"],["(\\d{4})(\\d{2})(\\d{7})","$1 $2 $3",["15[279]"],"0$1"],["(\\d{3})(\\d{2})(\\d{8})","$1 $2 $3",["15"],"0$1"]],"0"],DJ:["253","00","(?:2\\d|77)\\d{6}",[8],[["(\\d{2})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["[27]"]]]],DK:["45","00","[2-9]\\d{7}",[8],[["(\\d{2})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["[2-9]"]]]],DM:["1","011","(?:[58]\\d\\d|767|900)\\d{7}",[10],0,"1",0,"([2-7]\\d{6})$|1","767$1",0,"767"],DO:["1","011","(?:[58]\\d\\d|900)\\d{7}",[10],0,"1",0,0,0,0,"8001|8[024]9"],DZ:["213","00","(?:[1-4]|[5-79]\\d|80)\\d{7}",[8,9],[["(\\d{2})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["[1-4]"],"0$1"],["(\\d{2})(\\d{3})(\\d{2})(\\d{2})","$1 $2 $3 $4",["9"],"0$1"],["(\\d{3})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["[5-8]"],"0$1"]],"0"],EC:["593","00","1\\d{9,10}|(?:[2-7]|9\\d)\\d{7}",[8,9,10,11],[["(\\d)(\\d{3})(\\d{4})","$1 $2-$3",["[2-7]"],"(0$1)",0,"$1-$2-$3"],["(\\d{2})(\\d{3})(\\d{4})","$1 $2 $3",["9"],"0$1"],["(\\d{4})(\\d{3})(\\d{3,4})","$1 $2 $3",["1"]]],"0"],EE:["372","00","8\\d{9}|[4578]\\d{7}|(?:[3-8]\\d|90)\\d{5}",[7,8,10],[["(\\d{3})(\\d{4})","$1 $2",["[369]|4[3-8]|5(?:[0-2]|5[0-478]|6[45])|7[1-9]|88","[369]|4[3-8]|5(?:[02]|1(?:[0-8]|95)|5[0-478]|6(?:4[0-4]|5[1-589]))|7[1-9]|88"]],["(\\d{4})(\\d{3,4})","$1 $2",["[45]|8(?:00|[1-49])","[45]|8(?:00[1-9]|[1-49])"]],["(\\d{2})(\\d{2})(\\d{4})","$1 $2 $3",["7"]],["(\\d{4})(\\d{3})(\\d{3})","$1 $2 $3",["8"]]]],EG:["20","00","[189]\\d{8,9}|[24-6]\\d{8}|[135]\\d{7}",[8,9,10],[["(\\d)(\\d{7,8})","$1 $2",["[23]"],"0$1"],["(\\d{2})(\\d{6,7})","$1 $2",["1[35]|[4-6]|8[2468]|9[235-7]"],"0$1"],["(\\d{3})(\\d{3})(\\d{4})","$1 $2 $3",["[89]"],"0$1"],["(\\d{2})(\\d{8})","$1 $2",["1"],"0$1"]],"0"],EH:["212","00","[5-8]\\d{8}",[9],0,"0",0,0,0,0,0,[["528[89]\\d{5}"],["(?:6(?:[0-79]\\d|8[0-247-9])|7(?:[016-8]\\d|2[0-8]|5[0-5]))\\d{6}"],["80[0-7]\\d{6}"],["89\\d{7}"],0,0,0,0,["(?:592(?:4[0-2]|93)|80[89]\\d\\d)\\d{4}"]]],ER:["291","00","[178]\\d{6}",[7],[["(\\d)(\\d{3})(\\d{3})","$1 $2 $3",["[178]"],"0$1"]],"0"],ES:["34","00","[5-9]\\d{8}",[9],[["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["[89]00"]],["(\\d{3})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["[5-9]"]]]],ET:["251","00","(?:11|[2-579]\\d)\\d{7}",[9],[["(\\d{2})(\\d{3})(\\d{4})","$1 $2 $3",["[1-579]"],"0$1"]],"0"],FI:["358","00|99(?:[01469]|5(?:[14]1|3[23]|5[59]|77|88|9[09]))","[1-35689]\\d{4}|7\\d{10,11}|(?:[124-7]\\d|3[0-46-9])\\d{8}|[1-9]\\d{5,8}",[5,6,7,8,9,10,11,12],[["(\\d{5})","$1",["20[2-59]"],"0$1"],["(\\d{3})(\\d{3,7})","$1 $2",["(?:[1-3]0|[68])0|70[07-9]"],"0$1"],["(\\d{2})(\\d{4,8})","$1 $2",["[14]|2[09]|50|7[135]"],"0$1"],["(\\d{2})(\\d{6,10})","$1 $2",["7"],"0$1"],["(\\d)(\\d{4,9})","$1 $2",["(?:19|[2568])[1-8]|3(?:0[1-9]|[1-9])|9"],"0$1"]],"0",0,0,0,0,"1[03-79]|[2-9]",0,"00"],FJ:["679","0(?:0|52)","45\\d{5}|(?:0800\\d|[235-9])\\d{6}",[7,11],[["(\\d{3})(\\d{4})","$1 $2",["[235-9]|45"]],["(\\d{4})(\\d{3})(\\d{4})","$1 $2 $3",["0"]]],0,0,0,0,0,0,0,"00"],FK:["500","00","[2-7]\\d{4}",[5]],FM:["691","00","(?:[39]\\d\\d|820)\\d{4}",[7],[["(\\d{3})(\\d{4})","$1 $2",["[389]"]]]],FO:["298","00","[2-9]\\d{5}",[6],[["(\\d{6})","$1",["[2-9]"]]],0,0,"(10(?:01|[12]0|88))"],FR:["33","00","[1-9]\\d{8}",[9],[["(\\d{3})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["8"],"0 $1"],["(\\d)(\\d{2})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4 $5",["[1-79]"],"0$1"]],"0"],GA:["241","00","(?:[067]\\d|11)\\d{6}|[2-7]\\d{6}",[7,8],[["(\\d)(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["[2-7]"],"0$1"],["(\\d{2})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["0"]],["(\\d{2})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["11|[67]"],"0$1"]],0,0,"0(11\\d{6}|60\\d{6}|61\\d{6}|6[256]\\d{6}|7[467]\\d{6})","$1"],GB:["44","00","[1-357-9]\\d{9}|[18]\\d{8}|8\\d{6}",[7,9,10],[["(\\d{3})(\\d{4})","$1 $2",["800","8001","80011","800111","8001111"],"0$1"],["(\\d{3})(\\d{2})(\\d{2})","$1 $2 $3",["845","8454","84546","845464"],"0$1"],["(\\d{3})(\\d{6})","$1 $2",["800"],"0$1"],["(\\d{5})(\\d{4,5})","$1 $2",["1(?:38|5[23]|69|76|94)","1(?:(?:38|69)7|5(?:24|39)|768|946)","1(?:3873|5(?:242|39[4-6])|(?:697|768)[347]|9467)"],"0$1"],["(\\d{4})(\\d{5,6})","$1 $2",["1(?:[2-69][02-9]|[78])"],"0$1"],["(\\d{2})(\\d{4})(\\d{4})","$1 $2 $3",["[25]|7(?:0|6[02-9])","[25]|7(?:0|6(?:[03-9]|2[356]))"],"0$1"],["(\\d{4})(\\d{6})","$1 $2",["7"],"0$1"],["(\\d{3})(\\d{3})(\\d{4})","$1 $2 $3",["[1389]"],"0$1"]],"0",0,"0|180020",0,0,0,[["(?:1(?:1(?:3(?:[0-58]\\d\\d|73[0-5])|4(?:(?:[0-5]\\d|70)\\d|69[7-9])|(?:(?:5[0-26-9]|[78][0-49])\\d|6(?:[0-4]\\d|5[01]))\\d)|(?:2(?:(?:0[024-9]|2[3-9]|3[3-79]|4[1-689]|[58][02-9]|6[0-47-9]|7[013-9]|9\\d)\\d|1(?:[0-7]\\d|8[0-3]))|(?:3(?:0\\d|1[0-8]|[25][02-9]|3[02-579]|[468][0-46-9]|7[1-35-79]|9[2-578])|4(?:0[03-9]|[137]\\d|[28][02-57-9]|4[02-69]|5[0-8]|[69][0-79])|5(?:0[1-35-9]|[16]\\d|2[024-9]|3[015689]|4[02-9]|5[03-9]|7[0-35-9]|8[0-468]|9[0-57-9])|6(?:0[034689]|1\\d|2[0-35689]|[38][013-9]|4[1-467]|5[0-69]|6[13-9]|7[0-8]|9[0-24578])|7(?:0[0246-9]|2\\d|3[0236-8]|4[03-9]|5[0-46-9]|6[013-9]|7[0-35-9]|8[024-9]|9[02-9])|8(?:0[35-9]|2[1-57-9]|3[02-578]|4[0-578]|5[124-9]|6[2-69]|7\\d|8[02-9]|9[02569])|9(?:0[02-589]|[18]\\d|2[02-689]|3[1-57-9]|4[2-9]|5[0-579]|6[2-47-9]|7[0-24578]|9[2-57]))\\d)\\d)|2(?:0[013478]|3[0189]|4[017]|8[0-46-9]|9[0-2])\\d{3})\\d{4}|1(?:2(?:0(?:46[1-4]|87[2-9])|545[1-79]|76(?:2\\d|3[1-8]|6[1-6])|9(?:7(?:2[0-4]|3[2-5])|8(?:2[2-8]|7[0-47-9]|8[3-5])))|3(?:6(?:38[2-5]|47[23])|8(?:47[04-9]|64[0157-9]))|4(?:044[1-7]|20(?:2[23]|8\\d)|6(?:0(?:30|5[2-57]|6[1-8]|7[2-8])|140)|8(?:052|87[1-3]))|5(?:2(?:4(?:3[2-79]|6\\d)|76\\d)|6(?:26[06-9]|686))|6(?:06(?:4\\d|7[4-79])|295[5-7]|35[34]\\d|47(?:24|61)|59(?:5[08]|6[67]|74)|9(?:55[0-4]|77[23]))|7(?:26(?:6[13-9]|7[0-7])|(?:442|688)\\d|50(?:2[0-3]|[3-68]2|76))|8(?:27[56]\\d|37(?:5[2-5]|8[239])|843[2-58])|9(?:0(?:0(?:6[1-8]|85)|52\\d)|3583|4(?:66[1-8]|9(?:2[01]|81))|63(?:23|3[1-4])|9561))\\d{3}",[9,10]],["7(?:457[0-57-9]|700[01]|911[028])\\d{5}|7(?:[1-3]\\d\\d|4(?:[0-46-9]\\d|5[0-689])|5(?:0[0-8]|[13-9]\\d|2[0-35-9])|7(?:0[1-9]|[1-7]\\d|8[02-9]|9[0-689])|8(?:[014-9]\\d|[23][0-8])|9(?:[024-9]\\d|1[02-9]|3[0-689]))\\d{6}",[10]],["80[08]\\d{7}|800\\d{6}|8001111"],["(?:8(?:4[2-5]|7[0-3])|9(?:[01]\\d|8[2-49]))\\d{7}|845464\\d",[7,10]],["70\\d{8}",[10]],0,["(?:3[0347]|55)\\d{8}",[10]],["76(?:464|652)\\d{5}|76(?:0[0-28]|2[356]|34|4[01347]|5[49]|6[0-369]|77|8[14]|9[139])\\d{6}",[10]],["56\\d{8}",[10]]],0," x"],GD:["1","011","(?:473|[58]\\d\\d|900)\\d{7}",[10],0,"1",0,"([2-9]\\d{6})$|1","473$1",0,"473"],GE:["995","00","(?:[3-57]\\d\\d|800)\\d{6}",[9],[["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["70"],"0$1"],["(\\d{2})(\\d{3})(\\d{2})(\\d{2})","$1 $2 $3 $4",["32"],"0$1"],["(\\d{3})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["[57]"]],["(\\d{3})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["[348]"],"0$1"]],"0"],GF:["594","00","(?:[56]94\\d|7093)\\d{5}|(?:80|9\\d)\\d{7}",[9],[["(\\d{3})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["[5-7]|9[47]"],"0$1"],["(\\d{3})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["[89]"],"0$1"]],"0"],GG:["44","00","(?:1481|[357-9]\\d{3})\\d{6}|8\\d{6}(?:\\d{2})?",[7,9,10],0,"0",0,"([25-9]\\d{5})$|0|180020","1481$1",0,0,[["1481[25-9]\\d{5}",[10]],["7(?:(?:781|839)\\d|911[17])\\d{5}",[10]],["80[08]\\d{7}|800\\d{6}|8001111"],["(?:8(?:4[2-5]|7[0-3])|9(?:[01]\\d|8[0-3]))\\d{7}|845464\\d",[7,10]],["70\\d{8}",[10]],0,["(?:3[0347]|55)\\d{8}",[10]],["76(?:464|652)\\d{5}|76(?:0[0-28]|2[356]|34|4[01347]|5[49]|6[0-369]|77|8[14]|9[139])\\d{6}",[10]],["56\\d{8}",[10]]]],GH:["233","00","(?:[235]\\d{3}|800)\\d{5}",[8,9],[["(\\d{3})(\\d{5})","$1 $2",["8"],"0$1"],["(\\d{2})(\\d{3})(\\d{4})","$1 $2 $3",["[235]"],"0$1"]],"0"],GI:["350","00","(?:[25]\\d|60)\\d{6}",[8],[["(\\d{3})(\\d{5})","$1 $2",["2"]]]],GL:["299","00","(?:19|[2-689]\\d|70)\\d{4}",[6],[["(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3",["19|[2-9]"]]]],GM:["220","00","[2-9]\\d{6}",[7],[["(\\d{3})(\\d{4})","$1 $2",["[2-9]"]]]],GN:["224","00","722\\d{6}|(?:3|6\\d)\\d{7}",[8,9],[["(\\d{2})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["3"]],["(\\d{3})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["[67]"]]]],GP:["590","00","(?:590\\d|7090)\\d{5}|(?:69|80|9\\d)\\d{7}",[9],[["(\\d{3})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["[5-79]"],"0$1"],["(\\d{3})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["8"],"0$1"]],"0",0,0,0,0,0,[["590(?:0[1-68]|[14][0-24-9]|2[0-68]|3[1-9]|5[3-579]|[68][0-689]|7[08]|9\\d)\\d{4}"],["(?:69(?:0\\d\\d|1(?:2[2-9]|3[0-5])|4(?:0[89]|1[2-6]|9\\d)|6(?:1[016-9]|5[0-4]|[67]\\d))|7090[0-4])\\d{4}"],["80[0-5]\\d{6}"],0,0,0,0,0,["9(?:(?:39[5-7]|76[018])\\d|475[0-6])\\d{4}"]]],GQ:["240","00","222\\d{6}|(?:3\\d|55|[89]0)\\d{7}",[9],[["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["[235]"]],["(\\d{3})(\\d{6})","$1 $2",["[89]"]]]],GR:["30","00","5005000\\d{3}|8\\d{9,11}|(?:[269]\\d|70)\\d{8}",[10,11,12],[["(\\d{2})(\\d{4})(\\d{4})","$1 $2 $3",["21|7"]],["(\\d{4})(\\d{6})","$1 $2",["2(?:2|3[2-57-9]|4[2-469]|5[2-59]|6[2-9]|7[2-69]|8[2-49])|5"]],["(\\d{3})(\\d{3})(\\d{4})","$1 $2 $3",["[2689]"]],["(\\d{3})(\\d{3,4})(\\d{5})","$1 $2 $3",["8"]]]],GT:["502","00","80\\d{6}|(?:1\\d{3}|[2-7])\\d{7}",[8,11],[["(\\d{4})(\\d{4})","$1 $2",["[2-8]"]],["(\\d{4})(\\d{3})(\\d{4})","$1 $2 $3",["1"]]]],GU:["1","011","(?:[58]\\d\\d|671|900)\\d{7}",[10],0,"1",0,"([2-9]\\d{6})$|1","671$1",0,"671"],GW:["245","00","[49]\\d{8}|4\\d{6}",[7,9],[["(\\d{3})(\\d{4})","$1 $2",["40"]],["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["[49]"]]]],GY:["592","001","(?:[2-8]\\d{3}|9008)\\d{3}",[7],[["(\\d{3})(\\d{4})","$1 $2",["[2-9]"]]]],HK:["852","00(?:30|5[09]|[126-9]?)","8[0-46-9]\\d{6,7}|9\\d{4,7}|(?:[2-7]|9\\d{3})\\d{7}",[5,6,7,8,9,11],[["(\\d{3})(\\d{2,5})","$1 $2",["900","9003"]],["(\\d{4})(\\d{4})","$1 $2",["[2-7]|8[1-4]|9(?:0[1-9]|[1-8])"]],["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["8"]],["(\\d{3})(\\d{2})(\\d{3})(\\d{3})","$1 $2 $3 $4",["9"]]],0,0,0,0,0,0,0,"00"],HN:["504","00","8\\d{10}|[237-9]\\d{7}",[8,11],[["(\\d{4})(\\d{4})","$1-$2",["[237-9]"]]]],HR:["385","00","[2-69]\\d{8}|80\\d{5,7}|[1-79]\\d{7}|6\\d{6}",[7,8,9],[["(\\d{2})(\\d{2})(\\d{3})","$1 $2 $3",["6[01]"],"0$1"],["(\\d{3})(\\d{2})(\\d{2,3})","$1 $2 $3",["8"],"0$1"],["(\\d)(\\d{4})(\\d{3})","$1 $2 $3",["1"],"0$1"],["(\\d{2})(\\d{3})(\\d{3,4})","$1 $2 $3",["6|7[245]"],"0$1"],["(\\d{2})(\\d{3})(\\d{3,4})","$1 $2 $3",["9"],"0$1"],["(\\d{2})(\\d{3})(\\d{3,4})","$1 $2 $3",["[2-57]"],"0$1"],["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["8"],"0$1"]],"0"],HT:["509","00","[2-589]\\d{7}",[8],[["(\\d{2})(\\d{2})(\\d{4})","$1 $2 $3",["[2-589]"]]]],HU:["36","00","[235-7]\\d{8}|[1-9]\\d{7}",[8,9],[["(\\d)(\\d{3})(\\d{4})","$1 $2 $3",["1"],"(06 $1)"],["(\\d{2})(\\d{3})(\\d{3})","$1 $2 $3",["[27][2-9]|3[2-7]|4[24-9]|5[2-79]|6|8[2-57-9]|9[2-69]"],"(06 $1)"],["(\\d{2})(\\d{3})(\\d{3,4})","$1 $2 $3",["[2-9]"],"06 $1"]],"06"],ID:["62","00[89]","00[1-9]\\d{9,14}|(?:[1-36]|8\\d{5})\\d{6}|00\\d{9}|[1-9]\\d{8,10}|[2-9]\\d{7}",[7,8,9,10,11,12,13,14,15,16,17],[["(\\d)(\\d{3})(\\d{3})","$1 $2 $3",["15"]],["(\\d{2})(\\d{5,9})","$1 $2",["2[124]|[36]1"],"(0$1)"],["(\\d{3})(\\d{5,7})","$1 $2",["800"],"0$1"],["(\\d{3})(\\d{5,8})","$1 $2",["[2-79]"],"(0$1)"],["(\\d{3})(\\d{3,4})(\\d{3})","$1-$2-$3",["8[1-35-9]"],"0$1"],["(\\d{3})(\\d{6,8})","$1 $2",["1"],"0$1"],["(\\d{3})(\\d{3})(\\d{4})","$1 $2 $3",["804"],"0$1"],["(\\d{3})(\\d)(\\d{3})(\\d{3})","$1 $2 $3 $4",["80"],"0$1"],["(\\d{3})(\\d{4})(\\d{4,5})","$1-$2-$3",["8"],"0$1"]],"0"],IE:["353","00","(?:1\\d|[2569])\\d{6,8}|4\\d{6,9}|7\\d{8}|8\\d{8,9}",[7,8,9,10],[["(\\d{2})(\\d{5})","$1 $2",["2[24-9]|47|58|6[237-9]|9[35-9]"],"(0$1)"],["(\\d{3})(\\d{5})","$1 $2",["[45]0"],"(0$1)"],["(\\d)(\\d{3,4})(\\d{4})","$1 $2 $3",["1"],"(0$1)"],["(\\d{2})(\\d{3})(\\d{3,4})","$1 $2 $3",["[2569]|4[1-69]|7[14]"],"(0$1)"],["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["70"],"0$1"],["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["81"],"(0$1)"],["(\\d{2})(\\d{3})(\\d{4})","$1 $2 $3",["[78]"],"0$1"],["(\\d{4})(\\d{3})(\\d{3})","$1 $2 $3",["1"]],["(\\d{2})(\\d{4})(\\d{4})","$1 $2 $3",["4"],"(0$1)"],["(\\d{2})(\\d)(\\d{3})(\\d{4})","$1 $2 $3 $4",["8"],"0$1"]],"0"],IL:["972","0(?:0|1[2-9])","1\\d{6}(?:\\d{3,5})?|[57]\\d{8}|[1-489]\\d{7}",[7,8,9,10,11,12],[["(\\d{4})(\\d{3})","$1-$2",["125"]],["(\\d{4})(\\d{2})(\\d{2})","$1-$2-$3",["121"]],["(\\d)(\\d{3})(\\d{4})","$1-$2-$3",["[2-489]"],"0$1"],["(\\d{2})(\\d{3})(\\d{4})","$1-$2-$3",["[57]"],"0$1"],["(\\d{4})(\\d{3})(\\d{3})","$1-$2-$3",["12"]],["(\\d{4})(\\d{6})","$1-$2",["159"]],["(\\d)(\\d{3})(\\d{3})(\\d{3})","$1-$2-$3-$4",["1[7-9]"]],["(\\d{3})(\\d{1,2})(\\d{3})(\\d{4})","$1-$2 $3-$4",["15"]]],"0"],IM:["44","00","1624\\d{6}|(?:[3578]\\d|90)\\d{8}",[10],0,"0",0,"([25-8]\\d{5})$|0|180020","1624$1",0,"74576|(?:16|7[56])24"],IN:["91","00","(?:000800|[2-9]\\d\\d)\\d{7}|1\\d{7,12}",[8,9,10,11,12,13],[["(\\d{8})","$1",["5(?:0|2[23]|3[03]|[67]1|88)","5(?:0|2(?:21|3)|3(?:0|3[23])|616|717|888)","5(?:0|2(?:21|3)|3(?:0|3[23])|616|717|8888)"],0,1],["(\\d{4})(\\d{4,5})","$1 $2",["180","1800"],0,1],["(\\d{3})(\\d{3})(\\d{4})","$1 $2 $3",["140"],0,1],["(\\d{2})(\\d{4})(\\d{4})","$1 $2 $3",["11|2[02]|33|4[04]|79[1-7]|80[2-46]","11|2[02]|33|4[04]|79(?:[1-6]|7[19])|80(?:[2-4]|6[0-589])","11|2[02]|33|4[04]|79(?:[124-6]|3(?:[02-9]|1[0-24-9])|7(?:1|9[1-6]))|80(?:[2-4]|6[0-589])"],"0$1",1],["(\\d{3})(\\d{3})(\\d{4})","$1 $2 $3",["1(?:2[0-249]|3[0-25]|4[145]|[68]|7[1257])|2(?:1[257]|3[013]|4[01]|5[0137]|6[0158]|78|8[1568])|3(?:26|4[1-3]|5[34]|6[01489]|7[02-46]|8[159])|4(?:1[36]|2[1-47]|5[12]|6[0-26-9]|7[0-24-9]|8[013-57]|9[014-7])|5(?:1[025]|22|[36][25]|4[28]|5[12]|[78]1)|6(?:12|[2-4]1|5[17]|6[13]|80)|7(?:12|3[134]|4[47]|61|88)|8(?:16|2[014]|3[126]|6[136]|7[078]|8[34]|91)|(?:43|59|75)[15]|(?:1[59]|29|67|72)[14]","1(?:2[0-24]|3[0-25]|4[145]|[59][14]|6[1-9]|7[1257]|8[1-57-9])|2(?:1[257]|3[013]|4[01]|5[0137]|6[058]|78|8[1568]|9[14])|3(?:26|4[1-3]|5[34]|6[01489]|7[02-46]|8[159])|4(?:1[36]|2[1-47]|3[15]|5[12]|6[0-26-9]|7[0-24-9]|8[013-57]|9[014-7])|5(?:1[025]|22|[36][25]|4[28]|[578]1|9[15])|674|7(?:(?:2[14]|3[34]|5[15])[2-6]|61[346]|88[0-8])|8(?:70[2-6]|84[235-7]|91[3-7])|(?:1(?:29|60|8[06])|261|552|6(?:12|[2-47]1|5[17]|6[13]|80)|7(?:12|31|4[47])|8(?:16|2[014]|3[126]|6[136]|7[78]|83))[2-7]","1(?:2[0-24]|3[0-25]|4[145]|[59][14]|6[1-9]|7[1257]|8[1-57-9])|2(?:1[257]|3[013]|4[01]|5[0137]|6[058]|78|8[1568]|9[14])|3(?:26|4[1-3]|5[34]|6[01489]|7[02-46]|8[159])|4(?:1[36]|2[1-47]|3[15]|5[12]|6[0-26-9]|7[0-24-9]|8[013-57]|9[014-7])|5(?:1[025]|22|[36][25]|4[28]|[578]1|9[15])|6(?:12(?:[2-6]|7[0-8])|74[2-7])|7(?:(?:2[14]|5[15])[2-6]|3171|61[346]|88(?:[2-7]|82))|8(?:70[2-6]|84(?:[2356]|7[19])|91(?:[3-6]|7[19]))|73[134][2-6]|(?:74[47]|8(?:16|2[014]|3[126]|6[136]|7[78]|83))(?:[2-6]|7[19])|(?:1(?:29|60|8[06])|261|552|6(?:[2-4]1|5[17]|6[13]|7(?:1|4[0189])|80)|7(?:12|88[01]))[2-7]"],"0$1",1],["(\\d{4})(\\d{3})(\\d{3})","$1 $2 $3",["1(?:[2-479]|5[0235-9])|[2-5]|6(?:1[1358]|2[2457-9]|3[2-5]|4[235-7]|5[2-689]|6[24578]|7[235689]|8[1-6])|7(?:1[013-9]|28|3[129]|4[1-35689]|5[29]|6[02-5]|70)|807","1(?:[2-479]|5[0235-9])|[2-5]|6(?:1[1358]|2(?:[2457]|84|95)|3(?:[2-4]|55)|4[235-7]|5[2-689]|6[24578]|7[235689]|8[1-6])|7(?:1(?:[013-8]|9[6-9])|28[6-8]|3(?:17|2[0-49]|9[2-57])|4(?:1[2-4]|[29][0-7]|3[0-8]|[56]|8[0-24-7])|5(?:2[1-3]|9[0-6])|6(?:0[5689]|2[5-9]|3[02-8]|4|5[0-367])|70[13-7])|807[19]","1(?:[2-479]|5(?:[0236-9]|5[013-9]))|[2-5]|6(?:2(?:84|95)|355|8(?:28[235-7]|3))|73179|807(?:1|9[1-3])|(?:1552|6(?:(?:1[1358]|2[2457]|3[2-4]|4[235-7]|5[2-689]|6[24578]|7[235689])\\d|8(?:[14-6]\\d|2[0-79]))|7(?:1(?:[013-8]\\d|9[6-9])|28[6-8]|3(?:2[0-49]|9[2-57])|4(?:1[2-4]|[29][0-7]|3[0-8]|[56]\\d|8[0-24-7])|5(?:2[1-3]|9[0-6])|6(?:0[5689]|2[5-9]|3[02-8]|4\\d|5[0-367])|70[13-7]))[2-7]"],"0$1",1],["(\\d{5})(\\d{5})","$1 $2",["16|[6-9]"],"0$1",1],["(\\d{4})(\\d{2,4})(\\d{4})","$1 $2 $3",["18[06]","18[06]0"],0,1],["(\\d{4})(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3 $4",["18"],0,1]],"0"],IO:["246","00","3\\d{6}",[7],[["(\\d{3})(\\d{4})","$1 $2",["3"]]]],IQ:["964","00","(?:1|7\\d\\d)\\d{7}|[2-6]\\d{7,8}",[8,9,10],[["(\\d)(\\d{3})(\\d{4})","$1 $2 $3",["1"],"0$1"],["(\\d{2})(\\d{3})(\\d{3,4})","$1 $2 $3",["[2-6]"],"0$1"],["(\\d{3})(\\d{3})(\\d{4})","$1 $2 $3",["7"],"0$1"]],"0"],IR:["98","00","[1-9]\\d{9}|(?:[1-8]\\d\\d|9)\\d{3,4}",[4,5,6,7,10],[["(\\d{4,5})","$1",["96"],"0$1"],["(\\d{2})(\\d{4,5})","$1 $2",["(?:1[137]|2[13-68]|3[1458]|4[145]|5[1468]|6[16]|7[1467]|8[13467])[12689]"],"0$1"],["(\\d{3})(\\d{3})(\\d{3,4})","$1 $2 $3",["9"],"0$1"],["(\\d{2})(\\d{4})(\\d{4})","$1 $2 $3",["[1-8]"],"0$1"]],"0"],IS:["354","00|1(?:0(?:01|[12]0)|100)","(?:38\\d|[4-9])\\d{6}",[7,9],[["(\\d{3})(\\d{4})","$1 $2",["[4-9]"]],["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["3"]]],0,0,0,0,0,0,0,"00"],IT:["39","00","0\\d{5,11}|1\\d{8,10}|3(?:[0-8]\\d{7,10}|9\\d{7,8})|(?:43|55|70)\\d{8}|8\\d{5}(?:\\d{2,4})?",[6,7,8,9,10,11,12],[["(\\d{2})(\\d{4,6})","$1 $2",["0[26]"]],["(\\d{3})(\\d{3,6})","$1 $2",["0[13-57-9][0159]|8(?:03|4[17]|9[2-5])","0[13-57-9][0159]|8(?:03|4[17]|9(?:2|3[04]|[45][0-4]))"]],["(\\d{4})(\\d{2,6})","$1 $2",["0(?:[13-579][2-46-8]|8[236-8])"]],["(\\d{4})(\\d{4})","$1 $2",["894"]],["(\\d{2})(\\d{3,4})(\\d{4})","$1 $2 $3",["0[26]|5"]],["(\\d{3})(\\d{3})(\\d{3,4})","$1 $2 $3",["1(?:44|[679])|[378]|43"]],["(\\d{3})(\\d{3,4})(\\d{4})","$1 $2 $3",["0[13-57-9][0159]|14"]],["(\\d{2})(\\d{4})(\\d{5})","$1 $2 $3",["0[26]"]],["(\\d{4})(\\d{3})(\\d{4})","$1 $2 $3",["0"]],["(\\d{3})(\\d{4})(\\d{4,5})","$1 $2 $3",["[03]"]]],0,0,0,0,0,0,[["0(?:669[0-79]\\d{1,6}|831\\d{2,8})|0(?:1(?:[0159]\\d|[27][1-5]|31|4[1-4]|6[1356]|8[2-57])|2\\d\\d|3(?:[0159]\\d|2[1-4]|3[12]|[48][1-6]|6[2-59]|7[1-7])|4(?:[0159]\\d|[23][1-9]|4[245]|6[1-5]|7[1-4]|81)|5(?:[0159]\\d|2[1-5]|3[2-6]|4[1-79]|6[4-6]|7[1-578]|8[3-8])|6(?:[0-57-9]\\d|6[0-8])|7(?:[0159]\\d|2[12]|3[1-7]|4[2-46]|6[13569]|7[13-6]|8[1-59])|8(?:[0159]\\d|2[3-578]|3[2356]|[6-8][1-5])|9(?:[0159]\\d|[238][1-5]|4[12]|6[1-8]|7[1-6]))\\d{2,7}"],["3[2-9]\\d{7,8}|(?:31|43)\\d{8}",[9,10]],["80(?:0\\d{3}|3)\\d{3}",[6,9]],["(?:0878\\d{3}|89(?:2\\d|3[04]|4(?:[0-4]|[5-9]\\d\\d)|5[0-4]))\\d\\d|(?:1(?:44|6[346])|89(?:38|5[5-9]|9))\\d{6}",[6,8,9,10]],["1(?:78\\d|99)\\d{6}",[9,10]],["3[2-8]\\d{9,10}",[11,12]],0,0,["55\\d{8}",[10]],["84(?:[08]\\d{3}|[17])\\d{3}",[6,9]]]],JE:["44","00","1534\\d{6}|(?:[3578]\\d|90)\\d{8}",[10],0,"0",0,"([0-24-8]\\d{5})$|0|180020","1534$1",0,0,[["1534[0-24-8]\\d{5}"],["7(?:(?:(?:50|82)9|937)\\d|7(?:00[378]|97\\d))\\d{5}"],["80(?:07(?:35|81)|8901)\\d{4}"],["(?:8(?:4(?:4(?:4(?:05|42|69)|703)|5(?:041|800))|7(?:0002|1206))|90(?:066[59]|1810|71(?:07|55)))\\d{4}"],["701511\\d{4}"],0,["(?:3(?:0(?:07(?:35|81)|8901)|3\\d{4}|4(?:4(?:4(?:05|42|69)|703)|5(?:041|800))|7(?:0002|1206))|55\\d{4})\\d{4}"],["76(?:464|652)\\d{5}|76(?:0[0-28]|2[356]|34|4[01347]|5[49]|6[0-369]|77|8[14]|9[139])\\d{6}"],["56\\d{8}"]]],JM:["1","011","(?:[58]\\d\\d|658|900)\\d{7}",[10],0,"1",0,0,0,0,"658|876"],JO:["962","00","(?:(?:[2689]|7\\d)\\d|32|427|53)\\d{6}",[8,9],[["(\\d)(\\d{3})(\\d{4})","$1 $2 $3",["[2356]|87"],"(0$1)"],["(\\d{3})(\\d{5,6})","$1 $2",["[89]"],"0$1"],["(\\d{2})(\\d{7})","$1 $2",["70"],"0$1"],["(\\d)(\\d{4})(\\d{4})","$1 $2 $3",["[47]"],"0$1"]],"0"],JP:["81","010","00[1-9]\\d{6,14}|[25-9]\\d{9}|(?:00|[1-9]\\d\\d)\\d{6}",[8,9,10,11,12,13,14,15,16,17],[["(\\d{3})(\\d{3})(\\d{3})","$1-$2-$3",["(?:12|57|99)0"],"0$1"],["(\\d{4})(\\d)(\\d{4})","$1-$2-$3",["1(?:26|3[79]|4[56]|5[4-68]|6[3-5])|499|5(?:76|97)|746|8(?:3[89]|47|51)|9(?:80|9[16])","1(?:267|3(?:7[247]|9[278])|466|5(?:47|58|64)|6(?:3[245]|48|5[4-68]))|499[2468]|5(?:76|97)9|7468|8(?:3(?:8[7-9]|96)|477|51[2-9])|9(?:802|9(?:1[23]|69))|1(?:45|58)[67]","1(?:267|3(?:7[247]|9[278])|466|5(?:47|58|64)|6(?:3[245]|48|5[4-68]))|499[2468]|5(?:769|979[2-69])|7468|8(?:3(?:8[7-9]|96[2457-9])|477|51[2-9])|9(?:802|9(?:1[23]|69))|1(?:45|58)[67]"],"0$1"],["(\\d{2})(\\d{3})(\\d{4})","$1-$2-$3",["60"],"0$1"],["(\\d)(\\d{4})(\\d{4})","$1-$2-$3",["3|4(?:2[09]|7[01])|6[1-9]","3|4(?:2(?:0|9[02-69])|7(?:0[019]|1))|6[1-9]"],"0$1"],["(\\d{2})(\\d{3})(\\d{4})","$1-$2-$3",["1(?:1|5[45]|77|88|9[69])|2(?:2[1-37]|3[0-269]|4[59]|5|6[24]|7[1-358]|8[1369]|9[0-38])|4(?:[28][1-9]|3[0-57]|[45]|6[248]|7[2-579]|9[29])|5(?:2|3[0459]|4[0-369]|5[29]|8[02389]|9[0-389])|7(?:2[02-46-9]|34|[58]|6[0249]|7[57]|9[2-6])|8(?:2[124589]|3[26-9]|49|51|6|7[0-468]|8[68]|9[019])|9(?:[23][1-9]|4[15]|5[138]|6[1-3]|7[156]|8[189]|9[1-489])","1(?:1|5(?:4[018]|5[017])|77|88|9[69])|2(?:2(?:[127]|3[014-9])|3[0-269]|4[59]|5(?:[1-3]|5[0-69]|9[19])|62|7(?:[1-35]|8[0189])|8(?:[16]|3[0134]|9[0-5])|9(?:[028]|17))|4(?:2(?:[13-79]|8[014-6])|3[0-57]|[45]|6[248]|7[2-47]|8[1-9]|9[29])|5(?:2|3(?:[045]|9[0-8])|4[0-369]|5[29]|8[02389]|9[0-3])|7(?:2[02-46-9]|34|[58]|6[0249]|7[57]|9(?:[23]|4[0-59]|5[01569]|6[0167]))|8(?:2(?:[1258]|4[0-39]|9[0-2469])|3(?:[29]|60)|49|51|6(?:[0-24]|36|5[0-3589]|7[23]|9[01459])|7[0-468]|8[68])|9(?:[23][1-9]|4[15]|5[138]|6[1-3]|7[156]|8[189]|9(?:[1289]|3[34]|4[0178]))|(?:264|837)[016-9]|2(?:57|93)[015-9]|(?:25[0468]|422|838)[01]|(?:47[59]|59[89]|8(?:6[68]|9))[019]","1(?:1|5(?:4[018]|5[017])|77|88|9[69])|2(?:2[127]|3[0-269]|4[59]|5(?:[1-3]|5[0-69]|9(?:17|99))|6(?:2|4[016-9])|7(?:[1-35]|8[0189])|8(?:[16]|3[0134]|9[0-5])|9(?:[028]|17))|4(?:2(?:[13-79]|8[014-6])|3[0-57]|[45]|6[248]|7[2-47]|9[29])|5(?:2|3(?:[045]|9(?:[0-58]|6[4-9]|7[0-35689]))|4[0-369]|5[29]|8[02389]|9[0-3])|7(?:2[02-46-9]|34|[58]|6[0249]|7[57]|9(?:[23]|4[0-59]|5[01569]|6[0167]))|8(?:2(?:[1258]|4[0-39]|9[0169])|3(?:[29]|60|7(?:[017-9]|6[6-8]))|49|51|6(?:[0-24]|36[2-57-9]|5(?:[0-389]|5[23])|6(?:[01]|9[178])|7(?:2[2-468]|3[78])|9[0145])|7[0-468]|8[68])|9(?:4[15]|5[138]|7[156]|8[189]|9(?:[1289]|3(?:31|4[357])|4[0178]))|(?:8294|96)[1-3]|2(?:57|93)[015-9]|(?:223|8699)[014-9]|(?:25[0468]|422|838)[01]|(?:48|8292|9[23])[1-9]|(?:47[59]|59[89]|8(?:68|9))[019]"],"0$1"],["(\\d{3})(\\d{2})(\\d{4})","$1-$2-$3",["[14]|[289][2-9]|5[3-9]|7[2-4679]"],"0$1"],["(\\d{3})(\\d{3})(\\d{4})","$1-$2-$3",["800"],"0$1"],["(\\d{2})(\\d{4})(\\d{4})","$1-$2-$3",["[25-9]"],"0$1"]],"0",0,"(000[2569]\\d{4,6})$|(?:(?:003768)0?)|0","$1"],KE:["254","000","(?:[17]\\d\\d|900)\\d{6}|(?:2|80)0\\d{6,7}|[4-6]\\d{6,8}",[7,8,9,10],[["(\\d{2})(\\d{5,7})","$1 $2",["[24-6]"],"0$1"],["(\\d{3})(\\d{6})","$1 $2",["[17]"],"0$1"],["(\\d{3})(\\d{3})(\\d{3,4})","$1 $2 $3",["[89]"],"0$1"]],"0"],KG:["996","00","8\\d{9}|[235-9]\\d{8}",[9,10],[["(\\d{4})(\\d{5})","$1 $2",["3(?:1[346]|[24-79])"],"0$1"],["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["[235-79]|88"],"0$1"],["(\\d{3})(\\d{3})(\\d)(\\d{2,3})","$1 $2 $3 $4",["8"],"0$1"]],"0"],KH:["855","00[14-9]","1\\d{9}|[1-9]\\d{7,8}",[8,9,10],[["(\\d{2})(\\d{3})(\\d{3,4})","$1 $2 $3",["[1-9]"],"0$1"],["(\\d{4})(\\d{3})(\\d{3})","$1 $2 $3",["1"]]],"0"],KI:["686","00","(?:[37]\\d|6[0-79])\\d{6}|(?:[2-48]\\d|50)\\d{3}",[5,8],0,"0"],KM:["269","00","[3478]\\d{6}",[7],[["(\\d{3})(\\d{2})(\\d{2})","$1 $2 $3",["[3478]"]]]],KN:["1","011","(?:[58]\\d\\d|900)\\d{7}",[10],0,"1",0,"([2-7]\\d{6})$|1","869$1",0,"869"],KP:["850","00|99","85\\d{6}|(?:19\\d|[2-7])\\d{7}",[8,10],[["(\\d{2})(\\d{3})(\\d{3})","$1 $2 $3",["8"],"0$1"],["(\\d)(\\d{3})(\\d{4})","$1 $2 $3",["[2-7]"],"0$1"],["(\\d{3})(\\d{3})(\\d{4})","$1 $2 $3",["1"],"0$1"]],"0"],KR:["82","00(?:[125689]|3(?:[46]5|91)|7(?:00|27|3|55|6[126]))","00[1-9]\\d{8,11}|(?:[12]|5\\d{3})\\d{7}|[13-6]\\d{9}|(?:[1-6]\\d|80)\\d{7}|[3-6]\\d{4,5}|(?:00|7)0\\d{8}",[5,6,8,9,10,11,12,13,14],[["(\\d{2})(\\d{3,4})","$1-$2",["(?:3[1-3]|[46][1-4]|5[1-5])1"],"0$1"],["(\\d{4})(\\d{4})","$1-$2",["1"]],["(\\d)(\\d{3,4})(\\d{4})","$1-$2-$3",["2"],"0$1"],["(\\d{2})(\\d{3})(\\d{4})","$1-$2-$3",["[36]0|8"],"0$1"],["(\\d{2})(\\d{3,4})(\\d{4})","$1-$2-$3",["[1346]|5[1-5]"],"0$1"],["(\\d{2})(\\d{4})(\\d{4})","$1-$2-$3",["[57]"],"0$1"],["(\\d{2})(\\d{5})(\\d{4})","$1-$2-$3",["5"],"0$1"]],"0",0,"0(8(?:[1-46-8]|5\\d\\d))?"],KW:["965","00","18\\d{5}|(?:[2569]\\d|41)\\d{6}",[7,8],[["(\\d{4})(\\d{3,4})","$1 $2",["[169]|2(?:[235]|4[1-35-9])|52"]],["(\\d{3})(\\d{5})","$1 $2",["[245]"]]]],KY:["1","011","(?:345|[58]\\d\\d|900)\\d{7}",[10],0,"1",0,"([2-9]\\d{6})$|1","345$1",0,"345"],KZ:["7","810","8\\d{13}|[78]\\d{9}",[10,14],0,"8",0,0,0,0,"7",0,"8~10"],LA:["856","00","[23]\\d{9}|3\\d{8}|(?:[235-8]\\d|41)\\d{6}",[8,9,10],[["(\\d{2})(\\d{3})(\\d{3})","$1 $2 $3",["2[13]|3[14]|[4-8]"],"0$1"],["(\\d{2})(\\d{2})(\\d{2})(\\d{3})","$1 $2 $3 $4",["3"],"0$1"],["(\\d{2})(\\d{2})(\\d{3})(\\d{3})","$1 $2 $3 $4",["[23]"],"0$1"]],"0"],LB:["961","00","[27-9]\\d{7}|[13-9]\\d{6}",[7,8],[["(\\d)(\\d{3})(\\d{3})","$1 $2 $3",["[13-69]|7(?:[2-57]|62|8[0-6]|9[04-9])|8[02-9]"],"0$1"],["(\\d{2})(\\d{3})(\\d{3})","$1 $2 $3",["[27-9]"]]],"0"],LC:["1","011","(?:[58]\\d\\d|758|900)\\d{7}",[10],0,"1",0,"([2-8]\\d{6})$|1","758$1",0,"758"],LI:["423","00","[68]\\d{8}|(?:[2378]\\d|90)\\d{5}",[7,9],[["(\\d{3})(\\d{2})(\\d{2})","$1 $2 $3",["[2379]|8(?:0[09]|7)","[2379]|8(?:0(?:02|9)|7)"]],["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["8"]],["(\\d{2})(\\d{3})(\\d{4})","$1 $2 $3",["69"]],["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["6"]]],"0",0,"(1001)|0"],LK:["94","00","[1-9]\\d{8}",[9],[["(\\d{2})(\\d{3})(\\d{4})","$1 $2 $3",["7"],"0$1"],["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["[1-689]"],"0$1"]],"0"],LR:["231","00","(?:[2457]\\d|33|88)\\d{7}|(?:2\\d|[4-6])\\d{6}",[7,8,9],[["(\\d)(\\d{3})(\\d{3})","$1 $2 $3",["4[67]|[56]"],"0$1"],["(\\d{2})(\\d{3})(\\d{3})","$1 $2 $3",["2"],"0$1"],["(\\d{2})(\\d{3})(\\d{4})","$1 $2 $3",["[2-578]"],"0$1"]],"0"],LS:["266","00","(?:[256]\\d\\d|800)\\d{5}",[8],[["(\\d{4})(\\d{4})","$1 $2",["[2568]"]]]],LT:["370","00","(?:[3469]\\d|52|[78]0)\\d{6}",[8],[["(\\d)(\\d{3})(\\d{4})","$1 $2 $3",["52[0-7]"],"(0-$1)",1],["(\\d{3})(\\d{2})(\\d{3})","$1 $2 $3",["[7-9]"],"0 $1",1],["(\\d{2})(\\d{6})","$1 $2",["37|4(?:[15]|6[1-8])"],"(0-$1)",1],["(\\d{3})(\\d{5})","$1 $2",["[3-6]"],"(0-$1)",1]],"0",0,"[08]"],LU:["352","00","35[013-9]\\d{4,8}|6\\d{8}|35\\d{2,4}|(?:[2457-9]\\d|3[0-46-9])\\d{2,9}",[4,5,6,7,8,9,10,11],[["(\\d{2})(\\d{3})","$1 $2",["2(?:0[2-689]|[2-9])|[3-57]|8(?:0[2-9]|[13-9])|9(?:0[89]|[2-579])"]],["(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3",["2(?:0[2-689]|[2-9])|[3-57]|8(?:0[2-9]|[13-9])|9(?:0[89]|[2-579])"]],["(\\d{2})(\\d{2})(\\d{3})","$1 $2 $3",["20[2-689]"]],["(\\d{2})(\\d{2})(\\d{2})(\\d{1,2})","$1 $2 $3 $4",["20"]],["(\\d{2})(\\d{2})(\\d{2})(\\d{1,5})","$1 $2 $3 $4",["[3-57]|8[13-9]|9(?:0[89]|[2-579])|(?:2|80)[2-9]"]],["(\\d{3})(\\d{2})(\\d{3})","$1 $2 $3",["80[01]|90[015]"]],["(\\d{2})(\\d{2})(\\d{2})(\\d{3})","$1 $2 $3 $4",["20"]],["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["6"]],["(\\d{2})(\\d{2})(\\d{2})(\\d{2})(\\d{1,2})","$1 $2 $3 $4 $5",["20"]]],0,0,"(15(?:0[06]|1[12]|[35]5|4[04]|6[26]|77|88|99)\\d)"],LV:["371","00","(?:[268]\\d|78|90)\\d{6}",[8],[["(\\d{2})(\\d{3})(\\d{3})","$1 $2 $3",["[2679]|8[01]"]]]],LY:["218","00","[2-9]\\d{8}",[9],[["(\\d{2})(\\d{7})","$1-$2",["[2-9]"],"0$1"]],"0"],MA:["212","00","[5-8]\\d{8}",[9],[["(\\d{4})(\\d{5})","$1-$2",["892"],"0$1"],["(\\d{2})(\\d{7})","$1-$2",["8(?:0[0-7]|9)"],"0$1"],["(\\d)(\\d{2})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4 $5",["[5-8]"],"0$1"]],"0",0,0,0,0,"[5-8]"],MC:["377","00","(?:[3489]|[67]\\d)\\d{7}",[8,9],[["(\\d{2})(\\d{3})(\\d{3})","$1 $2 $3",["4"],"0$1"],["(\\d{2})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["[389]"]],["(\\d)(\\d{2})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4 $5",["[67]"],"0$1"]],"0"],MD:["373","00","(?:[235-7]\\d|[89]0)\\d{6}",[8],[["(\\d{3})(\\d{5})","$1 $2",["[89]"],"0$1"],["(\\d{2})(\\d{3})(\\d{3})","$1 $2 $3",["22|3"],"0$1"],["(\\d{3})(\\d{2})(\\d{3})","$1 $2 $3",["[25-7]"],"0$1"]],"0"],ME:["382","00","(?:20|[3-79]\\d)\\d{6}|80\\d{6,7}",[8,9],[["(\\d{2})(\\d{3})(\\d{3,4})","$1 $2 $3",["[2-9]"],"0$1"]],"0"],MF:["590","00","(?:590\\d|7090)\\d{5}|(?:69|80|9\\d)\\d{7}",[9],0,"0",0,0,0,0,0,[["590(?:0[079]|[14]3|[27][79]|3[03-7]|5[0-268]|87)\\d{4}"],["(?:69(?:0\\d\\d|1(?:2[2-9]|3[0-5])|4(?:0[89]|1[2-6]|9\\d)|6(?:1[016-9]|5[0-4]|[67]\\d))|7090[0-4])\\d{4}"],["80[0-5]\\d{6}"],0,0,0,0,0,["9(?:(?:39[5-7]|76[018])\\d|475[0-6])\\d{4}"]]],MG:["261","00","[23]\\d{8}",[9],[["(\\d{2})(\\d{2})(\\d{3})(\\d{2})","$1 $2 $3 $4",["[23]"],"0$1"]],"0",0,"([24-9]\\d{6})$|0","20$1"],MH:["692","011","329\\d{4}|(?:[256]\\d|45)\\d{5}",[7],[["(\\d{3})(\\d{4})","$1-$2",["[2-6]"]]],"1"],MK:["389","00","[2-578]\\d{7}",[8],[["(\\d)(\\d{3})(\\d{4})","$1 $2 $3",["2|34[47]|4(?:[37]7|5[47]|64)"],"0$1"],["(\\d{2})(\\d{3})(\\d{3})","$1 $2 $3",["[347]"],"0$1"],["(\\d{3})(\\d)(\\d{2})(\\d{2})","$1 $2 $3 $4",["[58]"],"0$1"]],"0"],ML:["223","00","[24-9]\\d{7}",[8],[["(\\d{2})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["[24-9]"]]]],MM:["95","00","1\\d{5,7}|95\\d{6}|(?:[4-7]|9[0-46-9])\\d{6,8}|(?:2|8\\d)\\d{5,8}",[6,7,8,9,10],[["(\\d)(\\d{2})(\\d{3})","$1 $2 $3",["16|2"],"0$1"],["(\\d{2})(\\d{2})(\\d{3})","$1 $2 $3",["4(?:[2-46]|5[3-5])|5|6(?:[1-689]|7[235-7])|7(?:[0-4]|5[2-7])|8[1-5]|(?:60|86)[23]"],"0$1"],["(\\d)(\\d{3})(\\d{3,4})","$1 $2 $3",["[12]|452|678|86","[12]|452|6788|86"],"0$1"],["(\\d{2})(\\d{3})(\\d{3,4})","$1 $2 $3",["[4-7]|8[1-35]"],"0$1"],["(\\d)(\\d{3})(\\d{4,6})","$1 $2 $3",["9(?:2[0-4]|[35-9]|4[137-9])"],"0$1"],["(\\d)(\\d{4})(\\d{4})","$1 $2 $3",["2"],"0$1"],["(\\d{3})(\\d{3})(\\d{4})","$1 $2 $3",["8"],"0$1"],["(\\d)(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3 $4",["92"],"0$1"],["(\\d)(\\d{5})(\\d{4})","$1 $2 $3",["9"],"0$1"]],"0"],MN:["976","001","[12]\\d{7,9}|[5-9]\\d{7}",[8,9,10],[["(\\d{2})(\\d{2})(\\d{4})","$1 $2 $3",["[12]1"],"0$1"],["(\\d{4})(\\d{4})","$1 $2",["[5-9]"]],["(\\d{3})(\\d{5,6})","$1 $2",["[12]2[1-3]"],"0$1"],["(\\d{4})(\\d{5,6})","$1 $2",["[12](?:27|3[2-8]|4[2-68]|5[1-4689])","[12](?:27|3[2-8]|4[2-68]|5[1-4689])[0-3]"],"0$1"],["(\\d{5})(\\d{4,5})","$1 $2",["[12]"],"0$1"]],"0"],MO:["853","00","0800\\d{3}|(?:28|[68]\\d)\\d{6}",[7,8],[["(\\d{4})(\\d{3})","$1 $2",["0"]],["(\\d{4})(\\d{4})","$1 $2",["[268]"]]]],MP:["1","011","[58]\\d{9}|(?:67|90)0\\d{7}",[10],0,"1",0,"([2-9]\\d{6})$|1","670$1",0,"670"],MQ:["596","00","(?:596\\d|7091)\\d{5}|(?:69|[89]\\d)\\d{7}",[9],[["(\\d{3})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["[5-79]|8(?:0[6-9]|[36])"],"0$1"],["(\\d{3})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["8"],"0$1"]],"0"],MR:["222","00","(?:[2-4]\\d\\d|800)\\d{5}",[8],[["(\\d{2})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["[2-48]"]]]],MS:["1","011","(?:[58]\\d\\d|664|900)\\d{7}",[10],0,"1",0,"([34]\\d{6})$|1","664$1",0,"664"],MT:["356","00","3550\\d{4}|(?:[2579]\\d\\d|800)\\d{5}",[8],[["(\\d{4})(\\d{4})","$1 $2",["[2357-9]"]]]],MU:["230","0(?:0|[24-7]0|3[03])","(?:[57]|8\\d\\d)\\d{7}|[2-468]\\d{6}",[7,8,10],[["(\\d{3})(\\d{4})","$1 $2",["[2-46]|8[013]"]],["(\\d{4})(\\d{4})","$1 $2",["[57]"]],["(\\d{5})(\\d{5})","$1 $2",["8"]]],0,0,0,0,0,0,0,"020"],MV:["960","0(?:0|19)","(?:800|9[0-57-9]\\d)\\d{7}|[34679]\\d{6}",[7,10],[["(\\d{3})(\\d{4})","$1-$2",["[34679]"]],["(\\d{3})(\\d{3})(\\d{4})","$1 $2 $3",["[89]"]]],0,0,0,0,0,0,0,"00"],MW:["265","00","(?:[1289]\\d|31|77)\\d{7}|1\\d{6}",[7,9],[["(\\d)(\\d{3})(\\d{3})","$1 $2 $3",["1[2-9]"],"0$1"],["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["2"],"0$1"],["(\\d{3})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["[137-9]"],"0$1"]],"0"],MX:["52","0[09]","[2-9]\\d{9}",[10],[["(\\d{2})(\\d{4})(\\d{4})","$1 $2 $3",["33|5[56]|81"]],["(\\d{3})(\\d{3})(\\d{4})","$1 $2 $3",["[2-9]"]]],0,0,0,0,0,0,0,"00"],MY:["60","00","1\\d{8,9}|(?:3\\d|[4-9])\\d{7}",[8,9,10],[["(\\d)(\\d{3})(\\d{4})","$1-$2 $3",["[4-79]"],"0$1"],["(\\d{2})(\\d{3})(\\d{3,4})","$1-$2 $3",["1(?:[02469]|[378][1-9]|53)|8","1(?:[02469]|[37][1-9]|53|8(?:[1-46-9]|5[7-9]))|8"],"0$1"],["(\\d)(\\d{4})(\\d{4})","$1-$2 $3",["3"],"0$1"],["(\\d)(\\d{3})(\\d{2})(\\d{4})","$1-$2-$3-$4",["1(?:[367]|80)"]],["(\\d{3})(\\d{3})(\\d{4})","$1-$2 $3",["15"],"0$1"],["(\\d{2})(\\d{4})(\\d{4})","$1-$2 $3",["1"],"0$1"]],"0"],MZ:["258","00","(?:2|8\\d)\\d{7}",[8,9],[["(\\d{2})(\\d{3})(\\d{3,4})","$1 $2 $3",["2|8[2-79]"]],["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["8"]]]],NA:["264","00","[68]\\d{7,8}",[8,9],[["(\\d{2})(\\d{3})(\\d{3})","$1 $2 $3",["88"],"0$1"],["(\\d{2})(\\d{3})(\\d{3,4})","$1 $2 $3",["6"],"0$1"],["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["87"],"0$1"],["(\\d{2})(\\d{3})(\\d{4})","$1 $2 $3",["8"],"0$1"]],"0"],NC:["687","00","(?:050|[2-57-9]\\d\\d)\\d{3}",[6],[["(\\d{2})(\\d{2})(\\d{2})","$1.$2.$3",["[02-57-9]"]]]],NE:["227","00","[027-9]\\d{7}",[8],[["(\\d{2})(\\d{3})(\\d{3})","$1 $2 $3",["08"]],["(\\d{2})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["[089]|2[013]|7[0467]"]]]],NF:["672","00","[13]\\d{5}",[6],[["(\\d{2})(\\d{4})","$1 $2",["1[0-3]"]],["(\\d)(\\d{5})","$1 $2",["[13]"]]],0,0,"([0-258]\\d{4})$","3$1"],NG:["234","009","(?:20|9\\d)\\d{8}|[78]\\d{9,13}",[10,11,12,13,14],[["(\\d{3})(\\d{3})(\\d{3,4})","$1 $2 $3",["[7-9]"],"0$1"],["(\\d{3})(\\d{3})(\\d{4})","$1 $2 $3",["20[129]"],"0$1"],["(\\d{4})(\\d{2})(\\d{4})","$1 $2 $3",["2"],"0$1"],["(\\d{3})(\\d{4})(\\d{4,5})","$1 $2 $3",["[78]"],"0$1"],["(\\d{3})(\\d{5})(\\d{5,6})","$1 $2 $3",["[78]"],"0$1"]],"0"],NI:["505","00","(?:1800|[25-8]\\d{3})\\d{4}",[8],[["(\\d{4})(\\d{4})","$1 $2",["[125-8]"]]]],NL:["31","00","(?:[124-7]\\d\\d|3(?:[02-9]\\d|1[0-8]))\\d{6}|8\\d{6,9}|9\\d{6,10}|1\\d{4,5}",[5,6,7,8,9,10,11],[["(\\d{3})(\\d{4,7})","$1 $2",["[89]0"],"0$1"],["(\\d{2})(\\d{7})","$1 $2",["66"],"0$1"],["(\\d)(\\d{8})","$1 $2",["6"],"0$1"],["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["1[16-8]|2[259]|3[124]|4[17-9]|5[124679]"],"0$1"],["(\\d{2})(\\d{3})(\\d{4})","$1 $2 $3",["[1-578]|91"],"0$1"],["(\\d{3})(\\d{3})(\\d{5})","$1 $2 $3",["9"],"0$1"]],"0"],NO:["47","00","(?:0|[2-9]\\d{3})\\d{4}",[5,8],[["(\\d{3})(\\d{2})(\\d{3})","$1 $2 $3",["8"]],["(\\d{2})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["[2-79]"]]],0,0,0,0,0,"[02-689]|7[0-8]"],NP:["977","00","(?:1\\d|9)\\d{9}|[1-9]\\d{7}",[8,10,11],[["(\\d)(\\d{7})","$1-$2",["1[2-6]"],"0$1"],["(\\d{2})(\\d{6})","$1-$2",["1[01]|[2-8]|9(?:[1-59]|[67][2-6])"],"0$1"],["(\\d{3})(\\d{7})","$1-$2",["9"]]],"0"],NR:["674","00","(?:222|444|(?:55|8\\d)\\d|666|777|999)\\d{4}",[7],[["(\\d{3})(\\d{4})","$1 $2",["[24-9]"]]]],NU:["683","00","(?:[4-7]|888\\d)\\d{3}",[4,7],[["(\\d{3})(\\d{4})","$1 $2",["8"]]]],NZ:["64","0(?:0|161)","[1289]\\d{9}|50\\d{5}(?:\\d{2,3})?|[27-9]\\d{7,8}|(?:[34]\\d|6[0-35-9])\\d{6}|8\\d{4,6}",[5,6,7,8,9,10],[["(\\d{2})(\\d{3,8})","$1 $2",["8[1-79]"],"0$1"],["(\\d{3})(\\d{2})(\\d{2,3})","$1 $2 $3",["50[036-8]|8|90","50(?:[0367]|88)|8|90"],"0$1"],["(\\d)(\\d{3})(\\d{4})","$1 $2 $3",["24|[346]|7[2-57-9]|9[2-9]"],"0$1"],["(\\d{3})(\\d{3})(\\d{3,4})","$1 $2 $3",["2(?:10|74)|[589]"],"0$1"],["(\\d{2})(\\d{3,4})(\\d{4})","$1 $2 $3",["1|2[028]"],"0$1"],["(\\d{2})(\\d{3})(\\d{3,5})","$1 $2 $3",["2(?:[169]|7[0-35-9])|7"],"0$1"]],"0",0,0,0,0,0,0,"00"],OM:["968","00","(?:1505|[279]\\d{3}|500)\\d{4}|800\\d{5,6}",[7,8,9],[["(\\d{3})(\\d{4,6})","$1 $2",["[58]"]],["(\\d{2})(\\d{6})","$1 $2",["2"]],["(\\d{4})(\\d{4})","$1 $2",["[179]"]]]],PA:["507","00","(?:00800|8\\d{3})\\d{6}|[68]\\d{7}|[1-57-9]\\d{6}",[7,8,10,11],[["(\\d{3})(\\d{4})","$1-$2",["[1-57-9]"]],["(\\d{4})(\\d{4})","$1-$2",["[68]"]],["(\\d{3})(\\d{3})(\\d{4})","$1 $2 $3",["8"]]]],PE:["51","00|19(?:1[124]|77|90)00","(?:[14-8]|9\\d)\\d{7}",[8,9],[["(\\d{3})(\\d{5})","$1 $2",["80"],"(0$1)"],["(\\d)(\\d{7})","$1 $2",["1"],"(0$1)"],["(\\d{2})(\\d{6})","$1 $2",["[4-8]"],"(0$1)"],["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["9"]]],"0",0,0,0,0,0,0,"00"," Anexo "],PF:["689","00","4\\d{5}(?:\\d{2})?|8\\d{7,8}",[6,8,9],[["(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3",["44"]],["(\\d{2})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["4|8[7-9]"]],["(\\d{3})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["8"]]]],PG:["675","00|140[1-3]","(?:180|[78]\\d{3})\\d{4}|(?:[2-589]\\d|64)\\d{5}",[7,8],[["(\\d{3})(\\d{4})","$1 $2",["18|[2-69]|85"]],["(\\d{4})(\\d{4})","$1 $2",["[78]"]]],0,0,0,0,0,0,0,"00"],PH:["63","00","(?:[2-7]|9\\d)\\d{8}|2\\d{5}|(?:1800|8)\\d{7,9}",[6,8,9,10,11,12,13],[["(\\d)(\\d{5})","$1 $2",["2"],"(0$1)"],["(\\d{4})(\\d{4,6})","$1 $2",["3(?:23|39|46)|4(?:2[3-6]|[35]9|4[26]|76)|544|88[245]|(?:52|64|86)2","3(?:230|397|461)|4(?:2(?:35|[46]4|51)|396|4(?:22|63)|59[347]|76[15])|5(?:221|446)|642[23]|8(?:622|8(?:[24]2|5[13]))"],"(0$1)"],["(\\d{5})(\\d{4})","$1 $2",["346|4(?:27|9[35])|883","3469|4(?:279|9(?:30|56))|8834"],"(0$1)"],["(\\d)(\\d{4})(\\d{4})","$1 $2 $3",["2"],"(0$1)"],["(\\d{2})(\\d{3})(\\d{4})","$1 $2 $3",["[3-7]|8[2-8]"],"(0$1)"],["(\\d{3})(\\d{3})(\\d{4})","$1 $2 $3",["[89]"],"0$1"],["(\\d{4})(\\d{3})(\\d{4})","$1 $2 $3",["1"]],["(\\d{4})(\\d{1,2})(\\d{3})(\\d{4})","$1 $2 $3 $4",["1"]]],"0"],PK:["92","00","122\\d{6}|[24-8]\\d{10,11}|9(?:[013-9]\\d{8,10}|2(?:[01]\\d\\d|2(?:[06-8]\\d|1[01]))\\d{7})|(?:[2-8]\\d{3}|92(?:[0-7]\\d|8[1-9]))\\d{6}|[24-9]\\d{8}|[89]\\d{7}",[8,9,10,11,12],[["(\\d{3})(\\d{3})(\\d{2,7})","$1 $2 $3",["[89]0"],"0$1"],["(\\d{4})(\\d{5})","$1 $2",["1"]],["(\\d{3})(\\d{6,7})","$1 $2",["2(?:3[2358]|4[2-4]|9[2-8])|45[3479]|54[2-467]|60[468]|72[236]|8(?:2[2-689]|3[23578]|4[3478]|5[2356])|9(?:2[2-8]|3[27-9]|4[2-6]|6[3569]|9[25-8])","9(?:2[3-8]|98)|(?:2(?:3[2358]|4[2-4]|9[2-8])|45[3479]|54[2-467]|60[468]|72[236]|8(?:2[2-689]|3[23578]|4[3478]|5[2356])|9(?:22|3[27-9]|4[2-6]|6[3569]|9[25-7]))[2-9]"],"(0$1)"],["(\\d{2})(\\d{7,8})","$1 $2",["(?:2[125]|4[0-246-9]|5[1-35-7]|6[1-8]|7[14]|8[16]|91)[2-9]"],"(0$1)"],["(\\d{5})(\\d{5})","$1 $2",["58"],"(0$1)"],["(\\d{3})(\\d{7})","$1 $2",["3"],"0$1"],["(\\d{2})(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3 $4",["2[125]|4[0-246-9]|5[1-35-7]|6[1-8]|7[14]|8[16]|91"],"(0$1)"],["(\\d{3})(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3 $4",["[24-9]"],"(0$1)"]],"0"],PL:["48","00","(?:6|8\\d\\d)\\d{7}|[1-9]\\d{6}(?:\\d{2})?|[26]\\d{5}",[6,7,8,9,10],[["(\\d{5})","$1",["19"]],["(\\d{3})(\\d{3})","$1 $2",["11|20|64"]],["(\\d{2})(\\d{2})(\\d{3})","$1 $2 $3",["(?:1[2-8]|2[2-69]|3[2-4]|4[1-468]|5[24-689]|6[1-3578]|7[14-7]|8[1-79]|9[145])1","(?:1[2-8]|2[2-69]|3[2-4]|4[1-468]|5[24-689]|6[1-3578]|7[14-7]|8[1-79]|9[145])19"]],["(\\d{3})(\\d{2})(\\d{2,3})","$1 $2 $3",["64"]],["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["21|39|45|5[0137]|6[0469]|7[02389]|8(?:0[14]|8)"]],["(\\d{2})(\\d{3})(\\d{2})(\\d{2})","$1 $2 $3 $4",["1[2-8]|[2-7]|8[1-79]|9[145]"]],["(\\d{3})(\\d{3})(\\d{3,4})","$1 $2 $3",["8"]]]],PM:["508","00","[45]\\d{5}|(?:708|8\\d\\d)\\d{6}",[6,9],[["(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3",["[45]"],"0$1"],["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["7"]],["(\\d{3})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["8"],"0$1"]],"0"],PR:["1","011","(?:[589]\\d\\d|787)\\d{7}",[10],0,"1",0,0,0,0,"787|939"],PS:["970","00","[2489]2\\d{6}|(?:1\\d|5)\\d{8}",[8,9,10],[["(\\d)(\\d{3})(\\d{4})","$1 $2 $3",["[2489]"],"0$1"],["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["5"],"0$1"],["(\\d{4})(\\d{3})(\\d{3})","$1 $2 $3",["1"]]],"0"],PT:["351","00","1693\\d{5}|(?:[26-9]\\d|30)\\d{7}",[9],[["(\\d{2})(\\d{3})(\\d{4})","$1 $2 $3",["2[12]"]],["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["16|[236-9]"]]]],PW:["680","01[12]","(?:[24-8]\\d\\d|345|900)\\d{4}",[7],[["(\\d{3})(\\d{4})","$1 $2",["[2-9]"]]]],PY:["595","00","[36-8]\\d{5,8}|4\\d{6,8}|59\\d{6}|9\\d{5,10}|(?:2\\d|5[0-8])\\d{6,7}",[6,7,8,9,10,11],[["(\\d{3})(\\d{3,6})","$1 $2",["[2-9]0"],"0$1"],["(\\d{2})(\\d{5})","$1 $2",["3[289]|4[246-8]|61|7[1-3]|8[1-36]"],"(0$1)"],["(\\d{3})(\\d{4,5})","$1 $2",["2[279]|3[13-5]|4[359]|5|6(?:[34]|7[1-46-8])|7[46-8]|85"],"(0$1)"],["(\\d{2})(\\d{3})(\\d{3,4})","$1 $2 $3",["2[14-68]|3[26-9]|4[1246-8]|6(?:1|75)|7[1-35]|8[1-36]"],"(0$1)"],["(\\d{2})(\\d{3})(\\d{4})","$1 $2 $3",["87"]],["(\\d{3})(\\d{6})","$1 $2",["9(?:[5-79]|8[1-7])"],"0$1"],["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["[2-8]"],"0$1"],["(\\d{4})(\\d{3})(\\d{4})","$1 $2 $3",["9"]]],"0"],QA:["974","00","800\\d{4}|(?:2|800)\\d{6}|(?:0080|[3-7])\\d{7}",[7,8,9,11],[["(\\d{3})(\\d{4})","$1 $2",["2[136]|8"]],["(\\d{4})(\\d{4})","$1 $2",["[3-7]"]]]],RE:["262","00","709\\d{6}|(?:26|[689]\\d)\\d{7}",[9],[["(\\d{3})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["[26-9]"],"0$1"]],"0",0,0,0,0,0,[["26(?:2\\d\\d|3(?:0\\d|1[0-6]))\\d{4}"],["(?:69(?:2\\d\\d|3(?:[06][0-6]|1[0-3]|2[0-2]|3[0-39]|4\\d|5[0-5]|7[0-37]|8[0-8]|9[0-479]))|7092[0-3])\\d{4}"],["80\\d{7}"],["89[1-37-9]\\d{6}"],0,0,0,0,["9(?:399[0-3]|479[0-6]|76(?:2[278]|3[0-37]))\\d{4}"],["8(?:1[019]|2[0156]|84|90)\\d{6}"]]],RO:["40","00","(?:[236-8]\\d|90)\\d{7}|[23]\\d{5}",[6,9],[["(\\d{3})(\\d{3})","$1 $2",["2[3-6]","2[3-6]\\d9"],"0$1"],["(\\d{2})(\\d{4})","$1 $2",["219|31"],"0$1"],["(\\d{2})(\\d{3})(\\d{4})","$1 $2 $3",["[23]1"],"0$1"],["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["[236-9]"],"0$1"]],"0",0,0,0,0,0,0,0," int "],RS:["381","00","38[02-9]\\d{6,9}|6\\d{7,9}|90\\d{4,8}|38\\d{5,6}|(?:7\\d\\d|800)\\d{3,9}|(?:[12]\\d|3[0-79])\\d{5,10}",[6,7,8,9,10,11,12],[["(\\d{3})(\\d{3,9})","$1 $2",["(?:2[389]|39)0|[7-9]"],"0$1"],["(\\d{2})(\\d{5,10})","$1 $2",["[1-36]"],"0$1"]],"0"],RU:["7","810","8\\d{13}|[347-9]\\d{9}",[10,14],[["(\\d{4})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["7(?:1[0-8]|2[1-9])","7(?:1(?:[0-356]2|4[29]|7|8[27])|2(?:1[23]|[2-9]2))","7(?:1(?:[0-356]2|4[29]|7|8[27])|2(?:13[03-69]|62[013-9]))|72[1-57-9]2"],"8 ($1)",1],["(\\d{5})(\\d)(\\d{2})(\\d{2})","$1 $2 $3 $4",["7(?:1[0-68]|2[1-9])","7(?:1(?:[06][3-6]|[18]|2[35]|[3-5][3-5])|2(?:[13][3-5]|[24-689]|7[457]))","7(?:1(?:0(?:[356]|4[023])|[18]|2(?:3[013-9]|5)|3[45]|43[013-79]|5(?:3[1-8]|4[1-7]|5)|6(?:3[0-35-9]|[4-6]))|2(?:1(?:3[178]|[45])|[24-689]|3[35]|7[457]))|7(?:14|23)4[0-8]|71(?:33|45)[1-79]"],"8 ($1)",1],["(\\d{3})(\\d{3})(\\d{4})","$1 $2 $3",["7"],"8 ($1)",1],["(\\d{3})(\\d{3})(\\d{2})(\\d{2})","$1 $2-$3-$4",["[349]|8(?:[02-7]|1[1-8])"],"8 ($1)",1],["(\\d{4})(\\d{4})(\\d{3})(\\d{3})","$1 $2 $3 $4",["8"],"8 ($1)"]],"8",0,0,0,0,"[3489]",0,"8~10"],RW:["250","00","(?:06|[27]\\d\\d|[89]00)\\d{6}",[8,9],[["(\\d{2})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["0"]],["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["2"]],["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["[7-9]"],"0$1"]],"0"],SA:["966","00","(?:[15]\\d|800|92)\\d{7}",[9,10],[["(\\d{4})(\\d{5})","$1 $2",["9"]],["(\\d{2})(\\d{3})(\\d{4})","$1 $2 $3",["1"],"0$1"],["(\\d{2})(\\d{3})(\\d{4})","$1 $2 $3",["5"],"0$1"],["(\\d{3})(\\d{3})(\\d{4})","$1 $2 $3",["8"]]],"0"],SB:["677","0[01]","[6-9]\\d{6}|[1-6]\\d{4}",[5,7],[["(\\d{2})(\\d{5})","$1 $2",["6[89]|7|8[4-9]|9(?:[1-8]|9[0-8])"]]]],SC:["248","010|0[0-2]","(?:[2489]\\d|64)\\d{5}",[7],[["(\\d)(\\d{3})(\\d{3})","$1 $2 $3",["[246]|9[57]"]]],0,0,0,0,0,0,0,"00"],SD:["249","00","[19]\\d{8}",[9],[["(\\d{2})(\\d{3})(\\d{4})","$1 $2 $3",["[19]"],"0$1"]],"0"],SE:["46","00","(?:[26]\\d\\d|9)\\d{9}|[1-9]\\d{8}|[1-689]\\d{7}|[1-4689]\\d{6}|2\\d{5}",[6,7,8,9,10,12],[["(\\d{2})(\\d{2,3})(\\d{2})","$1-$2 $3",["20"],"0$1",0,"$1 $2 $3"],["(\\d{3})(\\d{4})","$1-$2",["9(?:00|39|44|9)"],"0$1",0,"$1 $2"],["(\\d{2})(\\d{3})(\\d{2})","$1-$2 $3",["[12][136]|3[356]|4[0246]|6[03]|90[1-9]"],"0$1",0,"$1 $2 $3"],["(\\d)(\\d{2,3})(\\d{2})(\\d{2})","$1-$2 $3 $4",["8"],"0$1",0,"$1 $2 $3 $4"],["(\\d{3})(\\d{2,3})(\\d{2})","$1-$2 $3",["1[2457]|2(?:[247-9]|5[0138])|3[0247-9]|4[1357-9]|5[0-35-9]|6(?:[125689]|4[02-57]|7[0-2])|9(?:[125-8]|3[02-5]|4[0-3])"],"0$1",0,"$1 $2 $3"],["(\\d{3})(\\d{2,3})(\\d{3})","$1-$2 $3",["9(?:00|39|44)"],"0$1",0,"$1 $2 $3"],["(\\d{2})(\\d{2,3})(\\d{2})(\\d{2})","$1-$2 $3 $4",["1[13689]|2[0136]|3[1356]|4[0246]|54|6[03]|90[1-9]"],"0$1",0,"$1 $2 $3 $4"],["(\\d{2})(\\d{3})(\\d{2})(\\d{2})","$1-$2 $3 $4",["10|7"],"0$1",0,"$1 $2 $3 $4"],["(\\d)(\\d{3})(\\d{3})(\\d{2})","$1-$2 $3 $4",["8"],"0$1",0,"$1 $2 $3 $4"],["(\\d{3})(\\d{2})(\\d{2})(\\d{2})","$1-$2 $3 $4",["[13-5]|2(?:[247-9]|5[0138])|6(?:[124-689]|7[0-2])|9(?:[125-8]|3[02-5]|4[0-3])"],"0$1",0,"$1 $2 $3 $4"],["(\\d{3})(\\d{2})(\\d{2})(\\d{3})","$1-$2 $3 $4",["9"],"0$1",0,"$1 $2 $3 $4"],["(\\d{3})(\\d{2})(\\d{3})(\\d{2})(\\d{2})","$1-$2 $3 $4 $5",["[26]"],"0$1",0,"$1 $2 $3 $4 $5"]],"0"],SG:["65","0[0-3]\\d","(?:(?:1\\d|8)\\d\\d|7000)\\d{7}|[3689]\\d{7}",[8,10,11],[["(\\d{4})(\\d{4})","$1 $2",["[369]|8(?:0[1-9]|[1-9])"]],["(\\d{3})(\\d{3})(\\d{4})","$1 $2 $3",["8"]],["(\\d{4})(\\d{4})(\\d{3})","$1 $2 $3",["7"]],["(\\d{4})(\\d{3})(\\d{4})","$1 $2 $3",["1"]]]],SH:["290","00","(?:[256]\\d|8)\\d{3}",[4,5],0,0,0,0,0,0,"[256]"],SI:["386","00|10(?:22|66|88|99)","[1-7]\\d{7}|8\\d{4,7}|90\\d{4,6}",[5,6,7,8],[["(\\d{2})(\\d{3,6})","$1 $2",["8[09]|9"],"0$1"],["(\\d{3})(\\d{5})","$1 $2",["59|8"],"0$1"],["(\\d{2})(\\d{3})(\\d{3})","$1 $2 $3",["[37][01]|4[0139]|51|6"],"0$1"],["(\\d)(\\d{3})(\\d{2})(\\d{2})","$1 $2 $3 $4",["[1-57]"],"(0$1)"]],"0",0,0,0,0,0,0,"00"],SJ:["47","00","0\\d{4}|(?:[489]\\d|79)\\d{6}",[5,8],0,0,0,0,0,0,"79"],SK:["421","00","[2-689]\\d{8}|[2-59]\\d{6}|[2-5]\\d{5}",[6,7,9],[["(\\d)(\\d{2})(\\d{3,4})","$1 $2 $3",["21"],"0$1"],["(\\d{2})(\\d{2})(\\d{2,3})","$1 $2 $3",["[3-5][1-8]1","[3-5][1-8]1[67]"],"0$1"],["(\\d)(\\d{3})(\\d{3})(\\d{2})","$1/$2 $3 $4",["2"],"0$1"],["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["[689]"],"0$1"],["(\\d{2})(\\d{3})(\\d{2})(\\d{2})","$1/$2 $3 $4",["[3-5]"],"0$1"]],"0"],SL:["232","00","(?:[237-9]\\d|66)\\d{6}",[8],[["(\\d{2})(\\d{6})","$1 $2",["[236-9]"],"(0$1)"]],"0"],SM:["378","00","(?:0549|[5-7]\\d)\\d{6}",[8,10],[["(\\d{2})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["[5-7]"]],["(\\d{4})(\\d{6})","$1 $2",["0"]]],0,0,"([89]\\d{5})$","0549$1"],SN:["221","00","(?:[378]\\d|93)\\d{7}",[9],[["(\\d{3})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["8"]],["(\\d{2})(\\d{3})(\\d{2})(\\d{2})","$1 $2 $3 $4",["[379]"]]]],SO:["252","00","[346-9]\\d{8}|[12679]\\d{7}|[1-5]\\d{6}|[1348]\\d{5}",[6,7,8,9],[["(\\d{2})(\\d{4})","$1 $2",["8[125]"]],["(\\d{6})","$1",["[134]"]],["(\\d)(\\d{6})","$1 $2",["[15]|2[0-79]|3[0-46-8]|4[0-7]"]],["(\\d)(\\d{7})","$1 $2",["(?:2|90)4|[67]"]],["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["[348]|64|79|90"]],["(\\d{2})(\\d{5,7})","$1 $2",["1|28|6[0-35-9]|7[67]|9[2-9]"]]],"0"],SR:["597","00","(?:[2-5]|[6-8]\\d|90)\\d{5}",[6,7],[["(\\d{2})(\\d{2})(\\d{2})","$1-$2-$3",["56"]],["(\\d{3})(\\d{3})","$1-$2",["[2-5]"]],["(\\d{3})(\\d{4})","$1-$2",["[6-9]"]]]],SS:["211","00","[19]\\d{8}",[9],[["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["[19]"],"0$1"]],"0"],ST:["239","00","(?:22|9\\d)\\d{5}",[7],[["(\\d{3})(\\d{4})","$1 $2",["[29]"]]]],SV:["503","00","[25-7]\\d{7}|(?:80\\d|900)\\d{4}(?:\\d{4})?",[7,8,11],[["(\\d{3})(\\d{4})","$1 $2",["[89]"]],["(\\d{4})(\\d{4})","$1 $2",["[25-7]"]],["(\\d{3})(\\d{4})(\\d{4})","$1 $2 $3",["[89]"]]]],SX:["1","011","7215\\d{6}|(?:[58]\\d\\d|900)\\d{7}",[10],0,"1",0,"(5\\d{6})$|1","721$1",0,"721"],SY:["963","00","[1-359]\\d{8}|[1-5]\\d{7}",[8,9],[["(\\d{2})(\\d{3})(\\d{3,4})","$1 $2 $3",["[1-4]|5[1-3]"],"0$1",1],["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["[59]"],"0$1",1]],"0"],SZ:["268","00","0800\\d{4}|(?:[237]\\d|900)\\d{6}",[8,9],[["(\\d{4})(\\d{4})","$1 $2",["[0237]"]],["(\\d{5})(\\d{4})","$1 $2",["9"]]]],TA:["290","00","8\\d{3}",[4],0,0,0,0,0,0,"8"],TC:["1","011","(?:[58]\\d\\d|649|900)\\d{7}",[10],0,"1",0,"([2-479]\\d{6})$|1","649$1",0,"649"],TD:["235","00|16","(?:22|30|[689]\\d|77)\\d{6}",[8],[["(\\d{2})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["[236-9]"]]],0,0,0,0,0,0,0,"00"],TG:["228","00","[279]\\d{7}",[8],[["(\\d{2})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["[279]"]]]],TH:["66","00[1-9]","(?:001800|[2-57]|[689]\\d)\\d{7}|1\\d{7,9}",[8,9,10,13],[["(\\d)(\\d{3})(\\d{4})","$1 $2 $3",["2"],"0$1"],["(\\d{2})(\\d{3})(\\d{3,4})","$1 $2 $3",["[13-9]"],"0$1"],["(\\d{4})(\\d{3})(\\d{3})","$1 $2 $3",["1"]]],"0"],TJ:["992","810","(?:[0-57-9]\\d|66)\\d{7}",[9],[["(\\d{6})(\\d)(\\d{2})","$1 $2 $3",["331","3317"]],["(\\d{3})(\\d{2})(\\d{4})","$1 $2 $3",["44[02-479]|[34]7"]],["(\\d{4})(\\d)(\\d{4})","$1 $2 $3",["3(?:[1245]|3[12])"]],["(\\d{2})(\\d{3})(\\d{4})","$1 $2 $3",["\\d"]]],0,0,0,0,0,0,0,"8~10"],TK:["690","00","[2-47]\\d{3,6}",[4,5,6,7]],TL:["670","00","7\\d{7}|(?:[2-47]\\d|[89]0)\\d{5}",[7,8],[["(\\d{3})(\\d{4})","$1 $2",["[2-489]|70"]],["(\\d{4})(\\d{4})","$1 $2",["7"]]]],TM:["993","810","(?:[1-6]\\d|71)\\d{6}",[8],[["(\\d{2})(\\d{2})(\\d{2})(\\d{2})","$1 $2-$3-$4",["12"],"(8 $1)"],["(\\d{3})(\\d)(\\d{2})(\\d{2})","$1 $2-$3-$4",["[1-5]"],"(8 $1)"],["(\\d{2})(\\d{6})","$1 $2",["[67]"],"8 $1"]],"8",0,0,0,0,0,0,"8~10"],TN:["216","00","[2-57-9]\\d{7}",[8],[["(\\d{2})(\\d{3})(\\d{3})","$1 $2 $3",["[2-57-9]"]]]],TO:["676","00","(?:0800|(?:[5-8]\\d\\d|999)\\d)\\d{3}|[2-8]\\d{4}",[5,7],[["(\\d{2})(\\d{3})","$1-$2",["[2-4]|50|6[09]|7[0-24-69]|8[05]"]],["(\\d{4})(\\d{3})","$1 $2",["0"]],["(\\d{3})(\\d{4})","$1 $2",["[5-9]"]]]],TR:["90","00","4\\d{6}|8\\d{11,12}|(?:[2-58]\\d\\d|900)\\d{7}",[7,10,12,13],[["(\\d{3})(\\d{3})(\\d{4})","$1 $2 $3",["512|8[01589]|90"],"0$1",1],["(\\d{3})(\\d{3})(\\d{2})(\\d{2})","$1 $2 $3 $4",["5(?:[0-579]|61)","5(?:[0-579]|61[06])","5(?:[0-579]|61[06]1)"],"0$1",1],["(\\d{3})(\\d{3})(\\d{2})(\\d{2})","$1 $2 $3 $4",["[24][1-8]|3[1-9]"],"(0$1)",1],["(\\d{3})(\\d{3})(\\d{6,7})","$1 $2 $3",["80"],"0$1",1]],"0"],TT:["1","011","(?:[58]\\d\\d|900)\\d{7}",[10],0,"1",0,"([2-46-8]\\d{6})$|1","868$1",0,"868"],TV:["688","00","(?:2|7\\d\\d|90)\\d{4}",[5,6,7],[["(\\d{2})(\\d{3})","$1 $2",["2"]],["(\\d{2})(\\d{4})","$1 $2",["90"]],["(\\d{2})(\\d{5})","$1 $2",["7"]]]],TW:["886","0(?:0[25-79]|19)","[2-689]\\d{8}|7\\d{9,10}|[2-8]\\d{7}|2\\d{6}",[7,8,9,10,11],[["(\\d{2})(\\d)(\\d{4})","$1 $2 $3",["202"],"0$1"],["(\\d{2})(\\d{3})(\\d{3,4})","$1 $2 $3",["[258]0"],"0$1"],["(\\d)(\\d{3,4})(\\d{4})","$1 $2 $3",["[23568]|4(?:0[02-48]|[1-47-9])|7[1-9]","[23568]|4(?:0[2-48]|[1-47-9])|(?:400|7)[1-9]"],"0$1"],["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["[49]"],"0$1"],["(\\d{2})(\\d{4})(\\d{4,5})","$1 $2 $3",["7"],"0$1"]],"0",0,0,0,0,0,0,0,"#"],TZ:["255","00[056]","(?:[25-8]\\d|41|90)\\d{7}",[9],[["(\\d{3})(\\d{2})(\\d{4})","$1 $2 $3",["[89]"],"0$1"],["(\\d{2})(\\d{3})(\\d{4})","$1 $2 $3",["[24]"],"0$1"],["(\\d{2})(\\d{7})","$1 $2",["5"]],["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["[67]"],"0$1"]],"0"],UA:["380","00","[89]\\d{9}|[3-9]\\d{8}",[9,10],[["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["6[12][29]|(?:3[1-8]|4[136-8]|5[12457]|6[49])2|(?:56|65)[24]","6[12][29]|(?:35|4[1378]|5[12457]|6[49])2|(?:56|65)[24]|(?:3[1-46-8]|46)2[013-9]"],"0$1"],["(\\d{4})(\\d{5})","$1 $2",["3[1-8]|4(?:[1367]|[45][6-9]|8[4-6])|5(?:[1-5]|6[0135689]|7[4-6])|6(?:[12][3-7]|[459])","3[1-8]|4(?:[1367]|[45][6-9]|8[4-6])|5(?:[1-5]|6(?:[015689]|3[02389])|7[4-6])|6(?:[12][3-7]|[459])"],"0$1"],["(\\d{2})(\\d{3})(\\d{4})","$1 $2 $3",["[3-7]|89|9[1-9]"],"0$1"],["(\\d{3})(\\d{3})(\\d{3,4})","$1 $2 $3",["[89]"],"0$1"]],"0",0,0,0,0,0,0,"0~0"],UG:["256","00[057]","800\\d{6}|(?:[29]0|[347]\\d)\\d{7}",[9],[["(\\d{4})(\\d{5})","$1 $2",["202","2024"],"0$1"],["(\\d{3})(\\d{6})","$1 $2",["[27-9]|4(?:6[45]|[7-9])"],"0$1"],["(\\d{2})(\\d{7})","$1 $2",["[34]"],"0$1"]],"0"],US:["1","011","[2-9]\\d{9}|3\\d{6}",[10],[["(\\d{3})(\\d{4})","$1-$2",["310"],0,1],["(\\d{3})(\\d{3})(\\d{4})","($1) $2-$3",["[2-9]"],0,1,"$1-$2-$3"]],"1",0,0,0,0,0,[["(?:274[27]|(?:472|983)[2-47-9])\\d{6}|(?:2(?:0[1-35-9]|1[02-9]|2[03-57-9]|3[1459]|4[08]|5[1-46]|6[0279]|7[0269]|8[13])|3(?:0[1-57-9]|1[02-9]|2[013-79]|3[0-24679]|4[167]|5[0-3]|6[01349]|8[056])|4(?:0[124-9]|1[02-579]|2[3-5]|3[0245]|4[023578]|58|6[349]|7[0589]|8[04])|5(?:0[1-57-9]|1[0235-8]|20|3[0149]|4[01]|5[179]|6[1-47]|7[0-5]|8[0256])|6(?:0[1-35-9]|1[024-9]|2[03689]|3[016]|4[0156]|5[01679]|6[0-279]|78|8[0-269])|7(?:0[1-46-8]|1[2-9]|2[04-8]|3[0-247]|4[0378]|5[47]|6[02359]|7[0-59]|8[156])|8(?:0[1-68]|1[02-8]|2[0168]|3[0-2589]|4[03578]|5[046-9]|6[02-5]|7[028])|9(?:0[1346-9]|1[02-9]|2[0589]|3[0146-8]|4[01357-9]|5[12469]|7[0-3589]|8[04-69]))[2-9]\\d{6}"],[""],["8(?:00|33|44|55|66|77|88)[2-9]\\d{6}"],["900[2-9]\\d{6}"],["52(?:3(?:[2-46-9][02-9]\\d|5(?:[02-46-9]\\d|5[0-46-9]))|4(?:[2-478][02-9]\\d|5(?:[034]\\d|2[024-9]|5[0-46-9])|6(?:0[1-9]|[2-9]\\d)|9(?:[05-9]\\d|2[0-5]|49)))\\d{4}|52[34][2-9]1[02-9]\\d{4}|5(?:00|2[125-9]|3[23]|44|66|77|88)[2-9]\\d{6}"]]],UY:["598","0(?:0|1[3-9]\\d)","0004\\d{2,9}|[1249]\\d{7}|2\\d{3,4}|(?:[49]\\d|80)\\d{5}",[4,5,6,7,8,9,10,11,12,13],[["(\\d{4,5})","$1",["21"]],["(\\d{3})(\\d{3,4})","$1 $2",["0"]],["(\\d{3})(\\d{4})","$1 $2",["[49]0|8"],"0$1"],["(\\d{2})(\\d{3})(\\d{3})","$1 $2 $3",["9"],"0$1"],["(\\d{4})(\\d{4})","$1 $2",["[124]"]],["(\\d{3})(\\d{3})(\\d{2,4})","$1 $2 $3",["0"]],["(\\d{3})(\\d{3})(\\d{3})(\\d{2,4})","$1 $2 $3 $4",["0"]]],"0",0,0,0,0,0,0,"00"," int. "],UZ:["998","00","(?:20|33|[5-9]\\d)\\d{7}",[9],[["(\\d{2})(\\d{3})(\\d{2})(\\d{2})","$1 $2 $3 $4",["[235-9]"]]]],VA:["39","00","0\\d{5,10}|3[0-8]\\d{7,10}|55\\d{8}|8\\d{5}(?:\\d{2,4})?|(?:1\\d|39)\\d{7,8}",[6,7,8,9,10,11,12],0,0,0,0,0,0,"06698"],VC:["1","011","(?:[58]\\d\\d|784|900)\\d{7}",[10],0,"1",0,"([2-7]\\d{6})$|1","784$1",0,"784"],VE:["58","00","[68]00\\d{7}|(?:[24]\\d|[59]0)\\d{8}",[10],[["(\\d{3})(\\d{7})","$1-$2",["[24-689]"],"0$1"]],"0"],VG:["1","011","(?:284|[58]\\d\\d|900)\\d{7}",[10],0,"1",0,"([2-578]\\d{6})$|1","284$1",0,"284"],VI:["1","011","[58]\\d{9}|(?:34|90)0\\d{7}",[10],0,"1",0,"([2-9]\\d{6})$|1","340$1",0,"340"],VN:["84","00","[12]\\d{9}|[135-9]\\d{8}|[16]\\d{7}|[16-8]\\d{6}",[7,8,9,10],[["(\\d{2})(\\d{5})","$1 $2",["80"],"0$1",1],["(\\d{4})(\\d{4,6})","$1 $2",["1"],0,1],["(\\d{2})(\\d{3})(\\d{2})(\\d{2})","$1 $2 $3 $4",["6"],"0$1",1],["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["[357-9]"],"0$1",1],["(\\d{2})(\\d{4})(\\d{4})","$1 $2 $3",["2[48]"],"0$1",1],["(\\d{3})(\\d{4})(\\d{3})","$1 $2 $3",["2"],"0$1",1]],"0"],VU:["678","00","[57-9]\\d{6}|(?:[238]\\d|48)\\d{3}",[5,7],[["(\\d{3})(\\d{4})","$1 $2",["[57-9]"]]]],WF:["681","00","(?:40|72|8\\d{4})\\d{4}|[89]\\d{5}",[6,9],[["(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3",["[47-9]"]],["(\\d{3})(\\d{2})(\\d{2})(\\d{2})","$1 $2 $3 $4",["8"]]]],WS:["685","0","(?:[2-6]|8\\d{5})\\d{4}|[78]\\d{6}|[68]\\d{5}",[5,6,7,10],[["(\\d{5})","$1",["[2-5]|6[1-9]"]],["(\\d{3})(\\d{3,7})","$1 $2",["[68]"]],["(\\d{2})(\\d{5})","$1 $2",["7"]]]],XK:["383","00","2\\d{7,8}|3\\d{7,11}|(?:4\\d\\d|[89]00)\\d{5}",[8,9,10,11,12],[["(\\d{3})(\\d{5})","$1 $2",["[89]"],"0$1"],["(\\d{2})(\\d{3})(\\d{3})","$1 $2 $3",["[2-4]"],"0$1"],["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["2|39"],"0$1"],["(\\d{2})(\\d{7,10})","$1 $2",["3"],"0$1"]],"0"],YE:["967","00","(?:1|7\\d)\\d{7}|[1-7]\\d{6}",[7,8,9],[["(\\d)(\\d{3})(\\d{3,4})","$1 $2 $3",["[1-6]|7(?:[24-6]|8[0-7])"],"0$1"],["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["7"],"0$1"]],"0"],YT:["262","00","7093\\d{5}|(?:80|9\\d)\\d{7}|(?:26|63)9\\d{6}",[9],0,"0",0,0,0,0,0,[["269(?:0[0-467]|15|5[0-4]|6\\d|[78]0)\\d{4}"],["(?:639(?:0[0-79]|1[019]|[267]\\d|3[09]|40|5[05-9]|9[04-79])|7093[5-7])\\d{4}"],["80\\d{7}"],0,0,0,0,0,["9(?:(?:39|47)8[01]|769\\d)\\d{4}"]]],ZA:["27","00","[1-79]\\d{8}|8\\d{4,9}",[5,6,7,8,9,10],[["(\\d{2})(\\d{3,4})","$1 $2",["8[1-4]"],"0$1"],["(\\d{2})(\\d{3})(\\d{2,3})","$1 $2 $3",["8[1-4]"],"0$1"],["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["860"],"0$1"],["(\\d{2})(\\d{3})(\\d{4})","$1 $2 $3",["[1-9]"],"0$1"],["(\\d{3})(\\d{3})(\\d{4})","$1 $2 $3",["8"],"0$1"]],"0"],ZM:["260","00","800\\d{6}|(?:21|[579]\\d|63)\\d{7}",[9],[["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["[28]"],"0$1"],["(\\d{2})(\\d{7})","$1 $2",["[579]"],"0$1"]],"0"],ZW:["263","00","2(?:[0-57-9]\\d{6,8}|6[0-24-9]\\d{6,7})|[38]\\d{9}|[35-8]\\d{8}|[3-6]\\d{7}|[1-689]\\d{6}|[1-3569]\\d{5}|[1356]\\d{4}",[5,6,7,8,9,10],[["(\\d{3})(\\d{3,5})","$1 $2",["2(?:0[45]|2[278]|[49]8)|3(?:[09]8|17)|6(?:[29]8|37|75)|[23][78]|(?:33|5[15]|6[68])[78]"],"0$1"],["(\\d)(\\d{3})(\\d{2,4})","$1 $2 $3",["[49]"],"0$1"],["(\\d{3})(\\d{4})","$1 $2",["80"],"0$1"],["(\\d{2})(\\d{7})","$1 $2",["24|8[13-59]|(?:2[05-79]|39|5[45]|6[15-8])2","2(?:02[014]|4|[56]20|[79]2)|392|5(?:42|525)|6(?:[16-8]21|52[013])|8[13-59]"],"(0$1)"],["(\\d{2})(\\d{3})(\\d{4})","$1 $2 $3",["7"],"0$1"],["(\\d{3})(\\d{3})(\\d{3,4})","$1 $2 $3",["2(?:1[39]|2[0157]|[378]|[56][14])|3(?:12|29)","2(?:1[39]|2[0157]|[378]|[56][14])|3(?:123|29)"],"0$1"],["(\\d{4})(\\d{6})","$1 $2",["8"],"0$1"],["(\\d{2})(\\d{3,5})","$1 $2",["1|2(?:0[0-36-9]|12|29|[56])|3(?:1[0-689]|[24-6])|5(?:[0236-9]|1[2-4])|6(?:[013-59]|7[0-46-9])|(?:33|55|6[68])[0-69]|(?:29|3[09]|62)[0-79]"],"0$1"],["(\\d{2})(\\d{3})(\\d{3,4})","$1 $2 $3",["29[013-9]|39|54"],"0$1"],["(\\d{4})(\\d{3,5})","$1 $2",["(?:25|54)8","258|5483"],"0$1"]],"0"]},nonGeographic:{800:["800",0,"(?:00|[1-9]\\d)\\d{6}",[8],[["(\\d{4})(\\d{4})","$1 $2",["\\d"]]],0,0,0,0,0,0,[0,0,["(?:00|[1-9]\\d)\\d{6}"]]],808:["808",0,"[1-9]\\d{7}",[8],[["(\\d{4})(\\d{4})","$1 $2",["[1-9]"]]],0,0,0,0,0,0,[0,0,0,0,0,0,0,0,0,["[1-9]\\d{7}"]]],870:["870",0,"7\\d{11}|[235-7]\\d{8}",[9,12],[["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["[235-7]"]]],0,0,0,0,0,0,[0,["(?:[356]|774[45])\\d{8}|7[6-8]\\d{7}"],0,0,0,0,0,0,["2\\d{8}",[9]]]],878:["878",0,"10\\d{10}",[12],[["(\\d{2})(\\d{5})(\\d{5})","$1 $2 $3",["1"]]],0,0,0,0,0,0,[0,0,0,0,0,0,0,0,["10\\d{10}"]]],881:["881",0,"6\\d{9}|[0-36-9]\\d{8}",[9,10],[["(\\d)(\\d{3})(\\d{5})","$1 $2 $3",["[0-37-9]"]],["(\\d)(\\d{3})(\\d{5,6})","$1 $2 $3",["6"]]],0,0,0,0,0,0,[0,["6\\d{9}|[0-36-9]\\d{8}"]]],882:["882",0,"[13]\\d{6}(?:\\d{2,5})?|[19]\\d{7}|(?:[25]\\d\\d|4)\\d{7}(?:\\d{2})?",[7,8,9,10,11,12],[["(\\d{2})(\\d{5})","$1 $2",["16|342"]],["(\\d{2})(\\d{6})","$1 $2",["49"]],["(\\d{2})(\\d{2})(\\d{4})","$1 $2 $3",["1[36]|9"]],["(\\d{2})(\\d{4})(\\d{3})","$1 $2 $3",["3[23]"]],["(\\d{2})(\\d{3,4})(\\d{4})","$1 $2 $3",["16"]],["(\\d{2})(\\d{4})(\\d{4})","$1 $2 $3",["10|23|3(?:[15]|4[57])|4|5[12]"]],["(\\d{3})(\\d{4})(\\d{4})","$1 $2 $3",["34"]],["(\\d{2})(\\d{4,5})(\\d{5})","$1 $2 $3",["[1-35]"]]],0,0,0,0,0,0,[0,["342\\d{4}|(?:337|49)\\d{6}|(?:3(?:2|47|7\\d{3})|5(?:0\\d{3}|2[0-2]))\\d{7}",[7,8,9,10,12]],0,0,0,["348[57]\\d{7}",[11]],0,0,["1(?:3(?:0[0347]|[13][0139]|2[035]|4[013568]|6[0459]|7[06]|8[15-8]|9[0689])\\d{4}|6\\d{5,10})|(?:345\\d|9[89])\\d{6}|(?:10|2(?:3|85\\d)|3(?:[15]|[69]\\d\\d)|4[15-8]|51)\\d{8}"]]],883:["883",0,"(?:[1-4]\\d|51)\\d{6,10}",[8,9,10,11,12],[["(\\d{3})(\\d{3})(\\d{2,8})","$1 $2 $3",["[14]|2[24-689]|3[02-689]|51[24-9]"]],["(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3",["510"]],["(\\d{3})(\\d{3})(\\d{4})","$1 $2 $3",["21"]],["(\\d{4})(\\d{4})(\\d{4})","$1 $2 $3",["51[13]"]],["(\\d{3})(\\d{3})(\\d{3})(\\d{3})","$1 $2 $3 $4",["[235]"]]],0,0,0,0,0,0,[0,0,0,0,0,0,0,0,["(?:2(?:00\\d\\d|10)|(?:370[1-9]|51\\d0)\\d)\\d{7}|51(?:00\\d{5}|[24-9]0\\d{4,7})|(?:1[0-79]|2[24-689]|3[02-689]|4[0-4])0\\d{5,9}"]]],888:["888",0,"\\d{11}",[11],[["(\\d{3})(\\d{3})(\\d{5})","$1 $2 $3"]],0,0,0,0,0,0,[0,0,0,0,0,0,["\\d{11}"]]],979:["979",0,"[1359]\\d{8}",[9],[["(\\d)(\\d{4})(\\d{4})","$1 $2 $3",["[1359]"]]],0,0,0,0,0,0,[0,0,0,["[1359]\\d{8}"]]]}};function
vendor: 12,867 bytes, lines 41-42
41Woe(e,t){var r=Array.prototype.slice.call(t);return r.push(Yoe),e.apply(this,r)}function M6(e,t){e=e.split("-"),t=t.split("-");for(var r=e[0].split("."),i=t[0].split("."),n=0;n<3;n++){var a=Number(r[n]),s=Number(i[n]);if(a>s)return 1;if(s>a)return-1;if(!isNaN(a)&&isNaN(s))return 1;if(isNaN(a)&&!isNaN(s))return-1}return e[1]&&t[1]?e[1]>t[1]?1:e[1]<t[1]?-1:0:!e[1]&&t[1]?1:e[1]&&!t[1]?-1:0}var Zoe={}.constructor;function Ud(e){return e!=null&&e.constructor===Zoe}function vh(e){"@babel/helpers - typeof";return vh=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},vh(e)}function I1(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Koe(e,t){for(var r=0;r<t.length;r++){var i=t[r];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(e,Xoe(i.key),i)}}function A1(e,t,r){return t&&Koe(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e}function Xoe(e){var t=Joe(e,"string");return vh(t)=="symbol"?t:t+""}function Joe(e,t){if(vh(e)!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var i=r.call(e,t);if(vh(i)!="object")return i;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}var Qoe="1.2.0",ele="1.7.35",I6=" ext. ",tle=/^\d+$/,_n=(function(){function e(t){I1(this,e),X9(t),this.metadata=t,J9.call(this,t)}return A1(e,[{key:"getCountries",value:function(){return Object.keys(this.metadata.countries).filter(function(r){return r!=="001"})}},{key:"getCountryMetadata",value:function(r){return this.metadata.countries[r]}},{key:"nonGeographic",value:function(){if(!(this.v1||this.v2||this.v3))return this.metadata.nonGeographic||this.metadata.nonGeographical}},{key:"hasCountry",value:function(r){return this.getCountryMetadata(r)!==void 0}},{key:"hasCallingCode",value:function(r){if(this.getCountryCodesForCallingCode(r))return!0;if(this.nonGeographic()){if(this.nonGeographic()[r])return!0}else{var i=this.countryCallingCodes()[r];if(i&&i.length===1&&i[0]==="001")return!0}}},{key:"isNonGeographicCallingCode",value:function(r){return this.nonGeographic()?!!this.nonGeographic()[r]:!this.getCountryCodesForCallingCode(r)}},{key:"country",value:function(r){return this.selectNumberingPlan(r)}},{key:"selectNumberingPlan",value:function(r,i){if(r&&tle.test(r)&&(i=r,r=null),r&&r!=="001"){if(!this.hasCountry(r))throw new Error("Unknown country: ".concat(r));this.numberingPlan=new A6(this.getCountryMetadata(r),this)}else if(i){if(!this.hasCallingCode(i))throw new Error("Unknown calling code: ".concat(i));this.numberingPlan=new A6(this.getNumberingPlanMetadata(i),this)}else this.numberingPlan=void 0;return this}},{key:"getCountryCodesForCallingCode",value:function(r){var i=this.countryCallingCodes()[r];if(i)return i.length===1&&i[0].length===3?void 0:i}},{key:"getCountryCodeForCallingCode",value:function(r){var i=this.getCountryCodesForCallingCode(r);if(i)return i[0]}},{key:"getNumberingPlanMetadata",value:function(r){var i=this.getCountryCodeForCallingCode(r);if(i)return this.getCountryMetadata(i);if(this.nonGeographic()){var n=this.nonGeographic()[r];if(n)return n}else{var a=this.countryCallingCodes()[r];if(a&&a.length===1&&a[0]==="001")return this.metadata.countries["001"]}}},{key:"countryCallingCode",value:function(){return this.numberingPlan.callingCode()}},{key:"IDDPrefix",value:function(){return this.numberingPlan.IDDPrefix()}},{key:"defaultIDDPrefix",value:function(){return this.numberingPlan.defaultIDDPrefix()}},{key:"nationalNumberPattern",value:function(){return this.numberingPlan.nationalNumberPattern()}},{key:"possibleLengths",value:function(){return this.numberingPlan.possibleLengths()}},{key:"formats",value:function(){return this.numberingPlan.formats()}},{key:"nationalPrefixForParsing",value:function(){return this.numberingPlan.nationalPrefixForParsing()}},{key:"nationalPrefixTransformRule",value:function(){return this.numberingPlan.nationalPrefixTransformRule()}},{key:"leadingDigits",value:function(){return this.numberingPlan.leadingDigits()}},{key:"hasTypes",value:function(){return this.numberingPlan.hasTypes()}},{key:"type",value:function(r){return this.numberingPlan.type(r)}},{key:"ext",value:function(){return this.numberingPlan.ext()}},{key:"countryCallingCodes",value:function(){return this.v1?this.metadata.country_phone_code_to_countries:this.metadata.country_calling_codes}},{key:"chooseCountryByCountryCallingCode",value:function(r){return this.selectNumberingPlan(r)}},{key:"hasSelectedNumberingPlan",value:function(){return this.numberingPlan!==void 0}}])})(),A6=(function(){function e(t,r){I1(this,e),this.globalMetadataObject=r,this.metadata=t,J9.call(this,r.metadata)}return A1(e,[{key:"callingCode",value:function(){return this.metadata[0]}},{key:"getDefaultCountryMetadataForRegion",value:function(){return this.globalMetadataObject.getNumberingPlanMetadata(this.callingCode())}},{key:"IDDPrefix",value:function(){if(!(this.v1||this.v2))return this.metadata[1]}},{key:"defaultIDDPrefix",value:function(){if(!(this.v1||this.v2))return this.metadata[12]}},{key:"nationalNumberPattern",value:function(){return this.v1||this.v2?this.metadata[1]:this.metadata[2]}},{key:"possibleLengths",value:function(){if(!this.v1)return this.metadata[this.v2?2:3]}},{key:"_getFormats",value:function(r){return r[this.v1?2:this.v2?3:4]}},{key:"formats",value:function(){var r=this,i=this._getFormats(this.metadata)||this._getFormats(this.getDefaultCountryMetadataForRegion())||[];return i.map(function(n){return new rle(n,r)})}},{key:"nationalPrefix",value:function(){return this.metadata[this.v1?3:this.v2?4:5]}},{key:"_getNationalPrefixFormattingRule",value:function(r){return r[this.v1?4:this.v2?5:6]}},{key:"nationalPrefixFormattingRule",value:function(){return this._getNationalPrefixFormattingRule(this.metadata)||this._getNationalPrefixFormattingRule(this.getDefaultCountryMetadataForRegion())}},{key:"_nationalPrefixForParsing",value:function(){return this.metadata[this.v1?5:this.v2?6:7]}},{key:"nationalPrefixForParsing",value:function(){return this._nationalPrefixForParsing()||this.nationalPrefix()}},{key:"nationalPrefixTransformRule",value:function(){return this.metadata[this.v1?6:this.v2?7:8]}},{key:"_getNationalPrefixIsOptionalWhenFormatting",value:function(){return!!this.metadata[this.v1?7:this.v2?8:9]}},{key:"nationalPrefixIsOptionalWhenFormattingInNationalFormat",value:function(){return this._getNationalPrefixIsOptionalWhenFormatting(this.metadata)||this._getNationalPrefixIsOptionalWhenFormatting(this.getDefaultCountryMetadataForRegion())}},{key:"leadingDigits",value:function(){return this.metadata[this.v1?8:this.v2?9:10]}},{key:"types",value:function(){return this.metadata[this.v1?9:this.v2?10:11]}},{key:"hasTypes",value:function(){return this.types()&&this.types().length===0?!1:!!this.types()}},{key:"type",value:function(r){if(this.hasTypes()&&D6(this.types(),r))return new nle(D6(this.types(),r),this)}},{key:"ext",value:function(){return this.v1||this.v2?I6:this.metadata[13]||I6}}])})(),rle=(function(){function e(t,r){I1(this,e),this._format=t,this.metadata=r}return A1(e,[{key:"pattern",value:function(){return this._format[0]}},{key:"format",value:function(){return this._format[1]}},{key:"leadingDigitsPatterns",value:function(){return this._format[2]||[]}},{key:"nationalPrefixFormattingRule",value:function(){return this._format[3]||this.metadata.nationalPrefixFormattingRule()}},{key:"nationalPrefixIsOptionalWhenFormattingInNationalFormat",value:function(){return!!this._format[4]||this.metadata.nationalPrefixIsOptionalWhenFormattingInNationalFormat()}},{key:"nationalPrefixIsMandatoryWhenFormattingInNationalFormat",value:function(){return this.usesNationalPrefix()&&!this.nationalPrefixIsOptionalWhenFormattingInNationalFormat()}},{key:"usesNationalPrefix",value:function(){return!!(this.nationalPrefixFormattingRule()&&!ile.test(this.nationalPrefixFormattingRule()))}},{key:"internationalFormat",value:function(){return this._format[5]||this.format()}}])})(),ile=/^\(?\$1\)?$/,nle=(function(){function e(t,r){I1(this,e),this.type=t,this.metadata=r}return A1(e,[{key:"pattern",value:function(){return this.metadata.v1?this.type:this.type[0]}},{key:"possibleLengths",value:function(){if(!this.metadata.v1)return this.type[1]||this.metadata.possibleLengths()}}])})();function D6(e,t){switch(t){case"FIXED_LINE":return e[0];case"MOBILE":return e[1];case"TOLL_FREE":return e[2];case"PREMIUM_RATE":return e[3];case"PERSONAL_NUMBER":return e[4];case"VOICEMAIL":return e[5];case"UAN":return e[6];case"PAGER":return e[7];case"VOIP":return e[8];case"SHARED_COST":return e[9]}}function X9(e){if(!e)throw new Error("[libphonenumber-js] `metadata` argument not passed. Check your arguments.");if(!Ud(e)||!Ud(e.countries))throw new Error("[libphonenumber-js] `metadata` argument was passed but it's not a valid metadata. Must be an object having `.countries` child object property. Got ".concat(Ud(e)?"an object of shape: { "+Object.keys(e).join(", ")+" }":"a "+ale(e)+": "+e,"."))}var ale=function(t){return vh(t)};function U4(e,t){if(t=new _n(t),t.hasCountry(e))return t.selectNumberingPlan(e).countryCallingCode();throw new Error("Unknown country: ".concat(e))}function sle(e,t){return t.countries.hasOwnProperty(e)}function J9(e){var t=e.version;typeof t=="number"?(this.v1=t===1,this.v2=t===2,this.v3=t===3,this.v4=t===4):t?M6(t,Qoe)===-1?this.v2=!0:M6(t,ele)===-1?this.v3=!0:this.v4=!0:this.v1=!0}function V4(e,t,r){return ole(e,t,void 0,r)}function ole(e,t,r,i){t&&(i=new _n(i.metadata),i.selectNumberingPlan(t));var n=i.type(r),a=n&&n.possibleLengths()||i.possibleLengths();if(!a)return"IS_POSSIBLE";var s=e.length,o=a[0];return o===s?"IS_POSSIBLE":o>s?"TOO_SHORT":a[a.length-1]<s?"TOO_LONG":a.indexOf(s,1)>=0?"IS_POSSIBLE":"INVALID_LENGTH"}function lle(e,t,r){if(t===void 0&&(t={}),r=new _n(r),t.v2){if(!e.countryCallingCode)throw new Error("Invalid phone number object passed");r.selectNumberingPlan(e.countryCallingCode)}else{if(!e.phone)return!1;if(e.country){if(!r.hasCountry(e.country))throw new Error("Unknown country: ".concat(e.country));r.selectNumberingPlan(e.country)}else{if(!e.countryCallingCode)throw new Error("Invalid phone number object passed");r.selectNumberingPlan(e.countryCallingCode)}}if(r.possibleLengths())return Q9(e.phone||e.nationalNumber,e.country,r);if(e.countryCallingCode&&r.isNonGeographicCallingCode(e.countryCallingCode))return!0;throw new Error('Missing "possibleLengths" in metadata. Perhaps the metadata has been generated before v1.0.18.')}function Q9(e,t,r){switch(V4(e,t,r)){case"IS_POSSIBLE":return!0;default:return!1}}function al(e,t){return e=e||"",new RegExp("^(?:"+t+")$").test(e)}function ule(e,t){var r=typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(r)return(r=r.call(e)).next.bind(r);if(Array.isArray(e)||(r=cle(e))||t){r&&(e=r);var i=0;return function(){return i>=e.length?{done:!0}:{done:!1,value:e[i++]}}}throw new TypeError(`Invalid attempt to iterate non-iterable instance. 42In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function cle(e,t){if(e){if(typeof e=="string")return R6(e,t);var r={}.toString.call(e).slice(8,-1);return r==="Object"&&e.constructor&&(r=e.constructor.name),r==="Map"||r==="Set"?Array.from(e):r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?R6(e,t):void 0}}function R6(e,t){(t==null||t>e.length)&&(t=e.length);for(var r=0,i=Array(t);r<t;r++)i[r]=e[r];return i}var dle=["MOBILE","PREMIUM_RATE","TOLL_FREE","SHARED_COST","VOIP","PERSONAL_NUMBER","PAGER","UAN","VOICEMAIL"];function q4(e,t,r){if(t=t||{},!(!e.country&&!e.countryCallingCode)){r=new _n(r),r.selectNumberingPlan(e.country,e.countryCallingCode);var i=t.v2?e.nationalNumber:e.phone;if(al(i,r.nationalNumberPattern())){if(Yv(i,"FIXED_LINE",r))return r.type("MOBILE")&&r.type("MOBILE").pattern()===""||!r.type("MOBILE")||Yv(i,"MOBILE",r)?"FIXED_LINE_OR_MOBILE":"FIXED_LINE";for(var n=ule(dle),a;!(a=n()).done;){var s=a.value;if(Yv(i,s,r))return s}}}}function Yv(e,t,r){var i=r.type(t);return!i||!i.pattern()||i.possibleLengths()&&i.possibleLengths().indexOf(e.length)<0?!1:al(e,i.pattern())}function hle(e,t,r){if(t=t||{},r=new _n(r),r.selectNumberingPlan(e.country,e.countryCallingCode),r.hasTypes())return q4(e,t,r.metadata)!==void 0;var i=t.v2?e.nationalNumber:e.phone;return al(i,r.nationalNumberPattern())}function fle(e,t,r){var i=new _n(r),n=i.getCountryCodesForCallingCode(e);return n?n.filter(function(a){return ple(t,a,r)}):[]}function ple(e,t,r){var i=new _n(r);return i.selectNumberingPlan(t),i.numberingPlan.possibleLengths().indexOf(e.length)>=0}var G4=2,mle=17,gle=3,Ps="0-9ï¼-ï¼Ù -Ù©Û°-Û¹",_le="-â-ââã¼ï¼",yle="ï¼/",vle="ï¼.",ble="  Ââ
42â ã",xle="()ï¼ï¼ï¼»ï¼½\\[\\]",wle="~ââ¼ï½",ay="".concat(_le).concat(yle).concat(vle).concat(ble).concat(xle).concat(wle),H4="+ï¼",$le=new RegExp("(["+Ps+"])");function Sle(e,t,r,i){if(t){var n=new _n(i);n.selectNumberingPlan(t,r);var a=new RegExp(n.IDDPrefix());if(e.search(a)===0){e=e.slice(e.match(a)[0].length);var s=e.match($le);if(!(s&&s[1]!=null&&s[1].length>0&&s[1]==="0"))return e}}}function Tle(e,t){if(e&&t.numberingPlan.nationalPrefixForParsing()){var r=new RegExp("^(?:"+t.numberingPlan.nationalPrefixForParsing()+")"),i=r.exec(e);if(i){var n,a,s=i.length-1,o=s>0&&i[s];if(t.nationalPrefixTransformRule()&&o)n=e.replace(r,t.nationalPrefixTransformRule()),s>1&&(a=i[1]);else{var l=i[0];n=e.slice(l.length),o&&(a=i[1])}var u;if(o){var c=e.indexOf(i[1]),d=e.slice(0,c);d===t.numberingPlan.nationalPrefix()&&(u=t.numberingPlan.nationalPrefix())}else u=i[0];return{nationalNumber:n,nationalPrefix:u,carrierCode:a}}}return{nationalNumber:e}}function Cle(e,t){var r=typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(r)return(r=r.call(e)).next.bind(r);if(Array.isArray(e)||(r=kle(e))||t){r&&(e=r);var i=0;return function(){return i>=e.length?{done:!0}:{done:!1,value:e[i++]}}}throw new TypeError(`Invalid attempt to iterate non-iterable instance. 43In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function kle(e,t){if(e){if(typeof e=="string")return O6(e,t);var r={}.toString.call(e).slice(8,-1);return r==="Object"&&e.constructor&&(r=e.constructor.name),r==="Map"||r==="Set"?Array.from(e):r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?O6(e,t):void 0}}function O6(e,t){(t==null||t>e.length)&&(t=e.length);for(var r=0,i=Array(t);r<t;r++)i[r]=e[r];return i}function Ele(e,t){var r=t.countries,i=t.metadata;i=new _n(i);for(var n=Cle(r),a;!(a=n()).done;){var s=a.value;if(i.selectNumberingPlan(s),i.leadingDigits()){if(e&&e.search(i.leadingDigits())===0)return s}else if(q4({phone:e,country:s},void 0,i.metadata))return s}}function eD(e,t){var r=t.nationalNumber,i=t.metadata,n=i.getCountryCodesForCallingCode(e);if(n)return n.length===1?n[0]:Ele(r,{countries:n,metadata:i.metadata})}function J2(e,t,r){var i=Tle(e,r),n=i.carrierCode,a=i.nationalNumber;if(a!==e){if(!Ple(e,a,r))return{nationalNumber:e};if(r.numberingPlan.possibleLengths()&&(t||(t=eD(r.numberingPlan.callingCode(),{nationalNumber:a,metadata:r})),!Mle(a,t,r)))return{nationalNumber:e}}return{nationalNumber:a,carrierCode:n}}function Ple(e,t,r){return!(al(e,r.nationalNumberPattern())&&!al(t,r.nationalNumberPattern()))}function Mle(e,t,r){switch(V4(e,t,r)){case"TOO_SHORT":case"INVALID_LENGTH":return!1;default:return!0}}function Ile(e,t,r,i,n){var a=r?U4(r,n):i;if(e.indexOf(a)===0){n=new _n(n),n.selectNumberingPlan(r,a);var s=e.slice(a.length),o=J2(s,t,n),l=o.nationalNumber,u=J2(e,t,n),c=u.nationalNumber;if(!al(c,n.nationalNumberPattern())&&al(l,n.nationalNumberPattern())||V4(c,t,n)==="TOO_LONG")return{countryCallingCode:a,number:s}}return{number:e}}function tD(e,t,r,i,n){if(!e)return{};var a;if(e[0]!=="+"){var s=Sle(e,r,i,n);if(s&&s!==e)a=!0,e="+"+s;else{if(r||i){var o=Ile(e,t,r,i,n),l=o.countryCallingCode,u=o.number;if(l)return{countryCallingCodeSource:"FROM_NUMBER_WITHOUT_PLUS_SIGN",countryCallingCode:l,number:u}}return{number:e}}}if(e[1]==="0")return{};n=new _n(n);for(var c=2;c-1<=gle&&c<=e.length;){var d=e.slice(1,c);if(n.hasCallingCode(d))return n.selectNumberingPlan(d),{countryCallingCodeSource:a?"FROM_NUMBER_WITH_IDD":"FROM_NUMBER_WITH_PLUS_SIGN",countryCallingCode:d,number:e.slice(c)};c++}return{}}function Ale(e){return e.replace(new RegExp("[".concat(ay,"]+"),"g")," ").trim()}var Dle=/(\$\d)/;function Rle(e,t,r){var i=r.useInternationalFormat,n=r.withNationalPrefix,a=e.replace(new RegExp(t.pattern()),i?t.internationalFormat():n&&t.nationalPrefixFormattingRule()?t.format().replace(Dle,t.nationalPrefixFormattingRule()):t.format());return i?Ale(a):a}var Ole=/^[\d]+(?:[~\u2053\u223C\uFF5E][\d]+)?$/;function Lle(e,t,r){var i=new _n(r);if(i.selectNumberingPlan(e,t),i.defaultIDDPrefix())return i.defaultIDDPrefix();if(Ole.test(i.IDDPrefix()))return i.IDDPrefix()}var Fle=";ext=",Wc=function(t){return"([".concat(Ps,"]{1,").concat(t,"})")};function rD(e){var t="20",r="15",i="9",n="6",a="[  \\t,]*",s="[:\\.ï¼]?[  \\t,-]*",o="#?",l="(?:e?xt(?:ensi(?:oÌ?|ó))?n?|ï½ ?ï½ï½ï½?|доб|anexo)",u="(?:[xï½#ï¼~ï½]|int|ï½ï½ï½)",c="[- ]+",d="[  \\t]*",h="(?:,{2}|;)",f=Fle+Wc(t),p=a+l+s+Wc(t)+o,m=a+u+s+Wc(i)+o,g=c+Wc(n)+"#",v=d+h+s+Wc(r)+o,x=d+"(?:,)+"+s+Wc(i)+o;return f+"|"+p+"|"+m+"|"+g+"|"+v+"|"+x}var zle="["+Ps+"]{"+G4+"}",Nle="["+H4+"]{0,1}(?:["+ay+"]*["+Ps+"]){3,}["+ay+Ps+"]*",Ble=new RegExp("^["+H4+"]{0,1}(?:["+ay+"]*["+Ps+"]){1,2}$","i"),jle=Nle+"(?:"+rD()+")?",Ule=new RegExp("^"+zle+"$|^"+jle+"$","i");function Vle(e){return e.length>=G4&&Ule.test(e)}function qle(e){return Ble.test(e)}function Gle(e){var t=e.number,r=e.ext;if(!t)return"";if(t[0]!=="+")throw new Error('"formatRFC3966()" expects "number" to be in E.164 format.');return"tel:".concat(t).concat(r?";ext="+r:"")}var L6={formatExtension:function(t,r,i){return"".concat(t).concat(i.ext()).concat(r)}};
vendor: 17,144 bytes, lines 43-45
43function Hle(e,t,r,i){if(r?r=Zle({},L6,r):r=L6,i=new _n(i),e.country&&e.country!=="001"){if(!i.hasCountry(e.country))throw new Error("Unknown country: ".concat(e.country));i.selectNumberingPlan(e.country)}else if(e.countryCallingCode)i.selectNumberingPlan(e.countryCallingCode);else return e.phone||"";var n=i.countryCallingCode(),a=r.v2?e.nationalNumber:e.phone,s;switch(t){case"NATIONAL":return a?(s=sy(a,e.carrierCode,"NATIONAL",i,r),Wv(s,e.ext,i,r.formatExtension)):"";case"INTERNATIONAL":return a?(s=sy(a,null,"INTERNATIONAL",i,r),s="+".concat(n," ").concat(s),Wv(s,e.ext,i,r.formatExtension)):"+".concat(n);case"E.164":return"+".concat(n).concat(a);case"RFC3966":return Gle({number:"+".concat(n).concat(a),ext:e.ext});case"IDD":if(!r.fromCountry)return;var o=Wle(a,e.carrierCode,n,r.fromCountry,i);return o?Wv(o,e.ext,i,r.formatExtension):void 0;default:throw new Error('Unknown "format" argument passed to "formatNumber()": "'.concat(t,'"'))}}function sy(e,t,r,i,n){var a=Yle(i.formats(),e);return a?Rle(e,a,{useInternationalFormat:r==="INTERNATIONAL",withNationalPrefix:!(a.nationalPrefixIsOptionalWhenFormattingInNationalFormat()&&n&&n.nationalPrefix===!1)}):e}function Yle(e,t){return Kle(e,function(r){if(r.leadingDigitsPatterns().length>0){var i=r.leadingDigitsPatterns()[r.leadingDigitsPatterns().length-1];if(t.search(i)!==0)return!1}return al(t,r.pattern())})}function Wv(e,t,r,i){return t?i(e,t,r):e}function Wle(e,t,r,i,n){var a=U4(i,n.metadata);if(a===r){var s=sy(e,t,"NATIONAL",n);return r==="1"?r+" "+s:s}var o=Lle(i,void 0,n.metadata);if(o)return"".concat(o," ").concat(r," ").concat(sy(e,null,"INTERNATIONAL",n))}function Zle(){for(var e=1,t=arguments.length,r=new Array(t),i=0;i<t;i++)r[i]=arguments[i];for(;e<r.length;){if(r[e])for(var n in r[e])r[0][n]=r[e][n];e++}return r[0]}function Kle(e,t){for(var r=0;r<e.length;){if(t(e[r]))return e[r];r++}}function am(e){"@babel/helpers - typeof";return am=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},am(e)}function F6(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);t&&(i=i.filter(function(n){return Object.getOwnPropertyDescriptor(e,n).enumerable})),r.push.apply(r,i)}return r}function z6(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?F6(Object(r),!0).forEach(function(i){Xle(e,i,r[i])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):F6(Object(r)).forEach(function(i){Object.defineProperty(e,i,Object.getOwnPropertyDescriptor(r,i))})}return e}function Xle(e,t,r){return(t=iD(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function Jle(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function Qle(e,t){for(var r=0;r<t.length;r++){var i=t[r];i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(e,iD(i.key),i)}}function eue(e,t,r){return t&&Qle(e.prototype,t),Object.defineProperty(e,"prototype",{writable:!1}),e}function iD(e){var t=tue(e,"string");return am(t)=="symbol"?t:t+""}function tue(e,t){if(am(e)!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var i=r.call(e,t);if(am(i)!="object")return i;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(e)}var rue=(function(){function e(t,r,i){if(Jle(this,e),!t)throw new TypeError("First argument is required");if(typeof t!="string")throw new TypeError("First argument must be a string");if(t[0]==="+"&&!r)throw new TypeError("`metadata` argument not passed");if(Ud(r)&&Ud(r.countries)){i=r;var n=t;if(!aue.test(n))throw new Error('Invalid `number` argument passed: must consist of a "+" followed by digits');var a=tD(n,void 0,void 0,void 0,i),s=a.countryCallingCode,o=a.number;if(r=o,t=s,!r)throw new Error("Invalid `number` argument passed: too short")}if(!r)throw new TypeError("`nationalNumber` argument is required");if(typeof r!="string")throw new TypeError("`nationalNumber` argument must be a string");X9(i);var l=nue(t,i),u=l.country,c=l.countryCallingCode;this.country=u,this.countryCallingCode=c,this.nationalNumber=r,this.number="+"+this.countryCallingCode+this.nationalNumber,this.getMetadata=function(){return i}}return eue(e,[{key:"setExt",value:function(r){this.ext=r}},{key:"getPossibleCountries",value:function(){return this.country?[this.country]:fle(this.countryCallingCode,this.nationalNumber,this.getMetadata())}},{key:"isPossible",value:function(){return lle(this,{v2:!0},this.getMetadata())}},{key:"isValid",value:function(){return hle(this,{v2:!0},this.getMetadata())}},{key:"isNonGeographic",value:function(){var r=new _n(this.getMetadata());return r.isNonGeographicCallingCode(this.countryCallingCode)}},{key:"isEqual",value:function(r){return this.number===r.number&&this.ext===r.ext}},{key:"getType",value:function(){return q4(this,{v2:!0},this.getMetadata())}},{key:"format",value:function(r,i){return Hle(this,r,i?z6(z6({},i),{},{v2:!0}):{v2:!0},this.getMetadata())}},{key:"formatNational",value:function(r){return this.format("NATIONAL",r)}},{key:"formatInternational",value:function(r){return this.format("INTERNATIONAL",r)}},{key:"getURI",value:function(r){return this.format("RFC3966",r)}}])})(),iue=function(t){return/^[A-Z]{2}$/.test(t)};function nue(e,t){var r,i,n=new _n(t);return iue(e)?(r=e,n.selectNumberingPlan(r),i=n.countryCallingCode()):i=e,{country:r,countryCallingCode:i}}var aue=/^\+\d+$/;function Q2(e){"@babel/helpers - typeof";return Q2=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},Q2(e)}function sue(e,t,r){return Object.defineProperty(e,"prototype",{writable:!1}),e}function oue(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function lue(e,t,r){return t=om(t),uue(e,Y4()?Reflect.construct(t,r||[],om(e).constructor):t.apply(e,r))}function uue(e,t){if(t&&(Q2(t)=="object"||typeof t=="function"))return t;if(t!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return cue(e)}function cue(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function due(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&&sm(e,t)}function ex(e){var t=typeof Map=="function"?new Map:void 0;return ex=function(i){if(i===null||!fue(i))return i;if(typeof i!="function")throw new TypeError("Super expression must either be null or a function");if(t!==void 0){if(t.has(i))return t.get(i);t.set(i,n)}function n(){return hue(i,arguments,om(this).constructor)}return n.prototype=Object.create(i.prototype,{constructor:{value:n,enumerable:!1,writable:!0,configurable:!0}}),sm(n,i)},ex(e)}function hue(e,t,r){if(Y4())return Reflect.construct.apply(null,arguments);var i=[null];i.push.apply(i,t);var n=new(e.bind.apply(e,i));return r&&sm(n,r.prototype),n}function Y4(){try{var e=!Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){}))}catch{}return(Y4=function(){return!!e})()}function fue(e){try{return Function.toString.call(e).indexOf("[native code]")!==-1}catch{return typeof e=="function"}}function sm(e,t){return sm=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(r,i){return r.__proto__=i,r},sm(e,t)}function om(e){return om=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(t){return t.__proto__||Object.getPrototypeOf(t)},om(e)}var ko=(function(e){function t(r){var i;return oue(this,t),i=lue(this,t,[r]),Object.setPrototypeOf(i,t.prototype),i.name=i.constructor.name,i}return due(t,e),sue(t)})(ex(Error)),N6=new RegExp("(?:"+rD()+")$","i");function pue(e){var t=e.search(N6);if(t<0)return{};for(var r=e.slice(0,t),i=e.match(N6),n=1;n<i.length;){if(i[n])return{number:r,ext:i[n]};n++}}var mue={0:"0",1:"1",2:"2",3:"3",4:"4",5:"5",6:"6",7:"7",8:"8",9:"9","ï¼":"0","ï¼":"1","ï¼":"2","ï¼":"3","ï¼":"4","ï¼":"5","ï¼":"6","ï¼":"7","ï¼":"8","ï¼":"9","Ù ":"0","Ù¡":"1","Ù¢":"2","Ù£":"3","Ù¤":"4","Ù¥":"5","Ù¦":"6","Ù§":"7","Ù¨":"8","Ù©":"9","Û°":"0","Û±":"1","Û²":"2","Û³":"3","Û´":"4","Ûµ":"5","Û¶":"6","Û·":"7","Û¸":"8","Û¹":"9"};function gue(e){return mue[e]}function _ue(e,t){var r=typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(r)return(r=r.call(e)).next.bind(r);if(Array.isArray(e)||(r=yue(e))||t){r&&(e=r);var i=0;return function(){return i>=e.length?{done:!0}:{done:!1,value:e[i++]}}}throw new TypeError(`Invalid attempt to iterate non-iterable instance. 44In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function yue(e,t){if(e){if(typeof e=="string")return B6(e,t);var r={}.toString.call(e).slice(8,-1);return r==="Object"&&e.constructor&&(r=e.constructor.name),r==="Map"||r==="Set"?Array.from(e):r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?B6(e,t):void 0}}function B6(e,t){(t==null||t>e.length)&&(t=e.length);for(var r=0,i=Array(t);r<t;r++)i[r]=e[r];return i}function j6(e){for(var t="",r=_ue(e.split("")),i;!(i=r()).done;){var n=i.value;t+=vue(n,t)||""}return t}function vue(e,t,r){return e==="+"?t?void 0:"+":gue(e)}var nD="+",bue="[\\-\\.\\(\\)]?",U6="(["+Ps+"]|"+bue+")",xue="^\\"+nD+U6+"*["+Ps+"]"+U6+"*$",wue=new RegExp(xue,"g"),tx=Ps,$ue="["+tx+"]+((\\-)*["+tx+"])*",Sue="a-zA-Z",Tue="["+Sue+"]+((\\-)*["+tx+"])*",Cue="^("+$ue+"\\.)*"+Tue+"\\.?$",kue=new RegExp(Cue,"g"),V6="tel:",rx=";phone-context=",Eue=";isub=";function Pue(e){var t=e.indexOf(rx);if(t<0)return null;var r=t+rx.length;if(r>=e.length)return"";var i=e.indexOf(";",r);return i>=0?e.substring(r,i):e.substring(r)}function Mue(e){return e===null?!0:e.length===0?!1:wue.test(e)||kue.test(e)}function Iue(e,t){var r=t.extractFormattedPhoneNumber,i=Pue(e);if(!Mue(i))throw new ko("NOT_A_NUMBER");var n;if(i===null)n=r(e)||"";else{n="",i.charAt(0)===nD&&(n+=i);var a=e.indexOf(V6),s;a>=0?s=a+V6.length:s=0;var o=e.indexOf(rx);n+=e.substring(s,o)}var l=n.indexOf(Eue);if(l>0&&(n=n.substring(0,l)),n!=="")return n}var Aue=250,Due=new RegExp("["+H4+Ps+"]"),Rue=new RegExp("[^"+Ps+"#]+$");function Oue(e,t,r){if(t=t||{},r=new _n(r),t.defaultCountry&&!r.hasCountry(t.defaultCountry))throw t.v2?new ko("INVALID_COUNTRY"):new Error("Unknown country: ".concat(t.defaultCountry));var i=Fue(e,t.v2,t.extract),n=i.number,a=i.ext,s=i.error;if(!n){if(t.v2)throw s==="TOO_SHORT"?new ko("TOO_SHORT"):new ko("NOT_A_NUMBER");return{}}var o=Nue(n,t.defaultCountry,t.defaultCallingCode,r),l=o.country,u=o.nationalNumber,c=o.countryCallingCode,d=o.countryCallingCodeSource,h=o.carrierCode;if(!r.hasSelectedNumberingPlan()){if(t.v2)throw new ko("INVALID_COUNTRY");return{}}if(!u||u.length<G4){if(t.v2)throw new ko("TOO_SHORT");return{}}if(u.length>mle){if(t.v2)throw new ko("TOO_LONG");return{}}if(t.v2){var f=new rue(c,u,r.metadata);return l&&(f.country=l),h&&(f.carrierCode=h),a&&(f.ext=a),f.__countryCallingCodeSource=d,f}var p=(t.extended?r.hasSelectedNumberingPlan():l)?al(u,r.nationalNumberPattern()):!1;return t.extended?{country:l,countryCallingCode:c,carrierCode:h,valid:p,possible:p?!0:!!(t.extended===!0&&r.possibleLengths()&&Q9(u,l,r)),phone:u,ext:a}:p?zue(l,u,a):{}}function Lue(e,t,r){if(e){if(e.length>Aue){if(r)throw new ko("TOO_LONG");return}if(t===!1)return e;var i=e.search(Due);if(!(i<0))return e.slice(i).replace(Rue,"")}}function Fue(e,t,r){var i=Iue(e,{extractFormattedPhoneNumber:function(s){return Lue(s,r,t)}});if(!i)return{};if(!Vle(i))return qle(i)?{error:"TOO_SHORT"}:{};var n=pue(i);return n.ext?n:{number:i}}function zue(e,t,r){var i={country:e,phone:t};return r&&(i.ext=r),i}function Nue(e,t,r,i){var n=tD(j6(e),void 0,t,r,i.metadata),a=n.countryCallingCodeSource,s=n.countryCallingCode,o=n.number,l;if(s)i.selectNumberingPlan(s);else if(o&&(t||r))i.selectNumberingPlan(t,r),t&&(l=t),s=r||U4(t,i.metadata);else return{};if(!o)return{countryCallingCodeSource:a,countryCallingCode:s};var u=J2(j6(o),l,i),c=u.nationalNumber,d=u.carrierCode,h=eD(s,{nationalNumber:c,metadata:i});return h&&(l=h,h==="001"||i.selectNumberingPlan(l)),{country:l,countryCallingCode:s,countryCallingCodeSource:a,nationalNumber:c,carrierCode:d}}function lm(e){"@babel/helpers - typeof";return lm=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},lm(e)}function q6(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);t&&(i=i.filter(function(n){return Object.getOwnPropertyDescriptor(e,n).enumerable})),r.push.apply(r,i)}return r}function G6(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?q6(Object(r),!0).forEach(function(i){Bue(e,i,r[i])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):q6(Object(r)).forEach(function(i){Object.defineProperty(e,i,Object.getOwnPropertyDescriptor(r,i))})}return e}function Bue(e,t,r){return(t=jue(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function jue(e){var t=Uue(e,"string");return lm(t)=="symbol"?t:t+""}function Uue(e,t){if(lm(e)!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var i=r.call(e,t);if(lm(i)!="object")return i;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function Vue(e,t,r){return Oue(e,G6(G6({},t),{},{v2:!0}),r)}function um(e){"@babel/helpers - typeof";return um=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},um(e)}function H6(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);t&&(i=i.filter(function(n){return Object.getOwnPropertyDescriptor(e,n).enumerable})),r.push.apply(r,i)}return r}function que(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};t%2?H6(Object(r),!0).forEach(function(i){Gue(e,i,r[i])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):H6(Object(r)).forEach(function(i){Object.defineProperty(e,i,Object.getOwnPropertyDescriptor(r,i))})}return e}function Gue(e,t,r){return(t=Hue(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function Hue(e){var t=Yue(e,"string");return um(t)=="symbol"?t:t+""}function Yue(e,t){if(um(e)!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var i=r.call(e,t);if(um(i)!="object")return i;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function Wue(e,t){return Jue(e)||Xue(e,t)||Kue(e,t)||Zue()}function Zue(){throw new TypeError(`Invalid attempt to destructure non-iterable instance. 45In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function Kue(e,t){if(e){if(typeof e=="string")return Y6(e,t);var r={}.toString.call(e).slice(8,-1);return r==="Object"&&e.constructor&&(r=e.constructor.name),r==="Map"||r==="Set"?Array.from(e):r==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(r)?Y6(e,t):void 0}}function Y6(e,t){(t==null||t>e.length)&&(t=e.length);for(var r=0,i=Array(t);r<t;r++)i[r]=e[r];return i}function Xue(e,t){var r=e==null?null:typeof Symbol<"u"&&e[Symbol.iterator]||e["@@iterator"];if(r!=null){var i,n,a,s,o=[],l=!0,u=!1;try{if(a=(r=r.call(e)).next,t!==0)for(;!(l=(i=a.call(r)).done)&&(o.push(i.value),o.length!==t);l=!0);}catch(c){u=!0,n=c}finally{try{if(!l&&r.return!=null&&(s=r.return(),Object(s)!==s))return}finally{if(u)throw n}}return o}}function Jue(e){if(Array.isArray(e))return e}function Que(e){var t=Array.prototype.slice.call(e),r=Wue(t,4),i=r[0],n=r[1],a=r[2],s=r[3],o,l,u;if(typeof i=="string")o=i;else throw new TypeError("A text for parsing must be a string.");if(!n||typeof n=="string")s?(l=a,u=s):(l=void 0,u=a),n&&(l=que({defaultCountry:n},l));else if(Ud(n))a?(l=n,u=a):u=n;else throw new Error("Invalid second argument: ".concat(n));return{text:o,options:l,metadata:u}}function cm(e){"@babel/helpers - typeof";return cm=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},cm(e)}function W6(e,t){var r=Object.keys(e);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);t&&(i=i.filter(function(n){return Object.getOwnPropertyDescriptor(e,n).enumerable})),r.push.apply(r,i)}return r}function Z6(e){for(var t=1;t<arguments.length;t++){var r=arguments[t]!=null?arguments[t]:{};
45t%2?W6(Object(r),!0).forEach(function(i){ece(e,i,r[i])}):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(r)):W6(Object(r)).forEach(function(i){Object.defineProperty(e,i,Object.getOwnPropertyDescriptor(r,i))})}return e}function ece(e,t,r){return(t=tce(t))in e?Object.defineProperty(e,t,{value:r,enumerable:!0,configurable:!0,writable:!0}):e[t]=r,e}function tce(e){var t=rce(e,"string");return cm(t)=="symbol"?t:t+""}function rce(e,t){if(cm(e)!="object"||!e)return e;var r=e[Symbol.toPrimitive];if(r!==void 0){var i=r.call(e,t);if(cm(i)!="object")return i;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(e)}function ice(e,t,r){t&&t.defaultCountry&&!sle(t.defaultCountry,r)&&(t=Z6(Z6({},t),{},{defaultCountry:void 0}));try{return Vue(e,t,r)}catch(i){if(!(i instanceof ko))throw i}}function nce(){var e=Que(arguments),t=e.text,r=e.options,i=e.metadata;return ice(t,r,i)}function Uf(){return Woe(nce,arguments)}const ace=[["Afghanistan (â«Ø§ÙØºØ§ÙØ³ØªØ§Ùâ¬â)","af","93"],["Albania (Shqipëri)","al","355"],["Algeria (â«Ø§Ùجزائرâ¬â)","dz","213"],["American Samoa","as","1",5,["684"]],["Andorra","ad","376"],["Angola","ao","244"],["Anguilla","ai","1",6,["264"]],["Antigua and Barbuda","ag","1",7,["268"]],["Argentina","ar","54"],["Armenia (ÕÕ¡ÕµÕ¡Õ½Õ¿Õ¡Õ¶)","am","374"],["Aruba","aw","297"],["Ascension Island","ac","247"],["Australia","au","61",0],["Austria (Ãsterreich)","at","43"],["Azerbaijan (AzÉrbaycan)","az","994"],["Bahamas","bs","1",8,["242"]],["Bahrain (â«Ø§ÙØ¨ØØ±ÙÙâ¬â)","bh","973"],["Bangladesh (বাà¦à¦²à¦¾à¦¦à§à¦¶)","bd","880"],["Barbados","bb","1",9,["246"]],["Belarus (ÐелаÑÑÑÑ)","by","375"],["Belgium (België)","be","32"],["Belize","bz","501"],["Benin (Bénin)","bj","229"],["Bermuda","bm","1",10,["441"]],["Bhutan (འà½à¾²à½´à½)","bt","975"],["Bolivia","bo","591"],["Bosnia and Herzegovina (ÐоÑна и ХеÑÑеговина)","ba","387"],["Botswana","bw","267"],["Brazil (Brasil)","br","55"],["British Indian Ocean Territory","io","246"],["British Virgin Islands","vg","1",11,["284"]],["Brunei","bn","673"],["Bulgaria (ÐÑлгаÑиÑ)","bg","359"],["Burkina Faso","bf","226"],["Burundi (Uburundi)","bi","257"],["Cambodia (ááááá»áá¶)","kh","855"],["Cameroon (Cameroun)","cm","237"],["Canada","ca","1",1,["204","226","236","249","250","263","289","306","343","354","365","367","368","382","387","403","416","418","428","431","437","438","450","584","468","474","506","514","519","548","579","581","584","587","604","613","639","647","672","683","705","709","742","753","778","780","782","807","819","825","867","873","902","905"]],["Cape Verde (Kabu Verdi)","cv","238"],["Caribbean Netherlands","bq","599",1,["3","4","7"]],["Cayman Islands","ky","1",12,["345"]],["Central African Republic (République centrafricaine)","cf","236"],["Chad (Tchad)","td","235"],["Chile","cl","56"],["China (ä¸å½)","cn","86"],["Christmas Island","cx","61",2,["89164"]],["Cocos (Keeling) Islands","cc","61",1,["89162"]],["Colombia","co","57"],["Comoros (â«Ø¬Ø²Ø± اÙÙÙ
رâ¬â)","km","269"],["Congo (DRC) (République démocratique du Congo)","cd","243"],["Congo (Republic) (Congo-Brazzaville)","cg","242"],["Cook Islands","ck","682"],["Costa Rica","cr","506"],["Côte dâIvoire","ci","225"],["Croatia (Hrvatska)","hr","385"],["Cuba","cu","53"],["Curaçao","cw","599",0],["Cyprus (ÎÏÏÏοÏ)","cy","357"],["Czech Republic (Äeská republika)","cz","420"],["Denmark (Danmark)","dk","45"],["Djibouti","dj","253"],["Dominica","dm","1",13,["767"]],["Dominican Republic (República Dominicana)","do","1",2,["809","829","849"]],["Ecuador","ec","593"],["Egypt (â«Ù
صرâ¬â)","eg","20"],["El Salvador","sv","503"],["Equatorial Guinea (Guinea Ecuatorial)","gq","240"],["Eritrea","er","291"],["Estonia (Eesti)","ee","372"],["Eswatini","sz","268"],["Ethiopia","et","251"],["Falkland Islands (Islas Malvinas)","fk","500"],["Faroe Islands (Føroyar)","fo","298"],["Fiji","fj","679"],["Finland (Suomi)","fi","358",0],["France","fr","33"],["French Guiana (Guyane française)","gf","594"],["French Polynesia (Polynésie française)","pf","689"],["Gabon","ga","241"],["Gambia","gm","220"],["Georgia (á¡áá¥áá ááááá)","ge","995"],["Germany (Deutschland)","de","49"],["Ghana (Gaana)","gh","233"],["G
45ibraltar","gi","350"],["Greece (Îλλάδα)","gr","30"],["Greenland (Kalaallit Nunaat)","gl","299"],["Grenada","gd","1",14,["473"]],["Guadeloupe","gp","590",0],["Guam","gu","1",15,["671"]],["Guatemala","gt","502"],["Guernsey","gg","44",1,["1481","7781","7839","7911"]],["Guinea (Guinée)","gn","224"],["Guinea-Bissau (Guiné Bissau)","gw","245"],["Guyana","gy","592"],["Haiti","ht","509"],["Honduras","hn","504"],["Hong Kong (馿¸¯)","hk","852"],["Hungary (Magyarország)","hu","36"],["Iceland (Ãsland)","is","354"],["India (à¤à¤¾à¤°à¤¤)","in","91"],["Indonesia","id","62"],["Iran (â«Ø§ÛراÙâ¬â)","ir","98"],["Iraq (â«Ø§ÙعراÙâ¬â)","iq","964"],["Ireland","ie","353"],["Isle of Man","im","44",2,["1624","74576","7524","7924","7624"]],["Israel (â«×שר××â¬â)","il","972"],["Italy (Italia)","it","39",0],["Jamaica","jm","1",4,["876","658"]],["Japan (æ¥æ¬)","jp","81"],["Jersey","je","44",3,["1534","7509","7700","7797","7829","7937"]],["Jordan (â«Ø§ÙأردÙâ¬â)","jo","962"],["Kazakhstan (ÐазаÑ
ÑÑан)","kz","7",1,["33","7"]],["Kenya","ke","254"],["Kiribati","ki","686"],["Kosovo","xk","383"],["Kuwait (â«Ø§ÙÙÙÙØªâ¬â)","kw","965"],["Kyrgyzstan (ÐÑÑгÑзÑÑан)","kg","996"],["Laos (ລາວ)","la","856"],["Latvia (Latvija)","lv","371"],["Lebanon (â«ÙØ¨ÙØ§Ùâ¬â)","lb","961"],["Lesotho","ls","266"],["Liberia","lr","231"],["Libya (â«ÙÙØ¨Ùاâ¬â)","ly","218"],["Liechtenstein","li","423"],["Lithuania (Lietuva)","lt","370"],["Luxembourg","lu","352"],["Macau (æ¾³é)","mo","853"],["Madagascar (Madagasikara)","mg","261"],["Malawi","mw","265"],["Malaysia","my","60"],["Maldives","mv","960"],["Mali","ml","223"],["Malta","mt","356"],["Marshall Islands","mh","692"],["Martinique","mq","596"],["Mauritania (â«Ù
ÙØ±ÙتاÙÙØ§â¬â)","mr","222"],["Mauritius (Moris)","mu","230"],["Mayotte","yt","262",1,["269","639"]],["Mexico (México)","mx","52"],["Micronesia","fm","691"],["Moldova (Republica Moldova)","md","373"],["Monaco","mc","377"],["Mongolia (Ðонгол)","mn","976"],["Montenegro (Crna Gora)","me","382"],["Montserrat","ms","1",16,["664"]],["Morocco (â«Ø§ÙÙ
غربâ¬â)","ma","212",0],["Mozambique (Moçambique)","mz","258"],["Myanmar (Burma) (áá¼ááºáá¬)","mm","95"],["Namibia (Namibië)","na","264"],["Nauru","nr","674"],["Nepal (नà¥à¤ªà¤¾à¤²)","np","977"],["Netherlands (Nederland)","nl","31"],["New Caledonia (Nouvelle-Calédonie)","nc","687"],["New Zealand","nz","64"],["Nicaragua","ni","505"],["Niger (Nijar)","ne","227"],["Nigeria","ng","234"],["Niue","nu","683"],["Norfolk Island","nf","672"],["North Korea (ì¡°ì 민주주ì ì¸ë¯¼ ê³µíêµ)","kp","850"],["North Macedonia (СевеÑна ÐакедониÑа)","mk","389"],["Northern Mariana Islands","mp","1",17,["670"]],["Norway (Norge)","no","47",0],["Oman (â«Ø¹ÙÙ
اÙâ¬â)","om","968"],["Pakistan (â«Ù¾Ø§Ú©Ø³ØªØ§Ùâ¬â)","pk","92"],["Palau","pw","680"],["Palestine (â«ÙÙØ³Ø·ÙÙâ¬â)","ps","970"],["Panama (Panamá)","pa","507"],["Papua New Guinea","pg","675"],["Paraguay","py","595"],["Peru (Perú)","pe","51"],["Philippines","ph","63"],["Poland (Polska)","pl","48"],["Portugal","pt","351"],["Puerto Rico","pr","1",3,["787","939"]],["Qatar (â«Ùطرâ¬â)","qa","974"],["Réunion (La Réunion)","re","262",0],["Romania (România)","ro","40"],["Russia (РоÑÑиÑ)","ru","7",0],["Rwanda","rw","250"],["Saint Barthélemy","bl","590",1],["Saint Helena","sh","290"],["Saint Kitts and Nevis","kn","1",18,["869"]],["Saint Lucia","lc","1",19,["758"]],["Saint Martin (Saint-Martin (partie française))","mf","590",2],["Saint Pierre and Miquelon (Saint-Pierre-et-Miquelon)","pm","508"],["Saint Vincent and the Grenadines","vc","1",20,["784"]],["Samoa","ws","685"],["San Marino","sm","378"],["São Tomé and PrÃncipe (São Tomé e PrÃncipe)","st","239"],["Saudi Arabia (â«Ø§ÙÙ
Ù
ÙÙØ© Ø§ÙØ¹Ø±Ø¨ÙØ© Ø§ÙØ³Ø¹ÙØ¯ÙØ©â¬â)","sa","966"],["Senegal (Sénégal)","sn","221"],["Serbia (СÑбиÑа)","rs","381"],["Seychelles","sc","248"],["Sierra Leone","sl","232"],["Singapore","sg","65"],["Sint Maarten","sx","1",21,["721"]],["Slovakia (Slovensko)","sk","421"],["Slovenia (Slovenija)","si","386"],["Solomon Islands","sb","677"],["S
45omalia (Soomaaliya)","so","252"],["South Africa","za","27"],["South Korea (ëí민êµ)","kr","82"],["South Sudan (â«Ø¬ÙÙØ¨ Ø§ÙØ³ÙداÙâ¬â)","ss","211"],["Spain (España)","es","34"],["Sri Lanka (à·à·âර෠ලà¶à¶à·à·)","lk","94"],["Sudan (â«Ø§ÙØ³ÙØ¯Ø§Ùâ¬â)","sd","249"],["Suriname","sr","597"],["Svalbard and Jan Mayen","sj","47",1,["79"]],["Sweden (Sverige)","se","46"],["Switzerland (Schweiz)","ch","41"],["Syria (â«Ø³ÙØ±ÙØ§â¬â)","sy","963"],["Taiwan (å°ç£)","tw","886"],["Tajikistan","tj","992"],["Tanzania","tz","255"],["Thailand (à¹à¸à¸¢)","th","66"],["Timor-Leste","tl","670"],["Togo","tg","228"],["Tokelau","tk","690"],["Tonga","to","676"],["Trinidad and Tobago","tt","1",22,["868"]],["Tunisia (â«ØªÙÙØ³â¬â)","tn","216"],["Turkey (Türkiye)","tr","90"],["Turkmenistan","tm","993"],["Turks and Caicos Islands","tc","1",23,["649"]],["Tuvalu","tv","688"],["U.S. Virgin Islands","vi","1",24,["340"]],["Uganda","ug","256"],["Ukraine (УкÑаÑна)","ua","380"],["United Arab Emirates (â«Ø§ÙØ¥Ù
ارات Ø§ÙØ¹Ø±Ø¨ÙØ© اÙÙ
ØªØØ¯Ø©â¬â)","ae","971"],["United Kingdom","gb","44",0],["United States","us","1",0],["Uruguay","uy","598"],["Uzbekistan (OÊ»zbekiston)","uz","998"],["Vanuatu","vu","678"],["Vatican City (Città del Vaticano)","va","39",1,["06698"]],["Venezuela","ve","58"],["Vietnam (Viá»t Nam)","vn","84"],["Wallis and Futuna (Wallis-et-Futuna)","wf","681"],["Western Sahara (â«Ø§ÙØµØØ±Ø§Ø¡ Ø§ÙØºØ±Ø¨ÙØ©â¬â)","eh","212",1,["5288","5289"]],["Yemen (â«Ø§ÙÙÙ
Ùâ¬â)","ye","967"],["Zambia","zm","260"],["Zimbabwe","zw","263"],["Ã
land Islands","ax","358",1,["18"]]],sce=ace.map(([e,t,r,i=0,n=null])=>({name:e,iso2:t.toUpperCase(),dialCode:r,priority:i,areaCodes:n}));function oce(){return fetch("https://ip2c.org/s").then(e=>e.text()).then(e=>{const t=(e||"").toString();if(!t||t[0]!=="1")throw new Error("unable to fetch the country");return t.substr(2,2)})}function lce(e,t){if(e.setSelectionRange)e.focus(),e.setSelectionRange(t,t);else if("createTextRange"in e&&typeof e.createTextRange=="function"){const r=e.createTextRange();r.collapse(!0),r.moveEnd("character",t),r.moveStart("character",t),r.select()}}const uce=[{name:"allCountries",type:Array,default:sce,description:"All countries that are used in <code>libphonenumber-js</code>, can be overridden by this prop",inDemo:!1},{name:"autoFormat",type:Boolean,default:!0,description:"Auto update the input to the formatted phone number when it's valid",inDemo:!0},{name:"customValidate",type:[Boolean,RegExp],default:!1,description:"Custom validation RegExp for input",inDemo:!1},{name:"defaultCountry",default:"",type:[String,Number],description:"Default country (by iso2 or dialCode), will override the country fetched from IP address of user",inDemo:!1},{name:"disabled",default:!1,type:Boolean,description:"Disable <code>vue-tel-input</code>, including the input & flag dropdown",inDemo:!1},{name:"autoDefaultCountry",default:!0,type:Boolean,description:"To fetch default country based on IP address of user",inDemo:!1},{name:"dropdownOptions",type:Object,description:"Options for dropdown, see below",inDemo:!1},{name:"dropdownOptions.ariaLabel",default:"Country Code Selector",type:String,description:"Aria label for the country code selector dropdown",inDemo:!1},{name:"dropdownOptions.disabled",default:!1,type:Boolean,description:"Disable dropdown",inDemo:!1},{name:"dropdownOptions.showDialCodeInList",default:!0,type:Boolean,description:"Show dial code in the dropdown list",inDemo:!0},{name:"dropdownOptions.showDialCodeInSelection",default:!1,type:Boolean,description:"Show dial code in the dropdown selection",inDemo:!0},{name:"dropdownOptions.showFlags",default:!0,type:Boolean,description:"Show flags in the dropdown selection and list",inDemo:!0},{name:"dropdownOptions.showSearchBox",default:!1,type:Boolean,description:"Show country search box",inDemo:!0},{name:"dropdownOptions.searchBoxPlaceholder",default:"",type:String,description:"Placeholder for the search box",inDemo:!1},{name:"dropdownOptions.tabindex",default:0,type:Number,description:"Native dropdown <code>tabindex</code> attribute",inDemo:!1},{name:"ignoredCountries",default:[],type:Array,description:"List of countries will NOT be shown on the dropdown",inDemo:!1},{name:"inputOptions",type:Object,description:"Options for input, see below",inDemo:!1},{name:"inputOptions.autocomplete",type:String,default:"on",description:"Native input <code>autocomplete</code> attribute",inDemo:!1},{name:"inputOptions.autofocus",type:Boolean,default:!1,description:"Native input <code>autofocus</code> attribute",inDemo:!1},{name:"inputOptions.aria-describedby",default:"",type:String,description:"Native input <code>aria-describedby</code> attribute",inDemo:!1},{name:"inputOptions.id",default:"",type:String,description:"Native input <code>id</code> attribute",inDemo:!1},{name:"inputOptions.maxlength",default:25,type:Number,description:"Native input <code>maxlength</code> attribute",inDemo:!1}
45,{name:"inputOptions.name",default:"telephone",type:String,description:"Native input <code>name</code> attribute",inDemo:!1},{name:"inputOptions.showDialCode",default:!1,type:Boolean,description:"Show dial code in input",inDemo:!1},{name:"inputOptions.placeholder",default:"Enter a phone number",type:String,description:"Placeholder for the input",inDemo:!1},{name:"inputOptions.readonly",default:!1,type:Boolean,description:"Native input <code>readonly</code> attribute",inDemo:!1},{name:"inputOptions.required",default:!1,type:Boolean,description:"Native input <code>required</code> attribute",inDemo:!1},{name:"inputOptions.tabindex",default:0,type:Number,description:"Native input <code>tabindex</code> attribute",inDemo:!1},{name:"inputOptions.type",default:"tel",type:String,description:"Native input <code>type</code> attribute",inDemo:!1},{name:"inputOptions.styleClasses",default:"",type:[String,Array,Object],description:"Custom classes for the <code>input</code>",inDemo:!1},{name:"invalidMsg",default:"",type:String,description:"",inDemo:!1},{name:"mode",default:"auto",type:String,description:"Allowed values: <code>'auto'</code> (Default set by phone), <code>'international'</code> (Format number with the dial code i.e. + 61), <code>'national'</code> (Format number without dial code i.e. 0321232)",inDemo:!0,options:["auto","national","international"]},{name:"onlyCountries",default:[],type:Array,description:"List of countries will be shown on the dropdown",inDemo:!1},{name:"preferredCountries",default:[],type:Array,description:"Preferred countries list, will be on top of the dropdown",inDemo:!1},{name:"styleClasses",default:"",type:[String,Array,Object],description:"Custom classes for the wrapper",inDemo:!1},{name:"validCharactersOnly",default:!1,type:Boolean,description:"Only allow valid characters in a phone number (will also verify in <code>mounted</code>, so phone number with invalid characters will be shown as an empty string)",inDemo:!1},{name:"strictValidation",default:!1,type:Boolean,description:"Use strict phone number validation with full metadata (libphonenumber-js/max). When false (default), uses minimal metadata for smaller bundle size. When true, validates phone number patterns more precisely but increases bundle size by ~145KB.",inDemo:!1}],aD=[...uce].reduce((e,t)=>{if(t.name.includes(".")){const[r,i]=t.name.split(".");e[r]?Object.assign(e[r],{[i]:t.default}):Object.assign(e,{[r]:{[i]:t.default}})}else Object.assign(e,{[t.name]:t.default});return e},{}),ix={options:{...aD}};function Xi(e){const t=ix.options[e];return typeof t>"u"?ix.options[e]:t}function _f(e){return e==null?void 0:e.toLowerCase()}function yf(e){return e==null?void 0:e.toUpperCase()}let ec=null,Zv=null;async function cce(){return ec||Zv||(Zv=Hoe(()=>import("./index-z9l8C72U-Bx4tQYau.js"),[]).then(e=>(ec=e.parsePhoneNumberFromString,ec)),Zv)}function K6(e,t,r=!1){return r&&ec?t?ec(e,t):ec(e):t?Uf(e,t):Uf(e)}function X6(){return ec!==null}const dce={beforeMount(e,t,r){if(typeof t.value!="function"){const i=r.context.name;let n=`[Vue-click-outside:] provided expression ${t.expression} is not a function, but has to be`;i&&(n+=`Found in component ${i}`),console.warn(n)}e.clickOutsideEvent=function(i){const n=i.composedPath?i.composedPath():i.path;e===i.target||e.contains(i.target)||n.includes(e)||t.value(i,e)},document.body.addEventListener("click",e.clickOutsideEvent)},unmounted(e){document.body.removeEventListener("click",e.clickOutsideEvent)}},hce=["aria-label","aria-expanded","tabindex"],fce={class:"vti__selection"},pce={key:1,class:"vti__country-code"},mce={class:"vti__dropdown-arrow"},gce={key:0,class:"vti__search_box_container"},_ce=["placeholder"],yce=["onClick","onMousemove","aria-selected"],vce={key:1},bce=["type","autocomplete","autofocus","disabled","id","maxlength","name","placeholder","readonly","required","tabindex","value","aria-describedby"],xce=fr({name:"VueTelInput",directives:{clickOutside:dce},__name:"vue-tel-input",props:Hp({allCountries:{type:Array,default:()=>Xi("allCountries")},autoFormat:{type:Boolean,default:()=>Xi("autoFormat")},customValidate:{type:[Boolean,RegExp],default:()=>Xi("customValidate")},defaultCountry:{type:[String,Number],default:()=>Xi("defaultCountry")},disabled:{type:Boolean,default:()=>Xi("disabled")},autoDefaultCountry:{type:Boolean,default:()=>Xi("autoDefaultCountry")},dropdownOptions:{type:Object,default:()=>Xi("dropdownOptions")},ignoredCountries:{type:Array,default:()=>Xi("ignoredCountries")},inputOptions:{type:Object,default:()=>Xi("inputOptions")},invalidMsg:{type:String,default:()=>Xi("invalidMsg")},mode:{type:String,default:()=>Xi("mode")},onlyCountries:{type:Array,default:()=>Xi("onlyCountries")},preferredCountries:{type:Array,default:()=>Xi("preferredCountries")}
45,validCharactersOnly:{type:Boolean,default:()=>Xi("validCharactersOnly")},styleClasses:{type:[String,Array,Object],default:()=>Xi("styleClasses")},strictValidation:{type:Boolean,default:()=>Xi("strictValidation")}},{modelValue:{type:String},modelModifiers:{}}),emits:Hp(["blur","close","country-changed","enter","focus","on-input","open","space","validate"],["update:modelValue"]),setup(e,{expose:t,emit:r}){const i=Yu(),n=Yu(),a=Yu(),s=r,o=e,l=se(X6()),u=Al(e,"modelValue");tt(u,(Z,K)=>{E()?c.phone=Z??"":Bi(()=>{c.phone=K??"",I()})});const c=An({phone:"",activeCountryCode:void 0,open:!1,finishMounted:!1,selectedIndex:null,typeToFindInput:"",typeToFindTimer:void 0,dropdownOpenDirection:"below",parsedPlaceholder:o.inputOptions.placeholder,searchQuery:""});tt(()=>c.open,Z=>{Z?(ue(),s("open")):s("close")});const d=H(()=>o.onlyCountries.length?o.allCountries.filter(({iso2:Z})=>o.onlyCountries.some(K=>yf(K)===Z)):o.ignoredCountries.length?o.allCountries.filter(({iso2:Z})=>!o.ignoredCountries.includes(yf(Z))&&!o.ignoredCountries.includes(_f(Z))):o.allCountries),h=H(()=>_(c.activeCountryCode));tt(h,(Z,K)=>{if(!Z&&K!=null&&K.iso2){c.activeCountryCode=K.iso2;return}Z!=null&&Z.iso2&&s("country-changed",Z)});const f=H(()=>{var Z;const K=_f(o.mode);return K==="auto"?(Z=c.phone)!=null&&Z.startsWith("+")?"international":"national":["national","international","e.164","rfc3966","idd"].includes(K)?K:(console.error('Invalid value of prop "mode"'),"international")}),p=H(()=>{const Z=[...x(o.preferredCountries).map(fe=>({...fe,preferred:!0})),...d.value];if(!o.dropdownOptions.showSearchBox)return Z;const K=c.searchQuery.toLowerCase().replace(/[~`!@#$%^&*()+={}\[\];:\'\"<>.,\/\\\?-_]/g,"");return Z.filter(fe=>new RegExp(K,"i").test(fe.name)||new RegExp(K,"i").test(fe.iso2)||new RegExp(K,"i").test(fe.dialCode))}),m=H(()=>{var Z;l.value;const K=c.phone.startsWith("+")?K6(c.phone,void 0,o.strictValidation):K6(c.phone,c.activeCountryCode,o.strictValidation),fe={country:K==null?void 0:K.country,countryCode:K==null?void 0:K.country,formatted:c.phone,valid:K==null?void 0:K.isValid(),possible:(Z=K==null?void 0:K.isPossible)==null?void 0:Z.call(K),nationalNumber:K==null?void 0:K.nationalNumber};return fe.valid&&(fe.formatted=K==null?void 0:K.format(yf(f.value))),K!=null&&K.country&&(o.ignoredCountries.length||o.onlyCountries.length)&&!_(K.country)&&(fe.valid=!1,fe.possible=!1,K.country=null),K?{...fe,...K}:fe});tt(()=>m.value.countryCode,Z=>{Z&&(c.activeCountryCode=Z)}),tt(()=>m.value.valid,()=>{s("validate",m.value)}),tt(()=>m.value.formatted,Z=>{!o.autoFormat||o.customValidate||(P(Z),Bi(()=>{Z&&!u.value&&(c.phone=Z)}))}),tt(()=>o.inputOptions.placeholder,g),or(()=>{o.strictValidation&&!X6()&&cce().then(()=>{l.value=!0,s("validate",m.value)}),u.value&&(c.phone=u.value.trim()),S(),v().then(()=>{var Z;!c.phone&&(Z=o.inputOptions)!=null&&Z.showDialCode&&c.activeCountryCode&&(c.phone=`+${c.activeCountryCode}`),s("validate",m.value)}).catch(console.error).then(()=>{c.finishMounted=!0})});function g(){c.parsedPlaceholder=o.inputOptions.placeholder}function v(){return new Promise(Z=>{var K;if(((K=c.phone)==null?void 0:K[0])==="+"){Z();return}if(o.defaultCountry){if(typeof o.defaultCountry=="string"){$(o.defaultCountry),Z();return}if(typeof o.defaultCountry=="number"){const ve=y(o.defaultCountry);if(ve){$(ve.iso2),Z();return}}}const fe=o.preferredCountries[0]||d.value[0];o.autoDefaultCountry?oce().then(ve=>{$(ve||c.activeCountryCode)}).catch(ve=>{console.warn(ve),$(fe)}).then(()=>{Z()}):($(fe),Z())})}function x(Z=[]){return Z.map(_).filter(Boolean)}function _(Z=""){return d.value.find(K=>K.iso2===yf(Z))}function y(Z){return d.value.find(K=>Number(K.dialCode)===Z)}function w(Z,K){const fe=c.selectedIndex===Z,ve=Z===o.preferredCountries.length-1,$e=o.preferredCountries.some(Re=>yf(Re)===K);return{highlighted:fe,"last-preferred":ve,preferred:$e}}function $(Z){var K,fe,ve;let $e=Z;if(typeof $e=="string"&&($e=_($e)),!!$e){if(((K=c.phone)==null?void 0:K[0])==="+"&&$e.iso2&&m.value.nationalNumber){c.activeCountryCode=$e.iso2,c.phone=((fe=Uf(m.value.nationalNumber,$e.iso2))==null?void 0:fe.formatInternational())??"";return}if((ve=o.inputOptions)!=null&&ve.showDialCode&&$e){c.phone=`+${$e.dialCode}`,c.activeCountryCode=$e.iso2;return}c.activeCountryCode=$e.iso2,P(c.phone)}}function S(){const Z=c.phone;if(o.validCharactersOnly){const K=c.phone.match(/[()\-+0-9\s]*/g);c.phone=K.join("")}if(o.customValidate&&o.customValidate instanceof RegExp){const K=c.phone.match(o.customValidate);c.phone=K.join("")}Z!==c.phone&&P(c.phone)}function E(){return o.validCharactersOnly&&!/^[()\-+0-9\s]*$/.test(c.phone)?!1:o.customValidate?C():!0}function C(){return o.customValidate instanceof RegExp?o.customValidate.test(c.phone):!1}function I(){var Z;(Z=a.value)==null||Z.setCustomValidity(m.value.valid?"":o.invalidMsg),P(c.phone)}function P(Z){u.value=Z,s("on-input",Z,m.value,a.value)}function T(Z){s("blur",Z)}function D(Z){lce(a.value,c.phone.length),s("focus",Z)}function A(Z){s("enter",Z)}function z(Z){s("space",Z)}function R(){var Z;(Z=a.value)==null||Z.focus()}function O(){var Z;(Z=a.value)==null||Z.blur()}function V(){o.disabled||o.dropdownOptions.disabled||(c.searchQuery="",c.open=!c.open)}function Y(){c.open=!1}function F(Z){if(Z.keyCode===40){Z.preventDefault(),c.open=!0,c.selectedIndex===null?c.selectedIndex=0:c.selectedIndex=Math.min(p.value.length-1,c.selectedIndex+1);const K=n.value.children[c.selectedIndex];K.focus(),K.offsetTop+K.clientHeight>n.value.scrollTop+n.value.clientHeight&&(n.value.scrollTop=K.offsetTop-n.value.clientHeight+K.clientHeight)}else if(Z.keyCode===38){Z.preventDefault(),c.open=!0,c.selectedIndex===null?c.selectedIndex=
45p.value.length-1:c.selectedIndex=Math.max(0,c.selectedIndex-1);const K=n.value.children[c.selectedIndex];K.focus(),K.offsetTop<n.value.scrollTop&&(n.value.scrollTop=K.offsetTop)}else if(Z.keyCode===13)c.selectedIndex!==null&&$(p.value[c.selectedIndex]),c.open=!c.open;else if(c.open){c.typeToFindInput+=Z.key,clearTimeout(c.typeToFindTimer),c.typeToFindTimer=setTimeout(()=>{c.typeToFindInput=""},700);const K=p.value.slice(o.preferredCountries.length).findIndex(fe=>_f(fe.name).startsWith(c.typeToFindInput));if(K>=0){c.selectedIndex=o.preferredCountries.length+K;const fe=n.value.children[c.selectedIndex],ve=fe.offsetTop<n.value.scrollTop,$e=fe.offsetTop+fe.clientHeight>n.value.scrollTop+n.value.clientHeight;(ve||$e)&&(n.value.scrollTop=fe.offsetTop-n.value.clientHeight/2)}}}function ae(){c.selectedIndex=p.value.map(Z=>Z.iso2).indexOf(c.activeCountryCode),c.open=!1}function ue(){window.innerHeight-i.value.getBoundingClientRect().bottom>200?c.dropdownOpenDirection="below":c.dropdownOpenDirection="above"}return t({focus:R,blur:O}),(Z,K)=>{const fe=A3("click-outside");return k(),M("div",{ref_key:"refRoot",ref:i,class:pe(["vue-tel-input",e.styleClasses,{disabled:e.disabled}])},[it((k(),M("div",{"aria-label":e.dropdownOptions.ariaLabel,"aria-haspopup":"listbox","aria-expanded":c.open,role:"button",class:pe(["vti__dropdown",{open:c.open,disabled:e.dropdownOptions.disabled}]),tabindex:e.dropdownOptions.tabindex,onKeydown:[F,Ao(V,["space"]),Ao(ae,["esc"]),Ao(ae,["tab"])],onClick:V},[b("span",fce,[e.dropdownOptions.showFlags?(k(),M("span",{key:0,class:pe(["vti__flag",le(_f)(c.activeCountryCode)])},null,2)):X("",!0),e.dropdownOptions.showDialCodeInSelection?(k(),M("span",pce," +"+Q(h.value&&h.value.dialCode),1)):X("",!0),ws(Z.$slots,"arrow-icon",{open:c.open},()=>[b("span",mce,Q(c.open?"â²":"â¼"),1)])]),c.open?(k(),M("ul",{key:0,ref_key:"refList",ref:n,class:pe(["vti__dropdown-list",c.dropdownOpenDirection]),role:"listbox"},[e.dropdownOptions.showSearchBox?(k(),M("div",gce,[ws(Z.$slots,"search-icon"),it(b("input",{class:pe(["vti__input","vti__search_box"]),"aria-label":"Search by country name or country code",placeholder:e.dropdownOptions.searchBoxPlaceholder||(p.value.length?p.value[0].name:""),type:"text","onUpdate:modelValue":K[0]||(K[0]=ve=>c.searchQuery=ve),onClick:K[1]||(K[1]=di(()=>{},["stop"]))},null,8,_ce),[[ui,c.searchQuery]])])):X("",!0),(k(!0),M(xe,null,Me(p.value,(ve,$e)=>(k(),M("li",{role:"option",class:pe(["vti__dropdown-item",w($e,ve.iso2)]),key:ve.iso2+(ve.preferred?"-preferred":""),tabindex:"-1",onClick:Re=>$(ve),onMousemove:Re=>c.selectedIndex=$e,"aria-selected":c.activeCountryCode===ve.iso2&&!ve.preferred},[e.dropdownOptions.showFlags?(k(),M("span",{key:0,class:pe(["vti__flag",le(_f)(ve.iso2)])},null,2)):X("",!0),b("strong",null,Q(ve.name),1),e.dropdownOptions.showDialCodeInList?(k(),M("span",vce," +"+Q(ve.dialCode),1)):X("",!0)],42,yce))),128))],2)):X("",!0)],42,hce)),[[fe,Y]]),it(b("input",{"onUpdate:modelValue":K[2]||(K[2]=ve=>c.phone=ve),ref_key:"refInput",ref:a,type:e.inputOptions.type,autocomplete:e.inputOptions.autocomplete,autofocus:e.inputOptions.autofocus,class:pe(["vti__input","vti__phone",e.inputOptions.styleClasses]),disabled:e.disabled,id:e.inputOptions.id,maxlength:e.inputOptions.maxlength,name:e.inputOptions.name,placeholder:c.parsedPlaceholder,readonly:e.inputOptions.readonly,required:e.inputOptions.required,tabindex:e.inputOptions.tabindex,value:u.value,"aria-describedby":e.inputOptions["aria-describedby"],onBlur:T,onFocus:D,onInput:I,onKeyup:[Ao(A,["enter"]),Ao(z,["space"])]},null,42,bce),[[m1,c.phone]]),ws(Z.$slots,"icon-right")],2)}}}),wce={install(e,t={}){const{dropdownOptions:r,inputOptions:i,...n}=t,{dropdownOptions:a,inputOptions:s,...o}=aD;ix.options={inputOptions:{...s,...i},dropdownOptions:{...a,...r},...o,...n},e.component("vue-tel-input",xce)}};/** 46 * Vue 3 Carousel 0.16.0 47 * (c) 2025 48 * @license MIT 49 */const sD=["viewport","carousel"],oy={"bottom-to-top":"btt","left-to-right":"ltr","right-to-left":"rtl","top-to-bottom":"ttb"},oD=["ltr","left-to-right","rtl","right-to-left","ttb","top-to-bottom","btt","bottom-to-top"],$ce={ariaGallery:"Gallery",ariaNavigateToPage:"Navigate to page {slideNumber}
49",ariaNavigateToSlide:"Navigate to slide {slideNumber}",ariaNextSlide:"Navigate to next slide",ariaPreviousSlide:"Navigate to previous slide",iconArrowDown:"Arrow pointing downwards",iconArrowLeft:"Arrow pointing to the left",iconArrowRight:"Arrow pointing to the right",iconArrowUp:"Arrow pointing upwards",itemXofY:"Item {currentSlide} of {slidesCount}"},lD=["slide","fade"],uD=["center","start","end","center-even","center-odd"],J6=10,Gg=.08,Zr={autoplay:0,breakpointMode:sD[0],breakpoints:void 0,dir:oD[0],enabled:!0,gap:0,height:"auto",i18n:$ce,ignoreAnimations:!1,itemsToScroll:1,itemsToShow:1,modelValue:0,mouseDrag:!0,mouseWheel:!1,pauseAutoplayOnHover:!1,preventExcessiveDragging:!1,slideEffect:lD[0],snapAlign:uD[0],touchDrag:!0,transition:300,wrapAround:!1},dm=Symbol("carousel"),Sce=e=>{const t=jp([]),r=i=>{i!==void 0?t.slice(i).forEach((n,a)=>{var s;(s=n.exposed)===null||s===void 0||s.setIndex(i+a)}):t.forEach((n,a)=>{var s;(s=n.exposed)===null||s===void 0||s.setIndex(a)})};return{cleanup:()=>{t.splice(0,t.length)},getSlides:()=>t,registerSlide:(i,n)=>{if(!i||i.props.isClone)return;const a=n??t.length;t.splice(a,0,i),r(a),e("slide-registered",{slide:i,index:a})},unregisterSlide:i=>{const n=t.indexOf(i);n!==-1&&(e("slide-unregistered",{slide:i,index:n}),t.splice(n,1),r(n))}}};function Tce(e){return e.length===0?0:e.reduce((r,i)=>r+i,0)/e.length}function Q6({slides:e,position:t,toShow:r}){const i=[],n=t==="before",a=n?-r:0,s=n?0:r;if(e.length<=0)return i;for(let o=a;o<s;o++){const u={index:n?o:o+e.length,isClone:!0,id:void 0,key:`clone-${t}-${o}`},c=e[(o%e.length+e.length)%e.length].vnode,d=ks(c,u);d.el=null,i.push(d)}return i}const Cce='a[href], button, input, textarea, select, details, [tabindex]:not([tabindex="-1"])';function eC(e){if(!e.el||!(e.el instanceof Element))return;const t=e.el.querySelectorAll(Cce);for(const r of t)r instanceof HTMLElement&&!r.hasAttribute("disabled")&&r.getAttribute("aria-hidden")!=="true"&&r.setAttribute("tabindex","-1")}function kce(e,t){return Object.keys(e).filter(r=>!t.includes(r)).reduce((r,i)=>(r[i]=e[i],r),{})}function Ece(e){const{isVertical:t,isReversed:r,dragged:i,effectiveSlideSize:n,threshold:a}=e,s=t?i.y:i.x;if(s===0)return 0;const o=s/n,l=Math.abs(o);if(l<a)return 0;const u=l<1?Math.sign(o):Math.round(o);return r?u:-u}function vo({val:e,max:t,min:r}){return t<r?e:Math.min(Math.max(e,isNaN(r)?e:r),isNaN(t)?e:t)}function Pce(e){const{transform:t}=window.getComputedStyle(e);return t.split(/[(,)]/).slice(1,-1).map(r=>parseFloat(r))}function Mce(e){let t=1,r=1;return e.forEach(i=>{const n=Pce(i);n.length===6&&(t/=n[0],r/=n[3])}),{widthMultiplier:t,heightMultiplier:r}}function Ice(e,t){switch(e){case"start":return 0;case"center":case"center-odd":return(t-1)/2;case"center-even":return(t-2)/2;case"end":return t-1;default:return 0}}function Ace(e,t,r){switch(e){case"start":return 0;case"center":case"center-odd":return(r-t)/2;case"center-even":return r/2-t;case"end":return r-t;default:return 0}}function nx({slideSize:e,viewportSize:t,align:r,itemsToShow:i}){return i!==void 0?Ice(r,i):e!==void 0&&t!==void 0?Ace(r,e,t):0}function cD(e="",t={}){return Object.entries(t).reduce((r,[i,n])=>r.replace(`{${i}}`,String(n)),e)}function dD({val:e,max:t,min:r=0}){const i=t-r+1;return((e-r)%i+i)%i+r}function ax(e,t=0){let r=!1,i=0,n=null;function a(...s){if(r)return;r=!0;const o=()=>{n=requestAnimationFrame(l=>{l-i>t?(i=l,e(...s),r=!1):o()})};o()}return a.cancel=()=>{n&&(cancelAnimationFrame(n),n=null,r=!1)},a}function Hg(e,t="px"){if(!(e==null||e===""))return typeof e=="number"||parseFloat(e).toString()===e?`${e}${t}`:e}const Dce=fr({name:"CarouselAria",setup(){const e=Gi(dm);return e?()=>qa("div",{class:["carousel__liveregion","carousel__sr-only"],"aria-live":"polite","aria-atomic":"true"},cD(e.config.i18n.itemXofY,{currentSlide:e.currentSlide+1,slidesCount:e.slidesCount})):()=>""}});function Rce(e){let t=!1;const r={x:0,y:0},i=An({x:0,y:0}),n=se(!1),{isSliding:a}=e,s=H(()=>typeof a=="boolean"?a:a.value),o=c=>{var d;const h=c.target.tagName;if(["INPUT","TEXTAREA","SELECT"].includes(h)||s.value||(t=c.type==="touchstart",t&&c.touches.length>1))return;if(!t&&(c.preventDefault(),c.button!==0))return;r.x=t?c.touches[0].clientX:c.clientX,r.y=t?c.touches[0].clientY:c.clientY;
49const f=t?"touchmove":"mousemove",p=t?"touchend":"mouseup";document.addEventListener(f,l,{passive:!1}),document.addEventListener(p,u,{passive:!0}),(d=e.onDragStart)===null||d===void 0||d.call(e)},l=ax(c=>{var d;if(t&&c.touches.length>1)return;n.value=!0;const h=t?c.touches[0].clientX:c.clientX,f=t?c.touches[0].clientY:c.clientY;i.x=h-r.x,i.y=f-r.y,(d=e.onDrag)===null||d===void 0||d.call(e,{deltaX:i.x,deltaY:i.y,isTouch:t})}),u=()=>{var c;l.cancel();const d=Math.abs(i.x)+Math.abs(i.y);!t&&d>10&&window.addEventListener("click",p=>{p.preventDefault(),p.stopPropagation()},{once:!0,capture:!0}),(c=e.onDragEnd)===null||c===void 0||c.call(e),i.x=0,i.y=0,n.value=!1;const h=t?"touchmove":"mousemove",f=t?"touchend":"mouseup";document.removeEventListener(h,l),document.removeEventListener(f,u)};return{dragged:i,isDragging:n,handleDragStart:o}}function Oce(){const e=se(!1);return{isHover:e,handleMouseEnter:()=>{e.value=!0},handleMouseLeave:()=>{e.value=!1}}}function Lce(e){const{isVertical:t,isSliding:r,config:i}=e,n=H(()=>typeof t=="boolean"?t:t.value),a=H(()=>typeof r=="boolean"?r:r.value);return{handleScroll:o=>{var l,u;if(o.preventDefault(),!i.mouseWheel||a.value)return;const c=typeof i.mouseWheel=="object"&&(l=i.mouseWheel.threshold)!==null&&l!==void 0?l:J6,d=Math.abs(o.deltaY)>c?o.deltaY:0,h=Math.abs(o.deltaX)>c?o.deltaX:0;if(d===0&&h===0)return;const f=n.value?d:h,m=(f!==0?f:n.value?h:d)>0;(u=e.onWheel)===null||u===void 0||u.call(e,{deltaX:h,deltaY:d,isScrollingForward:m})}}}const Fce={autoplay:{default:Zr.autoplay,type:Number},breakpoints:{default:Zr.breakpoints,type:Object},breakpointMode:{default:Zr.breakpointMode,validator(e){return sD.includes(e)}},clamp:{type:Boolean},dir:{type:String,default:Zr.dir,validator(e,t){if(!oD.includes(e))return!1;const r=e in oy?oy[e]:e;return["ttb","btt"].includes(r)&&(!t.height||t.height==="auto")&&console.warn(`[vue3-carousel]: The dir "${e}" is not supported with height "auto".`),!0}},enabled:{default:Zr.enabled,type:Boolean},gap:{default:Zr.gap,type:Number},height:{default:Zr.height,type:[Number,String]},i18n:{default:Zr.i18n,type:Object},ignoreAnimations:{default:!1,type:[Array,Boolean,String]},itemsToScroll:{default:Zr.itemsToScroll,type:Number},itemsToShow:{default:Zr.itemsToShow,type:[Number,String]},modelValue:{default:void 0,type:Number},mouseDrag:{default:Zr.mouseDrag,type:[Boolean,Object]},mouseWheel:{default:Zr.mouseWheel,type:[Boolean,Object]},mouseScrollThreshold:{default:Zr.mouseScrollThreshold,type:Number},pauseAutoplayOnHover:{default:Zr.pauseAutoplayOnHover,type:Boolean},preventExcessiveDragging:{default:!1,type:Boolean,validator(e,t){return e&&t.wrapAround&&console.warn('[vue3-carousel]: "preventExcessiveDragging" cannot be used with wrapAround. The setting will be ignored.'),!0}},slideEffect:{type:String,default:Zr.slideEffect,validator(e){return lD.includes(e)}},snapAlign:{default:Zr.snapAlign,validator(e){return uD.includes(e)}},touchDrag:{default:Zr.touchDrag,type:[Boolean,Object]},transition:{default:Zr.transition,type:Number},wrapAround:{default:Zr.wrapAround,type:Boolean}},D1=fr({name:"VueCarousel",props:Fce,emits:["before-init","drag","init","loop","slide-end","slide-registered","slide-start","slide-unregistered","update:modelValue","wheel"],setup(e,{slots:t,emit:r,expose:i}){var n;const a=Sce(r),s=a.getSlides(),o=H(()=>s.length),l=se(null),u=se(null),c=se(0),d=H(()=>Object.assign(Object.assign(Object.assign({},Zr),kce(e,["breakpoints","modelValue"])),{i18n:Object.assign(Object.assign({},Zr.i18n),e.i18n)}
49)),h=jp(Object.assign({},d.value)),f=se((n=e.modelValue)!==null&&n!==void 0?n:0),p=se(f.value);tt(f,B=>p.value=B);const m=se(0),g=H(()=>Math.ceil((o.value-1)/2)),v=H(()=>o.value-1),x=H(()=>0);let _=null,y=null,w=null;const $=H(()=>c.value+h.gap),S=H(()=>{const B=h.dir||"ltr";return B in oy?oy[B]:B}),E=H(()=>["rtl","btt"].includes(S.value)),C=H(()=>["ttb","btt"].includes(S.value)),I=H(()=>h.itemsToShow==="auto"),P=H(()=>C.value?"height":"width");function T(){var B;if(!fe.value)return;const re=(d.value.breakpointMode==="carousel"?(B=l.value)===null||B===void 0?void 0:B.getBoundingClientRect().width:typeof window<"u"?window.innerWidth:0)||0,_e=Object.keys(e.breakpoints||{}).map(Fe=>Number(Fe)).sort((Fe,ht)=>+ht-+Fe),Ee={};_e.some(Fe=>re>=Fe?(Object.assign(Ee,e.breakpoints[Fe]),Ee.i18n&&Object.assign(Ee.i18n,d.value.i18n,e.breakpoints[Fe].i18n),!0):!1),Object.assign(h,d.value,Ee),I.value||(h.itemsToShow=vo({val:Number(h.itemsToShow),max:e.clamp?o.value:1/0,min:1}))}const D=ax(()=>{T(),F(),Y()}),A=jp(new Set),z=se([]);function R({widthMultiplier:B,heightMultiplier:re}){z.value=s.map(_e=>{var Ee;const Fe=(Ee=_e.exposed)===null||Ee===void 0?void 0:Ee.getBoundingRect();return{width:Fe.width*B,height:Fe.height*re}})}const O=se({width:0,height:0});function V({widthMultiplier:B,heightMultiplier:re}){var _e;const Ee=((_e=u.value)===null||_e===void 0?void 0:_e.getBoundingClientRect())||{width:0,height:0};O.value={width:Ee.width*B,height:Ee.height*re}}function Y(){if(!u.value)return;const B=Mce(A);if(V(B),R(B),I.value)c.value=Tce(z.value.map(re=>re[P.value]));else{const re=Number(h.itemsToShow),_e=(re-1)*h.gap;c.value=(O.value[P.value]-_e)/re}}function F(){!h.wrapAround&&o.value>0&&(f.value=vo({val:f.value,max:v.value,min:x.value}))}const ae=H(()=>typeof e.ignoreAnimations=="string"?e.ignoreAnimations.split(","):Array.isArray(e.ignoreAnimations)?e.ignoreAnimations:e.ignoreAnimations?!1:[]);Rd(()=>F()),Rd(()=>{Y()});let ue;const Z=B=>{const re=B.target;if(!(!(re!=null&&re.contains(l.value))||Array.isArray(ae.value)&&ae.value.includes(B.animationName))&&(A.add(re),!ue)){const _e=()=>{ue=requestAnimationFrame(()=>{Y(),_e()})};_e()}},K=B=>{const re=B.target;re&&A.delete(re),ue&&A.size===0&&(cancelAnimationFrame(ue),Y())},fe=se(!1);typeof document<"u"&&Rd(()=>{fe.value&&ae.value!==!1?(document.addEventListener("animationstart",Z),document.addEventListener("animationend",K)):(document.removeEventListener("animationstart",Z),document.removeEventListener("animationend",K))}),or(()=>{fe.value=!0,T(),qe(),l.value&&(w=new ResizeObserver(D),w.observe(l.value)),r("init")}),ra(()=>{fe.value=!1,a.cleanup(),y&&clearTimeout(y),ue&&cancelAnimationFrame(ue),_&&clearInterval(_),w&&(w.disconnect(),w=null),typeof document<"u"&&ze(),l.value&&(l.value.removeEventListener("transitionend",Y),l.value.removeEventListener("animationiteration",Y))});const{isHover:ve,handleMouseEnter:$e,handleMouseLeave:Re}=Oce(),Oe=ax(B=>{if(!B.ctrlKey)switch(B.key){case"ArrowLeft":case"ArrowUp":C.value===B.key.endsWith("Up")&&(E.value?te(!0):ee(!0));break;case"ArrowRight":case"ArrowDown":C.value===B.key.endsWith("Down")&&(E.value?ee(!0):te(!0));break}},200),ze=()=>{document.removeEventListener("keydown",Oe)},Be=()=>{document.addEventListener("keydown",Oe)};function qe(){!h.autoplay||h.autoplay<=0||(_=setInterval(()=>{h.pauseAutoplayOnHover&&ve.value||te()},h.autoplay))}function j(){W(),qe()}function W(){_&&(clearInterval(_),_=null)}const G=se(!1),ie=({deltaX:B,deltaY:re,isTouch:_e})=>{var Ee,Fe,ht,Et;r("drag",{deltaX:B,deltaY:re});const lr=_e?typeof h.touchDrag=="object"&&(Fe=(Ee=h.touchDrag)===null||Ee===void 0?void 0:Ee.threshold)!==null&&Fe!==void 0?Fe:Gg:typeof h.mouseDrag=="object"&&(Et=(ht=h.mouseDrag)===null||ht===void 0?void 0:ht.threshold)!==null&&Et!==void 0?Et:Gg,Br=Ece({isVertical:C.value,isReversed:E.value,dragged:{x:B,y:re},effectiveSlideSize:$.value,threshold:lr});Br!==0&&(p.value=h.wrapAround?f.value+Br:vo({val:f.value+Br,max:v.value,min:x.value}))},U=()=>oe(p.value),{dragged:ne,isDragging:me,handleDragStart:J}=Rce({isSliding:G,onDrag:ie,onDragEnd:U}),N=({deltaX:B,deltaY:re,isScrollingForward:_e})=>{r("wheel",{deltaX:B,deltaY:re}),_e?E.value?ee():te():E.value?te():ee()},{handleScroll:q}=Lce({isVertical:C,isSliding:G,config:h,onWheel:N});function te(B=!1){oe(f.value+h.itemsToScroll,B)}function ee(B=!1){oe(f.value-h.itemsToScroll,B)}function oe(B,re=!1){if(!re&&G.value)return;const _e=(h.wrapAround?dD:vo)({val:B,max:v.value,min:x.value});if(f.value===_e)return;m.value=f.value,r("slide-start",{slidingToIndex:B,currentSlideIndex:f.value,prevSlideIndex:m.value,slidesCount:o.value}),W(),G.value=!0,f.value=B,_e!==B&&we.pause(),r("update:modelValue",_e),y=setTimeout(()=>{h.wrapAround&&_e!==B&&(we.resume(),f.value=_e,r("loop",{currentSlideIndex:f.value,slidingToIndex:B})),r("slide-end",{currentSlideIndex:f.value,prevSlideIndex:m.value,slidesCount:o.value}),G.value=!1,j()},h.transition)}function Se(){T(),F(),Y(),j()}tt(()=>[d.value,e.breakpoints],()=>T(),{deep:!0}),tt(()=>e.autoplay,()=>j());const we=tt(()=>e.modelValue,B=>{B!==f.value&&oe(Number(B),!0)});r("before-init");const De=H(()=>
49{if(!h.wrapAround)return{before:0,after:0};if(I.value)return{before:s.length,after:s.length};const B=Number(h.itemsToShow),re=Math.ceil(B+(h.itemsToScroll-1)),_e=re-p.value,Ee=re-(o.value-(p.value+1));return{before:Math.max(0,_e),after:Math.max(0,Ee)}}),Ue=H(()=>De.value.before?I.value?z.value.slice(-1*De.value.before).reduce((B,re)=>B+re[P.value]+h.gap,0)*-1:De.value.before*$.value*-1:0),xt=H(()=>{var B;if(I.value){const re=(f.value%s.length+s.length)%s.length;return nx({slideSize:(B=z.value[re])===null||B===void 0?void 0:B[P.value],viewportSize:O.value[P.value],align:h.snapAlign})}return nx({align:h.snapAlign,itemsToShow:+h.itemsToShow})}),kt=H(()=>{let B=0;if(I.value){if(f.value<0?B=z.value.slice(f.value).reduce((re,_e)=>re+_e[P.value]+h.gap,0)*-1:B=z.value.slice(0,f.value).reduce((re,_e)=>re+_e[P.value]+h.gap,0),B-=xt.value,!h.wrapAround){const re=z.value.reduce((_e,Ee)=>_e+Ee[P.value]+h.gap,0)-O.value[P.value]-h.gap;B=vo({val:B,max:re,min:0})}}else{let re=f.value-xt.value;h.wrapAround||(re=vo({val:re,max:o.value-+h.itemsToShow,min:0})),B=re*$.value}return B*(E.value?1:-1)}),ot=H(()=>{var B,re;if(!I.value){const Fe=f.value-xt.value;return h.wrapAround?{min:Math.floor(Fe),max:Math.ceil(Fe+Number(h.itemsToShow)-1)}:{min:Math.floor(vo({val:Fe,max:o.value-Number(h.itemsToShow),min:0})),max:Math.ceil(vo({val:Fe+Number(h.itemsToShow)-1,max:o.value-1,min:0}))}}let _e=0;{let Fe=0,ht=0-De.value.before;const Et=Math.abs(kt.value+Ue.value);for(;Fe<=Et;){const lr=(ht%s.length+s.length)%s.length;Fe+=((B=z.value[lr])===null||B===void 0?void 0:B[P.value])+h.gap,ht++}_e=ht-1}let Ee=0;{let Fe=_e,ht=0;for(Fe<0?ht=z.value.slice(0,Fe).reduce((Et,lr)=>Et+lr[P.value]+h.gap,0)-Math.abs(kt.value+Ue.value):ht=z.value.slice(0,Fe).reduce((Et,lr)=>Et+lr[P.value]+h.gap,0)-Math.abs(kt.value);ht<O.value[P.value];){const Et=(Fe%s.length+s.length)%s.length;ht+=((re=z.value[Et])===null||re===void 0?void 0:re[P.value])+h.gap,Fe++}Ee=Fe-1}return{min:Math.floor(_e),max:Math.ceil(Ee)}}),rr=H(()=>{if(h.slideEffect==="fade")return;const B=C.value?"Y":"X",re=C.value?ne.y:ne.x;let _e=kt.value+re;if(!h.wrapAround&&h.preventExcessiveDragging){let Ee=0;I.value?Ee=z.value.reduce((Et,lr)=>Et+lr[P.value],0):Ee=(o.value-Number(h.itemsToShow))*$.value;const Fe=E.value?0:-1*Ee,ht=E.value?Ee:0;_e=vo({val:_e,min:Fe,max:ht})}return`translate${B}(${_e}px)`}),Cr=H(()=>({"--vc-carousel-height":Hg(h.height),"--vc-cloned-offset":Hg(Ue.value),"--vc-slide-gap":Hg(h.gap),"--vc-transition-duration":G.value?Hg(h.transition,"ms"):void 0})),Vt=An({activeSlide:p,config:h,currentSlide:f,isSliding:G,isVertical:C,maxSlide:v,minSlide:x,nav:{slideTo:oe,next:te,prev:ee},normalizedDir:S,slideRegistry:a,slideSize:c,slides:s,slidesCount:o,viewport:u,visibleRange:ot});xa(dm,Vt);const ge=An({config:h,currentSlide:f,maxSlide:v,middleSlide:g,minSlide:x,slideSize:c,slidesCount:o});return i(An(Object.assign({data:ge,next:te,prev:ee,restartCarousel:Se,slideTo:oe,updateBreakpointsConfig:T,updateSlideSize:Y,updateSlidesData:F},s1(Vt)))),()=>{var B;const re=t.default||t.slides,_e=(re==null?void 0:re(ge))||[],{before:Ee,after:Fe}=De.value,ht=Q6({slides:s,position:"before",toShow:Ee}),Et=Q6({slides:s,position:"after",toShow:Fe}),lr=[...ht,..._e,...Et];if(!h.enabled||!lr.length)return qa("section",{ref:l,class:["carousel","is-disabled"]},lr);const Br=((B=t.addons)===null||B===void 0?void 0:B.call(t,ge))||[],ls=qa("ol",{class:"carousel__track",onMousedownCapture:h.mouseDrag?J:null,onTouchstartPassiveCapture:h.touchDrag?J:null,onWheel:h.mouseWheel?q:null,style:{transform:rr.value}},lr),Ke=qa("div",{class:"carousel__viewport",ref:u},ls);return qa("section",{ref:l,class:["carousel",`is-${S.value}`,`is-effect-${h.slideEffect}`,{"is-dragging":me.value,"is-hover":ve.value,"is-sliding":G.value,"is-vertical":C.value}],dir:S.value,style:Cr.value,"aria-label":h.i18n.ariaGallery,tabindex:"0",onBlur:ze,onFocus:Be,onMouseenter:$e,onMouseleave:Re},[Ke,Br,qa(Dce)])}}});var tC;(function(e){e.arrowDown="arrowDown",e.arrowLeft="arrowLeft",e.arrowRight="arrowRight",e.arrowUp="arrowUp"})(tC||(tC={}));const zce=fr({name:"CarouselPagination",props:{disableOnClick:{type:Boolean},paginateByItemsToShow:{type:Boolean},carousel:{type:Object}},setup(e){let t=Gi(dm,null);const r=H(()=>t.config.itemsToShow),i=H(()=>nx({align:t.config.snapAlign,itemsToShow:r.value})),n=H(()=>e.paginateByItemsToShow&&r.value>1),a=H(()=>Math.ceil((t.activeSlide-i.value)/r.value)),s=H(()=>Math.ceil(t.slidesCount/r.value)),o=l=>dD(n.value?{val:a.value,max:s.value-1,min:0}:{val:t.activeSlide,max:t.maxSlide,min:t.minSlide})===l;return()=>{var l,u;if(e.carousel&&(t=e.carousel),!t)return console.warn("[vue3-carousel]: A carousel component must be provided for the pagination component to display"),"";const c=[];for(let d=n.value?0:t.minSlide;d<=(n.value?s.value-1:t.maxSlide);d++){const h=cD(t.config.i18n[n.value?"ariaNavigateToPage":"ariaNavigateToSli
49de"],{slideNumber:d+1}),f=o(d),p=qa("button",{type:"button",class:{"carousel__pagination-button":!0,"carousel__pagination-button--active":f},"aria-label":h,"aria-pressed":f,"aria-controls":(u=(l=t.slides[d])===null||l===void 0?void 0:l.exposed)===null||u===void 0?void 0:u.id,title:h,disabled:e.disableOnClick,onClick:()=>t.nav.slideTo(n.value?Math.floor(d*+t.config.itemsToShow+i.value):d)}),m=qa("li",{class:"carousel__pagination-item",key:d},p);c.push(m)}return qa("ol",{class:"carousel__pagination"},c)}}}),R1=fr({name:"CarouselSlide",props:{id:{type:String,default:e=>e.isClone?void 0:nM()},index:{type:Number,default:void 0},isClone:{type:Boolean,default:!1}},setup(e,{attrs:t,slots:r,expose:i}){const n=Gi(dm);if(xa(dm,void 0),!n)return()=>"";const a=se(e.index),s=p=>{a.value=p},o=pn(),l=()=>{const p=o.vnode.el;return p?p.getBoundingClientRect():{width:0,height:0}};i({id:e.id,setIndex:s,getBoundingRect:l});const u=H(()=>a.value===n.activeSlide),c=H(()=>a.value===n.activeSlide-1),d=H(()=>a.value===n.activeSlide+1),h=H(()=>a.value>=n.visibleRange.min&&a.value<=n.visibleRange.max),f=H(()=>{if(n.config.itemsToShow==="auto")return;const p=n.config.itemsToShow,m=n.config.gap>0&&p>1?`calc(${100/p}% - ${n.config.gap*(p-1)/p}px)`:`${100/p}%`;return n.isVertical?{height:m}:{width:m}});return n.slideRegistry.registerSlide(o,e.index),ss(()=>{n.slideRegistry.unregisterSlide(o)}),e.isClone&&(or(()=>{eC(o.vnode)}),jh(()=>{eC(o.vnode)})),()=>{var p,m;return n.config.enabled?qa("li",{style:[t.style,Object.assign({},f.value)],class:{carousel__slide:!0,"carousel__slide--clone":e.isClone,"carousel__slide--visible":h.value,"carousel__slide--active":u.value,"carousel__slide--prev":c.value,"carousel__slide--next":d.value,"carousel__slide--sliding":n.isSliding},onFocusin:()=>{n.viewport&&(n.viewport.scrollLeft=0),n.nav.slideTo(a.value)},id:e.isClone?void 0:e.id,"aria-hidden":e.isClone||void 0},(m=r.default)===null||m===void 0?void 0:m.call(r,{currentIndex:a.value,isActive:u.value,isClone:e.isClone,isPrev:c.value,isNext:d.value,isSliding:n.isSliding,isVisible:h.value})):(p=r.default)===null||p===void 0?void 0:p.call(r)}}}),Yt=(e,t)=>{const r=e.__vccOpts||e;for(const[i,n]of t)r[i]=n;return r},Nce={class:"relative"},Bce={class:"absolute bottom-half right-0 w-full flex justify-between z-30 -mb-5"},jce={class:"c05-carousel-wrap"},Uce={key:0,class:"c05-copyright-caption"},Vce={__name:"GalleryBlock",props:{images:{type:[Array,String],default:()=>[]}},setup(e){const t=se(null),r=se(0),i=e,n=H(()=>{if(Array.isArray(i.images))return i.images;try{return JSON.parse(i.images||"[]")}catch{return[]}}),a=()=>{var l;(l=t.value)==null||l.prev()},s=()=>{var l;(l=t.value)==null||l.next()},o=l=>{const u=(l&&(l.currentSlide??l.currentSlideIndex))??0;r.value=u};return(l,u)=>(k(),M("div",Nce,[b("div",Bce,[b("button",{onClick:di(a,["prevent"]),class:"w-8 h-8 md:h-10 md:w-10 bg-ag-green rounded-full flex justify-center lg:mx-5 mx-2 items-center transform rotate-180 fill-white"},[...u[0]||(u[0]=[b("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24"},[b("path",{d:"M7.293 4.707 14.586 12l-7.293 7.293 1.414 1.414L17.414 12 8.707 3.293 7.293 4.707z"})],-1)])]),b("button",{onClick:di(s,["prevent"]),class:"w-8 h-8 md:h-10 md:w-10 bg-ag-green rounded-full flex justify-center lg:mx-5 mx-2 items-center transform rotate-180 fill-white"},[...u[1]||(u[1]=[b("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24"},[b("path",{d:"M15.293 3.293 6.586 12l8.707 8.707 1.414-1.414L9.414 12l7.293-7.293-1.414-1.414z"})],-1)])])]),b("div",jce,[be(le(D1),{style:{height:"auto"},ref_key:"carousel",ref:t,"items-to-show":1.3,"wrap-around":!0,onSlideStart:o},{default:_t(()=>[(k(!0),M(xe,null,Me(n.value,c=>(k(),Mt(le(R1),{key:c.id},{default:_t(()=>[b("div",{class:"relative c05-gallery-item object-contain w-10/12 mx-auto bg-center bg-cover",style:Qt(`background-image: url(${c.url});`)},[c.copyright_caption?(k(),M("div",Uce,Q(c.copyright_caption),1)):X("",!0)],4)]),_:2},1024))),128))]),_:1},512)])]))}},qce=Yt(Vce,[["__scopeId","data-v-f6921b15"]]),Gce={class:"relative"},Hce={key:0,class:"absolute bottom-10 right-10 flex z-30"},Yce=["id"],Wce={key:0,class:"absolute bottom-3 left-5 copyright-caption z-10"},Zce={key:1},Kce={class:"absolute left-5 bottom-3 copyright-caption"},Xce={__name:"ImageCarousel",props:{images:{type:Array,default:()=>[]}},setup(e){const t=se(null),r=se(Date.now().toString(36)+Math.random().toString(36).substr(2)),i=H(()=>e.images||[]);function n(){var s;(s=t.value)==null||s.prev()}function a(){var s;(s=t.value)==null||s.next()}return(s,o)=>(k(),M("div",Gce,[e.images&&e.images.length>1?(k(),M("div",Hce,[b("button",{onClick:di(n,["prevent"]),class:"w-8 h-8 md:h-10 md:w-10 bg-ag-light-grey hover:bg-white opacity-75 rounded-full flex justify-center lg:mx-5 mx-2 items-center fill-black"},[...o[0]||(o[0]=[b("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24"},[b("path",{d:"M15.293 3.293 6.586 12l8.707 8.707 1.414-1.414L9.414 12l7.293-7.293-1.414-1.414z"})],-1)])]),b("button",{onClick:di(a,["prevent"]),class:"w-8 h-8 md:h-10 md:w-10 bg-ag-light-grey hover:bg-white opacity-75 rounded-full flex justify-center lg:mx-5 mx-2 items-center fill-black"},[...o[1]||(o[1]=[b("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24"},[b("path",{d:"M7.293 4.707 14.586 12l-7.293 7.293 1.414 1.414L17.414 12 8.707 3.293 7.293 4.707z"})],-1)])])])):X("",!0),b("div",{class:"relative",id:r.value},[e.images&&e.images.length>1?(k(),Mt(le(D1),{key:0,ref_key:"carousel",ref:t,"wrap-around":!0,transition:600},{default:_t(()=>[(k(!0),M(xe,null,Me(i.value,l=>(k(),Mt(le(R1),{key:l.id},{default:_t(()=>[b("div",{class:"carousel__item relative w-full bg-center bg-cover h-80 md:h-130 xl:h-130",style:Qt(`background-image: url(${l.url});`)},[l.copyright_caption?(k(),M("div",Wce,Q(l.copyright_caption),1)):X("",!0)],4)]),_:2},1024))),128))]),_:1},512)):e.images&&e.images.length>0?(k(),M("div",Zce,[b("div",{class:"bg-center bg-cover h-80 md:h-130 xl:h-130",style:Qt(`background-image: url(${e.images[0].url});`)},null,4),b("div",Kce,Q(e.images[0].copyright_caption),1)])):X("",!0)],8,Yce)]))}},hD=Yt(Xce,[["__scopeId","data-v-8377e96d"]]),Jce={name:"CurrencyDisplay",props:["value","decimal_places"],data(){return this.decimal_places,{selectedCurrency:"USD",rates:{},formattedValue:""}},watch:{value(e){this.formatCurrency(e,this.selectedCurrency)}},mounted(){const e=window.localStorage.getItem("selected_currency");e&&(this.selectedCurrency=e),window.currencyRates?(this.rates=window.currencyRates,this.formatCurrency(this.value,this.selectedCurrency)):console.error("Currency rates not available"),window.addEventListener("currencyUpdated",t=>{this.selectedCurrency=t.detail.message,this.formatCurrency(this.value,this.selectedCurrency)})},methods:{formatCurrency(e,t){if(!this.rates[t])return e;const r=this.rates[t],i=e*r;this.formattedValue=new Intl.NumberFormat("en-US",{style:"currency",currency:t,minimumFractionDigits:this.decimal_places||2,maximumFractionDigits:this.decimal_places||2}).format(i)}}};function Qce(e,t,r,i,n,a){return k(),M("span",null,Q(n.formattedValue),1)}const eg=Yt(Jce,[["render",Qce]]),ede={class:"relative"},tde={class:"safari-carousel-inner"},rde={class:"px-3"},ide=["href"],nde=["src","alt"],ade={class:"absolute top-0 left-0 w-full h-full flex flex-col justify-between w-full h-full p-6 z-50 text-left"},sde={class:"flex-1"},ode={class:"text-white font-primary uppercase text-xs mb-1 leading-none"},lde={class:"text-white font-primary font-bold uppercase text-lg mb-2"},ude={key:0,class:"text-white font-primary text-base mb-4"},cde={__name:"SafariCarousel",props:{cid:{type:String,required:!0},items:{type:Array,required:!0,default:()=>[]}},setup(e){const t=se(),r=()=>{var x;return(x=t.value)==null?void 0:x.next()},i=()=>{var x;return(x=t.value)==null?void 0:x.prev()},n=e,a=se(typeof window<"u"?window.innerWidth:768),s=H(()=>{var x;return((x=n.items)==null?void 0:x.length)??0}),o=H(()=>a.value<480?1:a.value<768?2:3),l=H(()=>s.value>o.value),u=H(()=>l.value),c=H(()=>
49l.value),d=H(()=>l.value?"start":"center"),h=H(()=>Math.min(s.value,o.value));function f(x){const _=Math.min(s.value,x),y=s.value<=x;return{itemsToShow:_,snapAlign:y?"center":"start",wrapAround:!y}}const p=H(()=>({1:f(1),480:f(2),768:f(3)}));function m(){a.value=window.innerWidth}or(()=>{window.addEventListener("resize",m)}),ss(()=>{window.removeEventListener("resize",m)});function g(x){x.currentTarget.classList.add("slick-card-block--hover"),x.currentTarget.querySelector(".button--slick-card")}function v(x){x.currentTarget.classList.remove("slick-card-block--hover"),x.currentTarget.querySelector(".button--slick-card")}return(x,_)=>(k(),M("div",ede,[b("div",tde,[be(le(D1),{ref_key:"carousel",ref:t,"items-to-show":h.value,"wrap-around":c.value,"mouse-drag":l.value,"touch-drag":l.value,transition:500,"snap-align":d.value,breakpoints:p.value,class:pe({"safari-carousel--static":!l.value})},pM({default:_t(()=>[(k(!0),M(xe,null,Me(e.items,(y,w)=>(k(),Mt(le(R1),{key:w},{default:_t(()=>[b("div",rde,[b("a",{href:y.url,class:"slick-card-block h-96 bg-center bg-cover relative",onMouseenter:g,onMouseleave:v},[_[2]||(_[2]=b("div",{class:"slide-gradient"},null,-1)),b("img",{src:y.image,class:"w-full h-full object-cover",alt:y.destination},null,8,nde),b("div",ade,[b("div",sde,[b("p",ode,Q(y.country),1),b("p",lde,Q(y.destination),1)]),b("div",null,[y.hide_pricing?X("",!0):(k(),M("p",ude,[_[0]||(_[0]=Ze(" from ",-1)),be(eg,{value:y.price},null,8,["value"]),Ze(" "+Q(y.price_description),1)])),_[1]||(_[1]=b("div",{class:"button--slick-card"},"Explore",-1))])])],40,ide)])]),_:2},1024))),128))]),_:2},[u.value?{name:"addons",fn:_t(()=>[b("div",{class:"carousel__prev",onClick:i},[..._[3]||(_[3]=[b("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 320 512"},[b("path",{fill:"currentColor",d:"M9.4 233.4c-12.5 12.5-12.5 32.8 0 45.3l192 192c12.5 12.5 32.8 12.5 45.3 0s12.5-32.8 0-45.3L77.3 256 246.6 86.6c12.5-12.5 12.5-32.8 0-45.3s-32.8-12.5-45.3 0l-192 192z"})],-1)])]),b("div",{class:"carousel__next",onClick:r},[..._[4]||(_[4]=[b("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 320 512"},[b("path",{fill:"currentColor",d:"M310.6 233.4c12.5 12.5 12.5 32.8 0 45.3l-192 192c-12.5 12.5-32.8 12.5-45.3 0s-12.5-32.8 0-45.3L242.7 256 73.4 86.6c-12.5-12.5-12.5-32.8 0-45.3s32.8-12.5 45.3 0l192 192z"})],-1)])]),be(le(zce))]),key:"0"}:void 0]),1032,["items-to-show","wrap-around","mouse-drag","touch-drag","snap-align","breakpoints","class"])])]))}},dde=Yt(cde,[["__scopeId","data-v-a21bc214"]]);function fD(e,t){return function(){return e.apply(t,arguments)}}const{toString:hde}=Object.prototype,{getPrototypeOf:W4}=Object,{iterator:O1,toStringTag:pD}=Symbol,L1=(e=>t=>{const r=hde.call(t);return e[r]||(e[r]=r.slice(8,-1).toLowerCase())})(Object.create(null)),Ds=e=>(e=e.toLowerCase(),t=>L1(t)===e),F1=e=>t=>typeof t===e,{isArray:Xh}=Array,bh=F1("undefined");function tg(e){return e!==null&&!bh(e)&&e.constructor!==null&&!bh(e.constructor)&&Wn(e.constructor.isBuffer)&&e.constructor.isBuffer(e)}const mD=Ds("ArrayBuffer");function fde(e){let t;return typeof ArrayBuffer<"u"&&ArrayBuffer.isView?t=ArrayBuffer.isView(e):t=e&&e.buffer&&mD(e.buffer),t}const pde=F1("string"),Wn=F1("function"),gD=F1("number"),rg=e=>e!==null&&typeof e=="object",mde=e=>e===!0||e===!1,K0=e=>{if(L1(e)!=="object")return!1;const t=W4(e);return(t===null||t===Object.prototype||Object.getPrototypeOf(t)===null)&&!(pD in e)&&!(O1 in e)},gde=e=>{if(!rg(e)||tg(e))return!1;try{return Object.keys(e).length===0&&Object.getPrototypeOf(e)===Object.prototype}catch{return!1}},_de=Ds("Date"),yde=Ds("File"),vde=e=>!!(e&&typeof e.uri<"u"),bde=e=>e&&typeof e.getParts<"u",xde=Ds("Blob"),wde=Ds("FileList"),$de=e=>rg(e)&&Wn(e.pipe);function Sde(){return typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:typeof global<"u"?global:{}}const rC=Sde(),iC=typeof rC.FormData<"u"?rC.FormData:void 0,Tde=e=>{let t;return e&&(iC&&e instanceof iC||Wn(e.append)&&((t=L1(e))==="formdata"||t==="object"&&Wn(e.toString)&&e.toString()==="[object FormData]"))},Cde=Ds("URLSearchParams"),[kde,Ede,Pde,Mde]=["ReadableStream","Request","Response","Headers"].map(Ds),Ide=e=>e.trim?e.trim():e.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,"");function ig(e,t,{allOwnKeys:r=!1}={}){if(e===null||typeof e>"u")return;let i,n;if(typeof e!="object"&&(e=[e]),Xh(e))for(i=0,n=e.length;i<n;i++)t.call(null,e[i],i,e);else{if(tg(e))return;const a=r?Object.getOwnPropertyNames(e):Object.keys(e),s=a.length;let o;for(i=0;i<s;i++)o=a[i],t.call(null,e[o],o,e)}}function _D(e,t){if(tg(e))return null;t=t.toLowerCase();const r=Object.keys(e);let i=r.length,n;for(;i-- >0;)if(n=r[i],t===n.toLowerCase())return n;return null}const Nu=typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:global,yD=e=>!bh(e)&&e!==Nu;function sx(){const{caseless:e,skipUndefined:t}=yD(this)&&this||{},r={},i=(n,a)=>
vendor: 23,123 bytes, lines 49-51
49{if(a==="__proto__"||a==="constructor"||a==="prototype")return;const s=e&&_D(r,a)||a;K0(r[s])&&K0(n)?r[s]=sx(r[s],n):K0(n)?r[s]=sx({},n):Xh(n)?r[s]=n.slice():(!t||!bh(n))&&(r[s]=n)};for(let n=0,a=arguments.length;n<a;n++)arguments[n]&&ig(arguments[n],i);return r}const Ade=(e,t,r,{allOwnKeys:i}={})=>(ig(t,(n,a)=>{r&&Wn(n)?Object.defineProperty(e,a,{value:fD(n,r),writable:!0,enumerable:!0,configurable:!0}):Object.defineProperty(e,a,{value:n,writable:!0,enumerable:!0,configurable:!0})},{allOwnKeys:i}),e),Dde=e=>(e.charCodeAt(0)===65279&&(e=e.slice(1)),e),Rde=(e,t,r,i)=>{e.prototype=Object.create(t.prototype,i),Object.defineProperty(e.prototype,"constructor",{value:e,writable:!0,enumerable:!1,configurable:!0}),Object.defineProperty(e,"super",{value:t.prototype}),r&&Object.assign(e.prototype,r)},Ode=(e,t,r,i)=>{let n,a,s;const o={};if(t=t||{},e==null)return t;do{for(n=Object.getOwnPropertyNames(e),a=n.length;a-- >0;)s=n[a],(!i||i(s,e,t))&&!o[s]&&(t[s]=e[s],o[s]=!0);e=r!==!1&&W4(e)}while(e&&(!r||r(e,t))&&e!==Object.prototype);return t},Lde=(e,t,r)=>{e=String(e),(r===void 0||r>e.length)&&(r=e.length),r-=t.length;const i=e.indexOf(t,r);return i!==-1&&i===r},Fde=e=>{if(!e)return null;if(Xh(e))return e;let t=e.length;if(!gD(t))return null;const r=new Array(t);for(;t-- >0;)r[t]=e[t];return r},zde=(e=>t=>e&&t instanceof e)(typeof Uint8Array<"u"&&W4(Uint8Array)),Nde=(e,t)=>{const i=(e&&e[O1]).call(e);let n;for(;(n=i.next())&&!n.done;){const a=n.value;t.call(e,a[0],a[1])}},Bde=(e,t)=>{let r;const i=[];for(;(r=e.exec(t))!==null;)i.push(r);return i},jde=Ds("HTMLFormElement"),Ude=e=>e.toLowerCase().replace(/[-_\s]([a-z\d])(\w*)/g,function(r,i,n){return i.toUpperCase()+n}),nC=(({hasOwnProperty:e})=>(t,r)=>e.call(t,r))(Object.prototype),Vde=Ds("RegExp"),vD=(e,t)=>{const r=Object.getOwnPropertyDescriptors(e),i={};ig(r,(n,a)=>{let s;(s=t(n,a,e))!==!1&&(i[a]=s||n)}),Object.defineProperties(e,i)},qde=e=>{vD(e,(t,r)=>{if(Wn(e)&&["arguments","caller","callee"].indexOf(r)!==-1)return!1;const i=e[r];if(Wn(i)){if(t.enumerable=!1,"writable"in t){t.writable=!1;return}t.set||(t.set=()=>{throw Error("Can not rewrite read-only method '"+r+"'")})}})},Gde=(e,t)=>{const r={},i=n=>{n.forEach(a=>{r[a]=!0})};return Xh(e)?i(e):i(String(e).split(t)),r},Hde=()=>{},Yde=(e,t)=>e!=null&&Number.isFinite(e=+e)?e:t;function Wde(e){return!!(e&&Wn(e.append)&&e[pD]==="FormData"&&e[O1])}const Zde=e=>{const t=new Array(10),r=(i,n)=>{if(rg(i)){if(t.indexOf(i)>=0)return;if(tg(i))return i;if(!("toJSON"in i)){t[n]=i;const a=Xh(i)?[]:{};return ig(i,(s,o)=>{const l=r(s,n+1);!bh(l)&&(a[o]=l)}),t[n]=void 0,a}}return i};return r(e,0)},Kde=Ds("AsyncFunction"),Xde=e=>e&&(rg(e)||Wn(e))&&Wn(e.then)&&Wn(e.catch),bD=((e,t)=>e?setImmediate:t?((r,i)=>(Nu.addEventListener("message",({source:n,data:a})=>{n===Nu&&a===r&&i.length&&i.shift()()},!1),n=>{i.push(n),Nu.postMessage(r,"*")}))(`axios@${Math.random()}`,[]):r=>setTimeout(r))(typeof setImmediate=="function",Wn(Nu.postMessage)),Jde=typeof queueMicrotask<"u"?queueMicrotask.bind(Nu):typeof process<"u"&&process.nextTick||bD,Qde=e=>e!=null&&Wn(e[O1]),he={isArray:Xh,isArrayBuffer:mD,isBuffer:tg,isFormData:Tde,isArrayBufferView:fde,isString:pde,isNumber:gD,isBoolean:mde,isObject:rg,isPlainObject:K0,isEmptyObject:gde,isReadableStream:kde,isRequest:Ede,isResponse:Pde,isHeaders:Mde,isUndefined:bh,isDate:_de,isFile:yde,isReactNativeBlob:vde,isReactNative:bde,isBlob:xde,isRegExp:Vde,isFunction:Wn,isStream:$de,isURLSearchParams:Cde,isTypedArray:zde,isFileList:wde,forEach:ig,merge:sx,extend:Ade,trim:Ide,stripBOM:Dde,inherits:Rde,toFlatObject:Ode,kindOf:L1,kindOfTest:Ds,endsWith:Lde,toArray:Fde,forEachEntry:Nde,matchAll:Bde,isHTMLForm:jde,hasOwnProperty:nC,hasOwnProp:nC,reduceDescriptors:vD,freezeMethods:qde,toObjectSet:Gde,toCamelCase:Ude,noop:Hde,toFiniteNumber:Yde,findKey:_D,global:Nu,isContextDefined:yD,isSpecCompliantForm:Wde,toJSONObject:Zde,isAsyncFn:Kde,isThenable:Xde,setImmediate:bD,asap:Jde,isIterable:Qde};let lt=class xD extends Error{static from(t,r,i,n,a,s){const o=new xD(t.message,r||t.code,i,n,a);return o.cause=t,o.name=t.name,t.status!=null&&o.status==null&&(o.status=t.status),s&&Object.assign(o,s),o}constructor(t,r,i,n,a){super(t),Object.defineProperty(this,"message",{value:t,enumerable:!0,writable:!0,configurable:!0}),this.name="AxiosError",this.isAxiosError=!0,r&&(this.code=r),i&&(this.config=i),n&&(this.request=n),a&&(this.response=a,this.status=a.status)}toJSON(){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:he.toJSONObject(this.config),code:this.code,status:this.status}}};lt.ERR_BAD_OPTION_VALUE="ERR_BAD_OPTION_VALUE";lt.ERR_BAD_OPTION="ERR_BAD_OPTION";lt.ECONNABORTED="ECONNABORTED";lt.ETIMEDOUT="ETIMEDOUT";lt.ERR_NETWORK="ERR_NETWORK";lt.ERR_FR_TOO_MANY_REDIRECTS="ERR_FR_TOO_MANY_REDIRECTS";lt.ERR_DEPRECATED="ERR_DEPRECATED";lt.ERR_BAD_RESPONSE="ERR_BAD_RESPONSE";lt.ERR_BAD_REQUEST="ERR_BAD_REQUEST";lt.ERR_CANCELED="ERR_CANCELED";lt.ERR_NOT_SUPPORT="ERR_NOT_SUPPORT";lt.ERR_INVALID_URL="ERR_INVALID_URL";const ehe=null;function ox(e){return he.isPlainObject(e)||he.isArray(e)}function wD(e){return he.endsWith(e,"[]")?e.slice(0,-2):e}function Kv(e,t,r){return e?e.concat(t).map(function(n,a){return n=wD(n),!r&&a?"["+n+"]":n}).join(r?".":""):t}function the(e){return he.isArray(e)&&!e.some(ox)}const rhe=he.toFlatObject(he,{},null,function(t){return/^is[A-Z]/.test(t)});function z1(e,t,r){if(!he.isObject(e))throw new TypeError("target must be an object");t=t||new FormData,r=he.toFlatObject(r,{metaTokens:!0,dots:!1,indexes:!1},!1,function(m,g){return!he.isUndefined(g[m])});const i=r.metaTokens,n=r.visitor||c,a=r.dots,s=r.indexes,l=(r.Blob||typeof Blob<"u"&&Blob)&&he.isSpecCompliantForm(t);if(!he.isFunction(n))throw new TypeError("visitor must be a function");function u(p){if(p===null)return"";if(he.isDate(p))return p.toISOString();if(he.isBoolean(p))return p.toString();if(!l&&he.isBlob(p))throw new lt("Blob is not supported. Use a Buffer instead.");return he.isArrayBuffer(p)||he.isTypedArray(p)?l&&typeof Blob=="function"?new Blob([p]):Buffer.from(p):p}function c(p,m,g){let v=p;if(he.isReactNative(t)&&he.isReactNativeBlob(p))return t.append(Kv(g,m,a),u(p)),!1;if(p&&!g&&typeof p=="object"){if(he.endsWith(m,"{}"))m=i?m:m.slice(0,-2),p=JSON.stringify(p);else if(he.isArray(p)&&the(p)||(he.isFileList(p)||he.endsWith(m,"[]"))&&(v=he.toArray(p)))return m=wD(m),v.forEach(function(_,y){!(he.isUndefined(_)||_===null)&&t.append(s===!0?Kv([m],y,a):s===null?m:m+"[]",u(_))}),!1}return ox(p)?!0:(t.append(Kv(g,m,a),u(p)),!1)}const d=[],h=Object.assign(rhe,{defaultVisitor:c,convertValue:u,isVisitable:ox});function f(p,m){if(!he.isUndefined(p)){if(d.indexOf(p)!==-1)throw Error("Circular reference detected in "+m.join("."));d.push(p),he.forEach(p,function(v,x){(!(he.isUndefined(v)||v===null)&&n.call(t,v,he.isString(x)?x.trim():x,m,h))===!0&&f(v,m?m.concat(x):[x])}),d.pop()}}if(!he.isObject(e))throw new TypeError("data must be an object");return f(e),t}function aC(e){const t={"!":"%21","'":"%27","(":"%28",")":"%29","~":"%7E","%20":"+","%00":"\0"};return encodeURIComponent(e).replace(/[!'()~]|%20|%00/g,function(i){return t[i]})}function Z4(e,t){this._pairs=[],e&&z1(e,this,t)}const $D=Z4.prototype;$D.append=function(t,r){this._pairs.push([t,r])};$D.toString=function(t){const r=t?function(i){return t.call(this,i,aC)}:aC;return this._pairs.map(function(n){return r(n[0])+"="+r(n[1])},"").join("&")};function ihe(e){return encodeURIComponent(e).replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%20/g,"+")}function SD(e,t,r){if(!t)return e;const i=r&&r.encode||ihe,n=he.isFunction(r)?{serialize:r}:r,a=n&&n.serialize;let s;if(a?s=a(t,n):s=he.isURLSearchParams(t)?t.toString():new Z4(t,n).toString(i),s){const o=e.indexOf("#");o!==-1&&(e=e.slice(0,o)),e+=(e.indexOf("?")===-1?"?":"&")+s}return e}class sC{constructor(){this.handlers=[]}use(t,r,i){return this.handlers.push({fulfilled:t,rejected:r,synchronous:i?i.synchronous:!1,runWhen:i?i.runWhen:null}),this.handlers.length-1}eject(t){this.handlers[t]&&(this.handlers[t]=null)}clear(){this.handlers&&(this.handlers=[])}forEach(t){he.forEach(this.handlers,function(i){i!==null&&t(i)})}}const K4={silentJSONParsing:!0,forcedJSONParsing:!0,clarifyTimeoutError:!1,legacyInterceptorReqResOrdering:!0},nhe=typeof URLSearchParams<"u"?URLSearchParams:Z4,ahe=typeof FormData<"u"?FormData:null,she=typeof Blob<"u"?Blob:null,ohe={isBrowser:!0,classes:{URLSearchParams:nhe,FormData:ahe,Blob:she},protocols:["http","https","file","blob","url","data"]},X4=typeof window<"u"&&typeof document<"u",lx=typeof navigator=="object"&&navigator||void 0,lhe=X4&&(!lx||["ReactNative","NativeScript","NS"].indexOf(lx.product)<0),uhe=typeof WorkerGlobalScope<"u"&&self instanceof WorkerGlobalScope&&typeof self.importScripts=="function",che=X4&&window.location.href||"http://localhost",dhe=Object.freeze(Object.defineProperty({__proto__:null,hasBrowserEnv:X4,hasStandardBrowserEnv:lhe,hasStandardBrowserWebWorkerEnv:uhe,navigator:lx,origin:che},Symbol.toStringTag,{value:"Module"})),sn={...dhe,...ohe};function hhe(e,t){return z1(e,new sn.classes.URLSearchParams,{visitor:function(r,i,n,a){return sn.isNode&&he.isBuffer(r)?(this.append(i,r.toString("base64")),!1):a.defaultVisitor.apply(this,arguments)},...t})}function fhe(e){return he.matchAll(/\w+|\[(\w*)]/g,e).map(t=>t[0]==="[]"?"":t[1]||t[0])}function phe(e){const t={},r=Object.keys(e);let i;const n=r.length;let a;for(i=0;i<n;i++)a=r[i],t[a]=e[a];return t}function TD(e){function t(r,i,n,a){let s=r[a++];if(s==="__proto__")return!0;const o=Number.isFinite(+s),l=a>=r.length;return s=!s&&he.isArray(n)?n.length:s,l?(he.hasOwnProp(n,s)?n[s]=[n[s],i]:n[s]=i,!o):((!n[s]||!he.isObject(n[s]))&&(n[s]=[]),t(r,i,n[s],a)&&he.isArray(n[s])&&(n[s]=phe(n[s])),!o)}if(he.isFormData(e)&&he.isFunction(e.entries)){const r={};return he.forEachEntry(e,(i,n)=>{t(fhe(i),n,r,0)}),r}return null}function mhe(e,t,r){if(he.isString(e))try{return(t||JSON.parse)(e),he.trim(e)}catch(i){if(i.name!=="SyntaxError")throw i}return(r||JSON.stringify)(e)}const ng={transitional:K4,adapter:["xhr","http","fetch"],transformRequest:[function(t,r){const i=r.getContentType()||"",n=i.indexOf("application/json")>-1,a=he.isObject(t);if(a&&he.isHTMLForm(t)&&(t=new FormData(t)),he.isFormData(t))return n?JSON.stringify(TD(t)):t;if(he.isArrayBuffer(t)||he.isBuffer(t)||he.isStream(t)||he.isFile(t)||he.isBlob(t)||he.isReadableStream(t))return t;if(he.isArrayBufferView(t))return t.buffer;if(he.isURLSearchParams(t))return r.setContentType("application/x-www-form-urlencoded;charset=utf-8",!1),t.toString();let o;if(a){if(i.indexOf("application/x-www-form-urlencoded")>-1)return hhe(t,this.formSerializer).toString();if((o=he.isFileList(t))||i.indexOf("multipart/form-data")>-1){const l=this.env&&this.env.FormData;return z1(o?{"files[]":t}:t,l&&new l,this.formSerializer)}}return a||n?(r.setContentType("application/json",!1),mhe(t)):t}],transformResponse:[function(t){const r=this.transitional||ng.transitional,i=r&&r.forcedJSONParsing,n=this.responseType==="json";if(he.isResponse(t)||he.isReadableStream(t))return t;if(t&&he.isString(t)&&(i&&!this.responseType||n)){const s=!(r&&r.silentJSONParsing)&&n;try{return JSON.parse(t,this.parseReviver)}catch(o){if(s)throw o.name==="SyntaxError"?lt.from(o,lt.ERR_BAD_RESPONSE,this,null,this.response):o}}return t}],timeout:0,xsrfCookieName:"XSRF-TOKEN",xsrfHeaderName:"X-XSRF-TOKEN",maxContentLength:-1,maxBodyLength:-1,env:{FormData:sn.classes.FormData,Blob:sn.classes.Blob},validateStatus:function(t){return t>=200&&t<300},headers:{common:{Accept:"application/json, text/plain, */*","Content-Type":void 0}}};he.forEach(["delete","get","head","post","put","patch"],e=>{ng.headers[e]={}});const ghe=he.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"]),_he=e=>{const t={};let r,i,n;return e&&e.split(` 50`).forEach(function(s){n=s.indexOf(":"),r=s.substring(0,n).trim().toLowerCase(),i=s.substring(n+1).trim(),!(!r||t[r]&&ghe[r])&&(r==="set-cookie"?t[r]?t[r].push(i):t[r]=[i]:t[r]=t[r]?t[r]+", "+i:i)}),t},oC=Symbol("internals");function vf(e){return e&&String(e).trim().toLowerCase()}function X0(e){return e===!1||e==null?e:he.isArray(e)?e.map(X0):String(e)}function yhe(e){const t=Object.create(null),r=/([^\s,;=]+)\s*(?:=\s*([^,;]+))?/g;let i;for(;i=r.exec(e);)t[i[1]]=i[2];return t}const vhe=e=>/^[-_a-zA-Z0-9^`|~,!#$%&'*+.]+$/.test(e.trim());function Xv(e,t,r,i,n){if(he.isFunction(i))return i.call(this,t,r);if(n&&(t=r),!!he.isString(t)){if(he.isString(i))return t.indexOf(i)!==-1;if(he.isRegExp(i))return i.test(t)}}function bhe(e){return e.trim().toLowerCase().replace(/([a-z\d])(\w*)/g,(t,r,i)=>r.toUpperCase()+i)}function xhe(e,t){const r=he.toCamelCase(" "+t);["get","set","has"].forEach(i=>{Object.defineProperty(e,i+r,{value:function(n,a,s){return this[i].call(this,t,n,a,s)},configurable:!0})})}let Zn=class{constructor(t){t&&this.set(t)}set(t,r,i){const n=this;function a(o,l,u){const c=vf(l);if(!c)throw new Error("header name must be a non-empty string");const d=he.findKey(n,c);(!d||n[d]===void 0||u===!0||u===void 0&&n[d]!==!1)&&(n[d||l]=X0(o))}const s=(o,l)=>he.forEach(o,(u,c)=>a(u,c,l));if(he.isPlainObject(t)||t instanceof this.constructor)s(t,r);else if(he.isString(t)&&(t=t.trim())&&!vhe(t))s(_he(t),r);else if(he.isObject(t)&&he.isIterable(t)){let o={},l,u;for(const c of t){if(!he.isArray(c))throw TypeError("Object iterator must return a key-value pair");o[u=c[0]]=(l=o[u])?he.isArray(l)?[...l,c[1]]:[l,c[1]]:c[1]}s(o,r)}else t!=null&&a(r,t,i);return this}get(t,r){if(t=vf(t),t){const i=he.findKey(this,t);if(i){const n=this[i];if(!r)return n;if(r===!0)return yhe(n);if(he.isFunction(r))return r.call(this,n,i);if(he.isRegExp(r))return r.exec(n);throw new TypeError("parser must be boolean|regexp|function")}}}has(t,r){if(t=vf(t),t){const i=he.findKey(this,t);return!!(i&&this[i]!==void 0&&(!r||Xv(this,this[i],i,r)))}return!1}delete(t,r){const i=this;let n=!1;function a(s){if(s=vf(s),s){const o=he.findKey(i,s);o&&(!r||Xv(i,i[o],o,r))&&(delete i[o],n=!0)}}return he.isArray(t)?t.forEach(a):a(t),n}clear(t){const r=Object.keys(this);let i=r.length,n=!1;for(;i--;){const a=r[i];(!t||Xv(this,this[a],a,t,!0))&&(delete this[a],n=!0)}return n}normalize(t){const r=this,i={};return he.forEach(this,(n,a)=>{const s=he.findKey(i,a);if(s){r[s]=X0(n),delete r[a];return}const o=t?bhe(a):String(a).trim();o!==a&&delete r[a],r[o]=X0(n),i[o]=!0}),this}concat(...t){return this.constructor.concat(this,...t)}toJSON(t){const r=Object.create(null);return he.forEach(this,(i,n)=>{i!=null&&i!==!1&&(r[n]=t&&he.isArray(i)?i.join(", "):i)}),r}[Symbol.iterator](){return Object.entries(this.toJSON())[Symbol.iterator]()}toString(){return Object.entries(this.toJSON()).map(([t,r])=>t+": "+r).join(` 51`)}getSetCookie(){return this.get("set-cookie")||[]}get[Symbol.toStringTag](){return"AxiosHeaders"}static from(t){return t instanceof this?t:new this(t)}static concat(t,...r){const i=new this(t);return r.forEach(n=>i.set(n)),i}static accessor(t){const i=(this[oC]=this[oC]={accessors:{}}).accessors,n=this.prototype;function a(s){const o=vf(s);i[o]||(xhe(n,s),i[o]=!0)}return he.isArray(t)?t.forEach(a):a(t),this}};Zn.accessor(["Content-Type","Content-Length","Accept","Accept-Encoding","User-Agent","Authorization"]);he.reduceDescriptors(Zn.prototype,({value:e},t)=>{let r=t[0].toUpperCase()+t.slice(1);return{get:()=>e,set(i){this[r]=i}}});he.freezeMethods(Zn);function Jv(e,t){const r=this||ng,i=t||r,n=Zn.from(i.headers);let a=i.data;return he.forEach(e,function(o){a=o.call(r,a,n.normalize(),t?t.status:void 0)}),n.normalize(),a}function CD(e){return!!(e&&e.__CANCEL__)}let ag=class extends lt{constructor(t,r,i){super(t??"canceled",lt.ERR_CANCELED,r,i),this.name="CanceledError",this.__CANCEL__=!0}};function kD(e,t,r){const i=r.config.validateStatus;!r.status||!i||i(r.status)?e(r):t(new lt("Request failed with status code "+r.status,[lt.ERR_BAD_REQUEST,lt.ERR_BAD_RESPONSE][Math.floor(r.status/100)-4],r.config,r.request,r))}function whe(e){const t=/^([-+\w]{1,25})(:?\/\/|:)/.exec(e);return t&&t[1]||""}function $he(e,t){e=e||10;const r=new Array(e),i=new Array(e);let n=0,a=0,s;return t=t!==void 0?t:1e3,function(l){const u=Date.now(),c=i[a];s||(s=u),r[n]=l,i[n]=u;let d=a,h=0;for(;d!==n;)h+=r[d++],d=d%e;if(n=(n+1)%e,n===a&&(a=(a+1)%e),u-s<t)return;const f=c&&u-c;return f?Math.round(h*1e3/f):void 0}}function She(e,t){let r=0,i=1e3/t,n,a;const s=(u,c=Date.now())=>{r=c,n=null,a&&(clearTimeout(a),a=null),e(...u)};return[(...u)=>{const c=Date.now(),d=c-r;d>=i?s(u,c):(n=u,a||(a=setTimeout(()=>{a=null,s(n)},i-d)))},()=>n&&s(n)]}const ly=(e,t,r=3)=>{let i=0;const n=$he(50,250);return She(a=>{const s=a.loaded,o=a.lengthComputable?a.total:void 0,l=s-i,u=n(l),c=s<=o;i=s;const d={loaded:s,total:o,progress:o?s/o:void 0,bytes:l,rate:u||void 0,estimated:u&&o&&c?(o-s)/u:void 0,event:a,lengthComputable:o!=null,[t?"download":"upload"]:!0};e(d)},r)},lC=(e,t)=>{const r=e!=null;return[i=>t[0]({lengthComputable:r,total:e,loaded:i}),t[1]]},uC=e=>(...t)=>he.asap(()=>e(...t)),The=sn.hasStandardBrowserEnv?((e,t)=>r=>(r=new URL(r,sn.origin),e.protocol===r.protocol&&e.host===r.host&&(t||e.port===r.port)))(new URL(sn.origin),sn.navigator&&/(msie|trident)/i.test(sn.navigator.userAgent)):()=>!0,Che=sn.hasStandardBrowserEnv?{write(e,t,r,i,n,a,s){if(typeof document>"u")return;const o=[`${e}=${encodeURIComponent(t)}`];he.isNumber(r)&&o.push(`expires=${new Date(r).toUTCString()}`),he.isString(i)&&o.push(`path=${i}`),he.isString(n)&&o.push(`domain=${n}`),a===!0&&o.push("secure"),he.isString(s)&&o.push(`SameSite=${s}`),document.cookie=o.join("; ")},read(e){if(typeof document>"u")return null;const t=document.cookie.match(new RegExp("(?:^|; )"+e+"=([^;]*)"));return t?decodeURIComponent(t[1]):null},remove(e){this.write(e,"",Date.now()-864e5,"/")}}:{write(){},read(){return null},remove(){}};function khe(e){return typeof e!="string"?!1:/^([a-z][a-z\d+\-.]*:)?\/\//i.test(e)}function Ehe(e,t){return t?e.replace(/\/?\/$/,"")+"/"+t.replace(/^\/+/,""):e}function ED(e,t,r){let i=!khe(t);return e&&(i||r==!1)?Ehe(e,t):t}const cC=e=>e instanceof Zn?{...e}:e;function xc(e,t){t=t||{};const r={};function i(u,c,d,h){return he.isPlainObject(u)&&he.isPlainObject(c)?he.merge.call({caseless:h},u,c):he.isPlainObject(c)?he.merge({},c):he.isArray(c)?c.slice():c}function n(u,c,d,h){if(he.isUndefined(c)){if(!he.isUndefined(u))return i(void 0,u,d,h)}else return i(u,c,d,h)}function a(u,c){if(!he.isUndefined(c))return i(void 0,c)}function s(u,c){if(he.isUndefined(c)){if(!he.isUndefined(u))return i(void 0,u)}else return i(void 0,c)}function o(u,c,d){if(d in t)return i(u,c);if(d in e)return i(void 0,u)}const l={url:a,method:a,data:a,baseURL:s,transformRequest:s,transformResponse:s,paramsSerializer:s,timeout:s,timeoutMessage:s,withCredentials:s,withXSRFToken:s,adapter:s,responseType:s,xsrfCookieName:s,xsrfHeaderName:s,onUploadProgress:s,onDownloadProgress:s,decompress:s,maxContentLength:s,maxBodyLength:s,beforeRedirect:s,transport:s,httpAgent:s,httpsAgent:s,cancelToken:s,socketPath:s,responseEncoding:s,validateStatus:o,headers:(u,c,d)=>n(cC(u),cC(c),d,!0)};return he.forEach(Object.keys({...e,...t}),function(c){if(c==="__proto__"||c==="constructor"||c==="prototype")return;const d=he.hasOwnProp(l,c)?l[c]:n,h=d(e[c],t[c],c);he.isUndefined(h)&&d!==o||(r[c]=h)}),r}const PD=e=>{const t=xc({},e);let{data:r,withXSRFToken:i,xsrfHeaderName:n,xsrfCookieName:a,headers:s,auth:o}=t;if(t.headers=s=Zn.from(s),t.url=SD(ED(t.baseURL,t.url,t.allowAbsoluteUrls),e.params,e.paramsSerializer),o&&s.set("Authorization","Basic "+btoa((o.username||"")+":"+(o.password?unescape(encodeURIComponent(o.password)):""))),he.isFormData(r)){if(sn.hasStandardBrowserEnv||sn.hasStandardBrowserWebWorkerEnv)s.setContentType(void 0);else if(he.isFunction(r.getHeaders)){const l=r.getHeaders(),u=["content-type","content-length"];Object.entries(l).forEach(([c,d])=>{u.includes(c.toLowerCase())&&s.set(c,d)})}}if(sn.hasStandardBrowserEnv&&(i&&he.isFunction(i)&&(i=i(t)),i||i!==!1&&The(t.url))){const l=n&&a&&Che.read(a);l&&s.set(n,l)}return t},Phe=typeof XMLHttpRequest<"u",Mhe=Phe&&function(e){return new Promise(function(r,i){const n=PD(e);let a=n.data;const s=Zn.from(n.headers).normalize();let{responseType:o,onUploadProgress:l,onDownloadProgress:u}=n,c,d,h,f,p;function m(){f&&f(),p&&p(),n.cancelToken&&n.cancelToken.unsubscribe(c),n.signal&&n.signal.removeEventListener("abort",c)}let g=new XMLHttpRequest;g.open(n.method.toUpperCase(),n.url,!0),g.timeout=n.timeout;function v(){if(!g)return;const _=Zn.from("getAllResponseHeaders"in g&&g.getAllResponseHeaders()),w={data:!o||o==="text"||o==="json"?g.responseText:g.response,status:g.status,statusText:g.statusText,headers:_,config:e,request:g};kD(function(S){r(S),m()},function(S){i(S),m()},w),g=null}"onloadend"in g?g.onloadend=v:g.onreadystatechange=function(){!g||g.readyState!==4||g.status===0&&!(g.responseURL&&g.responseURL.indexOf("file:")===0)||setTimeout(v)},g.onabort=function(){g&&(i(new lt("Request aborted",lt.ECONNABORTED,e,g)),g=null)},g.onerror=function(y){const w=y&&y.message?y.message:"Network Error",$=new lt(w,lt.ERR_NETWORK,e,g);$.event=y||null,i($),g=null},g.ontimeout=function(){let y=n.timeout?"timeout of "+n.timeout+"ms exceeded":"timeout exceeded";const w=n.transitional||K4;n.timeoutErrorMessage&&(y=n.timeoutErrorMessage),i(new lt(y,w.clarifyTimeoutError?lt.ETIMEDOUT:lt.ECONNABORTED,e,g)),g=null},a===void 0&&s.setContentType(null),"setRequestHeader"in g&&he.forEach(s.toJSON(),function(y,w){g.setRequestHeader(w,y)}),he.isUndefined(n.withCredentials)||(g.withCredentials=!!n.withCredentials),o&&o!=="json"&&(g.responseType=n.responseType),u&&([h,p]=ly(u,!0),g.addEventListener("progress",h)),l&&g.upload&&([d,f]=ly(l),g.upload.addEventListener("progress",d),g.upload.addEventListener("loadend",f)),(n.cancelToken||n.signal)&&(c=_=>{g&&(i(!_||_.type?new ag(null,e,g):_),g.abort(),g=null)},n.cancelToken&&n.cancelToken.subscribe(c),n.signal&&(n.signal.aborted?c():n.signal.addEventListener("abort",c)));const x=whe(n.url);if(x&&sn.protocols.indexOf(x)===-1){i(new lt("Unsupported protocol "+x+":",lt.ERR_BAD_REQUEST,e));return}g.send(a||null)})},Ihe=(e,t)=>{const{length:r}=e=e?e.filter(Boolean):[];if(t||r){let i=new AbortController,n;const a=function(u){if(!n){n=!0,o();const c=u instanceof Error?u:this.reason;i.abort(c instanceof lt?c:new ag(c instanceof Error?c.message:c))}};let s=t&&setTimeout(()=>{s=null,a(new lt(`timeout of ${t}ms exceeded`,lt.ETIMEDOUT))},t);const o=()=>{e&&(s&&clearTimeout(s),s=null,e.forEach(u=>{u.unsubscribe?u.unsubscribe(a):u.removeEventListener("abort",a)}),e=null)};e.forEach(u=>u.addEventListener("abort",a));const{signal:l}=i;return l.unsubscribe=()=>he.asap(o),l}},Ahe=function*(e,t){let r=e.byteLength;if(r<t){yield e;return}let i=0,n;for(;i<r;)n=i+t,yield e.slice(i,n),i=n}
vendor: 4,466 bytes, lines 51-53
51,Dhe=async function*(e,t){for await(const r of Rhe(e))yield*Ahe(r,t)},Rhe=async function*(e){if(e[Symbol.asyncIterator]){yield*e;return}const t=e.getReader();try{for(;;){const{done:r,value:i}=await t.read();if(r)break;yield i}}finally{await t.cancel()}},dC=(e,t,r,i)=>{const n=Dhe(e,t);let a=0,s,o=l=>{s||(s=!0,i&&i(l))};return new ReadableStream({async pull(l){try{const{done:u,value:c}=await n.next();if(u){o(),l.close();return}let d=c.byteLength;if(r){let h=a+=d;r(h)}l.enqueue(new Uint8Array(c))}catch(u){throw o(u),u}},cancel(l){return o(l),n.return()}},{highWaterMark:2})},hC=64*1024,{isFunction:Yg}=he,Ohe=(({Request:e,Response:t})=>({Request:e,Response:t}))(he.global),{ReadableStream:fC,TextEncoder:pC}=he.global,mC=(e,...t)=>{try{return!!e(...t)}catch{return!1}},Lhe=e=>{e=he.merge.call({skipUndefined:!0},Ohe,e);const{fetch:t,Request:r,Response:i}=e,n=t?Yg(t):typeof fetch=="function",a=Yg(r),s=Yg(i);if(!n)return!1;const o=n&&Yg(fC),l=n&&(typeof pC=="function"?(p=>m=>p.encode(m))(new pC):async p=>new Uint8Array(await new r(p).arrayBuffer())),u=a&&o&&mC(()=>{let p=!1;const m=new r(sn.origin,{body:new fC,method:"POST",get duplex(){return p=!0,"half"}}).headers.has("Content-Type");return p&&!m}),c=s&&o&&mC(()=>he.isReadableStream(new i("").body)),d={stream:c&&(p=>p.body)};n&&["text","arrayBuffer","blob","formData","stream"].forEach(p=>{!d[p]&&(d[p]=(m,g)=>{let v=m&&m[p];if(v)return v.call(m);throw new lt(`Response type '${p}' is not supported`,lt.ERR_NOT_SUPPORT,g)})});const h=async p=>{if(p==null)return 0;if(he.isBlob(p))return p.size;if(he.isSpecCompliantForm(p))return(await new r(sn.origin,{method:"POST",body:p}).arrayBuffer()).byteLength;if(he.isArrayBufferView(p)||he.isArrayBuffer(p))return p.byteLength;if(he.isURLSearchParams(p)&&(p=p+""),he.isString(p))return(await l(p)).byteLength},f=async(p,m)=>{const g=he.toFiniteNumber(p.getContentLength());return g??h(m)};return async p=>{let{url:m,method:g,data:v,signal:x,cancelToken:_,timeout:y,onDownloadProgress:w,onUploadProgress:$,responseType:S,headers:E,withCredentials:C="same-origin",fetchOptions:I}=PD(p),P=t||fetch;S=S?(S+"").toLowerCase():"text";let T=Ihe([x,_&&_.toAbortSignal()],y),D=null;const A=T&&T.unsubscribe&&(()=>{T.unsubscribe()});let z;try{if($&&u&&g!=="get"&&g!=="head"&&(z=await f(E,v))!==0){let ae=new r(m,{method:"POST",body:v,duplex:"half"}),ue;if(he.isFormData(v)&&(ue=ae.headers.get("content-type"))&&E.setContentType(ue),ae.body){const[Z,K]=lC(z,ly(uC($)));v=dC(ae.body,hC,Z,K)}}he.isString(C)||(C=C?"include":"omit");const R=a&&"credentials"in r.prototype,O={...I,signal:T,method:g.toUpperCase(),headers:E.normalize().toJSON(),body:v,duplex:"half",credentials:R?C:void 0};D=a&&new r(m,O);let V=await(a?P(D,I):P(m,O));const Y=c&&(S==="stream"||S==="response");if(c&&(w||Y&&A)){const ae={};["status","statusText","headers"].forEach(fe=>{ae[fe]=V[fe]});const ue=he.toFiniteNumber(V.headers.get("content-length")),[Z,K]=w&&lC(ue,ly(uC(w),!0))||[];V=new i(dC(V.body,hC,Z,()=>{K&&K(),A&&A()}),ae)}S=S||"text";let F=await d[he.findKey(d,S)||"text"](V,p);return!Y&&A&&A(),await new Promise((ae,ue)=>{kD(ae,ue,{data:F,headers:Zn.from(V.headers),status:V.status,statusText:V.statusText,config:p,request:D})})}catch(R){throw A&&A(),R&&R.name==="TypeError"&&/Load failed|fetch/i.test(R.message)?Object.assign(new lt("Network Error",lt.ERR_NETWORK,p,D,R&&R.response),{cause:R.cause||R}):lt.from(R,R&&R.code,p,D,R&&R.response)}}},Fhe=new Map,MD=e=>{let t=e&&e.env||{};const{fetch:r,Request:i,Response:n}=t,a=[i,n,r];let s=a.length,o=s,l,u,c=Fhe;for(;o--;)l=a[o],u=c.get(l),u===void 0&&c.set(l,u=o?new Map:Lhe(t)),c=u;return u};MD();const J4={http:ehe,xhr:Mhe,fetch:{get:MD}};he.forEach(J4,(e,t)=>{if(e){try{Object.defineProperty(e,"name",{value:t})}catch{}Object.defineProperty(e,"adapterName",{value:t})}});const gC=e=>`- ${e}`,zhe=e=>he.isFunction(e)||e===null||e===!1;function Nhe(e,t){e=he.isArray(e)?e:[e];const{length:r}=e;let i,n;const a={};for(let s=0;s<r;s++){i=e[s];let o;if(n=i,!zhe(i)&&(n=J4[(o=String(i)).toLowerCase()],n===void 0))throw new lt(`Unknown adapter '${o}'`);if(n&&(he.isFunction(n)||(n=n.get(t))))break;a[o||"#"+s]=n}if(!n){const s=Object.entries(a).map(([l,u])=>`adapter ${l} `+(u===!1?"is not supported by the environment":"is not available in the build"));let o=r?s.length>1?`since : 52`+s.map(gC).join(` 53`):" "+gC(s[0]):"as no adapter specified";throw new lt("There is no suitable adapter to dispatch the request "+o,"ERR_NOT_SUPPORT")}return n}
vendor: 1,712 bytes, line 53
53const ID={getAdapter:Nhe,adapters:J4};function Qv(e){if(e.cancelToken&&e.cancelToken.throwIfRequested(),e.signal&&e.signal.aborted)throw new ag(null,e)}function _C(e){return Qv(e),e.headers=Zn.from(e.headers),e.data=Jv.call(e,e.transformRequest),["post","put","patch"].indexOf(e.method)!==-1&&e.headers.setContentType("application/x-www-form-urlencoded",!1),ID.getAdapter(e.adapter||ng.adapter,e)(e).then(function(i){return Qv(e),i.data=Jv.call(e,e.transformResponse,i),i.headers=Zn.from(i.headers),i},function(i){return CD(i)||(Qv(e),i&&i.response&&(i.response.data=Jv.call(e,e.transformResponse,i.response),i.response.headers=Zn.from(i.response.headers))),Promise.reject(i)})}const AD="1.13.6",N1={};["object","boolean","number","function","string","symbol"].forEach((e,t)=>{N1[e]=function(i){return typeof i===e||"a"+(t<1?"n ":" ")+e}});const yC={};N1.transitional=function(t,r,i){function n(a,s){return"[Axios v"+AD+"] Transitional option '"+a+"'"+s+(i?". "+i:"")}return(a,s,o)=>{if(t===!1)throw new lt(n(s," has been removed"+(r?" in "+r:"")),lt.ERR_DEPRECATED);return r&&!yC[s]&&(yC[s]=!0,console.warn(n(s," has been deprecated since v"+r+" and will be removed in the near future"))),t?t(a,s,o):!0}};N1.spelling=function(t){return(r,i)=>(console.warn(`${i} is likely a misspelling of ${t}`),!0)};function Bhe(e,t,r){if(typeof e!="object")throw new lt("options must be an object",lt.ERR_BAD_OPTION_VALUE);const i=Object.keys(e);let n=i.length;for(;n-- >0;){const a=i[n],s=t[a];if(s){const o=e[a],l=o===void 0||s(o,a,e);if(l!==!0)throw new lt("option "+a+" must be "+l,lt.ERR_BAD_OPTION_VALUE);continue}if(r!==!0)throw new lt("Unknown option "+a,lt.ERR_BAD_OPTION)}}const J0={assertOptions:Bhe,validators:N1}
vendor: 3,916 bytes, lines 53-54
53,Ia=J0.validators;let tc=class{constructor(t){this.defaults=t||{},this.interceptors={request:new sC,response:new sC}}async request(t,r){try{return await this._request(t,r)}catch(i){if(i instanceof Error){let n={};Error.captureStackTrace?Error.captureStackTrace(n):n=new Error;const a=n.stack?n.stack.replace(/^.+\n/,""):"";try{i.stack?a&&!String(i.stack).endsWith(a.replace(/^.+\n.+\n/,""))&&(i.stack+=` 54`+a):i.stack=a}catch{}}throw i}}_request(t,r){typeof t=="string"?(r=r||{},r.url=t):r=t||{},r=xc(this.defaults,r);const{transitional:i,paramsSerializer:n,headers:a}=r;i!==void 0&&J0.assertOptions(i,{silentJSONParsing:Ia.transitional(Ia.boolean),forcedJSONParsing:Ia.transitional(Ia.boolean),clarifyTimeoutError:Ia.transitional(Ia.boolean),legacyInterceptorReqResOrdering:Ia.transitional(Ia.boolean)},!1),n!=null&&(he.isFunction(n)?r.paramsSerializer={serialize:n}:J0.assertOptions(n,{encode:Ia.function,serialize:Ia.function},!0)),r.allowAbsoluteUrls!==void 0||(this.defaults.allowAbsoluteUrls!==void 0?r.allowAbsoluteUrls=this.defaults.allowAbsoluteUrls:r.allowAbsoluteUrls=!0),J0.assertOptions(r,{baseUrl:Ia.spelling("baseURL"),withXsrfToken:Ia.spelling("withXSRFToken")},!0),r.method=(r.method||this.defaults.method||"get").toLowerCase();let s=a&&he.merge(a.common,a[r.method]);a&&he.forEach(["delete","get","head","post","put","patch","common"],p=>{delete a[p]}),r.headers=Zn.concat(s,a);const o=[];let l=!0;this.interceptors.request.forEach(function(m){if(typeof m.runWhen=="function"&&m.runWhen(r)===!1)return;l=l&&m.synchronous;const g=r.transitional||K4;g&&g.legacyInterceptorReqResOrdering?o.unshift(m.fulfilled,m.rejected):o.push(m.fulfilled,m.rejected)});const u=[];this.interceptors.response.forEach(function(m){u.push(m.fulfilled,m.rejected)});let c,d=0,h;if(!l){const p=[_C.bind(this),void 0];for(p.unshift(...o),p.push(...u),h=p.length,c=Promise.resolve(r);d<h;)c=c.then(p[d++],p[d++]);return c}h=o.length;let f=r;for(;d<h;){const p=o[d++],m=o[d++];try{f=p(f)}catch(g){m.call(this,g);break}}try{c=_C.call(this,f)}catch(p){return Promise.reject(p)}for(d=0,h=u.length;d<h;)c=c.then(u[d++],u[d++]);return c}getUri(t){t=xc(this.defaults,t);const r=ED(t.baseURL,t.url,t.allowAbsoluteUrls);return SD(r,t.params,t.paramsSerializer)}};he.forEach(["delete","get","head","options"],function(t){tc.prototype[t]=function(r,i){return this.request(xc(i||{},{method:t,url:r,data:(i||{}).data}))}});he.forEach(["post","put","patch"],function(t){function r(i){return function(a,s,o){return this.request(xc(o||{},{method:t,headers:i?{"Content-Type":"multipart/form-data"}:{},url:a,data:s}))}}tc.prototype[t]=r(),tc.prototype[t+"Form"]=r(!0)});let jhe=class DD{constructor(t){if(typeof t!="function")throw new TypeError("executor must be a function.");let r;this.promise=new Promise(function(a){r=a});const i=this;this.promise.then(n=>{if(!i._listeners)return;let a=i._listeners.length;for(;a-- >0;)i._listeners[a](n);i._listeners=null}),this.promise.then=n=>{let a;const s=new Promise(o=>{i.subscribe(o),a=o}).then(n);return s.cancel=function(){i.unsubscribe(a)},s},t(function(a,s,o){i.reason||(i.reason=new ag(a,s,o),r(i.reason))})}throwIfRequested(){if(this.reason)throw this.reason}subscribe(t){if(this.reason){t(this.reason);return}this._listeners?this._listeners.push(t):this._listeners=[t]}unsubscribe(t){if(!this._listeners)return;const r=this._listeners.indexOf(t);r!==-1&&this._listeners.splice(r,1)}toAbortSignal(){const t=new AbortController,r=i=>{t.abort(i)};return this.subscribe(r),t.signal.unsubscribe=()=>this.unsubscribe(r),t.signal}static source(){let t;return{token:new DD(function(n){t=n}),cancel:t}}};function Uhe(e){return function(r){return e.apply(null,r)}}function Vhe(e){return he.isObject(e)&&e.isAxiosError===!0}const ux={Continue:100,SwitchingProtocols:101,Processing:102,EarlyHints:103,Ok:200,Created:201,Accepted:202,NonAuthoritativeInformation:203,NoContent:204,ResetContent:205,Parti
54alContent: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,WebServerIsDown:521,ConnectionTimedOut:522,OriginIsUnreachable:523,TimeoutOccurred:524,SslHandshakeFailed:525,InvalidSslCertificate:526};
54Object.entries(ux).forEach(([e,t])=>{ux[t]=e});function RD(e){const t=new tc(e),r=fD(tc.prototype.request,t);return he.extend(r,tc.prototype,t,{allOwnKeys:!0}),he.extend(r,t,null,{allOwnKeys:!0}),r.create=function(n){return RD(xc(e,n))},r}const Rt=RD(ng);Rt.Axios=tc;Rt.CanceledError=ag;Rt.CancelToken=jhe;Rt.isCancel=CD;Rt.VERSION=AD;Rt.toFormData=z1;Rt.AxiosError=lt;Rt.Cancel=Rt.CanceledError;Rt.all=function(t){return Promise.all(t)};Rt.spread=Uhe;Rt.isAxiosError=Vhe;Rt.mergeConfig=xc;Rt.AxiosHeaders=Zn;Rt.formToJSON=e=>TD(he.isHTMLForm(e)?new FormData(e):e);Rt.getAdapter=ID.getAdapter;Rt.HttpStatusCode=ux;Rt.default=Rt;const{Axios:IOe,AxiosError:AOe,CanceledError:DOe,isCancel:ROe,CancelToken:OOe,VERSION:LOe,all:FOe,Cancel:zOe,isAxiosError:NOe,spread:BOe,toFormData:jOe,AxiosHeaders:UOe,HttpStatusCode:VOe,formToJSON:qOe,getAdapter:GOe,mergeConfig:HOe}=Rt,qhe={name:"Spinner",props:["paddingClass"]};function Ghe(e,t,r,i,n,a){return k(),M("div",{role:"status",class:pe(["flex justify-center items-center",`${r.paddingClass?r.paddingClass:"py-16"}`])},[...t[0]||(t[0]=[b("svg",{"aria-hidden":"true",class:"mr-2 w-12 h-12 text-gray-200 animate-spin fill-ag-red",viewBox:"0 0 100 101",fill:"none",xmlns:"http://www.w3.org/2000/svg"},[b("path",{d:"M100 50.5908C100 78.2051 77.6142 100.591 50 100.591C22.3858 100.591 0 78.2051 0 50.5908C0 22.9766 22.3858 0.59082 50 0.59082C77.6142 0.59082 100 22.9766 100 50.5908ZM9.08144 50.5908C9.08144 73.1895 27.4013 91.5094 50 91.5094C72.5987 91.5094 90.9186 73.1895 90.9186 50.5908C90.9186 27.9921 72.5987 9.67226 50 9.67226C27.4013 9.67226 9.08144 27.9921 9.08144 50.5908Z",fill:"currentColor"}),b("path",{d:"M93.9676 39.0409C96.393 38.4038 97.8624 35.9116 97.0079 33.5539C95.2932 28.8227 92.871 24.3692 89.8167 20.348C85.8452 15.1192 80.8826 10.7238 75.2124 7.41289C69.5422 4.10194 63.2754 1.94025 56.7698 1.05124C51.7666 0.367541 46.6976 0.446843 41.7345 1.27873C39.2613 1.69328 37.813 4.19778 38.4501 6.62326C39.0873 9.04874 41.5694 10.4717 44.0505 10.1071C47.8511 9.54855 51.7191 9.52689 55.5402 10.0491C60.8642 10.7766 65.9928 12.5457 70.6331 15.2552C75.2735 17.9648 79.3347 21.5619 82.5849 25.841C84.9175 28.9121 86.7997 32.2913 88.1811 35.8758C89.083 38.2158 91.5421 39.6781 93.9676 39.0409Z",fill:"currentFill"})],-1),b("span",{class:"sr-only"},"Loading...",-1)])],2)}const Q4=Yt(qhe,[["render",Ghe]]),e$={async getUserLocation(){return new Promise((e,t)=>{let r=window.localStorage.getItem("userLocation");r&&JSON.parse(r).updated>=Date.now()-1e3*60*60*24?(console.log(Date.now()-1e3*60*60*24),console.log(JSON.parse(r).updated),e(JSON.parse(r))):Rt.get(window.proxyUri+"/api/rest/location/user").then(i=>{let n=JSON.stringify(i.data);window.localStorage.setItem("userLocation",n),e(i.data)}).catch(i=>{t({countryName:"United States",updated:Date.now()-1e3*60*60*24})})})}};function To(e){if(e===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return e}function OD(e,t){e.prototype=Object.create(t.prototype),e.prototype.constructor=e,e.__proto__=t}/*! 55 * GSAP 3.14.2 56 * https://gsap.com 57 * 58 * @license Copyright 2008-2025, GreenSock. All rights reserved. 59 * Subject to the terms at https://gsap.com/standard-license 60 * @author: Jack Doyle, [email protected] 61*/var wa={autoSleep:120,force3D:"auto",nullTargetWarn:1,units:{lineHeight:""}},xh={duration:.5,overwrite:!1,delay:0},t$,Hi,Ir,Za=1e8,dr=1/Za,cx=Math.PI*2,Hhe=cx/4,Yhe=0,LD=Math.sqrt,Whe=Math.cos,Zhe=Math.sin,Pi=function(t){return typeof t=="string"},Yr=function(t){return typeof t=="function"},sl=function(t){return typeof t=="number"},r$=function(t){return typeof t>"u"},lo=function(t){return typeof t=="object"},Kn=function(t){return t!==!1},i$=function(){return typeof window<"u"},Wg=function(t){return Yr(t)||Pi(t)},FD=typeof ArrayBuffer=="function"&&ArrayBuffer.isView||function(){},hn=Array.isArray,Khe=/random\([^)]+\)/g,Xhe=/,\s*/g,vC=/(?:-?\.?\d|\.)+/gi,zD=/[-+=.]*\d+[.e\-+]*\d*[e\-+]*\d*/g,bd=/[-+=.]*\d+[.e-]*\d*[a-z%]*/g,eb=/[-+=.]*\d+\.?\d*(?:e-|e\+)?\d*/gi,ND=/[+-]=-?[.\d]+/,Jhe=
vendor: 7,128 bytes, line 61
61/[^,'"\[\]\s]+/gi,Qhe=/^[+\-=e\s\d]*\d+[.\d]*([a-z]*|%)\s*$/i,Fr,Us,dx,n$,Sa={},uy={},BD,jD=function(t){return(uy=wh(t,Sa))&&ta},a$=function(t,r){return console.warn("Invalid property",t,"set to",r,"Missing plugin? gsap.registerPlugin()")},hm=function(t,r){return!r&&console.warn(t)},UD=function(t,r){return t&&(Sa[t]=r)&&uy&&(uy[t]=r)||Sa},fm=function(){return 0},efe={suppressEvents:!0,isStart:!0,kill:!1},Q0={suppressEvents:!0,kill:!1},tfe={suppressEvents:!0},s$={},Zl=[],hx={},VD,ua={},tb={},bC=30,e_=[],o$="",l$=function(t){var r=t[0],i,n;if(lo(r)||Yr(r)||(t=[t]),!(i=(r._gsap||{}).harness)){for(n=e_.length;n--&&!e_[n].targetTest(r););i=e_[n]}for(n=t.length;n--;)t[n]&&(t[n]._gsap||(t[n]._gsap=new f7(t[n],i)))||t.splice(n,1);return t},rc=function(t){return t._gsap||l$(Ka(t))[0]._gsap},qD=function(t,r,i){return(i=t[r])&&Yr(i)?t[r]():r$(i)&&t.getAttribute&&t.getAttribute(r)||i},Xn=function(t,r){return(t=t.split(",")).forEach(r)||t},Qr=function(t){return Math.round(t*1e5)/1e5||0},Lr=function(t){return Math.round(t*1e7)/1e7||0},Vd=function(t,r){var i=r.charAt(0),n=parseFloat(r.substr(2));return t=parseFloat(t),i==="+"?t+n:i==="-"?t-n:i==="*"?t*n:t/n},rfe=function(t,r){for(var i=r.length,n=0;t.indexOf(r[n])<0&&++n<i;);return n<i},cy=function(){var t=Zl.length,r=Zl.slice(0),i,n;for(hx={},Zl.length=0,i=0;i<t;i++)n=r[i],n&&n._lazy&&(n.render(n._lazy[0],n._lazy[1],!0)._lazy=0)},u$=function(t){return!!(t._initted||t._startAt||t.add)},GD=function(t,r,i,n){Zl.length&&!Hi&&cy(),t.render(r,i,!!(Hi&&r<0&&u$(t))),Zl.length&&!Hi&&cy()},HD=function(t){var r=parseFloat(t);return(r||r===0)&&(t+"").match(Jhe).length<2?r:Pi(t)?t.trim():t},YD=function(t){return t},Ta=function(t,r){for(var i in r)i in t||(t[i]=r[i]);return t},ife=function(t){return function(r,i){for(var n in i)n in r||n==="duration"&&t||n==="ease"||(r[n]=i[n])}},wh=function(t,r){for(var i in r)t[i]=r[i];return t},xC=function e(t,r){for(var i in r)i!=="__proto__"&&i!=="constructor"&&i!=="prototype"&&(t[i]=lo(r[i])?e(t[i]||(t[i]={}),r[i]):r[i]);return t},dy=function(t,r){var i={},n;for(n in t)n in r||(i[n]=t[n]);return i},pp=function(t){var r=t.parent||Fr,i=t.keyframes?ife(hn(t.keyframes)):Ta;if(Kn(t.inherit))for(;r;)i(t,r.vars.defaults),r=r.parent||r._dp;return t},nfe=function(t,r){for(var i=t.length,n=i===r.length;n&&i--&&t[i]===r[i];);return i<0},WD=function(t,r,i,n,a){var s=t[n],o;if(a)for(o=r[a];s&&s[a]>o;)s=s._prev;return s?(r._next=s._next,s._next=r):(r._next=t[i],t[i]=r),r._next?r._next._prev=r:t[n]=r,r._prev=s,r.parent=r._dp=t,r},B1=function(t,r,i,n){i===void 0&&(i="_first"),n===void 0&&(n="_last");var a=r._prev,s=r._next;a?a._next=s:t[i]===r&&(t[i]=s),s?s._prev=a:t[n]===r&&(t[n]=a),r._next=r._prev=r.parent=null},nu=function(t,r){t.parent&&(!r||t.parent.autoRemoveChildren)&&t.parent.remove&&t.parent.remove(t),t._act=0},ic=function(t,r){if(t&&(!r||r._end>t._dur||r._start<0))for(var i=t;i;)i._dirty=1,i=i.parent;return t},afe=function(t){for(var r=t.parent;r&&r.parent;)r._dirty=1,r.totalDuration(),r=r.parent;return t},fx=function(t,r,i,n){return t._startAt&&(Hi?t._startAt.revert(Q0):t.vars.immediateRender&&!t.vars.autoRevert||t._startAt.render(r,!0,n))},sfe=function e(t){return!t||t._ts&&e(t.parent)},wC=function(t){return t._repeat?$h(t._tTime,t=t.duration()+t._rDelay)*t:0},$h=function(t,r){var i=Math.floor(t=Lr(t/r));return t&&i===t?i-1:i},hy=function(t,r){return(t-r._start)*r._ts+(r._ts>=0?0:r._dirty?r.totalDuration():r._tDur)},j1=function(t){return t._end=Lr(t._start+(t._tDur/Math.abs(t._ts||t._rts||dr)||0))},U1=function(t,r){var i=t._dp;return i&&i.smoothChildTiming&&t._ts&&(t._start=Lr(i._time-(t._ts>0?r/t._ts:((t._dirty?t.totalDuration():t._tDur)-r)/-t._ts)),j1(t),i._dirty||ic(i,t)),t},ZD=function(t,r){var i;if((r._time||!r._dur&&r._initted||r._start<t._time&&(r._dur||!r.add))&&(i=hy(t.rawTime(),r),(!r._dur||sg(0,r.totalDuration(),i)-r._tTime>dr)&&r.render(i,!0)),ic(t,r)._dp&&t._initted&&t._time>=t._dur&&t._ts){if(t._dur<t.duration())for(i=t;i._dp;)i.rawTime()>=0&&i.totalTime(i._tTime),i=i._dp;t._zTime=-dr}},Ys=function(t,r,i,n){return r.parent&&nu(r),r._start=Lr((sl(i)?i:i||t!==Fr?La(t,i,r):t._time)+r._delay),r._end=Lr(r._start+(r.totalDuration()/Math.abs(r.timeScale())||0)),WD(t,r,"_first","_last",t._sort?"_start":0),px(r)||(t._recent=r),n||ZD(t,r),t._ts<0&&U1(t,t._tTime),t},KD=function(t,r){return(Sa.ScrollTrigger||a$("scrollTrigger",r))&&Sa.ScrollTrigger.create(r,t)},XD=function(t,r,i,n,a){if(d$(t,r,a),!t._initted)return 1;if(!i&&t._pt&&!Hi&&(t._dur&&t.vars.lazy!==!1||!t._dur&&t.vars.lazy)&&VD!==ha.frame)return Zl.push(t),t._lazy=[a,n],1},ofe=function e(t){var r=t.parent;return r&&r._ts&&r._initted&&!r._lock&&(r.rawTime()<0||e(r))},px=function(t){var r=t.data;return r==="isFromStart"||r==="isStart"},lfe=function(t,r,i,n){var a=t.ratio,s=r<0||!r&&(!t._start&&ofe(t)&&!(!t._initted&&px(t))||(t._ts<0||t._dp._ts<0)&&!px(t))?0:1,o=t._rDelay,l=0,u,c,d;if(o&&t._repeat&&(l=sg(0,t._tDur,r),c=$h(l,o),t._yoyo&&c&1&&(s=1-s),c!==$h(t._tTime,o)&&(a=1-s,t.vars.repeatRefresh&&t._initted&&t.invalidate())),s!==a||Hi||n||t._zTime===dr||!r&&t._zTime){if(!t._initted&&XD(t,r,n,i,l))return;for(d=t._zTime,t._zTime=r||(i?dr:0),i||(i=r&&!d),t.ratio=s,t._from&&(s=1-s),t._time=0,t._tTime=l,u=t._pt;u;)u.r(s,u.d),u=u._next;r<0&&fx(t,r,i,!0),t._onUpdate&&!i&&ga(t,"onUpdate"),l&&t._repeat&&!i&&t.parent&&ga(t,"onRepeat"),(r>=t._tDur||r<0)&&t.ratio===s&&(s&&nu(t,1),!i&&!Hi&&(ga(t,s?"onComplete":"onReverseComplete",!0),t._prom&&t._prom()))}else t._zTime||(t._zTime=r)},ufe=function(t,r,i){var n;if(i>r)for(n=t._first;n&&n._start<=i;){if(n.data==="isPause"&&n._start>r)return n;n=n._next}else for(n=t._last;n&&n._start>=i;){if(n.data==="isPause"&&n._start<r)return n;n=n._prev}},Sh=function(t,r,i,n){var a=t._repeat,s=Lr(r)||0,o=t._tTime/t._tDur;return o&&!n&&(t._time*=s/t._dur),t._dur=s,t._tDur=a?a<0?1e10:Lr(s*(a+1)+t._rDelay*a):s,o>0&&!n&&U1(t,t._tTime=t._tDur*o),t.parent&&j1(t),i||ic(t.parent,t),t},$C=function(t){return t instanceof Pn?ic(t):Sh(t,t._dur)},cfe={_start:0,endTime:fm,totalDuration:fm},La=function e(t,r,i){var n=t.labels,a=t._recent||cfe,s=t.duration()>=Za?a.endTime(!1):t._dur,o,l,u;return Pi(r)&&(isNaN(r)||r in n)?(l=r.charAt(0),u=r.substr(-1)==="%",o=r.indexOf("="),l==="<"||l===">"?(o>=0&&(r=r.replace(/=/,"")),(l==="<"?a._start:a.endTime(a._repeat>=0))+(parseFloat(r.substr(1))||0)*(u?(o<0?a:i).totalDuration()/100:1)):o<0?(r in n||(n[r]=s),n[r]):(l=parseFloat(r.charAt(o-1)+r.substr(o+1)),u&&i&&(l=l/100*(hn(i)?i[0]:i).totalDuration()),o>1?e(t,r.substr(0,o-1),i)+l:s+l)):r==null?s:+r},mp=function(t,r,i){var n=sl(r[1]),a=(n?2:1)+(t<2?0:1),s=r[a],o,l;if(n&&(s.duration=r[1]),s.parent=i,t){for(o=s,l=i;l&&!("immediateRender"in o);)o=l.vars.defaults||{},l=Kn(l.vars.inherit)&&l.parent;s.immediateRender=Kn(o.immediateRender),t<2?s.runBackwards=1:s.startAt=r[a-1]}return new oi(r[0],s,r[a+1])},mu=function(t,r){return t||t===0?r(t):r},sg=function(t,r,i){return i<t?t:i>r?r:i},on=function(t,r){return!Pi(t)||!(r=Qhe.exec(t))?"":r[1]},dfe=function(t,r,i){return mu(i,function(n){return sg(t,r,n)})},mx=[].slice,JD=function(t,r){return t&&lo(t)&&"length"in t&&(!r&&!t.length||t.length-1
vendor: 4,996 bytes, line 61
61in t&&lo(t[0]))&&!t.nodeType&&t!==Us},hfe=function(t,r,i){return i===void 0&&(i=[]),t.forEach(function(n){var a;return Pi(n)&&!r||JD(n,1)?(a=i).push.apply(a,Ka(n)):i.push(n)})||i},Ka=function(t,r,i){return Ir&&!r&&Ir.selector?Ir.selector(t):Pi(t)&&!i&&(dx||!Th())?mx.call((r||n$).querySelectorAll(t),0):hn(t)?hfe(t,i):JD(t)?mx.call(t,0):t?[t]:[]},gx=function(t){return t=Ka(t)[0]||hm("Invalid scope")||{},function(r){var i=t.current||t.nativeElement||t;return Ka(r,i.querySelectorAll?i:i===t?hm("Invalid scope")||n$.createElement("div"):t)}},QD=function(t){return t.sort(function(){return .5-Math.random()})},e7=function(t){if(Yr(t))return t;var r=lo(t)?t:{each:t},i=nc(r.ease),n=r.from||0,a=parseFloat(r.base)||0,s={},o=n>0&&n<1,l=isNaN(n)||o,u=r.axis,c=n,d=n;return Pi(n)?c=d={center:.5,edges:.5,end:1}[n]||0:!o&&l&&(c=n[0],d=n[1]),function(h,f,p){var m=(p||r).length,g=s[m],v,x,_,y,w,$,S,E,C;if(!g){if(C=r.grid==="auto"?0:(r.grid||[1,Za])[1],!C){for(S=-Za;S<(S=p[C++].getBoundingClientRect().left)&&C<m;);C<m&&C--}for(g=s[m]=[],v=l?Math.min(C,m)*c-.5:n%C,x=C===Za?0:l?m*d/C-.5:n/C|0,S=0,E=Za,$=0;$<m;$++)_=$%C-v,y=x-($/C|0),g[$]=w=u?Math.abs(u==="y"?y:_):LD(_*_+y*y),w>S&&(S=w),w<E&&(E=w);n==="random"&&QD(g),g.max=S-E,g.min=E,g.v=m=(parseFloat(r.amount)||parseFloat(r.each)*(C>m?m-1:u?u==="y"?m/C:C:Math.max(C,m/C))||0)*(n==="edges"?-1:1),g.b=m<0?a-m:a,g.u=on(r.amount||r.each)||0,i=i&&m<0?c7(i):i}return m=(g[h]-g.min)/g.max||0,Lr(g.b+(i?i(m):m)*g.v)+g.u}},_x=function(t){var r=Math.pow(10,((t+"").split(".")[1]||"").length);return function(i){var n=Lr(Math.round(parseFloat(i)/t)*t*r);return(n-n%1)/r+(sl(i)?0:on(i))}},t7=function(t,r){var i=hn(t),n,a;return!i&&lo(t)&&(n=i=t.radius||Za,t.values?(t=Ka(t.values),(a=!sl(t[0]))&&(n*=n)):t=_x(t.increment)),mu(r,i?Yr(t)?function(s){return a=t(s),Math.abs(a-s)<=n?a:s}:function(s){for(var o=parseFloat(a?s.x:s),l=parseFloat(a?s.y:0),u=Za,c=0,d=t.length,h,f;d--;)a?(h=t[d].x-o,f=t[d].y-l,h=h*h+f*f):h=Math.abs(t[d]-o),h<u&&(u=h,c=d);return c=!n||u<=n?t[c]:s,a||c===s||sl(s)?c:c+on(s)}:_x(t))},r7=function(t,r,i,n){return mu(hn(t)?!r:i===!0?!!(i=0):!n,function(){return hn(t)?t[~~(Math.random()*t.length)]:(i=i||1e-5)&&(n=i<1?Math.pow(10,(i+"").length-2):1)&&Math.floor(Math.round((t-i/2+Math.random()*(r-t+i*.99))/i)*i*n)/n})},ffe=function(){for(var t=arguments.length,r=new Array(t),i=0;i<t;i++)r[i]=arguments[i];return function(n){return r.reduce(function(a,s){return s(a)},n)}},pfe=function(t,r){return function(i){return t(parseFloat(i))+(r||on(i))}},mfe=function(t,r,i){return n7(t,r,0,1,i)},i7=function(t,r,i){return mu(i,function(n){return t[~~r(n)]})},gfe=function e(t,r,i){var n=r-t;return hn(t)?i7(t,e(0,t.length),r):mu(i,function(a){return(n+(a-t)%n)%n+t})},_fe=function e(t,r,i){var n=r-t,a=n*2;return hn(t)?i7(t,e(0,t.length-1),r):mu(i,function(s){return s=(a+(s-t)%a)%a||0,t+(s>n?a-s:s)})},pm=function(t){return t.replace(Khe,function(r){var i=r.indexOf("[")+1,n=r.substring(i||7,i?r.indexOf("]"):r.length-1).split(Xhe);return r7(i?n:+n[0],i?0:+n[1],+n[2]||1e-5)})},n7=function(t,r,i,n,a){var s=r-t,o=n-i;return mu(a,function(l){return i+((l-t)/s*o||0)})},yfe=function e(t,r,i,n){var a=isNaN(t+r)?0:function(f){return(1-f)*t+f*r};if(!a){var s=Pi(t),o={},l,u,c,d,h;if(i===!0&&(n=1)&&(i=null),s)t={p:t},r={p:r};else if(hn(t)&&!hn(r)){for(c=[],d=t.length,h=d-2,u=1;u<d;u++)c.push(e(t[u-1],t[u]));d--,a=function(p){p*=d;var m=Math.min(h,~~p);return c[m](p-m)},i=r}else n||(t=wh(hn(t)?[]:{},t));if(!c){for(l in r)c$.call(o,t,l,"get",r[l]);a=function(p){return p$(p,o)||(s?t.p:t)}}}return mu(i,a)},SC=function(t,r,i){var n=t.labels,a=Za,s,o,l;for(s in n)o=n[s]-r,o<0==!!i&&o&&a>(o=Math.abs(o))&&(l=s,a=o);return l},ga=function(t,r,i){var n=t.vars,a=n[r],s=Ir,o=t._ctx,l,u,c;if(a)return l=n[r+"Params"],u=n.callbackScope||t,i&&Zl.length&&cy(),o&&(Ir=o),c=l?a.apply(u,l):a.call(u),Ir=s,c},Vf=function(t){return nu(t),t.scrollTrigger&&t.scrollTrigger.kill(!!Hi),t.progress()<1&&ga(t,"onInterrupt"),t},xd,a7=[],s7=function(t){if(t)if(t=!t.name&&t.default||t,i$()||t.headless){var r=t.name,i=Yr(t),n=r&&!i&&t.init?function(){this._props=[]}:t,a={init:fm,render:p$,add:c$,kill:Rfe,modifier:Dfe,rawVars:0},s={targetTest:0,get:0,getSetter:f$,aliases:{},register:0};if(Th(),t!==n){if(ua[r])return;Ta(n,Ta(dy(t,a),s)),wh(n.prototype,wh(a,dy(t,s))),ua[n.prop=r]=n,t.targetTest&&(e_.push(n),s$[r]=1),r=(r==="css"?"CSS":r.charAt(0).toUpperCase()+r.substr(1))+"Plugin"}UD(r,n),t.register&&t.register(ta,n,Jn)}else a7.push(t)},cr=255,qf={aqua:[0,cr,cr],lime:[0,cr,0],silver:[192,192,192],black:[0,0,0],maroon:[128,0,0],teal:[0,128,128],blue:[0,0,cr],navy:[0,0,128],white:[cr,cr,cr],olive:[128,128,0],yellow:[cr,cr,0],orange:[cr,165,0],gray:[128,128,128],purple:[128,0,128],green:[0,128,0],red:[cr,0,0],pink:[cr,192,203],cyan:[0,cr,cr],transparent:[cr,cr,cr,0]},rb=function(t,r,i){return t+=t<0?1:t>1?-1:0,(t*6<1?r+(i-r)*t*6:t<.5?i:t*3<2?r+(i-r)*(2/3-t)*6:r)*cr+.5|0},o7=function(t,r,i){var n=t?sl(t)?[t>>16,t>>8&cr,t&cr]:0:qf.black,a,s,o,l,u,c,d,h,f,p;
vendor: 5,865 bytes, line 61
61if(!n){if(t.substr(-1)===","&&(t=t.substr(0,t.length-1)),qf[t])n=qf[t];else if(t.charAt(0)==="#"){if(t.length<6&&(a=t.charAt(1),s=t.charAt(2),o=t.charAt(3),t="#"+a+a+s+s+o+o+(t.length===5?t.charAt(4)+t.charAt(4):"")),t.length===9)return n=parseInt(t.substr(1,6),16),[n>>16,n>>8&cr,n&cr,parseInt(t.substr(7),16)/255];t=parseInt(t.substr(1),16),n=[t>>16,t>>8&cr,t&cr]}else if(t.substr(0,3)==="hsl"){if(n=p=t.match(vC),!r)l=+n[0]%360/360,u=+n[1]/100,c=+n[2]/100,s=c<=.5?c*(u+1):c+u-c*u,a=c*2-s,n.length>3&&(n[3]*=1),n[0]=rb(l+1/3,a,s),n[1]=rb(l,a,s),n[2]=rb(l-1/3,a,s);else if(~t.indexOf("="))return n=t.match(zD),i&&n.length<4&&(n[3]=1),n}else n=t.match(vC)||qf.transparent;n=n.map(Number)}return r&&!p&&(a=n[0]/cr,s=n[1]/cr,o=n[2]/cr,d=Math.max(a,s,o),h=Math.min(a,s,o),c=(d+h)/2,d===h?l=u=0:(f=d-h,u=c>.5?f/(2-d-h):f/(d+h),l=d===a?(s-o)/f+(s<o?6:0):d===s?(o-a)/f+2:(a-s)/f+4,l*=60),n[0]=~~(l+.5),n[1]=~~(u*100+.5),n[2]=~~(c*100+.5)),i&&n.length<4&&(n[3]=1),n},l7=function(t){var r=[],i=[],n=-1;return t.split(Kl).forEach(function(a){var s=a.match(bd)||[];r.push.apply(r,s),i.push(n+=s.length+1)}),r.c=i,r},TC=function(t,r,i){var n="",a=(t+n).match(Kl),s=r?"hsla(":"rgba(",o=0,l,u,c,d;if(!a)return t;if(a=a.map(function(h){return(h=o7(h,r,1))&&s+(r?h[0]+","+h[1]+"%,"+h[2]+"%,"+h[3]:h.join(","))+")"}),i&&(c=l7(t),l=i.c,l.join(n)!==c.c.join(n)))for(u=t.replace(Kl,"1").split(bd),d=u.length-1;o<d;o++)n+=u[o]+(~l.indexOf(o)?a.shift()||s+"0,0,0,0)":(c.length?c:a.length?a:i).shift());if(!u)for(u=t.split(Kl),d=u.length-1;o<d;o++)n+=u[o]+a[o];return n+u[d]},Kl=(function(){var e="(?:\\b(?:(?:rgb|rgba|hsl|hsla)\\(.+?\\))|\\B#(?:[0-9a-f]{3,4}){1,2}\\b",t;for(t in qf)e+="|"+t+"\\b";return new RegExp(e+")","gi")})(),vfe=/hsl[a]?\(/,u7=function(t){var r=t.join(" "),i;if(Kl.lastIndex=0,Kl.test(r))return i=vfe.test(r),t[1]=TC(t[1],i),t[0]=TC(t[0],i,l7(t[1])),!0},mm,ha=(function(){var e=Date.now,t=500,r=33,i=e(),n=i,a=1e3/240,s=a,o=[],l,u,c,d,h,f,p=function m(g){var v=e()-n,x=g===!0,_,y,w,$;if((v>t||v<0)&&(i+=v-r),n+=v,w=n-i,_=w-s,(_>0||x)&&($=++d.frame,h=w-d.time*1e3,d.time=w=w/1e3,s+=_+(_>=a?4:a-_),y=1),x||(l=u(m)),y)for(f=0;f<o.length;f++)o[f](w,h,$,g)};return d={time:0,frame:0,tick:function(){p(!0)},deltaRatio:function(g){return h/(1e3/(g||60))},wake:function(){BD&&(!dx&&i$()&&(Us=dx=window,n$=Us.document||{},Sa.gsap=ta,(Us.gsapVersions||(Us.gsapVersions=[])).push(ta.version),jD(uy||Us.GreenSockGlobals||!Us.gsap&&Us||{}),a7.forEach(s7)),c=typeof requestAnimationFrame<"u"&&requestAnimationFrame,l&&d.sleep(),u=c||function(g){return setTimeout(g,s-d.time*1e3+1|0)},mm=1,p(2))},sleep:function(){(c?cancelAnimationFrame:clearTimeout)(l),mm=0,u=fm},lagSmoothing:function(g,v){t=g||1/0,r=Math.min(v||33,t)},fps:function(g){a=1e3/(g||240),s=d.time*1e3+a},add:function(g,v,x){var _=v?function(y,w,$,S){g(y,w,$,S),d.remove(_)}:g;return d.remove(g),o[x?"unshift":"push"](_),Th(),_},remove:function(g,v){~(v=o.indexOf(g))&&o.splice(v,1)&&f>=v&&f--},_listeners:o},d})(),Th=function(){return!mm&&ha.wake()},Bt={},bfe=/^[\d.\-M][\d.\-,\s]/,xfe=/["']/g,wfe=function(t){for(var r={},i=t.substr(1,t.length-3).split(":"),n=i[0],a=1,s=i.length,o,l,u;a<s;a++)l=i[a],o=a!==s-1?l.lastIndexOf(","):l.length,u=l.substr(0,o),r[n]=isNaN(u)?u.replace(xfe,"").trim():+u,n=l.substr(o+1).trim();return r},$fe=function(t){var r=t.indexOf("(")+1,i=t.indexOf(")"),n=t.indexOf("(",r);return t.substring(r,~n&&n<i?t.indexOf(")",i+1):i)},Sfe=function(t){var r=(t+"").split("("),i=Bt[r[0]];return i&&r.length>1&&i.config?i.config.apply(null,~t.indexOf("{")?[wfe(r[1])]:$fe(t).split(",").map(HD)):Bt._CE&&bfe.test(t)?Bt._CE("",t):i},c7=function(t){return function(r){return 1-t(1-r)}},d7=function e(t,r){for(var i=t._first,n;i;)i instanceof Pn?e(i,r):i.vars.yoyoEase&&(!i._yoyo||!i._repeat)&&i._yoyo!==r&&(i.timeline?e(i.timeline,r):(n=i._ease,i._ease=i._yEase,i._yEase=n,i._yoyo=r)),i=i._next},nc=function(t,r){return t&&(Yr(t)?t:Bt[t]||Sfe(t))||r},Lc=function(t,r,i,n){i===void 0&&(i=function(l){return 1-r(1-l)}),n===void 0&&(n=function(l){return l<.5?r(l*2)/2:1-r((1-l)*2)/2});var a={easeIn:r,easeOut:i,easeInOut:n},s;return Xn(t,function(o){Bt[o]=Sa[o]=a,Bt[s=o.toLowerCase()]=i;for(var l in a)Bt[s+(l==="easeIn"?".in":l==="easeOut"?".out":".inOut")]=Bt[o+"."+l]=a[l]}),a},h7=function(t){return function(r){return r<.5?(1-t(1-r*2))/2:.5+t((r-.5)*2)/2}},ib=function e(t,r,i){var n=r>=1?r:1,a=(i||(t?.3:.45))/(r<1?r:1),s=a/cx*(Math.asin(1/n)||0),o=function(c){return c===1?1:n*Math.pow(2,-10*c)*Zhe((c-s)*a)+1},l=t==="out"?o:t==="in"?function(u){return 1-o(1-u)}:h7(o);return a=cx/a,l.config=function(u,c){return e(t,u,c)},l},nb=function e(t,r){r===void 0&&(r=1.70158);var i=function(s){return s?--s*s*((r+1)*s+r)+1:0},n=t==="out"?i:t==="in"?function(a){return 1-i(1-a)}:h7(i);return n.config=function(a){return e(t,a)},n};Xn("Linear,Quad,Cubic,Quart,Quint,Strong",function(e,t){var r=t<5?t+1:t;Lc(e+",Power"+(r-1),t?function(i){return Math.pow(i,r)}:function(i){return i},function(i){return 1-Math.pow(1-i,r)},function(i){return i<.5?Math.pow(i*2,r)/2:1-Math.pow((1-i)*2,r)/2})});Bt.Linear.easeNone=Bt.none=Bt.Linear.easeIn;Lc("Elastic",ib("in"),ib("out"),ib());(function(e,t){var r=1/t,i=2*r,n=2.5*r,a=function(o){return o<r?e*o*o:o<i?e*Math.pow(o-1.5/t,2)+.75:o<n?e*(o-=2.25/t)*o+.9375:e*Math.pow(o-2.625/t,2)+.984375};Lc("Bounce",function(s){return 1-a(1-s)},a)})(7.5625,2.75);Lc("Expo",function(e){return Math.pow(2,10*(e-1))*e+e*e*e*e*e*e*(1-e)});Lc("Circ",function(e){return-(LD(1-e*e)-1)});Lc("Sine",function(e){return e===1?1:-Whe(e*Hhe)+1});Lc("Back",nb("in"),nb("out"),nb());Bt.SteppedEase=Bt.steps=Sa.SteppedEase={config:function(t,r){t===void 0&&(t=1);var i=1/t,n=t+(r?0:1),a=r?1:0,s=1-dr;return function(o){return((n*sg(0,s,o)|0)+a)*i}}};xh.ease=Bt["quad.out"];Xn("onComplete,onUpdate,onStart,onRepeat,onReverseComplete,onInterrupt",function(e){return o$+=e+","+e+"Params,"});
vendor: 14,947 bytes, line 61
61var f7=function(t,r){this.id=Yhe++,t._gsap=this,this.target=t,this.harness=r,this.get=r?r.get:qD,this.set=r?r.getSetter:f$},gm=(function(){function e(r){this.vars=r,this._delay=+r.delay||0,(this._repeat=r.repeat===1/0?-2:r.repeat||0)&&(this._rDelay=r.repeatDelay||0,this._yoyo=!!r.yoyo||!!r.yoyoEase),this._ts=1,Sh(this,+r.duration,1,1),this.data=r.data,Ir&&(this._ctx=Ir,Ir.data.push(this)),mm||ha.wake()}var t=e.prototype;return t.delay=function(i){return i||i===0?(this.parent&&this.parent.smoothChildTiming&&this.startTime(this._start+i-this._delay),this._delay=i,this):this._delay},t.duration=function(i){return arguments.length?this.totalDuration(this._repeat>0?i+(i+this._rDelay)*this._repeat:i):this.totalDuration()&&this._dur},t.totalDuration=function(i){return arguments.length?(this._dirty=0,Sh(this,this._repeat<0?i:(i-this._repeat*this._rDelay)/(this._repeat+1))):this._tDur},t.totalTime=function(i,n){if(Th(),!arguments.length)return this._tTime;var a=this._dp;if(a&&a.smoothChildTiming&&this._ts){for(U1(this,i),!a._dp||a.parent||ZD(a,this);a&&a.parent;)a.parent._time!==a._start+(a._ts>=0?a._tTime/a._ts:(a.totalDuration()-a._tTime)/-a._ts)&&a.totalTime(a._tTime,!0),a=a.parent;!this.parent&&this._dp.autoRemoveChildren&&(this._ts>0&&i<this._tDur||this._ts<0&&i>0||!this._tDur&&!i)&&Ys(this._dp,this,this._start-this._delay)}return(this._tTime!==i||!this._dur&&!n||this._initted&&Math.abs(this._zTime)===dr||!this._initted&&this._dur&&i||!i&&!this._initted&&(this.add||this._ptLookup))&&(this._ts||(this._pTime=i),GD(this,i,n)),this},t.time=function(i,n){return arguments.length?this.totalTime(Math.min(this.totalDuration(),i+wC(this))%(this._dur+this._rDelay)||(i?this._dur:0),n):this._time},t.totalProgress=function(i,n){return arguments.length?this.totalTime(this.totalDuration()*i,n):this.totalDuration()?Math.min(1,this._tTime/this._tDur):this.rawTime()>=0&&this._initted?1:0},t.progress=function(i,n){return arguments.length?this.totalTime(this.duration()*(this._yoyo&&!(this.iteration()&1)?1-i:i)+wC(this),n):this.duration()?Math.min(1,this._time/this._dur):this.rawTime()>0?1:0},t.iteration=function(i,n){var a=this.duration()+this._rDelay;return arguments.length?this.totalTime(this._time+(i-1)*a,n):this._repeat?$h(this._tTime,a)+1:1},t.timeScale=function(i,n){if(!arguments.length)return this._rts===-dr?0:this._rts;if(this._rts===i)return this;var a=this.parent&&this._ts?hy(this.parent._time,this):this._tTime;return this._rts=+i||0,this._ts=this._ps||i===-dr?0:this._rts,this.totalTime(sg(-Math.abs(this._delay),this.totalDuration(),a),n!==!1),j1(this),afe(this)},t.paused=function(i){return arguments.length?(this._ps!==i&&(this._ps=i,i?(this._pTime=this._tTime||Math.max(-this._delay,this.rawTime()),this._ts=this._act=0):(Th(),this._ts=this._rts,this.totalTime(this.parent&&!this.parent.smoothChildTiming?this.rawTime():this._tTime||this._pTime,this.progress()===1&&Math.abs(this._zTime)!==dr&&(this._tTime-=dr)))),this):this._ps},t.startTime=function(i){if(arguments.length){this._start=Lr(i);var n=this.parent||this._dp;return n&&(n._sort||!this.parent)&&Ys(n,this,this._start-this._delay),this}return this._start},t.endTime=function(i){return this._start+(Kn(i)?this.totalDuration():this.duration())/Math.abs(this._ts||1)},t.rawTime=function(i){var n=this.parent||this._dp;return n?i&&(!this._ts||this._repeat&&this._time&&this.totalProgress()<1)?this._tTime%(this._dur+this._rDelay):this._ts?hy(n.rawTime(i),this):this._tTime:this._tTime},t.revert=function(i){i===void 0&&(i=tfe);var n=Hi;return Hi=i,u$(this)&&(this.timeline&&this.timeline.revert(i),this.totalTime(-.01,i.suppressEvents)),this.data!=="nested"&&i.kill!==!1&&this.kill(),Hi=n,this},t.globalTime=function(i){for(var n=this,a=arguments.length?i:n.rawTime();n;)a=n._start+a/(Math.abs(n._ts)||1),n=n._dp;return!this.parent&&this._sat?this._sat.globalTime(i):a},t.repeat=function(i){return arguments.length?(this._repeat=i===1/0?-2:i,$C(this)):this._repeat===-2?1/0:this._repeat},t.repeatDelay=function(i){if(arguments.length){var n=this._time;return this._rDelay=i,$C(this),n?this.time(n):this}return this._rDelay},t.yoyo=function(i){return arguments.length?(this._yoyo=i,this):this._yoyo},t.seek=function(i,n){return this.totalTime(La(this,i),Kn(n))},t.restart=function(i,n){return this.play().totalTime(i?-this._delay:0,Kn(n)),this._dur||(this._zTime=-dr),this},t.play=function(i,n){return i!=null&&this.seek(i,n),this.reversed(!1).paused(!1)},t.reverse=function(i,n){return i!=null&&this.seek(i||this.totalDuration(),n),this.reversed(!0).paused(!1)},t.pause=function(i,n){return i!=null&&this.seek(i,n),this.paused(!0)},t.resume=function(){return this.paused(!1)},t.reversed=function(i){return arguments.length?(!!i!==this.reversed()&&this.timeScale(-this._rts||(i?-dr:0)),this):this._rts<0},t.invalidate=function(){return this._initted=this._act=0,this._zTime=-dr,this},t.isActive=function(){var i=this.parent||this._dp,n=this._start,a;return!!(!i||this._ts&&this._initted&&i.isActive()&&(a=i.rawTime(!0))>=n&&a<this.endTime(!0)-dr)},t.eventCallback=function(i,n,a){var s=this.vars;return arguments.length>1?(n?(s[i]=n,a&&(s[i+"Params"]=a),i==="onUpdate"&&(this._onUpdate=n)):delete s[i],this):s[i]},t.then=function(i){var n=this,a=n._prom;return new Promise(function(s){var o=Yr(i)?i:YD,l=function(){var c=n.then;n.then=null,a&&a(),Yr(o)&&(o=o(n))&&(o.then||o===n)&&(n.then=c),s(o),n.then=c};n._initted&&n.totalProgress()===1&&n._ts>=0||!n._tTime&&n._ts<0?l():n._prom=l})},t.kill=function(){Vf(this)},e})();Ta(gm.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:-dr,_prom:0,_ps:!1,_rts:1});var Pn=(function(e){OD(t,e);function t(i,n){var a;return i===void 0&&(i={}),a=e.call(this,i)||this,a.labels={},a.smoothChildTiming=!!i.smoothChildTiming,a.autoRemoveChildren=!!i.autoRemoveChildren,a._sort=Kn(i.sortChildren),Fr&&Ys(i.parent||Fr,To(a),n),i.reversed&&a.reverse(),i.paused&&a.paused(!0),i.scrollTrigger&&KD(To(a),i.scrollTrigger),a}var r=t.prototype;return r.to=function(n,a,s){return mp(0,arguments,this),this},r.from=function(n,a,s){return mp(1,arguments,this),this},r.fromTo=function(n,a,s,o){return mp(2,arguments,this),this},r.set=function(n,a,s){return a.duration=0,a.parent=this,pp(a).repeatDelay||(a.repeat=0),a.immediateRender=!!a.immediateRender,new oi(n,a,La(this,s),1),this},r.call=function(n,a,s){return Ys(this,oi.delayedCall(0,n,a),s)},r.staggerTo=function(n,a,s,o,l,u,c){return s.duration=a,s.stagger=s.stagger||o,s.onComplete=u,s.onCompleteParams=c,s.parent=this,new oi(n,s,La(this,l)),this},r.staggerFrom=function(n,a,s,o,l,u,c){return s.runBackwards=1,pp(s).immediateRender=Kn(s.immediateRender),this.staggerTo(n,a,s,o,l,u,c)},r.staggerFromTo=function(n,a,s,o,l,u,c,d){return o.startAt=s,pp(o).immediateRender=Kn(o.immediateRender),this.staggerTo(n,a,o,l,u,c,d)},r.render=function(n,a,s){var o=this._time,l=this._dirty?this.totalDuration():this._tDur,u=this._dur,c=n<=0?0:Lr(n),d=this._zTime<0!=n<0&&(this._initted||!u),h,f,p,m,g,v,x,_,y,w,$,S;if(this!==Fr&&c>l&&n>=0&&(c=l),c!==this._tTime||s||d){if(o!==this._time&&u&&(c+=this._time-o,n+=this._time-o),h=c,y=this._start,_=this._ts,v=!_,d&&(u||(o=this._zTime),(n||!a)&&(this._zTime=n)),this._repeat){if($=this._yoyo,g=u+this._rDelay,this._repeat<-1&&n<0)return this.totalTime(g*100+n,a,s);if(h=Lr(c%g),c===l?(m=this._repeat,h=u):(w=Lr(c/g),m=~~w,m&&m===w&&(h=u,m--),h>u&&(h=u)),w=$h(this._tTime,g),!o&&this._tTime&&w!==m&&this._tTime-w*g-this._dur<=0&&(w=m),$&&m&1&&(h=u-h,S=1),m!==w&&!this._lock){var E=$&&w&1,C=E===($&&m&1);if(m<w&&(E=!E),o=E?0:c%u?u:c,this._lock=1,this.render(o||(S?0:Lr(m*g)),a,!u)._lock=0,this._tTime=c,!a&&this.parent&&ga(this,"onRepeat"),this.vars.repeatRefresh&&!S&&(this.invalidate()._lock=1,w=m),o&&o!==this._time||v!==!this._ts||this.vars.onRepeat&&!this.parent&&!this._act)return this;if(u=this._dur,l=this._tDur,C&&(this._lock=2,o=E?u:-1e-4,this.render(o,!0),this.vars.repeatRefresh&&!S&&this.invalidate()),this._lock=0,!this._ts&&!v)return this;d7(this,S)}}if(this._hasPause&&!this._forcing&&this._lock<2&&(x=ufe(this,Lr(o),Lr(h)),x&&(c-=h-(h=x._start))),this._tTime=c,this._time=h,this._act=!_,this._initted||(this._onUpdate=this.vars.onUpdate,this._initted=1,this._zTime=n,o=0),!o&&c&&u&&!a&&!w&&(ga(this,"onStart"),this._tTime!==c))return this;if(h>=o&&n>=0)for(f=this._first;f;){if(p=f._next,(f._act||h>=f._start)&&f._ts&&x!==f){if(f.parent!==this)return this.render(n,a,s);if(f.render(f._ts>0?(h-f._start)*f._ts:(f._dirty?f.totalDuration():f._tDur)+(h-f._start)*f._ts,a,s),h!==this._time||!this._ts&&!v){x=0,p&&(c+=this._zTime=-dr);break}}f=p}else{f=this._last;for(var I=n<0?n:h;f;){if(p=f._prev,(f._act||I<=f._end)&&f._ts&&x!==f){if(f.parent!==this)return this.render(n,a,s);if(f.render(f._ts>0?(I-f._start)*f._ts:(f._dirty?f.totalDuration():f._tDur)+(I-f._start)*f._ts,a,s||Hi&&u$(f)),h!==this._time||!this._ts&&!v){x=0,p&&(c+=this._zTime=I?-dr:dr);break}}f=p}}if(x&&!a&&(this.pause(),x.render(h>=o?0:-dr)._zTime=h>=o?1:-1,this._ts))return this._start=y,j1(this),this.render(n,a,s);this._onUpdate&&!a&&ga(this,"onUpdate",!0),(c===l&&this._tTime>=this.totalDuration()||!c&&o)&&(y===this._start||Math.abs(_)!==Math.abs(this._ts))&&(this._lock||((n||!u)&&(c===l&&this._ts>0||!c&&this._ts<0)&&nu(this,1),!a&&!(n<0&&!o)&&(c||o||!l)&&(ga(this,c===l&&n>=0?"onComplete":"onReverseComplete",!0),this._prom&&!(c<l&&this.timeScale()>0)&&this._prom())))}return this},r.add=function(n,a){var s=this;if(sl(a)||(a=La(this,a,n)),!(n instanceof gm)){if(hn(n))return n.forEach(function(o){return s.add(o,a)}),this;if(Pi(n))return this.addLabel(n,a);if(Yr(n))n=oi.delayedCall(0,n);else return this}return this!==n?Ys(this,n,a):this},r.getChildren=function(n,a,s,o){n===void 0&&(n=!0),a===void 0&&(a=!0),s===void 0&&(s=!0),o===void 0&&(o=-Za);for(var l=[],u=this._first;u;)u._start>=o&&(u instanceof oi?a&&l.push(u):(s&&l.push(u),n&&l.push.apply(l,u.getChildren(!0,a,s)))),u=u._next;return l},r.getById=function(n){for(var a=this.getChildren(1,1,1),s=a.length;s--;)if(a[s].vars.id===n)return a[s]},r.remove=function(n){return Pi(n)?this.removeLabel(n):Yr(n)?this.killTweensOf(n):(n.parent===this&&B1(this,n),n===this._recent&&(this._recent=this._last),ic(this))},r.totalTime=function(n,a){return arguments.length?(this._forcing=1,!this._dp&&this._ts&&(this._start=Lr(ha.time-(this._ts>0?n/this._ts:(this.totalDuration()-n)/-this._ts))),e.prototype.totalTime.call(this,n,a),this._forcing=0,this):this._tTime},r.addLabel=function(n,a){return this.labels[n]=La(this,a),this},r.removeLabel=function(n){return delete this.labels[n],this},r.addPause=function(n,a,s){var o=oi.delayedCall(0,a||fm,s);return o.data="isPause",this._hasPause=1,Ys(this,o,La(this,n))},r.removePause=function(n){var a=this._first;for(n=La(this,n);a;)a._start===n&&a.data==="isPause"&&nu(a),a=a._next},r.killTweensOf=function(n,a,s){for(var o=this.getTweensOf(n,s),l=o.length;l--;)zl!==o[l]&&o[l].kill(n,a);return this},r.getTweensOf=function(n,a){for(var s=[],o=Ka(n),l=this._first,u=sl(a),c;l;)l instanceof oi?rfe(l._targets,o)&&(u?(!zl||l._initted&&l._ts)&&l.globalTime(0)<=a&&l.globalTime(l.totalDuration())>a:!a||l.isActive())&&s.push(l):(c=l.getTweensOf(o,a)).length&&s.push.apply(s,c),l=l._next;return s},r.tweenTo=function(n,a){a=a||{};var s=this,o=La(s,n),l=a,u=l.startAt,c=l.onStart,d=l.onStartParams,h=l.immediateRender,f,p=oi.to(s,Ta({ease:a.ease||"none",lazy:!1,immediateRender:!1,time:o,overwrite:"auto",duration:a.duration||Math.abs((o-(u&&"time"in u?u.time:s._time))/s.timeScale())||dr,onStart:function(){if(s.pause(),!f){var g=a.duration||Math.abs((o-(u&&"time"in u?u.time:s._time))/s.timeScale());p._dur!==g&&Sh(p,g,0,1).render(p._time,!0,!0),f=1}c&&c.apply(p,d||[])}},a));return h?p.render(0):p},r.tweenFromTo=function(n,a,s){return this.tweenTo(a,Ta({startAt:{time:La(this,n)}},s))},r.recent=function(){return this._recent},r.nextLabel=function(n){return n===void 0&&(n=this._time),SC(this,La(this,n))},r.previousLabel=function(n){return n===void 0&&(n=this._time),SC(this,La(this,n),1)},r.currentLabel=function(n){return arguments.length?this.seek(n,!0):this.previousLabel(this._time+dr)},r.shiftChildren=function(n,a,s){s===void 0&&(s=0);var o=this._first,l=this.labels,u;for(n=Lr(n);o;)o._start>=s&&(o._start+=n,o._end+=n),o=o._next;if(a)for(u in l)l[u]>=s&&(l[u]+=n);return ic(this)},r.invalidate=function(n){var a=this._first;for(this._lock=0;a;)a.invalidate(n),a=a._next;return e.prototype.invalidate.call(this,n)},r.clear=function(n){n===void 0&&(n=!0);for(var a=this._first,s;a;)s=a._next,this.remove(a),a=s;return this._dp&&(this._time=this._tTime=this._pTime=0),n&&(this.labels={}),ic(this)},r.totalDuration=function(n){var a=0,s=this,o=s._last,l=Za,u,c,d;if(arguments.length)return s.timeScale((s._repeat<0?s.duration():s.totalDuration())/(s.reversed()?-n:n));if(s._dirty){for(d=s.parent;o;)u=o._prev,o._dirty&&o.totalDuration(),c=o._start,c>l&&s._sort&&o._ts&&!s._lock?(s._lock=1,Ys(s,o,c-o._delay,1)._lock=0):l=c,c<0&&o._ts&&(a-=c,(!d&&!s._dp||d&&d.smoothChildTiming)&&(s._start+=Lr(c/s._ts),s._time-=c,s._tTime-=c),s.shiftChildren(-c,!1,-1/0),l=0),o._end>a&&o._ts&&(a=o._end),o=u;Sh(s,s===Fr&&s._time>a?s._time:a,1,1),s._dirty=0}return s._tDur},t.updateRoot=function(n){if(Fr._ts&&(GD(Fr,hy(n,Fr)),VD=ha.frame),ha.frame>=bC){bC+=wa.autoSleep||120;var a=Fr._first;if((!a||!a._ts)&&wa.autoSleep&&ha._listeners.length<2){for(;a&&!a._ts;)a=a._next;a||ha.sleep()}}},t})(gm);Ta(Pn.prototype,{_lock:0,_hasPause:0,_forcing:0});var Tfe=function(t,r,i,n,a,s,o){var l=new Jn(this._pt,t,r,0,1,v7,null,a),u=0,c=0,d,h,f,p,m,g,v,x;for(l.b=i,l.e=n,i+="",n+="",(v=~n.indexOf("random("))&&(n=pm(n)),s&&(x=[i,n],s(x,t,r),i=x[0],n=x[1]),h=i.match(eb)||[];d=eb.exec(n);)p=d[0],m=n.substring(u,d.index),f?f=(f+1)%5:m.substr(-5)==="rgba("&&(f=1),p!==h[c++]&&(g=parseFloat(h[c-1])||0,l._pt={_next:l._pt,p:m||c===1?m:",",s:g,c:p.charAt(1)==="="?Vd(g,p)-g:parseFloat(p)-g,m:f&&f<4?Math.round:0},u=eb.lastIndex);return l.c=u<n.length?n.substring(u,n.length):"",l.fp=o,(ND.test(n)||v)&&(l.e=0),this._pt=l,l},c$=function(t,r,i,n,a,s,o,l,u,c){Yr(n)&&(n=n(a||0,t,s));var d=t[r],h=i!=="get"?i:Yr(d)?u?t[r.indexOf("set")||!Yr(t["get"+r.substr(3)])?r:"get"+r.substr(3)](u):t[r]():d,f=Yr(d)?u?Mfe:_7:h$,p;if(Pi(n)&&(~n.indexOf("random(")&&(n=pm(n)),n.charAt(1)==="="&&(p=Vd(h,n)+(on(h)||0),(p||p===0)&&(n=p))),!c||h!==n||yx)return!isNaN(h*n)&&n!==""?(p=new Jn(this._pt,t,r,+h||0,n-(h||0),typeof d=="boolean"?Afe:y7,0,f),u&&(p.fp=u),o&&p.modifier(o,this,t),this._pt=p):(!d&&!(r in t)&&a$(r,n),Tfe.call(this,t,r,h,n,f,l||wa.stringFilter,u))},Cfe=function(t,r,i,n,a){if(Yr(t)&&(t=gp(t,a,r,i,n)),!lo(t)||t.style&&t.nodeType||hn(t)||FD(t))return Pi(t)?gp(t,a,r,i,n):t;var s={},o;for(o in t)s[o]=gp(t[o],a,r,i,n);return s},p7=function(t,r,i,n,a,s){var o,l,u,c;if(ua[t]&&(o=new ua[t]).init(a,o.rawVars?r[t]:Cfe(r[t],n,a,s,i),i,n,s)!==!1&&(i._pt=l=new Jn(i._pt,a,t,0,1,o.render,o,0,o.priority),i!==xd
vendor: 4,309 bytes, line 61
61))for(u=i._ptLookup[i._targets.indexOf(a)],c=o._props.length;c--;)u[o._props[c]]=l;return o},zl,yx,d$=function e(t,r,i){var n=t.vars,a=n.ease,s=n.startAt,o=n.immediateRender,l=n.lazy,u=n.onUpdate,c=n.runBackwards,d=n.yoyoEase,h=n.keyframes,f=n.autoRevert,p=t._dur,m=t._startAt,g=t._targets,v=t.parent,x=v&&v.data==="nested"?v.vars.targets:g,_=t._overwrite==="auto"&&!t$,y=t.timeline,w,$,S,E,C,I,P,T,D,A,z,R,O;if(y&&(!h||!a)&&(a="none"),t._ease=nc(a,xh.ease),t._yEase=d?c7(nc(d===!0?a:d,xh.ease)):0,d&&t._yoyo&&!t._repeat&&(d=t._yEase,t._yEase=t._ease,t._ease=d),t._from=!y&&!!n.runBackwards,!y||h&&!n.stagger){if(T=g[0]?rc(g[0]).harness:0,R=T&&n[T.prop],w=dy(n,s$),m&&(m._zTime<0&&m.progress(1),r<0&&c&&o&&!f?m.render(-1,!0):m.revert(c&&p?Q0:efe),m._lazy=0),s){if(nu(t._startAt=oi.set(g,Ta({data:"isStart",overwrite:!1,parent:v,immediateRender:!0,lazy:!m&&Kn(l),startAt:null,delay:0,onUpdate:u&&function(){return ga(t,"onUpdate")},stagger:0},s))),t._startAt._dp=0,t._startAt._sat=t,r<0&&(Hi||!o&&!f)&&t._startAt.revert(Q0),o&&p&&r<=0&&i<=0){r&&(t._zTime=r);return}}else if(c&&p&&!m){if(r&&(o=!1),S=Ta({overwrite:!1,data:"isFromStart",lazy:o&&!m&&Kn(l),immediateRender:o,stagger:0,parent:v},w),R&&(S[T.prop]=R),nu(t._startAt=oi.set(g,S)),t._startAt._dp=0,t._startAt._sat=t,r<0&&(Hi?t._startAt.revert(Q0):t._startAt.render(-1,!0)),t._zTime=r,!o)e(t._startAt,dr,dr);else if(!r)return}for(t._pt=t._ptCache=0,l=p&&Kn(l)||l&&!p,$=0;$<g.length;$++){if(C=g[$],P=C._gsap||l$(g)[$]._gsap,t._ptLookup[$]=A={},hx[P.id]&&Zl.length&&cy(),z=x===g?$:x.indexOf(C),T&&(D=new T).init(C,R||w,t,z,x)!==!1&&(t._pt=E=new Jn(t._pt,C,D.name,0,1,D.render,D,0,D.priority),D._props.forEach(function(V){A[V]=E}),D.priority&&(I=1)),!T||R)for(S in w)ua[S]&&(D=p7(S,w,t,z,C,x))?D.priority&&(I=1):A[S]=E=c$.call(t,C,S,"get",w[S],z,x,0,n.stringFilter);t._op&&t._op[$]&&t.kill(C,t._op[$]),_&&t._pt&&(zl=t,Fr.killTweensOf(C,A,t.globalTime(r)),O=!t.parent,zl=0),t._pt&&l&&(hx[P.id]=1)}I&&b7(t),t._onInit&&t._onInit(t)}t._onUpdate=u,t._initted=(!t._op||t._pt)&&!O,h&&r<=0&&y.render(Za,!0,!0)},kfe=function(t,r,i,n,a,s,o,l){var u=(t._pt&&t._ptCache||(t._ptCache={}))[r],c,d,h,f;if(!u)for(u=t._ptCache[r]=[],h=t._ptLookup,f=t._targets.length;f--;){if(c=h[f][r],c&&c.d&&c.d._pt)for(c=c.d._pt;c&&c.p!==r&&c.fp!==r;)c=c._next;if(!c)return yx=1,t.vars[r]="+=0",d$(t,o),yx=0,l?hm(r+" not eligible for reset"):1;u.push(c)}for(f=u.length;f--;)d=u[f],c=d._pt||d,c.s=(n||n===0)&&!a?n:c.s+(n||0)+s*c.c,c.c=i-c.s,d.e&&(d.e=Qr(i)+on(d.e)),d.b&&(d.b=c.s+on(d.b))},Efe=function(t,r){var i=t[0]?rc(t[0]).harness:0,n=i&&i.aliases,a,s,o,l;if(!n)return r;a=wh({},r);for(s in n)if(s in a)for(l=n[s].split(","),o=l.length;o--;)a[l[o]]=a[s];return a},Pfe=function(t,r,i,n){var a=r.ease||n||"power1.inOut",s,o;if(hn(r))o=i[t]||(i[t]=[]),r.forEach(function(l,u){return o.push({t:u/(r.length-1)*100,v:l,e:a})});else for(s in r)o=i[s]||(i[s]=[]),s==="ease"||o.push({t:parseFloat(t),v:r[s],e:a})},gp=function(t,r,i,n,a){return Yr(t)?t.call(r,i,n,a):Pi(t)&&~t.indexOf("random(")?pm(t):t},m7=o$+"repeat,repeatDelay,yoyo,repeatRefresh,yoyoEase,autoRevert",g7={};Xn(m7+",id,stagger,delay,duration,paused,scrollTrigger",function(e){return g7[e]=1});var oi=(function(e){OD(t,e);function t(i,n,a,s){var o;typeof n=="number"&&(a.duration=n,n=a,a=null),o=e.call(this,s?n:pp(n))||this;var l=o.vars,u=l.duration,c=l.delay,d=l.immediateRender,h=l.stagger,f=l.overwrite,p=l.keyframes,m=l.defaults,g=l.scrollTrigger,v=l.yoyoEase,x=n.parent||Fr,_=(hn(i)||FD(i)?sl(i[0]):"length"in n)?[i]:Ka(i),y,w,$,S,E,C,I,P;if(o._targets=_.length?l$(_):hm("GSAP target "+i+" not found. https://gsap.com",!wa.nullTargetWarn)||[],o._ptLookup=[],o._overwrite=f,p||h||Wg(u)||Wg(c)){if(n=o.vars,y=o.timeline=new Pn({data:"nested",defaults:m||{},targets:x&&x.data==="nested"?x.vars.targets:_}),y.kill(),y.parent=y._dp=To(o),y._start=0,h||Wg(u)||Wg(c)){if(S=_.length,I=h&&e7(h),lo(h))for(E in h)~m7.indexOf(E)&&(P||(P={}),P[E]=h[E]);for(w=0;w<S;w++)$=dy(n,g7),$.stagger=0,v&&($.yoyoEase=v),P&&wh($,P),C=_[w],$.duration=+gp(u,To(o),w,C,_),$.delay=(+gp(c,To(o),w,C,_)||0)-o._delay,!h&&S===1&&$.delay&&(o._delay=c=$.delay,o._start+=c,$.delay=0),y.to(C,$,I?I(w,C,_):0),y._ease=Bt.none;y.duration()?u=c=0:o.timeline=0}else if(p){pp(Ta(y.vars.defaults,{ease:"none"})),y._ease=nc(p.ease||n.ease||"none");var T=0,D,A,z;
vendor: 15,427 bytes, lines 61-68
61if(hn(p))p.forEach(function(R){return y.to(_,R,">")}),y.duration();else{$={};for(E in p)E==="ease"||E==="easeEach"||Pfe(E,p[E],$,p.easeEach);for(E in $)for(D=$[E].sort(function(R,O){return R.t-O.t}),T=0,w=0;w<D.length;w++)A=D[w],z={ease:A.e,duration:(A.t-(w?D[w-1].t:0))/100*u},z[E]=A.v,y.to(_,z,T),T+=z.duration;y.duration()<u&&y.to({},{duration:u-y.duration()})}}u||o.duration(u=y.duration())}else o.timeline=0;return f===!0&&!t$&&(zl=To(o),Fr.killTweensOf(_),zl=0),Ys(x,To(o),a),n.reversed&&o.reverse(),n.paused&&o.paused(!0),(d||!u&&!p&&o._start===Lr(x._time)&&Kn(d)&&sfe(To(o))&&x.data!=="nested")&&(o._tTime=-dr,o.render(Math.max(0,-c)||0)),g&&KD(To(o),g),o}var r=t.prototype;return r.render=function(n,a,s){var o=this._time,l=this._tDur,u=this._dur,c=n<0,d=n>l-dr&&!c?l:n<dr?0:n,h,f,p,m,g,v,x,_,y;if(!u)lfe(this,n,a,s);else if(d!==this._tTime||!n||s||!this._initted&&this._tTime||this._startAt&&this._zTime<0!==c||this._lazy){if(h=d,_=this.timeline,this._repeat){if(m=u+this._rDelay,this._repeat<-1&&c)return this.totalTime(m*100+n,a,s);if(h=Lr(d%m),d===l?(p=this._repeat,h=u):(g=Lr(d/m),p=~~g,p&&p===g?(h=u,p--):h>u&&(h=u)),v=this._yoyo&&p&1,v&&(y=this._yEase,h=u-h),g=$h(this._tTime,m),h===o&&!s&&this._initted&&p===g)return this._tTime=d,this;p!==g&&(_&&this._yEase&&d7(_,v),this.vars.repeatRefresh&&!v&&!this._lock&&h!==m&&this._initted&&(this._lock=s=1,this.render(Lr(m*p),!0).invalidate()._lock=0))}if(!this._initted){if(XD(this,c?n:h,s,a,d))return this._tTime=0,this;if(o!==this._time&&!(s&&this.vars.repeatRefresh&&p!==g))return this;if(u!==this._dur)return this.render(n,a,s)}if(this._tTime=d,this._time=h,!this._act&&this._ts&&(this._act=1,this._lazy=0),this.ratio=x=(y||this._ease)(h/u),this._from&&(this.ratio=x=1-x),!o&&d&&!a&&!g&&(ga(this,"onStart"),this._tTime!==d))return this;for(f=this._pt;f;)f.r(x,f.d),f=f._next;_&&_.render(n<0?n:_._dur*_._ease(h/this._dur),a,s)||this._startAt&&(this._zTime=n),this._onUpdate&&!a&&(c&&fx(this,n,a,s),ga(this,"onUpdate")),this._repeat&&p!==g&&this.vars.onRepeat&&!a&&this.parent&&ga(this,"onRepeat"),(d===this._tDur||!d)&&this._tTime===d&&(c&&!this._onUpdate&&fx(this,n,!0,!0),(n||!u)&&(d===this._tDur&&this._ts>0||!d&&this._ts<0)&&nu(this,1),!a&&!(c&&!o)&&(d||o||v)&&(ga(this,d===l?"onComplete":"onReverseComplete",!0),this._prom&&!(d<l&&this.timeScale()>0)&&this._prom()))}return this},r.targets=function(){return this._targets},r.invalidate=function(n){return(!n||!this.vars.runBackwards)&&(this._startAt=0),this._pt=this._op=this._onUpdate=this._lazy=this.ratio=0,this._ptLookup=[],this.timeline&&this.timeline.invalidate(n),e.prototype.invalidate.call(this,n)},r.resetTo=function(n,a,s,o,l){mm||ha.wake(),this._ts||this.play();var u=Math.min(this._dur,(this._dp._time-this._start)*this._ts),c;return this._initted||d$(this,u),c=this._ease(u/this._dur),kfe(this,n,a,s,o,c,u,l)?this.resetTo(n,a,s,o,1):(U1(this,0),this.parent||WD(this._dp,this,"_first","_last",this._dp._sort?"_start":0),this.render(0))},r.kill=function(n,a){if(a===void 0&&(a="all"),!n&&(!a||a==="all"))return this._lazy=this._pt=0,this.parent?Vf(this):this.scrollTrigger&&this.scrollTrigger.kill(!!Hi),this;if(this.timeline){var s=this.timeline.totalDuration();return this.timeline.killTweensOf(n,a,zl&&zl.vars.overwrite!==!0)._first||Vf(this),this.parent&&s!==this.timeline.totalDuration()&&Sh(this,this._dur*this.timeline._tDur/s,0,1),this}var o=this._targets,l=n?Ka(n):o,u=this._ptLookup,c=this._pt,d,h,f,p,m,g,v;if((!a||a==="all")&&nfe(o,l))return a==="all"&&(this._pt=0),Vf(this);for(d=this._op=this._op||[],a!=="all"&&(Pi(a)&&(m={},Xn(a,function(x){return m[x]=1}),a=m),a=Efe(o,a)),v=o.length;v--;)if(~l.indexOf(o[v])){h=u[v],a==="all"?(d[v]=a,p=h,f={}):(f=d[v]=d[v]||{},p=a);for(m in p)g=h&&h[m],g&&((!("kill"in g.d)||g.d.kill(m)===!0)&&B1(this,g,"_pt"),delete h[m]),f!=="all"&&(f[m]=1)}return this._initted&&!this._pt&&c&&Vf(this),this},t.to=function(n,a){return new t(n,a,arguments[2])},t.from=function(n,a){return mp(1,arguments)},t.delayedCall=function(n,a,s,o){return new t(a,0,{immediateRender:!1,lazy:!1,overwrite:!1,delay:n,onComplete:a,onReverseComplete:a,onCompleteParams:s,onReverseCompleteParams:s,callbackScope:o})},t.fromTo=function(n,a,s){return mp(2,arguments)},t.set=function(n,a){return a.duration=0,a.repeatDelay||(a.repeat=0),new t(n,a)},t.killTweensOf=function(n,a,s){return Fr.killTweensOf(n,a,s)},t})(gm);Ta(oi.prototype,{_targets:[],_lazy:0,_startAt:0,_op:0,_onInit:0});Xn("staggerTo,staggerFrom,staggerFromTo",function(e){oi[e]=function(){var t=new Pn,r=mx.call(arguments,0);return r.splice(e==="staggerFromTo"?5:4,0,0),t[e].apply(t,r)}});var h$=function(t,r,i){return t[r]=i},_7=function(t,r,i){return t[r](i)},Mfe=function(t,r,i,n){return t[r](n.fp,i)},Ife=function(t,r,i){return t.setAttribute(r,i)},f$=function(t,r){return Yr(t[r])?_7:r$(t[r])&&t.setAttribute?Ife:h$},y7=function(t,r){return r.set(r.t,r.p,Math.round((r.s+r.c*t)*1e6)/1e6,r)},Afe=function(t,r){return r.set(r.t,r.p,!!(r.s+r.c*t),r)},v7=function(t,r){var i=r._pt,n="";if(!t&&r.b)n=r.b;else if(t===1&&r.e)n=r.e;else{for(;i;)n=i.p+(i.m?i.m(i.s+i.c*t):Math.round((i.s+i.c*t)*1e4)/1e4)+n,i=i._next;n+=r.c}r.set(r.t,r.p,n,r)},p$=function(t,r){for(var i=r._pt;i;)i.r(t,i.d),i=i._next},Dfe=function(t,r,i,n){for(var a=this._pt,s;a;)s=a._next,a.p===n&&a.modifier(t,r,i),a=s},Rfe=function(t){for(var r=this._pt,i,n;r;)n=r._next,r.p===t&&!r.op||r.op===t?B1(this,r,"_pt"):r.dep||(i=1),r=n;return!i},Ofe=function(t,r,i,n){n.mSet(t,r,n.m.call(n.tween,i,n.mt),n)},b7=function(t){for(var r=t._pt,i,n,a,s;r;){for(i=r._next,n=a;n&&n.pr>r.pr;)n=n._next;(r._prev=n?n._prev:s)?r._prev._next=r:a=r,(r._next=n)?n._prev=r:s=r,r=i}t._pt=a},Jn=(function(){function e(r,i,n,a,s,o,l,u,c){this.t=i,this.s=a,this.c=s,this.p=n,this.r=o||y7,this.d=l||this,this.set=u||h$,this.pr=c||0,this._next=r,r&&(r._prev=this)}var t=e.prototype;return t.modifier=function(i,n,a){this.mSet=this.mSet||this.set,this.set=Ofe,this.m=i,this.mt=a,this.tween=n},e})();Xn(o$+"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 s$[e]=1});Sa.TweenMax=Sa.TweenLite=oi;Sa.TimelineLite=Sa.TimelineMax=Pn;Fr=new Pn({sortChildren:!1,defaults:xh,autoRemoveChildren:!0,id:"root",smoothChildTiming:!0});wa.stringFilter=u7;var ac=[],t_={},Lfe=[],CC=0,Ffe=0,ab=function(t){return(t_[t]||Lfe).map(function(r){return r()})},vx=function(){var t=Date.now(),r=[];t-CC>2&&(ab("matchMediaInit"),ac.forEach(function(i){var n=i.queries,a=i.conditions,s,o,l,u;for(o in n)s=Us.matchMedia(n[o]).matches,s&&(l=1),s!==a[o]&&(a[o]=s,u=1);u&&(i.revert(),l&&r.push(i))}),ab("matchMediaRevert"),r.forEach(function(i){return i.onMatch(i,function(n){return i.add(null,n)})}),CC=t,ab("matchMedia"))},x7=(function(){function e(r,i){this.selector=i&&gx(i),this.data=[],this._r=[],this.isReverted=!1,this.id=Ffe++,r&&this.add(r)}var t=e.prototype;return t.add=function(i,n,a){Yr(i)&&(a=n,n=i,i=Yr);var s=this,o=function(){var u=Ir,c=s.selector,d;return u&&u!==s&&u.data.push(s),a&&(s.selector=gx(a)),Ir=s,d=n.apply(s,arguments),Yr(d)&&s._r.push(d),Ir=u,s.selector=c,s.isReverted=!1,d};return s.last=o,i===Yr?o(s,function(l){return s.add(null,l)}):i?s[i]=o:o},t.ignore=function(i){var n=Ir;Ir=null,i(this),Ir=n},t.getTweens=function(){var i=[];return this.data.forEach(function(n){return n instanceof e?i.push.apply(i,n.getTweens()):n instanceof oi&&!(n.parent&&n.parent.data==="nested")&&i.push(n)}),i},t.clear=function(){this._r.length=this.data.length=0},t.kill=function(i,n){var a=this;if(i?(function(){for(var o=a.getTweens(),l=a.data.length,u;l--;)u=a.data[l],u.data==="isFlip"&&(u.revert(),u.getChildren(!0,!0,!1).forEach(function(c){return o.splice(o.indexOf(c),1)}));for(o.map(function(c){return{g:c._dur||c._delay||c._sat&&!c._sat.vars.immediateRender?c.globalTime(0):-1/0,t:c}}).sort(function(c,d){return d.g-c.g||-1/0}).forEach(function(c){return c.t.revert(i)}),l=a.data.length;l--;)u=a.data[l],u instanceof Pn?u.data!=="nested"&&(u.scrollTrigger&&u.scrollTrigger.revert(),u.kill()):!(u instanceof oi)&&u.revert&&u.revert(i);a._r.forEach(function(c){return c(i,a)}),a.isReverted=!0})():this.data.forEach(function(o){return o.kill&&o.kill()}),this.clear(),n)for(var s=ac.length;s--;)ac[s].id===this.id&&ac.splice(s,1)},t.revert=function(i){this.kill(i||{})},e})(),zfe=(function(){function e(r){this.contexts=[],this.scope=r,Ir&&Ir.data.push(this)}var t=e.prototype;return t.add=function(i,n,a){lo(i)||(i={matches:i});var s=new x7(0,a||this.scope),o=s.conditions={},l,u,c;Ir&&!s.selector&&(s.selector=Ir.selector),this.contexts.push(s),n=s.add("onMatch",n),s.queries=i;for(u in i)u==="all"?c=1:(l=Us.matchMedia(i[u]),l&&(ac.indexOf(s)<0&&ac.push(s),(o[u]=l.matches)&&(c=1),l.addListener?l.addListener(vx):l.addEventListener("change",vx)));return c&&n(s,function(d){return s.add(null,d)}),this},t.revert=function(i){this.kill(i||{})},t.kill=function(i){this.contexts.forEach(function(n){return n.kill(i,!0)})},e})(),fy={registerPlugin:function(){for(var t=arguments.length,r=new Array(t),i=0;i<t;i++)r[i]=arguments[i];r.forEach(function(n){return s7(n)})},timeline:function(t){return new Pn(t)},getTweensOf:function(t,r){return Fr.getTweensOf(t,r)},getProperty:function(t,r,i,n){Pi(t)&&(t=Ka(t)[0]);var a=rc(t||{}).get,s=i?YD:HD;return i==="native"&&(i=""),t&&(r?s((ua[r]&&ua[r].get||a)(t,r,i,n)):function(o,l,u){return s((ua[o]&&ua[o].get||a)(t,o,l,u))})},quickSetter:function(t,r,i){if(t=Ka(t),t.length>1){var n=t.map(function(c){return ta.quickSetter(c,r,i)}),a=n.length;return function(c){for(var d=a;d--;)n[d](c)}}t=t[0]||{};var s=ua[r],o=rc(t),l=o.harness&&(o.harness.aliases||{})[r]||r,u=s?function(c){var d=new s;xd._pt=0,d.init(t,i?c+i:c,xd,0,[t]),d.render(1,d),xd._pt&&p$(1,xd)}:o.set(t,l);return s?u:function(c){return u(t,l,i?c+i:c,o,1)}},quickTo:function(t,r,i){var n,a=ta.to(t,Ta((n={},n[r]="+=0.1",n.paused=!0,n.stagger=0,n),i||{})),s=function(l,u,c){return a.resetTo(r,l,u,c)};return s.tween=a,s},isTweening:function(t){return Fr.getTweensOf(t,!0).length>0},defaults:function(t){return t&&t.ease&&(t.ease=nc(t.ease,xh.ease)),xC(xh,t||{})},config:function(t){return xC(wa,t||{})},registerEffect:function(t){var r=t.name,i=t.effect,n=t.plugins,a=t.defaults,s=t.extendTimeline;(n||"").split(",").forEach(function(o){return o&&!ua[o]&&!Sa[o]&&hm(r+" effect requires "+o+" plugin.")}),tb[r]=function(o,l,u){return i(Ka(o),Ta(l||{},a),u)},s&&(Pn.prototype[r]=function(o,l,u){return this.add(tb[r](o,lo(l)?l:(u=l)&&{},this),u)})},registerEase:function(t,r){Bt[t]=nc(r)},parseEase:function(t,r){return arguments.length?nc(t,r):Bt},getById:function(t){return Fr.getById(t)},exportRoot:function(t,r){t===void 0&&(t={});var i=new Pn(t),n,a;for(i.smoothChildTiming=Kn(t.smoothChildTiming),Fr.remove(i),i._dp=0,i._time=i._tTime=Fr._time,n=Fr._first;n;)a=n._next,(r||!(!n._dur&&n instanceof oi&&n.vars.onComplete===n._targets[0]))&&Ys(i,n,n._start-n._delay),n=a;return Ys(Fr,i,0),i},context:function(t,r){return t?new x7(t,r):Ir},matchMedia:function(t){return new zfe(t)},matchMediaRefresh:function(){return ac.forEach(function(t){var r=t.conditions,i,n;for(n in r)r[n]&&(r[n]=!1,i=1);i&&t.revert()})||vx()},addEventListener:function(t,r){var i=t_[t]||(t_[t]=[]);~i.indexOf(r)||i.push(r)},removeEventListener:function(t,r){var i=t_[t],n=i&&i.indexOf(r);n>=0&&i.splice(n,1)},utils:{wrap:gfe,wrapYoyo:_fe,distribute:e7,random:r7,snap:t7,normalize:mfe,getUnit:on,clamp:dfe,splitColor:o7,toArray:Ka,selector:gx,mapRange:n7,pipe:ffe,unitize:pfe,interpolate:yfe,shuffle:QD},install:jD,effects:tb,ticker:ha,updateRoot:Pn.updateRoot,plugins:ua,globalTimeline:Fr,core:{PropTween:Jn,globals:UD,Tween:oi,Timeline:Pn,Animation:gm,getCache:rc,_removeLinkedListItem:B1,reverting:function(){return Hi},context:function(t){return t&&Ir&&(Ir.data.push(t),t._ctx=Ir),Ir},suppressOverwrites:function(t){return t$=t}}};Xn("to,from,fromTo,delayedCall,set,killTweensOf",function(e){return fy[e]=oi[e]});ha.add(Pn.updateRoot);xd=fy.to({},{duration:0});var Nfe=function(t,r){for(var i=t._pt;i&&i.p!==r&&i.op!==r&&i.fp!==r;)i=i._next;return i},Bfe=function(t,r){var i=t._targets,n,a,s;for(n in r)for(a=i.length;a--;)s=t._ptLookup[a][n],s&&(s=s.d)&&(s._pt&&(s=Nfe(s,n)),s&&s.modifier&&s.modifier(r[n],t,i[a],n))},sb=function(t,r){return{name:t,headless:1,rawVars:1,init:function(n,a,s){s._onInit=function(o){var l,u;if(Pi(a)&&(l={},Xn(a,function(c){return l[c]=1}),a=l),r){l={};for(u in a)l[u]=r(a[u]);a=l}Bfe(o,a)}}}},ta=fy.registerPlugin({name:"attr",init:function(t,r,i,n,a){var s,o,l;this.tween=i;for(s in r)l=t.getAttribute(s)||"",o=this.add(t,"setAttribute",(l||0)+"",r[s],n,a,0,0,s),o.op=s,o.b=l,this._props.push(s)},render:function(t,r){for(var i=r._pt;i;)Hi?i.set(i.t,i.p,i.b,i):i.r(t,i.d),i=i._next}},{name:"endArray",headless:1,init:function(t,r){for(var i=r.length;i--;)this.add(t,i,t[i]||0,r[i],0,0,0,0,0,1)}},sb("roundProps",_x),sb("modifiers"),sb("snap",t7))||fy;oi.version=Pn.version=ta.version="3.14.2";BD=1;i$()&&Th();Bt.Power0;Bt.Power1;Bt.Power2;Bt.Power3;Bt.Power4;Bt.Linear;Bt.Quad;Bt.Cubic;Bt.Quart;Bt.Quint;Bt.Strong;Bt.Elastic;Bt.Back;Bt.SteppedEase;Bt.Bounce;Bt.Sine;Bt.Expo;Bt.Circ;/*! 62 * CSSPlugin 3.14.2 63 * https://gsap.com 64 * 65 * Copyright 2008-2025, GreenSock. All rights reserved. 66 * Subject to the terms at https://gsap.com/standard-license 67 * @author: Jack Doyle, [email protected] 68*/var kC,Nl,qd,m$,Bu,EC,g$,jfe=function(){return typeof window<"u"},ol={},Pu=180/Math.PI,Gd=Math.PI/180,Zc=Math.atan2,PC=1e8,_$=/([A-Z])/g,Ufe=/(left|right|width|margin|padding|x)/i,Vfe=/[\s,\(]\S/,Xs={autoAlpha:"opacity,visibility",scale:"scaleX,scaleY",alpha:"opacity"},bx=function(t,r){return r.set(r.t,r.p,Math.round((r.s+r.c*t)*1e4)/1e4+r.u,r)},qfe=function(t,r){return r.set(r.t,r.p,t===1?r.e:Math.round((r.s+r.c*t)*1e4)/1e4+r.u,r)},Gfe=function(t,r){return r.set(r.t,r.p,t?Math.round((r.s+r.c*t)*1e4)/1e4+r.u:r.b,r)},Hfe=function(t,r){return r.set(r.t,r.p,t===1?r.e:t?Math.round((r.s+r.c*t)*1e4)/1e4+r.u:r.b,r)},Yfe=function(t,r){var i=r.s+r.c*t;r.set(r.t,r.p,~~(i+(i<0?-.5:.5))+r.u,r)},w7=function(t,r){return r.set(r.t,r.p,t?r.e:r.b,r)},$7=function(t,r){return r.set(r.t,r.p,t!==1?r.b:r.e,r)},Wfe=function(t,r,i){return t.style[r]=i},Zfe=function(t,r,i){return t.style.setProperty(r,i)},Kfe=function(t,r,i){return t._gsap[r]=i},Xfe=function(t,r,i){return t._gsap.scaleX=t._gsap.scaleY=i},Jfe=function(t,r,i,n,a){var s=t._gsap;s.scaleX=s.scaleY=i,s.renderTransform(a,s)},Qfe=function(t,r,i,n,a){var s=t._gsap;s[r]=i,s.renderTransform(a,s)},Nr="transform",Qn=Nr+"Origin",epe=function e(t,r){var i=this,n=this.target,a=n.style,s=n._gsap;if(t in ol&&a){if(this.tfm=this.tfm||{},t!=="transform")t=Xs[t]||t,~t.indexOf(",")?t.split(",").forEach(function(o){return i.tfm[o]=Eo(n,o)}):this.tfm[t]=s.x?s[t]:Eo(n,t),t===Qn&&(this.tfm.zOrigin=s.zOrigin);else return Xs.transform.split(",").forEach(function(o){return e.call(i,o,r)});if(this.props.indexOf(Nr)>=0)return;s.svg&&(this.svgo=n.getAttribute("data-svg-origin"),this.props.push(Qn,r,"")),t=Nr}(a||r)&&this.props.push(t,r,a[t])},S7=function(t){t.translate&&(t.removeProperty("translate"),t.removeProperty("scale"),t.removeProperty("rotate"))},tpe=function(){var t=this.props,r=this.target,i=r.style,n=r._gsap,a,s;for(a=0;a<t.length;a+=3)t[a+1]?t[a+1]===2?r[t[a]](t[a+2]):r[t[a]]=t[a+2]:t[a+2]?i[t[a]]=t[a+2]:i.removeProperty(t[a
vendor: 6,525 bytes, line 68
68].substr(0,2)==="--"?t[a]:t[a].replace(_$,"-$1").toLowerCase());if(this.tfm){for(s in this.tfm)n[s]=this.tfm[s];n.svg&&(n.renderTransform(),r.setAttribute("data-svg-origin",this.svgo||"")),a=g$(),(!a||!a.isStart)&&!i[Nr]&&(S7(i),n.zOrigin&&i[Qn]&&(i[Qn]+=" "+n.zOrigin+"px",n.zOrigin=0,n.renderTransform()),n.uncache=1)}},T7=function(t,r){var i={target:t,props:[],revert:tpe,save:epe};return t._gsap||ta.core.getCache(t),r&&t.style&&t.nodeType&&r.split(",").forEach(function(n){return i.save(n)}),i},C7,xx=function(t,r){var i=Nl.createElementNS?Nl.createElementNS((r||"http://www.w3.org/1999/xhtml").replace(/^https/,"http"),t):Nl.createElement(t);return i&&i.style?i:Nl.createElement(t)},_a=function e(t,r,i){var n=getComputedStyle(t);return n[r]||n.getPropertyValue(r.replace(_$,"-$1").toLowerCase())||n.getPropertyValue(r)||!i&&e(t,Ch(r)||r,1)||""},MC="O,Moz,ms,Ms,Webkit".split(","),Ch=function(t,r,i){var n=r||Bu,a=n.style,s=5;if(t in a&&!i)return t;for(t=t.charAt(0).toUpperCase()+t.substr(1);s--&&!(MC[s]+t in a););return s<0?null:(s===3?"ms":s>=0?MC[s]:"")+t},wx=function(){jfe()&&window.document&&(kC=window,Nl=kC.document,qd=Nl.documentElement,Bu=xx("div")||{style:{}},xx("div"),Nr=Ch(Nr),Qn=Nr+"Origin",Bu.style.cssText="border-width:0;line-height:0;position:absolute;padding:0",C7=!!Ch("perspective"),g$=ta.core.reverting,m$=1)},IC=function(t){var r=t.ownerSVGElement,i=xx("svg",r&&r.getAttribute("xmlns")||"http://www.w3.org/2000/svg"),n=t.cloneNode(!0),a;n.style.display="block",i.appendChild(n),qd.appendChild(i);try{a=n.getBBox()}catch{}return i.removeChild(n),qd.removeChild(i),a},AC=function(t,r){for(var i=r.length;i--;)if(t.hasAttribute(r[i]))return t.getAttribute(r[i])},k7=function(t){var r,i;try{r=t.getBBox()}catch{r=IC(t),i=1}return r&&(r.width||r.height)||i||(r=IC(t)),r&&!r.width&&!r.x&&!r.y?{x:+AC(t,["x","cx","x1"])||0,y:+AC(t,["y","cy","y1"])||0,width:0,height:0}:r},E7=function(t){return!!(t.getCTM&&(!t.parentNode||t.ownerSVGElement)&&k7(t))},au=function(t,r){if(r){var i=t.style,n;r in ol&&r!==Qn&&(r=Nr),i.removeProperty?(n=r.substr(0,2),(n==="ms"||r.substr(0,6)==="webkit")&&(r="-"+r),i.removeProperty(n==="--"?r:r.replace(_$,"-$1").toLowerCase())):i.removeAttribute(r)}},Bl=function(t,r,i,n,a,s){var o=new Jn(t._pt,r,i,0,1,s?$7:w7);return t._pt=o,o.b=n,o.e=a,t._props.push(i),o},DC={deg:1,rad:1,turn:1},rpe={grid:1,flex:1},su=function e(t,r,i,n){var a=parseFloat(i)||0,s=(i+"").trim().substr((a+"").length)||"px",o=Bu.style,l=Ufe.test(r),u=t.tagName.toLowerCase()==="svg",c=(u?"client":"offset")+(l?"Width":"Height"),d=100,h=n==="px",f=n==="%",p,m,g,v;if(n===s||!a||DC[n]||DC[s])return a;if(s!=="px"&&!h&&(a=e(t,r,i,"px")),v=t.getCTM&&E7(t),(f||s==="%")&&(ol[r]||~r.indexOf("adius")))return p=v?t.getBBox()[l?"width":"height"]:t[c],Qr(f?a/p*d:a/100*p);if(o[l?"width":"height"]=d+(h?s:n),m=n!=="rem"&&~r.indexOf("adius")||n==="em"&&t.appendChild&&!u?t:t.parentNode,v&&(m=(t.ownerSVGElement||{}).parentNode),(!m||m===Nl||!m.appendChild)&&(m=Nl.body),g=m._gsap,g&&f&&g.width&&l&&g.time===ha.time&&!g.uncache)return Qr(a/g.width*d);if(f&&(r==="height"||r==="width")){var x=t.style[r];t.style[r]=d+n,p=t[c],x?t.style[r]=x:au(t,r)}else(f||s==="%")&&!rpe[_a(m,"display")]&&(o.position=_a(t,"position")),m===t&&(o.position="static"),m.appendChild(Bu),p=Bu[c],m.removeChild(Bu),o.position="absolute";return l&&f&&(g=rc(m),g.time=ha.time,g.width=m[c]),Qr(h?p*a/d:p&&a?d/p*a:0)},Eo=function(t,r,i,n){var a;return m$||wx(),r in Xs&&r!=="transform"&&(r=Xs[r],~r.indexOf(",")&&(r=r.split(",")[0])),ol[r]&&r!=="transform"?(a=ym(t,n),a=r!=="transformOrigin"?a[r]:a.svg?a.origin:my(_a(t,Qn))+" "+a.zOrigin+"px"):(a=t.style[r],(!a||a==="auto"||n||~(a+"").indexOf("calc("))&&(a=py[r]&&py[r](t,r,i)||_a(t,r)||qD(t,r)||(r==="opacity"?1:0))),i&&!~(a+"").trim().indexOf(" ")?su(t,r,a,i)+i:a},ipe=function(t,r,i,n){if(!i||i==="none"){var a=Ch(r,t,1),s=a&&_a(t,a,1);s&&s!==i?(r=a,i=s):r==="borderColor"&&(i=_a(t,"borderTopColor"))}var o=new Jn(this._pt,t.style,r,0,1,v7),l=0,u=0,c,d,h,f,p,m,g,v,x,_,y,w;if(o.b=i,o.e=n,i+="",n+="",n.substring(0,6)==="var(--"&&(n=_a(t,n.substring(4,n.indexOf(")")))),n==="auto"&&(m=t.style[r],t.style[r]=n,n=_a(t,r)||n,m?t.style[r]=m:au(t,r)),c=[i,n],u7(c),i=c[0],n=c[1],h=i.match(bd)||[],w=n.match(bd)||[],w.length){for(;d=bd.exec(n);)g=d[0],x=n.substring(l,d.index),p?p=(p+1)%5:(x.substr(-5)==="rgba("||x.substr(-5)==="hsla(")&&(p=1),g!==(m=h[u++]||"")&&(f=parseFloat(m)||0,y=m.substr((f+"").length),g.charAt(1)==="="&&(g=Vd(f,g)+y),v=parseFloat(g),_=g.substr((v+"").length),l=bd.lastIndex-_.length,_||(_=_||wa.units[r]||y,l===n.length&&(n+=_,o.e+=_)),y!==_&&(f=su(t,r,m,_)||0),o._pt={_next:o._pt,p:x||u===1?x:",",s:f,c:v-f,m:p&&p<4||r==="zIndex"?Math.round:0});o.c=l<n.length?n.substring(l,n.length):""}else o.r=r==="display"&&n==="none"?$7:w7;return ND.test(n)&&(o.e=0),this._pt=o,o},RC={top:"0%",bottom:"100%",left:"0%",right:"100%",center:"50%"},npe=function(t){var r=t.split(" "),i=r[0],n=r[1]||"50%";return(i==="top"||i==="bottom"||n==="left"||n==="right")&&(t=i,i=n,n=t),r[0]=RC[i]||i,r[1]=RC[n]||n,r.join(" ")},ape=function(t,r){if(r.tween&&r.tween._time===r.tween._dur){var i=r.t,n=i.style,a=r.u,s=i._gsap,o,l,u;if(a==="all"||a===!0)n.cssText="",l=1;else for(a=a.split(","),u=a.length;--u>-1;)o=a[u],ol[o]&&(l=1,o=o==="transformOrigin"?Qn:Nr),au(i,o);l&&(au(i,Nr),s&&(s.svg&&i.removeAttribute("transform"),n.scale=n.rotate=n.translate="none",ym(i,1),s.uncache=1,S7(n)))}},py={clearProps:function(t,r,i,n,a){if(a.data!=="isFromStart"){var s=t._pt=new Jn(t._pt,r,i,0,0,ape);return s.u=n,s.pr=-10,s.tween=a,t._props.push(i),1}}},_m=[1,0,0,1,0,0],P7={},M7=function(t){return t==="matrix(1, 0, 0, 1, 0, 0)"||t==="none"||!t},OC=function(t){var r=_a(t,Nr);return M7(r)?_m:r.substr(7).match(zD).map(Qr)},y$=function(t,r){var i=t._gsap||rc(t),n=t.style,a=OC(t),s,o,l,u;return i.svg&&t.getAttribute("transform")?(l=t.transform.baseVal.consolidate().matrix,a=[l.a,l.b,l.c,l.d,l.e,l.f],a.join(",")==="1,0,0,1,0,0"?_m:a):(a===_m&&!t.offsetParent&&t!==qd&&!i.svg&&(l=n.display,n.display="block",s=t.parentNode,(!s||!t.offsetParent&&!t.getBoundingClientRect().width)&&(u=1,o=t.nextElementSibling,qd.appendChild(t)),a=OC(t),l?n.display=l:au(t,"display"),u&&(o?s.insertBefore(t,o):s?s.appendChild(t):qd.removeChild(t))),r&&a.length>6?[a[0],a[1],a[4],a[5],a[12],a[13]]:a)},$x=function(t,r,i,n,a,s){var o=t._gsap,l=a||y$(t,!0),u=o.xOrigin||0,c=o.yOrigin||0,d=o.xOffset||0,h=o.yOffset||0,f=l[0],p=l[1],m=l[2],g=l[3],v=l[4],x=l[5],_=r.split(" "),y=parseFloat(_[0])||0,w=parseFloat(_[1])||0,$,
vendor: 5,378 bytes, line 68
68S,E,C;i?l!==_m&&(S=f*g-p*m)&&(E=y*(g/S)+w*(-m/S)+(m*x-g*v)/S,C=y*(-p/S)+w*(f/S)-(f*x-p*v)/S,y=E,w=C):($=k7(t),y=$.x+(~_[0].indexOf("%")?y/100*$.width:y),w=$.y+(~(_[1]||_[0]).indexOf("%")?w/100*$.height:w)),n||n!==!1&&o.smooth?(v=y-u,x=w-c,o.xOffset=d+(v*f+x*m)-v,o.yOffset=h+(v*p+x*g)-x):o.xOffset=o.yOffset=0,o.xOrigin=y,o.yOrigin=w,o.smooth=!!n,o.origin=r,o.originIsAbsolute=!!i,t.style[Qn]="0px 0px",s&&(Bl(s,o,"xOrigin",u,y),Bl(s,o,"yOrigin",c,w),Bl(s,o,"xOffset",d,o.xOffset),Bl(s,o,"yOffset",h,o.yOffset)),t.setAttribute("data-svg-origin",y+" "+w)},ym=function(t,r){var i=t._gsap||new f7(t);if("x"in i&&!r&&!i.uncache)return i;var n=t.style,a=i.scaleX<0,s="px",o="deg",l=getComputedStyle(t),u=_a(t,Qn)||"0",c,d,h,f,p,m,g,v,x,_,y,w,$,S,E,C,I,P,T,D,A,z,R,O,V,Y,F,ae,ue,Z,K,fe;return c=d=h=m=g=v=x=_=y=0,f=p=1,i.svg=!!(t.getCTM&&E7(t)),l.translate&&((l.translate!=="none"||l.scale!=="none"||l.rotate!=="none")&&(n[Nr]=(l.translate!=="none"?"translate3d("+(l.translate+" 0 0").split(" ").slice(0,3).join(", ")+") ":"")+(l.rotate!=="none"?"rotate("+l.rotate+") ":"")+(l.scale!=="none"?"scale("+l.scale.split(" ").join(",")+") ":"")+(l[Nr]!=="none"?l[Nr]:"")),n.scale=n.rotate=n.translate="none"),S=y$(t,i.svg),i.svg&&(i.uncache?(V=t.getBBox(),u=i.xOrigin-V.x+"px "+(i.yOrigin-V.y)+"px",O=""):O=!r&&t.getAttribute("data-svg-origin"),$x(t,O||u,!!O||i.originIsAbsolute,i.smooth!==!1,S)),w=i.xOrigin||0,$=i.yOrigin||0,S!==_m&&(P=S[0],T=S[1],D=S[2],A=S[3],c=z=S[4],d=R=S[5],S.length===6?(f=Math.sqrt(P*P+T*T),p=Math.sqrt(A*A+D*D),m=P||T?Zc(T,P)*Pu:0,x=D||A?Zc(D,A)*Pu+m:0,x&&(p*=Math.abs(Math.cos(x*Gd))),i.svg&&(c-=w-(w*P+$*D),d-=$-(w*T+$*A))):(fe=S[6],Z=S[7],F=S[8],ae=S[9],ue=S[10],K=S[11],c=S[12],d=S[13],h=S[14],E=Zc(fe,ue),g=E*Pu,E&&(C=Math.cos(-E),I=Math.sin(-E),O=z*C+F*I,V=R*C+ae*I,Y=fe*C+ue*I,F=z*-I+F*C,ae=R*-I+ae*C,ue=fe*-I+ue*C,K=Z*-I+K*C,z=O,R=V,fe=Y),E=Zc(-D,ue),v=E*Pu,E&&(C=Math.cos(-E),I=Math.sin(-E),O=P*C-F*I,V=T*C-ae*I,Y=D*C-ue*I,K=A*I+K*C,P=O,T=V,D=Y),E=Zc(T,P),m=E*Pu,E&&(C=Math.cos(E),I=Math.sin(E),O=P*C+T*I,V=z*C+R*I,T=T*C-P*I,R=R*C-z*I,P=O,z=V),g&&Math.abs(g)+Math.abs(m)>359.9&&(g=m=0,v=180-v),f=Qr(Math.sqrt(P*P+T*T+D*D)),p=Qr(Math.sqrt(R*R+fe*fe)),E=Zc(z,R),x=Math.abs(E)>2e-4?E*Pu:0,y=K?1/(K<0?-K:K):0),i.svg&&(O=t.getAttribute("transform"),i.forceCSS=t.setAttribute("transform","")||!M7(_a(t,Nr)),O&&t.setAttribute("transform",O))),Math.abs(x)>90&&Math.abs(x)<270&&(a?(f*=-1,x+=m<=0?180:-180,m+=m<=0?180:-180):(p*=-1,x+=x<=0?180:-180)),r=r||i.uncache,i.x=c-((i.xPercent=c&&(!r&&i.xPercent||(Math.round(t.offsetWidth/2)===Math.round(-c)?-50:0)))?t.offsetWidth*i.xPercent/100:0)+s,i.y=d-((i.yPercent=d&&(!r&&i.yPercent||(Math.round(t.offsetHeight/2)===Math.round(-d)?-50:0)))?t.offsetHeight*i.yPercent/100:0)+s,i.z=h+s,i.scaleX=Qr(f),i.scaleY=Qr(p),i.rotation=Qr(m)+o,i.rotationX=Qr(g)+o,i.rotationY=Qr(v)+o,i.skewX=x+o,i.skewY=_+o,i.transformPerspective=y+s,(i.zOrigin=parseFloat(u.split(" ")[2])||!r&&i.zOrigin||0)&&(n[Qn]=my(u)),i.xOffset=i.yOffset=0,i.force3D=wa.force3D,i.renderTransform=i.svg?ope:C7?I7:spe,i.uncache=0,i},my=function(t){return(t=t.split(" "))[0]+" "+t[1]},ob=function(t,r,i){var n=on(r);return Qr(parseFloat(r)+parseFloat(su(t,"x",i+"px",n)))+n},spe=function(t,r){r.z="0px",r.rotationY=r.rotationX="0deg",r.force3D=0,I7(t,r)},$u="0deg",bf="0px",Su=") ",I7=function(t,r){var i=r||this,n=i.xPercent,a=i.yPercent,s=i.x,o=i.y,l=i.z,u=i.rotation,c=i.rotationY,d=i.rotationX,h=i.skewX,f=i.skewY,p=i.scaleX,m=i.scaleY,g=i.transformPerspective,v=i.force3D,x=i.target,_=i.zOrigin,y="",w=v==="auto"&&t&&t!==1||v===!0;if(_&&(d!==$u||c!==$u)){var $=parseFloat(c)*Gd,S=Math.sin($),E=Math.cos($),C;$=parseFloat(d)*Gd,C=Math.cos($),s=ob(x,s,S*C*-_),o=ob(x,o,-Math.sin($)*-_),l=ob(x,l,E*C*-_+_)}g!==bf&&(y+="perspective("+g+Su),(n||a)&&(y+="translate("+n+"%, "+a+"%) "),(w||s!==bf||o!==bf||l!==bf)&&(y+=l!==bf||w?"translate3d("+s+", "+o+", "+l+") ":"translate("+s+", "+o+Su),u!==$u&&(y+="rotate("+u+Su),c!==$u&&(y+="rotateY("+c+Su),d!==$u&&(y+="rotateX("+d+Su),(h!==$u||f!==$u)&&(y+="skew("+h+", "+f+Su),(p!==1||m!==1)&&(y+="scale("+p+", "+m+Su),x.style[Nr]=y||"translate(0, 0)"},ope=function(t,r){var i=r||this,n=i.xPercent,a=i.yPercent,s=i.x,o=i.y,l=i.rotation,u=i.skewX,c=i.skewY,d=i.scaleX,h=i.scaleY,f=i.target,p=i.xOrigin,m=i.yOrigin,g=i.xOffset,v=i.yOffset,x=i.forceCSS,_=parseFloat(s),y=parseFloat(o),w,$,S,E,C;l=parseFloat(l),u=parseFloat(u),c=parseFloat(c),c&&(c=parseFloat(c),u+=c,l+=c),l||u?(l*=Gd,u*=Gd,w=Math.cos(l)*d,$=Math.sin(l)*d,S=Math.sin(l-u)*-h,E=Math.cos(l-u)*h,u&&(c*=Gd,C=Math.tan(u-c),C=Math.sqrt(1+C*C),S*=C,E*=C,c&&(C=Math.tan(c),C=Math.sqrt(1+C*C),w*=C,$*=C)),w=Qr(w),$=Qr($),S=Qr(S),E=Qr(E)):(w=d,E=h,$=S=0),(_&&!~(s+"").indexOf("px")||y&&!~(o+"").indexOf("px"))&&(_=su(f,"x",s,"px"),y=su(f,"y",o,"px")),(p||m||g||v)&&(_=Qr(_+p-(p*w+m*S)+g),y=Qr(y+m-(p*$+m*E)+v)),(n||a)&&(C=f.getBBox(),_=Qr(_+n/100*C.width),y=Qr(y+a/100*C.height)),C="matrix("+w+","+$+","+S+","+E+","+_+","+y+")",f.setAttribute("transform",C),x&&(f.style[Nr]=C)},lpe=function(t,r,i,n,a){var s=360,o=Pi(a),l=parseFloat(a)*(o&&~a.indexOf("rad")?Pu:1),u=l-n,c=n+u+"deg",d,h;return o&&(d=a.split("_")[1],d==="short"&&(u%=s,u!==u%(s/2)&&(u+=u<0?s:-s)),d==="cw"&&u<0?u=(u+s*PC)%s-~~(u/s)*s:d==="ccw"&&u>0&&(u=(u-s*PC)%s-~~(u/s)*s)),t._pt=h=new Jn(t._pt,r,i,n,u,qfe),h.e=c,h.u="deg",t._props.push(i),h},LC=function(t,r){for(var i in r)t[i]=r[i];return t}
vendor: 5,079 bytes, line 68
68,upe=function(t,r,i){var n=LC({},i._gsap),a="perspective,force3D,transformOrigin,svgOrigin",s=i.style,o,l,u,c,d,h,f,p;n.svg?(u=i.getAttribute("transform"),i.setAttribute("transform",""),s[Nr]=r,o=ym(i,1),au(i,Nr),i.setAttribute("transform",u)):(u=getComputedStyle(i)[Nr],s[Nr]=r,o=ym(i,1),s[Nr]=u);for(l in ol)u=n[l],c=o[l],u!==c&&a.indexOf(l)<0&&(f=on(u),p=on(c),d=f!==p?su(i,l,u,p):parseFloat(u),h=parseFloat(c),t._pt=new Jn(t._pt,o,l,d,h-d,bx),t._pt.u=p||0,t._props.push(l));LC(o,n)};Xn("padding,margin,Width,Radius",function(e,t){var r="Top",i="Right",n="Bottom",a="Left",s=(t<3?[r,i,n,a]:[r+a,r+i,n+i,n+a]).map(function(o){return t<2?e+o:"border"+o+e});py[t>1?"border"+e:e]=function(o,l,u,c,d){var h,f;if(arguments.length<4)return h=s.map(function(p){return Eo(o,p,u)}),f=h.join(" "),f.split(h[0]).length===5?h[0]:f;h=(c+"").split(" "),f={},s.forEach(function(p,m){return f[p]=h[m]=h[m]||h[(m-1)/2|0]}),o.init(l,f,d)}});var A7={name:"css",register:wx,targetTest:function(t){return t.style&&t.nodeType},init:function(t,r,i,n,a){var s=this._props,o=t.style,l=i.vars.startAt,u,c,d,h,f,p,m,g,v,x,_,y,w,$,S,E,C;m$||wx(),this.styles=this.styles||T7(t),E=this.styles.props,this.tween=i;for(m in r)if(m!=="autoRound"&&(c=r[m],!(ua[m]&&p7(m,r,i,n,t,a)))){if(f=typeof c,p=py[m],f==="function"&&(c=c.call(i,n,t,a),f=typeof c),f==="string"&&~c.indexOf("random(")&&(c=pm(c)),p)p(this,t,m,c,i)&&(S=1);else if(m.substr(0,2)==="--")u=(getComputedStyle(t).getPropertyValue(m)+"").trim(),c+="",Kl.lastIndex=0,Kl.test(u)||(g=on(u),v=on(c),v?g!==v&&(u=su(t,m,u,v)+v):g&&(c+=g)),this.add(o,"setProperty",u,c,n,a,0,0,m),s.push(m),E.push(m,0,o[m]);else if(f!=="undefined"){if(l&&m in l?(u=typeof l[m]=="function"?l[m].call(i,n,t,a):l[m],Pi(u)&&~u.indexOf("random(")&&(u=pm(u)),on(u+"")||u==="auto"||(u+=wa.units[m]||on(Eo(t,m))||""),(u+"").charAt(1)==="="&&(u=Eo(t,m))):u=Eo(t,m),h=parseFloat(u),x=f==="string"&&c.charAt(1)==="="&&c.substr(0,2),x&&(c=c.substr(2)),d=parseFloat(c),m in Xs&&(m==="autoAlpha"&&(h===1&&Eo(t,"visibility")==="hidden"&&d&&(h=0),E.push("visibility",0,o.visibility),Bl(this,o,"visibility",h?"inherit":"hidden",d?"inherit":"hidden",!d)),m!=="scale"&&m!=="transform"&&(m=Xs[m],~m.indexOf(",")&&(m=m.split(",")[0]))),_=m in ol,_){if(this.styles.save(m),C=c,f==="string"&&c.substring(0,6)==="var(--"){if(c=_a(t,c.substring(4,c.indexOf(")"))),c.substring(0,5)==="calc("){var I=t.style.perspective;t.style.perspective=c,c=_a(t,"perspective"),I?t.style.perspective=I:au(t,"perspective")}d=parseFloat(c)}if(y||(w=t._gsap,w.renderTransform&&!r.parseTransform||ym(t,r.parseTransform),$=r.smoothOrigin!==!1&&w.smooth,y=this._pt=new Jn(this._pt,o,Nr,0,1,w.renderTransform,w,0,-1),y.dep=1),m==="scale")this._pt=new Jn(this._pt,w,"scaleY",w.scaleY,(x?Vd(w.scaleY,x+d):d)-w.scaleY||0,bx),this._pt.u=0,s.push("scaleY",m),m+="X";else if(m==="transformOrigin"){E.push(Qn,0,o[Qn]),c=npe(c),w.svg?$x(t,c,0,$,0,this):(v=parseFloat(c.split(" ")[2])||0,v!==w.zOrigin&&Bl(this,w,"zOrigin",w.zOrigin,v),Bl(this,o,m,my(u),my(c)));continue}else if(m==="svgOrigin"){$x(t,c,1,$,0,this);continue}else if(m in P7){lpe(this,w,m,h,x?Vd(h,x+c):c);continue}else if(m==="smoothOrigin"){Bl(this,w,"smooth",w.smooth,c);continue}else if(m==="force3D"){w[m]=c;continue}else if(m==="transform"){upe(this,c,t);continue}}else m in o||(m=Ch(m)||m);if(_||(d||d===0)&&(h||h===0)&&!Vfe.test(c)&&m in o)g=(u+"").substr((h+"").length),d||(d=0),v=on(c)||(m in wa.units?wa.units[m]:g),g!==v&&(h=su(t,m,u,v)),this._pt=new Jn(this._pt,_?w:o,m,h,(x?Vd(h,x+d):d)-h,!_&&(v==="px"||m==="zIndex")&&r.autoRound!==!1?Yfe:bx),this._pt.u=v||0,_&&C!==c?(this._pt.b=u,this._pt.e=C,this._pt.r=Hfe):g!==v&&v!=="%"&&(this._pt.b=u,this._pt.r=Gfe);else if(m in o)ipe.call(this,t,m,u,x?x+c:c);else if(m in t)this.add(t,m,u||t[m],x?x+c:c,n,a);else if(m!=="parseTransform"){a$(m,c);continue}_||(m in o?E.push(m,0,o[m]):typeof t[m]=="function"?E.push(m,2,t[m]()):E.push(m,1,u||t[m])),s.push(m)}}S&&b7(this)},render:function(t,r){if(r.tween._time||!g$())for(var i=r._pt;i;)i.r(t,i.d),i=i._next;else r.styles.revert()},get:Eo,aliases:Xs,getSetter:function(t,r,i){var n=Xs[r];return n&&n.indexOf(",")<0&&(r=n),r in ol&&r!==Qn&&(t._gsap.x||Eo(t,"x"))?i&&EC===i?r==="scale"?Xfe:Kfe:(EC=i||{})&&(r==="scale"?Jfe:Qfe):t.style&&!r$(t.style[r])?Wfe:~r.indexOf("-")?Zfe:f$(t,r)},core:{_removeProperty:au,_getMatrix:y$}};ta.utils.checkPrefix=Ch;ta.core.getStyleSaver=T7;(function(e,t,r,i){var n=Xn(e+","+t+","+r,function(a){ol[a]=1});Xn(t,function(a){wa.units[a]="deg",P7[a]=1}),Xs[n[13]]=e+","+t,Xn(i,function(a){var s=a.split(":");Xs[s[1]]=n[s[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");Xn("x,y,z,top,right,bottom,left,width,height,fontSize,padding,margin,perspective",function(e){wa.units[e]="px"});ta.registerPlugin(A7);var _p=ta.registerPlugin(A7)||ta;_p.core.Tween;function cpe(e,t){for(var r=0;r<t.length;r++){var i=t[r];
vendor: 11,254 bytes, lines 68-82
68i.enumerable=i.enumerable||!1,i.configurable=!0,"value"in i&&(i.writable=!0),Object.defineProperty(e,i.key,i)}}function dpe(e,t,r){return t&&cpe(e.prototype,t),e}/*! 69 * Observer 3.14.2 70 * https://gsap.com 71 * 72 * @license Copyright 2008-2025, GreenSock. All rights reserved. 73 * Subject to the terms at https://gsap.com/standard-license 74 * @author: Jack Doyle, [email protected] 75*/var Ui,r_,fa,jl,Ul,Hd,D7,Mu,yp,R7,Lo,fs,O7,L7=function(){return Ui||typeof window<"u"&&(Ui=window.gsap)&&Ui.registerPlugin&&Ui},F7=1,wd=[],St=[],ro=[],vp=Date.now,Sx=function(t,r){return r},hpe=function(){var t=yp.core,r=t.bridge||{},i=t._scrollers,n=t._proxies;i.push.apply(i,St),n.push.apply(n,ro),St=i,ro=n,Sx=function(s,o){return r[s](o)}},Xl=function(t,r){return~ro.indexOf(t)&&ro[ro.indexOf(t)+1][r]},bp=function(t){return!!~R7.indexOf(t)},bn=function(t,r,i,n,a){return t.addEventListener(r,i,{passive:n!==!1,capture:!!a})},yn=function(t,r,i,n){return t.removeEventListener(r,i,!!n)},Zg="scrollLeft",Kg="scrollTop",Tx=function(){return Lo&&Lo.isPressed||St.cache++},gy=function(t,r){var i=function n(a){if(a||a===0){F7&&(fa.history.scrollRestoration="manual");var s=Lo&&Lo.isPressed;a=n.v=Math.round(a)||(Lo&&Lo.iOS?1:0),t(a),n.cacheID=St.cache,s&&Sx("ss",a)}else(r||St.cache!==n.cacheID||Sx("ref"))&&(n.cacheID=St.cache,n.v=t());return n.v+n.offset};return i.offset=0,t&&i},Mn={s:Zg,p:"left",p2:"Left",os:"right",os2:"Right",d:"width",d2:"Width",a:"x",sc:gy(function(e){return arguments.length?fa.scrollTo(e,mi.sc()):fa.pageXOffset||jl[Zg]||Ul[Zg]||Hd[Zg]||0})},mi={s:Kg,p:"top",p2:"Top",os:"bottom",os2:"Bottom",d:"height",d2:"Height",a:"y",op:Mn,sc:gy(function(e){return arguments.length?fa.scrollTo(Mn.sc(),e):fa.pageYOffset||jl[Kg]||Ul[Kg]||Hd[Kg]||0})},zn=function(t,r){return(r&&r._ctx&&r._ctx.selector||Ui.utils.toArray)(t)[0]||(typeof t=="string"&&Ui.config().nullTargetWarn!==!1?console.warn("Element not found:",t):null)},fpe=function(t,r){for(var i=r.length;i--;)if(r[i]===t||r[i].contains(t))return!0;return!1},ou=function(t,r){var i=r.s,n=r.sc;bp(t)&&(t=jl.scrollingElement||Ul);var a=St.indexOf(t),s=n===mi.sc?1:2;!~a&&(a=St.push(t)-1),St[a+s]||bn(t,"scroll",Tx);var o=St[a+s],l=o||(St[a+s]=gy(Xl(t,i),!0)||(bp(t)?n:gy(function(u){return arguments.length?t[i]=u:t[i]})));return l.target=t,o||(l.smooth=Ui.getProperty(t,"scrollBehavior")==="smooth"),l},Cx=function(t,r,i){var n=t,a=t,s=vp(),o=s,l=r||50,u=Math.max(500,l*3),c=function(p,m){var g=vp();m||g-s>l?(a=n,n=p,o=s,s=g):i?n+=p:n=a+(p-a)/(g-o)*(s-o)},d=function(){a=n=i?0:n,o=s=0},h=function(p){var m=o,g=a,v=vp();return(p||p===0)&&p!==n&&c(p),s===o||v-o>u?0:(n+(i?g:-g))/((i?v:s)-m)*1e3};return{update:c,reset:d,getVelocity:h}},xf=function(t,r){return r&&!t._gsapAllow&&t.preventDefault(),t.changedTouches?t.changedTouches[0]:t},FC=function(t){var r=Math.max.apply(Math,t),i=Math.min.apply(Math,t);return Math.abs(r)>=Math.abs(i)?r:i},z7=function(){yp=Ui.core.globals().ScrollTrigger,yp&&yp.core&&hpe()},N7=function(t){return Ui=t||L7(),!r_&&Ui&&typeof document<"u"&&document.body&&(fa=window,jl=document,Ul=jl.documentElement,Hd=jl.body,R7=[fa,jl,Ul,Hd],Ui.utils.clamp,O7=Ui.core.context||function(){},Mu="onpointerenter"in Hd?"pointer":"mouse",D7=ii.isTouch=fa.matchMedia&&fa.matchMedia("(hover: none), (pointer: coarse)").matches?1:"ontouchstart"in fa||navigator.maxTouchPoints>0||navigator.msMaxTouchPoints>0?2:0,fs=ii.eventTypes=("ontouchstart"in Ul?"touchstart,touchmove,touchcancel,touchend":"onpointerdown"in Ul?"pointerdown,pointermove,pointercancel,pointerup":"mousedown,mousemove,mouseup,mouseup").split(","),setTimeout(function(){return F7=0},500),z7(),r_=1),r_};Mn.op=mi;St.cache=0;var ii=(function(){function e(r){this.init(r)}var t=e.prototype;return t.init=function(i){r_||N7(Ui)||console.warn("Please gsap.registerPlugin(Observer)"),yp||z7();var n=i.tolerance,a=i.dragMinimum,s=i.type,o=i.target,l=i.lineHeight,u=i.debounce,c=i.preventDefault,d=i.onStop,h=i.onStopDelay,f=i.ignore,p=i.wheelSpeed,m=i.event,g=i.onDragStart,v=i.onDragEnd,x=i.onDrag,_=i.onPress,y=i.onRelease,w=i.onRight,$=i.onLeft,S=i.onUp,E=i.onDown,C=i.onChangeX,I=i.onChangeY,P=i.onChange,T=i.onToggleX,D=i.onToggleY,A=i.onHover,z=i.onHoverEnd,R=i.onMove,O=i.ignoreCheck,V=i.isNormalizer,Y=i.onGestureStart,F=i.onGestureEnd,ae=i.onWheel,ue=i.onEnable,Z=i.onDisable,K=i.onClick,fe=i.scrollSpeed,ve=i.capture,$e=i.allowClicks,Re=i.lockAxis,Oe=i.onLockAxis;this.target=o=zn(o)||Ul,this.vars=i,f&&(f=Ui.utils.toArray(f)),n=n||1e-9,a=a||0,p=p||1,fe=fe||1,s=s||"wheel,touch,pointer",u=u!==!1,l||(l=parseFloat(fa.getComputedStyle(Hd).lineHeight)||22);var ze,Be,qe,j,W,G,ie,U=this,ne=0,me=0,J=i.passive||!c&&i.passive!==!1,N=ou(o,Mn),q=ou(o,mi),te=N(),ee=q(),oe=~s.indexOf("touch")&&!~s.indexOf("pointer")&&fs[0]==="pointerdown",Se=bp(o),we=o.ownerDocument||jl,De=[0,0,0],Ue=[0,0,0],xt=0,kt=function(){return xt=vp()},ot=function(et,It){return(U.event=et)&&f&&fpe(et.target,f)||It&&oe&&et.pointerType!=="touch"||O&&O(et,It)},rr=function(){U._vx.reset(),U._vy.reset(),Be.pause(),d&&d(U)},Cr=function(){var et=U.deltaX=FC(De),It=U.deltaY=FC(Ue),Ie=Math.abs(et)>=n,st=Math.abs(It)>=n;P&&(Ie||st)&&P(U,et,It,De,Ue),Ie&&(w&&U.deltaX>0&&w(U),$&&U.deltaX<0&&$(U),C&&C(U),T&&U.deltaX<0!=ne<0&&T(U),ne=U.deltaX,De[0]=De[1]=De[2]=0),st&&(E&&U.deltaY>0&&E(U),S&&U.deltaY<0&&S(U),I&&I(U),D&&U.deltaY<0!=me<0&&D(U),me=U.deltaY,Ue[0]=Ue[1]=Ue[2]=0),(j||qe)&&(R&&R(U),qe&&(g&&qe===1&&g(U),x&&x(U),qe=0),j=!1),G&&!(G=!1)&&Oe&&Oe(U),W&&(ae(U),W=!1),ze=0},xi=function(et,It,Ie){De[Ie]+=et,Ue[Ie]+=It,U._vx.update(et),U._vy.update(It),u?ze||(ze=requestAnimationFrame(Cr)):Cr()},Vt=function(et,It){Re&&!ie&&(U.axis=ie=Math.abs(et)>Math.abs(It)?"x":"y",G=!0),ie!=="y"&&(De[2]+=et,U._vx.update(et,!0)),ie!=="x"&&(Ue[2]+=It,U._vy.update(It,!0)),u?ze||(ze=requestAnimationFrame(Cr)):Cr()},ge=function(et){if(!ot(et,1)){et=xf(et,c);var It=et.clientX,Ie=et.clientY,st=It-U.x,Qe=Ie-U.y,pt=U.isDragging;U.x=It,U.y=Ie,(pt||(st||Qe)&&(Math.abs(U.startX-It)>=a||Math.abs(U.startY-Ie)>=a))&&(qe||(qe=pt?2:1),pt||(U.isDragging=!0),Vt(st,Qe))}},B=U.onPress=function(Ke){ot(Ke,1)||Ke&&Ke.button||(U.axis=ie=null,Be.pause(),U.isPressed=!0,Ke=xf(Ke),ne=me=0,U.startX=U.x=Ke.clientX,U.startY=U.y=Ke.clientY,U._vx.reset(),U._vy.reset(),bn(V?o:we,fs[1],ge,J,!0),U.deltaX=U.deltaY=0,_&&_(U))},re=U.onRelease=function(Ke){if(!ot(Ke,1)){yn(V?o:we,fs[1],ge,!0);var et=!isNaN(U.y-U.startY),It=U.isDragging,Ie=It&&(Math.abs(U.x-U.startX)>3||Math.abs(U.y-U.startY)>3),st=xf(Ke);!Ie&&et&&(U._vx.reset(),U._vy.reset(),c&&$e&&Ui.delayedCall(.08,function(){if(vp()-xt>300&&!Ke.defaultPrevented){if(Ke.target.click)Ke.target.click();else if(we.createEvent){var Qe=we.createEvent("MouseEvents");Qe.initMouseEvent("click",!0,!0,fa,1,st.screenX,st.screenY,st.clientX,st.clientY,!1,!1,!1,!1,0,null),Ke.target.dispatchEvent(Qe)}}})),U.isDragging=U.isGesturing=U.isPressed=!1,d&&It&&!V&&Be.restart(!0),qe&&Cr(),v&&It&&v(U),y&&y(U,Ie)}},_e=function(et){return et.touches&&et.touches.length>1&&(U.isGesturing=!0)&&Y(et,U.isDragging)},Ee=function(){return(U.isGesturing=!1)||F(U)},Fe=function(et){if(!ot(et)){var It=N(),Ie=q();xi((It-te)*fe,(Ie-ee)*fe,1),te=It,ee=Ie,d&&Be.restart(!0)}},ht=function(et){if(!ot(et)){et=xf(et,c),ae&&(W=!0);var It=(et.deltaMode===1?l:et.deltaMode===2?fa.innerHeight:1)*p;xi(et.deltaX*It,et.deltaY*It,0),d&&!V&&Be.restart(!0)}},Et=function(et){if(!ot(et)){var It=et.clientX,Ie=et.clientY,st=It-U.x,Qe=Ie-U.y;U.x=It,U.y=Ie,j=!0,d&&Be.restart(!0),(st||Qe)&&Vt(st,Qe)}},lr=function(et){U.event=et,A(U)},Br=function(et){U.event=et,z(U)},ls=function(et){return ot(et)||xf(et,c)&&K(U)};Be=U._dc=Ui.delayedCall(h||.25,rr).pause(),U.deltaX=U.deltaY=0,U._vx=Cx(0,50,!0),U._vy=Cx(0,50,!0),U.scrollX=N,U.scrollY=q,U.isDragging=U.isGesturing=U.isPressed=!1,O7(this),U.enable=function(Ke){return U.isEnabled||(bn(Se?we:o,"scroll",Tx),s.indexOf("scroll")>=0&&bn(Se?we:o,"scroll",Fe,J,ve),s.indexOf("wheel")>=0&&bn(o,"wheel",ht,J,ve),(s.indexOf("touch")>=0&&D7||s.indexOf("pointer")>=0)&&(bn(o,fs[0],B,J,ve),bn(we,fs[2],re),bn(we,fs[3],re),$e&&bn(o,"click",kt,!0,!0),K&&bn(o,"click",ls),Y&&bn(we,"gesturestart",_e),F&&bn(we,"gestureend",Ee),A&&bn(o,Mu+"enter",lr),z&&bn(o,Mu+"leave",Br),R&&bn(o,Mu+"move",Et)),U.isEnabled=!0,U.isDragging=U.isGesturing=U.isPressed=j=qe=!1,U._vx.reset(),U._vy.reset(),te=N(),ee=q(),Ke&&Ke.type&&B(Ke),ue&&ue(U)),U},U.disable=function(){U.isEnabled&&(wd.filter(function(Ke){return Ke!==U&&bp(Ke.target)}).length||yn(Se?we:o,"scroll",Tx),U.isPressed&&(U._vx.reset(),U._vy.reset(),yn(V?o:we,fs[1],ge,!0)),yn(Se?we:o,"scroll",Fe,ve),yn(o,"wheel",ht,ve),yn(o,fs[0],B,ve),yn(we,fs[2],re),yn(we,fs[3],re),yn(o,"click",kt,!0),yn(o,"click",ls),yn(we,"gesturestart",_e),yn(we,"gestureend",Ee),yn(o,Mu+"enter",lr),yn(o,Mu+"leave",Br),yn(o,Mu+"move",Et),U.isEnabled=U.isPressed=U.isDragging=!1,Z&&Z(U))},U.kill=U.revert=function(){U.disable();var Ke=wd.indexOf(U);Ke>=0&&wd.splice(Ke,1),Lo===U&&(Lo=0)},wd.push(U),V&&bp(o)&&(Lo=U),U.enable(m)},dpe(e,[{key:"velocityX",get:function(){return this._vx.getVelocity()}},{key:"velocityY",get:function(){return this._vy.getVelocity()}}]),e})();ii.version="3.14.2";ii.create=function(e){return new ii(e)};ii.register=N7;ii.getAll=function(){return wd.slice()};ii.getById=function(e){return wd.filter(function(t){return t.vars.id===e})[0]};L7()&&Ui.registerPlugin(ii);/*! 76 * ScrollTrigger 3.14.2 77 * https://gsap.com 78 * 79 * @license Copyright 2008-2025, GreenSock. All rights reserved. 80 * Subject to the terms at https://gsap.com/standard-license 81 * @author: Jack Doyle, [email protected] 82*/var je,od,$t,pr,ca,Jt,v$,_y,vm,xp,Gf,Xg,Ji,V1,kx,wn,zC,NC,ld,B7,lb,j7,xn,Ex,U7,V7,El,Px,b$,Yd,x$,wp,Mx,ub,Jg=1,nn=Date.now,cb=nn(),ts=0,Hf=0,BC=function(t,r,i){var n=oa(t)&&(t.substr(0,6)==="clamp("||t.indexOf("max")>-1);return i["_"+r+"Clamp"]=n,n?t.substr(6,t.length-7):t},jC=function(t,r){return r&&(!oa(t)||t.substr(0,6)!=="clamp(")?"clamp("+t+")":t},ppe=function e(){return Hf&&requestAnimationFrame(e)},UC=function(){return V1=1},VC=function(){return V1=0},Vs=function(t){return t},Yf=function(t){return Math.round(t*1e5)/1e5||0},q7=function(){return typeof window<"u"},G7=function(){return je||q7()&&(je=window.gsap)&&je.registerPlugin&&je},wc=function(t){return!!~v$.indexOf(t)},H7=function(t){return(t==="Height"?x$:$t["inner"+t])||ca["client"+t]||Jt["client"+t]},Y7=function(t){return Xl(t,"getBoundingClientRect")||(wc(t)?function(){return o_.width=$t.innerWidth,o_.height=x$,o_}:function(){return Do(t)})},mpe=function(t,r,i){var n=i.d,a=i.d2,s=i.a;return(s=Xl(t,"getBoundingClientRect"))?function(){return s()[n]}:function(){return(r?H7(a):t["client"+a])||0}},gpe=function(t,r){return!r||~ro.indexOf(t)?Y7(t):function(){return o_}},Js=function(t,r){var i=r.s,n=r.d2,a=r.d,s=r.a;return Math.max(0,(i="scroll"+n)&&(s=Xl(t,i))?s()-Y7(t)()[a]:wc(t)?(ca[i]||Jt[i])-H7(n):t[i]-t["offset"+n])},Qg=function(t,r){for(var i=0;i<ld.length;i+=3)(!r||~r.indexOf(ld[i+1]))&&t(ld[i],ld[i+1],ld[i+2])},oa=function(t){return typeof t=="string"},ln=function(t){return typeof t=="function"},Wf=function(t){return typeof t=="number"},Iu=function(t){return typeof t=="object"},wf=function(t,r,i){return t&&t.progress(r?0:1)&&i&&t.pause()},db=function(t,r){if(t.enabled){var i=t._ctx?t._ctx.add(function(){return r(t)}):r(t);
vendor: 7,943 bytes, line 82
82i&&i.totalTime&&(t.callbackAnimation=i)}},Kc=Math.abs,W7="left",Z7="top",w$="right",$$="bottom",sc="width",oc="height",$p="Right",Sp="Left",Tp="Top",Cp="Bottom",si="padding",ja="margin",kh="Width",S$="Height",pi="px",Ua=function(t){return $t.getComputedStyle(t)},_pe=function(t){var r=Ua(t).position;t.style.position=r==="absolute"||r==="fixed"?r:"relative"},qC=function(t,r){for(var i in r)i in t||(t[i]=r[i]);return t},Do=function(t,r){var i=r&&Ua(t)[kx]!=="matrix(1, 0, 0, 1, 0, 0)"&&je.to(t,{x:0,y:0,xPercent:0,yPercent:0,rotation:0,rotationX:0,rotationY:0,scale:1,skewX:0,skewY:0}).progress(1),n=t.getBoundingClientRect();return i&&i.progress(0).kill(),n},yy=function(t,r){var i=r.d2;return t["offset"+i]||t["client"+i]||0},K7=function(t){var r=[],i=t.labels,n=t.duration(),a;for(a in i)r.push(i[a]/n);return r},ype=function(t){return function(r){return je.utils.snap(K7(t),r)}},T$=function(t){var r=je.utils.snap(t),i=Array.isArray(t)&&t.slice(0).sort(function(n,a){return n-a});return i?function(n,a,s){s===void 0&&(s=.001);var o;if(!a)return r(n);if(a>0){for(n-=s,o=0;o<i.length;o++)if(i[o]>=n)return i[o];return i[o-1]}else for(o=i.length,n+=s;o--;)if(i[o]<=n)return i[o];return i[0]}:function(n,a,s){s===void 0&&(s=.001);var o=r(n);return!a||Math.abs(o-n)<s||o-n<0==a<0?o:r(a<0?n-t:n+t)}},vpe=function(t){return function(r,i){return T$(K7(t))(r,i.direction)}},e0=function(t,r,i,n){return i.split(",").forEach(function(a){return t(r,a,n)})},Ci=function(t,r,i,n,a){return t.addEventListener(r,i,{passive:!n,capture:!!a})},$i=function(t,r,i,n){return t.removeEventListener(r,i,!!n)},t0=function(t,r,i){i=i&&i.wheelHandler,i&&(t(r,"wheel",i),t(r,"touchmove",i))},GC={startColor:"green",endColor:"red",indent:0,fontSize:"16px",fontWeight:"normal"},r0={toggleActions:"play",anticipatePin:0},vy={top:0,left:0,center:.5,bottom:1,right:1},i_=function(t,r){if(oa(t)){var i=t.indexOf("="),n=~i?+(t.charAt(i-1)+1)*parseFloat(t.substr(i+1)):0;~i&&(t.indexOf("%")>i&&(n*=r/100),t=t.substr(0,i-1)),t=n+(t in vy?vy[t]*r:~t.indexOf("%")?parseFloat(t)*r/100:parseFloat(t)||0)}return t},i0=function(t,r,i,n,a,s,o,l){var u=a.startColor,c=a.endColor,d=a.fontSize,h=a.indent,f=a.fontWeight,p=pr.createElement("div"),m=wc(i)||Xl(i,"pinType")==="fixed",g=t.indexOf("scroller")!==-1,v=m?Jt:i,x=t.indexOf("start")!==-1,_=x?u:c,y="border-color:"+_+";font-size:"+d+";color:"+_+";font-weight:"+f+";pointer-events:none;white-space:nowrap;font-family:sans-serif,Arial;z-index:1000;padding:4px 8px;border-width:0;border-style:solid;";return y+="position:"+((g||l)&&m?"fixed;":"absolute;"),(g||l||!m)&&(y+=(n===mi?w$:$$)+":"+(s+parseFloat(h))+"px;"),o&&(y+="box-sizing:border-box;text-align:left;width:"+o.offsetWidth+"px;"),p._isStart=x,p.setAttribute("class","gsap-marker-"+t+(r?" marker-"+r:"")),p.style.cssText=y,p.innerText=r||r===0?t+"-"+r:t,v.children[0]?v.insertBefore(p,v.children[0]):v.appendChild(p),p._offset=p["offset"+n.op.d2],n_(p,0,n,x),p},n_=function(t,r,i,n){var a={display:"block"},s=i[n?"os2":"p2"],o=i[n?"p2":"os2"];t._isFlipped=n,a[i.a+"Percent"]=n?-100:0,a[i.a]=n?"1px":0,a["border"+s+kh]=1,a["border"+o+kh]=0,a[i.p]=r+"px",je.set(t,a)},wt=[],Ix={},bm,HC=function(){return nn()-ts>34&&(bm||(bm=requestAnimationFrame(Ho)))},Xc=function(){(!xn||!xn.isPressed||xn.startX>Jt.clientWidth)&&(St.cache++,xn?bm||(bm=requestAnimationFrame(Ho)):Ho(),ts||Sc("scrollStart"),ts=nn())},hb=function(){V7=$t.innerWidth,U7=$t.innerHeight},Zf=function(t){St.cache++,(t===!0||!Ji&&!j7&&!pr.fullscreenElement&&!pr.webkitFullscreenElement&&(!Ex||V7!==$t.innerWidth||Math.abs($t.innerHeight-U7)>$t.innerHeight*.25))&&_y.restart(!0)},$c={},bpe=[],X7=function e(){return $i(Tt,"scrollEnd",e)||ju(!0)},Sc=function(t){return $c[t]&&$c[t].map(function(r){return r()})||bpe},aa=[],J7=function(t){for(var r=0;r<aa.length;r+=5)(!t||aa[r+4]&&aa[r+4].query===t)&&(aa[r].style.cssText=aa[r+1],aa[r].getBBox&&aa[r].setAttribute("transform",aa[r+2]||""),aa[r+3].uncache=1)},Q7=function(){return St.forEach(function(t){return ln(t)&&++t.cacheID&&(t.rec=t())})},C$=function(t,r){var i;for(wn=0;wn<wt.length;wn++)i=wt[wn],i&&(!r||i._ctx===r)&&(t?i.kill(1):i.revert(!0,!0));wp=!0,r&&J7(r),r||Sc("revert")},eR=function(t,r){St.cache++,(r||!$n)&&St.forEach(function(i){return ln(i)&&i.cacheID++&&(i.rec=0)}),oa(t)&&($t.history.scrollRestoration=b$=t)},$n,lc=0,YC,xpe=function(){if(YC!==lc){var t=YC=lc;requestAnimationFrame(function(){return t===lc&&ju(!0)})}},tR=function(){Jt.appendChild(Yd),x$=!xn&&Yd.offsetHeight||$t.innerHeight,Jt.removeChild(Yd)},WC=function(t){return vm(".gsap-marker-start, .gsap-marker-end, .gsap-marker-scroller-start, .gsap-marker-scroller-end").forEach(function(r){return r.style.display=t?"none":"block"})},ju=function(t,r){if(ca=pr.documentElement,Jt=pr.body,v$=[$t,pr,ca,Jt],ts&&!t&&!wp){Ci(Tt,"scrollEnd",X7);return}tR(),$n=Tt.isRefreshing=!0,wp||Q7();var i=Sc("refreshInit");B7&&Tt.sort(),r||C$(),St.forEach(function(n){ln(n)&&(n.smooth&&(n.target.style.scrollBehavior="auto"),n(0))}),wt.slice(0).forEach(function(n){return n.refresh()}),wp=!1,wt.forEach(function(n){if(n._subPinOffset&&n.pin){var a=n.vars.horizontal?"offsetWidth":"offsetHeight",s=n.pin[a];n.revert(!0,1),n.adjustPinSpacing(n.pin[a]-s),n.refresh()}}),Mx=1,WC(!0),wt.forEach(function(n){var a=Js(n.scroller,n._dir),s=n.vars.end==="max"||n._endClamp&&n.end>a,o=n._startClamp&&n.start>=a;(s||o)&&n.setPositions(o?a-1:n.start,s?Math.max(o?a:n.start+1,a):n.end,!0)}),WC(!1),Mx=0,i.forEach(function(n){return n&&n.render&&n.render(-1)}),St.forEach(function(n){ln(n)&&(n.smooth&&requestAnimationFrame(function(){return n.target.style.scrollBehavior="smooth"}),n.rec&&n(n.rec))}),eR(b$,1),_y.pause(),lc++,$n=2,Ho(2),wt.forEach(function(n){return ln(n.vars.onRefresh)&&n.vars.onRefresh(n)}),$n=Tt.isRefreshing=!1,Sc("refresh")},Ax=0,a_=1,kp,Ho=function(t){if(t===2||!$n&&!wp){Tt.isUpdating=!0,kp&&kp.update(0);var r=wt.length,i=nn(),n=i-cb>=50,a=r&&wt[0].scroll();if(a_=Ax>a?-1:1,$n||(Ax=a),n&&(ts&&!V1&&i-ts>200&&(ts=0,Sc("scrollEnd")),Gf=cb,cb=i),a_<0){for(wn=r;wn-- >0;)wt[wn]&&wt[wn].update(0,n);a_=1}else for(wn=0;wn<r;wn++)wt[wn]&&wt[wn].update(0,n);Tt.isUpdating=!1}bm=0},Dx=[W7,Z7,$$,w$,ja+Cp,ja+$p,ja+Tp,ja+Sp,"display","flexShrink","float","zIndex","gridColumnStart","gridColumnEnd","gridRowStart","gridRowEnd","gridArea","justifySelf","alignSelf","placeSelf","order"],s_=Dx.concat([sc,oc,"boxSizing","max"+kh,"max"+S$,"position",ja,si,si+Tp,si+$p,si+Cp,si+Sp]),wpe=function(t,r,i){Wd(i);var n=t._gsap;if(n.spacerIsNative)Wd(n.spacerState);else if(t._gsap.swappedIn){var a=r.parentNode;a&&(a.insertBefore(t,r),a.removeChild(r))}t._gsap.swappedIn=!1},fb=function(t,r,i,n){if(!t._gsap.swappedIn){for(var a=Dx.length,s=r.style,o=t.style,l;a--;)l=Dx[a],s[l]=i[l];s.position=i.position==="absolute"?"absolute":"relative",i.display==="inline"&&(s.display="inline-block"),o[$$]=o[w$]="auto",s.flexBasis=i.flexBasis||"auto",s.overflow="visible",s.boxSizing="border-box",s[sc]=yy(t,Mn)+pi,s[oc]=yy(t,mi)+pi,s[si]=o[ja]=o[Z7]=o[W7]="0",Wd(n),o[sc]=o["max"+kh]=i[sc],o[oc]=o["max"+S$]=i[oc],o[si]=i[si],t.parentNode!==r&&(t.parentNode.insertBefore(r,t),r.appendChild(t)),t._gsap.swappedIn=!0}},$pe=/([A-Z])/g,Wd=function(t){if(t){var r=t.t.style,i=t.length,n=0,a,s;for((t.t._gsap||je.core.getCache(t.t)).uncache=1;n<i;n+=2)s=t[n+1],a=t[n],s?r[a]=s:r[a]&&r.removeProperty(a.replace($pe,"-$1").toLowerCase())}},n0=function(t){for(var r=s_.length,i=t.style,n=[],a=0;a<r;a++)n.push(s_[a],i[s_[a]]);return n.t=t,n},Spe=function(t,r,i){for(var n=[],a=t.length,s=i?8:0,o;s<a;s+=2)o=t[s],n.push(o,o in r?r[o]:t[s+1]);return n.t=t.t,n},o_={left:0,top:0},ZC=function(t,r,i,n,a,s,o,l,u,c,d,h,f,p){ln(t)&&(t=t(l)),oa(t)&&t.substr(0,3)==="max"&&(t=h+(t.charAt(4)==="="?i_("0"+t.substr(3),i):0));var m=f?f.time():0,g,v,x;if(f&&f.seek(0),isNaN(t)||(t=+t),Wf(t))f&&(t=je.utils.mapRange(f.scrollTrigger.start,f.scrollTrigger.end,0,h,t)),o&&n_(o,i,n,!0);else{ln(r)&&(r=r(l));var _=(t||"0").split(" "),y,w,$,S;
vendor: 8,800 bytes, line 82
82x=zn(r,l)||Jt,y=Do(x)||{},(!y||!y.left&&!y.top)&&Ua(x).display==="none"&&(S=x.style.display,x.style.display="block",y=Do(x),S?x.style.display=S:x.style.removeProperty("display")),w=i_(_[0],y[n.d]),$=i_(_[1]||"0",i),t=y[n.p]-u[n.p]-c+w+a-$,o&&n_(o,$,n,i-$<20||o._isStart&&$>20),i-=i-$}if(p&&(l[p]=t||-.001,t<0&&(t=0)),s){var E=t+i,C=s._isStart;g="scroll"+n.d2,n_(s,E,n,C&&E>20||!C&&(d?Math.max(Jt[g],ca[g]):s.parentNode[g])<=E+1),d&&(u=Do(o),d&&(s.style[n.op.p]=u[n.op.p]-n.op.m-s._offset+pi))}return f&&x&&(g=Do(x),f.seek(h),v=Do(x),f._caScrollDist=g[n.p]-v[n.p],t=t/f._caScrollDist*h),f&&f.seek(m),f?t:Math.round(t)},Tpe=/(webkit|moz|length|cssText|inset)/i,KC=function(t,r,i,n){if(t.parentNode!==r){var a=t.style,s,o;if(r===Jt){t._stOrig=a.cssText,o=Ua(t);for(s in o)!+s&&!Tpe.test(s)&&o[s]&&typeof a[s]=="string"&&s!=="0"&&(a[s]=o[s]);a.top=i,a.left=n}else a.cssText=t._stOrig;je.core.getCache(t).uncache=1,r.appendChild(t)}},rR=function(t,r,i){var n=r,a=n;return function(s){var o=Math.round(t());return o!==n&&o!==a&&Math.abs(o-n)>3&&Math.abs(o-a)>3&&(s=o,i&&i()),a=n,n=Math.round(s),n}},a0=function(t,r,i){var n={};n[r.p]="+="+i,je.set(t,n)},XC=function(t,r){var i=ou(t,r),n="_scroll"+r.p2,a=function s(o,l,u,c,d){var h=s.tween,f=l.onComplete,p={};u=u||i();var m=rR(i,u,function(){h.kill(),s.tween=0});return d=c&&d||0,c=c||o-u,h&&h.kill(),l[n]=o,l.inherit=!1,l.modifiers=p,p[n]=function(){return m(u+c*h.ratio+d*h.ratio*h.ratio)},l.onUpdate=function(){St.cache++,s.tween&&Ho()},l.onComplete=function(){s.tween=0,f&&f.call(h)},h=s.tween=je.to(t,l),h};return t[n]=i,i.wheelHandler=function(){return a.tween&&a.tween.kill()&&(a.tween=0)},Ci(t,"wheel",i.wheelHandler),Tt.isTouch&&Ci(t,"touchmove",i.wheelHandler),a},Tt=(function(){function e(r,i){od||e.register(je)||console.warn("Please gsap.registerPlugin(ScrollTrigger)"),Px(this),this.init(r,i)}var t=e.prototype;return t.init=function(i,n){if(this.progress=this.start=0,this.vars&&this.kill(!0,!0),!Hf){this.update=this.refresh=this.kill=Vs;return}i=qC(oa(i)||Wf(i)||i.nodeType?{trigger:i}:i,r0);var a=i,s=a.onUpdate,o=a.toggleClass,l=a.id,u=a.onToggle,c=a.onRefresh,d=a.scrub,h=a.trigger,f=a.pin,p=a.pinSpacing,m=a.invalidateOnRefresh,g=a.anticipatePin,v=a.onScrubComplete,x=a.onSnapComplete,_=a.once,y=a.snap,w=a.pinReparent,$=a.pinSpacer,S=a.containerAnimation,E=a.fastScrollEnd,C=a.preventOverlaps,I=i.horizontal||i.containerAnimation&&i.horizontal!==!1?Mn:mi,P=!d&&d!==0,T=zn(i.scroller||$t),D=je.core.getCache(T),A=wc(T),z=("pinType"in i?i.pinType:Xl(T,"pinType")||A&&"fixed")==="fixed",R=[i.onEnter,i.onLeave,i.onEnterBack,i.onLeaveBack],O=P&&i.toggleActions.split(" "),V="markers"in i?i.markers:r0.markers,Y=A?0:parseFloat(Ua(T)["border"+I.p2+kh])||0,F=this,ae=i.onRefreshInit&&function(){return i.onRefreshInit(F)},ue=mpe(T,A,I),Z=gpe(T,A),K=0,fe=0,ve=0,$e=ou(T,I),Re,Oe,ze,Be,qe,j,W,G,ie,U,ne,me,J,N,q,te,ee,oe,Se,we,De,Ue,xt,kt,ot,rr,Cr,xi,Vt,ge,B,re,_e,Ee,Fe,ht,Et,lr,Br;if(F._startClamp=F._endClamp=!1,F._dir=I,g*=45,F.scroller=T,F.scroll=S?S.time.bind(S):$e,Be=$e(),F.vars=i,n=n||i.animation,"refreshPriority"in i&&(B7=1,i.refreshPriority===-9999&&(kp=F)),D.tweenScroll=D.tweenScroll||{top:XC(T,mi),left:XC(T,Mn)},F.tweenTo=Re=D.tweenScroll[I.p],F.scrubDuration=function(Ie){_e=Wf(Ie)&&Ie,_e?re?re.duration(Ie):re=je.to(n,{ease:"expo",totalProgress:"+=0",inherit:!1,duration:_e,paused:!0,onComplete:function(){return v&&v(F)}}):(re&&re.progress(1).kill(),re=0)},n&&(n.vars.lazy=!1,n._initted&&!F.isReverted||n.vars.immediateRender!==!1&&i.immediateRender!==!1&&n.duration()&&n.render(0,!0,!0),F.animation=n.pause(),n.scrollTrigger=F,F.scrubDuration(d),ge=0,l||(l=n.vars.id)),y&&((!Iu(y)||y.push)&&(y={snapTo:y}),"scrollBehavior"in Jt.style&&je.set(A?[Jt,ca]:T,{scrollBehavior:"auto"}),St.forEach(function(Ie){return ln(Ie)&&Ie.target===(A?pr.scrollingElement||ca:T)&&(Ie.smooth=!1)}),ze=ln(y.snapTo)?y.snapTo:y.snapTo==="labels"?ype(n):y.snapTo==="labelsDirectional"?vpe(n):y.directional!==!1?function(Ie,st){return T$(y.snapTo)(Ie,nn()-fe<500?0:st.direction)}:je.utils.snap(y.snapTo),Ee=y.duration||{min:.1,max:2},Ee=Iu(Ee)?xp(Ee.min,Ee.max):xp(Ee,Ee),Fe=je.delayedCall(y.delay||_e/2||.1,function(){var Ie=$e(),st=nn()-fe<500,Qe=Re.tween;if((st||Math.abs(F.getVelocity())<10)&&!Qe&&!V1&&K!==Ie){var pt=(Ie-j)/N,wi=n&&!P?n.totalProgress():pt,Lt=st?0:(wi-B)/(nn()-Gf)*1e3||0,Wr=je.utils.clamp(-pt,1-pt,Kc(Lt/2)*Lt/.185),Yi=pt+(y.inertia===!1?0:Wr),jr,kr,ur=y,us=ur.onStart,Or=ur.onInterrupt,ia=ur.onComplete;if(jr=ze(Yi,F),Wf(jr)||(jr=Yi),kr=Math.max(0,Math.round(j+jr*N)),Ie<=W&&Ie>=j&&kr!==Ie){if(Qe&&!Qe._initted&&Qe.data<=Kc(kr-Ie))return;y.inertia===!1&&(Wr=jr-pt),Re(kr,{duration:Ee(Kc(Math.max(Kc(Yi-wi),Kc(jr-wi))*.185/Lt/.05||0)),ease:y.ease||"power3",data:Kc(kr-Ie),onInterrupt:function(){return Fe.restart(!0)&&Or&&Or(F)},onComplete:function(){F.update(),K=$e(),n&&!P&&(re?re.resetTo("totalProgress",jr,n._tTime/n._tDur):n.progress(jr)),ge=B=n&&!P?n.totalProgress():F.progress,x&&x(F),ia&&ia(F)}},Ie,Wr*N,kr-Ie-Wr*N),us&&us(F,Re.tween)}}else F.isActive&&K!==Ie&&Fe.restart(!0)}).pause()),l&&(Ix[l]=F),h=F.trigger=zn(h||f!==!0&&f),Br=h&&h._gsap&&h._gsap.stRevert,Br&&(Br=Br(F)),f=f===!0?h:zn(f),oa(o)&&(o={targets:h,className:o}),f&&(p===!1||p===ja||(p=!p&&f.parentNode&&f.parentNode.style&&Ua(f.parentNode).display==="flex"?!1:si),F.pin=f,Oe=je.core.getCache(f),Oe.spacer?q=Oe.pinState:($&&($=zn($),$&&!$.nodeType&&($=$.current||$.nativeElement),Oe.spacerIsNative=!!$,$&&(Oe.spacerState=n0($))),Oe.spacer=oe=$||pr.createElement("div"),oe.classList.add("pin-spacer"),l&&oe.classList.add("pin-spacer-"+l),Oe.pinState=q=n0(f)),i.force3D!==!1&&je.set(f,{force3D:!0}),F.spacer=oe=Oe.spacer,Vt=Ua(f),kt=Vt[p+I.os2],we=je.getProperty(f),De=je.quickSetter(f,I.a,pi),fb(f,oe,Vt),ee=n0(f)),V){me=Iu(V)?qC(V,GC):GC,U=i0("scroller-start",l,T,I,me,0),ne=i0("scroller-end",l,T,I,me,0,U),Se=U["offset"+I.op.d2];var ls=zn(Xl(T,"content")||T);G=this.markerStart=i0("start",l,ls,I,me,Se,0,S),ie=this.markerEnd=i0("end",l,ls,I,me,Se,0,S),S&&(lr=je.quickSetter([G,ie],I.a,pi)),!z&&!(ro.length&&Xl(T,"fixedMarkers")===!0)&&(_pe(A?Jt:T),je.set([U,ne],{force3D:!0}),rr=je.quickSetter(U,I.a,pi),xi=je.quickSetter(ne,I.a,pi))}if(S){var Ke=S.vars.onUpdate,et=S.vars.onUpdateParams;S.eventCallback("onUpdate",function(){F.update(0,0,1),Ke&&Ke.apply(S,et||[])})}if(F.previous=function(){return wt[wt.indexOf(F)-1]},F.next=function(){return wt[wt.indexOf(F)+1]},F.revert=function(Ie,st){if(!st)return F.kill(!0);var Qe=Ie!==!1||!F.enabled,pt=Ji;Qe!==F.isReverted&&(Qe&&(ht=Math.max($e(),F.scroll.rec||0),ve=F.progress,Et=n&&n.progress()),G&&[G,ie,U,ne].forEach(function(wi){return wi.style.display=Qe?"none":"block"}),Qe&&(Ji=F,F.update(Qe)),f&&(!w||!F.isActive)&&(Qe?wpe(f,oe,q):fb(f,oe,Ua(f),ot)),Qe||F.update(Qe),Ji=pt,F.isReverted=Qe)},F.refresh=function(Ie,st,Qe,pt){if(!((Ji||!F.enabled)&&!st)){if(f&&Ie&&ts){Ci(e,"scrollEnd",X7);return}!$n&&ae&&ae(F),Ji=F,Re.tween&&!Qe&&(Re.tween.kill(),Re.tween=0),re&&re.pause(),m&&n&&(n.revert({kill:!1}).invalidate(),n.getChildren?n.getChildren(!0,!0,!1).forEach(function(yl){return yl.vars.immediateRender&&yl.render(0,!0,!0)}):n.vars.immediateRender&&n.render(0,!0,!0)),F.isReverted||F.revert(!0,!0),F._subPinOffset=!1;var wi=ue(),Lt=Z(),Wr=S?S.duration():Js(T,I),Yi=N<=.01||!N,jr=0,kr=pt||0,ur=Iu(Qe)?Qe.end:i.end,us=i.endTrigger||h,Or=Iu(Qe)?Qe.start:i.start||(i.start===0||!h?0:f?"0 0":"0 100%"),ia=F.pinnedContainer=i.pinnedContainer&&zn(i.pinnedContainer,F),Os=h&&Math.max(0,wt.indexOf(F))||0,Ii=Os,Ai,Wi,bu,kg,Zi,fi,Ls,$v,VS,sf,Fs,of,Eg;for(V&&Iu(Qe)&&(of=je.getProperty(U,I.p),Eg=je.getProperty(ne,I.p));Ii-- >0;)fi=wt[Ii],fi.end||fi.refresh(0,1)||(Ji=F),Ls=fi.pin,Ls&&(Ls===h||Ls===f||Ls===ia)&&!fi.isReverted&&(sf||(sf=[]),sf.unshift(fi),fi.revert(!0,!0)),fi!==wt[Ii]&&(Os--,Ii--);for(ln(Or)&&(Or=Or(F)),Or=BC(Or,"start",F),j=ZC(Or,h,wi,I,$e(),G,U,F,Lt,Y,z,Wr,S,F._startClamp&&"_startClamp")||(f?-.001:0),ln(ur)&&(ur=ur(F)),oa(ur)&&!ur.indexOf("+=")&&(~ur.indexOf(" ")?ur=(oa(Or)?Or.split(" ")[0]:"")+ur:(jr=i_(ur.substr(2),wi),ur=oa(Or)?Or:(S?je.utils.mapRange(0,S.duration(),S.scrollTrigger.start,S.scrollTrigger.end,j):j)+jr,us=h)),ur=BC(ur,"end",F),W=Math.max(j,ZC(ur||(us?"100% 0":Wr),us,wi,I,$e()+jr,ie,ne,F,Lt,Y,z,Wr,S,F._endClamp&&"_endClamp"))||-.001,jr=0,Ii=Os;Ii--;)fi=wt[Ii]||{},Ls=fi.pin,Ls&&fi.start-fi._pinPush<=j&&!S&&fi.end>0&&(Ai=fi.end-(F._startClamp?Math.max(0,fi.start):fi.start),(Ls===h&&fi.start-fi._pinPush<j||Ls===ia)&&isNaN(Or)&&(jr+=Ai*(1-fi.progress)),Ls===f&&(kr+=Ai));if(j+=jr,W+=jr,F._startClamp&&(F._startClamp+=jr),F._endClamp&&!$n&&(F._endClamp=W||-.001,W=Math.min(W,Js(T,I))),N=W-j||(j-=.01)&&.001,Yi&&(ve=je.utils.clamp(0,1,je.utils.normalize(j,W,ht))),F._pinPush=kr,G&&jr&&(Ai={},Ai[I.a]="+="+jr,ia&&(Ai[I.p]="-="+$e()),je.set([G,ie],Ai)),f&&!(Mx&&F.end>
vendor: 2,806 bytes, line 82
82=Js(T,I)))Ai=Ua(f),kg=I===mi,bu=$e(),Ue=parseFloat(we(I.a))+kr,!Wr&&W>1&&(Fs=(A?pr.scrollingElement||ca:T).style,Fs={style:Fs,value:Fs["overflow"+I.a.toUpperCase()]},A&&Ua(Jt)["overflow"+I.a.toUpperCase()]!=="scroll"&&(Fs.style["overflow"+I.a.toUpperCase()]="scroll")),fb(f,oe,Ai),ee=n0(f),Wi=Do(f,!0),$v=z&&ou(T,kg?Mn:mi)(),p?(ot=[p+I.os2,N+kr+pi],ot.t=oe,Ii=p===si?yy(f,I)+N+kr:0,Ii&&(ot.push(I.d,Ii+pi),oe.style.flexBasis!=="auto"&&(oe.style.flexBasis=Ii+pi)),Wd(ot),ia&&wt.forEach(function(yl){yl.pin===ia&&yl.vars.pinSpacing!==!1&&(yl._subPinOffset=!0)}),z&&$e(ht)):(Ii=yy(f,I),Ii&&oe.style.flexBasis!=="auto"&&(oe.style.flexBasis=Ii+pi)),z&&(Zi={top:Wi.top+(kg?bu-j:$v)+pi,left:Wi.left+(kg?$v:bu-j)+pi,boxSizing:"border-box",position:"fixed"},Zi[sc]=Zi["max"+kh]=Math.ceil(Wi.width)+pi,Zi[oc]=Zi["max"+S$]=Math.ceil(Wi.height)+pi,Zi[ja]=Zi[ja+Tp]=Zi[ja+$p]=Zi[ja+Cp]=Zi[ja+Sp]="0",Zi[si]=Ai[si],Zi[si+Tp]=Ai[si+Tp],Zi[si+$p]=Ai[si+$p],Zi[si+Cp]=Ai[si+Cp],Zi[si+Sp]=Ai[si+Sp],te=Spe(q,Zi,w),$n&&$e(0)),n?(VS=n._initted,lb(1),n.render(n.duration(),!0,!0),xt=we(I.a)-Ue+N+kr,Cr=Math.abs(N-xt)>1,z&&Cr&&te.splice(te.length-2,2),n.render(0,!0,!0),VS||n.invalidate(!0),n.parent||n.totalTime(n.totalTime()),lb(0)):xt=N,Fs&&(Fs.value?Fs.style["overflow"+I.a.toUpperCase()]=Fs.value:Fs.style.removeProperty("overflow-"+I.a));else if(h&&$e()&&!S)for(Wi=h.parentNode;Wi&&Wi!==Jt;)Wi._pinOffset&&(j-=Wi._pinOffset,W-=Wi._pinOffset),Wi=Wi.parentNode;sf&&sf.forEach(function(yl){return yl.revert(!1,!0)}),F.start=j,F.end=W,Be=qe=$n?ht:$e(),!S&&!$n&&(Be<ht&&$e(ht),F.scroll.rec=0),F.revert(!1,!0),fe=nn(),Fe&&(K=-1,Fe.restart(!0)),Ji=0,n&&P&&(n._initted||Et)&&n.progress()!==Et&&n.progress(Et||0,!0).render(n.time(),!0,!0),(Yi||ve!==F.progress||S||m||n&&!n._initted)&&(n&&!P&&(n._initted||ve||n.vars.immediateRender!==!1)&&n.totalProgress(S&&j<-.001&&!ve?je.utils.normalize(j,W,0):ve,!0),F.progress=Yi||(Be-j)/N===ve?0:ve),f&&p&&(oe._pinOffset=Math.round(F.progress*xt)),re&&re.invalidate(),isNaN(of)||(of-=je.getProperty(U,I.p),Eg-=je.getProperty(ne,I.p),a0(U,I,of),a0(G,I,of-(pt||0)),a0(ne,I,Eg),a0(ie,I,Eg-(pt||0))),Yi&&!$n&&F.update(),c&&!$n&&!J&&(J=!0,c(F),J=!1)}},F.getVelocity=function(){return($e()-qe)/(nn()-Gf)*1e3||0},F.endAnimation=function(){wf(F.callbackAnimation),n&&(re?re.progress(1):n.paused()?P||wf(n,F.direction<0,1):wf(n,n.reversed()))},F.labelToScroll=function(Ie){return n&&n.labels&&(j||F.refresh()||j)+n.labels[Ie]/n.duration()*N||0},F.getTrailing=function(Ie){var st=wt.indexOf(F),Qe=F.direction>0?wt.slice(0,st).reverse():wt.slice(st+1);return(oa(Ie)?Qe.filter(function(pt){return pt.vars.preventOverlaps===Ie}):Qe).filter(function(pt){return F.direction>0?pt.end<=j:pt.start>=W})},F.update=function(Ie,st,Qe){if(!(S&&!Qe&&!Ie)){var pt=$n===!0?ht:F.scroll(),wi=Ie?0:(pt-j)/N,Lt=wi<0?0:wi>
vendor: 9,604 bytes, line 82
821?1:wi||0,Wr=F.progress,Yi,jr,kr,ur,us,Or,ia,Os;if(st&&(qe=Be,Be=S?$e():pt,y&&(B=ge,ge=n&&!P?n.totalProgress():Lt)),g&&f&&!Ji&&!Jg&&ts&&(!Lt&&j<pt+(pt-qe)/(nn()-Gf)*g?Lt=1e-4:Lt===1&&W>pt+(pt-qe)/(nn()-Gf)*g&&(Lt=.9999)),Lt!==Wr&&F.enabled){if(Yi=F.isActive=!!Lt&&Lt<1,jr=!!Wr&&Wr<1,Or=Yi!==jr,us=Or||!!Lt!=!!Wr,F.direction=Lt>Wr?1:-1,F.progress=Lt,us&&!Ji&&(kr=Lt&&!Wr?0:Lt===1?1:Wr===1?2:3,P&&(ur=!Or&&O[kr+1]!=="none"&&O[kr+1]||O[kr],Os=n&&(ur==="complete"||ur==="reset"||ur in n))),C&&(Or||Os)&&(Os||d||!n)&&(ln(C)?C(F):F.getTrailing(C).forEach(function(bu){return bu.endAnimation()})),P||(re&&!Ji&&!Jg?(re._dp._time-re._start!==re._time&&re.render(re._dp._time-re._start),re.resetTo?re.resetTo("totalProgress",Lt,n._tTime/n._tDur):(re.vars.totalProgress=Lt,re.invalidate().restart())):n&&n.totalProgress(Lt,!!(Ji&&(fe||Ie)))),f){if(Ie&&p&&(oe.style[p+I.os2]=kt),!z)De(Yf(Ue+xt*Lt));else if(us){if(ia=!Ie&&Lt>Wr&&W+1>pt&&pt+1>=Js(T,I),w)if(!Ie&&(Yi||ia)){var Ii=Do(f,!0),Ai=pt-j;KC(f,Jt,Ii.top+(I===mi?Ai:0)+pi,Ii.left+(I===mi?0:Ai)+pi)}else KC(f,oe);Wd(Yi||ia?te:ee),Cr&&Lt<1&&Yi||De(Ue+(Lt===1&&!ia?xt:0))}}y&&!Re.tween&&!Ji&&!Jg&&Fe.restart(!0),o&&(Or||_&&Lt&&(Lt<1||!ub))&&vm(o.targets).forEach(function(bu){return bu.classList[Yi||_?"add":"remove"](o.className)}),s&&!P&&!Ie&&s(F),us&&!Ji?(P&&(Os&&(ur==="complete"?n.pause().totalProgress(1):ur==="reset"?n.restart(!0).pause():ur==="restart"?n.restart(!0):n[ur]()),s&&s(F)),(Or||!ub)&&(u&&Or&&db(F,u),R[kr]&&db(F,R[kr]),_&&(Lt===1?F.kill(!1,1):R[kr]=0),Or||(kr=Lt===1?1:3,R[kr]&&db(F,R[kr]))),E&&!Yi&&Math.abs(F.getVelocity())>(Wf(E)?E:2500)&&(wf(F.callbackAnimation),re?re.progress(1):wf(n,ur==="reverse"?1:!Lt,1))):P&&s&&!Ji&&s(F)}if(xi){var Wi=S?pt/S.duration()*(S._caScrollDist||0):pt;rr(Wi+(U._isFlipped?1:0)),xi(Wi)}lr&&lr(-pt/S.duration()*(S._caScrollDist||0))}},F.enable=function(Ie,st){F.enabled||(F.enabled=!0,Ci(T,"resize",Zf),A||Ci(T,"scroll",Xc),ae&&Ci(e,"refreshInit",ae),Ie!==!1&&(F.progress=ve=0,Be=qe=K=$e()),st!==!1&&F.refresh())},F.getTween=function(Ie){return Ie&&Re?Re.tween:re},F.setPositions=function(Ie,st,Qe,pt){if(S){var wi=S.scrollTrigger,Lt=S.duration(),Wr=wi.end-wi.start;Ie=wi.start+Wr*Ie/Lt,st=wi.start+Wr*st/Lt}F.refresh(!1,!1,{start:jC(Ie,Qe&&!!F._startClamp),end:jC(st,Qe&&!!F._endClamp)},pt),F.update()},F.adjustPinSpacing=function(Ie){if(ot&&Ie){var st=ot.indexOf(I.d)+1;ot[st]=parseFloat(ot[st])+Ie+pi,ot[1]=parseFloat(ot[1])+Ie+pi,Wd(ot)}},F.disable=function(Ie,st){if(Ie!==!1&&F.revert(!0,!0),F.enabled&&(F.enabled=F.isActive=!1,st||re&&re.pause(),ht=0,Oe&&(Oe.uncache=1),ae&&$i(e,"refreshInit",ae),Fe&&(Fe.pause(),Re.tween&&Re.tween.kill()&&(Re.tween=0)),!A)){for(var Qe=wt.length;Qe--;)if(wt[Qe].scroller===T&&wt[Qe]!==F)return;$i(T,"resize",Zf),A||$i(T,"scroll",Xc)}},F.kill=function(Ie,st){F.disable(Ie,st),re&&!st&&re.kill(),l&&delete Ix[l];var Qe=wt.indexOf(F);Qe>=0&&wt.splice(Qe,1),Qe===wn&&a_>0&&wn--,Qe=0,wt.forEach(function(pt){return pt.scroller===F.scroller&&(Qe=1)}),Qe||$n||(F.scroll.rec=0),n&&(n.scrollTrigger=null,Ie&&n.revert({kill:!1}),st||n.kill()),G&&[G,ie,U,ne].forEach(function(pt){return pt.parentNode&&pt.parentNode.removeChild(pt)}),kp===F&&(kp=0),f&&(Oe&&(Oe.uncache=1),Qe=0,wt.forEach(function(pt){return pt.pin===f&&Qe++}),Qe||(Oe.spacer=0)),i.onKill&&i.onKill(F)},wt.push(F),F.enable(!1,!1),Br&&Br(F),n&&n.add&&!N){var It=F.update;F.update=function(){F.update=It,St.cache++,j||W||F.refresh()},je.delayedCall(.01,F.update),N=.01,j=W=0}else F.refresh();f&&xpe()},e.register=function(i){return od||(je=i||G7(),q7()&&window.document&&e.enable(),od=Hf),od},e.defaults=function(i){if(i)for(var n in i)r0[n]=i[n];return r0},e.disable=function(i,n){Hf=0,wt.forEach(function(s){return s[n?"kill":"disable"](i)}),$i($t,"wheel",Xc),$i(pr,"scroll",Xc),clearInterval(Xg),$i(pr,"touchcancel",Vs),$i(Jt,"touchstart",Vs),e0($i,pr,"pointerdown,touchstart,mousedown",UC),e0($i,pr,"pointerup,touchend,mouseup",VC),_y.kill(),Qg($i);for(var a=0;a<St.length;a+=3)t0($i,St[a],St[a+1]),t0($i,St[a],St[a+2])},e.enable=function(){if($t=window,pr=document,ca=pr.documentElement,Jt=pr.body,je&&(vm=je.utils.toArray,xp=je.utils.clamp,Px=je.core.context||Vs,lb=je.core.suppressOverwrites||Vs,b$=$t.history.scrollRestoration||"auto",Ax=$t.pageYOffset||0,je.core.globals("ScrollTrigger",e),Jt)){Hf=1,Yd=document.createElement("div"),Yd.style.height="100vh",Yd.style.position="absolute",tR(),ppe(),ii.register(je),e.isTouch=ii.isTouch,El=ii.isTouch&&/(iPad|iPhone|iPod|Mac)/g.test(navigator.userAgent),Ex=ii.isTouch===1,Ci($t,"wheel",Xc),v$=[$t,pr,ca,Jt],je.matchMedia?(e.matchMedia=function(u){var c=je.matchMedia(),d;for(d in u)c.add(d,u[d]);return c},je.addEventListener("matchMediaInit",function(){Q7(),C$()}),je.addEventListener("matchMediaRevert",function(){return J7()}),je.addEventListener("matchMedia",function(){ju(0,1),Sc("matchMedia")}),je.matchMedia().add("(orientation: portrait)",function(){return hb(),hb})):console.warn("Requires GSAP 3.11.0 or later"),hb(),Ci(pr,"scroll",Xc);var i=Jt.hasAttribute("style"),n=Jt.style,a=n.borderTopStyle,s=je.core.Animation.prototype,o,l;for(s.revert||Object.defineProperty(s,"revert",{value:function(){return this.time(-.01,!0)}}),n.borderTopStyle="solid",o=Do(Jt),mi.m=Math.round(o.top+mi.sc())||0,Mn.m=Math.round(o.left+Mn.sc())||0,a?n.borderTopStyle=a:n.removeProperty("border-top-style"),i||(Jt.setAttribute("style",""),Jt.removeAttribute("style")),Xg=setInterval(HC,250),je.delayedCall(.5,function(){return Jg=0}),Ci(pr,"touchcancel",Vs),Ci(Jt,"touchstart",Vs),e0(Ci,pr,"pointerdown,touchstart,mousedown",UC),e0(Ci,pr,"pointerup,touchend,mouseup",VC),kx=je.utils.checkPrefix("transform"),s_.push(kx),od=nn(),_y=je.delayedCall(.2,ju).pause(),ld=[pr,"visibilitychange",function(){var u=$t.innerWidth,c=$t.innerHeight;pr.hidden?(zC=u,NC=c):(zC!==u||NC!==c)&&Zf()},pr,"DOMContentLoaded",ju,$t,"load",ju,$t,"resize",Zf],Qg(Ci),wt.forEach(function(u){return u.enable(0,1)}),l=0;l<St.length;l+=3)t0($i,St[l],St[l+1]),t0($i,St[l],St[l+2])}},e.config=function(i){"limitCallbacks"in i&&(ub=!!i.limitCallbacks);var n=i.syncInterval;n&&clearInterval(Xg)||(Xg=n)&&setInterval(HC,n),"ignoreMobileResize"in i&&(Ex=e.isTouch===1&&i.ignoreMobileResize),"autoRefreshEvents"in i&&(Qg($i)||Qg(Ci,i.autoRefreshEvents||"none"),j7=(i.autoRefreshEvents+"").indexOf("resize")===-1)},e.scrollerProxy=function(i,n){var a=zn(i),s=St.indexOf(a),o=wc(a);~s&&St.splice(s,o?6:2),n&&(o?ro.unshift($t,n,Jt,n,ca,n):ro.unshift(a,n))},e.clearMatchMedia=function(i){wt.forEach(function(n){return n._ctx&&n._ctx.query===i&&n._ctx.kill(!0,!0)})},e.isInViewport=function(i,n,a){var s=(oa(i)?zn(i):i).getBoundingClientRect(),o=s[a?sc:oc]*n||0;return a?s.right-o>0&&s.left+o<$t.innerWidth:s.bottom-o>0&&s.top+o<$t.innerHeight},e.positionInViewport=function(i,n,a){oa(i)&&(i=zn(i));var s=i.getBoundingClientRect(),o=s[a?sc:oc],l=n==null?o/2:n in vy?vy[n]*o:~n.indexOf("%")?parseFloat(n)*o/100:parseFloat(n)||0;return a?(s.left+l)/$t.innerWidth:(s.top+l)/$t.innerHeight},e.killAll=function(i){if(wt.slice(0).forEach(function(a){return a.vars.id!=="ScrollSmoother"&&a.kill()}),i!==!0){var n=$c.killAll||[];$c={},n.forEach(function(a){return a()})}},e})();Tt.version="3.14.2";Tt.saveStyles=function(e){return e?vm(e).forEach(function(t){if(t&&t.style){var r=aa.indexOf(t);r>=0&&aa.splice(r,5),aa.push(t,t.style.cssText,t.getBBox&&t.getAttribute("transform"),je.core.getCache(t),Px())}}):aa};Tt.revert=function(e,t){return C$(!e,t)};Tt.create=function(e,t){return new Tt(e,t)};Tt.refresh=function(e){return e?Zf(!0):(od||Tt.register())&&ju(!0)};Tt.update=function(e){return++St.cache&&Ho(e===!0?2:0)};Tt.clearScrollMemory=eR;Tt.maxScroll=function(e,t){return Js(e,t?Mn:mi)};Tt.getScrollFunc=function(e,t){return ou(zn(e),t?Mn:mi)};Tt.getById=function(e){return Ix[e]};Tt.getAll=function(){return wt.filter(function(e){return e.vars.id!=="ScrollSmoother"})};Tt.isScrolling=function(){return!!ts};Tt.snapDirectional=T$;Tt.addEventListener=function(e,t){var r=$c[e]||($c[e]=[]);~r.indexOf(t)||r.push(t)};Tt.removeEventListener=function(e,t){var r=$c[e],i=r&&r.indexOf(t);i>=0&&r.splice(i,1)};Tt.batch=function(e,t){var r=[],i={},n=t.interval||.016,a=t.batchMax||1e9,s=function(u,c){var d=[],h=[],f=je.delayedCall(n,function(){c(d,h),d=[],h=[]}).pause();return function(p){d.length||f.restart(!0),d.push(p.trigger),h.push(p),a<=d.length&&f.progress(1)}},o;for(o in t)i[o]=o.substr(0,2)==="on"&&ln(t[o])&&o!=="onRefreshInit"?s(o,t[o]):t[o];return ln(a)&&(a=a(),Ci(Tt,"refresh",function(){return a=t.batchMax()})),vm(e).forEach(function(l){var u={};for(o in i)u[o]=i[o];u.trigger=l,r.push(Tt.create(u))}),r};var JC=function(t,r,i,n){return r>n?t(n):r<0&&t(0),i>n?(n-r)/(i-r):i<0?r/(r-i):1},pb=function e(t,r){r===!0?t.style.removeProperty("touch-action"):t.style.touchAction=r===!0?"auto":r?"pan-"+r+(ii.isTouch?" pinch-zoom":""):"none",t===ca&&e(Jt,r)},s0={auto:1,scroll:1},Cpe=function(t){var r=t.event,i=t.target,n=t.axis,a=(r.changedTouches?r.changedTouches[0]:r).target,s=a._gsap||je.core.getCache(a),o=nn(),l;if(!s._isScrollT||o-s._isScrollT>2e3){for(;a&&a!==Jt&&(a.scrollHeight<=a.clientHeight&&a.scrollWidth<=a.clientWidth||!(s0[(l=Ua(a)).overflowY]||s0[l.overflowX]));)a=a.parentNode;s._isScroll=a&&a!==i&&!wc(a)&&(s0[(l=Ua(a)).overflowY]||s0[l.overflowX]),s._isScrollT=o}(s._isScroll||n==="x")&&(r.stopPropagation(),r._gsapAllow=!0)},iR=function(t,r,i,n){return ii.create({target:t,capture:!0,debounce:!1,lockAxis:!0,type:r,onWheel:n=n&&Cpe,onPress:n,onDrag:n,onScroll:n,onEnable:function(){return i&&Ci(pr,ii.eventTypes[0],ek,!1,!0)},onDisable:function(){return $i(pr,ii.eventTypes[0],ek,!0)}})}
vendor: 1,647 bytes, line 82
82,kpe=/(input|label|select|textarea)/i,QC,ek=function(t){var r=kpe.test(t.target.tagName);(r||QC)&&(t._gsapAllow=!0,QC=r)},Epe=function(t){Iu(t)||(t={}),t.preventDefault=t.isNormalizer=t.allowClicks=!0,t.type||(t.type="wheel,touch"),t.debounce=!!t.debounce,t.id=t.id||"normalizer";var r=t,i=r.normalizeScrollX,n=r.momentum,a=r.allowNestedScroll,s=r.onRelease,o,l,u=zn(t.target)||ca,c=je.core.globals().ScrollSmoother,d=c&&c.get(),h=El&&(t.content&&zn(t.content)||d&&t.content!==!1&&!d.smooth()&&d.content()),f=ou(u,mi),p=ou(u,Mn),m=1,g=(ii.isTouch&&$t.visualViewport?$t.visualViewport.scale*$t.visualViewport.width:$t.outerWidth)/$t.innerWidth,v=0,x=ln(n)?function(){return n(o)}:function(){return n||2.8},_,y,w=iR(u,t.type,!0,a),$=function(){return y=!1},S=Vs,E=Vs,C=function(){l=Js(u,mi),E=xp(El?1:0,l),i&&(S=xp(0,Js(u,Mn))),_=lc},I=function(){h._gsap.y=Yf(parseFloat(h._gsap.y)+f.offset)+"px",h.style.transform="matrix3d(1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, "+parseFloat(h._gsap.y)+", 0, 1)",f.offset=f.cacheID=0},P=function(){if(y){requestAnimationFrame($);var V=Yf(o.deltaY/2),Y=E(f.v-V);if(h&&Y!==f.v+f.offset){f.offset=Y-f.v;var F=Yf((parseFloat(h&&h._gsap.y)||0)-f.offset);h.style.transform="matrix3d(1, 0, 0, 0, 0, 1, 0, 0, 0, 0, 1, 0, 0, "+F+", 0, 1)",h._gsap.y=F+"px",f.cacheID=St.cache,Ho()}return!0}f.offset&&I(),y=!0},T,D,A,z,R=function(){C(),T.isActive()&&T.vars.scrollY>l&&(f()>l?T.progress(1)&&f(l):T.resetTo("scrollY",l))};return h&&je.set(h,{y:"+=0"}),t.ignoreCheck=function(O){return El&&O.type==="touchmove"&&P()||m>1.05&&O.type!=="touchstart"||o.isGesturing||O.touches&&O.touches.length>1},t.onPress=function(){y=!1;var O=m;
82m=Yf(($t.visualViewport&&$t.visualViewport.scale||1)/g),T.pause(),O!==m&&pb(u,m>1.01?!0:i?!1:"x"),D=p(),A=f(),C(),_=lc},t.onRelease=t.onGestureStart=function(O,V){if(f.offset&&I(),!V)z.restart(!0);else{St.cache++;var Y=x(),F,ae;i&&(F=p(),ae=F+Y*.05*-O.velocityX/.227,Y*=JC(p,F,ae,Js(u,Mn)),T.vars.scrollX=S(ae)),F=f(),ae=F+Y*.05*-O.velocityY/.227,Y*=JC(f,F,ae,Js(u,mi)),T.vars.scrollY=E(ae),T.invalidate().duration(Y).play(.01),(El&&T.vars.scrollY>=l||F>=l-1)&&je.to({},{onUpdate:R,duration:Y})}s&&s(O)},t.onWheel=function(){T._ts&&T.pause(),nn()-v>1e3&&(_=0,v=nn())},t.onChange=function(O,V,Y,F,ae){if(lc!==_&&C(),V&&i&&p(S(F[2]===V?D+(O.startX-O.x):p()+V-F[1])),Y){f.offset&&I();var ue=ae[2]===Y,Z=ue?A+O.startY-O.y:f()+Y-ae[1],K=E(Z);ue&&Z!==K&&(A+=K-Z),f(K)}(Y||V)&&Ho()},t.onEnable=function(){pb(u,i?!1:"x"),Tt.addEventListener("refresh",R),Ci($t,"resize",R),f.smooth&&(f.target.style.scrollBehavior="auto",f.smooth=p.smooth=!1),w.enable()},t.onDisable=function(){pb(u,!0),$i($t,"resize",R),Tt.removeEventListener("refresh",R),w.kill()},t.lockAxis=t.lockAxis!==!1,o=new ii(t),o.iOS=El,El&&!f()&&f(1),El&&je.ticker.add(Vs),z=o._dc,T=je.to(o,{ease:"power4",paused:!0,inherit:!1,scrollX:i?"+=0.1":"+=0",scrollY:"+=0.1",modifiers:{scrollY:rR(f,f(),function(){return T.pause()})},onUpdate:Ho,onComplete:z.vars.onComplete}),o};Tt.sort=function(e){if(ln(e))return wt.sort(e);var t=$t.pageYOffset||0;return Tt.getAll().forEach(function(r){return r._sortY=r.trigger?t+r.trigger.getBoundingClientRect().top:r.start+$t.innerHeight}),wt.sort(e||function(r,i){return(r.vars.refreshPriority||0)*-1e6+(r.vars.containerAnimation?1e6:r._sortY)-((i.vars.containerAnimation?1e6:i._sortY)+(i.vars.refreshPriority||0)*-1e6)})};Tt.observe=function(e){return new ii(e)};Tt.normalizeScroll=function(e){if(typeof e>"u")return xn;if(e===!0&&xn)return xn.enable();if(e===!1){xn&&xn.kill(),xn=e;return}var t=e instanceof ii?e:Epe(e);return xn&&xn.target===t.target&&xn.kill(),wc(t.target)&&(xn=t),t};Tt.core={_getVelocityProp:Cx,_inputObserver:iR,_scrollers:St,_proxies:ro,bridge:{ss:function(){ts||Sc("scrollStart"),ts=nn()},ref:function(){return Ji}}};G7()&&je.registerPlugin(Tt);const Ppe={key:0,class:"sticky top-16 left-0 mb-6 md:mb-8 w-full bg-white bg-opacity-80 py-4",style:{"z-index":"49"}},Mpe={key:0,class:"list-none flex flex-wrap font-primary justify-center w-full mb-2",ref:"stickyNav",style:{"z-index":"49"}},Ipe=["onClick"],Ape={key:1},Dpe={key:0},Rpe={class:"min-h-24 h-full mb-0 lg:w-1/2 w-full"},Ope={class:"w-full lg:w-1/3 flex-1 py-8 lg:py-0 px-4 md:px-6 lg:px-10 xl:px-24 text-ag-dark-grey"},Lpe=["innerHTML"],Fpe=["innerHTML"],zpe=["innerHTML"],Npe={class:"flex flex-wrap font-primary md:mb-4"},Bpe=["innerHTML"],jpe=["innerHTML"],Upe={key:0,class:"font-primary text-2xl md:py-4 text-ag-black"},Vpe={class:""},qpe={class:"flex flex-wrap mt-6 w-full md:justify-start"},Gpe={class:"my-1"},Hpe=["onClick"],Ype={key:0,class:"my-1"},Wpe=["href"],Zpe={key:1,class:"my-1"},Kpe=["onClick"],Xpe={key:2,class:"my-1"},Jpe=["onClick"],Qpe={key:3,class:"my-1"},eme=["onClick"],tme={key:0,class:"fixed top-0 left-0 w-full z-50 h-screen bg-black bg-opacity-50 p-0 xl:p-0 flex justify-center items-center"},rme={class:"h-full flex flex-col",style:{width:"95%",height:"95%"}},ime={class:"bg-white bg-opacity-90 flex justify-between items-center p-3 xl:p-4 shadow z-50"},nme={class:"text-xs xl:text-sm font-light m-0"},ame={key:0,class:"flex-1 bg-white p-4 overflow-y-scroll"},sme={key:1,class:"flex-1 bg-white p-4 overflow-y-scroll"},ome={key:2,class:"flex-1 bg-white p-4 overflow-y-scroll"},lme={key:1,class:"py-24 text-ag-brown-grey text-xl text-center"},ume={key:2,class:"w-full flex justify-center items-center gap-1 mt-24"},cme=["disabled"],dme={class:"text-center text-xs mt-2 text-gray-400"},hme={__name:"SectionList",props:{custom:{type:Boolean,default:!1},filters:{type:Boolean,default:!1},listingIds:{type:Array,default:()=>[]},category:{type:String,default:""},bookNowLabel:{type:String,default:"Book now"},enquireLabel:{type:String,default:"Enquire"},countryTaxonomy:{type:String,default:""}},setup(e){_p.registerPlugin(Tt);const t=e,r=se(!0),i=se(!1),n=se([]),a=se([]),s=An({skip:0,take:15,total:0}),o=se("All"),l=se(""),u=se(""),c=se(""),d=se("United States"),h=se(["Angola","Botswana","Comoros","Eswatini","Lesotho","Madagascar","Malawi","Mauritius","Mozambique","Namibia","Seychelles","South Africa","Tanzania","Zambia","Zimbabwe"]),f=H(()=>{let y=n.value;return l.value!==""&&(y=y.filter(w=>{const $=(w.header_destination??"").toLowerCase(),S=(w.header_country??"").toLowerCase(),E=(w.content_paragraph??"").toLowerCase(),C=l.value.toLowerCase();return $.includes(C)||S.includes(C)||E.includes(C)})),y});function p(){_p.utils.toArray(".listing-item").forEach(y=>{_p.from(y,{opacity:0,duration:.2,ease:"power1.inOut",scrollTrigger:{trigger:y,start:"top bottom",toggleActions:"play none none none"}})})}function m(y){var $;const w=(($=y.button_link)==null?void 0:$.url)||y.url;typeof w=="string"?window.location=w:console.warn("Invalid link structure:",y.button_link)}function g(){s.skip=s.skip+s.take,v()}async function v(){var w;const y=[];t.custom&&((w=t.listingIds)!=null&&w.length)&&y.push("listings="+t.listingIds.join(",")),t.category&&y.push("category="+t.category),o.value!=="All"&&y.push("country="+o.value),y.push("skip="+s.skip),y.push("take="+s.take),r.value=!0,i.value=!1,Rt.get(window.proxyUri+"/api/rest/"+(t.custom?"listings/custom":"listings")+"?"+y.join("&")).then($=>{const S=n.value;if(S.push($.data.entries),n.value=S.flat(),a.value=$.data.countries,s.total=$.data.total,r.value=!1,window.localStorage.getItem("countryFilterUrl")&&window.localStorage.getItem("countryFilterUrl")===window.location.pathname&&window.localStorage.getItem("countryFilter")){const E=a.value.filter(C=>C.title===window.localStorage.getItem("countryFilter"));E&&E.length>0?o.value=window.localStorage.getItem("countryFilter"):o.value="All"}}).catch($=>{r.value=!1,i.value=!0,console.log($)})}function x(y){u.value!==null&&u.value!==""?(u.value=null,document.getElementsByTagName("body")[0].classList.remove("overflow-hidden")):(u.value=y,document.getElementsByTagName("body")[0].classList.add("overflow-hidden"))}function _(y){document.getElementById("scrollTop").scrollIntoView({behavior:"smooth"}),o.value=y,s.skip=0,n.value=[],v()}return or(async()=>{window.localStorage.getItem("countryFilter")&&window.localStorage.getItem("countryFilterUrl")===window.location.pathname&&(o.value=window.localStorage.getItem("countryFilter")),v(),c.value=window.proxyUrl;const y=await e$.getUserLocation();y&&(d.value=y.countryName,h.value=y.sadc_countries)}),jh(()=>{p()}),tt(o,()=>{window.localStorage.setItem("countryFilter",o.value),window.localStorage.setItem("countryFilterUrl",window.location.pathname)}),(y,w)=>{const $=qr("rr-resnova");
82return k(),M("div",{id:"scrollTop",class:pe({"pt-8":e.filters})},[a.value&&a.value.length>0?(k(),M("div",Ppe,[e.filters?(k(),M("ul",Mpe,[b("li",{onClick:w[0]||(w[0]=S=>_("All")),class:pe(["px-0 mx-3 my-1 text-[16px] cursor-pointer",o.value==="All"?"border-b-2 border-ag-red":"border-b-2 border-transparent"])}," All ",2),(k(!0),M(xe,null,Me(a.value,S=>(k(),M("li",{key:S.title,onClick:E=>_(S.title),class:pe(["px-0 mx-3 my-1 text-[16px] cursor-pointer",o.value===S.title?"border-b-2 border-ag-red":"border-b-2 border-transparent"])},Q(S.title),11,Ipe))),128))],512)):X("",!0)])):X("",!0),f.value&&f.value.length===0&&r.value?(k(),M("div",Ape,[be(Q4)])):X("",!0),b("div",null,[f.value&&f.value.length>0?(k(),M("div",Dpe,[(k(!0),M(xe,null,Me(f.value,(S,E)=>(k(),M("div",{key:E,class:pe(["listing-item flex flex-wrap w-full items-center my-4 md:my-4",{"flex-row-reverse":E%2}])},[b("div",Rpe,[be(hD,{images:S.images},null,8,["images"])]),b("div",Ope,[b("div",{class:"font-primary text-ag-black-2 text-sm pb-1",innerHTML:S.header_country},null,8,Lpe),b("div",{class:"text-3xl xl:text-5xl font-primary text-black",innerHTML:S.header_destination},null,8,Fpe),b("div",{class:"font-primary py-6 text-ag-black-2",innerHTML:S.content_paragraph},null,8,zpe),b("div",Npe,[(k(!0),M(xe,null,Me(S.three_columns,(C,I)=>(k(),M("div",{class:pe(["w-auto",[I!==S.three_columns.length-1?"border-b md:border-r md:border-b-0 py-4 pr-8 md:py-0 md:px-4":"border-0 py-4 md:py-0 md:px-4 pr-8",I===0?"md:pl-0":""]]),key:I},[b("div",{class:"column-title",innerHTML:C.column_title},null,8,Bpe),b("div",{class:"column-value",innerHTML:C.column_content},null,8,jpe)],2))),128))]),S.search_price?(k(),M("div",Upe,[b("span",Vpe,[w[3]||(w[3]=Ze("from ",-1)),be(eg,{value:S.search_price},null,8,["value"]),Ze(" "+Q(S.price_description),1)])])):X("",!0),b("div",qpe,[b("div",Gpe,[b("div",{class:"button mr-2",onClick:C=>m(S)},Q(S.button_text?S.button_text:"View Details"),9,Hpe)]),S.listing_type&&(S.listing_type.includes("lodges")||S.listing_type.includes("campsites")||S.listing_type.includes("journeys")||S.listing_type.includes("safaris"))&&S.show_enquiry_button?(k(),M("div",Ype,[b("a",{class:"button button--outline mr-2",href:`${c.value}/enquiry?listings=${S.id}`},Q(e.enquireLabel),9,Wpe)])):X("",!0),S.resnova_id&&y.location===S.header_country?(k(),M("div",Zpe,[b("button",{class:"button button--outline",onClick:C=>x(S.id)},Q(e.bookNowLabel),9,Kpe)])):X("",!0),S.resnova_id_international&&y.location!==S.header_country&&h.value&&!h.value.includes(y.location)?(k(),M("div",Xpe,[b("button",{class:"button button--outline",onClick:C=>x(S.id)},Q(e.bookNowLabel),9,Jpe)])):X("",!0),S.resnova_id_sadc&&y.location!==S.header_country&&h.value&&h.value.includes(y.location)?(k(),M("div",Qpe,[b("button",{class:"button button--outline",onClick:C=>x(S.id)},Q(e.bookNowLabel),9,eme)])):X("",!0)]),w[4]||(w[4]=b("hr",{class:"mt-6 visible md:invisible"},null,-1))]),(S.resnova_id||S.resnova_id_international||S.resnova_id_sadc)&&u.value===S.id?(k(),M("div",tme,[b("div",rme,[b("div",ime,[b("div",null,[w[5]||(w[5]=b("h2",{class:"text-lg xl:text-xl font-primary m-0"},"Booking",-1)),b("p",nme,Q(S.header_destination),1)]),b("div",{class:"inline-block cursor-pointer",onClick:w[1]||(w[1]=C=>x(null))},[...w[6]||(w[6]=[so('<svg width="25px" height="25px" viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><g data-name="Layer 2" class="fill-current text-gray-600 hover:text-ag-red"><g data-name="close"><rect width="24" height="24" transform="rotate(180 12 12)" opacity="0"></rect><path d="M13.41 12l4.3-4.29a1 1 0 1 0-1.42-1.42L12 10.59l-4.29-4.3a1 1 0 0 0-1.42 1.42l4.3 4.29-4.3 4.29a1 1 0 0 0 0 1.42 1 1 0 0 0 1.42 0l4.29-4.3 4.29 4.3a1 1 0 0 0 1.42 0 1 1 0 0 0 0-1.42z"></path></g></g></svg>',1)])])]),S.resnova_id&&y.location===S.header_country?(k(),M("div",ame,[be($,{"widget-id":S.resnova_id,"api-url":"https://resnova.resrequest.com/api"},null,8,["widget-id"])])):X("",!0),S.resnova_id_international&&y.location!==S.header_country&&h.value&&!h.value.includes(y.location)?(k(),M("div",sme,[be($,{"widget-id":S.resnova_id_international,"api-url":"https://resnova.resrequest.com/api"},null,8,["widget-id"])])):X("",!0),S.resnova_id_sadc&&y.location!==S.header_country&&h.value&&h.value.includes(y.location)?(k(),M("div",ome,[be($,{"widget-id":S.resnova_id_sadc,"api-url":"https://resnova.resrequest.com/api"},null,8,["widget-id"])])):X("",!0)])])):X("",!0)],2))),128))])):X("",!0),!r.value&&f.value&&f.value.length===0?(k(),M("div",lme,[...w[7]||(w[7]=[b("p",null,"No search results were found matching your query.",-1)])])):X("",!0),f.value?(k(),M("div",ume,[b("button",{class:"button button--outline",disabled:r.value||s.skip+s.take>=s.total,onClick:w[2]||(w[2]=S=>g())},Q(r.value?"Loading...":"Load More"),9,cme)])):X("",!0),b("div",dme,"Showing "+Q(n.value.length)+" of "+Q(s.total)+" results.",1)])],2)}}},fme={name:"CurrencySelector",props:["rates","options","variation"],data(){return{loading:!0,selectedCurrency:"USD",dropdownOpen:!1,variant:this.variation?this.variation:"default"}},watch:{selectedCurrency(e){console.log("Currency update watch:",e),this.selectedCurrency=e}},mounted(){const e=window.localStorage.getItem("selected_currency");e?this.selectedCurrency=e:(window.localStorage.setItem("selected_currency","USD"),this.selectedCurrency="USD"),window.addEventListener("currencyUpdated",this.handleCurrencyUpdated),window.addEventListener("click",this.handleClickOutside)},methods:{toggleDropdown(){this.dropdownOpen=!this.dropdownOpen},selectCurrency(e){this.setSelectedCurrency(e),this.dropdownOpen=!1},setSelectedCurrency(e){window.localStorage.setItem("selected_currency",e),this.$emit("currency-changed",e);const t=new CustomEvent("currencyUpdated",{detail:{message:e,timestamp:Date.now()}});window.dispatchEvent(t)},handleCurrencyUpdated(e){this.selectedCurrency=e.detail.message},handleClickOutside(e){this.$refs.currencyDropdown&&!this.$refs.currencyDropdown.contains(e.target)&&(this.dropdownOpen=!1)}},beforeUnmount(){window.removeEventListener("currencyUpdated",this.handleCurrencyUpdated),window.removeEventListener("click",this.handleClickOutside)}},pme={key:0,class:"relative",ref:"currencyDropdown"},mme=["src","alt"],gme=["onClick"],_me={class:"flex-1 flex items-center gap-3"},yme=["src","alt"],vme={class:"text-xs leading-4 tracking-normal"},bme={class:"text-xs leading-4 tracking-normal"};function xme(e,t,r,i,n,a){var s;return r.options&&r.options.length>0?(k(),M("div",pme,[b("div",{onClick:t[0]||(t[0]=(...o)=>a.toggleDropdown&&a.toggleDropdown(...o)),class:pe(["cursor-pointer flex items-center gap-2 p-1",n.variant==="filter"?"pr-0":"w-24"])},[b("img",{src:(s=r.options.find(o=>(o==null?void 0:o.code)===n.selectedCurrency))==null?void 0:s.icon,alt:n.selectedCurrency,class:"rounded-full object-cover block h-4 w-4 bg-gray-100"},null,8,mme),b("span",null,Q(n.selectedCurrency),1),(k(),M("svg",{class:"ml-1 w-4 h-4",fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",style:Qt(n.dropdownOpen?"transform: rotate(180deg)":"")},[...t[2]||(t[2]=[b("path",{"stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"M19 9l-7 7-7-7"},null,-1)])],4))],2),n.dropdownOpen?(k(),M("ul",{key:0,class:pe(["absolute bottom-full md:bottom-auto md:top-full bg-white border border-gray-200 rounded shadow-lg w-64 md:left-auto md:right-0",n.variant==="filter"?"right-0 md:right-0":"-left-20 md:left-auto"]),style:{"z-index":"999"},onBlur:t[1]||(t[1]=o=>n.dropdownOpen=!1)},[(k(!0),M(xe,null,Me(r.options,o=>
82(k(),M("li",{key:o.code,onClick:l=>a.selectCurrency(o.code),class:pe(["py-2 px-3 text-black cursor-pointer hover:bg-gray-100 border-b border-gray-200 flex items-center gap-5 last:border-none",{"bg-gray-200":o.code===n.selectedCurrency}])},[b("div",_me,[b("img",{src:o.icon,alt:o.code,class:"object-cover rounded-full block h-5 w-5 bg-gray-100"},null,8,yme),b("span",vme,Q(o.label),1)]),b("span",bme,Q(o.code),1)],10,gme))),128))],34)):X("",!0)],512)):X("",!0)}const k$=Yt(fme,[["render",xme]]),wme={data(){return{showDropdown:null,dropdownOpened:null,subMenuHoveredItem:null,windowWidth:window.innerWidth||1024,hoverTimeout:null}},props:["goldTheme","navItem"],computed:{isMobile(){return this.windowWidth<768},isActive(){var e,t,r;return((e=this.navItem)==null?void 0:e.is_parent)||((t=this.navItem)==null?void 0:t.is_current)||this.showDropdown===((r=this.navItem)==null?void 0:r.id)},activeBorderClass(){return this.goldTheme?"md:border-ukuri":"md:border-ag-red"},hoverBorderClass(){return this.goldTheme?"md:hover:border-ukuri":"md:hover:border-ag-red"}},methods:{openDropdown(e){this.hoverTimeout&&clearTimeout(this.hoverTimeout),this.hoverTimeout=setTimeout(()=>{this.showDropdown=e},300)},closeDropdown(){this.hoverTimeout&&(clearTimeout(this.hoverTimeout),this.hoverTimeout=null),this.showDropdown=null},toggleDropdown(e){this.showDropdown=this.showDropdown===e?null:e},setSubMenuHoverItem(e){this.subMenuHoveredItem=e},handleResize(){this.windowWidth=window.innerWidth||1024}},mounted(){window.addEventListener("resize",this.handleResize)},beforeUnmount(){window.removeEventListener("resize",this.handleResize),this.hoverTimeout&&clearTimeout(this.hoverTimeout)}},$me={class:"h-full"},Sme=["href","target"],Tme=["href","target"],Cme={class:"w-5 md:hidden"},kme=["href","target"],Eme={key:0,class:"w-full h-full inline-flex items-center"},Pme=["onMouseover","onMouseleave"],Mme=["src","alt"],Ime={class:"absolute top-0 left-0 w-full h-full z-10 bg-black bg-opacity-30"},Ame={class:"z-20 text-center h-auto text-white"},Dme={class:"uppercase text-sm lg:text-lg font-semibold tracking-wide m-0 lg:mb-1"},Rme={key:1,class:"text-sm p-2 md:text-sm lg:text-base text-center font-bold uppercase tracking-wider flex relative items-center justify-center w-full h-20 md:h-32 lg:h-40 bg-white underline underline-offset-1"},Ome={key:1,class:"font-normal text-black text-sm uppercase mb-3 md:mb-4 w-full md:w-auto"},Lme={key:0,class:"flex flex-col gap-2"},Fme=["href","target"];function zme(e,t,r,i,n,a){return k(),M("div",$me,[r.navItem.children.length?X("",!0):(k(),M("div",{key:0,class:pe(["cursor-pointer font-primary py-5 px-4 border-b border-grey-400 tracking-wide w-full justify-between md:justify-center font-semibold flex max-[1350px]:px-2 md:py-2 mx-0 uppercase md:border-b-2 items-center h-full max-[1224px]:text-[12px]",{[a.hoverBorderClass]:!0,[a.activeBorderClass]:a.isActive,"md:border-transparent":!a.isActive}])},[b("a",{href:r.navItem.url,target:r.navItem.nav_new_tab?"_blank":"_self"},Q(r.navItem.title),9,Sme)],2)),r.navItem.children.length?(k(),M("div",{key:1,onMouseover:t[3]||(t[3]=s=>!a.isMobile&&a.openDropdown(r.navItem.id)),onMouseleave:t[4]||(t[4]=s=>!a.isMobile&&a.closeDropdown()),class:"h-full",style:{"z-index":"62"}},[b("div",{class:pe(["cursor-pointer font-primary py-5 px-4 border-b border-grey-400 tracking-wide w-full justify-between md:justify-center max-[1200px]:text-[12px] font-semibold flex max-[1350px]:px-2 md:py-2 mx-0 uppercase md:border-b-2 items-center h-full max-[1224px]:text-[12px]",{[a.hoverBorderClass]:!0,[a.activeBorderClass]:a.isActive,"md:border-transparent":!a.isActive}]),onClick:t[0]||(t[0]=s=>a.isMobile&&a.toggleDropdown(r.navItem.id))},[b("a",{href:r.navItem.permalink,target:r.navItem.nav_new_tab?"_blank":null},Q(r.navItem.title),9,Tme),b("span",Cme,[(k(),M("svg",{class:pe([n.showDropdown!==r.navItem.id&&"rotate-180","mx-1 text-base"]),"aria-hidden":"true",focusable:"false","data-icon":"chevron",role:"img",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 448 512"},[...t[5]||(t[5]=[b("path",{fill:"currentColor",d:"M4.465 366.475l7.07 7.071c4.686 4.686 12.284 4.686 16.971 0L224 178.053l195.494 195.493c4.686 4.686 12.284 4.686 16.971 0l7.07-7.071c4.686-4.686 4.686-12.284 0-16.97l-211.05-211.051c-4.686-4.686-12.284-4.686-16.971 0L4.465 349.505c-4.687 4.686-4.687 12.284 0 16.97z",class:""},null,-1)])],2))])],2),it(b("div",{onMouseover:t[1]||(t[1]=s=>!a.isMobile&&a.openDropdown(r.navItem.id)),onMouseleave:t[2]||(t[2]=s=>!a.isMobile&&a.closeDropdown()),class:"bg-white w-full p-2 py-4 md:py-6 flex flex-row justify-start items-start md:min-h-96 md:shadow-md md:absolute md:w-screen md:px-1 lg:px-2 md:top-full md:-left-[16px]",style:{"z-index":"99999 !important","min-width":"320px"}},[b("div",{class:pe(["mx-0 lg:mx-auto w-full max-w-full flex-wrap gap-2 py-2 md:py-4 px-2 md:max-w-header grid grid-cols-1",r.navItem.nav_image_variant?"md:gap-4 gap-3 grid-cols-2 md:grid-cols-4":"md:grid-cols-5 md:gap-6 xl:gap-8"])},[(k(!0),M(xe,null,Me(r.navItem.children,(s,o)=>{var l,u,c;return k(),M("div",{key:s.id,class:pe(["w-full",r.navItem.nav_image_variant?"":"mb-4 md:mb-6"])},[b("a",{href:s.url,target:r.navItem.nav_new_tab?"_blank":null,class:"text-black font-primary flex align-stretch justify-stretch"},[r.navItem.nav_image_variant?(k(),M("div",Eme,[s.nav_image_variant?(k(),M("div",{key:0,class:pe(["flex relative items-center justify-center w-full h-24 md:h-32 lg:h-40",s.nav_image_variant?"bg-gray-100 px-4":"bg-white"]),onMouseover:d=>!a.isMobile&&s.description&&a.setSubMenuHoverItem(o),onMouseleave:d=>!a.isMobile&&s.description&&a.setSubMenuHoverItem(null)},[(l=s.nav_image)!=null&&l.url?(k(),M("img",{key:0,src:(u=s.nav_image)==null?void 0:u.url,alt:(c=s.nav_image)==null?void 0:c.alt,class:"absolute top-0 left-0 w-full h-full object-cover bg-gray-100"},null,8,Mme)):X("",!0),it(b("div",Ime,null,512),[[Dn,n.subMenuHoveredItem===o]]),b("div",Ame,[b("p",Dme,Q(s.title),1),b("p",{class:pe(["hidden lg:block text-sm transition-all duration-500 overflow-hidden m-0 leading-snug px-5 overflow-ellipsis",n.subMenuHoveredItem===o?"h-auto max-h-16 opacity-100":"h-0 max-h-0 opacity-0"])}
82,Q(s.description),3)])],42,Pme)):(k(),M("div",Rme,Q(s.title),1))])):X("",!0),!s.hide_in_navigation&&!r.navItem.nav_image_variant?(k(),M("div",Ome,Q(s.title),1)):X("",!0)],8,kme),s.children&&s.children.length>0?(k(),M("div",Lme,[(k(!0),M(xe,null,Me(s.children,d=>(k(),M("div",{key:d.id},[d.hide_in_navigation?X("",!0):(k(),M("a",{key:0,class:"text-ag-black text-sm leading-5 hover:underline font-primary font-thin",href:d.url,target:d.nav_new_tab?"_blank":"_self"},Q(d.title),9,Fme))]))),128))])):X("",!0)],2)}),128))],2)],544),[[Dn,n.showDropdown===r.navItem.id||n.dropdownOpened===r.navItem.id]])],32)):X("",!0)])}const Nme=Yt(wme,[["render",zme]]),Bme={name:"SiteNavigation",props:["buttonLabel","buttonUrl","agentButtonUrl","agentButtonLabel","navItems","whiteLogoUrl","blackLogoUrl","enableDualHeader","dualHeaderText","dualHeaderTextRight","dualHeaderImageRight","dualHeaderLinkRight","goldTheme","logoAlt","currencyRates","currencySelectorOptions","showCurrencyConverter"],components:{NavItem:Nme,CurrencySelector:k$},data(){return{navOpen:!1,showWhiteBar:!0,scrollY:0,pageYOffset:0,showSearch:!1,safariSearch:"/travel/all-safaris",textinput:"",category:"all"}},computed:{formatedNavItems(){if(this.navItems)return JSON.parse(this.navItems)},isSticky(){return this.scrollY>100}},methods:{handleSubmitSafari:function(){window.location.href=this.safariSearch},handleSubmit(){const e=new URLSearchParams;e.append("category",this.category);const t=`https://africageographic.com/search/${encodeURIComponent(this.textinput)}?${e.toString()}`;window.location.href=t},showSearchHandler:function(){this.showSearch?(document.querySelector("body").style.overflow="auto",this.showSearch=!1):(document.querySelector("body").style.overflow="hidden",this.showSearch=!0)},async toggle(){this.navOpen=!this.navOpen},handleScroll(){this.scrollY=window.scrollY||window.pageYOffset}},mounted(){window.addEventListener("scroll",this.handleScroll),this.handleScroll()},beforeUnmount(){window.removeEventListener("scroll",this.handleScroll)}},jme={"data-component":"navigation",class:"w-full z-50"},Ume={key:0,class:"h-screen w-screen bg-slate-800 fixed top-0 left-0 z-50 flex justify-center items-center",style:{"z-index":"3000000000 !important"}},Vme={class:"bg-slate-800 container mx-auto max-w-screen-xl p-8 md:p-0"},qme={class:"border-b border-black mb-4 pb-4"},Gme={class:"flex flex-wrap items-center justify-between flex-col"},Hme={class:"md:hidden flex flex-col fixed top-0 left-0 min-w-64 h-full bg-white shadow-md p-2 w-[95vw] max-w-[460px]",style:{"z-index":"9999"}},Yme={class:"p-2 text-sm flex items-center justify-between md:py-0"},Wme={href:"/",class:"w-52 router-link-active"},Zme=["src","alt"],Kme={class:"flex-1 py-2 max-h-75vh w-full overflow-y-auto"},Xme={class:"h-auto w-full flex flex-col gap-3 bg-white py-4 px-2"},Jme=["href"],Qme={key:1,class:"font-primary mt-2 py-1 px-3 md:p-0 underline text-black items-center justify-center flex"},ege=["href"],tge={key:0,class:"flex items-center justify-center"},rge={class:"bg-white"},ige={class:"h-auto m-0 md:hidden flex-1"},nge=["href"],age={key:0,class:"py-0 px-0"},sge={key:1,href:"/",class:"lg:w-48 block"},oge=["src","alt"],lge={class:"hidden md:flex bg-white relative mt-8 font-primary flex-col flex-1 justify-start text-sm md:text-xs lg:text-sm md:flex-row md:justify-stretch md:items-center md:flex-1 md:mt-0 text-black"},uge={class:"flex flex-wrap items-stretch justify-between w-full mx-auto max-w-header h-full min-h-[64px] xl:pr-2"},cge={class:"h-full flex-1 m-0 p-0 flex flex-wrap items-stretch justify-start"},dge={key:0,class:"py-0 px-3 md:p-0 md:mx-0 md:border-b md:border-transparent flex gap-4 items-center lg:items-center justify-end"},hge={key:0,href:"/search",class:"min-[1280px]:bg-gray-100 min-[1280px]:border-gray-400 color-ag-black min-[1280px]:w-52 h-auto min-[1280px]:rounded-sm flex items-center p-2 gap-3 min-h-[40px] focus:outline-none focus:ring-0"},fge={key:1,href:"/search",class:"color-ag-black h-auto flex items-center py-2 gap-3 min-h-[40px] focus:outline-none focus:ring-0"},pge={key:2,class:"flex justify-end items-center text-xs lg:text-base h-full"},mge=["href"];function gge(e,t,r,i,n,a){const s=qr("NavItem"),o=qr("CurrencySelector");return k(),M("div",jme,[n.showSearch?(k(),M("div",Ume,[b("div",{onClick:t[0]||(t[0]=(...l)=>a.showSearchHandler&&a.showSearchHandler(...l)),class:"fixed top-2 right-2 md:top-8 md:right-8 cursor-pointer"},[...t[8]||(t[8]=[so('<svg width="45px" height="45px" viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg" data-v-ab916bc5><g data-name="Layer 2" class="fill-current text-white hover:text-ag-red" data-v-ab916bc5><g data-name="close" data-v-ab916bc5><rect width="24" height="24" transform="rotate(180 12 12)" opacity="0" data-v-ab916bc5></rect><path d="M13.41 12l4.3-4.29a1 1 0 1 0-1.42-1.42L12 10.59l-4.29-4.3a1 1 0 0 0-1.42 1.42l4.3 4.29-4.3 4.29a1 1 0 0 0 0 1.42 1 1 0 0 0 1.42 0l4.29-4.3 4.29 4.3a1 1 0 0 0 1.42 0 1 1 0 0 0 0-1.42z" data-v-ab916bc5></path></g></g></svg>',1)])]),b("div",Vme,[b("div",qme,[t[11]||(t[11]=b("div",{class:"font-light text-black text-2xl md:text-3xl font-primary uppercase my-8 text-center"},"Search our stories ",-1)),b("form",{onSubmit:t[3]||(t[3]=di((...l)=>a.handleSubmit&&a.handleSubmit(...l),["prevent"])),class:"flex flex-wrap items-center justify-end gap-2 md:gap-12 mb-4"},[it(b("input",{"onUpdate:modelValue":t[1]||(t[1]=l=>n.textinput=l),class:"font-light text-lg md:text-2xl font-primary h-16 px-4 flex-1 max-w-full",type:"text",name:"textinput",id:"textinput",placeholder:"Enter a word or phrase ...",required:""},null,512),[[ui,n.textinput]]),it(b("select",{"onUpdate:modelValue":t[2]||(t[2]=l=>n.category=l),class:"font-light appearance-none text-lg md:text-2xl font-primary w-full md:w-56 h-16 px-4",name:"category",required:""},[...t[9]||(t[9]=[so('<option value="all" data-v-ab916bc5>All stories</option><option value="species" data-v-ab916bc5>Species - featured</option><option value="places" data-v-ab916bc5>Places - featured</option><option value="tips" data-v-ab916bc5>Safari tips</option><option value="trips" data-v-ab916bc5>Safari report-backs</option>',5)])],512),[[Yl,n.category]]),t[10]||(t[10]=b("button",{class:"font-light text-2xl font-primary w-full md:w-56 h-16 px-4 roun
82ded bg-ag-red text-white",type:"submit"},"Search",-1))],32)]),b("div",null,[t[14]||(t[14]=b("div",{class:"font-light text-white text-2xl md:text-3xl font-primary uppercase my-8 text-center"},"Search our safaris ",-1)),b("div",Gme,[b("form",{method:"get",onSubmit:t[5]||(t[5]=di((...l)=>a.handleSubmitSafari&&a.handleSubmitSafari(...l),["prevent"])),action:"/",class:"flex flex-wrap items-center justify-end gap-2 md:gap-12 mb-4"},[it(b("select",{"onUpdate:modelValue":t[4]||(t[4]=l=>n.safariSearch=l),class:"font-light appearance-none text-lg md:text-2xl font-primary w-full md:w-56 h-16 px-4",name:"safari_category",required:""},[...t[12]||(t[12]=[b("option",{value:"/travel/all-safaris",class:"selectFirst",selected:""},"All safaris",-1),b("option",{value:"/travel/all-places"},"By place",-1),b("option",{value:"/travel/all-safari-experiences"},"By experience",-1)])],512),[[Yl,n.safariSearch]]),t[13]||(t[13]=b("button",{class:"font-light text-2xl font-primary w-full md:w-56 h-16 px-4 rounded bg-ag-red text-white",type:"submit"},"Search",-1))],32)])])])])):X("",!0),it(b("div",Hme,[b("div",Yme,[b("a",Wme,[b("img",{src:r.blackLogoUrl,alt:r.logoAlt,width:"250",height:"110",class:"h-10 w-auto"},null,8,Zme)]),b("div",{onClick:t[6]||(t[6]=(...l)=>a.toggle&&a.toggle(...l)),class:"cursor-pointer"},[...t[15]||(t[15]=[b("svg",{xmlns:"http://www.w3.org/2000/svg",class:"h-6 w-6",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor"},[b("path",{"stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"M6 18L18 6M6 6l12 12"})],-1)])])]),b("div",Kme,[(k(!0),M(xe,null,Me(a.formatedNavItems,l=>(k(),M("div",{key:l.id,class:pe(!r.goldTheme&&"first-of-type:text-ag-red")},[be(s,{navItem:l,goldTheme:r.goldTheme},null,8,["navItem","goldTheme"])],2))),128))]),b("div",Xme,[b("div",null,[r.buttonUrl?(k(),M("a",{key:0,href:r.buttonUrl,class:pe(["w-full font-primary flex item-center justify-center rounded-3xl py-2 px-4 text-white",r.goldTheme?"bg-ukuri hover:bg-ukurihover":"bg-ag-green hover:bg-ag-green-hover"])},Q(r.buttonLabel),11,Jme)):X("",!0),r.agentButtonUrl?(k(),M("div",Qme,[b("a",{href:r.agentButtonUrl},Q(r.agentButtonLabel),9,ege)])):X("",!0)]),r.showCurrencyConverter?(k(),M("div",tge,[be(o,{rates:r.currencyRates,options:r.currencySelectorOptions?r.currencySelectorOptions:[]},null,8,["rates","options"])])):X("",!0)])],512),[[Dn,n.navOpen]]),b("div",rge,[b("div",{class:pe([r.enableDualHeader?"":"fixed top-0 z-40","z-40 bg-white flex justify-end md:justify-between border-b border-b-slate-200 md:border-b-0 border-t border-t-slate-200 bg-opacity-80 px-2 md:shadow-md w-full items-stretch md:px-4 min-h-[64px]"])},[it(b("p",{class:"md:hidden font-gunny mr-2 tracking-wide font-medium mb-0 text-xl lg:text-2xl text-left flex-1 h-full flex self-center"},Q(r.dualHeaderText),513),[[Dn,!a.isSticky]]),b("div",{class:pe(["text-sm flex items-center gap-4 m-0 p-1 md:py-0 md:hidden",a.isSticky?"justify-between items-center w-full":""])},[it(b("div",ige,[b("a",{href:r.buttonUrl,class:pe(["w-48 font-primary flex item-center justify-center rounded-3xl py-2 px-4 text-white",r.goldTheme?"bg-ukuri hover:bg-ukurihover":"bg-ag-green hover:bg-ag-green-hover"])},Q(r.buttonLabel),11,nge)],512),[[Dn,a.isSticky]]),r.enableDualHeader&&!r.goldTheme?(k(),M("div",age,[...t[16]||(t[16]=[b("a",{href:"/search",color:"color-ag-black flex h-full items-center justify-center"},[b("svg",{xmlns:"http://www.w3.org/2000/svg",class:"h-6 w-6",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor"},[b("path",{"stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"M21 21l-4.35-4.35m0 0A7.5 7.5 0 104.5 4.5a7.5 7.5 0 0012.15 12.15z"})])],-1)])])):X("",!0),b("div",{onClick:t[7]||(t[7]=(...l)=>a.toggle&&a.toggle(...l)),class:"flex flex-col items-center justify-start cursor-pointer"},[...t[17]||(t[17]=[b("svg",{width:"20","aria-hidden":"true",focusable:"false","data-prefix":"fal","data-icon":"bars",role:"img",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 448 512",class:"mr-1 text-black text-lg svg-inline--fa fa-bars fa-w-14"},[b("path",{fill:"currentColor",d:"M442 114H6a6 6 0 0 1-6-6V84a6 6 0 0 1 6-6h436a6 6 0 0 1 6 6v24a6 6 0 0 1-6 6zm0 160H6a6 6 0 0 1-6-6v-24a6 6 0 0 1 6-6h436a6 6 0 0 1 6 6v24a6 6 0 0 1-6 6zm0 160H6a6 6 0 0 1-6-6v-24a6 6 0 0 1 6-6h436a6 6 0 0 1 6 6v24a6 6 0 0 1-6 6z",class:""})],-1)])]),r.enableDualHeader?X("",!0):(k(),M("a",sge,[b("img",{src:r.whiteLogoUrl,alt:r.logoAlt,width:"250",height:"110",class:"h-8 w-auto lg:h-10"},null,8,oge)]))],2),b("div",lge,[b("div",uge,[b("div",cge,[(k(!0),M(xe,null,Me(a.formatedNavItems,l=>(k(),M("div",{key:l.id,class:pe(!r.goldTheme&&"first-of-type:text-ag-red h-16 lg:h-full")},[be(s,{navItem:l,goldTheme:r.goldTheme},null,8,["navItem","goldTheme"])],2))),128))]),r.enableDualHeader&&!r.goldTheme?(k(),M("div",dge,[a.isSticky?(k(),M("a",fge,[...t[19]||(t[19]=[b("svg",{xmlns:"http://www.w3.org/2000/svg",class:"h-5 w-5",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor"},[b("path",{"stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"M21 21l-4.35-4.35m0 0A7.5 7.5 0 104.5 4.5a7.5 7.5 0 0012.15 12.15z"})],-1)])])):(k(),M("a",hge,[...t[18]||(t[18]=[b("svg",{xmlns:"http://www.w3.org/2000/svg",class:"h-5 w-5",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor"},[b("path",{"stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"M21 21l-4.35-4.35m0 0A7.5 7.5 0 104.5 4.5a7.5 7.5 0 0012.15 12.15z"})],-1),b("span",{class:"hidden min-[1280px]:flex text-gray-400"},"Search ... ",-1)])])),a.isSticky&&r.buttonUrl?(k(),M("div",pge,[b("a",{href:r.buttonUrl,class:
82pe([r.goldTheme?"bg-ukuri hover:bg-ukurihover":"bg-ag-green hover:bg-ag-green-hover","w-40 font-primary rounded-3xl py-2 px-4 text-white text-center md:w-48 xl:w-52 nav-enquire"])},Q(r.buttonLabel),11,mge)])):X("",!0)])):X("",!0)])])],2)])])}const _ge=Yt(Bme,[["render",gge],["__scopeId","data-v-ab916bc5"]]),yge={name:"EnquiryForm",props:["enquiryForm","lodges","campsites","journeys","safaris"],data(){return{scrollTo:null,success:!1,error:!1,loading:!1,interval:null,activeStep:null,form:{listings:[]},stepSubmitted:[]}},mounted(){this.activeStep=this.enquiryForm.form_steps[0].title;let e=new URLSearchParams(window.location.search);if(window.localStorage.getItem("enquiry_form_data")&&!e.has("listings")&&(this.form=JSON.parse(window.localStorage.getItem("enquiry_form_data"))),window.localStorage.getItem("enquiry_form_step")&&!e.has("listings")){let r=JSON.parse(window.localStorage.getItem("enquiry_form_step"));this.activeStep=r.form_steps[0].title}if(e.has("listings")){let r=JSON.parse(window.localStorage.getItem("enquiry_form_data")),i=e.get("listings").split(",")[0];this.form.listings=r&&r.listings&&!r.listings.includes(i)?r.listings:[],this.form.listings.length>0?this.form.listings.push(i):this.form.listings=e.get("listings").split(","),this.scrollTo=this.form.listings[0],setTimeout(()=>{document.getElementById(this.form.listings[this.form.listings.length-1]).scrollIntoView({block:"center",behavior:"smooth"})},200)}let t=this;this.interval=setInterval(function(){t.updateLocalFormData()},2e3)},beforeUnmount(){clearInterval(this.interval)},computed:{firstStep(){return this.enquiryForm.form_steps[0].title},lastStep(){return this.enquiryForm.form_steps[this.enquiryForm.form_steps.length-1].title},nextStep(){let e=this.activeStep;return this.enquiryForm.form_steps.forEach((t,r)=>{t.title===this.activeStep&&this.enquiryForm.form_steps[r+1]&&(e=this.enquiryForm.form_steps[r+1].title)}),e},prevStep(){let e=this.activeStep;return this.enquiryForm.form_steps.forEach((t,r)=>{t.title===this.activeStep&&r>0&&(e=this.enquiryForm.form_steps[r-1].title)}),e},lodgeSections(){let e=this.lodges,t=[];return e.forEach((r,i)=>{t[i]=r.header_country}),[...new Set(t)].sort()},campSections(){let e=this.campsites,t=[];return e.forEach((r,i)=>{t[i]=r.header_country}),[...new Set(t)].sort()}},methods:{goToNext(){if(this.activeStep===this.lastStep){this.submitEnquiry();return}this.activeStep=this.nextStep,window.scrollTo({top:0,behavior:"smooth"})},goToPrev(){this.activeStep=this.prevStep,window.scrollTo({top:0,behavior:"smooth"})},submitEnquiry(){this.loading=!0,Rt.post(window.proxyUri+"/api/enquiries",this.form).then(e=>{this.success=!0,this.error=!1,this.loading=!1,this.activeStep=this.enquiryForm.form_steps[0].title,this.clearLocalFormData(),window.location.href="thank-you"}).catch(e=>{this.loading=!1,this.success=!1,this.error=!0})},updateLocalFormData(){window.localStorage.setItem("enquiry_form_data",JSON.stringify(this.form)),window.localStorage.setItem("enquiry_form_step",JSON.stringify(this.enquiryForm))},clearLocalFormData(){this.form={listings:[]},window.localStorage.removeItem("enquiry_form_data"),window.localStorage.removeItem("enquiry_form_step"),this.activeStep=this.enquiryForm.form_steps[0].title}}},vge={key:0,class:"bg-green-100 p-3 rounded text-black my-8"},bge={key:1,class:"bg-red-100 p-3 rounded text-black my-8"},xge={class:"flex flex-wrap justify-between items-center mb-12 border-b border-gray-100 pb-4"},wge={class:"inline-block"},$ge={key:0},Sge={key:0,class:"mb-8 pb-8 border-b border-gray-300"},Tge={key:1,class:"mb-8 pb-8 border-b border-gray-300"},Cge={class:"text-lg font-bold mb-2"},kge=["for"],Ege={class:"font-light"},Pge=["id","value"],Mge={key:2,class:"mb-8 pb-8 border-b border-gray-300"},Ige={class:"text-lg font-bold mb-2"},Age=["for"],Dge={class:"font-light"},Rge=["id","value"],Oge={key:3,class:"mb-8 pb-8 border-b border-gray-300"},Lge=["for"],Fge={class:"font-light"},zge=["id","value"],Nge={key:4,class:"mb-8 pb-8 border-b border-gray-300 max-h-50vh overflow-y-auto"},Bge=["for"],jge={class:"font-light"},Uge=["id","value"],Vge=["disabled"],qge={key:1,class:"w-full"},Gge={key:0},Hge={key:0},Yge={class:"block w-full"},Wge={class:"text-gray-300 font-light"},Zge={class:"text-ag-red"},Kge=["type","onUpdate:modelValue"],Xge=["onUpdate:modelValue"],Jge={key:1},Qge={key:0},e0e={class:"font-light"},t0e=["onUpdate:modelValue","name","id","value"],r0e={key:1},i0e={class:"font-light"},n0e=["onUpdate:modelValue","id","value"],a0e=["disabled"],s0e=["disabled","onClick"];function o0e(e,t,r,i,n,a){return k(),M("div",null,[n.success?(k(),M("div",vge,[t[8]||(t[8]=b("strong",null,"Submission Successful",-1)),t[9]||(t[9]=b("br",null,null,-1)),Ze(" "+Q(r.enquiryForm.success_message),1)])):X("",!0),n.error?(k(),M("div",bge,[t[10]||(t[10]=b("strong",null,"Submission Error",-1)),t[11]||(t[11]=b("br",null,null,-1)),Ze(" "+Q(r.enquiryForm.error_message),1)])):X("",!0),b("div",null,[b("div",xge,[b("ul",null,[(k(!0),M(xe,null,Me(r.enquiryForm.form_steps,(s,o)=>(k(),M("li",{class:"inline-block",key:o},[b("span",{class:pe(["inline-block py-2 text-sm mr-3 uppercase font-bold",{"border-b-2 border-ag-red":n.activeStep===s.title}])},Q(s.title),3)]))),128))]),b("ul",null,[b("li",wge,[b("span",{class:"text-ag-brown-grey inline-block py-0 xl:py-2 mb-0 mt-4 md:mt-0 xl:m-0 text-sm mr-4 cursor-pointer hover:text-ag-red underline font-light",onClick:t[0]||(t[0]=(...s)=>a.clearLocalFormData&&a.clearLocalFormData(...s))},"Reset Form")])])]),(k(!0),M(xe,null,Me(r.enquiryForm.form_steps,(s,o)=>it((k(),M("div",{key:o,class:"w-full"}
82,[s.show_listings?(k(),M("div",$ge,[b("form",{onSubmit:t[5]||(t[5]=di((...l)=>a.goToNext&&a.goToNext(...l),["prevent"]))},[(!r.lodges||r.lodges.length===0)&&(!r.campsites||r.campsites.length===0)&&(!r.journeys||r.journeys.length===0)&&(!r.safaris||r.safaris.length===0)?(k(),M("div",Sge,[...t[12]||(t[12]=[b("h2",{class:"text-2xl font-bold mb-1"},"No Listings",-1),b("p",{class:"text-sm text-ag-brown-grey"},"There are currently no listings available for enquiry, please check back soon.",-1)])])):X("",!0),r.lodges&&r.lodges.length>0?(k(),M("div",Tge,[t[13]||(t[13]=b("h2",{class:"text-2xl font-bold mb-1"},"Lodges",-1)),t[14]||(t[14]=b("p",{class:"text-sm text-ag-brown-grey"},"Please select the lodges you are interested in:",-1)),(k(!0),M(xe,null,Me(a.lodgeSections,(l,u)=>(k(),M("div",{key:u,class:"mb-4 pl-2"},[b("h3",Cge,Q(l),1),(k(!0),M(xe,null,Me(r.lodges,(c,d)=>(k(),M("div",{key:d},[c.header_country===l?(k(),M("label",{key:0,for:c.id,class:pe(["w-full flex justify-between items-center cursor-pointer hover:text-ag-red hover:bg-gray-100 p-2",{"bg-gray-100":n.form.listings.includes(c.id)}])},[b("span",Ege,Q(c.header_country)+" - "+Q(c.header_destination),1),it(b("input",{type:"checkbox",id:c.id,value:c.id,"onUpdate:modelValue":t[1]||(t[1]=h=>n.form.listings=h)},null,8,Pge),[[_s,n.form.listings]])],10,kge)):X("",!0)]))),128))]))),128))])):X("",!0),r.campsites&&r.campsites.length>0?(k(),M("div",Mge,[t[15]||(t[15]=b("h2",{class:"text-2xl font-bold mb-1"},"Campsites",-1)),t[16]||(t[16]=b("p",{class:"text-sm text-ag-brown-grey"},"Please select the campsites you are interested in:",-1)),(k(!0),M(xe,null,Me(a.campSections,(l,u)=>(k(),M("div",{key:u,class:"mb-4 pl-2"},[b("h3",Ige,Q(l),1),(k(!0),M(xe,null,Me(r.campsites,(c,d)=>(k(),M("div",{key:d},[c.header_country===l?(k(),M("label",{key:0,for:c.id,class:pe(["w-full flex justify-between items-center cursor-pointer hover:text-ag-red hover:bg-gray-100 p-2",{"bg-gray-100":n.form.listings.includes(c.id)}])},[b("span",Dge,Q(c.header_country)+" - "+Q(c.header_destination),1),it(b("input",{type:"checkbox",id:c.id,value:c.id,"onUpdate:modelValue":t[2]||(t[2]=h=>n.form.listings=h)},null,8,Rge),[[_s,n.form.listings]])],10,Age)):X("",!0)]))),128))]))),128))])):X("",!0),r.journeys&&r.journeys.length>0?(k(),M("div",Oge,[t[17]||(t[17]=b("h2",{class:"text-2xl font-bold mb-1"},"Journeys",-1)),t[18]||(t[18]=b("p",{class:"text-sm text-ag-brown-grey"},"Please select the journeys you are interested in:",-1)),(k(!0),M(xe,null,Me(r.journeys,(l,u)=>(k(),M("div",{key:u,class:"pl-2"},[b("label",{for:l.id,class:pe(["w-full flex justify-between items-center cursor-pointer hover:text-ag-red hover:bg-gray-100 p-2",{"bg-gray-100":n.form.listings.includes(l.id)}])},[b("span",Fge,Q(l.header_country)+" - "+Q(l.header_destination),1),it(b("input",{type:"checkbox",id:l.id,value:l.id,"onUpdate:modelValue":t[3]||(t[3]=c=>n.form.listings=c)},null,8,zge),[[_s,n.form.listings]])],10,Lge)]))),128))])):X("",!0),r.safaris&&r.safaris.length>0?(k(),M("div",Nge,[t[19]||(t[19]=b("h2",{class:"text-2xl font-bold mb-1"},"Safaris",-1)),t[20]||(t[20]=b("p",{class:"text-sm text-ag-brown-grey"},[Ze("Please select the safaris you are interested in, and then scroll down and tap âNextâ. "),b("strong",null,[Ze("If you have something else in mind, "),b("a",{href:"javascript:void(Tawk_API.toggle())",class:"hover:text-ag-red"},[b("u",null,"please email us")]),Ze(" and we'll help craft your ideal safari.")])],-1)),(k(!0),M(xe,null,Me(r.safaris,(l,u)=>(k(),M("div",{key:u,class:"pl-2"},[b("label",{for:l.id,class:pe(["w-full flex justify-between items-center cursor-pointer hover:text-ag-red hover:bg-gray-100 p-2",{"bg-gray-100":n.form.listings.includes(l.id)}])},[b("span",jge,Q(l.header_country)+" - "+Q(l.header_destination),1),it(b("input",{type:"checkbox",id:l.id,value:l.id,"onUpdate:modelValue":t[4]||(t[4]=c=>n.form.listings=c)},null,8,Uge),[[_s,n.form.listings]])],10,Bge)]))),128))])):X("",!0),b("button",{disabled:n.form.listings&&n.form.listings.length===0,type:"submit",class:"button"},"Next",8,Vge)],32)])):(k(),M("div",qge,[s.form&&s.form.length>0?(k(),M("div",Gge,[b("form",{onSubmit:t[7]||(t[7]=di((...l)=>a.goToNext&&a.goToNext(...l),["prevent"]))},[(k(!0),M(xe,null,Me(s.form,(l,u)=>(k(),M("div",{key:u,class:"w-full mb-4"},[["radio","checkbox"].includes(l.field_type.key)?(k(),M("div",Jge,[l.field_type.key==="radio"?(k(),M("div",Qge,[b("div",{class:pe(["form-label font-bold mb-2",{"text-ag-red":n.stepSubmitted.includes(s.title)&&l.required&&(!n.form.hasOwnProperty(l.field_name)||n.form[l.field_name]==="")}])}
82,Q(l.field_name),3),(k(!0),M(xe,null,Me(l.field_options,(c,d)=>(k(),M("label",{class:"w-full flex justify-between items-center cursor-pointer hover:text-ag-red hover:bg-gray-100 p-2 mb-1",key:d},[b("span",e0e,Q(c),1),it(b("input",Ha({class:"inline-block mr-2",type:"radio","onUpdate:modelValue":h=>n.form[l.field_name]=h,name:l.field_name},{ref_for:!0},{required:l.required},{id:c,value:c}),null,16,t0e),[[p1,n.form[l.field_name]]])]))),128))])):X("",!0),l.field_type.key==="checkbox"?(k(),M("div",r0e,[b("div",{class:pe(["form-label font-bold mb-2",{"text-ag-red":n.stepSubmitted.includes(s.title)&&l.required&&(!n.form.hasOwnProperty(l.field_name)||n.form[l.field_name]==="")}])},Q(l.field_name),3),(k(!0),M(xe,null,Me(l.field_options,(c,d)=>(k(),M("label",{class:pe(["w-full flex justify-between items-center cursor-pointer hover:text-ag-red hover:bg-gray-100 p-2 mb-1",{"bg-gray-100":n.form[c],"text-ag-red":n.stepSubmitted.includes(s.title)&&l.required&&(!n.form.hasOwnProperty(l.field_name)||n.form[l.field_name]==="")}]),key:d},[b("span",i0e,Q(c),1),it(b("input",Ha({class:"inline-block mr-2",type:"checkbox"},{ref_for:!0},{required:l.required},{"onUpdate:modelValue":h=>n.form[c]=h,id:c,value:c}),null,16,n0e),[[_s,n.form[c]]])],2))),128))])):X("",!0)])):(k(),M("div",Hge,[b("label",Yge,[b("div",{class:pe(["form-label font-bold",{"text-ag-red":n.stepSubmitted.includes(s.title)&&l.required&&(!n.form.hasOwnProperty(l.field_name)||n.form[l.field_name]==="")}])},[Ze(Q(l.field_name)+" ",1),it(b("span",Wge,"(optional)",512),[[Dn,!l.required]]),it(b("span",Zge,"*",512),[[Dn,l.required]])],2),l.field_type.key!=="textarea"?it((k(),M("input",Ha({key:0,placeholder:" ",class:"form-control",type:l.field_type.key,"onUpdate:modelValue":c=>n.form[l.field_name]=c},{ref_for:!0},{required:l.required},{class:{"border-ag-red":n.stepSubmitted.includes(s.title)&&l.required&&(!n.form.hasOwnProperty(l.field_name)||n.form[l.field_name]==="")}}),null,16,Kge)),[[m1,n.form[l.field_name]]]):it((k(),M("textarea",Ha({key:1,class:"form-control",placeholder:" ","onUpdate:modelValue":c=>n.form[l.field_name]=c},{ref_for:!0},{required:l.required},{class:{"border-ag-red":n.stepSubmitted.includes(s.title)&&l.required&&(!n.form.hasOwnProperty(l.field_name)||n.form[l.field_name]==="")}}),null,16,Xge)),[[ui,n.form[l.field_name]]])])]))]))),128)),s.title!==a.firstStep?(k(),M("button",{key:0,type:"button",disabled:n.loading,onClick:t[6]||(t[6]=(...l)=>a.goToPrev&&a.goToPrev(...l)),class:"button button--outline w-full md:w-auto mb-2"},"Back",8,a0e)):X("",!0),b("button",{type:"submit",disabled:n.loading,onClick:l=>n.stepSubmitted.push(s.title),class:"button w-full md:w-auto mb-2"},Q(s.title!==a.lastStep?"Next":"Submit Enquiry"),9,s0e)],32)])):X("",!0)]))])),[[Dn,n.activeStep===s.title]])),128))])])}const l0e=Yt(yge,[["render",o0e]]),u0e={name:"RelatedSectionBlock",props:{type:{type:String,default:""},tabs:{type:Array,default:()=>[]},tags:{type:Array,default:()=>[]}},data(){return{loading:!0,listings:[],activeTab:{slug:"all",listings:[]}}},components:{Spinner:Q4,CurrencyDisplay:eg},computed:{filteredTabs(){let e=this,t=this.tabs||[];return!t.length||!e.listings.length?[]:(t.forEach(r=>{r.listings=e.listings.filter(i=>i.listing_type&&i.listing_type.includes(r.slug))}),t=t.filter(r=>r.listings&&r.listings.length>0&&r.slug!==e.type),[...t].reverse())},filteredListings(){let e=this;
82if(!this.tabs||!this.activeTab)return[];let t=this.tabs.filter(r=>r.slug===e.activeTab.slug);return t&&t.length>0?t[0].listings||[]:[]}},mounted(){this.fetchListings()},methods:{fetchListings(){this.loading=!0,this.error=!1;let e="";this.tags&&(e=this.tags.join("&tags[]=")),Rt.get(window.proxyUri+"/api/rest/listings/related?tags[]="+e).then(t=>{this.listings=t.data,this.loading=!1,this.filteredTabs&&this.filteredTabs.length>0&&this.setActive(this.filteredTabs[0])}).catch(t=>{this.loading=!1,this.error=!0})},setActive(e){this.activeTab=e}}},c0e={class:"w-full"},d0e={key:0},h0e={key:1},f0e={class:"w-full sticky top-16 left-0",style:{"z-index":"49"}},p0e={ref:"stickyNav",class:"w-full list-none flex justify-center bg-white bg-opacity-80 py-6"},m0e=["onClick"],g0e={key:0,class:"max-w-screen-xl mx-auto flex flex-wrap justify-center items-start pb-8"},_0e={class:"uppercase font-primary text-xs py-2 leading-none"},y0e={class:"uppercase text-3xl py-1 mb-6 leading-none"},v0e=["innerHTML"],b0e={key:0,class:"font-primary pb-6 text-ag-black font-bold"},x0e={key:1,class:"font-primary pb-6 text-ag-black font-bold"},w0e=["href"],$0e={key:1,class:"max-w-screen-xl mx-auto flex flex-wrap justify-center items-start pb-8"};function S0e(e,t,r,i,n,a){const s=qr("spinner"),o=qr("currency-display");return k(),M("div",c0e,[n.loading?(k(),M("div",d0e,[be(s)])):(k(),M("div",h0e,[b("div",f0e,[b("ul",p0e,[(k(!0),M(xe,null,Me(a.filteredTabs,(l,u)=>(k(),M("li",{onClick:c=>a.setActive(l),class:pe(["px-0 py-2 mx-3 text-[16px] cursor-pointer uppercase",n.activeTab.slug===l.slug?"border-b-2 border-ag-red":"border-0"]),key:u},Q(l.title),11,m0e))),128))],512)]),n.activeTab&&n.activeTab.hasOwnProperty("listings")&&n.activeTab.listings.length>0?(k(),M("div",g0e,[(k(!0),M(xe,null,Me(n.activeTab.listings,(l,u)=>(k(),M("div",{key:u,class:"w-full xl:w-1/3 text-center p-4 xl:p-8 animate__animated animate__fadeIn"},[b("div",{class:"relative aspect-video w-full bg-center bg-cover bg-gray-200 mb-4",style:Qt(`background-image: url(${l.images?l.images[0].url:""})`)},null,4),b("div",_0e,Q(l.header_country),1),b("div",y0e,Q(l.header_destination),1),b("div",{class:"font-primary pb-4 text-ag-black-2",innerHTML:l.content_paragraph},null,8,v0e),l.search_price?(k(),M("div",b0e,[t[0]||(t[0]=Ze("from ",-1)),be(o,{value:l.search_price},null,8,["value"]),Ze(" "+Q(l.price_description),1)])):(k(),M("div",x0e,Q(l.price),1)),b("a",{class:"button button--outline mx-auto",href:`${l.url}`},"Explore",8,w0e)]))),128))])):(k(),M("div",$0e,[...t[1]||(t[1]=[b("p",{class:"text-center"},[Ze("We don't have anything right now, but we are working on it."),b("br"),Ze("In the meantime, keep searching our website or "),b("a",{class:"hover:text-ag-red underline",href:"https://africageographic.com/travel/lets-plan-your-dream-african-safari"},"contact us"),Ze(" to start the discussion about your next safari.")],-1)])]))]))])}const T0e=Yt(u0e,[["render",S0e]]),C0e={name:"BookNowButton",props:["listing","showBookNow","showEnquire","showForm","bookNowLabel","enquireLabel","formLabel","formLink"],data(){return{loading:!0,openListing:!1,proxyUrl:"",location:"United States",sadcCountries:["Angola","Botswana","Comoros","Eswatini","Lesotho","Madagascar","Malawi","Mauritius","Mozambique","Namibia","Seychelles","South Africa","Tanzania","Zambia","Zimbabwe"],show:null}},async mounted(){this.proxyUrl=window.proxyUrl;const e=await e$.getUserLocation();e&&(this.location=e.countryName,this.sadcCountries=e.sadc_countries,this.setShow())},watch:{location(){this.setShow()},show(){console.log("location_update",{user_location:this.location,header_country:this.listing.header_country,is_sadc:this.sadcCountries.includes(this.location),show:this.show})}},methods:{setShow(){if(this.location===this.listing.header_country){this.show="local",this.loading=!1;return}else if(this.sadcCountries.includes(this.location)){this.show="sadc",this.loading=!1;return}else{this.show="international",this.loading=!1;return}},toggleOpenListing(){this.openListing=!this.openListing,this.openListing?document.getElementsByTagName("body")[0].classList.add("overflow-hidden"):document.getElementsByTagName("body")[0].classList.remove("overflow-hidden")}}},k0e={class:"flex items-center justify-center"},E0e={key:0,class:"my-1"},P0e={key:1,class:"my-1 px-1"},M0e=["href"],I0e={key:2,class:"my-1 px-1"},A0e=["href"],D0e={key:0},R0e={class:"fixed top-0 left-0 w-full z-50 h-screen bg-black bg-opacity-50 p-0 xl:p-0 flex justify-center items-center"},O0e={class:"h-full flex flex-col",style:{width:"95%",height:"95%"}},L0e={class:"bg-white bg-opacity-90 flex justify-between items-center p-3 xl:p-4 shadow z-50"},F0e={class:""},z0e={class:"text-xs xl:text-sm font-light m-0"},N0e={key:0,class:"flex-1 bg-white p-4 overflow-y-scroll"},B0e={key:1,class:"flex-1 bg-white p-4 overflow-y-scroll"},j0e={key:2,class:"flex-1 bg-white p-4 overflow-y-scroll"};function U0e(e,t,r,i,n,a){const s=qr("rr-resnova");return k(),M("div",null,[b("div",k0e,[r.listing.resnova_id&&r.showBookNow?(k(),M("div",E0e,[b("button",{id:"rrbooknow",class:"button",onClick:t[0]||(t[0]=(...o)=>a.toggleOpenListing&&a.toggleOpenListing(...o))},Q(n.loading?"Loading...":r.bookNowLabel),1)])):X("",!0),r.showEnquire?(k(),M("div",P0e,[b("a",{class:"button button--outline mr-2",href:`${n.proxyUrl}/enquiry?listings=${r.listing.id}`},Q(r.enquireLabel),9,M0e)])):X("",!0),r.showForm?(k(),M("div",I0e,[b("a",{target:"_blank",class:"button button--outline mr-2",href:r.formLink},Q(r.formLabel),9,A0e)])):X("",!0)]),!n.loading&&n.show&&(r.listing.resnova_id||r.listing.resnova_id_international||r.listing.resnova_id_sadc)?(k(),M("div",D0e,[it(b("div",R0e,[b("div",O0e,[b("div",L0e,[b("div",F0e,[t[2]||(t[2]=b("h2",{class:"text-lg xl:text-xl font-primary m-0"},"Booking",-1)),b("p",z0e,Q(r.listing.header_destination),1)]),b("div",{class:"inline-listing cursor-pointer",onClick:t[1]||(t[1]=(...o)=>a.toggleOpenListing&&a.toggleOpenListing(...o))},[...t[3]||(t[3]=[so('<svg width="25px" height="25px" viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><g data-name="Layer 2" class="fill-current text-gray-600 hover:text-ag-red"><g data-name="close"><rect width="24" height="24" transform="rotate(180 12 12)" opacity="0"></rect><path d="M13.41 12l4.3-4.29a1 1 0 1 0-1.42-1.42L12 10.59l-4.29-4.3a1 1 0 0 0-1.42 1.42l4.3 4.29-4.3 4.29a1 1 0 0 0 0 1.42 1 1 0 0 0 1.42 0l4.29-4.3 4.29 4.3a1 1 0 0 0 1.42 0 1 1 0 0 0 0-1.42z"></path></g></g></svg>',1)])])]),r.listing.resnova_id&&n.show==="local"?(k(),M("div",N0e,[be(s,{"widget-id":r.listing.resnova_id,"api-url":"https://resnova.resrequest.com/api"},null,8,["widget-id"])])):X("",!0),r.listing.resnova_id_international&&n.show==="international"?(k(),M("div",B0e,[be(s,{"widget-id":r.listing.resnova_id_international,"api-url":"https://resnova.resrequest.com/api"},null,8,["widget-id"])])):X("",!0),r.listing.resnova_id_sadc&&n.show==="sadc"?(k(),M("div",j0e,[be(s,{"widget-id":r.listing.resnova_id_sadc,"api-url":"https://resnova.resrequest.com/api"},null,8,["widget-id"])])):X("",!0)])],512),[[Dn,n.openListing]])])):X("",!0)])}const V0e=Yt(C0e,[["render",U0e]]),q0e={name:"ResNovaPage",props:["listing"],data(){return{loading:!0,openListing:!1,proxyUrl:"",location:"United States",sadcCountries:["Angola","Botswana","Comoros","Eswatini","Lesotho","Madagascar","Malawi","Mauritius","Mozambique","Namibia","Seychelles","South Africa","Tanzania","Zambia","Zimbabwe"],show:null}},async mounted(){this.proxyUrl=window.proxyUrl;const e=await e$.getUserLocation();e&&(this.location=e.countryName,this.sadcCountries=e.sadc_countries,this.setShow())},watch:{location(){this.setShow()},show(){console.log("location_update",{user_location:this.location,header_country:this.listing.header_country,is_sadc:this.sadcCountries.includes(this.location),show:this.show})}},methods:{setShow(){if(this.location===this.listing.header_country){this.show="local",this.loading=!1;return}else if(this.sadcCountries.includes(this.location)){this.show="sadc",this.loading=!1;return}else{this.show="international",this.loading=!1;return}},toggleOpenListing(){this.openListing=!this.openListing,this.openListing?document.getElementsByTagName("body")[0].classList.add("overflow-hidden"):document.getElementsByTagName("body")[0].classList.remove("overflow-hidden")}}},G0e={key:0},H0e={class:"p-4 xl:p-4 h-auto"},Y0e={key:0,class:"p-4"},W0e={key:1,class:"p-4"},Z0e={key:2,class:"p-4"};function K0e(e,t,r,i,n,a){const s=qr("rr-resnova");return!n.loading&&n.show&&(r.listing.resnova_id||r.listing.resnova_id_international||r.listing.resnova_id_sadc)?(k(),M("div",G0e,[b("div",H0e,[b("div",null,[r.listing.resnova_id&&n.show==="local"?(k(),M("div",Y0e,[be(s,{"widget-id":r.listing.resnova_id,"api-url":"https://resnova.resrequest.com/api"},null,8,["widget-id"])])):X("",!0),r.listing.resnova_id_international&&n.show==="international"?(k(),M("div",W0e,[be(s,{"widget-id":r.listing.resnova_id_international,"api-url":"https://resnova.resrequest.com/api"},null,8,["widget-id"])])):X("",!0),r.listing.resnova_id_sadc&&n.show==="sadc"?(k(),M("div",Z0e,[be
82(s,{"widget-id":r.listing.resnova_id_sadc,"api-url":"https://resnova.resrequest.com/api"},null,8,["widget-id"])])):X("",!0)])])])):X("",!0)}const X0e=Yt(q0e,[["render",K0e]]),J0e={name:"HubspotForm",props:["hubspotFormId"],mounted(){let e=this.hubspotFormId,t=document.createElement("script"),r="/thank-you-enquiry";t.setAttribute("src","https://js-eu1.hsforms.net/forms/embed/v2.js"),t.setAttribute("charset","utf-8"),t.setAttribute("type","text/javascript"),document.querySelector(".c18-form").appendChild(t);const i=setInterval(()=>{typeof hbspt<"u"&&(hbspt.forms.create({region:"eu1",target:".c18-form",portalId:"139640268",formId:e,onFormReady:function(n){const a=document.querySelector(".c18-form iframe"),s=a.contentDocument||a.contentWindow.document,o=s.querySelector('input[name="what_is_your_group_total_budget_in_usd___hubspot_"]');if(o){o.type="range",o.min="4000",o.max="100000",o.step="1000",o.value="40000";let f=document.createElement("div");f.classList.add("legend"),f.innerHTML=` 83 <div class="legendvalue" style="display:flex;width: 100%;height: 30px;justify-content: center;align-items: flex-end;margin-bottom: 8px;"> 84 <span class="current-price-value">US$ 40 000</span> 85 </div> 86 `,o.before(f);let p=document.createElement("div");p.classList.add("legend"),p.innerHTML=` 87 <div class="legenddash" style="display:flex; width: 100%; height: 12px; justify-content: space-between;"> 88 <span class="bigdash"><div class="smallnum left">4 000</div></span> 89 <span class="smalldash"></span> 90 <span class="smalldash"></span> 91 <span class="bigdash"><div class="smallnum middle">20 000</div></span> 92 <span class="smalldash"></span> 93 <span class="smalldash"></span> 94 <span class="smalldash"></span> 95 <span class="bigdash"><div class="smallnum middle">40 000</div></span> 96 <span class="smalldash"></span> 97 <span class="smalldash"></span> 98 <span class="smalldash"></span> 99 <span class="bigdash"><div class="smallnum middle">60 000</div></span> 100 <span class="smalldash"></span> 101 <span class="smalldash"></span> 102 <span class="smalldash"></span> 103 <span class="bigdash"><div class="smallnum middle">80 000</div></span> 104 <span class="smalldash"></span> 105 <span class="smalldash"></span> 106 <span class="smalldash"></span> 107 <span class="bigdash"><div class="smallnum right">100 000 +</div></span> 108 </div> 109 `,o.after(p),o.addEventListener("input",function(){this.setAttribute("value",this.value);const m=this.value.toString().replace(/\B(?=(\d{3})+(?!\d))/g," ");f.querySelector(".current-price-value").innerHTML="US$ "+m})}let l=s.querySelectorAll(".hs_who_will_you_be_travelling_with___hubspot_ li input");l&&l.forEach(function(f){f.addEventListener("change",function(){const p=this.value,m=s.querySelector(".hs_how_many_people_are_travelling___hubspot_"),g=s.querySelector('input[name="how_many_people_are_travelling___hubspot_"]');p==="I travel solo"?(g.value=1,m.classList.remove("visible")):p==="My partner"?(g.value=2,m.classList.remove("visible")):(p==="My family"||p==="My friends")&&(g.value="",m.classList.add("visible"))})});const u=s.querySelector('input[name="safari_type__hubspot_"]');u.value=document.title;const c=s.querySelector('input[name="website"]');
109c&&(c.value=document.URL),setTimeout(()=>{const f=s.querySelector('input[name="gclid_field"]');var p=JSON.parse(localStorage.getItem("gclid")),m=p&&new Date().getTime()<p.expiryDate;p&&m&&(f.value=p.value)},5e3),(function(){function f(g){const v=g+"=",x=document.cookie.split(";");for(let _=0;_<x.length;_++){let y=x[_].trim();if(y.indexOf(v)===0)return decodeURIComponent(y.substring(v.length))}return null}const p=f("utm_campaign_cookie");if(p){const g=s.querySelector('input[name="enquiry_form___ag_newsletter"]');g.value=p}const m=f("hsa_grp_cookie");if(m){const g=s.querySelector('input[name="enquiry_adgroup_id"]');g.value=m}})();const d=document.createElement("style");d.type="text/css",d.innerHTML=` 110 .hbspt-form { 111 background-color:#fff !important; 112 padding:40px !important; 113 max-width:800px !important; 114 margin:auto !important; 115 } 116 .hs-form-field input[type=text], .hs-form-field input[type=email], .hs-form-field input[type=tel], .hs-form-field input[type=number], .hs-form-field select { 117 border-radius: 4px !important; 118 border-width: 1px; 119 border-style: solid; 120 border-color: #b8bdc9; 121 color: #333; 122 background-color: #fff !important; 123 width: 90% !important; 124 } 125 .hs-form-field textarea { 126 border-radius: 4px !important; 127 border-width: 1px; 128 border-style: solid; 129 border-color: #b8bdc9; 130 color: #333; 131 background-color: #fff !important; 132 } 133 .hs-form-field input[type=text]:hover, .hs-form-field input[type=email]:hover, .hs-form-field input[type=tel]:hover, .hs-form-field input[type=number]:hover, .hs-form-field textarea:hover, .hs-form-field select:hover { 134 border-width:2px; 135 border-color: rgba(238, 28, 37, .5); 136 box-shadow: 0 0 0 2px rgba(238, 28, 37, .25); 137 } 138 label { 139 margin-bottom:12px; 140 } 141 .hs-input[type=radio], .hs-input[type=checkbox] { 142 width:20px !important; 143 height:20px !important; 144 } 145 ul.multi-container span { 146 // position: absolute; 147 margin-top: 4px; 148 } 149 .multi-container { 150 columns:4; 151 } 152 .hs_which_experiences_are_you_interested_in___hubspot_ .multi-container, .hs_which_countries_would_you_like_to_visit_on_this_trip___hubspot_ .multi-container, .hs_travel_destination__hubspot_form_ .multi-container { 153 columns:3 !important; 154 } 155 .hs_what_is_your_group_total_budget_in_usd___hubspot_ label { 156 margin-top:20px; 157 } 158 .hs-form-field { 159 padding-bottom: 20px !important; 160 margin-bottom: 30px !important; 161 border-bottom: 1px solid #f1f1f1 !important; 162 } 163 .fn-date-picker .pika-lendar { 164 width: 320px; 165 } 166 .fn-date-picker .pika-button { 167 text-align: center; 168 } 169 .fn-date-picker .pika-button:hover {
170 background-color: #ee1c24 !important; 171 } 172 .fn-date-picker .is-today .pika-button { 173 color: #ee1c24; 174 } 175 .fn-date-picker .is-selected .pika-button { 176 background-color: #ee1c24 !important; 177 box-shadow: inset 0 1px 3px #ee1c24; 178 } 179 .hs-submit { 180 padding-bottom: 20px !important; 181 } 182 .hs-submit > .actions { 183 text-align: center !important; 184 } 185 .hs-submit > .actions input { 186 padding: 1rem 0.5rem; 187 width: 13rem; 188 border-radius: .125rem; 189 font-size:16px !important; 190 font-weight:100 !important; 191 } 192 .hs-submit > .actions input:hover { 193 background-color:#dc2626 !important; 194 font-size:16px !important; 195 font-weight:100 !important; 196 } 197 .current-price-value { 198 font-size: 16px; 199 background: #ed5565; 200 color: #fff; 201 padding: 4px 6px; 202 border-radius: 4px; 203 line-height: 14px; 204 font-family: "Ubuntu", "sans-serif"; 205 } 206 .hs-form-required { 207 margin-left:4px; 208 } 209 .legenddash { 210 padding-right: 1%; 211 padding-left: 2%; 212 } 213 .smalldash { 214 height:4px; 215 width:1px; 216 background:#e1e4e9; 217 margin-top: 2px; 218 } 219 .bigdash { 220 height:8px; 221 width:1px; 222 background:#e1e4e9; 223 margin-top: 2px; 224 position:relative; 225 } 226 .smallnum { 227 color: #999; 228 font-size: 12px; 229 position: absolute; 230 margin-top: 10px; 231 font-family: "Ubuntu", "sans-serif"; 232 } 233 .smallnum.left { 234 left: -3px; 235 } 236 .smallnum.right { 237 right: -12px; 238 } 239 .smallnum.middle { 240 left: -15px; 241 } 242 input[type="range"] { 243 -webkit-appearance: none; 244 width: 100%; 245 height: 25px; 246 background: #d3d3d3; 247 outline: none; 248 opacity: 0.7; 249 -webkit-transition: .2s; 250 transition: opacity .2s; 251 padding: 0 !important; 252 margin: 0 !important; 253 } 254 255 input[type="range"]:hover { 256 opacity: 1; 257 } 258 input[type="range"]::-webkit-slider-thumb { 259 -webkit-appearance: none; 260 appearance: none; 261 width: 24px; 262 height: 25px; 263 background: #ee1c25; 264 cursor: pointer; 265 } 266 input[type="range"]::-moz-range-thumb { 267 width: 25px; 268 height: 25px; 269 background: #ee1c25; 270 cursor: pointer; 271 } 272 input[type="radio"] { 273 display: none !important; 274 } 275 input[type="radio"]:checked + span { 276 background-color: #ed5565 !important; 277 color:#fff !important; 278 border: 1px solid #ed5565 !important; 279 width: 25px; 280 height: 25px; 281 background: #ee1c25; 282 cursor: pointer; 283 } 284 .hs-form-radio span { 285 width: 160px !important; 286 height: 50px !important; 287 background-color: #f1f1f1 !important; 288 transition: all 250ms ease !important; 289 will-change: transition !important; 290 display: inline-block !important; 291 text-align: center !important; 292 cursor: pointer !important; 293 position: relative !important; 294 line-height:48px !important; 295 border: 1px solid #f1eaea !important; 296 } 297 .hs-form-radio span:active { 298 transform: translateY(6px) !important; 299 } 300 .inputs-list>li+li { 301 padding-top:0 !important; 302 } 303 .form-columns-3 .input { 304 margin-right:25px !important; 305 } 306 .hs-dependent-field .hs-fieldtype-select, .hs-dependent-field .hs-fieldtype-number, .hs-dependent-field .hs-fieldtype-date { 307 width: 50%; 308 float: left; 309 } 310 .hs-fieldtype-intl-phone input { 311 width: 58% !important; 312 max-width: 58% !important; 313 } 314 .hs-fieldtype-intl-phone.hs-input select { 315 width: 40% !important; 316 } 317 .hs_how_many_people_are_travelling___hubspot_ { 318 display: none; 319 } 320 .visible { 321 display:block; 322 } 323 .fn-date-picker .pika-label { 324 background: #f1f1f1; 325 border: 1px solid #c1c1c1; 326 padding: 2px 6px; 327 border-radius: 2px; 328 margin: 0 1px; 329 } 330 .fn-date-picker .pika-label:hover { 331 background: #d6d4d4; 332 } 333 li.hs-form-checkbox label { 334 display:flex; 335 } 336 @media (max-width: 768px) { 337 .hbspt-form { 338 padding: 4% !important; 339 max-width: 88% !important; 340 } 341 .multi-container { 342 columns:2; 343 } 344 .hs_which_experiences_are_you_interested_in___hubspot_ .multi-container { 345 columns:1 !important; 346 } 347 .hs_which_countries_would_you_like_to_visit_on_this_trip___hubspot_ .multi-container, .hs_travel_destination__hubspot_form_ .multi-container { 348 columns:1 !important; 349 } 350 .hs-fieldtype-intl-phone select { 351 width: 40% !important; 352 max-width: 40% !important; 353 } 354 .hs-form-radio span { 355 width: 135px !important; 356 font-size: 14px !important; 357 } 358 .hs-dependent-field .hs-fieldtype-select, .hs-dependent-field .hs-fieldtype-number, .hs-dependent-field .hs-fieldtype-date { 359 float: unset !important; 360 width: 100% !important; 361 } 362 .smallnum { 363 font-size:10px; 364 } 365 } 366 @media (max-width: 480px) { 367 .hs-fieldtype-intl-phone select { 368 width: 40% !important; 369 max-width: 40% !important; 370 } 371 372 } 373 `,s.querySelector(".hbspt-form").appendChild(d)},onFormSubmit:function(n){var v,x,_,y,w,$;const a=document.querySelector(".c18-form iframe"),s=a.contentDocument||a.contentWindow.document,o=e,l=((v=s.querySelector('input[name="email"]'))==null?void 0:v.value)||"",u=((x=s.querySelector('input[name="gclid_field"]'))==null?void 0:x.value)||"",c=((_=s.querySelector('input[name="what_is_your_group_total_budget_in_usd___hubspot_"]'))==null?void 0:_.value)||"",d=Array.from(s.querySelectorAll('.hs_which_countries_would_you_like_to_visit_on_this_trip___hubspot_ li input[type="checkbox"]:checked')).map(S=>S.value).join(", "),h=Array.from(s.querySelectorAll('.hs_which_experiences_are_you_interested_in___hubspot_ li input[type="checkbox"]:checked')).map(S=>S.value).join(", "),f=((y=s.querySelector('input[name="arrival_date__hubspot_"]'))==null?void 0:y.value)||"",p=((w=s.querySelector('.hs_who_will_you_be_travelling_with___hubspot_ li input[type="radio"]:checked'))==null?void 0:w.value)||"",m=(($=s.querySelector('.hs_have_you_been_to_africa_before___hubspot_ li input[type="radio"]:checked'))==null?void 0:$.value)||"",g=Array.from(s.querySelectorAll('.hs_travel_destination__hubspot_form_ li input[type="checkbox"]:checked')).map(S=>S.value).join(", ");sessionStorage.setItem("enquiry_conversion",JSON.stringify({form_id:o,email:l,gclid:u,travel_budget:c,safari_destination:d,safari_experiences:h,travel_date_known:f,travel_group:p,been_to_africa:m,additional_destinations:g}))},onFormSubmitted:function(){window.location.href=r}}),clearInterval(i))})}},Q0e={class:"c18-form"};function e_e(e,t,r,i,n,a){return k(),M("div",Q0e)}const t_e=Yt(J0e,[["render",e_e]]),r_e={name:"HubspotFormcta",props:["hubspotFormId"],data(){return{formId:`${Date.now()}-${Math.random().toString(36).substr(2,9)}`}},mounted(){let e=this.hubspotFormId,t=this.formId;if(!window.hubspotScriptLoaded){let i=document.createElement("script");i.setAttribute("src","https://js-eu1.hsforms.net/forms/embed/v2.js"),i.setAttribute("charset","utf-8"),i.setAttribute("type","text/javascript"),document.head.appendChild(i),window.hubspotScriptLoaded=!0}const r=setInterval(()=>{typeof hbspt<"u"&&(hbspt.forms.create({region:"eu1",target:`#c03-form-${t}`,portalId:"139640268",formId:e,onFormReady:function(i){const n=document.querySelector(`#c03-form-${t} iframe`),a=n.contentDocument||n.contentWindow.document;a.querySelector('input[name="what_is_your_group_total_budget_in_usd___hubspot_"]');const s=a.querySelector('input[name="safari_type__hubspot_"]');
373s.value=document.title;const o=a.querySelector('input[name="website"]');o&&(o.value=document.URL),setTimeout(()=>{const c=a.querySelector('input[name="gclid_field"]');var d=JSON.parse(localStorage.getItem("gclid")),h=d&&new Date().getTime()<d.expiryDate;d&&h&&(c.value=d.value)},5e3),(function(){function c(f){const p=f+"=",m=document.cookie.split(";");for(let g=0;g<m.length;g++){let v=m[g].trim();if(v.indexOf(p)===0)return decodeURIComponent(v.substring(p.length))}return null}const d=c("utm_campaign_cookie");if(d){const f=a.querySelector('input[name="enquiry_form___ag_newsletter"]');f.value=d}const h=c("hsa_grp_cookie");if(h){const f=a.querySelector('input[name="enquiry_adgroup_id"]');f.value=h}})();const l=document.createElement("style");l.type="text/css",l.innerHTML=` 374 .hbspt-form { 375 max-width: 560px !important; 376 margin:auto !important; 377 } 378 .hbspt-form form { 379 display: flex; 380 justify-content: center; 381 align-items: center; 382 gap: 16px; 383 text-align: center; 384 flex-wrap: wrap; 385 } 386 .hs-form-field input[type=email] { 387 border-radius: 4px !important; 388 border-width: 1px; 389 border-style: solid; 390 border-color: #b8bdc9; 391 color: #333; 392 background-color: #fff !important; 393 } 394 .hs-form-field input[type=email]:hover { 395 border-width:2px; 396 border-color: rgba(238, 28, 37, .5); 397 box-shadow: 0 0 0 2px rgba(238, 28, 37, .25); 398 } 399 .hs-form-field { 400 width:55%; 401 margin-bottom: 0; 402 height: 65px; 403 } 404 405 .actions { 406 margin-top:0 !important; 407 padding: 0 !important; 408 } 409 .hs-email > .inputs-list label { 410 margin-top:4px !important; 411 font-size:12px; 412 } 413 .hs-submit > .actions input { 414 padding: 13px 0; 415 width: 13rem; 416 border-radius: 4px; 417 font-size:16px !important; 418 font-weight:100 !important; 419 } 420 .hs-submit > .actions input:hover { 421 background-color:#dc2626 !important; 422 font-size:16px !important; 423 font-weight:100 !important; 424 } 425 .hs_error_rollup { 426 display:none; 427 } 428 .submitted-message { 429 text-align:center;} 430 431 432 @media (max-width: 768px) { 433 .hbspt-form { 434 padding: 4% !important; 435 max-width: 88% !important; 436 } 437 .hs-form-field { 438 width:208px; 439 } 440 } 441 442 443 } 444 `,a.querySelector(".hbspt-form").appendChild(l)}}),clearInterval(r))})}},i_e=["id"];function n_e(e,t,r,i,n,a){return k(),M("div",{id:`c03-form-${n.formId}`,class:"c03-form"},null,8,i_e)}const a_e=Yt(r_e,[["render",n_e]]),s_e={name:"TypeForm",props:["formId"],mounted(){let e=document.createElement("script");e.setAttribute("src","//embed.typeform.com/next/embed.js"),e.setAttribute("charset","utf-8"),e.setAttribute("type","text/javascript"),document.querySelector(".c19-form-container").appendChild(e)}},o_e=["data-tf-live"];function l_e(e,t,r,i,n,a){return k(),M("div",{"data-tf-live":r.formId},null,8,o_e)}const u_e=Yt(s_e,[["render",l_e]]),c_e={name:"JotForm",props:["formId"],mounted(){}},d_e={id:"jotform111"};function h_e(e,t,r,i,n,a){return k(),M("div",d_e,[...t[0]||(t[0]=[b("iframe",{src:"jotformtest.html",width:"100%",height:"800px"},null,-1)])])}const f_e=Yt(c_e,[["render",h_e]]),p_e={name:"HeroImageBlock",props:["video_background_url","background_img_url","background_img_alt"],methods:{isMobile(){return!!/iPhone|iPad|iPod|Android/i.test(navigator.userAgent)}}}
444,m_e={key:0,class:"video hidden md:block",id:"bg-video-container",style:{position:"absolute",top:"0",left:"0",width:"100%",height:"100%","z-index":"0",overflow:"hidden"}},g_e={autoplay:"",muted:"",loop:"",playsinline:"",style:{width:"100%",height:"100%","object-fit":"cover"}},__e=["src"];function y_e(e,t,r,i,n,a){return a.isMobile()?X("",!0):(k(),M("div",m_e,[b("video",g_e,[b("source",{src:r.video_background_url,type:"video/mp4"},null,8,__e)])]))}const v_e=Yt(p_e,[["render",y_e]]),b_e={name:"HubspotBookingForm",props:["hubspotFormId"],mounted(){let e=this.hubspotFormId,t=document.createElement("script");t.setAttribute("src","https://js-eu1.hsforms.net/forms/embed/v2.js"),t.setAttribute("charset","utf-8"),t.setAttribute("type","text/javascript"),document.querySelector(".c23-form").appendChild(t);var r=document.getElementById("enquire"),i=document.getElementById("c23-bg");function n(){var l=r.getBoundingClientRect(),u=window.innerHeight||document.documentElement.clientHeight,c=l.top<0&&l.bottom>u,d=l.top<0&&l.bottom<u&&l.bottom>0;c?(i.classList.remove("absolute"),i.classList.add("fixed"),i.classList.add("top-0")):d?(i.classList.remove("fixed"),i.classList.remove("top-0"),i.classList.add("bottom-0"),i.classList.add("absolute"),i.classList.add("bg-bottom")):(i.classList.remove("fixed"),i.classList.add("absolute"))}var a=!1;function s(){a||(window.requestAnimationFrame(function(){n(),a=!1}),a=!0)}n(),window.addEventListener("scroll",s,{passive:!0}),window.addEventListener("resize",s);const o=setInterval(()=>{typeof hbspt<"u"&&(hbspt.forms.create({region:"eu1",target:".c23-form",portalId:"139640268",formId:e,onFormReady:function(l){const u=document.querySelector(".c23-form iframe"),c=u.contentDocument||u.contentWindow.document,d=document.createElement("style");d.type="text/css",d.innerHTML=` 445 .hbspt-form { 446 background-color:#fff !important; 447 padding:40px !important; 448 max-width:800px !important; 449 margin:auto !important; 450 } 451 .hs-form-field input[type=text], .hs-form-field input[type=email], .hs-form-field input[type=tel], .hs-form-field input[type=number], .hs-form-field select { 452 border-radius: 4px !important; 453 border-width: 1px; 454 border-style: solid; 455 border-color: #b8bdc9; 456 color: #333; 457 background-color: #fff !important; 458 width: 90% !important; 459 } 460 .hs-form-field textarea { 461 border-radius: 4px !important; 462 border-width: 1px; 463 border-style: solid; 464 border-color: #b8bdc9; 465 color: #333; 466 background-color: #fff !important; 467 } 468 .hs-form-field input[type=text]:hover, .hs-form-field input[type=email]:hover, .hs-form-field input[type=tel]:hover, .hs-form-field input[type=number]:hover, .hs-form-field textarea:hover, .hs-form-field select:hover { 469 border-width:2px; 470 border-color: rgba(238, 28, 37, .5); 471 box-shadow: 0 0 0 2px rgba(238, 28, 37, .25); 472 } 473 label { 474 margin-bottom:12px; 475 } 476 .hs-input[type=radio], .hs-input[type=checkbox] { 477 width:20px !important; 478 height:20px !important; 479 } 480 ul.multi-container span { 481 // position: absolute; 482 margin-top: 4px; 483 } 484 // .multi-container { 485 // columns:4; 486 // } 487 // .hs_which_experiences_are_you_interested_in___hubspot_ .multi-container, .hs_which_countries_would_you_like_to_visit_on_this_trip___hubspot_ .multi-container, .hs_travel_destination__hubspot_form_ .multi-container { 488 // columns:3 !important; 489 // } 490 .hs_what_is_your_group_total_budget_in_usd___hubspot_ label { 491 margin-top:20px; 492 } 493 .hs-form-field { 494 padding-bottom: 20px !important; 495 // margin-bottom: 30px !important; 496 // border-bottom: 1px solid #f1f1f1 !important; 497 }
498 .fn-date-picker .pika-lendar { 499 width: 320px; 500 } 501 .fn-date-picker .pika-button { 502 text-align: center; 503 } 504 .fn-date-picker .pika-button:hover { 505 background-color: #ee1c24 !important; 506 } 507 .fn-date-picker .is-today .pika-button { 508 color: #ee1c24; 509 } 510 .fn-date-picker .is-selected .pika-button { 511 background-color: #ee1c24 !important; 512 box-shadow: inset 0 1px 3px #ee1c24; 513 } 514 .hs-submit { 515 padding-bottom: 20px !important; 516 } 517 .hs-submit > .actions { 518 text-align: center !important; 519 } 520 .hs-submit > .actions input { 521 padding: 1rem 0.5rem; 522 width: 13rem; 523 border-radius: .125rem; 524 font-size:16px !important; 525 font-weight:100 !important; 526 } 527 .hs-submit > .actions input:hover { 528 background-color:#dc2626 !important; 529 font-size:16px !important; 530 font-weight:100 !important; 531 } 532 .current-price-value { 533 font-size: 16px; 534 background: #ed5565; 535 color: #fff; 536 padding: 4px 6px; 537 border-radius: 4px; 538 line-height: 14px; 539 font-family: "Ubuntu", "sans-serif"; 540 } 541 .hs-form-required { 542 margin-left:4px; 543 } 544 .legenddash { 545 padding:0 12px; 546 } 547 .smalldash { 548 height:4px; 549 width:1px; 550 background:#e1e4e9; 551 margin-top: 2px; 552 } 553 .bigdash { 554 height:8px; 555 width:1px; 556 background:#e1e4e9; 557 margin-top: 2px; 558 position:relative; 559 } 560 .smallnum { 561 color: #999; 562 font-size: 12px; 563 position: absolute; 564 margin-top: 10px; 565 font-family: "Ubuntu", "sans-serif"; 566 } 567 .smallnum.left { 568 left: -3px; 569 } 570 .smallnum.right { 571 right: -12px; 572 } 573 .smallnum.middle { 574 left: -15px; 575 } 576 input[type="range"] { 577 -webkit-appearance: none; 578 width: 100%; 579 height: 25px; 580 background: #d3d3d3; 581 outline: none; 582 opacity: 0.7; 583 -webkit-transition: .2s; 584 transition: opacity .2s; 585 padding: 0 !important; 586 margin: 0 !important; 587 } 588 589 input[type="range"]:hover { 590 opacity: 1; 591 } 592 input[type="range"]::-webkit-slider-thumb { 593 -webkit-appearance: none; 594 appearance: none; 595 width: 24px; 596 height: 25px; 597 background: #ee1c25; 598 cursor: pointer; 599 } 600 input[type="range"]::-moz-range-thumb { 601 width: 25px; 602 height: 25px; 603 background: #ee1c25; 604 cursor: pointer; 605 } 606 .hs_booking_form___booking_terms input[type="radio"] { 607 display: none !important; 608 } 609 .hs_booking_form___booking_terms input[type="radio"]:checked + span { 610 background-color: #ed5565 !important; 611 color:#fff !important; 612 border: 1px solid #ed5565 !important; 613 width: 25px; 614 height: 25px; 615 background: #ee1c25; 616 cursor: pointer; 617 } 618 .hs_booking_form___booking_terms .hs-form-radio span { 619 width: 170px !important; 620 height: 50px !important; 621 background-color: #f1f1f1 !important; 622 transition: all 250ms ease !important; 623 will-change: transition !important; 624 display: inline-block !important; 625 text-align: center !important; 626 cursor: pointer !important; 627 position: relative !important; 628 line-height:48px !important; 629 border: 1px solid #f1eaea !important; 630 font-size: 15px !important; 631 } 632 .hs_booking_form___booking_terms .hs-form-radio span:active { 633 transform: translateY(6px) !important; 634 } 635 .inputs-list>li+li { 636 padding-top:0 !important; 637 } 638 .form-columns-3 .input { 639 margin-right:25px !important; 640 } 641 .hs-dependent-field .hs-fieldtype-select, .hs-dependent-field .hs-fieldtype-number, .hs-dependent-field .hs-fieldtype-date { 642 width: 50%; 643 float: left; 644 } 645 .hs-fieldtype-intl-phone input { 646 width: 58% !important; 647 max-width: 58% !important; 648 } 649 .hs-fieldtype-intl-phone.hs-input select { 650 width: 40% !important; 651 } 652 .fn-date-picker .pika-label { 653 background: #f1f1f1; 654 border: 1px solid #c1c1c1; 655 padding: 2px 6px; 656 border-radius: 2px; 657 margin: 0 1px; 658 } 659 .fn-date-picker .pika-label:hover { 660 background: #d6d4d4; 661 } 662 663 @media (max-width: 768px) { 664 .hbspt-form { 665 padding: 4% !important; 666 max-width: 88% !important; 667 } 668 .hs-fieldtype-intl-phone select { 669 width: 40% !important; 670 max-width: 40% !important; 671 } 672 .hs_booking_form___booking_terms .hs-form-radio span { 673 width: 135px !important; 674 font-size: 14px !important; 675 } 676 .hs-dependent-field .hs-fieldtype-select, .hs-dependent-field .hs-fieldtype-number, .hs-dependent-field .hs-fieldtype-date { 677 float: unset !important; 678 width: 100% !important; 679 } 680 .smallnum { 681 font-size:10px; 682 } 683 } 684 685 686 .hs_booking_form___nationality, .hs_firstname, .hs_lastname, .hs_phone, .hs_email, .hs_booking_form___passport_number, .hs_booking_form___guest_1_first_name, .hs_booking_form___guest_1_last_name, .hs_booking_form___guest_1_phone_number, .hs_booking_form___guest_1_email { 687 width: 50%; 688 float: left; 689 } 690 #address-f908b9c2-d573-4a7b-a6a1-142ae3eda2a9, .hs_booking_form___dietary_requirements , .hs_booking_form___medical, .hs_booking_form___special_requests { 691 width: 95% !important; 692 } 693 .hs-fieldtype-intl-phone { 694 width: 90% !important; 695 } 696 .hs-field-desc { 697 font-size:14px !important; 698 } 699 .hs-input[type=file] { 700 margin-top:16px; 701 702 } 703 .hs_booking_form___passport_copy { 704 clear:both !important; 705 } 706 .hs_booking_form___information_type .inputs-list>li{ 707 position: relative; 708 } 709 .hs_booking_form___information_type .inputs-list li:nth-child(-n + 3)::after{ 710 content: '>'; 711 position: absolute; 712 top: 35%; 713 right: -5px; 714 } 715 .inputs-list label.hs-error-msg { 716 position:absolute; 717 } 718 .hs_firstname, .hs_lastname, .hs_phone, .hs_email, .hs_booking_form___passport_number, .hs_booking_form___passport_expiry_date, .hs_booking_form___nationality, .hs_booking_form___date_of_birth, .hs_country_region__drop_down_, .hs_booking_form___guest_1_first_name, .hs_booking_form___guest_1_last_name { 719 height:120px; 720 } 721 .nextbutton:hover { 722 cursor: pointer; 723 background-color: #dc2626 !important; 724 } 725 li.hs-form-checkbox label { 726 display:flex; 727 } 728 @media (max-width: 480px) { 729 .hs-fieldtype-intl-phone select { 730 width: 40% !important; 731 max-width: 40% !important; 732 } 733 .hs_booking_form___information_type .inputs-list li:nth-child(-n + 3)::after{ 734 right: 8px !important; 735 } 736 } 737 `,c.querySelector(".hbspt-form").appendChild(d)}}),clearInterval(o))})}},x_e={class:"c23-form"};function w_e(e,t,r,i,n,a){return k(),M("div",x_e)}const $_e=Yt(b_e,[["render",w_e]]),Zd=e=>{const t=RegExp("[?&]"+e+"=([^&]*)").exec(typeof window<"u"?window.location.search:"");return t?decodeURIComponent(t[1].replace(/\+/g," ")):null},Rx=e=>{const t=document.cookie.split("; ").find(r=>r.startsWith(e+"="));return t?t.split("=")[1]:null},E$=()=>{if(typeof window>"u")return!1;try{return Zd("ga_debug")==="1"&&sessionStorage.setItem("ga_debug","1"),sessionStorage.getItem("ga_debug")==="1"}catch{}return!1},nR=e=>typeof window>"u"||!e||typeof window.gtag=="function"?Promise.resolve():(window.dataLayer=window.dataLayer||[],window.gtag=function(){window.dataLayer.push(arguments)},window.gtag("js",new Date),new Promise(t=>{const r=document.createElement("script");
737r.async=!0,r.src=`https://www.googletagmanager.com/gtag/js?id=${e}`,r.onload=()=>{window.gtag("config",e,E$()?{debug_mode:!0}:{});let i=!1;const n=()=>{i||(i=!0,t())};window.gtag("get",e,"client_id",n),setTimeout(n,1500)},r.onerror=t,document.head.appendChild(r)})),Ox=(e,t,r={})=>{const i=r.sendTo||"G-B8LY2NVQH5";if(typeof window>"u"||!i)return;const n={...t,send_to:i};E$()&&(n.debug_mode=!0);const a=()=>{typeof window.gtag=="function"&&(r.userData&&window.gtag("set","user_data",r.userData),window.gtag("event",e,n))};typeof window.gtag=="function"?a():nR(i).then(a)},tk=e=>nR(e),by="ga_pending_event",S_e=(e,t={},r={})=>{if(!(typeof window>"u"))try{const i=JSON.parse(sessionStorage.getItem(by)||"[]"),n=Array.isArray(i)?i:[];n.push({event:e,data:t,sendTo:r.sendTo||null,userData:r.userData||null}),sessionStorage.setItem(by,JSON.stringify(n))}catch{}},T_e=()=>{if(typeof window>"u")return;let e=null;try{e=sessionStorage.getItem(by)}catch{return}if(!e)return;try{sessionStorage.removeItem(by)}catch{}let t;try{t=JSON.parse(e)}catch{return}Array.isArray(t)||(t=[t]),t.forEach(r=>{r&&r.event&&Ox(r.event,r.data||{},{...r.sendTo?{sendTo:r.sendTo}:{},...r.userData?{userData:r.userData}:{}})})},rk="enquiry_ab_variant",C_e=()=>typeof window<"u"&&["travel.africageographic.com","travel.staging.africageographic.com","localhost"].includes(window.location.hostname),k_e=e=>e&&String(e).trim()||void 0||"abtest001_step7_first",E_e=e=>String(e&&String(e).trim()||void 0||"A/B").toUpperCase(),P_e=e=>{let t=e;if((t==null||String(t).trim()==="")&&(t=void 0),t==null||String(t).trim()==="")return 50;const r=Number(t);return Number.isFinite(r)?Math.min(100,Math.max(0,r)):50},M_e=(e,t)=>{if(typeof window>"u"||!C_e())return"a";const r=(Zd("v")||"").toLowerCase();if(r==="a"||r==="b")return r;const i=E_e(e);if(i==="A")return"a";if(i==="B")return"b";try{const a=localStorage.getItem(rk);if(a==="a"||a==="b")return a}catch{}const n=Math.random()*100<P_e(t)?"b":"a";try{localStorage.setItem(rk,n)}catch{}return n},os=dA("enquiry",()=>{const e=se(!1),t=se(!1),r=se(null),i=se({}),n=se(null),a=se(!1),s=()=>({hutk:Rx("hubspotutk")||"",pageUri:window.location.href,pageName:window.location.pathname,ipAddress:"188.40.1.210"});return{enquiryForm:i,redirectUrl:n,loading:e,hubspotId:r,success:t,submitEnquiry:async()=>{try{return e.value=!0,await Rt.post("/api/enquiry-forms/"+r.value,{fields:Object.entries(i.value).filter(([l,u])=>u!==null).map(([l,u])=>({name:l,value:Array.isArray(u)?u.join(";"):u})),context:s()}),t.value=!0,!0}catch(l){return console.error(l),vA(l,{tags:{feature:"enquiry_form",area:"submit"},extra:{hubspot_id:r.value,page:typeof window<"u"?window.location.href:""}}),!1}finally{e.value=!1}},budgetValueRequired:a}}),P$=dA("currencyStore",()=>{const e=se({}),t=se([]),r=se("USD"),i=(l={},u="USD",c=[])=>{if(e.value=l||{},t.value=c||[],u&&e.value[u])r.value=u;else{const d=Object.keys(e.value);r.value=d.length?d[0]:"USD"}},n=l=>{if(!l||!e.value||!e.value[l]){console.log("no code");return}r.value=l},a=H(()=>r.value),s=H(()=>{const l=r.value||"USD";if(!e.value||typeof e.value!="object")return{code:"USD",rate:1};const u=e.value[l];return typeof u=="number"?{code:l,rate:u}:u&&typeof u=="object"&&typeof u.rate=="number"?{code:l,rate:u.rate}:{code:"USD",rate:1}}),o=H(()=>s.value.rate);return{currencyRates:e,currencySelectorOptions:t,selectedCurrency:r,activeCurrencyCode:a,activeCurrencyRate:s,getSelectedCurrency:o,init:i,setSelectedCurrency:n}}),I_e={class:"max-w-[48rem] mx-auto pt-3"},A_e={class:"grid grid-cols-1 md:grid-cols-2 gap-3"},D_e={__name:"StartHere",setup(e,{expose:t}){const r=os(),i=H({get(){return r.enquiryForm.safari_type},set(s){r.enquiryForm.safari_type=s}});function n(s){i.value=s}const a=H(()=>!!i.value);return t({isValid:a}),(s,o)=>(k(),M(xe,null,[o[8]||(o[8]=b("h4",{class:"text-center font-medium"},[Ze(" What type of safari are you interested in? "),b("span",{class:"text-ag-red"},"*")],-1)),b("div",I_e,[b("div",A_e,[b("button",{type:"button",class:pe(["flex w-full bg-white border rounded-[0.25rem] overflow-hidden shadow-md transition text-left focus:outline-none focus:ring-2 focus:ring-ag-red/60",i.value==="Pure safari"?"border-ag-red ring-2 ring-ag-red/40":"hover:shadow-md hover:outline-none hover:border-ag-red/60 hover:ring-2 hover:ring-ag-red/60"]),onClick:o[0]||(o[0]=l=>n("Pure safari"))},[...o[4]||(o[4]=[b("img",{src:"/img/1-Classic-safari_Imvelo_Cheetahs_and_Sally_Anne.webp",alt:"Pure safari",class:"w-1/2 object-cover"},null,-1),b("div",{class:"p-2 flex flex-col justify-center text-center"},[b("h3",{class:"font-semibold text-lg mb-2"},"Pure safari"),b("p",{class:"text-sm text-gray-600 mb-0"}," I want to spend my safari in Africaâs bushveld and forests. ")],-1)])],2),b("button",{type:"button",class:
737pe(["flex w-full bg-white border rounded-[0.25rem] overflow-hidden shadow-md transition text-left focus:outline-none focus:ring-2 focus:ring-ag-red/60",i.value==="Safari with extras"?"border-ag-red ring-2 ring-ag-red/40":"hover:shadow-md hover:outline-none hover:border-ag-red/60 hover:ring-2 hover:ring-ag-red/60"]),onClick:o[1]||(o[1]=l=>n("Safari with extras"))},[...o[5]||(o[5]=[b("img",{src:"/img/2-Safari-plus_Cape_Town_South_Africa.webp",alt:"Safari with extras",class:"w-1/2 object-cover"},null,-1),b("div",{class:"p-2 flex flex-col justify-center text-center"},[b("h3",{class:"font-semibold text-lg mb-2"},"Safari with extras"),b("p",{class:"text-sm text-gray-600 mb-0"}," On safari, plus visit a city like Cape Town or a destination like Victoria Falls. ")],-1)])],2),b("button",{type:"button",class:pe(["flex w-full bg-white border rounded-[0.25rem] overflow-hidden shadow-md transition text-left focus:outline-none focus:ring-2 focus:ring-ag-red/60",i.value==="Bush and beach"?"border-ag-red ring-2 ring-ag-red/40":"hover:shadow-md hover:outline-none hover:border-ag-red/60 hover:ring-2 hover:ring-ag-red/60"]),onClick:o[2]||(o[2]=l=>n("Bush and beach"))},[...o[6]||(o[6]=[b("img",{src:"/img/3-Bush-and-beach_Zanzibar_Pemba_Mafia_islands.webp",alt:"Bush & beach",class:"w-1/2 object-cover"},null,-1),b("div",{class:"p-2 flex flex-col justify-center text-center"},[b("h3",{class:"font-semibold text-lg mb-2"},"Bush & beach"),b("p",{class:"text-sm text-gray-600 mb-0"}," On safari, followed by some toes-in-the-sand time. ")],-1)])],2),b("button",{type:"button",class:pe(["flex w-full bg-white border rounded-[0.25rem] overflow-hidden shadow-md transition text-left focus:outline-none focus:ring-2 focus:ring-ag-red/60",i.value==="Open to ideas"?"border-ag-red ring-2 ring-ag-red/40":"hover:shadow-md hover:outline-none hover:border-ag-red/60 hover:ring-2 hover:ring-ag-red/60"]),onClick:o[3]||(o[3]=l=>n("Open to ideas"))},[...o[7]||(o[7]=[b("img",{src:"/img/4-Open-to-ideas_Bob_Ditty.webp",alt:"Open to ideas",class:"w-1/2 object-cover"},null,-1),b("div",{class:"p-2 flex flex-col justify-center text-center"},[b("h3",{class:"font-semibold text-lg mb-2"},"Open to ideas"),b("p",{class:"text-sm text-gray-600 mb-0"}," Iâm undecided and happy for an Africa Geographic safari expert to suggest ideas. ")],-1)])],2)])])],64))}},R_e={class:"max-w-[48rem] mx-auto space-y-6"},O_e={class:"grid grid-cols-2 md:grid-cols-4 gap-3"},L_e=["onClick"],F_e={__name:"Interests",setup(e){const t=os(),r=[{value:"Great Wildebeest Migration",label:"Great Migration"},{value:"Big 5",label:"Big 5"},{value:"Beach Safari",label:"Bush & beach"},{value:"Luxury safari",label:"Luxury safari"},{value:"Family safari",label:"Family safari"},{value:"Honeymoon",label:"Honeymoon"},{value:"Gorilla Trekking",label:"Gorilla trekking"},{value:"Chimpanzee Trekking",label:"Chimpanzee trekking"},{value:"Women on safari",label:"Women on safari"},{value:"Photographer-guided",label:"Photographer-guided"},{value:"Malaria-free",label:"Malaria-free"},{value:"Walking safari",label:"Walking safari"},{value:"Bird-watching",label:"Bird-watching"},{value:"Art safari",label:"Art safari"},{value:"Cultural encounters",label:"Cultural encounters"},{value:"Other",label:"Other"}];function i(a){n(a)?t.enquiryForm.which_experiences_are_you_interested_in___hubspot_=t.enquiryForm.which_experiences_are_you_interested_in___hubspot_.filter(s=>s!==a):t.enquiryForm.which_experiences_are_you_interested_in___hubspot_=[...t.enquiryForm.which_experiences_are_you_interested_in___hubspot_,a]}function n(a){return t.enquiryForm.which_experiences_are_you_interested_in___hubspot_.includes(a)}return(a,s)=>(k(),M("div",R_e,[s[0]||(s[0]=b("div",{class:"text-center space-y-2"},[b("h4",{class:"font-medium"}," Are there any experiences you are interested in? "),b("p",{class:"text-gray-500"}," Do you have experiences in mind? Share them with us, and we'll help craft the perfect safari. "),b("p",{class:"text-gray-500"},"Select as many as you like.")],-1)),b("div",O_e,[(k(),M(xe,null,Me(r,o=>
737b("button",{key:o.value,type:"button",class:pe(["enquiry-btn",n(o.value)?"enquiry-btn--selected":"enquiry-btn--unselected"]),onClick:l=>i(o.value)},Q(o.label),11,L_e)),64))])]))}},z_e={class:"max-w-[48rem] mx-auto space-y-6"},N_e={class:"flex flex-wrap items-center justify-center gap-3"},B_e=["onClick"],j_e={key:0,class:"text-gray-500 text-center"},U_e={key:1},V_e={class:"grid grid-cols-2 md:grid-cols-4 gap-4"},q_e=["onClick"],G_e={key:2},H_e={class:"grid grid-cols-2 md:grid-cols-4 gap-4"},Y_e=["onClick"],W_e={__name:"Travel",setup(e){const t=os(),r=[{value:"No",label:"No, help me decide"},{value:"Yes",label:"By country"},{value:"Destinations",label:"By destination"}],i=[{value:"Botswana",label:"Botswana"},{value:"Congo",label:"Congo"},{value:"DRC",label:"DRC"},{value:"Ethiopia",label:"Ethiopia"},{value:"Kenya",label:"Kenya"},{value:"Madagascar",label:"Madagascar"},{value:"Malawi",label:"Malawi"},{value:"Mozambique",label:"Mozambique"},{value:"Namibia",label:"Namibia"},{value:"Rwanda",label:"Rwanda"},{value:"South Africa",label:"South Africa"},{value:"Tanzania",label:"Tanzania"},{value:"Uganda",label:"Uganda"},{value:"Zambia",label:"Zambia"},{value:"Zanzibar",label:"Zanzibar"},{value:"Zimbabwe",label:"Zimbabwe"}],n=[{value:"Okavango Delta",label:"Okavango Delta"},{value:"Victoria Falls",label:"Victoria Falls"},{value:"Maasai Mara",label:"Maasai Mara"},{value:"Greater Kruger",label:"Kruger"},{value:"Chobe",label:"Chobe"},{value:"Cape Town",label:"Cape Town"},{value:"Serengeti",label:"Serengeti"},{value:"Volcanoes National Park",label:"Volcanoes"},{value:"Odzala-Kokoua",label:"Odzala-Kokoua"},{value:"Mana Pools",label:"Mana Pools"},{value:"Zanzibar",label:"Zanzibar"},{value:"Akagera",label:"Akagera"},{value:"Amboseli",label:"Amboseli"},{value:"Bazaruto",label:"Bazaruto"},{value:"South Luangwa",label:"South Luangwa"},{value:"Bwindi",label:"Bwindi"}],a=H({get(){return t.enquiryForm.do_you_know_where_you_want_to_travel___hubspot_},set(p){t.enquiryForm.do_you_know_where_you_want_to_travel___hubspot_=p}}),s=H({get(){return t.enquiryForm.which_countries_would_you_like_to_visit_on_this_trip___hubspot_||[]},set(p){t.enquiryForm.which_countries_would_you_like_to_visit_on_this_trip___hubspot_=p}}),o=H({get(){return t.enquiryForm.travel_destination__hubspot_form_},set(p){t.enquiryForm.travel_destination__hubspot_form_=p}});function l(p){a.value=p}function u(p){h(p)?s.value=s.value.filter(m=>m!==p):s.value=[...s.value,p]}function c(p){f(p)?o.value=o.value.filter(m=>m!==p):o.value=[...o.value,p]}function d(p){return a.value===p}function h(p){return s.value.includes(p)}function f(p){return o.value.includes(p)}return(p,m)=>(k(),M("div",z_e,[m[0]||(m[0]=b("div",{class:"text-center space-y-2"},[b("h4",{class:"font-medium"},[Ze(" Do you know where you want to travel? "),b("span",{class:"text-ag-red"},"*")]),b("p",{class:"text-gray-500"},[Ze(" Africa is our backyard - its landscapes, wildlife, and rhythms are familiar to us."),b("br"),Ze(" Pick a destination below, or let your Safari Expert recommend one. ")])],-1)),b("div",N_e,[(k(),M(xe,null,Me(r,g=>b("button",{type:"button",class:pe(["enquiry-btn w-[200px]",d(g.value)?"enquiry-btn--selected":""]),onClick:v=>l(g.value)},Q(g.label),11,B_e)),64))]),a.value==="Yes"||a.value==="Destinations"?(k(),M("p",j_e," If you have a place in mind, select one or more below. ")):X("",!0),a.value==="Yes"?(k(),M("div",U_e,[b("div",V_e,[(k(),M(xe,null,Me(i,g=>b("button",{type:"button",class:pe(["enquiry-btn",h(g.value)?"enquiry-btn--selected":""]),onClick:v=>u(g.value)},Q(g.label),11,q_e)),64))])])):X("",!0),a.value==="Destinations"?(k(),M("div",G_e,[b("div",H_e,[(k(),M(xe,null,Me(n,g=>b("button",{type:"button",class:pe(["enquiry-btn",f(g.value)?"enquiry-btn--selected":""]),onClick:v=>c(g.value)},Q(g.label),11,Y_e)),64))])])):X("",!0)]))}},Z_e={class:"max-w-[48rem] mx-auto space-y-6"},K_e={class:"text-center space-y-2"},X_e={class:"flex flex-wrap items-center justify-center gap-3"},J_e={key:0},Q_e={class:"flex items-center justify-center gap-4 mb-2"},eye=["disabled"],tye={class:"text-md"},rye={class:"flex items-center justify-center gap-3 mb-4"},iye={class:"grid grid-cols-2 md:grid-cols-4 gap-4"},nye=["disabled","onClick"],aye={class:"mt-4"},sye={class:"flex flex-wrap items-center justify-center gap-4"},oye={key:1},lye={class:"mt-6"},uye={key:0,class:"mt-4 text-center"},cye={__name:"Dates",setup(e){const t=os(),r=se(2);function i(){r.value=window.innerWidth<768?1:2}or(()=>{i(),window.addEventListener("resize",i)}),ss(()=>{window.removeEventListener("resize",i)});const n=new Date,a=n.getFullYear(),s=n.getMonth(),o=se(a),l=se(null),u=se(null),c=new Date;c.setDate(c.getDate()+1);const d={highlight:{start:{fillMode:"outline",style:{backgroundColor:"#dc2626",borderColor:"#dc2626"},contentStyle:{color:"white"}},base:{fillMode:"light",style:{backgroundColor:"#fee2e2",opacity:1}},end:{fillMode:"outline",style:{backgroundColor:"#dc2626",borderColor:"#dc2626"},contentStyle:{color:"white"}}}},h=["January","February","March","April","May","June","July","August","September","October","November","December"],f=H({get(){return t.enquiryForm.do_you_know_when_you_would_like_to_travel___hubspot_},set(P){t.enquiryForm.do_you_know_when_you_would_like_to_travel___hubspot_=P}});t.enquiryForm.do_you_know_when_you_would_like_to_travel___hubspot_==="I have an idea"&&t.enquiryForm.what_year_would_you_like_to_travel___hubspot_!==null&&t.enquiryForm.what_month_would_you_like_to_travel___hubspot_!==null?(o.value=t.enquiryForm.what_year_would_you_like_to_travel___hubspot_,l.value=t.enquiryForm.what_month_would_you_like_to_travel___hubspot_):t.enquiryForm.do_you_know_when_you_would_like_to_travel___hubspot_==="I have exact dates"&&t.enquiryForm.arrival_date__hubspot_&&t.enquiryForm.departure_date__hubspot_&&(u.value={start:new Date(t.enquiryForm.arrival_date__hubspot_),end:new Date(t.enquiryForm.departure_date__hubspot_)});const p=H({get(){return t.enquiryForm.as_an_estimate__how_many_days_would_you_like_to_travel___hubspot_},set(P){t.enquiryForm.what_is_your_group_total_budget_in_usd___hubspot_=null,t.enquiryForm.as_an_estimate__how_many_days_would_you_like_to_travel___hubspot_=P}});function m(P){f.value=P,P==="I have an idea"?u.value=null:P==="I have exact dates"&&(l.value=null)}function g(P){if(P&&P.start&&P.end){const T=new Date(P.start),D=new Date(P.end);D<=T&&(D.setDate(T.getDate()+1),u.value={start:T,end:D}),t.enquiryForm.do_you_know_when_you_would_like_to_travel___hubspot_="I have exact dates";const A=R=>`${R.getFullYear()}
737-${String(R.getMonth()+1).padStart(2,"0")}-${String(R.getDate()).padStart(2,"0")}`;t.enquiryForm.arrival_date__hubspot_=A(T),t.enquiryForm.departure_date__hubspot_=A(D);const z=Math.ceil((D-T)/(1e3*60*60*24));p.value=z}}function v(){u.value=null,f.value="exact",t.enquiryForm.arrival_date__hubspot_=null,t.enquiryForm.departure_date__hubspot_=null}function x(P){return f.value===P}function _(){t.enquiryForm.what_year_would_you_like_to_travel___hubspot_=o.value,t.enquiryForm.what_month_would_you_like_to_travel___hubspot_=l.value}function y(){if(l.value===null||l.value==="Any month")return;const P=h.indexOf(l.value);P!==-1&&S(P)&&(l.value=null)}function w(){o.value+=1,_()}function $(){o.value>a&&(o.value-=1,y(),_())}function S(P){return o.value===a?P<s:o.value<a}function E(P){S(P)||(l.value=P,t.enquiryForm.do_you_know_when_you_would_like_to_travel___hubspot_="I have an idea",t.enquiryForm.what_year_would_you_like_to_travel___hubspot_=o.value,t.enquiryForm.what_month_would_you_like_to_travel___hubspot_=P)}function C(P){p.value=P}function I(P){return p.value===P}return(P,T)=>{const D=qr("v-date-picker");return k(),M("div",Z_e,[b("div",K_e,[T[11]||(T[11]=b("h4",{class:"font-medium"},[Ze(" Do you know when you would like to travel? "),b("span",{class:"text-ag-red"},"*")],-1)),b("div",X_e,[b("button",{type:"button",class:pe(["enquiry-btn w-[200px]",x("I have an idea")?"enquiry-btn--selected":""]),onClick:T[0]||(T[0]=A=>m("I have an idea"))}," I have an idea ",2),b("button",{type:"button",class:pe(["enquiry-btn w-[200px]",x("I have exact dates")?"enquiry-btn--selected":""]),onClick:T[1]||(T[1]=A=>m("I have exact dates"))}," I have exact dates ",2)]),f.value==="I have an idea"?(k(),M("div",J_e,[b("div",Q_e,[b("button",{type:"button prev-year-btn",class:pe(["px-3 py-2 text-lg font-medium",o.value<=le(a)?"opacity-50 cursor-not-allowed":""]),disabled:o.value<=le(a),onClick:$},[...T[8]||(T[8]=[b("svg",{class:"w-6 h-6 text-gray-800","aria-hidden":"true",xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",fill:"none",viewBox:"0 0 24 24"},[b("path",{stroke:"currentColor","stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"m15 19-7-7 7-7"})],-1)])],10,eye),b("span",tye,Q(o.value),1),b("button",{type:"button",class:"px-3 py-2 text-lg font-medium",onClick:w},[...T[9]||(T[9]=[b("svg",{class:"w-6 h-6 text-gray-800","aria-hidden":"true",xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",fill:"none",viewBox:"0 0 24 24"},[b("path",{stroke:"currentColor","stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"m9 5 7 7-7 7"})],-1)])])]),b("div",rye,[b("button",{type:"button",class:pe(["enquiry-btn w-[120px]",l.value==="Any month"?"enquiry-btn--selected":""]),onClick:T[2]||(T[2]=A=>E("Any month"))}," Any month ",2)]),b("div",iye,[(k(),M(xe,null,Me(h,(A,z)=>b("button",{key:z,type:"button",class:pe(["enquiry-btn",l.value===A?"enquiry-btn--selected":""]),disabled:S(z),onClick:R=>E(A)},Q(A),11,nye)),64))]),b("div",aye,[T[10]||(T[10]=b("label",{for:"days",class:"block text-md font-medium mb-2 text-gray-700 text-[18px]"},[Ze(" How many days would you like to stay? "),b("span",{class:"text-ag-red"},"*")],-1)),b("div",sye,[b("button",{type:"button",class:pe(["enquiry-btn w-[120px]",I(7)?"enquiry-btn--selected":""]),onClick:T[3]||(T[3]=A=>C(7))}," 7 - 10 ",2),b("button",{type:"button",class:pe(["enquiry-btn w-[120px]",I(10)?"enquiry-btn--selected":""]),onClick:T[4]||(T[4]=A=>C(10))}," 10 - 14 ",2),b("button",{type:"button",class:pe(["enquiry-btn w-[120px]",I(14)?"enquiry-btn--selected":""]),onClick:T[5]||(T[5]=A=>C(14))}," 14+ ",2),b("button",{type:"button",class:pe(["enquiry-btn w-[120px]",I(1)?"enquiry-btn--selected":""]),onClick:T[6]||(T[6]=A=>C(1))}," Unsure ",2)])])])):X("",!0),f.value==="I have exact dates"?(k(),M("div",oye,[b("div",lye,[be(D,{modelValue:u.value,"onUpdate:modelValue":[T[7]||(T[7]=A=>u.value=A),g],modelModifiers:{range:!0},"is-expanded":"",columns:r.value,"min-date":le(c),"select-attribute":d,"drag-attribute":d},null,8,["modelValue","columns","min-date"]),u.value&&u.value.start&&u.value.end?(k(),M("div",uye,[b("button",{type:"button",class:"text-sm text-gray-600 underline",onClick:v}," Clear Dates ")])):X("",!0)])])):X("",!0)])])}}},dye=Yt(cye,[["__scopeId","data-v-67e719fa"]]),hye={class:"max-w-4xl mx-auto
737space-y-6"},fye={class:"grid grid-cols-2 md:grid-cols-4 gap-4"},pye={key:0,class:"mt-6 space-y-4"},mye={class:"grid grid-cols-1 md:grid-cols-3 gap-4"},gye=["value"],_ye=["value"],yye=["value"],vye={__name:"Participants",setup(e){const t=os(),r=H({get(){return t.enquiryForm.who_will_you_be_travelling_with___hubspot_},set(u){l(),t.enquiryForm.who_will_you_be_travelling_with___hubspot_=u}}),i=H({get(){return t.enquiryForm.how_many_people_are_travelling___hubspot_||1},set(u){l(),t.enquiryForm.how_many_people_are_travelling___hubspot_=u}}),n=H({get(){return t.enquiryForm.how_many_children_12_years_of_age_and_under_are_travelling___hubspot_||0},set(u){l(),t.enquiryForm.how_many_children_12_years_of_age_and_under_are_travelling___hubspot_=u}}),a=H({get(){return t.enquiryForm.how_many_infants___hubspot_||0},set(u){t.enquiryForm.how_many_infants___hubspot_=u}});function s(u){r.value=u,l(),u==="I travel solo"?(i.value=1,n.value=0,a.value=0):u==="My partner"&&(i.value=2,n.value=0,a.value=0)}function o(u){return r.value===u}function l(){t.enquiryForm.what_is_your_group_total_budget_in_usd___hubspot_=null}return(u,c)=>(k(),M("div",hye,[c[13]||(c[13]=b("div",{class:"text-center space-y-2"},[b("h4",{class:"font-medium"},[Ze(" Who will you be travelling with? "),b("span",{class:"text-ag-red"},"*")]),b("p",{class:"text-gray-500"}," This helps us find availability for your stay. ")],-1)),b("div",fye,[b("button",{type:"button",class:pe(["enquiry-btn",o("I travel solo")?"enquiry-btn--selected":""]),onClick:c[0]||(c[0]=d=>s("I travel solo"))}," Solo ",2),b("button",{type:"button",class:pe(["enquiry-btn",o("My partner")?"enquiry-btn--selected":""]),onClick:c[1]||(c[1]=d=>s("My partner"))}," Partner ",2),b("button",{type:"button",class:pe(["enquiry-btn",o("My family")?"enquiry-btn--selected":""]),onClick:c[2]||(c[2]=d=>s("My family"))}," Family ",2),b("button",{type:"button",class:pe(["enquiry-btn",o("My friends")?"enquiry-btn--selected":""]),onClick:c[3]||(c[3]=d=>s("My friends"))}," Friends ",2)]),o("My family")||o("My friends")?(k(),M("div",pye,[b("div",mye,[b("div",null,[c[7]||(c[7]=b("label",{for:"adults",class:"block text-sm font-medium text-gray-700 mb-2 text-center"},[Ze("How many adults are travelling? "),b("span",{class:"text-ag-red"},"*")],-1)),c[8]||(c[8]=b("p",{class:"text-gray-500 mb-2 text-center text-xs"},"13 years of age and older",-1)),it(b("select",{id:"adults","onUpdate:modelValue":c[4]||(c[4]=d=>i.value=d),class:"enquiry-btn w-full appearance-none pr-10 custom-select-arrow"},[(k(),M(xe,null,Me(10,d=>b("option",{key:d,value:d},Q(d),9,gye)),64))],512),[[Yl,i.value,void 0,{number:!0}]])]),b("div",null,[c[9]||(c[9]=b("label",{for:"children",class:"block text-sm font-medium text-gray-700 mb-2 text-center"},"How many children are travelling?",-1)),c[10]||(c[10]=b("p",{class:"text-gray-500 mb-2 text-center text-xs"},"2 - 12 years of age",-1)),it(b("select",{id:"children","onUpdate:modelValue":c[5]||(c[5]=d=>n.value=d),class:"enquiry-btn w-full custom-select-arrow appearance-none pr-10"},[(k(),M(xe,null,Me(10,d=>b("option",{key:d,value:d-1},Q(d-1),9,_ye)),64))],512),[[Yl,n.value,void 0,{number:!0}]])]),b("div",null,[c[11]||(c[11]=b("label",{for:"infants",class:"block text-sm font-medium text-gray-700 mb-2 text-center"},"How many infants are travelling?",-1)),c[12]||(c[12]=b("p",{class:"text-gray-500 mb-2 text-center text-xs"},"0 - 1 year of age",-1)),it(b("select",{id:"infants","onUpdate:modelValue":c[6]||(c[6]=d=>a.value=d),class:"enquiry-btn w-full custom-select-arrow appearance-none pr-10"},[(k(),M(xe,null,Me(10,d=>b("option",{key:d,value:d-1},Q(d-1),9,yye)),64))],512),[[Yl,a.value,void 0,{number:!0}]])])])])):X("",!0)]))}},bye=Yt(vye,[["__scopeId","data-v-8e8e3ed2"]]),xye=["src","alt"],wye=["onClick"],$ye={class:"flex-1 flex items-center gap-3"},Sye=["src","alt"],Tye={class:"text-xs leading-4 tracking-normal"},Cye={class:"text-xs leading-4 tracking-normal"},kye={__name:"BudgetCurrencySelector",props:{rates:{type:Object,required:!1},options:{type:Array,required:!1,default:()=>[]},variation:{type:String,required:!1,default:"default"}},setup(e){const t=P$(),r=e,i=se(null),n=se(!1),a=H(()=>r.variation||"default"),s=()=>{n.value=!n.value},o=d=>{r.rates&&r.rates[d]!==void 0&&r.rates[d],t.setSelectedCurrency(d)},l=d=>{o(d),n.value=!1},u=d=>{t.setSelectedCurrency(d.detail.message)},c=d=>{i.value&&!i.value.contains(d.target)&&(n.value=!1)};return or(()=>{window.addEventListener("currencyUpdated",u),window.addEventListener("click",c)}),ra(()=>{window.removeEventListener("currencyUpdated",u),window.removeEventListener("click",c)}),(d,h)=>{var f;return e.options&&e.options.length>0?(k(),M("div",{key:0,class:"relative z-20 flex items-center justify-center mb-3",ref_key:"currencyDropdown",ref:i},[b("div",{onClick:s,class:pe(["cursor-pointer flex items-center gap-2 p-1 pb-2 border border-gray-200 rounded-md pl-4 pr-2",a.value==="filter"?"pr-0":"w-24"])},[b("img",{src:(f=e.options.find(p=>
737(p==null?void 0:p.code)===le(t).selectedCurrency))==null?void 0:f.icon,alt:le(t).selectedCurrency,class:"rounded-full object-cover block h-4 w-4 bg-gray-100"},null,8,xye),b("span",null,Q(le(t).selectedCurrency),1),(k(),M("svg",{class:"mr-1 w-4 h-4",fill:"none",stroke:"currentColor",viewBox:"0 0 24 24",style:Qt(n.value?"transform: rotate(180deg)":"")},[...h[1]||(h[1]=[b("path",{"stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"M19 9l-7 7-7-7"},null,-1)])],4))],2),n.value?(k(),M("ul",{key:0,class:pe(["absolute top-full mt-1 bg-white border border-gray-200 rounded shadow-lg w-64 z-20",a.value==="filter"?"":"-left-20 md:left-auto"]),onBlur:h[0]||(h[0]=p=>n.value=!1)},[(k(!0),M(xe,null,Me(e.options,p=>(k(),M("li",{key:p.code,onClick:m=>l(p.code),class:pe(["py-2 px-3 text-black cursor-pointer hover:bg-gray-100 border-b border-gray-200 flex items-center gap-5 last:border-none",{"bg-gray-200":p.code===le(t).selectedCurrency}])},[b("div",$ye,[b("img",{src:p.icon,alt:p.code,class:"object-cover rounded-full block h-5 w-5 bg-gray-100"},null,8,Sye),b("span",Tye,Q(p.label),1)]),b("span",Cye,Q(p.code),1)],10,wye))),128))],34)):X("",!0)],512)):X("",!0)}}},Eye={class:"max-w-5xl mx-auto"},Pye={class:"grid gap-4 md:grid-cols-3"},Mye=["value","checked","onChange"],Iye={class:"flex items-center gap-3"},Aye={class:"min-w-0 flex-1"},Dye={class:"block font-bold leading-tight"},Rye={class:"md:hidden"},Oye={class:"hidden md:inline"},Lye={key:0,class:"font-normal text-[12px] text-gray-500"},Fye={class:"overflow-hidden"},zye={class:"mt-3 pt-3 border-t border-gray-100"},Nye={class:"italic text-gray-600"},Bye={class:"mt-3 space-y-2"},jye={class:"hidden md:block rounded-lg border border-gray-200 bg-gray-50 p-6 md:col-span-2"},Uye={class:"flex flex-wrap items-baseline justify-between gap-x-4 gap-y-1"},Vye={class:"text-xl font-bold"},qye={class:"whitespace-nowrap"},Gye={class:"text-xl font-bold text-ag-red"},Hye={class:"mt-2 italic text-gray-600"},Yye={class:"mt-3 grid gap-x-8 gap-y-2 lg:grid-cols-2"},Wye={key:"empty",class:"flex h-full items-center justify-center text-center text-gray-400"},Zye=1200,Kye="luxury",Xye=.5,Jye=0,Qye={__name:"Budget",props:{budgetValueRequired:{type:Boolean,required:!1,default:!1}},setup(e){const t=os(),r=P$(),i=[{key:"comfort",label:"Comfort",title:"Comfort safari",min:5e3,max:1e4,value:7500,tagline:"Comfortable, no-frills lodges and honest bush time â big adventure, small price.",includes:["Shared game drives","8â10 guests per vehicle on game drives","Tented camps & lodges","Road transfers between parks","Meals included, drinks extra","Well-known reserves"],icon:"/img/beer-mug-empty-thin-full.svg"},{key:"mid-range",label:"Mid-range",title:"Mid-range safari",min:1e4,max:15e3,value:12500,tagline:"The sweet spot: good guides, great beds, and enough space to feel unhurried.",includes:["Shared game drives","6â8 guests per vehicle on game drives","Mid-range lodges & camps","Mix of road & light-air transfers","All meals & house drinks","Two or three regions in one trip"],icon:"/img/wine-glass-empty-thin-full.svg"},{key:"luxury",label:"Luxury",title:"Luxury safari",min:15e3,max:25e3,value:2e4,tagline:"Private guides, unhurried mornings, and lodges you won't want to leave.",includes:["Shared game drives","Max 6 guests per vehicle on game drives","In some cases, private vehicles","Premium lodges and camps","Light-aircraft transfers","All meals, drinks & laundry","Private conservancies, few vehicles"],icon:"/img/champagne-glass-thin-full.svg"},{key:"ultra-luxury",label:"Ultra-luxury",title:"Ultra-luxury safari",min:25e3,plus:!0,value:25e3,tagline:"Exclusive-use lodges, helicopters and a trip built entirely around you.",includes:["Exclusive use villa","Premium conservancies, few vehicles","Dedicated guide, chef & host","Helicopter & balloon experiences","Conservation & research access","Fully bespoke, day by day"],icon:"/img/martini-glass-citrus-thin-full.svg"}],n=H(()=>{const f=t.enquiryForm,p=f.how_many_people_are_travelling___hubspot_||1,m=f.how_many_children_12_years_of_age_and_under_are_travelling___hubspot_||0,g=f.how_many_infants___hubspot_||0;return p+m*Xye+g*Jye}),a=f=>Math.round(f.value*n.value),o=se((()=>{var m;const f=t.enquiryForm.what_is_your_group_total_budget_in_usd___hubspot_;if(f==null)return null;const p=f/(n.value||1);return((m=i.find(g=>Math.abs(g.value-p)<1))==null?void 0:m.key)??null})()??Kye);t.enquiryForm.budget_type=o.value;const l=H(()=>i.find(f=>f.key===o.value)??null);function u(f){o.value=f.key,t.enquiryForm.budget_type=f.key,t.enquiryForm.what_is_your_group_total_budget_in_usd___hubspot_=a(f)}l.value&&t.enquiryForm.what_is_your_group_total_budget_in_usd___hubspot_==null&&u(l.value),tt(n,()=>{l.value&&(t.enquiryForm.what_is_your_group_total_budget_in_usd___hubspot_=a(l.value))});function c(f){const p=r.getSelectedCurrency||1,m=r.activeCurrencyCode||r.selectedCurrency||"USD";return new Intl.NumberFormat("en-US",{style:"currency",currency:m,minimumFractionDigits:0,maximumFractionDigits:0}).format(f*p)}function d(f){return f.plus?`${c(f.min)}+`:`${c(f.min)} â ${c(f.max)}`}const h=se(!1);return tt(()=>t.budgetValueRequired,f=>{f&&(h.value=!0,setTimeout(()=>{t.budgetValueRequired=!1,h.value=!1},Zye))}),(f,p)=>(k(),M("div",Eye,[p[8]||(p[8]=b("div",{class:"text-center"},[b("h4",{class:"font-medium"},[Ze(" What is your budget per person? "),b("span",{class:"text-ag-red"}
737,"*")]),b("p",{class:"text-gray-500"},[Ze(" The price below is "),b("b",null,"per person"),Ze(" for this trip, including your accommodation, activities, and local travel, but excludes the costs of your international flights. ")])],-1)),be(kye,{rates:le(r).currencyRates,options:le(r).currencySelectorOptions||{},variation:"filter"},null,8,["rates","options"]),b("div",Pye,[b("fieldset",{class:pe(["flex flex-col gap-3",{"budget-tiers-required":h.value}])},[p[3]||(p[3]=b("legend",{class:"sr-only"},"Budget per person",-1)),(k(),M(xe,null,Me(i,m=>b("label",{key:m.key,class:pe(["block rounded-lg border p-4 cursor-pointer transition-all duration-200 ease-in-out",m.key===o.value?"border-ag-red bg-white shadow-sm md:py-6":"border-gray-200 bg-gray-50 hover:border-gray-300"])},[b("input",{type:"radio",name:"budget_per_person",class:"sr-only",value:m.value,checked:m.key===o.value,onChange:g=>u(m)},null,40,Mye),b("span",Iye,[b("span",{class:pe(["flex h-10 w-10 shrink-0 items-center justify-center rounded-full transition-colors duration-200",m.key===o.value?"bg-ag-red text-[#ffffff]":"bg-gray-200 text-[#3d3d3d]"]),"aria-hidden":"true"},[b("span",{class:"budget-tier-icon h-7 w-7",style:Qt({"--tier-icon":`url('${m.icon}')`})},null,4)],2),b("span",Aye,[b("span",Dye,[b("span",Rye,Q(m.key===o.value?m.title:m.label),1),b("span",Oye,Q(m.label),1)]),b("span",{class:pe(["block leading-tight transition-colors duration-200",m.key===o.value?"font-bold text-ag-red":"text-gray-500"])},[Ze(Q(d(m)),1),m.key===o.value?(k(),M("span",Lye," per person")):X("",!0)],2)]),b("span",{class:pe(["flex h-6 w-6 shrink-0 items-center justify-center rounded-full border text-white transition-colors duration-200",m.key===o.value?"border-ag-red bg-ag-red":"border-gray-300 bg-white"]),"aria-hidden":"true"},[(k(),M("svg",{viewBox:"0 0 24 24",class:pe(["h-3.5 w-3.5 transition-opacity duration-200",m.key===o.value?"opacity-100":"opacity-0"]),fill:"none",stroke:"currentColor","stroke-width":"3","stroke-linecap":"round","stroke-linejoin":"round"},[...p[0]||(p[0]=[b("path",{d:"m5 13 4 4L19 7"},null,-1)])],2))],2)]),b("div",{class:pe(["grid md:hidden transition-[grid-template-rows] duration-200 ease-in-out",m.key===o.value?"grid-rows-[1fr]":"grid-rows-[0fr]"])},[b("div",Fye,[b("div",zye,[b("p",Nye,Q(m.tagline),1),p[2]||(p[2]=b("p",{class:"mt-4 text-xs font-[500] uppercase tracking-wide text-gray-400"},"What's included",-1)),b("ul",Bye,[(k(!0),M(xe,null,Me(m.includes,g=>(k(),M("li",{key:g,class:"flex gap-2 text-[15px] font-light"},[p[1]||(p[1]=b("span",{class:"mt-2 h-1.5 w-1.5 shrink-0 rounded-full bg-ag-red","aria-hidden":"true"},null,-1)),b("span",null,Q(g),1)]))),128))])])])],2)],2)),64))],2),b("div",jye,[be(Ym,{name:"budget-pane",mode:"out-in"},{default:_t(()=>[l.value?(k(),M("div",{key:l.value.key},[b("div",Uye,[b("h5",Vye,Q(l.value.title),1),b("p",qye,[b("span",Gye,Q(d(l.value)),1),p[4]||(p[4]=b("span",{class:"text-sm text-gray-500"}," per person",-1))])]),b("p",Hye,Q(l.value.tagline),1),p[6]||(p[6]=b("hr",{class:"my-4 border-gray-200"},null,-1)),p[7]||(p[7]=b("p",{class:"text-xs font-bold uppercase tracking-wide text-gray-400"},"What's included",-1)),b("ul",Yye,[(k(!0),M(xe,null,Me(l.value.includes,m=>(k(),M("li",{key:m,class:"flex gap-2 text-[15px] font-light"},[p[5]||(p[5]=b("span",{class:"mt-2 h-1.5 w-1.5 shrink-0 rounded-full bg-ag-red","aria-hidden":"true"},null,-1)),b("span",null,Q(m),1)]))),128))])])):(k(),M("p",Wye," Select a budget range to see what's included. "))]),_:1})])])]))}},e1e=Yt(Qye,[["__scopeId","data-v-809bde20"]]),t1e={class:"max-w-4xl mx-auto space-y-6"},r1e={class:"space-y-4"},i1e={class:"grid md:grid-cols-2 gap-4 text-[16px]"},n1e=["disabled"],a1e=["disabled"],s1e={class:"grid md:grid-cols-2 gap-4"},o1e=["disabled"],l1e={key:0,class:"mt-1 text-sm text-red-600"},u1e={class:"block font-medium mb-1",for:"phone"},c1e={key:0,class:"text-ag-red"},d1e={class:"mt-1 text-sm text-red-600 min-h-[20px]"},h1e={key:0},f1e={key:1},p1e={class:"pt-12"},m1e=["disabled"],g1e=["disabled"],_1e=["disabled"],y1e=["disabled"],v1e={__name:"Contact",emits:["validation-change"],setup(e,{emit:t}){const r=t,i=os(),n=se(!0),a=H({get(){return i.enquiryForm.firstname||""},set(x){i.enquiryForm.firstname=x}}),s=H({get(){return i.enquiryForm.lastname||""},set(x){i.enquiryForm.lastname=x}}),o=H({get(){return i.enquiryForm.email||""},set(x){i.enquiryForm.email=x}}),l=H(()=>{const x=o.value;return x?/^[^\s@]+@[^\s@]+\.[^\s@]+$/.test(x):!0}),u=H({get(){return i.enquiryForm.phone||""},set(x){i.enquiryForm.phone=x}}),c=H(()=>{const x=u.value;if(!x)return!0;
737if(n.value===!1)return!1;const _=x.replace(/\D/g,"");return _.length>=7&&_.length<=15});function d(x){n.value=x.valid}const h=H({get(){const x=i.enquiryForm.preferred_contact_options||"";return Array.isArray(x)?x:typeof x=="string"&&x.includes(",")?x.split(",").map(_=>_.trim()).filter(_=>_):x?[x]:[]},set(x){i.enquiryForm.preferred_contact_options=x}});function f(x){const _=h.value;if(Array.isArray(_)){const y=_.indexOf(x);y>-1?_.splice(y,1):_.push(x),h.value=_}else h.value=[x]}function p(x){const _=h.value;return Array.isArray(_)?_.includes(x):_===x}const m=H(()=>p("Phone call")||p("Whatsapp")),g=H(()=>a.value!==""&&s.value!==""&&o.value!==""&&l.value&&(m.value?u.value!=="":!0)&&c.value);tt(g,x=>{r("validation-change",x)},{immediate:!0});function v(){const x=document.getElementById("first_name"),_=document.getElementById("last_name"),y=document.getElementById("email");x!=null&&x.value&&!a.value&&(a.value=x.value),_!=null&&_.value&&!s.value&&(s.value=_.value),y!=null&&y.value&&!o.value&&(o.value=y.value)}return or(()=>{v(),setTimeout(v,200),setTimeout(v,800),setTimeout(v,1500)}),(x,_)=>{const y=qr("vue-tel-input");return k(),M("div",t1e,[_[14]||(_[14]=so('<div class="text-center space-y-2" data-v-eae48f8b><h4 class="font-medium" data-v-eae48f8b> Your contact details <span class="text-ag-red" data-v-eae48f8b>*</span></h4><p class="text-gray-500" data-v-eae48f8b><img src="/img/lock-keyhole-light-full.svg" alt="Info" class="w-5 h-5 inline-block mb-1" data-v-eae48f8b> Your personal details are protected; we only use this information to contact you. </p></div>',1)),b("div",r1e,[b("div",i1e,[b("div",null,[_[8]||(_[8]=b("label",{class:"block font-medium mb-1",for:"first_name"},[Ze("First name "),b("span",{class:"text-ag-red"},"*")],-1)),it(b("input",{id:"first_name",type:"text","onUpdate:modelValue":_[0]||(_[0]=w=>a.value=w),class:"w-full px-3 py-2 border border-gray-300 rounded-lg text-[16px] focus:outline-none focus:ring-2 focus:ring-ag-red/60 focus:border-ag-red disabled:opacity-50 disabled:cursor-not-allowed",disabled:le(i).loading||le(i).success,required:""},null,8,n1e),[[ui,a.value]])]),b("div",null,[_[9]||(_[9]=b("label",{class:"block font-medium mb-1",for:"last_name"},[Ze("Last name "),b("span",{class:"text-ag-red"},"*")],-1)),it(b("input",{id:"last_name",type:"text","onUpdate:modelValue":_[1]||(_[1]=w=>s.value=w),class:"w-full px-3 py-2 border border-gray-300 rounded-lg text-[16px] focus:outline-none focus:ring-2 focus:ring-ag-red/60 focus:border-ag-red disabled:opacity-50 disabled:cursor-not-allowed",disabled:le(i).loading||le(i).success,required:""},null,8,a1e),[[ui,s.value]])])]),b("div",s1e,[b("div",null,[_[10]||(_[10]=b("label",{class:"block font-medium mb-1",for:"email"},[Ze("Email "),b("span",{class:"text-ag-red"},"*")],-1)),it(b("input",{id:"email",type:"email","onUpdate:modelValue":_[2]||(_[2]=w=>o.value=w),class:pe(["w-full px-3 py-2 border rounded-lg focus:outline-none focus:ring-2 disabled:opacity-50 disabled:cursor-not-allowed",[l.value||o.value===""?"border-gray-300 focus:ring-ag-red/60 focus:border-ag-red":"border-red-500 focus:ring-red-500/60 focus:border-red-500"]]),disabled:le(i).loading||le(i).success,required:""},null,10,o1e),[[ui,o.value]]),!l.value&&o.value!==""?(k(),M("p",l1e," Please enter a valid email address ")):X("",!0)]),b("div",{class:pe({"opacity-50 cursor-not-allowed":le(i).loading||le(i).success})},[b("label",u1e,[_[11]||(_[11]=Ze(" Phone ",-1)),_[12]||(_[12]=b("span",{class:"text-gray-500"},"(optional)",-1)),m.value?(k(),M("span",c1e,"*")):X("",!0)]),b("div",{class:pe(["vue-tel-input-wrapper",{"phone-invalid":!c.value&&u.value!==""}])},[be(y,{class:"rounded-lg",defaultCountry:"US",mode:"international",autoFormat:!0,disabled:le(i).loading||le(i).success,inputOptions:{required:m.value,disabled:le(i).loading||le(i).success},modelValue:u.value,"onUpdate:modelValue":_[3]||(_[3]=w=>u.value=w),onValidate:d},null,8,["disabled","inputOptions","modelValue"])],2),b("p",d1e,[m.value&&u.value===""?(k(),M("span",h1e,"Phone is required for your selected contact method")):!c.value&&u.value!==""?(k(),M("span",f1e,"Please enter a valid phone number")):X("",!0)])],2)]),b("div",p1e,[_[13]||(_[13]=b("label",{class:"block text-[18px] font-medium text-gray-700 text-center mb-4"},[Ze(" How should we contact you? "),b("span",{class:"text-gray-500"},"(optional)")],-1)),b("div",{class:pe(["grid grid-cols-2 md:grid-cols-4 gap-4",{"opacity-50 cursor-not-allowed":le(i).loading||le(i).success}])}
737,[b("button",{type:"button",class:pe(["enquiry-btn",p("Email")?"enquiry-btn--selected":""]),disabled:le(i).loading||le(i).success,onClick:_[4]||(_[4]=w=>f("Email"))}," Email ",10,m1e),b("button",{type:"button",class:pe(["enquiry-btn",p("Phone call")?"enquiry-btn--selected":""]),disabled:le(i).loading||le(i).success,onClick:_[5]||(_[5]=w=>f("Phone call"))}," Phone Call ",10,g1e),b("button",{type:"button",class:pe(["enquiry-btn",p("Whatsapp")?"enquiry-btn--selected":""]),disabled:le(i).loading||le(i).success,onClick:_[6]||(_[6]=w=>f("Whatsapp"))}," WhatsApp ",10,_1e),b("button",{type:"button",class:pe(["enquiry-btn",p("Video call")?"enquiry-btn--selected":""]),disabled:le(i).loading||le(i).success,onClick:_[7]||(_[7]=w=>f("Video call"))}," Video Call ",10,y1e)],2)])])])}}},b1e=Yt(v1e,[["__scopeId","data-v-eae48f8b"]]),x1e={class:"breadcrumb-container-wrapper flex flex-wrap justify-between"},w1e=["disabled"],$1e={class:"text-gray-600 font-bold inline-block mr-2",style:{"margin-top":"-2px"},"aria-hidden":"true",xmlns:"http://www.w3.org/2000/svg",width:"18",height:"18",fill:"none",viewBox:"0 0 24 24"},S1e={key:1,class:"order-1 md:order-0 nav-buttons h-4"},T1e={class:"breadcrumb-scale w-full md:w-2/3 flex flex-wrap justify-center items-center gap-[2px] mb-6 md:mb-0 md:order-1 [&>.line-left]:-mt-4"},C1e=["disabled"],k1e={class:"text-white font-bold inline-block",style:{"margin-top":"-2px"},"aria-hidden":"true",xmlns:"http://www.w3.org/2000/svg",width:"17",height:"17",fill:"none",viewBox:"0 0 24 24"},E1e=["disabled"],P1e={__name:"BreadcrumbPawPrints",props:{currentStepIndex:{type:Number,required:!0},steps:{type:Array,required:!0},loading:{type:Boolean,default:!1},canGoNext:{type:Boolean,default:!1},isFormDisabled:{type:Boolean,default:!1},goBack:{type:Function,default:()=>{}},goNext:{type:Function,default:()=>{}},submitEnquiry:{type:Function,default:()=>{}}},setup(e){const t=os(),r=e,i=se(!1);return tt(()=>[r.currentStepIndex,t.enquiryForm.what_is_your_group_total_budget_in_usd___hubspot_],([n,a])=>{var s,o;((o=(s=r.steps)==null?void 0:s[n])==null?void 0:o.id)==="budget"&&a==null?i.value=!0:i.value=!1}),(n,a)=>(k(),M("div",x1e,[e.currentStepIndex!=0?(k(),M("button",{key:0,type:"button",class:"flex items-center text-sm font-medium text-gray-600 disabled:text-gray-300 nav-buttons back-btn order-1 md:order-0",onClick:a[0]||(a[0]=(...s)=>e.goBack&&e.goBack(...s)),disabled:e.isFormDisabled||e.loading},[(k(),M("svg",$1e,[...a[3]||(a[3]=[b("path",{stroke:"currentColor","stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"m15 19-7-7 7-7"},null,-1)])])),a[4]||(a[4]=Ze(" Back ",-1))],8,w1e)):(k(),M("div",S1e)),b("div",T1e,[(k(!0),M(xe,null,Me(e.steps,(s,o)=>(k(),M(xe,{key:s.id},[o%2===0?(k(),M("div",{key:0,class:pe(["paw-mask w-8 h-8 -mb-3 paw-right",{"completed-paw-img":o<=e.currentStepIndex,grey:o>e.currentStepIndex}]),role:"img","aria-hidden":"true"},null,2)):(k(),M("div",{key:1,class:pe(["paw-mask w-8 h-8 -mt-3 paw-left",{"completed-paw-img":o<=e.currentStepIndex,grey:o>e.currentStepIndex}]),role:"img","aria-hidden":"true"},null,2)),o%2===0&&o!==e.steps.length-1?(k(),M("div",{key:2,class:pe(["line-mask w-8 h-8 line-right",{"completed-paw-img-line":o<e.currentStepIndex,"line-grey":o>=e.currentStepIndex}]),role:"img","aria-hidden":"true"},null,2)):o!==e.steps.length-1?(k(),M("div",{key:3,class:pe(["line-mask w-8 h-8 -mb-3 line-left scale-x-[-1]",{"completed-paw-img-line":o<e.currentStepIndex,"line-grey":o>=e.currentStepIndex}]),role:"img","aria-hidden":"true"},null,2)):X("",!0)],64))),128))]),e.currentStepIndex!==e.steps.length-1?(k(),M("button",{key:2,type:"button",class:pe(["button-red rounded-[4px] nav-buttons next-btn w-auto max-w-full order-2 md:order-0",{"disabled-btn":i.value}]),onClick:a[1]||(a[1]=(...s)=>e.goNext&&e.goNext(...s)),disabled:!e.canGoNext||e.isFormDisabled||e.loading},[a[6]||(a[6]=Ze(" Next ",-1)),(k(),M("svg",k1e,[...a[5]||(a[5]=[b("path",{stroke:"currentColor","stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"m9 5 7 7-7 7"},null,-1)])]))],10,C1e)):(k(),M("button",{key:3,type:"button",class:"button-red rounded-[4px] nav-buttons next-btn w-auto max-w-full order-2 md:order-0",onClick:a[2]||(a[2]=(...s)=>e.submitEnquiry&&e.submitEnquiry(...s)),disabled:!e.canGoNext||e.isFormDisabled||e.loading}," Proceed ",8,E1e))]))}},M1e=Yt(P1e,[["__scopeId","data-v-7316fc19"]]),I1e={key:0,class:"fixed inset-0 z-50 flex items-center justify-center p-4"},A1e={class:"relative bg-white rounded-sm shadow-2xl max-w-md w-full p-8 text-center z-10"},D1e={class:"relative"},R1e={id:"dontForgetBookDropdown",class:"hidden book-call-container w-60 bg-white absolute text-sm flex-col z-70 p-2 rounded shadow-2xl justify-center items-center"},O1e={class:"book-call-item flex p-1"},L1e={xmlns:"http://www.w3.org/2000/svg","xmlns:xlink":"http://www.w3.org/1999/xlink",version:"1.1",id:"Layer_1",x:"0px",y:"0px",width:"25",height:"25",viewBox:"0 0 512 512",style:{"enable-background":"new 0 0 512 512"},"xml:space":"preserve"},F1e={class:"book-call-item flex p-1"},z1e={xmlns:"http://www.w3.org/2000/svg","xmlns:xlink":"http://www.w3.org/1999/xlink",version:"1.1",id:"Layer_1",x:"0px",y:"0px",width:"25",height:"25",viewBox:"0 0 512 512",style:{"enable-background":"new 0 0 512 512"},"xml:space":"preserve"},N1e={class:"book-call-item flex p-1"},B1e={xmlns:"http://www.w3.org/2000/svg","xmlns:xlink":"http://www.w3.org/1999/xlink",version:"1.1",id:"Layer_1",x:"0px",y:"0px",width:"25",height:"25",viewBox:"0 0 512 512",style:{"enable-background":"new 0 0 512 512"},"xml:space":"preserve"}
737,ik="enquiry_form_dismissed",j1e=1440*60*1e3,U1e=3e4,V1e={__name:"DontForgetYourEnquiry",props:{isFirstStep:{type:Boolean,required:!0}},emits:["close"],setup(e,{emit:t}){const r=e,i=t;function n(){const m=document.getElementById("dontForgetBookDropdown");m&&(m.classList.toggle("hidden"),m.classList.toggle("flex"))}function a(){try{const m=localStorage.getItem(ik);return m&&Date.now()-Number(m)<j1e}catch{return!1}}function s(){try{localStorage.setItem(ik,String(Date.now()))}catch{}}const o=se(!1);let l=null,u=a();function c(){clearTimeout(l),!(!r.isFirstStep||u)&&(l=setTimeout(()=>{o.value=!0,u=!0,p()},U1e))}function d(){o.value=!1,s(),i("close")}const h=["mousemove","mousedown","keydown","touchstart","scroll"];function f(){h.forEach(m=>document.addEventListener(m,c,{passive:!0}))}function p(){h.forEach(m=>document.removeEventListener(m,c))}return tt(()=>r.isFirstStep,m=>{m&&!u?(f(),c()):(clearTimeout(l),p(),o.value=!1)},{immediate:!0}),or(()=>{r.isFirstStep&&!u&&(f(),c())}),ss(()=>{clearTimeout(l),p()}),(m,g)=>(k(),Mt(QP,{to:"body"},[be(Ym,{name:"fade"},{default:_t(()=>[o.value?(k(),M("div",I1e,[b("div",{class:"absolute inset-0 bg-black/50 backdrop-blur-sm",onClick:d}),b("div",A1e,[b("button",{onClick:d,class:"absolute top-3 right-3 text-gray-400 hover:text-gray-700 transition-colors","aria-label":"Close"},[...g[0]||(g[0]=[b("svg",{xmlns:"http://www.w3.org/2000/svg",class:"h-6 w-6",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor","stroke-width":"2"},[b("path",{"stroke-linecap":"round","stroke-linejoin":"round",d:"M6 18L18 6M6 6l12 12"})],-1)])]),g[11]||(g[11]=b("h2",{class:"text-xl font-bold font-primary mb-3"}," Don't forget your enquiry ",-1)),b("p",{class:"font-primary text-base text-center mb-6"},[g[1]||(g[1]=Ze(" Prefer to speak to someone? ",-1)),g[2]||(g[2]=b("br",null,null,-1)),b("a",{class:"underline cursor-pointer",onClick:n},"Call a safari expert now"),g[3]||(g[3]=Ze(" for immediate help. ",-1))]),b("div",D1e,[b("div",R1e,[b("div",O1e,[(k(),M("svg",L1e,[...g[4]||(g[4]=[b("circle",{style:{fill:"#F0F0F0"},cx:"256",cy:"256",r:"256"},null,-1),b("path",{d:"M74.98,437.02c-99.974-99.975-99.974-262.065,0-362.04C74.973,74.991,222.609,256,222.609,256L74.98,437.02z"},null,-1),b("path",{style:{fill:"#FFDA44"},d:"M222.609,256L33.953,128.513c-5.849,10.167-11.007,20.779-15.439,31.763l95.509,95.725l-95.506,95.73 c4.428,10.976,9.581,21.581,15.426,31.741L222.609,256z"},null,-1),b("path",{style:{fill:"#295b04"},d:"M509.833,222.609H222.602L74.978,74.984c-15.908,15.908-29.729,33.899-41.025,53.53L161.192,256 L33.943,383.47c11.296,19.636,25.123,37.633,41.035,53.545l147.624-147.624h287.231C511.256,278.461,512,267.317,512,256 C512,244.683,511.256,233.539,509.833,222.609z"},null,-1),b("path",{style:{fill:"#0052B4"},d:"M100.138,459.077C143.307,492.259,197.344,512,256,512c118.279,0,217.805-80.221,247.181-189.217 H236.433L100.138,459.077z"},null,-1),b("path",{style:{fill:"#D80027"},d:"M503.181,189.217C473.805,80.221,374.279,0,256,0c-58.656,0-112.693,19.741-155.862,52.923 l136.294,136.294H503.181z"},null,-1)])])),g[5]||(g[5]=b("a",{href:"tel:+27600180308"},"(RSA) +27 60 018 0308",-1))]),b("div",F1e,[(k(),M("svg",z1e,[...g[6]||(g[6]=[b("circle",{style:{fill:"#F0F0F0"},cx:"256",cy:"256",r:"256"},null,-1),b("g",null,[b("path",{style:{fill:"#0052B4"},d:"M52.92,100.142c-20.109,26.163-35.272,56.318-44.101,89.077h133.178L52.92,100.142z"}),b("path",{style:{fill:"#0052B4"},d:"M503.181,189.219c-8.829-32.758-23.993-62.913-44.101-89.076l-89.075,89.076H503.181z"}),b("path",{style:{fill:"#0052B4"},d:"M8.819,322.784c8.83,32.758,23.993,62.913,44.101,89.075l89.074-89.075L8.819,322.784L8.819,322.784 z"}),b("path",{style:{fill:"#0052B4"},d:"M411.858,52.921c-26.163-20.109-56.317-35.272-89.076-44.102v133.177L411.858,52.921z"}),b("path",{style:{fill:"#0052B4"},d:"M100.142,459.079c26.163,20.109,56.318,35.272,89.076,44.102V370.005L100.142,459.079z"}),b("path",{style:{fill:"#0052B4"},d:"M189.217,8.819c-32.758,8.83-62.913,23.993-89.075,44.101l89.075,89.075V8.819z"}),b("path",{style:{fill:"#0052B4"},d:"M322.783,503.181c32.758-8.83,62.913-23.993,89.075-44.101l-89.075-89.075V503.181z"}),b("path",{style:{fill:"#0052B4"},d:"M370.005,322.784l89.075,89.076c20.108-26.162,35.272-56.318,44.101-89.076H370.005z"})],-1),b("g",null,[b("path",{style:{fill:"#D80027"},d:"M509.833,222.609h-220.44h-0.001V2.167C278.461,0.744,267.317,0,256,0 c-11.319,0-22.461,0.744-33.391,2.167v220.44v0.001H2.167C0.744,233.539,0,244.683,0,256c0,11.319,0.744,22.461,2.167,33.391 h220.44h0.001v220.442C233.539,511.256,244.681,512,256,512c11.317,0,22.461-0.743,33.391-2.167v-220.44v-0.001h220.442 C511.256,278.461,512,267.319,512,256C512,244.683,511.256,233.539,509.833,222.609z"}),b("path",{style:{fill:"#D80027"},d:"M322.783,322.784L322.783,322.784L437.019,437.02c5.254-5.252,10.266-10.743,15.048-16.435 l-97.802-97.802h-31.482V322.784z"}),b("path",{style:{fill:"#D80027"},d:"M189.217,322.784h-0.002L74.98,437.019c5.252,5.254,10.743,10.266,16.435,15.048l97.802-97.804 V322.784z"}),b("path",{style:{fill:"#D80027"},d:"M189.217,189.219v-0.002L74.981,74.98c-5.254,5.252-10.266,10.743-15.048,16.435l97.803,97.803 H189.217z"}),b("path",{style:{fill:"#D80027"},d:"M322.783,189.219L322.783,189.219L437.02,74.981c-5.252-5.254-10.743-10.266-16.435-15.047 l-97.802,97.803V189.219z"})],-1)])])),g[7]||(g[7]=b("a",{href:"tel:+447400075536"},"(UK) +44 740 007 5536",-1))]),b("div",N1e,[(k(),M("svg",B1e,[...g[8]||(g[8]=[b("circle",{style:{fill:"#F0F0F0"},cx:"256",cy:"256",r:"256"},null,-1),b("g",null,[b("path",{style:{fill:"#D80027"},d:"M244.87,256H512c0-23.106-3.08-45.49-8.819-66.783H244.87V256z"}),b("path",{style:{fill:"#D80027"},d:"M244.87,122.435h229.556c-15.671-25.572-35.708-48.175-59.07-66.783H244.87V122.435z"}),b("path",{style:{fill:"#D80027"},d:"M256,512c60.249,0,115.626-20.824,159.356-55.652H96.644C140.374,491.176,195.751,512,256,512z"}),b("path",{style:{fill:"#D80027"},d:"M37.574,389.565h436.852c12.581-20.529,22.338-42.969,28.755-66.783H8.819 C15.236,346.596,24.993,369.036,37.574,389.565z"})],-1),b("path",{style:{fill:"#0052B4"},d:"M118.584,39.978h23.329l-21.7,15.765l8.289,25.509l-21.699-15.765L85.104,81.252l7.16-22.037 C73.158,75.13,56.412,93.776,42.612,114.552h7.475l-13.813,10.035c-2.152,3.59-4.216,7.237-6.194,10.938l6.596,20.301l-12.306-8.941 c-3.059,6.481-5.857,13.108-8.372,19.873l7.267,22.368h26.822l-21.7,15.765l8.289,25.509l-21.699-15.765l-12.998,9.444 C0.678,234.537,0,245.189,0,256h256c0-141.384,0-158.052,0-256C205.428,0,158.285,14.67,118.584,39.978z M128.502,230.4 l-21.699-15.765L85.104,230.4l8.289-25.509l-21.7-15.765h26.822l8.288-25.509l8.288,25.509h26.822l-21.7,15.765L128.502,230.4z M120.213,130.317l8.289,25.509l-21.699-15.765l-21.699,15.765l8.289-25.509l-21.7-15.765h26.822l8.288-25.509l8.288,25.509h26.822 L120.213,130.317z M220.328,230.4l-21.699-15.765L176.93,230.4l8.289-25.509l-21.7-15.765h26.822l8.288-25.509l8.288,25.509h26.822 l-21.7,15.765L220.328,230.4z M212.039,130.317l8.289,25.509l-21.699-15.765l-21.699,15.765l8.289-25.509l-21.7-15.765h26.822 l8.288-25.509l8.288,25.509h26.822L212.039,130.317z M212.039,55.743l8.289,25.509l-21.699-15.765L176.93,81.252l8.289-25.509 l-21.7-15.765h26.822l8.288-25.509l8.288,25.509h26.822L212.039,55.743z"},null,-1)])])),g[9]||(g[9]=b("a",{href:"tel:+17866554040"},"(US) +1 786 655 4040",-1))]),g[10]||(g[10]=b("div",{class:"book-call-item flex p-1"},[b("svg",{xmlns:"http://www.w3.org/2000/svg",class:"svgphone",id:"Layer_1","data-name":"Layer 1",width:"25",height:"25",viewBox:"0 0 512 512"},[b("path",{d:"M280,0c128.1,0,232,103.9,232,232,0,13.3-10.7,24-24,24s-24-10.7-24-24c0-101.6-82.4-184-184-184-13.3,0-24-10.7-24-24S266.7,0,280,0Zm8,192c17.67,0,32,14.33,32,32s-14.33,32-32,32-32-14.33-32-32,14.33-32,32-32Zm-32-72c0-13.3,10.7-24,24-24,75.1,0,136,60.9,136,136,0,13.3-10.7,24-24,24s-24-10.7-24-24c0-48.6-39.4-88-88-88-13.3,0-24-10.7-24-24ZM117.5,1.4c19.4-5.3,39.7,4.6,47.4,23.2l40,96c6.8,16.3,2.1,35.2-11.6,46.3l-49.3,40.4c33.3,70.4,90.3,127.4,160.7,160.7l40.3-49.3c11.2-13.7,30-18.4,46.3-11.6l96,40c18.6,7.7,28.5,28,23.2,47.4l-24,88c-4.7,17.4-20.5,29.5-38.5,29.5C200.6,512,0,311.4,0,64,0,46,12.1,30.2,29.5,25.4c0,0,88-24,88-24Z"})]),b("a",{href:"https://meetings-eu1.hubspot.com/africa-geographic/free-safari-planning",target:"_blank"},"Schedule a call")],-1))])]),b("button",{onClick:d,class:"button-red rounded-[4px] nav-buttons next-btn w-auto max-w-full mb-4"}
737," Close ")])])):X("",!0)]),_:1})]))}},q1e=Yt(V1e,[["__scopeId","data-v-6207142c"]]),G1e={key:0,class:"space-y-6 max-w-screen-xl mx-auto bg-white rounded-lg p-4 md:p-8 shadow-2xl font-primary"},H1e={class:"pb-4",style:{flex:"1",height:"580px"}},Y1e=["value"],W1e={__name:"HubspotEnquiryContainer",props:{hubspotId:{type:String,required:!0},redirectUrl:{type:String,required:!0},currencyRates:{type:Object,required:!0},currencySelectorOptions:{type:Object,required:!0},experimentName:{type:String,default:""},experimentAlgo:{type:String,default:""},experimentDistribution:{type:[String,Number],default:""}},setup(e){var z,R;const t=e,r=os(),i=P$();i.currencyRates=t.currencyRates||{},i.currencySelectorOptions=t.currencySelectorOptions||{};const n=Object.keys(t.currencySelectorOptions||{})[0];n&&((z=t.currencySelectorOptions[n])!=null&&z.code)?i.selectedCurrency=t.currencySelectorOptions[n].code:i.selectedCurrency="USD";const a={safari_type:null,which_experiences_are_you_interested_in___hubspot_:[],do_you_know_where_you_want_to_travel___hubspot_:null,which_countries_would_you_like_to_visit_on_this_trip___hubspot_:[],travel_destination__hubspot_form_:[],do_you_know_when_you_would_like_to_travel___hubspot_:null,what_month_would_you_like_to_travel___hubspot_:null,as_an_estimate__how_many_days_would_you_like_to_travel___hubspot_:null,arrival_date__hubspot_:null,departure_date__hubspot_:null,who_will_you_be_travelling_with___hubspot_:null,how_many_people_are_travelling___hubspot_:1,how_many_children_12_years_of_age_and_under_are_travelling___hubspot_:0,how_many_infants___hubspot_:0,what_is_your_group_total_budget_in_usd___hubspot_:null,budget_type:"",firstname:"",lastname:"",email:"",phone:"",preferred_contact_options:""};let s=0;try{const O=JSON.parse(window.localStorage.getItem("enquiry_contacts"));O!=null&&O.enquiryForm?(r.enquiryForm={...a,...O.enquiryForm},s=O.currentStepIndex||0):r.enquiryForm={...a}}catch{r.enquiryForm={...a}}r.budgetValueRequired=!1;let o=Date.now();const l=new Set;for(let O=1;O<=s;O+=1)l.add(`step_${O}_complete`);const u=M_e(t.experimentAlgo,t.experimentDistribution),c=k_e(t.experimentName),d=[{id:"start-here",component:D_e,name:"What type of safari are you interested in"},{id:"interests",component:F_e,name:"Are there any experiences you are interested in"},{id:"travel",component:W_e,name:"Do you know where you want to travel"},{id:"dates",component:dye,name:"Do you know when you would like to travel"},{id:"participants",component:bye,name:"Who will you be travelling with"},{id:"budget",component:e1e,name:"What is your group total budget in USD"},{id:"contact",component:b1e,name:"What is your contact information"}],h=u==="b"?[d[d.length-1],...d.slice(0,-1)]:d;r.hubspotId=t.hubspotId,r.redirectUrl=t.redirectUrl,r.enquiryForm.safari_type__hubspot_=typeof document<"u"?document.title:"",r.enquiryForm.website=typeof window<"u"?window.location.href:"",r.enquiryForm.enquiry_form___ag_newsletter=Zd("utm_campaign")||Rx("utm_campaign_cookie")||"",r.enquiryForm.enquiry_adgroup_id=Zd("hsa_grp")||Rx("hsa_grp_cookie")||"",r.enquiryForm.gclid_field=Zd("gclid")||((R=JSON.parse(window.localStorage.getItem("gclid")))==null?void 0:R.value)||"",r.enquiryForm.referrer_url=document.referrer||"",r.enquiryForm.experiment_name=c,r.enquiryForm.experiment_variant=u;const f=H(()=>t.hubspotId&&t.redirectUrl),p=H(()=>!t.hubspotId||!t.redirectUrl),m=se(s),g=se(!1),v=se(!1),x=se(!1);function _(){Bi(()=>{var O;(O=document.getElementById("new-enquiry-form"))==null||O.scrollIntoView({behavior:"smooth",block:"start"})})}const y=H(()=>h[m.value]),w=H(()=>m.value===h.length-1),$=H(()=>{var O,V;return y.value.id==="start-here"?r.enquiryForm.safari_type!==null:y.value.id==="travel"?r.enquiryForm.do_you_know_where_you_want_to_travel___hubspot_==="Yes"&&(((O=r.enquiryForm.which_countries_would_you_like_to_visit_on_this_trip___hubspot_)==null?void 0:O.length)||0)>0||r.enquiryForm.do_you_know_where_you_want_to_travel___hubspot_==="Destinations"&&(((V=r.enquiryForm.travel_destination__hubspot_form_)==null?void 0:V.length)||0)>0||r.enquiryForm.do_you_know_where_you_want_to_travel___hubspot_==="No":y.value.id==="dates"?r.enquiryForm.do_you_know_when_you_would_like_to_travel___hubspot_!==null&&(r.enquiryForm.do_you_know_when_you_would_like_to_travel___hubspot_==="I have an idea"&&r.enquiryForm.what_month_would_you_like_to_travel___hubspot_!==null&&r.enquiryForm.as_an_estimate__how_many_days_would_you_like_to_travel___hubspot_!==null||r.enquiryForm.do_you_know_when_you_would_like_to_travel___hubspot_==="I have exact dates"&&r.enquiryForm.arrival_date__hubspot_!==null&&r.enquiryForm.departure_date__hubspot_!==null):y.value.id==="participants"?r.enquiryForm.who_will_you_be_travelling_with___hubspot_!==null:y.value.id==="contact"?v.value:y.value.id==="budget"?r.enquiryForm.what_is_your_group_total_budget_in_usd___hubspot_!==null:!0});function S(){m.value>0&&(m.value-=1,_(),I())}
737function E(){if(y.value.id==="budget"&&r.enquiryForm.what_is_your_group_total_budget_in_usd___hubspot_==null){r.budgetValueRequired=!0;return}$.value&&(A(y.value),m.value<h.length-1&&(m.value+=1,_(),I()))}function C(O){v.value=O}const I=()=>{window.localStorage.setItem("enquiry_contacts",JSON.stringify({enquiryForm:r.enquiryForm,currentStepIndex:m.value}))},P=async()=>{var O;A(y.value);try{if(await r.submitEnquiry()){g.value=!0,I();const V=t.redirectUrl+`?form_id=${encodeURIComponent(t.hubspotId)}&gclid=${encodeURIComponent(r.enquiryForm.gclid_field||"")}&travel_budget=${encodeURIComponent(r.enquiryForm.what_is_your_group_total_budget_in_usd___hubspot_||"")}&safari_destination=${encodeURIComponent(r.enquiryForm.which_countries_would_you_like_to_visit_on_this_trip___hubspot_.join(",")||"")}&safari_experiences=${encodeURIComponent(r.enquiryForm.which_experiences_are_you_interested_in___hubspot_.join(",")||"")}&travel_date_known=${encodeURIComponent(r.enquiryForm.do_you_know_when_you_would_like_to_travel___hubspot_||"")}&travel_group=${encodeURIComponent(r.enquiryForm.who_will_you_be_travelling_with___hubspot_||"")}&been_to_africa=${encodeURIComponent(r.enquiryForm.have_you_been_to_africa_before___hubspot_||"")}&additional_destinations=${encodeURIComponent(r.enquiryForm.travel_destination__hubspot_form_.join(",")||"")}`;window.localStorage.setItem("enquiry_contacts",JSON.stringify({enquiryForm:{firstname:r.enquiryForm.firstname,lastname:r.enquiryForm.lastname,email:r.enquiryForm.email,phone:r.enquiryForm.phone,gclid:r.enquiryForm.gclid_field},currentStepIndex:0}));let Y=!1;setTimeout(()=>{Y||(Y=!0,window.location.href=V.toString())},1500)}}catch(V){vA(V,{tags:{feature:"enquiry_form"},extra:{step_id:(O=y.value)==null?void 0:O.id,step_index:m.value}})}},T=()=>{if(typeof window>"u")return"";const O=window.location.hostname;return O==="travel.africageographic.com"?"G-1VMP2GYEW5":O==="travel.staging.africageographic.com"||O==="localhost"?"G-B8LY2NVQH5":""};or(()=>{var V;const O=T();if(O&&tk(O),m.value===0){const Y={step_event:"step_1_start",step_id:(V=y.value)==null?void 0:V.id,step_index:0,experiment_name:c,experiment_variant:u,...r.enquiryForm.budget_type?{budget_type:r.enquiryForm.budget_type}:{}};lT({category:"enquiry_form",message:"step_1_start",level:"info",data:Y}),Ox("step_1_start",Y,{sendTo:O})}});const D=/^[^\s@]+@[^\s@]+\.[^\s@]+$/;tt([w,()=>r.enquiryForm.email],([O,V])=>{if(!O)return;const Y=(V||"").trim();if(!D.test(Y))return;const F=T();F&&(tk(F),typeof window.gtag=="function"&&(E$()&&console.debug("[EC] gtag set user_data on last step",{email:Y}),window.gtag("set","user_data",{email:Y})))},{immediate:!0});const A=async O=>{var V;if(typeof window<"u"){const Y="step_"+(m.value+1)+"_complete";if(l.has(Y))return;l.add(Y);const F=T(),ae=r.enquiryForm,ue=ae.which_experiences_are_you_interested_in___hubspot_,Z=ae.which_countries_would_you_like_to_visit_on_this_trip___hubspot_,K=ae.travel_destination__hubspot_form_,fe={step_event:Y,step_id:O==null?void 0:O.id,step_index:m.value,time_in_seconds:(Date.now()-o)/1e3,experiment_name:c,experiment_variant:u,...ae.budget_type?{budget_type:ae.budget_type}:{},...ue!=null&&ue.length?{experience_name:ue.join(", ")}:{},...Z!=null&&Z.length?{country_name:Z.join(", ")}:{},...K!=null&&K.length?{destination_name:K.join(", ")}:{}},ve=Y==="step_7_complete";let $e;if(ve){const Re=(ae.email||"").trim();Re&&($e={email:Re});const Oe=(V=i.currencyRates)==null?void 0:V.ZAR,ze=typeof Oe=="number"?Oe:(Oe==null?void 0:Oe.rate)??0,Be=ae.what_is_your_group_total_budget_in_usd___hubspot_||0;fe.budget_value=Be*ze,fe.value=Be*ze,fe.currency="ZAR"}lT({category:"enquiry_form",message:"step_complete",level:"info",data:fe}),Ox(Y,fe,{sendTo:F,userData:$e}),o=Date.now()}};return(O,V)=>f.value?(k(),M("div",G1e,[b("div",H1e,[m.value===0?(k(),M(xe,{key:0},[V[0]||(V[0]=b("h3",{class:"text-center"},"Your dream African safari starts here",-1)),V[1]||(V[1]=b("p",{class:"text-center text-gray-500"},[Ze(" Tell us about your dream trip - our travel experts will craft a no-obligation itinerary just for you."),b("br"),Ze(" We have crafted over 5,000 safaris since 1991. ")],-1))],64)):X("",!0),(k(),Mt(c1(y.value.component),{"budget-value-required":O.budgetValueRequired,ref:"stepComponentRef",onValidationChange:C},null,40,["budget-value-required"]))]),w.value&&le(r).enquiryForm.email?(k(),M("input",{key:0,t
737ype:"email",name:"email",autocomplete:"email","aria-hidden":"true",tabindex:"-1",readonly:"",value:le(r).enquiryForm.email,style:{position:"absolute",width:"1px",height:"1px",padding:"0",border:"0",overflow:"hidden","white-space":"nowrap"}},null,8,Y1e)):X("",!0),be(M1e,{"current-step-index":m.value,steps:le(h),loading:le(r).loading,"can-go-next":$.value,"is-form-disabled":p.value,"disabled-btn":x.value,"go-back":S,"go-next":E,"submit-enquiry":P},null,8,["current-step-index","steps","loading","can-go-next","is-form-disabled","disabled-btn"]),be(q1e,{"is-first-step":m.value===0},null,8,["is-first-step"])])):X("",!0)}},Z1e={class:"grid grid-cols-2 md:grid-cols-4 gap-3 pt-3"},K1e={__name:"HaveYouBeenToAfrica",setup(e){const t=os(),r=n=>t.enquiryForm.have_you_been_to_africa_before___hubspot_===n,i=n=>{t.enquiryForm.have_you_been_to_africa_before___hubspot_=n};return(n,a)=>(k(),M(xe,null,[a[4]||(a[4]=b("div",{class:"font-primary text-base text-center font-bold"}," Have you been to Africa before? ",-1)),b("div",Z1e,[b("button",{type:"button",class:pe(["enquiry-white-btn",r("No")?"enquiry-white-btn--selected":""]),onClick:a[0]||(a[0]=s=>i("No"))}," I've never been ",2),b("button",{type:"button",class:pe(["enquiry-white-btn",r("Researched")?"enquiry-white-btn--selected":""]),onClick:a[1]||(a[1]=s=>i("Researched"))}," Never, but researched ",2),b("button",{type:"button",class:pe(["enquiry-white-btn",r("Once")?"enquiry-white-btn--selected":""]),onClick:a[2]||(a[2]=s=>i("Once"))},"I've been once",2),b("button",{type:"button",class:pe(["enquiry-white-btn",r("Yes")?"enquiry-white-btn--selected":""]),onClick:a[3]||(a[3]=s=>i("Yes"))},"I've been many times",2)])],64))}}
737,X1e={__name:"DreamSafari",setup(e){const t=os();return(r,i)=>(k(),M("div",null,[i[1]||(i[1]=b("div",{class:"font-primary text-base text-center font-bold pt-10"}," What else would make this your dream safari? ",-1)),i[2]||(i[2]=b("p",{class:"text-base text-center text-gray-400"},"What you and your fellow travellers hope to tick off your bucket list during your time in Africa.",-1)),it(b("textarea",{"onUpdate:modelValue":i[0]||(i[0]=n=>le(t).enquiryForm.what_else_would_make_this_your_dream_safari___hubspot_=n),class:"w-full p-2 border border-gray-300 rounded-md text-black h-[60px]"},null,512),[[ui,le(t).enquiryForm.what_else_would_make_this_your_dream_safari___hubspot_]])]))}},J1e={class:"mb-8 font-primary text-white text-base text-center"},Q1e=["innerHTML"],eve={class:"mb-8 font-primary text-white text-base text-center"},tve=["value"],rve=["value"],ive=["value"],nve=["value"],ave=["value"],sve=["disabled"],ove={__name:"ThankYouForEnquiring",props:{hubspotId:{type:String,required:!0},redirectUrl:{type:String},header:{type:String},note:{type:String}},setup(e){var l;const t=e,r=os(),i=((l=JSON.parse(window.localStorage.getItem("enquiry_contacts")))==null?void 0:l.enquiryForm)||{};r.hubspotId=t.hubspotId,r.redirectUrl=t.redirectUrl?t.redirectUrl:"/thank-you-enquiry",r.enquiryForm.email=i.email||"",r.redirectUrl=t.redirectUrl?t.redirectUrl:"/thank-you-enquiry";const n=H(()=>{const u=r.enquiryForm.have_you_been_to_africa_before___hubspot_;return u!=null&&u!==""}),a=()=>window.location.hostname==="travel.africageographic.com"?"G-1VMP2GYEW5":window.location.hostname==="travel.staging.africageographic.com"||window.location.hostname==="localhost"?"G-B8LY2NVQH5":"",s=()=>{const u=r.enquiryForm,c=(i.email||"").trim();S_e("additional_details_complete",{been_to_africa:u.have_you_been_to_africa_before___hubspot_||"",dream_safari:u.what_else_would_make_this_your_dream_safari___hubspot_||"",page_location:window.location.href},{sendTo:a(),userData:c?{email:c}:void 0})},o=async()=>{if(await r.submitEnquiry()){try{await s()}catch(u){console.error(u)}window.location.href=r.redirectUrl}};return(u,c)=>(k(),M(xe,null,[b("div",J1e,[b("h4",null,[b("em",null,Q(e.header||"Thank you, ")+" "+Q(le(i).firstname),1)])]),e.note?(k(),M("div",{key:0,class:"mb-8 font-primary text-white text-base text-center",innerHTML:e.note},null,8,Q1e)):X("",!0),b("div",eve,[b("input",{type:"hidden",name:"name",value:le(r).enquiryForm.firstname},null,8,tve),b("input",{type:"hidden",name:"surname",value:le(r).enquiryForm.lastname},null,8,rve),b("input",{type:"hidden",name:"email",value:le(r).enquiryForm.email},null,8,ive),b("input",{type:"hidden",name:"phone",value:le(r).enquiryForm.phone},null,8,nve),b("input",{type:"hidden",name:"gclid",value:le(r).enquiryForm.gclid},null,8,ave),be(K1e),be(X1e),b("button",{type:"button",class:pe(["button rounded-[2px] mt-6",n.value?"bg-ag-red border-ag-red hover:bg-ag-red-hover hover:border-ag-red-hover":"bg-gray-400 border-gray-400 hover:bg-gray-400 hover:border-gray-400"]),onClick:o,disabled:!n.value}," Submit ",10,sve)])],64))}},lve={class:"px-6 md:px-16 py-4 md:py-8 max-h-dvh overflow-y-scroll"},Yo={__name:"BookingsModal",props:["fullScreen"],setup(e){return or(()=>{document.body.style.overflow="hidden"}),ss(()=>{document.body.style.overflow="auto"}),(t,r)=>(k(),M("div",{class:pe(["bookings-modal fixed inset-0 bg-black bg-opacity-50 flex items-center justify-center",e.fullScreen?"p-0 overflow-hidden":"p-4 md:p-0 overflow-y-scroll"]),style:{"z-index":"1000"}},[b("div",{class:pe(["bg-white relative",{"w-full min-h-full md:min-h-0 sm:w-2/3 lg:w-1/2 xl:w-1/2 xxl:w-1/3 rounded-xl max-h-screen":!e.fullScreen,"w-full md:w-full h-dvh":e.fullScreen}])},[e.fullScreen?X("",!0):(k(),M("button",{key:0,onClick:r[0]||(r[0]=i=>t.$emit("close")),class:"absolute top-4 right-4 md:top-8 md:right-8"},[...r[2]||(r[2]=[b("svg",{class:"h-6 w-6 md:h-8 md:w-8",viewBox:"0 0 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg"},[b("path",{"fill-rule":"evenodd","clip-rule":"evenodd",d:"M19.207 6.207a1 1 0 0 0-1.414-1.414L12 10.586 6.207 4.793a1 1 0 0 0-1.414 1.414L10.586 12l-5.793 5.793a1 1 0 1 0 1.414 1.414L12 13.414l5.793 5.793a1 1 0 0 0 1.414-1.414L13.414 12l5.793-5.793z",fill:"#000000"})],-1)])])),e.fullScreen?(k(),M("button",{key:1,onClick:r[1]||(r[1]=i=>t.$emit("close")),class:"absolute top-4 left-4 md:top-8 md:left-8"},[...r[3]||(r[3]=[b("svg",{class:"h-6 w-6 md:h-8 md:w-8",viewBox:"0 0 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg"},[b("path",{d:"M15 6L9 12L15 18",stroke:"#000000","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round"})],-1)])])):X("",!0),b("div",lve,[ws(t.$slots,"default")])],2)],2))}},uve={class:"bookings-image-gallery"},cve={key:0,class:"relative"},dve={class:"grid grid-cols-1 md:grid-cols-2 gap-2 md:gap-4 my-4"},hve={class:"grid grid-cols-2 gap-2 md:gap-4"},fve={class:"max-w-screen-xl mx-auto py-6 md:py-12"},pve={class:"w-full md:w-1/3"},mve={class:"text-xl xl:text-2xl font-primary text-black my-0"},gve=["innerHTML"],_ve={class:"w-full md:w-2/3"},yve=["onClick"],vve={key:2,class:"fixed top-0 left-0 bg-black w-full w-screen h-screen overflow-scroll",style:{"z-index":"2000"}},bve={class:"grid grid-cols-3 md:grid-cols-3 gap-2 px-8 py-8 text-left"},xve={class:"text-white text-center"},wve={class:"flex justify-between items-center w-full py-2"},$ve={class:"flex-1 w-7/12 md:w-9/12"},Sve={class:"w-full flex flex-col justify-center items-center h-fit relative"},Tve={class:"relative mb-4"},Cve={key:0,class:"font-primary text-xxs absolute left-2 bottom-1 mb-0 text-white"},kve=["src"],Eve={key:0,class:"w-7/12 text-center font-primary text-white"},Pve={__name:"BookingsImageGallery",props:["galleries"],setup(e){const t=e,r=se(!1),i=se(1),n=se(!1),a=se(null),s=H(()=>{var h;return((h=t.galleries)==null?void 0:h.map(f=>f.images).flat())||[]});tt(n,h=>{document.body.style.overflow=h?"hidden":"auto"}),tt(r,h=>{document.body.style.overflow=h?"hidden":"auto"}),or(()=>{document.body.style.overflow="auto"}),ra(()=>{document.body.style.overflow="auto"});function o(){n.value=!n.value,document.body.style.overflow=n.value?"hidden":"auto"}function l(h){r.value=!0,i.value=s.value.indexOf(h),Bi(()=>{var f;(f=a.value)==null||f.slideTo(i.value)})}function u(h){i.value=h.currentSlideIndex}function c(){var h;(h=a.value)==null||h.prev()}function d(){var h;(h=a.value)==null||h.next()}return(h,f)=>(k(),M("div",uve,[s.value.length?(k(),M("div",cve,[b("button",{class:"button absolute top-4 md:top-auto md:bottom-4 left-4",onClick:o},"See all images"),b("div",dve,[b("div",{class:"w-full h-large-image bg-cover bg-center",style:Qt({backgroundImage:`url('${s.value[0].url}')`})},null,4),b("div",hve,[(k(!0),M(xe,null,Me(s.value.slice(1,5),(p,m)=>(k(),M("div",{key:`block-${m}`,class:"w-full h-medium-image bg-cover bg-center",style:Qt({backgroundImage:`url('${p.url}')`})},null,4))),128))])])])):X("",!0),n.value?(k(),Mt(Yo,{key:1,onClose:o,"full-screen":!0},{default:_t(()=>[b("div",fve,[(k(!0),M(xe,null,Me(e.galleries,(p,m)=>{var g;return k(),M("div",{key:`gallery-${m}`,class:"mt-5 pt-5 mb-8 border-t border-primary w-full flex flex-col md:flex-row items-start justify-between"},[b("div",pve,[b("div",mve,Q(p.title),1),b("div",{class:"font-primary",innerHTML:p.description},null,8,gve)]),b("div",_ve,[b("div",{class:pe(["grid gap-4",((g=p.images)==null?void 0:g.length)===1?"grid-cols-1":"grid-cols-2"])},[(k(!0),M(xe,null,Me(p.images,(v,x)=>{var _;return k(),M("div",{key:`gallery-block-${x}`,class:pe(["w-full bg-cover bg-center",((_=p.images)==null?void 0:_.length)===1?" h-large-image":" h-medium-image"]),style:Qt({backgroundImage:`url('${v.url}')`}),onClick:y=>l(v)},null,14,yve)}),128))],2)])])}),128))])]),_:1})):X("",!0),r.value?(k(),M("div",vve,[b("div",bve,[b("div",null,[b("button",{onClick:f[0]||(f[0]=di(p=>r.value=!1,["prevent"])),class:"text-white inline-block fill-white flex items-center gap-2"},[...f[1]||(f[1]=[b("svg",{width:"1.2rem",height:"1.2rem",viewBox:"0 0 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg"},[b("path",{fill:"currentColor","fill-rule":"evenodd","clip-rule":"evenodd",d:"M19.207 6.207a1 1 0 0 0-1.414-1.414L12 10.586 6.207 4.793a1 1 0 0 0-1.414 1.414L10.586 12l-5.793 5.793a1 1 0 1 0 1.414 1.414L12 13.414l5.793 5.793a1 1 0 0 0 1.414-1.414L13.414 12l5.793-5.793z"})],-1),b("span",null,"Close",-1)])])]),b("div",null,[b("div",xve,Q(i.value+1)+"/"+Q(s.value.length),1)]),f[2]||(f[2]=b("div",null,null,-1))]),b("div",wve,[b("button",{onClick:di(c,["prevent"]),class:"w-8 h-8 md:h-10 md:w-10 opacity-75 rounded-full border border-white flex justify-center lg:mx-5 mx-2 items-center fill-white"},[...f[3]||(f[3]=[b("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24"},[b("path",{d:"M15.293 3.293 6.586 12l8.707 8.707 1.414-1.414L9.414 12l7.293-7.293-1.414-1.414z"})],-1)])]),b("div",$ve,[be(le(D1),{style:{height:"auto"},ref_key:"carousel",ref:a,"wrap-around":!1,onSlideStart:u},{default:_t(()=>[(k(!0),M(xe,null,Me(s.value,(p,m)=>(k(),Mt(le(R1),{class:"",key:`slide-${m}`},{default:_t(()=>[b("div",Sve,[b("div",Tve,[p.copyright_caption?(k(),M("div",Cve,Q(p.copyright_caption),1)):X("",!0),b("img",{src:p.url,class:"h-auto w-70vw md:h-80vh md:w-auto"},null,8,kve)]),p.alt?(k(),M("div",Eve,Q(p.alt),1)):X("",!0)])]),_:2},1024))),128))]),_:1},512)]),b("button",{onClick:di(d,["prevent"]),class:"w-8 h-8 md:h-10 md:w-10 opacity-75 rounded-full border border-white flex justify-center lg:mx-5 mx-2 items-center fill-white"},[...f[4]||(f[4]=[b("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24"},[b("path",{d:"M7.293 4.707 14.586 12l-7.293 7.293 1.414 1.414L17.414 12 8.707 3.293 7.293 4.707z"})],-1)])])])])):X("",!0)]))}};
vendor: 6,060 bytes, line 737
737function aR(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var l_={exports:{}},Mve=l_.exports,nk;function Ive(){return nk||(nk=1,(function(e,t){(function(r,i){e.exports=i()})(Mve,(function(){var r=1e3,i=6e4,n=36e5,a="millisecond",s="second",o="minute",l="hour",u="day",c="week",d="month",h="quarter",f="year",p="date",m="Invalid Date",g=/^(\d{4})[-/]?(\d{1,2})?[-/]?(\d{0,2})[Tt\s]*(\d{1,2})?:?(\d{1,2})?:?(\d{1,2})?[.:]?(\d+)?$/,v=/\[([^\]]+)]|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,x={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(A){var z=["th","st","nd","rd"],R=A%100;return"["+A+(z[(R-20)%10]||z[R]||z[0])+"]"}},_=function(A,z,R){var O=String(A);return!O||O.length>=z?A:""+Array(z+1-O.length).join(R)+A},y={s:_,z:function(A){var z=-A.utcOffset(),R=Math.abs(z),O=Math.floor(R/60),V=R%60;return(z<=0?"+":"-")+_(O,2,"0")+":"+_(V,2,"0")},m:function A(z,R){if(z.date()<R.date())return-A(R,z);var O=12*(R.year()-z.year())+(R.month()-z.month()),V=z.clone().add(O,d),Y=R-V<0,F=z.clone().add(O+(Y?-1:1),d);return+(-(O+(R-V)/(Y?V-F:F-V))||0)},a:function(A){return A<0?Math.ceil(A)||0:Math.floor(A)},p:function(A){return{M:d,y:f,w:c,d:u,D:p,h:l,m:o,s,ms:a,Q:h}[A]||String(A||"").toLowerCase().replace(/s$/,"")},u:function(A){return A===void 0}},w="en",$={};$[w]=x;var S="$isDayjsObject",E=function(A){return A instanceof T||!(!A||!A[S])},C=function A(z,R,O){var V;if(!z)return w;if(typeof z=="string"){var Y=z.toLowerCase();$[Y]&&(V=Y),R&&($[Y]=R,V=Y);var F=z.split("-");if(!V&&F.length>1)return A(F[0])}else{var ae=z.name;$[ae]=z,V=ae}return!O&&V&&(w=V),V||!O&&w},I=function(A,z){if(E(A))return A.clone();var R=typeof z=="object"?z:{};return R.date=A,R.args=arguments,new T(R)},P=y;P.l=C,P.i=E,P.w=function(A,z){return I(A,{locale:z.$L,utc:z.$u,x:z.$x,$offset:z.$offset})};var T=(function(){function A(R){this.$L=C(R.locale,null,!0),this.parse(R),this.$x=this.$x||R.x||{},this[S]=!0}var z=A.prototype;return z.parse=function(R){this.$d=(function(O){var V=O.date,Y=O.utc;if(V===null)return new Date(NaN);if(P.u(V))return new Date;if(V instanceof Date)return new Date(V);if(typeof V=="string"&&!/Z$/i.test(V)){var F=V.match(g);if(F){var ae=F[2]-1||0,ue=(F[7]||"0").substring(0,3);return Y?new Date(Date.UTC(F[1],ae,F[3]||1,F[4]||0,F[5]||0,F[6]||0,ue)):new Date(F[1],ae,F[3]||1,F[4]||0,F[5]||0,F[6]||0,ue)}}return new Date(V)})(R),this.init()},z.init=function(){var R=this.$d;this.$y=R.getFullYear(),this.$M=R.getMonth(),this.$D=R.getDate(),this.$W=R.getDay(),this.$H=R.getHours(),this.$m=R.getMinutes(),this.$s=R.getSeconds(),this.$ms=R.getMilliseconds()},z.$utils=function(){return P},z.isValid=function(){return this.$d.toString()!==m},z.isSame=function(R,O){var V=I(R);return this.startOf(O)<=V&&V<=this.endOf(O)},z.isAfter=function(R,O){return I(R)<this.startOf(O)},z.isBefore=function(R,O){return this.endOf(O)<I(R)},z.$g=function(R,O,V){return P.u(R)?this[O]:this.set(V,R)},z.unix=function(){return Math.floor(this.valueOf()/1e3)},z.valueOf=function(){return this.$d.getTime()},z.startOf=function(R,O){var V=this,Y=!!P.u(O)||O,F=P.p(R),ae=function(Oe,ze){var Be=P.w(V.$u?Date.UTC(V.$y,ze,Oe):new Date(V.$y,ze,Oe),V);return Y?Be:Be.endOf(u)},ue=function(Oe,ze){return P.w(V.toDate()[Oe].apply(V.toDate("s"),(Y?[0,0,0,0]:[23,59,59,999]).slice(ze)),V)},Z=this.$W,K=this.$M,fe=this.$D,ve="set"+(this.$u?"UTC":"");switch(F){case f:return Y?ae(1,0):ae(31,11);case d:return Y?ae(1,K):ae(0,K+1);case c:var $e=this.$locale().weekStart||0,Re=(Z<$e?Z+7:Z)-$e;return ae(Y?fe-Re:fe+(6-Re),K);case u:case p:return ue(ve+"Hours",0);case l:return ue(ve+"Minutes",1);case o:return ue(ve+"Seconds",2);case s:return ue(ve+"Milliseconds",3);default:return this.clone()}},z.endOf=function(R){return this.startOf(R,!1)},z.$set=function(R,O){var V,Y=P.p(R),F="set"+(this.$u?"UTC":""),ae=(V={},V[u]=F+"Date",V[p]=F+"Date",V[d]=F+"Month",V[f]=F+"FullYear",V[l]=F+"Hours",V[o]=F+"Minutes",V[s]=F+"Seconds",V[a]=F+"Milliseconds",V)[Y],ue=Y===u?this.$D+(O-this.$W):O;if(Y===d||Y===f){var Z=this.clone().set(p,1);Z.$d[ae](ue),Z.init(),this.$d=Z.set(p,Math.min(this.$D,Z.daysInMonth())).$d}else ae&&this.$d[ae](ue);return this.init(),this},z.set=function(R,O){return this.clone().$set(R,O)},z.get=function(R){return this[P.p(R)]()},z.add=function(R,O){var V,Y=this;R=Number(R);var F=P.p(O),ae=function(K){var fe=I(Y);return P.w(fe.date(fe.date()+Math.round(K*R)),Y)};if(F===d)return this.set(d,this.$M+R);if(F===f)return this.set(f,this.$y+R);if(F===u)return ae(1);if(F===c)return ae(7);var ue=(V={},V[o]=i,V[l]=n,V[s]=r,V)[F]||1,Z=this.$d.getTime()+R*ue;return P.w(Z,this)},z.subtract=function(R,O){return this.add(-1*R,O)},z.format=function(R){var O=this,V=this.$locale();if(!this.isValid())return V.invalidDate||m;var Y=R||"YYYY-MM-DDTHH:mm:ssZ",F=P.z(this),ae=this.$H,ue=this.$m,Z=this.$M,K=V.weekdays,fe=V.months,ve=V.meridiem,$e=function(ze,Be,qe,j){return ze&&(ze[Be]||ze(O,Y))||qe[Be].slice(0,j)},Re=function(ze){return P.s(ae%12||12,ze,"0")},Oe=ve||function(ze,Be,qe){var j=ze<12?"AM":"PM";return qe?j.toLowerCase():j};return Y.replace(v,(function(ze,Be){return Be||(function(qe){switch(qe){case"YY":return String(O.$y).slice(-2);case"YYYY":return P.s(O.$y,4,"0");case"M":return Z+1;case"MM":return P.s(Z+1,2,"0");case"MMM":return $e(V.monthsShort,Z,fe,3);case"MMMM":return $e(fe,Z);case"D":return O.$D;case"DD":return P.s(O.$D,2,"0");case"d":return String(O.$W);case"dd":return $e(V.weekdaysMin,O.$W,K,2);case"ddd":return $e(V.weekdaysShort,O.$W,K,3);case"dddd":return K[O.$W];case"H":return String(ae);case"HH":return P.s(ae,2,"0");case"h":return Re(1);case"hh":return Re(2);case"a":return Oe(ae,ue,!0);case"A":return Oe(ae,ue,!1);case"m":return String(ue);case"mm":return P.s(ue,2,"0");case"s":return String(O.$s);case"ss":return P.s(O.$s,2,"0");case"SSS":return P.s(O.$ms,3,"0");case"Z":return F}return null})(ze)||F.replace(":","")}))}
737,z.utcOffset=function(){return 15*-Math.round(this.$d.getTimezoneOffset()/15)},z.diff=function(R,O,V){var Y,F=this,ae=P.p(O),ue=I(R),Z=(ue.utcOffset()-this.utcOffset())*i,K=this-ue,fe=function(){return P.m(F,ue)};switch(ae){case f:Y=fe()/12;break;case d:Y=fe();break;case h:Y=fe()/3;break;case c:Y=(K-Z)/6048e5;break;case u:Y=(K-Z)/864e5;break;case l:Y=K/n;break;case o:Y=K/i;break;case s:Y=K/r;break;default:Y=K}return V?Y:P.a(Y)},z.daysInMonth=function(){return this.endOf(d).$D},z.$locale=function(){return $[this.$L]},z.locale=function(R,O){if(!R)return this.$L;var V=this.clone(),Y=C(R,O,!0);return Y&&(V.$L=Y),V},z.clone=function(){return P.w(this.$d,this)},z.toDate=function(){return new Date(this.valueOf())},z.toJSON=function(){return this.isValid()?this.toISOString():null},z.toISOString=function(){return this.$d.toISOString()},z.toString=function(){return this.$d.toUTCString()},A})(),D=T.prototype;return I.prototype=D,[["$ms",a],["$s",s],["$m",o],["$H",l],["$W",u],["$M",d],["$y",f],["$D",p]].forEach((function(A){D[A[1]]=function(z){return this.$g(z,A[0],A[1])}})),I.extend=function(A,z){return A.$i||(A(z,T,I),A.$i=!0),I},I.locale=C,I.isDayjs=E,I.unix=function(A){return I(1e3*A)},I.en=$[w],I.Ls=$,I.p={},I}))})(l_)),l_.exports}var Ave=Ive();const ut=aR(Ave);var u_={exports:{}},Dve=u_.exports,ak;function Rve(){return ak||(ak=1,(function(e,t){(function(r,i){e.exports=i()})(Dve,(function(){var r={LTS:"h:mm:ss A",LT:"h:mm A",L:"MM/DD/YYYY",LL:"MMMM D, YYYY",LLL:"MMMM D, YYYY h:mm A",LLLL:"dddd, MMMM D, YYYY h:mm A"};return function(i,n,a){var s=n.prototype,o=s.format;a.en.formats=r,s.format=function(l){l===void 0&&(l="YYYY-MM-DDTHH:mm:ssZ");var u=this.$locale().formats,c=(function(d,h){return d.replace(/(\[[^\]]+])|(LTS?|l{1,4}|L{1,4})/g,(function(f,p,m){var g=m&&m.toUpperCase();return p||h[m]||r[m]||h[g].replace(/(\[[^\]]+])|(MMMM|MM|DD|dddd)/g,(function(v,x,_){return x||_.slice(1)}))}))})(l,u===void 0?{}:u);return o.call(this,c)}}}))})(u_)),u_.exports}var Ove=Rve();const sR=aR(Ove),sk=Zd("intr");
737sk!==null&&Rt.interceptors.request.use(e=>(e.params={...e.params||{},intr:sk},e));const o0={async getAccomodation(e,t,r){return Rt.get(`/api/bookings/getAccomodation/${e}/${t}/${r}`)},async getAccomodationUpdates(e,t,r,i){return Rt.post(`/api/bookings/getAccomodationUpdates/${e}/${t}/${r}`,i)},async getReservationRates(e,t,r){return Rt.post(`/api/bookings/getReservationRates/${e}/${t}`,r)},async createReservation(e){return new Promise((t,r)=>{Rt.post("/api/bookings/createReservation",e).then(i=>t(i)).catch(i=>{var n;return r((n=i.response)==null?void 0:n.data)})})}},Lve={key:0,class:"bookings-calendar",style:{transition:"opacity .2s ease-in-out"}},oR={__name:"BookingsCalendar",props:["defaultRange","disabledDates","maxStockDate","checkoutOnlyDates"],emits:["clear-dates","update-dates"],setup(e,{emit:t}){const r=e,i=t,n=se(null),a=se(null),s=se(ut().add(1,"day").toDate()),o=se(typeof window<"u"?window.innerWidth:1024),l=H(()=>[{key:"endRangeOnly",dates:r.checkoutOnlyDates,color:"none",contentStyle:{color:"#94a3b8"},content:{style:{color:"#94a3b8"}},popover:{visibility:"hover",label:"Checkout only"}}]),u={highlight:{start:{fillMode:"outline",style:{backgroundColor:"#d5af38",borderColor:"#d5af38"},contentStyle:{color:"white"}},base:{fillMode:"light",style:{backgroundColor:"#E9E9E9",color:"#94a3b8",opacity:1},contentStyle:{color:"#94a3b8",fontWeight:"500"}},end:{fillMode:"outline",style:{backgroundColor:"#d5af38",borderColor:"#d5af38",color:"white",zIndex:99},contentStyle:{color:"white"}}}},c=H(()=>o.value>=1024?2:1);function d(){o.value=window.innerWidth}return or(()=>{a.value=r.defaultRange,window.addEventListener("resize",d,{passive:!0})}),ra(()=>{window.removeEventListener("resize",d)}),tt(()=>r.defaultRange,h=>{var f,p;(!h||h.start!==((f=a.value)==null?void 0:f.start)||h.end!==((p=a.value)==null?void 0:p.end))&&Bi(()=>{a.value=h,h!=null&&h.start&&n.value&&n.value.move(h.start)})}),tt(a,h=>{var f,p;h!=null&&h.start&&(h!=null&&h.end)&&!r.checkoutOnlyDates.includes(ut(h.start).format("YYYY-MM-DD"))&&!r.checkoutOnlyDates.some(m=>ut(m).isAfter(ut(h.start))&&ut(m).isBefore(ut(h.end)))&&(h.start!==((f=r.defaultRange)==null?void 0:f.start)||h.end!==((p=r.defaultRange)==null?void 0:p.end))?i("update-dates",h):Bi(()=>{var m;a.value=r.defaultRange,(m=r.defaultRange)!=null&&m.start&&n.value&&n.value.move(r.defaultRange.start)})},{deep:!0}),(h,f)=>{const p=qr("v-date-picker");return a.value?(k(),M("div",Lve,[be(p,{ref_key:"calendar",ref:n,"disabled-dates":e.disabledDates,"select-attribute":u,"drag-attribute":u,attributes:l.value,"is-expanded":"",modelValue:a.value,"onUpdate:modelValue":f[0]||(f[0]=m=>a.value=m),"is-range":"",columns:c.value,"min-date":s.value,"max-date":e.maxStockDate},null,8,["disabled-dates","attributes","modelValue","columns","min-date","max-date"]),b("div",{onClick:f[1]||(f[1]=m=>h.$emit("clear-dates")),class:"cursor-pointer font-primary text-center md:text-right text-sm block underline mb-4 md:mb-0"}," Reset Dates ")])):X("",!0)}}},Fve=["disabled"],zve=["disabled"],Nve={class:"w-6 text-center"},Bve=["disabled"],jve={__name:"BookingsQtySelector",props:["value","max","min","disabled","type","totalAdults","totalChildren","maxChildren","maxAdults","maxCapacity","maxRoomCapacity"],emits:["error","input"],setup(e,{emit:t}){const r=e,i=t;function n(){if(!r.disabled){if(r.value>=r.max){i("error",r.value);return}i("input",r.value+1)}}function a(){if(!r.disabled){if(r.value<=0||r.value<=r.min){i("error",r.value);return}i("input",r.value-1)}}return(s,o)=>(k(),M("div",{disabled:e.disabled,class:"flex justify-center items-center gap-2"},[b("button",{onClick:a,class:"qty-button",disabled:e.disabled||e.value<=0||e.value<=e.min},[...o[0]||(o[0]=[b("div",{class:"w-6 h-6 bg-contain border border-black rounded-full",style:{"background-image":"url('/img/minus.svg')"}},null,-1)])],8,zve),b("div",Nve,Q(e.value),1),b("button",{onClick:n,class:"qty-button",disabled:e.disabled||e.type==="room"&&(e.maxRoomCapacity<=1||e.value>=e.max)||e.type==="child"&&e.totalChildren>=e.maxChildren||e.type==="adult"&&e.totalAdults>=e.maxAdults||["child","adult"].includes(e.type)&&e.maxCapacity<=e.totalChildren+e.totalAdults},[...o[1]||(o[1]=[b("div",{class:"w-6 h-6 bg-contain border border-black rounded-full",style:{"background-image":"url('/img/plus.svg')"}},null,-1)])],8,Bve)],8,Fve))}},Uve={class:"w-4 h-4 mx-2"},Vve={key:0,xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 512 512"},qve={key:1,xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 512 512"},ok={__name:"BookingsChevron",props:["direction"],setup(e){return(t,r)=>(k(),M("div",Uve,[e.direction==="up"?(k(),M("svg",Vve,[...r[0]||(r[0]=[b("path",{d:"M233.4 105.4c12.5-12.5 32.8-12.5 45.3 0l192 192c12.5 12.5 12.5 32.8 0 45.3s-32.8 12.5-45.3 0L256 173.3 86.6 342.6c-12.5 12.5-32.8 12.5-45.3 0s-12.5-32.8 0-45.3l192-192z"},null,-1)])])):X("",!0),e.direction==="down"?(k(),M("svg",qve,[...r[1]||(r[1]=[b("path",{d:"M233.4 406.6c12.5 12.5 32.8 12.5 45.3 0l192-192c12.5-12.5 12.5-32.8 0-45.3s-32.8-12.5-45.3 0L256 338.7 86.6 169.4c-12.5-12.5-32.8-12.5-45.3 0s-12.5 32.8 0 45.3l192 192z"},null,-1)])])):X("",!0)]))}},Gve={class:"bookings-form sticky top-20"},Hve={class:"border border-black bg-white shadow-xl relative"},Yve={class:"p-4 relative"},Wve={role:"status",title:"Updating...",class:"absolute top-4 right-4"},Zve={class:"text-2xl md:text-3xl font-primary text-black my-0"},Kve={key:0},Xve={key:1}
737,Jve={key:0,class:"mb-6 rounded-md border border-[#ecdcb0] bg-[#faf6ec] px-[18px] py-4"},Qve={class:"m-0 text-sm leading-normal text-[#4a4a4a]"},ebe=["href"],tbe={class:"flex flex-col justify-center items-center border border-black rounded-lg mb-4"},rbe={class:"flex-1 p-2 border-r border-black"},ibe={class:"flex-1 p-2"},nbe={class:"w-full"},abe={class:"border-b border-black relative h-16"},sbe={key:0},obe={key:1},lbe={key:0,class:"bg-white absolute top-16 left-0 z-20 shadow-xl border-t border-gray-100 p-4 rounded-b-lg flex flex-col gap-2",style:{width:"calc(100% + 2px)","margin-left":"-1px","max-height":"420px","overflow-y":"scroll"}},ube={class:"font-primary font-medium text-lg"},cbe={class:"font-primary text-sm"},dbe=["disabled","onClick"],hbe=["disabled","onClick"],fbe={class:"relative h-16"},pbe={class:"leading-none"},mbe={key:0,class:"bg-white absolute top-16 mt-1 left-0 w-full z-20 shadow-lg p-4 border border-white rounded-lg flex flex-col gap-2"},gbe={key:0,class:"flex-1"},_be={class:"font-primary text-xs font-light text-ag-black"},ybe={class:"flex-1"},vbe={class:"font-primary text-lg leading-1"},bbe={key:0,class:"font-primary text-xs font-light text-ag-black"},xbe={key:1},wbe={key:0,class:"font-primary text-xs font-light text-ag-black"},$be={key:1,class:"font-primary text-xs font-light text-ag-black"},Sbe={key:2,class:"font-primary text-xs font-light text-ag-black"},Tbe={key:1,class:"text-center text-ag-brown-grey font-primary text-sm mb-4"},Cbe={key:2,class:"text-center text-red-500 font-primary text-sm mb-4"},kbe={key:3,class:"text-center text-red-500 font-primary text-sm mb-4"},Ebe={key:4,class:"flex flex-col gap-4"},Pbe=["disabled"],Mbe={key:0,class:"flex items-center justify-center gap-2"},Ibe={key:1,class:"flex items-center justify-center gap-2"},Abe={class:"flex flex-col gap-2 mb-4"},Dbe={key:0,class:"font-primary text-center text-sm block"},Rbe={key:1,class:"font-primary text-center text-sm block"},Obe={key:2,class:"font-primary text-center text-sm block"},Lbe={key:3},Fbe={key:0},zbe={class:"grid grid-cols-2 gap-2 mb-2"},Nbe={class:"font-primary text-sm text-ag-black font-bold"},Bbe=["disabled","onClick"],jbe={key:0},Ube={key:1},Vbe={class:"grid grid-cols-2 gap-2"},qbe={class:"font-primary text-xs text-ag-black"},Gbe={class:"font-primary text-xs text-ag-black text-right"},Hbe={class:"grid grid-cols-2 gap-2"},Ybe={class:"font-primary text-xs text-ag-black"},Wbe={class:"font-primary text-xs text-ag-black text-right"},Zbe={class:"grid grid-cols-2 gap-2 mb-4 mt-2"},Kbe={class:"font-primary text-sm text-ag-black text-right"},Xbe={key:4},Jbe={class:"grid grid-cols-2 gap-2 mb-4"},Qbe={class:"font-primary text-base text-ag-black text-right"},e2e=["disabled"],t2e={key:0},r2e={key:1},i2e=["disabled"],n2e={key:0},a2e={key:1},s2e=["href"],mb={__name:"BookingsForm",props:["formTerms","range","accomodation","accomodationUpdates","removingReservationItem","booking","loading","loadingAccomodation","loadingAccomodationUpdates","loadingReservationRates","roomModal","isBookable","variant","unitDetails","submitting","reservationItems","reservationRates","rateGroupDescriptions","rateGroupLabels","allowedRateGroups","hasDisabledDates","maxRoomCapacity","title","isAfricanParks"],emits:["show-modal","update-room","set-guests","update-guests","update-reservation","remove-reservation-item","submit"],setup(e,{emit:t}){ut.extend(sR);const r=e,i=H(()=>`mailto:[email protected]?subject=${encodeURIComponent(r.title||"")}`),n=t,a=se(!1),s=se(!1),o=H(()=>r.booking.guests.filter(O=>O.qty>0).map(O=>O.qty>0?O.qty+" "+(S(O.id)||E(O.qty,O.desc)):null).filter(Boolean).join(", ")),l=H(()=>!r.range||!r.range.start||!r.range.end?0:r.range.end.diff(r.range.start,"day")),u=H(()=>r.booking.guests.filter(O=>O.type==="child").map(O=>O.qty>0?O.qty:0).reduce((O,V)=>O+V,0)),c=H(()=>r.booking.guests.filter(O=>O.type==="adult").map(O=>O.qty>0?O.qty:0).reduce((O,V)=>O+V,0)),d=H(()=>{var R,O,V;return{adult:parseInt((R=r.booking.roomType)==null?void 0:R.max_adults)||0,child:parseInt((O=r.booking.roomType)==null?void 0:O.max_capacity)-parseInt(c.value)||0,room:parseInt((V=r.booking.roomType)==null?void 0:V.room_capacity)||0}}),h=H(()=>({adult:0,child:0,room:1}));function f(){r.variant!=="select"||r.loading||(document.querySelector(".bookings-container").scrollIntoView({behavior:"smooth"}),p())}function p(){const R=document.querySelector(".bookings-calendar");R&&(R.style.opacity=0,setTimeout(()=>{R.style.opacity=1,setTimeout(()=>{R.style.opacity=0,setTimeout(()=>{R.style.opacity=1},200)},200)},200))}
737function m(R){return!R||!r.unitDetails?null:r.unitDetails.find(O=>O.accomodation_id===R.id)||null}function g(){r.variant!=="select"||r.loading||(s.value=!1,a.value=!a.value)}function v(){r.variant!=="select"||r.loading||(a.value=!1,s.value=!s.value,n("update-guests"))}function x(R){r.variant==="select"&&(a.value=!1,s.value=!1,n("update-room",R),f())}function _(R,O){r.variant==="select"&&n("set-guests",{id:R,qty:O})}function y(){r.variant==="select"&&(s.value=!1,n("update-guests"),f())}function w(){r.variant==="select"&&n("update-reservation")}function $(R){r.variant==="select"&&n("remove-reservation-item",R)}function S(R){return!r.rateGroupLabels||!Object.keys(r.rateGroupLabels).includes(R)?null:r.rateGroupLabels[R]||null}function E(R=0,O){switch(O.toLowerCase()){case"adult":return R===1?"Adult":"Adults";case"child":return R===1?"Child":"Children";case"unit":return R===1?"Unit":"Units";case"room":return R===1?"Room":"Rooms";default:return O}}function C(R){var Y,F,ae,ue,Z;const O=new Intl.NumberFormat("en-US",{style:"currency",currency:"USD"});let V=0;return(Y=r.accomodationUpdates)!=null&&Y.room_rates&&((F=r.accomodationUpdates)==null?void 0:F.room_rates.length)>0&&((ae=r.accomodationUpdates)!=null&&ae.room_rates.find(K=>K.accommodation_id===R))&&(V=parseFloat(((Z=(ue=r.accomodationUpdates)==null?void 0:ue.room_rates.find(K=>K.accommodation_id===R))==null?void 0:Z.display_value)||"0.00")),O.format(V)}function I(R){var Y,F,ae,ue;const O=new Intl.NumberFormat("en-US",{style:"currency",currency:"USD"});let V=0;if((Y=r.accomodationUpdates)!=null&&Y.shared_room_rate&&((F=r.accomodationUpdates)==null?void 0:F.shared_room_rate.accommodation_id)===R)V=parseFloat(((ue=(ae=r.accomodationUpdates)==null?void 0:ae.shared_room_rate)==null?void 0:ue.display_value)/2||"0.00");else return C(R);return O.format(V)}function P(R){return ut(R).format("ll")}function T(R){if(!r.accomodationUpdates||!r.accomodationUpdates.rate_groups)return"";const O=new Map(r.accomodationUpdates.rate_groups.map(Y=>[Y.id,Y]));return R.rate_groups.filter(Y=>Y.qty>0).map(Y=>{const F=O.get(Y.id);if(!F)return null;const ae=S(F.id)||E(Y.qty,F.desc);return`${Y.qty} ${ae}`}).filter(Boolean).join(", ")}function D(R){const O=new Intl.NumberFormat("en-US",{style:"currency",currency:"USD"});let V=0;return R&&R>0&&(V=R),O.format(V)}function A(R){var O;return R!=null&&R.total&&R.total>0?R.total:(O=R==null?void 0:R.totals)!=null&&O.length?R.totals.reduce((V,Y)=>V+(Y.total||0),0):0}function z(){const R=new Intl.NumberFormat("en-US",{style:"currency",currency:"USD"}),O=A(r.reservationRates);return R.format(O)}return(R,O)=>{var V,Y,F,ae,ue;return k(),M("div",Gve,[b("div",Hve,[b("div",Yve,[it(b("div",Wve,[...O[2]||(O[2]=[b("svg",{"aria-hidden":"true",class:"w-7 h-7 text-gray-200 animate-spin fill-gray-400",viewBox:"0 0 100 101",fill:"none",xmlns:"http://www.w3.org/2000/svg"},[b("path",{d:"M100 50.5908C100 78.2051 77.6142 100.591 50 100.591C22.3858 100.591 0 78.2051 0 50.5908C0 22.9766 22.3858 0.59082 50 0.59082C77.6142 0.59082 100 22.9766 100 50.5908ZM9.08144 50.5908C9.08144 73.1895 27.4013 91.5094 50 91.5094C72.5987 91.5094 90.9186 73.1895 90.9186 50.5908C90.9186 27.9921 72.5987 9.67226 50 9.67226C27.4013 9.67226 9.08144 27.9921 9.08144 50.5908Z",fill:"currentColor"}),b("path",{d:"M93.9676 39.0409C96.393 38.4038 97.8624 35.9116 97.0079 33.5539C95.2932 28.8227 92.871 24.3692 89.8167 20.348C85.8452 15.1192 80.8826 10.7238 75.2124 7.41289C69.5422 4.10194 63.2754 1.94025 56.7698 1.05124C51.7666 0.367541 46.6976 0.446843 41.7345 1.27873C39.2613 1.69328 37.813 4.19778 38.4501 6.62326C39.0873 9.04874 41.5694 10.4717 44.0505 10.1071C47.8511 9.54855 51.7191 9.52689 55.5402 10.0491C60.8642 10.7766 65.9928 12.5457 70.6331 15.2552C75.2735 17.9648 79.3347 21.5619 82.5849 25.841C84.9175 28.9121 86.7997 32.2913 88.1811 35.8758C89.083 38.2158 91.5421 39.6781 93.9676 39.0409Z",fill:"currentFill"})],-1)])],512),[[Dn,e.loading&&e.variant==="select"]]),b("div",null,[b("h4",Zve,[O[3]||(O[3]=Ze(" From ",-1)),e.booking.roomType?(k(),M("span",Kve,Q(I(e.booking.roomType.id)),1)):(k(),M("span",Xve,"$-.--"))]),O[4]||(O[4]=b("p",{class:"font-primary text-ag-brown-grey text-lg mb-4"},"per person sharing per night",-1))]),e.isAfricanParks?(k(),M("div",Jve,[b("p",Qve,[O[5]||(O[5]=Ze("You're viewing ",-1)),O[6]||(O[6]=b("span",{class:"font-bold text-[#b8860b]"},"International",-1)),O[7]||(O[7]=Ze(" rates. To view Citizen, Resident, EAC, SADC, African rates. ",-1)),b("a",{href:i.value,class:"font-semibold text-black underline"},"Contact us directly",8,ebe)])])):X("",!0),b("div",tbe,[b("div",{class:pe(["w-full flex justify-between items-center border-b border-black",{"curs
737or-pointer":!e.loading&&e.variant==="select","cursor-not-allowed":e.loading,"opacity-50":e.loading}]),onClick:f},[b("div",rbe,[O[8]||(O[8]=b("label",{for:"check-in",class:"font-primary text-ag-black-2 text-sm"},"Check-in",-1)),b("div",null,Q(e.range.start.format("ll")),1)]),b("div",ibe,[O[9]||(O[9]=b("label",{for:"check-out",class:"font-primary text-ag-black-2 text-sm"},"Check-out",-1)),b("div",null,Q(e.range.end.format("ll")),1)])],2),b("div",nbe,[b("div",abe,[b("div",{onClick:g,class:pe(["h-16 flex items-center justify-between gap-1 p-2 w-full",{"cursor-pointer":!e.loading&&e.variant==="select","cursor-not-allowed":e.loading,"opacity-50":e.loading}])},[b("div",null,[O[10]||(O[10]=b("label",{for:"check-out",class:"font-primary text-ag-black-2 text-sm"},"Room type",-1)),(V=e.booking.roomType)!=null&&V.id?X("",!0):(k(),M("div",sbe,"Select a room type")),(Y=e.booking.roomType)!=null&&Y.id?(k(),M("div",obe,Q(e.booking.roomType.name),1)):X("",!0)]),it(be(ok,{direction:a.value?"up":"down"},null,8,["direction"]),[[Dn,e.variant==="select"]])],2),e.variant==="select"&&a.value&&e.accomodation&&e.accomodation.length>0?(k(),M("div",lbe,[(k(!0),M(xe,null,Me(e.accomodation,(Z,K)=>{var fe,ve;return k(),M("div",{key:`roomType-${K}`,class:"grid grid-cols-2 gap-8"},[b("div",null,[b("div",ube,Q(Z.name),1),b("div",cbe,"From US$ "+Q(C(Z.id))+" per night",1),b("button",{class:pe(["font-primary text-sm underline",{"opacity-20":!m(Z)}]),disabled:!m(Z),onClick:$e=>R.$emit("show-modal",m(Z))},"View details",10,dbe)]),b("div",null,[b("button",{class:"button min-w-0 block w-full mt-2",disabled:((fe=e.booking.roomType)==null?void 0:fe.id)===Z.id,onClick:$e=>x(Z)},Q(((ve=e.booking.roomType)==null?void 0:ve.id)===Z.id?"Selected":"Select"),9,hbe)])])}),128)),b("button",{onClick:O[0]||(O[0]=Z=>{a.value=!1}),class:"underline font-primary text-right"},"Close")])):X("",!0)]),b("div",fbe,[b("div",{class:pe(["w-full flex justify-between items-center",{"cursor-pointer":!e.loading&&e.variant==="select","cursor-not-allowed":e.loading,"opacity-50":e.loading}])},[b("div",{onClick:v,class:"h-16 flex items-center justify-between gap-1 p-2 w-full border-r border-black"},[b("div",null,[O[11]||(O[11]=b("label",{for:"check-out",class:"font-primary text-ag-black-2 text-sm"},"Guests",-1)),b("div",pbe,Q(o.value),1)]),it(be(ok,{direction:s.value?"up":"down"},null,8,["direction"]),[[Dn,e.variant==="select"]])]),b("div",{class:"p-2",onClick:f},[O[12]||(O[12]=b("label",{for:"check-out",class:"font-primary text-ag-black-2 text-sm"},"Nights",-1)),b("div",null,Q(l.value),1)])],2),e.variant==="select"&&s.value&&((ae=(F=e.accomodationUpdates)==null?void 0:F.rate_groups)==null?void 0:ae.length)>0?(k(),M("div",mbe,[(k(!0),M(xe,null,Me(e.accomodationUpdates.rate_groups.filter(Z=>{var K;return(K=e.allowedRateGroups)==null?void 0:K.includes(Z.id)}).sort((Z,K)=>{const fe=e.allowedRateGroups.indexOf(Z.id),ve=e.allowedRateGroups.indexOf(K.id);return fe!==-1&&ve!==-1?fe-ve:fe!==-1?-1:ve!==-1?1:0}),(Z,K)=>{var fe,ve,$e,Re,Oe,ze,Be,qe,j,W;return k(),M("div",{key:K,class:"flex justify-between items-center w-full"},[Z.id==="RS1"?(k(),M("div",gbe,[b("div",_be,"Max persons per room: "+Q(((fe=e.booking.roomType)==null?void 0:fe.max_capacity)||0),1)])):(k(),M(xe,{key:1},[b("div",ybe,[b("div",vbe,Q(e.rateGroupLabels[Z.id]||Z.desc),1),e.rateGroupDescriptions[Z.id]?(k(),M("div",bbe,Q(e.rateGroupDescriptions[Z.id]),1)):(k(),M("div",xbe,[Z.id==="RS1"?(k(),M("div",wbe,"Max persons per room: "+Q(((ve=e.booking.roomType)==null?void 0:ve.max_capacity)||0),1)):X("",!0),Z.id==="RS2"?(k(),M("div",$be,"Max adults per room: "+Q((($e=e.booking.roomType)==null?void 0:$e.max_adults)||0),1)):X("",!0),Z.id==="RS3"?(k(),M("div",Sbe,"Max child age (12 years): "+Q(((Re=e.booking.roomType)==null?void 0:Re.max_child_age)||0),1)):X("",!0)]))]),b("div",null,[be(jve,{type:(Oe=e.booking.guests.find(G=>G.id===Z.id))==null?void 0:Oe.type,"total-adults":c.value,"total-children":u.value,"max-adults":d.value.adult,"max-children":d.value.child,"max-capacity":((ze=e.booking.roomType)==null?void 0:ze.max_capacity)||0,"max-room-capacity":e.maxRoomCapacity,max:d.value[((Be=e.booking.guests.find(G=>
737G.id===Z.id))==null?void 0:Be.type)||"adult"],min:h.value[((qe=e.booking.guests.find(G=>G.id===Z.id))==null?void 0:qe.type)||"adult"],value:e.maxRoomCapacity<=1&&((j=e.booking.guests.find(G=>G.id===Z.id))==null?void 0:j.type)=="room"?1:(W=e.booking.guests.find(G=>G.id===Z.id))==null?void 0:W.qty,onInput:G=>_(Z.id,G)},null,8,["type","total-adults","total-children","max-adults","max-children","max-capacity","max-room-capacity","max","min","value","onInput"])])],64))])}),128)),b("button",{onClick:y,class:"underline font-primary text-right"},"Close")])):X("",!0)])])]),!e.loadingAccomodationUpdates&&e.maxRoomCapacity?(k(),M("div",Tbe,[O[13]||(O[13]=Ze(" Available units for ",-1)),b("b",null,Q((ue=e.booking.roomType)==null?void 0:ue.name),1),Ze(": "+Q(e.maxRoomCapacity||0),1)])):X("",!0),e.hasDisabledDates?(k(),M("div",Cbe," Room unavailable for the selected date range. ")):!e.loading&&e.maxRoomCapacity<1?(k(),M("div",kbe," No more rooms available for the selected date range. ")):X("",!0),e.variant==="select"?(k(),M("div",Ebe,[b("button",{disabled:e.submitting||e.loading||e.hasDisabledDates||e.maxRoomCapacity<1||c.value===0&&u.value===0,onClick:w,class:"button button--solid mb-2 mx-auto"},[e.reservationItems.length>0?(k(),M("span",Mbe,[...O[14]||(O[14]=[b("svg",{width:"1.5rem",height:"1.5rem",viewBox:"0 0 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg"},[b("path",{d:"M6 12H18M12 6V18",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round"})],-1),b("span",null,"Add to booking",-1)])])):(k(),M("span",Ibe,[...O[15]||(O[15]=[b("span",null,"Next",-1)])]))],8,Pbe)])):X("",!0),b("div",Abe,[!e.loadingAccomodationUpdates&&!e.loadingReservationRates&&e.variant==="select"?(k(),M("p",Dbe,"You can add multiple rooms & guests")):X("",!0),e.loadingAccomodationUpdates&&e.variant==="select"?(k(),M("p",Rbe,"Checking availability...")):X("",!0),e.loadingReservationRates&&e.variant==="select"?(k(),M("p",Obe,"Updating reservation...")):X("",!0),e.reservationItems.length>0&&e.reservationRates&&e.reservationRates.totals&&e.reservationRates.totals.length>0?(k(),M("div",Lbe,[(k(!0),M(xe,null,Me(e.reservationItems,(Z,K)=>(k(),M("div",{key:`reservation-item-${K}`},[e.reservationRates.totals[K]?(k(),M("div",Fbe,[O[17]||(O[17]=b("hr",{class:"my-2"},null,-1)),b("div",zbe,[b("div",null,[b("div",Nbe,Q(Z.accomodation_name),1)]),e.variant==="select"?(k(),M("button",{key:0,class:pe(["font-primary text-xs text-ag-black text-right underline cursor-pointer disabled:opacity-50",{"cursor-not-allowed":e.submitting||e.loading}]),disabled:e.submitting||e.loading,onClick:fe=>$(K)},[e.removingReservationItem===K?(k(),M("span",jbe,"Removing...")):(k(),M("span",Ube,"Remove"))],10,Bbe)):X("",!0)]),b("div",null,[b("div",Vbe,[b("div",qbe,"Check-in: "+Q(P(Z.from_date)),1),b("div",Gbe,Q(T(Z)),1)]),b("div",Hbe,[b("div",Ybe,"Check-out: "+Q(P(Z.to_date)),1),b("div",Wbe,Q(e.reservationRates.totals[K].nights)+" "+Q(e.reservationRates.totals[K].nights==1?"night":"nights"),1)]),b("div",null,[b("div",Zbe,[O[16]||(O[16]=b("div",{class:"font-primary text-sm text-ag-black font-bold"},"Room Total",-1)),b("div",Kbe,Q(D(e.reservationRates.totals[K].total)),1)])])])])):X("",!0)]))),128))])):X("",!0),e.reservationItems.length>0&&e.reservationRates&&e.isBookable&&A(e.reservationRates)>0?(k(),M("div",Xbe,[O[19]||(O[19]=b("hr",{class:"my-2"},null,-1)),b("div",Jbe,[O[18]||(O[18]=b("div",{class:"font-primary text-base text-ag-black font-bold"},"Booking Total",-1)),b("div",Qbe,Q(z()),1)]),e.variant==="select"?(k(),M("button",{key:0,class:"button w-full block max-w-full text-xl",disabled:!e.isBookable||e.submitting||e.loading,onClick:O[1]||(O[1]=Z=>R.$emit("submit"))},[e.loading?(k(),M("span",t2e,"Book now")):X("",!0),e.loading?X("",!0):(k(),M("span",r2e,"Book now"))],8,e2e)):X("",!0)])):X("",!0),e.variant==="summary"?(k(),M("button",{key:5,class:"button w-full block max-w-full text-xl",disabled:!e.isBookable||e.submitting||e.loading,type:"submit"},[e.isBookable?X("",!0):(k(),M("span",n2e,"Cannot continue")),e.isBookable?(k(),M("span",a2e,"Continue to payment")):X("",!0)],8,i2e)):X("",!0),b("a",{href:e.formTerms,target:"_blank",class:"font-primary text-center text-sm block underline"},"View Terms and conditions",8,s2e)])]),O[20]||(O[20]=so('<div class="px-4 py-1 bg-gray-100 flex items-center justify-center gap-1 border-t border-black"><div class="font-primary text-center text-sm uppercase text-gray-400">Secure Payment</div><svg fill="#808080" width="1.6rem" height="1.6rem" viewBox="0 -6 36 36" xmlns="http://www.w3.org/2000/svg"><path d="m33.6 24h-31.2c-1.325 0-2.4-1.075-2.4-2.4v-19.2c0-1.325 1.075-2.4 2.4
737-2.4h31.2c1.325 0 2.4 1.075 2.4 2.4v19.2c0 1.325-1.075 2.4-2.4 2.4zm-15.76-9.238-.359 2.25c.79.338 1.709.535 2.674.535.077 0 .153-.001.229-.004h-.011c.088.005.19.008.294.008 1.109 0 2.137-.348 2.981-.941l-.017.011c.766-.568 1.258-1.469 1.258-2.485 0-.005 0-.01 0-.015v.001c0-1.1-.736-2.014-2.187-2.72-.426-.208-.79-.426-1.132-.672l.023.016c-.198-.13-.33-.345-.343-.592v-.002c.016-.26.165-.482.379-.6l.004-.002c.282-.164.62-.261.982-.261.042 0 .084.001.126.004h-.006.08c.023 0 .05-.001.077-.001.644 0 1.255.139 1.806.388l-.028-.011.234.125.359-2.171c-.675-.267-1.458-.422-2.277-.422-.016 0-.033 0-.049 0h.003c-.064-.003-.139-.005-.214-.005-1.096 0-2.112.347-2.943.937l.016-.011c-.752.536-1.237 1.404-1.237 2.386v.005c-.01 1.058.752 1.972 2.266 2.72.4.175.745.389 1.054.646l-.007-.006c.175.148.288.365.297.608v.002.002c0 .319-.19.593-.464.716l-.005.002c-.3.158-.656.25-1.034.25-.015 0-.031 0-.046 0h.002c-.022 0-.049 0-.075 0-.857 0-1.669-.19-2.397-.53l.035.015-.343-.172zm10.125 1.141h3.315q.08.343.313 1.5h2.407l-2.094-10.031h-2c-.035-.003-.076-.005-.118-.005-.562 0-1.043.348-1.239.84l-.003.009-3.84 9.187h2.72l.546-1.499zm-13.074-8.531-1.626 10.031h2.594l1.625-10.031zm-9.969 2.047 2.11 7.968h2.734l4.075-10.015h-2.746l-2.534 6.844-.266-1.391-.904-4.609c-.091-.489-.514-.855-1.023-.855-.052 0-.104.004-.154.011l.006-.001h-4.187l-.031.203c3.224.819 5.342 2.586 6.296 5.25-.309-.792-.76-1.467-1.326-2.024l-.001-.001c-.567-.582-1.248-1.049-2.007-1.368l-.04-.015zm25.937 4.421h-2.16q.219-.578 1.032-2.8l.046-.141c.042-.104.094-.24.16-.406s.11-.302.14-.406l.188.859.593 2.89z"></path></svg><svg fill="#808080" width="1.6rem" height="1.6rem" viewBox="0 -6 36 36" xmlns="http://www.w3.org/2000/svg"><path d="m33.6 24h-31.2c-1.325 0-2.4-1.075-2.4-2.4v-19.2c0-1.325 1.075-2.4 2.4-2.4h31.2c1.325 0 2.4 1.075 2.4 2.4v19.2c0 1.325-1.075 2.4-2.4 2.4zm-5.116-4.281c-.004 0-.009 0-.014 0-.288 0-.547.123-.728.319l-.001.001c-.189.208-.305.485-.305.789s.116.582.3
73706.79l-.001-.001c.182.197.441.32.729.32h.014-.001c.015.001.034.002.052.002.254 0 .479-.123.619-.312l.001-.002v.266h.453v-2.969h-.453v1.11c-.146-.191-.374-.314-.631-.314-.014 0-.028 0-.042.001zm-4.25 0c-.007 0-.015 0-.023 0-.289 0-.55.12-.735.313-.189.211-.305.49-.305.797s.116.587.306.798l-.001-.001c.186.193.447.313.736.313h.024-.001c.014.001.029.001.045.001.251 0 .473-.123.609-.312l.002-.002v.266h.47v-2.11h-.469v.25c-.143-.191-.369-.314-.623-.314-.012 0-.024 0-.035.001h.002zm-2.048 0c-.013-.001-.027-.001-.042-.001-.613 0-1.11.497-1.11 1.11s.497 1.11 1.11 1.11c.015 0 .03 0 .044-.001h-.002c.012 0 .026.001.041.001.27 0 .517-.094.712-.252l-.002.002-.219-.375c-.139.11-.315.18-.506.188h-.002c-.012.001-.027.001-.041.001-.179 0-.341-.072-.459-.189-.111-.129-.179-.299-.179-.484s.068-.355.18-.485l-.001.001c.112-.116.268-.188.441-.188h.021-.001c.207.001.397.071.549.189l-.002-.002.219-.375c-.198-.157-.451-.251-.726-.251-.008 0-.017 0-.025 0h.001zm-4.08 0c-.008 0-.016 0-.025 0-.286 0-.543.12-.725.313-.184.199-.298.466-.298.76 0 .014 0 .028.001.042v-.002c-.001.014-.001.03-.001.046 0 .295.117.563.306.759.19.189.452.305.741.305.011 0 .023 0 .034-.001h-.002c.012 0 .027.001.041.001.313 0 .599-.113.821-.3l-.002.002-.219-.343c-.162.143-.375.232-.608.234h-.001c-.016.001-.034.002-.052.002-.301 0-.55-.225-.588-.515v-.003h1.578v-.187c.001-.016.001-.034.001-.052 0-.289-.107-.553-.284-.754l.001.001c-.172-.19-.42-.309-.696-.309-.007 0-.015 0-.022 0h.001zm-3.077.063v.422h.437v.954c0 .518.247.781.734.781h.017c.202 0 .389-.06.546-.162l-.004.002-.126-.391c-.117.067-.257.107-.406.11h-.001c-.198 0-.298-.115-.298-.343v-.95h.75v-.422h-.75v-.64h-.469v.64zm-1.967 1.53-.203.36c.247.167.551.266.878.266h.03-.002c.02.001.043.002.066.002.239 0 .462-.071.649-.193l-.005.003c.156-.107.258-.285.258-.487 0-.005 0-.009 0-.014v.001c0-.352-.247-.56-.734-.625l-.218-.032c-.24-.041-.36-.114-.36-.218 0-.156.131-.234.391-.234h.005c.245 0 .475.064.674.176l-.007-.004.188-.375c-.23-.138-.508-.22-.805-.22-.019 0-.039 0-.058.001h.003c-.016-.001-.035-.001-.054-.001-.22 0-.424.071-.589.191l.003-.002c-.143.112-.234.285-.234.48v.021-.001c0 .342.247.547.734.609l.203.032c.249.042.375.115.375.219 0 .176-.16.266-.485.266-.003 0-.006 0-.009 0-.26 0-.501-.082-.698-.222l.004.003zm-1.782-1.594c-.007 0-.016 0-.025 0-.285 0-.543.12-.724.313-.185.212-.298.492-.298.797s.113.585.299.799l-.001-.001c.182.193.439.313.725.313h.026-.001c.012.001.026.001.041.001.257 0 .486-.122.631-.312l.001-.002v.266h.453v-2.11h-.453v.25c-.157-.192-.393-.313-.658-.313-.005 0-.01 0-.016 0h.001zm14.688.063v2.11h.453v-1.187c0-.362.152-.546.453-.546h.01c.099 0 .193.023.276.064l-.004-.002.14-.438c-.088-.04-.19-.063-.298-.063-.011 0-.021 0-.032.001h.002c-.005 0-.011 0-.017 0-.227 0-.425.125-.528.31l-.002.003v-.25zm-6.39 0v2.11h.469v-1.187c0-.362.152-.546.453-.546h.01c.099 0 .193.023.276.064l-.004-.002.141-.438c-.092-.04-.198-.063-.31-.063-.006 0-.012 0-.019 0h.001c-.005 0-.012 0-.018 0-.227 0-.424.125-.527.31l-.002.003v-.25zm-10.688.375c.311 0 .469.189.469.56v1.172h.469v-1.328c0-.01.001-.021.001-.033 0-.22-.087-.419-.228-.566-.159-.149-.374-.24-.609-.24-.003 0-.006 0-.009 0-.015-.001-.033-.002-.051-.002-.286 0-.538.149-.681.374l-.002.003c-.133-.227-.375-.377-.653-.377-.017 0-.035.001-.052.002h.002c-.003 0-.006 0-.009 0-.247 0-.466.123-.599.311l-.002.002v-.25h-.467v2.11h.469v-1.174c0-.373.174-.56.516-.56.311 0 .469.189.469.56v1.172h.453v-1.172c0-.374.174-.56.515-.56zm14.016-18.156c-.01 0-.021 0-.033 0-1.625 0-3.134.496-4.385 1.346l.027-.017c1.296 1.056 2.265 2.469 2.758 4.089l.016.06c.236.745.371 1.601.371 2.49 0 .879-.133 1.726-.379 2.524l.016-.06c-.504 1.678-1.477 3.087-2.766 4.118l-.016.013c1.232.832 2.751 1.328 4.385 1.328 1.12 0 2.185-.233 3.15-.653l-.051.02c1.918-.813 3.414-2.309 4.207-4.175l.019-.051c.4-.91.633-1.971.633-3.086s-.233-2.176-.653-3.136l.02.05c-.813-1.919-2.313-3.415-4.183-4.205l-.051-.019c-.907-.4-1.964-.633-3.075-.633-.004 0-.007 0-.011 0h.001zm-9.812 0c-.003 0-.007 0-.011 0-1.111 0-2.169.233-3.125.652l.05-.02c-1.923.809-3.422 2.306-4.216 4.175l-.019.051c-.4.91-.633 1.971-.633 3.086s.233 2.176.653 3.136l-.02-.05c.813 1.918 2.309 3.414 4.175 4.207l.051.019c.914.4 1.98.633 3.099.633 1.635 0 3.153-.496 4.413-1.346l-.028.018c-1.303-1.051-2.276-2.466-2.766-4.089l-.015-.059c-.229-.736-.361-1.582-.361-2.459 0-2.665 1.218-5.046 3.128-6.616l.015-.012c-1.223-.832-2.732-1.328-4.357-1.328-.012 0-.024 0-.036 0h.002zm4.906 1.703c-1.257.977-2.196 2.307-2.673 3.842l-.015.055c-.228.705-.36 1.517-.36 2.359 0 .834.129 1.637.368 2.392l-.015-.056c.489 1.591 1.432 2.921 2.677 3.879l.018.013c1.263-.971 2.206-2.301 2.681-3.837l.015-.054c.224-.699.353-1.503.353-2.337 0-.843-.132-1.654-.375-2.416l.015.056c-.492-1.59-1.431-2.92-2.67-3.884l-.018-.013zm10.546 17.797c-.005 0-.011 0-.017 0-.175 0-.333-.075-.443-.195-.112-.126-.18-.294-.18-.477s.068-.35.181-.478l-.001.001c.117-.121.28-.196.461-.196s.345.075.461.196c.111.128.179.296.179.48s-.068.352-.18.481l.001-.001c-.112.117-.27.189-.444.189-.006 0-.012 0-.018 0h.001zm-4.265 0c-.007 0-.014 0-.022 0-.17 0-.323-.072-.431-.187-.107-.131-.172-.3-.172-.484
737s.065-.353.173-.486l-.001.001c.108-.116.261-.188.431-.188h.023-.001.018c.175 0 .333.075.442.195.112.121.18.283.18.461v.02-.001c0 .008.001.018.001.027 0 .176-.065.336-.173.459l.001-.001c-.111.114-.265.184-.436.184-.011 0-.023 0-.034-.001h.002zm-12.938 0c-.009 0-.019.001-.029.001-.173 0-.329-.072-.439-.188-.107-.131-.172-.3-.172-.484s.065-.353.173-.486l-.001.001c.111-.116.267-.188.44-.188.01 0 .021 0 .031.001h-.001.023c.171 0 .325.075.43.195l.001.001c.106.13.171.297.171.48s-.065.35-.172.481l.001-.001c-.108.116-.262.188-.433.188-.007 0-.015 0-.022 0h.001zm7.297-.86h-1.093c.025-.282.26-.502.547-.502s.522.22.547.5v.002z"></path></svg></div>',1))])])}}},o2e={class:"bookings-amenities"},l2e={class:"grid grid-cols-1 md:grid-cols-2 gap-2 md:gap-4 my-8"},u2e={class:"font-primary text-ag-black-2 my-0"},c2e={class:"grid grid-cols-1 md:grid-cols-2 gap-2 md:gap-4 my-8"},d2e={class:"font-primary text-ag-black-2 my-0"},lR={__name:"BookingsAmenities",props:["amenities"],setup(e){const t=se(!1);function r(){t.value=!t.value}return(i,n)=>(k(),M("div",o2e,[n[0]||(n[0]=b("div",{class:"mt-5 mb-8 border-t border-primary"},null,-1)),n[1]||(n[1]=b("h4",{class:"text-2xl xl:text-4xl font-primary text-black my-0"},"Amenities",-1)),b("div",l2e,[(k(!0),M(xe,null,Me(e.amenities.slice(0,8),(a,s)=>(k(),M("div",{class:"flex items-center",key:s},[b("div",{class:"w-6 h-6 md:w-10 md:h-10 bg-cover bg-center mr-4",style:Qt(`background-image: url('${a.icon}')`)},null,4),b("p",u2e,Q(a.title),1)]))),128))]),b("button",{class:"button button--outline",onClick:r},"View all amenities"),t.value?(k(),Mt(Yo,{key:0,onClose:r},{default:_t(()=>[b("div",null,[b("div",c2e,[(k(!0),M(xe,null,Me(e.amenities,(a,s)=>(k(),M("div",{class:"flex items-center",key:s},[b("div",{class:"w-6 h-6 md:w-10 md:h-10 bg-cover bg-center mr-4",style:Qt(`background-image: url('${a.icon}')`)},null,4),b("p",d2e,Q(a.title),1)]))),128))])])]),_:1})):X("",!0)]))}},h2e={class:"bookings-amenities"},f2e={class:"grid grid-cols-1 md:grid-cols-2 gap-2 md:gap-4 my-8"},p2e={class:"font-primary text-ag-black-2 my-0"},m2e={class:"grid grid-cols-1 md:grid-cols-2 gap-2 md:gap-4 my-8"},g2e={class:"font-primary text-ag-black-2 my-0"},_2e={__name:"BookingsActivities",props:["activities"],setup(e){const t=se(!1);function r(){t.value=!t.value}return(i,n)=>(k(),M("div",h2e,[n[0]||(n[0]=b("div",{class:"mt-5 mb-8 border-t border-primary"},null,-1)),n[1]||(n[1]=b("h4",{class:"text-2xl xl:text-4xl font-primary text-black my-0"},"Activities & Experiences",-1)),b("div",f2e,[(k(!0),M(xe,null,Me(e.activities.slice(0,8),(a,s)=>(k(),M("div",{class:"flex items-center",key:s},[b("div",{class:"w-6 h-6 md:w-10 md:h-10 bg-cover bg-center mr-4",style:Qt(`background-image: url('${a.icon}')`)},null,4),b("p",p2e,Q(a.title),1)]))),128))]),b("button",{class:"button button--outline",onClick:r},"View all activities"),t.value?(k(),Mt(Yo,{key:0,onClose:r},{default:_t(()=>[b("div",null,[b("div",m2e,[(k(!0),M(xe,null,Me(e.activities,(a,s)=>(k(),M("div",{class:"flex items-center",key:s},[b("div",{class:"w-6 h-6 md:w-10 md:h-10 bg-cover bg-center mr-4",style:Qt(`background-image: url('${a.icon}')`)},null,4),b("p",g2e,Q(a.title),1)]))),128))])])]),_:1})):X("",!0)]))}},y2e={class:"bookings-amenities"},v2e={class:"my-8"},b2e={class:"bookings-bullet-list md:columns-2 md:gap-10"},x2e={class:"my-8"},w2e={class:"bookings-bullet-list md:columns-2 md:gap-10"},$2e={__name:"BookingsConservationImpact",props:{conservationImpact:{type:Array,default:()=>[]}},setup(e){const t=e,r=se(!1),i=H(()=>{const a=t.conservationImpact;return!Array.isArray(a)||a.length===0?[]:Array.isArray(a[0])?a[0]:a});function n(){r.value=!r.value}return(a,s)=>(k(),M("div",y2e,[s[0]||(s[0]=b("div",{class:"mt-5 mb-8 border-t border-primary"},null,-1)),s[1]||(s[1]=b("h4",{class:"text-2xl xl:text-4xl font-primary text-black my-0"},"Conservation Impact",-1)),b("div",v2e,[b("ul",b2e,[(k(!0),M(xe,null,Me(i.value.slice(0,6),(o,l)=>(k(),M("li",{key:l,class:"bookings-bullet-item font-primary text-ag-black-2 my-0"},Q(o.title),1))),128))])]),b("button",{class:"button button--outline",onClick:n},"View all impacts"),r.value?(k(),Mt(Yo,{key:0,onClose:n},{default:_t(()=>[b("div",null,[b("div",x2e,[b("ul",w2e,[(k(!0),M(xe,null,Me(i.value,(o,l)=>(k(),M("li",{key:l,class:"bookings-bullet-item font-primary text-ag-black-2 my-0"},Q(o.title),1))),128))])])])]),_:1})):X("",!0)]))}},S2e=Yt($2e,[["__scopeId","data-v-57f5d16a"]]),T2e={class:"bookings-amenities"},C2e={class:"grid grid-cols-1 md:grid-cols-2 gap-8 my-8"},k2e={key:0},E2e={class:"bookings-bullet-list space-y-1"},P2e={key:1},M2e={class:"bookings-bullet-list space-y-1"},I2e={class:"grid grid-cols-1 md:grid-cols-2 gap-8"},A2e={key:0},D2e={class:"bookings-bullet-list space-y-1"},R2e={key:1},O2e={class:"bookings-bullet-list space-y-1"},L2e={__name:"BookingsIncludesAndExcludes",props:{includes:{type:Array,default:()=>[]},excludes:{type:Array,default:()=>[]}},setup(e){const t=se(!1);function r(){t.value=!t.value}return(i,n)=>(k(),M("div",T2e,[n[4]||(n[4]=b("div",{class:"mt-5 mb-8 border-t border-primary"},null,-1)),n[5]||(n[5]=b("h4",{class:"text-2xl xl:text-4xl font-primary text-black my-0"},"Price Includes & Excludes",-1)),b("div",C2e,[e.includes.length?(k(),M("div",k2e,[n[0]||(n[0]=b("h5",{class:"text-lg font-primary text-black my-0 mb-2"},"Includes:",-1)),b("ul",E2e,[(k(!0),M(xe,null,Me(e.includes.slice(0,3),(a,s)=>(k(),M("li",{key:"inc-"+s,class:"bookings-bullet-item font-primary text-ag-black-2 my-0"},Q(a.title),1))),128))])])):X("",!0),e.excludes.length?(k(),M("div",P2e,[n[1]||(n[1]=b("h5",{class:"text-lg font-primary text-black my-0 mb-2"},"Excludes:",-1)),b("ul",M2e,[(k(!0),M(xe,null,Me(e.excludes.slice(0,3),(a,s)=>(k(),M("li",{key:"exc-"+s,class:"bookings-bullet-item font-primary text-ag-black-2 my-0"},Q(a.title),1))),128))])])):X("",!0)]),b("button",{class:"button button--outline max-w-70",onClick:r},"View all includes & excludes"),t.value?(k(),Mt(Yo,{key:0,onClose:r},{default:_t(()=>[b("div",I2e,[e.includes.length?(k(),M("div",A2e,[n[2]||(n[2]=b("h5",{class:"text-lg font-primary text-black my-0 mb-2"},"Includes:",-1)),b("ul",D2e,[(k(!0),M(xe,null,Me(e.includes,(a,s)=>(k(),M("li",{key:"m-inc-"+s,class:"bookings-bullet-item font-primary text-ag-black-2 my-0"},Q(a.title),1))),128))])])):X("",!0),e.excludes.length?(k(),M("div",R2e,[n[3]||(n[3]=b("h5",{class:"text-lg font-primary text-black my-0 mb-2"},"Excludes:",-1)),b("ul",O2e,[(k(!0),M(xe,null,Me(e.excludes,(a,s)=>(k(),M("li",{key:"m-exc-"+s,class:"bookings-bullet-item font-primary text-ag-black-2 my-0"},Q(a.title),1))),128))])])):X("",!0)])]),_:1})):X("",!0)]))}},F2e=Yt(L2e,[["__scopeId","data-v-04ed9ad1"]]);(function(){try{if(typeof document<"u"){var e=document.createElement("style");e.appendChild(document.createTextNode(".mapdiv[data-v-289550ca]{width:100%;height:100%}.advanced-marker-wrapper{display:none}.mapdiv .advanced-marker-wrapper{display:inline-block}
737.custom-control-wrapper[data-v-ab9120cd]{display:none}.mapdiv .custom-control-wrapper[data-v-ab9120cd]{display:inline-block}.info-window-wrapper[data-v-135889a7]{display:none}.mapdiv .info-window-wrapper[data-v-135889a7]{display:inline-block}.custom-marker-wrapper[data-v-2d2d343a]{display:none}.mapdiv .custom-marker-wrapper[data-v-2d2d343a]{display:inline-block}")),document.head.appendChild(e)}}catch(t){console.error("vite-plugin-css-injected-by-js",t)}})();var z2e=Object.defineProperty,N2e=(e,t,r)=>t in e?z2e(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,lk=(e,t,r)=>(N2e(e,typeof t!="symbol"?t+"":t,r),r);const uR=Symbol("map"),cR=Symbol("api"),B2e=Symbol("marker"),j2e=Symbol("markerCluster"),dR=Symbol("CustomMarker"),U2e=Symbol("mapTilesLoaded"),hR=["click","dblclick","drag","dragend","dragstart","mousedown","mousemove","mouseout","mouseover","mouseup","rightclick"];function V2e(e,t,r,i){function n(a){return a instanceof r?a:new r(function(s){s(a)})}return new(r||(r=Promise))(function(a,s){function o(c){try{u(i.next(c))}catch(d){s(d)}}function l(c){try{u(i.throw(c))}catch(d){s(d)}}function u(c){c.done?a(c.value):n(c.value).then(o,l)}u((i=i.apply(e,[])).next())})}function q2e(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var uk,ck;function G2e(){return ck||(ck=1,uk=function e(t,r){if(t===r)return!0;if(t&&r&&typeof t=="object"&&typeof r=="object"){if(t.constructor!==r.constructor)return!1;var i,n,a;if(Array.isArray(t)){if(i=t.length,i!=r.length)return!1;for(n=i;n--!==0;)if(!e(t[n],r[n]))return!1;return!0}if(t.constructor===RegExp)return t.source===r.source&&t.flags===r.flags;if(t.valueOf!==Object.prototype.valueOf)return t.valueOf()===r.valueOf();if(t.toString!==Object.prototype.toString)return t.toString()===r.toString();if(a=Object.keys(t),i=a.length,i!==Object.keys(r).length)return!1;for(n=i;n--!==0;)if(!Object.prototype.hasOwnProperty.call(r,a[n]))return!1;for(n=i;n--!==0;){var s=a[n];if(!e(t[s],r[s]))return!1}return!0}return t!==t&&r!==r}),uk}var H2e=G2e(),Y2e=q2e(H2e);const dk="__googleMapsScriptId";var $d;(function(e){e[e.INITIALIZED=0]="INITIALIZED",e[e.LOADING=1]="LOADING",e[e.SUCCESS=2]="SUCCESS",e[e.FAILURE=3]="FAILURE"})($d||($d={}));let W2e=class ud{constructor({apiKey:t,authReferrerPolicy:r,channel:i,client:n,id:a=dk,language:s,libraries:o=[],mapIds:l,nonce:u,region:c,retries:d=3,url:h="https://maps.googleapis.com/maps/api/js",version:f}){if(this.callbacks=[],this.done=!1,this.loading=!1,this.errors=[],this.apiKey=t,this.authReferrerPolicy=r,this.channel=i,this.client=n,this.id=a||dk,this.language=s,this.libraries=o,this.mapIds=l,this.nonce=u,this.region=c,this.retries=d,this.url=h,this.version=f,ud.instance){if(!Y2e(this.options,ud.instance.options))throw new Error(`Loader must not be called again with different options. ${JSON.stringify(this.options)} !== ${JSON.stringify(ud.instance.options)}`);return ud.instance}ud.instance=this}get options(){return{version:this.version,apiKey:this.apiKey,channel:this.channel,client:this.client,id:this.id,libraries:this.libraries,language:this.language,region:this.region,mapIds:this.mapIds,nonce:this.nonce,url:this.url,authReferrerPolicy:this.authReferrerPolicy}}get status(){return this.errors.length?$d.FAILURE:this.done?$d.SUCCESS:this.loading?$d.LOADING:$d.INITIALIZED}get failed(){return this.done&&!this.loading&&this.errors.length>=this.retries+1}createUrl(){let t=this.url;return t+="?callback=__googleMapsCallback&loading=async",this.apiKey&&(t+=`&key=${this.apiKey}`),this.channel&&(t+=`&channel=${this.channel}`),this.client&&(t+=`&client=${this.client}`),this.libraries.length>0&&(t+=`&libraries=${this.libraries.join(",")}`),this.language&&(t+=`&language=${this.language}`),this.region&&(t+=`®ion=${this.region}`),this.version&&(t+=`&v=${this.version}`),this.mapIds&&(t+=`&map_ids=${this.mapIds.join(",")}`),this.authReferrerPolicy&&(t+=`&auth_referrer_policy=${this.authReferrerPolicy}`),t}deleteScript(){const t=document.getElementById(this.id);t&&t.remove()}load(){return this.loadPromise()}loadPromise(){return new Promise((t,r)=>{this.loadCallback(i=>{i?r(i.error):t(window.google)})})}importLibrary(t){return this.execute(),google.maps.importLibrary(t)}loadCallback(t){this.callbacks.push(t),this.execute()}setScript(){var t,r;if(document.getElementById(this.id)){this.callback();return}const i={key:this.apiKey,channel:this.channel,client:this.client,libraries:this.libraries.length&&this.libraries,v:this.version,mapIds:this.mapIds,language:this.language,region:this.region,authReferrerPolicy:this.authReferrerPolicy};
737Object.keys(i).forEach(a=>!i[a]&&delete i[a]),!((r=(t=window==null?void 0:window.google)===null||t===void 0?void 0:t.maps)===null||r===void 0)&&r.importLibrary||(a=>{let s,o,l,u="The Google Maps JavaScript API",c="google",d="importLibrary",h="__ib__",f=document,p=window;p=p[c]||(p[c]={});const m=p.maps||(p.maps={}),g=new Set,v=new URLSearchParams,x=()=>s||(s=new Promise((_,y)=>V2e(this,void 0,void 0,function*(){var w;yield o=f.createElement("script"),o.id=this.id,v.set("libraries",[...g]+"");for(l in a)v.set(l.replace(/[A-Z]/g,$=>"_"+$[0].toLowerCase()),a[l]);v.set("callback",c+".maps."+h),o.src=this.url+"?"+v,m[h]=_,o.onerror=()=>s=y(Error(u+" could not load.")),o.nonce=this.nonce||((w=f.querySelector("script[nonce]"))===null||w===void 0?void 0:w.nonce)||"",f.head.append(o)})));m[d]?console.warn(u+" only loads once. Ignoring:",a):m[d]=(_,...y)=>g.add(_)&&x().then(()=>m[d](_,...y))})(i);const n=this.libraries.map(a=>this.importLibrary(a));n.length||n.push(this.importLibrary("core")),Promise.all(n).then(()=>this.callback(),a=>{const s=new ErrorEvent("error",{error:a});this.loadErrorCallback(s)})}reset(){this.deleteScript(),this.done=!1,this.loading=!1,this.errors=[],this.onerrorEvent=null}resetIfRetryingFailed(){this.failed&&this.reset()}loadErrorCallback(t){if(this.errors.push(t),this.errors.length<=this.retries){const r=this.errors.length*Math.pow(2,this.errors.length);console.error(`Failed to load Google Maps script, retrying in ${r} ms.`),setTimeout(()=>{this.deleteScript(),this.setScript()},r)}else this.onerrorEvent=t,this.callback()}callback(){this.done=!0,this.loading=!1,this.callbacks.forEach(t=>{t(this.onerrorEvent)}),this.callbacks=[]}execute(){if(this.resetIfRetryingFailed(),!this.loading)if(this.done)this.callback();else{if(window.google&&window.google.maps&&window.google.maps.version){console.warn("Google Maps already loaded outside @googlemaps/js-api-loader. This may result in undesirable behavior as options and script parameters may not match."),this.callback();return}this.loading=!0,this.setScript()}}};function Z2e(e){return class extends e.OverlayView{constructor(t){super(),lk(this,"element"),lk(this,"opts");const{element:r,...i}=t;this.element=r,this.opts=i,this.opts.map&&this.setMap(this.opts.map)}getPosition(){return this.opts.position?this.opts.position instanceof e.LatLng?this.opts.position:new e.LatLng(this.opts.position):null}getVisible(){if(!this.element)return!1;const t=this.element;return t.style.display!=="none"&&t.style.visibility!=="hidden"&&(t.style.opacity===""||Number(t.style.opacity)>.01)}onAdd(){if(!this.element)return;const t=this.getPanes();t&&t.overlayMouseTarget.appendChild(this.element)}draw(){if(!this.element)return;const t=this.getProjection(),r=t==null?void 0:t.fromLatLngToDivPixel(this.getPosition());if(r){this.element.style.position="absolute";let i,n;switch(this.opts.anchorPoint){case"TOP_CENTER":i="-50%",n="-100%";break;case"BOTTOM_CENTER":i="-50%",n="0";break;case"LEFT_CENTER":i="-100%",n="-50%";break;case"RIGHT_CENTER":i="0",n="-50%";break;case"TOP_LEFT":i="-100%",n="-100%";break;case"TOP_RIGHT":i="0",n="-100%";break;case"BOTTOM_LEFT":i="-100%",n="0";break;case"BOTTOM_RIGHT":i="0",n="0";break;default:i="-50%",n="-50%"}const a=r.x+(this.opts.offsetX||0)+"px",s=r.y+(this.opts.offsetY||0)+"px";this.element.style.transform=`translateX(${i}) translateX(${a}) translateY(${n}) translateY(${s})`,this.opts.zIndex&&(this.element.style.zIndex=this.opts.zIndex.toString())}}onRemove(){this.element&&this.element.remove()}setOptions(t){const{element:r,...i}=t;this.element=r,this.opts=i,this.draw()}}}let hk;const fk=["bounds_changed","center_changed","click","contextmenu","dblclick","drag","dragend","dragstart","heading_changed","idle","isfractionalzoomenabled_changed","mapcapabilities_changed","maptypeid_changed","mousemove","mouseout","mouseover","projection_changed","renderingtype_changed","rightclick","tilesloaded","tilt_changed","zoom_changed"],K2e=fr({props:{apiPromise:{type:Promise},apiKey:{type:String,default:""},version:{type:String,default:"weekly"},libraries:{type:Array,default:()=>["places","marker"]},region:{type:String,required:!1},language:{type:String,required:!1},backgroundColor:{type:String,required:!1},center:{type:Object,default:()=>({lat:0,lng:0})},clickableIcons:{type:Boolean,required:!1,default:void 0},colorScheme:{type:String,required:!1},controlSize:{type:Number,required:!1},disableDefaultUi:{type:Boolean,required:!1,default:void 0},disableDoubleClickZoom:{type:Boolean,required:!1,default:void 0},draggable:{type:Boolean,required:!1,default:void 0},draggableCursor:{type:String,required:!1},draggingCursor:{type:String,required:!1},fullscreenControl:{type:Boolean,required:!1,default:void 0},fullscreenControlPosition:{type:String,required:!1},gestureHandling:{type:String,required:!1},heading:{type:Number,required:!1},isFractionalZoomEnabled:{type:Boolean,required:!1,default:void 0},keyboardShortcuts:{type:Boolean,required:!1,default:void 0},mapTypeControl:{type:Boolean,required:!1,default:void 0},mapTypeControlOptions:{type:Object,required:!1},mapTypeId:{type:[Number,String],required:!1},mapId:{type:String,required:!1},maxZoom:{type:Number,required:!1},minZoom:{type:Number,required:!1},noClear:{type:Boolean,required:!1,default:void 0},panControl:{type:Boolean,required:!1,default:void 0},panControlPosition:{type:String,required:!1},restriction:{type:Object,required:!1},rotateControl:{type:Boolean,required:!1,default:void 0},rotateControlPosition:{type:String,required:!1},scaleControl:{type:Boolean,required:!1,default:void 0},scaleControlStyle:{type:Number,required:!1},scrollwheel:{type:Boolean,required:!1,default:void 0},streetView:{type:Object,required:!1},streetViewControl:{type:Boolean,required:!1,default:void 0},streetViewControlPosition:{type:String,required:!1},styles:{type:Array,required:!1},tilt:{type:Number,required:!1},zoom:{type:Number,required:!1},zoomControl:{type:Boolean,required:!1,default:void 0},zoomControlPosition:{type:String,required:!1},cameraControl:{type:Boolean,required:!1,default:void 0},cameraControlPosition:{type:String,required:!1},nonce:{type:String,default:""}},emits:fk,setup(e,{emit:t}){const r=se(),i=se(!1),n=se(),a=se(),s=se(!1);xa(uR,n),xa(cR,a),xa(U2e,s);const o=()=>{const d={...e};
737Object.keys(d).forEach(p=>{d[p]===void 0&&delete d[p]});const h=p=>{var m;return p?{position:(m=a.value)==null?void 0:m.ControlPosition[p]}:{}},f={scaleControlOptions:e.scaleControlStyle?{style:e.scaleControlStyle}:{},panControlOptions:h(e.panControlPosition),zoomControlOptions:h(e.zoomControlPosition),rotateControlOptions:h(e.rotateControlPosition),streetViewControlOptions:h(e.streetViewControlPosition),fullscreenControlOptions:h(e.fullscreenControlPosition),cameraControlOptions:h(e.cameraControlPosition),disableDefaultUI:e.disableDefaultUi};return{...d,...f}},l=tt([a,n],([d,h])=>{const f=d,p=h;f&&p&&(f.event.addListenerOnce(p,"tilesloaded",()=>{s.value=!0}),setTimeout(l,0))},{immediate:!0}),u=()=>{try{const{apiKey:d,region:h,version:f,language:p,libraries:m,nonce:g}=e;hk=new W2e({apiKey:d,region:h,version:f,language:p,libraries:m,nonce:g})}catch(d){console.error(d)}},c=d=>{a.value=mc(d.maps),n.value=mc(new d.maps.Map(r.value,o()));const h=Z2e(a.value);a.value[dR]=h,fk.forEach(p=>{var m;(m=n.value)==null||m.addListener(p,g=>t(p,g))}),i.value=!0;const f=Object.keys(e).filter(p=>!["apiPromise","apiKey","version","libraries","region","language","center","zoom","nonce"].includes(p)).map(p=>Wu(e,p));tt([()=>e.center,()=>e.zoom,...f],([p,m],[g,v])=>{var x,_,y;const{center:w,zoom:$,...S}=o();(x=n.value)==null||x.setOptions(S),m!==void 0&&m!==v&&((_=n.value)==null||_.setZoom(m));const E=!g||p.lng!==g.lng||p.lat!==g.lat;p&&E&&((y=n.value)==null||y.panTo(p))})};return or(()=>{e.apiPromise&&e.apiPromise instanceof Promise?e.apiPromise.then(c):(u(),hk.load().then(c))}),ra(()=>{var d;s.value=!1,n.value&&((d=a.value)==null||d.event.clearInstanceListeners(n.value))}),{mapRef:r,ready:i,map:n,api:a,mapTilesLoaded:s}}}),X2e=(e,t)=>{const r=e.__vccOpts||e;for(const[i,n]of t)r[i]=n;return r},J2e={ref:"mapRef",class:"mapdiv"};function Q2e(e,t,r,i,n,a){return k(),M("div",null,[b("div",J2e,null,512),ws(e.$slots,"default",Gu(nh({ready:e.ready,map:e.map,api:e.api,mapTilesLoaded:e.mapTilesLoaded})),void 0,!0)])}const exe=X2e(K2e,[["render",Q2e],["__scopeId","data-v-289550ca"]]);function txe(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var rxe=function e(t,r){if(t===r)return!0;if(t&&r&&typeof t=="object"&&typeof r=="object"){if(t.constructor!==r.constructor)return!1;var i,n,a;if(Array.isArray(t)){if(i=t.length,i!=r.length)return!1;for(n=i;n--!==0;)if(!e(t[n],r[n]))return!1;return!0}if(t.constructor===RegExp)return t.source===r.source&&t.flags===r.flags;if(t.valueOf!==Object.prototype.valueOf)return t.valueOf()===r.valueOf();if(t.toString!==Object.prototype.toString)return t.toString()===r.toString();if(a=Object.keys(t),i=a.length,i!==Object.keys(r).length)return!1;for(n=i;n--!==0;)if(!Object.prototype.hasOwnProperty.call(r,a[n]))return!1;for(n=i;n--!==0;){var s=a[n];if(!e(t[s],r[s]))return!1}return!0}return t!==t&&r!==r};const ixe=txe(rxe),nxe=(e,t,r,i)=>{const n=se(),a=Gi(uR,se()),s=Gi(cR,se()),o=Gi(j2e,se()),l=H(()=>!!(o.value&&s.value&&(n.value instanceof s.value.Marker||n.value instanceof s.value[dR])));return tt([a,r],(u,[c,d])=>{var h,f,p;const m=!ixe(r.value,d)||a.value!==c;!a.value||!s.value||!m||(n.value?(n.value.setOptions(r.value),l.value&&((h=o.value)==null||h.removeMarker(n.value),(f=o.value)==null||f.addMarker(n.value))):(n.value=mc(new s.value[e](r.value)),n.value&&(l.value?(p=o.value)==null||p.addMarker(n.value):n.value.setMap(a.value)),t.forEach(g=>{var v;(v=n.value)==null||v.addListener(g,x=>i(g,x))})))},{immediate:!0,flush:"post"}),ra(()=>{var u,c;n.value&&((u=s.value)==null||u.event.clearInstanceListeners(n.value),l.value?(c=o.value)==null||c.removeMarker(n.value):n.value.setMap(null))}),n},pk=["animation_changed","click","dblclick","rightclick","dragstart","dragend","drag","mouseover","mousedown","mouseout","mouseup","draggable_changed","clickable_changed","contextmenu","cursor_changed","flat_changed","zindex_changed","icon_changed","position_changed","shape_changed","title_changed","visible_changed"],axe=fr({name:"Marker",props:{options:{type:Object,required:!0}},emits:pk,setup(e,{emit:t,expose:r,slots:i}){const n=Wu(e,"options"),a=nxe("Marker",pk,n,t);return xa(B2e,a),r({marker:a}),()=>{var s;return(s=i.default)==null?void 0:s.call(i)}}});hR.concat(["bounds_changed"]);
737hR.concat(["center_changed","radius_changed"]);var sxe=Object.getOwnPropertyNames,oxe=Object.getOwnPropertySymbols,lxe=Object.prototype.hasOwnProperty;function mk(e,t){return function(r,i,n){return e(r,i,n)&&t(r,i,n)}}function l0(e){return function(t,r,i){if(!t||!r||typeof t!="object"||typeof r!="object")return e(t,r,i);var n=i.cache,a=n.get(t),s=n.get(r);if(a&&s)return a===r&&s===t;n.set(t,r),n.set(r,t);var o=e(t,r,i);return n.delete(t),n.delete(r),o}}function gk(e){return sxe(e).concat(oxe(e))}var uxe=Object.hasOwn||function(e,t){return lxe.call(e,t)};function Fc(e,t){return e===t||!e&&!t&&e!==e&&t!==t}var cxe="__v",dxe="__o",hxe="_owner",_k=Object.getOwnPropertyDescriptor,yk=Object.keys;function fxe(e,t,r){var i=e.length;if(t.length!==i)return!1;for(;i-- >0;)if(!r.equals(e[i],t[i],i,i,e,t,r))return!1;return!0}function pxe(e,t){return Fc(e.getTime(),t.getTime())}function mxe(e,t){return e.name===t.name&&e.message===t.message&&e.cause===t.cause&&e.stack===t.stack}function gxe(e,t){return e===t}function vk(e,t,r){var i=e.size;if(i!==t.size)return!1;if(!i)return!0;for(var n=new Array(i),a=e.entries(),s,o,l=0;(s=a.next())&&!s.done;){for(var u=t.entries(),c=!1,d=0;(o=u.next())&&!o.done;){if(n[d]){d++;continue}var h=s.value,f=o.value;if(r.equals(h[0],f[0],l,d,e,t,r)&&r.equals(h[1],f[1],h[0],f[0],e,t,r)){c=n[d]=!0;break}d++}if(!c)return!1;l++}return!0}var _xe=Fc;function yxe(e,t,r){var i=yk(e),n=i.length;if(yk(t).length!==n)return!1;for(;n-- >0;)if(!fR(e,t,r,i[n]))return!1;return!0}function $f(e,t,r){var i=gk(e),n=i.length;if(gk(t).length!==n)return!1;for(var a,s,o;n-- >0;)if(a=i[n],!fR(e,t,r,a)||(s=_k(e,a),o=_k(t,a),(s||o)&&(!s||!o||s.configurable!==o.configurable||s.enumerable!==o.enumerable||s.writable!==o.writable)))return!1;return!0}function vxe(e,t){return Fc(e.valueOf(),t.valueOf())}function bxe(e,t){return e.source===t.source&&e.flags===t.flags}function bk(e,t,r){var i=e.size;if(i!==t.size)return!1;if(!i)return!0;for(var n=new Array(i),a=e.values(),s,o;(s=a.next())&&!s.done;){for(var l=t.values(),u=!1,c=0;(o=l.next())&&!o.done;){if(!n[c]&&r.equals(s.value,o.value,s.value,o.value,e,t,r)){u=n[c]=!0;break}c++}if(!u)return!1}return!0}function xxe(e,t){var r=e.length;if(t.length!==r)return!1;for(;r-- >0;)if(e[r]!==t[r])return!1;return!0}function wxe(e,t){return e.hostname===t.hostname&&e.pathname===t.pathname&&e.protocol===t.protocol&&e.port===t.port&&e.hash===t.hash&&e.username===t.username&&e.password===t.password}function fR(e,t,r,i){return(i===hxe||i===dxe||i===cxe)&&(e.$$typeof||t.$$typeof)?!0:uxe(t,i)&&r.equals(e[i],t[i],i,i,e,t,r)}var $xe="[object Arguments]",Sxe="[object Boolean]",Txe="[object Date]",Cxe="[object Error]",kxe="[object Map]",Exe="[object Number]",Pxe="[object Object]",Mxe="[object RegExp]",Ixe="[object Set]",Axe="[object String]",Dxe="[object URL]",Rxe=Array.isArray,xk=typeof ArrayBuffer=="function"&&ArrayBuffer.isView?ArrayBuffer.isView:null,wk=Object.assign,Oxe=Object.prototype.toString.call.bind(Object.prototype.toString);function Lxe(e){var t=e.areArraysEqual,r=e.areDatesEqual,i=e.areErrorsEqual,n=e.areFunctionsEqual,a=e.areMapsEqual,s=e.areNumbersEqual,o=e.areObjectsEqual,l=e.arePrimitiveWrappersEqual,u=e.areRegExpsEqual,c=e.areSetsEqual,d=e.areTypedArraysEqual,h=e.areUrlsEqual;return function(f,p,m){if(f===p)return!0;if(f==null||p==null)return!1;var g=typeof f;if(g!==typeof p)return!1;if(g!=="object")return g==="number"?s(f,p,m):g==="function"?n(f,p,m):!1;var v=f.constructor;if(v!==p.constructor)return!1;if(v===Object)return o(f,p,m);if(Rxe(f))return t(f,p,m);if(xk!=null&&xk(f))return d(f,p,m);if(v===Date)return r(f,p,m);if(v===RegExp)return u(f,p,m);if(v===Map)return a(f,p,m);if(v===Set)return c(f,p,m);var x=Oxe(f);return x===Txe?r(f,p,m):x===Mxe?u(f,p,m):x===kxe?a(f,p,m):x===Ixe?c(f,p,m):x===Pxe?typeof f.then!="function"&&typeof p.then!="function"&&o(f,p,m):x===Dxe?h(f,p,m):x===Cxe?i(f,p,m):x===$xe?o(f,p,m):x===Sxe||x===Exe||x===Axe?l(f,p,m):!1}}function Fxe(e){var t=e.circular,r=e.createCustomConfig,i=e.strict,n={areArraysEqual:i?$f:fxe,areDatesEqual:pxe,areErrorsEqual:mxe,areFunctionsEqual:gxe,areMapsEqual:i?mk(vk,$f):vk,areNumbersEqual:_xe,areObjectsEqual:i?$f:yxe,arePrimitiveWrappersEqual:vxe,areRegExpsEqual:bxe,areSetsEqual:i?mk(bk,$f):bk,areTypedArraysEqual:i?$f:xxe,areUrlsEqual:wxe};if(r&&(n=wk({},n,r(n))),t){var a=l0(n.areArraysEqual),s=l0(n.areMapsEqual),o=l0(n.areObjectsEqual),l=l0(n.areSetsEqual);n=wk({},n,{areArraysEqual:a,areMapsEqual:s,areObjectsEqual:o,areSetsEqual:l})}return n}function zxe(e){return function(t,r,i,n,a,s,o){return e(t,r,o)}}
737function Nxe(e){var t=e.circular,r=e.comparator,i=e.createState,n=e.equals,a=e.strict;if(i)return function(o,l){var u=i(),c=u.cache,d=c===void 0?t?new WeakMap:void 0:c,h=u.meta;return r(o,l,{cache:d,equals:n,meta:h,strict:a})};if(t)return function(o,l){return r(o,l,{cache:new WeakMap,equals:n,meta:void 0,strict:a})};var s={cache:void 0,equals:n,meta:void 0,strict:a};return function(o,l){return r(o,l,s)}}gu();gu({strict:!0});gu({circular:!0});gu({circular:!0,strict:!0});gu({createInternalComparator:function(){return Fc}});gu({strict:!0,createInternalComparator:function(){return Fc}});gu({circular:!0,createInternalComparator:function(){return Fc}});gu({circular:!0,createInternalComparator:function(){return Fc},strict:!0});function gu(e){e===void 0&&(e={});var t=e.circular,r=t===void 0?!1:t,i=e.createInternalComparator,n=e.createState,a=e.strict,s=a===void 0?!1:a,o=Fxe(e),l=Lxe(o),u=i?i(l):zxe(l);return Nxe({circular:r,comparator:l,createState:n,equals:u,strict:s})}var Lx;(function(e){e.CLUSTERING_BEGIN="clusteringbegin",e.CLUSTERING_END="clusteringend",e.CLUSTER_CLICK="click",e.GMP_CLICK="gmp-click"})(Lx||(Lx={}));Object.values(Lx);const Bxe={class:"bookings-map"},jxe={class:"font-primary text-ag-black-2 mb-4"},Uxe={__name:"BookingsMap",props:["map"],setup(e){return(t,r)=>(k(),M("div",Bxe,[r[0]||(r[0]=b("div",{class:"mt-5 mb-8 border-t border-primary"},null,-1)),r[1]||(r[1]=b("h4",{class:"text-2xl xl:text-4xl font-primary text-black my-0"},"Where you'll be",-1)),b("p",jxe,Q(e.map.address),1),be(le(exe),{center:{lat:parseFloat(e.map.latitude),lng:parseFloat(e.map.longitude)},zoom:7,mapTypeId:"terrain",class:"w-full h-96","api-key":"AIzaSyDb0lkdsaJHPfexoYUC7dC8DMUgt1Xv6KA"},{default:_t(()=>[be(le(axe),{options:{position:{lat:parseFloat(e.map.latitude),lng:parseFloat(e.map.longitude)},icon:"/img/marker.svg"}},null,8,["options"])]),_:1},8,["center"])]))}},Vxe={class:"bookings-contact-form mt-6"},qxe={class:"grid grid-cols-1 md:grid-cols-2 gap-4"},Gxe={class:"mb-4"},Hxe={for:"first_name"},Yxe={key:0,class:"text-red-500"},Wxe={class:"mb-4"},Zxe={for:"last_name"},Kxe={key:0,class:"text-red-500"},Xxe={class:"grid grid-cols-1 md:grid-cols-2 gap-4"},Jxe={class:"mb-4"},Qxe={for:"email"},ewe={key:0,class:"text-red-500"},twe={class:"mb-4"},rwe={for:"confirm_email"},iwe={key:0,class:"text-red-500"},nwe={class:"grid grid-cols-1 md:grid-cols-2 gap-4"},awe={class:"mb-4"},swe={for:"country"},owe=["value"],lwe={key:0,class:"text-red-500"},uwe={class:"mb-4"},cwe={for:"phone"},dwe={class:"form-control p-0"},hwe={key:0,class:"text-red-500"},fwe={class:"mb-4"},pwe={for:"requests"},mwe={key:0,class:"text-red-500"},gwe={__name:"BookingsContactForm",props:["booking","errors"],setup(e){const t=[{name:"Afghanistan",code:"AF"},{name:"Ã
land Islands",code:"AX"},{name:"Albania",code:"AL"},{name:"Algeria",code:"DZ"},{name:"American Samoa",code:"AS"},{name:"AndorrA",code:"AD"},{name:"Angola",code:"AO"},{name:"Anguilla",code:"AI"},{name:"Antarctica",code:"AQ"},{name:"Antigua and Barbuda",code:"AG"},{name:"Argentina",code:"AR"},{name:"Armenia",code:"AM"},{name:"Aruba",code:"AW"},{name:"Australia",code:"AU"},{name:"Austria",code:"AT"},{name:"Azerbaijan",code:"AZ"},{name:"Bahamas",code:"BS"},{name:"Bahrain",code:"BH"},{name:"Bangladesh",code:"BD"},{name:"Barbados",code:"BB"},{name:"Belarus",code:"BY"},{name:"Belgium",code:"BE"},{name:"Belize",code:"BZ"},{name:"Benin",code:"BJ"},{name:"Bermuda",code:"BM"},{name:"Bhutan",code:"BT"},{name:"Bolivia",code:"BO"},{name:"Bosnia and Herzegovina",code:"BA"},{name:"Botswana",code:"BW"},{name:"Bouvet Island",code:"BV"},{name:"Brazil",code:"BR"},{name:"British Indian Ocean Territory",code:"IO"},{name:"Brunei Darussalam",code:"BN"},{name:"Bulgaria",code:"BG"},{name:"Burkina Faso",code:"BF"},{name:"Burundi",code:"BI"},{name:"Cambodia",code:"KH"},{name:"Cameroon",code:"CM"},{name:"Canada",code:"CA"},{name:"Cape Verde",code:"CV"},{name:"Cayman Islands",code:"KY"},{name:"Central African Republic",code:"CF"},{name:"Chad",code:"TD"},{name:"Chile",code:"CL"},{name:"China",code:"CN"},{name:"Christmas Island",code:"CX"},{name:"Cocos (Keeling) Islands",code:"CC"},{name:"Colombia",code:"CO"},{name:"Comoros",code:"KM"},{name:"Congo",code:"CG"},{name:"Congo, The Democratic Republic of the",code:"CD"},{name:"Cook Islands",code:"CK"},{name:"Costa Rica",code:"CR"},{name:"Croatia",code:"HR"},{name:"Cuba",code:"CU"},{name:"Cyprus",code:"CY"},{name:"Czech Republic",code:"CZ"},{name:"Denmark",code:"DK"},{name:"Djibouti",code:"DJ"},{name:"Dominica",code:"DM"},{name:"Dominican Republic",code:"DO"},{name:"Ecuador",code:"EC"},{name:"Egypt",code:"EG"},{name:"El Salvador",code:"SV"},{name:"Equatorial Guinea",code:"GQ"},{name:"Eritrea",code:"ER"},{name:"Estonia",code:"EE"},{name:"Ethiopia",code:"ET"},{name:"Falkland Islands (Malvinas)",code:"FK"},{name:"Faroe Islands",code:"FO"},{name:"Fiji",code:"FJ"},{name:"Finland",code:"FI"},{name:"France",code:"FR"},{name:"French Guiana",code:"GF"},{name:"French Polynesia",code:"PF"},{name:"French Southern Territories",code:"TF"},{name:"Gabon",code:"GA"},{name:"Gambia",code:"GM"},{name:"Georgia",code:"GE"},{name:"Germany",code:"DE"},{name:"Ghana",code:"GH"},{name:"Gibraltar",code:"GI"},{name:"Greece",code:"GR"},{name:"Greenland",code:"GL"},{name:"Grenada",code:"GD"},{name:"Guadeloupe",code:"GP"},{name:"Guam",code:"GU"},{name:"Guatemala",code:"GT"},{name:"Guernsey",code:"GG"},{name:"Guinea",code:"GN"},{name:"Guinea-Bissau",code:"GW"},{name:"Guyana",code:"GY"},{name:"Haiti",code:"HT"},{name:"Heard Island and Mcdonald Islands",code:"HM"},{name:"Holy See (Vatican City State)",code:"VA"},{name:"Honduras",code:"HN"},{name:"Hong Kong",code:"HK"},{name:"Hungary",code:"HU"},{name:"Iceland",code:"IS"},{name:"India",code:"IN"},{name:"Indonesia",code:"ID"}
737,{name:"Iran, Islamic Republic Of",code:"IR"},{name:"Iraq",code:"IQ"},{name:"Ireland",code:"IE"},{name:"Isle of Man",code:"IM"},{name:"Israel",code:"IL"},{name:"Italy",code:"IT"},{name:"Jamaica",code:"JM"},{name:"Japan",code:"JP"},{name:"Jersey",code:"JE"},{name:"Jordan",code:"JO"},{name:"Kazakhstan",code:"KZ"},{name:"Kenya",code:"KE"},{name:"Kiribati",code:"KI"},{name:"Korea, Republic of",code:"KR"},{name:"Kuwait",code:"KW"},{name:"Kyrgyzstan",code:"KG"},{name:"Latvia",code:"LV"},{name:"Lebanon",code:"LB"},{name:"Lesotho",code:"LS"},{name:"Liberia",code:"LR"},{name:"Libyan Arab Jamahiriya",code:"LY"},{name:"Liechtenstein",code:"LI"},{name:"Lithuania",code:"LT"},{name:"Luxembourg",code:"LU"},{name:"Macao",code:"MO"},{name:"North Macedonia",code:"MK"},{name:"Madagascar",code:"MG"},{name:"Malawi",code:"MW"},{name:"Malaysia",code:"MY"},{name:"Maldives",code:"MV"},{name:"Mali",code:"ML"},{name:"Malta",code:"MT"},{name:"Marshall Islands",code:"MH"},{name:"Martinique",code:"MQ"},{name:"Mauritania",code:"MR"},{name:"Mauritius",code:"MU"},{name:"Mayotte",code:"YT"},{name:"Mexico",code:"MX"},{name:"Micronesia, Federated States of",code:"FM"},{name:"Moldova, Republic of",code:"MD"},{name:"Monaco",code:"MC"},{name:"Mongolia",code:"MN"},{name:"Montserrat",code:"MS"},{name:"Morocco",code:"MA"},{name:"Mozambique",code:"MZ"},{name:"Myanmar",code:"MM"},{name:"Namibia",code:"NA"},{name:"Nauru",code:"NR"},{name:"Nepal",code:"NP"},{name:"Netherlands",code:"NL"},{name:"Netherlands Antilles",code:"AN"},{name:"New Caledonia",code:"NC"},{name:"New Zealand",code:"NZ"},{name:"Nicaragua",code:"NI"},{name:"Niger",code:"NE"},{name:"Nigeria",code:"NG"},{name:"Niue",code:"NU"},{name:"Norfolk Island",code:"NF"},{name:"Northern Mariana Islands",code:"MP"},{name:"Norway",code:"NO"},{name:"Oman",code:"OM"},{name:"Pakistan",code:"PK"},{name:"Palau",code:"PW"},{name:"Palestinian Territory, Occupied",code:"PS"},{name:"Panama",code:"PA"},{name:"Papua New Guinea",code:"PG"},{name:"Paraguay",code:"PY"},{name:"Peru",code:"PE"},{name:"Philippines",code:"PH"},{name:"Pitcairn Islands",code:"PN"},{name:"Poland",code:"PL"},{name:"Portugal",code:"PT"},{name:"Puerto Rico",code:"PR"},{name:"Qatar",code:"QA"},{name:"Reunion",code:"RE"},{name:"Romania",code:"RO"},{name:"Russian Federation",code:"RU"},{name:"Rwanda",code:"RW"},{name:"Saint Helena",code:"SH"},{name:"Saint Kitts and Nevis",code:"KN"},{name:"Saint Lucia",code:"LC"},{name:"Saint Pierre and Miquelon",code:"PM"},{name:"Saint Vincent and the Grenadines",code:"VC"},{name:"Samoa",code:"WS"},{name:"San Marino",code:"SM"},{name:"Sao Tome and Principe",code:"ST"},{name:"Saudi Arabia",code:"SA"},{name:"Senegal",code:"SN"},{name:"Serbia and Montenegro",code:"CS"},{name:"Seychelles",code:"SC"},{name:"Sierra Leone",code:"SL"},{name:"Singapore",code:"SG"},{name:"Slovakia",code:"SK"},{name:"Slovenia",code:"SI"},{name:"Solomon Islands",code:"SB"},{name:"Somalia",code:"SO"},{name:"South Africa",code:"ZA"},{name:"South Georgia and the South Sandwich Islands",code:"GS"},{name:"Spain",code:"ES"},{name:"Sri Lanka",code:"LK"},{name:"Sudan",code:"SD"},{name:"Suriname",code:"SR"},{name:"Svalbard and Jan Mayen",code:"SJ"},{name:"Swaziland",code:"SZ"},{name:"Sweden",code:"SE"},{name:"Switzerland",code:"CH"},{name:"Syrian Arab Republic",code:"SY"},{name:"Taiwan",code:"TW"},{name:"Tajikistan",code:"TJ"},{name:"Tanzania, United Republic of",code:"TZ"},{name:"Thailand",code:"TH"},{name:"Timor-Leste",code:"TL"},{name:"Togo",code:"TG"},{name:"Tokelau",code:"TK"},{name:"Tonga",code:"TO"},{name:"Trinidad and Tobago",code:"TT"},{name:"Tunisia",code:"TN"},{name:"Turkey",code:"TR"},{name:"Turkmenistan",code:"TM"},{name:"Turks and Caicos Islands",code:"TC"},{name:"Tuvalu",code:"TV"},{name:"Uganda",code:"UG"},{name:"Ukraine",code:"UA"},{name:"United Arab Emirates",code:"AE"},{name:"United Kingdom",code:"GB"},{name:"United States",code:"US"},{name:"United States Minor Outlying Islands",code:"UM"},{name:"Uruguay",code:"UY"},{name:"Uzbekistan",code:"UZ"},{name:"Vanuatu",code:"VU"},{name:"Venezuela",code:"VE"},{name:"Vietnam",code:"VN"},{name:"Virgin Islands, British",code:"VG"},{name:"Virgin Islands, U.S.",code:"VI"},{name:"Wallis and Futuna",code:"WF"},{name:"Western Sahara",code:"EH"},{name:"Yemen",code:"YE"},{name:"Zambia",code:"ZM"},{name:"Zimbabwe",code:"ZN"}];return(r,i)=>{const n=qr("vue-tel-input");return k(),M("div",Vxe,[b("div",qxe,[b("div",Gxe,[b("label",Hxe,[i[7]||(i[7]=b("div",{class:"form-label font-bold"},[Ze("First name "),b("span",{class:"text-red-500"},"*")],-1)),it(b("input",{"onUpdate:modelValue":i[0]||(i[0]=a=>e.booking.first_name=a),type:"text",required:"required",placeholder:"First name",name:"first_name",class:"form-control"},null,512),[[ui,e.booking.first_name]]),e.errors.first_name?(k(),M("p",Yxe,Q(e.errors.first_name[0]),1)):X("",!0)])]),b("div",Wxe,[b("label",Zxe,[i[8]||(i[8]=b("div",{class:"form-label font-bold"},[Ze("Last name "),b("span",{class:"text-red-500"},"*")],-1)),it(b("input",{"onUpdate:modelValue":i[1]||(i[1]=a=>e.booking.last_name=a),type:"text",required:"required",placeholder:"Last name",name:"last_name",class:"form-control"},null,512),[[ui,e.booking.last_name]]),e.errors.last_name?(k(),M("p",Kxe,Q(e.errors.last_name[0]),1)):X("",!0)])])]),b("div",Xxe,[b("div",Jxe,[b("label",Qxe,[i[9]||(i[9]=b("div",{class:"form-label font-bold"},[Ze("E-mail "),b("span",{class:"text-red-500"},"*")],-1)),it(b("input",{"onUpdate:modelValue":i[2]||(i[2]=a=>e.booking.email=a),type:"email",required:"required",placeholder:"E-mail",name:"email",class:"form-control"},null,512),[[ui,e.booking.email]]),e.errors.email?(k(),M("p",ewe,Q(e.errors.email[0]),1)):X("",!0)])]),b("div",twe,[b("label",rwe,[i[10]||(i[10]=b("div",{class:"form-label font-bold"},[Ze("Confirm e-mail "),b("span",{class:"text-red-500"},"*")],-1)),it(b("input",{"onUpdate:modelValue":i[3]||(i[3]=a=>e.booking.confirm_email=a),type:"email",required:"required",placeholder:"E-mail",name:"confirm_email",class:"form-control"},null,512),[[ui,e.booking.confirm_email]]),e.errors.confirm_email?(k(),M("p",iwe,Q(e.errors.confirm_email[0]),1)):X("",!0)])])]),b("div",nwe,[b("div",awe,[b("label",swe,[i[12]||(i[12]=b("div",{class:"form-label font-bold"},[Ze("Home country "),b("span",{class:"text-red-500"},"*")],-1)),it(b("select",{"onUpdate:modelValue":i[4]||(i[4]=a=>e.booking.country=a),placeholder:"Select country",required:"required",name:"country",class:"form-control border border-gray-300 focus:",style:{"min-height":"40px"}},[i[11]||(i[11]=b("option",{value:""},"Select country",-1)),(k(),M(xe,null,Me(t,a=>b("option",{value:a.name},Q(a.name),9,owe)),64))],512),[[Yl,e.booking.country]]),e.errors.country?(k(),M("p",lwe,Q(e.errors.country[0]),1)):X("",!0)])]),b("div",uwe,[b("label",cwe,[i[13]||(i[13]=b("div",{class:"form-label font-bold"},[Ze("Phone "),b("span",{class:"text-red-500"},"*")],-1)),b("div",dwe,[be(n,{defaultCountry:"US",mode:"international",autoFormat:!0,inputOptions:{placeholder:"Phone",required:!0},modelValue:e.booking.phone,"onUpdate:modelValue":i[5]||(i[5]=a=>e.booking.phone=a)},null,8,["modelValue"])]),e.errors.phone?(k(),M("p",hwe,Q(e.errors.phone[0]),1)):X("",!0)])])]),b("div",fwe,[b("label",pwe,[i[14]||(i[14]=b("div",{class:"form-label font-bold"}
737,"Do you have any special requests?",-1)),it(b("textarea",{"onUpdate:modelValue":i[6]||(i[6]=a=>e.booking.requests=a),placeholder:"Enter your requests",name:"requests",class:"form-control"},null,512),[[ui,e.booking.requests]]),e.errors.requests?(k(),M("p",mwe,Q(e.errors.requests[0]),1)):X("",!0)])])])}}},_we={class:"bookings-container"},ywe={class:"grid grid-cols-1 md:grid-cols-5 gap-20"},vwe={class:"col-span-3"},bwe={class:"mb-8"},xwe=["innerHTML"],wwe={id:"calendar"},$we={key:0,class:"font-primary text-ag-black-2 mb-4"},Swe={key:1,class:"font-primary text-ag-black-2 mb-4"},Twe={key:2,class:"bg-red-500 rounded-lg p-3 mb-4"},Cwe={class:"font-primary text-white mb-0"},kwe={key:3,class:"bg-green-500 rounded-lg p-3 mb-4"},Ewe={class:"font-primary text-white mb-0"},Pwe={key:4},Mwe={class:"mt-2 block md:hidden"},Iwe={key:5},Awe={key:0,id:"includes-and-excludes"},Dwe={id:"amenities"},Rwe={id:"amenities"},Owe={key:1,id:"conservation-impact"},Lwe={class:"col-span-2 hidden md:block"},Fwe={id:"map",class:"w-full"},zwe={class:"text-2xl font-primary text-black"},Nwe={class:"font-primary text-ag-black-2 whitespace-pre-wrap"},Bwe={class:"flex justify-center items-center gap-4 mt-8 w-full"},jwe={class:"text-2xl font-primary text-black"},Uwe=["innerHTML"],Vwe={class:"grid grid-cols-1 md:grid-cols-3 gap-2 mt-4"},qwe=["title"],Gwe={class:"grid grid-cols-1 md:grid-cols-5 gap-8"},Hwe={class:"col-span-3"},Ywe={class:"col-span-2"},Wwe={__name:"BookingsContainer",props:["includes","excludes","amenities","activities","conservationImpact","form-terms","description","linkId","propertyId","bookingPageId","unitDetails","remoteWarning","remoteWarningDescription","map","title","isAfricanParks"],setup(e){ut.extend(sR);const t=e,r=se(!1),i=se(null),n=se(null),a=se(!0),s=se(!0),o=se(!1),l=se(null),u=se(null),c=se(null),d=se(null),h=se(null),f=se(!1),p=se(!1),m=se(!1),g=se({}),v=se(ut().add(1,"year").format("YYYY-MM-DD")),x=se({start:ut().add(1,"day"),end:ut().add(2,"day")}),_=se(!1),y=se({roomType:null,guests:[],first_name:"",last_name:"",email:"",confirm_email:"",country:"",phone:"",requests:""}),w=se([]),$=se(0),S=se({}),E=se({}),C=se(["RS1","RS2","RS3"]),I=H(()=>{const G=x.value;return{start:G.start.toDate(),end:G.end.toDate()}}),P=H(()=>{var ie,U,ne,me,J;const G=[];return((ne=Object.keys(((U=(ie=u.value)==null?void 0:ie.stock)==null?void 0:U.total)||{}))==null?void 0:ne.length)>0&&Object.keys((J=(me=u.value)==null?void 0:me.stock)==null?void 0:J.total).forEach(N=>{var te,ee,oe;const q={provisional:parseInt(((te=u.value.stock)==null?void 0:te.provisional[N])||0),allocation:parseInt(((ee=u.value.stock)==null?void 0:ee.allocation[N])||0),total:parseInt(((oe=u.value.stock)==null?void 0:oe.total[N])||0)};q.available=q.total-q.provisional-q.allocation,q.available<=0&&G.push(N)}),G}),T=H(()=>P.value.map((G,ie,U)=>ut(G).format("YYYY-MM-DD")>ut().add(1,"day").format("YYYY-MM-DD")&&ie===0||ut(U[ie-1]).add(1,"day").format("YYYY-MM-DD")!==ut(G).format("YYYY-MM-DD")?ut(G).format("YYYY-MM-DD"):null).filter(Boolean)),D=H(()=>P.value.map((G,ie,U)=>T.value.includes(ut(G).format("YYYY-MM-DD"))?null:ut(G).format("YYYY-MM-DD")).filter(Boolean)),A=H(()=>c.value&&c.value.totals&&c.value.totals.length>0),z=H(()=>{if(!D.value||D.value.length===0)return!1;const G=x.value.start.format("YYYY-MM-DD"),ie=x.value.end.format("YYYY-MM-DD");return D.value.some(U=>U>=G&&U<=ie)});function R(){$.value++}function O(){try{const G=new URLSearchParams(window.location.search),ie=G.get("status"),U=G.get("reservation"),ne=G.get("reference");ie==="success"&&(n.value=`Your payment was successful and a reservation has been created with reference ${ne||U}.`,document.querySelector(".bookings-container").scrollIntoView({behavior:"smooth"})),ie==="cancelled"&&(i.value="Your payment was unsuccessful or cancelled. Please try again.",document.querySelector(".bookings-container").scrollIntoView({behavior:"smooth"}),console.log("reservation",U),U?fetch(`/api/bookings/${U}/cancel-payment-email`,{method:"POST"}).catch(me=>console.error("Failed to cancel payment email:",me)):console.error("No reservation found"))}catch(G){console.error(G)}}function V(){if(t.remoteWarning.enabled){f.value=!0;return}else p.value=!0}async function Y(){var G,ie,U,ne,me,J;try{m.value=!0;
737let N={link_id:t.linkId,booking_page_id:t.bookingPageId,first_name:y.value.first_name,last_name:y.value.last_name,email:y.value.email,confirm_email:y.value.confirm_email,country:y.value.country,phone:y.value.phone,requests:y.value.requests,reservationItems:w.value.map(te=>({accomodation_id:te.accomodation_id,accomodation_name:te.accomodation_name,from_date:te.from_date,to_date:te.to_date,label:te.label,rate_groups:te.rate_groups.map(ee=>ee.id==="RS1"?[ee.id,1]:[ee.id,ee.qty||0])}))};window.localStorage.setItem("reservation",JSON.stringify(N));const q=await o0.createReservation(N);q.errors&&(g.value=q.errors),(U=(ie=(G=q.data)==null?void 0:G.data)==null?void 0:ie.checkout_session)!=null&&U.url&&(window.location.href=(J=(me=(ne=q.data)==null?void 0:ne.data)==null?void 0:me.checkout_session)==null?void 0:J.url)}catch(N){N.errors&&(g.value=N.errors,console.error(g.value))}finally{m.value=!1}}async function F(){var G,ie;try{a.value=!0;const U=await o0.getAccomodation(t.bookingPageId,t.linkId,t.propertyId);if(!((G=U.data)!=null&&G.accomodation))throw new Error("No data found");l.value=U.data.accomodation,C.value=U.data.allowed_rate_groups||["RS1","RS2","RS3"],S.value=U.data.rate_group_descriptions||{},E.value=U.data.rate_group_labels||{},((ie=l.value)==null?void 0:ie.length)>0&&Z(l.value[0])}catch(U){console.error(U),i.value="An error occurred while fetching accomodation info. Please try again later."}finally{a.value=!1}}async function ae(){var G,ie,U,ne,me,J,N;try{s.value=!0;const q={selected_room_type_id:y.value.roomType.id,room_type_ids:(G=l.value)==null?void 0:G.map(ee=>ee.id),from_date:x.value.start.format("YYYY-MM-DD"),to_date:x.value.end.format("YYYY-MM-DD")},te=await o0.getAccomodationUpdates(t.bookingPageId,t.linkId,t.propertyId,q);if(!((ie=te.data)!=null&&ie.updates))throw new Error("No updates found");if(u.value=te.data.updates,((ne=(U=u.value)==null?void 0:U.rate_groups)==null?void 0:ne.length)>0&&y.value.guests.length===0&&(y.value.guests=(N=(J=(me=u.value)==null?void 0:me.rate_groups)==null?void 0:J.filter(ee=>{var oe;return(oe=C.value)==null?void 0:oe.includes(ee.id)}))==null?void 0:N.map(ee=>{const oe={1:"adult",10:"adult",2:"child",20:"child",0:"room"},Se=parseInt(ee.id==="RS3"?0:ee.default);return{id:ee.id,desc:ee.desc,type:oe[ee.class]||"room",qty:Se}})),!_.value){let ee=ut();const oe=ut(u.value.max_stock_date||v.value);for(;ee.isBefore(oe)||ee.isSame(oe,"day");){const Se=ee.add(1,"day").format("YYYY-MM-DD"),we=ee.add(2,"day").format("YYYY-MM-DD");if(!D.value.includes(Se)&&!D.value.includes(we)){x.value={start:ut(Se),end:ut(we)};return}ee=ee.add(1,"day")}}}catch(q){console.error(q),i.value="An error occurred while fetching accomodation info. Please try again later."}finally{s.value=!1}}async function ue(){try{if(w.value.length===0)return;o.value=!0;let G=w.value.map(U=>({accomodation_id:U.accomodation_id,accomodation_name:U.accomodation_name,from_date:U.from_date,to_date:U.to_date,rate_groups:U.rate_groups.map(ne=>ne.id==="RS1"?[ne.id,1]:[ne.id,ne.qty||0]),guests:U.rate_groups.filter(ne=>ne.id!=="RS1"&&ne.qty>0).reduce((ne,me)=>ne+me.qty,0)}));const ie=await o0.getReservationRates(t.bookingPageId,t.linkId,G);c.value=ie.data||null}catch(G){console.log(G)}finally{o.value=!1,d.value=null}}function Z(G){y.value.roomType=G,y.value.guests=[],Bi(()=>{ae()})}function K(G){y.value.guests=y.value.guests.map(ie=>ie.id===G.id?ie.id==="RS1"?{...ie,qty:1}:{...ie,qty:G.qty}:ie)}function fe(){const G={accomodation_id:y.value.roomType.id,accomodation_name:y.value.roomType.name,from_date:x.value.start.format("YYYY-MM-DD"),to_date:x.value.end.format("YYYY-MM-DD"),rate_groups:y.value.guests.map(ie=>({id:ie.id,qty:ie.id==="RS1"&&W.value<2?1:ie.qty})),guests:y.value.guests.filter(ie=>ie.id!=="RS1"&&ie.qty>0).reduce((ie,U)=>ie+U.qty,0)};G.label=$e(G),w.value=[...w.value,G]}function ve(G=0,ie){switch(ie.toLowerCase()){case"adult":return G===1?"Adult":"Adults";case"child":return G===1?"Child":"Children";case"unit":return G===1?"Unit":"Units";case"room":return G===1?"Room":"Rooms";default:return ie}}function $e(G){if(!u.value||!u.value.rate_groups)return"";const ie=[];return G.rate_groups.forEach(U=>{if(U.qty>0){const ne=u.value.rate_groups.find(me=>me.id===U.id);if(ne){const me=ve(U.id==="RS1"?1:U.qty,ne.desc);ie.push(`${U.qty} ${me}`)}}}),ie.join(", ")}function Re(G){d.value=G,w.value=w.value.filter((ie,U)=>U!==G)}function Oe(){r.value=!r.value}function ze(G){h.value=G}function Be(){_.value=!1,x.value={start:ut(),end:ut().add(1,"day")},F()}function qe(G){_.value=!0,ut(G.end).diff(ut(G.start),"day")<1?x.value={start:ut(G.start),end:ut(G.start).add(1,"day")}
737:x.value={start:ut(G.start),end:ut(G.end)},ae()}const j=(G,ie)=>{let U=0;return w.value.forEach(ne=>{var me;ne.accomodation_id===ie&&(ut(G).isAfter(ut(ne.from_date))&&ut(G).isBefore(ut(ne.to_date))||ut(G).isSame(ut(ne.from_date))||ut(G).isSame(ut(ne.to_date)))&&(U+=((me=ne.rate_groups.find(J=>J.id==="RS1"))==null?void 0:me.qty)||0)}),U},W=H(()=>{var ie,U,ne,me;if(!((U=(ie=u.value)==null?void 0:ie.stock)!=null&&U.total)||!((ne=x.value)!=null&&ne.start)||!((me=x.value)!=null&&me.end))return 0;const G=[];for(let J=x.value.start;J<=x.value.end;J=J.add(1,"day")){const N=J.format("YYYY-MM-DD"),q=parseInt(u.value.stock.total[N]||0),te=u.value.selected_room_rate.accommodation_id;G.push({date:N,capacity:q-j(N,te)})}return Math.min(...G.map(J=>J.capacity).slice(0,-1))||0});return tt(x,G=>{y.value.nights=G.end.diff(G.start,"day"),window.localStorage.setItem("range_start",G.start.format("YYYY-MM-DD")),window.localStorage.setItem("range_end",G.end.format("YYYY-MM-DD")),window.localStorage.setItem("range_expires",ut().add(1,"hour").unix())},{deep:!0}),tt(w,G=>{ue(),window.localStorage.setItem("reservation_items",JSON.stringify(G)),window.localStorage.setItem("reservation_items_expires",ut().add(1,"hour").unix())},{deep:!0}),or(()=>{const G=window.localStorage.getItem("reservation_items_expires");G&&ut.unix(G).isBefore(ut())&&(console.debug("Deleting expired reservation items from local storage"),window.localStorage.removeItem("reservation_items"),window.localStorage.removeItem("reservation_items_expires"));const ie=window.localStorage.getItem("range_expires");ie&&ut.unix(ie).isBefore(ut())&&(console.debug("Deleting expired range items from local storage"),window.localStorage.removeItem("range_start"),window.localStorage.removeItem("range_end"),window.localStorage.removeItem("range_expires"));const ne=new URLSearchParams(window.location.search).get("status");if(ne==="cancelled"){const J=window.localStorage.getItem("range_start");J&&(x.value.start=ut(J));const N=window.localStorage.getItem("range_end");N&&(x.value.end=ut(N))}if(F(),O(),ne==="cancelled"){const J=window.localStorage.getItem("reservation_items");if(J){const N=JSON.parse(J);w.value=N}}const me=window.localStorage.getItem("reservation");if(me){const J=JSON.parse(me);y.value.first_name=J.first_name,y.value.last_name=J.last_name,y.value.email=J.email,y.value.confirm_email=J.confirm_email,y.value.country=J.country,y.value.phone=J.phone,y.value.requests=J.requests}}),(G,ie)=>{var U,ne,me;return k(),M("div",_we,[b("div",ywe,[b("div",vwe,[b("div",bwe,[e.description?(k(),M("div",{key:0,class:pe(["font-primary text-xs text-ag-black-2 overflow-hidden relative",{"h-20":!r.value,"h-auto":r.value}])},[b("div",{class:pe(["h-1/2 w-full bottom-0 left-0 absolute bg-gradient-to-t to-transparent from-white z-20",{hidden:r.value}])},null,2),b("div",{class:"bookings-description",innerHTML:e.description},null,8,xwe)],2)):X("",!0),b("a",{href:"#",onClick:di(Oe,["prevent"]),class:"block py-4 text-ukuri hover:text-ukurihover"}," Read "+Q(r.value?"less":"more"),1)]),b("div",wwe,[ie[5]||(ie[5]=b("h4",{class:"text-2xl xl:text-4xl font-primary text-black my-0"},"Select a check-in date",-1)),a.value?(k(),M("p",$we,"Loading accomodation info, please wait a few moments...")):X("",!0),!a.value&&l.value?(k(),M("p",Swe,"Select your travel dates to check exact pricing and availibility")):X("",!0),i.value?(k(),M("div",Twe,[b("p",Cwe,Q(i.value),1)])):X("",!0),n.value?(k(),M("div",kwe,[b("p",Ewe,Q(n.value),1)])):X("",!0),!a.value&&l.value&&u.value?(k(),M("div",Pwe,[be(oR,{"disabled-dates":D.value,"checkout-only-dates":T.value,"max-stock-date":u.value.max_stock_date||v.value,"default-range":I.value,onClearDates:Be,onUpdateDates:qe},null,8,["disabled-dates","checkout-only-dates","max-stock-date","default-range"]),b("div",Mwe,[be(mb,{variant:"select","is-bookable":A.value,"form-terms":G.formTerms,range:x.value,accomodation:l.value,"accomodation-updates":u.value,loading:o.value||a.value||s.value||d.value,"loading-accomodation":a.value,"loading-accomodation-updates":s.value,"loading-reservation-rates":o.value,removingReservationItem:d.value,booking:y.value,"room-modal":h.value,"unit-details":e.unitDetails,submitting:m.value,"reservation-items":w.value,"reservation-rates":c.value,"rate-group-descriptions":S.value,"rate-group-labels":E.value,"allowed-rate-groups":C.value,"has-disabled-dates":z.value,"max-room-capacity":W.value,title:e.title,"is-african-parks":e.isAfricanParks,onUpdateRoom:Z,onSetGuests:K,onShowModal:ze,onSubmit:V,onUpdateReservation:fe,onRemoveReservationItem:Re},null,8,["is-bookable","form-terms","range","accomodation","accomodation-updates","loading","loading-accomodation","loading-accomodation-updates","loading-reservation-rates","removingReservationItem","booking","room-modal","unit-details","submitting","reservation-items","reservation-rates","rate-group-descriptions","rate-group-labels","allowed-rate-groups","has-disabled-dates","max-room-capacity","title","is-african-parks"])])])):X("",!0),o.value||a.value||s.value||d.value?(k(),M("div",Iwe,[be(Q4)])):X("",!0)]),(U=e.includes)!=null&&U.length||(ne=e.excludes)!=null&&ne.length?(k(),M("div",Awe,[be(F2e,{includes:e.includes,excludes:e.excludes},null,8,["includes","excludes"])])):X("",!0),b("div",Dwe,[be(lR,{amenities:e.amenities},null,8,["amenities"])]),b("div",Rwe,[be(_2e,{activities:e.activities},null,8,["activities"])]),(me=e.conservationImpact)!=null&&me.length?(k(),M("div",Owe,[be(S2e,{"conservation-impact":e.conservationImpact}
737,null,8,["conservation-impact"])])):X("",!0)]),b("div",Lwe,[be(mb,{variant:"select","is-bookable":A.value,"form-terms":G.formTerms,range:x.value,accomodation:l.value,"accomodation-updates":u.value,loading:o.value||a.value||s.value||d.value,"loading-accomodation":a.value,"loading-accomodation-updates":s.value,"loading-reservation-rates":o.value,removingReservationItem:d.value,booking:y.value,"room-modal":h.value,"unit-details":e.unitDetails,"reservation-items":w.value,"reservation-rates":c.value,"rate-group-descriptions":S.value,"rate-group-labels":E.value,"allowed-rate-groups":C.value,"has-disabled-dates":z.value,"max-room-capacity":W.value,title:e.title,"is-african-parks":e.isAfricanParks,onUpdateRoom:Z,onSetGuests:K,onShowModal:ze,onSubmit:V,onUpdateReservation:fe,onRemoveReservationItem:Re},null,8,["is-bookable","form-terms","range","accomodation","accomodation-updates","loading","loading-accomodation","loading-accomodation-updates","loading-reservation-rates","removingReservationItem","booking","room-modal","unit-details","reservation-items","reservation-rates","rate-group-descriptions","rate-group-labels","allowed-rate-groups","has-disabled-dates","max-room-capacity","title","is-african-parks"])])]),b("div",Fwe,[be(Uxe,{map:e.map},null,8,["map"])]),f.value?(k(),Mt(Yo,{key:0,onClose:ie[2]||(ie[2]=J=>f.value=null)},{default:_t(()=>[b("div",null,[b("h2",zwe,Q(e.remoteWarning.title),1),b("div",Nwe,Q(e.remoteWarningDescription),1),b("div",Bwe,[b("button",{onClick:ie[0]||(ie[0]=J=>f.value=!1),class:"button button--outline max-w-full flex-1"},"Cancel"),b("button",{onClick:ie[1]||(ie[1]=J=>{f.value=!1,p.value=!0}),class:"button max-w-full flex-1"},"Book now")])])]),_:1})):X("",!0),h.value?(k(),Mt(Yo,{key:1,onClose:ie[3]||(ie[3]=J=>h.value=null)},{default:_t(()=>[b("div",null,[b("h2",jwe,Q(h.value.name),1),b("div",{class:"font-primary text-ag-black-2 whitespace-pre-wrap",innerHTML:h.value.description},null,8,Uwe),b("div",Vwe,[(k(!0),M(xe,null,Me(h.value.images,J=>(k(),M("div",{class:"h-32 bg-cover bg-center",title:J.alt,style:Qt({backgroundImage:"url("+J.url+")"})},null,12,qwe))),256))])])]),_:1})):X("",!0),p.value?(k(),Mt(Yo,{key:2,onClose:ie[4]||(ie[4]=J=>p.value=!1),"full-screen":!0},{default:_t(()=>[b("div",{class:"max-w-screen-xl mx-auto py-12 px-4",onClick:R},[b("form",{onSubmit:di(Y,["prevent"])},[b("div",Gwe,[b("div",Hwe,[be(gwe,{booking:y.value,errors:g.value},null,8,["booking","errors"])]),b("div",Ywe,[be(mb,{variant:"summary","is-bookable":A.value,"form-terms":G.formTerms,range:x.value,accomodation:l.value,"accomodation-updates":u.value,loading:o.value||a.value||s.value||d.value,"loading-accomodation":a.value,"loading-accomodation-updates":s.value,"loading-reservation-rates":o.value,removingReservationItem:d.value,booking:y.value,"room-modal":h.value,"unit-details":e.unitDetails,submitting:m.value,"reservation-items":w.value,"reservation-rates":c.value,"rate-group-descriptions":S.value,"rate-group-labels":E.value,"allowed-rate-groups":C.value,"has-disabled-dates":z.value,title:e.title,"is-african-parks":e.isAfricanParks,onUpdateRoom:Z,onSetGuests:K,onShowModal:ze},null,8,["is-bookable","form-terms","range","accomodation","accomodation-updates","loading","loading-accomodation","loading-accomodation-updates","loading-reservation-rates","removingReservationItem","booking","room-modal","unit-details","submitting","reservation-items","reservation-rates","rate-group-descriptions","rate-group-labels","allowed-rate-groups","has-disabled-dates","title","is-african-parks"])])])],32)])]),_:1})):X("",!0)])}}},Zwe={class:"text-xl font-bold text-ag-black-2 mb-1"},Kwe={key:0,class:"text-ag-black-2"},Xwe={class:"flex items-center justify-center md:justify-start gap-4 py-8"},Jwe=["href"],Qwe={class:"flex flex-col items-center justify-center gap-2 hover:text-primary text-primary cursor-pointer"},e3e=["src"],t3e={class:"font-primary text-sm"},r3e={__name:"BookingsShare",props:["shareTitle","shareDescription","shareUrl"],setup(e){const t=e,r=se(!1),i=[{name:"facebook",title:"Facebook",icon:"/img/facebook.svg",color:"#1877f2",url:"https://www.facebook.com/sharer/sharer.php?u="},{name:"twitter",title:"X.com",icon:"/img/X.svg",color:"#1da1f2",url:"https://twitter.com/intent/tweet?url="},{name:"linkedin",title:"LinkedIn",icon:"/img/linkedin.svg",color:"#0a66c2",url:"https://www.linkedin.com/shareArticle?url="},{name:"whatsapp",title:"WhatsApp",icon:"/img/whatsapp.svg",color:"#25d366",url:"https://api.whatsapp.com/se
737nd?text="},{name:"email",title:"Email",icon:"/img/email.svg",color:"#0077b5",url:"mailto:?subject="}],n=H(()=>{var l;return(l=window==null?void 0:window.location)==null?void 0:l.href}),a=H(()=>document.title),s=H(()=>{var l;return(l=document.querySelector('meta[name="description"]'))==null?void 0:l.content});function o(l){const u=encodeURIComponent(t.shareUrl||n.value),c=encodeURIComponent(t.shareTitle||a.value),d=encodeURIComponent(t.shareDescription||s.value);switch(l.name){case"facebook":return`https://www.facebook.com/sharer/sharer.php?u=${u}`;case"twitter":return`https://twitter.com/intent/tweet?url=${u}&text=${c}`;case"linkedin":return`https://www.linkedin.com/shareArticle?url=${u}&title=${c}&summary=${d}`;case"whatsapp":return`https://api.whatsapp.com/send?text=${c} ${u}`;case"email":return`mailto:?subject=${c}&body=${d} ${u}`;default:return"#"}}return(l,u)=>(k(),M("div",null,[b("button",{onClick:u[0]||(u[0]=c=>r.value=!0),class:"flex items-center text-ag-black-2 font-primary hover:text-ukuri justify-center gap-2"},[...u[2]||(u[2]=[b("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 448 512",class:"h-4 w-auto"},[b("path",{fill:"currentColor",d:"M246.6 9.4c-12.5-12.5-32.8-12.5-45.3 0l-128 128c-12.5 12.5-12.5 32.8 0 45.3s32.8 12.5 45.3 0L192 109.3 192 320c0 17.7 14.3 32 32 32s32-14.3 32-32l0-210.7 73.4 73.4c12.5 12.5 32.8 12.5 45.3 0s12.5-32.8 0-45.3l-128-128zM64 352c0-17.7-14.3-32-32-32s-32 14.3-32 32l0 64c0 53 43 96 96 96l256 0c53 0 96-43 96-96l0-64c0-17.7-14.3-32-32-32s-32 14.3-32 32l0 64c0 17.7-14.3 32-32 32L96 448c-17.7 0-32-14.3-32-32l0-64z"})],-1),b("span",null,"Share",-1)])]),r.value?(k(),Mt(Yo,{key:0,onClose:u[1]||(u[1]=c=>r.value=!1),"full-screen":!1},{default:_t(()=>[b("div",null,[b("h1",Zwe,Q(e.shareTitle||"Share"),1),e.shareDescription?(k(),M("p",Kwe,Q(e.shareDescription||"Share this link with friends and family."),1)):X("",!0),b("div",Xwe,[(k(),M(xe,null,Me(i,c=>b("a",{key:c.name,href:o(c),target:"_blank",rel:"noopener noreferrer",class:"block"},[b("div",Qwe,[b("img",{class:"h-8 w-auto",src:c.icon},null,8,e3e),b("div",t3e,Q(c.title),1)])],8,Jwe)),64))])])]),_:1})):X("",!0)]))}},Ou={async getDefaultSearchDestinations(){return Rt.post("/api/search-default-destinations")},async getSearchDestinations(e){return Rt.post("/api/search-destinations",e)},async getDefaultSearchExperiences(){return Rt.post("/api/search-default-experiences")},async getSearchExperiences(e){return Rt.post("/api/search-experiences",e)},async getSearch(e){return Rt.post("/api/search",e)},async getSearchFilters(e){return Rt.post("/api/search-filters",e)}},i3e={name:"MinMaxRangeSlider",props:["minValue","maxValue","rangeSliderMin","rangeSliderMax","incrementValue"],data(){return{min:this.minValue||0,max:this.maxValue||9e5}},computed:{minthumb(){return(this.min-this.rangeSliderMin)/(this.rangeSliderMax-this.rangeSliderMin)*100},maxthumb(){return 100-(this.max-this.rangeSliderMin)/(this.rangeSliderMax-this.rangeSliderMin)*100}},watch:{min(e,t){this.$emit("update:minValue",e)},max(e,t){this.$emit("update:maxValue",e)},minValue(e){this.min=e},maxValue(e){this.max=e}},methods:{validate(){this.min=Number.isFinite(+this.min)?+this.min:this.rangeSliderMin,this.max=Number.isFinite(+this.max)?+this.max:this.rangeSliderMax,this.min=Math.max(this.rangeSliderMin,Math.min(this.min,this.rangeSliderMax-this.incrementValue,this.max-this.incrementValue)),this.max=Math.min(this.rangeSliderMax,Math.max(this.max,this.rangeSliderMin+this.incrementValue,this.min+this.incrementValue))}},mounted(){this.validate()}},n3e={class:"relative max-w-xl w-full"},a3e=["step","min","max"],s3e=["step","min","max"],o3e={class:"relative z-10 h-2"};function l3e(e,t,r,i,n,a){return k(),M("div",n3e,[it(b("input",{type:"range",step:r.incrementValue,min:r.rangeSliderMin,max:r.rangeSliderMax,"onUpdate:modelValue":t[0]||(t[0]=s=>n.min=s),onChange:t[1]||(t[1]=(...s)=>a.validate&&a.validate(...s)),onMouseup:t[2]||(t[2]=s=>{this.$emit("update:mouseup",s.target.value)}),onTouchend:t[3]||(t[3]=s=>{this.$emit("update:touchend",s.target.value)}),class:"absolute pointer-events-none appearance-none z-20 h-2 w-full opacity-0 cursor-pointer"},null,40,a3e),[[ui,n.min]]),it(b("input",{type:"range",step:r.incrementValue,min:r.rangeSliderMin,max:r.rangeSliderMax,"onUpdate:modelValue":t[4]||(t[4]=s=>
737n.max=s),onChange:t[5]||(t[5]=(...s)=>a.validate&&a.validate(...s)),onMouseup:t[6]||(t[6]=s=>{this.$emit("update:mouseup",s.target.value)}),onTouchend:t[7]||(t[7]=s=>{this.$emit("update:touchend",s.target.value)}),class:"absolute pointer-events-none appearance-none z-20 h-2 w-full opacity-0 cursor-pointer"},null,40,s3e),[[ui,n.max]]),b("div",o3e,[t[8]||(t[8]=b("div",{class:"absolute z-10 left-0 right-0 bottom-0 top-0 rounded-md bg-gray-200"},null,-1)),b("div",{class:"absolute z-20 top-0 bottom-0 rounded-md bg-ag-red max-w-full",style:Qt({right:a.maxthumb+"%",left:a.minthumb+"%"})},null,4),b("div",{class:"absolute z-30 w-4 h-4 top-0 left-0 bg-ag-red rounded-full -mt-1",style:Qt({left:a.minthumb+"%"})},null,4),b("div",{class:"absolute z-30 w-4 h-4 top-0 right-0 bg-ag-red rounded-full -mt-1",style:Qt({right:a.maxthumb+"%"})},null,4)])])}const $k=Yt(i3e,[["render",l3e]]),u3e={key:0,class:"bg-gray-50 fixed right-0 top-0 p-4 md:p-0 pb-8 md:pb-4 md:relative z-50 md:z-0 w-[90vw] md:w-[280px] xl:w-[310px] h-screen overflow-auto md:h-auto md:overflow-visible md:bg-transparent shadow-md md:shadow-none"},c3e={class:"flex flex-col gap-4 md:gap-6 w-full h-auto items-stretch md:h-full"},d3e={key:0,class:"text-black top-0 right-0 p-4 fixed w-auto"},h3e={class:"bg-gray-50 p-0 m-0 mb-24 md:mb-0"},f3e={class:"bg-gray-50 p-0 m-0 flex items-stretch flex-col"},p3e={class:"p-4 md:px-6 border-b border-b-gray-200"},m3e={class:"font-bold text-base md:text-lg m-0 tracking-wide"},g3e=["onClick"],_3e={key:1,class:"border-gray-300"},y3e={key:2,class:"bg-gray-50 p-0 m-0 mb-24 md:mb-0"},v3e={class:"py-4 px-4 md:px-6"},b3e={class:"font-bold text-base md:text-lg m-0 tracking-wide"},x3e={key:0,class:"w-full h-auto m-0"},w3e={key:0},$3e={key:1},S3e={key:0},T3e={class:"px-4 md:px-6 py-4 md:py-6 flex flex-col gap-4"},C3e={class:"flex flex-col gap-3 transform transition-height duration-300 ease-in-out"},k3e={class:"flex items-center justify-start gap-2"},E3e=["for"],P3e=["id","value"],M3e={class:"text-xs leading-5 font-medium"},I3e={class:"text-gray-500 font-normal"},A3e=["for"],D3e=["id","value"],R3e={class:"text-xs leading-5 pl-6"},O3e={class:"text-gray-500"},L3e={class:"text-sm"},F3e={key:1},z3e={class:"px-4 md:px-6 py-4 md:py-6 flex flex-col gap-4"},N3e={class:"flex flex-col gap-3 transform transition-height duration-300 ease-in-out"},B3e=["for"],j3e=["id","value"],U3e={class:"text-xs leading-5"},V3e={class:"text-gray-500"},q3e={class:"text-sm"},G3e={key:2},H3e={class:"px-4 md:px-6 py-4 md:py-6 flex flex-col gap-4"},Y3e={class:"font-medium text-black text-base m-0 tracking-wide flex flex-row items-center gap-2"},W3e={class:"flex flex-row justify-between items-center gap-3 text-sm text-black"},Z3e={class:"px-4 md:px-6 py-3 md:py-6 flex flex-col gap-4"},K3e={class:"flex flex-row justify-between items-center gap-3 text-sm text-black"},X3e={__name:"SearchSidebar",props:Hp({isMobile:{type:Boolean,default:!1},showFiltersMenu:{type:Boolean,default:!1},searchSettings:{type:Object,default:()=>({})},searchCategories:{type:Array,default:()=>[]},category:{type:String,default:""},loadingFilters:{type:Boolean,default:!1},filters:{type:Object,default:()=>({})},budget:{type:Object,default:()=>({})},duration:{type:Object,default:()=>({})},showAllDestinationsFilters:{type:Boolean,default:!1},showAllExperiencesFilters:{type:Boolean,default:!1},currencyRates:{type:Object,default:()=>({})},currencySelectorOptions:{type:Array,default:()=>[]},navigationItems:{type:Array,default:()=>[]}},{selectedDestinations:{default:()=>[]},selectedDestinationsModifiers:{},selectedExperiences:{default:()=>[]},selectedExperiencesModifiers:{},minBudget:{default:0},minBudgetModifiers:{},maxBudget:{default:null},maxBudgetModifiers:{},minDuration:{default:0},minDurationModifiers:{},maxDuration:{default:null},maxDurationModifiers:{}}),emits:Hp(["toggle-filters-menu","select-category","filter-changed","toggle-destinations-filters","toggle-experiences-filters","commit-budget","reset-budget","commit-duration","reset-duration"],["update:selectedDestinations","update:selectedExperiences","update:minBudget","update:maxBudget","update:minDuration","update:maxDuration"]),setup(e){const t=e,r=Al(e,"selectedDestinations"),i=Al(e,"selectedExperiences"),n=Al(e,"minBudget"),a=Al(e,"maxBudget"),s=Al(e,"minDuration"),o=Al(e,"maxDuration");function l(P){var D;const T=(t.navigationItems||[]).find(A=>A.title===P);return((D=T==null?void 0:T.children)==null?void 0:D.map(A=>A.id))??[]}const u=H(()=>!t.isMobile||t.isMobile&&t.showFiltersMenu),c=H(()=>!["information"].includes(t.category)),d=H(()=>["safaris"].includes(t.category)||!t.category),h=H(()=>{var P;return(["destinations","safaris"].includes(t.category)||!t.category)&&((P=t.filters)==null?void 0:P.popular_destinations)&&t.filters.popular_destinations.length>0}),f=H(()=>{var P;return["experiences","safaris"].includes(t.category)&&((P=t.filters)==null?void 0:P.popular_experiences)&&t.filters.popular_experiences.length>0}),p=H(()=>{var P;return(P=t.filters)!=null&&P.popular_destinations?(r.value,t.filters.popular_destinations):[]}),m=H(()=>{var P;return(P=t.filters)!=null&&P.popular_destinations?t.showAllDestinationsFilters?t.filters.popular_destinations.filter(T=>T.country===null).sort((T,D)=>T.title.localeCompare(D.title)):t.filters.popular_destinations.filter(T=>T.show_in_filter===!0&&T.country===null):[]}),g=H(()=>{var A;if(!((A=t.filters)!=null&&A.popular_experiences))return[];const P=i.value||[],T=l("Experiences");let D=t.showAllExperiencesFilters?[...t.filters.popular_experiences]:t.filters.popular_experiences.filter(z=>z.show_in_filter||P.includes(z.slug));return T.length>0&&D.sort((z,R)=>{const O=T.indexOf(z.id),V=T.indexOf(R.id);return O===-1&&V===-1?(R.result_count||0)-(z.result_count||0):O===-1?1:V===-1?-1:O-V}),D}),v=H(()=>{var P,T,D,A,z,R;return((P=t.budget)==null?void 0:P.min)&&t.budget.min!==((D=(T=t.filters)==null?void 0:T.budget_range)==null?void 0:D.min)||((A=t.budget)==null?void 0:A.max)&&t.budget.max!==((R=(z=t.filters)==null?void 0:z.budget_range)==null?void 0:R.max)}),x=H(()=>{var P,T,D,A,z,R;return((P=t.duration)==null?void 0:P.min)&&t.duration.min!==((D=(T=t.filters)==null?void 0:T.duration_range)==null?void 0:D.min)||((A=t.duration)==null?void 0:A.max)&&t.duration.max!==((R=(z=t.filters)==null?void 0:z.duration_range)==null?void 0:R.max)}),_=se("USD");function y(){_.value=window.localStorage.getItem("selected_currency")||"USD"}function w(P){var T;_.value=((T=P==null?void 0:P.detail)==null?void 0:T.message)||"USD"}or(()=>{y(),window.addEventListener("currencyUpdated",w)}),ra(()=>{window.removeEventListener("currencyUpdated",w)});function $(P){const T=typeof P=="string"?S(P):P;return!T||typeof T!="object"||Object.keys(T).length===0?null:T}function S(P){try{return JSON.parse(P)}catch{return null}}const E=H(()=>$(t.currencyRates)||$(window.currencyRates)||{});function C(P){const T=E.value[P];return T==null?1:typeof T=="object"?T.rate??1:T}function I(P){if(P==null)return"";const T=_.value;return new Intl.NumberFormat("en-US",{style:"currency",currency:T}).format(P*C(T))}return(P,T)=>u.value?(k(),M("div",u3e,[b("div",c3e,[e.isMobile?(k(),M("div",d3e,[b("button",{onClick:T[0]||(T[0]=D=>P.$emit("toggle-filters-menu"))},[...T[19]||(T[19]=[b("svg",{xmlns:"http://www.w3.org/2000/svg",class:"h-6 w-6",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor"},[b("path",{"stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"M6 18L18 6M6 6l12 12"})],-1)])])])):X("",!0),b("div",h3e,[b("div",f3e,[b("div",p3e,[b("h4",m3e,Q(e.searchSettings.category_title||"Deep-dive into categories & related safari ideas"),1)]),(k(!0),M(xe,null,Me(e.searchCategories,D=>(k(),M("div",{key:D.id},[b("button",{class:pe(["font-primary flex items-center justify-start w-full p-4 md:px-6 text-black text-left text-base border-r-5 border-transparent m-0 tracking-wide font-medium",{"border-r-4 border-r-ag-red bg-ag-red bg-opacity-10":e.category===D.id,"hover:bg-gray-300 hover:bg-opacity-20":e.category!==D.id}]),onClick:A=>P.$emit("select-category",D.id)},Q(D.title),11,g3e)]))),128))])]),c.value?(k(),M("hr",_3e)):X("",!0),c.value?(k(),M("div",y3e,[b("div",v3e,[b("h4",b3e,Q(e.searchSettings.filter_title||"Filter by category"),1)]),e.loadingFilters?(k(),M("div",x3e,[T[21]||(T[21]=so('<div data-v-b4456488><hr class="border-gray-300" data-v-b4456488><div class="px-4 md:px-6 py-3 md:py-6 flex flex-col gap-2 md:gap-4 w-full h-auto" data-v-b4456488><h4 class="font-medium text-black text-base m-0 tracking-wide" data-v-b4456488>Popular Destinations</h4><div class="animate-pulse bg-gray-200 w-full h-3" data-v-b4456488></div><div class="animate-pulse bg-gray-200 w-full h-3" data-v-b4456488></div></div></div><div data-v-b4456488><hr class="border-gray-300" data-v-b4456488><div class="px-4 md:px-6 py-3 md:py-6 flex flex-col gap-2 md:gap-4 w-full h-auto" data-v-b4456488><h4 class="font-medium text-black text-base m-0 tracking-wide" data-v-b4456488>Popular Experiences</h4><div class="animate-pulse bg-gray-200 w-full h-3" data-v-b4456488></div><div class="animate-pulse bg-gray-200 w-full h-3" data-v-b4456488></div></div></div>',2)),d.value?(k(),M("div",w3e,[...T[20]||(T[20]=[so('<hr class="border-gray-300" data-v-b4456488><div class="px-4 md:px-6 py-3 md:py-6 flex flex-col gap-2 md:gap-4 w-full h-auto" data-v-b4456488><h4 class="font-medium text-black text-base m-0 tracking-wide" data-v-b4456488>Budget</h4><div class="animate-pulse bg-gray-200 w-full h-3" data-v-b4456488></div></div><hr class="border-gray-300" data-v-b4456488><div class="px-4 md:px-6 py-3 md:py-6 flex flex-col gap-2 md:gap-4 w-full h-auto" data-v-b4456488><h4 class="font-medium text-black text-base m-0 tracking-wide" data-v-b4456488>Duration</h4><div class="animate-pulse bg-gray-200 w-full h-3" data-v-b4456488></div></div>',4)])])):X("",!0)])):(k(),M("div",$3e,[h.value?(k(),M("div",S3e,[T[24]||(T[24]=b("hr",{class:"border-gray-300"},null,-1)),b("div",T3e,[T[23]||(T[23]=b("h4",{class:"font-medium text-black text-base m-0 tracking-wide"},"Popular Destinations",-1)),b("ul",C3e,[(k(!0),M(xe,null,Me(m.value,D=>(k(),M(xe,{key:D.slug},[b("li",k3e,[b("label",{for:`destination-${D.slug}`,class:"filter-checkbox flex items-center gap-3 cursor-pointer"},[it(b("input",{id:`destination-${D.slug}`,type:"checkbox","onUpdate:modelValue":T[1]||(T[1]=A=>r.value=A),value:D.slug,onChange:T[2]||(T[2]=A=>P.$emit("filter-changed"))},null,40,P3e),[[_s,r.value]]),b("span",M3e,[Ze(Q(D.title)+" ",1),b("span",I3e,"("+Q(D.result_count)+")",1)])],8,E3e)]),(k(!0),M(xe,null,Me(p.value.filter(A=>A.country===D.slug).sort((A,z)=>A.title.localeCompare(z.title)),A=>(k(),M("li",{key:A.slug},[b("label",{for:`destination-${A.slug}`,class:"filter-checkbox flex items-center gap-2 cursor-pointer text-black"},[it(b("input",{id:`destination-${A.slug}`,type:"checkbox","onUpdate:modelValue":T[3]||(T[3]=z=>r.value=z),value:A.slug,onChange:T[4]||(T[4]=z=>P.$emit("filter-changed"))},null,40,D3e),[[_s,r.value]]),b("span",R3e,[Ze(Q(A.title)+" ",1),b("span",O3e,"("+Q(A.result_count)+")",1)])],8,A3e)]))),128))],64))),128))]),p.value?(k(),M("button",{key:0,class:"text-black underline text-left inline-flex items-center px-0 m-0 py-2 font-normal gap-2 mt-2",onClick:T[5]||(T[5]=D=>P.$emit("toggle-destinations-filters"))},[b("span",L3e,Q(e.showAllDestinationsFilters?"Hide Destinations":"View all Destinations"),1),(k(),M("svg",{class:pe([!e.showAllDestinationsFilters&&"rotate-180","mx-1 w-3"]),"aria-hidden":"true",focusable:"false","data-icon":"chevron-up",role:"img",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 448 512"},[...T[22]||(T[22]=[b("path",{fill:"currentColor",d:"M4.465 366.475l7.07 7.071c4.686 4.686 12.284 4.686 16.971 0L224 178.053l195.494 195.493c4.686 4.686 12.284 4.686 16.971 0l7.07-7.071c4.686-4.686 4.686-12.284 0-16.97l-211.05-211.051c-4.686-4.686-12.284-4.686-16.971 0L4.465 349.505c-4.687 4.686-4.687 12.284 0 16.97z"},null,-1)])],2))])):X("",!0)])])):X("",!0),f.value?(k(),M("div",F3e,[T[27]||(T[27]=b("hr",{class:"border-gray-300"},null,-1)),b("div",z3e,[T[26]||(T[26]=b("h4",{class:"font-medium text-black text-base m-0 tracking-wide"},"Popular Experiences",-1)),b("ul",N3e,[(k(!0),M(xe,null,Me(g.value,D=>(k(),M("li",{key:D.slug,class:"flex items-center justify-start gap-2"},[b("label",{for:`experience-${D.slug}`,class:"filter-checkbox flex items-center gap-2 cursor-pointer text-black"},[it(b("input",{id:`experience-${D.slug}`,type:"checkbox","onUpdate:modelValue":T[6]||(T[6]=A=>
737i.value=A),value:D.slug,onChange:T[7]||(T[7]=A=>P.$emit("filter-changed"))},null,40,j3e),[[_s,i.value]]),b("span",U3e,[Ze(Q(D.title)+" ",1),b("span",V3e,"("+Q(D.result_count)+")",1)])],8,B3e)]))),128))]),g.value?(k(),M("button",{key:0,class:"text-black underline text-left inline-flex items-center px-0 m-0 py-2 font-normal gap-2 mt-2",onClick:T[8]||(T[8]=D=>P.$emit("toggle-experiences-filters"))},[b("span",q3e,Q(e.showAllExperiencesFilters?"Hide Experiences":"View all Experiences"),1),b("div",null,[(k(),M("svg",{class:pe([!e.showAllExperiencesFilters&&"rotate-180","mx-1 text-sm w-3"]),"aria-hidden":"true",focusable:"false","data-icon":"chevron",role:"img",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 448 512"},[...T[25]||(T[25]=[b("path",{fill:"currentColor",d:"M4.465 366.475l7.07 7.071c4.686 4.686 12.284 4.686 16.971 0L224 178.053l195.494 195.493c4.686 4.686 12.284 4.686 16.971 0l7.07-7.071c4.686-4.686 4.686-12.284 0-16.97l-211.05-211.051c-4.686-4.686-12.284-4.686-16.971 0L4.465 349.505c-4.687 4.686-4.687 12.284 0 16.97z"},null,-1)])],2))])])):X("",!0)])])):X("",!0),d.value?(k(),M("div",G3e,[T[30]||(T[30]=b("hr",{class:"border-gray-300"},null,-1)),b("div",H3e,[b("h4",Y3e,[T[28]||(T[28]=b("span",{class:"flex-1"},"Budget",-1)),b("div",null,[be(k$,{rates:e.currencyRates,options:e.currencySelectorOptions?e.currencySelectorOptions:[],variation:"filter"},null,8,["rates","options"])])]),be($k,{minValue:n.value,maxValue:a.value,incrementValue:1,rangeSliderMin:e.filters.budget_range.min,rangeSliderMax:e.filters.budget_range.max,"onUpdate:minValue":T[9]||(T[9]=D=>{n.value=D}),"onUpdate:maxValue":T[10]||(T[10]=D=>{a.value=D}),"onUpdate:mouseup":T[11]||(T[11]=D=>P.$emit("commit-budget")),"onUpdate:touchend":T[12]||(T[12]=D=>P.$emit("commit-budget"))},null,8,["minValue","maxValue","rangeSliderMin","rangeSliderMax"]),b("div",W3e,[b("div",null,Q(I(n.value)),1),b("div",null,Q(I(a.value)),1)]),v.value?(k(),M("button",{key:0,class:"text-xs text-black hover:text-ag-red underline text-right",onClick:T[13]||(T[13]=D=>P.$emit("reset-budget"))}," Reset ")):X("",!0)]),T[31]||(T[31]=b("hr",{class:"border-gray-300"},null,-1)),b("div",Z3e,[T[29]||(T[29]=b("h4",{class:"font-medium text-black text-base m-0 tracking-wide"},"Duration",-1)),be($k,{minValue:s.value,maxValue:o.value,incrementValue:1,rangeSliderMin:e.filters.duration_range.min,rangeSliderMax:e.filters.duration_range.max,"onUpdate:minValue":T[14]||(T[14]=D=>{s.value=D}),"onUpdate:maxValue":T[15]||(T[15]=D=>{o.value=D}),"onUpdate:mouseup":T[16]||(T[16]=D=>P.$emit("commit-duration")),"onUpdate:touchend":T[17]||(T[17]=D=>P.$emit("commit-duration"))},null,8,["minValue","maxValue","rangeSliderMin","rangeSliderMax"]),b("div",K3e,[b("div",null,Q(s.value>0?s.value:"1")+" day"+Q(s.value>1?"s":""),1),b("div",null,Q(o.value)+" day"+Q(o.value>1?"s":""),1)]),x.value?(k(),M("button",{key:0,class:"text-xs text-black hover:text-ag-red underline text-right",onClick:T[18]||(T[18]=D=>P.$emit("reset-duration"))}," Reset ")):X("",!0)])])):X("",!0)]))])):X("",!0)])])):X("",!0)}},J3e=Yt(X3e,[["__scopeId","data-v-b4456488"]]),Q3e={name:"SearchCard",components:{CurrencyDisplay:eg},props:["type","result"]},e4e=["href"],t4e={key:0,class:"absolute bottom-0 right-0 text-white p-2 w-auto h-auto"},r4e={class:"font-normal tracking-wider text-base md:text-lg text-white mb-0",style:{"text-shadow":"0px 1px 1px rgba(0, 0, 0, 0.5)"}},i4e={key:0,class:"flex-1 flex gap-4 flex-col w-full"},n4e={class:"flex-1 flex gap-1 flex-col w-full"},a4e={key:0,class:"font-light uppercase text-[11px] leading-[14px] tracking-wide m-0"},s4e={key:1,class:"text-black font-semibold tracking-wide m-0 text-base",style:{"line-height":"20px"}},o4e=["innerHTML"],l4e={class:"flex items-end justify-between w-full gap-2"},u4e={class:"text-ag-black tracking-wide flex flex-col items-start justify-start"},c4e={class:"text-black"},d4e={class:"text-base font-bold leading-5"},h4e={key:1,class:"flex-1 flex gap-2 flex-col w-full"},f4e={key:0,class:"text-black font-semibold tracking-wide m-0 text-base leading-tight"},p4e={key:1,class:"text-black font-semibold tracking-wide m-0 text-base leading-tight"},m4e=["innerHTML"];function g4e(e,t,r,i,n,a){const s=qr("currency-display");return k(),M("a",{class:pe(["font-primary min-h-[300px] search-card border rounded hover:shadow h-full flex flex-col",r.type==="safaris"&&"min-h-[315px]"]),href:`${r.result.url}`,target:"_blank",rel:"noopener noreferrer"},[b("div",{class:"relative bg-cover bg-center w-full h-32 md:h-40 bg-gray-50",style:Qt(`background-image: url(${r.result.image_url});`)},[r.type==="safaris"&&r.result.duration_days?(k(),M("div",t4e,[b("p",r4e,Q(r.result.duration_days)+" day"+Q(r.result.duration_days>1?"s":""),1)])):X("",!0)],4),b("div",{class:pe(["p-2 px-3 md:p-3 lg:px-4 flex-1 flex flex-col justify-between w-full",r.type!=="safaris"&&"pt-3 pb-4"])},[r.type==="safaris"?(k(),M("div",i4e,[b("div",n4e,[r.result.header_country?(k(),M("span",a4e,Q(r.result.header_country),1)):X("",!0),r.result.header_destination?(k(),M("h4",s4e,Q(r.result.header_destination),1)):X("",!0),r.result.content_paragraph?(k(),M("p",{key:2,class:"text-ag-black-2 mt-1 text-xs tracking-normal leading-5 mb-0 font-normal line-clamp-3",innerHTML:r.result.content_paragraph},null,8,o4e)):X("",!0)]),b("div",l4e,[b("div",u4e,[t[1]||(t[1]=b("span",{class:"font-light text-ag-black text-xs leading-4"},"from",-1)),b("div",c4e,[b("span",d4e,[be(s,{value:r.result.price_usd},null,8,["value"])]),t[0]||(t[0]=b("span",{class:"font-light text-ag-black text-xs"},"pps",-1))])]),t[2]||(t[2]=b("span",{class:"flex items-center justify-end h-8 w-8"},[b("svg",{xmlns:"http://www.w3.org/2000/svg",class:"h-5 w-5 inline-block text-ag-black",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor"},[b("path",{"stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"M9 5l7 7-7 7"})])],-1))])])):(k(),M("div",h4e,[r.type!=="information"&&r.result.header_destination?(k(),M("h4",f4e,Q(r.result.header_destination),1)):X("",!0),r.type==="information"&&r.result.title?(k(),M("h4",p4e,Q(r.result.title),
7371)):X("",!0),r.result.content_paragraph?(k(),M("p",{key:2,class:"text-ag-black-2 text-xs tracking-normal leading-5 mb-0 font-normal line-clamp-4",innerHTML:r.result.content_paragraph},null,8,m4e)):X("",!0)]))],2)],10,e4e)}const _4e=Yt(Q3e,[["render",g4e],["__scopeId","data-v-062471d7"]]),y4e={class:"flex-1 flex flex-col gap-2 w-full items-stretch min-h-screen"},v4e={class:"flex justify-between items-center md:mt-3"},b4e={class:"text-base md:text-lg font-light tracking-wider mb-1"},x4e={class:"relative flex-1"},w4e=["value"],$4e={class:"flex shrink-0 gap-2"},S4e={class:"flex items-center justify-between h-10 md:h-12"},T4e={class:"flex-1 w-auto flex flex-wrap items-center"},C4e={class:"uppercase tracking-wide text-xs md:text-sm font-semibold leading-5 pr-1 md:pr-2"},k4e={key:0,class:"text-xs font-light"},E4e={key:1,class:"text-xs font-light"},P4e={key:0,class:"flex flex-row items-start md:items-center justify-end gap-3"},M4e={key:0,class:"relative inline-flex min-w-[60px]"},I4e={key:0},A4e={class:"absolute right-0 top-full bg-white shadow-lg rounded-md mt-1 w-40 z-50 font-primary overflow-hidden"},D4e={key:0,class:"py-4 md:py-6 text-center text-sm md:text-lg tracking-wider"},R4e={key:1,class:"py-6 px-4 md:p-8 lg:p-12 bg-gray-100 flex align-center justify-start flex-col gap-flex-1 w-auto gap-4 lg:gap-5"},O4e={class:"text-xl xl:text-2xl tracking-wider italic font-light"},L4e={key:0},F4e={class:"text-sm text-ag-black tracking-wide"},z4e=["href"],N4e={key:1},B4e={class:"text-sm text-ag-black tracking-wide"},j4e=["href"],U4e={key:2,class:"grid grid-cols-2 lg:grid-cols-3 xl:grid-cols-4 gap-y-3 gap-2 lg:gap-3 lg:gap-y-4"},V4e={key:3,class:"flex items-center w-auto mx-auto justify-center gap-2 mt-4 self-end"},q4e=["onClick"],G4e={__name:"SearchResults",props:{q:{type:String,default:""},category:{type:String,default:""},searchCategories:{type:Array,default:()=>[]},searchSettings:{type:Object,default:()=>({})},results:{type:Array,default:null},offset:{type:Number,default:0},limit:{type:Number,default:12},totalResults:{type:Number,default:0},loadingResults:{type:Boolean,default:!1},isMobile:{type:Boolean,default:!1},showSortMenu:{type:Boolean,default:!1},showClearFilters:{type:Boolean,default:!1}},emits:["update:q","search","set-sort","toggle-filters-menu","toggle-sort-menu","set-page","reset-filters"],setup(e,{emit:t}){const r=e,i=t,n=H(()=>{var c;return((c=r.searchCategories.find(d=>d.id===r.category))==null?void 0:c.title)||"Results"}),a=H(()=>["safaris"].includes(r.category)||!r.category),s=H(()=>["safaris"].includes(r.category)||!r.category),o=H(()=>Math.ceil(r.totalResults/r.limit));function l(c){return r.offset/r.limit+1===c||!r.offset&&c===1}function u(){r.isMobile&&i("toggle-filters-menu")}return(c,d)=>{var h,f,p,m,g,v,x,_,y,w;return k(),M("div",y4e,[b("div",v4e,[b("h1",b4e," Search results "+Q(e.q?`for "${e.q}"`:""),1)]),b("form",{class:"flex justify-between items-stretch gap-4 max-w-full md:max-w-2xl",onSubmit:d[3]||(d[3]=di($=>c.$emit("search"),["prevent"]))},[b("div",x4e,[d[12]||(d[12]=b("span",{class:"absolute left-3 top-1/2 transform -translate-y-1/2 text-black"},[b("svg",{xmlns:"http://www.w3.org/2000/svg",class:"h-5 w-5",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor"},[b("path",{"stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"M21 21l-4.35-4.35m0 0A7.5 7.5 0 104.5 4.5a7.5 7.5 0 0012.15 12.15z"})])],-1)),b("input",{class:"pl-12 pr-2 py-3 w-full bg-gray-100 rounded-sm border-gray-200 text-ag-black focus:outline-gray-300",type:"text",name:"q",value:e.q,onInput:d[0]||(d[0]=$=>c.$emit("update:q",$.target.value)),onKeyup:d[1]||(d[1]=Ao($=>c.$emit("search"),["enter"])),placeholder:"Search term..."},null,40,w4e)]),b("div",$4e,[d[14]||(d[14]=b("button",{type:"submit","aria-label":"Search",class:"button font-primary py-2 px-4 text-white text-center inline-flex items-center justify-center max-[899px]:w-12 max-[899px]:min-w-0 max-[899px]:p-0 min-[900px]:w-32 min-[900px]:min-w-24"},[b("span",{class:"hidden min-[900px]:inline"},"Search"),b("svg",{xmlns:"http://www.w3.org/2000/svg",class:"h-5 w-5 min-[900px]:hidden",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor","aria-hidden":"true"},[b("path",{"stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"M21 21l-4.35-4.35m0 0A7.5 7.5 0 104.5 4.5a7.5 7.5 0 0012.15 12.15z"})])],-1)),e.showClearFilters?(k(),M("a",{key:0,href:"/search","aria-label":"Clear search",class:"button font-primary py-2 px-4 text-center bg-transparent border border-ag-black text-ag-black hover:bg-gray-200 inline-flex items-center justify-center max-[899px]:w-12 max-[899px]:min-w-0 max-[899px]:p-0 min-[900px]:w-32 min-[900px]:min-w-24",onClick:d[2]||(d[2]=di($=>c.$emit("reset-filters"),["prevent"]))},[...d[13]||(d[13]=[b("span",{class:"hidden min-[900px]:inline"},"Clear Search",-1),b("svg",{xmlns:"http://www.w3.org/2000/svg",class:"h-5 w-5 min-[900px]:hidden",fill:"none",viewBox:"0 0 24 24",stroke:"currentColor","aria-hidden":"true"},[b("path",{"stroke-linecap":"round","stroke-linejoin":"round","stroke-width":"2",d:"M6 18L18 6M6 6l12 12"})],-1)])])):X("",!0)])],32),b("div",S4e,[b("div",T4e,[b("span",C4e," All "+Q(n.value),1),e.results&&e.results.length>0?(k(),M("span",k4e," ("+Q(e.offset>1?e.offset:1)+" - "+Q(e.offset+e.results.length)+" of "+Q(e.totalResults)+" results) ",1)):(k(),M("span",E4e,"(0 results)"))]),e.loadingResults?X("",!0):(k(),M("div",P4e,[b("button",{onClick:u,class:"md:hidden flex items-center justify-center font-semibold text-xs lg:text-sm uppercase gap-2 py-1 sm:px-2 leading-5"},[...d[15]||(d[15]=[b("span",null,"Filter",-1),b("img",{src:"/img/filter-regular.svg",alt:"Filter Icon",class:"h-4 w-4"},null,-1)])]),a.value?(k(),M("div",M4e,[b("button",{onClick:d[4]||(
737d[4]=$=>c.$emit("toggle-sort-menu")),class:"font-semibold text-xs lg:text-sm uppercase flex gap-2 py-1 sm:px-2 items-center leading-5"},[...d[16]||(d[16]=[b("span",null,"Sort",-1),b("img",{src:"/img/bars-sort-regular.svg",alt:"Sort Icon",class:"h-4 w-4"},null,-1)])]),e.showSortMenu?(k(),M("div",I4e,[b("ul",A4e,[it(b("li",{class:"px-4 py-2 hover:bg-gray-100 cursor-pointer text-xs leading-5",onClick:d[5]||(d[5]=$=>c.$emit("set-sort","relevance"))},"Relevance",512),[[Dn,e.q.length>0]]),b("li",{class:"px-4 py-2 hover:bg-gray-100 cursor-pointer text-xs leading-5",onClick:d[6]||(d[6]=$=>c.$emit("set-sort","price_desc"))},"Price: High to Low"),b("li",{class:"px-4 py-2 hover:bg-gray-100 cursor-pointer text-xs leading-5",onClick:d[7]||(d[7]=$=>c.$emit("set-sort","price_asc"))},"Price: Low to High"),b("li",{class:"px-4 py-2 hover:bg-gray-100 cursor-pointer text-xs leading-5",onClick:d[8]||(d[8]=$=>c.$emit("set-sort","duration_desc"))},"Duration: Longest"),b("li",{class:"px-4 py-2 hover:bg-gray-100 cursor-pointer text-xs leading-5",onClick:d[9]||(d[9]=$=>c.$emit("set-sort","duration_asc"))},"Duration: Shortest")])])):X("",!0)])):X("",!0)]))]),e.loadingResults?(k(),M("div",D4e,[...d[17]||(d[17]=[b("p",null,"Loading results...",-1)])])):e.results&&!e.results.length?(k(),M("div",R4e,[b("h2",O4e,Q(s.value?(h=e.searchSettings)==null?void 0:h.no_safari_results_title:(f=e.searchSettings)==null?void 0:f.no_results_title),1),s.value?(k(),M("div",L4e,[b("p",F4e,Q((p=e.searchSettings)==null?void 0:p.no_safari_results_description),1),e.showClearFilters?(k(),M("a",{key:0,href:"/search",class:"button bg-transparent border border-ag-black text-ag-black hover:bg-gray-200 font-primary rounded-sm py-2 px-4 text-center min-w-40 lg:min-w-32 mt-6 mr-3 inline-flex items-center justify-center",onClick:d[10]||(d[10]=di($=>c.$emit("reset-filters"),["prevent"]))}," Clear all filters ")):X("",!0),b("a",{href:(m=e.searchSettings)!=null&&m.no_safari_results_button_link?(g=e.searchSettings)==null?void 0:g.no_safari_results_button_link.url:"#",class:"button font-primary rounded-3xl py-2 px-4 text-white text-center min-w-40 lg:min-w-32 mt-6"},Q((v=e.searchSettings)==null?void 0:v.no_safari_results_button_label),9,z4e)])):(k(),M("div",N4e,[b("p",B4e,Q(((x=e.searchSettings)==null?void 0:x.no_results_description)||"Try adjusting your search terms - or explore our safaris guides for more ideas."),1),e.showClearFilters?(k(),M("a",{key:0,href:"/search",class:"button bg-transparent border border-ag-black text-ag-black hover:bg-gray-200 font-primary rounded-sm py-2 px-4 text-center min-w-40 lg:min-w-32 mt-6 mr-3 inline-flex items-center justify-center",onClick:d[11]||(d[11]=di($=>c.$emit("reset-filters"),["prevent"]))}," Clear all filters ")):X("",!0),b("a",{href:(_=e.searchSettings)!=null&&_.no_results_button_link?(y=e.searchSettings)==null?void 0:y.no_results_button_link.url:"#",class:"button bg-ag-red hover:bg-red-600 font-primary rounded-sm py-2 px-4 text-white text-center min-w-40 lg:min-w-32 mt-6"},Q((w=e.searchSettings)==null?void 0:w.no_results_button_label),9,j4e)]))])):e.results&&e.results.length?(k(),M("div",U4e,[(k(!0),M(xe,null,Me(e.results,$=>(k(),M("div",{key:$.id},[be(_4e,{result:$,type:e.category},null,8,["result","type"])]))),128))])):X("",!0),!e.loadingResults&&e.results&&e.results.length&&o.value>1?(k(),M("ul",V4e,[(k(!0),M(xe,null,Me(o.value,$=>(k(),M("li",{key:$,class:"px-2 py-1"},[b("button",{class:pe(["text-sm font-semibold text-ag-black hover:text-ag-red",{"text-ag-red":l($)}]),onClick:S=>c.$emit("set-page",($-1)*e.limit)},Q($),11,q4e)]))),128))])):X("",!0)])}}},gb="safaris",_b="price_desc",H4e="/search",Y4e={__name:"SearchContainer",props:{currencyRates:Object,currencySelectorOptions:Array,searchSettings:Object},setup(e){const t=se(null),r=An({q:"",limit:12,offset:0,category:"safaris",experiences:[],destinations:[],budget:{},duration:{},sort:"price_desc",currency:"USD"});let i=0,n=0;const a=se(!1),s=se(!0),o=se(!0),l=se(null),u=se(0),c=se(null),d=se(!1),h=se(!1),f=se(!1),p=se(!1),m=se(window.innerWidth||1024),g=se(0),v=se(null),x=se(0),_=se(null),y=se(null),w=se(null),$=[{id:"experiences",title:"Experiences"},{id:"destinations",title:"Destinations"},{id:"information",title:"Information"},{id:"safaris",title:"Safari Ideas"}],S=H(()=>m.value<768),E=H(()=>{var J,N,q,te;return!!r.q||r.offset>0||r.destinations.length>0||r.experiences.length>0||((J=r.budget)==null?void 0:J.min)!=null||((N=r.budget)==null?void 0:N.max)!=null||((q=r.duration)==null?void 0:q.min)!=null||((te=r.duration)==null?void 0:te.max)!=null||r.sort!==_b||r.category!==gb}),C=se(I());function I(){return(window.location.pathname.replace(/\/$/,"")||"/")==="/search"&&!window.location.search}function P(){C.value=I()}const T=H(()=>E.value&&!C.value);function D({replace:J=!1}={}){var ee,oe,Se,we,De,Ue;
737const N=new URL(window.location.href);r.q?N.searchParams.set("q",r.q):N.searchParams.delete("q"),r.offset>0?N.searchParams.set("offset",r.offset):N.searchParams.delete("offset"),r.category&&r.category!==gb?N.searchParams.set("category",r.category):N.searchParams.delete("category"),((ee=r.destinations)==null?void 0:ee.length)>0?N.searchParams.set("destinations",r.destinations.join(",")):N.searchParams.delete("destinations"),((oe=r.experiences)==null?void 0:oe.length)>0?N.searchParams.set("experiences",r.experiences.join(",")):N.searchParams.delete("experiences"),((Se=r.budget)==null?void 0:Se.min)!=null?N.searchParams.set("budget_min",r.budget.min):N.searchParams.delete("budget_min"),((we=r.budget)==null?void 0:we.max)!=null?N.searchParams.set("budget_max",r.budget.max):N.searchParams.delete("budget_max"),((De=r.duration)==null?void 0:De.min)!=null?N.searchParams.set("duration_min",r.duration.min):N.searchParams.delete("duration_min"),((Ue=r.duration)==null?void 0:Ue.max)!=null?N.searchParams.set("duration_max",r.duration.max):N.searchParams.delete("duration_max"),r.sort&&r.sort!==_b?N.searchParams.set("sort",r.sort):N.searchParams.delete("sort");const q=N.searchParams.toString(),te=q?`${N.pathname}?${q}`:N.pathname;J?window.history.replaceState({},"",te):window.history.pushState({},"",te),P()}function A(){var J,N;(J=c.value)!=null&&J.budget_range&&(g.value=c.value.budget_range.min,v.value=c.value.budget_range.max),(N=c.value)!=null&&N.duration_range&&(x.value=c.value.duration_range.min,_.value=c.value.duration_range.max)}function z(){window.history.replaceState({},"",H4e),P()}async function R(){r.q="",r.offset=0,r.category=gb,r.experiences=[],r.destinations=[],r.sort=_b,Oe(),qe(),f.value=!1,p.value=!1,z(),await Y({skipUrlUpdate:!0}),await F(),A()}async function O(J){r.destinations=[],r.experiences=[],r.offset=0,r.category=J,Oe(),qe(),await Y(),await F()}function V(J){r.sort=J,r.offset=0,h.value=!1,Y()}async function Y({replaceUrl:J=!1,skipUrlUpdate:N=!1}={}){var te,ee;const q=++i;if(a.value&&!N&&D({replace:J}),a.value&&t.value){const Se=t.value.getBoundingClientRect().top+window.pageYOffset-80;window.scrollTo({top:Se,behavior:"smooth"})}try{s.value=!0;const oe=await Ou.getSearch(r);if(q!==i)return;l.value=((te=oe.data)==null?void 0:te.results)||null,u.value=((ee=oe.data)==null?void 0:ee.total)||0}catch(oe){if(q!==i)return;console.error(oe)}finally{q===i&&(s.value=!1,a.value=!0)}}async function F(){var N;const J=++n;try{o.value=!0;const q=await Ou.getSearchFilters(r);if(J!==n)return;c.value=q.data||null,(N=c.value)!=null&&N.currency&&c.value.currency!=="USD"&&(ze(),j()),ae()===0&&(f.value=!0),ue()===0&&(p.value=!0)}catch(q){if(J!==n)return;console.error(q)}finally{J===n&&(o.value=!1)}}function ae(){var q;const J=((q=c.value)==null?void 0:q.popular_destinations)||[],N=r.destinations||[];return f.value?J.length:J.filter(te=>te.show_in_filter||N.includes(te.slug)).length}function ue(){var q;const J=((q=c.value)==null?void 0:q.popular_experiences)||[],N=r.experiences||[];return p.value?J.length:J.filter(te=>te.show_in_filter||N.includes(te.slug)).length}function Z(){r.offset=0,delete r.budget,qe(),Y(),F()}function K(){r.offset=0,Y()}function fe(){m.value=window.innerWidth||1024,d.value=m.value>=768}function ve(J){r.currency=J.detail.message}function $e(){d.value=!d.value,S.value&&(h.value=!1)}function Re(){h.value=!h.value}function Oe(){r.budget={}}function ze(){var J,N;g.value=c.value?(J=c.value.budget_range)==null?void 0:J.min:0,v.value=c.value?(N=c.value.budget_range)==null?void 0:N.max:1e4,r.budget={min:g.value,max:v.value}}function Be(){ze(),Y()}function qe(){r.duration={}}function j(){var J,N;x.value=c.value?(J=c.value.duration_range)==null?void 0:J.min:0,_.value=c.value?(N=c.value.duration_range)==null?void 0:N.max:30,r.duration={min:x.value,max:_.value}}function W(){j(),Y()}function G(){clearTimeout(y.value),y.value=setTimeout(()=>{var J,N,q,te;!s.value&&a.value&&(r.budget={min:g.value||((N=(J=c.value)==null?void 0:J.budget_range)==null?void 0:N.min),max:v.value||((te=(q=c.value)==null?void 0:q.budget_range)==null?void 0:te.max)},r.offset=0,Y())},300)}function ie(){clearTimeout(w.value),w.value=setTimeout(()=>{var J,N,q,te;!s.value&&a.value&&(r.duration={min:x.value||((N=(J=c.value)==null?void 0:J.duration_range)==null?void 0:N.min),max:_.value||((te=(q=c.value)==null?void 0:q.duration_range)==null?void 0:te.max)},r.offset=0,Y())},300)}function U(J){r.offset=J,Y()}function ne(){f.value=!f.value}function me(){p.value=!p.value}return or(()=>{r.currency=window.localStorage.getItem("selected_currency")||"USD";const J=new URLSearchParams(window.location.search),N=J.get("q");N&&(r.q=N);const q=J.get("offset");q&&(r.offset=parseInt(q,10));const te=J.get("category");te&&(r.category=te);const ee=J.get("destinations");ee&&(r.destinations=ee.split(",").map(kt=>kt.trim()));const oe=J.get("experiences");oe&&(r.experiences=oe.split(",").map(kt=>kt.trim()));const Se=J.get("budget_min");Se&&(r.budget.min=parseInt(Se,10),g.value=r.budget.min);const we=J.get("budget_max");we&&(r.budget.max=parseInt(we,10),v.value=r.budget.max);const De=J.get("duration_min");De&&(r.duration.min=parseInt(De,10),x.value=r.duration.min);const Ue=J.get("duration_max");Ue&&(r.duration.max=parseInt(Ue,10),_.value=r.duration.max);const xt=J.get("sort");xt&&(r.sort=xt),P(),Y(),F(),window.addEventListener("currencyUpdated",ve),window.addEventListener("resize",fe)}),ra(()=>{window.removeEventListener("resize",fe),window.removeEventListener("currencyUpdated",ve)}),(J,N)=>(k(),M("div",{class:"search-container flex flex-wrap gap-4 md:gap-8 font-primary",ref_key:"searchContainer",ref:t},[be(J3e,{"is-mobile":S.value,"show-filters-menu":d.value,"search-settings":e.searchSettings,"search-categories":$,category:r.category,"loading-filters":o.value,filters:c.value||{},budget:r.budget||{},duration:r.duration||{},"show-all-destinations-filters":f.value,"show-all-experiences-filters":p.value,"currency-rates":e.currencyRates,"currency-selector-options":e.currencySelectorOptions,selectedDestinations:r.destinations,"onUpdate:selectedDestinations":N[0]||(N[0]=q=>r.destinations=q),selectedExperiences:r.experiences,"onUpdate:selectedExperiences":N[1]||(N[1]=q=>r.experiences=q),minBudget:g.value,"onUpdate:minBudget":N[2]||(N[2]=q=>g.value=q),maxBudget:v.value,"onUpdate:maxBudget":N[3]||(N[3]=q=>v.value=q),minDuration:x.value,"onUpdate:minDuration":N[4]||(N[4]=q=>x.value=q),maxDuration:_.value,"onUpdate:maxDuration":N[5]||(N[5]=q=>_.value=q),onToggleFiltersMenu:$e,onSelectCategory:O,onFilterChanged:K,onToggleDestinationsFilters:ne,onToggleExperiencesFilters:me,onCommitBudget:G,onResetBudget:Be,onCommitDuration:ie,onResetDuration:W},null,8,["is-mobile","show-filters-menu","search-settings","category","loading-filters","filters","budget","duration","show-all-destinations-filters","show-all-experiences-filters","currency-rates","currency-selector-options","selectedDestinations","selectedExperiences","minBudget","maxBudget","minDuration","maxDuration"]),be(G4e,{q:r.q,"onUpdate:q":N[6]||(N[6]=q=>r.q=q),category:r.category,"search-categories":$,"search-settings":e.searchSettings,results:l.value,offset:r.offset,limit:r.limit,"total-results":u.value,"loading-results":s.value,"is-mobile":S.value,"show-sort-menu":h.value,"show-clear-filters":T.value,onSearch:Z,onSetSort:V,onToggleFiltersMenu:$e,onToggleSortMenu:Re,onSetPage:U,onResetFilters:R},null,8,["q","category","search-settings","results","offset","limit","total-results","loading-results","is-mobile","show-sort-menu","show-clear-filters"])],512))}},W4e={class:"w-full flex-1 relative"},Z4e={class:"relative"},K4e={key:0,class:"z-50 absolute top-12 left-0 border border-gray-700 bg-white rounded shadow-sm min-h-8 max-h-48 w-full overflow-x-hidden overflow-y-scroll",style:{"z-index":"9999"}},X4e=["onClick"],J4e={class:"w-full flex-1 relative"},Q4e={class:"relative"},e$e={key:0,class:"z-50 absolute top-12 left-0 border border-gray-700 bg-white rounded shadow-sm min-h-8 max-h-48 w-full overflow-x-hidden overflow-y-scroll",style:{"z-index":"9999"}},t$e=["onClick"],r$e=["disabled"],i$e={key:0},wl="all",n$e={__name:"C24SearchForm",setup(e){const t=se(null),r=se([]),i=se(""),n=se(null),a=se(!1),s=se([]),o=se(""),l=se(null),u=se(!1),c=se([]),d=se([]),h=se(null),f=se(null),p=se(null),m=se(!1),g=async()=>{try{const P=await Ou.getDefaultSearchDestinations();r.value=P.data||[],c.value=P.data||[],c.value.unshift({title:"All Destinations",slug:wl})}catch{}},v=async()=>{try{const P=await Ou.getDefaultSearchExperiences();s.value=P.data||[],d.value=P.data||[],d.value.unshift({title:"All Experiences",slug:wl})}catch(P){console.error(P)}},x=()=>{const P=new URL(window.location.origin+"/search");P.searchParams.set("destinations",h.value&&h.value.slug!==wl?h.value.slug:""),P.searchParams.set("experiences",f.value&&f.value.slug!==wl?f.value.slug:""),window.open(P.toString())},_=()=>{clearTimeout(n.value),n.value=setTimeout(()=>{y()},300)},y=async()=>{try{if(i.value.trim()===""){h.value=null,c.value=r.value,C();return}const P=await Ou.getSearchDestinations({q:i.value});c.value=P.data||[],a.value=!0}catch(P){console.error(P)}},w=P=>{h.value=P,i.value=P.title,a.value=!1,C()},$=()=>{clearTimeout(l.value),l.value=setTimeout(()=>{S()},300)},S=async()=>{try{if(o.value.trim()===""){f.value=null,d.value=s.value,C();return}const P=await Ou.getSearchExperiences({q:o.value});d.value=P.data||[],u.value=!0}catch(P){console.error(P)}},E=P=>{f.value=P,o.value=P.title,u.value=!1,C()},C=async()=>{try{const P={limit:0};m.value=!0,h.value&&h.value.slug!==wl&&(P.destinations=[h.value.slug]),f.value&&f.value.slug!==wl&&(P.experiences=[f.value.slug]);const T=await Ou.getSearch(P);p.value=T.data||[],m.value=!1}catch(P){console.error(P),m.value=!1}},I=P=>{t.value&&!t.value.contains(P.target)&&(u.value=!1,a.value=!1)};return or(()=>{g(),v(),C(),window.addEventListener("click",I)}),ra(()=>{window.removeEventListener("click",I)}),(P,T)=>(k(),M("div",{class:"flex flex-col md:flex-row justify-center items-center gap-4 w-full",ref_key:"searchComponent",ref:t},[b("div",W4e,[b("div",Z4e,[T[6]||(T[6]=b("div",{class:"absolute top-2 left-2"},[b("svg",{width:"25px",height:"25px",viewBox:"0 0 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg"},[b("path",{d:"M12 21C15.5 17.4 19 14.1764 19 10.2C19 6.22355 15.866 3 12 3C8.13401 3 5 6.22355 5 10.2C5 14.1764 8.5 17.4 12 21Z",stroke:"#000000","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round"}),b("path",{d:"M12 13C13.6569 13 15 11.6569 15 10C15 8.34315 13.6569 7 12 7C10.3431 7 9 8.34315 9 10C9 11.6569 10.3431 13 12 13Z",stroke:"#000000","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round"})])],-1)),it(b("input",{placeholder:"Destinations",class:"pl-10 pr-2 w-full border border-gray-700 outline-none h-10 rounded text-black",type:"text","onUpdate:modelValue":T[0]||(T[0]=D=>i.value=D),onFocusin:T[1]||(T[1]=D=>{u.value=!1,a.value=!0}),onKeyup:T[2]||(T[2]=D=>_())},null,544),[[ui,i.value]])]),a.value&&c.value.length>0?(k(),M("div",K4e,[(k(!0),M(xe,null,Me(c.value,D=>(k(),M("div",{key:D.slug,class:pe(["text-black block text-sm text-left px-2 py-1 hover:bg-gray-100 cursor-pointer",{"border-b border-gray-300":D.slug===wl}]),onClick:A=>w(D)},Q(D.title),11,X4e))),128))])):X("",!0)]),b("div",J4e,[b("div",Q4e,[T[7]||(T[7]=so('<div class="absolute top-2 left-2"><svg width="25px" height="25px" viewBox="0 0 512 512" xmlns="http://www.w3.org/2000/svg"><title>ionicons-v5-n</title><path d="M457.74,170.1a30.26,30.26,0,0,0-11.16-2.1h-.4c-20.17.3-42.79,19.19-54.66,47.76-14.23,34.18-7.68,69.15,14.74,78.14a30.21,30.21,0,0,0,11.15,2.1c20.27,0,43.2-19,55.17-47.76C486.71,214.06,48
7370.06,179.09,457.74,170.1Z" style="fill:none;stroke:#000000;stroke-miterlimit:10;stroke-width:32px;"></path><path d="M327.6,303.48C299.8,257.35,287.8,240,256,240s-43.9,17.46-71.7,63.48c-23.8,39.36-71.9,42.64-83.9,76.07a50.91,50.91,0,0,0-3.6,19.25c0,27.19,20.8,49.2,46.4,49.2,31.8,0,75.1-25.39,112.9-25.39S337,448,368.8,448c25.6,0,46.3-22,46.3-49.2a51,51,0,0,0-3.7-19.25C399.4,346,351.4,342.84,327.6,303.48Z" style="fill:none;stroke:#000000;stroke-miterlimit:10;stroke-width:32px;"></path><path d="M192.51,196a26.53,26.53,0,0,0,4-.3c23.21-3.37,37.7-35.53,32.44-71.85C224,89.61,203.22,64,181.49,64a26.53,26.53,0,0,0-4,.3c-23.21,3.37-37.7,35.53-32.44,71.85C150,170.29,170.78,196,192.51,196Z" style="fill:none;stroke:#000000;stroke-miterlimit:10;stroke-width:32px;"></path><path d="M366.92,136.15c5.26-36.32-9.23-68.48-32.44-71.85a26.53,26.53,0,0,0-4-.3c-21.73,0-42.47,25.61-47.43,59.85-5.26,36.32,9.23,68.48,32.44,71.85a26.53,26.53,0,0,0,4,.3C341.22,196,362,170.29,366.92,136.15Z" style="fill:none;stroke:#000000;stroke-miterlimit:10;stroke-width:32px;"></path><path d="M105.77,293.9c22.39-9,28.93-44,14.72-78.14C108.53,187,85.62,168,65.38,168a30.21,30.21,0,0,0-11.15,2.1c-22.39,9-28.93,44-14.72,78.14C51.47,277,74.38,296,94.62,296A30.21,30.21,0,0,0,105.77,293.9Z" style="fill:none;stroke:#000000;stroke-miterlimit:10;stroke-width:32px;"></path></svg></div>',1)),it(b("input",{placeholder:"Experiences",class:"pl-10 pr-2 w-full border border-gray-700 outline-none p-2 rounded text-black",type:"text","onUpdate:modelValue":T[3]||(T[3]=D=>o.value=D),onFocusin:T[4]||(T[4]=D=>{a.value=!1,u.value=!0}),onKeyup:T[5]||(T[5]=D=>$())},null,544),[[ui,o.value]])]),u.value&&d.value.length>0?(k(),M("div",e$e,[(k(!0),M(xe,null,Me(d.value,D=>(k(),M("div",{key:D.slug,class:pe(["text-black block text-sm text-left px-2 py-1 hover:bg-gray-100 cursor-pointer",{"border-b border-gray-300":D.slug===wl}]),onClick:A=>E(D)},Q(D.title),11,t$e))),128))])):X("",!0)]),b("button",{onClick:x,type:"button",disabled:m.value,class:"button"},[T[8]||(T[8]=Ze(" Show ",-1)),p.value&&p.value.total>=0?(k(),M("span",i$e,Q(p.value.total),1)):X("",!0),T[9]||(T[9]=Ze(" safari ideas ",-1))],8,r$e)],512))}};/** 738* MapLibre GL JS 739* @license 3-Clause BSD. Full text of license: https://github.com/maplibre/maplibre-gl-js/blob/v6.2.0/LICENSE.txt 740*/var a$e=Object.create,pR=Object.defineProperty,s$e=Object.getOwnPropertyDescriptor,o$e=Object.getOwnPropertyNames,l$e=Object.getPrototypeOf,u$e=Object.prototype.hasOwnProperty,M$=(e,t)=>()=>(t||(e((t={exports:{}}).exports,t),e=null),t.exports),c$e=(e,t,r,i)=>{if(t&&typeof t=="object"||typeof t=="function")for(var n=o$e(t),a=0,s=n.length,o;a<s;a++)o=n[a],!u$e.call(e,o)&&o!==r&&pR(e,o,{get:(l=>t[l]).bind(null,o),enumerable:!(i=s$e(t,o))||i.enumerable});return e},d$e=(e,t,r)=>(r=e==null?{}:a$e(l$e(e)),c$e(pR(r,"default",{value:e,enumerable:!0}),e));function de(e,t){this.x=e,this.y=t}de.prototype={clone(){return new de(this.x,this.y)},add(e){return this.clone()._add(e)},sub(e){return this.clone()._sub(e)},multByPoint(e){return this.clone()._multByPoint(e)},divByPoint(e){return this.clone()._divByPoint(e)},mult(e){return this.clone()._mult(e)},div(e){return this.clone()._div(e)},rotate(e){return this.clone()._rotate(e)},rotateAround(e,t){return this.clone()._rotateAround(e,t)},matMult(e){return this.clone()._matMult(e)},unit(){return this.clone()._unit()},perp(){return this.clone()._perp()},round(){return this.clone()._round()},mag(){return Math.sqrt(this.x*this.x+this.y*this.y)},equals(e){return this.x===e.x&&this.y===e.y},dist(e){return Math.sqrt(this.distSqr(e))},distSqr(e){let t=e.x-this.x,r=e.y-this.y;return t*t+r*r},angle(){return Math.atan2(this.y,this.x)},angleTo(e){return Math.atan2(this.y-e.y,this.x-e.x)},angleWith(e){return this.angleWithSep(e.x,e.y)},angleWithSep(e,t){return Math.atan2(this.x*t-this.y*e,this.x*e+this.y*t)},_matMult(e){let t=e[0]*this.x+e[1]*this.y,r=e[2]*this.x+e[3]*this.y;return this.x=t,this.y=r,this},_add(e){return this.x+=e.x,this.y+=e.y,this},_sub(e){return this.x-=e.x,this.y-=e.y,this},_mult(e){return this.x*=e,this.y*=e,this},_div(e){return this.x/=e,this.y/=e,this},_multByPoint(e){return this.x*=e.x,this.y*=e.y,this},_divByPoint(e){return this.x/=e.x,this.y/=e.y,this},_unit(){return this._div(this.mag()),this},_perp(){let e=this.y;return this.y=this.x,this.x=-e,this},_rotate(e){let t=Math.cos(e),r=Math.sin(e),i=t*this.x-r*this.y,n=r*this.x+t*this.y;return this.x=i,this.y=n,this}
vendor: 4,291 bytes, line 740
740,_rotateAround(e,t){let r=Math.cos(e),i=Math.sin(e),n=t.x+r*(this.x-t.x)-i*(this.y-t.y),a=t.y+i*(this.x-t.x)+r*(this.y-t.y);return this.x=n,this.y=a,this},_round(){return this.x=Math.round(this.x),this.y=Math.round(this.y),this},constructor:de},de.convert=function(e){if(e instanceof de)return e;if(Array.isArray(e))return new de(+e[0],+e[1]);if(e.x!==void 0&&e.y!==void 0)return new de(+e.x,+e.y);throw Error("Expected [x, y] or {x, y} point format")};function h$e(e,t,r,i){let n=3*e,a=3*(r-e)-n,s=1-n-a,o=3*t,l=3*(i-t)-o,u=1-o-l;return function(c,d=1e-6){if(c<=0)return 0;if(c>=1)return 1;let h=c;for(let m=0;m<8;m++){let g=((s*h+a)*h+n)*h-c;if(Math.abs(g)<d)return((u*h+l)*h+o)*h;let v=(3*s*h+2*a)*h+n;if(Math.abs(v)<1e-6)break;h-=g/v}let f=0,p=1;h=c;for(let m=0;m<20;m++){let g=((s*h+a)*h+n)*h;if(Math.abs(g-c)<d)break;c>g?f=h:p=h,h=(f+p)*.5}return((u*h+l)*h+o)*h}}let Sk;function mR(){return Sk??(Sk=typeof OffscreenCanvas<"u"&&new OffscreenCanvas(1,1).getContext("2d")&&typeof createImageBitmap=="function"),Sk}let u0;function f$e(){if(u0==null&&(u0=!1,mR())){let e=new OffscreenCanvas(5,5).getContext("2d",{willReadFrequently:!0});if(e){for(let r=0;r<25;r++){let i=r*4;e.fillStyle=`rgb(${i},${i+1},${i+2})`,e.fillRect(r%5,Math.floor(r/5),1,1)}let t=e.getImageData(0,0,5,5).data;for(let r=0;r<100;r++)if(r%4!=3&&t[r]!==r){u0=!0;break}}}return u0||!1}var bi=typeof Float32Array<"u"?Float32Array:Array;function gR(){var e=new bi(9);return bi!=Float32Array&&(e[1]=0,e[2]=0,e[3]=0,e[5]=0,e[6]=0,e[7]=0),e[0]=1,e[4]=1,e[8]=1,e}function p$e(e){var t=e[0],r=e[1],i=e[2],n=e[3],a=e[4],s=e[5],o=e[6],l=e[7],u=e[8];return t*(u*a-s*l)+r*(-u*n+s*o)+i*(l*n-a*o)}function m$e(e,t){var r=Math.sin(t),i=Math.cos(t);return e[0]=i,e[1]=r,e[2]=0,e[3]=-r,e[4]=i,e[5]=0,e[6]=0,e[7]=0,e[8]=1,e}function g$e(e,t){var r=t[0],i=t[1],n=t[2],a=t[3],s=r+r,o=i+i,l=n+n,u=r*s,c=i*s,d=i*o,h=n*s,f=n*o,p=n*l,m=a*s,g=a*o,v=a*l;return e[0]=1-d-p,e[3]=c-v,e[6]=h+g,e[1]=c+v,e[4]=1-u-p,e[7]=f-m,e[2]=h-g,e[5]=f+m,e[8]=1-u-d,e}function _u(){var e=new bi(16);return bi!=Float32Array&&(e[1]=0,e[2]=0,e[3]=0,e[4]=0,e[6]=0,e[7]=0,e[8]=0,e[9]=0,e[11]=0,e[12]=0,e[13]=0,e[14]=0),e[0]=1,e[5]=1,e[10]=1,e[15]=1,e}function Fx(e){var t=new bi(16);return t[0]=e[0],t[1]=e[1],t[2]=e[2],t[3]=e[3],t[4]=e[4],t[5]=e[5],t[6]=e[6],t[7]=e[7],t[8]=e[8],t[9]=e[9],t[10]=e[10],t[11]=e[11],t[12]=e[12],t[13]=e[13],t[14]=e[14],t[15]=e[15],t}function _$e(e,t){return e[0]=t[0],e[1]=t[1],e[2]=t[2],e[3]=t[3],e[4]=t[4],e[5]=t[5],e[6]=t[6],e[7]=t[7],e[8]=t[8],e[9]=t[9],e[10]=t[10],e[11]=t[11],e[12]=t[12],e[13]=t[13],e[14]=t[14],e[15]=t[15],e}function Ms(e){return e[0]=1,e[1]=0,e[2]=0,e[3]=0,e[4]=0,e[5]=1,e[6]=0,e[7]=0,e[8]=0,e[9]=0,e[10]=1,e[11]=0,e[12]=0,e[13]=0,e[14]=0,e[15]=1,e}function xy(e,t){var r=t[0],i=t[1],n=t[2],a=t[3],s=t[4],o=t[5],l=t[6],u=t[7],c=t[8],d=t[9],h=t[10],f=t[11],p=t[12],m=t[13],g=t[14],v=t[15],x=r*o-i*s,_=r*l-n*s,y=r*u-a*s,w=i*l-n*o,$=i*u-a*o,S=n*u-a*l,E=c*m-d*p,C=c*g-h*p,I=c*v-f*p,P=d*g-h*m,T=d*v-f*m,D=h*v-f*g,A=x*D-_*T+y*P+w*I-$*C+S*E;return A?(A=1/A,e[0]=(o*D-l*T+u*P)*A,e[1]=(n*T-i*D-a*P)*A,e[2]=(m*S-g*$+v*w)*A,e[3]=(h*$-d*S-f*w)*A,e[4]=(l*I-s*D-u*C)*A,e[5]=(r*D-n*I+a*C)*A,e[6]=(g*y-p*S-v*_)*A,e[7]=(c*S-h*y+f*_)*A,e[8]=(s*T-o*I+u*E)*A,e[9]=(i*I-r*T-a*E)*A,e[10]=(p*$-m*y+v*x)*A,e[11]=(d*y-c*$-f*x)*A,e[12]=(o*C-s*P-l*E)*A,e[13]=(r*P-i*C+n*E)*A,e[14]=(m*_-p*w-g*x)*A,e[15]=(c*w-d*_+h*x)*A,e):null}function cd(e,t,r){var i=t[0],n=t[1],a=t[2],s=t[3],o=t[4],l=t[5],u=t[6],c=t[7],d=t[8],h=t[9],f=t[10],p=t[11],m=t[12],g=t[13],v=t[14],x=t[15],_=r[0],y=r[1],w=r[2],$=r[3];return e[0]=_*i+y*o+w*d+$*m,e[1]=_*n+y*l+w*h+$*g,e[2]=_*a+y*u+w*f+$*v,e[3]=_*s+y*c+w*p+$*x,_=r[4],y=r[5],w=r[6],$=r[7],e[4]=_*i+y*o+w*d+$*m,e[5]=_*n+y*l+w*h+$*g,e[6]=_*a+y*u+w*f+$*v,e[7]=_*s+y*c+w*p+$*x,_=r[8],y=r[9],w=r[10],$=r[11],e[8]=_*i+y*o+w*d+$*m,e[9]=_*n+y*l+w*h+$*g,e[10]=_*a+y*u+w*f+$*v,e[11]=_*s+y*c+w*p+$*x,_=r[12],y=r[13],w=r[14],$=r[15],e[12]=_*i+y*o+w*d+$*m,e[13]=_*n+y*l+w*h+$*g,e[14]=_*a+y*u+w*f+$*v,e[15]=_*s+y*c+w*p+$*x,e}function ei(e,t,r){var i=r[0],n=r[1],a=r[2],s,o,l,u,c,d,h,f,p,m,g,v;return t===e?(e[12]=t[0]*i+t[4]*n+t[8]*a+t[12],e[13]=t[1]*i+t[5]*n+t[9]*a+t[13],e[14]=t[2]*i+t[6]*n+t[10]*a+t[14],e[15]=t[3]*i+t[7]*n+t[11]*a+t[15]):(s=t[0],o=t[1],l=t[2],u=t[3],c=t[4],d=t[5],h=t[6],f=t[7],p=t[8],m=t[9],g=t[10],v=t[11
vendor: 1,052 bytes, line 740
740],e[0]=s,e[1]=o,e[2]=l,e[3]=u,e[4]=c,e[5]=d,e[6]=h,e[7]=f,e[8]=p,e[9]=m,e[10]=g,e[11]=v,e[12]=s*i+c*n+p*a+t[12],e[13]=o*i+d*n+m*a+t[13],e[14]=l*i+h*n+g*a+t[14],e[15]=u*i+f*n+v*a+t[15]),e}function Li(e,t,r){var i=r[0],n=r[1],a=r[2];return e[0]=t[0]*i,e[1]=t[1]*i,e[2]=t[2]*i,e[3]=t[3]*i,e[4]=t[4]*n,e[5]=t[5]*n,e[6]=t[6]*n,e[7]=t[7]*n,e[8]=t[8]*a,e[9]=t[9]*a,e[10]=t[10]*a,e[11]=t[11]*a,e[12]=t[12],e[13]=t[13],e[14]=t[14],e[15]=t[15],e}function Eh(e,t,r){var i=Math.sin(r),n=Math.cos(r),a=t[4],s=t[5],o=t[6],l=t[7],u=t[8],c=t[9],d=t[10],h=t[11];return t!==e&&(e[0]=t[0],e[1]=t[1],e[2]=t[2],e[3]=t[3],e[12]=t[12],e[13]=t[13],e[14]=t[14],e[15]=t[15]),e[4]=a*n+u*i,e[5]=s*n+c*i,e[6]=o*n+d*i,e[7]=l*n+h*i,e[8]=u*n-a*i,e[9]=c*n-s*i,e[10]=d*n-o*i,e[11]=h*n-l*i,e}function _R(e,t,r){var i=Math.sin(r),n=Math.cos(r),a=t[0],s=t[1],o=t[2],l=t[3],u=t[8],c=t[9],d=t[10],h=t[11];return t!==e&&(e[4]=t[4],e[5]=t[5],e[6]=t[6],e[7]=t[7],e[12]=t[12],e[13]=t[13],e[14]=t[14],e[15]=t[15]),e[0]=a*n-u*i,e[1]=s*n-c*i,e[2]=o*n-d*i,e[3]=l*n-h*i,e[8]=a*i+u*n,e[9]=s*i+c*n,e[10
vendor: 12,664 bytes, line 740
740]=o*i+d*n,e[11]=l*i+h*n,e}function Vl(e,t,r){var i=Math.sin(r),n=Math.cos(r),a=t[0],s=t[1],o=t[2],l=t[3],u=t[4],c=t[5],d=t[6],h=t[7];return t!==e&&(e[8]=t[8],e[9]=t[9],e[10]=t[10],e[11]=t[11],e[12]=t[12],e[13]=t[13],e[14]=t[14],e[15]=t[15]),e[0]=a*n+u*i,e[1]=s*n+c*i,e[2]=o*n+d*i,e[3]=l*n+h*i,e[4]=u*n-a*i,e[5]=c*n-s*i,e[6]=d*n-o*i,e[7]=h*n-l*i,e}function y$e(e,t){return e[0]=t[0],e[1]=0,e[2]=0,e[3]=0,e[4]=0,e[5]=t[1],e[6]=0,e[7]=0,e[8]=0,e[9]=0,e[10]=t[2],e[11]=0,e[12]=0,e[13]=0,e[14]=0,e[15]=1,e}function v$e(e,t,r,i,n){var a=1/Math.tan(t/2);if(e[0]=a/r,e[1]=0,e[2]=0,e[3]=0,e[4]=0,e[5]=a,e[6]=0,e[7]=0,e[8]=0,e[9]=0,e[11]=-1,e[12]=0,e[13]=0,e[15]=0,n!=null&&n!==1/0){var s=1/(i-n);e[10]=(n+i)*s,e[14]=2*n*i*s}else e[10]=-1,e[14]=-2*i;return e}var zx=v$e;function b$e(e,t,r,i,n,a,s){var o=1/(t-r),l=1/(i-n),u=1/(a-s);return e[0]=-2*o,e[1]=0,e[2]=0,e[3]=0,e[4]=0,e[5]=-2*l,e[6]=0,e[7]=0,e[8]=0,e[9]=0,e[10]=2*u,e[11]=0,e[12]=(t+r)*o,e[13]=(n+i)*l,e[14]=(s+a)*u,e[15]=1,e}var qs=b$e;function x$e(e,t){return e[0]===t[0]&&e[1]===t[1]&&e[2]===t[2]&&e[3]===t[3]&&e[4]===t[4]&&e[5]===t[5]&&e[6]===t[6]&&e[7]===t[7]&&e[8]===t[8]&&e[9]===t[9]&&e[10]===t[10]&&e[11]===t[11]&&e[12]===t[12]&&e[13]===t[13]&&e[14]===t[14]&&e[15]===t[15]}function w$e(e,t){var r=e[0],i=e[1],n=e[2],a=e[3],s=e[4],o=e[5],l=e[6],u=e[7],c=e[8],d=e[9],h=e[10],f=e[11],p=e[12],m=e[13],g=e[14],v=e[15],x=t[0],_=t[1],y=t[2],w=t[3],$=t[4],S=t[5],E=t[6],C=t[7],I=t[8],P=t[9],T=t[10],D=t[11],A=t[12],z=t[13],R=t[14],O=t[15];return Math.abs(r-x)<=1e-6*Math.max(1,Math.abs(r),Math.abs(x))&&Math.abs(i-_)<=1e-6*Math.max(1,Math.abs(i),Math.abs(_))&&Math.abs(n-y)<=1e-6*Math.max(1,Math.abs(n),Math.abs(y))&&Math.abs(a-w)<=1e-6*Math.max(1,Math.abs(a),Math.abs(w))&&Math.abs(s-$)<=1e-6*Math.max(1,Math.abs(s),Math.abs($))&&Math.abs(o-S)<=1e-6*Math.max(1,Math.abs(o),Math.abs(S))&&Math.abs(l-E)<=1e-6*Math.max(1,Math.abs(l),Math.abs(E))&&Math.abs(u-C)<=1e-6*Math.max(1,Math.abs(u),Math.abs(C))&&Math.abs(c-I)<=1e-6*Math.max(1,Math.abs(c),Math.abs(I))&&Math.abs(d-P)<=1e-6*Math.max(1,Math.abs(d),Math.abs(P))&&Math.abs(h-T)<=1e-6*Math.max(1,Math.abs(h),Math.abs(T))&&Math.abs(f-D)<=1e-6*Math.max(1,Math.abs(f),Math.abs(D))&&Math.abs(p-A)<=1e-6*Math.max(1,Math.abs(p),Math.abs(A))&&Math.abs(m-z)<=1e-6*Math.max(1,Math.abs(m),Math.abs(z))&&Math.abs(g-R)<=1e-6*Math.max(1,Math.abs(g),Math.abs(R))&&Math.abs(v-O)<=1e-6*Math.max(1,Math.abs(v),Math.abs(O))}function yR(){var e=new bi(3);return bi!=Float32Array&&(e[0]=0,e[1]=0,e[2]=0),e}function Nx(e){var t=new bi(3);return t[0]=e[0],t[1]=e[1],t[2]=e[2],t}function q1(e){var t=e[0],r=e[1],i=e[2];return Math.sqrt(t*t+r*r+i*i)}function Tk(e,t,r){var i=new bi(3);return i[0]=e,i[1]=t,i[2]=r,i}function Xa(e,t,r){return e[0]=t[0]+r[0],e[1]=t[1]+r[1],e[2]=t[2]+r[2],e}function $$e(e,t,r){return e[0]=t[0]-r[0],e[1]=t[1]-r[1],e[2]=t[2]-r[2],e}function ri(e,t,r){return e[0]=t[0]*r,e[1]=t[1]*r,e[2]=t[2]*r,e}function S$e(e,t,r,i){return e[0]=t[0]+r[0]*i,e[1]=t[1]+r[1]*i,e[2]=t[2]+r[2]*i,e}function T$e(e,t){return e[0]=-t[0],e[1]=-t[1],e[2]=-t[2],e}function Ga(e,t){var r=t[0],i=t[1],n=t[2],a=r*r+i*i+n*n;return a>0&&(a=1/Math.sqrt(a)),e[0]=t[0]*a,e[1]=t[1]*a,e[2]=t[2]*a,e}function Fi(e,t){return e[0]*t[0]+e[1]*t[1]+e[2]*t[2]}function ya(e,t,r){var i=t[0],n=t[1],a=t[2],s=r[0],o=r[1],l=r[2];return e[0]=n*l-a*o,e[1]=a*s-i*l,e[2]=i*o-n*s,e}function C$e(e,t,r){var i=t[0],n=t[1],a=t[2],s=r[3]*i+r[7]*n+r[11]*a+r[15];return s||(s=1),e[0]=(r[0]*i+r[4]*n+r[8]*a+r[12])/s,e[1]=(r[1]*i+r[5]*n+r[9]*a+r[13])/s,e[2]=(r[2]*i+r[6]*n+r[10]*a+r[14])/s,e}function k$e(e,t,r){var i=t[0],n=t[1],a=t[2];return e[0]=i*r[0]+n*r[3]+a*r[6],e[1]=i*r[1]+n*r[4]+a*r[7],e[2]=i*r[2]+n*r[5]+a*r[8],e}function yb(e,t,r){var i=r[0],n=r[1],a=r[2],s=r[3],o=t[0],l=t[1],u=t[2],c=n*u-a*l,d=a*o-i*u,h=i*l-n*o;return c+=c,d+=d,h+=h,e[0]=o+s*c+n*h-a*d,e[1]=l+s*d+a*c-i*h,e[2]=u+s*h+i*d-n*c,e}function c0(e,t,r,i){var n=[],a=[];return n[0]=t[0]-r[0],n[1]=t[1]-r[1],n[2]=t[2]-r[2],a[0]=n[0],a[1]=n[1]*Math.cos(i)-n[2]*Math.sin(i),a[2]=n[1]*Math.sin(i)+n[2]*Math.cos(i),e[0]=a[0]+r[0],e[1]=a[1]+r[1],e[2]=a[2]+r[2],e}function Sf(e,t,r,i){var n=[],a=[];return n[0]=t[0]-r[0],n[1]=t[1]-r[1],n[2]=t[2]-r[2],a[0]=n[2]*Math.sin(i)+n[0]*Math.cos(i),a[1]=n[1],a[2]=n[2]*Math.cos(i)-n[0]*Math.sin(i),e[0]=a[0]+r[0],e[1]=a[1]+r[1],e[2]=a[2]+r[2],e}function vb(e,t,r,i){var n=[],a=[];return n[0]=t[0]-r[0],n[1]=t[1]-r[1],n[2]=t[2]-r[2],a[0]=n[0]*Math.cos(i)-n[1]*Math.sin(i),a[1]=n[0]*Math.sin(i)+n[1]*Math.cos(i),a[2]=n[2],e[0]=a[0]+r[0],e[1]=a[1]+r[1],e[2]=a[2]+r[2],e}function E$e(e){return e[0]=0,e[1]=0,e[2]=0,e}var ll=$$e,wy=q1;(function(){var e=yR();return function(t,r,i,n,a,s){var o,l;for(r||(r=3),i||(i=0),l=n?Math.min(n*r+i,t.length):t.length,o=i;o<l;o+=r)e[0]=t[o],e[1]=t[o+1],e[2]=t[o+2],a(e,e,s),t[o]=e[0],t[o+1]=e[1],t[o+2]=e[2];return t}})();function P$e(){var e=new bi(4);return bi!=Float32Array&&(e[0]=0,e[1]=0,e[2]=0,e[3]=0),e}function M$e(e,t,r){return e[0]=t[0]*r[0],e[1]=t[1]*r[1],e[2]=t[2]*r[2],e[3]=t[3]*r[3],e}function I$e(e,t,r){return e[0]=t[0]*r,e[1]=t[1]*r,e[2]=t[2]*r,e[3]=t[3]*r,e}function A$e(e,t){var r=t[0],i=t[1],n=t[2],a=t[3],s=r*r+i*i+n*n+a*a;return s>0&&(s=1/Math.sqrt(s)),e[0]=r*s,e[1]=i*s,e[2]=n*s,e[3]=a*s,e}function _i(e,t,r){var i=t[0],n=t[1],a=t[2],s=t[3];return e[0]=r[0]*i+r[4]*n+r[8]*a+r[12]*s,e[1]=r[1]*i+r[5]*n+r[9]*a+r[13]*s,e[2]=r[2]*i+r[6]*n+r[10]*a+r[14]*s,e[3]=r[3]*i+r[7]*n+r[11]*a+r[15]*s,e}var D$e=M$e;(function(){var e=P$e();return function(t,r,i,n,a,s){var o,l;for(r||(r=4),i||(i=0),l=n?Math.min(n*r+i,t.length):t.length,o=i;o<l;o+=r)e[0]=t[o],e[1]=t[o+1],e[2]=t[o+2],e[3]=t[o+3],a(e,e,s),t[o]=e[0],t[o+1]=e[1],t[o+2]=e[2],t[o+3]=e[3];return t}})();function Ck(){var e=new bi(4);return bi!=Float32Array&&(e[0]=0,e[1]=0,e[2]=0),e[3]=1,e}function R$e(e,t,r){r*=.5;var i=Math.sin(r);return e[0]=i*t[0],e[1]=i*t[1],e[2]=i*t[2],e[3]=Math.cos(r),e}function c_(e,t,r,i){var n=t[0],a=t[1],s=t[2],o=t[3],l=r[0],u=r[1],c=r[2],d=r[3],h,f=n*l+a*u+s*c+o*d,p,m,g;return f<0&&(f=-f,l=-l,u=-u,c=-c,d=-d),1-f>1e-6?(h=Math.acos(f),p=Math.sin(h),m=Math.sin((1-i)*h)/p,g=Math.sin(i*h)/p):(m=1-i,g=i),e[0]=m*n+g*l,e[1]=m*a+g*u,e[2]=m*s+g*c,e[3]=m*o+g*d,e}function O$e(e,t){var r=t[0]+t[4]+t[8],i;if(r>0)i=Math.sqrt(r+1),e[3]=.5*i,i=.5/i,e[0]=(t[5]-t[7])*i,e[1]=(t[6]-t[2])*i,e[2]=(t[1]-t[3])*i;else{var n=0;t[4]>t[0]&&(n=1),t[8]>t[n*3+n]&&(n=2);var a=(n+1)%3,s=(n+2)%3;i=Math.sqrt(t[n*3+n]-t[a*3+a]-t[s*3+s]+1),e[n]=.5*i,i=.5/i,e[3]=(t[a*3+s]-t[s*3+a])*i,e[a]=(t[a*3+n]+t[n*3+a])*i,e[s]=(t[s*3+n]+t[n*3+s])*i}return e}function vR(e,t,r,i){var n=arguments.length>4&&arguments[4]!==void 0?arguments[4]:"zyx",a=Math.PI/360;t*=a,i*=a,r*=a;var s=Math.sin(t),o=Math.cos(t),l=Math.sin(r),u=Math.cos(r),c=Math.sin(i),d=Math.cos(i);switch(n){case"xyz":e[0]=s*u*d+o*l*c,e[1]=o*l*d-s*u*c,e[2]=o*u*c+s*l*d,e[3]=o*u*d-s*l*c;break;case"xzy":e[0]=s*u*d-o*l*c,e[1]=o*l*d-s*u*c,e[2]=o*u*c+s*l*d,e[3]=o*u*d+s*l*c;break;case"yxz":e[0]=s*u*d+o*l*c,e[1]=o*l*d-s*u*c,e[2]=o*u*c-s*l*d,e[3]=o*u*d+s*l*c;break;case"yzx":e[0]=s*u*d+o*l*c,e[1]=o*l*d+s*u*c,e[2]=o*u*c-s*l*d,e[3]=o*u*d-s*l*c;break;case"zxy":e[0]=s*u*d-o*l*c,e[1]=o*l*d+s*u*c,e[2]=o*u*c+s*l*d,e[3]=o*u*d-s*l*c;break;case"zyx":e[0]=s*u*d-o*l*c,e[1]=o*l*d+s*u*c,e[2]=o*u*c-s*l*d,e[3]=o*u*d+s*l*c;break;default:throw Error("Unknown angle order "+n)}return e}var kk=A$e;(function(){var e=yR(),t=Tk(1,0,0),r=Tk(0,1,0);return function(i,n,a){var s=Fi(n,a);return s<-.999999?(ya(e,t,n),wy(e)<1e-6&&ya(e,r,n),Ga(e,e),R$e(i,e,Math.PI),i):s>.999999?(i[0]=0,i[1]=0,i[2]=0,i[3]=1,i):(ya(e,n,a),i[0]=e[0],i[1]=e[1],i[2]=e[2],i[3]=1+s,kk(i,i))}})(),(function(){var e=Ck(),t=Ck();return function(r,i,n,a,s,o){return c_(e,i,s,o),c_(t,n,a,o),c_(r,e,t,2*o*(1-o)),r}})(),(function(){var e=gR();return function(t,r,i,n){return e[0]=i[0],e[3]=i[1],e[6]=i[2],e[1]=n[0],e[4]=n[1],e[7]=n[2],e[2]=-r[0],e[5]=-r[1],e[8]=-r[2],kk(t,O$e(t,e))}})();function za(){var e=new bi(2);return bi!=Float32Array&&(e[0]=0,e[1]=0),e}function Bx(e){var t=new bi(2);return t[0]=e[0],t[1]=e[1],t}function jx(e,t){var r=new bi(2);return r[0]=e,r[1]=t,r}function L$e(e,t,r){return e[0]=t[0]+r[0],e[1]=t[1]+r[1],e}function F$e(e,t,r){return e[0]=t[0]-r[0],e[1]=t[1]-r[1],e}function $y(e,t,r){return e[0]=t[0]*r,e[1]=t[1]*r,e}function bb(e,t,r,i){return e[0]=t[0]+r[0]*i,e[1]=t[1]+r[1]*i,e}function Sy(e){var t=e[0],r=e[1];return Math.sqrt(t*t+r*r)}function z$e(e){var t=e[0],r=e[1];return t*t+r*r}function N$e(e,t){var r=t[0],i=t[1],n=r*r+i*i;return n>0&&(n=1/Math.sqrt(n)),e[0]=t[0]*n,e[1]=t[1]*n,e}function bR(e,t){return e[0]*t[0]+e[1]*t[1]}function B$e(e,t,r,i){var n=t[0]-r[0],a=t[1]-r[1],s=Math.sin(i),o=Math.cos(i);return e[0]=n*o-a*s+r[0],e[1]=n*s+a*o+r[1],e}function j$e(e,t){var r=e[0],i=e[1],n=t[0],a=t[1];return Math.abs(Math.atan2(i*n-r*a,r*n+i*a))}function Ek(e){return e[0]=0,e[1]=0,e}var d0=F$e,U$e=z$e;(function(){var e=za();return function(t,r,i,n,a,s){var o,l;for(r||(r=2),i||(i=0),l=n?Math.min(n*r+i,t.length):t.length,o=i;o<l;o+=r)e[0]=t[o],e[1]=t[o+1],a(e,e,s),t[o]=e[0],t[o+1]=e[1];return t}})();const ye=8192;function Ca(e,t,r){return t*(ye/(e.tileSize*2**(r-e.tileID.overscaledZ)))}function mn(e){return e instanceof Error?e:Error(typeof e=="string"?e:String(e))}function Tf(){return new Float64Array(4)}function Kr(){return new Float64Array(3)}function Uu(){return new Float64Array(16)}function h0(){let e=new Float64Array(16);return Ms(e),e}function xR(){let e=new Float32Array(16);return Ms(e),e}function lu(e,t,r,i,n=!1){if(!r[0]&&!r[1])return[0,0];let a=n?i==="map"?-e.bearingInRadians:0:i==="viewport"?e.bearingInRadians:0;if(a){let s=Math.sin(a),o=Math.cos(a);r=[r[0]*o-r[1]*s,r[0]*s+r[1]*o]}return[n?r[0]:Ca(t,r[0],e.zoom),n?r[1]:Ca(t,r[1],e.zoom)]}function Ux(e,t){return e[0]*t[0]+e[1]*t[1]+e[2]*t[2]+e[3]}function Aa(e,t,r){let i=p$e([e[0],e[1],e[2],t[0],t[1],t[2],r[0],r[1],r[2]]);if(i===0)return null;let n=ya([],[t[0],t[1],t[2]],[r[0],r[1],r[2]]),a=ya([],[r[0],r[1],r[2]],[e[0],e[1],e[2]]),s=ya([],[e[0],e[1],e[2]],[t[0],t[1],t[2]]),o=ri([],n,-e[3]);return Xa(o,o,ri([],a,-t[3])),Xa(o,o,ri([],s,-r[3])),ri(o,o,1/i),o}function V$e(e,t,r){let i=e[0]*r[0]+e[1]*r[1]+e[2]*r[2],n=t[0]*r[0]+t[1]*r[1]+t[2]*r[2];return n===0?null:(-i-r[3])/n}function f0(e,t,r,i){let n=Math.sqrt(e*e+t*t),a=Math.sqrt(r*r+i*i);e/=n,t/=n,r/=a,i/=a;let s=e*r+t*i,o=Math.acos(s);return-t*r+e*i>0?o:-o}function na(e,t){let r=Ph(e,360),i=Ph(t,360),n=i-r,a=i>r?n-360:n+360;return Math.abs(n)<Math.abs(a)?n:a}function p0(e,t){let r=Ph(e,Math.PI*2),i=Ph(t,Math.PI*2);return Math.min(Math.abs(r-i),Math.abs(r-i+Math.PI*2),Math.abs(r-i-Math.PI*2))}function Ph(e,t){return(e%t+t)%t}function d_(e,t,r,i,n){return Ep(i,n,Ot((e-t)/(r-t),0,1))}function Ep(e,t,r){return e*(1-r)+t*r}function q$e(e){let t=1/0,r=1/0,i=-1/0,n=-1/0;for(let a of e)t=Math.min(t,a.x),r=Math.min(r,a.y),i=Math.max(i,a.x),n=Math.max(n,a.y);return[t,r,i,n]}function G$e(e){if(!e.length)return new Set;let t=Math.max(...e.map(l=>l.canonical.z)),r=1/0,i=-1/0,n=1/0,a=-1/0,s=[];for(let l of e){let{x:u,y:c,z:d}=l.canonical,h=2**(t-d),f=u*h,p=c*h;s.push({id:l,x:f,y:p}),f<r&&(r=f),f>i&&(i=f),p<n&&(n=p),p>a&&(a=p)}let o=new Set;for(let l of s)(l.x===r||l.x===i||l.y===n||l.y===a)&&o.add(l.id);return o}function H$e(e){if(e<=0)return 0;if(e>=1)return 1;let t=e*e,r=t*e;return 4*(e<.5?r:3*(e-t)+r-.75)}function I$(e,t,r,i){return h$e(e,t,r,i)}const Vx=I$(.25,.1,.25,1);function Ot(e,t,r){return Math.min(r,Math.max(t,e))}function ys(e,t,r){let i=r-t,n=((e-t)%i+i)%i+t;return n===t?r:n}function Ne(e,...t){for(let r of t)for(let i in r)e[i]=r[i];return e}function og(e,t){let r={};for(let i of t)i in e&&(r[i]=e[i]);return r}let Y$e=1;function wR(){return Y$e++}function W$e(e){return Math.log(e)/Math.LN2%1==0}function Z$e(e){return e<=1?1:2**Math.ceil(Math.log(e)/Math.LN2)}function In(e){return 2**e}function cn(e){return Math.log(e)/Math.LN2}function da(e,t,r){if(t<=0)return e;let i=1/t;return r===void 0||Math.abs(r)<1e-10?Math.round(e*i)/i:(r>0?Math.ceil(e*i-1e-9):Math.floor(e*i+1e-10))/i}function A$(e,t,r){let i={};for(let n in e)i[n]=t.call(this,e[n],n,e);return i}function $R(e,t,r){let i={};for(let n in e)t.call(this,e[n],n,e)&&(i[n]=e[n]);return i}function Gs(e,t){if(Array.isArray(e)){if(!Array.isArray(t)||e.length!==t.length)return!1;for(let r=0;r<e.length;r++)if(!Gs(e[r],t[r]))return!1;return!0}if(typeof e=="object"&&e&&t!==null){if(typeof t!="object"||Object.keys(e).length!==Object.keys(t).length)return!1;for(let r in e)if(!Gs(e[r],t[r]))return!1;return!0}return e===t}function jn(e){return Array.isArray(e)?e.map(jn):typeof e=="object"&&e?A$(e,jn):e}const Pk={};function vr(e){Pk[e]||(typeof console<"u"&&console.warn(e),Pk[e]=!0)}function ql(e,t,r){return(r.y-e.y)*(t.x-e.x)>(t.y-e.y)*(r.x-e.x)}
740function K$e(e,t,r,i){let n=t.y-e.y,a=t.x-e.x,s=i.y-r.y,o=i.x-r.x,l=s*a-o*n;if(l===0)return null;let u=e.y-r.y,c=e.x-r.x,d=(o*u-s*c)/l;return new de(e.x+d*a,e.y+d*n)}function X$e([e,t,r]){return t+=90,t*=Math.PI/180,r*=Math.PI/180,[e*Math.cos(t)*Math.sin(r),e*Math.sin(t)*Math.sin(r),e*Math.cos(r)]}function Mh(e){return typeof WorkerGlobalScope<"u"&&e!==void 0&&e instanceof WorkerGlobalScope}function J$e(e){let t=/(?:^|(?:\s*\,\s*))([^\x00-\x20\(\)<>@\,;\:\\"\/\[\]\?\=\{\}\x7F]+)(?:\=(?:([^\x00-\x20\(\)<>@\,;\:\\"\/\[\]\?\=\{\}\x7F]+)|(?:\"((?:[^"\\]|\\.)*)\")))?/g,r={};if(e.replace(t,(i,n,a,s)=>{let o=a||s;return r[n]=!o||o.toLowerCase(),""}),r["max-age"]){let i=parseInt(r["max-age"],10);isNaN(i)?delete r["max-age"]:r["max-age"]=i}return r}let xb=null;function Q$e(e){if(xb==null){let t=e.navigator?e.navigator.userAgent:null;xb=!!e.safari||!!(t&&(/\b(iPad|iPhone|iPod)\b/.test(t)||t.match("Safari")&&!t.match("Chrome")))}return xb}function uc(e){return typeof ImageBitmap<"u"&&e instanceof ImageBitmap}const eSe=async(e,t)=>{if(e.byteLength===0)return createImageBitmap(new ImageData(1,1),t);let r=new Blob([new Uint8Array(e)],{type:"image/png"});try{return createImageBitmap(r,t)}catch(i){throw Error(`Could not load image because of ${mn(i).message}. Please make sure to use a supported image type such as PNG or JPEG. Note that SVGs are not supported.`)}},Mk="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAYAAAAfFcSJAAAAC0lEQVQYV2NgAAIAAAUAAarVyFEAAAAASUVORK5CYII=",tSe=e=>new Promise((t,r)=>{let i=new Image;i.onload=()=>{t(i),URL.revokeObjectURL(i.src),i.onload=null,window.requestAnimationFrame(()=>i.src=Mk)},i.onerror=()=>r(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."));let n=new Blob([new Uint8Array(e)],{type:"image/png"});i.src=e.byteLength?URL.createObjectURL(n):Mk});function rSe(e,t,r,i,n){let a=Math.max(-t,0)*4,s=(Math.max(0,r)-r)*i*4+a,o=i*4,l=Math.max(0,t),u=Math.max(0,r),c=Math.min(e.width,t+i),d=Math.min(e.height,r+n);return{rect:{x:l,y:u,width:c-l,height:d-u},layout:[{offset:s,stride:o}]}}async function iSe(e,t,r,i,n){if(typeof VideoFrame>"u")throw Error("VideoFrame not supported");let a=new VideoFrame(e,{timestamp:0});try{let s=a==null?void 0:a.format;if(!s||!(s.startsWith("BGR")||s.startsWith("RGB")))throw Error(`Unrecognized format ${s}`);let o=s.startsWith("BGR"),l=new Uint8ClampedArray(i*n*4);if(await a.copyTo(l,rSe(e,t,r,i,n)),o)for(let u=0;u<l.length;u+=4){let c=l[u];l[u]=l[u+2],l[u+2]=c}return l}finally{a.close()}}function qx(e,t,r,i){return e.addEventListener(t,r,i),{unsubscribe:()=>{e.removeEventListener(t,r,i)}}}function zr(e){return e*Math.PI/180}function Sd(e){return e/Math.PI*180}function SR(e,t){return e.roll==t.roll&&e.pitch==t.pitch&&e.bearing==t.bearing}function nSe(e){let t=new Float64Array(9);g$e(t,e);let r=Sd(-Math.asin(Ot(t[2],-1,1))),i,n;return Math.hypot(t[5],t[8])<.001?(i=0,n=-Sd(Math.atan2(t[3],t[4]))):(i=Sd(t[5]===0&&t[8]===0?0:Math.atan2(t[5],t[8])),n=Sd(t[1]===0&&t[0]===0?0:Math.atan2(t[1],t[0]))),{roll:i,pitch:r+90,bearing:n}}function TR(e,t,r){let i=jx(t.x-r.x,t.y-r.y),n=jx(e.x-r.x,e.y-r.y),a=i[0]*n[1]-i[1]*n[0];return Sd(Math.atan2(a,bR(i,n)))}function Ik(e,t,r){let i=new Float64Array(4);return vR(i,e,t-90,r),i}const ul=85.051129,CR={touchstart:!0,touchmove:!0,touchmoveWindow:!0,touchend:!0,touchcancel:!0},kR={dblclick:!0,click:!0,mouseover:!0,mouseout:!0,mousedown:!0,mousemove:!0,mousemoveWindow:!0,mouseup:!0,mouseupWindow:!0,contextmenu:!0,wheel:!0};function aSe(e,t){return CR[t]&&"touches"in e}function sSe(e,t){var n,a;if(!kR[t])return!1;let r=e,i=((a=(n=r==null?void 0:r.target)==null?void 0:n.ownerDocument)==null?void 0:a.defaultView)||window;return r instanceof i.MouseEvent||r instanceof i.WheelEvent}function oSe(e){return CR[e]||kR[e]}const Ak="AbortError";var lg=class extends Error{constructor(e=Ak){super(e instanceof Error?e.message:e),this.name=Ak,e instanceof Error&&e.stack&&(this.stack=e.stack)}};function uu(e){return e instanceof Error&&e.name==="AbortError"}function ER(e){if(e.aborted)throw new lg(e.reason)}const cl={MAX_PARALLEL_IMAGE_REQUESTS:16,MAX_PARALLEL_IMAGE_REQUESTS_PER_FRAME:8,MAX_TILE_CACHE_ZOOM_LEVELS:5,REGISTERED_PROTOCOLS:{},WORKER_URL:""};function PR(e){return cl.REGISTERED_PROTOCOLS[e.substring(0,e.indexOf("://"))]}function Dk(e,t){cl.REGISTERED_PROTOCOLS[e]=t}function lSe(e){delete cl.REGISTERED_PROTOCOLS[e]}
740const Gx="global-dispatcher";var Ty=class extends Error{constructor(e,t,r,i){super(`AJAXError: ${t} (${e}): ${r}`),this.status=e,this.statusText=t,this.url=r,this.body=i}};function D$(){var e;if(Mh(self))return(e=self.worker)==null?void 0:e.referrer;if(window.location.protocol==="blob:")try{return window.parent.location.href}catch{}return window.location.href}const uSe=e=>{var t;return e.startsWith("file:")||((t=D$())==null?void 0:t.startsWith("file:"))&&!/^\w+:/.test(e)};async function cSe(e,t){let r=new Request(e.url,{method:e.method||"GET",body:e.body,credentials:e.credentials,headers:e.headers,cache:e.cache,referrer:D$(),referrerPolicy:e.referrerPolicy,signal:t.signal});e.type==="json"&&!r.headers.has("Accept")&&r.headers.set("Accept","application/json");let i;try{i=await fetch(r)}catch(s){throw uu(s)?s:new Ty(0,mn(s).message,e.url,new Blob)}if(!i.ok){let s=await i.blob();throw new Ty(i.status,i.statusText,e.url,s)}let n;n=e.type==="arrayBuffer"||e.type==="image"?i.arrayBuffer():e.type==="json"?i.json():i.text();let a=await n;return ER(t.signal),{data:a,cacheControl:i.headers.get("Cache-Control"),expires:i.headers.get("Expires"),etag:i.headers.get("ETag")}}function dSe(e,t){return new Promise((r,i)=>{var a;let n=new XMLHttpRequest;n.open(e.method||"GET",e.url,!0),(e.type==="arrayBuffer"||e.type==="image")&&(n.responseType="arraybuffer");for(let s in e.headers)n.setRequestHeader(s,e.headers[s]);e.type==="json"&&(n.responseType="text",(a=e.headers)!=null&&a.Accept||n.setRequestHeader("Accept","application/json")),n.withCredentials=e.credentials==="include",n.onerror=()=>{i(Error(n.statusText))},n.onload=()=>{if(!t.signal.aborted)if((n.status>=200&&n.status<300||n.status===0)&&n.response!==null){let s=n.response;if(e.type==="json")try{s=JSON.parse(n.response)}catch(o){i(o);return}r({data:s,cacheControl:n.getResponseHeader("Cache-Control"),expires:n.getResponseHeader("Expires"),etag:n.getResponseHeader("ETag")})}else{let s=new Blob([n.response],{type:n.getResponseHeader("Content-Type")});i(new Ty(n.status,n.statusText,e.url,s))}},t.signal.addEventListener("abort",()=>{n.abort(),i(new lg(t.signal.reason))}),n.send(e.body)})}const G1=async function(e,t){var r,i;if(e.url.includes("://")&&!/^https?:|^file:/.test(e.url)){let n=PR(e.url);if(n){let a=await n(e,t);return!a.data&&e.type==="arrayBuffer"?Ne(a,{data:new ArrayBuffer(0)}):a}if(Mh(self)&&((r=self.worker)!=null&&r.actor))return self.worker.actor.sendAsync({type:"GR",data:e,targetMapId:Gx},t)}if(!uSe(e.url)){if(fetch&&Request&&AbortController&&Object.hasOwn(Request.prototype,"signal"))return cSe(e,t);if(Mh(self)&&((i=self.worker)!=null&&i.actor))return self.worker.actor.sendAsync({type:"GR",data:e,mustQueue:!0,targetMapId:Gx},t)}return dSe(e,t)},H1=(e,t)=>G1(Ne(e,{type:"json"}),t),hSe=(e,t)=>G1(Ne(e,{type:"arrayBuffer"}),t);function MR(e){if(!e||e.startsWith("data:image/"))return!0;if(e.startsWith("blob:")&&(e=e.slice(5),e.startsWith("null")))return!1;if(e.indexOf("://")<=0)return!0;let t=new URL(e),r=window.location;return t.protocol===r.protocol&&t.host===r.host}const fSe=e=>{let t=window.document.createElement("video");return t.muted=!0,new Promise(r=>{t.onloadstart=()=>{r(t)};for(let i of e){let n=window.document.createElement("source");MR(i)||(t.crossOrigin="Anonymous"),n.src=i,t.appendChild(n)}})};function Rk(e,t,r){var i;(i=r[e])!=null&&i.includes(t)||(r[e]||(r[e]=[]),r[e].push(t))}function wb(e,t,r){if(r!=null&&r[e]){let i=r[e].indexOf(t);i!==-1&&r[e].splice(i,1)}}var ug=class{constructor(e,t={}){Ne(this,t),this.type=e}},He=class extends ug{constructor(e,t={}){super("error",Ne({error:e},t))}},Rn=class{on(e,t){return this._listeners||(this._listeners={}),Rk(e,t,this._listeners),{unsubscribe:()=>{this.off(e,t)}}}off(e,t){return wb(e,t,this._listeners),wb(e,t,this._oneTimeListeners),this}once(e,t){return t?(this._oneTimeListeners||(this._oneTimeListeners={}),Rk(e,t,this._oneTimeListeners),this):new Promise(r=>this.once(e,r))}fire(e,t){var i,n;typeof e=="string"&&(e=new ug(e,t||{}));let r=e.type;if(this.listens(r)){e.target=this;let a=(i=this._listeners)!=null&&i[r]?this._listeners[r].slice():[];for(let l of a)l.call(this,e);let s=(n=this._oneTimeListeners)!=null&&n[r]?this._oneTimeListeners[r].slice():[];for(let l of s)wb(r,l,this._oneTimeListeners),l.call(this,e);let o=this._eventedParent;o&&(Ne(e,typeof this._eventedParentData=="function"?this._eventedParentData():this._eventedParentData),o.fire(e))}else e instanceof He&&console.error(e.error);return this}listens(e){var t,r,i,n,a;return((r=(t=this._listeners)==null?void 0:t[e])==null?void 0:r.length)>0||((n=(i=this._oneTimeListeners)==null?void 0:i[e])==null?void 0:n.length)>0||((a=this._eventedParent)==null?void 0:a.listens(e))}setEventedParent(e,t){return this._eventedParent=e,this._eventedParentData=t,this}};const ce={$version:8,$root:{version:{required:!0,type:"enum",values:[8]},name:{type:"string"},metadata:{type:"*"},center:{type:"array",value:"number",length:2},centerAltitude:{type:"number"},zoom:{type:"number"}
vendor: 14,404 bytes, line 740
740,bearing:{type:"number",default:0,period:360,units:"degrees"},pitch:{type:"number",default:0,units:"degrees"},roll:{type:"number",default:0,units:"degrees"},state:{type:"state",default:{}},light:{type:"light"},sky:{type:"sky"},projection:{type:"projection"},terrain:{type:"terrain"},sources:{required:!0,type:"sources"},sprite:{type:"sprite"},glyphs:{type:"string"},"font-faces":{type:"fontFaces"},transition:{type:"transition"},layers:{required:!0,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:!0,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:!1},encoding:{type:"enum",values:{mvt:{},mlt:{}},default:"mvt"},"*":{type:"*"}},source_raster:{type:{required:!0,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:!1},"*":{type:"*"}},source_raster_dem:{type:{required:!0,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:{},custom:{}},default:"mapbox"},redFactor:{type:"number",default:1},blueFactor:{type:"number",default:1},greenFactor:{type:"number",default:1},baseShift:{type:"number",default:0},volatile:{type:"boolean",default:!1},"*":{type:"*"}},source_geojson:{type:{required:!0,type:"enum",values:{geojson:{}}},data:{required:!0,type:"*"},maxzoom:{type:"number",default:18},attribution:{type:"string"},buffer:{type:"number",default:128,maximum:512,minimum:0},filter:{type:"filter"},tolerance:{type:"number",default:.375},cluster:{type:"boolean",default:!1},clusterRadius:{type:"number",default:50,minimum:0},clusterMaxZoom:{type:"number"},clusterMinPoints:{type:"number"},clusterProperties:{type:"*"},lineMetrics:{type:"boolean",default:!1},generateId:{type:"boolean",default:!1},promoteId:{type:"promoteId"}},source_video:{type:{required:!0,type:"enum",values:{video:{}}},urls:{required:!0,type:"array",value:"string"},coordinates:{required:!0,type:"array",length:4,value:{type:"array",length:2,value:"number"}}},source_image:{type:{required:!0,type:"enum",values:{image:{}}},url:{required:!0,type:"string"},coordinates:{required:!0,type:"array",length:4,value:{type:"array",length:2,value:"number"}}},layer:{id:{type:"string",required:!0},type:{type:"enum",values:{fill:{},line:{},symbol:{},circle:{},heatmap:{},"fill-extrusion":{},raster:{},hillshade:{},"color-relief":{},background:{}},required:!0},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_color-relief","layout_background"],layout_background:{visibility:{type:"enum",values:{visible:{},none:{}},default:"visible",expression:{interpolated:!1,parameters:["global-state"]},"property-type":"data-constant"}},layout_fill:{"fill-sort-key":{type:"number",expression:{interpolated:!1,parameters:["zoom","feature"]},"property-type":"data-driven"},visibility:{type:"enum",values:{visible:{},none:{}},default:"visible",expression:{interpolated:!1,parameters:["global-state"]},"property-type":"data-constant"}},layout_circle:{"circle-sort-key":{type:"number",expression:{interpolated:!1,parameters:["zoom","feature"]},"property-type":"data-driven"},visibility:{type:"enum",values:{visible:{},none:{}},default:"visible",expression:{interpolated:!1,parameters:["global-state"]},"property-type":"data-constant"}},layout_heatmap:{visibility:{type:"enum",values:{visible:{},none:{}},default:"visible",expression:{interpolated:!1,parameters:["global-state"]},"property-type":"data-constant"}},"layout_fill-extrusion":{visibility:{type:"enum",values:{visible:{},none:{}},default:"visible",expression:{interpolated:!1,parameters:["global-state"]},"property-type":"data-constant"},"fill-extrusion-rounded-corner-distance":{type:"number",default:0,minimum:0,units:"meters","property-type":"constant"}},layout_line:{"line-cap":{type:"enum",values:{butt:{},round:{},square:{}},default:"butt",expression:{interpolated:!1,parameters:["zoom","feature"]},"property-type":"data-driven"},"line-join":{type:"enum",values:{bevel:{},round:{},miter:{}},default:"miter",expression:{interpolated:!1,parameters:["zoom","feature"]},"property-type":"data-driven"},"line-miter-limit":{type:"number",default:2,requires:[{"line-join":"miter"}],expression:{interpolated:!0,parameters:["zoom","feature"]},"property-type":"data-driven"},"line-round-limit":{type:"number",default:1.05,requires:[{"line-join":"round"}],expression:{interpolated:!0,parameters:["zoom","feature"]},"property-type":"data-driven"},"line-sort-key":{type:"number",expression:{interpolated:!1,parameters:["zoom","feature"]},"property-type":"data-driven"},visibility:{type:"enum",values:{visible:{},none:{}},default:"visible",expression:{interpolated:!1,parameters:["global-state"]},"property-type":"data-constant"}},layout_symbol:{"symbol-placement":{type:"enum",values:{point:{},line:{},"line-center":{}},default:"point",expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"symbol-spacing":{type:"number",default:250,minimum:1,units:"pixels",requires:[{"symbol-placement":"line"}],expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"symbol-avoid-edges":{type:"boolean",default:!1,expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"symbol-sort-key":{type:"number",expression:{interpolated:!1,parameters:["zoom","feature"]},"property-type":"data-driven"},"symbol-z-order":{type:"enum",values:{auto:{},"viewport-y":{},source:{}},default:"auto",expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"icon-allow-overlap":{type:"boolean",default:!1,requires:["icon-image",{"!":"icon-overlap"}],expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"icon-overlap":{type:"enum",values:{never:{},always:{},cooperative:{}},requires:["icon-image"],expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"icon-ignore-placement":{type:"boolean",default:!1,requires:["icon-image"],expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"icon-optional":{type:"boolean",default:!1,requires:["icon-image","text-field"],expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"icon-rotation-alignment":{type:"enum",values:{map:{},viewport:{},auto:{}},default:"auto",requires:["icon-image"],expression:{interpolated:!1,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:!0,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:!1,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:!0,parameters:["zoom"]},"property-type":"data-constant"},"icon-image":{type:"resolvedImage",tokens:!0,expression:{interpolated:!1,parameters:["zoom","feature"]},"property-type":"data-driven"},"icon-rotate":{type:"number",default:0,period:360,units:"degrees",requires:["icon-image"],expression:{interpolated:!0,parameters:["zoom","feature"]},"property-type":"data-driven"},"icon-padding":{type:"padding",default:[2],units:"pixels",requires:["icon-image"],expression:{interpolated:!0,parameters:["zoom","feature"]},"property-type":"data-driven"},"icon-keep-upright":{type:"boolean",default:!1,requires:["icon-image",{"icon-rotation-alignment":"map"},{"symbol-placement":["line","line-center"]}],expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"icon-offset":{type:"array",value:"number",length:2,default:[0,0],requires:["icon-image"],expression:{interpolated:!0,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:!1,parameters:["zoom","feature"]},"property-type":"data-driven"},"icon-pitch-alignment":{type:"enum",values:{map:{},viewport:{},auto:{}},default:"auto",requires:["icon-image"],expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"text-pitch-alignment":{type:"enum",values:{map:{},viewport:{},auto:{}},default:"auto",requires:["text-field"],expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"text-rotation-alignment":{type:"enum",values:{map:{},viewport:{},"viewport-glyph":{},auto:{}},default:"auto",requires:["text-field"],expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"text-field":{type:"formatted",default:"",tokens:!0,expression:{interpolated:!1,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:!1,parameters:["zoom","feature"]},"property-type":"data-driven"},"text-size":{type:"number",default:16,minimum:0,units:"pixels",requires:["text-field"],expression:{interpolated:!0,parameters:["zoom","feature"]},"property-type":"data-driven"},"text-max-width":{type:"number",default:10,minimum:0,units:"ems",requires:["text-field"],expression:{interpolated:!0,parameters:["zoom","feature"]},"property-type":"data-driven"},"text-line-height":{type:"number",default:1.2,units:"ems",requires:["text-field"],expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"text-letter-spacing":{type:"number",default:0,units:"ems",requires:["text-field"],expression:{interpolated:!0,parameters:["zoom","feature"]},"property-type":"data-driven"},"text-justify":{type:"enum",values:{auto:{},left:{},center:{},right:{}},default:"center",requires:["text-field"],expression:{interpolated:!1,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:!0,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:!1,parameters:["zoom"]},"property-type":"data-constant"},"text-variable-anchor-offset":{type:"variableAnchorOffsetCollection",requires:["text-field",{"symbol-placement":["point"]}],expression:{interpolated:!0,parameters:["zoom","feature"]},"property-type":"data-driven"},"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:!1,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:!0,parameters:["zoom"]},"property-type":"data-constant"},"text-writing-mode":{type:"array",value:"enum",values:{horizontal:{},vertical:{}},requires:["text-field",{"symbol-placement":["point"]}],expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"text-rotate":{type:"number",default:0,period:360,units:"degrees",requires:["text-field"],expression:{interpolated:!0,parameters:["zoom","feature"]},"property-type":"data-driven"},"text-padding":{type:"number",default:2,minimum:0,units:"pixels",requires:["text-field"],expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"text-keep-upright":{type:"boolean",default:!0,requires:["text-field",{"text-rotation-alignment":"map"},{"symbol-placement":["line","line-center"]}],expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"text-transform":{type:"enum",values:{none:{},uppercase:{},lowercase:{}},default:"none",requires:["text-field"],expression:{interpolated:!1,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:!0,parameters:["zoom","feature"]},"property-type":"data-driven"},"text-allow-overlap":{type:"boolean",default:!1,requires:["text-field",{"!":"text-overlap"}],expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"text-overlap":{type:"enum",values:{never:{},always:{},cooperative:{}},requires:["text-field"],expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"text-ignore-placement":{type:"boolean",default:!1,requires:["text-field"],expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"text-optional":{type:"boolean",default:!1,requires:["text-field","icon-image
vendor: 19,782 bytes, line 740
740"],expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},visibility:{type:"enum",values:{visible:{},none:{}},default:"visible",expression:{interpolated:!1,parameters:["global-state"]},"property-type":"data-constant"}},layout_raster:{visibility:{type:"enum",values:{visible:{},none:{}},default:"visible",expression:{interpolated:!1,parameters:["global-state"]},"property-type":"data-constant"}},layout_hillshade:{visibility:{type:"enum",values:{visible:{},none:{}},default:"visible",expression:{interpolated:!1,parameters:["global-state"]},"property-type":"data-constant"}},"layout_color-relief":{visibility:{type:"enum",values:{visible:{},none:{}},default:"visible",expression:{interpolated:!1,parameters:["global-state"]},"property-type":"data-constant"}},filter:{type:"boolean",expression:{interpolated:!1,parameters:["zoom","feature"]},"property-type":"data-driven"},filter_operator:{type:"enum",values:{"==":{},"!=":{},">":{},">=":{},"<":{},"<=":{},in:{},"!in":{},all:{},any:{},none:{},has:{},"!has":{}}},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:!1}},function_stop:{type:"array",minimum:0,maximum:24,value:["number","color"],length:2},expression:{type:"array",value:"expression_name",minimum:1},light:{anchor:{type:"enum",default:"viewport",values:{map:{},viewport:{}},"property-type":"data-constant",transition:!1,expression:{interpolated:!1,parameters:["zoom"]}},position:{type:"array",default:[1.15,210,30],length:3,value:"number","property-type":"data-constant",transition:!0,expression:{interpolated:!0,parameters:["zoom"]}},color:{type:"color","property-type":"data-constant",default:"#ffffff",expression:{interpolated:!0,parameters:["zoom"]},transition:!0},intensity:{type:"number","property-type":"data-constant",default:.5,minimum:0,maximum:1,expression:{interpolated:!0,parameters:["zoom"]},transition:!0}},sky:{"sky-color":{type:"color","property-type":"data-constant",default:"#88C6FC",expression:{interpolated:!0,parameters:["zoom"]},transition:!0},"horizon-color":{type:"color","property-type":"data-constant",default:"#ffffff",expression:{interpolated:!0,parameters:["zoom"]},transition:!0},"fog-color":{type:"color","property-type":"data-constant",default:"#ffffff",expression:{interpolated:!0,parameters:["zoom"]},transition:!0},"fog-ground-blend":{type:"number","property-type":"data-constant",default:.5,minimum:0,maximum:1,expression:{interpolated:!0,parameters:["zoom"]},transition:!0},"horizon-fog-blend":{type:"number","property-type":"data-constant",default:.8,minimum:0,maximum:1,expression:{interpolated:!0,parameters:["zoom"]},transition:!0},"sky-horizon-blend":{type:"number","property-type":"data-constant",default:.8,minimum:0,maximum:1,expression:{interpolated:!0,parameters:["zoom"]},transition:!0},"atmosphere-blend":{type:"number","property-type":"data-constant",default:.8,minimum:0,maximum:1,expression:{interpolated:!0,parameters:["zoom"]},transition:!0}},terrain:{source:{type:"string",required:!0},exaggeration:{type:"number",minimum:0,default:1}},projection:{type:{type:"projectionDefinition",default:"mercator","property-type":"data-constant",transition:!1,expression:{interpolated:!0,parameters:["zoom"]}}},paint:["paint_fill","paint_line","paint_circle","paint_heatmap","paint_fill-extrusion","paint_symbol","paint_raster","paint_hillshade","paint_color-relief","paint_background"],paint_fill:{"fill-antialias":{type:"boolean",default:!0,expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"fill-opacity":{type:"number",default:1,minimum:0,maximum:1,transition:!0,expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"fill-layer-opacity":{type:"number",default:1,minimum:0,maximum:1,transition:!0,expression:{interpolated:!0,parameters:["zoom","global-state"]},"property-type":"data-constant"},"fill-color":{type:"color",default:"#000000",transition:!0,expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"fill-outline-color":{type:"color",transition:!0,requires:[{"!":"fill-pattern"},{"fill-antialias":!0}],expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"fill-translate":{type:"array",value:"number",length:2,default:[0,0],transition:!0,units:"pixels",expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"fill-translate-anchor":{type:"enum",values:{map:{},viewport:{}},default:"map",requires:["fill-translate"],expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"fill-pattern":{type:"resolvedImage",transition:!0,expression:{interpolated:!1,parameters:["zoom","feature"]},"property-type":"cross-faded-data-driven"}},"paint_fill-extrusion":{"fill-extrusion-opacity":{type:"number",default:1,minimum:0,maximum:1,transition:!0,expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"fill-extrusion-color":{type:"color",default:"#000000",transition:!0,requires:[{"!":"fill-extrusion-pattern"}],expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"fill-extrusion-translate":{type:"array",value:"number",length:2,default:[0,0],transition:!0,units:"pixels",expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"fill-extrusion-translate-anchor":{type:"enum",values:{map:{},viewport:{}},default:"map",requires:["fill-extrusion-translate"],expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"fill-extrusion-pattern":{type:"resolvedImage",transition:!0,expression:{interpolated:!1,parameters:["zoom","feature"]},"property-type":"cross-faded-data-driven"},"fill-extrusion-height":{type:"number",default:0,minimum:0,units:"meters",transition:!0,expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"fill-extrusion-base":{type:"number",default:0,minimum:0,units:"meters",transition:!0,requires:["fill-extrusion-height"],expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"fill-extrusion-vertical-gradient":{type:"boolean",default:!0,transition:!1,expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"}},paint_line:{"line-opacity":{type:"number",default:1,minimum:0,maximum:1,transition:!0,expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"line-layer-opacity":{type:"number",default:1,minimum:0,maximum:1,transition:!0,expression:{interpolated:!0,parameters:["zoom","global-state"]},"property-type":"data-constant"},"line-color":{type:"color",default:"#000000",transition:!0,requires:[{"!":"line-pattern"}],expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"line-translate":{type:"array",value:"number",length:2,default:[0,0],transition:!0,units:"pixels",expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"line-translate-anchor":{type:"enum",values:{map:{},viewport:{}},default:"map",requires:["line-translate"],expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"line-width":{type:"number",default:1,minimum:0,transition:!0,units:"pixels",expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"line-gap-width":{type:"number",default:0,minimum:0,transition:!0,units:"pixels",expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"line-offset":{type:"number",default:0,transition:!0,units:"pixels",expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"line-blur":{type:"number",default:0,minimum:0,transition:!0,units:"pixels",expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"line-dasharray":{type:"array",value:"number",minimum:0,transition:!0,units:"line widths",requires:[{"!":"line-pattern"}],expression:{interpolated:!1,parameters:["zoom","feature"]},"property-type":"cross-faded-data-driven"},"line-pattern":{type:"resolvedImage",transition:!0,expression:{interpolated:!1,parameters:["zoom","feature"]},"property-type":"cross-faded-data-driven"},"line-gradient":{type:"color",transition:!1,requires:[{"!":"line-dasharray"},{"!":"line-pattern"},{source:"geojson",has:{lineMetrics:!0}}],expression:{interpolated:!0,parameters:["line-progress"]},"property-type":"color-ramp"}},paint_circle:{"circle-radius":{type:"number",default:5,minimum:0,transition:!0,units:"pixels",expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"circle-color":{type:"color",default:"#000000",transition:!0,expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"circle-blur":{type:"number",default:0,transition:!0,expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"circle-opacity":{type:"number",default:1,minimum:0,maximum:1,transition:!0,expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"circle-translate":{type:"array",value:"number",length:2,default:[0,0],transition:!0,units:"pixels",expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"circle-translate-anchor":{type:"enum",values:{map:{},viewport:{}},default:"map",requires:["circle-translate"],expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"circle-pitch-scale":{type:"enum",values:{map:{},viewport:{}},default:"map",expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"circle-pitch-alignment":{type:"enum",values:{map:{},viewport:{}},default:"viewport",expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"circle-stroke-width":{type:"number",default:0,minimum:0,transition:!0,units:"pixels",expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"circle-stroke-color":{type:"color",default:"#000000",transition:!0,expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"circle-stroke-opacity":{type:"number",default:1,minimum:0,maximum:1,transition:!0,expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"}},paint_heatmap:{"heatmap-radius":{type:"number",default:30,minimum:1,transition:!0,units:"pixels",expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"heatmap-weight":{type:"number",default:1,minimum:0,transition:!1,expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"heatmap-intensity":{type:"number",default:1,minimum:0,transition:!0,expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"heatmap-color":{type:"color",default:["interpolate",["linear"],["heatmap-density"],0,"rgba(0, 0, 255, 0)",.1,"royalblue",.3,"cyan",.5,"lime",.7,"yellow",1,"red"],transition:!1,expression:{interpolated:!0,parameters:["heatmap-density"]},"property-type":"color-ramp"},"heatmap-opacity":{type:"number",default:1,minimum:0,maximum:1,transition:!0,expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"}},paint_symbol:{"icon-opacity":{type:"number",default:1,minimum:0,maximum:1,transition:!0,requires:["icon-image"],expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"icon-color":{type:"color",default:"#000000",transition:!0,requires:["icon-image"],expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"icon-halo-color":{type:"color",default:"rgba(0, 0, 0, 0)",transition:!0,requires:["icon-image"],expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"icon-halo-width":{type:"number",default:0,minimum:0,transition:!0,units:"pixels",requires:["icon-image"],expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"icon-halo-blur":{type:"number",default:0,minimum:0,transition:!0,units:"pixels",requires:["icon-image"],expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"icon-translate":{type:"array",value:"number",length:2,default:[0,0],transition:!0,units:"pixels",requires:["icon-image"],expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"icon-translate-anchor":{type:"enum",values:{map:{},viewport:{}},default:"map",requires:["icon-image","icon-translate"],expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"text-opacity":{type:"number",default:1,minimum:0,maximum:1,transition:!0,requires:["text-field"],expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"text-color":{type:"color",default:"#000000",transition:!0,overridable:!0,requires:["text-field"],expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"text-halo-color":{type:"color",default:"rgba(0, 0, 0, 0)",transition:!0,requires:["text-field"],expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"text-halo-width":{type:"number",default:0,minimum:0,transition:!0,units:"pixels",requires:["text-field"],expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"text-halo-blur":{type:"number",default:0,minimum:0,transition:!0,units:"pixels",requires:["text-field"],expression:{interpolated:!0,parameters:["zoom","feature","feature-state"]},"property-type":"data-driven"},"text-translate":{type:"array",value:"number",length:2,default:[0,0],transition:!0,units:"pixels",requires:["text-field"],expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"text-translate-anchor":{type:"enum",values:{map:{},viewport:{}},default:"map",requires:["text-field","text-translate"],expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"}},paint_raster:{"raster-opacity":{type:"number",default:1,minimum:0,maximum:1,transition:!0,expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"raster-hue-rotate":{type:"number",default:0,period:360,transition:!0,units:"degrees",expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"raster-brightness-min":{type:"number",default:0,minimum:0,maximum:1,transition:!0,expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"raster-brightness-max":{type:"number",default:1,minimum:0,maximum:1,transition:!0,expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"raster-saturation":{type:"number",default:0,minimum:-1,maximum:1,transition:!0,expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"raster-contrast":{type:"number",default:0,minimum:-1,maximum:1,transition:!0,expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},resampling:{type:"enum",values:{linear:{},nearest:{}},default:"linear",expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"raster-resampling":{type:"enum",values:{linear:{},nearest:{}},default:"linear",expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"raster-fade-duration":{type:"number",default:300,minimum:0,transition:!1,units:"milliseconds",expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"}},paint_hillshade:{"hillshade-illumination-direction":{type:"numberArray",default:335,minimum:0,maximum:359,transition:!1,expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"hillshade-illumination-altitude":{type:"numberArray",default:45,minimum:0,maximum:90,transition:!1,expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"hillshade-illumination-anchor":{type:"enum",values:{map:{},viewport:{}},default:"viewport",expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},"hillshade-exaggeration":{type:"number",default:.5,minimum:0,maximum:1,transition:!0,expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"hillshade-shadow-color":{type:"colorArray",default:"#000000",transition:!0,expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"hillshade-highlight-color":{type:"colorArray",default:"#FFFFFF",transition:!0,expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"hillshade-accent-color":{type:"color",default:"#000000",transition:!0,expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"hillshade-method":{type:"enum",values:{standard:{},basic:{},combined:{},igor:{},multidirectional:{}},default:"standard",expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"},resampling:{type:"enum",values:{linear:{},nearest:{}},default:"linear",expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"}},"paint_color-relief":{"color-relief-opacity":{type:"number",default:1,minimum:0,maximum:1,transition:!0,expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"color-relief-color":{type:"color",transition:!1,expression:{interpolated:!0,parameters:["elevation"]},"property-type":"color-ramp"},resampling:{type:"enum",values:{linear:{},nearest:{}},default:"linear",expression:{interpolated:!1,parameters:["zoom"]},"property-type":"data-constant"}},paint_background:{"background-color":{type:"color",default:"#000000",transition:!0,requires:[{"!":"background-pattern"}],expression:{interpolated:!0,parameters:["zoom"]},"property-type":"data-constant"},"background-pattern":{type:"resolvedImage",transition:!0,expression:{interpolated:!1,parameters:["zoom"]},"property-type":"cross-faded"},"background-opacity":{type:"number",default:1,minimum:0,maximum:1,transition:!0,expression:{interpolated:!0,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"},"cross-faded":{type:"property-type"},"cross-faded-data-driven":{type:"property-type"},"color-ramp":{type:"property-type"},"data-constant":{type:"property-type"},constant:{type:"property-type"}},promoteId:{"*":{type:"string"}},interpolation:{type:"array",value:"interpolation_name",minimum:1},interpolation_name:{type:"enum",values:{linear:{syntax:{overloads:[{parameters:[],"output-type":"interpolation"}],parameters:[]}},exponential:{syntax:{overloads:[{parameters:["base"],"output-type":"interpolation"}],parameters:[{name:"base",type:"number literal"}]}},"cubic-bezier":{syntax:{overloads:[{parameters:["x1","y1","x2","y2"],"output-type":"interpolation"}],parameters:[{name:"x1",type:"number literal"},{name:"y1",type:"number literal"},{name:"x2",type:"number literal"},{name:"y2",type:"number literal"}]}}}}}
740,pSe=["type","source","source-layer","minzoom","maxzoom","filter","layout"];function mSe(e,t){let r={};for(let i in e)i!=="ref"&&(r[i]=e[i]);return pSe.forEach(i=>
vendor: 9,473 bytes, line 740
740{i in t&&(r[i]=t[i])}),r}function Ok(e){e=e.slice();let t=Object.create(null);for(let r=0;r<e.length;r++)t[e[r].id]=e[r];for(let r=0;r<e.length;r++)"ref"in e[r]&&(e[r]=mSe(e[r],t[e[r].ref]));return e}function Zt(e,t){if(Array.isArray(e)){if(!Array.isArray(t)||e.length!==t.length)return!1;for(let r=0;r<e.length;r++)if(!Zt(e[r],t[r]))return!1;return!0}if(typeof e=="object"&&e&&t!==null){if(typeof t!="object"||Object.keys(e).length!==Object.keys(t).length)return!1;for(let r in e)if(!Zt(e[r],t[r]))return!1;return!0}return e===t}function Na(e,t){e.push(t)}function IR(e,t,r){Na(r,{command:"addSource",args:[e,t[e]]})}function AR(e,t,r){Na(t,{command:"removeSource",args:[e]}),r[e]=!0}function gSe(e,t,r,i){AR(e,r,i),IR(e,t,r)}function _Se(e,t,r){let i;for(i in e[r])if(Object.prototype.hasOwnProperty.call(e[r],i)&&i!=="data"&&!Zt(e[r][i],t[r][i]))return!1;for(i in t[r])if(Object.prototype.hasOwnProperty.call(t[r],i)&&i!=="data"&&!Zt(e[r][i],t[r][i]))return!1;return!0}function ySe(e,t,r,i){e||(e={}),t||(t={});let n;for(n in e)Object.prototype.hasOwnProperty.call(e,n)&&(Object.prototype.hasOwnProperty.call(t,n)||AR(n,r,i));for(n in t)Object.prototype.hasOwnProperty.call(t,n)&&(Object.prototype.hasOwnProperty.call(e,n)?Zt(e[n],t[n])||(e[n].type==="geojson"&&t[n].type==="geojson"&&_Se(e,t,n)?Na(r,{command:"setGeoJSONSourceData",args:[n,t[n].data]}):gSe(n,t,r,i)):IR(n,t,r))}function m0(e,t,r,i,n,a){e||(e={}),t||(t={});for(let s in e)Object.prototype.hasOwnProperty.call(e,s)&&(Zt(e[s],t[s])||r.push({command:a,args:[i,s,t[s],n]}));for(let s in t)!Object.prototype.hasOwnProperty.call(t,s)||Object.prototype.hasOwnProperty.call(e,s)||Zt(e[s],t[s])||r.push({command:a,args:[i,s,t[s],n]})}function Lk(e){return e.id}function Fk(e,t){return e[t.id]=t,e}function vSe(e,t,r){e||(e=[]),t||(t=[]);let i=e.map(Lk),n=t.map(Lk),a=e.reduce(Fk,{}),s=t.reduce(Fk,{}),o=i.slice(),l=Object.create(null),u,c,d,h,f;for(let p=0,m=0;p<i.length;p++)u=i[p],Object.prototype.hasOwnProperty.call(s,u)?m++:(Na(r,{command:"removeLayer",args:[u]}),o.splice(o.indexOf(u,m),1));for(let p=0,m=0;p<n.length;p++)u=n[n.length-1-p],o[o.length-1-p]!==u&&(Object.prototype.hasOwnProperty.call(a,u)?(Na(r,{command:"removeLayer",args:[u]}),o.splice(o.lastIndexOf(u,o.length-m),1)):m++,h=o[o.length-p],Na(r,{command:"addLayer",args:[s[u],h]}),o.splice(o.length-p,0,u),l[u]=!0);for(let p=0;p<n.length;p++)if(u=n[p],c=a[u],d=s[u],!(l[u]||Zt(c,d))){if(!Zt(c.source,d.source)||!Zt(c["source-layer"],d["source-layer"])||!Zt(c.type,d.type)){Na(r,{command:"removeLayer",args:[u]}),h=o[o.lastIndexOf(u)+1],Na(r,{command:"addLayer",args:[d,h]});continue}for(f in m0(c.layout,d.layout,r,u,null,"setLayoutProperty"),m0(c.paint,d.paint,r,u,null,"setPaintProperty"),Zt(c.filter,d.filter)||Na(r,{command:"setFilter",args:[u,d.filter]}),(!Zt(c.minzoom,d.minzoom)||!Zt(c.maxzoom,d.maxzoom))&&Na(r,{command:"setLayerZoomRange",args:[u,d.minzoom,d.maxzoom]}),c)Object.prototype.hasOwnProperty.call(c,f)&&f!=="layout"&&f!=="paint"&&f!=="filter"&&f!=="metadata"&&f!=="minzoom"&&f!=="maxzoom"&&(f.indexOf("paint.")===0?m0(c[f],d[f],r,u,f.slice(6),"setPaintProperty"):Zt(c[f],d[f])||Na(r,{command:"setLayerProperty",args:[u,f,d[f]]}));for(f in d)!Object.prototype.hasOwnProperty.call(d,f)||Object.prototype.hasOwnProperty.call(c,f)||f!=="layout"&&f!=="paint"&&f!=="filter"&&f!=="metadata"&&f!=="minzoom"&&f!=="maxzoom"&&(f.indexOf("paint.")===0?m0(c[f],d[f],r,u,f.slice(6),"setPaintProperty"):Zt(c[f],d[f])||Na(r,{command:"setLayerProperty",args:[u,f,d[f]]}))}}function bSe(e,t){if(!e)return[{command:"setStyle",args:[t]}];let r=[];try{if(!Zt(e.version,t.version))return[{command:"setStyle",args:[t]}];Zt(e.center,t.center)||r.push({command:"setCenter",args:[t.center]}),Zt(e.state,t.state)||r.push({command:"setGlobalState",args:[t.state]}),Zt(e.centerAltitude,t.centerAltitude)||r.push({command:"setCenterAltitude",args:[t.centerAltitude]}),Zt(e.zoom,t.zoom)||r.push({command:"setZoom",args:[t.zoom]}),Zt(e.bearing,t.bearing)||r.push({command:"setBearing",args:[t.bearing]}),Zt(e.pitch,t.pitch)||r.push({command:"setPitch",args:[t.pitch]}),Zt(e.roll,t.roll)||r.push({command:"setRoll",args:[t.roll]}),Zt(e.sprite,t.sprite)||r.push({command:"setSprite",args:[t.sprite]}),Zt(e.glyphs,t.glyphs)||r.push({command:"setGlyphs",args:[t.glyphs]}),Zt(e.transition,t.transition)||r.push({command:"setTransition",args:[t.transition]}),Zt(e.light,t.light)||r.push({command:"setLight",args:[t.light]}),Zt(e.terrain,t.terrain)||r.push({command:"setTerrain",args:[t.terrain]}),Zt(e.sky,t.sky)||r.push({command:"setSky",args:[t.sky]}),Zt(e.projection,t.projection)||r.push({command:"setProjection",args:[t.projection]});let i={},n=[];ySe(e.sources,t.sources,n,i);let a=[];e.layers&&e.layers.forEach(s=>{"source"in s&&i[s.source]?r.push({command:"removeLayer",args:[s.id]}):a.push(s)}),r=r.concat(n),vSe(a,t.layers,r)}catch(i){console.warn("Unable to compute style diff:",i),r=[{command:"setStyle",args:[t]}]}return r}var Te=class{constructor(t,r,i,n,a="error"){this.message=(t?`${t}: `:"")+i,n&&(this.identifier=n),this.severity=a,r!=null&&r.__line__&&(this.line=r.__line__)}},Ws=class extends Error{constructor(e,t){super(t),this.message=t,this.key=e}},xSe=class DR{constructor(t,r=[]){this.parent=t,this.bindings={};for(let[i,n]of r)this.bindings[i]=n}concat(t){return new DR(this,t)}get(t){if(this.bindings[t])return this.bindings[t];if(this.parent)return this.parent.get(t);throw Error(`${t} not found in scope.`)}has(t){return this.bindings[t]?!0:this.parent?this.parent.has(t):!1}};const cg={kind:"null"},ke={kind:"number"},ct={kind:"string"},yt={kind:"boolean"},Ss={kind:"color"},Y1={kind:"projectionDefinition"},cc={kind:"object"},mt={kind:"value"},wSe={kind:"error"},W1={kind:"collator"},dg={kind:"formatted"},Z1={kind:"padding"},xm={kind:"colorArray"},K1={kind:"numberArray"},hg={kind:"resolvedImage"},X1={kind:"variableAnchorOffsetCollection"};function Sn(e,t){return{kind:"array",itemType:e,N:t}}function Dr(e){if(e.kind==="array"){let t=Dr(e.itemType);return typeof e.N=="number"?`array<${t}, ${e.N}>`:e.itemType.kind==="value"?"array":`array<${t}>`}return e.kind}const $Se=[cg,ke,ct,yt,Ss,Y1,dg,cc,Sn(mt),Z1,K1,xm,hg,X1];function wm(e,t){if(t.kind==="error")return null;if(e.kind==="array"){if(t.kind==="array"&&(t.N===0&&t.itemType.kind==="value"||!wm(e.itemType,t.itemType))&&(typeof e.N!="number"||e.N===t.N))return null}else{if(e.kind===t.kind)return null;if(e.kind==="value"){for(let r of $Se)if(!wm(r,t))return null}}return`Expected ${Dr(e)} but found ${Dr(t)} instead.`}function R$(e,t){return t.some(r=>r.kind===e.kind)}function dc(e,t){return t.some(r=>r==="null"?e===null:r==="array"?Array.isArray(e):r==="object"?e&&!Array.isArray(e)&&typeof e=="object":r===typeof e)}function $l(e,t){return e.kind==="array"&&t.kind==="array"?e.itemType.kind===t.itemType.kind&&typeof e.N=="number":e.kind===t.kind}const RR=.96422,OR=.82521,LR=4/29,Hx=6/29,FR=3*Hx*Hx,SSe=Math.PI/180,TSe=180/Math.PI;function zR(e){return e%=360,e<0&&(e+=360),e}function NR([e,t,r,i]){e=$b(e),t=$b(t),r=$b(r);let n,a,s=Sb((.2225045*e+.7168786*t+.0606169*r)/1);e===t&&t===r?n=a=s:(n=Sb((.4360747*e+.3850649*t+.1430804*r)/RR),a=Sb((.0139322*e+.0971045*t+.7141733*r)/OR));let o=116*s-16;return[o<0?0:o,500*(n-s),200*(s-a),i]}function $b(e){return e<=.04045?e/12.92:((e+.055)/1.055)**2.4}function Sb(e){return e>.008856451679035631?e**(1/3):e/FR+LR}function BR([e,t,r,i]){let n=(e+16)/116,a=isNaN(t)?n:n+t/500,s=isNaN(r)?n:n-r/200;return n=1*Cb(n),a=RR*Cb(a),s=OR*Cb(s),[Tb(3.1338561*a-1.6168667*n-.4906146*s),Tb(-.9787684*a+1.9161415*n+.033454*s),Tb(.0719453*a-.2289914*n+1.4052427*s),i]}function Tb(e){return e=e<=.00304?12.92*e:1.055*e**(1/2.4)-.055,e<0?0:e>1?1:e}function Cb(e){return e>Hx?e*e*e:FR*(e-LR)}function CSe(e){let[t,r,i,n]=NR(e),a=Math.sqrt(r*r+i*i);return[Math.round(a*1e4)?zR(Math.atan2(i,r)*TSe):NaN,a,t,n]}function kSe([e,t,r,i]){return e=isNaN(e)?0:e*SSe,BR([r,Math.cos(e)*t,Math.sin(e)*t,i])}function ESe([e,t,r,i]){e=zR(e),t/=100,r/=100;function n(a){let s=(a+e/30)%12,o=t*Math.min(r,1-r);return r-o*Math.max(-1,Math.min(s-3,9-s,1))}return[n(0),n(8),n(4),i]}const PSe=Object.hasOwn||function(e,t){return Object.prototype.hasOwnProperty.call(e,t)};function Pp(e,t){return PSe(e,t)?e[t]:void 0}function MSe(e){if(e=e.toLowerCase().trim(),e==="transparent")return[0,0,0,0];let t=Pp(ISe,e);if(t){let[i,n,a]=t;return[i/255,n/255,a/255,1]}if(e.startsWith("#")&&/^#(?:[0-9a-f]{3,4}|[0-9a-f]{6}|[0-9a-f]{8})$/.test(e)){let i=e.length<6?1:2,n=1;return[g0(e.slice(n,n+=i)),g0(e.slice(n,n+=i)),g0(e.slice(n,n+=i)),g0(e.slice(n,n+i)||"ff")]}if(e.startsWith("rgb")){let i=e.match(/^rgba?\(\s*([\de.+-]+)(%)?(?:\s+|\s*(,)\s*)([\de.+-]+)(%)?(?:\s+|\s*(,)\s*)([\de.+-]+)(%)?(?:\s*([,\/])\s*([\de.+-]+)(%)?)?\s*\)$/);if(i){let[n,a,s,o,l,u,c,d,h,f,p,m]=i,g=[o||" ",c||" ",f].join("");if(g===" "||g===" /"||g===",,"||g===",,,"){let v=[s,u,h].join(""),x=v==="%%%"?100:v===""?255:0;if(x){let _=[dd(+a/x,0,1),dd(+l/x,0,1),dd(+d/x,0,1),p?zk(+p,m):1];if(Nk(_))return _}}return}}let r=e.match(/^hsla?\(\s*([\de.+-]+)(?:deg)?(?:\s+|\s*(,)\s*)([\de.+-]+)%(?:\s+|\s*(,)\s*)([\de.+-]+)%(?:\s*([,\/])\s*([\de.+-]+)(%)?)?\s*\)$/);if(r){let[i,n,a,s,o,l,u,c,d]=r,h=[a||" ",o||" ",u].join("");if(h===" "||h===" /"||h===",,"||h===",,,"){let f=[+n,dd(+s,0,100),dd(+l,0,100),c?zk(+c,d):1];if(Nk(f))return ESe(f)}}}function g0(e){return parseInt(e.padEnd(2,e),16)/255}function zk(e,t){return dd(t?e/100:e,0,1)}function dd(e,t,r){return Math.min(Math.max(t,e),r)}
vendor: 12,061 bytes, line 740
740function Nk(e){return!e.some(Number.isNaN)}const ISe={aliceblue:[240,248,255],antiquewhite:[250,235,215],aqua:[0,255,255],aquamarine:[127,255,212],azure:[240,255,255],beige:[245,245,220],bisque:[255,228,196],black:[0,0,0],blanchedalmond:[255,235,205],blue:[0,0,255],blueviolet:[138,43,226],brown:[165,42,42],burlywood:[222,184,135],cadetblue:[95,158,160],chartreuse:[127,255,0],chocolate:[210,105,30],coral:[255,127,80],cornflowerblue:[100,149,237],cornsilk:[255,248,220],crimson:[220,20,60],cyan:[0,255,255],darkblue:[0,0,139],darkcyan:[0,139,139],darkgoldenrod:[184,134,11],darkgray:[169,169,169],darkgreen:[0,100,0],darkgrey:[169,169,169],darkkhaki:[189,183,107],darkmagenta:[139,0,139],darkolivegreen:[85,107,47],darkorange:[255,140,0],darkorchid:[153,50,204],darkred:[139,0,0],darksalmon:[233,150,122],darkseagreen:[143,188,143],darkslateblue:[72,61,139],darkslategray:[47,79,79],darkslategrey:[47,79,79],darkturquoise:[0,206,209],darkviolet:[148,0,211],deeppink:[255,20,147],deepskyblue:[0,191,255],dimgray:[105,105,105],dimgrey:[105,105,105],dodgerblue:[30,144,255],firebrick:[178,34,34],floralwhite:[255,250,240],forestgreen:[34,139,34],fuchsia:[255,0,255],gainsboro:[220,220,220],ghostwhite:[248,248,255],gold:[255,215,0],goldenrod:[218,165,32],gray:[128,128,128],green:[0,128,0],greenyellow:[173,255,47],grey:[128,128,128],honeydew:[240,255,240],hotpink:[255,105,180],indianred:[205,92,92],indigo:[75,0,130],ivory:[255,255,240],khaki:[240,230,140],lavender:[230,230,250],lavenderblush:[255,240,245],lawngreen:[124,252,0],lemonchiffon:[255,250,205],lightblue:[173,216,230],lightcoral:[240,128,128],lightcyan:[224,255,255],lightgoldenrodyellow:[250,250,210],lightgray:[211,211,211],lightgreen:[144,238,144],lightgrey:[211,211,211],lightpink:[255,182,193],lightsalmon:[255,160,122],lightseagreen:[32,178,170],lightskyblue:[135,206,250],lightslategray:[119,136,153],lightslategrey:[119,136,153],lightsteelblue:[176,196,222],lightyellow:[255,255,224],lime:[0,255,0],limegreen:[50,205,50],linen:[250,240,230],magenta:[255,0,255],maroon:[128,0,0],mediumaquamarine:[102,205,170],mediumblue:[0,0,205],mediumorchid:[186,85,211],mediumpurple:[147,112,219],mediumseagreen:[60,179,113],mediumslateblue:[123,104,238],mediumspringgreen:[0,250,154],mediumturquoise:[72,209,204],mediumvioletred:[199,21,133],midnightblue:[25,25,112],mintcream:[245,255,250],mistyrose:[255,228,225],moccasin:[255,228,181],navajowhite:[255,222,173],navy:[0,0,128],oldlace:[253,245,230],olive:[128,128,0],olivedrab:[107,142,35],orange:[255,165,0],orangered:[255,69,0],orchid:[218,112,214],palegoldenrod:[238,232,170],palegreen:[152,251,152],paleturquoise:[175,238,238],palevioletred:[219,112,147],papayawhip:[255,239,213],peachpuff:[255,218,185],peru:[205,133,63],pink:[255,192,203],plum:[221,160,221],powderblue:[176,224,230],purple:[128,0,128],rebeccapurple:[102,51,153],red:[255,0,0],rosybrown:[188,143,143],royalblue:[65,105,225],saddlebrown:[139,69,19],salmon:[250,128,114],sandybrown:[244,164,96],seagreen:[46,139,87],seashell:[255,245,238],sienna:[160,82,45],silver:[192,192,192],skyblue:[135,206,235],slateblue:[106,90,205],slategray:[112,128,144],slategrey:[112,128,144],snow:[255,250,250],springgreen:[0,255,127],steelblue:[70,130,180],tan:[210,180,140],teal:[0,128,128],thistle:[216,191,216],tomato:[255,99,71],turquoise:[64,224,208],violet:[238,130,238],wheat:[245,222,179],white:[255,255,255],whitesmoke:[245,245,245],yellow:[255,255,0],yellowgreen:[154,205,50]};function Jl(e,t,r){return e+r*(t-e)}function Ih(e,t,r){return e.map((i,n)=>Jl(i,t[n],r))}function ASe(e){return e==="rgb"||e==="hcl"||e==="lab"}var Ti,at=(Ti=class{constructor(t,r,i,n=1,a=!0){this.r=t,this.g=r,this.b=i,this.a=n,a||(this.r*=n,this.g*=n,this.b*=n,n||this.overwriteGetter("rgb",[t,r,i,n]))}static parse(t){if(t instanceof Ti)return t;if(typeof t!="string")return;let r=MSe(t);if(r)return new Ti(...r,!1)}get rgb(){let{r:t,g:r,b:i,a:n}=this,a=n||1/0;return this.overwriteGetter("rgb",[t/a,r/a,i/a,n])}get hcl(){return this.overwriteGetter("hcl",CSe(this.rgb))}get lab(){return this.overwriteGetter("lab",NR(this.rgb))}overwriteGetter(t,r){return Object.defineProperty(this,t,{value:r}),r}toString(){let[t,r,i,n]=this.rgb;return`rgba(${[t,r,i].map(a=>Math.round(a*255)).join(",")},${n})`}static interpolate(t,r,i,n="rgb"){switch(n){case"rgb":{let[a,s,o,l]=Ih(t.rgb,r.rgb,i);return new Ti(a,s,o,l,!1)}case"hcl":{let[a,s,o,l]=t.hcl,[u,c,d,h]=r.hcl,f,p;if(!isNaN(a)&&!isNaN(u)){let _=u-a;u>a&&_>180?_-=360:u<a&&a-u>180&&(_+=360),f=a+i*_}else isNaN(a)?isNaN(u)?f=NaN:(f=u,(o===1||o===0)&&(p=c)):(f=a,(d===1||d===0)&&(p=s));let[m,g,v,x]=kSe([f,p??Jl(s,c,i),Jl(o,d,i),Jl(l,h,i)]);return new Ti(m,g,v,x,!1)}case"lab":{let[a,s,o,l]=BR(Ih(t.lab,r.lab,i));return new Ti(a,s,o,l,!1)}}}},Ti.black=new Ti(0,0,0,1),Ti.white=new Ti(1,1,1,1),Ti.transparent=new Ti(0,0,0,0),Ti.red=new Ti(1,0,0,1),Ti),O$=class{constructor(t,r,i){this.sensitivity=t?r?"variant":"case":r?"accent":"base",this.locale=i,this.collator=new Intl.Collator(this.locale?this.locale:[],{sensitivity:this.sensitivity,usage:"search"})}compare(t,r){return this.collator.compare(t,r)}resolvedLocale(){return new Intl.Collator(this.locale?this.locale:[]).resolvedOptions().locale}};const DSe=["bottom","center","top"];var Yx=class{constructor(t,r,i,n,a,s){this.text=t,this.image=r,this.scale=i,this.fontStack=n,this.textColor=a,this.verticalAlign=s}},dl=class h_{constructor(t){this.sections=t}static fromString(t){return new h_([new Yx(t,null,null,null,null,null)])}isEmpty(){return this.sections.length===0||!this.sections.some(t=>t.text.length!==0||t.image&&t.image.name.length!==0)}static factory(t){return t instanceof h_?t:h_.fromString(t)}toString(){return this.sections.length===0?"":this.sections.map(t=>t.text).join("")}},po=class Kf{constructor(t){this.values=t.slice()}static parse(t){if(t instanceof Kf)return t;if(typeof t=="number")return new Kf([t,t,t,t]);if(Array.isArray(t)&&!(t.length<1||t.length>4)){for(let r of t)if(typeof r!="number")return;switch(t.length){case 1:t=[t[0],t[0],t[0],t[0]];break;case 2:t=[t[0],t[1],t[0],t[1]];break;case 3:t=[t[0],t[1],t[2],t[1]]}return new Kf(t)}}toString(){return JSON.stringify(this.values)}static interpolate(t,r,i){return new Kf(Ih(t.values,r.values,i))}},mo=class Xf{constructor(t){this.values=t.slice()}static parse(t){if(t instanceof Xf)return t;if(typeof t=="number")return new Xf([t]);if(Array.isArray(t)){for(let r of t)if(typeof r!="number")return;return new Xf(t)}}toString(){return JSON.stringify(this.values)}static interpolate(t,r,i){return new Xf(Ih(t.values,r.values,i))}},rs=class Jf{constructor(t){this.values=t.slice()}static parse(t){if(t instanceof Jf)return t;if(typeof t=="string"){let i=at.parse(t);return i?new Jf([i]):void 0}if(!Array.isArray(t))return;let r=[];for(let i of t){if(typeof i!="string")return;let n=at.parse(i);if(!n)return;r.push(n)}return new Jf(r)}toString(){return JSON.stringify(this.values)}static interpolate(t,r,i,n="rgb"){let a=[];if(t.values.length!=r.values.length)throw Error(`colorArray: Arrays have mismatched length (${t.values.length} vs. ${r.values.length}), cannot interpolate.`);for(let s=0;s<t.values.length;s++)a.push(at.interpolate(t.values[s],r.values[s],i,n));return new Jf(a)}},xr=class extends Error{constructor(t,r){super(t),this.name="RuntimeError",this.path=r}toJSON(){return this.message}};const RSe=new Set(["center","left","right","top","bottom","top-left","top-right","bottom-left","bottom-right"]);var yu=class f_{constructor(t){this.values=t.slice()}static parse(t){if(t instanceof f_)return t;if(!(!Array.isArray(t)||t.length<1||t.length%2!=0)){for(let r=0;r<t.length;r+=2){let i=t[r],n=t[r+1];if(typeof i!="string"||!RSe.has(i)||!Array.isArray(n)||n.length!==2||typeof n[0]!="number"||typeof n[1]!="number")return}return new f_(t)}}toString(){return JSON.stringify(this.values)}static interpolate(t,r,i,n){let a=t.values,s=r.values;if(a.length!==s.length)throw new xr(`Cannot interpolate values of different length. from: ${t.toString()}, to: ${r.toString()}`,n);let o=[];for(let l=0;l<a.length;l+=2){if(a[l]!==s[l])throw new xr(`Cannot interpolate values containing mismatched anchors. from[${l}]: ${a[l]}, to[${l}]: ${s[l]}`,n);o.push(a[l]);let[u,c]=a[l+1],[d,h]=s[l+1];o.push([Jl(u,d,i),Jl(c,h,i)])}return new f_(o)}},uo=class jR{constructor(t){this.name=t.name,this.available=t.available}toString(){return this.name}static fromString(t){return t?new jR({name:t,available:!1}):null}},vu=class hd{constructor(t,r,i){this.from=t,this.to=r,this.transition=i}toString(){return this.from===this.to&&this.transition===1?this.from:JSON.stringify([this.from,this.to,this.transition])}static interpolate(t,r,i){return new hd(t,r,i)}static parse(t){if(t instanceof hd)return t;if(Array.isArray(t)&&t.length===3&&typeof t[0]=="string"&&typeof t[1]=="string"&&typeof t[2]=="number")return new hd(t[0],t[1],t[2]);if(typeof t=="object"&&typeof t.from=="string"&&typeof t.to=="string"&&typeof t.transition=="number")return new hd(t.from,t.to,t.transition);if(typeof t=="string")return new hd(t,t,1)}};function UR(e,t,r,i){return typeof e=="number"&&e>=0&&e<=255&&typeof t=="number"&&t>=0&&t<=255&&typeof r=="number"&&r>=0&&r<=255?i===void 0||typeof i=="number"&&i>=0&&i<=1?null:`Invalid rgba value [${[e,t,r,i].join(", ")}]: 'a' must be between 0 and 1.`:`Invalid rgba value [${(typeof i=="number"?[e,t,r,i]:[e,t,r]).join(", ")}]: 'r', 'g', and 'b' must be between 0 and 255.`}function $m(e){if(e===null||typeof e=="string"||typeof e=="boolean"||typeof e=="number"||e instanceof vu||e instanceof at||e instanceof O$||e instanceof dl||e instanceof po||e instanceof mo||e instanceof rs||e instanceof yu||e instanceof uo)return!0;if(Array.isArray(e)){for(let t of e)if(!$m(t))return!1;return!0}if(typeof e=="object"){for(let t in e)if(!$m(e[t]))return!1;return!0}return!1}function ni(e){if(e===null)return cg;if(typeof e=="string")return ct;if(typeof e=="boolean")return yt;if(typeof e=="number")return ke;if(e instanceof at)return Ss;if(e instanceof vu)return Y1;if(e instanceof O$)return W1;if(e instanceof dl)return dg;if(e instanceof po)return Z1;if(e instanceof mo)return K1;if(e instanceof rs)return xm;if(e instanceof yu)return X1;if(e instanceof uo)return hg;if(Array.isArray(e)){let t=e.length,r;for(let i of e){let n=ni(i);if(!r)r=n;else{if(r===n)continue;r=mt;break}}return Sn(r||mt,t)}return cc}function Mp(e){let t=typeof e;return e===null?"":t==="string"||t==="number"||t==="boolean"?String(e):e instanceof at||e instanceof vu||e instanceof dl||e instanceof po||e instanceof mo||e instanceof rs||e instanceof yu||e instanceof uo?e.toString():JSON.stringify(e)}var Sm=class VR{constructor(t,r){this.type=t,this.value=r}static parse(t,r){if(t.length!==2)return r.error(`'literal' expression requires exactly one argument, but found ${t.length-1} instead.`);if(!$m(t[1]))return r.error("invalid value");let i=t[1],n=ni(i),a=r.expectedType;return n.kind==="array"&&n.N===0&&a&&a.kind==="array"&&(typeof a.N!="number"||a.N===0)&&(n=a),new VR(n,i)}evaluate(){return this.value}eachChild(){}outputDefined(){return!0}};const _0={string:ct,number:ke,boolean:yt,object:cc};var Ro=class qR{constructor(t,r,i){this.type=t,this.args=r,this.key=i}static parse(t,r){if(t.length<2)return r.error("Expected at least one argument.");let i=1,n,a=t[0];if(a==="array"){let o;if(t.length>2){let u=t[1];if(typeof u!="string"||!(u in _0)||u==="object")return r.error('The item type argument of "array" must be one of string, number, boolean',1);o=_0[u],i++}else o=mt;let l;if(t.length>3){if(t[2]!==null&&(typeof t[2]!="number"||t[2]<0||t[2]!==Math.floor(t[2])))return r.error('The length argument to "array" must be a positive integer literal',2);l=t[2],i++}n=Sn(o,l)}else{if(!_0[a])throw Error(`Types doesn't contain name = ${a}`);n=_0[a]}let s=[];for(;i<t.length;i++){let o=r.parse(t[i],i,mt);if(!o)return null;s.push(o)}return new qR(n,s,r.key)}evaluate(t){for(let r=0;r<this.args.length;r++){let i=this.args[r].evaluate(t);if(!wm(this.type,ni(i)))return i;if(r===this.args.length-1)throw new xr(`Expected value to be of type ${Dr(this.t
740ype)}, but found ${Dr(ni(i))} instead.`,this.key)}throw Error()}eachChild(t){this.args.forEach(t)}outputDefined(){return this.args.every(t=>t.outputDefined())}};const Bk={"to-boolean":yt,"to-color":Ss,"to-number":ke,"to-string":ct};var Td=class GR{constructor(t,r,i){this.type=t,this.args=r,this.key=i}static parse(t,r){if(t.length<2)return r.error("Expected at least one argument.");let i=t[0];if(!Bk[i])throw Error(`Can't parse ${i} as it is not part of the known types`);if((i==="to-boolean"||i==="to-string")&&t.length!==2)return r.error("Expected one argument.");let n=Bk[i],a=[];for(let s=1;s<t.length;s++){let o=r.parse(t[s],s,mt);if(!o)return null;a.push(o)}return new GR(n,a,r.key)}evaluate(t){switch(this.type.kind){case"boolean":return!!this.args[0].evaluate(t);case"color":{let r,i;for(let n of this.args){if(r=n.evaluate(t),i=null,r instanceof at)return r;if(typeof r=="string"){let a=t.parseColor(r);if(a)return a}else if(Array.isArray(r)&&(i=r.length<3||r.length>4?`Invalid rgba value ${JSON.stringify(r)}: expected an array containing either three or four numeric values.`:UR(r[0],r[1],r[2],r[3]),!i))return new at(r[0]/255,r[1]/255,r[2]/255,r[3])}throw new xr(i||`Could not parse color from value '${typeof r=="string"?r:JSON.stringify(r)}'`,this.key)}case"padding":{let r;for(let i of this.args){r=i.evaluate(t);let n=po.parse(r);if(n)return n}throw new xr(`Could not parse padding from value '${typeof r=="string"?r:JSON.stringify(r)}'`,this.key)}case"numberArray":{let r;for(let i of this.args){r=i.evaluate(t);let n=mo.parse(r);if(n)return n}throw new xr(`Could not parse numberArray from value '${typeof r=="string"?r:JSON.stringify(r)}'`,this.key)}case"colorArray":{let r;for(let i of this.args){r=i.evaluate(t);let n=rs.parse(r);if(n)return n}throw new xr(`Could not parse colorArray from value '${typeof r=="string"?r:JSON.stringify(r)}'`,this.key)}case"variableAnchorOffsetCollection":{let r;for(let i of this.args){r=i.evaluate(t);let n=yu.parse(r);if(n)return n}throw new xr(`Could not parse variableAnchorOffsetCollection from value '${typeof r=="string"?r:JSON.stringify(r)}'`,this.key)}case"number":{let r=null;for(let i of this.args){if(r=i.evaluate(t),r===null)return 0;let n=Number(r);if(!isNaN(n))return n}throw new xr(`Could not convert ${JSON.stringify(r)} to number.`,this.key)}case"formatted":return dl.fromString(Mp(this.args[0].evaluate(t)));case"resolvedImage":return uo.fromString(Mp(this.args[0].evaluate(t)));case"projectionDefinition":{let r=this.args[0].evaluate(t);if(vu.parse(r))return r;throw new xr(`Could not parse projectionDefinition from value '${typeof r=="string"?r:JSON.stringify(r)}'`,this.key)}default:return Mp(this.args[0].evaluate(t))}}eachChild(t){this.args.forEach(t)}outputDefined(){return this.args.every(t=>t.outputDefined())}};const OSe=["Unknown","Point","LineString","Polygon"];var HR=class{constructor(){this.globals=null,this.feature=null,this.featureState=null,this.formattedSection=null,this._parseColorCache=new Map,this.availableImages=null,this.canonical=null}id(){return this.feature&&"id"in this.feature?this.feature.id:null}geometryType(){return this.feature?typeof this.feature.type=="number"?OSe[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||{}}parseColor(t){let r=this._parseColorCache.get(t);return r||(r=at.parse(t),this._parseColorCache.set(t,r)),r}},YR=class WR{constructor(t,r,i=[],n,a=new xSe,s=[]){this.registry=t,this.path=i,this.key=i.map(o=>`[${o}]`).join(""),this.scope=a,this.errors=s,this.expectedType=n,this._isConstant=r}parse(t,r,i,n,a={}){return r?this.concat(r,i,n)._parse(t,a):this._parse(t,a)}_parse(t,r){(t===null||typeof t=="string"||typeof t=="boolean"||typeof t=="number")&&(t=["literal",t]);let i=this.key;function n(a,s,o){return o==="assert"?new Ro(s,[a],i):o==="coerce"?new Td(s,[a],i):a}if(Array.isArray(t)){if(t.length===0)return this.error('Expected an array with at least one element. If you wanted a literal array, use ["literal", []].');let a=t[0];if(typeof a!="string")return this.error(`Expression name must be a string, but found ${typeof a} instead. If you wanted a literal array, use ["literal", [...]].`,0),null;let s=this.registry[a];if(s){let o=s.parse(t,this);if(!o)return null;if(this.expectedType){let l=this.expectedType,u=o.type;
vendor: 4,671 bytes, line 740
740if((l.kind==="string"||l.kind==="number"||l.kind==="boolean"||l.kind==="object"||l.kind==="array")&&u.kind==="value")o=n(o,l,r.typeAnnotation||"assert");else if(l.kind==="projectionDefinition"&&["string","array","value"].includes(u.kind)||["color","formatted","resolvedImage"].includes(l.kind)&&["value","string"].includes(u.kind)||["padding","numberArray"].includes(l.kind)&&["value","number","array"].includes(u.kind)||l.kind==="colorArray"&&["value","string","array"].includes(u.kind)||l.kind==="variableAnchorOffsetCollection"&&["value","array"].includes(u.kind))o=n(o,l,r.typeAnnotation||"coerce");else if(this.checkSubtype(l,u))return null}if(!(o instanceof Sm)&&o.type.kind!=="resolvedImage"&&this._isConstant(o)){let l=new HR;try{o=new Sm(o.type,o.evaluate(l))}catch(u){return this.error(u.message),null}}return o}return this.error(`Unknown expression "${a}". If you wanted a literal array, use ["literal", [...]].`,0)}return t===void 0?this.error("'undefined' value invalid. Use null instead."):typeof t=="object"?this.error('Bare objects invalid. Use ["literal", {...}] instead.'):this.error(`Expected an array, but found ${typeof t} instead.`)}concat(t,r,i){let n=typeof t=="number"?this.path.concat(t):this.path,a=i?this.scope.concat(i):this.scope;return new WR(this.registry,this._isConstant,n,r||null,a,this.errors)}error(t,...r){let i=`${this.key}${r.map(n=>`[${n}]`).join("")}`;this.errors.push(new Ws(i,t))}checkSubtype(t,r){let i=wm(t,r);return i&&this.error(i),i}},ZR=class KR{constructor(t,r){this.type=r.type,this.bindings=[].concat(t),this.result=r}evaluate(t){return this.result.evaluate(t)}eachChild(t){for(let r of this.bindings)t(r[1]);t(this.result)}static parse(t,r){if(t.length<4)return r.error(`Expected at least 3 arguments, but found ${t.length-1} instead.`);let i=[];for(let a=1;a<t.length-1;a+=2){let s=t[a];if(typeof s!="string")return r.error(`Expected string, but found ${typeof s} instead.`,a);if(/[^a-zA-Z0-9_]/.test(s))return r.error("Variable names must contain only alphanumeric characters or '_'.",a);let o=r.parse(t[a+1],a+1);if(!o)return null;i.push([s,o])}let n=r.parse(t[t.length-1],t.length-1,r.expectedType,i);return n?new KR(i,n):null}outputDefined(){return this.result.outputDefined()}},XR=class JR{constructor(t,r){this.type=r.type,this.name=t,this.boundExpression=r}static parse(t,r){if(t.length!==2||typeof t[1]!="string")return r.error("'var' expression requires exactly one string literal argument.");let i=t[1];return r.scope.has(i)?new JR(i,r.scope.get(i)):r.error(`Unknown variable "${i}". Make sure "${i}" has been bound in an enclosing "let" expression before using it.`,1)}evaluate(t){return this.boundExpression.evaluate(t)}eachChild(){}outputDefined(){return!1}},LSe=class QR{constructor(t,r,i,n){this.type=t,this.index=r,this.input=i,this.key=n}static parse(t,r){if(t.length!==3)return r.error(`Expected 2 arguments, but found ${t.length-1} instead.`);let i=r.parse(t[1],1,ke),n=r.parse(t[2],2,Sn(r.expectedType||mt));if(!i||!n)return null;let a=n.type;return new QR(a.itemType,i,n,r.key)}evaluate(t){let r=this.index.evaluate(t),i=this.input.evaluate(t);if(r<0)throw new xr(`Array index out of bounds: ${r} < 0.`,this.key);if(r>=i.length)throw new xr(`Array index out of bounds: ${r} > ${i.length-1}.`,this.key);if(r!==Math.floor(r))throw new xr(`Array index must be an integer, but found ${r} instead.`,this.key);return i[r]}eachChild(t){t(this.index),t(this.input)}outputDefined(){return!1}},FSe=class eO{constructor(t,r,i){this.needle=t,this.haystack=r,this.key=i,this.type=yt}static parse(t,r){if(t.length!==3)return r.error(`Expected 2 arguments, but found ${t.length-1} instead.`);let i=r.parse(t[1],1,mt),n=r.parse(t[2],2,mt);return!i||!n?null:R$(i.type,[yt,ct,ke,cg,mt])?new eO(i,n,r.key):r.error(`Expected first argument to be of type boolean, string, number or null, but found ${Dr(i.type)} instead`)}evaluate(t){let r=this.needle.evaluate(t),i=this.haystack.evaluate(t);if(!i)return!1;if(!dc(r,["boolean","string","number","null"]))throw new xr(`Expected first argument to be of type boolean, string, number or null, but found ${Dr(ni(r))} instead.`,this.key);if(!dc(i,["string","array"]))throw new xr(`Expected second argument to be of type array or string, but found ${Dr(ni(i))} instead.`,this.key);return i.indexOf(r)>=0}eachChild(t){t(this.needle),t(this.haystack)}outputDefined(){return!0}},zSe=class Wx{constructor(t,r,i,n){this.needle=t,this.haystack=r,this.key=i,this.fromIndex=n,this.type=ke}static parse(t,r){if(t.length<=2||t.length>=5)return r.error(`Expected 2 or 3 arguments, but found ${t.length-1} instead.`);let i=r.parse(t[1],1,mt),n=r.parse(t[2],2,mt);if(!i||!n)return null;
vendor: 4,957 bytes, line 740
740if(!R$(i.type,[yt,ct,ke,cg,mt]))return r.error(`Expected first argument to be of type boolean, string, number or null, but found ${Dr(i.type)} instead`);if(t.length===4){let a=r.parse(t[3],3,ke);return a?new Wx(i,n,r.key,a):null}return new Wx(i,n,r.key)}evaluate(t){let r=this.needle.evaluate(t),i=this.haystack.evaluate(t);if(!dc(r,["boolean","string","number","null"]))throw new xr(`Expected first argument to be of type boolean, string, number or null, but found ${Dr(ni(r))} instead.`,this.key);let n;if(this.fromIndex&&(n=this.fromIndex.evaluate(t)),dc(i,["string"])){let a=i.indexOf(r,n);return a===-1?-1:[...i.slice(0,a)].length}if(dc(i,["array"]))return i.indexOf(r,n);throw new xr(`Expected second argument to be of type array or string, but found ${Dr(ni(i))} instead.`,this.key)}eachChild(t){t(this.needle),t(this.haystack),this.fromIndex&&t(this.fromIndex)}outputDefined(){return!1}},NSe=class tO{constructor(t,r,i,n,a,s){this.inputType=t,this.type=r,this.input=i,this.cases=n,this.outputs=a,this.otherwise=s}static parse(t,r){if(t.length<5)return r.error(`Expected at least 4 arguments, but found only ${t.length-1}.`);if(t.length%2!=1)return r.error("Expected an even number of arguments.");let i,n;r.expectedType&&r.expectedType.kind!=="value"&&(n=r.expectedType);let a={},s=[];for(let u=2;u<t.length-1;u+=2){let c=t[u],d=t[u+1];Array.isArray(c)||(c=[c]);let h=r.concat(u);if(c.length===0)return h.error("Expected at least one branch label.");for(let p of c){if(typeof p!="number"&&typeof p!="string")return h.error("Branch labels must be numbers or strings.");if(typeof p=="number"&&Math.abs(p)>2**53-1)return h.error(`Branch labels must be integers no larger than ${2**53-1}.`);if(typeof p=="number"&&Math.floor(p)!==p)return h.error("Numeric branch labels must be integer values.");if(!i)i=ni(p);else if(h.checkSubtype(i,ni(p)))return null;if(a[String(p)]!==void 0)return h.error("Branch labels must be unique.");a[String(p)]=s.length}let f=r.parse(d,u,n);if(!f)return null;n||(n=f.type),s.push(f)}let o=r.parse(t[1],1,mt);if(!o)return null;let l=r.parse(t[t.length-1],t.length-1,n);return!l||o.type.kind!=="value"&&r.concat(1).checkSubtype(i,o.type)?null:new tO(i,n,o,a,s,l)}evaluate(t){let r=this.input.evaluate(t);return(ni(r)===this.inputType&&this.outputs[this.cases[r]]||this.otherwise).evaluate(t)}eachChild(t){t(this.input),this.outputs.forEach(t),t(this.otherwise)}outputDefined(){return this.outputs.every(t=>t.outputDefined())&&this.otherwise.outputDefined()}},BSe=class rO{constructor(t,r,i){this.type=t,this.branches=r,this.otherwise=i}static parse(t,r){if(t.length<4)return r.error(`Expected at least 3 arguments, but found only ${t.length-1}.`);if(t.length%2!=0)return r.error("Expected an odd number of arguments.");let i;r.expectedType&&r.expectedType.kind!=="value"&&(i=r.expectedType);let n=[];for(let s=1;s<t.length-1;s+=2){let o=r.parse(t[s],s,yt);if(!o)return null;let l=r.parse(t[s+1],s+1,i);if(!l)return null;n.push([o,l]),i||(i=l.type)}let a=r.parse(t[t.length-1],t.length-1,i);if(!a)return null;if(!i)throw Error("Can't infer output type");return new rO(i,n,a)}evaluate(t){for(let[r,i]of this.branches)if(r.evaluate(t))return i.evaluate(t);return this.otherwise.evaluate(t)}eachChild(t){for(let[r,i]of this.branches)t(r),t(i);t(this.otherwise)}outputDefined(){return this.branches.every(([t,r])=>r.outputDefined())&&this.otherwise.outputDefined()}},jSe=class Zx{constructor(t,r,i,n,a){this.type=t,this.input=r,this.beginIndex=i,this.key=n,this.endIndex=a}static parse(t,r){if(t.length<=2||t.length>=5)return r.error(`Expected 2 or 3 arguments, but found ${t.length-1} instead.`);let i=r.parse(t[1],1,mt),n=r.parse(t[2],2,ke);if(!i||!n)return null;if(!R$(i.type,[Sn(mt),ct,mt]))return r.error(`Expected first argument to be of type array or string, but found ${Dr(i.type)} instead`);if(t.length===4){let a=r.parse(t[3],3,ke);return a?new Zx(i.type,i,n,r.key,a):null}return new Zx(i.type,i,n,r.key)}evaluate(t){let r=this.input.evaluate(t),i=this.beginIndex.evaluate(t),n;if(this.endIndex&&(n=this.endIndex.evaluate(t)),dc(r,["string"]))return[...r].slice(i,n).join("");if(dc(r,["array"]))return r.slice(i,n);throw new xr(`Expected first argument to be of type array or string, but found ${Dr(ni(r))} instead.`,this.key)}eachChild(t){t(this.input),t(this.beginIndex),this.endIndex&&t(this.endIndex)}outputDefined(){return!1}};function J1(e,t,r){let i=e.length-1,n=0,a=i,s=0,o,l;for(;n<=a;)if(s=Math.floor((n+a)/2),o=e[s],l=e[s+1],o<=t){if(s===i||t<l)return s;n=s+1}else if(o>t)a=s-1;else throw new xr("Input is not a number.",r);return 0}var L$=class iO{constructor(t,r,i,n){this.type=t,this.input=r,this.key=n,this.labels=[],this.outputs=[];for(let[a,s]of i)this.labels.push(a),this.outputs.push(s)}static parse(t,r){if(t.length-1<4)return r.error(`Expected at least 4 arguments, but found only ${t.length-1}.`);if((t.length-1)%2!=0)return r.error("Expected an even number of arguments.");let i=r.parse(t[1],1,ke);
vendor: 47,479 bytes, line 740
740if(!i)return null;let n=[],a=null;r.expectedType&&r.expectedType.kind!=="value"&&(a=r.expectedType);for(let s=1;s<t.length;s+=2){let o=s===1?-1/0:t[s],l=t[s+1],u=s,c=s+1;if(typeof o!="number")return r.error('Input/output pairs for "step" expressions must be defined using literal numeric values (not computed expressions) for the input values.',u);if(n.length&&n[n.length-1][0]>=o)return r.error('Input/output pairs for "step" expressions must be arranged with input values in strictly ascending order.',u);let d=r.parse(l,c,a);if(!d)return null;a||(a=d.type),n.push([o,d])}return new iO(a,i,n,r.key)}evaluate(t){let r=this.labels,i=this.outputs;if(r.length===1)return i[0].evaluate(t);let n=this.input.evaluate(t);if(n<=r[0])return i[0].evaluate(t);let a=r.length;return n>=r[a-1]?i[a-1].evaluate(t):i[J1(r,n,this.key)].evaluate(t)}eachChild(t){t(this.input);for(let r of this.outputs)t(r)}outputDefined(){return this.outputs.every(t=>t.outputDefined())}};function USe(e,t,r,i){let n=3*e,a=3*(r-e)-n,s=1-n-a,o=3*t,l=3*(i-t)-o,u=1-o-l;return function(c,d=1e-6){if(c<=0)return 0;if(c>=1)return 1;let h=c;for(let m=0;m<8;m++){let g=((s*h+a)*h+n)*h-c;if(Math.abs(g)<d)return((u*h+l)*h+o)*h;let v=(3*s*h+2*a)*h+n;if(Math.abs(v)<1e-6)break;h-=g/v}let f=0,p=1;h=c;for(let m=0;m<20;m++){let g=((s*h+a)*h+n)*h;if(Math.abs(g-c)<d)break;c>g?f=h:p=h,h=(f+p)*.5}return((u*h+l)*h+o)*h}}var Ts=class Kx{constructor(t,r,i,n,a,s){this.type=t,this.operator=r,this.interpolation=i,this.input=n,this.key=s,this.labels=[],this.outputs=[];for(let[o,l]of a)this.labels.push(o),this.outputs.push(l)}static interpolationFactor(t,r,i,n){let a=0;if(t.name==="exponential")a=kb(r,t.base,i,n);else if(t.name==="linear")a=kb(r,1,i,n);else if(t.name==="cubic-bezier"){let s=t.controlPoints;a=USe(s[0],s[1],s[2],s[3])(kb(r,1,i,n))}return a}static parse(t,r){let[i,n,a,...s]=t;if(!Array.isArray(n)||n.length===0)return r.error("Expected an interpolation type expression.",1);if(n[0]==="linear")n={name:"linear"};else if(n[0]==="exponential"){let u=n[1];if(typeof u!="number")return r.error("Exponential interpolation requires a numeric base.",1,1);n={name:"exponential",base:u}}else if(n[0]==="cubic-bezier"){let u=n.slice(1);if(u.length!==4||u.some(c=>typeof c!="number"||c<0||c>1))return r.error("Cubic bezier interpolation requires four numeric arguments with values between 0 and 1.",1);n={name:"cubic-bezier",controlPoints:u}}else return r.error(`Unknown interpolation type ${String(n[0])}`,1,0);if(t.length-1<4)return r.error(`Expected at least 4 arguments, but found only ${t.length-1}.`);if((t.length-1)%2!=0)return r.error("Expected an even number of arguments.");if(a=r.parse(a,2,ke),!a)return null;let o=[],l=null;(i==="interpolate-hcl"||i==="interpolate-lab")&&r.expectedType!=xm?l=Ss:r.expectedType&&r.expectedType.kind!=="value"&&(l=r.expectedType);for(let u=0;u<s.length;u+=2){let c=s[u],d=s[u+1],h=u+3,f=u+4;if(typeof c!="number")return r.error('Input/output pairs for "interpolate" expressions must be defined using literal numeric values (not computed expressions) for the input values.',h);if(o.length&&o[o.length-1][0]>=c)return r.error('Input/output pairs for "interpolate" expressions must be arranged with input values in strictly ascending order.',h);let p=r.parse(d,f,l);if(!p)return null;l||(l=p.type),o.push([c,p])}return!$l(l,ke)&&!$l(l,Y1)&&!$l(l,Ss)&&!$l(l,Z1)&&!$l(l,K1)&&!$l(l,xm)&&!$l(l,X1)&&!$l(l,Sn(ke))?r.error(`Type ${Dr(l)} is not interpolatable.`):new Kx(l,i,n,a,o,r.key)}evaluate(t){let r=this.labels,i=this.outputs;if(r.length===1)return i[0].evaluate(t);let n=this.input.evaluate(t);if(n<=r[0])return i[0].evaluate(t);let a=r.length;if(n>=r[a-1])return i[a-1].evaluate(t);let s=J1(r,n,this.key),o=r[s],l=r[s+1],u=Kx.interpolationFactor(this.interpolation,n,o,l),c=i[s].evaluate(t),d=i[s+1].evaluate(t);switch(this.operator){case"interpolate":switch(this.type.kind){case"number":return Jl(c,d,u);case"color":return at.interpolate(c,d,u);case"padding":return po.interpolate(c,d,u);case"colorArray":return rs.interpolate(c,d,u);case"numberArray":return mo.interpolate(c,d,u);case"variableAnchorOffsetCollection":return yu.interpolate(c,d,u,this.key);case"array":return Ih(c,d,u);case"projectionDefinition":return vu.interpolate(c,d,u)}case"interpolate-hcl":switch(this.type.kind){case"color":return at.interpolate(c,d,u,"hcl");case"colorArray":return rs.interpolate(c,d,u,"hcl")}case"interpolate-lab":switch(this.type.kind){case"color":return at.interpolate(c,d,u,"lab");case"colorArray":return rs.interpolate(c,d,u,"lab")}}}eachChild(t){t(this.input);for(let r of this.outputs)t(r)}outputDefined(){return this.outputs.every(t=>t.outputDefined())}};function kb(e,t,r,i){let n=i-r,a=e-r;return n===0?0:t===1?a/n:(t**+a-1)/(t**+n-1)}const ai={color:at.interpolate,number:Jl,padding:po.interpolate,numberArray:mo.interpolate,colorArray:rs.interpolate,variableAnchorOffsetCollection:yu.interpolate,array:Ih};var nO=class Xx{constructor(t,r){this.type=t,this.args=r}static parse(t,r){if(t.length<2)return r.error("Expected at least one argument.");let i=null,n=r.expectedType;n&&n.kind!=="value"&&(i=n);let a=[];for(let s of t.slice(1)){let o=r.parse(s,1+a.length,i,void 0,{typeAnnotation:"omit"});if(!o)return null;i||(i=o.type),a.push(o)}if(!i)throw Error("No output type");return n&&a.some(s=>wm(n,s.type))?new Xx(mt,a):new Xx(i,a)}evaluate(t){let r=null,i=0,n;for(let a of this.args)if(i++,r=a.evaluate(t),r&&r instanceof uo&&!r.available&&(n||(n=r.name),r=null,i===this.args.length&&(r=n)),r!==null)break;return r}eachChild(t){this.args.forEach(t)}outputDefined(){return this.args.every(t=>t.outputDefined())}};function jk(e,t){return e==="=="||e==="!="?t.kind==="boolean"||t.kind==="string"||t.kind==="number"||t.kind==="null"||t.kind==="value":t.kind==="string"||t.kind==="number"||t.kind==="value"}function VSe(e,t,r){return t===r}function qSe(e,t,r){return t!==r}function GSe(e,t,r){return t<r}function HSe(e,t,r){return t>r}function YSe(e,t,r){return t<=r}function WSe(e,t,r){return t>=r}function aO(e,t,r,i){return i.compare(t,r)===0}function ZSe(e,t,r,i){return!aO(e,t,r,i)}function KSe(e,t,r,i){return i.compare(t,r)<0}function XSe(e,t,r,i){return i.compare(t,r)>0}function JSe(e,t,r,i){return i.compare(t,r)<=0}function QSe(e,t,r,i){return i.compare(t,r)>=0}function Jh(e,t,r){let i=e!=="=="&&e!=="!=";return class sO{constructor(a,s,o,l){this.lhs=a,this.rhs=s,this.key=o,this.collator=l,this.type=yt,this.hasUntypedArgument=a.type.kind==="value"||s.type.kind==="value"}static parse(a,s){if(a.length!==3&&a.length!==4)return s.error("Expected two or three arguments.");let o=a[0],l=s.parse(a[1],1,mt);if(!l)return null;if(!jk(o,l.type))return s.concat(1).error(`"${o}" comparisons are not supported for type '${Dr(l.type)}'.`);let u=s.parse(a[2],2,mt);if(!u)return null;if(!jk(o,u.type))return s.concat(2).error(`"${o}" comparisons are not supported for type '${Dr(u.type)}'.`);if(l.type.kind!==u.type.kind&&l.type.kind!=="value"&&u.type.kind!=="value")return s.error(`Cannot compare types '${Dr(l.type)}' and '${Dr(u.type)}'.`);i&&(l.type.kind==="value"&&u.type.kind!=="value"?l=new Ro(u.type,[l],s.key):l.type.kind!=="value"&&u.type.kind==="value"&&(u=new Ro(l.type,[u],s.key)));let c=null;if(a.length===4){if(l.type.kind!=="string"&&u.type.kind!=="string"&&l.type.kind!=="value"&&u.type.kind!=="value")return s.error("Cannot use collator to compare non-string types.");if(c=s.parse(a[3],3,W1),!c)return null}return new sO(l,u,s.key,c)}evaluate(a){let s=this.lhs.evaluate(a),o=this.rhs.evaluate(a);if(i&&this.hasUntypedArgument){let l=ni(s),u=ni(o);if(l.kind!==u.kind||l.kind!=="string"&&l.kind!=="number")throw new xr(`Expected arguments for "${e}" to be (string, string) or (number, number), but found (${l.kind}, ${u.kind}) instead.`,this.key)}if(this.collator&&!i&&this.hasUntypedArgument){let l=ni(s),u=ni(o);if(l.kind!=="string"||u.kind!=="string")return t(a,s,o)}return this.collator?r(a,s,o,this.collator.evaluate(a)):t(a,s,o)}eachChild(a){a(this.lhs),a(this.rhs),this.collator&&a(this.collator)}outputDefined(){return!0}}}const e5e=Jh("==",VSe,aO),t5e=Jh("!=",qSe,ZSe),r5e=Jh("<",GSe,KSe),i5e=Jh(">",HSe,XSe),n5e=Jh("<=",YSe,JSe),a5e=Jh(">=",WSe,QSe);var oO=class lO{constructor(t,r,i){this.type=W1,this.locale=i,this.caseSensitive=t,this.diacriticSensitive=r}static parse(t,r){if(t.length!==2)return r.error("Expected one argument.");let i=t[1];if(typeof i!="object"||Array.isArray(i))return r.error("Collator options argument must be an object.");let n=r.parse(i["case-sensitive"]!==void 0&&i["case-sensitive"],1,yt);if(!n)return null;let a=r.parse(i["diacritic-sensitive"]!==void 0&&i["diacritic-sensitive"],1,yt);if(!a)return null;let s=null;return i.locale&&(s=r.parse(i.locale,1,ct),!s)?null:new lO(n,a,s)}evaluate(t){return new O$(this.caseSensitive.evaluate(t),this.diacriticSensitive.evaluate(t),this.locale?this.locale.evaluate(t):null)}eachChild(t){t(this.caseSensitive),t(this.diacriticSensitive),this.locale&&t(this.locale)}outputDefined(){return!1}},s5e=class uO{constructor(t,r,i,n,a,s){this.type=ct,this.number=t,this.locale=r,this.currency=i,this.unit=n,this.minFractionDigits=a,this.maxFractionDigits=s}static parse(t,r){if(t.length!==3)return r.error("Expected two arguments.");let i=r.parse(t[1],1,ke);if(!i)return null;let n=t[2];if(typeof n!="object"||Array.isArray(n))return r.error("NumberFormat options argument must be an object.");let a=null;if(n.locale&&(a=r.parse(n.locale,1,ct),!a))return null;let s=null;if(n.currency&&(s=r.parse(n.currency,1,ct),!s))return null;let o=null;if(n.unit&&(o=r.parse(n.unit,1,ct),!o))return null;if(s&&o)return r.error("NumberFormat options `currency` and `unit` are mutually exclusive");let l=null;if(n["min-fraction-digits"]&&(l=r.parse(n["min-fraction-digits"],1,ke),!l))return null;let u=null;return n["max-fraction-digits"]&&(u=r.parse(n["max-fraction-digits"],1,ke),!u)?null:new uO(i,a,s,o,l,u)}evaluate(t){return new Intl.NumberFormat(this.locale?this.locale.evaluate(t):[],{style:this.currency?"currency":this.unit?"unit":"decimal",currency:this.currency?this.currency.evaluate(t):void 0,unit:this.unit?this.unit.evaluate(t):void 0,minimumFractionDigits:this.minFractionDigits?this.minFractionDigits.evaluate(t):void 0,maximumFractionDigits:this.maxFractionDigits?this.maxFractionDigits.evaluate(t):void 0}).format(this.number.evaluate(t))}eachChild(t){t(this.number),this.locale&&t(this.locale),this.currency&&t(this.currency),this.unit&&t(this.unit),this.minFractionDigits&&t(this.minFractionDigits),this.maxFractionDigits&&t(this.maxFractionDigits)}outputDefined(){return!1}},cO=class dO{constructor(t){this.type=dg,this.sections=t}static parse(t,r){if(t.length<2)return r.error("Expected at least one argument.");let i=t[1];if(!Array.isArray(i)&&typeof i=="object")return r.error("First argument must be an image or text section.");let n=[],a=!1;for(let s=1;s<=t.length-1;++s){let o=t[s];if(a&&typeof o=="object"&&!Array.isArray(o)){a=!1;let l=null;if(o["font-scale"]&&(l=r.parse(o["font-scale"],1,ke),!l))return null;let u=null;if(o["text-font"]&&(u=r.parse(o["text-font"],1,Sn(ct)),!u))return null;let c=null;if(o["text-color"]&&(c=r.parse(o["text-color"],1,Ss),!c))return null;let d=null;if(o["vertical-align"]){if(typeof o["vertical-align"]=="string"&&!DSe.includes(o["vertical-align"]))return r.error(`'vertical-align' must be one of: 'bottom', 'center', 'top' but found '${o["vertical-align"]}' instead.`);if(d=r.parse(o["vertical-align"],1,ct),!d)return null}let h=n[n.length-1];h.scale=l,h.font=u,h.textColor=c,h.verticalAlign=d}else{let l=r.parse(t[s],1,mt);if(!l)return null;let u=l.type.kind;if(u!=="string"&&u!=="value"&&u!=="null"&&u!=="resolvedImage")return r.error("Formatted text type must be 'string', 'value', 'image' or 'null'.");a=!0,n.push({content:l,scale:null,font:null,textColor:null,verticalAlign:null})}}return new dO(n)}evaluate(t){return new dl(this.sections.map(r=>{let i=r.content.evaluate(t);return ni(i)===hg?new Yx("",i,null,null,null,r.verticalAlign?r.verticalAlign.evaluate(t):null):new Yx(Mp(i),null,r.scale?r.scale.evaluate(t):null,r.font?r.font.evaluate(t).join(","):null,r.textColor?r.textColor.evaluate(t):null,r.verticalAlign?r.verticalAlign.evaluate(t):null)}))}eachChild(t){for(let r of this.sections)t(r.content),r.scale&&t(r.scale),r.font&&t(r.font),r.textColor&&t(r.textColor),r.verticalAlign&&t(r.verticalAlign)}outputDefined(){return!1}},o5e=class hO{constructor(t){this.type=hg,this.input=t}static parse(t,r){if(t.length!==2)return r.error("Expected two arguments.");let i=r.parse(t[1],1,ct);return i?new hO(i):r.error("No image name provided.")}evaluate(t){let r=this.input.evaluate(t),i=uo.fromString(r);return i&&t.availableImages&&(i.available=t.availableImages.indexOf(r)>-1),i}eachChild(t){t(this.input)}outputDefined(){return!1}},l5e=class fO{constructor(t,r){this.input=t,this.key=r,this.type=ke}static parse(t,r){if(t.length!==2)return r.error(`Expected 1 argument, but found ${t.length-1} instead.`);let i=r.parse(t[1],1);return i?i.type.kind!=="array"&&i.type.kind!=="string"&&i.type.kind!=="value"?r.error(`Expected argument of type string or array, but found ${Dr(i.type)} instead.`):new fO(i,r.key):null}evaluate(t){let r=this.input.evaluate(t);if(typeof r=="string")return[...r].length;if(Array.isArray(r))return r.length;throw new xr(`Expected value to be of type string or array, but found ${Dr(ni(r))} instead.`,this.key)}eachChild(t){t(this.input)}outputDefined(){return!1}};const io=8192;function u5e(e,t){let r=c5e(e[0]),i=h5e(e[1]),n=2**t.z;return[Math.round(r*n*io),Math.round(i*n*io)]}function F$(e,t){let r=2**t.z,i=(e[0]/io+t.x)/r,n=(e[1]/io+t.y)/r;return[d5e(i),f5e(n)]}function c5e(e){return(180+e)/360}function d5e(e){return e*360-180}function h5e(e){return(180-180/Math.PI*Math.log(Math.tan(Math.PI/4+e*Math.PI/360)))/360}function f5e(e){return 360/Math.PI*Math.atan(Math.exp((180-e*360)*Math.PI/180))-90}function fg(e,t){e[0]=Math.min(e[0],t[0]),e[1]=Math.min(e[1],t[1]),e[2]=Math.max(e[2],t[0]),e[3]=Math.max(e[3],t[1])}function Tm(e,t){return!(e[0]<=t[0]||e[2]>=t[2]||e[1]<=t[1]||e[3]>=t[3])}function p5e(e,t,r){return t[1]>e[1]!=r[1]>e[1]&&e[0]<(r[0]-t[0])*(e[1]-t[1])/(r[1]-t[1])+t[0]}function m5e(e,t,r){let i=e[0]-t[0],n=e[1]-t[1],a=e[0]-r[0],s=e[1]-r[1];return i*s-a*n===0&&i*a<=0&&n*s<=0}function Q1(e,t,r,i){let n=[t[0]-e[0],t[1]-e[1]];return v5e([i[0]-r[0],i[1]-r[1]],n)!==0&&!!(Uk(e,t,r,i)&&Uk(r,i,e,t))}function g5e(e,t,r){for(let i of r)for(let n=0;n<i.length-1;++n)if(Q1(e,t,i[n],i[n+1]))return!0;return!1}function Qh(e,t,r=!1){let i=!1;for(let n of t)for(let a=0;a<n.length-1;a++){if(m5e(e,n[a],n[a+1]))return r;p5e(e,n[a],n[a+1])&&(i=!i)}return i}function _5e(e,t){for(let r of t)if(Qh(e,r))return!0;return!1}function pO(e,t){for(let r of e)if(!Qh(r,t))return!1;for(let r=0;r<e.length-1;++r)if(g5e(e[r],e[r+1],t))return!1;return!0}function y5e(e,t){for(let r of t)if(pO(e,r))return!0;return!1}function v5e(e,t){return e[0]*t[1]-e[1]*t[0]}function Uk(e,t,r,i){let n=e[0]-r[0],a=e[1]-r[1],s=t[0]-r[0],o=t[1]-r[1],l=i[0]-r[0],u=i[1]-r[1],c=n*u-l*a,d=s*u-l*o;return c>0&&d<0||c<0&&d>0}function z$(e,t,r){let i=[];for(let n=0;n<e.length;n++){let a=[];for(let s=0;s<e[n].length;s++){let o=u5e(e[n][s],r);fg(t,o),a.push(o)}i.push(a)}return i}function mO(e,t,r){let i=[];for(let n=0;n<e.length;n++){let a=z$(e[n],t,r);i.push(a)}return i}function gO(e,t,r,i){if(e[0]<r[0]||e[0]>r[2]){let n=i*.5,a=e[0]-r[0]>n?-i:r[0]-e[0]>n?i:0;a===0&&(a=e[0]-r[2]>n?-i:r[2]-e[0]>n?i:0),e[0]+=a}fg(t,e)}function b5e(e){e[0]=e[1]=1/0,e[2]=e[3]=-1/0}function Vk(e,t,r,i){let n=2**i.z*io,a=[i.x*io,i.y*io],s=[];for(let o of e)for(let l of o){let u=[l.x+a[0],l.y+a[1]];gO(u,t,r,n),s.push(u)}return s}function qk(e,t,r,i){let n=2**i.z*io,a=[i.x*io,i.y*io],s=[];for(let o of e){let l=[];for(let u of o){let c=[u.x+a[0],u.y+a[1]];fg(t,c),l.push(c)}s.push(l)}if(t[2]-t[0]<=n/2){b5e(t);for(let o of s)for(let l of o)gO(l,t,r,n)}return s}function x5e(e,t){let r=[1/0,1/0,-1/0,-1/0],i=[1/0,1/0,-1/0,-1/0],n=e.canonicalID();if(t.type==="Polygon"){let a=z$(t.coordinates,i,n),s=Vk(e.geometry(),r,i,n);if(!Tm(r,i))return!1;for(let o of s)if(!Qh(o,a))return!1}if(t.type==="MultiPolygon"){let a=mO(t.coordinates,i,n),s=Vk(e.geometry(),r,i,n);if(!Tm(r,i))return!1;for(let o of s)if(!_5e(o,a))return!1}return!0}function w5e(e,t){let r=[1/0,1/0,-1/0,-1/0],i=[1/0,1/0,-1/0,-1/0],n=e.canonicalID();if(t.type==="Polygon"){let a=z$(t.coordinates,i,n),s=qk(e.geometry(),r,i,n);if(!Tm(r,i))return!1;for(let o of s)if(!pO(o,a))return!1}if(t.type==="MultiPolygon"){let a=mO(t.coordinates,i,n),s=qk(e.geometry(),r,i,n);if(!Tm(r,i))return!1;for(let o of s)if(!y5e(o,a))return!1}return!0}var N$=class p_{constructor(t,r){this.type=yt,this.geojson=t,this.geometries=r}static parse(t,r){if(t.length!==2)return r.error(`'within' expression requires exactly one argument, but found ${t.length-1} instead.`);if($m(t[1])){let i=t[1];if(i.type==="FeatureCollection"){let n=[];for(let a of i.features){let{type:s,coordinates:o}=a.geometry;s==="Polygon"&&n.push(o),s==="MultiPolygon"&&n.push(...o)}if(n.length)return new p_(i,{type:"MultiPolygon",coordinates:n})}else if(i.type==="Feature"){let n=i.geometry.type;if(n==="Polygon"||n==="MultiPolygon")return new p_(i,i.geometry)}else if(i.type==="Polygon"||i.type==="MultiPolygon")return new p_(i,i)}return r.error("'within' expression requires valid geojson object that contains polygon geometry type.")}evaluate(t){if(t.geometry()!=null&&t.canonicalID()!=null){if(t.geometryType()==="Point")return x5e(t,this.geometries);if(t.geometryType()==="LineString")return w5e(t,this.geometries)}return!1}eachChild(){}outputDefined(){return!0}},_O=class{constructor(t=[],r=(i,n)=>i<n?-1:+(i>n)){if(this.data=t,this.length=this.data.length,this.compare=r,this.length>0)for(let i=(this.length>>1)-1;i>=0;i--)this._down(i)}push(t){this.data.push(t),this._up(this.length++)}pop(){if(this.length===0)return;let t=this.data[0],r=this.data.pop();return--this.length>0&&(this.data[0]=r,this._down(0)),t}peek(){return this.data[0]}_up(t){let{data:r,compare:i}=this,n=r[t];for(;t>0;){let a=t-1>>1,s=r[a];if(i(n,s)>=0)break;r[t]=s,t=a}r[t]=n}_down(t){let{data:r,compare:i}=this,n=this.length>>1,a=r[t];for(;t<n;){let s=(t<<1)+1,o=s+1;if(o<this.length&&i(r[o],r[s])<0&&(s=o),i(r[s],a)>=0)break;r[t]=r[s],t=s}r[t]=a}};function yO(e,t,r=0,i=e.length-1,n=$5e){for(;i>r;){if(i-r>600){let l=i-r+1,u=t-r+1,c=Math.log(l),d=.5*Math.exp(2*c/3),h=.5*Math.sqrt(c*d*(l-d)/l)*(u-l/2<0?-1:1);yO(e,t,Math.max(r,Math.floor(t-u*d/l+h)),Math.min(i,Math.floor(t+(l-u)*d/l+h)),n)}let a=e[t],s=r,o=i;for(Cf(e,r,t),n(e[i],a)>0&&Cf(e,r,i);s<o;){for(Cf(e,s,o),s++,o--;n(e[s],a)<0;)s++;for(;n(e[o],a)>0;)o--}n(e[r],a)===0?Cf(e,r,o):(o++,Cf(e,o,i)),o<=t&&(r=o+1),t<=o&&(i=o-1)}}function Cf(e,t,r){let i=e[t];e[t]=e[r],e[r]=i}function $5e(e,t){return e<t?-1:+(e>t)}function B$(e,t){if(e.length<=1)return[e];let r=[],i,n;for(let a of e){let s=T5e(a);s!==0&&(a.area=Math.abs(s),n===void 0&&(n=s<0),n===s<0?(i&&r.push(i),i=[a]):i.push(a))}if(i&&r.push(i),t>1)for(let a=0;a<r.length;a++)r[a].length<=t||(yO(r[a],t,1,r[a].length-1,S5e),r[a]=r[a].slice(0,t));return r}function S5e(e,t){return t.area-e.area}function T5e(e){let t=0;for(let r=0,i=e.length,n=i-1,a,s;r<i;n=r++)a=e[r],s=e[n],t+=(s.x-a.x)*(a.y+s.y);return t}const Gk=Math.PI/180;var j$=class{constructor(t){let r=Gk*6378.137*1e3,i=Math.cos(t*Gk),n=1/(1-.0066943799901413165*(1-i*i)),a=Math.sqrt(n);this.kx=r*a*i,this.ky=r*a*n*.9933056200098587}distance(t,r){let i=this.wrap(t[0]-r[0])*this.kx,n=(t[1]-r[1])*this.ky;return Math.sqrt(i*i+n*n)}pointOnLine(t,r){let i=1/0,n,a,s,o;for(let l=0;l<t.length-1;l++){let u=t[l][0],c=t[l][1],d=this.wrap(t[l+1][0]-u)*this.kx,h=(t[l+1][1]-c)*this.ky,f=0;(d!==0||h!==0)&&(f=(this.wrap(r[0]-u)*this.kx*d+(r[1]-c)*this.ky*h)/(d*d+h*h),f>1?(u=t[l+1][0],c=t[l+1][1]):f>0&&(u+=d/this.kx*f,c+=h/this.ky*f)),d=this.wrap(r[0]-u)*this.kx,h=(r[1]-c)*this.ky;let p=d*d+h*h;p<i&&(i=p,n=u,a=c,s=l,o=f)}return{point:[n,a],index:s,t:Math.max(0,Math.min(1,o))}}wrap(t){for(;t<-180;)t+=360;for(;t>180;)t-=360;return t}};function vO(e,t){return t[0]-e[0]}function Cy(e){return e[1]-e[0]+1}function hl(e,t){return e[1]>=e[0]&&e[1]<t}function Jx(e,t){if(e[0]>e[1])return[null,null];let r=Cy(e);if(t){if(r===2)return[e,null];let n=Math.floor(r/2);return[[e[0],e[0]+n],[e[0]+n,e[1]]]}if(r===1)return[e,null];let i=Math.floor(r/2)-1;return[[e[0],e[0]+i],[e[0]+i+1,e[1]]]}function Qx(e,t){if(!hl(t,e.length))return[1/0,1/0,-1/0,-1/0];let r=[1/0,1/0,-1/0,-1/0];for(let i=t[0];i<=t[1];++i)fg(r,e[i]);return r}function ew(e){let t=[1/0,1/0,-1/0,-1/0];for(let r of e)for(let i of r)fg(t,i);return t}function Hk(e){return e[0]!==-1/0&&e[1]!==-1/0&&e[2]!==1/0&&e[3]!==1/0}function U$(e,t,r){if(!Hk(e)||!Hk(t))return NaN;let i=0,n=0;return e[2]<t[0]&&(i=t[0]-e[2]),e[0]>t[2]&&(i=e[0]-t[2]),e[1]>t[3]&&(n=e[1]-t[3]),e[3]<t[1]&&(n=t[1]-e[3]),r.distance([0,0],[i,n])}function Vu(e,t,r){let i=r.pointOnLine(t,e);return r.distance(e,i.point)}function V$(e,t,r,i,n){let a=Math.min(Vu(e,[r,i],n),Vu(t,[r,i],n)),s=Math.min(Vu(r,[e,t],n),Vu(i,[e,t],n));return Math.min(a,s)}function C5e(e,t,r,i,n){if(!(hl(t,e.length)&&hl(i,r.length)))return 1/0;let a=1/0;for(let s=t[0];s<t[1];++s){let o=e[s],l=e[s+1];for(let u=i[0];u<i[1];++u){let c=r[u],d=r[u+1];if(Q1(o,l,c,d))return 0;a=Math.min(a,V$(o,l,c,d,n))}}return a}function k5e(e,t,r,i,n){if(!(hl(t,e.length)&&hl(i,r.length)))return NaN;let a=1/0;for(let s=t[0];s<=t[1];++s)for(let o=i[0];o<=i[1];++o)if(a=Math.min(a,n.distance(e[s],r[o])),a===0)return a;return a}function E5e(e,t,r){if(Qh(e,t,!0))return 0;let i=1/0;for(let n of t){let a=n[0],s=n[n.length-1];if(a!==s&&(i=Math.min(i,Vu(e,[s,a],r)),i===0))return i;let o=r.pointOnLine(n,e);if(i=Math.min(i,r.distance(e,o.point)),i===0)return i}return i}function P5e(e,t,r,i){if(!hl(t,e.length))return NaN;for(let a=t[0];a<=t[1];++a)if(Qh(e[a],r,!0))return 0;let n=1/0;for(let a=t[0];a<t[1];++a){let s=e[a],o=e[a+1];for(let l of r)for(let u=0,c=l.length,d=c-1;u<c;d=u++){let h=l[d],f=l[u];if(Q1(s,o,h,f))return 0;n=Math.min(n,V$(s,o,h,f,i))}}return n}function Yk(e,t){for(let r of e)for(let i of r)if(Qh(i,t,!0))return!0;return!1}function M5e(e,t,r,i=1/0){let n=ew(e),a=ew(t);if(i!==1/0&&U$(n,a,r)>=i)return i;if(Tm(n,a)){if(Yk(e,t))return 0}else if(Yk(t,e))return 0;let s=1/0;for(let o of e)for(let l=0,u=o.length,c=u-1;l<u;c=l++){let d=o[c],h=o[l];for(let f of t)for(let p=0,m=f.length,g=m-1;p<m;g=p++){let v=f[g],x=f[p];if(Q1(d,h,v,x))return 0;s=Math.min(s,V$(d,h,v,x,r))}}return s}function Wk(e,t,r,i,n,a){if(!a)return;let s=U$(Qx(i,a),n,r);s<t&&e.push([s,a,[0,0]])}function y0(e,t,r,i,n,a,s){if(!a||!s)return;let o=U$(Qx(i,a),Qx(n,s),r);o<t&&e.push([o,a,s])}function ky(e,t,r,i,n=1/0){let a=Math.min(i.distance(e[0],r[0][0]),n);if(a===0)return a;let s=new _O([[0,[0,e.length-1],[0,0]]],vO),o=ew(r);for(;s.length>0;){let l=s.pop();if(l[0]>=a)continue;let u=l[1],c=t?50:100;if(Cy(u)<=c){if(!hl(u,e.length))return NaN;if(t){let d=P5e(e,u,r,i);if(isNaN(d)||d===0)return d;a=Math.min(a,d)}else for(let d=u[0];d<=u[1];++d){let h=E5e(e[d],r,i);if(a=Math.min(a,h),a===0)return 0}}else{let d=Jx(u,t);Wk(s,a,i,e,o,d[0]),Wk(s,a,i,e,o,d[1])}}return a}function Ey(e,t,r,i,n,a=1/0){let s=Math.min(a,n.distance(e[0],r[0]));if(s===0)return s;let o=new _O([[0,[0,e.length-1],[0,r.length-1]]],vO);for(;o.length>0;){let l=o.pop();if(l[0]>=s)continue;let u=l[1],c=l[2],d=t?50:100,h=i?50:100;if(Cy(u)<=d&&Cy(c)<=h){if(!hl(u,e.length)&&hl(c,r.length))return NaN;let f;if(t&&i)f=C5e(e,u,r,c,n),s=Math.min(s,f);else if(t&&!i){let p=e.slice(u[0],u[1]+1);for(let m=c[0];m<=c[1];++m)if(f=Vu(r[m],p,n),s=Math.min(s,f),s===0)return s}else if(!t&&i){let p=r.slice(c[0],c[1]+1);for(let m=u[0];m<=u[1];++m)if(f=Vu(e[m],p,n),s=Math.min(s,f),s===0)return s}else f=k5e(e,u,r,c,n),s=Math.min(s,f)}else{let f=Jx(u,t),p=Jx(c,i);y0(o,s,n,e,r,f[0],p[0]),y0(o,s,n,e,r,f[0],p[1]),y0(o,s,n,e,r,f[1],p[0]),y0(o,s,n,e,r,f[1],p[1])}}return s}function I5e(e,t){let r=e.geometry(),i=r.flat().map(s=>F$([s.x,s.y],e.canonical));if(r.length===0)return NaN;let n=new j$(i[0][1]),a=1/0;for(let s of t){switch(s.type){case"Point":a=Math.min(a,Ey(i,!1,[s.coordinates],!1,n,a));break;case"LineString":a=Math.min(a,Ey(i,!1,s.coordinates,!0,n,a));break;case"Polygon":a=Math.min(a,ky(i,!1,s.coordinates,n,a))}if(a===0)return a}return a}function A5e(e,t){let r=e.geometry(),i=r.flat().map(s=>F$([s.x,s.y],e.canonical));if(r.length===0)return NaN;let n=new j$(i[0][1]),a=1/0;for(let s of t){switch(s.type){case"Point":a=Math.min(a,Ey(i,!0,[s.coordinates],!1,n,a));break;case"LineString":a=Math.min(a,Ey(i,!0,s.coordinates,!0,n,a));break;case"Polygon":a=Math.min(a,ky(i,!0,s.coordinates,n,a))}if(a===0)return a}return a}function D5e(e,t){let r=e.geometry();if(r.length===0||r[0].length===0)return NaN;let i=B$(r,0).map(s=>s.map(o=>o.map(l=>F$([l.x,l.y],e.canonical)))),n=new j$(i[0][0][0][1]),a=1/0;for(let s of t)for(let o of i){switch(s.type){case"Point":a=Math.min(a,ky([s.coordinates],!1,o,n,a));break;case"LineString":a=Math.min(a,ky(s.coordinates,!0,o,n,a));break;case"Polygon":a=Math.min(a,M5e(o,s.coordinates,n,a))}if(a===0)return a}return a}function Eb(e){return e.type==="MultiPolygon"?e.coordinates.map(t=>({type:"Polygon",coordinates:t})):e.type==="MultiLineString"?e.coordinates.map(t=>({type:"LineString",coordinates:t})):e.type==="MultiPoint"?e.coordinates.map(t=>({type:"Point",coordinates:t})):[e]}var q$=class m_{constructor(t,r){this.type=ke,this.geojson=t,this.geometries=r}static parse(t,r){if(t.length!==2)return r.error(`'distance' expression requires exactly one argument, but found ${t.length-1} instead.`);if($m(t[1])){let i=t[1];if(i.type==="FeatureCollection")return new m_(i,i.features.map(n=>Eb(n.geometry)).flat());if(i.type==="Feature")return new m_(i,Eb(i.geometry));if("type"in i&&"coordinates"in i)return new m_(i,Eb(i))}return r.error("'distance' expression requires valid geojson object that contains polygon geometry type.")}evaluate(t){if(t.geometry()!=null&&t.canonicalID()!=null){if(t.geometryType()==="Point")return I5e(t,this.geometries);if(t.geometryType()==="LineString")return A5e(t,this.geometries);if(t.geometryType()==="Polygon")return D5e(t,this.geometries)}return NaN}eachChild(){}outputDefined(){return!0}},G$=class bO{constructor(t){this.key=t,this.type=mt}static parse(t,r){if(t.length!==2)return r.error(`Expected 1 argument, but found ${t.length-1} instead.`);let i=t[1];return i==null?r.error("Global state property must be defined."):typeof i=="string"?new bO(i):r.error(`Global state property must be string, but found ${typeof t[1]} instead.`)}evaluate(t){var i;let r=(i=t.globals)==null?void 0:i.globalState;return!r||Object.keys(r).length===0?null:Pp(r,this.key)??null}eachChild(){}outputDefined(){return!1}};const Kd={"==":e5e,"!=":t5e,">":i5e,"<":r5e,">=":a5e,"<=":n5e,array:Ro,at:LSe,boolean:Ro,case:BSe,coalesce:nO,collator:oO,format:cO,image:o5e,in:FSe,"index-of":zSe,interpolate:Ts,"interpolate-hcl":Ts,"interpolate-lab":Ts,length:l5e,let:ZR,literal:Sm,match:NSe,number:Ro,"number-format":s5e,object:Ro,slice:jSe,step:L$,string:Ro,"to-boolean":Td,"to-color":Td,"to-number":Td,"to-string":Td,var:XR,within:N$,distance:q$,"global-state":G$};var zc=class Qf{constructor(t,r,i,n,a){this.name=t,this.type=r,this._evaluate=i,this.args=n,this.key=a}evaluate(t){return this._evaluate(t,this.args,this.key)}eachChild(t){this.args.forEach(t)}outputDefined(){return!1}static parse(t,r){let i=t[0],n=Qf.definitions[i];if(!n)return r.error(`Unknown expression "${i}". If you wanted a literal array, use ["literal", [...]].`,0);let a=Array.isArray(n)?n[0]:n.type,s=Array.isArray(n)?[[n[1],n[2]]]:n.overloads,o=s.filter(([u])=>!Array.isArray(u)||u.length===t.length-1),l=null;for(let[u,c]of o){l=new YR(r.registry,Py,r.path,null,r.scope);let d=[],h=!1;for(let f=1;f<t.length;f++){let p=t[f],m=Array.isArray(u)?u[f-1]:u.type,g=l.parse(p,1+d.length,m);if(!g){h=!0;break}d.push(g)}if(!h){if(Array.isArray(u)&&u.length!==d.length){l.error(`Expected ${u.length} arguments, but found ${d.length} instead.`);continue}for(let f=0;f<d.length;f++){let p=Array.isArray(u)?u[f]:u.type,m=d[f];l.concat(f+1).checkSubtype(p,m.type)}if(l.errors.length===0)return new Qf(i,a,c,d,r.key)}}if(o.length===1)r.errors.push(...l.errors);else{let u=(o.length?o:s).map(([d])=>O5e(d)).join(" | "),c=[];for(let d=1;d<t.length;d++){let h=r.parse(t[d],1+c.length);if(!h)return null;c.push(Dr(h.type))}r.error(`Expected arguments of type ${u}, but found (${c.join(", ")}) instead.`)}return null}static register(t,r){Qf.definitions=r;for(let i in r)t[i]=Qf}};function Zk(e,[t,r,i,n],a){t=t.evaluate(e),r=r.evaluate(e),i=i.evaluate(e);let s=n?n.evaluate(e):1,o=UR(t,r,i,s);if(o)throw new xr(o,a);return new at(t/255,r/255,i/255,s,!1)}function Kk(e,t){return e in t&&t[e]!==void 0}function Pb(e,t){let r=t[e];return r===void 0?null:r}function R5e(e,t,r,i){for(;r<=i;){let n=r+i>>1;if(t[n]===e)return!0;t[n]>e?i=n-1:r=n+1}return!1}function Tu(e){return{type:e}}zc.register(Kd,{error:[wSe,[ct],(e,[t],r)=>{throw new xr(t.evaluate(e),r)}],typeof:[ct,[mt],(e,[t])=>Dr(ni(t.evaluate(e)))],"to-rgba":[Sn(ke,4),[Ss],(e,[t])=>{let[r,i,n,a]=t.evaluate(e).rgb;return[r*255,i*255,n*255,a]}],rgb:[Ss,[ke,ke,ke],Zk],rgba:[Ss,[ke,ke,ke,ke],Zk],has:{type:yt,overloads:[[[ct],(e,[t])=>Kk(t.evaluate(e),e.properties())],[[ct,cc],(e,[t,r])=>Kk(t.evaluate(e),r.evaluate(e))]]},get:{type:mt,overloads:[[[ct],(e,[t])=>Pb(t.evaluate(e),e.properties())],[[ct,cc],(e,[t,r])=>Pb(t.evaluate(e),r.evaluate(e))]]},"feature-state":[mt,[ct],(e,[t])=>Pb(t.evaluate(e),e.featureState||{})],properties:[cc,[],e=>e.properties()],"geometry-type":[ct,[],e=>e.geometryType()],id:[mt,[],e=>e.id()],zoom:[ke,[],e=>e.globals.zoom],"heatmap-density":[ke,[],e=>e.globals.heatmapDensity||0],elevation:[ke,[],e=>e.globals.elevation||0],"line-progress":[ke,[],e=>e.globals.lineProgress||0],accumulated:[mt,[],e=>e.globals.accumulated===void 0?null:e.globals.accumulated],"+":[ke,Tu(ke),(e,t)=>{let r=0;for(let i of t)r+=i.evaluate(e);return r}],"*":[ke,Tu(ke),(e,t)=>{let r=1;for(let i of t)r*=i.evaluate(e);return r}],"-":{type:ke,overloads:[[[ke,ke],(e,[t,r])=>t.evaluate(e)-r.evaluate(e)],[[ke],(e,[t])=>-t.evaluate(e)]]},"/":[ke,[ke,ke],(e,[t,r])=>t.evaluate(e)/r.evaluate(e)],"%":[ke,[ke,ke],(e,[t,r])=>t.evaluate(e)%r.evaluate(e)],ln2:[ke,[],()=>Math.LN2],pi:[ke,[],()=>Math.PI],e:[ke,[],()=>Math.E],"^":[ke,[ke,ke],(e,[t,r])=>t.evaluate(e)**+r.evaluate(e)],sqrt:[ke,[ke],(e,[t])=>Math.sqrt(t.evaluate(e))],log10:[ke,[ke],(e,[t])=>Math.log(t.evaluate(e))/Math.LN10],ln:[ke,[ke],(e,[t])=>Math.log(t.evaluate(e))],log2:[ke,[ke],(e,[t])=>Math.log(t.evaluate(e))/Math.LN2],sin:[ke,[ke],(e,[t])=>Math.sin(t.evaluate(e))],cos:[ke,[ke],(e,[t])=>Math.cos(t.evaluate(e))],tan:[ke,[ke],(e,[t])=>Math.tan(t.evaluate(e))],asin:[ke,[ke],(e,[t])=>Math.asin(t.evaluate(e))],acos:[ke,[ke],(e,[t])=>Math.acos(t.evaluate(e))],atan:[ke,[ke],(e,[t])=>Math.atan(t.evaluate(e))],min:[ke,Tu(ke),(e,t)=>Math.min(...t.map(r=>r.evaluate(e)))],max:[ke,Tu(ke),(e,t)=>Math.max(...t.map(r=>r.evaluate(e)))],abs:[ke,[ke],(e,[t])=>Math.abs(t.evaluate(e))],round:[ke,[ke],(e,[t])=>{let r=t.evaluate(e);return r<0?-Math.round(-r):Math.round(r)}],floor:[ke,[ke],(e,[t])=>Math.floor(t.evaluate(e))],ceil:[ke,[ke],(e,[t])=>Math.ceil(t.evaluate(e))],"filter-==":[yt,[ct,mt],(e,[t,r])=>e.properties()[t.value]===r.value],"filter-id-==":[yt,[mt],(e,[t])=>e.id()===t.value],"filter-type-==":[yt,[ct],(e,[t])=>e.geometryType()===t.value],"filter-<":[yt,[ct,mt],(e,[t,r])=>{let i=e.properties()[t.value],n=r.value;return typeof i==typeof n&&i<n}],"filter-id-<":[yt,[mt],(e,[t])=>{let r=e.id(),i=t.value;return typeof r==typeof i&&r<i}],"filter->":[yt,[ct,mt],(e,[t,r])=>{let i=e.properties()[t.value],n=r.value;return typeof i==typeof n&&i>n}],"filter-id->":[yt,[mt],(e,[t])=>{let r=e.id(),i=t.value;return typeof r==typeof i&&r>i}],"filter-<=":[yt,[ct,mt],(e,[t,r])=>{let i=e.properties()[t.value],n=r.value;return typeof i==typeof n&&i<=n}],"filter-id-<=":[yt,[mt],(e,[t])=>{let r=e.id(),i=t.value;return typeof r==typeof i&&r<=i}],"filter->=":[yt,[ct,mt],(e,[t,r])=>{let i=e.properties()[t.value],n=r.value;return typeof i==typeof n&&i>=n}],"filter-id->=":[yt,[mt],(e,[t])=>{let r=e.id(),i=t.value;return typeof r==typeof i&&r>=i}],"filter-has":[yt,[mt],(e,[t])=>{let r=t.value,i=e.properties();return r in i&&i[r]!==void 0}],"filter-has-id":[yt,[],e=>e.id()!==null&&e.id()!==void 0],"filter-type-in":[yt,[Sn(ct)],(e,[t])=>t.value.indexOf(e.geometryType())>=0],"filter-id-in":[yt,[Sn(mt)],(e,[t])=>t.value.indexOf(e.id())>=0],"filter-in-small":[yt,[ct,Sn(mt)],(e,[t,r])=>r.value.indexOf(e.properties()[t.value])>=0],"filter-in-large":[yt,[ct,Sn(mt)],(e,[t,r])=>R5e(e.properties()[t.value],r.value,0,r.value.length-1)],all:{type:yt,overloads:[[[yt,yt],(e,[t,r])=>t.evaluate(e)&&r.evaluate(e)],[Tu(yt),(e,t)=>{for(let r of t)if(!r.evaluate(e))return!1;return!0}]]},any:{type:yt,overloads:[[[yt,yt],(e,[t,r])=>t.evaluate(e)||r.evaluate(e)],[Tu(yt),(e,t)=>{for(let r of t)if(r.evaluate(e))return!0;return!1}]]},"!":[yt,[yt],(e,[t])=>!t.evaluate(e)],"is-supported-script":[yt,[ct],(e,[t])=>{let r=e.globals&&e.globals.isSupportedScript;return!r||r(t.evaluate(e))}],upcase:[ct,[ct],(e,[t])=>t.evaluate(e).toUpperCase()],downcase:[ct,[ct],(e,[t])=>t.evaluate(e).toLowerCase()],concat:[ct,Tu(mt),(e,t)=>t.map(r=>Mp(r.evaluate(e))).join("")],split:[Sn(ct),[ct,ct],(e,[t,r])=>t.evaluate(e).split(r.evaluate(e))],join:[ct,[Sn(ct),ct],(e,[t,r])=>t.evaluate(e).join(r.evaluate(e))],"resolved-locale":[ct,[W1],(e,[t])=>t.evaluate(e).resolvedLocale()]});function O5e(e){return Array.isArray(e)?`(${e.map(Dr).join(", ")})`:`(${Dr(e.type)}...)`}function Py(e){if(e instanceof XR)return Py(e.boundExpression);if(e instanceof zc&&e.name==="error"||e instanceof oO||e instanceof N$||e instanceof q$||e instanceof G$)return!1;let t=e instanceof Td||e instanceof Ro,r=!0;return e.eachChild(i=>{r&&(r=t?Py(i):i instanceof Sm)}),r?ev(e)&&tv(e,["zoom","heatmap-density","elevation","line-progress","accumulated","is-supported-script"]):!1}function ev(e){if(e instanceof zc&&(e.name==="get"&&e.args.length===1||e.name==="feature-state"||e.name==="has"&&e.args.length===1||e.name==="properties"||e.name==="geometry-type"||e.name==="id"||/^filter-/.test(e.name))||e instanceof N$||e instanceof q$)return!1;let t=!0;return e.eachChild(r=>{t&&!ev(r)&&(t=!1)}),t}function Cm(e){if(e instanceof zc&&e.name==="feature-state")return!1;let t=!0;return e.eachChild(r=>{t&&!Cm(r)&&(t=!1)}),t}function tv(e,t){if(e instanceof zc&&t.indexOf(e.name)>=0)return!1;let r=!0;return e.eachChild(i=>{r&&!tv(i,t)&&(r=!1)}),r}function tw(e){return{result:"success",value:e}}function fd(e){return{result:"error",value:e}}function Ah(e){return e["property-type"]==="data-driven"||e["property-type"]==="cross-faded-data-driven"}function xO(e){return!!e.expression&&e.expression.parameters.indexOf("zoom")>-1}function H$(e){return!!e.expression&&e.expression.interpolated}function km(e,...t){for(let r of t)for(let i in r)e[i]=r[i];return e}function vt(e){return e instanceof Number?"number":e instanceof String?"string":e instanceof Boolean?"boolean":Array.isArray(e)?"array":e===null?"null":typeof e}function rv(e){return typeof e=="object"&&!!e&&!Array.isArray(e)&&ni(e)===cc}function L5e(e){return e}function F5e(e){switch(e.type){case"color":return at.parse;case"padding":return po.parse;case"numberArray":return mo.parse;case"colorArray":return rs.parse;default:return null}}function z5e(e){switch(e){case"exponential":return $O;case"interval":return B5e;case"categorical":return N5e;case"identity":return j5e;default:throw Error(`Unknown function type "${e}"`)}}function wO(e,t){let r=e.stops&&typeof e.stops[0][0]=="object",i=r||e.property!==void 0,n=r||!i,a=e.type||(H$(t)?"exponential":"interval"),s=F5e(t);if(s&&(e=km({},e),e.stops&&(e.stops=e.stops.map(c=>[c[0],s(c[1])])),e.default?e.default=s(e.default):e.default=s(t.default)),e.colorSpace&&!ASe(e.colorSpace))throw Error(`Unknown color space: "${e.colorSpace}"`);let o=z5e(a),l,u;if(a==="categorical"){l=Object.create(null);for(let c of e.stops)l[c[0]]=c[1];u=typeof e.stops[0][0]}if(r){let c={},d=[];for(let p=0;p<e.stops.length;p++){let m=e.stops[p],g=m[0].zoom;c[g]===void 0&&(c[g]={zoom:g,type:e.type,property:e.property,default:e.default,stops:[]},d.push(g)),c[g].stops.push([m[0].value,m[1]])}let h=[];for(let p of d)h.push([c[p].zoom,wO(c[p],t)]);let f={name:"linear"};return{kind:"composite",interpolationType:f,interpolationFactor:Ts.interpolationFactor.bind(void 0,f),zoomStops:h.map(p=>p[0]),evaluate({zoom:p},m){return $O({stops:h,base:e.base},t,p).evaluate(p,m)}}}if(n){let c=a==="exponential"?{name:"exponential",base:e.base===void 0?1:e.base}:null;return{kind:"camera",interpolationType:c,interpolationFactor:Ts.interpolationFactor.bind(void 0,c),zoomStops:e.stops.map(d=>d[0]),evaluate:({zoom:d})=>o(e,t,d,l,u)}}return{kind:"source",evaluate(c,d){let h=d&&d.properties?d.properties[e.property]:void 0;return h===void 0?pg(e.default,t.default):o(e,t,h,l,u)}}}function pg(e,t,r){if(e!==void 0)return e;if(t!==void 0)return t;if(r!==void 0)return r}function N5e(e,t,r,i,n){return pg(typeof r===n?i[r]:void 0,e.default,t.default)}function B5e(e,t,r){if(vt(r)!=="number")return pg(e.default,t.default);let i=e.stops.length;if(i===1||r<=e.stops[0][0])return e.stops[0][1];if(r>=e.stops[i-1][0])return e.stops[i-1][1];let n=J1(e.stops.map(a=>a[0]),r,"");return e.stops[n][1]}function $O(e,t,r){let i=e.base===void 0?1:e.base;if(vt(r)!=="number")return pg(e.default,t.default);let n=e.stops.length;if(n===1||r<=e.stops[0][0])return e.stops[0][1];if(r>=e.stops[n-1][0])return e.stops[n-1][1];let a=J1(e.stops.map(c=>c[0]),r,""),s=U5e(r,i,e.stops[a][0],e.stops[a+1][0]),o=e.stops[a][1],l=e.stops[a+1][1],u=ai[t.type]||L5e;return typeof o.evaluate=="function"?{evaluate(...c){let d=o.evaluate.apply(void 0,c),h=l.evaluate.apply(void 0,c);if(d!==void 0&&h!==void 0)return u(d,h,s,e.colorSpace)}}:u(o,l,s,e.colorSpace)}function j5e(e,t,r){switch(t.type){case"color":r=at.parse(r);break;case"formatted":r=dl.fromString(r.toString());break;case"resolvedImage":r=uo.fromString(r.toString());break;case"padding":r=po.parse(r);break;case"colorArray":r=rs.parse(r);break;case"numberArray":r=mo.parse(r);break;default:vt(r)!==t.type&&(t.type!=="enum"||!t.values[r])&&(r=void 0)}return pg(r,e.default,t.default)}function U5e(e,t,r,i){let n=i-r,a=e-r;return n===0?0:t===1?a/n:(t**+a-1)/(t**+n-1)}var Y$=class{constructor(t,r,i,n){this.expression=t,this._warningHistory={},this._evaluator=new HR,this._defaultValue=i?PO(i):null,this._enumValues=i&&i.type==="enum"?i.values:null,this._globalState=n,this._rootKey=r}evaluateWithoutErrorHandling(t,r,i,n,a,s){return this._globalState&&(t=Dh(t,this._globalState)),this._evaluator.globals=t,this._evaluator.feature=r,this._evaluator.featureState=i,this._evaluator.canonical=n,this._evaluator.availableImages=a||null,this._evaluator.formattedSection=s,this.expression.evaluate(this._evaluator)}evaluate(t,r,i,n,a,s){this._globalState&&(t=Dh(t,this._globalState)),this._evaluator.globals=t,this._evaluator.feature=r||null,this._evaluator.featureState=i||null,this._evaluator.canonical=n,this._evaluator.availableImages=a||null,this._evaluator.formattedSection=s||null;try{let o=this.expression.evaluate(this._evaluator);if(o==null||typeof o=="number"&&o!==o)return this._defaultValue;if(this._enumValues&&!(o in this._enumValues))throw new xr(`Expected value to be one of ${Object.keys(this._enumValues).map(l=>JSON.stringify(l)).join(", ")}, but found ${JSON.stringify(o)} instead.`,"");return o}catch(o){let l=o instanceof xr?o.path:"",u=`${l}|${o.message}`;return this._warningHistory[u]||(this._warningHistory[u]=!0,typeof console<"u"&&console.warn(SO(this._rootKey,l,o.message,this._defaultValue))),this._defaultValue}}};function SO(e,t,r,i){return`${e}${t}: ${r}${i==null?"":` Falling back to ${String(i)}.`}`}function TO(e){if(!e)throw Error('rootKey must identify the location of the expression in the style JSON, e.g. "layers[3].paint.line-width".')}function iv(e){return Array.isArray(e)&&e.length>0&&typeof e[0]=="string"&&e[0]in Kd}function nv(e,t,r,i){TO(t);let n=new YR(Kd,Py,[],r?G5e(r):void 0),a=n.parse(e,void 0,void 0,void 0,r&&r.type==="string"?{typeAnnotation:"coerce"}:void 0);return a?tw(new Y$(a,t,r,i)):fd(n.errors)}var Em=class{constructor(t,r,i){this.kind=t,this._styleExpression=r,this.isStateDependent=t!=="constant"&&!Cm(r.expression),this.globalStateRefs=mg(r.expression),this._globalState=i}evaluateWithoutErrorHandling(t,r,i,n,a,s){return this._globalState&&(t=Dh(t,this._globalState)),this._styleExpression.evaluateWithoutErrorHandling(t,r,i,n,a,s)}evaluate(t,r,i,n,a,s){return this._globalState&&(t=Dh(t,this._globalState)),this._styleExpression.evaluate(t,r,i,n,a,s)}},My=class{constructor(t,r,i,n,a){this.kind=t,this.zoomStops=i,this._styleExpression=r,this.isStateDependent=t!=="camera"&&!Cm(r.expression),this.globalStateRefs=mg(r.expression),this.interpolationType=n,this._globalState=a}evaluateWithoutErrorHandling(t,r,i,n,a,s){return this._globalState&&(t=Dh(t,this._globalState)),this._styleExpression.evaluateWithoutErrorHandling(t,r,i,n,a,s)}evaluate(t,r,i,n,a,s){return this._globalState&&(t=Dh(t,this._globalState)),this._styleExpression.evaluate(t,r,i,n,a,s)}interpolationFactor(t,r,i){return this.interpolationType?Ts.interpolationFactor(this.interpolationType,t,r,i):0}};function V5e(e){return e._styleExpression!==void 0}function CO(e,t,r,i){let n=nv(e,t,r,i);if(n.result==="error")return n;let a=n.value.expression,s=ev(a);if(!s&&!Ah(r))return fd([new Ws("","data expressions not supported")]);let o=tv(a,["zoom"]);if(!o&&!xO(r))return fd([new Ws("","zoom expressions not supported")]);let l=g_(a);if(!l&&!o)return fd([new Ws("",'"zoom" expression may only be used as input to a top-level "step" or "interpolate" expression.')]);if(l instanceof Ws)return fd([l]);if(l instanceof Ts&&!H$(r))return fd([new Ws("",'"interpolate" expressions cannot be used with this property')]);if(!l)return tw(s?new Em("constant",n.value,i):new Em("source",n.value,i));let u=l instanceof Ts?l.interpolation:void 0;return tw(s?new My("camera",n.value,l.labels,u,i):new My("composite",n.value,l.labels,u,i))}var kO=class EO{constructor(t,r,i){this.isStateDependent=!1,this.globalStateRefs=new Set,this._globalState=null,TO(r),this._parameters=t,this._specification=i,this._rootKey=r,this._defaultValue=PO(i),this._warningHistory={};let n=wO(this._parameters,this._specification);this.kind=n.kind,this.interpolationFactor=n.interpolationFactor,this.zoomStops=n.zoomStops,this.interpolationType=n.interpolationType,this._innerEvaluate=n.evaluate}evaluate(t,r){try{return this._innerEvaluate(t,r)}catch(i){let n=i instanceof Error?i.message:String(i),a=`|${n}`;return this._warningHistory[a]||(this._warningHistory[a]=!0,typeof console<"u"&&console.warn(SO(this._rootKey,"",n,this._defaultValue))),this._defaultValue}}static deserialize(t){return new EO(t._parameters,t._rootKey,t._specification)}static serialize(t){return{_parameters:t._parameters,_specification:t._specification,_rootKey:t._rootKey}}};function q5e(e,t,r,i){if(rv(e))return new kO(e,t,r);if(iv(e)){let n=CO(e,t,r,i);if(n.result==="error")throw Error(n.value.map(a=>`${a.key}: ${a.message}`).join(", "));return n.value}{let n=e;return r.type==="color"&&typeof e=="string"?n=at.parse(e):r.type==="padding"&&(typeof e=="number"||Array.isArray(e))?n=po.parse(e):r.type==="numberArray"&&(typeof e=="number"||Array.isArray(e))?n=mo.parse(e):r.type==="colorArray"&&(typeof e=="string"||Array.isArray(e))?n=rs.parse(e):r.type==="variableAnchorOffsetCollection"&&Array.isArray(e)?n=yu.parse(e):r.type==="projectionDefinition"&&typeof e=="string"&&(n=vu.parse(e)),{globalStateRefs:new Set,_globalState:null,kind:"constant",evaluate:()=>n}}}function g_(e){let t=null;if(e instanceof ZR)t=g_(e.result);else if(e instanceof nO){for(let r of e.args)if(t=g_(r),t)break}else(e instanceof L$||e instanceof Ts)&&e.input instanceof zc&&e.input.name==="zoom"&&(t=e);return t instanceof Ws||e.eachChild(r=>{let i=g_(r);i instanceof Ws?t=i:!t&&i?t=new Ws("",'"zoom" expression may only be used as input to a top-level "step" or "interpolate" expression.'):t&&i&&t!==i&&(t=new Ws("",'Only one zoom-based "step" or "interpolate" subexpression may be used in an expression.'))}),t}function mg(e,t=new Set){return e instanceof G$&&t.add(e.key),e.eachChild(r=>{mg(r,t)}),t}function G5e(e){let t={color:Ss,string:ct,number:ke,enum:ct,boolean:yt,formatted:dg,padding:Z1,numberArray:K1,colorArray:xm,projectionDefinition:Y1,resolvedImage:hg,variableAnchorOffsetCollection:X1};return e.type==="array"?Sn(t[e.value]||mt,e.length):t[e.type]}function PO(e){if(e.type==="color"&&rv(e.default))return new at(0,0,0,0);switch(e.type){case"color":return at.parse(e.default)||null;case"padding":return po.parse(e.default)||null;case"numberArray":return mo.parse(e.default)||null;case"colorArray":return rs.parse(e.default)||null;case"variableAnchorOffsetCollection":return yu.parse(e.default)||null;case"projectionDefinition":return vu.parse(e.default)||null;default:return e.default===void 0?null:e.default}}function Dh(e,t){let{zoom:r,heatmapDensity:i,elevation:n,lineProgress:a,isSupportedScript:s,accumulated:o}=e??{};return{zoom:r,heatmapDensity:i,elevation:n,lineProgress:a,isSupportedScript:s,accumulated:o,globalState:t}}function H5e(e){let t=!1;for(let r of e){let i=MO(r);if(i==="expression")return"expression";i==="legacy"&&(t=!0)}return t?"legacy":"neutral"}function MO(e){if(typeof e=="boolean")return"neutral";if(!Array.isArray(e)||e.length===0)return"legacy";switch(e[0]){case"has":return e.length<2||e[1]==="$id"||e[1]==="$type"?"legacy":e.length===2?"neutral":"expression";case"in":return e.length>=3&&(typeof e[1]!="string"||Array.isArray(e[2]))?"expression":"legacy";case"!in":case"!has":return"legacy";case"==":case"!=":case">":case">=":case"<":case"<=":return e.length!==3||Array.isArray(e[1])||Array.isArray(e[2])?"expression":"legacy";case"none":return"legacy";case"any":case"all":return H5e(e.slice(1));default:return"expression"}}function W$(e){return MO(e)!=="legacy"}function Xk(e){return e==="$type"?["geometry-type"]:e==="$id"?["id"]:["get",e]}function Y5e(e){switch(e[0]){case"==":case"!=":case"<":case"<=":case">":case">=":return e.length!==3||typeof e[1]!="string"?null:[e[0],Xk(e[1]),e[2]];case"in":case"!in":{if(e.length<2||typeof e[1]!="string")return null;let t=["in",Xk(e[1]),["literal",e.slice(2)]];return e[0]==="!in"?["!",t]:t}case"has":case"!has":{if(e.length!==2||typeof e[1]!="string"||e[1]==="$type"||e[1]==="$id")return null;let t=["has",e[1]];return e[0]==="!has"?["!",t]:t}default:return null}}function IO(e){if((e[0]==="<"||e[0]==="<="||e[0]===">"||e[0]===">=")&&e[1]==="$type")return`"$type" cannot be use with operator "${e[0]}"`;let t=Y5e(e);return t?`Mixing deprecated filter syntax with expression syntax is not supported. Replace ${JSON.stringify(e)} with ${JSON.stringify(t)}.`:`Mixing deprecated filter syntax with expression syntax is not supported. Convert ${JSON.stringify(e)} to expression syntax.`}function Mb(e,t,r){let i=r[e];return Array.isArray(i)?W$(i)?Z$(i,t.concat(e)):{path:t.concat(e),legacyFilter:i}:null}function Z$(e,t=[]){if(!Array.isArray(e)||e.length<1)return null;switch(e[0]){case"all":case"any":case"none":for(let r=1;r<e.length;r++){let i=Mb(r,t,e);if(i)return i}break;case"!":{let r=Mb(1,t,e);if(r)return r;break}case"case":for(let r=1;r<e.length-1;r+=2){let i=Mb(r,t,e);if(i)return i}}return null}function W5e(e,t){let r=Z$(e);
vendor: 6,922 bytes, line 740
740if(!r||typeof console>"u")return;let i=r.path.map(n=>`[${n}]`).join("");console.warn(`${t}${i}: ${IO(r.legacyFilter)}`)}const Z5e={type:"boolean",default:!1,transition:!1,"property-type":"data-driven",expression:{interpolated:!1,parameters:["zoom","feature"]}};function Pm(e,t,r){if(e==null)return{filter:()=>!0,needGeometry:!1,getGlobalStateRefs:()=>new Set};W$(e)?W5e(e,t):e=Iy(e);let i=nv(e,t,Z5e,r);if(i.result==="error")throw Error(i.value.map(n=>`${n.key}: ${n.message}`).join(", "));return{filter:(n,a,s)=>i.value.evaluate(n,a,{},s),needGeometry:AO(e),getGlobalStateRefs:()=>mg(i.value.expression)}}function K5e(e,t){return e<t?-1:+(e>t)}function AO(e){if(!Array.isArray(e))return!1;if(e[0]==="within"||e[0]==="distance")return!0;for(let t=1;t<e.length;t++)if(AO(e[t]))return!0;return!1}function Iy(e){if(!e)return!0;let t=e[0];return e.length<=1?t!=="any":t==="=="?Ib(e[1],e[2],"=="):t==="!="?v0(Ib(e[1],e[2],"==")):t==="<"||t===">"||t==="<="||t===">="?Ib(e[1],e[2],t):t==="any"?X5e(e.slice(1)):t==="all"?["all"].concat(e.slice(1).map(Iy)):t==="none"?["all"].concat(e.slice(1).map(Iy).map(v0)):t==="in"?Jk(e[1],e.slice(2)):t==="!in"?v0(Jk(e[1],e.slice(2))):t==="has"?Qk(e[1]):t!=="!has"||v0(Qk(e[1]))}function Ib(e,t,r){switch(e){case"$type":return[`filter-type-${r}`,t];case"$id":return[`filter-id-${r}`,t];default:return[`filter-${r}`,e,t]}}function X5e(e){return["any"].concat(e.map(Iy))}function Jk(e,t){if(t.length===0)return!1;switch(e){case"$type":return["filter-type-in",["literal",t]];case"$id":return["filter-id-in",["literal",t]];default:return t.length>200&&!t.some(r=>typeof r!=typeof t[0])?["filter-in-large",e,["literal",t.sort(K5e)]]:["filter-in-small",e,["literal",t]]}}function Qk(e){switch(e){case"$type":return!0;case"$id":return["filter-has-id"];default:return["filter-has",e]}}function v0(e){return["!",e]}function J5e(){let e={},t=ce.$version;for(let r in ce.$root){let i=ce.$root[r];if(i.required){let n=null;n=r==="version"?t:i.type==="array"?[]:{},n!=null&&(e[r]=n)}}return e}function DO(e){let t=e.key,r=e.value;return r?[new Te(t,r,"constants have been deprecated as of v8")]:[]}function Vr(e){return e instanceof Number||e instanceof String||e instanceof Boolean?e.valueOf():e}function Tc(e){if(Array.isArray(e))return e.map(Tc);if(e instanceof Object&&!(e instanceof Number||e instanceof String||e instanceof Boolean)){let t={};for(let r in e)t[r]=Tc(e[r]);return t}return Vr(e)}function va(e){let t=e.key,r=e.value,i=e.valueSpec||{},n=e.objectElementValidators||{},a=e.style,s=e.styleSpec,o=e.validateSpec,l=[],u=vt(r);if(u!=="object")return[new Te(t,r,`object expected, ${u} found`)];for(let c in r){let d=c.split(".")[0],h=Pp(i,d)||i["*"],f;if(Pp(n,d))f=n[d];else if(Pp(i,d)){if(r[c]===void 0)continue;f=o}else if(n["*"])f=n["*"];else if(i["*"])f=o;else{l.push(new Te(t,r[c],`unknown property "${c}"`));continue}l=l.concat(f({key:(t&&`${t}.`)+c,value:r[c],valueSpec:h,style:a,styleSpec:s,object:r,objectKey:c,validateSpec:o},r))}for(let c in i)n[c]||i[c].required&&i[c].default===void 0&&r[c]===void 0&&l.push(new Te(t,r,`missing required property "${c}"`));return l}function K$(e){let t=e.value,r=e.valueSpec,i=e.validateSpec,n=e.style,a=e.styleSpec,s=e.key,o=e.arrayElementValidator||i;if(vt(t)!=="array")return[new Te(s,t,`array expected, ${vt(t)} found`)];if(r.length&&t.length!==r.length)return[new Te(s,t,`array length ${r.length} expected, length ${t.length} found`)];let l={type:r.value,values:r.values};a.$version<7&&(l.function=r.function),vt(r.value)==="object"&&(l=r.value);let u=[];for(let c=0;c<t.length;c++)u=u.concat(o({array:t,arrayIndex:c,value:t[c],valueSpec:l,validateSpec:e.validateSpec,style:n,styleSpec:a,key:`${s}[${c}]`}));return u}function av(e){let t=e.key,r=e.value,i=e.valueSpec,n=vt(r);return n==="number"&&r!==r&&(n="NaN"),n==="number"?"minimum"in i&&r<i.minimum?[new Te(t,r,`${r} is less than the minimum value ${i.minimum}`)]:"maximum"in i&&r>i.maximum?[new Te(t,r,`${r} is greater than the maximum value ${i.maximum}`)]:[]:[new Te(t,r,`number expected, ${n} found`)]}function RO(e){let t=e.valueSpec,r=Vr(e.value.type),i,n={},a,s,o=r!=="categorical"&&e.value.property===void 0,l=!o,u=vt(e.value.stops)==="array"&&vt(e.value.stops[0])==="array"&&vt(e.value.stops[0][0])==="object",c=va({key:e.key,value:e.value,valueSpec:e.styleSpec.function,validateSpec:e.validateSpec,style:e.style,styleSpec:e.styleSpec,objectElementValidators:{stops:d,default:p}});return r==="identity"&&o&&c.push(new Te(e.key,e.value,'missing required property "property"')),r!=="identity"&&!e.value.stops&&c.push(new Te(e.key,e.value,'missing required property "stops"')),r==="exponential"&&e.valueSpec.expression&&!H$(e.valueSpec)&&c.push(new Te(e.key,e.value,"exponential functions not supported")),e.styleSpec.$version>=8&&(l&&!Ah(e.valueSpec)?c.push(new Te(e.key,e.value,"property functions not supported")):o&&!xO(e.valueSpec)&&c.push(new Te(e.key,e.value,"zoom functions not supported"))),(r==="categorical"||u)&&e.value.property===void 0&&c.push(new Te(e.key,e.value,'"property" property is required')),c;function d(m){if(r==="identity")return[new Te(m.key,m.value,'identity function may not have a "stops" property')];let g=[],v=m.value;return g=g.concat(K$({key:m.key,value:v,valueSpec:m.valueSpec,validateSpec:m.validateSpec,style:m.style,styleSpec:m.styleSpec,arrayElementValidator:h})),vt(v)==="array"&&v.length===0&&g.push(new Te(m.key,v,"array must have at least one stop")),g}function h(m){let g=[],v=m.value,x=m.key;if(vt(v)!=="array")return[new Te(x,v,`array expected, ${vt(v)} found`)];if(v.length!==2)return[new Te(x,v,`array length 2 expected, length ${v.length} found`)];if(u){if(vt(v[0])!=="object")return[new Te(x,v,`object expected, ${vt(v[0])} found`)];if(v[0].zoom===void 0)return[new Te(x,v,"object stop key must have zoom")];if(v[0].value===void 0)return[new Te(x,v,"object stop key must have value")];if(s&&s>Vr(v[0].zoom))return[new Te(x,v[0].zoom,"stop zoom values must appear in ascending order")];Vr(v[0].zoom)!==s&&(s=Vr(v[0].zoom),a=void 0,n={}),g=g.concat(va({key:`${x}[0]`,value:v[0],valueSpec:{zoom:{}},validateSpec:m.validateSpec,style:m.style,styleSpec:m.styleSpec,objectElementValidators:{zoom:av,value:f}}))}else g=g.concat(f({key:`${x}[0]`,value:v[0],validateSpec:m.validateSpec,style:m.style,styleSpec:m.styleSpec},v));return iv(Tc(v[1]))?g.concat([new Te(`${x}[1]`,v[1],"expressions are not allowed in function stops.")]):g.concat(m.validateSpec({key:`${x}[1]`,value:v[1],valueSpec:t,validateSpec:m.validateSpec,style:m.style,styleSpec:m.styleSpec}))}function f(m,g){let v=vt(m.value),x=Vr(m.value),_=m.value===null?g:m.value;if(!i)i=v;else if(v!==i)return[new Te(m.key,_,`${v} stop domain type must match previous stop domain type ${i}`)];if(v!=="number"&&v!=="string"&&v!=="boolean")return[new Te(m.key,_,"stop domain value must be a number, string, or boolean")];if(v!=="number"&&r!=="categorical"){let y=`number expected, ${v}
740 found`;return Ah(t)&&r===void 0&&(y+='\nIf you intended to use a categorical function, specify `"type": "categorical"`.'),[new Te(m.key,_,y)]}return r==="categorical"&&v==="number"&&(!isFinite(x)||Math.floor(x)!==x)?[new Te(m.key,_,`integer expected, found ${x}`)]:r!=="categorical"&&v==="number"&&a!==void 0&&x<a?[new Te(m.key,_,"stop domain values must appear in ascending order")]:(a=x,r==="categorical"&&x in n?[new Te(m.key,_,"stop domain values must be unique")]:(n[x]=!0,[]))}function p(m){return m.validateSpec({key:m.key,value:m.value,valueSpec:t,validateSpec:m.validateSpec,style:m.style,styleSpec:m.styleSpec})}}function Rh(e){let t=(e.expressionContext==="property"?CO:nv)(Tc(e.value),e.key,e.valueSpec);if(t.result==="error")return t.value.map(i=>new Te(`${e.key}${i.key}`,e.value,i.message));let r=t.value.expression||t.value._styleExpression.expression;if(e.expressionContext==="property"&&e.propertyKey==="text-font"&&!r.outputDefined())return[new Te(e.key,e.value,`Invalid data expression for "${e.propertyKey}". Output values must be contained as literals within the expression.`)];if(e.expressionContext==="property"&&e.propertyType==="layout"&&!Cm(r))return[new Te(e.key,e.value,'"feature-state" data expressions are not supported with layout properties.')];if(e.expressionContext==="filter"&&!Cm(r))return[new Te(e.key,e.value,'"feature-state" data expressions are not supported with filters.')];if(e.expressionContext&&e.expressionContext.indexOf("cluster")===0){if(!tv(r,["zoom","feature-state"]))return[new Te(e.key,e.value,'"zoom" and "feature-state" expressions are not supported with cluster properties.')];if(e.expressionContext==="cluster-initial"&&!ev(r))return[new Te(e.key,e.value,"Feature data expressions are not supported with initial expression part of cluster properties.")]}return[]}function Q5e(e){let t=e.value,r=e.key,i=vt(t);return i==="boolean"?[]:[new Te(r,t,`boolean expected, ${i} found`)]}function rw(e){let t=e.key,r=e.value,i=vt(r);return i==="string"?at.parse(String(r))?[]:[new Te(t,r,`color expected, "${r}" found`)]:[new Te(t,r,`color expected, ${i} found`)]}function Mm(e){let t=e.key,r=e.value,i=e.valueSpec,n=[];return Array.isArray(i.values)?i.values.indexOf(Vr(r))===-1&&n.push(new Te(t,r,`expected one of [${i.values.join(", ")}], ${JSON.stringify(r)} found`)):Object.keys(i.values).indexOf(Vr(r))===-1&&n.push(new Te(t,r,`expected one of [${Object.keys(i.values).join(", ")}], ${JSON.stringify(r)} found`)),n}function eTe(e,t){let r=e;for(let i of t)r=r[i];return r}function tTe(e,t){let r=Z$(t);return r?[new Te(`${e.key}${r.path.map(i=>`[${i}]`).join("")}`,eTe(e.value,r.path),IO(r.legacyFilter),null,"warning")]:[]}function X$(e){let t=Tc(e.value);return W$(t)?[...tTe(e,t),...Rh(km({},e,{expressionContext:"filter",valueSpec:{value:"boolean"}}))]:OO(e)}function OO(e){let t=e.value,r=e.key;if(vt(t)!=="array")return[new Te(r,t,`array expected, ${vt(t)} found`)];let i=e.styleSpec,n,a=[];if(t.length<1)return[new Te(r,t,"filter array must have at least 1 element")];switch(a=a.concat(Mm({key:`${r}[0]`,value:t[0],valueSpec:i.filter_operator,style:e.style,styleSpec:e.styleSpec})),Vr(t[0])){case"<":case"<=":case">":case">=":t.length>=2&&Vr(t[1])==="$type"&&a.push(new Te(r,t,`"$type" cannot be use with operator "${t[0]}"`));case"==":case"!=":t.length!==3&&a.push(new Te(r,t,`filter array for operator "${t[0]}" must have 3 elements`));case"in":case"!in":t.length>=2&&(n=vt(t[1]),n!=="string"&&a.push(new Te(`${r}[1]`,t[1],`string expected, ${n} found`)));for(let s=2;s<t.length;s++)n=vt(t[s]),Vr(t[1])==="$type"?a=a.concat(Mm({key:`${r}[${s}]`,value:t[s],valueSpec:i.geometry_type,style:e.style,styleSpec:e.styleSpec})):n!=="string"&&n!=="number"&&n!=="boolean"&&a.push(new Te(`${r}[${s}]`,t[s],`string, number, or boolean expected, ${n} found`));break;case"any":case"all":case"none":for(let s=1;s<t.length;s++)a=a.concat(OO({key:`${r}[${s}]`,value:t[s],style:e.style,styleSpec:e.styleSpec}));break;case"has":case"!has":n=vt(t[1]),t.length===2?n!=="string"&&a.push(new Te(`${r}[1]`,t[1],`string expected, ${n} found`)):a.push(new Te(r,t,`filter array for "${t[0]}" operator must have 2 elements`))}return a}function LO(e,t){let r=e.key,i=e.validateSpec,n=e.style,a=e.styleSpec,s=e.value,o=e.objectKey,l=a[`${t}_${e.layerType}`];if(!l)return[];let u=o.match(/^(.*)-transition$/);if(t==="paint"&&u&&l[u[1]]&&l[u[1]].transition)return i({key:r,value:s,valueSpec:a.transition,style:n,styleSpec:a});let c=e.valueSpec||l[o];
vendor: 10,414 bytes, lines 740-741
740if(!c)return[new Te(r,s,`unknown property "${o}"`)];let d;if(vt(s)==="string"&&Ah(c)&&!c.tokens&&(d=/^{([^}]+)}$/.exec(s)))return[new Te(r,s,`"${o}" does not support interpolation syntax 741Use an identity property function instead: \`{ "type": "identity", "property": ${JSON.stringify(d[1])} }\`.`)];let h=[];return e.layerType==="symbol"&&o==="text-font"&&rv(Tc(s))&&Vr(s.type)==="identity"&&h.push(new Te(r,s,'"text-font" does not support identity functions')),h.concat(i({key:e.key,value:s,valueSpec:c,style:n,styleSpec:a,expressionContext:"property",propertyType:t,propertyKey:o}))}function FO(e){return LO(e,"paint")}function zO(e){return LO(e,"layout")}function NO(e){var l,u;let t=[],r=e.value,i=e.key,n=e.style,a=e.styleSpec;if(vt(r)!=="object")return[new Te(i,r,`object expected, ${vt(r)} found`)];!r.type&&!r.ref&&t.push(new Te(i,r,'either "type" or "ref" is required'));let s=Vr(r.type),o=Vr(r.ref);if(r.id){let c=Vr(r.id);for(let d=0;d<e.arrayIndex;d++){let h=n.layers[d];Vr(h.id)===c&&t.push(new Te(i,r.id,`duplicate layer id "${r.id}", previously used at line ${h.id.__line__}`))}}if("ref"in r){["type","source","source-layer","filter","layout"].forEach(d=>{d in r&&t.push(new Te(i,r[d],`"${d}" is prohibited for ref layers`))});let c;n.layers.forEach(d=>{Vr(d.id)===o&&(c=d)}),c?c.ref?t.push(new Te(i,r.ref,"ref cannot reference another ref layer")):s=Vr(c.type):t.push(new Te(i,r.ref,`ref layer "${o}" not found`))}else if(s!=="background")if(!r.source)t.push(new Te(i,r,'missing required property "source"'));else{let c=n.sources&&n.sources[r.source],d=c&&Vr(c.type);c?d==="vector"&&s==="raster"?t.push(new Te(i,r.source,`layer "${r.id}" requires a raster source`)):d!=="raster-dem"&&s==="hillshade"||d!=="raster-dem"&&s==="color-relief"?t.push(new Te(i,r.source,`layer "${r.id}" requires a raster-dem source`)):d==="raster"&&s!=="raster"?t.push(new Te(i,r.source,`layer "${r.id}" requires a vector source`)):d==="vector"&&!r["source-layer"]?t.push(new Te(i,r,`layer "${r.id}" must specify a "source-layer"`)):d==="raster-dem"&&s!=="hillshade"&&s!=="color-relief"?t.push(new Te(i,r.source,"raster-dem source can only be used with layer type 'hillshade' or 'color-relief'.")):s==="line"&&r.paint&&r.paint["line-gradient"]&&(d!=="geojson"||!c.lineMetrics)&&t.push(new Te(i,r,`layer "${r.id}" specifies a line-gradient, which requires a GeoJSON source with \`lineMetrics\` enabled.`)):t.push(new Te(i,r.source,`source "${r.source}" not found`))}return s==="raster"&&((l=r.paint)!=null&&l.resampling)&&((u=r.paint)!=null&&u["raster-resampling"])&&t.push(new Te(i,r.paint,`layer "${r.id}" redundantly specifies "resampling" and "raster-resampling" paint properties, but only one is allowed. It is advised to use "resampling".`)),t=t.concat(va({key:i,value:r,valueSpec:a.layer,style:e.style,styleSpec:e.styleSpec,validateSpec:e.validateSpec,objectElementValidators:{"*"(){return[]},type(){return e.validateSpec({key:`${i}.type`,value:r.type,valueSpec:a.layer.type,style:e.style,styleSpec:e.styleSpec,validateSpec:e.validateSpec,object:r,objectKey:"type"})},filter:X$,layout(c){return va({layer:r,key:c.key,value:c.value,style:c.style,styleSpec:c.styleSpec,validateSpec:c.validateSpec,objectElementValidators:{"*"(d){return zO(km({layerType:s},d))}}})},paint(c){return va({layer:r,key:c.key,value:c.value,style:c.style,styleSpec:c.styleSpec,validateSpec:c.validateSpec,objectElementValidators:{"*"(d){return FO(km({layerType:s},d))}}})}}})),t}function cu(e){let t=e.value,r=e.key,i=vt(t);return i==="string"?[]:[new Te(r,t,`string expected, ${i} found`)]}function rTe(e){let t=e.sourceName??"",r=e.value,i=e.styleSpec,n=i.source_raster_dem,a=e.style,s=[],o=vt(r);if(r===void 0)return s;if(o!=="object")return s.push(new Te("source_raster_dem",r,`object expected, ${o} found`)),s;let l=Vr(r.encoding)==="custom",u=["redFactor","greenFactor","blueFactor","baseShift"],c=e.value.encoding?`"${e.value.encoding}"`:"Default";for(let d in r)!l&&u.includes(d)?s.push(new Te(d,r[d],`In "${t}": "${d}" is only valid when "encoding" is set to "custom". ${c} encoding found`)):n[d]?s=s.concat(e.validateSpec({key:d,value:r[d],valueSpec:n[d],validateSpec:e.validateSpec,style:a,styleSpec:i})):s.push(new Te(d,r[d],`unknown property "${d}"`));return s}const e8={promoteId:iTe};function BO(e){let t=e.value,r=e.key,i=e.styleSpec,n=e.style,a=e.validateSpec;if(!t.type)return[new Te(r,t,'"type" is required')];let s=Vr(t.type),o;switch(s){case"vector":case"raster":return o=va({key:r,value:t,valueSpec:i[`source_${s.replace("-","_")}`],style:e.style,styleSpec:i,objectElementValidators:e8,validateSpec:a}),o;case"raster-dem":return o=rTe({sourceName:r,value:t,style:e.style,styleSpec:i,validateSpec:a}),o;case"geojson":if(o=va({key:r,value:t,valueSpec:i.source_geojson,style:n,styleSpec:i,validateSpec:a,objectElementValidators:e8}),t.cluster)for(let l in t.clusterProperties){let[u,c]=t.clusterProperties[l],d=typeof u=="string"?[u,["accumulated"],["get",l]]:u;o.push(...Rh({key:`${r}.${l}.map`,value:c,expressionContext:"cluster-map"})),o.push(...Rh({key:`${r}.${l}.reduce`,value:d,expressionContext:"cluster-reduce"}))}return o;case"video":return va({key:r,value:t,valueSpec:i.source_video,style:n,validateSpec:a,styleSpec:i});case"image":return va({key:r,value:t,valueSpec:i.source_image,style:n,validateSpec:a,styleSpec:i});case"canvas":return[new Te(r,null,"Please use runtime APIs to add canvas sources, rather than including them in stylesheets.","source.canvas")];default:return Mm({key:`${r}.type`,value:t.type,valueSpec:{values:["vector","raster","raster-dem","geojson","video","image"]}})}}function iTe({key:e,value:t}){if(vt(t)==="string")return cu({key:e,value:t});{let r=[];for(let i in t)r.push(...cu({key:`${e}.${i}`,value:t[i]}));return r}}function jO(e){let t=e.value,r=e.styleSpec,i=r.light,n=e.style,a=[],s=vt(t);if(t===void 0)return a;if(s!=="object")return a=a.concat([new Te("light",t,`object expected, ${s} found`)]),a;for(let o in t){let l=o.match(/^(.*)-transition$/);a=l&&i[l[1]]&&i[l[1]].transition?a.concat(e.validateSpec({key:o,value:t[o],valueSpec:r.transition,validateSpec:e.validateSpec,style:n,styleSpec:r})):i[o]?a.concat(e.validateSpec({key:o,value:t[o],valueSpec:i[o],validateSpec:e.validateSpec,style:n,styleSpec:r})):a.concat([new Te(o,t[o],`unknown property "${o}"`)])}return a}function UO(e){let t=e.value,r=e.styleSpec,i=r.sky,n=e.style,a=vt(t);if(t===void 0)return[];if(a!=="object")return[new Te("sky",t,`object expected, ${a} found`)];let s=[];for(let o in t)s=i[o]?s.concat(e.validateSpec({key:o,value:t[o],valueSpec:i[o],style:n,styleSpec:r})):s.concat([new Te(o,t[o],`unknown property "${o}"`)]);return s}function VO(e){let t=e.value,r=e.styleSpec,i=r.terrain,n=e.style,a=[],s=vt(t);if(t===void 0)return a;if(s!=="object")return a=a.concat([new Te("terrain",t,`object expected, ${s} found`)]),a;for(let o in t)a=i[o]?a.concat(e.validateSpec({key:o,value:t[o],valueSpec:i[o],validateSpec:e.validateSpec,style:n,styleSpec:r})):a.concat([new Te(o,t[o],`unknown property "${o}"`)]);return a}function nTe(e){return cu(e).length===0?[]:Rh(e)}function aTe(e){return cu(e).length===0?[]:Rh(e)}function sTe(e){let t=e.key,r=e.value;if(vt(r)==="array"){if(r.length<1||r.length>4)return[new Te(t,r,`padding requires 1 to 4 values; ${r.length} values found`)];let i={type:"number"},n=[];for(let a=0;a<r.length;a++)n=n.concat(e.validateSpec({key:`${t}[${a}]`,value:r[a],validateSpec:e.validateSpec,valueSpec:i}));return n}return av({key:t,value:r,valueSpec:{}})}function oTe(e){let t=e.key,r=e.value;if(vt(r)==="array"){let i={type:"number"};if(r.length<1)return[new Te(t,r,"array length at least 1 expected, length 0 found")];let n=[];for(let a=0;a<r.length;a++)n=n.concat(e.validateSpec({key:`${t}[${a}]`,value:r[a],validateSpec:e.validateSpec,valueSpec:i}));return n}return av({key:t,value:r,valueSpec:{}})}function lTe(e){let t=e.key,r=e.value;if(vt(r)==="array"){if(r.length<1)return[new Te(t,r,"array length at least 1 expected, length 0 found")];let i=[];for(let n=0;n<r.length;n++)i=i.concat(rw({key:`${t}[${n}]`,value:r[n]}));return i}return rw({key:t,value:r})}function uTe(e){let t=e.key,r=e.value,i=vt(r),n=e.styleSpec;if(i!=="array"||r.length<1||r.length%2!=0)return[new Te(t,r,"variableAnchorOffsetCollection requires a non-empty array of even length")];let a=[];for(let s=0;s<r.length;s+=2)a=a.concat(Mm({key:`${t}[${s}]`,value:r[s],valueSpec:n.layout_symbol["text-anchor"]})),a=a.concat(K$({key:`${t}[${s+1}]`,value:r[s+1],valueSpec:{length:2,value:"number"},validateSpec:e.validateSpec,style:e.style,styleSpec:n}));return a}function qO(e){let t=[],r=e.value,i=e.key;if(Array.isArray(r)){let n=[],a=[];for(let s in r)r[s].id&&n.includes(r[s].id)&&t.push(new Te(i,r,`all the sprites' ids must be unique, but ${r[s].id} is duplicated`)),n.push(r[s].id),r[s].url&&a.includes(r[s].url)&&t.push(new Te(i,r,`all the sprites' URLs must be unique, but ${r[s].url} is duplicated`)),a.push(r[s].url),t=t.concat(va({key:`${i}[${s}]`,value:r[s],valueSpec:{id:{type:"string",required:!0},url:{type:"string",required:!0}},validateSpec:e.validateSpec}));return t}return cu({key:i,value:r})}function cTe(e){let t=e.value,r=e.styleSpec,i=r.projection,n=e.style,a=vt(t);if(t===void 0)return[];if(a!=="object")return[new Te("projection",t,`object expected, ${a} found`)];let s=[];for(let o in t)s=i[o]?s.concat(e.validateSpec({key:o,value:t[o],valueSpec:i[o],style:n,styleSpec:r})):s.concat([new Te(o,t[o],`unknown property "${o}"`)]);return s}function dTe(e){let t=e.key,r=e.value;r=r instanceof String?r.valueOf():r;let i=vt(r);return i==="array"&&!fTe(r)&&!hTe(r)?[new Te(t,r,`projection expected, invalid array ${JSON.stringify(r)} found`)]:["array","string"].includes(i)?[]:[new Te(t,r,`projection expected, invalid type "${i}" found`)]}function hTe(e){return!!["interpolate","step","literal"].includes(e[0])}function fTe(e){return Array.isArray(e)&&e.length===3&&typeof e[0]=="string"&&typeof e[1]=="string"&&typeof e[2]=="number"}function GO(e){return!!e&&e.constructor===Object}function HO(e){return GO(e.value)?[]:[new Te(e.key,e.value,`object expected, ${vt(e.value)} found`)]}function pTe(e){let t=e.key,r=e.value,i=e.validateSpec,n=e.styleSpec,a=e.style;if(!GO(r))return[new Te(t,r,`object expected, ${vt(r)} found`)];let s=[];for(let o in r){let l=r[o],u=vt(l);if(u==="string")s.push(...cu({key:`${t}.${o}`,value:l}));else if(u==="array"){let c={url:{type:"string",required:!0}
vendor: 4,258 bytes, line 741
741,"unicode-range":{type:"array",value:"string"}};for(let[d,h]of l.entries())s.push(...va({key:`${t}.${o}[${d}]`,value:h,valueSpec:c,styleSpec:n,style:a,validateSpec:i}))}else s.push(new Te(`${t}.${o}`,l,`string or array expected, ${u} found`))}return s}const t8={"*"(){return[]},array:K$,boolean:Q5e,number:av,color:rw,constants:DO,enum:Mm,filter:X$,function:RO,layer:NO,object:va,source:BO,light:jO,sky:UO,terrain:VO,projection:cTe,projectionDefinition:dTe,string:cu,formatted:nTe,resolvedImage:aTe,padding:sTe,numberArray:oTe,colorArray:lTe,variableAnchorOffsetCollection:uTe,sprite:qO,state:HO,fontFaces:pTe};function Ay(e){let t=e.value,r=e.valueSpec,i=e.styleSpec;return e.validateSpec=Ay,r.expression&&rv(Vr(t))?RO(e):r.expression&&iv(Tc(t))?Rh(e):r.type&&t8[r.type]?t8[r.type](e):va(km({},e,{valueSpec:r.type?i[r.type]:r}))}function YO(e){let t=e.value,r=e.key,i=cu(e);return i.length||(t.indexOf("{fontstack}")===-1&&i.push(new Te(r,t,'"glyphs" url must include a "{fontstack}" token')),t.indexOf("{range}")===-1&&i.push(new Te(r,t,'"glyphs" url must include a "{range}" token'))),i}function Da(e,t=ce){let r=[];return r=r.concat(Ay({key:"",value:e,valueSpec:t.$root,styleSpec:t,style:e,validateSpec:Ay,objectElementValidators:{glyphs:YO,"*"(){return[]}}})),e.constants&&(r=r.concat(DO({key:"constants",value:e.constants}))),WO(r)}Da.source=ds(cs(BO)),Da.sprite=ds(cs(qO)),Da.glyphs=ds(cs(YO)),Da.light=ds(cs(jO)),Da.sky=ds(cs(UO)),Da.terrain=ds(cs(VO)),Da.state=ds(cs(HO)),Da.layer=ds(cs(NO)),Da.filter=ds(cs(X$)),Da.paintProperty=ds(cs(FO)),Da.layoutProperty=ds(cs(zO));function cs(e){return function(t){return e(Object.assign({},t,{validateSpec:Ay}))}}function WO(e){return[].concat(e).sort((t,r)=>t.line-r.line)}function ds(e){return function(...t){return WO(e.apply(this,t))}}const mTe={type:"enum","property-type":"data-constant",expression:{interpolated:!1,parameters:["global-state"]},values:{visible:{},none:{}},transition:!1,default:"visible"};var gTe=class{constructor(t,r,i){this._rootKey=r,this._globalState=i,this.setValue(t)}evaluate(){return this._literalValue??this._compiledValue.evaluate({})}setValue(t){if(t==null||t==="visible"||t==="none"){this._literalValue=t==="none"?"none":"visible",this._compiledValue=void 0,this._globalStateRefs=new Set;return}let r=nv(t,this._rootKey,mTe,this._globalState);if(r.result==="error")throw this._literalValue="visible",this._compiledValue=void 0,Error(r.value.map(i=>`${i.key}: ${i.message}`).join(", "));this._literalValue=void 0,this._compiledValue=r.value,this._globalStateRefs=mg(r.value.expression)}getGlobalStateRefs(){return this._globalStateRefs}};function _Te(e,t,r){return new gTe(e,t,r)}const Nn=Da,ZO=new Set(Object.keys(ce).filter(e=>e.startsWith("source_")).map(e=>e.slice(7).replaceAll("_","-")));function yTe(e){return Object.entries(e.sources??{}).filter(([,t])=>!ZO.has(t.type)).map(([t])=>`sources.${t}`)}function r8(e,t){let r=yTe(t);return J$(e,Nn(t).filter(({message:i})=>!r.some(n=>i.startsWith(`${n}:`)||i.startsWith(`${n}.`))))}function J$(e,t){let r=!1;for(let i of t){if(i.severity==="warning"){vr(i.message);continue}e.fire(new He(Error(i.message))),r=!0}return r}function gg(e,t,r,i){return(i==null?void 0:i.validate)!==!1&&J$(e,t({styleSpec:ce,...r}))}var iw=class KO{constructor(t,r,i){let n=this.cells=[];if(t instanceof ArrayBuffer){this.arrayBuffer=t;let s=new Int32Array(this.arrayBuffer);t=s[0],r=s[1],i=s[2],this.d=r+2*i;for(let u=0;u<this.d*this.d;u++){let c=s[3+u],d=s[3+u+1];n.push(c===d?null:s.subarray(c,d))}let o=s[3+n.length],l=s[3+n.length+1];this.keys=s.subarray(o,l),this.bboxes=s.subarray(l),this.insert=this._insertReadonly}else{this.d=r+2*i;for(let s=0;s<this.d*this.d;s++)n.push([]);this.keys=[],this.bboxes=[]}this.n=r,this.extent=t,this.padding=i,this.scale=r/t,this.uid=0;let a=i/r*t;this.min=-a,this.max=t+a}insert(t,r,i,n,a){this._forEachCell(r,i,n,a,this._insertCell,this.uid++,void 0,void 0),this.keys.push(t),this.bboxes.push(r),this.bboxes.push(i),this.bboxes.push(n),this.bboxes.push(a)}_insertReadonly(){throw Error("Cannot insert into a GridIndex created from an ArrayBuffer.")}_insertCell(t,r,i,n,a,s){this.cells[a].push(s)}query(t,r,i,n,a){let s=this.min,o=this.max;if(t<=s&&r<=s&&o<=i&&o<=n&&!a)return[...this.keys];{let l=[];
vendor: 8,230 bytes, line 741
741return this._forEachCell(t,r,i,n,this._queryCell,l,{},a),l}}_queryCell(t,r,i,n,a,s,o,l){let u=this.cells[a];if(u!==null){let c=this.keys,d=this.bboxes;for(let h of u)if(o[h]===void 0){let f=h*4;(l?l(d[f+0],d[f+1],d[f+2],d[f+3]):t<=d[f+2]&&r<=d[f+3]&&i>=d[f+0]&&n>=d[f+1])?(o[h]=!0,s.push(c[h])):o[h]=!1}}}_forEachCell(t,r,i,n,a,s,o,l){let u=this._convertToCellCoord(t),c=this._convertToCellCoord(r),d=this._convertToCellCoord(i),h=this._convertToCellCoord(n);for(let f=u;f<=d;f++)for(let p=c;p<=h;p++){let m=this.d*p+f;if(!(l&&!l(this._convertFromCellCoord(f),this._convertFromCellCoord(p),this._convertFromCellCoord(f+1),this._convertFromCellCoord(p+1)))&&a.call(this,t,r,i,n,m,s,o,l))return}}_convertFromCellCoord(t){return(t-this.padding)/this.scale}_convertToCellCoord(t){return Math.max(0,Math.min(this.d-1,Math.floor(t*this.scale)+this.padding))}toArrayBuffer(){if(this.arrayBuffer)return this.arrayBuffer;let t=this.cells,r=3+this.cells.length+1+1,i=0;for(let s of this.cells)i+=s.length;let n=new Int32Array(r+i+this.keys.length+this.bboxes.length);n[0]=this.extent,n[1]=this.n,n[2]=this.padding;let a=r;for(let s=0;s<t.length;s++){let o=t[s];n[3+s]=a,n.set(o,a),a+=o.length}return n[3+t.length]=a,n.set(this.keys,a),a+=this.keys.length,n[3+t.length+1]=a,n.set(this.bboxes,a),a+=this.bboxes.length,n.buffer}static serialize(t,r){let i=t.toArrayBuffer();return r&&r.push(i),{buffer:i}}static deserialize(t){return new KO(t.buffer)}};const Fo={};function Ae(e,t,r={}){if(Fo[e])throw Error(`${e} is already registered.`);Object.defineProperty(t,"_classRegistryKey",{value:e,writeable:!1}),Fo[e]={klass:t,omit:r.omit||[],shallow:r.shallow||[]}}Ae("Object",Object),Ae("Set",Set),Ae("TransferableGridIndex",iw),Ae("Color",at),Ae("Error",Error),Ae("AJAXError",Ty),Ae("ResolvedImage",uo),Ae("StylePropertyFunction",kO),Ae("StyleExpression",Y$,{omit:["_evaluator"]}),Ae("ZoomDependentExpression",My),Ae("ZoomConstantExpression",Em),Ae("CompoundExpression",zc,{omit:["_evaluate"]});for(let e in Kd)Kd[e]._classRegistryKey||Ae(`Expression_${e}`,Kd[e]);function XO(e){var t;return e&&typeof ArrayBuffer<"u"&&(e instanceof ArrayBuffer||((t=e.constructor)==null?void 0:t.name)==="ArrayBuffer")}function Q$(e){let t=e.constructor;return e.$name||t._classRegistryKey}function vTe(e){if(typeof e!="object"||!e)return!1;let t=Q$(e);return t&&t!=="Object"}function JO(e){return!vTe(e)&&(e==null||typeof e=="boolean"||typeof e=="number"||typeof e=="string"||e instanceof Boolean||e instanceof Number||e instanceof String||e instanceof Date||e instanceof RegExp||e instanceof Blob||e instanceof Error||XO(e)||uc(e)||ArrayBuffer.isView(e)||e instanceof ImageData)}function Ip(e,t){if(JO(e))return(XO(e)||uc(e))&&t&&t.push(e),ArrayBuffer.isView(e)&&t&&t.push(e.buffer),e instanceof ImageData&&t&&t.push(e.data.buffer),e;if(Array.isArray(e)){let a=[];for(let s of e)a.push(Ip(s,t));return a}if(typeof e!="object")throw Error(`can't serialize object of type ${typeof e}`);let r=Q$(e);if(!r)throw Error(`can't serialize object of unregistered class ${e.constructor.name}`);if(!Fo[r])throw Error(`${r} is not registered.`);let{klass:i}=Fo[r],n=i.serialize?i.serialize(e,t):{};if(i.serialize){if(n===(t==null?void 0:t[t.length-1]))throw Error("statically serialized object won't survive transfer of $name property")}else{for(let a in e){if(!e.hasOwnProperty(a)||Fo[r].omit.includes(a))continue;let s=e[a];s!==void 0&&(n[a]=Fo[r].shallow.includes(a)?s:Ip(s,t))}e instanceof Error&&(n.message=e.message)}if(n.$name)throw Error("$name property is reserved for worker serialization logic.");return r!=="Object"&&(n.$name=r),n}function Ap(e){if(JO(e))return e;if(Array.isArray(e))return e.map(Ap);if(typeof e!="object")throw Error(`can't deserialize object of type ${typeof e}`);let t=Q$(e)||"Object";if(!Fo[t])throw Error(`can't deserialize unregistered class ${t}`);let{klass:r}=Fo[t];if(!r)throw Error(`can't deserialize unregistered class ${t}`);if(r.deserialize)return r.deserialize(e);let i=Object.create(r.prototype);for(let n of Object.keys(e)){if(n==="$name")continue;let a=e[n];i[n]=Fo[t].shallow.includes(n)?a:Ap(a)}return i}var nw=class{constructor(){this.first=!0}update(t,r){let i=Math.floor(t);return this.first?(this.first=!1,this.lastIntegerZoom=i,this.lastIntegerZoomTime=0,this.lastZoom=t,this.lastFloorZoom=i,!0):(this.lastFloorZoom>i?(this.lastIntegerZoom=i+1,this.lastIntegerZoomTime=r):this.lastFloorZoom<i&&(this.lastIntegerZoom=i,this.lastIntegerZoomTime=r),t!==this.lastZoom&&(this.lastZoom=t,this.lastFloorZoom=i,!0))}};function bTe(e){return/[\u02EA\u02EB\u1100-\u11FF\u2E80-\u2FDF\u3000-\u30FF\u3105-\u312F\u3131-\u318E\u31A0-\u4DBF\u4E00-\uA48C\uA490-\uA4C6\uA960-\uA97C\uAC00-\uD7C6\uD7CB-\uD7FB\uF900-\uFA6D\uFA70-\uFAD9\uFE10-\uFE1F\uFE30-\uFE4F\uFF00-\uFFEF]|\uD81B[\uDFE0-\uDFFF]|[\uD81C-\uD822\uD840-\uD868\uD86A-\uD86D\uD86F-\uD872\uD874-\uD879\uD880-\uD883\uD885-\uD88C][\uDC00-\uDFFF]|\uD823[\uDC00-\uDCD5\uDCFF-\uDD1E\uDD80-\uDDF2]|\uD82B[\uDFF0-\uDFFF]|\uD82C[\uDC00-\uDEFB]|\uD83C[\uDE00-\uDEFF]|\uD869[\uDC00-\uDEDF\uDF00-\uDFFF]|\uD86E[\uDC00-\uDC1D\uDC20-\uDFFF]|\uD873[\uDC00-\uDEAD\uDEB0-\uDFFF]|\uD87A[\uDC00-\uDFE0\uDFF0-\uDFFF]|\uD87B[\uDC00-\uDE5D]|\uD87E[\uDC00-\uDE1D]|\uD884[\uDC00-\uDF4A\uDF50-\uDFFF]|\uD88D[\uDC00-\uDC79]/gim.test(String.fromCodePoint(e))}function xTe(e){return/[\u02EA\u02EB\u1100-\u11FF\u1400-\u167F\u18B0-\u18F5\u2E80-\u2E99\u2E9B-\u2EF3\u2F00-\u2FD5\u2FF0-\u3007\u3012\u3013\u3020-\u302F\u3031-\u303F\u3041-\u3096\u309D-\u30FB\u30FD-\u30FF\u3105-\u312F\u3131-\u318E\u3190-\uA48C\uA490-\uA4C6\uA960-\uA97C\uAC00-\uD7A3\uD7B0-\uD7C6\uD7CB-\uD7FB\uF900-\uFA6D\uFA70-\uFAD9\uFE10-\uFE1F\uFE30-\uFE48\uFE50-\uFE57\uFE5F-\uFE62\uFE67-\uFE6F\uFF00-\uFF07\uFF0A-\uFF0C\uFF0E-\uFF19\uFF1F-\uFF3A\uFF3C\uFF3E\uFF40-\uFF5A\uFFE0-\uFFE2\uFFE4-\uFFE7]|\uD802[\uDD80-\uDD9F]|\uD805[\uDD80-\uDDFF]|\uD806[\uDE00-\uDEBF]|\uD811[\uDC00-\uDE7F]|\uD81B[\uDFE0-\uDFE4\uDFF0-\uDFF6]|[\uD81C-\uD822\uD83D\uD840-\uD868\uD86A-\uD86D\uD86F-\uD872\uD874-\uD879\uD880-\uD883\uD885-\uD88C][\uDC00-\uDFFF]|\uD823[\uDC00-\uDCD5\uDCFF-\uDD1E\uDD80-\uDDF2]|\uD82B[\uDFF0-\uDFF3\uDFF5-\uDFFB\uDFFD\uDFFE]|\uD82C[\uDC00-\uDD22\uDD30-\uDEFB]|\uD833[\uDEC0-\uDFCF]|\uD834[\uDC00-\uDDFF\uDEE0-\uDF7F]|\uD836[\uDC00-\uDEAF]|\uD83C[\uDC00-\uDE00\uDF00-\uDFFF]|\uD83E[\uDD00-\uDEFF]|\uD869[\uDC00-\uDEDF\uDF00-\uDFFF]|\uD86E[\uDC00-\uDC1D\uDC20-\uDFFF]|\uD873[\uDC00-\uDEAD\uDEB0-\uDFFF]|\uD87A[\uDC00-\uDFE0\uDFF0-\uDFFF]|\uD87B[\uDC00-\uDE5D]|\uD87E[\uDC00-\uDE1D]|\uD884[\uDC00-\uDF4A\uDF50-\uDFFF]|\uD88D[\uDC00-\uDC79]/gim.test(String.fromCodePoint(e))}function wTe(e){return/[\u0900-\u0DFF\u0F00-\u109F\u1780-\u17FF]/gim.test(String.fromCodePoint(e))}function $Te(e){for(let t of e)if(xTe(t.codePointAt(0)))return!0;return!1}function QO(e){let t=e.map(r=>{try{return RegExp(`\\p{sc=${r}}`,"u").source}catch{return null}}).filter(r=>r);return new RegExp(t.join("|"),"u")}QO(["Arab","Dupl","Mong","Ougr","Syrc"]);const STe=QO("Adlm.Arab.Armi.Avst.Chrs.Cprt.Egyp.Elym.Gara.Hatr.Hebr.Hung.Khar.Lydi.Mand.Mani.Mend.Merc.Mero.Narb.Nbat.Nkoo.Orkh.Palm.Phli.Phlp.Phnx.Prti.Rohg.Samr.Sarb.Sogo.Syrc.Thaa.Todr.Yezi".split("."));function eL(e){return STe.test(String.fromCodePoint(e))}function TTe(e,t){return!t&&eL(e)?!1:!wTe(e)}function CTe(e){for(let t of e)if(eL(t.codePointAt(0)))return!0;return!1}function kTe(e,t){for(let r of e)if(!TTe(r.codePointAt(0),t))return!1;return!0}const Oh=new class{constructor(){this.TIMEOUT=5e3,this.applyArabicShaping=null,this.processBidirectionalText=null,this.processStyledBidirectionalText=null,this.pluginStatus="unavailable",this.pluginURL=null,this.loadScriptResolve=()=>{}}setState(e){this.pluginStatus=e.pluginStatus,this.pluginURL=e.pluginURL}getState(){return{pluginStatus:this.pluginStatus,pluginURL:this.pluginURL}}setMethods(e){if(Oh.isParsed())throw Error("RTL text plugin already registered.");this.applyArabicShaping=e.applyArabicShaping,this.processBidirectionalText=e.processBidirectionalText,this.processStyledBidirectionalText=e.processStyledBidirectionalText,this.loadScriptResolve()}isParsed(){return this.applyArabicShaping!=null&&this.processBidirectionalText!=null&&this.processStyledBidirectionalText!=null}getRTLTextPluginStatus(){return this.pluginStatus}
vendor: 7,209 bytes, line 741
741async syncState(e,t){if(this.isParsed())return this.getState();if(e.pluginStatus!=="loading")return this.setState(e),e;let r=e.pluginURL,i=new Promise(a=>{this.loadScriptResolve=a}),n=new Promise(a=>setTimeout(()=>a(),this.TIMEOUT));if(await t(r),await Promise.race([i,n]),this.isParsed()){let a={pluginStatus:"loaded",pluginURL:r};return this.setState(a),a}throw this.setState({pluginStatus:"error",pluginURL:""}),Error(`RTL Text Plugin failed to import scripts from ${r}`)}};var Tr=class{constructor(t,r){this.isSupportedScript=ETe,this.zoom=t,r?(this.now=r.now||0,this.fadeDuration=r.fadeDuration||0,this.zoomHistory=r.zoomHistory||new nw,this.transition=r.transition||{}):(this.now=0,this.fadeDuration=0,this.zoomHistory=new nw,this.transition={})}crossFadingFactor(){return this.fadeDuration===0?1:Math.min((this.now-this.zoomHistory.lastIntegerZoomTime)/this.fadeDuration,1)}getCrossfadeParameters(){let t=this.zoom,r=t-Math.floor(t),i=this.crossFadingFactor();return t>this.zoomHistory.lastIntegerZoom?{fromScale:2,toScale:1,t:r+(1-r)*i}:{fromScale:.5,toScale:1,t:1-(1-i)*r}}};function ETe(e){return kTe(e,Oh.getRTLTextPluginStatus()==="loaded")}const eS="-transition";var sv=class{constructor(t,r,i,n){this.property=t,this.value=r,this.expression=q5e(r===void 0?t.specification.default:r,i,t.specification,n)}isDataDriven(){return this.expression.kind==="source"||this.expression.kind==="composite"}getGlobalStateRefs(){return this.expression.globalStateRefs||new Set}possiblyEvaluate(t,r,i){return this.property.possiblyEvaluate(this,t,r,i)}},aw=class{constructor(t,r,i){this.property=t,this.value=new sv(t,void 0,r,i)}transitioned(t,r){return new i8(this.property,this.value,r,Ne({},t.transition,this.transition),t.now)}untransitioned(){return new i8(this.property,this.value,null,{},0)}},ov=class{constructor(t,r,i){this._properties=t,this._values=Object.create(t.defaultTransitionablePropertyValues),this._globalState=i,this._rootKey=r}_propertyRootKey(t){return`${this._rootKey}.${String(t)}`}hasProperty(t){return t in this._properties.defaultTransitionablePropertyValues}getValue(t){return jn(this._values[t].value.value)}setValue(t,r){Object.hasOwn(this._values,t)||(this._values[t]=new aw(this._values[t].property,this._propertyRootKey(t),this._globalState)),this._values[t].value=new sv(this._values[t].property,r===null?void 0:jn(r),this._propertyRootKey(t),this._globalState)}getTransition(t){return jn(this._values[t].transition)}setTransition(t,r){Object.hasOwn(this._values,t)||(this._values[t]=new aw(this._values[t].property,this._propertyRootKey(t),this._globalState)),this._values[t].transition=jn(r)||void 0}serialize(){let t={};for(let r of Object.keys(this._values)){let i=this.getValue(r);i!==void 0&&(t[r]=i);let n=this.getTransition(r);n!==void 0&&(t[`${r}${eS}`]=n)}return t}transitioned(t,r){let i=new n8(this._properties);for(let n of Object.keys(this._values))i._values[n]=this._values[n].transitioned(t,r._values[n]);return i}untransitioned(){let t=new n8(this._properties);for(let r of Object.keys(this._values))t._values[r]=this._values[r].untransitioned();return t}},i8=class{constructor(t,r,i,n,a){this.property=t,this.value=r,this.begin=a+n.delay||0,this.end=this.begin+n.duration||0,t.specification.transition&&(n.delay||n.duration)&&(this.prior=i)}possiblyEvaluate(t,r,i){let n=t.now||0,a=this.value.possiblyEvaluate(t,r,i),s=this.prior;if(!s)return a;if(n>this.end||this.value.isDataDriven())return this.prior=null,a;if(n<this.begin)return s.possiblyEvaluate(t,r,i);{let o=(n-this.begin)/(this.end-this.begin);return this.property.interpolate(s.possiblyEvaluate(t,r,i),a,H$e(o))}}},n8=class{constructor(t){this._properties=t,this._values=Object.create(t.defaultTransitioningPropertyValues)}possiblyEvaluate(t,r,i){let n=new lv(this._properties);for(let a of Object.keys(this._values))n._values[a]=this._values[a].possiblyEvaluate(t,r,i);return n}hasTransition(){for(let t of Object.keys(this._values))if(this._values[t].prior)return!0;return!1}},PTe=class{constructor(t,r,i){this._properties=t,this._values=Object.create(t.defaultPropertyValues),this._globalState=i,this._rootKey=r}_propertyRootKey(t){return`${this._rootKey}.${String(t)}`}hasValue(t){return this._values[t].value!==void 0}hasProperty(t){return t in this._properties.defaultPropertyValues}getValue(t){return jn(this._values[t].value)}setValue(t,r){this._values[t]=new sv(this._values[t].property,r===null?void 0:jn(r),this._propertyRootKey(t),this._globalState)}serialize(){let t={};for(let r of Object.keys(this._values)){let i=this.getValue(r);i!==void 0&&(t[r]=i)}return t}possiblyEvaluate(t,r,i){let n=new lv(this._properties);for(let a of Object.keys(this._values))n._values[a]=this._values[a].possiblyEvaluate(t,r,i);return n}},vs=class{constructor(t,r,i){this.property=t,this.value=r,this.parameters=i}isConstant(){return this.value.kind==="constant"}constantOr(t){return this.value.kind==="constant"?this.value.value:t}evaluate(t,r,i,n){return this.property.evaluate(this.value,this.parameters,t,r,i,n)}},lv=class{constructor(t){this._properties=t,this._values=Object.create(t.defaultPossiblyEvaluatedValues)}get(t){return this._values[t]}};function a8(e){if(Array.isArray(e))return e.length;let t=e==null?void 0:e.values;return Array.isArray(t)?t.length:void 0}function tL(e,t){let r=a8(e),i=a8(t);return r!==void 0&&i!==void 0&&r!==i}var Pe=class{constructor(t,r){this.specification=t,this.name=r}possiblyEvaluate(t,r){if(t.isDataDriven())throw Error("Value should not be data driven");return t.expression.evaluate(r)}interpolate(t,r,i){if(tL(t,r))return vr(`Property "${this.name}" is trying to interpolate arrays of different lengths. Rendering may 'jump'.`),r;let n=this.specification.type,a=ai[n];return a?a(t,r,i):t}},Ye=class{constructor(t,r,i){this.specification=t,this.name=r,this.overrides=i}possiblyEvaluate(t,r,i,n){return t.expression.kind==="constant"||t.expression.kind==="camera"?new vs(this,{kind:"constant",value:t.expression.evaluate(r,null,{},i,n)},r):new vs(this,t.expression,r)}interpolate(t,r,i){if(t.value.kind!=="constant"||r.value.kind!=="constant")return t;if(t.value.value===void 0||r.value.value===void 0)return new vs(this,{kind:"constant",value:void 0},t.parameters);if(tL(t.value.value,r.value.value))return vr(`Property "${this.name}" is trying to interpolate arrays of different lengths. Rendering may 'jump'.`),r;let n=this.specification.type,a=ai[n];if(a){let s=a(t.value.value,r.value.value,i);return new vs(this,{kind:"constant",value:s},t.parameters)}return t}evaluate(t,r,i,n,a,s){return t.kind==="constant"?t.value:t.evaluate(r,i,n,a,s)}},Im=class extends Ye{possiblyEvaluate(t,r,i,n){if(t.value===void 0)return new vs(this,{kind:"constant",value:void 0},r);if(t.expression.kind==="constant"){let a=t.expression.evaluate(r,null,{},i,n),s=t.property.specification.type==="resolvedImage"&&typeof a!="string"?a.name:a,o=this._calculate(s,s,s,r);return new vs(this,{kind:"constant",value:o},r)}if(t.expression.kind==="camera"){let a=this._calculate(t.expression.evaluate({zoom:r.zoom-1}),t.expression.evaluate({zoom:r.zoom}),t.expression.evaluate({zoom:r.zoom+1}),r);return new vs(this,{kind:"constant",value:a},r)}return new vs(this,t.expression,r)}
vendor: 6,374 bytes, line 741
741evaluate(t,r,i,n,a,s){if(t.kind==="source"){let o=t.evaluate(r,i,n,a,s);return this._calculate(o,o,o,r)}return t.kind==="composite"?this._calculate(t.evaluate({zoom:Math.floor(r.zoom)-1},i,n),t.evaluate({zoom:Math.floor(r.zoom)},i,n),t.evaluate({zoom:Math.floor(r.zoom)+1},i,n),r):t.value}_calculate(t,r,i,n){return n.zoom>n.zoomHistory.lastIntegerZoom?{from:t,to:r}:{from:i,to:r}}interpolate(t){return t}},rL=class{constructor(t,r){this.specification=t,this.name=r}possiblyEvaluate(t,r,i,n){if(t.value!==void 0){if(t.expression.kind==="constant"){let a=t.expression.evaluate(r,null,{},i,n);return this._calculate(a,a,a,r)}return this._calculate(t.expression.evaluate(new Tr(Math.floor(r.zoom-1),r)),t.expression.evaluate(new Tr(Math.floor(r.zoom),r)),t.expression.evaluate(new Tr(Math.floor(r.zoom+1),r)),r)}}_calculate(t,r,i,n){return n.zoom>n.zoomHistory.lastIntegerZoom?{from:t,to:r}:{from:i,to:r}}interpolate(t){return t}},uv=class{constructor(t,r){this.specification=t,this.name=r}possiblyEvaluate(t,r,i,n){return!!t.expression.evaluate(r,null,{},i,n)}interpolate(){return!1}},Mi=class{constructor(t){this.properties=t,this.defaultPropertyValues={},this.defaultTransitionablePropertyValues={},this.defaultTransitioningPropertyValues={},this.defaultPossiblyEvaluatedValues={},this.overridableProperties=[];for(let r in t){let i=t[r];i.specification.overridable&&this.overridableProperties.push(r);let n=this.defaultPropertyValues[r]=new sv(i,void 0,i.name,void 0),a=this.defaultTransitionablePropertyValues[r]=new aw(i,i.name,void 0);this.defaultTransitioningPropertyValues[r]=a.untransitioned(),this.defaultPossiblyEvaluatedValues[r]=n.possiblyEvaluate({})}}};Ae("DataDrivenProperty",Ye),Ae("DataConstantProperty",Pe),Ae("CrossFadedDataDrivenProperty",Im),Ae("CrossFadedProperty",rL),Ae("ColorRampProperty",uv);const s8=" is a PAINT property not a LAYOUT property. Use get/setPaintProperty instead?",Ab=" is a LAYOUT property not a PAINT property. Use get/setLayoutProperty instead?";var Rs=class extends Rn{constructor(t,r,i){if(super(),this.id=t.id,this.type=t.type,this._globalState=i,this._featureFilter={filter:()=>!0,needGeometry:!1,getGlobalStateRefs:()=>new Set},this._visibilityExpression=_Te(this.visibility,`layers[${this.id}].layout.visibility`,i),t.type!=="custom"&&(this.metadata=t.metadata,this.minzoom=t.minzoom,this.maxzoom=t.maxzoom,t.type!=="background"&&(this.source=t.source,this.sourceLayer=t["source-layer"],this.filter=t.filter,this._featureFilter=Pm(t.filter,`layers[${this.id}].filter`,i)),r.layout&&(this._unevaluatedLayout=new PTe(r.layout,`layers[${this.id}].layout`,i)),r.paint)){this._transitionablePaint=new ov(r.paint,`layers[${this.id}].paint`,i);for(let n in t.paint)this.setPaintProperty(n,t.paint[n],{validate:!1});for(let n in t.layout)this.setLayoutProperty(n,t.layout[n],{validate:!1});this._transitioningPaint=this._transitionablePaint.untransitioned(),this.paint=new lv(r.paint)}}setFilter(t){this.filter=t,this._featureFilter=Pm(t,`layers[${this.id}].filter`,this._globalState)}getCrossfadeParameters(){return this._crossfadeParameters}getLayoutProperty(t){var r;if(t==="visibility")return this.visibility;if((r=this._transitionablePaint)!=null&&r.hasProperty(t))throw Error(t+s8);if(!this._unevaluatedLayout)throw Error(`Cannot get layout property "${t}" on layer type "${this.type}" which has no layout properties.`);return this._unevaluatedLayout.getValue(t)}getLayoutAffectingGlobalStateRefs(){let t=new Set;for(let r of this._visibilityExpression.getGlobalStateRefs())t.add(r);if(this._unevaluatedLayout)for(let r in this._unevaluatedLayout._values){let i=this._unevaluatedLayout._values[r];for(let n of i.getGlobalStateRefs())t.add(n)}for(let r of this._featureFilter.getGlobalStateRefs())t.add(r);return t}getPaintAffectingGlobalStateRefs(){let t=new globalThis.Map;if(this._transitionablePaint)for(let r in this._transitionablePaint._values){let i=this._transitionablePaint._values[r].value;for(let n of i.getGlobalStateRefs()){let a=t.get(n)??[];a.push({name:r,value:i.value}),t.set(n,a)}}return t}getVisibilityAffectingGlobalStateRefs(){return this._visibilityExpression.getGlobalStateRefs()}setLayoutProperty(t,r,i={}){var n;if(t==="visibility"){this.visibility=r,this._visibilityExpression.setValue(r),this.recalculateVisibility();return}if((n=this._transitionablePaint)!=null&&n.hasProperty(t)){this.fire(new He(Error(t+s8)));return}r!=null&&this._validate(Nn.layoutProperty,`layers.${this.id}.layout.${t}`,t,r,i)||this._unevaluatedLayout.setValue(t,r)}getPaintProperty(t){var r,i;if(t.endsWith("-transition")){let n=t.slice(0,-11);if(n==="visibility"||(r=this._unevaluatedLayout)!=null&&r.hasProperty(n))throw Error(t+Ab);return this._transitionablePaint.getTransition(n)}if(t==="visibility"||(i=this._unevaluatedLayout)!=null&&i.hasProperty(t))throw Error(t+Ab);return this._transitionablePaint.getValue(t)}setPaintProperty(t,r,i={}){var n;if(t==="visibility"||(n=this._unevaluatedLayout)!=null&&n.hasProperty(t))return this.fire(new He(Error(t+Ab))),!1;if(r!=null&&this._validate(Nn.paintProperty,`layers.${this.id}.paint.${t}`,t,r,i))return!1;if(t.endsWith("-transition"))return this._transitionablePaint.setTransition(t.slice(0,-11),r||void 0),!1;{let a=this._transitionablePaint._values[t],s=a.property.specification["property-type"]==="cross-faded-data-driven",o=a.value.isDataDriven(),l=a.value;this._transitionablePaint.setValue(t,r),this._handleSpecialPaintPropertyUpdate(t);let u=this._transitionablePaint._values[t].value;return u.isDataDriven()||o||s||this._handleOverridablePaintPropertyUpdate(t,l,u)}}_handleSpecialPaintPropertyUpdate(t){}_handleOverridablePaintPropertyUpdate(t,r,i){return!1}isHidden(t=this.minzoom,r=!1){return this.minzoom&&t<(r?Math.floor(this.minzoom):this.minzoom)||this.maxzoom&&t>=this.maxzoom?!0:this._evaluatedVisibility==="none"}updateTransitions(t){this._transitioningPaint=this._transitionablePaint.transitioned(t,this._transitioningPaint)}hasTransition(){return this._transitioningPaint.hasTransition()}recalculateVisibility(){this._evaluatedVisibility=this._visibilityExpression.evaluate()}recalculate(t,r){t.getCrossfadeParameters&&(this._crossfadeParameters=t.getCrossfadeParameters()),this._unevaluatedLayout&&(this.layout=this._unevaluatedLayout.possiblyEvaluate(t,void 0,r)),this.paint=this._transitioningPaint.possiblyEvaluate(t,void 0,r)}serialize(){var r,i;
vendor: 22,570 bytes, line 741
741let t={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:(r=this._unevaluatedLayout)==null?void 0:r.serialize(),paint:(i=this._transitionablePaint)==null?void 0:i.serialize()};return this.visibility&&(t.layout||(t.layout={}),t.layout.visibility=this.visibility),$R(t,(n,a)=>n!==void 0&&!(a==="layout"&&!Object.keys(n).length)&&!(a==="paint"&&!Object.keys(n).length))}_validate(t,r,i,n,a={}){return gg(this,t,{key:r,layerType:this.type,objectKey:i,value:n},a)}is3D(){return!1}isTileClipped(){return!1}hasOffscreenPass(){return!1}resize(){}isStateDependent(){for(let t in this.paint._values){let r=this.paint.get(t);if(!(!(r instanceof vs)||!Ah(r.property.specification))&&(r.value.kind==="source"||r.value.kind==="composite")&&r.value.isStateDependent)return!0}return!1}};let MTe;const ITe=()=>MTe||(MTe=new Mi({"raster-opacity":new Pe(ce.paint_raster["raster-opacity"],"raster-opacity"),"raster-hue-rotate":new Pe(ce.paint_raster["raster-hue-rotate"],"raster-hue-rotate"),"raster-brightness-min":new Pe(ce.paint_raster["raster-brightness-min"],"raster-brightness-min"),"raster-brightness-max":new Pe(ce.paint_raster["raster-brightness-max"],"raster-brightness-max"),"raster-saturation":new Pe(ce.paint_raster["raster-saturation"],"raster-saturation"),"raster-contrast":new Pe(ce.paint_raster["raster-contrast"],"raster-contrast"),resampling:new Pe(ce.paint_raster.resampling,"resampling"),"raster-resampling":new Pe(ce.paint_raster["raster-resampling"],"raster-resampling"),"raster-fade-duration":new Pe(ce.paint_raster["raster-fade-duration"],"raster-fade-duration")}));var ATe={get paint(){return ITe()}};const sw=e=>e.type==="raster";var DTe=class extends Rs{constructor(t,r){super(t,ATe,r)}};const RTe={Int8:Int8Array,Uint8:Uint8Array,Int16:Int16Array,Uint16:Uint16Array,Int32:Int32Array,Uint32:Uint32Array,Float32:Float32Array};var _g=class{constructor(t,r){this._structArray=t,this._pos1=r*this.size,this._pos2=this._pos1/2,this._pos4=this._pos1/4,this._pos8=this._pos1/8}},Rr=class{constructor(){this.isTransferred=!1,this.capacity=-1,this.resize(0)}static serialize(t,r){return t._trim(),r&&(t.isTransferred=!0,r.push(t.arrayBuffer)),{length:t.length,arrayBuffer:t.arrayBuffer}}static deserialize(t){let r=Object.create(this.prototype);return r.arrayBuffer=t.arrayBuffer,r.length=t.length,r.capacity=t.arrayBuffer.byteLength/r.bytesPerElement,r._refreshViews(),r}_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(t){this.reserve(t),this.length=t}reserve(t){if(t>this.capacity){this.capacity=Math.max(t,Math.floor(this.capacity*5),128),this.arrayBuffer=new ArrayBuffer(this.capacity*this.bytesPerElement);let r=this.uint8;this._refreshViews(),r&&this.uint8.set(r)}}_refreshViews(){throw Error("_refreshViews() must be implemented by each concrete StructArray layout")}freeBufferAfterUpload(){this.arrayBuffer=new ArrayBuffer(0),this._refreshViews()}};function Ar(e,t=1){let r=0,i=0;return{members:e.map(n=>{let a=OTe(n.type),s=r=o8(r,Math.max(t,a)),o=n.components||1;return i=Math.max(i,a),r+=a*o,{name:n.name,type:n.type,components:o,offset:s}}),size:o8(r,Math.max(i,t)),alignment:t}}function OTe(e){return RTe[e].BYTES_PER_ELEMENT}function o8(e,t){return Math.ceil(e/t)*t}var Am=class extends Rr{_refreshViews(){this.uint8=new Uint8Array(this.arrayBuffer),this.int16=new Int16Array(this.arrayBuffer)}emplaceBack(t,r){let i=this.length;return this.resize(i+1),this.emplace(i,t,r)}emplace(t,r,i){let n=t*2;return this.int16[n+0]=r,this.int16[n+1]=i,t}};Am.prototype.bytesPerElement=4,Ae("StructArrayLayout2i4",Am);var Dy=class extends Rr{_refreshViews(){this.uint8=new Uint8Array(this.arrayBuffer),this.int16=new Int16Array(this.arrayBuffer)}emplaceBack(t,r,i){let n=this.length;return this.resize(n+1),this.emplace(n,t,r,i)}emplace(t,r,i,n){let a=t*3;return this.int16[a+0]=r,this.int16[a+1]=i,this.int16[a+2]=n,t}};Dy.prototype.bytesPerElement=6,Ae("StructArrayLayout3i6",Dy);var ow=class extends Rr{_refreshViews(){this.uint8=new Uint8Array(this.arrayBuffer),this.int16=new Int16Array(this.arrayBuffer)}emplaceBack(t,r,i,n){let a=this.length;return this.resize(a+1),this.emplace(a,t,r,i,n)}emplace(t,r,i,n,a){let s=t*4;return this.int16[s+0]=r,this.int16[s+1]=i,this.int16[s+2]=n,this.int16[s+3]=a,t}};ow.prototype.bytesPerElement=8,Ae("StructArrayLayout4i8",ow);var lw=class extends Rr{_refreshViews(){this.uint8=new Uint8Array(this.arrayBuffer),this.int16=new Int16Array(this.arrayBuffer)}emplaceBack(t,r,i,n,a,s){let o=this.length;return this.resize(o+1),this.emplace(o,t,r,i,n,a,s)}emplace(t,r,i,n,a,s,o){let l=t*6;return this.int16[l+0]=r,this.int16[l+1]=i,this.int16[l+2]=n,this.int16[l+3]=a,this.int16[l+4]=s,this.int16[l+5]=o,t}};lw.prototype.bytesPerElement=12,Ae("StructArrayLayout2i4i12",lw);var uw=class extends Rr{_refreshViews(){this.uint8=new Uint8Array(this.arrayBuffer),this.int16=new Int16Array(this.arrayBuffer)}emplaceBack(t,r,i,n,a,s){let o=this.length;return this.resize(o+1),this.emplace(o,t,r,i,n,a,s)}emplace(t,r,i,n,a,s,o){let l=t*4,u=t*8;return this.int16[l+0]=r,this.int16[l+1]=i,this.uint8[u+4]=n,this.uint8[u+5]=a,this.uint8[u+6]=s,this.uint8[u+7]=o,t}};uw.prototype.bytesPerElement=8,Ae("StructArrayLayout2i4ub8",uw);var Dm=class extends Rr{_refreshViews(){this.uint8=new Uint8Array(this.arrayBuffer),this.float32=new Float32Array(this.arrayBuffer)}emplaceBack(t,r){let i=this.length;return this.resize(i+1),this.emplace(i,t,r)}emplace(t,r,i){let n=t*2;return this.float32[n+0]=r,this.float32[n+1]=i,t}};Dm.prototype.bytesPerElement=8,Ae("StructArrayLayout2f8",Dm);var cw=class extends Rr{_refreshViews(){this.uint8=new Uint8Array(this.arrayBuffer),this.uint16=new Uint16Array(this.arrayBuffer)}emplaceBack(t,r,i,n,a,s,o,l,u,c){let d=this.length;return this.resize(d+1),this.emplace(d,t,r,i,n,a,s,o,l,u,c)}emplace(t,r,i,n,a,s,o,l,u,c,d){let h=t*10;return this.uint16[h+0]=r,this.uint16[h+1]=i,this.uint16[h+2]=n,this.uint16[h+3]=a,this.uint16[h+4]=s,this.uint16[h+5]=o,this.uint16[h+6]=l,this.uint16[h+7]=u,this.uint16[h+8]=c,this.uint16[h+9]=d,t}};cw.prototype.bytesPerElement=20,Ae("StructArrayLayout10ui20",cw);var dw=class extends Rr{_refreshViews(){this.uint8=new Uint8Array(this.arrayBuffer),this.uint16=new Uint16Array(this.arrayBuffer)}emplaceBack(t,r,i,n,a,s,o,l){let u=this.length;return this.resize(u+1),this.emplace(u,t,r,i,n,a,s,o,l)}emplace(t,r,i,n,a,s,o,l,u){let c=t*8;return this.uint16[c+0]=r,this.uint16[c+1]=i,this.uint16[c+2]=n,this.uint16[c+3]=a,this.uint16[c+4]=s,this.uint16[c+5]=o,this.uint16[c+6]=l,this.uint16[c+7]=u,t}};dw.prototype.bytesPerElement=16,Ae("StructArrayLayout8ui16",dw);var hw=class extends Rr{_refreshViews(){this.uint8=new Uint8Array(this.arrayBuffer),this.int16=new Int16Array(this.arrayBuffer),this.uint16=new Uint16Array(this.arrayBuffer)}emplaceBack(t,r,i,n,a,s,o,l,u,c,d,h){let f=this.length;return this.resize(f+1),this.emplace(f,t,r,i,n,a,s,o,l,u,c,d,h)}emplace(t,r,i,n,a,s,o,l,u,c,d,h,f){let p=t*12;return this.int16[p+0]=r,this.int16[p+1]=i,this.int16[p+2]=n,this.int16[p+3]=a,this.uint16[p+4]=s,this.uint16[p+5]=o,this.uint16[p+6]=l,this.uint16[p+7]=u,this.int16[p+8]=c,this.int16[p+9]=d,this.int16[p+10]=h,this.int16[p+11]=f,t}};hw.prototype.bytesPerElement=24,Ae("StructArrayLayout4i4ui4i24",hw);var fw=class extends Rr{_refreshViews(){this.uint8=new Uint8Array(this.arrayBuffer),this.float32=new Float32Array(this.arrayBuffer)}emplaceBack(t,r,i){let n=this.length;return this.resize(n+1),this.emplace(n,t,r,i)}emplace(t,r,i,n){let a=t*3;return this.float32[a+0]=r,this.float32[a+1]=i,this.float32[a+2]=n,t}};fw.prototype.bytesPerElement=12,Ae("StructArrayLayout3f12",fw);var pw=class extends Rr{_refreshViews(){this.uint8=new Uint8Array(this.arrayBuffer),this.uint32=new Uint32Array(this.arrayBuffer)}emplaceBack(t){let r=this.length;return this.resize(r+1),this.emplace(r,t)}emplace(t,r){let i=t*1;return this.uint32[i+0]=r,t}};pw.prototype.bytesPerElement=4,Ae("StructArrayLayout1ul4",pw);var mw=class extends Rr{_refreshViews(){this.uint8=new Uint8Array(this.arrayBuffer),this.int16=new Int16Array(this.arrayBuffer),this.uint32=new Uint32Array(this.arrayBuffer),this.uint16=new Uint16Array(this.arrayBuffer)}emplaceBack(t,r,i,n,a,s,o,l,u){let c=this.length;return this.resize(c+1),this.emplace(c,t,r,i,n,a,s,o,l,u)}emplace(t,r,i,n,a,s,o,l,u,c){let d=t*10,h=t*5;return this.int16[d+0]=r,this.int16[d+1]=i,this.int16[d+2]=n,this.int16[d+3]=a,this.int16[d+4]=s,this.int16[d+5]=o,this.uint32[h+3]=l,this.uint16[d+8]=u,this.uint16[d+9]=c,t}};mw.prototype.bytesPerElement=20,Ae("StructArrayLayout6i1ul2ui20",mw);var gw=class extends Rr{_refreshViews(){this.uint8=new Uint8Array(this.arrayBuffer),this.int16=new Int16Array(this.arrayBuffer)}emplaceBack(t,r,i,n,a,s){let o=this.length;return this.resize(o+1),this.emplace(o,t,r,i,n,a,s)}emplace(t,r,i,n,a,s,o){let l=t*6;return this.int16[l+0]=r,this.int16[l+1]=i,this.int16[l+2]=n,this.int16[l+3]=a,this.int16[l+4]=s,this.int16[l+5]=o,t}};gw.prototype.bytesPerElement=12,Ae("StructArrayLayout2i2i2i12",gw);var _w=class extends Rr{_refreshViews(){this.uint8=new Uint8Array(this.arrayBuffer),this.float32=new Float32Array(this.arrayBuffer),this.int16=new Int16Array(this.arrayBuffer)}emplaceBack(t,r,i,n,a){let s=this.length;return this.resize(s+1),this.emplace(s,t,r,i,n,a)}emplace(t,r,i,n,a,s){let o=t*4,l=t*8;return this.float32[o+0]=r,this.float32[o+1]=i,this.float32[o+2]=n,this.int16[l+6]=a,this.int16[l+7]=s,t}};_w.prototype.bytesPerElement=16,Ae("StructArrayLayout2f1f2i16",_w);var yw=class extends Rr{_refreshViews(){this.uint8=new Uint8Array(this.arrayBuffer),this.float32=new Float32Array(this.arrayBuffer),this.int16=new Int16Array(this.arrayBuffer)}emplaceBack(t,r,i,n,a,s){let o=this.length;return this.resize(o+1),this.emplace(o,t,r,i,n,a,s)}emplace(t,r,i,n,a,s,o){let l=t*16,u=t*4,c=t*8;return this.uint8[l+0]=r,this.uint8[l+1]=i,this.float32[u+1]=n,this.float32[u+2]=a,this.int16[c+6]=s,this.int16[c+7]=o,t}};yw.prototype.bytesPerElement=16,Ae("StructArrayLayout2ub2f2i16",yw);var Ry=class extends Rr{_refreshViews(){this.uint8=new Uint8Array(this.arrayBuffer),this.uint16=new Uint16Array(this.arrayBuffer)}emplaceBack(t,r,i){let n=this.length;return this.resize(n+1),this.emplace(n,t,r,i)}emplace(t,r,i,n){let a=t*3;return this.uint16[a+0]=r,this.uint16[a+1]=i,this.uint16[a+2]=n,t}};Ry.prototype.bytesPerElement=6,Ae("StructArrayLayout3ui6",Ry);var vw=class extends Rr{_refreshViews(){this.uint8=new Uint8Array(this.arrayBuffer),this.int16=new Int16Array(this.arrayBuffer),this.uint16=new Uint16Array(this.arrayBuffer),this.uint32=new Uint32Array(this.arrayBuffer),this.float32=new Float32Array(this.arrayBuffer)}emplaceBack(t,r,i,n,a,s,o,l,u,c,d,h,f,p,m,g,v){let x=this.length;return this.resize(x+1),this.emplace(x,t,r,i,n,a,s,o,l,u,c,d,h,f,p,m,g,v)}emplace(t,r,i,n,a,s,o,l,u,c,d,h,f,p,m,g,v,x){let _=t*24,y=t*12,w=t*48;return this.int16[_+0]=r,this.int16[_+1]=i,this.uint16[_+2]=n,this.uint16[_+3]=a,this.uint32[y+2]=s,this.uint32[y+3]=o,this.uint32[y+4]=l,this.uint16[_+10]=u,this.uint16[_+11]=c,this.uint16[_+12]=d,this.float32[y+7]=h,this.float32[y+8]=f,this.uint8[w+36]=p,this.uint8[w+37]=m,this.uint8[w+38]=g,this.uint32[y+10]=v,this.int16[_+22]=x,t}};vw.prototype.bytesPerElement=48,Ae("StructArrayLayout2i2ui3ul3ui2f3ub1ul1i48",vw);var bw=class extends Rr{_refreshViews(){this.uint8=new Uint8Array(this.arrayBuffer),this.int16=new Int16Array(this.arrayBuffer),this.uint16=new Uint16Array(this.arrayBuffer),this.uint32=new Uint32Array(this.arrayBuffer),this.float32=new Float32Array(this.arrayBuffer)}emplaceBack(t,r,i,n,a,s,o,l,u,c,d,h,f,p,m,g,v,x,_,y,w,$,S,E,C,I,P,T){let D=this.length;return this.resize(D+1),this.emplace(D,t,r,i,n,a,s,o,l,u,c,d,h,f,p,m,g,v,x,_,y,w,$,S,E,C,I,P,T)}emplace(t,r,i,n,a,s,o,l,u,c,d,h,f,p,m,g,v,x,_,y,w,$,S,E,C,I,P,T,D){let A=t*32,z=t*16;return this.int16[A+0]=r,this.int16[A+1]=i,this.int16[A+2]=n,this.int16[A+3]=a,this.int16[A+4]=s,this.int16[A+5]=o,this.int16[A+6]=l,this.int16[A+7]=u,this.uint16[A+8]=c,this.uint16[A+9]=d,this.uint16[A+10]=h,this.uint16[A+11]=f,this.uint16[A+12]=p,this.uint16[A+13]=m,this.uint16[A+14]=g,this.uint16[A+15]=v,this.uint16[A+16]=x,this.uint16[A+17]=_,this.uint16[A+18]=y,this.uint16[A+19]=w,this.uint16[A+20]=$,this.uint16[A+21]=S,this.uint16[A+22]=E,this.uint32[z+12]=C,this.float32[z+13]=I,this.float32[z+14]=P,this.uint16[A+30]=T,this.uint16[A+31]=D,t}};bw.prototype.bytesPerElement=64,Ae("StructArrayLayout8i15ui1ul2f2ui64",bw);var Oy=class extends Rr{_refreshViews(){this.uint8=new Uint8Array(this.arrayBuffer),this.float32=new Float32Array(this.arrayBuffer)}emplaceBack(t){let r=this.length;return this.resize(r+1),this.emplace(r,t)}emplace(t,r){let i=t*1;return this.float32[i+0]=r,t}};Oy.prototype.bytesPerElement=4,Ae("StructArrayLayout1f4",Oy);var xw=class extends Rr{_refreshViews(){this.uint8=new Uint8Array(this.arrayBuffer),this.uint16=new Uint16Array(this.arrayBuffer),this.float32=new Float32Array(this.arrayBuffer)}emplaceBack(t,r,i){let n=this.length;return this.resize(n+1),this.emplace(n,t,r,i)}emplace(t,r,i,n){let a=t*6,s=t*3;return this.uint16[a+0]=r,this.float32[s+1]=i,this.float32[s+2]=n,t}};xw.prototype.bytesPerElement=12,Ae("StructArrayLayout1ui2f12",xw);var ww=class extends Rr{_refreshViews(){this.uint8=new Uint8Array(this.arrayBuffer),this.uint32=new Uint32Array(this.arrayBuffer),this.uint16=new Uint16Array(this.arrayBuffer)}emplaceBack(t,r,i){let n=this.length;return this.resize(n+1),this.emplace(n,t,r,i)}emplace(t,r,i,n){let a=t*2,s=t*4;return this.uint32[a+0]=r,this.uint16[s+2]=i,this.uint16[s+3]=n,t}};ww.prototype.bytesPerElement=8,Ae("StructArrayLayout1ul2ui8",ww);var $w=class extends Rr{_refreshViews(){this.uint8=new Uint8Array(this.arrayBuffer),this.uint16=new Uint16Array(this.arrayBuffer)}emplaceBack(t,r){let i=this.length;return this.resize(i+1),this.emplace(i,t,r)}emplace(t,r,i){let n=t*2;return this.uint16[n+0]=r,this.uint16[n+1]=i,t}};$w.prototype.bytesPerElement=4,Ae("StructArrayLayout2ui4",$w);var Sw=class extends Rr{_refreshViews(){this.uint8=new Uint8Array(this.arrayBuffer),this.uint16=new Uint16Array(this.arrayBuffer)}emplaceBack(t){let r=this.length;return this.resize(r+1),this.emplace(r,t)}emplace(t,r){let i=t*1;return this.uint16[i+0]=r,t}};Sw.prototype.bytesPerElement=2,Ae("StructArrayLayout1ui2",Sw);var Tw=class extends Rr{_refreshViews(){this.uint8=new Uint8Array(this.arrayBuffer),this.float32=new Float32Array(this.arrayBuffer)}emplaceBack(t,r,i,n){let a=this.length;return this.resize(a+1),this.emplace(a,t,r,i,n)}emplace(t,r,i,n,a){let s=t*4;return this.float32[s+0]=r,this.float32[s+1]=i,this.float32[s+2]=n,this.float32[s+3]=a,t}};Tw.prototype.bytesPerElement=16,Ae("StructArrayLayout4f16",Tw);var iL=class extends _g{get anchorPointX(){return this._structArray.int16[this._pos2+0]}get anchorPointY(){return this._structArray.int16[this._pos2+1]}get x1(){return this._structArray.int16[this._pos2+2]}get y1(){return this._structArray.int16[this._pos2+3]}get x2(){return this._structArray.int16[this._pos2+4]}get y2(){return this._structArray.int16[this._pos2+5]}get featureIndex(){return this._structArray.uint32[this._pos4+3]}get sourceLayerIndex(){return this._structArray.uint16[this._pos2+8]}get bucketIndex(){return this._structArray.uint16[this._pos2+9]}get anchorPoint(){return new de(this.anchorPointX,this.anchorPointY)}};iL.prototype.size=20;var nL=class extends mw{get(t){return new iL(this,t)}};Ae("CollisionBoxArray",nL);var aL=class extends _g{get anchorX(){return this._structArray.int16[this._pos2+0]}get anchorY(){return this._structArray.int16[this._pos2+1]}get glyphStartIndex(){return this._structArray.uint16[this._pos2+2]}get numGlyphs(){return this._structArray.uint16[this._pos2+3]}get vertexStartIndex(){return this._structArray.uint32[this._pos4+2]}get lineStartIndex(){return this._structArray.uint32[this._pos4+3]}get lineLength(){return this._structArray.uint32[this._pos4+4]}get segment(){return this._structArray.uint16[this._pos2+10]}get lowerSize(){return this._structArray.uint16[this._pos2+11]}get upperSize(){return this._structArray.uint16[this._pos2+12]}get lineOffsetX(){return this._structArray.float32[this._pos4+7]}get lineOffsetY(){return this._structArray.float32[this._pos4+8]}get writingMode(){return this._structArray.uint8[this._pos1+36]}get placedOrientation(){return this._structArray.uint8[this._pos1+37]}set placedOrientation(t){this._structArray.uint8[this._pos1+37]=t}get hidden(){return this._structArray.uint8[this._pos1+38]}set hidden(t){this._structArray.uint8[this._pos1+38]=t}get crossTileID(){return this._structArray.uint32[this._pos4+10]}set crossTileID(t){this._structArray.uint32[this._pos4+10]=t}get associatedIconIndex(){return this._structArray.int16[this._pos2+22]}};aL.prototype.size=48;var sL=class extends vw{get(t){return new aL(this,t)}};Ae("PlacedSymbolArray",sL);var oL=class extends _g{get anchorX(){return this._structArray.int16[this._pos2+0]}get anchorY(){return this._structArray.int16[this._pos2+1]}get rightJustifiedTextSymbolIndex(){return this._structArray.int16[this._pos2+2]}get centerJustifiedTextSymbolIndex(){return this._structArray.int16[this._pos2+3]}get leftJustifiedTextSymbolIndex(){return this._structArray.int16[this._pos2+4]}get verticalPlacedTextSymbolIndex(){return this._structArray.int16[this._pos2+5]}get placedIconSymbolIndex(){return this._structArray.int16[this._pos2+6]}get verticalPlacedIconSymbolIndex(){return this._structArray.int16[this._pos2+7]}get key(){return this._structArray.uint16[this._pos2+8]}get textBoxStartIndex(){return this._structArray.uint16[this._pos2+9]}get textBoxEndIndex(){return this._structArray.uint16[this._pos2+10]}get verticalTextBoxStartIndex(){return this._structArray.uint16[this._pos2+11]}get verticalTextBoxEndIndex(){return this._structArray.uint16[this._pos2+12]}get iconBoxStartIndex(){return this._structArray.uint16[this._pos2+13]}get iconBoxEndIndex(){return this._structArray.uint16[this._pos2+14]}get verticalIconBoxStartIndex(){return this._structArray.uint16[this._pos2+15]}get verticalIconBoxEndIndex(){return this._structArray.uint16[this._pos2+16]}get featureIndex(){return this._structArray.uint16[this._pos2+17]}get numHorizontalGlyphVertices(){return this._structArray.uint16[this._pos2+18]}get numVerticalGlyphVertices(){return this._structArray.uint16[this._pos2+19]}get numIconVertices(){return this._structArray.uint16[this._pos2+20]}get numVerticalIconVertices(){return this._structArray.uint16[this._pos2+21]}get useRuntimeCollisionCircles(){return this._structArray.uint16[this._pos2+22]}get crossTileID(){return this._structArray.uint32[this._pos4+12]}set crossTileID(t){this._structArray.uint32[this._pos4+12]=t}get textBoxScale(){return this._structArray.float32[this._pos4+13]}get collisionCircleDiameter(){return this._structArray.float32[this._pos4+14]}get textAnchorOffsetStartIndex(){return this._structArray.uint16[this._pos2+30]}get textAnchorOffsetEndIndex(){return this._structArray.uint16[this._pos2+31]}};oL.prototype.size=64;var lL=class extends bw{get(t){return new oL(this,t)}};Ae("SymbolInstanceArray",lL);var uL=class extends Oy{getoffsetX(t){return this.float32[t*1+0]}};Ae("GlyphOffsetArray",uL);var cL=class extends Dy{getx(t){return this.int16[t*3+0]}gety(t){return this.int16[t*3+1]}gettileUnitDistanceFromAnchor(t){return this.int16[t*3+2]}};Ae("SymbolLineVertexArray",cL);var dL=class extends _g{get textAnchor(){return this._structArray.uint16[this._pos2+0]}get textOffset0(){return this._structArray.float32[this._pos4+1]}get textOffset1(){return this._structArray.float32[this._pos4+2]}};dL.prototype.size=12;var hL=class extends xw{get(t){return new dL(this,t)}};Ae("TextAnchorOffsetArray",hL);var fL=class extends _g{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]}};fL.prototype.size=8;var pL=class extends ww{get(t){return new fL(this,t)}};Ae("FeatureIndexArray",pL);var Gl=class extends Am{},LTe=class extends Dy{},FTe=class extends ow{},zTe=class extends Am{},NTe=class extends Am{},BTe=class extends lw{},jTe=class extends uw{},UTe=class extends Dm{},Jc=class extends cw{},l8=class extends dw{},VTe=class extends hw{},qTe=class extends fw{},GTe=class extends pw{},u8=class extends gw{},HTe=class extends _w{},YTe=class extends yw{},WTe=class extends Ry{},go=class extends Ry{},Cw=class extends $w{},ZTe=class extends Sw{};const KTe=Ar([{name:"a_pos",components:2,type:"Int16"}],4),XTe=KTe.members;var $r=class pd{constructor(t=[]){this._forceNewSegmentOnNextPrepare=!1,this.segments=t}prepareSegment(t,r,i,n){let a=this.segments[this.segments.length-1];return t>pd.MAX_VERTEX_ARRAY_LENGTH&&vr(`Max vertices per segment is ${pd.MAX_VERTEX_ARRAY_LENGTH}: bucket requested ${t}. Consider using the \`fillLargeMeshArrays\` function if you require meshes with more than ${pd.MAX_VERTEX_ARRAY_LENGTH} vertices.`),this._forceNewSegmentOnNextPrepare||!a||a.vertexLength+t>pd.MAX_VERTEX_ARRAY_LENGTH||a.sortKey!==n?this.createNewSegment(r,i,n):a}createNewSegment(t,r,i){let n={vertexOffset:t.length,primitiveOffset:r.length,vertexLength:0,primitiveLength:0,vaos:{}};return i!==void 0&&(n.sortKey=i),this._forceNewSegmentOnNextPrepare=!1,this.segments.push(n),n}getOrCreateLatestSegment(t,r,i){return this.prepareSegment(0,t,r,i)}forceNewSegmentOnNextPrepare(){this._forceNewSegmentOnNextPrepare=!0}get(){return this.segments}destroy(){for(let t of this.segments)for(let r in t.vaos)t.vaos[r].destroy()}static simpleSegment(t,r,i,n){return new pd([{vertexOffset:t,primitiveOffset:r,vertexLength:i,primitiveLength:n,vaos:{},sortKey:0}])}};$r.MAX_VERTEX_ARRAY_LENGTH=2**16-1,Ae("SegmentVector",$r);function c8(e,t){return e=Ot(Math.floor(e),0,255),t=Ot(Math.floor(t),0,255),256*e+t}const JTe=Ar([{name:"a_pattern_from",components:4,type:"Uint16"},{name:"a_pattern_to",components:4,type:"Uint16"},{name:"a_pixel_ratio_from",components:1,type:"Uint16"},{name:"a_pixel_ratio_to",components:1,type:"Uint16"}]),QTe=Ar([{name:"a_dasharray_from",components:4,type:"Uint16"},{name:"a_dasharray_to",components:4,type:"Uint16"}]);var e6e=M$(((e,t)=>{function r(i,n){for(var a=i.length&3,s=i.length-a,o=n,l,u=3432918353,c=461845907,d,h=0;h<s;)d=i.charCodeAt(h)&255|(i.charCodeAt(++h)&255)<<8|(i.charCodeAt(++h)&255)<<16|(i.charCodeAt(++h)&255)<<24,++h,d=(d&65535)
vendor: 6,148 bytes, line 741
741*u+(((d>>>16)*u&65535)<<16)&4294967295,d=d<<15|d>>>17,d=(d&65535)*c+(((d>>>16)*c&65535)<<16)&4294967295,o^=d,o=o<<13|o>>>19,l=(o&65535)*5+(((o>>>16)*5&65535)<<16)&4294967295,o=(l&65535)+27492+(((l>>>16)+58964&65535)<<16);switch(d=0,a){case 3:d^=(i.charCodeAt(h+2)&255)<<16;case 2:d^=(i.charCodeAt(h+1)&255)<<8;case 1:d^=i.charCodeAt(h)&255,d=(d&65535)*u+(((d>>>16)*u&65535)<<16)&4294967295,d=d<<15|d>>>17,d=(d&65535)*c+(((d>>>16)*c&65535)<<16)&4294967295,o^=d}return o^=i.length,o^=o>>>16,o=(o&65535)*2246822507+(((o>>>16)*2246822507&65535)<<16)&4294967295,o^=o>>>13,o=(o&65535)*3266489909+(((o>>>16)*3266489909&65535)<<16)&4294967295,o^=o>>>16,o>>>0}t!==void 0&&(t.exports=r)})),t6e=M$(((e,t)=>{function r(i,n){for(var a=i.length,s=n^a,o=0,l;a>=4;)l=i.charCodeAt(o)&255|(i.charCodeAt(++o)&255)<<8|(i.charCodeAt(++o)&255)<<16|(i.charCodeAt(++o)&255)<<24,l=(l&65535)*1540483477+(((l>>>16)*1540483477&65535)<<16),l^=l>>>24,l=(l&65535)*1540483477+(((l>>>16)*1540483477&65535)<<16),s=(s&65535)*1540483477+(((s>>>16)*1540483477&65535)<<16)^l,a-=4,++o;switch(a){case 3:s^=(i.charCodeAt(o+2)&255)<<16;case 2:s^=(i.charCodeAt(o+1)&255)<<8;case 1:s^=i.charCodeAt(o)&255,s=(s&65535)*1540483477+(((s>>>16)*1540483477&65535)<<16)}return s^=s>>>13,s=(s&65535)*1540483477+(((s>>>16)*1540483477&65535)<<16),s^=s>>>15,s>>>0}t.exports=r})),r6e=d$e(M$(((e,t)=>{var r=e6e(),i=t6e();t.exports=r,t.exports.murmur3=r,t.exports.murmur2=i}))()),mL=class gL{constructor(){this.ids=[],this.positions=[],this.indexed=!1}add(t,r,i,n){this.ids.push(d8(t)),this.positions.push(r,i,n)}getPositions(t){if(!this.indexed)throw Error("Trying to get index, but feature positions are not indexed");let r=d8(t),i=0,n=this.ids.length-1;for(;i<n;){let s=i+n>>1;this.ids[s]>=r?n=s:i=s+1}let a=[];for(;this.ids[i]===r;){let s=this.positions[3*i],o=this.positions[3*i+1],l=this.positions[3*i+2];a.push({index:s,start:o,end:l}),i++}return a}static serialize(t,r){let i=new Float64Array(t.ids),n=new Uint32Array(t.positions);return kw(i,n,0,i.length-1),r&&r.push(i.buffer,n.buffer),{ids:i,positions:n}}static deserialize(t){let r=new gL;return r.ids=t.ids,r.positions=t.positions,r.indexed=!0,r}};function d8(e){let t=+e;return!isNaN(t)&&t<=2**53-1?t:(0,r6e.default)(String(e))}function kw(e,t,r,i){for(;r<i;){let n=e[r+i>>1],a=r-1,s=i+1;for(;;){do a++;while(e[a]<n);do s--;while(e[s]>n);if(a>=s)break;b0(e,a,s),b0(t,3*a,3*s),b0(t,3*a+1,3*s+1),b0(t,3*a+2,3*s+2)}s-r<i-s?(kw(e,t,r,s),r=s+1):(kw(e,t,s+1,i),i=s)}}function b0(e,t,r){let i=e[t];e[t]=e[r],e[r]=i}Ae("FeaturePositionMap",mL);var _l=class{constructor(t,r){this.gl=t.gl,this.location=r}},We=class extends _l{constructor(t,r){super(t,r),this.current=0}set(t){this.current!==t&&(this.current=t,this.gl.uniform1i(this.location,t))}},Ce=class extends _l{constructor(t,r){super(t,r),this.current=0}set(t){this.current!==t&&(this.current=t,this.gl.uniform1f(this.location,t))}},Je=class extends _l{constructor(t,r){super(t,r),this.current=[0,0]}set(t){(t[0]!==this.current[0]||t[1]!==this.current[1])&&(this.current=t,this.gl.uniform2f(this.location,t[0],t[1]))}},ba=class extends _l{constructor(t,r){super(t,r),this.current=[0,0,0]}set(t){(t[0]!==this.current[0]||t[1]!==this.current[1]||t[2]!==this.current[2])&&(this.current=t,this.gl.uniform3f(this.location,t[0],t[1],t[2]))}},du=class extends _l{constructor(t,r){super(t,r),this.current=[0,0,0,0]}set(t){(t[0]!==this.current[0]||t[1]!==this.current[1]||t[2]!==this.current[2]||t[3]!==this.current[3])&&(this.current=t,this.gl.uniform4f(this.location,t[0],t[1],t[2],t[3]))}},hu=class extends _l{constructor(t,r){super(t,r),this.current=at.transparent}set(t){(t.r!==this.current.r||t.g!==this.current.g||t.b!==this.current.b||t.a!==this.current.a)&&(this.current=t,this.gl.uniform4f(this.location,t.r,t.g,t.b,t.a))}},h8=class extends _l{constructor(t,r){super(t,r),this.current=[]}set(t){if(t!=this.current){this.current=t;let r=new Float32Array(t.length*4);for(let i=0;i<t.length;i++)r[4*i]=t[i].r,r[4*i+1]=t[i].g,r[4*i+2]=t[i].b,r[4*i+3]=t[i].a;this.gl.uniform4fv(this.location,r)}}},f8=class extends _l{constructor(t,r){super(t,r),this.current=[]}set(t){if(t!=this.current){this.current=t;let r=new Float32Array(t);this.gl.uniform1fv(this.location,r)}}};const i6e=new Float32Array(16);var ka=class extends _l{constructor(t,r){super(t,r),this.current=i6e}set(t){if(t[12]!==this.current[12]||t[0]!==this.current[0]){this.current=t,this.gl.uniformMatrix4fv(this.location,!1,t);return}for(let r=1;r<16;r++)if(t[r]!==this.current[r]){this.current=t,this.gl.uniformMatrix4fv(this.location,!1,t);break}}};function Ew(e){return[c8(255*e.r,255*e.g),c8(255*e.b,255*e.a)]}var ep=class{constructor(t,r,i){this.value=t,this.uniformNames=r.map(n=>`u_${n}`),this.type=i}setUniform(t,r,i){t.set(i.constantOr(this.value))}getBinding(t,r,i){return this.type==="color"?new hu(t,r):new Ce(t,r)}},Au=class{constructor(t,r){this.uniformNames=r.map(i=>`u_${i}`),this.patternFrom=null,this.patternTo=null,this.pixelRatioFrom=1,this.pixelRatioTo=1}setConstantPatternPositions(t,r){this.pixelRatioFrom=r.pixelRatio,this.pixelRatioTo=t.pixelRatio,this.patternFrom=r.tlbr,this.patternTo=t.tlbr}setConstantDashPositions(t,r){this.dashTo=[0,t.y,t.height,t.width],this.dashFrom=[0,r.y,r.height,r.width]}setUniform(t,r,i,n){let a=null;n==="u_pattern_to"?a=this.patternTo:n==="u_pattern_from"?a=this.patternFrom:n==="u_dasharray_to"?a=this.dashTo:n==="u_dasharray_from"?a=this.dashFrom:n==="u_pixel_ratio_to"?a=this.pixelRatioTo:n==="u_pixel_ratio_from"&&(a=this.pixelRatioFrom),a!==null&&t.set(a)}getBinding(t,r,i){return i.startsWith("u_pattern")||i.startsWith("u_dasharray_")?new du(t,r):new Ce(t,r)}},xo=class{constructor(t,r,i,n){this.expression=t,this.type=i,this.maxValue=0,this.paintVertexAttributes=r.map(a=>({name:`a_${a}`,type:"Float32",components:i==="color"?2:1,offset:0})),this.paintVertexArray=new n}populatePaintArray(t,r,i){let n=this.paintVertexArray.length,a=this.expression.evaluate(new Tr(0,i),r,{},i.canonical,[],i.formattedSection);this.paintVertexArray.resize(t),this._setPaintValue(n,t,a)}updatePaintArray(t,r,i,n,a){let s=this.expression.evaluate(new Tr(0,a),i,n);this._setPaintValue(t,r,s)}
vendor: 8,452 bytes, line 741
741_setPaintValue(t,r,i){if(this.type==="color"){let n=Ew(i);for(let a=t;a<r;a++)this.paintVertexArray.emplace(a,n[0],n[1])}else{for(let n=t;n<r;n++)this.paintVertexArray.emplace(n,i);this.maxValue=Math.max(this.maxValue,Math.abs(i))}}upload(t){var r,i;(r=this.paintVertexArray)!=null&&r.arrayBuffer.byteLength&&((i=this.paintVertexBuffer)!=null&&i.buffer?this.paintVertexBuffer.updateData(this.paintVertexArray):this.paintVertexBuffer=t.createVertexBuffer(this.paintVertexArray,this.paintVertexAttributes,this.expression.isStateDependent))}destroy(){this.paintVertexBuffer&&this.paintVertexBuffer.destroy()}},ps=class{constructor(t,r,i,n,a,s){this.expression=t,this.uniformNames=r.map(o=>`u_${o}_t`),this.type=i,this.useIntegerZoom=n,this.zoom=a,this.maxValue=0,this.paintVertexAttributes=r.map(o=>({name:`a_${o}`,type:"Float32",components:i==="color"?4:2,offset:0})),this.paintVertexArray=new s}populatePaintArray(t,r,i){let n=this.expression.evaluate(new Tr(this.zoom,i),r,{},i.canonical,[],i.formattedSection),a=this.expression.evaluate(new Tr(this.zoom+1,i),r,{},i.canonical,[],i.formattedSection),s=this.paintVertexArray.length;this.paintVertexArray.resize(t),this._setPaintValue(s,t,n,a)}updatePaintArray(t,r,i,n,a){let s=this.expression.evaluate(new Tr(this.zoom,a),i,n),o=this.expression.evaluate(new Tr(this.zoom+1,a),i,n);this._setPaintValue(t,r,s,o)}_setPaintValue(t,r,i,n){if(this.type==="color"){let a=Ew(i),s=Ew(n);for(let o=t;o<r;o++)this.paintVertexArray.emplace(o,a[0],a[1],s[0],s[1])}else{for(let a=t;a<r;a++)this.paintVertexArray.emplace(a,i,n);this.maxValue=Math.max(this.maxValue,Math.abs(i),Math.abs(n))}}upload(t){var r,i;(r=this.paintVertexArray)!=null&&r.arrayBuffer.byteLength&&((i=this.paintVertexBuffer)!=null&&i.buffer?this.paintVertexBuffer.updateData(this.paintVertexArray):this.paintVertexBuffer=t.createVertexBuffer(this.paintVertexArray,this.paintVertexAttributes,this.expression.isStateDependent))}destroy(){this.paintVertexBuffer&&this.paintVertexBuffer.destroy()}setUniform(t,r){let i=this.useIntegerZoom?Math.floor(r.zoom):r.zoom,n=Ot(this.expression.interpolationFactor(i,this.zoom,this.zoom+1),0,1);t.set(n)}getBinding(t,r,i){return new Ce(t,r)}},Rl=class{constructor(t,r,i,n,a,s){this.expression=t,this.type=r,this.useIntegerZoom=i,this.zoom=n,this.layerId=s,this.zoomInPaintVertexArray=new a,this.zoomOutPaintVertexArray=new a}populatePaintArray(t,r,i){let n=this.zoomInPaintVertexArray.length;this.zoomInPaintVertexArray.resize(t),this.zoomOutPaintVertexArray.resize(t),this._setPaintValues(n,t,this.getPositionIds(r),i)}updatePaintArray(t,r,i,n,a){this._setPaintValues(t,r,this.getPositionIds(i),a)}_setPaintValues(t,r,i,n){let a=this.getPositions(n);if(!a||!i)return;let s=a[i.min],o=a[i.mid],l=a[i.max];if(!(!s||!o||!l))for(let u=t;u<r;u++)this.emplace(this.zoomInPaintVertexArray,u,s,o),this.emplace(this.zoomOutPaintVertexArray,u,l,o)}upload(t){var r,i;if((r=this.zoomInPaintVertexArray)!=null&&r.arrayBuffer.byteLength&&((i=this.zoomOutPaintVertexArray)!=null&&i.arrayBuffer.byteLength)){let n=this.getVertexAttributes();this.zoomInPaintVertexBuffer=t.createVertexBuffer(this.zoomInPaintVertexArray,n,this.expression.isStateDependent),this.zoomOutPaintVertexBuffer=t.createVertexBuffer(this.zoomOutPaintVertexArray,n,this.expression.isStateDependent)}}destroy(){this.zoomOutPaintVertexBuffer&&this.zoomOutPaintVertexBuffer.destroy(),this.zoomInPaintVertexBuffer&&this.zoomInPaintVertexBuffer.destroy()}},_L=class extends Rl{getPositions(t){return t.imagePositions}getPositionIds(t){var r;return(r=t.patterns)==null?void 0:r[this.layerId]}getVertexAttributes(){return JTe.members}emplace(t,r,i,n){t.emplace(r,i.tlbr[0],i.tlbr[1],i.tlbr[2],i.tlbr[3],n.tlbr[0],n.tlbr[1],n.tlbr[2],n.tlbr[3],i.pixelRatio,n.pixelRatio)}},yL=class extends Rl{getPositions(t){return t.dashPositions}getPositionIds(t){var r;return(r=t.dashes)==null?void 0:r[this.layerId]}getVertexAttributes(){return QTe.members}emplace(t,r,i,n){t.emplace(r,0,i.y,i.height,i.width,0,n.y,n.height,n.width)}},vL=class{constructor(t,r,i){this.binders={},this._buffers=[];let n=[];for(let a in t.paint._values){if(!i(a))continue;let s=t.paint.get(a);if(!(s instanceof vs)||!Ah(s.property.specification))continue;let o=n6e(a,t.type),l=s.value,u=s.property.specification.type,c=s.property.useIntegerZoom,d=s.property.specification["property-type"],h=d==="cross-faded"||d==="cross-faded-data-driven";if(l.kind==="constant")this.binders[a]=h?new Au(l.value,o):new ep(l.value,o,u),n.push(`/u_${a}`);else if(l.kind==="source"||h){let f=p8(a,u,"source");this.binders[a]=h?a==="line-dasharray"?new yL(l,u,c,r,f,t.id):new _L(l,u,c,r,f,t.id):new xo(l,o,u,f),n.push(`/a_${a}`)}else{let f=p8(a,u,"composite");this.binders[a]=new ps(l,o,u,c,r,f),n.push(`/z_${a}`)}}this.cacheKey=n.sort().join("")}getMaxValue(t){let r=this.binders[t];return r instanceof xo||r instanceof ps?r.maxValue:0}populatePaintArrays(t,r,i){for(let n in this.binders){let a=this.binders[n];(a instanceof xo||a instanceof ps||a instanceof Rl)&&a.populatePaintArray(t,r,i)}}setConstantPatternPositions(t,r){for(let i in this.binders){let n=this.binders[i];n instanceof Au&&n.setConstantPatternPositions(t,r)}}setConstantDashPositions(t,r){for(let i in this.binders){let n=this.binders[i];n instanceof Au&&n.setConstantDashPositions(t,r)}}updatePaintArrays(t,r,i,n,a){let s=!1;for(let o of t){let l=r.getPositions(o.id);for(let u of l){let c=i.feature(u.index);for(let d in this.binders){let h=this.binders[d];(h instanceof xo||h instanceof ps||h instanceof Rl)&&h.expression.isStateDependent===!0&&(h.expression=n.paint.get(d).value,h.updatePaintArray(u.start,u.end,c,o.state,a),s=!0)}}}return s}defines(){let t=[];for(let r in this.binders){let i=this.binders[r];(i instanceof ep||i instanceof Au)&&t.push(...i.uniformNames.map(n=>`#define HAS_UNIFORM_${n}`))}return t}getBinderAttributes(){let t=[];for(let r in this.binders){let i=this.binders[r];if(i instanceof xo||i instanceof ps)for(let n of i.paintVertexAttributes)t.push(n.name);else if(i instanceof Rl){let n=i.getVertexAttributes();for(let a of n)t.push(a.name)}}return t}getBinderUniforms(){let t=[];for(let r in this.binders){let i=this.binders[r];if(i instanceof ep||i instanceof Au||i instanceof ps)for(let n of i.uniformNames)t.push(n)}return t}getPaintVertexBuffers(){return this._buffers}getUniforms(t,r){let i=[];for(let n in this.binders){let a=this.binders[n];if(a instanceof ep||a instanceof Au||a instanceof ps){for(let s of a.uniformNames)if(r[s]){let o=a.getBinding(t,r[s],s);i.push({name:s,property:n,binding:o})}}}return i}setUniforms(t,r,i,n){for(let{name:a,property:s,binding:o}of r)this.binders[s].setUniform(o,n,i.get(s),a)}updatePaintBuffers(t){this._buffers=[];for(let r in this.binders){let i=this.binders[r];if(t&&i instanceof Rl){let n=t.fromScale===2?i.zoomInPaintVertexBuffer:i.zoomOutPaintVertexBuffer;n&&this._buffers.push(n)}else(i instanceof xo||i instanceof ps)&&i.paintVertexBuffer&&this._buffers.push(i.paintVertexBuffer)}}upload(t){for(let r in this.binders){let i=this.binders[r];(i instanceof xo||i instanceof ps||i instanceof Rl)&&i.upload(t)}this.updatePaintBuffers()}destroy(){for(let t in this.binders){let r=this.binders[t];(r instanceof xo||r instanceof ps||r instanceof Rl)&&r.destroy()}}},Cc=class{constructor(t,r,i=()=>!0){this.programConfigurations={};for(let n of t)this.programConfigurations[n.id]=new vL(n,r,i);this.needsUpload=!1,this._featureMap=new mL,this._bufferOffset=0}populatePaintArrays(t,r,i,n){for(let a in this.programConfigurations)this.programConfigurations[a].populatePaintArrays(t,r,n);r.id!==void 0&&this._featureMap.add(r.id,i,this._bufferOffset,t),this._bufferOffset=t,this.needsUpload=!0}updatePaintArrays(t,r,i,n){for(let a of i)this.needsUpload=this.programConfigurations[a.id].updatePaintArrays(t,this._featureMap,r,a,n)||this.needsUpload}get(t){return this.programConfigurations[t]}upload(t){if(this.needsUpload){for(let r in this.programConfigurations)this.programConfigurations[r].upload(t);this.needsUpload=!1}}destroy(){for(let t in this.programConfigurations)this.programConfigurations[t].destroy()}};function n6e(e,t){return{"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
741pwidth"],"line-dasharray":["dasharray_to","dasharray_from"],"line-pattern":["pattern_to","pattern_from","pixel_ratio_to","pixel_ratio_from"],"fill-pattern":["pattern_to","pattern_from","pixel_ratio_to","pixel_ratio_from"],"fill-extrusion-pattern":["pattern_to","pattern_from","pixel_ratio_to","pixel_ratio_from"]}[e]||[e.replace(`${t}-`,"").replace(/-/g,"_")]}function a6e(e){return{"line-pattern":{source:Jc,composite:Jc},"fill-pattern":{source:Jc,composite:Jc},"fill-extrusion-pattern":{source:Jc,composite:Jc},"line-dasharray":{source:l8,composite:l8}}[e]}function p8(e,t,r){var n;let i={color:{source:Dm,composite:Tw},number:{source:Oy,composite:Dm}};return((n=a6e(e))==null?void 0:n[r])||i[t][r]}Ae("ConstantBinder",ep),Ae("CrossFadedConstantBinder",Au),Ae("SourceExpressionBinder",xo),Ae("CrossFadedPatternBinder",_L),Ae("CrossFadedDasharrayBinder",yL),Ae("CompositeExpressionBinder",ps),Ae("ProgramConfiguration",vL,{omit:["_buffers"]}),Ae("ProgramConfigurationSet",Cc);const Pw=2**14-1,m8=-Pw-1;function Nc(e){let t=ye/e.extent,r=e.loadGeometry();for(let i of r)for(let n of i){let a=Math.round(n.x*t),s=Math.round(n.y*t);n.x=Ot(a,m8,Pw),n.y=Ot(s,m8,Pw),(a<n.x||a>n.x+1||s<n.y||s>n.y+1)&&vr("Geometry exceeds allowed extent, reduce your vector tile buffer size")}return r}function Bc(e,t){return{type:e.type,id:e.id,properties:e.properties,geometry:t?Nc(e):[]}}const g8=-32768;function s6e(e,t,r,i,n){e.emplaceBack(g8+t*8+i,g8+r*8+n)}var tS=class{constructor(t){this.zoom=t.zoom,this.overscaling=t.overscaling,this.layers=t.layers,this.layerIds=this.layers.map(r=>r.id),this.index=t.index,this.hasDependencies=!1,this.layoutVertexArray=new zTe,this.indexArray=new go,this.segments=new $r,this.programConfigurations=new Cc(t.layers,t.zoom),this.stateDependentLayerIds=this.layers.filter(r=>r.isStateDependent()).map(r=>r.id)}populate(t,r,i){let n=this.layers[0],a=[],s=null,o=!1,l=n.type==="heatmap";if(n.type==="circle"){let h=n;s=h.layout.get("circle-sort-key"),o=!s.isConstant(),l||(l=h.paint.get("circle-pitch-alignment")==="map")}let u=l?r.subdivisionGranularity.circle:1,c=new Tr(this.zoom),d=this.layers[0]._featureFilter.needGeometry;for(let{feature:h,id:f,index:p,sourceLayerIndex:m}of t){let g=Bc(h,d);if(!this.layers[0]._featureFilter.filter(c,g,i))continue;let v=o?s.evaluate(g,{},i):void 0,x={id:f,properties:h.properties,type:h.type,sourceLayerIndex:m,index:p,geometry:d?g.geometry:Nc(h),patterns:{},sortKey:v};a.push(x)}o&&a.sort((h,f)=>h.sortKey-f.sortKey);
vendor: 8,394 bytes, line 741
741for(let h of a){let{geometry:f,index:p,sourceLayerIndex:m}=h,g=t[p].feature;this.addFeature(h,f,p,i,u),r.featureIndex.insert(g,f,p,m,this.index)}}update(t,r,i){this.stateDependentLayers.length&&this.programConfigurations.updatePaintArrays(t,r,this.stateDependentLayers,{imagePositions:i})}isEmpty(){return this.layoutVertexArray.length===0}uploadPending(){return!this.uploaded||this.programConfigurations.needsUpload}upload(t){this.uploaded||(this.layoutVertexBuffer=t.createVertexBuffer(this.layoutVertexArray,XTe),this.indexBuffer=t.createIndexBuffer(this.indexArray)),this.programConfigurations.upload(t),this.uploaded=!0}destroy(){this.layoutVertexBuffer&&(this.layoutVertexBuffer.destroy(),this.indexBuffer.destroy(),this.programConfigurations.destroy(),this.segments.destroy())}addFeature(t,r,i,n,a=1){let s;switch(a){case 1:s=[0,7];break;case 3:s=[0,2,5,7];break;case 5:s=[0,1,3,4,6,7];break;case 7:s=[0,1,2,3,4,5,6,7];break;default:throw Error(`Invalid circle bucket granularity: ${a}; valid values are 1, 3, 5, 7.`)}let o=s.length;for(let l of r)for(let u of l){let c=u.x,d=u.y;if(c<0||c>=8192||d<0||d>=8192)continue;let h=this.segments.prepareSegment(o*o,this.layoutVertexArray,this.indexArray,t.sortKey),f=h.vertexLength;for(let p=0;p<o;p++)for(let m=0;m<o;m++)s6e(this.layoutVertexArray,c,d,s[m],s[p]);for(let p=0;p<o-1;p++)for(let m=0;m<o-1;m++){let g=f+p*o+m,v=f+(p+1)*o+m;this.indexArray.emplaceBack(g,v+1,g+1),this.indexArray.emplaceBack(g,v,v+1)}h.vertexLength+=o*o,h.primitiveLength+=(o-1)*(o-1)*2}this.programConfigurations.populatePaintArrays(this.layoutVertexArray.length,t,i,{imagePositions:{},canonical:n})}};Ae("CircleBucket",tS,{omit:["layers"]});function bL(e,t){for(let r of e)if(Lh(t,r))return!0;for(let r of t)if(Lh(e,r))return!0;return rS(e,t)}function cv(e,t,r){return Lh(e,t)?!0:Mw(t,e,r)}function xL(e,t){if(e.length===1)return _8(t,e[0]);for(let r of t)for(let i of r)if(Lh(e,i))return!0;for(let r of e)if(_8(t,r))return!0;for(let r of t)if(rS(e,r))return!0;return!1}function o6e(e,t,r){for(let i of t){if(e.length>=3){for(let n of i)if(Lh(e,n))return!0}if(l6e(e,i,r))return!0}return!1}function l6e(e,t,r){if(e.length>1){if(rS(e,t))return!0;for(let i of t)if(Mw(i,e,r))return!0}for(let i of e)if(Mw(i,t,r))return!0;return!1}function rS(e,t){if(e.length===0||t.length===0)return!1;for(let r=0;r<e.length-1;r++){let i=e[r],n=e[r+1];for(let a=0;a<t.length-1;a++){let s=t[a],o=t[a+1];if(u6e(i,n,s,o))return!0}}return!1}function u6e(e,t,r,i){return ql(e,r,i)!==ql(t,r,i)&&ql(e,t,r)!==ql(e,t,i)}function Mw(e,t,r){let i=r*r;if(t.length===1)return e.distSqr(t[0])<i;for(let n=1;n<t.length;n++){let a=t[n-1],s=t[n];if(c6e(e,a,s)<i)return!0}return!1}function c6e(e,t,r){let i=t.distSqr(r);if(i===0)return e.distSqr(t);let n=((e.x-t.x)*(r.x-t.x)+(e.y-t.y)*(r.y-t.y))/i;return n<0?e.distSqr(t):n>1?e.distSqr(r):e.distSqr(r.sub(t)._mult(n)._add(t))}function _8(e,t){let r=!1,i,n,a;for(let s of e){i=s;for(let o=0,l=i.length-1;o<i.length;l=o++)n=i[o],a=i[l],n.y>t.y!=a.y>t.y&&t.x<(a.x-n.x)*(t.y-n.y)/(a.y-n.y)+n.x&&(r=!r)}return r}function Lh(e,t){let r=!1;for(let i=0,n=e.length-1;i<e.length;n=i++){let a=e[i],s=e[n];a.y>t.y!=s.y>t.y&&t.x<(s.x-a.x)*(t.y-a.y)/(s.y-a.y)+a.x&&(r=!r)}return r}function d6e(e,t,r,i,n){for(let s of e)if(t<=s.x&&r<=s.y&&i>=s.x&&n>=s.y)return!0;let a=[new de(t,r),new de(t,n),new de(i,n),new de(i,r)];if(e.length>2){for(let s of a)if(Lh(e,s))return!0}for(let s=0;s<e.length-1;s++){let o=e[s],l=e[s+1];if(h6e(o,l,a))return!0}return!1}function h6e(e,t,r){let i=r[0],n=r[2];if(e.x<i.x&&t.x<i.x||e.x>n.x&&t.x>n.x||e.y<i.y&&t.y<i.y||e.y>n.y&&t.y>n.y)return!1;let a=ql(e,t,r[0]);return a!==ql(e,t,r[1])||a!==ql(e,t,r[2])||a!==ql(e,t,r[3])}function Xd(e,t,r){let i=t.paint.get(e).value;return i.kind==="constant"?i.value:r.programConfigurations.get(t.id).getMaxValue(e)}function dv(e){return Math.sqrt(e[0]*e[0]+e[1]*e[1])}function hv(e,t,r,i,n){if(!t[0]&&!t[1])return e;let a=de.convert(t)._mult(n);r==="viewport"&&a._rotate(-i);let s=[];for(let o of e)s.push(o.sub(a));return s}function f6e(e){let t=[];for(let r=0;r<e.length;r++){let i=e[r],n=t.at(-1);(r===0||n&&!i.equals(n))&&t.push(i)}return t}function p6e(e,t){let r=[];for(let i of e){let n=f6e(i),a=[];for(let s=0;s<n.length;s++){let o=n[s],l=n[s-1],u=n[s+1],c=s===0?new de(0,0):o.sub(l)._unit()._perp(),d=s===n.length-1?new de(0,0):u.sub(o)._unit()._perp(),h=c._add(d)._unit(),f=h.x*d.x+h.y*d.y;f!==0&&h._mult(1/f),a.push(h._mult(t)._add(o))}r.push(a)}return r}function m6e({queryGeometry:e,size:t},r){return cv(e,r,t)}function g6e({queryGeometry:e,size:t,transform:r,unwrappedTileID:i,getElevation:n},a){return cv(e,a,t*(r.projectTileCoordinates(a.x,a.y,i,n).signedDistanceFromCamera/r.cameraToCenterDistance))}function _6e({queryGeometry:e,size:t,transform:r,unwrappedTileID:i,getElevation:n},a){let s=r.projectTileCoordinates(a.x,a.y,i,n).signedDistanceFromCamera,o=t*(r.cameraToCenterDistance/s);return cv(e,iS(a,r,i,n),o)}function y6e({queryGeometry:e,size:t,transform:r,unwrappedTileID:i,getElevation:n},a){return cv(e,iS(a,r,i,n),t)}function wL({queryGeometry:e,size:t,transform:r,unwrappedTileID:i,getElevation:n,pitchAlignment:a="map",pitchScale:s="map"},o){let l=a==="map"?s==="map"?m6e:g6e:s==="map"?_6e:y6e,u={queryGeometry:e,size:t,transform:r,unwrappedTileID:i,getElevation:n};for(let c of o)for(let d of c)if(l(u,d))return!0;return!1}function iS(e,t,r,i){let n=t.projectTileCoordinates(e.x,e.y,r,i).point;return new de((n.x*.5+.5)*t.width,(-n.y*.5+.5)*t.height)}function v6e(e,t,r,i){return e.map(n=>iS(n,t,r,i))}let b6e;const x6e=()=>b6e||(b6e=new Mi({"circle-sort-key":new Ye(ce.layout_circle["circle-sort-key"],"circle-sort-key")}));let w6e;const $6e=()=>w6e||(w6e=new Mi({"circle-radius":new Ye(ce.paint_circle["circle-radius"],"circle-radius"),"circle-color":new Ye(ce.paint_circle["circle-color"],"circle-color"),"circle-blur":new Ye(ce.paint_circle["circle-blur"],"circle-blur"),"circle-opacity":new Ye(ce.paint_circle["circle-opacity"],"circle-opacity"),"circle-translate":new Pe(ce.paint_circle["circle-translate"],"circle-translate"),"circle-translate-anchor":new Pe(ce.paint_circle["circle-translate-anchor"],"circle-translate-anchor"),"circle-pitch-scale":new Pe(ce.paint_circle["circle-pitch-scale"],"circle-pitch-scale"),"circle-pitch-alignment":new Pe(ce.paint_circle["circle-pitch-alignment"],"circle-pitch-alignment"),"circle-stroke-width":new Ye(ce.paint_circle["circle-stroke-width"],"circle-stroke-width"),"circle-stroke-color":new Ye(ce.paint_circle["circle-stroke-color"],"circle-stroke-color"),"circle-stroke-opacity":new Ye(ce.paint_circle["circle-stroke-opacity"],"circle-stroke-opacity")}));var S6e={get paint(){return $6e()},get layout(){return x6e()}};const T6e=e=>e.type==="circle";var C6e=class extends Rs{constructor(t,r){super(t,S6e,r)}createBucket(t){return new tS(t)}queryRadius(t){let r=t;return Xd("circle-radius",this,r)+Xd("circle-stroke-width",this,r)+dv(this.paint.get("circle-translate"))}queryIntersectsFeature({queryGeometry:t,feature:r,featureState:i,geometry:n,transform:a,pixelsToTileUnits:s,unwrappedTileID:o,getElevation:l}){let u=hv(t,this.paint.get("circle-translate"),this.paint.get("circle-translate-anchor"),-a.bearingInRadians,s),c=this.paint.get("circle-radius").evaluate(r,i)+this.paint.get("circle-stroke-width").evaluate(r,i),d=this.paint.get("circle-pitch-scale"),h=this.paint.get("circle-pitch-alignment"),f,p;return h==="map"?(f=u,p=c*s):(f=v6e(u,a,o,l),p=c),wL({queryGeometry:f,size:p,transform:a,unwrappedTileID:o,getElevation:l,pitchAlignment:h,pitchScale:d},n)}},$L=class extends tS{};Ae("HeatmapBucket",$L,{omit:["layers"]});let k6e;const E6e=()=>k6e||(k6e=new Mi({"heatmap-radius":new Ye(ce.paint_heatmap["heatmap-radius"],"heatmap-radius"),"heatmap-weight":new Ye(ce.paint_heatmap["heatmap-weight"],"heatmap-weight"),"heatmap-intensity":new Pe(ce.paint_heatmap["heatmap-intensity"],"heatmap-intensity"),"heatmap-color":new uv(ce.paint_heatmap["heatmap-color"],"heatmap-color"),"heatmap-opacity":new Pe(ce.paint_heatmap["heatmap-opacity"],"heatmap-opacity")}));var P6e={get paint(){return E6e()}};function nS(e,{width:t,height:r},i,n){if(!n)n=new Uint8Array(t*r*i);else if(n instanceof Uint8ClampedArray)n=new Uint8Array(n.buffer);else if(n.length!==t*r*i)throw RangeError(`mismatched image size. expected: ${n.length} but got: ${t*r*i}`);return e.width=t,e.height=r,e.data=n,e}function SL(e,{width:t,height:r}
vendor: 8,470 bytes, line 741
741,i){if(t===e.width&&r===e.height)return;let n=nS({},{width:t,height:r},i);aS(e,n,{x:0,y:0},{x:0,y:0},{width:Math.min(e.width,t),height:Math.min(e.height,r)},i),e.width=t,e.height=r,e.data=n.data}function aS(e,t,r,i,n,a){if(n.width===0||n.height===0)return t;if(n.width>e.width||n.height>e.height||r.x>e.width-n.width||r.y>e.height-n.height)throw RangeError("out of range source coordinates for image copy");if(n.width>t.width||n.height>t.height||i.x>t.width-n.width||i.y>t.height-n.height)throw RangeError("out of range destination coordinates for image copy");let s=e.data,o=t.data;if(s===o)throw Error("srcData equals dstData, so image is already copied");for(let l=0;l<n.height;l++){let u=((r.y+l)*e.width+r.x)*a,c=((i.y+l)*t.width+i.x)*a;for(let d=0;d<n.width*a;d++)o[c+d]=s[u+d]}return t}var sS=class TL{constructor(t,r){nS(this,t,1,r)}resize(t){SL(this,t,1)}clone(){return new TL({width:this.width,height:this.height},new Uint8Array(this.data))}static copy(t,r,i,n,a){aS(t,r,i,n,a,1)}},_r=class CL{constructor(t,r){nS(this,t,4,r)}resize(t){SL(this,t,4)}replace(t,r){r?this.data.set(t):this.data=t instanceof Uint8ClampedArray?new Uint8Array(t.buffer):t}clone(){return new CL({width:this.width,height:this.height},new Uint8Array(this.data))}static copy(t,r,i,n,a){aS(t,r,i,n,a,4)}setPixel(t,r,i){let n=(t*this.width+r)*4;this.data[n+0]=Math.round(i.r*255/i.a),this.data[n+1]=Math.round(i.g*255/i.a),this.data[n+2]=Math.round(i.b*255/i.a),this.data[n+3]=Math.round(i.a*255)}};function Db(e){let t=new Uint8Array(e.length);for(let r=0;r<e.length;r+=4){let i=e[r+3];t[r+0]=Math.round(e[r+0]*i/255),t[r+1]=Math.round(e[r+1]*i/255),t[r+2]=Math.round(e[r+2]*i/255),t[r+3]=i}return t}Ae("AlphaImage",sS),Ae("RGBAImage",_r);function kL(e){let t={},r=e.resolution||256,i=e.clips?e.clips.length:1,n=e.image||new _r({width:r,height:i});if(!W$e(r))throw Error(`width is not a power of 2 - ${r}`);let a=(s,o,l)=>{t[e.evaluationKey]=l;let u=e.expression.evaluate(t);n.setPixel(s/4/r,o/4,u)};if(e.clips)for(let s=0,o=0;s<i;++s,o+=r*4)for(let l=0,u=0;l<r;l++,u+=4){let c=l/(r-1),{start:d,end:h}=e.clips[s],f=d*(1-c)+h*c;a(o,u,f)}else for(let s=0,o=0;s<r;s++,o+=4){let l=s/(r-1);a(0,o,l)}return n}const Ly="big-fb",M6e=e=>e.type==="heatmap";var I6e=class extends Rs{createBucket(t){return new $L(t)}constructor(t,r){super(t,P6e,r),this.heatmapFbos=new Map,this._updateColorRamp()}_handleSpecialPaintPropertyUpdate(t){t==="heatmap-color"&&this._updateColorRamp()}_updateColorRamp(){let t=this._transitionablePaint._values["heatmap-color"].value.expression;this.colorRamp=kL({expression:t,evaluationKey:"heatmapDensity",image:this.colorRamp}),this.colorRampTexture=null}resize(){this.heatmapFbos.has("big-fb")&&this.heatmapFbos.delete(Ly)}queryRadius(t){return Xd("heatmap-radius",this,t)}queryIntersectsFeature({queryGeometry:t,feature:r,featureState:i,geometry:n,transform:a,pixelsToTileUnits:s,unwrappedTileID:o,getElevation:l}){return wL({queryGeometry:t,size:this.paint.get("heatmap-radius").evaluate(r,i)*s,transform:a,unwrappedTileID:o,getElevation:l},n)}hasOffscreenPass(){return this.paint.get("heatmap-opacity")!==0&&!this.isHidden()}};let A6e;const D6e=()=>A6e||(A6e=new Mi({"hillshade-illumination-direction":new Pe(ce.paint_hillshade["hillshade-illumination-direction"],"hillshade-illumination-direction"),"hillshade-illumination-altitude":new Pe(ce.paint_hillshade["hillshade-illumination-altitude"],"hillshade-illumination-altitude"),"hillshade-illumination-anchor":new Pe(ce.paint_hillshade["hillshade-illumination-anchor"],"hillshade-illumination-anchor"),"hillshade-exaggeration":new Pe(ce.paint_hillshade["hillshade-exaggeration"],"hillshade-exaggeration"),"hillshade-shadow-color":new Pe(ce.paint_hillshade["hillshade-shadow-color"],"hillshade-shadow-color"),"hillshade-highlight-color":new Pe(ce.paint_hillshade["hillshade-highlight-color"],"hillshade-highlight-color"),"hillshade-accent-color":new Pe(ce.paint_hillshade["hillshade-accent-color"],"hillshade-accent-color"),"hillshade-method":new Pe(ce.paint_hillshade["hillshade-method"],"hillshade-method"),resampling:new Pe(ce.paint_hillshade.resampling,"resampling")}));var R6e={get paint(){return D6e()}};const O6e=e=>e.type==="hillshade";var L6e=class extends Rs{constructor(t,r){super(t,R6e,r),this.recalculate({zoom:0,zoomHistory:{}},void 0)}getIlluminationProperties(){let t=this.paint.get("hillshade-illumination-direction").values,r=this.paint.get("hillshade-illumination-altitude").values,i=this.paint.get("hillshade-highlight-color").values,n=this.paint.get("hillshade-shadow-color").values,a=Math.max(t.length,r.length,i.length,n.length);t=t.concat(Array(a-t.length).fill(t.at(-1))),r=r.concat(Array(a-r.length).fill(r.at(-1))),i=i.concat(Array(a-i.length).fill(i.at(-1))),n=n.concat(Array(a-n.length).fill(n.at(-1)));let s=r.map(zr);return{directionRadians:t.map(zr),altitudeRadians:s,shadowColor:n,highlightColor:i}}hasOffscreenPass(){return this.paint.get("hillshade-exaggeration")!==0&&!this.isHidden()}};let F6e;const z6e=()=>F6e||(F6e=new Mi({"color-relief-opacity":new Pe(ce["paint_color-relief"]["color-relief-opacity"],"color-relief-opacity"),"color-relief-color":new uv(ce["paint_color-relief"]["color-relief-color"],"color-relief-color"),resampling:new Pe(ce["paint_color-relief"].resampling,"resampling")}));var N6e={get paint(){return z6e()}};function Rb(e){return"data"in e}var Hr=class{constructor(t,r,i,n){this.context=t,this.format=i,this.texture=t.gl.createTexture(),this._ownedHandle=this.texture,this.update(r,n)}update(t,r,i){var c;let{width:n,height:a}=t,s=(((c=this.size)==null?void 0:c[0])!==n||this.size[1]!==a)&&!i,{context:o}=this,{gl:l}=o;this.useMipmap=!!(r!=null&&r.useMipmap),s&&this.size&&this.format===l.RGBA&&(l.deleteTexture(this.texture),this.texture=l.createTexture(),this._ownedHandle=this.texture),l.bindTexture(l.TEXTURE_2D,this.texture),o.pixelStoreUnpackFlipY.set(!1),o.pixelStoreUnpack.set(1);let u=this.format===l.RGBA&&(r==null?void 0:r.premultiply)!==!1;if(s)if(this.size=[n,a],this.format===l.RGBA&&n>0&&a>0){let d=this.useMipmap?Math.floor(Math.log2(Math.max(n,a)))+1:1;if(l.texStorage2D(l.TEXTURE_2D,d,l.RGBA8,n,a),Rb(t)){o.pixelStoreUnpackPremultiplyAlpha.set(!1);let{data:h}=t;u&&h&&(h=Db(h)),h&&l.texSubImage2D(l.TEXTURE_2D,0,0,0,n,a,l.RGBA,l.UNSIGNED_BYTE,h)}else o.pixelStoreUnpackPremultiplyAlpha.set(u),l.texSubImage2D(l.TEXTURE_2D,0,0,0,l.RGBA,l.UNSIGNED_BYTE,t)}else Rb(t)?(o.pixelStoreUnpackPremultiplyAlpha.set(!1),this._uploadRawData(t,u,n,a,l)):(o.pixelStoreUnpackPremultiplyAlpha.set(u),this._uploadDomImage(t,l));else{let{x:d,y:h}=i||{x:0,y:0};Rb(t)?(o.pixelStoreUnpackPremultiplyAlpha.set(!1),this._updateRawData(t,u,d,h,n,a,l)):(o.pixelStoreUnpackPremultiplyAlpha.set(u),this._updateDomImage(t,d,h,l))}this.useMipmap&&l.generateMipmap(l.TEXTURE_2D),o.pixelStoreUnpackFlipY.setDefault(),o.pixelStoreUnpack.setDefault(),o.pixelStoreUnpackPremultiplyAlpha.setDefault()}_uploadDomImage(t,r){r.texImage2D(r.TEXTURE_2D,0,this.format,this.format,r.UNSIGNED_BYTE,t)}_uploadRawData(t,r,i,n,a){let{data:s}=t;r&&s&&(s=Db(s)),a.texImage2D(a.TEXTURE_2D,0,this.format,i,n,0,this.format,a.UNSIGNED_BYTE,s)}_updateDomImage(t,r,i,n){n.texSubImage2D(n.TEXTURE_2D,0,r,i,n.RGBA,n.UNSIGNED_BYTE,t)}_updateRawData(t,r,i,n,a,s,o){let{data:l}=t;r&&l&&(l=Db(l)),o.texSubImage2D(o.TEXTURE_2D,0,i,n,a,s,o.RGBA,o.UNSIGNED_BYTE,l)}bind(t,r,i){let{context:n}=this,{gl:a}=n;this.texture!==this._ownedHandle&&(this.texture=this._ownedHandle),a.bindTexture(a.TEXTURE_2D,this.texture),i===a.LINEAR_MIPMAP_NEAREST&&!this.useMipmap&&(i=a.LINEAR),t!==this.filter&&(a.texParameteri(a.TEXTURE_2D,a.TEXTURE_MAG_FILTER,t),a.texParameteri(a.TEXTURE_2D,a.TEXTURE_MIN_FILTER,i||t),this.filter=t),r!==this.wrap&&(a.texParameteri(a.TEXTURE_2D,a.TEXTURE_WRAP_S,r),a.texParameteri(a.TEXTURE_2D,a.TEXTURE_WRAP_T,r),this.wrap=r)}destroy(){let{gl:t}=this.context;t.deleteTexture(this.texture),this.texture=null,this._ownedHandle=null}},Bo,B6e=(Bo=class{constructor(t,r,i,n=1,a=1,s=1,o=0){if(this.uid=t,r.height!==r.width)throw RangeError("DEM tiles must be square");if(i&&!["mapbox","terrarium","custom"].includes(i)){vr(`"${i}" is not a valid encoding type. Valid types include "mapbox", "terrarium" and "custom".`);return}this.stride=r.height;let l=this.dim=r.height-2;switch(this.data=new Uint32Array(r.data.buffer),Bo.byteViewCache.set(this,new Uint8Array(this.data.buffer)),i){case"terrarium":this.redFactor=256,this.greenFactor=1,this.blueFactor=1/256,this.baseShift=32768;break;
741case"custom":this.redFactor=n,this.greenFactor=a,this.blueFactor=s,this.baseShift=o;break;default:this.redFactor=6553.6,this.greenFactor=25.6,this.blueFactor=.1,this.baseShift=1e4}for(let c=0;c<l;c++)this.data[this._idx(-1,c)]=this.data[this._idx(0,c)],this.data[this._idx(l,c)]=this.data[this._idx(l-1,c)],this.data[this._idx(c,-1)]=this.data[this._idx(c,0)],this.data[this._idx(c,l)]=this.data[this._idx(c,l-1)];this.data[this._idx(-1,-1)]=this.data[this._idx(0,0)],this.data[this._idx(l,-1)]=this.data[this._idx(l-1,0)],this.data[this._idx(-1,l)]=this.data[this._idx(0,l-1)],this.data[this._idx(l,l)]=this.data[this._idx(l-1,l-1)];let u=this._getByteView();this.min=2**53-1,this.max=-9007199254740991;for(let c=0;c<l;c++)for(let d=0;d<l;d++){let h=this._idx(c,d)*4,f=this._unpackAtIndex(u,h);f>this.max&&(this.max=f),f<this.min&&(this.min=f)}}get(t,r){let i=this._getByteView(),n=this._idx(t,r)*4;return this._unpackAtIndex(i,n)}sampleBilinear(t,r){let i=Math.floor(t),n=Math.floor(r);if(i<-1||i>=this.dim||n<-1||n>=this.dim)throw RangeError(`Out of range source coordinates for DEM data. x: ${t}, y: ${r}, dim: ${this.dim}`);let a=this._getByteView(),s=((n+1)*this.stride+i+1)*4,o=this.stride*4,l=t-i,u=r-n,c=this._unpackAtIndex(a,s),d=this._unpackAtIndex(a,s+4),h=this._unpackAtIndex(a,s+o),f=this._unpackAtIndex(a,s+o+4);return c*(1-l)*(1-u)+d*l*(1-u)+h*(1-l)*u+f*l*u}getUnpackVector(){return[this.redFactor,this.greenFactor,this.blueFactor,this.baseShift]}_idx(t,r){if(t<-1||t>=this.dim+1||r<-1||r>=this.dim+1)throw RangeError(`Out of range source coordinates for DEM data. x: ${t}, y: ${r}, dim: ${this.dim}`);return(r+1)*this.stride+(t+1)}unpack(t,r,i){return t*this.redFactor+r*this.greenFactor+i*this.blueFactor-this.baseShift}pack(t){return EL(t,this.getUnpackVector())}getPixels(){return new _r({width:this.stride,height:this.stride},this._getByteView())}backfillBorder(t,r,i){if(this.dim!==t.dim)throw Error("dem dimension mismatch");let n=r*this.dim,a=r*this.dim+this.dim,s=i*this.dim,o=i*this.dim+this.dim;switch(r){case-1:n=a-1;break;case 1:a=n+1}switch(i){case-1:s=o-1;break;case 1:o=s+1}let l=-r*this.dim,u=-i*this.dim;for(let c=s;c<o;c++)for(let d=n;d<a;d++)this.data[this._idx(d,c)]=t.data[this._idx(d+l,c+u)]}_getByteView(){let t=Bo.byteViewCache.get(this);return(t==null?void 0:t.buffer)!==this.data.buffer&&(t=new Uint8Array(this.data.buffer),Bo.byteViewCache.set(this,t)),t}_unpackAtIndex(t,r){return this.unpack(t[r],t[r+1],t[r+2])}},Bo.byteViewCache=new WeakMap,Bo);function EL(e,t){let r=t[0],i=t[1],n=t[2],a=t[3],s=Math.min(r,i,n),o=Math.round((e+a)/s);return{r:Math.floor(o*s/r)%256,g:Math.floor(o*s/i)%256,b:Math.floor(o*s/n)%256}}Ae("DEMData",B6e);const j6e=e=>e.type==="color-relief";var U6e=class extends Rs{constructor(t,r){super(t,N6e,r)}_createColorRamp(t){let r={elevationStops:[],colorStops:[]},i=this._transitionablePaint._values["color-relief-color"].value.expression;if(i instanceof Em&&i._styleExpression.expression instanceof Ts){this.colorRampExpression=i;let s=i._styleExpression.expression;r.elevationStops=s.labels,r.colorStops=[];for(let o of r.elevationStops)r.colorStops.push(s.evaluate({globals:{elevation:o}}))}if(r.elevationStops.length<1&&(r.elevationStops=[0],r.colorStops=[at.transparent]),r.elevationStops.length<2&&(r.elevationStops.push(r.elevationStops[0]+1),r.colorStops.push(r.colorStops[0])),r.elevationStops.length<=t)return r;let n={elevationStops:[],colorStops:[]},a=(r.elevationStops.length-1)/(t-1);for(let s=0;s<r.elevationStops.length-.5;s+=a)n.elevationStops.push(r.elevationStops[Math.round(s)]),n.colorStops.push(r.colorStops[Math.round(s)]);return vr(`Too many colors in specification of ${this.id} color-relief layer, may not render properly. Max possible colors: ${t}, provided: ${r.elevationStops.length}`),n}_colorRampChanged(){return this.colorRampExpression!=this._transitionablePaint._values["color-relief-color"].value.expression}getColorRampTextures(t,r,i){if(this.colorRampTextures&&!this._colorRampChanged())return this.colorRampTextures;let n=this._createColorRamp(r),a=new _r({width:n.colorStops.length,height:1}),s=new _r({width:n.colorStops.length,height:1});for(let o=0;o<n.elevationStops.length;o++){let l=EL(n.elevationStops[o],i);s.setPixel(0,o,new at(l.r/255,l.g/255,l.b/255,1)),a.setPixel(0,o,n.colorStops[o])}return this.colorRampTextures={elevationTexture:new Hr(t,s,t.gl.RGBA),colorTexture:new Hr(t,a,t.gl.RGBA)},this.colorRampTextures}hasOffscreenPass(){return!this.isHidden()&&!!this.colorRampTextures}};const V6e=Ar([{name:"a_pos",components:2,type:"Int16"}],4),q6e=V6e.members;function Fy(e,t,r){let i=r.patternDependencies,n=!1;for(let a of t){let s=a.paint.get(`${e}-pattern`);s.isConstant()||(n=!0);let o=s.constantOr(null);o&&(n=!0,i[o.to]=!0,i[o.from]=!0)}return n}
vendor: 4,302 bytes, line 741
741function oS(e,t,r,i,n){let{zoom:a}=i,s=n.patternDependencies;for(let o of t){let l=o.paint.get(`${e}-pattern`).value;if(l.kind!=="constant"){let u=l.evaluate({zoom:a-1},r,{},n.availableImages),c=l.evaluate({zoom:a},r,{},n.availableImages),d=l.evaluate({zoom:a+1},r,{},n.availableImages);u=u!=null&&u.name?u.name:u,c=c!=null&&c.name?c.name:c,d=d!=null&&d.name?d.name:d,s[u]=!0,s[c]=!0,s[d]=!0,r.patterns[o.id]={min:u,mid:c,max:d}}}return r}const Rm=new Set;let Iw=!1;function G6e(e,t,r=2){let i=t&&t.length,n=i?t[0]*r:e.length;Rm.size&&Rm.clear();let a=PL(e,0,n,r,!0),s=[];if(!a||a.next===a.prev)return s;let o=0,l=0,u=0;if(i&&(a=K6e(e,t,a,r)),e.length>80*r){o=e[0],l=e[1];let c=o,d=l;for(let h=r;h<n;h+=r){let f=e[h],p=e[h+1];f<o&&(o=f),p<l&&(l=p),f>c&&(c=f),p>d&&(d=p)}u=Math.max(c-o,d-l),u=u===0?0:32767/u}return Aw(a,s,o,l,u),s}function PL(e,t,r,i,n){let a=null;if(n===uCe(e,t,r,i)>0)for(let s=t;s<r;s+=i)a=b8(s/i|0,e[s],e[s+1],a);else for(let s=r-i;s>=t;s-=i)a=b8(s/i|0,e[s],e[s+1],a);return a&&Om(a,a.next)&&(Fm(a),a=a.next),a}function kc(e,t=e){let r=t===e,i=e,n;do n=!1,i!==i.next&&(Rm.size===0||!Rm.has(i))&&(Om(i,i.next)||ci(i.prev,i,i.next)===0)?((r||i===t)&&(t=i.prev),Iw=!0,Fm(i),i=i.prev,n=!0):(r||i!==t)&&(i=i.next,n=!r);while(n||i!==t);return t}function Aw(e,t,r,i,n){n&&iCe(e,r,i,n);let a=e,s=!1;for(;e.prev!==e.next;){let o=e.prev,l=e.next;if(ci(o,e,l)<0&&(n?Y6e(e,r,i,n):H6e(e))){t.push(o.i,e.i,l.i),Fm(e),e=l,a=l;continue}if(e=l,e===a){if(Iw=!1,e=kc(e),Iw){a=e;continue}if(!s){e=W6e(e,t),a=e,s=!0;continue}Z6e(e,t,r,i,n);break}}}function H6e(e){let t=e.prev,r=e,i=e.next,n=t.x,a=r.x,s=i.x,o=t.y,l=r.y,u=i.y,c=Math.min(n,a,s),d=Math.min(o,l,u),h=Math.max(n,a,s),f=Math.max(o,l,u),p=i.next;for(;p!==t;){if(p.x>=c&&p.x<=h&&p.y>=d&&p.y<=f&&(n!==p.x||o!==p.y)&&Ny(n,o,a,l,s,u,p.x,p.y)&&ci(p.prev,p,p.next)>=0)return!1;p=p.next}return!0}function Y6e(e,t,r,i){let n=e.prev,a=e,s=e.next,o=n.x,l=a.x,u=s.x,c=n.y,d=a.y,h=s.y,f=Math.min(o,l,u),p=Math.min(c,d,h),m=Math.max(o,l,u),g=Math.max(c,d,h),v=Lw(f,p,t,r,i),x=Lw(m,g,t,r,i),_=e.prevZ;for(;_&&_.z>=v;){if(_.x>=f&&_.x<=m&&_.y>=p&&_.y<=g&&_!==s&&(o!==_.x||c!==_.y)&&Ny(o,c,l,d,u,h,_.x,_.y)&&ci(_.prev,_,_.next)>=0)return!1;_=_.prevZ}let y=e.nextZ;for(;y&&y.z<=x;){if(y.x>=f&&y.x<=m&&y.y>=p&&y.y<=g&&y!==s&&(o!==y.x||c!==y.y)&&Ny(o,c,l,d,u,h,y.x,y.y)&&ci(y.prev,y,y.next)>=0)return!1;y=y.nextZ}return!0}function W6e(e,t){let r=e,i=!1;do{let n=r.prev,a=r.next.next;IL(n,r,r.next,a,!1)&&Lm(n,a)&&Lm(a,n)&&(t.push(n.i,r.i,a.i),Fm(r),Fm(r.next),r=e=a,i=!0),r=r.next}while(r!==e);return i?kc(r):r}function Z6e(e,t,r,i,n){let a=e;do{let s=a.next.next;for(;s!==a.prev;){if(a.i!==s.i&&sCe(a,s)){let o=AL(a,s);a=kc(a,a.next),o=kc(o,o.next),Aw(a,t,r,i,n),Aw(o,t,r,i,n);return}s=s.next}a=a.next}while(a!==e)}let Dw=!1;function K6e(e,t,r,i){let n=[];for(let a=0,s=t.length;a<s;a++){let o=PL(e,t[a]*i,a<s-1?t[a+1]*i:e.length,i,!1);o===o.next&&Rm.add(o),n.push(aCe(o))}n.sort(X6e),Q6e(e.length/i,t.length),ML(r,r),Dw=!0;for(let a=0;a<n.length;a++)r=J6e(n[a],r);return Dw=!1,kc(r)}function X6e(e,t){return e.x-t.x||e.y-t.y||(e.next.y-e.y)/(e.next.x-e.x)-(t.next.y-t.y)/(t.next.x-t.x)}function J6e(e,t){let r=tCe(e,t);if(!r)return t;let i=AL(r,e),n=i.next;return ML(r,n.next),kc(i,i.next),kc(r,r.next)}let Ur=new Float64Array,zy=0;const Rw=[],Ow=[];function Q6e(e,t){let r=Math.ceil((e+2*t)/16)+t+2;Ur.length<r*4&&(Ur=new Float64Array(r*4)),zy=0}function ML(e,t){let r=e;do{let i=zy++;Rw[i]=r;let n=1/0,a=1/0,s=-1/0,o=-1/0,l=0;do{let c=r.next;r.z=i,r.x<n&&(n=r.x),r.x>s&&(s=r.x),r.y<a&&(a=r.y),r.y>o&&(o=r.y),c.x<n&&(n=c.x),c.x>s&&(s=c.x),c.y<a&&(a=c.y),c.y>o&&(o=c.y),r=c}while(++l<16&&r!==t);Ow[i]=r;let u=i*4;Ur[u]=n,Ur[u+1]=a,Ur[u+2]=s,Ur[u+3]=o}while(r!==t)}function eCe(e,t){let r=e.z*4;t.x<Ur[r]&&(Ur[r]=t.x),t.y<Ur[r+1]&&(Ur[r+1]=t.y),t.x>Ur[r+2]&&(Ur[r+2]=t.x),t.y>Ur[r+3]&&(Ur[r+3]=t.y)}function y8(e){let t=Ow[e];for(;t.prev.next!==t;)t=t.next;return Ow[e]=t,t}function v8(e){let t=Rw[e];for(;t.prev.next!==t;)t=t.next;return Rw[e]=t,t}function tCe(e,t){let r=t,i=e.x,n=e.y,a=-1/0,s;if(Om(e,r))return r;for(let h=0,f=0;h<zy;h++,f+=4){if(n<Ur[f+1]||n>Ur[f+3]||Ur[f]>i||Ur[f+2]<=a)continue;let p=y8(h);r=v8(h);do{if(r.prev.next===r){if(Om(e,r.next))return r.next;if(n<=r.y&&n>=r.next.y&&r.next.y!==r.y){let m=r.x+(n-r.y)*(r.next.x-r.x)/(r.next.y-r.y
vendor: 3,161 bytes, line 741
741);if(m<=i&&m>a&&(a=m,s=r.x<r.next.x?r:r.next,m===i))return s}}r=r.next}while(r!==p)}if(!s)return null;let o=s.x,l=s.y,u=Math.min(n,l),c=Math.max(n,l),d=1/0;for(let h=0,f=0;h<zy;h++,f+=4){if(Ur[f+2]<o||Ur[f]>i||Ur[f+3]<u||Ur[f+1]>c)continue;let p=y8(h);r=v8(h);do{if(r.prev.next===r&&i>=r.x&&r.x>=o&&i!==r.x&&Ny(n<l?i:a,n,o,l,n<l?a:i,n,r.x,r.y)){let m=Math.abs(n-r.y)/(i-r.x);(Lm(r,e)||r.y===n&&r.next.y===n&&r.next.x>i)&&(m<d||m===d&&(r.x>s.x||r.x===s.x&&rCe(s,r)))&&(s=r,d=m)}r=r.next}while(r!==p)}return s}function rCe(e,t){return ci(e.prev,e,t.prev)<0&&ci(t.next,e,e.next)<0}const Fa=[];let kf=[],Cu=new Uint32Array,Ef=new Uint32Array;const Pf=new Uint32Array(256);function iCe(e,t,r,i){let n=e,a=0;do n.z=Lw(n.x,n.y,t,r,i),Fa[a++]=n,n=n.next;while(n!==e);nCe(a);let s=null;for(let o=0;o<a;o++){let l=Fa[o];l.prevZ=s,s&&(s.nextZ=l),s=l}s.nextZ=null}function nCe(e){if(e<=32){for(let t=1;t<e;t++){let r=Fa[t],i=r.z,n=t-1;for(;n>=0&&Fa[n].z>i;)Fa[n+1]=Fa[n],n--;Fa[n+1]=r}return}Cu.length<e&&(Cu=new Uint32Array(e),Ef=new Uint32Array(e),kf=Array(e));for(let t=0;t<e;t++)Cu[t]=Fa[t].z;x0(e,Fa,Cu,kf,Ef,0),x0(e,kf,Ef,Fa,Cu,8),x0(e,Fa,Cu,kf,Ef,16),x0(e,kf,Ef,Fa,Cu,24)}function x0(e,t,r,i,n,a){Pf.fill(0);for(let o=0;o<e;o++)Pf[r[o]>>>a&255]++;let s=0;for(let o=0;o<256;o++){let l=Pf[o];Pf[o]=s,s+=l}for(let o=0;o<e;o++){let l=r[o],u=Pf[l>>>a&255]++;i[u]=t[o],n[u]=l}}function Lw(e,t,r,i,n){return e=(e-r)*n|0,t=(t-i)*n|0,e=(e|e<<8)&16711935,e=(e|e<<4)&252645135,e=(e|e<<2)&858993459,e=(e|e<<1)&1431655765,t=(t|t<<8)&16711935,t=(t|t<<4)&252645135,t=(t|t<<2)&858993459,t=(t|t<<1)&1431655765,e|t<<1}function aCe(e){let t=e,r=e;do(t.x<r.x||t.x===r.x&&t.y<r.y)&&(r=t),t=t.next;while(t!==e);return r}function Ny(e,t,r,i,n,a,s,o){return(n-s)*(t-o)>=(e-s)*(a-o)&&(e-s)*(i-o)>=(r-s)*(t-o)&&(r-s)*(a-o)>=(n-s)*(i-o)}function sCe(e,t){let r=Om(e,t)&&ci(e.prev,e,e.next)>0&&ci(t.prev,t,t.next)>0;return e.next.i!==t.i&&(r||Lm(e,t)&&Lm(t,e)&&(ci(e.prev,e,t.prev)!==0||ci(e,t.prev,t)!==0))&&!oCe(e,t)&&(r||lCe(e,t))}function ci(e,t,r){return(t.y-e.y)*(r.x-t.x)-(t.x-e.x)*(r.y-t.y)}function Om(e,t){return e.x===t.x&&e.y===t.y}function IL(e,t,r,i,n=!0){let a=ci(e,t,r),s=ci(e,t,i),o=ci(r,i,e),l=ci(r,i,t);return(a>0&&s<0||a<0&&s>0)&&(o>0&&l<0||o<0&&l>0)?!0:n?!!(a===0&&w0(e,r,t)||s===0&&w0(e,i,t)||o===0&&w0(r,e,i)||l===0&&w0(r,t,i)):!1}function w0(e,t,r){return t.x<=Math.max(e.x,r.x)&&t.x>=Math.min(e.x,r.x)&&t.y<=Math.max(e.y,r.y)&&t.y>=Math.min(e.y,r.y)}function oCe(e,t){let r=Math.min(e.x,t.x),i=Math.max(e.x,t.x),n=Math.min(e.y,t.y),a=Math.max(e.y,t.y),s=e;do{let o=s.next;if(s.x>i&&o.x>i||s.x<r&&o.x<r||s.y>a&&o.y>a||s.y<n&&o.y<n){s=o;continue}if(s.i!==e.i&&o.i!==e.i&&s.i!==t.i&&o.i!==t.i&&IL(s,o,e,t))return!0;s=o}while(s!==e);return!1}function Lm(e,t){return ci(e.prev,e,e.next)<0?ci(e,t,e.next)>=0&&ci(e,e.prev,t)>=0:ci(e,t,e.prev)<0||ci(e,e.next,t)<0}function lCe(e,t){let r=e,i=!1,n=(e.x+t.x)/2,a=(e.y+t.y)/2;do{let s=r.next;r.y>a!=s.y>a&&n<(s.x-r.x)*(a-r.y)/(s.y-r.y)+r.x&&(i=!i),r=s}while(r!==e);return i}function AL(e,t){let r=Fw(e.i,e.x,e.y),i=Fw(t.i,t.x,t.y),n=e.next,a=t.prev;return e.next=t,t.prev=e,r.next=n,n.prev=r,i.next=r,r.prev=i,a.next=i,i.prev=a,i}
vendor: 6,750 bytes, line 741
741function b8(e,t,r,i){let n=Fw(e,t,r);return i?(n.next=i.next,n.prev=i,i.next.prev=n,i.next=n):(n.prev=n,n.next=n),n}function Fm(e){e.next.prev=e.prev,e.prev.next=e.next,e.prevZ&&(e.prevZ.nextZ=e.nextZ),e.nextZ&&(e.nextZ.prevZ=e.prevZ),Dw&&eCe(e.prev,e.next)}function Fw(e,t,r){return{i:e,x:t,y:r,prev:null,next:null,z:0,prevZ:null,nextZ:null}}function uCe(e,t,r,i){let n=0;for(let a=t,s=r-i;a<r;a+=i)n+=(e[s]-e[a])*(e[a+1]+e[s+1]),s=a;return n}var zo=class{constructor(e,t){if(t>e)throw Error("Min granularity must not be greater than base granularity.");this._baseZoomGranularity=e,this._minGranularity=t}getGranularityForZoomLevel(e){let t=1<<e;return Math.max(Math.floor(this._baseZoomGranularity/t),this._minGranularity,1)}},fc,lS=(fc=class{constructor(t){this.fill=t.fill,this.line=t.line,this.tile=t.tile,this.stencil=t.stencil,this.circle=t.circle}},fc.noSubdivision=new fc({fill:new zo(0,0),line:new zo(0,0),tile:new zo(0,0),stencil:new zo(0,0),circle:1}),fc);Ae("SubdivisionGranularityExpression",zo),Ae("SubdivisionGranularitySetting",lS);const Dp=-32768,Rp=32767;var cCe=class{constructor(e,t){this._vertexBuffer=[],this._vertexDictionary=new Map,this._used=!1,this._granularity=e,this._granularityCellSize=ye/e,this._canonical=t}_getKey(e,t){return e+=32768,t+=32768,e<<16|t<<0}_vertexToIndex(e,t){if(e<-32768||t<-32768||e>32767||t>32767)throw Error("Vertex coordinates are out of signed 16 bit integer range.");let r=Math.round(e)|0,i=Math.round(t)|0,n=this._getKey(r,i);if(this._vertexDictionary.has(n))return this._vertexDictionary.get(n);let a=this._vertexBuffer.length/2;return this._vertexDictionary.set(n,a),this._vertexBuffer.push(r,i),a}_subdivideTrianglesScanline(e){if(this._granularity<2)return hCe(this._vertexBuffer,e);let t=[],r=e.length;for(let i=0;i<r;i+=3){let n=[e[i+0],e[i+1],e[i+2]],a=[this._vertexBuffer[e[i+0]*2+0],this._vertexBuffer[e[i+0]*2+1],this._vertexBuffer[e[i+1]*2+0],this._vertexBuffer[e[i+1]*2+1],this._vertexBuffer[e[i+2]*2+0],this._vertexBuffer[e[i+2]*2+1]],s=1/0,o=1/0,l=-1/0,u=-1/0;for(let p=0;p<3;p++){let m=a[p*2],g=a[p*2+1];s=Math.min(s,m),l=Math.max(l,m),o=Math.min(o,g),u=Math.max(u,g)}if(s===l||o===u)continue;let c=Math.floor(s/this._granularityCellSize),d=Math.ceil(l/this._granularityCellSize),h=Math.floor(o/this._granularityCellSize),f=Math.ceil(u/this._granularityCellSize);if(c===d&&h===f){t.push(...n);continue}for(let p=h;p<f;p++){let m=this._scanlineGenerateVertexRingForCellRow(p,a,n);fCe(this._vertexBuffer,m,t)}}return t}_scanlineGenerateVertexRingForCellRow(e,t,r){let i=e*this._granularityCellSize,n=i+this._granularityCellSize,a=[];for(let s=0;s<3;s++){let o=t[s*2],l=t[s*2+1],u=t[(s+1)*2%6],c=t[((s+1)*2+1)%6],d=t[(s+2)*2%6],h=t[((s+2)*2+1)%6],f=u-o,p=c-l,m=f===0,g=p===0,v=(i-l)/p,x=(n-l)/p,_=Math.min(v,x),y=Math.max(v,x);if(!g&&(_>=1||y<=0)||g&&(l<i||l>n)){c>=i&&c<=n&&a.push(r[(s+1)%3]);continue}if(!g&&_>0){let S=o+f*_,E=l+p*_;a.push(this._vertexToIndex(S,E))}let w=o+f*Math.max(_,0),$=o+f*Math.min(y,1);if(m||this._generateIntraEdgeVertices(a,o,l,u,c,w,$),!g&&y<1){let S=o+f*y,E=l+p*y;a.push(this._vertexToIndex(S,E))}(g||c>=i&&c<=n)&&a.push(r[(s+1)%3]),!g&&(c<=i||c>=n)&&this._generateInterEdgeVertices(a,o,l,u,c,d,h,$,i,n)}return a}_generateIntraEdgeVertices(e,t,r,i,n,a,s){let o=i-t,l=n-r,u=l===0,c=u?Math.min(t,i):Math.min(a,s),d=u?Math.max(t,i):Math.max(a,s),h=Math.floor(c/this._granularityCellSize)+1,f=Math.ceil(d/this._granularityCellSize)-1;if(u?t<i:a<s)for(let p=h;p<=f;p++){let m=p*this._granularityCellSize,g=r+l*(m-t)/o;e.push(this._vertexToIndex(m,g))}else for(let p=f;p>=h;p--){let m=p*this._granularityCellSize,g=r+l*(m-t)/o;e.push(this._vertexToIndex(m,g))}}_generateInterEdgeVertices(e,t,r,i,n,a,s,o,l,u){let c=n-r,d=a-i,h=s-n,f=(l-n)/h,p=(u-n)/h,m=Math.min(f,p),g=Math.max(f,p),v=i+d*m,x=Math.floor(Math.min(v,o)/this._granularityCellSize)+1,_=Math.ceil(Math.max(v,o)/this._granularityCellSize)-1,y=o<v,w=h===0;if(w&&(s===l||s===u))return;if(w||m>=1||g<=0){let S=t-a,E=r-s,C=(l-s)/E,I=(u-s)/E,P=a+S*Math.min(C,I);x=Math.floor(Math.min(P,o)/this._granularityCellSize)+1,_=Math.ceil(Math.max(P,o)/this._granularityCellSize)-1,y=o<P}let $=c>0?u:l;if(y)for(let S=x;S<=_;S++){let E=S*this._granularityCellSize;e.push(this._vertexToIndex(E,$))}else for(let S=_;S>=x;S--){let E=S*this._granularityCellSize;e.push(this._vertexToIndex(E,$))}}_generateOutline(e){let t=[];for(let r of e){let i=uS(r,this._granularity,!0),n=this._pointArrayToIndices(i),a=[];for(let s=1;s<n.length;s++)a.push(n[s-1]),a.push(n[s]);t.push(a)}return t}_handlePoles(e){let t=!1,r=!1;this._canonical&&(this._canonical.y===0&&(t=!0),this._canonical.y===(1<<this._canonical.z)-1&&(r=!0)),(t||r)&&this._fillPoles(e,t,r)}_ensureNoPoleVertices(){let e=this._vertexBuffer;for(let t=0;t<e.length;t+=2){let r=e[t+1];r===-32768&&(e[t+1]=-32767),r===32767&&(e[t+1]=32766)}}_generatePoleQuad(e,t,r,i,n,a){i>n==(a===-32768)?(e.push(r),e.push(t),e.push(this._vertexToIndex(i,a)),e.push(this._vertexToIndex(n,a)),e.push(r),e.push(this._vertexToIndex(i,a))):(e.push(t),e.push(r),e.push(this._vertexToIndex(i,a)),e.push(r),e.push(this._vertexToIndex(n,a)),e.push(this._vertexToIndex(i,a)))}_fillPoles(e,t,r){let i=this._vertexBuffer,n=ye,a=e.length;for(let s=2;s<a;s+=3){let o=e[s-2],l=e[s-1],u=e[s],c=i[o*2],d=i[o*2+1],h=i[l*2],f=i[l*2+1],p=i[u*2],m=i[u*2+1];t&&(d===0&&f===0&&this._generatePoleQuad(e,o,l,c,h,Dp),f===0&&m===0&&this._generatePoleQuad(e,l,u,h,p,Dp),m===0&&d===0&&this._generatePoleQuad(e,u,o,p,c,Dp)),r&&(d===n&&f===n&&this._generatePoleQuad(e,o,l,c,h,Rp),f===n&&m===n&&this._generatePoleQuad(e,l,u,h,p,Rp),m===n&&d===n&&this._generatePoleQuad(e,u,o,p,c,Rp))}}_initializeVertices(e){for(let t=0;t<e.length;t+=2)this._vertexToIndex(e[t],e[t+1])}subdividePolygonInternal(e,t){var s;if(this._used)throw Error("Subdivision: multiple use not allowed.");this._used=!0;let{flattened:r,holeIndices:i}=dCe(e);this._initializeVertices(r);let n;try{let o=G6e(r,i),l=this._convertIndices(r,o);n=this._subdivideTrianglesScanline(l)}catch(o){console.error(o)}let a=[];return t&&(a=this._generateOutline(e)),this._ensureNoPoleVertices(),this._handlePoles(n),this._granularity>=2&&((s=this._canonical)==null?void 0:s.z)===0&&(n=this._removeTrianglesOutsideTileX(n),a=a.map(o=>this._removeLinesOutsideTileX(o))),{verticesFlattened:this._vertexBuffer,indicesTriangles:n,indicesLineList:a}}_vertexOutsideTileX(e){let t=this._vertexBuffer[e*2];return t<0||t>8192}_removeTrianglesOutsideTileX(e){let t=[];for(let r=0;r<e.length;r+=3)this._vertexOutsideTileX(e[r])||this._vertexOutsideTileX(e[r+1])||this._vertexOutsideTileX(e[r+2])||t.push(e[r],e[r+1],e[r+2]);return t}_removeLinesOutsideTileX(e){let t=[];for(let r=0;r<e.length;r+=2)this._vertexOutsideTileX(e[r])||this._vertexOutsideTileX(e[r+1])||t.pu
vendor: 4,365 bytes, line 741
741sh(e[r],e[r+1]);return t}_convertIndices(e,t){let r=[];for(let i of t){let n=e[i*2],a=e[i*2+1];r.push(this._vertexToIndex(n,a))}return r}_pointArrayToIndices(e){let t=[];for(let r of e)t.push(this._vertexToIndex(r.x,r.y));return t}};function DL(e,t,r,i=!0){return new cCe(r,t).subdividePolygonInternal(e,i)}function uS(e,t,r=!1){if(!e||e.length<1||e.length<2)return[];let i=e[0],n=e[e.length-1],a=r&&(i.x!==n.x||i.y!==n.y);if(t<2)return a?[...e,e[0]]:[...e];let s=Math.floor(ye/t),o=[];o.push(new de(e[0].x,e[0].y));let l=e.length,u=a?l:l-1;for(let c=0;c<u;c++){let d=e[c],h=c<l-1?e[c+1]:e[0],f=d.x,p=d.y,m=h.x,g=h.y,v=f!==m,x=p!==g;if(!v&&!x)continue;let _=m-f,y=g-p,w=Math.abs(_),$=Math.abs(y),S=f,E=p;for(;;){let I=_>0?(Math.floor(S/s)+1)*s:(Math.ceil(S/s)-1)*s,P=y>0?(Math.floor(E/s)+1)*s:(Math.ceil(E/s)-1)*s,T=Math.abs(S-I),D=Math.abs(E-P),A=Math.abs(S-m),z=Math.abs(E-g),R=v?T/w:1/0,O=x?D/$:1/0;if((A<=T||!v)&&(z<=D||!x))break;if(R<O&&v||!x){S=I,E+=y*R;let V=new de(S,Math.round(E));(o[o.length-1].x!==V.x||o[o.length-1].y!==V.y)&&o.push(V)}else{S+=_*O,E=P;let V=new de(Math.round(S),E);(o[o.length-1].x!==V.x||o[o.length-1].y!==V.y)&&o.push(V)}}let C=new de(m,g);(o[o.length-1].x!==C.x||o[o.length-1].y!==C.y)&&o.push(C)}return o}function dCe(e){let t=[],r=[];for(let i of e)if(i.length!==0){i!==e[0]&&t.push(r.length/2);for(let n of i)r.push(n.x),r.push(n.y)}return{flattened:r,holeIndices:t}}function hCe(e,t){let r=[];for(let i=0;i<t.length;i+=3){let n=t[i],a=t[i+1],s=t[i+2],o=e[n*2],l=e[n*2+1],u=e[a*2],c=e[a*2+1],d=e[s*2],h=e[s*2+1],f=u-o,p=c-l,m=d-o;f*(h-l)-p*m>0?(r.push(n),r.push(s),r.push(a)):(r.push(n),r.push(a),r.push(s))}return r}function fCe(e,t,r){if(t.length===0)throw Error("Subdivision vertex ring is empty.");let i=0,n=e[t[0]*2];for(let l=1;l<t.length;l++){let u=e[t[l]*2];u<n&&(n=u,i=l)}let a=t.length,s=i,o=(s+1)%a;for(;;){let l=s-1>=0?s-1:a-1,u=(o+1)%a,c=e[t[l]*2],d=e[t[l]*2+1],h=e[t[u]*2],f=e[t[u]*2+1],p=e[t[s]*2],m=e[t[s]*2+1],g=e[t[o]*2],v=e[t[o]*2+1],x=!1;if(c<h)x=!0;else if(c>h)x=!1;else{let _=v-m,y=-(g-p),w=m<v?1:-1;((c-p)*_+(d-m)*y)*w>((h-p)*_+(f-m)*y)*w&&(x=!0)}if(x){let _=t[l],y=t[s],w=t[o];_!==y&&_!==w&&y!==w&&r.push(w,y,_),s--,s<0&&(s=a-1)}else{let _=t[u],y=t[s],w=t[o];_!==y&&_!==w&&y!==w&&r.push(w,y,_),o++,o>=a&&(o=0)}if(l===u)break}}function RL(e,t,r,i,n,a,s,o,l){let u=n.length/2,c=s&&o&&l;if(u<$r.MAX_VERTEX_ARRAY_LENGTH){let d=t.prepareSegment(u,r,i),h=d.vertexLength;for(let m=0;m<a.length;m+=3)i.emplaceBack(h+a[m],h+a[m+1],h+a[m+2]);d.vertexLength+=u,d.primitiveLength+=a.length/3;let f,p;c&&(p=s.prepareSegment(u,r,o),f=p.vertexLength,p.vertexLength+=u);for(let m=0;m<n.length;m+=2)e(n[m],n[m+1]);if(c)for(let m of l){for(let g=1;g<m.length;g+=2)o.emplaceBack(f+m[g-1],f+m[g]);p.primitiveLength+=m.length/2}}else pCe(t,r,i,n,a,e),c&&mCe(s,r,o,n,l,e),t.forceNewSegmentOnNextPrepare(),s==null||s.forceNewSegmentOnNextPrepare()}function Op(e,t,r,i,n,a,s){if(a){let o=i.count;return r(t[n*2],t[n*2+1]),e[n]=i.count,i.count++,s.vertexLength++,o}return e[n]}function pCe(e,t,r,i,n,a){let s=[];for(let d=0;d<i.length/2;d++)s.push(-1);let o={count:0},l=0,u=e.getOrCreateLatestSegment(t,r),c=u.vertexLength;for(let d=2;d<n.length;d+=3){let h=n[d-2],f=n[d-1],p=n[d],m=s[h]<l,g=s[f]<l,v=s[p]<l,x=+!!m+ +!!g+ +!!v;u.vertexLength+x>$r.MAX_VERTEX_ARRAY_LENGTH&&(u=e.createNewSegment(t,r),l=o.count,m=!0,g=!0,v=!0,c=0);let _=Op(s,i,a,o,h,m,u),y=Op(s,i,a,o,f,g,u),w=Op(s,i,a,o,p,v,u);r.emplaceBack(c+_-l,c+y-l,c+w-l),u.primitiveLength++}}function mCe(e,t,r,i,n,a){let s=[];for(let d=0;d<i.length/2;d++)s.push(-1);let o={count:0},l=0,u=e.getOrCreateLatestSegment(t,r),c=u.vertexLength;for(let d of n)for(let h=1;h<d.length;h+=2){let f=d[h-1],p=d[h],m=s[f]<l,g=s[p]<l,v=+!!m+ +!!g;u.vertexLength+v>$r.MAX_VERTEX_ARRAY_LENGTH&&(u=e.createNewSegment(t,r),l=o.count,m=!0,g=!0,c=0);let x=Op(s,i,a,o,f,m,u),_=Op(s,i,a,o,p,g,u);r.emplaceBack(c+x-l,c+_-l),u.primitiveLength++}}var OL=class{constructor(e){this.zoom=e.zoom,this.overscaling=e.overscaling,this.layers=e.layers,this.layerIds=this.layers.map(t=>t.id),this.index=e.index,this.hasDependencies=!1,this.patternFeatures=[],this.layoutVertexArray=new NTe,this.indexArray=new go,this.indexArray2=new Cw,this.programConfigurations=new Cc(e.layers,e.zoom),this.segments=new $r,this.segments2=new $r,this.stateDependentLayerIds=this.layers.filter(t=>t.isStateDependent()).map(t=>
vendor: 9,811 bytes, line 741
741t.id)}populate(e,t,r){this.hasDependencies=Fy("fill",this.layers,t);let i=this.layers[0].layout.get("fill-sort-key"),n=!i.isConstant(),a=[],s=new Tr(this.zoom),o=this.layers[0]._featureFilter.needGeometry;for(let{feature:l,id:u,index:c,sourceLayerIndex:d}of e){let h=Bc(l,o);if(!this.layers[0]._featureFilter.filter(s,h,r))continue;let f=n?i.evaluate(h,{},r,t.availableImages):void 0,p={id:u,properties:l.properties,type:l.type,sourceLayerIndex:d,index:c,geometry:o?h.geometry:Nc(l),patterns:{},sortKey:f};a.push(p)}n&&a.sort((l,u)=>l.sortKey-u.sortKey);for(let l of a){let{geometry:u,index:c,sourceLayerIndex:d}=l;if(this.hasDependencies){let f=oS("fill",this.layers,l,{zoom:this.zoom},t);this.patternFeatures.push(f)}else this.addFeature(l,u,c,r,{},t.subdivisionGranularity);let h=e[c].feature;t.featureIndex.insert(h,u,c,d,this.index)}}update(e,t,r){this.stateDependentLayers.length&&this.programConfigurations.updatePaintArrays(e,t,this.stateDependentLayers,{imagePositions:r})}addFeatures(e,t,r){for(let i of this.patternFeatures)this.addFeature(i,i.geometry,i.index,t,r,e.subdivisionGranularity)}isEmpty(){return this.layoutVertexArray.length===0}uploadPending(){return!this.uploaded||this.programConfigurations.needsUpload}upload(e){this.uploaded||(this.layoutVertexBuffer=e.createVertexBuffer(this.layoutVertexArray,q6e),this.indexBuffer=e.createIndexBuffer(this.indexArray),this.indexBuffer2=e.createIndexBuffer(this.indexArray2)),this.programConfigurations.upload(e),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(e,t,r,i,n,a){for(let s of B$(t,500)){let o=DL(s,i,a.fill.getGranularityForZoomLevel(i.z)),l=this.layoutVertexArray;RL((u,c)=>{l.emplaceBack(u,c)},this.segments,this.layoutVertexArray,this.indexArray,o.verticesFlattened,o.indicesTriangles,this.segments2,this.indexArray2,o.indicesLineList)}this.programConfigurations.populatePaintArrays(this.layoutVertexArray.length,e,r,{imagePositions:n,canonical:i})}};Ae("FillBucket",OL,{omit:["layers","patternFeatures"]});let gCe;const _Ce=()=>gCe||(gCe=new Mi({"fill-sort-key":new Ye(ce.layout_fill["fill-sort-key"],"fill-sort-key")}));let yCe;const vCe=()=>yCe||(yCe=new Mi({"fill-antialias":new Pe(ce.paint_fill["fill-antialias"],"fill-antialias"),"fill-opacity":new Ye(ce.paint_fill["fill-opacity"],"fill-opacity"),"fill-layer-opacity":new Pe(ce.paint_fill["fill-layer-opacity"],"fill-layer-opacity"),"fill-color":new Ye(ce.paint_fill["fill-color"],"fill-color"),"fill-outline-color":new Ye(ce.paint_fill["fill-outline-color"],"fill-outline-color"),"fill-translate":new Pe(ce.paint_fill["fill-translate"],"fill-translate"),"fill-translate-anchor":new Pe(ce.paint_fill["fill-translate-anchor"],"fill-translate-anchor"),"fill-pattern":new Im(ce.paint_fill["fill-pattern"],"fill-pattern")}));var bCe={get paint(){return vCe()},get layout(){return _Ce()}};const xCe=e=>e.type==="fill";var wCe=class extends Rs{constructor(e,t){super(e,bCe,t)}recalculate(e,t){super.recalculate(e,t);let r=this.paint._values["fill-outline-color"];r.value.kind==="constant"&&r.value.value===void 0&&(this.paint._values["fill-outline-color"]=this.paint._values["fill-color"])}createBucket(e){return new OL(e)}queryRadius(){return dv(this.paint.get("fill-translate"))}queryIntersectsFeature({queryGeometry:e,geometry:t,transform:r,pixelsToTileUnits:i}){return xL(hv(e,this.paint.get("fill-translate"),this.paint.get("fill-translate-anchor"),-r.bearingInRadians,i),t)}isTileClipped(){return!0}};const $Ce=Ar([{name:"a_pos",components:2,type:"Int16"},{name:"a_normal_ed",components:4,type:"Int16"}],4),SCe=Ar([{name:"a_centroid",components:2,type:"Int16"}],4),TCe=$Ce.members;var yg=class{constructor(t,r,i,n,a){for(this.properties=Object.create(null),this.extent=i,this.type=0,this.id=void 0,this._pbf=t,this._geometry=-1,this._keys=n,this._values=a;t.pos<r;){let s=t.readVarint();if(s===8)this.id=t.readVarint();else if(s===18){let o=t.readVarint()+t.pos;for(;t.pos<o;){let l=n[t.readVarint()],u=a[t.readVarint()];this.properties[l]=u}}else s===24?this.type=t.readVarint():(s===34&&(this._geometry=t.pos),t.skip(s))}}loadGeometry(){if(this._geometry<0)throw Error("feature has no geometry");let t=this._pbf;t.pos=this._geometry;let r=t.readVarint()+t.pos,i=[],n,a=1,s=0,o=0,l=0;for(;t.pos<r;){if(s<=0){let u=t.readVarint();if(a=u&7,s=u>>3,s===0)continue}if(s--,a===1)o+=t.readSVarint(),l+=t.readSVarint(),n&&i.push(n),n=[new de(o,l)];else if(a===2)o+=t.readSVarint(),l+=t.readSVarint(),n&&n.push(new de(o,l));else if(a===7)n&&n.push(n[0].clone());else throw Error(`unknown command ${a}`)}return n&&i.push(n),i}bbox(){if(this._geometry<0)throw Error("feature has no geometry");let t=this._pbf;t.pos=this._geometry;let r=t.readVarint()+t.pos,i=1,n=0,a=0,s=0,o=1/0,l=-1/0,u=1/0,c=-1/0;for(;t.pos<r;){if(n<=0){let d=t.readVarint();if(i=d&7,n=d>>3,n===0)continue}if(n--,i===1||i===2)a+=t.readSVarint(),s+=t.readSVarint(),a<o&&(o=a),a>l&&(l=a),s<u&&(u=s),s>c&&(c=s);else if(i!==7)throw Error(`unknown command ${i}`)}return[o,u,l,c]}toGeoJSON(t,r,i){let n=this.extent*2**i,a=this.extent*t,s=this.extent*r,o=this.loadGeometry();function l(h){return[(h.x+a)*360/n-180,360/Math.PI*Math.atan(Math.exp((1-(h.y+s)*2/n)*Math.PI))-90]}function u(h){return h.map(l)}let c;if(this.type===1){let h=[];for(let p of o)h.push(p[0]);let f=u(h);c=h.length===1?{type:"Point",coordinates:f[0]}:{type:"MultiPoint",coordinates:f}}else if(this.type===2){let h=o.map(u);c=h.length===1?{type:"LineString",coordinates:h[0]}:{type:"MultiLineString",coordinates:h}}else if(this.type===3){let h=LL(o),f=[];for(let p of h)f.push(p.map(u));c=f.length===1?{type:"Polygon",coordinates:f[0]}:{type:"MultiPolygon",coordinates:f}}else throw Error("unknown feature type");let d={type:"Feature",geometry:c,properties:this.properties};return this.id!=null&&(d.id=this.id),d}};yg.types=["Unknown","Point","LineString","Polygon"];function LL(e){let t=e.length;if(t<=1)return[e];let r=[],i,n;for(let a=0;a<t;a++){let s=CCe(e[a]);s!==0&&(n===void 0&&(n=s<0),n===s<0?(i&&r.push(i),i=[e[a]]):i&&i.push(e[a]))}return i&&r.push(i),r}function CCe(e){let t=0;for(let r=0,i=e.length,n=i-1,a,s;r<i;n=r++)a=e[r],s=e[n],t+=(s.x-a.x)*(a.y+s.y);return t}var kCe=class{constructor(e,t){for(this.version=1,this.name="",this.extent=4096,this.length=0,this._pbf=e,this._keys=[],this._values=[],this._features=[],t===void 0&&(t=e.length);e.pos<t;){let r=e.readVarint();r===10?this.name=e.readString():r===18?(this._features.push(e.pos),e.skip(r)):r===26?this._keys.push(e.readString()):r===34?this._values.push(ECe(e)):r===40?this.extent=e.readVarint():r===120?this.version=e.readVarint():e.skip(r)}this.length=this._features.length}feature(e){if(e<0||e>=this._features.length)throw Error("feature index out of bounds");this._pbf.pos=this._features[e];let t=this._pbf.readVarint()+this._pbf.pos;return new yg(this._pbf,t,this.extent,this._keys,this._values)}};function ECe(e){let t=null,r=e.readVarint()+e.pos;for(;e.pos<r;){let i=e.readVarint();t=i===10?e.readString():i===21?e.readFloat():i===25?e.readDouble():i===32?e.readVarint(!0):i===40?e.readVarint():i===48?e.readSVarint():i===56?e.readBoolean():(e.skip(i),null)}if(t==null)throw Error("unknown feature value");return t}var PCe=class{constructor(e,t=e.length){let r=Object.create(null);for(;e.pos<t;){let i=e.readVarint();if(i===26){let n=new kCe(e,e.readVarint()+e.pos);n.length&&(r[n.name]=n)}else e.skip(i)}this.layers=r}};const Ql=63710088e-1;var rt=class tp{constructor(t,r){if(isNaN(t)||isNaN(r))throw Error(`Invalid LngLat object: (${t}, ${r})`);if(this.lng=+t,this.lat=+r,this.lat>90||this.lat<-90)throw Error("Invalid LngLat latitude value: must be between -90 and 90")}wrap(){return new tp(ys(this.lng,-180,180),this.lat)}toArray(){return[this.lng,this.lat]}toString(){return`LngLat(${this.lng}, ${this.lat})`}distanceTo(t){let r=Math.PI/180,i=this.lat*r,n=t.lat*r,a=Math.sin(i)*Math.sin(n)+Math.cos(i)*Math.cos(n)*Math.cos((t.lng-this.lng)*r);return Ql*Math.acos(Math.min(a,1))}static convert(t){if(t instanceof tp)return t;if(Array.isArray(t)&&(t.length===2||t.length===3))return new tp(Number(t[0]),Number(t[1]));if(!Array.isArray(t)&&typeof t=="object"&&t)return new tp(Number("lng"in t?t.lng:t.lon),Number(t.lat));throw 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>]")}};const FL=2*Math.PI*Ql;function zL(e){return FL*Math.cos(e*Math.PI/180)}function Fh(e){return(180+e)/360}function zh(e){return(180-180/Math.PI*Math.log(Math.tan(Math.PI/4+e*Math.PI/360)))/360}function eu(e,t){return e/zL(t)}function zw(e){return e*360-180}function zm(e){let t=180-e*360;return 360/Math.PI*Math.atan(Math.exp(t*Math.PI/180))-90}function NL(e,t){return e*zL(zm(t))}function MCe(e){return 1/Math.cos(e*Math.PI/180)}var nr=class BL{constructor(t,r,i=0){this.x=+t,this.y=+r,this.z=+i}static fromLngLat(t,r=0){let i=rt.convert(t);return new BL(Fh(i.lng),zh(i.lat),eu(r,i.lat))}toLngLat(){return new rt(zw(this.x),zm(this.y))}toAltitude(){return NL(this.z,this.y)}meterInMercatorCoordinateUnits(){return 1/FL*MCe(zm(this.y))}};const hc=89.25;function jL(e,t,r){let i=1/(1<<r.z);return new nr(e/ye*i+r.x*i,t/ye*i+r.y*i)}function ICe(e,t,r){return jL(e,t,r).toLngLat()}function Qs(e,t){let r=Ot(t.lat,-85.051129,ul);return new de(Fh(t.lng)*e,zh(r)*e)}function Nm(e,t){return new nr(t.x/e,t.y/e).toLngLat()}function Lp(e){return e.cameraToCenterDistance*Math.min(Math.tan(zr(90-e.pitch))*.85,Math.tan(zr(hc-e.pitch)))}function Ob(e,t){let r=e.canonical,i=t/In(r.z),n=r.x+2**r.z*e.wrap,a=new Float64Array(16);return Ms(a),ei(a,a,[n*i,r.y*i,0]),Li(a,a,[i/ye,i/ye,1]),a}
741function UL(e,t,r,i,n){let a=nr.fromLngLat(e,t),s=n*eu(1,e.lat),{x:o,y:l,z:u}=Nw(r,i),c=s*-o,d=s*-l,h=s*-u;return new nr(a.x+c,a.y+d,a.z+h)}function Nw(e,t){let r=zr(e),i=zr(t),n=Math.cos(-r),a=Math.sin(r);return{x:a*Math.sin(i),y:-a*Math.cos(i),z:n}}function x8(e,t,r){if(t<=0||!e||e.length===0)return e;let i=ACe(t,r);return e.map(n=>DCe(n,i))}function ACe(e,t){let r=ICe(ye/2,ye/2,t),i=nr.fromLngLat(r).meterInMercatorCoordinateUnits(),n=(1<<t.z)*ye;return e*i*n}function DCe(e,t){if(!e||e.length<3)return e;let r=e[0].x===e[e.length-1].x&&e[0].y===e[e.length-1].y,i=r?e.length-1:e.length;if(i<3)return e;let n=e.map(s=>jx(s.x,s.y)),a=[];for(let s=0;s<i;s++){let o=n[(s-1+i)%i],l=n[s],u=n[(s+1)%i];RCe(a,o,l,u,t)}return r&&a.length>0&&a.push(Bx(a[0])),a.map(s=>new de(s[0],s[1]))}function RCe(e,t,r,i,n){let a=d0(za(),t,r),s=d0(za(),i,r),o=Sy(a),l=Sy(s);if(o<1e-6||l<1e-6){e.push(Bx(r));return}$y(a,a,1/o),$y(s,s,1/l);let u=bR(a,s);if(Math.abs(u)>Math.cos(5*Math.PI/180)){e.push(Bx(r));return}let c=.2,d=Math.min(n,o*c,l*c),h=bb(za(),r,a,d),f=bb(za(),r,s,d),p=L$e(za(),a,s);N$e(p,p);let m=Math.sqrt((1+u)/2),g=bb(za(),r,p,d/m),v=d0(za(),h,g),x=d0(za(),f,g),_=j$e(v,x),y=Math.sign(v[0]*x[1]-v[1]*x[0]),w=Math.max(2,Math.ceil(_/(Math.PI/6)-1e-6));for(let $=0;$<=w;$++){let S=y*_*($/w);e.push(B$e(za(),h,g,S))}}const Lb=2**13;function Mf(e,t,r,i,n,a,s,o){e.emplaceBack(t,r,Math.floor(i*Lb)*2+s,n*Lb*2,a*Lb*2,Math.round(o))}var VL=class{constructor(e){this.zoom=e.zoom,this.overscaling=e.overscaling,this.layers=e.layers,this.layerIds=this.layers.map(t=>t.id),this.index=e.index,this.hasDependencies=!1,this.layoutVertexArray=new BTe,this.centroidVertexArray=new Gl,this.indexArray=new go,this.programConfigurations=new Cc(e.layers,e.zoom),this.segments=new $r,this.stateDependentLayerIds=this.layers.filter(t=>t.isStateDependent()).map(t=>t.id)}populate(e,t,r){this.features=[],this.hasDependencies=Fy("fill-extrusion",this.layers,t);let i=new Tr(this.zoom),n=this.layers[0],a=n.layout.get("fill-extrusion-rounded-corner-distance"),s=n._featureFilter.needGeometry;for(let{feature:o,id:l,index:u,sourceLayerIndex:c}of e){let d=Bc(o,s);if(!n._featureFilter.filter(i,d,r))continue;let h=s?d.geometry:Nc(o),f={id:l,sourceLayerIndex:c,index:u,geometry:a>0?x8(h,a,r):h,properties:o.properties,type:o.type,patterns:{}};this.hasDependencies?this.features.push(oS("fill-extrusion",this.layers,f,{zoom:this.zoom},t)):this.addFeature(f,f.geometry,u,r,{},t.subdivisionGranularity),t.featureIndex.insert(o,f.geometry,u,c,this.index,!0)}}addFeatures(e,t,r){for(let i of this.features){let{geometry:n}=i;this.addFeature(i,n,i.index,t,r,e.subdivisionGranularity)}}update(e,t,r){this.stateDependentLayers.length&&this.programConfigurations.updatePaintArrays(e,t,this.stateDependentLayers,{imagePositions:r})}isEmpty(){return this.layoutVertexArray.length===0&&this.centroidVertexArray.length===0}uploadPending(){return!this.uploaded||this.programConfigurations.needsUpload}upload(e){this.uploaded||(this.layoutVertexBuffer=e.createVertexBuffer(this.layoutVertexArray,TCe),this.centroidVertexBuffer=e.createVertexBuffer(this.centroidVertexArray,SCe.members,!0),this.indexBuffer=e.createIndexBuffer(this.indexArray)),this.programConfigurations.upload(e),this.uploaded=!0}destroy(){this.layoutVertexBuffer&&(this.layoutVertexBuffer.destroy(),this.indexBuffer.destroy(),this.programConfigurations.destroy(),this.segments.destroy(),this.centroidVertexBuffer.destroy())}addFeature(e,t,r,i,n,a){let s=this.layers[0],o=s.layout?s.layout.get("fill-extrusion-rounded-corner-distance"):0,l=o>0?x8(t,o,i):t;for(let u of B$(l,500)){let c={x:0,y:0,sampleCount:0},d=this.layoutVertexArray.length;this.processPolygon(c,i,e,u,a);let h=this.layoutVertexArray.length-d,f=Math.floor(c.x/c.sampleCount),p=Math.floor(c.y/c.sampleCount);for(let m=0;m<h;m++)this.centroidVertexArray.emplaceBack(f,p)}this.programConfigurations.populatePaintArrays(this.layoutVertexArray.length,e,r,{imagePositions:n,canonical:i})}processPolygon(e,t,r,i,n){if(i.length<1||w8(i[0]))return;for(let c of i)c.length!==0&&OCe(e,c);let a={segment:this.segments.prepareSegment(4,this.layoutVertexArray,this.indexArray)},s=n.fill.getGranularityForZoomLevel(t.z),o=yg.types[r.type]==="Polygon";
vendor: 14,511 bytes, line 741
741for(let c of i){if(c.length===0||w8(c))continue;let d=uS(c,s,o);this._generateSideFaces(d,a)}if(!o)return;let l=DL(i,t,s,!1),u=this.layoutVertexArray;RL((c,d)=>{Mf(u,c,d,0,0,1,1,0)},this.segments,this.layoutVertexArray,this.indexArray,l.verticesFlattened,l.indicesTriangles)}_generateSideFaces(e,t){let r=0;for(let i=1;i<e.length;i++){let n=e[i],a=e[i-1];if(LCe(n,a))continue;t.segment.vertexLength+4>$r.MAX_VERTEX_ARRAY_LENGTH&&(t.segment=this.segments.prepareSegment(4,this.layoutVertexArray,this.indexArray));let s=n.sub(a)._perp()._unit(),o=a.dist(n);r+o>32768&&(r=0),Mf(this.layoutVertexArray,n.x,n.y,s.x,s.y,0,0,r),Mf(this.layoutVertexArray,n.x,n.y,s.x,s.y,0,1,r),r+=o,Mf(this.layoutVertexArray,a.x,a.y,s.x,s.y,0,0,r),Mf(this.layoutVertexArray,a.x,a.y,s.x,s.y,0,1,r);let l=t.segment.vertexLength;this.indexArray.emplaceBack(l,l+2,l+1),this.indexArray.emplaceBack(l+1,l+2,l+3),t.segment.vertexLength+=4,t.segment.primitiveLength+=2}}};function OCe(e,t){for(let r=0;r<t.length;r++){let i=t[r];(r!==t.length-1||t[0].x!==i.x||t[0].y!==i.y)&&(e.x+=i.x,e.y+=i.y,e.sampleCount++)}}Ae("FillExtrusionBucket",VL,{omit:["layers","features"]});function LCe(e,t){return e.x===t.x&&(e.x<0||e.x>8192)||e.y===t.y&&(e.y<0||e.y>8192)}function w8(e){return e.every(t=>t.x<0)||e.every(t=>t.x>8192)||e.every(t=>t.y<0)||e.every(t=>t.y>8192)}let FCe;const zCe=()=>FCe||(FCe=new Mi({"fill-extrusion-rounded-corner-distance":new Pe(ce["layout_fill-extrusion"]["fill-extrusion-rounded-corner-distance"],"fill-extrusion-rounded-corner-distance")}));let NCe;const BCe=()=>NCe||(NCe=new Mi({"fill-extrusion-opacity":new Pe(ce["paint_fill-extrusion"]["fill-extrusion-opacity"],"fill-extrusion-opacity"),"fill-extrusion-color":new Ye(ce["paint_fill-extrusion"]["fill-extrusion-color"],"fill-extrusion-color"),"fill-extrusion-translate":new Pe(ce["paint_fill-extrusion"]["fill-extrusion-translate"],"fill-extrusion-translate"),"fill-extrusion-translate-anchor":new Pe(ce["paint_fill-extrusion"]["fill-extrusion-translate-anchor"],"fill-extrusion-translate-anchor"),"fill-extrusion-pattern":new Im(ce["paint_fill-extrusion"]["fill-extrusion-pattern"],"fill-extrusion-pattern"),"fill-extrusion-height":new Ye(ce["paint_fill-extrusion"]["fill-extrusion-height"],"fill-extrusion-height"),"fill-extrusion-base":new Ye(ce["paint_fill-extrusion"]["fill-extrusion-base"],"fill-extrusion-base"),"fill-extrusion-vertical-gradient":new Pe(ce["paint_fill-extrusion"]["fill-extrusion-vertical-gradient"],"fill-extrusion-vertical-gradient")}));var jCe={get paint(){return BCe()},get layout(){return zCe()}};const UCe=e=>e.type==="fill-extrusion";var VCe=class extends Rs{constructor(e,t){super(e,jCe,t)}createBucket(e){return new VL(e)}queryRadius(){return dv(this.paint.get("fill-extrusion-translate"))}is3D(){return!0}queryIntersectsFeature({queryGeometry:e,feature:t,featureState:r,geometry:i,transform:n,pixelsToTileUnits:a,pixelPosMatrix:s}){let o=hv(e,this.paint.get("fill-extrusion-translate"),this.paint.get("fill-extrusion-translate-anchor"),-n.bearingInRadians,a),l=this.paint.get("fill-extrusion-height").evaluate(t,r),u=this.paint.get("fill-extrusion-base").evaluate(t,r),c=HCe(o,s,0),d=GCe(i,u,l,s),h=d[0],f=d[1];return qCe(h,f,c)}};function If(e,t){return e.x*t.x+e.y*t.y}function $8(e,t){if(e.length===1){let r=0,i=t[r++],n;for(;!n||i.equals(n);)if(n=t[r++],!n)return 1/0;for(;r<t.length;r++){let a=t[r],s=e[0],o=n.sub(i),l=a.sub(i),u=s.sub(i),c=If(o,o),d=If(o,l),h=If(l,l),f=If(u,o),p=If(u,l),m=c*h-d*d,g=(h*f-d*p)/m,v=(c*p-d*f)/m,x=1-g-v,_=i.z*x+n.z*g+a.z*v;if(isFinite(_))return _}return 1/0}{let r=1/0;for(let i of t)r=Math.min(r,i.z);return r}}function qCe(e,t,r){let i=1/0;xL(r,t)&&(i=$8(r,t[0]));for(let n=0;n<t.length;n++){let a=t[n],s=e[n];for(let o=0;o<a.length-1;o++){let l=a[o],u=a[o+1],c=s[o],d=[l,u,s[o+1],c,l];bL(r,d)&&(i=Math.min(i,$8(r,d)))}}return i!==1/0&&i}function GCe(e,t,r,i){let n=[],a=[],s=i[8]*t,o=i[9]*t,l=i[10]*t,u=i[11]*t,c=i[8]*r,d=i[9]*r,h=i[10]*r,f=i[11]*r;for(let p of e){let m=[],g=[];for(let v of p){let x=v.x,_=v.y,y=i[0]*x+i[4]*_+i[12],w=i[1]*x+i[5]*_+i[13],$=i[2]*x+i[6]*_+i[14],S=i[3]*x+i[7]*_+i[15],E=y+s,C=w+o,I=$+l,P=S+u,T=y+c,D=w+d,A=$+h,z=S+f,R=new de(E/P,C/P);R.z=I/P,m.push(R);let O=new de(T/z,D/z);O.z=A/z,g.push(O)}n.push(m),a.push(g)}return[n,a]}function HCe(e,t,r){let i=[];for(let n of e){let a=[n.x,n.y,r,1];_i(a,a,t),i.push(new de(a[0]/a[3],a[1]/a[3]))}return i}const YCe="geojsonvt_clip_start",WCe="geojsonvt_clip_end",ZCe=Ar([{name:"a_pos_normal",components:2,type:"Int16"},{name:"a_data",components:4,type:"Uint8"}],4),KCe=ZCe.members,XCe=Ar([{name:"a_uv_x",components:1,type:"Float32"},{name:"a_split_index",components:1,type:"Float32"}]),JCe=XCe.members,QCe=Math.cos(75/2*(Math.PI/180)),qL=1/2,S8=2**14/qL;var GL=class{constructor(e){this.zoom=e.zoom,this.overscaling=e.overscaling,this.layers=e.layers,this.layerIds=this.layers.map(t=>t.id),this.index=e.index,this.hasDependencies=!1,this.patternFeatures=[],this.lineClipsArray=[],this.gradients={};for(let t of this.layers)this.gradients[t.id]={};this.layoutVertexArray=new jTe,this.layoutVertexArray2=new UTe,this.indexArray=new go,this.programConfigurations=new Cc(e.layers,e.zoom),this.segments=new $r,this.maxLineLength=0,this.stateDependentLayerIds=this.layers.filter(t=>t.isStateDependent()).map(t=>t.id)}populate(e,t,r){this.hasDependencies=Fy("line",this.layers,t)||this.hasLineDasharray(this.layers);let i=this.layers[0].layout.get("line-sort-key"),n=!i.isConstant(),a=[],s=new Tr(this.zoom),o=this.layers[0]._featureFilter.needGeometry;for(let{feature:l,id:u,index:c,sourceLayerIndex:d}of e){let h=Bc(l,o);if(!this.layers[0]._featureFilter.filter(s,h,r))continue;let f=n?i.evaluate(h,{},r):void 0,p={id:u,properties:l.properties,type:l.type,sourceLayerIndex:d,index:c,geometry:o?h.geometry:Nc(l),patterns:{},dashes:{},sortKey:f};a.push(p)}n&&a.sort((l,u)=>l.sortKey-u.sortKey);for(let l of a){let{geometry:u,index:c,sourceLayerIndex:d}=l;this.hasDependencies?(Fy("line",this.layers,t)?oS("line",this.layers,l,{zoom:this.zoom},t):this.hasLineDasharray(this.layers)&&this.addLineDashDependencies(this.layers,l,this.zoom,t),this.patternFeatures.push(l)):this.addFeature(l,u,c,r,{},{},t.subdivisionGranularity);let h=e[c].feature;t.featureIndex.insert(h,u,c,d,this.index)}}update(e,t,r,i){this.stateDependentLayers.length&&this.programConfigurations.updatePaintArrays(e,t,this.stateDependentLayers,{imagePositions:r,dashPositions:i})}addFeatures(e,t,r,i){for(let n of this.patternFeatures)this.addFeature(n,n.geometry,n.index,t,r,i,e.subdivisionGranularity)}isEmpty(){return this.layoutVertexArray.length===0}uploadPending(){return!this.uploaded||this.programConfigurations.needsUpload}upload(e){this.uploaded||(this.layoutVertexArray2.length!==0&&(this.layoutVertexBuffer2=e.createVertexBuffer(this.layoutVertexArray2,JCe)),this.layoutVertexBuffer=e.createVertexBuffer(this.layoutVertexArray,KCe),this.indexBuffer=e.createIndexBuffer(this.indexArray)),this.programConfigurations.upload(e),this.uploaded=!0}destroy(){this.layoutVertexBuffer&&(this.layoutVertexBuffer.destroy(),this.indexBuffer.destroy(),this.programConfigurations.destroy(),this.segments.destroy())}lineFeatureClips(e){if(e.properties&&Object.hasOwn(e.properties,"geojsonvt_clip_start")&&Object.hasOwn(e.properties,"geojsonvt_clip_end"))return{start:+e.properties[YCe],end:+e.properties[WCe]}}addFeature(e,t,r,i,n,a,s){let o=this.layers[0].layout,l=o.get("line-join").evaluate(e,{}),u=o.get("line-cap").evaluate(e,{}),c=o.get("line-miter-limit").evaluate(e,{}),d=o.get("line-round-limit").evaluate(e,{});this.lineClips=this.lineFeatureClips(e);for(let h of t)this.addLine(h,e,l,u,c,d,i,s);this.programConfigurations.populatePaintArrays(this.layoutVertexArray.length,e,r,{imagePositions:n,dashPositions:a,canonical:i})}addLine(e,t,r,i,n,a,s,o){this.distance=0,this.scaledDistance=0,this.totalDistance=0;let l=s?o.line.getGranularityForZoomLevel(s.z):1;if(e=uS(e,l),this.lineClips){this.lineClipsArray.push(this.lineClips);for(let _=0;_<e.length-1;_++)this.totalDistance+=e[_].dist(e[_+1]);this.updateScaledDistance(),this.maxLineLength=Math.max(this.maxLineLength,this.totalDistance)}let u=yg.types[t.type]==="Polygon",c=e.length;for(;c>=2&&e[c-1].equals(e[c-2]);)c--;let d=0;for(;d<c-1&&e[d].equals(e[d+1]);)d++;if(c-d<(u?3:2))return;r==="bevel"&&(n=1.05);let h=this.overscaling<=16?15*ye/(512*this.overscaling):0,f=this.segments.prepareSegment(c*10,this.layoutVertexArray,this.indexArray),p,m,g,v,x;this.e1=this.e2=-1,u&&(p=e[c-2],x=e[d].sub(p)._unit()._perp());for(let _=d;_<c;_++){if(g=_===c-1?u?e[d+1]:void 0:e[_+1],g&&e[_].equals(g))continue;x&&(v=x),p&&(m=p),p=e[_],x=g?g.sub(p)._unit()._perp():v,v||(v=x);let y=v.add(x);(y.x!==0||y.y!==0)&&y._unit();let w=v.x*x.x+v.y*x.y,$=y.x*x.x+y.y*x.y,S=$===0?1/0:1/$,E=2*Math.sqrt(2-2*$),C=$<QCe&&m&&g,I=v.x*x.y-v.y*x.x>0;if(C&&_>d){let D=p.dist(m);if(D>2*h){let A=p.sub(p.sub(m)._mult(h/D)._round());this.updateDistance(m,A),this.addCurrentVertex(A,v,0,0,f),m=A}}let P=m&&g,T=P?r:u?"butt":i;if(P&&T==="round"&&(S<a?T="miter":S<=2&&(T="fakeround")),T==="miter"&&S>n&&(T="bevel"),T==="bevel"&&(S>2&&(T="flipbevel"),S<n&&(T="miter")),m&&this.updateDistance(m,p),T==="miter")y._mult(S),this.addCurrentVertex(p,y,0,0,f);else if(T==="flipbevel"){if(S>100)y=x.mult(-1);else{let D=S*v.add(x).mag()/v.sub(x).mag();y._perp()._mult(D*(I?-1:1))}this.addCurrentVertex(p,y,0,0,f),this.addCurrentVertex(p,y.mult(-1),0,0,f)}else if(T==="bevel"||T==="fakeround"){let D=-Math.sqrt(S*S-1),A=I?D:0,z=I?0:D;if(m&&this.addCurrentVertex(p,v,A,z,f),T==="fakeround"){let R=Math.round(E*180/Math.PI/20);for(let O=1;O<R;O++){let V=O/R;if(V!==.5){let F=V-.5,ae=1.0904+w*(-3.2452+w*(3.55645-w*1.43519)),ue=.848013+w*(-1.06021+w*.215638);V+=V*F*(V-1)*(ae*F*F+ue)}let Y=x.sub(v)._mult(V)._add(v)._unit()._mult(I?-1:1);this.addHalfVertex(p,Y.x,Y.y,!1,I,0,f)}}g&&this.addCurrentVertex(p,x,-A,-z,f)}else if(T==="butt")this.addCurrentVertex(p,y,0,0,f);else if(T==="square"){let D=m?1:-1;this.addCurrentVertex(p,y,D,D,f)}else T==="round"&&(m&&(this.addCurrentVertex(p,v,0,0,f),this.addCurrentVertex(p,v,1,1,f,!0)),g&&(this.addCurrentVertex(p,x,-1,-1,f,!0),this.addCurrentVertex(p,x,0,0,f)));if(C&&_<c-1){let D=p.dist(g);if(D>2*h){let A=p.add(g.sub(p)._mult(h/D)._round());this.updateDistance(p,A),this.addCurrentVertex(A,x,0,0,f),p=A}}}}addCurrentVertex(e,t,r,i,n,a=!1){let s=t.x+t.y*r,o=t.y-t.x*r,l=-t.x+t.y*i,u=-t.y-t.x*i;this.addHalfVertex(e,s,o,a,!1,r,n),this.addHalfVertex(e,l,u,a,!0,-i,n),this.distance>S8/2&&this.totalDistance===0&&(this.distance=0,this.updateScaledDistance(),this.addCurrentVertex(e,t,r,i,n,a))}addHalfVertex({x:e,y:t},r,i,n,a,s,o){let l=(this.lineClips?this.scaledDistance*(S8-1):this.scaledDistance)*qL;if(this.layoutVertexArray.emplaceBack((e<<1)+ +!!n,(t<<1)+ +!!a,Math.round(63*r)+128,Math.round(63*i)+128,(s===0?0:s<0?-1:1)+1|(l&63)<<2,l>>6),this.lineClips){let c=(this.scaledDistance-this.lineClips.start)/(this.lineClips.end-this.lineClips.start);this.layoutVertexArray2.emplaceBack(c,this.lineClipsArray.length)}let u=o.vertexLength++;this.e1>=0&&this.e2>=0&&(this.indexArray.emplaceBack(this.e1,u,this.e2),o.primitiveLength++),a?this.e2=u:this.e1=u}updateScaledDistance(){this.scaledDistance=this.lineClips?this.lineClips.start+(this.lineClips.end-this.lineClips.start)*this.distance/this.totalDistance:this.distance}updateDistance(e,t){this.distance+=e.dist(t),this.updateScaledDistance()}hasLineDasharray(e){for(let t of e){let r=t.paint.get("line-dasharray");if(r&&!r.isConstant())return!0}return!1}addLineDashDependencies(e,t,r,i){for(let n of e){let a=n.paint.get("line-dasharray");if(!a||a.value.kind==="constant")continue;let s=n.layout.get("line-cap").evaluate(t,{})==="round",o={dasharray:a.value.evaluate({zoom:r-1},t,{}),round:s},l={dasharray:a.value.evaluate({zoom:r},t,{}),round:s},u={dasharray:a.value.evaluate({zoom:r+1},t,{}),round:s},c=`${o.dasharray.join(",")},${o.round}`,d=`${l.dasharray.join(",")},${l.round}`,h=`${u.dasharray.join(",")},${u.round}`;i.dashDependencies[c]=o,i.dashDependencies[d]=l,i.dashDependencies[h]=u,t.dashes[n.id]={min:c,mid:d,max:h}}}};Ae("LineBucket",GL,{omit:["layers","patternFeatures"]});let eke;const tke=()=>eke||(eke=new Mi({"line-cap":new Ye(ce.layout_line["line-cap"],"line-cap"),"line-join":new Ye(ce.layout_line["line-join"],"line-join"),"line-miter-limit":new Ye(ce.layout_line["line-miter-limit"],"line-miter-limit"),"line-round-limit":new Ye(ce.layout_line["line-round-limit"],"line-round-limit"),"line-sort-key":new Ye(ce.layout_line["line-sort-key"],"line-sort-key")}));let rke;const ike=()=>rke||(rke=new Mi({"line-opacity":new Ye(ce.paint_line["line-opacity"],"line-opacity"),"line-layer-opacity":new Pe(ce.paint_line["line-layer-opacity"],"line-layer-opacity"),"line-color":new Ye(ce.paint_line["line-color"],"line-color"),"line-translate":new Pe(ce.paint_line["line-translate"],"line-translate"),"line-translate-anchor":new Pe(ce.paint_line["line-translate-anchor"],"line-translate-anchor"),"line-width":new Ye(ce.paint_line["line-width"],"line-width"),"line-gap-width":new Ye(ce.paint_line["line-gap-width"],"line-gap-width"),"line-offset":new Ye(ce.paint_line["line-offset"],"line-offset"),"line-blur":new Ye(ce.paint_line["line-blur"],"line-blur"),"line-dasharray":new Im(ce.paint_line["line-dasharray"],"line-dasharray"),"line-pattern":new Im(ce.paint_line["line-pattern"],"line-pattern"),"line-gradient":new uv(ce.paint_line["line-gradient"],"line-gradient")}));var T8={get paint(){return ike()},get layout(){return tke()}},nke=class extends Ye{possiblyEvaluate(e,t){return t=new Tr(Math.floor(t.zoom),{now:t.now,fadeDuration:t.fadeDuration,zoomHistory:t.zoomHistory,transition:t.transition}),super.possiblyEvaluate(e,t)}evaluate(e,t,r,i){return t=Ne({},t,{zoom:Math.floor(t.zoom)}),super.evaluate(e,t,r,i)}};let $0;const ake=e=>e.type==="line";var ske=class extends Rs{constructor(e,t){super(e,T8,t),this.gradientVersion=0,$0||($0=new nke(T8.paint.properties["line-width"].specification,"line-floorwidth"),$0.useIntegerZoom=!0)}_handleSpecialPaintPropertyUpdate(e){if(e==="line-gradient"){let t=this.gradientExpression();this.stepInterpolant=V5e(t)?t._styleExpression.expression instanceof L$:!1,this.gradientVersion=(this.gradientVersion+1)%(2**53-1)}}gradientExpression(){return this._transitionablePaint._values["line-gradient"].value.expression}recalculate(e,t){super.recalculate(e,t),this.paint._values["line-floorwidth"]=$0.possiblyEvaluate(this._transitioningPaint._values["line-width"].value,e)}createBucket(e){return new GL(e)}
vendor: 9,200 bytes, line 741
741queryRadius(e){let t=e,r=C8(Xd("line-width",this,t),Xd("line-gap-width",this,t)),i=Xd("line-offset",this,t);return r/2+Math.abs(i)+dv(this.paint.get("line-translate"))}queryIntersectsFeature({queryGeometry:e,feature:t,featureState:r,geometry:i,transform:n,pixelsToTileUnits:a}){let s=hv(e,this.paint.get("line-translate"),this.paint.get("line-translate-anchor"),-n.bearingInRadians,a),o=a/2*C8(this.paint.get("line-width").evaluate(t,r),this.paint.get("line-gap-width").evaluate(t,r)),l=this.paint.get("line-offset").evaluate(t,r);return l&&(i=p6e(i,l*a)),o6e(s,i,o)}isTileClipped(){return!0}};function C8(e,t){return t>0?t+2*e:e}const oke=Ar([{name:"a_pos_offset",components:4,type:"Int16"},{name:"a_data",components:4,type:"Uint16"},{name:"a_pixeloffset",components:4,type:"Int16"}],4),lke=Ar([{name:"a_projected_pos",components:3,type:"Float32"}],4);Ar([{name:"a_fade_opacity",components:1,type:"Uint32"}],4);const uke=Ar([{name:"a_placed",components:2,type:"Uint8"},{name:"a_shift",components:2,type:"Float32"},{name:"a_box_real",components:2,type:"Int16"}]);Ar([{type:"Int16",name:"anchorPointX"},{type:"Int16",name:"anchorPointY"},{type:"Int16",name:"x1"},{type:"Int16",name:"y1"},{type:"Int16",name:"x2"},{type:"Int16",name:"y2"},{type:"Uint32",name:"featureIndex"},{type:"Uint16",name:"sourceLayerIndex"},{type:"Uint16",name:"bucketIndex"}]);const k8=Ar([{name:"a_pos",components:2,type:"Int16"},{name:"a_anchor_pos",components:2,type:"Int16"},{name:"a_extrude",components:2,type:"Int16"}],4),cke=Ar([{name:"a_pos",components:2,type:"Float32"},{name:"a_radius",components:1,type:"Float32"},{name:"a_flags",components:2,type:"Int16"}],4);Ar([{name:"triangle",components:3,type:"Uint16"}]),Ar([{type:"Int16",name:"anchorX"},{type:"Int16",name:"anchorY"},{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"}]),Ar([{type:"Int16",name:"anchorX"},{type:"Int16",name:"anchorY"},{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",name:"textBoxScale"},{type:"Float32",name:"collisionCircleDiameter"},{type:"Uint16",name:"textAnchorOffsetStartIndex"},{type:"Uint16",name:"textAnchorOffsetEndIndex"}]),Ar([{type:"Float32",name:"offsetX"}]),Ar([{type:"Int16",name:"x"},{type:"Int16",name:"y"},{type:"Int16",name:"tileUnitDistanceFromAnchor"}]),Ar([{type:"Uint16",name:"textAnchor"},{type:"Float32",components:2,name:"textOffset"}]);function dke(e,t,r){let i=t.layout.get("text-transform").evaluate(r,{});return i==="uppercase"?e=e.toLocaleUpperCase():i==="lowercase"&&(e=e.toLocaleLowerCase()),Oh.applyArabicShaping&&(e=Oh.applyArabicShaping(e)),e}function hke(e,t,r){for(let i of e.sections)i.text=dke(i.text,t,r);return e}function fke(e){let t={},r={},i=[],n=0;function a(u){i.push(e[u]),n++}function s(u,c,d){let h=r[u];return delete r[u],r[c]=h,i[h].geometry[0].pop(),i[h].geometry[0]=i[h].geometry[0].concat(d[0]),h}function o(u,c,d){let h=t[c];return delete t[c],t[u]=h,i[h].geometry[0].shift(),i[h].geometry[0]=d[0].concat(i[h].geometry[0]),h}function l(u,c,d){let h=d?c[0][c[0].length-1]:c[0][0];return`${u}:${h.x}:${h.y}`}for(let u=0;u<e.length;u++){let c=e[u],d=c.geometry,h=c.text?c.text.toString():null;if(!h){a(u);continue}let f=l(h,d),p=l(h,d,!0);if(f in r&&p in t&&r[f]!==t[p]){let m=o(f,p,d),g=s(f,p,i[m].geometry);delete t[f],delete r[p],r[l(h,i[g].geometry,!0)]=g,i[m].geometry=null}else f in r?s(f,p,d):p in t?o(f,p,d):(a(u),t[f]=n-1,r[p]=n-1)}return i.filter(u=>u.geometry)}const pke={"!":"ï¸","#":"ï¼",$:"ï¼","%":"ï¼
","&":"ï¼","(":"︵",")":"︶","*":"ï¼","+":"ï¼",",":"ï¸","-":"︲",".":"ã»","/":"ï¼",":":"ï¸",";":"ï¸","<":"︿","=":"ï¼",">":"ï¹","?":"ï¸","@":"ï¼ ","[":"ï¹","\\":"ï¼¼","]":"ï¹","^":"ï¼¾",_:"︳","`":"ï½","{":"︷","|":"â","}":"︸","~":"ï½","¢":"ï¿ ","£":"ï¿¡","Â¥":"ï¿¥","¦":"¦","¬":"ï¿¢","¯":"ï¿£","â":"︲","â":"︱","â":"ï¹","â":"ï¹","â":"ï¹","â":"ï¹","â¦":"ï¸","â¯":"ï¸","â§":"ã»","â©":"₩","ã":"ï¸","ã":"ï¸","ã":"︿","ã":"ï¹","ã":"︽","ã":"︾","ã":"ï¹","ã":"ï¹","ã":"ï¹","ã":"ï¹","ã":"︻","ã":"︼","ã":"︹","ã":"︺","ã":"ï¸","ã":"ï¸","ï¼":"ï¸","ï¼":"︵","ï¼":"︶","ï¼":"ï¸","ï¼":"︲","ï¼":"ã»","ï¼":"ï¸","ï¼":"ï¸","ï¼":"︿","ï¼":"ï¹","ï¼":"ï¸","ï¼»":"ï¹","ï¼½":"ï¹","_":"︳","ï½":"︷","ï½":"â","ï½":"︸","ï½":"︵","ï½ ":"︶","。":"ï¸","ï½¢":"ï¹","ï½£":"ï¹"},E8=4294967296,P8=typeof TextDecoder>"u"?null:new TextDecoder("utf-8");var HL=class{constructor(e){this.buf=ArrayBuffer.isView(e)?e:new Uint8Array(e),this.dataView=new DataView(this.buf.buffer,this.buf.byteOffset,this.buf.byteLength),this.pos=0,this.type=0,this._valueStart=-1,this.length=this.buf.length}readFields(e,t,r=this.length){let i;for(;i=this.nextField(r);)e(i,t,this);return t}readMessage(e,t){return this.readFields(e,t,this.readVarint()+this.pos)}readFixed32(){let e=this.dataView.getUint32(this.pos,!0);return this.pos+=4,e}readSFixed32(){let e=this.dataView.getInt32(this.pos,!0);return this.pos+=4,e}readFixed64(){let e=this.dataView.getUint32(this.pos,!0)+this.dataView.getUint32(this.pos+4,!0)*E8;return this.pos+=8,e}readSFixed64(){let e=this.dataView.getUint32(this.pos,!0)+this.dataView.getInt32(this.pos+4,!0)*E8;return this.pos+=8,e}readFloat(){let e=this.dataView.getFloat32(this.pos,!0);return this.pos+=4,e}readDouble(){let e=this.dataView.getFloat64(this.pos,!0);return this.pos+=8,e}readVarint(e){let t=this.buf,r=t[this.pos++];if(r<128)return r;let i=r&127,n;return n=t[this.pos++],i|=(n&127)<<7,n<128||(n=t[this.pos++],i|=(n&127)<<14,n<128)||(n=t[this.pos++],i|=(n&127)<<21,n<128)?i:(n=t[this.pos],i|=(n&15)<<28,mke(i,e,this))}readSVarint(){let e=this.readVarint();return e%2==1?(e+1)/-2:e/2}readBoolean(){return!!this.readVarint()}readString(){let e=this.readVarint()+this.pos,t=this.pos;return this.pos=e,e-t>=12&&P8?P8.decode(this.buf.subarray(t,e)):_ke(this.buf,t,e)}readBytes(){let e=this.readVarint()+this.pos,t=this.buf.subarray(this.pos,e);return this.pos=e,t}readPackedVarint(e=[],t){let r=this.readPackedEnd();for(;this.pos<r;)e.push(this.readVarint(t));return e}readPackedSVarint(e=[]){let t=this.readPackedEnd();for(;this.pos<t;)e.push(this.readSVarint());return e}readPackedBoolean(e=[]){let t=this.readPackedEnd();for(;this.pos<t;)e.push(this.readBoolean());return e}readPackedFloat(e=[]){let t=this.readPackedEnd();for(;this.pos<t;)e.push(this.readFloat());return e}readPackedDouble(e=[]){let t=this.readPackedEnd();for(;this.pos<t;)e.push(this.readDouble());return e}readPackedFixed32(e=[]){let t=this.readPackedEnd();for(;this.pos<t;)e.push(this.readFixed32());return e}readPackedSFixed32(e=[]){let t=this.readPackedEnd();for(;this.pos<t;)e.push(this.readSFixed32());return e}readPackedFixed64(e=[]){let t=this.readPackedEnd();for(;this.pos<t;)e.push(this.readFixed64());return e}readPackedSFixed64(e=[]){let t=this.readPackedEnd();for(;this.pos<t;)e.push(this.readSFixed64());return e}readPackedEnd(){return this.type===2?this.readVarint()+this.pos:this.pos+1}nextField(e=this.length){if(this.pos===this._valueStart&&this.skip(this.type),this.pos>=e)return 0;let t=this.readVarint();return this.type=t&7,this._valueStart=this.pos,t>>>3}skip(e){let t=e&7;if(t===0)for(;this.buf[this.pos++]>127;);else if(t===2)this.pos=this.readVarint()+this.pos;else if(t===5)this.pos+=4;else if(t===1)this.pos+=8;else throw Error(`Unimplemented type: ${t}`)}};function mke(e,t,r){let i=r.buf,n,a;if(a=i[r.pos++],n=(a&112)>>4,a<128||(a=i[r.pos++],n|=(a&127)<<3,a<128)||(a=i[r.pos++],n|=(a&127)<<10,a<128)||(a=i[r.pos++],n|=(a&127)<<17,a<128)||(a=i[r.pos++],n|=(a&127)<<24,a<128)||(a=i[r.pos++],n|=(a&1)<<31,a<128))return gke(e,n,t);throw Error("Expected varint not more than 10 bytes")}function gke(e,t,r){return r?t*4294967296+(e>>>0):(t>>>0)*4294967296+(e>>>0)}function _ke(e,t,r){let i="",n=t;
741for(;n<r;){let a=e[n],s=null,o=a>239?4:a>223?3:a>191?2:1;if(n+o>r)break;let l,u,c;o===1?a<128&&(s=a):o===2?(l=e[n+1],(l&192)==128&&(s=(a&31)<<6|l&63,s<=127&&(s=null))):o===3?(l=e[n+1],u=e[n+2],(l&192)==128&&(u&192)==128&&(s=(a&15)<<12|(l&63)<<6|u&63,(s<=2047||s>=55296&&s<=57343)&&(s=null))):o===4&&(l=e[n+1],u=e[n+2],c=e[n+3],(l&192)==128&&(u&192)==128&&(c&192)==128&&(s=(a&15)<<18|(l&63)<<12|(u&63)<<6|c&63,(s<=65535||s>=1114112)&&(s=null))),s===null?(s=65533,o=1):s>65535&&(s-=65536,i+=String.fromCharCode(s>>>10&1023|55296),s=56320|s&1023),i+=String.fromCharCode(s),n+=o}return i}function yke(e,t,r){e===1&&r.readMessage(vke,t)}function vke(e,t,r){if(e===3){let{id:i,bitmap:n,width:a,height:s,left:o,top:l,advance:u}=r.readMessage(bke,{});t.push({id:i,bitmap:new sS({width:a+6,height:s+6},n),metrics:{width:a,height:s,left:o,top:l,advance:u}})}}function bke(e,t,r){e===1?t.id=r.readVarint():e===2?t.bitmap=r.readBytes():e===3?t.width=r.readVarint():e===4?t.height=r.readVarint():e===5?t.left=r.readSVarint():e===6?t.top=r.readSVarint():e===7&&(t.advance=r.readVarint())}function xke(e){return new HL(e).readFields(yke,[])}function wke(e){let{userImage:t}=e;return t!=null&&t.render&&t.render()?(e.data.replace(new Uint8Array(t.data.buffer)),!0):!1}function YL(e){let t=0,r=0;for(let s of e)t+=s.w*s.h,r=Math.max(r,s.w);e.sort((s,o)=>o.h-s.h);let i=[{x:0,y:0,w:Math.max(Math.ceil(Math.sqrt(t/.95)),r),h:1/0}],n=0,a=0;for(let s of e)for(let o=i.length-1;o>=0;o--){let l=i[o];if(!(s.w>l.w||s.h>l.h)){if(s.x=l.x,s.y=l.y,a=Math.max(a,s.y+s.h),n=Math.max(n,s.x+s.w),s.w===l.w&&s.h===l.h){let u=i.pop();u&&o<i.length&&(i[o]=u)}else s.h===l.h?(l.x+=s.w,l.w-=s.w):s.w===l.w?(l.y+=s.h,l.h-=s.h):(i.push({x:l.x+s.w,y:l.y,w:l.w-s.w,h:s.h}),l.y+=s.h,l.h-=s.h);break}}return{w:n,h:a,fill:t/(n*a)||0}}var cS=class{constructor(e,{pixelRatio:t,version:r,stretchX:i,stretchY:n,content:a,textFitWidth:s,textFitHeight:o}){this.paddedRect=e,this.pixelRatio=t,this.stretchX=i,this.stretchY=n,this.content=a,this.version=r,this.textFitWidth=s,this.textFitHeight=o}get tl(){return[this.paddedRect.x+1,this.paddedRect.y+1]}get br(){return[this.paddedRect.x+this.paddedRect.w-1,this.paddedRect.y+this.paddedRect.h-1]}get tlbr(){return this.tl.concat(this.br)}get displaySize(){return[(this.paddedRect.w-2)/this.pixelRatio,(this.paddedRect.h-2)/this.pixelRatio]}},$ke=class{constructor(e,t){let r={},i={};this.haveRenderCallbacks=[];let n=[];this.addImages(e,r,n),this.addImages(t,i,n);let{w:a,h:s}=YL(n),o=new _r({width:a||1,height:s||1});for(let l in e){let u=e[l],c=r[l].paddedRect;_r.copy(u.data,o,{x:0,y:0},{x:c.x+1,y:c.y+1},u.data)}for(let l in t){let u=t[l],c=i[l].paddedRect,d=c.x+1,h=c.y+1,f=u.data.width,p=u.data.height;_r.copy(u.data,o,{x:0,y:0},{x:d,y:h},u.data),_r.copy(u.data,o,{x:0,y:p-1},{x:d,y:h-1},{width:f,height:1}),_r.copy(u.data,o,{x:0,y:0},{x:d,y:h+p},{width:f,height:1}),_r.copy(u.data,o,{x:f-1,y:0},{x:d-1,y:h},{width:1,height:p}),_r.copy(u.data,o,{x:0,y:0},{x:d+f,y:h},{width:1,height:p})}this.image=o,this.iconPositions=r,this.patternPositions=i}addImages(e,t,r){for(let i in e){let n=e[i],a={x:0,y:0,w:n.data.width+2,h:n.data.height+2};r.push(a),t[i]=new cS(a,n),n.hasRenderCallback&&this.haveRenderCallbacks.push(i)}}patchUpdatedImages(e,t){e.dispatchRenderCallbacks(this.haveRenderCallbacks);for(let r in e.updatedImages)this.patchUpdatedImage(this.iconPositions[r],e.getImage(r),t),this.patchUpdatedImage(this.patternPositions[r],e.getImage(r),t)}patchUpdatedImage(e,t,r){if(!e||!t||e.version===t.version)return;e.version=t.version;let[i,n]=e.tl;r.update(t.data,void 0,{x:i,y:n})}};Ae("ImagePosition",cS),Ae("ImageAtlas",$ke);var WL=(function(e){return e[e.none=0]="none",e[e.horizontal=1]="horizontal",e[e.vertical=2]="vertical",e[e.horizontalOnly=3]="horizontalOnly",e})(WL||{});function ZL(e){let t=.5,r=.5;switch(e){case"right":case"top-right":case"bottom-right":t=1;break;case"left":case"top-left":case"bottom-left":t=0}switch(e){case"bottom":case"bottom-right":case"bottom-left":r=1;break;case"top":case"top-right":case"top-left":r=0}return{horizontalAlign:t,verticalAlign:r}}const M8=32640;function I8(e,t){let{expression:r}=t;if(r.kind==="constant")return{kind:"constant",layoutSize:r.evaluate(new Tr(e+1))};if(r.kind==="source")return{kind:"source"};{let{zoomStops:i,interpolationType:n}=r,a=0;for(;a<i.length&&i[a]<=e;)a++;a=Math.max(0,a-1);let s=a;for(;s<i.length&&i[s]<e+1;)s++;s=Math.min(i.length-1,s);let o=i[a],l=i[s];return r.kind==="composite"?{kind:"composite",minZoom:o,maxZoom:l,interpolationType:n}:{kind:"camera",minZoom:o,maxZoom:l,minSize:r.evaluate(new Tr(o)),maxSize:r.evaluate(new Tr(l)),interpolationType:n}}}function dS(e,{uSize:t,uSizeT:r},{lowerSize:i,upperSize:n}){return e.kind==="source"?i/128:e.kind==="composite"?ai.number(i/128,n/128,r):t}function fv(e,t){let r=0,i=0;if(e.kind==="constant")i=e.layoutSize;else if(e.kind!=="source"){let{interpolationType:n,minZoom:a,maxZoom:s}=e,o=n?Ot(Ts.interpolationFactor(n,t,a,s),0,1):0;e.kind==="camera"?i=ai.number(e.minSize,e.maxSize,o):r=o}return{uSizeT:r,uSize:i}}function By(e,t,r){let i="never",n=e.get(t);return n?i=n:e.get(r)&&(i="always"),i}const Ske=[{name:"a_fade_opacity",components:1,type:"Uint8",offset:0}];function S0(e,t,r,i,n,a,s,o,l,u,c,d,h){let f=o?Math.min(M8,Math.round(o[0])):0,p=o?Math.min(M8,Math.round(o[1])):0;e.emplaceBack(t,r,Math.round(i*32),Math.round(n*32),a,s,(f<<1)+ +!!l,p,u*16,c*16,d*256,h*256)}function Bm(e,t,r){e.emplaceBack(t.x,t.y,r),e.emplaceBack(t.x,t.y,r),e.emplaceBack(t.x,t.y,r),e.emplaceBack(t.x,t.y,r)}function Tke(e){for(let t of e.sections)if(CTe(t.text))return!0;return!1}var Bw=class{constructor(e){this.layoutVertexArray=new VTe,this.indexArray=new go,this.programConfigurations=e,this.segments=new $r,this.dynamicLayoutVertexArray=new qTe,this.opacityVertexArray=new GTe,this.hasVisibleVertices=!1,this.placedSymbolArray=new sL}isEmpty(){return this.layoutVertexArray.length===0&&this.indexArray.length===0&&this.dynamicLayoutVertexArray.length===0&&this.opacityVertexArray.length===0}upload(e,t,r,i){this.isEmpty()||(r&&(this.layoutVertexBuffer=e.createVertexBuffer(this.layoutVertexArray,oke.members),this.indexBuffer=e.createIndexBuffer(this.indexArray,t),this.dynamicLayoutVertexBuffer=e.createVertexBuffer(this.dynamicLayoutVertexArray,lke.members,!0),this.opacityVertexBuffer=e.createVertexBuffer(this.opacityVertexArray,Ske,!0),this.opacityVertexBuffer.itemSize=1),(r||i)&&this.programConfigurations.upload(e))}destroy(){this.layoutVertexBuffer&&(this.layoutVertexBuffer.destroy(),this.indexBuffer.destroy(),this.programConfigurations.destroy(),this.segments.destroy(),this.dynamicLayoutVertexBuffer.destroy(),this.opacityVertexBuffer.destroy())}};Ae("SymbolBuffers",Bw);var jw=class{constructor(e,t,r){this.layoutVertexArray=new e,this.layoutAttributes=t,this.indexArray=new r,this.segments=new $r,this.collisionVertexArray=new YTe}upload(e){this.layoutVertexBuffer=e.createVertexBuffer(this.layoutVertexArray,this.layoutAttributes),this.indexBuffer=e.createIndexBuffer(this.indexArray),this.collisionVertexBuffer=e.createVertexBuffer(this.collisionVertexArray,uke.members,!0)}destroy(){this.layoutVertexBuffer&&(this.layoutVertexBuffer.destroy(),this.indexBuffer.destroy(),this.segments.destroy(),this.collisionVertexBuffer.destroy())}};Ae("CollisionBuffers",jw);var Jd=class{constructor(e){this.collisionBoxArray=e.collisionBoxArray,this.zoom=e.zoom,this.overscaling=e.overscaling,this.layers=e.layers,this.layerIds=this.layers.map(s=>s.id),this.index=e.index,this.pixelRatio=e.pixelRatio,this.sourceLayerIndex=e.s
741ourceLayerIndex,this.hasDependencies=!1,this.hasRTLText=!1,this.sortKeyRanges=[],this.collisionCircleArray=[];let t=this.layers[0]._unevaluatedLayout._values;this.textSizeData=I8(this.zoom,t["text-size"]),this.iconSizeData=I8(this.zoom,t["icon-size"]);let r=this.layers[0].layout,i=r.get("symbol-sort-key"),n=r.get("symbol-z-order");this.canOverlap=By(r,"text-overlap","text-allow-overlap")!=="never"||By(r,"icon-overlap","icon-allow-overlap")!=="never"||r.get("text-ignore-placement")||r.get("icon-ignore-placement"),this.sortFeaturesByKey=n!=="viewport-y"&&!i.isConstant();let a=n==="viewport-y"||n==="auto"&&!this.sortFeaturesByKey;this.sortFeaturesByY=a&&this.canOverlap,r.get("symbol-placement")==="point"&&(this.writingModes=r.get("text-writing-mode").map(s=>WL[s])),this.stateDependentLayerIds=this.layers.filter(s=>s.isStateDependent()).map(s=>s.id),this.sourceID=e.sourceID}createArrays(){this.text=new Bw(new Cc(this.layers,this.zoom,e=>e.startsWith("text"))),this.icon=new Bw(new Cc(this.layers,this.zoom,e=>e.startsWith("icon"))),this.glyphOffsetArray=new uL,this.lineVertexArray=new cL,this.symbolInstances=new lL,this.textAnchorOffsets=new hL}calculateGlyphDependencies(e,t,r,i,n){for(let a of e)if(t[a.codePointAt(0)]=!0,(r||i)&&n){let s=pke[a];s&&(t[s.codePointAt(0)]=!0)}}populate(e,t,r){var m;let i=this.layers[0],n=i.layout,a=n.get("text-font"),s=n.get("text-field"),o=n.get("icon-image"),l=(s.value.kind!=="constant"||s.value.value instanceof dl&&!s.value.value.isEmpty()||s.value.value.toString().length>0)&&(a.value.kind!=="constant"||a.value.value.length>0),u=o.value.kind!=="constant"||!!o.value.value||Object.keys(o.parameters).length>0,c=n.get("symbol-sort-key");if(this.features=[],!l&&!u)return;let d=t.iconDependencies,h=t.glyphDependencies,f=t.availableImages,p=new Tr(this.zoom);for(let{feature:g,id:v,index:x,sourceLayerIndex:_}of e){let y=i._featureFilter.needGeometry,w=Bc(g,y);if(!i._featureFilter.filter(p,w,r))continue;y||(w.geometry=Nc(g));let $;if(l){let I=i.getValueAndResolveTokens("text-field",w,r,f),P=dl.factory(I);this.hasRTLText||(this.hasRTLText=Tke(P)),(!this.hasRTLText||Oh.getRTLTextPluginStatus()==="unavailable"||this.hasRTLText&&Oh.isParsed())&&($=hke(P,i,w))}let S;if(u){let I=i.getValueAndResolveTokens("icon-image",w,r,f);S=I instanceof uo?I:uo.fromString(I)}if(!$&&!S)continue;let E=this.sortFeaturesByKey?c.evaluate(w,{},r):void 0,C={id:v,text:$,icon:S,index:x,sourceLayerIndex:_,geometry:w.geometry,properties:g.properties,type:yg.types[g.type],sortKey:E};if(this.features.push(C),S&&(d[S.name]=!0),$){let I=a.evaluate(w,{},r).join(","),P=n.get("text-rotation-alignment")!=="viewport"&&n.get("symbol-placement")!=="point";this.allowVerticalPlacement=(m=this.writingModes)==null?void 0:m.includes(2);for(let T of $.sections)if(T.image)d[T.image.name]=!0;else{let D=$Te($.toString()),A=T.fontStack||I;h[A]||(h[A]={}),this.calculateGlyphDependencies(T.text,h[A],P,this.allowVerticalPlacement,D)}}}n.get("symbol-placement")==="line"&&(this.features=fke(this.features)),this.sortFeaturesByKey&&this.features.sort((g,v)=>g.sortKey-v.sortKey)}update(e,t,r){this.stateDependentLayers.length&&(this.text.programConfigurations.updatePaintArrays(e,t,this.layers,{imagePositions:r}),this.icon.programConfigurations.updatePaintArrays(e,t,this.layers,{imagePositions:r}))}isEmpty(){return this.symbolInstances.length===0&&!this.hasRTLText}uploadPending(){return!this.uploaded||this.text.programConfigurations.needsUpload||this.icon.programConfigurations.needsUpload}upload(e){!this.uploaded&&this.hasDebugData()&&(this.textCollisionBox.upload(e),this.iconCollisionBox.upload(e)),this.text.upload(e,this.sortFeaturesByY,!this.uploaded,this.text.programConfigurations.needsUpload),this.icon.upload(e,this.sortFeaturesByY,!this.uploaded,this.icon.programConfigurations.needsUpload),this.uploaded=!0}destroyDebugData(){this.textCollisionBox.destroy(),this.iconCollisionBox.destroy()}destroy(){this.text.destroy(),this.icon.destroy(),this.hasDebugData()&&this.destroyDebugData()}addToLineVertexArray(e,t){let r=this.lineVertexArray.length;if(e.segment!==void 0){let i=e.dist(t[e.segment+1]),n=e.dist(t[e.segment]),a={};for(let s=e.segment+1;s<t.length;s++)a[s]={x:t[s].x,y:t[s].y,tileUnitDistanceFromAnchor:i},s<t.length-1&&(i+=t[s+1].dist(t[s]));for(let s=e.segment||0;s>=0;s--)a[s]={x:t[s].x,y:t[s].y,tileUnitDistanceFromAnchor:n},s>0&&(n+=t[s-1].dist(t[s]));for(let s=0;s<t.length;s++){let o=a[s];this.lineVertexArray.emplaceBack(o.x,o.y,o.tileUnitDistanceFromAnchor)}}return{lineStartIndex:r,lineLength:this.lineVertexArray.length-r}}addSymbols(e,t,r,i,n,a,s,o,l,u,c,d){let h=e.indexArray,f=e.layoutVertexArray,p=e.segments.prepareSegment(4*t.length,f,h,this.canOverlap?a.sortKey:void 0),m=this.glyphOffsetArray.length,g=p.vertexLength,v=this.allowVerticalPlacement&&s===2?Math.PI/2:0,x=a.text&&a.text.sections;for(let _=0;_<t.length;_++){let{tl:y,tr:w,bl:$,br:S,tex:E,pixelOffsetTL:C,pixelOffsetBR:I,minFontScaleX:P,minFontScaleY:T,glyphOffset:D,isSDF:A,sectionIndex:z}=t[_],R=p.vertexLength,O=D[1];S0(f,o.x,o.y,y.x,O+y.y,E.x,E.y,r,A,C.x,C.y,P,T),S0(f,o.x,o.y,w.x,O+w.y,E.x+E.w,E.y,r,A,I.x,C.y,P,T),S0(f,o.x,o.y,$.x,O+$.y,E.x,E.y+E.h,r,A,C.x,I.y,P,T),S0(f,o.x,o.y,S.x,O+S.y,E.x+E.w,E.y+E.h,r,A,I.x,I.y,P,T),Bm(e.dynamicLayoutVertexArray,o,v),h.emplaceBack(R,R+2,R+1),h.emplaceBack(R+1,R+2,R+3),p.vertexLength+=4,p.primitiveLength+=2,this.glyphOffsetArray.emplaceBack(D[0]),(_===t.length-1||z!==t[_+1].sectionIndex)&&e.programConfigurations.populatePaintArrays(f.length,a,a.index,{imagePositions:{},canonical:d,formattedSection:x==null?void 0:x[z]})}e.placedSymbolArray.emplaceBack(o.x,o.y,m,this.glyphOffsetArray.length-m,g,l,u,o.segment,r?r[0]:0,r?r[1]:0,i[0],i[1],s,0,!1,0,c)}_addCollisionDebugVertex(e,t,r,i,n,a){return t.emplaceBack(0,0),e.emplaceBack(r.x,r.y,i,n,Math.round(a.x),Math.round(a.y))}addCollisionDebugVertices(e,t,r,i,n,a,s){let o=n.segments.prepareSegment(4,n.layoutVertexArray,n.indexArray),l=o.vertexLength,u=n.layoutVertexArray,c=n.
vendor: 4,891 bytes, line 741
741collisionVertexArray,d=s.anchorX,h=s.anchorY;this._addCollisionDebugVertex(u,c,a,d,h,new de(e,t)),this._addCollisionDebugVertex(u,c,a,d,h,new de(r,t)),this._addCollisionDebugVertex(u,c,a,d,h,new de(r,i)),this._addCollisionDebugVertex(u,c,a,d,h,new de(e,i)),o.vertexLength+=4;let f=n.indexArray;f.emplaceBack(l,l+1),f.emplaceBack(l+1,l+2),f.emplaceBack(l+2,l+3),f.emplaceBack(l+3,l),o.primitiveLength+=4}addDebugCollisionBoxes(e,t,r,i){for(let n=e;n<t;n++){let a=this.collisionBoxArray.get(n),s=a.x1,o=a.y1,l=a.x2,u=a.y2;this.addCollisionDebugVertices(s,o,l,u,i?this.textCollisionBox:this.iconCollisionBox,a.anchorPoint,r)}}generateCollisionDebugBuffers(){this.hasDebugData()&&this.destroyDebugData(),this.textCollisionBox=new jw(u8,k8.members,Cw),this.iconCollisionBox=new jw(u8,k8.members,Cw);for(let e=0;e<this.symbolInstances.length;e++){let t=this.symbolInstances.get(e);this.addDebugCollisionBoxes(t.textBoxStartIndex,t.textBoxEndIndex,t,!0),this.addDebugCollisionBoxes(t.verticalTextBoxStartIndex,t.verticalTextBoxEndIndex,t,!0),this.addDebugCollisionBoxes(t.iconBoxStartIndex,t.iconBoxEndIndex,t,!1),this.addDebugCollisionBoxes(t.verticalIconBoxStartIndex,t.verticalIconBoxEndIndex,t,!1)}}_deserializeCollisionBoxesForSymbol(e,t,r,i,n,a,s,o,l){let u={};for(let c=t;c<r;c++){let d=e.get(c);u.textBox={x1:d.x1,y1:d.y1,x2:d.x2,y2:d.y2,anchorPointX:d.anchorPointX,anchorPointY:d.anchorPointY},u.textFeatureIndex=d.featureIndex;break}for(let c=i;c<n;c++){let d=e.get(c);u.verticalTextBox={x1:d.x1,y1:d.y1,x2:d.x2,y2:d.y2,anchorPointX:d.anchorPointX,anchorPointY:d.anchorPointY},u.verticalTextFeatureIndex=d.featureIndex;break}for(let c=a;c<s;c++){let d=e.get(c);u.iconBox={x1:d.x1,y1:d.y1,x2:d.x2,y2:d.y2,anchorPointX:d.anchorPointX,anchorPointY:d.anchorPointY},u.iconFeatureIndex=d.featureIndex;break}for(let c=o;c<l;c++){let d=e.get(c);u.verticalIconBox={x1:d.x1,y1:d.y1,x2:d.x2,y2:d.y2,anchorPointX:d.anchorPointX,anchorPointY:d.anchorPointY},u.verticalIconFeatureIndex=d.featureIndex;break}return u}deserializeCollisionBoxes(e){this.collisionArrays=[];for(let t=0;t<this.symbolInstances.length;t++){let r=this.symbolInstances.get(t);this.collisionArrays.push(this._deserializeCollisionBoxesForSymbol(e,r.textBoxStartIndex,r.textBoxEndIndex,r.verticalTextBoxStartIndex,r.verticalTextBoxEndIndex,r.iconBoxStartIndex,r.iconBoxEndIndex,r.verticalIconBoxStartIndex,r.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(e,t){let r=e.placedSymbolArray.get(t),i=r.vertexStartIndex+r.numGlyphs*4;for(let n=r.vertexStartIndex;n<i;n+=4)e.indexArray.emplaceBack(n,n+2,n+1),e.indexArray.emplaceBack(n+1,n+2,n+3)}getSortedSymbolIndexes(e){if(this.sortedAngle===e&&this.symbolInstanceIndexes!==void 0)return this.symbolInstanceIndexes;let t=Math.sin(e),r=Math.cos(e),i=[],n=[],a=[];for(let s=0;s<this.symbolInstances.length;++s){a.push(s);let o=this.symbolInstances.get(s);i.push(Math.round(t*o.anchorX+r*o.anchorY)|0),n.push(o.featureIndex)}return a.sort((s,o)=>i[s]-i[o]||n[o]-n[s]),a}addToSortKeyRanges(e,t){let r=this.sortKeyRanges[this.sortKeyRanges.length-1];(r==null?void 0:r.sortKey)===t?r.symbolInstanceEnd=e+1:this.sortKeyRanges.push({sortKey:t,symbolInstanceStart:e,symbolInstanceEnd:e+1})}sortFeatures(e){if(this.sortFeaturesByY&&this.sortedAngle!==e&&!(this.text.segments.get().length>1||this.icon.segments.get().length>1)){this.symbolInstanceIndexes=this.getSortedSymbolIndexes(e),this.sortedAngle=e,this.text.indexArray.clear(),this.icon.indexArray.clear(),this.featureSortOrder=[];for(let t of this.symbolInstanceIndexes){let r=this.symbolInstances.get(t);this.featureSortOrder.push(r.featureIndex);let i=[r.rightJustifiedTextSymbolIndex,r.centerJustifiedTextSymbolIndex,r.leftJustifiedTextSymbolIndex];for(let n=0;n<i.length;n++){let a=i[n];a>=0&&i.indexOf(a)===n&&this.addIndicesForPlacedSymbol(this.text,a)}r.verticalPlacedTextSymbolIndex>=0&&this.addIndicesForPlacedSymbol(this.text,r.verticalPlacedTextSymbolIndex),r.placedIconSymbolIndex>=0&&this.addIndicesForPlacedSymbol(this.icon,r.placedIconSymbolIndex),r.verticalPlacedIconSymbolIndex>=0&&this.addIndicesForPlacedSymbol(this.icon,r.verticalPlacedIconSymbolIndex)}this.text.indexBuffer&&this.text.indexBuffer.updateData(this.text.indexArray),this.icon.indexBuffer&&this.icon.indexBuffer.updateData(this.icon.indexArray)}}};Ae("SymbolBucket",Jd,{omit:["layers","collisionBoxArray","features","compareText"]}),Jd.MAX_GLYPHS=65535,Jd.addDynamicAttributes=Bm;function Cke(e,t){return t.replace(/{([^{}]+)}/g,(r,i)=>e&&i in e?String(e[i]):"")}let kke;
vendor: 19,089 bytes, line 741
741const Eke=()=>kke||(kke=new Mi({"symbol-placement":new Pe(ce.layout_symbol["symbol-placement"],"symbol-placement"),"symbol-spacing":new Pe(ce.layout_symbol["symbol-spacing"],"symbol-spacing"),"symbol-avoid-edges":new Pe(ce.layout_symbol["symbol-avoid-edges"],"symbol-avoid-edges"),"symbol-sort-key":new Ye(ce.layout_symbol["symbol-sort-key"],"symbol-sort-key"),"symbol-z-order":new Pe(ce.layout_symbol["symbol-z-order"],"symbol-z-order"),"icon-allow-overlap":new Pe(ce.layout_symbol["icon-allow-overlap"],"icon-allow-overlap"),"icon-overlap":new Pe(ce.layout_symbol["icon-overlap"],"icon-overlap"),"icon-ignore-placement":new Pe(ce.layout_symbol["icon-ignore-placement"],"icon-ignore-placement"),"icon-optional":new Pe(ce.layout_symbol["icon-optional"],"icon-optional"),"icon-rotation-alignment":new Pe(ce.layout_symbol["icon-rotation-alignment"],"icon-rotation-alignment"),"icon-size":new Ye(ce.layout_symbol["icon-size"],"icon-size"),"icon-text-fit":new Pe(ce.layout_symbol["icon-text-fit"],"icon-text-fit"),"icon-text-fit-padding":new Pe(ce.layout_symbol["icon-text-fit-padding"],"icon-text-fit-padding"),"icon-image":new Ye(ce.layout_symbol["icon-image"],"icon-image"),"icon-rotate":new Ye(ce.layout_symbol["icon-rotate"],"icon-rotate"),"icon-padding":new Ye(ce.layout_symbol["icon-padding"],"icon-padding"),"icon-keep-upright":new Pe(ce.layout_symbol["icon-keep-upright"],"icon-keep-upright"),"icon-offset":new Ye(ce.layout_symbol["icon-offset"],"icon-offset"),"icon-anchor":new Ye(ce.layout_symbol["icon-anchor"],"icon-anchor"),"icon-pitch-alignment":new Pe(ce.layout_symbol["icon-pitch-alignment"],"icon-pitch-alignment"),"text-pitch-alignment":new Pe(ce.layout_symbol["text-pitch-alignment"],"text-pitch-alignment"),"text-rotation-alignment":new Pe(ce.layout_symbol["text-rotation-alignment"],"text-rotation-alignment"),"text-field":new Ye(ce.layout_symbol["text-field"],"text-field"),"text-font":new Ye(ce.layout_symbol["text-font"],"text-font"),"text-size":new Ye(ce.layout_symbol["text-size"],"text-size"),"text-max-width":new Ye(ce.layout_symbol["text-max-width"],"text-max-width"),"text-line-height":new Pe(ce.layout_symbol["text-line-height"],"text-line-height"),"text-letter-spacing":new Ye(ce.layout_symbol["text-letter-spacing"],"text-letter-spacing"),"text-justify":new Ye(ce.layout_symbol["text-justify"],"text-justify"),"text-radial-offset":new Ye(ce.layout_symbol["text-radial-offset"],"text-radial-offset"),"text-variable-anchor":new Pe(ce.layout_symbol["text-variable-anchor"],"text-variable-anchor"),"text-variable-anchor-offset":new Ye(ce.layout_symbol["text-variable-anchor-offset"],"text-variable-anchor-offset"),"text-anchor":new Ye(ce.layout_symbol["text-anchor"],"text-anchor"),"text-max-angle":new Pe(ce.layout_symbol["text-max-angle"],"text-max-angle"),"text-writing-mode":new Pe(ce.layout_symbol["text-writing-mode"],"text-writing-mode"),"text-rotate":new Ye(ce.layout_symbol["text-rotate"],"text-rotate"),"text-padding":new Pe(ce.layout_symbol["text-padding"],"text-padding"),"text-keep-upright":new Pe(ce.layout_symbol["text-keep-upright"],"text-keep-upright"),"text-transform":new Ye(ce.layout_symbol["text-transform"],"text-transform"),"text-offset":new Ye(ce.layout_symbol["text-offset"],"text-offset"),"text-allow-overlap":new Pe(ce.layout_symbol["text-allow-overlap"],"text-allow-overlap"),"text-overlap":new Pe(ce.layout_symbol["text-overlap"],"text-overlap"),"text-ignore-placement":new Pe(ce.layout_symbol["text-ignore-placement"],"text-ignore-placement"),"text-optional":new Pe(ce.layout_symbol["text-optional"],"text-optional")}));let Pke;const Mke=()=>Pke||(Pke=new Mi({"icon-opacity":new Ye(ce.paint_symbol["icon-opacity"],"icon-opacity"),"icon-color":new Ye(ce.paint_symbol["icon-color"],"icon-color"),"icon-halo-color":new Ye(ce.paint_symbol["icon-halo-color"],"icon-halo-color"),"icon-halo-width":new Ye(ce.paint_symbol["icon-halo-width"],"icon-halo-width"),"icon-halo-blur":new Ye(ce.paint_symbol["icon-halo-blur"],"icon-halo-blur"),"icon-translate":new Pe(ce.paint_symbol["icon-translate"],"icon-translate"),"icon-translate-anchor":new Pe(ce.paint_symbol["icon-translate-anchor"],"icon-translate-anchor"),"text-opacity":new Ye(ce.paint_symbol["text-opacity"],"text-opacity"),"text-color":new Ye(ce.paint_symbol["text-color"],"text-color",{runtimeType:Ss,getOverride:e=>e.textColor,hasOverride:e=>!!e.textColor}),"text-halo-color":new Ye(ce.paint_symbol["text-halo-color"],"text-halo-color"),"text-halo-width":new Ye(ce.paint_symbol["text-halo-width"],"text-halo-width"),"text-halo-blur":new Ye(ce.paint_symbol["text-halo-blur"],"text-halo-blur"),"text-translate":new Pe(ce.paint_symbol["text-translate"],"text-translate"),"text-translate-anchor":new Pe(ce.paint_symbol["text-translate-anchor"],"text-translate-anchor")}));var Fb={get paint(){return Mke()},get layout(){return Eke()}},KL=class{constructor(e){if(e.property.overrides===void 0)throw Error("overrides must be provided to instantiate FormatSectionOverride class");this.type=e.property.overrides?e.property.overrides.runtimeType:cg,this.defaultValue=e}evaluate(e){if(e.formattedSection){let t=this.defaultValue.property.overrides;if(t!=null&&t.hasOverride(e.formattedSection))return t.getOverride(e.formattedSection)}return e.feature&&e.featureState?this.defaultValue.evaluate(e.feature,e.featureState):this.defaultValue.property.specification.default}eachChild(e){if(!this.defaultValue.isConstant()){let t=this.defaultValue.value;e(t._styleExpression.expression)}}outputDefined(){return!1}serialize(){return null}};Ae("FormatSectionOverride",KL,{omit:["defaultValue"]});const XL=e=>e.type==="symbol";var Ike=class Uw extends Rs{constructor(t,r){super(t,Fb,r)}recalculate(t,r){if(super.recalculate(t,r),this.layout.get("icon-rotation-alignment")==="auto"&&(this.layout.get("symbol-placement")==="point"?this.layout._values["icon-rotation-alignment"]="viewport":this.layout._values["icon-rotation-alignment"]="map"),this.layout.get("text-rotation-alignment")==="auto"&&(this.layout.get("symbol-placement")==="point"?this.layout._values["text-rotation-alignment"]="viewport":this.layout._values["text-rotation-alignment"]="map"),this.layout.get("text-pitch-alignment")==="auto"&&(this.layout._values["text-pitch-alignment"]=this.layout.get("text-rotation-alignment")==="map"?"map":"viewport"),this.layout.get("icon-pitch-alignment")==="auto"&&(this.layout._values["icon-pitch-alignment"]=this.layout.get("icon-rotation-alignment")),this.layout.get("symbol-placement")==="point"){let i=this.layout.get("text-writing-mode");if(i){let n=[];for(let a of i)n.includes(a)||n.push(a);this.layout._values["text-writing-mode"]=n}else this.layout._values["text-writing-mode"]=["horizontal"]}this._setPaintOverrides()}getValueAndResolveTokens(t,r,i,n){let a=this.layout.get(t).evaluate(r,{},i,n),s=this._unevaluatedLayout._values[t];return!s.isDataDriven()&&!iv(s.value)&&a?Cke(r.properties,a):a}createBucket(t){return new Jd(t)}queryRadius(){return 0}queryIntersectsFeature(){throw Error("Should take a different path in FeatureIndex")}_setPaintOverrides(){for(let t of Fb.paint.overridableProperties){if(!Uw.hasPaintOverride(this.layout,t))continue;let r=this.paint.get(t),i=new Y$(new KL(r),`layers[${this.id}].paint.${r.property.name}`,r.property.specification),n=null;n=r.value.kind==="constant"||r.value.kind==="source"?new Em("source",i):new My("composite",i,r.value.zoomStops),this.paint._values[t]=new vs(r.property,n,r.parameters)}}_handleOverridablePaintPropertyUpdate(t,r,i){return!this.layout||r.isDataDriven()||i.isDataDriven()?!1:Uw.hasPaintOverride(this.layout,t)}static hasPaintOverride(t,r){let i=t.get("text-field"),n=Fb.paint.properties[r],a=!1,s=o=>{var l;for(let u of o)if((l=n.overrides)!=null&&l.hasOverride(u)){a=!0;return}};if(i.value.kind==="constant"&&i.value.value instanceof dl)s(i.value.value.sections);else if(i.value.kind==="source"||i.value.kind==="composite"){let o=u=>{if(!a)if(u instanceof Sm&&ni(u.value)===dg){let c=u.value;s(c.sections)}else u instanceof cO?s(u.sections):u.eachChild(o)},l=i.value;l._styleExpression&&o(l._styleExpression.expression)}return a}};let Ake;const Dke=()=>Ake||(Ake=new Mi({"background-color":new Pe(ce.paint_background["background-color"],"background-color"),"background-pattern":new rL(ce.paint_background["background-pattern"],"background-pattern"),"background-opacity":new Pe(ce.paint_background["background-opacity"],"background-opacity")}));var Rke={get paint(){return Dke()}};const Oke=e=>e.type==="background";var Lke=class extends Rs{constructor(e,t){super(e,Rke,t)}};function Fke(e){let t=[],r=e.id;return r===void 0&&t.push(new Te(`layers.${r}`,null,'missing required property "id"')),e.render===void 0&&t.push(new Te(`layers.${r}`,null,'missing required method "render"')),e.renderingMode&&e.renderingMode!=="2d"&&e.renderingMode!=="3d"&&t.push(new Te(`layers.${r}`,null,'property "renderingMode" must be either "2d" or "3d"')),t}const zke=e=>e.type==="custom";var Nke=class extends Rs{constructor(e,t){super(e,{},t),this.onAdd=r=>{this.implementation.onAdd&&this.implementation.onAdd(r,r.painter.context.gl)},this.onRemove=r=>{this.implementation.onRemove&&this.implementation.onRemove(r,r.painter.context.gl)},this.implementation=e}is3D(){return this.implementation.renderingMode==="3d"}hasOffscreenPass(){return this.implementation.prerender!==void 0}recalculate(){}updateTransitions(){}hasTransition(){return!1}serialize(){throw Error("Custom layers cannot be serialized")}};function zb(e,t){if(e.type==="custom")return new Nke(e,t);switch(e.type){case"background":return new Lke(e,t);case"circle":return new C6e(e,t);case"color-relief":return new U6e(e,t);case"fill":return new wCe(e,t);case"fill-extrusion":return new VCe(e,t);case"heatmap":return new I6e(e,t);case"hillshade":return new L6e(e,t);case"line":return new ske(e,t);case"raster":return new DTe(e,t);case"symbol":return new Ike(e,t)}}var Bke=class{constructor(e){this._methodToThrottle=e,this._triggered=!1,this._channel=new MessageChannel,this._channel.port2.onmessage=()=>{this._triggered=!1,this._methodToThrottle()}}trigger(){var e;this._triggered||(this._triggered=!0,(e=this._channel)==null||e.port1.postMessage(!0))}remove(){delete this._channel,this._methodToThrottle=()=>{}}};const jke={once:!0};var Uke=class{constructor(e,t){this.target=e,this.mapId=t,this.resolveRejects={},this.tasks={},this.taskQueue=[],this.abortControllers={},this.messageHandlers={},this.invoker=new Bke(()=>this.process()),this.subscription=qx(this.target,"message",r=>this.receive(r),!1),this.globalScope=Mh(self)?e:window}registerMessageHandler(e,t){this.messageHandlers[e]=t}unregisterMessageHandler(e){delete this.messageHandlers[e]}sendAsync(e,t){return new Promise((r,i)=>{let n=Math.round(Math.random()*1e18).toString(36).substring(0,10),a=t?qx(t.signal,"abort",()=>{a==null||a.unsubscribe(),delete this.resolveRejects[n];let l={id:n,type:"<cancel>",origin:location.origin,targetMapId:e.targetMapId,sourceMapId:this.mapId};this.target.postMessage(l),i(new lg(t.signal.reason))},jke):null;this.resolveRejects[n]={resolve:l=>{a==null||a.unsubscribe(),r(l)},reject:l=>{a==null||a.unsubscribe(),i(l)}};let s=[],o={...e,id:n,sourceMapId:this.mapId,origin:location.origin,data:Ip(e.data,s)};this.target.postMessage(o,{transfer:s})})}receive(e){let t=e.data,r=t.id,i=["file://","resource://android","null"],n=[t.origin,location.origin],a=t.origin===location.origin,s=n.some(o=>i.includes(o));if(!(!a&&!s)&&!(t.targetMapId&&this.mapId!==t.targetMapId)){if(t.type==="<cancel>"){delete this.tasks[r];let o=this.abortControllers[r];delete this.abortControllers[r],o&&o.abort();return}if(Mh(self)||t.mustQueue){this.tasks[r]=t,this.taskQueue.push(r),this.invoker.trigger();return}this.processTask(r,t)}}process(){if(this.taskQueue.length===0)return;let e=this.taskQueue.shift(),t=this.tasks[e];delete this.tasks[e],this.taskQueue.length>0&&this.invoker.trigger(),t&&this.processTask(e,t)}async processTask(e,t){if(t.type==="<response>"){let n=this.resolveRejects[e];if(delete this.resolveRejects[e],!n)return;t.error?n.reject(mn(Ap(t.error))):n.resolve(Ap(t.data));return}if(!this.messageHandlers[t.type]){this.completeTask(e,null,null);return}let r=Ap(t.data),i=new AbortController;this.abortControllers[e]=i;try{let n=await this.messageHandlers[t.type](t.sourceMapId,r,i);this.completeTask(e,null,n)}catch(n){this.completeTask(e,mn(n))}}completeTask(e,t,r){let i=[];delete this.abortControllers[e];let n={id:e,type:"<response>",sourceMapId:this.mapId,origin:location.origin,error:t?Ip(t):null,data:Ip(r,i)};this.target.postMessage(n,{transfer:i})}remove(){this.invoker.remove(),this.subscription.unsubscribe()}};function Vke(e,t,r){return!(e<0||e>25||r<0||r>=2**e||t<0||t>=2**e)}function A8(e,t){let{x:r,y:i}=nr.fromLngLat(t);return!(e<0||e>25||i<0||i>=1||r<0||r>=1)}var pv=class{constructor(e,t,r){if(!Vke(e,t,r))throw Error(`x=${t}, y=${r}, z=${e} outside of bounds. 0<=x<${2**e}, 0<=y<${2**e} 0<=z<=25 `);this.z=e,this.x=t,this.y=r,this.key=Qd(0,e,e,t,r)}equals(e){return this.z===e.z&&this.x===e.x&&this.y===e.y}url(e,t,r){let i=qke(this.x,this.y,this.z),n=Gke(this.z,this.x,this.y);return e[(this.x+this.y)%e.length].replace(/{prefix}/g,(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(r==="tms"?2**this.z-this.y-1:this.y)).replace(/{ratio}/g,t>1?"@2x":"").replace(/{quadkey}/g,n).replace(/{bbox-epsg-3857}/g,i)}isChildOf(e){let t=this.z-e.z;return t>0&&e.x===this.x>>t&&e.y===this.y>>t}getTilePoint(e){let t=2**this.z;return new de((e.x*t-this.x)*ye,(e.y*t-this.y)*ye)}toString(){return`${this.z}/${this.x}/${this.y}`}},jy=class{constructor(e,t){this.wrap=e,this.canonical=t,this.key=Qd(e,t.z,t.z,t.x,t.y)}},Ri=class Ra{constructor(t,r,i,n,a){if(this.terrainRttPosMatrix32f=null,t<i)throw Error(`overscaledZ should be >= z; overscaledZ = ${t}; z = ${i}`);this.overscaledZ=t,this.wrap=r,this.canonical=new pv(i,+n,+a),this.key=Qd(r,t,i,n,a)}clone(){return new Ra(this.overscaledZ,this.wrap,this.canonical.z,this.canonical.x,this.canonical.y)}equals(t){return this.overscaledZ===t.overscaledZ&&this.wrap===t.wrap&&this.canonical.equals(t.canonical)}scaledTo(t){if(t>this.overscaledZ)throw Error(`targetZ > this.overscaledZ; targetZ = ${t}; overscaledZ = ${this.overscaledZ}`);let r=this.canonical.z-t;return t>this.canonical.z?new Ra(t,this.wrap,this.canonical.z,this.canonical.x,this.canonical.y):new Ra(t,this.wrap,t,this.canonical.x>>r,this.canonical.y>>r)}isOverscaled(){return this.overscaledZ>this.canonical.z}calculateScaledKey(t,r){if(t>this.overscaledZ)throw Error(`targetZ > this.overscaledZ; targetZ = ${t}; overscaledZ = ${this.overscaledZ}`);let i=this.canonical.z-t;return t>this.canonical.z?Qd(this.wrap*+r,t,this.canonical.z,this.canonical.x,this.canonical.y):Qd(this.wrap*+r,t,t,this.canonical.x>>i,this.canonical.y>>i)}isChildOf(t){if(t.wrap!==this.wrap||this.overscaledZ-t.overscaledZ<=0)return!1;if(t.overscaledZ===0)return this.overscaledZ>0;let r=this.canonical.z-t.canonical.z;return r<0?!1:t.canonical.x===this.canonical.x>>r&&t.canonical.y===this.canonical.y>>r}children(t){if(this.overscaledZ>=t)return[new Ra(this.overscaledZ+1,this.wrap,this.canonical.z,this.canonical.x,this.canonical.y)];let r=this.canonical.z+1,i=this.canonical.x*2,n=this.canonical.y*2;return[new Ra(r,this.wrap,r,i,n),new Ra(r,this.wrap,r,i+1,n),new Ra(r,this.wrap,r,i,n+1),new Ra(r,this.wrap,r,i+1,n+1)]}isLessThan(t){return this.wrap<t.wrap?!0:this.wrap>t.wrap?!1:this.overscaledZ<t.overscaledZ?!0:this.overscaledZ>t.overscaledZ?!1:this.canonical.x<t.canonical.x?!0:this.canonical.x>t.canonical.x?!1:this.canonical.y<t.canonical.y}wrapped(){return new Ra(this.overscaledZ,0,this.canonical.z,this.canonical.x,this.canonical.y)}unwrapTo(t){return new Ra(this.overscaledZ,t,this.canonical.z,this.canonical.x,this.canonical.y)}overscaleFactor(){return 2**(this.overscaledZ-this.canonical.z)}toUnwrapped(){return new jy(this.wrap,this.canonical)}toString(){return`${this.overscaledZ}/${this.canonical.x}/${this.canonical.y}`}getTilePoint(t){return this.canonical.getTilePoint(new nr(t.x-this.wrap,t.y))}normalizeCoordinates(t,r,i=ye){if(t>=0&&t<i&&r>=0&&r<i)return{tileID:this,x:t,y:r};let n=Math.floor(t/i),a=Math.floor(r/i),s=t-n*i,o=r-a*i,l=this.canonical.z,u=1<<l,c=this.canonical.y+a;if(c<0||c>=u)return null;let d=this.canonical.x+n,h=this.wrap;return d<0?(h-=Math.ceil(-d/u),d=(d%u+u)%u):d>=u&&(h+=Math.floor(d/u),d%=u),{tileID:new Ra(this.overscaledZ,h,l,d,c),x:s,y:o}}};function Qd(e,t,r,i,n){e*=2,e<0&&(e=e*-1-1);let a=1<<r;return(a*a*e+a*n+i).toString(36)+r.toString(36)+t.toString(36)}const Nb=Math.PI*6378137;function qke(e,t,r){t=2**r-t-1;let i=D8(e*256,t*256,r),n=D8((e+1)*256,(t+1)*256,r);return`${i[0]},${i[1]},${n[0]},${n[1]}`}function D8(e,t,r){let i=2*Nb/256/2**r;return[e*i-Nb,t*i-Nb]}function Gke(e,t,r){let i="";for(let n=e;n>0;n--){let a=1<<n-1;i+=(t&a?1:0)+(r&a?2:0)}return i}function R8(e,t){let r=Math.abs(e.wrap*2)-+(e.wrap<0),i=Math.abs(t.wrap*2)-+(t.wrap<0);return e.overscaledZ-t.overscaledZ||i-r||t.canonical.y-e.canonical.y||t.canonical.x-e.canonical.x}Ae("CanonicalTileID",pv),Ae("OverscaledTileID",Ri,{omit:["terrainRttPosMatrix32f"]});var no=class Vw{constructor(){this.minX=1/0,this.maxX=-1/0,this.minY=1/0,this.maxY=-1/0}extend(t){return this.minX=Math.min(this.minX,t.x),this.minY=Math.min(this.minY,t.y),this.maxX=Math.max(this.maxX,t.x),this.maxY=Math.max(this.maxY,t.y),this}expandBy(t){return this.minX-=t,this.minY-=t,this.maxX+=t,this.maxY+=t,(this.minX>this.maxX||this.minY>this.maxY)&&(this.minX=1/0,this.maxX=-1/0,this.minY=1/0,this.maxY=-1/0),this}shrinkBy(t){return this.expandBy(-t)}map(t){let r=new Vw;return r.extend(t(new de(this.minX,this.minY))),r.extend(t(new de(this.maxX,this.minY))),r.extend(t(new de(this.minX,this.maxY))),r.extend(t(new de(this.maxX,this.maxY))),r}static fromPoints(t){let r=new Vw;for(let i of t)r.extend(i);return r}contains(t){return t.x>=this.minX&&t.x<=this.maxX&&t.y>=this.minY&&t.y<=this.maxY}empty(){return this.minX>this.maxX}width(){return this.maxX-this.minX}height(){return this.maxY-this.minY}covers(t){return!this.empty()&&!t.empty()&&t.minX>=this.minX&&t.maxX<=this.maxX&&t.minY>=this.minY&&t.maxY<=this.maxY}intersects(t){return!this.empty()&&!t.empty()&&t.minX<=this.maxX&&t.maxX>=this.minX&&t.minY<=this.maxY&&t.maxY>=this.minY}};const __="_geojsonTileLayer";var Hke=class{constructor(e){this._stringToNumber={},this._numberToString=[];for(let t=0;t<e.length;t++){let r=e[t];this._stringToNumber[r]=t,this._numberToString[t]=r}}encode(e){return this._stringToNumber[e]}decode(e){if(e>=this._numberToString.length)throw Error(`Out of bounds. Index requested n=${e} can't be >= this._numberToString.length ${this._numberToString.length}`);return this._numberToString[e]}},JL=class{constructor(e,t,r,i,n){this.type="Feature",this._vectorTileFeature=e,this._x=r,this._y=i,this._z=t;for(let a in e.properties)typeof e.properties[a]!="string"||!e.properties[a].startsWith("__$json__:")||(e.properties[a]=JSON.parse(e.properties[a].slice(10)));this.properties=e.properties,this.id=n}
vendor: 1,704 bytes, line 741
741projectPoint(e,t,r,i){return[(e.x+t)*360/i-180,360/Math.PI*Math.atan(Math.exp((1-(e.y+r)*2/i)*Math.PI))-90]}projectLine(e,t,r,i){return e.map(n=>this.projectPoint(n,t,r,i))}get geometry(){if(this._geometry)return this._geometry;let e=this._vectorTileFeature,t=e.extent*2**this._z,r=e.extent*this._x,i=e.extent*this._y,n=e.loadGeometry();switch(e.type){case 1:{let a=[];for(let o of n)a.push(o[0]);let s=this.projectLine(a,r,i,t);this._geometry=a.length===1?{type:"Point",coordinates:s[0]}:{type:"MultiPoint",coordinates:s};break}case 2:{let a=n.map(s=>this.projectLine(s,r,i,t));this._geometry=a.length===1?{type:"LineString",coordinates:a[0]}:{type:"MultiLineString",coordinates:a};break}case 3:{let a=LL(n),s=[];for(let o of a)s.push(o.map(l=>this.projectLine(l,r,i,t)));this._geometry=s.length===1?{type:"Polygon",coordinates:s[0]}:{type:"MultiPolygon",coordinates:s};break}default:throw Error(`unknown feature type: ${e.type}`)}return this._geometry}set geometry(e){this._geometry=e}toJSON(){let e={geometry:this.geometry};for(let t in this)t!=="_geometry"&&t!=="_vectorTileFeature"&&t!=="_x"&&t!=="_y"&&t!=="_z"&&(e[t]=this[t]);return e}},ef=class{constructor(e,t,r){this._name=e,this.dataBuffer=t,typeof r=="number"?this._size=r:(this.nullabilityBuffer=r,this._size=r.size())}getValue(e){return this.nullabilityBuffer&&!this.nullabilityBuffer.get(e)?null:this.getValueFromBuffer(e)}has(e){var t;return((t=this.nullabilityBuffer)==null?void 0:t.get(e))||!this.nullabilityBuffer}get name(){return this._name}get size(){return this._size}},mv=class extends ef{},hS=class extends mv{getValueFromBuffer(e){return this.dataBuffer[e]}},fS=class extends mv{getValueFromBuffer(e){return this.dataBuffer[e]}}
741,QL=class extends ef{constructor(e,t,r,i){super(e,t,i),this.delta=r}},pS=class extends QL{constructor(e,t,r,i){super(e,Int32Array.of(t),r,i)}getValueFromBuffer(e){return this.dataBuffer[0]+e*this.delta}},mS=class extends ef{constructor(e,t,r,i){super(e,i?Int32Array.of(t):Uint32Array.of(t),r)}getValueFromBuffer(e){return this.dataBuffer[0]}},Yke=class{constructor(e,t,r,i,n=4096){if(this._name=e,this._geometryVector=t,this._idVector=r,this._propertyVectors=i,this._extent=n,e.length===0)throw Error("Missing layer name")}get name(){return this._name}get idVector(){return this._idVector}get geometryVector(){return this._geometryVector}get propertyVectors(){return this._propertyVectors}getPropertyVector(e){return this.propertyVectorsMap||(this.propertyVectorsMap=new Map(this._propertyVectors.map(t=>[t.name,t]))),this.propertyVectorsMap.get(e)}get numFeatures(){return this.geometryVector.numGeometries}get extent(){return this._extent}getFeatures(){let e=[],t=this.geometryVector.getGeometries();for(let r=0;r<this.numFeatures;r++){let i;if(this.idVector){let s=this.idVector.getValue(r);i=this.containsMaxSafeIntegerValues(this.idVector)&&s!==null?Number(s):s}let n={coordinates:t[r],type:this.geometryVector.geometryType(r)},a={};for(let s of this.propertyVectors){if(!s)continue;let o=s.name,l=s.getValue(r);l!==null&&(a[o]=l)}e.push({id:i,geometry:n,properties:a})}return e}containsMaxSafeIntegerValues(e){return e instanceof hS||e instanceof mS||e instanceof pS||e instanceof fS}};const y_={FEATURE:0},zt={BOOLEAN:0,INT_8:1,UINT_8:2,INT_32:3,UINT_32:4,INT_64:5,UINT_64:6,FLOAT:7,DOUBLE:8,STRING:9},jm={GEOMETRY:0,STRUCT:1},gS={ID:0};var eF=class{constructor(e){this.value=e}get(){return this.value}set(e){this.value=e}increment(){return this.value++}add(e){this.value+=e}},dt;(function(e){e.NONE="NONE",e.DELTA="DELTA",e.COMPONENTWISE_DELTA="COMPONENTWISE_DELTA",e.RLE="RLE",e.MORTON="MORTON",e.PDE="PDE"})(dt||(dt={}));var Wo;(function(e){e.NONE="NONE",e.FAST_PFOR="FAST_PFOR",e.VARINT="VARINT"})(Wo||(Wo={}));const _S=new Uint32Array(33);_S[0]=0;for(let e=1;e<=32;e++)_S[e]=e===32?4294967295:4294967295>>>32-e;const qw=_S,tF=65536;function yS(e,t){return e-e%t}function Wke(e){return yS(e+31,32)}function Zke(e){if(!Number.isFinite(e)||e<=0)return tF;let t=yS(Math.floor(e),256);return t===0?256:t}function Kke(e){let t=e>>>0;return((t&255)<<24|(t&65280)<<8|t>>>8&65280|t>>>24&255)>>>0}function Xke(e,t,r,i){let n=i,a=e[t]>>>0,s=e[t+1]>>>0;r[n++]=a>>>0&3,r[n++]=a>>>2&3,r[n++]=a>>>4&3,r[n++]=a>>>6&3,r[n++]=a>>>8&3,r[n++]=a>>>10&3,r[n++]=a>>>12&3,r[n++]=a>>>14&3,r[n++]=a>>>16&3,r[n++]=a>>>18&3,r[n++]=a>>>20&3,r[n++]=a>>>22&3,r[n++]=a>>>24&3,r[n++]=a>>>26&3,r[n++]=a>>>28&3,r[n++]=a>>>30&3,r[n++]=s>>>0&3,r[n++]=s>>>2&3,r[n++]=s>>>4&3,r[n++]=s>>>6&3,r[n++]=s>>>8&3,r[n++]=s>>>10&3,r[n++]=s>>>12&3,r[n++]=s>>>14&3,r[n++]=s>>>16&3,r[n++]=s>>>18&3,r[n++]=s>>>20&3,r[n++]=s>>>22&3,r[n++]=s>>>24&3,r[n++]=s>>>26&3,r[n++]=s>>>28&3,r[n]=s>>>30&3}function Jke(e,t,r,i){let n=i,a=e[t]>>>0,s=e[t+1]>>>0,o=e[t+2]>>>0;r[n++]=a>>>0&7,r[n++]=a>>>3&7,r[n++]=a>>>6&7,r[n++]=a>>>9&7,r[n++]=a>>>12&7,r[n++]=a>>>15&7,r[n++]=a>>>18&7,r[n++]=a>>>21&7,r[n++]=a>>>24&7,r[n++]=a>>>27&7,r[n++]=(a>>>30|(s&1)<<2)&7,r[n++]=s>>>1&7,r[n++]=s>>>4&7,r[n++]=s>>>7&7,r[n++]=s>>>10&7,r[n++]=s>>>13&7,r[n++]=s>>>16&7,r[n++]=s>>>19&7,r[n++]=s>>>22&7,r[n++]=s>>>25&7,r[n++]=s>>>28&7,r[n++]=(s>>>31|(o&3)<<1)&7,r[n++]=o>>>2&7,r[n++]=o>>>5&7,r[n++]=o>>>8&7,r[n++]=o>>>11&7,r[n++]=o>>>14&7,r[n++]=o>>>17&7,r[n++]=o>>>20&7,r[n++]=o>>>23&7,r[n++]=o>>>
vendor: 8,203 bytes, line 741
74126&7,r[n]=o>>>29&7}function Qke(e,t,r,i){let n=i,a=e[t]>>>0,s=e[t+1]>>>0,o=e[t+2]>>>0,l=e[t+3]>>>0;r[n++]=a>>>0&15,r[n++]=a>>>4&15,r[n++]=a>>>8&15,r[n++]=a>>>12&15,r[n++]=a>>>16&15,r[n++]=a>>>20&15,r[n++]=a>>>24&15,r[n++]=a>>>28&15,r[n++]=s>>>0&15,r[n++]=s>>>4&15,r[n++]=s>>>8&15,r[n++]=s>>>12&15,r[n++]=s>>>16&15,r[n++]=s>>>20&15,r[n++]=s>>>24&15,r[n++]=s>>>28&15,r[n++]=o>>>0&15,r[n++]=o>>>4&15,r[n++]=o>>>8&15,r[n++]=o>>>12&15,r[n++]=o>>>16&15,r[n++]=o>>>20&15,r[n++]=o>>>24&15,r[n++]=o>>>28&15,r[n++]=l>>>0&15,r[n++]=l>>>4&15,r[n++]=l>>>8&15,r[n++]=l>>>12&15,r[n++]=l>>>16&15,r[n++]=l>>>20&15,r[n++]=l>>>24&15,r[n]=l>>>28&15}function e8e(e,t,r,i){let n=i,a=e[t]>>>0,s=e[t+1]>>>0,o=e[t+2]>>>0,l=e[t+3]>>>0,u=e[t+4]>>>0;r[n++]=a>>>0&31,r[n++]=a>>>5&31,r[n++]=a>>>10&31,r[n++]=a>>>15&31,r[n++]=a>>>20&31,r[n++]=a>>>25&31,r[n++]=(a>>>30|(s&7)<<2)&31,r[n++]=s>>>3&31,r[n++]=s>>>8&31,r[n++]=s>>>13&31,r[n++]=s>>>18&31,r[n++]=s>>>23&31,r[n++]=(s>>>28|(o&1)<<4)&31,r[n++]=o>>>1&31,r[n++]=o>>>6&31,r[n++]=o>>>11&31,r[n++]=o>>>16&31,r[n++]=o>>>21&31,r[n++]=o>>>26&31,r[n++]=(o>>>31|(l&15)<<1)&31,r[n++]=l>>>4&31,r[n++]=l>>>9&31,r[n++]=l>>>14&31,r[n++]=l>>>19&31,r[n++]=l>>>24&31,r[n++]=(l>>>29|(u&3)<<3)&31,r[n++]=u>>>2&31,r[n++]=u>>>7&31,r[n++]=u>>>12&31,r[n++]=u>>>17&31,r[n++]=u>>>22&31,r[n]=u>>>27&31}function t8e(e,t,r,i){let n=i,a=e[t]>>>0,s=e[t+1]>>>0,o=e[t+2]>>>0,l=e[t+3]>>>0,u=e[t+4]>>>0,c=e[t+5]>>>0;r[n++]=a>>>0&63,r[n++]=a>>>6&63,r[n++]=a>>>12&63,r[n++]=a>>>18&63,r[n++]=a>>>24&63,r[n++]=(a>>>30|(s&15)<<2)&63,r[n++]=s>>>4&63,r[n++]=s>>>10&63,r[n++]=s>>>16&63,r[n++]=s>>>22&63,r[n++]=(s>>>28|(o&3)<<4)&63,r[n++]=o>>>2&63,r[n++]=o>>>8&63,r[n++]=o>>>14&63,r[n++]=o>>>20&63,r[n++]=o>>>26&63,r[n++]=l>>>0&63,r[n++]=l>>>6&63,r[n++]=l>>>12&63,r[n++]=l>>>18&63,r[n++]=l>>>24&63,r[n++]=(l>>>30|(u&15)<<2)&63,r[n++]=u>>>4&63,r[n++]=u>>>10&63,r[n++]=u>>>16&63,r[n++]=u>>>22&63,r[n++]=(u>>>28|(c&3)<<4)&63,r[n++]=c>>>2&63,r[n++]=c>>>8&63,r[n++]=c>>>14&63,r[n++]=c>>>20&63,r[n]=c>>>26&63}function r8e(e,t,r,i){let n=i,a=e[t]>>>0,s=e[t+1]>>>0,o=e[t+2]>>>0,l=e[t+3]>>>0,u=e[t+4]>>>0,c=e[t+5]>>>0,d=e[t+6]>>>0;r[n++]=a>>>0&127,r[n++]=a>>>7&127,r[n++]=a>>>14&127,r[n++]=a>>>21&127,r[n++]=(a>>>28|(s&7)<<4)&127,r[n++]=s>>>3&127,r[n++]=s>>>10&127,r[n++]=s>>>17&127,r[n++]=s>>>24&127,r[n++]=(s>>>31|(o&63)<<1)&127,r[n++]=o>>>6&127,r[n++]=o>>>13&127,r[n++]=o>>>20&127,r[n++]=(o>>>27|(l&3)<<5)&127,r[n++]=l>>>2&127,r[n++]=l>>>9&127,r[n++]=l>>>16&127,r[n++]=l>>>23&127,r[n++]=(l>>>30|(u&31)<<2)&127,r[n++]=u>>>5&127,r[n++]=u>>>12&127,r[n++]=u>>>19&127,r[n++]=(u>>>26|(c&1)<<6)&127,r[n++]=c>>>1&127,r[n++]=c>>>8&127,r[n++]=c>>>15&127,r[n++]=c>>>22&127,r[n++]=(c>>>29|(d&15)<<3)&127,r[n++]=d>>>4&127,r[n++]=d>>>11&127,r[n++]=d>>>18&127,r[n]=d>>>25&127}function i8e(e,t,r,i){let n=i,a=e[t]>>>0,s=e[t+1]>>>0,o=e[t+2]>>>0,l=e[t+3]>>>0,u=e[t+4]>>>0,c=e[t+5]>>>0,d=e[t+6]>>>0,h=e[t+7]>>>0;r[n++]=a>>>0&255,r[n++]=a>>>8&255,r[n++]=a>>>16&255,r[n++]=a>>>24&255,r[n++]=s>>>0&255,r[n++]=s>>>8&255,r[n++]=s>>>16&255,r[n++]=s>>>24&255,r[n++]=o>>>0&255,r[n++]=o>>>8&255,r[n++]=o>>>16&255,r[n++]=o>>>24&255,r[n++]=l>>>0&255,r[n++]=l>>>8&255,r[n++]=l>>>16&255,r[n++]=l>>>24&255,r[n++]=u>>>0&255,r[n++]=u>>>8&255,r[n++]=u>>>16&255,r[n++]=u>>>24&255,r[n++]=c>>>0&255,r[n++]=c>>>8&255,r[n++]=c>>>16&255,r[n++]=c>>>24&255,r[n++]=d>>>0&255,r[n++]=d>>>8&255,r[n++]=d>>>16&255,r[n++]=d>>>24&255,r[n++]=h>>>0&255,r[n++]=h>>>8&255,r[n++]=h>>>16&255,r[n]=h>>>24&255}function n8e(e,t,r,i){let n=i,a=e[t]>>>0,s=e[t+1]>>>0,o=e[t+2]>>>0,l=e[t+3]>>>0,u=e[t+4]>>>0,c=e[t+5]>>>0,d=e[t+6]>>>0,h=e[t+7]>>>0,f=e[t+8]>>>0;r[n++]=a>>>0&511,r[n++]=a>>>9&511,r[n++]=a>>>18&511,r[n++]=(a>>>27|(s&15)<<5)&511,r[n++]=s>>>4&511,r[n++]=s>>>13&511,r[n++]=s>>>22&511,r[n++]=(s>>>31|(o&255)<<1)&511,r[n++]=o>>>8&511,r[n++]=o>>>17&511,r[n++]=(o>>>26|(l&7)<<6)&511,r[n++]=l>>>3&511,r[n++]=l>>>12&511,r[n++]=l>>>21&511,r[n++]=(l>>>30|(u&127)<<2)&511,r[n++]=u>>>7&511,r[n++]=u>>>16&511,r[n++]=(u>>>25|(c&3)<<7)&511,r[n++]=c>>>2&511,r[n++]=c>>>11&511,r[n++]=c>>>20&511,r[n++]=(c>>>29|(d&63)<<3)&511,r[n++]=d>>>6&511,r[n++]=d>>>15&511,r[n++]=(d>>>24|(h&1)<<8)&511,r[n++]=h>>>1&511,r[n++]=h>>>10&511,r[n++]=h>>>19&511,r[n++]=(h>>>28|(f&31)<<4)&511,r[n++]=f>>>5&511,r[n++]=f>>>14&511,r[n]=f>>>23&511}function a8e(e,t,r,i){let n=i,a=e[t]>>>0,s=e[t+1]>>>0,o=e[t+2]>>>0,l=e[t+3]>>>0,u=e[t+4]>>>0,c=e[t+5]>>>0,d=e[t+6]>>>0,h=e[t+7]>>>0,f=e[t+8]>>>0,p=e[t+9]>>>0;r[n++]=a>>>0&1023,r[n++]=a>>>10&1023,r[n++]=a>>>20&1023,r[n++]=(a>>>30|(s&255)<<2)&1023,r[n++]=s>>>8&1023,r[n++]=s>>>18&1023,r[n++]=(s>>>28|(o&63)<<4)&1023,r[n++]=o>>>6&1023,r[n++]=o>>>16&1023,r[n++]=(o>>>26|(l&15)<<6)&1023,r[n++]=l>>>4&1023,r[n++]=l>>>14&1023,r[n++]=(l>>>24|(u&3)<<8)&1023,r[n++]=u>>>2&1023,r[n++]=u>>>12&1023,r[n++]=u>>>22&1023,r[n++]=c>>>0&1023,r[n++]=c>>>10&1023,r[n++]=c>>>20&1023,r[n++]=(c>>>30|(d&255)<<2)&1023,r[n++]=d>>>8&1023,r[n++]=d>>>18&1023,r[n++]=(d>>>28|(h&63)<<4)&1023,r[n++]=h>>>6&1023,r[n++]=h>>>16&1023,r[n++]=(h>>>26|(f&15)<<6)&1023,r[n++]=f>>>4&1023,r[n++]=f>>>14&1023,r[n++]=(f>>>24|(p&3)<<8)&1023,r[n++]=p>>>2&1023,r[n++]=p>>>12&1023,r[n]=p>>>22&1023}function s8e(e,t,r,i){let n=i,a=e[t]>>>0,s=e[t+1]>>>0,o=e[t+2]>>>0,l=e[t+3]>>>0,u=e[t+4]>>>0,c=e[t+5]>>>0,d=e[t+6]>>>0,h=e[t+7]>>>0,f=e[t+8]>>>0,p=e[t+9]>>>0,m=e[t+10]>>>0;r[n++]=a>>>0&2047,r[n++]=a>>>11&2047,r[n++]=(a>>>22|(s&1)<<10)&2047,r[n++]=s>>>1&2047,r[n++]=s>>>12&2047,r[n++]=(s>>>23|(o&3)<<9)&2047,r[n++]=o>>>2&2047,r[n++]=o>>>13&2047,r[n++]=(o>>>24|(l&7)<<8)&2047,r[n++]=l>>>3&2047,r[n++]=l>>>14&2047,r[n++]=(l>>>25|(u&15)<<7)&2047,r[n++]=u>>>4&2047,r[n++]=u>>>15&2047,r[n++]=(u>>>26|(c&31)<<6)&2047,r[n++]=c>>>5&2047,r[n++]=c>>>16&2047,r[n++]=(c>>>27|(d&63)<<5)&2047,r[n++]=d>>>6&2047,r[n++]=d>>>17&2047,r[n++]=(d>>>28|(h&127)<<4)&2047,r[n++]=h>>>7&2047,r[n++]=h>>>18&2047,r[n++]=(h>>>29|(f&255)<<3)&2047,r[n++]=f>>>8&2047,r[n++]=f>>>19&2047,r[n++]=(f>>>30|(p&511)<<2)&2047,r[n++]=p>>>9&2047,r[n++]=p>>>20&2047,r[n++]=(p>>>31|(m&1023)<<1)&2047,r[n++]=m>>>10&2047,r[n]=m>>>21&2047}function o8e(e,t,r,i){let n=i,a=e[t]>>>0,s=e[t+1]>>>0,o=e[t+2]>>>0,l=e[t+3]>>>0,u=e[t+4]>>>0,c=e[t+5]>>>0,d=e[t+6]>>>0,h=e[t+7]>>>0,f=e[t+8]>>>0,p=e[t+9]>>>0,m=e[t+10]>>>0,g=e[t+11]>>>0;r[n++]=a>>>0&4095,r[n++]=a>>>12&4095,r[n++]=(a>>>24|(s&15)<<8)&4095,r[n++]=s>>>4&4095,r[n++]=s>>>16&4095,r[n++]=(s>>>28|(o&255)<<4)&4095,r[n++]=o>>>8&4095,r[n++]=o>>>20&4095,r[n++]=l>>>0&4095,r[n++]=l>>>12&4095,r[n++]=(l>>>24|(u&15)<<8)&4095,r[n++]=u>>>4&4095,r[n++]=u>>>16&4095,r[n++]=(u>>>28|(c&255)<<4)&4095,r[n++]=c>>>8&4095,r[n++]=c>>>20&4095,r[n++]=d>>>0&4095,r[n++]=d>>>12&4095,r[n++]=(d>>>24|(h&15)<<8)&4095,r[n++]=h>>>4&4095,r[n++]=h>>>16&4095,r[n++]=(h>>>28|(f&255)<<4)&4095,r[n++]=f>>>8&4095,r[n++]=f>>>20&4095,r[n++]=p>>>0&4095,r[n++]=p>>>12&4095,r[n++]=(p>>>24|(m&15)<<8)&4095,r[n++]=m>>>4&4095,r[n++]=m>>>16&4095,r[n++]=(m>>>28|(g&255)<<4)&4095,r[n++]=g>>>8&4095,r[n]=g>>>20&4095}function l8e(e,t,r,i){let n=i,a=e[t]>>>0,s=e[t+1]>>>0,o=e[t+2]>>>0,l=e[t+3]>>>0,u=e[t+4]>>>0,c=e[t+5]>>>0,d=e[t+6]>>>0,h=e[t+7]>>>0,f=e[t+8]>>>0,p=e[t+9]>>>0,m=e[t+10]>>>0,g=e[t+11]>>>0,v=e[t+12]>>>0,x=e[t+13]>>>0,_=e[t+14]>>>0,y=e[t+15]>>>0;r[n++]=a>>>0&65535,r[n++]=a>>>16&65535,r[n++]=s>>>0&65535,r[n++]=s>>>16&65535,r[n++]=o>>>0&65535,r[n++]=o>>>16&65535,r[n++]=l>>>0&65535,r[n++]=l>>>16&65535,r[n++]=u>>>0&65535,r[n++]=u>>>16&65535,r[n++]=c>>>0&65535,r[n++]=c>>>16&65535,r[n++]=d>>>0&65535,r[n++]=d>>>16&65535,r[n++]=h>>>0&65535,r[n++]=h>>>16&65535,r[n++]=f>>>0&65535,r[n++]=f>>>16&65535,r[n++]=p>>>0&65535,r[n++]=p>>>16&65535,r[n++]=m>>>0&65535,r[n++]=m>>>16&65535,r[n++]=g>>>0&65535,r[n++]=g>>>16&65535,r[n++]=v>>>0&65535,r[n++]=v>>>16&65535,r[n++]=x>>>0&65535,r[n++]=x>>>16&65535,r[n++]=_>>>0&65535,r[n++]=_>>>16&65535,r[n++]=y>>>0&65535,r[n]=y>>>16&65535}function u8e(e,t,r,i){let n=i,a=t;for(let s=0;s<8;s++){let o=e[a++]>>>0;r[n++]=o>>>0&1,r[n++]=o>>>1&1,r[n++]=o>>>2&1,r[n++]=o>>>3&1,r[n++]=o>>>4&1,r[n++]=o>>>5&1,r[n++]=o>>>6&1,r[n++]=o>>>7&1,r[n++]=o>>>8&1,r[n++]=o>>>9&1,r[n++]=o>>>10&1,r[n++]=o>>>11&1,r[n++]=o>>>12&1,r[n++]=o>>>13&1,r[n++]=o>>>14&1,r[n++]=o>>>15&1,r[n++]=o>>>16&1,r[n++]=o>>>17&1,r[n++]=o>>>18&1,r[n++]=o>>>19&1,r[n++]=o>>>20&1,r[n++]=o>>>21&1,r[n++]=o>>>22&1,r[n++]=o>>>23&1,r[n++]=o>>>24&1,r[n++]=o>>>25&1,r[n++]=o>>>
74126&1,r[n++]=o>>>27&1,r[n++]=o>>>28&1,r[n++]=o>>>29&1,r[n++]=o>>>30&1,r[n++]=o>>>31&1}}function c8e(e,t,r,i){let n=i,a=t;for(let s=0;s<8;s++){let o=e[a++]>>>0,l=e[a++]>>>0;r[n++]=o>>>0&3,r[n++]=o>>>2&3,r[n++]=o>>>4&3,r[n++]=o>>>6&3,r[n++]=o>>>8&3,r[n++]=o>>>10&3,r[n++]=o>>>12&3,r[n++]=o>>>14&3,r[n++]=o>>>16&3,r[n++]=o>>>18&3,r[n++]=o>>>20&3,r[n++]=o>>>22&3,r[n++]=o>>>24&3,r[n++]=o>>>26&3,r[n++]=o>>>28&3,r[n++]=o>>>30&3,r[n++]=l>>>0&3,r[n++]=l>>>2&3,r[n++]=l>>>4&3,r[n++]=l>>>6&3,r[n++]=l>>>8&3,r[n++]=l>>>10&3,r[n++]=l>>>12&3,r[n++]=l>>>14&3,r[n++]=l>>>16&3,r[n++]=l>>>18&3,r[n++]=l>>>20&3,r[n++]=l>>>22&3,r[n++]=l>>>24&3,r[n++]=l>>>26&3,r[n++]=l>>>28&3,r[n++]=l>>>30&3}}function d8e(e,t,r,i){let n=i,a=t;for(let s=0;s<8;s++){let o=e[a++]>>>0,l=e[a++]>>>0,u=e[a++]>>>0;r[n++]=o>>>0&7,r[n++]=o>>>3&7,r[n++]=o>>>6&7,r[n++]=o>>>9&7,r[n++]=o>>>12&7,r[n++]=o>>>15&7,r[n++]=o>>>18&7,r[n++]=o>>>21&7,r[n++]=o>>>24&7,r[n++]=o>>>27&7,r[n++]=(o>>>30|(l&1)<<2)&7,r[n++]=l>>>1&7,r[n++]=l>>>4&7,r[n++]=l>>>7&7,r[n++]=l>>>10&7,r[n++]=l>>>13&7,r[n++]=l>>>16&7,r[n++]=l>>>19&7,r[n++]=l>>>22&7,r[n++]=l>>>25&7,r[n++]=l>>>28&7,r[n++]=(l>>>31|(u&3)<<1)&7,r[n++]=u>>>2&7,r[n++]=u>>>5&7,r[n++]=u>>>8&7,r[n++]=u>>>11&7,r[n++]=u>>>14&7,r[n++]=u>>>17&7,r[n++]=u>>>20&7,r[n++]=u>>>23&7,r[n++]=u>>>26&7,r[n++]=u>>>29&7}}
741function h8e(e,t,r,i){let n=i,a=t;for(let s=0;s<8;s++){let o=e[a++]>>>0,l=e[a++]>>>0,u=e[a++]>>>0,c=e[a++]>>>0;r[n++]=o>>>0&15,r[n++]=o>>>4&15,r[n++]=o>>>8&15,r[n++]=o>>>12&15,r[n++]=o>>>16&15,r[n++]=o>>>20&15,r[n++]=o>>>24&15,r[n++]=o>>>28&15,r[n++]=l>>>0&15,r[n++]=l>>>4&15,r[n++]=l>>>8&15,r[n++]=l>>>12&15,r[n++]=l>>>16&15,r[n++]=l>>>20&15,r[n++]=l>>>24&15,r[n++]=l>>>28&15,r[n++]=u>>>0&15,r[n++]=u>>>4&15,r[n++]=u>>>8&15,r[n++]=u>>>12&15,r[n++]=u>>>16&15,r[n++]=u>>>20&15,r[n++]=u>>>24&15,r[n++]=u>>>28&15,r[n++]=c>>>0&15,r[n++]=c>>>4&15,r[n++]=c>>>8&15,r[n++]=c>>>12&15,r[n++]=c>>>16&15,r[n++]=c>>>20&15,r[n++]=c>>>24&15,r[n++]=c>>>28&15}}function f8e(e,t,r,i){let n=i,a=t;for(let s=0;s<8;s++){let o=e[a++]>>>0,l=e[a++]>>>0,u=e[a++]>>>0,c=e[a++]>>>0,d=e[a++]>>>0;r[n++]=o>>>0&31,r[n++]=o>>>5&31,r[n++]=o>>>10&31,r[n++]=o>>>15&31,r[n++]=o>>>20&31,r[n++]=o>>>25&31,r[n++]=(o>>>30|(l&7)<<2)&31,r[n++]=l>>>3&31,r[n++]=l>>>8&31,r[n++]=l>>>13&31,r[n++]=l>>>18&31,r[n++]=l>>>23&31,r[n++]=(l>>>28|(u&1)<<4)&31,r[n++]=u>>>1&31,r[n++]=u>>>6&31,r[n++]=u>>>11&31,r[n++]=u>>>16&31,r[n++]=u>>>21&31,r[n++]=u>>>26&31,r[n++]=(u>>>31|(c&15)<<1)&31,r[n++]=c>>>4&31,r[n++]=c>>>9&31,r[n++]=c>>>14&31,r[n++]=c>>>19&31,r[n++]=c>>>24&31,r[n++]=(c>>>29|(d&3)<<3)&31,r[n++]=d>>>2&31,r[n++]=d>>>7&31,r[n++]=d>>>12&31,r[n++]=d>>>17&31,r[n++]=d>>>22&31,r[n++]=d>>>27&31}}function p8e(e,t,r,i){let n=i,a=t;for(let s=0;s<8;s++){let o=e[a++]>>>0,l=e[a++]>>>0,u=e[a++]>>>0,c=e[a++]>>>0,d=e[a++]>>>0,h=e[a++]>>>0;r[n++]=o>>>0&63,r[n++]=o>>>6&63,r[n++]=o>>>12&63,r[n++]=o>>>18&63,r[n++]=o>>>24&63,r[n++]=(o>>>30|(l&15)<<2)&63,r[n++]=l>>>4&63,r[n++]=l>>>10&63,r[n++]=l>>>16&63,r[n++]=l>>>22&63,r[n++]=(l>>>28|(u&3)<<4)&63,r[n++]=u>>>2&63,r[n++]=u>>>8&63,r[n++]=u>>>14&63,r[n++]=u>>>20&63,r[n++]=u>>>26&63,r[n++]=c>>>0&63,r[n++]=c>>>6&63,r[n++]=c>>>12&63,r[n++]=c>>>18&63,r[n++]=c>>>24&63,r[n++]=(c>>>30|(d&15)<<2)&63,r[n++]=d>>>4&63,r[n++]=d>>>10&63,r[n++]=d>>>16&63,r[n++]=d>>>22&63,r[n++]=(d>>>28|(h&3)<<4)&63,r[n++]=h>>>2&63,r[n++]=h>>>8&63,r[n++]=h>>>14&63,r[n++]=h>>>20&63,r[n++]=h>>>26&63}}function m8e(e,t,r,i){let n=i,a=t;for(let s=0;s<8;s++){let o=e[a++]>>>0,l=e[a++]>>>0,u=e[a++]>>>0,c=e[a++]>>>0,d=e[a++]>>>0,h=e[a++]>>>0,f=e[a++]>>>0;r[n++]=o>>>0&127,r[n++]=o>>>7&127,r[n++]=o>>>14&127,r[n++]=o>>>21&127,r[n++]=(o>>>28|(l&7)<<4)&127,r[n++]=l>>>3&127,r[n++]=l>>>10&127,r[n++]=l>>>17&127,r[n++]=l>>>24&127,r[n++]=(l>>>31|(u&63)<<1)&127,r[n++]=u>>>6&127,r[n++]=u>>>
vendor: 16,975 bytes, line 741
74113&127,r[n++]=u>>>20&127,r[n++]=(u>>>27|(c&3)<<5)&127,r[n++]=c>>>2&127,r[n++]=c>>>9&127,r[n++]=c>>>16&127,r[n++]=c>>>23&127,r[n++]=(c>>>30|(d&31)<<2)&127,r[n++]=d>>>5&127,r[n++]=d>>>12&127,r[n++]=d>>>19&127,r[n++]=(d>>>26|(h&1)<<6)&127,r[n++]=h>>>1&127,r[n++]=h>>>8&127,r[n++]=h>>>15&127,r[n++]=h>>>22&127,r[n++]=(h>>>29|(f&15)<<3)&127,r[n++]=f>>>4&127,r[n++]=f>>>11&127,r[n++]=f>>>18&127,r[n++]=f>>>25&127}}function g8e(e,t,r,i){let n=i,a=t;for(let s=0;s<8;s++){let o=e[a++]>>>0,l=e[a++]>>>0,u=e[a++]>>>0,c=e[a++]>>>0,d=e[a++]>>>0,h=e[a++]>>>0,f=e[a++]>>>0,p=e[a++]>>>0;r[n++]=o>>>0&255,r[n++]=o>>>8&255,r[n++]=o>>>16&255,r[n++]=o>>>24&255,r[n++]=l>>>0&255,r[n++]=l>>>8&255,r[n++]=l>>>16&255,r[n++]=l>>>24&255,r[n++]=u>>>0&255,r[n++]=u>>>8&255,r[n++]=u>>>16&255,r[n++]=u>>>24&255,r[n++]=c>>>0&255,r[n++]=c>>>8&255,r[n++]=c>>>16&255,r[n++]=c>>>24&255,r[n++]=d>>>0&255,r[n++]=d>>>8&255,r[n++]=d>>>16&255,r[n++]=d>>>24&255,r[n++]=h>>>0&255,r[n++]=h>>>8&255,r[n++]=h>>>16&255,r[n++]=h>>>24&255,r[n++]=f>>>0&255,r[n++]=f>>>8&255,r[n++]=f>>>16&255,r[n++]=f>>>24&255,r[n++]=p>>>0&255,r[n++]=p>>>8&255,r[n++]=p>>>16&255,r[n++]=p>>>24&255}}function _8e(e,t,r,i){let n=i,a=t;for(let s=0;s<128;s++){let o=e[a++]>>>0;r[n++]=o&65535,r[n++]=o>>>16&65535}}function y8e(e,t,r,i,n){let a=qw[n]>>>0,s=t,o=0,l=e[s]>>>0,u=i;for(let c=0;c<8;c++){for(let d=0;d<32;d++)if(o+n<=32){let h=l>>>o&a;r[u+d]=h|0,o+=n,o===32&&(o=0,s++,d!==31&&(l=e[s]>>>0))}else{let h=32-o,f=l>>>o;s++,l=e[s]>>>0;let p=n-h,m=-1>>>32-p>>>0,g=(f|(l&m)<<h)&a;r[u+d]=g|0,o=p}u+=32,o=0,c<7&&(l=e[s]>>>0)}}const Gw=Zke(tF),v8e=3*Gw/256+Gw|0;function rF(){let e=new Uint8Array(v8e);return{dataToBePacked:Array(33),dataPointers:new Int32Array(33),byteContainer:e,byteContainerI32:new Int32Array(e.buffer,e.byteOffset,e.byteLength>>>2),exceptionSizes:new Int32Array(33)}}function b8e(e=16){if(e<0)throw RangeError(`initialEncodedWordCapacity must be >= 0, got ${e}`);let t=Math.max(16,e|0);return{encodedWords:new Uint32Array(t),decoderWorkspace:rF()}}function x8e(e,t){if(t<=e.encodedWords.length)return e.encodedWords;let r=new Uint32Array(Math.max(16,t*2));return e.encodedWords=r,r}function w8e(e,t,r,i){i.byteContainer.length<r&&(i.byteContainer=new Uint8Array(r*2),i.byteContainerI32=void 0);let n=i.byteContainer,a=r>>>2;if(n.byteOffset&3)for(let o=0;o<a;o=o+1|0){let l=e[t+o|0]|0,u=o<<2;n[u]=l&255,n[u+1|0]=l>>>8&255,n[u+2|0]=l>>>16&255,n[u+3|0]=l>>>24&255}else{let o=i.byteContainerI32;(!o||o.buffer!==n.buffer||o.byteOffset!==n.byteOffset||o.length<a)&&(o=i.byteContainerI32=new Int32Array(n.buffer,n.byteOffset,n.byteLength>>>2)),o.set(e.subarray(t,t+a))}let s=r&3;if(s>0){let o=e[t+a|0]|0,l=a<<2;for(let u=0;u<s;u=u+1|0)n[l+u|0]=o>>>(u<<3)&255}return n}function $8e(e,t,r){let i=e[t++]|0,n=r.dataToBePacked;for(let a=2;a<=32;a=a+1|0){if(!(i>>>a-1&1))continue;if(t>=e.length)throw Error(`FastPFOR decode: truncated exception stream header (bitWidth=${a}, streamWordIndex=${t}, needWords=1, availableWords=${e.length-t}, encodedWords=${e.length})`);let s=e[t++]>>>0,o=Wke(s),l=s*a+31>>>5;if(t+l>e.length)throw Error(`FastPFOR decode: truncated exception stream (bitWidth=${a}, size=${s}, streamWordIndex=${t}, needWords=${l}, availableWords=${e.length-t}, encodedWords=${e.length})`);let u=n[a];(!u||u.length<o)&&(u=n[a]=new Uint32Array(o));let c=0;for(;c<s;c=c+32|0)D8e(e,t,u,c,a),t=t+a|0;let d=c-s|0;t=t-(d*a>>>5)|0,r.exceptionSizes[a]=s}return t}function S8e(e,t,r,i,n){switch(n){case 1:u8e(e,t,r,i);break;case 2:c8e(e,t,r,i);break;case 3:d8e(e,t,r,i);break;case 4:h8e(e,t,r,i);break;case 5:f8e(e,t,r,i);break;case 6:p8e(e,t,r,i);break;case 7:m8e(e,t,r,i);break;case 8:g8e(e,t,r,i);break;case 16:_8e(e,t,r,i);break;default:y8e(e,t,r,i,n)}return t+(n<<3)|0}function T8e(e,t,r,i){if(r+2>t)throw Error(`FastPFOR decode: byteContainer underflow at block=${i} (need 2 bytes for [bitWidth, exceptionCount], bytePos=${r}, byteSize=${t})`);let n=e[r++],a=e[r++];if(n>32)throw Error(`FastPFOR decode: invalid bitWidth=${n} at block=${i} (expected 0..32). This likely indicates corrupted or truncated input.`);return{bitWidth:n,exceptionCount:a,bytePosIn:r}}function C8e(e,t,r,i,n,a){if(r+1>t)throw Error(`FastPFOR decode: exception header underflow at block=${a} (need 1 byte for maxBits, bytePos=${r}, byteSize=${t})`);let s=e[r++];if(s<i||s>32)throw Error(`FastPFOR decode: invalid maxBits=${s} at block=${a} (bitWidth=${i}, expected ${i}..32)`);let o=s-i|0;if(o<1||o>32)throw Error(`FastPFOR decode: invalid exceptionBitWidth=${o} at block=${a} (bitWidth=${i}, maxBits=${s})`);if(r+n>t)throw Error(`FastPFOR decode: exception positions underflow at block=${a} (need=${n}, have=${t-r})`);return{maxBits:s,exceptionBitWidth:o,bytePosIn:r}}function k8e(e,t,r,i,n,a,s,o,l){let{maxBits:u,exceptionBitWidth:c,bytePosIn:d}=C8e(n,a,s,r,i,l);if(s=d,c===1){let g=1<<r;for(let v=0;v<i;v=v+1|0){let x=n[s++];e[x+t|0]|=g}return s}let h=o.dataToBePacked[c];if(!h)throw Error(`FastPFOR decode: missing exception stream for exceptionBitWidth=${c} (bitWidth=${r}, maxBits=${u}) at block ${l}`);let f=o.dataPointers,p=f[c]|0,m=o.exceptionSizes[c]|0;if(p+i>m)throw Error(`FastPFOR decode: exception stream overflow for exceptionBitWidth=${c} (ptr=${p}, need ${i}, size=${m}) at block ${l}`);for(let g=0;g<i;g=g+1|0){let v=n[s++],x=h[p++]|0;e[v+t|0]|=x<<r}return f[c]=p,s}function E8e(e,t,r,i,n,a,s,o,l,u){let c=r|0,d=0;for(let h=0;h<s;h=h+1|0){let f=T8e(o,l,d,h);d=f.bytePosIn;let p=f.bitWidth,m=f.exceptionCount,g=a+h*256|0;switch(p){case 0:n.fill(0,g,g+256);break;case 32:for(let v=0;v<256;v=v+1|0)n[g+v|0]=e[c+v|0]|0;c=c+256|0;break;default:c=S8e(e,c,n,g,p)}m>0&&(d=k8e(n,g,p,m,o,l,d,u,h))}if(c!==i)throw Error(`FastPFOR decode: packed region mismatch (pageStart=${t}, packedStart=${r}, consumedPackedEnd=${c}, expectedPackedEnd=${i}, packedWords=${i-r}, encoded.length=${e.length})`)}function P8e(e,t,r,i,n,a){let s=r|0,o=e[s]|0;if(o<=0||s+o>e.length-1)throw Error(`FastPFOR decode: invalid whereMeta=${o} at pageStart=${s} (expected > 0 and pageStart+whereMeta < encoded.length=${e.length})`);let l=s+1|0,u=s+o|0,c=e[u]>>>0,d=c+3>>>2,h=u+1,f=h+d;if(f>=e.length)throw Error(`FastPFOR decode: invalid byteSize=${c} (metaInts=${d}, pageStart=${s}, packedEnd=${u}, byteContainerStart=${h}) causes bitmapPos=${f} out of bounds (encoded.length=${e.length})`);let p=w8e(e,h,c,a),m=c,g=$8e(e,f,a);return a.dataPointers.fill(0),E8e(e,s,l,u,t,i|0,n/256|0,p,m,a),g}function M8e(e,t,r,i,n,a){let s=i+yS(n,256),o=i,l=r;for(;o!==s;){let u=Math.min(Gw,s-o);l=P8e(e,t,l,o,u,a),o=o+u|0}return l}function I8e(e,t,r,i,n,a){if(a===0)return t;let s=0,o=t,l=t+r,u=n,c=n,d=n+a,h=0,f=0;for(;o<l&&c<d;){let p=e[o]>>>s&255;if(s+=8,o+=s>>>5,s&=31,h|=(p&127)<<f,p&128)i[c++]=h|0,h=0,f=0;else if(f+=7,f>28)throw Error(`FastPFOR VByte: unterminated value (expected MSB=1 terminator within 5 bytes; shift=${f}, partial=${h}, decoded=${c-u}/${a}, inPos=${o}, inEnd=${l})`)}if(c!==d)throw Error(`FastPFOR VByte: truncated stream (decoded=${c-u}, expected=${a}, consumedWords=${o-t}/${r}, vbyteStart=${t}, vbyteEnd=${l})`);return o}function A8e(e,t,r){let i=0,n=0,a=new Uint32Array(t),s=r??rF();if(e.length>0){let u=e[i]|0;if(i=i+1|0,u&255)throw Error(`FastPFOR decode: invalid alignedLength=${u} (expected multiple of 256)`);if(n+u>a.length)throw Error(`FastPFOR decode: output buffer too small (outPos=${n}, alignedLength=${u}, out.length=${a.length})`);i=M8e(e,a,i,n,u,s),n=n+u|0}let o=e.length-i|0,l=t-n|0;return I8e(e,i,o,a,n,l),a}function D8e(e,t,r,i,n){switch(n){case 2:Xke(e,t,r,i);return;case 3:Jke(e,t,r,i);return;case 4:Qke(e,t,r,i);return;case 5:e8e(e,t,r,i);return;case 6:t8e(e,t,r,i);return;case 7:r8e(e,t,r,i);return;case 8:i8e(e,t,r,i);return;case 9:n8e(e,t,r,i);return;case 10:a8e(e,t,r,i);return;case 11:s8e(e,t,r,i);return;case 12:o8e(e,t,r,i);return;case 16:l8e(e,t,r,i);return;case 32:for(let u=0;u<32;u=u+1|0)r[i+u|0]=e[t+u|0]|0;return}let a=qw[n]>>>0,s=t,o=0,l=e[s]>>>0;for(let u=0;u<32;u++)if(o+n<=32){let c=l>>>o&a;r[i+u]=c|0,o+=n,o===32&&(o=0,s++,u!==31&&(l=e[s]>>>0))}else{let c=32-o,d=l>>>o;s++,l=e[s]>>>0;let h=qw[n-c]>>>0,f=(d|(l&h)<<c)&a;r[i+u]=f|0,o=n-c}}function R8e(e,t,r,i){if(t<0||r<0||t+r>e.length)throw RangeError(`decodeBigEndianInt32sInto: out of bounds (offset=${t}, byteLength=${r}, bytes.length=${e.length})`);let n=Math.floor(r/4),a=r%4!=0,s=a?n+1:n;if(i.length<s)throw RangeError(`decodeBigEndianInt32sInto: out.length=${i.length} < ${s}`);if(n>0){let o=e.byteOffset+t;if(o&3)for(let l=0;l<n;l++){let u=t+l*4;i[l]=e[u]<<24|e[u+1]<<16|e[u+2]<<8|e[u+3]|0}else{let l=new Uint32Array(e.buffer,o,n);for(let u=0;u<n;u++)i[u]=Kke(l[u])|0}}if(a){let o=t+n*4,l=r-n*4,u=0;for(let c=0;c<l;c++)u|=e[o+c]<<24-c*8;i[n]=u|0}return s}function Vi(e,t,r){let i=new Uint32Array(r),n=0,a=t.get();for(let s=0;s<i.length;s++){let o=e[a++],l=o&127;if(o<128){i[n++]=l;continue}if(o=e[a++],l|=(o&127)<<7,o<128){i[n++]=l;continue}if(o=e[a++],l|=(o&127)<<14,o<128){i[n++]=l;continue}if(o=e[a++],l|=(o&127)<<21,o<128){i[n++]=l;continue}o=e[a++],l|=(o&15)<<28,i[n++]=l}return t.set(a),i}function tf(e,t,r){let i=new BigUint64Array(r);for(let n=0;n<i.length;n++)i[n]=O8e(e,t);return i}function O8e(e,t){let r=0n,i=0,n=t.get();for(;n<e.length;){let a=e[n++];if(r|=BigInt(a&127)<<BigInt(i),!(a&128))break;if(i+=7,i>=64)throw Error("Varint too long")}return t.set(n),r}function L8e(e,t,r){let i=new Float64Array(r);for(let n=0;n<r;n++)i[n]=F8e(e,t);return i}function F8e(e,t){let r,i;return i=e[t.get()],t.increment(),r=i&127,i<128||(i=e[t.get()],t.increment(),r|=(i&127)<<7,i<128)||(i=e[t.get()],t.increment(),r|=(i&127)<<14,i<128)||(i=e[t.get()],t.increment(),r|=(i&127)<<21,i<128)?r:(i=e[t.get()],r|=(i&15)<<28,z8e(r,e,t))}function z8e(e,t,r){let i,n;if(n=t[r.get()],r.increment(),i=(n&112)>>4,n<128||(n=t[r.get()],r.increment(),i|=(n&127)<<3,n<128)||(n=t[r.get()],r.increment(),i|=(n&127)<<10,n<128)||(n=t[r.get()],r.increment(),i|=(n&127)<<17,n<128)||(n=t[r.get()],r.increment(),i|=(n&127)<<24,n<128)||(n=t[r.get()],r.increment(),i|=(n&1)<<31,n<128))return i*4294967296+(e>>>0);throw Error("Expected varint not more than 10 bytes")}function N8e(e,t,r,i){return B8e(e,t,r,i,b8e(r>>>2))}function B8e(e,t,r,i,n){let a=i.get();if(r&3)throw Error(`FastPFOR: invalid encodedByteLength=${r} at offset=${a} (encodedBytes.length=${e.length}; expected a multiple of 4 bytes for an int32 big-endian word stream)`);let s=r>>>2,o=x8e(n,s);R8e(e,a,r,o);let l=A8e(o.subarray(0,s),t,n.decoderWorkspace);return i.add(r),l}function Gt(e){return e>>>1^-(e&1)}function zi(e){return e>>1n^-(e&1n)}function Du(e){return e%2==1?(e+1)/-2:e/2}function j8e(e){let t=new Int32Array(e.length);for(let r=0;r<e.length;r++)t[r]=Gt(e[r]);return t}function U8e(e){let t=new BigInt64Array(e.length);for(let r=0;r<e.length;r++)t[r]=zi(e[r]);return t}function Hw(e,t,r){if(r===void 0){r=0;for(let a=0;a<t;a++)r+=e[a]}let i=new Uint32Array(r),n=0;for(let a=0;a<t;a++){let s=e[a],o=e[a+t];i.fill(o,n,n+s),n+=s}return i}function Yw(e,t,r){if(r===void 0){r=0;for(let a=0;a<t;a++)r+=Number(e[a])}let i=new BigUint64Array(r),n=0;for(let a=0;a<t;a++){let s=Number(e[a]),o=e[a+t];i.fill(o,n,n+s),n+=s}return i}function iF(e,t,r){let i=new Float64Array(r),n=0;for(let a=0;a<t;a++){let s=e[a],o=e[a+t];i.fill(o,n,n+s),n+=s}return i}function O8(e){let t=new Int32Array(e.length);t[0]=Gt(e[0]);let r=e.length/4*4,i=1;if(r>=4)for(;i<r-4;i+=4){let n=e[i],a=e[i+1],s=e[i+2],o=e[i+3];t[i]=Gt(n)+t[i-1],t[i+1]=Gt(a)+t[i],t[i+2]=Gt(s)+t[i+1],t[i+3]=Gt(o)+t[i+2]}for(;i!==e.length;++i)t[i]=Gt(e[i])+t[i-1];return t}function L8(e){let t=new BigInt64Array(e.length);t[0]=zi(e[0]);let r=e.length/4*4,i=1;if(r>=4)for(;i<r-4;i+=4){let n=e[i],a=e[i+1],s=e[i+2],o=e[i+3];t[i]=zi(n)+t[i-1],t[i+1]=zi(a)+t[i],t[i+2]=zi(s)+t[i+1],t[i+3]=zi(o)+t[i+2]}for(;i!==t.length;++i)t[i]=zi(e[i])+t[i-1];return t}function V8e(e){e[0]=Du(e[0]);let t=e.length/4*4,r=1;if(t>=4)for(;r<t-4;r+=4){let i=e[r],n=e[r+1],a=e[r+2],s=e[r+3];e[r]=Du(i)+e[r-1],e[r+1]=Du(n)+e[r],e[r+2]=Du(a)+e[r+1],e[r+3]=Du(s)+e[r+2]}for(;r!==e.length;++r)e[r]=Du(e[r])+e[r-1]}function q8e(e,t,r){if(r===void 0){r=0;for(let a=0;a<t;a++)r+=e[a]}let i=new Int32Array(r),n=0;for(let a=0;a<t;a++){let s=e[a],o=e[a+t];o=Gt(o),i.fill(o,n,n+s),n+=s}return i}function G8e(e,t,r){if(r===void 0){r=0;for(let a=0;a<t;a++)r+=Number(e[a])}let i=new BigInt64Array(r),n=0;for(let a=0;a<t;a++){let s=Number(e[a]),o=e[a+t];o=zi(o),i.fill(o,n,n+s),n+=s}return i}function H8e(e,t,r){let i=new Float64Array(r),n=0;for(let a=0;a<t;a++){let s=e[a],o=e[a+t];o=Du(o),i.fill(o,n,n+s),n+=s}return i}function vS(e){let t=e.length/4*4,r=1;if(t>=4)for(let i=e[0];r<t-4;r+=4)i=e[r]+=i,i=e[r+1]+=i,i=e[r+2]+=i,i=e[r+3]+=i;for(;r!==e.length;)e[r]+=e[r-1],++r}function Y8e(e){let t=0;for(let r=0;r<e.length;r++)e[r]+=t,t=e[r]}function W8e(e){if(e.length<2)return new Int32Array(e);let t=new Int32Array(e.length);t[0]=Gt(e[0]),t[1]=Gt(e[1]);let r=e.length/4*4,i=2;if(r>=4)for(;i<r-4;i+=4){let n=e[i],a=e[i+1],s=e[i+2],o=e[i+3];t[i]=Gt(n)+t[i-2],t[i+1]=Gt(a)+t[i-1],t[i+2]=Gt(s)+t[i],t[i+3]=Gt(o)+t[i+1]}for(;i!==e.length;i+=2)t[i]=Gt(e[i])+t[i-2],t[i+1]=Gt(e[i+1])+t[i-1];return t}function Z8e(e){let t=new Int32Array(e.length+1);t[0]=0,t[1]=Gt(e[0]);let r=t[1];for(let i=2;i!==t.length;++i){let n=e[i-1],a=Gt(n);r+=a,t[i]=t[i-1]+r}return new Uint32Array(t)}function K8e(e,t,r){let i=new Int32Array(r+1);i[0]=0;let n=1,a=i[0];for(let s=0;s<t;s++){let o=e[s],l=e[s+t];l=Gt(l);for(let u=n;u<n+o;u++)i[u]=l+a,a=i[u];n+=o}return i}function X8e(e,t,r){let i=new Uint32Array(r+1);i[0]=0;let n=1,a=i[0];for(let s=0;s<t;s++){let o=e[s],l=e[s+t];for(let u=n;u<n+o;u++)i[u]=l+a,a=i[u];n+=o}return i}function J8e(e,t,r){let i=new Int32Array(r),n=0,a=0;for(let s=0;s<t;s++){let o=e[s],l=e[s+t],u=Gt(l);for(let c=0;c<o;c++)a+=u,i[n++]=a}return i}function Q8e(e,t,r){let i=new BigInt64Array(r),n=0,a=0n;for(let s=0;s<t;s++){let o=Number(e[s]),l=e[s+t],u=zi(l);for(let c=0;c<o;c++)a+=u,i[n++]=a}return i}function F8(e){let t=new Uint32Array(e.length);t[0]=Gt(e[0])>>>0;for(let r=1;r<e.length;r++)t[r]=t[r-1]+Gt(e[r])>>>0;return t}function z8(e){let t=new BigUint64Array(e.length);t[0]=BigInt.asUintN(64,zi(e[0]));for(let r=1;r<e.length;r++)t[r]=BigInt.asUintN(64,t[r-1]+zi(e[r]));return t}function eEe(e){if(e.length<2)return new Uint32Array(e);let t=new Uint32Array(e.length);t[0]=Gt(e[0])>>>0,t[1]=Gt(e[1])>>>0;for(let r=2;r<e.length;r+=2)t[r]=t[r-2]+Gt(e[r])>>>0,t[r+1]=t[r-1]+Gt(e[r+1])>>>0;return t}function tEe(e){return e[1]}function rEe(e){return Gt(e[1])}function iEe(e){if(e.length===2){let t=Gt(e[1]);return[t,t]}return[Gt(e[2]),Gt(e[3])]}function nEe(e){return e[1]}function aEe(e){return zi(e[1])}function sEe(e){if(e.length===2){let t=zi(e[1]);return[t,t]}return[zi(e[2]),zi(e[3])]}var li;(function(e){e.PRESENT="PRESENT",e.DATA="DATA",e.OFFSET="OFFSET",e.LENGTH="LENGTH"})(li||(li={}));var kn;(function(e){e.NONE="NONE",e.SINGLE="SINGLE",e.SHARED="SHARED",e.VERTEX="VERTEX",e.MORTON="MORTON",e.FSST="FSST"})(kn||(kn={}));var No;(function(e){e.VERTEX="VERTEX",e.INDEX="INDEX",e.STRING="STRING",e.KEY="KEY"})(No||(No={}));var gi;(function(e){e.VAR_BINARY="VAR_BINARY",e.GEOMETRIES="GEOMETRIES",e.PARTS="PARTS",e.RINGS="RINGS",e.TRIANGLES="TRIANGLES",e.SYMBOL="SYMBOL",e.DICTIONARY="DICTIONARY"})(gi||(gi={}));const oEe=[li.PRESENT,li.DATA,li.OFFSET,li.LENGTH],N8=[dt.NONE,dt.DELTA,dt.COMPONENTWISE_DELTA,dt.RLE,dt.MORTON,dt.PDE],lEe=[Wo.NONE,Wo.FAST_PFOR,Wo.VARINT],uEe=[kn.NONE,kn.SINGLE,kn.SHARED,kn.VERTEX,kn.MORTON,kn.FSST],cEe=[No.VERTEX,No.INDEX,No.STRING,No.KEY],dEe=[gi.VAR_BINARY,gi.GEOMETRIES,gi.PARTS,gi.RINGS,gi.TRIANGLES,gi.SYMBOL,gi.DICTIONARY];function fn(e,t){let r=pEe(e,t);return r.logicalLevelTechnique1===dt.MORTON?hEe(r,e,t):(dt.RLE===r.logicalLevelTechnique1||dt.RLE===r.logicalLevelTechnique2)&&Wo.NONE!==r.physicalLevelTechnique?fEe(r,e,t):r}function hEe(e,t,r){let i=Vi(t,r,2);return{physicalStreamType:e.physicalStreamType,logicalStreamType:e.logicalStreamType,logicalLevelTechnique1:e.logicalLevelTechnique1,logicalLevelTechnique2:e.logicalLevelTechnique2,physicalLevelTechnique:e.physicalLevelTechnique,numValues:e.numValues,byteLength:e.byteLength,decompressedCount:e.decompressedCount,numBits:i[0],coordinateShift:i[1]}}function fEe(e,t,r){let i=Vi(t,r,2);return{physicalStreamType:e.physicalStreamType,logicalStreamType:e.logicalStreamType,logicalLevelTechnique1:e.logicalLevelTechnique1,logicalLevelTechnique2:e.logicalLevelTechnique2,physicalLevelTechnique:e.physicalLevelTechnique,numValues:e.numValues,byteLength:e.byteLength,decompressedCount:i[1],runs:i[0],numRleValues:i[1]}}function pEe(e,t){let r=e[t.get()],i=oEe[r>>4],n={};switch(i){case li.DATA:n={dictionaryType:uEe[r&15]};break;case li.OFFSET:n={offsetType:cEe[r&15]};break;case li.LENGTH:n={lengthType:dEe[r&15]}}t.increment();let a=e[t.get()],s=N8[a>>5],o=N8[a>>2&7],l=lEe[a&3];t.increment();let u=Vi(e,t,2),c=u[0],d=u[1];return{physicalStreamType:i,logicalStreamType:n,logicalLevelTechnique1:s,logicalLevelTechnique2:o,physicalLevelTechnique:l,numValues:c,byteLength:d,decompressedCount:c}}var gr;
vendor: 4,148 bytes, line 741
741(function(e){e[e.FLAT=0]="FLAT",e[e.CONST=1]="CONST",e[e.SEQUENCE=2]="SEQUENCE",e[e.DICTIONARY=3]="DICTIONARY",e[e.FSST_DICTIONARY=4]="FSST_DICTIONARY"})(gr||(gr={}));var fl=class{constructor(e,t){this.values=e,this._size=t}get(e){let t=Math.floor(e/8),r=e%8;return(this.values[t]>>r&1)==1}set(e,t){let r=Math.floor(e/8),i=e%8;this.values[r]=this.values[r]|+!!t<<i}getInt(e){let t=Math.floor(e/8),r=e%8;return this.values[t]>>r&1}size(){return this._size}getBuffer(){return this.values}};function rf(e,t,r){if(!t)return e;let i=t.size(),n=e.constructor,a=new n(i),s=0;for(let o=0;o<i;o++)a[o]=t.get(o)?e[s++]:r;return a}function mEe(e,t,r){if(!r)return e;let i=r.size(),n=new fl(e,t),a=new fl(new Uint8Array(Math.ceil(i/8)),i),s=0;for(let o=0;o<i;o++){let l=r.get(o)?n.get(s++):!1;a.set(o,l)}return a.getBuffer()}function Ww(e,t,r,i,n){return bEe(nf(e,t,r),r,i,n)}function Fn(e,t,r,i,n){return xEe(nf(e,t,r),r,i,n)}function Fl(e,t,r){return TEe(nf(e,t,r),r)}function nf(e,t,r){let i=r.physicalLevelTechnique;switch(i){case Wo.FAST_PFOR:return N8e(e,r.numValues,r.byteLength,t);case Wo.VARINT:return Vi(e,t,r.numValues);case Wo.NONE:{let n=t.get(),a=r.byteLength;t.add(a);let s=e.subarray(n,t.get());return new Uint32Array(s)}default:throw Error(`Specified physicalLevelTechnique ${i} is not supported (yet).`)}}function gEe(e,t,r){let i=nf(e,t,r);return i.length===1?Gt(i[0]):rEe(i)}function bS(e,t,r){let i=nf(e,t,r);return i.length===1?r.logicalLevelTechnique1===dt.DELTA?Gt(i[0]):i[0]:tEe(i)}function nF(e,t,r){return iEe(nf(e,t,r))}function aF(e,t,r){return sEe(tf(e,t,r.numValues))}function _Ee(e,t,r,i){return wEe(tf(e,t,r.numValues),r,i)}function sF(e,t,r,i){return $Ee(tf(e,t,r.numValues),r,i)}function yEe(e,t,r){return SEe(L8e(e,t,r.numValues),r,!1)}function vEe(e,t,r){let i=tf(e,t,r.numValues);return i.length===1?zi(i[0]):aEe(i)}function oF(e,t,r){let i=tf(e,t,r.numValues);return i.length===1?r.logicalLevelTechnique1===dt.DELTA?zi(i[0]):i[0]:nEe(i)}function bEe(e,t,r,i){let n;switch(t.logicalLevelTechnique1){case dt.DELTA:if(t.logicalLevelTechnique2===dt.RLE){let a=t;if(!i)return J8e(e,a.runs,a.numRleValues);e=Hw(e,a.runs,a.numRleValues),n=O8(e)}else n=O8(e);break;case dt.RLE:n=q8e(e,t.runs,t.numRleValues);break;case dt.MORTON:vS(e),n=new Int32Array(e);break;case dt.COMPONENTWISE_DELTA:n=W8e(e);break;case dt.NONE:n=j8e(e);break;default:throw Error(`The specified Logical level technique is not supported: ${t.logicalLevelTechnique1}`)}return i?rf(n,i,0):n}function xEe(e,t,r,i){let n;switch(t.logicalLevelTechnique1){case dt.DELTA:if(t.logicalLevelTechnique2===dt.RLE){let a=t;n=F8(Hw(e,a.runs,a.numRleValues))}else n=F8(e);break;case dt.RLE:n=Hw(e,t.runs,t.numRleValues);break;case dt.MORTON:vS(e),n=e;break;case dt.COMPONENTWISE_DELTA:n=eEe(e);break;case dt.NONE:n=e;break;default:throw Error(`The specified Logical level technique is not supported: ${t.logicalLevelTechnique1}`)}return i?rf(n,i,0):n}function wEe(e,t,r){let i;switch(t.logicalLevelTechnique1){case dt.DELTA:if(t.logicalLevelTechnique2===dt.RLE){let n=t;if(!r)return Q8e(e,n.runs,n.numRleValues);e=Yw(e,n.runs,n.numRleValues),i=L8(e)}else i=L8(e);break;case dt.RLE:i=G8e(e,t.runs,t.numRleValues);break;case dt.NONE:i=U8e(e);break;default:throw Error(`The specified Logical level technique is not supported: ${t.logicalLevelTechnique1}`)}return r?rf(i,r,0n):i}function $Ee(e,t,r){let i;switch(t.logicalLevelTechnique1){case dt.DELTA:if(t.logicalLevelTechnique2===dt.RLE){let n=t;i=z8(Yw(e,n.runs,n.numRleValues))}else i=z8(e);break;case dt.RLE:i=Yw(e,t.runs,t.numRleValues);break;case dt.NONE:i=e;break;default:throw Error(`The specified Logical level technique is not supported: ${t.logicalLevelTechnique1}`)}return r?rf(i,r,0n):i}function SEe(e,t,r){switch(t.logicalLevelTechnique1){case dt.DELTA:if(t.logicalLevelTechnique2===dt.RLE){let i=t;e=iF(e,i.runs,i.numRleValues)}return V8e(e),e;case dt.RLE:return kEe(e,t,r);case dt.NONE:return e;default:throw Error(`The specified Logical level technique is not supported: ${t.logicalLevelTechnique1}`)}}function TEe(e,t){if(t.logicalLevelTechnique1===dt.DELTA&&t.logicalLevelTechnique2===dt.NONE)return Z8e(e);
vendor: 6,008 bytes, line 741
741if(t.logicalLevelTechnique1===dt.RLE&&t.logicalLevelTechnique2===dt.NONE){let r=t;return X8e(e,r.runs,r.numRleValues)}if(t.logicalLevelTechnique1===dt.NONE&&t.logicalLevelTechnique2===dt.NONE){Y8e(e);let r=new Uint32Array(t.numValues+1);return r[0]=0,r.set(e,1),r}if(t.logicalLevelTechnique1===dt.DELTA&&t.logicalLevelTechnique2===dt.RLE){let r=t,i=K8e(e,r.runs,r.numRleValues);return vS(i),new Uint32Array(i)}throw Error("Only delta encoding is supported for transforming length to offset streams yet.")}function gv(e,t,r,i,n="int32"){let a=e.logicalLevelTechnique1;if(a===dt.RLE)return e.runs===1?gr.CONST:gr.FLAT;if(a!==dt.DELTA||e.logicalLevelTechnique2!==dt.RLE)return e.numValues===1?gr.CONST:gr.FLAT;let s=t instanceof fl?t.size():t,o=e;if(o.numRleValues!==s)return gr.FLAT;if(o.runs===1)return gr.SEQUENCE;if(o.runs!==2)return e.numValues===1?gr.CONST:gr.FLAT;let l=i.get();if(e.physicalLevelTechnique===Wo.VARINT)return CEe(r,i,n)?gr.SEQUENCE:e.numValues===1?gr.CONST:gr.FLAT;let u=i.get(),c=new Int32Array(r.buffer,r.byteOffset+u,4);return i.set(l),c[2]===2&&c[3]===2?gr.SEQUENCE:e.numValues===1?gr.CONST:gr.FLAT}function CEe(e,t,r){let i=new eF(t.get());if(r==="int64"){let a=tf(e,i,4);return a[2]===2n&&a[3]===2n}let n=Vi(e,i,4);return n[2]===2&&n[3]===2}function kEe(e,t,r){return r?H8e(e,t.runs,t.numRleValues):iF(e,t.runs,t.numRleValues)}var lF=class extends mv{getValueFromBuffer(e){return this.dataBuffer[e]}},uF=class extends QL{constructor(e,t,r,i){super(e,BigInt64Array.of(t),r,i)}getValueFromBuffer(e){return this.dataBuffer[0]+BigInt(e)*this.delta}};function xS(e,t,r){return{x:B8(e,t)-r,y:B8(e>>1,t)-r}}function B8(e,t){let r=0;for(let i=0;i<t;i++)r|=(e&1<<2*i)>>i;return r}var vi;(function(e){e[e.POINT=0]="POINT",e[e.LINESTRING=1]="LINESTRING",e[e.POLYGON=2]="POLYGON",e[e.MULTIPOINT=3]="MULTIPOINT",e[e.MULTILINESTRING=4]="MULTILINESTRING",e[e.MULTIPOLYGON=5]="MULTIPOLYGON"})(vi||(vi={}));var EEe;(function(e){e[e.POINT=0]="POINT",e[e.LINESTRING=1]="LINESTRING",e[e.POLYGON=2]="POLYGON"})(EEe||(EEe={}));var jc;(function(e){e[e.MORTON=0]="MORTON",e[e.VEC_2=1]="VEC_2",e[e.VEC_3=2]="VEC_3"})(jc||(jc={}));function PEe(e){let t=Array(e.numGeometries),r=1,i=1,n=1,a=0,s=0,o=0,l=e.mortonSettings,u=e.topologyVector,c=u.geometryOffsets,d=u.partOffsets,h=u.ringOffsets,f=e.vertexOffsets,p=!f||f.length===0,m=e.containsPolygonGeometry(),g=e.vertexBuffer;for(let v=0;v<e.numGeometries;v++){let x=e.geometryType(v);switch(x){case vi.POINT:{let _,y;if(p)_=g[s++],y=g[s++];else if(e.vertexBufferType===jc.MORTON){let w=g[f[o++]],$=xS(w,l.numBits,l.coordinateShift);_=$.x,y=$.y}else{let w=f[o++]*2;_=g[w],y=g[w+1]}t[a++]=[[new de(_,y)]],c&&n++,d&&r++,h&&i++}break;case vi.MULTIPOINT:{let _=c[n]-c[n-1];n++;let y=Array(_);if(p)for(let w=0;w<_;w++){let $=g[s++],S=g[s++];y[w]=new de($,S)}else for(let w=0;w<_;w++){let $=f[o++]*2,S=g[$],E=g[$+1];y[w]=new de(S,E)}t[a++]=y.map(w=>[w]),r+=_,i+=_}break;case vi.LINESTRING:{let _;m?(_=h[i]-h[i-1],i++):_=d[r]-d[r-1],r++;let y;p?(y=ed(g,s,_,!1),s+=_*2):(y=Qc(e.vertexBufferType,g,f,o,_,!1,l),o+=_),t[a++]=[y],c&&n++}break;case vi.POLYGON:{let _=d[r]-d[r-1];r++;let y=Array(_-1),w,$=h[i]-h[i-1];if(i++,p){w=ed(g,s,$,!0),s+=$*2;for(let S=0;S<y.length;S++)$=h[i]-h[i-1],i++,y[S]=ed(g,s,$,!0),s+=$*2}else{w=Qc(e.vertexBufferType,g,f,o,$,!0,l),o+=$;for(let S=0;S<y.length;S++)$=h[i]-h[i-1],i++,y[S]=Qc(e.vertexBufferType,g,f,o,$,!0,l),o+=$}t[a++]=[w].concat(y),c&&n++}break;case vi.MULTILINESTRING:{let _=c[n]-c[n-1];n++;let y=Array(_);for(let w=0;w<_;w++){let $;if(m?($=h[i]-h[i-1],i++):$=d[r]-d[r-1],r++,p)y[w]=ed(g,s,$,!1),s+=$*2;else{let S=Qc(e.vertexBufferType,g,f,o,$,!1,l);y[w]=S,o+=$}}t[a++]=y}break;case vi.MULTIPOLYGON:{let _=c[n]-c[n-1];n++;let y=Array(_);for(let w=0;w<_;w++){let $=d[r]-d[r-1];r++;let S,E=Array($-1),C=h[i]-h[i-1];i++,p?(S=ed(g,s,C,!0),s+=C*2):(S=Qc(e.vertexBufferType,g,f,o,C,!0,l),o+=C);for(let I=0;I<E.length;I++){let P=h[i]-h[i-1];i++,p?(E[I]=ed(g,s,P,!0),s+=P*2):(E[I]=Qc(e.vertexBufferType,g,f,o,P,!0,l),o+=P)}y[w]=[S].concat(E)}t[a++]=y.flat()}break;default:throw Error(`The specified geometry type (${x}) is currently not supported.`)}}return t}function Qc(e,t,r,i,n,a,s){return e===jc.MORTON?IEe(t,r,i,n,a,s):MEe(t,r,i,n,a)}function ed(e,t,r,i){let n=Array(i?r+1:r);for(let a=0;a<r*2;a+=2){let s=e[t+a],o=e[t+a+1];n[a/2]=new de(s,o)}return i&&(n[n.length-1]=n[0]),n}function MEe(e,t,r,i,n){let a=Array(n?i+1:i);for(let s=0;s<i*2;s+=2){let o=t[r+s/2]*2,l=e[o],u=e[o+1];a[s/2]=new de(l,u)}return n&&(a[a.length-1]=a[0]),a}function IEe(e,t,r,i,n,a){let s=Array(n?i+1:i);for(let o=0;o<i;o++){let l=e[t[r+o]],u=xS(l,a.numBits,a.coordinateShift);s[o]=new de(u.x,u.y)}return n&&(s[s.length-1]=s[0]),s}var cF=class{constructor(e,t,r,i,n){this._vertexBufferType=e,this._topologyVector=t,this._vertexOffsets=r,this._vertexBuffer=i,this._mortonSettings=n}get vertexBufferType(){return this._vertexBufferType}get topologyVector(){return this._topologyVector}get vertexOffsets(){return this._vertexOffsets}get vertexBuffer(){return this._vertexBuffer}getSimpleEncodedVertex(e){let t=this.vertexOffsets?this.vertexOffsets[e]*2:e*2;return[this.vertexBuffer[t],this.vertexBuffer[t+1]]}getVertex(e){if(this.vertexOffsets&&this.mortonSettings){let r=this.vertexOffsets[e],i=this.vertexBuffer[r],n=xS(i,this.mortonSettings.numBits,this.mortonSettings.coordinateShift);return[n.x,n.y]}let t=this.vertexOffsets?this.vertexOffsets[e]*2:e*2;return[this.vertexBuffer[t],this.vertexBuffer[t+1]]}getGeometries(){return PEe(this)}get mortonSettings(){return this._mortonSettings}};function AEe(e,t,r,i,n){return new dF(e,t,jc.VEC_2,r,i,n)}function DEe(e,t,r,i,n,a){return new dF(e,t,jc.MORTON,r,i,n,a)}var dF=class extends cF{constructor(e,t,r,i,n,a,s){super(r,i,n,a,s),this._numGeometries=e,this._geometryType=t}geometryType(e){return this._geometryType}get numGeometries(){return this._numGeometries}containsPolygonGeometry(){return this._geometryType===vi.POLYGON||this._geometryType===vi.MULTIPOLYGON}containsSingleGeometryType(){return!0}};
741function REe(e,t,r,i){return new hF(jc.VEC_2,e,t,r,i)}function OEe(e,t,r,i,n){return new hF(jc.MORTON,e,t,r,i,n)}var hF=class extends cF{constructor(e,t,r,i,n,a){super(e,r,i,n,a),this._geometryTypes=t}geometryType(e){return this._geometryTypes[e]}get numGeometries(){return this._geometryTypes.length}containsPolygonGeometry(){for(let e=0;e<this.numGeometries;e++)if(this.geometryType(e)===vi.POLYGON||this.geometryType(e)===vi.MULTIPOLYGON)return!0;return!1}containsSingleGeometryType(){return!1}},fF=class{constructor(e,t,r,i){this._triangleOffsets=e,this._indexBuffer=t,this._vertexBuffer=r,this._topologyVector=i}get triangleOffsets(){return this._triangleOffsets}get indexBuffer(){return this._indexBuffer}get vertexBuffer(){return this._vertexBuffer}get topologyVector(){return this._topologyVector}getGeometries(){if(!this._topologyVector)throw Error("Cannot convert GpuVector to coordinates without topology information");let e=Array(this.numGeometries),t=this._topologyVector,r=t.partOffsets,i=t.ringOffsets,n=t.geometryOffsets,a=0,s=1,o=1,l=1;for(let u=0;u<this.numGeometries;u++)switch(this.geometryType(u)){case vi.POLYGON:{let c=r[s]-r[s-1];s++;let d=[];for(let h=0;h<c;h++){let f=i[o]-i[o-1];o++;let p=[];for(let m=0;m<f;m++){let g=this._vertexBuffer[a++],v=this._vertexBuffer[a++];p.push(new de(g,v))}p.length>0&&p.push(p[0]),d.push(p)}e[u]=d,n&&l++}break;case vi.MULTIPOLYGON:{let c=n[l]-n[l-1];l++;let d=[];for(let h=0;h<c;h++){let f=r[s]-r[s-1];s++;for(let p=0;p<f;p++){let m=i[o]-i[o-1];o++;let g=[];for(let v=0;v<m;v++){let x=this._vertexBuffer[a++],_=this._vertexBuffer[a++];g.push(new de(x,_))}g.length>0&&g.push(g[0]),d.push(g)}}e[u]=d}}return e}[Symbol.iterator](){return null}};function j8(e,t,r,i,n,a){return new LEe(e,t,r,i,n,a)}var LEe=class extends fF{constructor(e,t,r,i,n,a){super(r,i,n,a),this._numGeometries=e,this._geometryType=t}geometryType(e){return this._geometryType}get numGeometries(){return this._numGeometries}containsSingleGeometryType(){return!0}};function U8(e,t,r,i,n){return new FEe(e,t,r,i,n)}var FEe=class extends fF{constructor(e,t,r,i,n){super(t,r,i,n),this._geometryTypes=e}geometryType(e){return this._geometryTypes[e]}get numGeometries(){return this._geometryTypes.length}containsSingleGeometryType(){return!1}};function zEe(e,t,r,i,n){let a=fn(e,r),s=gv(a,i,e,r),o,l,u,c;if(s===gr.CONST){let _=bS(e,r,a),y,w,$,S;for(let E=0;E<t-1;E++){let C=fn(e,r);switch(C.physicalStreamType){case li.LENGTH:switch(C.logicalStreamType.lengthType){case gi.GEOMETRIES:y=Fl(e,r,C);break;case gi.PARTS:w=Fl(e,r,C);break;case gi.RINGS:$=Fl(e,r,C);break;case gi.TRIANGLES:S=Fl(e,r,C)}break;case li.OFFSET:switch(C.logicalStreamType.offsetType){case No.VERTEX:o=Fn(e,r,C);break;case No.INDEX:c=Fn(e,r,C)}break;case li.DATA:if(kn.VERTEX===C.logicalStreamType.dictionaryType)l=Ww(e,r,C,n);else{let I=C;u={numBits:I.numBits,coordinateShift:I.coordinateShift},l=Fn(e,r,C,n)}}}return c?y!==void 0||w!==void 0?j8(i,_,S,c,l,{geometryOffsets:y,partOffsets:w,ringOffsets:$}):j8(i,_,S,c,l):u===void 0?AEe(i,_,{geometryOffsets:y,partOffsets:w,ringOffsets:$},o,l):DEe(i,_,{geometryOffsets:y,partOffsets:w,ringOffsets:$},o,l,u)}let d=Fn(e,r,a),h,f,p,m;for(let _=0;_<t-1;_++){let y=fn(e,r);switch(y.physicalStreamType){case li.LENGTH:switch(y.logicalStreamType.lengthType){case gi.GEOMETRIES:h=Fn(e,r,y);break;case gi.PARTS:f=Fn(e,r,y);break;case gi.RINGS:p=Fn(e,r,y);break;case gi.TRIANGLES:m=Fl(e,r,y)}break;case li.OFFSET:switch(y.logicalStreamType.offsetType){case No.VERTEX:o=Fn(e,r,y);break;case No.INDEX:c=Fn(e,r,y)}break;case li.DATA:if(kn.VERTEX===y.logicalStreamType.dictionaryType)l=Ww(e,r,y,n);else{let w=y;u={numBits:w.numBits,coordinateShift:w.coordinateShift},l=Fn(e,r,y,n)}}}let g,v,x;return h?(g=Bb(d,h,2),f&&p?(v=V8(d,g,f,!1),x=BEe(d,g,v,p)):f&&(v=NEe(d,g,f))):f&&p?(v=Bb(d,f,1),x=V8(d,v,p,!0)):f&&(v=Bb(d,f,0)),c&&!v?U8(d,m,c,l):c?U8(d,m,c,l,{geometryOffsets:g,partOffsets:v,ringOffsets:x}):u===void 0?REe(d,{geometryOffsets:g,partOffsets:v,ringOffsets:x},o,l):OEe(d,{geometryOffsets:g,partOffsets:v,ringOffsets:x},o,l,u)}function Bb(e,t,r){let i=new Uint32Array(e.length+1),n=0;i[0]=n;let a=0;for(let s=0;s<e.length;s++)n=i[s+1]=n+(e[s]>r?t[a++]:1);return i}
vendor: 2,529 bytes, line 741
741function V8(e,t,r,i){let n=new Uint32Array(t[t.length-1]+1),a=0;n[0]=a;let s=1,o=0;for(let l=0;l<e.length;l++){let u=e[l],c=t[l+1]-t[l];if(u===5||u===2||i&&(u===4||u===1))for(let d=0;d<c;d++)a=n[s++]=a+r[o++];else for(let d=0;d<c;d++)n[s++]=++a}return n}function NEe(e,t,r){let i=new Uint32Array(t[t.length-1]+1),n=0;i[0]=n;let a=1,s=0;for(let o=0;o<e.length;o++){let l=e[o],u=t[o+1]-t[o];if(l===4||l===1)for(let c=0;c<u;c++)n=i[a++]=n+r[s++];else for(let c=0;c<u;c++)i[a++]=++n}return i}function BEe(e,t,r,i){let n=new Uint32Array(r[r.length-1]+1),a=0;n[0]=a;let s=1,o=1,l=0;for(let u=0;u<e.length;u++){let c=e[u],d=t[u+1]-t[u];if(c!==0&&c!==3)for(let h=0;h<d;h++){let f=r[s]-r[s-1];s++;for(let p=0;p<f;p++)a=n[o++]=a+i[l++]}else for(let h=0;h<d;h++)n[o++]=++a,s++}return n}var jEe=class extends ef{constructor(e,t,r){super(e,t.getBuffer(),r),this.dataVector=t}getValueFromBuffer(e){return this.dataVector.get(e)}},UEe=class extends mv{getValueFromBuffer(e){return this.dataBuffer[e]}},pF=class extends ef{constructor(e,t,r,i){super(e,i?BigInt64Array.of(t):BigUint64Array.of(t),r)}getValueFromBuffer(e){return this.dataBuffer[0]}};function vg(e,t,r,i,n){let a=VEe(e,Math.ceil(t/8),r,i);return n?mEe(a,t,n):a}function VEe(e,t,r,i){let n=new Uint8Array(t),a=0,s=i.get()+r;for(;a<t&&!(i.get()>=s);){let o=e[i.increment()];if(o<=127){let l=o+3,u=e[i.increment()],c=Math.min(a+l,t);n.fill(u,a,c),a=c}else{let l=256-o;for(let u=0;u<l&&a<t;u++)n[a++]=e[i.increment()]}}return i.set(s),n}function qEe(e,t,r,i){let n=t.get(),a=n+r*Float32Array.BYTES_PER_ELEMENT,s=new Uint8Array(e.subarray(n,a)).buffer,o=new Float32Array(s);return t.set(a),i?rf(o,i,0):o}function GEe(e,t,r,i){let n=t.get(),a=n+r*Float64Array.BYTES_PER_ELEMENT,s=new Uint8Array(e.subarray(n,a)).buffer,o=new Float64Array(s);return t.set(a),i?rf(o,i,0):o}const HEe=new TextDecoder;function wS(e,t,r){return r-t>=12?HEe.decode(e.subarray(t,r)):YEe(e,t,r)}function YEe(e,t,r){let i="",n=t;for(;n<r;){let a=e[n],s=null,o=a>239?4:a>223?3:a>191?2:1;if(n+o>r)break;let l,u,c;o===1?a<128&&(s=a):o===2?(l=e[n+1],(l&192)==128&&(s=(a&31)<<6|l&63,s<=127&&(s=null))):o===3?(l=e[n+1],u=e[n+2],(l&192)==128&&(u&192)==128&&(s=(a&15)<<12|(l&63)<<6|u&63,(s<=2047||s>=55296&&s<=57343)&&(s=null))):o===4&&(l=e[n+1],u=e[n+2],c=e[n+3],(l&192)==128&&(u&192)==128&&(c&192)==128&&(s=(a&15)<<18|(l&63)<<12|(u&63)<<6|c&63,(s<=65535||s>=1114112)&&(s=null))),s===null?(s=65533,o=1):s>65535&&(s-=65536,i+=String.fromCharCode(s>>>10&1023|55296),s=56320|s&1023),i+=String.fromCharCode(s),n+=o}return i}
741var $S=class extends ef{constructor(e,t,r,i){super(e,r,i),this.offsetBuffer=t}},q8=class extends $S{constructor(e,t,r,i){super(e,t,r,i??t.length-1)}getValueFromBuffer(e){let t=this.offsetBuffer[e],r=this.offsetBuffer[e+1];return wS(this.dataBuffer,t,r)}},eh=class extends $S{constructor(e,t,r,i,n){super(e,r,i,n??t.length),this.indexBuffer=t,this.indexBuffer=t}getValueFromBuffer(e){let t=this.indexBuffer[e],r=this.offsetBuffer[t],i=this.offsetBuffer[t+1];return wS(this.dataBuffer,r,i)}};function WEe(e,t,r){let i=[],n=Array(t.length).fill(0);for(let a=1;a<t.length;a++)n[a]=n[a-1]+t[a-1];for(let a=0;a<r.length;a++)if(r[a]===255)i.push(r[++a]);else{let s=t[r[a]],o=n[r[a]];for(let l=0;l<s;l++)i.push(e[o+l])}return new Uint8Array(i)}var mF=class extends $S{constructor(e,t,r,i,n,a,s){super(e,r,i,s??t.length),this.indexBuffer=t,this.symbolOffsetBuffer=n,this.symbolTableBuffer=a}getValueFromBuffer(e){this.decodedDictionary??(this.decodedDictionary=(this.symbolLengthBuffer??(this.symbolLengthBuffer=this.offsetToLengthBuffer(this.symbolOffsetBuffer)),WEe(this.symbolTableBuffer,this.symbolLengthBuffer,this.dataBuffer)));let t=this.indexBuffer[e],r=this.offsetBuffer[t],i=this.offsetBuffer[t+1];return wS(this.decodedDictionary,r,i)}offsetToLengthBuffer(e){let t=new Uint32Array(e.length-1),r=e[0];for(let i=1;i<e.length;i++){let n=e[i];t[i-1]=n-r,r=n}return t}};function ZEe(e,t,r,i,n){let a=null,s=null,o=null,l=null,u=null,c=n??null,d=null,h=null;for(let f=0;f<i;f++){let p=fn(t,r);switch(p.physicalStreamType){case li.PRESENT:{let m=new fl(vg(t,p.numValues,p.byteLength,r),p.numValues);c=n??m;break}case li.OFFSET:s=Fn(t,r,p,void 0,c);break;case li.LENGTH:{let m=Fl(t,r,p);gi.DICTIONARY===p.logicalStreamType.lengthType?a=m:gi.SYMBOL===p.logicalStreamType.lengthType?l=m:d=m;break}case li.DATA:{let m=t.subarray(r.get(),r.get()+p.byteLength);r.add(p.byteLength);let g=p.logicalStreamType.dictionaryType;kn.FSST===g?u=m:kn.SINGLE===g||kn.SHARED===g?o=m:kn.NONE===g&&(h=m);break}}}return KEe(e,u,s,a,o,l,c)??XEe(e,o,s,a,c)??JEe(e,d,h,s,c)}function KEe(e,t,r,i,n,a,s){return t?new mF(e,r,i,n,a,t,s):null}function XEe(e,t,r,i,n){return t?n?new eh(e,r,i,t,n):new eh(e,r,i,t):null}function JEe(e,t,r,i,n){if(!t||!r)return null;if(i)return n?new eh(e,i,t,r,n):new eh(e,i,t,r);if(n&&n.size()!==t.length-1){let a=new Uint32Array(n.size()),s=0;for(let o=0;o<n.size();o++)n.get(o)?a[o]=s++:a[o]=0;return new eh(e,a,t,r,n)}return n?new q8(e,t,r,n):new q8(e,t,r)}function QEe(e,t,r,i){let n=null,a=null,s=null,o=null,l=!1;for(;!l;){let h=fn(e,t);switch(h.physicalStreamType){case li.LENGTH:gi.DICTIONARY===h.logicalStreamType.lengthType?n=Fl(e,t,h):s=Fl(e,t,h);break;case li.DATA:kn.SINGLE===h.logicalStreamType.dictionaryType||kn.SHARED===h.logicalStreamType.dictionaryType?(a=e.subarray(t.get(),t.get()+h.byteLength),l=!0):o=e.subarray(t.get(),t.get()+h.byteLength),t.add(h.byteLength)}}let u=r.complexType.children,c=[],d=0;for(let h of u){let f=Vi(e,t,1)[0];if(f===0)continue;let p=h.name?`${r.name}${h.name}`:r.name;if(h.type!=="scalarField"||h.scalarField.physicalType!==zt.STRING)throw Error("Currently only scalar string fields are implemented for a struct.");if(f>1&&!h.nullable||f===1&&h.nullable)throw Error(`The number of streams for the child field ${h.name} does not match its nullability. nullibilty: ${h.nullable}, numStreams: ${f}`);let m;if(h.nullable){let v=fn(e,t);m=new fl(vg(e,v.numValues,v.byteLength,t),v.numValues)}let g=Fn(e,t,fn(e,t),void 0,m);c[d++]=o?new mF(p,g,n,a,s,o,m):new eh(p,g,n,a,m)}return c}function ePe(e,t,r,i,n,a){return r.type==="scalarType"?tPe(i,e,t,n,r.scalarType,r):i===0?null:QEe(e,t,r)}function tPe(e,t,r,i,n,a){let s=null;if(e===0)return null;if(a.nullable){let l=fn(t,r),u=l.numValues,c=r.get(),d=vg(t,u,l.byteLength,r);r.set(c+l.byteLength),s=new fl(d,l.numValues)}let o=s??i;switch(n.physicalType){case zt.UINT_32:case zt.INT_32:return sPe(t,r,a,n,o);case zt.STRING:{let l=a.nullable?e-1:e;return ZEe(a.name,t,r,l,s)}case zt.BOOLEAN:return rPe(t,r,a,i,o);case zt.UINT_64:case zt.INT_64:return aPe(t,r,a,o,n);case zt.FLOAT:return iPe(t,r,a,o);case zt.DOUBLE:return nPe(t,r,a,o);default:throw Error(`The specified data type for the field is currently not supported: ${n}`)}}
741function rPe(e,t,r,i,n){let a=fn(e,t),s=a.numValues,o=t.get(),l=bg(n)?n:void 0,u=vg(e,s,a.byteLength,t,l);t.set(o+a.byteLength);let c=new fl(u,s);return new jEe(r.name,c,n)}function iPe(e,t,r,i){let n=fn(e,t),a=bg(i)?i:void 0,s=qEe(e,t,n.numValues,a);return new UEe(r.name,s,i)}function nPe(e,t,r,i){let n=fn(e,t),a=bg(i)?i:void 0,s=GEe(e,t,n.numValues,a);return new fS(r.name,s,i)}function aPe(e,t,r,i,n){let a=fn(e,t),s=gv(a,i,e,t,"int64"),o=n.physicalType===zt.INT_64;if(s===gr.FLAT){let u=bg(i)?i:void 0,c=o?_Ee(e,t,a,u):sF(e,t,a,u);return new lF(r.name,c,i)}if(s===gr.SEQUENCE){let u=aF(e,t,a);return new uF(r.name,u[0],u[1],a.numRleValues)}let l=o?vEe(e,t,a):oF(e,t,a);return new pF(r.name,l,i,o)}function sPe(e,t,r,i,n){let a=fn(e,t),s=gv(a,n,e,t),o=i.physicalType===zt.INT_32;if(s===gr.FLAT){let u=bg(n)?n:void 0,c=o?Ww(e,t,a,void 0,u):Fn(e,t,a,void 0,u);return new hS(r.name,c,n)}if(s===gr.SEQUENCE){let u=nF(e,t,a);return new pS(r.name,u[0],u[1],a.numRleValues)}let l=o?gEe(e,t,a):bS(e,t,a);return new mS(r.name,l,n,o)}function bg(e){return e instanceof fl}function gF(e){switch(e){case 0:case 1:case 2:case 3:{let t={};t.nullable=!!(e&1),t.columnScope=y_.FEATURE;let r={};return r.type="logicalType",r.logicalType=gS.ID,r.longID=!!(e&2),t.scalarType=r,t.type="scalarType",t}case 4:{let t={};t.nullable=!1,t.columnScope=y_.FEATURE;let r={};return r.type="physicalType",r.physicalType=jm.GEOMETRY,t.type="complexType",t.complexType=r,t}case 30:{let t={};t.nullable=!1,t.columnScope=y_.FEATURE;let r={};return r.type="physicalType",r.physicalType=jm.STRUCT,t.type="complexType",t.complexType=r,t}default:return cPe(e)}}function _F(e){return e>=10}function yF(e){return e===30}function oPe(e){if(e.type==="scalarType"){let t=e.scalarType;if(t.type==="physicalType")switch(t.physicalType){case zt.BOOLEAN:case zt.INT_8:case zt.UINT_8:case zt.INT_32:case zt.UINT_32:case zt.INT_64:case zt.UINT_64:case zt.FLOAT:case zt.DOUBLE:return!1;case zt.STRING:return!0;default:return!1}if(t.type==="logicalType")return!1}else if(e.type==="complexType"){let t=e.complexType;if(t.type==="physicalType")switch(t.physicalType){case jm.GEOMETRY:case jm.STRUCT:return!0;default:return!1}}return console.warn("Unexpected column type in hasStreamCount",e),!1}function lPe(e){var t;return e.type==="scalarType"&&((t=e.scalarType)==null?void 0:t.type)==="logicalType"&&e.scalarType.logicalType===gS.ID}function uPe(e){var t;return e.type==="complexType"&&((t=e.complexType)==null?void 0:t.type)==="physicalType"&&e.complexType.physicalType===jm.GEOMETRY}function cPe(e){let t;switch(e){case 10:case 11:t=zt.BOOLEAN;break;case 12:case 13:t=zt.INT_8;break;case 14:case 15:t=zt.UINT_8;break;case 16:case 17:t=zt.INT_32;break;case 18:case 19:t=zt.UINT_32;break;case 20:case 21:t=zt.INT_64;break;case 22:case 23:t=zt.UINT_64;break;case 24:case 25:t=zt.FLOAT;break;case 26:case 27:t=zt.DOUBLE;break;case 28:case 29:t=zt.STRING;break;default:return null}let r={};r.nullable=!!(e&1),r.columnScope=y_.FEATURE;let i={};return i.type="physicalType",i.physicalType=t,r.type="scalarType",r.scalarType=i,r}const dPe=new TextDecoder;function SS(e,t){let r=Vi(e,t,1)[0];if(r===0)return"";let i=t.get(),n=i+r,a=e.subarray(i,n);return t.add(r),dPe.decode(a)}function hPe(e){return{name:e.name,nullable:e.nullable,scalarField:e.scalarType,complexField:e.complexType,type:e.type==="scalarType"?"scalarField":"complexField"}}function vF(e,t){let r=Vi(e,t,1)[0]>>>0;if(r<10||r>30)throw Error(`Unsupported field type code ${r}. Supported: 10-29(scalars), 30(STRUCT)`);let i=gF(r);if(_F(r)&&(i.name=SS(e,t)),yF(r)){let n=Vi(e,t,1)[0]>>>0;i.complexType.children=Array(n);for(let a=0;a<n;a++)i.complexType.children[a]=vF(e,t)}return hPe(i)}function fPe(e,t){let r=Vi(e,t,1)[0]>>>0,i=gF(r);if(!i)throw Error(`Unsupported column type code ${r}. Supported: 0-3(ID), 4(GEOMETRY), 10-29(scalars), 30(STRUCT)`);if(_F(r)?i.name=SS(e,t):r>=0&&r<=3?i.name="id":r===4&&(i.name="geometry"),yF(r)){let n=Vi(e,t,1)[0]>>>0,a=i.complexType;a.children=Array(n);for(let s=0;s<n;s++)a.children[s]=vF(e,t)}return i}function pPe(e,t){let r={};r.featureTables=[];let i={};if(i.name=SS(e,t),i.name.length===0)throw Error("Missing layer name");let n=Vi(e,t,1)[0]>>>0,a=Vi(e,t,1)[0]>>>0;i.columns=Array(a);for(let s=0;s<a;s++)i.columns[s]=fPe(e,t);return r.featureTables.push(i),[r,n]}function mPe(e,t,r=!0){let i=new eF(0),n=[];for(;i.get()<e.length;){let a=Vi(e,i,1)[0]>>>0,s=i.get()+a;if(s>e.length)throw Error(`Block overruns tile: ${s} > ${e.length}`);if(Vi(e,i,1)[0]>>>0!=1){i.set(s);continue}let[o,l]=pPe(e,i),u=o.featureTables[0],c=null,d=null,h=[],f=0;for(let m of u.columns){let g=m.name;if(lPe(m)){let v=null;if(m.nullable){let _=fn(e,i),y=i.get(),w=vg(e,_.numValues,_.byteLength,i);i.set(y+_.byteLength),v=new fl(w,_.numValues)}let x=fn(e,i);f=v?v.size():x.decompressedCount,c=gPe(e,m,i,g,x,v??f,r)}else if(uPe(m)){let v=Vi(e,i,1)[0];if(f===0){let x=i.get();f=fn(e,i).decompressedCount,i.set(x)}d=zEe(e,v,i,f,t)}else{let v=oPe(m)?Vi(e,i,1)[0]:1;if(v===0)continue;let x=ePe(e,i,m,v,f);if(x)if(Array.isArray(x))for(let _ of x)h.push(_);else h.push(x)}}let p=new Yke(u.name,d,c,h,l);n.push(p),i.set(s)}return n}function gPe(e,t,r,i,n,a,s=!1){let o=t.scalarType;if((o==null?void 0:o.type)!=="logicalType"||o.logicalType!==gS.ID)throw Error(`ID column must be a logical ID scalar type: ${i}`);let l=o.longID?zt.UINT_64:zt.UINT_32,u=typeof a=="number"?void 0:a,c=gv(n,a,e,r,l===zt.UINT_64?"int64":"int32");if(l===zt.UINT_32)switch(c){case gr.FLAT:return new hS(i,Fn(e,r,n,void 0,u),a);case gr.SEQUENCE:{let d=nF(e,r,n);return new pS(i,d[0],d[1],n.numRleValues)}case gr.CONST:return new mS(i,bS(e,r,n),a,!1)}switch(c){case gr.FLAT:return s?new fS(i,yEe(e,r,n),a):new lF(i,sF(e,r,n,u),a);case gr.SEQUENCE:{let d=aF(e,r,n);return new uF(i,d[0],d[1],n.numRleValues)}case gr.CONST:return new pF(i,oF(e,r,n),a,!1)}throw Error("Vector type not supported for id column.")}var _Pe=class{constructor(e,t){var r;switch(this._featureData=e,this.properties=this._featureData.properties||{},(r=this._featureData.geometry)==null?void 0:r.type){case vi.POINT:case vi.MULTIPOINT:this.t
vendor: 4,936 bytes, line 741
741ype=1;break;case vi.LINESTRING:case vi.MULTILINESTRING:this.type=2;break;case vi.POLYGON:case vi.MULTIPOLYGON:this.type=3;break;default:this.type=0}this.extent=t,this.id=Number(this._featureData.id)}loadGeometry(){let e=[];for(let t of this._featureData.geometry.coordinates){let r=[];for(let i of t)r.push(new de(i.x,i.y));e.push(r)}return e}},yPe=class{constructor(e){this.features=[],this.featureTable=e,this.name=e.name,this.extent=e.extent,this.version=2,this.features=e.getFeatures(),this.length=this.features.length}feature(e){return new _Pe(this.features[e],this.extent)}},vPe=class{constructor(e){this.layers={};let t=mPe(new Uint8Array(e));this.layers=t.reduce((r,i)=>({...r,[i.name]:new yPe(i)}),{})}},bPe=class{constructor(e,t){this.tileID=e,this.x=e.canonical.x,this.y=e.canonical.y,this.z=e.canonical.z,this.grid=new iw(ye,16,0),this.grid3D=new iw(ye,16,0),this.featureIndexArray=new pL,this.promoteId=t}insert(e,t,r,i,n,a){let s=this.featureIndexArray.length;this.featureIndexArray.emplaceBack(r,i,n);let o=a?this.grid3D:this.grid;for(let l of t){let u=[1/0,1/0,-1/0,-1/0];for(let c of l)u[0]=Math.min(u[0],c.x),u[1]=Math.min(u[1],c.y),u[2]=Math.max(u[2],c.x),u[3]=Math.max(u[3],c.y);u[0]<8192&&u[1]<8192&&u[2]>=0&&u[3]>=0&&o.insert(s,u[0],u[1],u[2],u[3])}}loadVTLayers(){if(!this.vtLayers){switch(this.encoding){case"mlt":this.vtLayers=new vPe(this.rawTileData).layers;break;default:this.vtLayers=new PCe(new HL(this.rawTileData)).layers}this.sourceLayerCoder=new Hke(this.vtLayers?Object.keys(this.vtLayers).sort():[__])}return this.vtLayers}query(e,t,r,i){this.loadVTLayers();let n=e.params,a=ye/e.tileSize/e.scale,s=Pm(n.filter,"queryRenderedFeatures filter",n.globalState),o=e.queryGeometry,l=e.queryPadding*a,u=no.fromPoints(o),c=this.grid.query(u.minX-l,u.minY-l,u.maxX+l,u.maxY+l),d=no.fromPoints(e.cameraQueryGeometry).expandBy(l),h=this.grid3D.query(d.minX,d.minY,d.maxX,d.maxY,(m,g,v,x)=>d6e(e.cameraQueryGeometry,m-l,g-l,v+l,x+l));for(let m of h)c.push(m);c.sort(xPe);let f={},p;for(let m of c){if(m===p)continue;p=m;let g=this.featureIndexArray.get(m),v=null;this.loadMatchingFeature(f,g.bucketIndex,g.sourceLayerIndex,g.featureIndex,s,n.layers,n.availableImages,t,r,i,(x,_,y)=>(v||(v=Nc(x)),_.queryIntersectsFeature({queryGeometry:o,feature:x,featureState:y,geometry:v,zoom:this.z,transform:e.transform,pixelsToTileUnits:a,pixelPosMatrix:e.pixelPosMatrix,unwrappedTileID:this.tileID.toUnwrapped(),getElevation:e.getElevation})))}return f}loadMatchingFeature(e,t,r,i,n,a,s,o,l,u,c){let d=this.bucketLayerIDs[t];if(a&&!d.some(m=>a.has(m)))return;let h=this.sourceLayerCoder.decode(r),f=this.vtLayers[h].feature(i);if(n.needGeometry){let m=Bc(f,!0);if(!n.filter(new Tr(this.tileID.overscaledZ),m,this.tileID.canonical))return}else if(!n.filter(new Tr(this.tileID.overscaledZ),f))return;let p=this.getId(f,h);for(let m of d){if(a&&!a.has(m))continue;let g=o[m];if(!g)continue;let v={};p&&u&&(v=u.getState(g.sourceLayer||"_geojsonTileLayer",p));let x=Ne({},l[m]);x.paint=G8(x.paint,g.paint,f,v,s),x.layout=G8(x.layout,g.layout,f,v,s);let _=!c||c(f,g,v);if(!_)continue;let y=new JL(f,this.z,this.x,this.y,p);y.layer=x;let w=e[m];w===void 0&&(w=e[m]=[]),w.push({featureIndex:i,feature:y,intersectionZ:_})}}lookupSymbolFeatures(e,t,r,i,n,a,s,o){let l={};this.loadVTLayers();let u=Pm(n.filterSpec,"queryRenderedFeatures symbol filter",n.globalState);for(let c of e)this.loadMatchingFeature(l,r,i,c,u,a,s,o,t);return l}hasLayer(e){for(let t of this.bucketLayerIDs)for(let r of t)if(e===r)return!0;return!1}getId(e,t){var i;let r=e.id;if(this.promoteId){let n=typeof this.promoteId=="string"?this.promoteId:this.promoteId[t];r=e.properties[n],typeof r=="boolean"&&(r=Number(r)),r===void 0&&((i=e.properties)!=null&&i.cluster)&&this.promoteId&&(r=Number(e.properties.cluster_id))}return r}};Ae("FeatureIndex",bPe,{omit:["rawTileData","sourceLayerCoder"]});function G8(e,t,r,i,n){return A$(e,(a,s)=>{let o=t instanceof lv?t.get(s):null;return o!=null&&o.evaluate?o.evaluate(r,i,n):o})}function xPe(e,t){return t-e}var wPe=class{constructor(e,t){this.max=e,this.onRemove=t,this.reset()}reset(){for(let e in this.data)for(let t of this.data[e])t.timeout&&clearTimeout(t.timeout),this.onRemove(t.value);return this.data={},this.order=[],this}add(e,t,r){let i=e.wrapped().key;this.data[i]===void 0&&(this.data[i]=[]);let n={value:t,timeout:void 0};if(r!==void 0&&(n.timeout=setTimeout(()=>{this.remove(e,n)},r)),this.data[i].push(n),this.order.push(i),this.order.length>this.max){let a=this._getAndRemoveByKey(this.order[0]);a&&this.onRemove(a)}return this}has(e){return e.wrapped().key in this.data}getAndRemove(e){return this.has(e)?this._getAndRemoveByKey(e.wrapped().key):null}_getAndRemoveByKey(e){let t=this.data[e].shift();return t.timeout&&clearTimeout(t.timeout),this.data[e].length===0&&delete this.data[e],this.order.splice(this.order.indexOf(e),1),t.value}getByKey(e){let t=this.data[e];return t?t[0].value:null}
741get(e){return this.has(e)?this.data[e.wrapped().key][0].value:null}remove(e,t){if(!this.has(e))return this;let r=e.wrapped().key,i=t===void 0?0:this.data[r].indexOf(t),n=this.data[r][i];return this.data[r].splice(i,1),n.timeout&&clearTimeout(n.timeout),this.data[r].length===0&&delete this.data[r],this.onRemove(n.value),this.order.splice(this.order.indexOf(r),1),this}setMaxSize(e){for(this.max=e;this.order.length>this.max;){let t=this._getAndRemoveByKey(this.order[0]);t&&this.onRemove(t)}return this}filter(e){let t=[];for(let r in this.data)for(let i of this.data[r])e(i.value)||t.push(i);for(let r of t)this.remove(r.value.tileID,r)}};function $Pe(e,t,r,i,n){let a=[];for(let s of e){let o;for(let l=0;l<s.length-1;l++){let u=s[l],c=s[l+1];u.x<t&&c.x<t||(u.x<t?u=new de(t,u.y+(c.y-u.y)*((t-u.x)/(c.x-u.x)))._round():c.x<t&&(c=new de(t,u.y+(c.y-u.y)*((t-u.x)/(c.x-u.x)))._round()),!(u.y<r&&c.y<r)&&(u.y<r?u=new de(u.x+(c.x-u.x)*((r-u.y)/(c.y-u.y)),r)._round():c.y<r&&(c=new de(u.x+(c.x-u.x)*((r-u.y)/(c.y-u.y)),r)._round()),!(u.x>=i&&c.x>=i)&&(u.x>=i?u=new de(i,u.y+(c.y-u.y)*((i-u.x)/(c.x-u.x)))._round():c.x>=i&&(c=new de(i,u.y+(c.y-u.y)*((i-u.x)/(c.x-u.x)))._round()),!(u.y>=n&&c.y>=n)&&(u.y>=n?u=new de(u.x+(c.x-u.x)*((n-u.y)/(c.y-u.y)),n)._round():c.y>=n&&(c=new de(u.x+(c.x-u.x)*((n-u.y)/(c.y-u.y)),n)._round()),(!o||!u.equals(o[o.length-1]))&&(o=[u],a.push(o)),o.push(c)))))}}return a}var SPe=class bF extends de{constructor(t,r,i,n){super(t,r),this.angle=i,n!==void 0&&(this.segment=n)}clone(){return new bF(this.x,this.y,this.angle,this.segment)}};Ae("Anchor",SPe);let H8=(function(e){return e[e.center=1]="center",e[e.left=2]="left",e[e.right=3]="right",e[e.top=4]="top",e[e.bottom=5]="bottom",e[e["top-left"]=6]="top-left",e[e["top-right"]=7]="top-right",e[e["bottom-left"]=8]="bottom-left",e[e["bottom-right"]=9]="bottom-right",e})({});function TPe(e){switch(e){case"right":case"top-right":case"bottom-right":return"right";case"left":case"top-left":case"bottom-left":return"left"}return"center"}/** 742* MapLibre GL JS 743* @license 3-Clause BSD. Full text of license: https://github.com/maplibre/maplibre-gl-js/blob/v6.2.0/LICENSE.txt 744*/var CPe="6.2.0";function xF(){var e=new bi(4);return bi!=Float32Array&&(e[1]=0,e[2]=0),e[0]=1,e[3]=1,e}function kPe(e,t){var r=t[0],i=t[1],n=t[2],a=t[3],s=r*a-n*i;return s?(s=1/s,e[0]=a*s,e[1]=-i*s,e[2]=-n*s,e[3]=r*s,e):null}function EPe(e,t,r){var i=t[0],n=t[1],a=t[2],s=t[3],o=Math.sin(r),l=Math.cos(r);return e[0]=i*l+a*o,e[1]=n*l+s*o,e[2]=i*-o+a*l,e[3]=n*-o+s*l,e}let jb,Y8,Ub;const qn={frame(e,t,r,i){let n=i||window,a=n.requestAnimationFrame(o=>{s(),t(o)}),{unsubscribe:s}=qx(e.signal,"abort",()=>{s(),n.cancelAnimationFrame(a),r(new lg(e.signal.reason))},!1)},frameAsync(e,t){return new Promise((r,i)=>{this.frame(e,r,i,t)})},getImageData(e,t=0){return this.getImageCanvasContext(e).getImageData(-t,-t,e.width+2*t,e.height+2*t)},getImageCanvasContext(e){let t=window.document.createElement("canvas"),r=t.getContext("2d",{willReadFrequently:!0});if(!r)throw Error("failed to create canvas 2d context");return t.width=e.width,t.height=e.height,r.drawImage(e,0,0,e.width,e.height),r},resolveURL(e){return jb||(jb=document.createElement("a")),jb.href=e,jb.href},get hardwareConcurrency(){return typeof navigator<"u"&&navigator.hardwareConcurrency||4},get prefersReducedMotion(){return Ub===void 0?matchMedia?(Y8??(Y8=matchMedia("(prefers-reduced-motion: reduce)")),Y8.matches):!1:Ub},set prefersReducedMotion(e){Ub=e}},PPe=new class{constructor(){this._frozenAt=null}getCurrentTime(){return this._frozenAt===null?performance.now():this._frozenAt}setNow(e){this._frozenAt=e}restoreNow(){this._frozenAt=null}isFrozen(){return this._frozenAt!==null}};function tr(){return PPe.getCurrentTime()}var t,qt,Ut=(qt=class{static create(t,r,i){let n=window.document.createElement(t);return r!==void 0&&(n.className=r),i&&i.appendChild(n),n}static createNS(t,r){return window.document.createElementNS(t,r)}static disableDrag(){qt.docStyle&&qt.selectProp&&(qt.userSelect=qt.docStyle[qt.selectProp],qt.docStyle[qt.selectProp]="none")}static enableDrag(){qt.docStyle&&qt.selectProp&&(qt.docStyle[qt.selectProp]=qt.userSelect)}static suppressClickInternal(t){t.preventDefault(),t.stopPropagation(),window.removeEventListener("click",qt.suppressClickInternal,!0)}static suppressClick(){window.addEventListener("click",qt.suppressClickInternal,!0),window.setTimeout(()=>{window.removeEventListener("click",qt.suppressClickInternal,!0)},0)}static getScale(t){let r=t.getBoundingClientRect();return{x:r.width/t.offsetWidth||1,y:r.height/t.offsetHeight||1,boundingClientRect:r}}
vendor: 4,178 bytes, line 744
744static getPoint(t,r,i){let n=r.boundingClientRect;return new de((i.clientX-n.left)/r.x-t.clientLeft,(i.clientY-n.top)/r.y-t.clientTop)}static mousePos(t,r){let i=qt.getScale(t);return qt.getPoint(t,i,r)}static touchPos(t,r){let i=[],n=qt.getScale(t);for(let a of r)i.push(qt.getPoint(t,n,a));return i}static sanitize(t){let r=new DOMParser().parseFromString(t,"text/html").body||document.createElement("body"),i=r.querySelectorAll("script");for(let n of i)n.remove();return qt.clean(r),r.innerHTML}static isPossiblyDangerous(t,r){let i=r.replace(/\s+/g,"").toLowerCase();if(["src","href","xlink:href"].includes(t)&&(i.includes("javascript:")||i.includes("data:"))||t.startsWith("on"))return!0}static clean(t){let r=t.children;for(let i of r)qt.removeAttributes(i),qt.clean(i)}static removeAttributes(t){for(let{name:r,value:i}of t.attributes)qt.isPossiblyDangerous(r,i)&&t.removeAttribute(r)}},qt.docStyle=typeof window<"u"&&((t=window.document)==null?void 0:t.documentElement.style),qt.selectProp=!qt.docStyle||"userSelect"in qt.docStyle?"userSelect":"webkitUserSelect",qt);let Zo;(function(e){let t,r,i,n;e.resetRequestQueue=()=>{t=[],r=0,i=0,n={}},e.addThrottleControl=c=>{let d=i++;return n[d]=c,d},e.removeThrottleControl=c=>{delete n[c],l()};let a=()=>{for(let c of Object.keys(n))if(n[c]())return!0;return!1};e.getImage=(c,d,h=!0,f)=>new Promise((p,m)=>{c.headers||(c.headers={}),c.headers.accept="image/webp,*/*",Ne(c,{type:"image"});let g={abortController:d,requestParameters:c,supportImageRefresh:h,imageBitmapOptions:f,state:"queued",onError:v=>{m(v)},onSuccess:v=>{p(v)}};t.push(g),l()});let s=(c,d)=>typeof createImageBitmap=="function"?eSe(c,d):tSe(c),o=async c=>{c.state="running";let{requestParameters:d,supportImageRefresh:h,imageBitmapOptions:f,onError:p,onSuccess:m,abortController:g}=c,v=h===!1&&!f&&!Mh(self)&&!PR(d.url)&&(!d.headers||Object.keys(d.headers).reduce((_,y)=>_&&y==="accept",!0));r++;let x=v?u(d,g):G1(d,g);try{let _=await x;delete c.abortController,c.state="completed",_.data instanceof HTMLImageElement||uc(_.data)?m(_):_.data&&m({data:await s(_.data,f),cacheControl:_.cacheControl,expires:_.expires})}catch(_){delete c.abortController,p(mn(_))}finally{r--,l()}},l=()=>{let c=a()?cl.MAX_PARALLEL_IMAGE_REQUESTS_PER_FRAME:cl.MAX_PARALLEL_IMAGE_REQUESTS;for(let d=r;d<c&&t.length>0;d++){let h=t.shift();if(h.abortController.signal.aborted){d--;continue}o(h)}},u=(c,d)=>new Promise((h,f)=>{let p=new Image,m=c.url,g=c.credentials;g&&g==="include"?p.crossOrigin="use-credentials":(g&&g==="same-origin"||!MR(m))&&(p.crossOrigin="anonymous"),d.signal.addEventListener("abort",()=>{p.src="",f(new lg(d.signal.reason))}),p.fetchPriority="high",p.onload=()=>{p.onerror=p.onload=null,h({data:p})},p.onerror=()=>{p.onerror=p.onload=null,!d.signal.aborted&&f(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."))},p.src=m})})(Zo||(Zo={})),Zo.resetRequestQueue();var MPe=class{constructor(e){this._transformRequestFn=e??null}transformRequest(e,t){return this._transformRequestFn&&this._transformRequestFn(e,t)||{url:e}}setTransformRequest(e){this._transformRequestFn=e}},Ei=class extends ug{},Ve=class extends Ei{},W8=class extends Ei{constructor(e={}){super("style.load",e)}},ms=class extends Ei{constructor(e,t={}){super(e,t),this.dataType="style"}},yr=class extends Ei{constructor(t,r={}){super(t,r),this.dataType="source"}},Va=class extends Ei{preventDefault(){this._defaultPrevented=!0}get defaultPrevented(){return this._defaultPrevented}constructor(e,t,r,i={}){r=r instanceof MouseEvent?r:new MouseEvent(e,r);let n=Ut.mousePos(t.getCanvas(),r),a=t.unproject(n);super(e,Ne({point:n,lngLat:a,originalEvent:r},i)),this._defaultPrevented=!1,this.target=t}},T0=class extends Ei{preventDefault(){this._defaultPrevented=!0}get defaultPrevented(){return this._defaultPrevented}constructor(e,t,r){let i=e==="touchend"?r.changedTouches:r.touches,n=Ut.touchPos(t.getCanvasContainer(),i),a=n.map(l=>t.unproject(l)),s=n.reduce((l,u,c,d)=>l.add(u.div(d.length)),new de(0,0)),o=t.unproject(s);super(e,{points:n,point:s,lngLats:a,lngLat:o,originalEvent:r}),this._defaultPrevented=!1}}
744,IPe=class extends Ei{preventDefault(){this._defaultPrevented=!0}get defaultPrevented(){return this._defaultPrevented}constructor(e,t){super("wheel",{originalEvent:t}),this._defaultPrevented=!1}},Z8=class extends Ei{},APe=class extends Ei{constructor(e={}){super("terrain",e)}},DPe=class extends Ei{constructor(e={}){super("projectiontransition",e)}},Vb=class extends Ei{},RPe=class extends Ei{constructor(e={}){super("styleimagemissing",e)}};function v_(e){let t=[];if(typeof e=="string")t.push({id:"default",url:e});else if(e&&e.length>0){let r=[];for(let{id:i,url:n}of e){let a=`${i}${n}`;r.includes(a)||(r.push(a),t.push({id:i,url:n}))}}return t}function K8(e,t,r){try{let i=new URL(e);return i.pathname+=`${t}${r}`,i.toString()}catch{throw Error(`Invalid sprite URL "${e}", must be absolute. Modify style specification directly or use TransformStyleFunction to correct the issue dynamically`)}}async function OPe(e,t,r,i){let n=v_(e),a=r>1?"@2x":"",s={},o={};for(let{id:l,url:u}of n){let c=await t.transformRequest(K8(u,a,".json"),"SpriteJSON");s[l]=H1(c,i);let d=await t.transformRequest(K8(u,a,".png"),"SpriteImage");o[l]=Zo.getImage(d,i)}return await Promise.all([...Object.values(s),...Object.values(o)]),LPe(s,o)}async function LPe(e,t){let r={};for(let i in e){r[i]={};let n=qn.getImageCanvasContext((await t[i]).data),a=(await e[i]).data;for(let s in a){let{width:o,height:l,x:u,y:c,sdf:d,pixelRatio:h,stretchX:f,stretchY:p,content:m,textFitWidth:g,textFitHeight:v}=a[s],x={width:o,height:l,x:u,y:c,context:n};r[i][s]={data:null,pixelRatio:h,sdf:d,stretchX:f,stretchY:p,content:m,textFitWidth:g,textFitHeight:v,spriteData:x}}}return r}var FPe=class extends Rn{constructor(){super(),this.images={},this.updatedImages={},this.callbackDispatchedThisFrame={},this.loaded=!1,this.requestors=[],this.missingImageResolver=null,this.patterns={},this.atlasImage=new _r({width:1,height:1}),this.dirty=!0}destroy(){this.atlasTexture&&(this.atlasTexture=(this.atlasTexture.destroy(),null));for(let e of Object.keys(this.images))this.removeImage(e);this.patterns={},this.atlasImage=new _r({width:1,height:1}),this.dirty=!0}isLoaded(){return this.loaded}setLoaded(e){if(this.loaded!==e&&(this.loaded=e,e)){for(let{ids:t,promiseResolve:r}of this.requestors)r(this._getImagesForIds(t));this.requestors=[]}}getImage(e){let t=this.images[e];if(t&&!t.data&&t.spriteData){let r=t.spriteData;t.data=new _r({width:r.width,height:r.height},r.context.getImageData(r.x,r.y,r.width,r.height).data),t.spriteData=null}return t}addImage(e,t){if(this.images[e])throw Error(`Image id ${e} already exist, use updateImage instead`);this._validate(e,t)&&(this.images[e]=t)}_validate(e,t){let r=!0,i=t.data||t.spriteData;return this._validateStretch(t.stretchX,i==null?void 0:i.width)||(this.fire(new He(Error(`Image "${e}" has invalid "stretchX" value`))),r=!1),this._validateStretch(t.stretchY,i==null?void 0:i.height)||(this.fire(new He(Error(`Image "${e}" has invalid "stretchY" value`))),r=!1),this._validateContent(t.content,t)||(this.fire(new He(Error(`Image "${e}" has invalid "content" value`))),r=!1),r}_validateStretch(e,t){if(!e)return!0;let r=0;for(let i of e){if(i[0]<r||i[1]<i[0]||t<i[1])return!1;r=i[1]}return!0}_validateContent(e,t){if(!e)return!0;if(e.length!==4)return!1;let r=t.spriteData,i=(r==null?void 0:r.width)||t.data.width,n=(r==null?void 0:r.height)||t.data.height;return e[0]<0||i<e[0]||e[1]<0||n<e[1]||e[2]<0||i<e[2]||e[3]<0||n<e[3]||e[2]<e[0]?!1:e[3]>=e[1]}updateImage(e,t,r=!0){let i=this.getImage(e);if(r&&(i.data.width!==t.data.width||i.data.height!==t.data.height))throw Error(`size mismatch between old image (${i.data.width}x${i.data.height}) and new image (${t.data.width}x${t.data.height}).`);t.version=i.version+1,this.images[e]=t,this.updatedImages[e]=!0}removeImage(e){var r;let t=this.images[e];delete this.images[e],delete this.patterns[e],(r=t.userImage)!=null&&r.onRemove&&t.userImage.onRemove()}listImages(){return Object.keys(this.images)}setMissingImageResolver(e){this.missingImageResolver=e}getImages(e){return new Promise((t,r)=>{let i=!0;if(!this.isLoaded())for(let n of e)this.images[n]||(i=!1);this.isLoaded()||i?t(this._getImagesForIds(e)):this.requestors.push({ids:e,promiseResolve:t})})}async _getImagesForIds(e){var n;let t=new Set(e.filter(a=>!this.getImage(a))),r=this.missingImageResolver;r&&await Promise.all(Array.from(t,a=>r(a)));let i={};for(let a of e){let s=this.getImage(a);s&&(t.delete(a),i[a]={data:s.data.clone(),pixelRatio:s.pixelRatio,sdf:s.sdf,ver
744sion:s.version,stretchX:s.stretchX,stretchY:s.stretchY,content:s.content,textFitWidth:s.textFitWidth,textFitHeight:s.textFitHeight,hasRenderCallback:!!((n=s.userImage)!=null&&n.render)})}for(let a of t)this.fire(new RPe({id:a})),vr(`Image "${a}" could not be loaded. Please make sure you have added the image before it is needed with map.addImage(), resolved it with map.setMissingStyleImageResolver(), or included it in a "sprite" property in your style.`);return i}getPixelSize(){let{width:e,height:t}=this.atlasImage;return{width:e,height:t}}getPattern(e){let t=this.patterns[e],r=this.getImage(e);if(!r)return null;if(t&&t.position.version===r.version)return t.position;if(t)t.position.version=r.version;else{let i={w:r.data.width+2,h:r.data.height+2,x:0,y:0},n=new cS(i,r);this.patterns[e]={bin:i,position:n}}return this._updatePatternAtlas(),this.patterns[e].position}bind(e){let t=e.gl;this.atlasTexture?this.dirty&&(this.dirty=(this.atlasTexture.update(this.atlasImage),!1)):this.atlasTexture=new Hr(e,this.atlasImage,t.RGBA),this.atlasTexture.bind(t.LINEAR,t.CLAMP_TO_EDGE)}_updatePatternAtlas(){let e=[];for(let n in this.patterns)e.push(this.patterns[n].bin);let{w:t,h:r}=YL(e),i=this.atlasImage;i.resize({width:t||1,height:r||1});for(let n in this.patterns){let{bin:a}=this.patterns[n],s=a.x+1,o=a.y+1,l=this.getImage(n).data,u=l.width,c=l.height;_r.copy(l,i,{x:0,y:0},{x:s,y:o},{width:u,height:c}),_r.copy(l,i,{x:0,y:c-1},{x:s,y:o-1},{width:u,height:1}),_r.copy(l,i,{x:0,y:0},{x:s,y:o+c},{width:u,height:1}),_r.copy(l,i,{x:u-1,y:0},{x:s-1,y:o},{width:1,height:c}),_r.copy(l,i,{x:0,y:0},{x:s+u,y:o},{width:1,height:c})}this.dirty=!0}beginFrame(){this.callbackDispatchedThisFrame={}}dispatchRenderCallbacks(e){for(let t of e){if(this.callbackDispatchedThisFrame[t])continue;this.callbackDispatchedThisFrame[t]=!0;let r=this.getImage(t);r||vr(`Image with ID: "${t}" was not found`),wke(r)&&this.updateImage(t,r)}}cloneImages(){let e={};for(let t in this.images){let r=this.images[t];e[t]={...r,data:r.data?r.data.clone():null}}return e}};async function zPe(e,t,r,i){let n=t*256,a=n+255,s=await i.transformRequest(r.replace("{fontstack}",e).replace("{range}",`${n}-${a}`),"Glyphs"),o=await hSe(s,new AbortController);if(!(o!=null&&o.data))throw Error(`Could not load glyph range. range: ${t}, ${n}-${a}`);let l={};for(let u of xke(o.data))l[u.id]=u;return l}const Zw=1e20,TS=new Float64Array(256);for(let e=0;e<256;e++){let t=.5-(e/255)**.45454545454545453;TS[e]=t*Math.abs(t)}TS[255]=-1e20;var NPe=class{constructor({fontSize:e=24,buffer:t=3,radius:r=8,cutoff:i=.25,fontFamily:n="sans-serif",fontWeight:a="normal",fontStyle:s="normal",lang:o=null}={}){this.buffer=t,this.radius=r,this.cutoff=i,this.lang=o;let l=this.size=e+t*4,u=this._createCanvas(l),c=this.ctx=u.getContext("2d",{willReadFrequently:!0});c.font=`${s} ${a} ${e}px ${n}`,c.textBaseline="alphabetic",c.textAlign="left",c.fillStyle="black",this.gridOuter=new Float64Array(l*l),this.gridInner=new Float64Array(l*l),this.f=new Float64Array(l),this.z=new Float64Array(l+1),this.v=new Uint16Array(l)}_createCanvas(e){if(typeof OffscreenCanvas<"u")return new OffscreenCanvas(e,e);let t=document.createElement("canvas");return t.width=t.height=e,t}draw(e){let{width:t,actualBoundingBoxAscent:r,actualBoundingBoxDescent:i,actualBoundingBoxLeft:n,actualBoundingBoxRight:a}=this.ctx.measureText(e),s=Math.ceil(r),o=Math.floor(-n),l=Math.max(0,Math.min(this.size-this.buffer,Math.ceil(a)-o)),u=Math.max(0,Math.min(this.size-this.buffer,s+Math.ceil(i))),c=l+2*this.buffer,d=u+2*this.buffer,h=Math.max(c*d,0),f=new Uint8ClampedArray(h),p={data:f,width:c,height:d,glyphWidth:l,glyphHeight:u,glyphTop:s,glyphLeft:o,glyphAdvance:t};if(l===0||u===0)return p;let{ctx:m,buffer:g,gridInner:v,gridOuter:x}=this;this.lang&&(m.lang=this.lang),m.clearRect(g,g,l,u),m.fillText(e,g-o,g+s);let _=m.getImageData(g,g,l,u);x.fill(Zw,0,h),v.fill(0,0,h);let y=3;for(let E=0;E<u;E++){let C=(E+g)*c+g;for(let I=0;I<l;I++,y+=4,C++){let P=_.data[y];if(P===0)continue;let T=TS[P];x[C]=Math.max(0,T),v[C]=Math.max(0,-T)}}X8(x,0,0,c,d,c,this.f,this.v,this.z);let w=Math.min(g,1);X8(v,g-w,g-w,l+2*w,u+2*w,c,this.f,this.v,this.z);let $=255/this.radius,S=255*(1-this.cutoff);for(let E=0;E<h;E++){let C=Math.sqrt(x[E])-Math.sqrt(v[E]);f[E]=Math.round(S-$*C)}return p}};function X8(e,t,r,i,n,a,s,o,l){for(let u=t;u<t+i;u++)J8(e,r*a+u,a,n,s,o,l);for(let u=r;u<r+n;u++)J8(e,u*a+t,1,i,s,o,l)}function J8(e,t,r,i,n,a,s){a[0]=0,s[0]=-1e20,s[1]=Zw,n[0]=e[t];for(let o=1,l=0,u=0;o<i;o++){n[o]=e[t+o*r];let c=o*o;do{let d=a[l];u=(n[o]-n[d]+c-d*d)/(o-d)/2}while(u<=s[l]&&--l>-1);l++,a[l]=o,s[l]=u,s[l+1]=Zw}for(let o=0,l=0;o<i;o++){for(;s[l+1]<o;)l++;let u=a[l],c=o-u;e[t+o*r]=n[u]+c*c}}const BPe=ce.layout_symbol["text-font"].default.join(",");var jo,jPe=(jo=class{constructor(t,r,i){this.requestManager=t,this.localIdeographFontFamily=r,this.entries={},this.lang=i}setURL(t){this.url=t}async getGlyphs(t){let r=[];for(let a in t)for(let s of t[a])r.push(this._getAndCacheGlyphsPromise(a,s));let i=await Promise.all(r),n={};for(let{stack:a,id:s,glyph:o}of i)n[a]||(n[a]={}),n[a][s]=o&&{id:o.id,bitmap:o.bitmap.clone(),metrics:o.metrics};return n}async _getAndCacheGlyphsPromise(t,r){var a;(a=this.entries)[t]??(a[t]={glyphs:{},requests:{},ranges:{}});let i=this.entries[t],n=i.glyphs[r];return n===void 0?!this.url||this._charUsesLocalIdeographFontFamily(r)?(n=i.glyphs[r]=await this._drawGlyph(i,t,r),{stack:t,id:r,glyph:n}):await this._downloadAndCacheRangePromise(t,r):{stack:t,id:r,glyph:n}}async _downloadAndCacheRangePromise(t,r){var a;let i=this.entries[t],n=Math.floor(r/256);if(i.ranges[n])return{stack:t,id:r,glyph:null};(a=i.requests)[n]||(a[n]=jo.loadGlyphRange(t,n,this.url,this.requestManager));try{let s=await i.requests[n];for(let o in s)i.glyphs[+o]=s[+o];return i.ranges[n]=!0,{stack:t,id:r,glyph:s[r]||null}}catch(s){let o=i.glyphs[r]=await this._drawGlyph(i,t,r);return this._warnOnMissingGlyphRange(o,n,r,mn(s)),{stack:t,id:r,glyph:o}}}_warnOnMissingGlyphRange(t,r,i,n){let a=r*256,s=a+255,o=i.toString(16).padStart(4,"0").toUpperCase();vr(`Unable to load glyph range ${r}, ${a}-${s}. Rendering codepoint U+${o} locally instead. ${n}`)}_charUsesLocalIdeographFontFamily(t){return!!this.localIdeographFontFamily&&bTe(t)}async _drawGlyph(t,r,i){let n=r===BPe&&this.localIdeographFontFamily!==""&&this._charUsesLocalIdeographFontFamily(i),a=n?"ideographTinySDF":"tinySDF";t[a]||(t[a]=this._createTinySDF(n?this.localIdeographFontFamily:r));let s=(await t[a]).draw(String.fromCodePoint(i)),o=new RegExp("^\\p{gc=Cf}+$","u").test(String.fromCodePoint(i));return{id:i,bitmap:new sS({width:s.width||60,height:s.height||60},s.data),metrics:{width:o?0:s.glyphWidth/2||24,height:s.glyphHeight/2||24,left:s.glyphLeft/2+.5||0,top:s.glyphTop/2-27.5||-8,advance:o?0:s.glyphAdvance/2||24,isDoubleResolution:!0}}}async _createTinySDF(t){var s;let r=t?t.split(","):[];r.push("sans-serif");let i=r.map(o=>/[-\w]+/.test(o)?o:`'${CSS.escape(o)}'`).join(","),n=this._fontWeight(r[0]),a=this._fontStyle(r[0]);if(typeof document<"u"&&((s=document.fonts)!=null&&s.load))try{await document.fonts.load(`${a} ${n||"normal"} 48px ${i}`)}catch(o){vr(`Failed to load font "${i}": ${mn(o).message}`)}return new jo.TinySDF({fontSize:48,buffer:6,radius:16,cutoff:.25,fontFamily:i,fontWeight:n,fontStyle:a,lang:this.lang})}_fontStyle(t){return/italic/i.test(t)?"italic":/oblique/i.test(t)?"oblique":"normal"}_fontWeight(t){let r={thin:100,hairline:100,"extra light":200,"ultra light":200,light:300,normal:400,regular:400,medium:500,semibold:600,demibold:600,bold:700,"extra bold":800,"ultra bold":800,black:900,heavy:900,"extra black":950,"ultra black":950},i;for(let[n,a]of Object.entries(r))RegExp(`\\b${n}\\b`,"i").test(t)&&(i=`${a}`);return i}destroy(){for(let t in this.entries){let r=this.entries[t];r.tinySDF=null,r.ideographTinySDF=null,r.glyphs={},r.requests={},r.ranges={}}this.entries={}}},jo.loadGlyphRange=zPe,jo.TinySDF=NPe,jo);let UPe;const VPe=()=>UPe||(UPe=new Mi({anchor:new Pe(ce.light.anchor,"anchor"),position:new Pe
744(ce.light.position,"position"),color:new Pe(ce.light.color,"color"),intensity:new Pe(ce.light.intensity,"intensity")}));var qPe=class extends Rn{constructor(e,t){super(),this._transitionable=new ov(VPe(),"light",t),this.setLight(e),this._transitioning=this._transitionable.untransitioned()}getLight(){return this._transitionable.serialize()}getCartesianPosition(){return X$e(this.properties.get("position"))}setLight(e,t={}){if(!this._validate(Nn.light,e,t))for(let r in e){let i=e[r];r.endsWith("-transition")?this._transitionable.setTransition(r.slice(0,-eS.length),i):this._transitionable.setValue(r,i)}}updateTransitions(e){this._transitioning=this._transitionable.transitioned(e,this._transitioning)}hasTransition(){return this._transitioning.hasTransition()}recalculate(e){this.properties=this._transitioning.possiblyEvaluate(e)}_validate(e,t,r){return gg(this,e,{value:t},r)}};let GPe;const HPe=()=>GPe||(GPe=new Mi({"sky-color":new Pe(ce.sky["sky-color"],"sky-color"),"horizon-color":new Pe(ce.sky["horizon-color"],"horizon-color"),"fog-color":new Pe(ce.sky["fog-color"],"fog-color"),"fog-ground-blend":new Pe(ce.sky["fog-ground-blend"],"fog-ground-blend"),"horizon-fog-blend":new Pe(ce.sky["horizon-fog-blend"],"horizon-fog-blend"),"sky-horizon-blend":new Pe(ce.sky["sky-horizon-blend"],"sky-horizon-blend"),"atmosphere-blend":new Pe(ce.sky["atmosphere-blend"],"atmosphere-blend")}));var YPe=class extends Rn{constructor(e,t){super(),this._transitionable=new ov(HPe(),"sky",t),this.setSky(e),this._transitioning=this._transitionable.untransitioned(),this.recalculate(new Tr(0))}setSky(e,t={}){if(!this._validate(Nn.sky,e,t)){e||(e={"sky-color":"transparent","horizon-color":"transparent","fog-color":"transparent","fog-ground-blend":1,"atmosphere-blend":0});for(let r in e){let i=e[r];r.endsWith("-transition")?this._transitionable.setTransition(r.slice(0,-eS.length),i):this._transitionable.setValue(r,i)}}}getSky(){return this._transitionable.serialize()}updateTransitions(e){this._transitioning=this._transitionable.transitioned(e,this._transitioning)}hasTransition(){return this._transitioning.hasTransition()}recalculate(e){this.properties=this._transitioning.possiblyEvaluate(e)}_validate(e,t,r={}){return gg(this,e,{value:t},r)}calculateFogBlendOpacity(e){return e<60?0:e<70?(e-60)/10:1}},WPe=class{constructor(e,t){this.width=e,this.height=t,this.nextRow=0,this.data=new Uint8Array(this.width*this.height),this.dashEntry={}}getDash(e,t){var i;let r=e.join(",")+String(t);return(i=this.dashEntry)[r]||(i[r]=this.addDash(e,t)),this.dashEntry[r]}getDashRanges(e,t,r){let i=e.length%2==1,n=[],a=i?-e[e.length-1]*r:0,s=e[0]*r,o=!0;n.push({left:a,right:s,isDash:o,zeroLength:e[0]===0});let l=e[0];for(let u=1;u<e.length;u++){o=!o;let c=e[u];a=l*r,l+=c,s=l*r,n.push({left:a,right:s,isDash:o,zeroLength:c===0})}return n}addRoundDash(e,t,r){let i=t/2;for(let n=-r;n<=r;n++){let a=this.nextRow+r+n,s=this.width*a,o=0,l=e[o];for(let u=0;u<this.width;u++){u/l.right>1&&(l=e[++o]);let c=Math.abs(u-l.left),d=Math.abs(u-l.right),h=Math.min(c,d),f,p=n/r*(i+1);if(l.isDash){let m=i-Math.abs(p);f=Math.sqrt(h*h+m*m)}else f=i-Math.sqrt(h*h+p*p);this.data[s+u]=Math.max(0,Math.min(255,f+128))}}}addRegularDash(e){for(let s=e.length-1;s>=0;--s){let o=e[s],l=e[s+1];o.zeroLength?e.splice(s,1):(l==null?void 0:l.isDash)===o.isDash&&(l.left=o.left,e.splice(s,1))}let t=e[0],r=e[e.length-1];t.isDash===r.isDash&&(t.left=r.left-this.width,r.right=t.right+this.width);let i=this.width*this.nextRow,n=0,a=e[n];for(let s=0;s<this.width;s++){s/a.right>1&&(a=e[++n]);let o=Math.abs(s-a.left),l=Math.abs(s-a.right),u=Math.min(o,l),c=a.isDash?u:-u;this.data[i+s]=Math.max(0,Math.min(255,c+128))}}addDash(e,t){let r=t?7:0,i=2*r+1;if(this.nextRow+i>this.height)return vr("LineAtlas out of space"),null;let n=0;for(let s of e)n+=s;if(n!==0){let s=this.width/n,o=this.getDashRanges(e,this.width,s);t?this.addRoundDash(o,s,r):this.addRegularDash(o)}let a={y:this.nextRow+r,height:2*r,width:n};return this.nextRow+=i,this.dirty=!0,a}bind(e){let t=e.gl;this.texture?(t.bindTexture(t.TEXTURE_2D,this.texture),this.dirty&&(this.dirty=!1,t.texSubImage2D(t.TEXTURE_2D,0,0,0,this.width,this.height,t.ALPHA,t.UNSIGNED_BYTE,this.data))):(this.texture=t.createTexture(),t.bindTexture(t.TEXTURE_2D,this.texture),t.texParameteri(t.TEXTURE_2D,t.TEXTURE_WRAP_S,t.REPEAT),t.texParameteri(t.TEXTURE_2D,t.TEXTURE_WRAP_T,t.REPEAT),t.texParameteri(t.TEXTURE_2D,t.TEXTURE_MIN_FILTER,t.LINEAR),t.texParameteri(t.TEXTURE_2D,t.TEXTURE_MAG_FILTER,t.LINEAR),t.texImage2D(t.TEXTURE_2D,0,t.ALPHA,this.width,this.height,0,t.ALPHA,t.UNSIGNED_BYTE,this.data))}};function ZPe(e){if(!e)return!1;let t=globalThis.location;if(!t)return!1;try{return new URL(e,t.href).origin!==t.origin}catch{return!1}}function KPe(){let e=import.meta.url;if(!/^https?:/.test(e))return"";let t=e.endsWith("-dev.mjs")?"maplibre-gl-worker-dev.mjs":"maplibre-gl-worker.mjs";return new URL(`./${t}`,e).href}function qb(e,t){if(t)try{return new Worker(e,{type:"module"})}catch(r){console.warn("Module worker not supported, falling back to classic worker",r)}return new Worker(e)}async function XPe(e){let t=await fetch(e);if(!t.ok)throw Error(`Failed to fetch worker script (${t.status}): ${e}`);let r=await t.text(),i=new Blob([r],{type:"text/javascript"});return URL.createObjectURL(i)}function JPe(e){let t=new Blob([`import ${JSON.stringify(new URL(e,import.meta.url).href)}`],{type:"text/javascript"});return URL.createObjectURL(t)}async function QPe(){let e=cl.WORKER_URL||KPe(),t=!(e!=null&&e.endsWith(".cjs"));if(!ZPe(e))return qb(e,t);if(t){let i=JPe(e);try{return qb(i,t)}finally{URL.revokeObjectURL(i)}}let r=await XPe(e);try{return qb(r,t)}finally{URL.revokeObjectURL(r)}}const eMe="maplibre_preloaded_worker_pool";var wF=class $F{constructor(){this.active={},this.workersPromise=null}async acquire(t){if(this.active[t]=!0,!this.workersPromise){let r=[];for(;r.length<$F.workerCount;)r.push(QPe());this.workersPromise=Promise.all(r)}return(await this.workersPromise).slice()}release(t){if(delete this.active[t],this.numActive()===0&&this.workersPromise){let r=this.workersPromise;this.workersPromise=null,r.then(i=>{for(let n of i)n.terminate()})}}isPreloaded(){return!!this.active[eMe]}numActive(){return Object.keys(this.active).length}};const tMe=Math.floor(qn.hardwareConcurrency/2);wF.workerCount=Q$e(globalThis)?Math.max(Math.min(tMe,3),1):1;let Q8;function SF(){return Q8||(Q8=new wF),Q8}var TF=class{constructor(e,t){this.workerPool=e,this.actors=[],this.currentActor=0,this.id=t,this.removed=!1,this.actorsPromise=this.initActors(t)}async initActors(e){let t=await this.workerPool.acquire(e);if(this.removed)return[];if(this.actors=t.map((r,i)=>{let n=new Uke(r,e);return n.name=`Worker ${i}`,n}),!this.actors.length)throw Error("No actors found");return this.actors}async broadcast(e,t){let r=await this.actorsPromise;return Promise.all(r.map(i=>i.sendAsync({type:e,data:t})))}async getActor(){let e=await this.actorsPromise;return this.currentActor=(this.currentActor+1)%e.length,e[this.currentActor]}async waitForInitComplete(){this.actors.length===0&&await this.actorsPromise}getReadyActor(){return this.currentActor=(this.currentActor+1)%this.actors.length,this.actors[this.currentActor]}remove(e=!0){this.removed=!0;for(let t of this.actors)t.remove();
744this.actors=[],e&&this.workerPool.release(this.id)}async registerMessageHandler(e,t){let r=await this.actorsPromise;for(let i of r)i.registerMessageHandler(e,t)}async unregisterMessageHandler(e){let t=await this.actorsPromise;for(let r of t)r.unregisterMessageHandler(e)}};let C0;function rMe(){return C0||(C0=new TF(SF(),Gx),C0.registerMessageHandler("GR",(e,t,r)=>G1(t,r))),C0}function iMe(e,t){let r=_u();return ei(r,r,[1,1,0]),Li(r,r,[e.width*.5,e.height*.5,1]),e.calculatePosMatrix?cd(r,r,e.calculatePosMatrix(t.toUnwrapped())):r}function nMe(e,t,r){if(e)for(let i of e){let n=t[i];if((n==null?void 0:n.source)===r&&n.type==="fill-extrusion")return!0}else for(let i in t){let n=t[i];if(n.source===r&&n.type==="fill-extrusion")return!0}return!1}function aMe(e,t,r,i,n,a,s){let o=nMe((n==null?void 0:n.layers)??null,t,e.id),l=a.maxPitchScaleFactor(),u=e.tilesIn(i,l,o);u.sort(CF);let c=[];for(let d of u)c.push({wrappedTileID:d.tileID.wrapped().key,queryResults:d.tile.queryRenderedFeatures(t,r,e.getState(),d.queryGeometry,d.cameraQueryGeometry,d.scale,n,a,l,iMe(a,d.tileID),s?(h,f)=>s(d.tileID,h,f):void 0)});return uMe(lMe(c),e)}function sMe(e,t,r,i,n,a,s){let o={},l=a.queryRenderedSymbols(i),u=[];for(let c of Object.keys(l).map(Number))u.push(s[c]);u.sort(CF);for(let c of u){let d=c.featureIndex.lookupSymbolFeatures(l[c.bucketInstanceId],t,c.bucketIndex,c.sourceLayerIndex,{filterSpec:n.filter,globalState:n.globalState},n.layers,n.availableImages,e);for(let h in d){o[h]||(o[h]=[]);let f=d[h];f.sort((p,m)=>{let g=c.featureSortOrder;if(g){let v=g.indexOf(p.featureIndex);return g.indexOf(m.featureIndex)-v}return m.featureIndex-p.featureIndex});for(let p of f)o[h].push(p)}}return cMe(o,e,r)}function oMe(e,t){let r=e.getRenderableIds().map(a=>e.getTileByID(a)),i=[],n={};for(let a of r){let s=a.tileID.canonical.key;n[s]||(n[s]=!0,a.querySourceFeatures(i,t))}return i}function CF(e,t){let r=e.tileID,i=t.tileID;return r.overscaledZ-i.overscaledZ||r.canonical.y-i.canonical.y||r.wrap-i.wrap||r.canonical.x-i.canonical.x}function lMe(e){let t={},r={};for(let{queryResults:i,wrappedTileID:n}of e){r[n]||(r[n]={});let a=r[n];for(let s in i){let o=i[s];a[s]||(a[s]={});let l=a[s];t[s]||(t[s]=[]);for(let u of o)l[u.featureIndex]||(l[u.featureIndex]=!0,t[s].push(u))}}return t}function uMe(e,t){for(let r in e)for(let i of e[r])kF(i,t);return e}function cMe(e,t,r){for(let i in e)for(let n of e[i]){let a=r[t[i].source];kF(n,a)}return e}function kF(e,t){let r=e.feature,i=t.getFeatureState(r.layer["source-layer"],r.id);r.source=r.layer.source,r.layer["source-layer"]&&(r.sourceLayer=r.layer["source-layer"]),r.state=i}async function EF(e,t,r,i){let n=e;if(e.url?n=(await H1(await t.transformRequest(e.url,"Source"),r)).data:await qn.frameAsync(r,i),!n)return null;let a=og(Ne(n,e),["tiles","minzoom","maxzoom","attribution","bounds","scheme","tileSize","encoding"]);return"vector_layers"in n&&n.vector_layers&&(a.vectorLayerIds=n.vector_layers.map(s=>s.id)),a}var co=class wo{constructor(t,r){t&&(r?this.setSouthWest(t).setNorthEast(r):Array.isArray(t)&&(t.length===4?this.setSouthWest([t[0],t[1]]).setNorthEast([t[2],t[3]]):this.setSouthWest(t[0]).setNorthEast(t[1])))}setNorthEast(t){return this._ne=t instanceof rt?new rt(t.lng,t.lat):rt.convert(t),this}setSouthWest(t){return this._sw=t instanceof rt?new rt(t.lng,t.lat):rt.convert(t),this}extend(t){let r=this._sw,i=this._ne,n,a;if(t instanceof rt)n=t,a=t;else if(t instanceof wo){if(n=t._sw,a=t._ne,!n||!a)return this}else{if(Array.isArray(t))if(t.length===4||t.every(Array.isArray)){let s=t;return this.extend(wo.convert(s))}else{let s=t;return this.extend(rt.convert(s))}return t&&("lng"in t||"lon"in t)&&"lat"in t?this.extend(rt.convert(t)):this}return!r&&!i?(this._sw=new rt(n.lng,n.lat),this._ne=new rt(a.lng,a.lat)):(r.lng=Math.min(n.lng,r.lng),r.lat=Math.min(n.lat,r.lat),i.lng=Math.max(a.lng,i.lng),i.lat=Math.max(a.lat,i.lat)),this}getCenter(){return new rt((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 rt(this.getWest(),this.getNorth())}
vendor: 1,835 bytes, line 744
744getSouthEast(){return new rt(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(t){let{lng:r,lat:i}=rt.convert(t),n=this._sw.lat<=i&&i<=this._ne.lat,a=this._sw.lng<=r&&r<=this._ne.lng;return this._sw.lng>this._ne.lng&&(a=this._sw.lng>=r&&r>=this._ne.lng),n&&a}intersects(t){if(t=wo.convert(t),!(t.getNorth()>=this.getSouth()&&t.getSouth()<=this.getNorth()))return!1;let r=Math.abs(this.getEast()-this.getWest()),i=Math.abs(t.getEast()-t.getWest());if(r>=360||i>=360)return!0;let n=ys(this.getWest(),-180,180),a=ys(this.getEast(),-180,180),s=ys(t.getWest(),-180,180),o=ys(t.getEast(),-180,180),l=n>a,u=s>o;return l&&u?!0:l?o>=n||s<=a:u?a>=s||n<=o:s<=a&&o>=n}static convert(t){return t instanceof wo||!t?t:new wo(t)}static fromLngLat(t,r=0){let i=360*r/40075017,n=i/Math.cos(Math.PI/180*t.lat);return new wo(new rt(t.lng-n,t.lat-i),new rt(t.lng+n,t.lat+i))}adjustAntiMeridian(){let t=new rt(this._sw.lng,this._sw.lat),r=new rt(this._ne.lng,this._ne.lat);return t.lng>r.lng?new wo(t,new rt(r.lng+360,r.lat)):new wo(t,r)}},PF=class{constructor(e,t,r){this.bounds=co.convert(this.validateBounds(e)),this.minzoom=t||0,this.maxzoom=r||24}validateBounds(e){return!Array.isArray(e)||e.length!==4?[-180,-90,180,90]:[Math.max(-180,e[0]),Math.max(-90,e[1]),Math.min(180,e[2]),Math.min(90,e[3])]}contains(e){let t=2**e.z,r={minX:Math.floor(Fh(this.bounds.getWest())*t),minY:Math.floor(zh(this.bounds.getNorth())*t),maxX:Math.ceil(Fh(this.bounds.getEast())*t),maxY:Math.ceil(zh(this.bounds.getSouth())*t)};return e.x>=r.minX&&e.x<r.maxX&&e.y>=r.minY&&e.y<r.maxY}}
744,dMe=class extends Rn{constructor(e,t,r,i){if(super(),this.id=e,this.dispatcher=r,this.type="vector",this.minzoom=0,this.maxzoom=22,this.scheme="xyz",this.tileSize=512,this.reparseOverscaled=!0,this.isTileClipped=!0,this._loaded=!1,Ne(this,og(t,["url","scheme","tileSize","promoteId","encoding"])),this._options=Ne({type:"vector"},t),this._collectResourceTiming=t.collectResourceTiming,this.tileSize!==512)throw Error("vector tile sources must have a tileSize of 512");this.setEventedParent(i)}async load(e=!1){this._loaded=!1,this.fire(new yr("dataloading")),this._tileJSONRequest=new AbortController;try{let t=await EF(this._options,this.map._requestManager,this._tileJSONRequest,this.map._ownerWindow);this._tileJSONRequest=null,this._loaded=!0,t&&(Ne(this,t),t.bounds&&(this.tileBounds=new PF(t.bounds,this.minzoom,this.maxzoom)),this.fire(new yr("data",{sourceDataType:"metadata"})),this.fire(new yr("data",{sourceDataType:"content",sourceDataChanged:e})))}catch(t){this._tileJSONRequest=null,this._loaded=!0,uu(t)||this.fire(new He(mn(t)))}}loaded(){return this._loaded}hasTile(e){return!this.tileBounds||this.tileBounds.contains(e.canonical)}onAdd(e){this.map=e,this.load()}setSourceProperty(e){this._tileJSONRequest&&this._tileJSONRequest.abort(),e(),this.load(!0)}setTiles(e){return this.setSourceProperty(()=>{this._options.tiles=e}),this}setUrl(e){return this.setSourceProperty(()=>{this.url=e,this._options.url=e}),this}onRemove(){this._tileJSONRequest&&(this._tileJSONRequest=(this._tileJSONRequest.abort(),null))}serialize(){return Ne({},this._options)}async loadTile(e){let t=e.tileID.canonical.url(this.tiles,this.map.getPixelRatio(),this.scheme),r={request:await this.map._requestManager.transformRequest(t,"Tile"),uid:e.uid,tileID:e.tileID,zoom:e.tileID.overscaledZ,tileSize:this.tileSize*e.tileID.overscaleFactor(),type:this.t
744ype,source:this.id,pixelRatio:this.map.getPixelRatio(),showCollisionBoxes:this.map.showCollisionBoxes,promoteId:this.promoteId,subdivisionGranularity:this.map.style.projection.subdivisionGranularity,encoding:this.encoding,overzoomParameters:await this._getOverzoomParameters(e),etag:e.etag};r.request.collectResourceTiming=this._collectResourceTiming,await this.dispatcher.waitForInitComplete();let i="RT";if(!e.actor||e.state==="expired")e.actor=this.dispatcher.getReadyActor(),i="LT";else if(e.state==="loading")return new Promise((n,a)=>{e.reloadPromise={resolve:n,reject:a}});e.abortController=new AbortController;try{let n=await e.actor.sendAsync({type:i,data:r},e.abortController);if(delete e.abortController,e.aborted)return;this._afterTileLoadWorkerResponse(e,n);let a={};return n!=null&&n.etagUnmodified&&(a.unmodified=!0),a}catch(n){if(delete e.abortController,e.aborted||uu(n))return;if(n&&n.status!==404)throw n;this._afterTileLoadWorkerResponse(e,null)}}async _getOverzoomParameters(e){if(e.tileID.canonical.z<=this.maxzoom||this.map._zoomLevelsToOverscale===void 0)return;let t=e.tileID.scaledTo(this.maxzoom).canonical,r=t.url(this.tiles,this.map.getPixelRatio(),this.scheme);return{maxZoomTileID:t,overzoomRequest:await this.map._requestManager.transformRequest(r,"Tile")}}_afterTileLoadWorkerResponse(e,t){if(t!=null&&t.resourceTiming&&(e.resourceTiming=t.resourceTiming),t&&this.map._refreshExpiredTiles&&e.setExpiryData(t),e.etag=t==null?void 0:t.etag,e.loadVectorData(t,this.map.painter),e.reloadPromise){let r=e.reloadPromise;e.reloadPromise=null,this.loadTile(e).then(r.resolve).catch(r.reject)}}async abortTile(e){e.abortController&&(e.abortController.abort(),delete e.abortController),e.actor&&await e.actor.sendAsync({type:"AT",data:{uid:e.uid,type:this.t
744ype,source:this.id}})}async unloadTile(e){e.unloadVectorData(),e.actor&&await e.actor.sendAsync({type:"RMT",data:{uid:e.uid,type:this.type,source:this.id}})}hasTransition(){return!1}},MF=class extends Rn{constructor(e,t,r,i){super(),this.id=e,this.dispatcher=r,this.setEventedParent(i),this.type="raster",this.minzoom=0,this.maxzoom=22,this.roundZoom=!0,this.scheme="xyz",this.tileSize=512,this._loaded=!1,this._premultiplyAlpha=!0,this._options=Ne({type:"raster"},t),Ne(this,og(t,["url","scheme","tileSize"]))}async load(e=!1){this._loaded=!1,this.fire(new yr("dataloading")),this._tileJSONRequest=new AbortController;try{let t=await EF(this._options,this.map._requestManager,this._tileJSONRequest,this.map._ownerWindow);this._tileJSONRequest=null,this._loaded=!0,t&&(Ne(this,t),t.bounds&&(this.tileBounds=new PF(t.bounds,this.minzoom,this.maxzoom)),this.fire(new yr("data",{sourceDataType:"metadata"})),this.fire(new yr("data",{sourceDataType:"content",sourceDataChanged:e})))}catch(t){this._tileJSONRequest=null,this._loaded=!0,uu(t)||this.fire(new He(mn(t)))}}loaded(){return this._loaded}onAdd(e){this.map=e,this.load()}onRemove(){this._tileJSONRequest&&(this._tileJSONRequest=(this._tileJSONRequest.abort(),null))}setSourceProperty(e){this._tileJSONRequest&&(this._tileJSONRequest=(this._tileJSONRequest.abort(),null)),e(),this.load(!0)}setTiles(e){return this.setSourceProperty(()=>{this._options.tiles=e}),this}setUrl(e){return this.setSourceProperty(()=>{this.url=e,this._options.url=e}),this}serialize(){return Ne({},this._options)}setPremultiplyAlpha(e){return this._premultiplyAlpha===e||this.setSourceProperty(()=>{this._premultiplyAlpha=e}),this}hasTile(e){return!this.tileBounds||this.tileBounds.contains(e.canonical)}async loadTile(e){let t=e.tileID.canonical.url(this.tiles,this.map.getPixelRatio(),this.scheme),r=this._premultiplyAlpha,i=r?void 0:{premultiplyAlpha:"none"},n=await this.map._requestManager.transformRequest(t,"Tile");e.abortController=new AbortController;try{let a=await Zo.getImage(n,e.abortController,this.map._refreshExpiredTiles,i);if(delete e.abortController,e.aborted){e.state="unloaded";return}if(a!=null&&a.data){this.map._refreshExpiredTiles&&(a.cacheControl||a.expires)&&e.setExpiryData({cacheControl:a.cacheControl,expires:a.expires});let s=this.map.painter.context,o=s.gl,l=a.data;e.texture=this.map.painter.getTileTexture(l.width),e.texture?e.texture.update(l,{useMipmap:!0,premultiply:r}):(e.texture=new Hr(s,l,o.RGBA,{useMipmap:!0,premultiply:r}),e.texture.bind(o.LINEAR,o.CLAMP_TO_EDGE,o.LINEAR_MIPMAP_NEAREST)),e.state="loaded"}}catch(a){if(delete e.abortController,e.aborted)e.state="unloaded";else if(a)throw e.state="errored",a}}async abortTile(e){e.abortController&&(e.abortController.abort(),delete e.abortController)}async unloadTile(e){e.texture&&this.map.painter.saveTileTexture(e.texture)}hasTransition(){return!1}}
vendor: 4,338 bytes, line 744
744,hMe=class extends MF{constructor(e,t,r,i){super(e,t,r,i),this.type="raster-dem",this.maxzoom=22,this._options=Ne({type:"raster-dem"},t),this.encoding=t.encoding||"mapbox",this.redFactor=t.redFactor,this.greenFactor=t.greenFactor,this.blueFactor=t.blueFactor,this.baseShift=t.baseShift}async loadTile(e){let t=e.tileID.canonical.url(this.tiles,this.map.getPixelRatio(),this.scheme),r=await this.map._requestManager.transformRequest(t,"Tile");e.neighboringTiles=this._getNeighboringTiles(e.tileID),e.abortController=new AbortController;try{let i=await Zo.getImage(r,e.abortController,this.map._refreshExpiredTiles);if(delete e.abortController,e.aborted){e.state="unloaded";return}if(i!=null&&i.data){let n=i.data;this.map._refreshExpiredTiles&&(i.cacheControl||i.expires)&&e.setExpiryData({cacheControl:i.cacheControl,expires:i.expires});let a=uc(n)&&mR()?n:await this.readImageNow(n),s={type:this.type,uid:e.uid,source:this.id,rawImageData:a,encoding:this.encoding,redFactor:this.redFactor,greenFactor:this.greenFactor,blueFactor:this.blueFactor,baseShift:this.baseShift};if(e.actor&&e.state!=="expired"&&e.state!=="reloading")return;await this.dispatcher.waitForInitComplete(),(!e.actor||e.state==="expired")&&(e.actor=this.dispatcher.getReadyActor()),e.dem=await e.actor.sendAsync({type:"LDT",data:s}),e.needsHillshadePrepare=!0,e.needsTerrainPrepare=!0,e.state="loaded"}}catch(i){if(delete e.abortController,e.aborted)e.state="unloaded";else if(i)throw e.state="errored",i}}async readImageNow(e){if(typeof VideoFrame<"u"&&f$e()){let t=e.width+2,r=e.height+2;try{return new _r({width:t,height:r},await iSe(e,-1,-1,t,r))}catch{}}return qn.getImageData(e,1)}_getNeighboringTiles(e){let t=e.canonical,r=2**t.z,i=(t.x-1+r)%r,n=t.x===0?e.wrap-1:e.wrap,a=(t.x+1+r)%r,s=t.x+1===r?e.wrap+1:e.wrap,o={};return o[new Ri(e.overscaledZ,n,t.z,i,t.y).key]={backfilled:!1},o[new Ri(e.overscaledZ,s,t.z,a,t.y).key]={backfilled:!1},t.y>0&&(o[new Ri(e.overscaledZ,n,t.z,i,t.y-1).key]={backfilled:!1},o[new Ri(e.overscaledZ,e.wrap,t.z,t.x,t.y-1).key]={backfilled:!1},o[new Ri(e.overscaledZ,s,t.z,a,t.y-1).key]={backfilled:!1}),t.y+1<r&&(o[new Ri(e.overscaledZ,n,t.z,i,t.y+1).key]={backfilled:!1},o[new Ri(e.overscaledZ,e.wrap,t.z,t.x,t.y+1).key]={backfilled:!1},o[new Ri(e.overscaledZ,s,t.z,a,t.y+1).key]={backfilled:!1}),o}async unloadTile(e){e.demTexture&&this.map.painter.saveTileTexture(e.demTexture),e.fbo&&(e.fbo.destroy(),delete e.fbo),e.dem&&delete e.dem,delete e.neighboringTiles,e.state="unloaded",e.actor&&await e.actor.sendAsync({type:"RDT",data:{type:this.type,uid:e.uid,source:this.id}})}};function Kw(e,t){return t?e.properties[t]:e.id}function fMe(e,t){let r=new Map;if(e==null||e.type==null)return r;if(e.type==="Feature"){let i=Kw(e,t);return i==null?void 0:(r.set(i,e),r)}if(e.type==="FeatureCollection"){let i=new Set;for(let n of e.features){let a=Kw(n,t);if(a==null||i.has(a))return;i.add(a),r.set(a,n)}return r}}function pMe(e,t,r){var n,a;let i=[];if(t.removeAll)e.clear();else if(t.remove)for(let s of t.remove){let o=e.get(s);o&&(i.push(o.geometry),e.delete(s))}if(t.add)for(let s of t.add){let o=Kw(s,r);if(o==null)continue;let l=e.get(o);l&&i.push(l.geometry),i.push(s.geometry),e.set(o,s)}if(t.update)for(let s of t.update){let o=e.get(s.id);if(!o)continue;let l=!!s.newGeometry,u=s.removeAllProperties||((n=s.removeProperties)==null?void 0:n.length)>0||((a=s.addOrUpdateProperties)==null?void 0:a.length)>0;if(!l&&!u)continue;i.push(o.geometry);let c={...o};if(e.set(s.id,c),l&&(i.push(s.newGeometry),c.geometry=s.newGeometry),u){if(c.properties=s.removeAllProperties?{}:{...c.properties||{}},s.removeProperties)for(let d of s.removeProperties)delete c.properties[d];if(s.addOrUpdateProperties)for(let{key:d,value:h}of s.addOrUpdateProperties)c.properties[d]=h}}return i}function mMe(e,t,r){if(!e)return t||{};if(!t)return e||{};let i=eE(e),n=eE(t);gMe(i,n);let a={};if((i.removeAll||n.removeAll)&&(a.removeAll=!0),a.remove=new Set([...i.remove,...n.remove]),a.add=new Map([...i.add,...n.add]),a.update=new Map([...i.update,...n.update]),a.remove.size&&a.add.size)for(let o of a.add.keys())a.remove.delete(o);return yMe(a)}function gMe(e,t){t.removeAll&&(e.add.clear(),e.update.clear(),e.remove.clear(),t.remove.clear());for(let r of t.remove)e.add.delete(r),e.update.delete(r);for(let[r,i]of t.update){let n=e.update.get(r);
744n&&(t.update.set(r,_Me(n,i)),e.update.delete(r))}}function _Me(e,t){let r={id:e.id};if(t.removeAllProperties&&(delete e.removeProperties,delete e.addOrUpdateProperties,delete t.removeProperties),t.removeProperties)for(let i of t.removeProperties){let n=e.addOrUpdateProperties.findIndex(a=>a.key===i);n>-1&&e.addOrUpdateProperties.splice(n,1)}return(e.removeAllProperties||t.removeAllProperties)&&(r.removeAllProperties=!0),(e.removeProperties||t.removeProperties)&&(r.removeProperties=[...e.removeProperties||[],...t.removeProperties||[]]),(e.addOrUpdateProperties||t.addOrUpdateProperties)&&(r.addOrUpdateProperties=[...e.addOrUpdateProperties||[],...t.addOrUpdateProperties||[]]),(e.newGeometry||t.newGeometry)&&(r.newGeometry=t.newGeometry||e.newGeometry),r}function eE(e){var r,i;if(!e)return{};let t={};return t.removeAll=e.removeAll,t.remove=new Set(e.remove||[]),t.add=new Map((r=e.add)==null?void 0:r.map(n=>[n.id,n])),t.update=new Map((i=e.update)==null?void 0:i.map(n=>[n.id,n])),t}function yMe(e){let t={};return e.removeAll&&(t.removeAll=e.removeAll),e.remove&&(t.remove=Array.from(e.remove)),e.add&&(t.add=Array.from(e.add.values())),e.update&&(t.update=Array.from(e.update.values())
vendor: 7,556 bytes, line 744
744),t}function IF(e){return!e||e.length===0?[]:typeof e[0]=="number"?[e]:e.flatMap(t=>IF(t))}function b_(e){return e.type==="GeometryCollection"?e.geometries.flatMap(t=>b_(t)):IF(e.coordinates)}function tE(e){let t=new co,r;switch(e.type){case"FeatureCollection":r=e.features.flatMap(i=>b_(i.geometry));break;case"Feature":r=b_(e.geometry);break;default:r=b_(e)}if(r.length===0)return t;for(let i of r){let[n,a]=i;t.extend([n,a])}return t}function vMe({x:e,y:t,z:r},i=0){let n=zw((e-i)/2**r),a=zm((t+1+i)/2**r),s=zw((e+1+i)/2**r),o=zm((t-i)/2**r);return new co([n,a],[s,o])}var bMe=class extends Rn{constructor(e,t,r,i){super(),this.id=e,this.type="geojson",this.minzoom=0,this.maxzoom=18,this.tileSize=512,this.isTileClipped=!0,this.reparseOverscaled=!0,this._removed=!1,this._isUpdatingWorker=!1,this._pendingWorkerUpdate={data:t.data},this.actorPromise=r.getActor(),this.setEventedParent(i),this._data=typeof t.data=="string"?{url:t.data}:{geojson:t.data},this._options=Ne({},t),this._collectResourceTiming=t.collectResourceTiming,t.maxzoom!==void 0&&(this.maxzoom=t.maxzoom),t.type&&(this.type=t.type),t.attribution&&(this.attribution=t.attribution),this.promoteId=t.promoteId,t.clusterMaxZoom!==void 0&&this.maxzoom<=t.clusterMaxZoom&&vr(`The maxzoom value "${this.maxzoom}" is expected to be greater than the clusterMaxZoom value "${t.clusterMaxZoom}".`),this.workerOptions=Ne({source:this.id,geojsonVtOptions:{buffer:this._pixelsToTileUnits(t.buffer===void 0?128:t.buffer),tolerance:this._pixelsToTileUnits(t.tolerance===void 0?.375:t.tolerance),extent:ye,maxZoom:this.maxzoom,lineMetrics:t.lineMetrics||!1,generateId:t.generateId||!1,promoteId:typeof t.promoteId=="string"?t.promoteId:void 0,cluster:t.cluster||!1,clusterOptions:{maxZoom:this._getClusterMaxZoom(t.clusterMaxZoom),minPoints:Math.max(2,t.clusterMinPoints||2),extent:ye,radius:this._pixelsToTileUnits(t.clusterRadius||50),log:!1,generateId:t.generateId||!1}},clusterProperties:t.clusterProperties,filter:t.filter},t.workerOptions)}_hasPendingWorkerUpdate(){return this._pendingWorkerUpdate.data!==void 0||this._pendingWorkerUpdate.diff!==void 0||this._pendingWorkerUpdate.updateCluster}_pixelsToTileUnits(e){return e*(ye/this.tileSize)}_tileUnitsToPixels(e){return e/(ye/this.tileSize)}_getClusterMaxZoom(e){let t=e?Math.round(e):this.maxzoom-1;return Number.isInteger(e)||e===void 0||vr(`Integer expected for option 'clusterMaxZoom': provided value "${e}" rounded to "${t}"`),t}async load(){await this._updateWorkerData()}onAdd(e){this.map=e,this.load()}setData(e){return this._data=typeof e=="string"?{url:e}:{geojson:e},this._pendingWorkerUpdate={data:e},this._updateWorkerData()}updateData(e){return this._pendingWorkerUpdate.diff=mMe(this._pendingWorkerUpdate.diff,e),this._updateWorkerData()}async getData(){return this._data.url&&await this.once("data"),this._data.geojson?this._data.geojson:{type:"FeatureCollection",features:Array.from(this._data.updateable.values())}}async getBounds(){return tE(await this.getData())}setClusterOptions(e){return this.workerOptions.geojsonVtOptions.cluster=e.cluster,e.clusterRadius!==void 0&&(this.workerOptions.geojsonVtOptions.clusterOptions.radius=this._pixelsToTileUnits(e.clusterRadius)),e.clusterMaxZoom!==void 0&&(this.workerOptions.geojsonVtOptions.clusterOptions.maxZoom=this._getClusterMaxZoom(e.clusterMaxZoom)),this._pendingWorkerUpdate.updateCluster=!0,this._updateWorkerData()}getClusterOptions(){let{cluster:e,clusterOptions:t}=this.workerOptions.geojsonVtOptions;return{cluster:e,clusterMaxZoom:t.maxZoom,clusterRadius:this._tileUnitsToPixels(t.radius)}}async getClusterExpansionZoom(e){return(await this.actorPromise).sendAsync({type:"GCEZ",data:{type:this.type,clusterId:e,source:this.id}})}async getClusterChildren(e){return(await this.actorPromise).sendAsync({type:"GCC",data:{type:this.type,clusterId:e,source:this.id}})}async getClusterLeaves(e,t,r){return(await this.actorPromise).sendAsync({type:"GCL",data:{type:this.type,source:this.id,clusterId:e,limit:t,offset:r}})}async _updateWorkerData(){if(this._isUpdatingWorker)return this._updatePromise;if(!this._hasPendingWorkerUpdate()){vr(`No pending worker updates for GeoJSONSource ${this.id}.`);return}let{data:e,diff:t,updateCluster:r}=this._pendingWorkerUpdate,i=this._getLoadGeoJSONParameters(e,t,r);e===void 0?t?this._pendingWorkerUpdate.diff=void 0:r&&(this._pendingWorkerUpdate.updateCluster=void 0):this._pendingWorkerUpdate.data=void 0,this._updatePromise=this._dispatchWorkerUpdate(i),await this._updatePromise}async _getLoadGeoJSONParameters(e,t,r){let i=Ne({type:this.type,source:this.id},this.workerOptions);if(typeof e=="string")return i.request=await this.map._requestManager.transformRequest(qn.resolveURL(e),"Source"),i.request.collectResourceTiming=this._collectResourceTiming,i;if(e!==void 0)return i.data=e,i;if(t)return i.dataDiff=t,i;if(r)return i.updateCluster=!0,i}async _dispatchWorkerUpdate(e){this._isUpdatingWorker=!0,this.fire(new yr("dataloading"));try{let t=await e,r=await(await this.actorPromise).sendAsync({type:"LD",data:t});if(this._isUpdatingWorker=!1,this._removed||r.abandoned){this.fire(new yr("dataabort"));return}r.data&&(this._data={geojson:r.data});let i=this._applyDiffToSource(t.dataDiff),n=this._getShouldReloadTileOptions(i),a={};this._applyResourceTiming(a,r),this.fire(new yr("data",{...a,sourceDataType:"metadata"})),this.fire(new yr("data",{...a,sourceDataType:"content",shouldReloadTileOptions:n}))}catch(t){if(this._isUpdatingWorker=!1,this._removed){this.fire(new yr("dataabort"));return}this.fire(new He(mn(t)))}finally{this._hasPendingWorkerUpdate()&&await this._updateWorkerData()}}_applyResourceTiming(e,t){var n;if(!this._collectResourceTiming)return;let r=(n=t.resourceTiming)==null?void 0:n[this.id];if(!r)return;let i=r.slice(0);i!=null&&i.length&&Ne(e,{resourceTiming:i})}_applyDiffToSource(e){if(!e)return;let t=typeof this.promoteId=="string"?this.promoteId:void 0;if(!this._data.url&&!this._data.updateable){let i=fMe(this._data.geojson,t);if(!i)throw Error(`GeoJSONSource "${this.id}": GeoJSON data is not compatible with updateData`);this._data={updateable:i}}if(!this._data.updateable)return;let r=pMe(this._data.updateable,e,t);if(!(e.removeAll||this._options.cluster))return r}_getShouldReloadTileOptions(e){if(e)return{affectedBounds:e.filter(Boolean).map(t=>tE(t))}}shouldReloadTile(e,{affectedBounds:t}){if(e.state==="loading")return!0;if(e.state==="unloaded")return!1;let{buffer:r,extent:i}=this.workerOptions.geojsonVtOptions,n=vMe(e.tileID.canonical,r/i);for(let a of t)if(n.intersects(a))return!0;return!1}loaded(){return!this._isUpdatingWorker&&!this._hasPendingWorkerUpdate()}async loadTile(e){let t=e.actor?"RT":"LT";e.actor=await this.actorPromise;let r={type:this.type,uid:e.uid,tileID:e.tileID,zoom:e.tileID.overscaledZ,maxZoom:this.maxzoom,tileSize:this.tileSize,source:this.id,pixelRatio:this.map.getPixelRatio(),showCollisionBoxes:this.map.showCollisionBoxes,promoteId:this.promoteId,subdivisionGranularity:this.map.style.projection.subdivisionGranularity};e.abortController=new AbortController;try{let i=await(await this.actorPromise).sendAsync({type:t,data:r},e.abortController);delete e.abortController,e.unloadVectorData(),e.aborted||e.loadVectorData(i,this.map.painter,t==="RT")}catch(i){if(delete e.abortController,e.aborted||uu(i))return;throw i}}async abortTile(e){e.abortController&&(e.abortController.abort(),delete e.abortController),e.aborted=!0}async unloadTile(e){e.unloadVectorData(),await(await this.actorPromise).sendAsync({type:"RMT",data:{uid:e.uid,type:this.t
744ype,source:this.id}})}onRemove(){this._removed=!0,this.actorPromise.then(e=>e.sendAsync({type:"RS",data:{type:this.type,source:this.id}}))}serialize(){return Ne({},this._options,{type:this.type,data:this._data.updateable?{type:"FeatureCollection",features:Array.from(this._data.updateable.values())}:this._data.url||this._data.geojson})}hasTransition(){return!1}},xg=class extends Rn{constructor(e,t,r,i){super(),this.flippedWindingOrder=!1,this.id=e,this.dispatcher=r,this.coordinates=t.coordinates,this.type="image",this.minzoom=0,this.maxzoom=22,this.tileSize=512,this.tiles={},this._loaded=!1,this.setEventedParent(i),this.options=t}async load(e){this._loaded=!1,this.fire(new yr("dataloading")),this.url=this.options.url;let t=await this.map._requestManager.transformRequest(this.url,"Image");this._request=new AbortController;try{let r=await Zo.getImage(t,this._request);this._request=null,this._loaded=!0,r!=null&&r.data&&(this.image=r.data,e&&(this.coordinates=e),this._finishLoading())}catch(r){this._request=null,this._loaded=!0,uu(r)||this.fire(new He(mn(r)))}}loaded(){return this._loaded}updateImage(e){return this._request&&(this._request=(this._request.abort(),null)),"image"in e?(this._loaded=!0,this.image=e.image,e.coordinates&&(this.coordinates=e.coordinates),this.texture=null,this._finishLoading(),this):e.url?(this.options.url=e.url,this.load(e.coordinates).finally(()=>this.texture=null),this):this}_finishLoading(){this.map&&(this.setCoordinates(this.coordinates),this.fire(new yr("data",{sourceDataType:"metadata"})))}onAdd(e){this.map=e,this.load()}onRemove(){this._request&&(this._request=(this._request.abort(),null))}setCoordinates(e){this.coordinates=e;let t=e.map(nr.fromLngLat);return this.tileID=xMe(t),this.terrainTileRanges=this._getOverlappingTileRanges(t),this.minzoom=this.maxzoom=this.tileID.z,this.tileCoords=t.map(r=>
744this.tileID.getTilePoint(r)._round()),this.flippedWindingOrder=wMe(this.tileCoords),this.fire(new yr("data",{sourceDataType:"content"})),this}prepare(){if(Object.keys(this.tiles).length===0||!this.image)return;let e=this.map.painter.context,t=e.gl;this.texture||(this.texture=new Hr(e,this.image,t.RGBA),this.texture.bind(t.LINEAR,t.CLAMP_TO_EDGE));let r=!1;for(let i in this.tiles){let n=this.tiles[i];n.state!=="loaded"&&(n.state="loaded",n.texture=this.texture,r=!0)}r&&this.fire(new yr("data",{sourceDataType:"idle",sourceId:this.id}))}async loadTile(e){var t;(t=this.tileID)!=null&&t.equals(e.tileID.canonical)?(this.tiles[String(e.tileID.wrap)]=e,e.buckets={}):e.state="errored"}serialize(){return{type:"image",url:this.options.url,coordinates:this.coordinates}}hasTransition(){return!1}_getOverlappingTileRanges(e){let{minX:t,minY:r,maxX:i,maxY:n}=no.fromPoints(e),a={};for(let s=0;s<=25;s++){let o=2**s,l=Math.floor(t*o),u=Math.floor(r*o),c=Math.floor(i*o),d=Math.floor(n*o),h=(l%o+o)%o,f=c%o,p=Math.floor(l/o),m=Math.floor(c/o);a[s]={minWrap:p,maxWrap:m,minTileXWrapped:h,maxTileXWrapped:f,minTileY:u,maxTileY:d}}return a}};function xMe(e){let t=no.fromPoints(e),r=t.width(),i=t.height(),n=Math.max(0,Math.floor(-Math.log(Math.max(r,i))/Math.LN2)),a=2**n;return new pv(n,Math.floor((t.minX+t.maxX)/2*a),Math.floor((t.minY+t.maxY)/2*a))}function wMe(e){let t=e[1].x-e[0].x,r=e[1].y-e[0].y,i=e[2].x-e[0].x;return t*(e[2].y-e[0].y)-r*i<0}
vendor: 1,859 bytes, line 744
744var $Me=class extends xg{constructor(e,t,r,i){super(e,t,r,i),this._onPlayingHandler=()=>{var n;(n=this.map)==null||n.triggerRepaint()},this.roundZoom=!0,this.type="video",this.options=t}async load(){this._loaded=!1;let e=this.options;this.urls=[];for(let t of e.urls)this.urls.push((await this.map._requestManager.transformRequest(t,"Source")).url);try{let t=await fSe(this.urls);if(this._loaded=!0,!t)return;this.video=t,this.video.loop=!0,this.video.addEventListener("playing",this._onPlayingHandler),this.map&&this.video.play(),this._finishLoading()}catch(t){this.fire(new He(mn(t)))}}pause(){this.video&&this.video.pause()}play(){this.video&&this.video.play()}seek(e){if(this.video){let t=this.video.seekable;e<t.start(0)||e>t.end(0)?this.fire(new He(new Te(`sources.${this.id}`,null,`Playback for this video can be set only between the ${t.start(0)} and ${t.end(0)}-second mark.`))):this.video.currentTime=e}}getVideo(){return this.video}onAdd(e){this.map||(this.map=e,this.load(),this.video&&(this.video.play(),this.setCoordinates(this.coordinates)))}onRemove(){super.onRemove(),this.video&&(this.video.removeEventListener("playing",this._onPlayingHandler),this.video.pause())}prepare(){if(Object.keys(this.tiles).length===0||this.video.readyState<2)return;let e=this.map.painter.context,t=e.gl;this.texture?this.video.paused||(this.texture.bind(t.LINEAR,t.CLAMP_TO_EDGE),t.texSubImage2D(t.TEXTURE_2D,0,0,0,t.RGBA,t.UNSIGNED_BYTE,this.video)):(this.texture=new Hr(e,this.video,t.RGBA),this.texture.bind(t.LINEAR,t.CLAMP_TO_EDGE));let r=!1;for(let i in this.tiles){let n=this.tiles[i];n.state!=="loaded"&&(n.state="loaded",n.texture=this.texture,r=!0)}r&&this.fire(new yr("data",{sourceDataType:"idle",sourceId:this.id}))}serialize(){return{type:"video",urls:this.urls,coordinates:this.coordinates}}hasTransition(){return this.video&&!this.video.paused}}
vendor: 13,331 bytes, line 744
744,SMe=class extends xg{constructor(e,t,r,i){super(e,t,r,i),t.coordinates?(!Array.isArray(t.coordinates)||t.coordinates.length!==4||t.coordinates.some(n=>!Array.isArray(n)||n.length!==2||n.some(a=>typeof a!="number")))&&this.fire(new He(new Te(`sources.${e}`,null,'"coordinates" property must be an array of 4 longitude/latitude array pairs'))):this.fire(new He(new Te(`sources.${e}`,null,'missing required property "coordinates"'))),t.animate&&typeof t.animate!="boolean"&&this.fire(new He(new Te(`sources.${e}`,null,'optional "animate" property must be a boolean value'))),t.canvas?typeof t.canvas!="string"&&!(t.canvas instanceof HTMLCanvasElement)&&this.fire(new He(new Te(`sources.${e}`,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 He(new Te(`sources.${e}`,null,'missing required property "canvas"'))),this.options=t,this.animate=t.animate===void 0||t.animate}async load(){if(this._loaded=!0,this.canvas||(this.canvas=this.options.canvas instanceof HTMLCanvasElement?this.options.canvas:document.getElementById(this.options.canvas)),this.width=this.canvas.width,this.height=this.canvas.height,this._hasInvalidDimensions()){this.fire(new He(Error("Canvas dimensions cannot be less than or equal to zero.")));return}this.play=function(){this._playing=!0,this.map.triggerRepaint()},this.pause=function(){this._playing&&(this._playing=(this.prepare(),!1))},this._finishLoading()}getCanvas(){return this.canvas}onAdd(e){this.map=e,this.load(),this.canvas&&this.animate&&this.play()}onRemove(){this.pause()}prepare(){let e=!1;if(this.canvas.width!==this.width&&(this.width=this.canvas.width,e=!0),this.canvas.height!==this.height&&(this.height=this.canvas.height,e=!0),this._hasInvalidDimensions()||Object.keys(this.tiles).length===0)return;let t=this.map.painter.context,r=t.gl;this.texture?(e||this._playing)&&this.texture.update(this.canvas,{premultiply:!0}):(this.texture=new Hr(t,this.canvas,r.RGBA,{premultiply:!0}),this.texture.bind(r.LINEAR,r.CLAMP_TO_EDGE));let i=!1;for(let n in this.tiles){let a=this.tiles[n];a.state!=="loaded"&&(a.state="loaded",a.texture=this.texture,i=!0)}i&&this.fire(new yr("data",{sourceDataType:"idle",sourceId:this.id}))}serialize(){return{type:"canvas",animate:this.animate,canvas:this.options.canvas,coordinates:this.coordinates}}hasTransition(){return this._playing}_hasInvalidDimensions(){for(let e of[this.canvas.width,this.canvas.height])if(isNaN(e)||e<=0)return!0;return!1}};const TMe={},CMe=(e,t,r,i)=>{let n=new(kMe(t.type))(e,t,r,i);if(n.id!==e)throw Error(`Expected Source id to be ${e} instead of ${n.id}`);return n},kMe=e=>{switch(e){case"geojson":return bMe;case"image":return xg;case"raster":return MF;case"raster-dem":return hMe;case"vector":return dMe;case"video":return $Me;case"canvas":return SMe}return TMe[e]};function EMe(e,t){let r={};if(!t)return r;for(let i of e){let n=i.layerIds.map(a=>t.getLayer(a)).filter(Boolean);if(n.length!==0){i.layers=n,i.stateDependentLayerIds&&(i.stateDependentLayers=i.stateDependentLayerIds.map(a=>n.filter(s=>s.id===a)[0]));for(let a of n)r[a.id]=i}}return r}const Xw="RTLPluginLoaded";var PMe=class extends Rn{constructor(...e){super(...e),this.status="unavailable",this.url=null,this.dispatcher=rMe()}_syncState(e){return this.status=e,this.dispatcher.broadcast("SRPS",{pluginStatus:e,pluginURL:this.url}).catch(t=>{throw this.status="error",t})}getRTLTextPluginStatus(){return this.status}clearRTLTextPlugin(){this.status="unavailable",this.url=null}async setRTLTextPlugin(e,t=!1){if(this.url)throw Error("setRTLTextPlugin cannot be called multiple times.");if(this.url=qn.resolveURL(e),!this.url)throw Error(`requested url ${e} is invalid`);if(this.status==="unavailable")if(t)this.status="deferred",this._syncState(this.status);else return this._requestImport();else if(this.status==="requested")return this._requestImport()}async _requestImport(){await this._syncState("loading"),this.status="loaded",this.fire(new ug(Xw))}lazyLoad(){this.status==="unavailable"?this.status="requested":this.status==="deferred"&&this._requestImport()}};let rE=null;function Jw(){return rE||(rE=new PMe),rE}var AF=class{constructor(e,t){this.timeAdded=0,this.fadeEndTime=0,this.fadeOpacity=1,this.tileID=e,this.uid=wR(),this.uses=0,this.tileSize=t,this.buckets={},this.expirationTime=null,this.queryPadding=0,this.hasSymbolBuckets=!1,this.hasRTLText=!1,this.dependencies={},this.rttObjects=[],this.rttFingerprint={},this.expiredRequestCount=0,this.state="loading",this.featureStateRevision=-1}isRenderable(e){return this.hasData()&&(!this.fadeEndTime||this.fadeOpacity>0)&&(e||!this.holdingForSymbolFade())}setCrossFadeLogic({fadingRole:e,fadingDirection:t,fadingParentID:r,fadeEndTime:i}){this.resetFadeLogic(),this.fadingRole=e,this.fadingDirection=t,this.fadingParentID=r,this.fadeEndTime=i}setSelfFadeLogic(e){this.resetFadeLogic(),this.selfFading=!0,this.fadeEndTime=e}resetFadeLogic(){this.fadingRole=null,this.fadingDirection=null,this.fadingParentID=null,this.selfFading=!1,this.timeAdded=tr(),this.fadeEndTime=0,this.fadeOpacity=1}wasRequested(){return this.state==="errored"||this.state==="loaded"||this.state==="reloading"}clearTextures(e){this.demTexture&&e.saveTileTexture(this.demTexture),this.demTexture=null}getRTT(e){return this.rttObjects[e]}acquireRTT(e,t,r){return this.rttObjects[t]=e.acquireRTT(r)}releaseRTT(e){if(this.rttObjects.length!==0){for(let t of this.rttObjects)t&&e.releaseRTT(t);this.rttObjects.length=0}}loadVectorData(e,t,r){if((e==null?void 0:e.etagUnmodified)===!0){this.state="loaded";return}if(this.hasData()&&this.unloadVectorData(),this.state="loaded",!e){this.collisionBoxArray=new nL;return}e.featureIndex&&(this.latestFeatureIndex=e.featureIndex,e.rawTileData?(this.latestRawTileData=e.rawTileData,this.latestEncoding=e.encoding,this.latestFeatureIndex.rawTileData=e.rawTileData,this.latestFeatureIndex.encoding=e.encoding):this.latestRawTileData&&(this.latestFeatureIndex.rawTileData=this.latestRawTileData,this.latestFeatureIndex.encoding=this.latestEncoding)),this.collisionBoxArray=e.collisionBoxArray,this.buckets=EMe(e.buckets,t==null?void 0:t.style),this.hasSymbolBuckets=!1;for(let i in this.buckets){let n=this.buckets[i];if(n instanceof Jd)if(this.hasSymbolBuckets=!0,r)n.justReloaded=!0;else break}if(this.hasRTLText=!1,this.hasSymbolBuckets)for(let i in this.buckets){let n=this.buckets[i];if(n instanceof Jd&&n.hasRTLText){this.hasRTLText=!0,Jw().lazyLoad();break}}this.queryPadding=0;for(let i in this.buckets){let n=this.buckets[i];this.queryPadding=Math.max(this.queryPadding,t.style.getLayer(i).queryRadius(n))}e.imageAtlas&&(this.imageAtlas=e.imageAtlas),e.glyphAtlasImage&&(this.glyphAtlasImage=e.glyphAtlasImage),this.dashPositions=e.dashPositions}unloadVectorData(){for(let e in this.buckets)this.buckets[e].destroy();this.buckets={},this.imageAtlasTexture&&this.imageAtlasTexture.destroy(),this.glyphAtlasTexture&&this.glyphAtlasTexture.destroy(),this.imageAtlas=null,this.dashPositions=null,this.latestFeatureIndex=null,this.state="unloaded"}getBucket(e){return this.buckets[e.id]}upload(e){for(let r in this.buckets){let i=this.buckets[r];i.uploadPending()&&i.upload(e)}let t=e.gl;this.imageAtlas&&!this.imageAtlas.uploaded&&(this.imageAtlasTexture=new Hr(e,this.imageAtlas.image,t.RGBA),this.imageAtlas.uploaded=!0),this.glyphAtlasImage&&(this.glyphAtlasImage=(this.glyphAtlasTexture=new Hr(e,this.glyphAtlasImage,t.ALPHA),null))}prepare(e){this.imageAtlas&&this.imageAtlas.patchUpdatedImages(e,this.imageAtlasTexture)}queryRenderedFeatures(e,t,r,i,n,a,s,o,l,u,c){var d;return(d=this.latestFeatureIndex)!=null&&d.rawTileData?this.latestFeatureIndex.query({queryGeometry:i,cameraQueryGeometry:n,scale:a,tileSize:this.tileSize,pixelPosMatrix:u,transform:o,params:s,queryPadding:this.queryPadding*l,getElevation:c},e,t,r):{}}querySourceFeatures(e,t){let r=this.latestFeatureIndex;if(!(r!=null&&r.rawTileData))return;let i=r.loadVTLayers(),n=t!=null&&t.sourceLayer?t.sourceLayer:"",a=i._geojsonTileLayer||i[n];if(!a)return;let s=Pm(t==null?void 0:t.filter,`querySourceFeatures[${n}].filter`,t==null?void 0:t.globalState),{z:o,x:l,y:u}=this.tileID.canonical,c={z:o,x:l,y:u};for(let d=0;d<a.length;d++){let h=a.feature(d);if(s.needGeometry){let m=Bc(h,!0);if(!s.filter(new Tr(this.tileID.overscaledZ),m,this.tileID.canonical))continue}else if(!s.filter(new Tr(this.tileID.overscaledZ),h))continue;let f=r.getId(h,n),p=new JL(h,o,l,u,f);p.tile=c,e.push(p)}}hasData(){return this.state==="loaded"||this.state==="reloading"||this.state==="expired"}patternsLoaded(){return this.imageAtlas&&!!Object.keys(this.imageAtlas.patternPositions).length}setExpiryData(e){let t=this.expirationTime;if(e.cacheControl){let r=J$e(e.cacheControl);r["max-age"]&&(this.expirationTime=Date.now()+r["max-age"]*1e3)}else e.expires&&(this.expirationTime=new Date(e.expires).getTime());if(this.expirationTime){let r=Date.now(),i=!1;if(this.expirationTime>r)i=!1;else if(!t)i=!0;else if(this.expirationTime<t)i=!0;else{let n=this.expirationTime-t;n?this.expirationTime=r+Math.max(n,3e4):i=!0}i?(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(),2**31-1)}setFeatureState(e,t,r){var n,a,s;if(!((n=this.latestFeatureIndex)!=null&&n.rawTileData)||Object.keys(e).length===0||this.featureStateRevision===r)return;this.featureStateRevision=r;let i=this.latestFeatureIndex.loadVTLayers();for(let o in this.buckets){if(!t.style.hasLayer(o))continue;let l=this.buckets[o],u=l.layers[0].sourceLayer||"_geojsonTileLayer",c=i[u],d=e[u];if(!c||!d||d.length===0)continue;l.update(d,c,((a=this.imageAtlas)==null?void 0:a.patternPositions)||{},this.dashPositions||{});let h=(s=t==null?void 0:t.style)==null?void 0:s.getLayer(o);h&&(this.queryPadding=Math.max(this.queryPadding,h.queryRadius(l)))}}holdingForSymbolFade(){return this.symbolFadeHoldUntil!==void 0}symbolFadeFinished(){return!this.symbolFadeHoldUntil||this.symbolFadeHoldUntil<tr()}clearSymbolFadeHold(){this.symbolFadeHoldUntil=void 0}setSymbolHoldDuration(e){this.symbolFadeHoldUntil=tr()+e}setDependencies(e,t){let r={};for(let i of t)r[i]=!0;this.dependencies[e]=r}hasDependency(e,t){for(let r of e){let i=this.dependencies[r];if(i){for(let n of t)if(i[n])return!0}}return!1}};function iE(e){let t=[];for(let r in e)t.push({id:r,state:e[r]});return t}var MMe=class{constructor(){this.state={},this.stateChanges={},this.deletedStates={},this.revision=0}updateState(e,t,r){var n,a,s,o,l;let i=String(t);if((n=this.stateChanges)[e]||(n[e]={}),(a=this.stateChanges[e])[i]||(a[i]={}),Ne(this.stateChanges[e][i],r),this.deletedStates[e]===null){this.deletedStates[e]={};for(let u in this.state[e])if(u===i){this.deletedStates[e][i]={};for(let c in this.state[e][u])r[c]===void 0&&(this.deletedStates[e][i][c]=null)}else this.deletedStates[e][u]=null}else if(((s=this.deletedStates[e])==null?void 0:s[i])===null){this.deletedStates[e][i]={};for(let u in this.state[e][i])r[u]===void 0&&(this.deletedStates[e][i][u]=null)}else for(let u in r)((l=(o=this.deletedStates[e])==null?void 0:o[i])==null?void 0:l[u])===null&&delete this.deletedStates[e][i][u]}removeFeatureState(e,t,r){var n,a,s;if(this.deletedStates[e]===null)return;let i=String(t);if((n=this.deletedStates)[e]||(n[e]={}),r&&t!==void 0)this.deletedStates[e][i]!==null&&((a=this.deletedStates[e])[i]||(a[i]={}),this.deletedStates[e][i][r]=null);else if(t!==void 0)if((s=this.stateChanges[e])!=null&&s[i])for(r in this.deletedStates[e][i]={},this.stateChanges[e][i])this.deletedStates[e][i][r]=null;else this.deletedStates[e][i]=null;else this.deletedStates[e]=null}getState(e,t){let r=String(t),i=this.state[e]||{},n=this.stateChanges[e]||{},a=Ne({},i[r],n[r]);if(this.deletedStates[e]===null)return{};if(this.deletedStates[e]){let s=this.deletedStates[e][t];if(s===null)return{};for(let o in s)delete a[o]}return a}initializeTileState(e,t){let r={};for(let i in this.state)r[i]=iE(this.state[i]);e.setFeatureState(r,t,this.revision)}coalesceChanges(e,t){var n,a,s;let r={};for(let o in this.stateChanges){(n=this.state)[o]||(n[o]={}),r[o]||(r[o]={});for(let l in this.stateChanges[o])(a=this.state[o])[l]||(a[l]={}),Ne(this.state[o][l],this.stateChanges[o][l]),r[o][l]=this.state[o][l]}for(let o in this.deletedStates)if((s=this.state)[o]||(s[o]={}),r[o]||(r[o]={}),this.deletedStates[o]===null)for(let l in this.state[o])this.state[o][l]={},r[o][l]={};else for(let l in this.deletedStates[o]){if(this.deletedStates[o][l]===null)this.state[o][l]={};else for(let u of Object.keys(this.deletedStates[o][l]))delete this.state[o][l][u];r[o][l]=this.state[o][l]}if(this.stateChanges={},this.deletedStates={},Object.keys(r).length===0)return;this.revision++;let i={};for(let o in r)i[o]=iE(r[o]);e.setFeatureState(i,t,this.revision)}};function IMe(e,t,r){let i=t.intersectsFrustum(e);if(!r||i===0)return i;let n=t.intersectsPlane(r);return n===0?0:i===2&&n===2?2:1}function nE(e,t,r){let i=0,n=(r-t)/10;for(let a=0;a<10;a++){let s=t+(a+.5)/10*(r-t);i+=n*Math.cos(s)**+e}return i}function Qw(e,t){return function(r,i,n,a,s){let o=2*((e-1)/cn(Math.cos(zr(hc-s))/Math.cos(zr(hc)))-1),l=Math.acos(n/a),u=2*nE(o-1,
vendor: 3,077 bytes, line 744
7440,zr(s/2)),c=Math.min(zr(hc),l+zr(s/2)),d=Math.min(c,l-zr(s/2)),h=nE(o-1,d,c),f=Math.atan(i/n),p=Math.hypot(i,n),m=r;return m+=cn(a/p/Math.max(.5,Math.cos(zr(s/2)))),m+=o*cn(Math.cos(f))/2,m-=cn(Math.max(1,h/u/t))/2,m}}const AMe=Qw(9.314,3);function CS(e,t){let r=(t.roundZoom?Math.round:Math.floor)(e.zoom+cn(e.tileSize/t.tileSize));return Math.max(0,r)}function DMe(e){let t=hc-e.pitch-e.fov/2,r=Ot((15-t)/15,0,1);return e.elevation+r*500}function af(e,t){let r=e.getCameraFrustum(),i=e.getClippingPlane(),n=e.screenPointToMercatorCoordinate(e.getCameraPoint()),a=nr.fromLngLat(e.center,e.elevation);n.z=a.z+Math.cos(e.pitchInRadians)*e.cameraToCenterDistance/e.worldSize;let s=DMe(e),o=e.getCoveringTilesDetailsProvider(),l=o.allowVariableZoom(e,t),u=CS(e,t),c=t.minzoom||0,d=t.maxzoom===void 0?e.maxZoom:t.maxzoom,h=Math.min(Math.max(0,u),d),f=2**h,p=[f*n.x,f*n.y,0],m=[f*a.x,f*a.y,0],g=Math.hypot(a.x-n.x,a.y-n.y),v=Math.abs(a.z-n.z),x=Math.hypot(g,v),_=$=>({zoom:0,x:0,y:0,wrap:$,fullyVisible:!1}),y=[],w=[];if(e.renderWorldCopies&&o.allowWorldCopies())for(let $=1;$<=3;$++)y.push(_(-$)),y.push(_($));for(y.push(_(0));y.length>0;){let $=y.pop(),S=$.x,E=$.y,C=$.fullyVisible,I={x:S,y:E,z:$.zoom},P=o.getTileBoundingVolume(I,$.wrap,s,t);if(!C){let z=IMe(r,P,i);if(z===0)continue;C=z===2}let T=o.distanceToTile2d(n.x,n.y,I,P),D=u;l&&(D=(t.calculateTileZoom||AMe)(e.zoom+cn(e.tileSize/t.tileSize),T,v,x,e.fov)),D=(t.roundZoom?Math.round:Math.floor)(D),D=Math.max(0,D);let A=Math.min(D,d);if($.wrap=o.getWrap(a,I,$.wrap),$.zoom>=A){if($.zoom<c)continue;let z=h-$.zoom,R=p[0]-.5-(S<<z),O=p[1]-.5-(E<<z),V=t.reparseOverscaled?Math.max($.zoom,D):$.zoom;w.push({tileID:new Ri($.zoom===d?V:$.zoom,$.wrap,$.zoom,S,E),distanceSq:U$e([m[0]-.5-S,m[1]-.5-E]),tileDistanceToCamera:Math.sqrt(R*R+O*O)});continue}for(let z=0;z<4;z++){let R=(S<<1)+z%2,O=(E<<1)+(z>>1),V=$.zoom+1;y.push({zoom:V,x:R,y:O,wrap:$.wrap,fullyVisible:C})}}return w.sort(($,S)=>$.distanceSq-S.distanceSq).map($=>$.tileID)}const RMe=no.fromPoints([new de(0,0),new de(ye,ye)]);function aE(e){return e==="raster"||e==="image"||e==="video"}function OMe(e,t,r,i,n,a,s){let o=tr(),l=G$e(t);for(let u of t){let c=e.getTileById(u.key);(c.fadingDirection===0||c.fadeOpacity===0)&&c.resetFadeLogic(),!LMe(e,c,r,o,i,n,s)&&(FMe(e,c,r,o,a,s)||zMe(c,l,o,s)||c.resetFadeLogic())}}function LMe(e,t,r,i,n,a,s){if(!t.hasData())return!1;let{tileID:o,fadingRole:l,fadingDirection:u,fadingParentID:c}=t;if(l===0&&u===1&&c)return r[c.key]=c,!0;let d=Math.max(o.overscaledZ-n,a);for(let h=o.overscaledZ-1;h>=d;h--){let f=o.scaledTo(h),p=e.getLoadedTile(f);if(p)return t.setCrossFadeLogic({fadingRole:0,fadingDirection:1,fadingParentID:p.tileID,fadeEndTime:i+s}),p.setCrossFadeLogic({fadingRole:1,fadingDirection:0,fadeEndTime:i+s}),r[f.key]=f,!0}return!1}function FMe(e,t,r,i,n,a){if(!t.hasData())return!1;let s=t.tileID.children(n),o=sE(e,t,s,r,i,n,a);if(o)return!0;for(let l of s)sE(e,t,l.children(n),r,i,n,a)&&(o=!0);return o}function sE(e,t,r,i,n,a,s){if(r[0].overscaledZ>=a)return!1;let o=!1;for(let l of r){let u=e.getLoadedTile(l);
vendor: 16,603 bytes, line 744
744if(!u)continue;let{fadingRole:c,fadingDirection:d,fadingParentID:h}=u;(c!==0||d!==0||!h)&&(u.setCrossFadeLogic({fadingRole:0,fadingDirection:0,fadingParentID:t.tileID,fadeEndTime:n+s}),t.setCrossFadeLogic({fadingRole:1,fadingDirection:1,fadeEndTime:n+s})),i[l.key]=l,o=!0}return o}function zMe(e,t,r,i){let n=e.tileID;if(e.selfFading)return!0;if(e.hasData())return!1;if(t.has(n)){let a=r+i;return e.setSelfFadeLogic(a),!0}return!1}function NMe(e,t){if(t<=0)return!1;let r=tr();for(let i of e.getAllTiles())if(i.fadeEndTime>=r)return!0;return!1}function BMe(e,t){var i,n,a;let r=t.getRenderableIds();for(let s of r){if(!((i=e.neighboringTiles)!=null&&i[s]))continue;let o=t.getTileById(s);e.neighboringTiles[s].backfilled||oE(e,o),!((a=(n=o.neighboringTiles)==null?void 0:n[e.tileID.key])!=null&&a.backfilled)&&oE(o,e)}}function oE(e,t){var s;e.needsHillshadePrepare=!0,e.needsTerrainPrepare=!0;let r=t.tileID.canonical.x-e.tileID.canonical.x,i=t.tileID.canonical.y-e.tileID.canonical.y,n=2**e.tileID.canonical.z,a=t.tileID.key;(r!==0||i!==0)&&(Math.abs(i)>1||(Math.abs(r)>1&&(Math.abs(r+n)===1?r+=n:Math.abs(r-n)===1&&(r-=n)),!(!t.dem||!e.dem)&&(e.dem.backfillBorder(t.dem,r,i),(s=e.neighboringTiles)!=null&&s[a]&&(e.neighboringTiles[a].backfilled=!0))))}var lE=class{constructor(){this._tiles={}}handleWrapJump(e){let t={};for(let r in this._tiles){let i=this._tiles[r];i.tileID=i.tileID.unwrapTo(i.tileID.wrap+e),t[i.tileID.key]=i}this._tiles=t}setFeatureState(e,t,r){for(let i in this._tiles)this._tiles[i].setFeatureState(e,t,r)}getAllTiles(){return Object.values(this._tiles)}getAllIds(e=!1){return e?Object.values(this._tiles).map(t=>t.tileID).sort(R8).map(t=>t.key):Object.keys(this._tiles)}getTileById(e){return this._tiles[e]}setTile(e,t){this._tiles[e]=t}deleteTileById(e){delete this._tiles[e]}getLoadedTile(e){let t=this.getTileById(e.key);return t!=null&&t.hasData()?t:null}isIdRenderable(e,t=!1){var r;return(r=this.getTileById(e))==null?void 0:r.isRenderable(t)}getRenderableIds(e=0,t){let r=[];for(let i of this.getAllIds())this.isIdRenderable(i,t)&&r.push(this.getTileById(i));return t?r.sort((i,n)=>{let a=i.tileID,s=n.tileID,o=new de(a.canonical.x,a.canonical.y)._rotate(-e),l=new de(s.canonical.x,s.canonical.y)._rotate(-e);return a.overscaledZ-s.overscaledZ||l.y-o.y||l.x-o.x}).map(i=>i.tileID.key):r.map(i=>i.tileID).sort(R8).map(i=>i.key)}},Uo,e3=(Uo=class extends Rn{constructor(t,r,i){super(),this.id=t,this.dispatcher=i,this.on("data",n=>{this._dataHandler(n)}),this.on("dataloading",()=>{this._sourceErrored=!1}),this.on("error",()=>{this._sourceErrored=this._source.loaded()}),this._source=CMe(t,r,i,this),this._inViewTiles=new lE,this._outOfViewCache=new wPe(0,n=>this._unloadTile(n)),this._timers={},this._maxTileCacheSize=null,this._maxTileCacheZoomLevels=null,this._rasterFadeDuration=0,this._maxFadingAncestorLevels=5,this._state=new MMe,this._didEmitContent=!1,this._updated=!1}onAdd(t){var r;this.map=t,this._maxTileCacheSize=t?t._maxTileCacheSize:null,this._maxTileCacheZoomLevels=t?t._maxTileCacheZoomLevels:null,(r=this._source)!=null&&r.onAdd&&this._source.onAdd(t)}onRemove(t){var r;for(let i of this._inViewTiles.getAllTiles())i.unloadVectorData();this.clearTiles(),(r=this._source)!=null&&r.onRemove&&this._source.onRemove(t),this._inViewTiles=new lE}loaded(){if(this._sourceErrored)return!0;if(!this._sourceLoaded||!this._source.loaded())return!1;if((this.used!==void 0||this.usedForTerrain!==void 0)&&!this.used&&!this.usedForTerrain)return!0;if(!this._updated)return!1;for(let t of this._inViewTiles.getAllTiles())if(t.state!=="loaded"&&t.state!=="errored")return!1;return!0}getSource(){return this._source}getState(){return this._state}pause(){this._paused=!0}resume(){if(!this._paused)return;let t=this._shouldReloadOnResume;this._paused=!1,this._shouldReloadOnResume=!1,t&&this.reload(),this.transform&&this.update(this.transform,this.terrain)}async _loadTile(t,r,i){try{let n=await this._source.loadTile(t);this._tileLoaded(t,r,i,n)}catch(n){t.state="errored",n.status===404?this.update(this.transform,this.terrain):this._source.fire(new He(mn(n),{tile:t}))}}_unloadTile(t){this._source.unloadTile&&this._source.unloadTile(t)}_abortTile(t){this._source.abortTile&&this._source.abortTile(t),this._source.fire(new yr("dataabort",{tile:t,coord:t.tileID}))}serialize(){return this._source.serialize()}prepare(t){this._source.prepare&&this._source.prepare(),this._state.coalesceChanges(this._inViewTiles,this.map?this.map.painter:null);for(let r of this._inViewTiles.getAllTiles())r.upload(t),r.prepare(this.map.style.imageManager)}getIds(){return this._inViewTiles.getAllIds(!0)}getRenderableIds(t){var r;return this._inViewTiles.getRenderableIds((r=this.transform)==null?void 0:r.bearingInRadians,t)}hasRenderableParent(t){let r=t.overscaledZ-1;if(r>=this._source.minzoom){let i=this.getLoadedTile(t.scaledTo(r));if(i)return this._inViewTiles.isIdRenderable(i.tileID.key)}return!1}reload(t,r=void 0){if(this._paused){this._shouldReloadOnResume=!0;return}this._outOfViewCache.reset();for(let i of this._inViewTiles.getAllIds()){let n=this._inViewTiles.getTileById(i);r&&!this._source.shouldReloadTile(n,r)||(t?this._reloadTile(i,n.state==="errored"?"loading":"expired"):n.state!=="errored"&&this._reloadTile(i,"reloading"))}}async _reloadTile(t,r){let i=this._inViewTiles.getTileById(t);i&&(i.state!=="loading"&&(i.state=r),await this._loadTile(i,t,r))}_tileLoaded(t,r,i,n){t.timeAdded=tr(),t.selfFading&&(t.fadeEndTime=t.timeAdded+this._rasterFadeDuration),i==="expired"&&(t.refreshedUponExpiration=!0),this._setTileReloadTimer(r,t),!(n!=null&&n.unmodified)&&(this.getSource().type==="raster-dem"&&t.dem&&BMe(t,this._inViewTiles),t.featureStateRevision=-1,this._state.initializeTileState(t,this.map?this.map.painter:null),t.aborted||this._source.fire(new yr("data",{tile:t,coord:t.tileID})))}getTile(t){return this.getTileByID(t.key)}getTileByID(t){return this._inViewTiles.getTileById(t)}_retainLoadedChildren(t,r){let i=this._getLoadedDescendents(r),n=new Set;for(let a of r){let s=i[a.key];if(!(s!=null&&s.length)){n.add(a);continue}let o=a.overscaledZ+Uo.maxOverzooming,l=s.filter(d=>d.tileID.overscaledZ<=o);if(!l.length){n.add(a);continue}let u=Math.min(...l.map(d=>d.tileID.overscaledZ)),c=l.filter(d=>d.tileID.overscaledZ===u).map(d=>d.tileID);for(let d of c)t[d.key]=d;this._areDescendentsComplete(c,u,a.overscaledZ)||n.add(a)}return n}_getLoadedDescendents(t){var i;let r={};for(let n of this._inViewTiles.getAllTiles().filter(a=>a.hasData()))for(let a of t)n.tileID.isChildOf(a)&&(r[i=a.key]||(r[i]=[]),r[a.key].push(n));return r}_areDescendentsComplete(t,r,i){return t.length===1&&t[0].isOverscaled()?t[0].overscaledZ===r:4**(r-i)===t.length}getLoadedTile(t){return this._inViewTiles.getLoadedTile(t)}updateCacheSize(t){let r=(Math.ceil(t.width/this._source.tileSize)+1)*(Math.ceil(t.height/this._source.tileSize)+1),i=this._maxTileCacheZoomLevels===null?cl.MAX_TILE_CACHE_ZOOM_LEVELS:this._maxTileCacheZoomLevels,n=Math.floor(r*i),a=typeof this._maxTileCacheSize=="number"?Math.min(this._maxTileCacheSize,n):n;this._outOfViewCache.setMaxSize(a)}handleWrapJump(t){let r=(t-(this._prevLng===void 0?t:this._prevLng))/360,i=Math.round(r);this._prevLng=t,i&&(this._inViewTiles.handleWrapJump(i),this._resetTileReloadTimers())}update(t,r){if(!this._sourceLoaded||this._paused)return;this.transform=t,this.terrain=r,this.updateCacheSize(t),this.handleWrapJump(this.transform.center.lng);let i;!this.used&&!this.usedForTerrain?i=[]:this._source.tileID?i=t.getVisibleUnwrappedCoordinates(this._source.tileID).map(l=>new Ri(l.canonical.z,l.wrap,l.canonical.z,l.canonical.x,l.canonical.y)):(i=af(t,{tileSize:this.usedForTerrain?this.tileSize:this._source.tileSize,minzoom:this._source.minzoom,maxzoom:this._source.type==="vector"&&this.map._zoomLevelsToOverscale!==void 0?Math.max(this._source.maxzoom,t.maxZoom-this.map._zoomLevelsToOverscale):this._source.maxzoom,roundZoom:!this.usedForTerrain&&this._source.roundZoom,reparseOverscaled:this._source.reparseOverscaled,terrain:r,calculateTileZoom:this._source.calculateTileZoom}),this._source.hasTile&&(i=i.filter(l=>this._source.hasTile(l)))),this.usedForTerrain&&(i=this._addTerrainIdealTiles(i));let n=i.length===0&&!this._updated&&this._didEmitContent;this._updated=!0,n&&this.fire(new yr("data",{sourceDataType:"idle",sourceId:this.id}));let a=CS(t,this._source),s=this._updateRetainedTiles(i,a),o=aE(this._source.type);o&&this._rasterFadeDuration>0&&!r&&OMe(this._inViewTiles,i,s,this._maxFadingAncestorLevels,this._source.minzoom,this._source.maxzoom,this._rasterFadeDuration),o?this._cleanUpRasterTiles(s):this._cleanUpVectorTiles(s)}_cleanUpRasterTiles(t){for(let r of this._inViewTiles.getAllIds())t[r]||this._removeTile(r)}_cleanUpVectorTiles(t){for(let r of this._inViewTiles.getAllIds()){let i=this._inViewTiles.getTileById(r);if(t[r]){i.clearSymbolFadeHold();continue}if(!i.hasSymbolBuckets){this._removeTile(r);continue}i.holdingForSymbolFade()?i.symbolFadeFinished()&&this._removeTile(r):i.setSymbolHoldDuration(this.map._fadeDuration)}}_addTerrainIdealTiles(t){let r=[];for(let i of t)if(i.canonical.z>this._source.minzoom){let n=i.scaledTo(i.canonical.z-1);r.push(n);let a=i.scaledTo(Math.max(this._source.minzoom,Math.min(i.canonical.z,5)));r.push(a)}return t.concat(r)}releaseSymbolFadeTiles(){for(let t of this._inViewTiles.getAllIds())this._inViewTiles.getTileById(t).holdingForSymbolFade()&&this._removeTile(t)}_updateRetainedTiles(t,r){var l;let i=new Set;for(let u of t)this._addTile(u).hasData()||i.add(u);let n=t.reduce((u,c)=>(u[c.key]=c,u),{}),a=this._retainLoadedChildren(n,i),s={},o=Math.max(r-Uo.maxUnderzooming,this._source.minzoom);for(let u of a){let c=this._inViewTiles.getTileById(u.key),d=c==null?void 0:c.wasRequested();for(let h=u.overscaledZ-1;h>=o;--h){let f=u.scaledTo(h);if(s[f.key])break;if(s[f.key]=!0,c=this.getTile(f),!c&&d&&(c=this._addTile(f)),c){let p=c.hasData();if((p||!((l=this.map)!=null&&l.cancelPendingTileRequestsWhileZooming)||d)&&(n[f.key]=f),d=c.wasRequested(),p)break}}}return n}_addTile(t){let r=this._inViewTiles.getTileById(t.key);if(r)return r;r=this._outOfViewCache.getAndRemove(t),r&&(r.resetFadeLogic(),this._setTileReloadTimer(t.key,r),r.tileID=t,this._state.initializeTileState(r,this.map?this.map.painter:null));let i=r;return r||(r=new AF(t,this._source.tileSize*t.overscaleFactor()),this._loadTile(r,t.key,r.state)),r.uses++,this._inViewTiles.setTile(t.key,r),i||this._source.fire(new yr("dataloading",{tile:r,coord:r.tileID})),r}_setTileReloadTimer(t,r){this._clearTileReloadTimer(t);let i=r.getExpiryTimeout();if(i){let n=()=>{this._reloadTile(t,"expired"),delete this._timers[t]};this._timers[t]=setTimeout(n,i)}}_clearTileReloadTimer(t){let r=this._timers[t];r&&(clearTimeout(r),delete this._timers[t])}_resetTileReloadTimers(){for(let t in this._timers)clearTimeout(this._timers[t]),delete this._timers[t];for(let t of this._inViewTiles.getAllIds()){let r=this._inViewTiles.getTileById(t);this._setTileReloadTimer(t,r)}}refreshTiles(t){for(let r of this._inViewTiles.getAllIds()){let i=this._inViewTiles.getTileById(r);!this._inViewTiles.isIdRenderable(r)&&i.state!="errored"||t.some(n=>n.equals(i.tileID.canonical))&&this._reloadTile(r,"expired")}}_removeTile(t){let r=this._inViewTiles.getTileById(t);r&&(r.uses--,this._inViewTiles.deleteTileById(t),this._clearTileReloadTimer(t),!(r.uses>0)&&(r.hasData()&&r.state!=="reloading"?this._outOfViewCache.add(r.tileID,r,r.getExpiryTimeout()):(r.aborted=!0,this._abortTile(r),this._unloadTile(r))))}_dataHandler(t){if(t.dataType==="source"){if(t.sourceDataType==="metadata"){this._sourceLoaded=!0;return}t.sourceDataType!=="content"||!this._sourceLoaded||this._paused||(this.reload(t.sourceDataChanged,t.shouldReloadTileOptions),this.transform&&this.update(this.transform,this.terrain),this._didEmitContent=!0)}}clearTiles(){this._shouldReloadOnResume=!1,this._paused=!1;for(let t of this._inViewTiles.getAllIds())this._removeTile(t);this._outOfViewCache.reset()}tilesIn(t,r,i){let n=[],a=this.transform;if(!a)return n;let s=a.getCoveringTilesDetailsProvider().allowWorldCopies(),o=i?a.getCameraQueryGeometry(t):t,l=f=>a.screenPointToMercatorCoordinate(f,this.terrain),u=this.transformBbox(t,l,!s),c=this.transformBbox(o,l,!s),d=this.getIds(),h=no.fromPoints(c);for(let f of d){let p=this._inViewTiles.getTileById(f);if(p.holdingForSymbolFade())continue;let m=s?[p.tileID]:[p.tileID.unwrapTo(-1),p.tileID.unwrapTo(0)],g=2**(a.zoom-p.tileID.overscaledZ),v=r*p.queryPadding*ye/p.tileSize/g;for(let x of m){let _=h.map(y=>x.getTilePoint(new nr(y.x,y.y)));if(_.expandBy(v),_.intersects(RMe)){let y=u.map($=>x.getTilePoint($)),w=c.map($=>x.getTilePoint($));n.push({tile:p,tileID:s?x:x.unwrapTo(0),queryGeometry:y,cameraQueryGeometry:w,scale:g})}}}return n}transformBbox(t,r,i){let n=t.map(r);if(i){let a=no.fromPoints(t);a.shrinkBy(Math.min(a.width(),a.height())*.001);let s=a.map(r);no.fromPoints(n).covers(s)||(n=n.map(o=>o.x>.5?new nr(o.x-1,o.y,o.z):o))}return n}getVisibleCoordinates(t){let r=this.getRenderableIds(t).map(i=>this._inViewTiles.getTileById(i).tileID);return this.transform&&this.transform.populateCache(r),r}hasTransition(){return this._source.hasTransition()?!0:aE(this._source.type)&&NMe(this._inViewTiles,this._rasterFadeDuration)}setRasterFadeDuration(t){this._rasterFadeDuration=t}setFeatureState(t,r,i){t||(t=__),this._state.updateState(t,r,i)}removeFeatureState(t,r,i){t||(t=__),this._state.removeFeatureState(t,r,i)}getFeatureState(t,r){return t||(t=__),this._state.getState(t,r)}setDependencies(t,r,i){let n=this._inViewTiles.getTileById(t);n&&n.setDependencies(r,i)}reloadTilesForDependencies(t,r){for(let i of this._inViewTiles.getAllIds())this._inViewTiles.getTileById(i).hasDependency(t,r)&&this._reloadTile(i,"reloading");this._outOfViewCache.filter(i=>!i.hasDependency(t,r))}areTilesLoaded(){for(let t of this._inViewTiles.getAllTiles())if(t.state!=="loaded"&&t.state!=="errored")return!1;return!0}},Uo.maxUnderzooming=10,Uo.maxOverzooming=3,Uo),jMe=class{constructor(e,t){this.reset(e,t)}reset(e,t){this.points=e||[],this._distances=[0];for(let r=1;r<this.points.length;r++)this._distances[r]=this._distances[r-1]+this.points[r].dist(this.points[r-1]);this.length=this._distances[this._distances.length-1],this.padding=Math.min(t||0,this.length*.5),this.paddedLength=this.length-this.padding*2}lerp(e){if(this.points.length===1)return this.points[0];e=Ot(e,0,1);let t=1,r=this._distances[t],i=e*this.paddedLength+this.padding;for(;r<i&&t<this._distances.length;)r=this._distances[++t];let n=t-1,a=this._distances[n],s=r-a,o=s>0?(i-a)/s:0;return this.points[n].mult(1-o).add(this.points[t].mult(o))}};function k0(e,t){let r=!0;return e==="always"||(e==="never"||t==="never")&&(r=!1),r}var uE=class{constructor(e,t,r){let i=this.boxCells=[],n=this.circleCells=[];this.xCellCount=Math.ceil(e/r),this.yCellCount=Math.ceil(t/r);for(let a=0;a<this.xCellCount*this.yCellCount;a++)i.push([]),n.push([]);this.circleKeys=[],this.boxKeys=[],this.bboxes=[],this.circles=[],this.width=e,this.height=t,this.xScale=this.xCellCount/e,this.yScale=this.yCellCount/t,this.boxUid=0,this.circleUid=0}keysLength(){return this.boxKeys.length+this.circleKeys.length}insert(e,t,r,i,n){this._forEachCell(t,r,i,n,this._insertBoxCell,this.boxUid++),this.boxKeys.push(e),this.bboxes.push(t),this.bboxes.push(r),this.bboxes.push(i),this.bboxes.push(n)}insertCircle(e,t,r,i){this._forEachCell(t-i,r-i,t+i,r+i,this._insertCircleCell,this.circleUid++),this.circleKeys.push(e),this.circles.push(t),this.circles.push(r),this.circles.push(i)}_insertBoxCell(e,t,r,i,n,a){this.boxCells[n].push(a)}_insertCircleCell(e,t,r,i,n,a){this.circleCells[n].push(a)}_query(e,t,r,i,n,a,s){if(r<0||e>this.width||i<0||t>this.height)return[];let o=[];if(e<=0&&t<=0&&this.width<=r&&this.height<=i){if(n)return[{key:null,x1:e,y1:t,x2:r,y2:i}];for(let l=0;l<this.boxKeys.length;l++)o.push({key:this.boxKeys[l],x1:this.bboxes[l*4],y1:this.bboxes[l*4+1],x2:this.bboxes[l*4+2],y2:this.bboxes[l*4+3]});for(let l=0;l<this.circleKeys.length;l++){let u=this.circles[l*3],c=this.circles[l*3+1],d=this.circles[l*3+2];o.push({key:this.circleKeys[l],x1:u-d,y1:c-d,x2:u+d,y2:c+d})}}else{let l={hitTest:n,overlapMode:a,seenUids:{box:{},circle:{}}};this._forEachCell(e,t,r,i,this._queryCell,o,l,s)}return o}query(e,t,r,i){return this._query(e,t,r,i,!1,null)}hitTest(e,t,r,i,n,a){return this._query(e,t,r,i,!0,n,a).length>0}hitTestCircle(e,t,r,i,n){let a=e-r,s=e+r,o=t-r,l=t+r;if(s<0||a>this.width||l<0||o>this.height)return!1;let u=[],c={hitTest:!0,overlapMode:i,circle:{x:e,y:t,radius:r},seenUids:{box:{},circle:{}}};
vendor: 4,358 bytes, line 744
744return this._forEachCell(a,o,s,l,this._queryCellCircle,u,c,n),u.length>0}_queryCell(e,t,r,i,n,a,s,o){let{seenUids:l,hitTest:u,overlapMode:c}=s,d=this.boxCells[n],h=1e-6;if(d!==null){let p=this.bboxes;for(let m of d)if(!l.box[m]){l.box[m]=!0;let g=m*4,v=this.boxKeys[m];if(e<=p[g+2]+h&&t<=p[g+3]+h&&r>=p[g+0]-h&&i>=p[g+1]-h&&(!o||o(v))&&(!u||!k0(c,v.overlapMode))&&(a.push({key:v,x1:p[g],y1:p[g+1],x2:p[g+2],y2:p[g+3]}),u))return!0}}let f=this.circleCells[n];if(f!==null){let p=this.circles;for(let m of f)if(!l.circle[m]){l.circle[m]=!0;let g=m*3,v=this.circleKeys[m];if(this._circleAndRectCollide(p[g],p[g+1],p[g+2],e,t,r,i)&&(!o||o(v))&&(!u||!k0(c,v.overlapMode))){let x=p[g],_=p[g+1],y=p[g+2];if(a.push({key:v,x1:x-y,y1:_-y,x2:x+y,y2:_+y}),u)return!0}}}return!1}_queryCellCircle(e,t,r,i,n,a,s,o){let{circle:l,seenUids:u,overlapMode:c}=s,d=this.boxCells[n];if(d!==null){let f=this.bboxes;for(let p of d)if(!u.box[p]){u.box[p]=!0;let m=p*4,g=this.boxKeys[p];if(this._circleAndRectCollide(l.x,l.y,l.radius,f[m+0],f[m+1],f[m+2],f[m+3])&&(!o||o(g))&&!k0(c,g.overlapMode))return a.push(!0),!0}}let h=this.circleCells[n];if(h!==null){let f=this.circles;for(let p of h)if(!u.circle[p]){u.circle[p]=!0;let m=p*3,g=this.circleKeys[p];if(this._circlesCollide(f[m],f[m+1],f[m+2],l.x,l.y,l.radius)&&(!o||o(g))&&!k0(c,g.overlapMode))return a.push(!0),!0}}}_forEachCell(e,t,r,i,n,a,s,o){let l=this._convertToXCellCoord(e),u=this._convertToYCellCoord(t),c=this._convertToXCellCoord(r),d=this._convertToYCellCoord(i);for(let h=l;h<=c;h++)for(let f=u;f<=d;f++){let p=this.xCellCount*f+h;if(n.call(this,e,t,r,i,p,a,s,o))return}}_convertToXCellCoord(e){return Math.max(0,Math.min(this.xCellCount-1,Math.floor(e*this.xScale)))}_convertToYCellCoord(e){return Math.max(0,Math.min(this.yCellCount-1,Math.floor(e*this.yScale)))}_circlesCollide(e,t,r,i,n,a){let s=i-e,o=n-t,l=r+a;return l*l>s*s+o*o}_circleAndRectCollide(e,t,r,i,n,a,s){let o=(a-i)/2,l=Math.abs(e-(i+o));if(l>o+r)return!1;let u=(s-n)/2,c=Math.abs(t-(n+u));if(c>u+r)return!1;if(l<=o||c<=u)return!0;let d=l-o,h=c-u;return d*d+h*h<=r*r}};function UMe(e,t){let r=1/(t[0]*t[0]+t[1]*t[1]+t[2]*t[2]),i=1/(t[8]*t[8]+t[9]*t[9]+t[10]*t[10]),n=t[0]*r,a=t[4]*r,s=t[8]*i,o=t[1]*r,l=t[5]*r,u=t[9]*i,c=t[2]*r,d=t[6]*r,h=t[10]*i;e[0]=n,e[1]=a,e[2]=s,e[4]=o,e[5]=l,e[6]=u,e[8]=c,e[9]=d,e[10]=h;let f=t[12],p=t[13],m=t[14];return e[12]=-n*f-o*p-c*m,e[13]=-a*f-l*p-d*m,e[14]=-s*f-u*p-h*m,e[3]=0,e[7]=0,e[11]=0,e[15]=1,e}function VMe(e,t){return e[0]=1/t[0],e[1]=0,e[2]=0,e[3]=0,e[4]=0,e[5]=1/t[5],e[6]=0,e[7]=0,e[8]=0,e[9]=0,e[10]=0,e[11]=1/t[14],e[12]=0,e[13]=0,e[14]=-1,e[15]=t[10]/t[14],e}function qMe(e,t){let r=1/(t[0]*t[5]-t[1]*t[4]);return e[0]=t[5]*r,e[1]=-t[1]*r,e[2]=0,e[3]=0,e[4]=-t[4]*r,e[5]=t[0]*r,e[6]=0,e[7]=0,e[8]=0,e[9]=0,e[10]=1/t[10],e[11]=0,e[12]=0,e[13]=0,e[14]=0,e[15]=1/t[15],e}const GMe=_u();function kS(e,t,r){let i=_u();if(!e){let{vecSouth:n,vecEast:a}=ES(t),s=xF();s[0]=a[0],s[1]=a[1],s[2]=n[0],s[3]=n[1],kPe(s,s),i[0]=s[0],i[1]=s[1],i[4]=s[2],i[5]=s[3]}return Li(i,i,[1/r,1/r,1]),i}function HMe(e,t,r,i){if(e){let n=_u();if(!t){let{vecSouth:a,vecEast:s}=ES(r);n[0]=s[0],n[1]=s[1],n[4]=a[0],n[5]=a[1]}return Li(n,n,[i,i,1]),n}return r.pixelsToClipSpaceMatrix}function ES(e){let t=Math.cos(e.rollInRadians),r=Math.sin(e.rollInRadians),i=Math.cos(e.pitchInRadians),n=Math.cos(e.bearingInRadians),a=Math.sin(e.bearingInRadians),s=za();s[0]=-n*i*r-a*t,s[1]=-a*i*r+n*t;let o=Sy(s);o<1e-9?Ek(s):$y(s,s,1/o);let l=za();l[0]=n*i*t-a*r,l[1]=a*i*t+n*r;let u=Sy(l);return u<1e-9?Ek(l):$y(l,l,1/u),{vecEast:l,vecSouth:s}}function PS(e,t,r,i){let n;i?(n=[e,t,i(e,t),1],_i(n,n,r)):(n=[e,t,0,1],MS(n,n,r));let a=n[3];return{point:new de(n[0]/a,n[1]/a),signedDistanceFromCamera:a,isOccluded:!1}}function DF(e,t){return .5+e/t*.5}function YMe(e,t){return e.x>=-t[0]&&e.x<=t[0]&&e.y>=-t[1]&&e.y<=t[1]}function WMe(e,t,r,i,n,a,s,o,l,u,c,d,h){let f=r?e.textSizeData:e.iconSizeData,p=fv(f,t.transform.zoom),m=[256/t.width*2+1,256/t.height*2+1],g=r?e.text.dynamicLayoutVertexArray:e.icon.dynamicLayoutVertexArray;g.clear();let v=e.lineVertexArray,x=r?e.text.placedSymbolArray:e.icon.placedSymbolArray,_=t.transform.width/t.transform.height,y=!1;for(let w=0;w<x.length;w++){let $=x.get(w);if($.hidden||$.writingMode===2&&!y){th($.numGlyphs,g);continue}y=!1;let S=new de($.anchorX,$.anchorY),E={getElevation:h,pitchedLabelPlaneMatr
vendor: 9,605 bytes, line 744
744ix:i,lineVertexArray:v,pitchWithMap:a,projectionCache:{projections:{},offsets:{},cachedAnchorPoint:void 0,anyProjectionOccluded:!1},transform:t.transform,tileAnchorPoint:S,unwrappedTileID:l,width:u,height:c,translation:d},C=LF($.anchorX,$.anchorY,E);if(!YMe(C.point,m)){th($.numGlyphs,g);continue}let I=C.signedDistanceFromCamera,P=DF(t.transform.cameraToCenterDistance,I),T=dS(f,p,$),D=a?T*t.transform.getPitchedTextCorrection($.anchorX,$.anchorY,l)/P:T*P,A=dE({projectionContext:E,pitchedLabelPlaneMatrixInverse:n,symbol:$,fontSize:D,flip:!1,keepUpright:s,glyphOffsetArray:e.glyphOffsetArray,dynamicLayoutVertexArray:g,aspectRatio:_,rotateToLine:o});y=A.useVertical,(A.notEnoughRoom||y||A.needsFlipping&&dE({projectionContext:E,pitchedLabelPlaneMatrixInverse:n,symbol:$,fontSize:D,flip:!0,keepUpright:s,glyphOffsetArray:e.glyphOffsetArray,dynamicLayoutVertexArray:g,aspectRatio:_,rotateToLine:o}).notEnoughRoom)&&th($.numGlyphs,g)}r?e.text.dynamicLayoutVertexBuffer.updateData(g):e.icon.dynamicLayoutVertexBuffer.updateData(g)}function RF(e,t,r,i,n,a,s,o){let l=a.glyphStartIndex+a.numGlyphs,u=a.lineStartIndex,c=a.lineStartIndex+a.lineLength,d=t.getoffsetX(a.glyphStartIndex),h=t.getoffsetX(l-1),f=Uy(e*d,r,i,n,a.segment,u,c,o,s);if(!f)return null;let p=Uy(e*h,r,i,n,a.segment,u,c,o,s);return!p||o.projectionCache.anyProjectionOccluded?null:{first:f,last:p}}function cE(e,t,r,i){return e===1&&Math.abs(r.y-t.y)>Math.abs(r.x-t.x)*i?{useVertical:!0}:(e===2?t.y<r.y:t.x>r.x)?{needsFlipping:!0}:null}function dE(e){let{projectionContext:t,pitchedLabelPlaneMatrixInverse:r,symbol:i,fontSize:n,flip:a,keepUpright:s,glyphOffsetArray:o,dynamicLayoutVertexArray:l,aspectRatio:u,rotateToLine:c}=e,d=n/24,h=i.lineOffsetX*d,f=i.lineOffsetY*d,p;if(i.numGlyphs>1){let m=i.glyphStartIndex+i.numGlyphs,g=i.lineStartIndex,v=i.lineStartIndex+i.lineLength,x=RF(d,o,h,f,a,i,c,t);if(!x)return{notEnoughRoom:!0};let _=E0(x.first.point.x,x.first.point.y,t,r),y=E0(x.last.point.x,x.last.point.y,t,r);if(s&&!a){let w=cE(i.writingMode,_,y,u);if(w)return w}p=[x.first];for(let w=i.glyphStartIndex+1;w<m-1;w++){let $=Uy(d*o.getoffsetX(w),h,f,a,i.segment,g,v,t,c);if(!$)return{notEnoughRoom:!0};p.push($)}p.push(x.last)}else{if(s&&!a){let g=Ec(t.tileAnchorPoint.x,t.tileAnchorPoint.y,t).point,v=i.lineStartIndex+i.segment+1,x=new de(t.lineVertexArray.getx(v),t.lineVertexArray.gety(v)),_=Ec(x.x,x.y,t),y=_.signedDistanceFromCamera>0?_.point:OF(t.tileAnchorPoint,x,g,1,t),w=E0(g.x,g.y,t,r),$=E0(y.x,y.y,t,r),S=cE(i.writingMode,w,$,u);if(S)return S}let m=Uy(d*o.getoffsetX(i.glyphStartIndex),h,f,a,i.segment,i.lineStartIndex,i.lineStartIndex+i.lineLength,t,c);if(!m||t.projectionCache.anyProjectionOccluded)return{notEnoughRoom:!0};p=[m]}for(let m of p)Bm(l,m.point,m.angle);return{}}function OF(e,t,r,i,n){let a=e.add(e.sub(t)._unit()),s=Ec(a.x,a.y,n).point,o=r.sub(s);return r.add(o._mult(i/o.mag()))}function t3(e,t,r){let i=t.projectionCache;if(i.projections[e])return i.projections[e];let n=new de(t.lineVertexArray.getx(e),t.lineVertexArray.gety(e)),a=Ec(n.x,n.y,t);if(a.signedDistanceFromCamera>0)return i.projections[e]=a.point,i.anyProjectionOccluded||(i.anyProjectionOccluded=a.isOccluded),a.point;let s=e-r.direction,o=r.distanceFromAnchor===0?t.tileAnchorPoint:new de(t.lineVertexArray.getx(s),t.lineVertexArray.gety(s)),l=r.absOffsetX-r.distanceFromAnchor+1;return OF(o,n,r.previousVertex,l,t)}function Ec(e,t,r){let i=e+r.translation[0],n=t+r.translation[1],a;return r.pitchWithMap?(a=PS(i,n,r.pitchedLabelPlaneMatrix,r.getElevation),a.isOccluded=!1):(a=r.transform.projectTileCoordinates(i,n,r.unwrappedTileID,r.getElevation),a.point.x=(a.point.x*.5+.5)*r.width,a.point.y=(-a.point.y*.5+.5)*r.height),a}function E0(e,t,r,i){if(r.pitchWithMap){let n=[e,t,0,1];return _i(n,n,i),r.transform.projectTileCoordinates(n[0]/n[3],n[1]/n[3],r.unwrappedTileID,r.getElevation).point}return{x:e/r.width*2-1,y:1-t/r.height*2}}function LF(e,t,r){return r.transform.projectTileCoordinates(e,t,r.unwrappedTileID,r.getElevation)}function r3(e,t,r){return e._unit()._perp()._mult(t*r)}function ZMe(e,t,r,i,n,a,s,o,l){if(o.projectionCache.offsets[e])return o.projectionCache.offsets[e];let u=r.add(t);if(e+l.direction<i||e+l.direction>=n)return o.projectionCache.offsets[e]=u,u;let c=t3(e+l.direction,o,l),d=r3(c.sub(r),s,l.direction),h=r.add(d),f=c.add(d);return o.projectionCache.offsets[e]=K$e(a,u,h,f)||u,o.projectionCache.offsets[e]}function Uy(e,t,r,i,n,a,s,o,l){let u=i?e-t:e+t,c=u>0?1:-1,d=0;i&&(c*=-1,d=Math.PI),c<0&&(d+=Math.PI);let h=c>0?a+n:a+n+1,f;o.projectionCache.cachedAnchorPoint?f=o.projectionCache.cachedAnchorPoint:(f=Ec(o.tileAnchorPoint.x,o.tileAnchorPoint.y,o).point,o.projectionCache.cachedAnchorPoint=f);let p=f,m=f,g,v,x=0,_=0,y=Math.abs(u),w=[],$;for(;x+_<=y;){if(h+=c,h<a||h>=s)return null;x+=_,m=p,v=g;let I={absOffsetX:y,direction:c,distanceFromAnchor:x,previousVertex:m};if(p=t3(h,o,I),r===0)w.push(m),$=p.sub(m);else{let P,T=p.sub(m);P=T.mag()===0?r3(t3(h+c,o,I).sub(p),r,c):r3(T,r,c),v||(v=m.add(P)),g=ZMe(h,P,p,a,s,v,r,o,I),w.push(v),$=g.sub(v)}_=$.mag()}let S=(y-x)/_,E=$._mult(S)._add(v||m),C=d+Math.atan2(p.y-m.y,p.x-m.x);return w.push(E),{point:E,angle:l?C:0,path:w}}const KMe=new Float32Array([-1/0,-1/0,0,-1/0,-1/0,0,-1/0,-1/0,0,-1/0,-1/0,0]);function th(e,t){for(let r=0;r<e;r++){let i=t.length;t.resize(i+4),t.float32.set(KMe,i*3)}}function MS(e,t,r){let i=t[0],n=t[1];return e[0]=r[0]*i+r[4]*n+r[12],e[1]=r[1]*i+r[5]*n+r[13],e[3]=r[3]*i+r[7]*n+r[15],e}function XMe(e,t){let r=GMe;return qMe(r,t.pitchedLabelPlaneMatrix),e.map(i=>{let n=PS(i.x,i.y,r,t.getElevation),a=t.transform.projectTileCoordinates(n.point.x,n.point.y,t.unwrappedTileID,t.getElevation);return a.point.x=(a.point.x*.5+.5)*t.width,a.point.y=(-a.point.y*.5+.5)*t.height,a})}function JMe(e){let t=0,r=0,i=0,n=0;for(let a=0;a<e.length;a++)e[a].isOccluded?(i=a+1,n=0):(n++,n>r&&(r=n,t=i));return e.slice(t,t+r)}var QMe=class{constructor(e,t=new uE(e.width+200,e.height+200,25),r=new uE(e.width+200,e.height+200,25)){this.transform=e,this.grid=t,this.ignoredGrid=r,this.pitchFactor=Math.cos(e.pitch*Math.PI/180)*e.cameraToCenterDistance,this.screenRightBoundary=e.width+100,this.screenBottomBoundary=e.height+100,this.gridRightBoundary=e.width+200,this.gridBottomBoundary=e.height+200,this.perspectiveRatioCutoff=.6}placeCollisionBox(e,t,r,i,n,a,s,o,l,u,c,d){let h=e.anchorPointX+o[0],f=e.anchorPointY+o[1],p=this.projectAndGetPerspectiveRatio(h,f,n,u,d),m=r*p.perspectiveRatio,g;if(!a&&!s){let S=p.x+(c?c.x*m:0),E=p.y+(c?c.y*m:0);g={allPointsOccluded:!1,box:[S+e.x1*m,E+e.y1*m,S+e.x2*m,E+e.y2*m]}}else g=this._projectCollisionBox(e,m,i,n,a,s,o,p,u,c,d);let[v,x,_,y]=g.box,w=a?g.allPointsOccluded:p.isOccluded,$=w;return $||($=p.perspectiveRatio<this.perspectiveRatioCutoff),$||($=!this.isInsideGrid(v,x,_,y)),$||t!=="always"&&this.grid.hitTest(v,x,_,y,t,l)?{box:[v,x,_,y],placeable:!1,offscreen:!1,occluded:w}:{box:[v,x,_,y],placeable:!0,offscreen:this.isOffscreen(v,x,_,y),occluded:w}}placeCollisionCircles(e,t,r,i,n,a,s,o,l,u,c,d,h,f){let p=[],m=new de(t.anchorX,t.anchorY),g=this.getPerspectiveRatio(m.x,m.y,a,f),v=(l?n*this.transform.getPitchedTextCorrection(t.anchorX,t.anchorY,a)/g:n*g)/24,x={projections:{},offsets:{},cachedAnchorPoint:void 0,anyProjectionOccluded:!1},_=t.lineOffsetX*v,y=t.lineOffsetY*v,w={getElevation:f,pitchedLabelPlaneMatrix:s,lineVertexArray:r,pitchWithMap:l,projectionCache:x,transform:this.transform,tileAnchorPoint:m,unwrappedTileID:a,width:this.transform.width,height:this.transform.height,translation:h},$=RF(v,i,_,y,!1,t,!1,w),S=!1,E=!1,C=!0;if($){let I=c*.5*g+d,P=new de(-100,-100),T=new de(this.screenRightBoundary,this.screenBottomBoundary),D=new jMe,A=$.first,z=$.last,R=[];for(let Y=A.path.length-1;Y>=1;Y--)R.push(A.path[Y]);for(let Y=1;Y<z.path.length;Y++)R.push(z.path[Y]);let O=I*2.5;if(l){let Y=this.projectPathToScreenSpace(R,w);R=Y.some(F=>F.signedDistanceFromCamera<=0)?[]:Y.map(F=>F.point)}let V=[];if(R.length>0){let Y=R[0].clone(),F=R[0].clone();for(let ae=1;ae<R.length;ae++)Y.x=Math.min(Y.x,R[ae].x),Y.y=Math.min(Y.y,R[ae].y),F.x=Math.max(F.x,R[ae].x),F.y=Math.max(F.y,R[ae].y);V=Y.x>=P.x&&F.x<=T.x&&Y.y>=P.y&&F.y<=T.y?[R]:F.x<P.x||Y.x>T.x||F.y<P.y||Y.y>T.y?[]:$Pe([R],P.x,P.y,T.x,T.y)}for(let Y of V){D.reset(Y,I*.25);let F=0;F=D.length<=.5*I?1:Math.ceil(D.paddedLength/O)+1;for(let ae=0;ae<F;ae++){let ue=ae/Math.max(F-1,1),Z=D.lerp(ue),K=Z.x+100,fe=Z.y+100;p.push(K,fe,I,0);let ve=K-I,$e=fe-I,Re=K+I,Oe=fe+I;if(C&&(C=this.isOffscreen(ve,$e,Re,Oe)),E||(E=this.isInsideGrid(ve,$e,Re,Oe)),e!=="always"&&this.grid.hitTestCircle(K,fe,I,e,u)&&(S=!0,!o))return{circles:[],offscreen:!1,collisionDetected:S}}}}return{circles:!o&&S||!E||g<this.perspectiveRatioCutoff?[]:p,offscreen:C,collisionDetected:S}}projectPathToScreenSpace(e,t){return JMe(XMe(e,t))}queryRenderedSymbols(e){if(e.length===0||this.grid.keysLength()===0&&this.ignoredGrid.keysLength()===0)return{};let t=[],r=new no;for(let c of e){let d=new de(c.x+100,c.y+100);r.extend(d),t.push(d)}let{minX:i,minY:n,maxX:a,maxY:s}=r,o=this.grid.query(i,n,a,s).concat(this.ignoredGrid.query(i,n,a,s)),l={},u={};for(let c of o){let d=c.key;if(l[d.bucketInstanceId]===void 0&&(l[d.bucketInstanceId]={}),l[d.bucketInstanceId][d.featureIndex])continue;let h=[new de(c.x1,c.y1),new de(c.x2,c.y1),new de(c.x2,c.y2),new de(c.x1,c.y2)];bL(t,h)&&(l[d.bucketInstanceId][d.featureIndex]=!0,u[d.bucketInstanceId]===void 0&&(u[d.bucketInstanceId]=[]),u[d.bucketInstanceId].push(d.featureIndex))}return u}insertCollisionBox(e,t,r,i,n,a){let s=r?this.ignoredGrid:this.grid,o={bucketInstanceId:i,featureIndex:n,collisionGroupID:a,overlapMode:t};
vendor: 2,431 bytes, line 744
744s.insert(o,e[0],e[1],e[2],e[3])}insertCollisionCircles(e,t,r,i,n,a){let s=r?this.ignoredGrid:this.grid,o={bucketInstanceId:i,featureIndex:n,collisionGroupID:a,overlapMode:t};for(let l=0;l<e.length;l+=4)s.insertCircle(o,e[l],e[l+1],e[l+2])}projectAndGetPerspectiveRatio(e,t,r,i,n){if(n){let a;i?(a=[e,t,i(e,t),1],_i(a,a,n)):(a=[e,t,0,1],MS(a,a,n));let s=a[3];return{x:(a[0]/s+1)/2*this.transform.width+100,y:(-a[1]/s+1)/2*this.transform.height+100,perspectiveRatio:.5+.5*(this.transform.cameraToCenterDistance/s),isOccluded:!1,signedDistanceFromCamera:s}}{let a=this.transform.projectTileCoordinates(e,t,r,i);return{x:(a.point.x+1)/2*this.transform.width+100,y:(-a.point.y+1)/2*this.transform.height+100,perspectiveRatio:.5+.5*(this.transform.cameraToCenterDistance/a.signedDistanceFromCamera),isOccluded:a.isOccluded,signedDistanceFromCamera:a.signedDistanceFromCamera}}}getPerspectiveRatio(e,t,r,i){let n=this.transform.projectTileCoordinates(e,t,r,i);return .5+.5*(this.transform.cameraToCenterDistance/n.signedDistanceFromCamera)}isOffscreen(e,t,r,i){return r<100||e>=this.screenRightBoundary||i<100||t>this.screenBottomBoundary}isInsideGrid(e,t,r,i){return r>=0&&e<this.gridRightBoundary&&i>=0&&t<this.gridBottomBoundary}getViewportMatrix(){let e=Ms([]);return ei(e,e,[-100,-100,0]),e}_projectCollisionBox(e,t,r,i,n,a,s,o,l,u,c){let d=1,h=0,f=0,p=1,m=e.anchorPointX+s[0],g=e.anchorPointY+s[1];if(a&&!n){let D=this.projectAndGetPerspectiveRatio(m+1,g,i,l,c),A=D.x-o.x,z=D.y-o.y,R=Math.atan(z/A)+(A<0?Math.PI:0),O=Math.sin(R),V=Math.cos(R);d=V,h=O,f=-O,p=V}else if(!a&&n){let D=ES(this.transform);d=D.vecEast[0],h=D.vecEast[1],f=D.vecSouth[0],p=D.vecSouth[1]}let v=o.x,x=o.y,_=t;if(n&&(v=m,x=g,_=2**-(this.transform.zoom-r.overscaledZ),_*=this.transform.getPitchedTextCorrection(m,g,i),!u)){let D=o.signedDistanceFromCamera/this.transform.cameraToCenterDistance,A=Ot(.5+.5*D,0,4);_*=A}u&&(v+=d*u.x*_+f*u.y*_,x+=h*u.x*_+p*u.y*_);let y=e.x1*_,w=e.x2*_,$=(y+w)/2,S=e.y1*_,E=e.y2*_,C=(S+E)/2,I=[{offsetX:y,offsetY:S},{offsetX:$,offsetY:S},{offsetX:w,offsetY:S},{offsetX:w,offsetY:C},{offsetX:w,offsetY:E},{offsetX:$,offsetY:E},{offsetX:y,offsetY:E},{offsetX:y,offsetY:C}],P=[];for(let{offsetX:D,offsetY:A}of I)P.push(new de(v+d*D+f*A,x+h*D+p*A));let T=!1;if(n){let D=P.map(A=>this.projectAndGetPerspectiveRatio(A.x,A.y,i,l,c));T=D.some(A=>!A.isOccluded),P=D.map(A=>new de(A.x,A.y))}else T=!0;return{box:q$e(P),allPointsOccluded:!T}}}
vendor: 14,774 bytes, line 744
744,hE=class{constructor(e,t,r,i){this.opacity=e?Math.max(0,Math.min(1,e.opacity+(e.placed?t:-t))):i&&r?1:0,this.placed=r}isHidden(){return this.opacity===0&&!this.placed}},Af=class{constructor(e,t,r,i,n){this.text=new hE(e?e.text:null,t,r,n),this.icon=new hE(e?e.icon:null,t,i,n)}isHidden(){return this.text.isHidden()&&this.icon.isHidden()}},fE=class{constructor(e,t,r){this.text=e,this.icon=t,this.skipFade=r}},eIe=class{constructor(e,t,r,i,n){this.bucketInstanceId=e,this.featureIndex=t,this.sourceLayerIndex=r,this.bucketIndex=i,this.tileID=n}},tIe=class{constructor(e){this.crossSourceCollisions=e,this.maxGroupID=0,this.collisionGroups={}}get(e){if(this.crossSourceCollisions)return{ID:0,predicate:null};if(!this.collisionGroups[e]){let t=++this.maxGroupID;this.collisionGroups[e]={ID:t,predicate:r=>r.collisionGroupID===t}}return this.collisionGroups[e]}};function pE(e,t,r,i,n){let{horizontalAlign:a,verticalAlign:s}=ZL(e),o=-(a-.5)*t,l=-(s-.5)*r;return new de(o+i[0]*n,l+i[1]*n)}var rIe=class{constructor(e,t,r,i,n){this.transform=e.clone(),this.terrain=t,this.collisionIndex=new QMe(this.transform),this.placements={},this.opacities={},this.variableOffsets={},this.stale=!1,this.commitTime=0,this.fadeDuration=r,this.retainedQueryData={},this.collisionGroups=new tIe(i),this.collisionCircleArrays={},this.collisionBoxArrays=new Map,this.prevPlacement=n,n&&(n.prevPlacement=void 0),this.placedOrientations={}}_getTerrainElevationFunc(e){let t=this.terrain;return t?(r,i)=>t.getElevation(e,r,i):null}getBucketParts(e,t,r,i){let n=r.getBucket(t),a=r.latestFeatureIndex;if(!n||!a||t.id!==n.layerIds[0])return;let s=r.collisionBoxArray,o=n.layers[0].layout,l=n.layers[0].paint,u=2**(this.transform.zoom-r.tileID.overscaledZ),c=r.tileSize/ye,d=r.tileID.toUnwrapped(),h=o.get("text-rotation-alignment")==="map",f=Ca(r,1,this.transform.zoom),p=lu(this.collisionIndex.transform,r,l.get("text-translate"),l.get("text-translate-anchor")),m=lu(this.collisionIndex.transform,r,l.get("icon-translate"),l.get("icon-translate-anchor")),g=kS(h,this.transform,f);this.retainedQueryData[n.bucketInstanceId]=new eIe(n.bucketInstanceId,a,n.sourceLayerIndex,n.index,r.tileID);let v={bucket:n,layout:o,translationText:p,translationIcon:m,unwrappedTileID:d,pitchedLabelPlaneMatrix:g,scale:u,textPixelRatio:c,holdingForFade:r.holdingForSymbolFade(),collisionBoxArray:s,partiallyEvaluatedTextSize:fv(n.textSizeData,this.transform.zoom),collisionGroup:this.collisionGroups.get(n.sourceID)};if(i)for(let x of n.sortKeyRanges){let{sortKey:_,symbolInstanceStart:y,symbolInstanceEnd:w}=x;e.push({sortKey:_,symbolInstanceStart:y,symbolInstanceEnd:w,parameters:v})}else e.push({symbolInstanceStart:0,symbolInstanceEnd:n.symbolInstances.length,parameters:v})}attemptAnchorPlacement(e,t,r,i,n,a,s,o,l,u,c,d,h,f,p,m,g,v,x,_){var E,C,I;let y=H8[e.textAnchor],w=[e.textOffset0,e.textOffset1],$=pE(y,r,i,w,n),S=this.collisionIndex.placeCollisionBox(t,d,o,l,u,s,a,m,c.predicate,x,$,_);if(!(v&&!this.collisionIndex.placeCollisionBox(v,d,o,l,u,s,a,g,c.predicate,x,$,_).placeable)&&S.placeable){let P;if((E=this.prevPlacement)!=null&&E.variableOffsets[h.crossTileID]&&((I=(C=this.prevPlacement)==null?void 0:C.placements[h.crossTileID])!=null&&I.text)&&(P=this.prevPlacement.variableOffsets[h.crossTileID].anchor),h.crossTileID===0)throw Error("symbolInstance.crossTileID can't be 0");return this.variableOffsets[h.crossTileID]={textOffset:w,width:r,height:i,anchor:y,textBoxScale:n,prevAnchor:P},this.markUsedJustification(f,y,h,p),f.allowVerticalPlacement&&(this.markUsedOrientation(f,p,h),this.placedOrientations[h.crossTileID]=p),{shift:$,placedGlyphBoxes:S}}}placeLayerBucketPart(e,t,r){let{bucket:i,layout:n,translationText:a,translationIcon:s,unwrappedTileID:o,pitchedLabelPlaneMatrix:l,textPixelRatio:u,holdingForFade:c,collisionBoxArray:d,partiallyEvaluatedTextSize:h,collisionGroup:f}=e.parameters,p=n.get("text-optional"),m=n.get("icon-optional"),g=By(n,"text-overlap","text-allow-overlap"),v=g==="always",x=By(n,"icon-overlap","icon-allow-overlap"),_=x==="always",y=n.get("text-rotation-alignment")==="map",w=n.get("text-pitch-alignment")==="map",$=n.get("icon-text-fit")!=="none",S=n.get("symbol-z-order")==="viewport-y",E=v&&(_||!i.hasIconData()||m),C=_&&(v||!i.hasTextData()||p);!i.collisionArrays&&d&&i.deserializeCollisionBoxes(d);let I=this.retainedQueryData[i.bucketInstanceId].tileID,P=this._getTerrainElevationFunc(I),T=this.transform.getFastPathSimpleProjectionMatrix(I),D=(A,z,R)=>{var ie,U;if(t[A.crossTileID])return;if(c){this.placements[A.crossTileID]=new fE(!1,!1,!1);return}let O=!1,V=!1,Y=!0,F=null,ae={box:null,placeable:!1,offscreen:null,occluded:!1},ue={placeable:!1},Z=null,K=null,fe=null,ve=0,$e=0,Re=0;z.textFeatureIndex?ve=z.textFeatureIndex:A.useRuntimeCollisionCircles&&(ve=A.featureIndex),z.verticalTextFeatureIndex&&($e=z.verticalTextFeatureIndex);let Oe=z.textBox;if(Oe){let ne=q=>{let te=1;if(i.allowVerticalPlacement&&!q&&this.prevPlacement){let ee=this.prevPlacement.placedOrientations[A.crossTileID];ee&&(this.placedOrientations[A.crossTileID]=ee,te=ee,this.markUsedOrientation(i,te,A))}return te},me=(q,te)=>{if(i.allowVerticalPlacement&&A.numVerticalGlyphVertices>0&&z.verticalTextBox){for(let ee of i.writingModes)if(ee===2?(ae=te(),ue=ae):ae=q(),ae==null?void 0:ae.placeable)break}else ae=q()},J=A.textAnchorOffsetStartIndex,N=A.textAnchorOffsetEndIndex;if(N===J){let q=(te,ee)=>{let oe=this.collisionIndex.placeCollisionBox(te,g,u,I,o,w,y,a,f.predicate,P,void 0,T);return oe!=null&&oe.placeable&&(this.markUsedOrientation(i,ee,A),this.placedOrientations[A.crossTileID]=ee),oe};me(()=>q(Oe,1),()=>{let te=z.verticalTextBox;return i.allowVerticalPlacement&&A.numVerticalGlyphVertices>0&&te?q(te,2):{box:null,offscreen:null}}),ne(ae==null?void 0:ae.placeable)}else{let q=H8[(U=(ie=this.prevPlacement)==null?void 0:ie.variableOffsets[A.crossTileID])==null?void 0:U.anchor],te=(oe,Se,we)=>{let De=oe.x2-oe.x1,Ue=oe.y2-oe.y1,xt=A.textBoxScale,kt=$&&x==="never"?Se:null,ot=null,rr=g==="never"?1:2,Cr="never";q&&rr++;for(let xi=0;xi<rr;xi++){for(let Vt=J;Vt<N;Vt++){let ge=i.textAnchorOffsets.get(Vt);if(q&&ge.textAnchor!==q)continue;let B=this.attemptAnchorPlacement(ge,oe,De,Ue,xt,y,w,u,I,o,f,Cr,A,i,we,a,s,kt,P);if(B&&(ot=B.placedGlyphBoxes,ot==null?void 0:ot.placeable))return O=!0,F=B.shift,ot}q?q=null:Cr=g}return r&&!ot&&(ot={box:this.collisionIndex.placeCollisionBox(Oe,"always",u,I,o,w,y,a,f.predicate,P,void 0,T).box,offscreen:!1,placeable:!1,occluded:!1}),ot};me(()=>te(Oe,z.iconBox,1),()=>{let oe=z.verticalTextBox,Se=ae==null?void 0:ae.placeable;return i.allowVerticalPlacement&&!Se&&A.numVerticalGlyphVertices>0&&oe?te(oe,z.verticalIconBox,2):{box:null,occluded:!0,offscreen:null}}),ae&&(O=ae.placeable,Y=ae.offscreen);let ee=ne(ae==null?void 0:ae.placeable);if(!O&&this.prevPlacement){let oe=this.prevPlacement.variableOffsets[A.crossTileID];oe&&(this.variableOffsets[A.crossTileID]=oe,this.markUsedJustification(i,oe.anchor,A,ee))}}}if(Z=ae,O=Z==null?void 0:Z.placeable,Y=Z==null?void 0:Z.offscreen,A.useRuntimeCollisionCircles&&A.centerJustifiedTextSymbolIndex>=0){let ne=i.text.placedSymbolArray.get(A.centerJustifiedTextSymbolIndex),me=dS(i.textSizeData,h,ne),J=n.get("text-padding"),N=A.collisionCircleDiameter;K=this.collisionIndex.placeCollisionCircles(g,ne,i.lineVertexArray,i.glyphOffsetArray,me,o,l,r,w,f.predicate,N,J,a,P),K.circles.length&&K.collisionDetected&&!r&&vr("Collisions detected, but collision boxes are not shown"),O=v||K.circles.length>0&&!K.collisionDetected,Y&&(Y=K.offscreen)}if(z.iconFeatureIndex&&(Re=z.iconFeatureIndex),z.iconBox){let ne=me=>this.collisionIndex.placeCollisionBox(me,x,u,I,o,w,y,s,f.predicate,P,$&&F?F:void 0,T);ue&&ue.placeable&&z.verticalIconBox?(fe=ne(z.verticalIconBox),V=fe.placeable):(fe=ne(z.iconBox),V=fe.placeable),Y&&(Y=fe.offscreen)}let ze=p||A.numHorizontalGlyphVertices===0&&A.numVerticalGlyphVertices===0,Be=m||A.numIconVertices===0;!ze&&!Be?V=O=V&&O:Be?ze||V&&(V=O):O=V&&O;let qe=O&&Z.placeable,j=V&&fe.placeable;if(qe&&(ue&&ue.placeable&&$e?this.collisionIndex.insertCollisionBox(Z.box,g,n.get("text-ignore-placement"),i.bucketInstanceId,$e,f.ID):this.collisionIndex.insertCollisionBox(Z.box,g,n.get("text-ignore-placement"),i.bucketInstanceId,ve,f.ID)),j&&this.collisionIndex.insertCollisionBox(fe.box,x,n.get("icon-ignore-placement"),i.bucketInstanceId,Re,f.ID),K&&O&&this.collisionIndex.insertCollisionCircles(K.circles,g,n.get("text-ignore-placement"),i.bucketInstanceId,ve,f.ID),r&&this.storeCollisionData(i.bucketInstanceId,R,z,Z,fe,K),A.crossTileID===0)throw Error("symbolInstance.crossTileID can't be 0");if(i.bucketInstanceId===0)throw Error("bucket.bucketInstanceId can't be 0");let W=(O||E)&&!(Z!=null&&Z.occluded),G=(V||C)&&!(fe!=null&&fe.occluded);this.placements[A.crossTileID]=new fE(W,G,Y||i.justReloaded),t[A.crossTileID]=!0};if(S){if(e.symbolInstanceStart!==0)throw Error("bucket.bucketInstanceId should be 0");let A=i.getSortedSymbolIndexes(-this.transform.bearingInRadians);for(let z=A.length-1;z>=0;--z){let R=A[z];D(i.symbolInstances.get(R),i.collisionArrays[R],R)}}else for(let A=e.symbolInstanceStart;A<e.symbolInstanceEnd;A++)D(i.symbolInstances.get(A),i.collisionArrays[A],A);i.justReloaded=!1}storeCollisionData(e,t,r,i,n,a){if(r.textBox||r.iconBox){let s;this.collisionBoxArrays.has(e)?s=this.collisionBoxArrays.get(e):(s=new Map,this.collisionBoxArrays.set(e,s));let o;s.has(t)?o=s.get(t):(o={text:null,icon:null},s.set(t,o)),r.textBox&&(o.text=i.box),r.iconBox&&(o.icon=n.box)}if(a){let s=this.collisionCircleArrays[e];s===void 0&&(s=this.collisionCircleArrays[e]=[]);for(let o=0;o<a.circles.length;o+=4)s.push(a.circles[o+0]-100),s.push(a.circles[o+1]-100),s.push(a.circles[o+2]),s.push(+!!a.collisionDetected)}}markUsedJustification(e,t,r,i){let n={left:r.leftJustifiedTextSymbolIndex,center:r.centerJustifiedTextSymbolIndex,right:r.rightJustifiedTextSymbolIndex},a;a=i===2?r.verticalPlacedTextSymbolIndex:n[TPe(t)];let s=[r.leftJustifiedTextSymbolIndex,r.centerJustifiedTextSymbolIndex,r.rightJustifiedTextSymbolIndex,r.verticalPlacedTextSymbolIndex];for(let o of s)o>=0&&(a>=0&&o!==a?e.text.placedSymbolArray.get(o).crossTileID=0:e.text.placedSymbolArray.get(o).crossTileID=r.crossTileID)}markUsedOrientation(e,t,r){let i=t===1||t===3?t:0,n=t===2?t:0,a=[r.leftJustifiedTextSymbolIndex,r.centerJustifiedTextSymbolIndex,r.rightJustifiedTextSymbolIndex];for(let s of a)e.text.placedSymbolArray.get(s).placedOrientation=i;r.verticalPlacedTextSymbolIndex&&(e.text.placedSymbolArray.get(r.verticalPlacedTextSymbolIndex).placedOrientation=n)}commit(e){this.commitTime=e,this.zoomAtLastRecencyCheck=this.transform.zoom;let t=this.prevPlacement,r=!1;this.prevZoomAdjustment=t?t.zoomAdjustment(this.transform.zoom):0;let i=t?t.symbolFadeChange(e):1,n=t?t.opacities:{},a=t?t.variableOffsets:{},s=t?t.placedOrientations:{};for(let o in this.placements){let l=this.placements[o],u=n[o];u?(this.opacities[o]=new Af(u,i,l.text,l.icon),r||(r=l.text!==u.text.placed),r||(r=l.icon!==u.icon.placed)):(this.opacities[o]=new Af(null,i,l.text,l.icon,l.skipFade),r||(r=l.text||l.icon))}for(let o in n){let l=n[o];if(!this.opacities[o]){let u=new Af(l,i,!1,!1);u.isHidden()||(this.opacities[o]=u,r||(r=l.text.placed),r||(r=l.icon.placed))}}for(let o in a)!this.variableOffsets[o]&&this.opacities[o]&&!this.opacities[o].isHidden()&&(this.variableOffsets[o]=a[o]);for(let o in s)!this.placedOrientations[o]&&this.opacities[o]&&!this.opacities[o].isHidden()&&(this.placedOrientations[o]=s[o]);if(t&&t.lastPlacementChangeTime===void 0)throw Error("Last placement time for previous placement is not defined");r?this.lastPlacementChangeTime=e:typeof this.lastPlacementChangeTime!="number"&&(this.lastPlacementChangeTime=t?t.lastPlacementChangeTime:e)}updateLayerOpacities(e,t){let r={};for(let i of t){let n=i.getBucket(e);n&&i.latestFeatureIndex&&e.id===n.layerIds[0]&&this.updateBucketOpacities(n,i.tileID,r,i.collisionBoxArray)}}updateBucketOpacities(e,t,r,i){e.hasTextData()&&(e.text.opacityVertexArray.clear(),e.text.hasVisibleVertices=!1),e.hasIconData()&&(e.icon.opacityVertexArray.clear(),e.icon.hasVisibleVertices=!1),e.hasIconCollisionBoxData()&&e.iconCollisionBox.collisionVertexArray.clear(),e.hasTextCollisionBoxData()&&e.textCollisionBox.collisionVertexArray.clear();let n=e.layers[0],a=n.layout,s=new Af(null,0,!1,!1,!0),o=a.get("text-allow-overlap"),l=a.get("icon-allow-overlap"),u=n._unevaluatedLayout.hasValue("text-variable-anchor")||n._unevaluatedLayout.hasValue("text-variable-anchor-offset"),c=a.get("text-rotation-alignment")==="map",d=a.get("text-pitch-alignment")==="map",h=a.get("icon-text-fit")!=="none",f=new Af(null,0,o&&(l||!e.hasIconData()||a.get("icon-optional")),l&&(o||!e.hasTextData()||a.get("text-optional")),!0);!e.collisionArrays&&i&&(e.hasIconCollisionBoxData()||e.hasTextCollisionBoxData())&&e.deserializeCollisionBoxes(i);let p=(g,v,x)=>{for(let _=0;_<v/4;_++)g.opacityVertexArray.emplaceBack(x);g.hasVisibleVertices||(g.hasVisibleVertices=x!==Df)},m=this.collisionBoxArrays.get(e.bucketInstanceId);for(let g=0;g<e.symbolInstances.length;g++){let v=e.symbolInstances.get(g),{numHorizontalGlyphVertices:x,numVerticalGlyphVertices:_,crossTileID:y}=v,w=r[y],$=this.opacities[y];w?$=s:$||($=f,this.opacities[y]=$),r[y]=!0;let S=x>0||_>0,E=v.numIconVertices>0,C=this.placedOrientations[v.crossTileID],I=C===2,P=C===1||C===3;if(S){let D=gE($.text),A=I?Df:D;p(e.text,x,A);let z=P?Df:D;p(e.text,_,z);let R=$.text.isHidden(),O=[v.rightJustifiedTextSymbolIndex,v.centerJustifiedTextSymbolIndex,v.leftJustifiedTextSymbolIndex];for(let F of O)F>=0&&(e.text.placedSymbolArray.get(F).hidden=R||I?1:0);v.verticalPlacedTextSymbolIndex>=0&&(e.text.placedSymbolArray.get(v.verticalPlacedTextSymbolIndex).hidden=R||P?1:0);let V=this.variableOffsets[v.crossTileID];V&&this.markUsedJustification(e,V.anchor,v,C);let Y=this.placedOrientations[v.crossTileID];Y&&(this.markUsedJustification(e,"left",v,Y),this.markUsedOrientation(e,Y,v))}if(E){let D=gE($.icon),A=!(h&&v.verticalPlacedIconSymbolIndex&&I);if(v.placedIconSymbolIndex>=0){let z=A?D:Df;p(e.icon,v.numIconVertices,z),e.icon.placedSymbolArray.get(v.placedIconSymbolIndex).hidden=$.icon.isHidden()}if(v.verticalPlacedIconSymbolIndex>=0){let z=A?Df:D;p(e.icon,v.numVerticalIconVertices,z),e.icon.placedSymbolArray.get(v.verticalPlacedIconSymbolIndex).hidden=$.icon.isHidden()}}let T=m!=null&&m.has(g)?m.get(g):{text:null,icon:null};if(e.hasIconCollisionBoxData()||e.hasTextCollisionBoxData()){let D=e.collisionArrays[g];if(D){let A=new de(0,0);if(D.textBox||D.verticalTextBox){let z=!0;if(u){let R=this.variableOffsets[y];R?(A=pE(R.anchor,R.width,R.height,R.textOffset,R.textBoxScale),c&&A._rotate(d?-this.transform.bearingInRadians:this.transform.bearingInRadians)):z=!1}if(D.textBox||D.verticalTextBox){let R;
vendor: 8,397 bytes, line 744
744D.textBox&&(R=I),D.verticalTextBox&&(R=P),mE(e.textCollisionBox.collisionVertexArray,$.text.placed,!z||R,T.text,A.x,A.y)}}if(D.iconBox||D.verticalIconBox){let z=!!(!P&&D.verticalIconBox),R;D.iconBox&&(R=z),D.verticalIconBox&&(R=!z),mE(e.iconCollisionBox.collisionVertexArray,$.icon.placed,R,T.icon,h?A.x:0,h?A.y:0)}}}}if(e.sortFeatures(-this.transform.bearingInRadians),this.retainedQueryData[e.bucketInstanceId]&&(this.retainedQueryData[e.bucketInstanceId].featureSortOrder=e.featureSortOrder),e.hasTextData()&&e.text.opacityVertexBuffer&&e.text.opacityVertexBuffer.updateData(e.text.opacityVertexArray),e.hasIconData()&&e.icon.opacityVertexBuffer&&e.icon.opacityVertexBuffer.updateData(e.icon.opacityVertexArray),e.hasIconCollisionBoxData()&&e.iconCollisionBox.collisionVertexBuffer&&e.iconCollisionBox.collisionVertexBuffer.updateData(e.iconCollisionBox.collisionVertexArray),e.hasTextCollisionBoxData()&&e.textCollisionBox.collisionVertexBuffer&&e.textCollisionBox.collisionVertexBuffer.updateData(e.textCollisionBox.collisionVertexArray),e.text.opacityVertexArray.length!==e.text.layoutVertexArray.length/4)throw Error(`bucket.text.opacityVertexArray.length (= ${e.text.opacityVertexArray.length}) !== bucket.text.layoutVertexArray.length (= ${e.text.layoutVertexArray.length}) / 4`);if(e.icon.opacityVertexArray.length!==e.icon.layoutVertexArray.length/4)throw Error(`bucket.icon.opacityVertexArray.length (= ${e.icon.opacityVertexArray.length}) !== bucket.icon.layoutVertexArray.length (= ${e.icon.layoutVertexArray.length}) / 4`);e.bucketInstanceId in this.collisionCircleArrays&&(e.collisionCircleArray=this.collisionCircleArrays[e.bucketInstanceId],delete this.collisionCircleArrays[e.bucketInstanceId])}symbolFadeChange(e){return this.fadeDuration===0?1:(e-this.commitTime)/this.fadeDuration+this.prevZoomAdjustment}zoomAdjustment(e){return Math.max(0,(this.transform.zoom-e)/1.5)}hasTransitions(e){return this.stale||e-this.lastPlacementChangeTime<this.fadeDuration}stillRecent(e,t){let r=this.zoomAtLastRecencyCheck===t?1-this.zoomAdjustment(t):1;return this.zoomAtLastRecencyCheck=t,this.commitTime+this.fadeDuration*r>e}setStale(){this.stale=!0}};function mE(e,t,r,i,n,a){(!i||i.length===0)&&(i=[0,0,0,0]);let s=i[0]-100,o=i[1]-100,l=i[2]-100,u=i[3]-100;e.emplaceBack(+!!t,+!!r,n||0,a||0,s,o),e.emplaceBack(+!!t,+!!r,n||0,a||0,l,o),e.emplaceBack(+!!t,+!!r,n||0,a||0,l,u),e.emplaceBack(+!!t,+!!r,n||0,a||0,s,u)}const iIe=2**25,nIe=2**24,aIe=2**17,sIe=2**16;function gE(e){if(e.opacity===0&&!e.placed)return 0;if(e.opacity===1&&e.placed)return 4294967295;let t=+!!e.placed,r=Math.floor(e.opacity*127);return r*iIe+t*nIe+r*aIe+t*sIe+r*512+t*256+r*2+t}const Df=0;var oIe=class{constructor(e){this._sortAcrossTiles=e.layout.get("symbol-z-order")!=="viewport-y"&&!e.layout.get("symbol-sort-key").isConstant(),this._currentTileIndex=0,this._currentPartIndex=0,this._seenCrossTileIDs={},this._bucketParts=[]}continuePlacement(e,t,r,i,n){let a=this._bucketParts;for(;this._currentTileIndex<e.length;){let s=e[this._currentTileIndex];if(t.getBucketParts(a,i,s,this._sortAcrossTiles),this._currentTileIndex++,n())return!0}for(this._sortAcrossTiles&&(this._sortAcrossTiles=!1,a.sort((s,o)=>s.sortKey-o.sortKey));this._currentPartIndex<a.length;){let s=a[this._currentPartIndex];if(t.placeLayerBucketPart(s,this._seenCrossTileIDs,r),this._currentPartIndex++,n())return!0}return!1}},lIe=class{constructor(e,t,r,i,n,a,s,o){this.placement=new rIe(e,t,a,s,o),this._currentPlacementIndex=r.length-1,this._forceFullPlacement=i,this._showCollisionBoxes=n,this._done=!1}isDone(){return this._done}continuePlacement(e,t,r){let i=tr(),n=()=>!this._forceFullPlacement&&tr()-i>2;for(;this._currentPlacementIndex>=0;){let a=t[e[this._currentPlacementIndex]],s=this.placement.collisionIndex.transform.zoom;if(XL(a)&&a.layout&&(!a.minzoom||a.minzoom<=s)&&(!a.maxzoom||a.maxzoom>s)){if(this._inProgressLayer||(this._inProgressLayer=new oIe(a)),this._inProgressLayer.continuePlacement(r[a.source],this.placement,this._showCollisionBoxes,a,n))return;delete this._inProgressLayer}this._currentPlacementIndex--}this._done=!0}commit(e){return this.placement.commit(e),this.placement}};const _E=[Int8Array,Uint8Array,Uint8ClampedArray,Int16Array,Uint16Array,Int32Array,Uint32Array,Float32Array,Float64Array],Er=new Uint32Array(96);var uIe=class FF{static from(t){if(!t||t.byteLength===void 0||t.buffer)throw Error("Data must be an instance of ArrayBuffer or SharedArrayBuffer.");let[r,i]=new Uint8Array(t,0,2);if(r!==219)throw Error("Data does not appear to be in a KDBush format.");let n=i>>4;if(n!==1)throw Error(`Got v${n} data when expected v1.`);let a=_E[i&15];if(!a)throw Error("Unrecognized array type.");let[s]=new Uint16Array(t,2,1),[o]=new Uint32Array(t,4,1);return new FF(o,s,a,void 0,t)}constructor(t,r=64,i=Float64Array,n=ArrayBuffer,a){if(isNaN(t)||t<0)throw Error(`Unexpected numItems value: ${t}.`);this.numItems=+t,this.nodeSize=Math.min(Math.max(+r,2),65535),this.ArrayType=i,this.IndexArrayType=t<65536?Uint16Array:Uint32Array;let s=_E.indexOf(this.ArrayType),o=t*2*this.ArrayType.BYTES_PER_ELEMENT,l=t*this.IndexArrayType.BYTES_PER_ELEMENT,u=(8-l%8)%8;if(s<0)throw Error(`Unexpected typed array class: ${i}.`);if(a)this.data=a,this.ids=new this.IndexArrayType(a,8,t),this.coords=new i(a,8+l+u,t*2),this._pos=t*2,this._finished=!0;else{let c=this.data=new n(8+o+l+u);this.ids=new this.IndexArrayType(c,8,t),this.coords=new i(c,8+l+u,t*2),this._pos=0,this._finished=!1,new Uint8Array(c,0,2).set([219,16+s]),new Uint16Array(c,2,1)[0]=r,new Uint32Array(c,4,1)[0]=t}}add(t,r){let i=this._pos>>1;return this.ids[i]=i,this.coords[this._pos++]=t,this.coords[this._pos++]=r,i}finish(){let t=this._pos>>1;if(t!==this.numItems)throw Error(`Added ${t} items when expected ${this.numItems}.`);return i3(this.ids,this.coords,this.nodeSize,0,this.numItems-1,0),this._finished=!0,this}range(t,r,i,n){if(!this._finished)throw Error("Data not yet indexed - call index.finish().");let{ids:a,coords:s,nodeSize:o}=this;Er[0]=0,Er[1]=a.length-1,Er[2]=0;let l=3,u=[];for(;l>0;){let c=Er[--l],d=Er[--l],h=Er[--l];if(d-h<=o){for(let g=h;g<=d;g++){let v=s[2*g],x=s[2*g+1];v>=t&&v<=i&&x>=r&&x<=n&&u.push(a[g])}continue}let f=h+d>>1,p=s[2*f],m=s[2*f+1];p>=t&&p<=i&&m>=r&&m<=n&&u.push(a[f]),(c===0?t<=p:r<=m)&&(Er[l++]=h,Er[l++]=f-1,Er[l++]=1-c),(c===0?i>=p:n>=m)&&(Er[l++]=f+1,Er[l++]=d,Er[l++]=1-c)}return u}within(t,r,i){let n=[];return this.withinInto(t,r,i,n),n}withinInto(t,r,i,n){if(!this._finished)throw Error("Data not yet indexed - call index.finish().");let{ids:a,coords:s,nodeSize:o}=this;Er[0]=0,Er[1]=a.length-1,Er[2]=0;let l=3,u=0,c=i*i;for(;l>0;){let d=Er[--l],h=Er[--l],f=Er[--l];if(h-f<=o){for(let v=f;v<=h;v++)yE(s[2*v],s[2*v+1],t,r)<=c&&(n[u++]=a[v]);continue}let p=f+h>>1,m=s[2*p],g=s[2*p+1];yE(m,g,t,r)<=c&&(n[u++]=a[p]),(d===0?t-i<=m:r-i<=g)&&(Er[l++]=f,Er[l++]=p-1,Er[l++]=1-d),(d===0?t+i>=m:r+i>=g)&&(Er[l++]=p+1,Er[l++]=h,Er[l++]=1-d)}return u}};function i3(e,t,r,i,n,a){if(n-i<=r)return;let s=i+n>>1;zF(e,t,s,i,n,a),i3(e,t,r,i,s-1,1-a),i3(e,t,r,s+1,n,1-a)}function zF(e,t,r,i,n,a){for(;n>i;){if(n-i>600){let u=n-i+1,c=r-i+1,d=Math.log(u),h=.5*Math.exp(2*d/3),f=.5*Math.sqrt(d*h*(u-h)/u)*(c-u/2<0?-1:1);zF(e,t,r,Math.max(i,Math.floor(r-c*h/u+f)),Math.min(n,Math.floor(r+(u-c)*h/u+f)),a)}let s=t[2*r+a],o=i,l=n;for(Rf(e,t,i,r),t[2*n+a]>s&&Rf(e,t,i,n);o<l;){for(Rf(e,t,o,l),o++,l--;t[2*o+a]<s;)o++;for(;t[2*l+a]>s;)l--}t[2*i+a]===s?Rf(e,t,i,l):(l++,Rf(e,t,l,n)),l<=r&&(i=l+1),r<=l&&(n=l-1)}}function Rf(e,t,r,i){Gb(e,r,i),Gb(t,2*r,2*i),Gb(t,2*r+1,2*i+1)}function Gb(e,t,r){let i=e[t];e[t]=e[r],e[r]=i}function yE(e,t,r,i){let n=e-r,a=t-i;return n*n+a*a}const Of=512/ye/2;var cIe=class{constructor(e,t,r){this.tileID=e,this.bucketInstanceId=r,this._symbolsByKey={};let i=new Map;for(let n=0;n<t.length;n++){let a=t.get(n),s=a.key,o=i.get(s);o?o.push(a):i.set(s,[a])}for(let[n,a]of i){let s={positions:a.map(o=>({x:Math.floor(o.anchorX*Of),y:Math.floor(o.anchorY*Of)})),crossTileIDs:a.map(o=>o.crossTileID)};if(s.positions.length>128){let o=new uIe(s.positions.length,16,Uint16Array);for(let{x:l,y:u}of s.positions)o.add(l,u);o.finish(),delete s.positions,s.index=o}this._symbolsByKey[n]=s}}getScaledCoordinates(e,t){let{x:r,y:i,z:n}=this.tileID.canonical,{x:a,y:s,z:o}=t.canonical,l=o-n,u=Of/2**l,c=(a*ye+e.anchorX)*u,d=(s*ye+e.anchorY)*u,h=r*ye*Of,f=i*ye*Of;return{x:Math.floor(c-h),y:Math.floor(d-f)}}
vendor: 4,446 bytes, lines 744-771
744findMatches(e,t,r){let i=this.tileID.canonical.z<t.canonical.z?1:2**(this.tileID.canonical.z-t.canonical.z);for(let n=0;n<e.length;n++){let a=e.get(n);if(a.crossTileID)continue;let s=this._symbolsByKey[a.key];if(!s)continue;let o=this.getScaledCoordinates(a,t);if(s.index){let l=s.index.range(o.x-i,o.y-i,o.x+i,o.y+i).sort();for(let u of l){let c=s.crossTileIDs[u];if(!r[c]){r[c]=!0,a.crossTileID=c;break}}}else if(s.positions)for(let l=0;l<s.positions.length;l++){let u=s.positions[l],c=s.crossTileIDs[l];if(Math.abs(u.x-o.x)<=i&&Math.abs(u.y-o.y)<=i&&!r[c]){r[c]=!0,a.crossTileID=c;break}}}}getCrossTileIDsLists(){return Object.values(this._symbolsByKey).map(({crossTileIDs:e})=>e)}},dIe=class{constructor(){this.maxCrossTileID=0}generate(){return++this.maxCrossTileID}},hIe=class{constructor(){this.indexes={},this.usedCrossTileIDs={},this.lng=0}handleWrapJump(e){let t=Math.round((e-this.lng)/360);if(t!==0)for(let r in this.indexes){let i=this.indexes[r],n={};for(let a in i){let s=i[a];s.tileID=s.tileID.unwrapTo(s.tileID.wrap+t),n[s.tileID.key]=s}this.indexes[r]=n}this.lng=e}addBucket(e,t,r){var n,a,s;if((n=this.indexes[e.overscaledZ])!=null&&n[e.key]){if(this.indexes[e.overscaledZ][e.key].bucketInstanceId===t.bucketInstanceId)return!1;this.removeBucketCrossTileIDs(e.overscaledZ,this.indexes[e.overscaledZ][e.key])}for(let o=0;o<t.symbolInstances.length;o++){let l=t.symbolInstances.get(o);l.crossTileID=0}(a=this.usedCrossTileIDs)[s=e.overscaledZ]||(a[s]={});let i=this.usedCrossTileIDs[e.overscaledZ];for(let o in this.indexes){let l=this.indexes[o];if(Number(o)>e.overscaledZ)for(let u in l){let c=l[u];c.tileID.isChildOf(e)&&c.findMatches(t.symbolInstances,e,i)}else{let u=l[e.scaledTo(Number(o)).key];u&&u.findMatches(t.symbolInstances,e,i)}}for(let o=0;o<t.symbolInstances.length;o++){let l=t.symbolInstances.get(o);l.crossTileID||(l.crossTileID=r.generate(),i[l.crossTileID]=!0)}return this.indexes[e.overscaledZ]===void 0&&(this.indexes[e.overscaledZ]={}),this.indexes[e.overscaledZ][e.key]=new cIe(e,t.symbolInstances,t.bucketInstanceId),!0}removeBucketCrossTileIDs(e,t){for(let r of t.getCrossTileIDsLists())for(let i of r)delete this.usedCrossTileIDs[e][i]}removeStaleBuckets(e){let t=!1;for(let r in this.indexes){let i=this.indexes[r];for(let n in i)e[i[n].bucketInstanceId]||(this.removeBucketCrossTileIDs(r,i[n]),delete i[n],t=!0)}return t}},NF=class{constructor(){this.layerIndexes={},this.crossTileIDs=new dIe,this.maxBucketInstanceId=0,this.bucketsInCurrentPlacement={}}addLayer(e,t,r){let i=this.layerIndexes[e.id];i===void 0&&(i=this.layerIndexes[e.id]=new hIe);let n=!1,a={};i.handleWrapJump(r);for(let s of t){let o=s.getBucket(e);e.id===(o==null?void 0:o.layerIds[0])&&(o.bucketInstanceId||(o.bucketInstanceId=(this.maxBucketInstanceId+=1,this.maxBucketInstanceId)),i.addBucket(s.tileID,o,this.crossTileIDs)&&(n=!0),a[o.bucketInstanceId]=!0)}return i.removeStaleBuckets(a)&&(n=!0),n}pruneUnusedLayers(e){let t={};for(let r of e)t[r]=!0;for(let r in this.layerIndexes)t[r]||delete this.layerIndexes[r]}},fIe=`#ifdef GL_ES 745precision mediump float; 746#else 747#if !defined(lowp) 748#define lowp 749#endif 750#if !defined(mediump) 751#define mediump 752#endif 753#if !defined(highp) 754#define highp 755#endif 756#endif 757out highp vec4 fragColor;`,pIe=`#ifdef GL_ES 758precision highp float; 759#else 760#if !defined(lowp) 761#define lowp 762#endif 763#if !defined(mediump) 764#define mediump 765#endif 766#if !defined(highp) 767#define highp 768#endif 769#endif 770vec2 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(unpack_float(encodedColor[0])/255.0,unpack_float(encodedColor[1])/255.0 771);}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);
771return (tile_units_to_pixels*pos+offset)/pattern_size;}mat3 rotationMatrixFromAxisAngle(vec3 u,float angle) {float c=cos(angle);float s=sin(angle);float c2=1.0-c;return mat3(u.x*u.x*c2+ c,u.x*u.y*c2-u.z*s,u.x*u.z*c2+u.y*s,u.y*u.x*c2+u.z*s,u.y*u.y*c2+ c,u.y*u.z*c2-u.x*s,u.z*u.x*c2-u.y*s,u.z*u.y*c2+u.x*s,u.z*u.z*c2+ c 772);} 773#ifdef TERRAIN3D 774uniform sampler2D u_terrain;uniform float u_terrain_dim;uniform mat4 u_terrain_matrix;uniform vec4 u_terrain_unpack;uniform float u_terrain_exaggeration;uniform highp sampler2D u_depth; 775#endif 776const highp vec4 bitSh=vec4(256.*256.*256.,256.*256.,256.,1.);const highp vec4 bitShifts=vec4(1.)/bitSh;highp float unpack(highp vec4 color) {return dot(color,bitShifts);}highp float depthOpacity(vec3 frag) { 777#ifdef TERRAIN3D 778highp float d=unpack(texture(u_depth,frag.xy*0.5+0.5))+0.0001-frag.z;return 1.0-max(0.0,min(1.0,-d*500.0)); 779#else 780return 1.0; 781#endif 782}float calculate_visibility(vec4 pos) { 783#ifdef TERRAIN3D 784vec3 frag=pos.xyz/pos.w;highp float d=depthOpacity(frag);if (d > 0.95) return 1.0;return (d+depthOpacity(frag+vec3(0.0,0.01,0.0)))/2.0; 785#else 786return 1.0; 787#endif 788}float ele(vec2 pos) { 789#ifdef TERRAIN3D 790vec4 rgb=(texture(u_terrain,pos)*255.0)*u_terrain_unpack;return rgb.r+rgb.g+rgb.b-u_terrain_unpack.a; 791#else 792return 0.0; 793#endif 794}float get_elevation(vec2 pos) { 795#ifdef TERRAIN3D 796#ifdef GLOBE 797if ((pos.y <-32767.5) || (pos.y > 32766.5)) {return 0.0;} 798#endif 799vec2 coord=(u_terrain_matrix*vec4(pos,0.0,1.0)).xy*u_terrain_dim+1.0;vec2 f=fract(coord);vec2 c=(floor(coord)+0.5)/(u_terrain_dim+2.0);float d=1.0/(u_terrain_dim+2.0);float tl=ele(c);float tr=ele(c+vec2(d,0.0));float bl=ele(c+vec2(0.0,d));float br=ele(c+vec2(d,d));float elevation=mix(mix(tl,tr,f.x),mix(bl,br,f.x),f.y);return elevation*u_terrain_exaggeration; 800#else 801return 0.0; 802#endif 803}const float PI=3.141592653589793;uniform mat4 u_projection_matrix;`,mIe=`uniform vec4 u_color;uniform float u_opacity;void main() {fragColor=u_color*u_opacity; 804#ifdef OVERDRAW_INSPECTOR 805fragColor=vec4(1.0); 806#endif 807}`,gIe="layout(location=0) in vec2 a_pos;void main() {gl_Position=projectTile(a_pos);}",_Ie=`uniform vec2 u_pattern_tl_a;uniform vec2 u_pattern_br_a;uniform vec2 u_pattern_tl_b;uniform vec2 u_pattern_br_b;uniform vec2 u_texsize;uniform float u_mix;uniform float u_opacity;uniform sampler2D u_image;in vec2 v_pos_a;in vec2 v_pos_b;void main() {vec2 imagecoord=mod(v_pos_a,1.0);vec2 pos=mix(u_pattern_tl_a/u_texsize,u_pattern_br_a/u_texsize,imagecoord);vec4 color1=texture(u_image,pos);vec2 imagecoord_b=mod(v_pos_b,1.0);vec2 pos2=mix(u_pattern_tl_b/u_texsize,u_pattern_br_b/u_texsize,imagecoord_b);vec4 color2=texture(u_image,pos2);fragColor=mix(color1,color2,u_mix)*u_opacity; 808#ifdef OVERDRAW_INSPECTOR 809fragColor=vec4(1.0); 810#endif 811}`,yIe="uniform vec2 u_pattern_size_a;uniform vec2 u_pattern_size_b;uniform vec2 u_pixel_coord_upper;uniform vec2 u_pixel_coord_lower;uniform float u_scale_a;uniform float u_scale_b;uniform float u_tile_units_to_pixels;layout(location=0) in vec2 a_pos;out vec2 v_pos_a;out vec2 v_pos_b;void main() {gl_Position=projectTile(a_pos);v_pos_a=get_pattern_pos(u_pixel_coord_upper,u_pixel_coord_lower,u_scale_a*u_pattern_size_a,u_tile_units_to_pixels,a_pos);v_pos_b=get_pattern_pos(u_pixel_coord_upper,u_pixel_coord_lower,u_scale_b*u_pattern_size_b,u_tile_units_to_pixels,a_pos);}",vIe=`in vec3 v_data;flat in float v_visibility; 812#pragma maplibre: define highp vec4 color 813#pragma maplibre: define mediump float radius 814#pragma maplibre: define lowp float blur 815#pragma maplibre: define lowp float opacity 816#pragma maplibre: define highp vec4 stroke_color 817#pragma maplibre: define mediump float stroke_width 818#pragma maplibre: define lowp float stroke_opacity 819void main() { 820#pragma maplibre: initialize highp vec4 color 821#pragma maplibre: initialize mediump float radius 822#pragma maplibre: initialize lowp float blur 823#pragma maplibre: initialize lowp float opacity 824#pragma maplibre: initialize highp vec4 stroke_color 825#pragma maplibre: initialize mediump float stroke_width 826#pragma maplibre: initialize lowp float stroke_opacity 827vec2 extrude=v_data.xy;float extrude_length=length(extrude);float antialiased_blur=v_data.z;float opacity_t=smoothstep(0.0,antialiased_blur,extrude_length-1.0);float color_t=stroke_width < 0.01 ? 0.0 : smoothstep(antialiased_blur,0.0,extrude_length-radius
827/(radius+stroke_width));fragColor=v_visibility*opacity_t*mix(color*opacity,stroke_color*stroke_opacity,color_t);const float epsilon=0.5/255.0;if (fragColor.r < epsilon && fragColor.g < epsilon && fragColor.b < epsilon && fragColor.a < epsilon) {discard;} 828#ifdef OVERDRAW_INSPECTOR 829fragColor=vec4(1.0); 830#endif 831}`,bIe=`uniform bool u_scale_with_map;uniform bool u_pitch_with_map;uniform vec2 u_extrude_scale;uniform highp float u_globe_extrude_scale;uniform lowp float u_device_pixel_ratio;uniform highp float u_camera_to_center_distance;uniform vec2 u_translate;layout(location=0) in vec2 a_pos;out vec3 v_data;flat out float v_visibility; 832#pragma maplibre: define highp vec4 color 833#pragma maplibre: define mediump float radius 834#pragma maplibre: define lowp float blur 835#pragma maplibre: define lowp float opacity 836#pragma maplibre: define highp vec4 stroke_color 837#pragma maplibre: define mediump float stroke_width 838#pragma maplibre: define lowp float stroke_opacity 839void main(void) { 840#pragma maplibre: initialize highp vec4 color 841#pragma maplibre: initialize mediump float radius 842#pragma maplibre: initialize lowp float blur 843#pragma maplibre: initialize lowp float opacity 844#pragma maplibre: initialize highp vec4 stroke_color 845#pragma maplibre: initialize mediump float stroke_width 846#pragma maplibre: initialize lowp float stroke_opacity 847vec2 pos_raw=a_pos+32768.0;vec2 extrude=vec2(mod(pos_raw,8.0)/7.0*2.0-1.0);vec2 circle_center=floor(pos_raw/8.0)+u_translate;float ele=get_elevation(circle_center);v_visibility=calculate_visibility(projectTileWithElevation(circle_center,ele));if (u_pitch_with_map) { 848#ifdef GLOBE 849vec3 center_vector=projectToSphere(circle_center); 850#endif 851float angle_scale=u_globe_extrude_scale;vec2 corner_position=circle_center;if (u_scale_with_map) {angle_scale*=(radius+stroke_width);corner_position+=extrude*u_extrude_scale*(radius+stroke_width);} else { 852#ifdef GLOBE 853vec4 projected_center=interpolateProjection(circle_center,center_vector,ele); 854#else 855vec4 projected_center=projectTileWithElevation(circle_center,ele); 856#endif 857corner_position+=extrude*u_extrude_scale*(radius+stroke_width)*(projected_center.w/u_camera_to_center_distance);angle_scale*=(radius+stroke_width)*(projected_center.w/u_camera_to_center_distance);} 858#ifdef GLOBE 859vec2 angles=extrude*angle_scale;vec3 corner_vector=globeRotateVector(center_vector,angles);gl_Position=interpolateProjection(corner_position,corner_vector,ele); 860#else 861gl_Position=projectTileWithElevation(corner_position,ele); 862#endif 863} else {gl_Position=projectTileWithElevation(circle_center,ele);if (gl_Position.z/gl_Position.w > 1.0) {gl_Position.xy=vec2(10000.0);}if (u_scale_with_map) {gl_Position.xy+=extrude*(radius+stroke_width)*u_extrude_scale*u_camera_to_center_distance;} else {gl_Position.xy+=extrude*(radius+stroke_width)*u_extrude_scale*gl_Position.w;}}float antialiasblur=-max(1.0/u_device_pixel_ratio/(radius+stroke_width),blur);v_data=vec3(extrude.x,extrude.y,antialiasblur);}`,vE="void main() {fragColor=vec4(1.0);}";const eo={prelude:Pt(fIe,pIe),projectionMercator:Pt(` 864void clipAntimeridian() {}`,"float projectLineThickness(float tileY) {return 1.0;}float projectCircleRadius(float tileY) {return 1.0;}vec4 projectTile(vec2 p) {vec4 result=u_projection_matrix*vec4(p,0.0,1.0);return result;}vec4 projectTile(vec2 p,vec2 rawPos) {vec4 result=u_projection_matrix*vec4(p,0.0,1.0);if (rawPos.y <-32767.5 || rawPos.y > 32766.5) {result.z=-10000000.0;}return result;}vec4 projectTileWithElevation(vec2 posInTile,float elevation) {return u_projection_matrix*vec4(posInTile,elevation,1.0);}vec4 projectTileFor3D(vec2 posInTile,float elevation) {return projectTileWithElevation(posInTile,elevation);}"),projectionGlobe:Pt("uniform bool u_projection_clip_antimeridian;in highp float v_projection_tile_x;void clipAntimeridian() {if (u_projection_clip_antimeridian && (v_projection_tile_x < 0.0 || v_projection_tile_x >=8192.0)) {discard;}}",`#define GLOBE_RADIUS 6371008.8 865uniform highp vec4 u_projection_tile_mercator_coords;uniform highp vec4 u_projection_clipping_plane;uniform highp float u_projection_transition;uniform mat4 u_projection_fallback_matrix;out highp float v_projection_tile_x;vec3 globeRotateVector(vec3 vec,vec2 angles) {vec3 axisRight=vec3(vec.z,0.0,-vec.x);vec3 axisUp=cross(axisRight,vec);axisRight=normalize(axisRight);axisUp=normalize(axisUp);vec2 t=tan(angles);return normalize(vec+axisRight*t.x+axisUp*t.y);}mat3 globeGetRotationMatrix(vec3 spherePos) {vec3 axisRight=vec3(spherePos.z,0.0,-spherePos.x);vec3 axisDown=cross(axisRight,spherePos);axisRight=normalize(axisRight);axisDown=normalize(axisDown);return mat3(axisRight,axisDown,spherePos 866);}float circumferenceRatioAtTileY(float tileY) {float mercator_pos_y=u_projection_tile_mercator_coords.y+u_projection_tile_mercator_coords.w*tileY;float t=exp(PI-(mercator_pos_y*PI*2.0));return (2.0*t)/(t*t+1.0);}float projectLineThickness(float tileY) {float thickness=1.0/circumferenceRatioAtTileY(tileY);if (u_projection_transition < 0.999) {return mix(1.0,thickness,u_projection_transition);} else {return thickness;}}vec3 projectToSphere(vec2 translatedPos,vec2 rawPos) {vec2 mercator_pos=u_projection_tile_mercator_coords.xy+u_projection_tile_mercator_coords.zw*translatedPos;float spherical_x=mercator_pos.x*PI*2.0+PI;float t=exp(PI-(mercator_pos.y*PI*2.0));
866float t2=t*t;float denom=t2+1.0;float sin_sy=(t2-1.0)/denom;float cos_sy=(2.0*t)/denom;vec3 pos=vec3(sin(spherical_x)*cos_sy,sin_sy,cos(spherical_x)*cos_sy 867);if (rawPos.y <-32767.5) {pos=vec3(0.0,1.0,0.0);}if (rawPos.y > 32766.5) {pos=vec3(0.0,-1.0,0.0);}return pos;}vec3 projectToSphere(vec2 posInTile) {return projectToSphere(posInTile,vec2(0.0,0.0));}float globeComputeClippingZ(vec3 spherePos) {return (1.0-(dot(spherePos,u_projection_clipping_plane.xyz)+u_projection_clipping_plane.w));}vec4 interpolateProjection(vec2 posInTile,vec3 spherePos,float elevation) {v_projection_tile_x=posInTile.x;vec3 elevatedPos=spherePos*(1.0+elevation/GLOBE_RADIUS);vec4 globePosition=u_projection_matrix*vec4(elevatedPos,1.0);globePosition.z=globeComputeClippingZ(elevatedPos)*globePosition.w;if (u_projection_transition > 0.999) {return globePosition;}vec4 flatPosition=u_projection_fallback_matrix*vec4(posInTile,elevation,1.0);const float z_globeness_threshold=0.2;vec4 result=globePosition;result.z=mix(0.0,globePosition.z,clamp((u_projection_transition-z_globeness_threshold)/(1.0-z_globeness_threshold),0.0,1.0));result.xyw=mix(flatPosition.xyw,globePosition.xyw,u_projection_transition);if ((posInTile.y <-32767.5) || (posInTile.y > 32766.5)) {result=globePosition;const float poles_hidden_anim_percentage=0.02;result.z=mix(globePosition.z,100.0,pow(max((1.0-u_projection_transition)/poles_hidden_anim_percentage,0.0),8.0));}return result;}vec4 interpolateProjectionFor3D(vec2 posInTile,vec3 spherePos,float elevation) {v_projection_tile_x=posInTile.x;vec3 elevatedPos=spherePos*(1.0+elevation/GLOBE_RADIUS);vec4 globePosition=u_projection_matrix*vec4(elevatedPos,1.0);if (u_projection_transition > 0.999) {return globePosition;}vec4 fallbackPosition=u_projection_fallback_matrix*vec4(posInTile,elevation,1.0);return mix(fallbackPosition,globePosition,u_projection_transition);}vec4 projectTile(vec2 posInTile) {return interpolateProjection(posInTile,projectToSphere(posInTile),0.0);}vec4 projectTile(vec2 posInTile,vec2 rawPos) {return interpolateProjection(posInTile,projectToSphere(posInTile,rawPos),0.0);}vec4 projectTileWithElevation(vec2 posInTile,float elevation) {return interpolateProjection(posInTile,projectToSphere(posInTile),elevation);}vec4 projectTileFor3D(vec2 posInTile,float elevation) {vec3 spherePos=projectToSphere(posInTile,posInTile);return interpolateProjectionFor3D(posInTile,spherePos,elevation);}`),background:Pt(mIe,gIe),backgroundPattern:Pt(_Ie,yIe),circle:Pt(vIe,bIe),clippingMask:Pt(vE,"layout(location=0) in vec2 a_pos;void main() {gl_Position=projectTile(a_pos);}"),heatmap:Pt(`uniform highp float u_intensity;in vec2 v_extrude; 868#pragma maplibre: define highp float weight 869#define GAUSS_COEF 0.3989422804014327 870void main() { 871#pragma maplibre: initialize highp float weight 872float d=-0.5*3.0*3.0*dot(v_extrude,v_extrude);float val=weight*u_intensity*GAUSS_COEF*exp(d);fragColor=vec4(val,1.0,1.0,1.0); 873#ifdef OVERDRAW_INSPECTOR 874fragColor=vec4(1.0); 875#endif 876}`,`uniform float u_extrude_scale;uniform float u_opacity;uniform float u_intensity;uniform highp float u_globe_extrude_scale;layout(location=0) in vec2 a_pos;out vec2 v_extrude; 877#pragma maplibre: define highp float weight 878#pragma maplibre: define mediump float radius 879const highp float ZERO=1.0/255.0/16.0; 880#define GAUSS_COEF 0.3989422804014327 881void main(void) { 882#pragma maplibre: initialize highp float weight 883#pragma maplibre: initialize mediump float radius 884vec2 pos_raw=a_pos+32768.0;vec2 unscaled_extrude=vec2(mod(pos_raw,8.0)/7.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 circle_center=floor(pos_raw/8.0); 885#ifdef GLOBE 886vec2 angles=v_extrude*radius*u_globe_extrude_scale;vec3 center_vector=projectToSphere(circle_center);vec3 corner_vector=globeRotateVector(center_vector,angles);gl_Position=interpolateProjection(circle_center+extrude,corner_vector,0.0); 887#else 888gl_Position=projectTileFor3D(circle_center+extrude,get_elevation(circle_center)); 889#endif 890}`),heatmapTexture:Pt(`uniform sampler2D u_image;uniform sampler2D u_color_ramp;uniform float u_opacity;in vec2 v_pos;void main() {float t=texture(u_image,v_pos).r;vec4 color=texture(u_color_ramp,vec2(t,0.5));fragColor=color*u_opacity; 891#ifdef OVERDRAW_INSPECTOR 892fragColor=vec4(0.0); 893#endif 894}`,"uniform mat4 u_matrix;uniform vec2 u_world;layout(location=0) in vec2 a_pos;out vec2 v_pos;void main() {gl_Position=u_matrix*vec4(a_pos*u_world,0,1);v_pos.x=a_pos.x;v_pos.y=1.0-a_pos.y;}"),collisionBox:Pt("flat in float v_placed;flat in float v_notUsed;void main() {float alpha=0.5;fragColor=vec4(1.0,0.0,0.0,1.0)*alpha;if (v_placed > 0.5) {fragColor=vec4(0.0,0.0,1.0,0.5)*alpha;}if (v_notUsed > 0.5) {fragColor*=.1;}}","layout(location=0) in vec2 a_anchor_pos;layout(location=1) in vec2 a_placed;layout(location=2) in vec2 a_box_real;uniform vec2 u_pixel_extrude_scale;flat out float v_placed;flat out float v_notUsed;void main() {gl_Position=projectTileWithElevation(a_anchor_pos,get_elevation(a_anchor_pos));gl_Position.xy=((a_box_real+0.5)*u_pixel_extrude_scale*2.0-1.0)*vec2(1.0,-1.0)*gl_Position.w;if (gl_Position.z/gl_Position.w < 1.1) {gl_Position.z=0.5;}v_placed=a_placed.x;v_notUsed=a_placed.y;}"),collisionCircle:Pt("flat in float v_radius;in vec2 v_extrude;flat in float v_collision;void main() {float alpha=0.5;float stroke_radius=0.9;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);fragColor=color*alpha*opacity_t;}","layout(location=0) in vec2 a_pos;layout(location=1) in float a_radius;layout(location=2) in vec2 a_flags;uniform vec2 u_viewport_size;flat out float v_radius;out vec2 v_extrude;flat out float v_collision;void main() {float radius=a_radius;float collision=a_flags.x;float vertexIdx=a_flags.y;vec2 quadVertexOffset=vec2(mix(-1.0,1.0,float(vertexIdx >=2.0)),mix(-1.0,1.0,float(vertexIdx >=1.0 && vertexIdx <=2.0)));vec2 quadVertexExtent=quadVertexOffset*radius;float padding_factor=1.2;v_radius=radius;v_extrude=quadVertexExtent*padding_factor;v_collision=collision;gl_Position=vec4((a_pos/u_viewport_size*2.0-1.0)*vec2(1.0,-1.0),0.0,1.0)+vec4(quadVertexExtent*padding_factor/u_viewport_size*2.0,0.0,0.0);}"),colorRelief:Pt(`#ifdef GL_ES 895precision highp float; 896#endif 897uniform sampler2D u_image;uniform vec4 u_unpack;uniform sampler2D u_elevation_stops;uniform sampler2D u_color_stops;uniform int u_color_ramp_size;uniform float u_opacity;in vec2 v_pos;float getElevation(vec2 coord) {vec4 data=texture(u_image,coord)*255.0;data.a=-1.0;return dot(data,u_unpack);}float getElevationStop(int stop) {float x=(float(stop)+0.5)/float(u_color_ramp_size);vec4 data=texture(u_elevation_stops,vec2(x,0))*255.0;data.a=-1.0;return dot(data,u_unpack);}void main() {float el=getElevation(v_pos);int r=(u_color_ramp_size-1);int l=0;float el_l=getElevationStop(l);float el_r=getElevationStop(r);while(r-l > 1){int m=(r+l)/2;float el_m=getElevationStop(m);if(el < el_m){r=m;el_r=el_m;}else 898{l=m;el_l=el_m;}}float x=(float(l)+(el-el_l)/(el_r-el_l)+0.5)/float(u_color_ramp_size);fragColor=u_opacity*texture(u_color_stops,vec2(x,0)); 899#ifdef OVERDRAW_INSPECTOR 900fragColor=vec4(1.0); 901#endif 902}`,"uniform vec2 u_dimension;layout(location=0) in vec2 a_pos;out vec2 v_pos;void main() {gl_Position=projectTile(a_pos,a_pos);highp vec2 epsilon=1.0/u_dimension;float scale=(u_dimension.x-2.0)/u_dimension.x;v_pos=(a_pos/8192.0)*scale+epsilon;if (a_pos.y <-32767.5) {v_pos.y=0.0;}if (a_pos.y > 32766.5) {v_pos.y=1.0;}}"),debug:Pt("uniform highp vec4 u_color;uniform sampler2D u_overlay;in vec2 v_uv;void main() {vec4 overlay_color=texture(u_overlay,v_uv);fragColor=mix(u_color,overlay_color,overlay_color.a);}","layout(location=0) in vec2 a_pos;out vec2 v_uv;uniform float u_overlay_scale;void main() {v_uv=a_pos/8192.0;gl_Position=projectTileWithElevation(a_pos*u_overlay_scale,get_elevation(a_pos));}"),depth:Pt(vE,`layout(location=0) in vec2 a_pos;void main() { 903#ifdef GLOBE 904gl_Position=projectTileFor3D(a_pos,0.0); 905#else 906gl_Position=u_projection_matrix*vec4(a_pos,0.0,1.0); 907#endif 908}`),fill:Pt(`#pragma maplibre: define highp vec4 color 909#pragma maplibre: define lowp float opacity 910void main() { 911#pragma maplibre: initialize highp vec4 color 912#pragma maplibre: initialize lowp float opacity 913fragColor=color*opacity; 914#ifdef OVERDRAW_INSPECTOR 915fragColor=vec4(1.0); 916#endif 917}`,`uniform vec2 u_fill_translate;layout(location=0) in vec2 a_pos; 918#pragma maplibre: define highp vec4 color 919#pragma maplibre: define lowp float opacity 920void main() { 921#pragma maplibre: initialize highp vec4 color 922#pragma maplibre: initialize lowp float opacity 923if (opacity < 0.01) {gl_Position=vec4(-2.0,-2.0,-2.0,1.0);return;}gl_Position=projectTile(a_pos+u_fill_translate,a_pos);}`),fillOutline:Pt(`in vec2 v_pos; 924#ifdef GLOBE 925in float v_depth; 926#endif 927#pragma maplibre: define highp vec4 outline_color 928#pragma maplibre: define lowp float opacity 929void main() { 930#pragma maplibre: initialize highp vec4 outline_color 931#pragma maplibre: initialize lowp float opacity 932float dist=length(v_pos-gl_FragCoord.xy);float alpha=1.0-smoothstep(0.0,1.0,dist);fragColor=outline_color*(alpha*opacity); 933#ifdef GLOBE 934if (v_depth > 1.0) {discard;} 935#endif 936#ifdef OVERDRAW_INSPECTOR 937fragColor=vec4(1.0); 938#endif 939}`,`uniform vec2 u_world;uniform vec2 u_fill_translate;layout(location=0) in vec2 a_pos;out vec2 v_pos; 940#ifdef GLOBE 941out float v_depth; 942#endif 943#pragma maplibre: define highp vec4 outline_color 944#pragma maplibre: define lowp float opacity 945void main() { 946#pragma maplibre: initialize highp vec4 outline_color 947#pragma maplibre: initialize lowp float opacity 948if (opacity < 0.01) {gl_Position=vec4(-2.0,-2.0,-2.0,1.0);return;}gl_Position=projectTile(a_pos+u_fill_translate,a_pos);v_pos=(gl_Position.xy/gl_Position.w+1.0)/2.0*u_world; 949#ifdef GLOBE 950v_depth=gl_Position.z/gl_Position.w; 951#endif 952}`),fillOutlinePattern:Pt(`uniform vec2 u_texsize;uniform sampler2D u_image;uniform float u_fade;in vec2 v_pos_a;in vec2 v_pos_b;in vec2 v_pos; 953#ifdef GLOBE 954in float v_depth; 955#endif 956#pragma maplibre: define lowp float opacity 957#pragma maplibre: define lowp vec4 pattern_from 958#pragma maplibre: define lowp vec4 pattern_to 959void main() { 960#pragma maplibre: initialize lowp float opacity 961#pragma maplibre: initialize mediump vec4 pattern_from 962#pragma maplibre: initialize mediump vec4 pattern_to 963vec2 pattern_tl_a=pattern_from.xy;vec2 pattern_br_a=pattern_from.zw;vec2 pattern_tl_b=pattern_to.xy;vec2 pattern_br_b=pattern_to.zw;vec2 imagecoord=mod(v_pos_a,1.0);vec2 pos=mix(pattern_tl_a/u_texsize,pattern_br_a/u_texsize,imagecoord);vec4 color1=texture(u_image,pos);vec2 imagecoord_b=mod(v_pos_b,1.0);vec2 pos2=mix(pattern_tl_b/u_texsize,pattern_br_b/u_texsize,imagecoord_b);vec4 color2=texture(u_image,pos2);float dist=length(v_pos-gl_FragCoord.xy);float alpha=1.0-smoothstep(0.0,1.0,dist);fragColor=mix(color1,color2,u_fade)*alpha*opacity; 964#ifdef GLOBE 965if (v_depth > 1.0) {discard;} 966#endif 967#ifdef OVERDRAW_INSPECTOR 968fragColor=vec4(1.0); 969#endif 970}`,`uniform vec2 u_world;uniform vec2 u_pixel_coord_upper;uniform vec2 u_pixel_coord_lower;uniform vec3 u_scale;uniform vec2 u_fill_translate;layout(location=0) in vec2 a_pos;out vec2 v_pos_a;out vec2 v_pos_b;out vec2 v_pos; 971#ifdef GLOBE 972out float v_depth; 973#endif 974#pragma maplibre: define lowp float opacity 975#pragma maplibre: define lowp vec4 pattern_from 976#pragma maplibre: define lowp vec4 pattern_to 977#pragma maplibre: define lowp float pixel_ratio_from 978#pragma maplibre: define lowp float pixel_ratio_to 979void main() { 980#pragma maplibre: initialize lowp float opacity 981#pragma maplibre: initialize mediump vec4 pattern_from 982#pragma maplibre: initialize mediump vec4 pattern_to 983#pragma maplibre: initialize lowp float pixel_ratio_from 984#pragma maplibre: initialize lowp float pixel_ratio_to 985if (opacity < 0.01) {gl_Position=vec4(-2.0,-2.0,-2.0,1.0);return;}vec2 pattern_tl_a=pattern_from.xy;vec2 pattern_br_a=pattern_from.zw;vec2 pattern_tl_b=pattern_to.xy;vec2 pattern_br_b=pattern_to.zw;float tileRatio=u_scale.x;float fromScale=u_scale.y;float toScale=u_scale.z;gl_Position=projectTile(a_pos+u_fill_translate,a_pos);vec2 display_size_a=(pattern_br_a-pattern_tl_a)/pixel_ratio_from;vec2 display_size_b=(pattern_br_b-pattern_tl_b)/pixel_ratio_to;v_pos_a=get_pattern_pos(u_pixel_coord_upper,u_pixel_coord_lower,fromScale*display_size_a,tileRatio,a_pos);v_pos_b=get_pattern_pos(u_pixel_coord_upper,u_pixel_coord_lower,toScale*display_size_b,tileRatio,a_pos);v_pos=(gl_Position.xy/gl_Position.w+1.0)/2.0*u_world; 986#ifdef GLOBE 987v_depth=gl_Position.z/gl_Position.w; 988#endif 989}`),fillPattern:Pt(`#ifdef GL_ES 990precision highp float; 991#endif 992uniform vec2 u_texsize;uniform float u_fade;uniform sampler2D u_image;in vec2 v_pos_a;in vec2 v_pos_b; 993#pragma maplibre: define lowp float opacity 994#pragma maplibre: define lowp vec4 pattern_from 995#pragma maplibre: define lowp vec4 pattern_to 996void main() { 997#pragma maplibre: initialize lowp float opacity 998#pragma maplibre: initialize mediump vec4 pattern_from 999#pragma maplibre: initialize mediump vec4 pattern_to 1000vec2 pattern_tl_a=pattern_from.xy;vec2 pattern_br_a=pattern_from.zw;vec2 pattern_tl_b=pattern_to.xy;vec2 pattern_br_b=pattern_to.zw;vec2 imagecoord=mod(v_pos_a,1.0);vec2 pos=mix(pattern_tl_a/u_texsize,pattern_br_a/u_texsize,imagecoord);vec4 color1=texture(u_image,pos);vec2 imagecoord_b=mod(v_pos_b,1.0);vec2 pos2=mix(pattern_tl_b/u_texsize,pattern_br_b/u_texsize,imagecoord_b);vec4 color2=texture(u_image,pos2);fragColor=mix(color1,color2,u_fade)*opacity; 1001#ifdef OVERDRAW_INSPECTOR 1002fragColor=vec4(1.0); 1003#endif 1004}`,`uniform vec2 u_pixel_coord_upper;uniform vec2 u_pixel_coord_lower;uniform vec3 u_scale;uniform vec2 u_fill_translate;layout(location=0) in vec2 a_pos;out vec2 v_pos_a;out vec2 v_pos_b; 1005#pragma maplibre: define lowp float opacity 1006#pragma maplibre: define lowp vec4 pattern_from 1007#pragma maplibre: define lowp vec4 pattern_to 1008#pragma maplibre: define lowp float pixel_ratio_from 1009#pragma maplibre: define lowp float pixel_ratio_to 1010void main() { 1011#pragma maplibre: initialize lowp float opacity 1012#pragma maplibre: initialize mediump vec4 pattern_from 1013#pragma maplibre: initialize mediump vec4 pattern_to 1014#pragma maplibre: initialize lowp float pixel_ratio_from 1015#pragma maplibre: initialize lowp float pixel_ratio_to 1016if (opacity < 0.01) {gl_Position=vec4(-2.0,-2.0,-2.0,1.0);return;}vec2 pattern_tl_a=pattern_from.xy;vec2 pattern_br_a=pattern_from.zw;vec2 pattern_tl_b=pattern_to.xy;vec2 pattern_br_b=pattern_to.zw;float tileZoomRatio=u_scale.x;float fromScale=u_scale.y;float toScale=u_scale.z;vec2 display_size_a=(pattern_br_a-pattern_tl_a)/pixel_ratio_from;vec2 display_size_b=(pattern_br_b-pattern_tl_b)/pixel_ratio_to;gl_Position=projectTile(a_pos+u_fill_translate,a_pos);v_pos_a=get_pattern_pos(u_pixel_coord_upper,u_pixel_coord_lower,fromScale*display_size_a,tileZoomRatio,a_pos);v_pos_b=get_pattern_pos(u_pixel_coord_upper,u_pixel_coord_lower,toScale*display_size_b,tileZoomRatio,a_pos);}`),fillExtrusion:Pt(`in vec4 v_color;void main() {fragColor=v_color; 1017#ifdef OVERDRAW_INSPECTOR 1018fragColor=vec4(1.0); 1019#endif 1020}`,`uniform vec3 u_lightcolor;uniform lowp vec3 u_lightpos;uniform lowp vec3 u_lightpos_globe;uniform lowp float u_lightintensity;uniform float u_vertical_gradient;uniform lowp float u_opacity;uniform vec2 u_fill_translate;layout(location=0) in vec2 a_pos;layout(location=1) in vec4 a_normal_ed; 1021#ifdef TERRAIN3D 1022layout(location=2) in vec2 a_centroid; 1023#endif 1024out vec4 v_color; 1025#pragma maplibre: define highp float base 1026#pragma maplibre: define highp float height 1027#pragma maplibre: define highp vec4 color 1028void main() { 1029#pragma maplibre: initialize highp float base 1030#pragma maplibre: initialize highp float height 1031#pragma maplibre: initialize highp vec4 color 1032vec3 normal=a_normal_ed.xyz; 1033#ifdef TERRAIN3D 1034float height_terrain3d_offset=get_elevation(a_centroid);float base_terrain3d_offset=height_terrain3d_offset-(base > 0.0 ? 0.0 : 10.0); 1035#else 1036float height_terrain3d_offset=0.0;float base_terrain3d_offset=0.0; 1037#endif 1038base=max(0.0,base)+base_terrain3d_offset;height=max(0.0,height)+height_terrain3d_offset;float t=mod(normal.x,2.0);float elevation=t > 0.0 ? height : base;vec2 posInTile=a_pos+u_fill_translate; 1039#ifdef GLOBE 1040vec3 spherePos=projectToSphere(posInTile,a_pos);gl_Position=interpolateProject
1040ionFor3D(posInTile,spherePos,elevation); 1041#else 1042gl_Position=u_projection_matrix*vec4(posInTile,elevation,1.0); 1043#endif 1044float colorvalue=color.r*0.2126+color.g*0.7152+color.b*0.0722;v_color=vec4(0.0,0.0,0.0,1.0);vec4 ambientlight=vec4(0.03,0.03,0.03,1.0);color+=ambientlight;vec3 normalForLighting=normal/16384.0;float directional=clamp(dot(normalForLighting,u_lightpos),0.0,1.0); 1045#ifdef GLOBE 1046mat3 rotMatrix=globeGetRotationMatrix(spherePos);normalForLighting=rotMatrix*normalForLighting;directional=mix(directional,clamp(dot(normalForLighting,u_lightpos_globe),0.0,1.0),u_projection_transition); 1047#endif 1048directional=mix((1.0-u_lightintensity),max((1.0-colorvalue+u_lightintensity),1.0),directional);if (normal.y !=0.0) {directional*=((1.0-u_vertical_gradient)+(u_vertical_gradient*clamp((t+base)*pow(height/150.0,0.5),mix(0.7,0.98,1.0-u_lightintensity),1.0)));}v_color.r+=clamp(color.r*directional*u_lightcolor.r,mix(0.0,0.3,1.0-u_lightcolor.r),1.0);v_color.g+=clamp(color.g*directional*u_lightcolor.g,mix(0.0,0.3,1.0-u_lightcolor.g),1.0);v_color.b+=clamp(color.b*directional*u_lightcolor.b,mix(0.0,0.3,1.0-u_lightcolor.b),1.0);v_color*=u_opacity;}`),fillExtrusionPattern:Pt(`uniform vec2 u_texsize;uniform float u_fade;uniform sampler2D u_image;in vec2 v_pos_a;in vec2 v_pos_b;in vec4 v_lighting; 1049#pragma maplibre: define lowp float base 1050#pragma maplibre: define lowp float height 1051#pragma maplibre: define lowp vec4 pattern_from 1052#pragma maplibre: define lowp vec4 pattern_to 1053#pragma maplibre: define lowp float pixel_ratio_from 1054#pragma maplibre: define lowp float pixel_ratio_to 1055void main() { 1056#pragma maplibre: initialize lowp float base 1057#pragma maplibre: initialize lowp float height 1058#pragma maplibre: initialize mediump vec4 pattern_from 1059#pragma maplibre: initialize mediump vec4 pattern_to 1060#pragma maplibre: initialize lowp float pixel_ratio_from 1061#pragma maplibre: initialize lowp float pixel_ratio_to 1062vec2 pattern_tl_a=pattern_from.xy;vec2 pattern_br_a=pattern_from.zw;vec2 pattern_tl_b=pattern_to.xy;vec2 pattern_br_b=pattern_to.zw;vec2 imagecoord=mod(v_pos_a,1.0);vec2 pos=mix(pattern_tl_a/u_texsize,pattern_br_a/u_texsize,imagecoord);vec4 color1=texture(u_image,pos);vec2 imagecoord_b=mod(v_pos_b,1.0);vec2 pos2=mix(pattern_tl_b/u_texsize,pattern_br_b/u_texsize,imagecoord_b);vec4 color2=texture(u_image,pos2);vec4 mixedColor=mix(color1,color2,u_fade);fragColor=mixedColor*v_lighting; 1063#ifdef OVERDRAW_INSPECTOR 1064fragColor=vec4(1.0); 1065#endif 1066}`,`uniform vec2 u_pixel_coord_upper;uniform vec2 u_pixel_coord_lower;uniform float u_height_factor;uniform vec3 u_scale;uniform float u_vertical_gradient;uniform lowp float u_opacity;uniform vec2 u_fill_translate;uniform vec3 u_lightcolor;uniform lowp vec3 u_lightpos;uniform lowp vec3 u_lightpos_globe;uniform lowp float u_lightintensity;layout(location=0) in vec2 a_pos;layout(location=1) in vec4 a_normal_ed; 1067#ifdef TERRAIN3D 1068layout(location=2) in vec2 a_centroid; 1069#endif 1070#ifdef GLOBE 1071out vec3 v_sphere_pos; 1072#endif 1073out vec2 v_pos_a;out vec2 v_pos_b;out vec4 v_lighting; 1074#pragma maplibre: define lowp float base 1075#pragma maplibre: define lowp float height 1076#pragma maplibre: define lowp vec4 pattern_from 1077#pragma maplibre: define lowp vec4 pattern_to 1078#pragma maplibre: define lowp float pixel_ratio_from 1079#pragma maplibre: define lowp float pixel_ratio_to 1080void main() { 1081#pragma maplibre: initialize lowp float base 1082#pragma maplibre: initialize lowp float height 1083#pragma maplibre: initialize mediump vec4 pattern_from 1084#pragma maplibre: initialize mediump vec4 pattern_to 1085#pragma maplibre: initialize lowp float pixel_ratio_from 1086#pragma maplibre: initialize lowp float pixel_ratio_to 1087vec2 pattern_tl_a=pattern_from.xy;vec2 pattern_br_a=pattern_from.zw;vec2 pattern_tl_b=pattern_to.xy;vec2 pattern_br_b=pattern_to.zw;float tileRatio=u_scale.x;float fromScale=u_scale.y;float toScale=u_scale.z;vec3 normal=a_normal_ed.xyz;float edgedistance=a_normal_ed.w;vec2 display_size_a=(pattern_br_a-pattern_tl_a)/pixel_ratio_from;vec2 display_size_b=(pattern_br_b-pattern_tl_b)/pixel_ratio_to; 1088#ifdef TERRAIN3D 1089float height_terrain3d_offset=get_elevation(a_centroid);float base_terrain3d_offset=height_terrain3d_offset-(base > 0.0 ? 0.0 : 10.0); 1090#else 1091float height_terrain3d_offset=0.0;float base_terrain3d_offset=0.0; 1092#endif 1093base=max(0.0,base)+base_terrain3d_offset;height=max(0.0,height)+height_terrain3d_offset;float t=mod(normal.x,2.0);float elevation=t > 0.0 ? height : base;vec2 posInTile=a_pos+u_fill_translate; 1094#ifdef GLOBE 1095vec3 spherePos=projectToSphere(posInTile,a_pos);vec3 elevatedPos=spherePos*(1.0+elevation/GLOBE_RADIUS);v_sphere_pos=elevatedPos;gl_Position=interpolateProjectionFor3D(posInTile,spherePos,elevation); 1096#else 1097gl_Position=u_projection_matrix*vec4(posInTile,elevation,1.0); 1098#endif 1099vec2 pos=normal.x==1.0 && normal.y==0.0 && normal.z==16384.0 1100? a_pos 1101: vec2(edgedistance,elevation*u_height_factor);v_pos_a=get_pattern_pos(u_pixel_coord_upper,u_pixel_coord_lower,fromScale*display_size_a,tileRatio,pos);v_pos_b=get_pattern_pos(u_pixel_coord_upper,u_pixel_coord_lower,toScale*display_size_b,tileRatio,pos);v_lighting=vec4(0.0,0.0,0.0,1.0);float directional=clamp(dot(normal/16383.0,u_lightpos),0.0,1.0);directional=mix((1.0-u_lightintensity),max((0.5+u_lightintensity),1.0),directional);if (normal.y !=0.0) {directional*=((1.0-u_vertical_gradient)+(u_vertical_gradient*clamp((t+base)*pow(height/150.0,0.5),mix(0.7,0.98,1.0-u_lightintensity),1.0)));}v_lighting.rgb+=clamp(directional*u_lightcolor,mix(vec3(0.0),vec3(0.3),1.0-u_lightcolor),vec3(1.0));v_lighting*=u_opacity;}`),hillshadePrepare:Pt(`#ifdef GL_ES 1102precision highp float; 1103#endif 1104uniform sampler2D u_image;in vec2 v_pos;uniform vec2 u_dimension;uniform float u_zoom;uniform vec4 u_unpack;float getElevation(vec2 coord,float bias) {vec4 data=texture(u_image,coord)*255.0;data.a=-1.0;return dot(data,u_unpack);}void main() {vec2 epsilon=1.0/u_dimension;float tileSize=u_dimension.x-2.0;float a=getElevation(v_pos+vec2(-epsilon.x,-epsilon.y),0.0);float b=getElevation(v_pos+vec2(0,-epsilon.y),0.0);float c=getElevation(v_pos+vec2(epsilon.x,-epsilon.y),0.0);float d=getElevation(v_pos+vec2(-epsilon.x,0),0.0);float e=getElevation(v_pos,0.0);float f=getElevation(v_pos+vec2(epsilon.x,0),0.0);float g=getElevation(v_pos+vec2(-epsilon.x,epsilon.y),0.0);float h=getElevation(v_pos+vec2(0,epsilon.y),0.0);float i=getElevation(v_pos+vec2(epsilon.x,epsilon.y),0.0);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((c+f+f+i)-(a+d+d+g),(g+h+h+i)-(a+b+b+c))*tileSize/p
1104ow(2.0,exaggeration+(28.2562-u_zoom));fragColor=clamp(vec4(deriv.x/8.0+0.5,deriv.y/8.0+0.5,1.0,1.0),0.0,1.0); 1105#ifdef OVERDRAW_INSPECTOR 1106fragColor=vec4(1.0); 1107#endif 1108}`,"uniform mat4 u_matrix;uniform vec2 u_dimension;layout(location=0) in vec2 a_pos;layout(location=1) in vec2 a_texture_pos;out 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:Pt(`uniform sampler2D u_image;in vec2 v_pos;uniform vec2 u_latrange;uniform float u_exaggeration;uniform vec4 u_accent;uniform int u_method;uniform float u_altitudes[NUM_ILLUMINATION_SOURCES];uniform float u_azimuths[NUM_ILLUMINATION_SOURCES];uniform vec4 u_shadows[NUM_ILLUMINATION_SOURCES];uniform vec4 u_highlights[NUM_ILLUMINATION_SOURCES]; 1109#define PI 3.141592653589793 1110#define STANDARD 0 1111#define COMBINED 1 1112#define IGOR 2 1113#define MULTIDIRECTIONAL 3 1114#define BASIC 4 1115float get_aspect(vec2 deriv){return deriv.x !=0.0 ? atan(deriv.y,-deriv.x) : PI/2.0*(deriv.y > 0.0 ? 1.0 :-1.0);}void igor_hillshade(vec2 deriv){deriv=deriv*u_exaggeration*2.0;float aspect=get_aspect(deriv);float azimuth=u_azimuths[0]+PI;float slope_stength=atan(length(deriv))*2.0/PI;float aspect_strength=1.0-abs(mod((aspect+azimuth)/PI+0.5,2.0)-1.0);float shadow_strength=slope_stength*aspect_strength;float highlight_strength=slope_stength*(1.0-aspect_strength);fragColor=u_shadows[0]*shadow_strength+u_highlights[0]*highlight_strength;}void standard_hillshade(vec2 deriv){float azimuth=u_azimuths[0]+PI;float slope=atan(0.625*length(deriv));float aspect=get_aspect(deriv);float intensity=u_exaggeration;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_shadows[0],u_highlights[0],shade)*sin(scaledSlope)*clamp(intensity*2.0,0.0,1.0);fragColor=accent_color*(1.0-shade_color.a)+shade_color;}void basic_hillshade(vec2 deriv){deriv=deriv*u_exaggeration*2.0;float azimuth=u_azimuths[0]+PI;float cos_az=cos(azimuth);float sin_az=sin(azimuth);float cos_alt=cos(u_altitudes[0]);float sin_alt=sin(u_altitudes[0]);float cang=(sin_alt-(deriv.y*cos_az*cos_alt-deriv.x*sin_az*cos_alt))/sqrt(1.0+dot(deriv,deriv));float shade=clamp(cang,0.0,1.0);if(shade > 0.5){fragColor=u_highlights[0]*(2.0*shade-1.0);}else 1116{fragColor=u_shadows[0]*(1.0-2.0*shade);}}void multidirectional_hillshade(vec2 deriv){deriv=deriv*u_exaggeration*2.0;fragColor=vec4(0,0,0,0);for(int i=0; i < NUM_ILLUMINATION_SOURCES; i++){float cos_alt=cos(u_altitudes[i]);float sin_alt=sin(u_altitudes[i]);float cos_az=-cos(u_azimuths[i]);float sin_az=-sin(u_azimuths[i]);float cang=(sin_alt-(deriv.y*cos_az*cos_alt-deriv.x*sin_az*cos_alt))/sqrt(1.0+dot(deriv,deriv));float shade=clamp(cang,0.0,1.0);if(shade > 0.5){fragColor+=u_highlights[i]*(2.0*shade-1.0)/float(NUM_ILLUMINATION_SOURCES);}else 1117{fragColor+=u_shadows[i]*(1.0-2.0*shade)/float(NUM_ILLUMINATION_SOURCES);}}}void combined_hillshade(vec2 deriv){deriv=deriv*u_exaggeration*2.0;float azimuth=u_azimuths[0]+PI;float cos_az=cos(azimuth);float sin_az=sin(azimuth);float cos_alt=cos(u_altitudes[0]);float sin_alt=sin(u_altitudes[0]);float cang=acos((sin_alt-(deriv.y*cos_az*cos_alt-deriv.x*sin_az*cos_alt))/sqrt(1.0+dot(deriv,deriv)));cang=clamp(cang,0.0,PI/2.0);float shade=cang*atan(length(deriv))*4.0/PI/PI;float highlight=(PI/2.0-cang)*atan(length(deriv))*4.0/PI/PI;fragColor=u_shadows[0]*shade+u_highlights[0]*highlight;}void main() {vec4 pixel=texture(u_image,v_pos);float scaleFactor=cos(radians((u_latrange[0]-u_latrange[1])*(1.0-v_pos.y)+u_latrange[1]));vec2 deriv=((pixel.rg*8.0)-4.0)/scaleFactor;if (u_method==BASIC) {basic_hillshade(deriv);} else if (u_method==COMBINED) {combined_hillshade(deriv);} else if (u_method==IGOR) {igor_hillshade(deriv);} else if (u_method==MULTIDIRECTIONAL) {multidirectional_hillshade(deriv);} else if (u_method==STANDARD) {standard_hillshade(deriv);} else {standard_hillshade(deriv);} 1118#ifdef OVERDRAW_INSPECTOR 1119fragColor=vec4(1.0); 1120#endif 1121}`,"uniform mat4 u_matrix;layout(location=0) in vec2 a_pos;out vec2 v_pos;void main() {gl_Position=projectTile(a_pos,a_pos);v_pos=a_pos/8192.0;if (a_pos.y <-32767.5) {v_pos.y=0.0;}if (a_pos.y > 32766.5) {v_pos.y=1.0;}}"),line:Pt(`uniform lowp float u_device_pixel_ratio;flat in vec2 v_width2;in vec2 v_normal;in float v_gamma_scale; 1122#ifdef GLOBE 1123in float v_depth; 1124#endif 1125#pragma maplibre: define highp vec4 color 1126#pragma maplibre: define lowp float blur 1127#pragma maplibre: define lowp float opacity 1128void main() { 1129#pragma maplibre: initialize highp vec4 color 1130#pragma maplibre: initialize lowp float blur 1131#pragma maplibre: initialize lowp float opacity 1132clipAntimeridian();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);fragColor=color*(alpha*opacity); 1133#ifdef GLOBE 1134if (v_depth > 1.0) {discard;} 1135#endif 1136#ifdef OVERDRAW_INSPECTOR 1137fragColor=vec4(1.0); 1138#endif 1139}`,` 1140#define scale 0.015873016 1141layout(location=0) in vec2 a_pos_normal;layout(location=1) in vec4 a_data;uniform vec2 u_translation;uniform mediump float u_ratio;uniform vec2 u_units_to_pixels;uniform lowp float u_device_pixel_ratio;out vec2 v_normal;flat out vec2 v_width2;out float v_gamma_scale;out highp float v_linesofar; 1142#ifdef GLOBE 1143out float v_depth; 1144#endif 1145#pragma maplibre: define highp vec4 color 1146#pragma maplibre: define lowp float blur 1147#pragma maplibre: define lowp float opacity 1148#pragma maplibre: define mediump float gapwidth 1149#pragma maplibre: define lowp float offset 1150#pragma maplibre: define mediump float width 1151void main() { 1152#pragma maplibre: initialize highp vec4 color 1153#pragma maplibre: initialize lowp float blur 1154#pragma maplibre: initialize lowp float opacity 1155#pragma maplibre: initialize mediump float gapwidth 1156#pragma maplibre: initialize lowp float offset 1157#pragma maplibre: initialize mediump float width 1158if (opacity < 0.01) {gl_Position=vec4(-2.0,-2.0,-2.0,1.0);return;}float 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;v_linesofar=(floor(a_data.z/4.0)+a_data.w*64.0)*2.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);
1158float adjustedThickness=projectLineThickness(pos.y);vec4 projected_no_extrude=projectTile(pos+offset2/u_ratio*adjustedThickness+u_translation);vec4 projected_with_extrude=projectTile(pos+offset2/u_ratio*adjustedThickness+u_translation+dist/u_ratio*adjustedThickness);gl_Position=projected_with_extrude; 1159#ifdef GLOBE 1160v_depth=gl_Position.z/gl_Position.w; 1161#endif 1162#ifdef TERRAIN3D 1163v_gamma_scale=1.0; 1164#else 1165float extrude_length_without_perspective=length(dist);float extrude_length_with_perspective=length((projected_with_extrude.xy-projected_no_extrude.xy)/projected_with_extrude.w*u_units_to_pixels);v_gamma_scale=extrude_length_without_perspective/extrude_length_with_perspective; 1166#endif 1167v_width2=vec2(outset,inset);}`),lineGradient:Pt(`uniform lowp float u_device_pixel_ratio;uniform sampler2D u_image;flat in vec2 v_width2;in vec2 v_normal;in float v_gamma_scale;in highp vec2 v_uv; 1168#ifdef GLOBE 1169in float v_depth; 1170#endif 1171#pragma maplibre: define lowp float blur 1172#pragma maplibre: define lowp float opacity 1173void main() { 1174#pragma maplibre: initialize lowp float blur 1175#pragma maplibre: initialize lowp float opacity 1176clipAntimeridian();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);vec4 color=texture(u_image,v_uv);fragColor=color*(alpha*opacity); 1177#ifdef GLOBE 1178if (v_depth > 1.0) {discard;} 1179#endif 1180#ifdef OVERDRAW_INSPECTOR 1181fragColor=vec4(1.0); 1182#endif 1183}`,` 1184#define scale 0.015873016 1185layout(location=0) in vec2 a_pos_normal;layout(location=1) in vec4 a_data;layout(location=2) in float a_uv_x;layout(location=3) in float a_split_index;uniform vec2 u_translation;uniform mediump float u_ratio;uniform lowp float u_device_pixel_ratio;uniform vec2 u_units_to_pixels;uniform float u_image_height;out vec2 v_normal;flat out vec2 v_width2;out float v_gamma_scale;out highp vec2 v_uv; 1186#ifdef GLOBE 1187out float v_depth; 1188#endif 1189#pragma maplibre: define lowp float blur 1190#pragma maplibre: define lowp float opacity 1191#pragma maplibre: define mediump float gapwidth 1192#pragma maplibre: define lowp float offset 1193#pragma maplibre: define mediump float width 1194void main() { 1195#pragma maplibre: initialize lowp float blur 1196#pragma maplibre: initialize lowp float opacity 1197#pragma maplibre: initialize mediump float gapwidth 1198#pragma maplibre: initialize lowp float offset 1199#pragma maplibre: initialize mediump float width 1200if (opacity < 0.01) {gl_Position=vec4(-2.0,-2.0,-2.0,1.0);return;}float 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;highp float texel_height=1.0/u_image_height;highp float half_texel_height=0.5*texel_height;v_uv=vec2(a_uv_x,a_split_index*texel_height-half_texel_height);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);float adjustedThickness=projectLineThickness(pos.y);vec4 projected_no_extrude=projectTile(pos+offset2/u_ratio*adjustedThickness+u_translation);vec4 projected_with_extrude=projectTile(pos+offset2/u_ratio*adjustedThickness+u_translation+dist/u_ratio*adjustedThickness);gl_Position=projected_with_extrude; 1201#ifdef GLOBE 1202v_depth=gl_Position.z/gl_Position.w; 1203#endif 1204#ifdef TERRAIN3D 1205v_gamma_scale=1.0; 1206#else 1207float extrude_length_without_perspective=length(dist);float extrude_length_with_perspective=length((projected_with_extrude.xy-projected_no_extrude.xy)/projected_with_extrude.w*u_units_to_pixels);v_gamma_scale=extrude_length_without_perspective/extrude_length_with_perspective; 1208#endif 1209v_width2=vec2(outset,inset);}`),linePattern:Pt(`#ifdef GL_ES 1210precision highp float; 1211#endif 1212uniform lowp float u_device_pixel_ratio;uniform vec2 u_texsize;uniform float u_fade;uniform mediump vec3 u_scale;uniform sampler2D u_image;in vec2 v_normal;flat in vec2 v_width2;in float v_linesofar;in float v_gamma_scale;flat in float v_width; 1213#ifdef GLOBE 1214in float v_depth; 1215#endif 1216#pragma maplibre: define lowp vec4 pattern_from 1217#pragma maplibre: define lowp vec4 pattern_to 1218#pragma maplibre: define lowp float pixel_ratio_from 1219#pragma maplibre: define lowp float pixel_ratio_to 1220#pragma maplibre: define lowp float blur 1221#pragma maplibre: define lowp float opacity 1222void main() { 1223#pragma maplibre: initialize mediump vec4 pattern_from 1224#pragma maplibre: initialize mediump vec4 pattern_to 1225#pragma maplibre: initialize lowp float pixel_ratio_from 1226#pragma maplibre: initialize lowp float pixel_ratio_to 1227#pragma maplibre: initialize lowp float blur 1228#pragma maplibre: initialize lowp float opacity 1229clipAntimeridian();vec2 pattern_tl_a=pattern_from.xy;vec2 pattern_br_a=pattern_from.zw;vec2 pattern_tl_b=pattern_to.xy;vec2 pattern_br_b=pattern_to.zw;float tileZoomRatio=u_scale.x;float fromScale=u_scale.y;float toScale=u_scale.z;vec2 display_size_a=(pattern_br_a-pattern_tl_a)/pixel_ratio_from;vec2 display_size_b=(pattern_br_b-pattern_tl_b)/pixel_ratio_to;vec2 pattern_size_a=vec2(display_size_a.x*fromScale/tileZoomRatio,display_size_a.y);vec2 pattern_size_b=vec2(display_size_b.x*toScale/tileZoomRatio,display_size_b.y);float aspect_a=display_size_a.y/v_width;float aspect_b=display_size_b.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_a=mod(v_linesofar/pattern_size_a.x*aspect_a,1.0);float x_b=mod(v_linesofar/pattern_size_b.x*aspect_b,1.0);float y=0.5*v_normal.y+0.5;vec2 texel_size=1.0/u_texsize;vec2 pos_a=mix(pattern_tl_a*texel_size-texel_size,pattern_br_a*texel_size+texel_size,vec2(x_a,y));vec2 pos_b=mix(pattern_tl_b*texel_size-texel_size,pattern_br_b*texel_size+texel_size,vec2(x_b,y));vec4 color=mix(texture(u_image,pos_a),texture(u_image,pos_b),u_fade);fragColor=color*alpha*opacity; 1230#ifdef GLOBE 1231if (v_depth > 1.0) {discard;} 1232#endif 1233#ifdef OVERDRAW_INSPECTOR 1234fragColor=vec4(1.0); 1235#endif 1236}`,` 1237#define scale 0.015873016 1238#define LINE_DISTANCE_SCALE 2.0 1239layout(location=0) in vec2 a_pos_normal;layout(location=1) in vec4 a_data;uniform vec2 u_translation;uniform vec2 u_units_to_pixels;uniform mediump float u_ratio;uniform lowp float u_device_pixel_ratio;out vec2 v_normal;flat out vec2 v_width2;out float v_linesofar;out float v_gamma_scale;flat out float v_width; 1240#ifdef GLOBE 1241out float v_depth; 1242#endif 1243#pragma maplibre: define lowp float blur 1244#pragma maplibre: define lowp float opacity 1245#pragma maplibre: define lowp float offset 1246#pragma maplibre: define mediump float gapwidth 1247#pragma maplibre: define mediump float width 1248#pragma maplibre: define lowp float floorwidth 1249#pragma maplibre: define lowp vec4 pattern_from 1250#pragma maplibre: define lowp vec4 pattern_to 1251#pragma maplibre: define lowp float pixel_ratio_from 1252#pragma maplibre: define lowp float pixel_ratio_to 1253void main() { 1254#pragma maplibre: initialize lowp float blur 1255#pragma maplibre: initialize lowp float opacity 1256#pragma maplibre: initialize lowp float offset 1257#pragma maplibre: initialize mediump float gapwidth 1258#pragma maplibre: initialize mediump float width 1259#pragma maplibre: initialize lowp float floorwidth 1260#pragma maplibre: initialize mediump vec4 pattern_from 1261#pragma maplibre: initialize mediump vec4 pattern_to 1262#pragma maplibre: initialize lowp float pixel_ratio_from 1263#pragma maplibre: initialize lowp float pixel_ratio_to 1264if (opacity < 0.01) {gl_Position=vec4(-2.0,-2.0,-2.0,1.0);return;}float 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;float a_linesofar=(floor(a_data.z/4.0)+a_data.w*64.0)*LINE_DISTANCE_SCALE;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);
1264float adjustedThickness=projectLineThickness(pos.y);vec4 projected_no_extrude=projectTile(pos+offset2/u_ratio*adjustedThickness+u_translation);vec4 projected_with_extrude=projectTile(pos+offset2/u_ratio*adjustedThickness+u_translation+dist/u_ratio*adjustedThickness);gl_Position=projected_with_extrude; 1265#ifdef GLOBE 1266v_depth=gl_Position.z/gl_Position.w; 1267#endif 1268#ifdef TERRAIN3D 1269v_gamma_scale=1.0; 1270#else 1271float extrude_length_without_perspective=length(dist);float extrude_length_with_perspective=length((projected_with_extrude.xy-projected_no_extrude.xy)/projected_with_extrude.w*u_units_to_pixels);v_gamma_scale=extrude_length_without_perspective/extrude_length_with_perspective; 1272#endif 1273v_linesofar=a_linesofar;v_width2=vec2(outset,inset);v_width=floorwidth;}`),lineSDF:Pt(`uniform lowp float u_device_pixel_ratio;uniform lowp float u_lineatlas_width;uniform sampler2D u_image;uniform float u_mix;in vec2 v_normal;flat in vec2 v_width2;in vec2 v_tex_a;in vec2 v_tex_b;in float v_gamma_scale; 1274#ifdef GLOBE 1275in float v_depth; 1276#endif 1277#pragma maplibre: define highp vec4 color 1278#pragma maplibre: define lowp float blur 1279#pragma maplibre: define lowp float opacity 1280#pragma maplibre: define mediump float width 1281#pragma maplibre: define lowp float floorwidth 1282#pragma maplibre: define mediump vec4 dasharray_from 1283#pragma maplibre: define mediump vec4 dasharray_to 1284void main() { 1285#pragma maplibre: initialize highp vec4 color 1286#pragma maplibre: initialize lowp float blur 1287#pragma maplibre: initialize lowp float opacity 1288#pragma maplibre: initialize mediump float width 1289#pragma maplibre: initialize lowp float floorwidth 1290#pragma maplibre: initialize mediump vec4 dasharray_from 1291#pragma maplibre: initialize mediump vec4 dasharray_to 1292clipAntimeridian();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 sdfdist_a=texture(u_image,v_tex_a).a;float sdfdist_b=texture(u_image,v_tex_b).a;float sdfdist=mix(sdfdist_a,sdfdist_b,u_mix);
1292float sdfgamma=(u_lineatlas_width/256.0/u_device_pixel_ratio)/min(dasharray_from.w,dasharray_to.w);alpha*=smoothstep(0.5-sdfgamma/floorwidth,0.5+sdfgamma/floorwidth,sdfdist);fragColor=color*(alpha*opacity); 1293#ifdef GLOBE 1294if (v_depth > 1.0) {discard;} 1295#endif 1296#ifdef OVERDRAW_INSPECTOR 1297fragColor=vec4(1.0); 1298#endif 1299}`,` 1300#define scale 0.015873016 1301#define LINE_DISTANCE_SCALE 2.0 1302layout(location=0) in vec2 a_pos_normal;layout(location=1) in vec4 a_data;uniform vec2 u_translation;uniform mediump float u_ratio;uniform lowp float u_device_pixel_ratio;uniform vec2 u_units_to_pixels;uniform float u_tileratio;uniform float u_crossfade_from;uniform float u_crossfade_to;uniform float u_lineatlas_height;out vec2 v_normal;flat out vec2 v_width2;out vec2 v_tex_a;out vec2 v_tex_b;out float v_gamma_scale; 1303#ifdef GLOBE 1304out float v_depth; 1305#endif 1306#pragma maplibre: define highp vec4 color 1307#pragma maplibre: define lowp float blur 1308#pragma maplibre: define lowp float opacity 1309#pragma maplibre: define mediump float gapwidth 1310#pragma maplibre: define lowp float offset 1311#pragma maplibre: define mediump float width 1312#pragma maplibre: define lowp float floorwidth 1313#pragma maplibre: define mediump vec4 dasharray_from 1314#pragma maplibre: define mediump vec4 dasharray_to 1315void main() { 1316#pragma maplibre: initialize highp vec4 color 1317#pragma maplibre: initialize lowp float blur 1318#pragma maplibre: initialize lowp float opacity 1319#pragma maplibre: initialize mediump float gapwidth 1320#pragma maplibre: initialize lowp float offset 1321#pragma maplibre: initialize mediump float width 1322#pragma maplibre: initialize lowp float floorwidth 1323#pragma maplibre: initialize mediump vec4 dasharray_from 1324#pragma maplibre: initialize mediump vec4 dasharray_to 1325if (opacity < 0.01) {gl_Position=vec4(-2.0,-2.0,-2.0,1.0);return;}float 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;float a_linesofar=(floor(a_data.z/4.0)+a_data.w*64.0)*LINE_DISTANCE_SCALE;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);float adjustedThickness=projectLineThickness(pos.y);vec4 projected_no_extrude=projectTile(pos+offset2/u_ratio*adjustedThickness+u_translation);vec4 projected_with_extrude=projectTile(pos+offset2/u_ratio*adjustedThickness+u_translation+dist/u_ratio*adjustedThickness);gl_Position=projected_with_extrude; 1326#ifdef GLOBE 1327v_depth=gl_Position.z/gl_Position.w; 1328#endif 1329#ifdef TERRAIN3D 1330v_gamma_scale=1.0; 1331#else 1332float extrude_length_without_perspective=length(dist);float extrude_length_with_perspective=length((projected_with_extrude.xy-projected_no_extrude.xy)/projected_with_extrude.w*u_units_to_pixels);v_gamma_scale=extrude_length_without_perspective/extrude_length_with_perspective; 1333#endif 1334float u_patternscale_a_x=u_tileratio/dasharray_from.w/u_crossfade_from;float u_patternscale_a_y=-dasharray_from.z/2.0/u_lineatlas_height;float u_patternscale_b_x=u_tileratio/dasharray_to.w/u_crossfade_to;float u_patternscale_b_y=-dasharray_to.z/2.0/u_lineatlas_height;v_tex_a=vec2(a_linesofar*u_patternscale_a_x/floorwidth,normal.y*u_patternscale_a_y+(float(dasharray_from.y)+0.5)/u_lineatlas_height);v_tex_b=vec2(a_linesofar*u_patternscale_b_x/floorwidth,normal.y*u_patternscale_b_y+(float(dasharray_to.y)+0.5)/u_lineatlas_height);v_width2=vec2(outset,inset);}`),lineGradientSDF:Pt(`uniform lowp float u_device_pixel_ratio;uniform sampler2D u_image;uniform sampler2D u_image_dash;uniform float u_mix;uniform lowp float u_lineatlas_width;in vec2 v_normal;flat in vec2 v_width2;in vec2 v_tex_a;in vec2 v_tex_b;in float v_gamma_scale;in highp vec2 v_uv; 1335#ifdef GLOBE 1336in float v_depth; 1337#endif 1338#pragma maplibre: define lowp float blur 1339#pragma maplibre: define lowp float opacity 1340#pragma maplibre: define mediump float width 1341#pragma maplibre: define lowp float floorwidth 1342#pragma maplibre: define mediump vec4 dasharray_from 1343#pragma maplibre: define mediump vec4 dasharray_to 1344void main() { 1345#pragma maplibre: initialize lowp float blur 1346#pragma maplibre: initialize lowp float opacity 1347#pragma maplibre: initialize mediump float width 1348#pragma maplibre: initialize lowp float floorwidth 1349#pragma maplibre: initialize mediump vec4 dasharray_from 1350#pragma maplibre: initialize mediump vec4 dasharray_to 1351clipAntimeridian();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);vec4 color=texture(u_image,v_uv);float sdfdist_a=texture(u_image_dash,v_tex_a).a;float sdfdist_b=texture(u_image_dash,v_tex_b).a;float sdfdist=mix(sdfdist_a,sdfdist_b,u_mix);
1351float sdfgamma=(u_lineatlas_width/256.0)/min(dasharray_from.w,dasharray_to.w);float dash_alpha=smoothstep(0.5-sdfgamma/floorwidth,0.5+sdfgamma/floorwidth,sdfdist);fragColor=color*(alpha*dash_alpha*opacity); 1352#ifdef GLOBE 1353if (v_depth > 1.0) {discard;} 1354#endif 1355#ifdef OVERDRAW_INSPECTOR 1356fragColor=vec4(1.0); 1357#endif 1358}`,` 1359#define scale 0.015873016 1360#define LINE_DISTANCE_SCALE 2.0 1361layout(location=0) in vec2 a_pos_normal;layout(location=1) in vec4 a_data;layout(location=2) in float a_uv_x;layout(location=3) in float a_split_index;uniform vec2 u_translation;uniform mediump float u_ratio;uniform lowp float u_device_pixel_ratio;uniform vec2 u_units_to_pixels;uniform float u_image_height;uniform float u_tileratio;uniform float u_crossfade_from;uniform float u_crossfade_to;uniform float u_lineatlas_height;out vec2 v_normal;flat out vec2 v_width2;out float v_gamma_scale;out highp vec2 v_uv;out vec2 v_tex_a;out vec2 v_tex_b; 1362#ifdef GLOBE 1363out float v_depth; 1364#endif 1365#pragma maplibre: define lowp float blur 1366#pragma maplibre: define lowp float opacity 1367#pragma maplibre: define mediump float gapwidth 1368#pragma maplibre: define lowp float offset 1369#pragma maplibre: define mediump float width 1370#pragma maplibre: define lowp float floorwidth 1371#pragma maplibre: define mediump vec4 dasharray_from 1372#pragma maplibre: define mediump vec4 dasharray_to 1373void main() { 1374#pragma maplibre: initialize lowp float blur 1375#pragma maplibre: initialize lowp float opacity 1376#pragma maplibre: initialize mediump float gapwidth 1377#pragma maplibre: initialize lowp float offset 1378#pragma maplibre: initialize mediump float width 1379#pragma maplibre: initialize lowp float floorwidth 1380#pragma maplibre: initialize mediump vec4 dasharray_from 1381#pragma maplibre: initialize mediump vec4 dasharray_to 1382if (opacity < 0.01) {gl_Position=vec4(-2.0,-2.0,-2.0,1.0);return;}float 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;float a_linesofar=(floor(a_data.z/4.0)+a_data.w*64.0)*LINE_DISTANCE_SCALE;float texel_height=1.0/u_image_height;float half_texel_height=0.5*texel_height;v_uv=vec2(a_uv_x,a_split_index*texel_height-half_texel_height);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);float adjustedThickness=projectLineThickness(pos.y);vec4 projected_no_extrude=projectTile(pos+offset2/u_ratio*adjustedThickness+u_translation);vec4 projected_with_extrude=projectTile(pos+offset2/u_ratio*adjustedThickness+u_translation+dist/u_ratio*adjustedThickness);gl_Position=projected_with_extrude; 1383#ifdef GLOBE 1384v_depth=gl_Position.z/gl_Position.w; 1385#endif 1386#ifdef TERRAIN3D 1387v_gamma_scale=1.0; 1388#else 1389float extrude_length_without_perspective=length(dist);float extrude_length_with_perspective=length((projected_with_extrude.xy-projected_no_extrude.xy)/projected_with_extrude.w*u_units_to_pixels);v_gamma_scale=extrude_length_without_perspective/extrude_length_with_perspective; 1390#endif 1391float u_patternscale_a_x=u_tileratio/dasharray_from.w/u_crossfade_from;float u_patternscale_a_y=-dasharray_from.z/2.0/u_lineatlas_height;float u_patternscale_b_x=u_tileratio/dasharray_to.w/u_crossfade_to;float u_patternscale_b_y=-dasharray_to.z/2.0/u_lineatlas_height;v_tex_a=vec2(a_linesofar*u_patternscale_a_x/floorwidth,normal.y*u_patternscale_a_y+(float(dasharray_from.y)+0.5)/u_lineatlas_height);v_tex_b=vec2(a_linesofar*u_patternscale_b_x/floorwidth,normal.y*u_patternscale_b_y+(float(dasharray_to.y)+0.5)/u_lineatlas_height);v_width2=vec2(outset,inset);}`),layerOpacity:Pt(`uniform sampler2D u_image;uniform float u_opacity;in vec2 v_pos;void main() {fragColor=texture(u_image,v_pos)*u_opacity; 1392#ifdef OVERDRAW_INSPECTOR 1393fragColor=vec4(0.0); 1394#endif 1395}`,"layout(location=0) in vec2 a_pos;out vec2 v_pos;void main() {gl_Position=vec4(a_pos.x*2.0-1.0,1.0-a_pos.y*2.0,0.0,1.0);v_pos.x=a_pos.x;v_pos.y=1.0-a_pos.y;}"),raster:Pt(`uniform float u_fade_t;uniform float u_opacity;uniform sampler2D u_image0;uniform sampler2D u_image1;in vec2 v_pos0;in 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=texture(u_image0,v_pos0);vec4 color1=texture(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(dot(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);fragColor=vec4(mix(u_high_vec,u_low_vec,rgb)*color.a,color.a); 1396#ifdef OVERDRAW_INSPECTOR 1397fragColor=vec4(1.0); 1398#endif 1399}`,`uniform vec2 u_tl_parent;uniform float u_scale_parent;uniform float u_buffer_scale;uniform vec4 u_coords_top;uniform vec4 u_coords_bottom;layout(location=0) in vec2 a_pos;out vec2 v_pos0;out vec2 v_pos1;void main() {vec2 fractionalPos=a_pos/8192.0;vec2 position=mix(mix(u_coords_top.xy,u_coords_top.zw,fractionalPos.x),mix(u_coords_bottom.xy,u_coords_bottom.zw,fractionalPos.x),fractionalPos.y);gl_Position=projectTile(position,position);v_pos0=((fractionalPos-0.5)/u_buffer_scale)+0.5; 1400#ifdef GLOBE 1401if (a_pos.y <-32767.5) {v_pos0.y=0.0;}if (a_pos.y > 32766.5) {v_pos0.y=1.0;} 1402#endif 1403v_pos1=(v_pos0*u_scale_parent)+u_tl_parent;}`),symbolIcon:Pt(`uniform sampler2D u_texture;in vec2 v_tex;flat in float v_total_opacity;void main() {fragColor=texture(u_texture,v_tex)*v_total_opacity; 1404#ifdef OVERDRAW_INSPECTOR 1405fragColor=vec4(1.0); 1406#endif 1407}`,`layout(location=0) in vec4 a_pos_offset;layout(location=1) in vec4 a_data;layout(location=2) in vec4 a_pixeloffset;layout(location=3) in vec3 a_projected_pos;layout(location=4) in float a_fade_opacity;uniform 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 highp float u_pitch;uniform bool u_rotate_symbol;uniform highp float u_aspect_ratio;uniform float u_fade_change;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 bool u_is_along_line;uniform bool u_is_variable_anchor;uniform vec2 u_translation;uniform float u_pitched_scale;uniform bool u_is_offset;out vec2 v_tex;flat out float v_total_opacity; 1408#pragma maplibre: define lowp float opacity 1409void main() { 1410#pragma maplibre: initialize lowp float opacity 1411vec2 a_pos=a_pos_offset.xy;vec2 a_offset=a_pos_offset.zw;vec2 a_tex=a_data.xy;vec2 a_size=a_data.zw;float a_size_min=floor(a_size[0]*0.5);vec2 a_pxoffset=a_pixeloffset.xy;vec2 a_minFontScale=a_pixeloffset.zw/256.0;float ele=get_elevation(a_pos);highp float segment_angle=-a_projected_pos[2];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 translated_a_pos=a_pos+u_translation;vec4 projectedPoint=projectTileWithElevation(translated_a_pos,ele);vec2 fade_opacity=unpack_opacity(a_fade_opacity);float fade_change=fade_opacity[1] > 0.5 ? u_fade_change :-u_fade_change;float visibility=calculate_visibility(projectedPoint);v_total_opacity=opacity*max(0.0,min(visibility,fade_opacity[0]+fade_change));if (v_total_opacity < 0.1){gl_Position=vec4(-2.,-2.,-2.,1.);return;}highp float camera_to_anchor_distance=projectedPoint.w;highp float distance_ratio=u_pitch_with_map ? 1412camera_to_anchor_distance/u_camera_to_center_distance : 1413u_camera_to_center_distance/camera_to_anchor_distance;highp float perspective_ratio=clamp(0.5+0.5*distance_ratio,0.0,4.0);if (!u_is_offset) {size*=perspective_ratio;}float fontScale=u_is_text ? size/24.0 : size;highp float symbol_rotation=0.0;if (u_rotate_symbol) {vec4 offsetProjectedPoint=projectTileWithElevation(translated_a_pos+vec2(1,0),ele);vec2 a=projectedPoint.xy/projectedPoint.w;vec2 b=offsetProjectedPoint.xy/offsetProjectedPoint.w;symbol_rotation=atan((b.y-a.y)/u_aspect_ratio,b.x-a.x);}highp 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);vec4 projected_pos;if (u_is_along_line || u_is_variable_anchor) {projected_pos=vec4(a_projected_pos.xy,ele,1.0);} else if (u_pitch_with_map) {projected_pos=u_label_plane_matrix*vec4(a_projected_pos.xy+u_translation,ele,1.0);} else {projected_pos=u_label_plane_matrix*projectTileWithElevation(a_projected_pos.xy+u_translation,ele);}float z=float(u_pitch_with_map)*projected_pos.z/projected_pos.w;float projectionScaling=1.0; 1414#ifdef GLOBE 1415if(u_pitch_with_map) {float anchor_pos_tile_y=(u_coord_matrix*vec4(projected_pos.xy/projected_pos.w,z,1.0)).y;projectionScaling=mix(projectionScaling,1.0/circumferenceRatioAtTileY(anchor_pos_tile_y)*u_pitched_scale,u_projection_transition);} 1416#endif 1417vec4 finalPos=u_coord_matrix*vec4(projected_pos.xy/projected_pos.w+rotation_matrix*(a_offset/32.0*max(a_minFontScale,fontScale)+a_pxoffset/16.0)*projectionScaling,z,1.0);if(u_pitch_with_map) {finalPos=projectTileWithElevation(finalPos.xy,finalPos.z);}gl_Position=finalPos;v_tex=a_tex/u_texsize;}`),symbolSDF:Pt(`#define SDF_PX 8.0 1418uniform bool u_is_halo;uniform bool u_is_plain;uniform sampler2D u_texture;uniform highp float u_gamma_scale;uniform lowp float u_device_pixel_ratio;uniform bool u_is_text;in vec2 v_data0;in vec3 v_data1; 1419#pragma maplibre: define highp vec4 fill_color 1420#pragma maplibre: define highp vec4 halo_color 1421#pragma maplibre: define lowp float halo_width 1422#pragma maplibre: define lowp float halo_blur 1423void main() { 1424#pragma maplibre: initialize highp vec4 fill_color 1425#pragma maplibre: initialize highp vec4 halo_color 1426#pragma maplibre: initialize lowp float halo_width 1427#pragma maplibre: initialize lowp float halo_blur 1428float 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 total_opacity=v_data1[2];float fontScale=u_is_text ? size/24.0 : size;highp float gamma=EDGE_GAMMA/(fontScale*u_gamma_scale);lowp float inner_edge=(256.0-64.0)/256.0;lowp float dist=texture(u_texture,tex).a;lowp vec4 color_alpha_out_text,color_alpha_out_halo;if (u_is_plain){highp float gamma_scaled=gamma*gamma_scale;highp float alpha=smoothstep(inner_edge-gamma_scaled,inner_edge+gamma_scaled,dist);color_alpha_out_text=total_opacity*alpha*fill_color;}if (u_is_halo) {float gamma_halo=(halo_blur*1.19/SDF_PX+EDGE_GAMMA)/(fontScale*u_gamma_scale);float inner_edge_halo=inner_edge+gamma_halo*gamma_scale;highp float gamma_scaled_halo=gamma_halo*gamma_scale;highp float alpha_halo=smoothstep(inner_edge_halo-gamma_scaled_halo,inner_edge_halo+gamma_scaled_halo,dist);highp float halo_edge=(6.0-halo_width/fontScale)/SDF_PX;alpha_halo= min(smoothstep(halo_edge-gamma_scaled_halo,halo_edge+gamma_scaled_halo,dist),1.0-alpha_halo);color_alpha_out_halo=total_opacity*alpha_halo*halo_color;}if (u_is_plain && u_is_halo) {fragColor=color_alpha_out_text+(1.-color_alpha_out_text.a)*color_alpha_out_halo;} else if (u_is_halo){fragColor=color_alpha_out_halo;} else {fragColor=color_alpha_out_text;} 1429#ifdef OVERDRAW_INSPECTOR 1430fragColor=vec4(1.0); 1431#endif 1432}`,`layout(location=0) in vec4 a_pos_offset;layout(location=1) in vec4 a_data;layout(location=2) in vec4 a_pixeloffset;layout(location=3) in vec3 a_projected_pos;layout(location=4) in float a_fade_opacity;uniform 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_label_plane_matrix;uniform mat4 u_coord_matrix;uniform bool u_is_text;uniform bool u_pitch_with_map;uniform bool u_is_along_line;uniform bool u_is_variable_anchor;uniform highp float u_pitch;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 vec2 u_translation;uniform float u_pitched_scale;uniform bool u_is_offset;out vec2 v_data0;out vec3 v_data1; 1433#pragma maplibre: define highp vec4 fill_color 1434#pragma maplibre: define highp vec4 halo_color 1435#pragma maplibre: define lowp float opacity 1436#pragma maplibre: define lowp float halo_width 1437#pragma maplibre: define lowp float halo_blur 1438void main() { 1439#pragma maplibre: initialize highp vec4 fill_color 1440#pragma maplibre: initialize highp vec4 halo_color 1441#pragma maplibre: initialize lowp float opacity 1442#pragma maplibre: initialize lowp float halo_width 1443#pragma maplibre: initialize lowp float halo_blur 1444vec2 a_pos=a_pos_offset.xy;vec2 a_offset=a_pos_offset.zw;vec2 a_tex=a_data.xy;vec2 a_size=a_data.zw;float a_size_min=floor(a_size[0]*0.5);vec2 a_pxoffset=a_pixeloffset.xy/16.0;vec2 a_minFontScale=a_pixeloffset.zw/256.0;float ele=get_elevation(a_pos);highp float segment_angle=-a_projected_pos[2];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 translated_a_pos=a_pos+u_translation;vec4 projectedPoint=projectTileWithElevation(translated_a_pos,ele);vec2 fade_opacity=unpack_opacity(a_fade_opacity);float visibility=calculate_visibility(projectedPoint);float fade_change=fade_opacity[1] > 0.5 ? u_fade_change :-u_fade_change;float interpolated_fade_opacity=max(0.0,min(visibility,fade_opacity[0]+fade_change));float total_opacity=opacity*interpolated_fade_opacity;if (total_opacity < 0.1){gl_Position=vec4(-2.,-2.,-2.,1.);return;}highp float camera_to_anchor_distance=projectedPoint.w;highp float distance_ratio=u_pitch_with_map ? 1445camera_to_anchor_distance/u_camera_to_center_distance : 1446u_camera_to_center_distance/camera_to_anchor_distance;highp float perspective_ratio=clamp(0.5+0.5*distance_ratio,0.0,4.0);if (!u_is_offset) {size*=perspective_ratio;}float fontScale=u_is_text ? size/24.0 : size;highp float symbol_rotation=0.0;if (u_rotate_symbol) {vec4 offsetProjectedPoint=projectTileWithElevation(translated_a_pos+vec2(1,0),ele);vec2 a=projectedPoint.xy/projectedPoint.w;vec2 b=offsetProjectedPoint.xy/offsetProjectedPoint.w;symbol_rotation=atan((b.y-a.y)/u_aspect_ratio,b.x-a.x);}highp 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);vec4 projected_pos;if (u_is_along_line || u_is_variable_anchor) {projected_pos=vec4(a_projected_pos.xy,ele,1.0);} else if (u_pitch_with_map) {projected_pos=u_label_plane_matrix*vec4(a_projected_pos.xy+u_translation,ele,1.0);} else {projected_pos=u_label_plane_matrix*projectTileWithElevation(a_projected_pos.xy+u_translation,ele);}float z=float(u_pitch_with_map)*projected_pos.z/projected_pos.w;float projectionScaling=1.0; 1447#ifdef GLOBE 1448if(u_pitch_with_map) {float anchor_pos_tile_y=(u_coord_matrix*vec4(projected_pos.xy/projected_pos.w,z,1.0)).y;projectionScaling=mix(projectionScaling,1.0/circumferenceRatioAtTileY(anchor_pos_tile_y)*u_pitched_scale,u_projection_transition);} 1449#endif 1450vec4 finalPos=u_coord_matrix*vec4(projected_pos.xy/projected_pos.w+rotation_matrix*(a_offset/32.0*max(a_minFontScale,fontScale)+a_pxoffset)*projectionScaling,z,1.0);if(u_pitch_with_map) {finalPos=projectTileWithElevation(finalPos.xy,finalPos.z);}float gamma_scale=finalPos.w;gl_Position=finalPos;v_data0=a_tex/u_texsize;v_data1=vec3(gamma_scale,size,total_opacity);}`),symbolTextAndIcon:Pt(`#define SDF_PX 8.0 1451#define SDF 1.0 1452#define ICON 0.0 1453uniform bool u_is_halo;uniform bool u_is_text;uniform sampler2D u_texture;uniform sampler2D u_texture_icon;uniform highp float u_gamma_scale;uniform lowp float u_device_pixel_ratio;in vec4 v_data0;in ve
1453c3 v_data1;flat in float v_is_sdf; 1454#pragma maplibre: define highp vec4 fill_color 1455#pragma maplibre: define highp vec4 halo_color 1456#pragma maplibre: define lowp float halo_width 1457#pragma maplibre: define lowp float halo_blur 1458void main() { 1459#pragma maplibre: initialize highp vec4 fill_color 1460#pragma maplibre: initialize highp vec4 halo_color 1461#pragma maplibre: initialize lowp float halo_width 1462#pragma maplibre: initialize lowp float halo_blur 1463float total_opacity=v_data1[2];if (v_is_sdf==ICON) {vec2 tex_icon=v_data0.zw;fragColor=texture(u_texture_icon,tex_icon)*total_opacity; 1464#ifdef OVERDRAW_INSPECTOR 1465fragColor=vec4(1.0); 1466#endif 1467return;}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;highp float gamma=EDGE_GAMMA/(fontScale*u_gamma_scale);lowp float buff=(256.0-64.0)/256.0;lowp float dist=texture(u_texture,tex).a;lowp vec4 color_alpha_out,color_alpha_out_halo;if (u_is_text) {highp float gamma_scaled=gamma*gamma_scale;highp float alpha=smoothstep(buff-gamma_scaled,buff+gamma_scaled,dist);color_alpha_out=fill_color*(alpha*total_opacity);}if (u_is_halo) {highp float gamma_halo=(halo_blur*1.19/SDF_PX+EDGE_GAMMA)/(fontScale*u_gamma_scale);lowp float buff_halo=(6.0-halo_width/fontScale)/SDF_PX;highp float gamma_scaled_halo=gamma_halo*gamma_scale;highp float alpha_halo=smoothstep(buff_halo-gamma_scaled_halo,buff_halo+gamma_scaled_halo,dist);color_alpha_out_halo=halo_color*(alpha_halo*total_opacity);}if (u_is_text && u_is_halo) {fragColor=color_alpha_out+(1.-color_alpha_out.a)*color_alpha_out_halo;} else if (u_is_halo) {fragColor=color_alpha_out_halo;} else {fragColor=color_alpha_out;} 1468#ifdef OVERDRAW_INSPECTOR 1469fragColor=vec4(1.0); 1470#endif 1471}`,`layout(location=0) in vec4 a_pos_offset;layout(location=1) in vec4 a_data;layout(location=2) in vec3 a_projected_pos;layout(location=3) in float a_fade_opacity;uniform 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_label_plane_matrix;uniform mat4 u_coord_matrix;uniform bool u_is_text;uniform bool u_pitch_with_map;uniform highp float u_pitch;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 vec2 u_texsize_icon;uniform bool u_is_along_line;uniform bool u_is_variable_anchor;uniform vec2 u_translation;uniform float u_pitched_scale;uniform bool u_is_offset;out vec4 v_data0;out vec3 v_data1;flat out float v_is_sdf; 1472#pragma maplibre: define highp vec4 fill_color 1473#pragma maplibre: define highp vec4 halo_color 1474#pragma maplibre: define lowp float opacity 1475#pragma maplibre: define lowp float halo_width 1476#pragma maplibre: define lowp float halo_blur 1477void main() { 1478#pragma maplibre: initialize highp vec4 fill_color 1479#pragma maplibre: initialize highp vec4 halo_color 1480#pragma maplibre: initialize lowp float opacity 1481#pragma maplibre: initialize lowp float halo_width 1482#pragma maplibre: initialize lowp float halo_blur 1483vec2 a_pos=a_pos_offset.xy;vec2 a_offset=a_pos_offset.zw;vec2 a_tex=a_data.xy;vec2 a_size=a_data.zw;float a_size_min=floor(a_size[0]*0.5);float is_sdf=a_size[0]-2.0*a_size_min;float ele=get_elevation(a_pos);highp float segment_angle=-a_projected_pos[2];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 translated_a_pos=a_pos+u_translation;vec4 projectedPoint=projectTileWithElevation(translated_a_pos,ele);vec2 fade_opacity=unpack_opacity(a_fade_opacity);float visibility=calculate_visibility(projectedPoint);float fade_change=fade_opacity[1] > 0.5 ? u_fade_change :-u_fade_change;float interpolated_fade_opacity=max(0.0,min(visibility,fade_opacity[0]+fade_change));float total_opacity=opacity*interpolated_fade_opacity;if (total_opacity < 0.1){gl_Position=vec4(-2.,-2.,-2.,1.);return;}highp float camera_to_anchor_distance=projectedPoint.w;highp float distance_ratio=u_pitch_with_map ? 1484camera_to_anchor_distance/u_camera_to_center_distance : 1485u_camera_to_center_distance/camera_to_anchor_distance;highp float perspective_ratio=clamp(0.5+0.5*distance_ratio,0.0,4.0);if (!u_is_offset) {size*=perspective_ratio;}float fontScale=size/24.0;highp float symbol_rotation=0.0;if (u_rotate_symbol) {vec4 offsetProjectedPoint=projectTileWithElevation(translated_a_pos+vec2(1,0),ele);vec2 a=projectedPoint.xy/projectedPoint.w;vec2 b=offsetProjectedPoint.xy/offsetProjectedPoint.w;symbol_rotation=atan((b.y-a.y)/u_aspect_ratio,b.x-a.x);}highp 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);vec4 projected_pos;if (u_is_along_line || u_is_variable_anchor) {projected_pos=vec4(a_projected_pos.xy,ele,1.0);} else if (u_pitch_with_map) {projected_pos=u_label_plane_matrix*vec4(a_projected_pos.xy+u_translation,ele,1.0);} else {projected_pos=u_label_plane_matrix*projectTileWithElevation(a_projected_pos.xy+u_translation,ele);}float z=float(u_pitch_with_map)*projected_pos.z/projected_pos.w;float projectionScaling=1.0; 1486#ifdef GLOBE 1487if(u_pitch_with_map && !u_is_along_line) {float anchor_pos_tile_y=(u_coord_matrix*vec4(projected_pos.xy/projected_pos.w,z,1.0)).y;projectionScaling=mix(projectionScaling,1.0/circumferenceRatioAtTileY(anchor_pos_tile_y)*u_pitched_scale,u_projection_transition);} 1488#endif 1489vec4 finalPos=u_coord_matrix*vec4(projected_pos.xy/projected_pos.w+rotation_matrix*(a_offset/32.0*fontScale)*projectionScaling,z,1.0);if(u_pitch_with_map) {finalPos=projectTileWithElevation(finalPos.xy,finalPos.z);}float gamma_scale=finalPos.w;gl_Position=finalPos;v_data0.xy=a_tex/u_texsize;v_data0.zw=a_tex/u_texsize_icon;v_data1=vec3(gamma_scale,size,total_opacity);v_is_sdf=is_sdf;}`),terrain:Pt("uniform sampler2D u_texture;uniform vec4 u_fog_color;uniform vec4 u_horizon_color;uniform float u_fog_ground_blend;uniform float u_fog_ground_blend_opacity;uniform float u_horizon_fog_blend;uniform bool u_is_globe_mode;in vec2 v_texture_pos;in float v_fog_depth;const float gamma=2.2;vec4 gammaToLinear(vec4 color) {return pow(color,vec4(gamma));}vec4 linearToGamma(vec4 color) {return pow(color,vec4(1.0/gamma));}void main() {vec4 surface_color=texture(u_texture,vec2(v_texture_pos.x,1.0-v_texture_pos.y));if (!u_is_globe_mode && u_fog_ground_blend_opacity > 0.0 && v_fog_depth > u_fog_ground_blend) {vec4 surface_color_linear=gammaToLinear(surface_color);float blend_color=smoothstep(0.0,1.0,max((v_fog_depth-u_horizon_fog_blend)/(1.0-u_horizon_fog_blend),0.0));vec4 fog_horizon_color_linear=mix(gammaToLinear(u_fog_color),gammaToLinear(u_horizon_color),blend_color);
1489float factor_fog=max(v_fog_depth-u_fog_ground_blend,0.0)/(1.0-u_fog_ground_blend);fragColor=linearToGamma(mix(surface_color_linear,fog_horizon_color_linear,pow(factor_fog,2.0)*u_fog_ground_blend_opacity));} else {fragColor=surface_color;}}","layout(location=0) in vec3 a_pos3d;uniform mat4 u_fog_matrix;uniform float u_ele_delta;out vec2 v_texture_pos;out float v_fog_depth;void main() {float ele=get_elevation(a_pos3d.xy);float ele_delta=a_pos3d.z==1.0 ? u_ele_delta : 0.0;v_texture_pos=a_pos3d.xy/8192.0;gl_Position=projectTileFor3D(a_pos3d.xy,ele-ele_delta);vec4 pos=u_fog_matrix*vec4(a_pos3d.xy,ele,1.0);v_fog_depth=pos.z/pos.w*0.5+0.5;}"),terrainDepth:Pt("in float v_depth;const highp vec4 bitSh=vec4(256.*256.*256.,256.*256.,256.,1.);const highp vec4 bitMsk=vec4(0.,vec3(1./256.0));highp vec4 pack(highp float value) {highp vec4 comp=fract(value*bitSh);comp-=comp.xxyz*bitMsk;return comp;}void main() {fragColor=pack(v_depth);}","layout(location=0) in vec3 a_pos3d;uniform float u_ele_delta;out float v_depth;void main() {float ele=get_elevation(a_pos3d.xy);float ele_delta=a_pos3d.z==1.0 ? u_ele_delta : 0.0;gl_Position=projectTileFor3D(a_pos3d.xy,ele-ele_delta);v_depth=gl_Position.z/gl_Position.w;}"),terrainCoords:Pt("precision mediump float;uniform sampler2D u_texture;uniform float u_terrain_coords_id;in vec2 v_texture_pos;void main() {vec4 rgba=texture(u_texture,v_texture_pos);fragColor=vec4(rgba.r,rgba.g,rgba.b,u_terrain_coords_id);}","layout(location=0) in vec3 a_pos3d;uniform float u_ele_delta;out vec2 v_texture_pos;void main() {float ele=get_elevation(a_pos3d.xy);float ele_delta=a_pos3d.z==1.0 ? u_ele_delta : 0.0;v_texture_pos=a_pos3d.xy/8192.0;gl_Position=projectTileFor3D(a_pos3d.xy,ele-ele_delta);}"),atmosphere:Pt(`#ifdef GL_ES 1490precision highp float; 1491#endif 1492in vec3 view_direction;uniform vec3 u_sun_pos;uniform vec3 u_globe_position;uniform float u_globe_radius;uniform float u_atmosphere_blend;/**Shader use from https:*Made some change to adapt to MapLibre Globe geometry*/const float PI=3.141592653589793;const int iSteps=5;const int jSteps=3;/*radius of the planet*/const float EARTH_RADIUS=6371e3;/*radius of the atmosphere*/const float ATMOS_RADIUS=6471e3;vec2 rsi(vec3 r0,vec3 rd,float sr) {float a=dot(rd,rd);float b=2.0*dot(rd,r0);float c=dot(r0,r0)-(sr*sr);float d=(b*b)-4.0*a*c;if (d < 0.0) return vec2(1e5,-1e5);return vec2((-b-sqrt(d))/(2.0*a),(-b+sqrt(d))/(2.0*a));}vec4 atmosphere(vec3 r,vec3 r0,vec3 pSun,float iSun,float rPlanet,float rAtmos,vec3 kRlh,float kMie,float shRlh,float shMie,float g) {pSun=normalize(pSun);r=normalize(r);vec2 p=rsi(r0,r,rAtmos);if (p.x > p.y) {return vec4(0.0,0.0,0.0,1.0);}if (p.x < 0.0) {p.x=0.0;}vec3 pos=r0+r*p.x;vec2 p2=rsi(r0,r,rPlanet);if (p2.x <=p2.y && p2.x > 0.0) {p.y=min(p.y,p2.x);}float iStepSize=(p.y-p.x)/float(iSteps);float iTime=p.x+iStepSize*0.5;vec3 totalRlh=vec3(0,0,0);vec3 totalMie=vec3(0,0,0);float iOdRlh=0.0;float iOdMie=0.0;float mu=dot(r,pSun);float mumu=mu*mu;float gg=g*g;float pRlh=3.0/(16.0*PI)*(1.0+mumu);float pMie=3.0/(8.0*PI)*((1.0-gg)*(mumu+1.0))/(pow(1.0+gg-2.0*mu*g,1.5)*(2.0+gg));for (int i=0; i < iSteps; i++) {vec3 iPos=r0+r*iTime;float iHeight=length(iPos)-rPlanet;float odStepRlh=exp(-iHeight/shRlh)*iStepSize;float odStepMie=exp(-iHeight/shMie)*iStepSize;iOdRlh+=odStepRlh;iOdMie+=odStepMie;float jStepSize=rsi(iPos,pSun,rAtmos).y/float(jSteps);float jTime=jStepSize*0.5;float jOdRlh=0.0;float jOdMie=0.0;for (int j=0; j < jSteps; j++) {vec3 jPos=iPos+pSun*jTime;float jHeight=length(jPos)-rPlanet;jOdRlh+=exp(-jHeight/shRlh)*jStepSize;jOdMie+=exp(-jHeight/shMie)*jStepSize;jTime+=jStepSize;}vec3 attn=exp(-(kMie*(iOdMie+jOdMie)+kRlh*(iOdRlh+jOdRlh)));totalRlh+=odStepRlh*attn;totalMie+=odStepMie*attn;iTime+=iStepSize;}float opacity=exp(-(length(kRlh)*length(totalRlh)+kMie*length(totalMie)));vec3 color=iSun*(pRlh*kRlh*totalRlh+pMie*kMie*totalMie);return vec4(color,opacity);}void main() {vec3 scale_camera_pos=-u_globe_position*EARTH_RADIUS/u_globe_radius;vec4 color=atmosphere(normalize(view_direction),scale_camera_pos,u_sun_pos,22.0,EARTH_RADIUS,ATMOS_RADIUS,vec3(5.5e-6,13.0e-6,22.4e-6),21e-6,8e3,1.2e3,0.758 1493);color.rgb=1.0-exp(-1.0*color.rgb);color=pow(color,vec4(1.0/2.2));fragColor=vec4(color.rgb,1.0-color.a)*u_atmosphere_blend;}`,"layout(location=0) in vec2 a_pos;uniform mat4 u_inv_proj_matrix;out vec3 view_direction;void main() {view_direction=(u_inv_proj_matrix*vec4(a_pos,0.0,1.0)).xyz;gl_Position=vec4(a_pos,0.0,1.0);}"),sky:Pt("uniform vec4 u_sky_color;uniform vec4 u_horizon_color;uniform vec2 u_horizon;uniform vec2 u_horizon_normal;uniform float u_sky_horizon_blend;uniform float u_sky_blend;void main() {float x=gl_FragCoord.x;float y=gl_FragCoord.y;float blend=(y-u_horizon.y)*u_horizon_normal.y+(x-u_horizon.x)*u_horizon_normal.x;if (blend > 0.0) {if (blend < u_sky_horizon_blend) {fragColor=mix(u_sky_color,u_horizon_color,pow(1.0-blend/u_sky_horizon_blend,2.0));} else {fragColor=u_sky_color;}}fragColor=mix(fragColor,vec4(vec3(0.0),0.0),u_sky_blend);}","layout(location=0) in vec2 a_pos;void main() {gl_Position=vec4(a_pos,1.0,1.0);}")};function Pt(e,t){let r=/#pragma maplibre: ([\w]+) ([\w]+) ([\w]+) ([\w]+)/g,i=t.match(/in ([\w]+) ([\w]+)/g),n=e.match(/uniform ([\w]+) ([\w]+)([\s]*)([\w]*)/g),a=t.match(/uniform ([\w]+) ([\w]+)([\s]*)([\w]*)/g),s=a?a.concat(n):n,o=i?i.length:0,l={};return e=e.replace(r,(u,c,d,h,f)=>(l[f]=!0,c==="define"?` 1494#ifndef HAS_UNIFORM_u_${f} 1495in ${d} ${h} ${f}; 1496#else 1497uniform ${d} ${h} u_${f}; 1498#endif 1499`:` 1500#ifdef HAS_UNIFORM_u_${f} 1501 ${d} ${h} ${f} = u_${f}; 1502#endif 1503`)),t=t.replace(r,(u,c,d,h,f)=>{let p=h==="float"?"vec2":"vec4",m=f.match(/color/)?"color":p;return l[f]?c==="define"?` 1504#ifndef HAS_UNIFORM_u_${f} 1505uniform lowp float u_${f}_t; 1506layout(location = ${o++}) in ${d} ${p} a_${f}; 1507out ${d} ${h} ${f}; 1508#else 1509uniform ${d} ${h} u_${f}; 1510#endif 1511`:m==="vec4"?` 1512#ifndef HAS_UNIFORM_u_${f} 1513 ${f} = a_${f}; 1514#else 1515 ${d} ${h} ${f} = u_${f}; 1516#endif 1517`:` 1518#ifndef HAS_UNIFORM_u_${f} 1519 ${f} = unpack_mix_${m}(a_${f}, u_${f}_t); 1520#else 1521 ${d} ${h} ${f} = u_${f}; 1522#endif 1523`:c==="define"?` 1524#ifndef HAS_UNIFORM_u_${f} 1525uniform lowp float u_${f}_t; 1526layout(location = ${o++}) in ${d} ${p} a_${f}; 1527#else 1528uniform ${d} ${h} u_${f}; 1529#endif 1530`:m==="vec4"?` 1531#ifndef HAS_UNIFORM_u_${f} 1532 ${d} ${h} ${f} = a_${f}; 1533#else 1534 ${d} ${h} ${f} = u_${f}; 1535#endif 1536`:` 1537#ifndef HAS_UNIFORM_u_${f} 1538 ${d} ${h} ${f} = unpack_mix_${m}(a_${f}, u_${f}_t); 1539#else 1540 ${d} ${h} ${f} = u_${f}; 1541#endif 1542`}),{fragmentSource:e,vertexSource:t,staticAttributes:i,staticUniforms:s}}var wg=class{constructor(e,t,r){this.vertexBuffer=e,this.indexBuffer=t,this.segments=r}destroy(){this.vertexBuffer.destroy(),this.indexBuffer.destroy(),this.segments.destroy(),this.vertexBuffer=null,this.indexBuffer=null,this.segments=null}};const qu=Ar([{name:"a_pos",type:"Int16",components:2}]),BF="#define PROJECTION_MERCATOR",jF="mercator";var n3=class{constructor(){this._cachedMesh=null}get name(){return"mercator"}get useSubdivision(){return!1}get shaderVariantName(){return jF}get shaderDefine(){return BF}get shaderPreludeCode(){return eo.projectionMercator}get vertexShaderPreludeCode(){return eo.projectionMercator.vertexSource}get subdivisionGranularity(){return lS.noSubdivision}get useGlobeControls(){return!1}get transitionState(){return 0}destroy(){}getMeshFromTileID(e,t,r,i,n){if(this._cachedMesh)return this._cachedMesh;let a=new Gl;a.emplaceBack(0,0),a.emplaceBack(ye,0),a.emplaceBack(0,ye),a.emplaceBack(ye,ye);let s=e.createVertexBuffer(a,qu.members),o=$r.simpleSegment(0,0,4,2),l=new go;
vendor: 8,365 bytes, line 1542
1542l.emplaceBack(1,0,2),l.emplaceBack(1,2,3);let u=e.createIndexBuffer(l);return this._cachedMesh=new wg(s,u,o),this._cachedMesh}recalculate(){}hasTransition(){return!1}},bE=class UF{constructor(t=0,r=0,i=0,n=0){if(isNaN(t)||t<0||isNaN(r)||r<0||isNaN(i)||i<0||isNaN(n)||n<0)throw Error("Invalid value for edge-insets, top, bottom, left and right must all be numbers");this.top=t,this.bottom=r,this.left=i,this.right=n}interpolate(t,r,i){return r.top!=null&&t.top!=null&&(this.top=ai.number(t.top,r.top,i)),r.bottom!=null&&t.bottom!=null&&(this.bottom=ai.number(t.bottom,r.bottom,i)),r.left!=null&&t.left!=null&&(this.left=ai.number(t.left,r.left,i)),r.right!=null&&t.right!=null&&(this.right=ai.number(t.right,r.right,i)),this}getCenter(t,r){let i=Ot((this.left+t-this.right)/2,0,t),n=Ot((this.top+r-this.bottom)/2,0,r);return new de(i,n)}equals(t){return this.top===t.top&&this.bottom===t.bottom&&this.left===t.left&&this.right===t.right}clone(){return new UF(this.top,this.bottom,this.left,this.right)}toJSON(){return{top:this.top,bottom:this.bottom,left:this.left,right:this.right}}};function Vy(e,t){if(!e.renderWorldCopies||e.lngRange)return;let r=t.lng-e.center.lng;t.lng+=r>180?-360:r<-180?360:0}function xE(e){return Math.max(0,Math.floor(e))}var IS=class{constructor(e,t){this.applyConstrain=(r,i)=>this._constrainOverride===null?this._callbacks.defaultConstrain(r,i):this._constrainOverride(r,i),this._callbacks=e,this._tileSize=512,this._renderWorldCopies=(t==null?void 0:t.renderWorldCopies)===void 0||!!(t!=null&&t.renderWorldCopies),this._minZoom=(t==null?void 0:t.minZoom)||0,this._maxZoom=(t==null?void 0:t.maxZoom)||22,this._minPitch=(t==null?void 0:t.minPitch)===void 0||(t==null?void 0:t.minPitch)===null?0:t==null?void 0:t.minPitch,this._maxPitch=(t==null?void 0:t.maxPitch)===void 0||(t==null?void 0:t.maxPitch)===null?60:t==null?void 0:t.maxPitch,this._constrainOverride=(t==null?void 0:t.constrainOverride)??null,this.setMaxBounds(),this._width=0,this._height=0,this._center=new rt(0,0),this._elevation=0,this._zoom=0,this._tileZoom=xE(this._zoom),this._scale=In(this._zoom),this._bearingInRadians=0,this._fovInRadians=.6435011087932844,this._pitchInRadians=0,this._rollInRadians=0,this._unmodified=!0,this._edgeInsets=new bE,this._minElevationForCurrentTile=0,this._autoCalculateNearFarZ=!0}apply(e,t,r){this._constrainOverride=e.constrainOverride,this._latRange=e.latRange,this._lngRange=e.lngRange,this._width=e.width,this._height=e.height,this._center=e.center,this._elevation=e.elevation,this._minElevationForCurrentTile=e.minElevationForCurrentTile,this._zoom=e.zoom,this._tileZoom=xE(this._zoom),this._scale=In(this._zoom),this._bearingInRadians=e.bearingInRadians,this._fovInRadians=e.fovInRadians,this._pitchInRadians=e.pitchInRadians,this._rollInRadians=e.rollInRadians,this._unmodified=e.unmodified,this._edgeInsets=new bE(e.padding.top,e.padding.bottom,e.padding.left,e.padding.right),this._minZoom=e.minZoom,this._maxZoom=e.maxZoom,this._minPitch=e.minPitch,this._maxPitch=e.maxPitch,this._renderWorldCopies=e.renderWorldCopies,this._cameraToCenterDistance=e.cameraToCenterDistance,this._nearZ=e.nearZ,this._farZ=e.farZ,this._autoCalculateNearFarZ=!r&&e.autoCalculateNearFarZ,t&&this.constrainInternal(),this._calcMatrices()}get pixelsToClipSpaceMatrix(){return this._pixelsToClipSpaceMatrix}get clipSpaceToPixelsMatrix(){return this._clipSpaceToPixelsMatrix}get minElevationForCurrentTile(){return this._minElevationForCurrentTile}setMinElevationForCurrentTile(e){this._minElevationForCurrentTile=e}get tileSize(){return this._tileSize}get tileZoom(){return this._tileZoom}get scale(){return this._scale}get width(){return this._width}get height(){return this._height}get bearingInRadians(){return this._bearingInRadians}get lngRange(){return this._lngRange}get latRange(){return this._latRange}get pixelsToGLUnits(){return this._pixelsToGLUnits}get minZoom(){return this._minZoom}setMinZoom(e){this._minZoom!==e&&(this._minZoom=e,this.setZoom(this.applyConstrain(this._center,this.zoom).zoom))}get maxZoom(){return this._maxZoom}setMaxZoom(e){this._maxZoom!==e&&(this._maxZoom=e,this.setZoom(this.applyConstrain(this._center,this.zoom).zoom))}get minPitch(){return this._minPitch}setMinPitch(e){this._minPitch!==e&&(this._minPitch=e,this.setPitch(Math.max(this.pitch,e)))}get maxPitch(){return this._maxPitch}setMaxPitch(e){this._maxPitch!==e&&(this._maxPitch=e,this.setPitch(Math.min(this.pitch,e)))}get renderWorldCopies(){return this._renderWorldCopies}setRenderWorldCopies(e){e===void 0?e=!0:e===null&&(e=!1),this._renderWorldCopies=e}get constrainOverride(){return this._constrainOverride}setConstrainOverride(e){e===void 0&&(e=null),this._constrainOverride!==e&&(this._constrainOverride=e,this.constrainInternal(),this._calcMatrices())}get worldSize(){return this._tileSize*this._scale}get centerOffset(){return this.centerPoint._sub(this.size._div(2))}get size(){return new de(this._width,this._height)}get bearing(){return this._bearingInRadians/Math.PI*180}setBearing(e){let t=ys(e,-180,180)*Math.PI/180;this._bearingInRadians!==t&&(this._unmodified=!1,this._bearingInRadians=t,this._calcMatrices(),this._rotationMatrix=xF(),EPe(this._rotationMatrix,this._rotationMatrix,-this._bearingInRadians))}get rotationMatrix(){return this._rotationMatrix}get pitchInRadians(){return this._pitchInRadians}get pitch(){return this._pitchInRadians/Math.PI*180}setPitch(e){let t=Ot(e,this.minPitch,this.maxPitch)/180*Math.PI;this._pitchInRadians!==t&&(this._unmodified=!1,this._pitchInRadians=t,this._calcMatrices())}get rollInRadians(){return this._rollInRadians}get roll(){return this._rollInRadians/Math.PI*180}setRoll(e){let t=e/180*Math.PI;this._rollInRadians!==t&&(this._unmodified=!1,this._rollInRadians=t,this._calcMatrices())}get fovInRadians(){return this._fovInRadians}get fov(){return Sd(this._fovInRadians)}setFov(e){e=Ot(e,.1,150),this.fov!==e&&(this._unmodified=!1,this._fovInRadians=zr(e),this._calcMatrices())}get zoom(){return this._zoom}setZoom(e){let t=this.applyConstrain(this._center,e).zoom;this._zoom!==t&&(this._unmodified=!1,this._zoom=t,this._tileZoom=Math.max(0,Math.floor(t)),this._scale=In(t),this.constrainInternal(),this._calcMatrices())}get center(){return this._center}setCenter(e){(e.lat!==this._center.lat||e.lng!==this._center.lng)&&(this._unmodified=!1,this._center=e,this.constrainInternal(),this._calcMatrices())}get elevation(){return this._elevation}setElevation(e){e!==this._elevation&&(this._elevation=e,this.constrainInternal(),this._calcMatrices())}get padding(){return this._edgeInsets.toJSON()}setPadding(e){this._edgeInsets.equals(e)||(this._unmodified=!1,this._edgeInsets.interpolate(this._edgeInsets,e,1),this._calcMatrices())}get centerPoint(){return this._edgeInsets.getCenter(this._width,this._height)}get pixelsPerMeter(){return this._pixelPerMeter}get unmodified(){return this._unmodified}get cameraToCenterDistance(){return this._cameraToCenterDistance}get nearZ(){return this._nearZ}get farZ(){return this._farZ}get autoCalculateNearFarZ(){return this._autoCalculateNearFarZ}overrideNearFarZ(e,t){this._autoCalculateNearFarZ=!1,this._nearZ=e,this._farZ=t,this._calcMatrices()}clearNearFarZOverride(){this._autoCalculateNearFarZ=!0,this._calcMatrices()}isPaddingEqual(e){return this._edgeInsets.equals(e)}interpolatePadding(e,t,r){this._unmodified=!1,this._edgeInsets.interpolate(e,t,r),this.constrainInternal(),this._calcMatrices()}resize(e,t,r=!0){this._width=e,this._height=t,r&&this.constrainInternal(),this._calcMatrices()}getMaxBounds(){var e,t;return((e=this._latRange)==null?void 0:e.length)!==2||((t=this._lngRange)==null?void 0:t.length)!==2?null:new co([this._lngRange[0],this._latRange[0]],[this._lngRange[1],this._latRange[1]])}setMaxBounds(e){e?(this._lngRange=[e.getWest(),e.getEast()],this._latRange=[e.getSouth(),e.getNorth()],this.constrainInternal()):(this._lngRange=null,this._latRange=[-ul,ul])}getCameraQueryGeometry(e,t){if(t.length===1)return[t[0],e];{let{minX:r,minY:i,maxX:n,maxY:a}=no.fromPoints(t).extend(e);return[new de(r,i),new de(n,i),new de(n,a),new de(r,a),new de(r,i)]}}constrainInternal(){if(!this.center||!this._width||!this._height||this._constraining)return;this._constraining=!0;let e=this._unmodified,{center:t,zoom:r}=this.applyConstrain(this.center,this.zoom);this.setCenter(t),this.setZoom(r),this._unmodified=e,this._constraining=!1}
vendor: 4,565 bytes, line 1542
1542_calcMatrices(){if(this._width&&this._height){this._pixelsToGLUnits=[2/this._width,-2/this._height];let e=Ms(new Float64Array(16));Li(e,e,[this._width/2,-this._height/2,1]),ei(e,e,[1,-1,0]),this._clipSpaceToPixelsMatrix=e,e=Ms(new Float64Array(16)),Li(e,e,[1,-1,1]),ei(e,e,[-1,-1,0]),Li(e,e,[2/this._width,2/this._height,1]),this._pixelsToClipSpaceMatrix=e;let t=this.fovInRadians/2;this._cameraToCenterDistance=.5/Math.tan(t)*this._height}this._callbacks.calcMatrices()}calculateCenterFromCameraLngLatAlt(e,t,r,i){let n=r===void 0?this.bearing:r,a=i=i===void 0?this.pitch:i,{distanceToCenter:s,clampedElevation:o}=this._distanceToCenterFromAltElevationPitch(t,this.elevation,a),{x:l,y:u}=Nw(a,n),c=nr.fromLngLat(e,t),d=NL(1,c.y),h,f,p=0;do{if(p+=1,p>10)break;f=s/d;let m=l*f,g=u*f;h=new nr(c.x+m,c.y+g),d=1/h.meterInMercatorCoordinateUnits()}while(Math.abs(s-f*d)>1e-12);return{center:h.toLngLat(),elevation:o,zoom:cn(this.height/2/Math.tan(this.fovInRadians/2)/f/this.tileSize)}}recalculateZoomAndCenter(e){if(this.elevation-e===0)return;let t=1/this.worldSize,r=eu(1,this.center.lat)*this.worldSize,i=nr.fromLngLat(this.center,this.elevation),n=i.x/t,a=i.y/t,s=i.z/t,o=this.pitch,l=this.bearing,{x:u,y:c,z:d}=Nw(o,l),h=this.cameraToCenterDistance,f=n+h*-u,p=a+h*-c,m=s+h*d,{distanceToCenter:g,clampedElevation:v}=this._distanceToCenterFromAltElevationPitch(m/r,e,o),x=g*r,_=f+u*x,y=p+c*x,w=new nr(_*t,y*t,0).toLngLat(),$=eu(1,w.lat),S=cn(this.height/2/Math.tan(this.fovInRadians/2)/g/$/this.tileSize);this._elevation=v,this._center=w,this.setZoom(S)}_distanceToCenterFromAltElevationPitch(e,t,r){let i=-Math.cos(zr(r)),n=e-t,a,s=t;return i*n>=0||Math.abs(i)<.1?(a=1e4,s=e+a*i):a=-n/i,{distanceToCenter:a,clampedElevation:s}}getCameraPoint(){let e=this.pitchInRadians,t=Math.tan(e)*(this.cameraToCenterDistance||1);return this.centerPoint.add(new de(t*Math.sin(this.rollInRadians),t*Math.cos(this.rollInRadians)))}getCameraAltitude(){return Math.cos(this.pitchInRadians)*this._cameraToCenterDistance/this._pixelPerMeter+this.elevation}getCameraLngLat(){let e=eu(1,this.center.lat)*this.worldSize,t=this.cameraToCenterDistance/e;return UL(this.center,this.elevation,this.pitch,this.bearing,t).toLngLat()}getMercatorTileCoordinates(e){if(!e)return[0,0,1,1];let t=e.canonical.z>=0?1<<e.canonical.z:2**e.canonical.z;return[e.canonical.x/t,e.canonical.y/t,1/t/ye,1/t/ye]}},VF=class qF{constructor(t,r){this.min=t,this.max=r,this.center=ri([],Xa([],this.min,this.max),.5)}quadrant(t){let r=[t%2==0,t<2],i=Nx(this.min),n=Nx(this.max);for(let a=0;a<r.length;a++)i[a]=r[a]?this.min[a]:this.center[a],n[a]=r[a]?this.center[a]:this.max[a];return n[2]=this.max[2],new qF(i,n)}distanceX(t){return Math.max(Math.min(this.max[0],t[0]),this.min[0])-t[0]}distanceY(t){return Math.max(Math.min(this.max[1],t[1]),this.min[1])-t[1]}intersectsFrustum(t){let r=!0;for(let i of t.planes){let n=this.intersectsPlane(i);if(n===0)return 0;n===1&&(r=!1)}return r?2:t.aabb.min[0]>this.max[0]||t.aabb.min[1]>this.max[1]||t.aabb.min[2]>this.max[2]||t.aabb.max[0]<this.min[0]||t.aabb.max[1]<this.min[1]||t.aabb.max[2]<this.min[2]?0:1}intersectsPlane(t){let r=t[3],i=t[3];for(let n=0;n<3;n++)t[n]>0?(r+=t[n]*this.min[n],i+=t[n]*this.max[n]):(i+=t[n]*this.min[n],r+=t[n]*this.max[n]);return r>=0?2:i<0?0:1}},xIe=class{distanceToTile2d(e,t,r,i){let n=i,a=n.distanceX([e,t]),s=n.distanceY([e,t]);return Math.hypot(a,s)}getWrap(e,t,r){return r}getTileBoundingVolume(e,t,r,i){let n=Math.min(0,r),a=Math.max(0,r);if(i!=null&&i.terrain){let o=new Ri(e.z,t,e.z,e.x,e.y),l=i.terrain.getMinMaxElevation(o);n=l.minElevation??n,a=l.maxElevation??a}let s=1<<e.z;return new VF([t+e.x/s,e.y/s,n],[t+(e.x+1)/s,(e.y+1)/s,a])}allowVariableZoom(e,t){let r=e.fov*(Math.abs(Math.cos(e.rollInRadians))*e.height+Math.abs(Math.sin(e.rollInRadians))*e.width)/e.height,i=Ot(78.5-r/2,0,60);return!!t.terrain||e.pitch>i}allowWorldCopies(){return!0}prepareNextFrame(){}},GF=class HF{constructor(t,r,i){this.points=t,this.planes=r,this.aabb=i}static fromInvProjectionMatrix(t,r=1,i=0,n,a){let s=[[-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]],o=a?[[6,5,4],[0,1,2],[0,3,7],[2,1,5],[3,2,6],[0,4,5]]:[[0,1,2],[6,5,4],[0,3,7],[2,1,5],[3,2,6],[0,4,5]],l=2**i,u=s.map(f=>wIe(f,t,r,l));n&&$Ie(u,o[0],n,a);let c=o.map(f=>{let p=ll([],u[f[0]],u[f[1]]),m=ll([],u[f[2]],u[f[1]]),g=Ga([],ya([],p,m)),v=-Fi(g,u[f[1]]);return g.concat(v)}),d=[1/0,1/0,1/0],h=[-1/0,-1/0,-1/0];for(let f of u)for(let p=0;p<3;p++)d[p]=Math.min(d[p],f[p]),h[p]=Math.max(h[p],f[p]);return new HF(u,c,new VF(d,h))}};
vendor: 4,787 bytes, line 1542
1542function wIe(e,t,r,i){let n=_i([],e,t),a=1/n[3]/r*i;return D$e(n,n,[a,a,1/n[3],a])}function $Ie(e,t,r,i){let n=i?4:0,a=i?0:4,s=0,o=[],l=[];for(let d=0;d<4;d++){let h=ll([],e[d+a],e[d+n]),f=q1(h);ri(h,h,1/f),o.push(f),l.push(h)}for(let d=0;d<4;d++){let h=V$e(e[d+n],l[d],r);s=h!==null&&h>=0?Math.max(s,h):Math.max(s,o[d])}let u=SIe(e,t),c=TIe(r,u);if(c!==null){let d=c/Fi(l[0],u);s=Math.min(s,d)}for(let d=0;d<4;d++){let h=Math.min(s,o[d]);e[d+a]=[e[d+n][0]+l[d][0]*h,e[d+n][1]+l[d][1]*h,e[d+n][2]+l[d][2]*h,1]}}function SIe(e,t){let r=ll([],e[t[0]],e[t[1]]),i=ll([],e[t[2]],e[t[1]]),n=[0,0,0,0];return Ga(n,ya([],r,i)),n[3]=-Fi(n,e[t[0]]),n}function TIe(e,t){let r=wy(e),i=I$e([],e,1/r),n=ll([],t,ri([],i,Fi(t,i))),a=wy(n);if(a>0){let s=Math.sqrt(1-i[3]*i[3]),o=ri([],i,-i[3]),l=Xa([],o,ri([],n,s/a));return Ux(t,l)}return null}var qy=class YF{get pixelsToClipSpaceMatrix(){return this._helper.pixelsToClipSpaceMatrix}get clipSpaceToPixelsMatrix(){return this._helper.clipSpaceToPixelsMatrix}get pixelsToGLUnits(){return this._helper.pixelsToGLUnits}get centerOffset(){return this._helper.centerOffset}get size(){return this._helper.size}get rotationMatrix(){return this._helper.rotationMatrix}get centerPoint(){return this._helper.centerPoint}get pixelsPerMeter(){return this._helper.pixelsPerMeter}setMinZoom(t){this._helper.setMinZoom(t)}setMaxZoom(t){this._helper.setMaxZoom(t)}setMinPitch(t){this._helper.setMinPitch(t)}setMaxPitch(t){this._helper.setMaxPitch(t)}setRenderWorldCopies(t){this._helper.setRenderWorldCopies(t)}setBearing(t){this._helper.setBearing(t)}setPitch(t){this._helper.setPitch(t)}setRoll(t){this._helper.setRoll(t)}setFov(t){this._helper.setFov(t)}setZoom(t){this._helper.setZoom(t)}setCenter(t){this._helper.setCenter(t)}setElevation(t){this._helper.setElevation(t)}setMinElevationForCurrentTile(t){this._helper.setMinElevationForCurrentTile(t)}setPadding(t){this._helper.setPadding(t)}interpolatePadding(t,r,i){this._helper.interpolatePadding(t,r,i)}isPaddingEqual(t){return this._helper.isPaddingEqual(t)}resize(t,r,i=!0){this._helper.resize(t,r,i)}getMaxBounds(){return this._helper.getMaxBounds()}setMaxBounds(t){this._helper.setMaxBounds(t)}setConstrainOverride(t){this._helper.setConstrainOverride(t)}overrideNearFarZ(t,r){this._helper.overrideNearFarZ(t,r)}clearNearFarZOverride(){this._helper.clearNearFarZOverride()}getCameraQueryGeometry(t){return this._helper.getCameraQueryGeometry(this.getCameraPoint(),t)}get tileSize(){return this._helper.tileSize}get tileZoom(){return this._helper.tileZoom}get scale(){return this._helper.scale}get worldSize(){return this._helper.worldSize}get width(){return this._helper.width}get height(){return this._helper.height}get lngRange(){return this._helper.lngRange}get latRange(){return this._helper.latRange}get minZoom(){return this._helper.minZoom}get maxZoom(){return this._helper.maxZoom}get zoom(){return this._helper.zoom}get center(){return this._helper.center}get minPitch(){return this._helper.minPitch}get maxPitch(){return this._helper.maxPitch}get pitch(){return this._helper.pitch}get pitchInRadians(){return this._helper.pitchInRadians}get roll(){return this._helper.roll}get rollInRadians(){return this._helper.rollInRadians}get bearing(){return this._helper.bearing}get bearingInRadians(){return this._helper.bearingInRadians}get fov(){return this._helper.fov}get fovInRadians(){return this._helper.fovInRadians}get elevation(){return this._helper.elevation}get minElevationForCurrentTile(){return this._helper.minElevationForCurrentTile}get padding(){return this._helper.padding}get unmodified(){return this._helper.unmodified}get renderWorldCopies(){return this._helper.renderWorldCopies}get cameraToCenterDistance(){return this._helper.cameraToCenterDistance}get constrainOverride(){return this._helper.constrainOverride}get nearZ(){return this._helper.nearZ}get farZ(){return this._helper.farZ}get autoCalculateNearFarZ(){return this._helper.autoCalculateNearFarZ}setTransitionState(t){}constructor(t){this._posMatrixCache=new Map,this._alignedPosMatrixCache=new Map,this._fogMatrixCacheF32=new Map,this.defaultConstrain=(r,i)=>{i=Ot(+i,this.minZoom,this.maxZoom);let n={center:new rt(r.lng,r.lat),zoom:i},a=this._helper._lngRange;!this._helper._renderWorldCopies&&a===null&&(a=[-179.9999999999,180-1e-10]);let s=this.tileSize*In(n.zoom),o=0,l=s,u=0,c=s,d=0,h=0,{x:f,y:p}=this.size;if(this._helper._latRange){let y=this._helper._latRange;o=zh(y[1])*s,l=zh(y[0])*s,l-o<p&&(d=p/(l-o))}a&&(u=ys(Fh(a[0])*s,0,s),c=ys(Fh(a[1])*s,0,s),c<u&&(c+=s),c-u<f&&(h=f/(c-u)));let{x:m,y:g}=Qs(s,r),v,x,_=Math.max(h||0,d||0);if(_){let y=new de(h?(c+u)/2:m,d?(l+o)/2:g);return n.center=Nm(s,y).wrap(),n.zoom+=cn(_),n}if(this._helper._latRange){let y=p/2;g-y<o&&(x=o+y),g+y>l&&(x=l-y)}if(a){let y=(u+c)/2,w=m;
1542this._helper._renderWorldCopies&&(w=ys(m,y-s/2,y+s/2));let $=f/2;w-$<u&&(v=u+$),w+$>c&&(v=c-$)}if(v!==void 0||x!==void 0){let y=new de(v??m,x??g);n.center=Nm(s,y).wrap()}return n},this.applyConstrain=(r,i)=>this._helper.applyConstrain(r,i),this._helper=new IS({calcMatrices:()=>this._calcMatrices(),defaultConstrain:(r,i)=>this.defaultConstrain(r,i)},t),this._coveringTilesDetailsProvider=new xIe}clone(){let t=new YF;return t.apply(this,!1),t}apply(t,r,i){this._helper.apply(t,r,i)}get cameraPosition(){return this._cameraPosition}get projectionMatrix(){return this._projectionMatrix}get modelViewProjectionMatrix(){return this._viewProjMatrix}get inverseProjectionMatrix(){return this._invProjMatrix}get mercatorMatrix(){return this._mercatorMatrix}getVisibleUnwrappedCoordinates(t){let r=[new jy(0,t)];if(this._helper._renderWorldCopies){let i=this.screenPointToMercatorCoordinate(new de(0,0)),n=this.screenPointToMercatorCoordinate(new de(this._helper._width,0)),a=this.screenPointToMercatorCoordinate(new de(this._helper._width,this._helper._height)),s=this.screenPointToMercatorCoordinate(new de(0,this._helper._height)),o=Math.floor(Math.min(i.x,n.x,a.x,s.x)),l=Math.floor(Math.max(i.x,n.x,a.x,s.x));for(let u=o-1;u<=l+1;u++)u!==0&&r.push(new jy(u,t))}return r}getCameraFrustum(){return GF.fromInvProjectionMatrix(this._invViewProjMatrix,this.worldSize)}getClippingPlane(){return null}getCoveringTilesDetailsProvider(){return this._coveringTilesDetailsProvider}recalculateZoomAndCenter(t){let r=this.screenPointToLocation(this.centerPoint,t),i=t?t.getElevationForLngLatZoom(r,this._helper._tileZoom):0;this._helper.recalculateZoomAndCenter(i)}setLocationAtPoint(t,r){let i=eu(this.elevation,this.center.lat),n=this.screenPointToMercatorCoordinateAtZ(r,i),a=this.screenPointToMercatorCoordinateAtZ(this.centerPoint,i),s=nr.fromLngLat(t),o=new nr(s.x-(n.x-a.x),s.y-(n.y-a.y));this.setCenter(o==null?void 0:o.toLngLat()),this._helper._renderWorldCopies&&this.setCenter(this.center.wrap())}locationToScreenPoint(t,r){return r?this.coordinatePoint(nr.fromLngLat(t),r.getElevationForLngLat(t,this),this._pixelMatrix3D):this.coordinatePoint(nr.fromLngLat(t))}screenPointToLocation(t,r){var i;return(i=this.screenPointToMercatorCoordinate(t,r))==null?void 0:i.toLngLat()}screenPointToMercatorCoordinate(t,r){if(r){let i=r.pointCoordinate(t);if(i!=null)return i}return this.screenPointToMercatorCoordinateAtZ(t)}screenPointToMercatorCoordinateAtZ(t,r){let i=r||0,n=[t.x,t.y,0,1],a=[t.x,t.y,1,1];_i(n,n,this._pixelMatrixInverse),_i(a,a,this._pixelMatrixInverse);let s=n[3],o=a[3],l=n[0]/s,u=a[0]/o,c=n[1]/s,d=a[1]/o,h=n[2]/s,f=a[2]/o,p=h===f?0:(i-h)/(f-h);return new nr(ai.number(l,u,p)/this.worldSize,ai.number(c,d,p)/this.worldSize,i)}coordinatePoint(t,r=0,i=this._pixelMatrix){let n=[t.x*this.worldSize,t.y*this.worldSize,r,1];return _i(n,n,i),new de(n[0]/n[3],n[1]/n[3])}getBounds(){let t=Math.max(0,this._helper._height/2-Lp(this));return new co().extend(this.screenPointToLocation(new de(0,t))).extend(this.screenPointToLocation(new de(this._helper._width,t))).extend(this.screenPointToLocation(new de(this._helper._width,this._helper._height))).extend(this.screenPointToLocation(new de(0,this._helper._height)))}isPointOnMapSurface(t,r){return r?r.pointCoordinate(t)!=null:t.y>this.height/2-Lp(this)}calculatePosMatrix(t,r=!1,i=!1){let n=t.key??Qd(t.wrap,t.canonical.z,t.canonical.z,t.canonical.x,t.canonical.y),a=r?this._alignedPosMatrixCache:this._posMatrixCache;if(a.has(n)){let l=a.get(n);return i?l.f32:l.f64}let s=Ob(t,this.worldSize);cd(s,r?this._alignedProjMatrix:this._viewProjMatrix,s);let o={f64:s,f32:new Float32Array(s)};return a.set(n,o),i?o.f32:o.f64}calculateFogMatrix(t){let r=t.key,i=this._fogMatrixCacheF32;if(i.has(r))return i.get(r);let n=Ob(t,this.worldSize);return cd(n,this._fogMatrix,n),i.set(r,new Float32Array(n)),i.get(r)}calculateCenterFromCameraLngLatAlt(t,r,i,n){return this._helper.calculateCenterFromCameraLngLatAlt(t,r,i,n)}_calculateNearFarZIfNeeded(t,r,i){if(!this._helper.autoCalculateNearFarZ)return;let n=Math.min(this.elevation,this.minElevationForCurrentTile,this.getCameraAltitude()-100),a=t-n*this._helper._pixelPerMeter/Math.cos(r),s=n<0?a:t,o=Math.PI/2+this.pitchInRadians,l=zr(this.fov)*(Math.abs(Math.cos(zr(this.roll)))*this.height+Math.abs(Math.sin(zr(this.roll)))*this.width)/this.height*(.5+i.y/this.height),u=Math.sin(l)*s/Math.sin(Ot(Math.PI-o-l,.01,Math.PI-.01)),c=Lp(this),d=Math.atan(c/this._helper.cameraToCenterDistance),h=zr(90-hc),f=d>h?2*d*(.5+i.y/(c*2)):h,p=Math.sin(f)*s/Math.sin(Ot(Math.PI-o-f,.01,Math.PI-.01)),m=
vendor: 5,501 bytes, line 1542
1542Math.min(u,p);this._helper._farZ=(Math.cos(Math.PI/2-r)*m+s)*1.01,this._helper._nearZ=this._helper._height/50}_calcMatrices(){if(!this._helper._height)return;let t=this.centerOffset,r=Qs(this.worldSize,this.center),i=r.x,n=r.y;this._helper._pixelPerMeter=eu(1,this.center.lat)*this.worldSize;let a=zr(Math.min(this.pitch,hc)),s=Math.max(this._helper.cameraToCenterDistance/2,this._helper.cameraToCenterDistance+this._helper._elevation*this._helper._pixelPerMeter/Math.cos(a));this._calculateNearFarZIfNeeded(s,a,t);let o;o=new Float64Array(16),zx(o,this.fovInRadians,this._helper._width/this._helper._height,this._helper._nearZ,this._helper._farZ),this._invProjMatrix=new Float64Array(16),VMe(this._invProjMatrix,o),o[8]=-t.x*2/this._helper._width,o[9]=t.y*2/this._helper._height,this._projectionMatrix=Fx(o),Li(o,o,[1,-1,1]),ei(o,o,[0,0,-this._helper.cameraToCenterDistance]),Vl(o,o,-this.rollInRadians),Eh(o,o,this.pitchInRadians),Vl(o,o,-this.bearingInRadians),ei(o,o,[-i,-n,0]),this._mercatorMatrix=Li([],o,[this.worldSize,this.worldSize,this.worldSize]),Li(o,o,[1,1,this._helper._pixelPerMeter]),this._pixelMatrix=cd(new Float64Array(16),this.clipSpaceToPixelsMatrix,o),ei(o,o,[0,0,-this.elevation]),this._viewProjMatrix=o,this._invViewProjMatrix=xy([],o);let l=[0,0,-1,1];_i(l,l,this._invViewProjMatrix),this._cameraPosition=[l[0]/l[3],l[1]/l[3],l[2]/l[3]],this._fogMatrix=new Float64Array(16),zx(this._fogMatrix,this.fovInRadians,this.width/this.height,s,this._helper._farZ),this._fogMatrix[8]=-t.x*2/this.width,this._fogMatrix[9]=t.y*2/this.height,Li(this._fogMatrix,this._fogMatrix,[1,-1,1]),ei(this._fogMatrix,this._fogMatrix,[0,0,-this.cameraToCenterDistance]),Vl(this._fogMatrix,this._fogMatrix,-this.rollInRadians),Eh(this._fogMatrix,this._fogMatrix,this.pitchInRadians),Vl(this._fogMatrix,this._fogMatrix,-this.bearingInRadians),ei(this._fogMatrix,this._fogMatrix,[-i,-n,0]),Li(this._fogMatrix,this._fogMatrix,[1,1,this._helper._pixelPerMeter]),ei(this._fogMatrix,this._fogMatrix,[0,0,-this.elevation]),this._pixelMatrix3D=cd(new Float64Array(16),this.clipSpaceToPixelsMatrix,o);let u=this._helper._width%2/2,c=this._helper._height%2/2,d=Math.cos(this.bearingInRadians),h=Math.sin(-this.bearingInRadians),f=i-Math.round(i)+d*u+h*c,p=n-Math.round(n)+d*c+h*u,m=new Float64Array(o);if(ei(m,m,[f>.5?f-1:f,p>.5?p-1:p,0]),this._alignedProjMatrix=m,o=xy(new Float64Array(16),this._pixelMatrix),!o)throw Error("failed to invert matrix");this._pixelMatrixInverse=o,this._clearMatrixCaches()}_clearMatrixCaches(){this._posMatrixCache.clear(),this._alignedPosMatrixCache.clear(),this._fogMatrixCacheF32.clear()}maxPitchScaleFactor(){if(!this._pixelMatrixInverse)return 1;let t=this.screenPointToMercatorCoordinate(new de(0,0)),r=[t.x*this.worldSize,t.y*this.worldSize,0,1];return _i(r,r,this._pixelMatrix)[3]/this._helper.cameraToCenterDistance}getCameraPoint(){return this._helper.getCameraPoint()}getCameraAltitude(){return this._helper.getCameraAltitude()}getCameraLngLat(){let t=eu(1,this.center.lat)*this.worldSize,r=this._helper.cameraToCenterDistance/t;return UL(this.center,this.elevation,this.pitch,this.bearing,r).toLngLat()}lngLatToCameraDepth(t,r){let i=nr.fromLngLat(t),n=[i.x*this.worldSize,i.y*this.worldSize,r,1];return _i(n,n,this._viewProjMatrix),n[2]/n[3]}getProjectionData(t){let{overscaledTileID:r,aligned:i,applyTerrainMatrix:n}=t,a=this._helper.getMercatorTileCoordinates(r),s=r?this.calculatePosMatrix(r,i,!0):null,o;return o=r!=null&&r.terrainRttPosMatrix32f&&n?r.terrainRttPosMatrix32f:s||xR(),{mainMatrix:o,tileMercatorCoords:a,clippingPlane:[0,0,0,0],projectionTransition:0,fallbackMatrix:o,clipAntimeridian:!1}}isLocationOccluded(t){return!1}getPixelScale(){return 1}getCircleRadiusCorrection(){return 1}getPitchedTextCorrection(t,r,i){return 1}transformLightDirection(t){return Nx(t)}getRayDirectionFromPixel(t){throw Error("Not implemented.")}projectTileCoordinates(t,r,i,n){let a=this.calculatePosMatrix(i),s;n?(s=[t,r,n(t,r),1],_i(s,s,a)):(s=[t,r,0,1],MS(s,s,a));let o=s[3];return{point:new de(s[0]/o,s[1]/o),signedDistanceFromCamera:o,isOccluded:!1}}populateCache(t){for(let r of t)this.calculatePosMatrix(r)}getProjectionDataForCustomLayer(t=!0){let r=new Ri(0,0,0,0,0),i=this.getProjectionData({overscaledTileID:r,applyGlobeMatrix:t}),n=Ob(r,this.worldSize);cd(n,this._viewProjMatrix,n);let a=[ye,ye,this.worldSize/this._helper.pixelsPerMeter],s=Uu();return Li(s,n,a),{...i,tileMercatorCoords:[0,0,1,1],fallbackMatrix:s,mainMatrix:s}}getFastPathSimpleProjectionMatrix(t){return this.calculatePosMatrix(t)}};function WF(){vr("Map cannot fit within canvas with the given bounds, padding, and/or offset.")}function ZF(e){if(e.useSlerp)if(e.k<1){let t=Ik(e.startEulerAngles.roll,e.startEulerAngles.pitch,e.startEulerAngles.bearing),r=Ik(e.endEulerAngles.roll,e.endEulerAngles.pitch,e.endEulerAngles.bearing),i=new Float64Array(4);c_(i,t,r,e.k);let n=nSe(i);e.tr.setRoll(n.roll),e.tr.setPitch(n.pitch),e.tr.setBearing(n.bearing)}else e.tr.setRoll(e.endEulerAngles.roll),e.tr.setPitch(e.endEulerAngles.pitch),e.tr.setBearing(e.endEulerAngles.bearing);else e.tr.setRoll(ai.number(e.startEulerAngles.roll,e.endEulerAngles.roll,e.k)),e.tr.setPitch(ai.number(e.startEulerAngles.pitch,e.endEulerAngles.pitch,e.k)),e.tr.setBearing(ai.number(e.startEulerAngles.bearing,e.endEulerAngles.bearing,e.k))}function KF(e,t,r,i,n){let a=n.padding,s=Qs(n.worldSize,r.getNorthWest()),o=Qs(n.worldSize,r.getNorthEast()),l=Qs(n.worldSize,r.getSouthEast()),u=Qs(n.worldSize,r.getSouthWest
vendor: 4,767 bytes, line 1542
1542()),c=zr(-i),d=s.rotate(c),h=o.rotate(c),f=l.rotate(c),p=u.rotate(c),m=new de(Math.max(d.x,h.x,p.x,f.x),Math.max(d.y,h.y,p.y,f.y)),g=new de(Math.min(d.x,h.x,p.x,f.x),Math.min(d.y,h.y,p.y,f.y)),v=m.sub(g),x=n.width-(a.left+a.right+t.left+t.right),_=n.height-(a.top+a.bottom+t.top+t.bottom),y=x/v.x,w=_/v.y;if(w<0||y<0){WF();return}let $=Math.min(cn(n.scale*Math.min(y,w)),e.maxZoom),S=de.convert(e.offset),E=(t.left-t.right)/2,C=(t.top-t.bottom)/2,I=new de(E,C).rotate(zr(i)),P=S.add(I).mult(n.scale/In($));return{center:Nm(n.worldSize,s.add(l).div(2).sub(P)),zoom:$,bearing:i}}var Gy=class{get useGlobeControls(){return!1}handlePanInertia(e,t){let r=e.mag(),i=Math.abs(Lp(t));return{easingOffset:e.mult(Math.min(i*.75/r,1)),easingCenter:t.center}}handleMapControlsRollPitchBearingZoom(e,t){e.bearingDelta&&t.setBearing(t.bearing+e.bearingDelta),e.pitchDelta&&t.setPitch(t.pitch+e.pitchDelta),e.rollDelta&&t.setRoll(t.roll+e.rollDelta),e.zoomDelta&&t.setZoom(t.zoom+e.zoomDelta)}handleMapControlsPan(e,t,r){e.around.distSqr(t.centerPoint)<.01||t.setLocationAtPoint(r,e.around)}cameraForBoxAndBearing(e,t,r,i,n){return KF(e,t,r,i,n)}handleJumpToCenterZoom(e,t){let r=t.zoom===void 0?e.zoom:+t.zoom;e.zoom!==r&&e.setZoom(+t.zoom),t.center!==void 0&&e.setCenter(rt.convert(t.center))}handleEaseTo(e,t){let r=e.zoom,i=e.padding,n={roll:e.roll,pitch:e.pitch,bearing:e.bearing},a={roll:t.roll===void 0?e.roll:t.roll,pitch:t.pitch===void 0?e.pitch:t.pitch,bearing:t.bearing===void 0?e.bearing:t.bearing},s=t.zoom!==void 0,o=!e.isPaddingEqual(t.padding),l=!1,u=s?+t.zoom:e.zoom,c=e.centerPoint.add(t.offsetAsPoint),d=e.screenPointToLocation(c),{center:h,zoom:f}=e.applyConstrain(rt.convert(t.center||d),u??r);Vy(e,h);let p=Qs(e.worldSize,d),m=Qs(e.worldSize,h).sub(p),g=In(f-r);return l=f!==r,{easeFunc:v=>{if(l&&e.setZoom(ai.number(r,f,v)),SR(n,a)||ZF({startEulerAngles:n,endEulerAngles:a,tr:e,k:v,useSlerp:n.roll!=a.roll}),o&&(e.interpolatePadding(i,t.padding,v),c=e.centerPoint.add(t.offsetAsPoint)),t.around)e.setLocationAtPoint(t.around,t.aroundPoint);else{let x=In(e.zoom-r),_=(f>r?Math.min(2,g):Math.max(.5,g))**(1-v),y=Nm(e.worldSize,p.add(m.mult(v*_)).mult(x));e.setLocationAtPoint(e.renderWorldCopies?y.wrap():y,c)}},isZooming:l,elevationCenter:h}}handleFlyTo(e,t){let r=t.zoom!==void 0,i=e.zoom,n=e.applyConstrain(rt.convert(t.center||t.locationAtOffset),r?+t.zoom:i),a=n.center,s=n.zoom;Vy(e,a);let o=e.worldSize,l=Qs(o,t.locationAtOffset),u=Qs(o,a).sub(l),c=u.mag(),d=In(s-i),h=t.minZoom===void 0?e.minZoom:+t.minZoom,f=Math.max(h,e.minZoom),p=Math.min(f,i,s),m=e.applyConstrain(a,p).zoom;return{easeFunc:(g,v,x,_)=>{e.setZoom(g===1?s:i+cn(v));let y=g===1?a:Nm(o,l.add(u.mult(x)));e.setLocationAtPoint(e.renderWorldCopies?y.wrap():y,_)},scaleOfZoom:d,targetCenter:a,scaleOfMinZoom:In(m-i),pixelPathLength:c}}};let CIe;const kIe=()=>CIe||(CIe=new Mi({type:new Pe(ce.projection.type,"type")})),P0=ye/128;function EIe(e,t){let r=PIe(t,"16bit"),i=Gl.deserialize({arrayBuffer:r.vertices,length:r.vertices.byteLength/2/2}),n=go.deserialize({arrayBuffer:r.indices,length:r.indices.byteLength/2/3});return new wg(e.createVertexBuffer(i,qu.members),e.createIndexBuffer(n),$r.simpleSegment(0,0,i.length,n.length))}function PIe(e,t){let r=e.granularity===void 0?1:Math.max(e.granularity,1),i=r+(e.generateBorders?2:0),n=r+(e.extendToNorthPole||e.generateBorders?1:0)+(e.extendToSouthPole||e.generateBorders?1:0),a=i+1,s=n+1,o=e.generateBorders?-1:0,l=e.generateBorders||e.extendToNorthPole?-1:0,u=r+ +!!e.generateBorders,c=r+(e.generateBorders||e.extendToSouthPole?1:0),d=a*s,h=i*n*6,f=a*s>65536;if(f&&t==="16bit")throw Error("Granularity is too large and meshes would not fit inside 16 bit vertex indices.");let p=f||t==="32bit",m=new Int16Array(d*2),g=0;for(let _=l;_<=c;_++)for(let y=o;y<=u;y++){let w=y/r*ye;y===-1&&(w=-P0),y===r+1&&(w=ye+P0);let $=_/r*ye;_===-1&&($=e.extendToNorthPole?Dp:-P0),_===r+1&&($=e.extendToSouthPole?Rp:ye+P0),m[g++]=w,m[g++]=$}let v=p?new Uint32Array(h):new Uint16Array(h),x=0;for(let _=0;_<n;_++)for(let y=0;y<i;y++){let w=y+_*a,$=y+1+_*a,S=y+(_+1)*a,E=y+1+(_+1)*a;v[x++]=w,v[x++]=S,v[x++]=$,v[x++]=$,v[x++]=S,v[x++]=E}return{vertices:m.buffer.slice(0),indices:v.buffer.slice(0),uses32bitIndices:p}}const Hb=new lS({fill:new zo(128,2),line:new zo(512,0),tile:new zo(128,32),stencil:new zo(128,1),circle:3});var XF=class{constructor(){this._tileMeshCache={}}get name(){return"vertical-perspective"}get transitionState(){return 1}get useSubdivision(){return!0}get shaderVariantName(){return"globe"}get shaderDefine(){return"#define GLOBE"}get shaderPreludeCode(){return eo.projectionGlobe}get vertexShaderPreludeCode(){return eo.projectionMercator.vertexSource}get subdivisionGranularity(){return Hb}get useGlobeControls(){return!0}destroy(){}
vendor: 4,367 bytes, line 1542
1542_getMeshKey(e){return`${e.granularity.toString(36)}_${e.generateBorders?"b":""}${e.extendToNorthPole?"n":""}${e.extendToSouthPole?"s":""}`}getMeshFromTileID(e,t,r,i,n){let a=(n==="stencil"?Hb.stencil:Hb.tile).getGranularityForZoomLevel(t.z),s=t.y===0&&i,o=t.y===(1<<t.z)-1&&i;return this._getMesh(e,{granularity:a,generateBorders:r,extendToNorthPole:s,extendToSouthPole:o})}_getMesh(e,t){let r=this._getMeshKey(t);if(r in this._tileMeshCache)return this._tileMeshCache[r];let i=EIe(e,t);return this._tileMeshCache[r]=i,i}recalculate(e){}hasTransition(){return!1}},wE=class extends Rn{constructor(e,t){super(),this._transitionable=new ov(kIe(),"projection",t),this.setProjection(e),this._transitioning=this._transitionable.untransitioned(),this.recalculate(new Tr(0)),this._mercatorProjection=new n3,this._verticalPerspectiveProjection=new XF}get transitionState(){let e=this.properties.get("type");if(typeof e=="string"&&e==="mercator")return 0;if(typeof e=="string"&&e==="vertical-perspective")return 1;if(e instanceof vu){if(e.from===e.to)return e.from==="mercator"?0:1;if(e.from==="vertical-perspective"&&e.to==="mercator")return 1-e.transition;if(e.from==="mercator"&&e.to==="vertical-perspective")return e.transition}return 1}get useGlobeRendering(){return this.transitionState>0}get currentProjection(){return this.useGlobeRendering?this._verticalPerspectiveProjection:this._mercatorProjection}get name(){return"globe"}get useSubdivision(){return this.currentProjection.useSubdivision}get shaderVariantName(){return this.currentProjection.shaderVariantName}get shaderDefine(){return this.currentProjection.shaderDefine}get shaderPreludeCode(){return this.currentProjection.shaderPreludeCode}get vertexShaderPreludeCode(){return this.currentProjection.vertexShaderPreludeCode}get subdivisionGranularity(){return this.currentProjection.subdivisionGranularity}get useGlobeControls(){return this.transitionState>0}destroy(){this._mercatorProjection.destroy(),this._verticalPerspectiveProjection.destroy()}getMeshFromTileID(e,t,r,i,n){return this.currentProjection.getMeshFromTileID(e,t,r,i,n)}setProjection(e){this._transitionable.setValue("type",(e==null?void 0:e.type)||"mercator")}updateTransitions(e){this._transitioning=this._transitionable.transitioned(e,this._transitioning)}hasTransition(){return this._transitioning.hasTransition()||this.currentProjection.hasTransition()}recalculate(e){this.properties=this._transitioning.possiblyEvaluate(e)}};function JF(e){let t=_v(e.worldSize,e.center.lat);return 2*Math.PI*t}function MIe(e,t,r){let i=rn(t),n=rn(r),a=Fi(i,n),s=Math.acos(a),o=JF(e);return s/(2*Math.PI)*o}function IIe(e,t){return[Ph(e*Math.PI*2+Math.PI,Math.PI*2),2*Math.atan(Math.exp(Math.PI-t*Math.PI*2))-Math.PI*.5]}function AIe(e,t){let r=Math.cos(t),i=new Float64Array(3);return i[0]=Math.sin(e)*r,i[1]=Math.sin(t),i[2]=Math.cos(e)*r,i}function Pl(e,t,r,i,n){let a=1/(1<<n),s=e/ye*a+r*a,o=t/ye*a+i*a,l=Ph(s*Math.PI*2+Math.PI,Math.PI*2),u=2*Math.atan(Math.exp(Math.PI-o*Math.PI*2))-Math.PI*.5,c=Math.cos(u),d=new Float64Array(3);return d[0]=Math.sin(l)*c,d[1]=Math.sin(u),d[2]=Math.cos(l)*c,d}function rn(e){return AIe(e.lng*Math.PI/180,e.lat*Math.PI/180)}function _v(e,t){return e/(2*Math.PI)/Math.cos(t*Math.PI/180)}function $E(e){let t=Math.asin(e[1])/Math.PI*180,r=Math.sqrt(e[0]*e[0]+e[2]*e[2]);if(r>1e-6){let i=e[0]/r,n=e[2]/r,a=Math.acos(n),s=(i>0?a:-a)/Math.PI*180;return new rt(ys(s,-180,180),t)}return new rt(0,t)}function DIe(e){let t=Kr();return t[0]=e[0]*-e[3],t[1]=e[1]*-e[3],t[2]=e[2]*-e[3],{center:t,radius:Math.sqrt(1-e[3]*e[3])}}function RIe(e,t,r){let i=Kr();ll(i,r,e);let n=Kr();return S$e(n,e,i,t/wy(i)),n}function Hy(e){return Math.cos(e*Math.PI/180)}function Si(e,t){let r=Hy(e),i=Hy(t);return cn(i/r)}function OIe(e,t){return 360/JF({worldSize:e,center:{lat:t}})}function SE(e,t){let r=e.rotate(t.bearingInRadians),i=t.zoom+Si(t.center.lat,0),n=Ep(1/Hy(t.center.lat),1/Hy(Math.min(Math.abs(t.center.lat),60)),d_(i,7,3,0,1)),a=OIe(t.worldSize,t.center.lat);return new rt(t.center.lng-r.x*a*n,Ot(t.center.lat+r.y*a,-ul,ul))}function Yb(e){let t=.5*e,r=Math.sin(t),i=Math.cos(t);return Math.log(r+i)-Math.log(i-r)}function TE(e,t,r,i){let n=e.lat+r*i;if(Math.abs(r)>1){let a=e.lat+r,s=(Math.sign(a)===Math.sign(e.lat)?Math.abs(e.lat):-Math.abs(e.lat))*Math.PI/180,o=Math.abs(e.lat+r)*Math.PI/180,l=Yb(s+i*(o-s)),u=Yb(s),c=Yb(o
vendor: 4,523 bytes, line 1542
1542),d=(l-u)/(c-u),h=e.lng+t*d;return new rt(h,n)}{let a=e.lng+t*i;return new rt(a,n)}}var LIe=class{constructor(t){this._cachePrevious=new Map,this._cache=new Map,this._hadAnyChanges=!1,this._boundingVolumeFactory=t}swapBuffers(){if(!this._hadAnyChanges)return;let t=this._cachePrevious;this._cachePrevious=this._cache,this._cache=t,this._cache.clear(),this._hadAnyChanges=!1}getTileBoundingVolume(t,r,i,n){let a=`${t.z}_${t.x}_${t.y}_${n!=null&&n.terrain?"t":""}_${Math.round(i)}`,s=this._cache.get(a);if(s)return s;let o=this._cachePrevious.get(a);if(o)return this._cache.set(a,o),o;let l=this._boundingVolumeFactory(t,r,i,n);return this._cache.set(a,l),this._hadAnyChanges=!0,l}},Wb=class a3{constructor(t,r,i,n){this.min=i,this.max=n,this.points=t,this.planes=r}static fromAabb(t,r){let i=[];for(let n=0;n<8;n++)i.push([(n>>0&1)==1?r[0]:t[0],(n>>1&1)==1?r[1]:t[1],(n>>2&1)==1?r[2]:t[2]]);return new a3(i,[[-1,0,0,r[0]],[1,0,0,-t[0]],[0,-1,0,r[1]],[0,1,0,-t[1]],[0,0,-1,r[2]],[0,0,1,-t[2]]],t,r)}static fromCenterSizeAngles(t,r,i){let n=vR([],i[0],i[1],i[2]),a=yb([],[r[0],0,0],n),s=yb([],[0,r[1],0],n),o=yb([],[0,0,r[2]],n),l=[...t],u=[...t];for(let d=0;d<8;d++)for(let h=0;h<3;h++){let f=t[h]+a[h]*((d>>0&1)==1?1:-1)+s[h]*((d>>1&1)==1?1:-1)+o[h]*((d>>2&1)==1?1:-1);l[h]=Math.min(l[h],f),u[h]=Math.max(u[h],f)}let c=[];for(let d=0;d<8;d++){let h=[...t];Xa(h,h,ri([],a,(d>>0&1)==1?1:-1)),Xa(h,h,ri([],s,(d>>1&1)==1?1:-1)),Xa(h,h,ri([],o,(d>>2&1)==1?1:-1)),c.push(h)}return new a3(c,[[...a,-Fi(a,c[0])],[...s,-Fi(s,c[0])],[...o,-Fi(o,c[0])],[-a[0],-a[1],-a[2],-Fi(a,c[7])],[-s[0],-s[1],-s[2],-Fi(s,c[7])],[-o[0],-o[1],-o[2],-Fi(o,c[7])]],l,u)}intersectsFrustum(t){let r=!0,i=this.points.length,n=this.planes.length,a=t.planes.length,s=t.points.length;for(let o=0;o<a;o++){let l=t.planes[o],u=0;for(let c=0;c<i;c++){let d=this.points[c];l[0]*d[0]+l[1]*d[1]+l[2]*d[2]+l[3]>=0&&u++}if(u===0)return 0;u<i&&(r=!1)}if(r)return 2;for(let o=0;o<n;o++){let l=this.planes[o],u=0;for(let c=0;c<s;c++){let d=t.points[c];l[0]*d[0]+l[1]*d[1]+l[2]*d[2]+l[3]>=0&&u++}if(u===0)return 0}return 1}intersectsPlane(t){let r=this.points.length,i=0;for(let n=0;n<r;n++){let a=this.points[n];t[0]*a[0]+t[1]*a[1]+t[2]*a[2]+t[3]>=0&&i++}return i===r?2:i===0?0:1}};function x_(e,t,r){let i=e-t;return i<0?-i:Math.max(0,i-r)}function Zb(e,t,r,i,n){let a=e-r,s;return s=a<0?Math.min(-a,1+a-n):a>n?Math.min(Math.max(a-n,0),1-a):0,Math.max(s,x_(t,i,n))}var FIe=class{constructor(){this._boundingVolumeCache=new LIe(this._computeTileBoundingVolume)}prepareNextFrame(){this._boundingVolumeCache.swapBuffers()}distanceToTile2d(e,t,r,i){let n=1<<r.z,a=1/n,s=r.x/n,o=r.y/n,l=.5,u=2;return u=Math.min(u,Zb(e,t,s,o,a)),u=Math.min(u,Zb(e,t,s+l,-o-a,a)),u=Math.min(u,Zb(e,t,s+l,2-o-a,a)),u}getWrap(e,t,r){let i=1<<t.z,n=1/i,a=t.x/i,s=x_(e.x,a,n),o=x_(e.x,a-1,n),l=x_(e.x,a+1,n),u=Math.min(s,o,l);return u===l?1:u===o?-1:0}allowVariableZoom(e,t){return CS(e,t)>4}allowWorldCopies(){return!1}getTileBoundingVolume(e,t,r,i){return this._boundingVolumeCache.getTileBoundingVolume(e,t,r,i)}_computeTileBoundingVolume(e,t,r,i){let n=Math.min(0,r),a=Math.max(0,r);if(i!=null&&i.terrain){let s=new Ri(e.z,t,e.z,e.x,e.y),o=i.terrain.getMinMaxElevation(s);n=o.minElevation??n,a=o.maxElevation??a}if(n/=Ql,a/=Ql,n+=1,a+=1,e.z<=0)return Wb.fromAabb([-a,-a,-a],[a,a,a]);if(e.z===1)return Wb.fromAabb([e.x===0?-a:0,e.y===0?0:-a,-a],[e.x===0?0:a,e.y===0?a:0,a]);{let s=[Pl(0,0,e.x,e.y,e.z),Pl(ye,0,e.x,e.y,e.z),Pl(ye,ye,e.x,e.y,e.z),Pl(0,ye,e.x,e.y,e.z)],o=[];for(let E of s)o.push(ri([],E,a));if(a!==n)for(let E of s)o.push(ri([],E,n));e.y===0&&o.push([0,1,0]),e.y===(1<<e.z)-1&&o.push([0,-1,0]);let l=[1,1,1],u=[-1,-1,-1];for(let E of o)for(let C=0;C<3;C++)l[C]=Math.min(l[C],E[C]),u[C]=Math.max(u[C],E[C]);let c=Pl(ye/2,ye/2,e.x,e.y,e.z),d=ya([],[0,1,0],c);Ga(d,d);let h=ya([],c,d);Ga(h,h);let f=ya([],s[2],s[1]);Ga(f,f);let p=ya([],s[0],s[3]);Ga(p,p),o.push(ri([],c,a)),e.y>=(1<<e.z)/2&&o.push(ri([],Pl(ye/2,0,e.x,e.y,e.z),a)),e.y<(1<<e.z)/2&&o.push(ri([],Pl(ye/2,ye,e.x,e.y,e.z),a));let m=CE(c,o),g=CE(h,o),v=[-c[0],-c[1],-c[2],m.max],x=[c[0],c[1],c[2],-m.min],_=[-h[0],-h[1],-h[2],g.max],y=[h[0],h[1],h[2],-g.min],w=[...f,0],$=[...p,0],S=[];return e.y===0?S.push(Aa($,w,v),Aa($,w,x)):S.push(Aa(_,w,v),Aa(_,w,x),Aa(_,$,v),Aa(_,$,x)),e.y===(1<<e.z)-1?S.push(Aa($,w,v),Aa($,w,x)):S.push(Aa(y,w,v),Aa(y,w,x),Aa(y,$,v),Aa(y,$,x)),new Wb(S,[v,x,_,y,w,$],l,u)}}};function CE(e,t){let r=1/0,i=-1/0;for(let n of t){let a=Fi(e,n);r=Math.min(r,a),i=Math.max(i,a)}return{min:r,max:i}}
vendor: 10,436 bytes, line 1542
1542var QF=class ez{get pixelsToClipSpaceMatrix(){return this._helper.pixelsToClipSpaceMatrix}get clipSpaceToPixelsMatrix(){return this._helper.clipSpaceToPixelsMatrix}get pixelsToGLUnits(){return this._helper.pixelsToGLUnits}get centerOffset(){return this._helper.centerOffset}get size(){return this._helper.size}get rotationMatrix(){return this._helper.rotationMatrix}get centerPoint(){return this._helper.centerPoint}get pixelsPerMeter(){return this._helper.pixelsPerMeter}setMinZoom(t){this._helper.setMinZoom(t)}setMaxZoom(t){this._helper.setMaxZoom(t)}setMinPitch(t){this._helper.setMinPitch(t)}setMaxPitch(t){this._helper.setMaxPitch(t)}setRenderWorldCopies(t){this._helper.setRenderWorldCopies(t)}setBearing(t){this._helper.setBearing(t)}setPitch(t){this._helper.setPitch(t)}setRoll(t){this._helper.setRoll(t)}setFov(t){this._helper.setFov(t)}setZoom(t){this._helper.setZoom(t)}setCenter(t){this._helper.setCenter(t)}setElevation(t){this._helper.setElevation(t)}setMinElevationForCurrentTile(t){this._helper.setMinElevationForCurrentTile(t)}setPadding(t){this._helper.setPadding(t)}interpolatePadding(t,r,i){this._helper.interpolatePadding(t,r,i)}isPaddingEqual(t){return this._helper.isPaddingEqual(t)}resize(t,r){this._helper.resize(t,r)}getMaxBounds(){return this._helper.getMaxBounds()}setMaxBounds(t){this._helper.setMaxBounds(t)}setConstrainOverride(t){this._helper.setConstrainOverride(t)}overrideNearFarZ(t,r){this._helper.overrideNearFarZ(t,r)}clearNearFarZOverride(){this._helper.clearNearFarZOverride()}getCameraQueryGeometry(t){return this._helper.getCameraQueryGeometry(this.getCameraPoint(),t)}get tileSize(){return this._helper.tileSize}get tileZoom(){return this._helper.tileZoom}get scale(){return this._helper.scale}get worldSize(){return this._helper.worldSize}get width(){return this._helper.width}get height(){return this._helper.height}get lngRange(){return this._helper.lngRange}get latRange(){return this._helper.latRange}get minZoom(){return this._helper.minZoom}get maxZoom(){return this._helper.maxZoom}get zoom(){return this._helper.zoom}get center(){return this._helper.center}get minPitch(){return this._helper.minPitch}get maxPitch(){return this._helper.maxPitch}get pitch(){return this._helper.pitch}get pitchInRadians(){return this._helper.pitchInRadians}get roll(){return this._helper.roll}get rollInRadians(){return this._helper.rollInRadians}get bearing(){return this._helper.bearing}get bearingInRadians(){return this._helper.bearingInRadians}get fov(){return this._helper.fov}get fovInRadians(){return this._helper.fovInRadians}get elevation(){return this._helper.elevation}get minElevationForCurrentTile(){return this._helper.minElevationForCurrentTile}get padding(){return this._helper.padding}get unmodified(){return this._helper.unmodified}get renderWorldCopies(){return this._helper.renderWorldCopies}get constrainOverride(){return this._helper.constrainOverride}get nearZ(){return this._helper.nearZ}get farZ(){return this._helper.farZ}get autoCalculateNearFarZ(){return this._helper.autoCalculateNearFarZ}setTransitionState(t){}constructor(t){this._cachedClippingPlane=Tf(),this._projectionMatrix=h0(),this._globeViewProjMatrix32f=xR(),this._globeViewProjMatrixF64=h0(),this._globeViewProjMatrixF64Inverted=h0(),this._globeProjMatrixInverted=h0(),this._cameraPosition=Kr(),this.defaultConstrain=(r,i)=>{let n=Ot(r.lat,-ul,ul),a=Ot(+i,this.minZoom+Si(0,n),this.maxZoom);return{center:new rt(r.lng,n),zoom:a}},this.applyConstrain=(r,i)=>this._helper.applyConstrain(r,i),this._helper=new IS({calcMatrices:()=>this._calcMatrices(),defaultConstrain:(r,i)=>this.defaultConstrain(r,i)},t),this._coveringTilesDetailsProvider=new FIe}clone(){let t=new ez;return t.apply(this,!1),t}apply(t,r){this._helper.apply(t,r)}get projectionMatrix(){return this._projectionMatrix}get modelViewProjectionMatrix(){return this._globeViewProjMatrixF64}get inverseProjectionMatrix(){return this._globeProjMatrixInverted}get cameraPosition(){let t=Kr();return t[0]=this._cameraPosition[0],t[1]=this._cameraPosition[1],t[2]=this._cameraPosition[2],t}get cameraToCenterDistance(){return this._helper.cameraToCenterDistance}getProjectionData(t){let{overscaledTileID:r,applyGlobeMatrix:i}=t,n=this._helper.getMercatorTileCoordinates(r);return{mainMatrix:this._globeViewProjMatrix32f,tileMercatorCoords:n,clippingPlane:this._cachedClippingPlane,projectionTransition:+!!i,fallbackMatrix:this._globeViewProjMatrix32f,clipAntimeridian:(r==null?void 0:r.canonical.z)===0}}_computeClippingPlane(t){let r=this.pitchInRadians,i=this.cameraToCenterDistance/t,n=Math.sin(r)*i,a=Math.cos(r)*i+1,s=1/Math.sqrt(n*n+a*a)*1,o=-n,l=a,u=Math.sqrt(o*o+l*l);o/=u,l/=u;let c=[0,o,l];vb(c,c,[0,0,0],-this.bearingInRadians),c0(c,c,[0,0,0],-1*this.center.lat*Math.PI/180),Sf(c,c,[0,0,0],this.center.lng*Math.PI/180);let d=1/q1(c);return ri(c,c,d),[...c,-s*d]}isLocationOccluded(t){return!this.isSurfacePointVisible(rn(t))}transformLightDirection(t){let r=this._helper._center.lng*Math.PI/180,i=this._helper._center.lat*Math.PI/180,n=Math.cos(i),a=[Math.sin(r)*n,Math.sin(i),Math.cos(r)*n],s=[a[2],0,-a[0]],o=[0,0,0];ya(o,s,a),Ga(s,s),Ga(o,o);let l=[s[0]*t[0]+o[0]*t[1]+a[0]*t[2],s[1]*t[0]+o[1]*t[1]+a[1]*t[2],s[2]*t[0]+o[2]*t[1]+a[2]*t[2]],u=[0,0,0];return Ga(u,l),u}getPixelScale(){return 1/Math.cos(this._helper._center.lat*Math.PI/180)}getCircleRadiusCorrection(){return Math.cos(this._helper._center.lat*Math.PI/180)}getPitchedTextCorrection(t,r,i){let n=jL(t,r,i.canonical),a=IIe(n.x,n.y);return this.getCircleRadiusCorrection()/Math.cos(a[1])}projectTileCoordinates(t,r,i,n){let a=i.canonical,s=Pl(t,r,a.x,a.y,a.z),o=1+(n?n(t,r):0)/Ql,l=[s[0]*o,s[1]*o,s[2]*o,1];_i(l,l,this._globeViewProjMatrixF64);let u=this._cachedClippingPlane,c=u[0]*s[0]+u[1]*s[1]+u[2]*s[2]+u[3]<0;return{point:new de(l[0]/l[3],l[1]/l[3]),signedDistanceFromCamera:l[3],isOccluded:c}}_calcMatrices(){if(!this._helper._width||!this._helper._height)return;let t=_v(this.worldSize,this.center.lat),r=Uu();this._helper.autoCalculateNearFarZ&&(this._helper._nearZ=.5,this._helper._farZ=this.cameraToCenterDistance+t*2),zx(r,this.fovInRadians,this.width/this.height,this._helper._nearZ,this._helper._farZ);let i=this.centerOffset;r[8]=-i.x*2/this._helper._width,r[9]=i.y*2/this._helper._height,this._projectionMatrix=Fx(r),this._globeProjMatrixInverted=Uu(),xy(this._globeProjMatrixInverted,r),ei(r,r,[0,0,-this.cameraToCenterDistance]),Vl(r,r,this.rollInRadians),Eh(r,r,-this.pitchInRadians),Vl(r,r,this.bearingInRadians),ei(r,r,[0,0,-t]);let n=Kr();n[0]=t,n[1]=t,n[2]=t,Eh(r,r,this.center.lat*Math.PI/180),_R(r,r,-this.center.lng*Math.PI/180),Li(r,r,n),this._globeViewProjMatrixF64=r,this._globeViewProjMatrix32f=new Float32Array(r),this._globeViewProjMatrixF64Inverted=Uu(),xy(this._globeViewProjMatrixF64Inverted,r);let a=Kr();this._cameraPosition=Kr(),this._cameraPosition[2]=this.cameraToCenterDistance/t,vb(this._cameraPosition,this._cameraPosition,a,-this.rollInRadians),c0(this._cameraPosition,this._cameraPosition,a,this.pitchInRadians),vb(this._cameraPosition,this._cameraPosition,a,-this.bearingInRadians),Xa(this._cameraPosition,this._cameraPosition,[0,0,1]),c0(this._cameraPosition,this._cameraPosition,a,-this.center.lat*Math.PI/180),Sf(this._cameraPosition,this._cameraPosition,a,this.center.lng*Math.PI/180),this._cachedClippingPlane=this._computeClippingPlane(t);let s=Fx(this._globeViewProjMatrixF64Inverted);Li(s,s,[1,1,-1]),this._cachedFrustum=GF.fromInvProjectionMatrix(s,1,0,this._cachedClippingPlane,!0)}calculateFogMatrix(t){vr("calculateFogMatrix is not supported on globe projection.");let r=Uu();return Ms(r),r}getVisibleUnwrappedCoordinates(t){return[new jy(0,t)]}getCameraFrustum(){return this._cachedFrustum}getClippingPlane(){return this._cachedClippingPlane}getCoveringTilesDetailsProvider(){return this._coveringTilesDetailsProvider}recalculateZoomAndCenter(t){if(t){vr("terrain is not fully supported on vertical perspective projection.");return}this._helper.recalculateZoomAndCenter(0)}maxPitchScaleFactor(){return 1}getCameraPoint(){return this._helper.getCameraPoint()}getCameraAltitude(){return this._helper.getCameraAltitude()}getCameraLngLat(){return this._helper.getCameraLngLat()}lngLatToCameraDepth(t,r){if(!this._globeViewProjMatrixF64)return 1;let i=rn(t);ri(i,i,1+r/Ql);let n=Tf();return _i(n,[i[0],i[1],i[2],1],this._globeViewProjMatrixF64),n[2]/n[3]}populateCache(t){}getBounds(){let t=this.width*.5,r=this.height*.5,i=[new de(0,0),new de(t,0),new de(this.width,0),new de(this.width,r),new de(this.width,this.height),new de(t,this.height),new de(0,this.height),new de(0,r)],n=[];for(let d of i)n.push(this.unprojectScreenPoint(d));let a=0,s=0,o=0,l=0,u=this.center;for(let d of n){let h=na(u.lng,d.lng),f=na(u.lat,d.lat);h<s&&(s=h),h>a&&(a=h),f<l&&(l=f),f>o&&(o=f)}let c=[u.lng+s,u.lat+l,u.lng+a,u.lat+o];return this.isSurfacePointOnScreen([0,1,0])&&(c[3]=90,c[0]=-180,c[2]=180),this.isSurfacePointOnScreen([0,-1,0])&&(c[1]=-90,c[0]=-180,c[2]=180),new co(c)}calculateCenterFromCameraLngLatAlt(t,r,i,n){return this._helper.calculateCenterFromCameraLngLatAlt(t,r,i,n)}setLocationAtPoint(t,r){let i=rn(this.unprojectScreenPoint(r)),n=rn(t),a=Kr();E$e(a);let s=Kr();Sf(s,i,a,-this.center.lng*Math.PI/180),c0(s,s,a,this.center.lat*Math.PI/180);let o=n[0]*n[0]+n[2]*n[2],l=s[0]*s[0];if(o<l)return;let u=Math.sqrt(o-l),c=-u,d=f0(n[0],n[2],s[0],u),h=f0(n[0],n[2],s[0],c),f=Kr();Sf(f,n,a,-d);let p=f0(f[1],f[2],s[1],s[2]),m=Kr();Sf(m,n,a,-h);let g=f0(m[1],m[2],s[1],s[2]),v=Math.PI*.5,x=p>=-v&&p<=v,_=g>=-v&&g<=v,y,w;if(x&&_){let C=this.center.lng*Math.PI/180,I=this.center.lat*Math.PI/180,P=p0(d,C),T=p0(p,I),D=p0(h,C),A=p0(g,I);P+T<D+A?(y=d,w=p):(y=h,w=g)}else if(x)y=d,w=p;else if(_)y=h,w=g;else return;let $=y/Math.PI*180,S=w/Math.PI*180,E=this.center.lat;this.setCenter(new rt($,Ot(S,-90,90))),this.setZoom(this.zoom+Si(E,this.center.lat))}locationToScreenPoint(t,r){let i=rn(t);if(r){let n=r.getElevationForLngLatZoom(t,this._helper._tileZoom);ri(i,i,1+n/Ql)}return this._projectSurfacePointToScreen(i)}_projectSurfacePointToScreen(t){let r=Tf();return _i(r,[...t,1],this._globeViewProjMatrixF64),r[0]/=r[3],r[1]/=r[3],new de((r[0]*.5+.5)*this.width,(-r[1]*.5+.5)*this.height)}screenPointToMercatorCoordinate(t,r){if(r){let i=r.pointCoordinate(t);if(i)return i}return nr.fromLngLat(this.unprojectScreenPoint(t))}screenPointToLocation(t,r){var i;return(i=this.screenPointToMercatorCoordinate(t,r))==null?void 0:i.toLngLat()}
vendor: 5,641 bytes, line 1542
1542isPointOnMapSurface(t,r){let i=this._cameraPosition,n=this.getRayDirectionFromPixel(t);return!!this.rayPlanetIntersection(i,n)}getRayDirectionFromPixel(t){let r=Tf();r[0]=t.x/this.width*2-1,r[1]=(t.y/this.height*2-1)*-1,r[2]=1,r[3]=1,_i(r,r,this._globeViewProjMatrixF64Inverted),r[0]/=r[3],r[1]/=r[3],r[2]/=r[3];let i=Kr();i[0]=r[0]-this._cameraPosition[0],i[1]=r[1]-this._cameraPosition[1],i[2]=r[2]-this._cameraPosition[2];let n=Kr();return Ga(n,i),n}isSurfacePointVisible(t){let r=this._cachedClippingPlane;return r[0]*t[0]+r[1]*t[1]+r[2]*t[2]+r[3]>=0}isSurfacePointOnScreen(t){if(!this.isSurfacePointVisible(t))return!1;let r=Tf();return _i(r,[...t,1],this._globeViewProjMatrixF64),r[0]/=r[3],r[1]/=r[3],r[2]/=r[3],r[0]>-1&&r[0]<1&&r[1]>-1&&r[1]<1&&r[2]>-1&&r[2]<1}rayPlanetIntersection(t,r){let i=Fi(t,r),n=Kr(),a=Kr();ri(a,r,i),ll(n,t,a);let s=1-Fi(n,n);if(s<0)return null;let o=Fi(t,t)-1,l=-i+(i<0?1:-1)*Math.sqrt(s),u=o/l,c=l;return{tMin:Math.min(u,c),tMax:Math.max(u,c)}}unprojectScreenPoint(t){let r=this._cameraPosition,i=this.getRayDirectionFromPixel(t),n=this.rayPlanetIntersection(r,i);if(n){let c=Kr();Xa(c,r,[i[0]*n.tMin,i[1]*n.tMin,i[2]*n.tMin]);let d=Kr();return Ga(d,c),$E(d)}let a=this._cachedClippingPlane,s=a[0]*i[0]+a[1]*i[1]+a[2]*i[2],o=-Ux(a,r)/s,l=Kr();if(o>0)Xa(l,r,[i[0]*o,i[1]*o,i[2]*o]);else{let c=Kr();Xa(c,r,[i[0]*2,i[1]*2,i[2]*2]);let d=Ux(this._cachedClippingPlane,c);ll(l,c,[this._cachedClippingPlane[0]*d,this._cachedClippingPlane[1]*d,this._cachedClippingPlane[2]*d])}let u=DIe(a);return $E(RIe(u.center,u.radius,l))}getProjectionDataForCustomLayer(t=!0){let r=this.getProjectionData({overscaledTileID:new Ri(0,0,0,0,0),applyGlobeMatrix:t});return r.tileMercatorCoords=[0,0,1,1],r}getFastPathSimpleProjectionMatrix(t){}},kE=class tz{get pixelsToClipSpaceMatrix(){return this._helper.pixelsToClipSpaceMatrix}get clipSpaceToPixelsMatrix(){return this._helper.clipSpaceToPixelsMatrix}get pixelsToGLUnits(){return this._helper.pixelsToGLUnits}get centerOffset(){return this._helper.centerOffset}get size(){return this._helper.size}get rotationMatrix(){return this._helper.rotationMatrix}get centerPoint(){return this._helper.centerPoint}get pixelsPerMeter(){return this._helper.pixelsPerMeter}setMinZoom(t){this._helper.setMinZoom(t)}setMaxZoom(t){this._helper.setMaxZoom(t)}setMinPitch(t){this._helper.setMinPitch(t)}setMaxPitch(t){this._helper.setMaxPitch(t)}setRenderWorldCopies(t){this._helper.setRenderWorldCopies(t)}setBearing(t){this._helper.setBearing(t)}setPitch(t){this._helper.setPitch(t)}setRoll(t){this._helper.setRoll(t)}setFov(t){this._helper.setFov(t)}setZoom(t){this._helper.setZoom(t)}setCenter(t){this._helper.setCenter(t)}setElevation(t){this._helper.setElevation(t)}setMinElevationForCurrentTile(t){this._helper.setMinElevationForCurrentTile(t)}setPadding(t){this._helper.setPadding(t)}interpolatePadding(t,r,i){this._helper.interpolatePadding(t,r,i)}isPaddingEqual(t){return this._helper.isPaddingEqual(t)}resize(t,r,i=!0){this._helper.resize(t,r,i)}getMaxBounds(){return this._helper.getMaxBounds()}setMaxBounds(t){this._helper.setMaxBounds(t)}setConstrainOverride(t){this._helper.setConstrainOverride(t)}overrideNearFarZ(t,r){this._helper.overrideNearFarZ(t,r)}clearNearFarZOverride(){this._helper.clearNearFarZOverride()}getCameraQueryGeometry(t){return this._helper.getCameraQueryGeometry(this.getCameraPoint(),t)}get tileSize(){return this._helper.tileSize}get tileZoom(){return this._helper.tileZoom}get scale(){return this._helper.scale}get worldSize(){return this._helper.worldSize}get width(){return this._helper.width}get height(){return this._helper.height}get lngRange(){return this._helper.lngRange}get latRange(){return this._helper.latRange}get minZoom(){return this._helper.minZoom}get maxZoom(){return this._helper.maxZoom}get zoom(){return this._helper.zoom}get center(){return this._helper.center}get minPitch(){return this._helper.minPitch}get maxPitch(){return this._helper.maxPitch}get pitch(){return this._helper.pitch}get pitchInRadians(){return this._helper.pitchInRadians}get roll(){return this._helper.roll}get rollInRadians(){return this._helper.rollInRadians}get bearing(){return this._helper.bearing}get bearingInRadians(){return this._helper.bearingInRadians}get fov(){return this._helper.fov}get fovInRadians(){return this._helper.fovInRadians}get elevation(){return this._helper.elevation}get minElevationForCurrentTile(){return this._helper.minElevationForCurrentTile}get padding(){return this._helper.padding}get unmodified(){return this._helper.unmodified}get renderWorldCopies(){return this._helper.renderWorldCopies}get cameraToCenterDistance(){return this._helper.cameraToCenterDistance}get constrainOverride(){return this._helper.constrainOverride}get nearZ(){return this._helper.nearZ}get farZ(){return this._helper.farZ}get autoCalculateNearFarZ(){return this._helper.autoCalculateNearFarZ}get isGlobeRendering(){return this._globeness>0}setTransitionState(t){this._globeness=t,this._calcMatrices(),this._verticalPerspectiveTransform.getCoveringTilesDetailsProvider().prepareNextFrame(),this._mercatorTransform.getCoveringTilesDetailsProvider().prepareNextFrame()}get currentTransform(){return this.isGlobeRendering?this._verticalPerspectiveTransform:this._mercatorTransform}constructor(t){this._globeness=1,this.defaultConstrain=(r,i)=>this.currentTransform.defaultConstrain(r,i),this.applyConstrain=(r,i)=>this._helper.applyConstrain(r,i),this._helper=new IS({calcMatrices:()=>this._calcMatrices(),defaultConstrain:(r,i)=>this.defaultConstrain(r,i)},t),this._globeness=1,this._mercatorTransform=new qy,this._verticalPerspectiveTransform=new Q
vendor: 4,390 bytes, line 1542
1542F}clone(){let t=new tz;return t._globeness=this._globeness,t.apply(this,!1),t}apply(t,r){this._helper.apply(t,r),this._mercatorTransform.apply(this,!1),this._verticalPerspectiveTransform.apply(this,!1)}get projectionMatrix(){return this.currentTransform.projectionMatrix}get modelViewProjectionMatrix(){return this.currentTransform.modelViewProjectionMatrix}get inverseProjectionMatrix(){return this.currentTransform.inverseProjectionMatrix}get cameraPosition(){return this.currentTransform.cameraPosition}getProjectionData(t){let r=this._mercatorTransform.getProjectionData(t),i=this._verticalPerspectiveTransform.getProjectionData(t);return{mainMatrix:this.isGlobeRendering?i.mainMatrix:r.mainMatrix,clippingPlane:i.clippingPlane,tileMercatorCoords:i.tileMercatorCoords,projectionTransition:t.applyGlobeMatrix?this._globeness:0,fallbackMatrix:r.fallbackMatrix,clipAntimeridian:i.clipAntimeridian}}isLocationOccluded(t){return this.currentTransform.isLocationOccluded(t)}transformLightDirection(t){return this.currentTransform.transformLightDirection(t)}getPixelScale(){return Ep(this._mercatorTransform.getPixelScale(),this._verticalPerspectiveTransform.getPixelScale(),this._globeness)}getCircleRadiusCorrection(){return Ep(this._mercatorTransform.getCircleRadiusCorrection(),this._verticalPerspectiveTransform.getCircleRadiusCorrection(),this._globeness)}getPitchedTextCorrection(t,r,i){let n=this._mercatorTransform.getPitchedTextCorrection(t,r,i),a=this._verticalPerspectiveTransform.getPitchedTextCorrection(t,r,i);return Ep(n,a,this._globeness)}projectTileCoordinates(t,r,i,n){return this.currentTransform.projectTileCoordinates(t,r,i,n)}_calcMatrices(){!this._helper._width||!this._helper._height||(this._verticalPerspectiveTransform.apply(this,!1),this._helper._nearZ=this._verticalPerspectiveTransform.nearZ,this._helper._farZ=this._verticalPerspectiveTransform.farZ,this._mercatorTransform.apply(this,!0,this.isGlobeRendering),this._helper._nearZ=this._mercatorTransform.nearZ,this._helper._farZ=this._mercatorTransform.farZ)}calculateFogMatrix(t){return this.currentTransform.calculateFogMatrix(t)}getVisibleUnwrappedCoordinates(t){return this.currentTransform.getVisibleUnwrappedCoordinates(t)}getCameraFrustum(){return this.currentTransform.getCameraFrustum()}getClippingPlane(){return this.currentTransform.getClippingPlane()}getCoveringTilesDetailsProvider(){return this.currentTransform.getCoveringTilesDetailsProvider()}recalculateZoomAndCenter(t){this.currentTransform.recalculateZoomAndCenter(t)}maxPitchScaleFactor(){return this._mercatorTransform.maxPitchScaleFactor()}getCameraPoint(){return this._helper.getCameraPoint()}getCameraAltitude(){return this._helper.getCameraAltitude()}getCameraLngLat(){return this._helper.getCameraLngLat()}lngLatToCameraDepth(t,r){return this.currentTransform.lngLatToCameraDepth(t,r)}populateCache(t){this._mercatorTransform.populateCache(t),this._verticalPerspectiveTransform.populateCache(t)}getBounds(){return this.currentTransform.getBounds()}calculateCenterFromCameraLngLatAlt(t,r,i,n){return this._helper.calculateCenterFromCameraLngLatAlt(t,r,i,n)}setLocationAtPoint(t,r){if(!this.isGlobeRendering){this._mercatorTransform.setLocationAtPoint(t,r),this.apply(this._mercatorTransform,!1);return}this._verticalPerspectiveTransform.setLocationAtPoint(t,r),this.apply(this._verticalPerspectiveTransform,!1)}locationToScreenPoint(t,r){return this.currentTransform.locationToScreenPoint(t,r)}screenPointToMercatorCoordinate(t,r){return this.currentTransform.screenPointToMercatorCoordinate(t,r)}screenPointToLocation(t,r){return this.currentTransform.screenPointToLocation(t,r)}isPointOnMapSurface(t,r){return this.currentTransform.isPointOnMapSurface(t,r)}getRayDirectionFromPixel(t){return this._verticalPerspectiveTransform.getRayDirectionFromPixel(t)}getProjectionDataForCustomLayer(t=!0){let r=this._mercatorTransform.getProjectionDataForCustomLayer(t);if(!this.isGlobeRendering)return r;let i=this._verticalPerspectiveTransform.getProjectionDataForCustomLayer(t);return i.fallbackMatrix=r.mainMatrix,i}getFastPathSimpleProjectionMatrix(t){return this.currentTransform.getFastPathSimpleProjectionMatrix(t)}},rz=class $o{get useGlobeControls(){return!0}handlePanInertia(t,r){let i=SE(t,r);return Math.abs(i.lng-r.center.lng)>180&&(i.lng=r.center.lng+179.5*Math.sign(i.lng-r.center.lng)),{easingCenter:i,easingOffset:new de(0,0)}}
1542handleMapControlsRollPitchBearingZoom(t,r){let i=t.around,n=r.screenPointToLocation(i);t.bearingDelta&&r.setBearing(r.bearing+t.bearingDelta),t.pitchDelta&&r.setPitch(r.pitch+t.pitchDelta),t.rollDelta&&r.setRoll(r.roll+t.rollDelta);let a=r.zoom;t.zoomDelta&&r.setZoom(r.zoom+t.zoomDelta);let s=r.zoom-a;if(s===0)return;let o=na(r.center.lng,n.lng),l=o/(Math.abs(o/180)+1),u=na(r.center.lat,n.lat),c=r.getRayDirectionFromPixel(i),d=r.cameraPosition,h=Fi(d,c)*-1,f=Kr();Xa(f,d,[c[0]*h,c[1]*h,c[2]*h]);let p=q1(f)-1,m=Math.exp(-Math.max(p-.3,0)*.5),g=_v(r.worldSize,r.center.lat)/Math.min(r.width,r.height),v=d_(g,.9,.5,1,.25),x=(1-In(-s))*Math.min(m,v),_=r.center.lat,y=r.zoom,w=new rt(r.center.lng+l*x,Ot(r.center.lat+u*x,-ul,ul));r.setLocationAtPoint(n,i);let $=r.center,S=d_(Math.abs(o),45,85,0,1),E=d_(g,.75,.35,0,1),C=Math.max(S,E)**.25,I=na($.lng,w.lng),P=na($.lat,w.lat);r.setCenter(new rt($.lng+I*C,$.lat+P*C).wrap()),r.setZoom(y+Si(_,r.center.lat))}handleMapControlsPan(t,r,i){if(!t.panDelta)return;let n=r.center.lat,a=r.zoom;r.setCenter(SE(t.panDelta,r).wrap()),r.setZoom(a+Si(n,r.center.lat))}cameraForBoxAndBearing(t,r,i,n,a){let s=KF(t,r,i,n,a),o=r.left/a.width*2-1,l=(a.width-r.right)/a.width*2-1,u=r.top/a.height*-2+1,c=(a.height-r.bottom)/a.height*-2+1,d=na(i.getWest(),i.getEast())<0,h=d?i.getEast():i.getWest(),f=d?i.getWest():i.getEast(),p=Math.max(i.getNorth(),i.getSouth()),m=Math.min(i.getNorth(),i.getSouth()),g=h+na(h,f)*.5,v=p+na(p,m)*.5,x=a.clone();x.setCenter(s.center),x.setBearing(s.bearing),x.setPitch(0),x.setRoll(0),x.setZoom(s.zoom);let _=x.modelViewProjectionMatrix,y=[rn(i.getNorthWest()),rn(i.getNorthEast()),rn(i.getSouthWest
vendor: 4,633 bytes, line 1542
1542()),rn(i.getSouthEast()),rn(new rt(f,v)),rn(new rt(h,v)),rn(new rt(g,p)),rn(new rt(g,m))],w=rn(s.center),$=1/0;for(let S of y)o<0&&($=$o.getLesserNonNegativeNonNull($,$o.solveVectorScale(S,w,_,"x",o))),l>0&&($=$o.getLesserNonNegativeNonNull($,$o.solveVectorScale(S,w,_,"x",l))),u>0&&($=$o.getLesserNonNegativeNonNull($,$o.solveVectorScale(S,w,_,"y",u))),c<0&&($=$o.getLesserNonNegativeNonNull($,$o.solveVectorScale(S,w,_,"y",c)));if(!Number.isFinite($)||$===0){WF();return}return s.zoom=Math.min(x.zoom+cn($),t.maxZoom),s}handleJumpToCenterZoom(t,r){let i=t.center.lat,n=t.applyConstrain(r.center?rt.convert(r.center):t.center,t.zoom).center;t.setCenter(n.wrap());let a=r.zoom===void 0?t.zoom+Si(i,n.lat):+r.zoom;t.zoom!==a&&t.setZoom(a)}handleEaseTo(t,r){let i=t.zoom,n=t.center,a=t.padding,s={roll:t.roll,pitch:t.pitch,bearing:t.bearing},o={roll:r.roll===void 0?t.roll:r.roll,pitch:r.pitch===void 0?t.pitch:r.pitch,bearing:r.bearing===void 0?t.bearing:r.bearing},l=r.zoom!==void 0,u=!t.isPaddingEqual(r.padding),c=!1,d=r.center?rt.convert(r.center):n,h=t.applyConstrain(d,i).center;Vy(t,h);let f=t.clone();f.setCenter(h),f.setZoom(l?+r.zoom:i+Si(n.lat,d.lat)),f.setBearing(r.bearing);let p=new de(Ot(t.centerPoint.x+r.offsetAsPoint.x,0,t.width),Ot(t.centerPoint.y+r.offsetAsPoint.y,0,t.height));f.setLocationAtPoint(h,p);let m=(r.offset&&r.offsetAsPoint.mag())>0?f.center:h,g=l?+r.zoom:i+Si(n.lat,m.lat),v=i+Si(n.lat,0),x=g+Si(m.lat,0),_=na(n.lng,m.lng),y=na(n.lat,m.lat),w=In(x-v);return c=g!==i,{easeFunc:$=>{if(SR(s,o)||ZF({startEulerAngles:s,endEulerAngles:o,tr:t,k:$,useSlerp:s.roll!=o.roll}),u&&t.interpolatePadding(a,r.padding,$),r.around)vr("Easing around a point is not supported under globe projection."),t.setLocationAtPoint(r.around,r.aroundPoint);else{let S=$*(x>v?Math.min(2,w):Math.max(.5,w))**(1-$),E=TE(n,_,y,S);t.setCenter(E.wrap())}if(c){let S=ai.number(v,x,$)+Si(0,t.center.lat);t.setZoom(S)}},isZooming:c,elevationCenter:m}}handleFlyTo(t,r){let i=r.zoom!==void 0,n=t.center,a=t.zoom,s=t.padding,o=!t.isPaddingEqual(r.padding),l=t.applyConstrain(rt.convert(r.center||r.locationAtOffset),a).center,u=i?+r.zoom:t.zoom+Si(t.center.lat,l.lat),c=t.clone();c.setCenter(l),c.setZoom(u),c.setBearing(r.bearing);let d=new de(Ot(t.centerPoint.x+r.offsetAsPoint.x,0,t.width),Ot(t.centerPoint.y+r.offsetAsPoint.y,0,t.height));c.setLocationAtPoint(l,d);let h=c.center;Vy(t,h);let f=MIe(t,n,h),p=a+Si(n.lat,0),m=u+Si(h.lat,0),g=In(m-p),v=typeof r.minZoom=="number"?+r.minZoom:t.minZoom,x=Math.max(v,t.minZoom)+Si(h.lat,0),_=Math.min(x,p,m)+Si(0,h.lat),y=t.applyConstrain(h,_).zoom+Si(h.lat,0),w=In(y-p),$=na(n.lng,h.lng),S=na(n.lat,h.lat);return{easeFunc:(E,C,I,P)=>{let T=TE(n,$,S,I);o&&t.interpolatePadding(s,r.padding,E);let D=E===1?h:T;t.setCenter(D.wrap());let A=p+cn(C);t.setZoom(E===1?u:A+Si(0,D.lat))},scaleOfZoom:g,targetCenter:h,scaleOfMinZoom:w,pixelPathLength:f}}static solveVectorScale(t,r,i,n,a){let s=a,o=n==="x"?[i[0],i[4],i[8],i[12]]:[i[1],i[5],i[9],i[13]],l=[i[3],i[7],i[11],i[15]],u=t[0]*o[0]+t[1]*o[1]+t[2]*o[2],c=t[0]*l[0]+t[1]*l[1]+t[2]*l[2],d=r[0]*o[0]+r[1]*o[1]+r[2]*o[2],h=r[0]*l[0]+r[1]*l[1]+r[2]*l[2],f=(d+o[3]-s*h-s*l[3])/(d-u-s*h+s*c);return d+s*c===u+s*h||l[3]*(u-d)+o[3]*(h-c)+u*h===d*c?null:f}static getLesserNonNegativeNonNull(t,r){return r!==null&&r>=0&&r<t?r:t}},EE=class{constructor(e){this._globe=e,this._mercatorCameraHelper=new Gy,this._verticalPerspectiveCameraHelper=new rz}get useGlobeControls(){return this._globe.useGlobeRendering}get currentHelper(){return this.useGlobeControls?this._verticalPerspectiveCameraHelper:this._mercatorCameraHelper}handlePanInertia(e,t){return this.currentHelper.handlePanInertia(e,t)}handleMapControlsRollPitchBearingZoom(e,t){this.currentHelper.handleMapControlsRollPitchBearingZoom(e,t)}handleMapControlsPan(e,t,r){this.currentHelper.handleMapControlsPan(e,t,r)}cameraForBoxAndBearing(e,t,r,i,n){return this.currentHelper.cameraForBoxAndBearing(e,t,r,i,n)}handleJumpToCenterZoom(e,t){this.currentHelper.handleJumpToCenterZoom(e,t)}handleEaseTo(e,t){return this.currentHelper.handleEaseTo(e,t)}handleFlyTo(e,t){return this.currentHelper.handleFlyTo(e,t)}};function zIe(e,t,r){let i={constrainOverride:t};if(Array.isArray(e)){let n=new wE({type:e},r);return{projection:n,transform:new kE(i),cameraHelper:new EE(n)}}switch(e){case"mercator":return{projection:new n3,transform:new qy(i),cameraHelper:new Gy};case"globe":{let n=new wE({type:["interpolate",["linear"],["zoom"],11,"vertical-perspective",12,"mercator"]},{});return{projection:n,transform:new kE(i),cameraHelper:new EE(n)}}case"vertical-perspective":return{projection:new XF,transform:new Q
1542F(i),cameraHelper:new rz};default:return vr(`Unknown projection name: ${e}. Falling back to mercator projection.`),{projection:new n3,transform:new qy(i),cameraHelper:new Gy}}}const NIe=J5e();var PE=class extends Rn{constructor(e,t={}){var i,n;super(),this._rtlPluginLoaded=()=>{for(let a in this.tileManagers){let s=this.tileManagers[a].getSource().type;(s==="vector"||s==="geojson")&&this.tileManagers[a].reload()}},this.map=e,this.dispatcher=new TF(SF(),e._getMapId()),this.dispatcher.registerMessageHandler("GG",(a,s)=>this.getGlyphs(a,s)),this.dispatcher.registerMessageHandler("GI",(a,s)=>this.getImages(a,s)),this.dispatcher.registerMessageHandler("GDA",(a,s)=>this.getDashes(a,s)),this.imageManager=new FPe,this.imageManager.setEventedParent(this),this.imageManager.setMissingImageResolver(e._missingStyleImageResolver);let r=((i=e._container)==null?void 0:i.lang)||typeof document<"u"&&((n=document.documentElement)==null?void 0:n.lang)||void 0;this.glyphManager=new jPe(e._requestManager,t.localIdeographFontFamily,r),this.lineAtlas=new WPe(256,512),this.crossTileSymbolIndex=new NF,this._setInitialValues(),this._resetUpdates(),this.dispatcher.broadcast("SR",D$()),Jw().on(Xw,this._rtlPluginLoaded),this.on("data",a=>{if(a.dataType!=="source"||a.sourceDataType!=="metadata")return;let s=this.tileManagers[a.sourceId];if(!s)return;let o=s.getSource();if(o!=null&&o.vectorLayerIds)for(let l in this._layers){let u=this._layers[l];u.source===o.id&&this._validateLayer(u)}})}_setInitialValues(){var e;this._spritesImagesIds={},this._layers={},this._order=[],this.tileManagers={},this.zoomHistory=new nw,this._availableImages=[],this._imagesListDirty=!1,this._globalState={},this._serializedLayers={},this.stylesheet=null,this.light=null,this.sky=null,this.projection&&(this.projection.destroy(),delete this.projection),this._loaded=!1,this._changed=!1,this._updatedLayers={},this._updatedSources={},this._changedImages={},this._glyphsDidChange=!1,this._updatedPaintProps={},this._layerOrderChanged=!1,this.crossTileSymbolIndex=new(((e=this.crossTileSymbolIndex)==null?void 0:e.constructor)||Object),this.pauseablePlacement=void 0,this.placement=void 0,this.z=0}setGlobalStateProperty(e,t){var i,n;this._checkLoaded();let r=t===null?((n=(i=this.stylesheet.state)==null?void 0:i[e])==null?void 0:n.default)??null:t;if(Gs(r,this._globalState[e]))return this;this._globalState[e]=r,this._applyGlobalStateChanges([e])}getGlobalState(){return this._globalState}setGlobalState(e){this._checkLoaded();let t=[];for(let r in e)Gs(this._globalState[r],e[r].default)||(t.push(r),this._globalState[r]=e[r].default);this._applyGlobalStateChanges(t)}_applyGlobalStateChanges(e){if(e.length===0)return;let t=new Set,r={};for(let i of e){r[i]=this._globalState[i];for(let n in this._layers){let a=this._layers[n],s=a.getLayoutAffectingGlobalStateRefs(),o=a.getPaintAffectingGlobalStateRefs(),l=a.getVisibilityAffectingGlobalStateRefs();if(s.has(i)&&t.add(a.source),o.has(i))for(let{name:u,value:c}of o.get(i))this._updatePaintProperty(a,u,c);l!=null&&l.has(i)&&(a.recalculateVisibility(),this._updateLayer(a))}}this.dispatcher.broadcast("UGS",r);for(let i in this.tileManagers)t.has(i)&&(this._reloadSource(i),this._changed=!0)}async loadURL(e,t={},r){this.fire(new ms("dataloading")),t.validate=typeof t.validate!="boolean"||t.validate,this._loadStyleRequest=new AbortController;let i=this._loadStyleRequest;try{let n=await this.map._requestManager.transformRequest(e,"Style");ER(i.signal);let a=await H1(n,i);this._loadStyleRequest===i&&(this._loadStyleRequest=null),this._load(a.data,t,r)}catch(n){this._loadStyleRequest===i&&(this._loadStyleRequest=null),n&&!i.signal.aborted&&this.fire(new He(mn(n)))}}loadJSON(e,t={},r){this.fire(new ms("dataloading")),this._frameRequest=new AbortController,qn.frameAsync(this._frameRequest,this.map._ownerWindow).then(()=>{this._frameRequest=null,t.validate=t.validate!==!1,this._load(e,t,r)}).catch(()=>{})}loadEmpty(){this.fire(new ms("dataloading")),this._load(NIe,{validate:!1})}_load(e,t,r){var n;let i=t.transformStyle?t.transformStyle(r,e):e;if(!(t.validate&&r8(this,i))){i={...i},this._loaded=!0,this.stylesheet=i;for(let a in i.sources)this.addSource(a,i.sources[a],{validate:!1});i.sprite?this._loadSprite(i.sprite):this.imageManager.setLoaded(!0),this.glyphManager.setURL(i.glyphs),this._createLayers(),this.light=new qPe(this.stylesheet.light??{},this._globalState),this._setProjectionInternal(((n=this.stylesheet.projection)==null?void 0:n.type)||"mercator"),this.sky=new YPe(this.stylesheet.sky,this._globalState),this.map.setTerrain(this.stylesheet.terrain??null,{validate:!1}),this.fire(new ms("data")),this.fire(new W8)}}_createLayers(){var t;
1542let e=Ok(this.stylesheet.layers);this.setGlobalState(this.stylesheet.state??null),this.dispatcher.broadcast("SL",e),this._order=e.map(r=>r.id),this._layers={},this._serializedLayers=null;for(let r of e){let i=zb(r,this._globalState);if(i.setEventedParent(this,{layer:{id:r.id}}),this._layers[r.id]=i,sw(i)&&this.tileManagers[i.source]){let n=((t=r.paint)==null?void 0:t["raster-fade-duration"])??i.paint.get("raster-fade-duration");this.tileManagers[i.source].setRasterFadeDuration(n)}}}_loadSprite(e,t=!1,r=void 0){this.imageManager.setLoaded(!1);let i=new AbortController;this._spriteRequest=i;let n;OPe(e,this.map._requestManager,this.map.getPixelRatio(),this._spriteRequest).then(a=>{if(this._spriteRequest=null,a)for(let s in a){this._spritesImagesIds[s]=[];let o=this._spritesImagesIds[s]?this._spritesImagesIds[s].filter(l=>!(l in a)):[];for(let l of o)this.imageManager.removeImage(l),this._changedImages[l]=!0;for(let l in a[s]){let u=s==="default"?l:`${s}:${l}`;this._spritesImagesIds[s].push(u),u in this.imageManager.images?this.imageManager.updateImage(u,a[s][l],!1):this.imageManager.addImage(u,a[s][l]),t&&(this._changedImages[u]=!0)}}}).catch(a=>{this._spriteRequest=null,n=a,i.signal.aborted||this.fire(new He(n))}).finally(()=>{this.imageManager.setLoaded(!0),this._availableImages=this.imageManager.listImages(),t&&(this._changed=!0),this.dispatcher.broadcast("SI",this._availableImages),this.fire(new ms("data")),r&&r(n)})}_unloadSprite(){for(let e of Object.values(this._spritesImagesIds).flat())this.imageManager.removeImage(e),this._changedImages[e]=!0;this._spritesImagesIds={},this._availableImages=this.imageManager.listImages(),this._imagesListDirty=!0,this._changed=!0,this.fire(new ms("data"))}_validateLayer(e){let t=this.tileManagers[e.source];if(!t)return;let r=e.sourceLayer;if(!r)return;let i=t.getSource();(i.type==="geojson"||i.vectorLayerIds&&!i.vectorLayerIds.includes(r))&&this.fire(new He(Error(`Source layer "${r}" does not exist on source "${i.id}" as specified by style layer "${e.id}".`)))}loaded(){if(!this._loaded||Object.keys(this._updatedSources).length)return!1;for(let e in this.tileManagers)if(!this.tileManagers[e].loaded())return!1;return this.imageManager.isLoaded()}_serializeByIds(e,t=!1){let r=this._serializedAllLayers();if(!e||e.length===0)return Object.values(t?jn(r):r);let i=[];for(let n of e)if(r[n]){let a=t?jn(r[n]):r[n];i.push(a)}return i}_serializedAllLayers(){let e=this._serializedLayers;if(e)return e;e=this._serializedLayers={};let t=Object.keys(this._layers);for(let r of t){let i=this._layers[r];i.type!=="custom"&&(e[r]=i.serialize())}return e}hasTransitions(){var e,t,r;if((e=this.light)!=null&&e.hasTransition()||(t=this.sky)!=null&&t.hasTransition()||(r=this.projection)!=null&&r.hasTransition())return!0;for(let i in this.tileManagers)if(this.tileManagers[i].hasTransition())return!0;for(let i in this._layers)if(this._layers[i].hasTransition())return!0;return!1}_checkLoaded(){if(!this._loaded)throw Error("Style is not done loading.")}update(e){if(!this._loaded)return;let t=this._changed;if(t){this._imagesListDirty&&(this._imagesListDirty=(this.dispatcher.broadcast("SI",this._availableImages),!1));let i=Object.keys(this._updatedLayers),n=Object.keys(this._removedLayers);(i.length||n.length)&&this._updateWorkerLayers(i,n);for(let a in this._updatedSources){let s=this._updatedSources[a];if(s==="reload")this._reloadSource(a);else if(s==="clear")this._clearSource(a);else throw Error(`Invalid action ${s}`)}this._updateTilesForChangedImages(),this._updateTilesForChangedGlyphs();for(let a in this._updatedPaintProps)this._layers[a].updateTransitions(e);this.light.updateTransitions(e),this.sky.updateTransitions(e),this._resetUpdates()}let r={};for(let i in this.tileManagers){let n=this.tileManagers[i];r[i]=n.used,n.used=!1}for(let i of this._order){let n=this._layers[i];n.recalculate(e,this._availableImages),!n.isHidden(e.zoom)&&n.source&&(this.tileManagers[n.source].used=!0)}for(let i in r){let n=this.tileManagers[i];!!r[i]!=!!n.used&&n.fire(new yr("data",{sourceDataType:"visibility",sourceId:i}))}this.light.recalculate(e),this.sky.recalculate(e),this.projection.recalculate(e),this.z=e.zoom,t&&this.fire(new ms("data"))}_updateTilesForChangedImages(){let e=Object.keys(this._changedImages);if(e.length){for(let t in this.tileManagers)this.tileManagers[t].reloadTilesForDependencies(["icons","patterns"],e);this._changedImages={}}}_updateTilesForChangedGlyphs(){if(this._glyphsDidChange){for(let e in this.tileManagers)this.tileManagers[e].reloadTilesForDependencies(["glyphs"],[""]);this._glyphsDidChange=!1}}_updateWorkerLayers(e,t){this.dispatcher.broadcast("UL",{layers:this._serializeByIds(e,!1),removedIds:t})}_resetUpdates(){this._changed=!1,this._updatedLayers={},this._removedLayers={},this._updatedSources={},this._updatedPaintProps={},this._changedImages={},this._glyphsDidChange=!1}setState(e,t={}){this._checkLoaded();let r=this.serialize();if(e=t.transformStyle?t.transformStyle(r,e):e,(t.validate??!0)&&r8(this,e))return!1;
vendor: 4,294 bytes, line 1542
1542e=jn(e),e.layers=Ok(e.layers);let i=bSe(r,e),n=this._getOperationsToPerform(i);if(n.unimplemented.length>0)throw Error(`Unimplemented: ${n.unimplemented.join(", ")}.`);if(n.operations.length===0)return!1;for(let a of n.operations)a();return this.stylesheet=e,this._serializedLayers=null,this.fire(new W8({style:this})),!0}_getOperationsToPerform(e){let t=[],r=[];for(let i of e)switch(i.command){case"setCenter":case"setZoom":case"setBearing":case"setPitch":case"setRoll":continue;case"addLayer":t.push(()=>this.addLayer.apply(this,i.args));break;case"removeLayer":t.push(()=>this.removeLayer.apply(this,i.args));break;case"setPaintProperty":t.push(()=>this.setPaintProperty.apply(this,i.args));break;case"setLayoutProperty":t.push(()=>this.setLayoutProperty.apply(this,i.args));break;case"setFilter":t.push(()=>this.setFilter.apply(this,i.args));break;case"addSource":t.push(()=>this.addSource.apply(this,i.args));break;case"removeSource":t.push(()=>this.removeSource.apply(this,i.args));break;case"setLayerZoomRange":t.push(()=>this.setLayerZoomRange.apply(this,i.args));break;case"setLight":t.push(()=>this.setLight.apply(this,i.args));break;case"setGeoJSONSourceData":t.push(()=>this.setGeoJSONSourceData.apply(this,i.args));break;case"setGlyphs":t.push(()=>this.setGlyphs.apply(this,i.args));break;case"setSprite":t.push(()=>this.setSprite.apply(this,i.args));break;case"setTerrain":t.push(()=>this.map.setTerrain.apply(this,i.args));break;case"setSky":t.push(()=>this.setSky.apply(this,i.args));break;case"setProjection":this.setProjection.apply(this,i.args);break;case"setGlobalState":t.push(()=>this.setGlobalState.apply(this,i.args));break;case"setTransition":t.push(()=>{});break;default:r.push(i.command)}return{operations:t,unimplemented:r}}addImage(e,t){if(this.getImage(e)){this.fire(new He(Error(`An image named "${e}" already exists.`)));return}this.imageManager.addImage(e,t),this._afterImageUpdated(e)}updateImage(e,t){this.imageManager.updateImage(e,t)}getImage(e){return this.imageManager.getImage(e)}setMissingImageResolver(e){this.imageManager.setMissingImageResolver(e)}removeImage(e){if(!this.getImage(e)){this.fire(new He(Error(`An image named "${e}" does not exist.`)));return}this.imageManager.removeImage(e),this._afterImageUpdated(e)}_afterImageUpdated(e){this._availableImages=this.imageManager.listImages(),this._changedImages[e]=!0,this._imagesListDirty=!0,this._changed=!0,this.fire(new ms("data"))}listImages(){return this._checkLoaded(),this.imageManager.listImages()}addSource(e,t,r={}){var n;if(this._checkLoaded(),this.tileManagers[e]!==void 0)throw Error(`Source "${e}" already exists.`);if(!t.type)throw Error(`The type property must be defined, but only the following properties were given: ${Object.keys(t).join(", ")}.`);if(ZO.has(t.type)&&this._validate(Nn.source,`sources.${e}`,t,null,r))return;(n=this.map)!=null&&n._collectResourceTiming&&(t.collectResourceTiming=!0);let i=this.tileManagers[e]=new e3(e,t,this.dispatcher);i.style=this,i.setEventedParent(this,()=>({isSourceLoaded:i.loaded(),source:i.serialize(),sourceId:e})),i.onAdd(this.map),this._changed=!0}removeSource(e){if(this._checkLoaded(),this.tileManagers[e]===void 0)throw Error(`There is no source with this ID=${e}`);for(let r in this._layers)if(this._layers[r].source===e)return this.fire(new He(Error(`Source "${e}" cannot be removed while layer "${r}" is using it.`)));let t=this.tileManagers[e];delete this.tileManagers[e],delete this._updatedSources[e],t.fire(new yr("data",{sourceDataType:"metadata",sourceId:e})),t.setEventedParent(null),t.onRemove(this.map),this._changed=!0}setGeoJSONSourceData(e,t){if(this._checkLoaded(),this.tileManagers[e]===void 0)throw Error(`There is no source with this ID=${e}`);let r=this.tileManagers[e].getSource();if(r.type!=="geojson")throw Error(`geojsonSource.type is ${r.type}, which is !== 'geojson`);r.setData(t),this._changed=!0}getSource(e){var t;return(t=this.tileManagers[e])==null?void 0:t.getSource()}addLayer(e,t,r={}){this._checkLoaded();let i=e.id;if(this.getLayer(i)){this.fire(new He(Error(`Layer "${i}" already exists on this map.`)));return}let n;if(e.type==="custom"){if(J$(this,Fke(e)))return;n=zb(e,this._globalState)}else{if("source"in e&&typeof e.source=="object"&&(this.addSource(i,e.source),e=jn(e),e=Ne(e,{source:i}
vendor: 2,211 bytes, line 1542
1542)),this._validate(Nn.layer,`layers.${i}`,e,{arrayIndex:-1},r))return;n=zb(e,this._globalState),this._validateLayer(n),n.setEventedParent(this,{layer:{id:i}})}let a=t?this._order.indexOf(t):this._order.length;if(t&&a===-1){this.fire(new He(Error(`Cannot add layer "${i}" before non-existing layer "${t}".`)));return}if(this._order.splice(a,0,i),this._layerOrderChanged=!0,this._layers[i]=n,this._removedLayers[i]&&n.source&&n.type!=="custom"){let s=this._removedLayers[i];delete this._removedLayers[i],s.type===n.type?(this._updatedSources[n.source]="reload",this.tileManagers[n.source].pause()):this._updatedSources[n.source]="clear"}this._updateLayer(n),n.onAdd&&n.onAdd(this.map)}moveLayer(e,t){if(this._checkLoaded(),this._changed=!0,!this._layers[e]){this.fire(new He(Error(`The layer '${e}' does not exist in the map's style and cannot be moved.`)));return}if(e===t)return;let r=this._order.indexOf(e);this._order.splice(r,1);let i=t?this._order.indexOf(t):this._order.length;if(t&&i===-1){this.fire(new He(Error(`Cannot move layer "${e}" before non-existing layer "${t}".`)));return}this._order.splice(i,0,e),this._layerOrderChanged=!0}removeLayer(e){this._checkLoaded();let t=this._layers[e];if(!t){this.fire(new He(Error(`Cannot remove non-existing layer "${e}".`)));return}t.setEventedParent(null);let r=this._order.indexOf(e);this._order.splice(r,1),this._layerOrderChanged=!0,this._changed=!0,this._removedLayers[e]=t,delete this._layers[e],this._serializedLayers&&delete this._serializedLayers[e],delete this._updatedLayers[e],delete this._updatedPaintProps[e],t.onRemove&&t.onRemove(this.map)}getLayer(e){return this._layers[e]}getLayersOrder(){return[...this._order]}hasLayer(e){return e in this._layers}setLayerZoomRange(e,t,r){this._checkLoaded();let i=this.getLayer(e);if(!i){this.fire(new He(Error(`Cannot set the zoom range of non-existing layer "${e}".`)));return}(i.minzoom!==t||i.maxzoom!==r)&&(t!=null&&(i.minzoom=t),r!=null&&(i.maxzoom=r),this._updateLayer(i))}setFilter(e,t,r={}){this._checkLoaded();let i=this.getLayer(e);if(!i){this.fire(new He(Error(`Cannot filter non-existing layer "${e}".`)));return}if(!Gs(i.filter,t)){if(t==null){i.setFilter(void 0),this._updateLayer(i);return}
vendor: 4,205 bytes, line 1542
1542this._validate(Nn.filter,`layers.${i.id}.filter`,t,null,r)||(i.setFilter(jn(t)),this._updateLayer(i))}}getFilter(e){return jn(this.getLayer(e).filter)}setLayoutProperty(e,t,r,i={}){this._checkLoaded();let n=this.getLayer(e);if(!n){this.fire(new He(Error(`Cannot style non-existing layer "${e}".`)));return}Gs(n.getLayoutProperty(t),r)||(n.setLayoutProperty(t,r,i),this._updateLayer(n))}getLayoutProperty(e,t){let r=this.getLayer(e);if(!r){this.fire(new He(Error(`Cannot get style of non-existing layer "${e}".`)));return}return r.getLayoutProperty(t)}setPaintProperty(e,t,r,i={}){this._checkLoaded();let n=this.getLayer(e);if(!n){this.fire(new He(Error(`Cannot style non-existing layer "${e}".`)));return}Gs(n.getPaintProperty(t),r)||this._updatePaintProperty(n,t,r,i)}_updatePaintProperty(e,t,r,i={}){e.setPaintProperty(t,r,i)&&this._updateLayer(e),sw(e)&&t==="raster-fade-duration"&&this.tileManagers[e.source].setRasterFadeDuration(r),this._changed=!0,this._updatedPaintProps[e.id]=!0,this._serializedLayers=null}getPaintProperty(e,t){return this.getLayer(e).getPaintProperty(t)}setFeatureState(e,t){this._checkLoaded();let r=e.source,i=e.sourceLayer,n=this.tileManagers[r];if(n===void 0){this.fire(new He(Error(`The source '${r}' does not exist in the map's style.`)));return}let a=n.getSource().type;if(a==="geojson"&&i){this.fire(new He(Error("GeoJSON sources cannot have a sourceLayer parameter.")));return}if(a==="vector"&&!i){this.fire(new He(Error("The sourceLayer parameter must be provided for vector source types.")));return}if(e.id===void 0){this.fire(new He(Error("The feature id parameter must be provided.")));return}let s=["__proto__","constructor","prototype"];if(t&&Object.keys(t).some(o=>s.includes(o))){this.fire(new He(Error(`The feature state should not include one of the following keys: ${s}`)));return}n.setFeatureState(i,e.id,t)}removeFeatureState(e,t){this._checkLoaded();let r=e.source,i=this.tileManagers[r];if(i===void 0){this.fire(new He(Error(`The source '${r}' does not exist in the map's style.`)));return}let n=i.getSource().type,a=n==="vector"?e.sourceLayer:void 0;if(n==="vector"&&!a){this.fire(new He(Error("The sourceLayer parameter must be provided for vector source types.")));return}if(t&&typeof e.id!="string"&&typeof e.id!="number"){this.fire(new He(Error("A feature id is required to remove its specific state property.")));return}i.removeFeatureState(a,e.id,t)}getFeatureState(e){this._checkLoaded();let t=e.source,r=e.sourceLayer,i=this.tileManagers[t];if(i===void 0){this.fire(new He(Error(`The source '${t}' does not exist in the map's style.`)));return}if(i.getSource().type==="vector"&&!r){this.fire(new He(Error("The sourceLayer parameter must be provided for vector source types.")));return}return e.id===void 0&&this.fire(new He(Error("The feature id parameter must be provided."))),i.getFeatureState(r,e.id)}getTransition(){var e;return Ne({duration:300,delay:0},(e=this.stylesheet)==null?void 0:e.transition)}serialize(){if(!this._loaded)return;let e=A$(this.tileManagers,n=>n.serialize()),t=this._serializeByIds(this._order,!0),r=this.map.getTerrain()||void 0,i=this.stylesheet;return $R({version:i.version,name:i.name,metadata:i.metadata,light:i.light,sky:i.sky,center:i.center,zoom:i.zoom,bearing:i.bearing,pitch:i.pitch,sprite:i.sprite,glyphs:i.glyphs,transition:i.transition,projection:i.projection,sources:e,layers:t,terrain:r},n=>n!==void 0)}_updateLayer(e){this._updatedLayers[e.id]=!0,e.source&&!this._updatedSources[e.source]&&this.tileManagers[e.source].getSource().type!=="raster"&&(this._updatedSources[e.source]="reload",this.tileManagers[e.source].pause()),this._serializedLayers=null,this._changed=!0}_flattenAndSortRenderedFeatures(e){let t=a=>this._layers[a].type==="fill-extrusion",r={},i=[];for(let a=this._order.length-1;a>=0;a--){let s=this._order[a];if(t(s)){r[s]=a;for(let o of e){let l=o[s];if(l)for(let u of l)i.push(u)}}}i.sort((a,s)=>s.intersectionZ-a.intersectionZ);let n=[];for(let a=this._order.length-1;a>=0;a--){let s=this._order[a];if(t(s))for(let o=i.length-1;o>=0;o--){let l=i[o].feature;if(r[l.layer.id]<a)break;n.push(l),i.pop()}else for(let o of e){let l=o[s];if(l)for(let u of l)n.push(u.feature)}}return n}
1542queryRenderedFeatures(e,t,r){t!=null&&t.filter&&this._validate(Nn.filter,"queryRenderedFeatures.filter",t.filter,null,t);let i={};if(t!=null&&t.layers){if(!(Array.isArray(t.layers)||t.layers instanceof Set))return this.fire(new He(Error("parameters.layers must be an Array or a Set of strings"))),[];for(let l of t.layers){let u=this._layers[l];if(!u)return this.fire(new He(Error(`The layer '${l}' does not exist in the map's style and cannot be queried for features.`))),[];i[u.source]=!0}}let n=[];t.availableImages=this._availableImages;let a=this._serializedAllLayers(),s=t.layers instanceof Set?t.layers:Array.isArray(t.layers)?new Set(t.layers):null,o={...t,layers:s,globalState:this._globalState};for(let l in this.tileManagers)t.layers&&!i[l]||n.push(aMe(this.tileManagers[l],this._layers,a,e,o,r,this.map.terrain?(u,c,d)=>this.map.terrain.getElevation(u,c,d):void 0));return this.placement&&n.push(sMe(this._layers,a,this.tileManagers,e,o,this.placement.collisionIndex,this.placement.retainedQueryData)),this._flattenAndSortRenderedFeatures(n)}querySourceFeatures(e,t){t!=null&&t.filter&&this._validate(Nn.filter,"querySourceFeatures.filter",t.filter,null,t);let r=this.tileManagers[e];return r?oMe(r,t?{...t,globalState:this._globalState}:{globalState:this._globalState}):[]}getLight(){return this.light.getLight()}setLight(e,t={}){this._checkLoaded();let r=this.light.getLight(),i=!1;for(let a in e)if(!Gs(e[a],r[a])){i=!0;break}if(!i)return;let n={now:tr(),transition:Ne({duration:300,delay:0},this.stylesheet.transition)};this.light.setLight(e,t),this.light.updateTransitions(n)}getProjection(){var e;return(e=this.stylesheet)==null?void 0:e.projection}setProjection(e){this._checkLoaded();let t=e??{type:"mercator"};if(this.stylesheet.projection=e,this.projection){if(this.projection.name===t.type)return;this.projection.destroy(),delete this.projection}this._setProjectionInternal(t.type)}getSky(){var e;return(e=this.stylesheet)==null?void 0:e.sky}setSky(e,t={}){this._checkLoaded();let r=this.getSky(),i=!1;if(!e&&!r)return;if(e&&!r)i=!0;else if(!e&&r)i=!0;else for(let a in e)if(!Gs(e[a],r[a])){i=!0;break}if(!i)return;let n={now:tr(),transition:Ne({duration:300,delay:0},this.stylesheet.transition)};this.stylesheet.sky=e,this.sky.setSky(e,t),this.sky.updateTransitions(n)}_setProjectionInternal(e){var r;let t=zIe(e,(r=this.map._camera)==null?void 0:r.transform.constrainOverride,this._globalState);this.projection=t.projection,this.map.migrateProjection(t.transform,t.cameraHelper);for(let i in this.tileManagers)this.tileManagers[i].reload()}_validate(e,t,r,i,n={}){return gg(this,e,{key:t,style:this.serialize(),value:r,...i},n)}_remove(e=!0){this._frameRequest&&(this._frameRequest=(this._frameRequest.abort(),null)),this._loadStyleRequest&&(this._loadStyleRequest=(this._loadStyleRequest.abort(),null)),this._spriteRequest&&(this._spriteRequest=(this._spriteRequest.abort(),null)),Jw().off(Xw,this._rtlPluginLoaded);for(let t in this._layers)this._layers[t].setEventedParent(null);for(let t in this.tileManagers){let r=this.tileManagers[t];r.setEventedParent(null),r.onRemove(this.map)}this.imageManager.setEventedParent(null),this.setEventedParent(null),e&&this.dispatcher.broadcast("RM",void 0),this.dispatcher.remove(e)}_clearSource(e){this.tileManagers[e].clearTiles()}_reloadSource(e){this.tileManagers[e].resume(),this.tileManagers[e].reload()}_updateSources(e){for(let t in this.tileManagers)this.tileManagers[t].update(e,this.map.terrain)}_generateCollisionBoxes(){for(let e in this.tileManagers)this._reloadSource(e)}_updatePlacement(e,t,r,i,n=!1){let a=!1,s=!1,o={};for(let l of this._order){let u=this._layers[l];if(u.type!=="symbol")continue;if(!o[u.source]){let d=this.tileManagers[u.source];o[u.source]=d.getRenderableIds(!0).map(h=>d.getTileByID(h)).sort((h,f)=>f.tileID.overscaledZ-h.tileID.overscaledZ||(h.tileID.isLessThan(f.tileID)?-1:1))}let c=this.crossTileSymbolIndex.addLayer(u,o[u.source],e.center.lng);a||(a=c)}if(this.crossTileSymbolIndex.pruneUnusedLayers(this._order),n||(n=this._layerOrderChanged||r===0),(n||!this.pauseablePlacement||this.pauseablePlacement.isDone()&&!this.placement.stillRecent(tr(),e.zoom))&&(this.pauseablePlacement=new lIe(e,this.map.terrain,this._order,n,t,r,i,this.placement),this._layerOrderChanged=!1),this.pauseablePlacement.isDone()?this.placement.setStale():(this.pauseablePlacement.continuePlacement(this._order,this._layers,o),this.pauseablePlacement.isDone()&&(this.placement=this.pauseablePlacement.commit(tr()),s=!0),a&&this.pauseablePlacement.placement.setStale()),s||a)for(let l of this._order){let u=this._layers[l];u.type==="symbol"&&this.placement.updateLayerOpacities(u,o[u.source])}return!this.pauseablePlacement.isDone()||this.placement.hasTransitions(tr())}_releaseSymbolFadeTiles(){for(let e in this.tileManagers)this.tileManagers[e].releaseSymbolFadeTiles()}async getImages(e,t){let r=await this.imageManager.getImages(t.icons);this._updateTilesForChangedImages();let i=this.tileManagers[t.source];return i&&i.setDependencies(t.tileID.key,t.type,t.icons),r}async getGlyphs(e,t){let r=await this.glyphManager.getGlyphs(t.stacks),i=this.tileManagers[t.source];return i&&i.setDependencies(t.tileID.key,t.type,[""]),r}getGlyphsUrl(){return this.stylesheet.glyphs||null}setGlyphs(e,t={}
1542){this._checkLoaded(),!(e&&this._validate(Nn.glyphs,"glyphs",e,null,t))&&(this._glyphsDidChange=!0,this.stylesheet.glyphs=e,this.glyphManager.entries={},this.glyphManager.setURL(e))}async getDashes(e,t){let r={};for(let[i,n]of Object.entries(t.dashes))r[i]=this.lineAtlas.getDash(n.dasharray,n.round);return r}addSprite(e,t,r={},i){this._checkLoaded();let n=[{id:e,url:t}],a=[...v_(this.stylesheet.sprite),...n];this._validate(Nn.sprite,"sprite",a,null,r)||(this.stylesheet.sprite=a,this._loadSprite(n,!0,i))}removeSprite(e){this._checkLoaded();let t=v_(this.stylesheet.sprite);if(!t.find(r=>r.id===e)){this.fire(new He(Error(`Sprite "${e}" doesn't exists on this map.`)));return}if(this._spritesImagesIds[e])for(let r of this._spritesImagesIds[e])this.imageManager.removeImage(r),this._changedImages[r]=!0;t.splice(t.findIndex(r=>r.id===e),1),this.stylesheet.sprite=t.length>0?t:void 0,delete this._spritesImagesIds[e],this._availableImages=this.imageManager.listImages(),this._imagesListDirty=!0,this._changed=!0,this.fire(new ms("data"))}getSprite(){return v_(this.stylesheet.sprite)}setSprite(e,t={},r){this._checkLoaded(),!(e&&this._validate(Nn.sprite,"sprite",e,null,t))&&(this.stylesheet.sprite=e,e?this._loadSprite(e,!0,r):(this._unloadSprite(),r&&r(null)))}destroy(){this._frameRequest&&(this._frameRequest=(this._frameRequest.abort(),null)),this._loadStyleRequest&&(this._loadStyleRequest=(this._loadStyleRequest.abort(),null)),this._spriteRequest&&(this._spriteRequest=(this._spriteRequest.abort(),null));for(let e in this.tileManagers){let t=this.tileManagers[e];t.setEventedParent(null),t.onRemove(this.map)}this.tileManagers={},this.imageManager&&(this.imageManager.setEventedParent(null),this.imageManager.destroy(),this._availableImages=[],this._spritesImagesIds={}),this.glyphManager&&this.glyphManager.destroy();for(let e in this._layers){let t=this._layers[e];t.setEventedParent(null),t.onRemove&&t.onRemove(this.map)}this._setInitialValues(),this.setEventedParent(null),this.dispatcher.unregisterMessageHandler("GG"),this.dispatcher.unregisterMessageHandler("GI"),this.dispatcher.unregisterMessageHandler("GDA"),this.dispatcher.remove(!0),this._listeners={},this._oneTimeListeners={}}};const BIe=Ar([{name:"a_pos",type:"Int16",components:2},{name:"a_texture_pos",type:"Int16",components:2}]);var jIe=class{constructor(){this.boundProgram=null,this.boundLayoutVertexBuffer=null,this.boundPaintVertexBuffers=[],this.boundIndexBuffer=null,this.boundVertexOffset=null,this.boundDynamicVertexBuffer=null,this.vao=null}bind(e,t,r,i,n,a,s,o,l){this.context=e;let u=this.boundPaintVertexBuffers.length!==i.length;for(let c=0;!u&&c<i.length;c++)this.boundPaintVertexBuffers[c]!==i[c]&&(u=!0);!this.vao||this.boundProgram!==t||this.boundLayoutVertexBuffer!==r||u||this.boundIndexBuffer!==n||this.boundVertexOffset!==a||this.boundDynamicVertexBuffer!==s||this.boundDynamicVertexBuffer2!==o||this.boundDynamicVertexBuffer3!==l?this.freshBind(t,r,i,n,a,s,o,l):(e.bindVertexArray.set(this.vao),s&&s.bind(),n!=null&&n.dynamicDraw&&n.bind(),o&&o.bind(),l&&l.bind())}freshBind(e,t,r,i,n,a,s,o){let l=e.numAttributes,u=this.context,c=u.gl;this.vao&&this.destroy(),this.vao=u.createVertexArray(),u.bindVertexArray.set(this.vao),this.boundProgram=e,this.boundLayoutVertexBuffer=t,this.boundPaintVertexBuffers=r,this.boundIndexBuffer=i,this.boundVertexOffset=n,this.boundDynamicVertexBuffer=a,this.boundDynamicVertexBuffer2=s,this.boundDynamicVertexBuffer3=o,t.enableAttributes(c,e);for(let d of r)d.enableAttributes(c,e);a&&a.enableAttributes(c,e),s&&s.enableAttributes(c,e),o&&o.enableAttributes(c,e),t.bind(),t.setVertexAttribPointers(c,e,n);for(let d of r)d.bind(),d.setVertexAttribPointers(c,e,n);a&&(a.bind(),a.setVertexAttribPointers(c,e,n)),i&&i.bind(),s&&(s.bind(),s.setVertexAttribPointers(c,e,n)),o&&(o.bind(),o.setVertexAttribPointers(c,e,n)),u.currentNumAttributes=l}destroy(){this.vao&&(this.vao=(this.context.deleteVertexArray(this.vao),null))}};const UIe=(e,t)=>({u_depth:new We(e,t.u_depth),u_terrain:new We(e,t.u_terrain),u_terrain_dim:new Ce(e,t.u_terrain_dim),u_terrain_matrix:new ka(e,t.u_terrain_matrix),u_terrain_unpack:new du(e,t.u_terrain_unpack),u_terrain_exaggeration:new Ce(e,t.u_terrain_exaggeration)}),VIe=(e,t)=>({u_texture:new We(e,t.u_texture),u_ele_delta:new Ce(e,t.u_ele_delta),u_fog_matrix:new ka(e,t.u_fog_matrix),u_fog_color:new hu(e,t.u_fog_color),u_fog_ground_blend:new Ce(e,t.u_fog_ground_blend),u_fog_ground_blend_opacity:new Ce(e,t.u_fog_ground_blend_opacity),u_horizon_color:new hu(e,t.u_horizon_color),u_horizon_fog_blend:new Ce(e,t.u_horizon_fog_blend),u_is_globe_mode:new Ce(e,t.u_is_globe_mode)}),qIe=(e,t)=>({u_ele_delta:new Ce(e,t.u_ele_delta)}),GIe=(e,t)=>({u_texture:new We(e,t.u_texture),u_terrain_coords_id:new Ce(e,t.u_terrain_coords_id),u_ele_delta:new Ce(e,t.u_ele_delta)}),HIe=(e,t,r,i,n)=>({u_texture:0,u_ele_delta:e,u_fog_matrix:t,u_fog_color:r?r.properties.get("fog-color"):at.white,u_fog_ground_blend:r?r.properties.get("fog-ground-blend"):1,u_fog_ground_blend_opacity:n?0:r?r.calculateFogBlendOpacity(i):0,u_horizon_color:r?r.properties.get("horizon-color"):at.white,u_horizon_fog_blend:r?r.properties.get("horizon-fog-blend"):1,u_is_globe_mode:+!!n}),YIe=e=>({u_ele_delta:e}),WIe=(e,t)=>({u_terrain_coords_id:e/255,u_texture:0,u_ele_delta:t}),ZIe=(e,t)=>({u_projection_matrix:new ka(e,t.u_projection_matrix),u_projection_tile_mercator_coords:new du(e,t.u_projection_tile_mercator_coords),u_projection_clipping_plane
1542:new du(e,t.u_projection_clipping_plane),u_projection_transition:new Ce(e,t.u_projection_transition),u_projection_fallback_matrix:new ka(e,t.u_projection_fallback_matrix),u_projection_clip_antimeridian:new We(e,t.u_projection_clip_antimeridian)}),KIe=e=>({u_projection_matrix:e.mainMatrix,u_projection_tile_mercator_coords:e.tileMercatorCoords,u_projection_clipping_plane:e.clippingPlane,u_projection_transition:e.projectionTransition,u_projection_fallback_matrix:e.fallbackMatrix,u_projection_clip_antimeridian:+!!e.clipAntimeridian});function M0(e){let t=[];for(let r of e){if(r===null)continue;let i=r.split(" ");t.push(i.pop())}return t}var XIe=class{constructor(e,t,r,i,n,a,s,o,l=[]){let u=e.gl;this.program=u.createProgram();let c=M0(t.staticAttributes),d=r?r.getBinderAttributes():[],h=c.concat(d),f=eo.prelude.staticUniforms?M0(eo.prelude.staticUniforms):[],p=s.staticUniforms?M0(s.staticUniforms):[],m=t.staticUniforms?M0(t.staticUniforms):[],g=r?r.getBinderUniforms():[],v=f.concat(p).concat(m).concat(g),x=[];for(let C of v)x.includes(C)||x.push(C);let _=r?r.defines():[];_.unshift("#version 300 es"),n&&_.push("#define OVERDRAW_INSPECTOR;"),a&&_.push("#define TERRAIN3D;"),o&&_.push(o),l&&_.push(...l);let y=_.concat(eo.prelude.fragmentSource,s.fragmentSource,t.fragmentSource).join(` 1543`),w=_.concat(eo.prelude.vertexSource,s.vertexSource,t.vertexSource).join(` 1544`),$=u.createShader(u.FRAGMENT_SHADER);if(u.isContextLost()){this.failedToCreate=!0;return}if(u.shaderSource($,y),u.compileShader($),!u.getShaderParameter($,u.COMPILE_STATUS))throw Error(`Could not compile fragment shader: ${u.getShaderInfoLog($)}`);u.attachShader(this.program,$);let S=u.createShader(u.VERTEX_SHADER);if(u.isContextLost()){this.failedToCreate=!0;return}if(u.shaderSource(S,w),u.compileShader(S),!u.getShaderParameter(S,u.COMPILE_STATUS))throw Error(`Could not compile vertex shader: ${u.getShaderInfoLog(S)}`);u.attachShader(this.program,S),this.attributes={};let E={};this.numAttributes=h.length;for(let C=0;C<this.numAttributes;C++)h[C]&&(this.attributes[h[C]]=C);u.linkProgram(this.program);for(let C in this.attributes){let I=u.getAttribLocation(this.program,C);I>=0?this.attributes[C]=I:delete this.attributes[C]}if(!u.getProgramParameter(this.program,u.LINK_STATUS))throw Error(`Program failed to link: ${u.getProgramInfoLog(this.program)}`);u.deleteShader(S),u.deleteShader($);for(let C of x)if(C&&!E[C]){let I=u.getUniformLocation(this.program,C);I&&(E[C]=I)}this.fixedUniforms=i(e,E),this.terrainUniforms=UIe(e,E),this.projectionUniforms=ZIe(e,E),this.binderUniforms=r?r.getUniforms(e,E):[]}draw(e,t,r,i,n,a,s,o,l,u,c,d,h,f,p,m,g,v,x){var w;let _=e.gl;if(this.failedToCreate)return;if(e.program.set(this.program),e.setDepthMode(r),e.setStencilMode(i),e.setColorMode(n),e.setCullFace(a),o){e.activeTexture.set(_.TEXTURE2),_.bindTexture(_.TEXTURE_2D,o.depthTexture),e.activeTexture.set(_.TEXTURE3),_.bindTexture(_.TEXTURE_2D,o.texture);for(let $ in this.terrainUniforms)this.terrainUniforms[$].set(o[$])}if(l){let $=KIe(l);for(let S in this.projectionUniforms)this.projectionUniforms[S].set($[S])}if(s)for(let $ in this.fixedUniforms)this.fixedUniforms[$].set(s[$]);m&&m.setUniforms(e,this.binderUniforms,f,{zoom:p});let y=0;switch(t){case _.LINES:y=2;break;case _.TRIANGLES:y=3;break;case _.LINE_STRIP:y=1}for(let $ of h.get())$.vaos||($.vaos={}),(w=$.vaos)[u]||(w[u]=new jIe),$.vaos[u].bind(e,this,c,m?m.getPaintVertexBuffers():[],d,$.vertexOffset,g,v,x),_.drawElements(t,$.primitiveLength*y,_.UNSIGNED_SHORT,$.primitiveOffset*y*2)}};function iz(e,t,r){let i=1/Ca(r,1,t.transform.tileZoom),n=2**r.tileID.overscaledZ,a=r.tileSize*2**t.transform.tileZoom/n,s=a*(r.tileID.canonical.x+r.tileID.wrap*n),o=a*r.tileID.canonical.y;return{u_image:0,u_texsize:r.imageAtlasTexture.size,u_scale:[i,e.fromScale,e.toScale],u_fade:e.t,u_pixel_coord_upper:[s>>16,o>>16],u_pixel_coord_lower:[s&65535,o&65535]}}function JIe(e,t,r,i){let n=r.imageManager.getPattern(e.from.toString()),a=r.imageManager.getPattern(e.to.toString()),{width:s,height:o}=r.imageManager.getPixelSize(),l=2**i.tileID.overscaledZ,u=i.tileSize*2**r.transform.tileZoom/l,c=u*(i.tileID.canonical.x+i.tileID.wrap*l),d=u*i.tileID.canonical.y;return{u_image:0,u_pattern_tl_a:n.tl,u_pattern_br_a:n.br,u_pattern_tl_b:a.tl,u_pattern_br_b:a.br,u_texsize:[s,o],u_mi
1544x:t.t,u_pattern_size_a:n.displaySize,u_pattern_size_b:a.displaySize,u_scale_a:t.fromScale,u_scale_b:t.toScale,u_tile_units_to_pixels:1/Ca(i,1,r.transform.tileZoom),u_pixel_coord_upper:[c>>16,d>>16],u_pixel_coord_lower:[c&65535,d&65535]}}const QIe=(e,t)=>({u_lightpos:new ba(e,t.u_lightpos),u_lightpos_globe:new ba(e,t.u_lightpos_globe),u_lightintensity:new Ce(e,t.u_lightintensity),u_lightcolor:new ba(e,t.u_lightcolor),u_vertical_gradient:new Ce(e,t.u_vertical_gradient),u_opacity:new Ce(e,t.u_opacity),u_fill_translate:new Je(e,t.u_fill_translate)}),eAe=(e,t)=>({u_lightpos:new ba(e,t.u_lightpos),u_lightpos_globe:new ba(e,t.u_lightpos_globe),u_lightintensity:new Ce(e,t.u_lightintensity),u_lightcolor:new ba(e,t.u_lightcolor),u_vertical_gradient:new Ce(e,t.u_vertical_gradient),u_height_factor:new Ce(e,t.u_height_factor),u_opacity:new Ce(e,t.u_opacity),u_fill_translate:new Je(e,t.u_fill_translate),u_image:new We(e,t.u_image),u_texsize:new Je(e,t.u_texsize),u_pixel_coord_upper:new Je(e,t.u_pixel_coord_upper),u_pixel_coord_lower:new Je(e,t.u_pixel_coord_lower),u_scale:new ba(e,t.u_scale),u_fade:new Ce(e,t.u_fade)}),nz=(e,t,r,i)=>{let n=e.style.light,a=n.getCartesianPosition(),s=gR();n.properties.get("anchor")==="viewport"&&m$e(s,e.transform.bearingInRadians),k$e(a,a,s);let o=e.transform.transformLightDirection(a),l=n.properties.get("color");return{u_lightpos:a,u_lightpos_globe:o,u_lightintensity:n.properties.get("intensity"),u_lightcolor:[l.r,l.g,l.b],u_vertical_gradient:+t,u_opacity:r,u_fill_translate:i}},tAe=(e,t,r,i,n,a,s)=>Ne(nz(e,t,r,i),iz(a,e,s),{u_height_factor:-(2**n.overscaledZ)/s.tileSize/8}),rAe=(e,t)=>({u_fill_translate:new Je(e,t.u_fill_translate)}),iAe=(e,t)=>({u_image:new We(e,t.u_image),u_texsize:new Je(e,t.u_texsize),u_pixel_coord_upper:new Je(e,t.u_pixel_coord_upper),u_pixel_coord_lower:new Je(e,t.u_pixel_coord_lower),u_scale:new ba(e,t.u_scale),u_fade:new Ce(e,t.u_fade),u_fill_translate:new Je(e,t.u_fill_translate)}),nAe=(e,t)=>({u_world:new Je(e,t.u_world),u_fill_translate:new Je(e,t.u_fill_translate)}),aAe=(e,t)=>({u_world:new Je(e,t.u_world),u_image:new We(e,t.u_image),u_texsize:new Je(e,t.u_texsize),u_pixel_coord_upper:new Je(e,t.u_pixel_coord_upper),u_pixel_coord_lower:new Je(e,t.u_pixel_coord_lower),u_scale:new ba(e,t.u_scale),u_fade:new Ce(e,t.u_fade),u_fill_translate:new Je(e,t.u_fill_translate)}),az=(e,t,r,i)=>Ne(iz(t,e,r),{u_fill_translate:i}),sAe=e=>({u_fill_translate:e}),oAe=(e,t)=>({u_world:e,u_fill_translate:t}),lAe=(e,t,r,i,n)=>Ne(az(e,t,r,n),{u_world:i}),uAe=(e,t)=>({u_camera_to_center_distance:new Ce(e,t.u_camera_to_center_distance),u_scale_with_map:new We(e,t.u_scale_with_map),u_pitch_with_map:new We(e,t.u_pitch_with_map),u_extrude_scale:new Je(e,t.u_extrude_scale),u_device_pixel_ratio:new Ce(e,t.u_device_pixel_ratio),u_globe_extrude_scale:new Ce(e,t.u_globe_extrude_scale),u_translate:new Je(e,t.u_translate)}),cAe=(e,t,r,i,n)=>{let a=e.transform,s,o,l=0;if(r.paint.get("circle-pitch-alignment")==="map"){let u=Ca(t,1,a.zoom);s=!0,o=[u,u],l=u/(ye*2**t.tileID.overscaledZ)*2*Math.PI*n}else s=!1,o=a.pixelsToGLUnits;return{u_camera_to_center_distance:a.cameraToCenterDistance,u_scale_with_map:+(r.paint.get("circle-pitch-scale")==="map"),u_pitch_with_map:+s,u_device_pixel_ratio:e.pixelRatio,u_extrude_scale:o,u_globe_extrude_scale:l,u_translate:i}},dAe=(e,t)=>({u_pixel_extrude_scale:new Je(e,t.u_pixel_extrude_scale)}),hAe=(e,t)=>({u_viewport_size:new Je(e,t.u_viewport_size)}),fAe=e=>({u_pixel_extrude_scale:[1/e.width,1/e.height]}),pAe=e=>({u_viewport_size:[e.width,e.height]}),mAe=(e,t)=>({u_color:new hu(e,t.u_color),u_overlay:new We(e,t.u_overlay),u_overlay_scale:new Ce(e,t.u_overlay_scale)}),ME=(e,t=1)=>({u_color:e,u_overlay:0,u_overlay_scale:t}),gAe=(e,t)=>({u_extrude_scale:new Ce(e,t.u_extrude_scale),u_intensity:new Ce(e,t.u_intensity),u_globe_extrude_scale:new Ce(e,t.u_globe_extrude_scale)}),_Ae=(e,t)=>
1544({u_matrix:new ka(e,t.u_matrix),u_world:new Je(e,t.u_world),u_image:new We(e,t.u_image),u_color_ramp:new We(e,t.u_color_ramp),u_opacity:new Ce(e,t.u_opacity)}),sz=(e,t,r,i)=>{let n=Ca(e,1,t)/(ye*2**e.tileID.overscaledZ)*2*Math.PI*i;return{u_extrude_scale:Ca(e,1,t),u_intensity:r,u_globe_extrude_scale:n}},oz=(e,t,r,i)=>{let n=_u();qs(n,0,e.width,e.height,0,0,1);let a=e.context.gl;return{u_matrix:n,u_world:[a.drawingBufferWidth,a.drawingBufferHeight],u_image:r,u_color_ramp:i,u_opacity:t.paint.get("heatmap-opacity")}},yAe=(e,t)=>({u_image:new We(e,t.u_image),u_latrange:new Je(e,t.u_latrange),u_exaggeration:new Ce(e,t.u_exaggeration),u_altitudes:new f8(e,t.u_altitudes),u_azimuths:new f8(e,t.u_azimuths),u_accent:new hu(e,t.u_accent),u_method:new We(e,t.u_method),u_shadows:new h8(e,t.u_shadows),u_highlights:new h8(e,t.u_highlights)}),vAe=(e,t)=>({u_matrix:new ka(e,t.u_matrix),u_image:new We(e,t.u_image),u_dimension:new Je(e,t.u_dimension),u_zoom:new Ce(e,t.u_zoom),u_unpack:new du(e,t.u_unpack)}),bAe=(e,t,r)=>{let i=r.paint.get("hillshade-accent-color"),n;switch(r.paint.get("hillshade-method")){case"basic":n=4;break;case"combined":n=1;break;case"igor":n=2;break;case"multidirectional":n=3;break;default:n=0}let a=r.getIlluminationProperties();for(let s=0;s<a.directionRadians.length;s++)r.paint.get("hillshade-illumination-anchor")==="viewport"&&(a.directionRadians[s]+=e.transform.bearingInRadians);return{u_image:0,u_latrange:wAe(e,t.tileID),u_exaggeration:r.paint.get("hillshade-exaggeration"),u_altitudes:a.altitudeRadians,u_azimuths:a.directionRadians,u_accent:i,u_method:n,u_highlights:a.highlightColor,u_shadows:a.shadowColor}},xAe=(e,t)=>{let r=t.stride,i=_u();return qs(i,0,ye,-ye,0,0,1),ei(i,i,[0,-ye,0]),{u_matrix:i,u_image:1,u_dimension:[r,r],u_zoom:e.overscaledZ,u_unpack:t.getUnpackVector()}};function wAe(e,t){let r=2**t.canonical.z,i=t.canonical.y;return[new nr(0,i/r).toLngLat().lat,new nr(0,(i+1)/r).toLngLat().lat]}const $Ae=(e,t)=>({u_image:new We(e,t.u_image),u_unpack:new du(e,t.u_unpack),u_dimension:new Je(e,t.u_dimension),u_elevation_stops:new We(e,t.u_elevation_stops),u_color_stops:new We(e,t.u_color_stops),u_color_ramp_size:new We(e,t.u_color_ramp_size),u_opacity:new Ce(e,t.u_opacity)}),SAe=(e,t,r=0)=>({u_image:0,u_unpack:t.getUnpackVector(),u_dimension:[t.stride,t.stride],u_elevation_stops:1,u_color_stops:4,u_color_ramp_size:r,u_opacity:e.paint.get("color-relief-opacity")}),TAe=(e,t)=>({u_translation:new Je(e,t.u_translation),u_ratio:new Ce(e,t.u_ratio),u_device_pixel_ratio:new Ce(e,t.u_device_pixel_ratio),u_units_to_pixels:new Je(e,t.u_units_to_pixels)}),CAe=(e,t)=>({u_translation:new Je(e,t.u_translation),u_ratio:new Ce(e,t.u_ratio),u_device_pixel_ratio:new Ce(e,t.u_device_pixel_ratio),u_units_to_pixels:new Je(e,t.u_units_to_pixels),u_image:new We(e,t.u_image),u_image_height:new Ce(e,t.u_image_height)}),kAe=(e,t)=>({u_translation:new Je(e,t.u_translation),u_texsize:new Je(e,t.u_texsize),u_ratio:new Ce(e,t.u_ratio),u_device_pixel_ratio:new Ce(e,t.u_device_pixel_ratio),u_image:new We(e,t.u_image),u_units_to_pixels:new Je(e,t.u_units_to_pixels),u_scale:new ba(e,t.u_scale),u_fade:new Ce(e,t.u_fade)}),EAe=(e,t)=>({u_translation:new Je(e,t.u_translation),u_ratio:new Ce(e,t.u_ratio),u_device_pixel_ratio:new Ce(e,t.u_device_pixel_ratio),u_units_to_pixels:new Je(e,t.u_units_to_pixels),u_image:new We(e,t.u_image),u_mix:new Ce(e,t.u_mix),u_tileratio:new Ce(e,t.u_tileratio),u_crossfade_from:new Ce(e,t.u_crossfade_from),u_crossfade_to:new Ce(e,t.u_crossfade_to),u_lineatlas_width:new Ce(e,t.u_lineatlas_width),u_lineatlas_height:new Ce(e,t.u_lineatlas_height)}),PAe=(e,t)=>({u_translation:new Je(e,t.u_translation),u_ratio:new Ce(e,t.u_ratio),u_device_pixel_ratio:new Ce(e,t.u_device_pixel_ratio),u_units_to_pixels:new Je(e,t.u_units_to_pixels),u_image:new We(e,t.u_image),u_image_height:new Ce(e,t.u_image_height),u_tileratio:new Ce(e,t.u_tileratio),u_crossfade_from:new Ce(e,t.u_crossfade_from),u_crossfade_to:new Ce(e,t.u_crossfade_to),u_image_dash:new We(e,t.u_image_dash),u_mix:new Ce(e,t.u_mix),u_lineatlas_width:new Ce(e,t.u_lineatlas_width),u_lineatlas_height:new Ce(e,t.u_lineatlas_height)}),yv=(e,t,r,i)=>{let n=e.transform;return{u_translation:lz(e,t,r),u_ratio:i/Ca(t,1,n.zoom),u_device_pixel_ratio:e.pixelRatio,u_units_to_pixels:[1/n.pixelsToGLUnits[0],1/n.pixelsToGLUnits[1]]}},MAe=(e,t,r,i,n)=>
vendor: 4,347 bytes, line 1544
1544Ne(yv(e,t,r,i),{u_image:0,u_image_height:n}),IAe=(e,t,r,i,n)=>{let a=e.transform,s=AS(t,a);return{u_translation:lz(e,t,r),u_texsize:t.imageAtlasTexture.size,u_ratio:i/Ca(t,1,a.zoom),u_device_pixel_ratio:e.pixelRatio,u_image:0,u_scale:[s,n.fromScale,n.toScale],u_fade:n.t,u_units_to_pixels:[1/a.pixelsToGLUnits[0],1/a.pixelsToGLUnits[1]]}},AAe=(e,t,r,i,n)=>{let a=e.transform,s=AS(t,a);return Ne(yv(e,t,r,i),{u_tileratio:s,u_crossfade_from:n.fromScale,u_crossfade_to:n.toScale,u_image:0,u_mix:n.t,u_lineatlas_width:e.lineAtlas.width,u_lineatlas_height:e.lineAtlas.height})},DAe=(e,t,r,i,n,a)=>{let s=e.transform,o=AS(t,s);return Ne(yv(e,t,r,i),{u_image:0,u_image_height:a,u_tileratio:o,u_crossfade_from:n.fromScale,u_crossfade_to:n.toScale,u_image_dash:1,u_mix:n.t,u_lineatlas_width:e.lineAtlas.width,u_lineatlas_height:e.lineAtlas.height})};function AS(e,t){return 1/Ca(e,1,t.tileZoom)}function lz(e,t,r){return lu(e.transform,t,r.paint.get("line-translate"),r.paint.get("line-translate-anchor"))}const RAe=(e,t)=>({u_image:new We(e,t.u_image),u_opacity:new Ce(e,t.u_opacity)}),OAe=(e,t)=>({u_image:t,u_opacity:e}),LAe=(e,t)=>({u_tl_parent:new Je(e,t.u_tl_parent),u_scale_parent:new Ce(e,t.u_scale_parent),u_buffer_scale:new Ce(e,t.u_buffer_scale),u_fade_t:new Ce(e,t.u_fade_t),u_opacity:new Ce(e,t.u_opacity),u_image0:new We(e,t.u_image0),u_image1:new We(e,t.u_image1),u_brightness_low:new Ce(e,t.u_brightness_low),u_brightness_high:new Ce(e,t.u_brightness_high),u_saturation_factor:new Ce(e,t.u_saturation_factor),u_contrast_factor:new Ce(e,t.u_contrast_factor),u_spin_weights:new ba(e,t.u_spin_weights),u_coords_top:new du(e,t.u_coords_top),u_coords_bottom:new du(e,t.u_coords_bottom)}),FAe=(e,t,r,i,n)=>({u_tl_parent:e,u_scale_parent:t,u_buffer_scale:1,u_fade_t:r.mix,u_opacity:r.opacity*i.paint.get("raster-opacity"),u_image0:0,u_image1:1,u_brightness_low:i.paint.get("raster-brightness-min"),u_brightness_high:i.paint.get("raster-brightness-max"),u_saturation_factor:BAe(i.paint.get("raster-saturation")),u_contrast_factor:NAe(i.paint.get("raster-contrast")),u_spin_weights:zAe(i.paint.get("raster-hue-rotate")),u_coords_top:[n[0].x,n[0].y,n[1].x,n[1].y],u_coords_bottom:[n[3].x,n[3].y,n[2].x,n[2].y]});function zAe(e){e*=Math.PI/180;let t=Math.sin(e),r=Math.cos(e);return[(2*r+1)/3,(-Math.sqrt(3)*t-r+1)/3,(Math.sqrt(3)*t-r+1)/3]}function NAe(e){return e>0?1/(1-e):1+e}function BAe(e){return e>0?1-1/(1.001-e):-e}const jAe=(e,t)=>({u_is_size_zoom_constant:new We(e,t.u_is_size_zoom_constant),u_is_size_feature_constant:new We(e,t.u_is_size_feature_constant),u_size_t:new Ce(e,t.u_size_t),u_size:new Ce(e,t.u_size),u_camera_to_center_distance:new Ce(e,t.u_camera_to_center_distance),u_pitch:new Ce(e,t.u_pitch),u_rotate_symbol:new We(e,t.u_rotate_symbol),u_aspect_ratio:new Ce(e,t.u_aspect_ratio),u_fade_change:new Ce(e,t.u_fade_change),u_label_plane_matrix:new ka(e,t.u_label_plane_matrix),u_coord_matrix:new ka(e,t.u_coord_matrix),u_is_text:new We(e,t.u_is_text),u_pitch_with_map:new We(e,t.u_pitch_with_map),u_is_along_line:new We(e,t.u_is_along_line),u_is_variable_anchor:new We(e,t.u_is_variable_anchor),u_texsize:new Je(e,t.u_texsize),u_texture:new We(e,t.u_texture),u_translation:new Je(e,t.u_translation),u_pitched_scale:new Ce(e,t.u_pitched_scale),u_is_offset:new We(e,t.u_is_offset)}),UAe=(e,t)=>({u_is_size_zoom_constant:new We(e,t.u_is_size_zoom_constant),u_is_size_feature_constant:new We(e,t.u_is_size_feature_constant),u_size_t:new Ce(e,t.u_size_t),u_size:new Ce(e,t.u_size),u_camera_to_center_distance:new Ce(e,t.u_camera_to_center_distance),u_pitch:new Ce(e,t.u_pitch),u_rotate_symbol:new We(e,t.u_rotate_symbol),u_aspect_ratio:new Ce(e,t.u_aspect_ratio),u_fade_change:new Ce(e,t.u_fade_change),u_label_plane_matrix:new ka(e,t.u_label_plane_matrix),u_coord_matrix:new ka(e,t.u_coord_matrix),u_is_text:new We(e,t.u_is_text),u_pitch_with_map:new We(e,t.u_pitch_with_map),u_is_along_line:new We(e,t.u_is_along_line),u_is_variable_anchor:new We(e,t.u_is_variable_anchor),u_texsize:new Je(e,t.u_texsize),u_texture:new We(e,t.u_texture),u_gamma_scale:new Ce(e,t.u_gamma_scale),u_device_pixel_ratio:new Ce(e,t.u_device_pixel_ratio),u_is_halo:new We(e,t.u_is_halo),u_is_plain:new We(e,t.u_is_plain),u_translation:new Je(e,t.u_translation),u_pitched_scale:new Ce(e,t.u_pitched_scale),u_is_offset:new We(e,t.u_is_offset)}),VAe=(e,t)=>
1544({u_is_size_zoom_constant:new We(e,t.u_is_size_zoom_constant),u_is_size_feature_constant:new We(e,t.u_is_size_feature_constant),u_size_t:new Ce(e,t.u_size_t),u_size:new Ce(e,t.u_size),u_camera_to_center_distance:new Ce(e,t.u_camera_to_center_distance),u_pitch:new Ce(e,t.u_pitch),u_rotate_symbol:new We(e,t.u_rotate_symbol),u_aspect_ratio:new Ce(e,t.u_aspect_ratio),u_fade_change:new Ce(e,t.u_fade_change),u_label_plane_matrix:new ka(e,t.u_label_plane_matrix),u_coord_matrix:new ka(e,t.u_coord_matrix),u_is_text:new We(e,t.u_is_text),u_pitch_with_map:new We(e,t.u_pitch_with_map),u_is_along_line:new We(e,t.u_is_along_line),u_is_variable_anchor:new We(e,t.u_is_variable_anchor),u_texsize:new Je(e,t.u_texsize),u_texsize_icon:new Je(e,t.u_texsize_icon),u_texture:new We(e,t.u_texture),u_texture_icon:new We(e,t.u_texture_icon),u_gamma_scale:new Ce(e,t.u_gamma_scale),u_device_pixel_ratio:new Ce(e,t.u_device_pixel_ratio),u_is_halo:new We(e,t.u_is_halo),u_translation:new Je(e,t.u_translation),u_pitched_scale:new Ce(e,t.u_pitched_scale),u_is_offset:new We(e,t.u_is_offset)}),uz=(e,t,r,i,n,a,s,o,l,u,c,d,h,f)=>{let p=s.transform;return{u_is_size_zoom_constant:+(e==="constant"||e==="source"),u_is_size_feature_constant:+(e==="constant"||e==="camera"),u_size_t:t?t.uSizeT:0,u_size:t?t.uSize:0,u_camera_to_center_distance:p.cameraToCenterDistance,u_pitch:p.pitch/360*2*Math.PI,u_rotate_symbol:+r,u_aspect_ratio:p.width/p.height,u_fade_change:s.options.fadeDuration?s.symbolFadeChange:1,u_label_plane_matrix:o,u_coord_matrix:l,u_is_text:+c,u_pitch_with_map:+i,u_is_along_line:n,u_is_variable_anchor:a,u_texsize:d,u_texture:0,u_translation:u,u_pitched_scale:h,u_is_offset:f}},cz=(e,t,r,i,n,a,s,o,l,u,c,d,h,f,p)=>{let m=s.transform;return Ne(uz(e,t,r,i,n,a,s,o,l,u,c,d,f,p),{u_gamma_scale:i?Math.cos(m.pitch*Math.PI/180)*m.cameraToCenterDistance:1,u_device_pixel_ratio:s.pixelRatio,u_is_halo:+!!h,u_is_plain:1})},qAe=(e,t,r,i,n,a,s,o,l,u,c,d,h,f)=>Ne(cz(e,t,r,i,n,a,s,o,l,u,!0,c,!0,h,f),{u_texsize_icon:d,u_texture_icon:1}),GAe=(e,t)=>({u_opacity:new Ce(e,t.u_opacity),u_color:new hu(e,t.u_color)}),HAe=(e,t)=>({u_opacity:new Ce(e,t.u_opacity),u_image:new We(e,t.u_image),u_pattern_tl_a:new Je(e,t.u_pattern_tl_a),u_pattern_br_a:new Je(e,t.u_pattern_br_a),u_pattern_tl_b:new Je(e,t.u_pattern_tl_b),u_pattern_br_b:new Je(e,t.u_pattern_br_b),u_texsize:new Je(e,t.u_texsize),u_mix:new Ce(e,t.u_mix),u_pattern_size_a:new Je(e,t.u_pattern_size_a),u_pattern_size_b:new Je(e,t.u_pattern_size_b),u_scale_a:new Ce(e,t.u_scale_a),u_scale_b:new Ce(e,t.u_scale_b),u_pixel_coord_upper:new Je(e,t.u_pixel_coord_upper),u_pixel_coord_lower:new Je(e,t.u_pixel_coord_lower),u_tile_units_to_pixels:new Ce(e,t.u_tile_units_to_pixels)}),YAe=(e,t)=>({u_opacity:e,u_color:t}),WAe=(e,t,r,i,n)=>Ne(JIe(r,n,t,i),{u_opacity:e}),ZAe=(e,t)=>({u_sun_pos:new ba(e,t.u_sun_pos),u_atmosphere_blend:new Ce(e,t.u_atmosphere_blend),u_globe_position:new ba(e,t.u_globe_position),u_globe_radius:new Ce(e,t.u_globe_radius),u_inv_proj_matrix:new ka(e,t.u_inv_proj_matrix)}),KAe=(e,t,r,i,n)=>({u_sun_pos:e,u_atmosphere_blend:t,u_globe_position:r,u_globe_radius:i,u_inv_proj_matrix:n}),XAe=(e,t)=>({u_sky_color:new hu(e,t.u_sky_color),u_horizon_color:new hu(e,t.u_horizon_color),u_horizon:new Je(e,t.u_horizon),u_horizon_normal:new Je(e,t.u_horizon_normal),u_sky_horizon_blend:new Ce(e,t.u_sky_horizon_blend),u_sky_blend:new Ce(e,t.u_sky_blend)}),JAe=(e,t,r)=>{let i=Math.cos(t.rollInRadians),n=Math.sin(t.rollInRadians),a=Lp(t),s=t.getProjectionData({overscaledTileID:null,applyGlobeMatrix:!0,applyTerrainMatrix:!0}).projectionTransition;return{u_sky_color:e.properties.get("sky-color"),u_horizon_color:e.properties.get("horizon-color"),u_horizon:[(t.width/2-a*n)*r,(t.height/2+a*i)*r],u_horizon_normal:[-n,i],u_sky_horizon_blend:e.properties.get("sky-horizon-blend")*t.height/2*r,u_sky_blend:s}},IE=(e,t)=>{},QAe={fillExtrusion:QIe,fillExtrusionPattern:eAe,fill:rAe,fillPattern:iAe,fillOutline:nAe,fillOutlinePattern:aAe,circle:uAe,collisionBox:dAe,collisionCircle:hAe,debug:mAe,depth:IE,clippingMask:IE,heatmap:gAe,heatmapTexture:_Ae,hillshade:yAe,hillshadePrepare:vAe,colorRelief:$Ae,line:TAe,lineGradient:CAe,linePattern:kAe,lineSDF:EAe,lineGradientSDF:PAe,layerOpacity:RAe,raster:LAe,symbolIcon:jAe,symbolSDF:UAe,symbolTextAndIcon:VAe,background:GAe,backgroundPattern:HAe,terrain:VIe,terrainDepth:qIe,terrainCoords:GIe,atmosphere:ZAe,sky:XAe};var e9e=class{constructor(e,t,r){this.context=e;let i=e.gl;this.buffer=i.createBuffer(),this.dynamicDraw=!!r,this.context.unbindVAO(),e.bindElementBuffer.set(this.buffer),i.bufferData(i.ELEMENT_ARRAY_BUFFER,t.arrayBuffer,this.dynamicDraw?i.DYNAMIC_DRAW:i.STATIC_DRAW),this.dynamicDraw||t.freeBufferAfterUpload()}bind(){this.context.bindElementBuffer.set(this.buffer)}updateData(e){let t=this.context.gl;if(!this.dynamicDraw)throw Error("Attempted to update data while not in dynamic mode.");this.context.unbindVAO(),this.bind(),t.bufferSubData(t.ELEMENT_ARRAY_BUFFER,0,e.arrayBuffer)}destroy(){let e=this.context.gl;this.buffer&&(e.deleteBuffer(this.buffer),delete this.buffer)}};const t9e={Int8:"BYTE",Uint8:"UNSIGNED_BYTE",Int16:"SHORT",Uint16:"UNSIGNED_SHORT",Int32:"INT",Uint32:"UNSIGNED_INT",Float32:"FLOAT"};
1544var r9e=class{constructor(e,t,r,i){this.length=t.length,this.attributes=r,this.itemSize=t.bytesPerElement,this.dynamicDraw=i,this.context=e;let n=e.gl;this.buffer=n.createBuffer(),e.bindVertexBuffer.set(this.buffer),n.bufferData(n.ARRAY_BUFFER,t.arrayBuffer,this.dynamicDraw?n.DYNAMIC_DRAW:n.STATIC_DRAW),this.dynamicDraw||t.freeBufferAfterUpload()}bind(){this.context.bindVertexBuffer.set(this.buffer)}updateData(e){if(e.length!==this.length)throw Error(`Length of new data is ${e.length}, which doesn't match current length of ${this.length}`);let t=this.context.gl;this.bind(),t.bufferSubData(t.ARRAY_BUFFER,0,e.arrayBuffer)}enableAttributes(e,t){for(let r of this.attributes){let i=t.attributes[r.name];i!==void 0&&e.enableVertexAttribArray(i)}}setVertexAttribPointers(e,t,r){for(let i of this.attributes){let n=t.attributes[i.name];n!==void 0&&e.vertexAttribPointer(n,i.components,e[t9e[i.type]],!1,this.itemSize,i.offset+this.itemSize*(r||0))}}destroy(){let e=this.context.gl;this.buffer&&(e.deleteBuffer(this.buffer),delete this.buffer)}},Wt=class{constructor(t){this.gl=t.gl,this.default=this.getDefault(),this.current=this.default,this.dirty=!1}get(){return this.current}set(t){}getDefault(){return this.default}setDefault(){this.set(this.default)}},i9e=class extends Wt{getDefault(){return at.transparent}set(e){let t=this.current;e.r===t.r&&e.g===t.g&&e.b===t.b&&e.a===t.a&&!this.dirty||(this.gl.clearColor(e.r,e.g,e.b,e.a),this.current=e,this.dirty=!1)}},n9e=class extends Wt{getDefault(){return 1}set(e){e===this.current&&!this.dirty||(this.gl.clearDepth(e),this.current=e,this.dirty=!1)}},a9e=class extends Wt{getDefault(){return 0}set(e){e===this.current&&!this.dirty||(this.gl.clearStencil(e),this.current=e,this.dirty=!1)}},s9e=class extends Wt{getDefault(){return[!0,!0,!0,!0]}set(e){let t=this.current;e[0]===t[0]&&e[1]===t[1]&&e[2]===t[2]&&e[3]===t[3]&&!this.dirty||(this.gl.colorMask(e[0],e[1],e[2],e[3]),this.current=e,this.dirty=!1)}},o9e=class extends Wt{getDefault(){return!0}set(e){e===this.current&&!this.dirty||(this.gl.depthMask(e),this.current=e,this.dirty=!1)}},l9e=class extends Wt{getDefault(){return 255}set(e){e===this.current&&!this.dirty||(this.gl.stencilMask(e),this.current=e,this.dirty=!1)}},u9e=class extends Wt{getDefault(){return{func:this.gl.ALWAYS,ref:0,mask:255}}set(e){let t=this.current;e.func===t.func&&e.ref===t.ref&&e.mask===t.mask&&!this.dirty||(this.gl.stencilFunc(e.func,e.ref,e.mask),this.current=e,this.dirty=!1)}},c9e=class extends Wt{getDefault(){let e=this.gl;return[e.KEEP,e.KEEP,e.KEEP]}set(e){let t=this.current;e[0]===t[0]&&e[1]===t[1]&&e[2]===t[2]&&!this.dirty||(this.gl.stencilOp(e[0],e[1],e[2]),this.current=e,this.dirty=!1)}},d9e=class extends Wt{getDefault(){return!1}set(e){if(e===this.current&&!this.dirty)return;let t=this.gl;e?t.enable(t.STENCIL_TEST):t.disable(t.STENCIL_TEST),this.current=e,this.dirty=!1}},h9e=class extends Wt{getDefault(){return[0,1]}set(e){let t=this.current;e[0]===t[0]&&e[1]===t[1]&&!this.dirty||(this.gl.depthRange(e[0],e[1]),this.current=e,this.dirty=!1)}},f9e=class extends Wt{getDefault(){return!1}set(e){if(e===this.current&&!this.dirty)return;let t=this.gl;e?t.enable(t.DEPTH_TEST):t.disable(t.DEPTH_TEST),this.current=e,this.dirty=!1}},p9e=class extends Wt{getDefault(){return this.gl.LESS}set(e){e===this.current&&!this.dirty||(this.gl.depthFunc(e),this.current=e,this.dirty=!1)}},m9e=class extends Wt{getDefault(){return!1}set(e){if(e===this.current&&!this.dirty)return;let t=this.gl;e?t.enable(t.BLEND):t.disable(t.BLEND),this.current=e,this.dirty=!1}},g9e=class extends Wt{getDefault(){let e=this.gl;return[e.ONE,e.ZERO]}set(e){let t=this.current;e[0]===t[0]&&e[1]===t[1]&&!this.dirty||(this.gl.blendFunc(e[0],e[1]),this.current=e,this.dirty=!1)}},_9e=class extends Wt{getDefault(){return at.transparent}set(e){let t=this.current;e.r===t.r&&e.g===t.g&&e.b===t.b&&e.a===t.a&&!this.dirty||(this.gl.blendColor(e.r,e.g,e.b,e.a),this.current=e,this.dirty=!1)}},y9e=class extends Wt{getDefault(){return this.gl.FUNC_ADD}set(e){e===this.current&&!this.dirty||(this.gl.blendEquation(e),this.current=e,this.dirty=!1)}},v9e=class extends Wt{getDefault(){return!1}set(e){if(e===this.current&&!this.dirty)return;let t=this.gl;e?t.enable(t.CULL_FACE):t.disable(t.CULL_FACE),this.current=e,this.dirty=!1}},b9e=class extends Wt{getDefault(){return this.gl.BACK}
vendor: 9,208 bytes, line 1544
1544set(e){e===this.current&&!this.dirty||(this.gl.cullFace(e),this.current=e,this.dirty=!1)}},x9e=class extends Wt{getDefault(){return this.gl.CCW}set(e){e===this.current&&!this.dirty||(this.gl.frontFace(e),this.current=e,this.dirty=!1)}},w9e=class extends Wt{getDefault(){return null}set(e){e===this.current&&!this.dirty||(this.gl.useProgram(e),this.current=e,this.dirty=!1)}},$9e=class extends Wt{getDefault(){return this.gl.TEXTURE0}set(e){e===this.current&&!this.dirty||(this.gl.activeTexture(e),this.current=e,this.dirty=!1)}},S9e=class extends Wt{getDefault(){let e=this.gl;return[0,0,e.drawingBufferWidth,e.drawingBufferHeight]}set(e){let t=this.current;e[0]===t[0]&&e[1]===t[1]&&e[2]===t[2]&&e[3]===t[3]&&!this.dirty||(this.gl.viewport(e[0],e[1],e[2],e[3]),this.current=e,this.dirty=!1)}},T9e=class extends Wt{getDefault(){return null}set(e){if(e===this.current&&!this.dirty)return;let t=this.gl;t.bindFramebuffer(t.FRAMEBUFFER,e),this.current=e,this.dirty=!1}},C9e=class extends Wt{getDefault(){return null}set(e){if(e===this.current&&!this.dirty)return;let t=this.gl;t.bindRenderbuffer(t.RENDERBUFFER,e),this.current=e,this.dirty=!1}},k9e=class extends Wt{getDefault(){return null}set(e){if(e===this.current&&!this.dirty)return;let t=this.gl;t.bindTexture(t.TEXTURE_2D,e),this.current=e,this.dirty=!1}},E9e=class extends Wt{getDefault(){return null}set(e){if(e===this.current&&!this.dirty)return;let t=this.gl;t.bindBuffer(t.ARRAY_BUFFER,e),this.current=e,this.dirty=!1}},P9e=class extends Wt{getDefault(){return null}set(e){let t=this.gl;t.bindBuffer(t.ELEMENT_ARRAY_BUFFER,e),this.current=e,this.dirty=!1}},M9e=class extends Wt{getDefault(){return null}set(e){e===this.current&&!this.dirty||(this.gl.bindVertexArray(e),this.current=e,this.dirty=!1)}},I9e=class extends Wt{getDefault(){return 4}set(e){if(e===this.current&&!this.dirty)return;let t=this.gl;t.pixelStorei(t.UNPACK_ALIGNMENT,e),this.current=e,this.dirty=!1}},A9e=class extends Wt{getDefault(){return!1}set(e){if(e===this.current&&!this.dirty)return;let t=this.gl;t.pixelStorei(t.UNPACK_PREMULTIPLY_ALPHA_WEBGL,e),this.current=e,this.dirty=!1}},D9e=class extends Wt{getDefault(){return!1}set(e){if(e===this.current&&!this.dirty)return;let t=this.gl;t.pixelStorei(t.UNPACK_FLIP_Y_WEBGL,e),this.current=e,this.dirty=!1}},DS=class extends Wt{constructor(e,t){super(e),this.context=e,this.parent=t}getDefault(){return null}},R9e=class extends DS{setDirty(){this.dirty=!0}set(e){if(e===this.current&&!this.dirty)return;this.context.bindFramebuffer.set(this.parent);let t=this.gl;t.framebufferTexture2D(t.FRAMEBUFFER,t.COLOR_ATTACHMENT0,t.TEXTURE_2D,e,0),this.current=e,this.dirty=!1}},O9e=class extends DS{set(e){if(e===this.current&&!this.dirty)return;this.context.bindFramebuffer.set(this.parent);let t=this.gl;t.framebufferRenderbuffer(t.FRAMEBUFFER,t.DEPTH_ATTACHMENT,t.RENDERBUFFER,e),this.current=e,this.dirty=!1}},L9e=class extends DS{set(e){if(e===this.current&&!this.dirty)return;this.context.bindFramebuffer.set(this.parent);let t=this.gl;t.framebufferRenderbuffer(t.FRAMEBUFFER,t.DEPTH_STENCIL_ATTACHMENT,t.RENDERBUFFER,e),this.current=e,this.dirty=!1}},F9e=class{constructor(e,t,r,i,n){this.context=e,this.width=t,this.height=r;let a=e.gl,s=this.framebuffer=a.createFramebuffer();if(this.colorAttachment=new R9e(e,s),i)this.depthAttachment=n?new L9e(e,s):new O9e(e,s);else if(n)throw Error("Stencil cannot be set without depth")}destroy(){let e=this.context.gl,t=this.colorAttachment.get();if(t&&e.deleteTexture(t),this.depthAttachment){let r=this.depthAttachment.get();r&&e.deleteRenderbuffer(r)}e.deleteFramebuffer(this.framebuffer)}},Mr=class{constructor(t,r,i){this.blendFunction=t,this.blendColor=r,this.mask=i}};Mr.Replace=[1,0],Mr.disabled=new Mr(Mr.Replace,at.transparent,[!1,!1,!1,!1]),Mr.unblended=new Mr(Mr.Replace,at.transparent,[!0,!0,!0,!0]),Mr.alphaBlended=new Mr([1,771],at.transparent,[!0,!0,!0,!0]);var z9e=class{constructor(e){this.gl=e,this.clearColor=new i9e(this),this.clearDepth=new n9e(this),this.clearStencil=new a9e(this),this.colorMask=new s9e(this),this.depthMask=new o9e(this),this.stencilMask=new l9e(this),this.stencilFunc=new u9e(this),this.stencilOp=new c9e(this),this.stencilTest=new d9e(this),this.depthRange=new h9e(this),this.depthTest=new f9e(this),this.depthFunc=new p9e(this),this.blend=new m9e(this),this.blendFunc=new g9e(this),this.blendColor=new _9e(this),this.blendEquation=new y9e(this),this.cullFace=new v9e(this),this.cullFaceSide=new b9e(this),this.frontFace=new x9e(this),this.program=new w9e(this),this.activeTexture=new $9e(this),this.viewport=new S9e(this),this.bindFramebuffer=new T9e(this),this.bindRenderbuffer=new C9e(this),this.bindTexture=new k9e(this),this.bindVertexBuffer=new E9e(this),this.bindElementBuffer=new P9e(this),this.bindVertexArray=new M9e(this),this.pixelStoreUnpack=new I9e(this),this.pixelStoreUnpackPremultiplyAlpha=new A9e(this),this.pixelStoreUnpackFlipY=new D9e(this),this.extTextureFilterAnisotropic=e.getExtension("EXT_texture_filter_anisotropic"),this.extTextureFilterAnisotropic&&(this.extTextureFilterAnisotropicMax=e.getParameter(this.extTextureFilterAnisotropic.MAX_TEXTURE_MAX_ANISOTROPY_EXT)),this.maxTextureSize=e.getParameter(e.MAX_TEXTURE_SIZE),e.getExtension("EXT_color_buffer_half_float"),e.getExtension("EXT_color_buffer_float")}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.bindVertexArray.dirty=!0,this.pixelStoreUnpack.dirty=!0,this.pixelStoreUnpackPremultiplyAlpha.dirty=!0,this.pixelStoreUnpackFlipY.dirty=!0}createIndexBuffer(e,t){return new e9e(this,e,t)}createVertexBuffer(e,t,r){return new r9e(this,e,t,r)}createRenderbuffer(e,t,r){let i=this.gl,n=i.createRenderbuffer();return this.bindRenderbuffer.set(n),i.renderbufferStorage(i.RENDERBUFFER,e,t,r),this.bindRenderbuffer.set(null),n}createFramebuffer(e,t,r,i){return new F9e(this,e,t,r,i)}clear({color:e,depth:t,stencil:r}){let i=this.gl,n=0;e&&(n|=i.COLOR_BUFFER_BIT,this.clearColor.set(e),this.colorMask.set([!0,!0,!0,!0])),t!==void 0&&(n|=i.DEPTH_BUFFER_BIT,this.depthRange.set([0,1]),this.clearDepth.set(t),this.depthMask.set(!0)),r!==void 0&&(n|=i.STENCIL_BUFFER_BIT,this.clearStencil.set(r),this.stencilMask.set(255)),i.clear(n)}setCullFace(e){e.enable===!1?this.cullFace.set(!1):(this.cullFace.set(!0),this.cullFaceSide.set(e.mode),this.frontFace.set(e.frontFace))}setDepthMode(e){e.func===this.gl.ALWAYS&&!e.mask?this.depthTest.set(!1):(this.depthTest.set(!0),this.depthFunc.set(e.func),this.depthMask.set(e.mask),this.depthRange.set(e.range))}setStencilMode(e){e.test.func===this.gl.ALWAYS&&!e.mask?this.stencilTest.set(!1):(this.stencilTest.set(!0),this.stencilMask.set(e.mask),this.stencilOp.set([e.fail,e.depthFail,e.pass]),this.stencilFunc.set({func:e.test.func,ref:e.ref,mask:e.test.mask}))}setColorMode(e){Gs(e.blendFunction,Mr.Replace)?this.blend.set(!1):(this.blend.set(!0),this.blendFunc.set(e.blendFunction),this.blendColor.set(e.blendColor)),this.colorMask.set(e.mask)}createVertexArray(){return this.gl.createVertexArray()}deleteVertexArray(e){this.gl.deleteVertexArray(e)}unbindVAO(){this.bindVertexArray.set(null)}},gt=class{constructor(t,r,i){this.func=t,this.mask=r,this.range=i}};gt.ReadOnly=!1,gt.ReadWrite=!0,gt.disabled=new gt(519,gt.ReadOnly,[0,1]);const Kb=7680;var jt=class{constructor(t,r,i,n,a,s){this.test=t,this.ref=r,this.mask=i,this.fail=n,this.depthFail=a,this.pass=s}};jt.disabled=new jt({func:519,mask:0},0,0,Kb,Kb,Kb);const AE=1029,Xb=2305;var Nt=class{constructor(e,t,r){this.enable=e,this.mode=t,this.frontFace=r}};Nt.disabled=new Nt(!1,AE,Xb),Nt.backCCW=new Nt(!0,AE,Xb),Nt.frontCCW=new Nt(!0,1028,Xb);let I0;function DE(e,t,r,i,n){var v,x;let a=e.context,s=e.transform,o=a.gl,l=e.useProgram("collisionBox"),u=[],c=0,d=0;for(let _ of i){let y=t.getTile(_).getBucket(r);
vendor: 19,212 bytes, line 1544
1544if(!y)continue;let w=n?y.textCollisionBox:y.iconCollisionBox,$=y.collisionCircleArray;$.length>0&&(u.push({circleArray:$,circleOffset:d,coord:_}),c+=$.length/4,d=c),w&&l.draw(a,o.LINES,gt.disabled,jt.disabled,e.colorModeForRenderPass(),Nt.disabled,fAe(e.transform),(v=e.style.map.terrain)==null?void 0:v.getTerrainData(_),s.getProjectionData({overscaledTileID:_,applyGlobeMatrix:!0,applyTerrainMatrix:!0}),r.id,w.layoutVertexBuffer,w.indexBuffer,w.segments,null,e.transform.zoom,null,null,w.collisionVertexBuffer)}if(!n||!u.length)return;let h=e.useProgram("collisionCircle"),f=new HTe;f.resize(c*4),f._trim();let p=0;for(let _ of u)for(let y=0;y<_.circleArray.length/4;y++){let w=y*4,$=_.circleArray[w+0],S=_.circleArray[w+1],E=_.circleArray[w+2],C=_.circleArray[w+3];f.emplace(p++,$,S,E,C,0),f.emplace(p++,$,S,E,C,1),f.emplace(p++,$,S,E,C,2),f.emplace(p++,$,S,E,C,3)}(!I0||I0.length<c*2)&&(I0=N9e(c));let m=a.createIndexBuffer(I0,!0),g=a.createVertexBuffer(f,cke.members,!0);for(let _ of u){let y=pAe(e.transform);h.draw(a,o.TRIANGLES,gt.disabled,jt.disabled,e.colorModeForRenderPass(),Nt.disabled,y,(x=e.style.map.terrain)==null?void 0:x.getTerrainData(_.coord),null,r.id,g,m,$r.simpleSegment(0,_.circleOffset*2,_.circleArray.length,_.circleArray.length/2),null,e.transform.zoom,null,null,null)}g.destroy(),m.destroy()}function N9e(e){let t=e*2,r=new WTe;r.resize(t),r._trim();for(let i=0;i<t;i++){let n=i*6;r.uint16[n+0]=i*4+0,r.uint16[n+1]=i*4+1,r.uint16[n+2]=i*4+2,r.uint16[n+3]=i*4+2,r.uint16[n+4]=i*4+3,r.uint16[n+5]=i*4+0}return r}const B9e=Ms(new Float32Array(16));function j9e(e,t,r,i,n,a){if(e.renderPass!=="translucent")return;let{isRenderingToTexture:s}=a,o=jt.disabled,l=e.colorModeForRenderPass();(r._unevaluatedLayout.hasValue("text-variable-anchor")||r._unevaluatedLayout.hasValue("text-variable-anchor-offset"))&&V9e(i,e,r,t,r.layout.get("text-rotation-alignment"),r.layout.get("text-pitch-alignment"),r.paint.get("text-translate"),r.paint.get("text-translate-anchor"),n),r.paint.get("icon-opacity").constantOr(1)!==0&&RE(e,t,r,i,!1,r.paint.get("icon-translate"),r.paint.get("icon-translate-anchor"),r.layout.get("icon-rotation-alignment"),r.layout.get("icon-pitch-alignment"),r.layout.get("icon-keep-upright"),o,l,s),r.paint.get("text-opacity").constantOr(1)!==0&&RE(e,t,r,i,!0,r.paint.get("text-translate"),r.paint.get("text-translate-anchor"),r.layout.get("text-rotation-alignment"),r.layout.get("text-pitch-alignment"),r.layout.get("text-keep-upright"),o,l,s),t.map.showCollisionBoxes&&(DE(e,t,r,i,!0),DE(e,t,r,i,!1))}function U9e(e,t,r,i,n,a){let{horizontalAlign:s,verticalAlign:o}=ZL(e),l=-(s-.5)*t,u=-(o-.5)*r;return new de((l/n+i[0])*a,(u/n+i[1])*a)}function V9e(e,t,r,i,n,a,s,o,l){var f;let u=t.transform,c=t.style.map.terrain,d=n==="map",h=a==="map";for(let p of e){let m=i.getTile(p),g=m.getBucket(r);if(!((f=g==null?void 0:g.text)!=null&&f.segments.get().length))continue;let v=g.textSizeData,x=fv(v,u.zoom),_=Ca(m,1,t.transform.zoom),y=kS(d,t.transform,_),w=r.layout.get("icon-text-fit")!=="none"&&g.hasIconData();if(x){let $=2**(u.zoom-m.tileID.overscaledZ),S=c?(E,C)=>c.getElevation(p,E,C):null;G9e(g,d,h,l,u,y,$,x,w,lu(u,m,s,o),p.toUnwrapped(),S)}}}function q9e(e,t,r,i,n,a){let s=t.tileAnchorPoint.add(new de(t.translation[0],t.translation[1]));if(t.pitchWithMap){let o=i.mult(a);r||(o=o.rotate(-n));let l=s.add(o);return PS(l.x,l.y,t.pitchedLabelPlaneMatrix,t.getElevation).point}if(r){let o=Ec(t.tileAnchorPoint.x+1,t.tileAnchorPoint.y,t).point.sub(e),l=Math.atan(o.y/o.x)+(o.x<0?Math.PI:0);return e.add(i.rotate(l))}return e.add(i)}function G9e(e,t,r,i,n,a,s,o,l,u,c,d){let h=e.text.placedSymbolArray,f=e.text.dynamicLayoutVertexArray,p=e.icon.dynamicLayoutVertexArray,m={};f.clear();for(let g=0;g<h.length;g++){let v=h.get(g),x=e.allowVerticalPlacement&&!v.placedOrientation,_=!v.hidden&&v.crossTileID&&!x?i[v.crossTileID]:null;if(!_)th(v.numGlyphs,f);else{let y=new de(v.anchorX,v.anchorY),w={getElevation:d,width:n.width,height:n.height,pitchedLabelPlaneMatrix:a,pitchWithMap:r,transform:n,tileAnchorPoint:y,translation:u,unwrappedTileID:c},$=r?LF(y.x,y.y,w):Ec(y.x,y.y,w),S=DF(n.cameraToCenterDistance,$.signedDistanceFromCamera),E=dS(e.textSizeData,o,v)*S/24;r&&(E*=e.tilePixelRatio/s);let{width:C,height:I,anchor:P,textOffset:T,textBoxScale:D}=_,A=U9e(P,C,I,T,D,E),z=n.getPitchedTextCorrection(y.x+u[0],y.y+u[1],c),R=q9e($.point,w,t,A,-n.bearingInRadians,z),O=e.allowVerticalPlacement&&v.placedOrientation===2?Math.PI/2:0;for(let V=0;V<v.numGlyphs;V++)Bm(f,R,O);l&&v.associatedIconIndex>=0&&(m[v.associatedIconIndex]={shiftedAnchor:R,angle:O})}}if(l){p.clear();let g=e.icon.placedSymbolArray;for(let v=0;v<g.length;v++){let x=g.get(v);if(x.hidden)th(x.numGlyphs,p);else{let _=m[v];if(!_)th(x.numGlyphs,p);else for(let y=0;y<x.numGlyphs;y++)Bm(p,_.shiftedAnchor,_.angle)}}e.icon.dynamicLayoutVertexBuffer.updateData(p)}e.text.dynamicLayoutVertexBuffer.updateData(f)}function H9e(e,t,r){return r.iconsInText&&t?"symbolTextAndIcon":e?"symbolSDF":"symbolIcon"}function RE(e,t,r,i,n,a,s,o,l,u,c,d,h){var T;let f=e.context,p=f.gl,m=e.transform,g=o==="map",v=l==="map",x=o!=="viewport"&&r.layout.get("symbol-placement")!=="point",_=g&&!v&&!x,y=!r.layout.get("symbol-sort-key").isConstant(),w=!1,$=e.getDepthModeForSublayer(0,gt.ReadOnly),S=r._unevaluatedLayout.hasValue("text-variable-anchor")||r._unevaluatedLayout.hasValue("text-variable-anchor-offset"),E=[],C=m.getCircleRadiusCorrection();for(let D of i){let A=t.getTile(D),z=A.getBucket(r);if(!z)continue;let R=n?z.text:z.icon;if(!(R!=null&&R.segments.get().length)||!R.hasVisibleVertices)continue;let O=R.programConfigurations.get(r.id),V=n||z.sdfIcons,Y=n?z.textSizeData:z.iconSizeData,F=v||m.pitch!==0,ae=e.useProgram(H9e(V,n,z),O),ue=fv(Y,m.zoom),Z=(T=e.style.map.terrain)==null?void 0:T.getTerrainData(D),K,fe=[0,0],ve,$e,Re=null,Oe;if(n){if(ve=A.glyphAtlasTexture,$e=p.LINEAR,K=A.glyphAtlasTexture.size,z.iconsInText){fe=A.imageAtlasTexture.size,Re=A.imageAtlasTexture;let ee=Y.kind==="composite"||Y.kind==="camera";Oe=F||e.options.rotating||e.options.zooming||ee?p.LINEAR:p.NEAREST}}else{let ee=r.layout.get("icon-size").constantOr(0)!==1||z.iconsNeedLinear;ve=A.imageAtlasTexture,$e=V||e.options.rotating||e.options.zooming||ee||F?p.LINEAR:p.NEAREST,K=A.imageAtlasTexture.size}let ze=Ca(A,1,e.transform.zoom),Be=kS(g,e.transform,ze),qe=HMe(v,g,e.transform,ze),j=lu(m,A,a,s),W=m.getProjectionData({overscaledTileID:D,applyGlobeMatrix:!h,applyTerrainMatrix:!0}),G=S&&z.hasTextData(),ie=r.layout.get("icon-text-fit")!=="none"&&G&&z.hasIconData(),U=r._unevaluatedLayout.hasValue("icon-offset");if(x){let ee=_u();UMe(ee,Be);let oe=e.style.map.terrain?(Se,we)=>e.style.map.terrain.getElevation(D,Se,we):null;WMe(z,e,n,Be,ee,v,u,r.layout.get("text-rotation-alignment")==="map",D.toUnwrapped(),m.width,m.height,j,oe)}let ne=n&&S||ie,me=v?Be:e.transform.clipSpaceToPixelsMatrix,J=x||ne?B9e:me,N=V&&r.paint.get(n?"text-halo-width":"icon-halo-width").constantOr(1)!==0,q;q=V?z.iconsInText?qAe(Y.kind,ue,_,v,x,ne,e,J,qe,j,K,fe,C,U):cz(Y.kind,ue,_,v,x,ne,e,J,qe,j,n,K,N,C,U):uz(Y.kind,ue,_,v,x,ne,e,J,qe,j,n,K,C,U);let te={program:ae,buffers:R,uniformValues:q,projectionData:W,atlasTexture:ve,atlasTextureIcon:Re,atlasInterpolation:$e,atlasInterpolationIcon:Oe,isSDF:V,hasHalo:N};if(y&&z.canOverlap){w=!0;let ee=R.segments.get();for(let oe of ee)E.push({segments:new $r([oe]),sortKey:oe.sortKey,state:te,terrainData:Z})}else E.push({segments:R.segments,sortKey:0,state:te,terrainData:Z})}w&&E.sort((D,A)=>D.sortKey-A.sortKey);let I=r.paint.get(n?"text-halo-width":"icon-halo-width").constantOr(null)??1/0,P=r.layout.get("text-letter-spacing").constantOr(0)*24<0||I>1;for(let D of E){let A=D.state;f.activeTexture.set(p.TEXTURE0),A.atlasTexture.bind(A.atlasInterpolation,p.CLAMP_TO_EDGE),A.atlasTextureIcon&&(f.activeTexture.set(p.TEXTURE1),A.atlasTextureIcon&&A.atlasTextureIcon.bind(A.atlasInterpolationIcon,p.CLAMP_TO_EDGE));let z=A.isSDF&&A.hasHalo;if(z){let R=A.uniformValues;R.u_is_halo=1,P&&(R.u_is_plain=0,OE(A.buffers,D.segments,r,e,A.program,$,c,d,R,A.projectionData,D.terrainData),R.u_is_halo=0,R.u_is_plain=1)}OE(A.buffers,D.segments,r,e,A.program,$,c,d,A.uniformValues,A.projectionData,D.terrainData),z&&!P&&(A.uniformValues.u_is_halo=0)}}function OE(e,t,r,i,n,a,s,o,l,u,c){let d=i.context,h=d.gl;n.draw(d,h.TRIANGLES,a,s,o,Nt.backCCW,l,c,u,r.id,e.layoutVertexBuffer,e.indexBuffer,t,r.paint,i.transform.zoom,e.programConfigurations.get(r.id),e.dynamicLayoutVertexBuffer,e.opacityVertexBuffer)}function Y9e(e,t,r,i,n){var x;if(e.renderPass!=="translucent")return;let{isRenderingToTexture:a}=n,s=r.paint.get("circle-opacity"),o=r.paint.get("circle-stroke-width"),l=r.paint.get("circle-stroke-opacity"),u=!r.layout.get("circle-sort-key").isConstant();if(s.constantOr(1)===0&&(o.constantOr(1)===0||l.constantOr(1)===0))return;let c=e.context,d=c.gl,h=e.transform,f=e.getDepthModeForSublayer(0,gt.ReadOnly),p=jt.disabled,m=e.colorModeForRenderPass(),g=[],v=h.getCircleRadiusCorrection();for(let _ of i){let y=t.getTile(_),w=y.getBucket(r);if(!w)continue;let $=r.paint.get("circle-translate"),S=r.paint.get("circle-translate-anchor"),E=lu(h,y,$,S),C=w.programConfigurations.get(r.id),I=e.useProgram("circle",C),P=w.layoutVertexBuffer,T=w.indexBuffer,D=(x=e.style.map.terrain)==null?void 0:x.getTerrainData(_),A={programConfiguration:C,program:I,layoutVertexBuffer:P,indexBuffer:T,uniformValues:cAe(e,y,r,E,v),terrainData:D,projectionData:h.getProjectionData({overscaledTileID:_,applyGlobeMatrix:!a,applyTerrainMatrix:!0})};if(u){let z=w.segments.get();for(let R of z)g.push({segments:new $r([R]),sortKey:R.sortKey,state:A})}else g.push({segments:w.segments,sortKey:0,state:A})}u&&g.sort((_,y)=>_.sortKey-y.sortKey);for(let _ of g){let{programConfiguration:y,program:w,layoutVertexBuffer:$,indexBuffer:S,uniformValues:E,terrainData:C,projectionData:I}=_.state,P=_.segments;w.draw(c,d.TRIANGLES,f,p,m,Nt.backCCW,E,C,I,r.id,$,S,P,r.paint,e.transform.zoom,y)}}function W9e(e,t,r,i,n){if(r.paint.get("heatmap-opacity")===0)return;let a=e.context,{isRenderingToTexture:s,isRenderingGlobe:o}=n;if(e.style.map.terrain){for(let l of i){let u=t.getTile(l);t.hasRenderableParent(l)||(e.renderPass==="offscreen"?X9e(e,u,r,l,o):e.renderPass==="translucent"&&J9e(e,r,l,s,o))}a.viewport.set([0,0,e.width,e.height])}else e.renderPass==="offscreen"?Z9e(e,t,r,i):e.renderPass==="translucent"&&K9e(e,r)}function Z9e(e,t,r,i){let n=e.context,a=n.gl,s=e.transform,o=jt.disabled,l=new Mr([a.ONE,a.ONE],at.transparent,[!0,!0,!0,!0]);Q9e(n,e,r),n.clear({color:at.transparent});for(let u of i){if(t.hasRenderableParent(u))continue;let c=t.getTile(u),d=c.getBucket(r);if(!d)continue;let h=d.programConfigurations.get(r.id),f=e.useProgram("heatmap",h),p=s.getProjectionData({overscaledTileID:u,applyGlobeMatrix:!0,applyTerrainMatrix:!1}),m=s.getCircleRadiusCorrection();f.draw(n,a.TRIANGLES,gt.disabled,o,l,Nt.backCCW,sz(c,s.zoom,r.paint.get("heatmap-intensity"),m),null,p,r.id,d.layoutVertexBuffer,d.indexBuffer,d.segments,r.paint,s.zoom,h)}n.viewport.set([0,0,e.width,e.height])}function K9e(e,t){let r=e.context,i=r.gl;r.setColorMode(e.colorModeForRenderPass());let n=t.heatmapFbos.get(Ly);n&&(r.activeTexture.set(i.TEXTURE0),i.bindTexture(i.TEXTURE_2D,n.colorAttachment.get()),r.activeTexture.set(i.TEXTURE1),hz(r,t).bind(i.LINEAR,i.CLAMP_TO_EDGE),e.useProgram("heatmapTexture").draw(r,i.TRIANGLES,gt.disabled,jt.disabled,e.colorModeForRenderPass(),Nt.disabled,oz(e,t,0,1),null,null,t.id,e.viewportBuffer,e.quadTriangleIndexBuffer,e.viewportSegments,t.paint,e.transform.zoom))}function X9e(e,t,r,i,n){let a=e.context,s=a.gl,o=jt.disabled,l=new Mr([s.ONE,s.ONE],at.transparent,[!0,!0,!0,!0]),u=t.getBucket(r);if(!u)return;let c=i.key,d=r.heatmapFbos.get(c);d||(d=dz(a,t.tileSize,t.tileSize),r.heatmapFbos.set(c,d)),a.bindFramebuffer.set(d.framebuffer),a.viewport.set([0,0,t.tileSize,t.tileSize]),a.clear({color:at.transparent});let h=u.programConfigurations.get(r.id),f=e.useProgram("heatmap",h,!n),p=e.transform.getProjectionData({overscaledTileID:t.tileID,applyGlobeMatrix:!0,applyTerrainMatrix:!0}),m=e.style.map.terrain.getTerrainData(i);f.draw(a,s.TRIANGLES,gt.disabled,o,l,Nt.disabled,sz(t,e.transform.zoom,r.paint.get("heatmap-intensity"),1),m,p,r.id,u.layoutVertexBuffer,u.indexBuffer,u.segments,r.paint,e.transform.zoom,h)}function J9e(e,t,r,i,n){let a=e.context,s=a.gl,o=e.transform;a.setColorMode(e.colorModeForRenderPass());let l=hz(a,t),u=r.key,c=t.heatmapFbos.get(u);if(!c)return;a.activeTexture.set(s.TEXTURE0),s.bindTexture(s.TEXTURE_2D,c.colorAttachment.get()),a.activeTexture.set(s.TEXTURE1),l.bind(s.LINEAR,s.CLAMP_TO_EDGE);let d=o.getProjectionData({overscaledTileID:r,applyTerrainMatrix:n,applyGlobeMatrix:!i});e.useProgram("heatmapTexture").draw(a,s.TRIANGLES,gt.disabled,jt.disabled,e.colorModeForRenderPass(),Nt.disabled,oz(e,t,0,1),null,d,t.id,e.rasterBoundsBuffer,e.quadTriangleIndexBuffer,e.rasterBoundsSegments,t.paint,o.zoom),c.destroy(),t.heatmapFbos.delete(u)}function Q9e(e,t,r){let i=e.gl;e.activeTexture.set(i.TEXTURE1),e.viewport.set([0,0,t.width/4,t.height/4]);let n=r.heatmapFbos.get(Ly);n?(i.bindTexture(i.TEXTURE_2D,n.colorAttachment.get()),e.bindFramebuffer.set(n.framebuffer)):(n=dz(e,t.width/4,t.height/4),r.heatmapFbos.set(Ly,n))}function dz(e,t,r){let i=e.gl,n=i.createTexture();i.bindTexture(i.TEXTURE_2D,n),i.texParameteri(i.TEXTURE_2D,i.TEXTURE_WRAP_S,i.CLAMP_TO_EDGE),i.texParameteri(i.TEXTURE_2D,i.TEXTURE_WRAP_T,i.CLAMP_TO_EDGE),i.texParameteri(i.TEXTURE_2D,i.TEXTURE_MIN_FILTER,i.LINEAR),i.texParameteri(i.TEXTURE_2D,i.TEXTURE_MAG_FILTER,i.LINEAR),i.texStorage2D(i.TEXTURE_2D,1,i.RGBA16F,t,r);let a=e.createFramebuffer(t,r,!1,!1);return a.colorAttachment.set(n),a}function hz(e,t){return t.colorRampTexture||(t.colorRampTexture=new Hr(e,t.colorRamp,e.gl.RGBA)),t.colorRampTexture}function fz(e,t,r,i){let n=e.context,a=n.bindFramebuffer.get(),s=n.viewport.get(),[,,o,l]=s;return eDe(e,o,l),n.viewport.set([0,0,o,l]),n.clear({color:at.transparent,depth:1,stencil:0}),e.currentStencilSource=void 0,e.renderTileClippingMasks(t,r,i),{compositeTarget:a,compositeViewport:s}}function eDe(e,t,r){let i=e.context.gl;if(!e.layerOpacityFbo){let a=e.context.createFramebuffer(t,r,!0,!0),s=i.createTexture();i.bindTexture(i.TEXTURE_2D,s),i.texParameteri(i.TEXTURE_2D,i.TEXTURE_WRAP_S,i.CLAMP_TO_EDGE),i.texParameteri(i.TEXTURE_2D,i.TEXTURE_WRAP_T,i.CLAMP_TO_EDGE),i.texParameteri(i.TEXTURE_2D,i.TEXTURE_MIN_FILTER,i.LINEAR),i.texParameteri(i.TEXTURE_2D,i.TEXTURE_MAG_FILTER,i.LINEAR),i.texImage2D(i.TEXTURE_2D,0,i.RGBA,t,r,0,i.RGBA,i.UNSIGNED_BYTE,null),a.colorAttachment.set(s),a.depthAttachment.set(e.context.createRenderbuffer(i.DEPTH_STENCIL,t,r)),e.layerOpacityFbo=a,e.context.bindFramebuffer.set(e.layerOpacityFbo.framebuffer);return}if(e.layerOpacityFbo.width===t&&e.layerOpacityFbo.height===r){e.context.bindFramebuffer.set(e.layerOpacityFbo.framebuffer);return}let n=e.layerOpacityFbo;i.bindTexture(i.TEXTURE_2D,n.colorAttachment.get()),i.texImage2D(i.TEXTURE_2D,0,i.RGBA,t,r,0,i.RGBA,i.UNSIGNED_BYTE,null),e.context.bindRenderbuffer.set(n.depthAttachment.get()),i.renderbufferStorage(i.RENDERBUFFER,i.DEPTH_STENCIL,t,r),e.context.bindRenderbuffer.set(null),n.width=t,n.height=r,e.context.bindFramebuffer.set(n.framebuffer)}function pz(e,t,r,i){let n=e.context,a=n.gl;n.bindFramebuffer.set(r.compositeTarget),n.viewport.set(r.compositeViewport),n.activeTexture.set(a.TEXTURE0),a.bindTexture(a.TEXTURE_2D,e.layerOpacityFbo.colorAttachment.get()),e.useProgram("layerOpacity").draw(n,a.TRIANGLES,gt.disabled,jt.disabled,e.colorModeForRenderPass(),Nt.disabled,OAe(t,0),null,null,i.id,e.viewportBuffer,e.quadTriangleIndexBuffer,e.viewportSegments,i.paint,e.transform.zoom),e.currentStencilSource=void 0}function mz(e,t,r,i,n,a,s,o){let l=256;if(n.stepInterpolant){let u=t.getSource().maxzoom,c=s.canonical.z===u?Math.ceil(1<<e.transform.maxZoom-s.canonical.z):1,d=a.maxLineLength/ye*1024*c;l=Ot(Z$e(d),256,r.maxTextureSize)}return o.gradient=kL({expression:n.gradientExpression(),evaluationKey:"lineProgress",resolution:l,image:o.gradient||void 0,clips:a.lineClipsArray}),o.texture?o.texture.update(o.gradient):o.texture=new Hr(r,o.gradient,i.RGBA),o.version=n.gradientVersion,o.texture}function tDe(e,t,r,i,n){e.activeTexture.set(t.TEXTURE0),r.imageAtlasTexture.bind(t.LINEAR,t.CLAMP_TO_EDGE),i.updatePaintBuffers(n)}function rDe(e,t,r,i,n,a){(n||e.lineAtlas.dirty)&&(t.activeTexture.set(r.TEXTURE0),e.lineAtlas.bind(t)),i.updatePaintBuffers(a)}function iDe(e,t,r,i,n,a,s){let o=a.gradients[n.id],l=o.texture;n.gradientVersion!==o.version&&(l=mz(e,t,r,i,n,a,s,o)),r.activeTexture.set(i.TEXTURE0),l.bind(n.stepInterpolant?i.NEAREST:i.LINEAR,i.CLAMP_TO_EDGE)}function nDe(e,t,r,i,n,a,s,o,l){let u=a.gradients[n.id],c=u.texture;n.gradientVersion!==u.version&&(c=mz(e,t,r,i,n,a,s,u)),r.activeTexture.set(i.TEXTURE0),c.bind(n.stepInterpolant?i.NEAREST:i.LINEAR,i.CLAMP_TO_EDGE),r.activeTexture.set(i.TEXTURE1),e.lineAtlas.bind(r),o.updatePaintBuffers(l)}function aDe(e,t,r,i,n){if(e.renderPass!=="translucent")return;let a=r.paint.get("line-opacity"),s=r.paint.get("line-width"),o=r.paint.get("line-layer-opacity");if(a.constantOr(1)===0||s.constantOr(1)===0||o===0)return;let l=!!e.style.map.terrain;if(o<1){let u=fz(e,r,i,l);LE(e,t,r,i,n,l),pz(e,o,u,r);return}LE(e,t,r,i,n,l)}function LE(e,t,r,i,n,a){let{isRenderingToTexture:s}=n,o=e.getDepthModeForSublayer(0,gt.ReadOnly),l=e.colorModeForRenderPass(),u=r.paint.get("line-dasharray"),c=u.constantOr(1),d=r.paint.get("line-pattern"),h=d.constantOr(1),f=r.paint.get("line-gradient"),p=r.getCrossfadeParameters(),m;m=h?"linePattern":c&&f?"lineGradientSDF":c?"lineSDF":f?"lineGradient":"line";let g=e.context,v=g.gl,x=e.transform,_=!0;for(let y of i){let w=t.getTile(y);if(h&&!w.patternsLoaded())continue;let $=w.getBucket(r);if(!$)continue;let S=$.programConfigurations.get(r.id),E=e.context.program.get(),C=e.useProgram(m,S),I=_||C.program!==E,P=a?e.getTerrainDataForTile(y,s):null,T=d.constantOr(null),D=u==null?void 0:u.constantOr(null);if(T&&w.imageAtlas){let V=w.imageAtlas,Y=V.patternPositions[T.to.toString()],F=V.patternPositions[T.from.toString()];Y&&F&&S.setConstantPatternPositions(Y,F)}else if(D){let V=r.layout.get("line-cap").constantOr(null)==="round",Y=e.lineAtlas.getDash(D.to,V),F=e.lineAtlas.getDash(D.from,V);S.setConstantDashPositions(Y,F)}let A=x.getProjectionData({overscaledTileID:y,applyGlobeMatrix:!s,applyTerrainMatrix:!0}),z=x.getPixelScale(),R;h?(R=IAe(e,w,r,z,p),tDe(g,v,w,S,p)):c&&f?(R=DAe(e,w,r,z,p,$.lineClipsArray.length),nDe(e,t,g,v,r,$,y,S,p)):c?(R=AAe(e,w,r,z,p),rDe(e,g,v,S,I,p)):f?(R=MAe(e,w,r,z,$.lineClipsArray.length),iDe(e,t,g,v,r,$,y)):R=yv(e,w,r,z);let O=e.stencilModeForClipping(y);C.draw(g,v.TRIANGLES,o,O,l,Nt.disabled,R,P,A,r.id,$.layoutVertexBuffer,$.indexBuffer,$.segments,r.paint,e.transform.zoom,S,$.layoutVertexBuffer2),_=!1}}function gz(e,t,r,i,n){if(!r||!(i!=null&&i.imageAtlas))return;let a=i.imageAtlas.patternPositions,s=a[r.to.toString()],o=a[r.from.toString()];if(!s&&o&&(s=o),!o&&s&&(o=s),!s||!o){let l=n.getPaintProperty(t);s=a[l],o=a[l]}s&&o&&e.setConstantPatternPositions(s,o)}function sDe(e,t,r,i,n){let a=r.paint.get("fill-color"),s=r.paint.get("fill-opacity"),o=r.paint.get("fill-layer
vendor: 9,504 bytes, line 1544
1544-opacity");if(s.constantOr(1)===0||o===0)return;if(o<1){if(e.renderPass!=="translucent")return;let c=fz(e,r,i,!!e.style.map.terrain);FE(e,t,r,i,n),pz(e,o,c,r);return}let l=r.paint.get("fill-pattern"),u=e.opaquePassEnabledForLayer()&&!l.constantOr(1)&&a.constantOr(at.transparent).a===1&&s.constantOr(0)===1;if(u&&e.renderPass==="opaque"){let{isRenderingToTexture:c}=n,d=e.colorModeForRenderPass();RS(e,t,r,i,e.getDepthModeForSublayer(1,gt.ReadWrite),d,!1,c);return}if(u&&e.renderPass==="translucent"){_z(e,t,r,i,n);return}e.renderPass==="translucent"&&FE(e,t,r,i,n)}function FE(e,t,r,i,n){let{isRenderingToTexture:a}=n,s=e.colorModeForRenderPass();RS(e,t,r,i,e.getDepthModeForSublayer(1,gt.ReadOnly),s,!1,a),_z(e,t,r,i,n)}function _z(e,t,r,i,n){if(!r.paint.get("fill-antialias"))return;let{isRenderingToTexture:a}=n,s=e.colorModeForRenderPass();RS(e,t,r,i,e.getDepthModeForSublayer(r.getPaintProperty("fill-outline-color")?2:0,gt.ReadOnly),s,!0,a)}function RS(e,t,r,i,n,a,s,o){let l=e.context.gl,u="fill-pattern",c=r.paint.get(u),d=c==null?void 0:c.constantOr(1),h=r.getCrossfadeParameters(),f,p,m,g,v,x=e.transform,_=r.paint.get("fill-translate"),y=r.paint.get("fill-translate-anchor");s?(p=d&&!r.getPaintProperty("fill-outline-color")?"fillOutlinePattern":"fillOutline",f=l.LINES):(p=d?"fillPattern":"fill",f=l.TRIANGLES);let w=c.constantOr(null);for(let $ of i){let S=t.getTile($);if(d&&!S.patternsLoaded())continue;let E=S.getBucket(r);if(!E)continue;let C=E.programConfigurations.get(r.id),I=e.useProgram(p,C),P=e.getTerrainDataForTile($,o);d&&(e.context.activeTexture.set(l.TEXTURE0),S.imageAtlasTexture.bind(l.LINEAR,l.CLAMP_TO_EDGE),C.updatePaintBuffers(h)),gz(C,u,w,S,r);let T=x.getProjectionData({overscaledTileID:$,applyGlobeMatrix:!o,applyTerrainMatrix:!0}),D=lu(x,S,_,y);if(!s)g=E.indexBuffer,v=E.segments,m=d?az(e,h,S,D):sAe(D);else{g=E.indexBuffer2,v=E.segments2;let z=[l.drawingBufferWidth,l.drawingBufferHeight];m=p==="fillOutlinePattern"&&d?lAe(e,h,S,z,D):oAe(z,D)}let A=e.stencilModeForClipping($);I.draw(e.context,f,n,A,a,Nt.backCCW,m,P,T,r.id,E.layoutVertexBuffer,g,v,r.paint,e.transform.zoom,C)}}function oDe(e,t,r,i,n){let a=r.paint.get("fill-extrusion-opacity");if(a===0)return;let{isRenderingToTexture:s}=n;if(e.renderPass==="translucent"){let o=new gt(e.context.gl.LEQUAL,gt.ReadWrite,e.depthRangeFor3D);if(a===1&&!r.paint.get("fill-extrusion-pattern").constantOr(1)){let l=e.colorModeForRenderPass();Jb(e,t,r,i,o,jt.disabled,l,s)}else Jb(e,t,r,i,o,jt.disabled,Mr.disabled,s),Jb(e,t,r,i,o,e.stencilModeFor3D(),e.colorModeForRenderPass(),s)}}function Jb(e,t,r,i,n,a,s,o){var v;let l=e.context,u=l.gl,c="fill-extrusion-pattern",d=r.paint.get(c),h=d.constantOr(1),f=r.getCrossfadeParameters(),p=r.paint.get("fill-extrusion-opacity"),m=d.constantOr(null),g=e.transform;for(let x of i){let _=t.getTile(x),y=_.getBucket(r);if(!y)continue;let w=(v=e.style.map.terrain)==null?void 0:v.getTerrainData(x),$=y.programConfigurations.get(r.id),S=e.useProgram(h?"fillExtrusionPattern":"fillExtrusion",$);h&&(e.context.activeTexture.set(u.TEXTURE0),_.imageAtlasTexture.bind(u.LINEAR,u.CLAMP_TO_EDGE),$.updatePaintBuffers(f));let E=g.getProjectionData({overscaledTileID:x,applyGlobeMatrix:!o,applyTerrainMatrix:!0});gz($,c,m,_,r);let C=lu(g,_,r.paint.get("fill-extrusion-translate"),r.paint.get("fill-extrusion-translate-anchor")),I=r.paint.get("fill-extrusion-vertical-gradient"),P=h?tAe(e,I,p,C,x,f,_):nz(e,I,p,C);S.draw(l,l.gl.TRIANGLES,n,a,s,Nt.backCCW,P,w,E,r.id,y.layoutVertexBuffer,y.indexBuffer,y.segments,r.paint,e.transform.zoom,$,e.style.map.terrain&&y.centroidVertexBuffer)}}function lDe(e,t,r,i,n){if(e.renderPass!=="offscreen"&&e.renderPass!=="translucent")return;let{isRenderingToTexture:a}=n,s=e.context,o=e.style.projection.useSubdivision,l=e.getDepthModeForSublayer(0,gt.ReadOnly),u=e.colorModeForRenderPass();if(e.renderPass==="offscreen")uDe(e,t,i,r,l,jt.disabled,u),s.viewport.set([0,0,e.width,e.height]);else if(e.renderPass==="translucent")if(o){let[c,d,h]=e.stencilConfigForOverlapTwoPass(i);Qb(e,t,r,h,c,l,u,!1,a),Qb(e,t,r,h,d,l,u,!0,a)}else{let[c,d]=e.getStencilConfigForOverlapAndUpdateStencilID(i);Qb(e,t,r,d,c,l,u,!1,a)}}function Qb(e,t,r,i,n,a,s,o,l){let u=e.style.projection,c=e.context,d=e.transform,h=c.gl,f=[`#define NUM_ILLUMINATION_SOURCES ${r.paint.get("hillshade-highlight-color").values.length}`],p=e.useProgram("hillshade",null,!1,f),m=!e.options.moving;for(let g of i){let v=t.getTile(g),x=v.fbo;if(!x)continue;let _=u.getMeshFromTileID(c,g.canonical,o,!0,"raster"),y=e.getTerrainDataForTile(g,l);c.activeTexture.set(h.TEXTURE0),h.bindTexture(h.TEXTURE_2D,x.colorAttachment.get());let w=d.getProjectionData({overscaledTileID:g,aligned:m,applyGlobeMatrix:!l,applyTerrainMatrix:!0});p.draw(c,h.TRIANGLES,a,n[g.overscaledZ],s,Nt.backCCW,bAe(e,v,r),y,w,r.id,_.vertexBuffer,_.indexBuffer,_.segments)}}function uDe(e,t,r,i,n,a,s){let o=e.context,l=o.gl,u=i.paint.get("resampling")==="nearest"?l.NEAREST:l.LINEAR;for(let c of r){let d=t.getTile(c),h=d.dem;if(!(h!=null&&h.data)||!d.needsHillshadePrepare)continue;let f=h.dim,p=h.stride,m=h.getPixels();if(o.activeTexture.set(l.TEXTURE1),o.pixelStoreUnpackPremultiplyAlpha.set(!1),d.demTexture||(d.demTexture=e.getTileTexture(p)),d.demTexture){let v=d.demTexture;v.update(m,{premultiply:!1}),v.bind(l.NEAREST,l.CLAMP_TO_EDGE)}else d.demTexture=new Hr(o,m,l.RGBA,{premultiply:!1}),d.demTexture.bind(l.NEAREST,l.CLAMP_TO_EDGE);o.activeTexture.set(l.TEXTURE0);let g=d.fbo;if(!g){let v=new Hr(o,{width:f,height:f,data:null},l.RGBA);v.bind(u,l.CLAMP_TO_EDGE),g=d.fbo=o.createFramebuffer(f,f,!0,!1),g.colorAttachment.set(v.texture)}o.bindFramebuffer.set(g.framebuffer),o.viewport.set([0,0,f,f]),e.useProgram("hillshadePrepare").draw(o,l.TRIANGLES,n,a,s,Nt.disabled,xAe(d.tileID,h),null,null,i.id,e.rasterBoundsBuffer,e.quadTriangleIndexBuffer,e.rasterBoundsSegments),d.needsHillshadePrepare=!1}}function cDe(e,t,r,i,n){if(e.renderPass!=="translucent"||!i.length)return;let{isRenderingToTexture:a}=n,s=e.style.projection.useSubdivision,o=e.getDepthModeForSublayer(0,gt.ReadOnly),l=e.colorModeForRenderPass();if(s){let[u,c,d]=e.stencilConfigForOverlapTwoPass(i);e2(e,t,r,d,u,o,l,!1,a),e2(e,t,r,d,c,o,l,!0,a)}else{let[u,c]=e.getStencilConfigForOverlapAndUpdateStencilID(i);e2(e,t,r,c,u,o,l,!1,a)}}let zE=0;function e2(e,t,r,i,n,a,s,o,l){let u=e.style.projection,c=e.context,d=e.transform,h=c.gl,f=e.useProgram("colorRelief"),p=!e.options.moving,m=r.paint.get("resampling")==="nearest"?h.NEAREST:h.LINEAR,g=!0,v=0;for(let x of i){let _=t.getTile(x),y=_.dem;if(g){zE||(zE=h.getParameter(h.MAX_TEXTURE_SIZE));let I=zE,{elevationTexture:P,colorTexture:T}=r.getColorRampTextures(c,I,y.getUnpackVector());c.activeTexture.set(h.TEXTURE1),P.bind(h.NEAREST,h.CLAMP_TO_EDGE),c.activeTexture.set(h.TEXTURE4),T.bind(h.LINEAR,h.CLAMP_TO_EDGE),g=!1,v=P.size[0]}if(!(y!=null&&y.data))continue;let w=y.stride,$=y.getPixels();if(c.activeTexture.set(h.TEXTURE0),c.pixelStoreUnpackPremultiplyAlpha.set(!1),_.demTexture||(_.demTexture=e.getTileTexture(w)),_.demTexture){let I=_.demTexture;I.update($,{premultiply:!1}),I.bind(m,h.CLAMP_TO_EDGE)}else _.demTexture=new Hr(c,$,h.RGBA,{premultiply:!1}),_.demTexture.bind(m,h.CLAMP_TO_EDGE);let S=u.getMeshFromTileID(c,x.canonical,o,!0,"raster"),E=e.getTerrainDataForTile(x,l),C=d.getProjectionData({overscaledTileID:x,aligned:p,applyGlobeMatrix:!l,applyTerrainMatrix:!0});f.draw(c,h.TRIANGLES,a,n[x.overscaledZ],s,Nt.backCCW,SAe(r,_.dem,v),E,C,r.id,S.vertexBuffer,S.indexBuffer,S.segments)}}const t2=[new de(0,0),new de(ye,0),new de(ye,ye),new de(0,ye)];function dDe(e,t,r,i,n){if(e.renderPass!=="translucent"||r.paint.get("raster-opacity")===0||!i.length)return;let{isRenderingToTexture:a}=n,s=t.getSource(),o=e.style.projection.useSubdivision;if(s instanceof xg)A0(e,t,r,i,null,!1,!1,s.tileCoords,s.flippedWindingOrder,a);else if(o){let[l,u,c]=e.stencilConfigForOverlapTwoPass(i);A0(e,t,r,c,l,!1,!0,t2,!1,a),A0(e,t,r,c,u,!0,!0,t2,!1,a)}else{let[l,u]=e.getStencilConfigForOverlapAndUpdateStencilID(i);A0(e,t,r,u,l,!1,!0,t2,!1,a)}}function A0(e,t,r,i,n,a,s,o,l=!1,u=!1){let c=i[i.length-1].overscaledZ,d=e.context,h=d.gl,f=e.useProgram("raster"),p=e.transform,m=e.style.projection,g=e.colorModeForRenderPass(),v=!e.options.moving,x=r.paint.get("raster-opacity"),_=r.paint.get("resampling")==="nearest"||r.paint.get("raster-resampling")==="nearest"?h.NEAREST:h.LINEAR,y=r.paint.get("raster-fade-duration"),w=!!e.style.map.terrain;for(let $ of i){let S=e.getDepthModeForSublayer($.overscaledZ-c,x===1?gt.ReadWrite:gt.ReadOnly,h.LESS),E=t.getTile($);d.activeTexture.set(h.TEXTURE0),E.texture.bind(_,h.CLAMP_TO_EDGE,h.LINEAR_MIPMAP_NEAREST),d.activeTexture.set(h.TEXTURE1);let{parentTile:C,parentScaleBy:I,parentTopLeft:P,fadeValues:T}=hDe(E,t,y,w);E.fadeOpacity=T.tileOpacity,C?(C.fadeOpacity=T.parentTileOpacity,C.texture.bind(_,h.CLAMP_TO_EDGE,h.LINEAR_MIPMAP_NEAREST)):E.texture.bind(_,h.CLAMP_TO_EDGE,h.LINEAR_MIPMAP_NEAREST),E.texture.useMipmap&&d.extTextureFilterAnisotropic&&e.transform.pitch>e.options.anisotropicFilterPitch&&h.texParameterf(h.TEXTURE_2D,d.extTextureFilterAnisotropic.TEXTURE_MAX_ANISOTROPY_EXT,d.extTextureFilterAnisotropicMax);let D=e.getTerrainDataForTile($,u),A=p.getProjectionData({overscaledTileID:$,aligned:v,applyGlobeMatrix:!u,applyTerrainMatrix:!0}),z=FAe(P,I,T.fadeMix,r,o),R=m.getMeshFromTileID(d,$.canonical,a,s,"raster"),O=n?n[$.overscaledZ]:jt.disabled;f.draw(d,h.TRIANGLES,S,O,g,l?Nt.frontCCW:Nt.backCCW,z,D,A,r.id,R.vertexBuffer,R.indexBuffer,R.segments)}}
vendor: 4,151 bytes, line 1544
1544function hDe(e,t,r,i){let n={parentTile:null,parentScaleBy:1,parentTopLeft:[0,0],fadeValues:{tileOpacity:1,parentTileOpacity:1,fadeMix:{opacity:1,mix:0}}};if(r===0||i)return n;if(e.fadingParentID){let a=t.getLoadedTile(e.fadingParentID);if(!a)return n;let s=2**(a.tileID.overscaledZ-e.tileID.overscaledZ);return{parentTile:a,parentScaleBy:s,parentTopLeft:[e.tileID.canonical.x*s%1,e.tileID.canonical.y*s%1],fadeValues:fDe(e,a,r)}}return e.selfFading?{parentTile:null,parentScaleBy:1,parentTopLeft:[0,0],fadeValues:pDe(e,r)}:n}function fDe(e,t,r){let i=tr(),n=(i-e.timeAdded)/r,a=(i-t.timeAdded)/r,s=e.fadingDirection===1,o=Ot(n,0,1),l=Ot(1-a,0,1),u=s?o:l;return{tileOpacity:u,parentTileOpacity:s?l:o,fadeMix:{opacity:1,mix:1-u}}}function pDe(e,t){let r=(tr()-e.timeAdded)/t,i=Ot(r,0,1);return{tileOpacity:i,fadeMix:{opacity:i,mix:0}}}function mDe(e,t,r,i,n){let a=r.paint.get("background-color"),s=r.paint.get("background-opacity");if(s===0)return;let{isRenderingToTexture:o}=n,l=e.context,u=l.gl,c=e.style.projection,d=e.transform,h=d.tileSize,f=r.paint.get("background-pattern");if(e.isPatternMissing(f))return;let p=!f&&a.a===1&&s===1&&e.opaquePassEnabledForLayer()?"opaque":"translucent";if(e.renderPass!==p)return;let m=jt.disabled,g=e.getDepthModeForSublayer(0,p==="opaque"?gt.ReadWrite:gt.ReadOnly),v=e.colorModeForRenderPass(),x=e.useProgram(f?"backgroundPattern":"background"),_=i||af(d,{tileSize:h,terrain:e.style.map.terrain});f&&(l.activeTexture.set(u.TEXTURE0),e.imageManager.bind(e.context));let y=r.getCrossfadeParameters();for(let w of _){let $=d.getProjectionData({overscaledTileID:w,applyGlobeMatrix:!o,applyTerrainMatrix:!0}),S=f?WAe(s,e,f,{tileID:w,tileSize:h},y):YAe(s,a),E=e.getTerrainDataForTile(w,o),C=c.getMeshFromTileID(l,w.canonical,!1,!0,"raster");x.draw(l,u.TRIANGLES,g,m,v,Nt.backCCW,S,E,$,r.id,C.vertexBuffer,C.indexBuffer,C.segments)}}const gDe=new at(1,0,0,1),_De=new at(0,1,0,1),yDe=new at(0,0,1,1),vDe=new at(1,0,1,1),bDe=new at(0,1,1,1);function xDe(e){let t=e.transform.padding;NE(e,e.transform.height-(t.top||0),3,gDe),NE(e,t.bottom||0,3,_De),BE(e,t.left||0,3,yDe),BE(e,e.transform.width-(t.right||0),3,vDe);let r=e.transform.centerPoint;wDe(e,r.x,e.transform.height-r.y,bDe)}function wDe(e,t,r,i){Yy(e,t-2/2,r-20/2,2,20,i),Yy(e,t-20/2,r-2/2,20,2,i)}function NE(e,t,r,i){Yy(e,0,t+r/2,e.transform.width,r,i)}function BE(e,t,r,i){Yy(e,t-r/2,0,r,e.transform.height,i)}function Yy(e,t,r,i,n,a){let s=e.context,o=s.gl;o.enable(o.SCISSOR_TEST),o.scissor(t*e.pixelRatio,r*e.pixelRatio,i*e.pixelRatio,n*e.pixelRatio),s.clear({color:a}),o.disable(o.SCISSOR_TEST)}function $De(e,t,r){for(let i of r)SDe(e,t,i)}function SDe(e,t,r){var v,x;let i=e.context,n=i.gl,a=e.useProgram("debug"),s=gt.disabled,o=jt.disabled,l=e.colorModeForRenderPass(),u="$debug",c=(v=e.style.map.terrain)==null?void 0:v.getTerrainData(r);i.activeTexture.set(n.TEXTURE0);let d=((x=t.getTileByID(r.key).latestRawTileData)==null?void 0:x.byteLength)||0,h=Math.floor(d/1024),f=t.getTile(r).tileSize,p=512/Math.min(f,512)*(r.overscaledZ/e.transform.zoom)*.5,m=r.canonical.toString();r.overscaledZ!==r.canonical.z&&(m+=` => ${r.overscaledZ}`),TDe(e,`${m} ${h}kB`);let g=e.transform.getProjectionData({overscaledTileID:r,applyGlobeMatrix:!0,applyTerrainMatrix:!0});a.draw(i,n.TRIANGLES,s,o,Mr.alphaBlended,Nt.disabled,ME(at.transparent,p),null,g,u,e.debugBuffer,e.quadTriangleIndexBuffer,e.debugSegments),a.draw(i,n.LINE_STRIP,s,o,l,Nt.disabled,ME(at.red),c,g,u,e.debugBuffer,e.tileBorderIndexBuffer,e.debugSegments)}function TDe(e,t){e.initDebugOverlayCanvas();let r=e.debugOverlayCanvas,i=e.context.gl,n=e.debugOverlayCanvas.getContext("2d");n.clearRect(0,0,r.width,r.height),n.shadowColor="white",n.shadowBlur=2,n.lineWidth=1.5,n.strokeStyle="white",n.textBaseline="top",n.font="bold 36px Open Sans, sans-serif",n.fillText(t,5,5),n.strokeText(t,5,5),e.debugOverlayTexture.update(r),e.debugOverlayTexture.bind(i.LINEAR,i.CLAMP_TO_EDGE)}function CDe(e,t){let r=null,i=Object.values(e._layers).flatMap(o=>o.source&&!o.isHidden(t)?[e.tileManagers[o.source]]:[]),n=i.filter(o=>o.getSource().type==="vector"),a=i.filter(o=>o.getSource().type!=="vector"),s=o=>
vendor: 4,623 bytes, lines 1544-1546
1544{(!r||r.getSource().maxzoom<o.getSource().maxzoom)&&(r=o)};for(let o of n)s(o);if(!r)for(let o of a)s(o);return r}function kDe(e,t,r,i){let{isRenderingGlobe:n}=i,a=e.context,s=r.implementation,o=e.style.projection,l=e.transform,u=l.getProjectionDataForCustomLayer(n),c={farZ:l.farZ,nearZ:l.nearZ,fov:l.fov*Math.PI/180,modelViewProjectionMatrix:l.modelViewProjectionMatrix,projectionMatrix:l.projectionMatrix,shaderData:{variantName:o.shaderVariantName,vertexShaderPrelude:`const float PI = 3.141592653589793; 1545uniform mat4 u_projection_matrix; 1546${o.shaderPreludeCode.vertexSource}`,define:o.shaderDefine},defaultProjectionData:u,getProjectionData:h=>l.getProjectionData({overscaledTileID:new Ri(h.tileID.canonical.z,h.tileID.wrap??0,h.tileID.canonical.z,h.tileID.canonical.x,h.tileID.canonical.y),aligned:h.aligned,applyGlobeMatrix:h.applyGlobeMatrix,applyTerrainMatrix:h.applyTerrainMatrix})},d=s.renderingMode?s.renderingMode:"2d";if(e.renderPass==="offscreen"){let h=s.prerender;h&&(e.setCustomLayerDefaults(),a.setColorMode(e.colorModeForRenderPass()),h.call(s,a.gl,c),a.setDirty(),e.setBaseState())}else if(e.renderPass==="translucent"){e.setCustomLayerDefaults(),a.setColorMode(e.colorModeForRenderPass()),a.setStencilMode(jt.disabled);let h=d==="3d"?e.getDepthModeFor3D():e.getDepthModeForSublayer(0,gt.ReadOnly);a.setDepthMode(h),s.render(a.gl,c),a.setDirty(),e.setBaseState(),a.bindFramebuffer.set(null)}}function EDe(e,t){let r=e.context,i=r.gl,n=e.transform,a=Mr.unblended,s=new gt(i.LEQUAL,gt.ReadWrite,[0,1]),o=t.tileManager.getRenderableTiles(),l=e.useProgram("terrainDepth");r.bindFramebuffer.set(t.getFramebuffer("depth").framebuffer),r.viewport.set([0,0,e.width/devicePixelRatio,e.height/devicePixelRatio]),r.clear({color:at.transparent,depth:1});for(let u of o){let c=t.getTerrainMesh(u.tileID),d=t.getTerrainData(u.tileID),h=n.getProjectionData({overscaledTileID:u.tileID,applyTerrainMatrix:!1,applyGlobeMatrix:!0}),f=YIe(t.getSkirtLength(n.zoom));l.draw(r,i.TRIANGLES,s,jt.disabled,a,Nt.backCCW,f,d,h,"terrain",c.vertexBuffer,c.indexBuffer,c.segments)}r.bindFramebuffer.set(null),r.viewport.set([0,0,e.width,e.height])}function PDe(e,t){let r=e.context,i=r.gl,n=e.transform,a=Mr.unblended,s=new gt(i.LEQUAL,gt.ReadWrite,[0,1]),o=t.getCoordsTexture(),l=t.tileManager.getRenderableTiles(),u=e.useProgram("terrainCoords");r.bindFramebuffer.set(t.getFramebuffer("coords").framebuffer),r.viewport.set([0,0,e.width/devicePixelRatio,e.height/devicePixelRatio]),r.clear({color:at.transparent,depth:1}),t.coordsIndex=[];for(let c of l){let d=t.getTerrainMesh(c.tileID),h=t.getTerrainData(c.tileID);r.activeTexture.set(i.TEXTURE0),i.bindTexture(i.TEXTURE_2D,o.texture);let f=WIe(255-t.coordsIndex.length,t.getSkirtLength(n.zoom)),p=n.getProjectionData({overscaledTileID:c.tileID,applyTerrainMatrix:!1,applyGlobeMatrix:!0});u.draw(r,i.TRIANGLES,s,jt.disabled,a,Nt.backCCW,f,h,p,"terrain",d.vertexBuffer,d.indexBuffer,d.segments),t.coordsIndex.push(c.tileID.key)}r.bindFramebuffer.set(null),r.viewport.set([0,0,e.width,e.height])}function MDe(e,t,r,i){let{isRenderingGlobe:n}=i,a=e.context,s=a.gl,o=e.transform,l=e.colorModeForRenderPass(),u=e.getDepthModeFor3D(),c=e.useProgram("terrain");a.bindFramebuffer.set(null),a.viewport.set([0,0,e.width,e.height]);for(let d of r){let h=t.getTerrainMesh(d.tileID),f=e.renderToTexture.getTexture(d),p=t.getTerrainData(d.tileID);a.activeTexture.set(s.TEXTURE0),s.bindTexture(s.TEXTURE_2D,f.texture);let m=t.getSkirtLength(o.zoom),g=o.calculateFogMatrix(d.tileID.toUnwrapped()),v=HIe(m,g,e.style.sky,o.pitch,n),x=o.getProjectionData({overscaledTileID:d.tileID,applyTerrainMatrix:!1,applyGlobeMatrix:!0});c.draw(a,s.TRIANGLES,u,jt.disabled,l,Nt.backCCW,v,p,x,"terrain",h.vertexBuffer,h.indexBuffer,h.segments)}}function yz(e,t){if(!t.mesh){let r=new Gl;r.emplaceBack(-1,-1),r.emplaceBack(1,-1),r.emplaceBack(1,1),r.emplaceBack(-1,1);let i=new go;i.emplaceBack(0,1,2),i.emplaceBack(0,2,3),t.mesh=new wg(e.createVertexBuffer(r,qu.members),e.createIndexBuffer(i),$r.simpleSegment(0,0,r.length,i.length))}return t.mesh}function IDe(e,t){let r=e.context,i=r.gl,n=JAe(t,e.transform,e.pixelRatio),a=new gt(i.LEQUAL,gt.ReadWrite,[0,1]),s=jt.disabled,o=e.colorModeForRenderPass(),l=e.useProgram("sky"),u=yz(r,t);l.draw(r,i.TRIANGLES,a,s,o,Nt.disabled,n,null,void 0,"sky",u.vertexBuffer,u.indexBuffer,u.segments)}function ADe(e,t){let r=e.getCartesianPosition();T$e(r,r);let i=Ms(new Float64Array(16));return e.properties.get("anchor")==="map"&&(Vl(i,i,t.rollInRadians),Eh(i,i,-t.pitchInRadians),Vl(i,i,t.bearingInRadians),Eh(i,i,t.center.lat*Math.PI/180),_R(i,i,-t.center.lng*Math.PI/180)
vendor: 5,827 bytes, line 1546
1546),C$e(r,r,i),r}function DDe(e,t,r){let i=e.context,n=i.gl,a=e.useProgram("atmosphere"),s=new gt(n.LEQUAL,gt.ReadOnly,[0,1]),o=e.transform,l=ADe(r,e.transform),u=o.getProjectionData({overscaledTileID:null,applyGlobeMatrix:!0,applyTerrainMatrix:!0}),c=t.properties.get("atmosphere-blend")*u.projectionTransition;if(c===0)return;let d=_v(o.worldSize,o.center.lat),h=o.inverseProjectionMatrix,f=new Float64Array(4);f[3]=1,_i(f,f,o.modelViewProjectionMatrix),f[0]/=f[3],f[1]/=f[3],f[2]/=f[3],f[3]=1,_i(f,f,h),f[0]/=f[3],f[1]/=f[3],f[2]/=f[3],f[3]=1;let p=[f[0],f[1],f[2]],m=KAe(l,c,p,d,h),g=yz(i,t);a.draw(i,n.TRIANGLES,s,jt.disabled,Mr.alphaBlended,Nt.disabled,m,null,null,"atmosphere",g.vertexBuffer,g.indexBuffer,g.segments)}const RDe={symbol:j9e,circle:Y9e,heatmap:W9e,line:aDe,fill:sDe,fillExtrusion:oDe,hillshade:lDe,colorRelief:cDe,raster:dDe,background:mDe,sky:IDe,atmosphere:DDe,custom:kDe,debug:$De,debugPadding:xDe,terrainDepth:EDe,terrainCoords:PDe};var pc,ODe=(pc=class{constructor(t,r){this.drawFunctions=RDe,this.context=new z9e(t),this.transform=r,this.layerOpacityFbo=null,this._tileTextures={},this._rttObjectRecyclePool=[],this._rttSharedFbo=null,this.terrainFacilitator={depthDirty:!0,coordsDirty:!1,matrix:Ms(new Float64Array(16)),renderTime:0},this.setup(),this.numSublayers=e3.maxOverzooming+e3.maxUnderzooming+1,this.depthEpsilon=1/2**16,this.crossTileSymbolIndex=new NF}resize(t,r,i){if(this.width=Math.floor(t*i),this.height=Math.floor(r*i),this.pixelRatio=i,this.context.viewport.set([0,0,this.width,this.height]),this.style)for(let n of this.style._order)this.style._layers[n].resize()}setup(){let t=this.context,r=new Gl;r.emplaceBack(0,0),r.emplaceBack(ye,0),r.emplaceBack(0,ye),r.emplaceBack(ye,ye),this.tileExtentBuffer=t.createVertexBuffer(r,qu.members),this.tileExtentSegments=$r.simpleSegment(0,0,4,2);let i=new Gl;i.emplaceBack(0,0),i.emplaceBack(ye,0),i.emplaceBack(0,ye),i.emplaceBack(ye,ye),this.debugBuffer=t.createVertexBuffer(i,qu.members),this.debugSegments=$r.simpleSegment(0,0,4,5);let n=new FTe;n.emplaceBack(0,0,0,0),n.emplaceBack(ye,0,ye,0),n.emplaceBack(0,ye,0,ye),n.emplaceBack(ye,ye,ye,ye),this.rasterBoundsBuffer=t.createVertexBuffer(n,BIe.members),this.rasterBoundsSegments=$r.simpleSegment(0,0,4,2);let a=new Gl;a.emplaceBack(0,0),a.emplaceBack(ye,0),a.emplaceBack(0,ye),a.emplaceBack(ye,ye),this.rasterBoundsBufferPosOnly=t.createVertexBuffer(a,qu.members),this.rasterBoundsSegmentsPosOnly=$r.simpleSegment(0,0,4,5);let s=new Gl;s.emplaceBack(0,0),s.emplaceBack(1,0),s.emplaceBack(0,1),s.emplaceBack(1,1),this.viewportBuffer=t.createVertexBuffer(s,qu.members),this.viewportSegments=$r.simpleSegment(0,0,4,2);let o=new ZTe;o.emplaceBack(0),o.emplaceBack(1),o.emplaceBack(3),o.emplaceBack(2),o.emplaceBack(0),this.tileBorderIndexBuffer=t.createIndexBuffer(o);let l=new go;l.emplaceBack(1,0,2),l.emplaceBack(1,2,3),this.quadTriangleIndexBuffer=t.createIndexBuffer(l);let u=this.context.gl;this.stencilClearMode=new jt({func:u.ALWAYS,mask:0},0,255,u.ZERO,u.ZERO,u.ZERO),this.tileExtentMesh=new wg(this.tileExtentBuffer,this.quadTriangleIndexBuffer,this.tileExtentSegments)}clearStencil(){let t=this.context,r=t.gl;this.nextStencilID=1,this.currentStencilSource=void 0;let i=_u();qs(i,0,this.width,this.height,0,0,1),Li(i,i,[r.drawingBufferWidth,r.drawingBufferHeight,0]);let n={mainMatrix:i,tileMercatorCoords:[0,0,1,1],clippingPlane:[0,0,0,0],projectionTransition:0,fallbackMatrix:i,clipAntimeridian:!1};this.useProgram("clippingMask",null,!0).draw(t,r.TRIANGLES,gt.disabled,this.stencilClearMode,Mr.disabled,Nt.disabled,null,null,n,"$clipping",this.viewportBuffer,this.quadTriangleIndexBuffer,this.viewportSegments)}renderTileClippingMasks(t,r,i){if(this.currentStencilSource===t.source||!t.isTileClipped()||!(r!=null&&r.length))return;this.currentStencilSource=t.source,this.nextStencilID+r.length>256&&this.clearStencil();let n=this.context;n.setColorMode(Mr.disabled),n.setDepthMode(gt.disabled);let a={};for(let s of r)a[s.key]=this.nextStencilID++;this.style.projection.useSubdivision&&this._renderTileMasks(a,r,i,!0),this._renderTileMasks(a,r,i,!1),this._tileClippingMaskIDs=a}_renderTileMasks(t,r,i,n){let a=this.context,s=a.gl,o=this.style.projection,l=this.transform,u=this.useProgram("clippingMask");for(let c of r){let d=t[c.key],h=this.getTerrainDataForTile(c,i),f=o.getMeshFromTileID(this.context,c.canonical,n,!0,"stencil"),p=l.getProjectionData({overscaledTileID:c,applyGlobeMatrix:!i,applyTerrainMatrix:!0});u.draw(a,s.TRIANGLES,gt.disabled,new jt({func:s.ALWAYS,mask:0},d,255,s.KEEP,s.KEEP,s.REPLACE),Mr.disabled,i?Nt.disabled:Nt.backCCW,null,h,p,"$clipping",f.vertexBuffer,f.indexBuffer,f.segments)}}getTerrainDataForTile(t,r){var i,n;return r&&((i=this.style.projection)==null?void 0:i.name)==="mercator"?null:((n=this.style.map.terrain)==null?void 0:n.getTerrainData(t))||null}_renderTilesDepthBuffer(){var l;let t=this.context,r=t.gl,i=this.style.projection,n=this.transform,a=this.useProgram("depth"),s=this.getDepthModeFor3D(),o=af(n,{tileSize:n.tileSize});for(let u of o){let c=(l=this.style.map.terrain)==null?void 0:l.getTerrainData(u),d=i.getMeshFromTileID(this.context,u.canonical,!0,!0,"raster"),h=n.getProjectionData({overscaledTileID:u,applyGlobeMatrix:!0,applyTerrainMatrix:!0});a.draw(t,r.TRIANGLES,s,jt.disabled,Mr.disabled,Nt.backCCW,null,c,h,"$clipping",d.vertexBuffer,d.indexBuffer,d.segments)}}stencilModeFor3D(){this.currentStencilSource=void 0,this.nextStencilID+1>256&&this.clearStencil();let t=this.nextStencilID++,r=this.context.gl;return new jt({func:r.NOTEQUAL,mask:255},t,255,r.KEEP,r.KEEP,r.REPLACE)}stencilModeForClipping(t){let r=this.context.gl;return new jt({func:r.EQUAL,mask:255},this._tileClippingMaskIDs[t.key],0,r.KEEP,r.KEEP,r.REPLACE)}getStencilConfigForOverlapAndUpdateStencilID(t){let r=this.context.gl,i=t.sort((s,o)=>
1546o.overscaledZ-s.overscaledZ),n=i[i.length-1].overscaledZ,a=i[0].overscaledZ-n+1;if(a>1){this.currentStencilSource=void 0,this.nextStencilID+a>256&&this.clearStencil();let s={};for(let o=0;o<a;o++)s[o+n]=new jt({func:r.GEQUAL,mask:255},o+this.nextStencilID,255,r.KEEP,r.KEEP,r.REPLACE);return this.nextStencilID+=a,[s,i]}return[{[n]:jt.disabled},i]}stencilConfigForOverlapTwoPass(t){let r=this.context.gl,i=t.sort((s,o)=>o.overscaledZ-s.overscaledZ),n=i[i.length-1].overscaledZ,a=i[0].overscaledZ-n+1;if(this.clearStencil(),a>1){let s={},o={};for(let l=0;l<a;l++)s[l+n]=new jt({func:r.GREATER,mask:255},a+1+l,255,r.KEEP,r.KEEP,r.REPLACE),o[l+n]=new jt({func:r.GREATER,mask:255},1+l,255,r.KEEP,r.KEEP,r.REPLACE);return this.nextStencilID=a*2+1,[s,o,i]}return this.nextStencilID=3,[{[n]:new jt({func:r.GREATER,mask:255},2,255,r.KEEP,r.KEEP,r.REPLACE)},{[n]:new jt({func:r.GREATER,mask:255},1,255,r.KEEP,r.KEEP,r.REPLACE)},i]}colorModeForRenderPass(){let t=this.context.gl;if(this._showOverdrawInspector){let r=.125;return new Mr([t.CONSTANT_COLOR,t.ONE],new at(r,r,r,0),[!0,!0,!0,!0])}return this.renderPass==="opaque"?Mr.unblended:Mr.alphaBlended}getDepthModeForSublayer(t,r,i){if(!this.opaquePassEnabledForLayer())return gt.disabled;let n=1-((1+this.currentLayer)*this.numSublayers+t)*this.depthEpsilon;return new gt(i||this.context.gl.LEQUAL,r,[n,n])}getDepthModeFor3D(){return new gt(this.context.gl.LEQUAL,gt.ReadWrite,this.depthRangeFor3D)}opaquePassEnabledForLayer(){return this.currentLayer<this.opaquePassCutoff}render(t,r){var c,d;this.style=t,this.options=r,this.lineAtlas=t.lineAtlas,this.imageManager=t.imageManager,this.glyphManager=t.glyphManager,this.symbolFadeChange=t.placement.symbolFadeChange(tr()),this.imageManager.beginFrame();let i=this.style._order,n=this.style.tileManagers,a={},s={},o={},l={isRenderingToTexture:!1,isRenderingGlobe:((c=t.projection)==null?void 0:c.transitionState)>0};for(let h in n){let f=n[h];f.used&&f.prepare(this.context),a[h]=f.getVisibleCoordinates(!1),s[h]=a[h].slice().reverse(),o[h]=f.getVisibleCoordinates(!0).reverse()}this.opaquePassCutoff=1/0;for(let h=0;h<i.length;h++){let f=i[h];if(this.style._layers[f].is3D()){this.opaquePassCutoff=h;break}}this.maybeDrawDepth(!1),this.renderToTexture&&(this.renderToTexture.prepareForRender(this.style,this.transform.zoom),this.opaquePassCutoff=0),this.renderPass="offscreen";for(let h of i){let f=this.style._layers[h];if(!f.hasOffscreenPass()||f.isHidden(this.transform.zoom))continue;let p=s[f.source];f.type!=="custom"&&!p.length||this.renderLayer(this,n[f.source],f,p,l)}if(this.context.viewport.set([0,0,this.width,this.height]),this.context.bindFramebuffer.set(null),this.context.clear({color:r.showOverdrawInspector?at.black:at.transparent,depth:1}),this.clearStencil(),this.style.sky&&this.drawFunctions.sky(this,this.style.sky),this._showOverdrawInspector=r.showOverdrawInspector,this.depthRangeFor3D=[0,1-(t._order.length+2)*this.numSublayers*this.depthEpsilon],!this.renderToTexture)for(this.renderPass="opaque",this.currentLayer=i.length-1;this.currentLayer>=0;this.currentLayer--){let h=this.style._layers[i[this.currentLayer]],f=n[h.source],p=a[h.source];this.renderTileClippingMasks(h,p,!1),this.renderLayer(this,f,h,p,l)}this.renderPass="translucent";let u=!1;for(this.currentLayer=0;this.currentLayer<i.length;this.currentLayer++){let h=this.style._layers[i[this.currentLayer]],f=n[h.source];if((d=this.renderToTexture)!=null&&d.renderLayer(h,l))continue;!this.opaquePassEnabledForLayer()&&!u&&(u=!0,l.isRenderingGlobe&&!this.style.map.terrain&&this._renderTilesDepthBuffer());let p=(h.type==="symbol"?o:s)[h.source];this.renderTileClippingMasks(h,a[h.source],!!this.renderToTexture),this.renderLayer(this,f,h,p,l)}if(l.isRenderingGlobe&&this.drawFunctions.atmosphere(this,this.style.sky,this.style.light),this.options.showTileBoundaries){let h=CDe(this.style,this.transform.zoom);h&&this.drawFunctions.debug(this,h,h.getVisibleCoordinates())}this.options.showPadding&&this.drawFunctions.debugPadding(this),this.context.setDefault()}maybeDrawDepth(t){var a,s;if(!((s=(a=this.style)==null?void 0:a.map)!=null&&s.terrain))return;let r=this.terrainFacilitator.matrix,i=this.transform.modelViewProjectionMatrix,n=this.terrainFacilitator.depthDirty;n||(n=t?!x$e(r,i):!w$e(r,i)),n||(n=this.style.map.terrain.tileManager.anyTilesAfterTime(this.terrainFacilitator.renderTime)),n&&(_$e(r,i),this.terrainFacilitator.renderTime=tr(),this.terrainFacilitator.depthDirty=!1,this.terrainFacilitator.coordsDirty=!0,this.drawFunctions.terrainDepth(this,this.style.map.terrain))}maybeDrawCoords(){var t,r;!((r=(t=this.style)==null?void 0:t.map)!=null&&r.terrain)||!this.terrainFacilitator.coordsDirty||(this.terrainFacilitator.coordsDirty=!1,this.drawFunctions.terrainCoords(this,this.style.map.terrain))}renderLayer(t,r,i,n,a){if(i.isHidden(this.transform.zoom)||i.type!=="background"&&i.type!=="custom"&&!(n||[]).length)return;this.id=i.id;let s=this.drawFunctions;XL(i)?s.symbol(t,r,i,n,this.style.placement.variableOffsets,a):T6e(i)?s.circle(t,r,i,n,a):M6e(i)?s.heatmap(t,r,i,n,a):ake(i)?s.line(t,r,i,n,a):xCe(i)?s.fill(t,r,i,n,a):UCe(i)?s.fillExtrusion(t,r,i,n,a):O6e(i)?s.hillshade(t,r,i,n,a):j6e(i)?s.colorRelief(t,r,i,n,a):sw(i)?s.raster(t,r,i,n,a):Oke(i)?s.background(t,r,i,n,a):zke(i)&&s.custom(t,r,i,a)}saveTileTexture(t){let r=this._tileTextures[t.size[0]];
vendor: 4,336 bytes, line 1546
1546r?r.length<pc.MAX_TEXTURE_POOL_SIZE_PER_BUCKET?r.push(t):t.destroy():this._tileTextures[t.size[0]]=[t]}getTileTexture(t){let r=this._tileTextures[t];return r&&r.length>0?r.pop():null}acquireRTT(t){let r=this.context.gl,i=this._rttObjectRecyclePool.pop();if(i)return i.size!==t&&(r.bindTexture(r.TEXTURE_2D,i.texture.texture),r.texImage2D(r.TEXTURE_2D,0,r.RGBA,t,t,0,r.RGBA,r.UNSIGNED_BYTE,null),i.texture.size=[t,t],i.size=t),i;let n=new Hr(this.context,{width:t,height:t,data:null},r.RGBA);return n.bind(r.LINEAR,r.CLAMP_TO_EDGE),this.context.extTextureFilterAnisotropic&&r.texParameterf(r.TEXTURE_2D,this.context.extTextureFilterAnisotropic.TEXTURE_MAX_ANISOTROPY_EXT,this.context.extTextureFilterAnisotropicMax),{texture:n,size:t}}bindRTT(t){let r=this.context.gl,i=t.size;if(!this._rttSharedFbo){let n=this.context.createFramebuffer(i,i,!0,!0),a=this.context.createRenderbuffer(r.DEPTH_STENCIL,i,i);n.depthAttachment.set(a),this._rttSharedFbo={fbo:n,depthRenderbuffer:a,size:i}}this._rttSharedFbo.size!==i&&(this.context.bindRenderbuffer.set(this._rttSharedFbo.depthRenderbuffer),r.renderbufferStorage(r.RENDERBUFFER,r.DEPTH_STENCIL,i,i),this.context.bindRenderbuffer.set(null),this._rttSharedFbo.fbo.width=i,this._rttSharedFbo.fbo.height=i,this._rttSharedFbo.size=i),this._rttSharedFbo.fbo.colorAttachment.set(t.texture.texture),this.context.bindFramebuffer.set(this._rttSharedFbo.fbo.framebuffer)}releaseRTT(t){this._rttObjectRecyclePool.push(t)}isPatternMissing(t){if(!t)return!1;if(!t.from||!t.to)return!0;let r=this.imageManager.getPattern(t.from.toString()),i=this.imageManager.getPattern(t.to.toString());return!r||!i}useProgram(t,r,i=!1,n=[]){var m;this.cache||(this.cache={});let a=!!this.style.map.terrain,s=this.style.projection,o=i?eo.projectionMercator:s.shaderPreludeCode,l=i?BF:s.shaderDefine,u=`/${i?jF:s.shaderVariantName}`,c=r?r.cacheKey:"",d=this._showOverdrawInspector?"/overdraw":"",h=a?"/terrain":"",f=n?`/${n.join("/")}`:"",p=t+c+u+d+h+f;return(m=this.cache)[p]||(m[p]=new XIe(this.context,eo[t],r,QAe[t],this._showOverdrawInspector,a,o,l,n)),this.cache[p]}setCustomLayerDefaults(){this.context.unbindVAO(),this.context.cullFace.setDefault(),this.context.activeTexture.setDefault(),this.context.pixelStoreUnpack.setDefault(),this.context.pixelStoreUnpackPremultiplyAlpha.setDefault(),this.context.pixelStoreUnpackFlipY.setDefault()}setBaseState(){let t=this.context.gl;this.context.cullFace.set(!1),this.context.viewport.set([0,0,this.width,this.height]),this.context.blendEquation.set(t.FUNC_ADD)}initDebugOverlayCanvas(){if(this.debugOverlayCanvas==null){this.debugOverlayCanvas=document.createElement("canvas"),this.debugOverlayCanvas.width=512,this.debugOverlayCanvas.height=512;let t=this.context.gl;this.debugOverlayTexture=new Hr(this.context,this.debugOverlayCanvas,t.RGBA)}}destroy(){var t,r,i;if(this._tileTextures){for(let n in this._tileTextures){let a=this._tileTextures[n];if(a)for(let s of a)s.destroy()}this._tileTextures={}}for(let n of this._rttObjectRecyclePool)n.texture.destroy();if(this._rttObjectRecyclePool=[],this._rttSharedFbo){this._rttSharedFbo.fbo.colorAttachment.set(null),this._rttSharedFbo.fbo.depthAttachment.set(null);let n=this.context.gl;n.deleteRenderbuffer(this._rttSharedFbo.depthRenderbuffer),n.deleteFramebuffer(this._rttSharedFbo.fbo.framebuffer),this._rttSharedFbo=null}if((t=this.layerOpacityFbo)==null||t.destroy(),this.layerOpacityFbo=null,this.tileExtentBuffer&&this.tileExtentBuffer.destroy(),this.debugBuffer&&this.debugBuffer.destroy(),this.rasterBoundsBuffer&&this.rasterBoundsBuffer.destroy(),this.rasterBoundsBufferPosOnly&&this.rasterBoundsBufferPosOnly.destroy(),this.viewportBuffer&&this.viewportBuffer.destroy(),this.tileBorderIndexBuffer&&this.tileBorderIndexBuffer.destroy(),this.quadTriangleIndexBuffer&&this.quadTriangleIndexBuffer.destroy(),this.tileExtentMesh&&((r=this.tileExtentMesh.vertexBuffer)==null||r.destroy()),this.tileExtentMesh&&((i=this.tileExtentMesh.indexBuffer)==null||i.destroy()),this.debugOverlayTexture&&this.debugOverlayTexture.destroy(),this.cache){for(let n in this.cache){let a=this.cache[n];a!=null&&a.program&&this.context.gl.deleteProgram(a.program)}this.cache={}}this.context&&this.context.setDefault()}overLimit(){let{drawingBufferWidth:t,drawingBufferHeight:r}=this.context.gl;return this.width!==t||this.height!==r}}
1546,pc.MAX_TEXTURE_POOL_SIZE_PER_BUCKET=50,pc),LDe=class extends Error{constructor(e,t){super("WebGL2 is required to display this map. We are sorry, but it seems that your browser does not support WebGL2, a technology for rendering 3D graphics on the web. Read more on https://wiki.openstreetmap.org/wiki/This_map_requires_WebGL"),this.name="GPUInitializationError",this.requestedAttributes=e,this.statusMessage=(t==null?void 0:t.statusMessage)??null}};function vz(e,t){let r=!1,i=null,n,a=()=>{i=null,r&&(r=(e(...n),i=setTimeout(a,t),!1))};return(...s)=>(r=!0,n=s,i||a(),i)}var FDe=class{constructor(e){this._getHashParams=()=>new URLSearchParams(window.location.hash.replace("#","")),this._getCurrentHash=()=>{let t=this._getHashParams();return this._hashName?(t.get(this._hashName)||"").split("/"):([...t.keys()][0]??"").split("/")},this._onHashChange=()=>{let t=this._getCurrentHash();if(!this._isValidHash(t))return!1;let r=this._map.dragRotate.isEnabled()&&this._map.touchZoomRotate.isEnabled()?+(t[3]||0):this._map.getBearing();return this._map.jumpTo({center:[+t[2],+t[1]],zoom:+t[0],bearing:r,pitch:+(t[4]||0)}),!0},this._updateHashUnthrottled=()=>{let t=window.location.href.replace(/(#.*)?$/,this.getHashString());window.history.replaceState(window.history.state,null,t)},this._removeHash=()=>{let t=this._getHashParams();if(this._hashName)t.delete(this._hashName);else{let a=Array.from(t.keys());a.length>0&&t.delete(a[0])}let r=decodeURIComponent(t.toString()).replace(/=&/g,"&").replace(/=$/g,""),i=r?`#${r}`:"",n=window.location.href.replace(/(#.+)?$/,i);n=n.replace("&&","&"),window.history.replaceState(window.history.state,null,n)},this._updateHash=vz(this._updateHashUnthrottled,3e4/100),this._hashName=e&&encodeURIComponent(e)}addTo(e){return this._map=e,addEventListener("hashchange",this._onHashChange,!1),this._map.on("moveend",this._updateHash),this}remove(){return removeEventListener("hashchange",this._onHashChange,!1),this._map.off("moveend",this._updateHash),clearTimeout(this._updateHash()),this._removeHash(),delete this._map,this}getHashString(e){let t=this._map.getCenter(),r=Math.round(this._map.getZoom()*100)/100,i=10**Math.ceil((r*Math.LN2+Math.log(512/360/.5))/Math.LN10),n=Math.round(t.lng*i)/i,a=Math.round(t.lat*i)/i,s=this._map.getBearing(),o=this._map.getPitch(),l="";if(l+=e?`/${n}/${a}/${r}`:`${r}/${a}/${n}`,(s||o)&&(l+=`/${Math.round(s*10)/10}`),o&&(l+=`/${Math.round(o)}`),this._hashName){let u=this._getHashParams();return u.set(this._hashName,l),`#${decodeURIComponent(u.toString()).replace(/=&/g,"&").replace(/=$/g,"")}`}return`#${l}`}_isValidHash(e){if(e.length<3||e.some(n=>
vendor: 20,411 bytes, line 1546
1546isNaN(+n)))return!1;try{new rt(+e[2],+e[1])}catch{return!1}let t=+e[0],r=+(e[3]||0),i=+(e[4]||0);return t>=this._map.getMinZoom()&&t<=this._map.getMaxZoom()&&r>=-180&&r<=180&&i>=this._map.getMinPitch()&&i<=this._map.getMaxPitch()}};const $g={linearity:.3,easing:I$(0,0,.3,1)},zDe=Ne({deceleration:2500,maxSpeed:1400},$g),NDe=Ne({deceleration:20,maxSpeed:1400},$g),BDe=Ne({deceleration:1e3,maxSpeed:360},$g),jDe=Ne({deceleration:1e3,maxSpeed:90},$g),UDe=Ne({deceleration:1e3,maxSpeed:360},$g);var VDe=class{constructor(e){this._map=e,this.clear()}clear(){this._inertiaBuffer=[]}record(e){this._drainInertiaBuffer(),this._inertiaBuffer.push({time:tr(),settings:e})}_drainInertiaBuffer(){let e=this._inertiaBuffer,t=tr();for(;e.length>0&&t-e[0].time>160;)e.shift()}_onMoveEnd(e){if(this._drainInertiaBuffer(),this._inertiaBuffer.length<2)return;let t={zoom:0,bearing:0,pitch:0,roll:0,pan:new de(0,0),pinchAround:void 0,around:void 0};for(let{settings:n}of this._inertiaBuffer)t.zoom+=n.zoomDelta||0,t.bearing+=n.bearingDelta||0,t.pitch+=n.pitchDelta||0,t.roll+=n.rollDelta||0,n.panDelta&&t.pan._add(n.panDelta),n.around&&(t.around=n.around),n.pinchAround&&(t.pinchAround=n.pinchAround);let r=this._inertiaBuffer[this._inertiaBuffer.length-1].time-this._inertiaBuffer[0].time,i={};if(t.pan.mag()){let n=Ff(t.pan.mag(),r,Ne({},zDe,e||{})),a=t.pan.mult(n.amount/t.pan.mag()),s=this._map._camera.cameraHelper.handlePanInertia(a,this._map._camera.transform);i.center=s.easingCenter,i.offset=s.easingOffset,Lf(i,n)}if(t.zoom){let n=Ff(t.zoom,r,NDe);i.zoom=da(this._map.getZoom()+n.amount,this._map.getZoomSnap(),n.amount),Lf(i,n)}if(t.bearing){let n=Ff(t.bearing,r,BDe);i.bearing=this._map.getBearing()+Ot(n.amount,-179,179),Lf(i,n)}if(t.pitch){let n=Ff(t.pitch,r,jDe);i.pitch=this._map.getPitch()+n.amount,Lf(i,n)}if(t.roll){let n=Ff(t.roll,r,UDe);i.roll=this._map.getRoll()+Ot(n.amount,-179,179),Lf(i,n)}if(i.zoom||i.bearing){let n=t.pinchAround===void 0?t.around:t.pinchAround;i.around=n?this._map.unproject(n):this._map.getCenter()}return this.clear(),Ne(i,{noMoveStart:!0})}};function Lf(e,t){(!e.duration||e.duration<t.duration)&&(e.duration=t.duration,e.easing=t.easing)}function Ff(e,t,r){let{maxSpeed:i,linearity:n,deceleration:a}=r,s=Ot(e*n/(t/1e3),-i,i),o=Math.abs(s)/(a*n);return{easing:r.easing,duration:o*1e3,amount:o/2*s}}var qDe=class{constructor(e,t){this._map=e,this._clickTolerance=t.clickTolerance}reset(){delete this._mousedownPos}wheel(e){return this._firePreventable(new IPe(this._map,e))}mousedown(e,t){return this._mousedownPos=t,this._firePreventable(new Va(e.type,this._map,e))}mouseup(e){this._map.fire(new Va(e.type,this._map,e))}click(e,t){this._mousedownPos&&this._mousedownPos.dist(t)>=this._clickTolerance||this._map.fire(new Va(e.type,this._map,e))}dblclick(e){return this._firePreventable(new Va(e.type,this._map,e))}mouseover(e){this._map.fire(new Va(e.type,this._map,e))}mouseout(e){this._map.fire(new Va(e.type,this._map,e))}touchstart(e){return this._firePreventable(new T0(e.type,this._map,e))}touchmove(e){this._map.fire(new T0(e.type,this._map,e))}touchend(e){this._map.fire(new T0(e.type,this._map,e))}touchcancel(e){this._map.fire(new T0(e.type,this._map,e))}_firePreventable(e){if(this._map.fire(e),e.defaultPrevented)return{}}isEnabled(){return!0}isActive(){return!1}enable(){}disable(){}},GDe=class{constructor(e){this._map=e}reset(){this._delayContextMenu=!1,this._ignoreContextMenu=!0,delete this._contextMenuEvent}mousemove(e){this._map.fire(new Va(e.type,this._map,e))}mousedown(){this._delayContextMenu=!0,this._ignoreContextMenu=!1}mouseup(){this._delayContextMenu=!1,this._contextMenuEvent&&(this._map.fire(new Va("contextmenu",this._map,this._contextMenuEvent)),delete this._contextMenuEvent)}contextmenu(e){this._delayContextMenu?this._contextMenuEvent=e:this._ignoreContextMenu||this._map.fire(new Va(e.type,this._map,e)),this._map.listens("contextmenu")&&e.preventDefault()}isEnabled(){return!0}isActive(){return!1}enable(){}disable(){}},HDe=class{constructor(e,t,r){this._map=e,this._tr=r,this._el=e.getCanvasContainer(),this._container=e.getContainer(),this._clickTolerance=t.clickTolerance||1,t.boxZoom&&typeof t.boxZoom=="object"&&(this._boxZoomEnd=t.boxZoom.boxZoomEnd)}isEnabled(){return!!this._enabled}isActive(){return!!this._active}enable(){this.isEnabled()||(this._enabled=!0)}disable(){this.isEnabled()&&(this._enabled=!1)}mousedown(e,t){this.isEnabled()&&e.shiftKey&&e.button===0&&(Ut.disableDrag(),this._startPos=this._lastPos=t,this._active=!0)}mousemoveWindow(e,t){if(!this._active)return;let r=t;if(this._lastPos.equals(r)||!this._box&&r.dist(this._startPos)<this._clickTolerance)return;let i=this._startPos;this._lastPos=r,this._box||(this._box=Ut.create("div","maplibregl-boxzoom",this._container),this._container.classList.add("maplibregl-crosshair"),this._fireEvent("boxzoomstart",e));let n=Math.min(i.x,r.x),a=Math.max(i.x,r.x),s=Math.min(i.y,r.y),o=Math.max(i.y,r.y);this._box.style.transform=`translate(${n}px,${s}px)`,this._box.style.width=`${a-n}px`,this._box.style.height=`${o-s}px`}mouseupWindow(e,t){if(!this._active||e.button!==0)return;let r=this._startPos,i=t;if(this.reset(),Ut.suppressClick(),r.x===i.x&&r.y===i.y)this._fireEvent("boxzoomcancel",e);else{if(this._map.fire(new Z8("boxzoomend",{originalEvent:e})),this._boxZoomEnd){this._boxZoomEnd(this._map,r,i,e);return}return{cameraAnimation:n=>n.fitScreenCoordinates(r,i,this._tr.bearing,{linear:!0})}}}keydown(e){this._active&&e.keyCode===27&&(this.reset(),this._fireEvent("boxzoomcancel",e))}reset(){this._active=!1,this._container.classList.remove("maplibregl-crosshair"),this._box&&(this._box=(this._box.remove(),null)),Ut.enableDrag(),delete this._startPos,delete this._lastPos}_fireEvent(e,t){return this._map.fire(new Z8(e,{originalEvent:t}))}};function s3(e,t){if(e.length!==t.length)throw Error(`The number of touches and points are not equal - touches ${e.length}, points ${t.length}`);let r={};for(let i=0;i<e.length;i++)r[e[i].identifier]=t[i];return r}function YDe(e){let t=new de(0,0);for(let r of e)t._add(r);return t.div(e.length)}var WDe=class{constructor(e){this.reset(),this.numTouches=e.numTouches}reset(){delete this.centroid,delete this.startTime,delete this.touches,this.aborted=!1}touchstart(e,t,r){(this.centroid||r.length>this.numTouches)&&(this.aborted=!0),!this.aborted&&(this.startTime===void 0&&(this.startTime=e.timeStamp),r.length===this.numTouches&&(this.centroid=YDe(t),this.touches=s3(r,t)))}touchmove(e,t,r){if(this.aborted||!this.centroid)return;let i=s3(r,t);for(let n in this.touches){let a=this.touches[n],s=i[n];(!s||s.dist(a)>30)&&(this.aborted=!0)}}touchend(e,t,r){if((!this.centroid||e.timeStamp-this.startTime>500)&&(this.aborted=!0),r.length===0){let i=!this.aborted&&this.centroid;if(this.reset(),i)return i}}},o3=class{constructor(e){this.singleTap=new WDe(e),this.numTaps=e.numTaps,this.reset()}reset(){this.lastTime=1/0,delete this.lastTap,this.count=0,this.singleTap.reset()}touchstart(e,t,r){this.singleTap.touchstart(e,t,r)}touchmove(e,t,r){this.singleTap.touchmove(e,t,r)}touchend(e,t,r){let i=this.singleTap.touchend(e,t,r);if(i){let n=e.timeStamp-this.lastTime<500,a=!this.lastTap||this.lastTap.dist(i)<30;if((!n||!a)&&this.reset(),this.count++,this.lastTime=e.timeStamp,this.lastTap=i,this.count===this.numTaps)return this.reset(),i}}},ZDe=class{constructor(e,t){this._tr=t,this._zoomIn=new o3({numTouches:1,numTaps:2}),this._zoomOut=new o3({numTouches:2,numTaps:1}),this.reset()}reset(){this._active=!1,this._zoomIn.reset(),this._zoomOut.reset()}touchstart(e,t,r){this._zoomIn.touchstart(e,t,r),this._zoomOut.touchstart(e,t,r)}touchmove(e,t,r){this._zoomIn.touchmove(e,t,r),this._zoomOut.touchmove(e,t,r)}touchend(e,t,r){let i=this._zoomIn.touchend(e,t,r),n=this._zoomOut.touchend(e,t,r),a=this._tr;if(i)return this._active=!0,e.preventDefault(),setTimeout(()=>this.reset(),0),{cameraAnimation:s=>s.easeTo({duration:300,zoom:da(a.zoom+1,s.getZoomSnap()),around:a.unproject(i)},{originalEvent:e})};if(n)return this._active=!0,e.preventDefault(),setTimeout(()=>this.reset(),0),{cameraAnimation:s=>s.easeTo({duration:300,zoom:da(a.zoom-1,s.getZoomSnap()),around:a.unproject(n)},{originalEvent:e})}}touchcancel(){this.reset()}enable(){this._enabled=!0}disable(){this._enabled=!1,this.reset()}isEnabled(){return this._enabled}isActive(){return this._active}},Sg=class{constructor(e){this._enabled=!!e.enable,this._moveStateManager=e.moveStateManager,this._clickTolerance=e.clickTolerance||1,this._moveFunction=e.move,this._activateOnStart=!!e.activateOnStart,e.assignEvents(this),this.reset()}reset(e){this._active=!1,this._moved=!1,delete this._lastPoint,this._moveStateManager.endMove(e)}_move(...e){let t=this._moveFunction(...e);if(t.bearingDelta||t.pitchDelta||t.rollDelta||t.around||t.panDelta)return this._active=!0,t}dragStart(e,t){!this.isEnabled()||this._lastPoint||this._moveStateManager.isValidStartEvent(e)&&(this._moveStateManager.startMove(e),this._lastPoint=Array.isArray(t)?t[0]:t,this._activateOnStart&&this._lastPoint&&(this._active=!0))}dragMove(e,t){if(!this.isEnabled())return;let r=this._lastPoint;if(!r)return;if(e.preventDefault(),!this._moveStateManager.isValidMoveEvent(e)){this.reset(e);return}let i=Array.isArray(t)?t[0]:t;if(!(!this._moved&&i.dist(r)<this._clickTolerance))return this._moved=!0,this._lastPoint=i,this._move(r,i)}dragEnd(e){!this.isEnabled()||!this._lastPoint||this._moveStateManager.isValidEndEvent(e)&&(this._moved&&Ut.suppressClick(),this.reset(e))}enable(){this._enabled=!0}disable(){this._enabled=!1,this.reset()}isEnabled(){return this._enabled}isActive(){return this._active}getClickTolerance(){return this._clickTolerance}};const KDe={0:1,2:2};function XDe(e,t){let r=KDe[t];return e.buttons===void 0||(e.buttons&r)!==r}var Tg=class{constructor(e){this._correctEvent=e.checkCorrectEvent}startMove(e){this._eventButton=e.button}endMove(e){delete this._eventButton}isValidStartEvent(e){return this._correctEvent(e)}isValidMoveEvent(e){return!XDe(e,this._eventButton)}isValidEndEvent(e){return e.button===this._eventButton}},JDe=class{constructor(){this._firstTouch=void 0}_isOneFingerTouch(e){return e.targetTouches.length===1}_isSameTouchEvent(e){return e.targetTouches[0].identifier===this._firstTouch}startMove(e){this._firstTouch=e.targetTouches[0].identifier}endMove(e){delete this._firstTouch}isValidStartEvent(e){return this._isOneFingerTouch(e)}isValidMoveEvent(e){return this._isOneFingerTouch(e)&&this._isSameTouchEvent(e)}isValidEndEvent(e){return this._isOneFingerTouch(e)&&this._isSameTouchEvent(e)}},QDe=class{constructor(e=new Tg({checkCorrectEvent:()=>!0}),t=new JDe){this.mouseMoveStateManager=e,this.oneFingerTouchMoveStateManager=t}_executeRelevantHandler(e,t,r){if(e instanceof MouseEvent)return t(e);if(typeof TouchEvent<"u"&&e instanceof TouchEvent)return r(e)}startMove(e){this._executeRelevantHandler(e,t=>{this.mouseMoveStateManager.startMove(t)},t=>{this.oneFingerTouchMoveStateManager.startMove(t)})}endMove(e){this._executeRelevantHandler(e,t=>{this.mouseMoveStateManager.endMove(t)},t=>{this.oneFingerTouchMoveStateManager.endMove(t)})}isValidStartEvent(e){return!!this._executeRelevantHandler(e,t=>this.mouseMoveStateManager.isValidStartEvent(t),t=>this.oneFingerTouchMoveStateManager.isValidStartEvent(t))}isValidMoveEvent(e){return!!this._executeRelevantHandler(e,t=>this.mouseMoveStateManager.isValidMoveEvent(t),t=>this.oneFingerTouchMoveStateManager.isValidMoveEvent(t))}isValidEndEvent(e){return!!this._executeRelevantHandler(e,t=>this.mouseMoveStateManager.isValidEndEvent(t),t=>this.oneFingerTouchMoveStateManager.isValidEndEvent(t))}};const vv=e=>{e.mousedown=e.dragStart,e.mousemoveWindow=e.dragMove,e.mouseup=e.dragEnd,e.contextmenu=t=>{t.preventDefault()}};function e7e({enable:e,clickTolerance:t}){return new Sg({clickTolerance:t,move:(r,i)=>({around:i,panDelta:i.sub(r)}),activateOnStart:!0,moveStateManager:new Tg({checkCorrectEvent:r=>r.button===0&&!r.ctrlKey}),enable:e,assignEvents:vv})}function t7e({enable:e,clickTolerance:t,aroundCenter:r=!0,minPixelCenterThreshold:i=100,rotateSpeed:n=.8},a){return new Sg({clickTolerance:t,move:(s,o)=>{let l=a();if(r&&Math.abs(l.y-s.y)>i)return{bearingDelta:TR(new de(s.x,o.y),o,l)};let u=(o.x-s.x)*n;return r&&o.y<l.y&&(u=-u),{bearingDelta:u}},moveStateManager:new Tg({checkCorrectEvent:s=>s.button===0&&s.ctrlKey||s.button===2&&!s.ctrlKey}),enable:e,assignEvents:vv})}function r7e({enable:e,clickTolerance:t,pitchSpeed:r=-.5}){return new Sg({clickTolerance:t,move:(i,n)=>({pitchDelta:(n.y-i.y)*r}),moveStateManager:new Tg({checkCorrectEvent:i=>i.button===0&&i.ctrlKey||i.button===2}),enable:e,assignEvents:vv})}function i7e({enable:e,clickTolerance:t,rollDegreesPerPixelMoved:r=.3},i){return new Sg({clickTolerance:t,move:(n,a)=>{let s=i(),o=(a.x-n.x)*r;return a.y<s.y&&(o=-o),{rollDelta:o}},moveStateManager:new Tg({checkCorrectEvent:n=>n.button===2&&n.ctrlKey}),enable:e,assignEvents:vv})}var n7e=class{constructor(e,t){this._clickTolerance=e.clickTolerance||1,this._map=t,this.reset()}reset(){this._active=!1,this._touches={},this._sum=new de(0,0)}_shouldBePrevented(e){return e<(this._map.cooperativeGestures.isEnabled()?2:1)}touchstart(e,t,r){return this._calculateTransform(e,t,r)}touchmove(e,t,r){if(this._active){if(this._shouldBePrevented(r.length)){this._map.cooperativeGestures.notifyGestureBlocked("touch_pan",e);return}return e.preventDefault(),this._calculateTransform(e,t,r)}}touchend(e,t,r){this._calculateTransform(e,t,r),this._active&&this._shouldBePrevented(r.length)&&this.reset()}touchcancel(){this.reset()}_calculateTransform(e,t,r){r.length>0&&(this._active=!0);let i=s3(r,t),n=new de(0,0),a=new de(0,0),s=0;for(let l in i){let u=i[l],c=this._touches[l];c&&(n._add(u),a._add(u.sub(c)),s++,i[l]=u)}if(this._touches=i,this._shouldBePrevented(s)||!a.mag())return;let o=a.div(s);if(this._sum._add(o),!(this._sum.mag()<this._clickTolerance))return{around:n.div(s),panDelta:o}}enable(){this._enabled=!0}disable(){this._enabled=!1,this.reset()}isEnabled(){return this._enabled}isActive(){return this._active}},OS=class{constructor(){this.reset()}reset(){this._active=!1,delete this._firstTwoTouches}touchstart(e,t,r){this._firstTwoTouches||r.length<2||(this._firstTwoTouches=[r[0].identifier,r[1].identifier],this._start([t[0],t[1]]))}touchmove(e,t,r){if(!this._firstTwoTouches)return;e.preventDefault();let[i,n]=this._firstTwoTouches,a=D0(r,t,i),s=D0(r,t,n);if(!a||!s)return;let o=this._aroundCenter?null:a.add(s).div(2);return this._move([a,s],o,e)}touchend(e,t,r){if(!this._firstTwoTouches)return;let[i,n]=this._firstTwoTouches,a=D0(r,t,i),s=D0(r,t,n);a&&s||(this._active&&Ut.suppressClick(),this.reset())}touchcancel(){this.reset()}enable(e){this._enabled=!0,this._aroundCenter=!!e&&e.around==="center"}disable(){this._enabled=!1,this.reset()}isEnabled(){return!!this._enabled}isActive(){return!!this._active}};function D0(e,t,r){for(let i=0;i<e.length;i++)if(e[i].identifier===r)return t[i]}const jE=.1;function UE(e,t){return Math.log(e/t)/Math.LN2}var a7e=class extends OS{constructor(){super(),this._zoomRate=1,this._zoomThreshold=jE}setZoomRate(e){this._zoomRate=e??1}setZoomThreshold(e){this._zoomThreshold=e??jE}reset(){super.reset(),delete this._distance,delete this._startDistance}_start(e){this._startDistance=this._distance=e[0].dist(e[1])}_move(e,t){let r=this._distance;if(this._distance=e[0].dist(e[1]),!(!this._active&&Math.abs(UE(this._distance,this._startDistance))<this._zoomThreshold))return this._active=!0,{zoomDelta:UE(this._distance,r)*this._zoomRate,pinchAround:t}}};function VE(e,t){return e.angleWith(t)*180/Math.PI}var s7e=class extends OS{reset(){super.reset(),delete this._minDiameter,delete this._startVector,delete this._vector}_start(e){this._startVector=this._vector=e[0].sub(e[1]),this._minDiameter=e[0].dist(e[1])}_move(e,t,r){let i=this._vector;if(this._vector=e[0].sub(e[1]),!(!this._active&&this._isBelowThreshold(this._vector)))return this._active=!0,{bearingDelta:VE(this._vector,i),pinchAround:t}}_isBelowThreshold(e){this._minDiameter=Math.min(this._minDiameter,e.mag());let t=25/(Math.PI*this._minDiameter)*360,r=VE(e,this._startVector);return Math.abs(r)<t}};function r2(e){return Math.abs(e.y)>Math.abs(e.x)}var o7e=class extends OS{constructor(e){super(),this._currentTouchCount=0,this._map=e}reset(){super.reset(),this._valid=void 0,delete this._firstMove,delete this._lastPoints}touchstart(e,t,r){super.touchstart(e,t,r),this._currentTouchCount=r.length}_start(e){this._lastPoints=e,r2(e[0].sub(e[1]))&&(this._valid=!1)}_move(e,t,r){if(this._map.cooperativeGestures.isEnabled()&&this._currentTouchCount<3)return;let i=e[0].sub(this._lastPoints[0]),n=e[1].sub(this._lastPoints[1]);if(this._valid=this.gestureBeginsVertically(i,n,r.timeStamp),this._valid)return this._lastPoints=e,this._active=!0,{pitchDelta:(i.y+n.y)/2*-.5}}gestureBeginsVertically(e,t,r){if(this._valid!==void 0)return this._valid;let i=e.mag()>=2,n=t.mag()>=2;if(!i&&!n)return;if(!i||!n)return this._firstMove===void 0&&(this._firstMove=r),r-this._firstMove<100&&void 0;let a=e.y>0==t.y>0;return r2(e)&&r2(t)&&a}};const l7e={panStep:100,bearingStep:15,pitchStep:10};var u7e=class{constructor(e,t){this._tr=t;let r=l7e;this._panStep=r.panStep,this._bearingStep=r.bearingStep,this._pitchStep=r.pitchStep,this._rotationDisabled=!1}reset(){this._active=!1}keydown(e){if(e.altKey||e.ctrlKey||e.metaKey)return;let t=0,r=0,i=0,n=0,a=0;switch(e.keyCode){case 61:case 107:case 171:case 187:t=1;break;case 189:case 109:case 173:t=-1;break;case 37:e.shiftKey?r=-1:(e.preventDefault(),n=-1);break;case 39:e.shiftKey?r=1:(e.preventDefault(),n=1);break;case 38:e.shiftKey?i=1:(e.preventDefault(),a=-1);break;case 40:e.shiftKey?i=-1:(e.preventDefault(),a=1);break;default:return}return this._rotationDisabled&&(r=0,i=0),{cameraAnimation:s=>{let o=this._tr;s.easeTo({duration:300,easeId:"keyboardHandler",easing:c7e,zoom:t?da(o.zoom+t*(e.shiftKey?2:1),s.getZoomSnap()):o.zoom,bearing:o.bearing+r*this._bearingStep,pitch:o.pitch+i*this._pitchStep,offset:[-n*this._panStep,-a*this._panStep],center:o.center},{originalEvent:e})}}}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 c7e(e){return e*(2-e)}const qE=4.000244140625;var d7e=class{constructor(e,t,r){this._onTimeout=i=>{this._type="wheel",this._delta-=this._lastValue,this._active||this._start(i)},this._map=e,this._tr=r,this._triggerRenderFrame=t,this._delta=0,this._defaultZoomRate=.01,this._wheelZoomRate=.0022222222222222222}setZoomRate(e){this._defaultZoomRate=e}setWheelZoomRate(e){this._wheelZoomRate=e}isEnabled(){return!!this._enabled}isActive(){return!!this._active||this._finishTimeout!==void 0}isZooming(){return!!this._zooming}enable(e){this.isEnabled()||(this._enabled=!0,this._aroundCenter=!!e&&e.around==="center")}disable(){this.isEnabled()&&(this._enabled=!1)}_shouldBePrevented(e){return this._map.cooperativeGestures.isEnabled()?!(e.ctrlKey||this._map.cooperativeGestures.isBypassed(e)):!1}wheel(e){if(!this.isEnabled())return;if(this._shouldBePrevented(e)){this._map.cooperativeGestures.notifyGestureBlocked("wheel_zoom",e);return}let t=e.deltaMode===WheelEvent.DOM_DELTA_LINE?e.deltaY*40:e.deltaY,r=tr(),i=r-(this._lastWheelEventTime||0);this._lastWheelEventTime=r,t!==0&&t%qE==0?this._type="wheel":t!==0&&Math.abs(t)<4?this._type="trackpad":i>400?(this._type=null,this._lastValue=t,this._timeout=setTimeout(this._onTimeout,40,e)):this._type||(this._type=Math.abs(i*t)<200?"trackpad":"wheel",this._timeout&&(clearTimeout(this._timeout),this._timeout=null,t+=this._lastValue)),e.shiftKey&&t&&(t/=4),this._type&&(this._lastWheelEvent=e,this._delta-=t,this._active||this._start(e)),e.preventDefault()}_start(e){if(!this._delta)return;this._needsRerender=!1,this._active=!0,this.isZooming()||(this._zooming=!0),this._finishTimeout&&(clearTimeout(this._finishTimeout),delete this._finishTimeout);let t=Ut.mousePos(this._map.getCanvas(),e),r=this._tr;this._aroundPoint=this._aroundCenter?r.transform.locationToScreenPoint(rt.convert(r.center)):t,this._needsRerender||(this._needsRerender=!0,this._triggerRenderFrame())}renderFrame(){if(!this._needsRerender||(this._needsRerender=!1,!this.isActive()))return;let e=this._tr.transform;if(typeof this._lastExpectedZoom=="number"){let s=e.zoom-this._lastExpectedZoom;
vendor: 3,998 bytes, line 1546
1546typeof this._startZoom=="number"&&(this._startZoom+=s),typeof this._targetZoom=="number"&&(this._targetZoom+=s)}if(this._delta!==0){let s=this._type==="wheel"&&Math.abs(this._delta)>qE?this._wheelZoomRate:this._defaultZoomRate,o=2/(1+Math.exp(-Math.abs(this._delta*s)));this._delta<0&&o!==0&&(o=1/o);let l=typeof this._targetZoom=="number"?In(this._targetZoom):e.scale,u=e.applyConstrain(e.getCameraLngLat(),cn(l*o)).zoom,c=this._map.getZoomSnap();if(this._type==="wheel"&&c>0){let d=da(e.zoom,c);this._targetZoom=da(u,c,u-d)}else this._targetZoom=u;this._type==="wheel"&&(this._startZoom=e.zoom,this._easing=this._smoothOutEasing(200)),this._delta=0}let t=typeof this._targetZoom=="number"?this._targetZoom:e.zoom,r=this._startZoom,i=this._easing,n=!1,a;if(this._type==="wheel"&&r&&i){let s=tr()-this._lastWheelEventTime,o=Math.min((s+5)/200,1),l=i(o);a=ai.number(r,t,l),o<1?this._needsRerender=!0:n=!0}else a=t,n=!0;return this._active=!0,n&&(this._active=!1,this._finishTimeout=setTimeout(()=>{this._zooming=!1,this._triggerRenderFrame(),delete this._targetZoom,delete this._lastExpectedZoom,delete this._finishTimeout},200)),this._lastExpectedZoom=a,{noInertia:!0,needsRenderFrame:!n,zoomDelta:a-e.zoom,around:this._aroundPoint,originalEvent:this._lastWheelEvent}}_smoothOutEasing(e){let t=Vx;if(this._prevEase){let r=this._prevEase,i=(tr()-r.start)/r.duration,n=r.easing(i+.01)-r.easing(i),a=.27/Math.sqrt(n*n+1e-4)*.01,s=Math.sqrt(.0729-a*a);t=I$(a,s,.25,1)}return this._prevEase={start:tr(),duration:e,easing:t},t}reset(){this._active=!1,this._zooming=!1,delete this._targetZoom,delete this._lastExpectedZoom,this._finishTimeout&&(clearTimeout(this._finishTimeout),delete this._finishTimeout)}},h7e=class{constructor(e,t){this._clickZoom=e,this._tapZoom=t}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()}},f7e=class{constructor(e,t){this._tr=t,this.reset()}reset(){this._active=!1}dblclick(e,t){return e.preventDefault(),{cameraAnimation:r=>{r.easeTo({duration:300,zoom:da(this._tr.zoom+(e.shiftKey?-1:1),r.getZoomSnap()),around:this._tr.unproject(t)},{originalEvent:e})}}}enable(){this._enabled=!0}disable(){this._enabled=!1,this.reset()}isEnabled(){return this._enabled}isActive(){return this._active}},p7e=class{constructor(){this._tap=new o3({numTouches:1,numTaps:1}),this._zoomRate=1,this.reset()}setZoomRate(e){this._zoomRate=e??1}reset(){this._active=!1,delete this._swipePoint,delete this._swipeTouch,delete this._tapTime,delete this._tapPoint,this._tap.reset()}touchstart(e,t,r){if(!this._swipePoint)if(!this._tapTime)this._tap.touchstart(e,t,r);else{let i=t[0],n=e.timeStamp-this._tapTime<500,a=this._tapPoint.dist(i)<30;!n||!a?this.reset():r.length>0&&(this._swipePoint=i,this._swipeTouch=r[0].identifier)}}touchmove(e,t,r){if(!this._tapTime)this._tap.touchmove(e,t,r);else if(this._swipePoint){if(r[0].identifier!==this._swipeTouch)return;let i=t[0],n=i.y-this._swipePoint.y;return this._swipePoint=i,e.preventDefault(),this._active=!0,{zoomDelta:n/128*this._zoomRate}}}touchend(e,t,r){if(this._tapTime)this._swipePoint&&r.length===0&&this.reset();else{let i=this._tap.touchend(e,t,r);i&&(this._tapTime=e.timeStamp,this._tapPoint=i)}}touchcancel(){this.reset()}enable(){this._enabled=!0}disable(){this._enabled=!1,this.reset()}isEnabled(){return this._enabled}isActive(){return this._active}},m7e=class{constructor(e,t,r){this._el=e,this._mousePan=t,this._touchPan=r}enable(e){this._inertiaOptions=e||{},this._mousePan.enable(),this._touchPan.enable(),this._el.classList.add("maplibregl-touch-drag-pan")}disable(){this._mousePan.disable(),this._touchPan.disable(),this._el.classList.remove("maplibregl-touch-drag-pan")}isEnabled(){return this._mousePan.isEnabled()&&this._touchPan.isEnabled()}isActive(){return this._mousePan.isActive()||this._touchPan.isActive()}}
1546,g7e=class{constructor(e,t,r,i){this._pitchWithRotate=e.pitchWithRotate,this._rollEnabled=e.rollEnabled,this._mouseRotate=t,this._mousePitch=r,this._mouseRoll=i}enable(){this._mouseRotate.enable(),this._pitchWithRotate&&this._mousePitch.enable(),this._rollEnabled&&this._mouseRoll.enable()}disable(){this._mouseRotate.disable(),this._mousePitch.disable(),this._mouseRoll.disable()}isEnabled(){return this._mouseRotate.isEnabled()&&(!this._pitchWithRotate||this._mousePitch.isEnabled())&&(!this._rollEnabled||this._mouseRoll.isEnabled())}isActive(){return this._mouseRotate.isActive()||this._mousePitch.isActive()||this._mouseRoll.isActive()}},_7e=class{constructor(e,t,r,i){this._el=e,this._touchZoom=t,this._touchRotate=r,this._tapDragZoom=i,this._rotationDisabled=!1,this._enabled=!0}enable(e){this._touchZoom.enable(e),this._rotationDisabled||this._touchRotate.enable(e),this._tapDragZoom.enable(),this._el.classList.add("maplibregl-touch-zoom-rotate")}disable(){this._touchZoom.disable(),this._touchRotate.disable(),this._tapDragZoom.disable(),this._el.classList.remove("maplibregl-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()}setZoomRate(e){this._touchZoom.setZoomRate(e),this._tapDragZoom.setZoomRate(e)}setZoomThreshold(e){this._touchZoom.setZoomThreshold(e)}disableRotation(){this._rotationDisabled=!0,this._touchRotate.disable()}enableRotation(){this._rotationDisabled=!1,this._touchZoom.isEnabled()&&this._touchRotate.enable()}},y7e=class{constructor(e,t){this._bypassKey=navigator.userAgent.includes("Mac")?"metaKey":"ctrlKey",this._map=e,this._options=t,this._enabled=!1}isActive(){return!1}reset(){}_setupUI(){if(this._container)return;let e=this._map.getCanvasContainer();e.classList.add("maplibregl-cooperative-gestures"),this._container=Ut.create("div","maplibregl-cooperative-gesture-screen",e);let t=this._map._getUIString("CooperativeGesturesHandler.WindowsHelpText");this._bypassKey==="metaKey"&&(t=this._map._getUIString("CooperativeGesturesHandler.MacHelpText"));let r=this._map._getUIString("CooperativeGesturesHandler.MobileHelpText"),i=document.createElement("div");i.className="maplibregl-desktop-message",i.textContent=t,this._container.appendChild(i);let n=document.createElement("div");n.className="maplibregl-mobile-message",n.textContent=r,this._container.appendChild(n),this._container.setAttribute("aria-hidden","true")}_destroyUI(){this._container&&(this._container.remove(),this._map.getCanvasContainer().classList.remove("maplibregl-cooperative-gestures")),delete this._container}enable(){this._setupUI(),this._enabled=!0}disable(){this._enabled=!1,this._destroyUI()}isEnabled(){return this._enabled}isBypassed(e){return e[this._bypassKey]}notifyGestureBlocked(e,t){this._enabled&&(this._map.fire(new Ei("cooperativegestureprevented",{gestureType:e,originalEvent:t})),this._container.classList.add("maplibregl-show"),setTimeout(()=>{this._container.classList.remove("maplibregl-show")},100))}},v7e=class{constructor(e){this._camera=e}get transform(){return this._camera._requestedCameraState||this._camera.transform}get center(){return{lng:this.transform.center.lng,lat:this.transform.center.lat}}get zoom(){return this.transform.zoom}get pitch(){return this.transform.pitch}get bearing(){return this.transform.bearing}unproject(e){return this.transform.screenPointToLocation(de.convert(e),this._camera.terrain)}};const R0=e=>e.zoom||e.drag||e.roll||e.pitch||e.rotate;var b7e=class extends ug{};function i2(e){var t;return((t=e.panDelta)==null?void 0:t.mag())||e.zoomDelta||e.bearingDelta||e.pitchDelta||e.rollDelta}var x7e=class{get _ownerDocument(){var e;return((e=this._el)==null?void 0:e.ownerDocument)||document}get _ownerWindow(){var e,t;return((t=(e=this._el)==null?void 0:e.ownerDocument)==null?void 0:t.defaultView)||window}constructor(e,t,r){this.handleWindowEvent=n=>{this.handleEvent(n,`${n.type}Window`)},this.handleEvent=(n,a)=>
vendor: 8,604 bytes, line 1546
1546{if(n.type==="blur"){this.stop(!0);return}this._updatingCamera=!0;let s=n.type==="renderFrame"?void 0:n,o={needsRenderFrame:!1},l={},u={};for(let{handlerName:h,handler:f,allowed:p}of this._handlers){if(!f.isEnabled())continue;let m;if(this._blockedByActive(u,p,h))f.reset();else if(f[a||n.type]){if(sSe(n,a||n.type)){let g=Ut.mousePos(this._map.getCanvas(),n);m=f[a||n.type](n,g)}else if(aSe(n,a||n.type)){let g=n.touches,v=this._getMapTouches(g),x=Ut.touchPos(this._map.getCanvas(),v);m=f[a||n.type](n,x,v)}else oSe(a||n.type)||(m=f[a||n.type](n));this.mergeHandlerResult(o,l,m,h,s),m!=null&&m.needsRenderFrame&&this._triggerRenderFrame()}(m||f.isActive())&&(u[h]=f)}let c={};for(let h in this._previousActiveHandlers)u[h]||(c[h]=s);this._previousActiveHandlers=u,(Object.keys(c).length||i2(o))&&(this._changes.push([o,l,c]),this._triggerRenderFrame()),(Object.keys(u).length||i2(o))&&this._camera.stop(!0),this._updatingCamera=!1;let{cameraAnimation:d}=o;d&&(this._inertia.clear(),this._fireEvents({},{},!0),this._changes=[],d(this._map))},this._map=e,this._camera=t,this._transformProvider=new v7e(this._camera),this._el=this._map.getCanvasContainer(),this._handlers=[],this._handlersById={},this._changes=[],this._inertia=new VDe(e),this._bearingSnap=r.bearingSnap,this._previousActiveHandlers={},this._eventsInProgress={},this._addDefaultHandlers(r);let i=this._el;this._listeners=[[i,"touchstart",{passive:!0}],[i,"touchmove",{passive:!1}],[i,"touchend",void 0],[i,"touchcancel",void 0],[i,"mousedown",void 0],[i,"mousemove",void 0],[i,"mouseup",void 0],[this._ownerDocument,"mousemove",{capture:!0}],[this._ownerDocument,"mouseup",void 0],[i,"mouseover",void 0],[i,"mouseout",void 0],[i,"dblclick",void 0],[i,"click",void 0],[i,"keydown",{capture:!1}],[i,"keyup",void 0],[i,"wheel",{passive:!1}],[i,"contextmenu",void 0],[this._ownerWindow,"blur",void 0]];for(let[n,a,s]of this._listeners)n.addEventListener(a,n===this._ownerDocument?this.handleWindowEvent:this.handleEvent,s)}destroy(){for(let[e,t,r]of this._listeners)e.removeEventListener(t,e===this._ownerDocument?this.handleWindowEvent:this.handleEvent,r)}_addDefaultHandlers(e){let t=this._map,r=t.getCanvasContainer();this._add("mapEvent",new qDe(t,e));let i=t.boxZoom=new HDe(t,e,this._transformProvider);this._add("boxZoom",i),e.interactive&&e.boxZoom&&i.enable();let n=t.cooperativeGestures=new y7e(t,e.cooperativeGestures);this._add("cooperativeGestures",n),e.cooperativeGestures&&n.enable();let a=new ZDe(t,this._transformProvider),s=new f7e(t,this._transformProvider);t.doubleClickZoom=new h7e(s,a),this._add("tapZoom",a),this._add("clickZoom",s),e.interactive&&e.doubleClickZoom&&t.doubleClickZoom.enable();let o=new p7e;this._add("tapDragZoom",o);let l=t.touchPitch=new o7e(t);this._add("touchPitch",l),e.interactive&&e.touchPitch&&t.touchPitch.enable(e.touchPitch);let u=()=>t.project(t.getCenter()),c=t7e(e,u),d=r7e(e),h=i7e(e,u);t.dragRotate=new g7e(e,c,d,h),this._add("mouseRotate",c,["mousePitch"]),this._add("mousePitch",d,["mouseRotate","mouseRoll"]),this._add("mouseRoll",h,["mousePitch"]),e.interactive&&e.dragRotate&&t.dragRotate.enable();let f=e7e(e),p=new n7e(e,t);t.dragPan=new m7e(r,f,p),this._add("mousePan",f),this._add("touchPan",p,["touchZoom","touchRotate"]),e.interactive&&e.dragPan&&t.dragPan.enable(e.dragPan);let m=new s7e,g=new a7e;t.touchZoomRotate=new _7e(r,g,m,o),this._add("touchRotate",m,["touchPan","touchZoom"]),this._add("touchZoom",g,["touchPan","touchRotate"]),e.interactive&&e.touchZoomRotate&&t.touchZoomRotate.enable(e.touchZoomRotate),this._add("blockableMapEvent",new GDe(t));let v=t.scrollZoom=new d7e(t,()=>this._triggerRenderFrame(),this._transformProvider);this._add("scrollZoom",v,["mousePan"]),e.interactive&&e.scrollZoom&&t.scrollZoom.enable(e.scrollZoom);let x=t.keyboard=new u7e(t,this._transformProvider);this._add("keyboard",x),e.interactive&&e.keyboard&&t.keyboard.enable()}_add(e,t,r){this._handlers.push({handlerName:e,handler:t,allowed:r}),this._handlersById[e]=t}stop(e){if(!this._updatingCamera){for(let{handler:t}of this._handlers)t.reset();this._inertia.clear(),this._fireEvents({},{},e),this._changes=[]}}isActive(){for(let{handler:e}of this._handlers)if(e.isActive())return!0;return!1}isZooming(){return!!this._eventsInProgress.zoom||this._map.scrollZoom.isZooming()}isRotating(){return!!this._eventsInProgress.rotate}isMoving(){return!!R0(this._eventsInProgress)||this.isZooming()}_blockedByActive(e,t,r){for(let i in e)if(i!==r&&!(t!=null&&t.includes(i)))return!0;return!1}_getMapTouches(e){let t=[];for(let r of e){let i=r.target;this._el.contains(i)&&t.push(r)}return t}mergeHandlerResult(e,t,r,i,n){if(!r)return;Ne(e,r);let a={handlerName:i,originalEvent:r.originalEvent||n};r.zoomDelta!==void 0&&(t.zoom=a),r.panDelta!==void 0&&(t.drag=a),r.rollDelta!==void 0&&(t.roll=a),r.pitchDelta!==void 0&&(t.pitch=a),r.bearingDelta!==void 0&&(t.rotate=a)}_applyChanges(){let e={},t={},r={};for(let[i,n,a]of this._changes)i.panDelta&&(e.panDelta=(e.panDelta||new de(0,0))._add(i.panDelta)),i.zoomDelta&&(e.zoomDelta=(e.zoomDelta||0)+i.zoomDelta),i.bearingDelta&&(e.bearingDelta=(e.bearingDelta||0)+i.bearingDelta),i.pitchDelta&&(e.pitchDelta=(e.pitchDelta||0)+i.pitchDelta),i.rollDelta&&(e.rollDelta=(e.rollDelta||0)+i.rollDelta),i.around!==void 0&&(e.around=i.around),i.pinchAround!==void 0&&(e.pinchAround=i.pinchAround),i.noInertia&&(e.noInertia=i.noInertia),Ne(t,n),Ne(r,a);this._updateMapTransform(e,t,r),this._changes=[]}_updateMapTransform(e,t,r){let i=this._map,n=this._camera.getTransformForUpdate(),a=i.terrain;if(!i2(e)&&!(a&&this._terrainMovement)){this._fireEvents(t,r,!0);return}this._camera.stop(!0);let{panDelta:s,zoomDelta:o,bearingDelta:l,pitchDelta:u,rollDelta:c,around:d,pinchAround:h}=e;h!==void 0&&(d=h),d||(d=this._camera.transform.centerPoint),a&&!n.isPointOnMapSurface(d)&&(d=n.centerPoint);let f={panDelta:s,zoomDelta:o,rollDelta:c,pitchDelta:u,bearingDelta:l,around:d};this._camera.cameraHelper.useGlobeControls&&!n.isPointOnMapSurface(d)&&(d=n.centerPoint);let p=d.distSqr(n.centerPoint)<.01?n.center:n.screenPointToLocation(s?d.sub(s):d);this._handleMapControls({terrain:a,tr:n,deltasForHelper:f,preZoomAroundLoc:p,combinedEventsInProgress:t,panDelta:s}),this._camera.applyUpdatedTransform(n),this._map._update(),e.noInertia||this._inertia.record(e),this._fireEvents(t,r,!0)}_handleMapControls({terrain:e,tr:t,deltasForHelper:r,preZoomAroundLoc:i,combinedEventsInProgress:n,panDelta:a}){let s=this._camera.cameraHelper;if(s.handleMapControlsRollPitchBearingZoom(r,t),!e){s.handleMapControlsPan(r,t,i);return}if(s.useGlobeControls){!this._terrainMovement&&(n.drag||n.zoom)&&(this._terrainMovement=!0,this._camera.elevationFreeze=!0),s.handleMapControlsPan(r,t,i);return}if(!this._terrainMovement&&(n.drag||n.zoom)){this._terrainMovement=!0,this._camera.elevationFreeze=!0,s.handleMapControlsPan(r,t,i);return}if(n.drag&&this._terrainMovement&&a){t.setCenter(t.screenPointToLocation(t.centerPoint.sub(a)));return}s.handleMapControlsPan(r,t,i)}_fireEvents(e,t,r){let i=R0(this._eventsInProgress),n=R0(e),a={};for(let c in e){let{originalEvent:d}=e[c];this._eventsInProgress[c]||(a[`${c}start`]=d),this._eventsInProgress[c]=e[c]}!i&&n&&this._fireEvent("movestart",n.originalEvent);for(let c in a)this._fireEvent(c,a[c]);n&&this._fireEvent("move",n.originalEvent);for(let c in e){let{originalEvent:d}=e[c];this._fireEvent(c,d)}let s={},o;for(let c in this._eventsInProgress){let{handlerName:d,originalEvent:h}=this._eventsInProgress[c];this._handlersById[d].isActive()||(delete this._eventsInProgress[c],o=t[d]||h,s[`${c}end`]=o)}for(let c in s)this._fireEvent(c,s[c]);let l=R0(this._eventsInProgress),u=(i||n)&&!l;if(u&&this._terrainMovement){this._camera.elevationFreeze=!1,this._terrainMovement=!1;let c=this._camera.getTransformForUpdate();this._map.getCenterClampedToGround()&&c.recalculateZoomAndCenter(this._map.terrain),this._camera.applyUpdatedTransform(c)}if(r&&u){this._updatingCamera=!0;let c=this._inertia._onMoveEnd(this._map.dragPan._inertiaOptions),d=h=>h!==0&&-this._bearingSnap<h&&h<this._bearingSnap;c&&(c.essential||!qn.prefersReducedMotion)?(d(c.bearing||this._map.getBearing())&&(c.bearing=0),c.freezeElevation=!0,this._map.easeTo(c,{originalEvent:o})):(this._map.fire(new Ve("moveend",{originalEvent:o})),d(this._map.getBearing())&&this._map.resetNorth()),this._updatingCamera=!1}}_fireEvent(e,t){this._map.fire(new Ve(e,t?{originalEvent:t}:{}))}_requestFrame(){return this._map.triggerRepaint(),this._map._renderTaskQueue.add(e=>{delete this._frameId,this.handleEvent(new b7e("renderFrame",{timeStamp:e})),this._applyChanges()})}
1546_triggerRenderFrame(){this._frameId===void 0&&(this._frameId=this._requestFrame())}},w7e=class extends Rn{constructor(e){super(),this._renderFrameCallback=()=>{let t=Math.min((tr()-this._easeStart)/this._easeOptions.duration,1);this._onEaseFrame(this._easeOptions.easing(t)),t<1&&this._easeFrameId?this._easeFrameId=this._requestRenderFrame(this._renderFrameCallback):this.stop()},this.transform=new qy,this.cameraHelper=new Gy,e.minZoom!==void 0&&this.transform.setMinZoom(e.minZoom),e.maxZoom!==void 0&&this.transform.setMaxZoom(e.maxZoom),e.minPitch!==void 0&&this.transform.setMinPitch(e.minPitch),e.maxPitch!==void 0&&this.transform.setMaxPitch(e.maxPitch),e.renderWorldCopies!==void 0&&this.transform.setRenderWorldCopies(e.renderWorldCopies),e.transformConstrain!==null&&this.transform.setConstrainOverride(e.transformConstrain),this._moving=!1,this._zooming=!1,this._bearingSnap=e.bearingSnap,this._zoomSnap=e.zoomSnap,this._requestRenderFrame=e.requestRenderFrame,this._cancelRenderFrame=e.cancelRenderFrame,this.terrain=e.terrain,this._centerClampedToGround=e.centerClampedToGround??!0,this.transformCameraUpdate=e.transformCameraUpdate??null,this._stopHandlers=e.stopHandlers??(()=>{}),this.on("moveend",()=>{delete this._requestedCameraState})}migrateProjection(e,t){e.apply(this.transform,!0),this.transform=e,this.cameraHelper=t}getCenter(){return new rt(this.transform.center.lng,this.transform.center.lat)}setCenter(e,t){return this.jumpTo({center:e},t)}getCenterElevation(){return this.transform.elevation}setCenterElevation(e,t){return this.jumpTo({elevation:e},t),this}getCenterClampedToGround(){return this._centerClampedToGround}setCenterClampedToGround(e){this._centerClampedToGround=e}panBy(e,t,r){return e=de.convert(e).mult(-1),this.panTo(this.transform.center,Ne({offset:e},t),r)}panTo(e,t,r){return this.easeTo(Ne({center:e},t),r)}getZoom(){return this.transform.zoom}setZoom(e,t){return this.jumpTo({zoom:e},t),this}zoomTo(e,t,r){return this.easeTo(Ne({zoom:e},t),r)}zoomIn(e,t){return this.zoomTo(da(this.getZoom()+1,this._zoomSnap),e,t),this}zoomOut(e,t){return this.zoomTo(da(this.getZoom()-1,this._zoomSnap),e,t),this}getVerticalFieldOfView(){return this.transform.fov}setVerticalFieldOfView(e,t){return e!=this.transform.fov&&(this.transform.setFov(e),this.fire(new Ve("movestart",t)).fire(new Ve("move",t)).fire(new Ve("moveend",t))),this}getBearing(){return this.transform.bearing}setZoomSnap(e){return this._zoomSnap=e,this}getZoomSnap(){return this._zoomSnap}setBearing(e,t){return this.jumpTo({bearing:e},t),this}getPadding(){return this.transform.padding}setPadding(e,t){return this.jumpTo({padding:e},t),this}rotateTo(e,t,r){return this.easeTo(Ne({bearing:e},t),r)}resetNorth(e,t){return this.rotateTo(0,Ne({duration:1e3},e),t),this}resetNorthPitch(e,t){return this.easeTo(Ne({bearing:0,pitch:0,roll:0,duration:1e3},e),t),this}snapToNorth(e,t){return Math.abs(this.getBearing())<this._bearingSnap?this.resetNorth(e,t):this}getPitch(){return this.transform.pitch}setPitch(e,t){return this.jumpTo({pitch:e},t),this}getRoll(){return this.transform.roll}setRoll(e,t){return this.jumpTo({roll:e},t),this}cameraForBounds(e,t){e=co.convert(e).adjustAntiMeridian();let r=(t==null?void 0:t.bearing)||0;return this._cameraForBoxAndBearing(e.getNorthWest(),e.getSouthEast(),r,t)}_cameraForBoxAndBearing(e,t,r,i){let n={top:0,bottom:0,right:0,left:0};if(i=Ne({padding:n,offset:[0,0],maxZoom:this.transform.maxZoom},i),typeof i.padding=="number"){let u=i.padding;i.padding={top:u,bottom:u,right:u,left:u}}let a=Ne(n,i.padding);i.padding=a;let s=this.transform,o=new co(e,t),l=this.cameraHelper.cameraForBoxAndBearing(i,a,o,r,s);return l&&this._zoomSnap&&(l.zoom=da(l.zoom,this._zoomSnap,-1)),l}fitBounds(e,t,r){return this._fitInternal(this.cameraForBounds(e,t),t,r)}fitScreenCoordinates(e,t,r,i,n){return this._fitInternal(this._cameraForBoxAndBearing(this.transform.screenPointToLocation(de.convert(e)),this.transform.screenPointToLocation(de.convert(t)),r,i),i,n)}_fitInternal(e,t,r){return e?(t=Ne(e,t),delete t.padding,t.linear?this.easeTo(t,r):this.flyTo(t,r)):this}jumpTo(e,t){this.stop(),"zoom"in e&&this._zoomSnap&&(e.zoom=da(e.zoom,this._zoomSnap));let r=this.getTransformForUpdate(),i=!1,n=!1,a=!1,s=r.zoom;this.terrain&&r.setElevation(this.terrain.getElevationForLngLatZoom(e.center?rt.convert(e.center):r.center,e.zoom||r.tileZoom)),this.cameraHelper.handleJumpToCenterZoom(r,e);let o=r.zoom!==s;return"elevation"in e&&r.elevation!==+e.elevation&&r.setElevation(+e.elevation),"bearing"in e&&r.bearing!==+e.bearing&&(i=!0,r.setBearing(+e.bearing)),"pitch"in e&&r.pitch!==+e.pitch&&(n=!0,r.setPitch(+e.pitch)),"roll"in e&&r.roll!==+e.roll&&(a=!0,r.setRoll(+e.roll)),e.padding!=null&&!r.isPaddingEqual(e.padding)&&r.setPadding(e.padding),this.applyUpdatedTransform(r),this.fire(new Ve("movestart",t)).fire(new Ve("move",t)),o&&this.fire(new Ve("zoomstart",t)).fire(new Ve("zoom",t)).fire(new Ve("zoomend",t)),i&&this.fire(new Ve("rotatestart",t)).fire(new Ve("rotate",t)).fire(new Ve("rotateend",t)),n&&this.fire(new Ve("pitchstart",t)).fire(new Ve("pitch",t)).fire(new Ve("pitchend",t)),a&&this.fire(new Ve("rollstart",t)).fire(new Ve("roll",t)).fire(new Ve("rollend",t)),this.fire(new Ve("moveend",t))}calculateCameraOptionsFromTo(e,t,r,i=0){let n=nr.fromLngLat(e,t),a=nr.fromLngLat(r,i),s=a.x-n.x,o=a.y-n.y,l=a.z-n.z,u=Math.hypot(s,o,l);if(u===0)throw Error("Can't calculate camera options with same From and To");let c=Math.hypot(s,o),d=cn(this.transform.cameraToCenterDistance/u/this.transform.tileSize),h=Math.atan2(s,-o)*180/Math.PI,f=Math.acos(c/u)*180/Math.PI;return f=l<0?90-f:90+f,{center:a.toLngLat(),elevation:i,zoom:d,pitch:f,bearing:h}}calculateCameraOptionsFromCameraLngLatAltRotation(e,t,r,i,n){let a=this.transform.calculateCenterFromCameraLngLatAlt(e,t,r,i
vendor: 5,238 bytes, line 1546
1546);return{center:a.center,elevation:a.elevation,zoom:a.zoom,bearing:r,pitch:i,roll:n}}easeTo(e,t){this._stop(!1,e.easeId),e=Ne({offset:[0,0],duration:500,easing:Vx},e),"zoom"in e&&this._zoomSnap&&(e.zoom=da(e.zoom,this._zoomSnap)),(e.animate===!1||!e.essential&&qn.prefersReducedMotion)&&(e.duration=0);let r=this.getTransformForUpdate(),i=this.getBearing(),n=r.pitch,a=r.roll,s="bearing"in e?this._normalizeBearing(e.bearing,i):i,o="pitch"in e?+e.pitch:n,l="roll"in e?this._normalizeBearing(e.roll,a):a,u="padding"in e?e.padding:r.padding,c=de.convert(e.offset),d,h;e.around&&(d=rt.convert(e.around),h=r.locationToScreenPoint(d));let f={moving:this._moving,zooming:this._zooming,rotating:this._rotating,pitching:this._pitching,rolling:this._rolling},p=this.cameraHelper.handleEaseTo(r,{bearing:s,pitch:o,roll:l,padding:u,around:d,aroundPoint:h,offsetAsPoint:c,offset:e.offset,zoom:e.zoom,center:e.center});return this._rotating||(this._rotating=i!==s),this._pitching||(this._pitching=o!==n),this._rolling||(this._rolling=l!==a),this._padding=!r.isPaddingEqual(u),this._zooming||(this._zooming=p.isZooming),this._easeId=e.easeId,this._prepareEase(t,e.noMoveStart,f),this.terrain&&this._prepareElevation(p.elevationCenter),this._ease(m=>{p.easeFunc(m),this.terrain&&!e.freezeElevation&&this._updateElevation(m),this.applyUpdatedTransform(r),this._fireMoveEvents(t)},m=>{this.terrain&&e.freezeElevation&&this._finalizeElevation(),this._afterEase(t,m)},e),this}_prepareEase(e,t,r={}){this._moving=!0,!t&&!r.moving&&this.fire(new Ve("movestart",e)),this._zooming&&!r.zooming&&this.fire(new Ve("zoomstart",e)),this._rotating&&!r.rotating&&this.fire(new Ve("rotatestart",e)),this._pitching&&!r.pitching&&this.fire(new Ve("pitchstart",e)),this._rolling&&!r.rolling&&this.fire(new Ve("rollstart",e))}_prepareElevation(e){this._elevationCenter=e,this._elevationStart=this.transform.elevation,this._elevationTarget=this.terrain.getElevationForLngLatZoom(e,this.transform.tileZoom),this.elevationFreeze=!0}_updateElevation(e){(this._elevationStart===void 0||this._elevationCenter===void 0)&&this._prepareElevation(this.transform.center),this.transform.setMinElevationForCurrentTile(this.terrain.getMinTileElevationForLngLatZoom(this._elevationCenter,this.transform.tileZoom));let t=this.terrain.getElevationForLngLatZoom(this._elevationCenter,this.transform.tileZoom);if(e<1&&t!==this._elevationTarget){let r=this._elevationTarget-this._elevationStart,i=(t-(r*e+this._elevationStart))/(1-e);this._elevationStart+=e*(r-i),this._elevationTarget=t}this.transform.setElevation(ai.number(this._elevationStart,this._elevationTarget,e))}_finalizeElevation(){this.elevationFreeze=!1,this.getCenterClampedToGround()&&this.transform.recalculateZoomAndCenter(this.terrain)}getTransformForUpdate(){return!this.transformCameraUpdate&&!this.terrain?this.transform:(this._requestedCameraState||(this._requestedCameraState=this.transform.clone()),this._requestedCameraState)}_elevateCameraIfInsideTerrain(e){if(!this.terrain&&e.elevation>=0&&e.pitch<=90)return{};let t=e.getCameraLngLat(),r=e.getCameraAltitude(),i=this.terrain?this.terrain.getElevationForLngLatZoom(t,e.zoom):0;if(r<i){let n=this.calculateCameraOptionsFromTo(t,i,e.center,e.elevation);return{pitch:n.pitch,zoom:n.zoom}}return{}}applyUpdatedTransform(e){let t=[];if(t.push(i=>this._elevateCameraIfInsideTerrain(i)),this.transformCameraUpdate&&t.push(i=>this.transformCameraUpdate(i)),!t.length)return;let r=e.clone();for(let i of t){let n=r.clone(),{center:a,zoom:s,roll:o,pitch:l,bearing:u,elevation:c}=i(n);a&&n.setCenter(a),c!==void 0&&n.setElevation(c),s!==void 0&&n.setZoom(s),o!==void 0&&n.setRoll(o),l!==void 0&&n.setPitch(l),u!==void 0&&n.setBearing(u),r.apply(n,!1)}this.transform.apply(r,!1)}_fireMoveEvents(e){this.fire(new Ve("move",e)),this._zooming&&this.fire(new Ve("zoom",e)),this._rotating&&this.fire(new Ve("rotate",e)),this._pitching&&this.fire(new Ve("pitch",e)),this._rolling&&this.fire(new Ve("roll",e))}_afterEase(e,t){if(this._easeId&&t&&this._easeId===t)return;delete this._easeId;let r=this._zooming,i=this._rotating,n=this._pitching,a=this._rolling;this._moving=!1,this._zooming=!1,this._rotating=!1,this._pitching=!1,this._rolling=!1,this._padding=!1,r&&this.fire(new Ve("zoomend",e)),i&&this.fire(new Ve("rotateend",e)),n&&this.fire(new Ve("pitchend",e)),a&&this.fire(new Ve("rollend",e)),this.fire(new Ve("moveend",e))}flyTo(e,t){if(!e.essential&&qn.prefersReducedMotion){let D=og(e,["center","zoom","bearing","pitch","roll","elevation","padding"]);return this.jumpTo(D,t)}this.stop(),e=Ne({offset:[0,0],speed:1.2,curve:1.42,easing:Vx},e),"zoom"in e&&this._zoomSnap&&(e.zoom=da(e.zoom,this._zoomSnap));let r=this.getTransformForUpdate(),i=r.bearing,n=r.pitch,a=r.roll,s=r.padding,o="bearing"in e?this._normalizeBearing(e.bearing,i):i,l="pitch"in e?+e.pitch:n,u="roll"in e?this._normalizeBearing(e.roll,a):a,c="padding"in e?e.padding:r.padding,d=de.convert(e.offset),h=r.centerPoint.add(d),f=r.screenPointToLocation(h),p=this.cameraHelper.handleFlyTo(r,{bearing:o,pitch:l,roll:u,padding:c,locationAtOffset:f,offsetAsPoint:d,center:e.center,minZoom:e.minZoom,zoom:e.zoom}),m=e.curve,g=Math.max(r.width,r.height),v=g/p.scaleOfZoom,x=p.pixelPathLength,_=g/p.scaleOfMinZoom;
vendor: 4,866 bytes, line 1546
1546m=Math.min(m,Math.sqrt(_/x*2));let y=m*m;function w(D){let A=(v*v-g*g+(D?-1:1)*y*y*x*x)/(2*(D?v:g)*y*x);return Math.log(Math.sqrt(A*A+1)-A)}function $(D){return(Math.exp(D)-Math.exp(-D))/2}function S(D){return(Math.exp(D)+Math.exp(-D))/2}function E(D){return $(D)/S(D)}let C=w(!1),I=function(D){return S(C)/S(C+m*D)},P=function(D){return g*((S(C)*E(C+m*D)-$(C))/y)/x},T=(w(!0)-C)/m;if(Math.abs(x)<2e-6||!isFinite(T)){if(Math.abs(g-v)<1e-6)return this.easeTo(e,t);let D=v<g?-1:1;T=Math.abs(Math.log(v/g))/m,P=()=>0,I=A=>Math.exp(D*m*A)}if("duration"in e)e.duration=+e.duration;else{let D="screenSpeed"in e?+e.screenSpeed/m:+e.speed;e.duration=1e3*T/D}return e.maxDuration&&e.duration>e.maxDuration&&(e.duration=0),this._zooming=!0,this._rotating=i!==o,this._pitching=l!==n,this._rolling=u!==a,this._padding=!r.isPaddingEqual(c),this._prepareEase(t,!1),this.terrain&&this._prepareElevation(p.targetCenter),this._ease(D=>{let A=D*T,z=1/I(A),R=P(A);this._rotating&&r.setBearing(ai.number(i,o,D)),this._pitching&&r.setPitch(ai.number(n,l,D)),this._rolling&&r.setRoll(ai.number(a,u,D)),this._padding&&(r.interpolatePadding(s,c,D),h=r.centerPoint.add(d)),p.easeFunc(D,z,R,h),this.terrain&&!e.freezeElevation&&this._updateElevation(D),this.applyUpdatedTransform(r),this._fireMoveEvents(t)},()=>{this.terrain&&e.freezeElevation&&this._finalizeElevation(),this._afterEase(t)},e),this}isEasing(){return!!this._easeFrameId}stop(e){return this._stop(e)}_stop(e,t){if(this._easeFrameId&&(this._cancelRenderFrame(this._easeFrameId),delete this._easeFrameId,delete this._onEaseFrame),this._onEaseEnd){let r=this._onEaseEnd;delete this._onEaseEnd,r.call(this,t)}return e||this._stopHandlers(),this}_ease(e,t,r){r.animate===!1||r.duration===0?(e(1),t()):(this._easeStart=tr(),this._easeOptions=r,this._onEaseFrame=e,this._onEaseEnd=t,this._easeFrameId=this._requestRenderFrame(this._renderFrameCallback))}_normalizeBearing(e,t){e=ys(e,-180,180);let r=Math.abs(e-t);return Math.abs(e-360-t)<r&&(e-=360),Math.abs(e+360-t)<r&&(e+=360),e}isMoving(){return this._moving}isZooming(){return this._zooming}isRotating(){return this._rotating}};const bz={compact:!0,customAttribution:'<a href="https://maplibre.org/" target="_blank">MapLibre</a>'};var xz=class{constructor(e=bz){this._toggleAttribution=()=>{this._container.classList.contains("maplibregl-compact")&&(this._container.classList.contains("maplibregl-compact-show")?(this._container.setAttribute("open",""),this._container.classList.remove("maplibregl-compact-show")):(this._container.classList.add("maplibregl-compact-show"),this._container.removeAttribute("open")))},this._updateData=t=>{t&&(t.type==="terrain"||t.dataType==="style"||t.dataType==="source"&&(t.sourceDataType==="metadata"||t.sourceDataType==="visibility"))&&this._updateAttributions()},this._updateCompact=()=>{this._map.getCanvasContainer().offsetWidth<=640||this._compact?this._compact===!1?this._container.setAttribute("open",""):!this._container.classList.contains("maplibregl-compact")&&!this._container.classList.contains("maplibregl-attrib-empty")&&(this._container.setAttribute("open",""),this._container.classList.add("maplibregl-compact","maplibregl-compact-show")):(this._container.setAttribute("open",""),this._container.classList.contains("maplibregl-compact")&&this._container.classList.remove("maplibregl-compact","maplibregl-compact-show"))},this._updateCompactMinimize=()=>{this._container.classList.contains("maplibregl-compact")&&this._container.classList.contains("maplibregl-compact-show")&&this._container.classList.remove("maplibregl-compact-show")},this.options=e}getDefaultPosition(){return"bottom-right"}onAdd(e){return this._map=e,this._compact=this.options.compact,this._container=Ut.create("details","maplibregl-ctrl maplibregl-ctrl-attrib"),this._compactButton=Ut.create("summary","maplibregl-ctrl-attrib-button",this._container),this._compactButton.addEventListener("click",this._toggleAttribution),this._setElementTitle(this._compactButton,"ToggleAttribution"),this._innerContainer=Ut.create("div","maplibregl-ctrl-attrib-inner",this._container),this._updateAttributions(),this._updateCompact(),this._map.on("styledata",this._updateData),this._map.on("sourcedata",this._updateData),this._map.on("terrain",this._updateData),this._map.on("resize",this._updateCompact),this._map.on("drag",this._updateCompactMinimize),this._container}onRemove(){this._container.remove(),this._map.off("styledata",this._updateData),this._map.off("sourcedata",this._updateData),this._map.off("terrain",this._updateData),this._map.off("resize",this._updateCompact),this._map.off("drag",this._updateCompactMinimize),this._map=void 0,this._compact=void 0,this._attribHTML=void 0}_setElementTitle(e,t){let r=this._map._getUIString(`AttributionControl.${t}`);e.title=r,e.setAttribute("aria-label",r)}_updateAttributions(){if(!this._map.style)return;let e=[];
vendor: 6,831 bytes, line 1546
1546if(this.options.customAttribution&&(Array.isArray(this.options.customAttribution)?e=e.concat(this.options.customAttribution.map(i=>typeof i=="string"?i:"")):typeof this.options.customAttribution=="string"&&e.push(this.options.customAttribution)),this._map.style.stylesheet){let i=this._map.style.stylesheet;this.styleOwner=i.owner,this.styleId=i.id}let t=this._map.style.tileManagers;for(let i in t){let n=t[i];if(n.used||n.usedForTerrain){let a=n.getSource();a.attribution&&!e.includes(a.attribution)&&e.push(a.attribution)}}e=e.filter(i=>String(i).trim()),e.sort((i,n)=>i.length-n.length),e=e.filter((i,n)=>{for(let a=n+1;a<e.length;a++)if(e[a].includes(i))return!1;return!0});let r=e.join(" | ");r!==this._attribHTML&&(this._attribHTML=r,e.length?(this._innerContainer.innerHTML=Ut.sanitize(r),this._container.classList.remove("maplibregl-attrib-empty")):this._container.classList.add("maplibregl-attrib-empty"),this._updateCompact(),this._editLink=null)}},$7e=class{constructor(e={}){this._updateCompact=()=>{let t=this._container.children;if(t.length){let r=t[0];this._map.getCanvasContainer().offsetWidth<=640||this._compact?this._compact!==!1&&r.classList.add("maplibregl-compact"):r.classList.remove("maplibregl-compact")}},this.options=e}getDefaultPosition(){return"bottom-left"}onAdd(e){var r;this._map=e,this._compact=(r=this.options)==null?void 0:r.compact,this._container=Ut.create("div","maplibregl-ctrl");let t=Ut.create("a","maplibregl-ctrl-logo");return t.target="_blank",t.rel="noopener nofollow",t.href="https://maplibre.org/",t.setAttribute("aria-label",this._map._getUIString("LogoControl.Title")),t.setAttribute("rel","noopener nofollow"),this._container.appendChild(t),this._container.style.display="block",this._map.on("resize",this._updateCompact),this._updateCompact(),this._container}onRemove(){this._container.remove(),this._map.off("resize",this._updateCompact),this._map=void 0,this._compact=void 0}},S7e=class{constructor(){this._queue=[],this._id=0,this._cleared=!1,this._currentlyRunning=!1}add(e){let t=++this._id;return this._queue.push({callback:e,id:t,cancelled:!1}),t}remove(e){let t=this._currentlyRunning,r=t?this._queue.concat(t):this._queue;for(let i of r)if(i.id===e){i.cancelled=!0;return}}run(e=0){if(this._currentlyRunning)throw Error("Attempting to run(), but is already running.");let t=this._currentlyRunning=this._queue;this._queue=[];for(let r of t)if(!r.cancelled&&(r.callback(e),this._cleared))break;this._cleared=!1,this._currentlyRunning=!1}clear(){this._currentlyRunning&&(this._cleared=!0),this._queue=[]}};const T7e=Ar([{name:"a_pos3d",type:"Int16",components:3}]);var C7e=class extends Rn{constructor(e){super(),this._lastTilesetChange=tr(),this.tileManager=e,this._tiles={},this._renderableTilesKeys=[],this._sourceTileCache={},this.minzoom=0,this.maxzoom=22,this.deltaZoom=1,this.tileSize=e._source.tileSize*2**this.deltaZoom,e.usedForTerrain=!0,e.tileSize=this.tileSize}destruct(){this.tileManager.usedForTerrain=!1,this.tileManager.tileSize=null,this.releaseAllRTT()}getSource(){return this.tileManager._source}update(e,t){this.tileManager.update(e,t),this._renderableTilesKeys=[];let r={};for(let i of af(e,{tileSize:this.tileSize,minzoom:this.minzoom,maxzoom:this.maxzoom,reparseOverscaled:!1,terrain:t,calculateTileZoom:this.tileManager._source.calculateTileZoom}))r[i.key]=!0,this._renderableTilesKeys.push(i.key),this._tiles[i.key]||(i.terrainRttPosMatrix32f=new Float32Array(16),qs(i.terrainRttPosMatrix32f,0,ye,ye,0,0,1),this._tiles[i.key]=new AF(i,this.tileSize),this._lastTilesetChange=tr());for(let i in this._tiles)r[i]||(this._tiles[i].releaseRTT(this.tileManager.map.painter),delete this._tiles[i])}releaseRTT(e){for(let t in this._tiles){let r=this._tiles[t];(r.tileID.equals(e)||r.tileID.isChildOf(e)||e.isChildOf(r.tileID))&&r.releaseRTT(this.tileManager.map.painter)}}releaseAllRTT(){for(let e in this._tiles)this._tiles[e].releaseRTT(this.tileManager.map.painter)}getRenderableTiles(){return this._renderableTilesKeys.map(e=>this.getTileByID(e))}getTileByID(e){return this._tiles[e]}getTerrainCoords(e,t){return t?this._getTerrainCoordsForTileRanges(e,t):this._getTerrainCoordsForRegularTile(e)}_getTerrainCoordsForRegularTile(e){let t={};for(let r of this._renderableTilesKeys){let i=this._tiles[r].tileID,n=e.clone(),a=Uu();if(i.canonical.equals(e.canonical))qs(a,0,ye,ye,0,0,1);else if(i.canonical.isChildOf(e.canonical)){let s=i.canonical.z-e.canonical.z,o=i.canonical.x-(i.canonical.x>>s<<s),l=i.canonical.y-(i.canonical.y>>s<<s),u=ye>>s;qs(a,0,u,u,0,0,1),ei(a,a,[-o*u,-l*u,0])}else if(e.canonical.isChildOf(i.canonical)){let s=e.canonical.z-i.canonical.z,o=e.canonical.x-(e.canonical.x>>s<<s),l=e.canonical.y-(e.canonical.y>>s<<s),u=ye>>s;qs(a,0,ye,ye,0,0,1),ei(a,a,[o*u,l*u,0]),Li(a,a,[1/2**s,1/2**s,0])}else continue;n.terrainRttPosMatrix32f=new Float32Array(a),t[r]=n}return t}_getTerrainCoordsForTileRanges(e,t){let r={};for(let i of this._renderableTilesKeys){let n=this._tiles[i].tileID;if(!this._isWithinTileRanges(n,t))continue;let a=e.clone(),s=Uu();if(n.canonical.z===e.canonical.z){let o=e.canonical.x-n.canonical.x+e.wrap*(1<<e.canonical.z),l=e.canonical.y-n.canonical.y;qs(s,0,ye,ye,0,0,1),ei(s,s,[o*ye,l*ye,0])}else if(n.canonical.z>e.canonical.z){let o=n.canonical.z-e.canonical.z,l=n.canonical.x-(n.canonical.x>>o<<o)+e.wrap*(1<<n.canonical.z),u=n.canonical.y-(n.canonical.y>>o<<o),c=e.canonical.x-(n.canonical.x>>o),d=e.canonical.y-(n.canonical.y>>o),h=ye>>o;qs(s,0,h,h,0,0,1),ei(s,s,[-l*h+c*ye,-u*h+d*ye,0])}else{let o=e.canonical.z-n.canonical.z,l=e.canonical.x-(e.canonical.x>>o<<o)+e.wrap*(1<<e.canonical.z),u=e.canonical.y-(e.canonical.y>>o<<o),c=(e.canonical.x>>o)-n.canonical.x,d=(e.canonical.y>>o)-n.canonical.y,h=ye<<o;qs(s,0,h,h,0,0,1),ei(s,s,[l*ye+c*h,u*ye+d*h,0])}a.terrainRttPosMatrix32f=new Float32Array(s),r[i]=a}return r}getSourceTile(e,t){var a,s;let r=this.tileManager._source,i=e.overscaledZ-this.deltaZoom;if(i>r.maxzoom&&(i=r.maxzoom),i<r.minzoom)return;(a=this._sourceTileCache)[s=e.key]||(a[s]=e.scaledTo(i).key);let n=this.findTileInCaches(this._sourceTileCache[e.key]);if(!(n!=null&&n.dem)&&t)for(;i>=r.minzoom&&!(n!=null&&n.dem);)n=this.findTileInCaches(e.scaledTo(i--).key);return n}findTileInCaches(e){let t=this.tileManager.getTileByID(e);return t||(t=this.tileManager._outOfViewCache.getByKey(e),t)}anyTilesAfterTime(e=tr()){return this._lastTilesetChange>=e}_isWithinTileRanges(e,t){let r=t[e.canonical.z];return!!r&&(e.wrap>r.minWrap||e.wrap<r.maxWrap||e.canonical.x>=r.minTileXWrapped&&e.canonical.x<=r.maxTileXWrapped&&e.canonical.y>=r.minTileY&&e.canonical.y<=r.maxTileY)}},k7e=class{constructor(e,t,r,i="auto"){this._meshCache={},this.painter=e,this.tileManager=new C7e(t),this.options=r,this.exaggeration=typeof r.exaggeration=="number"?r.exaggeration:1,this._terrainSkirtLength=i,this.qual
1546ityFactor=2,this.meshSize=128,this._demMatrixCache=new Map,this._elevationSamplerCache=new Map,this.coordsIndex=[],this._coordsTextureSize=1024}destroy(){this._fbo&&(this._fbo=(this._fbo.destroy(),null)),this._fboCoordsTexture&&(this._fboCoordsTexture=(this._fboCoordsTexture.destroy(),null)),this._fboDepthTexture&&(this._fboDepthTexture=(this._fboDepthTexture.destroy(),null)),this._emptyDemTexture&&(this._emptyDemTexture=(this._emptyDemTexture.destroy(),null)),this._emptyDepthTexture&&(this._emptyDepthTexture=(this._emptyDepthTexture.destroy(),null)),this._coordsTexture&&(this._coordsTexture=(this._coordsTexture.destroy(),null));for(let e in this._meshCache)this._meshCache[e].destroy();this._meshCache={},this.tileManager.destruct()}getDEMElevation(e,t,r,i=ye){let n=e.normalizeCoordinates(t,r,i);if(!n)return 0;let a=this._getElevationSampler(n.tileID);return a?a(n.x,n.y,i):0}getElevationForLngLatZoom(e,t){if(!A8(t,e.wrap()))return 0;let{tileID:r,mercatorX:i,mercatorY:n}=this._getOverscaledTileIDFromLngLatZoom(e,t);return this.getElevation(r,i%ye,n%ye,ye)}getElevationForLngLat(e,t){let r=af(t,{maxzoom:this.tileManager.maxzoom,minzoom:this.tileManager.minzoom,tileSize:512,terrain:this}),i=0;for(let n of r)n.canonical.z>i&&(i=Math.min(n.canonical.z,this.tileManager.maxzoom));return this.getElevationForLngLatZoom(e,i)}getElevation(e,t,r,i=ye){return this.getDEMElevation(e,t,r,i)*this.exaggeration}resetElevationCache(){this._elevationSamplerCache.clear()}_getElevationSampler(e){let t=e.key,r=this._elevationSamplerCache.get(t);if(r)return r;let i=this.tileManager.getSourceTile(e,!0),n=i==null?void 0:i.dem;if(!i||!n)return null;let a=this._getDEMTileMatrix(e,i),s=a[0]*n.dim,o=a[5]*n.dim,l=a[12]*n.dim,u=a[13]*n.dim,c=(d,h,f)=>{let p=f===8192?1:ye/f;return n.sampleBilinear(d*p*s+l,h*p*o+u)};return this._elevationSamplerCache.set(t,c),c}_getDEMTileMatrix(e,t){let r=`${t.tileID.key}/${e.key}`,i=this._demMatrixCache.get(r);if(i)return i;let n=this.tileManager.getSource().maxzoom,a=e.canonical.z-t.tileID.canonical.z;e.overscaledZ>e.canonical.z&&(e.canonical.z>=n?a=e.canonical.z-n:vr("cannot calculate elevation if elevation maxzoom > source.maxzoom"));let s=e.canonical.x-(e.canonical.x>>a<<a),o=e.canonical.y-(e.canonical.y>>a<<a),l=y$e(new Float64Array(16),[1/(ye<<a),1/(ye<<a),0]);return ei(l,l,[s*ye,o*ye,0]),this._demMatrixCache.set(r,l),l}getTerrainData(e){var i,n;if(!this._emptyDemTexture){let a=this.painter.context,s=new _r({width:1,height:1},new Uint8Array(4));this._emptyDepthTexture=new Hr(a,s,a.gl.RGBA,{premultiply:!1}),this._emptyDemUnpack=[0,0,0,0],this._emptyDemTexture=new Hr(a,new _r({width:1,height:1}),a.gl.RGBA,{premultiply:!1}),this._emptyDemTexture.bind(a.gl.NEAREST,a.gl.CLAMP_TO_EDGE),this._emptyDemMatrix=Ms([])}let t=this.tileManager.getSourceTile(e,!0);if(t!=null&&t.dem&&(!t.demTexture||t.needsTerrainPrepare)){let a=this.painter.context;t.demTexture||(t.demTexture=this.painter.getTileTexture(t.dem.stride)),t.demTexture?t.demTexture.update(t.dem.getPixels(),{premultiply:!1}):t.demTexture=new Hr(a,t.dem.getPixels(),a.gl.RGBA,{premultiply:!1}),t.demTexture.bind(a.gl.NEAREST,a.gl.CLAMP_TO_EDGE),t.needsTerrainPrepare=!1}let r=t?this._getDEMTileMatrix(e,t):this._emptyDemMatrix;return{u_depth:2,u_terrain:3,u_terrain_dim:((i=t==null?void 0:t.dem)==null?void 0:i.dim)||1,u_terrain_matrix:r,u_terrain_unpack:((n=t==null?void 0:t.dem)==null?void 0:n.getUnpackVector())||this._emptyDemUnpack,u_terrain_exaggeration:this.exaggeration,texture:((t==null?void 0:t.demTexture)||this._emptyDemTexture).texture,depthTexture:(this._fboDepthTexture||this._emptyDepthTexture).texture,tile:t}}getFramebuffer(e){let t=this.painter,r=t.width/devicePixelRatio,i=t.height/devicePixelRatio;return this._fbo&&(this._fbo.width!==r||this._fbo.height!==i)&&(this._fbo.destroy(),this._fboCoordsTexture.destroy(),this._fboDepthTexture.destroy(),delete this._fbo,delete this._fboDepthTexture,delete this._fboCoordsTexture),this._fboCoordsTexture||(this._fboCoordsTexture=new Hr(t.context,{width:r,height:i,data:null},t.context.gl.RGBA,{premultiply:!1}),this._fboCoordsTexture.bind(t.context.gl.NEAREST,t.context.gl.CLAMP_TO_EDGE)),this._fboDepthTexture||(this._fboDepthTexture=new Hr(t.context,{width:r,height:i,data:null},t.context.gl.RGBA,{premultiply:!1}),this._fboDepthTexture.bind(t.context.gl.NEAREST,t.context.gl.CLAMP_TO_EDGE)),this._fbo||(this._fbo=t.context.createFramebuffer(r,i,!0,!1),this._fbo.depthAttachment.set(t.context.createRenderbuffer(t.context.gl.DEPTH_COMPONENT16,r,i))),this._fbo.colorAttachment.set(e==="coords"?this._fboCoordsTexture.texture:this._fboDepthTexture.texture),this._fbo}getCoordsTexture(){let e=this.painter.context;if(this._coordsTexture)return this._coordsTexture;let t=new Uint8Array(this._coordsTextureSize*this._coordsTextureSize*4);for(let n=0,a=0;n<this._coordsTextureSize;n++)for(let s=0;s<this._coordsTextureSize;s++,a+=4)t[a+0]=s&255,t[a+1]=n&255,t[a+2]=s>>8<<4|n>>8,t[a+3]=0;let r=new _r({width:this._coordsTextureSize,height:this._coordsTextureSize},new Uint8Array(t.buffer)),i=new Hr(e,r,e.gl.RGBA,{premultiply:!1});return i.bind(e.gl.NEAREST,e.gl.CLAMP_TO_EDGE),this._coordsTexture=i,i}pointCoordinate(e){this.painter.maybeDrawDepth(!0),this.painter.maybeDrawCoords();let t=new Uint8Array(4),r=this.painter.context,i=r.gl,n=Math.round(e.x*this.painter.pixelRatio/devicePixelRatio),a=Math.round(e.y*this.painter.pixelRatio/devicePixelRatio),s=Math.round(this.painter.height/devicePixelRatio);r.bindFramebuffer.set(this.getFramebuffer("coords").framebuffer),i.readPixels(n,s-a-1,1,1,i.RGBA,i.UNSIGNED_BYTE,t),r.bindFramebuffer.set(null);let o=t[0]+(t[2]>>4<<8),l=t[1]+((t[2]&15)<<8),u=this.coordsIndex[255-t[3]],c=u&&this.tileManager.getTileByID(u);if(!c)return null;let d=this._coordsTextureSize,h=(1<<c.tileID.canonical.z)*d;return new nr((c.tileID.canonical.x*d+o)/h+c.tileID.wrap,(c.tileID.canonical.y*d+l)/h,this.getElevation(c.tileID,o,l,d))}depthAtPoint(e){let t=new Uint8Array(4),r=this.painter.context,i=r.gl;return r.bindFramebuffer.set(this.getFramebuffer("depth").framebuffer),i.readPixels(e.x,this.painter.height/devicePixelRatio-e.y-1,1,1,i.RGBA,i.UNSIGNED_BYTE,t),r.bindFramebuffer.set(null),(t[0]/16777216+t[1]/65536+t[2]/256+t[3])/256}getTerrainMesh(e){var h;let t=((h=this.painter.style.projection)==null?void 0:h.transitionState)>0,r=t&&e.canonical.y===0,i=t&&e.canonical.y===(1<<e.canonical.z)-1,n=`m_${r?"n":""}_${i?"s":""}`;if(this._meshCache[n])return this._meshCache[n];let a=this.painter.context,s=new LTe,o=new go,l=this.meshSize,u=ye/l,c=l*l;for(let f=0;f<=l;f++)for(let p=0;p<=l;p++)s.emplaceBack(p*u,f*u,0);for(let f=0;f<c;f+=l+1)for(let p=0;p<l;p++)o.emplaceBack(p+f,l+p+f+1,l+p+f+2),o.emplaceBack(p+f,l+p+f+2,p+f+1);this._terrainSkirtLength!=="none"&&this._buildSkirts(s,o,l,u,r,i);let d=new wg(a.createVertexBuffer(s,T7e.members),a.createIndexBuffer(o),$r.simpleSegment(0,0,s.length,o.length));return this._meshCache[n]=d,d}getSkirtLength(e){return 2*Math.PI*Ql/2**Math.max(e,0)/5}getMinTileElevationForLngLatZoom(e,t){if(!A8(t,e.wrap()))return 0;let{tileID:r}=this._getOverscaledTileIDFromLngLatZoom(e,t);return this.getMinMaxElevation(r).minElevation??0}getMinMaxElevation(e){let t=this.tileManager.getSourceTile(e,!0),r={minElevation:null,maxElevation:null};return t!=null&&t.dem&&(r.minElevation=t.dem.min*this.exaggeration,r.maxElevation=t.dem.max*this.exaggeration),r}_getOverscaledTileIDFromLngLatZoom(e,t){let r=nr.fromLngLat(e.wrap()),i=(1<<t)*ye,n=r.x*i,a=r.y*i,s=Math.floor(n/ye),o=Math.floor(a/ye);return{tileID:new Ri(t,0,t,s,o),mercatorX:n,mercatorY:a}}_buildSkirts(e,t,r,i,n,a){let s=e.length,o=s+(r+1),l=(r+1)*r,u=n?Dp:0,c=+!n,d=a?Rp:ye,h=+!a;for(let m=0;m<=r;m++)e.emplaceBack(m*i,u,c);for(let m=0;m<=r;m++)e.emplaceBack(m*i,d,h);for(let m=0;m<r;m++)t.emplaceBack(l+m,o+m,o+m+1),t.emplaceBack(l+m,o+m+1,l+m+1),t.emplaceBack(0+m,s+m+1,s+m),t.emplaceBack(0+m,0+m+1,s+m+1);let f=e.length,p=f+(r+1)*2;for(let m of[0,1])for(let g=0;g<=r;g++)for(let v of[0,1])e.emplaceBack(m*ye,g*i,v);for(let m=0;m<r*2;m+=2)t.emplaceBack(f+m,f+m+1,f+m+3),t.emplaceBack(f+m,f+m+3,f+m+2),t.emplaceBack(p+m,p+m+3,p+m+1),t.emplaceBack(p+m,p+m+2,p+m+3)}};const td={background:!0,fill:!0,line:!0,raster:!0,hillshade:!0,"color-relief":!0};var E7e=class{constructor(e,t){this.painter=e,this.terrain=t,this.rttSize=t.tileManager.tileSize*t.qualityFactor}getTexture(e){return e.getRTT(this._stacks.length-1).texture}
1546prepareForRender(e,t){this._stacks=[],this._prevType=null,this._rttTiles=[],this._renderableTiles=this.terrain.tileManager.getRenderableTiles(),this._renderableLayerIds=e._order.filter(i=>!e._layers[i].isHidden(t));let r=new Set;for(let i of this._renderableLayerIds){let n=e._layers[i],a=n.source;a&&td[n.type]&&r.add(a)}this._coordsAscending={},this._rttFingerprints={};for(let i of r){let n=e.tileManagers[i];if(!n)continue;this._coordsAscending[i]={};let a=this._coordsAscending[i],s=n.getSource(),o=s instanceof xg?s.terrainTileRanges:null;for(let c of n.getVisibleCoordinates()){let d=this.terrain.tileManager.getTerrainCoords(c,o);for(let h in d)a[h]||(a[h]=[]),a[h].push(d[h])}this._rttFingerprints[i]={};let l=this._rttFingerprints[i],u=n.getState().revision;for(let c in a)l[c]=`${a[c].map(d=>d.key).sort().join()}#${u}`}for(let i of this._renderableTiles)for(let n in this._rttFingerprints){let a=this._rttFingerprints[n][i.tileID.key];a&&a!==i.rttFingerprint[n]&&i.releaseRTT(this.painter)}}renderLayer(e,t){if(e.isHidden(this.painter.transform.zoom))return!1;let r={...t,isRenderingToTexture:!0},i=e.type,n=this.painter,a=this._renderableLayerIds[this._renderableLayerIds.length-1]===e.id;if(td[i]&&((!this._prevType||!td[this._prevType])&&this._stacks.push([]),this._prevType=i,this._stacks[this._stacks.length-1].push(e.id),!a))return!0;if(td[this._prevType]||td[i]&&a){this._prevType=i;let s=this._stacks.length-1,o=this._stacks[s]||[];for(let l of this._renderableTiles){if(this._rttTiles.push(l),l.getRTT(s))continue;let u=l.acquireRTT(n,s,this.rttSize);n.bindRTT(u),n.context.clear({color:at.transparent,stencil:0}),n.currentStencilSource=void 0;for(let c of o){let d=n.style._layers[c],h=d.source?this._coordsAscending[d.source][l.tileID.key]:[l.tileID];n.context.viewport.set([0,0,this.rttSize,this.rttSize]),n.renderTileClippingMasks(d,h,!0),n.renderLayer(n,n.style.tileManagers[d.source],d,h,r),d.source&&(l.rttFingerprint[d.source]=this._rttFingerprints[d.source][l.tileID.key])}}return MDe(this.painter,this.terrain,this._rttTiles,r),this._rttTiles=[],td[i]}return!1}};const P7e={"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":"MapLibre logo","Map.Title":"Map","Marker.Title":"Map marker","NavigationControl.ResetBearing":"Drag to rotate map, click to reset north","NavigationControl.ZoomIn":"Zoom in","NavigationControl.ZoomOut":"Zoom out","Popup.Close":"Close popup","ScaleControl.Feet":"ft","ScaleControl.Meters":"m","ScaleControl.Kilometers":"km","ScaleControl.Miles":"mi","ScaleControl.NauticalMiles":"nm","GlobeControl.Enable":"Enable globe","GlobeControl.Disable":"Disable globe","TerrainControl.Enable":"Enable terrain","TerrainControl.Disable":"Disable terrain","CooperativeGesturesHandler.WindowsHelpText":"Use Ctrl + scroll to zoom the map","CooperativeGesturesHandler.MacHelpText":"Use â + scroll to zoom the map","CooperativeGesturesHandler.MobileHelpText":"Use two fingers to move the map"},M7e=CPe,GE={hash:!1,interactive:!0,bearingSnap:7,zoomSnap:0,attributionControl:bz,maplibreLogo:!1,refreshExpiredTiles:!0,canvasContextAttributes:{antialias:!1,preserveDrawingBuffer:!1,powerPreference:"high-performance",failIfMajorPerformanceCaveat:!1,desynchronized:!1,contextType:void 0},scrollZoom:!0,minZoom:-2,maxZoom:22,minPitch:0,maxPitch:60,boxZoom:!0,dragRotate:!0,dragPan:!0,keyboard:!0,doubleClickZoom:!0,touchZoomRotate:!0,touchPitch:!0,cooperativeGestures:!1,trackResize:!0,center:[0,0],elevation:0,zoom:0,bearing:0,pitch:0,roll:0,renderWorldCopies:!0,maxTileCacheSize:null,maxTileCacheZoomLevels:cl.MAX_TILE_CACHE_ZOOM_LEVELS,transformRequest:null,transformCameraUpdate:null,transformConstrain:null,fadeDuration:300,crossSourceCollisions:!0,clickTolerance:3,localIdeographFontFamily:"sans-serif",pitchWithRotate:!0,rollEnabled:!1,rotateSpeed:.8,pitchSpeed:-.5,reduceMotion:void 0,validateStyle:!0,maxCanvasSize:[4096,4096],cancelPendingTileRequestsWhileZooming:!0,centerClampedToGroun
1546d:!0,terrainSkirtLength:"auto",zoomLevelsToOverscale:4,anisotropicFilterPitch:20};var I7e=class extends Rn{get _ownerWindow(){var e,t;return((t=(e=this._container)==null?void 0:e.ownerDocument)==null?void 0:t.defaultView)||window}constructor(e){var n,a,s;super(),this._idleTriggered=!1,this._crossFadingFactor=1,this._renderTaskQueue=new S7e,this._controls=[],this._mapId=wR(),this._missingStyleImageResolver=null,this._lostContextStyle={style:null,images:null},this._contextLost=o=>{if(o.preventDefault(),this._frameRequest&&(this._frameRequest=(this._frameRequest.abort(),null)),this.painter.destroy(),this._lostContextStyle=this._getStyleAndImages(),!this.style){this.fire(new Vb("webglcontextlost",{originalEvent:o}));return}for(let l of Object.values(this.style._layers))if(l.type==="custom"&&console.warn(`Custom layer with id '${l.id}' cannot be restored after WebGL context loss. You will need to re-add it manually after context restoration.`),l._listeners)for(let[u]of Object.entries(l._listeners))console.warn(`Custom layer with id '${l.id}' had event listeners for event '${u}' which cannot be restored after WebGL context loss. You will need to re-add them manually after context restoration.`);this.style.destroy(),this.style=null,this.fire(new Vb("webglcontextlost",{originalEvent:o}))},this._contextRestored=o=>{this._lostContextStyle.style&&this.setStyle(this._lostContextStyle.style,{diff:!1}),this._lostContextStyle.images&&this.style&&(this.style.imageManager.images=this._lostContextStyle.images),this._lostContextStyle={style:null,images:null},this._setupPainter(),this.painter&&(this.resize(),this._update(),this._resizeInternal(),this.fire(new Vb("webglcontextrestored",{originalEvent:o})))},this._onMapScroll=o=>{if(o.target===this._container)return this._container.scrollTop=0,this._container.scrollLeft=0,!1},this._onWindowOnline=()=>{this._update()};let t={...GE,...e,canvasContextAttributes:{...GE.canvasContextAttributes,...e.canvasContextAttributes}};if(t.minZoom!=null&&t.maxZoom!=null&&t.minZoom>t.maxZoom)throw Error("maxZoom must be greater than or equal to minZoom");if(t.minPitch!=null&&t.maxPitch!=null&&t.minPitch>t.maxPitch)throw Error("maxPitch must be greater than or equal to minPitch");if(t.minPitch!=null&&t.minPitch<0)throw Error("minPitch must be greater than or equal to 0");if(t.maxPitch!=null&&t.maxPitch>180)throw Error("maxPitch must be less than or equal to 180");if(this._camera=new w7e({minZoom:t.minZoom,maxZoom:t.maxZoom,minPitch:t.minPitch,maxPitch:t.maxPitch,bearingSnap:t.bearingSnap,zoomSnap:t.zoomSnap,renderWorldCopies:t.renderWorldCopies,centerClampedToGround:t.centerClampedToGround,terrain:this.terrain,transformConstrain:t.transformConstrain,requestRenderFrame:o=>this._requestRenderFrame(o),cancelRenderFrame:o=>this._cancelRenderFrame(o),transformCameraUpdate:t.transformCameraUpdate,stopHandlers:()=>{var o;return(o=this._handlers)==null?void 0:o.stop(!1)}}),this._camera.setEventedParent(this),this._interactive=t.interactive,this._maxTileCacheSize=t.maxTileCacheSize,this._maxTileCacheZoomLevels=t.maxTileCacheZoomLevels,this._canvasContextAttributes={...t.canvasContextAttributes},this._trackResize=t.trackResize===!0,this._terrainSkirtLength=t.terrainSkirtLength,this._refreshExpiredTiles=t.refreshExpiredTiles===!0,this._fadeDuration=t.fadeDuration,this._crossSourceCollisions=t.crossSourceCollisions===!0,this._collectResourceTiming=t.collectResourceTiming===!0,this._locale={...P7e,...t.locale},this._clickTolerance=t.clickTolerance,this._overridePixelRatio=t.pixelRatio,this._maxCanvasSize=t.maxCanvasSize,this._zoomLevelsToOverscale=t.zoomLevelsToOverscale,this.cancelPendingTileRequestsWhileZooming=t.cancelPendingTileRequestsWhileZooming===!0,this.setAnisotropicFilterPitch(t.anisotropicFilterPitch),t.reduceMotion!==void 0&&(qn.prefersReducedMotion=t.reduceMotion),this._imageQueueHandle=Zo.addThrottleControl(()=>this.isMoving()),this._requestManager=new MPe(t.transformRequest),this._container=this._resolveContainer(t.container),t.maxBounds&&this.setMaxBounds(t.maxBounds),this._setupContainer(),this._setupPainter(),!this.painter)return;this.on("move",()=>this._update(!1)),this.on("moveend",()=>this._update(!1)),this.on("zoom",()=>this._update(!0)),this.on("terrain",()=>{this.painter.terrainFacilitator.depthDirty=!0,this._update(!0)}),this.once("idle",()=>this._idleTriggered=!0),this._handlers=new x7e(this,this._camera,t),typeof window<"u"&&(this._ownerWindow.addEventListener("online",this._onWindowOnline,!1),this._setupResizeObserver());let r=typeof t.hash=="string"&&t.hash||void 0;this._hash=t.hash?new FDe(r).addTo(this):void 0,(n=this._hash)!=null&&n._onHashChange()||(this.jumpTo({center:t.center,elevation:t.elevation,zoom:t.zoom,bearing:t.bearing,pitch:t.pitch,roll:t.roll}),t.bounds&&(this.resize(),this.fitBounds(t.bounds,Ne({},t.fitBoundsOptions,{duration:0}))));let i=typeof t.style=="string"||((s=(a=t.style)==null?void 0:a.projection)==null?void 0:s.type)!=="globe";this.resize(null,i),this._localIdeographFontFamily=t.localIdeographFontFamily,this._val
vendor: 16,223 bytes, line 1546
1546idateStyle=t.validateStyle,t.style&&this.setStyle(t.style,{localIdeographFontFamily:t.localIdeographFontFamily}),t.attributionControl&&this.addControl(new xz(typeof t.attributionControl=="boolean"?void 0:t.attributionControl)),t.maplibreLogo&&this.addControl(new $7e,t.logoPosition),this.on("style.load",()=>{if(i||this._resizeTransform(),this._camera.transform.unmodified){let o=og(this.style.stylesheet,["center","zoom","bearing","pitch","roll"]);this.jumpTo(o)}}),this.on("data",o=>{this._update(o.dataType==="style"),this.fire(o.dataType==="style"?new ms("styledata",o):new yr("sourcedata",o))}),this.on("dataloading",o=>{this.fire(o.dataType==="style"?new ms("styledataloading",o):new yr("sourcedataloading",o))}),this.on("dataabort",o=>{this.fire(new yr("sourcedataabort",o))})}_getMapId(){return this._mapId}setGlobalStateProperty(e,t){return this.style.setGlobalStateProperty(e,t),this._update(!0)}getGlobalState(){return this.style.getGlobalState()}addControl(e,t){if(t===void 0&&(t=e.getDefaultPosition?e.getDefaultPosition():"top-right"),!(e!=null&&e.onAdd))return this.fire(new He(Error("Invalid argument to map.addControl(). Argument must be a control with onAdd and onRemove methods.")));let r=e.onAdd(this);this._controls.push(e);let i=this._controlPositions[t];return t.includes("bottom")?i.insertBefore(r,i.firstChild):i.appendChild(r),this}removeControl(e){if(!(e!=null&&e.onRemove))return this.fire(new He(Error("Invalid argument to map.removeControl(). Argument must be a control with onAdd and onRemove methods.")));let t=this._controls.indexOf(e);return t>-1&&this._controls.splice(t,1),e.onRemove(this),this}hasControl(e){return this._controls.includes(e)}coveringTiles(e){return af(this._camera.transform,e)}setTransformCameraUpdate(e){this._camera.transformCameraUpdate=e}getCenter(){return new rt(this._camera.transform.center.lng,this._camera.transform.center.lat)}setCenter(e,t){return this._camera.setCenter(e,t),this}getCenterElevation(){return this._camera.transform.elevation}setCenterElevation(e,t){return this._camera.setCenterElevation(e,t),this}setCenterClampedToGround(e){this._camera.setCenterClampedToGround(e)}panBy(e,t,r){return this._camera.panBy(e,t,r),this}panTo(e,t,r){return this._camera.panTo(e,t,r),this}getZoom(){return this._camera.transform.zoom}setZoom(e,t){return this._camera.setZoom(e,t),this}zoomTo(e,t,r){return this._camera.zoomTo(e,t,r),this}zoomIn(e,t){return this._camera.zoomIn(e,t),this}zoomOut(e,t){return this._camera.zoomOut(e,t),this}getVerticalFieldOfView(){return this._camera.transform.fov}setVerticalFieldOfView(e,t){return this._camera.setVerticalFieldOfView(e,t),this}getBearing(){return this._camera.transform.bearing}setBearing(e,t){return this._camera.setBearing(e,t),this}getZoomSnap(){return this._camera.getZoomSnap()}setZoomSnap(e){return this._camera.setZoomSnap(e),this}getPadding(){return this._camera.transform.padding}setPadding(e,t){return this._camera.setPadding(e,t),this}rotateTo(e,t,r){return this._camera.rotateTo(e,t,r),this}resetNorth(e,t){return this._camera.resetNorth(e,t),this}resetNorthPitch(e,t){return this._camera.resetNorthPitch(e,t),this}snapToNorth(e,t){return this._camera.snapToNorth(e,t),this}getPitch(){return this._camera.transform.pitch}setPitch(e,t){return this._camera.setPitch(e,t),this}getRoll(){return this._camera.transform.roll}setRoll(e,t){return this._camera.setRoll(e,t),this}cameraForBounds(e,t){return this._camera.cameraForBounds(e,t)}fitBounds(e,t,r){return this._camera.fitBounds(e,t,r),this}fitScreenCoordinates(e,t,r,i,n){return this._camera.fitScreenCoordinates(e,t,r,i,n),this}jumpTo(e,t){return this._camera.jumpTo(e,t),this}calculateCameraOptionsFromCameraLngLatAltRotation(e,t,r,i,n){return this._camera.calculateCameraOptionsFromCameraLngLatAltRotation(e,t,r,i,n)}easeTo(e,t){return this._camera.easeTo(e,t),this}flyTo(e,t){return this._camera.flyTo(e,t),this}stop(){return this._camera.stop(),this}queryTerrainElevation(e){return this.terrain?this.terrain.getElevationForLngLat(rt.convert(e),this._camera.transform):null}getCenterClampedToGround(){return this._camera.getCenterClampedToGround()}calculateCameraOptionsFromTo(e,t,r,i){return i==null&&this.terrain&&(i=this.terrain.getElevationForLngLat(r,this._camera.transform)),this._camera.calculateCameraOptionsFromTo(e,t,r,i)}resize(e,t=!0){if(this._lostContextStyle.style!==null)return this;this._resizeInternal(t);let r=!this._camera._moving;return r&&(this.stop(),this.fire(new Ve("movestart",e)).fire(new Ve("move",e))),this.fire(new Ei("resize",e)),r&&this.fire(new Ve("moveend",e)),this}_resizeInternal(e=!0){let[t,r]=this._containerDimensions(),i=this._getClampedPixelRatio(t,r);if(this._resizeCanvas(t,r,i),this.painter.resize(t,r,i),this.painter.overLimit()){let n=this.painter.context.gl;this._maxCanvasSize=[n.drawingBufferWidth,n.drawingBufferHeight];let a=this._getClampedPixelRatio(t,r);this._resizeCanvas(t,r,a),this.painter.resize(t,r,a)}this._resizeTransform(e)}_resizeTransform(e=!0){var i;let[t,r]=this._containerDimensions();this._camera.transform.resize(t,r,e),(i=this._camera._requestedCameraState)==null||i.resize(t,r,e)}_getClampedPixelRatio(e,t){let{0:r,1:i}=this._maxCanvasSize,n=this.getPixelRatio(),a=e*n,s=t*n,o=a>r?r/a:1,l=s>i?i/s:1;return Math.min(o,l)*n}getPixelRatio(){return this._overridePixelRatio??devicePixelRatio}setPixelRatio(e){this._overridePixelRatio=e,this.resize()}getBounds(){return this._camera.transform.getBounds()}getMaxBounds(){return this._camera.transform.getMaxBounds()}setMaxBounds(e){return this._camera.transform.setMaxBounds(co.convert(e)),this._update()}setMinZoom(e){if(e??(e=-2),e>=-2&&e<=this._camera.transform.maxZoom){let t=this._camera.transform.zoom,r=this._camera.getTransformForUpdate();return r.setMinZoom(e),this._camera.applyUpdatedTransform(r),this._update(),t!==this._camera.transform.zoom&&this.fire(new Ve("zoomstart")).fire(new Ve("zoom")).fire(new Ve("zoomend")).fire(new Ve("movestart")).fire(new Ve("move")).fire(new Ve("moveend")),this}throw Error("minZoom must be between -2 and the current maxZoom, inclusive")}getMinZoom(){return this._camera.transform.minZoom}setMaxZoom(e){if(e??(e=22),e>=this._camera.transform.minZoom){let t=this._camera.transform.zoom,r=this._camera.getTransformForUpdate();return r.setMaxZoom(e),this._camera.applyUpdatedTransform(r),this._update(),t!==this._camera.transform.zoom&&this.fire(new Ve("zoomstart")).fire(new Ve("zoom")).fire(new Ve("zoomend")).fire(new Ve("movestart")).fire(new Ve("move")).fire(new Ve("moveend")),this}throw Error("maxZoom must be greater than the current minZoom")}getMaxZoom(){return this._camera.transform.maxZoom}setMinPitch(e){if(e??(e=0),e<0)throw Error("minPitch must be greater than or equal to 0");if(e>=0&&e<=this._camera.transform.maxPitch){let t=this._camera.transform.pitch,r=this._camera.getTransformForUpdate();return r.setMinPitch(e),this._camera.applyUpdatedTransform(r),this._update(),t!==this._camera.transform.pitch&&this.fire(new Ve("pitchstart")).fire(new Ve("pitch")).fire(new Ve("pitchend")).fire(new Ve("movestart")).fire(new Ve("move")).fire(new Ve("moveend")),this}throw Error("minPitch must be between 0 and the current maxPitch, inclusive")}getMinPitch(){return this._camera.transform.minPitch}setMaxPitch(e){if(e??(e=60),e>180)throw Error("maxPitch must be less than or equal to 180");if(e>=this._camera.transform.minPitch){let t=this._camera.transform.pitch,r=this._camera.getTransformForUpdate();return r.setMaxPitch(e),this._camera.applyUpdatedTransform(r),this._update(),t!==this._camera.transform.pitch&&this.fire(new Ve("pitchstart")).fire(new Ve("pitch")).fire(new Ve("pitchend")).fire(new Ve("movestart")).fire(new Ve("move")).fire(new Ve("moveend")),this}throw Error("maxPitch must be greater than the current minPitch")}getMaxPitch(){return this._camera.transform.maxPitch}getAnisotropicFilterPitch(){return this._anisotropicFilterPitch}setAnisotropicFilterPitch(e){if(e??(e=20),e>180)throw Error("anisotropicFilterPitch must be less than or equal to 180");if(e<0)throw Error("anisotropicFilterPitch must be greater than or equal to 0");return this._anisotropicFilterPitch=e,this._update()}getRenderWorldCopies(){return this._camera.transform.renderWorldCopies}setRenderWorldCopies(e){return this._camera.transform.setRenderWorldCopies(e),this._update()}setTransformConstrain(e){return this._camera.transform.setConstrainOverride(e),this._update()}project(e){return this._camera.transform.locationToScreenPoint(rt.convert(e),this.style&&this.terrain)}unproject(e){return this._camera.transform.screenPointToLocation(de.convert(e),this.terrain)}isMoving(){var e;return this._camera.isMoving()||((e=this._handlers)==null?void 0:e.isMoving())||!1}isZooming(){var e;return this._camera.isZooming()||((e=this._handlers)==null?void 0:e.isZooming())||!1}isRotating(){var e;return this._camera.isRotating()||((e=this._handlers)==null?void 0:e.isRotating())||!1}_createDelegatedListener(e,t,r){if(e==="mouseenter"||e==="mouseover"){let i=!1;return{layers:t,listener:r,delegates:{mousemove:n=>{let a=t.filter(o=>this.getLayer(o)),s=a.length===0?[]:this.queryRenderedFeatures(n.point,{layers:a});s.length?i||(i=!0,r.call(this,new Va(e,this,n.originalEvent,{features:s}))):i=!1},mouseout:()=>{i=!1}}}}if(e==="mouseleave"||e==="mouseout"){let i=!1;return{layers:t,listener:r,delegates:{mousemove:n=>{let a=t.filter(s=>this.getLayer(s));(a.length===0?[]:this.queryRenderedFeatures(n.point,{layers:a})).length?i=!0:i&&(i=!1,r.call(this,new Va(e,this,n.originalEvent)))},mouseout:n=>{i&&(i=!1,r.call(this,new Va(e,this,n.originalEvent)))}}}}{let i=n=>{let a=t.filter(o=>this.getLayer(o)),s=a.length===0?[]:this.queryRenderedFeatures(n.point,{layers:a});s.length&&(n.features=s,r.call(this,n),delete n.features)};return{layers:t,listener:r,delegates:{[e]:i}}}}_saveDelegatedListener(e,t){var r;this._delegatedListeners||(this._delegatedListeners={}),(r=this._delegatedListeners)[e]||(r[e]=[]),this._delegatedListeners[e].push(t)}_removeDelegatedListener(e,t,r){var n;if(!((n=this._delegatedListeners)!=null&&n[e]))return;let i=this._delegatedListeners[e];for(let a=0;a<i.length;a++){let s=i[a];if(s.listener===r&&s.layers.length===t.length&&s.layers.every(o=>t.includes(o))){for(let o in s.delegates)this.off(o,s.delegates[o]);i.splice(a,1);return}}}on(e,t,r){if(r===void 0)return super.on(e,t);let i=typeof t=="string"?[t]:t,n=this._createDelegatedListener(e,i,r);this._saveDelegatedListener(e,n);for(let a in n.delegates)this.on(a,n.delegates[a]);return{unsubscribe:()=>{this._removeDelegatedListener(e,i,r)}}}once(e,t,r){if(r===void 0)return super.once(e,t);let i=typeof t=="string"?[t]:t,n=this._createDelegatedListener(e,i,r);for(let a in n.delegates){let s=n.delegates[a];n.delegates[a]=(...o)=>{this._removeDelegatedListener(e,i,r),s(...o)}}this._saveDelegatedListener(e,n);for(let a in n.delegates)this.once(a,n.delegates[a]);return this}off(e,t,r){if(r===void 0)return super.off(e,t);let i=typeof t=="string"?[t]:t;return this._removeDelegatedListener(e,i,r),this}queryRenderedFeatures(e,t){if(!this.style)return[];let r,i=e instanceof de||Array.isArray(e),n=i?e:[[0,0],[this._camera.transform.width,this._camera.transform.height]];if(t||(t=(i?{}:e)||{}),n instanceof de||typeof n[0]=="number")r=[de.convert(n)];else{let a=de.convert(n[0]),s=de.convert(n[1]);r=[a,new de(s.x,a.y),s,new de(a.x,s.y),a]}return this.style.queryRenderedFeatures(r,t,this._camera.transform)}querySourceFeatures(e,t){return this.style.querySourceFeatures(e,t)}setStyle(e,t){return t=Ne({},{localIdeographFontFamily:this._localIdeographFontFamily,validate:this._validateStyle},t),t.diff!==!1&&t.localIdeographFontFamily===this._localIdeographFontFamily&&this.style&&e?(this._diffStyle(e,t),this):(this._localIdeographFontFamily=t.localIdeographFontFamily,this._updateStyle(e,t))}setTransformRequest(e){return this._requestManager.setTransformRequest(e),this}_getUIString(e){let t=this._locale[e];if(t==null)throw Error(`Missing UI string '${e}'`);return t}_updateStyle(e,t){var i,n,a;if((i=this._diffStyleRequest)==null||i.abort(),this._diffStyleRequest=null,t.transformStyle&&this.style&&!this.style._loaded){this.style.once("style.load",()=>this._updateStyle(e,t));return}let r=this.style&&t.transformStyle?this.style.serialize():void 0;if(this.style&&(this.style.setEventedParent(null),this.style._remove(!e)),e)this.style=new PE(this,t||{});else return this._frameRequest&&(this._frameRequest=(this._frameRequest.abort(),null)),(a=(n=this.style)==null?void 0:n.projection)==null||a.destroy(),delete this.style,this;return this.style.setEventedParent(this,{style:this.style}),typeof e=="string"?this.style.loadURL(e,t,r):this.style.loadJSON(e,t,r),this}_lazyInitEmptyStyle(){this.style||(this.style=new PE(this,{}),this.style.setEventedParent(this,{style:this.style}),this.style.loadEmpty())}async _diffStyle(e,t){var r;if((r=this._diffStyleRequest)==null||r.abort(),typeof e=="string"){let i=e;this._diffStyleRequest=new AbortController;let n=this._diffStyleRequest;try{let a=await this._requestManager.transformRequest(i,"Style");if(n.signal.aborted){this._diffStyleRequest=null;return}let s=await H1(a,n);this._diffStyleRequest=null,this._updateDiff(s.data,t)}catch(a){this._diffStyleRequest=null,uu(a)||this.fire(new He(mn(a)))}}else typeof e=="object"&&(this._diffStyleRequest=null,this._updateDiff(e,t))}_updateDiff(e,t){try{this.style.setState(e,t)&&this._update(!0)}catch(r){vr(`Unable to perform style diff: ${mn(r).message}. Rebuilding the style from scratch.`),this._updateStyle(e,t)}}getStyle(){if(this.style)return this.style.serialize()}_getStyleAndImages(){return this.style?{style:this.style.serialize(),images:this.style.imageManager.cloneImages()}:{style:null,images:{}}}isStyleLoaded(){if(!this.style){vr("There is no style added to the map.");return}return this.style.loaded()}addSource(e,t){return this._lazyInitEmptyStyle(),this.style.addSource(e,t),this._update(!0)}isSourceLoaded(e){var r;let t=(r=this.style)==null?void 0:r.tileManagers[e];if(t===void 0){this.fire(new He(Error(`There is no tile manager with ID '${e}'`)));return}return t.loaded()}setTerrain(e,t={}){if(this.style._checkLoaded(),e&&gg(this,Nn.terrain,{value:e},t))return this;if(this._terrainDataCallback&&this.style.off("data",this._terrainDataCallback),!e)this.terrain&&this.terrain.destroy(),this.terrain=null,this.painter.renderToTexture=null,this._camera.terrain=null,this._camera.transform.setMinElevationForCurrentTile(0),this.getCenterClampedToGround()&&this._camera.transform.setElevation(0);else{let r=this.style.tileManagers[e.source];if(!r)throw Error(`cannot load terrain, because there exists no source with ID: ${e.source}`);this.terrain===null&&r.reload();for(let i in this.style._layers){let n=this.style._layers[i];n.type==="hillshade"&&n.source===e.source&&vr("You are using the same source for a hillshade layer and for 3D terrain. Please consider using two separate sources to improve rendering quality."),n.type==="color-relief"&&n.source===e.source&&vr("You are using the same source for a color-relief layer and for 3D terrain. Please consider using two separate sources to improve rendering quality.")}this.terrain&&this.terrain.destroy(),this.terrain=new k7e(this.painter,r,e,this._terrainSkirtLength),this.painter.renderToTexture=new E7e(this.painter,this.terrain),this._camera.terrain=this.terrain,this._camera.transform.setMinElevationForCurrentTile(this.terrain.getMinTileElevationForLngLatZoom(this._camera.transform.center,this._camera.transform.tileZoom)),this._camera.transform.setElevation(this.terrain.getElevationForLngLatZoom(this._camera.transform.center,this._camera.transform.tileZoom)),this._terrainDataCallback=i=>this._handleTerrainDataEvent(i,e.source),this.style.on("data",this._terrainDataCallback)}return this.fire(new APe({terrain:e})),this}_handleTerrainDataEvent(e,t){var i;if(e.dataType==="style"){this.terrain.tileManager.releaseAllRTT();return}let r=e.sourceId===t;if(r&&this.terrain.resetElevationCache(),r&&e.tile&&!this._camera.elevationFreeze&&(this._camera.transform.setMinElevationForCurrentTile(this.terrain.getMinTileElevationForLngLatZoom(this._camera.transform.center,this._camera.transform.tileZoom)),this.getCenterClampedToGroun
1546d()&&this._camera.transform.setElevation(this.terrain.getElevationForLngLatZoom(this._camera.transform.center,this._camera.transform.tileZoom))),e.tile){if(((i=e.source)==null?void 0:i.type)==="image"){this.terrain.tileManager.releaseAllRTT();return}this.terrain.tileManager.releaseRTT(e.tile.tileID)}}getTerrain(){var e;return((e=this.terrain)==null?void 0:e.options)??null}areTilesLoaded(){var t;let e=(t=this.style)==null?void 0:t.tileManagers;for(let r of Object.values(e))if(!r.areTilesLoaded())return!1;return!0}removeSource(e){return this.style.removeSource(e),this._update(!0)}getSource(e){var t;return(t=this.style)==null?void 0:t.getSource(e)}setSourceTileLodParams(e,t,r){if(r){let i=this.getSource(r);if(!i)throw Error(`There is no source with ID "${r}", cannot set LOD parameters`);i.calculateTileZoom=Qw(Math.max(1,e),Math.max(1,t))}else for(let i in this.style.tileManagers)this.style.tileManagers[i].getSource().calculateTileZoom=Qw(Math.max(1,e),Math.max(1,t));return this._update(!0),this}refreshTiles(e,t){let r=this.style.tileManagers[e];if(!r)throw Error(`There is no tile manager with ID "${e}", cannot refresh tile`);t===void 0?r.reload(!0):r.refreshTiles(t.map(i=>new pv(i.z,i.x,i.y)))}addImage(e,t,r={}){var n;this._lazyInitEmptyStyle();let i=this._createStyleImage(t,r);return i?(this.style.addImage(e,i),(n=i.userImage)!=null&&n.onAdd&&i.userImage.onAdd(this,e),this):this}setMissingStyleImageResolver(e){var t;return this._missingStyleImageResolver=e,(t=this.style)==null||t.setMissingImageResolver(e),this}_createStyleImage(e,t={}){let{pixelRatio:r=1,sdf:i=!1,stretchX:n,stretchY:a,content:s,textFitWidth:o,textFitHeight:l}=t;if(e instanceof HTMLImageElement||uc(e)){let{width:u,height:c,data:d}=qn.getImageData(e);return{data:new _r({width:u,height:c},d),pixelRatio:r,stretchX:n,stretchY:a,content:s,textFitWidth:o,textFitHeight:l,sdf:i,version:0}}if(e.width===void 0||e.height===void 0)return this.fire(new He(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`"))),null;{let{width:u,height:c,data:d}=e,h=e;return{data:new _r({width:u,height:c},new Uint8Array(d)),pixelRatio:r,stretchX:n,stretchY:a,content:s,textFitWidth:o,textFitHeight:l,sdf:i,version:0,userImage:h}}}updateImage(e,t){let r=this.style.getImage(e);if(!r)return this.fire(new He(Error("The map has no image with that id. If you are adding a new image use `map.addImage(...)` instead.")));let{width:i,height:n,data:a}=t instanceof HTMLImageElement||uc(t)?qn.getImageData(t):t;if(i===void 0||n===void 0)return this.fire(new He(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`")));if(i!==r.data.width||n!==r.data.height)return this.fire(new He(Error("The width and height of the updated image must be that same as the previous version of the image")));let s=!(t instanceof HTMLImageElement||uc(t));return r.data.replace(a,s),this.style.updateImage(e,r),this}getImage(e){return this.style.getImage(e)}hasImage(e){return e?!!this.style.getImage(e):(this.fire(new He(Error("Missing required image id"))),!1)}removeImage(e){this.style.removeImage(e)}async loadImage(e){return Zo.getImage(await this._requestManager.transformRequest(e,"Image"),new AbortController)}listImages(){var e;return((e=this.style)==null?void 0:e.listImages())??[]}addLayer(e,t){return this._lazyInitEmptyStyle(),this.style.addLayer(e,t),this._update(!0)}moveLayer(e,t){return this.style.moveLayer(e,t),this._update(!0)}removeLayer(e){return this.style.removeLayer(e),this._update(!0)}getLayer(e){var t;return(t=this.style)==null?void 0:t.getLayer(e)}getLayersOrder(){var e;return((e=this.style)==null?void 0:e.getLayersOrder())??[]}setLayerZoomRange(e,t,r){return this.style.setLayerZoomRange(e,t,r),this._update(!0)}setFilter(e,t,r={}){var i;return(i=this.style)==null||i.setFilter(e,t,r),this._update(!0)}getFilter(e){return this.style.getFilter(e)}setPaintProperty(e,t,r,i={}){var n;return(n=this.style)==null||n.setPaintProperty(e,t,r,i),this._update(!0)}getPaintProperty(e,t){return this.style.getPaintProperty(e,t)}setLayoutProperty(e,t,r,i={}){return this.style.setLayoutProperty(e,t,r,i),this._update(!0)}getLayoutProperty(e,t){return this.style.getLayoutProperty(e,t)}setGlyphs(e,t={}){return this._lazyInitEmptyStyle(),this.style.setGlyphs(e,t),this._update(!0)}getGlyphs(){return this.style.getGlyphsUrl()}addSprite(e,t,r={}){return this._lazyInitEmptyStyle(),this.style.addSprite(e,t,r,i=>{i||this._update(!0)}),this}removeSprite(e){return this._lazyInitEmptyStyle(),this.style.removeSprite(e),this._update(!0)}getSprite(){return this.style.getSprite()}setSprite(e,t={}){return this._lazyInitEmptyStyle(),this.style.setSprite(e,t,r=>{r||this._update(!0)}),this}setLight(e,t={}){return this._lazyInitEmptyStyle(),this.style.setLight(e,t),this._update(!0)}getLight(){return this.style.getLight()}setSky(e,t={}){return this._lazyInitEmptyStyle(),this.style.setSky(e,t),this._update(!0)}getSky(){return this.style.getSky()}setFeatureState(e,t){return this.style.setFeatureState(e,t),this._update()}removeFeatureState(e,t){return this.style.removeFeatureState(e,t),this._update()}getFeatureState(e){return this.style.getFeatureState(e)}getContainer(){return this._container}getCanvasContainer(){return this._canvasContainer}getCanvas(){return this._canvas}_containerDimensions(){let e=0,t=0;return this._container&&(e=this._container.clientWidth||400,t=this._container.clientHeight||300),[e,t]}_setupResizeObserver(){let e=!1,t=vz(i=>{this._trackResize&&!this._removed&&(this.resize(i),this.redraw())},50),r=this._ownerWindow.ResizeObserver??ResizeObserver;this._resizeObserver=new r(i=>{if(!e){e=!0;return}t(i)}),this._resizeObserver.observe(this._container)}
vendor: 12,783 bytes, line 1546
1546_resolveContainer(e){if(typeof e=="string"){let t=document.getElementById(e);if(!t)throw Error(`Container '${e}' not found.`);return t}if(e instanceof HTMLElement||e&&typeof e=="object"&&e.nodeType===1)return e;throw Error("Invalid type: 'container' must be a String or HTMLElement.")}_setupContainer(){let e=this._container;e.classList.add("maplibregl-map");let t=this._canvasContainer=Ut.create("div","maplibregl-canvas-container",e);this._interactive&&t.classList.add("maplibregl-interactive"),this._canvas=Ut.create("canvas","maplibregl-canvas",t),this._canvas.addEventListener("webglcontextlost",this._contextLost,!1),this._canvas.addEventListener("webglcontextrestored",this._contextRestored,!1),this._canvas.setAttribute("tabindex",this._interactive?"0":"-1"),this._canvas.setAttribute("aria-label",this._getUIString("Map.Title")),this._canvas.setAttribute("role","region");let r=this._containerDimensions(),i=this._getClampedPixelRatio(r[0],r[1]);this._resizeCanvas(r[0],r[1],i);let n=this._controlContainer=Ut.create("div","maplibregl-control-container",e),a=this._controlPositions={};for(let s of["top-left","top-right","bottom-left","bottom-right"])a[s]=Ut.create("div",`maplibregl-ctrl-${s} `,n);this._container.addEventListener("scroll",this._onMapScroll,!1)}_resizeCanvas(e,t,r){this._canvas.width=Math.floor(r*e),this._canvas.height=Math.floor(r*t),this._canvas.style.width=`${e}px`,this._canvas.style.height=`${t}px`}_setupPainter(){let e={...this._canvasContextAttributes,alpha:!0,depth:!0,stencil:!0,premultipliedAlpha:!0},t=null;this._canvas.addEventListener("webglcontextcreationerror",i=>{t=i},{once:!0});let r=this._canvas.getContext("webgl2",e);if(!r){this.fire(new He(new LDe(e,t)));return}this.painter=new ODe(r,this._camera.transform)}migrateProjection(e,t){this._camera.migrateProjection(e,t),this.painter.transform=e,this.fire(new DPe({newProjection:this.style.projection.name}))}loaded(){return!this._styleDirty&&!this._sourcesDirty&&!!this.style&&this.style.loaded()}_update(e){var t;return(t=this.style)!=null&&t._loaded?(this._styleDirty||(this._styleDirty=e),this._sourcesDirty=!0,this.triggerRepaint(),this):this}_requestRenderFrame(e){return this._update(),this._renderTaskQueue.add(e)}_cancelRenderFrame(e){this._renderTaskQueue.remove(e)}_render(e){var s,o,l,u;let t=this._idleTriggered?this._fadeDuration:0,r=((s=this.style.projection)==null?void 0:s.transitionState)>0;if(this.painter.context.setDirty(),this.painter.setBaseState(),this._renderTaskQueue.run(e),this._removed)return;let i=!1;if(this.style&&this._styleDirty){this._styleDirty=!1;let c=this._camera.transform.zoom,d=tr();this.style.zoomHistory.update(c,d);let h=new Tr(c,{now:d,fadeDuration:t,zoomHistory:this.style.zoomHistory,transition:this.style.getTransition()}),f=h.crossFadingFactor();(f!==1||f!==this._crossFadingFactor)&&(i=!0,this._crossFadingFactor=f),this.style.update(h)}let n=((o=this.style.projection)==null?void 0:o.transitionState)>0!==r;this._camera.transform.setTransitionState((l=this.style.projection)==null?void 0:l.transitionState),this.style&&(this._sourcesDirty||n)&&(this._sourcesDirty=!1,this.style._updateSources(this._camera.transform)),this.terrain?(this.terrain.tileManager.update(this._camera.transform,this.terrain),this.terrain.resetElevationCache(),this._camera.transform.setMinElevationForCurrentTile(this.terrain.getMinTileElevationForLngLatZoom(this._camera.transform.center,this._camera.transform.tileZoom)),!this._camera.elevationFreeze&&this.getCenterClampedToGround()&&this._camera.transform.setElevation(this.terrain.getElevationForLngLatZoom(this._camera.transform.center,this._camera.transform.tileZoom))):(this._camera.transform.setMinElevationForCurrentTile(0),this.getCenterClampedToGround()&&this._camera.transform.setElevation(0)),this._placementDirty=(u=this.style)==null?void 0:u._updatePlacement(this._camera.transform,this.showCollisionBoxes,t,this._crossSourceCollisions,n),this.painter.render(this.style,{showTileBoundaries:this.showTileBoundaries,showOverdrawInspector:this._showOverdrawInspector,rotating:this.isRotating(),zooming:this.isZooming(),moving:this.isMoving(),fadeDuration:t,showPadding:this.showPadding,anisotropicFilterPitch:this.getAnisotropicFilterPitch()}),this.fire(new Ei("render")),this.loaded()&&!this._loaded&&(this._loaded=!0,this.fire(new Ei("load"))),this.style&&(this.style.hasTransitions()||i)&&(this._styleDirty=!0),this.style&&!this._placementDirty&&this.style._releaseSymbolFadeTiles();let a=this._sourcesDirty||this._styleDirty||this._placementDirty;return a||this._repaint?this.triggerRepaint():!this.isMoving()&&this.loaded()&&this.fire(new Ei("idle")),this._loaded&&!this._fullyLoaded&&!a&&(this._fullyLoaded=!0),this}redraw(){return this.style&&(this._frameRequest&&(this._frameRequest=(this._frameRequest.abort(),null)),this._render(0)),this}remove(){var t,r;this._hash&&this._hash.remove();for(let i of this._controls)i.onRemove(this);this._controls=[],this._frameRequest&&(this._frameRequest=(this._frameRequest.abort(),null)),this._renderTaskQueue.clear(),(t=this._diffStyleRequest)==null||t.abort(),this.painter.destroy(),this._handlers.destroy(),this.setStyle(null),typeof window<"u"&&this._ownerWindow.removeEventListener("online",this._onWindowOnline,!1),Zo.removeThrottleControl(this._imageQueueHandle),(r=this._resizeObserver)==null||r.disconnect();let e=this.painter.context.gl.getExtension("WEBGL_lose_context");e!=null&&e.loseContext&&e.loseContext(),this._canvas.removeEventListener("webglcontextrestored",this._contextRestored,!1),this._canvas.removeEventListener("webglcontextlost",this._contextLost,!1),this._canvasContainer.remove(),this._controlContainer.remove(),this._container.removeEventListener("scroll",this._onMapScroll,!1),this._container.classList.remove("maplibregl-map"),this._removed=!0,this.fire(new Ei("remove"))}triggerRepaint(){this.style&&!this._frameRequest&&(this._frameRequest=new AbortController,qn.frame(this._frameRequest,e=>{this._frameRequest=null;try{this._render(e)}catch(t){if(!uu(t))throw t}},()=>{},this._ownerWindow))}get showTileBoundaries(){return!!this._showTileBoundaries}set showTileBoundaries(e){this._showTileBoundaries!==e&&(this._showTileBoundaries=e,this._update())}get showPadding(){return!!this._showPadding}set showPadding(e){this._showPadding!==e&&(this._showPadding=e,this._update())}get showCollisionBoxes(){return!!this._showCollisionBoxes}set showCollisionBoxes(e){this._showCollisionBoxes!==e&&(this._showCollisionBoxes=e,e?this.style._generateCollisionBoxes():this._update())}get showOverdrawInspector(){return!!this._showOverdrawInspector}set showOverdrawInspector(e){this._showOverdrawInspector!==e&&(this._showOverdrawInspector=e,this._update())}get repaint(){return!!this._repaint}set repaint(e){this._repaint!==e&&(this._repaint=e,this.triggerRepaint())}get vertices(){return!!this._vertices}set vertices(e){this._vertices=e,this._update()}get version(){return M7e}getCameraTargetElevation(){return this._camera.transform.elevation}getProjection(){return this.style.getProjection()}setProjection(e){return this._lazyInitEmptyStyle(),this.style.setProjection(e),this._update(!0)}};const A7e={showCompass:!0,showZoom:!0,visualizePitch:!1,visualizeRoll:!0};var D7e=class{constructor(e){this._updateZoomButtons=()=>{let t=this._map.getZoom(),r=t===this._map.getMaxZoom(),i=t===this._map.getMinZoom();this._zoomInButton.disabled=r,this._zoomOutButton.disabled=i,this._zoomInButton.setAttribute("aria-disabled",r.toString()),this._zoomOutButton.setAttribute("aria-disabled",i.toString())},this._rotateCompassArrow=()=>{let t=this._map.getPitch(),r=this._map.getRoll(),i=this._map.getBearing(),n=1/Math.cos(zr(t))**.5;if(this.options.visualizePitch&&this.options.visualizeRoll){this._compassIcon.style.transform=`scale(${n}) rotateZ(${-r}deg) rotateX(${t}deg) rotateZ(${-i}deg)`;return}if(this.options.visualizePitch){this._compassIcon.style.transform=`scale(${n}) rotateX(${t}deg) rotateZ(${-i}deg)`;return}if(this.options.visualizeRoll){this._compassIcon.style.transform=`rotate(${-i-r}deg)`;return}this._compassIcon.style.transform=`rotate(${-i}deg)`},this._setButtonTitle=(t,r)=>{let i=this._map._getUIString(`NavigationControl.${r}`);t.title=i,t.setAttribute("aria-label",i)},this.options=Ne({},A7e,e),this._container=Ut.create("div","maplibregl-ctrl maplibregl-ctrl-group"),this._container.addEventListener("contextmenu",t=>t.preventDefault()),this.options.showZoom&&(this._zoomInButton=this._createButton("maplibregl-ctrl-zoom-in",t=>this._map.zoomIn({},{originalEvent:t})),Ut.create("span","maplibregl-ctrl-icon",this._zoomInButton).setAttribute("aria-hidden","true"),this._zoomOutButton=this._createButton("maplibregl-ctrl-zoom-out",t=>this._map.zoomOut({},{originalEvent:t})),Ut.create("span","maplibregl-ctrl-icon",this._zoomOutButton).setAttribute("aria-hidden","true")),this.options.showCompass&&(this._compass=this._createButton("maplibregl-ctrl-compass",t=>{this.options.visualizePitch?this._map.resetNorthPitch({},{originalEvent:t}):this._map.resetNorth({},{originalEvent:t})}),this._compassIcon=Ut.create("span","maplibregl-ctrl-icon",this._compass),this._compassIcon.setAttribute("aria-hidden","true"))}onAdd(e){return this._map=e,this.options.showZoom&&(this._setButtonTitle(this._zoomInButton,"ZoomIn"),this._setButtonTitle(this._zoomOutButton,"ZoomOut"),this._map.on("zoom",this._updateZoomButtons),this._updateZoomButtons()),this.options.showCompass&&(this._setButtonTitle(this._compass,"ResetBearing"),this.options.visualizePitch&&this._map.on("pitch",this._rotateCompassArrow),this.options.visualizeRoll&&this._map.on("roll",this._rotateCompassArrow),this._map.on("rotate",this._rotateCompassArrow),this._rotateCompassArrow(),this._handler=new R7e(this._map,this._compass,this.options.visualizePitch)),this._container}onRemove(){this._container.remove(),this.options.showZoom&&this._map.off("zoom",this._updateZoomButtons),this.options.showCompass&&(this.options.visualizePitch&&this._map.off("pitch",this._rotateCompassArrow),this.options.visualizeRoll&&this._map.off("roll",this._rotateCompassArrow),this._map.off("rotate",this._rotateCompassArrow),this._handler.off(),delete this._handler),delete this._map}_createButton(e,t){let r=Ut.create("button",e,this._container);return r.type="button",r.addEventListener("click",t),r}},R7e=class{constructor(e,t,r=!1){this.mousedown=n=>{this.startMove(n,Ut.mousePos(this.element,n)),window.addEventListener("mousemove",this.mousemove),window.addEventListener("mouseup",this.mouseup)},this.mousemove=n=>{this.move(n,Ut.mousePos(this.element,n))},this.mouseup=n=>{this._rotatePitchHandler.dragEnd(n),this.offTemp()},this.touchstart=n=>{n.targetTouches.length===1?(this._startPos=this._lastPos=Ut.touchPos(this.element,n.targetTouches)[0],this.startMove(n,this._startPos),window.addEventListener("touchmove",this.touchmove,{passive:!1}),window.addEventListener("touchend",this.touchend)):this.reset()},this.touchmove=n=>{n.targetTouches.length===1?(this._lastPos=Ut.touchPos(this.element,n.targetTouches)[0],this.move(n,this._lastPos)):this.reset()},this.touchend=n=>{n.targetTouches.length===0&&this._startPos&&this._lastPos&&this._startPos.dist(this._lastPos)<this._clickTolerance&&this.element.click(),delete this._startPos,delete this._lastPos,this.offTemp()},this.reset=()=>{this._rotatePitchHandler.reset(),delete this._startPos,delete this._lastPos,this.offTemp()},this._clickTolerance=10,this.element=t;let i=new QDe;this._rotatePitchHandler=new Sg({clickTolerance:3,move:(n,a)=>{let s=t.getBoundingClientRect(),o=new de((s.bottom-s.top)/2,(s.right-s.left)/2);return{bearingDelta:TR(new de(n.x,a.y),a,o),pitchDelta:r?(a.y-n.y)*-.5:void 0}},moveStateManager:i,enable:!0,assignEvents:()=>{}}),this.map=e,t.addEventListener("mousedown",this.mousedown),t.addEventListener("touchstart",this.touchstart,{passive:!1}),t.addEventListener("touchcancel",this.reset)}startMove(e,t){this._rotatePitchHandler.dragStart(e,t),Ut.disableDrag()}move(e,t){let r=this.map,{bearingDelta:i,pitchDelta:n}=this._rotatePitchHandler.dragMove(e,t)||{};i&&r.setBearing(r.getBearing()+i),n&&r.setPitch(r.getPitch()+n)}off(){let e=this.element;e.removeEventListener("mousedown",this.mousedown),e.removeEventListener("touchstart",this.touchstart),window.removeEventListener("touchmove",this.touchmove),window.removeEventListener("touchend",this.touchend),e.removeEventListener("touchcancel",this.reset),this.offTemp()}offTemp(){Ut.enableDrag(),window.removeEventListener("mousemove",this.mousemove),window.removeEventListener("mouseup",this.mouseup),window.removeEventListener("touchmove",this.touchmove),window.removeEventListener("touchend",this.touchend)}};function O7e(e){cl.WORKER_URL=e}const L7e="/build/assets/maplibre-gl-worker-Dj8JSkXq.js",F7e={key:0,class:"ag-control
1546s"},z7e=["checked","onChange"],N7e={class:"ag-controls__name"},B7e={key:0,class:"ag-controls__badge"},j7e={__name:"AgMapControls",props:{layers:{type:Array,required:!0},visibility:{type:Object,required:!0}},emits:["toggle"],setup(e){const t=r=>r.replace(/[-_]/g," ").replace(/\b\w/g,i=>i.toUpperCase());return(r,i)=>e.layers.length?(k(),M("div",F7e,[i[0]||(i[0]=b("p",{class:"ag-controls__title"},"Layers",-1)),(k(!0),M(xe,null,Me(e.layers,n=>(k(),M("label",{key:n.id,class:"ag-controls__row"},[b("input",{type:"checkbox",checked:e.visibility[n.id]!==!1,onChange:a=>r.$emit("toggle",n.id,a.target.checked)},null,40,z7e),b("span",N7e,Q(t(n.id)),1),n.type==="live"?(k(),M("span",B7e,"live")):X("",!0)]))),128))])):X("",!0)}},U7e=Yt(j7e,[["__scopeId","data-v-8009abf1"]]),Ge={background:"#BFC7A0",water:"#257E9A",border:"#de1117",label:"#4a463f",labelHalo:"rgba(255, 255, 255, 0.75)",boundaryNationalPark:"#24522f",boundaryNatureReserve:"#3c6a34",boundaryProtectedArea:"#557f45",outline:"#2c4f36",parkLabel:"#1d3a26",parkLabelHalo:"rgba(255, 255, 255, 0.85)",city:"#5c574e",cityDot:"#7a746a",highway:"#a87f42",highwayCasing:"rgba(255, 252, 245, 0.7)",waterLabel:"#0b3f52",waterLabelHalo:"rgba(255, 255, 255, 0.92)",lodge:"#b4531f",road:"#9c7a4f",roadCasing:"#fbf8f2",trail:"#a08a5c",settlement:"#6b5f7a",protectedNationalPark:"#5b914e",protectedNatureReserve:"#6fa15f",protectedPrivateReserve:"#84ae74",protectedAreaEdge:"#679758",airstrip:"#3f6484",destination:"#a8332a",destinationLabel:"#5f1f18",destinationLabelHalo:"rgba(255, 255, 255, 0.9)",flooding:"#2f7fb0",migration:"#c98f3c",generic:"#7a7f8a"},Wy=[[14.255698,-34.11],[50.368782,2.579727]],V7e="https://tiles.openfreemap.org/planet",q7e='© <a href="https://www.openstreetmap.org/copyright">OpenStreetMap</a> contributors',G7e="https://tiles.openfreemap.org/fonts/{fontstack}/{range}.pbf",Cd="ag-place-country",HE=["city","town"],YE=6,WE=["motorway","trunk","primary"],ZE=6,n2=(e,t,r)=>["match",["get","class"],"motorway",e,"trunk",t,r],KE=(e=0)=>["interpolate",["linear"],["zoom"],6,n2(1.4+e,1.1+e,.8+e),10,n2(3+e,2.4+e,1.6+e),13,n2(5+e,4+e,2.8+e)],H7e=["river","canal"],Y7e=9,a2=["Noto Sans Italic"],s2=["coalesce",["get","name:en"],["get","name"]],W7e=["match",["geometry-type"],["Point","MultiPoint"],!0,!1],XE=["match",["geometry-type"],["LineString","MultiLineString"],!0,!1],Z7e={water:["ag-water"],roads:["ag-road-casing","ag-road"],borders:["ag-border-country","ag-border-disputed"],countryNames:[Cd],cityNames:["ag-place-city-dot","ag-place-city"],waterNames:["ag-water-name-point","ag-water-name-line","ag-waterway-name"]},K7e={water:!0,roads:!0,borders:!0,countryNames:!0,cityNames:!0,parkNames:!0,waterNames:!0,destinationNames:!0,airstripNames:!0};function X7e(){return{version:8,glyphs:G7e,sources:{"ag-basemap":{type:"vector",url:V7e,attribution:q7e}},layers:[{id:"ag-background",type:"background",paint:{"background-color":Ge.background}},{id:"ag-water",type:"fill",source:"ag-basemap","source-layer":"water",paint:{"fill-color":Ge.water}},{id:"ag-road-casing",type:"line",source:"ag-basemap","source-layer":"transportation",filter:["in",["get","class"],["literal",WE]],minzoom:ZE,layout:{"line-join":"round","line-cap":"round"},paint:{"line-color":Ge.highwayCasing,"line-width":KE(1.2)}},{id:"ag-road",type:"line",source:"ag-basemap","source-layer":"transportation",filter:["in",["get","class"],["literal",WE]],minzoom:ZE,layout:{"line-join":"round","line-cap":"round"},paint:{"line-color":Ge.highway,"line-width":KE()}},{id:"ag-border-country",type:"line",source:"ag-basemap","source-layer":"boundary",filter:["all",["==",["get","admin_level"],2],["!=",["get","maritime"],1],["!=",["get","disputed"],1]],layout:{"line-join":"round","line-cap":"round"},paint:{"line-color":Ge.border,"line-width":["interpolate",["linear"],["zoom"],2,.6,6,1,10,1.6],"line-opacity":.85}},{id:"ag-border-disputed",type:"line",source:"ag-basemap","source-layer":"boundary",filter:["all",["==",["get","admin_level"],2],["!=",["get","maritime"],1],["==",["get","disputed"],1]],paint:{"line-color":Ge.border,"line-width":["interpolate",["linear"],["zoom"],2,.6,6,1,10,1.6],"line-opacity":.85,"line-dasharray":[3,2]}},{id:Cd,type:"symbol",source:"ag-basemap","source-layer":"place",filter:["all",["==",["get","class"],"country"],["<=",["get","rank"],4]],maxzoom:9,layout:{"text-field":["coalesce",["get","name:en"],["get","name"]],"text-font":["Noto Sans Regular"],"text-size":["interpolate",["linear"],["zoom"],2,9,5,12,8,14],"text-transform":"uppercase","text-letter-spacing":.14,"text-max-width":7,"text-padding":6},paint:{"text-color":Ge.label,"text-halo-color":Ge.labelHalo,"text-halo-width":1.2}}
1546,{id:"ag-place-city-dot",type:"circle",source:"ag-basemap","source-layer":"place",filter:["in",["get","class"],["literal",HE]],minzoom:YE,paint:{"circle-radius":["interpolate",["linear"],["zoom"],6,1.5,12,3],"circle-color":Ge.cityDot,"circle-stroke-width":.8,"circle-stroke-color":"rgba(255, 255, 255, 0.85)"}},{id:"ag-place-city",type:"symbol",source:"ag-basemap","source-layer":"place",filter:["in",["get","class"],["literal",HE]],minzoom:YE,layout:{"text-field":["coalesce",["get","name:en"],["get","name"]],"text-font":["Noto Sans Regular"],"text-size":["interpolate",["linear"],["zoom"],6,10,12,13],"text-anchor":"left","text-offset":[.55,.05],"text-max-width":8,"text-padding":4,"symbol-sort-key":["coalesce",["get","rank"],100]},paint:{"text-color":Ge.city,"text-halo-color":Ge.labelHalo,"text-halo-width":1.1}},{id:"ag-water-name-point",type:"symbol",source:"ag-basemap","source-layer":"water_name",filter:["all",W7e,["!=",["get","class"],"river"]],layout:{"text-field":s2,"text-font":a2,"text-size":["interpolate",["linear"],["zoom"],3,["match",["get","class"],"ocean",13,"sea",12,10],10,["match",["get","class"],"ocean",17,"sea",15,13]],"text-max-width":8,"text-letter-spacing":.08,"text-padding":3},paint:{"text-color":Ge.waterLabel,"text-halo-color":Ge.waterLabelHalo,"text-halo-width":1.4}},{id:"ag-water-name-line",type:"symbol",source:"ag-basemap","source-layer":"water_name",filter:["all",XE,["!=",["get","class"],"river"]],minzoom:4,layout:{"text-field":s2,"text-font":a2,"text-size":["interpolate",["linear"],["zoom"],4,11,10,14],"symbol-placement":"line","symbol-spacing":350,"text-letter-spacing":.12,"text-max-angle":60,"text-padding":3},paint:{"text-color":Ge.waterLabel,"text-halo-color":Ge.waterLabelHalo,"text-halo-width":1.4}},{id:"ag-waterway-name",type:"symbol",source:"ag-basemap","source-layer":"waterway",filter:["all",XE,["in",["get","class"],["literal",H7e]],["any",["has","name"],["has","name:en"]]],minzoom:Y7e,layout:{"text-field":s2,"text-font":a2,"text-size":["interpolate",["linear"],["zoom"],9,10,13,12],"symbol-placement":"line","symbol-spacing":350,"text-max-angle":75,"text-letter-spacing":.08,"text-padding":2},paint:{"text-color":Ge.waterLabel,"text-halo-color":Ge.waterLabelHalo,"text-halo-width":1.4}}]}}const J7e={key:0,class:"ag-legend"},Q7e={class:"ag-legend__list"},eRe=["checked","onChange"],tRe={class:"ag-legend__label"},rRe="rgba(251, 248, 242, 0.5)",iRe="rgba(44, 79, 54, 0.28)",nRe={__name:"AgMapLegend",props:{entries:{type:Array,required:!0},unchecked:{type:Array,default:()=>[]}},emits:["toggle"],setup(e){iI(n=>({v4d5644d5:rRe,v7feecaed:iRe,eb53ed22:le(r),ce34f588:le(i)}));function t(n){var a;return n.shape==="dashed"?{borderTopColor:n.color}:(a=n.shape)!=null&&a.startsWith("area")?{backgroundColor:n.color,borderColor:n.outline||n.color}:{backgroundColor:n.color}}const r=Ge.label,i=Ge.city;return(n,a)=>e.entries.length?(k(),M("div",J7e,[a[0]||(a[0]=b("p",{class:"ag-legend__title"},"Key",-1)),b("ul",Q7e,[(k(!0),M(xe,null,Me(e.entries,s=>(k(),M("li",{key:s.value},[b("label",{class:pe(["ag-legend__item",{"ag-legend__item--off":e.unchecked.includes(s.value)}])},[b("input",{type:"checkbox",class:"ag-legend__check",checked:!e.unchecked.includes(s.value),onChange:o=>n.$emit("toggle",s.value,o.target.checked)},null,40,eRe),b("span",{class:pe(["ag-legend__swatch",`ag-legend__swatch--${s.shape||"dot"}`]),style:Qt(t(s))},null,6),b("span",tRe,Q(s.label),1)],2)]))),128))])])):X("",!0)}}
1546,aRe=Yt(nRe,[["__scopeId","data-v-2809b543"]]),sRe=99999,oRe=350,lRe="cubic-bezier(0.4, 0, 0.2, 1)",JE={position:"fixed",top:"0px",left:"0px",width:"100%",height:"100%",margin:"0","min-height":"0","max-width":"none","max-height":"none","z-index":String(sRe)},o2=e=>e.getBoundingClientRect(),uRe=()=>({top:0,left:0,width:document.documentElement.clientWidth,height:document.documentElement.clientHeight}),QE=({top:e,left:t,width:r,height:i})=>({top:`${e}px`,left:`${t}px`,width:`${r}px`,height:`${i}px`}),cRe=()=>{var e;return((e=window.matchMedia)==null?void 0:e.call(window,"(prefers-reduced-motion: reduce)").matches)??!1};class dRe{constructor({target:t,duration:r=oRe,onChange:i}={}){this.target=t,this.duration=r,this.onChange=i,this.expanded=!1,this.animation=null,this.handleKeydown=n=>{n.key==="Escape"&&this.expanded&&this.toggle()}}onAdd(t){this.map=t;const r=document.createElement("span");return r.className="maplibregl-ctrl-icon",r.setAttribute("aria-hidden","true"),this.button=document.createElement("button"),this.button.type="button",this.button.appendChild(r),this.button.addEventListener("click",()=>this.toggle()),this.container=document.createElement("div"),this.container.className="maplibregl-ctrl maplibregl-ctrl-group",this.container.appendChild(this.button),this.syncButton(),document.addEventListener("keydown",this.handleKeydown),this.container}onRemove(){var t;document.removeEventListener("keydown",this.handleKeydown),(t=this.animation)==null||t.cancel(),this.clearStyles(),this.container.remove(),this.map=null}toggle(){this.expanded?this.collapse():this.expand()}expand(){if(this.expanded)return;const t=o2(this.target);this.applyStyles(),this.setExpanded(!0),this.animate(t,uRe())}async collapse(){var i;if(!this.expanded)return;const t=o2(this.target);(i=this.animation)==null||i.cancel(),this.clearStyles();const r=o2(this.target);this.applyStyles(),this.setExpanded(!1),await this.animate(t,r)&&this.clearStyles()}animate(t,r){var i;return(i=this.animation)==null||i.cancel(),this.animation=this.target.animate([QE(t),QE(r)],{duration:cRe()?0:this.duration,easing:lRe}),this.animation.finished.then(()=>!0,()=>!1)}applyStyles(){for(const[t,r]of Object.entries(JE))this.target.style.setProperty(t,r)}clearStyles(){for(const t of Object.keys(JE))this.target.style.removeProperty(t)}setExpanded(t){var r;this.expanded=t,this.syncButton(),(r=this.onChange)==null||r.call(this,t)}syncButton(){const t=this.expanded?"Exit fullscreen":"Enter fullscreen";this.button.className=this.expanded?"maplibregl-ctrl-shrink":"maplibregl-ctrl-fullscreen",this.button.title=t,this.button.setAttribute("aria-label",t),this.button.setAttribute("aria-pressed",String(this.expanded))}}const hRe="data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' width='29' height='29' viewBox='0 0 29 29' fill='none' stroke='%23333' stroke-width='2' stroke-linecap='round'%3E%3Ccircle cx='14.5' cy='14.5' r='6'/%3E%3Cpath d='M14.5 3.8v3.6M14.5 21.6v3.6M3.8 14.5h3.6M21.6 14.5h3.6'/%3E%3Ccircle cx='14.5' cy='14.5' r='1.4' fill='%23333' stroke='none'/%3E%3C/svg%3E";class fRe{constructor({onFocus:t,label:r="Recentre the map"}={}){this.onFocus=t,this.label=r,this.available=!0}onAdd(t){this.map=t;const r=document.createElement("span");return r.className="maplibregl-ctrl-icon",r.setAttribute("aria-hidden","true"),r.style.backgroundImage=`url("${hRe}")`,this.button=document.createElement("button"),this.button.type="button",this.button.title=this.label,this.button.setAttribute("aria-label",this.label),this.button.appendChild(r),this.button.addEventListener("click",()=>{var i;return(i=this.onFocus)==null?void 0:i.call(this)}),this.container=document.createElement("div"),this.container.className="maplibregl-ctrl maplibregl-ctrl-group",this.container.appendChild(this.button),this.syncAvailability(),this.container}onRemove(){this.container.remove(),this.map=null}setAvailable(t){this.available=t,this.container&&this.syncAvailability()}syncAvailability(){this.container.style.display=this.available?"":"none"}}var pa=Uint8Array,kd=Uint16Array,pRe=Int32Array,wz=new pa([0,0,0,0,0,0,0,0,1,1,1,1,2,2,2,2,3,3,3,3,4,4,4,4,5,5,5,5,0,0,0,0]),$z=new pa([0,0,0,0,1,1,2,2,3,3,4,4,5,5,6,6,7,7,8,8,9,9,10,10,11,11,12,12,13,13,0,0]),mRe=new pa([16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15]),Sz=function(e,t){for(var r=new kd(31),i=0;i<31;++i)r[i]=t+=1<<e[i-1];for(var n=new pRe(r[30]),i=1;i<30;++i)for(var a=r[i];a<r[i+1];++a)n[a]=a-r[i]<<5|i;return{b:r,r:n}},Tz=Sz(wz,2),Cz=Tz.b,gRe=Tz.r;Cz[28]=258,gRe[258]=28;var _Re=Sz($z,0),yRe=_Re.b,l3=new kd(32768);for(var Sr=0;Sr<32768;++Sr){var Sl=(Sr&43690)>>1|(Sr&21845)<<1;Sl=(Sl&52428)>>2|(Sl&13107)<<2,Sl=(Sl&61680)>>4|(Sl&3855)<<4,l3[Sr]=((Sl&65280)>>8|(Sl&255)<<8)>>1}var Fp=(function(e,t,r){for(var i=e.length,n=0,a=new kd(t);n<i;++n)e[n]&&++a[e[n]-1];var s=new kd(t);for(n=1;n<t;++n)s[n]=s[n-1]+a[n-1]<<1;var o;if(r){o=new kd(1<<t);var l=15-t;for(n=0;n<i;++n)if(e[n])for(var u=n<<4|e[n],c=t-e[n],d=s[e[n]-1]++<<c,h=d|(1<<c)-1;d<=h;++d)o[l3[d]>>l]=u}else for(o=new kd(i),n=0;n<i;++n)e[n]&&(o[n]=l3[s[e[n]-1]++]>>15-e[n]);return o}
1546),Cg=new pa(288);for(var Sr=0;Sr<144;++Sr)Cg[Sr]=8;for(var Sr=144;Sr<256;++Sr)Cg[Sr]=9;for(var Sr=256;Sr<280;++Sr)Cg[Sr]=7;for(var Sr=280;Sr<288;++Sr)Cg[Sr]=8;var kz=new pa(32);for(var Sr=0;Sr<32;++Sr)kz[Sr]=5;var vRe=Fp(Cg,9,1),bRe=Fp(kz,5,1),l2=function(e){for(var t=e[0],r=1;r<e.length;++r)e[r]>t&&(t=e[r]);return t},hs=function(e,t,r){var i=t/8|0;return(e[i]|e[i+1]<<8)>>(t&7)&r},u2=function(e,t){var r=t/8|0;return(e[r]|e[r+1]<<8|e[r+2]<<16)>>(t&7)},xRe=function(e){return(e+7)/8|0},wRe=function(e,t,r){return(r==null||r>e.length)&&(r=e.length),new pa(e.subarray(t,r))},$Re=["unexpected EOF","invalid block type","invalid length/literal","invalid distance","stream finished","no stream handler",,"no callback","invalid UTF-8 data","extra field too long","date not in range 1980-2099","filename too long","stream finishing","invalid zip data"],la=function(e,t,r){var i=new Error(t||$Re[e]);if(i.code=e,Error.captureStackTrace&&Error.captureStackTrace(i,la),!r)throw i;return i},LS=function(e,t,r,i){var n=e.length,a=0;if(!n||t.f&&!t.l)return r||new pa(0);var s=!r,o=s||t.i!=2,l=t.i;s&&(r=new pa(n*3));var u=function(Be){var qe=r.length;if(Be>qe){var j=new pa(Math.max(qe*2,Be));j.set(r),r=j}},c=t.f||0,d=t.p||0,h=t.b||0,f=t.l,p=t.d,m=t.m,g=t.n,v=n*8;do{if(!f){c=hs(e,d,1);var x=hs(e,d+1,3);if(d+=3,x)if(x==1)f=vRe,p=bRe,m=9,g=5;else if(x==2){var $=hs(e,d,31)+257,S=hs(e,d+10,15)+4,E=$+hs(e,d+5,31)+1;d+=14;for(var C=new pa(E),I=new pa(19),P=0;P<S;++P)I[mRe[P]]=hs(e,d+P*3,7);d+=S*3;for(var T=l2(I),D=(1<<T)-1,A=Fp(I,T,1),P=0;P<E;){var z=A[hs(e,d,D)];d+=z&15;var _=z>>4;if(_<16)C[P++]=_;else{var R=0,O=0;for(_==16?(O=3+hs(e,d,3),d+=2,R=C[P-1]):_==17?(O=3+hs(e,d,7),d+=3):_==18&&(O=11+hs(e,d,127),d+=7);O--;)C[P++]=R}}var V=C.subarray(0,$),Y=C.subarray($);m=l2(V),g=l2(Y),f=Fp(V,m,1),p=Fp(Y,g,1)}else la(1);else{var _=xRe(d)+4,y=e[_-4]|e[_-3]<<8,w=_+y;if(w>n){l&&la(0);break}o&&u(h+y),r.set(e.subarray(_,w),h),t.b=h+=y,t.p=d=w*8,t.f=c;continue}if(d>v){l&&la(0);break}}o&&u(h+131072);for(var F=(1<<m)-1,ae=(1<<g)-1,ue=d;;ue=d){var R=f[u2(e,d)&F],Z=R>>4;if(d+=R&15,d>v){l&&la(0);break}if(R||la(2),Z<256)r[h++]=Z;else if(Z==256){ue=d,f=null;break}else{var K=Z-254;if(Z>264){var P=Z-257,fe=wz[P];K=hs(e,d,(1<<fe)-1)+Cz[P],d+=fe}var ve=p[u2(e,d)&ae],$e=ve>>4;ve||la(3),d+=ve&15;var Y=yRe[$e];if($e>3){var fe=$z[$e];Y+=u2(e,d)&(1<<fe)-1,d+=fe}if(d>v){l&&la(0);break}o&&u(h+131072);var Re=h+K;if(h<Y){var Oe=a-Y,ze=Math.min(Y,Re);for(Oe+h<0&&la(3);h<ze;++h)r[h]=i[Oe+h]}for(;h<Re;++h)r[h]=r[h-Y]}}t.l=f,t.p=ue,t.b=h,t.f=c,f&&(c=1,t.m=m,t.d=p,t.n=g)}while(!c);return h!=r.length&&s?wRe(r,0,h):r.subarray(0,h)},SRe=new pa(0),TRe=function(e){(e[0]!=31||e[1]!=139||e[2]!=8)&&la(6,"invalid gzip data");var t=e[3],r=10;t&4&&(r+=(e[10]|e[11]<<8)+2);for(var i=(t>>3&1)+(t>>4&1);i>0;i-=!e[r++]);return r+(t&2)},CRe=function(e){var t=e.length;return(e[t-4]|e[t-3]<<8|e[t-2]<<16|e[t-1]<<24)>>>0},kRe=function(e,t){return((e[0]&15)!=8||e[0]>>4>7||(e[0]<<8|e[1])%31)&&la(6,"invalid zlib data"),(e[1]>>5&1)==1&&la(6,"invalid zlib data: "+(e[1]&32?"need":"unexpected")+" dictionary"),(e[1]>>3&4)+2};function ERe(e,t){return LS(e,{i:2},t,t)}function PRe(e,t){var r=TRe(e);return r+8>e.length&&la(6,"invalid gzip data"),LS(e.subarray(r,-8),{i:2},new pa(CRe(e)),t)}function MRe(e,t){return LS(e.subarray(kRe(e),-4),{i:2},t,t)}function IRe(e,t){return e[0]==31&&e[1]==139&&e[2]==8?PRe(e,t):(e[0]&15)!=8||e[0]>>4>7||(e[0]<<8|e[1])%31?ERe(e,t):MRe(e,t)}var ARe=typeof TextDecoder<"u"&&new TextDecoder,DRe=0;try{ARe.decode(SRe,{stream:!0}),DRe=1}catch{}var RRe=Object.defineProperty,ORe=Math.pow,sr=(e,t)=>RRe(e,"name",{value:t,configurable:!0}),ki=(e,t,r)=>new Promise((i,n)=>{var a=l=>{try{o(r.next(l))}catch(u){n(u)}},s=l=>{try{o(r.throw(l))}catch(u){n(u)}},o=l=>l.done?i(l.value):Promise.resolve(l.value).then(a,s);o((r=r.apply(e,t)).next())});sr((e,t)=>{let r=!1,i="",n=L.GridLayer.extend({createTile:sr((a,s)=>{let o=document.createElement("img"),l=new AbortController,u=l.signal;return o.cancel=()=>{l.abort()},r||(e.getHeader().then(c=>{c.tileType===1||c.tileType===6?console.error("Error: archive contains vector tiles, but leafletRasterLayer is for displaying raster tiles. See https://github.com/protomaps/PMTiles/tree/main/js for details."):c.tileType===2?i="image/png":c.tileType===3?i="image/jpeg":c.tileType===4?i="image/webp":c.tileType===5&&(i="image/avif")}),r=!0),e.getZxy(a.z,a.x,a.y,u).then(c=>{if(c){let d=new Blob([c.data],{type:i}),h=window.URL.createObjectURL(d);o.src=h}else o.style.display="none";o.cancel=void 0,s(void 0,o)}).catch(c=>{if(c.name!=="AbortError")throw c}),o},"createTile"),_removeTile:sr(function(a){let s=this._tiles[a];s&&(s.el.cancel&&s.el.cancel(),s.el.src&&window.URL.revokeObjectURL(s.el.src),s.el.width=0,s.el.height=0,s.el.deleted=!0,L.DomUtil.remove(s.el),delete this._tiles[a],this.fire("tileunload",{tile:s.el,coords:this._keyToTileCoords(a)}))},"_removeTile")});return new n(t)},"leafletRasterLayer");var LRe=sr(e=>(t,r)=>{if(r instanceof AbortController)return e(t,r);let i=new AbortController;return e(t,i).then(n=>r(void 0,n.data,n.cacheControl||"",n.expires||""),n=>r(n)).catch(n=>r(n)),{cancel:sr(()=>i.abort(),"cancel")}},"v3compat"),Ez=class{constructor(t){this.tilev4=sr((r,i)=>ki(this,null,function*(){if(r.type==="json"){let f=r.url.substr(10),p=this.tiles.get(f);if(p||(p=new eP(f),this.tiles.set(f,p)),this.metadata){let g=yield p.getTileJson(r.url);return i.signal.throwIfAborted(),{data:g}}let m=yield p.getHeader();return i.signal.throwIfAborted(),(m.minLon>=m.maxLon||m.minLat>=m.maxLat)&&console.error(`Bounds of PMTiles archive ${m.minLon},${m.minLat},${m.maxLon},${m.maxLat} are not valid.`),{data:{tiles:[`${r.url}/{z}/{x}/{y}`],minzoom:m.minZoom,maxzoom:m.maxZoom,bounds:[m.minLon,m.minLat,m.maxLon,m.maxLat]}}}let n=new RegExp(/pmtiles:\/\/(.+)\/(\d+)\/(\d+)\/(\d+)/),a=r.url.match(n);if(!a)throw new Error("Invalid PMTiles protocol URL");let s=a[1],o=this.tiles.get(s);o||(o=new eP(s),this.tiles.set(s,o));let l=a[2],u=a[3],c=a[4],d=yield o==null?void 0:o.getZxy(+l,+u,+c,i.signal);if(i.signal.throwIfAborted(),d)return{data:new Uint8Array(d.data),cacheControl:d.cacheControl,expires:d.expires};let h=yield o.getHeader();if(h.tileType===1||h.tileType===6){if(this.errorOnMissingTile)throw new Error("Tile not found.");return{data:new Uint8Array}}return{data:null}}),"tilev4"),this.tile=LRe(this.tilev4),this.tiles=new Map,this.metadata=(t==null?void 0:t.metadata)||!1,this.errorOnMissingTile=(t==null?void 0:t.errorOnMissingTile)||!1}add(t){this.tiles.set(t.source.getKey(),t)}get(t){return this.tiles.get(t)}};sr(Ez,"Protocol");var FRe=Ez;function Pz(e,t){return(t>>>0)*4294967296+(e>>>0)}sr(Pz,"toNum");function Mz(e,t){let r=t.buf,i=r[t.pos++],n=(i&112)>>4;if(i<128||(i=r[t.pos++],n|=(i&127)<<3,i<128)||(i=r[t.pos++],n|=(i&127)<<10,i<128)||(i=r[t.pos++],n|=(i&127)<<17,i<128)||(i=r[t.pos++],n|=(i&127)<<24,i<128)||(i=r[t.pos++],n|=(i&1)<<31,i<128))return Pz(e,n);throw new Error("Expected varint not more than 10 bytes")}sr(Mz,"readVarintRemainder");function md(e){let t=e.buf,r=t[e.pos++],i=r&127;return r<128||(r=t[e.pos++],i|=(r&127)<<7,r<128)||(r=t[e.pos++],i|=(r&127)<<14,r<128)||(r=t[e.pos++],i|=(r&127)<<21,r<128)?
vendor: 2,890 bytes, line 1546
1546i:(r=t[e.pos],i|=(r&15)<<28,Mz(i,e))}sr(md,"readVarint");function FS(e,t,r,i,n){return n===0?i!==0?[e-1-r,e-1-t]:[r,t]:[t,r]}sr(FS,"rotate");function Iz(e,t,r){if(e>26)throw new Error("Tile zoom level exceeds max safe number limit (26)");if(t>=1<<e||r>=1<<e)throw new Error("tile x/y outside zoom level bounds");let i=((1<<e)*(1<<e)-1)/3,n=e-1,[a,s]=[t,r];for(let o=1<<n;o>0;o>>=1){let l=a&o,u=s&o;i+=(3*l^u)*(1<<n),[a,s]=FS(o,a,s,l,u),n--}return i}sr(Iz,"zxyToTileId");function Az(e){let t=3*e+1;return t<4294967296?31-Math.clz32(t):63-Math.clz32(t/4294967296)}sr(Az,"tileIdToZ");function zRe(e){let t=Az(e)>>1;if(t>26)throw new Error("Tile zoom level exceeds max safe number limit (26)");let r=((1<<t)*(1<<t)-1)/3,i=e-r,n=0,a=0,s=1<<t;for(let o=1;o<s;o<<=1){let l=o&i/2,u=o&(i^l);[n,a]=FS(o,n,a,l,u),i=i/2,n+=l,a+=u}return[t,n,a]}sr(zRe,"tileIdToZxy");var NRe=(e=>(e[e.Unknown=0]="Unknown",e[e.None=1]="None",e[e.Gzip=2]="Gzip",e[e.Brotli=3]="Brotli",e[e.Zstd=4]="Zstd",e))(NRe||{});function bv(e,t){return ki(this,null,function*(){if(t===1||t===0)return e;if(t===2){if(typeof globalThis.DecompressionStream>"u")return IRe(new Uint8Array(e));let r=new Response(e).body;if(!r)throw new Error("Failed to read response stream");let i=r.pipeThrough(new globalThis.DecompressionStream("gzip"));return new Response(i).arrayBuffer()}throw new Error("Compression method not supported")})}sr(bv,"defaultDecompress");var BRe=(e=>(e[e.Unknown=0]="Unknown",e[e.Mvt=1]="Mvt",e[e.Png=2]="Png",e[e.Jpeg=3]="Jpeg",e[e.Webp=4]="Webp",e[e.Avif=5]="Avif",e[e.Mlt=6]="Mlt",e))(BRe||{});function Dz(e){return e===1?".mvt":e===2?".png":e===3?".jpg":e===4?".webp":e===5?".avif":e===6?".mlt":""}sr(Dz,"tileTypeExt");var jRe=127;function Rz(e,t){let r=0,i=e.length-1;for(;r<=i;){let n=i+r>>1,a=t-e[n].tileId;if(a>0)r=n+1;else if(a<0)i=n-1;else return e[n]}return i>=0&&(e[i].runLength===0||t-e[i].tileId<e[i].runLength)?e[i]:null}sr(Rz,"findTile");var URe=class{constructor(t){this.file=t}getKey(){return this.file.name}getBytes(t,r){return ki(this,null,function*(){return{data:yield this.file.slice(t,t+r).arrayBuffer()}})}};sr(URe,"FileSource");var Oz=class{constructor(t,r=new Headers,i=void 0){var n,a;this.url=t,this.customHeaders=r,this.credentials=i,this.mustReload=!1;let s="";"navigator"in globalThis&&(s=(a=(n=globalThis.navigator)==null?void 0:n.userAgent)!=null?a:"");let o=s.indexOf("Windows")>-1,l=/Chrome|Chromium|Edg|OPR|Brave/.test(s);this.chromeWindowsNoCache=!1,o&&l&&(this.chromeWindowsNoCache=!0)}getKey(){return this.url}setHeaders(t){this.customHeaders=t}getBytes(t,r,i,n){return ki(this,null,function*(){let a,s;i?s=i:(a=new AbortController,s=a.signal);let o=new Headers(this.customHeaders);o.set("range",`bytes=${t}-${t+r-1}`);let l;this.mustReload?l="reload":this.chromeWindowsNoCache&&(l="no-store");let u=yield fetch(this.url,{signal:s,cache:l,headers:o,credentials:this.credentials});
vendor: 5,418 bytes, line 1546
1546if(t===0&&u.status===416){let h=u.headers.get("Content-Range");if(!h||!h.startsWith("bytes */"))throw new Error("Missing content-length on 416 response");let f=+h.substr(8);o.set("range",`bytes=0-${f-1}`),u=yield fetch(this.url,{signal:s,cache:"reload",headers:o,credentials:this.credentials})}let c=u.headers.get("Etag");if(c!=null&&c.startsWith("W/")&&(c=null),u.status===416||n&&c&&c!==n)throw this.mustReload=!0,new u3(`Server returned non-matching ETag ${n} after one retry. Check browser extensions and servers for issues that may affect correct ETag headers.`);if(u.status>=300)throw new Error(`Bad response code: ${u.status}`);let d=u.headers.get("Content-Length");if(u.status===200&&(!d||+d>r))throw a&&a.abort(),new Error("Server returned no content-length header or content-length exceeding request. Check that your storage backend supports HTTP Byte Serving.");return{data:yield u.arrayBuffer(),etag:c||void 0,cacheControl:u.headers.get("Cache-Control")||void 0,expires:u.headers.get("Expires")||void 0}})}};sr(Oz,"FetchSource");var VRe=Oz;function Oa(e,t){let r=e.getUint32(t+4,!0),i=e.getUint32(t+0,!0);return r*ORe(2,32)+i}sr(Oa,"getUint64");function Lz(e,t){let r=new DataView(e),i=r.getUint8(7);if(i>3)throw new Error(`Archive is spec version ${i} but this library supports up to spec version 3`);return{specVersion:i,rootDirectoryOffset:Oa(r,8),rootDirectoryLength:Oa(r,16),jsonMetadataOffset:Oa(r,24),jsonMetadataLength:Oa(r,32),leafDirectoryOffset:Oa(r,40),leafDirectoryLength:Oa(r,48),tileDataOffset:Oa(r,56),tileDataLength:Oa(r,64),numAddressedTiles:Oa(r,72),numTileEntries:Oa(r,80),numTileContents:Oa(r,88),clustered:r.getUint8(96)===1,internalCompression:r.getUint8(97),tileCompression:r.getUint8(98),tileType:r.getUint8(99),minZoom:r.getUint8(100),maxZoom:r.getUint8(101),minLon:r.getInt32(102,!0)/1e7,minLat:r.getInt32(106,!0)/1e7,maxLon:r.getInt32(110,!0)/1e7,maxLat:r.getInt32(114,!0)/1e7,centerZoom:r.getUint8(118),centerLon:r.getInt32(119,!0)/1e7,centerLat:r.getInt32(123,!0)/1e7,etag:t}}sr(Lz,"bytesToHeader");function zS(e){let t={buf:new Uint8Array(e),pos:0},r=md(t),i=[],n=0;for(let a=0;a<r;a++){let s=md(t);i.push({tileId:n+s,offset:0,length:0,runLength:1}),n+=s}for(let a=0;a<r;a++)i[a].runLength=md(t);for(let a=0;a<r;a++)i[a].length=md(t);for(let a=0;a<r;a++){let s=md(t);s===0&&a>0?i[a].offset=i[a-1].offset+i[a-1].length:i[a].offset=s-1}return i}sr(zS,"deserializeIndex");var Fz=class extends Error{};sr(Fz,"EtagMismatch");var u3=Fz;function NS(e,t){return ki(this,null,function*(){let r=yield e.getBytes(0,16384);if(new DataView(r.data).getUint16(0,!0)!==19792)throw new Error("Wrong magic number for PMTiles archive");let i=r.data.slice(0,jRe),n=Lz(i,r.etag),a=r.data.slice(n.rootDirectoryOffset,n.rootDirectoryOffset+n.rootDirectoryLength),s=`${e.getKey()}|${n.etag||""}|${n.rootDirectoryOffset}|${n.rootDirectoryLength}`,o=zS(yield t(a,n.internalCompression));return[n,[s,o.length,o]]})}sr(NS,"getHeaderAndRoot");function BS(e,t,r,i,n){return ki(this,null,function*(){let a=yield e.getBytes(r,i,void 0,n.etag),s=yield t(a.data,n.internalCompression),o=zS(s);if(o.length===0)throw new Error("Empty directory is invalid");return o})}sr(BS,"getDirectory");var qRe=class{constructor(t=100,r=!0,i=bv){this.cache=new Map,this.maxCacheEntries=t,this.counter=1,this.decompress=i}getHeader(t){return ki(this,null,function*(){let r=t.getKey(),i=this.cache.get(r);if(i)return i.lastUsed=this.counter++,i.data;let n=yield NS(t,this.decompress);return n[1]&&this.cache.set(n[1][0],{lastUsed:this.counter++,data:n[1][2]}),this.cache.set(r,{lastUsed:this.counter++,data:n[0]}),this.prune(),n[0]})}getDirectory(t,r,i,n){return ki(this,null,function*(){let a=`${t.getKey()}|${n.etag||""}|${r}|${i}`,s=this.cache.get(a);if(s)return s.lastUsed=this.counter++,s.data;let o=yield BS(t,this.decompress,r,i,n);return this.cache.set(a,{lastUsed:this.counter++,data:o}),this.prune(),o})}prune(){if(this.cache.size>this.maxCacheEntries){let t=1/0,r;this.cache.forEach((i,n)=>{i.lastUsed<t&&(t=i.lastUsed,r=n)}),r&&this.cache.delete(r)}}invalidate(t){return ki(this,null,function*(){this.cache.delete(t.getKey())})}};sr(qRe,"ResolvedValueCache");var zz=class{constructor(t=100,r=!0,i=bv){this.cache=new Map,this.invalidations=new Map,this.maxCacheEntries=t,this.counter=1,this.decompress=i}getHeader(t){return ki(this,null,function*(){let r=t.getKey(),i=this.cache.get(r);if(i)return i.lastUsed=this.counter++,yield i.data;let n=new Promise((a,s)=>{NS(t,this.decompress).then(o=>{o[1]&&this.cache.set(o[1][0],{lastUsed:this.counter++,data:Promise.resolve(o[1][2])}),a(o[0]),this.prune()}).catch(o=>{s(o)})});return this.cache.set(r,{lastUsed:this.counter++,data:n}),n})}getDirectory(t,r,i,n){return ki(this,null,function*(){let a=`${t.getKey()}|${n.etag||""}|${r}|${i}`,s=this.cache.get(a);if(s)return s.lastUsed=this.counter++,yield s.data;let o=new Promise((l,u)=>{BS(t,this.decompress,r,i,n).then(c=>{l(c),this.prune()}).catch(c=>{u(c)})});return this.cache.set(a,{lastUsed:this.counter++,data:o}),o})}prune(){if(this.cache.size>=this.maxCacheEntries){let t=1/0,r;this.cache.forEach((i,n)=>{i.lastUsed<t&&(t=i.lastUsed,r=n)}),r&&this.cache.delete(r)}}invalidate(t){return ki(this,null,function*(){let r=t.getKey();if(this.invalidations.get(r))return yield this.invalidations.get(r);this.cache.delete(t.getKey());let i=new Promise((n,a)=>{this.getHeader(t).then(s=>{n(),this.invalidations.delete(r)}
1546).catch(s=>{a(s)})});this.invalidations.set(r,i)})}};sr(zz,"SharedPromiseCache");var GRe=zz,Nz=class{constructor(t,r,i){typeof t=="string"?this.source=new VRe(t):this.source=t,i?this.decompress=i:this.decompress=bv,r?this.cache=r:this.cache=new GRe}getHeader(){return ki(this,null,function*(){return yield this.cache.getHeader(this.source)})}getZxyAttempt(t,r,i,n){return ki(this,null,function*(){let a=Iz(t,r,i),s=yield this.cache.getHeader(this.source);if(t<s.minZoom||t>s.maxZoom)return;let o=s.rootDirectoryOffset,l=s.rootDirectoryLength;for(let u=0;u<=3;u++){let c=yield this.cache.getDirectory(this.source,o,l,s),d=Rz(c,a);if(d){if(d.runLength>0){let h=yield this.source.getBytes(s.tileDataOffset+d.offset,d.length,n,s.etag);return{data:yield this.decompress(h.data,s.tileCompression),cacheControl:h.cacheControl,expires:h.expires}}o=s.leafDirectoryOffset+d.offset,l=d.length}else return}throw new Error("Maximum directory depth exceeded")})}getZxy(t,r,i,n){return ki(this,null,function*(){try{return yield this.getZxyAttempt(t,r,i,n)}catch(a){if(a instanceof u3)return this.cache.invalidate(this.source),yield this.getZxyAttempt(t,r,i,n);throw a}})}getMetadataAttempt(){return ki(this,null,function*(){let t=yield this.cache.getHeader(this.source),r=yield this.source.getBytes(t.jsonMetadataOffset,t.jsonMetadataLength,void 0,t.etag),i=yield this.decompress(r.data,t.internalCompression),n=new TextDecoder("utf-8");return JSON.parse(n.decode(i))})}getMetadata(){return ki(this,null,function*(){try{return yield this.getMetadataAttempt()}catch(t){if(t instanceof u3)return this.cache.invalidate(this.source),yield this.getMetadataAttempt();throw t}})}getTileJson(t){return ki(this,null,function*(){let r=yield this.getHeader(),i=yield this.getMetadata(),n=Dz(r.tileType);return{tilejson:"3.0.0",scheme:"xyz",tiles:[`${t}/{z}/{x}/{y}${n}`],vector_layers:i.vector_layers,attribution:i.attribution,description:i.description,name:i.name,version:i.version,bounds:[r.minLon,r.minLat,r.maxLon,r.maxLat],center:[r.centerLon,r.centerLat,r.centerZoom],minzoom:r.minZoom,maxzoom:r.maxZoom}})}};sr(Nz,"PMTiles");var eP=Nz;let rd=null;function HRe(){if(rd)return rd;rd=new FRe;try{Dk("pmtiles",rd.tile)}catch{lSe("pmtiles"),Dk("pmtiles",rd.tile)}return rd}const Bz="https://storage.googleapis.com/ag-geo-tiles/manifest.json",YRe=new Set(["gates","destinations"]);function WRe(e,t){if(!t||typeof t!="object")return console.warn(`[ag-map] layer "${e}" skipped: entry is not an object`),null;if(typeof t.url!="string"||!t.url)return console.warn(`[ag-map] layer "${e}" skipped: missing "url"`),null;const r=t.type==="live"?"live":"static";t.type!=="live"&&t.type!=="static"&&console.warn(`[ag-map] layer "${e}": unknown type "${t.type}", treating as static`);const i=t.format==="geojson"?"geojson":"pmtiles";t.format!==void 0&&t.format!=="geojson"&&t.format!=="pmtiles"&&console.warn(`[ag-map] layer "${e}": unknown format "${t.format}", treating as pmtiles`);const n=t.vector_layer||e;return i!=="geojson"&&typeof t.vector_layer!="string"&&console.warn(`[ag-map] layer "${e}": no "vector_layer", falling back to "${n}"`),{id:e,url:t.url,vectorLayer:n,format:i,type:r,minzoom:Number.isFinite(t.minzoom)?t.minzoom:void 0,maxzoom:Number.isFinite(t.maxzoom)?t.maxzoom:void 0,attribution:typeof t.attribution=="string"?t.attribution:void 0,features:Number.isFinite(t.features)?t.features:void 0,updatedAt:t.updated_at}}async function tP(e=Bz,t){const r=await fetch(e,{signal:t});if(!r.ok)throw new Error(`[ag-map] manifest fetch failed: ${r.status} ${r.statusText}`);const i=await r.json();if(!i||typeof i.layers!="object"||i.layers===null)throw new Error('[ag-map] manifest has no "layers" object');const n=Object.entries(i.layers).filter(([a])=>!YRe.has(a)).map(([a,s])=>WRe(a,s)).filter(Boolean);return n.length||console.warn("[ag-map] manifest contained no usable layers"),{version:i.version,generatedAt:i.generated_at,layers:n}}function ZRe(e){return[...new Set(e.map(t=>t.attribution).filter(Boolean))]}const Ed=e=>`ag-src-${e}`,KRe=14,jz=new Set(["boundaries","lodges","destinations"]),XRe=e=>jz.has(e.id),c3=e=>e.format==="geojson";function JRe(e){const t=c3(e)?{type:"geojson",data:e.url}:{type:"vector",url:`pmtiles://${e.url}`};return c3(e)||(e.minzoom!==void 0&&(t.minzoom=e.minzoom),e.maxzoom!==void 0&&(t.maxzoom=e.maxzoom)),e.attribution&&(t.attribution=e.attribution),jz.has(e.id)&&(t.promoteId="location_id"),t}const Tl=(e,t)=>
1546["case",["boolean",["feature-state","hover"],!1],t,e],Um=["==",["geometry-type"],"Polygon"],c2=["==",["geometry-type"],"LineString"],Ru=["==",["geometry-type"],"Point"],rP=e=>t=>[{id:`ag-${t.id}-fill`,type:"fill",filter:Um,paint:{"fill-color":e,"fill-opacity":.4}},{id:`ag-${t.id}-edge`,type:"line",filter:Um,paint:{"line-color":e,"line-width":.8,"line-opacity":.75}}],gd=e=>`ag-src-${e}-labels`,QRe=new Set(["boundaries","protected_areas"]),eOe={protected_areas:"area_id"},tOe=e=>eOe[e.id]??"location_id",d3=e=>QRe.has(e.id),Uz=["coalesce",["get","name"],""],rOe=["format",Uz,{},["case",["!",["has","country"]],"",["has","name"],["concat",` 1547`,["get","country"]],["get","country"]],{"font-scale":.82}],iP={boundaries:{field:rOe,size:["interpolate",["linear"],["zoom"],3,10,7,12,10,14]},protected_areas:{field:Uz,size:["interpolate",["linear"],["zoom"],3,8.5,7,10,10,11.5]}};function h3(e){if(typeof e=="string")return e;const t=(e==null?void 0:e.value)??(e==null?void 0:e.key);return typeof t=="string"?t:null}function iOe(e){const t=Array.isArray(e)?e:e==null?void 0:e.label_overrides,r={};if(!Array.isArray(t))return r;for(const i of t){const n=h3(i==null?void 0:i.layer),a=typeof(i==null?void 0:i.original)=="string"?i.original.trim():"",s=typeof(i==null?void 0:i.replacement)=="string"?i.replacement.trim():"";typeof n!="string"||!n||!a||!s||(r[n]??(r[n]={}),r[n][a]=s)}return r}const w_="ag-src-custom-areas",nOe=3,jS=0,US=24;function Zy(e,t){const r=typeof e=="number"?e:Number.parseFloat(e);return Number.isFinite(r)?Math.min(Math.max(r,jS),US):t}function Vz(e){if(typeof e!="string")return null;const[t,r]=e.split(",").map(i=>Number.parseFloat(i));return!Number.isFinite(t)||!Number.isFinite(r)||Math.abs(t)>180||Math.abs(r)>90?null:[t,r]}function aOe(e){if(typeof e!="string")return null;const t=[];for(const n of e.split(/\r?\n/)){if(!n.trim())continue;const a=Vz(n);a&&t.push(a)}if(t.length<nOe)return null;const[r]=t,i=t[t.length-1];return(r[0]!==i[0]||r[1]!==i[1])&&t.push([...r]),t}function sOe(e){const t=Array.isArray(e)?e:e==null?void 0:e.custom_areas,r=[];if(!Array.isArray(t))return{type:"FeatureCollection",features:r};for(const i of t){const n=typeof(i==null?void 0:i.name)=="string"?i.name.trim():"",a=aOe(i==null?void 0:i.points);!n||!a||r.push({type:"Feature",properties:{name:n,color:typeof(i==null?void 0:i.color)=="string"?i.color:Ge.boundaryNationalPark,minzoom:Zy(i==null?void 0:i.min_zoom,jS),maxzoom:Zy(i==null?void 0:i.max_zoom,US)},geometry:{type:"Polygon",coordinates:[a]}})}return{type:"FeatureCollection",features:r}}const oOe=e=>["all",["<=",["get","minzoom"],e],[">=",["get","maxzoom"],e]];function lOe(){return[{id:"ag-custom-areas-fill",type:"fill",source:w_,paint:{"fill-color":["get","color"],"fill-opacity":.3}},{id:"ag-custom-areas-outline",type:"line",source:w_,layout:{"line-join":"round"},paint:{"line-color":["get","color"],"line-width":1.4,"line-opacity":.9}},{id:"ag-custom-areas-label",type:"symbol",source:w_,minzoom:3,layout:{"text-field":["get","name"],"text-font":["Noto Sans Regular"],"text-size":["interpolate",["linear"],["zoom"],3,10,7,12,10,14],"text-max-width":9,"text-padding":2},paint:{"text-color":Ge.parkLabel,"text-halo-color":Ge.parkLabelHalo,"text-halo-width":1.4}}]}const f3="ag-src-custom-labels",nP={small:.8,medium:1,large:1.3};function uOe(e){const t=Array.isArray(e)?e:e==null?void 0:e.custom_labels,r=[];if(!Array.isArray(t))return{type:"FeatureCollection",features:r};for(const i of t){const n=typeof(i==null?void 0:i.label)=="string"?i.label.trim():"",a=Vz(i==null?void 0:i.coordinates);if(!n||!a)continue;cOe(n,a);const s=h3(i==null?void 0:i.style);r.push({type:"Feature",properties:{label:n,color:typeof(i==null?void 0:i.color)=="string"?i.color:Ge.parkLabel,scale:nP[h3(i==null?void 0:i.size)]??nP.medium,italic:s==="italic",uppercase:s==="uppercase",marker:(i==null?void 0:i.marker)!==!1,minzoom:Zy(i==null?void 0:i.min_zoom,jS),maxzoom:Zy(i==null?void 0:i.max_zoom,US)},geometry:{type:"Point",coordinates:a}})}return{type:"FeatureCollection",features:r}}const aP=new Set;function cOe(e,[t,r]){const[[i,n],[a,s]]=Wy;t>=i&&t<=a&&r>=n&&r<=s||aP.has(e)||(aP.add(e),console.warn(`[ag-map] custom label "${e}" at ${t}, ${r} falls outside the mapped region - check the coordinate is longitude first, then latitude.`))}const id=e=>["boolean",["get",e],!1],O0=e=>
1547["*",e,["coalesce",["get","scale"],1]];function dOe(){return[{id:"ag-custom-labels-dot",type:"circle",source:f3,filter:id("marker"),paint:{"circle-radius":["interpolate",["linear"],["zoom"],3,O0(3),10,O0(5.5)],"circle-color":["get","color"],"circle-stroke-width":1.4,"circle-stroke-color":"#ffffff","circle-opacity":.95}},{id:"ag-custom-labels-label",type:"symbol",source:f3,layout:{"text-field":["get","label"],"text-font":["case",id("italic"),["literal",["Noto Sans Italic"]],["literal",["Noto Sans Regular"]]],"text-transform":["case",id("uppercase"),"uppercase","none"],"text-letter-spacing":["case",id("uppercase"),.08,0],"text-size":["interpolate",["linear"],["zoom"],3,O0(10),10,O0(14)],"text-offset":["case",id("marker"),["literal",[0,.9]],["literal",[0,0]]],"text-anchor":["case",id("marker"),"top","center"],"text-max-width":10,"text-padding":2,"text-allow-overlap":!0},paint:{"text-color":["get","color"],"text-halo-color":Ge.parkLabelHalo,"text-halo-width":1.4}}]}function hOe(e,t){if(!t)return e;let r=!1;const i=e.features.map(n=>{var s;const a=t[(s=n.properties)==null?void 0:s.name];return a?(r=!0,{...n,properties:{...n.properties,name:a}}):n});return r?{...e,features:i}:e}function sP(e,t=!0){if(!d3(e))return null;const r=iP[e.id]??iP.boundaries;return{id:`ag-${e.id}-label`,type:"symbol",source:gd(e.id),minzoom:3,layout:{"text-field":r.field,"text-font":["Noto Sans Regular"],"text-size":r.size,"text-max-width":9,"text-line-height":1.25,"text-padding":2,visibility:t?"visible":"none"},paint:{"text-color":Ge.parkLabel,"text-halo-color":Ge.parkLabelHalo,"text-halo-width":1.4},metadata:{agLayer:e.id,agInteractive:!1,agFeature:"parkNames"}}}const oP=["match",["get","boundary_class"],"national_park",Ge.protectedNationalPark,"national_reserve",Ge.protectedNatureReserve,"game_reserve",Ge.protectedNatureReserve,"private_reserve",Ge.protectedPrivateReserve,Ge.protectedAreaEdge],lP={boundaries:e=>[{id:`ag-${e.id}-fill`,type:"fill",paint:{"fill-color":["match",["get","boundary_type"],"national_park",Ge.boundaryNationalPark,"nature_reserve",Ge.boundaryNatureReserve,"protected_area",Ge.boundaryProtectedArea,Ge.generic],"fill-opacity":.35},interactive:!0},{id:`ag-${e.id}-outline`,type:"line",paint:{"line-color":Ge.outline,"line-width":.8,"line-opacity":.9}}],lodges:e=>[{id:`ag-${e.id}-pin`,type:"circle",paint:{"circle-radius":["interpolate",["linear"],["zoom"],6,Tl(3.5,5),10,Tl(6,8)],"circle-color":Ge.lodge,"circle-stroke-width":1.5,"circle-stroke-color":"#ffffff","circle-opacity":Tl(.9,1)},interactive:!0}],roads:e=>[{id:`ag-${e.id}-casing`,type:"line",filter:c2,layout:{"line-join":"round","line-cap":"round"},paint:{"line-color":Ge.roadCasing,"line-width":["interpolate",["linear"],["zoom"],7,1.8,12,6],"line-opacity":.7}},{id:`ag-${e.id}-line`,type:"line",filter:c2,layout:{"line-join":"round","line-cap":"round"},paint:{"line-color":Ge.road,"line-width":["interpolate",["linear"],["zoom"],7,.6,12,2.6]}}],trails:e=>[{id:`ag-${e.id}-line`,type:"line",filter:c2,layout:{"line-join":"round","line-cap":"butt"},paint:{"line-color":Ge.trail,"line-width":["interpolate",["linear"],["zoom"],8,.6,12,1.8],"line-dasharray":[2,2],"line-opacity":.9}}],settlements:e=>[{id:`ag-${e.id}-point`,type:"circle",filter:Ru,paint:{"circle-radius":["interpolate",["linear"],["zoom"],6,2.5,12,5.5],"circle-color":Ge.settlement,"circle-stroke-width":1,"circle-stroke-color":"#ffffff","circle-opacity":.95},interactive:!0}],protected_areas:e=>[{id:`ag-${e.id}-fill`,type:"fill",filter:Um,paint:{"fill-color":oP,"fill-opacity":.2}},{id:`ag-${e.id}-edge`,type:"line",filter:Um,layout:{"line-join":"round"},paint:{"line-color":oP,"line-width":["interpolate",["linear"],["zoom"],3,.6,10,1.6],"line-opacity":.85},interactive:!0}],airstrips:e=>[{id:`ag-${e.id}-major`,type:"circle",filter:["all",Ru,["in",["get","type"],["literal",["large_airport","medium_airport"]]]],paint:{"circle-radius":["interpolate",["linear"],["zoom"],5,["case",["==",["get","type"],"large_airport"],4,3],12,["case",["==",["get","type"],"large_airport"],7,5.5]],"circle-color":Ge.airstrip,"circle-stroke-width":1.2,"circle-stroke-color":"#ffffff","circle-opacity":.95},interactive:!0},{id:`ag-${e.id}-minor`,type:"circle",filter:["all",Ru,["==",["get","type"],"small_airport"]],minzoom:8,paint:{"circle-radius":["interpolate",["linear"],["zoom"],8,2,12,4],"circle-color":Ge.airstrip,"circle-stroke-width":1,"cir
1547cle-stroke-color":"#ffffff","circle-opacity":.85},interactive:!0},{id:`ag-${e.id}-label`,type:"symbol",filter:Ru,minzoom:9,layout:{"text-field":["coalesce",["get","iata_code"],["get","name"]],"text-font":["Noto Sans Regular"],"text-size":["interpolate",["linear"],["zoom"],9,10,13,12],"text-offset":[0,.9],"text-anchor":"top","text-padding":3},paint:{"text-color":Ge.airstrip,"text-halo-color":Ge.parkLabelHalo,"text-halo-width":1.3},feature:"airstripNames"}],destinations:e=>[{id:`ag-${e.id}-pin`,type:"circle",filter:Ru,paint:{"circle-radius":["interpolate",["linear"],["zoom"],3,["case",["get","is_gateway_city"],Tl(4,5.5),Tl(3,4.5)],10,["case",["get","is_gateway_city"],Tl(8,10),Tl(6.5,8.5)]],"circle-color":Ge.destination,"circle-stroke-width":1.6,"circle-stroke-color":"#ffffff","circle-opacity":Tl(.92,1)},interactive:!0},{id:`ag-${e.id}-label`,type:"symbol",filter:Ru,minzoom:4,layout:{"text-field":["get","name"],"text-font":["Noto Sans Regular"],"text-size":["interpolate",["linear"],["zoom"],4,11,10,14],"text-offset":[0,1],"text-anchor":"top","text-max-width":10,"text-padding":2},paint:{"text-color":Ge.destinationLabel,"text-halo-color":Ge.destinationLabelHalo,"text-halo-width":1.4},feature:"destinationNames"}],flooding:rP(Ge.flooding),migration:rP(Ge.migration)};function fOe(e){return[{id:`ag-${e.id}-fill`,type:"fill",filter:Um,paint:{"fill-color":Ge.generic,"fill-opacity":.25}},{id:`ag-${e.id}-line`,type:"line",filter:["in",["geometry-type"],["literal",["LineString","Polygon"]]],paint:{"line-color":Ge.generic,"line-width":1}},{id:`ag-${e.id}-point`,type:"circle",filter:Ru,paint:{"circle-radius":4,"circle-color":Ge.generic,"circle-stroke-width":1,"circle-stroke-color":"#ffffff"}}]}const uP=new Set;function d2(e,t=!0){const i=(lP[e.id]||fOe)(e);return!lP[e.id]&&!uP.has(e.id)&&(uP.add(e.id),console.info(`[ag-map] layer "${e.id}" has no designed style yet â rendering with the generic geometry-type fallback.`)),i.map(n=>{const{interactive:a,feature:s,...o}=n,l=o.minzoom??e.minzoom,u=o.maxzoom??KRe;return{...o,source:Ed(e.id),...c3(e)?{}:{"source-layer":e.vectorLayer},...l!==void 0?{minzoom:l}:{},...u!==void 0?{maxzoom:u}:{},layout:{...o.layout||{},visibility:t?"visible":"none"},metadata:{agLayer:e.id,agInteractive:!!a,...s?{agFeature:s}:{}}}})}const Uc=[{value:"lodges",label:"Lodge",color:Ge.lodge,layerId:"lodges"},{value:"airstrips",label:"Airport / airstrip",color:Ge.airstrip,layerId:"airstrips"},{value:"settlements",label:"Town",color:Ge.settlement,layerId:"settlements"},{value:"roads",label:"Road",color:Ge.road,layerId:"roads",basemapFeature:"roads",shape:"line"},{value:"boundaries",label:"Park / reserve",color:Ge.boundaryNationalPark,outline:Ge.outline,layerId:"boundaries",shape:"area"},{value:"protected_areas",label:"Protected area",color:Ge.protectedNationalPark,outline:Ge.protectedAreaEdge,layerId:"protected_areas",shape:"area"}],qz=new Set(Uc.map(e=>e.layerId)),pOe=new Set(Uc.map(e=>e.basemapFeature).filter(Boolean));function mOe(e){if(!Array.isArray(e))return null;const t=e.map(r=>typeof r=="string"?r:(r==null?void 0:r.value)??(r==null?void 0:r.key)).filter(r=>Uc.some(i=>i.value===r));return t.length?t:null}function gOe(e,t){return!t||!qz.has(e)?!0:Uc.some(r=>r.layerId===e&&t.includes(r.value))}function _Oe(e,t){return!t||!pOe.has(e)?!0:Uc.some(r=>r.basemapFeature===e&&t.includes(r.value))}function cP(e,t){if(!t||!qz.has(e))return null;const r=Uc.filter(n=>n.layerId===e),i=r.filter(n=>t.includes(n.value));return!i.length||i.length===r.length||i.some(n=>!n.filter)?null:i.length===1?i[0].filter:["any",...i.map(n=>n.filter)]}function yOe(e,t={},r=null){const i=new Set(e.filter(n=>t[n.id]!==!1).map(n=>n.id));return Uc.filter(n=>i.has(n.layerId)&&(!r||r.includes(n.value)))}const dP=new Map,p3=600;function Gz(e,t){var i;if(!e)return;if(e.type==="GeometryCollection"){(i=e.geometries)==null||i.forEach(n=>Gz(n,t));return}const r=n=>{Array.isArray(n)&&(typeof n[0]=="number"?t(n):n.forEach(r))};r(e.coordinates)}function Hz(e){var t;return e?e.type==="Polygon"?e.coordinates[0]?[e.coordinates]:[]:e.type==="MultiPolygon"?e.coordinates.filter(r=>r[0]):e.type==="GeometryCollection"?((t=e.geometries)==null?void 0:t.flatMap(Hz))||[]:[]:[]}function hP(e){let t=0;for(let r=0,i=e.length-1;r<e.length;i=r++)t+=e[i][0]*e[r][1]-e[r][0]*e[i][1];return Math.abs(t)/2}function vOe(e,t){const[r,i]=e;let n=!1;for(const a of t)for(let s=0,o=a.length-1;s<a.length;o=s++){const l=a[s][0],u=a[s][1],c=a[o][0],d=a[o][1];u>i!=d>i&&r<(c-l)*(i-u)/(d-u)+l&&(n=!n)}return n}function Yz(e){const t=e==null?void 0:e[0];if(!t||t.length<3)return null;let r=1/0,i=1/0,n=-1/0,a=-1/0;for(const[u,c]of t)u<r&&(r=u),c<i&&(i=c),u>n&&(n=u),c>a&&(a=c);if(!Number.isFinite(r))return null;const s=[(r+n)/2,(i+a)/2];if(vOe(s,e))return s;let o=null;const l=24;for(let u=1;u<l;u++){const c=i+(a-i)*u/l,d=[];for(const h of e)for(let f=0,p=h.length-1;f<h.length;p=f++){const m=h[f][1],g=h[p][1];if(m!==g&&m>c!=g>c){const v=h[f][0],x=h[p][0];d.push(v+(x-v)*(c-m)/(g-m))}}d.sort((h,f)=>h-f);for(let h=0;h+1<d.length;h+=2){const f=d[h+1]-d[h];(!o||f>o.width)&&(o={width:f,x:(d[h]+d[h+1])/2,y:c})}}return o?[o.x,o.y]:t[0]}function xv(e,t,r){var a,s,o;let i=[];try{i=e.querySourceFeatures(Ed(t.id),{sourceLayer:t.vectorLayer})}catch{return r}r.labelRings||(r.labelRings=new Map);const n=tOe(t);for(const l of i){const u=(a=l.properties)==null?void 0:a[n];if(!u)continue;r.props.has(u)||r.props.set(u,{name:(s=l.properties)==null?void 0:s.name,country:(o=l.properties)==null?void 0:o.country});
1547const c=r.bounds.get(u)||new co;Gz(l.geometry,([d,h])=>{Number.isFinite(d)&&Number.isFinite(h)&&c.extend([d,h])}),c.isEmpty()||r.bounds.set(u,c);for(const d of Hz(l.geometry)){if(d[0].length<3)continue;const h=hP(d[0]),f=r.labelRings.get(u);(!f||h>hP(f[0]))&&r.labelRings.set(u,d)}}return r}const bOe=e=>new Promise(t=>e.once("idle",t));async function m3(e,t,r){e.fitBounds(Wy,{padding:20,duration:0});const i=t.minzoom??0;return i>0&&e.getZoom()<i&&e.setZoom(i),await bOe(e),xv(e,t,r),r.swept=!0,r}function Wz(e,t,{allowSweep:r=!0}={}){const i=dP.get(t.url);if(i)return i.then(async a=>(r&&!a.swept&&await m3(e,t,a),a));const n=(async()=>{const a={bounds:new Map,props:new Map,labelRings:new Map,swept:!1};return xv(e,t,a),!a.bounds.size&&r&&await m3(e,t,a),a})();return dP.set(t.url,n),n}async function xOe(e,t,{allowSweep:r=!1}={}){const i=await Wz(e,t,{allowSweep:r});return xv(e,t,i),{type:"FeatureCollection",features:[...i.bounds].map(([n,a])=>{var l;const s=(l=i.labelRings)==null?void 0:l.get(n),o=s&&Yz(s)||a.getCenter().toArray();return{type:"Feature",properties:{location_id:n,...i.props.get(n)},geometry:{type:"Point",coordinates:o}}})}}async function wOe(e,t,r,{padding:i=40,maxZoom:n=11,zoom:a=null}={}){const s=Array.isArray(t)?t:[t],o=await Promise.all(s.map(c=>Wz(e,c))),l=()=>o.map(c=>c.bounds.get(r)).find(Boolean);let u=l();if(!u){for(const[c,d]of o.entries())xv(e,s[c],d);u=l()}if(!u){for(const[c,d]of o.entries())if(d.swept=!1,await m3(e,s[c],d),l())break;u=l()}if(!u)return console.warn(`[ag-map] no feature found for location_id "${r}" in ${s.map(c=>c.id).join(", ")} â keeping current view.`),!1;if(a!==null){const c=o.map(h=>{var f;return(f=h.labelRings)==null?void 0:f.get(r)}).find(Boolean),d=c&&Yz(c)||u.getCenter().toArray();return await fP(e,()=>e.flyTo({center:d,zoom:a,duration:p3})),!0}return await fP(e,()=>e.fitBounds(u,{padding:i,maxZoom:n,duration:p3})),!0}function fP(e,t){return new Promise(r=>{e.once("moveend",r),t()})}const $Oe=["src"],SOe={key:3,class:"ag-map__error"},TOe={__name:"AgMap",props:{manifestUrl:{type:String,default:Bz},focus:{type:[String,Array],default:null},zoom:{type:Number,default:null},layers:{type:Array,default:null},features:{type:Object,default:()=>({})},showControls:{type:Boolean,default:!1},showLegend:{type:Boolean,default:!0},brand:{type:String,default:"/img/ag-faded-60.png"},keyItems:{type:Array,default:null},settings:{type:[Object,Array],default:null},refreshMs:{type:Number,default:3e5}},emits:["ready","manifest-loaded","error","layer-toggled","expanded"],setup(e,{expose:t,emit:r}){O7e(L7e);const i={type:"FeatureCollection",features:[]},n=e,a=r,s=se(null),o=se(null),l=Yu(null),u=Yu(null),c=se([]),d=se({}),h=se(null),f=H(()=>typeof n.focus=="string"&&n.focus||null),p=H(()=>Array.isArray(n.focus)&&n.focus.length===2?n.focus:null),m=H(()=>!!(f.value||p.value)),g=H(()=>{var N;return[f.value??"",((N=p.value)==null?void 0:N.join(","))??"",n.zoom??""].join("|")}),v=H(()=>({...K7e,...n.features})),x=H(()=>mOe(n.keyItems)),_=H(()=>yOe(c.value,d.value,x.value)),y=se([]),w=H(()=>y.value.length?_.value.map(N=>N.value).filter(N=>!y.value.includes(N)):x.value);function $(N,q){y.value=q?y.value.filter(te=>te!==N):[...y.value,N]}let S=null,E=null,C=null;const I=new Map,P=H(()=>iOe(n.settings)),T=H(()=>sOe(n.settings)),D=H(()=>uOe(n.settings)),A=()=>[{source:w_,data:T.value,specs:lOe},{source:f3,data:D.value,specs:dOe}],z=new Map;let R=!1;const O=N=>new Promise(q=>N.once("idle",q)),V=N=>!n.layers||n.layers.includes(N),Y=N=>!N||v.value[N]!==!1,F=(N,q,te)=>{N.getLayer(q)&&N.setLayoutProperty(q,"visibility",te?"visible":"none")},ae=N=>{const q=sP(N);return q?[...d2(N),q]:d2(N)},ue=(N,q)=>{var te;return d.value[N.id]!==!1&&Y((te=q.metadata)==null?void 0:te.agFeature)&&gOe(N.id,w.value)};function Z(N){for(const[q,te]of Object.entries(Z7e)){const ee=Y(q)&&_Oe(q,w.value);for(const oe of te)F(N,oe,ee)}for(const q of c.value)for(const te of ae(q))F(N,te.id,ue(q,te)),K(N,q,te)}function K(N,q,te){if(!N.getLayer(te.id))return;const ee=cP(q.id,w.value),oe=te.filter;if(!ee){N.setFilter(te.id,oe);return}N.setFilter(te.id,oe?["all",oe,ee]:ee)}function fe(N,q){var Se;const te=N.getStyle().layers,ee=q?te.findIndex(we=>we.id===q):-1,oe=ee===-1?te.length:ee;for(let we=0;we<oe;we++)if(te[we].type==="symbol"&&((Se=te[we].metadata)!=null&&Se.agLayer))return te[we].id;return q}function ve(N,q){N.getSource(Ed(q.id))||N.addSource(Ed(q.id),JRe(q)),d3(q)&&!N.getSource(gd(q.id))&&N.addSource(gd(q.id),{type:"geojson",data:i});const te=N.getLayer(Cd)?Cd:void 0;let ee=fe(N,te);const oe=(we,De)=>{if(N.getLayer(we.id))return;we.layout.visibility=ue(q,we)?"visible":"none";const Ue=cP(q.id,w.value);Ue&&(we.filter=we.filter?["all",we.filter,Ue]:Ue),N.addLayer(we,De)};for(const we of d2(q)){if(we.type!=="symbol"){oe(we,ee);continue}oe(we,te),ee===te&&(ee=we.id)}const Se=sP(q);Se&&oe(Se)}function $e(N,q){for(const te of ae(q))N.getLayer(te.id)&&N.removeLayer(te.id);N.getSource(gd(q.id))&&N.removeSource(gd(q.id)),N.getSource(Ed(q.id))&&N.removeSource(Ed(q.id))}function Re(N,q){var oe;d.value={...d.value,[N]:q};const te=l.value,ee=c.value.find(Se=>Se.id===N);if(!(!te||!ee)){for(const Se of ae(ee))F(te,Se.id,q&&Y((oe=Se.metadata)==null?void 0:oe.agFeature));a("layer-toggled",N,q)}}function Oe(N,q){const{source:te,data:ee,specs:oe}=q,Se=N.getSource(te);if(Se)Se.setData(ee),z.delete(te);else{if(!ee.features.length)return;N.addSource(te,{type:"geojson",data:ee});const we=N.getLayer(Cd)?Cd:void 0;for(const De of oe())N.addLayer(De,De.type==="symbol"?void 0:we)}Be(N,q)}function ze(N){const q=A();for(const te of q)Oe(N,te);R||!q.some(te=>N.getSource(te.source))||(R=!0,N.on("zoom",()=>{for(const te of A())Be(N,te)}))}function Be(N,{source:q,data:te,specs:ee}
1547){if(!N.getSource(q))return;const oe=N.getZoom(),Se=te.features.filter(De=>De.properties.minzoom<=oe&&De.properties.maxzoom>=oe).map(De=>De.properties.name??De.properties.label).join("|");if(z.get(q)===Se)return;z.set(q,Se);const we=oOe(oe);for(const De of ee())N.getLayer(De.id)&&N.setFilter(De.id,De.filter?["all",De.filter,we]:we)}function qe(N){return N.features.map(q=>{const[te,ee]=q.geometry.coordinates;return`${q.properties.location_id}|${q.properties.name??""}:${te.toFixed(5)},${ee.toFixed(5)}`}).sort().join("|")}async function j(N,{complete:q=!1}={}){N.loaded()||await O(N);for(const te of c.value.filter(d3))try{const ee=await xOe(N,te,{allowSweep:q}),oe=hOe(ee,P.value[te.id]),Se=qe(oe);if(I.get(te.id)===Se)continue;const we=N.getSource(gd(te.id));if(!we)continue;we.setData(oe),I.set(te.id,Se)}catch(ee){console.warn(`[ag-map] label points for "${te.id}" failed`,ee)}}async function W(N,{animate:q=!1}={}){const te=c.value.filter(XRe);if(!(f.value&&te.length&&await wOe(N,te,f.value,{zoom:n.zoom}))&&(p.value||n.zoom!==null)){const ee={...p.value?{center:p.value}:{},...n.zoom!==null?{zoom:n.zoom}:{}};q?N.flyTo({...ee,duration:p3}):N.jumpTo(ee)}}async function G(N){try{await W(N,{animate:!0})}catch(q){console.warn("[ag-map] re-centring on focus failed",q)}}function ie(){clearTimeout(E),c.value.some(N=>N.type==="live")&&(document.hidden||(E=setTimeout(U,n.refreshMs)))}async function U(){const N=l.value;if(N)try{const q=await tP(n.manifestUrl);for(const te of q.layers){if(te.type!=="live"||!V(te.id))continue;const ee=c.value.find(oe=>oe.id===te.id);(ee==null?void 0:ee.url)!==te.url&&(ee&&$e(N,ee),ve(N,te),c.value=[...c.value.filter(oe=>oe.id!==te.id),te])}}catch(q){q.name!=="AbortError"&&console.warn("[ag-map] live refresh failed",q)}finally{ie()}}function ne(){document.hidden?clearTimeout(E):ie()}async function me(){HRe();const N=p.value,q=new I7e({container:s.value,style:X7e(),...N?{center:N,zoom:n.zoom??6}:{bounds:Wy,fitBoundsOptions:{padding:20}},attributionControl:!1});l.value=q,q.addControl(new dRe({target:o.value,onChange:ee=>a("expanded",ee)}),"top-right"),q.addControl(new D7e({showCompass:!1}),"top-right"),u.value=new fRe({onFocus:()=>G(q)}),u.value.setAvailable(m.value),q.addControl(u.value,"top-right"),q.on("error",ee=>console.warn("[ag-map] maplibre error",(ee==null?void 0:ee.error)||ee)),q.on("idle",()=>j(q)),await new Promise(ee=>q.once("load",ee)),S=new AbortController;let te;try{te=await tP(n.manifestUrl,S.signal)}catch(ee){if(ee.name==="AbortError")return;h.value=ee.message,a("error",ee);return}c.value=te.layers.filter(ee=>V(ee.id)),d.value=Object.fromEntries(c.value.map(ee=>[ee.id,!0])),q.addControl(new xz({compact:!1,customAttribution:ZRe(c.value)}),"bottom-right");for(const ee of c.value)ve(q,ee);ze(q),Z(q),a("manifest-loaded",te),await O(q),q.resize(),N?(W(q),await O(q),await j(q)):(q.fitBounds(Wy,{padding:20,duration:0}),await O(q),await j(q,{complete:!0}),await W(q),await O(q),await j(q)),ie(),a("ready",q)}function J(){const N=l.value;N&&(N.resize(),N.redraw())}return or(()=>{me().catch(N=>{h.value=N.message,a("error",N)}),document.addEventListener("visibilitychange",ne),s.value&&typeof ResizeObserver<"u"&&(C=new ResizeObserver(J),C.observe(s.value))}),ra(()=>{var N;document.removeEventListener("visibilitychange",ne),C==null||C.disconnect(),C=null,clearTimeout(E),S==null||S.abort(),(N=l.value)==null||N.remove(),l.value=null,u.value=null,I.clear()}),tt(m,N=>{var q;return(q=u.value)==null?void 0:q.setAvailable(N)}),tt(v,()=>{l.value&&Z(l.value)}),tt(w,()=>{l.value&&Z(l.value)}),tt(g,async()=>{!l.value||!c.value.length||(await W(l.value),l.value&&await j(l.value))}),t({map:l}),(N,q)=>(k(),M("div",{ref_key:"root",ref:o,class:"ag-map"},[b("div",{ref_key:"container",ref:s,class:"ag-map__canvas"},null,512),e.showControls?(k(),Mt(U7e,{key:0,layers:c.value,visibility:d.value,onToggle:Re},null,8,["layers","visibility"])):X("",!0),e.showLegend?(k(),Mt(aRe,{key:1,entries:_.value,unchecked:y.value,onToggle:$},null,8,["entries","unchecked"])):X("",!0),e.brand?(k(),M("img",{key:2,src:e.brand,class:"ag-map__brand",alt:"",draggable:"false"},null,8,$Oe)):X("",!0),h.value?(k(),M("p",SOe,Q(h.value),1)):X("",!0)],512))}},COe=Yt(TOe,[["__scopeId","data-v-de6313bc"]]);_p.registerPlugin(Tt);T_e();const wv=N_({components:{SiteNavigation:_ge,ImageCarousel:hD,SafariCarousel:dde,GalleryBlock:qce,SectionList:hme,EnquiryForm:l0e,RelatedSectionBlock:T0e,BookNowButton:V0e,ResNovaPage:X0e,HubspotForm:t_e,HubspotFormcta:a_e,TypeForm:u_e,JotForm:f_e,HeroImageBlock:v_e,HubspotBookingForm:$_e,BookingsImageGallery:Pve,BookingsContainer:Wwe,BookingsCalendar:oR,BookingsAmenities:lR,BookingsShare:r3e,SearchContainer:Y4e,CurrencySelector:k$,CurrencyDisplay:eg,C24SearchForm:n$e,HubspotEnquiryContainer:W1e,ThankYouForEnquiring:ove,AgMap:COe}}),kOe=pq();wv.use(kOe);wv.use(Voe,{});wv.use(wce);wv.mount("#app");
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.